1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
|
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-CLk4meQ0.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,{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};
|