diff options
author | Baitinq <manuelpalenzuelamerino@gmail.com> | 2024-06-06 23:21:53 +0200 |
---|---|---|
committer | Baitinq <manuelpalenzuelamerino@gmail.com> | 2024-06-06 23:21:53 +0200 |
commit | df78f96338211f5b7cc4494461806cbf65d049b5 (patch) | |
tree | ab76a12c3ebee6508a6f1c0bd60e4a057227a286 | |
parent | Updates (diff) | |
download | fs-tracer-frontend-df78f96338211f5b7cc4494461806cbf65d049b5.tar.gz fs-tracer-frontend-df78f96338211f5b7cc4494461806cbf65d049b5.tar.bz2 fs-tracer-frontend-df78f96338211f5b7cc4494461806cbf65d049b5.zip |
Updates
-rw-r--r-- | assets/browser-Cflo9lLP.js (renamed from assets/browser-miNZUl8P.js) | 2 | ||||
-rw-r--r-- | assets/index-B-cH4mZc.js | 67 | ||||
-rw-r--r-- | assets/index-CYv8RTDj.js | 67 | ||||
-rw-r--r-- | index.html | 2 |
4 files changed, 69 insertions, 69 deletions
diff --git a/assets/browser-miNZUl8P.js b/assets/browser-Cflo9lLP.js index a544212..fa0fea0 100644 --- a/assets/browser-miNZUl8P.js +++ b/assets/browser-Cflo9lLP.js @@ -1 +1 @@ -import{g as a}from"./index-CYv8RTDj.js";function f(t,s){for(var o=0;o<s.length;o++){const e=s[o];if(typeof e!="string"&&!Array.isArray(e)){for(const r in e)if(r!=="default"&&!(r in t)){const n=Object.getOwnPropertyDescriptor(e,r);n&&Object.defineProperty(t,r,n.get?n:{enumerable:!0,get:()=>e[r]})}}}return Object.freeze(Object.defineProperty(t,Symbol.toStringTag,{value:"Module"}))}var c=function(){throw new Error("ws does not work in the browser. Browser clients must use the native WebSocket object")};const i=a(c),u=f({__proto__:null,default:i},[c]);export{u as b}; +import{g as a}from"./index-B-cH4mZc.js";function f(t,s){for(var o=0;o<s.length;o++){const e=s[o];if(typeof e!="string"&&!Array.isArray(e)){for(const r in e)if(r!=="default"&&!(r in t)){const n=Object.getOwnPropertyDescriptor(e,r);n&&Object.defineProperty(t,r,n.get?n:{enumerable:!0,get:()=>e[r]})}}}return Object.freeze(Object.defineProperty(t,Symbol.toStringTag,{value:"Module"}))}var c=function(){throw new Error("ws does not work in the browser. Browser clients must use the native WebSocket object")};const i=a(c),u=f({__proto__:null,default:i},[c]);export{u as b}; diff --git a/assets/index-B-cH4mZc.js b/assets/index-B-cH4mZc.js new file mode 100644 index 0000000..f068e98 --- /dev/null +++ b/assets/index-B-cH4mZc.js @@ -0,0 +1,67 @@ +function vf(e,t){for(var n=0;n<t.length;n++){const r=t[n];if(typeof r!="string"&&!Array.isArray(r)){for(const i in r)if(i!=="default"&&!(i in e)){const s=Object.getOwnPropertyDescriptor(r,i);s&&Object.defineProperty(e,i,s.get?s:{enumerable:!0,get:()=>r[i]})}}}return Object.freeze(Object.defineProperty(e,Symbol.toStringTag,{value:"Module"}))}(function(){const t=document.createElement("link").relList;if(t&&t.supports&&t.supports("modulepreload"))return;for(const i of document.querySelectorAll('link[rel="modulepreload"]'))r(i);new MutationObserver(i=>{for(const s of i)if(s.type==="childList")for(const o of s.addedNodes)o.tagName==="LINK"&&o.rel==="modulepreload"&&r(o)}).observe(document,{childList:!0,subtree:!0});function n(i){const s={};return i.integrity&&(s.integrity=i.integrity),i.referrerPolicy&&(s.referrerPolicy=i.referrerPolicy),i.crossOrigin==="use-credentials"?s.credentials="include":i.crossOrigin==="anonymous"?s.credentials="omit":s.credentials="same-origin",s}function r(i){if(i.ep)return;i.ep=!0;const s=n(i);fetch(i.href,s)}})();function mf(e){return e&&e.__esModule&&Object.prototype.hasOwnProperty.call(e,"default")?e.default:e}var Lu={exports:{}},Ki={},Iu={exports:{}},$={};/** + * @license React + * react.production.min.js + * + * Copyright (c) Facebook, Inc. and its affiliates. + * + * This source code is licensed under the MIT license found in the + * LICENSE file in the root directory of this source tree. + */var Nr=Symbol.for("react.element"),gf=Symbol.for("react.portal"),yf=Symbol.for("react.fragment"),wf=Symbol.for("react.strict_mode"),_f=Symbol.for("react.profiler"),Sf=Symbol.for("react.provider"),kf=Symbol.for("react.context"),Ef=Symbol.for("react.forward_ref"),Cf=Symbol.for("react.suspense"),xf=Symbol.for("react.memo"),Pf=Symbol.for("react.lazy"),Yl=Symbol.iterator;function Tf(e){return e===null||typeof e!="object"?null:(e=Yl&&e[Yl]||e["@@iterator"],typeof e=="function"?e:null)}var $u={isMounted:function(){return!1},enqueueForceUpdate:function(){},enqueueReplaceState:function(){},enqueueSetState:function(){}},Nu=Object.assign,Au={};function Un(e,t,n){this.props=e,this.context=t,this.refs=Au,this.updater=n||$u}Un.prototype.isReactComponent={};Un.prototype.setState=function(e,t){if(typeof e!="object"&&typeof e!="function"&&e!=null)throw Error("setState(...): takes an object of state variables to update or a function which returns an object of state variables.");this.updater.enqueueSetState(this,e,t,"setState")};Un.prototype.forceUpdate=function(e){this.updater.enqueueForceUpdate(this,e,"forceUpdate")};function Uu(){}Uu.prototype=Un.prototype;function qo(e,t,n){this.props=e,this.context=t,this.refs=Au,this.updater=n||$u}var Yo=qo.prototype=new Uu;Yo.constructor=qo;Nu(Yo,Un.prototype);Yo.isPureReactComponent=!0;var Xl=Array.isArray,Du=Object.prototype.hasOwnProperty,Xo={current:null},zu={key:!0,ref:!0,__self:!0,__source:!0};function Fu(e,t,n){var r,i={},s=null,o=null;if(t!=null)for(r in t.ref!==void 0&&(o=t.ref),t.key!==void 0&&(s=""+t.key),t)Du.call(t,r)&&!zu.hasOwnProperty(r)&&(i[r]=t[r]);var l=arguments.length-2;if(l===1)i.children=n;else if(1<l){for(var a=Array(l),u=0;u<l;u++)a[u]=arguments[u+2];i.children=a}if(e&&e.defaultProps)for(r in l=e.defaultProps,l)i[r]===void 0&&(i[r]=l[r]);return{$$typeof:Nr,type:e,key:s,ref:o,props:i,_owner:Xo.current}}function Of(e,t){return{$$typeof:Nr,type:e.type,key:t,ref:e.ref,props:e.props,_owner:e._owner}}function Zo(e){return typeof e=="object"&&e!==null&&e.$$typeof===Nr}function Rf(e){var t={"=":"=0",":":"=2"};return"$"+e.replace(/[=:]/g,function(n){return t[n]})}var Zl=/\/+/g;function vs(e,t){return typeof e=="object"&&e!==null&&e.key!=null?Rf(""+e.key):t.toString(36)}function ai(e,t,n,r,i){var s=typeof e;(s==="undefined"||s==="boolean")&&(e=null);var o=!1;if(e===null)o=!0;else switch(s){case"string":case"number":o=!0;break;case"object":switch(e.$$typeof){case Nr:case gf:o=!0}}if(o)return o=e,i=i(o),e=r===""?"."+vs(o,0):r,Xl(i)?(n="",e!=null&&(n=e.replace(Zl,"$&/")+"/"),ai(i,t,n,"",function(u){return u})):i!=null&&(Zo(i)&&(i=Of(i,n+(!i.key||o&&o.key===i.key?"":(""+i.key).replace(Zl,"$&/")+"/")+e)),t.push(i)),1;if(o=0,r=r===""?".":r+":",Xl(e))for(var l=0;l<e.length;l++){s=e[l];var a=r+vs(s,l);o+=ai(s,t,n,a,i)}else if(a=Tf(e),typeof a=="function")for(e=a.call(e),l=0;!(s=e.next()).done;)s=s.value,a=r+vs(s,l++),o+=ai(s,t,n,a,i);else if(s==="object")throw t=String(e),Error("Objects are not valid as a React child (found: "+(t==="[object Object]"?"object with keys {"+Object.keys(e).join(", ")+"}":t)+"). If you meant to render a collection of children, use an array instead.");return o}function Br(e,t,n){if(e==null)return e;var r=[],i=0;return ai(e,r,"","",function(s){return t.call(n,s,i++)}),r}function jf(e){if(e._status===-1){var t=e._result;t=t(),t.then(function(n){(e._status===0||e._status===-1)&&(e._status=1,e._result=n)},function(n){(e._status===0||e._status===-1)&&(e._status=2,e._result=n)}),e._status===-1&&(e._status=0,e._result=t)}if(e._status===1)return e._result.default;throw e._result}var pe={current:null},ui={transition:null},Lf={ReactCurrentDispatcher:pe,ReactCurrentBatchConfig:ui,ReactCurrentOwner:Xo};function Mu(){throw Error("act(...) is not supported in production builds of React.")}$.Children={map:Br,forEach:function(e,t,n){Br(e,function(){t.apply(this,arguments)},n)},count:function(e){var t=0;return Br(e,function(){t++}),t},toArray:function(e){return Br(e,function(t){return t})||[]},only:function(e){if(!Zo(e))throw Error("React.Children.only expected to receive a single React element child.");return e}};$.Component=Un;$.Fragment=yf;$.Profiler=_f;$.PureComponent=qo;$.StrictMode=wf;$.Suspense=Cf;$.__SECRET_INTERNALS_DO_NOT_USE_OR_YOU_WILL_BE_FIRED=Lf;$.act=Mu;$.cloneElement=function(e,t,n){if(e==null)throw Error("React.cloneElement(...): The argument must be a React element, but you passed "+e+".");var r=Nu({},e.props),i=e.key,s=e.ref,o=e._owner;if(t!=null){if(t.ref!==void 0&&(s=t.ref,o=Xo.current),t.key!==void 0&&(i=""+t.key),e.type&&e.type.defaultProps)var l=e.type.defaultProps;for(a in t)Du.call(t,a)&&!zu.hasOwnProperty(a)&&(r[a]=t[a]===void 0&&l!==void 0?l[a]:t[a])}var a=arguments.length-2;if(a===1)r.children=n;else if(1<a){l=Array(a);for(var u=0;u<a;u++)l[u]=arguments[u+2];r.children=l}return{$$typeof:Nr,type:e.type,key:i,ref:s,props:r,_owner:o}};$.createContext=function(e){return e={$$typeof:kf,_currentValue:e,_currentValue2:e,_threadCount:0,Provider:null,Consumer:null,_defaultValue:null,_globalName:null},e.Provider={$$typeof:Sf,_context:e},e.Consumer=e};$.createElement=Fu;$.createFactory=function(e){var t=Fu.bind(null,e);return t.type=e,t};$.createRef=function(){return{current:null}};$.forwardRef=function(e){return{$$typeof:Ef,render:e}};$.isValidElement=Zo;$.lazy=function(e){return{$$typeof:Pf,_payload:{_status:-1,_result:e},_init:jf}};$.memo=function(e,t){return{$$typeof:xf,type:e,compare:t===void 0?null:t}};$.startTransition=function(e){var t=ui.transition;ui.transition={};try{e()}finally{ui.transition=t}};$.unstable_act=Mu;$.useCallback=function(e,t){return pe.current.useCallback(e,t)};$.useContext=function(e){return pe.current.useContext(e)};$.useDebugValue=function(){};$.useDeferredValue=function(e){return pe.current.useDeferredValue(e)};$.useEffect=function(e,t){return pe.current.useEffect(e,t)};$.useId=function(){return pe.current.useId()};$.useImperativeHandle=function(e,t,n){return pe.current.useImperativeHandle(e,t,n)};$.useInsertionEffect=function(e,t){return pe.current.useInsertionEffect(e,t)};$.useLayoutEffect=function(e,t){return pe.current.useLayoutEffect(e,t)};$.useMemo=function(e,t){return pe.current.useMemo(e,t)};$.useReducer=function(e,t,n){return pe.current.useReducer(e,t,n)};$.useRef=function(e){return pe.current.useRef(e)};$.useState=function(e){return pe.current.useState(e)};$.useSyncExternalStore=function(e,t,n){return pe.current.useSyncExternalStore(e,t,n)};$.useTransition=function(){return pe.current.useTransition()};$.version="18.3.1";Iu.exports=$;var E=Iu.exports;const Gi=mf(E),If=vf({__proto__:null,default:Gi},[E]);/** + * @license React + * react-jsx-runtime.production.min.js + * + * Copyright (c) Facebook, Inc. and its affiliates. + * + * This source code is licensed under the MIT license found in the + * LICENSE file in the root directory of this source tree. + */var $f=E,Nf=Symbol.for("react.element"),Af=Symbol.for("react.fragment"),Uf=Object.prototype.hasOwnProperty,Df=$f.__SECRET_INTERNALS_DO_NOT_USE_OR_YOU_WILL_BE_FIRED.ReactCurrentOwner,zf={key:!0,ref:!0,__self:!0,__source:!0};function bu(e,t,n){var r,i={},s=null,o=null;n!==void 0&&(s=""+n),t.key!==void 0&&(s=""+t.key),t.ref!==void 0&&(o=t.ref);for(r in t)Uf.call(t,r)&&!zf.hasOwnProperty(r)&&(i[r]=t[r]);if(e&&e.defaultProps)for(r in t=e.defaultProps,t)i[r]===void 0&&(i[r]=t[r]);return{$$typeof:Nf,type:e,key:s,ref:o,props:i,_owner:Df.current}}Ki.Fragment=Af;Ki.jsx=bu;Ki.jsxs=bu;Lu.exports=Ki;var z=Lu.exports,Qs={},Bu={exports:{}},Pe={},Vu={exports:{}},Hu={};/** + * @license React + * scheduler.production.min.js + * + * Copyright (c) Facebook, Inc. and its affiliates. + * + * This source code is licensed under the MIT license found in the + * LICENSE file in the root directory of this source tree. + */(function(e){function t(x,R){var L=x.length;x.push(R);e:for(;0<L;){var Q=L-1>>>1,ee=x[Q];if(0<i(ee,R))x[Q]=R,x[L]=ee,L=Q;else break e}}function n(x){return x.length===0?null:x[0]}function r(x){if(x.length===0)return null;var R=x[0],L=x.pop();if(L!==R){x[0]=L;e:for(var Q=0,ee=x.length,Mr=ee>>>1;Q<Mr;){var Nt=2*(Q+1)-1,ps=x[Nt],At=Nt+1,br=x[At];if(0>i(ps,L))At<ee&&0>i(br,ps)?(x[Q]=br,x[At]=L,Q=At):(x[Q]=ps,x[Nt]=L,Q=Nt);else if(At<ee&&0>i(br,L))x[Q]=br,x[At]=L,Q=At;else break e}}return R}function i(x,R){var L=x.sortIndex-R.sortIndex;return L!==0?L:x.id-R.id}if(typeof performance=="object"&&typeof performance.now=="function"){var s=performance;e.unstable_now=function(){return s.now()}}else{var o=Date,l=o.now();e.unstable_now=function(){return o.now()-l}}var a=[],u=[],c=1,d=null,h=3,m=!1,g=!1,y=!1,_=typeof setTimeout=="function"?setTimeout:null,p=typeof clearTimeout=="function"?clearTimeout:null,f=typeof setImmediate<"u"?setImmediate:null;typeof navigator<"u"&&navigator.scheduling!==void 0&&navigator.scheduling.isInputPending!==void 0&&navigator.scheduling.isInputPending.bind(navigator.scheduling);function v(x){for(var R=n(u);R!==null;){if(R.callback===null)r(u);else if(R.startTime<=x)r(u),R.sortIndex=R.expirationTime,t(a,R);else break;R=n(u)}}function w(x){if(y=!1,v(x),!g)if(n(a)!==null)g=!0,Ze(k);else{var R=n(u);R!==null&&Bn(w,R.startTime-x)}}function k(x,R){g=!1,y&&(y=!1,p(O),O=-1),m=!0;var L=h;try{for(v(R),d=n(a);d!==null&&(!(d.expirationTime>R)||x&&!de());){var Q=d.callback;if(typeof Q=="function"){d.callback=null,h=d.priorityLevel;var ee=Q(d.expirationTime<=R);R=e.unstable_now(),typeof ee=="function"?d.callback=ee:d===n(a)&&r(a),v(R)}else r(a);d=n(a)}if(d!==null)var Mr=!0;else{var Nt=n(u);Nt!==null&&Bn(w,Nt.startTime-R),Mr=!1}return Mr}finally{d=null,h=L,m=!1}}var P=!1,T=null,O=-1,M=5,j=-1;function de(){return!(e.unstable_now()-j<M)}function qe(){if(T!==null){var x=e.unstable_now();j=x;var R=!0;try{R=T(!0,x)}finally{R?Ye():(P=!1,T=null)}}else P=!1}var Ye;if(typeof f=="function")Ye=function(){f(qe)};else if(typeof MessageChannel<"u"){var Oe=new MessageChannel,Xe=Oe.port2;Oe.port1.onmessage=qe,Ye=function(){Xe.postMessage(null)}}else Ye=function(){_(qe,0)};function Ze(x){T=x,P||(P=!0,Ye())}function Bn(x,R){O=_(function(){x(e.unstable_now())},R)}e.unstable_IdlePriority=5,e.unstable_ImmediatePriority=1,e.unstable_LowPriority=4,e.unstable_NormalPriority=3,e.unstable_Profiling=null,e.unstable_UserBlockingPriority=2,e.unstable_cancelCallback=function(x){x.callback=null},e.unstable_continueExecution=function(){g||m||(g=!0,Ze(k))},e.unstable_forceFrameRate=function(x){0>x||125<x?console.error("forceFrameRate takes a positive int between 0 and 125, forcing frame rates higher than 125 fps is not supported"):M=0<x?Math.floor(1e3/x):5},e.unstable_getCurrentPriorityLevel=function(){return h},e.unstable_getFirstCallbackNode=function(){return n(a)},e.unstable_next=function(x){switch(h){case 1:case 2:case 3:var R=3;break;default:R=h}var L=h;h=R;try{return x()}finally{h=L}},e.unstable_pauseExecution=function(){},e.unstable_requestPaint=function(){},e.unstable_runWithPriority=function(x,R){switch(x){case 1:case 2:case 3:case 4:case 5:break;default:x=3}var L=h;h=x;try{return R()}finally{h=L}},e.unstable_scheduleCallback=function(x,R,L){var Q=e.unstable_now();switch(typeof L=="object"&&L!==null?(L=L.delay,L=typeof L=="number"&&0<L?Q+L:Q):L=Q,x){case 1:var ee=-1;break;case 2:ee=250;break;case 5:ee=1073741823;break;case 4:ee=1e4;break;default:ee=5e3}return ee=L+ee,x={id:c++,callback:R,priorityLevel:x,startTime:L,expirationTime:ee,sortIndex:-1},L>Q?(x.sortIndex=L,t(u,x),n(a)===null&&x===n(u)&&(y?(p(O),O=-1):y=!0,Bn(w,L-Q))):(x.sortIndex=ee,t(a,x),g||m||(g=!0,Ze(k))),x},e.unstable_shouldYield=de,e.unstable_wrapCallback=function(x){var R=h;return function(){var L=h;h=R;try{return x.apply(this,arguments)}finally{h=L}}}})(Hu);Vu.exports=Hu;var Ff=Vu.exports;/** + * @license React + * react-dom.production.min.js + * + * Copyright (c) Facebook, Inc. and its affiliates. + * + * This source code is licensed under the MIT license found in the + * LICENSE file in the root directory of this source tree. + */var Mf=E,xe=Ff;function S(e){for(var t="https://reactjs.org/docs/error-decoder.html?invariant="+e,n=1;n<arguments.length;n++)t+="&args[]="+encodeURIComponent(arguments[n]);return"Minified React error #"+e+"; visit "+t+" for the full message or use the non-minified dev environment for full errors and additional helpful warnings."}var Wu=new Set,pr={};function Zt(e,t){Tn(e,t),Tn(e+"Capture",t)}function Tn(e,t){for(pr[e]=t,e=0;e<t.length;e++)Wu.add(t[e])}var st=!(typeof window>"u"||typeof window.document>"u"||typeof window.document.createElement>"u"),Js=Object.prototype.hasOwnProperty,bf=/^[: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]*$/,ea={},ta={};function Bf(e){return Js.call(ta,e)?!0:Js.call(ea,e)?!1:bf.test(e)?ta[e]=!0:(ea[e]=!0,!1)}function Vf(e,t,n,r){if(n!==null&&n.type===0)return!1;switch(typeof t){case"function":case"symbol":return!0;case"boolean":return r?!1:n!==null?!n.acceptsBooleans:(e=e.toLowerCase().slice(0,5),e!=="data-"&&e!=="aria-");default:return!1}}function Hf(e,t,n,r){if(t===null||typeof t>"u"||Vf(e,t,n,r))return!0;if(r)return!1;if(n!==null)switch(n.type){case 3:return!t;case 4:return t===!1;case 5:return isNaN(t);case 6:return isNaN(t)||1>t}return!1}function ve(e,t,n,r,i,s,o){this.acceptsBooleans=t===2||t===3||t===4,this.attributeName=r,this.attributeNamespace=i,this.mustUseProperty=n,this.propertyName=e,this.type=t,this.sanitizeURL=s,this.removeEmptyString=o}var se={};"children dangerouslySetInnerHTML defaultValue defaultChecked innerHTML suppressContentEditableWarning suppressHydrationWarning style".split(" ").forEach(function(e){se[e]=new ve(e,0,!1,e,null,!1,!1)});[["acceptCharset","accept-charset"],["className","class"],["htmlFor","for"],["httpEquiv","http-equiv"]].forEach(function(e){var t=e[0];se[t]=new ve(t,1,!1,e[1],null,!1,!1)});["contentEditable","draggable","spellCheck","value"].forEach(function(e){se[e]=new ve(e,2,!1,e.toLowerCase(),null,!1,!1)});["autoReverse","externalResourcesRequired","focusable","preserveAlpha"].forEach(function(e){se[e]=new ve(e,2,!1,e,null,!1,!1)});"allowFullScreen async autoFocus autoPlay controls default defer disabled disablePictureInPicture disableRemotePlayback formNoValidate hidden loop noModule noValidate open playsInline readOnly required reversed scoped seamless itemScope".split(" ").forEach(function(e){se[e]=new ve(e,3,!1,e.toLowerCase(),null,!1,!1)});["checked","multiple","muted","selected"].forEach(function(e){se[e]=new ve(e,3,!0,e,null,!1,!1)});["capture","download"].forEach(function(e){se[e]=new ve(e,4,!1,e,null,!1,!1)});["cols","rows","size","span"].forEach(function(e){se[e]=new ve(e,6,!1,e,null,!1,!1)});["rowSpan","start"].forEach(function(e){se[e]=new ve(e,5,!1,e.toLowerCase(),null,!1,!1)});var el=/[\-:]([a-z])/g;function tl(e){return e[1].toUpperCase()}"accent-height alignment-baseline arabic-form baseline-shift cap-height clip-path clip-rule color-interpolation color-interpolation-filters color-profile color-rendering dominant-baseline enable-background fill-opacity fill-rule flood-color flood-opacity font-family font-size font-size-adjust font-stretch font-style font-variant font-weight glyph-name glyph-orientation-horizontal glyph-orientation-vertical horiz-adv-x horiz-origin-x image-rendering letter-spacing lighting-color marker-end marker-mid marker-start overline-position overline-thickness paint-order panose-1 pointer-events rendering-intent shape-rendering stop-color stop-opacity strikethrough-position strikethrough-thickness stroke-dasharray stroke-dashoffset stroke-linecap stroke-linejoin stroke-miterlimit stroke-opacity stroke-width text-anchor text-decoration text-rendering underline-position underline-thickness unicode-bidi unicode-range units-per-em v-alphabetic v-hanging v-ideographic v-mathematical vector-effect vert-adv-y vert-origin-x vert-origin-y word-spacing writing-mode xmlns:xlink x-height".split(" ").forEach(function(e){var t=e.replace(el,tl);se[t]=new ve(t,1,!1,e,null,!1,!1)});"xlink:actuate xlink:arcrole xlink:role xlink:show xlink:title xlink:type".split(" ").forEach(function(e){var t=e.replace(el,tl);se[t]=new ve(t,1,!1,e,"http://www.w3.org/1999/xlink",!1,!1)});["xml:base","xml:lang","xml:space"].forEach(function(e){var t=e.replace(el,tl);se[t]=new ve(t,1,!1,e,"http://www.w3.org/XML/1998/namespace",!1,!1)});["tabIndex","crossOrigin"].forEach(function(e){se[e]=new ve(e,1,!1,e.toLowerCase(),null,!1,!1)});se.xlinkHref=new ve("xlinkHref",1,!1,"xlink:href","http://www.w3.org/1999/xlink",!0,!1);["src","href","action","formAction"].forEach(function(e){se[e]=new ve(e,1,!1,e.toLowerCase(),null,!0,!0)});function nl(e,t,n,r){var i=se.hasOwnProperty(t)?se[t]:null;(i!==null?i.type!==0:r||!(2<t.length)||t[0]!=="o"&&t[0]!=="O"||t[1]!=="n"&&t[1]!=="N")&&(Hf(t,n,i,r)&&(n=null),r||i===null?Bf(t)&&(n===null?e.removeAttribute(t):e.setAttribute(t,""+n)):i.mustUseProperty?e[i.propertyName]=n===null?i.type===3?!1:"":n:(t=i.attributeName,r=i.attributeNamespace,n===null?e.removeAttribute(t):(i=i.type,n=i===3||i===4&&n===!0?"":""+n,r?e.setAttributeNS(r,t,n):e.setAttribute(t,n))))}var ut=Mf.__SECRET_INTERNALS_DO_NOT_USE_OR_YOU_WILL_BE_FIRED,Vr=Symbol.for("react.element"),an=Symbol.for("react.portal"),un=Symbol.for("react.fragment"),rl=Symbol.for("react.strict_mode"),qs=Symbol.for("react.profiler"),Ku=Symbol.for("react.provider"),Gu=Symbol.for("react.context"),il=Symbol.for("react.forward_ref"),Ys=Symbol.for("react.suspense"),Xs=Symbol.for("react.suspense_list"),sl=Symbol.for("react.memo"),ft=Symbol.for("react.lazy"),Qu=Symbol.for("react.offscreen"),na=Symbol.iterator;function Vn(e){return e===null||typeof e!="object"?null:(e=na&&e[na]||e["@@iterator"],typeof e=="function"?e:null)}var K=Object.assign,ms;function Xn(e){if(ms===void 0)try{throw Error()}catch(n){var t=n.stack.trim().match(/\n( *(at )?)/);ms=t&&t[1]||""}return` +`+ms+e}var gs=!1;function ys(e,t){if(!e||gs)return"";gs=!0;var n=Error.prepareStackTrace;Error.prepareStackTrace=void 0;try{if(t)if(t=function(){throw Error()},Object.defineProperty(t.prototype,"props",{set:function(){throw Error()}}),typeof Reflect=="object"&&Reflect.construct){try{Reflect.construct(t,[])}catch(u){var r=u}Reflect.construct(e,[],t)}else{try{t.call()}catch(u){r=u}e.call(t.prototype)}else{try{throw Error()}catch(u){r=u}e()}}catch(u){if(u&&r&&typeof u.stack=="string"){for(var i=u.stack.split(` +`),s=r.stack.split(` +`),o=i.length-1,l=s.length-1;1<=o&&0<=l&&i[o]!==s[l];)l--;for(;1<=o&&0<=l;o--,l--)if(i[o]!==s[l]){if(o!==1||l!==1)do if(o--,l--,0>l||i[o]!==s[l]){var a=` +`+i[o].replace(" at new "," at ");return e.displayName&&a.includes("<anonymous>")&&(a=a.replace("<anonymous>",e.displayName)),a}while(1<=o&&0<=l);break}}}finally{gs=!1,Error.prepareStackTrace=n}return(e=e?e.displayName||e.name:"")?Xn(e):""}function Wf(e){switch(e.tag){case 5:return Xn(e.type);case 16:return Xn("Lazy");case 13:return Xn("Suspense");case 19:return Xn("SuspenseList");case 0:case 2:case 15:return e=ys(e.type,!1),e;case 11:return e=ys(e.type.render,!1),e;case 1:return e=ys(e.type,!0),e;default:return""}}function Zs(e){if(e==null)return null;if(typeof e=="function")return e.displayName||e.name||null;if(typeof e=="string")return e;switch(e){case un:return"Fragment";case an:return"Portal";case qs:return"Profiler";case rl:return"StrictMode";case Ys:return"Suspense";case Xs:return"SuspenseList"}if(typeof e=="object")switch(e.$$typeof){case Gu:return(e.displayName||"Context")+".Consumer";case Ku:return(e._context.displayName||"Context")+".Provider";case il:var t=e.render;return e=e.displayName,e||(e=t.displayName||t.name||"",e=e!==""?"ForwardRef("+e+")":"ForwardRef"),e;case sl:return t=e.displayName||null,t!==null?t:Zs(e.type)||"Memo";case ft:t=e._payload,e=e._init;try{return Zs(e(t))}catch{}}return null}function Kf(e){var t=e.type;switch(e.tag){case 24:return"Cache";case 9:return(t.displayName||"Context")+".Consumer";case 10:return(t._context.displayName||"Context")+".Provider";case 18:return"DehydratedFragment";case 11:return e=t.render,e=e.displayName||e.name||"",t.displayName||(e!==""?"ForwardRef("+e+")":"ForwardRef");case 7:return"Fragment";case 5:return t;case 4:return"Portal";case 3:return"Root";case 6:return"Text";case 16:return Zs(t);case 8:return t===rl?"StrictMode":"Mode";case 22:return"Offscreen";case 12:return"Profiler";case 21:return"Scope";case 13:return"Suspense";case 19:return"SuspenseList";case 25:return"TracingMarker";case 1:case 0:case 17:case 2:case 14:case 15:if(typeof t=="function")return t.displayName||t.name||null;if(typeof t=="string")return t}return null}function Rt(e){switch(typeof e){case"boolean":case"number":case"string":case"undefined":return e;case"object":return e;default:return""}}function Ju(e){var t=e.type;return(e=e.nodeName)&&e.toLowerCase()==="input"&&(t==="checkbox"||t==="radio")}function Gf(e){var t=Ju(e)?"checked":"value",n=Object.getOwnPropertyDescriptor(e.constructor.prototype,t),r=""+e[t];if(!e.hasOwnProperty(t)&&typeof n<"u"&&typeof n.get=="function"&&typeof n.set=="function"){var i=n.get,s=n.set;return Object.defineProperty(e,t,{configurable:!0,get:function(){return i.call(this)},set:function(o){r=""+o,s.call(this,o)}}),Object.defineProperty(e,t,{enumerable:n.enumerable}),{getValue:function(){return r},setValue:function(o){r=""+o},stopTracking:function(){e._valueTracker=null,delete e[t]}}}}function Hr(e){e._valueTracker||(e._valueTracker=Gf(e))}function qu(e){if(!e)return!1;var t=e._valueTracker;if(!t)return!0;var n=t.getValue(),r="";return e&&(r=Ju(e)?e.checked?"true":"false":e.value),e=r,e!==n?(t.setValue(e),!0):!1}function Si(e){if(e=e||(typeof document<"u"?document:void 0),typeof e>"u")return null;try{return e.activeElement||e.body}catch{return e.body}}function eo(e,t){var n=t.checked;return K({},t,{defaultChecked:void 0,defaultValue:void 0,value:void 0,checked:n??e._wrapperState.initialChecked})}function ra(e,t){var n=t.defaultValue==null?"":t.defaultValue,r=t.checked!=null?t.checked:t.defaultChecked;n=Rt(t.value!=null?t.value:n),e._wrapperState={initialChecked:r,initialValue:n,controlled:t.type==="checkbox"||t.type==="radio"?t.checked!=null:t.value!=null}}function Yu(e,t){t=t.checked,t!=null&&nl(e,"checked",t,!1)}function to(e,t){Yu(e,t);var n=Rt(t.value),r=t.type;if(n!=null)r==="number"?(n===0&&e.value===""||e.value!=n)&&(e.value=""+n):e.value!==""+n&&(e.value=""+n);else if(r==="submit"||r==="reset"){e.removeAttribute("value");return}t.hasOwnProperty("value")?no(e,t.type,n):t.hasOwnProperty("defaultValue")&&no(e,t.type,Rt(t.defaultValue)),t.checked==null&&t.defaultChecked!=null&&(e.defaultChecked=!!t.defaultChecked)}function ia(e,t,n){if(t.hasOwnProperty("value")||t.hasOwnProperty("defaultValue")){var r=t.type;if(!(r!=="submit"&&r!=="reset"||t.value!==void 0&&t.value!==null))return;t=""+e._wrapperState.initialValue,n||t===e.value||(e.value=t),e.defaultValue=t}n=e.name,n!==""&&(e.name=""),e.defaultChecked=!!e._wrapperState.initialChecked,n!==""&&(e.name=n)}function no(e,t,n){(t!=="number"||Si(e.ownerDocument)!==e)&&(n==null?e.defaultValue=""+e._wrapperState.initialValue:e.defaultValue!==""+n&&(e.defaultValue=""+n))}var Zn=Array.isArray;function _n(e,t,n,r){if(e=e.options,t){t={};for(var i=0;i<n.length;i++)t["$"+n[i]]=!0;for(n=0;n<e.length;n++)i=t.hasOwnProperty("$"+e[n].value),e[n].selected!==i&&(e[n].selected=i),i&&r&&(e[n].defaultSelected=!0)}else{for(n=""+Rt(n),t=null,i=0;i<e.length;i++){if(e[i].value===n){e[i].selected=!0,r&&(e[i].defaultSelected=!0);return}t!==null||e[i].disabled||(t=e[i])}t!==null&&(t.selected=!0)}}function ro(e,t){if(t.dangerouslySetInnerHTML!=null)throw Error(S(91));return K({},t,{value:void 0,defaultValue:void 0,children:""+e._wrapperState.initialValue})}function sa(e,t){var n=t.value;if(n==null){if(n=t.children,t=t.defaultValue,n!=null){if(t!=null)throw Error(S(92));if(Zn(n)){if(1<n.length)throw Error(S(93));n=n[0]}t=n}t==null&&(t=""),n=t}e._wrapperState={initialValue:Rt(n)}}function Xu(e,t){var n=Rt(t.value),r=Rt(t.defaultValue);n!=null&&(n=""+n,n!==e.value&&(e.value=n),t.defaultValue==null&&e.defaultValue!==n&&(e.defaultValue=n)),r!=null&&(e.defaultValue=""+r)}function oa(e){var t=e.textContent;t===e._wrapperState.initialValue&&t!==""&&t!==null&&(e.value=t)}function Zu(e){switch(e){case"svg":return"http://www.w3.org/2000/svg";case"math":return"http://www.w3.org/1998/Math/MathML";default:return"http://www.w3.org/1999/xhtml"}}function io(e,t){return e==null||e==="http://www.w3.org/1999/xhtml"?Zu(t):e==="http://www.w3.org/2000/svg"&&t==="foreignObject"?"http://www.w3.org/1999/xhtml":e}var Wr,ec=function(e){return typeof MSApp<"u"&&MSApp.execUnsafeLocalFunction?function(t,n,r,i){MSApp.execUnsafeLocalFunction(function(){return e(t,n,r,i)})}:e}(function(e,t){if(e.namespaceURI!=="http://www.w3.org/2000/svg"||"innerHTML"in e)e.innerHTML=t;else{for(Wr=Wr||document.createElement("div"),Wr.innerHTML="<svg>"+t.valueOf().toString()+"</svg>",t=Wr.firstChild;e.firstChild;)e.removeChild(e.firstChild);for(;t.firstChild;)e.appendChild(t.firstChild)}});function vr(e,t){if(t){var n=e.firstChild;if(n&&n===e.lastChild&&n.nodeType===3){n.nodeValue=t;return}}e.textContent=t}var rr={animationIterationCount:!0,aspectRatio:!0,borderImageOutset:!0,borderImageSlice:!0,borderImageWidth:!0,boxFlex:!0,boxFlexGroup:!0,boxOrdinalGroup:!0,columnCount:!0,columns:!0,flex:!0,flexGrow:!0,flexPositive:!0,flexShrink:!0,flexNegative:!0,flexOrder:!0,gridArea:!0,gridRow:!0,gridRowEnd:!0,gridRowSpan:!0,gridRowStart:!0,gridColumn:!0,gridColumnEnd:!0,gridColumnSpan:!0,gridColumnStart:!0,fontWeight:!0,lineClamp:!0,lineHeight:!0,opacity:!0,order:!0,orphans:!0,tabSize:!0,widows:!0,zIndex:!0,zoom:!0,fillOpacity:!0,floodOpacity:!0,stopOpacity:!0,strokeDasharray:!0,strokeDashoffset:!0,strokeMiterlimit:!0,strokeOpacity:!0,strokeWidth:!0},Qf=["Webkit","ms","Moz","O"];Object.keys(rr).forEach(function(e){Qf.forEach(function(t){t=t+e.charAt(0).toUpperCase()+e.substring(1),rr[t]=rr[e]})});function tc(e,t,n){return t==null||typeof t=="boolean"||t===""?"":n||typeof t!="number"||t===0||rr.hasOwnProperty(e)&&rr[e]?(""+t).trim():t+"px"}function nc(e,t){e=e.style;for(var n in t)if(t.hasOwnProperty(n)){var r=n.indexOf("--")===0,i=tc(n,t[n],r);n==="float"&&(n="cssFloat"),r?e.setProperty(n,i):e[n]=i}}var Jf=K({menuitem:!0},{area:!0,base:!0,br:!0,col:!0,embed:!0,hr:!0,img:!0,input:!0,keygen:!0,link:!0,meta:!0,param:!0,source:!0,track:!0,wbr:!0});function so(e,t){if(t){if(Jf[e]&&(t.children!=null||t.dangerouslySetInnerHTML!=null))throw Error(S(137,e));if(t.dangerouslySetInnerHTML!=null){if(t.children!=null)throw Error(S(60));if(typeof t.dangerouslySetInnerHTML!="object"||!("__html"in t.dangerouslySetInnerHTML))throw Error(S(61))}if(t.style!=null&&typeof t.style!="object")throw Error(S(62))}}function oo(e,t){if(e.indexOf("-")===-1)return typeof t.is=="string";switch(e){case"annotation-xml":case"color-profile":case"font-face":case"font-face-src":case"font-face-uri":case"font-face-format":case"font-face-name":case"missing-glyph":return!1;default:return!0}}var lo=null;function ol(e){return e=e.target||e.srcElement||window,e.correspondingUseElement&&(e=e.correspondingUseElement),e.nodeType===3?e.parentNode:e}var ao=null,Sn=null,kn=null;function la(e){if(e=Dr(e)){if(typeof ao!="function")throw Error(S(280));var t=e.stateNode;t&&(t=Xi(t),ao(e.stateNode,e.type,t))}}function rc(e){Sn?kn?kn.push(e):kn=[e]:Sn=e}function ic(){if(Sn){var e=Sn,t=kn;if(kn=Sn=null,la(e),t)for(e=0;e<t.length;e++)la(t[e])}}function sc(e,t){return e(t)}function oc(){}var ws=!1;function lc(e,t,n){if(ws)return e(t,n);ws=!0;try{return sc(e,t,n)}finally{ws=!1,(Sn!==null||kn!==null)&&(oc(),ic())}}function mr(e,t){var n=e.stateNode;if(n===null)return null;var r=Xi(n);if(r===null)return null;n=r[t];e:switch(t){case"onClick":case"onClickCapture":case"onDoubleClick":case"onDoubleClickCapture":case"onMouseDown":case"onMouseDownCapture":case"onMouseMove":case"onMouseMoveCapture":case"onMouseUp":case"onMouseUpCapture":case"onMouseEnter":(r=!r.disabled)||(e=e.type,r=!(e==="button"||e==="input"||e==="select"||e==="textarea")),e=!r;break e;default:e=!1}if(e)return null;if(n&&typeof n!="function")throw Error(S(231,t,typeof n));return n}var uo=!1;if(st)try{var Hn={};Object.defineProperty(Hn,"passive",{get:function(){uo=!0}}),window.addEventListener("test",Hn,Hn),window.removeEventListener("test",Hn,Hn)}catch{uo=!1}function qf(e,t,n,r,i,s,o,l,a){var u=Array.prototype.slice.call(arguments,3);try{t.apply(n,u)}catch(c){this.onError(c)}}var ir=!1,ki=null,Ei=!1,co=null,Yf={onError:function(e){ir=!0,ki=e}};function Xf(e,t,n,r,i,s,o,l,a){ir=!1,ki=null,qf.apply(Yf,arguments)}function Zf(e,t,n,r,i,s,o,l,a){if(Xf.apply(this,arguments),ir){if(ir){var u=ki;ir=!1,ki=null}else throw Error(S(198));Ei||(Ei=!0,co=u)}}function en(e){var t=e,n=e;if(e.alternate)for(;t.return;)t=t.return;else{e=t;do t=e,t.flags&4098&&(n=t.return),e=t.return;while(e)}return t.tag===3?n:null}function ac(e){if(e.tag===13){var t=e.memoizedState;if(t===null&&(e=e.alternate,e!==null&&(t=e.memoizedState)),t!==null)return t.dehydrated}return null}function aa(e){if(en(e)!==e)throw Error(S(188))}function eh(e){var t=e.alternate;if(!t){if(t=en(e),t===null)throw Error(S(188));return t!==e?null:e}for(var n=e,r=t;;){var i=n.return;if(i===null)break;var s=i.alternate;if(s===null){if(r=i.return,r!==null){n=r;continue}break}if(i.child===s.child){for(s=i.child;s;){if(s===n)return aa(i),e;if(s===r)return aa(i),t;s=s.sibling}throw Error(S(188))}if(n.return!==r.return)n=i,r=s;else{for(var o=!1,l=i.child;l;){if(l===n){o=!0,n=i,r=s;break}if(l===r){o=!0,r=i,n=s;break}l=l.sibling}if(!o){for(l=s.child;l;){if(l===n){o=!0,n=s,r=i;break}if(l===r){o=!0,r=s,n=i;break}l=l.sibling}if(!o)throw Error(S(189))}}if(n.alternate!==r)throw Error(S(190))}if(n.tag!==3)throw Error(S(188));return n.stateNode.current===n?e:t}function uc(e){return e=eh(e),e!==null?cc(e):null}function cc(e){if(e.tag===5||e.tag===6)return e;for(e=e.child;e!==null;){var t=cc(e);if(t!==null)return t;e=e.sibling}return null}var dc=xe.unstable_scheduleCallback,ua=xe.unstable_cancelCallback,th=xe.unstable_shouldYield,nh=xe.unstable_requestPaint,J=xe.unstable_now,rh=xe.unstable_getCurrentPriorityLevel,ll=xe.unstable_ImmediatePriority,fc=xe.unstable_UserBlockingPriority,Ci=xe.unstable_NormalPriority,ih=xe.unstable_LowPriority,hc=xe.unstable_IdlePriority,Qi=null,Qe=null;function sh(e){if(Qe&&typeof Qe.onCommitFiberRoot=="function")try{Qe.onCommitFiberRoot(Qi,e,void 0,(e.current.flags&128)===128)}catch{}}var Be=Math.clz32?Math.clz32:ah,oh=Math.log,lh=Math.LN2;function ah(e){return e>>>=0,e===0?32:31-(oh(e)/lh|0)|0}var Kr=64,Gr=4194304;function er(e){switch(e&-e){case 1:return 1;case 2:return 2;case 4:return 4;case 8:return 8;case 16:return 16;case 32:return 32;case 64:case 128:case 256:case 512:case 1024:case 2048:case 4096:case 8192:case 16384:case 32768:case 65536:case 131072:case 262144:case 524288:case 1048576:case 2097152:return e&4194240;case 4194304:case 8388608:case 16777216:case 33554432:case 67108864:return e&130023424;case 134217728:return 134217728;case 268435456:return 268435456;case 536870912:return 536870912;case 1073741824:return 1073741824;default:return e}}function xi(e,t){var n=e.pendingLanes;if(n===0)return 0;var r=0,i=e.suspendedLanes,s=e.pingedLanes,o=n&268435455;if(o!==0){var l=o&~i;l!==0?r=er(l):(s&=o,s!==0&&(r=er(s)))}else o=n&~i,o!==0?r=er(o):s!==0&&(r=er(s));if(r===0)return 0;if(t!==0&&t!==r&&!(t&i)&&(i=r&-r,s=t&-t,i>=s||i===16&&(s&4194240)!==0))return t;if(r&4&&(r|=n&16),t=e.entangledLanes,t!==0)for(e=e.entanglements,t&=r;0<t;)n=31-Be(t),i=1<<n,r|=e[n],t&=~i;return r}function uh(e,t){switch(e){case 1:case 2:case 4:return t+250;case 8:case 16:case 32:case 64:case 128:case 256:case 512:case 1024:case 2048:case 4096:case 8192:case 16384:case 32768:case 65536:case 131072:case 262144:case 524288:case 1048576:case 2097152:return t+5e3;case 4194304:case 8388608:case 16777216:case 33554432:case 67108864:return-1;case 134217728:case 268435456:case 536870912:case 1073741824:return-1;default:return-1}}function ch(e,t){for(var n=e.suspendedLanes,r=e.pingedLanes,i=e.expirationTimes,s=e.pendingLanes;0<s;){var o=31-Be(s),l=1<<o,a=i[o];a===-1?(!(l&n)||l&r)&&(i[o]=uh(l,t)):a<=t&&(e.expiredLanes|=l),s&=~l}}function fo(e){return e=e.pendingLanes&-1073741825,e!==0?e:e&1073741824?1073741824:0}function pc(){var e=Kr;return Kr<<=1,!(Kr&4194240)&&(Kr=64),e}function _s(e){for(var t=[],n=0;31>n;n++)t.push(e);return t}function Ar(e,t,n){e.pendingLanes|=t,t!==536870912&&(e.suspendedLanes=0,e.pingedLanes=0),e=e.eventTimes,t=31-Be(t),e[t]=n}function dh(e,t){var n=e.pendingLanes&~t;e.pendingLanes=t,e.suspendedLanes=0,e.pingedLanes=0,e.expiredLanes&=t,e.mutableReadLanes&=t,e.entangledLanes&=t,t=e.entanglements;var r=e.eventTimes;for(e=e.expirationTimes;0<n;){var i=31-Be(n),s=1<<i;t[i]=0,r[i]=-1,e[i]=-1,n&=~s}}function al(e,t){var n=e.entangledLanes|=t;for(e=e.entanglements;n;){var r=31-Be(n),i=1<<r;i&t|e[r]&t&&(e[r]|=t),n&=~i}}var U=0;function vc(e){return e&=-e,1<e?4<e?e&268435455?16:536870912:4:1}var mc,ul,gc,yc,wc,ho=!1,Qr=[],St=null,kt=null,Et=null,gr=new Map,yr=new Map,vt=[],fh="mousedown mouseup touchcancel touchend touchstart auxclick dblclick pointercancel pointerdown pointerup dragend dragstart drop compositionend compositionstart keydown keypress keyup input textInput copy cut paste click change contextmenu reset submit".split(" ");function ca(e,t){switch(e){case"focusin":case"focusout":St=null;break;case"dragenter":case"dragleave":kt=null;break;case"mouseover":case"mouseout":Et=null;break;case"pointerover":case"pointerout":gr.delete(t.pointerId);break;case"gotpointercapture":case"lostpointercapture":yr.delete(t.pointerId)}}function Wn(e,t,n,r,i,s){return e===null||e.nativeEvent!==s?(e={blockedOn:t,domEventName:n,eventSystemFlags:r,nativeEvent:s,targetContainers:[i]},t!==null&&(t=Dr(t),t!==null&&ul(t)),e):(e.eventSystemFlags|=r,t=e.targetContainers,i!==null&&t.indexOf(i)===-1&&t.push(i),e)}function hh(e,t,n,r,i){switch(t){case"focusin":return St=Wn(St,e,t,n,r,i),!0;case"dragenter":return kt=Wn(kt,e,t,n,r,i),!0;case"mouseover":return Et=Wn(Et,e,t,n,r,i),!0;case"pointerover":var s=i.pointerId;return gr.set(s,Wn(gr.get(s)||null,e,t,n,r,i)),!0;case"gotpointercapture":return s=i.pointerId,yr.set(s,Wn(yr.get(s)||null,e,t,n,r,i)),!0}return!1}function _c(e){var t=Bt(e.target);if(t!==null){var n=en(t);if(n!==null){if(t=n.tag,t===13){if(t=ac(n),t!==null){e.blockedOn=t,wc(e.priority,function(){gc(n)});return}}else if(t===3&&n.stateNode.current.memoizedState.isDehydrated){e.blockedOn=n.tag===3?n.stateNode.containerInfo:null;return}}}e.blockedOn=null}function ci(e){if(e.blockedOn!==null)return!1;for(var t=e.targetContainers;0<t.length;){var n=po(e.domEventName,e.eventSystemFlags,t[0],e.nativeEvent);if(n===null){n=e.nativeEvent;var r=new n.constructor(n.type,n);lo=r,n.target.dispatchEvent(r),lo=null}else return t=Dr(n),t!==null&&ul(t),e.blockedOn=n,!1;t.shift()}return!0}function da(e,t,n){ci(e)&&n.delete(t)}function ph(){ho=!1,St!==null&&ci(St)&&(St=null),kt!==null&&ci(kt)&&(kt=null),Et!==null&&ci(Et)&&(Et=null),gr.forEach(da),yr.forEach(da)}function Kn(e,t){e.blockedOn===t&&(e.blockedOn=null,ho||(ho=!0,xe.unstable_scheduleCallback(xe.unstable_NormalPriority,ph)))}function wr(e){function t(i){return Kn(i,e)}if(0<Qr.length){Kn(Qr[0],e);for(var n=1;n<Qr.length;n++){var r=Qr[n];r.blockedOn===e&&(r.blockedOn=null)}}for(St!==null&&Kn(St,e),kt!==null&&Kn(kt,e),Et!==null&&Kn(Et,e),gr.forEach(t),yr.forEach(t),n=0;n<vt.length;n++)r=vt[n],r.blockedOn===e&&(r.blockedOn=null);for(;0<vt.length&&(n=vt[0],n.blockedOn===null);)_c(n),n.blockedOn===null&&vt.shift()}var En=ut.ReactCurrentBatchConfig,Pi=!0;function vh(e,t,n,r){var i=U,s=En.transition;En.transition=null;try{U=1,cl(e,t,n,r)}finally{U=i,En.transition=s}}function mh(e,t,n,r){var i=U,s=En.transition;En.transition=null;try{U=4,cl(e,t,n,r)}finally{U=i,En.transition=s}}function cl(e,t,n,r){if(Pi){var i=po(e,t,n,r);if(i===null)js(e,t,r,Ti,n),ca(e,r);else if(hh(i,e,t,n,r))r.stopPropagation();else if(ca(e,r),t&4&&-1<fh.indexOf(e)){for(;i!==null;){var s=Dr(i);if(s!==null&&mc(s),s=po(e,t,n,r),s===null&&js(e,t,r,Ti,n),s===i)break;i=s}i!==null&&r.stopPropagation()}else js(e,t,r,null,n)}}var Ti=null;function po(e,t,n,r){if(Ti=null,e=ol(r),e=Bt(e),e!==null)if(t=en(e),t===null)e=null;else if(n=t.tag,n===13){if(e=ac(t),e!==null)return e;e=null}else if(n===3){if(t.stateNode.current.memoizedState.isDehydrated)return t.tag===3?t.stateNode.containerInfo:null;e=null}else t!==e&&(e=null);return Ti=e,null}function Sc(e){switch(e){case"cancel":case"click":case"close":case"contextmenu":case"copy":case"cut":case"auxclick":case"dblclick":case"dragend":case"dragstart":case"drop":case"focusin":case"focusout":case"input":case"invalid":case"keydown":case"keypress":case"keyup":case"mousedown":case"mouseup":case"paste":case"pause":case"play":case"pointercancel":case"pointerdown":case"pointerup":case"ratechange":case"reset":case"resize":case"seeked":case"submit":case"touchcancel":case"touchend":case"touchstart":case"volumechange":case"change":case"selectionchange":case"textInput":case"compositionstart":case"compositionend":case"compositionupdate":case"beforeblur":case"afterblur":case"beforeinput":case"blur":case"fullscreenchange":case"focus":case"hashchange":case"popstate":case"select":case"selectstart":return 1;case"drag":case"dragenter":case"dragexit":case"dragleave":case"dragover":case"mousemove":case"mouseout":case"mouseover":case"pointermove":case"pointerout":case"pointerover":case"scroll":case"toggle":case"touchmove":case"wheel":case"mouseenter":case"mouseleave":case"pointerenter":case"pointerleave":return 4;case"message":switch(rh()){case ll:return 1;case fc:return 4;case Ci:case ih:return 16;case hc:return 536870912;default:return 16}default:return 16}}var yt=null,dl=null,di=null;function kc(){if(di)return di;var e,t=dl,n=t.length,r,i="value"in yt?yt.value:yt.textContent,s=i.length;for(e=0;e<n&&t[e]===i[e];e++);var o=n-e;for(r=1;r<=o&&t[n-r]===i[s-r];r++);return di=i.slice(e,1<r?1-r:void 0)}function fi(e){var t=e.keyCode;return"charCode"in e?(e=e.charCode,e===0&&t===13&&(e=13)):e=t,e===10&&(e=13),32<=e||e===13?e:0}function Jr(){return!0}function fa(){return!1}function Te(e){function t(n,r,i,s,o){this._reactName=n,this._targetInst=i,this.type=r,this.nativeEvent=s,this.target=o,this.currentTarget=null;for(var l in e)e.hasOwnProperty(l)&&(n=e[l],this[l]=n?n(s):s[l]);return this.isDefaultPrevented=(s.defaultPrevented!=null?s.defaultPrevented:s.returnValue===!1)?Jr:fa,this.isPropagationStopped=fa,this}return K(t.prototype,{preventDefault:function(){this.defaultPrevented=!0;var n=this.nativeEvent;n&&(n.preventDefault?n.preventDefault():typeof n.returnValue!="unknown"&&(n.returnValue=!1),this.isDefaultPrevented=Jr)},stopPropagation:function(){var n=this.nativeEvent;n&&(n.stopPropagation?n.stopPropagation():typeof n.cancelBubble!="unknown"&&(n.cancelBubble=!0),this.isPropagationStopped=Jr)},persist:function(){},isPersistent:Jr}),t}var Dn={eventPhase:0,bubbles:0,cancelable:0,timeStamp:function(e){return e.timeStamp||Date.now()},defaultPrevented:0,isTrusted:0},fl=Te(Dn),Ur=K({},Dn,{view:0,detail:0}),gh=Te(Ur),Ss,ks,Gn,Ji=K({},Ur,{screenX:0,screenY:0,clientX:0,clientY:0,pageX:0,pageY:0,ctrlKey:0,shiftKey:0,altKey:0,metaKey:0,getModifierState:hl,button:0,buttons:0,relatedTarget:function(e){return e.relatedTarget===void 0?e.fromElement===e.srcElement?e.toElement:e.fromElement:e.relatedTarget},movementX:function(e){return"movementX"in e?e.movementX:(e!==Gn&&(Gn&&e.type==="mousemove"?(Ss=e.screenX-Gn.screenX,ks=e.screenY-Gn.screenY):ks=Ss=0,Gn=e),Ss)},movementY:function(e){return"movementY"in e?e.movementY:ks}}),ha=Te(Ji),yh=K({},Ji,{dataTransfer:0}),wh=Te(yh),_h=K({},Ur,{relatedTarget:0}),Es=Te(_h),Sh=K({},Dn,{animationName:0,elapsedTime:0,pseudoElement:0}),kh=Te(Sh),Eh=K({},Dn,{clipboardData:function(e){return"clipboardData"in e?e.clipboardData:window.clipboardData}}),Ch=Te(Eh),xh=K({},Dn,{data:0}),pa=Te(xh),Ph={Esc:"Escape",Spacebar:" ",Left:"ArrowLeft",Up:"ArrowUp",Right:"ArrowRight",Down:"ArrowDown",Del:"Delete",Win:"OS",Menu:"ContextMenu",Apps:"ContextMenu",Scroll:"ScrollLock",MozPrintableKey:"Unidentified"},Th={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"},Oh={Alt:"altKey",Control:"ctrlKey",Meta:"metaKey",Shift:"shiftKey"};function Rh(e){var t=this.nativeEvent;return t.getModifierState?t.getModifierState(e):(e=Oh[e])?!!t[e]:!1}function hl(){return Rh}var jh=K({},Ur,{key:function(e){if(e.key){var t=Ph[e.key]||e.key;if(t!=="Unidentified")return t}return e.type==="keypress"?(e=fi(e),e===13?"Enter":String.fromCharCode(e)):e.type==="keydown"||e.type==="keyup"?Th[e.keyCode]||"Unidentified":""},code:0,location:0,ctrlKey:0,shiftKey:0,altKey:0,metaKey:0,repeat:0,locale:0,getModifierState:hl,charCode:function(e){return e.type==="keypress"?fi(e):0},keyCode:function(e){return e.type==="keydown"||e.type==="keyup"?e.keyCode:0},which:function(e){return e.type==="keypress"?fi(e):e.type==="keydown"||e.type==="keyup"?e.keyCode:0}}),Lh=Te(jh),Ih=K({},Ji,{pointerId:0,width:0,height:0,pressure:0,tangentialPressure:0,tiltX:0,tiltY:0,twist:0,pointerType:0,isPrimary:0}),va=Te(Ih),$h=K({},Ur,{touches:0,targetTouches:0,changedTouches:0,altKey:0,metaKey:0,ctrlKey:0,shiftKey:0,getModifierState:hl}),Nh=Te($h),Ah=K({},Dn,{propertyName:0,elapsedTime:0,pseudoElement:0}),Uh=Te(Ah),Dh=K({},Ji,{deltaX:function(e){return"deltaX"in e?e.deltaX:"wheelDeltaX"in e?-e.wheelDeltaX:0},deltaY:function(e){return"deltaY"in e?e.deltaY:"wheelDeltaY"in e?-e.wheelDeltaY:"wheelDelta"in e?-e.wheelDelta:0},deltaZ:0,deltaMode:0}),zh=Te(Dh),Fh=[9,13,27,32],pl=st&&"CompositionEvent"in window,sr=null;st&&"documentMode"in document&&(sr=document.documentMode);var Mh=st&&"TextEvent"in window&&!sr,Ec=st&&(!pl||sr&&8<sr&&11>=sr),ma=" ",ga=!1;function Cc(e,t){switch(e){case"keyup":return Fh.indexOf(t.keyCode)!==-1;case"keydown":return t.keyCode!==229;case"keypress":case"mousedown":case"focusout":return!0;default:return!1}}function xc(e){return e=e.detail,typeof e=="object"&&"data"in e?e.data:null}var cn=!1;function bh(e,t){switch(e){case"compositionend":return xc(t);case"keypress":return t.which!==32?null:(ga=!0,ma);case"textInput":return e=t.data,e===ma&&ga?null:e;default:return null}}function Bh(e,t){if(cn)return e==="compositionend"||!pl&&Cc(e,t)?(e=kc(),di=dl=yt=null,cn=!1,e):null;switch(e){case"paste":return null;case"keypress":if(!(t.ctrlKey||t.altKey||t.metaKey)||t.ctrlKey&&t.altKey){if(t.char&&1<t.char.length)return t.char;if(t.which)return String.fromCharCode(t.which)}return null;case"compositionend":return Ec&&t.locale!=="ko"?null:t.data;default:return null}}var Vh={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 ya(e){var t=e&&e.nodeName&&e.nodeName.toLowerCase();return t==="input"?!!Vh[e.type]:t==="textarea"}function Pc(e,t,n,r){rc(r),t=Oi(t,"onChange"),0<t.length&&(n=new fl("onChange","change",null,n,r),e.push({event:n,listeners:t}))}var or=null,_r=null;function Hh(e){Dc(e,0)}function qi(e){var t=hn(e);if(qu(t))return e}function Wh(e,t){if(e==="change")return t}var Tc=!1;if(st){var Cs;if(st){var xs="oninput"in document;if(!xs){var wa=document.createElement("div");wa.setAttribute("oninput","return;"),xs=typeof wa.oninput=="function"}Cs=xs}else Cs=!1;Tc=Cs&&(!document.documentMode||9<document.documentMode)}function _a(){or&&(or.detachEvent("onpropertychange",Oc),_r=or=null)}function Oc(e){if(e.propertyName==="value"&&qi(_r)){var t=[];Pc(t,_r,e,ol(e)),lc(Hh,t)}}function Kh(e,t,n){e==="focusin"?(_a(),or=t,_r=n,or.attachEvent("onpropertychange",Oc)):e==="focusout"&&_a()}function Gh(e){if(e==="selectionchange"||e==="keyup"||e==="keydown")return qi(_r)}function Qh(e,t){if(e==="click")return qi(t)}function Jh(e,t){if(e==="input"||e==="change")return qi(t)}function qh(e,t){return e===t&&(e!==0||1/e===1/t)||e!==e&&t!==t}var He=typeof Object.is=="function"?Object.is:qh;function Sr(e,t){if(He(e,t))return!0;if(typeof e!="object"||e===null||typeof t!="object"||t===null)return!1;var n=Object.keys(e),r=Object.keys(t);if(n.length!==r.length)return!1;for(r=0;r<n.length;r++){var i=n[r];if(!Js.call(t,i)||!He(e[i],t[i]))return!1}return!0}function Sa(e){for(;e&&e.firstChild;)e=e.firstChild;return e}function ka(e,t){var n=Sa(e);e=0;for(var r;n;){if(n.nodeType===3){if(r=e+n.textContent.length,e<=t&&r>=t)return{node:n,offset:t-e};e=r}e:{for(;n;){if(n.nextSibling){n=n.nextSibling;break e}n=n.parentNode}n=void 0}n=Sa(n)}}function Rc(e,t){return e&&t?e===t?!0:e&&e.nodeType===3?!1:t&&t.nodeType===3?Rc(e,t.parentNode):"contains"in e?e.contains(t):e.compareDocumentPosition?!!(e.compareDocumentPosition(t)&16):!1:!1}function jc(){for(var e=window,t=Si();t instanceof e.HTMLIFrameElement;){try{var n=typeof t.contentWindow.location.href=="string"}catch{n=!1}if(n)e=t.contentWindow;else break;t=Si(e.document)}return t}function vl(e){var t=e&&e.nodeName&&e.nodeName.toLowerCase();return t&&(t==="input"&&(e.type==="text"||e.type==="search"||e.type==="tel"||e.type==="url"||e.type==="password")||t==="textarea"||e.contentEditable==="true")}function Yh(e){var t=jc(),n=e.focusedElem,r=e.selectionRange;if(t!==n&&n&&n.ownerDocument&&Rc(n.ownerDocument.documentElement,n)){if(r!==null&&vl(n)){if(t=r.start,e=r.end,e===void 0&&(e=t),"selectionStart"in n)n.selectionStart=t,n.selectionEnd=Math.min(e,n.value.length);else if(e=(t=n.ownerDocument||document)&&t.defaultView||window,e.getSelection){e=e.getSelection();var i=n.textContent.length,s=Math.min(r.start,i);r=r.end===void 0?s:Math.min(r.end,i),!e.extend&&s>r&&(i=r,r=s,s=i),i=ka(n,s);var o=ka(n,r);i&&o&&(e.rangeCount!==1||e.anchorNode!==i.node||e.anchorOffset!==i.offset||e.focusNode!==o.node||e.focusOffset!==o.offset)&&(t=t.createRange(),t.setStart(i.node,i.offset),e.removeAllRanges(),s>r?(e.addRange(t),e.extend(o.node,o.offset)):(t.setEnd(o.node,o.offset),e.addRange(t)))}}for(t=[],e=n;e=e.parentNode;)e.nodeType===1&&t.push({element:e,left:e.scrollLeft,top:e.scrollTop});for(typeof n.focus=="function"&&n.focus(),n=0;n<t.length;n++)e=t[n],e.element.scrollLeft=e.left,e.element.scrollTop=e.top}}var Xh=st&&"documentMode"in document&&11>=document.documentMode,dn=null,vo=null,lr=null,mo=!1;function Ea(e,t,n){var r=n.window===n?n.document:n.nodeType===9?n:n.ownerDocument;mo||dn==null||dn!==Si(r)||(r=dn,"selectionStart"in r&&vl(r)?r={start:r.selectionStart,end:r.selectionEnd}:(r=(r.ownerDocument&&r.ownerDocument.defaultView||window).getSelection(),r={anchorNode:r.anchorNode,anchorOffset:r.anchorOffset,focusNode:r.focusNode,focusOffset:r.focusOffset}),lr&&Sr(lr,r)||(lr=r,r=Oi(vo,"onSelect"),0<r.length&&(t=new fl("onSelect","select",null,t,n),e.push({event:t,listeners:r}),t.target=dn)))}function qr(e,t){var n={};return n[e.toLowerCase()]=t.toLowerCase(),n["Webkit"+e]="webkit"+t,n["Moz"+e]="moz"+t,n}var fn={animationend:qr("Animation","AnimationEnd"),animationiteration:qr("Animation","AnimationIteration"),animationstart:qr("Animation","AnimationStart"),transitionend:qr("Transition","TransitionEnd")},Ps={},Lc={};st&&(Lc=document.createElement("div").style,"AnimationEvent"in window||(delete fn.animationend.animation,delete fn.animationiteration.animation,delete fn.animationstart.animation),"TransitionEvent"in window||delete fn.transitionend.transition);function Yi(e){if(Ps[e])return Ps[e];if(!fn[e])return e;var t=fn[e],n;for(n in t)if(t.hasOwnProperty(n)&&n in Lc)return Ps[e]=t[n];return e}var Ic=Yi("animationend"),$c=Yi("animationiteration"),Nc=Yi("animationstart"),Ac=Yi("transitionend"),Uc=new Map,Ca="abort auxClick cancel canPlay canPlayThrough click close contextMenu copy cut drag dragEnd dragEnter dragExit dragLeave dragOver dragStart drop durationChange emptied encrypted ended error gotPointerCapture input invalid keyDown keyPress keyUp load loadedData loadedMetadata loadStart lostPointerCapture mouseDown mouseMove mouseOut mouseOver mouseUp paste pause play playing pointerCancel pointerDown pointerMove pointerOut pointerOver pointerUp progress rateChange reset resize seeked seeking stalled submit suspend timeUpdate touchCancel touchEnd touchStart volumeChange scroll toggle touchMove waiting wheel".split(" ");function Lt(e,t){Uc.set(e,t),Zt(t,[e])}for(var Ts=0;Ts<Ca.length;Ts++){var Os=Ca[Ts],Zh=Os.toLowerCase(),ep=Os[0].toUpperCase()+Os.slice(1);Lt(Zh,"on"+ep)}Lt(Ic,"onAnimationEnd");Lt($c,"onAnimationIteration");Lt(Nc,"onAnimationStart");Lt("dblclick","onDoubleClick");Lt("focusin","onFocus");Lt("focusout","onBlur");Lt(Ac,"onTransitionEnd");Tn("onMouseEnter",["mouseout","mouseover"]);Tn("onMouseLeave",["mouseout","mouseover"]);Tn("onPointerEnter",["pointerout","pointerover"]);Tn("onPointerLeave",["pointerout","pointerover"]);Zt("onChange","change click focusin focusout input keydown keyup selectionchange".split(" "));Zt("onSelect","focusout contextmenu dragend focusin keydown keyup mousedown mouseup selectionchange".split(" "));Zt("onBeforeInput",["compositionend","keypress","textInput","paste"]);Zt("onCompositionEnd","compositionend focusout keydown keypress keyup mousedown".split(" "));Zt("onCompositionStart","compositionstart focusout keydown keypress keyup mousedown".split(" "));Zt("onCompositionUpdate","compositionupdate focusout keydown keypress keyup mousedown".split(" "));var tr="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(" "),tp=new Set("cancel close invalid load scroll toggle".split(" ").concat(tr));function xa(e,t,n){var r=e.type||"unknown-event";e.currentTarget=n,Zf(r,t,void 0,e),e.currentTarget=null}function Dc(e,t){t=(t&4)!==0;for(var n=0;n<e.length;n++){var r=e[n],i=r.event;r=r.listeners;e:{var s=void 0;if(t)for(var o=r.length-1;0<=o;o--){var l=r[o],a=l.instance,u=l.currentTarget;if(l=l.listener,a!==s&&i.isPropagationStopped())break e;xa(i,l,u),s=a}else for(o=0;o<r.length;o++){if(l=r[o],a=l.instance,u=l.currentTarget,l=l.listener,a!==s&&i.isPropagationStopped())break e;xa(i,l,u),s=a}}}if(Ei)throw e=co,Ei=!1,co=null,e}function b(e,t){var n=t[So];n===void 0&&(n=t[So]=new Set);var r=e+"__bubble";n.has(r)||(zc(t,e,2,!1),n.add(r))}function Rs(e,t,n){var r=0;t&&(r|=4),zc(n,e,r,t)}var Yr="_reactListening"+Math.random().toString(36).slice(2);function kr(e){if(!e[Yr]){e[Yr]=!0,Wu.forEach(function(n){n!=="selectionchange"&&(tp.has(n)||Rs(n,!1,e),Rs(n,!0,e))});var t=e.nodeType===9?e:e.ownerDocument;t===null||t[Yr]||(t[Yr]=!0,Rs("selectionchange",!1,t))}}function zc(e,t,n,r){switch(Sc(t)){case 1:var i=vh;break;case 4:i=mh;break;default:i=cl}n=i.bind(null,t,n,e),i=void 0,!uo||t!=="touchstart"&&t!=="touchmove"&&t!=="wheel"||(i=!0),r?i!==void 0?e.addEventListener(t,n,{capture:!0,passive:i}):e.addEventListener(t,n,!0):i!==void 0?e.addEventListener(t,n,{passive:i}):e.addEventListener(t,n,!1)}function js(e,t,n,r,i){var s=r;if(!(t&1)&&!(t&2)&&r!==null)e:for(;;){if(r===null)return;var o=r.tag;if(o===3||o===4){var l=r.stateNode.containerInfo;if(l===i||l.nodeType===8&&l.parentNode===i)break;if(o===4)for(o=r.return;o!==null;){var a=o.tag;if((a===3||a===4)&&(a=o.stateNode.containerInfo,a===i||a.nodeType===8&&a.parentNode===i))return;o=o.return}for(;l!==null;){if(o=Bt(l),o===null)return;if(a=o.tag,a===5||a===6){r=s=o;continue e}l=l.parentNode}}r=r.return}lc(function(){var u=s,c=ol(n),d=[];e:{var h=Uc.get(e);if(h!==void 0){var m=fl,g=e;switch(e){case"keypress":if(fi(n)===0)break e;case"keydown":case"keyup":m=Lh;break;case"focusin":g="focus",m=Es;break;case"focusout":g="blur",m=Es;break;case"beforeblur":case"afterblur":m=Es;break;case"click":if(n.button===2)break e;case"auxclick":case"dblclick":case"mousedown":case"mousemove":case"mouseup":case"mouseout":case"mouseover":case"contextmenu":m=ha;break;case"drag":case"dragend":case"dragenter":case"dragexit":case"dragleave":case"dragover":case"dragstart":case"drop":m=wh;break;case"touchcancel":case"touchend":case"touchmove":case"touchstart":m=Nh;break;case Ic:case $c:case Nc:m=kh;break;case Ac:m=Uh;break;case"scroll":m=gh;break;case"wheel":m=zh;break;case"copy":case"cut":case"paste":m=Ch;break;case"gotpointercapture":case"lostpointercapture":case"pointercancel":case"pointerdown":case"pointermove":case"pointerout":case"pointerover":case"pointerup":m=va}var y=(t&4)!==0,_=!y&&e==="scroll",p=y?h!==null?h+"Capture":null:h;y=[];for(var f=u,v;f!==null;){v=f;var w=v.stateNode;if(v.tag===5&&w!==null&&(v=w,p!==null&&(w=mr(f,p),w!=null&&y.push(Er(f,w,v)))),_)break;f=f.return}0<y.length&&(h=new m(h,g,null,n,c),d.push({event:h,listeners:y}))}}if(!(t&7)){e:{if(h=e==="mouseover"||e==="pointerover",m=e==="mouseout"||e==="pointerout",h&&n!==lo&&(g=n.relatedTarget||n.fromElement)&&(Bt(g)||g[ot]))break e;if((m||h)&&(h=c.window===c?c:(h=c.ownerDocument)?h.defaultView||h.parentWindow:window,m?(g=n.relatedTarget||n.toElement,m=u,g=g?Bt(g):null,g!==null&&(_=en(g),g!==_||g.tag!==5&&g.tag!==6)&&(g=null)):(m=null,g=u),m!==g)){if(y=ha,w="onMouseLeave",p="onMouseEnter",f="mouse",(e==="pointerout"||e==="pointerover")&&(y=va,w="onPointerLeave",p="onPointerEnter",f="pointer"),_=m==null?h:hn(m),v=g==null?h:hn(g),h=new y(w,f+"leave",m,n,c),h.target=_,h.relatedTarget=v,w=null,Bt(c)===u&&(y=new y(p,f+"enter",g,n,c),y.target=v,y.relatedTarget=_,w=y),_=w,m&&g)t:{for(y=m,p=g,f=0,v=y;v;v=nn(v))f++;for(v=0,w=p;w;w=nn(w))v++;for(;0<f-v;)y=nn(y),f--;for(;0<v-f;)p=nn(p),v--;for(;f--;){if(y===p||p!==null&&y===p.alternate)break t;y=nn(y),p=nn(p)}y=null}else y=null;m!==null&&Pa(d,h,m,y,!1),g!==null&&_!==null&&Pa(d,_,g,y,!0)}}e:{if(h=u?hn(u):window,m=h.nodeName&&h.nodeName.toLowerCase(),m==="select"||m==="input"&&h.type==="file")var k=Wh;else if(ya(h))if(Tc)k=Jh;else{k=Gh;var P=Kh}else(m=h.nodeName)&&m.toLowerCase()==="input"&&(h.type==="checkbox"||h.type==="radio")&&(k=Qh);if(k&&(k=k(e,u))){Pc(d,k,n,c);break e}P&&P(e,h,u),e==="focusout"&&(P=h._wrapperState)&&P.controlled&&h.type==="number"&&no(h,"number",h.value)}switch(P=u?hn(u):window,e){case"focusin":(ya(P)||P.contentEditable==="true")&&(dn=P,vo=u,lr=null);break;case"focusout":lr=vo=dn=null;break;case"mousedown":mo=!0;break;case"contextmenu":case"mouseup":case"dragend":mo=!1,Ea(d,n,c);break;case"selectionchange":if(Xh)break;case"keydown":case"keyup":Ea(d,n,c)}var T;if(pl)e:{switch(e){case"compositionstart":var O="onCompositionStart";break e;case"compositionend":O="onCompositionEnd";break e;case"compositionupdate":O="onCompositionUpdate";break e}O=void 0}else cn?Cc(e,n)&&(O="onCompositionEnd"):e==="keydown"&&n.keyCode===229&&(O="onCompositionStart");O&&(Ec&&n.locale!=="ko"&&(cn||O!=="onCompositionStart"?O==="onCompositionEnd"&&cn&&(T=kc()):(yt=c,dl="value"in yt?yt.value:yt.textContent,cn=!0)),P=Oi(u,O),0<P.length&&(O=new pa(O,e,null,n,c),d.push({event:O,listeners:P}),T?O.data=T:(T=xc(n),T!==null&&(O.data=T)))),(T=Mh?bh(e,n):Bh(e,n))&&(u=Oi(u,"onBeforeInput"),0<u.length&&(c=new pa("onBeforeInput","beforeinput",null,n,c),d.push({event:c,listeners:u}),c.data=T))}Dc(d,t)})}function Er(e,t,n){return{instance:e,listener:t,currentTarget:n}}function Oi(e,t){for(var n=t+"Capture",r=[];e!==null;){var i=e,s=i.stateNode;i.tag===5&&s!==null&&(i=s,s=mr(e,n),s!=null&&r.unshift(Er(e,s,i)),s=mr(e,t),s!=null&&r.push(Er(e,s,i))),e=e.return}return r}function nn(e){if(e===null)return null;do e=e.return;while(e&&e.tag!==5);return e||null}function Pa(e,t,n,r,i){for(var s=t._reactName,o=[];n!==null&&n!==r;){var l=n,a=l.alternate,u=l.stateNode;if(a!==null&&a===r)break;l.tag===5&&u!==null&&(l=u,i?(a=mr(n,s),a!=null&&o.unshift(Er(n,a,l))):i||(a=mr(n,s),a!=null&&o.push(Er(n,a,l)))),n=n.return}o.length!==0&&e.push({event:t,listeners:o})}var np=/\r\n?/g,rp=/\u0000|\uFFFD/g;function Ta(e){return(typeof e=="string"?e:""+e).replace(np,` +`).replace(rp,"")}function Xr(e,t,n){if(t=Ta(t),Ta(e)!==t&&n)throw Error(S(425))}function Ri(){}var go=null,yo=null;function wo(e,t){return e==="textarea"||e==="noscript"||typeof t.children=="string"||typeof t.children=="number"||typeof t.dangerouslySetInnerHTML=="object"&&t.dangerouslySetInnerHTML!==null&&t.dangerouslySetInnerHTML.__html!=null}var _o=typeof setTimeout=="function"?setTimeout:void 0,ip=typeof clearTimeout=="function"?clearTimeout:void 0,Oa=typeof Promise=="function"?Promise:void 0,sp=typeof queueMicrotask=="function"?queueMicrotask:typeof Oa<"u"?function(e){return Oa.resolve(null).then(e).catch(op)}:_o;function op(e){setTimeout(function(){throw e})}function Ls(e,t){var n=t,r=0;do{var i=n.nextSibling;if(e.removeChild(n),i&&i.nodeType===8)if(n=i.data,n==="/$"){if(r===0){e.removeChild(i),wr(t);return}r--}else n!=="$"&&n!=="$?"&&n!=="$!"||r++;n=i}while(n);wr(t)}function Ct(e){for(;e!=null;e=e.nextSibling){var t=e.nodeType;if(t===1||t===3)break;if(t===8){if(t=e.data,t==="$"||t==="$!"||t==="$?")break;if(t==="/$")return null}}return e}function Ra(e){e=e.previousSibling;for(var t=0;e;){if(e.nodeType===8){var n=e.data;if(n==="$"||n==="$!"||n==="$?"){if(t===0)return e;t--}else n==="/$"&&t++}e=e.previousSibling}return null}var zn=Math.random().toString(36).slice(2),Ge="__reactFiber$"+zn,Cr="__reactProps$"+zn,ot="__reactContainer$"+zn,So="__reactEvents$"+zn,lp="__reactListeners$"+zn,ap="__reactHandles$"+zn;function Bt(e){var t=e[Ge];if(t)return t;for(var n=e.parentNode;n;){if(t=n[ot]||n[Ge]){if(n=t.alternate,t.child!==null||n!==null&&n.child!==null)for(e=Ra(e);e!==null;){if(n=e[Ge])return n;e=Ra(e)}return t}e=n,n=e.parentNode}return null}function Dr(e){return e=e[Ge]||e[ot],!e||e.tag!==5&&e.tag!==6&&e.tag!==13&&e.tag!==3?null:e}function hn(e){if(e.tag===5||e.tag===6)return e.stateNode;throw Error(S(33))}function Xi(e){return e[Cr]||null}var ko=[],pn=-1;function It(e){return{current:e}}function B(e){0>pn||(e.current=ko[pn],ko[pn]=null,pn--)}function F(e,t){pn++,ko[pn]=e.current,e.current=t}var jt={},ce=It(jt),ye=It(!1),Qt=jt;function On(e,t){var n=e.type.contextTypes;if(!n)return jt;var r=e.stateNode;if(r&&r.__reactInternalMemoizedUnmaskedChildContext===t)return r.__reactInternalMemoizedMaskedChildContext;var i={},s;for(s in n)i[s]=t[s];return r&&(e=e.stateNode,e.__reactInternalMemoizedUnmaskedChildContext=t,e.__reactInternalMemoizedMaskedChildContext=i),i}function we(e){return e=e.childContextTypes,e!=null}function ji(){B(ye),B(ce)}function ja(e,t,n){if(ce.current!==jt)throw Error(S(168));F(ce,t),F(ye,n)}function Fc(e,t,n){var r=e.stateNode;if(t=t.childContextTypes,typeof r.getChildContext!="function")return n;r=r.getChildContext();for(var i in r)if(!(i in t))throw Error(S(108,Kf(e)||"Unknown",i));return K({},n,r)}function Li(e){return e=(e=e.stateNode)&&e.__reactInternalMemoizedMergedChildContext||jt,Qt=ce.current,F(ce,e),F(ye,ye.current),!0}function La(e,t,n){var r=e.stateNode;if(!r)throw Error(S(169));n?(e=Fc(e,t,Qt),r.__reactInternalMemoizedMergedChildContext=e,B(ye),B(ce),F(ce,e)):B(ye),F(ye,n)}var tt=null,Zi=!1,Is=!1;function Mc(e){tt===null?tt=[e]:tt.push(e)}function up(e){Zi=!0,Mc(e)}function $t(){if(!Is&&tt!==null){Is=!0;var e=0,t=U;try{var n=tt;for(U=1;e<n.length;e++){var r=n[e];do r=r(!0);while(r!==null)}tt=null,Zi=!1}catch(i){throw tt!==null&&(tt=tt.slice(e+1)),dc(ll,$t),i}finally{U=t,Is=!1}}return null}var vn=[],mn=0,Ii=null,$i=0,je=[],Le=0,Jt=null,nt=1,rt="";function zt(e,t){vn[mn++]=$i,vn[mn++]=Ii,Ii=e,$i=t}function bc(e,t,n){je[Le++]=nt,je[Le++]=rt,je[Le++]=Jt,Jt=e;var r=nt;e=rt;var i=32-Be(r)-1;r&=~(1<<i),n+=1;var s=32-Be(t)+i;if(30<s){var o=i-i%5;s=(r&(1<<o)-1).toString(32),r>>=o,i-=o,nt=1<<32-Be(t)+i|n<<i|r,rt=s+e}else nt=1<<s|n<<i|r,rt=e}function ml(e){e.return!==null&&(zt(e,1),bc(e,1,0))}function gl(e){for(;e===Ii;)Ii=vn[--mn],vn[mn]=null,$i=vn[--mn],vn[mn]=null;for(;e===Jt;)Jt=je[--Le],je[Le]=null,rt=je[--Le],je[Le]=null,nt=je[--Le],je[Le]=null}var Ce=null,Ee=null,V=!1,be=null;function Bc(e,t){var n=Ie(5,null,null,0);n.elementType="DELETED",n.stateNode=t,n.return=e,t=e.deletions,t===null?(e.deletions=[n],e.flags|=16):t.push(n)}function Ia(e,t){switch(e.tag){case 5:var n=e.type;return t=t.nodeType!==1||n.toLowerCase()!==t.nodeName.toLowerCase()?null:t,t!==null?(e.stateNode=t,Ce=e,Ee=Ct(t.firstChild),!0):!1;case 6:return t=e.pendingProps===""||t.nodeType!==3?null:t,t!==null?(e.stateNode=t,Ce=e,Ee=null,!0):!1;case 13:return t=t.nodeType!==8?null:t,t!==null?(n=Jt!==null?{id:nt,overflow:rt}:null,e.memoizedState={dehydrated:t,treeContext:n,retryLane:1073741824},n=Ie(18,null,null,0),n.stateNode=t,n.return=e,e.child=n,Ce=e,Ee=null,!0):!1;default:return!1}}function Eo(e){return(e.mode&1)!==0&&(e.flags&128)===0}function Co(e){if(V){var t=Ee;if(t){var n=t;if(!Ia(e,t)){if(Eo(e))throw Error(S(418));t=Ct(n.nextSibling);var r=Ce;t&&Ia(e,t)?Bc(r,n):(e.flags=e.flags&-4097|2,V=!1,Ce=e)}}else{if(Eo(e))throw Error(S(418));e.flags=e.flags&-4097|2,V=!1,Ce=e}}}function $a(e){for(e=e.return;e!==null&&e.tag!==5&&e.tag!==3&&e.tag!==13;)e=e.return;Ce=e}function Zr(e){if(e!==Ce)return!1;if(!V)return $a(e),V=!0,!1;var t;if((t=e.tag!==3)&&!(t=e.tag!==5)&&(t=e.type,t=t!=="head"&&t!=="body"&&!wo(e.type,e.memoizedProps)),t&&(t=Ee)){if(Eo(e))throw Vc(),Error(S(418));for(;t;)Bc(e,t),t=Ct(t.nextSibling)}if($a(e),e.tag===13){if(e=e.memoizedState,e=e!==null?e.dehydrated:null,!e)throw Error(S(317));e:{for(e=e.nextSibling,t=0;e;){if(e.nodeType===8){var n=e.data;if(n==="/$"){if(t===0){Ee=Ct(e.nextSibling);break e}t--}else n!=="$"&&n!=="$!"&&n!=="$?"||t++}e=e.nextSibling}Ee=null}}else Ee=Ce?Ct(e.stateNode.nextSibling):null;return!0}function Vc(){for(var e=Ee;e;)e=Ct(e.nextSibling)}function Rn(){Ee=Ce=null,V=!1}function yl(e){be===null?be=[e]:be.push(e)}var cp=ut.ReactCurrentBatchConfig;function Qn(e,t,n){if(e=n.ref,e!==null&&typeof e!="function"&&typeof e!="object"){if(n._owner){if(n=n._owner,n){if(n.tag!==1)throw Error(S(309));var r=n.stateNode}if(!r)throw Error(S(147,e));var i=r,s=""+e;return t!==null&&t.ref!==null&&typeof t.ref=="function"&&t.ref._stringRef===s?t.ref:(t=function(o){var l=i.refs;o===null?delete l[s]:l[s]=o},t._stringRef=s,t)}if(typeof e!="string")throw Error(S(284));if(!n._owner)throw Error(S(290,e))}return e}function ei(e,t){throw e=Object.prototype.toString.call(t),Error(S(31,e==="[object Object]"?"object with keys {"+Object.keys(t).join(", ")+"}":e))}function Na(e){var t=e._init;return t(e._payload)}function Hc(e){function t(p,f){if(e){var v=p.deletions;v===null?(p.deletions=[f],p.flags|=16):v.push(f)}}function n(p,f){if(!e)return null;for(;f!==null;)t(p,f),f=f.sibling;return null}function r(p,f){for(p=new Map;f!==null;)f.key!==null?p.set(f.key,f):p.set(f.index,f),f=f.sibling;return p}function i(p,f){return p=Ot(p,f),p.index=0,p.sibling=null,p}function s(p,f,v){return p.index=v,e?(v=p.alternate,v!==null?(v=v.index,v<f?(p.flags|=2,f):v):(p.flags|=2,f)):(p.flags|=1048576,f)}function o(p){return e&&p.alternate===null&&(p.flags|=2),p}function l(p,f,v,w){return f===null||f.tag!==6?(f=Fs(v,p.mode,w),f.return=p,f):(f=i(f,v),f.return=p,f)}function a(p,f,v,w){var k=v.type;return k===un?c(p,f,v.props.children,w,v.key):f!==null&&(f.elementType===k||typeof k=="object"&&k!==null&&k.$$typeof===ft&&Na(k)===f.type)?(w=i(f,v.props),w.ref=Qn(p,f,v),w.return=p,w):(w=wi(v.type,v.key,v.props,null,p.mode,w),w.ref=Qn(p,f,v),w.return=p,w)}function u(p,f,v,w){return f===null||f.tag!==4||f.stateNode.containerInfo!==v.containerInfo||f.stateNode.implementation!==v.implementation?(f=Ms(v,p.mode,w),f.return=p,f):(f=i(f,v.children||[]),f.return=p,f)}function c(p,f,v,w,k){return f===null||f.tag!==7?(f=Kt(v,p.mode,w,k),f.return=p,f):(f=i(f,v),f.return=p,f)}function d(p,f,v){if(typeof f=="string"&&f!==""||typeof f=="number")return f=Fs(""+f,p.mode,v),f.return=p,f;if(typeof f=="object"&&f!==null){switch(f.$$typeof){case Vr:return v=wi(f.type,f.key,f.props,null,p.mode,v),v.ref=Qn(p,null,f),v.return=p,v;case an:return f=Ms(f,p.mode,v),f.return=p,f;case ft:var w=f._init;return d(p,w(f._payload),v)}if(Zn(f)||Vn(f))return f=Kt(f,p.mode,v,null),f.return=p,f;ei(p,f)}return null}function h(p,f,v,w){var k=f!==null?f.key:null;if(typeof v=="string"&&v!==""||typeof v=="number")return k!==null?null:l(p,f,""+v,w);if(typeof v=="object"&&v!==null){switch(v.$$typeof){case Vr:return v.key===k?a(p,f,v,w):null;case an:return v.key===k?u(p,f,v,w):null;case ft:return k=v._init,h(p,f,k(v._payload),w)}if(Zn(v)||Vn(v))return k!==null?null:c(p,f,v,w,null);ei(p,v)}return null}function m(p,f,v,w,k){if(typeof w=="string"&&w!==""||typeof w=="number")return p=p.get(v)||null,l(f,p,""+w,k);if(typeof w=="object"&&w!==null){switch(w.$$typeof){case Vr:return p=p.get(w.key===null?v:w.key)||null,a(f,p,w,k);case an:return p=p.get(w.key===null?v:w.key)||null,u(f,p,w,k);case ft:var P=w._init;return m(p,f,v,P(w._payload),k)}if(Zn(w)||Vn(w))return p=p.get(v)||null,c(f,p,w,k,null);ei(f,w)}return null}function g(p,f,v,w){for(var k=null,P=null,T=f,O=f=0,M=null;T!==null&&O<v.length;O++){T.index>O?(M=T,T=null):M=T.sibling;var j=h(p,T,v[O],w);if(j===null){T===null&&(T=M);break}e&&T&&j.alternate===null&&t(p,T),f=s(j,f,O),P===null?k=j:P.sibling=j,P=j,T=M}if(O===v.length)return n(p,T),V&&zt(p,O),k;if(T===null){for(;O<v.length;O++)T=d(p,v[O],w),T!==null&&(f=s(T,f,O),P===null?k=T:P.sibling=T,P=T);return V&&zt(p,O),k}for(T=r(p,T);O<v.length;O++)M=m(T,p,O,v[O],w),M!==null&&(e&&M.alternate!==null&&T.delete(M.key===null?O:M.key),f=s(M,f,O),P===null?k=M:P.sibling=M,P=M);return e&&T.forEach(function(de){return t(p,de)}),V&&zt(p,O),k}function y(p,f,v,w){var k=Vn(v);if(typeof k!="function")throw Error(S(150));if(v=k.call(v),v==null)throw Error(S(151));for(var P=k=null,T=f,O=f=0,M=null,j=v.next();T!==null&&!j.done;O++,j=v.next()){T.index>O?(M=T,T=null):M=T.sibling;var de=h(p,T,j.value,w);if(de===null){T===null&&(T=M);break}e&&T&&de.alternate===null&&t(p,T),f=s(de,f,O),P===null?k=de:P.sibling=de,P=de,T=M}if(j.done)return n(p,T),V&&zt(p,O),k;if(T===null){for(;!j.done;O++,j=v.next())j=d(p,j.value,w),j!==null&&(f=s(j,f,O),P===null?k=j:P.sibling=j,P=j);return V&&zt(p,O),k}for(T=r(p,T);!j.done;O++,j=v.next())j=m(T,p,O,j.value,w),j!==null&&(e&&j.alternate!==null&&T.delete(j.key===null?O:j.key),f=s(j,f,O),P===null?k=j:P.sibling=j,P=j);return e&&T.forEach(function(qe){return t(p,qe)}),V&&zt(p,O),k}function _(p,f,v,w){if(typeof v=="object"&&v!==null&&v.type===un&&v.key===null&&(v=v.props.children),typeof v=="object"&&v!==null){switch(v.$$typeof){case Vr:e:{for(var k=v.key,P=f;P!==null;){if(P.key===k){if(k=v.type,k===un){if(P.tag===7){n(p,P.sibling),f=i(P,v.props.children),f.return=p,p=f;break e}}else if(P.elementType===k||typeof k=="object"&&k!==null&&k.$$typeof===ft&&Na(k)===P.type){n(p,P.sibling),f=i(P,v.props),f.ref=Qn(p,P,v),f.return=p,p=f;break e}n(p,P);break}else t(p,P);P=P.sibling}v.type===un?(f=Kt(v.props.children,p.mode,w,v.key),f.return=p,p=f):(w=wi(v.type,v.key,v.props,null,p.mode,w),w.ref=Qn(p,f,v),w.return=p,p=w)}return o(p);case an:e:{for(P=v.key;f!==null;){if(f.key===P)if(f.tag===4&&f.stateNode.containerInfo===v.containerInfo&&f.stateNode.implementation===v.implementation){n(p,f.sibling),f=i(f,v.children||[]),f.return=p,p=f;break e}else{n(p,f);break}else t(p,f);f=f.sibling}f=Ms(v,p.mode,w),f.return=p,p=f}return o(p);case ft:return P=v._init,_(p,f,P(v._payload),w)}if(Zn(v))return g(p,f,v,w);if(Vn(v))return y(p,f,v,w);ei(p,v)}return typeof v=="string"&&v!==""||typeof v=="number"?(v=""+v,f!==null&&f.tag===6?(n(p,f.sibling),f=i(f,v),f.return=p,p=f):(n(p,f),f=Fs(v,p.mode,w),f.return=p,p=f),o(p)):n(p,f)}return _}var jn=Hc(!0),Wc=Hc(!1),Ni=It(null),Ai=null,gn=null,wl=null;function _l(){wl=gn=Ai=null}function Sl(e){var t=Ni.current;B(Ni),e._currentValue=t}function xo(e,t,n){for(;e!==null;){var r=e.alternate;if((e.childLanes&t)!==t?(e.childLanes|=t,r!==null&&(r.childLanes|=t)):r!==null&&(r.childLanes&t)!==t&&(r.childLanes|=t),e===n)break;e=e.return}}function Cn(e,t){Ai=e,wl=gn=null,e=e.dependencies,e!==null&&e.firstContext!==null&&(e.lanes&t&&(ge=!0),e.firstContext=null)}function Ne(e){var t=e._currentValue;if(wl!==e)if(e={context:e,memoizedValue:t,next:null},gn===null){if(Ai===null)throw Error(S(308));gn=e,Ai.dependencies={lanes:0,firstContext:e}}else gn=gn.next=e;return t}var Vt=null;function kl(e){Vt===null?Vt=[e]:Vt.push(e)}function Kc(e,t,n,r){var i=t.interleaved;return i===null?(n.next=n,kl(t)):(n.next=i.next,i.next=n),t.interleaved=n,lt(e,r)}function lt(e,t){e.lanes|=t;var n=e.alternate;for(n!==null&&(n.lanes|=t),n=e,e=e.return;e!==null;)e.childLanes|=t,n=e.alternate,n!==null&&(n.childLanes|=t),n=e,e=e.return;return n.tag===3?n.stateNode:null}var ht=!1;function El(e){e.updateQueue={baseState:e.memoizedState,firstBaseUpdate:null,lastBaseUpdate:null,shared:{pending:null,interleaved:null,lanes:0},effects:null}}function Gc(e,t){e=e.updateQueue,t.updateQueue===e&&(t.updateQueue={baseState:e.baseState,firstBaseUpdate:e.firstBaseUpdate,lastBaseUpdate:e.lastBaseUpdate,shared:e.shared,effects:e.effects})}function it(e,t){return{eventTime:e,lane:t,tag:0,payload:null,callback:null,next:null}}function xt(e,t,n){var r=e.updateQueue;if(r===null)return null;if(r=r.shared,A&2){var i=r.pending;return i===null?t.next=t:(t.next=i.next,i.next=t),r.pending=t,lt(e,n)}return i=r.interleaved,i===null?(t.next=t,kl(r)):(t.next=i.next,i.next=t),r.interleaved=t,lt(e,n)}function hi(e,t,n){if(t=t.updateQueue,t!==null&&(t=t.shared,(n&4194240)!==0)){var r=t.lanes;r&=e.pendingLanes,n|=r,t.lanes=n,al(e,n)}}function Aa(e,t){var n=e.updateQueue,r=e.alternate;if(r!==null&&(r=r.updateQueue,n===r)){var i=null,s=null;if(n=n.firstBaseUpdate,n!==null){do{var o={eventTime:n.eventTime,lane:n.lane,tag:n.tag,payload:n.payload,callback:n.callback,next:null};s===null?i=s=o:s=s.next=o,n=n.next}while(n!==null);s===null?i=s=t:s=s.next=t}else i=s=t;n={baseState:r.baseState,firstBaseUpdate:i,lastBaseUpdate:s,shared:r.shared,effects:r.effects},e.updateQueue=n;return}e=n.lastBaseUpdate,e===null?n.firstBaseUpdate=t:e.next=t,n.lastBaseUpdate=t}function Ui(e,t,n,r){var i=e.updateQueue;ht=!1;var s=i.firstBaseUpdate,o=i.lastBaseUpdate,l=i.shared.pending;if(l!==null){i.shared.pending=null;var a=l,u=a.next;a.next=null,o===null?s=u:o.next=u,o=a;var c=e.alternate;c!==null&&(c=c.updateQueue,l=c.lastBaseUpdate,l!==o&&(l===null?c.firstBaseUpdate=u:l.next=u,c.lastBaseUpdate=a))}if(s!==null){var d=i.baseState;o=0,c=u=a=null,l=s;do{var h=l.lane,m=l.eventTime;if((r&h)===h){c!==null&&(c=c.next={eventTime:m,lane:0,tag:l.tag,payload:l.payload,callback:l.callback,next:null});e:{var g=e,y=l;switch(h=t,m=n,y.tag){case 1:if(g=y.payload,typeof g=="function"){d=g.call(m,d,h);break e}d=g;break e;case 3:g.flags=g.flags&-65537|128;case 0:if(g=y.payload,h=typeof g=="function"?g.call(m,d,h):g,h==null)break e;d=K({},d,h);break e;case 2:ht=!0}}l.callback!==null&&l.lane!==0&&(e.flags|=64,h=i.effects,h===null?i.effects=[l]:h.push(l))}else m={eventTime:m,lane:h,tag:l.tag,payload:l.payload,callback:l.callback,next:null},c===null?(u=c=m,a=d):c=c.next=m,o|=h;if(l=l.next,l===null){if(l=i.shared.pending,l===null)break;h=l,l=h.next,h.next=null,i.lastBaseUpdate=h,i.shared.pending=null}}while(!0);if(c===null&&(a=d),i.baseState=a,i.firstBaseUpdate=u,i.lastBaseUpdate=c,t=i.shared.interleaved,t!==null){i=t;do o|=i.lane,i=i.next;while(i!==t)}else s===null&&(i.shared.lanes=0);Yt|=o,e.lanes=o,e.memoizedState=d}}function Ua(e,t,n){if(e=t.effects,t.effects=null,e!==null)for(t=0;t<e.length;t++){var r=e[t],i=r.callback;if(i!==null){if(r.callback=null,r=n,typeof i!="function")throw Error(S(191,i));i.call(r)}}}var zr={},Je=It(zr),xr=It(zr),Pr=It(zr);function Ht(e){if(e===zr)throw Error(S(174));return e}function Cl(e,t){switch(F(Pr,t),F(xr,e),F(Je,zr),e=t.nodeType,e){case 9:case 11:t=(t=t.documentElement)?t.namespaceURI:io(null,"");break;default:e=e===8?t.parentNode:t,t=e.namespaceURI||null,e=e.tagName,t=io(t,e)}B(Je),F(Je,t)}function Ln(){B(Je),B(xr),B(Pr)}function Qc(e){Ht(Pr.current);var t=Ht(Je.current),n=io(t,e.type);t!==n&&(F(xr,e),F(Je,n))}function xl(e){xr.current===e&&(B(Je),B(xr))}var H=It(0);function Di(e){for(var t=e;t!==null;){if(t.tag===13){var n=t.memoizedState;if(n!==null&&(n=n.dehydrated,n===null||n.data==="$?"||n.data==="$!"))return t}else if(t.tag===19&&t.memoizedProps.revealOrder!==void 0){if(t.flags&128)return t}else if(t.child!==null){t.child.return=t,t=t.child;continue}if(t===e)break;for(;t.sibling===null;){if(t.return===null||t.return===e)return null;t=t.return}t.sibling.return=t.return,t=t.sibling}return null}var $s=[];function Pl(){for(var e=0;e<$s.length;e++)$s[e]._workInProgressVersionPrimary=null;$s.length=0}var pi=ut.ReactCurrentDispatcher,Ns=ut.ReactCurrentBatchConfig,qt=0,W=null,Y=null,te=null,zi=!1,ar=!1,Tr=0,dp=0;function oe(){throw Error(S(321))}function Tl(e,t){if(t===null)return!1;for(var n=0;n<t.length&&n<e.length;n++)if(!He(e[n],t[n]))return!1;return!0}function Ol(e,t,n,r,i,s){if(qt=s,W=t,t.memoizedState=null,t.updateQueue=null,t.lanes=0,pi.current=e===null||e.memoizedState===null?vp:mp,e=n(r,i),ar){s=0;do{if(ar=!1,Tr=0,25<=s)throw Error(S(301));s+=1,te=Y=null,t.updateQueue=null,pi.current=gp,e=n(r,i)}while(ar)}if(pi.current=Fi,t=Y!==null&&Y.next!==null,qt=0,te=Y=W=null,zi=!1,t)throw Error(S(300));return e}function Rl(){var e=Tr!==0;return Tr=0,e}function Ke(){var e={memoizedState:null,baseState:null,baseQueue:null,queue:null,next:null};return te===null?W.memoizedState=te=e:te=te.next=e,te}function Ae(){if(Y===null){var e=W.alternate;e=e!==null?e.memoizedState:null}else e=Y.next;var t=te===null?W.memoizedState:te.next;if(t!==null)te=t,Y=e;else{if(e===null)throw Error(S(310));Y=e,e={memoizedState:Y.memoizedState,baseState:Y.baseState,baseQueue:Y.baseQueue,queue:Y.queue,next:null},te===null?W.memoizedState=te=e:te=te.next=e}return te}function Or(e,t){return typeof t=="function"?t(e):t}function As(e){var t=Ae(),n=t.queue;if(n===null)throw Error(S(311));n.lastRenderedReducer=e;var r=Y,i=r.baseQueue,s=n.pending;if(s!==null){if(i!==null){var o=i.next;i.next=s.next,s.next=o}r.baseQueue=i=s,n.pending=null}if(i!==null){s=i.next,r=r.baseState;var l=o=null,a=null,u=s;do{var c=u.lane;if((qt&c)===c)a!==null&&(a=a.next={lane:0,action:u.action,hasEagerState:u.hasEagerState,eagerState:u.eagerState,next:null}),r=u.hasEagerState?u.eagerState:e(r,u.action);else{var d={lane:c,action:u.action,hasEagerState:u.hasEagerState,eagerState:u.eagerState,next:null};a===null?(l=a=d,o=r):a=a.next=d,W.lanes|=c,Yt|=c}u=u.next}while(u!==null&&u!==s);a===null?o=r:a.next=l,He(r,t.memoizedState)||(ge=!0),t.memoizedState=r,t.baseState=o,t.baseQueue=a,n.lastRenderedState=r}if(e=n.interleaved,e!==null){i=e;do s=i.lane,W.lanes|=s,Yt|=s,i=i.next;while(i!==e)}else i===null&&(n.lanes=0);return[t.memoizedState,n.dispatch]}function Us(e){var t=Ae(),n=t.queue;if(n===null)throw Error(S(311));n.lastRenderedReducer=e;var r=n.dispatch,i=n.pending,s=t.memoizedState;if(i!==null){n.pending=null;var o=i=i.next;do s=e(s,o.action),o=o.next;while(o!==i);He(s,t.memoizedState)||(ge=!0),t.memoizedState=s,t.baseQueue===null&&(t.baseState=s),n.lastRenderedState=s}return[s,r]}function Jc(){}function qc(e,t){var n=W,r=Ae(),i=t(),s=!He(r.memoizedState,i);if(s&&(r.memoizedState=i,ge=!0),r=r.queue,jl(Zc.bind(null,n,r,e),[e]),r.getSnapshot!==t||s||te!==null&&te.memoizedState.tag&1){if(n.flags|=2048,Rr(9,Xc.bind(null,n,r,i,t),void 0,null),ne===null)throw Error(S(349));qt&30||Yc(n,t,i)}return i}function Yc(e,t,n){e.flags|=16384,e={getSnapshot:t,value:n},t=W.updateQueue,t===null?(t={lastEffect:null,stores:null},W.updateQueue=t,t.stores=[e]):(n=t.stores,n===null?t.stores=[e]:n.push(e))}function Xc(e,t,n,r){t.value=n,t.getSnapshot=r,ed(t)&&td(e)}function Zc(e,t,n){return n(function(){ed(t)&&td(e)})}function ed(e){var t=e.getSnapshot;e=e.value;try{var n=t();return!He(e,n)}catch{return!0}}function td(e){var t=lt(e,1);t!==null&&Ve(t,e,1,-1)}function Da(e){var t=Ke();return typeof e=="function"&&(e=e()),t.memoizedState=t.baseState=e,e={pending:null,interleaved:null,lanes:0,dispatch:null,lastRenderedReducer:Or,lastRenderedState:e},t.queue=e,e=e.dispatch=pp.bind(null,W,e),[t.memoizedState,e]}function Rr(e,t,n,r){return e={tag:e,create:t,destroy:n,deps:r,next:null},t=W.updateQueue,t===null?(t={lastEffect:null,stores:null},W.updateQueue=t,t.lastEffect=e.next=e):(n=t.lastEffect,n===null?t.lastEffect=e.next=e:(r=n.next,n.next=e,e.next=r,t.lastEffect=e)),e}function nd(){return Ae().memoizedState}function vi(e,t,n,r){var i=Ke();W.flags|=e,i.memoizedState=Rr(1|t,n,void 0,r===void 0?null:r)}function es(e,t,n,r){var i=Ae();r=r===void 0?null:r;var s=void 0;if(Y!==null){var o=Y.memoizedState;if(s=o.destroy,r!==null&&Tl(r,o.deps)){i.memoizedState=Rr(t,n,s,r);return}}W.flags|=e,i.memoizedState=Rr(1|t,n,s,r)}function za(e,t){return vi(8390656,8,e,t)}function jl(e,t){return es(2048,8,e,t)}function rd(e,t){return es(4,2,e,t)}function id(e,t){return es(4,4,e,t)}function sd(e,t){if(typeof t=="function")return e=e(),t(e),function(){t(null)};if(t!=null)return e=e(),t.current=e,function(){t.current=null}}function od(e,t,n){return n=n!=null?n.concat([e]):null,es(4,4,sd.bind(null,t,e),n)}function Ll(){}function ld(e,t){var n=Ae();t=t===void 0?null:t;var r=n.memoizedState;return r!==null&&t!==null&&Tl(t,r[1])?r[0]:(n.memoizedState=[e,t],e)}function ad(e,t){var n=Ae();t=t===void 0?null:t;var r=n.memoizedState;return r!==null&&t!==null&&Tl(t,r[1])?r[0]:(e=e(),n.memoizedState=[e,t],e)}function ud(e,t,n){return qt&21?(He(n,t)||(n=pc(),W.lanes|=n,Yt|=n,e.baseState=!0),t):(e.baseState&&(e.baseState=!1,ge=!0),e.memoizedState=n)}function fp(e,t){var n=U;U=n!==0&&4>n?n:4,e(!0);var r=Ns.transition;Ns.transition={};try{e(!1),t()}finally{U=n,Ns.transition=r}}function cd(){return Ae().memoizedState}function hp(e,t,n){var r=Tt(e);if(n={lane:r,action:n,hasEagerState:!1,eagerState:null,next:null},dd(e))fd(t,n);else if(n=Kc(e,t,n,r),n!==null){var i=he();Ve(n,e,r,i),hd(n,t,r)}}function pp(e,t,n){var r=Tt(e),i={lane:r,action:n,hasEagerState:!1,eagerState:null,next:null};if(dd(e))fd(t,i);else{var s=e.alternate;if(e.lanes===0&&(s===null||s.lanes===0)&&(s=t.lastRenderedReducer,s!==null))try{var o=t.lastRenderedState,l=s(o,n);if(i.hasEagerState=!0,i.eagerState=l,He(l,o)){var a=t.interleaved;a===null?(i.next=i,kl(t)):(i.next=a.next,a.next=i),t.interleaved=i;return}}catch{}finally{}n=Kc(e,t,i,r),n!==null&&(i=he(),Ve(n,e,r,i),hd(n,t,r))}}function dd(e){var t=e.alternate;return e===W||t!==null&&t===W}function fd(e,t){ar=zi=!0;var n=e.pending;n===null?t.next=t:(t.next=n.next,n.next=t),e.pending=t}function hd(e,t,n){if(n&4194240){var r=t.lanes;r&=e.pendingLanes,n|=r,t.lanes=n,al(e,n)}}var Fi={readContext:Ne,useCallback:oe,useContext:oe,useEffect:oe,useImperativeHandle:oe,useInsertionEffect:oe,useLayoutEffect:oe,useMemo:oe,useReducer:oe,useRef:oe,useState:oe,useDebugValue:oe,useDeferredValue:oe,useTransition:oe,useMutableSource:oe,useSyncExternalStore:oe,useId:oe,unstable_isNewReconciler:!1},vp={readContext:Ne,useCallback:function(e,t){return Ke().memoizedState=[e,t===void 0?null:t],e},useContext:Ne,useEffect:za,useImperativeHandle:function(e,t,n){return n=n!=null?n.concat([e]):null,vi(4194308,4,sd.bind(null,t,e),n)},useLayoutEffect:function(e,t){return vi(4194308,4,e,t)},useInsertionEffect:function(e,t){return vi(4,2,e,t)},useMemo:function(e,t){var n=Ke();return t=t===void 0?null:t,e=e(),n.memoizedState=[e,t],e},useReducer:function(e,t,n){var r=Ke();return t=n!==void 0?n(t):t,r.memoizedState=r.baseState=t,e={pending:null,interleaved:null,lanes:0,dispatch:null,lastRenderedReducer:e,lastRenderedState:t},r.queue=e,e=e.dispatch=hp.bind(null,W,e),[r.memoizedState,e]},useRef:function(e){var t=Ke();return e={current:e},t.memoizedState=e},useState:Da,useDebugValue:Ll,useDeferredValue:function(e){return Ke().memoizedState=e},useTransition:function(){var e=Da(!1),t=e[0];return e=fp.bind(null,e[1]),Ke().memoizedState=e,[t,e]},useMutableSource:function(){},useSyncExternalStore:function(e,t,n){var r=W,i=Ke();if(V){if(n===void 0)throw Error(S(407));n=n()}else{if(n=t(),ne===null)throw Error(S(349));qt&30||Yc(r,t,n)}i.memoizedState=n;var s={value:n,getSnapshot:t};return i.queue=s,za(Zc.bind(null,r,s,e),[e]),r.flags|=2048,Rr(9,Xc.bind(null,r,s,n,t),void 0,null),n},useId:function(){var e=Ke(),t=ne.identifierPrefix;if(V){var n=rt,r=nt;n=(r&~(1<<32-Be(r)-1)).toString(32)+n,t=":"+t+"R"+n,n=Tr++,0<n&&(t+="H"+n.toString(32)),t+=":"}else n=dp++,t=":"+t+"r"+n.toString(32)+":";return e.memoizedState=t},unstable_isNewReconciler:!1},mp={readContext:Ne,useCallback:ld,useContext:Ne,useEffect:jl,useImperativeHandle:od,useInsertionEffect:rd,useLayoutEffect:id,useMemo:ad,useReducer:As,useRef:nd,useState:function(){return As(Or)},useDebugValue:Ll,useDeferredValue:function(e){var t=Ae();return ud(t,Y.memoizedState,e)},useTransition:function(){var e=As(Or)[0],t=Ae().memoizedState;return[e,t]},useMutableSource:Jc,useSyncExternalStore:qc,useId:cd,unstable_isNewReconciler:!1},gp={readContext:Ne,useCallback:ld,useContext:Ne,useEffect:jl,useImperativeHandle:od,useInsertionEffect:rd,useLayoutEffect:id,useMemo:ad,useReducer:Us,useRef:nd,useState:function(){return Us(Or)},useDebugValue:Ll,useDeferredValue:function(e){var t=Ae();return Y===null?t.memoizedState=e:ud(t,Y.memoizedState,e)},useTransition:function(){var e=Us(Or)[0],t=Ae().memoizedState;return[e,t]},useMutableSource:Jc,useSyncExternalStore:qc,useId:cd,unstable_isNewReconciler:!1};function ze(e,t){if(e&&e.defaultProps){t=K({},t),e=e.defaultProps;for(var n in e)t[n]===void 0&&(t[n]=e[n]);return t}return t}function Po(e,t,n,r){t=e.memoizedState,n=n(r,t),n=n==null?t:K({},t,n),e.memoizedState=n,e.lanes===0&&(e.updateQueue.baseState=n)}var ts={isMounted:function(e){return(e=e._reactInternals)?en(e)===e:!1},enqueueSetState:function(e,t,n){e=e._reactInternals;var r=he(),i=Tt(e),s=it(r,i);s.payload=t,n!=null&&(s.callback=n),t=xt(e,s,i),t!==null&&(Ve(t,e,i,r),hi(t,e,i))},enqueueReplaceState:function(e,t,n){e=e._reactInternals;var r=he(),i=Tt(e),s=it(r,i);s.tag=1,s.payload=t,n!=null&&(s.callback=n),t=xt(e,s,i),t!==null&&(Ve(t,e,i,r),hi(t,e,i))},enqueueForceUpdate:function(e,t){e=e._reactInternals;var n=he(),r=Tt(e),i=it(n,r);i.tag=2,t!=null&&(i.callback=t),t=xt(e,i,r),t!==null&&(Ve(t,e,r,n),hi(t,e,r))}};function Fa(e,t,n,r,i,s,o){return e=e.stateNode,typeof e.shouldComponentUpdate=="function"?e.shouldComponentUpdate(r,s,o):t.prototype&&t.prototype.isPureReactComponent?!Sr(n,r)||!Sr(i,s):!0}function pd(e,t,n){var r=!1,i=jt,s=t.contextType;return typeof s=="object"&&s!==null?s=Ne(s):(i=we(t)?Qt:ce.current,r=t.contextTypes,s=(r=r!=null)?On(e,i):jt),t=new t(n,s),e.memoizedState=t.state!==null&&t.state!==void 0?t.state:null,t.updater=ts,e.stateNode=t,t._reactInternals=e,r&&(e=e.stateNode,e.__reactInternalMemoizedUnmaskedChildContext=i,e.__reactInternalMemoizedMaskedChildContext=s),t}function Ma(e,t,n,r){e=t.state,typeof t.componentWillReceiveProps=="function"&&t.componentWillReceiveProps(n,r),typeof t.UNSAFE_componentWillReceiveProps=="function"&&t.UNSAFE_componentWillReceiveProps(n,r),t.state!==e&&ts.enqueueReplaceState(t,t.state,null)}function To(e,t,n,r){var i=e.stateNode;i.props=n,i.state=e.memoizedState,i.refs={},El(e);var s=t.contextType;typeof s=="object"&&s!==null?i.context=Ne(s):(s=we(t)?Qt:ce.current,i.context=On(e,s)),i.state=e.memoizedState,s=t.getDerivedStateFromProps,typeof s=="function"&&(Po(e,t,s,n),i.state=e.memoizedState),typeof t.getDerivedStateFromProps=="function"||typeof i.getSnapshotBeforeUpdate=="function"||typeof i.UNSAFE_componentWillMount!="function"&&typeof i.componentWillMount!="function"||(t=i.state,typeof i.componentWillMount=="function"&&i.componentWillMount(),typeof i.UNSAFE_componentWillMount=="function"&&i.UNSAFE_componentWillMount(),t!==i.state&&ts.enqueueReplaceState(i,i.state,null),Ui(e,n,i,r),i.state=e.memoizedState),typeof i.componentDidMount=="function"&&(e.flags|=4194308)}function In(e,t){try{var n="",r=t;do n+=Wf(r),r=r.return;while(r);var i=n}catch(s){i=` +Error generating stack: `+s.message+` +`+s.stack}return{value:e,source:t,stack:i,digest:null}}function Ds(e,t,n){return{value:e,source:null,stack:n??null,digest:t??null}}function Oo(e,t){try{console.error(t.value)}catch(n){setTimeout(function(){throw n})}}var yp=typeof WeakMap=="function"?WeakMap:Map;function vd(e,t,n){n=it(-1,n),n.tag=3,n.payload={element:null};var r=t.value;return n.callback=function(){bi||(bi=!0,zo=r),Oo(e,t)},n}function md(e,t,n){n=it(-1,n),n.tag=3;var r=e.type.getDerivedStateFromError;if(typeof r=="function"){var i=t.value;n.payload=function(){return r(i)},n.callback=function(){Oo(e,t)}}var s=e.stateNode;return s!==null&&typeof s.componentDidCatch=="function"&&(n.callback=function(){Oo(e,t),typeof r!="function"&&(Pt===null?Pt=new Set([this]):Pt.add(this));var o=t.stack;this.componentDidCatch(t.value,{componentStack:o!==null?o:""})}),n}function ba(e,t,n){var r=e.pingCache;if(r===null){r=e.pingCache=new yp;var i=new Set;r.set(t,i)}else i=r.get(t),i===void 0&&(i=new Set,r.set(t,i));i.has(n)||(i.add(n),e=Ip.bind(null,e,t,n),t.then(e,e))}function Ba(e){do{var t;if((t=e.tag===13)&&(t=e.memoizedState,t=t!==null?t.dehydrated!==null:!0),t)return e;e=e.return}while(e!==null);return null}function Va(e,t,n,r,i){return e.mode&1?(e.flags|=65536,e.lanes=i,e):(e===t?e.flags|=65536:(e.flags|=128,n.flags|=131072,n.flags&=-52805,n.tag===1&&(n.alternate===null?n.tag=17:(t=it(-1,1),t.tag=2,xt(n,t,1))),n.lanes|=1),e)}var wp=ut.ReactCurrentOwner,ge=!1;function fe(e,t,n,r){t.child=e===null?Wc(t,null,n,r):jn(t,e.child,n,r)}function Ha(e,t,n,r,i){n=n.render;var s=t.ref;return Cn(t,i),r=Ol(e,t,n,r,s,i),n=Rl(),e!==null&&!ge?(t.updateQueue=e.updateQueue,t.flags&=-2053,e.lanes&=~i,at(e,t,i)):(V&&n&&ml(t),t.flags|=1,fe(e,t,r,i),t.child)}function Wa(e,t,n,r,i){if(e===null){var s=n.type;return typeof s=="function"&&!Fl(s)&&s.defaultProps===void 0&&n.compare===null&&n.defaultProps===void 0?(t.tag=15,t.type=s,gd(e,t,s,r,i)):(e=wi(n.type,null,r,t,t.mode,i),e.ref=t.ref,e.return=t,t.child=e)}if(s=e.child,!(e.lanes&i)){var o=s.memoizedProps;if(n=n.compare,n=n!==null?n:Sr,n(o,r)&&e.ref===t.ref)return at(e,t,i)}return t.flags|=1,e=Ot(s,r),e.ref=t.ref,e.return=t,t.child=e}function gd(e,t,n,r,i){if(e!==null){var s=e.memoizedProps;if(Sr(s,r)&&e.ref===t.ref)if(ge=!1,t.pendingProps=r=s,(e.lanes&i)!==0)e.flags&131072&&(ge=!0);else return t.lanes=e.lanes,at(e,t,i)}return Ro(e,t,n,r,i)}function yd(e,t,n){var r=t.pendingProps,i=r.children,s=e!==null?e.memoizedState:null;if(r.mode==="hidden")if(!(t.mode&1))t.memoizedState={baseLanes:0,cachePool:null,transitions:null},F(wn,ke),ke|=n;else{if(!(n&1073741824))return e=s!==null?s.baseLanes|n:n,t.lanes=t.childLanes=1073741824,t.memoizedState={baseLanes:e,cachePool:null,transitions:null},t.updateQueue=null,F(wn,ke),ke|=e,null;t.memoizedState={baseLanes:0,cachePool:null,transitions:null},r=s!==null?s.baseLanes:n,F(wn,ke),ke|=r}else s!==null?(r=s.baseLanes|n,t.memoizedState=null):r=n,F(wn,ke),ke|=r;return fe(e,t,i,n),t.child}function wd(e,t){var n=t.ref;(e===null&&n!==null||e!==null&&e.ref!==n)&&(t.flags|=512,t.flags|=2097152)}function Ro(e,t,n,r,i){var s=we(n)?Qt:ce.current;return s=On(t,s),Cn(t,i),n=Ol(e,t,n,r,s,i),r=Rl(),e!==null&&!ge?(t.updateQueue=e.updateQueue,t.flags&=-2053,e.lanes&=~i,at(e,t,i)):(V&&r&&ml(t),t.flags|=1,fe(e,t,n,i),t.child)}function Ka(e,t,n,r,i){if(we(n)){var s=!0;Li(t)}else s=!1;if(Cn(t,i),t.stateNode===null)mi(e,t),pd(t,n,r),To(t,n,r,i),r=!0;else if(e===null){var o=t.stateNode,l=t.memoizedProps;o.props=l;var a=o.context,u=n.contextType;typeof u=="object"&&u!==null?u=Ne(u):(u=we(n)?Qt:ce.current,u=On(t,u));var c=n.getDerivedStateFromProps,d=typeof c=="function"||typeof o.getSnapshotBeforeUpdate=="function";d||typeof o.UNSAFE_componentWillReceiveProps!="function"&&typeof o.componentWillReceiveProps!="function"||(l!==r||a!==u)&&Ma(t,o,r,u),ht=!1;var h=t.memoizedState;o.state=h,Ui(t,r,o,i),a=t.memoizedState,l!==r||h!==a||ye.current||ht?(typeof c=="function"&&(Po(t,n,c,r),a=t.memoizedState),(l=ht||Fa(t,n,l,r,h,a,u))?(d||typeof o.UNSAFE_componentWillMount!="function"&&typeof o.componentWillMount!="function"||(typeof o.componentWillMount=="function"&&o.componentWillMount(),typeof o.UNSAFE_componentWillMount=="function"&&o.UNSAFE_componentWillMount()),typeof o.componentDidMount=="function"&&(t.flags|=4194308)):(typeof o.componentDidMount=="function"&&(t.flags|=4194308),t.memoizedProps=r,t.memoizedState=a),o.props=r,o.state=a,o.context=u,r=l):(typeof o.componentDidMount=="function"&&(t.flags|=4194308),r=!1)}else{o=t.stateNode,Gc(e,t),l=t.memoizedProps,u=t.type===t.elementType?l:ze(t.type,l),o.props=u,d=t.pendingProps,h=o.context,a=n.contextType,typeof a=="object"&&a!==null?a=Ne(a):(a=we(n)?Qt:ce.current,a=On(t,a));var m=n.getDerivedStateFromProps;(c=typeof m=="function"||typeof o.getSnapshotBeforeUpdate=="function")||typeof o.UNSAFE_componentWillReceiveProps!="function"&&typeof o.componentWillReceiveProps!="function"||(l!==d||h!==a)&&Ma(t,o,r,a),ht=!1,h=t.memoizedState,o.state=h,Ui(t,r,o,i);var g=t.memoizedState;l!==d||h!==g||ye.current||ht?(typeof m=="function"&&(Po(t,n,m,r),g=t.memoizedState),(u=ht||Fa(t,n,u,r,h,g,a)||!1)?(c||typeof o.UNSAFE_componentWillUpdate!="function"&&typeof o.componentWillUpdate!="function"||(typeof o.componentWillUpdate=="function"&&o.componentWillUpdate(r,g,a),typeof o.UNSAFE_componentWillUpdate=="function"&&o.UNSAFE_componentWillUpdate(r,g,a)),typeof o.componentDidUpdate=="function"&&(t.flags|=4),typeof o.getSnapshotBeforeUpdate=="function"&&(t.flags|=1024)):(typeof o.componentDidUpdate!="function"||l===e.memoizedProps&&h===e.memoizedState||(t.flags|=4),typeof o.getSnapshotBeforeUpdate!="function"||l===e.memoizedProps&&h===e.memoizedState||(t.flags|=1024),t.memoizedProps=r,t.memoizedState=g),o.props=r,o.state=g,o.context=a,r=u):(typeof o.componentDidUpdate!="function"||l===e.memoizedProps&&h===e.memoizedState||(t.flags|=4),typeof o.getSnapshotBeforeUpdate!="function"||l===e.memoizedProps&&h===e.memoizedState||(t.flags|=1024),r=!1)}return jo(e,t,n,r,s,i)}function jo(e,t,n,r,i,s){wd(e,t);var o=(t.flags&128)!==0;if(!r&&!o)return i&&La(t,n,!1),at(e,t,s);r=t.stateNode,wp.current=t;var l=o&&typeof n.getDerivedStateFromError!="function"?null:r.render();return t.flags|=1,e!==null&&o?(t.child=jn(t,e.child,null,s),t.child=jn(t,null,l,s)):fe(e,t,l,s),t.memoizedState=r.state,i&&La(t,n,!0),t.child}function _d(e){var t=e.stateNode;t.pendingContext?ja(e,t.pendingContext,t.pendingContext!==t.context):t.context&&ja(e,t.context,!1),Cl(e,t.containerInfo)}function Ga(e,t,n,r,i){return Rn(),yl(i),t.flags|=256,fe(e,t,n,r),t.child}var Lo={dehydrated:null,treeContext:null,retryLane:0};function Io(e){return{baseLanes:e,cachePool:null,transitions:null}}function Sd(e,t,n){var r=t.pendingProps,i=H.current,s=!1,o=(t.flags&128)!==0,l;if((l=o)||(l=e!==null&&e.memoizedState===null?!1:(i&2)!==0),l?(s=!0,t.flags&=-129):(e===null||e.memoizedState!==null)&&(i|=1),F(H,i&1),e===null)return Co(t),e=t.memoizedState,e!==null&&(e=e.dehydrated,e!==null)?(t.mode&1?e.data==="$!"?t.lanes=8:t.lanes=1073741824:t.lanes=1,null):(o=r.children,e=r.fallback,s?(r=t.mode,s=t.child,o={mode:"hidden",children:o},!(r&1)&&s!==null?(s.childLanes=0,s.pendingProps=o):s=is(o,r,0,null),e=Kt(e,r,n,null),s.return=t,e.return=t,s.sibling=e,t.child=s,t.child.memoizedState=Io(n),t.memoizedState=Lo,e):Il(t,o));if(i=e.memoizedState,i!==null&&(l=i.dehydrated,l!==null))return _p(e,t,o,r,l,i,n);if(s){s=r.fallback,o=t.mode,i=e.child,l=i.sibling;var a={mode:"hidden",children:r.children};return!(o&1)&&t.child!==i?(r=t.child,r.childLanes=0,r.pendingProps=a,t.deletions=null):(r=Ot(i,a),r.subtreeFlags=i.subtreeFlags&14680064),l!==null?s=Ot(l,s):(s=Kt(s,o,n,null),s.flags|=2),s.return=t,r.return=t,r.sibling=s,t.child=r,r=s,s=t.child,o=e.child.memoizedState,o=o===null?Io(n):{baseLanes:o.baseLanes|n,cachePool:null,transitions:o.transitions},s.memoizedState=o,s.childLanes=e.childLanes&~n,t.memoizedState=Lo,r}return s=e.child,e=s.sibling,r=Ot(s,{mode:"visible",children:r.children}),!(t.mode&1)&&(r.lanes=n),r.return=t,r.sibling=null,e!==null&&(n=t.deletions,n===null?(t.deletions=[e],t.flags|=16):n.push(e)),t.child=r,t.memoizedState=null,r}function Il(e,t){return t=is({mode:"visible",children:t},e.mode,0,null),t.return=e,e.child=t}function ti(e,t,n,r){return r!==null&&yl(r),jn(t,e.child,null,n),e=Il(t,t.pendingProps.children),e.flags|=2,t.memoizedState=null,e}function _p(e,t,n,r,i,s,o){if(n)return t.flags&256?(t.flags&=-257,r=Ds(Error(S(422))),ti(e,t,o,r)):t.memoizedState!==null?(t.child=e.child,t.flags|=128,null):(s=r.fallback,i=t.mode,r=is({mode:"visible",children:r.children},i,0,null),s=Kt(s,i,o,null),s.flags|=2,r.return=t,s.return=t,r.sibling=s,t.child=r,t.mode&1&&jn(t,e.child,null,o),t.child.memoizedState=Io(o),t.memoizedState=Lo,s);if(!(t.mode&1))return ti(e,t,o,null);if(i.data==="$!"){if(r=i.nextSibling&&i.nextSibling.dataset,r)var l=r.dgst;return r=l,s=Error(S(419)),r=Ds(s,r,void 0),ti(e,t,o,r)}if(l=(o&e.childLanes)!==0,ge||l){if(r=ne,r!==null){switch(o&-o){case 4:i=2;break;case 16:i=8;break;case 64:case 128:case 256:case 512:case 1024:case 2048:case 4096:case 8192:case 16384:case 32768:case 65536:case 131072:case 262144:case 524288:case 1048576:case 2097152:case 4194304:case 8388608:case 16777216:case 33554432:case 67108864:i=32;break;case 536870912:i=268435456;break;default:i=0}i=i&(r.suspendedLanes|o)?0:i,i!==0&&i!==s.retryLane&&(s.retryLane=i,lt(e,i),Ve(r,e,i,-1))}return zl(),r=Ds(Error(S(421))),ti(e,t,o,r)}return i.data==="$?"?(t.flags|=128,t.child=e.child,t=$p.bind(null,e),i._reactRetry=t,null):(e=s.treeContext,Ee=Ct(i.nextSibling),Ce=t,V=!0,be=null,e!==null&&(je[Le++]=nt,je[Le++]=rt,je[Le++]=Jt,nt=e.id,rt=e.overflow,Jt=t),t=Il(t,r.children),t.flags|=4096,t)}function Qa(e,t,n){e.lanes|=t;var r=e.alternate;r!==null&&(r.lanes|=t),xo(e.return,t,n)}function zs(e,t,n,r,i){var s=e.memoizedState;s===null?e.memoizedState={isBackwards:t,rendering:null,renderingStartTime:0,last:r,tail:n,tailMode:i}:(s.isBackwards=t,s.rendering=null,s.renderingStartTime=0,s.last=r,s.tail=n,s.tailMode=i)}function kd(e,t,n){var r=t.pendingProps,i=r.revealOrder,s=r.tail;if(fe(e,t,r.children,n),r=H.current,r&2)r=r&1|2,t.flags|=128;else{if(e!==null&&e.flags&128)e:for(e=t.child;e!==null;){if(e.tag===13)e.memoizedState!==null&&Qa(e,n,t);else if(e.tag===19)Qa(e,n,t);else if(e.child!==null){e.child.return=e,e=e.child;continue}if(e===t)break e;for(;e.sibling===null;){if(e.return===null||e.return===t)break e;e=e.return}e.sibling.return=e.return,e=e.sibling}r&=1}if(F(H,r),!(t.mode&1))t.memoizedState=null;else switch(i){case"forwards":for(n=t.child,i=null;n!==null;)e=n.alternate,e!==null&&Di(e)===null&&(i=n),n=n.sibling;n=i,n===null?(i=t.child,t.child=null):(i=n.sibling,n.sibling=null),zs(t,!1,i,n,s);break;case"backwards":for(n=null,i=t.child,t.child=null;i!==null;){if(e=i.alternate,e!==null&&Di(e)===null){t.child=i;break}e=i.sibling,i.sibling=n,n=i,i=e}zs(t,!0,n,null,s);break;case"together":zs(t,!1,null,null,void 0);break;default:t.memoizedState=null}return t.child}function mi(e,t){!(t.mode&1)&&e!==null&&(e.alternate=null,t.alternate=null,t.flags|=2)}function at(e,t,n){if(e!==null&&(t.dependencies=e.dependencies),Yt|=t.lanes,!(n&t.childLanes))return null;if(e!==null&&t.child!==e.child)throw Error(S(153));if(t.child!==null){for(e=t.child,n=Ot(e,e.pendingProps),t.child=n,n.return=t;e.sibling!==null;)e=e.sibling,n=n.sibling=Ot(e,e.pendingProps),n.return=t;n.sibling=null}return t.child}function Sp(e,t,n){switch(t.tag){case 3:_d(t),Rn();break;case 5:Qc(t);break;case 1:we(t.type)&&Li(t);break;case 4:Cl(t,t.stateNode.containerInfo);break;case 10:var r=t.type._context,i=t.memoizedProps.value;F(Ni,r._currentValue),r._currentValue=i;break;case 13:if(r=t.memoizedState,r!==null)return r.dehydrated!==null?(F(H,H.current&1),t.flags|=128,null):n&t.child.childLanes?Sd(e,t,n):(F(H,H.current&1),e=at(e,t,n),e!==null?e.sibling:null);F(H,H.current&1);break;case 19:if(r=(n&t.childLanes)!==0,e.flags&128){if(r)return kd(e,t,n);t.flags|=128}if(i=t.memoizedState,i!==null&&(i.rendering=null,i.tail=null,i.lastEffect=null),F(H,H.current),r)break;return null;case 22:case 23:return t.lanes=0,yd(e,t,n)}return at(e,t,n)}var Ed,$o,Cd,xd;Ed=function(e,t){for(var n=t.child;n!==null;){if(n.tag===5||n.tag===6)e.appendChild(n.stateNode);else if(n.tag!==4&&n.child!==null){n.child.return=n,n=n.child;continue}if(n===t)break;for(;n.sibling===null;){if(n.return===null||n.return===t)return;n=n.return}n.sibling.return=n.return,n=n.sibling}};$o=function(){};Cd=function(e,t,n,r){var i=e.memoizedProps;if(i!==r){e=t.stateNode,Ht(Je.current);var s=null;switch(n){case"input":i=eo(e,i),r=eo(e,r),s=[];break;case"select":i=K({},i,{value:void 0}),r=K({},r,{value:void 0}),s=[];break;case"textarea":i=ro(e,i),r=ro(e,r),s=[];break;default:typeof i.onClick!="function"&&typeof r.onClick=="function"&&(e.onclick=Ri)}so(n,r);var o;n=null;for(u in i)if(!r.hasOwnProperty(u)&&i.hasOwnProperty(u)&&i[u]!=null)if(u==="style"){var l=i[u];for(o in l)l.hasOwnProperty(o)&&(n||(n={}),n[o]="")}else u!=="dangerouslySetInnerHTML"&&u!=="children"&&u!=="suppressContentEditableWarning"&&u!=="suppressHydrationWarning"&&u!=="autoFocus"&&(pr.hasOwnProperty(u)?s||(s=[]):(s=s||[]).push(u,null));for(u in r){var a=r[u];if(l=i!=null?i[u]:void 0,r.hasOwnProperty(u)&&a!==l&&(a!=null||l!=null))if(u==="style")if(l){for(o in l)!l.hasOwnProperty(o)||a&&a.hasOwnProperty(o)||(n||(n={}),n[o]="");for(o in a)a.hasOwnProperty(o)&&l[o]!==a[o]&&(n||(n={}),n[o]=a[o])}else n||(s||(s=[]),s.push(u,n)),n=a;else u==="dangerouslySetInnerHTML"?(a=a?a.__html:void 0,l=l?l.__html:void 0,a!=null&&l!==a&&(s=s||[]).push(u,a)):u==="children"?typeof a!="string"&&typeof a!="number"||(s=s||[]).push(u,""+a):u!=="suppressContentEditableWarning"&&u!=="suppressHydrationWarning"&&(pr.hasOwnProperty(u)?(a!=null&&u==="onScroll"&&b("scroll",e),s||l===a||(s=[])):(s=s||[]).push(u,a))}n&&(s=s||[]).push("style",n);var u=s;(t.updateQueue=u)&&(t.flags|=4)}};xd=function(e,t,n,r){n!==r&&(t.flags|=4)};function Jn(e,t){if(!V)switch(e.tailMode){case"hidden":t=e.tail;for(var n=null;t!==null;)t.alternate!==null&&(n=t),t=t.sibling;n===null?e.tail=null:n.sibling=null;break;case"collapsed":n=e.tail;for(var r=null;n!==null;)n.alternate!==null&&(r=n),n=n.sibling;r===null?t||e.tail===null?e.tail=null:e.tail.sibling=null:r.sibling=null}}function le(e){var t=e.alternate!==null&&e.alternate.child===e.child,n=0,r=0;if(t)for(var i=e.child;i!==null;)n|=i.lanes|i.childLanes,r|=i.subtreeFlags&14680064,r|=i.flags&14680064,i.return=e,i=i.sibling;else for(i=e.child;i!==null;)n|=i.lanes|i.childLanes,r|=i.subtreeFlags,r|=i.flags,i.return=e,i=i.sibling;return e.subtreeFlags|=r,e.childLanes=n,t}function kp(e,t,n){var r=t.pendingProps;switch(gl(t),t.tag){case 2:case 16:case 15:case 0:case 11:case 7:case 8:case 12:case 9:case 14:return le(t),null;case 1:return we(t.type)&&ji(),le(t),null;case 3:return r=t.stateNode,Ln(),B(ye),B(ce),Pl(),r.pendingContext&&(r.context=r.pendingContext,r.pendingContext=null),(e===null||e.child===null)&&(Zr(t)?t.flags|=4:e===null||e.memoizedState.isDehydrated&&!(t.flags&256)||(t.flags|=1024,be!==null&&(bo(be),be=null))),$o(e,t),le(t),null;case 5:xl(t);var i=Ht(Pr.current);if(n=t.type,e!==null&&t.stateNode!=null)Cd(e,t,n,r,i),e.ref!==t.ref&&(t.flags|=512,t.flags|=2097152);else{if(!r){if(t.stateNode===null)throw Error(S(166));return le(t),null}if(e=Ht(Je.current),Zr(t)){r=t.stateNode,n=t.type;var s=t.memoizedProps;switch(r[Ge]=t,r[Cr]=s,e=(t.mode&1)!==0,n){case"dialog":b("cancel",r),b("close",r);break;case"iframe":case"object":case"embed":b("load",r);break;case"video":case"audio":for(i=0;i<tr.length;i++)b(tr[i],r);break;case"source":b("error",r);break;case"img":case"image":case"link":b("error",r),b("load",r);break;case"details":b("toggle",r);break;case"input":ra(r,s),b("invalid",r);break;case"select":r._wrapperState={wasMultiple:!!s.multiple},b("invalid",r);break;case"textarea":sa(r,s),b("invalid",r)}so(n,s),i=null;for(var o in s)if(s.hasOwnProperty(o)){var l=s[o];o==="children"?typeof l=="string"?r.textContent!==l&&(s.suppressHydrationWarning!==!0&&Xr(r.textContent,l,e),i=["children",l]):typeof l=="number"&&r.textContent!==""+l&&(s.suppressHydrationWarning!==!0&&Xr(r.textContent,l,e),i=["children",""+l]):pr.hasOwnProperty(o)&&l!=null&&o==="onScroll"&&b("scroll",r)}switch(n){case"input":Hr(r),ia(r,s,!0);break;case"textarea":Hr(r),oa(r);break;case"select":case"option":break;default:typeof s.onClick=="function"&&(r.onclick=Ri)}r=i,t.updateQueue=r,r!==null&&(t.flags|=4)}else{o=i.nodeType===9?i:i.ownerDocument,e==="http://www.w3.org/1999/xhtml"&&(e=Zu(n)),e==="http://www.w3.org/1999/xhtml"?n==="script"?(e=o.createElement("div"),e.innerHTML="<script><\/script>",e=e.removeChild(e.firstChild)):typeof r.is=="string"?e=o.createElement(n,{is:r.is}):(e=o.createElement(n),n==="select"&&(o=e,r.multiple?o.multiple=!0:r.size&&(o.size=r.size))):e=o.createElementNS(e,n),e[Ge]=t,e[Cr]=r,Ed(e,t,!1,!1),t.stateNode=e;e:{switch(o=oo(n,r),n){case"dialog":b("cancel",e),b("close",e),i=r;break;case"iframe":case"object":case"embed":b("load",e),i=r;break;case"video":case"audio":for(i=0;i<tr.length;i++)b(tr[i],e);i=r;break;case"source":b("error",e),i=r;break;case"img":case"image":case"link":b("error",e),b("load",e),i=r;break;case"details":b("toggle",e),i=r;break;case"input":ra(e,r),i=eo(e,r),b("invalid",e);break;case"option":i=r;break;case"select":e._wrapperState={wasMultiple:!!r.multiple},i=K({},r,{value:void 0}),b("invalid",e);break;case"textarea":sa(e,r),i=ro(e,r),b("invalid",e);break;default:i=r}so(n,i),l=i;for(s in l)if(l.hasOwnProperty(s)){var a=l[s];s==="style"?nc(e,a):s==="dangerouslySetInnerHTML"?(a=a?a.__html:void 0,a!=null&&ec(e,a)):s==="children"?typeof a=="string"?(n!=="textarea"||a!=="")&&vr(e,a):typeof a=="number"&&vr(e,""+a):s!=="suppressContentEditableWarning"&&s!=="suppressHydrationWarning"&&s!=="autoFocus"&&(pr.hasOwnProperty(s)?a!=null&&s==="onScroll"&&b("scroll",e):a!=null&&nl(e,s,a,o))}switch(n){case"input":Hr(e),ia(e,r,!1);break;case"textarea":Hr(e),oa(e);break;case"option":r.value!=null&&e.setAttribute("value",""+Rt(r.value));break;case"select":e.multiple=!!r.multiple,s=r.value,s!=null?_n(e,!!r.multiple,s,!1):r.defaultValue!=null&&_n(e,!!r.multiple,r.defaultValue,!0);break;default:typeof i.onClick=="function"&&(e.onclick=Ri)}switch(n){case"button":case"input":case"select":case"textarea":r=!!r.autoFocus;break e;case"img":r=!0;break e;default:r=!1}}r&&(t.flags|=4)}t.ref!==null&&(t.flags|=512,t.flags|=2097152)}return le(t),null;case 6:if(e&&t.stateNode!=null)xd(e,t,e.memoizedProps,r);else{if(typeof r!="string"&&t.stateNode===null)throw Error(S(166));if(n=Ht(Pr.current),Ht(Je.current),Zr(t)){if(r=t.stateNode,n=t.memoizedProps,r[Ge]=t,(s=r.nodeValue!==n)&&(e=Ce,e!==null))switch(e.tag){case 3:Xr(r.nodeValue,n,(e.mode&1)!==0);break;case 5:e.memoizedProps.suppressHydrationWarning!==!0&&Xr(r.nodeValue,n,(e.mode&1)!==0)}s&&(t.flags|=4)}else r=(n.nodeType===9?n:n.ownerDocument).createTextNode(r),r[Ge]=t,t.stateNode=r}return le(t),null;case 13:if(B(H),r=t.memoizedState,e===null||e.memoizedState!==null&&e.memoizedState.dehydrated!==null){if(V&&Ee!==null&&t.mode&1&&!(t.flags&128))Vc(),Rn(),t.flags|=98560,s=!1;else if(s=Zr(t),r!==null&&r.dehydrated!==null){if(e===null){if(!s)throw Error(S(318));if(s=t.memoizedState,s=s!==null?s.dehydrated:null,!s)throw Error(S(317));s[Ge]=t}else Rn(),!(t.flags&128)&&(t.memoizedState=null),t.flags|=4;le(t),s=!1}else be!==null&&(bo(be),be=null),s=!0;if(!s)return t.flags&65536?t:null}return t.flags&128?(t.lanes=n,t):(r=r!==null,r!==(e!==null&&e.memoizedState!==null)&&r&&(t.child.flags|=8192,t.mode&1&&(e===null||H.current&1?X===0&&(X=3):zl())),t.updateQueue!==null&&(t.flags|=4),le(t),null);case 4:return Ln(),$o(e,t),e===null&&kr(t.stateNode.containerInfo),le(t),null;case 10:return Sl(t.type._context),le(t),null;case 17:return we(t.type)&&ji(),le(t),null;case 19:if(B(H),s=t.memoizedState,s===null)return le(t),null;if(r=(t.flags&128)!==0,o=s.rendering,o===null)if(r)Jn(s,!1);else{if(X!==0||e!==null&&e.flags&128)for(e=t.child;e!==null;){if(o=Di(e),o!==null){for(t.flags|=128,Jn(s,!1),r=o.updateQueue,r!==null&&(t.updateQueue=r,t.flags|=4),t.subtreeFlags=0,r=n,n=t.child;n!==null;)s=n,e=r,s.flags&=14680066,o=s.alternate,o===null?(s.childLanes=0,s.lanes=e,s.child=null,s.subtreeFlags=0,s.memoizedProps=null,s.memoizedState=null,s.updateQueue=null,s.dependencies=null,s.stateNode=null):(s.childLanes=o.childLanes,s.lanes=o.lanes,s.child=o.child,s.subtreeFlags=0,s.deletions=null,s.memoizedProps=o.memoizedProps,s.memoizedState=o.memoizedState,s.updateQueue=o.updateQueue,s.type=o.type,e=o.dependencies,s.dependencies=e===null?null:{lanes:e.lanes,firstContext:e.firstContext}),n=n.sibling;return F(H,H.current&1|2),t.child}e=e.sibling}s.tail!==null&&J()>$n&&(t.flags|=128,r=!0,Jn(s,!1),t.lanes=4194304)}else{if(!r)if(e=Di(o),e!==null){if(t.flags|=128,r=!0,n=e.updateQueue,n!==null&&(t.updateQueue=n,t.flags|=4),Jn(s,!0),s.tail===null&&s.tailMode==="hidden"&&!o.alternate&&!V)return le(t),null}else 2*J()-s.renderingStartTime>$n&&n!==1073741824&&(t.flags|=128,r=!0,Jn(s,!1),t.lanes=4194304);s.isBackwards?(o.sibling=t.child,t.child=o):(n=s.last,n!==null?n.sibling=o:t.child=o,s.last=o)}return s.tail!==null?(t=s.tail,s.rendering=t,s.tail=t.sibling,s.renderingStartTime=J(),t.sibling=null,n=H.current,F(H,r?n&1|2:n&1),t):(le(t),null);case 22:case 23:return Dl(),r=t.memoizedState!==null,e!==null&&e.memoizedState!==null!==r&&(t.flags|=8192),r&&t.mode&1?ke&1073741824&&(le(t),t.subtreeFlags&6&&(t.flags|=8192)):le(t),null;case 24:return null;case 25:return null}throw Error(S(156,t.tag))}function Ep(e,t){switch(gl(t),t.tag){case 1:return we(t.type)&&ji(),e=t.flags,e&65536?(t.flags=e&-65537|128,t):null;case 3:return Ln(),B(ye),B(ce),Pl(),e=t.flags,e&65536&&!(e&128)?(t.flags=e&-65537|128,t):null;case 5:return xl(t),null;case 13:if(B(H),e=t.memoizedState,e!==null&&e.dehydrated!==null){if(t.alternate===null)throw Error(S(340));Rn()}return e=t.flags,e&65536?(t.flags=e&-65537|128,t):null;case 19:return B(H),null;case 4:return Ln(),null;case 10:return Sl(t.type._context),null;case 22:case 23:return Dl(),null;case 24:return null;default:return null}}var ni=!1,ue=!1,Cp=typeof WeakSet=="function"?WeakSet:Set,C=null;function yn(e,t){var n=e.ref;if(n!==null)if(typeof n=="function")try{n(null)}catch(r){G(e,t,r)}else n.current=null}function No(e,t,n){try{n()}catch(r){G(e,t,r)}}var Ja=!1;function xp(e,t){if(go=Pi,e=jc(),vl(e)){if("selectionStart"in e)var n={start:e.selectionStart,end:e.selectionEnd};else e:{n=(n=e.ownerDocument)&&n.defaultView||window;var r=n.getSelection&&n.getSelection();if(r&&r.rangeCount!==0){n=r.anchorNode;var i=r.anchorOffset,s=r.focusNode;r=r.focusOffset;try{n.nodeType,s.nodeType}catch{n=null;break e}var o=0,l=-1,a=-1,u=0,c=0,d=e,h=null;t:for(;;){for(var m;d!==n||i!==0&&d.nodeType!==3||(l=o+i),d!==s||r!==0&&d.nodeType!==3||(a=o+r),d.nodeType===3&&(o+=d.nodeValue.length),(m=d.firstChild)!==null;)h=d,d=m;for(;;){if(d===e)break t;if(h===n&&++u===i&&(l=o),h===s&&++c===r&&(a=o),(m=d.nextSibling)!==null)break;d=h,h=d.parentNode}d=m}n=l===-1||a===-1?null:{start:l,end:a}}else n=null}n=n||{start:0,end:0}}else n=null;for(yo={focusedElem:e,selectionRange:n},Pi=!1,C=t;C!==null;)if(t=C,e=t.child,(t.subtreeFlags&1028)!==0&&e!==null)e.return=t,C=e;else for(;C!==null;){t=C;try{var g=t.alternate;if(t.flags&1024)switch(t.tag){case 0:case 11:case 15:break;case 1:if(g!==null){var y=g.memoizedProps,_=g.memoizedState,p=t.stateNode,f=p.getSnapshotBeforeUpdate(t.elementType===t.type?y:ze(t.type,y),_);p.__reactInternalSnapshotBeforeUpdate=f}break;case 3:var v=t.stateNode.containerInfo;v.nodeType===1?v.textContent="":v.nodeType===9&&v.documentElement&&v.removeChild(v.documentElement);break;case 5:case 6:case 4:case 17:break;default:throw Error(S(163))}}catch(w){G(t,t.return,w)}if(e=t.sibling,e!==null){e.return=t.return,C=e;break}C=t.return}return g=Ja,Ja=!1,g}function ur(e,t,n){var r=t.updateQueue;if(r=r!==null?r.lastEffect:null,r!==null){var i=r=r.next;do{if((i.tag&e)===e){var s=i.destroy;i.destroy=void 0,s!==void 0&&No(t,n,s)}i=i.next}while(i!==r)}}function ns(e,t){if(t=t.updateQueue,t=t!==null?t.lastEffect:null,t!==null){var n=t=t.next;do{if((n.tag&e)===e){var r=n.create;n.destroy=r()}n=n.next}while(n!==t)}}function Ao(e){var t=e.ref;if(t!==null){var n=e.stateNode;switch(e.tag){case 5:e=n;break;default:e=n}typeof t=="function"?t(e):t.current=e}}function Pd(e){var t=e.alternate;t!==null&&(e.alternate=null,Pd(t)),e.child=null,e.deletions=null,e.sibling=null,e.tag===5&&(t=e.stateNode,t!==null&&(delete t[Ge],delete t[Cr],delete t[So],delete t[lp],delete t[ap])),e.stateNode=null,e.return=null,e.dependencies=null,e.memoizedProps=null,e.memoizedState=null,e.pendingProps=null,e.stateNode=null,e.updateQueue=null}function Td(e){return e.tag===5||e.tag===3||e.tag===4}function qa(e){e:for(;;){for(;e.sibling===null;){if(e.return===null||Td(e.return))return null;e=e.return}for(e.sibling.return=e.return,e=e.sibling;e.tag!==5&&e.tag!==6&&e.tag!==18;){if(e.flags&2||e.child===null||e.tag===4)continue e;e.child.return=e,e=e.child}if(!(e.flags&2))return e.stateNode}}function Uo(e,t,n){var r=e.tag;if(r===5||r===6)e=e.stateNode,t?n.nodeType===8?n.parentNode.insertBefore(e,t):n.insertBefore(e,t):(n.nodeType===8?(t=n.parentNode,t.insertBefore(e,n)):(t=n,t.appendChild(e)),n=n._reactRootContainer,n!=null||t.onclick!==null||(t.onclick=Ri));else if(r!==4&&(e=e.child,e!==null))for(Uo(e,t,n),e=e.sibling;e!==null;)Uo(e,t,n),e=e.sibling}function Do(e,t,n){var r=e.tag;if(r===5||r===6)e=e.stateNode,t?n.insertBefore(e,t):n.appendChild(e);else if(r!==4&&(e=e.child,e!==null))for(Do(e,t,n),e=e.sibling;e!==null;)Do(e,t,n),e=e.sibling}var re=null,Fe=!1;function ct(e,t,n){for(n=n.child;n!==null;)Od(e,t,n),n=n.sibling}function Od(e,t,n){if(Qe&&typeof Qe.onCommitFiberUnmount=="function")try{Qe.onCommitFiberUnmount(Qi,n)}catch{}switch(n.tag){case 5:ue||yn(n,t);case 6:var r=re,i=Fe;re=null,ct(e,t,n),re=r,Fe=i,re!==null&&(Fe?(e=re,n=n.stateNode,e.nodeType===8?e.parentNode.removeChild(n):e.removeChild(n)):re.removeChild(n.stateNode));break;case 18:re!==null&&(Fe?(e=re,n=n.stateNode,e.nodeType===8?Ls(e.parentNode,n):e.nodeType===1&&Ls(e,n),wr(e)):Ls(re,n.stateNode));break;case 4:r=re,i=Fe,re=n.stateNode.containerInfo,Fe=!0,ct(e,t,n),re=r,Fe=i;break;case 0:case 11:case 14:case 15:if(!ue&&(r=n.updateQueue,r!==null&&(r=r.lastEffect,r!==null))){i=r=r.next;do{var s=i,o=s.destroy;s=s.tag,o!==void 0&&(s&2||s&4)&&No(n,t,o),i=i.next}while(i!==r)}ct(e,t,n);break;case 1:if(!ue&&(yn(n,t),r=n.stateNode,typeof r.componentWillUnmount=="function"))try{r.props=n.memoizedProps,r.state=n.memoizedState,r.componentWillUnmount()}catch(l){G(n,t,l)}ct(e,t,n);break;case 21:ct(e,t,n);break;case 22:n.mode&1?(ue=(r=ue)||n.memoizedState!==null,ct(e,t,n),ue=r):ct(e,t,n);break;default:ct(e,t,n)}}function Ya(e){var t=e.updateQueue;if(t!==null){e.updateQueue=null;var n=e.stateNode;n===null&&(n=e.stateNode=new Cp),t.forEach(function(r){var i=Np.bind(null,e,r);n.has(r)||(n.add(r),r.then(i,i))})}}function Ue(e,t){var n=t.deletions;if(n!==null)for(var r=0;r<n.length;r++){var i=n[r];try{var s=e,o=t,l=o;e:for(;l!==null;){switch(l.tag){case 5:re=l.stateNode,Fe=!1;break e;case 3:re=l.stateNode.containerInfo,Fe=!0;break e;case 4:re=l.stateNode.containerInfo,Fe=!0;break e}l=l.return}if(re===null)throw Error(S(160));Od(s,o,i),re=null,Fe=!1;var a=i.alternate;a!==null&&(a.return=null),i.return=null}catch(u){G(i,t,u)}}if(t.subtreeFlags&12854)for(t=t.child;t!==null;)Rd(t,e),t=t.sibling}function Rd(e,t){var n=e.alternate,r=e.flags;switch(e.tag){case 0:case 11:case 14:case 15:if(Ue(t,e),We(e),r&4){try{ur(3,e,e.return),ns(3,e)}catch(y){G(e,e.return,y)}try{ur(5,e,e.return)}catch(y){G(e,e.return,y)}}break;case 1:Ue(t,e),We(e),r&512&&n!==null&&yn(n,n.return);break;case 5:if(Ue(t,e),We(e),r&512&&n!==null&&yn(n,n.return),e.flags&32){var i=e.stateNode;try{vr(i,"")}catch(y){G(e,e.return,y)}}if(r&4&&(i=e.stateNode,i!=null)){var s=e.memoizedProps,o=n!==null?n.memoizedProps:s,l=e.type,a=e.updateQueue;if(e.updateQueue=null,a!==null)try{l==="input"&&s.type==="radio"&&s.name!=null&&Yu(i,s),oo(l,o);var u=oo(l,s);for(o=0;o<a.length;o+=2){var c=a[o],d=a[o+1];c==="style"?nc(i,d):c==="dangerouslySetInnerHTML"?ec(i,d):c==="children"?vr(i,d):nl(i,c,d,u)}switch(l){case"input":to(i,s);break;case"textarea":Xu(i,s);break;case"select":var h=i._wrapperState.wasMultiple;i._wrapperState.wasMultiple=!!s.multiple;var m=s.value;m!=null?_n(i,!!s.multiple,m,!1):h!==!!s.multiple&&(s.defaultValue!=null?_n(i,!!s.multiple,s.defaultValue,!0):_n(i,!!s.multiple,s.multiple?[]:"",!1))}i[Cr]=s}catch(y){G(e,e.return,y)}}break;case 6:if(Ue(t,e),We(e),r&4){if(e.stateNode===null)throw Error(S(162));i=e.stateNode,s=e.memoizedProps;try{i.nodeValue=s}catch(y){G(e,e.return,y)}}break;case 3:if(Ue(t,e),We(e),r&4&&n!==null&&n.memoizedState.isDehydrated)try{wr(t.containerInfo)}catch(y){G(e,e.return,y)}break;case 4:Ue(t,e),We(e);break;case 13:Ue(t,e),We(e),i=e.child,i.flags&8192&&(s=i.memoizedState!==null,i.stateNode.isHidden=s,!s||i.alternate!==null&&i.alternate.memoizedState!==null||(Al=J())),r&4&&Ya(e);break;case 22:if(c=n!==null&&n.memoizedState!==null,e.mode&1?(ue=(u=ue)||c,Ue(t,e),ue=u):Ue(t,e),We(e),r&8192){if(u=e.memoizedState!==null,(e.stateNode.isHidden=u)&&!c&&e.mode&1)for(C=e,c=e.child;c!==null;){for(d=C=c;C!==null;){switch(h=C,m=h.child,h.tag){case 0:case 11:case 14:case 15:ur(4,h,h.return);break;case 1:yn(h,h.return);var g=h.stateNode;if(typeof g.componentWillUnmount=="function"){r=h,n=h.return;try{t=r,g.props=t.memoizedProps,g.state=t.memoizedState,g.componentWillUnmount()}catch(y){G(r,n,y)}}break;case 5:yn(h,h.return);break;case 22:if(h.memoizedState!==null){Za(d);continue}}m!==null?(m.return=h,C=m):Za(d)}c=c.sibling}e:for(c=null,d=e;;){if(d.tag===5){if(c===null){c=d;try{i=d.stateNode,u?(s=i.style,typeof s.setProperty=="function"?s.setProperty("display","none","important"):s.display="none"):(l=d.stateNode,a=d.memoizedProps.style,o=a!=null&&a.hasOwnProperty("display")?a.display:null,l.style.display=tc("display",o))}catch(y){G(e,e.return,y)}}}else if(d.tag===6){if(c===null)try{d.stateNode.nodeValue=u?"":d.memoizedProps}catch(y){G(e,e.return,y)}}else if((d.tag!==22&&d.tag!==23||d.memoizedState===null||d===e)&&d.child!==null){d.child.return=d,d=d.child;continue}if(d===e)break e;for(;d.sibling===null;){if(d.return===null||d.return===e)break e;c===d&&(c=null),d=d.return}c===d&&(c=null),d.sibling.return=d.return,d=d.sibling}}break;case 19:Ue(t,e),We(e),r&4&&Ya(e);break;case 21:break;default:Ue(t,e),We(e)}}function We(e){var t=e.flags;if(t&2){try{e:{for(var n=e.return;n!==null;){if(Td(n)){var r=n;break e}n=n.return}throw Error(S(160))}switch(r.tag){case 5:var i=r.stateNode;r.flags&32&&(vr(i,""),r.flags&=-33);var s=qa(e);Do(e,s,i);break;case 3:case 4:var o=r.stateNode.containerInfo,l=qa(e);Uo(e,l,o);break;default:throw Error(S(161))}}catch(a){G(e,e.return,a)}e.flags&=-3}t&4096&&(e.flags&=-4097)}function Pp(e,t,n){C=e,jd(e)}function jd(e,t,n){for(var r=(e.mode&1)!==0;C!==null;){var i=C,s=i.child;if(i.tag===22&&r){var o=i.memoizedState!==null||ni;if(!o){var l=i.alternate,a=l!==null&&l.memoizedState!==null||ue;l=ni;var u=ue;if(ni=o,(ue=a)&&!u)for(C=i;C!==null;)o=C,a=o.child,o.tag===22&&o.memoizedState!==null?eu(i):a!==null?(a.return=o,C=a):eu(i);for(;s!==null;)C=s,jd(s),s=s.sibling;C=i,ni=l,ue=u}Xa(e)}else i.subtreeFlags&8772&&s!==null?(s.return=i,C=s):Xa(e)}}function Xa(e){for(;C!==null;){var t=C;if(t.flags&8772){var n=t.alternate;try{if(t.flags&8772)switch(t.tag){case 0:case 11:case 15:ue||ns(5,t);break;case 1:var r=t.stateNode;if(t.flags&4&&!ue)if(n===null)r.componentDidMount();else{var i=t.elementType===t.type?n.memoizedProps:ze(t.type,n.memoizedProps);r.componentDidUpdate(i,n.memoizedState,r.__reactInternalSnapshotBeforeUpdate)}var s=t.updateQueue;s!==null&&Ua(t,s,r);break;case 3:var o=t.updateQueue;if(o!==null){if(n=null,t.child!==null)switch(t.child.tag){case 5:n=t.child.stateNode;break;case 1:n=t.child.stateNode}Ua(t,o,n)}break;case 5:var l=t.stateNode;if(n===null&&t.flags&4){n=l;var a=t.memoizedProps;switch(t.type){case"button":case"input":case"select":case"textarea":a.autoFocus&&n.focus();break;case"img":a.src&&(n.src=a.src)}}break;case 6:break;case 4:break;case 12:break;case 13:if(t.memoizedState===null){var u=t.alternate;if(u!==null){var c=u.memoizedState;if(c!==null){var d=c.dehydrated;d!==null&&wr(d)}}}break;case 19:case 17:case 21:case 22:case 23:case 25:break;default:throw Error(S(163))}ue||t.flags&512&&Ao(t)}catch(h){G(t,t.return,h)}}if(t===e){C=null;break}if(n=t.sibling,n!==null){n.return=t.return,C=n;break}C=t.return}}function Za(e){for(;C!==null;){var t=C;if(t===e){C=null;break}var n=t.sibling;if(n!==null){n.return=t.return,C=n;break}C=t.return}}function eu(e){for(;C!==null;){var t=C;try{switch(t.tag){case 0:case 11:case 15:var n=t.return;try{ns(4,t)}catch(a){G(t,n,a)}break;case 1:var r=t.stateNode;if(typeof r.componentDidMount=="function"){var i=t.return;try{r.componentDidMount()}catch(a){G(t,i,a)}}var s=t.return;try{Ao(t)}catch(a){G(t,s,a)}break;case 5:var o=t.return;try{Ao(t)}catch(a){G(t,o,a)}}}catch(a){G(t,t.return,a)}if(t===e){C=null;break}var l=t.sibling;if(l!==null){l.return=t.return,C=l;break}C=t.return}}var Tp=Math.ceil,Mi=ut.ReactCurrentDispatcher,$l=ut.ReactCurrentOwner,$e=ut.ReactCurrentBatchConfig,A=0,ne=null,q=null,ie=0,ke=0,wn=It(0),X=0,jr=null,Yt=0,rs=0,Nl=0,cr=null,me=null,Al=0,$n=1/0,et=null,bi=!1,zo=null,Pt=null,ri=!1,wt=null,Bi=0,dr=0,Fo=null,gi=-1,yi=0;function he(){return A&6?J():gi!==-1?gi:gi=J()}function Tt(e){return e.mode&1?A&2&&ie!==0?ie&-ie:cp.transition!==null?(yi===0&&(yi=pc()),yi):(e=U,e!==0||(e=window.event,e=e===void 0?16:Sc(e.type)),e):1}function Ve(e,t,n,r){if(50<dr)throw dr=0,Fo=null,Error(S(185));Ar(e,n,r),(!(A&2)||e!==ne)&&(e===ne&&(!(A&2)&&(rs|=n),X===4&&mt(e,ie)),_e(e,r),n===1&&A===0&&!(t.mode&1)&&($n=J()+500,Zi&&$t()))}function _e(e,t){var n=e.callbackNode;ch(e,t);var r=xi(e,e===ne?ie:0);if(r===0)n!==null&&ua(n),e.callbackNode=null,e.callbackPriority=0;else if(t=r&-r,e.callbackPriority!==t){if(n!=null&&ua(n),t===1)e.tag===0?up(tu.bind(null,e)):Mc(tu.bind(null,e)),sp(function(){!(A&6)&&$t()}),n=null;else{switch(vc(r)){case 1:n=ll;break;case 4:n=fc;break;case 16:n=Ci;break;case 536870912:n=hc;break;default:n=Ci}n=zd(n,Ld.bind(null,e))}e.callbackPriority=t,e.callbackNode=n}}function Ld(e,t){if(gi=-1,yi=0,A&6)throw Error(S(327));var n=e.callbackNode;if(xn()&&e.callbackNode!==n)return null;var r=xi(e,e===ne?ie:0);if(r===0)return null;if(r&30||r&e.expiredLanes||t)t=Vi(e,r);else{t=r;var i=A;A|=2;var s=$d();(ne!==e||ie!==t)&&(et=null,$n=J()+500,Wt(e,t));do try{jp();break}catch(l){Id(e,l)}while(!0);_l(),Mi.current=s,A=i,q!==null?t=0:(ne=null,ie=0,t=X)}if(t!==0){if(t===2&&(i=fo(e),i!==0&&(r=i,t=Mo(e,i))),t===1)throw n=jr,Wt(e,0),mt(e,r),_e(e,J()),n;if(t===6)mt(e,r);else{if(i=e.current.alternate,!(r&30)&&!Op(i)&&(t=Vi(e,r),t===2&&(s=fo(e),s!==0&&(r=s,t=Mo(e,s))),t===1))throw n=jr,Wt(e,0),mt(e,r),_e(e,J()),n;switch(e.finishedWork=i,e.finishedLanes=r,t){case 0:case 1:throw Error(S(345));case 2:Ft(e,me,et);break;case 3:if(mt(e,r),(r&130023424)===r&&(t=Al+500-J(),10<t)){if(xi(e,0)!==0)break;if(i=e.suspendedLanes,(i&r)!==r){he(),e.pingedLanes|=e.suspendedLanes&i;break}e.timeoutHandle=_o(Ft.bind(null,e,me,et),t);break}Ft(e,me,et);break;case 4:if(mt(e,r),(r&4194240)===r)break;for(t=e.eventTimes,i=-1;0<r;){var o=31-Be(r);s=1<<o,o=t[o],o>i&&(i=o),r&=~s}if(r=i,r=J()-r,r=(120>r?120:480>r?480:1080>r?1080:1920>r?1920:3e3>r?3e3:4320>r?4320:1960*Tp(r/1960))-r,10<r){e.timeoutHandle=_o(Ft.bind(null,e,me,et),r);break}Ft(e,me,et);break;case 5:Ft(e,me,et);break;default:throw Error(S(329))}}}return _e(e,J()),e.callbackNode===n?Ld.bind(null,e):null}function Mo(e,t){var n=cr;return e.current.memoizedState.isDehydrated&&(Wt(e,t).flags|=256),e=Vi(e,t),e!==2&&(t=me,me=n,t!==null&&bo(t)),e}function bo(e){me===null?me=e:me.push.apply(me,e)}function Op(e){for(var t=e;;){if(t.flags&16384){var n=t.updateQueue;if(n!==null&&(n=n.stores,n!==null))for(var r=0;r<n.length;r++){var i=n[r],s=i.getSnapshot;i=i.value;try{if(!He(s(),i))return!1}catch{return!1}}}if(n=t.child,t.subtreeFlags&16384&&n!==null)n.return=t,t=n;else{if(t===e)break;for(;t.sibling===null;){if(t.return===null||t.return===e)return!0;t=t.return}t.sibling.return=t.return,t=t.sibling}}return!0}function mt(e,t){for(t&=~Nl,t&=~rs,e.suspendedLanes|=t,e.pingedLanes&=~t,e=e.expirationTimes;0<t;){var n=31-Be(t),r=1<<n;e[n]=-1,t&=~r}}function tu(e){if(A&6)throw Error(S(327));xn();var t=xi(e,0);if(!(t&1))return _e(e,J()),null;var n=Vi(e,t);if(e.tag!==0&&n===2){var r=fo(e);r!==0&&(t=r,n=Mo(e,r))}if(n===1)throw n=jr,Wt(e,0),mt(e,t),_e(e,J()),n;if(n===6)throw Error(S(345));return e.finishedWork=e.current.alternate,e.finishedLanes=t,Ft(e,me,et),_e(e,J()),null}function Ul(e,t){var n=A;A|=1;try{return e(t)}finally{A=n,A===0&&($n=J()+500,Zi&&$t())}}function Xt(e){wt!==null&&wt.tag===0&&!(A&6)&&xn();var t=A;A|=1;var n=$e.transition,r=U;try{if($e.transition=null,U=1,e)return e()}finally{U=r,$e.transition=n,A=t,!(A&6)&&$t()}}function Dl(){ke=wn.current,B(wn)}function Wt(e,t){e.finishedWork=null,e.finishedLanes=0;var n=e.timeoutHandle;if(n!==-1&&(e.timeoutHandle=-1,ip(n)),q!==null)for(n=q.return;n!==null;){var r=n;switch(gl(r),r.tag){case 1:r=r.type.childContextTypes,r!=null&&ji();break;case 3:Ln(),B(ye),B(ce),Pl();break;case 5:xl(r);break;case 4:Ln();break;case 13:B(H);break;case 19:B(H);break;case 10:Sl(r.type._context);break;case 22:case 23:Dl()}n=n.return}if(ne=e,q=e=Ot(e.current,null),ie=ke=t,X=0,jr=null,Nl=rs=Yt=0,me=cr=null,Vt!==null){for(t=0;t<Vt.length;t++)if(n=Vt[t],r=n.interleaved,r!==null){n.interleaved=null;var i=r.next,s=n.pending;if(s!==null){var o=s.next;s.next=i,r.next=o}n.pending=r}Vt=null}return e}function Id(e,t){do{var n=q;try{if(_l(),pi.current=Fi,zi){for(var r=W.memoizedState;r!==null;){var i=r.queue;i!==null&&(i.pending=null),r=r.next}zi=!1}if(qt=0,te=Y=W=null,ar=!1,Tr=0,$l.current=null,n===null||n.return===null){X=1,jr=t,q=null;break}e:{var s=e,o=n.return,l=n,a=t;if(t=ie,l.flags|=32768,a!==null&&typeof a=="object"&&typeof a.then=="function"){var u=a,c=l,d=c.tag;if(!(c.mode&1)&&(d===0||d===11||d===15)){var h=c.alternate;h?(c.updateQueue=h.updateQueue,c.memoizedState=h.memoizedState,c.lanes=h.lanes):(c.updateQueue=null,c.memoizedState=null)}var m=Ba(o);if(m!==null){m.flags&=-257,Va(m,o,l,s,t),m.mode&1&&ba(s,u,t),t=m,a=u;var g=t.updateQueue;if(g===null){var y=new Set;y.add(a),t.updateQueue=y}else g.add(a);break e}else{if(!(t&1)){ba(s,u,t),zl();break e}a=Error(S(426))}}else if(V&&l.mode&1){var _=Ba(o);if(_!==null){!(_.flags&65536)&&(_.flags|=256),Va(_,o,l,s,t),yl(In(a,l));break e}}s=a=In(a,l),X!==4&&(X=2),cr===null?cr=[s]:cr.push(s),s=o;do{switch(s.tag){case 3:s.flags|=65536,t&=-t,s.lanes|=t;var p=vd(s,a,t);Aa(s,p);break e;case 1:l=a;var f=s.type,v=s.stateNode;if(!(s.flags&128)&&(typeof f.getDerivedStateFromError=="function"||v!==null&&typeof v.componentDidCatch=="function"&&(Pt===null||!Pt.has(v)))){s.flags|=65536,t&=-t,s.lanes|=t;var w=md(s,l,t);Aa(s,w);break e}}s=s.return}while(s!==null)}Ad(n)}catch(k){t=k,q===n&&n!==null&&(q=n=n.return);continue}break}while(!0)}function $d(){var e=Mi.current;return Mi.current=Fi,e===null?Fi:e}function zl(){(X===0||X===3||X===2)&&(X=4),ne===null||!(Yt&268435455)&&!(rs&268435455)||mt(ne,ie)}function Vi(e,t){var n=A;A|=2;var r=$d();(ne!==e||ie!==t)&&(et=null,Wt(e,t));do try{Rp();break}catch(i){Id(e,i)}while(!0);if(_l(),A=n,Mi.current=r,q!==null)throw Error(S(261));return ne=null,ie=0,X}function Rp(){for(;q!==null;)Nd(q)}function jp(){for(;q!==null&&!th();)Nd(q)}function Nd(e){var t=Dd(e.alternate,e,ke);e.memoizedProps=e.pendingProps,t===null?Ad(e):q=t,$l.current=null}function Ad(e){var t=e;do{var n=t.alternate;if(e=t.return,t.flags&32768){if(n=Ep(n,t),n!==null){n.flags&=32767,q=n;return}if(e!==null)e.flags|=32768,e.subtreeFlags=0,e.deletions=null;else{X=6,q=null;return}}else if(n=kp(n,t,ke),n!==null){q=n;return}if(t=t.sibling,t!==null){q=t;return}q=t=e}while(t!==null);X===0&&(X=5)}function Ft(e,t,n){var r=U,i=$e.transition;try{$e.transition=null,U=1,Lp(e,t,n,r)}finally{$e.transition=i,U=r}return null}function Lp(e,t,n,r){do xn();while(wt!==null);if(A&6)throw Error(S(327));n=e.finishedWork;var i=e.finishedLanes;if(n===null)return null;if(e.finishedWork=null,e.finishedLanes=0,n===e.current)throw Error(S(177));e.callbackNode=null,e.callbackPriority=0;var s=n.lanes|n.childLanes;if(dh(e,s),e===ne&&(q=ne=null,ie=0),!(n.subtreeFlags&2064)&&!(n.flags&2064)||ri||(ri=!0,zd(Ci,function(){return xn(),null})),s=(n.flags&15990)!==0,n.subtreeFlags&15990||s){s=$e.transition,$e.transition=null;var o=U;U=1;var l=A;A|=4,$l.current=null,xp(e,n),Rd(n,e),Yh(yo),Pi=!!go,yo=go=null,e.current=n,Pp(n),nh(),A=l,U=o,$e.transition=s}else e.current=n;if(ri&&(ri=!1,wt=e,Bi=i),s=e.pendingLanes,s===0&&(Pt=null),sh(n.stateNode),_e(e,J()),t!==null)for(r=e.onRecoverableError,n=0;n<t.length;n++)i=t[n],r(i.value,{componentStack:i.stack,digest:i.digest});if(bi)throw bi=!1,e=zo,zo=null,e;return Bi&1&&e.tag!==0&&xn(),s=e.pendingLanes,s&1?e===Fo?dr++:(dr=0,Fo=e):dr=0,$t(),null}function xn(){if(wt!==null){var e=vc(Bi),t=$e.transition,n=U;try{if($e.transition=null,U=16>e?16:e,wt===null)var r=!1;else{if(e=wt,wt=null,Bi=0,A&6)throw Error(S(331));var i=A;for(A|=4,C=e.current;C!==null;){var s=C,o=s.child;if(C.flags&16){var l=s.deletions;if(l!==null){for(var a=0;a<l.length;a++){var u=l[a];for(C=u;C!==null;){var c=C;switch(c.tag){case 0:case 11:case 15:ur(8,c,s)}var d=c.child;if(d!==null)d.return=c,C=d;else for(;C!==null;){c=C;var h=c.sibling,m=c.return;if(Pd(c),c===u){C=null;break}if(h!==null){h.return=m,C=h;break}C=m}}}var g=s.alternate;if(g!==null){var y=g.child;if(y!==null){g.child=null;do{var _=y.sibling;y.sibling=null,y=_}while(y!==null)}}C=s}}if(s.subtreeFlags&2064&&o!==null)o.return=s,C=o;else e:for(;C!==null;){if(s=C,s.flags&2048)switch(s.tag){case 0:case 11:case 15:ur(9,s,s.return)}var p=s.sibling;if(p!==null){p.return=s.return,C=p;break e}C=s.return}}var f=e.current;for(C=f;C!==null;){o=C;var v=o.child;if(o.subtreeFlags&2064&&v!==null)v.return=o,C=v;else e:for(o=f;C!==null;){if(l=C,l.flags&2048)try{switch(l.tag){case 0:case 11:case 15:ns(9,l)}}catch(k){G(l,l.return,k)}if(l===o){C=null;break e}var w=l.sibling;if(w!==null){w.return=l.return,C=w;break e}C=l.return}}if(A=i,$t(),Qe&&typeof Qe.onPostCommitFiberRoot=="function")try{Qe.onPostCommitFiberRoot(Qi,e)}catch{}r=!0}return r}finally{U=n,$e.transition=t}}return!1}function nu(e,t,n){t=In(n,t),t=vd(e,t,1),e=xt(e,t,1),t=he(),e!==null&&(Ar(e,1,t),_e(e,t))}function G(e,t,n){if(e.tag===3)nu(e,e,n);else for(;t!==null;){if(t.tag===3){nu(t,e,n);break}else if(t.tag===1){var r=t.stateNode;if(typeof t.type.getDerivedStateFromError=="function"||typeof r.componentDidCatch=="function"&&(Pt===null||!Pt.has(r))){e=In(n,e),e=md(t,e,1),t=xt(t,e,1),e=he(),t!==null&&(Ar(t,1,e),_e(t,e));break}}t=t.return}}function Ip(e,t,n){var r=e.pingCache;r!==null&&r.delete(t),t=he(),e.pingedLanes|=e.suspendedLanes&n,ne===e&&(ie&n)===n&&(X===4||X===3&&(ie&130023424)===ie&&500>J()-Al?Wt(e,0):Nl|=n),_e(e,t)}function Ud(e,t){t===0&&(e.mode&1?(t=Gr,Gr<<=1,!(Gr&130023424)&&(Gr=4194304)):t=1);var n=he();e=lt(e,t),e!==null&&(Ar(e,t,n),_e(e,n))}function $p(e){var t=e.memoizedState,n=0;t!==null&&(n=t.retryLane),Ud(e,n)}function Np(e,t){var n=0;switch(e.tag){case 13:var r=e.stateNode,i=e.memoizedState;i!==null&&(n=i.retryLane);break;case 19:r=e.stateNode;break;default:throw Error(S(314))}r!==null&&r.delete(t),Ud(e,n)}var Dd;Dd=function(e,t,n){if(e!==null)if(e.memoizedProps!==t.pendingProps||ye.current)ge=!0;else{if(!(e.lanes&n)&&!(t.flags&128))return ge=!1,Sp(e,t,n);ge=!!(e.flags&131072)}else ge=!1,V&&t.flags&1048576&&bc(t,$i,t.index);switch(t.lanes=0,t.tag){case 2:var r=t.type;mi(e,t),e=t.pendingProps;var i=On(t,ce.current);Cn(t,n),i=Ol(null,t,r,e,i,n);var s=Rl();return t.flags|=1,typeof i=="object"&&i!==null&&typeof i.render=="function"&&i.$$typeof===void 0?(t.tag=1,t.memoizedState=null,t.updateQueue=null,we(r)?(s=!0,Li(t)):s=!1,t.memoizedState=i.state!==null&&i.state!==void 0?i.state:null,El(t),i.updater=ts,t.stateNode=i,i._reactInternals=t,To(t,r,e,n),t=jo(null,t,r,!0,s,n)):(t.tag=0,V&&s&&ml(t),fe(null,t,i,n),t=t.child),t;case 16:r=t.elementType;e:{switch(mi(e,t),e=t.pendingProps,i=r._init,r=i(r._payload),t.type=r,i=t.tag=Up(r),e=ze(r,e),i){case 0:t=Ro(null,t,r,e,n);break e;case 1:t=Ka(null,t,r,e,n);break e;case 11:t=Ha(null,t,r,e,n);break e;case 14:t=Wa(null,t,r,ze(r.type,e),n);break e}throw Error(S(306,r,""))}return t;case 0:return r=t.type,i=t.pendingProps,i=t.elementType===r?i:ze(r,i),Ro(e,t,r,i,n);case 1:return r=t.type,i=t.pendingProps,i=t.elementType===r?i:ze(r,i),Ka(e,t,r,i,n);case 3:e:{if(_d(t),e===null)throw Error(S(387));r=t.pendingProps,s=t.memoizedState,i=s.element,Gc(e,t),Ui(t,r,null,n);var o=t.memoizedState;if(r=o.element,s.isDehydrated)if(s={element:r,isDehydrated:!1,cache:o.cache,pendingSuspenseBoundaries:o.pendingSuspenseBoundaries,transitions:o.transitions},t.updateQueue.baseState=s,t.memoizedState=s,t.flags&256){i=In(Error(S(423)),t),t=Ga(e,t,r,n,i);break e}else if(r!==i){i=In(Error(S(424)),t),t=Ga(e,t,r,n,i);break e}else for(Ee=Ct(t.stateNode.containerInfo.firstChild),Ce=t,V=!0,be=null,n=Wc(t,null,r,n),t.child=n;n;)n.flags=n.flags&-3|4096,n=n.sibling;else{if(Rn(),r===i){t=at(e,t,n);break e}fe(e,t,r,n)}t=t.child}return t;case 5:return Qc(t),e===null&&Co(t),r=t.type,i=t.pendingProps,s=e!==null?e.memoizedProps:null,o=i.children,wo(r,i)?o=null:s!==null&&wo(r,s)&&(t.flags|=32),wd(e,t),fe(e,t,o,n),t.child;case 6:return e===null&&Co(t),null;case 13:return Sd(e,t,n);case 4:return Cl(t,t.stateNode.containerInfo),r=t.pendingProps,e===null?t.child=jn(t,null,r,n):fe(e,t,r,n),t.child;case 11:return r=t.type,i=t.pendingProps,i=t.elementType===r?i:ze(r,i),Ha(e,t,r,i,n);case 7:return fe(e,t,t.pendingProps,n),t.child;case 8:return fe(e,t,t.pendingProps.children,n),t.child;case 12:return fe(e,t,t.pendingProps.children,n),t.child;case 10:e:{if(r=t.type._context,i=t.pendingProps,s=t.memoizedProps,o=i.value,F(Ni,r._currentValue),r._currentValue=o,s!==null)if(He(s.value,o)){if(s.children===i.children&&!ye.current){t=at(e,t,n);break e}}else for(s=t.child,s!==null&&(s.return=t);s!==null;){var l=s.dependencies;if(l!==null){o=s.child;for(var a=l.firstContext;a!==null;){if(a.context===r){if(s.tag===1){a=it(-1,n&-n),a.tag=2;var u=s.updateQueue;if(u!==null){u=u.shared;var c=u.pending;c===null?a.next=a:(a.next=c.next,c.next=a),u.pending=a}}s.lanes|=n,a=s.alternate,a!==null&&(a.lanes|=n),xo(s.return,n,t),l.lanes|=n;break}a=a.next}}else if(s.tag===10)o=s.type===t.type?null:s.child;else if(s.tag===18){if(o=s.return,o===null)throw Error(S(341));o.lanes|=n,l=o.alternate,l!==null&&(l.lanes|=n),xo(o,n,t),o=s.sibling}else o=s.child;if(o!==null)o.return=s;else for(o=s;o!==null;){if(o===t){o=null;break}if(s=o.sibling,s!==null){s.return=o.return,o=s;break}o=o.return}s=o}fe(e,t,i.children,n),t=t.child}return t;case 9:return i=t.type,r=t.pendingProps.children,Cn(t,n),i=Ne(i),r=r(i),t.flags|=1,fe(e,t,r,n),t.child;case 14:return r=t.type,i=ze(r,t.pendingProps),i=ze(r.type,i),Wa(e,t,r,i,n);case 15:return gd(e,t,t.type,t.pendingProps,n);case 17:return r=t.type,i=t.pendingProps,i=t.elementType===r?i:ze(r,i),mi(e,t),t.tag=1,we(r)?(e=!0,Li(t)):e=!1,Cn(t,n),pd(t,r,i),To(t,r,i,n),jo(null,t,r,!0,e,n);case 19:return kd(e,t,n);case 22:return yd(e,t,n)}throw Error(S(156,t.tag))};function zd(e,t){return dc(e,t)}function Ap(e,t,n,r){this.tag=e,this.key=n,this.sibling=this.child=this.return=this.stateNode=this.type=this.elementType=null,this.index=0,this.ref=null,this.pendingProps=t,this.dependencies=this.memoizedState=this.updateQueue=this.memoizedProps=null,this.mode=r,this.subtreeFlags=this.flags=0,this.deletions=null,this.childLanes=this.lanes=0,this.alternate=null}function Ie(e,t,n,r){return new Ap(e,t,n,r)}function Fl(e){return e=e.prototype,!(!e||!e.isReactComponent)}function Up(e){if(typeof e=="function")return Fl(e)?1:0;if(e!=null){if(e=e.$$typeof,e===il)return 11;if(e===sl)return 14}return 2}function Ot(e,t){var n=e.alternate;return n===null?(n=Ie(e.tag,t,e.key,e.mode),n.elementType=e.elementType,n.type=e.type,n.stateNode=e.stateNode,n.alternate=e,e.alternate=n):(n.pendingProps=t,n.type=e.type,n.flags=0,n.subtreeFlags=0,n.deletions=null),n.flags=e.flags&14680064,n.childLanes=e.childLanes,n.lanes=e.lanes,n.child=e.child,n.memoizedProps=e.memoizedProps,n.memoizedState=e.memoizedState,n.updateQueue=e.updateQueue,t=e.dependencies,n.dependencies=t===null?null:{lanes:t.lanes,firstContext:t.firstContext},n.sibling=e.sibling,n.index=e.index,n.ref=e.ref,n}function wi(e,t,n,r,i,s){var o=2;if(r=e,typeof e=="function")Fl(e)&&(o=1);else if(typeof e=="string")o=5;else e:switch(e){case un:return Kt(n.children,i,s,t);case rl:o=8,i|=8;break;case qs:return e=Ie(12,n,t,i|2),e.elementType=qs,e.lanes=s,e;case Ys:return e=Ie(13,n,t,i),e.elementType=Ys,e.lanes=s,e;case Xs:return e=Ie(19,n,t,i),e.elementType=Xs,e.lanes=s,e;case Qu:return is(n,i,s,t);default:if(typeof e=="object"&&e!==null)switch(e.$$typeof){case Ku:o=10;break e;case Gu:o=9;break e;case il:o=11;break e;case sl:o=14;break e;case ft:o=16,r=null;break e}throw Error(S(130,e==null?e:typeof e,""))}return t=Ie(o,n,t,i),t.elementType=e,t.type=r,t.lanes=s,t}function Kt(e,t,n,r){return e=Ie(7,e,r,t),e.lanes=n,e}function is(e,t,n,r){return e=Ie(22,e,r,t),e.elementType=Qu,e.lanes=n,e.stateNode={isHidden:!1},e}function Fs(e,t,n){return e=Ie(6,e,null,t),e.lanes=n,e}function Ms(e,t,n){return t=Ie(4,e.children!==null?e.children:[],e.key,t),t.lanes=n,t.stateNode={containerInfo:e.containerInfo,pendingChildren:null,implementation:e.implementation},t}function Dp(e,t,n,r,i){this.tag=t,this.containerInfo=e,this.finishedWork=this.pingCache=this.current=this.pendingChildren=null,this.timeoutHandle=-1,this.callbackNode=this.pendingContext=this.context=null,this.callbackPriority=0,this.eventTimes=_s(0),this.expirationTimes=_s(-1),this.entangledLanes=this.finishedLanes=this.mutableReadLanes=this.expiredLanes=this.pingedLanes=this.suspendedLanes=this.pendingLanes=0,this.entanglements=_s(0),this.identifierPrefix=r,this.onRecoverableError=i,this.mutableSourceEagerHydrationData=null}function Ml(e,t,n,r,i,s,o,l,a){return e=new Dp(e,t,n,l,a),t===1?(t=1,s===!0&&(t|=8)):t=0,s=Ie(3,null,null,t),e.current=s,s.stateNode=e,s.memoizedState={element:r,isDehydrated:n,cache:null,transitions:null,pendingSuspenseBoundaries:null},El(s),e}function zp(e,t,n){var r=3<arguments.length&&arguments[3]!==void 0?arguments[3]:null;return{$$typeof:an,key:r==null?null:""+r,children:e,containerInfo:t,implementation:n}}function Fd(e){if(!e)return jt;e=e._reactInternals;e:{if(en(e)!==e||e.tag!==1)throw Error(S(170));var t=e;do{switch(t.tag){case 3:t=t.stateNode.context;break e;case 1:if(we(t.type)){t=t.stateNode.__reactInternalMemoizedMergedChildContext;break e}}t=t.return}while(t!==null);throw Error(S(171))}if(e.tag===1){var n=e.type;if(we(n))return Fc(e,n,t)}return t}function Md(e,t,n,r,i,s,o,l,a){return e=Ml(n,r,!0,e,i,s,o,l,a),e.context=Fd(null),n=e.current,r=he(),i=Tt(n),s=it(r,i),s.callback=t??null,xt(n,s,i),e.current.lanes=i,Ar(e,i,r),_e(e,r),e}function ss(e,t,n,r){var i=t.current,s=he(),o=Tt(i);return n=Fd(n),t.context===null?t.context=n:t.pendingContext=n,t=it(s,o),t.payload={element:e},r=r===void 0?null:r,r!==null&&(t.callback=r),e=xt(i,t,o),e!==null&&(Ve(e,i,o,s),hi(e,i,o)),o}function Hi(e){if(e=e.current,!e.child)return null;switch(e.child.tag){case 5:return e.child.stateNode;default:return e.child.stateNode}}function ru(e,t){if(e=e.memoizedState,e!==null&&e.dehydrated!==null){var n=e.retryLane;e.retryLane=n!==0&&n<t?n:t}}function bl(e,t){ru(e,t),(e=e.alternate)&&ru(e,t)}function Fp(){return null}var bd=typeof reportError=="function"?reportError:function(e){console.error(e)};function Bl(e){this._internalRoot=e}os.prototype.render=Bl.prototype.render=function(e){var t=this._internalRoot;if(t===null)throw Error(S(409));ss(e,t,null,null)};os.prototype.unmount=Bl.prototype.unmount=function(){var e=this._internalRoot;if(e!==null){this._internalRoot=null;var t=e.containerInfo;Xt(function(){ss(null,e,null,null)}),t[ot]=null}};function os(e){this._internalRoot=e}os.prototype.unstable_scheduleHydration=function(e){if(e){var t=yc();e={blockedOn:null,target:e,priority:t};for(var n=0;n<vt.length&&t!==0&&t<vt[n].priority;n++);vt.splice(n,0,e),n===0&&_c(e)}};function Vl(e){return!(!e||e.nodeType!==1&&e.nodeType!==9&&e.nodeType!==11)}function ls(e){return!(!e||e.nodeType!==1&&e.nodeType!==9&&e.nodeType!==11&&(e.nodeType!==8||e.nodeValue!==" react-mount-point-unstable "))}function iu(){}function Mp(e,t,n,r,i){if(i){if(typeof r=="function"){var s=r;r=function(){var u=Hi(o);s.call(u)}}var o=Md(t,r,e,0,null,!1,!1,"",iu);return e._reactRootContainer=o,e[ot]=o.current,kr(e.nodeType===8?e.parentNode:e),Xt(),o}for(;i=e.lastChild;)e.removeChild(i);if(typeof r=="function"){var l=r;r=function(){var u=Hi(a);l.call(u)}}var a=Ml(e,0,!1,null,null,!1,!1,"",iu);return e._reactRootContainer=a,e[ot]=a.current,kr(e.nodeType===8?e.parentNode:e),Xt(function(){ss(t,a,n,r)}),a}function as(e,t,n,r,i){var s=n._reactRootContainer;if(s){var o=s;if(typeof i=="function"){var l=i;i=function(){var a=Hi(o);l.call(a)}}ss(t,o,e,i)}else o=Mp(n,t,e,i,r);return Hi(o)}mc=function(e){switch(e.tag){case 3:var t=e.stateNode;if(t.current.memoizedState.isDehydrated){var n=er(t.pendingLanes);n!==0&&(al(t,n|1),_e(t,J()),!(A&6)&&($n=J()+500,$t()))}break;case 13:Xt(function(){var r=lt(e,1);if(r!==null){var i=he();Ve(r,e,1,i)}}),bl(e,1)}};ul=function(e){if(e.tag===13){var t=lt(e,134217728);if(t!==null){var n=he();Ve(t,e,134217728,n)}bl(e,134217728)}};gc=function(e){if(e.tag===13){var t=Tt(e),n=lt(e,t);if(n!==null){var r=he();Ve(n,e,t,r)}bl(e,t)}};yc=function(){return U};wc=function(e,t){var n=U;try{return U=e,t()}finally{U=n}};ao=function(e,t,n){switch(t){case"input":if(to(e,n),t=n.name,n.type==="radio"&&t!=null){for(n=e;n.parentNode;)n=n.parentNode;for(n=n.querySelectorAll("input[name="+JSON.stringify(""+t)+'][type="radio"]'),t=0;t<n.length;t++){var r=n[t];if(r!==e&&r.form===e.form){var i=Xi(r);if(!i)throw Error(S(90));qu(r),to(r,i)}}}break;case"textarea":Xu(e,n);break;case"select":t=n.value,t!=null&&_n(e,!!n.multiple,t,!1)}};sc=Ul;oc=Xt;var bp={usingClientEntryPoint:!1,Events:[Dr,hn,Xi,rc,ic,Ul]},qn={findFiberByHostInstance:Bt,bundleType:0,version:"18.3.1",rendererPackageName:"react-dom"},Bp={bundleType:qn.bundleType,version:qn.version,rendererPackageName:qn.rendererPackageName,rendererConfig:qn.rendererConfig,overrideHookState:null,overrideHookStateDeletePath:null,overrideHookStateRenamePath:null,overrideProps:null,overridePropsDeletePath:null,overridePropsRenamePath:null,setErrorHandler:null,setSuspenseHandler:null,scheduleUpdate:null,currentDispatcherRef:ut.ReactCurrentDispatcher,findHostInstanceByFiber:function(e){return e=uc(e),e===null?null:e.stateNode},findFiberByHostInstance:qn.findFiberByHostInstance||Fp,findHostInstancesForRefresh:null,scheduleRefresh:null,scheduleRoot:null,setRefreshHandler:null,getCurrentFiber:null,reconcilerVersion:"18.3.1-next-f1338f8080-20240426"};if(typeof __REACT_DEVTOOLS_GLOBAL_HOOK__<"u"){var ii=__REACT_DEVTOOLS_GLOBAL_HOOK__;if(!ii.isDisabled&&ii.supportsFiber)try{Qi=ii.inject(Bp),Qe=ii}catch{}}Pe.__SECRET_INTERNALS_DO_NOT_USE_OR_YOU_WILL_BE_FIRED=bp;Pe.createPortal=function(e,t){var n=2<arguments.length&&arguments[2]!==void 0?arguments[2]:null;if(!Vl(t))throw Error(S(200));return zp(e,t,null,n)};Pe.createRoot=function(e,t){if(!Vl(e))throw Error(S(299));var n=!1,r="",i=bd;return t!=null&&(t.unstable_strictMode===!0&&(n=!0),t.identifierPrefix!==void 0&&(r=t.identifierPrefix),t.onRecoverableError!==void 0&&(i=t.onRecoverableError)),t=Ml(e,1,!1,null,null,n,!1,r,i),e[ot]=t.current,kr(e.nodeType===8?e.parentNode:e),new Bl(t)};Pe.findDOMNode=function(e){if(e==null)return null;if(e.nodeType===1)return e;var t=e._reactInternals;if(t===void 0)throw typeof e.render=="function"?Error(S(188)):(e=Object.keys(e).join(","),Error(S(268,e)));return e=uc(t),e=e===null?null:e.stateNode,e};Pe.flushSync=function(e){return Xt(e)};Pe.hydrate=function(e,t,n){if(!ls(t))throw Error(S(200));return as(null,e,t,!0,n)};Pe.hydrateRoot=function(e,t,n){if(!Vl(e))throw Error(S(405));var r=n!=null&&n.hydratedSources||null,i=!1,s="",o=bd;if(n!=null&&(n.unstable_strictMode===!0&&(i=!0),n.identifierPrefix!==void 0&&(s=n.identifierPrefix),n.onRecoverableError!==void 0&&(o=n.onRecoverableError)),t=Md(t,null,e,1,n??null,i,!1,s,o),e[ot]=t.current,kr(e),r)for(e=0;e<r.length;e++)n=r[e],i=n._getVersion,i=i(n._source),t.mutableSourceEagerHydrationData==null?t.mutableSourceEagerHydrationData=[n,i]:t.mutableSourceEagerHydrationData.push(n,i);return new os(t)};Pe.render=function(e,t,n){if(!ls(t))throw Error(S(200));return as(null,e,t,!1,n)};Pe.unmountComponentAtNode=function(e){if(!ls(e))throw Error(S(40));return e._reactRootContainer?(Xt(function(){as(null,null,e,!1,function(){e._reactRootContainer=null,e[ot]=null})}),!0):!1};Pe.unstable_batchedUpdates=Ul;Pe.unstable_renderSubtreeIntoContainer=function(e,t,n,r){if(!ls(n))throw Error(S(200));if(e==null||e._reactInternals===void 0)throw Error(S(38));return as(e,t,n,!1,r)};Pe.version="18.3.1-next-f1338f8080-20240426";function Bd(){if(!(typeof __REACT_DEVTOOLS_GLOBAL_HOOK__>"u"||typeof __REACT_DEVTOOLS_GLOBAL_HOOK__.checkDCE!="function"))try{__REACT_DEVTOOLS_GLOBAL_HOOK__.checkDCE(Bd)}catch(e){console.error(e)}}Bd(),Bu.exports=Pe;var Vp=Bu.exports,su=Vp;Qs.createRoot=su.createRoot,Qs.hydrateRoot=su.hydrateRoot;/** + * @remix-run/router v1.16.1 + * + * Copyright (c) Remix Software Inc. + * + * This source code is licensed under the MIT license found in the + * LICENSE.md file in the root directory of this source tree. + * + * @license MIT + */function Lr(){return Lr=Object.assign?Object.assign.bind():function(e){for(var t=1;t<arguments.length;t++){var n=arguments[t];for(var r in n)Object.prototype.hasOwnProperty.call(n,r)&&(e[r]=n[r])}return e},Lr.apply(this,arguments)}var _t;(function(e){e.Pop="POP",e.Push="PUSH",e.Replace="REPLACE"})(_t||(_t={}));const ou="popstate";function Hp(e){e===void 0&&(e={});function t(r,i){let{pathname:s,search:o,hash:l}=r.location;return Bo("",{pathname:s,search:o,hash:l},i.state&&i.state.usr||null,i.state&&i.state.key||"default")}function n(r,i){return typeof i=="string"?i:Hd(i)}return Kp(t,n,null,e)}function Z(e,t){if(e===!1||e===null||typeof e>"u")throw new Error(t)}function Vd(e,t){if(!e){typeof console<"u"&&console.warn(t);try{throw new Error(t)}catch{}}}function Wp(){return Math.random().toString(36).substr(2,8)}function lu(e,t){return{usr:e.state,key:e.key,idx:t}}function Bo(e,t,n,r){return n===void 0&&(n=null),Lr({pathname:typeof e=="string"?e:e.pathname,search:"",hash:""},typeof t=="string"?Fn(t):t,{state:n,key:t&&t.key||r||Wp()})}function Hd(e){let{pathname:t="/",search:n="",hash:r=""}=e;return n&&n!=="?"&&(t+=n.charAt(0)==="?"?n:"?"+n),r&&r!=="#"&&(t+=r.charAt(0)==="#"?r:"#"+r),t}function Fn(e){let t={};if(e){let n=e.indexOf("#");n>=0&&(t.hash=e.substr(n),e=e.substr(0,n));let r=e.indexOf("?");r>=0&&(t.search=e.substr(r),e=e.substr(0,r)),e&&(t.pathname=e)}return t}function Kp(e,t,n,r){r===void 0&&(r={});let{window:i=document.defaultView,v5Compat:s=!1}=r,o=i.history,l=_t.Pop,a=null,u=c();u==null&&(u=0,o.replaceState(Lr({},o.state,{idx:u}),""));function c(){return(o.state||{idx:null}).idx}function d(){l=_t.Pop;let _=c(),p=_==null?null:_-u;u=_,a&&a({action:l,location:y.location,delta:p})}function h(_,p){l=_t.Push;let f=Bo(y.location,_,p);u=c()+1;let v=lu(f,u),w=y.createHref(f);try{o.pushState(v,"",w)}catch(k){if(k instanceof DOMException&&k.name==="DataCloneError")throw k;i.location.assign(w)}s&&a&&a({action:l,location:y.location,delta:1})}function m(_,p){l=_t.Replace;let f=Bo(y.location,_,p);u=c();let v=lu(f,u),w=y.createHref(f);o.replaceState(v,"",w),s&&a&&a({action:l,location:y.location,delta:0})}function g(_){let p=i.location.origin!=="null"?i.location.origin:i.location.href,f=typeof _=="string"?_:Hd(_);return f=f.replace(/ $/,"%20"),Z(p,"No window.location.(origin|href) available to create URL for href: "+f),new URL(f,p)}let y={get action(){return l},get location(){return e(i,o)},listen(_){if(a)throw new Error("A history only accepts one active listener");return i.addEventListener(ou,d),a=_,()=>{i.removeEventListener(ou,d),a=null}},createHref(_){return t(i,_)},createURL:g,encodeLocation(_){let p=g(_);return{pathname:p.pathname,search:p.search,hash:p.hash}},push:h,replace:m,go(_){return o.go(_)}};return y}var au;(function(e){e.data="data",e.deferred="deferred",e.redirect="redirect",e.error="error"})(au||(au={}));function Gp(e,t,n){n===void 0&&(n="/");let r=typeof t=="string"?Fn(t):t,i=Gd(r.pathname||"/",n);if(i==null)return null;let s=Wd(e);Qp(s);let o=null;for(let l=0;o==null&&l<s.length;++l){let a=ov(i);o=rv(s[l],a)}return o}function Wd(e,t,n,r){t===void 0&&(t=[]),n===void 0&&(n=[]),r===void 0&&(r="");let i=(s,o,l)=>{let a={relativePath:l===void 0?s.path||"":l,caseSensitive:s.caseSensitive===!0,childrenIndex:o,route:s};a.relativePath.startsWith("/")&&(Z(a.relativePath.startsWith(r),'Absolute route path "'+a.relativePath+'" nested under path '+('"'+r+'" is not valid. An absolute child route path ')+"must start with the combined path of all its parent routes."),a.relativePath=a.relativePath.slice(r.length));let u=Gt([r,a.relativePath]),c=n.concat(a);s.children&&s.children.length>0&&(Z(s.index!==!0,"Index routes must not have child routes. Please remove "+('all child routes from route path "'+u+'".')),Wd(s.children,t,c,u)),!(s.path==null&&!s.index)&&t.push({path:u,score:tv(u,s.index),routesMeta:c})};return e.forEach((s,o)=>{var l;if(s.path===""||!((l=s.path)!=null&&l.includes("?")))i(s,o);else for(let a of Kd(s.path))i(s,o,a)}),t}function Kd(e){let t=e.split("/");if(t.length===0)return[];let[n,...r]=t,i=n.endsWith("?"),s=n.replace(/\?$/,"");if(r.length===0)return i?[s,""]:[s];let o=Kd(r.join("/")),l=[];return l.push(...o.map(a=>a===""?s:[s,a].join("/"))),i&&l.push(...o),l.map(a=>e.startsWith("/")&&a===""?"/":a)}function Qp(e){e.sort((t,n)=>t.score!==n.score?n.score-t.score:nv(t.routesMeta.map(r=>r.childrenIndex),n.routesMeta.map(r=>r.childrenIndex)))}const Jp=/^:[\w-]+$/,qp=3,Yp=2,Xp=1,Zp=10,ev=-2,uu=e=>e==="*";function tv(e,t){let n=e.split("/"),r=n.length;return n.some(uu)&&(r+=ev),t&&(r+=Yp),n.filter(i=>!uu(i)).reduce((i,s)=>i+(Jp.test(s)?qp:s===""?Xp:Zp),r)}function nv(e,t){return e.length===t.length&&e.slice(0,-1).every((r,i)=>r===t[i])?e[e.length-1]-t[t.length-1]:0}function rv(e,t){let{routesMeta:n}=e,r={},i="/",s=[];for(let o=0;o<n.length;++o){let l=n[o],a=o===n.length-1,u=i==="/"?t:t.slice(i.length)||"/",c=iv({path:l.relativePath,caseSensitive:l.caseSensitive,end:a},u);if(!c)return null;Object.assign(r,c.params);let d=l.route;s.push({params:r,pathname:Gt([i,c.pathname]),pathnameBase:fv(Gt([i,c.pathnameBase])),route:d}),c.pathnameBase!=="/"&&(i=Gt([i,c.pathnameBase]))}return s}function iv(e,t){typeof e=="string"&&(e={path:e,caseSensitive:!1,end:!0});let[n,r]=sv(e.path,e.caseSensitive,e.end),i=t.match(n);if(!i)return null;let s=i[0],o=s.replace(/(.)\/+$/,"$1"),l=i.slice(1);return{params:r.reduce((u,c,d)=>{let{paramName:h,isOptional:m}=c;if(h==="*"){let y=l[d]||"";o=s.slice(0,s.length-y.length).replace(/(.)\/+$/,"$1")}const g=l[d];return m&&!g?u[h]=void 0:u[h]=(g||"").replace(/%2F/g,"/"),u},{}),pathname:s,pathnameBase:o,pattern:e}}function sv(e,t,n){t===void 0&&(t=!1),n===void 0&&(n=!0),Vd(e==="*"||!e.endsWith("*")||e.endsWith("/*"),'Route path "'+e+'" will be treated as if it were '+('"'+e.replace(/\*$/,"/*")+'" because the `*` character must ')+"always follow a `/` in the pattern. To get rid of this warning, "+('please change the route path to "'+e.replace(/\*$/,"/*")+'".'));let r=[],i="^"+e.replace(/\/*\*?$/,"").replace(/^\/*/,"/").replace(/[\\.*+^${}|()[\]]/g,"\\$&").replace(/\/:([\w-]+)(\?)?/g,(o,l,a)=>(r.push({paramName:l,isOptional:a!=null}),a?"/?([^\\/]+)?":"/([^\\/]+)"));return e.endsWith("*")?(r.push({paramName:"*"}),i+=e==="*"||e==="/*"?"(.*)$":"(?:\\/(.+)|\\/*)$"):n?i+="\\/*$":e!==""&&e!=="/"&&(i+="(?:(?=\\/|$))"),[new RegExp(i,t?void 0:"i"),r]}function ov(e){try{return e.split("/").map(t=>decodeURIComponent(t).replace(/\//g,"%2F")).join("/")}catch(t){return Vd(!1,'The URL path "'+e+'" could not be decoded because it is is a malformed URL segment. This is probably due to a bad percent '+("encoding ("+t+").")),e}}function Gd(e,t){if(t==="/")return e;if(!e.toLowerCase().startsWith(t.toLowerCase()))return null;let n=t.endsWith("/")?t.length-1:t.length,r=e.charAt(n);return r&&r!=="/"?null:e.slice(n)||"/"}function lv(e,t){t===void 0&&(t="/");let{pathname:n,search:r="",hash:i=""}=typeof e=="string"?Fn(e):e;return{pathname:n?n.startsWith("/")?n:av(n,t):t,search:hv(r),hash:pv(i)}}function av(e,t){let n=t.replace(/\/+$/,"").split("/");return e.split("/").forEach(i=>{i===".."?n.length>1&&n.pop():i!=="."&&n.push(i)}),n.length>1?n.join("/"):"/"}function bs(e,t,n,r){return"Cannot include a '"+e+"' character in a manually specified "+("`to."+t+"` field ["+JSON.stringify(r)+"]. Please separate it out to the ")+("`to."+n+"` field. Alternatively you may provide the full path as ")+'a string in <Link to="..."> and the router will parse it for you.'}function uv(e){return e.filter((t,n)=>n===0||t.route.path&&t.route.path.length>0)}function cv(e,t){let n=uv(e);return t?n.map((r,i)=>i===e.length-1?r.pathname:r.pathnameBase):n.map(r=>r.pathnameBase)}function dv(e,t,n,r){r===void 0&&(r=!1);let i;typeof e=="string"?i=Fn(e):(i=Lr({},e),Z(!i.pathname||!i.pathname.includes("?"),bs("?","pathname","search",i)),Z(!i.pathname||!i.pathname.includes("#"),bs("#","pathname","hash",i)),Z(!i.search||!i.search.includes("#"),bs("#","search","hash",i)));let s=e===""||i.pathname==="",o=s?"/":i.pathname,l;if(o==null)l=n;else{let d=t.length-1;if(!r&&o.startsWith("..")){let h=o.split("/");for(;h[0]==="..";)h.shift(),d-=1;i.pathname=h.join("/")}l=d>=0?t[d]:"/"}let a=lv(i,l),u=o&&o!=="/"&&o.endsWith("/"),c=(s||o===".")&&n.endsWith("/");return!a.pathname.endsWith("/")&&(u||c)&&(a.pathname+="/"),a}const Gt=e=>e.join("/").replace(/\/\/+/g,"/"),fv=e=>e.replace(/\/+$/,"").replace(/^\/*/,"/"),hv=e=>!e||e==="?"?"":e.startsWith("?")?e:"?"+e,pv=e=>!e||e==="#"?"":e.startsWith("#")?e:"#"+e;function vv(e){return e!=null&&typeof e.status=="number"&&typeof e.statusText=="string"&&typeof e.internal=="boolean"&&"data"in e}const Qd=["post","put","patch","delete"];new Set(Qd);const mv=["get",...Qd];new Set(mv);/** + * React Router v6.23.1 + * + * Copyright (c) Remix Software Inc. + * + * This source code is licensed under the MIT license found in the + * LICENSE.md file in the root directory of this source tree. + * + * @license MIT + */function Ir(){return Ir=Object.assign?Object.assign.bind():function(e){for(var t=1;t<arguments.length;t++){var n=arguments[t];for(var r in n)Object.prototype.hasOwnProperty.call(n,r)&&(e[r]=n[r])}return e},Ir.apply(this,arguments)}const Hl=E.createContext(null),gv=E.createContext(null),us=E.createContext(null),cs=E.createContext(null),Mn=E.createContext({outlet:null,matches:[],isDataRoute:!1}),Jd=E.createContext(null);function ds(){return E.useContext(cs)!=null}function qd(){return ds()||Z(!1),E.useContext(cs).location}function Yd(e){E.useContext(us).static||E.useLayoutEffect(e)}function Xd(){let{isDataRoute:e}=E.useContext(Mn);return e?jv():yv()}function yv(){ds()||Z(!1);let e=E.useContext(Hl),{basename:t,future:n,navigator:r}=E.useContext(us),{matches:i}=E.useContext(Mn),{pathname:s}=qd(),o=JSON.stringify(cv(i,n.v7_relativeSplatPath)),l=E.useRef(!1);return Yd(()=>{l.current=!0}),E.useCallback(function(u,c){if(c===void 0&&(c={}),!l.current)return;if(typeof u=="number"){r.go(u);return}let d=dv(u,JSON.parse(o),s,c.relative==="path");e==null&&t!=="/"&&(d.pathname=d.pathname==="/"?t:Gt([t,d.pathname])),(c.replace?r.replace:r.push)(d,c.state,c)},[t,r,o,s,e])}function wv(e,t){return _v(e,t)}function _v(e,t,n,r){ds()||Z(!1);let{navigator:i}=E.useContext(us),{matches:s}=E.useContext(Mn),o=s[s.length-1],l=o?o.params:{};o&&o.pathname;let a=o?o.pathnameBase:"/";o&&o.route;let u=qd(),c;if(t){var d;let _=typeof t=="string"?Fn(t):t;a==="/"||(d=_.pathname)!=null&&d.startsWith(a)||Z(!1),c=_}else c=u;let h=c.pathname||"/",m=h;if(a!=="/"){let _=a.replace(/^\//,"").split("/");m="/"+h.replace(/^\//,"").split("/").slice(_.length).join("/")}let g=Gp(e,{pathname:m}),y=xv(g&&g.map(_=>Object.assign({},_,{params:Object.assign({},l,_.params),pathname:Gt([a,i.encodeLocation?i.encodeLocation(_.pathname).pathname:_.pathname]),pathnameBase:_.pathnameBase==="/"?a:Gt([a,i.encodeLocation?i.encodeLocation(_.pathnameBase).pathname:_.pathnameBase])})),s,n,r);return t&&y?E.createElement(cs.Provider,{value:{location:Ir({pathname:"/",search:"",hash:"",state:null,key:"default"},c),navigationType:_t.Pop}},y):y}function Sv(){let e=Rv(),t=vv(e)?e.status+" "+e.statusText:e instanceof Error?e.message:JSON.stringify(e),n=e instanceof Error?e.stack:null,i={padding:"0.5rem",backgroundColor:"rgba(200,200,200, 0.5)"};return E.createElement(E.Fragment,null,E.createElement("h2",null,"Unexpected Application Error!"),E.createElement("h3",{style:{fontStyle:"italic"}},t),n?E.createElement("pre",{style:i},n):null,null)}const kv=E.createElement(Sv,null);class Ev extends E.Component{constructor(t){super(t),this.state={location:t.location,revalidation:t.revalidation,error:t.error}}static getDerivedStateFromError(t){return{error:t}}static getDerivedStateFromProps(t,n){return n.location!==t.location||n.revalidation!=="idle"&&t.revalidation==="idle"?{error:t.error,location:t.location,revalidation:t.revalidation}:{error:t.error!==void 0?t.error:n.error,location:n.location,revalidation:t.revalidation||n.revalidation}}componentDidCatch(t,n){console.error("React Router caught the following error during render",t,n)}render(){return this.state.error!==void 0?E.createElement(Mn.Provider,{value:this.props.routeContext},E.createElement(Jd.Provider,{value:this.state.error,children:this.props.component})):this.props.children}}function Cv(e){let{routeContext:t,match:n,children:r}=e,i=E.useContext(Hl);return i&&i.static&&i.staticContext&&(n.route.errorElement||n.route.ErrorBoundary)&&(i.staticContext._deepestRenderedBoundaryId=n.route.id),E.createElement(Mn.Provider,{value:t},r)}function xv(e,t,n,r){var i;if(t===void 0&&(t=[]),n===void 0&&(n=null),r===void 0&&(r=null),e==null){var s;if((s=n)!=null&&s.errors)e=n.matches;else return null}let o=e,l=(i=n)==null?void 0:i.errors;if(l!=null){let c=o.findIndex(d=>d.route.id&&(l==null?void 0:l[d.route.id])!==void 0);c>=0||Z(!1),o=o.slice(0,Math.min(o.length,c+1))}let a=!1,u=-1;if(n&&r&&r.v7_partialHydration)for(let c=0;c<o.length;c++){let d=o[c];if((d.route.HydrateFallback||d.route.hydrateFallbackElement)&&(u=c),d.route.id){let{loaderData:h,errors:m}=n,g=d.route.loader&&h[d.route.id]===void 0&&(!m||m[d.route.id]===void 0);if(d.route.lazy||g){a=!0,u>=0?o=o.slice(0,u+1):o=[o[0]];break}}}return o.reduceRight((c,d,h)=>{let m,g=!1,y=null,_=null;n&&(m=l&&d.route.id?l[d.route.id]:void 0,y=d.route.errorElement||kv,a&&(u<0&&h===0?(g=!0,_=null):u===h&&(g=!0,_=d.route.hydrateFallbackElement||null)));let p=t.concat(o.slice(0,h+1)),f=()=>{let v;return m?v=y:g?v=_:d.route.Component?v=E.createElement(d.route.Component,null):d.route.element?v=d.route.element:v=c,E.createElement(Cv,{match:d,routeContext:{outlet:c,matches:p,isDataRoute:n!=null},children:v})};return n&&(d.route.ErrorBoundary||d.route.errorElement||h===0)?E.createElement(Ev,{location:n.location,revalidation:n.revalidation,component:y,error:m,children:f(),routeContext:{outlet:null,matches:p,isDataRoute:!0}}):f()},null)}var Zd=function(e){return e.UseBlocker="useBlocker",e.UseRevalidator="useRevalidator",e.UseNavigateStable="useNavigate",e}(Zd||{}),Wi=function(e){return e.UseBlocker="useBlocker",e.UseLoaderData="useLoaderData",e.UseActionData="useActionData",e.UseRouteError="useRouteError",e.UseNavigation="useNavigation",e.UseRouteLoaderData="useRouteLoaderData",e.UseMatches="useMatches",e.UseRevalidator="useRevalidator",e.UseNavigateStable="useNavigate",e.UseRouteId="useRouteId",e}(Wi||{});function Pv(e){let t=E.useContext(Hl);return t||Z(!1),t}function Tv(e){let t=E.useContext(gv);return t||Z(!1),t}function Ov(e){let t=E.useContext(Mn);return t||Z(!1),t}function ef(e){let t=Ov(),n=t.matches[t.matches.length-1];return n.route.id||Z(!1),n.route.id}function Rv(){var e;let t=E.useContext(Jd),n=Tv(Wi.UseRouteError),r=ef(Wi.UseRouteError);return t!==void 0?t:(e=n.errors)==null?void 0:e[r]}function jv(){let{router:e}=Pv(Zd.UseNavigateStable),t=ef(Wi.UseNavigateStable),n=E.useRef(!1);return Yd(()=>{n.current=!0}),E.useCallback(function(i,s){s===void 0&&(s={}),n.current&&(typeof i=="number"?e.navigate(i):e.navigate(i,Ir({fromRouteId:t},s)))},[e,t])}function _i(e){Z(!1)}function Lv(e){let{basename:t="/",children:n=null,location:r,navigationType:i=_t.Pop,navigator:s,static:o=!1,future:l}=e;ds()&&Z(!1);let a=t.replace(/^\/*/,"/"),u=E.useMemo(()=>({basename:a,navigator:s,static:o,future:Ir({v7_relativeSplatPath:!1},l)}),[a,l,s,o]);typeof r=="string"&&(r=Fn(r));let{pathname:c="/",search:d="",hash:h="",state:m=null,key:g="default"}=r,y=E.useMemo(()=>{let _=Gd(c,a);return _==null?null:{location:{pathname:_,search:d,hash:h,state:m,key:g},navigationType:i}},[a,c,d,h,m,g,i]);return y==null?null:E.createElement(us.Provider,{value:u},E.createElement(cs.Provider,{children:n,value:y}))}function Iv(e){let{children:t,location:n}=e;return wv(Vo(t),n)}new Promise(()=>{});function Vo(e,t){t===void 0&&(t=[]);let n=[];return E.Children.forEach(e,(r,i)=>{if(!E.isValidElement(r))return;let s=[...t,i];if(r.type===E.Fragment){n.push.apply(n,Vo(r.props.children,s));return}r.type!==_i&&Z(!1),!r.props.index||!r.props.children||Z(!1);let o={id:r.props.id||s.join("-"),caseSensitive:r.props.caseSensitive,element:r.props.element,Component:r.props.Component,index:r.props.index,path:r.props.path,loader:r.props.loader,action:r.props.action,errorElement:r.props.errorElement,ErrorBoundary:r.props.ErrorBoundary,hasErrorBoundary:r.props.ErrorBoundary!=null||r.props.errorElement!=null,shouldRevalidate:r.props.shouldRevalidate,handle:r.props.handle,lazy:r.props.lazy};r.props.children&&(o.children=Vo(r.props.children,s)),n.push(o)}),n}/** + * React Router DOM v6.23.1 + * + * Copyright (c) Remix Software Inc. + * + * This source code is licensed under the MIT license found in the + * LICENSE.md file in the root directory of this source tree. + * + * @license MIT + */const $v="6";try{window.__reactRouterVersion=$v}catch{}const Nv="startTransition",cu=If[Nv];function Av(e){let{basename:t,children:n,future:r,window:i}=e,s=E.useRef();s.current==null&&(s.current=Hp({window:i,v5Compat:!0}));let o=s.current,[l,a]=E.useState({action:o.action,location:o.location}),{v7_startTransition:u}=r||{},c=E.useCallback(d=>{u&&cu?cu(()=>a(d)):a(d)},[a,u]);return E.useLayoutEffect(()=>o.listen(c),[o,c]),E.createElement(Lv,{basename:t,children:n,location:l.location,navigationType:l.action,navigator:o,future:r})}var du;(function(e){e.UseScrollRestoration="useScrollRestoration",e.UseSubmit="useSubmit",e.UseSubmitFetcher="useSubmitFetcher",e.UseFetcher="useFetcher",e.useViewTransitionState="useViewTransitionState"})(du||(du={}));var fu;(function(e){e.UseFetcher="useFetcher",e.UseFetchers="useFetchers",e.UseScrollRestoration="useScrollRestoration"})(fu||(fu={}));const Uv="modulepreload",Dv=function(e,t){return new URL(e,t).href},hu={},Nn=function(t,n,r){let i=Promise.resolve();if(n&&n.length>0){const s=document.getElementsByTagName("link"),o=document.querySelector("meta[property=csp-nonce]"),l=(o==null?void 0:o.nonce)||(o==null?void 0:o.getAttribute("nonce"));i=Promise.all(n.map(a=>{if(a=Dv(a,r),a in hu)return;hu[a]=!0;const u=a.endsWith(".css"),c=u?'[rel="stylesheet"]':"";if(!!r)for(let m=s.length-1;m>=0;m--){const g=s[m];if(g.href===a&&(!u||g.rel==="stylesheet"))return}else if(document.querySelector(`link[href="${a}"]${c}`))return;const h=document.createElement("link");if(h.rel=u?"stylesheet":Uv,u||(h.as="script",h.crossOrigin=""),h.href=a,l&&h.setAttribute("nonce",l),document.head.appendChild(h),u)return new Promise((m,g)=>{h.addEventListener("load",m),h.addEventListener("error",()=>g(new Error(`Unable to preload CSS for ${a}`)))})}))}return i.then(()=>t()).catch(s=>{const o=new Event("vite:preloadError",{cancelable:!0});if(o.payload=s,window.dispatchEvent(o),!o.defaultPrevented)throw s})},zv=e=>{let t;return e?t=e:typeof fetch>"u"?t=(...n)=>Nn(()=>Promise.resolve().then(()=>Fr),void 0,import.meta.url).then(({default:r})=>r(...n)):t=fetch,(...n)=>t(...n)};class Wl extends Error{constructor(t,n="FunctionsError",r){super(t),this.name=n,this.context=r}}class Fv extends Wl{constructor(t){super("Failed to send a request to the Edge Function","FunctionsFetchError",t)}}class Mv extends Wl{constructor(t){super("Relay Error invoking the Edge Function","FunctionsRelayError",t)}}class bv extends Wl{constructor(t){super("Edge Function returned a non-2xx status code","FunctionsHttpError",t)}}var Ho;(function(e){e.Any="any",e.ApNortheast1="ap-northeast-1",e.ApNortheast2="ap-northeast-2",e.ApSouth1="ap-south-1",e.ApSoutheast1="ap-southeast-1",e.ApSoutheast2="ap-southeast-2",e.CaCentral1="ca-central-1",e.EuCentral1="eu-central-1",e.EuWest1="eu-west-1",e.EuWest2="eu-west-2",e.EuWest3="eu-west-3",e.SaEast1="sa-east-1",e.UsEast1="us-east-1",e.UsWest1="us-west-1",e.UsWest2="us-west-2"})(Ho||(Ho={}));var Bv=function(e,t,n,r){function i(s){return s instanceof n?s:new n(function(o){o(s)})}return new(n||(n=Promise))(function(s,o){function l(c){try{u(r.next(c))}catch(d){o(d)}}function a(c){try{u(r.throw(c))}catch(d){o(d)}}function u(c){c.done?s(c.value):i(c.value).then(l,a)}u((r=r.apply(e,t||[])).next())})};class Vv{constructor(t,{headers:n={},customFetch:r,region:i=Ho.Any}={}){this.url=t,this.headers=n,this.region=i,this.fetch=zv(r)}setAuth(t){this.headers.Authorization=`Bearer ${t}`}invoke(t,n={}){var r;return Bv(this,void 0,void 0,function*(){try{const{headers:i,method:s,body:o}=n;let l={},{region:a}=n;a||(a=this.region),a&&a!=="any"&&(l["x-region"]=a);let u;o&&(i&&!Object.prototype.hasOwnProperty.call(i,"Content-Type")||!i)&&(typeof Blob<"u"&&o instanceof Blob||o instanceof ArrayBuffer?(l["Content-Type"]="application/octet-stream",u=o):typeof o=="string"?(l["Content-Type"]="text/plain",u=o):typeof FormData<"u"&&o instanceof FormData?u=o:(l["Content-Type"]="application/json",u=JSON.stringify(o)));const c=yield this.fetch(`${this.url}/${t}`,{method:s||"POST",headers:Object.assign(Object.assign(Object.assign({},l),this.headers),i),body:u}).catch(g=>{throw new Fv(g)}),d=c.headers.get("x-relay-error");if(d&&d==="true")throw new Mv(c);if(!c.ok)throw new bv(c);let h=((r=c.headers.get("Content-Type"))!==null&&r!==void 0?r:"text/plain").split(";")[0].trim(),m;return h==="application/json"?m=yield c.json():h==="application/octet-stream"?m=yield c.blob():h==="text/event-stream"?m=c:h==="multipart/form-data"?m=yield c.formData():m=yield c.text(),{data:m,error:null}}catch(i){return{data:null,error:i}}})}}var Hv=function(){if(typeof self<"u")return self;if(typeof window<"u")return window;if(typeof global<"u")return global;throw new Error("unable to locate global object")},An=Hv();const Wv=An.fetch,Kl=An.fetch.bind(An),tf=An.Headers,Kv=An.Request,Gv=An.Response,Fr=Object.freeze(Object.defineProperty({__proto__:null,Headers:tf,Request:Kv,Response:Gv,default:Kl,fetch:Wv},Symbol.toStringTag,{value:"Module"}));class Qv extends Error{constructor(t){super(t.message),this.name="PostgrestError",this.details=t.details,this.hint=t.hint,this.code=t.code}}class Jv{constructor(t){this.shouldThrowOnError=!1,this.method=t.method,this.url=t.url,this.headers=t.headers,this.schema=t.schema,this.body=t.body,this.shouldThrowOnError=t.shouldThrowOnError,this.signal=t.signal,this.isMaybeSingle=t.isMaybeSingle,t.fetch?this.fetch=t.fetch:typeof fetch>"u"?this.fetch=Kl:this.fetch=fetch}throwOnError(){return this.shouldThrowOnError=!0,this}then(t,n){this.schema===void 0||(["GET","HEAD"].includes(this.method)?this.headers["Accept-Profile"]=this.schema:this.headers["Content-Profile"]=this.schema),this.method!=="GET"&&this.method!=="HEAD"&&(this.headers["Content-Type"]="application/json");const r=this.fetch;let i=r(this.url.toString(),{method:this.method,headers:this.headers,body:JSON.stringify(this.body),signal:this.signal}).then(async s=>{var o,l,a;let u=null,c=null,d=null,h=s.status,m=s.statusText;if(s.ok){if(this.method!=="HEAD"){const p=await s.text();p===""||(this.headers.Accept==="text/csv"||this.headers.Accept&&this.headers.Accept.includes("application/vnd.pgrst.plan+text")?c=p:c=JSON.parse(p))}const y=(o=this.headers.Prefer)===null||o===void 0?void 0:o.match(/count=(exact|planned|estimated)/),_=(l=s.headers.get("content-range"))===null||l===void 0?void 0:l.split("/");y&&_&&_.length>1&&(d=parseInt(_[1])),this.isMaybeSingle&&this.method==="GET"&&Array.isArray(c)&&(c.length>1?(u={code:"PGRST116",details:`Results contain ${c.length} rows, application/vnd.pgrst.object+json requires 1 row`,hint:null,message:"JSON object requested, multiple (or no) rows returned"},c=null,d=null,h=406,m="Not Acceptable"):c.length===1?c=c[0]:c=null)}else{const y=await s.text();try{u=JSON.parse(y),Array.isArray(u)&&s.status===404&&(c=[],u=null,h=200,m="OK")}catch{s.status===404&&y===""?(h=204,m="No Content"):u={message:y}}if(u&&this.isMaybeSingle&&(!((a=u==null?void 0:u.details)===null||a===void 0)&&a.includes("0 rows"))&&(u=null,h=200,m="OK"),u&&this.shouldThrowOnError)throw new Qv(u)}return{error:u,data:c,count:d,status:h,statusText:m}});return this.shouldThrowOnError||(i=i.catch(s=>{var o,l,a;return{error:{message:`${(o=s==null?void 0:s.name)!==null&&o!==void 0?o:"FetchError"}: ${s==null?void 0:s.message}`,details:`${(l=s==null?void 0:s.stack)!==null&&l!==void 0?l:""}`,hint:"",code:`${(a=s==null?void 0:s.code)!==null&&a!==void 0?a:""}`},data:null,count:null,status:0,statusText:""}})),i.then(t,n)}}class qv extends Jv{select(t){let n=!1;const r=(t??"*").split("").map(i=>/\s/.test(i)&&!n?"":(i==='"'&&(n=!n),i)).join("");return this.url.searchParams.set("select",r),this.headers.Prefer&&(this.headers.Prefer+=","),this.headers.Prefer+="return=representation",this}order(t,{ascending:n=!0,nullsFirst:r,foreignTable:i,referencedTable:s=i}={}){const o=s?`${s}.order`:"order",l=this.url.searchParams.get(o);return this.url.searchParams.set(o,`${l?`${l},`:""}${t}.${n?"asc":"desc"}${r===void 0?"":r?".nullsfirst":".nullslast"}`),this}limit(t,{foreignTable:n,referencedTable:r=n}={}){const i=typeof r>"u"?"limit":`${r}.limit`;return this.url.searchParams.set(i,`${t}`),this}range(t,n,{foreignTable:r,referencedTable:i=r}={}){const s=typeof i>"u"?"offset":`${i}.offset`,o=typeof i>"u"?"limit":`${i}.limit`;return this.url.searchParams.set(s,`${t}`),this.url.searchParams.set(o,`${n-t+1}`),this}abortSignal(t){return this.signal=t,this}single(){return this.headers.Accept="application/vnd.pgrst.object+json",this}maybeSingle(){return this.method==="GET"?this.headers.Accept="application/json":this.headers.Accept="application/vnd.pgrst.object+json",this.isMaybeSingle=!0,this}csv(){return this.headers.Accept="text/csv",this}geojson(){return this.headers.Accept="application/geo+json",this}explain({analyze:t=!1,verbose:n=!1,settings:r=!1,buffers:i=!1,wal:s=!1,format:o="text"}={}){var l;const a=[t?"analyze":null,n?"verbose":null,r?"settings":null,i?"buffers":null,s?"wal":null].filter(Boolean).join("|"),u=(l=this.headers.Accept)!==null&&l!==void 0?l:"application/json";return this.headers.Accept=`application/vnd.pgrst.plan+${o}; for="${u}"; options=${a};`,o==="json"?this:this}rollback(){var t;return((t=this.headers.Prefer)!==null&&t!==void 0?t:"").trim().length>0?this.headers.Prefer+=",tx=rollback":this.headers.Prefer="tx=rollback",this}returns(){return this}}class ln extends qv{eq(t,n){return this.url.searchParams.append(t,`eq.${n}`),this}neq(t,n){return this.url.searchParams.append(t,`neq.${n}`),this}gt(t,n){return this.url.searchParams.append(t,`gt.${n}`),this}gte(t,n){return this.url.searchParams.append(t,`gte.${n}`),this}lt(t,n){return this.url.searchParams.append(t,`lt.${n}`),this}lte(t,n){return this.url.searchParams.append(t,`lte.${n}`),this}like(t,n){return this.url.searchParams.append(t,`like.${n}`),this}likeAllOf(t,n){return this.url.searchParams.append(t,`like(all).{${n.join(",")}}`),this}likeAnyOf(t,n){return this.url.searchParams.append(t,`like(any).{${n.join(",")}}`),this}ilike(t,n){return this.url.searchParams.append(t,`ilike.${n}`),this}ilikeAllOf(t,n){return this.url.searchParams.append(t,`ilike(all).{${n.join(",")}}`),this}ilikeAnyOf(t,n){return this.url.searchParams.append(t,`ilike(any).{${n.join(",")}}`),this}is(t,n){return this.url.searchParams.append(t,`is.${n}`),this}in(t,n){const r=Array.from(new Set(n)).map(i=>typeof i=="string"&&new RegExp("[,()]").test(i)?`"${i}"`:`${i}`).join(",");return this.url.searchParams.append(t,`in.(${r})`),this}contains(t,n){return typeof n=="string"?this.url.searchParams.append(t,`cs.${n}`):Array.isArray(n)?this.url.searchParams.append(t,`cs.{${n.join(",")}}`):this.url.searchParams.append(t,`cs.${JSON.stringify(n)}`),this}containedBy(t,n){return typeof n=="string"?this.url.searchParams.append(t,`cd.${n}`):Array.isArray(n)?this.url.searchParams.append(t,`cd.{${n.join(",")}}`):this.url.searchParams.append(t,`cd.${JSON.stringify(n)}`),this}rangeGt(t,n){return this.url.searchParams.append(t,`sr.${n}`),this}rangeGte(t,n){return this.url.searchParams.append(t,`nxl.${n}`),this}rangeLt(t,n){return this.url.searchParams.append(t,`sl.${n}`),this}rangeLte(t,n){return this.url.searchParams.append(t,`nxr.${n}`),this}rangeAdjacent(t,n){return this.url.searchParams.append(t,`adj.${n}`),this}overlaps(t,n){return typeof n=="string"?this.url.searchParams.append(t,`ov.${n}`):this.url.searchParams.append(t,`ov.{${n.join(",")}}`),this}textSearch(t,n,{config:r,type:i}={}){let s="";i==="plain"?s="pl":i==="phrase"?s="ph":i==="websearch"&&(s="w");const o=r===void 0?"":`(${r})`;return this.url.searchParams.append(t,`${s}fts${o}.${n}`),this}match(t){return Object.entries(t).forEach(([n,r])=>{this.url.searchParams.append(n,`eq.${r}`)}),this}not(t,n,r){return this.url.searchParams.append(t,`not.${n}.${r}`),this}or(t,{foreignTable:n,referencedTable:r=n}={}){const i=r?`${r}.or`:"or";return this.url.searchParams.append(i,`(${t})`),this}filter(t,n,r){return this.url.searchParams.append(t,`${n}.${r}`),this}}class Yv{constructor(t,{headers:n={},schema:r,fetch:i}){this.url=t,this.headers=n,this.schema=r,this.fetch=i}select(t,{head:n=!1,count:r}={}){const i=n?"HEAD":"GET";let s=!1;const o=(t??"*").split("").map(l=>/\s/.test(l)&&!s?"":(l==='"'&&(s=!s),l)).join("");return this.url.searchParams.set("select",o),r&&(this.headers.Prefer=`count=${r}`),new ln({method:i,url:this.url,headers:this.headers,schema:this.schema,fetch:this.fetch,allowEmpty:!1})}insert(t,{count:n,defaultToNull:r=!0}={}){const i="POST",s=[];if(this.headers.Prefer&&s.push(this.headers.Prefer),n&&s.push(`count=${n}`),r||s.push("missing=default"),this.headers.Prefer=s.join(","),Array.isArray(t)){const o=t.reduce((l,a)=>l.concat(Object.keys(a)),[]);if(o.length>0){const l=[...new Set(o)].map(a=>`"${a}"`);this.url.searchParams.set("columns",l.join(","))}}return new ln({method:i,url:this.url,headers:this.headers,schema:this.schema,body:t,fetch:this.fetch,allowEmpty:!1})}upsert(t,{onConflict:n,ignoreDuplicates:r=!1,count:i,defaultToNull:s=!0}={}){const o="POST",l=[`resolution=${r?"ignore":"merge"}-duplicates`];if(n!==void 0&&this.url.searchParams.set("on_conflict",n),this.headers.Prefer&&l.push(this.headers.Prefer),i&&l.push(`count=${i}`),s||l.push("missing=default"),this.headers.Prefer=l.join(","),Array.isArray(t)){const a=t.reduce((u,c)=>u.concat(Object.keys(c)),[]);if(a.length>0){const u=[...new Set(a)].map(c=>`"${c}"`);this.url.searchParams.set("columns",u.join(","))}}return new ln({method:o,url:this.url,headers:this.headers,schema:this.schema,body:t,fetch:this.fetch,allowEmpty:!1})}update(t,{count:n}={}){const r="PATCH",i=[];return this.headers.Prefer&&i.push(this.headers.Prefer),n&&i.push(`count=${n}`),this.headers.Prefer=i.join(","),new ln({method:r,url:this.url,headers:this.headers,schema:this.schema,body:t,fetch:this.fetch,allowEmpty:!1})}delete({count:t}={}){const n="DELETE",r=[];return t&&r.push(`count=${t}`),this.headers.Prefer&&r.unshift(this.headers.Prefer),this.headers.Prefer=r.join(","),new ln({method:n,url:this.url,headers:this.headers,schema:this.schema,fetch:this.fetch,allowEmpty:!1})}}const Xv="1.15.2",Zv={"X-Client-Info":`postgrest-js/${Xv}`};class Gl{constructor(t,{headers:n={},schema:r,fetch:i}={}){this.url=t,this.headers=Object.assign(Object.assign({},Zv),n),this.schemaName=r,this.fetch=i}from(t){const n=new URL(`${this.url}/${t}`);return new Yv(n,{headers:Object.assign({},this.headers),schema:this.schemaName,fetch:this.fetch})}schema(t){return new Gl(this.url,{headers:this.headers,schema:t,fetch:this.fetch})}rpc(t,n={},{head:r=!1,get:i=!1,count:s}={}){let o;const l=new URL(`${this.url}/rpc/${t}`);let a;r||i?(o=r?"HEAD":"GET",Object.entries(n).filter(([c,d])=>d!==void 0).map(([c,d])=>[c,Array.isArray(d)?`{${d.join(",")}}`:`${d}`]).forEach(([c,d])=>{l.searchParams.append(c,d)})):(o="POST",a=n);const u=Object.assign({},this.headers);return s&&(u.Prefer=`count=${s}`),new ln({method:o,url:l,headers:u,schema:this.schemaName,body:a,fetch:this.fetch,allowEmpty:!1})}}const em="2.9.5",tm={"X-Client-Info":`realtime-js/${em}`},nm="1.0.0",nf=1e4,rm=1e3;var Pn;(function(e){e[e.connecting=0]="connecting",e[e.open=1]="open",e[e.closing=2]="closing",e[e.closed=3]="closed"})(Pn||(Pn={}));var Se;(function(e){e.closed="closed",e.errored="errored",e.joined="joined",e.joining="joining",e.leaving="leaving"})(Se||(Se={}));var Me;(function(e){e.close="phx_close",e.error="phx_error",e.join="phx_join",e.reply="phx_reply",e.leave="phx_leave",e.access_token="access_token"})(Me||(Me={}));var Wo;(function(e){e.websocket="websocket"})(Wo||(Wo={}));var bt;(function(e){e.Connecting="connecting",e.Open="open",e.Closing="closing",e.Closed="closed"})(bt||(bt={}));class rf{constructor(t,n){this.callback=t,this.timerCalc=n,this.timer=void 0,this.tries=0,this.callback=t,this.timerCalc=n}reset(){this.tries=0,clearTimeout(this.timer)}scheduleTimeout(){clearTimeout(this.timer),this.timer=setTimeout(()=>{this.tries=this.tries+1,this.callback()},this.timerCalc(this.tries+1))}}class im{constructor(){this.HEADER_LENGTH=1}decode(t,n){return t.constructor===ArrayBuffer?n(this._binaryDecode(t)):n(typeof t=="string"?JSON.parse(t):{})}_binaryDecode(t){const n=new DataView(t),r=new TextDecoder;return this._decodeBroadcast(t,n,r)}_decodeBroadcast(t,n,r){const i=n.getUint8(1),s=n.getUint8(2);let o=this.HEADER_LENGTH+2;const l=r.decode(t.slice(o,o+i));o=o+i;const a=r.decode(t.slice(o,o+s));o=o+s;const u=JSON.parse(r.decode(t.slice(o,t.byteLength)));return{ref:null,topic:l,event:a,payload:u}}}class Bs{constructor(t,n,r={},i=nf){this.channel=t,this.event=n,this.payload=r,this.timeout=i,this.sent=!1,this.timeoutTimer=void 0,this.ref="",this.receivedResp=null,this.recHooks=[],this.refEvent=null}resend(t){this.timeout=t,this._cancelRefEvent(),this.ref="",this.refEvent=null,this.receivedResp=null,this.sent=!1,this.send()}send(){this._hasReceived("timeout")||(this.startTimeout(),this.sent=!0,this.channel.socket.push({topic:this.channel.topic,event:this.event,payload:this.payload,ref:this.ref,join_ref:this.channel._joinRef()}))}updatePayload(t){this.payload=Object.assign(Object.assign({},this.payload),t)}receive(t,n){var r;return this._hasReceived(t)&&n((r=this.receivedResp)===null||r===void 0?void 0:r.response),this.recHooks.push({status:t,callback:n}),this}startTimeout(){if(this.timeoutTimer)return;this.ref=this.channel.socket._makeRef(),this.refEvent=this.channel._replyEventName(this.ref);const t=n=>{this._cancelRefEvent(),this._cancelTimeout(),this.receivedResp=n,this._matchReceive(n)};this.channel._on(this.refEvent,{},t),this.timeoutTimer=setTimeout(()=>{this.trigger("timeout",{})},this.timeout)}trigger(t,n){this.refEvent&&this.channel._trigger(this.refEvent,{status:t,response:n})}destroy(){this._cancelRefEvent(),this._cancelTimeout()}_cancelRefEvent(){this.refEvent&&this.channel._off(this.refEvent,{})}_cancelTimeout(){clearTimeout(this.timeoutTimer),this.timeoutTimer=void 0}_matchReceive({status:t,response:n}){this.recHooks.filter(r=>r.status===t).forEach(r=>r.callback(n))}_hasReceived(t){return this.receivedResp&&this.receivedResp.status===t}}var pu;(function(e){e.SYNC="sync",e.JOIN="join",e.LEAVE="leave"})(pu||(pu={}));class fr{constructor(t,n){this.channel=t,this.state={},this.pendingDiffs=[],this.joinRef=null,this.caller={onJoin:()=>{},onLeave:()=>{},onSync:()=>{}};const r=(n==null?void 0:n.events)||{state:"presence_state",diff:"presence_diff"};this.channel._on(r.state,{},i=>{const{onJoin:s,onLeave:o,onSync:l}=this.caller;this.joinRef=this.channel._joinRef(),this.state=fr.syncState(this.state,i,s,o),this.pendingDiffs.forEach(a=>{this.state=fr.syncDiff(this.state,a,s,o)}),this.pendingDiffs=[],l()}),this.channel._on(r.diff,{},i=>{const{onJoin:s,onLeave:o,onSync:l}=this.caller;this.inPendingSyncState()?this.pendingDiffs.push(i):(this.state=fr.syncDiff(this.state,i,s,o),l())}),this.onJoin((i,s,o)=>{this.channel._trigger("presence",{event:"join",key:i,currentPresences:s,newPresences:o})}),this.onLeave((i,s,o)=>{this.channel._trigger("presence",{event:"leave",key:i,currentPresences:s,leftPresences:o})}),this.onSync(()=>{this.channel._trigger("presence",{event:"sync"})})}static syncState(t,n,r,i){const s=this.cloneDeep(t),o=this.transformState(n),l={},a={};return this.map(s,(u,c)=>{o[u]||(a[u]=c)}),this.map(o,(u,c)=>{const d=s[u];if(d){const h=c.map(_=>_.presence_ref),m=d.map(_=>_.presence_ref),g=c.filter(_=>m.indexOf(_.presence_ref)<0),y=d.filter(_=>h.indexOf(_.presence_ref)<0);g.length>0&&(l[u]=g),y.length>0&&(a[u]=y)}else l[u]=c}),this.syncDiff(s,{joins:l,leaves:a},r,i)}static syncDiff(t,n,r,i){const{joins:s,leaves:o}={joins:this.transformState(n.joins),leaves:this.transformState(n.leaves)};return r||(r=()=>{}),i||(i=()=>{}),this.map(s,(l,a)=>{var u;const c=(u=t[l])!==null&&u!==void 0?u:[];if(t[l]=this.cloneDeep(a),c.length>0){const d=t[l].map(m=>m.presence_ref),h=c.filter(m=>d.indexOf(m.presence_ref)<0);t[l].unshift(...h)}r(l,c,a)}),this.map(o,(l,a)=>{let u=t[l];if(!u)return;const c=a.map(d=>d.presence_ref);u=u.filter(d=>c.indexOf(d.presence_ref)<0),t[l]=u,i(l,u,a),u.length===0&&delete t[l]}),t}static map(t,n){return Object.getOwnPropertyNames(t).map(r=>n(r,t[r]))}static transformState(t){return t=this.cloneDeep(t),Object.getOwnPropertyNames(t).reduce((n,r)=>{const i=t[r];return"metas"in i?n[r]=i.metas.map(s=>(s.presence_ref=s.phx_ref,delete s.phx_ref,delete s.phx_ref_prev,s)):n[r]=i,n},{})}static cloneDeep(t){return JSON.parse(JSON.stringify(t))}onJoin(t){this.caller.onJoin=t}onLeave(t){this.caller.onLeave=t}onSync(t){this.caller.onSync=t}inPendingSyncState(){return!this.joinRef||this.joinRef!==this.channel._joinRef()}}var D;(function(e){e.abstime="abstime",e.bool="bool",e.date="date",e.daterange="daterange",e.float4="float4",e.float8="float8",e.int2="int2",e.int4="int4",e.int4range="int4range",e.int8="int8",e.int8range="int8range",e.json="json",e.jsonb="jsonb",e.money="money",e.numeric="numeric",e.oid="oid",e.reltime="reltime",e.text="text",e.time="time",e.timestamp="timestamp",e.timestamptz="timestamptz",e.timetz="timetz",e.tsrange="tsrange",e.tstzrange="tstzrange"})(D||(D={}));const vu=(e,t,n={})=>{var r;const i=(r=n.skipTypes)!==null&&r!==void 0?r:[];return Object.keys(t).reduce((s,o)=>(s[o]=sm(o,e,t,i),s),{})},sm=(e,t,n,r)=>{const i=t.find(l=>l.name===e),s=i==null?void 0:i.type,o=n[e];return s&&!r.includes(s)?sf(s,o):Ko(o)},sf=(e,t)=>{if(e.charAt(0)==="_"){const n=e.slice(1,e.length);return um(t,n)}switch(e){case D.bool:return om(t);case D.float4:case D.float8:case D.int2:case D.int4:case D.int8:case D.numeric:case D.oid:return lm(t);case D.json:case D.jsonb:return am(t);case D.timestamp:return cm(t);case D.abstime:case D.date:case D.daterange:case D.int4range:case D.int8range:case D.money:case D.reltime:case D.text:case D.time:case D.timestamptz:case D.timetz:case D.tsrange:case D.tstzrange:return Ko(t);default:return Ko(t)}},Ko=e=>e,om=e=>{switch(e){case"t":return!0;case"f":return!1;default:return e}},lm=e=>{if(typeof e=="string"){const t=parseFloat(e);if(!Number.isNaN(t))return t}return e},am=e=>{if(typeof e=="string")try{return JSON.parse(e)}catch(t){return console.log(`JSON parse error: ${t}`),e}return e},um=(e,t)=>{if(typeof e!="string")return e;const n=e.length-1,r=e[n];if(e[0]==="{"&&r==="}"){let s;const o=e.slice(1,n);try{s=JSON.parse("["+o+"]")}catch{s=o?o.split(","):[]}return s.map(l=>sf(t,l))}return e},cm=e=>typeof e=="string"?e.replace(" ","T"):e;var mu;(function(e){e.ALL="*",e.INSERT="INSERT",e.UPDATE="UPDATE",e.DELETE="DELETE"})(mu||(mu={}));var gu;(function(e){e.BROADCAST="broadcast",e.PRESENCE="presence",e.POSTGRES_CHANGES="postgres_changes"})(gu||(gu={}));var yu;(function(e){e.SUBSCRIBED="SUBSCRIBED",e.TIMED_OUT="TIMED_OUT",e.CLOSED="CLOSED",e.CHANNEL_ERROR="CHANNEL_ERROR"})(yu||(yu={}));class Ql{constructor(t,n={config:{}},r){this.topic=t,this.params=n,this.socket=r,this.bindings={},this.state=Se.closed,this.joinedOnce=!1,this.pushBuffer=[],this.subTopic=t.replace(/^realtime:/i,""),this.params.config=Object.assign({broadcast:{ack:!1,self:!1},presence:{key:""}},n.config),this.timeout=this.socket.timeout,this.joinPush=new Bs(this,Me.join,this.params,this.timeout),this.rejoinTimer=new rf(()=>this._rejoinUntilConnected(),this.socket.reconnectAfterMs),this.joinPush.receive("ok",()=>{this.state=Se.joined,this.rejoinTimer.reset(),this.pushBuffer.forEach(i=>i.send()),this.pushBuffer=[]}),this._onClose(()=>{this.rejoinTimer.reset(),this.socket.log("channel",`close ${this.topic} ${this._joinRef()}`),this.state=Se.closed,this.socket._remove(this)}),this._onError(i=>{this._isLeaving()||this._isClosed()||(this.socket.log("channel",`error ${this.topic}`,i),this.state=Se.errored,this.rejoinTimer.scheduleTimeout())}),this.joinPush.receive("timeout",()=>{this._isJoining()&&(this.socket.log("channel",`timeout ${this.topic}`,this.joinPush.timeout),this.state=Se.errored,this.rejoinTimer.scheduleTimeout())}),this._on(Me.reply,{},(i,s)=>{this._trigger(this._replyEventName(s),i)}),this.presence=new fr(this),this.broadcastEndpointURL=this._broadcastEndpointURL()}subscribe(t,n=this.timeout){var r,i;if(this.socket.isConnected()||this.socket.connect(),this.joinedOnce)throw"tried to subscribe multiple times. 'subscribe' can only be called a single time per channel instance";{const{config:{broadcast:s,presence:o}}=this.params;this._onError(u=>t&&t("CHANNEL_ERROR",u)),this._onClose(()=>t&&t("CLOSED"));const l={},a={broadcast:s,presence:o,postgres_changes:(i=(r=this.bindings.postgres_changes)===null||r===void 0?void 0:r.map(u=>u.filter))!==null&&i!==void 0?i:[]};this.socket.accessToken&&(l.access_token=this.socket.accessToken),this.updateJoinPayload(Object.assign({config:a},l)),this.joinedOnce=!0,this._rejoin(n),this.joinPush.receive("ok",({postgres_changes:u})=>{var c;if(this.socket.accessToken&&this.socket.setAuth(this.socket.accessToken),u===void 0){t&&t("SUBSCRIBED");return}else{const d=this.bindings.postgres_changes,h=(c=d==null?void 0:d.length)!==null&&c!==void 0?c:0,m=[];for(let g=0;g<h;g++){const y=d[g],{filter:{event:_,schema:p,table:f,filter:v}}=y,w=u&&u[g];if(w&&w.event===_&&w.schema===p&&w.table===f&&w.filter===v)m.push(Object.assign(Object.assign({},y),{id:w.id}));else{this.unsubscribe(),t&&t("CHANNEL_ERROR",new Error("mismatch between server and client bindings for postgres changes"));return}}this.bindings.postgres_changes=m,t&&t("SUBSCRIBED");return}}).receive("error",u=>{t&&t("CHANNEL_ERROR",new Error(JSON.stringify(Object.values(u).join(", ")||"error")))}).receive("timeout",()=>{t&&t("TIMED_OUT")})}return this}presenceState(){return this.presence.state}async track(t,n={}){return await this.send({type:"presence",event:"track",payload:t},n.timeout||this.timeout)}async untrack(t={}){return await this.send({type:"presence",event:"untrack"},t)}on(t,n,r){return this._on(t,n,r)}async send(t,n={}){var r,i;if(!this._canPush()&&t.type==="broadcast"){const{event:s,payload:o}=t,l={method:"POST",headers:{apikey:(r=this.socket.apiKey)!==null&&r!==void 0?r:"","Content-Type":"application/json"},body:JSON.stringify({messages:[{topic:this.subTopic,event:s,payload:o}]})};try{return(await this._fetchWithTimeout(this.broadcastEndpointURL,l,(i=n.timeout)!==null&&i!==void 0?i:this.timeout)).ok?"ok":"error"}catch(a){return a.name==="AbortError"?"timed out":"error"}}else return new Promise(s=>{var o,l,a;const u=this._push(t.type,t,n.timeout||this.timeout);t.type==="broadcast"&&!(!((a=(l=(o=this.params)===null||o===void 0?void 0:o.config)===null||l===void 0?void 0:l.broadcast)===null||a===void 0)&&a.ack)&&s("ok"),u.receive("ok",()=>s("ok")),u.receive("error",()=>s("error")),u.receive("timeout",()=>s("timed out"))})}updateJoinPayload(t){this.joinPush.updatePayload(t)}unsubscribe(t=this.timeout){this.state=Se.leaving;const n=()=>{this.socket.log("channel",`leave ${this.topic}`),this._trigger(Me.close,"leave",this._joinRef())};return this.rejoinTimer.reset(),this.joinPush.destroy(),new Promise(r=>{const i=new Bs(this,Me.leave,{},t);i.receive("ok",()=>{n(),r("ok")}).receive("timeout",()=>{n(),r("timed out")}).receive("error",()=>{r("error")}),i.send(),this._canPush()||i.trigger("ok",{})})}_broadcastEndpointURL(){let t=this.socket.endPoint;return t=t.replace(/^ws/i,"http"),t=t.replace(/(\/socket\/websocket|\/socket|\/websocket)\/?$/i,""),t.replace(/\/+$/,"")+"/api/broadcast"}async _fetchWithTimeout(t,n,r){const i=new AbortController,s=setTimeout(()=>i.abort(),r),o=await this.socket.fetch(t,Object.assign(Object.assign({},n),{signal:i.signal}));return clearTimeout(s),o}_push(t,n,r=this.timeout){if(!this.joinedOnce)throw`tried to push '${t}' to '${this.topic}' before joining. Use channel.subscribe() before pushing events`;let i=new Bs(this,t,n,r);return this._canPush()?i.send():(i.startTimeout(),this.pushBuffer.push(i)),i}_onMessage(t,n,r){return n}_isMember(t){return this.topic===t}_joinRef(){return this.joinPush.ref}_trigger(t,n,r){var i,s;const o=t.toLocaleLowerCase(),{close:l,error:a,leave:u,join:c}=Me;if(r&&[l,a,u,c].indexOf(o)>=0&&r!==this._joinRef())return;let h=this._onMessage(o,n,r);if(n&&!h)throw"channel onMessage callbacks must return the payload, modified or unmodified";["insert","update","delete"].includes(o)?(i=this.bindings.postgres_changes)===null||i===void 0||i.filter(m=>{var g,y,_;return((g=m.filter)===null||g===void 0?void 0:g.event)==="*"||((_=(y=m.filter)===null||y===void 0?void 0:y.event)===null||_===void 0?void 0:_.toLocaleLowerCase())===o}).map(m=>m.callback(h,r)):(s=this.bindings[o])===null||s===void 0||s.filter(m=>{var g,y,_,p,f,v;if(["broadcast","presence","postgres_changes"].includes(o))if("id"in m){const w=m.id,k=(g=m.filter)===null||g===void 0?void 0:g.event;return w&&((y=n.ids)===null||y===void 0?void 0:y.includes(w))&&(k==="*"||(k==null?void 0:k.toLocaleLowerCase())===((_=n.data)===null||_===void 0?void 0:_.type.toLocaleLowerCase()))}else{const w=(f=(p=m==null?void 0:m.filter)===null||p===void 0?void 0:p.event)===null||f===void 0?void 0:f.toLocaleLowerCase();return w==="*"||w===((v=n==null?void 0:n.event)===null||v===void 0?void 0:v.toLocaleLowerCase())}else return m.type.toLocaleLowerCase()===o}).map(m=>{if(typeof h=="object"&&"ids"in h){const g=h.data,{schema:y,table:_,commit_timestamp:p,type:f,errors:v}=g;h=Object.assign(Object.assign({},{schema:y,table:_,commit_timestamp:p,eventType:f,new:{},old:{},errors:v}),this._getPayloadRecords(g))}m.callback(h,r)})}_isClosed(){return this.state===Se.closed}_isJoined(){return this.state===Se.joined}_isJoining(){return this.state===Se.joining}_isLeaving(){return this.state===Se.leaving}_replyEventName(t){return`chan_reply_${t}`}_on(t,n,r){const i=t.toLocaleLowerCase(),s={type:i,filter:n,callback:r};return this.bindings[i]?this.bindings[i].push(s):this.bindings[i]=[s],this}_off(t,n){const r=t.toLocaleLowerCase();return this.bindings[r]=this.bindings[r].filter(i=>{var s;return!(((s=i.type)===null||s===void 0?void 0:s.toLocaleLowerCase())===r&&Ql.isEqual(i.filter,n))}),this}static isEqual(t,n){if(Object.keys(t).length!==Object.keys(n).length)return!1;for(const r in t)if(t[r]!==n[r])return!1;return!0}_rejoinUntilConnected(){this.rejoinTimer.scheduleTimeout(),this.socket.isConnected()&&this._rejoin()}_onClose(t){this._on(Me.close,{},t)}_onError(t){this._on(Me.error,{},n=>t(n))}_canPush(){return this.socket.isConnected()&&this._isJoined()}_rejoin(t=this.timeout){this._isLeaving()||(this.socket._leaveOpenTopic(this.topic),this.state=Se.joining,this.joinPush.resend(t))}_getPayloadRecords(t){const n={new:{},old:{}};return(t.type==="INSERT"||t.type==="UPDATE")&&(n.new=vu(t.columns,t.record)),(t.type==="UPDATE"||t.type==="DELETE")&&(n.old=vu(t.columns,t.old_record)),n}}const dm=()=>{},fm=typeof WebSocket<"u";class hm{constructor(t,n){var r;this.accessToken=null,this.apiKey=null,this.channels=[],this.endPoint="",this.headers=tm,this.params={},this.timeout=nf,this.heartbeatIntervalMs=3e4,this.heartbeatTimer=void 0,this.pendingHeartbeatRef=null,this.ref=0,this.logger=dm,this.conn=null,this.sendBuffer=[],this.serializer=new im,this.stateChangeCallbacks={open:[],close:[],error:[],message:[]},this._resolveFetch=s=>{let o;return s?o=s:typeof fetch>"u"?o=(...l)=>Nn(()=>Promise.resolve().then(()=>Fr),void 0,import.meta.url).then(({default:a})=>a(...l)):o=fetch,(...l)=>o(...l)},this.endPoint=`${t}/${Wo.websocket}`,n!=null&&n.transport?this.transport=n.transport:this.transport=null,n!=null&&n.params&&(this.params=n.params),n!=null&&n.headers&&(this.headers=Object.assign(Object.assign({},this.headers),n.headers)),n!=null&&n.timeout&&(this.timeout=n.timeout),n!=null&&n.logger&&(this.logger=n.logger),n!=null&&n.heartbeatIntervalMs&&(this.heartbeatIntervalMs=n.heartbeatIntervalMs);const i=(r=n==null?void 0:n.params)===null||r===void 0?void 0:r.apikey;i&&(this.accessToken=i,this.apiKey=i),this.reconnectAfterMs=n!=null&&n.reconnectAfterMs?n.reconnectAfterMs:s=>[1e3,2e3,5e3,1e4][s-1]||1e4,this.encode=n!=null&&n.encode?n.encode:(s,o)=>o(JSON.stringify(s)),this.decode=n!=null&&n.decode?n.decode:this.serializer.decode.bind(this.serializer),this.reconnectTimer=new rf(async()=>{this.disconnect(),this.connect()},this.reconnectAfterMs),this.fetch=this._resolveFetch(n==null?void 0:n.fetch)}connect(){if(!this.conn){if(this.transport){this.conn=new this.transport(this._endPointURL(),void 0,{headers:this.headers});return}if(fm){this.conn=new WebSocket(this._endPointURL()),this.setupConnection();return}this.conn=new pm(this._endPointURL(),void 0,{close:()=>{this.conn=null}}),Nn(()=>import("./browser-Cflo9lLP.js").then(t=>t.b),[],import.meta.url).then(({default:t})=>{this.conn=new t(this._endPointURL(),void 0,{headers:this.headers}),this.setupConnection()})}}disconnect(t,n){this.conn&&(this.conn.onclose=function(){},t?this.conn.close(t,n??""):this.conn.close(),this.conn=null,this.heartbeatTimer&&clearInterval(this.heartbeatTimer),this.reconnectTimer.reset())}getChannels(){return this.channels}async removeChannel(t){const n=await t.unsubscribe();return this.channels.length===0&&this.disconnect(),n}async removeAllChannels(){const t=await Promise.all(this.channels.map(n=>n.unsubscribe()));return this.disconnect(),t}log(t,n,r){this.logger(t,n,r)}connectionState(){switch(this.conn&&this.conn.readyState){case Pn.connecting:return bt.Connecting;case Pn.open:return bt.Open;case Pn.closing:return bt.Closing;default:return bt.Closed}}isConnected(){return this.connectionState()===bt.Open}channel(t,n={config:{}}){const r=new Ql(`realtime:${t}`,n,this);return this.channels.push(r),r}push(t){const{topic:n,event:r,payload:i,ref:s}=t,o=()=>{this.encode(t,l=>{var a;(a=this.conn)===null||a===void 0||a.send(l)})};this.log("push",`${n} ${r} (${s})`,i),this.isConnected()?o():this.sendBuffer.push(o)}setAuth(t){this.accessToken=t,this.channels.forEach(n=>{t&&n.updateJoinPayload({access_token:t}),n.joinedOnce&&n._isJoined()&&n._push(Me.access_token,{access_token:t})})}_makeRef(){let t=this.ref+1;return t===this.ref?this.ref=0:this.ref=t,this.ref.toString()}_leaveOpenTopic(t){let n=this.channels.find(r=>r.topic===t&&(r._isJoined()||r._isJoining()));n&&(this.log("transport",`leaving duplicate topic "${t}"`),n.unsubscribe())}_remove(t){this.channels=this.channels.filter(n=>n._joinRef()!==t._joinRef())}setupConnection(){this.conn&&(this.conn.binaryType="arraybuffer",this.conn.onopen=()=>this._onConnOpen(),this.conn.onerror=t=>this._onConnError(t),this.conn.onmessage=t=>this._onConnMessage(t),this.conn.onclose=t=>this._onConnClose(t))}_endPointURL(){return this._appendParams(this.endPoint,Object.assign({},this.params,{vsn:nm}))}_onConnMessage(t){this.decode(t.data,n=>{let{topic:r,event:i,payload:s,ref:o}=n;(o&&o===this.pendingHeartbeatRef||i===(s==null?void 0:s.type))&&(this.pendingHeartbeatRef=null),this.log("receive",`${s.status||""} ${r} ${i} ${o&&"("+o+")"||""}`,s),this.channels.filter(l=>l._isMember(r)).forEach(l=>l._trigger(i,s,o)),this.stateChangeCallbacks.message.forEach(l=>l(n))})}_onConnOpen(){this.log("transport",`connected to ${this._endPointURL()}`),this._flushSendBuffer(),this.reconnectTimer.reset(),this.heartbeatTimer&&clearInterval(this.heartbeatTimer),this.heartbeatTimer=setInterval(()=>this._sendHeartbeat(),this.heartbeatIntervalMs),this.stateChangeCallbacks.open.forEach(t=>t())}_onConnClose(t){this.log("transport","close",t),this._triggerChanError(),this.heartbeatTimer&&clearInterval(this.heartbeatTimer),this.reconnectTimer.scheduleTimeout(),this.stateChangeCallbacks.close.forEach(n=>n(t))}_onConnError(t){this.log("transport",t.message),this._triggerChanError(),this.stateChangeCallbacks.error.forEach(n=>n(t))}_triggerChanError(){this.channels.forEach(t=>t._trigger(Me.error))}_appendParams(t,n){if(Object.keys(n).length===0)return t;const r=t.match(/\?/)?"&":"?",i=new URLSearchParams(n);return`${t}${r}${i}`}_flushSendBuffer(){this.isConnected()&&this.sendBuffer.length>0&&(this.sendBuffer.forEach(t=>t()),this.sendBuffer=[])}_sendHeartbeat(){var t;if(this.isConnected()){if(this.pendingHeartbeatRef){this.pendingHeartbeatRef=null,this.log("transport","heartbeat timeout. Attempting to re-establish connection"),(t=this.conn)===null||t===void 0||t.close(rm,"hearbeat timeout");return}this.pendingHeartbeatRef=this._makeRef(),this.push({topic:"phoenix",event:"heartbeat",payload:{},ref:this.pendingHeartbeatRef}),this.setAuth(this.accessToken)}}}class pm{constructor(t,n,r){this.binaryType="arraybuffer",this.onclose=()=>{},this.onerror=()=>{},this.onmessage=()=>{},this.onopen=()=>{},this.readyState=Pn.connecting,this.send=()=>{},this.url=null,this.url=t,this.close=r.close}}class Jl extends Error{constructor(t){super(t),this.__isStorageError=!0,this.name="StorageError"}}function ae(e){return typeof e=="object"&&e!==null&&"__isStorageError"in e}class vm extends Jl{constructor(t,n){super(t),this.name="StorageApiError",this.status=n}toJSON(){return{name:this.name,message:this.message,status:this.status}}}class wu extends Jl{constructor(t,n){super(t),this.name="StorageUnknownError",this.originalError=n}}var mm=function(e,t,n,r){function i(s){return s instanceof n?s:new n(function(o){o(s)})}return new(n||(n=Promise))(function(s,o){function l(c){try{u(r.next(c))}catch(d){o(d)}}function a(c){try{u(r.throw(c))}catch(d){o(d)}}function u(c){c.done?s(c.value):i(c.value).then(l,a)}u((r=r.apply(e,t||[])).next())})};const of=e=>{let t;return e?t=e:typeof fetch>"u"?t=(...n)=>Nn(()=>Promise.resolve().then(()=>Fr),void 0,import.meta.url).then(({default:r})=>r(...n)):t=fetch,(...n)=>t(...n)},gm=()=>mm(void 0,void 0,void 0,function*(){return typeof Response>"u"?(yield Nn(()=>Promise.resolve().then(()=>Fr),void 0,import.meta.url)).Response:Response});var bn=function(e,t,n,r){function i(s){return s instanceof n?s:new n(function(o){o(s)})}return new(n||(n=Promise))(function(s,o){function l(c){try{u(r.next(c))}catch(d){o(d)}}function a(c){try{u(r.throw(c))}catch(d){o(d)}}function u(c){c.done?s(c.value):i(c.value).then(l,a)}u((r=r.apply(e,t||[])).next())})};const Vs=e=>e.msg||e.message||e.error_description||e.error||JSON.stringify(e),ym=(e,t)=>bn(void 0,void 0,void 0,function*(){const n=yield gm();e instanceof n?e.json().then(r=>{t(new vm(Vs(r),e.status||500))}).catch(r=>{t(new wu(Vs(r),r))}):t(new wu(Vs(e),e))}),wm=(e,t,n,r)=>{const i={method:e,headers:(t==null?void 0:t.headers)||{}};return e==="GET"?i:(i.headers=Object.assign({"Content-Type":"application/json"},t==null?void 0:t.headers),i.body=JSON.stringify(r),Object.assign(Object.assign({},i),n))};function fs(e,t,n,r,i,s){return bn(this,void 0,void 0,function*(){return new Promise((o,l)=>{e(n,wm(t,r,i,s)).then(a=>{if(!a.ok)throw a;return r!=null&&r.noResolveJson?a:a.json()}).then(a=>o(a)).catch(a=>ym(a,l))})})}function Go(e,t,n,r){return bn(this,void 0,void 0,function*(){return fs(e,"GET",t,n,r)})}function pt(e,t,n,r,i){return bn(this,void 0,void 0,function*(){return fs(e,"POST",t,r,i,n)})}function _m(e,t,n,r,i){return bn(this,void 0,void 0,function*(){return fs(e,"PUT",t,r,i,n)})}function lf(e,t,n,r,i){return bn(this,void 0,void 0,function*(){return fs(e,"DELETE",t,r,i,n)})}var Re=function(e,t,n,r){function i(s){return s instanceof n?s:new n(function(o){o(s)})}return new(n||(n=Promise))(function(s,o){function l(c){try{u(r.next(c))}catch(d){o(d)}}function a(c){try{u(r.throw(c))}catch(d){o(d)}}function u(c){c.done?s(c.value):i(c.value).then(l,a)}u((r=r.apply(e,t||[])).next())})};const Sm={limit:100,offset:0,sortBy:{column:"name",order:"asc"}},_u={cacheControl:"3600",contentType:"text/plain;charset=UTF-8",upsert:!1};class km{constructor(t,n={},r,i){this.url=t,this.headers=n,this.bucketId=r,this.fetch=of(i)}uploadOrUpdate(t,n,r,i){return Re(this,void 0,void 0,function*(){try{let s;const o=Object.assign(Object.assign({},_u),i),l=Object.assign(Object.assign({},this.headers),t==="POST"&&{"x-upsert":String(o.upsert)});typeof Blob<"u"&&r instanceof Blob?(s=new FormData,s.append("cacheControl",o.cacheControl),s.append("",r)):typeof FormData<"u"&&r instanceof FormData?(s=r,s.append("cacheControl",o.cacheControl)):(s=r,l["cache-control"]=`max-age=${o.cacheControl}`,l["content-type"]=o.contentType);const a=this._removeEmptyFolders(n),u=this._getFinalPath(a),c=yield this.fetch(`${this.url}/object/${u}`,Object.assign({method:t,body:s,headers:l},o!=null&&o.duplex?{duplex:o.duplex}:{})),d=yield c.json();return c.ok?{data:{path:a,id:d.Id,fullPath:d.Key},error:null}:{data:null,error:d}}catch(s){if(ae(s))return{data:null,error:s};throw s}})}upload(t,n,r){return Re(this,void 0,void 0,function*(){return this.uploadOrUpdate("POST",t,n,r)})}uploadToSignedUrl(t,n,r,i){return Re(this,void 0,void 0,function*(){const s=this._removeEmptyFolders(t),o=this._getFinalPath(s),l=new URL(this.url+`/object/upload/sign/${o}`);l.searchParams.set("token",n);try{let a;const u=Object.assign({upsert:_u.upsert},i),c=Object.assign(Object.assign({},this.headers),{"x-upsert":String(u.upsert)});typeof Blob<"u"&&r instanceof Blob?(a=new FormData,a.append("cacheControl",u.cacheControl),a.append("",r)):typeof FormData<"u"&&r instanceof FormData?(a=r,a.append("cacheControl",u.cacheControl)):(a=r,c["cache-control"]=`max-age=${u.cacheControl}`,c["content-type"]=u.contentType);const d=yield this.fetch(l.toString(),{method:"PUT",body:a,headers:c}),h=yield d.json();return d.ok?{data:{path:s,fullPath:h.Key},error:null}:{data:null,error:h}}catch(a){if(ae(a))return{data:null,error:a};throw a}})}createSignedUploadUrl(t){return Re(this,void 0,void 0,function*(){try{let n=this._getFinalPath(t);const r=yield pt(this.fetch,`${this.url}/object/upload/sign/${n}`,{},{headers:this.headers}),i=new URL(this.url+r.url),s=i.searchParams.get("token");if(!s)throw new Jl("No token returned by API");return{data:{signedUrl:i.toString(),path:t,token:s},error:null}}catch(n){if(ae(n))return{data:null,error:n};throw n}})}update(t,n,r){return Re(this,void 0,void 0,function*(){return this.uploadOrUpdate("PUT",t,n,r)})}move(t,n){return Re(this,void 0,void 0,function*(){try{return{data:yield pt(this.fetch,`${this.url}/object/move`,{bucketId:this.bucketId,sourceKey:t,destinationKey:n},{headers:this.headers}),error:null}}catch(r){if(ae(r))return{data:null,error:r};throw r}})}copy(t,n){return Re(this,void 0,void 0,function*(){try{return{data:{path:(yield pt(this.fetch,`${this.url}/object/copy`,{bucketId:this.bucketId,sourceKey:t,destinationKey:n},{headers:this.headers})).Key},error:null}}catch(r){if(ae(r))return{data:null,error:r};throw r}})}createSignedUrl(t,n,r){return Re(this,void 0,void 0,function*(){try{let i=this._getFinalPath(t),s=yield pt(this.fetch,`${this.url}/object/sign/${i}`,Object.assign({expiresIn:n},r!=null&&r.transform?{transform:r.transform}:{}),{headers:this.headers});const o=r!=null&&r.download?`&download=${r.download===!0?"":r.download}`:"";return s={signedUrl:encodeURI(`${this.url}${s.signedURL}${o}`)},{data:s,error:null}}catch(i){if(ae(i))return{data:null,error:i};throw i}})}createSignedUrls(t,n,r){return Re(this,void 0,void 0,function*(){try{const i=yield pt(this.fetch,`${this.url}/object/sign/${this.bucketId}`,{expiresIn:n,paths:t},{headers:this.headers}),s=r!=null&&r.download?`&download=${r.download===!0?"":r.download}`:"";return{data:i.map(o=>Object.assign(Object.assign({},o),{signedUrl:o.signedURL?encodeURI(`${this.url}${o.signedURL}${s}`):null})),error:null}}catch(i){if(ae(i))return{data:null,error:i};throw i}})}download(t,n){return Re(this,void 0,void 0,function*(){const i=typeof(n==null?void 0:n.transform)<"u"?"render/image/authenticated":"object",s=this.transformOptsToQueryString((n==null?void 0:n.transform)||{}),o=s?`?${s}`:"";try{const l=this._getFinalPath(t);return{data:yield(yield Go(this.fetch,`${this.url}/${i}/${l}${o}`,{headers:this.headers,noResolveJson:!0})).blob(),error:null}}catch(l){if(ae(l))return{data:null,error:l};throw l}})}getPublicUrl(t,n){const r=this._getFinalPath(t),i=[],s=n!=null&&n.download?`download=${n.download===!0?"":n.download}`:"";s!==""&&i.push(s);const l=typeof(n==null?void 0:n.transform)<"u"?"render/image":"object",a=this.transformOptsToQueryString((n==null?void 0:n.transform)||{});a!==""&&i.push(a);let u=i.join("&");return u!==""&&(u=`?${u}`),{data:{publicUrl:encodeURI(`${this.url}/${l}/public/${r}${u}`)}}}remove(t){return Re(this,void 0,void 0,function*(){try{return{data:yield lf(this.fetch,`${this.url}/object/${this.bucketId}`,{prefixes:t},{headers:this.headers}),error:null}}catch(n){if(ae(n))return{data:null,error:n};throw n}})}list(t,n,r){return Re(this,void 0,void 0,function*(){try{const i=Object.assign(Object.assign(Object.assign({},Sm),n),{prefix:t||""});return{data:yield pt(this.fetch,`${this.url}/object/list/${this.bucketId}`,i,{headers:this.headers},r),error:null}}catch(i){if(ae(i))return{data:null,error:i};throw i}})}_getFinalPath(t){return`${this.bucketId}/${t}`}_removeEmptyFolders(t){return t.replace(/^\/|\/$/g,"").replace(/\/+/g,"/")}transformOptsToQueryString(t){const n=[];return t.width&&n.push(`width=${t.width}`),t.height&&n.push(`height=${t.height}`),t.resize&&n.push(`resize=${t.resize}`),t.format&&n.push(`format=${t.format}`),t.quality&&n.push(`quality=${t.quality}`),n.join("&")}}const Em="2.5.5",Cm={"X-Client-Info":`storage-js/${Em}`};var rn=function(e,t,n,r){function i(s){return s instanceof n?s:new n(function(o){o(s)})}return new(n||(n=Promise))(function(s,o){function l(c){try{u(r.next(c))}catch(d){o(d)}}function a(c){try{u(r.throw(c))}catch(d){o(d)}}function u(c){c.done?s(c.value):i(c.value).then(l,a)}u((r=r.apply(e,t||[])).next())})};class xm{constructor(t,n={},r){this.url=t,this.headers=Object.assign(Object.assign({},Cm),n),this.fetch=of(r)}listBuckets(){return rn(this,void 0,void 0,function*(){try{return{data:yield Go(this.fetch,`${this.url}/bucket`,{headers:this.headers}),error:null}}catch(t){if(ae(t))return{data:null,error:t};throw t}})}getBucket(t){return rn(this,void 0,void 0,function*(){try{return{data:yield Go(this.fetch,`${this.url}/bucket/${t}`,{headers:this.headers}),error:null}}catch(n){if(ae(n))return{data:null,error:n};throw n}})}createBucket(t,n={public:!1}){return rn(this,void 0,void 0,function*(){try{return{data:yield pt(this.fetch,`${this.url}/bucket`,{id:t,name:t,public:n.public,file_size_limit:n.fileSizeLimit,allowed_mime_types:n.allowedMimeTypes},{headers:this.headers}),error:null}}catch(r){if(ae(r))return{data:null,error:r};throw r}})}updateBucket(t,n){return rn(this,void 0,void 0,function*(){try{return{data:yield _m(this.fetch,`${this.url}/bucket/${t}`,{id:t,name:t,public:n.public,file_size_limit:n.fileSizeLimit,allowed_mime_types:n.allowedMimeTypes},{headers:this.headers}),error:null}}catch(r){if(ae(r))return{data:null,error:r};throw r}})}emptyBucket(t){return rn(this,void 0,void 0,function*(){try{return{data:yield pt(this.fetch,`${this.url}/bucket/${t}/empty`,{},{headers:this.headers}),error:null}}catch(n){if(ae(n))return{data:null,error:n};throw n}})}deleteBucket(t){return rn(this,void 0,void 0,function*(){try{return{data:yield lf(this.fetch,`${this.url}/bucket/${t}`,{},{headers:this.headers}),error:null}}catch(n){if(ae(n))return{data:null,error:n};throw n}})}}class Pm extends xm{constructor(t,n={},r){super(t,n,r)}from(t){return new km(this.url,this.headers,t,this.fetch)}}const Tm="2.43.4";let nr="";typeof Deno<"u"?nr="deno":typeof document<"u"?nr="web":typeof navigator<"u"&&navigator.product==="ReactNative"?nr="react-native":nr="node";const Om={"X-Client-Info":`supabase-js-${nr}/${Tm}`},Rm={headers:Om},jm={schema:"public"},Lm={autoRefreshToken:!0,persistSession:!0,detectSessionInUrl:!0,flowType:"implicit"},Im={};var $m=function(e,t,n,r){function i(s){return s instanceof n?s:new n(function(o){o(s)})}return new(n||(n=Promise))(function(s,o){function l(c){try{u(r.next(c))}catch(d){o(d)}}function a(c){try{u(r.throw(c))}catch(d){o(d)}}function u(c){c.done?s(c.value):i(c.value).then(l,a)}u((r=r.apply(e,t||[])).next())})};const Nm=e=>{let t;return e?t=e:typeof fetch>"u"?t=Kl:t=fetch,(...n)=>t(...n)},Am=()=>typeof Headers>"u"?tf:Headers,Um=(e,t,n)=>{const r=Nm(n),i=Am();return(s,o)=>$m(void 0,void 0,void 0,function*(){var l;const a=(l=yield t())!==null&&l!==void 0?l:e;let u=new i(o==null?void 0:o.headers);return u.has("apikey")||u.set("apikey",e),u.has("Authorization")||u.set("Authorization",`Bearer ${a}`),r(s,Object.assign(Object.assign({},o),{headers:u}))})};function Dm(e){return e.replace(/\/$/,"")}function zm(e,t){const{db:n,auth:r,realtime:i,global:s}=e,{db:o,auth:l,realtime:a,global:u}=t;return{db:Object.assign(Object.assign({},o),n),auth:Object.assign(Object.assign({},l),r),realtime:Object.assign(Object.assign({},a),i),global:Object.assign(Object.assign({},u),s)}}const af="2.64.2",Fm="http://localhost:9999",Mm="supabase.auth.token",bm={"X-Client-Info":`gotrue-js/${af}`},Su=10,Qo="X-Supabase-Api-Version",uf={"2024-01-01":{timestamp:Date.parse("2024-01-01T00:00:00.0Z"),name:"2024-01-01"}};function Bm(e){return Math.round(Date.now()/1e3)+e}function Vm(){return"xxxxxxxx-xxxx-4xxx-yxxx-xxxxxxxxxxxx".replace(/[xy]/g,function(e){const t=Math.random()*16|0;return(e=="x"?t:t&3|8).toString(16)})}const De=()=>typeof document<"u",Ut={tested:!1,writable:!1},hr=()=>{if(!De())return!1;try{if(typeof globalThis.localStorage!="object")return!1}catch{return!1}if(Ut.tested)return Ut.writable;const e=`lswt-${Math.random()}${Math.random()}`;try{globalThis.localStorage.setItem(e,e),globalThis.localStorage.removeItem(e),Ut.tested=!0,Ut.writable=!0}catch{Ut.tested=!0,Ut.writable=!1}return Ut.writable};function Hs(e){const t={},n=new URL(e);if(n.hash&&n.hash[0]==="#")try{new URLSearchParams(n.hash.substring(1)).forEach((i,s)=>{t[s]=i})}catch{}return n.searchParams.forEach((r,i)=>{t[i]=r}),t}const cf=e=>{let t;return e?t=e:typeof fetch>"u"?t=(...n)=>Nn(()=>Promise.resolve().then(()=>Fr),void 0,import.meta.url).then(({default:r})=>r(...n)):t=fetch,(...n)=>t(...n)},Hm=e=>typeof e=="object"&&e!==null&&"status"in e&&"ok"in e&&"json"in e&&typeof e.json=="function",df=async(e,t,n)=>{await e.setItem(t,JSON.stringify(n))},si=async(e,t)=>{const n=await e.getItem(t);if(!n)return null;try{return JSON.parse(n)}catch{return n}},Ws=async(e,t)=>{await e.removeItem(t)};function Wm(e){const t="ABCDEFGHIJKLMNOPQRSTUVWXYZabcdefghijklmnopqrstuvwxyz0123456789+/=";let n="",r,i,s,o,l,a,u,c=0;for(e=e.replace("-","+").replace("_","/");c<e.length;)o=t.indexOf(e.charAt(c++)),l=t.indexOf(e.charAt(c++)),a=t.indexOf(e.charAt(c++)),u=t.indexOf(e.charAt(c++)),r=o<<2|l>>4,i=(l&15)<<4|a>>2,s=(a&3)<<6|u,n=n+String.fromCharCode(r),a!=64&&i!=0&&(n=n+String.fromCharCode(i)),u!=64&&s!=0&&(n=n+String.fromCharCode(s));return n}class hs{constructor(){this.promise=new hs.promiseConstructor((t,n)=>{this.resolve=t,this.reject=n})}}hs.promiseConstructor=Promise;function ku(e){const t=/^([a-z0-9_-]{4})*($|[a-z0-9_-]{3}=?$|[a-z0-9_-]{2}(==)?$)$/i,n=e.split(".");if(n.length!==3)throw new Error("JWT is not valid: not a JWT structure");if(!t.test(n[1]))throw new Error("JWT is not valid: payload is not in base64url format");const r=n[1];return JSON.parse(Wm(r))}async function Km(e){return await new Promise(t=>{setTimeout(()=>t(null),e)})}function Gm(e,t){return new Promise((r,i)=>{(async()=>{for(let s=0;s<1/0;s++)try{const o=await e(s);if(!t(s,null,o)){r(o);return}}catch(o){if(!t(s,o)){i(o);return}}})()})}function Qm(e){return("0"+e.toString(16)).substr(-2)}function Jm(){const t=new Uint32Array(56);if(typeof crypto>"u"){const n="ABCDEFGHIJKLMNOPQRSTUVWXYZabcdefghijklmnopqrstuvwxyz0123456789-._~",r=n.length;let i="";for(let s=0;s<56;s++)i+=n.charAt(Math.floor(Math.random()*r));return i}return crypto.getRandomValues(t),Array.from(t,Qm).join("")}async function qm(e){const n=new TextEncoder().encode(e),r=await crypto.subtle.digest("SHA-256",n),i=new Uint8Array(r);return Array.from(i).map(s=>String.fromCharCode(s)).join("")}function Ym(e){return btoa(e).replace(/\+/g,"-").replace(/\//g,"_").replace(/=+$/,"")}async function Xm(e){if(!(typeof crypto<"u"&&typeof crypto.subtle<"u"&&typeof TextEncoder<"u"))return console.warn("WebCrypto API is not supported. Code challenge method will default to use plain instead of sha256."),e;const n=await qm(e);return Ym(n)}async function sn(e,t,n=!1){const r=Jm();let i=r;n&&(i+="/PASSWORD_RECOVERY"),await df(e,`${t}-code-verifier`,i);const s=await Xm(r);return[s,r===s?"plain":"s256"]}const Zm=/^2[0-9]{3}-(0[1-9]|1[0-2])-(0[1-9]|1[0-9]|2[0-9]|3[0-1])$/i;function eg(e){const t=e.headers.get(Qo);if(!t||!t.match(Zm))return null;try{return new Date(`${t}T00:00:00.0Z`)}catch{return null}}class ql extends Error{constructor(t,n,r){super(t),this.__isAuthError=!0,this.name="AuthError",this.status=n,this.code=r}}function I(e){return typeof e=="object"&&e!==null&&"__isAuthError"in e}class tg extends ql{constructor(t,n,r){super(t,n,r),this.name="AuthApiError",this.status=n,this.code=r}}function ng(e){return I(e)&&e.name==="AuthApiError"}class ff extends ql{constructor(t,n){super(t),this.name="AuthUnknownError",this.originalError=n}}class tn extends ql{constructor(t,n,r,i){super(t,r,i),this.name=n,this.status=r}}class Dt extends tn{constructor(){super("Auth session missing!","AuthSessionMissingError",400,void 0)}}class Ks extends tn{constructor(){super("Auth session or user missing","AuthInvalidTokenResponseError",500,void 0)}}class oi extends tn{constructor(t){super(t,"AuthInvalidCredentialsError",400,void 0)}}class li extends tn{constructor(t,n=null){super(t,"AuthImplicitGrantRedirectError",500,void 0),this.details=null,this.details=n}toJSON(){return{name:this.name,message:this.message,status:this.status,details:this.details}}}class Eu extends tn{constructor(t,n=null){super(t,"AuthPKCEGrantCodeExchangeError",500,void 0),this.details=null,this.details=n}toJSON(){return{name:this.name,message:this.message,status:this.status,details:this.details}}}class Jo extends tn{constructor(t,n){super(t,"AuthRetryableFetchError",n,void 0)}}function Gs(e){return I(e)&&e.name==="AuthRetryableFetchError"}class Cu extends tn{constructor(t,n,r){super(t,"AuthWeakPasswordError",n,"weak_password"),this.reasons=r}}var rg=function(e,t){var n={};for(var r in e)Object.prototype.hasOwnProperty.call(e,r)&&t.indexOf(r)<0&&(n[r]=e[r]);if(e!=null&&typeof Object.getOwnPropertySymbols=="function")for(var i=0,r=Object.getOwnPropertySymbols(e);i<r.length;i++)t.indexOf(r[i])<0&&Object.prototype.propertyIsEnumerable.call(e,r[i])&&(n[r[i]]=e[r[i]]);return n};const Mt=e=>e.msg||e.message||e.error_description||e.error||JSON.stringify(e),ig=[502,503,504];async function xu(e){var t;if(!Hm(e))throw new Jo(Mt(e),0);if(ig.includes(e.status))throw new Jo(Mt(e),e.status);let n;try{n=await e.json()}catch(s){throw new ff(Mt(s),s)}let r;const i=eg(e);if(i&&i.getTime()>=uf["2024-01-01"].timestamp&&typeof n=="object"&&n&&typeof n.code=="string"?r=n.code:typeof n=="object"&&n&&typeof n.error_code=="string"&&(r=n.error_code),r){if(r==="weak_password")throw new Cu(Mt(n),e.status,((t=n.weak_password)===null||t===void 0?void 0:t.reasons)||[])}else if(typeof n=="object"&&n&&typeof n.weak_password=="object"&&n.weak_password&&Array.isArray(n.weak_password.reasons)&&n.weak_password.reasons.length&&n.weak_password.reasons.reduce((s,o)=>s&&typeof o=="string",!0))throw new Cu(Mt(n),e.status,n.weak_password.reasons);throw new tg(Mt(n),e.status||500,r)}const sg=(e,t,n,r)=>{const i={method:e,headers:(t==null?void 0:t.headers)||{}};return e==="GET"?i:(i.headers=Object.assign({"Content-Type":"application/json;charset=UTF-8"},t==null?void 0:t.headers),i.body=JSON.stringify(r),Object.assign(Object.assign({},i),n))};async function N(e,t,n,r){var i;const s=Object.assign({},r==null?void 0:r.headers);s[Qo]||(s[Qo]=uf["2024-01-01"].name),r!=null&&r.jwt&&(s.Authorization=`Bearer ${r.jwt}`);const o=(i=r==null?void 0:r.query)!==null&&i!==void 0?i:{};r!=null&&r.redirectTo&&(o.redirect_to=r.redirectTo);const l=Object.keys(o).length?"?"+new URLSearchParams(o).toString():"",a=await og(e,t,n+l,{headers:s,noResolveJson:r==null?void 0:r.noResolveJson},{},r==null?void 0:r.body);return r!=null&&r.xform?r==null?void 0:r.xform(a):{data:Object.assign({},a),error:null}}async function og(e,t,n,r,i,s){const o=sg(t,r,i,s);let l;try{l=await e(n,Object.assign({},o))}catch(a){throw console.error(a),new Jo(Mt(a),0)}if(l.ok||await xu(l),r!=null&&r.noResolveJson)return l;try{return await l.json()}catch(a){await xu(a)}}function dt(e){var t;let n=null;cg(e)&&(n=Object.assign({},e),e.expires_at||(n.expires_at=Bm(e.expires_in)));const r=(t=e.user)!==null&&t!==void 0?t:e;return{data:{session:n,user:r},error:null}}function Pu(e){const t=dt(e);return!t.error&&e.weak_password&&typeof e.weak_password=="object"&&Array.isArray(e.weak_password.reasons)&&e.weak_password.reasons.length&&e.weak_password.message&&typeof e.weak_password.message=="string"&&e.weak_password.reasons.reduce((n,r)=>n&&typeof r=="string",!0)&&(t.data.weak_password=e.weak_password),t}function gt(e){var t;return{data:{user:(t=e.user)!==null&&t!==void 0?t:e},error:null}}function lg(e){return{data:e,error:null}}function ag(e){const{action_link:t,email_otp:n,hashed_token:r,redirect_to:i,verification_type:s}=e,o=rg(e,["action_link","email_otp","hashed_token","redirect_to","verification_type"]),l={action_link:t,email_otp:n,hashed_token:r,redirect_to:i,verification_type:s},a=Object.assign({},o);return{data:{properties:l,user:a},error:null}}function ug(e){return e}function cg(e){return e.access_token&&e.refresh_token&&e.expires_in}var dg=function(e,t){var n={};for(var r in e)Object.prototype.hasOwnProperty.call(e,r)&&t.indexOf(r)<0&&(n[r]=e[r]);if(e!=null&&typeof Object.getOwnPropertySymbols=="function")for(var i=0,r=Object.getOwnPropertySymbols(e);i<r.length;i++)t.indexOf(r[i])<0&&Object.prototype.propertyIsEnumerable.call(e,r[i])&&(n[r[i]]=e[r[i]]);return n};class fg{constructor({url:t="",headers:n={},fetch:r}){this.url=t,this.headers=n,this.fetch=cf(r),this.mfa={listFactors:this._listFactors.bind(this),deleteFactor:this._deleteFactor.bind(this)}}async signOut(t,n="global"){try{return await N(this.fetch,"POST",`${this.url}/logout?scope=${n}`,{headers:this.headers,jwt:t,noResolveJson:!0}),{data:null,error:null}}catch(r){if(I(r))return{data:null,error:r};throw r}}async inviteUserByEmail(t,n={}){try{return await N(this.fetch,"POST",`${this.url}/invite`,{body:{email:t,data:n.data},headers:this.headers,redirectTo:n.redirectTo,xform:gt})}catch(r){if(I(r))return{data:{user:null},error:r};throw r}}async generateLink(t){try{const{options:n}=t,r=dg(t,["options"]),i=Object.assign(Object.assign({},r),n);return"newEmail"in r&&(i.new_email=r==null?void 0:r.newEmail,delete i.newEmail),await N(this.fetch,"POST",`${this.url}/admin/generate_link`,{body:i,headers:this.headers,xform:ag,redirectTo:n==null?void 0:n.redirectTo})}catch(n){if(I(n))return{data:{properties:null,user:null},error:n};throw n}}async createUser(t){try{return await N(this.fetch,"POST",`${this.url}/admin/users`,{body:t,headers:this.headers,xform:gt})}catch(n){if(I(n))return{data:{user:null},error:n};throw n}}async listUsers(t){var n,r,i,s,o,l,a;try{const u={nextPage:null,lastPage:0,total:0},c=await N(this.fetch,"GET",`${this.url}/admin/users`,{headers:this.headers,noResolveJson:!0,query:{page:(r=(n=t==null?void 0:t.page)===null||n===void 0?void 0:n.toString())!==null&&r!==void 0?r:"",per_page:(s=(i=t==null?void 0:t.perPage)===null||i===void 0?void 0:i.toString())!==null&&s!==void 0?s:""},xform:ug});if(c.error)throw c.error;const d=await c.json(),h=(o=c.headers.get("x-total-count"))!==null&&o!==void 0?o:0,m=(a=(l=c.headers.get("link"))===null||l===void 0?void 0:l.split(","))!==null&&a!==void 0?a:[];return m.length>0&&(m.forEach(g=>{const y=parseInt(g.split(";")[0].split("=")[1].substring(0,1)),_=JSON.parse(g.split(";")[1].split("=")[1]);u[`${_}Page`]=y}),u.total=parseInt(h)),{data:Object.assign(Object.assign({},d),u),error:null}}catch(u){if(I(u))return{data:{users:[]},error:u};throw u}}async getUserById(t){try{return await N(this.fetch,"GET",`${this.url}/admin/users/${t}`,{headers:this.headers,xform:gt})}catch(n){if(I(n))return{data:{user:null},error:n};throw n}}async updateUserById(t,n){try{return await N(this.fetch,"PUT",`${this.url}/admin/users/${t}`,{body:n,headers:this.headers,xform:gt})}catch(r){if(I(r))return{data:{user:null},error:r};throw r}}async deleteUser(t,n=!1){try{return await N(this.fetch,"DELETE",`${this.url}/admin/users/${t}`,{headers:this.headers,body:{should_soft_delete:n},xform:gt})}catch(r){if(I(r))return{data:{user:null},error:r};throw r}}async _listFactors(t){try{const{data:n,error:r}=await N(this.fetch,"GET",`${this.url}/admin/users/${t.userId}/factors`,{headers:this.headers,xform:i=>({data:{factors:i},error:null})});return{data:n,error:r}}catch(n){if(I(n))return{data:null,error:n};throw n}}async _deleteFactor(t){try{return{data:await N(this.fetch,"DELETE",`${this.url}/admin/users/${t.userId}/factors/${t.id}`,{headers:this.headers}),error:null}}catch(n){if(I(n))return{data:null,error:n};throw n}}}const hg={getItem:e=>hr()?globalThis.localStorage.getItem(e):null,setItem:(e,t)=>{hr()&&globalThis.localStorage.setItem(e,t)},removeItem:e=>{hr()&&globalThis.localStorage.removeItem(e)}};function Tu(e={}){return{getItem:t=>e[t]||null,setItem:(t,n)=>{e[t]=n},removeItem:t=>{delete e[t]}}}function pg(){if(typeof globalThis!="object")try{Object.defineProperty(Object.prototype,"__magic__",{get:function(){return this},configurable:!0}),__magic__.globalThis=__magic__,delete Object.prototype.__magic__}catch{typeof self<"u"&&(self.globalThis=self)}}const on={debug:!!(globalThis&&hr()&&globalThis.localStorage&&globalThis.localStorage.getItem("supabase.gotrue-js.locks.debug")==="true")};class hf extends Error{constructor(t){super(t),this.isAcquireTimeout=!0}}class vg extends hf{}async function mg(e,t,n){on.debug&&console.log("@supabase/gotrue-js: navigatorLock: acquire lock",e,t);const r=new globalThis.AbortController;return t>0&&setTimeout(()=>{r.abort(),on.debug&&console.log("@supabase/gotrue-js: navigatorLock acquire timed out",e)},t),await globalThis.navigator.locks.request(e,t===0?{mode:"exclusive",ifAvailable:!0}:{mode:"exclusive",signal:r.signal},async i=>{if(i){on.debug&&console.log("@supabase/gotrue-js: navigatorLock: acquired",e,i.name);try{return await n()}finally{on.debug&&console.log("@supabase/gotrue-js: navigatorLock: released",e,i.name)}}else{if(t===0)throw on.debug&&console.log("@supabase/gotrue-js: navigatorLock: not immediately available",e),new vg(`Acquiring an exclusive Navigator LockManager lock "${e}" immediately failed`);if(on.debug)try{const s=await globalThis.navigator.locks.query();console.log("@supabase/gotrue-js: Navigator LockManager state",JSON.stringify(s,null," "))}catch(s){console.warn("@supabase/gotrue-js: Error when querying Navigator LockManager state",s)}return console.warn("@supabase/gotrue-js: Navigator LockManager returned a null lock when using #request without ifAvailable set to true, it appears this browser is not following the LockManager spec https://developer.mozilla.org/en-US/docs/Web/API/LockManager/request"),await n()}})}pg();const gg={url:Fm,storageKey:Mm,autoRefreshToken:!0,persistSession:!0,detectSessionInUrl:!0,headers:bm,flowType:"implicit",debug:!1,hasCustomAuthorizationHeader:!1},Yn=30*1e3,Ou=3;async function Ru(e,t,n){return await n()}class $r{constructor(t){var n,r;this.memoryStorage=null,this.stateChangeEmitters=new Map,this.autoRefreshTicker=null,this.visibilityChangedCallback=null,this.refreshingDeferred=null,this.initializePromise=null,this.detectSessionInUrl=!0,this.hasCustomAuthorizationHeader=!1,this.suppressGetSessionWarning=!1,this.lockAcquired=!1,this.pendingInLock=[],this.broadcastChannel=null,this.logger=console.log,this.instanceID=$r.nextInstanceID,$r.nextInstanceID+=1,this.instanceID>0&&De()&&console.warn("Multiple GoTrueClient instances detected in the same browser context. It is not an error, but this should be avoided as it may produce undefined behavior when used concurrently under the same storage key.");const i=Object.assign(Object.assign({},gg),t);if(this.logDebugMessages=!!i.debug,typeof i.debug=="function"&&(this.logger=i.debug),this.persistSession=i.persistSession,this.storageKey=i.storageKey,this.autoRefreshToken=i.autoRefreshToken,this.admin=new fg({url:i.url,headers:i.headers,fetch:i.fetch}),this.url=i.url,this.headers=i.headers,this.fetch=cf(i.fetch),this.lock=i.lock||Ru,this.detectSessionInUrl=i.detectSessionInUrl,this.flowType=i.flowType,this.hasCustomAuthorizationHeader=i.hasCustomAuthorizationHeader,i.lock?this.lock=i.lock:De()&&(!((n=globalThis==null?void 0:globalThis.navigator)===null||n===void 0)&&n.locks)?this.lock=mg:this.lock=Ru,this.mfa={verify:this._verify.bind(this),enroll:this._enroll.bind(this),unenroll:this._unenroll.bind(this),challenge:this._challenge.bind(this),listFactors:this._listFactors.bind(this),challengeAndVerify:this._challengeAndVerify.bind(this),getAuthenticatorAssuranceLevel:this._getAuthenticatorAssuranceLevel.bind(this)},this.persistSession?i.storage?this.storage=i.storage:hr()?this.storage=hg:(this.memoryStorage={},this.storage=Tu(this.memoryStorage)):(this.memoryStorage={},this.storage=Tu(this.memoryStorage)),De()&&globalThis.BroadcastChannel&&this.persistSession&&this.storageKey){try{this.broadcastChannel=new globalThis.BroadcastChannel(this.storageKey)}catch(s){console.error("Failed to create a new BroadcastChannel, multi-tab state changes will not be available",s)}(r=this.broadcastChannel)===null||r===void 0||r.addEventListener("message",async s=>{this._debug("received broadcast notification from other tab or client",s),await this._notifyAllSubscribers(s.data.event,s.data.session,!1)})}this.initialize()}_debug(...t){return this.logDebugMessages&&this.logger(`GoTrueClient@${this.instanceID} (${af}) ${new Date().toISOString()}`,...t),this}async initialize(){return this.initializePromise?await this.initializePromise:(this.initializePromise=(async()=>await this._acquireLock(-1,async()=>await this._initialize()))(),await this.initializePromise)}async _initialize(){try{const t=De()?await this._isPKCEFlow():!1;if(this._debug("#_initialize()","begin","is PKCE flow",t),t||this.detectSessionInUrl&&this._isImplicitGrantFlow()){const{data:n,error:r}=await this._getSessionFromURL(t);if(r)return this._debug("#_initialize()","error detecting session from URL",r),(r==null?void 0:r.message)==="Identity is already linked"||(r==null?void 0:r.message)==="Identity is already linked to another user"?{error:r}:(await this._removeSession(),{error:r});const{session:i,redirectType:s}=n;return this._debug("#_initialize()","detected session in URL",i,"redirect type",s),await this._saveSession(i),setTimeout(async()=>{s==="recovery"?await this._notifyAllSubscribers("PASSWORD_RECOVERY",i):await this._notifyAllSubscribers("SIGNED_IN",i)},0),{error:null}}return await this._recoverAndRefresh(),{error:null}}catch(t){return I(t)?{error:t}:{error:new ff("Unexpected error during initialization",t)}}finally{await this._handleVisibilityChange(),this._debug("#_initialize()","end")}}async signInAnonymously(t){var n,r,i;try{await this._removeSession();const s=await N(this.fetch,"POST",`${this.url}/signup`,{headers:this.headers,body:{data:(r=(n=t==null?void 0:t.options)===null||n===void 0?void 0:n.data)!==null&&r!==void 0?r:{},gotrue_meta_security:{captcha_token:(i=t==null?void 0:t.options)===null||i===void 0?void 0:i.captchaToken}},xform:dt}),{data:o,error:l}=s;if(l||!o)return{data:{user:null,session:null},error:l};const a=o.session,u=o.user;return o.session&&(await this._saveSession(o.session),await this._notifyAllSubscribers("SIGNED_IN",a)),{data:{user:u,session:a},error:null}}catch(s){if(I(s))return{data:{user:null,session:null},error:s};throw s}}async signUp(t){var n,r,i;try{await this._removeSession();let s;if("email"in t){const{email:c,password:d,options:h}=t;let m=null,g=null;this.flowType==="pkce"&&([m,g]=await sn(this.storage,this.storageKey)),s=await N(this.fetch,"POST",`${this.url}/signup`,{headers:this.headers,redirectTo:h==null?void 0:h.emailRedirectTo,body:{email:c,password:d,data:(n=h==null?void 0:h.data)!==null&&n!==void 0?n:{},gotrue_meta_security:{captcha_token:h==null?void 0:h.captchaToken},code_challenge:m,code_challenge_method:g},xform:dt})}else if("phone"in t){const{phone:c,password:d,options:h}=t;s=await N(this.fetch,"POST",`${this.url}/signup`,{headers:this.headers,body:{phone:c,password:d,data:(r=h==null?void 0:h.data)!==null&&r!==void 0?r:{},channel:(i=h==null?void 0:h.channel)!==null&&i!==void 0?i:"sms",gotrue_meta_security:{captcha_token:h==null?void 0:h.captchaToken}},xform:dt})}else throw new oi("You must provide either an email or phone number and a password");const{data:o,error:l}=s;if(l||!o)return{data:{user:null,session:null},error:l};const a=o.session,u=o.user;return o.session&&(await this._saveSession(o.session),await this._notifyAllSubscribers("SIGNED_IN",a)),{data:{user:u,session:a},error:null}}catch(s){if(I(s))return{data:{user:null,session:null},error:s};throw s}}async signInWithPassword(t){try{await this._removeSession();let n;if("email"in t){const{email:s,password:o,options:l}=t;n=await N(this.fetch,"POST",`${this.url}/token?grant_type=password`,{headers:this.headers,body:{email:s,password:o,gotrue_meta_security:{captcha_token:l==null?void 0:l.captchaToken}},xform:Pu})}else if("phone"in t){const{phone:s,password:o,options:l}=t;n=await N(this.fetch,"POST",`${this.url}/token?grant_type=password`,{headers:this.headers,body:{phone:s,password:o,gotrue_meta_security:{captcha_token:l==null?void 0:l.captchaToken}},xform:Pu})}else throw new oi("You must provide either an email or phone number and a password");const{data:r,error:i}=n;return i?{data:{user:null,session:null},error:i}:!r||!r.session||!r.user?{data:{user:null,session:null},error:new Ks}:(r.session&&(await this._saveSession(r.session),await this._notifyAllSubscribers("SIGNED_IN",r.session)),{data:Object.assign({user:r.user,session:r.session},r.weak_password?{weakPassword:r.weak_password}:null),error:i})}catch(n){if(I(n))return{data:{user:null,session:null},error:n};throw n}}async signInWithOAuth(t){var n,r,i,s;return await this._removeSession(),await this._handleProviderSignIn(t.provider,{redirectTo:(n=t.options)===null||n===void 0?void 0:n.redirectTo,scopes:(r=t.options)===null||r===void 0?void 0:r.scopes,queryParams:(i=t.options)===null||i===void 0?void 0:i.queryParams,skipBrowserRedirect:(s=t.options)===null||s===void 0?void 0:s.skipBrowserRedirect})}async exchangeCodeForSession(t){return await this.initializePromise,this._acquireLock(-1,async()=>this._exchangeCodeForSession(t))}async _exchangeCodeForSession(t){const n=await si(this.storage,`${this.storageKey}-code-verifier`),[r,i]=(n??"").split("/"),{data:s,error:o}=await N(this.fetch,"POST",`${this.url}/token?grant_type=pkce`,{headers:this.headers,body:{auth_code:t,code_verifier:r},xform:dt});return await Ws(this.storage,`${this.storageKey}-code-verifier`),o?{data:{user:null,session:null,redirectType:null},error:o}:!s||!s.session||!s.user?{data:{user:null,session:null,redirectType:null},error:new Ks}:(s.session&&(await this._saveSession(s.session),await this._notifyAllSubscribers("SIGNED_IN",s.session)),{data:Object.assign(Object.assign({},s),{redirectType:i??null}),error:o})}async signInWithIdToken(t){await this._removeSession();try{const{options:n,provider:r,token:i,access_token:s,nonce:o}=t,l=await N(this.fetch,"POST",`${this.url}/token?grant_type=id_token`,{headers:this.headers,body:{provider:r,id_token:i,access_token:s,nonce:o,gotrue_meta_security:{captcha_token:n==null?void 0:n.captchaToken}},xform:dt}),{data:a,error:u}=l;return u?{data:{user:null,session:null},error:u}:!a||!a.session||!a.user?{data:{user:null,session:null},error:new Ks}:(a.session&&(await this._saveSession(a.session),await this._notifyAllSubscribers("SIGNED_IN",a.session)),{data:a,error:u})}catch(n){if(I(n))return{data:{user:null,session:null},error:n};throw n}}async signInWithOtp(t){var n,r,i,s,o;try{if(await this._removeSession(),"email"in t){const{email:l,options:a}=t;let u=null,c=null;this.flowType==="pkce"&&([u,c]=await sn(this.storage,this.storageKey));const{error:d}=await N(this.fetch,"POST",`${this.url}/otp`,{headers:this.headers,body:{email:l,data:(n=a==null?void 0:a.data)!==null&&n!==void 0?n:{},create_user:(r=a==null?void 0:a.shouldCreateUser)!==null&&r!==void 0?r:!0,gotrue_meta_security:{captcha_token:a==null?void 0:a.captchaToken},code_challenge:u,code_challenge_method:c},redirectTo:a==null?void 0:a.emailRedirectTo});return{data:{user:null,session:null},error:d}}if("phone"in t){const{phone:l,options:a}=t,{data:u,error:c}=await N(this.fetch,"POST",`${this.url}/otp`,{headers:this.headers,body:{phone:l,data:(i=a==null?void 0:a.data)!==null&&i!==void 0?i:{},create_user:(s=a==null?void 0:a.shouldCreateUser)!==null&&s!==void 0?s:!0,gotrue_meta_security:{captcha_token:a==null?void 0:a.captchaToken},channel:(o=a==null?void 0:a.channel)!==null&&o!==void 0?o:"sms"}});return{data:{user:null,session:null,messageId:u==null?void 0:u.message_id},error:c}}throw new oi("You must provide either an email or phone number.")}catch(l){if(I(l))return{data:{user:null,session:null},error:l};throw l}}async verifyOtp(t){var n,r;try{t.type!=="email_change"&&t.type!=="phone_change"&&await this._removeSession();let i,s;"options"in t&&(i=(n=t.options)===null||n===void 0?void 0:n.redirectTo,s=(r=t.options)===null||r===void 0?void 0:r.captchaToken);const{data:o,error:l}=await N(this.fetch,"POST",`${this.url}/verify`,{headers:this.headers,body:Object.assign(Object.assign({},t),{gotrue_meta_security:{captcha_token:s}}),redirectTo:i,xform:dt});if(l)throw l;if(!o)throw new Error("An error occurred on token verification.");const a=o.session,u=o.user;return a!=null&&a.access_token&&(await this._saveSession(a),await this._notifyAllSubscribers(t.type=="recovery"?"PASSWORD_RECOVERY":"SIGNED_IN",a)),{data:{user:u,session:a},error:null}}catch(i){if(I(i))return{data:{user:null,session:null},error:i};throw i}}async signInWithSSO(t){var n,r,i;try{await this._removeSession();let s=null,o=null;return this.flowType==="pkce"&&([s,o]=await sn(this.storage,this.storageKey)),await N(this.fetch,"POST",`${this.url}/sso`,{body:Object.assign(Object.assign(Object.assign(Object.assign(Object.assign({},"providerId"in t?{provider_id:t.providerId}:null),"domain"in t?{domain:t.domain}:null),{redirect_to:(r=(n=t.options)===null||n===void 0?void 0:n.redirectTo)!==null&&r!==void 0?r:void 0}),!((i=t==null?void 0:t.options)===null||i===void 0)&&i.captchaToken?{gotrue_meta_security:{captcha_token:t.options.captchaToken}}:null),{skip_http_redirect:!0,code_challenge:s,code_challenge_method:o}),headers:this.headers,xform:lg})}catch(s){if(I(s))return{data:null,error:s};throw s}}async reauthenticate(){return await this.initializePromise,await this._acquireLock(-1,async()=>await this._reauthenticate())}async _reauthenticate(){try{return await this._useSession(async t=>{const{data:{session:n},error:r}=t;if(r)throw r;if(!n)throw new Dt;const{error:i}=await N(this.fetch,"GET",`${this.url}/reauthenticate`,{headers:this.headers,jwt:n.access_token});return{data:{user:null,session:null},error:i}})}catch(t){if(I(t))return{data:{user:null,session:null},error:t};throw t}}async resend(t){try{t.type!="email_change"&&t.type!="phone_change"&&await this._removeSession();const n=`${this.url}/resend`;if("email"in t){const{email:r,type:i,options:s}=t,{error:o}=await N(this.fetch,"POST",n,{headers:this.headers,body:{email:r,type:i,gotrue_meta_security:{captcha_token:s==null?void 0:s.captchaToken}},redirectTo:s==null?void 0:s.emailRedirectTo});return{data:{user:null,session:null},error:o}}else if("phone"in t){const{phone:r,type:i,options:s}=t,{data:o,error:l}=await N(this.fetch,"POST",n,{headers:this.headers,body:{phone:r,type:i,gotrue_meta_security:{captcha_token:s==null?void 0:s.captchaToken}}});return{data:{user:null,session:null,messageId:o==null?void 0:o.message_id},error:l}}throw new oi("You must provide either an email or phone number and a type")}catch(n){if(I(n))return{data:{user:null,session:null},error:n};throw n}}async getSession(){return await this.initializePromise,await this._acquireLock(-1,async()=>this._useSession(async n=>n))}async _acquireLock(t,n){this._debug("#_acquireLock","begin",t);try{if(this.lockAcquired){const r=this.pendingInLock.length?this.pendingInLock[this.pendingInLock.length-1]:Promise.resolve(),i=(async()=>(await r,await n()))();return this.pendingInLock.push((async()=>{try{await i}catch{}})()),i}return await this.lock(`lock:${this.storageKey}`,t,async()=>{this._debug("#_acquireLock","lock acquired for storage key",this.storageKey);try{this.lockAcquired=!0;const r=n();for(this.pendingInLock.push((async()=>{try{await r}catch{}})()),await r;this.pendingInLock.length;){const i=[...this.pendingInLock];await Promise.all(i),this.pendingInLock.splice(0,i.length)}return await r}finally{this._debug("#_acquireLock","lock released for storage key",this.storageKey),this.lockAcquired=!1}})}finally{this._debug("#_acquireLock","end")}}async _useSession(t){this._debug("#_useSession","begin");try{const n=await this.__loadSession();return await t(n)}finally{this._debug("#_useSession","end")}}async __loadSession(){this._debug("#__loadSession()","begin"),this.lockAcquired||this._debug("#__loadSession()","used outside of an acquired lock!",new Error().stack);try{let t=null;const n=await si(this.storage,this.storageKey);if(this._debug("#getSession()","session from storage",n),n!==null&&(this._isValidSession(n)?t=n:(this._debug("#getSession()","session from storage is not valid"),await this._removeSession())),!t)return{data:{session:null},error:null};const r=t.expires_at?t.expires_at<=Date.now()/1e3:!1;if(this._debug("#__loadSession()",`session has${r?"":" not"} expired`,"expires_at",t.expires_at),!r){if(this.storage.isServer){const o=this.suppressGetSessionWarning;t=new Proxy(t,{get(a,u,c){return!o&&u==="user"&&console.warn("Using the user object as returned from supabase.auth.getSession() or from some supabase.auth.onAuthStateChange() events could be insecure! This value comes directly from the storage medium (usually cookies on the server) and many not be authentic. Use supabase.auth.getUser() instead which authenticates the data by contacting the Supabase Auth server."),Reflect.get(a,u,c)}})}return{data:{session:t},error:null}}const{session:i,error:s}=await this._callRefreshToken(t.refresh_token);return s?{data:{session:null},error:s}:{data:{session:i},error:null}}finally{this._debug("#__loadSession()","end")}}async getUser(t){return t?await this._getUser(t):(await this.initializePromise,await this._acquireLock(-1,async()=>await this._getUser()))}async _getUser(t){try{return t?await N(this.fetch,"GET",`${this.url}/user`,{headers:this.headers,jwt:t,xform:gt}):await this._useSession(async n=>{var r,i,s;const{data:o,error:l}=n;if(l)throw l;return!(!((r=o.session)===null||r===void 0)&&r.access_token)&&!this.hasCustomAuthorizationHeader?{data:{user:null},error:new Dt}:await N(this.fetch,"GET",`${this.url}/user`,{headers:this.headers,jwt:(s=(i=o.session)===null||i===void 0?void 0:i.access_token)!==null&&s!==void 0?s:void 0,xform:gt})})}catch(n){if(I(n))return{data:{user:null},error:n};throw n}}async updateUser(t,n={}){return await this.initializePromise,await this._acquireLock(-1,async()=>await this._updateUser(t,n))}async _updateUser(t,n={}){try{return await this._useSession(async r=>{const{data:i,error:s}=r;if(s)throw s;if(!i.session)throw new Dt;const o=i.session;let l=null,a=null;this.flowType==="pkce"&&t.email!=null&&([l,a]=await sn(this.storage,this.storageKey));const{data:u,error:c}=await N(this.fetch,"PUT",`${this.url}/user`,{headers:this.headers,redirectTo:n==null?void 0:n.emailRedirectTo,body:Object.assign(Object.assign({},t),{code_challenge:l,code_challenge_method:a}),jwt:o.access_token,xform:gt});if(c)throw c;return o.user=u.user,await this._saveSession(o),await this._notifyAllSubscribers("USER_UPDATED",o),{data:{user:o.user},error:null}})}catch(r){if(I(r))return{data:{user:null},error:r};throw r}}_decodeJWT(t){return ku(t)}async setSession(t){return await this.initializePromise,await this._acquireLock(-1,async()=>await this._setSession(t))}async _setSession(t){try{if(!t.access_token||!t.refresh_token)throw new Dt;const n=Date.now()/1e3;let r=n,i=!0,s=null;const o=ku(t.access_token);if(o.exp&&(r=o.exp,i=r<=n),i){const{session:l,error:a}=await this._callRefreshToken(t.refresh_token);if(a)return{data:{user:null,session:null},error:a};if(!l)return{data:{user:null,session:null},error:null};s=l}else{const{data:l,error:a}=await this._getUser(t.access_token);if(a)throw a;s={access_token:t.access_token,refresh_token:t.refresh_token,user:l.user,token_type:"bearer",expires_in:r-n,expires_at:r},await this._saveSession(s),await this._notifyAllSubscribers("SIGNED_IN",s)}return{data:{user:s.user,session:s},error:null}}catch(n){if(I(n))return{data:{session:null,user:null},error:n};throw n}}async refreshSession(t){return await this.initializePromise,await this._acquireLock(-1,async()=>await this._refreshSession(t))}async _refreshSession(t){try{return await this._useSession(async n=>{var r;if(!t){const{data:o,error:l}=n;if(l)throw l;t=(r=o.session)!==null&&r!==void 0?r:void 0}if(!(t!=null&&t.refresh_token))throw new Dt;const{session:i,error:s}=await this._callRefreshToken(t.refresh_token);return s?{data:{user:null,session:null},error:s}:i?{data:{user:i.user,session:i},error:null}:{data:{user:null,session:null},error:null}})}catch(n){if(I(n))return{data:{user:null,session:null},error:n};throw n}}async _getSessionFromURL(t){try{if(!De())throw new li("No browser detected.");if(this.flowType==="implicit"&&!this._isImplicitGrantFlow())throw new li("Not a valid implicit grant flow url.");if(this.flowType=="pkce"&&!t)throw new Eu("Not a valid PKCE flow url.");const n=Hs(window.location.href);if(t){if(!n.code)throw new Eu("No code detected.");const{data:f,error:v}=await this._exchangeCodeForSession(n.code);if(v)throw v;const w=new URL(window.location.href);return w.searchParams.delete("code"),window.history.replaceState(window.history.state,"",w.toString()),{data:{session:f.session,redirectType:null},error:null}}if(n.error||n.error_description||n.error_code)throw new li(n.error_description||"Error in URL with unspecified error_description",{error:n.error||"unspecified_error",code:n.error_code||"unspecified_code"});const{provider_token:r,provider_refresh_token:i,access_token:s,refresh_token:o,expires_in:l,expires_at:a,token_type:u}=n;if(!s||!l||!o||!u)throw new li("No session defined in URL");const c=Math.round(Date.now()/1e3),d=parseInt(l);let h=c+d;a&&(h=parseInt(a));const m=h-c;m*1e3<=Yn&&console.warn(`@supabase/gotrue-js: Session as retrieved from URL expires in ${m}s, should have been closer to ${d}s`);const g=h-d;c-g>=120?console.warn("@supabase/gotrue-js: Session as retrieved from URL was issued over 120s ago, URL could be stale",g,h,c):c-g<0&&console.warn("@supabase/gotrue-js: Session as retrieved from URL was issued in the future? Check the device clok for skew",g,h,c);const{data:y,error:_}=await this._getUser(s);if(_)throw _;const p={provider_token:r,provider_refresh_token:i,access_token:s,expires_in:d,expires_at:h,refresh_token:o,token_type:u,user:y.user};return window.location.hash="",this._debug("#_getSessionFromURL()","clearing window.location.hash"),{data:{session:p,redirectType:n.type},error:null}}catch(n){if(I(n))return{data:{session:null,redirectType:null},error:n};throw n}}_isImplicitGrantFlow(){const t=Hs(window.location.href);return!!(De()&&(t.access_token||t.error_description))}async _isPKCEFlow(){const t=Hs(window.location.href),n=await si(this.storage,`${this.storageKey}-code-verifier`);return!!(t.code&&n)}async signOut(t={scope:"global"}){return await this.initializePromise,await this._acquireLock(-1,async()=>await this._signOut(t))}async _signOut({scope:t}={scope:"global"}){return await this._useSession(async n=>{var r;const{data:i,error:s}=n;if(s)return{error:s};const o=(r=i.session)===null||r===void 0?void 0:r.access_token;if(o){const{error:l}=await this.admin.signOut(o,t);if(l&&!(ng(l)&&(l.status===404||l.status===401||l.status===403)))return{error:l}}return t!=="others"&&(await this._removeSession(),await Ws(this.storage,`${this.storageKey}-code-verifier`),await this._notifyAllSubscribers("SIGNED_OUT",null)),{error:null}})}onAuthStateChange(t){const n=Vm(),r={id:n,callback:t,unsubscribe:()=>{this._debug("#unsubscribe()","state change callback with id removed",n),this.stateChangeEmitters.delete(n)}};return this._debug("#onAuthStateChange()","registered callback with id",n),this.stateChangeEmitters.set(n,r),(async()=>(await this.initializePromise,await this._acquireLock(-1,async()=>{this._emitInitialSession(n)})))(),{data:{subscription:r}}}async _emitInitialSession(t){return await this._useSession(async n=>{var r,i;try{const{data:{session:s},error:o}=n;if(o)throw o;await((r=this.stateChangeEmitters.get(t))===null||r===void 0?void 0:r.callback("INITIAL_SESSION",s)),this._debug("INITIAL_SESSION","callback id",t,"session",s)}catch(s){await((i=this.stateChangeEmitters.get(t))===null||i===void 0?void 0:i.callback("INITIAL_SESSION",null)),this._debug("INITIAL_SESSION","callback id",t,"error",s),console.error(s)}})}async resetPasswordForEmail(t,n={}){let r=null,i=null;this.flowType==="pkce"&&([r,i]=await sn(this.storage,this.storageKey,!0));try{return await N(this.fetch,"POST",`${this.url}/recover`,{body:{email:t,code_challenge:r,code_challenge_method:i,gotrue_meta_security:{captcha_token:n.captchaToken}},headers:this.headers,redirectTo:n.redirectTo})}catch(s){if(I(s))return{data:null,error:s};throw s}}async getUserIdentities(){var t;try{const{data:n,error:r}=await this.getUser();if(r)throw r;return{data:{identities:(t=n.user.identities)!==null&&t!==void 0?t:[]},error:null}}catch(n){if(I(n))return{data:null,error:n};throw n}}async linkIdentity(t){var n;try{const{data:r,error:i}=await this._useSession(async s=>{var o,l,a,u,c;const{data:d,error:h}=s;if(h)throw h;const m=await this._getUrlForProvider(`${this.url}/user/identities/authorize`,t.provider,{redirectTo:(o=t.options)===null||o===void 0?void 0:o.redirectTo,scopes:(l=t.options)===null||l===void 0?void 0:l.scopes,queryParams:(a=t.options)===null||a===void 0?void 0:a.queryParams,skipBrowserRedirect:!0});return await N(this.fetch,"GET",m,{headers:this.headers,jwt:(c=(u=d.session)===null||u===void 0?void 0:u.access_token)!==null&&c!==void 0?c:void 0})});if(i)throw i;return De()&&!(!((n=t.options)===null||n===void 0)&&n.skipBrowserRedirect)&&window.location.assign(r==null?void 0:r.url),{data:{provider:t.provider,url:r==null?void 0:r.url},error:null}}catch(r){if(I(r))return{data:{provider:t.provider,url:null},error:r};throw r}}async unlinkIdentity(t){try{return await this._useSession(async n=>{var r,i;const{data:s,error:o}=n;if(o)throw o;return await N(this.fetch,"DELETE",`${this.url}/user/identities/${t.identity_id}`,{headers:this.headers,jwt:(i=(r=s.session)===null||r===void 0?void 0:r.access_token)!==null&&i!==void 0?i:void 0})})}catch(n){if(I(n))return{data:null,error:n};throw n}}async _refreshAccessToken(t){const n=`#_refreshAccessToken(${t.substring(0,5)}...)`;this._debug(n,"begin");try{const r=Date.now();return await Gm(async i=>(i>0&&await Km(200*Math.pow(2,i-1)),this._debug(n,"refreshing attempt",i),await N(this.fetch,"POST",`${this.url}/token?grant_type=refresh_token`,{body:{refresh_token:t},headers:this.headers,xform:dt})),(i,s)=>{const o=200*Math.pow(2,i);return s&&Gs(s)&&Date.now()+o-r<Yn})}catch(r){if(this._debug(n,"error",r),I(r))return{data:{session:null,user:null},error:r};throw r}finally{this._debug(n,"end")}}_isValidSession(t){return typeof t=="object"&&t!==null&&"access_token"in t&&"refresh_token"in t&&"expires_at"in t}async _handleProviderSignIn(t,n){const r=await this._getUrlForProvider(`${this.url}/authorize`,t,{redirectTo:n.redirectTo,scopes:n.scopes,queryParams:n.queryParams});return this._debug("#_handleProviderSignIn()","provider",t,"options",n,"url",r),De()&&!n.skipBrowserRedirect&&window.location.assign(r),{data:{provider:t,url:r},error:null}}async _recoverAndRefresh(){var t;const n="#_recoverAndRefresh()";this._debug(n,"begin");try{const r=await si(this.storage,this.storageKey);if(this._debug(n,"session from storage",r),!this._isValidSession(r)){this._debug(n,"session is not valid"),r!==null&&await this._removeSession();return}const i=Math.round(Date.now()/1e3),s=((t=r.expires_at)!==null&&t!==void 0?t:1/0)<i+Su;if(this._debug(n,`session has${s?"":" not"} expired with margin of ${Su}s`),s){if(this.autoRefreshToken&&r.refresh_token){const{error:o}=await this._callRefreshToken(r.refresh_token);o&&(console.error(o),Gs(o)||(this._debug(n,"refresh failed with a non-retryable error, removing the session",o),await this._removeSession()))}}else await this._notifyAllSubscribers("SIGNED_IN",r)}catch(r){this._debug(n,"error",r),console.error(r);return}finally{this._debug(n,"end")}}async _callRefreshToken(t){var n,r;if(!t)throw new Dt;if(this.refreshingDeferred)return this.refreshingDeferred.promise;const i=`#_callRefreshToken(${t.substring(0,5)}...)`;this._debug(i,"begin");try{this.refreshingDeferred=new hs;const{data:s,error:o}=await this._refreshAccessToken(t);if(o)throw o;if(!s.session)throw new Dt;await this._saveSession(s.session),await this._notifyAllSubscribers("TOKEN_REFRESHED",s.session);const l={session:s.session,error:null};return this.refreshingDeferred.resolve(l),l}catch(s){if(this._debug(i,"error",s),I(s)){const o={session:null,error:s};return Gs(s)||(await this._removeSession(),await this._notifyAllSubscribers("SIGNED_OUT",null)),(n=this.refreshingDeferred)===null||n===void 0||n.resolve(o),o}throw(r=this.refreshingDeferred)===null||r===void 0||r.reject(s),s}finally{this.refreshingDeferred=null,this._debug(i,"end")}}async _notifyAllSubscribers(t,n,r=!0){const i=`#_notifyAllSubscribers(${t})`;this._debug(i,"begin",n,`broadcast = ${r}`);try{this.broadcastChannel&&r&&this.broadcastChannel.postMessage({event:t,session:n});const s=[],o=Array.from(this.stateChangeEmitters.values()).map(async l=>{try{await l.callback(t,n)}catch(a){s.push(a)}});if(await Promise.all(o),s.length>0){for(let l=0;l<s.length;l+=1)console.error(s[l]);throw s[0]}}finally{this._debug(i,"end")}}async _saveSession(t){this._debug("#_saveSession()",t),this.suppressGetSessionWarning=!0,await df(this.storage,this.storageKey,t)}async _removeSession(){this._debug("#_removeSession()"),await Ws(this.storage,this.storageKey)}_removeVisibilityChangedCallback(){this._debug("#_removeVisibilityChangedCallback()");const t=this.visibilityChangedCallback;this.visibilityChangedCallback=null;try{t&&De()&&(window!=null&&window.removeEventListener)&&window.removeEventListener("visibilitychange",t)}catch(n){console.error("removing visibilitychange callback failed",n)}}async _startAutoRefresh(){await this._stopAutoRefresh(),this._debug("#_startAutoRefresh()");const t=setInterval(()=>this._autoRefreshTokenTick(),Yn);this.autoRefreshTicker=t,t&&typeof t=="object"&&typeof t.unref=="function"?t.unref():typeof Deno<"u"&&typeof Deno.unrefTimer=="function"&&Deno.unrefTimer(t),setTimeout(async()=>{await this.initializePromise,await this._autoRefreshTokenTick()},0)}async _stopAutoRefresh(){this._debug("#_stopAutoRefresh()");const t=this.autoRefreshTicker;this.autoRefreshTicker=null,t&&clearInterval(t)}async startAutoRefresh(){this._removeVisibilityChangedCallback(),await this._startAutoRefresh()}async stopAutoRefresh(){this._removeVisibilityChangedCallback(),await this._stopAutoRefresh()}async _autoRefreshTokenTick(){this._debug("#_autoRefreshTokenTick()","begin");try{await this._acquireLock(0,async()=>{try{const t=Date.now();try{return await this._useSession(async n=>{const{data:{session:r}}=n;if(!r||!r.refresh_token||!r.expires_at){this._debug("#_autoRefreshTokenTick()","no session");return}const i=Math.floor((r.expires_at*1e3-t)/Yn);this._debug("#_autoRefreshTokenTick()",`access token expires in ${i} ticks, a tick lasts ${Yn}ms, refresh threshold is ${Ou} ticks`),i<=Ou&&await this._callRefreshToken(r.refresh_token)})}catch(n){console.error("Auto refresh tick failed with error. This is likely a transient error.",n)}}finally{this._debug("#_autoRefreshTokenTick()","end")}})}catch(t){if(t.isAcquireTimeout||t instanceof hf)this._debug("auto refresh token tick lock not available");else throw t}}async _handleVisibilityChange(){if(this._debug("#_handleVisibilityChange()"),!De()||!(window!=null&&window.addEventListener))return this.autoRefreshToken&&this.startAutoRefresh(),!1;try{this.visibilityChangedCallback=async()=>await this._onVisibilityChanged(!1),window==null||window.addEventListener("visibilitychange",this.visibilityChangedCallback),await this._onVisibilityChanged(!0)}catch(t){console.error("_handleVisibilityChange",t)}}async _onVisibilityChanged(t){const n=`#_onVisibilityChanged(${t})`;this._debug(n,"visibilityState",document.visibilityState),document.visibilityState==="visible"?(this.autoRefreshToken&&this._startAutoRefresh(),t||(await this.initializePromise,await this._acquireLock(-1,async()=>{if(document.visibilityState!=="visible"){this._debug(n,"acquired the lock to recover the session, but the browser visibilityState is no longer visible, aborting");return}await this._recoverAndRefresh()}))):document.visibilityState==="hidden"&&this.autoRefreshToken&&this._stopAutoRefresh()}async _getUrlForProvider(t,n,r){const i=[`provider=${encodeURIComponent(n)}`];if(r!=null&&r.redirectTo&&i.push(`redirect_to=${encodeURIComponent(r.redirectTo)}`),r!=null&&r.scopes&&i.push(`scopes=${encodeURIComponent(r.scopes)}`),this.flowType==="pkce"){const[s,o]=await sn(this.storage,this.storageKey),l=new URLSearchParams({code_challenge:`${encodeURIComponent(s)}`,code_challenge_method:`${encodeURIComponent(o)}`});i.push(l.toString())}if(r!=null&&r.queryParams){const s=new URLSearchParams(r.queryParams);i.push(s.toString())}return r!=null&&r.skipBrowserRedirect&&i.push(`skip_http_redirect=${r.skipBrowserRedirect}`),`${t}?${i.join("&")}`}async _unenroll(t){try{return await this._useSession(async n=>{var r;const{data:i,error:s}=n;return s?{data:null,error:s}:await N(this.fetch,"DELETE",`${this.url}/factors/${t.factorId}`,{headers:this.headers,jwt:(r=i==null?void 0:i.session)===null||r===void 0?void 0:r.access_token})})}catch(n){if(I(n))return{data:null,error:n};throw n}}async _enroll(t){try{return await this._useSession(async n=>{var r,i;const{data:s,error:o}=n;if(o)return{data:null,error:o};const{data:l,error:a}=await N(this.fetch,"POST",`${this.url}/factors`,{body:{friendly_name:t.friendlyName,factor_type:t.factorType,issuer:t.issuer},headers:this.headers,jwt:(r=s==null?void 0:s.session)===null||r===void 0?void 0:r.access_token});return a?{data:null,error:a}:(!((i=l==null?void 0:l.totp)===null||i===void 0)&&i.qr_code&&(l.totp.qr_code=`data:image/svg+xml;utf-8,${l.totp.qr_code}`),{data:l,error:null})})}catch(n){if(I(n))return{data:null,error:n};throw n}}async _verify(t){return this._acquireLock(-1,async()=>{try{return await this._useSession(async n=>{var r;const{data:i,error:s}=n;if(s)return{data:null,error:s};const{data:o,error:l}=await N(this.fetch,"POST",`${this.url}/factors/${t.factorId}/verify`,{body:{code:t.code,challenge_id:t.challengeId},headers:this.headers,jwt:(r=i==null?void 0:i.session)===null||r===void 0?void 0:r.access_token});return l?{data:null,error:l}:(await this._saveSession(Object.assign({expires_at:Math.round(Date.now()/1e3)+o.expires_in},o)),await this._notifyAllSubscribers("MFA_CHALLENGE_VERIFIED",o),{data:o,error:l})})}catch(n){if(I(n))return{data:null,error:n};throw n}})}async _challenge(t){return this._acquireLock(-1,async()=>{try{return await this._useSession(async n=>{var r;const{data:i,error:s}=n;return s?{data:null,error:s}:await N(this.fetch,"POST",`${this.url}/factors/${t.factorId}/challenge`,{headers:this.headers,jwt:(r=i==null?void 0:i.session)===null||r===void 0?void 0:r.access_token})})}catch(n){if(I(n))return{data:null,error:n};throw n}})}async _challengeAndVerify(t){const{data:n,error:r}=await this._challenge({factorId:t.factorId});return r?{data:null,error:r}:await this._verify({factorId:t.factorId,challengeId:n.id,code:t.code})}async _listFactors(){const{data:{user:t},error:n}=await this.getUser();if(n)return{data:null,error:n};const r=(t==null?void 0:t.factors)||[],i=r.filter(s=>s.factor_type==="totp"&&s.status==="verified");return{data:{all:r,totp:i},error:null}}async _getAuthenticatorAssuranceLevel(){return this._acquireLock(-1,async()=>await this._useSession(async t=>{var n,r;const{data:{session:i},error:s}=t;if(s)return{data:null,error:s};if(!i)return{data:{currentLevel:null,nextLevel:null,currentAuthenticationMethods:[]},error:null};const o=this._decodeJWT(i.access_token);let l=null;o.aal&&(l=o.aal);let a=l;((r=(n=i.user.factors)===null||n===void 0?void 0:n.filter(d=>d.status==="verified"))!==null&&r!==void 0?r:[]).length>0&&(a="aal2");const c=o.amr||[];return{data:{currentLevel:l,nextLevel:a,currentAuthenticationMethods:c},error:null}}))}}$r.nextInstanceID=0;const yg=$r;class wg extends yg{constructor(t){super(t)}}var _g=function(e,t,n,r){function i(s){return s instanceof n?s:new n(function(o){o(s)})}return new(n||(n=Promise))(function(s,o){function l(c){try{u(r.next(c))}catch(d){o(d)}}function a(c){try{u(r.throw(c))}catch(d){o(d)}}function u(c){c.done?s(c.value):i(c.value).then(l,a)}u((r=r.apply(e,t||[])).next())})};class Sg{constructor(t,n,r){var i,s,o;if(this.supabaseUrl=t,this.supabaseKey=n,!t)throw new Error("supabaseUrl is required.");if(!n)throw new Error("supabaseKey is required.");const l=Dm(t);this.realtimeUrl=`${l}/realtime/v1`.replace(/^http/i,"ws"),this.authUrl=`${l}/auth/v1`,this.storageUrl=`${l}/storage/v1`,this.functionsUrl=`${l}/functions/v1`;const a=`sb-${new URL(this.authUrl).hostname.split(".")[0]}-auth-token`,u={db:jm,realtime:Im,auth:Object.assign(Object.assign({},Lm),{storageKey:a}),global:Rm},c=zm(r??{},u);this.storageKey=(i=c.auth.storageKey)!==null&&i!==void 0?i:"",this.headers=(s=c.global.headers)!==null&&s!==void 0?s:{},this.auth=this._initSupabaseAuthClient((o=c.auth)!==null&&o!==void 0?o:{},this.headers,c.global.fetch),this.fetch=Um(n,this._getAccessToken.bind(this),c.global.fetch),this.realtime=this._initRealtimeClient(Object.assign({headers:this.headers},c.realtime)),this.rest=new Gl(`${l}/rest/v1`,{headers:this.headers,schema:c.db.schema,fetch:this.fetch}),this._listenForAuthEvents()}get functions(){return new Vv(this.functionsUrl,{headers:this.headers,customFetch:this.fetch})}get storage(){return new Pm(this.storageUrl,this.headers,this.fetch)}from(t){return this.rest.from(t)}schema(t){return this.rest.schema(t)}rpc(t,n={},r={}){return this.rest.rpc(t,n,r)}channel(t,n={config:{}}){return this.realtime.channel(t,n)}getChannels(){return this.realtime.getChannels()}removeChannel(t){return this.realtime.removeChannel(t)}removeAllChannels(){return this.realtime.removeAllChannels()}_getAccessToken(){var t,n;return _g(this,void 0,void 0,function*(){const{data:r}=yield this.auth.getSession();return(n=(t=r.session)===null||t===void 0?void 0:t.access_token)!==null&&n!==void 0?n:null})}_initSupabaseAuthClient({autoRefreshToken:t,persistSession:n,detectSessionInUrl:r,storage:i,storageKey:s,flowType:o,debug:l},a,u){var c;const d={Authorization:`Bearer ${this.supabaseKey}`,apikey:`${this.supabaseKey}`};return new wg({url:this.authUrl,headers:Object.assign(Object.assign({},d),a),storageKey:s,autoRefreshToken:t,persistSession:n,detectSessionInUrl:r,storage:i,flowType:o,debug:l,fetch:u,hasCustomAuthorizationHeader:(c="Authorization"in this.headers)!==null&&c!==void 0?c:!1})}_initRealtimeClient(t){return new hm(this.realtimeUrl,Object.assign(Object.assign({},t),{params:Object.assign({apikey:this.supabaseKey},t==null?void 0:t.params)}))}_listenForAuthEvents(){return this.auth.onAuthStateChange((n,r)=>{this._handleTokenChanged(n,"CLIENT",r==null?void 0:r.access_token)})}_handleTokenChanged(t,n,r){(t==="TOKEN_REFRESHED"||t==="SIGNED_IN")&&this.changedAccessToken!==r?(this.realtime.setAuth(r??null),this.changedAccessToken=r):t==="SIGNED_OUT"&&(this.realtime.setAuth(this.supabaseKey),n=="STORAGE"&&this.auth.signOut(),this.changedAccessToken=void 0)}}const kg=(e,t,n)=>new Sg(e,t,n);function Eg(e){const t=Xd(),[n,r]=E.useState([]);E.useEffect(()=>{e.session||t("/login")},[e.session]);const i=E.useCallback(async()=>{const{data:s,error:o}=await e.supabase.from("file").select();if(o){console.error(o);return}r(s.map(l=>l))},[e.supabase]);return E.useEffect(()=>{i()},[]),z.jsx(z.Fragment,{children:z.jsxs("div",{children:[z.jsx("h1",{children:"Home"}),z.jsx("p",{children:"Logged in!"}),n.map(s=>z.jsx("div",{children:z.jsxs("p",{children:["file: ",s.absolute_path]})},s.id))]})})}function Cg(e={}){const{nonce:t,onScriptLoadSuccess:n,onScriptLoadError:r}=e,[i,s]=E.useState(!1),o=E.useRef(n);o.current=n;const l=E.useRef(r);return l.current=r,E.useEffect(()=>{const a=document.createElement("script");return a.src="https://accounts.google.com/gsi/client",a.async=!0,a.defer=!0,a.nonce=t,a.onload=()=>{var u;s(!0),(u=o.current)===null||u===void 0||u.call(o)},a.onerror=()=>{var u;s(!1),(u=l.current)===null||u===void 0||u.call(l)},document.body.appendChild(a),()=>{document.body.removeChild(a)}},[t]),i}const pf=E.createContext(null);function xg({clientId:e,nonce:t,onScriptLoadSuccess:n,onScriptLoadError:r,children:i}){const s=Cg({nonce:t,onScriptLoadSuccess:n,onScriptLoadError:r}),o=E.useMemo(()=>({clientId:e,scriptLoadedSuccessfully:s}),[e,s]);return Gi.createElement(pf.Provider,{value:o},i)}function Pg(){const e=E.useContext(pf);if(!e)throw new Error("Google OAuth components must be used within GoogleOAuthProvider");return e}function Tg(e){var t;return(t=e==null?void 0:e.clientId)!==null&&t!==void 0?t:e==null?void 0:e.client_id}const Og={large:40,medium:32,small:20};function Rg({onSuccess:e,onError:t,useOneTap:n,promptMomentNotification:r,type:i="standard",theme:s="outline",size:o="large",text:l,shape:a,logo_alignment:u,width:c,locale:d,click_listener:h,containerProps:m,...g}){const y=E.useRef(null),{clientId:_,scriptLoadedSuccessfully:p}=Pg(),f=E.useRef(e);f.current=e;const v=E.useRef(t);v.current=t;const w=E.useRef(r);return w.current=r,E.useEffect(()=>{var k,P,T,O,M,j,de,qe,Ye;if(p)return(T=(P=(k=window==null?void 0:window.google)===null||k===void 0?void 0:k.accounts)===null||P===void 0?void 0:P.id)===null||T===void 0||T.initialize({client_id:_,callback:Oe=>{var Xe;if(!(Oe!=null&&Oe.credential))return(Xe=v.current)===null||Xe===void 0?void 0:Xe.call(v);const{credential:Ze,select_by:Bn}=Oe;f.current({credential:Ze,clientId:Tg(Oe),select_by:Bn})},...g}),(j=(M=(O=window==null?void 0:window.google)===null||O===void 0?void 0:O.accounts)===null||M===void 0?void 0:M.id)===null||j===void 0||j.renderButton(y.current,{type:i,theme:s,size:o,text:l,shape:a,logo_alignment:u,width:c,locale:d,click_listener:h}),n&&((Ye=(qe=(de=window==null?void 0:window.google)===null||de===void 0?void 0:de.accounts)===null||qe===void 0?void 0:qe.id)===null||Ye===void 0||Ye.prompt(w.current)),()=>{var Oe,Xe,Ze;n&&((Ze=(Xe=(Oe=window==null?void 0:window.google)===null||Oe===void 0?void 0:Oe.accounts)===null||Xe===void 0?void 0:Xe.id)===null||Ze===void 0||Ze.cancel())}},[_,p,n,i,s,o,l,a,u,c,d]),Gi.createElement("div",{...m,ref:y,style:{height:Og[o],...m==null?void 0:m.style}})}function jg(e){const t=Xd();return E.useEffect(()=>{e.supabase.auth.getSession().then(({data:{session:r}})=>{e.setSession(r),console.log("LOGIN SESSION",r)});const{data:{subscription:n}}=e.supabase.auth.onAuthStateChange((r,i)=>{e.setSession(i),console.log("SESSION CHANGE",i)});return()=>n.unsubscribe()},[]),E.useEffect(()=>{e.session&&t("/")},[e.session]),z.jsxs(z.Fragment,{children:[z.jsxs("div",{children:[z.jsx("h1",{children:"Login"}),z.jsxs("p",{children:["Log in to access your account! ",JSON.stringify(e.session)]})]}),z.jsx(xg,{clientId:"952965459060-nrnrsdoq22mf646vfa72hk410pvdda5q.apps.googleusercontent.com",children:z.jsx(Rg,{onSuccess:async n=>{await e.supabase.auth.signInWithIdToken({provider:"google",token:n.credential})},onError:()=>{console.log("Login Failed")}})})]})}const ju=kg("https://slpoocycjgqsuoedhkbn.supabase.co","eyJhbGciOiJIUzI1NiIsInR5cCI6IkpXVCJ9.eyJpc3MiOiJzdXBhYmFzZSIsInJlZiI6InNscG9vY3ljamdxc3VvZWRoa2JuIiwicm9sZSI6ImFub24iLCJpYXQiOjE3MTUyMDU0MjUsImV4cCI6MjAzMDc4MTQyNX0.xZYRTRN65rlms1Hb96IBAQvw3EGtMzUxlGPP5TVey34");function Lg(){const[e,t]=E.useState(null);return z.jsx(z.Fragment,{children:z.jsx(Av,{basename:"/fs-tracer-frontend",children:z.jsxs(Iv,{children:[z.jsx(_i,{index:!0,element:z.jsx(Eg,{supabase:ju,session:e})}),z.jsx(_i,{path:"login",element:z.jsx(jg,{supabase:ju,session:e,setSession:t})}),z.jsx(_i,{path:"*",element:z.jsx("p",{children:"notfound"})})]})})})}Qs.createRoot(document.getElementById("root")).render(z.jsx(Gi.StrictMode,{children:z.jsx(Lg,{})}));export{mf as g}; diff --git a/assets/index-CYv8RTDj.js b/assets/index-CYv8RTDj.js deleted file mode 100644 index 0ffd67e..0000000 --- a/assets/index-CYv8RTDj.js +++ /dev/null @@ -1,67 +0,0 @@ -function fh(e,t){for(var n=0;n<t.length;n++){const r=t[n];if(typeof r!="string"&&!Array.isArray(r)){for(const i in r)if(i!=="default"&&!(i in e)){const s=Object.getOwnPropertyDescriptor(r,i);s&&Object.defineProperty(e,i,s.get?s:{enumerable:!0,get:()=>r[i]})}}}return Object.freeze(Object.defineProperty(e,Symbol.toStringTag,{value:"Module"}))}(function(){const t=document.createElement("link").relList;if(t&&t.supports&&t.supports("modulepreload"))return;for(const i of document.querySelectorAll('link[rel="modulepreload"]'))r(i);new MutationObserver(i=>{for(const s of i)if(s.type==="childList")for(const o of s.addedNodes)o.tagName==="LINK"&&o.rel==="modulepreload"&&r(o)}).observe(document,{childList:!0,subtree:!0});function n(i){const s={};return i.integrity&&(s.integrity=i.integrity),i.referrerPolicy&&(s.referrerPolicy=i.referrerPolicy),i.crossOrigin==="use-credentials"?s.credentials="include":i.crossOrigin==="anonymous"?s.credentials="omit":s.credentials="same-origin",s}function r(i){if(i.ep)return;i.ep=!0;const s=n(i);fetch(i.href,s)}})();function ph(e){return e&&e.__esModule&&Object.prototype.hasOwnProperty.call(e,"default")?e.default:e}var Ru={exports:{}},Bi={},ju={exports:{}},I={};/** - * @license React - * react.production.min.js - * - * Copyright (c) Facebook, Inc. and its affiliates. - * - * This source code is licensed under the MIT license found in the - * LICENSE file in the root directory of this source tree. - */var jr=Symbol.for("react.element"),mh=Symbol.for("react.portal"),vh=Symbol.for("react.fragment"),gh=Symbol.for("react.strict_mode"),yh=Symbol.for("react.profiler"),wh=Symbol.for("react.provider"),_h=Symbol.for("react.context"),kh=Symbol.for("react.forward_ref"),Sh=Symbol.for("react.suspense"),Eh=Symbol.for("react.memo"),Ch=Symbol.for("react.lazy"),Jl=Symbol.iterator;function xh(e){return e===null||typeof e!="object"?null:(e=Jl&&e[Jl]||e["@@iterator"],typeof e=="function"?e:null)}var Lu={isMounted:function(){return!1},enqueueForceUpdate:function(){},enqueueReplaceState:function(){},enqueueSetState:function(){}},Iu=Object.assign,$u={};function Ln(e,t,n){this.props=e,this.context=t,this.refs=$u,this.updater=n||Lu}Ln.prototype.isReactComponent={};Ln.prototype.setState=function(e,t){if(typeof e!="object"&&typeof e!="function"&&e!=null)throw Error("setState(...): takes an object of state variables to update or a function which returns an object of state variables.");this.updater.enqueueSetState(this,e,t,"setState")};Ln.prototype.forceUpdate=function(e){this.updater.enqueueForceUpdate(this,e,"forceUpdate")};function Nu(){}Nu.prototype=Ln.prototype;function Qo(e,t,n){this.props=e,this.context=t,this.refs=$u,this.updater=n||Lu}var Go=Qo.prototype=new Nu;Go.constructor=Qo;Iu(Go,Ln.prototype);Go.isPureReactComponent=!0;var ql=Array.isArray,Au=Object.prototype.hasOwnProperty,Jo={current:null},Uu={key:!0,ref:!0,__self:!0,__source:!0};function Du(e,t,n){var r,i={},s=null,o=null;if(t!=null)for(r in t.ref!==void 0&&(o=t.ref),t.key!==void 0&&(s=""+t.key),t)Au.call(t,r)&&!Uu.hasOwnProperty(r)&&(i[r]=t[r]);var l=arguments.length-2;if(l===1)i.children=n;else if(1<l){for(var a=Array(l),u=0;u<l;u++)a[u]=arguments[u+2];i.children=a}if(e&&e.defaultProps)for(r in l=e.defaultProps,l)i[r]===void 0&&(i[r]=l[r]);return{$$typeof:jr,type:e,key:s,ref:o,props:i,_owner:Jo.current}}function Ph(e,t){return{$$typeof:jr,type:e.type,key:t,ref:e.ref,props:e.props,_owner:e._owner}}function qo(e){return typeof e=="object"&&e!==null&&e.$$typeof===jr}function Th(e){var t={"=":"=0",":":"=2"};return"$"+e.replace(/[=:]/g,function(n){return t[n]})}var Yl=/\/+/g;function hs(e,t){return typeof e=="object"&&e!==null&&e.key!=null?Th(""+e.key):t.toString(36)}function ii(e,t,n,r,i){var s=typeof e;(s==="undefined"||s==="boolean")&&(e=null);var o=!1;if(e===null)o=!0;else switch(s){case"string":case"number":o=!0;break;case"object":switch(e.$$typeof){case jr:case mh:o=!0}}if(o)return o=e,i=i(o),e=r===""?"."+hs(o,0):r,ql(i)?(n="",e!=null&&(n=e.replace(Yl,"$&/")+"/"),ii(i,t,n,"",function(u){return u})):i!=null&&(qo(i)&&(i=Ph(i,n+(!i.key||o&&o.key===i.key?"":(""+i.key).replace(Yl,"$&/")+"/")+e)),t.push(i)),1;if(o=0,r=r===""?".":r+":",ql(e))for(var l=0;l<e.length;l++){s=e[l];var a=r+hs(s,l);o+=ii(s,t,n,a,i)}else if(a=xh(e),typeof a=="function")for(e=a.call(e),l=0;!(s=e.next()).done;)s=s.value,a=r+hs(s,l++),o+=ii(s,t,n,a,i);else if(s==="object")throw t=String(e),Error("Objects are not valid as a React child (found: "+(t==="[object Object]"?"object with keys {"+Object.keys(e).join(", ")+"}":t)+"). If you meant to render a collection of children, use an array instead.");return o}function zr(e,t,n){if(e==null)return e;var r=[],i=0;return ii(e,r,"","",function(s){return t.call(n,s,i++)}),r}function Oh(e){if(e._status===-1){var t=e._result;t=t(),t.then(function(n){(e._status===0||e._status===-1)&&(e._status=1,e._result=n)},function(n){(e._status===0||e._status===-1)&&(e._status=2,e._result=n)}),e._status===-1&&(e._status=0,e._result=t)}if(e._status===1)return e._result.default;throw e._result}var fe={current:null},si={transition:null},Rh={ReactCurrentDispatcher:fe,ReactCurrentBatchConfig:si,ReactCurrentOwner:Jo};function zu(){throw Error("act(...) is not supported in production builds of React.")}I.Children={map:zr,forEach:function(e,t,n){zr(e,function(){t.apply(this,arguments)},n)},count:function(e){var t=0;return zr(e,function(){t++}),t},toArray:function(e){return zr(e,function(t){return t})||[]},only:function(e){if(!qo(e))throw Error("React.Children.only expected to receive a single React element child.");return e}};I.Component=Ln;I.Fragment=vh;I.Profiler=yh;I.PureComponent=Qo;I.StrictMode=gh;I.Suspense=Sh;I.__SECRET_INTERNALS_DO_NOT_USE_OR_YOU_WILL_BE_FIRED=Rh;I.act=zu;I.cloneElement=function(e,t,n){if(e==null)throw Error("React.cloneElement(...): The argument must be a React element, but you passed "+e+".");var r=Iu({},e.props),i=e.key,s=e.ref,o=e._owner;if(t!=null){if(t.ref!==void 0&&(s=t.ref,o=Jo.current),t.key!==void 0&&(i=""+t.key),e.type&&e.type.defaultProps)var l=e.type.defaultProps;for(a in t)Au.call(t,a)&&!Uu.hasOwnProperty(a)&&(r[a]=t[a]===void 0&&l!==void 0?l[a]:t[a])}var a=arguments.length-2;if(a===1)r.children=n;else if(1<a){l=Array(a);for(var u=0;u<a;u++)l[u]=arguments[u+2];r.children=l}return{$$typeof:jr,type:e.type,key:i,ref:s,props:r,_owner:o}};I.createContext=function(e){return e={$$typeof:_h,_currentValue:e,_currentValue2:e,_threadCount:0,Provider:null,Consumer:null,_defaultValue:null,_globalName:null},e.Provider={$$typeof:wh,_context:e},e.Consumer=e};I.createElement=Du;I.createFactory=function(e){var t=Du.bind(null,e);return t.type=e,t};I.createRef=function(){return{current:null}};I.forwardRef=function(e){return{$$typeof:kh,render:e}};I.isValidElement=qo;I.lazy=function(e){return{$$typeof:Ch,_payload:{_status:-1,_result:e},_init:Oh}};I.memo=function(e,t){return{$$typeof:Eh,type:e,compare:t===void 0?null:t}};I.startTransition=function(e){var t=si.transition;si.transition={};try{e()}finally{si.transition=t}};I.unstable_act=zu;I.useCallback=function(e,t){return fe.current.useCallback(e,t)};I.useContext=function(e){return fe.current.useContext(e)};I.useDebugValue=function(){};I.useDeferredValue=function(e){return fe.current.useDeferredValue(e)};I.useEffect=function(e,t){return fe.current.useEffect(e,t)};I.useId=function(){return fe.current.useId()};I.useImperativeHandle=function(e,t,n){return fe.current.useImperativeHandle(e,t,n)};I.useInsertionEffect=function(e,t){return fe.current.useInsertionEffect(e,t)};I.useLayoutEffect=function(e,t){return fe.current.useLayoutEffect(e,t)};I.useMemo=function(e,t){return fe.current.useMemo(e,t)};I.useReducer=function(e,t,n){return fe.current.useReducer(e,t,n)};I.useRef=function(e){return fe.current.useRef(e)};I.useState=function(e){return fe.current.useState(e)};I.useSyncExternalStore=function(e,t,n){return fe.current.useSyncExternalStore(e,t,n)};I.useTransition=function(){return fe.current.useTransition()};I.version="18.3.1";ju.exports=I;var x=ju.exports;const Fu=ph(x),jh=fh({__proto__:null,default:Fu},[x]);/** - * @license React - * react-jsx-runtime.production.min.js - * - * Copyright (c) Facebook, Inc. and its affiliates. - * - * This source code is licensed under the MIT license found in the - * LICENSE file in the root directory of this source tree. - */var Lh=x,Ih=Symbol.for("react.element"),$h=Symbol.for("react.fragment"),Nh=Object.prototype.hasOwnProperty,Ah=Lh.__SECRET_INTERNALS_DO_NOT_USE_OR_YOU_WILL_BE_FIRED.ReactCurrentOwner,Uh={key:!0,ref:!0,__self:!0,__source:!0};function Mu(e,t,n){var r,i={},s=null,o=null;n!==void 0&&(s=""+n),t.key!==void 0&&(s=""+t.key),t.ref!==void 0&&(o=t.ref);for(r in t)Nh.call(t,r)&&!Uh.hasOwnProperty(r)&&(i[r]=t[r]);if(e&&e.defaultProps)for(r in t=e.defaultProps,t)i[r]===void 0&&(i[r]=t[r]);return{$$typeof:Ih,type:e,key:s,ref:o,props:i,_owner:Ah.current}}Bi.Fragment=$h;Bi.jsx=Mu;Bi.jsxs=Mu;Ru.exports=Bi;var z=Ru.exports,Ws={},bu={exports:{}},xe={},Bu={exports:{}},Vu={};/** - * @license React - * scheduler.production.min.js - * - * Copyright (c) Facebook, Inc. and its affiliates. - * - * This source code is licensed under the MIT license found in the - * LICENSE file in the root directory of this source tree. - */(function(e){function t(C,R){var j=C.length;C.push(R);e:for(;0<j;){var G=j-1>>>1,ee=C[G];if(0<i(ee,R))C[G]=R,C[j]=ee,j=G;else break e}}function n(C){return C.length===0?null:C[0]}function r(C){if(C.length===0)return null;var R=C[0],j=C.pop();if(j!==R){C[0]=j;e:for(var G=0,ee=C.length,Ur=ee>>>1;G<Ur;){var Rt=2*(G+1)-1,ds=C[Rt],jt=Rt+1,Dr=C[jt];if(0>i(ds,j))jt<ee&&0>i(Dr,ds)?(C[G]=Dr,C[jt]=j,G=jt):(C[G]=ds,C[Rt]=j,G=Rt);else if(jt<ee&&0>i(Dr,j))C[G]=Dr,C[jt]=j,G=jt;else break e}}return R}function i(C,R){var j=C.sortIndex-R.sortIndex;return j!==0?j:C.id-R.id}if(typeof performance=="object"&&typeof performance.now=="function"){var s=performance;e.unstable_now=function(){return s.now()}}else{var o=Date,l=o.now();e.unstable_now=function(){return o.now()-l}}var a=[],u=[],c=1,d=null,f=3,v=!1,g=!1,y=!1,_=typeof setTimeout=="function"?setTimeout:null,p=typeof clearTimeout=="function"?clearTimeout:null,h=typeof setImmediate<"u"?setImmediate:null;typeof navigator<"u"&&navigator.scheduling!==void 0&&navigator.scheduling.isInputPending!==void 0&&navigator.scheduling.isInputPending.bind(navigator.scheduling);function m(C){for(var R=n(u);R!==null;){if(R.callback===null)r(u);else if(R.startTime<=C)r(u),R.sortIndex=R.expirationTime,t(a,R);else break;R=n(u)}}function w(C){if(y=!1,m(C),!g)if(n(a)!==null)g=!0,us(S);else{var R=n(u);R!==null&&cs(w,R.startTime-C)}}function S(C,R){g=!1,y&&(y=!1,p(O),O=-1),v=!0;var j=f;try{for(m(R),d=n(a);d!==null&&(!(d.expirationTime>R)||C&&!Ne());){var G=d.callback;if(typeof G=="function"){d.callback=null,f=d.priorityLevel;var ee=G(d.expirationTime<=R);R=e.unstable_now(),typeof ee=="function"?d.callback=ee:d===n(a)&&r(a),m(R)}else r(a);d=n(a)}if(d!==null)var Ur=!0;else{var Rt=n(u);Rt!==null&&cs(w,Rt.startTime-R),Ur=!1}return Ur}finally{d=null,f=j,v=!1}}var P=!1,T=null,O=-1,Q=5,$=-1;function Ne(){return!(e.unstable_now()-$<Q)}function Dn(){if(T!==null){var C=e.unstable_now();$=C;var R=!0;try{R=T(!0,C)}finally{R?zn():(P=!1,T=null)}}else P=!1}var zn;if(typeof h=="function")zn=function(){h(Dn)};else if(typeof MessageChannel<"u"){var Gl=new MessageChannel,hh=Gl.port2;Gl.port1.onmessage=Dn,zn=function(){hh.postMessage(null)}}else zn=function(){_(Dn,0)};function us(C){T=C,P||(P=!0,zn())}function cs(C,R){O=_(function(){C(e.unstable_now())},R)}e.unstable_IdlePriority=5,e.unstable_ImmediatePriority=1,e.unstable_LowPriority=4,e.unstable_NormalPriority=3,e.unstable_Profiling=null,e.unstable_UserBlockingPriority=2,e.unstable_cancelCallback=function(C){C.callback=null},e.unstable_continueExecution=function(){g||v||(g=!0,us(S))},e.unstable_forceFrameRate=function(C){0>C||125<C?console.error("forceFrameRate takes a positive int between 0 and 125, forcing frame rates higher than 125 fps is not supported"):Q=0<C?Math.floor(1e3/C):5},e.unstable_getCurrentPriorityLevel=function(){return f},e.unstable_getFirstCallbackNode=function(){return n(a)},e.unstable_next=function(C){switch(f){case 1:case 2:case 3:var R=3;break;default:R=f}var j=f;f=R;try{return C()}finally{f=j}},e.unstable_pauseExecution=function(){},e.unstable_requestPaint=function(){},e.unstable_runWithPriority=function(C,R){switch(C){case 1:case 2:case 3:case 4:case 5:break;default:C=3}var j=f;f=C;try{return R()}finally{f=j}},e.unstable_scheduleCallback=function(C,R,j){var G=e.unstable_now();switch(typeof j=="object"&&j!==null?(j=j.delay,j=typeof j=="number"&&0<j?G+j:G):j=G,C){case 1:var ee=-1;break;case 2:ee=250;break;case 5:ee=1073741823;break;case 4:ee=1e4;break;default:ee=5e3}return ee=j+ee,C={id:c++,callback:R,priorityLevel:C,startTime:j,expirationTime:ee,sortIndex:-1},j>G?(C.sortIndex=j,t(u,C),n(a)===null&&C===n(u)&&(y?(p(O),O=-1):y=!0,cs(w,j-G))):(C.sortIndex=ee,t(a,C),g||v||(g=!0,us(S))),C},e.unstable_shouldYield=Ne,e.unstable_wrapCallback=function(C){var R=f;return function(){var j=f;f=R;try{return C.apply(this,arguments)}finally{f=j}}}})(Vu);Bu.exports=Vu;var Dh=Bu.exports;/** - * @license React - * react-dom.production.min.js - * - * Copyright (c) Facebook, Inc. and its affiliates. - * - * This source code is licensed under the MIT license found in the - * LICENSE file in the root directory of this source tree. - */var zh=x,Ce=Dh;function k(e){for(var t="https://reactjs.org/docs/error-decoder.html?invariant="+e,n=1;n<arguments.length;n++)t+="&args[]="+encodeURIComponent(arguments[n]);return"Minified React error #"+e+"; visit "+t+" for the full message or use the non-minified dev environment for full errors and additional helpful warnings."}var Hu=new Set,cr={};function Gt(e,t){Sn(e,t),Sn(e+"Capture",t)}function Sn(e,t){for(cr[e]=t,e=0;e<t.length;e++)Hu.add(t[e])}var et=!(typeof window>"u"||typeof window.document>"u"||typeof window.document.createElement>"u"),Ks=Object.prototype.hasOwnProperty,Fh=/^[: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]*$/,Xl={},Zl={};function Mh(e){return Ks.call(Zl,e)?!0:Ks.call(Xl,e)?!1:Fh.test(e)?Zl[e]=!0:(Xl[e]=!0,!1)}function bh(e,t,n,r){if(n!==null&&n.type===0)return!1;switch(typeof t){case"function":case"symbol":return!0;case"boolean":return r?!1:n!==null?!n.acceptsBooleans:(e=e.toLowerCase().slice(0,5),e!=="data-"&&e!=="aria-");default:return!1}}function Bh(e,t,n,r){if(t===null||typeof t>"u"||bh(e,t,n,r))return!0;if(r)return!1;if(n!==null)switch(n.type){case 3:return!t;case 4:return t===!1;case 5:return isNaN(t);case 6:return isNaN(t)||1>t}return!1}function pe(e,t,n,r,i,s,o){this.acceptsBooleans=t===2||t===3||t===4,this.attributeName=r,this.attributeNamespace=i,this.mustUseProperty=n,this.propertyName=e,this.type=t,this.sanitizeURL=s,this.removeEmptyString=o}var se={};"children dangerouslySetInnerHTML defaultValue defaultChecked innerHTML suppressContentEditableWarning suppressHydrationWarning style".split(" ").forEach(function(e){se[e]=new pe(e,0,!1,e,null,!1,!1)});[["acceptCharset","accept-charset"],["className","class"],["htmlFor","for"],["httpEquiv","http-equiv"]].forEach(function(e){var t=e[0];se[t]=new pe(t,1,!1,e[1],null,!1,!1)});["contentEditable","draggable","spellCheck","value"].forEach(function(e){se[e]=new pe(e,2,!1,e.toLowerCase(),null,!1,!1)});["autoReverse","externalResourcesRequired","focusable","preserveAlpha"].forEach(function(e){se[e]=new pe(e,2,!1,e,null,!1,!1)});"allowFullScreen async autoFocus autoPlay controls default defer disabled disablePictureInPicture disableRemotePlayback formNoValidate hidden loop noModule noValidate open playsInline readOnly required reversed scoped seamless itemScope".split(" ").forEach(function(e){se[e]=new pe(e,3,!1,e.toLowerCase(),null,!1,!1)});["checked","multiple","muted","selected"].forEach(function(e){se[e]=new pe(e,3,!0,e,null,!1,!1)});["capture","download"].forEach(function(e){se[e]=new pe(e,4,!1,e,null,!1,!1)});["cols","rows","size","span"].forEach(function(e){se[e]=new pe(e,6,!1,e,null,!1,!1)});["rowSpan","start"].forEach(function(e){se[e]=new pe(e,5,!1,e.toLowerCase(),null,!1,!1)});var Yo=/[\-:]([a-z])/g;function Xo(e){return e[1].toUpperCase()}"accent-height alignment-baseline arabic-form baseline-shift cap-height clip-path clip-rule color-interpolation color-interpolation-filters color-profile color-rendering dominant-baseline enable-background fill-opacity fill-rule flood-color flood-opacity font-family font-size font-size-adjust font-stretch font-style font-variant font-weight glyph-name glyph-orientation-horizontal glyph-orientation-vertical horiz-adv-x horiz-origin-x image-rendering letter-spacing lighting-color marker-end marker-mid marker-start overline-position overline-thickness paint-order panose-1 pointer-events rendering-intent shape-rendering stop-color stop-opacity strikethrough-position strikethrough-thickness stroke-dasharray stroke-dashoffset stroke-linecap stroke-linejoin stroke-miterlimit stroke-opacity stroke-width text-anchor text-decoration text-rendering underline-position underline-thickness unicode-bidi unicode-range units-per-em v-alphabetic v-hanging v-ideographic v-mathematical vector-effect vert-adv-y vert-origin-x vert-origin-y word-spacing writing-mode xmlns:xlink x-height".split(" ").forEach(function(e){var t=e.replace(Yo,Xo);se[t]=new pe(t,1,!1,e,null,!1,!1)});"xlink:actuate xlink:arcrole xlink:role xlink:show xlink:title xlink:type".split(" ").forEach(function(e){var t=e.replace(Yo,Xo);se[t]=new pe(t,1,!1,e,"http://www.w3.org/1999/xlink",!1,!1)});["xml:base","xml:lang","xml:space"].forEach(function(e){var t=e.replace(Yo,Xo);se[t]=new pe(t,1,!1,e,"http://www.w3.org/XML/1998/namespace",!1,!1)});["tabIndex","crossOrigin"].forEach(function(e){se[e]=new pe(e,1,!1,e.toLowerCase(),null,!1,!1)});se.xlinkHref=new pe("xlinkHref",1,!1,"xlink:href","http://www.w3.org/1999/xlink",!0,!1);["src","href","action","formAction"].forEach(function(e){se[e]=new pe(e,1,!1,e.toLowerCase(),null,!0,!0)});function Zo(e,t,n,r){var i=se.hasOwnProperty(t)?se[t]:null;(i!==null?i.type!==0:r||!(2<t.length)||t[0]!=="o"&&t[0]!=="O"||t[1]!=="n"&&t[1]!=="N")&&(Bh(t,n,i,r)&&(n=null),r||i===null?Mh(t)&&(n===null?e.removeAttribute(t):e.setAttribute(t,""+n)):i.mustUseProperty?e[i.propertyName]=n===null?i.type===3?!1:"":n:(t=i.attributeName,r=i.attributeNamespace,n===null?e.removeAttribute(t):(i=i.type,n=i===3||i===4&&n===!0?"":""+n,r?e.setAttributeNS(r,t,n):e.setAttribute(t,n))))}var it=zh.__SECRET_INTERNALS_DO_NOT_USE_OR_YOU_WILL_BE_FIRED,Fr=Symbol.for("react.element"),nn=Symbol.for("react.portal"),rn=Symbol.for("react.fragment"),el=Symbol.for("react.strict_mode"),Qs=Symbol.for("react.profiler"),Wu=Symbol.for("react.provider"),Ku=Symbol.for("react.context"),tl=Symbol.for("react.forward_ref"),Gs=Symbol.for("react.suspense"),Js=Symbol.for("react.suspense_list"),nl=Symbol.for("react.memo"),lt=Symbol.for("react.lazy"),Qu=Symbol.for("react.offscreen"),ea=Symbol.iterator;function Fn(e){return e===null||typeof e!="object"?null:(e=ea&&e[ea]||e["@@iterator"],typeof e=="function"?e:null)}var W=Object.assign,fs;function Gn(e){if(fs===void 0)try{throw Error()}catch(n){var t=n.stack.trim().match(/\n( *(at )?)/);fs=t&&t[1]||""}return` -`+fs+e}var ps=!1;function ms(e,t){if(!e||ps)return"";ps=!0;var n=Error.prepareStackTrace;Error.prepareStackTrace=void 0;try{if(t)if(t=function(){throw Error()},Object.defineProperty(t.prototype,"props",{set:function(){throw Error()}}),typeof Reflect=="object"&&Reflect.construct){try{Reflect.construct(t,[])}catch(u){var r=u}Reflect.construct(e,[],t)}else{try{t.call()}catch(u){r=u}e.call(t.prototype)}else{try{throw Error()}catch(u){r=u}e()}}catch(u){if(u&&r&&typeof u.stack=="string"){for(var i=u.stack.split(` -`),s=r.stack.split(` -`),o=i.length-1,l=s.length-1;1<=o&&0<=l&&i[o]!==s[l];)l--;for(;1<=o&&0<=l;o--,l--)if(i[o]!==s[l]){if(o!==1||l!==1)do if(o--,l--,0>l||i[o]!==s[l]){var a=` -`+i[o].replace(" at new "," at ");return e.displayName&&a.includes("<anonymous>")&&(a=a.replace("<anonymous>",e.displayName)),a}while(1<=o&&0<=l);break}}}finally{ps=!1,Error.prepareStackTrace=n}return(e=e?e.displayName||e.name:"")?Gn(e):""}function Vh(e){switch(e.tag){case 5:return Gn(e.type);case 16:return Gn("Lazy");case 13:return Gn("Suspense");case 19:return Gn("SuspenseList");case 0:case 2:case 15:return e=ms(e.type,!1),e;case 11:return e=ms(e.type.render,!1),e;case 1:return e=ms(e.type,!0),e;default:return""}}function qs(e){if(e==null)return null;if(typeof e=="function")return e.displayName||e.name||null;if(typeof e=="string")return e;switch(e){case rn:return"Fragment";case nn:return"Portal";case Qs:return"Profiler";case el:return"StrictMode";case Gs:return"Suspense";case Js:return"SuspenseList"}if(typeof e=="object")switch(e.$$typeof){case Ku:return(e.displayName||"Context")+".Consumer";case Wu:return(e._context.displayName||"Context")+".Provider";case tl:var t=e.render;return e=e.displayName,e||(e=t.displayName||t.name||"",e=e!==""?"ForwardRef("+e+")":"ForwardRef"),e;case nl:return t=e.displayName||null,t!==null?t:qs(e.type)||"Memo";case lt:t=e._payload,e=e._init;try{return qs(e(t))}catch{}}return null}function Hh(e){var t=e.type;switch(e.tag){case 24:return"Cache";case 9:return(t.displayName||"Context")+".Consumer";case 10:return(t._context.displayName||"Context")+".Provider";case 18:return"DehydratedFragment";case 11:return e=t.render,e=e.displayName||e.name||"",t.displayName||(e!==""?"ForwardRef("+e+")":"ForwardRef");case 7:return"Fragment";case 5:return t;case 4:return"Portal";case 3:return"Root";case 6:return"Text";case 16:return qs(t);case 8:return t===el?"StrictMode":"Mode";case 22:return"Offscreen";case 12:return"Profiler";case 21:return"Scope";case 13:return"Suspense";case 19:return"SuspenseList";case 25:return"TracingMarker";case 1:case 0:case 17:case 2:case 14:case 15:if(typeof t=="function")return t.displayName||t.name||null;if(typeof t=="string")return t}return null}function Ct(e){switch(typeof e){case"boolean":case"number":case"string":case"undefined":return e;case"object":return e;default:return""}}function Gu(e){var t=e.type;return(e=e.nodeName)&&e.toLowerCase()==="input"&&(t==="checkbox"||t==="radio")}function Wh(e){var t=Gu(e)?"checked":"value",n=Object.getOwnPropertyDescriptor(e.constructor.prototype,t),r=""+e[t];if(!e.hasOwnProperty(t)&&typeof n<"u"&&typeof n.get=="function"&&typeof n.set=="function"){var i=n.get,s=n.set;return Object.defineProperty(e,t,{configurable:!0,get:function(){return i.call(this)},set:function(o){r=""+o,s.call(this,o)}}),Object.defineProperty(e,t,{enumerable:n.enumerable}),{getValue:function(){return r},setValue:function(o){r=""+o},stopTracking:function(){e._valueTracker=null,delete e[t]}}}}function Mr(e){e._valueTracker||(e._valueTracker=Wh(e))}function Ju(e){if(!e)return!1;var t=e._valueTracker;if(!t)return!0;var n=t.getValue(),r="";return e&&(r=Gu(e)?e.checked?"true":"false":e.value),e=r,e!==n?(t.setValue(e),!0):!1}function gi(e){if(e=e||(typeof document<"u"?document:void 0),typeof e>"u")return null;try{return e.activeElement||e.body}catch{return e.body}}function Ys(e,t){var n=t.checked;return W({},t,{defaultChecked:void 0,defaultValue:void 0,value:void 0,checked:n??e._wrapperState.initialChecked})}function ta(e,t){var n=t.defaultValue==null?"":t.defaultValue,r=t.checked!=null?t.checked:t.defaultChecked;n=Ct(t.value!=null?t.value:n),e._wrapperState={initialChecked:r,initialValue:n,controlled:t.type==="checkbox"||t.type==="radio"?t.checked!=null:t.value!=null}}function qu(e,t){t=t.checked,t!=null&&Zo(e,"checked",t,!1)}function Xs(e,t){qu(e,t);var n=Ct(t.value),r=t.type;if(n!=null)r==="number"?(n===0&&e.value===""||e.value!=n)&&(e.value=""+n):e.value!==""+n&&(e.value=""+n);else if(r==="submit"||r==="reset"){e.removeAttribute("value");return}t.hasOwnProperty("value")?Zs(e,t.type,n):t.hasOwnProperty("defaultValue")&&Zs(e,t.type,Ct(t.defaultValue)),t.checked==null&&t.defaultChecked!=null&&(e.defaultChecked=!!t.defaultChecked)}function na(e,t,n){if(t.hasOwnProperty("value")||t.hasOwnProperty("defaultValue")){var r=t.type;if(!(r!=="submit"&&r!=="reset"||t.value!==void 0&&t.value!==null))return;t=""+e._wrapperState.initialValue,n||t===e.value||(e.value=t),e.defaultValue=t}n=e.name,n!==""&&(e.name=""),e.defaultChecked=!!e._wrapperState.initialChecked,n!==""&&(e.name=n)}function Zs(e,t,n){(t!=="number"||gi(e.ownerDocument)!==e)&&(n==null?e.defaultValue=""+e._wrapperState.initialValue:e.defaultValue!==""+n&&(e.defaultValue=""+n))}var Jn=Array.isArray;function mn(e,t,n,r){if(e=e.options,t){t={};for(var i=0;i<n.length;i++)t["$"+n[i]]=!0;for(n=0;n<e.length;n++)i=t.hasOwnProperty("$"+e[n].value),e[n].selected!==i&&(e[n].selected=i),i&&r&&(e[n].defaultSelected=!0)}else{for(n=""+Ct(n),t=null,i=0;i<e.length;i++){if(e[i].value===n){e[i].selected=!0,r&&(e[i].defaultSelected=!0);return}t!==null||e[i].disabled||(t=e[i])}t!==null&&(t.selected=!0)}}function eo(e,t){if(t.dangerouslySetInnerHTML!=null)throw Error(k(91));return W({},t,{value:void 0,defaultValue:void 0,children:""+e._wrapperState.initialValue})}function ra(e,t){var n=t.value;if(n==null){if(n=t.children,t=t.defaultValue,n!=null){if(t!=null)throw Error(k(92));if(Jn(n)){if(1<n.length)throw Error(k(93));n=n[0]}t=n}t==null&&(t=""),n=t}e._wrapperState={initialValue:Ct(n)}}function Yu(e,t){var n=Ct(t.value),r=Ct(t.defaultValue);n!=null&&(n=""+n,n!==e.value&&(e.value=n),t.defaultValue==null&&e.defaultValue!==n&&(e.defaultValue=n)),r!=null&&(e.defaultValue=""+r)}function ia(e){var t=e.textContent;t===e._wrapperState.initialValue&&t!==""&&t!==null&&(e.value=t)}function Xu(e){switch(e){case"svg":return"http://www.w3.org/2000/svg";case"math":return"http://www.w3.org/1998/Math/MathML";default:return"http://www.w3.org/1999/xhtml"}}function to(e,t){return e==null||e==="http://www.w3.org/1999/xhtml"?Xu(t):e==="http://www.w3.org/2000/svg"&&t==="foreignObject"?"http://www.w3.org/1999/xhtml":e}var br,Zu=function(e){return typeof MSApp<"u"&&MSApp.execUnsafeLocalFunction?function(t,n,r,i){MSApp.execUnsafeLocalFunction(function(){return e(t,n,r,i)})}:e}(function(e,t){if(e.namespaceURI!=="http://www.w3.org/2000/svg"||"innerHTML"in e)e.innerHTML=t;else{for(br=br||document.createElement("div"),br.innerHTML="<svg>"+t.valueOf().toString()+"</svg>",t=br.firstChild;e.firstChild;)e.removeChild(e.firstChild);for(;t.firstChild;)e.appendChild(t.firstChild)}});function dr(e,t){if(t){var n=e.firstChild;if(n&&n===e.lastChild&&n.nodeType===3){n.nodeValue=t;return}}e.textContent=t}var Zn={animationIterationCount:!0,aspectRatio:!0,borderImageOutset:!0,borderImageSlice:!0,borderImageWidth:!0,boxFlex:!0,boxFlexGroup:!0,boxOrdinalGroup:!0,columnCount:!0,columns:!0,flex:!0,flexGrow:!0,flexPositive:!0,flexShrink:!0,flexNegative:!0,flexOrder:!0,gridArea:!0,gridRow:!0,gridRowEnd:!0,gridRowSpan:!0,gridRowStart:!0,gridColumn:!0,gridColumnEnd:!0,gridColumnSpan:!0,gridColumnStart:!0,fontWeight:!0,lineClamp:!0,lineHeight:!0,opacity:!0,order:!0,orphans:!0,tabSize:!0,widows:!0,zIndex:!0,zoom:!0,fillOpacity:!0,floodOpacity:!0,stopOpacity:!0,strokeDasharray:!0,strokeDashoffset:!0,strokeMiterlimit:!0,strokeOpacity:!0,strokeWidth:!0},Kh=["Webkit","ms","Moz","O"];Object.keys(Zn).forEach(function(e){Kh.forEach(function(t){t=t+e.charAt(0).toUpperCase()+e.substring(1),Zn[t]=Zn[e]})});function ec(e,t,n){return t==null||typeof t=="boolean"||t===""?"":n||typeof t!="number"||t===0||Zn.hasOwnProperty(e)&&Zn[e]?(""+t).trim():t+"px"}function tc(e,t){e=e.style;for(var n in t)if(t.hasOwnProperty(n)){var r=n.indexOf("--")===0,i=ec(n,t[n],r);n==="float"&&(n="cssFloat"),r?e.setProperty(n,i):e[n]=i}}var Qh=W({menuitem:!0},{area:!0,base:!0,br:!0,col:!0,embed:!0,hr:!0,img:!0,input:!0,keygen:!0,link:!0,meta:!0,param:!0,source:!0,track:!0,wbr:!0});function no(e,t){if(t){if(Qh[e]&&(t.children!=null||t.dangerouslySetInnerHTML!=null))throw Error(k(137,e));if(t.dangerouslySetInnerHTML!=null){if(t.children!=null)throw Error(k(60));if(typeof t.dangerouslySetInnerHTML!="object"||!("__html"in t.dangerouslySetInnerHTML))throw Error(k(61))}if(t.style!=null&&typeof t.style!="object")throw Error(k(62))}}function ro(e,t){if(e.indexOf("-")===-1)return typeof t.is=="string";switch(e){case"annotation-xml":case"color-profile":case"font-face":case"font-face-src":case"font-face-uri":case"font-face-format":case"font-face-name":case"missing-glyph":return!1;default:return!0}}var io=null;function rl(e){return e=e.target||e.srcElement||window,e.correspondingUseElement&&(e=e.correspondingUseElement),e.nodeType===3?e.parentNode:e}var so=null,vn=null,gn=null;function sa(e){if(e=$r(e)){if(typeof so!="function")throw Error(k(280));var t=e.stateNode;t&&(t=Qi(t),so(e.stateNode,e.type,t))}}function nc(e){vn?gn?gn.push(e):gn=[e]:vn=e}function rc(){if(vn){var e=vn,t=gn;if(gn=vn=null,sa(e),t)for(e=0;e<t.length;e++)sa(t[e])}}function ic(e,t){return e(t)}function sc(){}var vs=!1;function oc(e,t,n){if(vs)return e(t,n);vs=!0;try{return ic(e,t,n)}finally{vs=!1,(vn!==null||gn!==null)&&(sc(),rc())}}function hr(e,t){var n=e.stateNode;if(n===null)return null;var r=Qi(n);if(r===null)return null;n=r[t];e:switch(t){case"onClick":case"onClickCapture":case"onDoubleClick":case"onDoubleClickCapture":case"onMouseDown":case"onMouseDownCapture":case"onMouseMove":case"onMouseMoveCapture":case"onMouseUp":case"onMouseUpCapture":case"onMouseEnter":(r=!r.disabled)||(e=e.type,r=!(e==="button"||e==="input"||e==="select"||e==="textarea")),e=!r;break e;default:e=!1}if(e)return null;if(n&&typeof n!="function")throw Error(k(231,t,typeof n));return n}var oo=!1;if(et)try{var Mn={};Object.defineProperty(Mn,"passive",{get:function(){oo=!0}}),window.addEventListener("test",Mn,Mn),window.removeEventListener("test",Mn,Mn)}catch{oo=!1}function Gh(e,t,n,r,i,s,o,l,a){var u=Array.prototype.slice.call(arguments,3);try{t.apply(n,u)}catch(c){this.onError(c)}}var er=!1,yi=null,wi=!1,lo=null,Jh={onError:function(e){er=!0,yi=e}};function qh(e,t,n,r,i,s,o,l,a){er=!1,yi=null,Gh.apply(Jh,arguments)}function Yh(e,t,n,r,i,s,o,l,a){if(qh.apply(this,arguments),er){if(er){var u=yi;er=!1,yi=null}else throw Error(k(198));wi||(wi=!0,lo=u)}}function Jt(e){var t=e,n=e;if(e.alternate)for(;t.return;)t=t.return;else{e=t;do t=e,t.flags&4098&&(n=t.return),e=t.return;while(e)}return t.tag===3?n:null}function lc(e){if(e.tag===13){var t=e.memoizedState;if(t===null&&(e=e.alternate,e!==null&&(t=e.memoizedState)),t!==null)return t.dehydrated}return null}function oa(e){if(Jt(e)!==e)throw Error(k(188))}function Xh(e){var t=e.alternate;if(!t){if(t=Jt(e),t===null)throw Error(k(188));return t!==e?null:e}for(var n=e,r=t;;){var i=n.return;if(i===null)break;var s=i.alternate;if(s===null){if(r=i.return,r!==null){n=r;continue}break}if(i.child===s.child){for(s=i.child;s;){if(s===n)return oa(i),e;if(s===r)return oa(i),t;s=s.sibling}throw Error(k(188))}if(n.return!==r.return)n=i,r=s;else{for(var o=!1,l=i.child;l;){if(l===n){o=!0,n=i,r=s;break}if(l===r){o=!0,r=i,n=s;break}l=l.sibling}if(!o){for(l=s.child;l;){if(l===n){o=!0,n=s,r=i;break}if(l===r){o=!0,r=s,n=i;break}l=l.sibling}if(!o)throw Error(k(189))}}if(n.alternate!==r)throw Error(k(190))}if(n.tag!==3)throw Error(k(188));return n.stateNode.current===n?e:t}function ac(e){return e=Xh(e),e!==null?uc(e):null}function uc(e){if(e.tag===5||e.tag===6)return e;for(e=e.child;e!==null;){var t=uc(e);if(t!==null)return t;e=e.sibling}return null}var cc=Ce.unstable_scheduleCallback,la=Ce.unstable_cancelCallback,Zh=Ce.unstable_shouldYield,ef=Ce.unstable_requestPaint,J=Ce.unstable_now,tf=Ce.unstable_getCurrentPriorityLevel,il=Ce.unstable_ImmediatePriority,dc=Ce.unstable_UserBlockingPriority,_i=Ce.unstable_NormalPriority,nf=Ce.unstable_LowPriority,hc=Ce.unstable_IdlePriority,Vi=null,Qe=null;function rf(e){if(Qe&&typeof Qe.onCommitFiberRoot=="function")try{Qe.onCommitFiberRoot(Vi,e,void 0,(e.current.flags&128)===128)}catch{}}var be=Math.clz32?Math.clz32:lf,sf=Math.log,of=Math.LN2;function lf(e){return e>>>=0,e===0?32:31-(sf(e)/of|0)|0}var Br=64,Vr=4194304;function qn(e){switch(e&-e){case 1:return 1;case 2:return 2;case 4:return 4;case 8:return 8;case 16:return 16;case 32:return 32;case 64:case 128:case 256:case 512:case 1024:case 2048:case 4096:case 8192:case 16384:case 32768:case 65536:case 131072:case 262144:case 524288:case 1048576:case 2097152:return e&4194240;case 4194304:case 8388608:case 16777216:case 33554432:case 67108864:return e&130023424;case 134217728:return 134217728;case 268435456:return 268435456;case 536870912:return 536870912;case 1073741824:return 1073741824;default:return e}}function ki(e,t){var n=e.pendingLanes;if(n===0)return 0;var r=0,i=e.suspendedLanes,s=e.pingedLanes,o=n&268435455;if(o!==0){var l=o&~i;l!==0?r=qn(l):(s&=o,s!==0&&(r=qn(s)))}else o=n&~i,o!==0?r=qn(o):s!==0&&(r=qn(s));if(r===0)return 0;if(t!==0&&t!==r&&!(t&i)&&(i=r&-r,s=t&-t,i>=s||i===16&&(s&4194240)!==0))return t;if(r&4&&(r|=n&16),t=e.entangledLanes,t!==0)for(e=e.entanglements,t&=r;0<t;)n=31-be(t),i=1<<n,r|=e[n],t&=~i;return r}function af(e,t){switch(e){case 1:case 2:case 4:return t+250;case 8:case 16:case 32:case 64:case 128:case 256:case 512:case 1024:case 2048:case 4096:case 8192:case 16384:case 32768:case 65536:case 131072:case 262144:case 524288:case 1048576:case 2097152:return t+5e3;case 4194304:case 8388608:case 16777216:case 33554432:case 67108864:return-1;case 134217728:case 268435456:case 536870912:case 1073741824:return-1;default:return-1}}function uf(e,t){for(var n=e.suspendedLanes,r=e.pingedLanes,i=e.expirationTimes,s=e.pendingLanes;0<s;){var o=31-be(s),l=1<<o,a=i[o];a===-1?(!(l&n)||l&r)&&(i[o]=af(l,t)):a<=t&&(e.expiredLanes|=l),s&=~l}}function ao(e){return e=e.pendingLanes&-1073741825,e!==0?e:e&1073741824?1073741824:0}function fc(){var e=Br;return Br<<=1,!(Br&4194240)&&(Br=64),e}function gs(e){for(var t=[],n=0;31>n;n++)t.push(e);return t}function Lr(e,t,n){e.pendingLanes|=t,t!==536870912&&(e.suspendedLanes=0,e.pingedLanes=0),e=e.eventTimes,t=31-be(t),e[t]=n}function cf(e,t){var n=e.pendingLanes&~t;e.pendingLanes=t,e.suspendedLanes=0,e.pingedLanes=0,e.expiredLanes&=t,e.mutableReadLanes&=t,e.entangledLanes&=t,t=e.entanglements;var r=e.eventTimes;for(e=e.expirationTimes;0<n;){var i=31-be(n),s=1<<i;t[i]=0,r[i]=-1,e[i]=-1,n&=~s}}function sl(e,t){var n=e.entangledLanes|=t;for(e=e.entanglements;n;){var r=31-be(n),i=1<<r;i&t|e[r]&t&&(e[r]|=t),n&=~i}}var U=0;function pc(e){return e&=-e,1<e?4<e?e&268435455?16:536870912:4:1}var mc,ol,vc,gc,yc,uo=!1,Hr=[],vt=null,gt=null,yt=null,fr=new Map,pr=new Map,ct=[],df="mousedown mouseup touchcancel touchend touchstart auxclick dblclick pointercancel pointerdown pointerup dragend dragstart drop compositionend compositionstart keydown keypress keyup input textInput copy cut paste click change contextmenu reset submit".split(" ");function aa(e,t){switch(e){case"focusin":case"focusout":vt=null;break;case"dragenter":case"dragleave":gt=null;break;case"mouseover":case"mouseout":yt=null;break;case"pointerover":case"pointerout":fr.delete(t.pointerId);break;case"gotpointercapture":case"lostpointercapture":pr.delete(t.pointerId)}}function bn(e,t,n,r,i,s){return e===null||e.nativeEvent!==s?(e={blockedOn:t,domEventName:n,eventSystemFlags:r,nativeEvent:s,targetContainers:[i]},t!==null&&(t=$r(t),t!==null&&ol(t)),e):(e.eventSystemFlags|=r,t=e.targetContainers,i!==null&&t.indexOf(i)===-1&&t.push(i),e)}function hf(e,t,n,r,i){switch(t){case"focusin":return vt=bn(vt,e,t,n,r,i),!0;case"dragenter":return gt=bn(gt,e,t,n,r,i),!0;case"mouseover":return yt=bn(yt,e,t,n,r,i),!0;case"pointerover":var s=i.pointerId;return fr.set(s,bn(fr.get(s)||null,e,t,n,r,i)),!0;case"gotpointercapture":return s=i.pointerId,pr.set(s,bn(pr.get(s)||null,e,t,n,r,i)),!0}return!1}function wc(e){var t=Dt(e.target);if(t!==null){var n=Jt(t);if(n!==null){if(t=n.tag,t===13){if(t=lc(n),t!==null){e.blockedOn=t,yc(e.priority,function(){vc(n)});return}}else if(t===3&&n.stateNode.current.memoizedState.isDehydrated){e.blockedOn=n.tag===3?n.stateNode.containerInfo:null;return}}}e.blockedOn=null}function oi(e){if(e.blockedOn!==null)return!1;for(var t=e.targetContainers;0<t.length;){var n=co(e.domEventName,e.eventSystemFlags,t[0],e.nativeEvent);if(n===null){n=e.nativeEvent;var r=new n.constructor(n.type,n);io=r,n.target.dispatchEvent(r),io=null}else return t=$r(n),t!==null&&ol(t),e.blockedOn=n,!1;t.shift()}return!0}function ua(e,t,n){oi(e)&&n.delete(t)}function ff(){uo=!1,vt!==null&&oi(vt)&&(vt=null),gt!==null&&oi(gt)&&(gt=null),yt!==null&&oi(yt)&&(yt=null),fr.forEach(ua),pr.forEach(ua)}function Bn(e,t){e.blockedOn===t&&(e.blockedOn=null,uo||(uo=!0,Ce.unstable_scheduleCallback(Ce.unstable_NormalPriority,ff)))}function mr(e){function t(i){return Bn(i,e)}if(0<Hr.length){Bn(Hr[0],e);for(var n=1;n<Hr.length;n++){var r=Hr[n];r.blockedOn===e&&(r.blockedOn=null)}}for(vt!==null&&Bn(vt,e),gt!==null&&Bn(gt,e),yt!==null&&Bn(yt,e),fr.forEach(t),pr.forEach(t),n=0;n<ct.length;n++)r=ct[n],r.blockedOn===e&&(r.blockedOn=null);for(;0<ct.length&&(n=ct[0],n.blockedOn===null);)wc(n),n.blockedOn===null&&ct.shift()}var yn=it.ReactCurrentBatchConfig,Si=!0;function pf(e,t,n,r){var i=U,s=yn.transition;yn.transition=null;try{U=1,ll(e,t,n,r)}finally{U=i,yn.transition=s}}function mf(e,t,n,r){var i=U,s=yn.transition;yn.transition=null;try{U=4,ll(e,t,n,r)}finally{U=i,yn.transition=s}}function ll(e,t,n,r){if(Si){var i=co(e,t,n,r);if(i===null)Ts(e,t,r,Ei,n),aa(e,r);else if(hf(i,e,t,n,r))r.stopPropagation();else if(aa(e,r),t&4&&-1<df.indexOf(e)){for(;i!==null;){var s=$r(i);if(s!==null&&mc(s),s=co(e,t,n,r),s===null&&Ts(e,t,r,Ei,n),s===i)break;i=s}i!==null&&r.stopPropagation()}else Ts(e,t,r,null,n)}}var Ei=null;function co(e,t,n,r){if(Ei=null,e=rl(r),e=Dt(e),e!==null)if(t=Jt(e),t===null)e=null;else if(n=t.tag,n===13){if(e=lc(t),e!==null)return e;e=null}else if(n===3){if(t.stateNode.current.memoizedState.isDehydrated)return t.tag===3?t.stateNode.containerInfo:null;e=null}else t!==e&&(e=null);return Ei=e,null}function _c(e){switch(e){case"cancel":case"click":case"close":case"contextmenu":case"copy":case"cut":case"auxclick":case"dblclick":case"dragend":case"dragstart":case"drop":case"focusin":case"focusout":case"input":case"invalid":case"keydown":case"keypress":case"keyup":case"mousedown":case"mouseup":case"paste":case"pause":case"play":case"pointercancel":case"pointerdown":case"pointerup":case"ratechange":case"reset":case"resize":case"seeked":case"submit":case"touchcancel":case"touchend":case"touchstart":case"volumechange":case"change":case"selectionchange":case"textInput":case"compositionstart":case"compositionend":case"compositionupdate":case"beforeblur":case"afterblur":case"beforeinput":case"blur":case"fullscreenchange":case"focus":case"hashchange":case"popstate":case"select":case"selectstart":return 1;case"drag":case"dragenter":case"dragexit":case"dragleave":case"dragover":case"mousemove":case"mouseout":case"mouseover":case"pointermove":case"pointerout":case"pointerover":case"scroll":case"toggle":case"touchmove":case"wheel":case"mouseenter":case"mouseleave":case"pointerenter":case"pointerleave":return 4;case"message":switch(tf()){case il:return 1;case dc:return 4;case _i:case nf:return 16;case hc:return 536870912;default:return 16}default:return 16}}var ft=null,al=null,li=null;function kc(){if(li)return li;var e,t=al,n=t.length,r,i="value"in ft?ft.value:ft.textContent,s=i.length;for(e=0;e<n&&t[e]===i[e];e++);var o=n-e;for(r=1;r<=o&&t[n-r]===i[s-r];r++);return li=i.slice(e,1<r?1-r:void 0)}function ai(e){var t=e.keyCode;return"charCode"in e?(e=e.charCode,e===0&&t===13&&(e=13)):e=t,e===10&&(e=13),32<=e||e===13?e:0}function Wr(){return!0}function ca(){return!1}function Pe(e){function t(n,r,i,s,o){this._reactName=n,this._targetInst=i,this.type=r,this.nativeEvent=s,this.target=o,this.currentTarget=null;for(var l in e)e.hasOwnProperty(l)&&(n=e[l],this[l]=n?n(s):s[l]);return this.isDefaultPrevented=(s.defaultPrevented!=null?s.defaultPrevented:s.returnValue===!1)?Wr:ca,this.isPropagationStopped=ca,this}return W(t.prototype,{preventDefault:function(){this.defaultPrevented=!0;var n=this.nativeEvent;n&&(n.preventDefault?n.preventDefault():typeof n.returnValue!="unknown"&&(n.returnValue=!1),this.isDefaultPrevented=Wr)},stopPropagation:function(){var n=this.nativeEvent;n&&(n.stopPropagation?n.stopPropagation():typeof n.cancelBubble!="unknown"&&(n.cancelBubble=!0),this.isPropagationStopped=Wr)},persist:function(){},isPersistent:Wr}),t}var In={eventPhase:0,bubbles:0,cancelable:0,timeStamp:function(e){return e.timeStamp||Date.now()},defaultPrevented:0,isTrusted:0},ul=Pe(In),Ir=W({},In,{view:0,detail:0}),vf=Pe(Ir),ys,ws,Vn,Hi=W({},Ir,{screenX:0,screenY:0,clientX:0,clientY:0,pageX:0,pageY:0,ctrlKey:0,shiftKey:0,altKey:0,metaKey:0,getModifierState:cl,button:0,buttons:0,relatedTarget:function(e){return e.relatedTarget===void 0?e.fromElement===e.srcElement?e.toElement:e.fromElement:e.relatedTarget},movementX:function(e){return"movementX"in e?e.movementX:(e!==Vn&&(Vn&&e.type==="mousemove"?(ys=e.screenX-Vn.screenX,ws=e.screenY-Vn.screenY):ws=ys=0,Vn=e),ys)},movementY:function(e){return"movementY"in e?e.movementY:ws}}),da=Pe(Hi),gf=W({},Hi,{dataTransfer:0}),yf=Pe(gf),wf=W({},Ir,{relatedTarget:0}),_s=Pe(wf),_f=W({},In,{animationName:0,elapsedTime:0,pseudoElement:0}),kf=Pe(_f),Sf=W({},In,{clipboardData:function(e){return"clipboardData"in e?e.clipboardData:window.clipboardData}}),Ef=Pe(Sf),Cf=W({},In,{data:0}),ha=Pe(Cf),xf={Esc:"Escape",Spacebar:" ",Left:"ArrowLeft",Up:"ArrowUp",Right:"ArrowRight",Down:"ArrowDown",Del:"Delete",Win:"OS",Menu:"ContextMenu",Apps:"ContextMenu",Scroll:"ScrollLock",MozPrintableKey:"Unidentified"},Pf={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"},Tf={Alt:"altKey",Control:"ctrlKey",Meta:"metaKey",Shift:"shiftKey"};function Of(e){var t=this.nativeEvent;return t.getModifierState?t.getModifierState(e):(e=Tf[e])?!!t[e]:!1}function cl(){return Of}var Rf=W({},Ir,{key:function(e){if(e.key){var t=xf[e.key]||e.key;if(t!=="Unidentified")return t}return e.type==="keypress"?(e=ai(e),e===13?"Enter":String.fromCharCode(e)):e.type==="keydown"||e.type==="keyup"?Pf[e.keyCode]||"Unidentified":""},code:0,location:0,ctrlKey:0,shiftKey:0,altKey:0,metaKey:0,repeat:0,locale:0,getModifierState:cl,charCode:function(e){return e.type==="keypress"?ai(e):0},keyCode:function(e){return e.type==="keydown"||e.type==="keyup"?e.keyCode:0},which:function(e){return e.type==="keypress"?ai(e):e.type==="keydown"||e.type==="keyup"?e.keyCode:0}}),jf=Pe(Rf),Lf=W({},Hi,{pointerId:0,width:0,height:0,pressure:0,tangentialPressure:0,tiltX:0,tiltY:0,twist:0,pointerType:0,isPrimary:0}),fa=Pe(Lf),If=W({},Ir,{touches:0,targetTouches:0,changedTouches:0,altKey:0,metaKey:0,ctrlKey:0,shiftKey:0,getModifierState:cl}),$f=Pe(If),Nf=W({},In,{propertyName:0,elapsedTime:0,pseudoElement:0}),Af=Pe(Nf),Uf=W({},Hi,{deltaX:function(e){return"deltaX"in e?e.deltaX:"wheelDeltaX"in e?-e.wheelDeltaX:0},deltaY:function(e){return"deltaY"in e?e.deltaY:"wheelDeltaY"in e?-e.wheelDeltaY:"wheelDelta"in e?-e.wheelDelta:0},deltaZ:0,deltaMode:0}),Df=Pe(Uf),zf=[9,13,27,32],dl=et&&"CompositionEvent"in window,tr=null;et&&"documentMode"in document&&(tr=document.documentMode);var Ff=et&&"TextEvent"in window&&!tr,Sc=et&&(!dl||tr&&8<tr&&11>=tr),pa=" ",ma=!1;function Ec(e,t){switch(e){case"keyup":return zf.indexOf(t.keyCode)!==-1;case"keydown":return t.keyCode!==229;case"keypress":case"mousedown":case"focusout":return!0;default:return!1}}function Cc(e){return e=e.detail,typeof e=="object"&&"data"in e?e.data:null}var sn=!1;function Mf(e,t){switch(e){case"compositionend":return Cc(t);case"keypress":return t.which!==32?null:(ma=!0,pa);case"textInput":return e=t.data,e===pa&&ma?null:e;default:return null}}function bf(e,t){if(sn)return e==="compositionend"||!dl&&Ec(e,t)?(e=kc(),li=al=ft=null,sn=!1,e):null;switch(e){case"paste":return null;case"keypress":if(!(t.ctrlKey||t.altKey||t.metaKey)||t.ctrlKey&&t.altKey){if(t.char&&1<t.char.length)return t.char;if(t.which)return String.fromCharCode(t.which)}return null;case"compositionend":return Sc&&t.locale!=="ko"?null:t.data;default:return null}}var Bf={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 va(e){var t=e&&e.nodeName&&e.nodeName.toLowerCase();return t==="input"?!!Bf[e.type]:t==="textarea"}function xc(e,t,n,r){nc(r),t=Ci(t,"onChange"),0<t.length&&(n=new ul("onChange","change",null,n,r),e.push({event:n,listeners:t}))}var nr=null,vr=null;function Vf(e){Uc(e,0)}function Wi(e){var t=an(e);if(Ju(t))return e}function Hf(e,t){if(e==="change")return t}var Pc=!1;if(et){var ks;if(et){var Ss="oninput"in document;if(!Ss){var ga=document.createElement("div");ga.setAttribute("oninput","return;"),Ss=typeof ga.oninput=="function"}ks=Ss}else ks=!1;Pc=ks&&(!document.documentMode||9<document.documentMode)}function ya(){nr&&(nr.detachEvent("onpropertychange",Tc),vr=nr=null)}function Tc(e){if(e.propertyName==="value"&&Wi(vr)){var t=[];xc(t,vr,e,rl(e)),oc(Vf,t)}}function Wf(e,t,n){e==="focusin"?(ya(),nr=t,vr=n,nr.attachEvent("onpropertychange",Tc)):e==="focusout"&&ya()}function Kf(e){if(e==="selectionchange"||e==="keyup"||e==="keydown")return Wi(vr)}function Qf(e,t){if(e==="click")return Wi(t)}function Gf(e,t){if(e==="input"||e==="change")return Wi(t)}function Jf(e,t){return e===t&&(e!==0||1/e===1/t)||e!==e&&t!==t}var Ve=typeof Object.is=="function"?Object.is:Jf;function gr(e,t){if(Ve(e,t))return!0;if(typeof e!="object"||e===null||typeof t!="object"||t===null)return!1;var n=Object.keys(e),r=Object.keys(t);if(n.length!==r.length)return!1;for(r=0;r<n.length;r++){var i=n[r];if(!Ks.call(t,i)||!Ve(e[i],t[i]))return!1}return!0}function wa(e){for(;e&&e.firstChild;)e=e.firstChild;return e}function _a(e,t){var n=wa(e);e=0;for(var r;n;){if(n.nodeType===3){if(r=e+n.textContent.length,e<=t&&r>=t)return{node:n,offset:t-e};e=r}e:{for(;n;){if(n.nextSibling){n=n.nextSibling;break e}n=n.parentNode}n=void 0}n=wa(n)}}function Oc(e,t){return e&&t?e===t?!0:e&&e.nodeType===3?!1:t&&t.nodeType===3?Oc(e,t.parentNode):"contains"in e?e.contains(t):e.compareDocumentPosition?!!(e.compareDocumentPosition(t)&16):!1:!1}function Rc(){for(var e=window,t=gi();t instanceof e.HTMLIFrameElement;){try{var n=typeof t.contentWindow.location.href=="string"}catch{n=!1}if(n)e=t.contentWindow;else break;t=gi(e.document)}return t}function hl(e){var t=e&&e.nodeName&&e.nodeName.toLowerCase();return t&&(t==="input"&&(e.type==="text"||e.type==="search"||e.type==="tel"||e.type==="url"||e.type==="password")||t==="textarea"||e.contentEditable==="true")}function qf(e){var t=Rc(),n=e.focusedElem,r=e.selectionRange;if(t!==n&&n&&n.ownerDocument&&Oc(n.ownerDocument.documentElement,n)){if(r!==null&&hl(n)){if(t=r.start,e=r.end,e===void 0&&(e=t),"selectionStart"in n)n.selectionStart=t,n.selectionEnd=Math.min(e,n.value.length);else if(e=(t=n.ownerDocument||document)&&t.defaultView||window,e.getSelection){e=e.getSelection();var i=n.textContent.length,s=Math.min(r.start,i);r=r.end===void 0?s:Math.min(r.end,i),!e.extend&&s>r&&(i=r,r=s,s=i),i=_a(n,s);var o=_a(n,r);i&&o&&(e.rangeCount!==1||e.anchorNode!==i.node||e.anchorOffset!==i.offset||e.focusNode!==o.node||e.focusOffset!==o.offset)&&(t=t.createRange(),t.setStart(i.node,i.offset),e.removeAllRanges(),s>r?(e.addRange(t),e.extend(o.node,o.offset)):(t.setEnd(o.node,o.offset),e.addRange(t)))}}for(t=[],e=n;e=e.parentNode;)e.nodeType===1&&t.push({element:e,left:e.scrollLeft,top:e.scrollTop});for(typeof n.focus=="function"&&n.focus(),n=0;n<t.length;n++)e=t[n],e.element.scrollLeft=e.left,e.element.scrollTop=e.top}}var Yf=et&&"documentMode"in document&&11>=document.documentMode,on=null,ho=null,rr=null,fo=!1;function ka(e,t,n){var r=n.window===n?n.document:n.nodeType===9?n:n.ownerDocument;fo||on==null||on!==gi(r)||(r=on,"selectionStart"in r&&hl(r)?r={start:r.selectionStart,end:r.selectionEnd}:(r=(r.ownerDocument&&r.ownerDocument.defaultView||window).getSelection(),r={anchorNode:r.anchorNode,anchorOffset:r.anchorOffset,focusNode:r.focusNode,focusOffset:r.focusOffset}),rr&&gr(rr,r)||(rr=r,r=Ci(ho,"onSelect"),0<r.length&&(t=new ul("onSelect","select",null,t,n),e.push({event:t,listeners:r}),t.target=on)))}function Kr(e,t){var n={};return n[e.toLowerCase()]=t.toLowerCase(),n["Webkit"+e]="webkit"+t,n["Moz"+e]="moz"+t,n}var ln={animationend:Kr("Animation","AnimationEnd"),animationiteration:Kr("Animation","AnimationIteration"),animationstart:Kr("Animation","AnimationStart"),transitionend:Kr("Transition","TransitionEnd")},Es={},jc={};et&&(jc=document.createElement("div").style,"AnimationEvent"in window||(delete ln.animationend.animation,delete ln.animationiteration.animation,delete ln.animationstart.animation),"TransitionEvent"in window||delete ln.transitionend.transition);function Ki(e){if(Es[e])return Es[e];if(!ln[e])return e;var t=ln[e],n;for(n in t)if(t.hasOwnProperty(n)&&n in jc)return Es[e]=t[n];return e}var Lc=Ki("animationend"),Ic=Ki("animationiteration"),$c=Ki("animationstart"),Nc=Ki("transitionend"),Ac=new Map,Sa="abort auxClick cancel canPlay canPlayThrough click close contextMenu copy cut drag dragEnd dragEnter dragExit dragLeave dragOver dragStart drop durationChange emptied encrypted ended error gotPointerCapture input invalid keyDown keyPress keyUp load loadedData loadedMetadata loadStart lostPointerCapture mouseDown mouseMove mouseOut mouseOver mouseUp paste pause play playing pointerCancel pointerDown pointerMove pointerOut pointerOver pointerUp progress rateChange reset resize seeked seeking stalled submit suspend timeUpdate touchCancel touchEnd touchStart volumeChange scroll toggle touchMove waiting wheel".split(" ");function Pt(e,t){Ac.set(e,t),Gt(t,[e])}for(var Cs=0;Cs<Sa.length;Cs++){var xs=Sa[Cs],Xf=xs.toLowerCase(),Zf=xs[0].toUpperCase()+xs.slice(1);Pt(Xf,"on"+Zf)}Pt(Lc,"onAnimationEnd");Pt(Ic,"onAnimationIteration");Pt($c,"onAnimationStart");Pt("dblclick","onDoubleClick");Pt("focusin","onFocus");Pt("focusout","onBlur");Pt(Nc,"onTransitionEnd");Sn("onMouseEnter",["mouseout","mouseover"]);Sn("onMouseLeave",["mouseout","mouseover"]);Sn("onPointerEnter",["pointerout","pointerover"]);Sn("onPointerLeave",["pointerout","pointerover"]);Gt("onChange","change click focusin focusout input keydown keyup selectionchange".split(" "));Gt("onSelect","focusout contextmenu dragend focusin keydown keyup mousedown mouseup selectionchange".split(" "));Gt("onBeforeInput",["compositionend","keypress","textInput","paste"]);Gt("onCompositionEnd","compositionend focusout keydown keypress keyup mousedown".split(" "));Gt("onCompositionStart","compositionstart focusout keydown keypress keyup mousedown".split(" "));Gt("onCompositionUpdate","compositionupdate focusout keydown keypress keyup mousedown".split(" "));var Yn="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(" "),ep=new Set("cancel close invalid load scroll toggle".split(" ").concat(Yn));function Ea(e,t,n){var r=e.type||"unknown-event";e.currentTarget=n,Yh(r,t,void 0,e),e.currentTarget=null}function Uc(e,t){t=(t&4)!==0;for(var n=0;n<e.length;n++){var r=e[n],i=r.event;r=r.listeners;e:{var s=void 0;if(t)for(var o=r.length-1;0<=o;o--){var l=r[o],a=l.instance,u=l.currentTarget;if(l=l.listener,a!==s&&i.isPropagationStopped())break e;Ea(i,l,u),s=a}else for(o=0;o<r.length;o++){if(l=r[o],a=l.instance,u=l.currentTarget,l=l.listener,a!==s&&i.isPropagationStopped())break e;Ea(i,l,u),s=a}}}if(wi)throw e=lo,wi=!1,lo=null,e}function M(e,t){var n=t[yo];n===void 0&&(n=t[yo]=new Set);var r=e+"__bubble";n.has(r)||(Dc(t,e,2,!1),n.add(r))}function Ps(e,t,n){var r=0;t&&(r|=4),Dc(n,e,r,t)}var Qr="_reactListening"+Math.random().toString(36).slice(2);function yr(e){if(!e[Qr]){e[Qr]=!0,Hu.forEach(function(n){n!=="selectionchange"&&(ep.has(n)||Ps(n,!1,e),Ps(n,!0,e))});var t=e.nodeType===9?e:e.ownerDocument;t===null||t[Qr]||(t[Qr]=!0,Ps("selectionchange",!1,t))}}function Dc(e,t,n,r){switch(_c(t)){case 1:var i=pf;break;case 4:i=mf;break;default:i=ll}n=i.bind(null,t,n,e),i=void 0,!oo||t!=="touchstart"&&t!=="touchmove"&&t!=="wheel"||(i=!0),r?i!==void 0?e.addEventListener(t,n,{capture:!0,passive:i}):e.addEventListener(t,n,!0):i!==void 0?e.addEventListener(t,n,{passive:i}):e.addEventListener(t,n,!1)}function Ts(e,t,n,r,i){var s=r;if(!(t&1)&&!(t&2)&&r!==null)e:for(;;){if(r===null)return;var o=r.tag;if(o===3||o===4){var l=r.stateNode.containerInfo;if(l===i||l.nodeType===8&&l.parentNode===i)break;if(o===4)for(o=r.return;o!==null;){var a=o.tag;if((a===3||a===4)&&(a=o.stateNode.containerInfo,a===i||a.nodeType===8&&a.parentNode===i))return;o=o.return}for(;l!==null;){if(o=Dt(l),o===null)return;if(a=o.tag,a===5||a===6){r=s=o;continue e}l=l.parentNode}}r=r.return}oc(function(){var u=s,c=rl(n),d=[];e:{var f=Ac.get(e);if(f!==void 0){var v=ul,g=e;switch(e){case"keypress":if(ai(n)===0)break e;case"keydown":case"keyup":v=jf;break;case"focusin":g="focus",v=_s;break;case"focusout":g="blur",v=_s;break;case"beforeblur":case"afterblur":v=_s;break;case"click":if(n.button===2)break e;case"auxclick":case"dblclick":case"mousedown":case"mousemove":case"mouseup":case"mouseout":case"mouseover":case"contextmenu":v=da;break;case"drag":case"dragend":case"dragenter":case"dragexit":case"dragleave":case"dragover":case"dragstart":case"drop":v=yf;break;case"touchcancel":case"touchend":case"touchmove":case"touchstart":v=$f;break;case Lc:case Ic:case $c:v=kf;break;case Nc:v=Af;break;case"scroll":v=vf;break;case"wheel":v=Df;break;case"copy":case"cut":case"paste":v=Ef;break;case"gotpointercapture":case"lostpointercapture":case"pointercancel":case"pointerdown":case"pointermove":case"pointerout":case"pointerover":case"pointerup":v=fa}var y=(t&4)!==0,_=!y&&e==="scroll",p=y?f!==null?f+"Capture":null:f;y=[];for(var h=u,m;h!==null;){m=h;var w=m.stateNode;if(m.tag===5&&w!==null&&(m=w,p!==null&&(w=hr(h,p),w!=null&&y.push(wr(h,w,m)))),_)break;h=h.return}0<y.length&&(f=new v(f,g,null,n,c),d.push({event:f,listeners:y}))}}if(!(t&7)){e:{if(f=e==="mouseover"||e==="pointerover",v=e==="mouseout"||e==="pointerout",f&&n!==io&&(g=n.relatedTarget||n.fromElement)&&(Dt(g)||g[tt]))break e;if((v||f)&&(f=c.window===c?c:(f=c.ownerDocument)?f.defaultView||f.parentWindow:window,v?(g=n.relatedTarget||n.toElement,v=u,g=g?Dt(g):null,g!==null&&(_=Jt(g),g!==_||g.tag!==5&&g.tag!==6)&&(g=null)):(v=null,g=u),v!==g)){if(y=da,w="onMouseLeave",p="onMouseEnter",h="mouse",(e==="pointerout"||e==="pointerover")&&(y=fa,w="onPointerLeave",p="onPointerEnter",h="pointer"),_=v==null?f:an(v),m=g==null?f:an(g),f=new y(w,h+"leave",v,n,c),f.target=_,f.relatedTarget=m,w=null,Dt(c)===u&&(y=new y(p,h+"enter",g,n,c),y.target=m,y.relatedTarget=_,w=y),_=w,v&&g)t:{for(y=v,p=g,h=0,m=y;m;m=Yt(m))h++;for(m=0,w=p;w;w=Yt(w))m++;for(;0<h-m;)y=Yt(y),h--;for(;0<m-h;)p=Yt(p),m--;for(;h--;){if(y===p||p!==null&&y===p.alternate)break t;y=Yt(y),p=Yt(p)}y=null}else y=null;v!==null&&Ca(d,f,v,y,!1),g!==null&&_!==null&&Ca(d,_,g,y,!0)}}e:{if(f=u?an(u):window,v=f.nodeName&&f.nodeName.toLowerCase(),v==="select"||v==="input"&&f.type==="file")var S=Hf;else if(va(f))if(Pc)S=Gf;else{S=Kf;var P=Wf}else(v=f.nodeName)&&v.toLowerCase()==="input"&&(f.type==="checkbox"||f.type==="radio")&&(S=Qf);if(S&&(S=S(e,u))){xc(d,S,n,c);break e}P&&P(e,f,u),e==="focusout"&&(P=f._wrapperState)&&P.controlled&&f.type==="number"&&Zs(f,"number",f.value)}switch(P=u?an(u):window,e){case"focusin":(va(P)||P.contentEditable==="true")&&(on=P,ho=u,rr=null);break;case"focusout":rr=ho=on=null;break;case"mousedown":fo=!0;break;case"contextmenu":case"mouseup":case"dragend":fo=!1,ka(d,n,c);break;case"selectionchange":if(Yf)break;case"keydown":case"keyup":ka(d,n,c)}var T;if(dl)e:{switch(e){case"compositionstart":var O="onCompositionStart";break e;case"compositionend":O="onCompositionEnd";break e;case"compositionupdate":O="onCompositionUpdate";break e}O=void 0}else sn?Ec(e,n)&&(O="onCompositionEnd"):e==="keydown"&&n.keyCode===229&&(O="onCompositionStart");O&&(Sc&&n.locale!=="ko"&&(sn||O!=="onCompositionStart"?O==="onCompositionEnd"&&sn&&(T=kc()):(ft=c,al="value"in ft?ft.value:ft.textContent,sn=!0)),P=Ci(u,O),0<P.length&&(O=new ha(O,e,null,n,c),d.push({event:O,listeners:P}),T?O.data=T:(T=Cc(n),T!==null&&(O.data=T)))),(T=Ff?Mf(e,n):bf(e,n))&&(u=Ci(u,"onBeforeInput"),0<u.length&&(c=new ha("onBeforeInput","beforeinput",null,n,c),d.push({event:c,listeners:u}),c.data=T))}Uc(d,t)})}function wr(e,t,n){return{instance:e,listener:t,currentTarget:n}}function Ci(e,t){for(var n=t+"Capture",r=[];e!==null;){var i=e,s=i.stateNode;i.tag===5&&s!==null&&(i=s,s=hr(e,n),s!=null&&r.unshift(wr(e,s,i)),s=hr(e,t),s!=null&&r.push(wr(e,s,i))),e=e.return}return r}function Yt(e){if(e===null)return null;do e=e.return;while(e&&e.tag!==5);return e||null}function Ca(e,t,n,r,i){for(var s=t._reactName,o=[];n!==null&&n!==r;){var l=n,a=l.alternate,u=l.stateNode;if(a!==null&&a===r)break;l.tag===5&&u!==null&&(l=u,i?(a=hr(n,s),a!=null&&o.unshift(wr(n,a,l))):i||(a=hr(n,s),a!=null&&o.push(wr(n,a,l)))),n=n.return}o.length!==0&&e.push({event:t,listeners:o})}var tp=/\r\n?/g,np=/\u0000|\uFFFD/g;function xa(e){return(typeof e=="string"?e:""+e).replace(tp,` -`).replace(np,"")}function Gr(e,t,n){if(t=xa(t),xa(e)!==t&&n)throw Error(k(425))}function xi(){}var po=null,mo=null;function vo(e,t){return e==="textarea"||e==="noscript"||typeof t.children=="string"||typeof t.children=="number"||typeof t.dangerouslySetInnerHTML=="object"&&t.dangerouslySetInnerHTML!==null&&t.dangerouslySetInnerHTML.__html!=null}var go=typeof setTimeout=="function"?setTimeout:void 0,rp=typeof clearTimeout=="function"?clearTimeout:void 0,Pa=typeof Promise=="function"?Promise:void 0,ip=typeof queueMicrotask=="function"?queueMicrotask:typeof Pa<"u"?function(e){return Pa.resolve(null).then(e).catch(sp)}:go;function sp(e){setTimeout(function(){throw e})}function Os(e,t){var n=t,r=0;do{var i=n.nextSibling;if(e.removeChild(n),i&&i.nodeType===8)if(n=i.data,n==="/$"){if(r===0){e.removeChild(i),mr(t);return}r--}else n!=="$"&&n!=="$?"&&n!=="$!"||r++;n=i}while(n);mr(t)}function wt(e){for(;e!=null;e=e.nextSibling){var t=e.nodeType;if(t===1||t===3)break;if(t===8){if(t=e.data,t==="$"||t==="$!"||t==="$?")break;if(t==="/$")return null}}return e}function Ta(e){e=e.previousSibling;for(var t=0;e;){if(e.nodeType===8){var n=e.data;if(n==="$"||n==="$!"||n==="$?"){if(t===0)return e;t--}else n==="/$"&&t++}e=e.previousSibling}return null}var $n=Math.random().toString(36).slice(2),Ke="__reactFiber$"+$n,_r="__reactProps$"+$n,tt="__reactContainer$"+$n,yo="__reactEvents$"+$n,op="__reactListeners$"+$n,lp="__reactHandles$"+$n;function Dt(e){var t=e[Ke];if(t)return t;for(var n=e.parentNode;n;){if(t=n[tt]||n[Ke]){if(n=t.alternate,t.child!==null||n!==null&&n.child!==null)for(e=Ta(e);e!==null;){if(n=e[Ke])return n;e=Ta(e)}return t}e=n,n=e.parentNode}return null}function $r(e){return e=e[Ke]||e[tt],!e||e.tag!==5&&e.tag!==6&&e.tag!==13&&e.tag!==3?null:e}function an(e){if(e.tag===5||e.tag===6)return e.stateNode;throw Error(k(33))}function Qi(e){return e[_r]||null}var wo=[],un=-1;function Tt(e){return{current:e}}function b(e){0>un||(e.current=wo[un],wo[un]=null,un--)}function F(e,t){un++,wo[un]=e.current,e.current=t}var xt={},ce=Tt(xt),ge=Tt(!1),Vt=xt;function En(e,t){var n=e.type.contextTypes;if(!n)return xt;var r=e.stateNode;if(r&&r.__reactInternalMemoizedUnmaskedChildContext===t)return r.__reactInternalMemoizedMaskedChildContext;var i={},s;for(s in n)i[s]=t[s];return r&&(e=e.stateNode,e.__reactInternalMemoizedUnmaskedChildContext=t,e.__reactInternalMemoizedMaskedChildContext=i),i}function ye(e){return e=e.childContextTypes,e!=null}function Pi(){b(ge),b(ce)}function Oa(e,t,n){if(ce.current!==xt)throw Error(k(168));F(ce,t),F(ge,n)}function zc(e,t,n){var r=e.stateNode;if(t=t.childContextTypes,typeof r.getChildContext!="function")return n;r=r.getChildContext();for(var i in r)if(!(i in t))throw Error(k(108,Hh(e)||"Unknown",i));return W({},n,r)}function Ti(e){return e=(e=e.stateNode)&&e.__reactInternalMemoizedMergedChildContext||xt,Vt=ce.current,F(ce,e),F(ge,ge.current),!0}function Ra(e,t,n){var r=e.stateNode;if(!r)throw Error(k(169));n?(e=zc(e,t,Vt),r.__reactInternalMemoizedMergedChildContext=e,b(ge),b(ce),F(ce,e)):b(ge),F(ge,n)}var qe=null,Gi=!1,Rs=!1;function Fc(e){qe===null?qe=[e]:qe.push(e)}function ap(e){Gi=!0,Fc(e)}function Ot(){if(!Rs&&qe!==null){Rs=!0;var e=0,t=U;try{var n=qe;for(U=1;e<n.length;e++){var r=n[e];do r=r(!0);while(r!==null)}qe=null,Gi=!1}catch(i){throw qe!==null&&(qe=qe.slice(e+1)),cc(il,Ot),i}finally{U=t,Rs=!1}}return null}var cn=[],dn=0,Oi=null,Ri=0,Oe=[],Re=0,Ht=null,Ye=1,Xe="";function $t(e,t){cn[dn++]=Ri,cn[dn++]=Oi,Oi=e,Ri=t}function Mc(e,t,n){Oe[Re++]=Ye,Oe[Re++]=Xe,Oe[Re++]=Ht,Ht=e;var r=Ye;e=Xe;var i=32-be(r)-1;r&=~(1<<i),n+=1;var s=32-be(t)+i;if(30<s){var o=i-i%5;s=(r&(1<<o)-1).toString(32),r>>=o,i-=o,Ye=1<<32-be(t)+i|n<<i|r,Xe=s+e}else Ye=1<<s|n<<i|r,Xe=e}function fl(e){e.return!==null&&($t(e,1),Mc(e,1,0))}function pl(e){for(;e===Oi;)Oi=cn[--dn],cn[dn]=null,Ri=cn[--dn],cn[dn]=null;for(;e===Ht;)Ht=Oe[--Re],Oe[Re]=null,Xe=Oe[--Re],Oe[Re]=null,Ye=Oe[--Re],Oe[Re]=null}var Ee=null,Se=null,B=!1,Me=null;function bc(e,t){var n=je(5,null,null,0);n.elementType="DELETED",n.stateNode=t,n.return=e,t=e.deletions,t===null?(e.deletions=[n],e.flags|=16):t.push(n)}function ja(e,t){switch(e.tag){case 5:var n=e.type;return t=t.nodeType!==1||n.toLowerCase()!==t.nodeName.toLowerCase()?null:t,t!==null?(e.stateNode=t,Ee=e,Se=wt(t.firstChild),!0):!1;case 6:return t=e.pendingProps===""||t.nodeType!==3?null:t,t!==null?(e.stateNode=t,Ee=e,Se=null,!0):!1;case 13:return t=t.nodeType!==8?null:t,t!==null?(n=Ht!==null?{id:Ye,overflow:Xe}:null,e.memoizedState={dehydrated:t,treeContext:n,retryLane:1073741824},n=je(18,null,null,0),n.stateNode=t,n.return=e,e.child=n,Ee=e,Se=null,!0):!1;default:return!1}}function _o(e){return(e.mode&1)!==0&&(e.flags&128)===0}function ko(e){if(B){var t=Se;if(t){var n=t;if(!ja(e,t)){if(_o(e))throw Error(k(418));t=wt(n.nextSibling);var r=Ee;t&&ja(e,t)?bc(r,n):(e.flags=e.flags&-4097|2,B=!1,Ee=e)}}else{if(_o(e))throw Error(k(418));e.flags=e.flags&-4097|2,B=!1,Ee=e}}}function La(e){for(e=e.return;e!==null&&e.tag!==5&&e.tag!==3&&e.tag!==13;)e=e.return;Ee=e}function Jr(e){if(e!==Ee)return!1;if(!B)return La(e),B=!0,!1;var t;if((t=e.tag!==3)&&!(t=e.tag!==5)&&(t=e.type,t=t!=="head"&&t!=="body"&&!vo(e.type,e.memoizedProps)),t&&(t=Se)){if(_o(e))throw Bc(),Error(k(418));for(;t;)bc(e,t),t=wt(t.nextSibling)}if(La(e),e.tag===13){if(e=e.memoizedState,e=e!==null?e.dehydrated:null,!e)throw Error(k(317));e:{for(e=e.nextSibling,t=0;e;){if(e.nodeType===8){var n=e.data;if(n==="/$"){if(t===0){Se=wt(e.nextSibling);break e}t--}else n!=="$"&&n!=="$!"&&n!=="$?"||t++}e=e.nextSibling}Se=null}}else Se=Ee?wt(e.stateNode.nextSibling):null;return!0}function Bc(){for(var e=Se;e;)e=wt(e.nextSibling)}function Cn(){Se=Ee=null,B=!1}function ml(e){Me===null?Me=[e]:Me.push(e)}var up=it.ReactCurrentBatchConfig;function Hn(e,t,n){if(e=n.ref,e!==null&&typeof e!="function"&&typeof e!="object"){if(n._owner){if(n=n._owner,n){if(n.tag!==1)throw Error(k(309));var r=n.stateNode}if(!r)throw Error(k(147,e));var i=r,s=""+e;return t!==null&&t.ref!==null&&typeof t.ref=="function"&&t.ref._stringRef===s?t.ref:(t=function(o){var l=i.refs;o===null?delete l[s]:l[s]=o},t._stringRef=s,t)}if(typeof e!="string")throw Error(k(284));if(!n._owner)throw Error(k(290,e))}return e}function qr(e,t){throw e=Object.prototype.toString.call(t),Error(k(31,e==="[object Object]"?"object with keys {"+Object.keys(t).join(", ")+"}":e))}function Ia(e){var t=e._init;return t(e._payload)}function Vc(e){function t(p,h){if(e){var m=p.deletions;m===null?(p.deletions=[h],p.flags|=16):m.push(h)}}function n(p,h){if(!e)return null;for(;h!==null;)t(p,h),h=h.sibling;return null}function r(p,h){for(p=new Map;h!==null;)h.key!==null?p.set(h.key,h):p.set(h.index,h),h=h.sibling;return p}function i(p,h){return p=Et(p,h),p.index=0,p.sibling=null,p}function s(p,h,m){return p.index=m,e?(m=p.alternate,m!==null?(m=m.index,m<h?(p.flags|=2,h):m):(p.flags|=2,h)):(p.flags|=1048576,h)}function o(p){return e&&p.alternate===null&&(p.flags|=2),p}function l(p,h,m,w){return h===null||h.tag!==6?(h=Us(m,p.mode,w),h.return=p,h):(h=i(h,m),h.return=p,h)}function a(p,h,m,w){var S=m.type;return S===rn?c(p,h,m.props.children,w,m.key):h!==null&&(h.elementType===S||typeof S=="object"&&S!==null&&S.$$typeof===lt&&Ia(S)===h.type)?(w=i(h,m.props),w.ref=Hn(p,h,m),w.return=p,w):(w=mi(m.type,m.key,m.props,null,p.mode,w),w.ref=Hn(p,h,m),w.return=p,w)}function u(p,h,m,w){return h===null||h.tag!==4||h.stateNode.containerInfo!==m.containerInfo||h.stateNode.implementation!==m.implementation?(h=Ds(m,p.mode,w),h.return=p,h):(h=i(h,m.children||[]),h.return=p,h)}function c(p,h,m,w,S){return h===null||h.tag!==7?(h=bt(m,p.mode,w,S),h.return=p,h):(h=i(h,m),h.return=p,h)}function d(p,h,m){if(typeof h=="string"&&h!==""||typeof h=="number")return h=Us(""+h,p.mode,m),h.return=p,h;if(typeof h=="object"&&h!==null){switch(h.$$typeof){case Fr:return m=mi(h.type,h.key,h.props,null,p.mode,m),m.ref=Hn(p,null,h),m.return=p,m;case nn:return h=Ds(h,p.mode,m),h.return=p,h;case lt:var w=h._init;return d(p,w(h._payload),m)}if(Jn(h)||Fn(h))return h=bt(h,p.mode,m,null),h.return=p,h;qr(p,h)}return null}function f(p,h,m,w){var S=h!==null?h.key:null;if(typeof m=="string"&&m!==""||typeof m=="number")return S!==null?null:l(p,h,""+m,w);if(typeof m=="object"&&m!==null){switch(m.$$typeof){case Fr:return m.key===S?a(p,h,m,w):null;case nn:return m.key===S?u(p,h,m,w):null;case lt:return S=m._init,f(p,h,S(m._payload),w)}if(Jn(m)||Fn(m))return S!==null?null:c(p,h,m,w,null);qr(p,m)}return null}function v(p,h,m,w,S){if(typeof w=="string"&&w!==""||typeof w=="number")return p=p.get(m)||null,l(h,p,""+w,S);if(typeof w=="object"&&w!==null){switch(w.$$typeof){case Fr:return p=p.get(w.key===null?m:w.key)||null,a(h,p,w,S);case nn:return p=p.get(w.key===null?m:w.key)||null,u(h,p,w,S);case lt:var P=w._init;return v(p,h,m,P(w._payload),S)}if(Jn(w)||Fn(w))return p=p.get(m)||null,c(h,p,w,S,null);qr(h,w)}return null}function g(p,h,m,w){for(var S=null,P=null,T=h,O=h=0,Q=null;T!==null&&O<m.length;O++){T.index>O?(Q=T,T=null):Q=T.sibling;var $=f(p,T,m[O],w);if($===null){T===null&&(T=Q);break}e&&T&&$.alternate===null&&t(p,T),h=s($,h,O),P===null?S=$:P.sibling=$,P=$,T=Q}if(O===m.length)return n(p,T),B&&$t(p,O),S;if(T===null){for(;O<m.length;O++)T=d(p,m[O],w),T!==null&&(h=s(T,h,O),P===null?S=T:P.sibling=T,P=T);return B&&$t(p,O),S}for(T=r(p,T);O<m.length;O++)Q=v(T,p,O,m[O],w),Q!==null&&(e&&Q.alternate!==null&&T.delete(Q.key===null?O:Q.key),h=s(Q,h,O),P===null?S=Q:P.sibling=Q,P=Q);return e&&T.forEach(function(Ne){return t(p,Ne)}),B&&$t(p,O),S}function y(p,h,m,w){var S=Fn(m);if(typeof S!="function")throw Error(k(150));if(m=S.call(m),m==null)throw Error(k(151));for(var P=S=null,T=h,O=h=0,Q=null,$=m.next();T!==null&&!$.done;O++,$=m.next()){T.index>O?(Q=T,T=null):Q=T.sibling;var Ne=f(p,T,$.value,w);if(Ne===null){T===null&&(T=Q);break}e&&T&&Ne.alternate===null&&t(p,T),h=s(Ne,h,O),P===null?S=Ne:P.sibling=Ne,P=Ne,T=Q}if($.done)return n(p,T),B&&$t(p,O),S;if(T===null){for(;!$.done;O++,$=m.next())$=d(p,$.value,w),$!==null&&(h=s($,h,O),P===null?S=$:P.sibling=$,P=$);return B&&$t(p,O),S}for(T=r(p,T);!$.done;O++,$=m.next())$=v(T,p,O,$.value,w),$!==null&&(e&&$.alternate!==null&&T.delete($.key===null?O:$.key),h=s($,h,O),P===null?S=$:P.sibling=$,P=$);return e&&T.forEach(function(Dn){return t(p,Dn)}),B&&$t(p,O),S}function _(p,h,m,w){if(typeof m=="object"&&m!==null&&m.type===rn&&m.key===null&&(m=m.props.children),typeof m=="object"&&m!==null){switch(m.$$typeof){case Fr:e:{for(var S=m.key,P=h;P!==null;){if(P.key===S){if(S=m.type,S===rn){if(P.tag===7){n(p,P.sibling),h=i(P,m.props.children),h.return=p,p=h;break e}}else if(P.elementType===S||typeof S=="object"&&S!==null&&S.$$typeof===lt&&Ia(S)===P.type){n(p,P.sibling),h=i(P,m.props),h.ref=Hn(p,P,m),h.return=p,p=h;break e}n(p,P);break}else t(p,P);P=P.sibling}m.type===rn?(h=bt(m.props.children,p.mode,w,m.key),h.return=p,p=h):(w=mi(m.type,m.key,m.props,null,p.mode,w),w.ref=Hn(p,h,m),w.return=p,p=w)}return o(p);case nn:e:{for(P=m.key;h!==null;){if(h.key===P)if(h.tag===4&&h.stateNode.containerInfo===m.containerInfo&&h.stateNode.implementation===m.implementation){n(p,h.sibling),h=i(h,m.children||[]),h.return=p,p=h;break e}else{n(p,h);break}else t(p,h);h=h.sibling}h=Ds(m,p.mode,w),h.return=p,p=h}return o(p);case lt:return P=m._init,_(p,h,P(m._payload),w)}if(Jn(m))return g(p,h,m,w);if(Fn(m))return y(p,h,m,w);qr(p,m)}return typeof m=="string"&&m!==""||typeof m=="number"?(m=""+m,h!==null&&h.tag===6?(n(p,h.sibling),h=i(h,m),h.return=p,p=h):(n(p,h),h=Us(m,p.mode,w),h.return=p,p=h),o(p)):n(p,h)}return _}var xn=Vc(!0),Hc=Vc(!1),ji=Tt(null),Li=null,hn=null,vl=null;function gl(){vl=hn=Li=null}function yl(e){var t=ji.current;b(ji),e._currentValue=t}function So(e,t,n){for(;e!==null;){var r=e.alternate;if((e.childLanes&t)!==t?(e.childLanes|=t,r!==null&&(r.childLanes|=t)):r!==null&&(r.childLanes&t)!==t&&(r.childLanes|=t),e===n)break;e=e.return}}function wn(e,t){Li=e,vl=hn=null,e=e.dependencies,e!==null&&e.firstContext!==null&&(e.lanes&t&&(ve=!0),e.firstContext=null)}function Ie(e){var t=e._currentValue;if(vl!==e)if(e={context:e,memoizedValue:t,next:null},hn===null){if(Li===null)throw Error(k(308));hn=e,Li.dependencies={lanes:0,firstContext:e}}else hn=hn.next=e;return t}var zt=null;function wl(e){zt===null?zt=[e]:zt.push(e)}function Wc(e,t,n,r){var i=t.interleaved;return i===null?(n.next=n,wl(t)):(n.next=i.next,i.next=n),t.interleaved=n,nt(e,r)}function nt(e,t){e.lanes|=t;var n=e.alternate;for(n!==null&&(n.lanes|=t),n=e,e=e.return;e!==null;)e.childLanes|=t,n=e.alternate,n!==null&&(n.childLanes|=t),n=e,e=e.return;return n.tag===3?n.stateNode:null}var at=!1;function _l(e){e.updateQueue={baseState:e.memoizedState,firstBaseUpdate:null,lastBaseUpdate:null,shared:{pending:null,interleaved:null,lanes:0},effects:null}}function Kc(e,t){e=e.updateQueue,t.updateQueue===e&&(t.updateQueue={baseState:e.baseState,firstBaseUpdate:e.firstBaseUpdate,lastBaseUpdate:e.lastBaseUpdate,shared:e.shared,effects:e.effects})}function Ze(e,t){return{eventTime:e,lane:t,tag:0,payload:null,callback:null,next:null}}function _t(e,t,n){var r=e.updateQueue;if(r===null)return null;if(r=r.shared,A&2){var i=r.pending;return i===null?t.next=t:(t.next=i.next,i.next=t),r.pending=t,nt(e,n)}return i=r.interleaved,i===null?(t.next=t,wl(r)):(t.next=i.next,i.next=t),r.interleaved=t,nt(e,n)}function ui(e,t,n){if(t=t.updateQueue,t!==null&&(t=t.shared,(n&4194240)!==0)){var r=t.lanes;r&=e.pendingLanes,n|=r,t.lanes=n,sl(e,n)}}function $a(e,t){var n=e.updateQueue,r=e.alternate;if(r!==null&&(r=r.updateQueue,n===r)){var i=null,s=null;if(n=n.firstBaseUpdate,n!==null){do{var o={eventTime:n.eventTime,lane:n.lane,tag:n.tag,payload:n.payload,callback:n.callback,next:null};s===null?i=s=o:s=s.next=o,n=n.next}while(n!==null);s===null?i=s=t:s=s.next=t}else i=s=t;n={baseState:r.baseState,firstBaseUpdate:i,lastBaseUpdate:s,shared:r.shared,effects:r.effects},e.updateQueue=n;return}e=n.lastBaseUpdate,e===null?n.firstBaseUpdate=t:e.next=t,n.lastBaseUpdate=t}function Ii(e,t,n,r){var i=e.updateQueue;at=!1;var s=i.firstBaseUpdate,o=i.lastBaseUpdate,l=i.shared.pending;if(l!==null){i.shared.pending=null;var a=l,u=a.next;a.next=null,o===null?s=u:o.next=u,o=a;var c=e.alternate;c!==null&&(c=c.updateQueue,l=c.lastBaseUpdate,l!==o&&(l===null?c.firstBaseUpdate=u:l.next=u,c.lastBaseUpdate=a))}if(s!==null){var d=i.baseState;o=0,c=u=a=null,l=s;do{var f=l.lane,v=l.eventTime;if((r&f)===f){c!==null&&(c=c.next={eventTime:v,lane:0,tag:l.tag,payload:l.payload,callback:l.callback,next:null});e:{var g=e,y=l;switch(f=t,v=n,y.tag){case 1:if(g=y.payload,typeof g=="function"){d=g.call(v,d,f);break e}d=g;break e;case 3:g.flags=g.flags&-65537|128;case 0:if(g=y.payload,f=typeof g=="function"?g.call(v,d,f):g,f==null)break e;d=W({},d,f);break e;case 2:at=!0}}l.callback!==null&&l.lane!==0&&(e.flags|=64,f=i.effects,f===null?i.effects=[l]:f.push(l))}else v={eventTime:v,lane:f,tag:l.tag,payload:l.payload,callback:l.callback,next:null},c===null?(u=c=v,a=d):c=c.next=v,o|=f;if(l=l.next,l===null){if(l=i.shared.pending,l===null)break;f=l,l=f.next,f.next=null,i.lastBaseUpdate=f,i.shared.pending=null}}while(!0);if(c===null&&(a=d),i.baseState=a,i.firstBaseUpdate=u,i.lastBaseUpdate=c,t=i.shared.interleaved,t!==null){i=t;do o|=i.lane,i=i.next;while(i!==t)}else s===null&&(i.shared.lanes=0);Kt|=o,e.lanes=o,e.memoizedState=d}}function Na(e,t,n){if(e=t.effects,t.effects=null,e!==null)for(t=0;t<e.length;t++){var r=e[t],i=r.callback;if(i!==null){if(r.callback=null,r=n,typeof i!="function")throw Error(k(191,i));i.call(r)}}}var Nr={},Ge=Tt(Nr),kr=Tt(Nr),Sr=Tt(Nr);function Ft(e){if(e===Nr)throw Error(k(174));return e}function kl(e,t){switch(F(Sr,t),F(kr,e),F(Ge,Nr),e=t.nodeType,e){case 9:case 11:t=(t=t.documentElement)?t.namespaceURI:to(null,"");break;default:e=e===8?t.parentNode:t,t=e.namespaceURI||null,e=e.tagName,t=to(t,e)}b(Ge),F(Ge,t)}function Pn(){b(Ge),b(kr),b(Sr)}function Qc(e){Ft(Sr.current);var t=Ft(Ge.current),n=to(t,e.type);t!==n&&(F(kr,e),F(Ge,n))}function Sl(e){kr.current===e&&(b(Ge),b(kr))}var V=Tt(0);function $i(e){for(var t=e;t!==null;){if(t.tag===13){var n=t.memoizedState;if(n!==null&&(n=n.dehydrated,n===null||n.data==="$?"||n.data==="$!"))return t}else if(t.tag===19&&t.memoizedProps.revealOrder!==void 0){if(t.flags&128)return t}else if(t.child!==null){t.child.return=t,t=t.child;continue}if(t===e)break;for(;t.sibling===null;){if(t.return===null||t.return===e)return null;t=t.return}t.sibling.return=t.return,t=t.sibling}return null}var js=[];function El(){for(var e=0;e<js.length;e++)js[e]._workInProgressVersionPrimary=null;js.length=0}var ci=it.ReactCurrentDispatcher,Ls=it.ReactCurrentBatchConfig,Wt=0,H=null,Y=null,te=null,Ni=!1,ir=!1,Er=0,cp=0;function oe(){throw Error(k(321))}function Cl(e,t){if(t===null)return!1;for(var n=0;n<t.length&&n<e.length;n++)if(!Ve(e[n],t[n]))return!1;return!0}function xl(e,t,n,r,i,s){if(Wt=s,H=t,t.memoizedState=null,t.updateQueue=null,t.lanes=0,ci.current=e===null||e.memoizedState===null?pp:mp,e=n(r,i),ir){s=0;do{if(ir=!1,Er=0,25<=s)throw Error(k(301));s+=1,te=Y=null,t.updateQueue=null,ci.current=vp,e=n(r,i)}while(ir)}if(ci.current=Ai,t=Y!==null&&Y.next!==null,Wt=0,te=Y=H=null,Ni=!1,t)throw Error(k(300));return e}function Pl(){var e=Er!==0;return Er=0,e}function We(){var e={memoizedState:null,baseState:null,baseQueue:null,queue:null,next:null};return te===null?H.memoizedState=te=e:te=te.next=e,te}function $e(){if(Y===null){var e=H.alternate;e=e!==null?e.memoizedState:null}else e=Y.next;var t=te===null?H.memoizedState:te.next;if(t!==null)te=t,Y=e;else{if(e===null)throw Error(k(310));Y=e,e={memoizedState:Y.memoizedState,baseState:Y.baseState,baseQueue:Y.baseQueue,queue:Y.queue,next:null},te===null?H.memoizedState=te=e:te=te.next=e}return te}function Cr(e,t){return typeof t=="function"?t(e):t}function Is(e){var t=$e(),n=t.queue;if(n===null)throw Error(k(311));n.lastRenderedReducer=e;var r=Y,i=r.baseQueue,s=n.pending;if(s!==null){if(i!==null){var o=i.next;i.next=s.next,s.next=o}r.baseQueue=i=s,n.pending=null}if(i!==null){s=i.next,r=r.baseState;var l=o=null,a=null,u=s;do{var c=u.lane;if((Wt&c)===c)a!==null&&(a=a.next={lane:0,action:u.action,hasEagerState:u.hasEagerState,eagerState:u.eagerState,next:null}),r=u.hasEagerState?u.eagerState:e(r,u.action);else{var d={lane:c,action:u.action,hasEagerState:u.hasEagerState,eagerState:u.eagerState,next:null};a===null?(l=a=d,o=r):a=a.next=d,H.lanes|=c,Kt|=c}u=u.next}while(u!==null&&u!==s);a===null?o=r:a.next=l,Ve(r,t.memoizedState)||(ve=!0),t.memoizedState=r,t.baseState=o,t.baseQueue=a,n.lastRenderedState=r}if(e=n.interleaved,e!==null){i=e;do s=i.lane,H.lanes|=s,Kt|=s,i=i.next;while(i!==e)}else i===null&&(n.lanes=0);return[t.memoizedState,n.dispatch]}function $s(e){var t=$e(),n=t.queue;if(n===null)throw Error(k(311));n.lastRenderedReducer=e;var r=n.dispatch,i=n.pending,s=t.memoizedState;if(i!==null){n.pending=null;var o=i=i.next;do s=e(s,o.action),o=o.next;while(o!==i);Ve(s,t.memoizedState)||(ve=!0),t.memoizedState=s,t.baseQueue===null&&(t.baseState=s),n.lastRenderedState=s}return[s,r]}function Gc(){}function Jc(e,t){var n=H,r=$e(),i=t(),s=!Ve(r.memoizedState,i);if(s&&(r.memoizedState=i,ve=!0),r=r.queue,Tl(Xc.bind(null,n,r,e),[e]),r.getSnapshot!==t||s||te!==null&&te.memoizedState.tag&1){if(n.flags|=2048,xr(9,Yc.bind(null,n,r,i,t),void 0,null),ne===null)throw Error(k(349));Wt&30||qc(n,t,i)}return i}function qc(e,t,n){e.flags|=16384,e={getSnapshot:t,value:n},t=H.updateQueue,t===null?(t={lastEffect:null,stores:null},H.updateQueue=t,t.stores=[e]):(n=t.stores,n===null?t.stores=[e]:n.push(e))}function Yc(e,t,n,r){t.value=n,t.getSnapshot=r,Zc(t)&&ed(e)}function Xc(e,t,n){return n(function(){Zc(t)&&ed(e)})}function Zc(e){var t=e.getSnapshot;e=e.value;try{var n=t();return!Ve(e,n)}catch{return!0}}function ed(e){var t=nt(e,1);t!==null&&Be(t,e,1,-1)}function Aa(e){var t=We();return typeof e=="function"&&(e=e()),t.memoizedState=t.baseState=e,e={pending:null,interleaved:null,lanes:0,dispatch:null,lastRenderedReducer:Cr,lastRenderedState:e},t.queue=e,e=e.dispatch=fp.bind(null,H,e),[t.memoizedState,e]}function xr(e,t,n,r){return e={tag:e,create:t,destroy:n,deps:r,next:null},t=H.updateQueue,t===null?(t={lastEffect:null,stores:null},H.updateQueue=t,t.lastEffect=e.next=e):(n=t.lastEffect,n===null?t.lastEffect=e.next=e:(r=n.next,n.next=e,e.next=r,t.lastEffect=e)),e}function td(){return $e().memoizedState}function di(e,t,n,r){var i=We();H.flags|=e,i.memoizedState=xr(1|t,n,void 0,r===void 0?null:r)}function Ji(e,t,n,r){var i=$e();r=r===void 0?null:r;var s=void 0;if(Y!==null){var o=Y.memoizedState;if(s=o.destroy,r!==null&&Cl(r,o.deps)){i.memoizedState=xr(t,n,s,r);return}}H.flags|=e,i.memoizedState=xr(1|t,n,s,r)}function Ua(e,t){return di(8390656,8,e,t)}function Tl(e,t){return Ji(2048,8,e,t)}function nd(e,t){return Ji(4,2,e,t)}function rd(e,t){return Ji(4,4,e,t)}function id(e,t){if(typeof t=="function")return e=e(),t(e),function(){t(null)};if(t!=null)return e=e(),t.current=e,function(){t.current=null}}function sd(e,t,n){return n=n!=null?n.concat([e]):null,Ji(4,4,id.bind(null,t,e),n)}function Ol(){}function od(e,t){var n=$e();t=t===void 0?null:t;var r=n.memoizedState;return r!==null&&t!==null&&Cl(t,r[1])?r[0]:(n.memoizedState=[e,t],e)}function ld(e,t){var n=$e();t=t===void 0?null:t;var r=n.memoizedState;return r!==null&&t!==null&&Cl(t,r[1])?r[0]:(e=e(),n.memoizedState=[e,t],e)}function ad(e,t,n){return Wt&21?(Ve(n,t)||(n=fc(),H.lanes|=n,Kt|=n,e.baseState=!0),t):(e.baseState&&(e.baseState=!1,ve=!0),e.memoizedState=n)}function dp(e,t){var n=U;U=n!==0&&4>n?n:4,e(!0);var r=Ls.transition;Ls.transition={};try{e(!1),t()}finally{U=n,Ls.transition=r}}function ud(){return $e().memoizedState}function hp(e,t,n){var r=St(e);if(n={lane:r,action:n,hasEagerState:!1,eagerState:null,next:null},cd(e))dd(t,n);else if(n=Wc(e,t,n,r),n!==null){var i=he();Be(n,e,r,i),hd(n,t,r)}}function fp(e,t,n){var r=St(e),i={lane:r,action:n,hasEagerState:!1,eagerState:null,next:null};if(cd(e))dd(t,i);else{var s=e.alternate;if(e.lanes===0&&(s===null||s.lanes===0)&&(s=t.lastRenderedReducer,s!==null))try{var o=t.lastRenderedState,l=s(o,n);if(i.hasEagerState=!0,i.eagerState=l,Ve(l,o)){var a=t.interleaved;a===null?(i.next=i,wl(t)):(i.next=a.next,a.next=i),t.interleaved=i;return}}catch{}finally{}n=Wc(e,t,i,r),n!==null&&(i=he(),Be(n,e,r,i),hd(n,t,r))}}function cd(e){var t=e.alternate;return e===H||t!==null&&t===H}function dd(e,t){ir=Ni=!0;var n=e.pending;n===null?t.next=t:(t.next=n.next,n.next=t),e.pending=t}function hd(e,t,n){if(n&4194240){var r=t.lanes;r&=e.pendingLanes,n|=r,t.lanes=n,sl(e,n)}}var Ai={readContext:Ie,useCallback:oe,useContext:oe,useEffect:oe,useImperativeHandle:oe,useInsertionEffect:oe,useLayoutEffect:oe,useMemo:oe,useReducer:oe,useRef:oe,useState:oe,useDebugValue:oe,useDeferredValue:oe,useTransition:oe,useMutableSource:oe,useSyncExternalStore:oe,useId:oe,unstable_isNewReconciler:!1},pp={readContext:Ie,useCallback:function(e,t){return We().memoizedState=[e,t===void 0?null:t],e},useContext:Ie,useEffect:Ua,useImperativeHandle:function(e,t,n){return n=n!=null?n.concat([e]):null,di(4194308,4,id.bind(null,t,e),n)},useLayoutEffect:function(e,t){return di(4194308,4,e,t)},useInsertionEffect:function(e,t){return di(4,2,e,t)},useMemo:function(e,t){var n=We();return t=t===void 0?null:t,e=e(),n.memoizedState=[e,t],e},useReducer:function(e,t,n){var r=We();return t=n!==void 0?n(t):t,r.memoizedState=r.baseState=t,e={pending:null,interleaved:null,lanes:0,dispatch:null,lastRenderedReducer:e,lastRenderedState:t},r.queue=e,e=e.dispatch=hp.bind(null,H,e),[r.memoizedState,e]},useRef:function(e){var t=We();return e={current:e},t.memoizedState=e},useState:Aa,useDebugValue:Ol,useDeferredValue:function(e){return We().memoizedState=e},useTransition:function(){var e=Aa(!1),t=e[0];return e=dp.bind(null,e[1]),We().memoizedState=e,[t,e]},useMutableSource:function(){},useSyncExternalStore:function(e,t,n){var r=H,i=We();if(B){if(n===void 0)throw Error(k(407));n=n()}else{if(n=t(),ne===null)throw Error(k(349));Wt&30||qc(r,t,n)}i.memoizedState=n;var s={value:n,getSnapshot:t};return i.queue=s,Ua(Xc.bind(null,r,s,e),[e]),r.flags|=2048,xr(9,Yc.bind(null,r,s,n,t),void 0,null),n},useId:function(){var e=We(),t=ne.identifierPrefix;if(B){var n=Xe,r=Ye;n=(r&~(1<<32-be(r)-1)).toString(32)+n,t=":"+t+"R"+n,n=Er++,0<n&&(t+="H"+n.toString(32)),t+=":"}else n=cp++,t=":"+t+"r"+n.toString(32)+":";return e.memoizedState=t},unstable_isNewReconciler:!1},mp={readContext:Ie,useCallback:od,useContext:Ie,useEffect:Tl,useImperativeHandle:sd,useInsertionEffect:nd,useLayoutEffect:rd,useMemo:ld,useReducer:Is,useRef:td,useState:function(){return Is(Cr)},useDebugValue:Ol,useDeferredValue:function(e){var t=$e();return ad(t,Y.memoizedState,e)},useTransition:function(){var e=Is(Cr)[0],t=$e().memoizedState;return[e,t]},useMutableSource:Gc,useSyncExternalStore:Jc,useId:ud,unstable_isNewReconciler:!1},vp={readContext:Ie,useCallback:od,useContext:Ie,useEffect:Tl,useImperativeHandle:sd,useInsertionEffect:nd,useLayoutEffect:rd,useMemo:ld,useReducer:$s,useRef:td,useState:function(){return $s(Cr)},useDebugValue:Ol,useDeferredValue:function(e){var t=$e();return Y===null?t.memoizedState=e:ad(t,Y.memoizedState,e)},useTransition:function(){var e=$s(Cr)[0],t=$e().memoizedState;return[e,t]},useMutableSource:Gc,useSyncExternalStore:Jc,useId:ud,unstable_isNewReconciler:!1};function De(e,t){if(e&&e.defaultProps){t=W({},t),e=e.defaultProps;for(var n in e)t[n]===void 0&&(t[n]=e[n]);return t}return t}function Eo(e,t,n,r){t=e.memoizedState,n=n(r,t),n=n==null?t:W({},t,n),e.memoizedState=n,e.lanes===0&&(e.updateQueue.baseState=n)}var qi={isMounted:function(e){return(e=e._reactInternals)?Jt(e)===e:!1},enqueueSetState:function(e,t,n){e=e._reactInternals;var r=he(),i=St(e),s=Ze(r,i);s.payload=t,n!=null&&(s.callback=n),t=_t(e,s,i),t!==null&&(Be(t,e,i,r),ui(t,e,i))},enqueueReplaceState:function(e,t,n){e=e._reactInternals;var r=he(),i=St(e),s=Ze(r,i);s.tag=1,s.payload=t,n!=null&&(s.callback=n),t=_t(e,s,i),t!==null&&(Be(t,e,i,r),ui(t,e,i))},enqueueForceUpdate:function(e,t){e=e._reactInternals;var n=he(),r=St(e),i=Ze(n,r);i.tag=2,t!=null&&(i.callback=t),t=_t(e,i,r),t!==null&&(Be(t,e,r,n),ui(t,e,r))}};function Da(e,t,n,r,i,s,o){return e=e.stateNode,typeof e.shouldComponentUpdate=="function"?e.shouldComponentUpdate(r,s,o):t.prototype&&t.prototype.isPureReactComponent?!gr(n,r)||!gr(i,s):!0}function fd(e,t,n){var r=!1,i=xt,s=t.contextType;return typeof s=="object"&&s!==null?s=Ie(s):(i=ye(t)?Vt:ce.current,r=t.contextTypes,s=(r=r!=null)?En(e,i):xt),t=new t(n,s),e.memoizedState=t.state!==null&&t.state!==void 0?t.state:null,t.updater=qi,e.stateNode=t,t._reactInternals=e,r&&(e=e.stateNode,e.__reactInternalMemoizedUnmaskedChildContext=i,e.__reactInternalMemoizedMaskedChildContext=s),t}function za(e,t,n,r){e=t.state,typeof t.componentWillReceiveProps=="function"&&t.componentWillReceiveProps(n,r),typeof t.UNSAFE_componentWillReceiveProps=="function"&&t.UNSAFE_componentWillReceiveProps(n,r),t.state!==e&&qi.enqueueReplaceState(t,t.state,null)}function Co(e,t,n,r){var i=e.stateNode;i.props=n,i.state=e.memoizedState,i.refs={},_l(e);var s=t.contextType;typeof s=="object"&&s!==null?i.context=Ie(s):(s=ye(t)?Vt:ce.current,i.context=En(e,s)),i.state=e.memoizedState,s=t.getDerivedStateFromProps,typeof s=="function"&&(Eo(e,t,s,n),i.state=e.memoizedState),typeof t.getDerivedStateFromProps=="function"||typeof i.getSnapshotBeforeUpdate=="function"||typeof i.UNSAFE_componentWillMount!="function"&&typeof i.componentWillMount!="function"||(t=i.state,typeof i.componentWillMount=="function"&&i.componentWillMount(),typeof i.UNSAFE_componentWillMount=="function"&&i.UNSAFE_componentWillMount(),t!==i.state&&qi.enqueueReplaceState(i,i.state,null),Ii(e,n,i,r),i.state=e.memoizedState),typeof i.componentDidMount=="function"&&(e.flags|=4194308)}function Tn(e,t){try{var n="",r=t;do n+=Vh(r),r=r.return;while(r);var i=n}catch(s){i=` -Error generating stack: `+s.message+` -`+s.stack}return{value:e,source:t,stack:i,digest:null}}function Ns(e,t,n){return{value:e,source:null,stack:n??null,digest:t??null}}function xo(e,t){try{console.error(t.value)}catch(n){setTimeout(function(){throw n})}}var gp=typeof WeakMap=="function"?WeakMap:Map;function pd(e,t,n){n=Ze(-1,n),n.tag=3,n.payload={element:null};var r=t.value;return n.callback=function(){Di||(Di=!0,Ao=r),xo(e,t)},n}function md(e,t,n){n=Ze(-1,n),n.tag=3;var r=e.type.getDerivedStateFromError;if(typeof r=="function"){var i=t.value;n.payload=function(){return r(i)},n.callback=function(){xo(e,t)}}var s=e.stateNode;return s!==null&&typeof s.componentDidCatch=="function"&&(n.callback=function(){xo(e,t),typeof r!="function"&&(kt===null?kt=new Set([this]):kt.add(this));var o=t.stack;this.componentDidCatch(t.value,{componentStack:o!==null?o:""})}),n}function Fa(e,t,n){var r=e.pingCache;if(r===null){r=e.pingCache=new gp;var i=new Set;r.set(t,i)}else i=r.get(t),i===void 0&&(i=new Set,r.set(t,i));i.has(n)||(i.add(n),e=Lp.bind(null,e,t,n),t.then(e,e))}function Ma(e){do{var t;if((t=e.tag===13)&&(t=e.memoizedState,t=t!==null?t.dehydrated!==null:!0),t)return e;e=e.return}while(e!==null);return null}function ba(e,t,n,r,i){return e.mode&1?(e.flags|=65536,e.lanes=i,e):(e===t?e.flags|=65536:(e.flags|=128,n.flags|=131072,n.flags&=-52805,n.tag===1&&(n.alternate===null?n.tag=17:(t=Ze(-1,1),t.tag=2,_t(n,t,1))),n.lanes|=1),e)}var yp=it.ReactCurrentOwner,ve=!1;function de(e,t,n,r){t.child=e===null?Hc(t,null,n,r):xn(t,e.child,n,r)}function Ba(e,t,n,r,i){n=n.render;var s=t.ref;return wn(t,i),r=xl(e,t,n,r,s,i),n=Pl(),e!==null&&!ve?(t.updateQueue=e.updateQueue,t.flags&=-2053,e.lanes&=~i,rt(e,t,i)):(B&&n&&fl(t),t.flags|=1,de(e,t,r,i),t.child)}function Va(e,t,n,r,i){if(e===null){var s=n.type;return typeof s=="function"&&!Ul(s)&&s.defaultProps===void 0&&n.compare===null&&n.defaultProps===void 0?(t.tag=15,t.type=s,vd(e,t,s,r,i)):(e=mi(n.type,null,r,t,t.mode,i),e.ref=t.ref,e.return=t,t.child=e)}if(s=e.child,!(e.lanes&i)){var o=s.memoizedProps;if(n=n.compare,n=n!==null?n:gr,n(o,r)&&e.ref===t.ref)return rt(e,t,i)}return t.flags|=1,e=Et(s,r),e.ref=t.ref,e.return=t,t.child=e}function vd(e,t,n,r,i){if(e!==null){var s=e.memoizedProps;if(gr(s,r)&&e.ref===t.ref)if(ve=!1,t.pendingProps=r=s,(e.lanes&i)!==0)e.flags&131072&&(ve=!0);else return t.lanes=e.lanes,rt(e,t,i)}return Po(e,t,n,r,i)}function gd(e,t,n){var r=t.pendingProps,i=r.children,s=e!==null?e.memoizedState:null;if(r.mode==="hidden")if(!(t.mode&1))t.memoizedState={baseLanes:0,cachePool:null,transitions:null},F(pn,ke),ke|=n;else{if(!(n&1073741824))return e=s!==null?s.baseLanes|n:n,t.lanes=t.childLanes=1073741824,t.memoizedState={baseLanes:e,cachePool:null,transitions:null},t.updateQueue=null,F(pn,ke),ke|=e,null;t.memoizedState={baseLanes:0,cachePool:null,transitions:null},r=s!==null?s.baseLanes:n,F(pn,ke),ke|=r}else s!==null?(r=s.baseLanes|n,t.memoizedState=null):r=n,F(pn,ke),ke|=r;return de(e,t,i,n),t.child}function yd(e,t){var n=t.ref;(e===null&&n!==null||e!==null&&e.ref!==n)&&(t.flags|=512,t.flags|=2097152)}function Po(e,t,n,r,i){var s=ye(n)?Vt:ce.current;return s=En(t,s),wn(t,i),n=xl(e,t,n,r,s,i),r=Pl(),e!==null&&!ve?(t.updateQueue=e.updateQueue,t.flags&=-2053,e.lanes&=~i,rt(e,t,i)):(B&&r&&fl(t),t.flags|=1,de(e,t,n,i),t.child)}function Ha(e,t,n,r,i){if(ye(n)){var s=!0;Ti(t)}else s=!1;if(wn(t,i),t.stateNode===null)hi(e,t),fd(t,n,r),Co(t,n,r,i),r=!0;else if(e===null){var o=t.stateNode,l=t.memoizedProps;o.props=l;var a=o.context,u=n.contextType;typeof u=="object"&&u!==null?u=Ie(u):(u=ye(n)?Vt:ce.current,u=En(t,u));var c=n.getDerivedStateFromProps,d=typeof c=="function"||typeof o.getSnapshotBeforeUpdate=="function";d||typeof o.UNSAFE_componentWillReceiveProps!="function"&&typeof o.componentWillReceiveProps!="function"||(l!==r||a!==u)&&za(t,o,r,u),at=!1;var f=t.memoizedState;o.state=f,Ii(t,r,o,i),a=t.memoizedState,l!==r||f!==a||ge.current||at?(typeof c=="function"&&(Eo(t,n,c,r),a=t.memoizedState),(l=at||Da(t,n,l,r,f,a,u))?(d||typeof o.UNSAFE_componentWillMount!="function"&&typeof o.componentWillMount!="function"||(typeof o.componentWillMount=="function"&&o.componentWillMount(),typeof o.UNSAFE_componentWillMount=="function"&&o.UNSAFE_componentWillMount()),typeof o.componentDidMount=="function"&&(t.flags|=4194308)):(typeof o.componentDidMount=="function"&&(t.flags|=4194308),t.memoizedProps=r,t.memoizedState=a),o.props=r,o.state=a,o.context=u,r=l):(typeof o.componentDidMount=="function"&&(t.flags|=4194308),r=!1)}else{o=t.stateNode,Kc(e,t),l=t.memoizedProps,u=t.type===t.elementType?l:De(t.type,l),o.props=u,d=t.pendingProps,f=o.context,a=n.contextType,typeof a=="object"&&a!==null?a=Ie(a):(a=ye(n)?Vt:ce.current,a=En(t,a));var v=n.getDerivedStateFromProps;(c=typeof v=="function"||typeof o.getSnapshotBeforeUpdate=="function")||typeof o.UNSAFE_componentWillReceiveProps!="function"&&typeof o.componentWillReceiveProps!="function"||(l!==d||f!==a)&&za(t,o,r,a),at=!1,f=t.memoizedState,o.state=f,Ii(t,r,o,i);var g=t.memoizedState;l!==d||f!==g||ge.current||at?(typeof v=="function"&&(Eo(t,n,v,r),g=t.memoizedState),(u=at||Da(t,n,u,r,f,g,a)||!1)?(c||typeof o.UNSAFE_componentWillUpdate!="function"&&typeof o.componentWillUpdate!="function"||(typeof o.componentWillUpdate=="function"&&o.componentWillUpdate(r,g,a),typeof o.UNSAFE_componentWillUpdate=="function"&&o.UNSAFE_componentWillUpdate(r,g,a)),typeof o.componentDidUpdate=="function"&&(t.flags|=4),typeof o.getSnapshotBeforeUpdate=="function"&&(t.flags|=1024)):(typeof o.componentDidUpdate!="function"||l===e.memoizedProps&&f===e.memoizedState||(t.flags|=4),typeof o.getSnapshotBeforeUpdate!="function"||l===e.memoizedProps&&f===e.memoizedState||(t.flags|=1024),t.memoizedProps=r,t.memoizedState=g),o.props=r,o.state=g,o.context=a,r=u):(typeof o.componentDidUpdate!="function"||l===e.memoizedProps&&f===e.memoizedState||(t.flags|=4),typeof o.getSnapshotBeforeUpdate!="function"||l===e.memoizedProps&&f===e.memoizedState||(t.flags|=1024),r=!1)}return To(e,t,n,r,s,i)}function To(e,t,n,r,i,s){yd(e,t);var o=(t.flags&128)!==0;if(!r&&!o)return i&&Ra(t,n,!1),rt(e,t,s);r=t.stateNode,yp.current=t;var l=o&&typeof n.getDerivedStateFromError!="function"?null:r.render();return t.flags|=1,e!==null&&o?(t.child=xn(t,e.child,null,s),t.child=xn(t,null,l,s)):de(e,t,l,s),t.memoizedState=r.state,i&&Ra(t,n,!0),t.child}function wd(e){var t=e.stateNode;t.pendingContext?Oa(e,t.pendingContext,t.pendingContext!==t.context):t.context&&Oa(e,t.context,!1),kl(e,t.containerInfo)}function Wa(e,t,n,r,i){return Cn(),ml(i),t.flags|=256,de(e,t,n,r),t.child}var Oo={dehydrated:null,treeContext:null,retryLane:0};function Ro(e){return{baseLanes:e,cachePool:null,transitions:null}}function _d(e,t,n){var r=t.pendingProps,i=V.current,s=!1,o=(t.flags&128)!==0,l;if((l=o)||(l=e!==null&&e.memoizedState===null?!1:(i&2)!==0),l?(s=!0,t.flags&=-129):(e===null||e.memoizedState!==null)&&(i|=1),F(V,i&1),e===null)return ko(t),e=t.memoizedState,e!==null&&(e=e.dehydrated,e!==null)?(t.mode&1?e.data==="$!"?t.lanes=8:t.lanes=1073741824:t.lanes=1,null):(o=r.children,e=r.fallback,s?(r=t.mode,s=t.child,o={mode:"hidden",children:o},!(r&1)&&s!==null?(s.childLanes=0,s.pendingProps=o):s=Zi(o,r,0,null),e=bt(e,r,n,null),s.return=t,e.return=t,s.sibling=e,t.child=s,t.child.memoizedState=Ro(n),t.memoizedState=Oo,e):Rl(t,o));if(i=e.memoizedState,i!==null&&(l=i.dehydrated,l!==null))return wp(e,t,o,r,l,i,n);if(s){s=r.fallback,o=t.mode,i=e.child,l=i.sibling;var a={mode:"hidden",children:r.children};return!(o&1)&&t.child!==i?(r=t.child,r.childLanes=0,r.pendingProps=a,t.deletions=null):(r=Et(i,a),r.subtreeFlags=i.subtreeFlags&14680064),l!==null?s=Et(l,s):(s=bt(s,o,n,null),s.flags|=2),s.return=t,r.return=t,r.sibling=s,t.child=r,r=s,s=t.child,o=e.child.memoizedState,o=o===null?Ro(n):{baseLanes:o.baseLanes|n,cachePool:null,transitions:o.transitions},s.memoizedState=o,s.childLanes=e.childLanes&~n,t.memoizedState=Oo,r}return s=e.child,e=s.sibling,r=Et(s,{mode:"visible",children:r.children}),!(t.mode&1)&&(r.lanes=n),r.return=t,r.sibling=null,e!==null&&(n=t.deletions,n===null?(t.deletions=[e],t.flags|=16):n.push(e)),t.child=r,t.memoizedState=null,r}function Rl(e,t){return t=Zi({mode:"visible",children:t},e.mode,0,null),t.return=e,e.child=t}function Yr(e,t,n,r){return r!==null&&ml(r),xn(t,e.child,null,n),e=Rl(t,t.pendingProps.children),e.flags|=2,t.memoizedState=null,e}function wp(e,t,n,r,i,s,o){if(n)return t.flags&256?(t.flags&=-257,r=Ns(Error(k(422))),Yr(e,t,o,r)):t.memoizedState!==null?(t.child=e.child,t.flags|=128,null):(s=r.fallback,i=t.mode,r=Zi({mode:"visible",children:r.children},i,0,null),s=bt(s,i,o,null),s.flags|=2,r.return=t,s.return=t,r.sibling=s,t.child=r,t.mode&1&&xn(t,e.child,null,o),t.child.memoizedState=Ro(o),t.memoizedState=Oo,s);if(!(t.mode&1))return Yr(e,t,o,null);if(i.data==="$!"){if(r=i.nextSibling&&i.nextSibling.dataset,r)var l=r.dgst;return r=l,s=Error(k(419)),r=Ns(s,r,void 0),Yr(e,t,o,r)}if(l=(o&e.childLanes)!==0,ve||l){if(r=ne,r!==null){switch(o&-o){case 4:i=2;break;case 16:i=8;break;case 64:case 128:case 256:case 512:case 1024:case 2048:case 4096:case 8192:case 16384:case 32768:case 65536:case 131072:case 262144:case 524288:case 1048576:case 2097152:case 4194304:case 8388608:case 16777216:case 33554432:case 67108864:i=32;break;case 536870912:i=268435456;break;default:i=0}i=i&(r.suspendedLanes|o)?0:i,i!==0&&i!==s.retryLane&&(s.retryLane=i,nt(e,i),Be(r,e,i,-1))}return Al(),r=Ns(Error(k(421))),Yr(e,t,o,r)}return i.data==="$?"?(t.flags|=128,t.child=e.child,t=Ip.bind(null,e),i._reactRetry=t,null):(e=s.treeContext,Se=wt(i.nextSibling),Ee=t,B=!0,Me=null,e!==null&&(Oe[Re++]=Ye,Oe[Re++]=Xe,Oe[Re++]=Ht,Ye=e.id,Xe=e.overflow,Ht=t),t=Rl(t,r.children),t.flags|=4096,t)}function Ka(e,t,n){e.lanes|=t;var r=e.alternate;r!==null&&(r.lanes|=t),So(e.return,t,n)}function As(e,t,n,r,i){var s=e.memoizedState;s===null?e.memoizedState={isBackwards:t,rendering:null,renderingStartTime:0,last:r,tail:n,tailMode:i}:(s.isBackwards=t,s.rendering=null,s.renderingStartTime=0,s.last=r,s.tail=n,s.tailMode=i)}function kd(e,t,n){var r=t.pendingProps,i=r.revealOrder,s=r.tail;if(de(e,t,r.children,n),r=V.current,r&2)r=r&1|2,t.flags|=128;else{if(e!==null&&e.flags&128)e:for(e=t.child;e!==null;){if(e.tag===13)e.memoizedState!==null&&Ka(e,n,t);else if(e.tag===19)Ka(e,n,t);else if(e.child!==null){e.child.return=e,e=e.child;continue}if(e===t)break e;for(;e.sibling===null;){if(e.return===null||e.return===t)break e;e=e.return}e.sibling.return=e.return,e=e.sibling}r&=1}if(F(V,r),!(t.mode&1))t.memoizedState=null;else switch(i){case"forwards":for(n=t.child,i=null;n!==null;)e=n.alternate,e!==null&&$i(e)===null&&(i=n),n=n.sibling;n=i,n===null?(i=t.child,t.child=null):(i=n.sibling,n.sibling=null),As(t,!1,i,n,s);break;case"backwards":for(n=null,i=t.child,t.child=null;i!==null;){if(e=i.alternate,e!==null&&$i(e)===null){t.child=i;break}e=i.sibling,i.sibling=n,n=i,i=e}As(t,!0,n,null,s);break;case"together":As(t,!1,null,null,void 0);break;default:t.memoizedState=null}return t.child}function hi(e,t){!(t.mode&1)&&e!==null&&(e.alternate=null,t.alternate=null,t.flags|=2)}function rt(e,t,n){if(e!==null&&(t.dependencies=e.dependencies),Kt|=t.lanes,!(n&t.childLanes))return null;if(e!==null&&t.child!==e.child)throw Error(k(153));if(t.child!==null){for(e=t.child,n=Et(e,e.pendingProps),t.child=n,n.return=t;e.sibling!==null;)e=e.sibling,n=n.sibling=Et(e,e.pendingProps),n.return=t;n.sibling=null}return t.child}function _p(e,t,n){switch(t.tag){case 3:wd(t),Cn();break;case 5:Qc(t);break;case 1:ye(t.type)&&Ti(t);break;case 4:kl(t,t.stateNode.containerInfo);break;case 10:var r=t.type._context,i=t.memoizedProps.value;F(ji,r._currentValue),r._currentValue=i;break;case 13:if(r=t.memoizedState,r!==null)return r.dehydrated!==null?(F(V,V.current&1),t.flags|=128,null):n&t.child.childLanes?_d(e,t,n):(F(V,V.current&1),e=rt(e,t,n),e!==null?e.sibling:null);F(V,V.current&1);break;case 19:if(r=(n&t.childLanes)!==0,e.flags&128){if(r)return kd(e,t,n);t.flags|=128}if(i=t.memoizedState,i!==null&&(i.rendering=null,i.tail=null,i.lastEffect=null),F(V,V.current),r)break;return null;case 22:case 23:return t.lanes=0,gd(e,t,n)}return rt(e,t,n)}var Sd,jo,Ed,Cd;Sd=function(e,t){for(var n=t.child;n!==null;){if(n.tag===5||n.tag===6)e.appendChild(n.stateNode);else if(n.tag!==4&&n.child!==null){n.child.return=n,n=n.child;continue}if(n===t)break;for(;n.sibling===null;){if(n.return===null||n.return===t)return;n=n.return}n.sibling.return=n.return,n=n.sibling}};jo=function(){};Ed=function(e,t,n,r){var i=e.memoizedProps;if(i!==r){e=t.stateNode,Ft(Ge.current);var s=null;switch(n){case"input":i=Ys(e,i),r=Ys(e,r),s=[];break;case"select":i=W({},i,{value:void 0}),r=W({},r,{value:void 0}),s=[];break;case"textarea":i=eo(e,i),r=eo(e,r),s=[];break;default:typeof i.onClick!="function"&&typeof r.onClick=="function"&&(e.onclick=xi)}no(n,r);var o;n=null;for(u in i)if(!r.hasOwnProperty(u)&&i.hasOwnProperty(u)&&i[u]!=null)if(u==="style"){var l=i[u];for(o in l)l.hasOwnProperty(o)&&(n||(n={}),n[o]="")}else u!=="dangerouslySetInnerHTML"&&u!=="children"&&u!=="suppressContentEditableWarning"&&u!=="suppressHydrationWarning"&&u!=="autoFocus"&&(cr.hasOwnProperty(u)?s||(s=[]):(s=s||[]).push(u,null));for(u in r){var a=r[u];if(l=i!=null?i[u]:void 0,r.hasOwnProperty(u)&&a!==l&&(a!=null||l!=null))if(u==="style")if(l){for(o in l)!l.hasOwnProperty(o)||a&&a.hasOwnProperty(o)||(n||(n={}),n[o]="");for(o in a)a.hasOwnProperty(o)&&l[o]!==a[o]&&(n||(n={}),n[o]=a[o])}else n||(s||(s=[]),s.push(u,n)),n=a;else u==="dangerouslySetInnerHTML"?(a=a?a.__html:void 0,l=l?l.__html:void 0,a!=null&&l!==a&&(s=s||[]).push(u,a)):u==="children"?typeof a!="string"&&typeof a!="number"||(s=s||[]).push(u,""+a):u!=="suppressContentEditableWarning"&&u!=="suppressHydrationWarning"&&(cr.hasOwnProperty(u)?(a!=null&&u==="onScroll"&&M("scroll",e),s||l===a||(s=[])):(s=s||[]).push(u,a))}n&&(s=s||[]).push("style",n);var u=s;(t.updateQueue=u)&&(t.flags|=4)}};Cd=function(e,t,n,r){n!==r&&(t.flags|=4)};function Wn(e,t){if(!B)switch(e.tailMode){case"hidden":t=e.tail;for(var n=null;t!==null;)t.alternate!==null&&(n=t),t=t.sibling;n===null?e.tail=null:n.sibling=null;break;case"collapsed":n=e.tail;for(var r=null;n!==null;)n.alternate!==null&&(r=n),n=n.sibling;r===null?t||e.tail===null?e.tail=null:e.tail.sibling=null:r.sibling=null}}function le(e){var t=e.alternate!==null&&e.alternate.child===e.child,n=0,r=0;if(t)for(var i=e.child;i!==null;)n|=i.lanes|i.childLanes,r|=i.subtreeFlags&14680064,r|=i.flags&14680064,i.return=e,i=i.sibling;else for(i=e.child;i!==null;)n|=i.lanes|i.childLanes,r|=i.subtreeFlags,r|=i.flags,i.return=e,i=i.sibling;return e.subtreeFlags|=r,e.childLanes=n,t}function kp(e,t,n){var r=t.pendingProps;switch(pl(t),t.tag){case 2:case 16:case 15:case 0:case 11:case 7:case 8:case 12:case 9:case 14:return le(t),null;case 1:return ye(t.type)&&Pi(),le(t),null;case 3:return r=t.stateNode,Pn(),b(ge),b(ce),El(),r.pendingContext&&(r.context=r.pendingContext,r.pendingContext=null),(e===null||e.child===null)&&(Jr(t)?t.flags|=4:e===null||e.memoizedState.isDehydrated&&!(t.flags&256)||(t.flags|=1024,Me!==null&&(zo(Me),Me=null))),jo(e,t),le(t),null;case 5:Sl(t);var i=Ft(Sr.current);if(n=t.type,e!==null&&t.stateNode!=null)Ed(e,t,n,r,i),e.ref!==t.ref&&(t.flags|=512,t.flags|=2097152);else{if(!r){if(t.stateNode===null)throw Error(k(166));return le(t),null}if(e=Ft(Ge.current),Jr(t)){r=t.stateNode,n=t.type;var s=t.memoizedProps;switch(r[Ke]=t,r[_r]=s,e=(t.mode&1)!==0,n){case"dialog":M("cancel",r),M("close",r);break;case"iframe":case"object":case"embed":M("load",r);break;case"video":case"audio":for(i=0;i<Yn.length;i++)M(Yn[i],r);break;case"source":M("error",r);break;case"img":case"image":case"link":M("error",r),M("load",r);break;case"details":M("toggle",r);break;case"input":ta(r,s),M("invalid",r);break;case"select":r._wrapperState={wasMultiple:!!s.multiple},M("invalid",r);break;case"textarea":ra(r,s),M("invalid",r)}no(n,s),i=null;for(var o in s)if(s.hasOwnProperty(o)){var l=s[o];o==="children"?typeof l=="string"?r.textContent!==l&&(s.suppressHydrationWarning!==!0&&Gr(r.textContent,l,e),i=["children",l]):typeof l=="number"&&r.textContent!==""+l&&(s.suppressHydrationWarning!==!0&&Gr(r.textContent,l,e),i=["children",""+l]):cr.hasOwnProperty(o)&&l!=null&&o==="onScroll"&&M("scroll",r)}switch(n){case"input":Mr(r),na(r,s,!0);break;case"textarea":Mr(r),ia(r);break;case"select":case"option":break;default:typeof s.onClick=="function"&&(r.onclick=xi)}r=i,t.updateQueue=r,r!==null&&(t.flags|=4)}else{o=i.nodeType===9?i:i.ownerDocument,e==="http://www.w3.org/1999/xhtml"&&(e=Xu(n)),e==="http://www.w3.org/1999/xhtml"?n==="script"?(e=o.createElement("div"),e.innerHTML="<script><\/script>",e=e.removeChild(e.firstChild)):typeof r.is=="string"?e=o.createElement(n,{is:r.is}):(e=o.createElement(n),n==="select"&&(o=e,r.multiple?o.multiple=!0:r.size&&(o.size=r.size))):e=o.createElementNS(e,n),e[Ke]=t,e[_r]=r,Sd(e,t,!1,!1),t.stateNode=e;e:{switch(o=ro(n,r),n){case"dialog":M("cancel",e),M("close",e),i=r;break;case"iframe":case"object":case"embed":M("load",e),i=r;break;case"video":case"audio":for(i=0;i<Yn.length;i++)M(Yn[i],e);i=r;break;case"source":M("error",e),i=r;break;case"img":case"image":case"link":M("error",e),M("load",e),i=r;break;case"details":M("toggle",e),i=r;break;case"input":ta(e,r),i=Ys(e,r),M("invalid",e);break;case"option":i=r;break;case"select":e._wrapperState={wasMultiple:!!r.multiple},i=W({},r,{value:void 0}),M("invalid",e);break;case"textarea":ra(e,r),i=eo(e,r),M("invalid",e);break;default:i=r}no(n,i),l=i;for(s in l)if(l.hasOwnProperty(s)){var a=l[s];s==="style"?tc(e,a):s==="dangerouslySetInnerHTML"?(a=a?a.__html:void 0,a!=null&&Zu(e,a)):s==="children"?typeof a=="string"?(n!=="textarea"||a!=="")&&dr(e,a):typeof a=="number"&&dr(e,""+a):s!=="suppressContentEditableWarning"&&s!=="suppressHydrationWarning"&&s!=="autoFocus"&&(cr.hasOwnProperty(s)?a!=null&&s==="onScroll"&&M("scroll",e):a!=null&&Zo(e,s,a,o))}switch(n){case"input":Mr(e),na(e,r,!1);break;case"textarea":Mr(e),ia(e);break;case"option":r.value!=null&&e.setAttribute("value",""+Ct(r.value));break;case"select":e.multiple=!!r.multiple,s=r.value,s!=null?mn(e,!!r.multiple,s,!1):r.defaultValue!=null&&mn(e,!!r.multiple,r.defaultValue,!0);break;default:typeof i.onClick=="function"&&(e.onclick=xi)}switch(n){case"button":case"input":case"select":case"textarea":r=!!r.autoFocus;break e;case"img":r=!0;break e;default:r=!1}}r&&(t.flags|=4)}t.ref!==null&&(t.flags|=512,t.flags|=2097152)}return le(t),null;case 6:if(e&&t.stateNode!=null)Cd(e,t,e.memoizedProps,r);else{if(typeof r!="string"&&t.stateNode===null)throw Error(k(166));if(n=Ft(Sr.current),Ft(Ge.current),Jr(t)){if(r=t.stateNode,n=t.memoizedProps,r[Ke]=t,(s=r.nodeValue!==n)&&(e=Ee,e!==null))switch(e.tag){case 3:Gr(r.nodeValue,n,(e.mode&1)!==0);break;case 5:e.memoizedProps.suppressHydrationWarning!==!0&&Gr(r.nodeValue,n,(e.mode&1)!==0)}s&&(t.flags|=4)}else r=(n.nodeType===9?n:n.ownerDocument).createTextNode(r),r[Ke]=t,t.stateNode=r}return le(t),null;case 13:if(b(V),r=t.memoizedState,e===null||e.memoizedState!==null&&e.memoizedState.dehydrated!==null){if(B&&Se!==null&&t.mode&1&&!(t.flags&128))Bc(),Cn(),t.flags|=98560,s=!1;else if(s=Jr(t),r!==null&&r.dehydrated!==null){if(e===null){if(!s)throw Error(k(318));if(s=t.memoizedState,s=s!==null?s.dehydrated:null,!s)throw Error(k(317));s[Ke]=t}else Cn(),!(t.flags&128)&&(t.memoizedState=null),t.flags|=4;le(t),s=!1}else Me!==null&&(zo(Me),Me=null),s=!0;if(!s)return t.flags&65536?t:null}return t.flags&128?(t.lanes=n,t):(r=r!==null,r!==(e!==null&&e.memoizedState!==null)&&r&&(t.child.flags|=8192,t.mode&1&&(e===null||V.current&1?X===0&&(X=3):Al())),t.updateQueue!==null&&(t.flags|=4),le(t),null);case 4:return Pn(),jo(e,t),e===null&&yr(t.stateNode.containerInfo),le(t),null;case 10:return yl(t.type._context),le(t),null;case 17:return ye(t.type)&&Pi(),le(t),null;case 19:if(b(V),s=t.memoizedState,s===null)return le(t),null;if(r=(t.flags&128)!==0,o=s.rendering,o===null)if(r)Wn(s,!1);else{if(X!==0||e!==null&&e.flags&128)for(e=t.child;e!==null;){if(o=$i(e),o!==null){for(t.flags|=128,Wn(s,!1),r=o.updateQueue,r!==null&&(t.updateQueue=r,t.flags|=4),t.subtreeFlags=0,r=n,n=t.child;n!==null;)s=n,e=r,s.flags&=14680066,o=s.alternate,o===null?(s.childLanes=0,s.lanes=e,s.child=null,s.subtreeFlags=0,s.memoizedProps=null,s.memoizedState=null,s.updateQueue=null,s.dependencies=null,s.stateNode=null):(s.childLanes=o.childLanes,s.lanes=o.lanes,s.child=o.child,s.subtreeFlags=0,s.deletions=null,s.memoizedProps=o.memoizedProps,s.memoizedState=o.memoizedState,s.updateQueue=o.updateQueue,s.type=o.type,e=o.dependencies,s.dependencies=e===null?null:{lanes:e.lanes,firstContext:e.firstContext}),n=n.sibling;return F(V,V.current&1|2),t.child}e=e.sibling}s.tail!==null&&J()>On&&(t.flags|=128,r=!0,Wn(s,!1),t.lanes=4194304)}else{if(!r)if(e=$i(o),e!==null){if(t.flags|=128,r=!0,n=e.updateQueue,n!==null&&(t.updateQueue=n,t.flags|=4),Wn(s,!0),s.tail===null&&s.tailMode==="hidden"&&!o.alternate&&!B)return le(t),null}else 2*J()-s.renderingStartTime>On&&n!==1073741824&&(t.flags|=128,r=!0,Wn(s,!1),t.lanes=4194304);s.isBackwards?(o.sibling=t.child,t.child=o):(n=s.last,n!==null?n.sibling=o:t.child=o,s.last=o)}return s.tail!==null?(t=s.tail,s.rendering=t,s.tail=t.sibling,s.renderingStartTime=J(),t.sibling=null,n=V.current,F(V,r?n&1|2:n&1),t):(le(t),null);case 22:case 23:return Nl(),r=t.memoizedState!==null,e!==null&&e.memoizedState!==null!==r&&(t.flags|=8192),r&&t.mode&1?ke&1073741824&&(le(t),t.subtreeFlags&6&&(t.flags|=8192)):le(t),null;case 24:return null;case 25:return null}throw Error(k(156,t.tag))}function Sp(e,t){switch(pl(t),t.tag){case 1:return ye(t.type)&&Pi(),e=t.flags,e&65536?(t.flags=e&-65537|128,t):null;case 3:return Pn(),b(ge),b(ce),El(),e=t.flags,e&65536&&!(e&128)?(t.flags=e&-65537|128,t):null;case 5:return Sl(t),null;case 13:if(b(V),e=t.memoizedState,e!==null&&e.dehydrated!==null){if(t.alternate===null)throw Error(k(340));Cn()}return e=t.flags,e&65536?(t.flags=e&-65537|128,t):null;case 19:return b(V),null;case 4:return Pn(),null;case 10:return yl(t.type._context),null;case 22:case 23:return Nl(),null;case 24:return null;default:return null}}var Xr=!1,ue=!1,Ep=typeof WeakSet=="function"?WeakSet:Set,E=null;function fn(e,t){var n=e.ref;if(n!==null)if(typeof n=="function")try{n(null)}catch(r){K(e,t,r)}else n.current=null}function Lo(e,t,n){try{n()}catch(r){K(e,t,r)}}var Qa=!1;function Cp(e,t){if(po=Si,e=Rc(),hl(e)){if("selectionStart"in e)var n={start:e.selectionStart,end:e.selectionEnd};else e:{n=(n=e.ownerDocument)&&n.defaultView||window;var r=n.getSelection&&n.getSelection();if(r&&r.rangeCount!==0){n=r.anchorNode;var i=r.anchorOffset,s=r.focusNode;r=r.focusOffset;try{n.nodeType,s.nodeType}catch{n=null;break e}var o=0,l=-1,a=-1,u=0,c=0,d=e,f=null;t:for(;;){for(var v;d!==n||i!==0&&d.nodeType!==3||(l=o+i),d!==s||r!==0&&d.nodeType!==3||(a=o+r),d.nodeType===3&&(o+=d.nodeValue.length),(v=d.firstChild)!==null;)f=d,d=v;for(;;){if(d===e)break t;if(f===n&&++u===i&&(l=o),f===s&&++c===r&&(a=o),(v=d.nextSibling)!==null)break;d=f,f=d.parentNode}d=v}n=l===-1||a===-1?null:{start:l,end:a}}else n=null}n=n||{start:0,end:0}}else n=null;for(mo={focusedElem:e,selectionRange:n},Si=!1,E=t;E!==null;)if(t=E,e=t.child,(t.subtreeFlags&1028)!==0&&e!==null)e.return=t,E=e;else for(;E!==null;){t=E;try{var g=t.alternate;if(t.flags&1024)switch(t.tag){case 0:case 11:case 15:break;case 1:if(g!==null){var y=g.memoizedProps,_=g.memoizedState,p=t.stateNode,h=p.getSnapshotBeforeUpdate(t.elementType===t.type?y:De(t.type,y),_);p.__reactInternalSnapshotBeforeUpdate=h}break;case 3:var m=t.stateNode.containerInfo;m.nodeType===1?m.textContent="":m.nodeType===9&&m.documentElement&&m.removeChild(m.documentElement);break;case 5:case 6:case 4:case 17:break;default:throw Error(k(163))}}catch(w){K(t,t.return,w)}if(e=t.sibling,e!==null){e.return=t.return,E=e;break}E=t.return}return g=Qa,Qa=!1,g}function sr(e,t,n){var r=t.updateQueue;if(r=r!==null?r.lastEffect:null,r!==null){var i=r=r.next;do{if((i.tag&e)===e){var s=i.destroy;i.destroy=void 0,s!==void 0&&Lo(t,n,s)}i=i.next}while(i!==r)}}function Yi(e,t){if(t=t.updateQueue,t=t!==null?t.lastEffect:null,t!==null){var n=t=t.next;do{if((n.tag&e)===e){var r=n.create;n.destroy=r()}n=n.next}while(n!==t)}}function Io(e){var t=e.ref;if(t!==null){var n=e.stateNode;switch(e.tag){case 5:e=n;break;default:e=n}typeof t=="function"?t(e):t.current=e}}function xd(e){var t=e.alternate;t!==null&&(e.alternate=null,xd(t)),e.child=null,e.deletions=null,e.sibling=null,e.tag===5&&(t=e.stateNode,t!==null&&(delete t[Ke],delete t[_r],delete t[yo],delete t[op],delete t[lp])),e.stateNode=null,e.return=null,e.dependencies=null,e.memoizedProps=null,e.memoizedState=null,e.pendingProps=null,e.stateNode=null,e.updateQueue=null}function Pd(e){return e.tag===5||e.tag===3||e.tag===4}function Ga(e){e:for(;;){for(;e.sibling===null;){if(e.return===null||Pd(e.return))return null;e=e.return}for(e.sibling.return=e.return,e=e.sibling;e.tag!==5&&e.tag!==6&&e.tag!==18;){if(e.flags&2||e.child===null||e.tag===4)continue e;e.child.return=e,e=e.child}if(!(e.flags&2))return e.stateNode}}function $o(e,t,n){var r=e.tag;if(r===5||r===6)e=e.stateNode,t?n.nodeType===8?n.parentNode.insertBefore(e,t):n.insertBefore(e,t):(n.nodeType===8?(t=n.parentNode,t.insertBefore(e,n)):(t=n,t.appendChild(e)),n=n._reactRootContainer,n!=null||t.onclick!==null||(t.onclick=xi));else if(r!==4&&(e=e.child,e!==null))for($o(e,t,n),e=e.sibling;e!==null;)$o(e,t,n),e=e.sibling}function No(e,t,n){var r=e.tag;if(r===5||r===6)e=e.stateNode,t?n.insertBefore(e,t):n.appendChild(e);else if(r!==4&&(e=e.child,e!==null))for(No(e,t,n),e=e.sibling;e!==null;)No(e,t,n),e=e.sibling}var re=null,ze=!1;function st(e,t,n){for(n=n.child;n!==null;)Td(e,t,n),n=n.sibling}function Td(e,t,n){if(Qe&&typeof Qe.onCommitFiberUnmount=="function")try{Qe.onCommitFiberUnmount(Vi,n)}catch{}switch(n.tag){case 5:ue||fn(n,t);case 6:var r=re,i=ze;re=null,st(e,t,n),re=r,ze=i,re!==null&&(ze?(e=re,n=n.stateNode,e.nodeType===8?e.parentNode.removeChild(n):e.removeChild(n)):re.removeChild(n.stateNode));break;case 18:re!==null&&(ze?(e=re,n=n.stateNode,e.nodeType===8?Os(e.parentNode,n):e.nodeType===1&&Os(e,n),mr(e)):Os(re,n.stateNode));break;case 4:r=re,i=ze,re=n.stateNode.containerInfo,ze=!0,st(e,t,n),re=r,ze=i;break;case 0:case 11:case 14:case 15:if(!ue&&(r=n.updateQueue,r!==null&&(r=r.lastEffect,r!==null))){i=r=r.next;do{var s=i,o=s.destroy;s=s.tag,o!==void 0&&(s&2||s&4)&&Lo(n,t,o),i=i.next}while(i!==r)}st(e,t,n);break;case 1:if(!ue&&(fn(n,t),r=n.stateNode,typeof r.componentWillUnmount=="function"))try{r.props=n.memoizedProps,r.state=n.memoizedState,r.componentWillUnmount()}catch(l){K(n,t,l)}st(e,t,n);break;case 21:st(e,t,n);break;case 22:n.mode&1?(ue=(r=ue)||n.memoizedState!==null,st(e,t,n),ue=r):st(e,t,n);break;default:st(e,t,n)}}function Ja(e){var t=e.updateQueue;if(t!==null){e.updateQueue=null;var n=e.stateNode;n===null&&(n=e.stateNode=new Ep),t.forEach(function(r){var i=$p.bind(null,e,r);n.has(r)||(n.add(r),r.then(i,i))})}}function Ae(e,t){var n=t.deletions;if(n!==null)for(var r=0;r<n.length;r++){var i=n[r];try{var s=e,o=t,l=o;e:for(;l!==null;){switch(l.tag){case 5:re=l.stateNode,ze=!1;break e;case 3:re=l.stateNode.containerInfo,ze=!0;break e;case 4:re=l.stateNode.containerInfo,ze=!0;break e}l=l.return}if(re===null)throw Error(k(160));Td(s,o,i),re=null,ze=!1;var a=i.alternate;a!==null&&(a.return=null),i.return=null}catch(u){K(i,t,u)}}if(t.subtreeFlags&12854)for(t=t.child;t!==null;)Od(t,e),t=t.sibling}function Od(e,t){var n=e.alternate,r=e.flags;switch(e.tag){case 0:case 11:case 14:case 15:if(Ae(t,e),He(e),r&4){try{sr(3,e,e.return),Yi(3,e)}catch(y){K(e,e.return,y)}try{sr(5,e,e.return)}catch(y){K(e,e.return,y)}}break;case 1:Ae(t,e),He(e),r&512&&n!==null&&fn(n,n.return);break;case 5:if(Ae(t,e),He(e),r&512&&n!==null&&fn(n,n.return),e.flags&32){var i=e.stateNode;try{dr(i,"")}catch(y){K(e,e.return,y)}}if(r&4&&(i=e.stateNode,i!=null)){var s=e.memoizedProps,o=n!==null?n.memoizedProps:s,l=e.type,a=e.updateQueue;if(e.updateQueue=null,a!==null)try{l==="input"&&s.type==="radio"&&s.name!=null&&qu(i,s),ro(l,o);var u=ro(l,s);for(o=0;o<a.length;o+=2){var c=a[o],d=a[o+1];c==="style"?tc(i,d):c==="dangerouslySetInnerHTML"?Zu(i,d):c==="children"?dr(i,d):Zo(i,c,d,u)}switch(l){case"input":Xs(i,s);break;case"textarea":Yu(i,s);break;case"select":var f=i._wrapperState.wasMultiple;i._wrapperState.wasMultiple=!!s.multiple;var v=s.value;v!=null?mn(i,!!s.multiple,v,!1):f!==!!s.multiple&&(s.defaultValue!=null?mn(i,!!s.multiple,s.defaultValue,!0):mn(i,!!s.multiple,s.multiple?[]:"",!1))}i[_r]=s}catch(y){K(e,e.return,y)}}break;case 6:if(Ae(t,e),He(e),r&4){if(e.stateNode===null)throw Error(k(162));i=e.stateNode,s=e.memoizedProps;try{i.nodeValue=s}catch(y){K(e,e.return,y)}}break;case 3:if(Ae(t,e),He(e),r&4&&n!==null&&n.memoizedState.isDehydrated)try{mr(t.containerInfo)}catch(y){K(e,e.return,y)}break;case 4:Ae(t,e),He(e);break;case 13:Ae(t,e),He(e),i=e.child,i.flags&8192&&(s=i.memoizedState!==null,i.stateNode.isHidden=s,!s||i.alternate!==null&&i.alternate.memoizedState!==null||(Il=J())),r&4&&Ja(e);break;case 22:if(c=n!==null&&n.memoizedState!==null,e.mode&1?(ue=(u=ue)||c,Ae(t,e),ue=u):Ae(t,e),He(e),r&8192){if(u=e.memoizedState!==null,(e.stateNode.isHidden=u)&&!c&&e.mode&1)for(E=e,c=e.child;c!==null;){for(d=E=c;E!==null;){switch(f=E,v=f.child,f.tag){case 0:case 11:case 14:case 15:sr(4,f,f.return);break;case 1:fn(f,f.return);var g=f.stateNode;if(typeof g.componentWillUnmount=="function"){r=f,n=f.return;try{t=r,g.props=t.memoizedProps,g.state=t.memoizedState,g.componentWillUnmount()}catch(y){K(r,n,y)}}break;case 5:fn(f,f.return);break;case 22:if(f.memoizedState!==null){Ya(d);continue}}v!==null?(v.return=f,E=v):Ya(d)}c=c.sibling}e:for(c=null,d=e;;){if(d.tag===5){if(c===null){c=d;try{i=d.stateNode,u?(s=i.style,typeof s.setProperty=="function"?s.setProperty("display","none","important"):s.display="none"):(l=d.stateNode,a=d.memoizedProps.style,o=a!=null&&a.hasOwnProperty("display")?a.display:null,l.style.display=ec("display",o))}catch(y){K(e,e.return,y)}}}else if(d.tag===6){if(c===null)try{d.stateNode.nodeValue=u?"":d.memoizedProps}catch(y){K(e,e.return,y)}}else if((d.tag!==22&&d.tag!==23||d.memoizedState===null||d===e)&&d.child!==null){d.child.return=d,d=d.child;continue}if(d===e)break e;for(;d.sibling===null;){if(d.return===null||d.return===e)break e;c===d&&(c=null),d=d.return}c===d&&(c=null),d.sibling.return=d.return,d=d.sibling}}break;case 19:Ae(t,e),He(e),r&4&&Ja(e);break;case 21:break;default:Ae(t,e),He(e)}}function He(e){var t=e.flags;if(t&2){try{e:{for(var n=e.return;n!==null;){if(Pd(n)){var r=n;break e}n=n.return}throw Error(k(160))}switch(r.tag){case 5:var i=r.stateNode;r.flags&32&&(dr(i,""),r.flags&=-33);var s=Ga(e);No(e,s,i);break;case 3:case 4:var o=r.stateNode.containerInfo,l=Ga(e);$o(e,l,o);break;default:throw Error(k(161))}}catch(a){K(e,e.return,a)}e.flags&=-3}t&4096&&(e.flags&=-4097)}function xp(e,t,n){E=e,Rd(e)}function Rd(e,t,n){for(var r=(e.mode&1)!==0;E!==null;){var i=E,s=i.child;if(i.tag===22&&r){var o=i.memoizedState!==null||Xr;if(!o){var l=i.alternate,a=l!==null&&l.memoizedState!==null||ue;l=Xr;var u=ue;if(Xr=o,(ue=a)&&!u)for(E=i;E!==null;)o=E,a=o.child,o.tag===22&&o.memoizedState!==null?Xa(i):a!==null?(a.return=o,E=a):Xa(i);for(;s!==null;)E=s,Rd(s),s=s.sibling;E=i,Xr=l,ue=u}qa(e)}else i.subtreeFlags&8772&&s!==null?(s.return=i,E=s):qa(e)}}function qa(e){for(;E!==null;){var t=E;if(t.flags&8772){var n=t.alternate;try{if(t.flags&8772)switch(t.tag){case 0:case 11:case 15:ue||Yi(5,t);break;case 1:var r=t.stateNode;if(t.flags&4&&!ue)if(n===null)r.componentDidMount();else{var i=t.elementType===t.type?n.memoizedProps:De(t.type,n.memoizedProps);r.componentDidUpdate(i,n.memoizedState,r.__reactInternalSnapshotBeforeUpdate)}var s=t.updateQueue;s!==null&&Na(t,s,r);break;case 3:var o=t.updateQueue;if(o!==null){if(n=null,t.child!==null)switch(t.child.tag){case 5:n=t.child.stateNode;break;case 1:n=t.child.stateNode}Na(t,o,n)}break;case 5:var l=t.stateNode;if(n===null&&t.flags&4){n=l;var a=t.memoizedProps;switch(t.type){case"button":case"input":case"select":case"textarea":a.autoFocus&&n.focus();break;case"img":a.src&&(n.src=a.src)}}break;case 6:break;case 4:break;case 12:break;case 13:if(t.memoizedState===null){var u=t.alternate;if(u!==null){var c=u.memoizedState;if(c!==null){var d=c.dehydrated;d!==null&&mr(d)}}}break;case 19:case 17:case 21:case 22:case 23:case 25:break;default:throw Error(k(163))}ue||t.flags&512&&Io(t)}catch(f){K(t,t.return,f)}}if(t===e){E=null;break}if(n=t.sibling,n!==null){n.return=t.return,E=n;break}E=t.return}}function Ya(e){for(;E!==null;){var t=E;if(t===e){E=null;break}var n=t.sibling;if(n!==null){n.return=t.return,E=n;break}E=t.return}}function Xa(e){for(;E!==null;){var t=E;try{switch(t.tag){case 0:case 11:case 15:var n=t.return;try{Yi(4,t)}catch(a){K(t,n,a)}break;case 1:var r=t.stateNode;if(typeof r.componentDidMount=="function"){var i=t.return;try{r.componentDidMount()}catch(a){K(t,i,a)}}var s=t.return;try{Io(t)}catch(a){K(t,s,a)}break;case 5:var o=t.return;try{Io(t)}catch(a){K(t,o,a)}}}catch(a){K(t,t.return,a)}if(t===e){E=null;break}var l=t.sibling;if(l!==null){l.return=t.return,E=l;break}E=t.return}}var Pp=Math.ceil,Ui=it.ReactCurrentDispatcher,jl=it.ReactCurrentOwner,Le=it.ReactCurrentBatchConfig,A=0,ne=null,q=null,ie=0,ke=0,pn=Tt(0),X=0,Pr=null,Kt=0,Xi=0,Ll=0,or=null,me=null,Il=0,On=1/0,Je=null,Di=!1,Ao=null,kt=null,Zr=!1,pt=null,zi=0,lr=0,Uo=null,fi=-1,pi=0;function he(){return A&6?J():fi!==-1?fi:fi=J()}function St(e){return e.mode&1?A&2&&ie!==0?ie&-ie:up.transition!==null?(pi===0&&(pi=fc()),pi):(e=U,e!==0||(e=window.event,e=e===void 0?16:_c(e.type)),e):1}function Be(e,t,n,r){if(50<lr)throw lr=0,Uo=null,Error(k(185));Lr(e,n,r),(!(A&2)||e!==ne)&&(e===ne&&(!(A&2)&&(Xi|=n),X===4&&dt(e,ie)),we(e,r),n===1&&A===0&&!(t.mode&1)&&(On=J()+500,Gi&&Ot()))}function we(e,t){var n=e.callbackNode;uf(e,t);var r=ki(e,e===ne?ie:0);if(r===0)n!==null&&la(n),e.callbackNode=null,e.callbackPriority=0;else if(t=r&-r,e.callbackPriority!==t){if(n!=null&&la(n),t===1)e.tag===0?ap(Za.bind(null,e)):Fc(Za.bind(null,e)),ip(function(){!(A&6)&&Ot()}),n=null;else{switch(pc(r)){case 1:n=il;break;case 4:n=dc;break;case 16:n=_i;break;case 536870912:n=hc;break;default:n=_i}n=Dd(n,jd.bind(null,e))}e.callbackPriority=t,e.callbackNode=n}}function jd(e,t){if(fi=-1,pi=0,A&6)throw Error(k(327));var n=e.callbackNode;if(_n()&&e.callbackNode!==n)return null;var r=ki(e,e===ne?ie:0);if(r===0)return null;if(r&30||r&e.expiredLanes||t)t=Fi(e,r);else{t=r;var i=A;A|=2;var s=Id();(ne!==e||ie!==t)&&(Je=null,On=J()+500,Mt(e,t));do try{Rp();break}catch(l){Ld(e,l)}while(!0);gl(),Ui.current=s,A=i,q!==null?t=0:(ne=null,ie=0,t=X)}if(t!==0){if(t===2&&(i=ao(e),i!==0&&(r=i,t=Do(e,i))),t===1)throw n=Pr,Mt(e,0),dt(e,r),we(e,J()),n;if(t===6)dt(e,r);else{if(i=e.current.alternate,!(r&30)&&!Tp(i)&&(t=Fi(e,r),t===2&&(s=ao(e),s!==0&&(r=s,t=Do(e,s))),t===1))throw n=Pr,Mt(e,0),dt(e,r),we(e,J()),n;switch(e.finishedWork=i,e.finishedLanes=r,t){case 0:case 1:throw Error(k(345));case 2:Nt(e,me,Je);break;case 3:if(dt(e,r),(r&130023424)===r&&(t=Il+500-J(),10<t)){if(ki(e,0)!==0)break;if(i=e.suspendedLanes,(i&r)!==r){he(),e.pingedLanes|=e.suspendedLanes&i;break}e.timeoutHandle=go(Nt.bind(null,e,me,Je),t);break}Nt(e,me,Je);break;case 4:if(dt(e,r),(r&4194240)===r)break;for(t=e.eventTimes,i=-1;0<r;){var o=31-be(r);s=1<<o,o=t[o],o>i&&(i=o),r&=~s}if(r=i,r=J()-r,r=(120>r?120:480>r?480:1080>r?1080:1920>r?1920:3e3>r?3e3:4320>r?4320:1960*Pp(r/1960))-r,10<r){e.timeoutHandle=go(Nt.bind(null,e,me,Je),r);break}Nt(e,me,Je);break;case 5:Nt(e,me,Je);break;default:throw Error(k(329))}}}return we(e,J()),e.callbackNode===n?jd.bind(null,e):null}function Do(e,t){var n=or;return e.current.memoizedState.isDehydrated&&(Mt(e,t).flags|=256),e=Fi(e,t),e!==2&&(t=me,me=n,t!==null&&zo(t)),e}function zo(e){me===null?me=e:me.push.apply(me,e)}function Tp(e){for(var t=e;;){if(t.flags&16384){var n=t.updateQueue;if(n!==null&&(n=n.stores,n!==null))for(var r=0;r<n.length;r++){var i=n[r],s=i.getSnapshot;i=i.value;try{if(!Ve(s(),i))return!1}catch{return!1}}}if(n=t.child,t.subtreeFlags&16384&&n!==null)n.return=t,t=n;else{if(t===e)break;for(;t.sibling===null;){if(t.return===null||t.return===e)return!0;t=t.return}t.sibling.return=t.return,t=t.sibling}}return!0}function dt(e,t){for(t&=~Ll,t&=~Xi,e.suspendedLanes|=t,e.pingedLanes&=~t,e=e.expirationTimes;0<t;){var n=31-be(t),r=1<<n;e[n]=-1,t&=~r}}function Za(e){if(A&6)throw Error(k(327));_n();var t=ki(e,0);if(!(t&1))return we(e,J()),null;var n=Fi(e,t);if(e.tag!==0&&n===2){var r=ao(e);r!==0&&(t=r,n=Do(e,r))}if(n===1)throw n=Pr,Mt(e,0),dt(e,t),we(e,J()),n;if(n===6)throw Error(k(345));return e.finishedWork=e.current.alternate,e.finishedLanes=t,Nt(e,me,Je),we(e,J()),null}function $l(e,t){var n=A;A|=1;try{return e(t)}finally{A=n,A===0&&(On=J()+500,Gi&&Ot())}}function Qt(e){pt!==null&&pt.tag===0&&!(A&6)&&_n();var t=A;A|=1;var n=Le.transition,r=U;try{if(Le.transition=null,U=1,e)return e()}finally{U=r,Le.transition=n,A=t,!(A&6)&&Ot()}}function Nl(){ke=pn.current,b(pn)}function Mt(e,t){e.finishedWork=null,e.finishedLanes=0;var n=e.timeoutHandle;if(n!==-1&&(e.timeoutHandle=-1,rp(n)),q!==null)for(n=q.return;n!==null;){var r=n;switch(pl(r),r.tag){case 1:r=r.type.childContextTypes,r!=null&&Pi();break;case 3:Pn(),b(ge),b(ce),El();break;case 5:Sl(r);break;case 4:Pn();break;case 13:b(V);break;case 19:b(V);break;case 10:yl(r.type._context);break;case 22:case 23:Nl()}n=n.return}if(ne=e,q=e=Et(e.current,null),ie=ke=t,X=0,Pr=null,Ll=Xi=Kt=0,me=or=null,zt!==null){for(t=0;t<zt.length;t++)if(n=zt[t],r=n.interleaved,r!==null){n.interleaved=null;var i=r.next,s=n.pending;if(s!==null){var o=s.next;s.next=i,r.next=o}n.pending=r}zt=null}return e}function Ld(e,t){do{var n=q;try{if(gl(),ci.current=Ai,Ni){for(var r=H.memoizedState;r!==null;){var i=r.queue;i!==null&&(i.pending=null),r=r.next}Ni=!1}if(Wt=0,te=Y=H=null,ir=!1,Er=0,jl.current=null,n===null||n.return===null){X=1,Pr=t,q=null;break}e:{var s=e,o=n.return,l=n,a=t;if(t=ie,l.flags|=32768,a!==null&&typeof a=="object"&&typeof a.then=="function"){var u=a,c=l,d=c.tag;if(!(c.mode&1)&&(d===0||d===11||d===15)){var f=c.alternate;f?(c.updateQueue=f.updateQueue,c.memoizedState=f.memoizedState,c.lanes=f.lanes):(c.updateQueue=null,c.memoizedState=null)}var v=Ma(o);if(v!==null){v.flags&=-257,ba(v,o,l,s,t),v.mode&1&&Fa(s,u,t),t=v,a=u;var g=t.updateQueue;if(g===null){var y=new Set;y.add(a),t.updateQueue=y}else g.add(a);break e}else{if(!(t&1)){Fa(s,u,t),Al();break e}a=Error(k(426))}}else if(B&&l.mode&1){var _=Ma(o);if(_!==null){!(_.flags&65536)&&(_.flags|=256),ba(_,o,l,s,t),ml(Tn(a,l));break e}}s=a=Tn(a,l),X!==4&&(X=2),or===null?or=[s]:or.push(s),s=o;do{switch(s.tag){case 3:s.flags|=65536,t&=-t,s.lanes|=t;var p=pd(s,a,t);$a(s,p);break e;case 1:l=a;var h=s.type,m=s.stateNode;if(!(s.flags&128)&&(typeof h.getDerivedStateFromError=="function"||m!==null&&typeof m.componentDidCatch=="function"&&(kt===null||!kt.has(m)))){s.flags|=65536,t&=-t,s.lanes|=t;var w=md(s,l,t);$a(s,w);break e}}s=s.return}while(s!==null)}Nd(n)}catch(S){t=S,q===n&&n!==null&&(q=n=n.return);continue}break}while(!0)}function Id(){var e=Ui.current;return Ui.current=Ai,e===null?Ai:e}function Al(){(X===0||X===3||X===2)&&(X=4),ne===null||!(Kt&268435455)&&!(Xi&268435455)||dt(ne,ie)}function Fi(e,t){var n=A;A|=2;var r=Id();(ne!==e||ie!==t)&&(Je=null,Mt(e,t));do try{Op();break}catch(i){Ld(e,i)}while(!0);if(gl(),A=n,Ui.current=r,q!==null)throw Error(k(261));return ne=null,ie=0,X}function Op(){for(;q!==null;)$d(q)}function Rp(){for(;q!==null&&!Zh();)$d(q)}function $d(e){var t=Ud(e.alternate,e,ke);e.memoizedProps=e.pendingProps,t===null?Nd(e):q=t,jl.current=null}function Nd(e){var t=e;do{var n=t.alternate;if(e=t.return,t.flags&32768){if(n=Sp(n,t),n!==null){n.flags&=32767,q=n;return}if(e!==null)e.flags|=32768,e.subtreeFlags=0,e.deletions=null;else{X=6,q=null;return}}else if(n=kp(n,t,ke),n!==null){q=n;return}if(t=t.sibling,t!==null){q=t;return}q=t=e}while(t!==null);X===0&&(X=5)}function Nt(e,t,n){var r=U,i=Le.transition;try{Le.transition=null,U=1,jp(e,t,n,r)}finally{Le.transition=i,U=r}return null}function jp(e,t,n,r){do _n();while(pt!==null);if(A&6)throw Error(k(327));n=e.finishedWork;var i=e.finishedLanes;if(n===null)return null;if(e.finishedWork=null,e.finishedLanes=0,n===e.current)throw Error(k(177));e.callbackNode=null,e.callbackPriority=0;var s=n.lanes|n.childLanes;if(cf(e,s),e===ne&&(q=ne=null,ie=0),!(n.subtreeFlags&2064)&&!(n.flags&2064)||Zr||(Zr=!0,Dd(_i,function(){return _n(),null})),s=(n.flags&15990)!==0,n.subtreeFlags&15990||s){s=Le.transition,Le.transition=null;var o=U;U=1;var l=A;A|=4,jl.current=null,Cp(e,n),Od(n,e),qf(mo),Si=!!po,mo=po=null,e.current=n,xp(n),ef(),A=l,U=o,Le.transition=s}else e.current=n;if(Zr&&(Zr=!1,pt=e,zi=i),s=e.pendingLanes,s===0&&(kt=null),rf(n.stateNode),we(e,J()),t!==null)for(r=e.onRecoverableError,n=0;n<t.length;n++)i=t[n],r(i.value,{componentStack:i.stack,digest:i.digest});if(Di)throw Di=!1,e=Ao,Ao=null,e;return zi&1&&e.tag!==0&&_n(),s=e.pendingLanes,s&1?e===Uo?lr++:(lr=0,Uo=e):lr=0,Ot(),null}function _n(){if(pt!==null){var e=pc(zi),t=Le.transition,n=U;try{if(Le.transition=null,U=16>e?16:e,pt===null)var r=!1;else{if(e=pt,pt=null,zi=0,A&6)throw Error(k(331));var i=A;for(A|=4,E=e.current;E!==null;){var s=E,o=s.child;if(E.flags&16){var l=s.deletions;if(l!==null){for(var a=0;a<l.length;a++){var u=l[a];for(E=u;E!==null;){var c=E;switch(c.tag){case 0:case 11:case 15:sr(8,c,s)}var d=c.child;if(d!==null)d.return=c,E=d;else for(;E!==null;){c=E;var f=c.sibling,v=c.return;if(xd(c),c===u){E=null;break}if(f!==null){f.return=v,E=f;break}E=v}}}var g=s.alternate;if(g!==null){var y=g.child;if(y!==null){g.child=null;do{var _=y.sibling;y.sibling=null,y=_}while(y!==null)}}E=s}}if(s.subtreeFlags&2064&&o!==null)o.return=s,E=o;else e:for(;E!==null;){if(s=E,s.flags&2048)switch(s.tag){case 0:case 11:case 15:sr(9,s,s.return)}var p=s.sibling;if(p!==null){p.return=s.return,E=p;break e}E=s.return}}var h=e.current;for(E=h;E!==null;){o=E;var m=o.child;if(o.subtreeFlags&2064&&m!==null)m.return=o,E=m;else e:for(o=h;E!==null;){if(l=E,l.flags&2048)try{switch(l.tag){case 0:case 11:case 15:Yi(9,l)}}catch(S){K(l,l.return,S)}if(l===o){E=null;break e}var w=l.sibling;if(w!==null){w.return=l.return,E=w;break e}E=l.return}}if(A=i,Ot(),Qe&&typeof Qe.onPostCommitFiberRoot=="function")try{Qe.onPostCommitFiberRoot(Vi,e)}catch{}r=!0}return r}finally{U=n,Le.transition=t}}return!1}function eu(e,t,n){t=Tn(n,t),t=pd(e,t,1),e=_t(e,t,1),t=he(),e!==null&&(Lr(e,1,t),we(e,t))}function K(e,t,n){if(e.tag===3)eu(e,e,n);else for(;t!==null;){if(t.tag===3){eu(t,e,n);break}else if(t.tag===1){var r=t.stateNode;if(typeof t.type.getDerivedStateFromError=="function"||typeof r.componentDidCatch=="function"&&(kt===null||!kt.has(r))){e=Tn(n,e),e=md(t,e,1),t=_t(t,e,1),e=he(),t!==null&&(Lr(t,1,e),we(t,e));break}}t=t.return}}function Lp(e,t,n){var r=e.pingCache;r!==null&&r.delete(t),t=he(),e.pingedLanes|=e.suspendedLanes&n,ne===e&&(ie&n)===n&&(X===4||X===3&&(ie&130023424)===ie&&500>J()-Il?Mt(e,0):Ll|=n),we(e,t)}function Ad(e,t){t===0&&(e.mode&1?(t=Vr,Vr<<=1,!(Vr&130023424)&&(Vr=4194304)):t=1);var n=he();e=nt(e,t),e!==null&&(Lr(e,t,n),we(e,n))}function Ip(e){var t=e.memoizedState,n=0;t!==null&&(n=t.retryLane),Ad(e,n)}function $p(e,t){var n=0;switch(e.tag){case 13:var r=e.stateNode,i=e.memoizedState;i!==null&&(n=i.retryLane);break;case 19:r=e.stateNode;break;default:throw Error(k(314))}r!==null&&r.delete(t),Ad(e,n)}var Ud;Ud=function(e,t,n){if(e!==null)if(e.memoizedProps!==t.pendingProps||ge.current)ve=!0;else{if(!(e.lanes&n)&&!(t.flags&128))return ve=!1,_p(e,t,n);ve=!!(e.flags&131072)}else ve=!1,B&&t.flags&1048576&&Mc(t,Ri,t.index);switch(t.lanes=0,t.tag){case 2:var r=t.type;hi(e,t),e=t.pendingProps;var i=En(t,ce.current);wn(t,n),i=xl(null,t,r,e,i,n);var s=Pl();return t.flags|=1,typeof i=="object"&&i!==null&&typeof i.render=="function"&&i.$$typeof===void 0?(t.tag=1,t.memoizedState=null,t.updateQueue=null,ye(r)?(s=!0,Ti(t)):s=!1,t.memoizedState=i.state!==null&&i.state!==void 0?i.state:null,_l(t),i.updater=qi,t.stateNode=i,i._reactInternals=t,Co(t,r,e,n),t=To(null,t,r,!0,s,n)):(t.tag=0,B&&s&&fl(t),de(null,t,i,n),t=t.child),t;case 16:r=t.elementType;e:{switch(hi(e,t),e=t.pendingProps,i=r._init,r=i(r._payload),t.type=r,i=t.tag=Ap(r),e=De(r,e),i){case 0:t=Po(null,t,r,e,n);break e;case 1:t=Ha(null,t,r,e,n);break e;case 11:t=Ba(null,t,r,e,n);break e;case 14:t=Va(null,t,r,De(r.type,e),n);break e}throw Error(k(306,r,""))}return t;case 0:return r=t.type,i=t.pendingProps,i=t.elementType===r?i:De(r,i),Po(e,t,r,i,n);case 1:return r=t.type,i=t.pendingProps,i=t.elementType===r?i:De(r,i),Ha(e,t,r,i,n);case 3:e:{if(wd(t),e===null)throw Error(k(387));r=t.pendingProps,s=t.memoizedState,i=s.element,Kc(e,t),Ii(t,r,null,n);var o=t.memoizedState;if(r=o.element,s.isDehydrated)if(s={element:r,isDehydrated:!1,cache:o.cache,pendingSuspenseBoundaries:o.pendingSuspenseBoundaries,transitions:o.transitions},t.updateQueue.baseState=s,t.memoizedState=s,t.flags&256){i=Tn(Error(k(423)),t),t=Wa(e,t,r,n,i);break e}else if(r!==i){i=Tn(Error(k(424)),t),t=Wa(e,t,r,n,i);break e}else for(Se=wt(t.stateNode.containerInfo.firstChild),Ee=t,B=!0,Me=null,n=Hc(t,null,r,n),t.child=n;n;)n.flags=n.flags&-3|4096,n=n.sibling;else{if(Cn(),r===i){t=rt(e,t,n);break e}de(e,t,r,n)}t=t.child}return t;case 5:return Qc(t),e===null&&ko(t),r=t.type,i=t.pendingProps,s=e!==null?e.memoizedProps:null,o=i.children,vo(r,i)?o=null:s!==null&&vo(r,s)&&(t.flags|=32),yd(e,t),de(e,t,o,n),t.child;case 6:return e===null&&ko(t),null;case 13:return _d(e,t,n);case 4:return kl(t,t.stateNode.containerInfo),r=t.pendingProps,e===null?t.child=xn(t,null,r,n):de(e,t,r,n),t.child;case 11:return r=t.type,i=t.pendingProps,i=t.elementType===r?i:De(r,i),Ba(e,t,r,i,n);case 7:return de(e,t,t.pendingProps,n),t.child;case 8:return de(e,t,t.pendingProps.children,n),t.child;case 12:return de(e,t,t.pendingProps.children,n),t.child;case 10:e:{if(r=t.type._context,i=t.pendingProps,s=t.memoizedProps,o=i.value,F(ji,r._currentValue),r._currentValue=o,s!==null)if(Ve(s.value,o)){if(s.children===i.children&&!ge.current){t=rt(e,t,n);break e}}else for(s=t.child,s!==null&&(s.return=t);s!==null;){var l=s.dependencies;if(l!==null){o=s.child;for(var a=l.firstContext;a!==null;){if(a.context===r){if(s.tag===1){a=Ze(-1,n&-n),a.tag=2;var u=s.updateQueue;if(u!==null){u=u.shared;var c=u.pending;c===null?a.next=a:(a.next=c.next,c.next=a),u.pending=a}}s.lanes|=n,a=s.alternate,a!==null&&(a.lanes|=n),So(s.return,n,t),l.lanes|=n;break}a=a.next}}else if(s.tag===10)o=s.type===t.type?null:s.child;else if(s.tag===18){if(o=s.return,o===null)throw Error(k(341));o.lanes|=n,l=o.alternate,l!==null&&(l.lanes|=n),So(o,n,t),o=s.sibling}else o=s.child;if(o!==null)o.return=s;else for(o=s;o!==null;){if(o===t){o=null;break}if(s=o.sibling,s!==null){s.return=o.return,o=s;break}o=o.return}s=o}de(e,t,i.children,n),t=t.child}return t;case 9:return i=t.type,r=t.pendingProps.children,wn(t,n),i=Ie(i),r=r(i),t.flags|=1,de(e,t,r,n),t.child;case 14:return r=t.type,i=De(r,t.pendingProps),i=De(r.type,i),Va(e,t,r,i,n);case 15:return vd(e,t,t.type,t.pendingProps,n);case 17:return r=t.type,i=t.pendingProps,i=t.elementType===r?i:De(r,i),hi(e,t),t.tag=1,ye(r)?(e=!0,Ti(t)):e=!1,wn(t,n),fd(t,r,i),Co(t,r,i,n),To(null,t,r,!0,e,n);case 19:return kd(e,t,n);case 22:return gd(e,t,n)}throw Error(k(156,t.tag))};function Dd(e,t){return cc(e,t)}function Np(e,t,n,r){this.tag=e,this.key=n,this.sibling=this.child=this.return=this.stateNode=this.type=this.elementType=null,this.index=0,this.ref=null,this.pendingProps=t,this.dependencies=this.memoizedState=this.updateQueue=this.memoizedProps=null,this.mode=r,this.subtreeFlags=this.flags=0,this.deletions=null,this.childLanes=this.lanes=0,this.alternate=null}function je(e,t,n,r){return new Np(e,t,n,r)}function Ul(e){return e=e.prototype,!(!e||!e.isReactComponent)}function Ap(e){if(typeof e=="function")return Ul(e)?1:0;if(e!=null){if(e=e.$$typeof,e===tl)return 11;if(e===nl)return 14}return 2}function Et(e,t){var n=e.alternate;return n===null?(n=je(e.tag,t,e.key,e.mode),n.elementType=e.elementType,n.type=e.type,n.stateNode=e.stateNode,n.alternate=e,e.alternate=n):(n.pendingProps=t,n.type=e.type,n.flags=0,n.subtreeFlags=0,n.deletions=null),n.flags=e.flags&14680064,n.childLanes=e.childLanes,n.lanes=e.lanes,n.child=e.child,n.memoizedProps=e.memoizedProps,n.memoizedState=e.memoizedState,n.updateQueue=e.updateQueue,t=e.dependencies,n.dependencies=t===null?null:{lanes:t.lanes,firstContext:t.firstContext},n.sibling=e.sibling,n.index=e.index,n.ref=e.ref,n}function mi(e,t,n,r,i,s){var o=2;if(r=e,typeof e=="function")Ul(e)&&(o=1);else if(typeof e=="string")o=5;else e:switch(e){case rn:return bt(n.children,i,s,t);case el:o=8,i|=8;break;case Qs:return e=je(12,n,t,i|2),e.elementType=Qs,e.lanes=s,e;case Gs:return e=je(13,n,t,i),e.elementType=Gs,e.lanes=s,e;case Js:return e=je(19,n,t,i),e.elementType=Js,e.lanes=s,e;case Qu:return Zi(n,i,s,t);default:if(typeof e=="object"&&e!==null)switch(e.$$typeof){case Wu:o=10;break e;case Ku:o=9;break e;case tl:o=11;break e;case nl:o=14;break e;case lt:o=16,r=null;break e}throw Error(k(130,e==null?e:typeof e,""))}return t=je(o,n,t,i),t.elementType=e,t.type=r,t.lanes=s,t}function bt(e,t,n,r){return e=je(7,e,r,t),e.lanes=n,e}function Zi(e,t,n,r){return e=je(22,e,r,t),e.elementType=Qu,e.lanes=n,e.stateNode={isHidden:!1},e}function Us(e,t,n){return e=je(6,e,null,t),e.lanes=n,e}function Ds(e,t,n){return t=je(4,e.children!==null?e.children:[],e.key,t),t.lanes=n,t.stateNode={containerInfo:e.containerInfo,pendingChildren:null,implementation:e.implementation},t}function Up(e,t,n,r,i){this.tag=t,this.containerInfo=e,this.finishedWork=this.pingCache=this.current=this.pendingChildren=null,this.timeoutHandle=-1,this.callbackNode=this.pendingContext=this.context=null,this.callbackPriority=0,this.eventTimes=gs(0),this.expirationTimes=gs(-1),this.entangledLanes=this.finishedLanes=this.mutableReadLanes=this.expiredLanes=this.pingedLanes=this.suspendedLanes=this.pendingLanes=0,this.entanglements=gs(0),this.identifierPrefix=r,this.onRecoverableError=i,this.mutableSourceEagerHydrationData=null}function Dl(e,t,n,r,i,s,o,l,a){return e=new Up(e,t,n,l,a),t===1?(t=1,s===!0&&(t|=8)):t=0,s=je(3,null,null,t),e.current=s,s.stateNode=e,s.memoizedState={element:r,isDehydrated:n,cache:null,transitions:null,pendingSuspenseBoundaries:null},_l(s),e}function Dp(e,t,n){var r=3<arguments.length&&arguments[3]!==void 0?arguments[3]:null;return{$$typeof:nn,key:r==null?null:""+r,children:e,containerInfo:t,implementation:n}}function zd(e){if(!e)return xt;e=e._reactInternals;e:{if(Jt(e)!==e||e.tag!==1)throw Error(k(170));var t=e;do{switch(t.tag){case 3:t=t.stateNode.context;break e;case 1:if(ye(t.type)){t=t.stateNode.__reactInternalMemoizedMergedChildContext;break e}}t=t.return}while(t!==null);throw Error(k(171))}if(e.tag===1){var n=e.type;if(ye(n))return zc(e,n,t)}return t}function Fd(e,t,n,r,i,s,o,l,a){return e=Dl(n,r,!0,e,i,s,o,l,a),e.context=zd(null),n=e.current,r=he(),i=St(n),s=Ze(r,i),s.callback=t??null,_t(n,s,i),e.current.lanes=i,Lr(e,i,r),we(e,r),e}function es(e,t,n,r){var i=t.current,s=he(),o=St(i);return n=zd(n),t.context===null?t.context=n:t.pendingContext=n,t=Ze(s,o),t.payload={element:e},r=r===void 0?null:r,r!==null&&(t.callback=r),e=_t(i,t,o),e!==null&&(Be(e,i,o,s),ui(e,i,o)),o}function Mi(e){if(e=e.current,!e.child)return null;switch(e.child.tag){case 5:return e.child.stateNode;default:return e.child.stateNode}}function tu(e,t){if(e=e.memoizedState,e!==null&&e.dehydrated!==null){var n=e.retryLane;e.retryLane=n!==0&&n<t?n:t}}function zl(e,t){tu(e,t),(e=e.alternate)&&tu(e,t)}function zp(){return null}var Md=typeof reportError=="function"?reportError:function(e){console.error(e)};function Fl(e){this._internalRoot=e}ts.prototype.render=Fl.prototype.render=function(e){var t=this._internalRoot;if(t===null)throw Error(k(409));es(e,t,null,null)};ts.prototype.unmount=Fl.prototype.unmount=function(){var e=this._internalRoot;if(e!==null){this._internalRoot=null;var t=e.containerInfo;Qt(function(){es(null,e,null,null)}),t[tt]=null}};function ts(e){this._internalRoot=e}ts.prototype.unstable_scheduleHydration=function(e){if(e){var t=gc();e={blockedOn:null,target:e,priority:t};for(var n=0;n<ct.length&&t!==0&&t<ct[n].priority;n++);ct.splice(n,0,e),n===0&&wc(e)}};function Ml(e){return!(!e||e.nodeType!==1&&e.nodeType!==9&&e.nodeType!==11)}function ns(e){return!(!e||e.nodeType!==1&&e.nodeType!==9&&e.nodeType!==11&&(e.nodeType!==8||e.nodeValue!==" react-mount-point-unstable "))}function nu(){}function Fp(e,t,n,r,i){if(i){if(typeof r=="function"){var s=r;r=function(){var u=Mi(o);s.call(u)}}var o=Fd(t,r,e,0,null,!1,!1,"",nu);return e._reactRootContainer=o,e[tt]=o.current,yr(e.nodeType===8?e.parentNode:e),Qt(),o}for(;i=e.lastChild;)e.removeChild(i);if(typeof r=="function"){var l=r;r=function(){var u=Mi(a);l.call(u)}}var a=Dl(e,0,!1,null,null,!1,!1,"",nu);return e._reactRootContainer=a,e[tt]=a.current,yr(e.nodeType===8?e.parentNode:e),Qt(function(){es(t,a,n,r)}),a}function rs(e,t,n,r,i){var s=n._reactRootContainer;if(s){var o=s;if(typeof i=="function"){var l=i;i=function(){var a=Mi(o);l.call(a)}}es(t,o,e,i)}else o=Fp(n,t,e,i,r);return Mi(o)}mc=function(e){switch(e.tag){case 3:var t=e.stateNode;if(t.current.memoizedState.isDehydrated){var n=qn(t.pendingLanes);n!==0&&(sl(t,n|1),we(t,J()),!(A&6)&&(On=J()+500,Ot()))}break;case 13:Qt(function(){var r=nt(e,1);if(r!==null){var i=he();Be(r,e,1,i)}}),zl(e,1)}};ol=function(e){if(e.tag===13){var t=nt(e,134217728);if(t!==null){var n=he();Be(t,e,134217728,n)}zl(e,134217728)}};vc=function(e){if(e.tag===13){var t=St(e),n=nt(e,t);if(n!==null){var r=he();Be(n,e,t,r)}zl(e,t)}};gc=function(){return U};yc=function(e,t){var n=U;try{return U=e,t()}finally{U=n}};so=function(e,t,n){switch(t){case"input":if(Xs(e,n),t=n.name,n.type==="radio"&&t!=null){for(n=e;n.parentNode;)n=n.parentNode;for(n=n.querySelectorAll("input[name="+JSON.stringify(""+t)+'][type="radio"]'),t=0;t<n.length;t++){var r=n[t];if(r!==e&&r.form===e.form){var i=Qi(r);if(!i)throw Error(k(90));Ju(r),Xs(r,i)}}}break;case"textarea":Yu(e,n);break;case"select":t=n.value,t!=null&&mn(e,!!n.multiple,t,!1)}};ic=$l;sc=Qt;var Mp={usingClientEntryPoint:!1,Events:[$r,an,Qi,nc,rc,$l]},Kn={findFiberByHostInstance:Dt,bundleType:0,version:"18.3.1",rendererPackageName:"react-dom"},bp={bundleType:Kn.bundleType,version:Kn.version,rendererPackageName:Kn.rendererPackageName,rendererConfig:Kn.rendererConfig,overrideHookState:null,overrideHookStateDeletePath:null,overrideHookStateRenamePath:null,overrideProps:null,overridePropsDeletePath:null,overridePropsRenamePath:null,setErrorHandler:null,setSuspenseHandler:null,scheduleUpdate:null,currentDispatcherRef:it.ReactCurrentDispatcher,findHostInstanceByFiber:function(e){return e=ac(e),e===null?null:e.stateNode},findFiberByHostInstance:Kn.findFiberByHostInstance||zp,findHostInstancesForRefresh:null,scheduleRefresh:null,scheduleRoot:null,setRefreshHandler:null,getCurrentFiber:null,reconcilerVersion:"18.3.1-next-f1338f8080-20240426"};if(typeof __REACT_DEVTOOLS_GLOBAL_HOOK__<"u"){var ei=__REACT_DEVTOOLS_GLOBAL_HOOK__;if(!ei.isDisabled&&ei.supportsFiber)try{Vi=ei.inject(bp),Qe=ei}catch{}}xe.__SECRET_INTERNALS_DO_NOT_USE_OR_YOU_WILL_BE_FIRED=Mp;xe.createPortal=function(e,t){var n=2<arguments.length&&arguments[2]!==void 0?arguments[2]:null;if(!Ml(t))throw Error(k(200));return Dp(e,t,null,n)};xe.createRoot=function(e,t){if(!Ml(e))throw Error(k(299));var n=!1,r="",i=Md;return t!=null&&(t.unstable_strictMode===!0&&(n=!0),t.identifierPrefix!==void 0&&(r=t.identifierPrefix),t.onRecoverableError!==void 0&&(i=t.onRecoverableError)),t=Dl(e,1,!1,null,null,n,!1,r,i),e[tt]=t.current,yr(e.nodeType===8?e.parentNode:e),new Fl(t)};xe.findDOMNode=function(e){if(e==null)return null;if(e.nodeType===1)return e;var t=e._reactInternals;if(t===void 0)throw typeof e.render=="function"?Error(k(188)):(e=Object.keys(e).join(","),Error(k(268,e)));return e=ac(t),e=e===null?null:e.stateNode,e};xe.flushSync=function(e){return Qt(e)};xe.hydrate=function(e,t,n){if(!ns(t))throw Error(k(200));return rs(null,e,t,!0,n)};xe.hydrateRoot=function(e,t,n){if(!Ml(e))throw Error(k(405));var r=n!=null&&n.hydratedSources||null,i=!1,s="",o=Md;if(n!=null&&(n.unstable_strictMode===!0&&(i=!0),n.identifierPrefix!==void 0&&(s=n.identifierPrefix),n.onRecoverableError!==void 0&&(o=n.onRecoverableError)),t=Fd(t,null,e,1,n??null,i,!1,s,o),e[tt]=t.current,yr(e),r)for(e=0;e<r.length;e++)n=r[e],i=n._getVersion,i=i(n._source),t.mutableSourceEagerHydrationData==null?t.mutableSourceEagerHydrationData=[n,i]:t.mutableSourceEagerHydrationData.push(n,i);return new ts(t)};xe.render=function(e,t,n){if(!ns(t))throw Error(k(200));return rs(null,e,t,!1,n)};xe.unmountComponentAtNode=function(e){if(!ns(e))throw Error(k(40));return e._reactRootContainer?(Qt(function(){rs(null,null,e,!1,function(){e._reactRootContainer=null,e[tt]=null})}),!0):!1};xe.unstable_batchedUpdates=$l;xe.unstable_renderSubtreeIntoContainer=function(e,t,n,r){if(!ns(n))throw Error(k(200));if(e==null||e._reactInternals===void 0)throw Error(k(38));return rs(e,t,n,!1,r)};xe.version="18.3.1-next-f1338f8080-20240426";function bd(){if(!(typeof __REACT_DEVTOOLS_GLOBAL_HOOK__>"u"||typeof __REACT_DEVTOOLS_GLOBAL_HOOK__.checkDCE!="function"))try{__REACT_DEVTOOLS_GLOBAL_HOOK__.checkDCE(bd)}catch(e){console.error(e)}}bd(),bu.exports=xe;var Bp=bu.exports,ru=Bp;Ws.createRoot=ru.createRoot,Ws.hydrateRoot=ru.hydrateRoot;/** - * @remix-run/router v1.16.1 - * - * Copyright (c) Remix Software Inc. - * - * This source code is licensed under the MIT license found in the - * LICENSE.md file in the root directory of this source tree. - * - * @license MIT - */function Tr(){return Tr=Object.assign?Object.assign.bind():function(e){for(var t=1;t<arguments.length;t++){var n=arguments[t];for(var r in n)Object.prototype.hasOwnProperty.call(n,r)&&(e[r]=n[r])}return e},Tr.apply(this,arguments)}var mt;(function(e){e.Pop="POP",e.Push="PUSH",e.Replace="REPLACE"})(mt||(mt={}));const iu="popstate";function Vp(e){e===void 0&&(e={});function t(r,i){let{pathname:s,search:o,hash:l}=r.location;return Fo("",{pathname:s,search:o,hash:l},i.state&&i.state.usr||null,i.state&&i.state.key||"default")}function n(r,i){return typeof i=="string"?i:Vd(i)}return Wp(t,n,null,e)}function Z(e,t){if(e===!1||e===null||typeof e>"u")throw new Error(t)}function Bd(e,t){if(!e){typeof console<"u"&&console.warn(t);try{throw new Error(t)}catch{}}}function Hp(){return Math.random().toString(36).substr(2,8)}function su(e,t){return{usr:e.state,key:e.key,idx:t}}function Fo(e,t,n,r){return n===void 0&&(n=null),Tr({pathname:typeof e=="string"?e:e.pathname,search:"",hash:""},typeof t=="string"?Nn(t):t,{state:n,key:t&&t.key||r||Hp()})}function Vd(e){let{pathname:t="/",search:n="",hash:r=""}=e;return n&&n!=="?"&&(t+=n.charAt(0)==="?"?n:"?"+n),r&&r!=="#"&&(t+=r.charAt(0)==="#"?r:"#"+r),t}function Nn(e){let t={};if(e){let n=e.indexOf("#");n>=0&&(t.hash=e.substr(n),e=e.substr(0,n));let r=e.indexOf("?");r>=0&&(t.search=e.substr(r),e=e.substr(0,r)),e&&(t.pathname=e)}return t}function Wp(e,t,n,r){r===void 0&&(r={});let{window:i=document.defaultView,v5Compat:s=!1}=r,o=i.history,l=mt.Pop,a=null,u=c();u==null&&(u=0,o.replaceState(Tr({},o.state,{idx:u}),""));function c(){return(o.state||{idx:null}).idx}function d(){l=mt.Pop;let _=c(),p=_==null?null:_-u;u=_,a&&a({action:l,location:y.location,delta:p})}function f(_,p){l=mt.Push;let h=Fo(y.location,_,p);u=c()+1;let m=su(h,u),w=y.createHref(h);try{o.pushState(m,"",w)}catch(S){if(S instanceof DOMException&&S.name==="DataCloneError")throw S;i.location.assign(w)}s&&a&&a({action:l,location:y.location,delta:1})}function v(_,p){l=mt.Replace;let h=Fo(y.location,_,p);u=c();let m=su(h,u),w=y.createHref(h);o.replaceState(m,"",w),s&&a&&a({action:l,location:y.location,delta:0})}function g(_){let p=i.location.origin!=="null"?i.location.origin:i.location.href,h=typeof _=="string"?_:Vd(_);return h=h.replace(/ $/,"%20"),Z(p,"No window.location.(origin|href) available to create URL for href: "+h),new URL(h,p)}let y={get action(){return l},get location(){return e(i,o)},listen(_){if(a)throw new Error("A history only accepts one active listener");return i.addEventListener(iu,d),a=_,()=>{i.removeEventListener(iu,d),a=null}},createHref(_){return t(i,_)},createURL:g,encodeLocation(_){let p=g(_);return{pathname:p.pathname,search:p.search,hash:p.hash}},push:f,replace:v,go(_){return o.go(_)}};return y}var ou;(function(e){e.data="data",e.deferred="deferred",e.redirect="redirect",e.error="error"})(ou||(ou={}));function Kp(e,t,n){n===void 0&&(n="/");let r=typeof t=="string"?Nn(t):t,i=Kd(r.pathname||"/",n);if(i==null)return null;let s=Hd(e);Qp(s);let o=null;for(let l=0;o==null&&l<s.length;++l){let a=sm(i);o=nm(s[l],a)}return o}function Hd(e,t,n,r){t===void 0&&(t=[]),n===void 0&&(n=[]),r===void 0&&(r="");let i=(s,o,l)=>{let a={relativePath:l===void 0?s.path||"":l,caseSensitive:s.caseSensitive===!0,childrenIndex:o,route:s};a.relativePath.startsWith("/")&&(Z(a.relativePath.startsWith(r),'Absolute route path "'+a.relativePath+'" nested under path '+('"'+r+'" is not valid. An absolute child route path ')+"must start with the combined path of all its parent routes."),a.relativePath=a.relativePath.slice(r.length));let u=Bt([r,a.relativePath]),c=n.concat(a);s.children&&s.children.length>0&&(Z(s.index!==!0,"Index routes must not have child routes. Please remove "+('all child routes from route path "'+u+'".')),Hd(s.children,t,c,u)),!(s.path==null&&!s.index)&&t.push({path:u,score:em(u,s.index),routesMeta:c})};return e.forEach((s,o)=>{var l;if(s.path===""||!((l=s.path)!=null&&l.includes("?")))i(s,o);else for(let a of Wd(s.path))i(s,o,a)}),t}function Wd(e){let t=e.split("/");if(t.length===0)return[];let[n,...r]=t,i=n.endsWith("?"),s=n.replace(/\?$/,"");if(r.length===0)return i?[s,""]:[s];let o=Wd(r.join("/")),l=[];return l.push(...o.map(a=>a===""?s:[s,a].join("/"))),i&&l.push(...o),l.map(a=>e.startsWith("/")&&a===""?"/":a)}function Qp(e){e.sort((t,n)=>t.score!==n.score?n.score-t.score:tm(t.routesMeta.map(r=>r.childrenIndex),n.routesMeta.map(r=>r.childrenIndex)))}const Gp=/^:[\w-]+$/,Jp=3,qp=2,Yp=1,Xp=10,Zp=-2,lu=e=>e==="*";function em(e,t){let n=e.split("/"),r=n.length;return n.some(lu)&&(r+=Zp),t&&(r+=qp),n.filter(i=>!lu(i)).reduce((i,s)=>i+(Gp.test(s)?Jp:s===""?Yp:Xp),r)}function tm(e,t){return e.length===t.length&&e.slice(0,-1).every((r,i)=>r===t[i])?e[e.length-1]-t[t.length-1]:0}function nm(e,t){let{routesMeta:n}=e,r={},i="/",s=[];for(let o=0;o<n.length;++o){let l=n[o],a=o===n.length-1,u=i==="/"?t:t.slice(i.length)||"/",c=rm({path:l.relativePath,caseSensitive:l.caseSensitive,end:a},u);if(!c)return null;Object.assign(r,c.params);let d=l.route;s.push({params:r,pathname:Bt([i,c.pathname]),pathnameBase:dm(Bt([i,c.pathnameBase])),route:d}),c.pathnameBase!=="/"&&(i=Bt([i,c.pathnameBase]))}return s}function rm(e,t){typeof e=="string"&&(e={path:e,caseSensitive:!1,end:!0});let[n,r]=im(e.path,e.caseSensitive,e.end),i=t.match(n);if(!i)return null;let s=i[0],o=s.replace(/(.)\/+$/,"$1"),l=i.slice(1);return{params:r.reduce((u,c,d)=>{let{paramName:f,isOptional:v}=c;if(f==="*"){let y=l[d]||"";o=s.slice(0,s.length-y.length).replace(/(.)\/+$/,"$1")}const g=l[d];return v&&!g?u[f]=void 0:u[f]=(g||"").replace(/%2F/g,"/"),u},{}),pathname:s,pathnameBase:o,pattern:e}}function im(e,t,n){t===void 0&&(t=!1),n===void 0&&(n=!0),Bd(e==="*"||!e.endsWith("*")||e.endsWith("/*"),'Route path "'+e+'" will be treated as if it were '+('"'+e.replace(/\*$/,"/*")+'" because the `*` character must ')+"always follow a `/` in the pattern. To get rid of this warning, "+('please change the route path to "'+e.replace(/\*$/,"/*")+'".'));let r=[],i="^"+e.replace(/\/*\*?$/,"").replace(/^\/*/,"/").replace(/[\\.*+^${}|()[\]]/g,"\\$&").replace(/\/:([\w-]+)(\?)?/g,(o,l,a)=>(r.push({paramName:l,isOptional:a!=null}),a?"/?([^\\/]+)?":"/([^\\/]+)"));return e.endsWith("*")?(r.push({paramName:"*"}),i+=e==="*"||e==="/*"?"(.*)$":"(?:\\/(.+)|\\/*)$"):n?i+="\\/*$":e!==""&&e!=="/"&&(i+="(?:(?=\\/|$))"),[new RegExp(i,t?void 0:"i"),r]}function sm(e){try{return e.split("/").map(t=>decodeURIComponent(t).replace(/\//g,"%2F")).join("/")}catch(t){return Bd(!1,'The URL path "'+e+'" could not be decoded because it is is a malformed URL segment. This is probably due to a bad percent '+("encoding ("+t+").")),e}}function Kd(e,t){if(t==="/")return e;if(!e.toLowerCase().startsWith(t.toLowerCase()))return null;let n=t.endsWith("/")?t.length-1:t.length,r=e.charAt(n);return r&&r!=="/"?null:e.slice(n)||"/"}function om(e,t){t===void 0&&(t="/");let{pathname:n,search:r="",hash:i=""}=typeof e=="string"?Nn(e):e;return{pathname:n?n.startsWith("/")?n:lm(n,t):t,search:hm(r),hash:fm(i)}}function lm(e,t){let n=t.replace(/\/+$/,"").split("/");return e.split("/").forEach(i=>{i===".."?n.length>1&&n.pop():i!=="."&&n.push(i)}),n.length>1?n.join("/"):"/"}function zs(e,t,n,r){return"Cannot include a '"+e+"' character in a manually specified "+("`to."+t+"` field ["+JSON.stringify(r)+"]. Please separate it out to the ")+("`to."+n+"` field. Alternatively you may provide the full path as ")+'a string in <Link to="..."> and the router will parse it for you.'}function am(e){return e.filter((t,n)=>n===0||t.route.path&&t.route.path.length>0)}function um(e,t){let n=am(e);return t?n.map((r,i)=>i===e.length-1?r.pathname:r.pathnameBase):n.map(r=>r.pathnameBase)}function cm(e,t,n,r){r===void 0&&(r=!1);let i;typeof e=="string"?i=Nn(e):(i=Tr({},e),Z(!i.pathname||!i.pathname.includes("?"),zs("?","pathname","search",i)),Z(!i.pathname||!i.pathname.includes("#"),zs("#","pathname","hash",i)),Z(!i.search||!i.search.includes("#"),zs("#","search","hash",i)));let s=e===""||i.pathname==="",o=s?"/":i.pathname,l;if(o==null)l=n;else{let d=t.length-1;if(!r&&o.startsWith("..")){let f=o.split("/");for(;f[0]==="..";)f.shift(),d-=1;i.pathname=f.join("/")}l=d>=0?t[d]:"/"}let a=om(i,l),u=o&&o!=="/"&&o.endsWith("/"),c=(s||o===".")&&n.endsWith("/");return!a.pathname.endsWith("/")&&(u||c)&&(a.pathname+="/"),a}const Bt=e=>e.join("/").replace(/\/\/+/g,"/"),dm=e=>e.replace(/\/+$/,"").replace(/^\/*/,"/"),hm=e=>!e||e==="?"?"":e.startsWith("?")?e:"?"+e,fm=e=>!e||e==="#"?"":e.startsWith("#")?e:"#"+e;function pm(e){return e!=null&&typeof e.status=="number"&&typeof e.statusText=="string"&&typeof e.internal=="boolean"&&"data"in e}const Qd=["post","put","patch","delete"];new Set(Qd);const mm=["get",...Qd];new Set(mm);/** - * React Router v6.23.1 - * - * Copyright (c) Remix Software Inc. - * - * This source code is licensed under the MIT license found in the - * LICENSE.md file in the root directory of this source tree. - * - * @license MIT - */function Or(){return Or=Object.assign?Object.assign.bind():function(e){for(var t=1;t<arguments.length;t++){var n=arguments[t];for(var r in n)Object.prototype.hasOwnProperty.call(n,r)&&(e[r]=n[r])}return e},Or.apply(this,arguments)}const bl=x.createContext(null),vm=x.createContext(null),is=x.createContext(null),ss=x.createContext(null),An=x.createContext({outlet:null,matches:[],isDataRoute:!1}),Gd=x.createContext(null);function os(){return x.useContext(ss)!=null}function Jd(){return os()||Z(!1),x.useContext(ss).location}function qd(e){x.useContext(is).static||x.useLayoutEffect(e)}function Yd(){let{isDataRoute:e}=x.useContext(An);return e?Rm():gm()}function gm(){os()||Z(!1);let e=x.useContext(bl),{basename:t,future:n,navigator:r}=x.useContext(is),{matches:i}=x.useContext(An),{pathname:s}=Jd(),o=JSON.stringify(um(i,n.v7_relativeSplatPath)),l=x.useRef(!1);return qd(()=>{l.current=!0}),x.useCallback(function(u,c){if(c===void 0&&(c={}),!l.current)return;if(typeof u=="number"){r.go(u);return}let d=cm(u,JSON.parse(o),s,c.relative==="path");e==null&&t!=="/"&&(d.pathname=d.pathname==="/"?t:Bt([t,d.pathname])),(c.replace?r.replace:r.push)(d,c.state,c)},[t,r,o,s,e])}function ym(e,t){return wm(e,t)}function wm(e,t,n,r){os()||Z(!1);let{navigator:i}=x.useContext(is),{matches:s}=x.useContext(An),o=s[s.length-1],l=o?o.params:{};o&&o.pathname;let a=o?o.pathnameBase:"/";o&&o.route;let u=Jd(),c;if(t){var d;let _=typeof t=="string"?Nn(t):t;a==="/"||(d=_.pathname)!=null&&d.startsWith(a)||Z(!1),c=_}else c=u;let f=c.pathname||"/",v=f;if(a!=="/"){let _=a.replace(/^\//,"").split("/");v="/"+f.replace(/^\//,"").split("/").slice(_.length).join("/")}let g=Kp(e,{pathname:v}),y=Cm(g&&g.map(_=>Object.assign({},_,{params:Object.assign({},l,_.params),pathname:Bt([a,i.encodeLocation?i.encodeLocation(_.pathname).pathname:_.pathname]),pathnameBase:_.pathnameBase==="/"?a:Bt([a,i.encodeLocation?i.encodeLocation(_.pathnameBase).pathname:_.pathnameBase])})),s,n,r);return t&&y?x.createElement(ss.Provider,{value:{location:Or({pathname:"/",search:"",hash:"",state:null,key:"default"},c),navigationType:mt.Pop}},y):y}function _m(){let e=Om(),t=pm(e)?e.status+" "+e.statusText:e instanceof Error?e.message:JSON.stringify(e),n=e instanceof Error?e.stack:null,i={padding:"0.5rem",backgroundColor:"rgba(200,200,200, 0.5)"};return x.createElement(x.Fragment,null,x.createElement("h2",null,"Unexpected Application Error!"),x.createElement("h3",{style:{fontStyle:"italic"}},t),n?x.createElement("pre",{style:i},n):null,null)}const km=x.createElement(_m,null);class Sm extends x.Component{constructor(t){super(t),this.state={location:t.location,revalidation:t.revalidation,error:t.error}}static getDerivedStateFromError(t){return{error:t}}static getDerivedStateFromProps(t,n){return n.location!==t.location||n.revalidation!=="idle"&&t.revalidation==="idle"?{error:t.error,location:t.location,revalidation:t.revalidation}:{error:t.error!==void 0?t.error:n.error,location:n.location,revalidation:t.revalidation||n.revalidation}}componentDidCatch(t,n){console.error("React Router caught the following error during render",t,n)}render(){return this.state.error!==void 0?x.createElement(An.Provider,{value:this.props.routeContext},x.createElement(Gd.Provider,{value:this.state.error,children:this.props.component})):this.props.children}}function Em(e){let{routeContext:t,match:n,children:r}=e,i=x.useContext(bl);return i&&i.static&&i.staticContext&&(n.route.errorElement||n.route.ErrorBoundary)&&(i.staticContext._deepestRenderedBoundaryId=n.route.id),x.createElement(An.Provider,{value:t},r)}function Cm(e,t,n,r){var i;if(t===void 0&&(t=[]),n===void 0&&(n=null),r===void 0&&(r=null),e==null){var s;if((s=n)!=null&&s.errors)e=n.matches;else return null}let o=e,l=(i=n)==null?void 0:i.errors;if(l!=null){let c=o.findIndex(d=>d.route.id&&(l==null?void 0:l[d.route.id])!==void 0);c>=0||Z(!1),o=o.slice(0,Math.min(o.length,c+1))}let a=!1,u=-1;if(n&&r&&r.v7_partialHydration)for(let c=0;c<o.length;c++){let d=o[c];if((d.route.HydrateFallback||d.route.hydrateFallbackElement)&&(u=c),d.route.id){let{loaderData:f,errors:v}=n,g=d.route.loader&&f[d.route.id]===void 0&&(!v||v[d.route.id]===void 0);if(d.route.lazy||g){a=!0,u>=0?o=o.slice(0,u+1):o=[o[0]];break}}}return o.reduceRight((c,d,f)=>{let v,g=!1,y=null,_=null;n&&(v=l&&d.route.id?l[d.route.id]:void 0,y=d.route.errorElement||km,a&&(u<0&&f===0?(g=!0,_=null):u===f&&(g=!0,_=d.route.hydrateFallbackElement||null)));let p=t.concat(o.slice(0,f+1)),h=()=>{let m;return v?m=y:g?m=_:d.route.Component?m=x.createElement(d.route.Component,null):d.route.element?m=d.route.element:m=c,x.createElement(Em,{match:d,routeContext:{outlet:c,matches:p,isDataRoute:n!=null},children:m})};return n&&(d.route.ErrorBoundary||d.route.errorElement||f===0)?x.createElement(Sm,{location:n.location,revalidation:n.revalidation,component:y,error:v,children:h(),routeContext:{outlet:null,matches:p,isDataRoute:!0}}):h()},null)}var Xd=function(e){return e.UseBlocker="useBlocker",e.UseRevalidator="useRevalidator",e.UseNavigateStable="useNavigate",e}(Xd||{}),bi=function(e){return e.UseBlocker="useBlocker",e.UseLoaderData="useLoaderData",e.UseActionData="useActionData",e.UseRouteError="useRouteError",e.UseNavigation="useNavigation",e.UseRouteLoaderData="useRouteLoaderData",e.UseMatches="useMatches",e.UseRevalidator="useRevalidator",e.UseNavigateStable="useNavigate",e.UseRouteId="useRouteId",e}(bi||{});function xm(e){let t=x.useContext(bl);return t||Z(!1),t}function Pm(e){let t=x.useContext(vm);return t||Z(!1),t}function Tm(e){let t=x.useContext(An);return t||Z(!1),t}function Zd(e){let t=Tm(),n=t.matches[t.matches.length-1];return n.route.id||Z(!1),n.route.id}function Om(){var e;let t=x.useContext(Gd),n=Pm(bi.UseRouteError),r=Zd(bi.UseRouteError);return t!==void 0?t:(e=n.errors)==null?void 0:e[r]}function Rm(){let{router:e}=xm(Xd.UseNavigateStable),t=Zd(bi.UseNavigateStable),n=x.useRef(!1);return qd(()=>{n.current=!0}),x.useCallback(function(i,s){s===void 0&&(s={}),n.current&&(typeof i=="number"?e.navigate(i):e.navigate(i,Or({fromRouteId:t},s)))},[e,t])}function vi(e){Z(!1)}function jm(e){let{basename:t="/",children:n=null,location:r,navigationType:i=mt.Pop,navigator:s,static:o=!1,future:l}=e;os()&&Z(!1);let a=t.replace(/^\/*/,"/"),u=x.useMemo(()=>({basename:a,navigator:s,static:o,future:Or({v7_relativeSplatPath:!1},l)}),[a,l,s,o]);typeof r=="string"&&(r=Nn(r));let{pathname:c="/",search:d="",hash:f="",state:v=null,key:g="default"}=r,y=x.useMemo(()=>{let _=Kd(c,a);return _==null?null:{location:{pathname:_,search:d,hash:f,state:v,key:g},navigationType:i}},[a,c,d,f,v,g,i]);return y==null?null:x.createElement(is.Provider,{value:u},x.createElement(ss.Provider,{children:n,value:y}))}function Lm(e){let{children:t,location:n}=e;return ym(Mo(t),n)}new Promise(()=>{});function Mo(e,t){t===void 0&&(t=[]);let n=[];return x.Children.forEach(e,(r,i)=>{if(!x.isValidElement(r))return;let s=[...t,i];if(r.type===x.Fragment){n.push.apply(n,Mo(r.props.children,s));return}r.type!==vi&&Z(!1),!r.props.index||!r.props.children||Z(!1);let o={id:r.props.id||s.join("-"),caseSensitive:r.props.caseSensitive,element:r.props.element,Component:r.props.Component,index:r.props.index,path:r.props.path,loader:r.props.loader,action:r.props.action,errorElement:r.props.errorElement,ErrorBoundary:r.props.ErrorBoundary,hasErrorBoundary:r.props.ErrorBoundary!=null||r.props.errorElement!=null,shouldRevalidate:r.props.shouldRevalidate,handle:r.props.handle,lazy:r.props.lazy};r.props.children&&(o.children=Mo(r.props.children,s)),n.push(o)}),n}/** - * React Router DOM v6.23.1 - * - * Copyright (c) Remix Software Inc. - * - * This source code is licensed under the MIT license found in the - * LICENSE.md file in the root directory of this source tree. - * - * @license MIT - */const Im="6";try{window.__reactRouterVersion=Im}catch{}const $m="startTransition",au=jh[$m];function Nm(e){let{basename:t,children:n,future:r,window:i}=e,s=x.useRef();s.current==null&&(s.current=Vp({window:i,v5Compat:!0}));let o=s.current,[l,a]=x.useState({action:o.action,location:o.location}),{v7_startTransition:u}=r||{},c=x.useCallback(d=>{u&&au?au(()=>a(d)):a(d)},[a,u]);return x.useLayoutEffect(()=>o.listen(c),[o,c]),x.createElement(jm,{basename:t,children:n,location:l.location,navigationType:l.action,navigator:o,future:r})}var uu;(function(e){e.UseScrollRestoration="useScrollRestoration",e.UseSubmit="useSubmit",e.UseSubmitFetcher="useSubmitFetcher",e.UseFetcher="useFetcher",e.useViewTransitionState="useViewTransitionState"})(uu||(uu={}));var cu;(function(e){e.UseFetcher="useFetcher",e.UseFetchers="useFetchers",e.UseScrollRestoration="useScrollRestoration"})(cu||(cu={}));const Am="modulepreload",Um=function(e,t){return new URL(e,t).href},du={},Rn=function(t,n,r){let i=Promise.resolve();if(n&&n.length>0){const s=document.getElementsByTagName("link"),o=document.querySelector("meta[property=csp-nonce]"),l=(o==null?void 0:o.nonce)||(o==null?void 0:o.getAttribute("nonce"));i=Promise.all(n.map(a=>{if(a=Um(a,r),a in du)return;du[a]=!0;const u=a.endsWith(".css"),c=u?'[rel="stylesheet"]':"";if(!!r)for(let v=s.length-1;v>=0;v--){const g=s[v];if(g.href===a&&(!u||g.rel==="stylesheet"))return}else if(document.querySelector(`link[href="${a}"]${c}`))return;const f=document.createElement("link");if(f.rel=u?"stylesheet":Am,u||(f.as="script",f.crossOrigin=""),f.href=a,l&&f.setAttribute("nonce",l),document.head.appendChild(f),u)return new Promise((v,g)=>{f.addEventListener("load",v),f.addEventListener("error",()=>g(new Error(`Unable to preload CSS for ${a}`)))})}))}return i.then(()=>t()).catch(s=>{const o=new Event("vite:preloadError",{cancelable:!0});if(o.payload=s,window.dispatchEvent(o),!o.defaultPrevented)throw s})},Dm=e=>{let t;return e?t=e:typeof fetch>"u"?t=(...n)=>Rn(()=>Promise.resolve().then(()=>Ar),void 0,import.meta.url).then(({default:r})=>r(...n)):t=fetch,(...n)=>t(...n)};class Bl extends Error{constructor(t,n="FunctionsError",r){super(t),this.name=n,this.context=r}}class zm extends Bl{constructor(t){super("Failed to send a request to the Edge Function","FunctionsFetchError",t)}}class Fm extends Bl{constructor(t){super("Relay Error invoking the Edge Function","FunctionsRelayError",t)}}class Mm extends Bl{constructor(t){super("Edge Function returned a non-2xx status code","FunctionsHttpError",t)}}var bo;(function(e){e.Any="any",e.ApNortheast1="ap-northeast-1",e.ApNortheast2="ap-northeast-2",e.ApSouth1="ap-south-1",e.ApSoutheast1="ap-southeast-1",e.ApSoutheast2="ap-southeast-2",e.CaCentral1="ca-central-1",e.EuCentral1="eu-central-1",e.EuWest1="eu-west-1",e.EuWest2="eu-west-2",e.EuWest3="eu-west-3",e.SaEast1="sa-east-1",e.UsEast1="us-east-1",e.UsWest1="us-west-1",e.UsWest2="us-west-2"})(bo||(bo={}));var bm=function(e,t,n,r){function i(s){return s instanceof n?s:new n(function(o){o(s)})}return new(n||(n=Promise))(function(s,o){function l(c){try{u(r.next(c))}catch(d){o(d)}}function a(c){try{u(r.throw(c))}catch(d){o(d)}}function u(c){c.done?s(c.value):i(c.value).then(l,a)}u((r=r.apply(e,t||[])).next())})};class Bm{constructor(t,{headers:n={},customFetch:r,region:i=bo.Any}={}){this.url=t,this.headers=n,this.region=i,this.fetch=Dm(r)}setAuth(t){this.headers.Authorization=`Bearer ${t}`}invoke(t,n={}){var r;return bm(this,void 0,void 0,function*(){try{const{headers:i,method:s,body:o}=n;let l={},{region:a}=n;a||(a=this.region),a&&a!=="any"&&(l["x-region"]=a);let u;o&&(i&&!Object.prototype.hasOwnProperty.call(i,"Content-Type")||!i)&&(typeof Blob<"u"&&o instanceof Blob||o instanceof ArrayBuffer?(l["Content-Type"]="application/octet-stream",u=o):typeof o=="string"?(l["Content-Type"]="text/plain",u=o):typeof FormData<"u"&&o instanceof FormData?u=o:(l["Content-Type"]="application/json",u=JSON.stringify(o)));const c=yield this.fetch(`${this.url}/${t}`,{method:s||"POST",headers:Object.assign(Object.assign(Object.assign({},l),this.headers),i),body:u}).catch(g=>{throw new zm(g)}),d=c.headers.get("x-relay-error");if(d&&d==="true")throw new Fm(c);if(!c.ok)throw new Mm(c);let f=((r=c.headers.get("Content-Type"))!==null&&r!==void 0?r:"text/plain").split(";")[0].trim(),v;return f==="application/json"?v=yield c.json():f==="application/octet-stream"?v=yield c.blob():f==="text/event-stream"?v=c:f==="multipart/form-data"?v=yield c.formData():v=yield c.text(),{data:v,error:null}}catch(i){return{data:null,error:i}}})}}var Vm=function(){if(typeof self<"u")return self;if(typeof window<"u")return window;if(typeof global<"u")return global;throw new Error("unable to locate global object")},jn=Vm();const Hm=jn.fetch,Vl=jn.fetch.bind(jn),eh=jn.Headers,Wm=jn.Request,Km=jn.Response,Ar=Object.freeze(Object.defineProperty({__proto__:null,Headers:eh,Request:Wm,Response:Km,default:Vl,fetch:Hm},Symbol.toStringTag,{value:"Module"}));class Qm extends Error{constructor(t){super(t.message),this.name="PostgrestError",this.details=t.details,this.hint=t.hint,this.code=t.code}}class Gm{constructor(t){this.shouldThrowOnError=!1,this.method=t.method,this.url=t.url,this.headers=t.headers,this.schema=t.schema,this.body=t.body,this.shouldThrowOnError=t.shouldThrowOnError,this.signal=t.signal,this.isMaybeSingle=t.isMaybeSingle,t.fetch?this.fetch=t.fetch:typeof fetch>"u"?this.fetch=Vl:this.fetch=fetch}throwOnError(){return this.shouldThrowOnError=!0,this}then(t,n){this.schema===void 0||(["GET","HEAD"].includes(this.method)?this.headers["Accept-Profile"]=this.schema:this.headers["Content-Profile"]=this.schema),this.method!=="GET"&&this.method!=="HEAD"&&(this.headers["Content-Type"]="application/json");const r=this.fetch;let i=r(this.url.toString(),{method:this.method,headers:this.headers,body:JSON.stringify(this.body),signal:this.signal}).then(async s=>{var o,l,a;let u=null,c=null,d=null,f=s.status,v=s.statusText;if(s.ok){if(this.method!=="HEAD"){const p=await s.text();p===""||(this.headers.Accept==="text/csv"||this.headers.Accept&&this.headers.Accept.includes("application/vnd.pgrst.plan+text")?c=p:c=JSON.parse(p))}const y=(o=this.headers.Prefer)===null||o===void 0?void 0:o.match(/count=(exact|planned|estimated)/),_=(l=s.headers.get("content-range"))===null||l===void 0?void 0:l.split("/");y&&_&&_.length>1&&(d=parseInt(_[1])),this.isMaybeSingle&&this.method==="GET"&&Array.isArray(c)&&(c.length>1?(u={code:"PGRST116",details:`Results contain ${c.length} rows, application/vnd.pgrst.object+json requires 1 row`,hint:null,message:"JSON object requested, multiple (or no) rows returned"},c=null,d=null,f=406,v="Not Acceptable"):c.length===1?c=c[0]:c=null)}else{const y=await s.text();try{u=JSON.parse(y),Array.isArray(u)&&s.status===404&&(c=[],u=null,f=200,v="OK")}catch{s.status===404&&y===""?(f=204,v="No Content"):u={message:y}}if(u&&this.isMaybeSingle&&(!((a=u==null?void 0:u.details)===null||a===void 0)&&a.includes("0 rows"))&&(u=null,f=200,v="OK"),u&&this.shouldThrowOnError)throw new Qm(u)}return{error:u,data:c,count:d,status:f,statusText:v}});return this.shouldThrowOnError||(i=i.catch(s=>{var o,l,a;return{error:{message:`${(o=s==null?void 0:s.name)!==null&&o!==void 0?o:"FetchError"}: ${s==null?void 0:s.message}`,details:`${(l=s==null?void 0:s.stack)!==null&&l!==void 0?l:""}`,hint:"",code:`${(a=s==null?void 0:s.code)!==null&&a!==void 0?a:""}`},data:null,count:null,status:0,statusText:""}})),i.then(t,n)}}class Jm extends Gm{select(t){let n=!1;const r=(t??"*").split("").map(i=>/\s/.test(i)&&!n?"":(i==='"'&&(n=!n),i)).join("");return this.url.searchParams.set("select",r),this.headers.Prefer&&(this.headers.Prefer+=","),this.headers.Prefer+="return=representation",this}order(t,{ascending:n=!0,nullsFirst:r,foreignTable:i,referencedTable:s=i}={}){const o=s?`${s}.order`:"order",l=this.url.searchParams.get(o);return this.url.searchParams.set(o,`${l?`${l},`:""}${t}.${n?"asc":"desc"}${r===void 0?"":r?".nullsfirst":".nullslast"}`),this}limit(t,{foreignTable:n,referencedTable:r=n}={}){const i=typeof r>"u"?"limit":`${r}.limit`;return this.url.searchParams.set(i,`${t}`),this}range(t,n,{foreignTable:r,referencedTable:i=r}={}){const s=typeof i>"u"?"offset":`${i}.offset`,o=typeof i>"u"?"limit":`${i}.limit`;return this.url.searchParams.set(s,`${t}`),this.url.searchParams.set(o,`${n-t+1}`),this}abortSignal(t){return this.signal=t,this}single(){return this.headers.Accept="application/vnd.pgrst.object+json",this}maybeSingle(){return this.method==="GET"?this.headers.Accept="application/json":this.headers.Accept="application/vnd.pgrst.object+json",this.isMaybeSingle=!0,this}csv(){return this.headers.Accept="text/csv",this}geojson(){return this.headers.Accept="application/geo+json",this}explain({analyze:t=!1,verbose:n=!1,settings:r=!1,buffers:i=!1,wal:s=!1,format:o="text"}={}){var l;const a=[t?"analyze":null,n?"verbose":null,r?"settings":null,i?"buffers":null,s?"wal":null].filter(Boolean).join("|"),u=(l=this.headers.Accept)!==null&&l!==void 0?l:"application/json";return this.headers.Accept=`application/vnd.pgrst.plan+${o}; for="${u}"; options=${a};`,o==="json"?this:this}rollback(){var t;return((t=this.headers.Prefer)!==null&&t!==void 0?t:"").trim().length>0?this.headers.Prefer+=",tx=rollback":this.headers.Prefer="tx=rollback",this}returns(){return this}}class tn extends Jm{eq(t,n){return this.url.searchParams.append(t,`eq.${n}`),this}neq(t,n){return this.url.searchParams.append(t,`neq.${n}`),this}gt(t,n){return this.url.searchParams.append(t,`gt.${n}`),this}gte(t,n){return this.url.searchParams.append(t,`gte.${n}`),this}lt(t,n){return this.url.searchParams.append(t,`lt.${n}`),this}lte(t,n){return this.url.searchParams.append(t,`lte.${n}`),this}like(t,n){return this.url.searchParams.append(t,`like.${n}`),this}likeAllOf(t,n){return this.url.searchParams.append(t,`like(all).{${n.join(",")}}`),this}likeAnyOf(t,n){return this.url.searchParams.append(t,`like(any).{${n.join(",")}}`),this}ilike(t,n){return this.url.searchParams.append(t,`ilike.${n}`),this}ilikeAllOf(t,n){return this.url.searchParams.append(t,`ilike(all).{${n.join(",")}}`),this}ilikeAnyOf(t,n){return this.url.searchParams.append(t,`ilike(any).{${n.join(",")}}`),this}is(t,n){return this.url.searchParams.append(t,`is.${n}`),this}in(t,n){const r=Array.from(new Set(n)).map(i=>typeof i=="string"&&new RegExp("[,()]").test(i)?`"${i}"`:`${i}`).join(",");return this.url.searchParams.append(t,`in.(${r})`),this}contains(t,n){return typeof n=="string"?this.url.searchParams.append(t,`cs.${n}`):Array.isArray(n)?this.url.searchParams.append(t,`cs.{${n.join(",")}}`):this.url.searchParams.append(t,`cs.${JSON.stringify(n)}`),this}containedBy(t,n){return typeof n=="string"?this.url.searchParams.append(t,`cd.${n}`):Array.isArray(n)?this.url.searchParams.append(t,`cd.{${n.join(",")}}`):this.url.searchParams.append(t,`cd.${JSON.stringify(n)}`),this}rangeGt(t,n){return this.url.searchParams.append(t,`sr.${n}`),this}rangeGte(t,n){return this.url.searchParams.append(t,`nxl.${n}`),this}rangeLt(t,n){return this.url.searchParams.append(t,`sl.${n}`),this}rangeLte(t,n){return this.url.searchParams.append(t,`nxr.${n}`),this}rangeAdjacent(t,n){return this.url.searchParams.append(t,`adj.${n}`),this}overlaps(t,n){return typeof n=="string"?this.url.searchParams.append(t,`ov.${n}`):this.url.searchParams.append(t,`ov.{${n.join(",")}}`),this}textSearch(t,n,{config:r,type:i}={}){let s="";i==="plain"?s="pl":i==="phrase"?s="ph":i==="websearch"&&(s="w");const o=r===void 0?"":`(${r})`;return this.url.searchParams.append(t,`${s}fts${o}.${n}`),this}match(t){return Object.entries(t).forEach(([n,r])=>{this.url.searchParams.append(n,`eq.${r}`)}),this}not(t,n,r){return this.url.searchParams.append(t,`not.${n}.${r}`),this}or(t,{foreignTable:n,referencedTable:r=n}={}){const i=r?`${r}.or`:"or";return this.url.searchParams.append(i,`(${t})`),this}filter(t,n,r){return this.url.searchParams.append(t,`${n}.${r}`),this}}class qm{constructor(t,{headers:n={},schema:r,fetch:i}){this.url=t,this.headers=n,this.schema=r,this.fetch=i}select(t,{head:n=!1,count:r}={}){const i=n?"HEAD":"GET";let s=!1;const o=(t??"*").split("").map(l=>/\s/.test(l)&&!s?"":(l==='"'&&(s=!s),l)).join("");return this.url.searchParams.set("select",o),r&&(this.headers.Prefer=`count=${r}`),new tn({method:i,url:this.url,headers:this.headers,schema:this.schema,fetch:this.fetch,allowEmpty:!1})}insert(t,{count:n,defaultToNull:r=!0}={}){const i="POST",s=[];if(this.headers.Prefer&&s.push(this.headers.Prefer),n&&s.push(`count=${n}`),r||s.push("missing=default"),this.headers.Prefer=s.join(","),Array.isArray(t)){const o=t.reduce((l,a)=>l.concat(Object.keys(a)),[]);if(o.length>0){const l=[...new Set(o)].map(a=>`"${a}"`);this.url.searchParams.set("columns",l.join(","))}}return new tn({method:i,url:this.url,headers:this.headers,schema:this.schema,body:t,fetch:this.fetch,allowEmpty:!1})}upsert(t,{onConflict:n,ignoreDuplicates:r=!1,count:i,defaultToNull:s=!0}={}){const o="POST",l=[`resolution=${r?"ignore":"merge"}-duplicates`];if(n!==void 0&&this.url.searchParams.set("on_conflict",n),this.headers.Prefer&&l.push(this.headers.Prefer),i&&l.push(`count=${i}`),s||l.push("missing=default"),this.headers.Prefer=l.join(","),Array.isArray(t)){const a=t.reduce((u,c)=>u.concat(Object.keys(c)),[]);if(a.length>0){const u=[...new Set(a)].map(c=>`"${c}"`);this.url.searchParams.set("columns",u.join(","))}}return new tn({method:o,url:this.url,headers:this.headers,schema:this.schema,body:t,fetch:this.fetch,allowEmpty:!1})}update(t,{count:n}={}){const r="PATCH",i=[];return this.headers.Prefer&&i.push(this.headers.Prefer),n&&i.push(`count=${n}`),this.headers.Prefer=i.join(","),new tn({method:r,url:this.url,headers:this.headers,schema:this.schema,body:t,fetch:this.fetch,allowEmpty:!1})}delete({count:t}={}){const n="DELETE",r=[];return t&&r.push(`count=${t}`),this.headers.Prefer&&r.unshift(this.headers.Prefer),this.headers.Prefer=r.join(","),new tn({method:n,url:this.url,headers:this.headers,schema:this.schema,fetch:this.fetch,allowEmpty:!1})}}const Ym="1.15.2",Xm={"X-Client-Info":`postgrest-js/${Ym}`};class Hl{constructor(t,{headers:n={},schema:r,fetch:i}={}){this.url=t,this.headers=Object.assign(Object.assign({},Xm),n),this.schemaName=r,this.fetch=i}from(t){const n=new URL(`${this.url}/${t}`);return new qm(n,{headers:Object.assign({},this.headers),schema:this.schemaName,fetch:this.fetch})}schema(t){return new Hl(this.url,{headers:this.headers,schema:t,fetch:this.fetch})}rpc(t,n={},{head:r=!1,get:i=!1,count:s}={}){let o;const l=new URL(`${this.url}/rpc/${t}`);let a;r||i?(o=r?"HEAD":"GET",Object.entries(n).filter(([c,d])=>d!==void 0).map(([c,d])=>[c,Array.isArray(d)?`{${d.join(",")}}`:`${d}`]).forEach(([c,d])=>{l.searchParams.append(c,d)})):(o="POST",a=n);const u=Object.assign({},this.headers);return s&&(u.Prefer=`count=${s}`),new tn({method:o,url:l,headers:u,schema:this.schemaName,body:a,fetch:this.fetch,allowEmpty:!1})}}const Zm="2.9.5",ev={"X-Client-Info":`realtime-js/${Zm}`},tv="1.0.0",th=1e4,nv=1e3;var kn;(function(e){e[e.connecting=0]="connecting",e[e.open=1]="open",e[e.closing=2]="closing",e[e.closed=3]="closed"})(kn||(kn={}));var _e;(function(e){e.closed="closed",e.errored="errored",e.joined="joined",e.joining="joining",e.leaving="leaving"})(_e||(_e={}));var Fe;(function(e){e.close="phx_close",e.error="phx_error",e.join="phx_join",e.reply="phx_reply",e.leave="phx_leave",e.access_token="access_token"})(Fe||(Fe={}));var Bo;(function(e){e.websocket="websocket"})(Bo||(Bo={}));var Ut;(function(e){e.Connecting="connecting",e.Open="open",e.Closing="closing",e.Closed="closed"})(Ut||(Ut={}));class nh{constructor(t,n){this.callback=t,this.timerCalc=n,this.timer=void 0,this.tries=0,this.callback=t,this.timerCalc=n}reset(){this.tries=0,clearTimeout(this.timer)}scheduleTimeout(){clearTimeout(this.timer),this.timer=setTimeout(()=>{this.tries=this.tries+1,this.callback()},this.timerCalc(this.tries+1))}}class rv{constructor(){this.HEADER_LENGTH=1}decode(t,n){return t.constructor===ArrayBuffer?n(this._binaryDecode(t)):n(typeof t=="string"?JSON.parse(t):{})}_binaryDecode(t){const n=new DataView(t),r=new TextDecoder;return this._decodeBroadcast(t,n,r)}_decodeBroadcast(t,n,r){const i=n.getUint8(1),s=n.getUint8(2);let o=this.HEADER_LENGTH+2;const l=r.decode(t.slice(o,o+i));o=o+i;const a=r.decode(t.slice(o,o+s));o=o+s;const u=JSON.parse(r.decode(t.slice(o,t.byteLength)));return{ref:null,topic:l,event:a,payload:u}}}class Fs{constructor(t,n,r={},i=th){this.channel=t,this.event=n,this.payload=r,this.timeout=i,this.sent=!1,this.timeoutTimer=void 0,this.ref="",this.receivedResp=null,this.recHooks=[],this.refEvent=null}resend(t){this.timeout=t,this._cancelRefEvent(),this.ref="",this.refEvent=null,this.receivedResp=null,this.sent=!1,this.send()}send(){this._hasReceived("timeout")||(this.startTimeout(),this.sent=!0,this.channel.socket.push({topic:this.channel.topic,event:this.event,payload:this.payload,ref:this.ref,join_ref:this.channel._joinRef()}))}updatePayload(t){this.payload=Object.assign(Object.assign({},this.payload),t)}receive(t,n){var r;return this._hasReceived(t)&&n((r=this.receivedResp)===null||r===void 0?void 0:r.response),this.recHooks.push({status:t,callback:n}),this}startTimeout(){if(this.timeoutTimer)return;this.ref=this.channel.socket._makeRef(),this.refEvent=this.channel._replyEventName(this.ref);const t=n=>{this._cancelRefEvent(),this._cancelTimeout(),this.receivedResp=n,this._matchReceive(n)};this.channel._on(this.refEvent,{},t),this.timeoutTimer=setTimeout(()=>{this.trigger("timeout",{})},this.timeout)}trigger(t,n){this.refEvent&&this.channel._trigger(this.refEvent,{status:t,response:n})}destroy(){this._cancelRefEvent(),this._cancelTimeout()}_cancelRefEvent(){this.refEvent&&this.channel._off(this.refEvent,{})}_cancelTimeout(){clearTimeout(this.timeoutTimer),this.timeoutTimer=void 0}_matchReceive({status:t,response:n}){this.recHooks.filter(r=>r.status===t).forEach(r=>r.callback(n))}_hasReceived(t){return this.receivedResp&&this.receivedResp.status===t}}var hu;(function(e){e.SYNC="sync",e.JOIN="join",e.LEAVE="leave"})(hu||(hu={}));class ar{constructor(t,n){this.channel=t,this.state={},this.pendingDiffs=[],this.joinRef=null,this.caller={onJoin:()=>{},onLeave:()=>{},onSync:()=>{}};const r=(n==null?void 0:n.events)||{state:"presence_state",diff:"presence_diff"};this.channel._on(r.state,{},i=>{const{onJoin:s,onLeave:o,onSync:l}=this.caller;this.joinRef=this.channel._joinRef(),this.state=ar.syncState(this.state,i,s,o),this.pendingDiffs.forEach(a=>{this.state=ar.syncDiff(this.state,a,s,o)}),this.pendingDiffs=[],l()}),this.channel._on(r.diff,{},i=>{const{onJoin:s,onLeave:o,onSync:l}=this.caller;this.inPendingSyncState()?this.pendingDiffs.push(i):(this.state=ar.syncDiff(this.state,i,s,o),l())}),this.onJoin((i,s,o)=>{this.channel._trigger("presence",{event:"join",key:i,currentPresences:s,newPresences:o})}),this.onLeave((i,s,o)=>{this.channel._trigger("presence",{event:"leave",key:i,currentPresences:s,leftPresences:o})}),this.onSync(()=>{this.channel._trigger("presence",{event:"sync"})})}static syncState(t,n,r,i){const s=this.cloneDeep(t),o=this.transformState(n),l={},a={};return this.map(s,(u,c)=>{o[u]||(a[u]=c)}),this.map(o,(u,c)=>{const d=s[u];if(d){const f=c.map(_=>_.presence_ref),v=d.map(_=>_.presence_ref),g=c.filter(_=>v.indexOf(_.presence_ref)<0),y=d.filter(_=>f.indexOf(_.presence_ref)<0);g.length>0&&(l[u]=g),y.length>0&&(a[u]=y)}else l[u]=c}),this.syncDiff(s,{joins:l,leaves:a},r,i)}static syncDiff(t,n,r,i){const{joins:s,leaves:o}={joins:this.transformState(n.joins),leaves:this.transformState(n.leaves)};return r||(r=()=>{}),i||(i=()=>{}),this.map(s,(l,a)=>{var u;const c=(u=t[l])!==null&&u!==void 0?u:[];if(t[l]=this.cloneDeep(a),c.length>0){const d=t[l].map(v=>v.presence_ref),f=c.filter(v=>d.indexOf(v.presence_ref)<0);t[l].unshift(...f)}r(l,c,a)}),this.map(o,(l,a)=>{let u=t[l];if(!u)return;const c=a.map(d=>d.presence_ref);u=u.filter(d=>c.indexOf(d.presence_ref)<0),t[l]=u,i(l,u,a),u.length===0&&delete t[l]}),t}static map(t,n){return Object.getOwnPropertyNames(t).map(r=>n(r,t[r]))}static transformState(t){return t=this.cloneDeep(t),Object.getOwnPropertyNames(t).reduce((n,r)=>{const i=t[r];return"metas"in i?n[r]=i.metas.map(s=>(s.presence_ref=s.phx_ref,delete s.phx_ref,delete s.phx_ref_prev,s)):n[r]=i,n},{})}static cloneDeep(t){return JSON.parse(JSON.stringify(t))}onJoin(t){this.caller.onJoin=t}onLeave(t){this.caller.onLeave=t}onSync(t){this.caller.onSync=t}inPendingSyncState(){return!this.joinRef||this.joinRef!==this.channel._joinRef()}}var D;(function(e){e.abstime="abstime",e.bool="bool",e.date="date",e.daterange="daterange",e.float4="float4",e.float8="float8",e.int2="int2",e.int4="int4",e.int4range="int4range",e.int8="int8",e.int8range="int8range",e.json="json",e.jsonb="jsonb",e.money="money",e.numeric="numeric",e.oid="oid",e.reltime="reltime",e.text="text",e.time="time",e.timestamp="timestamp",e.timestamptz="timestamptz",e.timetz="timetz",e.tsrange="tsrange",e.tstzrange="tstzrange"})(D||(D={}));const fu=(e,t,n={})=>{var r;const i=(r=n.skipTypes)!==null&&r!==void 0?r:[];return Object.keys(t).reduce((s,o)=>(s[o]=iv(o,e,t,i),s),{})},iv=(e,t,n,r)=>{const i=t.find(l=>l.name===e),s=i==null?void 0:i.type,o=n[e];return s&&!r.includes(s)?rh(s,o):Vo(o)},rh=(e,t)=>{if(e.charAt(0)==="_"){const n=e.slice(1,e.length);return av(t,n)}switch(e){case D.bool:return sv(t);case D.float4:case D.float8:case D.int2:case D.int4:case D.int8:case D.numeric:case D.oid:return ov(t);case D.json:case D.jsonb:return lv(t);case D.timestamp:return uv(t);case D.abstime:case D.date:case D.daterange:case D.int4range:case D.int8range:case D.money:case D.reltime:case D.text:case D.time:case D.timestamptz:case D.timetz:case D.tsrange:case D.tstzrange:return Vo(t);default:return Vo(t)}},Vo=e=>e,sv=e=>{switch(e){case"t":return!0;case"f":return!1;default:return e}},ov=e=>{if(typeof e=="string"){const t=parseFloat(e);if(!Number.isNaN(t))return t}return e},lv=e=>{if(typeof e=="string")try{return JSON.parse(e)}catch(t){return console.log(`JSON parse error: ${t}`),e}return e},av=(e,t)=>{if(typeof e!="string")return e;const n=e.length-1,r=e[n];if(e[0]==="{"&&r==="}"){let s;const o=e.slice(1,n);try{s=JSON.parse("["+o+"]")}catch{s=o?o.split(","):[]}return s.map(l=>rh(t,l))}return e},uv=e=>typeof e=="string"?e.replace(" ","T"):e;var pu;(function(e){e.ALL="*",e.INSERT="INSERT",e.UPDATE="UPDATE",e.DELETE="DELETE"})(pu||(pu={}));var mu;(function(e){e.BROADCAST="broadcast",e.PRESENCE="presence",e.POSTGRES_CHANGES="postgres_changes"})(mu||(mu={}));var vu;(function(e){e.SUBSCRIBED="SUBSCRIBED",e.TIMED_OUT="TIMED_OUT",e.CLOSED="CLOSED",e.CHANNEL_ERROR="CHANNEL_ERROR"})(vu||(vu={}));class Wl{constructor(t,n={config:{}},r){this.topic=t,this.params=n,this.socket=r,this.bindings={},this.state=_e.closed,this.joinedOnce=!1,this.pushBuffer=[],this.subTopic=t.replace(/^realtime:/i,""),this.params.config=Object.assign({broadcast:{ack:!1,self:!1},presence:{key:""}},n.config),this.timeout=this.socket.timeout,this.joinPush=new Fs(this,Fe.join,this.params,this.timeout),this.rejoinTimer=new nh(()=>this._rejoinUntilConnected(),this.socket.reconnectAfterMs),this.joinPush.receive("ok",()=>{this.state=_e.joined,this.rejoinTimer.reset(),this.pushBuffer.forEach(i=>i.send()),this.pushBuffer=[]}),this._onClose(()=>{this.rejoinTimer.reset(),this.socket.log("channel",`close ${this.topic} ${this._joinRef()}`),this.state=_e.closed,this.socket._remove(this)}),this._onError(i=>{this._isLeaving()||this._isClosed()||(this.socket.log("channel",`error ${this.topic}`,i),this.state=_e.errored,this.rejoinTimer.scheduleTimeout())}),this.joinPush.receive("timeout",()=>{this._isJoining()&&(this.socket.log("channel",`timeout ${this.topic}`,this.joinPush.timeout),this.state=_e.errored,this.rejoinTimer.scheduleTimeout())}),this._on(Fe.reply,{},(i,s)=>{this._trigger(this._replyEventName(s),i)}),this.presence=new ar(this),this.broadcastEndpointURL=this._broadcastEndpointURL()}subscribe(t,n=this.timeout){var r,i;if(this.socket.isConnected()||this.socket.connect(),this.joinedOnce)throw"tried to subscribe multiple times. 'subscribe' can only be called a single time per channel instance";{const{config:{broadcast:s,presence:o}}=this.params;this._onError(u=>t&&t("CHANNEL_ERROR",u)),this._onClose(()=>t&&t("CLOSED"));const l={},a={broadcast:s,presence:o,postgres_changes:(i=(r=this.bindings.postgres_changes)===null||r===void 0?void 0:r.map(u=>u.filter))!==null&&i!==void 0?i:[]};this.socket.accessToken&&(l.access_token=this.socket.accessToken),this.updateJoinPayload(Object.assign({config:a},l)),this.joinedOnce=!0,this._rejoin(n),this.joinPush.receive("ok",({postgres_changes:u})=>{var c;if(this.socket.accessToken&&this.socket.setAuth(this.socket.accessToken),u===void 0){t&&t("SUBSCRIBED");return}else{const d=this.bindings.postgres_changes,f=(c=d==null?void 0:d.length)!==null&&c!==void 0?c:0,v=[];for(let g=0;g<f;g++){const y=d[g],{filter:{event:_,schema:p,table:h,filter:m}}=y,w=u&&u[g];if(w&&w.event===_&&w.schema===p&&w.table===h&&w.filter===m)v.push(Object.assign(Object.assign({},y),{id:w.id}));else{this.unsubscribe(),t&&t("CHANNEL_ERROR",new Error("mismatch between server and client bindings for postgres changes"));return}}this.bindings.postgres_changes=v,t&&t("SUBSCRIBED");return}}).receive("error",u=>{t&&t("CHANNEL_ERROR",new Error(JSON.stringify(Object.values(u).join(", ")||"error")))}).receive("timeout",()=>{t&&t("TIMED_OUT")})}return this}presenceState(){return this.presence.state}async track(t,n={}){return await this.send({type:"presence",event:"track",payload:t},n.timeout||this.timeout)}async untrack(t={}){return await this.send({type:"presence",event:"untrack"},t)}on(t,n,r){return this._on(t,n,r)}async send(t,n={}){var r,i;if(!this._canPush()&&t.type==="broadcast"){const{event:s,payload:o}=t,l={method:"POST",headers:{apikey:(r=this.socket.apiKey)!==null&&r!==void 0?r:"","Content-Type":"application/json"},body:JSON.stringify({messages:[{topic:this.subTopic,event:s,payload:o}]})};try{return(await this._fetchWithTimeout(this.broadcastEndpointURL,l,(i=n.timeout)!==null&&i!==void 0?i:this.timeout)).ok?"ok":"error"}catch(a){return a.name==="AbortError"?"timed out":"error"}}else return new Promise(s=>{var o,l,a;const u=this._push(t.type,t,n.timeout||this.timeout);t.type==="broadcast"&&!(!((a=(l=(o=this.params)===null||o===void 0?void 0:o.config)===null||l===void 0?void 0:l.broadcast)===null||a===void 0)&&a.ack)&&s("ok"),u.receive("ok",()=>s("ok")),u.receive("error",()=>s("error")),u.receive("timeout",()=>s("timed out"))})}updateJoinPayload(t){this.joinPush.updatePayload(t)}unsubscribe(t=this.timeout){this.state=_e.leaving;const n=()=>{this.socket.log("channel",`leave ${this.topic}`),this._trigger(Fe.close,"leave",this._joinRef())};return this.rejoinTimer.reset(),this.joinPush.destroy(),new Promise(r=>{const i=new Fs(this,Fe.leave,{},t);i.receive("ok",()=>{n(),r("ok")}).receive("timeout",()=>{n(),r("timed out")}).receive("error",()=>{r("error")}),i.send(),this._canPush()||i.trigger("ok",{})})}_broadcastEndpointURL(){let t=this.socket.endPoint;return t=t.replace(/^ws/i,"http"),t=t.replace(/(\/socket\/websocket|\/socket|\/websocket)\/?$/i,""),t.replace(/\/+$/,"")+"/api/broadcast"}async _fetchWithTimeout(t,n,r){const i=new AbortController,s=setTimeout(()=>i.abort(),r),o=await this.socket.fetch(t,Object.assign(Object.assign({},n),{signal:i.signal}));return clearTimeout(s),o}_push(t,n,r=this.timeout){if(!this.joinedOnce)throw`tried to push '${t}' to '${this.topic}' before joining. Use channel.subscribe() before pushing events`;let i=new Fs(this,t,n,r);return this._canPush()?i.send():(i.startTimeout(),this.pushBuffer.push(i)),i}_onMessage(t,n,r){return n}_isMember(t){return this.topic===t}_joinRef(){return this.joinPush.ref}_trigger(t,n,r){var i,s;const o=t.toLocaleLowerCase(),{close:l,error:a,leave:u,join:c}=Fe;if(r&&[l,a,u,c].indexOf(o)>=0&&r!==this._joinRef())return;let f=this._onMessage(o,n,r);if(n&&!f)throw"channel onMessage callbacks must return the payload, modified or unmodified";["insert","update","delete"].includes(o)?(i=this.bindings.postgres_changes)===null||i===void 0||i.filter(v=>{var g,y,_;return((g=v.filter)===null||g===void 0?void 0:g.event)==="*"||((_=(y=v.filter)===null||y===void 0?void 0:y.event)===null||_===void 0?void 0:_.toLocaleLowerCase())===o}).map(v=>v.callback(f,r)):(s=this.bindings[o])===null||s===void 0||s.filter(v=>{var g,y,_,p,h,m;if(["broadcast","presence","postgres_changes"].includes(o))if("id"in v){const w=v.id,S=(g=v.filter)===null||g===void 0?void 0:g.event;return w&&((y=n.ids)===null||y===void 0?void 0:y.includes(w))&&(S==="*"||(S==null?void 0:S.toLocaleLowerCase())===((_=n.data)===null||_===void 0?void 0:_.type.toLocaleLowerCase()))}else{const w=(h=(p=v==null?void 0:v.filter)===null||p===void 0?void 0:p.event)===null||h===void 0?void 0:h.toLocaleLowerCase();return w==="*"||w===((m=n==null?void 0:n.event)===null||m===void 0?void 0:m.toLocaleLowerCase())}else return v.type.toLocaleLowerCase()===o}).map(v=>{if(typeof f=="object"&&"ids"in f){const g=f.data,{schema:y,table:_,commit_timestamp:p,type:h,errors:m}=g;f=Object.assign(Object.assign({},{schema:y,table:_,commit_timestamp:p,eventType:h,new:{},old:{},errors:m}),this._getPayloadRecords(g))}v.callback(f,r)})}_isClosed(){return this.state===_e.closed}_isJoined(){return this.state===_e.joined}_isJoining(){return this.state===_e.joining}_isLeaving(){return this.state===_e.leaving}_replyEventName(t){return`chan_reply_${t}`}_on(t,n,r){const i=t.toLocaleLowerCase(),s={type:i,filter:n,callback:r};return this.bindings[i]?this.bindings[i].push(s):this.bindings[i]=[s],this}_off(t,n){const r=t.toLocaleLowerCase();return this.bindings[r]=this.bindings[r].filter(i=>{var s;return!(((s=i.type)===null||s===void 0?void 0:s.toLocaleLowerCase())===r&&Wl.isEqual(i.filter,n))}),this}static isEqual(t,n){if(Object.keys(t).length!==Object.keys(n).length)return!1;for(const r in t)if(t[r]!==n[r])return!1;return!0}_rejoinUntilConnected(){this.rejoinTimer.scheduleTimeout(),this.socket.isConnected()&&this._rejoin()}_onClose(t){this._on(Fe.close,{},t)}_onError(t){this._on(Fe.error,{},n=>t(n))}_canPush(){return this.socket.isConnected()&&this._isJoined()}_rejoin(t=this.timeout){this._isLeaving()||(this.socket._leaveOpenTopic(this.topic),this.state=_e.joining,this.joinPush.resend(t))}_getPayloadRecords(t){const n={new:{},old:{}};return(t.type==="INSERT"||t.type==="UPDATE")&&(n.new=fu(t.columns,t.record)),(t.type==="UPDATE"||t.type==="DELETE")&&(n.old=fu(t.columns,t.old_record)),n}}const cv=()=>{},dv=typeof WebSocket<"u";class hv{constructor(t,n){var r;this.accessToken=null,this.apiKey=null,this.channels=[],this.endPoint="",this.headers=ev,this.params={},this.timeout=th,this.heartbeatIntervalMs=3e4,this.heartbeatTimer=void 0,this.pendingHeartbeatRef=null,this.ref=0,this.logger=cv,this.conn=null,this.sendBuffer=[],this.serializer=new rv,this.stateChangeCallbacks={open:[],close:[],error:[],message:[]},this._resolveFetch=s=>{let o;return s?o=s:typeof fetch>"u"?o=(...l)=>Rn(()=>Promise.resolve().then(()=>Ar),void 0,import.meta.url).then(({default:a})=>a(...l)):o=fetch,(...l)=>o(...l)},this.endPoint=`${t}/${Bo.websocket}`,n!=null&&n.transport?this.transport=n.transport:this.transport=null,n!=null&&n.params&&(this.params=n.params),n!=null&&n.headers&&(this.headers=Object.assign(Object.assign({},this.headers),n.headers)),n!=null&&n.timeout&&(this.timeout=n.timeout),n!=null&&n.logger&&(this.logger=n.logger),n!=null&&n.heartbeatIntervalMs&&(this.heartbeatIntervalMs=n.heartbeatIntervalMs);const i=(r=n==null?void 0:n.params)===null||r===void 0?void 0:r.apikey;i&&(this.accessToken=i,this.apiKey=i),this.reconnectAfterMs=n!=null&&n.reconnectAfterMs?n.reconnectAfterMs:s=>[1e3,2e3,5e3,1e4][s-1]||1e4,this.encode=n!=null&&n.encode?n.encode:(s,o)=>o(JSON.stringify(s)),this.decode=n!=null&&n.decode?n.decode:this.serializer.decode.bind(this.serializer),this.reconnectTimer=new nh(async()=>{this.disconnect(),this.connect()},this.reconnectAfterMs),this.fetch=this._resolveFetch(n==null?void 0:n.fetch)}connect(){if(!this.conn){if(this.transport){this.conn=new this.transport(this._endPointURL(),void 0,{headers:this.headers});return}if(dv){this.conn=new WebSocket(this._endPointURL()),this.setupConnection();return}this.conn=new fv(this._endPointURL(),void 0,{close:()=>{this.conn=null}}),Rn(()=>import("./browser-miNZUl8P.js").then(t=>t.b),[],import.meta.url).then(({default:t})=>{this.conn=new t(this._endPointURL(),void 0,{headers:this.headers}),this.setupConnection()})}}disconnect(t,n){this.conn&&(this.conn.onclose=function(){},t?this.conn.close(t,n??""):this.conn.close(),this.conn=null,this.heartbeatTimer&&clearInterval(this.heartbeatTimer),this.reconnectTimer.reset())}getChannels(){return this.channels}async removeChannel(t){const n=await t.unsubscribe();return this.channels.length===0&&this.disconnect(),n}async removeAllChannels(){const t=await Promise.all(this.channels.map(n=>n.unsubscribe()));return this.disconnect(),t}log(t,n,r){this.logger(t,n,r)}connectionState(){switch(this.conn&&this.conn.readyState){case kn.connecting:return Ut.Connecting;case kn.open:return Ut.Open;case kn.closing:return Ut.Closing;default:return Ut.Closed}}isConnected(){return this.connectionState()===Ut.Open}channel(t,n={config:{}}){const r=new Wl(`realtime:${t}`,n,this);return this.channels.push(r),r}push(t){const{topic:n,event:r,payload:i,ref:s}=t,o=()=>{this.encode(t,l=>{var a;(a=this.conn)===null||a===void 0||a.send(l)})};this.log("push",`${n} ${r} (${s})`,i),this.isConnected()?o():this.sendBuffer.push(o)}setAuth(t){this.accessToken=t,this.channels.forEach(n=>{t&&n.updateJoinPayload({access_token:t}),n.joinedOnce&&n._isJoined()&&n._push(Fe.access_token,{access_token:t})})}_makeRef(){let t=this.ref+1;return t===this.ref?this.ref=0:this.ref=t,this.ref.toString()}_leaveOpenTopic(t){let n=this.channels.find(r=>r.topic===t&&(r._isJoined()||r._isJoining()));n&&(this.log("transport",`leaving duplicate topic "${t}"`),n.unsubscribe())}_remove(t){this.channels=this.channels.filter(n=>n._joinRef()!==t._joinRef())}setupConnection(){this.conn&&(this.conn.binaryType="arraybuffer",this.conn.onopen=()=>this._onConnOpen(),this.conn.onerror=t=>this._onConnError(t),this.conn.onmessage=t=>this._onConnMessage(t),this.conn.onclose=t=>this._onConnClose(t))}_endPointURL(){return this._appendParams(this.endPoint,Object.assign({},this.params,{vsn:tv}))}_onConnMessage(t){this.decode(t.data,n=>{let{topic:r,event:i,payload:s,ref:o}=n;(o&&o===this.pendingHeartbeatRef||i===(s==null?void 0:s.type))&&(this.pendingHeartbeatRef=null),this.log("receive",`${s.status||""} ${r} ${i} ${o&&"("+o+")"||""}`,s),this.channels.filter(l=>l._isMember(r)).forEach(l=>l._trigger(i,s,o)),this.stateChangeCallbacks.message.forEach(l=>l(n))})}_onConnOpen(){this.log("transport",`connected to ${this._endPointURL()}`),this._flushSendBuffer(),this.reconnectTimer.reset(),this.heartbeatTimer&&clearInterval(this.heartbeatTimer),this.heartbeatTimer=setInterval(()=>this._sendHeartbeat(),this.heartbeatIntervalMs),this.stateChangeCallbacks.open.forEach(t=>t())}_onConnClose(t){this.log("transport","close",t),this._triggerChanError(),this.heartbeatTimer&&clearInterval(this.heartbeatTimer),this.reconnectTimer.scheduleTimeout(),this.stateChangeCallbacks.close.forEach(n=>n(t))}_onConnError(t){this.log("transport",t.message),this._triggerChanError(),this.stateChangeCallbacks.error.forEach(n=>n(t))}_triggerChanError(){this.channels.forEach(t=>t._trigger(Fe.error))}_appendParams(t,n){if(Object.keys(n).length===0)return t;const r=t.match(/\?/)?"&":"?",i=new URLSearchParams(n);return`${t}${r}${i}`}_flushSendBuffer(){this.isConnected()&&this.sendBuffer.length>0&&(this.sendBuffer.forEach(t=>t()),this.sendBuffer=[])}_sendHeartbeat(){var t;if(this.isConnected()){if(this.pendingHeartbeatRef){this.pendingHeartbeatRef=null,this.log("transport","heartbeat timeout. Attempting to re-establish connection"),(t=this.conn)===null||t===void 0||t.close(nv,"hearbeat timeout");return}this.pendingHeartbeatRef=this._makeRef(),this.push({topic:"phoenix",event:"heartbeat",payload:{},ref:this.pendingHeartbeatRef}),this.setAuth(this.accessToken)}}}class fv{constructor(t,n,r){this.binaryType="arraybuffer",this.onclose=()=>{},this.onerror=()=>{},this.onmessage=()=>{},this.onopen=()=>{},this.readyState=kn.connecting,this.send=()=>{},this.url=null,this.url=t,this.close=r.close}}class Kl extends Error{constructor(t){super(t),this.__isStorageError=!0,this.name="StorageError"}}function ae(e){return typeof e=="object"&&e!==null&&"__isStorageError"in e}class pv extends Kl{constructor(t,n){super(t),this.name="StorageApiError",this.status=n}toJSON(){return{name:this.name,message:this.message,status:this.status}}}class gu extends Kl{constructor(t,n){super(t),this.name="StorageUnknownError",this.originalError=n}}var mv=function(e,t,n,r){function i(s){return s instanceof n?s:new n(function(o){o(s)})}return new(n||(n=Promise))(function(s,o){function l(c){try{u(r.next(c))}catch(d){o(d)}}function a(c){try{u(r.throw(c))}catch(d){o(d)}}function u(c){c.done?s(c.value):i(c.value).then(l,a)}u((r=r.apply(e,t||[])).next())})};const ih=e=>{let t;return e?t=e:typeof fetch>"u"?t=(...n)=>Rn(()=>Promise.resolve().then(()=>Ar),void 0,import.meta.url).then(({default:r})=>r(...n)):t=fetch,(...n)=>t(...n)},vv=()=>mv(void 0,void 0,void 0,function*(){return typeof Response>"u"?(yield Rn(()=>Promise.resolve().then(()=>Ar),void 0,import.meta.url)).Response:Response});var Un=function(e,t,n,r){function i(s){return s instanceof n?s:new n(function(o){o(s)})}return new(n||(n=Promise))(function(s,o){function l(c){try{u(r.next(c))}catch(d){o(d)}}function a(c){try{u(r.throw(c))}catch(d){o(d)}}function u(c){c.done?s(c.value):i(c.value).then(l,a)}u((r=r.apply(e,t||[])).next())})};const Ms=e=>e.msg||e.message||e.error_description||e.error||JSON.stringify(e),gv=(e,t)=>Un(void 0,void 0,void 0,function*(){const n=yield vv();e instanceof n?e.json().then(r=>{t(new pv(Ms(r),e.status||500))}).catch(r=>{t(new gu(Ms(r),r))}):t(new gu(Ms(e),e))}),yv=(e,t,n,r)=>{const i={method:e,headers:(t==null?void 0:t.headers)||{}};return e==="GET"?i:(i.headers=Object.assign({"Content-Type":"application/json"},t==null?void 0:t.headers),i.body=JSON.stringify(r),Object.assign(Object.assign({},i),n))};function ls(e,t,n,r,i,s){return Un(this,void 0,void 0,function*(){return new Promise((o,l)=>{e(n,yv(t,r,i,s)).then(a=>{if(!a.ok)throw a;return r!=null&&r.noResolveJson?a:a.json()}).then(a=>o(a)).catch(a=>gv(a,l))})})}function Ho(e,t,n,r){return Un(this,void 0,void 0,function*(){return ls(e,"GET",t,n,r)})}function ut(e,t,n,r,i){return Un(this,void 0,void 0,function*(){return ls(e,"POST",t,r,i,n)})}function wv(e,t,n,r,i){return Un(this,void 0,void 0,function*(){return ls(e,"PUT",t,r,i,n)})}function sh(e,t,n,r,i){return Un(this,void 0,void 0,function*(){return ls(e,"DELETE",t,r,i,n)})}var Te=function(e,t,n,r){function i(s){return s instanceof n?s:new n(function(o){o(s)})}return new(n||(n=Promise))(function(s,o){function l(c){try{u(r.next(c))}catch(d){o(d)}}function a(c){try{u(r.throw(c))}catch(d){o(d)}}function u(c){c.done?s(c.value):i(c.value).then(l,a)}u((r=r.apply(e,t||[])).next())})};const _v={limit:100,offset:0,sortBy:{column:"name",order:"asc"}},yu={cacheControl:"3600",contentType:"text/plain;charset=UTF-8",upsert:!1};class kv{constructor(t,n={},r,i){this.url=t,this.headers=n,this.bucketId=r,this.fetch=ih(i)}uploadOrUpdate(t,n,r,i){return Te(this,void 0,void 0,function*(){try{let s;const o=Object.assign(Object.assign({},yu),i),l=Object.assign(Object.assign({},this.headers),t==="POST"&&{"x-upsert":String(o.upsert)});typeof Blob<"u"&&r instanceof Blob?(s=new FormData,s.append("cacheControl",o.cacheControl),s.append("",r)):typeof FormData<"u"&&r instanceof FormData?(s=r,s.append("cacheControl",o.cacheControl)):(s=r,l["cache-control"]=`max-age=${o.cacheControl}`,l["content-type"]=o.contentType);const a=this._removeEmptyFolders(n),u=this._getFinalPath(a),c=yield this.fetch(`${this.url}/object/${u}`,Object.assign({method:t,body:s,headers:l},o!=null&&o.duplex?{duplex:o.duplex}:{})),d=yield c.json();return c.ok?{data:{path:a,id:d.Id,fullPath:d.Key},error:null}:{data:null,error:d}}catch(s){if(ae(s))return{data:null,error:s};throw s}})}upload(t,n,r){return Te(this,void 0,void 0,function*(){return this.uploadOrUpdate("POST",t,n,r)})}uploadToSignedUrl(t,n,r,i){return Te(this,void 0,void 0,function*(){const s=this._removeEmptyFolders(t),o=this._getFinalPath(s),l=new URL(this.url+`/object/upload/sign/${o}`);l.searchParams.set("token",n);try{let a;const u=Object.assign({upsert:yu.upsert},i),c=Object.assign(Object.assign({},this.headers),{"x-upsert":String(u.upsert)});typeof Blob<"u"&&r instanceof Blob?(a=new FormData,a.append("cacheControl",u.cacheControl),a.append("",r)):typeof FormData<"u"&&r instanceof FormData?(a=r,a.append("cacheControl",u.cacheControl)):(a=r,c["cache-control"]=`max-age=${u.cacheControl}`,c["content-type"]=u.contentType);const d=yield this.fetch(l.toString(),{method:"PUT",body:a,headers:c}),f=yield d.json();return d.ok?{data:{path:s,fullPath:f.Key},error:null}:{data:null,error:f}}catch(a){if(ae(a))return{data:null,error:a};throw a}})}createSignedUploadUrl(t){return Te(this,void 0,void 0,function*(){try{let n=this._getFinalPath(t);const r=yield ut(this.fetch,`${this.url}/object/upload/sign/${n}`,{},{headers:this.headers}),i=new URL(this.url+r.url),s=i.searchParams.get("token");if(!s)throw new Kl("No token returned by API");return{data:{signedUrl:i.toString(),path:t,token:s},error:null}}catch(n){if(ae(n))return{data:null,error:n};throw n}})}update(t,n,r){return Te(this,void 0,void 0,function*(){return this.uploadOrUpdate("PUT",t,n,r)})}move(t,n){return Te(this,void 0,void 0,function*(){try{return{data:yield ut(this.fetch,`${this.url}/object/move`,{bucketId:this.bucketId,sourceKey:t,destinationKey:n},{headers:this.headers}),error:null}}catch(r){if(ae(r))return{data:null,error:r};throw r}})}copy(t,n){return Te(this,void 0,void 0,function*(){try{return{data:{path:(yield ut(this.fetch,`${this.url}/object/copy`,{bucketId:this.bucketId,sourceKey:t,destinationKey:n},{headers:this.headers})).Key},error:null}}catch(r){if(ae(r))return{data:null,error:r};throw r}})}createSignedUrl(t,n,r){return Te(this,void 0,void 0,function*(){try{let i=this._getFinalPath(t),s=yield ut(this.fetch,`${this.url}/object/sign/${i}`,Object.assign({expiresIn:n},r!=null&&r.transform?{transform:r.transform}:{}),{headers:this.headers});const o=r!=null&&r.download?`&download=${r.download===!0?"":r.download}`:"";return s={signedUrl:encodeURI(`${this.url}${s.signedURL}${o}`)},{data:s,error:null}}catch(i){if(ae(i))return{data:null,error:i};throw i}})}createSignedUrls(t,n,r){return Te(this,void 0,void 0,function*(){try{const i=yield ut(this.fetch,`${this.url}/object/sign/${this.bucketId}`,{expiresIn:n,paths:t},{headers:this.headers}),s=r!=null&&r.download?`&download=${r.download===!0?"":r.download}`:"";return{data:i.map(o=>Object.assign(Object.assign({},o),{signedUrl:o.signedURL?encodeURI(`${this.url}${o.signedURL}${s}`):null})),error:null}}catch(i){if(ae(i))return{data:null,error:i};throw i}})}download(t,n){return Te(this,void 0,void 0,function*(){const i=typeof(n==null?void 0:n.transform)<"u"?"render/image/authenticated":"object",s=this.transformOptsToQueryString((n==null?void 0:n.transform)||{}),o=s?`?${s}`:"";try{const l=this._getFinalPath(t);return{data:yield(yield Ho(this.fetch,`${this.url}/${i}/${l}${o}`,{headers:this.headers,noResolveJson:!0})).blob(),error:null}}catch(l){if(ae(l))return{data:null,error:l};throw l}})}getPublicUrl(t,n){const r=this._getFinalPath(t),i=[],s=n!=null&&n.download?`download=${n.download===!0?"":n.download}`:"";s!==""&&i.push(s);const l=typeof(n==null?void 0:n.transform)<"u"?"render/image":"object",a=this.transformOptsToQueryString((n==null?void 0:n.transform)||{});a!==""&&i.push(a);let u=i.join("&");return u!==""&&(u=`?${u}`),{data:{publicUrl:encodeURI(`${this.url}/${l}/public/${r}${u}`)}}}remove(t){return Te(this,void 0,void 0,function*(){try{return{data:yield sh(this.fetch,`${this.url}/object/${this.bucketId}`,{prefixes:t},{headers:this.headers}),error:null}}catch(n){if(ae(n))return{data:null,error:n};throw n}})}list(t,n,r){return Te(this,void 0,void 0,function*(){try{const i=Object.assign(Object.assign(Object.assign({},_v),n),{prefix:t||""});return{data:yield ut(this.fetch,`${this.url}/object/list/${this.bucketId}`,i,{headers:this.headers},r),error:null}}catch(i){if(ae(i))return{data:null,error:i};throw i}})}_getFinalPath(t){return`${this.bucketId}/${t}`}_removeEmptyFolders(t){return t.replace(/^\/|\/$/g,"").replace(/\/+/g,"/")}transformOptsToQueryString(t){const n=[];return t.width&&n.push(`width=${t.width}`),t.height&&n.push(`height=${t.height}`),t.resize&&n.push(`resize=${t.resize}`),t.format&&n.push(`format=${t.format}`),t.quality&&n.push(`quality=${t.quality}`),n.join("&")}}const Sv="2.5.5",Ev={"X-Client-Info":`storage-js/${Sv}`};var Xt=function(e,t,n,r){function i(s){return s instanceof n?s:new n(function(o){o(s)})}return new(n||(n=Promise))(function(s,o){function l(c){try{u(r.next(c))}catch(d){o(d)}}function a(c){try{u(r.throw(c))}catch(d){o(d)}}function u(c){c.done?s(c.value):i(c.value).then(l,a)}u((r=r.apply(e,t||[])).next())})};class Cv{constructor(t,n={},r){this.url=t,this.headers=Object.assign(Object.assign({},Ev),n),this.fetch=ih(r)}listBuckets(){return Xt(this,void 0,void 0,function*(){try{return{data:yield Ho(this.fetch,`${this.url}/bucket`,{headers:this.headers}),error:null}}catch(t){if(ae(t))return{data:null,error:t};throw t}})}getBucket(t){return Xt(this,void 0,void 0,function*(){try{return{data:yield Ho(this.fetch,`${this.url}/bucket/${t}`,{headers:this.headers}),error:null}}catch(n){if(ae(n))return{data:null,error:n};throw n}})}createBucket(t,n={public:!1}){return Xt(this,void 0,void 0,function*(){try{return{data:yield ut(this.fetch,`${this.url}/bucket`,{id:t,name:t,public:n.public,file_size_limit:n.fileSizeLimit,allowed_mime_types:n.allowedMimeTypes},{headers:this.headers}),error:null}}catch(r){if(ae(r))return{data:null,error:r};throw r}})}updateBucket(t,n){return Xt(this,void 0,void 0,function*(){try{return{data:yield wv(this.fetch,`${this.url}/bucket/${t}`,{id:t,name:t,public:n.public,file_size_limit:n.fileSizeLimit,allowed_mime_types:n.allowedMimeTypes},{headers:this.headers}),error:null}}catch(r){if(ae(r))return{data:null,error:r};throw r}})}emptyBucket(t){return Xt(this,void 0,void 0,function*(){try{return{data:yield ut(this.fetch,`${this.url}/bucket/${t}/empty`,{},{headers:this.headers}),error:null}}catch(n){if(ae(n))return{data:null,error:n};throw n}})}deleteBucket(t){return Xt(this,void 0,void 0,function*(){try{return{data:yield sh(this.fetch,`${this.url}/bucket/${t}`,{},{headers:this.headers}),error:null}}catch(n){if(ae(n))return{data:null,error:n};throw n}})}}class xv extends Cv{constructor(t,n={},r){super(t,n,r)}from(t){return new kv(this.url,this.headers,t,this.fetch)}}const Pv="2.43.4";let Xn="";typeof Deno<"u"?Xn="deno":typeof document<"u"?Xn="web":typeof navigator<"u"&&navigator.product==="ReactNative"?Xn="react-native":Xn="node";const Tv={"X-Client-Info":`supabase-js-${Xn}/${Pv}`},Ov={headers:Tv},Rv={schema:"public"},jv={autoRefreshToken:!0,persistSession:!0,detectSessionInUrl:!0,flowType:"implicit"},Lv={};var Iv=function(e,t,n,r){function i(s){return s instanceof n?s:new n(function(o){o(s)})}return new(n||(n=Promise))(function(s,o){function l(c){try{u(r.next(c))}catch(d){o(d)}}function a(c){try{u(r.throw(c))}catch(d){o(d)}}function u(c){c.done?s(c.value):i(c.value).then(l,a)}u((r=r.apply(e,t||[])).next())})};const $v=e=>{let t;return e?t=e:typeof fetch>"u"?t=Vl:t=fetch,(...n)=>t(...n)},Nv=()=>typeof Headers>"u"?eh:Headers,Av=(e,t,n)=>{const r=$v(n),i=Nv();return(s,o)=>Iv(void 0,void 0,void 0,function*(){var l;const a=(l=yield t())!==null&&l!==void 0?l:e;let u=new i(o==null?void 0:o.headers);return u.has("apikey")||u.set("apikey",e),u.has("Authorization")||u.set("Authorization",`Bearer ${a}`),r(s,Object.assign(Object.assign({},o),{headers:u}))})};function Uv(e){return e.replace(/\/$/,"")}function Dv(e,t){const{db:n,auth:r,realtime:i,global:s}=e,{db:o,auth:l,realtime:a,global:u}=t;return{db:Object.assign(Object.assign({},o),n),auth:Object.assign(Object.assign({},l),r),realtime:Object.assign(Object.assign({},a),i),global:Object.assign(Object.assign({},u),s)}}const oh="2.64.2",zv="http://localhost:9999",Fv="supabase.auth.token",Mv={"X-Client-Info":`gotrue-js/${oh}`},wu=10,Wo="X-Supabase-Api-Version",lh={"2024-01-01":{timestamp:Date.parse("2024-01-01T00:00:00.0Z"),name:"2024-01-01"}};function bv(e){return Math.round(Date.now()/1e3)+e}function Bv(){return"xxxxxxxx-xxxx-4xxx-yxxx-xxxxxxxxxxxx".replace(/[xy]/g,function(e){const t=Math.random()*16|0;return(e=="x"?t:t&3|8).toString(16)})}const Ue=()=>typeof document<"u",Lt={tested:!1,writable:!1},ur=()=>{if(!Ue())return!1;try{if(typeof globalThis.localStorage!="object")return!1}catch{return!1}if(Lt.tested)return Lt.writable;const e=`lswt-${Math.random()}${Math.random()}`;try{globalThis.localStorage.setItem(e,e),globalThis.localStorage.removeItem(e),Lt.tested=!0,Lt.writable=!0}catch{Lt.tested=!0,Lt.writable=!1}return Lt.writable};function bs(e){const t={},n=new URL(e);if(n.hash&&n.hash[0]==="#")try{new URLSearchParams(n.hash.substring(1)).forEach((i,s)=>{t[s]=i})}catch{}return n.searchParams.forEach((r,i)=>{t[i]=r}),t}const ah=e=>{let t;return e?t=e:typeof fetch>"u"?t=(...n)=>Rn(()=>Promise.resolve().then(()=>Ar),void 0,import.meta.url).then(({default:r})=>r(...n)):t=fetch,(...n)=>t(...n)},Vv=e=>typeof e=="object"&&e!==null&&"status"in e&&"ok"in e&&"json"in e&&typeof e.json=="function",uh=async(e,t,n)=>{await e.setItem(t,JSON.stringify(n))},ti=async(e,t)=>{const n=await e.getItem(t);if(!n)return null;try{return JSON.parse(n)}catch{return n}},Bs=async(e,t)=>{await e.removeItem(t)};function Hv(e){const t="ABCDEFGHIJKLMNOPQRSTUVWXYZabcdefghijklmnopqrstuvwxyz0123456789+/=";let n="",r,i,s,o,l,a,u,c=0;for(e=e.replace("-","+").replace("_","/");c<e.length;)o=t.indexOf(e.charAt(c++)),l=t.indexOf(e.charAt(c++)),a=t.indexOf(e.charAt(c++)),u=t.indexOf(e.charAt(c++)),r=o<<2|l>>4,i=(l&15)<<4|a>>2,s=(a&3)<<6|u,n=n+String.fromCharCode(r),a!=64&&i!=0&&(n=n+String.fromCharCode(i)),u!=64&&s!=0&&(n=n+String.fromCharCode(s));return n}class as{constructor(){this.promise=new as.promiseConstructor((t,n)=>{this.resolve=t,this.reject=n})}}as.promiseConstructor=Promise;function _u(e){const t=/^([a-z0-9_-]{4})*($|[a-z0-9_-]{3}=?$|[a-z0-9_-]{2}(==)?$)$/i,n=e.split(".");if(n.length!==3)throw new Error("JWT is not valid: not a JWT structure");if(!t.test(n[1]))throw new Error("JWT is not valid: payload is not in base64url format");const r=n[1];return JSON.parse(Hv(r))}async function Wv(e){return await new Promise(t=>{setTimeout(()=>t(null),e)})}function Kv(e,t){return new Promise((r,i)=>{(async()=>{for(let s=0;s<1/0;s++)try{const o=await e(s);if(!t(s,null,o)){r(o);return}}catch(o){if(!t(s,o)){i(o);return}}})()})}function Qv(e){return("0"+e.toString(16)).substr(-2)}function Gv(){const t=new Uint32Array(56);if(typeof crypto>"u"){const n="ABCDEFGHIJKLMNOPQRSTUVWXYZabcdefghijklmnopqrstuvwxyz0123456789-._~",r=n.length;let i="";for(let s=0;s<56;s++)i+=n.charAt(Math.floor(Math.random()*r));return i}return crypto.getRandomValues(t),Array.from(t,Qv).join("")}async function Jv(e){const n=new TextEncoder().encode(e),r=await crypto.subtle.digest("SHA-256",n),i=new Uint8Array(r);return Array.from(i).map(s=>String.fromCharCode(s)).join("")}function qv(e){return btoa(e).replace(/\+/g,"-").replace(/\//g,"_").replace(/=+$/,"")}async function Yv(e){if(!(typeof crypto<"u"&&typeof crypto.subtle<"u"&&typeof TextEncoder<"u"))return console.warn("WebCrypto API is not supported. Code challenge method will default to use plain instead of sha256."),e;const n=await Jv(e);return qv(n)}async function Zt(e,t,n=!1){const r=Gv();let i=r;n&&(i+="/PASSWORD_RECOVERY"),await uh(e,`${t}-code-verifier`,i);const s=await Yv(r);return[s,r===s?"plain":"s256"]}const Xv=/^2[0-9]{3}-(0[1-9]|1[0-2])-(0[1-9]|1[0-9]|2[0-9]|3[0-1])$/i;function Zv(e){const t=e.headers.get(Wo);if(!t||!t.match(Xv))return null;try{return new Date(`${t}T00:00:00.0Z`)}catch{return null}}class Ql extends Error{constructor(t,n,r){super(t),this.__isAuthError=!0,this.name="AuthError",this.status=n,this.code=r}}function L(e){return typeof e=="object"&&e!==null&&"__isAuthError"in e}class eg extends Ql{constructor(t,n,r){super(t,n,r),this.name="AuthApiError",this.status=n,this.code=r}}function tg(e){return L(e)&&e.name==="AuthApiError"}class ch extends Ql{constructor(t,n){super(t),this.name="AuthUnknownError",this.originalError=n}}class qt extends Ql{constructor(t,n,r,i){super(t,r,i),this.name=n,this.status=r}}class It extends qt{constructor(){super("Auth session missing!","AuthSessionMissingError",400,void 0)}}class Vs extends qt{constructor(){super("Auth session or user missing","AuthInvalidTokenResponseError",500,void 0)}}class ni extends qt{constructor(t){super(t,"AuthInvalidCredentialsError",400,void 0)}}class ri extends qt{constructor(t,n=null){super(t,"AuthImplicitGrantRedirectError",500,void 0),this.details=null,this.details=n}toJSON(){return{name:this.name,message:this.message,status:this.status,details:this.details}}}class ku extends qt{constructor(t,n=null){super(t,"AuthPKCEGrantCodeExchangeError",500,void 0),this.details=null,this.details=n}toJSON(){return{name:this.name,message:this.message,status:this.status,details:this.details}}}class Ko extends qt{constructor(t,n){super(t,"AuthRetryableFetchError",n,void 0)}}function Hs(e){return L(e)&&e.name==="AuthRetryableFetchError"}class Su extends qt{constructor(t,n,r){super(t,"AuthWeakPasswordError",n,"weak_password"),this.reasons=r}}var ng=function(e,t){var n={};for(var r in e)Object.prototype.hasOwnProperty.call(e,r)&&t.indexOf(r)<0&&(n[r]=e[r]);if(e!=null&&typeof Object.getOwnPropertySymbols=="function")for(var i=0,r=Object.getOwnPropertySymbols(e);i<r.length;i++)t.indexOf(r[i])<0&&Object.prototype.propertyIsEnumerable.call(e,r[i])&&(n[r[i]]=e[r[i]]);return n};const At=e=>e.msg||e.message||e.error_description||e.error||JSON.stringify(e),rg=[502,503,504];async function Eu(e){var t;if(!Vv(e))throw new Ko(At(e),0);if(rg.includes(e.status))throw new Ko(At(e),e.status);let n;try{n=await e.json()}catch(s){throw new ch(At(s),s)}let r;const i=Zv(e);if(i&&i.getTime()>=lh["2024-01-01"].timestamp&&typeof n=="object"&&n&&typeof n.code=="string"?r=n.code:typeof n=="object"&&n&&typeof n.error_code=="string"&&(r=n.error_code),r){if(r==="weak_password")throw new Su(At(n),e.status,((t=n.weak_password)===null||t===void 0?void 0:t.reasons)||[])}else if(typeof n=="object"&&n&&typeof n.weak_password=="object"&&n.weak_password&&Array.isArray(n.weak_password.reasons)&&n.weak_password.reasons.length&&n.weak_password.reasons.reduce((s,o)=>s&&typeof o=="string",!0))throw new Su(At(n),e.status,n.weak_password.reasons);throw new eg(At(n),e.status||500,r)}const ig=(e,t,n,r)=>{const i={method:e,headers:(t==null?void 0:t.headers)||{}};return e==="GET"?i:(i.headers=Object.assign({"Content-Type":"application/json;charset=UTF-8"},t==null?void 0:t.headers),i.body=JSON.stringify(r),Object.assign(Object.assign({},i),n))};async function N(e,t,n,r){var i;const s=Object.assign({},r==null?void 0:r.headers);s[Wo]||(s[Wo]=lh["2024-01-01"].name),r!=null&&r.jwt&&(s.Authorization=`Bearer ${r.jwt}`);const o=(i=r==null?void 0:r.query)!==null&&i!==void 0?i:{};r!=null&&r.redirectTo&&(o.redirect_to=r.redirectTo);const l=Object.keys(o).length?"?"+new URLSearchParams(o).toString():"",a=await sg(e,t,n+l,{headers:s,noResolveJson:r==null?void 0:r.noResolveJson},{},r==null?void 0:r.body);return r!=null&&r.xform?r==null?void 0:r.xform(a):{data:Object.assign({},a),error:null}}async function sg(e,t,n,r,i,s){const o=ig(t,r,i,s);let l;try{l=await e(n,Object.assign({},o))}catch(a){throw console.error(a),new Ko(At(a),0)}if(l.ok||await Eu(l),r!=null&&r.noResolveJson)return l;try{return await l.json()}catch(a){await Eu(a)}}function ot(e){var t;let n=null;ug(e)&&(n=Object.assign({},e),e.expires_at||(n.expires_at=bv(e.expires_in)));const r=(t=e.user)!==null&&t!==void 0?t:e;return{data:{session:n,user:r},error:null}}function Cu(e){const t=ot(e);return!t.error&&e.weak_password&&typeof e.weak_password=="object"&&Array.isArray(e.weak_password.reasons)&&e.weak_password.reasons.length&&e.weak_password.message&&typeof e.weak_password.message=="string"&&e.weak_password.reasons.reduce((n,r)=>n&&typeof r=="string",!0)&&(t.data.weak_password=e.weak_password),t}function ht(e){var t;return{data:{user:(t=e.user)!==null&&t!==void 0?t:e},error:null}}function og(e){return{data:e,error:null}}function lg(e){const{action_link:t,email_otp:n,hashed_token:r,redirect_to:i,verification_type:s}=e,o=ng(e,["action_link","email_otp","hashed_token","redirect_to","verification_type"]),l={action_link:t,email_otp:n,hashed_token:r,redirect_to:i,verification_type:s},a=Object.assign({},o);return{data:{properties:l,user:a},error:null}}function ag(e){return e}function ug(e){return e.access_token&&e.refresh_token&&e.expires_in}var cg=function(e,t){var n={};for(var r in e)Object.prototype.hasOwnProperty.call(e,r)&&t.indexOf(r)<0&&(n[r]=e[r]);if(e!=null&&typeof Object.getOwnPropertySymbols=="function")for(var i=0,r=Object.getOwnPropertySymbols(e);i<r.length;i++)t.indexOf(r[i])<0&&Object.prototype.propertyIsEnumerable.call(e,r[i])&&(n[r[i]]=e[r[i]]);return n};class dg{constructor({url:t="",headers:n={},fetch:r}){this.url=t,this.headers=n,this.fetch=ah(r),this.mfa={listFactors:this._listFactors.bind(this),deleteFactor:this._deleteFactor.bind(this)}}async signOut(t,n="global"){try{return await N(this.fetch,"POST",`${this.url}/logout?scope=${n}`,{headers:this.headers,jwt:t,noResolveJson:!0}),{data:null,error:null}}catch(r){if(L(r))return{data:null,error:r};throw r}}async inviteUserByEmail(t,n={}){try{return await N(this.fetch,"POST",`${this.url}/invite`,{body:{email:t,data:n.data},headers:this.headers,redirectTo:n.redirectTo,xform:ht})}catch(r){if(L(r))return{data:{user:null},error:r};throw r}}async generateLink(t){try{const{options:n}=t,r=cg(t,["options"]),i=Object.assign(Object.assign({},r),n);return"newEmail"in r&&(i.new_email=r==null?void 0:r.newEmail,delete i.newEmail),await N(this.fetch,"POST",`${this.url}/admin/generate_link`,{body:i,headers:this.headers,xform:lg,redirectTo:n==null?void 0:n.redirectTo})}catch(n){if(L(n))return{data:{properties:null,user:null},error:n};throw n}}async createUser(t){try{return await N(this.fetch,"POST",`${this.url}/admin/users`,{body:t,headers:this.headers,xform:ht})}catch(n){if(L(n))return{data:{user:null},error:n};throw n}}async listUsers(t){var n,r,i,s,o,l,a;try{const u={nextPage:null,lastPage:0,total:0},c=await N(this.fetch,"GET",`${this.url}/admin/users`,{headers:this.headers,noResolveJson:!0,query:{page:(r=(n=t==null?void 0:t.page)===null||n===void 0?void 0:n.toString())!==null&&r!==void 0?r:"",per_page:(s=(i=t==null?void 0:t.perPage)===null||i===void 0?void 0:i.toString())!==null&&s!==void 0?s:""},xform:ag});if(c.error)throw c.error;const d=await c.json(),f=(o=c.headers.get("x-total-count"))!==null&&o!==void 0?o:0,v=(a=(l=c.headers.get("link"))===null||l===void 0?void 0:l.split(","))!==null&&a!==void 0?a:[];return v.length>0&&(v.forEach(g=>{const y=parseInt(g.split(";")[0].split("=")[1].substring(0,1)),_=JSON.parse(g.split(";")[1].split("=")[1]);u[`${_}Page`]=y}),u.total=parseInt(f)),{data:Object.assign(Object.assign({},d),u),error:null}}catch(u){if(L(u))return{data:{users:[]},error:u};throw u}}async getUserById(t){try{return await N(this.fetch,"GET",`${this.url}/admin/users/${t}`,{headers:this.headers,xform:ht})}catch(n){if(L(n))return{data:{user:null},error:n};throw n}}async updateUserById(t,n){try{return await N(this.fetch,"PUT",`${this.url}/admin/users/${t}`,{body:n,headers:this.headers,xform:ht})}catch(r){if(L(r))return{data:{user:null},error:r};throw r}}async deleteUser(t,n=!1){try{return await N(this.fetch,"DELETE",`${this.url}/admin/users/${t}`,{headers:this.headers,body:{should_soft_delete:n},xform:ht})}catch(r){if(L(r))return{data:{user:null},error:r};throw r}}async _listFactors(t){try{const{data:n,error:r}=await N(this.fetch,"GET",`${this.url}/admin/users/${t.userId}/factors`,{headers:this.headers,xform:i=>({data:{factors:i},error:null})});return{data:n,error:r}}catch(n){if(L(n))return{data:null,error:n};throw n}}async _deleteFactor(t){try{return{data:await N(this.fetch,"DELETE",`${this.url}/admin/users/${t.userId}/factors/${t.id}`,{headers:this.headers}),error:null}}catch(n){if(L(n))return{data:null,error:n};throw n}}}const hg={getItem:e=>ur()?globalThis.localStorage.getItem(e):null,setItem:(e,t)=>{ur()&&globalThis.localStorage.setItem(e,t)},removeItem:e=>{ur()&&globalThis.localStorage.removeItem(e)}};function xu(e={}){return{getItem:t=>e[t]||null,setItem:(t,n)=>{e[t]=n},removeItem:t=>{delete e[t]}}}function fg(){if(typeof globalThis!="object")try{Object.defineProperty(Object.prototype,"__magic__",{get:function(){return this},configurable:!0}),__magic__.globalThis=__magic__,delete Object.prototype.__magic__}catch{typeof self<"u"&&(self.globalThis=self)}}const en={debug:!!(globalThis&&ur()&&globalThis.localStorage&&globalThis.localStorage.getItem("supabase.gotrue-js.locks.debug")==="true")};class dh extends Error{constructor(t){super(t),this.isAcquireTimeout=!0}}class pg extends dh{}async function mg(e,t,n){en.debug&&console.log("@supabase/gotrue-js: navigatorLock: acquire lock",e,t);const r=new globalThis.AbortController;return t>0&&setTimeout(()=>{r.abort(),en.debug&&console.log("@supabase/gotrue-js: navigatorLock acquire timed out",e)},t),await globalThis.navigator.locks.request(e,t===0?{mode:"exclusive",ifAvailable:!0}:{mode:"exclusive",signal:r.signal},async i=>{if(i){en.debug&&console.log("@supabase/gotrue-js: navigatorLock: acquired",e,i.name);try{return await n()}finally{en.debug&&console.log("@supabase/gotrue-js: navigatorLock: released",e,i.name)}}else{if(t===0)throw en.debug&&console.log("@supabase/gotrue-js: navigatorLock: not immediately available",e),new pg(`Acquiring an exclusive Navigator LockManager lock "${e}" immediately failed`);if(en.debug)try{const s=await globalThis.navigator.locks.query();console.log("@supabase/gotrue-js: Navigator LockManager state",JSON.stringify(s,null," "))}catch(s){console.warn("@supabase/gotrue-js: Error when querying Navigator LockManager state",s)}return console.warn("@supabase/gotrue-js: Navigator LockManager returned a null lock when using #request without ifAvailable set to true, it appears this browser is not following the LockManager spec https://developer.mozilla.org/en-US/docs/Web/API/LockManager/request"),await n()}})}fg();const vg={url:zv,storageKey:Fv,autoRefreshToken:!0,persistSession:!0,detectSessionInUrl:!0,headers:Mv,flowType:"implicit",debug:!1,hasCustomAuthorizationHeader:!1},Qn=30*1e3,Pu=3;async function Tu(e,t,n){return await n()}class Rr{constructor(t){var n,r;this.memoryStorage=null,this.stateChangeEmitters=new Map,this.autoRefreshTicker=null,this.visibilityChangedCallback=null,this.refreshingDeferred=null,this.initializePromise=null,this.detectSessionInUrl=!0,this.hasCustomAuthorizationHeader=!1,this.suppressGetSessionWarning=!1,this.lockAcquired=!1,this.pendingInLock=[],this.broadcastChannel=null,this.logger=console.log,this.instanceID=Rr.nextInstanceID,Rr.nextInstanceID+=1,this.instanceID>0&&Ue()&&console.warn("Multiple GoTrueClient instances detected in the same browser context. It is not an error, but this should be avoided as it may produce undefined behavior when used concurrently under the same storage key.");const i=Object.assign(Object.assign({},vg),t);if(this.logDebugMessages=!!i.debug,typeof i.debug=="function"&&(this.logger=i.debug),this.persistSession=i.persistSession,this.storageKey=i.storageKey,this.autoRefreshToken=i.autoRefreshToken,this.admin=new dg({url:i.url,headers:i.headers,fetch:i.fetch}),this.url=i.url,this.headers=i.headers,this.fetch=ah(i.fetch),this.lock=i.lock||Tu,this.detectSessionInUrl=i.detectSessionInUrl,this.flowType=i.flowType,this.hasCustomAuthorizationHeader=i.hasCustomAuthorizationHeader,i.lock?this.lock=i.lock:Ue()&&(!((n=globalThis==null?void 0:globalThis.navigator)===null||n===void 0)&&n.locks)?this.lock=mg:this.lock=Tu,this.mfa={verify:this._verify.bind(this),enroll:this._enroll.bind(this),unenroll:this._unenroll.bind(this),challenge:this._challenge.bind(this),listFactors:this._listFactors.bind(this),challengeAndVerify:this._challengeAndVerify.bind(this),getAuthenticatorAssuranceLevel:this._getAuthenticatorAssuranceLevel.bind(this)},this.persistSession?i.storage?this.storage=i.storage:ur()?this.storage=hg:(this.memoryStorage={},this.storage=xu(this.memoryStorage)):(this.memoryStorage={},this.storage=xu(this.memoryStorage)),Ue()&&globalThis.BroadcastChannel&&this.persistSession&&this.storageKey){try{this.broadcastChannel=new globalThis.BroadcastChannel(this.storageKey)}catch(s){console.error("Failed to create a new BroadcastChannel, multi-tab state changes will not be available",s)}(r=this.broadcastChannel)===null||r===void 0||r.addEventListener("message",async s=>{this._debug("received broadcast notification from other tab or client",s),await this._notifyAllSubscribers(s.data.event,s.data.session,!1)})}this.initialize()}_debug(...t){return this.logDebugMessages&&this.logger(`GoTrueClient@${this.instanceID} (${oh}) ${new Date().toISOString()}`,...t),this}async initialize(){return this.initializePromise?await this.initializePromise:(this.initializePromise=(async()=>await this._acquireLock(-1,async()=>await this._initialize()))(),await this.initializePromise)}async _initialize(){try{const t=Ue()?await this._isPKCEFlow():!1;if(this._debug("#_initialize()","begin","is PKCE flow",t),t||this.detectSessionInUrl&&this._isImplicitGrantFlow()){const{data:n,error:r}=await this._getSessionFromURL(t);if(r)return this._debug("#_initialize()","error detecting session from URL",r),(r==null?void 0:r.message)==="Identity is already linked"||(r==null?void 0:r.message)==="Identity is already linked to another user"?{error:r}:(await this._removeSession(),{error:r});const{session:i,redirectType:s}=n;return this._debug("#_initialize()","detected session in URL",i,"redirect type",s),await this._saveSession(i),setTimeout(async()=>{s==="recovery"?await this._notifyAllSubscribers("PASSWORD_RECOVERY",i):await this._notifyAllSubscribers("SIGNED_IN",i)},0),{error:null}}return await this._recoverAndRefresh(),{error:null}}catch(t){return L(t)?{error:t}:{error:new ch("Unexpected error during initialization",t)}}finally{await this._handleVisibilityChange(),this._debug("#_initialize()","end")}}async signInAnonymously(t){var n,r,i;try{await this._removeSession();const s=await N(this.fetch,"POST",`${this.url}/signup`,{headers:this.headers,body:{data:(r=(n=t==null?void 0:t.options)===null||n===void 0?void 0:n.data)!==null&&r!==void 0?r:{},gotrue_meta_security:{captcha_token:(i=t==null?void 0:t.options)===null||i===void 0?void 0:i.captchaToken}},xform:ot}),{data:o,error:l}=s;if(l||!o)return{data:{user:null,session:null},error:l};const a=o.session,u=o.user;return o.session&&(await this._saveSession(o.session),await this._notifyAllSubscribers("SIGNED_IN",a)),{data:{user:u,session:a},error:null}}catch(s){if(L(s))return{data:{user:null,session:null},error:s};throw s}}async signUp(t){var n,r,i;try{await this._removeSession();let s;if("email"in t){const{email:c,password:d,options:f}=t;let v=null,g=null;this.flowType==="pkce"&&([v,g]=await Zt(this.storage,this.storageKey)),s=await N(this.fetch,"POST",`${this.url}/signup`,{headers:this.headers,redirectTo:f==null?void 0:f.emailRedirectTo,body:{email:c,password:d,data:(n=f==null?void 0:f.data)!==null&&n!==void 0?n:{},gotrue_meta_security:{captcha_token:f==null?void 0:f.captchaToken},code_challenge:v,code_challenge_method:g},xform:ot})}else if("phone"in t){const{phone:c,password:d,options:f}=t;s=await N(this.fetch,"POST",`${this.url}/signup`,{headers:this.headers,body:{phone:c,password:d,data:(r=f==null?void 0:f.data)!==null&&r!==void 0?r:{},channel:(i=f==null?void 0:f.channel)!==null&&i!==void 0?i:"sms",gotrue_meta_security:{captcha_token:f==null?void 0:f.captchaToken}},xform:ot})}else throw new ni("You must provide either an email or phone number and a password");const{data:o,error:l}=s;if(l||!o)return{data:{user:null,session:null},error:l};const a=o.session,u=o.user;return o.session&&(await this._saveSession(o.session),await this._notifyAllSubscribers("SIGNED_IN",a)),{data:{user:u,session:a},error:null}}catch(s){if(L(s))return{data:{user:null,session:null},error:s};throw s}}async signInWithPassword(t){try{await this._removeSession();let n;if("email"in t){const{email:s,password:o,options:l}=t;n=await N(this.fetch,"POST",`${this.url}/token?grant_type=password`,{headers:this.headers,body:{email:s,password:o,gotrue_meta_security:{captcha_token:l==null?void 0:l.captchaToken}},xform:Cu})}else if("phone"in t){const{phone:s,password:o,options:l}=t;n=await N(this.fetch,"POST",`${this.url}/token?grant_type=password`,{headers:this.headers,body:{phone:s,password:o,gotrue_meta_security:{captcha_token:l==null?void 0:l.captchaToken}},xform:Cu})}else throw new ni("You must provide either an email or phone number and a password");const{data:r,error:i}=n;return i?{data:{user:null,session:null},error:i}:!r||!r.session||!r.user?{data:{user:null,session:null},error:new Vs}:(r.session&&(await this._saveSession(r.session),await this._notifyAllSubscribers("SIGNED_IN",r.session)),{data:Object.assign({user:r.user,session:r.session},r.weak_password?{weakPassword:r.weak_password}:null),error:i})}catch(n){if(L(n))return{data:{user:null,session:null},error:n};throw n}}async signInWithOAuth(t){var n,r,i,s;return await this._removeSession(),await this._handleProviderSignIn(t.provider,{redirectTo:(n=t.options)===null||n===void 0?void 0:n.redirectTo,scopes:(r=t.options)===null||r===void 0?void 0:r.scopes,queryParams:(i=t.options)===null||i===void 0?void 0:i.queryParams,skipBrowserRedirect:(s=t.options)===null||s===void 0?void 0:s.skipBrowserRedirect})}async exchangeCodeForSession(t){return await this.initializePromise,this._acquireLock(-1,async()=>this._exchangeCodeForSession(t))}async _exchangeCodeForSession(t){const n=await ti(this.storage,`${this.storageKey}-code-verifier`),[r,i]=(n??"").split("/"),{data:s,error:o}=await N(this.fetch,"POST",`${this.url}/token?grant_type=pkce`,{headers:this.headers,body:{auth_code:t,code_verifier:r},xform:ot});return await Bs(this.storage,`${this.storageKey}-code-verifier`),o?{data:{user:null,session:null,redirectType:null},error:o}:!s||!s.session||!s.user?{data:{user:null,session:null,redirectType:null},error:new Vs}:(s.session&&(await this._saveSession(s.session),await this._notifyAllSubscribers("SIGNED_IN",s.session)),{data:Object.assign(Object.assign({},s),{redirectType:i??null}),error:o})}async signInWithIdToken(t){await this._removeSession();try{const{options:n,provider:r,token:i,access_token:s,nonce:o}=t,l=await N(this.fetch,"POST",`${this.url}/token?grant_type=id_token`,{headers:this.headers,body:{provider:r,id_token:i,access_token:s,nonce:o,gotrue_meta_security:{captcha_token:n==null?void 0:n.captchaToken}},xform:ot}),{data:a,error:u}=l;return u?{data:{user:null,session:null},error:u}:!a||!a.session||!a.user?{data:{user:null,session:null},error:new Vs}:(a.session&&(await this._saveSession(a.session),await this._notifyAllSubscribers("SIGNED_IN",a.session)),{data:a,error:u})}catch(n){if(L(n))return{data:{user:null,session:null},error:n};throw n}}async signInWithOtp(t){var n,r,i,s,o;try{if(await this._removeSession(),"email"in t){const{email:l,options:a}=t;let u=null,c=null;this.flowType==="pkce"&&([u,c]=await Zt(this.storage,this.storageKey));const{error:d}=await N(this.fetch,"POST",`${this.url}/otp`,{headers:this.headers,body:{email:l,data:(n=a==null?void 0:a.data)!==null&&n!==void 0?n:{},create_user:(r=a==null?void 0:a.shouldCreateUser)!==null&&r!==void 0?r:!0,gotrue_meta_security:{captcha_token:a==null?void 0:a.captchaToken},code_challenge:u,code_challenge_method:c},redirectTo:a==null?void 0:a.emailRedirectTo});return{data:{user:null,session:null},error:d}}if("phone"in t){const{phone:l,options:a}=t,{data:u,error:c}=await N(this.fetch,"POST",`${this.url}/otp`,{headers:this.headers,body:{phone:l,data:(i=a==null?void 0:a.data)!==null&&i!==void 0?i:{},create_user:(s=a==null?void 0:a.shouldCreateUser)!==null&&s!==void 0?s:!0,gotrue_meta_security:{captcha_token:a==null?void 0:a.captchaToken},channel:(o=a==null?void 0:a.channel)!==null&&o!==void 0?o:"sms"}});return{data:{user:null,session:null,messageId:u==null?void 0:u.message_id},error:c}}throw new ni("You must provide either an email or phone number.")}catch(l){if(L(l))return{data:{user:null,session:null},error:l};throw l}}async verifyOtp(t){var n,r;try{t.type!=="email_change"&&t.type!=="phone_change"&&await this._removeSession();let i,s;"options"in t&&(i=(n=t.options)===null||n===void 0?void 0:n.redirectTo,s=(r=t.options)===null||r===void 0?void 0:r.captchaToken);const{data:o,error:l}=await N(this.fetch,"POST",`${this.url}/verify`,{headers:this.headers,body:Object.assign(Object.assign({},t),{gotrue_meta_security:{captcha_token:s}}),redirectTo:i,xform:ot});if(l)throw l;if(!o)throw new Error("An error occurred on token verification.");const a=o.session,u=o.user;return a!=null&&a.access_token&&(await this._saveSession(a),await this._notifyAllSubscribers(t.type=="recovery"?"PASSWORD_RECOVERY":"SIGNED_IN",a)),{data:{user:u,session:a},error:null}}catch(i){if(L(i))return{data:{user:null,session:null},error:i};throw i}}async signInWithSSO(t){var n,r,i;try{await this._removeSession();let s=null,o=null;return this.flowType==="pkce"&&([s,o]=await Zt(this.storage,this.storageKey)),await N(this.fetch,"POST",`${this.url}/sso`,{body:Object.assign(Object.assign(Object.assign(Object.assign(Object.assign({},"providerId"in t?{provider_id:t.providerId}:null),"domain"in t?{domain:t.domain}:null),{redirect_to:(r=(n=t.options)===null||n===void 0?void 0:n.redirectTo)!==null&&r!==void 0?r:void 0}),!((i=t==null?void 0:t.options)===null||i===void 0)&&i.captchaToken?{gotrue_meta_security:{captcha_token:t.options.captchaToken}}:null),{skip_http_redirect:!0,code_challenge:s,code_challenge_method:o}),headers:this.headers,xform:og})}catch(s){if(L(s))return{data:null,error:s};throw s}}async reauthenticate(){return await this.initializePromise,await this._acquireLock(-1,async()=>await this._reauthenticate())}async _reauthenticate(){try{return await this._useSession(async t=>{const{data:{session:n},error:r}=t;if(r)throw r;if(!n)throw new It;const{error:i}=await N(this.fetch,"GET",`${this.url}/reauthenticate`,{headers:this.headers,jwt:n.access_token});return{data:{user:null,session:null},error:i}})}catch(t){if(L(t))return{data:{user:null,session:null},error:t};throw t}}async resend(t){try{t.type!="email_change"&&t.type!="phone_change"&&await this._removeSession();const n=`${this.url}/resend`;if("email"in t){const{email:r,type:i,options:s}=t,{error:o}=await N(this.fetch,"POST",n,{headers:this.headers,body:{email:r,type:i,gotrue_meta_security:{captcha_token:s==null?void 0:s.captchaToken}},redirectTo:s==null?void 0:s.emailRedirectTo});return{data:{user:null,session:null},error:o}}else if("phone"in t){const{phone:r,type:i,options:s}=t,{data:o,error:l}=await N(this.fetch,"POST",n,{headers:this.headers,body:{phone:r,type:i,gotrue_meta_security:{captcha_token:s==null?void 0:s.captchaToken}}});return{data:{user:null,session:null,messageId:o==null?void 0:o.message_id},error:l}}throw new ni("You must provide either an email or phone number and a type")}catch(n){if(L(n))return{data:{user:null,session:null},error:n};throw n}}async getSession(){return await this.initializePromise,await this._acquireLock(-1,async()=>this._useSession(async n=>n))}async _acquireLock(t,n){this._debug("#_acquireLock","begin",t);try{if(this.lockAcquired){const r=this.pendingInLock.length?this.pendingInLock[this.pendingInLock.length-1]:Promise.resolve(),i=(async()=>(await r,await n()))();return this.pendingInLock.push((async()=>{try{await i}catch{}})()),i}return await this.lock(`lock:${this.storageKey}`,t,async()=>{this._debug("#_acquireLock","lock acquired for storage key",this.storageKey);try{this.lockAcquired=!0;const r=n();for(this.pendingInLock.push((async()=>{try{await r}catch{}})()),await r;this.pendingInLock.length;){const i=[...this.pendingInLock];await Promise.all(i),this.pendingInLock.splice(0,i.length)}return await r}finally{this._debug("#_acquireLock","lock released for storage key",this.storageKey),this.lockAcquired=!1}})}finally{this._debug("#_acquireLock","end")}}async _useSession(t){this._debug("#_useSession","begin");try{const n=await this.__loadSession();return await t(n)}finally{this._debug("#_useSession","end")}}async __loadSession(){this._debug("#__loadSession()","begin"),this.lockAcquired||this._debug("#__loadSession()","used outside of an acquired lock!",new Error().stack);try{let t=null;const n=await ti(this.storage,this.storageKey);if(this._debug("#getSession()","session from storage",n),n!==null&&(this._isValidSession(n)?t=n:(this._debug("#getSession()","session from storage is not valid"),await this._removeSession())),!t)return{data:{session:null},error:null};const r=t.expires_at?t.expires_at<=Date.now()/1e3:!1;if(this._debug("#__loadSession()",`session has${r?"":" not"} expired`,"expires_at",t.expires_at),!r){if(this.storage.isServer){const o=this.suppressGetSessionWarning;t=new Proxy(t,{get(a,u,c){return!o&&u==="user"&&console.warn("Using the user object as returned from supabase.auth.getSession() or from some supabase.auth.onAuthStateChange() events could be insecure! This value comes directly from the storage medium (usually cookies on the server) and many not be authentic. Use supabase.auth.getUser() instead which authenticates the data by contacting the Supabase Auth server."),Reflect.get(a,u,c)}})}return{data:{session:t},error:null}}const{session:i,error:s}=await this._callRefreshToken(t.refresh_token);return s?{data:{session:null},error:s}:{data:{session:i},error:null}}finally{this._debug("#__loadSession()","end")}}async getUser(t){return t?await this._getUser(t):(await this.initializePromise,await this._acquireLock(-1,async()=>await this._getUser()))}async _getUser(t){try{return t?await N(this.fetch,"GET",`${this.url}/user`,{headers:this.headers,jwt:t,xform:ht}):await this._useSession(async n=>{var r,i,s;const{data:o,error:l}=n;if(l)throw l;return!(!((r=o.session)===null||r===void 0)&&r.access_token)&&!this.hasCustomAuthorizationHeader?{data:{user:null},error:new It}:await N(this.fetch,"GET",`${this.url}/user`,{headers:this.headers,jwt:(s=(i=o.session)===null||i===void 0?void 0:i.access_token)!==null&&s!==void 0?s:void 0,xform:ht})})}catch(n){if(L(n))return{data:{user:null},error:n};throw n}}async updateUser(t,n={}){return await this.initializePromise,await this._acquireLock(-1,async()=>await this._updateUser(t,n))}async _updateUser(t,n={}){try{return await this._useSession(async r=>{const{data:i,error:s}=r;if(s)throw s;if(!i.session)throw new It;const o=i.session;let l=null,a=null;this.flowType==="pkce"&&t.email!=null&&([l,a]=await Zt(this.storage,this.storageKey));const{data:u,error:c}=await N(this.fetch,"PUT",`${this.url}/user`,{headers:this.headers,redirectTo:n==null?void 0:n.emailRedirectTo,body:Object.assign(Object.assign({},t),{code_challenge:l,code_challenge_method:a}),jwt:o.access_token,xform:ht});if(c)throw c;return o.user=u.user,await this._saveSession(o),await this._notifyAllSubscribers("USER_UPDATED",o),{data:{user:o.user},error:null}})}catch(r){if(L(r))return{data:{user:null},error:r};throw r}}_decodeJWT(t){return _u(t)}async setSession(t){return await this.initializePromise,await this._acquireLock(-1,async()=>await this._setSession(t))}async _setSession(t){try{if(!t.access_token||!t.refresh_token)throw new It;const n=Date.now()/1e3;let r=n,i=!0,s=null;const o=_u(t.access_token);if(o.exp&&(r=o.exp,i=r<=n),i){const{session:l,error:a}=await this._callRefreshToken(t.refresh_token);if(a)return{data:{user:null,session:null},error:a};if(!l)return{data:{user:null,session:null},error:null};s=l}else{const{data:l,error:a}=await this._getUser(t.access_token);if(a)throw a;s={access_token:t.access_token,refresh_token:t.refresh_token,user:l.user,token_type:"bearer",expires_in:r-n,expires_at:r},await this._saveSession(s),await this._notifyAllSubscribers("SIGNED_IN",s)}return{data:{user:s.user,session:s},error:null}}catch(n){if(L(n))return{data:{session:null,user:null},error:n};throw n}}async refreshSession(t){return await this.initializePromise,await this._acquireLock(-1,async()=>await this._refreshSession(t))}async _refreshSession(t){try{return await this._useSession(async n=>{var r;if(!t){const{data:o,error:l}=n;if(l)throw l;t=(r=o.session)!==null&&r!==void 0?r:void 0}if(!(t!=null&&t.refresh_token))throw new It;const{session:i,error:s}=await this._callRefreshToken(t.refresh_token);return s?{data:{user:null,session:null},error:s}:i?{data:{user:i.user,session:i},error:null}:{data:{user:null,session:null},error:null}})}catch(n){if(L(n))return{data:{user:null,session:null},error:n};throw n}}async _getSessionFromURL(t){try{if(!Ue())throw new ri("No browser detected.");if(this.flowType==="implicit"&&!this._isImplicitGrantFlow())throw new ri("Not a valid implicit grant flow url.");if(this.flowType=="pkce"&&!t)throw new ku("Not a valid PKCE flow url.");const n=bs(window.location.href);if(t){if(!n.code)throw new ku("No code detected.");const{data:h,error:m}=await this._exchangeCodeForSession(n.code);if(m)throw m;const w=new URL(window.location.href);return w.searchParams.delete("code"),window.history.replaceState(window.history.state,"",w.toString()),{data:{session:h.session,redirectType:null},error:null}}if(n.error||n.error_description||n.error_code)throw new ri(n.error_description||"Error in URL with unspecified error_description",{error:n.error||"unspecified_error",code:n.error_code||"unspecified_code"});const{provider_token:r,provider_refresh_token:i,access_token:s,refresh_token:o,expires_in:l,expires_at:a,token_type:u}=n;if(!s||!l||!o||!u)throw new ri("No session defined in URL");const c=Math.round(Date.now()/1e3),d=parseInt(l);let f=c+d;a&&(f=parseInt(a));const v=f-c;v*1e3<=Qn&&console.warn(`@supabase/gotrue-js: Session as retrieved from URL expires in ${v}s, should have been closer to ${d}s`);const g=f-d;c-g>=120?console.warn("@supabase/gotrue-js: Session as retrieved from URL was issued over 120s ago, URL could be stale",g,f,c):c-g<0&&console.warn("@supabase/gotrue-js: Session as retrieved from URL was issued in the future? Check the device clok for skew",g,f,c);const{data:y,error:_}=await this._getUser(s);if(_)throw _;const p={provider_token:r,provider_refresh_token:i,access_token:s,expires_in:d,expires_at:f,refresh_token:o,token_type:u,user:y.user};return window.location.hash="",this._debug("#_getSessionFromURL()","clearing window.location.hash"),{data:{session:p,redirectType:n.type},error:null}}catch(n){if(L(n))return{data:{session:null,redirectType:null},error:n};throw n}}_isImplicitGrantFlow(){const t=bs(window.location.href);return!!(Ue()&&(t.access_token||t.error_description))}async _isPKCEFlow(){const t=bs(window.location.href),n=await ti(this.storage,`${this.storageKey}-code-verifier`);return!!(t.code&&n)}async signOut(t={scope:"global"}){return await this.initializePromise,await this._acquireLock(-1,async()=>await this._signOut(t))}async _signOut({scope:t}={scope:"global"}){return await this._useSession(async n=>{var r;const{data:i,error:s}=n;if(s)return{error:s};const o=(r=i.session)===null||r===void 0?void 0:r.access_token;if(o){const{error:l}=await this.admin.signOut(o,t);if(l&&!(tg(l)&&(l.status===404||l.status===401||l.status===403)))return{error:l}}return t!=="others"&&(await this._removeSession(),await Bs(this.storage,`${this.storageKey}-code-verifier`),await this._notifyAllSubscribers("SIGNED_OUT",null)),{error:null}})}onAuthStateChange(t){const n=Bv(),r={id:n,callback:t,unsubscribe:()=>{this._debug("#unsubscribe()","state change callback with id removed",n),this.stateChangeEmitters.delete(n)}};return this._debug("#onAuthStateChange()","registered callback with id",n),this.stateChangeEmitters.set(n,r),(async()=>(await this.initializePromise,await this._acquireLock(-1,async()=>{this._emitInitialSession(n)})))(),{data:{subscription:r}}}async _emitInitialSession(t){return await this._useSession(async n=>{var r,i;try{const{data:{session:s},error:o}=n;if(o)throw o;await((r=this.stateChangeEmitters.get(t))===null||r===void 0?void 0:r.callback("INITIAL_SESSION",s)),this._debug("INITIAL_SESSION","callback id",t,"session",s)}catch(s){await((i=this.stateChangeEmitters.get(t))===null||i===void 0?void 0:i.callback("INITIAL_SESSION",null)),this._debug("INITIAL_SESSION","callback id",t,"error",s),console.error(s)}})}async resetPasswordForEmail(t,n={}){let r=null,i=null;this.flowType==="pkce"&&([r,i]=await Zt(this.storage,this.storageKey,!0));try{return await N(this.fetch,"POST",`${this.url}/recover`,{body:{email:t,code_challenge:r,code_challenge_method:i,gotrue_meta_security:{captcha_token:n.captchaToken}},headers:this.headers,redirectTo:n.redirectTo})}catch(s){if(L(s))return{data:null,error:s};throw s}}async getUserIdentities(){var t;try{const{data:n,error:r}=await this.getUser();if(r)throw r;return{data:{identities:(t=n.user.identities)!==null&&t!==void 0?t:[]},error:null}}catch(n){if(L(n))return{data:null,error:n};throw n}}async linkIdentity(t){var n;try{const{data:r,error:i}=await this._useSession(async s=>{var o,l,a,u,c;const{data:d,error:f}=s;if(f)throw f;const v=await this._getUrlForProvider(`${this.url}/user/identities/authorize`,t.provider,{redirectTo:(o=t.options)===null||o===void 0?void 0:o.redirectTo,scopes:(l=t.options)===null||l===void 0?void 0:l.scopes,queryParams:(a=t.options)===null||a===void 0?void 0:a.queryParams,skipBrowserRedirect:!0});return await N(this.fetch,"GET",v,{headers:this.headers,jwt:(c=(u=d.session)===null||u===void 0?void 0:u.access_token)!==null&&c!==void 0?c:void 0})});if(i)throw i;return Ue()&&!(!((n=t.options)===null||n===void 0)&&n.skipBrowserRedirect)&&window.location.assign(r==null?void 0:r.url),{data:{provider:t.provider,url:r==null?void 0:r.url},error:null}}catch(r){if(L(r))return{data:{provider:t.provider,url:null},error:r};throw r}}async unlinkIdentity(t){try{return await this._useSession(async n=>{var r,i;const{data:s,error:o}=n;if(o)throw o;return await N(this.fetch,"DELETE",`${this.url}/user/identities/${t.identity_id}`,{headers:this.headers,jwt:(i=(r=s.session)===null||r===void 0?void 0:r.access_token)!==null&&i!==void 0?i:void 0})})}catch(n){if(L(n))return{data:null,error:n};throw n}}async _refreshAccessToken(t){const n=`#_refreshAccessToken(${t.substring(0,5)}...)`;this._debug(n,"begin");try{const r=Date.now();return await Kv(async i=>(i>0&&await Wv(200*Math.pow(2,i-1)),this._debug(n,"refreshing attempt",i),await N(this.fetch,"POST",`${this.url}/token?grant_type=refresh_token`,{body:{refresh_token:t},headers:this.headers,xform:ot})),(i,s)=>{const o=200*Math.pow(2,i);return s&&Hs(s)&&Date.now()+o-r<Qn})}catch(r){if(this._debug(n,"error",r),L(r))return{data:{session:null,user:null},error:r};throw r}finally{this._debug(n,"end")}}_isValidSession(t){return typeof t=="object"&&t!==null&&"access_token"in t&&"refresh_token"in t&&"expires_at"in t}async _handleProviderSignIn(t,n){const r=await this._getUrlForProvider(`${this.url}/authorize`,t,{redirectTo:n.redirectTo,scopes:n.scopes,queryParams:n.queryParams});return this._debug("#_handleProviderSignIn()","provider",t,"options",n,"url",r),Ue()&&!n.skipBrowserRedirect&&window.location.assign(r),{data:{provider:t,url:r},error:null}}async _recoverAndRefresh(){var t;const n="#_recoverAndRefresh()";this._debug(n,"begin");try{const r=await ti(this.storage,this.storageKey);if(this._debug(n,"session from storage",r),!this._isValidSession(r)){this._debug(n,"session is not valid"),r!==null&&await this._removeSession();return}const i=Math.round(Date.now()/1e3),s=((t=r.expires_at)!==null&&t!==void 0?t:1/0)<i+wu;if(this._debug(n,`session has${s?"":" not"} expired with margin of ${wu}s`),s){if(this.autoRefreshToken&&r.refresh_token){const{error:o}=await this._callRefreshToken(r.refresh_token);o&&(console.error(o),Hs(o)||(this._debug(n,"refresh failed with a non-retryable error, removing the session",o),await this._removeSession()))}}else await this._notifyAllSubscribers("SIGNED_IN",r)}catch(r){this._debug(n,"error",r),console.error(r);return}finally{this._debug(n,"end")}}async _callRefreshToken(t){var n,r;if(!t)throw new It;if(this.refreshingDeferred)return this.refreshingDeferred.promise;const i=`#_callRefreshToken(${t.substring(0,5)}...)`;this._debug(i,"begin");try{this.refreshingDeferred=new as;const{data:s,error:o}=await this._refreshAccessToken(t);if(o)throw o;if(!s.session)throw new It;await this._saveSession(s.session),await this._notifyAllSubscribers("TOKEN_REFRESHED",s.session);const l={session:s.session,error:null};return this.refreshingDeferred.resolve(l),l}catch(s){if(this._debug(i,"error",s),L(s)){const o={session:null,error:s};return Hs(s)||(await this._removeSession(),await this._notifyAllSubscribers("SIGNED_OUT",null)),(n=this.refreshingDeferred)===null||n===void 0||n.resolve(o),o}throw(r=this.refreshingDeferred)===null||r===void 0||r.reject(s),s}finally{this.refreshingDeferred=null,this._debug(i,"end")}}async _notifyAllSubscribers(t,n,r=!0){const i=`#_notifyAllSubscribers(${t})`;this._debug(i,"begin",n,`broadcast = ${r}`);try{this.broadcastChannel&&r&&this.broadcastChannel.postMessage({event:t,session:n});const s=[],o=Array.from(this.stateChangeEmitters.values()).map(async l=>{try{await l.callback(t,n)}catch(a){s.push(a)}});if(await Promise.all(o),s.length>0){for(let l=0;l<s.length;l+=1)console.error(s[l]);throw s[0]}}finally{this._debug(i,"end")}}async _saveSession(t){this._debug("#_saveSession()",t),this.suppressGetSessionWarning=!0,await uh(this.storage,this.storageKey,t)}async _removeSession(){this._debug("#_removeSession()"),await Bs(this.storage,this.storageKey)}_removeVisibilityChangedCallback(){this._debug("#_removeVisibilityChangedCallback()");const t=this.visibilityChangedCallback;this.visibilityChangedCallback=null;try{t&&Ue()&&(window!=null&&window.removeEventListener)&&window.removeEventListener("visibilitychange",t)}catch(n){console.error("removing visibilitychange callback failed",n)}}async _startAutoRefresh(){await this._stopAutoRefresh(),this._debug("#_startAutoRefresh()");const t=setInterval(()=>this._autoRefreshTokenTick(),Qn);this.autoRefreshTicker=t,t&&typeof t=="object"&&typeof t.unref=="function"?t.unref():typeof Deno<"u"&&typeof Deno.unrefTimer=="function"&&Deno.unrefTimer(t),setTimeout(async()=>{await this.initializePromise,await this._autoRefreshTokenTick()},0)}async _stopAutoRefresh(){this._debug("#_stopAutoRefresh()");const t=this.autoRefreshTicker;this.autoRefreshTicker=null,t&&clearInterval(t)}async startAutoRefresh(){this._removeVisibilityChangedCallback(),await this._startAutoRefresh()}async stopAutoRefresh(){this._removeVisibilityChangedCallback(),await this._stopAutoRefresh()}async _autoRefreshTokenTick(){this._debug("#_autoRefreshTokenTick()","begin");try{await this._acquireLock(0,async()=>{try{const t=Date.now();try{return await this._useSession(async n=>{const{data:{session:r}}=n;if(!r||!r.refresh_token||!r.expires_at){this._debug("#_autoRefreshTokenTick()","no session");return}const i=Math.floor((r.expires_at*1e3-t)/Qn);this._debug("#_autoRefreshTokenTick()",`access token expires in ${i} ticks, a tick lasts ${Qn}ms, refresh threshold is ${Pu} ticks`),i<=Pu&&await this._callRefreshToken(r.refresh_token)})}catch(n){console.error("Auto refresh tick failed with error. This is likely a transient error.",n)}}finally{this._debug("#_autoRefreshTokenTick()","end")}})}catch(t){if(t.isAcquireTimeout||t instanceof dh)this._debug("auto refresh token tick lock not available");else throw t}}async _handleVisibilityChange(){if(this._debug("#_handleVisibilityChange()"),!Ue()||!(window!=null&&window.addEventListener))return this.autoRefreshToken&&this.startAutoRefresh(),!1;try{this.visibilityChangedCallback=async()=>await this._onVisibilityChanged(!1),window==null||window.addEventListener("visibilitychange",this.visibilityChangedCallback),await this._onVisibilityChanged(!0)}catch(t){console.error("_handleVisibilityChange",t)}}async _onVisibilityChanged(t){const n=`#_onVisibilityChanged(${t})`;this._debug(n,"visibilityState",document.visibilityState),document.visibilityState==="visible"?(this.autoRefreshToken&&this._startAutoRefresh(),t||(await this.initializePromise,await this._acquireLock(-1,async()=>{if(document.visibilityState!=="visible"){this._debug(n,"acquired the lock to recover the session, but the browser visibilityState is no longer visible, aborting");return}await this._recoverAndRefresh()}))):document.visibilityState==="hidden"&&this.autoRefreshToken&&this._stopAutoRefresh()}async _getUrlForProvider(t,n,r){const i=[`provider=${encodeURIComponent(n)}`];if(r!=null&&r.redirectTo&&i.push(`redirect_to=${encodeURIComponent(r.redirectTo)}`),r!=null&&r.scopes&&i.push(`scopes=${encodeURIComponent(r.scopes)}`),this.flowType==="pkce"){const[s,o]=await Zt(this.storage,this.storageKey),l=new URLSearchParams({code_challenge:`${encodeURIComponent(s)}`,code_challenge_method:`${encodeURIComponent(o)}`});i.push(l.toString())}if(r!=null&&r.queryParams){const s=new URLSearchParams(r.queryParams);i.push(s.toString())}return r!=null&&r.skipBrowserRedirect&&i.push(`skip_http_redirect=${r.skipBrowserRedirect}`),`${t}?${i.join("&")}`}async _unenroll(t){try{return await this._useSession(async n=>{var r;const{data:i,error:s}=n;return s?{data:null,error:s}:await N(this.fetch,"DELETE",`${this.url}/factors/${t.factorId}`,{headers:this.headers,jwt:(r=i==null?void 0:i.session)===null||r===void 0?void 0:r.access_token})})}catch(n){if(L(n))return{data:null,error:n};throw n}}async _enroll(t){try{return await this._useSession(async n=>{var r,i;const{data:s,error:o}=n;if(o)return{data:null,error:o};const{data:l,error:a}=await N(this.fetch,"POST",`${this.url}/factors`,{body:{friendly_name:t.friendlyName,factor_type:t.factorType,issuer:t.issuer},headers:this.headers,jwt:(r=s==null?void 0:s.session)===null||r===void 0?void 0:r.access_token});return a?{data:null,error:a}:(!((i=l==null?void 0:l.totp)===null||i===void 0)&&i.qr_code&&(l.totp.qr_code=`data:image/svg+xml;utf-8,${l.totp.qr_code}`),{data:l,error:null})})}catch(n){if(L(n))return{data:null,error:n};throw n}}async _verify(t){return this._acquireLock(-1,async()=>{try{return await this._useSession(async n=>{var r;const{data:i,error:s}=n;if(s)return{data:null,error:s};const{data:o,error:l}=await N(this.fetch,"POST",`${this.url}/factors/${t.factorId}/verify`,{body:{code:t.code,challenge_id:t.challengeId},headers:this.headers,jwt:(r=i==null?void 0:i.session)===null||r===void 0?void 0:r.access_token});return l?{data:null,error:l}:(await this._saveSession(Object.assign({expires_at:Math.round(Date.now()/1e3)+o.expires_in},o)),await this._notifyAllSubscribers("MFA_CHALLENGE_VERIFIED",o),{data:o,error:l})})}catch(n){if(L(n))return{data:null,error:n};throw n}})}async _challenge(t){return this._acquireLock(-1,async()=>{try{return await this._useSession(async n=>{var r;const{data:i,error:s}=n;return s?{data:null,error:s}:await N(this.fetch,"POST",`${this.url}/factors/${t.factorId}/challenge`,{headers:this.headers,jwt:(r=i==null?void 0:i.session)===null||r===void 0?void 0:r.access_token})})}catch(n){if(L(n))return{data:null,error:n};throw n}})}async _challengeAndVerify(t){const{data:n,error:r}=await this._challenge({factorId:t.factorId});return r?{data:null,error:r}:await this._verify({factorId:t.factorId,challengeId:n.id,code:t.code})}async _listFactors(){const{data:{user:t},error:n}=await this.getUser();if(n)return{data:null,error:n};const r=(t==null?void 0:t.factors)||[],i=r.filter(s=>s.factor_type==="totp"&&s.status==="verified");return{data:{all:r,totp:i},error:null}}async _getAuthenticatorAssuranceLevel(){return this._acquireLock(-1,async()=>await this._useSession(async t=>{var n,r;const{data:{session:i},error:s}=t;if(s)return{data:null,error:s};if(!i)return{data:{currentLevel:null,nextLevel:null,currentAuthenticationMethods:[]},error:null};const o=this._decodeJWT(i.access_token);let l=null;o.aal&&(l=o.aal);let a=l;((r=(n=i.user.factors)===null||n===void 0?void 0:n.filter(d=>d.status==="verified"))!==null&&r!==void 0?r:[]).length>0&&(a="aal2");const c=o.amr||[];return{data:{currentLevel:l,nextLevel:a,currentAuthenticationMethods:c},error:null}}))}}Rr.nextInstanceID=0;const gg=Rr;class yg extends gg{constructor(t){super(t)}}var wg=function(e,t,n,r){function i(s){return s instanceof n?s:new n(function(o){o(s)})}return new(n||(n=Promise))(function(s,o){function l(c){try{u(r.next(c))}catch(d){o(d)}}function a(c){try{u(r.throw(c))}catch(d){o(d)}}function u(c){c.done?s(c.value):i(c.value).then(l,a)}u((r=r.apply(e,t||[])).next())})};class _g{constructor(t,n,r){var i,s,o;if(this.supabaseUrl=t,this.supabaseKey=n,!t)throw new Error("supabaseUrl is required.");if(!n)throw new Error("supabaseKey is required.");const l=Uv(t);this.realtimeUrl=`${l}/realtime/v1`.replace(/^http/i,"ws"),this.authUrl=`${l}/auth/v1`,this.storageUrl=`${l}/storage/v1`,this.functionsUrl=`${l}/functions/v1`;const a=`sb-${new URL(this.authUrl).hostname.split(".")[0]}-auth-token`,u={db:Rv,realtime:Lv,auth:Object.assign(Object.assign({},jv),{storageKey:a}),global:Ov},c=Dv(r??{},u);this.storageKey=(i=c.auth.storageKey)!==null&&i!==void 0?i:"",this.headers=(s=c.global.headers)!==null&&s!==void 0?s:{},this.auth=this._initSupabaseAuthClient((o=c.auth)!==null&&o!==void 0?o:{},this.headers,c.global.fetch),this.fetch=Av(n,this._getAccessToken.bind(this),c.global.fetch),this.realtime=this._initRealtimeClient(Object.assign({headers:this.headers},c.realtime)),this.rest=new Hl(`${l}/rest/v1`,{headers:this.headers,schema:c.db.schema,fetch:this.fetch}),this._listenForAuthEvents()}get functions(){return new Bm(this.functionsUrl,{headers:this.headers,customFetch:this.fetch})}get storage(){return new xv(this.storageUrl,this.headers,this.fetch)}from(t){return this.rest.from(t)}schema(t){return this.rest.schema(t)}rpc(t,n={},r={}){return this.rest.rpc(t,n,r)}channel(t,n={config:{}}){return this.realtime.channel(t,n)}getChannels(){return this.realtime.getChannels()}removeChannel(t){return this.realtime.removeChannel(t)}removeAllChannels(){return this.realtime.removeAllChannels()}_getAccessToken(){var t,n;return wg(this,void 0,void 0,function*(){const{data:r}=yield this.auth.getSession();return(n=(t=r.session)===null||t===void 0?void 0:t.access_token)!==null&&n!==void 0?n:null})}_initSupabaseAuthClient({autoRefreshToken:t,persistSession:n,detectSessionInUrl:r,storage:i,storageKey:s,flowType:o,debug:l},a,u){var c;const d={Authorization:`Bearer ${this.supabaseKey}`,apikey:`${this.supabaseKey}`};return new yg({url:this.authUrl,headers:Object.assign(Object.assign({},d),a),storageKey:s,autoRefreshToken:t,persistSession:n,detectSessionInUrl:r,storage:i,flowType:o,debug:l,fetch:u,hasCustomAuthorizationHeader:(c="Authorization"in this.headers)!==null&&c!==void 0?c:!1})}_initRealtimeClient(t){return new hv(this.realtimeUrl,Object.assign(Object.assign({},t),{params:Object.assign({apikey:this.supabaseKey},t==null?void 0:t.params)}))}_listenForAuthEvents(){return this.auth.onAuthStateChange((n,r)=>{this._handleTokenChanged(n,"CLIENT",r==null?void 0:r.access_token)})}_handleTokenChanged(t,n,r){(t==="TOKEN_REFRESHED"||t==="SIGNED_IN")&&this.changedAccessToken!==r?(this.realtime.setAuth(r??null),this.changedAccessToken=r):t==="SIGNED_OUT"&&(this.realtime.setAuth(this.supabaseKey),n=="STORAGE"&&this.auth.signOut(),this.changedAccessToken=void 0)}}const kg=(e,t,n)=>new _g(e,t,n);function Sg(e){const t=Yd(),[n,r]=x.useState([]);x.useEffect(()=>{e.session||t("/login")},[e.session]);const i=x.useCallback(async()=>{const{data:s,error:o}=await e.supabase.from("file").select();if(o){console.error(o);return}r(s.map(l=>l))},[e.supabase]);return x.useEffect(()=>{i()},[]),z.jsx(z.Fragment,{children:z.jsxs("div",{children:[z.jsx("h1",{children:"Home"}),z.jsx("p",{children:"Logged in!"}),n.map(s=>z.jsx("div",{children:z.jsxs("p",{children:["file: ",s.absolute_path]})},s.id))]})})}function Eg(e){const t=Yd();return x.useEffect(()=>{window.HandleSignInWithGoogle=async r=>{await e.supabase.auth.signInWithIdToken({provider:"google",token:r.credential})},e.supabase.auth.getSession().then(({data:{session:r}})=>{e.setSession(r),console.log("LOGIN SESSION",r)});const{data:{subscription:n}}=e.supabase.auth.onAuthStateChange((r,i)=>{e.setSession(i),console.log("SESSION CHANGE",i)});return()=>n.unsubscribe()},[]),x.useEffect(()=>{e.session&&t("/")},[e.session]),z.jsxs(z.Fragment,{children:[z.jsxs("div",{children:[z.jsx("h1",{children:"Login"}),z.jsxs("p",{children:["Log in to access your account! ",JSON.stringify(e.session)]})]}),z.jsx("div",{id:"g_id_onload","data-client_id":"952965459060-nrnrsdoq22mf646vfa72hk410pvdda5q.apps.googleusercontent.com","data-context":"signin","data-ux_mode":"popup","data-callback":"HandleSignInWithGoogle","data-auto_prompt":"false"}),z.jsx("div",{className:"g_id_signin","data-type":"standard","data-shape":"pill","data-theme":"outline","data-text":"signin","data-size":"large","data-logo_alignment":"center"})]})}const Ou=kg("https://slpoocycjgqsuoedhkbn.supabase.co","eyJhbGciOiJIUzI1NiIsInR5cCI6IkpXVCJ9.eyJpc3MiOiJzdXBhYmFzZSIsInJlZiI6InNscG9vY3ljamdxc3VvZWRoa2JuIiwicm9sZSI6ImFub24iLCJpYXQiOjE3MTUyMDU0MjUsImV4cCI6MjAzMDc4MTQyNX0.xZYRTRN65rlms1Hb96IBAQvw3EGtMzUxlGPP5TVey34");function Cg(){const[e,t]=x.useState(null);return z.jsx(z.Fragment,{children:z.jsx(Nm,{basename:"/fs-tracer-frontend",children:z.jsxs(Lm,{children:[z.jsx(vi,{index:!0,element:z.jsx(Sg,{supabase:Ou,session:e})}),z.jsx(vi,{path:"login",element:z.jsx(Eg,{supabase:Ou,session:e,setSession:t})}),z.jsx(vi,{path:"*",element:z.jsx("p",{children:"notfound"})})]})})})}Ws.createRoot(document.getElementById("root")).render(z.jsx(Fu.StrictMode,{children:z.jsx(Cg,{})}));export{ph as g}; diff --git a/index.html b/index.html index 5630b49..123aba8 100644 --- a/index.html +++ b/index.html @@ -30,7 +30,7 @@ }(window.location)) </script> <!-- End Single Page Apps for GitHub Pages --> - <script type="module" crossorigin src="./assets/index-CYv8RTDj.js"></script> + <script type="module" crossorigin src="./assets/index-B-cH4mZc.js"></script> <link rel="stylesheet" crossorigin href="./assets/index-Bx9V9zN2.css"> </head> <body> |