@alfatech/livechat 2025.4.0-7.1 → 2025.4.0-8.1

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
package/dist/main.js CHANGED
@@ -1,4 +1,4 @@
1
- var kd=e=>{throw TypeError(e)};var ov=(e,t)=>()=>(t||e((t={exports:{}}).exports,t),t.exports);var $a=(e,t,n)=>t.has(e)||kd("Cannot "+n);var g=(e,t,n)=>($a(e,t,"read from private field"),n?n.call(e):t.get(e)),U=(e,t,n)=>t.has(e)?kd("Cannot add the same private member more than once"):t instanceof WeakSet?t.add(e):t.set(e,n),j=(e,t,n,r)=>($a(e,t,"write to private field"),r?r.call(e,n):t.set(e,n),n),q=(e,t,n)=>($a(e,t,"access private method"),n);var So=(e,t,n,r)=>({set _(i){j(e,t,i,n)},get _(){return g(e,t,r)}});var OO=ov((yt,vt)=>{function lv(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 Ki(e){return e&&e.__esModule&&Object.prototype.hasOwnProperty.call(e,"default")?e.default:e}var nm={exports:{}},Hl={},rm={exports:{}},Y={};/**
1
+ var kd=e=>{throw TypeError(e)};var lv=(e,t)=>()=>(t||e((t={exports:{}}).exports,t),t.exports);var $a=(e,t,n)=>t.has(e)||kd("Cannot "+n);var y=(e,t,n)=>($a(e,t,"read from private field"),n?n.call(e):t.get(e)),U=(e,t,n)=>t.has(e)?kd("Cannot add the same private member more than once"):t instanceof WeakSet?t.add(e):t.set(e,n),j=(e,t,n,r)=>($a(e,t,"write to private field"),r?r.call(e,n):t.set(e,n),n),q=(e,t,n)=>($a(e,t,"access private method"),n);var So=(e,t,n,r)=>({set _(i){j(e,t,i,n)},get _(){return y(e,t,r)}});var RO=lv((vt,wt)=>{function av(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 Ki(e){return e&&e.__esModule&&Object.prototype.hasOwnProperty.call(e,"default")?e.default:e}var nm={exports:{}},Hl={},rm={exports:{}},Y={};/**
2
2
  * @license React
3
3
  * react.production.min.js
4
4
  *
@@ -6,7 +6,7 @@ var kd=e=>{throw TypeError(e)};var ov=(e,t)=>()=>(t||e((t={exports:{}}).exports,
6
6
  *
7
7
  * This source code is licensed under the MIT license found in the
8
8
  * LICENSE file in the root directory of this source tree.
9
- */var io=Symbol.for("react.element"),av=Symbol.for("react.portal"),uv=Symbol.for("react.fragment"),cv=Symbol.for("react.strict_mode"),fv=Symbol.for("react.profiler"),dv=Symbol.for("react.provider"),hv=Symbol.for("react.context"),pv=Symbol.for("react.forward_ref"),mv=Symbol.for("react.suspense"),gv=Symbol.for("react.memo"),yv=Symbol.for("react.lazy"),Cd=Symbol.iterator;function vv(e){return e===null||typeof e!="object"?null:(e=Cd&&e[Cd]||e["@@iterator"],typeof e=="function"?e:null)}var im={isMounted:function(){return!1},enqueueForceUpdate:function(){},enqueueReplaceState:function(){},enqueueSetState:function(){}},sm=Object.assign,om={};function Yi(e,t,n){this.props=e,this.context=t,this.refs=om,this.updater=n||im}Yi.prototype.isReactComponent={};Yi.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")};Yi.prototype.forceUpdate=function(e){this.updater.enqueueForceUpdate(this,e,"forceUpdate")};function lm(){}lm.prototype=Yi.prototype;function Yc(e,t,n){this.props=e,this.context=t,this.refs=om,this.updater=n||im}var Gc=Yc.prototype=new lm;Gc.constructor=Yc;sm(Gc,Yi.prototype);Gc.isPureReactComponent=!0;var Td=Array.isArray,am=Object.prototype.hasOwnProperty,Xc={current:null},um={key:!0,ref:!0,__self:!0,__source:!0};function cm(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)am.call(t,r)&&!um.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),c=0;c<l;c++)a[c]=arguments[c+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:io,type:e,key:s,ref:o,props:i,_owner:Xc.current}}function wv(e,t){return{$$typeof:io,type:e.type,key:t,ref:e.ref,props:e.props,_owner:e._owner}}function Zc(e){return typeof e=="object"&&e!==null&&e.$$typeof===io}function xv(e){var t={"=":"=0",":":"=2"};return"$"+e.replace(/[=:]/g,function(n){return t[n]})}var Od=/\/+/g;function Ia(e,t){return typeof e=="object"&&e!==null&&e.key!=null?xv(""+e.key):t.toString(36)}function Qo(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 io:case av:o=!0}}if(o)return o=e,i=i(o),e=r===""?"."+Ia(o,0):r,Td(i)?(n="",e!=null&&(n=e.replace(Od,"$&/")+"/"),Qo(i,t,n,"",function(c){return c})):i!=null&&(Zc(i)&&(i=wv(i,n+(!i.key||o&&o.key===i.key?"":(""+i.key).replace(Od,"$&/")+"/")+e)),t.push(i)),1;if(o=0,r=r===""?".":r+":",Td(e))for(var l=0;l<e.length;l++){s=e[l];var a=r+Ia(s,l);o+=Qo(s,t,n,a,i)}else if(a=vv(e),typeof a=="function")for(e=a.call(e),l=0;!(s=e.next()).done;)s=s.value,a=r+Ia(s,l++),o+=Qo(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 bo(e,t,n){if(e==null)return e;var r=[],i=0;return Qo(e,r,"","",function(s){return t.call(n,s,i++)}),r}function Sv(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 Xe={current:null},qo={transition:null},bv={ReactCurrentDispatcher:Xe,ReactCurrentBatchConfig:qo,ReactCurrentOwner:Xc};function fm(){throw Error("act(...) is not supported in production builds of React.")}Y.Children={map:bo,forEach:function(e,t,n){bo(e,function(){t.apply(this,arguments)},n)},count:function(e){var t=0;return bo(e,function(){t++}),t},toArray:function(e){return bo(e,function(t){return t})||[]},only:function(e){if(!Zc(e))throw Error("React.Children.only expected to receive a single React element child.");return e}};Y.Component=Yi;Y.Fragment=uv;Y.Profiler=fv;Y.PureComponent=Yc;Y.StrictMode=cv;Y.Suspense=mv;Y.__SECRET_INTERNALS_DO_NOT_USE_OR_YOU_WILL_BE_FIRED=bv;Y.act=fm;Y.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=sm({},e.props),i=e.key,s=e.ref,o=e._owner;if(t!=null){if(t.ref!==void 0&&(s=t.ref,o=Xc.current),t.key!==void 0&&(i=""+t.key),e.type&&e.type.defaultProps)var l=e.type.defaultProps;for(a in t)am.call(t,a)&&!um.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 c=0;c<a;c++)l[c]=arguments[c+2];r.children=l}return{$$typeof:io,type:e.type,key:i,ref:s,props:r,_owner:o}};Y.createContext=function(e){return e={$$typeof:hv,_currentValue:e,_currentValue2:e,_threadCount:0,Provider:null,Consumer:null,_defaultValue:null,_globalName:null},e.Provider={$$typeof:dv,_context:e},e.Consumer=e};Y.createElement=cm;Y.createFactory=function(e){var t=cm.bind(null,e);return t.type=e,t};Y.createRef=function(){return{current:null}};Y.forwardRef=function(e){return{$$typeof:pv,render:e}};Y.isValidElement=Zc;Y.lazy=function(e){return{$$typeof:yv,_payload:{_status:-1,_result:e},_init:Sv}};Y.memo=function(e,t){return{$$typeof:gv,type:e,compare:t===void 0?null:t}};Y.startTransition=function(e){var t=qo.transition;qo.transition={};try{e()}finally{qo.transition=t}};Y.unstable_act=fm;Y.useCallback=function(e,t){return Xe.current.useCallback(e,t)};Y.useContext=function(e){return Xe.current.useContext(e)};Y.useDebugValue=function(){};Y.useDeferredValue=function(e){return Xe.current.useDeferredValue(e)};Y.useEffect=function(e,t){return Xe.current.useEffect(e,t)};Y.useId=function(){return Xe.current.useId()};Y.useImperativeHandle=function(e,t,n){return Xe.current.useImperativeHandle(e,t,n)};Y.useInsertionEffect=function(e,t){return Xe.current.useInsertionEffect(e,t)};Y.useLayoutEffect=function(e,t){return Xe.current.useLayoutEffect(e,t)};Y.useMemo=function(e,t){return Xe.current.useMemo(e,t)};Y.useReducer=function(e,t,n){return Xe.current.useReducer(e,t,n)};Y.useRef=function(e){return Xe.current.useRef(e)};Y.useState=function(e){return Xe.current.useState(e)};Y.useSyncExternalStore=function(e,t,n){return Xe.current.useSyncExternalStore(e,t,n)};Y.useTransition=function(){return Xe.current.useTransition()};Y.version="18.3.1";rm.exports=Y;var b=rm.exports;const N=Ki(b),Ev=lv({__proto__:null,default:N},[b]);/**
9
+ */var io=Symbol.for("react.element"),uv=Symbol.for("react.portal"),cv=Symbol.for("react.fragment"),fv=Symbol.for("react.strict_mode"),dv=Symbol.for("react.profiler"),hv=Symbol.for("react.provider"),pv=Symbol.for("react.context"),mv=Symbol.for("react.forward_ref"),yv=Symbol.for("react.suspense"),gv=Symbol.for("react.memo"),vv=Symbol.for("react.lazy"),Cd=Symbol.iterator;function wv(e){return e===null||typeof e!="object"?null:(e=Cd&&e[Cd]||e["@@iterator"],typeof e=="function"?e:null)}var im={isMounted:function(){return!1},enqueueForceUpdate:function(){},enqueueReplaceState:function(){},enqueueSetState:function(){}},sm=Object.assign,om={};function Yi(e,t,n){this.props=e,this.context=t,this.refs=om,this.updater=n||im}Yi.prototype.isReactComponent={};Yi.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")};Yi.prototype.forceUpdate=function(e){this.updater.enqueueForceUpdate(this,e,"forceUpdate")};function lm(){}lm.prototype=Yi.prototype;function Yc(e,t,n){this.props=e,this.context=t,this.refs=om,this.updater=n||im}var Gc=Yc.prototype=new lm;Gc.constructor=Yc;sm(Gc,Yi.prototype);Gc.isPureReactComponent=!0;var Td=Array.isArray,am=Object.prototype.hasOwnProperty,Xc={current:null},um={key:!0,ref:!0,__self:!0,__source:!0};function cm(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)am.call(t,r)&&!um.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),c=0;c<l;c++)a[c]=arguments[c+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:io,type:e,key:s,ref:o,props:i,_owner:Xc.current}}function xv(e,t){return{$$typeof:io,type:e.type,key:t,ref:e.ref,props:e.props,_owner:e._owner}}function Zc(e){return typeof e=="object"&&e!==null&&e.$$typeof===io}function Sv(e){var t={"=":"=0",":":"=2"};return"$"+e.replace(/[=:]/g,function(n){return t[n]})}var Od=/\/+/g;function Ia(e,t){return typeof e=="object"&&e!==null&&e.key!=null?Sv(""+e.key):t.toString(36)}function Qo(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 io:case uv:o=!0}}if(o)return o=e,i=i(o),e=r===""?"."+Ia(o,0):r,Td(i)?(n="",e!=null&&(n=e.replace(Od,"$&/")+"/"),Qo(i,t,n,"",function(c){return c})):i!=null&&(Zc(i)&&(i=xv(i,n+(!i.key||o&&o.key===i.key?"":(""+i.key).replace(Od,"$&/")+"/")+e)),t.push(i)),1;if(o=0,r=r===""?".":r+":",Td(e))for(var l=0;l<e.length;l++){s=e[l];var a=r+Ia(s,l);o+=Qo(s,t,n,a,i)}else if(a=wv(e),typeof a=="function")for(e=a.call(e),l=0;!(s=e.next()).done;)s=s.value,a=r+Ia(s,l++),o+=Qo(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 bo(e,t,n){if(e==null)return e;var r=[],i=0;return Qo(e,r,"","",function(s){return t.call(n,s,i++)}),r}function bv(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 Xe={current:null},qo={transition:null},Ev={ReactCurrentDispatcher:Xe,ReactCurrentBatchConfig:qo,ReactCurrentOwner:Xc};function fm(){throw Error("act(...) is not supported in production builds of React.")}Y.Children={map:bo,forEach:function(e,t,n){bo(e,function(){t.apply(this,arguments)},n)},count:function(e){var t=0;return bo(e,function(){t++}),t},toArray:function(e){return bo(e,function(t){return t})||[]},only:function(e){if(!Zc(e))throw Error("React.Children.only expected to receive a single React element child.");return e}};Y.Component=Yi;Y.Fragment=cv;Y.Profiler=dv;Y.PureComponent=Yc;Y.StrictMode=fv;Y.Suspense=yv;Y.__SECRET_INTERNALS_DO_NOT_USE_OR_YOU_WILL_BE_FIRED=Ev;Y.act=fm;Y.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=sm({},e.props),i=e.key,s=e.ref,o=e._owner;if(t!=null){if(t.ref!==void 0&&(s=t.ref,o=Xc.current),t.key!==void 0&&(i=""+t.key),e.type&&e.type.defaultProps)var l=e.type.defaultProps;for(a in t)am.call(t,a)&&!um.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 c=0;c<a;c++)l[c]=arguments[c+2];r.children=l}return{$$typeof:io,type:e.type,key:i,ref:s,props:r,_owner:o}};Y.createContext=function(e){return e={$$typeof:pv,_currentValue:e,_currentValue2:e,_threadCount:0,Provider:null,Consumer:null,_defaultValue:null,_globalName:null},e.Provider={$$typeof:hv,_context:e},e.Consumer=e};Y.createElement=cm;Y.createFactory=function(e){var t=cm.bind(null,e);return t.type=e,t};Y.createRef=function(){return{current:null}};Y.forwardRef=function(e){return{$$typeof:mv,render:e}};Y.isValidElement=Zc;Y.lazy=function(e){return{$$typeof:vv,_payload:{_status:-1,_result:e},_init:bv}};Y.memo=function(e,t){return{$$typeof:gv,type:e,compare:t===void 0?null:t}};Y.startTransition=function(e){var t=qo.transition;qo.transition={};try{e()}finally{qo.transition=t}};Y.unstable_act=fm;Y.useCallback=function(e,t){return Xe.current.useCallback(e,t)};Y.useContext=function(e){return Xe.current.useContext(e)};Y.useDebugValue=function(){};Y.useDeferredValue=function(e){return Xe.current.useDeferredValue(e)};Y.useEffect=function(e,t){return Xe.current.useEffect(e,t)};Y.useId=function(){return Xe.current.useId()};Y.useImperativeHandle=function(e,t,n){return Xe.current.useImperativeHandle(e,t,n)};Y.useInsertionEffect=function(e,t){return Xe.current.useInsertionEffect(e,t)};Y.useLayoutEffect=function(e,t){return Xe.current.useLayoutEffect(e,t)};Y.useMemo=function(e,t){return Xe.current.useMemo(e,t)};Y.useReducer=function(e,t,n){return Xe.current.useReducer(e,t,n)};Y.useRef=function(e){return Xe.current.useRef(e)};Y.useState=function(e){return Xe.current.useState(e)};Y.useSyncExternalStore=function(e,t,n){return Xe.current.useSyncExternalStore(e,t,n)};Y.useTransition=function(){return Xe.current.useTransition()};Y.version="18.3.1";rm.exports=Y;var b=rm.exports;const N=Ki(b),_v=av({__proto__:null,default:N},[b]);/**
10
10
  * @license React
11
11
  * react-jsx-runtime.production.min.js
12
12
  *
@@ -14,7 +14,7 @@ var kd=e=>{throw TypeError(e)};var ov=(e,t)=>()=>(t||e((t={exports:{}}).exports,
14
14
  *
15
15
  * This source code is licensed under the MIT license found in the
16
16
  * LICENSE file in the root directory of this source tree.
17
- */var _v=b,kv=Symbol.for("react.element"),Cv=Symbol.for("react.fragment"),Tv=Object.prototype.hasOwnProperty,Ov=_v.__SECRET_INTERNALS_DO_NOT_USE_OR_YOU_WILL_BE_FIRED.ReactCurrentOwner,Rv={key:!0,ref:!0,__self:!0,__source:!0};function dm(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)Tv.call(t,r)&&!Rv.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:kv,type:e,key:s,ref:o,props:i,_owner:Ov.current}}Hl.Fragment=Cv;Hl.jsx=dm;Hl.jsxs=dm;nm.exports=Hl;var _=nm.exports,hm={exports:{}},St={},pm={exports:{}},mm={};/**
17
+ */var kv=b,Cv=Symbol.for("react.element"),Tv=Symbol.for("react.fragment"),Ov=Object.prototype.hasOwnProperty,Rv=kv.__SECRET_INTERNALS_DO_NOT_USE_OR_YOU_WILL_BE_FIRED.ReactCurrentOwner,Nv={key:!0,ref:!0,__self:!0,__source:!0};function dm(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)Ov.call(t,r)&&!Nv.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:Cv,type:e,key:s,ref:o,props:i,_owner:Rv.current}}Hl.Fragment=Tv;Hl.jsx=dm;Hl.jsxs=dm;nm.exports=Hl;var _=nm.exports,hm={exports:{}},bt={},pm={exports:{}},mm={};/**
18
18
  * @license React
19
19
  * scheduler.production.min.js
20
20
  *
@@ -22,7 +22,7 @@ var kd=e=>{throw TypeError(e)};var ov=(e,t)=>()=>(t||e((t={exports:{}}).exports,
22
22
  *
23
23
  * This source code is licensed under the MIT license found in the
24
24
  * LICENSE file in the root directory of this source tree.
25
- */(function(e){function t(P,L){var H=P.length;P.push(L);e:for(;0<H;){var M=H-1>>>1,V=P[M];if(0<i(V,L))P[M]=L,P[H]=V,H=M;else break e}}function n(P){return P.length===0?null:P[0]}function r(P){if(P.length===0)return null;var L=P[0],H=P.pop();if(H!==L){P[0]=H;e:for(var M=0,V=P.length,ee=V>>>1;M<ee;){var de=2*(M+1)-1,Ce=P[de],Z=de+1,Je=P[Z];if(0>i(Ce,H))Z<V&&0>i(Je,Ce)?(P[M]=Je,P[Z]=H,M=Z):(P[M]=Ce,P[de]=H,M=de);else if(Z<V&&0>i(Je,H))P[M]=Je,P[Z]=H,M=Z;else break e}}return L}function i(P,L){var H=P.sortIndex-L.sortIndex;return H!==0?H:P.id-L.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=[],c=[],f=1,u=null,d=3,h=!1,v=!1,w=!1,S=typeof setTimeout=="function"?setTimeout:null,m=typeof clearTimeout=="function"?clearTimeout:null,p=typeof setImmediate<"u"?setImmediate:null;typeof navigator<"u"&&navigator.scheduling!==void 0&&navigator.scheduling.isInputPending!==void 0&&navigator.scheduling.isInputPending.bind(navigator.scheduling);function y(P){for(var L=n(c);L!==null;){if(L.callback===null)r(c);else if(L.startTime<=P)r(c),L.sortIndex=L.expirationTime,t(a,L);else break;L=n(c)}}function x(P){if(w=!1,y(P),!v)if(n(a)!==null)v=!0,K(C);else{var L=n(c);L!==null&&Qe(x,L.startTime-P)}}function C(P,L){v=!1,w&&(w=!1,m(R),R=-1),h=!0;var H=d;try{for(y(L),u=n(a);u!==null&&(!(u.expirationTime>L)||P&&!B());){var M=u.callback;if(typeof M=="function"){u.callback=null,d=u.priorityLevel;var V=M(u.expirationTime<=L);L=e.unstable_now(),typeof V=="function"?u.callback=V:u===n(a)&&r(a),y(L)}else r(a);u=n(a)}if(u!==null)var ee=!0;else{var de=n(c);de!==null&&Qe(x,de.startTime-L),ee=!1}return ee}finally{u=null,d=H,h=!1}}var T=!1,k=null,R=-1,I=5,D=-1;function B(){return!(e.unstable_now()-D<I)}function se(){if(k!==null){var P=e.unstable_now();D=P;var L=!0;try{L=k(!0,P)}finally{L?oe():(T=!1,k=null)}}else T=!1}var oe;if(typeof p=="function")oe=function(){p(se)};else if(typeof MessageChannel<"u"){var He=new MessageChannel,We=He.port2;He.port1.onmessage=se,oe=function(){We.postMessage(null)}}else oe=function(){S(se,0)};function K(P){k=P,T||(T=!0,oe())}function Qe(P,L){R=S(function(){P(e.unstable_now())},L)}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(P){P.callback=null},e.unstable_continueExecution=function(){v||h||(v=!0,K(C))},e.unstable_forceFrameRate=function(P){0>P||125<P?console.error("forceFrameRate takes a positive int between 0 and 125, forcing frame rates higher than 125 fps is not supported"):I=0<P?Math.floor(1e3/P):5},e.unstable_getCurrentPriorityLevel=function(){return d},e.unstable_getFirstCallbackNode=function(){return n(a)},e.unstable_next=function(P){switch(d){case 1:case 2:case 3:var L=3;break;default:L=d}var H=d;d=L;try{return P()}finally{d=H}},e.unstable_pauseExecution=function(){},e.unstable_requestPaint=function(){},e.unstable_runWithPriority=function(P,L){switch(P){case 1:case 2:case 3:case 4:case 5:break;default:P=3}var H=d;d=P;try{return L()}finally{d=H}},e.unstable_scheduleCallback=function(P,L,H){var M=e.unstable_now();switch(typeof H=="object"&&H!==null?(H=H.delay,H=typeof H=="number"&&0<H?M+H:M):H=M,P){case 1:var V=-1;break;case 2:V=250;break;case 5:V=1073741823;break;case 4:V=1e4;break;default:V=5e3}return V=H+V,P={id:f++,callback:L,priorityLevel:P,startTime:H,expirationTime:V,sortIndex:-1},H>M?(P.sortIndex=H,t(c,P),n(a)===null&&P===n(c)&&(w?(m(R),R=-1):w=!0,Qe(x,H-M))):(P.sortIndex=V,t(a,P),v||h||(v=!0,K(C))),P},e.unstable_shouldYield=B,e.unstable_wrapCallback=function(P){var L=d;return function(){var H=d;d=L;try{return P.apply(this,arguments)}finally{d=H}}}})(mm);pm.exports=mm;var Nv=pm.exports;/**
25
+ */(function(e){function t(P,D){var H=P.length;P.push(D);e:for(;0<H;){var M=H-1>>>1,V=P[M];if(0<i(V,D))P[M]=D,P[H]=V,H=M;else break e}}function n(P){return P.length===0?null:P[0]}function r(P){if(P.length===0)return null;var D=P[0],H=P.pop();if(H!==D){P[0]=H;e:for(var M=0,V=P.length,ee=V>>>1;M<ee;){var de=2*(M+1)-1,Ce=P[de],Z=de+1,Je=P[Z];if(0>i(Ce,H))Z<V&&0>i(Je,Ce)?(P[M]=Je,P[Z]=H,M=Z):(P[M]=Ce,P[de]=H,M=de);else if(Z<V&&0>i(Je,H))P[M]=Je,P[Z]=H,M=Z;else break e}}return D}function i(P,D){var H=P.sortIndex-D.sortIndex;return H!==0?H:P.id-D.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=[],c=[],f=1,u=null,d=3,h=!1,v=!1,w=!1,S=typeof setTimeout=="function"?setTimeout:null,m=typeof clearTimeout=="function"?clearTimeout:null,p=typeof setImmediate<"u"?setImmediate:null;typeof navigator<"u"&&navigator.scheduling!==void 0&&navigator.scheduling.isInputPending!==void 0&&navigator.scheduling.isInputPending.bind(navigator.scheduling);function g(P){for(var D=n(c);D!==null;){if(D.callback===null)r(c);else if(D.startTime<=P)r(c),D.sortIndex=D.expirationTime,t(a,D);else break;D=n(c)}}function x(P){if(w=!1,g(P),!v)if(n(a)!==null)v=!0,K(C);else{var D=n(c);D!==null&&Qe(x,D.startTime-P)}}function C(P,D){v=!1,w&&(w=!1,m(R),R=-1),h=!0;var H=d;try{for(g(D),u=n(a);u!==null&&(!(u.expirationTime>D)||P&&!B());){var M=u.callback;if(typeof M=="function"){u.callback=null,d=u.priorityLevel;var V=M(u.expirationTime<=D);D=e.unstable_now(),typeof V=="function"?u.callback=V:u===n(a)&&r(a),g(D)}else r(a);u=n(a)}if(u!==null)var ee=!0;else{var de=n(c);de!==null&&Qe(x,de.startTime-D),ee=!1}return ee}finally{u=null,d=H,h=!1}}var T=!1,k=null,R=-1,I=5,L=-1;function B(){return!(e.unstable_now()-L<I)}function se(){if(k!==null){var P=e.unstable_now();L=P;var D=!0;try{D=k(!0,P)}finally{D?oe():(T=!1,k=null)}}else T=!1}var oe;if(typeof p=="function")oe=function(){p(se)};else if(typeof MessageChannel<"u"){var He=new MessageChannel,We=He.port2;He.port1.onmessage=se,oe=function(){We.postMessage(null)}}else oe=function(){S(se,0)};function K(P){k=P,T||(T=!0,oe())}function Qe(P,D){R=S(function(){P(e.unstable_now())},D)}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(P){P.callback=null},e.unstable_continueExecution=function(){v||h||(v=!0,K(C))},e.unstable_forceFrameRate=function(P){0>P||125<P?console.error("forceFrameRate takes a positive int between 0 and 125, forcing frame rates higher than 125 fps is not supported"):I=0<P?Math.floor(1e3/P):5},e.unstable_getCurrentPriorityLevel=function(){return d},e.unstable_getFirstCallbackNode=function(){return n(a)},e.unstable_next=function(P){switch(d){case 1:case 2:case 3:var D=3;break;default:D=d}var H=d;d=D;try{return P()}finally{d=H}},e.unstable_pauseExecution=function(){},e.unstable_requestPaint=function(){},e.unstable_runWithPriority=function(P,D){switch(P){case 1:case 2:case 3:case 4:case 5:break;default:P=3}var H=d;d=P;try{return D()}finally{d=H}},e.unstable_scheduleCallback=function(P,D,H){var M=e.unstable_now();switch(typeof H=="object"&&H!==null?(H=H.delay,H=typeof H=="number"&&0<H?M+H:M):H=M,P){case 1:var V=-1;break;case 2:V=250;break;case 5:V=1073741823;break;case 4:V=1e4;break;default:V=5e3}return V=H+V,P={id:f++,callback:D,priorityLevel:P,startTime:H,expirationTime:V,sortIndex:-1},H>M?(P.sortIndex=H,t(c,P),n(a)===null&&P===n(c)&&(w?(m(R),R=-1):w=!0,Qe(x,H-M))):(P.sortIndex=V,t(a,P),v||h||(v=!0,K(C))),P},e.unstable_shouldYield=B,e.unstable_wrapCallback=function(P){var D=d;return function(){var H=d;d=D;try{return P.apply(this,arguments)}finally{d=H}}}})(mm);pm.exports=mm;var Pv=pm.exports;/**
26
26
  * @license React
27
27
  * react-dom.production.min.js
28
28
  *
@@ -30,14 +30,14 @@ var kd=e=>{throw TypeError(e)};var ov=(e,t)=>()=>(t||e((t={exports:{}}).exports,
30
30
  *
31
31
  * This source code is licensed under the MIT license found in the
32
32
  * LICENSE file in the root directory of this source tree.
33
- */var Pv=b,xt=Nv;function O(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 gm=new Set,Ps={};function Kr(e,t){Mi(e,t),Mi(e+"Capture",t)}function Mi(e,t){for(Ps[e]=t,e=0;e<t.length;e++)gm.add(t[e])}var Cn=!(typeof window>"u"||typeof window.document>"u"||typeof window.document.createElement>"u"),bu=Object.prototype.hasOwnProperty,Av=/^[: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]*$/,Rd={},Nd={};function jv(e){return bu.call(Nd,e)?!0:bu.call(Rd,e)?!1:Av.test(e)?Nd[e]=!0:(Rd[e]=!0,!1)}function Fv(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 $v(e,t,n,r){if(t===null||typeof t>"u"||Fv(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 Ze(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 Ie={};"children dangerouslySetInnerHTML defaultValue defaultChecked innerHTML suppressContentEditableWarning suppressHydrationWarning style".split(" ").forEach(function(e){Ie[e]=new Ze(e,0,!1,e,null,!1,!1)});[["acceptCharset","accept-charset"],["className","class"],["htmlFor","for"],["httpEquiv","http-equiv"]].forEach(function(e){var t=e[0];Ie[t]=new Ze(t,1,!1,e[1],null,!1,!1)});["contentEditable","draggable","spellCheck","value"].forEach(function(e){Ie[e]=new Ze(e,2,!1,e.toLowerCase(),null,!1,!1)});["autoReverse","externalResourcesRequired","focusable","preserveAlpha"].forEach(function(e){Ie[e]=new Ze(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){Ie[e]=new Ze(e,3,!1,e.toLowerCase(),null,!1,!1)});["checked","multiple","muted","selected"].forEach(function(e){Ie[e]=new Ze(e,3,!0,e,null,!1,!1)});["capture","download"].forEach(function(e){Ie[e]=new Ze(e,4,!1,e,null,!1,!1)});["cols","rows","size","span"].forEach(function(e){Ie[e]=new Ze(e,6,!1,e,null,!1,!1)});["rowSpan","start"].forEach(function(e){Ie[e]=new Ze(e,5,!1,e.toLowerCase(),null,!1,!1)});var Jc=/[\-:]([a-z])/g;function ef(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(Jc,ef);Ie[t]=new Ze(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(Jc,ef);Ie[t]=new Ze(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(Jc,ef);Ie[t]=new Ze(t,1,!1,e,"http://www.w3.org/XML/1998/namespace",!1,!1)});["tabIndex","crossOrigin"].forEach(function(e){Ie[e]=new Ze(e,1,!1,e.toLowerCase(),null,!1,!1)});Ie.xlinkHref=new Ze("xlinkHref",1,!1,"xlink:href","http://www.w3.org/1999/xlink",!0,!1);["src","href","action","formAction"].forEach(function(e){Ie[e]=new Ze(e,1,!1,e.toLowerCase(),null,!0,!0)});function tf(e,t,n,r){var i=Ie.hasOwnProperty(t)?Ie[t]:null;(i!==null?i.type!==0:r||!(2<t.length)||t[0]!=="o"&&t[0]!=="O"||t[1]!=="n"&&t[1]!=="N")&&($v(t,n,i,r)&&(n=null),r||i===null?jv(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 Nn=Pv.__SECRET_INTERNALS_DO_NOT_USE_OR_YOU_WILL_BE_FIRED,Eo=Symbol.for("react.element"),oi=Symbol.for("react.portal"),li=Symbol.for("react.fragment"),nf=Symbol.for("react.strict_mode"),Eu=Symbol.for("react.profiler"),ym=Symbol.for("react.provider"),vm=Symbol.for("react.context"),rf=Symbol.for("react.forward_ref"),_u=Symbol.for("react.suspense"),ku=Symbol.for("react.suspense_list"),sf=Symbol.for("react.memo"),Dn=Symbol.for("react.lazy"),wm=Symbol.for("react.offscreen"),Pd=Symbol.iterator;function is(e){return e===null||typeof e!="object"?null:(e=Pd&&e[Pd]||e["@@iterator"],typeof e=="function"?e:null)}var ge=Object.assign,La;function ps(e){if(La===void 0)try{throw Error()}catch(n){var t=n.stack.trim().match(/\n( *(at )?)/);La=t&&t[1]||""}return`
34
- `+La+e}var Da=!1;function Ma(e,t){if(!e||Da)return"";Da=!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(c){var r=c}Reflect.construct(e,[],t)}else{try{t.call()}catch(c){r=c}e.call(t.prototype)}else{try{throw Error()}catch(c){r=c}e()}}catch(c){if(c&&r&&typeof c.stack=="string"){for(var i=c.stack.split(`
33
+ */var Av=b,St=Pv;function O(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 ym=new Set,Ps={};function Kr(e,t){Mi(e,t),Mi(e+"Capture",t)}function Mi(e,t){for(Ps[e]=t,e=0;e<t.length;e++)ym.add(t[e])}var Cn=!(typeof window>"u"||typeof window.document>"u"||typeof window.document.createElement>"u"),bu=Object.prototype.hasOwnProperty,jv=/^[: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]*$/,Rd={},Nd={};function Fv(e){return bu.call(Nd,e)?!0:bu.call(Rd,e)?!1:jv.test(e)?Nd[e]=!0:(Rd[e]=!0,!1)}function $v(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 Iv(e,t,n,r){if(t===null||typeof t>"u"||$v(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 Ze(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 Ie={};"children dangerouslySetInnerHTML defaultValue defaultChecked innerHTML suppressContentEditableWarning suppressHydrationWarning style".split(" ").forEach(function(e){Ie[e]=new Ze(e,0,!1,e,null,!1,!1)});[["acceptCharset","accept-charset"],["className","class"],["htmlFor","for"],["httpEquiv","http-equiv"]].forEach(function(e){var t=e[0];Ie[t]=new Ze(t,1,!1,e[1],null,!1,!1)});["contentEditable","draggable","spellCheck","value"].forEach(function(e){Ie[e]=new Ze(e,2,!1,e.toLowerCase(),null,!1,!1)});["autoReverse","externalResourcesRequired","focusable","preserveAlpha"].forEach(function(e){Ie[e]=new Ze(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){Ie[e]=new Ze(e,3,!1,e.toLowerCase(),null,!1,!1)});["checked","multiple","muted","selected"].forEach(function(e){Ie[e]=new Ze(e,3,!0,e,null,!1,!1)});["capture","download"].forEach(function(e){Ie[e]=new Ze(e,4,!1,e,null,!1,!1)});["cols","rows","size","span"].forEach(function(e){Ie[e]=new Ze(e,6,!1,e,null,!1,!1)});["rowSpan","start"].forEach(function(e){Ie[e]=new Ze(e,5,!1,e.toLowerCase(),null,!1,!1)});var Jc=/[\-:]([a-z])/g;function ef(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(Jc,ef);Ie[t]=new Ze(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(Jc,ef);Ie[t]=new Ze(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(Jc,ef);Ie[t]=new Ze(t,1,!1,e,"http://www.w3.org/XML/1998/namespace",!1,!1)});["tabIndex","crossOrigin"].forEach(function(e){Ie[e]=new Ze(e,1,!1,e.toLowerCase(),null,!1,!1)});Ie.xlinkHref=new Ze("xlinkHref",1,!1,"xlink:href","http://www.w3.org/1999/xlink",!0,!1);["src","href","action","formAction"].forEach(function(e){Ie[e]=new Ze(e,1,!1,e.toLowerCase(),null,!0,!0)});function tf(e,t,n,r){var i=Ie.hasOwnProperty(t)?Ie[t]:null;(i!==null?i.type!==0:r||!(2<t.length)||t[0]!=="o"&&t[0]!=="O"||t[1]!=="n"&&t[1]!=="N")&&(Iv(t,n,i,r)&&(n=null),r||i===null?Fv(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 Nn=Av.__SECRET_INTERNALS_DO_NOT_USE_OR_YOU_WILL_BE_FIRED,Eo=Symbol.for("react.element"),oi=Symbol.for("react.portal"),li=Symbol.for("react.fragment"),nf=Symbol.for("react.strict_mode"),Eu=Symbol.for("react.profiler"),gm=Symbol.for("react.provider"),vm=Symbol.for("react.context"),rf=Symbol.for("react.forward_ref"),_u=Symbol.for("react.suspense"),ku=Symbol.for("react.suspense_list"),sf=Symbol.for("react.memo"),Ln=Symbol.for("react.lazy"),wm=Symbol.for("react.offscreen"),Pd=Symbol.iterator;function is(e){return e===null||typeof e!="object"?null:(e=Pd&&e[Pd]||e["@@iterator"],typeof e=="function"?e:null)}var ye=Object.assign,Da;function ps(e){if(Da===void 0)try{throw Error()}catch(n){var t=n.stack.trim().match(/\n( *(at )?)/);Da=t&&t[1]||""}return`
34
+ `+Da+e}var La=!1;function Ma(e,t){if(!e||La)return"";La=!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(c){var r=c}Reflect.construct(e,[],t)}else{try{t.call()}catch(c){r=c}e.call(t.prototype)}else{try{throw Error()}catch(c){r=c}e()}}catch(c){if(c&&r&&typeof c.stack=="string"){for(var i=c.stack.split(`
35
35
  `),s=r.stack.split(`
36
36
  `),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=`
37
- `+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{Da=!1,Error.prepareStackTrace=n}return(e=e?e.displayName||e.name:"")?ps(e):""}function Iv(e){switch(e.tag){case 5:return ps(e.type);case 16:return ps("Lazy");case 13:return ps("Suspense");case 19:return ps("SuspenseList");case 0:case 2:case 15:return e=Ma(e.type,!1),e;case 11:return e=Ma(e.type.render,!1),e;case 1:return e=Ma(e.type,!0),e;default:return""}}function Cu(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 li:return"Fragment";case oi:return"Portal";case Eu:return"Profiler";case nf:return"StrictMode";case _u:return"Suspense";case ku:return"SuspenseList"}if(typeof e=="object")switch(e.$$typeof){case vm:return(e.displayName||"Context")+".Consumer";case ym:return(e._context.displayName||"Context")+".Provider";case rf:var t=e.render;return e=e.displayName,e||(e=t.displayName||t.name||"",e=e!==""?"ForwardRef("+e+")":"ForwardRef"),e;case sf:return t=e.displayName||null,t!==null?t:Cu(e.type)||"Memo";case Dn:t=e._payload,e=e._init;try{return Cu(e(t))}catch{}}return null}function Lv(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 Cu(t);case 8:return t===nf?"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 cr(e){switch(typeof e){case"boolean":case"number":case"string":case"undefined":return e;case"object":return e;default:return""}}function xm(e){var t=e.type;return(e=e.nodeName)&&e.toLowerCase()==="input"&&(t==="checkbox"||t==="radio")}function Dv(e){var t=xm(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 _o(e){e._valueTracker||(e._valueTracker=Dv(e))}function Sm(e){if(!e)return!1;var t=e._valueTracker;if(!t)return!0;var n=t.getValue(),r="";return e&&(r=xm(e)?e.checked?"true":"false":e.value),e=r,e!==n?(t.setValue(e),!0):!1}function dl(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 Tu(e,t){var n=t.checked;return ge({},t,{defaultChecked:void 0,defaultValue:void 0,value:void 0,checked:n??e._wrapperState.initialChecked})}function Ad(e,t){var n=t.defaultValue==null?"":t.defaultValue,r=t.checked!=null?t.checked:t.defaultChecked;n=cr(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 bm(e,t){t=t.checked,t!=null&&tf(e,"checked",t,!1)}function Ou(e,t){bm(e,t);var n=cr(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")?Ru(e,t.type,n):t.hasOwnProperty("defaultValue")&&Ru(e,t.type,cr(t.defaultValue)),t.checked==null&&t.defaultChecked!=null&&(e.defaultChecked=!!t.defaultChecked)}function jd(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 Ru(e,t,n){(t!=="number"||dl(e.ownerDocument)!==e)&&(n==null?e.defaultValue=""+e._wrapperState.initialValue:e.defaultValue!==""+n&&(e.defaultValue=""+n))}var ms=Array.isArray;function wi(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=""+cr(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 Nu(e,t){if(t.dangerouslySetInnerHTML!=null)throw Error(O(91));return ge({},t,{value:void 0,defaultValue:void 0,children:""+e._wrapperState.initialValue})}function Fd(e,t){var n=t.value;if(n==null){if(n=t.children,t=t.defaultValue,n!=null){if(t!=null)throw Error(O(92));if(ms(n)){if(1<n.length)throw Error(O(93));n=n[0]}t=n}t==null&&(t=""),n=t}e._wrapperState={initialValue:cr(n)}}function Em(e,t){var n=cr(t.value),r=cr(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 $d(e){var t=e.textContent;t===e._wrapperState.initialValue&&t!==""&&t!==null&&(e.value=t)}function _m(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 Pu(e,t){return e==null||e==="http://www.w3.org/1999/xhtml"?_m(t):e==="http://www.w3.org/2000/svg"&&t==="foreignObject"?"http://www.w3.org/1999/xhtml":e}var ko,km=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(ko=ko||document.createElement("div"),ko.innerHTML="<svg>"+t.valueOf().toString()+"</svg>",t=ko.firstChild;e.firstChild;)e.removeChild(e.firstChild);for(;t.firstChild;)e.appendChild(t.firstChild)}});function As(e,t){if(t){var n=e.firstChild;if(n&&n===e.lastChild&&n.nodeType===3){n.nodeValue=t;return}}e.textContent=t}var xs={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},Mv=["Webkit","ms","Moz","O"];Object.keys(xs).forEach(function(e){Mv.forEach(function(t){t=t+e.charAt(0).toUpperCase()+e.substring(1),xs[t]=xs[e]})});function Cm(e,t,n){return t==null||typeof t=="boolean"||t===""?"":n||typeof t!="number"||t===0||xs.hasOwnProperty(e)&&xs[e]?(""+t).trim():t+"px"}function Tm(e,t){e=e.style;for(var n in t)if(t.hasOwnProperty(n)){var r=n.indexOf("--")===0,i=Cm(n,t[n],r);n==="float"&&(n="cssFloat"),r?e.setProperty(n,i):e[n]=i}}var zv=ge({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 Au(e,t){if(t){if(zv[e]&&(t.children!=null||t.dangerouslySetInnerHTML!=null))throw Error(O(137,e));if(t.dangerouslySetInnerHTML!=null){if(t.children!=null)throw Error(O(60));if(typeof t.dangerouslySetInnerHTML!="object"||!("__html"in t.dangerouslySetInnerHTML))throw Error(O(61))}if(t.style!=null&&typeof t.style!="object")throw Error(O(62))}}function ju(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 Fu=null;function of(e){return e=e.target||e.srcElement||window,e.correspondingUseElement&&(e=e.correspondingUseElement),e.nodeType===3?e.parentNode:e}var $u=null,xi=null,Si=null;function Id(e){if(e=lo(e)){if(typeof $u!="function")throw Error(O(280));var t=e.stateNode;t&&(t=Yl(t),$u(e.stateNode,e.type,t))}}function Om(e){xi?Si?Si.push(e):Si=[e]:xi=e}function Rm(){if(xi){var e=xi,t=Si;if(Si=xi=null,Id(e),t)for(e=0;e<t.length;e++)Id(t[e])}}function Nm(e,t){return e(t)}function Pm(){}var za=!1;function Am(e,t,n){if(za)return e(t,n);za=!0;try{return Nm(e,t,n)}finally{za=!1,(xi!==null||Si!==null)&&(Pm(),Rm())}}function js(e,t){var n=e.stateNode;if(n===null)return null;var r=Yl(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(O(231,t,typeof n));return n}var Iu=!1;if(Cn)try{var ss={};Object.defineProperty(ss,"passive",{get:function(){Iu=!0}}),window.addEventListener("test",ss,ss),window.removeEventListener("test",ss,ss)}catch{Iu=!1}function Bv(e,t,n,r,i,s,o,l,a){var c=Array.prototype.slice.call(arguments,3);try{t.apply(n,c)}catch(f){this.onError(f)}}var Ss=!1,hl=null,pl=!1,Lu=null,Uv={onError:function(e){Ss=!0,hl=e}};function Vv(e,t,n,r,i,s,o,l,a){Ss=!1,hl=null,Bv.apply(Uv,arguments)}function Hv(e,t,n,r,i,s,o,l,a){if(Vv.apply(this,arguments),Ss){if(Ss){var c=hl;Ss=!1,hl=null}else throw Error(O(198));pl||(pl=!0,Lu=c)}}function Yr(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 jm(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 Ld(e){if(Yr(e)!==e)throw Error(O(188))}function Wv(e){var t=e.alternate;if(!t){if(t=Yr(e),t===null)throw Error(O(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 Ld(i),e;if(s===r)return Ld(i),t;s=s.sibling}throw Error(O(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(O(189))}}if(n.alternate!==r)throw Error(O(190))}if(n.tag!==3)throw Error(O(188));return n.stateNode.current===n?e:t}function Fm(e){return e=Wv(e),e!==null?$m(e):null}function $m(e){if(e.tag===5||e.tag===6)return e;for(e=e.child;e!==null;){var t=$m(e);if(t!==null)return t;e=e.sibling}return null}var Im=xt.unstable_scheduleCallback,Dd=xt.unstable_cancelCallback,Qv=xt.unstable_shouldYield,qv=xt.unstable_requestPaint,xe=xt.unstable_now,Kv=xt.unstable_getCurrentPriorityLevel,lf=xt.unstable_ImmediatePriority,Lm=xt.unstable_UserBlockingPriority,ml=xt.unstable_NormalPriority,Yv=xt.unstable_LowPriority,Dm=xt.unstable_IdlePriority,Wl=null,an=null;function Gv(e){if(an&&typeof an.onCommitFiberRoot=="function")try{an.onCommitFiberRoot(Wl,e,void 0,(e.current.flags&128)===128)}catch{}}var Kt=Math.clz32?Math.clz32:Jv,Xv=Math.log,Zv=Math.LN2;function Jv(e){return e>>>=0,e===0?32:31-(Xv(e)/Zv|0)|0}var Co=64,To=4194304;function gs(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 gl(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=gs(l):(s&=o,s!==0&&(r=gs(s)))}else o=n&~i,o!==0?r=gs(o):s!==0&&(r=gs(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-Kt(t),i=1<<n,r|=e[n],t&=~i;return r}function e1(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 t1(e,t){for(var n=e.suspendedLanes,r=e.pingedLanes,i=e.expirationTimes,s=e.pendingLanes;0<s;){var o=31-Kt(s),l=1<<o,a=i[o];a===-1?(!(l&n)||l&r)&&(i[o]=e1(l,t)):a<=t&&(e.expiredLanes|=l),s&=~l}}function Du(e){return e=e.pendingLanes&-1073741825,e!==0?e:e&1073741824?1073741824:0}function Mm(){var e=Co;return Co<<=1,!(Co&4194240)&&(Co=64),e}function Ba(e){for(var t=[],n=0;31>n;n++)t.push(e);return t}function so(e,t,n){e.pendingLanes|=t,t!==536870912&&(e.suspendedLanes=0,e.pingedLanes=0),e=e.eventTimes,t=31-Kt(t),e[t]=n}function n1(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-Kt(n),s=1<<i;t[i]=0,r[i]=-1,e[i]=-1,n&=~s}}function af(e,t){var n=e.entangledLanes|=t;for(e=e.entanglements;n;){var r=31-Kt(n),i=1<<r;i&t|e[r]&t&&(e[r]|=t),n&=~i}}var re=0;function zm(e){return e&=-e,1<e?4<e?e&268435455?16:536870912:4:1}var Bm,uf,Um,Vm,Hm,Mu=!1,Oo=[],er=null,tr=null,nr=null,Fs=new Map,$s=new Map,zn=[],r1="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 Md(e,t){switch(e){case"focusin":case"focusout":er=null;break;case"dragenter":case"dragleave":tr=null;break;case"mouseover":case"mouseout":nr=null;break;case"pointerover":case"pointerout":Fs.delete(t.pointerId);break;case"gotpointercapture":case"lostpointercapture":$s.delete(t.pointerId)}}function os(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=lo(t),t!==null&&uf(t)),e):(e.eventSystemFlags|=r,t=e.targetContainers,i!==null&&t.indexOf(i)===-1&&t.push(i),e)}function i1(e,t,n,r,i){switch(t){case"focusin":return er=os(er,e,t,n,r,i),!0;case"dragenter":return tr=os(tr,e,t,n,r,i),!0;case"mouseover":return nr=os(nr,e,t,n,r,i),!0;case"pointerover":var s=i.pointerId;return Fs.set(s,os(Fs.get(s)||null,e,t,n,r,i)),!0;case"gotpointercapture":return s=i.pointerId,$s.set(s,os($s.get(s)||null,e,t,n,r,i)),!0}return!1}function Wm(e){var t=_r(e.target);if(t!==null){var n=Yr(t);if(n!==null){if(t=n.tag,t===13){if(t=jm(n),t!==null){e.blockedOn=t,Hm(e.priority,function(){Um(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 Ko(e){if(e.blockedOn!==null)return!1;for(var t=e.targetContainers;0<t.length;){var n=zu(e.domEventName,e.eventSystemFlags,t[0],e.nativeEvent);if(n===null){n=e.nativeEvent;var r=new n.constructor(n.type,n);Fu=r,n.target.dispatchEvent(r),Fu=null}else return t=lo(n),t!==null&&uf(t),e.blockedOn=n,!1;t.shift()}return!0}function zd(e,t,n){Ko(e)&&n.delete(t)}function s1(){Mu=!1,er!==null&&Ko(er)&&(er=null),tr!==null&&Ko(tr)&&(tr=null),nr!==null&&Ko(nr)&&(nr=null),Fs.forEach(zd),$s.forEach(zd)}function ls(e,t){e.blockedOn===t&&(e.blockedOn=null,Mu||(Mu=!0,xt.unstable_scheduleCallback(xt.unstable_NormalPriority,s1)))}function Is(e){function t(i){return ls(i,e)}if(0<Oo.length){ls(Oo[0],e);for(var n=1;n<Oo.length;n++){var r=Oo[n];r.blockedOn===e&&(r.blockedOn=null)}}for(er!==null&&ls(er,e),tr!==null&&ls(tr,e),nr!==null&&ls(nr,e),Fs.forEach(t),$s.forEach(t),n=0;n<zn.length;n++)r=zn[n],r.blockedOn===e&&(r.blockedOn=null);for(;0<zn.length&&(n=zn[0],n.blockedOn===null);)Wm(n),n.blockedOn===null&&zn.shift()}var bi=Nn.ReactCurrentBatchConfig,yl=!0;function o1(e,t,n,r){var i=re,s=bi.transition;bi.transition=null;try{re=1,cf(e,t,n,r)}finally{re=i,bi.transition=s}}function l1(e,t,n,r){var i=re,s=bi.transition;bi.transition=null;try{re=4,cf(e,t,n,r)}finally{re=i,bi.transition=s}}function cf(e,t,n,r){if(yl){var i=zu(e,t,n,r);if(i===null)Xa(e,t,r,vl,n),Md(e,r);else if(i1(i,e,t,n,r))r.stopPropagation();else if(Md(e,r),t&4&&-1<r1.indexOf(e)){for(;i!==null;){var s=lo(i);if(s!==null&&Bm(s),s=zu(e,t,n,r),s===null&&Xa(e,t,r,vl,n),s===i)break;i=s}i!==null&&r.stopPropagation()}else Xa(e,t,r,null,n)}}var vl=null;function zu(e,t,n,r){if(vl=null,e=of(r),e=_r(e),e!==null)if(t=Yr(e),t===null)e=null;else if(n=t.tag,n===13){if(e=jm(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 vl=e,null}function Qm(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(Kv()){case lf:return 1;case Lm:return 4;case ml:case Yv:return 16;case Dm:return 536870912;default:return 16}default:return 16}}var Xn=null,ff=null,Yo=null;function qm(){if(Yo)return Yo;var e,t=ff,n=t.length,r,i="value"in Xn?Xn.value:Xn.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 Yo=i.slice(e,1<r?1-r:void 0)}function Go(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 Ro(){return!0}function Bd(){return!1}function bt(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)?Ro:Bd,this.isPropagationStopped=Bd,this}return ge(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=Ro)},stopPropagation:function(){var n=this.nativeEvent;n&&(n.stopPropagation?n.stopPropagation():typeof n.cancelBubble!="unknown"&&(n.cancelBubble=!0),this.isPropagationStopped=Ro)},persist:function(){},isPersistent:Ro}),t}var Gi={eventPhase:0,bubbles:0,cancelable:0,timeStamp:function(e){return e.timeStamp||Date.now()},defaultPrevented:0,isTrusted:0},df=bt(Gi),oo=ge({},Gi,{view:0,detail:0}),a1=bt(oo),Ua,Va,as,Ql=ge({},oo,{screenX:0,screenY:0,clientX:0,clientY:0,pageX:0,pageY:0,ctrlKey:0,shiftKey:0,altKey:0,metaKey:0,getModifierState:hf,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!==as&&(as&&e.type==="mousemove"?(Ua=e.screenX-as.screenX,Va=e.screenY-as.screenY):Va=Ua=0,as=e),Ua)},movementY:function(e){return"movementY"in e?e.movementY:Va}}),Ud=bt(Ql),u1=ge({},Ql,{dataTransfer:0}),c1=bt(u1),f1=ge({},oo,{relatedTarget:0}),Ha=bt(f1),d1=ge({},Gi,{animationName:0,elapsedTime:0,pseudoElement:0}),h1=bt(d1),p1=ge({},Gi,{clipboardData:function(e){return"clipboardData"in e?e.clipboardData:window.clipboardData}}),m1=bt(p1),g1=ge({},Gi,{data:0}),Vd=bt(g1),y1={Esc:"Escape",Spacebar:" ",Left:"ArrowLeft",Up:"ArrowUp",Right:"ArrowRight",Down:"ArrowDown",Del:"Delete",Win:"OS",Menu:"ContextMenu",Apps:"ContextMenu",Scroll:"ScrollLock",MozPrintableKey:"Unidentified"},v1={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"},w1={Alt:"altKey",Control:"ctrlKey",Meta:"metaKey",Shift:"shiftKey"};function x1(e){var t=this.nativeEvent;return t.getModifierState?t.getModifierState(e):(e=w1[e])?!!t[e]:!1}function hf(){return x1}var S1=ge({},oo,{key:function(e){if(e.key){var t=y1[e.key]||e.key;if(t!=="Unidentified")return t}return e.type==="keypress"?(e=Go(e),e===13?"Enter":String.fromCharCode(e)):e.type==="keydown"||e.type==="keyup"?v1[e.keyCode]||"Unidentified":""},code:0,location:0,ctrlKey:0,shiftKey:0,altKey:0,metaKey:0,repeat:0,locale:0,getModifierState:hf,charCode:function(e){return e.type==="keypress"?Go(e):0},keyCode:function(e){return e.type==="keydown"||e.type==="keyup"?e.keyCode:0},which:function(e){return e.type==="keypress"?Go(e):e.type==="keydown"||e.type==="keyup"?e.keyCode:0}}),b1=bt(S1),E1=ge({},Ql,{pointerId:0,width:0,height:0,pressure:0,tangentialPressure:0,tiltX:0,tiltY:0,twist:0,pointerType:0,isPrimary:0}),Hd=bt(E1),_1=ge({},oo,{touches:0,targetTouches:0,changedTouches:0,altKey:0,metaKey:0,ctrlKey:0,shiftKey:0,getModifierState:hf}),k1=bt(_1),C1=ge({},Gi,{propertyName:0,elapsedTime:0,pseudoElement:0}),T1=bt(C1),O1=ge({},Ql,{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}),R1=bt(O1),N1=[9,13,27,32],pf=Cn&&"CompositionEvent"in window,bs=null;Cn&&"documentMode"in document&&(bs=document.documentMode);var P1=Cn&&"TextEvent"in window&&!bs,Km=Cn&&(!pf||bs&&8<bs&&11>=bs),Wd=" ",Qd=!1;function Ym(e,t){switch(e){case"keyup":return N1.indexOf(t.keyCode)!==-1;case"keydown":return t.keyCode!==229;case"keypress":case"mousedown":case"focusout":return!0;default:return!1}}function Gm(e){return e=e.detail,typeof e=="object"&&"data"in e?e.data:null}var ai=!1;function A1(e,t){switch(e){case"compositionend":return Gm(t);case"keypress":return t.which!==32?null:(Qd=!0,Wd);case"textInput":return e=t.data,e===Wd&&Qd?null:e;default:return null}}function j1(e,t){if(ai)return e==="compositionend"||!pf&&Ym(e,t)?(e=qm(),Yo=ff=Xn=null,ai=!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 Km&&t.locale!=="ko"?null:t.data;default:return null}}var F1={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 qd(e){var t=e&&e.nodeName&&e.nodeName.toLowerCase();return t==="input"?!!F1[e.type]:t==="textarea"}function Xm(e,t,n,r){Om(r),t=wl(t,"onChange"),0<t.length&&(n=new df("onChange","change",null,n,r),e.push({event:n,listeners:t}))}var Es=null,Ls=null;function $1(e){a0(e,0)}function ql(e){var t=fi(e);if(Sm(t))return e}function I1(e,t){if(e==="change")return t}var Zm=!1;if(Cn){var Wa;if(Cn){var Qa="oninput"in document;if(!Qa){var Kd=document.createElement("div");Kd.setAttribute("oninput","return;"),Qa=typeof Kd.oninput=="function"}Wa=Qa}else Wa=!1;Zm=Wa&&(!document.documentMode||9<document.documentMode)}function Yd(){Es&&(Es.detachEvent("onpropertychange",Jm),Ls=Es=null)}function Jm(e){if(e.propertyName==="value"&&ql(Ls)){var t=[];Xm(t,Ls,e,of(e)),Am($1,t)}}function L1(e,t,n){e==="focusin"?(Yd(),Es=t,Ls=n,Es.attachEvent("onpropertychange",Jm)):e==="focusout"&&Yd()}function D1(e){if(e==="selectionchange"||e==="keyup"||e==="keydown")return ql(Ls)}function M1(e,t){if(e==="click")return ql(t)}function z1(e,t){if(e==="input"||e==="change")return ql(t)}function B1(e,t){return e===t&&(e!==0||1/e===1/t)||e!==e&&t!==t}var Gt=typeof Object.is=="function"?Object.is:B1;function Ds(e,t){if(Gt(e,t))return!0;if(typeof e!="object"||e===null||typeof t!="object"||t===null)return!1;var n=Object.keys(e),r=Object.keys(t);if(n.length!==r.length)return!1;for(r=0;r<n.length;r++){var i=n[r];if(!bu.call(t,i)||!Gt(e[i],t[i]))return!1}return!0}function Gd(e){for(;e&&e.firstChild;)e=e.firstChild;return e}function Xd(e,t){var n=Gd(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=Gd(n)}}function e0(e,t){return e&&t?e===t?!0:e&&e.nodeType===3?!1:t&&t.nodeType===3?e0(e,t.parentNode):"contains"in e?e.contains(t):e.compareDocumentPosition?!!(e.compareDocumentPosition(t)&16):!1:!1}function t0(){for(var e=window,t=dl();t instanceof e.HTMLIFrameElement;){try{var n=typeof t.contentWindow.location.href=="string"}catch{n=!1}if(n)e=t.contentWindow;else break;t=dl(e.document)}return t}function mf(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 U1(e){var t=t0(),n=e.focusedElem,r=e.selectionRange;if(t!==n&&n&&n.ownerDocument&&e0(n.ownerDocument.documentElement,n)){if(r!==null&&mf(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=Xd(n,s);var o=Xd(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 V1=Cn&&"documentMode"in document&&11>=document.documentMode,ui=null,Bu=null,_s=null,Uu=!1;function Zd(e,t,n){var r=n.window===n?n.document:n.nodeType===9?n:n.ownerDocument;Uu||ui==null||ui!==dl(r)||(r=ui,"selectionStart"in r&&mf(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}),_s&&Ds(_s,r)||(_s=r,r=wl(Bu,"onSelect"),0<r.length&&(t=new df("onSelect","select",null,t,n),e.push({event:t,listeners:r}),t.target=ui)))}function No(e,t){var n={};return n[e.toLowerCase()]=t.toLowerCase(),n["Webkit"+e]="webkit"+t,n["Moz"+e]="moz"+t,n}var ci={animationend:No("Animation","AnimationEnd"),animationiteration:No("Animation","AnimationIteration"),animationstart:No("Animation","AnimationStart"),transitionend:No("Transition","TransitionEnd")},qa={},n0={};Cn&&(n0=document.createElement("div").style,"AnimationEvent"in window||(delete ci.animationend.animation,delete ci.animationiteration.animation,delete ci.animationstart.animation),"TransitionEvent"in window||delete ci.transitionend.transition);function Kl(e){if(qa[e])return qa[e];if(!ci[e])return e;var t=ci[e],n;for(n in t)if(t.hasOwnProperty(n)&&n in n0)return qa[e]=t[n];return e}var r0=Kl("animationend"),i0=Kl("animationiteration"),s0=Kl("animationstart"),o0=Kl("transitionend"),l0=new Map,Jd="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 hr(e,t){l0.set(e,t),Kr(t,[e])}for(var Ka=0;Ka<Jd.length;Ka++){var Ya=Jd[Ka],H1=Ya.toLowerCase(),W1=Ya[0].toUpperCase()+Ya.slice(1);hr(H1,"on"+W1)}hr(r0,"onAnimationEnd");hr(i0,"onAnimationIteration");hr(s0,"onAnimationStart");hr("dblclick","onDoubleClick");hr("focusin","onFocus");hr("focusout","onBlur");hr(o0,"onTransitionEnd");Mi("onMouseEnter",["mouseout","mouseover"]);Mi("onMouseLeave",["mouseout","mouseover"]);Mi("onPointerEnter",["pointerout","pointerover"]);Mi("onPointerLeave",["pointerout","pointerover"]);Kr("onChange","change click focusin focusout input keydown keyup selectionchange".split(" "));Kr("onSelect","focusout contextmenu dragend focusin keydown keyup mousedown mouseup selectionchange".split(" "));Kr("onBeforeInput",["compositionend","keypress","textInput","paste"]);Kr("onCompositionEnd","compositionend focusout keydown keypress keyup mousedown".split(" "));Kr("onCompositionStart","compositionstart focusout keydown keypress keyup mousedown".split(" "));Kr("onCompositionUpdate","compositionupdate focusout keydown keypress keyup mousedown".split(" "));var ys="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(" "),Q1=new Set("cancel close invalid load scroll toggle".split(" ").concat(ys));function eh(e,t,n){var r=e.type||"unknown-event";e.currentTarget=n,Hv(r,t,void 0,e),e.currentTarget=null}function a0(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,c=l.currentTarget;if(l=l.listener,a!==s&&i.isPropagationStopped())break e;eh(i,l,c),s=a}else for(o=0;o<r.length;o++){if(l=r[o],a=l.instance,c=l.currentTarget,l=l.listener,a!==s&&i.isPropagationStopped())break e;eh(i,l,c),s=a}}}if(pl)throw e=Lu,pl=!1,Lu=null,e}function ue(e,t){var n=t[qu];n===void 0&&(n=t[qu]=new Set);var r=e+"__bubble";n.has(r)||(u0(t,e,2,!1),n.add(r))}function Ga(e,t,n){var r=0;t&&(r|=4),u0(n,e,r,t)}var Po="_reactListening"+Math.random().toString(36).slice(2);function Ms(e){if(!e[Po]){e[Po]=!0,gm.forEach(function(n){n!=="selectionchange"&&(Q1.has(n)||Ga(n,!1,e),Ga(n,!0,e))});var t=e.nodeType===9?e:e.ownerDocument;t===null||t[Po]||(t[Po]=!0,Ga("selectionchange",!1,t))}}function u0(e,t,n,r){switch(Qm(t)){case 1:var i=o1;break;case 4:i=l1;break;default:i=cf}n=i.bind(null,t,n,e),i=void 0,!Iu||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 Xa(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=_r(l),o===null)return;if(a=o.tag,a===5||a===6){r=s=o;continue e}l=l.parentNode}}r=r.return}Am(function(){var c=s,f=of(n),u=[];e:{var d=l0.get(e);if(d!==void 0){var h=df,v=e;switch(e){case"keypress":if(Go(n)===0)break e;case"keydown":case"keyup":h=b1;break;case"focusin":v="focus",h=Ha;break;case"focusout":v="blur",h=Ha;break;case"beforeblur":case"afterblur":h=Ha;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":h=Ud;break;case"drag":case"dragend":case"dragenter":case"dragexit":case"dragleave":case"dragover":case"dragstart":case"drop":h=c1;break;case"touchcancel":case"touchend":case"touchmove":case"touchstart":h=k1;break;case r0:case i0:case s0:h=h1;break;case o0:h=T1;break;case"scroll":h=a1;break;case"wheel":h=R1;break;case"copy":case"cut":case"paste":h=m1;break;case"gotpointercapture":case"lostpointercapture":case"pointercancel":case"pointerdown":case"pointermove":case"pointerout":case"pointerover":case"pointerup":h=Hd}var w=(t&4)!==0,S=!w&&e==="scroll",m=w?d!==null?d+"Capture":null:d;w=[];for(var p=c,y;p!==null;){y=p;var x=y.stateNode;if(y.tag===5&&x!==null&&(y=x,m!==null&&(x=js(p,m),x!=null&&w.push(zs(p,x,y)))),S)break;p=p.return}0<w.length&&(d=new h(d,v,null,n,f),u.push({event:d,listeners:w}))}}if(!(t&7)){e:{if(d=e==="mouseover"||e==="pointerover",h=e==="mouseout"||e==="pointerout",d&&n!==Fu&&(v=n.relatedTarget||n.fromElement)&&(_r(v)||v[Tn]))break e;if((h||d)&&(d=f.window===f?f:(d=f.ownerDocument)?d.defaultView||d.parentWindow:window,h?(v=n.relatedTarget||n.toElement,h=c,v=v?_r(v):null,v!==null&&(S=Yr(v),v!==S||v.tag!==5&&v.tag!==6)&&(v=null)):(h=null,v=c),h!==v)){if(w=Ud,x="onMouseLeave",m="onMouseEnter",p="mouse",(e==="pointerout"||e==="pointerover")&&(w=Hd,x="onPointerLeave",m="onPointerEnter",p="pointer"),S=h==null?d:fi(h),y=v==null?d:fi(v),d=new w(x,p+"leave",h,n,f),d.target=S,d.relatedTarget=y,x=null,_r(f)===c&&(w=new w(m,p+"enter",v,n,f),w.target=y,w.relatedTarget=S,x=w),S=x,h&&v)t:{for(w=h,m=v,p=0,y=w;y;y=ii(y))p++;for(y=0,x=m;x;x=ii(x))y++;for(;0<p-y;)w=ii(w),p--;for(;0<y-p;)m=ii(m),y--;for(;p--;){if(w===m||m!==null&&w===m.alternate)break t;w=ii(w),m=ii(m)}w=null}else w=null;h!==null&&th(u,d,h,w,!1),v!==null&&S!==null&&th(u,S,v,w,!0)}}e:{if(d=c?fi(c):window,h=d.nodeName&&d.nodeName.toLowerCase(),h==="select"||h==="input"&&d.type==="file")var C=I1;else if(qd(d))if(Zm)C=z1;else{C=D1;var T=L1}else(h=d.nodeName)&&h.toLowerCase()==="input"&&(d.type==="checkbox"||d.type==="radio")&&(C=M1);if(C&&(C=C(e,c))){Xm(u,C,n,f);break e}T&&T(e,d,c),e==="focusout"&&(T=d._wrapperState)&&T.controlled&&d.type==="number"&&Ru(d,"number",d.value)}switch(T=c?fi(c):window,e){case"focusin":(qd(T)||T.contentEditable==="true")&&(ui=T,Bu=c,_s=null);break;case"focusout":_s=Bu=ui=null;break;case"mousedown":Uu=!0;break;case"contextmenu":case"mouseup":case"dragend":Uu=!1,Zd(u,n,f);break;case"selectionchange":if(V1)break;case"keydown":case"keyup":Zd(u,n,f)}var k;if(pf)e:{switch(e){case"compositionstart":var R="onCompositionStart";break e;case"compositionend":R="onCompositionEnd";break e;case"compositionupdate":R="onCompositionUpdate";break e}R=void 0}else ai?Ym(e,n)&&(R="onCompositionEnd"):e==="keydown"&&n.keyCode===229&&(R="onCompositionStart");R&&(Km&&n.locale!=="ko"&&(ai||R!=="onCompositionStart"?R==="onCompositionEnd"&&ai&&(k=qm()):(Xn=f,ff="value"in Xn?Xn.value:Xn.textContent,ai=!0)),T=wl(c,R),0<T.length&&(R=new Vd(R,e,null,n,f),u.push({event:R,listeners:T}),k?R.data=k:(k=Gm(n),k!==null&&(R.data=k)))),(k=P1?A1(e,n):j1(e,n))&&(c=wl(c,"onBeforeInput"),0<c.length&&(f=new Vd("onBeforeInput","beforeinput",null,n,f),u.push({event:f,listeners:c}),f.data=k))}a0(u,t)})}function zs(e,t,n){return{instance:e,listener:t,currentTarget:n}}function wl(e,t){for(var n=t+"Capture",r=[];e!==null;){var i=e,s=i.stateNode;i.tag===5&&s!==null&&(i=s,s=js(e,n),s!=null&&r.unshift(zs(e,s,i)),s=js(e,t),s!=null&&r.push(zs(e,s,i))),e=e.return}return r}function ii(e){if(e===null)return null;do e=e.return;while(e&&e.tag!==5);return e||null}function th(e,t,n,r,i){for(var s=t._reactName,o=[];n!==null&&n!==r;){var l=n,a=l.alternate,c=l.stateNode;if(a!==null&&a===r)break;l.tag===5&&c!==null&&(l=c,i?(a=js(n,s),a!=null&&o.unshift(zs(n,a,l))):i||(a=js(n,s),a!=null&&o.push(zs(n,a,l)))),n=n.return}o.length!==0&&e.push({event:t,listeners:o})}var q1=/\r\n?/g,K1=/\u0000|\uFFFD/g;function nh(e){return(typeof e=="string"?e:""+e).replace(q1,`
38
- `).replace(K1,"")}function Ao(e,t,n){if(t=nh(t),nh(e)!==t&&n)throw Error(O(425))}function xl(){}var Vu=null,Hu=null;function Wu(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 Qu=typeof setTimeout=="function"?setTimeout:void 0,Y1=typeof clearTimeout=="function"?clearTimeout:void 0,rh=typeof Promise=="function"?Promise:void 0,G1=typeof queueMicrotask=="function"?queueMicrotask:typeof rh<"u"?function(e){return rh.resolve(null).then(e).catch(X1)}:Qu;function X1(e){setTimeout(function(){throw e})}function Za(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),Is(t);return}r--}else n!=="$"&&n!=="$?"&&n!=="$!"||r++;n=i}while(n);Is(t)}function rr(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 ih(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 Xi=Math.random().toString(36).slice(2),ln="__reactFiber$"+Xi,Bs="__reactProps$"+Xi,Tn="__reactContainer$"+Xi,qu="__reactEvents$"+Xi,Z1="__reactListeners$"+Xi,J1="__reactHandles$"+Xi;function _r(e){var t=e[ln];if(t)return t;for(var n=e.parentNode;n;){if(t=n[Tn]||n[ln]){if(n=t.alternate,t.child!==null||n!==null&&n.child!==null)for(e=ih(e);e!==null;){if(n=e[ln])return n;e=ih(e)}return t}e=n,n=e.parentNode}return null}function lo(e){return e=e[ln]||e[Tn],!e||e.tag!==5&&e.tag!==6&&e.tag!==13&&e.tag!==3?null:e}function fi(e){if(e.tag===5||e.tag===6)return e.stateNode;throw Error(O(33))}function Yl(e){return e[Bs]||null}var Ku=[],di=-1;function pr(e){return{current:e}}function fe(e){0>di||(e.current=Ku[di],Ku[di]=null,di--)}function ae(e,t){di++,Ku[di]=e.current,e.current=t}var fr={},Ue=pr(fr),lt=pr(!1),zr=fr;function zi(e,t){var n=e.type.contextTypes;if(!n)return fr;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 at(e){return e=e.childContextTypes,e!=null}function Sl(){fe(lt),fe(Ue)}function sh(e,t,n){if(Ue.current!==fr)throw Error(O(168));ae(Ue,t),ae(lt,n)}function c0(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(O(108,Lv(e)||"Unknown",i));return ge({},n,r)}function bl(e){return e=(e=e.stateNode)&&e.__reactInternalMemoizedMergedChildContext||fr,zr=Ue.current,ae(Ue,e),ae(lt,lt.current),!0}function oh(e,t,n){var r=e.stateNode;if(!r)throw Error(O(169));n?(e=c0(e,t,zr),r.__reactInternalMemoizedMergedChildContext=e,fe(lt),fe(Ue),ae(Ue,e)):fe(lt),ae(lt,n)}var wn=null,Gl=!1,Ja=!1;function f0(e){wn===null?wn=[e]:wn.push(e)}function ew(e){Gl=!0,f0(e)}function mr(){if(!Ja&&wn!==null){Ja=!0;var e=0,t=re;try{var n=wn;for(re=1;e<n.length;e++){var r=n[e];do r=r(!0);while(r!==null)}wn=null,Gl=!1}catch(i){throw wn!==null&&(wn=wn.slice(e+1)),Im(lf,mr),i}finally{re=t,Ja=!1}}return null}var hi=[],pi=0,El=null,_l=0,Rt=[],Nt=0,Br=null,bn=1,En="";function Sr(e,t){hi[pi++]=_l,hi[pi++]=El,El=e,_l=t}function d0(e,t,n){Rt[Nt++]=bn,Rt[Nt++]=En,Rt[Nt++]=Br,Br=e;var r=bn;e=En;var i=32-Kt(r)-1;r&=~(1<<i),n+=1;var s=32-Kt(t)+i;if(30<s){var o=i-i%5;s=(r&(1<<o)-1).toString(32),r>>=o,i-=o,bn=1<<32-Kt(t)+i|n<<i|r,En=s+e}else bn=1<<s|n<<i|r,En=e}function gf(e){e.return!==null&&(Sr(e,1),d0(e,1,0))}function yf(e){for(;e===El;)El=hi[--pi],hi[pi]=null,_l=hi[--pi],hi[pi]=null;for(;e===Br;)Br=Rt[--Nt],Rt[Nt]=null,En=Rt[--Nt],Rt[Nt]=null,bn=Rt[--Nt],Rt[Nt]=null}var wt=null,gt=null,he=!1,Ht=null;function h0(e,t){var n=At(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 lh(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,wt=e,gt=rr(t.firstChild),!0):!1;case 6:return t=e.pendingProps===""||t.nodeType!==3?null:t,t!==null?(e.stateNode=t,wt=e,gt=null,!0):!1;case 13:return t=t.nodeType!==8?null:t,t!==null?(n=Br!==null?{id:bn,overflow:En}:null,e.memoizedState={dehydrated:t,treeContext:n,retryLane:1073741824},n=At(18,null,null,0),n.stateNode=t,n.return=e,e.child=n,wt=e,gt=null,!0):!1;default:return!1}}function Yu(e){return(e.mode&1)!==0&&(e.flags&128)===0}function Gu(e){if(he){var t=gt;if(t){var n=t;if(!lh(e,t)){if(Yu(e))throw Error(O(418));t=rr(n.nextSibling);var r=wt;t&&lh(e,t)?h0(r,n):(e.flags=e.flags&-4097|2,he=!1,wt=e)}}else{if(Yu(e))throw Error(O(418));e.flags=e.flags&-4097|2,he=!1,wt=e}}}function ah(e){for(e=e.return;e!==null&&e.tag!==5&&e.tag!==3&&e.tag!==13;)e=e.return;wt=e}function jo(e){if(e!==wt)return!1;if(!he)return ah(e),he=!0,!1;var t;if((t=e.tag!==3)&&!(t=e.tag!==5)&&(t=e.type,t=t!=="head"&&t!=="body"&&!Wu(e.type,e.memoizedProps)),t&&(t=gt)){if(Yu(e))throw p0(),Error(O(418));for(;t;)h0(e,t),t=rr(t.nextSibling)}if(ah(e),e.tag===13){if(e=e.memoizedState,e=e!==null?e.dehydrated:null,!e)throw Error(O(317));e:{for(e=e.nextSibling,t=0;e;){if(e.nodeType===8){var n=e.data;if(n==="/$"){if(t===0){gt=rr(e.nextSibling);break e}t--}else n!=="$"&&n!=="$!"&&n!=="$?"||t++}e=e.nextSibling}gt=null}}else gt=wt?rr(e.stateNode.nextSibling):null;return!0}function p0(){for(var e=gt;e;)e=rr(e.nextSibling)}function Bi(){gt=wt=null,he=!1}function vf(e){Ht===null?Ht=[e]:Ht.push(e)}var tw=Nn.ReactCurrentBatchConfig;function us(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(O(309));var r=n.stateNode}if(!r)throw Error(O(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(O(284));if(!n._owner)throw Error(O(290,e))}return e}function Fo(e,t){throw e=Object.prototype.toString.call(t),Error(O(31,e==="[object Object]"?"object with keys {"+Object.keys(t).join(", ")+"}":e))}function uh(e){var t=e._init;return t(e._payload)}function m0(e){function t(m,p){if(e){var y=m.deletions;y===null?(m.deletions=[p],m.flags|=16):y.push(p)}}function n(m,p){if(!e)return null;for(;p!==null;)t(m,p),p=p.sibling;return null}function r(m,p){for(m=new Map;p!==null;)p.key!==null?m.set(p.key,p):m.set(p.index,p),p=p.sibling;return m}function i(m,p){return m=lr(m,p),m.index=0,m.sibling=null,m}function s(m,p,y){return m.index=y,e?(y=m.alternate,y!==null?(y=y.index,y<p?(m.flags|=2,p):y):(m.flags|=2,p)):(m.flags|=1048576,p)}function o(m){return e&&m.alternate===null&&(m.flags|=2),m}function l(m,p,y,x){return p===null||p.tag!==6?(p=ou(y,m.mode,x),p.return=m,p):(p=i(p,y),p.return=m,p)}function a(m,p,y,x){var C=y.type;return C===li?f(m,p,y.props.children,x,y.key):p!==null&&(p.elementType===C||typeof C=="object"&&C!==null&&C.$$typeof===Dn&&uh(C)===p.type)?(x=i(p,y.props),x.ref=us(m,p,y),x.return=m,x):(x=rl(y.type,y.key,y.props,null,m.mode,x),x.ref=us(m,p,y),x.return=m,x)}function c(m,p,y,x){return p===null||p.tag!==4||p.stateNode.containerInfo!==y.containerInfo||p.stateNode.implementation!==y.implementation?(p=lu(y,m.mode,x),p.return=m,p):(p=i(p,y.children||[]),p.return=m,p)}function f(m,p,y,x,C){return p===null||p.tag!==7?(p=Ir(y,m.mode,x,C),p.return=m,p):(p=i(p,y),p.return=m,p)}function u(m,p,y){if(typeof p=="string"&&p!==""||typeof p=="number")return p=ou(""+p,m.mode,y),p.return=m,p;if(typeof p=="object"&&p!==null){switch(p.$$typeof){case Eo:return y=rl(p.type,p.key,p.props,null,m.mode,y),y.ref=us(m,null,p),y.return=m,y;case oi:return p=lu(p,m.mode,y),p.return=m,p;case Dn:var x=p._init;return u(m,x(p._payload),y)}if(ms(p)||is(p))return p=Ir(p,m.mode,y,null),p.return=m,p;Fo(m,p)}return null}function d(m,p,y,x){var C=p!==null?p.key:null;if(typeof y=="string"&&y!==""||typeof y=="number")return C!==null?null:l(m,p,""+y,x);if(typeof y=="object"&&y!==null){switch(y.$$typeof){case Eo:return y.key===C?a(m,p,y,x):null;case oi:return y.key===C?c(m,p,y,x):null;case Dn:return C=y._init,d(m,p,C(y._payload),x)}if(ms(y)||is(y))return C!==null?null:f(m,p,y,x,null);Fo(m,y)}return null}function h(m,p,y,x,C){if(typeof x=="string"&&x!==""||typeof x=="number")return m=m.get(y)||null,l(p,m,""+x,C);if(typeof x=="object"&&x!==null){switch(x.$$typeof){case Eo:return m=m.get(x.key===null?y:x.key)||null,a(p,m,x,C);case oi:return m=m.get(x.key===null?y:x.key)||null,c(p,m,x,C);case Dn:var T=x._init;return h(m,p,y,T(x._payload),C)}if(ms(x)||is(x))return m=m.get(y)||null,f(p,m,x,C,null);Fo(p,x)}return null}function v(m,p,y,x){for(var C=null,T=null,k=p,R=p=0,I=null;k!==null&&R<y.length;R++){k.index>R?(I=k,k=null):I=k.sibling;var D=d(m,k,y[R],x);if(D===null){k===null&&(k=I);break}e&&k&&D.alternate===null&&t(m,k),p=s(D,p,R),T===null?C=D:T.sibling=D,T=D,k=I}if(R===y.length)return n(m,k),he&&Sr(m,R),C;if(k===null){for(;R<y.length;R++)k=u(m,y[R],x),k!==null&&(p=s(k,p,R),T===null?C=k:T.sibling=k,T=k);return he&&Sr(m,R),C}for(k=r(m,k);R<y.length;R++)I=h(k,m,R,y[R],x),I!==null&&(e&&I.alternate!==null&&k.delete(I.key===null?R:I.key),p=s(I,p,R),T===null?C=I:T.sibling=I,T=I);return e&&k.forEach(function(B){return t(m,B)}),he&&Sr(m,R),C}function w(m,p,y,x){var C=is(y);if(typeof C!="function")throw Error(O(150));if(y=C.call(y),y==null)throw Error(O(151));for(var T=C=null,k=p,R=p=0,I=null,D=y.next();k!==null&&!D.done;R++,D=y.next()){k.index>R?(I=k,k=null):I=k.sibling;var B=d(m,k,D.value,x);if(B===null){k===null&&(k=I);break}e&&k&&B.alternate===null&&t(m,k),p=s(B,p,R),T===null?C=B:T.sibling=B,T=B,k=I}if(D.done)return n(m,k),he&&Sr(m,R),C;if(k===null){for(;!D.done;R++,D=y.next())D=u(m,D.value,x),D!==null&&(p=s(D,p,R),T===null?C=D:T.sibling=D,T=D);return he&&Sr(m,R),C}for(k=r(m,k);!D.done;R++,D=y.next())D=h(k,m,R,D.value,x),D!==null&&(e&&D.alternate!==null&&k.delete(D.key===null?R:D.key),p=s(D,p,R),T===null?C=D:T.sibling=D,T=D);return e&&k.forEach(function(se){return t(m,se)}),he&&Sr(m,R),C}function S(m,p,y,x){if(typeof y=="object"&&y!==null&&y.type===li&&y.key===null&&(y=y.props.children),typeof y=="object"&&y!==null){switch(y.$$typeof){case Eo:e:{for(var C=y.key,T=p;T!==null;){if(T.key===C){if(C=y.type,C===li){if(T.tag===7){n(m,T.sibling),p=i(T,y.props.children),p.return=m,m=p;break e}}else if(T.elementType===C||typeof C=="object"&&C!==null&&C.$$typeof===Dn&&uh(C)===T.type){n(m,T.sibling),p=i(T,y.props),p.ref=us(m,T,y),p.return=m,m=p;break e}n(m,T);break}else t(m,T);T=T.sibling}y.type===li?(p=Ir(y.props.children,m.mode,x,y.key),p.return=m,m=p):(x=rl(y.type,y.key,y.props,null,m.mode,x),x.ref=us(m,p,y),x.return=m,m=x)}return o(m);case oi:e:{for(T=y.key;p!==null;){if(p.key===T)if(p.tag===4&&p.stateNode.containerInfo===y.containerInfo&&p.stateNode.implementation===y.implementation){n(m,p.sibling),p=i(p,y.children||[]),p.return=m,m=p;break e}else{n(m,p);break}else t(m,p);p=p.sibling}p=lu(y,m.mode,x),p.return=m,m=p}return o(m);case Dn:return T=y._init,S(m,p,T(y._payload),x)}if(ms(y))return v(m,p,y,x);if(is(y))return w(m,p,y,x);Fo(m,y)}return typeof y=="string"&&y!==""||typeof y=="number"?(y=""+y,p!==null&&p.tag===6?(n(m,p.sibling),p=i(p,y),p.return=m,m=p):(n(m,p),p=ou(y,m.mode,x),p.return=m,m=p),o(m)):n(m,p)}return S}var Ui=m0(!0),g0=m0(!1),kl=pr(null),Cl=null,mi=null,wf=null;function xf(){wf=mi=Cl=null}function Sf(e){var t=kl.current;fe(kl),e._currentValue=t}function Xu(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 Ei(e,t){Cl=e,wf=mi=null,e=e.dependencies,e!==null&&e.firstContext!==null&&(e.lanes&t&&(ot=!0),e.firstContext=null)}function Ft(e){var t=e._currentValue;if(wf!==e)if(e={context:e,memoizedValue:t,next:null},mi===null){if(Cl===null)throw Error(O(308));mi=e,Cl.dependencies={lanes:0,firstContext:e}}else mi=mi.next=e;return t}var kr=null;function bf(e){kr===null?kr=[e]:kr.push(e)}function y0(e,t,n,r){var i=t.interleaved;return i===null?(n.next=n,bf(t)):(n.next=i.next,i.next=n),t.interleaved=n,On(e,r)}function On(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 Mn=!1;function Ef(e){e.updateQueue={baseState:e.memoizedState,firstBaseUpdate:null,lastBaseUpdate:null,shared:{pending:null,interleaved:null,lanes:0},effects:null}}function v0(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 _n(e,t){return{eventTime:e,lane:t,tag:0,payload:null,callback:null,next:null}}function ir(e,t,n){var r=e.updateQueue;if(r===null)return null;if(r=r.shared,J&2){var i=r.pending;return i===null?t.next=t:(t.next=i.next,i.next=t),r.pending=t,On(e,n)}return i=r.interleaved,i===null?(t.next=t,bf(r)):(t.next=i.next,i.next=t),r.interleaved=t,On(e,n)}function Xo(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,af(e,n)}}function ch(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 Tl(e,t,n,r){var i=e.updateQueue;Mn=!1;var s=i.firstBaseUpdate,o=i.lastBaseUpdate,l=i.shared.pending;if(l!==null){i.shared.pending=null;var a=l,c=a.next;a.next=null,o===null?s=c:o.next=c,o=a;var f=e.alternate;f!==null&&(f=f.updateQueue,l=f.lastBaseUpdate,l!==o&&(l===null?f.firstBaseUpdate=c:l.next=c,f.lastBaseUpdate=a))}if(s!==null){var u=i.baseState;o=0,f=c=a=null,l=s;do{var d=l.lane,h=l.eventTime;if((r&d)===d){f!==null&&(f=f.next={eventTime:h,lane:0,tag:l.tag,payload:l.payload,callback:l.callback,next:null});e:{var v=e,w=l;switch(d=t,h=n,w.tag){case 1:if(v=w.payload,typeof v=="function"){u=v.call(h,u,d);break e}u=v;break e;case 3:v.flags=v.flags&-65537|128;case 0:if(v=w.payload,d=typeof v=="function"?v.call(h,u,d):v,d==null)break e;u=ge({},u,d);break e;case 2:Mn=!0}}l.callback!==null&&l.lane!==0&&(e.flags|=64,d=i.effects,d===null?i.effects=[l]:d.push(l))}else h={eventTime:h,lane:d,tag:l.tag,payload:l.payload,callback:l.callback,next:null},f===null?(c=f=h,a=u):f=f.next=h,o|=d;if(l=l.next,l===null){if(l=i.shared.pending,l===null)break;d=l,l=d.next,d.next=null,i.lastBaseUpdate=d,i.shared.pending=null}}while(!0);if(f===null&&(a=u),i.baseState=a,i.firstBaseUpdate=c,i.lastBaseUpdate=f,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);Vr|=o,e.lanes=o,e.memoizedState=u}}function fh(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(O(191,i));i.call(r)}}}var ao={},un=pr(ao),Us=pr(ao),Vs=pr(ao);function Cr(e){if(e===ao)throw Error(O(174));return e}function _f(e,t){switch(ae(Vs,t),ae(Us,e),ae(un,ao),e=t.nodeType,e){case 9:case 11:t=(t=t.documentElement)?t.namespaceURI:Pu(null,"");break;default:e=e===8?t.parentNode:t,t=e.namespaceURI||null,e=e.tagName,t=Pu(t,e)}fe(un),ae(un,t)}function Vi(){fe(un),fe(Us),fe(Vs)}function w0(e){Cr(Vs.current);var t=Cr(un.current),n=Pu(t,e.type);t!==n&&(ae(Us,e),ae(un,n))}function kf(e){Us.current===e&&(fe(un),fe(Us))}var pe=pr(0);function Ol(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 eu=[];function Cf(){for(var e=0;e<eu.length;e++)eu[e]._workInProgressVersionPrimary=null;eu.length=0}var Zo=Nn.ReactCurrentDispatcher,tu=Nn.ReactCurrentBatchConfig,Ur=0,me=null,Ee=null,Re=null,Rl=!1,ks=!1,Hs=0,nw=0;function De(){throw Error(O(321))}function Tf(e,t){if(t===null)return!1;for(var n=0;n<t.length&&n<e.length;n++)if(!Gt(e[n],t[n]))return!1;return!0}function Of(e,t,n,r,i,s){if(Ur=s,me=t,t.memoizedState=null,t.updateQueue=null,t.lanes=0,Zo.current=e===null||e.memoizedState===null?ow:lw,e=n(r,i),ks){s=0;do{if(ks=!1,Hs=0,25<=s)throw Error(O(301));s+=1,Re=Ee=null,t.updateQueue=null,Zo.current=aw,e=n(r,i)}while(ks)}if(Zo.current=Nl,t=Ee!==null&&Ee.next!==null,Ur=0,Re=Ee=me=null,Rl=!1,t)throw Error(O(300));return e}function Rf(){var e=Hs!==0;return Hs=0,e}function en(){var e={memoizedState:null,baseState:null,baseQueue:null,queue:null,next:null};return Re===null?me.memoizedState=Re=e:Re=Re.next=e,Re}function $t(){if(Ee===null){var e=me.alternate;e=e!==null?e.memoizedState:null}else e=Ee.next;var t=Re===null?me.memoizedState:Re.next;if(t!==null)Re=t,Ee=e;else{if(e===null)throw Error(O(310));Ee=e,e={memoizedState:Ee.memoizedState,baseState:Ee.baseState,baseQueue:Ee.baseQueue,queue:Ee.queue,next:null},Re===null?me.memoizedState=Re=e:Re=Re.next=e}return Re}function Ws(e,t){return typeof t=="function"?t(e):t}function nu(e){var t=$t(),n=t.queue;if(n===null)throw Error(O(311));n.lastRenderedReducer=e;var r=Ee,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,c=s;do{var f=c.lane;if((Ur&f)===f)a!==null&&(a=a.next={lane:0,action:c.action,hasEagerState:c.hasEagerState,eagerState:c.eagerState,next:null}),r=c.hasEagerState?c.eagerState:e(r,c.action);else{var u={lane:f,action:c.action,hasEagerState:c.hasEagerState,eagerState:c.eagerState,next:null};a===null?(l=a=u,o=r):a=a.next=u,me.lanes|=f,Vr|=f}c=c.next}while(c!==null&&c!==s);a===null?o=r:a.next=l,Gt(r,t.memoizedState)||(ot=!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,me.lanes|=s,Vr|=s,i=i.next;while(i!==e)}else i===null&&(n.lanes=0);return[t.memoizedState,n.dispatch]}function ru(e){var t=$t(),n=t.queue;if(n===null)throw Error(O(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);Gt(s,t.memoizedState)||(ot=!0),t.memoizedState=s,t.baseQueue===null&&(t.baseState=s),n.lastRenderedState=s}return[s,r]}function x0(){}function S0(e,t){var n=me,r=$t(),i=t(),s=!Gt(r.memoizedState,i);if(s&&(r.memoizedState=i,ot=!0),r=r.queue,Nf(_0.bind(null,n,r,e),[e]),r.getSnapshot!==t||s||Re!==null&&Re.memoizedState.tag&1){if(n.flags|=2048,Qs(9,E0.bind(null,n,r,i,t),void 0,null),Ne===null)throw Error(O(349));Ur&30||b0(n,t,i)}return i}function b0(e,t,n){e.flags|=16384,e={getSnapshot:t,value:n},t=me.updateQueue,t===null?(t={lastEffect:null,stores:null},me.updateQueue=t,t.stores=[e]):(n=t.stores,n===null?t.stores=[e]:n.push(e))}function E0(e,t,n,r){t.value=n,t.getSnapshot=r,k0(t)&&C0(e)}function _0(e,t,n){return n(function(){k0(t)&&C0(e)})}function k0(e){var t=e.getSnapshot;e=e.value;try{var n=t();return!Gt(e,n)}catch{return!0}}function C0(e){var t=On(e,1);t!==null&&Yt(t,e,1,-1)}function dh(e){var t=en();return typeof e=="function"&&(e=e()),t.memoizedState=t.baseState=e,e={pending:null,interleaved:null,lanes:0,dispatch:null,lastRenderedReducer:Ws,lastRenderedState:e},t.queue=e,e=e.dispatch=sw.bind(null,me,e),[t.memoizedState,e]}function Qs(e,t,n,r){return e={tag:e,create:t,destroy:n,deps:r,next:null},t=me.updateQueue,t===null?(t={lastEffect:null,stores:null},me.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 T0(){return $t().memoizedState}function Jo(e,t,n,r){var i=en();me.flags|=e,i.memoizedState=Qs(1|t,n,void 0,r===void 0?null:r)}function Xl(e,t,n,r){var i=$t();r=r===void 0?null:r;var s=void 0;if(Ee!==null){var o=Ee.memoizedState;if(s=o.destroy,r!==null&&Tf(r,o.deps)){i.memoizedState=Qs(t,n,s,r);return}}me.flags|=e,i.memoizedState=Qs(1|t,n,s,r)}function hh(e,t){return Jo(8390656,8,e,t)}function Nf(e,t){return Xl(2048,8,e,t)}function O0(e,t){return Xl(4,2,e,t)}function R0(e,t){return Xl(4,4,e,t)}function N0(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 P0(e,t,n){return n=n!=null?n.concat([e]):null,Xl(4,4,N0.bind(null,t,e),n)}function Pf(){}function A0(e,t){var n=$t();t=t===void 0?null:t;var r=n.memoizedState;return r!==null&&t!==null&&Tf(t,r[1])?r[0]:(n.memoizedState=[e,t],e)}function j0(e,t){var n=$t();t=t===void 0?null:t;var r=n.memoizedState;return r!==null&&t!==null&&Tf(t,r[1])?r[0]:(e=e(),n.memoizedState=[e,t],e)}function F0(e,t,n){return Ur&21?(Gt(n,t)||(n=Mm(),me.lanes|=n,Vr|=n,e.baseState=!0),t):(e.baseState&&(e.baseState=!1,ot=!0),e.memoizedState=n)}function rw(e,t){var n=re;re=n!==0&&4>n?n:4,e(!0);var r=tu.transition;tu.transition={};try{e(!1),t()}finally{re=n,tu.transition=r}}function $0(){return $t().memoizedState}function iw(e,t,n){var r=or(e);if(n={lane:r,action:n,hasEagerState:!1,eagerState:null,next:null},I0(e))L0(t,n);else if(n=y0(e,t,n,r),n!==null){var i=Ge();Yt(n,e,r,i),D0(n,t,r)}}function sw(e,t,n){var r=or(e),i={lane:r,action:n,hasEagerState:!1,eagerState:null,next:null};if(I0(e))L0(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,Gt(l,o)){var a=t.interleaved;a===null?(i.next=i,bf(t)):(i.next=a.next,a.next=i),t.interleaved=i;return}}catch{}finally{}n=y0(e,t,i,r),n!==null&&(i=Ge(),Yt(n,e,r,i),D0(n,t,r))}}function I0(e){var t=e.alternate;return e===me||t!==null&&t===me}function L0(e,t){ks=Rl=!0;var n=e.pending;n===null?t.next=t:(t.next=n.next,n.next=t),e.pending=t}function D0(e,t,n){if(n&4194240){var r=t.lanes;r&=e.pendingLanes,n|=r,t.lanes=n,af(e,n)}}var Nl={readContext:Ft,useCallback:De,useContext:De,useEffect:De,useImperativeHandle:De,useInsertionEffect:De,useLayoutEffect:De,useMemo:De,useReducer:De,useRef:De,useState:De,useDebugValue:De,useDeferredValue:De,useTransition:De,useMutableSource:De,useSyncExternalStore:De,useId:De,unstable_isNewReconciler:!1},ow={readContext:Ft,useCallback:function(e,t){return en().memoizedState=[e,t===void 0?null:t],e},useContext:Ft,useEffect:hh,useImperativeHandle:function(e,t,n){return n=n!=null?n.concat([e]):null,Jo(4194308,4,N0.bind(null,t,e),n)},useLayoutEffect:function(e,t){return Jo(4194308,4,e,t)},useInsertionEffect:function(e,t){return Jo(4,2,e,t)},useMemo:function(e,t){var n=en();return t=t===void 0?null:t,e=e(),n.memoizedState=[e,t],e},useReducer:function(e,t,n){var r=en();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=iw.bind(null,me,e),[r.memoizedState,e]},useRef:function(e){var t=en();return e={current:e},t.memoizedState=e},useState:dh,useDebugValue:Pf,useDeferredValue:function(e){return en().memoizedState=e},useTransition:function(){var e=dh(!1),t=e[0];return e=rw.bind(null,e[1]),en().memoizedState=e,[t,e]},useMutableSource:function(){},useSyncExternalStore:function(e,t,n){var r=me,i=en();if(he){if(n===void 0)throw Error(O(407));n=n()}else{if(n=t(),Ne===null)throw Error(O(349));Ur&30||b0(r,t,n)}i.memoizedState=n;var s={value:n,getSnapshot:t};return i.queue=s,hh(_0.bind(null,r,s,e),[e]),r.flags|=2048,Qs(9,E0.bind(null,r,s,n,t),void 0,null),n},useId:function(){var e=en(),t=Ne.identifierPrefix;if(he){var n=En,r=bn;n=(r&~(1<<32-Kt(r)-1)).toString(32)+n,t=":"+t+"R"+n,n=Hs++,0<n&&(t+="H"+n.toString(32)),t+=":"}else n=nw++,t=":"+t+"r"+n.toString(32)+":";return e.memoizedState=t},unstable_isNewReconciler:!1},lw={readContext:Ft,useCallback:A0,useContext:Ft,useEffect:Nf,useImperativeHandle:P0,useInsertionEffect:O0,useLayoutEffect:R0,useMemo:j0,useReducer:nu,useRef:T0,useState:function(){return nu(Ws)},useDebugValue:Pf,useDeferredValue:function(e){var t=$t();return F0(t,Ee.memoizedState,e)},useTransition:function(){var e=nu(Ws)[0],t=$t().memoizedState;return[e,t]},useMutableSource:x0,useSyncExternalStore:S0,useId:$0,unstable_isNewReconciler:!1},aw={readContext:Ft,useCallback:A0,useContext:Ft,useEffect:Nf,useImperativeHandle:P0,useInsertionEffect:O0,useLayoutEffect:R0,useMemo:j0,useReducer:ru,useRef:T0,useState:function(){return ru(Ws)},useDebugValue:Pf,useDeferredValue:function(e){var t=$t();return Ee===null?t.memoizedState=e:F0(t,Ee.memoizedState,e)},useTransition:function(){var e=ru(Ws)[0],t=$t().memoizedState;return[e,t]},useMutableSource:x0,useSyncExternalStore:S0,useId:$0,unstable_isNewReconciler:!1};function zt(e,t){if(e&&e.defaultProps){t=ge({},t),e=e.defaultProps;for(var n in e)t[n]===void 0&&(t[n]=e[n]);return t}return t}function Zu(e,t,n,r){t=e.memoizedState,n=n(r,t),n=n==null?t:ge({},t,n),e.memoizedState=n,e.lanes===0&&(e.updateQueue.baseState=n)}var Zl={isMounted:function(e){return(e=e._reactInternals)?Yr(e)===e:!1},enqueueSetState:function(e,t,n){e=e._reactInternals;var r=Ge(),i=or(e),s=_n(r,i);s.payload=t,n!=null&&(s.callback=n),t=ir(e,s,i),t!==null&&(Yt(t,e,i,r),Xo(t,e,i))},enqueueReplaceState:function(e,t,n){e=e._reactInternals;var r=Ge(),i=or(e),s=_n(r,i);s.tag=1,s.payload=t,n!=null&&(s.callback=n),t=ir(e,s,i),t!==null&&(Yt(t,e,i,r),Xo(t,e,i))},enqueueForceUpdate:function(e,t){e=e._reactInternals;var n=Ge(),r=or(e),i=_n(n,r);i.tag=2,t!=null&&(i.callback=t),t=ir(e,i,r),t!==null&&(Yt(t,e,r,n),Xo(t,e,r))}};function ph(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?!Ds(n,r)||!Ds(i,s):!0}function M0(e,t,n){var r=!1,i=fr,s=t.contextType;return typeof s=="object"&&s!==null?s=Ft(s):(i=at(t)?zr:Ue.current,r=t.contextTypes,s=(r=r!=null)?zi(e,i):fr),t=new t(n,s),e.memoizedState=t.state!==null&&t.state!==void 0?t.state:null,t.updater=Zl,e.stateNode=t,t._reactInternals=e,r&&(e=e.stateNode,e.__reactInternalMemoizedUnmaskedChildContext=i,e.__reactInternalMemoizedMaskedChildContext=s),t}function mh(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&&Zl.enqueueReplaceState(t,t.state,null)}function Ju(e,t,n,r){var i=e.stateNode;i.props=n,i.state=e.memoizedState,i.refs={},Ef(e);var s=t.contextType;typeof s=="object"&&s!==null?i.context=Ft(s):(s=at(t)?zr:Ue.current,i.context=zi(e,s)),i.state=e.memoizedState,s=t.getDerivedStateFromProps,typeof s=="function"&&(Zu(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&&Zl.enqueueReplaceState(i,i.state,null),Tl(e,n,i,r),i.state=e.memoizedState),typeof i.componentDidMount=="function"&&(e.flags|=4194308)}function Hi(e,t){try{var n="",r=t;do n+=Iv(r),r=r.return;while(r);var i=n}catch(s){i=`
37
+ `+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{La=!1,Error.prepareStackTrace=n}return(e=e?e.displayName||e.name:"")?ps(e):""}function Dv(e){switch(e.tag){case 5:return ps(e.type);case 16:return ps("Lazy");case 13:return ps("Suspense");case 19:return ps("SuspenseList");case 0:case 2:case 15:return e=Ma(e.type,!1),e;case 11:return e=Ma(e.type.render,!1),e;case 1:return e=Ma(e.type,!0),e;default:return""}}function Cu(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 li:return"Fragment";case oi:return"Portal";case Eu:return"Profiler";case nf:return"StrictMode";case _u:return"Suspense";case ku:return"SuspenseList"}if(typeof e=="object")switch(e.$$typeof){case vm:return(e.displayName||"Context")+".Consumer";case gm:return(e._context.displayName||"Context")+".Provider";case rf:var t=e.render;return e=e.displayName,e||(e=t.displayName||t.name||"",e=e!==""?"ForwardRef("+e+")":"ForwardRef"),e;case sf:return t=e.displayName||null,t!==null?t:Cu(e.type)||"Memo";case Ln:t=e._payload,e=e._init;try{return Cu(e(t))}catch{}}return null}function Lv(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 Cu(t);case 8:return t===nf?"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 cr(e){switch(typeof e){case"boolean":case"number":case"string":case"undefined":return e;case"object":return e;default:return""}}function xm(e){var t=e.type;return(e=e.nodeName)&&e.toLowerCase()==="input"&&(t==="checkbox"||t==="radio")}function Mv(e){var t=xm(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 _o(e){e._valueTracker||(e._valueTracker=Mv(e))}function Sm(e){if(!e)return!1;var t=e._valueTracker;if(!t)return!0;var n=t.getValue(),r="";return e&&(r=xm(e)?e.checked?"true":"false":e.value),e=r,e!==n?(t.setValue(e),!0):!1}function dl(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 Tu(e,t){var n=t.checked;return ye({},t,{defaultChecked:void 0,defaultValue:void 0,value:void 0,checked:n??e._wrapperState.initialChecked})}function Ad(e,t){var n=t.defaultValue==null?"":t.defaultValue,r=t.checked!=null?t.checked:t.defaultChecked;n=cr(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 bm(e,t){t=t.checked,t!=null&&tf(e,"checked",t,!1)}function Ou(e,t){bm(e,t);var n=cr(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")?Ru(e,t.type,n):t.hasOwnProperty("defaultValue")&&Ru(e,t.type,cr(t.defaultValue)),t.checked==null&&t.defaultChecked!=null&&(e.defaultChecked=!!t.defaultChecked)}function jd(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 Ru(e,t,n){(t!=="number"||dl(e.ownerDocument)!==e)&&(n==null?e.defaultValue=""+e._wrapperState.initialValue:e.defaultValue!==""+n&&(e.defaultValue=""+n))}var ms=Array.isArray;function wi(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=""+cr(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 Nu(e,t){if(t.dangerouslySetInnerHTML!=null)throw Error(O(91));return ye({},t,{value:void 0,defaultValue:void 0,children:""+e._wrapperState.initialValue})}function Fd(e,t){var n=t.value;if(n==null){if(n=t.children,t=t.defaultValue,n!=null){if(t!=null)throw Error(O(92));if(ms(n)){if(1<n.length)throw Error(O(93));n=n[0]}t=n}t==null&&(t=""),n=t}e._wrapperState={initialValue:cr(n)}}function Em(e,t){var n=cr(t.value),r=cr(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 $d(e){var t=e.textContent;t===e._wrapperState.initialValue&&t!==""&&t!==null&&(e.value=t)}function _m(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 Pu(e,t){return e==null||e==="http://www.w3.org/1999/xhtml"?_m(t):e==="http://www.w3.org/2000/svg"&&t==="foreignObject"?"http://www.w3.org/1999/xhtml":e}var ko,km=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(ko=ko||document.createElement("div"),ko.innerHTML="<svg>"+t.valueOf().toString()+"</svg>",t=ko.firstChild;e.firstChild;)e.removeChild(e.firstChild);for(;t.firstChild;)e.appendChild(t.firstChild)}});function As(e,t){if(t){var n=e.firstChild;if(n&&n===e.lastChild&&n.nodeType===3){n.nodeValue=t;return}}e.textContent=t}var xs={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},zv=["Webkit","ms","Moz","O"];Object.keys(xs).forEach(function(e){zv.forEach(function(t){t=t+e.charAt(0).toUpperCase()+e.substring(1),xs[t]=xs[e]})});function Cm(e,t,n){return t==null||typeof t=="boolean"||t===""?"":n||typeof t!="number"||t===0||xs.hasOwnProperty(e)&&xs[e]?(""+t).trim():t+"px"}function Tm(e,t){e=e.style;for(var n in t)if(t.hasOwnProperty(n)){var r=n.indexOf("--")===0,i=Cm(n,t[n],r);n==="float"&&(n="cssFloat"),r?e.setProperty(n,i):e[n]=i}}var Bv=ye({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 Au(e,t){if(t){if(Bv[e]&&(t.children!=null||t.dangerouslySetInnerHTML!=null))throw Error(O(137,e));if(t.dangerouslySetInnerHTML!=null){if(t.children!=null)throw Error(O(60));if(typeof t.dangerouslySetInnerHTML!="object"||!("__html"in t.dangerouslySetInnerHTML))throw Error(O(61))}if(t.style!=null&&typeof t.style!="object")throw Error(O(62))}}function ju(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 Fu=null;function of(e){return e=e.target||e.srcElement||window,e.correspondingUseElement&&(e=e.correspondingUseElement),e.nodeType===3?e.parentNode:e}var $u=null,xi=null,Si=null;function Id(e){if(e=lo(e)){if(typeof $u!="function")throw Error(O(280));var t=e.stateNode;t&&(t=Yl(t),$u(e.stateNode,e.type,t))}}function Om(e){xi?Si?Si.push(e):Si=[e]:xi=e}function Rm(){if(xi){var e=xi,t=Si;if(Si=xi=null,Id(e),t)for(e=0;e<t.length;e++)Id(t[e])}}function Nm(e,t){return e(t)}function Pm(){}var za=!1;function Am(e,t,n){if(za)return e(t,n);za=!0;try{return Nm(e,t,n)}finally{za=!1,(xi!==null||Si!==null)&&(Pm(),Rm())}}function js(e,t){var n=e.stateNode;if(n===null)return null;var r=Yl(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(O(231,t,typeof n));return n}var Iu=!1;if(Cn)try{var ss={};Object.defineProperty(ss,"passive",{get:function(){Iu=!0}}),window.addEventListener("test",ss,ss),window.removeEventListener("test",ss,ss)}catch{Iu=!1}function Uv(e,t,n,r,i,s,o,l,a){var c=Array.prototype.slice.call(arguments,3);try{t.apply(n,c)}catch(f){this.onError(f)}}var Ss=!1,hl=null,pl=!1,Du=null,Vv={onError:function(e){Ss=!0,hl=e}};function Hv(e,t,n,r,i,s,o,l,a){Ss=!1,hl=null,Uv.apply(Vv,arguments)}function Wv(e,t,n,r,i,s,o,l,a){if(Hv.apply(this,arguments),Ss){if(Ss){var c=hl;Ss=!1,hl=null}else throw Error(O(198));pl||(pl=!0,Du=c)}}function Yr(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 jm(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 Dd(e){if(Yr(e)!==e)throw Error(O(188))}function Qv(e){var t=e.alternate;if(!t){if(t=Yr(e),t===null)throw Error(O(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 Dd(i),e;if(s===r)return Dd(i),t;s=s.sibling}throw Error(O(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(O(189))}}if(n.alternate!==r)throw Error(O(190))}if(n.tag!==3)throw Error(O(188));return n.stateNode.current===n?e:t}function Fm(e){return e=Qv(e),e!==null?$m(e):null}function $m(e){if(e.tag===5||e.tag===6)return e;for(e=e.child;e!==null;){var t=$m(e);if(t!==null)return t;e=e.sibling}return null}var Im=St.unstable_scheduleCallback,Ld=St.unstable_cancelCallback,qv=St.unstable_shouldYield,Kv=St.unstable_requestPaint,xe=St.unstable_now,Yv=St.unstable_getCurrentPriorityLevel,lf=St.unstable_ImmediatePriority,Dm=St.unstable_UserBlockingPriority,ml=St.unstable_NormalPriority,Gv=St.unstable_LowPriority,Lm=St.unstable_IdlePriority,Wl=null,an=null;function Xv(e){if(an&&typeof an.onCommitFiberRoot=="function")try{an.onCommitFiberRoot(Wl,e,void 0,(e.current.flags&128)===128)}catch{}}var Kt=Math.clz32?Math.clz32:e1,Zv=Math.log,Jv=Math.LN2;function e1(e){return e>>>=0,e===0?32:31-(Zv(e)/Jv|0)|0}var Co=64,To=4194304;function ys(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 yl(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=ys(l):(s&=o,s!==0&&(r=ys(s)))}else o=n&~i,o!==0?r=ys(o):s!==0&&(r=ys(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-Kt(t),i=1<<n,r|=e[n],t&=~i;return r}function t1(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 n1(e,t){for(var n=e.suspendedLanes,r=e.pingedLanes,i=e.expirationTimes,s=e.pendingLanes;0<s;){var o=31-Kt(s),l=1<<o,a=i[o];a===-1?(!(l&n)||l&r)&&(i[o]=t1(l,t)):a<=t&&(e.expiredLanes|=l),s&=~l}}function Lu(e){return e=e.pendingLanes&-1073741825,e!==0?e:e&1073741824?1073741824:0}function Mm(){var e=Co;return Co<<=1,!(Co&4194240)&&(Co=64),e}function Ba(e){for(var t=[],n=0;31>n;n++)t.push(e);return t}function so(e,t,n){e.pendingLanes|=t,t!==536870912&&(e.suspendedLanes=0,e.pingedLanes=0),e=e.eventTimes,t=31-Kt(t),e[t]=n}function r1(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-Kt(n),s=1<<i;t[i]=0,r[i]=-1,e[i]=-1,n&=~s}}function af(e,t){var n=e.entangledLanes|=t;for(e=e.entanglements;n;){var r=31-Kt(n),i=1<<r;i&t|e[r]&t&&(e[r]|=t),n&=~i}}var re=0;function zm(e){return e&=-e,1<e?4<e?e&268435455?16:536870912:4:1}var Bm,uf,Um,Vm,Hm,Mu=!1,Oo=[],er=null,tr=null,nr=null,Fs=new Map,$s=new Map,zn=[],i1="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 Md(e,t){switch(e){case"focusin":case"focusout":er=null;break;case"dragenter":case"dragleave":tr=null;break;case"mouseover":case"mouseout":nr=null;break;case"pointerover":case"pointerout":Fs.delete(t.pointerId);break;case"gotpointercapture":case"lostpointercapture":$s.delete(t.pointerId)}}function os(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=lo(t),t!==null&&uf(t)),e):(e.eventSystemFlags|=r,t=e.targetContainers,i!==null&&t.indexOf(i)===-1&&t.push(i),e)}function s1(e,t,n,r,i){switch(t){case"focusin":return er=os(er,e,t,n,r,i),!0;case"dragenter":return tr=os(tr,e,t,n,r,i),!0;case"mouseover":return nr=os(nr,e,t,n,r,i),!0;case"pointerover":var s=i.pointerId;return Fs.set(s,os(Fs.get(s)||null,e,t,n,r,i)),!0;case"gotpointercapture":return s=i.pointerId,$s.set(s,os($s.get(s)||null,e,t,n,r,i)),!0}return!1}function Wm(e){var t=_r(e.target);if(t!==null){var n=Yr(t);if(n!==null){if(t=n.tag,t===13){if(t=jm(n),t!==null){e.blockedOn=t,Hm(e.priority,function(){Um(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 Ko(e){if(e.blockedOn!==null)return!1;for(var t=e.targetContainers;0<t.length;){var n=zu(e.domEventName,e.eventSystemFlags,t[0],e.nativeEvent);if(n===null){n=e.nativeEvent;var r=new n.constructor(n.type,n);Fu=r,n.target.dispatchEvent(r),Fu=null}else return t=lo(n),t!==null&&uf(t),e.blockedOn=n,!1;t.shift()}return!0}function zd(e,t,n){Ko(e)&&n.delete(t)}function o1(){Mu=!1,er!==null&&Ko(er)&&(er=null),tr!==null&&Ko(tr)&&(tr=null),nr!==null&&Ko(nr)&&(nr=null),Fs.forEach(zd),$s.forEach(zd)}function ls(e,t){e.blockedOn===t&&(e.blockedOn=null,Mu||(Mu=!0,St.unstable_scheduleCallback(St.unstable_NormalPriority,o1)))}function Is(e){function t(i){return ls(i,e)}if(0<Oo.length){ls(Oo[0],e);for(var n=1;n<Oo.length;n++){var r=Oo[n];r.blockedOn===e&&(r.blockedOn=null)}}for(er!==null&&ls(er,e),tr!==null&&ls(tr,e),nr!==null&&ls(nr,e),Fs.forEach(t),$s.forEach(t),n=0;n<zn.length;n++)r=zn[n],r.blockedOn===e&&(r.blockedOn=null);for(;0<zn.length&&(n=zn[0],n.blockedOn===null);)Wm(n),n.blockedOn===null&&zn.shift()}var bi=Nn.ReactCurrentBatchConfig,gl=!0;function l1(e,t,n,r){var i=re,s=bi.transition;bi.transition=null;try{re=1,cf(e,t,n,r)}finally{re=i,bi.transition=s}}function a1(e,t,n,r){var i=re,s=bi.transition;bi.transition=null;try{re=4,cf(e,t,n,r)}finally{re=i,bi.transition=s}}function cf(e,t,n,r){if(gl){var i=zu(e,t,n,r);if(i===null)Xa(e,t,r,vl,n),Md(e,r);else if(s1(i,e,t,n,r))r.stopPropagation();else if(Md(e,r),t&4&&-1<i1.indexOf(e)){for(;i!==null;){var s=lo(i);if(s!==null&&Bm(s),s=zu(e,t,n,r),s===null&&Xa(e,t,r,vl,n),s===i)break;i=s}i!==null&&r.stopPropagation()}else Xa(e,t,r,null,n)}}var vl=null;function zu(e,t,n,r){if(vl=null,e=of(r),e=_r(e),e!==null)if(t=Yr(e),t===null)e=null;else if(n=t.tag,n===13){if(e=jm(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 vl=e,null}function Qm(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(Yv()){case lf:return 1;case Dm:return 4;case ml:case Gv:return 16;case Lm:return 536870912;default:return 16}default:return 16}}var Xn=null,ff=null,Yo=null;function qm(){if(Yo)return Yo;var e,t=ff,n=t.length,r,i="value"in Xn?Xn.value:Xn.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 Yo=i.slice(e,1<r?1-r:void 0)}function Go(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 Ro(){return!0}function Bd(){return!1}function Et(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)?Ro:Bd,this.isPropagationStopped=Bd,this}return ye(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=Ro)},stopPropagation:function(){var n=this.nativeEvent;n&&(n.stopPropagation?n.stopPropagation():typeof n.cancelBubble!="unknown"&&(n.cancelBubble=!0),this.isPropagationStopped=Ro)},persist:function(){},isPersistent:Ro}),t}var Gi={eventPhase:0,bubbles:0,cancelable:0,timeStamp:function(e){return e.timeStamp||Date.now()},defaultPrevented:0,isTrusted:0},df=Et(Gi),oo=ye({},Gi,{view:0,detail:0}),u1=Et(oo),Ua,Va,as,Ql=ye({},oo,{screenX:0,screenY:0,clientX:0,clientY:0,pageX:0,pageY:0,ctrlKey:0,shiftKey:0,altKey:0,metaKey:0,getModifierState:hf,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!==as&&(as&&e.type==="mousemove"?(Ua=e.screenX-as.screenX,Va=e.screenY-as.screenY):Va=Ua=0,as=e),Ua)},movementY:function(e){return"movementY"in e?e.movementY:Va}}),Ud=Et(Ql),c1=ye({},Ql,{dataTransfer:0}),f1=Et(c1),d1=ye({},oo,{relatedTarget:0}),Ha=Et(d1),h1=ye({},Gi,{animationName:0,elapsedTime:0,pseudoElement:0}),p1=Et(h1),m1=ye({},Gi,{clipboardData:function(e){return"clipboardData"in e?e.clipboardData:window.clipboardData}}),y1=Et(m1),g1=ye({},Gi,{data:0}),Vd=Et(g1),v1={Esc:"Escape",Spacebar:" ",Left:"ArrowLeft",Up:"ArrowUp",Right:"ArrowRight",Down:"ArrowDown",Del:"Delete",Win:"OS",Menu:"ContextMenu",Apps:"ContextMenu",Scroll:"ScrollLock",MozPrintableKey:"Unidentified"},w1={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"},x1={Alt:"altKey",Control:"ctrlKey",Meta:"metaKey",Shift:"shiftKey"};function S1(e){var t=this.nativeEvent;return t.getModifierState?t.getModifierState(e):(e=x1[e])?!!t[e]:!1}function hf(){return S1}var b1=ye({},oo,{key:function(e){if(e.key){var t=v1[e.key]||e.key;if(t!=="Unidentified")return t}return e.type==="keypress"?(e=Go(e),e===13?"Enter":String.fromCharCode(e)):e.type==="keydown"||e.type==="keyup"?w1[e.keyCode]||"Unidentified":""},code:0,location:0,ctrlKey:0,shiftKey:0,altKey:0,metaKey:0,repeat:0,locale:0,getModifierState:hf,charCode:function(e){return e.type==="keypress"?Go(e):0},keyCode:function(e){return e.type==="keydown"||e.type==="keyup"?e.keyCode:0},which:function(e){return e.type==="keypress"?Go(e):e.type==="keydown"||e.type==="keyup"?e.keyCode:0}}),E1=Et(b1),_1=ye({},Ql,{pointerId:0,width:0,height:0,pressure:0,tangentialPressure:0,tiltX:0,tiltY:0,twist:0,pointerType:0,isPrimary:0}),Hd=Et(_1),k1=ye({},oo,{touches:0,targetTouches:0,changedTouches:0,altKey:0,metaKey:0,ctrlKey:0,shiftKey:0,getModifierState:hf}),C1=Et(k1),T1=ye({},Gi,{propertyName:0,elapsedTime:0,pseudoElement:0}),O1=Et(T1),R1=ye({},Ql,{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}),N1=Et(R1),P1=[9,13,27,32],pf=Cn&&"CompositionEvent"in window,bs=null;Cn&&"documentMode"in document&&(bs=document.documentMode);var A1=Cn&&"TextEvent"in window&&!bs,Km=Cn&&(!pf||bs&&8<bs&&11>=bs),Wd=" ",Qd=!1;function Ym(e,t){switch(e){case"keyup":return P1.indexOf(t.keyCode)!==-1;case"keydown":return t.keyCode!==229;case"keypress":case"mousedown":case"focusout":return!0;default:return!1}}function Gm(e){return e=e.detail,typeof e=="object"&&"data"in e?e.data:null}var ai=!1;function j1(e,t){switch(e){case"compositionend":return Gm(t);case"keypress":return t.which!==32?null:(Qd=!0,Wd);case"textInput":return e=t.data,e===Wd&&Qd?null:e;default:return null}}function F1(e,t){if(ai)return e==="compositionend"||!pf&&Ym(e,t)?(e=qm(),Yo=ff=Xn=null,ai=!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 Km&&t.locale!=="ko"?null:t.data;default:return null}}var $1={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 qd(e){var t=e&&e.nodeName&&e.nodeName.toLowerCase();return t==="input"?!!$1[e.type]:t==="textarea"}function Xm(e,t,n,r){Om(r),t=wl(t,"onChange"),0<t.length&&(n=new df("onChange","change",null,n,r),e.push({event:n,listeners:t}))}var Es=null,Ds=null;function I1(e){a0(e,0)}function ql(e){var t=fi(e);if(Sm(t))return e}function D1(e,t){if(e==="change")return t}var Zm=!1;if(Cn){var Wa;if(Cn){var Qa="oninput"in document;if(!Qa){var Kd=document.createElement("div");Kd.setAttribute("oninput","return;"),Qa=typeof Kd.oninput=="function"}Wa=Qa}else Wa=!1;Zm=Wa&&(!document.documentMode||9<document.documentMode)}function Yd(){Es&&(Es.detachEvent("onpropertychange",Jm),Ds=Es=null)}function Jm(e){if(e.propertyName==="value"&&ql(Ds)){var t=[];Xm(t,Ds,e,of(e)),Am(I1,t)}}function L1(e,t,n){e==="focusin"?(Yd(),Es=t,Ds=n,Es.attachEvent("onpropertychange",Jm)):e==="focusout"&&Yd()}function M1(e){if(e==="selectionchange"||e==="keyup"||e==="keydown")return ql(Ds)}function z1(e,t){if(e==="click")return ql(t)}function B1(e,t){if(e==="input"||e==="change")return ql(t)}function U1(e,t){return e===t&&(e!==0||1/e===1/t)||e!==e&&t!==t}var Gt=typeof Object.is=="function"?Object.is:U1;function Ls(e,t){if(Gt(e,t))return!0;if(typeof e!="object"||e===null||typeof t!="object"||t===null)return!1;var n=Object.keys(e),r=Object.keys(t);if(n.length!==r.length)return!1;for(r=0;r<n.length;r++){var i=n[r];if(!bu.call(t,i)||!Gt(e[i],t[i]))return!1}return!0}function Gd(e){for(;e&&e.firstChild;)e=e.firstChild;return e}function Xd(e,t){var n=Gd(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=Gd(n)}}function e0(e,t){return e&&t?e===t?!0:e&&e.nodeType===3?!1:t&&t.nodeType===3?e0(e,t.parentNode):"contains"in e?e.contains(t):e.compareDocumentPosition?!!(e.compareDocumentPosition(t)&16):!1:!1}function t0(){for(var e=window,t=dl();t instanceof e.HTMLIFrameElement;){try{var n=typeof t.contentWindow.location.href=="string"}catch{n=!1}if(n)e=t.contentWindow;else break;t=dl(e.document)}return t}function mf(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 V1(e){var t=t0(),n=e.focusedElem,r=e.selectionRange;if(t!==n&&n&&n.ownerDocument&&e0(n.ownerDocument.documentElement,n)){if(r!==null&&mf(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=Xd(n,s);var o=Xd(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 H1=Cn&&"documentMode"in document&&11>=document.documentMode,ui=null,Bu=null,_s=null,Uu=!1;function Zd(e,t,n){var r=n.window===n?n.document:n.nodeType===9?n:n.ownerDocument;Uu||ui==null||ui!==dl(r)||(r=ui,"selectionStart"in r&&mf(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}),_s&&Ls(_s,r)||(_s=r,r=wl(Bu,"onSelect"),0<r.length&&(t=new df("onSelect","select",null,t,n),e.push({event:t,listeners:r}),t.target=ui)))}function No(e,t){var n={};return n[e.toLowerCase()]=t.toLowerCase(),n["Webkit"+e]="webkit"+t,n["Moz"+e]="moz"+t,n}var ci={animationend:No("Animation","AnimationEnd"),animationiteration:No("Animation","AnimationIteration"),animationstart:No("Animation","AnimationStart"),transitionend:No("Transition","TransitionEnd")},qa={},n0={};Cn&&(n0=document.createElement("div").style,"AnimationEvent"in window||(delete ci.animationend.animation,delete ci.animationiteration.animation,delete ci.animationstart.animation),"TransitionEvent"in window||delete ci.transitionend.transition);function Kl(e){if(qa[e])return qa[e];if(!ci[e])return e;var t=ci[e],n;for(n in t)if(t.hasOwnProperty(n)&&n in n0)return qa[e]=t[n];return e}var r0=Kl("animationend"),i0=Kl("animationiteration"),s0=Kl("animationstart"),o0=Kl("transitionend"),l0=new Map,Jd="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 hr(e,t){l0.set(e,t),Kr(t,[e])}for(var Ka=0;Ka<Jd.length;Ka++){var Ya=Jd[Ka],W1=Ya.toLowerCase(),Q1=Ya[0].toUpperCase()+Ya.slice(1);hr(W1,"on"+Q1)}hr(r0,"onAnimationEnd");hr(i0,"onAnimationIteration");hr(s0,"onAnimationStart");hr("dblclick","onDoubleClick");hr("focusin","onFocus");hr("focusout","onBlur");hr(o0,"onTransitionEnd");Mi("onMouseEnter",["mouseout","mouseover"]);Mi("onMouseLeave",["mouseout","mouseover"]);Mi("onPointerEnter",["pointerout","pointerover"]);Mi("onPointerLeave",["pointerout","pointerover"]);Kr("onChange","change click focusin focusout input keydown keyup selectionchange".split(" "));Kr("onSelect","focusout contextmenu dragend focusin keydown keyup mousedown mouseup selectionchange".split(" "));Kr("onBeforeInput",["compositionend","keypress","textInput","paste"]);Kr("onCompositionEnd","compositionend focusout keydown keypress keyup mousedown".split(" "));Kr("onCompositionStart","compositionstart focusout keydown keypress keyup mousedown".split(" "));Kr("onCompositionUpdate","compositionupdate focusout keydown keypress keyup mousedown".split(" "));var gs="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(" "),q1=new Set("cancel close invalid load scroll toggle".split(" ").concat(gs));function eh(e,t,n){var r=e.type||"unknown-event";e.currentTarget=n,Wv(r,t,void 0,e),e.currentTarget=null}function a0(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,c=l.currentTarget;if(l=l.listener,a!==s&&i.isPropagationStopped())break e;eh(i,l,c),s=a}else for(o=0;o<r.length;o++){if(l=r[o],a=l.instance,c=l.currentTarget,l=l.listener,a!==s&&i.isPropagationStopped())break e;eh(i,l,c),s=a}}}if(pl)throw e=Du,pl=!1,Du=null,e}function ue(e,t){var n=t[qu];n===void 0&&(n=t[qu]=new Set);var r=e+"__bubble";n.has(r)||(u0(t,e,2,!1),n.add(r))}function Ga(e,t,n){var r=0;t&&(r|=4),u0(n,e,r,t)}var Po="_reactListening"+Math.random().toString(36).slice(2);function Ms(e){if(!e[Po]){e[Po]=!0,ym.forEach(function(n){n!=="selectionchange"&&(q1.has(n)||Ga(n,!1,e),Ga(n,!0,e))});var t=e.nodeType===9?e:e.ownerDocument;t===null||t[Po]||(t[Po]=!0,Ga("selectionchange",!1,t))}}function u0(e,t,n,r){switch(Qm(t)){case 1:var i=l1;break;case 4:i=a1;break;default:i=cf}n=i.bind(null,t,n,e),i=void 0,!Iu||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 Xa(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=_r(l),o===null)return;if(a=o.tag,a===5||a===6){r=s=o;continue e}l=l.parentNode}}r=r.return}Am(function(){var c=s,f=of(n),u=[];e:{var d=l0.get(e);if(d!==void 0){var h=df,v=e;switch(e){case"keypress":if(Go(n)===0)break e;case"keydown":case"keyup":h=E1;break;case"focusin":v="focus",h=Ha;break;case"focusout":v="blur",h=Ha;break;case"beforeblur":case"afterblur":h=Ha;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":h=Ud;break;case"drag":case"dragend":case"dragenter":case"dragexit":case"dragleave":case"dragover":case"dragstart":case"drop":h=f1;break;case"touchcancel":case"touchend":case"touchmove":case"touchstart":h=C1;break;case r0:case i0:case s0:h=p1;break;case o0:h=O1;break;case"scroll":h=u1;break;case"wheel":h=N1;break;case"copy":case"cut":case"paste":h=y1;break;case"gotpointercapture":case"lostpointercapture":case"pointercancel":case"pointerdown":case"pointermove":case"pointerout":case"pointerover":case"pointerup":h=Hd}var w=(t&4)!==0,S=!w&&e==="scroll",m=w?d!==null?d+"Capture":null:d;w=[];for(var p=c,g;p!==null;){g=p;var x=g.stateNode;if(g.tag===5&&x!==null&&(g=x,m!==null&&(x=js(p,m),x!=null&&w.push(zs(p,x,g)))),S)break;p=p.return}0<w.length&&(d=new h(d,v,null,n,f),u.push({event:d,listeners:w}))}}if(!(t&7)){e:{if(d=e==="mouseover"||e==="pointerover",h=e==="mouseout"||e==="pointerout",d&&n!==Fu&&(v=n.relatedTarget||n.fromElement)&&(_r(v)||v[Tn]))break e;if((h||d)&&(d=f.window===f?f:(d=f.ownerDocument)?d.defaultView||d.parentWindow:window,h?(v=n.relatedTarget||n.toElement,h=c,v=v?_r(v):null,v!==null&&(S=Yr(v),v!==S||v.tag!==5&&v.tag!==6)&&(v=null)):(h=null,v=c),h!==v)){if(w=Ud,x="onMouseLeave",m="onMouseEnter",p="mouse",(e==="pointerout"||e==="pointerover")&&(w=Hd,x="onPointerLeave",m="onPointerEnter",p="pointer"),S=h==null?d:fi(h),g=v==null?d:fi(v),d=new w(x,p+"leave",h,n,f),d.target=S,d.relatedTarget=g,x=null,_r(f)===c&&(w=new w(m,p+"enter",v,n,f),w.target=g,w.relatedTarget=S,x=w),S=x,h&&v)t:{for(w=h,m=v,p=0,g=w;g;g=ii(g))p++;for(g=0,x=m;x;x=ii(x))g++;for(;0<p-g;)w=ii(w),p--;for(;0<g-p;)m=ii(m),g--;for(;p--;){if(w===m||m!==null&&w===m.alternate)break t;w=ii(w),m=ii(m)}w=null}else w=null;h!==null&&th(u,d,h,w,!1),v!==null&&S!==null&&th(u,S,v,w,!0)}}e:{if(d=c?fi(c):window,h=d.nodeName&&d.nodeName.toLowerCase(),h==="select"||h==="input"&&d.type==="file")var C=D1;else if(qd(d))if(Zm)C=B1;else{C=M1;var T=L1}else(h=d.nodeName)&&h.toLowerCase()==="input"&&(d.type==="checkbox"||d.type==="radio")&&(C=z1);if(C&&(C=C(e,c))){Xm(u,C,n,f);break e}T&&T(e,d,c),e==="focusout"&&(T=d._wrapperState)&&T.controlled&&d.type==="number"&&Ru(d,"number",d.value)}switch(T=c?fi(c):window,e){case"focusin":(qd(T)||T.contentEditable==="true")&&(ui=T,Bu=c,_s=null);break;case"focusout":_s=Bu=ui=null;break;case"mousedown":Uu=!0;break;case"contextmenu":case"mouseup":case"dragend":Uu=!1,Zd(u,n,f);break;case"selectionchange":if(H1)break;case"keydown":case"keyup":Zd(u,n,f)}var k;if(pf)e:{switch(e){case"compositionstart":var R="onCompositionStart";break e;case"compositionend":R="onCompositionEnd";break e;case"compositionupdate":R="onCompositionUpdate";break e}R=void 0}else ai?Ym(e,n)&&(R="onCompositionEnd"):e==="keydown"&&n.keyCode===229&&(R="onCompositionStart");R&&(Km&&n.locale!=="ko"&&(ai||R!=="onCompositionStart"?R==="onCompositionEnd"&&ai&&(k=qm()):(Xn=f,ff="value"in Xn?Xn.value:Xn.textContent,ai=!0)),T=wl(c,R),0<T.length&&(R=new Vd(R,e,null,n,f),u.push({event:R,listeners:T}),k?R.data=k:(k=Gm(n),k!==null&&(R.data=k)))),(k=A1?j1(e,n):F1(e,n))&&(c=wl(c,"onBeforeInput"),0<c.length&&(f=new Vd("onBeforeInput","beforeinput",null,n,f),u.push({event:f,listeners:c}),f.data=k))}a0(u,t)})}function zs(e,t,n){return{instance:e,listener:t,currentTarget:n}}function wl(e,t){for(var n=t+"Capture",r=[];e!==null;){var i=e,s=i.stateNode;i.tag===5&&s!==null&&(i=s,s=js(e,n),s!=null&&r.unshift(zs(e,s,i)),s=js(e,t),s!=null&&r.push(zs(e,s,i))),e=e.return}return r}function ii(e){if(e===null)return null;do e=e.return;while(e&&e.tag!==5);return e||null}function th(e,t,n,r,i){for(var s=t._reactName,o=[];n!==null&&n!==r;){var l=n,a=l.alternate,c=l.stateNode;if(a!==null&&a===r)break;l.tag===5&&c!==null&&(l=c,i?(a=js(n,s),a!=null&&o.unshift(zs(n,a,l))):i||(a=js(n,s),a!=null&&o.push(zs(n,a,l)))),n=n.return}o.length!==0&&e.push({event:t,listeners:o})}var K1=/\r\n?/g,Y1=/\u0000|\uFFFD/g;function nh(e){return(typeof e=="string"?e:""+e).replace(K1,`
38
+ `).replace(Y1,"")}function Ao(e,t,n){if(t=nh(t),nh(e)!==t&&n)throw Error(O(425))}function xl(){}var Vu=null,Hu=null;function Wu(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 Qu=typeof setTimeout=="function"?setTimeout:void 0,G1=typeof clearTimeout=="function"?clearTimeout:void 0,rh=typeof Promise=="function"?Promise:void 0,X1=typeof queueMicrotask=="function"?queueMicrotask:typeof rh<"u"?function(e){return rh.resolve(null).then(e).catch(Z1)}:Qu;function Z1(e){setTimeout(function(){throw e})}function Za(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),Is(t);return}r--}else n!=="$"&&n!=="$?"&&n!=="$!"||r++;n=i}while(n);Is(t)}function rr(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 ih(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 Xi=Math.random().toString(36).slice(2),ln="__reactFiber$"+Xi,Bs="__reactProps$"+Xi,Tn="__reactContainer$"+Xi,qu="__reactEvents$"+Xi,J1="__reactListeners$"+Xi,ew="__reactHandles$"+Xi;function _r(e){var t=e[ln];if(t)return t;for(var n=e.parentNode;n;){if(t=n[Tn]||n[ln]){if(n=t.alternate,t.child!==null||n!==null&&n.child!==null)for(e=ih(e);e!==null;){if(n=e[ln])return n;e=ih(e)}return t}e=n,n=e.parentNode}return null}function lo(e){return e=e[ln]||e[Tn],!e||e.tag!==5&&e.tag!==6&&e.tag!==13&&e.tag!==3?null:e}function fi(e){if(e.tag===5||e.tag===6)return e.stateNode;throw Error(O(33))}function Yl(e){return e[Bs]||null}var Ku=[],di=-1;function pr(e){return{current:e}}function fe(e){0>di||(e.current=Ku[di],Ku[di]=null,di--)}function ae(e,t){di++,Ku[di]=e.current,e.current=t}var fr={},Ue=pr(fr),lt=pr(!1),zr=fr;function zi(e,t){var n=e.type.contextTypes;if(!n)return fr;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 at(e){return e=e.childContextTypes,e!=null}function Sl(){fe(lt),fe(Ue)}function sh(e,t,n){if(Ue.current!==fr)throw Error(O(168));ae(Ue,t),ae(lt,n)}function c0(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(O(108,Lv(e)||"Unknown",i));return ye({},n,r)}function bl(e){return e=(e=e.stateNode)&&e.__reactInternalMemoizedMergedChildContext||fr,zr=Ue.current,ae(Ue,e),ae(lt,lt.current),!0}function oh(e,t,n){var r=e.stateNode;if(!r)throw Error(O(169));n?(e=c0(e,t,zr),r.__reactInternalMemoizedMergedChildContext=e,fe(lt),fe(Ue),ae(Ue,e)):fe(lt),ae(lt,n)}var wn=null,Gl=!1,Ja=!1;function f0(e){wn===null?wn=[e]:wn.push(e)}function tw(e){Gl=!0,f0(e)}function mr(){if(!Ja&&wn!==null){Ja=!0;var e=0,t=re;try{var n=wn;for(re=1;e<n.length;e++){var r=n[e];do r=r(!0);while(r!==null)}wn=null,Gl=!1}catch(i){throw wn!==null&&(wn=wn.slice(e+1)),Im(lf,mr),i}finally{re=t,Ja=!1}}return null}var hi=[],pi=0,El=null,_l=0,Rt=[],Nt=0,Br=null,bn=1,En="";function Sr(e,t){hi[pi++]=_l,hi[pi++]=El,El=e,_l=t}function d0(e,t,n){Rt[Nt++]=bn,Rt[Nt++]=En,Rt[Nt++]=Br,Br=e;var r=bn;e=En;var i=32-Kt(r)-1;r&=~(1<<i),n+=1;var s=32-Kt(t)+i;if(30<s){var o=i-i%5;s=(r&(1<<o)-1).toString(32),r>>=o,i-=o,bn=1<<32-Kt(t)+i|n<<i|r,En=s+e}else bn=1<<s|n<<i|r,En=e}function yf(e){e.return!==null&&(Sr(e,1),d0(e,1,0))}function gf(e){for(;e===El;)El=hi[--pi],hi[pi]=null,_l=hi[--pi],hi[pi]=null;for(;e===Br;)Br=Rt[--Nt],Rt[Nt]=null,En=Rt[--Nt],Rt[Nt]=null,bn=Rt[--Nt],Rt[Nt]=null}var xt=null,gt=null,he=!1,Ht=null;function h0(e,t){var n=At(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 lh(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,xt=e,gt=rr(t.firstChild),!0):!1;case 6:return t=e.pendingProps===""||t.nodeType!==3?null:t,t!==null?(e.stateNode=t,xt=e,gt=null,!0):!1;case 13:return t=t.nodeType!==8?null:t,t!==null?(n=Br!==null?{id:bn,overflow:En}:null,e.memoizedState={dehydrated:t,treeContext:n,retryLane:1073741824},n=At(18,null,null,0),n.stateNode=t,n.return=e,e.child=n,xt=e,gt=null,!0):!1;default:return!1}}function Yu(e){return(e.mode&1)!==0&&(e.flags&128)===0}function Gu(e){if(he){var t=gt;if(t){var n=t;if(!lh(e,t)){if(Yu(e))throw Error(O(418));t=rr(n.nextSibling);var r=xt;t&&lh(e,t)?h0(r,n):(e.flags=e.flags&-4097|2,he=!1,xt=e)}}else{if(Yu(e))throw Error(O(418));e.flags=e.flags&-4097|2,he=!1,xt=e}}}function ah(e){for(e=e.return;e!==null&&e.tag!==5&&e.tag!==3&&e.tag!==13;)e=e.return;xt=e}function jo(e){if(e!==xt)return!1;if(!he)return ah(e),he=!0,!1;var t;if((t=e.tag!==3)&&!(t=e.tag!==5)&&(t=e.type,t=t!=="head"&&t!=="body"&&!Wu(e.type,e.memoizedProps)),t&&(t=gt)){if(Yu(e))throw p0(),Error(O(418));for(;t;)h0(e,t),t=rr(t.nextSibling)}if(ah(e),e.tag===13){if(e=e.memoizedState,e=e!==null?e.dehydrated:null,!e)throw Error(O(317));e:{for(e=e.nextSibling,t=0;e;){if(e.nodeType===8){var n=e.data;if(n==="/$"){if(t===0){gt=rr(e.nextSibling);break e}t--}else n!=="$"&&n!=="$!"&&n!=="$?"||t++}e=e.nextSibling}gt=null}}else gt=xt?rr(e.stateNode.nextSibling):null;return!0}function p0(){for(var e=gt;e;)e=rr(e.nextSibling)}function Bi(){gt=xt=null,he=!1}function vf(e){Ht===null?Ht=[e]:Ht.push(e)}var nw=Nn.ReactCurrentBatchConfig;function us(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(O(309));var r=n.stateNode}if(!r)throw Error(O(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(O(284));if(!n._owner)throw Error(O(290,e))}return e}function Fo(e,t){throw e=Object.prototype.toString.call(t),Error(O(31,e==="[object Object]"?"object with keys {"+Object.keys(t).join(", ")+"}":e))}function uh(e){var t=e._init;return t(e._payload)}function m0(e){function t(m,p){if(e){var g=m.deletions;g===null?(m.deletions=[p],m.flags|=16):g.push(p)}}function n(m,p){if(!e)return null;for(;p!==null;)t(m,p),p=p.sibling;return null}function r(m,p){for(m=new Map;p!==null;)p.key!==null?m.set(p.key,p):m.set(p.index,p),p=p.sibling;return m}function i(m,p){return m=lr(m,p),m.index=0,m.sibling=null,m}function s(m,p,g){return m.index=g,e?(g=m.alternate,g!==null?(g=g.index,g<p?(m.flags|=2,p):g):(m.flags|=2,p)):(m.flags|=1048576,p)}function o(m){return e&&m.alternate===null&&(m.flags|=2),m}function l(m,p,g,x){return p===null||p.tag!==6?(p=ou(g,m.mode,x),p.return=m,p):(p=i(p,g),p.return=m,p)}function a(m,p,g,x){var C=g.type;return C===li?f(m,p,g.props.children,x,g.key):p!==null&&(p.elementType===C||typeof C=="object"&&C!==null&&C.$$typeof===Ln&&uh(C)===p.type)?(x=i(p,g.props),x.ref=us(m,p,g),x.return=m,x):(x=rl(g.type,g.key,g.props,null,m.mode,x),x.ref=us(m,p,g),x.return=m,x)}function c(m,p,g,x){return p===null||p.tag!==4||p.stateNode.containerInfo!==g.containerInfo||p.stateNode.implementation!==g.implementation?(p=lu(g,m.mode,x),p.return=m,p):(p=i(p,g.children||[]),p.return=m,p)}function f(m,p,g,x,C){return p===null||p.tag!==7?(p=Ir(g,m.mode,x,C),p.return=m,p):(p=i(p,g),p.return=m,p)}function u(m,p,g){if(typeof p=="string"&&p!==""||typeof p=="number")return p=ou(""+p,m.mode,g),p.return=m,p;if(typeof p=="object"&&p!==null){switch(p.$$typeof){case Eo:return g=rl(p.type,p.key,p.props,null,m.mode,g),g.ref=us(m,null,p),g.return=m,g;case oi:return p=lu(p,m.mode,g),p.return=m,p;case Ln:var x=p._init;return u(m,x(p._payload),g)}if(ms(p)||is(p))return p=Ir(p,m.mode,g,null),p.return=m,p;Fo(m,p)}return null}function d(m,p,g,x){var C=p!==null?p.key:null;if(typeof g=="string"&&g!==""||typeof g=="number")return C!==null?null:l(m,p,""+g,x);if(typeof g=="object"&&g!==null){switch(g.$$typeof){case Eo:return g.key===C?a(m,p,g,x):null;case oi:return g.key===C?c(m,p,g,x):null;case Ln:return C=g._init,d(m,p,C(g._payload),x)}if(ms(g)||is(g))return C!==null?null:f(m,p,g,x,null);Fo(m,g)}return null}function h(m,p,g,x,C){if(typeof x=="string"&&x!==""||typeof x=="number")return m=m.get(g)||null,l(p,m,""+x,C);if(typeof x=="object"&&x!==null){switch(x.$$typeof){case Eo:return m=m.get(x.key===null?g:x.key)||null,a(p,m,x,C);case oi:return m=m.get(x.key===null?g:x.key)||null,c(p,m,x,C);case Ln:var T=x._init;return h(m,p,g,T(x._payload),C)}if(ms(x)||is(x))return m=m.get(g)||null,f(p,m,x,C,null);Fo(p,x)}return null}function v(m,p,g,x){for(var C=null,T=null,k=p,R=p=0,I=null;k!==null&&R<g.length;R++){k.index>R?(I=k,k=null):I=k.sibling;var L=d(m,k,g[R],x);if(L===null){k===null&&(k=I);break}e&&k&&L.alternate===null&&t(m,k),p=s(L,p,R),T===null?C=L:T.sibling=L,T=L,k=I}if(R===g.length)return n(m,k),he&&Sr(m,R),C;if(k===null){for(;R<g.length;R++)k=u(m,g[R],x),k!==null&&(p=s(k,p,R),T===null?C=k:T.sibling=k,T=k);return he&&Sr(m,R),C}for(k=r(m,k);R<g.length;R++)I=h(k,m,R,g[R],x),I!==null&&(e&&I.alternate!==null&&k.delete(I.key===null?R:I.key),p=s(I,p,R),T===null?C=I:T.sibling=I,T=I);return e&&k.forEach(function(B){return t(m,B)}),he&&Sr(m,R),C}function w(m,p,g,x){var C=is(g);if(typeof C!="function")throw Error(O(150));if(g=C.call(g),g==null)throw Error(O(151));for(var T=C=null,k=p,R=p=0,I=null,L=g.next();k!==null&&!L.done;R++,L=g.next()){k.index>R?(I=k,k=null):I=k.sibling;var B=d(m,k,L.value,x);if(B===null){k===null&&(k=I);break}e&&k&&B.alternate===null&&t(m,k),p=s(B,p,R),T===null?C=B:T.sibling=B,T=B,k=I}if(L.done)return n(m,k),he&&Sr(m,R),C;if(k===null){for(;!L.done;R++,L=g.next())L=u(m,L.value,x),L!==null&&(p=s(L,p,R),T===null?C=L:T.sibling=L,T=L);return he&&Sr(m,R),C}for(k=r(m,k);!L.done;R++,L=g.next())L=h(k,m,R,L.value,x),L!==null&&(e&&L.alternate!==null&&k.delete(L.key===null?R:L.key),p=s(L,p,R),T===null?C=L:T.sibling=L,T=L);return e&&k.forEach(function(se){return t(m,se)}),he&&Sr(m,R),C}function S(m,p,g,x){if(typeof g=="object"&&g!==null&&g.type===li&&g.key===null&&(g=g.props.children),typeof g=="object"&&g!==null){switch(g.$$typeof){case Eo:e:{for(var C=g.key,T=p;T!==null;){if(T.key===C){if(C=g.type,C===li){if(T.tag===7){n(m,T.sibling),p=i(T,g.props.children),p.return=m,m=p;break e}}else if(T.elementType===C||typeof C=="object"&&C!==null&&C.$$typeof===Ln&&uh(C)===T.type){n(m,T.sibling),p=i(T,g.props),p.ref=us(m,T,g),p.return=m,m=p;break e}n(m,T);break}else t(m,T);T=T.sibling}g.type===li?(p=Ir(g.props.children,m.mode,x,g.key),p.return=m,m=p):(x=rl(g.type,g.key,g.props,null,m.mode,x),x.ref=us(m,p,g),x.return=m,m=x)}return o(m);case oi:e:{for(T=g.key;p!==null;){if(p.key===T)if(p.tag===4&&p.stateNode.containerInfo===g.containerInfo&&p.stateNode.implementation===g.implementation){n(m,p.sibling),p=i(p,g.children||[]),p.return=m,m=p;break e}else{n(m,p);break}else t(m,p);p=p.sibling}p=lu(g,m.mode,x),p.return=m,m=p}return o(m);case Ln:return T=g._init,S(m,p,T(g._payload),x)}if(ms(g))return v(m,p,g,x);if(is(g))return w(m,p,g,x);Fo(m,g)}return typeof g=="string"&&g!==""||typeof g=="number"?(g=""+g,p!==null&&p.tag===6?(n(m,p.sibling),p=i(p,g),p.return=m,m=p):(n(m,p),p=ou(g,m.mode,x),p.return=m,m=p),o(m)):n(m,p)}return S}var Ui=m0(!0),y0=m0(!1),kl=pr(null),Cl=null,mi=null,wf=null;function xf(){wf=mi=Cl=null}function Sf(e){var t=kl.current;fe(kl),e._currentValue=t}function Xu(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 Ei(e,t){Cl=e,wf=mi=null,e=e.dependencies,e!==null&&e.firstContext!==null&&(e.lanes&t&&(ot=!0),e.firstContext=null)}function Ft(e){var t=e._currentValue;if(wf!==e)if(e={context:e,memoizedValue:t,next:null},mi===null){if(Cl===null)throw Error(O(308));mi=e,Cl.dependencies={lanes:0,firstContext:e}}else mi=mi.next=e;return t}var kr=null;function bf(e){kr===null?kr=[e]:kr.push(e)}function g0(e,t,n,r){var i=t.interleaved;return i===null?(n.next=n,bf(t)):(n.next=i.next,i.next=n),t.interleaved=n,On(e,r)}function On(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 Mn=!1;function Ef(e){e.updateQueue={baseState:e.memoizedState,firstBaseUpdate:null,lastBaseUpdate:null,shared:{pending:null,interleaved:null,lanes:0},effects:null}}function v0(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 _n(e,t){return{eventTime:e,lane:t,tag:0,payload:null,callback:null,next:null}}function ir(e,t,n){var r=e.updateQueue;if(r===null)return null;if(r=r.shared,J&2){var i=r.pending;return i===null?t.next=t:(t.next=i.next,i.next=t),r.pending=t,On(e,n)}return i=r.interleaved,i===null?(t.next=t,bf(r)):(t.next=i.next,i.next=t),r.interleaved=t,On(e,n)}function Xo(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,af(e,n)}}function ch(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 Tl(e,t,n,r){var i=e.updateQueue;Mn=!1;var s=i.firstBaseUpdate,o=i.lastBaseUpdate,l=i.shared.pending;if(l!==null){i.shared.pending=null;var a=l,c=a.next;a.next=null,o===null?s=c:o.next=c,o=a;var f=e.alternate;f!==null&&(f=f.updateQueue,l=f.lastBaseUpdate,l!==o&&(l===null?f.firstBaseUpdate=c:l.next=c,f.lastBaseUpdate=a))}if(s!==null){var u=i.baseState;o=0,f=c=a=null,l=s;do{var d=l.lane,h=l.eventTime;if((r&d)===d){f!==null&&(f=f.next={eventTime:h,lane:0,tag:l.tag,payload:l.payload,callback:l.callback,next:null});e:{var v=e,w=l;switch(d=t,h=n,w.tag){case 1:if(v=w.payload,typeof v=="function"){u=v.call(h,u,d);break e}u=v;break e;case 3:v.flags=v.flags&-65537|128;case 0:if(v=w.payload,d=typeof v=="function"?v.call(h,u,d):v,d==null)break e;u=ye({},u,d);break e;case 2:Mn=!0}}l.callback!==null&&l.lane!==0&&(e.flags|=64,d=i.effects,d===null?i.effects=[l]:d.push(l))}else h={eventTime:h,lane:d,tag:l.tag,payload:l.payload,callback:l.callback,next:null},f===null?(c=f=h,a=u):f=f.next=h,o|=d;if(l=l.next,l===null){if(l=i.shared.pending,l===null)break;d=l,l=d.next,d.next=null,i.lastBaseUpdate=d,i.shared.pending=null}}while(!0);if(f===null&&(a=u),i.baseState=a,i.firstBaseUpdate=c,i.lastBaseUpdate=f,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);Vr|=o,e.lanes=o,e.memoizedState=u}}function fh(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(O(191,i));i.call(r)}}}var ao={},un=pr(ao),Us=pr(ao),Vs=pr(ao);function Cr(e){if(e===ao)throw Error(O(174));return e}function _f(e,t){switch(ae(Vs,t),ae(Us,e),ae(un,ao),e=t.nodeType,e){case 9:case 11:t=(t=t.documentElement)?t.namespaceURI:Pu(null,"");break;default:e=e===8?t.parentNode:t,t=e.namespaceURI||null,e=e.tagName,t=Pu(t,e)}fe(un),ae(un,t)}function Vi(){fe(un),fe(Us),fe(Vs)}function w0(e){Cr(Vs.current);var t=Cr(un.current),n=Pu(t,e.type);t!==n&&(ae(Us,e),ae(un,n))}function kf(e){Us.current===e&&(fe(un),fe(Us))}var pe=pr(0);function Ol(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 eu=[];function Cf(){for(var e=0;e<eu.length;e++)eu[e]._workInProgressVersionPrimary=null;eu.length=0}var Zo=Nn.ReactCurrentDispatcher,tu=Nn.ReactCurrentBatchConfig,Ur=0,me=null,Ee=null,Re=null,Rl=!1,ks=!1,Hs=0,rw=0;function Le(){throw Error(O(321))}function Tf(e,t){if(t===null)return!1;for(var n=0;n<t.length&&n<e.length;n++)if(!Gt(e[n],t[n]))return!1;return!0}function Of(e,t,n,r,i,s){if(Ur=s,me=t,t.memoizedState=null,t.updateQueue=null,t.lanes=0,Zo.current=e===null||e.memoizedState===null?lw:aw,e=n(r,i),ks){s=0;do{if(ks=!1,Hs=0,25<=s)throw Error(O(301));s+=1,Re=Ee=null,t.updateQueue=null,Zo.current=uw,e=n(r,i)}while(ks)}if(Zo.current=Nl,t=Ee!==null&&Ee.next!==null,Ur=0,Re=Ee=me=null,Rl=!1,t)throw Error(O(300));return e}function Rf(){var e=Hs!==0;return Hs=0,e}function en(){var e={memoizedState:null,baseState:null,baseQueue:null,queue:null,next:null};return Re===null?me.memoizedState=Re=e:Re=Re.next=e,Re}function $t(){if(Ee===null){var e=me.alternate;e=e!==null?e.memoizedState:null}else e=Ee.next;var t=Re===null?me.memoizedState:Re.next;if(t!==null)Re=t,Ee=e;else{if(e===null)throw Error(O(310));Ee=e,e={memoizedState:Ee.memoizedState,baseState:Ee.baseState,baseQueue:Ee.baseQueue,queue:Ee.queue,next:null},Re===null?me.memoizedState=Re=e:Re=Re.next=e}return Re}function Ws(e,t){return typeof t=="function"?t(e):t}function nu(e){var t=$t(),n=t.queue;if(n===null)throw Error(O(311));n.lastRenderedReducer=e;var r=Ee,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,c=s;do{var f=c.lane;if((Ur&f)===f)a!==null&&(a=a.next={lane:0,action:c.action,hasEagerState:c.hasEagerState,eagerState:c.eagerState,next:null}),r=c.hasEagerState?c.eagerState:e(r,c.action);else{var u={lane:f,action:c.action,hasEagerState:c.hasEagerState,eagerState:c.eagerState,next:null};a===null?(l=a=u,o=r):a=a.next=u,me.lanes|=f,Vr|=f}c=c.next}while(c!==null&&c!==s);a===null?o=r:a.next=l,Gt(r,t.memoizedState)||(ot=!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,me.lanes|=s,Vr|=s,i=i.next;while(i!==e)}else i===null&&(n.lanes=0);return[t.memoizedState,n.dispatch]}function ru(e){var t=$t(),n=t.queue;if(n===null)throw Error(O(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);Gt(s,t.memoizedState)||(ot=!0),t.memoizedState=s,t.baseQueue===null&&(t.baseState=s),n.lastRenderedState=s}return[s,r]}function x0(){}function S0(e,t){var n=me,r=$t(),i=t(),s=!Gt(r.memoizedState,i);if(s&&(r.memoizedState=i,ot=!0),r=r.queue,Nf(_0.bind(null,n,r,e),[e]),r.getSnapshot!==t||s||Re!==null&&Re.memoizedState.tag&1){if(n.flags|=2048,Qs(9,E0.bind(null,n,r,i,t),void 0,null),Ne===null)throw Error(O(349));Ur&30||b0(n,t,i)}return i}function b0(e,t,n){e.flags|=16384,e={getSnapshot:t,value:n},t=me.updateQueue,t===null?(t={lastEffect:null,stores:null},me.updateQueue=t,t.stores=[e]):(n=t.stores,n===null?t.stores=[e]:n.push(e))}function E0(e,t,n,r){t.value=n,t.getSnapshot=r,k0(t)&&C0(e)}function _0(e,t,n){return n(function(){k0(t)&&C0(e)})}function k0(e){var t=e.getSnapshot;e=e.value;try{var n=t();return!Gt(e,n)}catch{return!0}}function C0(e){var t=On(e,1);t!==null&&Yt(t,e,1,-1)}function dh(e){var t=en();return typeof e=="function"&&(e=e()),t.memoizedState=t.baseState=e,e={pending:null,interleaved:null,lanes:0,dispatch:null,lastRenderedReducer:Ws,lastRenderedState:e},t.queue=e,e=e.dispatch=ow.bind(null,me,e),[t.memoizedState,e]}function Qs(e,t,n,r){return e={tag:e,create:t,destroy:n,deps:r,next:null},t=me.updateQueue,t===null?(t={lastEffect:null,stores:null},me.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 T0(){return $t().memoizedState}function Jo(e,t,n,r){var i=en();me.flags|=e,i.memoizedState=Qs(1|t,n,void 0,r===void 0?null:r)}function Xl(e,t,n,r){var i=$t();r=r===void 0?null:r;var s=void 0;if(Ee!==null){var o=Ee.memoizedState;if(s=o.destroy,r!==null&&Tf(r,o.deps)){i.memoizedState=Qs(t,n,s,r);return}}me.flags|=e,i.memoizedState=Qs(1|t,n,s,r)}function hh(e,t){return Jo(8390656,8,e,t)}function Nf(e,t){return Xl(2048,8,e,t)}function O0(e,t){return Xl(4,2,e,t)}function R0(e,t){return Xl(4,4,e,t)}function N0(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 P0(e,t,n){return n=n!=null?n.concat([e]):null,Xl(4,4,N0.bind(null,t,e),n)}function Pf(){}function A0(e,t){var n=$t();t=t===void 0?null:t;var r=n.memoizedState;return r!==null&&t!==null&&Tf(t,r[1])?r[0]:(n.memoizedState=[e,t],e)}function j0(e,t){var n=$t();t=t===void 0?null:t;var r=n.memoizedState;return r!==null&&t!==null&&Tf(t,r[1])?r[0]:(e=e(),n.memoizedState=[e,t],e)}function F0(e,t,n){return Ur&21?(Gt(n,t)||(n=Mm(),me.lanes|=n,Vr|=n,e.baseState=!0),t):(e.baseState&&(e.baseState=!1,ot=!0),e.memoizedState=n)}function iw(e,t){var n=re;re=n!==0&&4>n?n:4,e(!0);var r=tu.transition;tu.transition={};try{e(!1),t()}finally{re=n,tu.transition=r}}function $0(){return $t().memoizedState}function sw(e,t,n){var r=or(e);if(n={lane:r,action:n,hasEagerState:!1,eagerState:null,next:null},I0(e))D0(t,n);else if(n=g0(e,t,n,r),n!==null){var i=Ge();Yt(n,e,r,i),L0(n,t,r)}}function ow(e,t,n){var r=or(e),i={lane:r,action:n,hasEagerState:!1,eagerState:null,next:null};if(I0(e))D0(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,Gt(l,o)){var a=t.interleaved;a===null?(i.next=i,bf(t)):(i.next=a.next,a.next=i),t.interleaved=i;return}}catch{}finally{}n=g0(e,t,i,r),n!==null&&(i=Ge(),Yt(n,e,r,i),L0(n,t,r))}}function I0(e){var t=e.alternate;return e===me||t!==null&&t===me}function D0(e,t){ks=Rl=!0;var n=e.pending;n===null?t.next=t:(t.next=n.next,n.next=t),e.pending=t}function L0(e,t,n){if(n&4194240){var r=t.lanes;r&=e.pendingLanes,n|=r,t.lanes=n,af(e,n)}}var Nl={readContext:Ft,useCallback:Le,useContext:Le,useEffect:Le,useImperativeHandle:Le,useInsertionEffect:Le,useLayoutEffect:Le,useMemo:Le,useReducer:Le,useRef:Le,useState:Le,useDebugValue:Le,useDeferredValue:Le,useTransition:Le,useMutableSource:Le,useSyncExternalStore:Le,useId:Le,unstable_isNewReconciler:!1},lw={readContext:Ft,useCallback:function(e,t){return en().memoizedState=[e,t===void 0?null:t],e},useContext:Ft,useEffect:hh,useImperativeHandle:function(e,t,n){return n=n!=null?n.concat([e]):null,Jo(4194308,4,N0.bind(null,t,e),n)},useLayoutEffect:function(e,t){return Jo(4194308,4,e,t)},useInsertionEffect:function(e,t){return Jo(4,2,e,t)},useMemo:function(e,t){var n=en();return t=t===void 0?null:t,e=e(),n.memoizedState=[e,t],e},useReducer:function(e,t,n){var r=en();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=sw.bind(null,me,e),[r.memoizedState,e]},useRef:function(e){var t=en();return e={current:e},t.memoizedState=e},useState:dh,useDebugValue:Pf,useDeferredValue:function(e){return en().memoizedState=e},useTransition:function(){var e=dh(!1),t=e[0];return e=iw.bind(null,e[1]),en().memoizedState=e,[t,e]},useMutableSource:function(){},useSyncExternalStore:function(e,t,n){var r=me,i=en();if(he){if(n===void 0)throw Error(O(407));n=n()}else{if(n=t(),Ne===null)throw Error(O(349));Ur&30||b0(r,t,n)}i.memoizedState=n;var s={value:n,getSnapshot:t};return i.queue=s,hh(_0.bind(null,r,s,e),[e]),r.flags|=2048,Qs(9,E0.bind(null,r,s,n,t),void 0,null),n},useId:function(){var e=en(),t=Ne.identifierPrefix;if(he){var n=En,r=bn;n=(r&~(1<<32-Kt(r)-1)).toString(32)+n,t=":"+t+"R"+n,n=Hs++,0<n&&(t+="H"+n.toString(32)),t+=":"}else n=rw++,t=":"+t+"r"+n.toString(32)+":";return e.memoizedState=t},unstable_isNewReconciler:!1},aw={readContext:Ft,useCallback:A0,useContext:Ft,useEffect:Nf,useImperativeHandle:P0,useInsertionEffect:O0,useLayoutEffect:R0,useMemo:j0,useReducer:nu,useRef:T0,useState:function(){return nu(Ws)},useDebugValue:Pf,useDeferredValue:function(e){var t=$t();return F0(t,Ee.memoizedState,e)},useTransition:function(){var e=nu(Ws)[0],t=$t().memoizedState;return[e,t]},useMutableSource:x0,useSyncExternalStore:S0,useId:$0,unstable_isNewReconciler:!1},uw={readContext:Ft,useCallback:A0,useContext:Ft,useEffect:Nf,useImperativeHandle:P0,useInsertionEffect:O0,useLayoutEffect:R0,useMemo:j0,useReducer:ru,useRef:T0,useState:function(){return ru(Ws)},useDebugValue:Pf,useDeferredValue:function(e){var t=$t();return Ee===null?t.memoizedState=e:F0(t,Ee.memoizedState,e)},useTransition:function(){var e=ru(Ws)[0],t=$t().memoizedState;return[e,t]},useMutableSource:x0,useSyncExternalStore:S0,useId:$0,unstable_isNewReconciler:!1};function zt(e,t){if(e&&e.defaultProps){t=ye({},t),e=e.defaultProps;for(var n in e)t[n]===void 0&&(t[n]=e[n]);return t}return t}function Zu(e,t,n,r){t=e.memoizedState,n=n(r,t),n=n==null?t:ye({},t,n),e.memoizedState=n,e.lanes===0&&(e.updateQueue.baseState=n)}var Zl={isMounted:function(e){return(e=e._reactInternals)?Yr(e)===e:!1},enqueueSetState:function(e,t,n){e=e._reactInternals;var r=Ge(),i=or(e),s=_n(r,i);s.payload=t,n!=null&&(s.callback=n),t=ir(e,s,i),t!==null&&(Yt(t,e,i,r),Xo(t,e,i))},enqueueReplaceState:function(e,t,n){e=e._reactInternals;var r=Ge(),i=or(e),s=_n(r,i);s.tag=1,s.payload=t,n!=null&&(s.callback=n),t=ir(e,s,i),t!==null&&(Yt(t,e,i,r),Xo(t,e,i))},enqueueForceUpdate:function(e,t){e=e._reactInternals;var n=Ge(),r=or(e),i=_n(n,r);i.tag=2,t!=null&&(i.callback=t),t=ir(e,i,r),t!==null&&(Yt(t,e,r,n),Xo(t,e,r))}};function ph(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?!Ls(n,r)||!Ls(i,s):!0}function M0(e,t,n){var r=!1,i=fr,s=t.contextType;return typeof s=="object"&&s!==null?s=Ft(s):(i=at(t)?zr:Ue.current,r=t.contextTypes,s=(r=r!=null)?zi(e,i):fr),t=new t(n,s),e.memoizedState=t.state!==null&&t.state!==void 0?t.state:null,t.updater=Zl,e.stateNode=t,t._reactInternals=e,r&&(e=e.stateNode,e.__reactInternalMemoizedUnmaskedChildContext=i,e.__reactInternalMemoizedMaskedChildContext=s),t}function mh(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&&Zl.enqueueReplaceState(t,t.state,null)}function Ju(e,t,n,r){var i=e.stateNode;i.props=n,i.state=e.memoizedState,i.refs={},Ef(e);var s=t.contextType;typeof s=="object"&&s!==null?i.context=Ft(s):(s=at(t)?zr:Ue.current,i.context=zi(e,s)),i.state=e.memoizedState,s=t.getDerivedStateFromProps,typeof s=="function"&&(Zu(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&&Zl.enqueueReplaceState(i,i.state,null),Tl(e,n,i,r),i.state=e.memoizedState),typeof i.componentDidMount=="function"&&(e.flags|=4194308)}function Hi(e,t){try{var n="",r=t;do n+=Dv(r),r=r.return;while(r);var i=n}catch(s){i=`
39
39
  Error generating stack: `+s.message+`
40
- `+s.stack}return{value:e,source:t,stack:i,digest:null}}function iu(e,t,n){return{value:e,source:null,stack:n??null,digest:t??null}}function ec(e,t){try{console.error(t.value)}catch(n){setTimeout(function(){throw n})}}var uw=typeof WeakMap=="function"?WeakMap:Map;function z0(e,t,n){n=_n(-1,n),n.tag=3,n.payload={element:null};var r=t.value;return n.callback=function(){Al||(Al=!0,cc=r),ec(e,t)},n}function B0(e,t,n){n=_n(-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(){ec(e,t)}}var s=e.stateNode;return s!==null&&typeof s.componentDidCatch=="function"&&(n.callback=function(){ec(e,t),typeof r!="function"&&(sr===null?sr=new Set([this]):sr.add(this));var o=t.stack;this.componentDidCatch(t.value,{componentStack:o!==null?o:""})}),n}function gh(e,t,n){var r=e.pingCache;if(r===null){r=e.pingCache=new uw;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=Ew.bind(null,e,t,n),t.then(e,e))}function yh(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 vh(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=_n(-1,1),t.tag=2,ir(n,t,1))),n.lanes|=1),e)}var cw=Nn.ReactCurrentOwner,ot=!1;function Ye(e,t,n,r){t.child=e===null?g0(t,null,n,r):Ui(t,e.child,n,r)}function wh(e,t,n,r,i){n=n.render;var s=t.ref;return Ei(t,i),r=Of(e,t,n,r,s,i),n=Rf(),e!==null&&!ot?(t.updateQueue=e.updateQueue,t.flags&=-2053,e.lanes&=~i,Rn(e,t,i)):(he&&n&&gf(t),t.flags|=1,Ye(e,t,r,i),t.child)}function xh(e,t,n,r,i){if(e===null){var s=n.type;return typeof s=="function"&&!Mf(s)&&s.defaultProps===void 0&&n.compare===null&&n.defaultProps===void 0?(t.tag=15,t.type=s,U0(e,t,s,r,i)):(e=rl(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:Ds,n(o,r)&&e.ref===t.ref)return Rn(e,t,i)}return t.flags|=1,e=lr(s,r),e.ref=t.ref,e.return=t,t.child=e}function U0(e,t,n,r,i){if(e!==null){var s=e.memoizedProps;if(Ds(s,r)&&e.ref===t.ref)if(ot=!1,t.pendingProps=r=s,(e.lanes&i)!==0)e.flags&131072&&(ot=!0);else return t.lanes=e.lanes,Rn(e,t,i)}return tc(e,t,n,r,i)}function V0(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},ae(yi,mt),mt|=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,ae(yi,mt),mt|=e,null;t.memoizedState={baseLanes:0,cachePool:null,transitions:null},r=s!==null?s.baseLanes:n,ae(yi,mt),mt|=r}else s!==null?(r=s.baseLanes|n,t.memoizedState=null):r=n,ae(yi,mt),mt|=r;return Ye(e,t,i,n),t.child}function H0(e,t){var n=t.ref;(e===null&&n!==null||e!==null&&e.ref!==n)&&(t.flags|=512,t.flags|=2097152)}function tc(e,t,n,r,i){var s=at(n)?zr:Ue.current;return s=zi(t,s),Ei(t,i),n=Of(e,t,n,r,s,i),r=Rf(),e!==null&&!ot?(t.updateQueue=e.updateQueue,t.flags&=-2053,e.lanes&=~i,Rn(e,t,i)):(he&&r&&gf(t),t.flags|=1,Ye(e,t,n,i),t.child)}function Sh(e,t,n,r,i){if(at(n)){var s=!0;bl(t)}else s=!1;if(Ei(t,i),t.stateNode===null)el(e,t),M0(t,n,r),Ju(t,n,r,i),r=!0;else if(e===null){var o=t.stateNode,l=t.memoizedProps;o.props=l;var a=o.context,c=n.contextType;typeof c=="object"&&c!==null?c=Ft(c):(c=at(n)?zr:Ue.current,c=zi(t,c));var f=n.getDerivedStateFromProps,u=typeof f=="function"||typeof o.getSnapshotBeforeUpdate=="function";u||typeof o.UNSAFE_componentWillReceiveProps!="function"&&typeof o.componentWillReceiveProps!="function"||(l!==r||a!==c)&&mh(t,o,r,c),Mn=!1;var d=t.memoizedState;o.state=d,Tl(t,r,o,i),a=t.memoizedState,l!==r||d!==a||lt.current||Mn?(typeof f=="function"&&(Zu(t,n,f,r),a=t.memoizedState),(l=Mn||ph(t,n,l,r,d,a,c))?(u||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=c,r=l):(typeof o.componentDidMount=="function"&&(t.flags|=4194308),r=!1)}else{o=t.stateNode,v0(e,t),l=t.memoizedProps,c=t.type===t.elementType?l:zt(t.type,l),o.props=c,u=t.pendingProps,d=o.context,a=n.contextType,typeof a=="object"&&a!==null?a=Ft(a):(a=at(n)?zr:Ue.current,a=zi(t,a));var h=n.getDerivedStateFromProps;(f=typeof h=="function"||typeof o.getSnapshotBeforeUpdate=="function")||typeof o.UNSAFE_componentWillReceiveProps!="function"&&typeof o.componentWillReceiveProps!="function"||(l!==u||d!==a)&&mh(t,o,r,a),Mn=!1,d=t.memoizedState,o.state=d,Tl(t,r,o,i);var v=t.memoizedState;l!==u||d!==v||lt.current||Mn?(typeof h=="function"&&(Zu(t,n,h,r),v=t.memoizedState),(c=Mn||ph(t,n,c,r,d,v,a)||!1)?(f||typeof o.UNSAFE_componentWillUpdate!="function"&&typeof o.componentWillUpdate!="function"||(typeof o.componentWillUpdate=="function"&&o.componentWillUpdate(r,v,a),typeof o.UNSAFE_componentWillUpdate=="function"&&o.UNSAFE_componentWillUpdate(r,v,a)),typeof o.componentDidUpdate=="function"&&(t.flags|=4),typeof o.getSnapshotBeforeUpdate=="function"&&(t.flags|=1024)):(typeof o.componentDidUpdate!="function"||l===e.memoizedProps&&d===e.memoizedState||(t.flags|=4),typeof o.getSnapshotBeforeUpdate!="function"||l===e.memoizedProps&&d===e.memoizedState||(t.flags|=1024),t.memoizedProps=r,t.memoizedState=v),o.props=r,o.state=v,o.context=a,r=c):(typeof o.componentDidUpdate!="function"||l===e.memoizedProps&&d===e.memoizedState||(t.flags|=4),typeof o.getSnapshotBeforeUpdate!="function"||l===e.memoizedProps&&d===e.memoizedState||(t.flags|=1024),r=!1)}return nc(e,t,n,r,s,i)}function nc(e,t,n,r,i,s){H0(e,t);var o=(t.flags&128)!==0;if(!r&&!o)return i&&oh(t,n,!1),Rn(e,t,s);r=t.stateNode,cw.current=t;var l=o&&typeof n.getDerivedStateFromError!="function"?null:r.render();return t.flags|=1,e!==null&&o?(t.child=Ui(t,e.child,null,s),t.child=Ui(t,null,l,s)):Ye(e,t,l,s),t.memoizedState=r.state,i&&oh(t,n,!0),t.child}function W0(e){var t=e.stateNode;t.pendingContext?sh(e,t.pendingContext,t.pendingContext!==t.context):t.context&&sh(e,t.context,!1),_f(e,t.containerInfo)}function bh(e,t,n,r,i){return Bi(),vf(i),t.flags|=256,Ye(e,t,n,r),t.child}var rc={dehydrated:null,treeContext:null,retryLane:0};function ic(e){return{baseLanes:e,cachePool:null,transitions:null}}function Q0(e,t,n){var r=t.pendingProps,i=pe.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),ae(pe,i&1),e===null)return Gu(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=ta(o,r,0,null),e=Ir(e,r,n,null),s.return=t,e.return=t,s.sibling=e,t.child=s,t.child.memoizedState=ic(n),t.memoizedState=rc,e):Af(t,o));if(i=e.memoizedState,i!==null&&(l=i.dehydrated,l!==null))return fw(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=lr(i,a),r.subtreeFlags=i.subtreeFlags&14680064),l!==null?s=lr(l,s):(s=Ir(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?ic(n):{baseLanes:o.baseLanes|n,cachePool:null,transitions:o.transitions},s.memoizedState=o,s.childLanes=e.childLanes&~n,t.memoizedState=rc,r}return s=e.child,e=s.sibling,r=lr(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 Af(e,t){return t=ta({mode:"visible",children:t},e.mode,0,null),t.return=e,e.child=t}function $o(e,t,n,r){return r!==null&&vf(r),Ui(t,e.child,null,n),e=Af(t,t.pendingProps.children),e.flags|=2,t.memoizedState=null,e}function fw(e,t,n,r,i,s,o){if(n)return t.flags&256?(t.flags&=-257,r=iu(Error(O(422))),$o(e,t,o,r)):t.memoizedState!==null?(t.child=e.child,t.flags|=128,null):(s=r.fallback,i=t.mode,r=ta({mode:"visible",children:r.children},i,0,null),s=Ir(s,i,o,null),s.flags|=2,r.return=t,s.return=t,r.sibling=s,t.child=r,t.mode&1&&Ui(t,e.child,null,o),t.child.memoizedState=ic(o),t.memoizedState=rc,s);if(!(t.mode&1))return $o(e,t,o,null);if(i.data==="$!"){if(r=i.nextSibling&&i.nextSibling.dataset,r)var l=r.dgst;return r=l,s=Error(O(419)),r=iu(s,r,void 0),$o(e,t,o,r)}if(l=(o&e.childLanes)!==0,ot||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,On(e,i),Yt(r,e,i,-1))}return Df(),r=iu(Error(O(421))),$o(e,t,o,r)}return i.data==="$?"?(t.flags|=128,t.child=e.child,t=_w.bind(null,e),i._reactRetry=t,null):(e=s.treeContext,gt=rr(i.nextSibling),wt=t,he=!0,Ht=null,e!==null&&(Rt[Nt++]=bn,Rt[Nt++]=En,Rt[Nt++]=Br,bn=e.id,En=e.overflow,Br=t),t=Af(t,r.children),t.flags|=4096,t)}function Eh(e,t,n){e.lanes|=t;var r=e.alternate;r!==null&&(r.lanes|=t),Xu(e.return,t,n)}function su(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 q0(e,t,n){var r=t.pendingProps,i=r.revealOrder,s=r.tail;if(Ye(e,t,r.children,n),r=pe.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&&Eh(e,n,t);else if(e.tag===19)Eh(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(ae(pe,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&&Ol(e)===null&&(i=n),n=n.sibling;n=i,n===null?(i=t.child,t.child=null):(i=n.sibling,n.sibling=null),su(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&&Ol(e)===null){t.child=i;break}e=i.sibling,i.sibling=n,n=i,i=e}su(t,!0,n,null,s);break;case"together":su(t,!1,null,null,void 0);break;default:t.memoizedState=null}return t.child}function el(e,t){!(t.mode&1)&&e!==null&&(e.alternate=null,t.alternate=null,t.flags|=2)}function Rn(e,t,n){if(e!==null&&(t.dependencies=e.dependencies),Vr|=t.lanes,!(n&t.childLanes))return null;if(e!==null&&t.child!==e.child)throw Error(O(153));if(t.child!==null){for(e=t.child,n=lr(e,e.pendingProps),t.child=n,n.return=t;e.sibling!==null;)e=e.sibling,n=n.sibling=lr(e,e.pendingProps),n.return=t;n.sibling=null}return t.child}function dw(e,t,n){switch(t.tag){case 3:W0(t),Bi();break;case 5:w0(t);break;case 1:at(t.type)&&bl(t);break;case 4:_f(t,t.stateNode.containerInfo);break;case 10:var r=t.type._context,i=t.memoizedProps.value;ae(kl,r._currentValue),r._currentValue=i;break;case 13:if(r=t.memoizedState,r!==null)return r.dehydrated!==null?(ae(pe,pe.current&1),t.flags|=128,null):n&t.child.childLanes?Q0(e,t,n):(ae(pe,pe.current&1),e=Rn(e,t,n),e!==null?e.sibling:null);ae(pe,pe.current&1);break;case 19:if(r=(n&t.childLanes)!==0,e.flags&128){if(r)return q0(e,t,n);t.flags|=128}if(i=t.memoizedState,i!==null&&(i.rendering=null,i.tail=null,i.lastEffect=null),ae(pe,pe.current),r)break;return null;case 22:case 23:return t.lanes=0,V0(e,t,n)}return Rn(e,t,n)}var K0,sc,Y0,G0;K0=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}};sc=function(){};Y0=function(e,t,n,r){var i=e.memoizedProps;if(i!==r){e=t.stateNode,Cr(un.current);var s=null;switch(n){case"input":i=Tu(e,i),r=Tu(e,r),s=[];break;case"select":i=ge({},i,{value:void 0}),r=ge({},r,{value:void 0}),s=[];break;case"textarea":i=Nu(e,i),r=Nu(e,r),s=[];break;default:typeof i.onClick!="function"&&typeof r.onClick=="function"&&(e.onclick=xl)}Au(n,r);var o;n=null;for(c in i)if(!r.hasOwnProperty(c)&&i.hasOwnProperty(c)&&i[c]!=null)if(c==="style"){var l=i[c];for(o in l)l.hasOwnProperty(o)&&(n||(n={}),n[o]="")}else c!=="dangerouslySetInnerHTML"&&c!=="children"&&c!=="suppressContentEditableWarning"&&c!=="suppressHydrationWarning"&&c!=="autoFocus"&&(Ps.hasOwnProperty(c)?s||(s=[]):(s=s||[]).push(c,null));for(c in r){var a=r[c];if(l=i!=null?i[c]:void 0,r.hasOwnProperty(c)&&a!==l&&(a!=null||l!=null))if(c==="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(c,n)),n=a;else c==="dangerouslySetInnerHTML"?(a=a?a.__html:void 0,l=l?l.__html:void 0,a!=null&&l!==a&&(s=s||[]).push(c,a)):c==="children"?typeof a!="string"&&typeof a!="number"||(s=s||[]).push(c,""+a):c!=="suppressContentEditableWarning"&&c!=="suppressHydrationWarning"&&(Ps.hasOwnProperty(c)?(a!=null&&c==="onScroll"&&ue("scroll",e),s||l===a||(s=[])):(s=s||[]).push(c,a))}n&&(s=s||[]).push("style",n);var c=s;(t.updateQueue=c)&&(t.flags|=4)}};G0=function(e,t,n,r){n!==r&&(t.flags|=4)};function cs(e,t){if(!he)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 Me(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 hw(e,t,n){var r=t.pendingProps;switch(yf(t),t.tag){case 2:case 16:case 15:case 0:case 11:case 7:case 8:case 12:case 9:case 14:return Me(t),null;case 1:return at(t.type)&&Sl(),Me(t),null;case 3:return r=t.stateNode,Vi(),fe(lt),fe(Ue),Cf(),r.pendingContext&&(r.context=r.pendingContext,r.pendingContext=null),(e===null||e.child===null)&&(jo(t)?t.flags|=4:e===null||e.memoizedState.isDehydrated&&!(t.flags&256)||(t.flags|=1024,Ht!==null&&(hc(Ht),Ht=null))),sc(e,t),Me(t),null;case 5:kf(t);var i=Cr(Vs.current);if(n=t.type,e!==null&&t.stateNode!=null)Y0(e,t,n,r,i),e.ref!==t.ref&&(t.flags|=512,t.flags|=2097152);else{if(!r){if(t.stateNode===null)throw Error(O(166));return Me(t),null}if(e=Cr(un.current),jo(t)){r=t.stateNode,n=t.type;var s=t.memoizedProps;switch(r[ln]=t,r[Bs]=s,e=(t.mode&1)!==0,n){case"dialog":ue("cancel",r),ue("close",r);break;case"iframe":case"object":case"embed":ue("load",r);break;case"video":case"audio":for(i=0;i<ys.length;i++)ue(ys[i],r);break;case"source":ue("error",r);break;case"img":case"image":case"link":ue("error",r),ue("load",r);break;case"details":ue("toggle",r);break;case"input":Ad(r,s),ue("invalid",r);break;case"select":r._wrapperState={wasMultiple:!!s.multiple},ue("invalid",r);break;case"textarea":Fd(r,s),ue("invalid",r)}Au(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&&Ao(r.textContent,l,e),i=["children",l]):typeof l=="number"&&r.textContent!==""+l&&(s.suppressHydrationWarning!==!0&&Ao(r.textContent,l,e),i=["children",""+l]):Ps.hasOwnProperty(o)&&l!=null&&o==="onScroll"&&ue("scroll",r)}switch(n){case"input":_o(r),jd(r,s,!0);break;case"textarea":_o(r),$d(r);break;case"select":case"option":break;default:typeof s.onClick=="function"&&(r.onclick=xl)}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=_m(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[ln]=t,e[Bs]=r,K0(e,t,!1,!1),t.stateNode=e;e:{switch(o=ju(n,r),n){case"dialog":ue("cancel",e),ue("close",e),i=r;break;case"iframe":case"object":case"embed":ue("load",e),i=r;break;case"video":case"audio":for(i=0;i<ys.length;i++)ue(ys[i],e);i=r;break;case"source":ue("error",e),i=r;break;case"img":case"image":case"link":ue("error",e),ue("load",e),i=r;break;case"details":ue("toggle",e),i=r;break;case"input":Ad(e,r),i=Tu(e,r),ue("invalid",e);break;case"option":i=r;break;case"select":e._wrapperState={wasMultiple:!!r.multiple},i=ge({},r,{value:void 0}),ue("invalid",e);break;case"textarea":Fd(e,r),i=Nu(e,r),ue("invalid",e);break;default:i=r}Au(n,i),l=i;for(s in l)if(l.hasOwnProperty(s)){var a=l[s];s==="style"?Tm(e,a):s==="dangerouslySetInnerHTML"?(a=a?a.__html:void 0,a!=null&&km(e,a)):s==="children"?typeof a=="string"?(n!=="textarea"||a!=="")&&As(e,a):typeof a=="number"&&As(e,""+a):s!=="suppressContentEditableWarning"&&s!=="suppressHydrationWarning"&&s!=="autoFocus"&&(Ps.hasOwnProperty(s)?a!=null&&s==="onScroll"&&ue("scroll",e):a!=null&&tf(e,s,a,o))}switch(n){case"input":_o(e),jd(e,r,!1);break;case"textarea":_o(e),$d(e);break;case"option":r.value!=null&&e.setAttribute("value",""+cr(r.value));break;case"select":e.multiple=!!r.multiple,s=r.value,s!=null?wi(e,!!r.multiple,s,!1):r.defaultValue!=null&&wi(e,!!r.multiple,r.defaultValue,!0);break;default:typeof i.onClick=="function"&&(e.onclick=xl)}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 Me(t),null;case 6:if(e&&t.stateNode!=null)G0(e,t,e.memoizedProps,r);else{if(typeof r!="string"&&t.stateNode===null)throw Error(O(166));if(n=Cr(Vs.current),Cr(un.current),jo(t)){if(r=t.stateNode,n=t.memoizedProps,r[ln]=t,(s=r.nodeValue!==n)&&(e=wt,e!==null))switch(e.tag){case 3:Ao(r.nodeValue,n,(e.mode&1)!==0);break;case 5:e.memoizedProps.suppressHydrationWarning!==!0&&Ao(r.nodeValue,n,(e.mode&1)!==0)}s&&(t.flags|=4)}else r=(n.nodeType===9?n:n.ownerDocument).createTextNode(r),r[ln]=t,t.stateNode=r}return Me(t),null;case 13:if(fe(pe),r=t.memoizedState,e===null||e.memoizedState!==null&&e.memoizedState.dehydrated!==null){if(he&&gt!==null&&t.mode&1&&!(t.flags&128))p0(),Bi(),t.flags|=98560,s=!1;else if(s=jo(t),r!==null&&r.dehydrated!==null){if(e===null){if(!s)throw Error(O(318));if(s=t.memoizedState,s=s!==null?s.dehydrated:null,!s)throw Error(O(317));s[ln]=t}else Bi(),!(t.flags&128)&&(t.memoizedState=null),t.flags|=4;Me(t),s=!1}else Ht!==null&&(hc(Ht),Ht=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||pe.current&1?ke===0&&(ke=3):Df())),t.updateQueue!==null&&(t.flags|=4),Me(t),null);case 4:return Vi(),sc(e,t),e===null&&Ms(t.stateNode.containerInfo),Me(t),null;case 10:return Sf(t.type._context),Me(t),null;case 17:return at(t.type)&&Sl(),Me(t),null;case 19:if(fe(pe),s=t.memoizedState,s===null)return Me(t),null;if(r=(t.flags&128)!==0,o=s.rendering,o===null)if(r)cs(s,!1);else{if(ke!==0||e!==null&&e.flags&128)for(e=t.child;e!==null;){if(o=Ol(e),o!==null){for(t.flags|=128,cs(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 ae(pe,pe.current&1|2),t.child}e=e.sibling}s.tail!==null&&xe()>Wi&&(t.flags|=128,r=!0,cs(s,!1),t.lanes=4194304)}else{if(!r)if(e=Ol(o),e!==null){if(t.flags|=128,r=!0,n=e.updateQueue,n!==null&&(t.updateQueue=n,t.flags|=4),cs(s,!0),s.tail===null&&s.tailMode==="hidden"&&!o.alternate&&!he)return Me(t),null}else 2*xe()-s.renderingStartTime>Wi&&n!==1073741824&&(t.flags|=128,r=!0,cs(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=xe(),t.sibling=null,n=pe.current,ae(pe,r?n&1|2:n&1),t):(Me(t),null);case 22:case 23:return Lf(),r=t.memoizedState!==null,e!==null&&e.memoizedState!==null!==r&&(t.flags|=8192),r&&t.mode&1?mt&1073741824&&(Me(t),t.subtreeFlags&6&&(t.flags|=8192)):Me(t),null;case 24:return null;case 25:return null}throw Error(O(156,t.tag))}function pw(e,t){switch(yf(t),t.tag){case 1:return at(t.type)&&Sl(),e=t.flags,e&65536?(t.flags=e&-65537|128,t):null;case 3:return Vi(),fe(lt),fe(Ue),Cf(),e=t.flags,e&65536&&!(e&128)?(t.flags=e&-65537|128,t):null;case 5:return kf(t),null;case 13:if(fe(pe),e=t.memoizedState,e!==null&&e.dehydrated!==null){if(t.alternate===null)throw Error(O(340));Bi()}return e=t.flags,e&65536?(t.flags=e&-65537|128,t):null;case 19:return fe(pe),null;case 4:return Vi(),null;case 10:return Sf(t.type._context),null;case 22:case 23:return Lf(),null;case 24:return null;default:return null}}var Io=!1,Be=!1,mw=typeof WeakSet=="function"?WeakSet:Set,F=null;function gi(e,t){var n=e.ref;if(n!==null)if(typeof n=="function")try{n(null)}catch(r){ve(e,t,r)}else n.current=null}function oc(e,t,n){try{n()}catch(r){ve(e,t,r)}}var _h=!1;function gw(e,t){if(Vu=yl,e=t0(),mf(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,c=0,f=0,u=e,d=null;t:for(;;){for(var h;u!==n||i!==0&&u.nodeType!==3||(l=o+i),u!==s||r!==0&&u.nodeType!==3||(a=o+r),u.nodeType===3&&(o+=u.nodeValue.length),(h=u.firstChild)!==null;)d=u,u=h;for(;;){if(u===e)break t;if(d===n&&++c===i&&(l=o),d===s&&++f===r&&(a=o),(h=u.nextSibling)!==null)break;u=d,d=u.parentNode}u=h}n=l===-1||a===-1?null:{start:l,end:a}}else n=null}n=n||{start:0,end:0}}else n=null;for(Hu={focusedElem:e,selectionRange:n},yl=!1,F=t;F!==null;)if(t=F,e=t.child,(t.subtreeFlags&1028)!==0&&e!==null)e.return=t,F=e;else for(;F!==null;){t=F;try{var v=t.alternate;if(t.flags&1024)switch(t.tag){case 0:case 11:case 15:break;case 1:if(v!==null){var w=v.memoizedProps,S=v.memoizedState,m=t.stateNode,p=m.getSnapshotBeforeUpdate(t.elementType===t.type?w:zt(t.type,w),S);m.__reactInternalSnapshotBeforeUpdate=p}break;case 3:var y=t.stateNode.containerInfo;y.nodeType===1?y.textContent="":y.nodeType===9&&y.documentElement&&y.removeChild(y.documentElement);break;case 5:case 6:case 4:case 17:break;default:throw Error(O(163))}}catch(x){ve(t,t.return,x)}if(e=t.sibling,e!==null){e.return=t.return,F=e;break}F=t.return}return v=_h,_h=!1,v}function Cs(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&&oc(t,n,s)}i=i.next}while(i!==r)}}function Jl(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 lc(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 X0(e){var t=e.alternate;t!==null&&(e.alternate=null,X0(t)),e.child=null,e.deletions=null,e.sibling=null,e.tag===5&&(t=e.stateNode,t!==null&&(delete t[ln],delete t[Bs],delete t[qu],delete t[Z1],delete t[J1])),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 Z0(e){return e.tag===5||e.tag===3||e.tag===4}function kh(e){e:for(;;){for(;e.sibling===null;){if(e.return===null||Z0(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 ac(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=xl));else if(r!==4&&(e=e.child,e!==null))for(ac(e,t,n),e=e.sibling;e!==null;)ac(e,t,n),e=e.sibling}function uc(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(uc(e,t,n),e=e.sibling;e!==null;)uc(e,t,n),e=e.sibling}var Fe=null,Ut=!1;function In(e,t,n){for(n=n.child;n!==null;)J0(e,t,n),n=n.sibling}function J0(e,t,n){if(an&&typeof an.onCommitFiberUnmount=="function")try{an.onCommitFiberUnmount(Wl,n)}catch{}switch(n.tag){case 5:Be||gi(n,t);case 6:var r=Fe,i=Ut;Fe=null,In(e,t,n),Fe=r,Ut=i,Fe!==null&&(Ut?(e=Fe,n=n.stateNode,e.nodeType===8?e.parentNode.removeChild(n):e.removeChild(n)):Fe.removeChild(n.stateNode));break;case 18:Fe!==null&&(Ut?(e=Fe,n=n.stateNode,e.nodeType===8?Za(e.parentNode,n):e.nodeType===1&&Za(e,n),Is(e)):Za(Fe,n.stateNode));break;case 4:r=Fe,i=Ut,Fe=n.stateNode.containerInfo,Ut=!0,In(e,t,n),Fe=r,Ut=i;break;case 0:case 11:case 14:case 15:if(!Be&&(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)&&oc(n,t,o),i=i.next}while(i!==r)}In(e,t,n);break;case 1:if(!Be&&(gi(n,t),r=n.stateNode,typeof r.componentWillUnmount=="function"))try{r.props=n.memoizedProps,r.state=n.memoizedState,r.componentWillUnmount()}catch(l){ve(n,t,l)}In(e,t,n);break;case 21:In(e,t,n);break;case 22:n.mode&1?(Be=(r=Be)||n.memoizedState!==null,In(e,t,n),Be=r):In(e,t,n);break;default:In(e,t,n)}}function Ch(e){var t=e.updateQueue;if(t!==null){e.updateQueue=null;var n=e.stateNode;n===null&&(n=e.stateNode=new mw),t.forEach(function(r){var i=kw.bind(null,e,r);n.has(r)||(n.add(r),r.then(i,i))})}}function Dt(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:Fe=l.stateNode,Ut=!1;break e;case 3:Fe=l.stateNode.containerInfo,Ut=!0;break e;case 4:Fe=l.stateNode.containerInfo,Ut=!0;break e}l=l.return}if(Fe===null)throw Error(O(160));J0(s,o,i),Fe=null,Ut=!1;var a=i.alternate;a!==null&&(a.return=null),i.return=null}catch(c){ve(i,t,c)}}if(t.subtreeFlags&12854)for(t=t.child;t!==null;)eg(t,e),t=t.sibling}function eg(e,t){var n=e.alternate,r=e.flags;switch(e.tag){case 0:case 11:case 14:case 15:if(Dt(t,e),Zt(e),r&4){try{Cs(3,e,e.return),Jl(3,e)}catch(w){ve(e,e.return,w)}try{Cs(5,e,e.return)}catch(w){ve(e,e.return,w)}}break;case 1:Dt(t,e),Zt(e),r&512&&n!==null&&gi(n,n.return);break;case 5:if(Dt(t,e),Zt(e),r&512&&n!==null&&gi(n,n.return),e.flags&32){var i=e.stateNode;try{As(i,"")}catch(w){ve(e,e.return,w)}}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&&bm(i,s),ju(l,o);var c=ju(l,s);for(o=0;o<a.length;o+=2){var f=a[o],u=a[o+1];f==="style"?Tm(i,u):f==="dangerouslySetInnerHTML"?km(i,u):f==="children"?As(i,u):tf(i,f,u,c)}switch(l){case"input":Ou(i,s);break;case"textarea":Em(i,s);break;case"select":var d=i._wrapperState.wasMultiple;i._wrapperState.wasMultiple=!!s.multiple;var h=s.value;h!=null?wi(i,!!s.multiple,h,!1):d!==!!s.multiple&&(s.defaultValue!=null?wi(i,!!s.multiple,s.defaultValue,!0):wi(i,!!s.multiple,s.multiple?[]:"",!1))}i[Bs]=s}catch(w){ve(e,e.return,w)}}break;case 6:if(Dt(t,e),Zt(e),r&4){if(e.stateNode===null)throw Error(O(162));i=e.stateNode,s=e.memoizedProps;try{i.nodeValue=s}catch(w){ve(e,e.return,w)}}break;case 3:if(Dt(t,e),Zt(e),r&4&&n!==null&&n.memoizedState.isDehydrated)try{Is(t.containerInfo)}catch(w){ve(e,e.return,w)}break;case 4:Dt(t,e),Zt(e);break;case 13:Dt(t,e),Zt(e),i=e.child,i.flags&8192&&(s=i.memoizedState!==null,i.stateNode.isHidden=s,!s||i.alternate!==null&&i.alternate.memoizedState!==null||($f=xe())),r&4&&Ch(e);break;case 22:if(f=n!==null&&n.memoizedState!==null,e.mode&1?(Be=(c=Be)||f,Dt(t,e),Be=c):Dt(t,e),Zt(e),r&8192){if(c=e.memoizedState!==null,(e.stateNode.isHidden=c)&&!f&&e.mode&1)for(F=e,f=e.child;f!==null;){for(u=F=f;F!==null;){switch(d=F,h=d.child,d.tag){case 0:case 11:case 14:case 15:Cs(4,d,d.return);break;case 1:gi(d,d.return);var v=d.stateNode;if(typeof v.componentWillUnmount=="function"){r=d,n=d.return;try{t=r,v.props=t.memoizedProps,v.state=t.memoizedState,v.componentWillUnmount()}catch(w){ve(r,n,w)}}break;case 5:gi(d,d.return);break;case 22:if(d.memoizedState!==null){Oh(u);continue}}h!==null?(h.return=d,F=h):Oh(u)}f=f.sibling}e:for(f=null,u=e;;){if(u.tag===5){if(f===null){f=u;try{i=u.stateNode,c?(s=i.style,typeof s.setProperty=="function"?s.setProperty("display","none","important"):s.display="none"):(l=u.stateNode,a=u.memoizedProps.style,o=a!=null&&a.hasOwnProperty("display")?a.display:null,l.style.display=Cm("display",o))}catch(w){ve(e,e.return,w)}}}else if(u.tag===6){if(f===null)try{u.stateNode.nodeValue=c?"":u.memoizedProps}catch(w){ve(e,e.return,w)}}else if((u.tag!==22&&u.tag!==23||u.memoizedState===null||u===e)&&u.child!==null){u.child.return=u,u=u.child;continue}if(u===e)break e;for(;u.sibling===null;){if(u.return===null||u.return===e)break e;f===u&&(f=null),u=u.return}f===u&&(f=null),u.sibling.return=u.return,u=u.sibling}}break;case 19:Dt(t,e),Zt(e),r&4&&Ch(e);break;case 21:break;default:Dt(t,e),Zt(e)}}function Zt(e){var t=e.flags;if(t&2){try{e:{for(var n=e.return;n!==null;){if(Z0(n)){var r=n;break e}n=n.return}throw Error(O(160))}switch(r.tag){case 5:var i=r.stateNode;r.flags&32&&(As(i,""),r.flags&=-33);var s=kh(e);uc(e,s,i);break;case 3:case 4:var o=r.stateNode.containerInfo,l=kh(e);ac(e,l,o);break;default:throw Error(O(161))}}catch(a){ve(e,e.return,a)}e.flags&=-3}t&4096&&(e.flags&=-4097)}function yw(e,t,n){F=e,tg(e)}function tg(e,t,n){for(var r=(e.mode&1)!==0;F!==null;){var i=F,s=i.child;if(i.tag===22&&r){var o=i.memoizedState!==null||Io;if(!o){var l=i.alternate,a=l!==null&&l.memoizedState!==null||Be;l=Io;var c=Be;if(Io=o,(Be=a)&&!c)for(F=i;F!==null;)o=F,a=o.child,o.tag===22&&o.memoizedState!==null?Rh(i):a!==null?(a.return=o,F=a):Rh(i);for(;s!==null;)F=s,tg(s),s=s.sibling;F=i,Io=l,Be=c}Th(e)}else i.subtreeFlags&8772&&s!==null?(s.return=i,F=s):Th(e)}}function Th(e){for(;F!==null;){var t=F;if(t.flags&8772){var n=t.alternate;try{if(t.flags&8772)switch(t.tag){case 0:case 11:case 15:Be||Jl(5,t);break;case 1:var r=t.stateNode;if(t.flags&4&&!Be)if(n===null)r.componentDidMount();else{var i=t.elementType===t.type?n.memoizedProps:zt(t.type,n.memoizedProps);r.componentDidUpdate(i,n.memoizedState,r.__reactInternalSnapshotBeforeUpdate)}var s=t.updateQueue;s!==null&&fh(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}fh(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 c=t.alternate;if(c!==null){var f=c.memoizedState;if(f!==null){var u=f.dehydrated;u!==null&&Is(u)}}}break;case 19:case 17:case 21:case 22:case 23:case 25:break;default:throw Error(O(163))}Be||t.flags&512&&lc(t)}catch(d){ve(t,t.return,d)}}if(t===e){F=null;break}if(n=t.sibling,n!==null){n.return=t.return,F=n;break}F=t.return}}function Oh(e){for(;F!==null;){var t=F;if(t===e){F=null;break}var n=t.sibling;if(n!==null){n.return=t.return,F=n;break}F=t.return}}function Rh(e){for(;F!==null;){var t=F;try{switch(t.tag){case 0:case 11:case 15:var n=t.return;try{Jl(4,t)}catch(a){ve(t,n,a)}break;case 1:var r=t.stateNode;if(typeof r.componentDidMount=="function"){var i=t.return;try{r.componentDidMount()}catch(a){ve(t,i,a)}}var s=t.return;try{lc(t)}catch(a){ve(t,s,a)}break;case 5:var o=t.return;try{lc(t)}catch(a){ve(t,o,a)}}}catch(a){ve(t,t.return,a)}if(t===e){F=null;break}var l=t.sibling;if(l!==null){l.return=t.return,F=l;break}F=t.return}}var vw=Math.ceil,Pl=Nn.ReactCurrentDispatcher,jf=Nn.ReactCurrentOwner,jt=Nn.ReactCurrentBatchConfig,J=0,Ne=null,Se=null,$e=0,mt=0,yi=pr(0),ke=0,qs=null,Vr=0,ea=0,Ff=0,Ts=null,it=null,$f=0,Wi=1/0,vn=null,Al=!1,cc=null,sr=null,Lo=!1,Zn=null,jl=0,Os=0,fc=null,tl=-1,nl=0;function Ge(){return J&6?xe():tl!==-1?tl:tl=xe()}function or(e){return e.mode&1?J&2&&$e!==0?$e&-$e:tw.transition!==null?(nl===0&&(nl=Mm()),nl):(e=re,e!==0||(e=window.event,e=e===void 0?16:Qm(e.type)),e):1}function Yt(e,t,n,r){if(50<Os)throw Os=0,fc=null,Error(O(185));so(e,n,r),(!(J&2)||e!==Ne)&&(e===Ne&&(!(J&2)&&(ea|=n),ke===4&&Bn(e,$e)),ut(e,r),n===1&&J===0&&!(t.mode&1)&&(Wi=xe()+500,Gl&&mr()))}function ut(e,t){var n=e.callbackNode;t1(e,t);var r=gl(e,e===Ne?$e:0);if(r===0)n!==null&&Dd(n),e.callbackNode=null,e.callbackPriority=0;else if(t=r&-r,e.callbackPriority!==t){if(n!=null&&Dd(n),t===1)e.tag===0?ew(Nh.bind(null,e)):f0(Nh.bind(null,e)),G1(function(){!(J&6)&&mr()}),n=null;else{switch(zm(r)){case 1:n=lf;break;case 4:n=Lm;break;case 16:n=ml;break;case 536870912:n=Dm;break;default:n=ml}n=ug(n,ng.bind(null,e))}e.callbackPriority=t,e.callbackNode=n}}function ng(e,t){if(tl=-1,nl=0,J&6)throw Error(O(327));var n=e.callbackNode;if(_i()&&e.callbackNode!==n)return null;var r=gl(e,e===Ne?$e:0);if(r===0)return null;if(r&30||r&e.expiredLanes||t)t=Fl(e,r);else{t=r;var i=J;J|=2;var s=ig();(Ne!==e||$e!==t)&&(vn=null,Wi=xe()+500,$r(e,t));do try{Sw();break}catch(l){rg(e,l)}while(!0);xf(),Pl.current=s,J=i,Se!==null?t=0:(Ne=null,$e=0,t=ke)}if(t!==0){if(t===2&&(i=Du(e),i!==0&&(r=i,t=dc(e,i))),t===1)throw n=qs,$r(e,0),Bn(e,r),ut(e,xe()),n;if(t===6)Bn(e,r);else{if(i=e.current.alternate,!(r&30)&&!ww(i)&&(t=Fl(e,r),t===2&&(s=Du(e),s!==0&&(r=s,t=dc(e,s))),t===1))throw n=qs,$r(e,0),Bn(e,r),ut(e,xe()),n;switch(e.finishedWork=i,e.finishedLanes=r,t){case 0:case 1:throw Error(O(345));case 2:br(e,it,vn);break;case 3:if(Bn(e,r),(r&130023424)===r&&(t=$f+500-xe(),10<t)){if(gl(e,0)!==0)break;if(i=e.suspendedLanes,(i&r)!==r){Ge(),e.pingedLanes|=e.suspendedLanes&i;break}e.timeoutHandle=Qu(br.bind(null,e,it,vn),t);break}br(e,it,vn);break;case 4:if(Bn(e,r),(r&4194240)===r)break;for(t=e.eventTimes,i=-1;0<r;){var o=31-Kt(r);s=1<<o,o=t[o],o>i&&(i=o),r&=~s}if(r=i,r=xe()-r,r=(120>r?120:480>r?480:1080>r?1080:1920>r?1920:3e3>r?3e3:4320>r?4320:1960*vw(r/1960))-r,10<r){e.timeoutHandle=Qu(br.bind(null,e,it,vn),r);break}br(e,it,vn);break;case 5:br(e,it,vn);break;default:throw Error(O(329))}}}return ut(e,xe()),e.callbackNode===n?ng.bind(null,e):null}function dc(e,t){var n=Ts;return e.current.memoizedState.isDehydrated&&($r(e,t).flags|=256),e=Fl(e,t),e!==2&&(t=it,it=n,t!==null&&hc(t)),e}function hc(e){it===null?it=e:it.push.apply(it,e)}function ww(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(!Gt(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 Bn(e,t){for(t&=~Ff,t&=~ea,e.suspendedLanes|=t,e.pingedLanes&=~t,e=e.expirationTimes;0<t;){var n=31-Kt(t),r=1<<n;e[n]=-1,t&=~r}}function Nh(e){if(J&6)throw Error(O(327));_i();var t=gl(e,0);if(!(t&1))return ut(e,xe()),null;var n=Fl(e,t);if(e.tag!==0&&n===2){var r=Du(e);r!==0&&(t=r,n=dc(e,r))}if(n===1)throw n=qs,$r(e,0),Bn(e,t),ut(e,xe()),n;if(n===6)throw Error(O(345));return e.finishedWork=e.current.alternate,e.finishedLanes=t,br(e,it,vn),ut(e,xe()),null}function If(e,t){var n=J;J|=1;try{return e(t)}finally{J=n,J===0&&(Wi=xe()+500,Gl&&mr())}}function Hr(e){Zn!==null&&Zn.tag===0&&!(J&6)&&_i();var t=J;J|=1;var n=jt.transition,r=re;try{if(jt.transition=null,re=1,e)return e()}finally{re=r,jt.transition=n,J=t,!(J&6)&&mr()}}function Lf(){mt=yi.current,fe(yi)}function $r(e,t){e.finishedWork=null,e.finishedLanes=0;var n=e.timeoutHandle;if(n!==-1&&(e.timeoutHandle=-1,Y1(n)),Se!==null)for(n=Se.return;n!==null;){var r=n;switch(yf(r),r.tag){case 1:r=r.type.childContextTypes,r!=null&&Sl();break;case 3:Vi(),fe(lt),fe(Ue),Cf();break;case 5:kf(r);break;case 4:Vi();break;case 13:fe(pe);break;case 19:fe(pe);break;case 10:Sf(r.type._context);break;case 22:case 23:Lf()}n=n.return}if(Ne=e,Se=e=lr(e.current,null),$e=mt=t,ke=0,qs=null,Ff=ea=Vr=0,it=Ts=null,kr!==null){for(t=0;t<kr.length;t++)if(n=kr[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}kr=null}return e}function rg(e,t){do{var n=Se;try{if(xf(),Zo.current=Nl,Rl){for(var r=me.memoizedState;r!==null;){var i=r.queue;i!==null&&(i.pending=null),r=r.next}Rl=!1}if(Ur=0,Re=Ee=me=null,ks=!1,Hs=0,jf.current=null,n===null||n.return===null){ke=1,qs=t,Se=null;break}e:{var s=e,o=n.return,l=n,a=t;if(t=$e,l.flags|=32768,a!==null&&typeof a=="object"&&typeof a.then=="function"){var c=a,f=l,u=f.tag;if(!(f.mode&1)&&(u===0||u===11||u===15)){var d=f.alternate;d?(f.updateQueue=d.updateQueue,f.memoizedState=d.memoizedState,f.lanes=d.lanes):(f.updateQueue=null,f.memoizedState=null)}var h=yh(o);if(h!==null){h.flags&=-257,vh(h,o,l,s,t),h.mode&1&&gh(s,c,t),t=h,a=c;var v=t.updateQueue;if(v===null){var w=new Set;w.add(a),t.updateQueue=w}else v.add(a);break e}else{if(!(t&1)){gh(s,c,t),Df();break e}a=Error(O(426))}}else if(he&&l.mode&1){var S=yh(o);if(S!==null){!(S.flags&65536)&&(S.flags|=256),vh(S,o,l,s,t),vf(Hi(a,l));break e}}s=a=Hi(a,l),ke!==4&&(ke=2),Ts===null?Ts=[s]:Ts.push(s),s=o;do{switch(s.tag){case 3:s.flags|=65536,t&=-t,s.lanes|=t;var m=z0(s,a,t);ch(s,m);break e;case 1:l=a;var p=s.type,y=s.stateNode;if(!(s.flags&128)&&(typeof p.getDerivedStateFromError=="function"||y!==null&&typeof y.componentDidCatch=="function"&&(sr===null||!sr.has(y)))){s.flags|=65536,t&=-t,s.lanes|=t;var x=B0(s,l,t);ch(s,x);break e}}s=s.return}while(s!==null)}og(n)}catch(C){t=C,Se===n&&n!==null&&(Se=n=n.return);continue}break}while(!0)}function ig(){var e=Pl.current;return Pl.current=Nl,e===null?Nl:e}function Df(){(ke===0||ke===3||ke===2)&&(ke=4),Ne===null||!(Vr&268435455)&&!(ea&268435455)||Bn(Ne,$e)}function Fl(e,t){var n=J;J|=2;var r=ig();(Ne!==e||$e!==t)&&(vn=null,$r(e,t));do try{xw();break}catch(i){rg(e,i)}while(!0);if(xf(),J=n,Pl.current=r,Se!==null)throw Error(O(261));return Ne=null,$e=0,ke}function xw(){for(;Se!==null;)sg(Se)}function Sw(){for(;Se!==null&&!Qv();)sg(Se)}function sg(e){var t=ag(e.alternate,e,mt);e.memoizedProps=e.pendingProps,t===null?og(e):Se=t,jf.current=null}function og(e){var t=e;do{var n=t.alternate;if(e=t.return,t.flags&32768){if(n=pw(n,t),n!==null){n.flags&=32767,Se=n;return}if(e!==null)e.flags|=32768,e.subtreeFlags=0,e.deletions=null;else{ke=6,Se=null;return}}else if(n=hw(n,t,mt),n!==null){Se=n;return}if(t=t.sibling,t!==null){Se=t;return}Se=t=e}while(t!==null);ke===0&&(ke=5)}function br(e,t,n){var r=re,i=jt.transition;try{jt.transition=null,re=1,bw(e,t,n,r)}finally{jt.transition=i,re=r}return null}function bw(e,t,n,r){do _i();while(Zn!==null);if(J&6)throw Error(O(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(O(177));e.callbackNode=null,e.callbackPriority=0;var s=n.lanes|n.childLanes;if(n1(e,s),e===Ne&&(Se=Ne=null,$e=0),!(n.subtreeFlags&2064)&&!(n.flags&2064)||Lo||(Lo=!0,ug(ml,function(){return _i(),null})),s=(n.flags&15990)!==0,n.subtreeFlags&15990||s){s=jt.transition,jt.transition=null;var o=re;re=1;var l=J;J|=4,jf.current=null,gw(e,n),eg(n,e),U1(Hu),yl=!!Vu,Hu=Vu=null,e.current=n,yw(n),qv(),J=l,re=o,jt.transition=s}else e.current=n;if(Lo&&(Lo=!1,Zn=e,jl=i),s=e.pendingLanes,s===0&&(sr=null),Gv(n.stateNode),ut(e,xe()),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(Al)throw Al=!1,e=cc,cc=null,e;return jl&1&&e.tag!==0&&_i(),s=e.pendingLanes,s&1?e===fc?Os++:(Os=0,fc=e):Os=0,mr(),null}function _i(){if(Zn!==null){var e=zm(jl),t=jt.transition,n=re;try{if(jt.transition=null,re=16>e?16:e,Zn===null)var r=!1;else{if(e=Zn,Zn=null,jl=0,J&6)throw Error(O(331));var i=J;for(J|=4,F=e.current;F!==null;){var s=F,o=s.child;if(F.flags&16){var l=s.deletions;if(l!==null){for(var a=0;a<l.length;a++){var c=l[a];for(F=c;F!==null;){var f=F;switch(f.tag){case 0:case 11:case 15:Cs(8,f,s)}var u=f.child;if(u!==null)u.return=f,F=u;else for(;F!==null;){f=F;var d=f.sibling,h=f.return;if(X0(f),f===c){F=null;break}if(d!==null){d.return=h,F=d;break}F=h}}}var v=s.alternate;if(v!==null){var w=v.child;if(w!==null){v.child=null;do{var S=w.sibling;w.sibling=null,w=S}while(w!==null)}}F=s}}if(s.subtreeFlags&2064&&o!==null)o.return=s,F=o;else e:for(;F!==null;){if(s=F,s.flags&2048)switch(s.tag){case 0:case 11:case 15:Cs(9,s,s.return)}var m=s.sibling;if(m!==null){m.return=s.return,F=m;break e}F=s.return}}var p=e.current;for(F=p;F!==null;){o=F;var y=o.child;if(o.subtreeFlags&2064&&y!==null)y.return=o,F=y;else e:for(o=p;F!==null;){if(l=F,l.flags&2048)try{switch(l.tag){case 0:case 11:case 15:Jl(9,l)}}catch(C){ve(l,l.return,C)}if(l===o){F=null;break e}var x=l.sibling;if(x!==null){x.return=l.return,F=x;break e}F=l.return}}if(J=i,mr(),an&&typeof an.onPostCommitFiberRoot=="function")try{an.onPostCommitFiberRoot(Wl,e)}catch{}r=!0}return r}finally{re=n,jt.transition=t}}return!1}function Ph(e,t,n){t=Hi(n,t),t=z0(e,t,1),e=ir(e,t,1),t=Ge(),e!==null&&(so(e,1,t),ut(e,t))}function ve(e,t,n){if(e.tag===3)Ph(e,e,n);else for(;t!==null;){if(t.tag===3){Ph(t,e,n);break}else if(t.tag===1){var r=t.stateNode;if(typeof t.type.getDerivedStateFromError=="function"||typeof r.componentDidCatch=="function"&&(sr===null||!sr.has(r))){e=Hi(n,e),e=B0(t,e,1),t=ir(t,e,1),e=Ge(),t!==null&&(so(t,1,e),ut(t,e));break}}t=t.return}}function Ew(e,t,n){var r=e.pingCache;r!==null&&r.delete(t),t=Ge(),e.pingedLanes|=e.suspendedLanes&n,Ne===e&&($e&n)===n&&(ke===4||ke===3&&($e&130023424)===$e&&500>xe()-$f?$r(e,0):Ff|=n),ut(e,t)}function lg(e,t){t===0&&(e.mode&1?(t=To,To<<=1,!(To&130023424)&&(To=4194304)):t=1);var n=Ge();e=On(e,t),e!==null&&(so(e,t,n),ut(e,n))}function _w(e){var t=e.memoizedState,n=0;t!==null&&(n=t.retryLane),lg(e,n)}function kw(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(O(314))}r!==null&&r.delete(t),lg(e,n)}var ag;ag=function(e,t,n){if(e!==null)if(e.memoizedProps!==t.pendingProps||lt.current)ot=!0;else{if(!(e.lanes&n)&&!(t.flags&128))return ot=!1,dw(e,t,n);ot=!!(e.flags&131072)}else ot=!1,he&&t.flags&1048576&&d0(t,_l,t.index);switch(t.lanes=0,t.tag){case 2:var r=t.type;el(e,t),e=t.pendingProps;var i=zi(t,Ue.current);Ei(t,n),i=Of(null,t,r,e,i,n);var s=Rf();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,at(r)?(s=!0,bl(t)):s=!1,t.memoizedState=i.state!==null&&i.state!==void 0?i.state:null,Ef(t),i.updater=Zl,t.stateNode=i,i._reactInternals=t,Ju(t,r,e,n),t=nc(null,t,r,!0,s,n)):(t.tag=0,he&&s&&gf(t),Ye(null,t,i,n),t=t.child),t;case 16:r=t.elementType;e:{switch(el(e,t),e=t.pendingProps,i=r._init,r=i(r._payload),t.type=r,i=t.tag=Tw(r),e=zt(r,e),i){case 0:t=tc(null,t,r,e,n);break e;case 1:t=Sh(null,t,r,e,n);break e;case 11:t=wh(null,t,r,e,n);break e;case 14:t=xh(null,t,r,zt(r.type,e),n);break e}throw Error(O(306,r,""))}return t;case 0:return r=t.type,i=t.pendingProps,i=t.elementType===r?i:zt(r,i),tc(e,t,r,i,n);case 1:return r=t.type,i=t.pendingProps,i=t.elementType===r?i:zt(r,i),Sh(e,t,r,i,n);case 3:e:{if(W0(t),e===null)throw Error(O(387));r=t.pendingProps,s=t.memoizedState,i=s.element,v0(e,t),Tl(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=Hi(Error(O(423)),t),t=bh(e,t,r,n,i);break e}else if(r!==i){i=Hi(Error(O(424)),t),t=bh(e,t,r,n,i);break e}else for(gt=rr(t.stateNode.containerInfo.firstChild),wt=t,he=!0,Ht=null,n=g0(t,null,r,n),t.child=n;n;)n.flags=n.flags&-3|4096,n=n.sibling;else{if(Bi(),r===i){t=Rn(e,t,n);break e}Ye(e,t,r,n)}t=t.child}return t;case 5:return w0(t),e===null&&Gu(t),r=t.type,i=t.pendingProps,s=e!==null?e.memoizedProps:null,o=i.children,Wu(r,i)?o=null:s!==null&&Wu(r,s)&&(t.flags|=32),H0(e,t),Ye(e,t,o,n),t.child;case 6:return e===null&&Gu(t),null;case 13:return Q0(e,t,n);case 4:return _f(t,t.stateNode.containerInfo),r=t.pendingProps,e===null?t.child=Ui(t,null,r,n):Ye(e,t,r,n),t.child;case 11:return r=t.type,i=t.pendingProps,i=t.elementType===r?i:zt(r,i),wh(e,t,r,i,n);case 7:return Ye(e,t,t.pendingProps,n),t.child;case 8:return Ye(e,t,t.pendingProps.children,n),t.child;case 12:return Ye(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,ae(kl,r._currentValue),r._currentValue=o,s!==null)if(Gt(s.value,o)){if(s.children===i.children&&!lt.current){t=Rn(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=_n(-1,n&-n),a.tag=2;var c=s.updateQueue;if(c!==null){c=c.shared;var f=c.pending;f===null?a.next=a:(a.next=f.next,f.next=a),c.pending=a}}s.lanes|=n,a=s.alternate,a!==null&&(a.lanes|=n),Xu(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(O(341));o.lanes|=n,l=o.alternate,l!==null&&(l.lanes|=n),Xu(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}Ye(e,t,i.children,n),t=t.child}return t;case 9:return i=t.type,r=t.pendingProps.children,Ei(t,n),i=Ft(i),r=r(i),t.flags|=1,Ye(e,t,r,n),t.child;case 14:return r=t.type,i=zt(r,t.pendingProps),i=zt(r.type,i),xh(e,t,r,i,n);case 15:return U0(e,t,t.type,t.pendingProps,n);case 17:return r=t.type,i=t.pendingProps,i=t.elementType===r?i:zt(r,i),el(e,t),t.tag=1,at(r)?(e=!0,bl(t)):e=!1,Ei(t,n),M0(t,r,i),Ju(t,r,i,n),nc(null,t,r,!0,e,n);case 19:return q0(e,t,n);case 22:return V0(e,t,n)}throw Error(O(156,t.tag))};function ug(e,t){return Im(e,t)}function Cw(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 At(e,t,n,r){return new Cw(e,t,n,r)}function Mf(e){return e=e.prototype,!(!e||!e.isReactComponent)}function Tw(e){if(typeof e=="function")return Mf(e)?1:0;if(e!=null){if(e=e.$$typeof,e===rf)return 11;if(e===sf)return 14}return 2}function lr(e,t){var n=e.alternate;return n===null?(n=At(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 rl(e,t,n,r,i,s){var o=2;if(r=e,typeof e=="function")Mf(e)&&(o=1);else if(typeof e=="string")o=5;else e:switch(e){case li:return Ir(n.children,i,s,t);case nf:o=8,i|=8;break;case Eu:return e=At(12,n,t,i|2),e.elementType=Eu,e.lanes=s,e;case _u:return e=At(13,n,t,i),e.elementType=_u,e.lanes=s,e;case ku:return e=At(19,n,t,i),e.elementType=ku,e.lanes=s,e;case wm:return ta(n,i,s,t);default:if(typeof e=="object"&&e!==null)switch(e.$$typeof){case ym:o=10;break e;case vm:o=9;break e;case rf:o=11;break e;case sf:o=14;break e;case Dn:o=16,r=null;break e}throw Error(O(130,e==null?e:typeof e,""))}return t=At(o,n,t,i),t.elementType=e,t.type=r,t.lanes=s,t}function Ir(e,t,n,r){return e=At(7,e,r,t),e.lanes=n,e}function ta(e,t,n,r){return e=At(22,e,r,t),e.elementType=wm,e.lanes=n,e.stateNode={isHidden:!1},e}function ou(e,t,n){return e=At(6,e,null,t),e.lanes=n,e}function lu(e,t,n){return t=At(4,e.children!==null?e.children:[],e.key,t),t.lanes=n,t.stateNode={containerInfo:e.containerInfo,pendingChildren:null,implementation:e.implementation},t}function Ow(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=Ba(0),this.expirationTimes=Ba(-1),this.entangledLanes=this.finishedLanes=this.mutableReadLanes=this.expiredLanes=this.pingedLanes=this.suspendedLanes=this.pendingLanes=0,this.entanglements=Ba(0),this.identifierPrefix=r,this.onRecoverableError=i,this.mutableSourceEagerHydrationData=null}function zf(e,t,n,r,i,s,o,l,a){return e=new Ow(e,t,n,l,a),t===1?(t=1,s===!0&&(t|=8)):t=0,s=At(3,null,null,t),e.current=s,s.stateNode=e,s.memoizedState={element:r,isDehydrated:n,cache:null,transitions:null,pendingSuspenseBoundaries:null},Ef(s),e}function Rw(e,t,n){var r=3<arguments.length&&arguments[3]!==void 0?arguments[3]:null;return{$$typeof:oi,key:r==null?null:""+r,children:e,containerInfo:t,implementation:n}}function cg(e){if(!e)return fr;e=e._reactInternals;e:{if(Yr(e)!==e||e.tag!==1)throw Error(O(170));var t=e;do{switch(t.tag){case 3:t=t.stateNode.context;break e;case 1:if(at(t.type)){t=t.stateNode.__reactInternalMemoizedMergedChildContext;break e}}t=t.return}while(t!==null);throw Error(O(171))}if(e.tag===1){var n=e.type;if(at(n))return c0(e,n,t)}return t}function fg(e,t,n,r,i,s,o,l,a){return e=zf(n,r,!0,e,i,s,o,l,a),e.context=cg(null),n=e.current,r=Ge(),i=or(n),s=_n(r,i),s.callback=t??null,ir(n,s,i),e.current.lanes=i,so(e,i,r),ut(e,r),e}function na(e,t,n,r){var i=t.current,s=Ge(),o=or(i);return n=cg(n),t.context===null?t.context=n:t.pendingContext=n,t=_n(s,o),t.payload={element:e},r=r===void 0?null:r,r!==null&&(t.callback=r),e=ir(i,t,o),e!==null&&(Yt(e,i,o,s),Xo(e,i,o)),o}function $l(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 Ah(e,t){if(e=e.memoizedState,e!==null&&e.dehydrated!==null){var n=e.retryLane;e.retryLane=n!==0&&n<t?n:t}}function Bf(e,t){Ah(e,t),(e=e.alternate)&&Ah(e,t)}function Nw(){return null}var dg=typeof reportError=="function"?reportError:function(e){console.error(e)};function Uf(e){this._internalRoot=e}ra.prototype.render=Uf.prototype.render=function(e){var t=this._internalRoot;if(t===null)throw Error(O(409));na(e,t,null,null)};ra.prototype.unmount=Uf.prototype.unmount=function(){var e=this._internalRoot;if(e!==null){this._internalRoot=null;var t=e.containerInfo;Hr(function(){na(null,e,null,null)}),t[Tn]=null}};function ra(e){this._internalRoot=e}ra.prototype.unstable_scheduleHydration=function(e){if(e){var t=Vm();e={blockedOn:null,target:e,priority:t};for(var n=0;n<zn.length&&t!==0&&t<zn[n].priority;n++);zn.splice(n,0,e),n===0&&Wm(e)}};function Vf(e){return!(!e||e.nodeType!==1&&e.nodeType!==9&&e.nodeType!==11)}function ia(e){return!(!e||e.nodeType!==1&&e.nodeType!==9&&e.nodeType!==11&&(e.nodeType!==8||e.nodeValue!==" react-mount-point-unstable "))}function jh(){}function Pw(e,t,n,r,i){if(i){if(typeof r=="function"){var s=r;r=function(){var c=$l(o);s.call(c)}}var o=fg(t,r,e,0,null,!1,!1,"",jh);return e._reactRootContainer=o,e[Tn]=o.current,Ms(e.nodeType===8?e.parentNode:e),Hr(),o}for(;i=e.lastChild;)e.removeChild(i);if(typeof r=="function"){var l=r;r=function(){var c=$l(a);l.call(c)}}var a=zf(e,0,!1,null,null,!1,!1,"",jh);return e._reactRootContainer=a,e[Tn]=a.current,Ms(e.nodeType===8?e.parentNode:e),Hr(function(){na(t,a,n,r)}),a}function sa(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=$l(o);l.call(a)}}na(t,o,e,i)}else o=Pw(n,t,e,i,r);return $l(o)}Bm=function(e){switch(e.tag){case 3:var t=e.stateNode;if(t.current.memoizedState.isDehydrated){var n=gs(t.pendingLanes);n!==0&&(af(t,n|1),ut(t,xe()),!(J&6)&&(Wi=xe()+500,mr()))}break;case 13:Hr(function(){var r=On(e,1);if(r!==null){var i=Ge();Yt(r,e,1,i)}}),Bf(e,1)}};uf=function(e){if(e.tag===13){var t=On(e,134217728);if(t!==null){var n=Ge();Yt(t,e,134217728,n)}Bf(e,134217728)}};Um=function(e){if(e.tag===13){var t=or(e),n=On(e,t);if(n!==null){var r=Ge();Yt(n,e,t,r)}Bf(e,t)}};Vm=function(){return re};Hm=function(e,t){var n=re;try{return re=e,t()}finally{re=n}};$u=function(e,t,n){switch(t){case"input":if(Ou(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=Yl(r);if(!i)throw Error(O(90));Sm(r),Ou(r,i)}}}break;case"textarea":Em(e,n);break;case"select":t=n.value,t!=null&&wi(e,!!n.multiple,t,!1)}};Nm=If;Pm=Hr;var Aw={usingClientEntryPoint:!1,Events:[lo,fi,Yl,Om,Rm,If]},fs={findFiberByHostInstance:_r,bundleType:0,version:"18.3.1",rendererPackageName:"react-dom"},jw={bundleType:fs.bundleType,version:fs.version,rendererPackageName:fs.rendererPackageName,rendererConfig:fs.rendererConfig,overrideHookState:null,overrideHookStateDeletePath:null,overrideHookStateRenamePath:null,overrideProps:null,overridePropsDeletePath:null,overridePropsRenamePath:null,setErrorHandler:null,setSuspenseHandler:null,scheduleUpdate:null,currentDispatcherRef:Nn.ReactCurrentDispatcher,findHostInstanceByFiber:function(e){return e=Fm(e),e===null?null:e.stateNode},findFiberByHostInstance:fs.findFiberByHostInstance||Nw,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 Do=__REACT_DEVTOOLS_GLOBAL_HOOK__;if(!Do.isDisabled&&Do.supportsFiber)try{Wl=Do.inject(jw),an=Do}catch{}}St.__SECRET_INTERNALS_DO_NOT_USE_OR_YOU_WILL_BE_FIRED=Aw;St.createPortal=function(e,t){var n=2<arguments.length&&arguments[2]!==void 0?arguments[2]:null;if(!Vf(t))throw Error(O(200));return Rw(e,t,null,n)};St.createRoot=function(e,t){if(!Vf(e))throw Error(O(299));var n=!1,r="",i=dg;return t!=null&&(t.unstable_strictMode===!0&&(n=!0),t.identifierPrefix!==void 0&&(r=t.identifierPrefix),t.onRecoverableError!==void 0&&(i=t.onRecoverableError)),t=zf(e,1,!1,null,null,n,!1,r,i),e[Tn]=t.current,Ms(e.nodeType===8?e.parentNode:e),new Uf(t)};St.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(O(188)):(e=Object.keys(e).join(","),Error(O(268,e)));return e=Fm(t),e=e===null?null:e.stateNode,e};St.flushSync=function(e){return Hr(e)};St.hydrate=function(e,t,n){if(!ia(t))throw Error(O(200));return sa(null,e,t,!0,n)};St.hydrateRoot=function(e,t,n){if(!Vf(e))throw Error(O(405));var r=n!=null&&n.hydratedSources||null,i=!1,s="",o=dg;if(n!=null&&(n.unstable_strictMode===!0&&(i=!0),n.identifierPrefix!==void 0&&(s=n.identifierPrefix),n.onRecoverableError!==void 0&&(o=n.onRecoverableError)),t=fg(t,null,e,1,n??null,i,!1,s,o),e[Tn]=t.current,Ms(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 ra(t)};St.render=function(e,t,n){if(!ia(t))throw Error(O(200));return sa(null,e,t,!1,n)};St.unmountComponentAtNode=function(e){if(!ia(e))throw Error(O(40));return e._reactRootContainer?(Hr(function(){sa(null,null,e,!1,function(){e._reactRootContainer=null,e[Tn]=null})}),!0):!1};St.unstable_batchedUpdates=If;St.unstable_renderSubtreeIntoContainer=function(e,t,n,r){if(!ia(n))throw Error(O(200));if(e==null||e._reactInternals===void 0)throw Error(O(38));return sa(e,t,n,!1,r)};St.version="18.3.1-next-f1338f8080-20240426";function hg(){if(!(typeof __REACT_DEVTOOLS_GLOBAL_HOOK__>"u"||typeof __REACT_DEVTOOLS_GLOBAL_HOOK__.checkDCE!="function"))try{__REACT_DEVTOOLS_GLOBAL_HOOK__.checkDCE(hg)}catch(e){console.error(e)}}hg(),hm.exports=St;var pg=hm.exports;const Fw=Ki(pg);var mg,Fh=pg;mg=Fh.createRoot,Fh.hydrateRoot;const $w="@alfatech/livechat",Iw="v2025.04.07.1",Lw="module",Dw="https://api-live.alfatek.dev",Mw="wss://api-live.alfatek.dev",zw=["dist","README.md"],Bw="dist/widget.js",Uw={dev:"vite",build:"tsc -b && vite build",lint:"biome lint --write",prepare:"husky",format:"biome format --write && yarn lint"},Vw={"@tanstack/react-query":"^5.59.20",classnames:"^2.5.1",dayjs:"^1.11.13",formik:"^2.4.6",react:"^18.3.1","react-dom":"^18.3.1","react-router-dom":"^6.26.2","socket.io-client":"^4.8.1",sonner:"^2.0.1",yup:"^1.4.0",zustand:"^4.5.5"},Hw={"@biomejs/biome":"^1.8.3","@types/node":"^22.5.4","@types/react":"^18.3.3","@types/react-dom":"^18.3.0","@vitejs/plugin-react-swc":"^3.5.0",globals:"^15.9.0",husky:"^9.1.5",tailwindcss:"^3.4.10",typescript:"^5.5.3",vite:"^5.4.1"},gg={name:$w,private:!1,version:Iw,type:Lw,apiURL:Dw,wsURL:Mw,files:zw,main:Bw,scripts:Uw,dependencies:Vw,devDependencies:Hw,"lint-staged":{"./**/*.{js,ts,tsx,json}":["npm run format"]}},Ww=gg.apiURL,Qw=gg.wsURL,qw=e=>[{limit:Number.parseInt(e.headers.get("X-Ratelimit-Limit")||"0"),remaining:Number.parseInt(e.headers.get("X-Ratelimit-Remaining")||"0"),reset:Number.parseInt(e.headers.get("X-Ratelimit-Reset")||"0"),retryAfter:Number.parseInt(e.headers.get("Retry-After")||"0")},429],Kw=(e,t)=>[{message:"message"in t?t.message:"Not Found"},404],Yw={429:qw,404:Kw};async function oa(e,t={}){const n={};!(t.body instanceof FormData)&&t.body&&(n["Content-Type"]="application/json");const r=await fetch(`${Ww}/${e}`,{...t,credentials:"include",headers:{...t.headers,...n}}).catch(s=>(console.log("err::",s),new Response(null,{status:500})));if(!r.ok){let s={};try{return s=await r.json(),[s,r.status]}catch{console.log("response: ",r)}const o=Yw[r.status];return o?o(r,s):[{},r.status]}const i=r.headers.get("Content-Type");return i&&i.includes("application/json")?[await r.json(),r.status]:[await r.text(),r.status]}const yg=e=>[200,201,204].includes(e);var Zi=class{constructor(){this.listeners=new Set,this.subscribe=this.subscribe.bind(this)}subscribe(e){return this.listeners.add(e),this.onSubscribe(),()=>{this.listeners.delete(e),this.onUnsubscribe()}}hasListeners(){return this.listeners.size>0}onSubscribe(){}onUnsubscribe(){}},Wr=typeof window>"u"||"Deno"in globalThis;function Ot(){}function Gw(e,t){return typeof e=="function"?e(t):e}function pc(e){return typeof e=="number"&&e>=0&&e!==1/0}function vg(e,t){return Math.max(e+(t||0)-Date.now(),0)}function ki(e,t){return typeof e=="function"?e(t):e}function Wt(e,t){return typeof e=="function"?e(t):e}function $h(e,t){const{type:n="all",exact:r,fetchStatus:i,predicate:s,queryKey:o,stale:l}=e;if(o){if(r){if(t.queryHash!==Hf(o,t.options))return!1}else if(!Ks(t.queryKey,o))return!1}if(n!=="all"){const a=t.isActive();if(n==="active"&&!a||n==="inactive"&&a)return!1}return!(typeof l=="boolean"&&t.isStale()!==l||i&&i!==t.state.fetchStatus||s&&!s(t))}function Ih(e,t){const{exact:n,status:r,predicate:i,mutationKey:s}=e;if(s){if(!t.options.mutationKey)return!1;if(n){if(Qr(t.options.mutationKey)!==Qr(s))return!1}else if(!Ks(t.options.mutationKey,s))return!1}return!(r&&t.state.status!==r||i&&!i(t))}function Hf(e,t){return((t==null?void 0:t.queryKeyHashFn)||Qr)(e)}function Qr(e){return JSON.stringify(e,(t,n)=>mc(n)?Object.keys(n).sort().reduce((r,i)=>(r[i]=n[i],r),{}):n)}function Ks(e,t){return e===t?!0:typeof e!=typeof t?!1:e&&t&&typeof e=="object"&&typeof t=="object"?!Object.keys(t).some(n=>!Ks(e[n],t[n])):!1}function wg(e,t){if(e===t)return e;const n=Lh(e)&&Lh(t);if(n||mc(e)&&mc(t)){const r=n?e:Object.keys(e),i=r.length,s=n?t:Object.keys(t),o=s.length,l=n?[]:{};let a=0;for(let c=0;c<o;c++){const f=n?c:s[c];(!n&&r.includes(f)||n)&&e[f]===void 0&&t[f]===void 0?(l[f]=void 0,a++):(l[f]=wg(e[f],t[f]),l[f]===e[f]&&e[f]!==void 0&&a++)}return i===o&&a===i?e:l}return t}function Il(e,t){if(!t||Object.keys(e).length!==Object.keys(t).length)return!1;for(const n in e)if(e[n]!==t[n])return!1;return!0}function Lh(e){return Array.isArray(e)&&e.length===Object.keys(e).length}function mc(e){if(!Dh(e))return!1;const t=e.constructor;if(t===void 0)return!0;const n=t.prototype;return!(!Dh(n)||!n.hasOwnProperty("isPrototypeOf")||Object.getPrototypeOf(e)!==Object.prototype)}function Dh(e){return Object.prototype.toString.call(e)==="[object Object]"}function Xw(e){return new Promise(t=>{setTimeout(t,e)})}function gc(e,t,n){return typeof n.structuralSharing=="function"?n.structuralSharing(e,t):n.structuralSharing!==!1?wg(e,t):t}function Zw(e,t,n=0){const r=[...e,t];return n&&r.length>n?r.slice(1):r}function Jw(e,t,n=0){const r=[t,...e];return n&&r.length>n?r.slice(0,-1):r}var Wf=Symbol();function xg(e,t){return!e.queryFn&&(t!=null&&t.initialPromise)?()=>t.initialPromise:!e.queryFn||e.queryFn===Wf?()=>Promise.reject(new Error(`Missing queryFn: '${e.queryHash}'`)):e.queryFn}var Or,Un,Ci,Qp,ex=(Qp=class extends Zi{constructor(){super();U(this,Or);U(this,Un);U(this,Ci);j(this,Ci,t=>{if(!Wr&&window.addEventListener){const n=()=>t();return window.addEventListener("visibilitychange",n,!1),()=>{window.removeEventListener("visibilitychange",n)}}})}onSubscribe(){g(this,Un)||this.setEventListener(g(this,Ci))}onUnsubscribe(){var t;this.hasListeners()||((t=g(this,Un))==null||t.call(this),j(this,Un,void 0))}setEventListener(t){var n;j(this,Ci,t),(n=g(this,Un))==null||n.call(this),j(this,Un,t(r=>{typeof r=="boolean"?this.setFocused(r):this.onFocus()}))}setFocused(t){g(this,Or)!==t&&(j(this,Or,t),this.onFocus())}onFocus(){const t=this.isFocused();this.listeners.forEach(n=>{n(t)})}isFocused(){var t;return typeof g(this,Or)=="boolean"?g(this,Or):((t=globalThis.document)==null?void 0:t.visibilityState)!=="hidden"}},Or=new WeakMap,Un=new WeakMap,Ci=new WeakMap,Qp),Qf=new ex,Ti,Vn,Oi,qp,tx=(qp=class extends Zi{constructor(){super();U(this,Ti,!0);U(this,Vn);U(this,Oi);j(this,Oi,t=>{if(!Wr&&window.addEventListener){const n=()=>t(!0),r=()=>t(!1);return window.addEventListener("online",n,!1),window.addEventListener("offline",r,!1),()=>{window.removeEventListener("online",n),window.removeEventListener("offline",r)}}})}onSubscribe(){g(this,Vn)||this.setEventListener(g(this,Oi))}onUnsubscribe(){var t;this.hasListeners()||((t=g(this,Vn))==null||t.call(this),j(this,Vn,void 0))}setEventListener(t){var n;j(this,Oi,t),(n=g(this,Vn))==null||n.call(this),j(this,Vn,t(this.setOnline.bind(this)))}setOnline(t){g(this,Ti)!==t&&(j(this,Ti,t),this.listeners.forEach(r=>{r(t)}))}isOnline(){return g(this,Ti)}},Ti=new WeakMap,Vn=new WeakMap,Oi=new WeakMap,qp),Ll=new tx;function yc(){let e,t;const n=new Promise((i,s)=>{e=i,t=s});n.status="pending",n.catch(()=>{});function r(i){Object.assign(n,i),delete n.resolve,delete n.reject}return n.resolve=i=>{r({status:"fulfilled",value:i}),e(i)},n.reject=i=>{r({status:"rejected",reason:i}),t(i)},n}function nx(e){return Math.min(1e3*2**e,3e4)}function Sg(e){return(e??"online")==="online"?Ll.isOnline():!0}var bg=class extends Error{constructor(e){super("CancelledError"),this.revert=e==null?void 0:e.revert,this.silent=e==null?void 0:e.silent}};function au(e){return e instanceof bg}function Eg(e){let t=!1,n=0,r=!1,i;const s=yc(),o=w=>{var S;r||(d(new bg(w)),(S=e.abort)==null||S.call(e))},l=()=>{t=!0},a=()=>{t=!1},c=()=>Qf.isFocused()&&(e.networkMode==="always"||Ll.isOnline())&&e.canRun(),f=()=>Sg(e.networkMode)&&e.canRun(),u=w=>{var S;r||(r=!0,(S=e.onSuccess)==null||S.call(e,w),i==null||i(),s.resolve(w))},d=w=>{var S;r||(r=!0,(S=e.onError)==null||S.call(e,w),i==null||i(),s.reject(w))},h=()=>new Promise(w=>{var S;i=m=>{(r||c())&&w(m)},(S=e.onPause)==null||S.call(e)}).then(()=>{var w;i=void 0,r||(w=e.onContinue)==null||w.call(e)}),v=()=>{if(r)return;let w;const S=n===0?e.initialPromise:void 0;try{w=S??e.fn()}catch(m){w=Promise.reject(m)}Promise.resolve(w).then(u).catch(m=>{var T;if(r)return;const p=e.retry??(Wr?0:3),y=e.retryDelay??nx,x=typeof y=="function"?y(n,m):y,C=p===!0||typeof p=="number"&&n<p||typeof p=="function"&&p(n,m);if(t||!C){d(m);return}n++,(T=e.onFail)==null||T.call(e,n,m),Xw(x).then(()=>c()?void 0:h()).then(()=>{t?d(m):v()})})};return{promise:s,cancel:o,continue:()=>(i==null||i(),s),cancelRetry:l,continueRetry:a,canStart:f,start:()=>(f()?v():h().then(v),s)}}function rx(){let e=[],t=0,n=l=>{l()},r=l=>{l()},i=l=>setTimeout(l,0);const s=l=>{t?e.push(l):i(()=>{n(l)})},o=()=>{const l=e;e=[],l.length&&i(()=>{r(()=>{l.forEach(a=>{n(a)})})})};return{batch:l=>{let a;t++;try{a=l()}finally{t--,t||o()}return a},batchCalls:l=>(...a)=>{s(()=>{l(...a)})},schedule:s,setNotifyFunction:l=>{n=l},setBatchNotifyFunction:l=>{r=l},setScheduler:l=>{i=l}}}var _e=rx(),Rr,Kp,_g=(Kp=class{constructor(){U(this,Rr)}destroy(){this.clearGcTimeout()}scheduleGc(){this.clearGcTimeout(),pc(this.gcTime)&&j(this,Rr,setTimeout(()=>{this.optionalRemove()},this.gcTime))}updateGcTime(e){this.gcTime=Math.max(this.gcTime||0,e??(Wr?1/0:5*60*1e3))}clearGcTimeout(){g(this,Rr)&&(clearTimeout(g(this,Rr)),j(this,Rr,void 0))}},Rr=new WeakMap,Kp),Ri,Ni,Tt,ze,eo,Nr,Bt,yn,Yp,ix=(Yp=class extends _g{constructor(t){super();U(this,Bt);U(this,Ri);U(this,Ni);U(this,Tt);U(this,ze);U(this,eo);U(this,Nr);j(this,Nr,!1),j(this,eo,t.defaultOptions),this.setOptions(t.options),this.observers=[],j(this,Tt,t.cache),this.queryKey=t.queryKey,this.queryHash=t.queryHash,j(this,Ri,sx(this.options)),this.state=t.state??g(this,Ri),this.scheduleGc()}get meta(){return this.options.meta}get promise(){var t;return(t=g(this,ze))==null?void 0:t.promise}setOptions(t){this.options={...g(this,eo),...t},this.updateGcTime(this.options.gcTime)}optionalRemove(){!this.observers.length&&this.state.fetchStatus==="idle"&&g(this,Tt).remove(this)}setData(t,n){const r=gc(this.state.data,t,this.options);return q(this,Bt,yn).call(this,{data:r,type:"success",dataUpdatedAt:n==null?void 0:n.updatedAt,manual:n==null?void 0:n.manual}),r}setState(t,n){q(this,Bt,yn).call(this,{type:"setState",state:t,setStateOptions:n})}cancel(t){var r,i;const n=(r=g(this,ze))==null?void 0:r.promise;return(i=g(this,ze))==null||i.cancel(t),n?n.then(Ot).catch(Ot):Promise.resolve()}destroy(){super.destroy(),this.cancel({silent:!0})}reset(){this.destroy(),this.setState(g(this,Ri))}isActive(){return this.observers.some(t=>Wt(t.options.enabled,this)!==!1)}isDisabled(){return this.getObserversCount()>0?!this.isActive():this.options.queryFn===Wf||this.state.dataUpdateCount+this.state.errorUpdateCount===0}isStale(){return this.state.isInvalidated?!0:this.getObserversCount()>0?this.observers.some(t=>t.getCurrentResult().isStale):this.state.data===void 0}isStaleByTime(t=0){return this.state.isInvalidated||this.state.data===void 0||!vg(this.state.dataUpdatedAt,t)}onFocus(){var n;const t=this.observers.find(r=>r.shouldFetchOnWindowFocus());t==null||t.refetch({cancelRefetch:!1}),(n=g(this,ze))==null||n.continue()}onOnline(){var n;const t=this.observers.find(r=>r.shouldFetchOnReconnect());t==null||t.refetch({cancelRefetch:!1}),(n=g(this,ze))==null||n.continue()}addObserver(t){this.observers.includes(t)||(this.observers.push(t),this.clearGcTimeout(),g(this,Tt).notify({type:"observerAdded",query:this,observer:t}))}removeObserver(t){this.observers.includes(t)&&(this.observers=this.observers.filter(n=>n!==t),this.observers.length||(g(this,ze)&&(g(this,Nr)?g(this,ze).cancel({revert:!0}):g(this,ze).cancelRetry()),this.scheduleGc()),g(this,Tt).notify({type:"observerRemoved",query:this,observer:t}))}getObserversCount(){return this.observers.length}invalidate(){this.state.isInvalidated||q(this,Bt,yn).call(this,{type:"invalidate"})}fetch(t,n){var a,c,f;if(this.state.fetchStatus!=="idle"){if(this.state.data!==void 0&&(n!=null&&n.cancelRefetch))this.cancel({silent:!0});else if(g(this,ze))return g(this,ze).continueRetry(),g(this,ze).promise}if(t&&this.setOptions(t),!this.options.queryFn){const u=this.observers.find(d=>d.options.queryFn);u&&this.setOptions(u.options)}const r=new AbortController,i=u=>{Object.defineProperty(u,"signal",{enumerable:!0,get:()=>(j(this,Nr,!0),r.signal)})},s=()=>{const u=xg(this.options,n),d={queryKey:this.queryKey,meta:this.meta};return i(d),j(this,Nr,!1),this.options.persister?this.options.persister(u,d,this):u(d)},o={fetchOptions:n,options:this.options,queryKey:this.queryKey,state:this.state,fetchFn:s};i(o),(a=this.options.behavior)==null||a.onFetch(o,this),j(this,Ni,this.state),(this.state.fetchStatus==="idle"||this.state.fetchMeta!==((c=o.fetchOptions)==null?void 0:c.meta))&&q(this,Bt,yn).call(this,{type:"fetch",meta:(f=o.fetchOptions)==null?void 0:f.meta});const l=u=>{var d,h,v,w;au(u)&&u.silent||q(this,Bt,yn).call(this,{type:"error",error:u}),au(u)||((h=(d=g(this,Tt).config).onError)==null||h.call(d,u,this),(w=(v=g(this,Tt).config).onSettled)==null||w.call(v,this.state.data,u,this)),this.scheduleGc()};return j(this,ze,Eg({initialPromise:n==null?void 0:n.initialPromise,fn:o.fetchFn,abort:r.abort.bind(r),onSuccess:u=>{var d,h,v,w;if(u===void 0){l(new Error(`${this.queryHash} data is undefined`));return}try{this.setData(u)}catch(S){l(S);return}(h=(d=g(this,Tt).config).onSuccess)==null||h.call(d,u,this),(w=(v=g(this,Tt).config).onSettled)==null||w.call(v,u,this.state.error,this),this.scheduleGc()},onError:l,onFail:(u,d)=>{q(this,Bt,yn).call(this,{type:"failed",failureCount:u,error:d})},onPause:()=>{q(this,Bt,yn).call(this,{type:"pause"})},onContinue:()=>{q(this,Bt,yn).call(this,{type:"continue"})},retry:o.options.retry,retryDelay:o.options.retryDelay,networkMode:o.options.networkMode,canRun:()=>!0})),g(this,ze).start()}},Ri=new WeakMap,Ni=new WeakMap,Tt=new WeakMap,ze=new WeakMap,eo=new WeakMap,Nr=new WeakMap,Bt=new WeakSet,yn=function(t){const n=r=>{switch(t.type){case"failed":return{...r,fetchFailureCount:t.failureCount,fetchFailureReason:t.error};case"pause":return{...r,fetchStatus:"paused"};case"continue":return{...r,fetchStatus:"fetching"};case"fetch":return{...r,...kg(r.data,this.options),fetchMeta:t.meta??null};case"success":return{...r,data:t.data,dataUpdateCount:r.dataUpdateCount+1,dataUpdatedAt:t.dataUpdatedAt??Date.now(),error:null,isInvalidated:!1,status:"success",...!t.manual&&{fetchStatus:"idle",fetchFailureCount:0,fetchFailureReason:null}};case"error":const i=t.error;return au(i)&&i.revert&&g(this,Ni)?{...g(this,Ni),fetchStatus:"idle"}:{...r,error:i,errorUpdateCount:r.errorUpdateCount+1,errorUpdatedAt:Date.now(),fetchFailureCount:r.fetchFailureCount+1,fetchFailureReason:i,fetchStatus:"idle",status:"error"};case"invalidate":return{...r,isInvalidated:!0};case"setState":return{...r,...t.state}}};this.state=n(this.state),_e.batch(()=>{this.observers.forEach(r=>{r.onQueryUpdate()}),g(this,Tt).notify({query:this,type:"updated",action:t})})},Yp);function kg(e,t){return{fetchFailureCount:0,fetchFailureReason:null,fetchStatus:Sg(t.networkMode)?"fetching":"paused",...e===void 0&&{error:null,status:"pending"}}}function sx(e){const t=typeof e.initialData=="function"?e.initialData():e.initialData,n=t!==void 0,r=n?typeof e.initialDataUpdatedAt=="function"?e.initialDataUpdatedAt():e.initialDataUpdatedAt:0;return{data:t,dataUpdateCount:0,dataUpdatedAt:n?r??Date.now():0,error:null,errorUpdateCount:0,errorUpdatedAt:0,fetchFailureCount:0,fetchFailureReason:null,fetchMeta:null,isInvalidated:!1,status:n?"success":"pending",fetchStatus:"idle"}}var nn,Gp,ox=(Gp=class extends Zi{constructor(t={}){super();U(this,nn);this.config=t,j(this,nn,new Map)}build(t,n,r){const i=n.queryKey,s=n.queryHash??Hf(i,n);let o=this.get(s);return o||(o=new ix({cache:this,queryKey:i,queryHash:s,options:t.defaultQueryOptions(n),state:r,defaultOptions:t.getQueryDefaults(i)}),this.add(o)),o}add(t){g(this,nn).has(t.queryHash)||(g(this,nn).set(t.queryHash,t),this.notify({type:"added",query:t}))}remove(t){const n=g(this,nn).get(t.queryHash);n&&(t.destroy(),n===t&&g(this,nn).delete(t.queryHash),this.notify({type:"removed",query:t}))}clear(){_e.batch(()=>{this.getAll().forEach(t=>{this.remove(t)})})}get(t){return g(this,nn).get(t)}getAll(){return[...g(this,nn).values()]}find(t){const n={exact:!0,...t};return this.getAll().find(r=>$h(n,r))}findAll(t={}){const n=this.getAll();return Object.keys(t).length>0?n.filter(r=>$h(t,r)):n}notify(t){_e.batch(()=>{this.listeners.forEach(n=>{n(t)})})}onFocus(){_e.batch(()=>{this.getAll().forEach(t=>{t.onFocus()})})}onOnline(){_e.batch(()=>{this.getAll().forEach(t=>{t.onOnline()})})}},nn=new WeakMap,Gp),rn,qe,Pr,sn,Ln,Xp,lx=(Xp=class extends _g{constructor(t){super();U(this,sn);U(this,rn);U(this,qe);U(this,Pr);this.mutationId=t.mutationId,j(this,qe,t.mutationCache),j(this,rn,[]),this.state=t.state||Cg(),this.setOptions(t.options),this.scheduleGc()}setOptions(t){this.options=t,this.updateGcTime(this.options.gcTime)}get meta(){return this.options.meta}addObserver(t){g(this,rn).includes(t)||(g(this,rn).push(t),this.clearGcTimeout(),g(this,qe).notify({type:"observerAdded",mutation:this,observer:t}))}removeObserver(t){j(this,rn,g(this,rn).filter(n=>n!==t)),this.scheduleGc(),g(this,qe).notify({type:"observerRemoved",mutation:this,observer:t})}optionalRemove(){g(this,rn).length||(this.state.status==="pending"?this.scheduleGc():g(this,qe).remove(this))}continue(){var t;return((t=g(this,Pr))==null?void 0:t.continue())??this.execute(this.state.variables)}async execute(t){var i,s,o,l,a,c,f,u,d,h,v,w,S,m,p,y,x,C,T,k;j(this,Pr,Eg({fn:()=>this.options.mutationFn?this.options.mutationFn(t):Promise.reject(new Error("No mutationFn found")),onFail:(R,I)=>{q(this,sn,Ln).call(this,{type:"failed",failureCount:R,error:I})},onPause:()=>{q(this,sn,Ln).call(this,{type:"pause"})},onContinue:()=>{q(this,sn,Ln).call(this,{type:"continue"})},retry:this.options.retry??0,retryDelay:this.options.retryDelay,networkMode:this.options.networkMode,canRun:()=>g(this,qe).canRun(this)}));const n=this.state.status==="pending",r=!g(this,Pr).canStart();try{if(!n){q(this,sn,Ln).call(this,{type:"pending",variables:t,isPaused:r}),await((s=(i=g(this,qe).config).onMutate)==null?void 0:s.call(i,t,this));const I=await((l=(o=this.options).onMutate)==null?void 0:l.call(o,t));I!==this.state.context&&q(this,sn,Ln).call(this,{type:"pending",context:I,variables:t,isPaused:r})}const R=await g(this,Pr).start();return await((c=(a=g(this,qe).config).onSuccess)==null?void 0:c.call(a,R,t,this.state.context,this)),await((u=(f=this.options).onSuccess)==null?void 0:u.call(f,R,t,this.state.context)),await((h=(d=g(this,qe).config).onSettled)==null?void 0:h.call(d,R,null,this.state.variables,this.state.context,this)),await((w=(v=this.options).onSettled)==null?void 0:w.call(v,R,null,t,this.state.context)),q(this,sn,Ln).call(this,{type:"success",data:R}),R}catch(R){try{throw await((m=(S=g(this,qe).config).onError)==null?void 0:m.call(S,R,t,this.state.context,this)),await((y=(p=this.options).onError)==null?void 0:y.call(p,R,t,this.state.context)),await((C=(x=g(this,qe).config).onSettled)==null?void 0:C.call(x,void 0,R,this.state.variables,this.state.context,this)),await((k=(T=this.options).onSettled)==null?void 0:k.call(T,void 0,R,t,this.state.context)),R}finally{q(this,sn,Ln).call(this,{type:"error",error:R})}}finally{g(this,qe).runNext(this)}}},rn=new WeakMap,qe=new WeakMap,Pr=new WeakMap,sn=new WeakSet,Ln=function(t){const n=r=>{switch(t.type){case"failed":return{...r,failureCount:t.failureCount,failureReason:t.error};case"pause":return{...r,isPaused:!0};case"continue":return{...r,isPaused:!1};case"pending":return{...r,context:t.context,data:void 0,failureCount:0,failureReason:null,error:null,isPaused:t.isPaused,status:"pending",variables:t.variables,submittedAt:Date.now()};case"success":return{...r,data:t.data,failureCount:0,failureReason:null,error:null,status:"success",isPaused:!1};case"error":return{...r,data:void 0,error:t.error,failureCount:r.failureCount+1,failureReason:t.error,isPaused:!1,status:"error"}}};this.state=n(this.state),_e.batch(()=>{g(this,rn).forEach(r=>{r.onMutationUpdate(t)}),g(this,qe).notify({mutation:this,type:"updated",action:t})})},Xp);function Cg(){return{context:void 0,data:void 0,error:null,failureCount:0,failureReason:null,isPaused:!1,status:"idle",variables:void 0,submittedAt:0}}var pt,to,Zp,ax=(Zp=class extends Zi{constructor(t={}){super();U(this,pt);U(this,to);this.config=t,j(this,pt,new Map),j(this,to,Date.now())}build(t,n,r){const i=new lx({mutationCache:this,mutationId:++So(this,to)._,options:t.defaultMutationOptions(n),state:r});return this.add(i),i}add(t){const n=Mo(t),r=g(this,pt).get(n)??[];r.push(t),g(this,pt).set(n,r),this.notify({type:"added",mutation:t})}remove(t){var r;const n=Mo(t);if(g(this,pt).has(n)){const i=(r=g(this,pt).get(n))==null?void 0:r.filter(s=>s!==t);i&&(i.length===0?g(this,pt).delete(n):g(this,pt).set(n,i))}this.notify({type:"removed",mutation:t})}canRun(t){var r;const n=(r=g(this,pt).get(Mo(t)))==null?void 0:r.find(i=>i.state.status==="pending");return!n||n===t}runNext(t){var r;const n=(r=g(this,pt).get(Mo(t)))==null?void 0:r.find(i=>i!==t&&i.state.isPaused);return(n==null?void 0:n.continue())??Promise.resolve()}clear(){_e.batch(()=>{this.getAll().forEach(t=>{this.remove(t)})})}getAll(){return[...g(this,pt).values()].flat()}find(t){const n={exact:!0,...t};return this.getAll().find(r=>Ih(n,r))}findAll(t={}){return this.getAll().filter(n=>Ih(t,n))}notify(t){_e.batch(()=>{this.listeners.forEach(n=>{n(t)})})}resumePausedMutations(){const t=this.getAll().filter(n=>n.state.isPaused);return _e.batch(()=>Promise.all(t.map(n=>n.continue().catch(Ot))))}},pt=new WeakMap,to=new WeakMap,Zp);function Mo(e){var t;return((t=e.options.scope)==null?void 0:t.id)??String(e.mutationId)}function Mh(e){return{onFetch:(t,n)=>{var f,u,d,h,v;const r=t.options,i=(d=(u=(f=t.fetchOptions)==null?void 0:f.meta)==null?void 0:u.fetchMore)==null?void 0:d.direction,s=((h=t.state.data)==null?void 0:h.pages)||[],o=((v=t.state.data)==null?void 0:v.pageParams)||[];let l={pages:[],pageParams:[]},a=0;const c=async()=>{let w=!1;const S=y=>{Object.defineProperty(y,"signal",{enumerable:!0,get:()=>(t.signal.aborted?w=!0:t.signal.addEventListener("abort",()=>{w=!0}),t.signal)})},m=xg(t.options,t.fetchOptions),p=async(y,x,C)=>{if(w)return Promise.reject();if(x==null&&y.pages.length)return Promise.resolve(y);const T={queryKey:t.queryKey,pageParam:x,direction:C?"backward":"forward",meta:t.options.meta};S(T);const k=await m(T),{maxPages:R}=t.options,I=C?Jw:Zw;return{pages:I(y.pages,k,R),pageParams:I(y.pageParams,x,R)}};if(i&&s.length){const y=i==="backward",x=y?ux:zh,C={pages:s,pageParams:o},T=x(r,C);l=await p(C,T,y)}else{const y=e??s.length;do{const x=a===0?o[0]??r.initialPageParam:zh(r,l);if(a>0&&x==null)break;l=await p(l,x),a++}while(a<y)}return l};t.options.persister?t.fetchFn=()=>{var w,S;return(S=(w=t.options).persister)==null?void 0:S.call(w,c,{queryKey:t.queryKey,meta:t.options.meta,signal:t.signal},n)}:t.fetchFn=c}}}function zh(e,{pages:t,pageParams:n}){const r=t.length-1;return t.length>0?e.getNextPageParam(t[r],t,n[r],n):void 0}function ux(e,{pages:t,pageParams:n}){var r;return t.length>0?(r=e.getPreviousPageParam)==null?void 0:r.call(e,t[0],t,n[0],n):void 0}var ye,Hn,Wn,Pi,Ai,Qn,ji,Fi,Jp,cx=(Jp=class{constructor(e={}){U(this,ye);U(this,Hn);U(this,Wn);U(this,Pi);U(this,Ai);U(this,Qn);U(this,ji);U(this,Fi);j(this,ye,e.queryCache||new ox),j(this,Hn,e.mutationCache||new ax),j(this,Wn,e.defaultOptions||{}),j(this,Pi,new Map),j(this,Ai,new Map),j(this,Qn,0)}mount(){So(this,Qn)._++,g(this,Qn)===1&&(j(this,ji,Qf.subscribe(async e=>{e&&(await this.resumePausedMutations(),g(this,ye).onFocus())})),j(this,Fi,Ll.subscribe(async e=>{e&&(await this.resumePausedMutations(),g(this,ye).onOnline())})))}unmount(){var e,t;So(this,Qn)._--,g(this,Qn)===0&&((e=g(this,ji))==null||e.call(this),j(this,ji,void 0),(t=g(this,Fi))==null||t.call(this),j(this,Fi,void 0))}isFetching(e){return g(this,ye).findAll({...e,fetchStatus:"fetching"}).length}isMutating(e){return g(this,Hn).findAll({...e,status:"pending"}).length}getQueryData(e){var n;const t=this.defaultQueryOptions({queryKey:e});return(n=g(this,ye).get(t.queryHash))==null?void 0:n.state.data}ensureQueryData(e){const t=this.getQueryData(e.queryKey);if(t===void 0)return this.fetchQuery(e);{const n=this.defaultQueryOptions(e),r=g(this,ye).build(this,n);return e.revalidateIfStale&&r.isStaleByTime(ki(n.staleTime,r))&&this.prefetchQuery(n),Promise.resolve(t)}}getQueriesData(e){return g(this,ye).findAll(e).map(({queryKey:t,state:n})=>{const r=n.data;return[t,r]})}setQueryData(e,t,n){const r=this.defaultQueryOptions({queryKey:e}),i=g(this,ye).get(r.queryHash),s=i==null?void 0:i.state.data,o=Gw(t,s);if(o!==void 0)return g(this,ye).build(this,r).setData(o,{...n,manual:!0})}setQueriesData(e,t,n){return _e.batch(()=>g(this,ye).findAll(e).map(({queryKey:r})=>[r,this.setQueryData(r,t,n)]))}getQueryState(e){var n;const t=this.defaultQueryOptions({queryKey:e});return(n=g(this,ye).get(t.queryHash))==null?void 0:n.state}removeQueries(e){const t=g(this,ye);_e.batch(()=>{t.findAll(e).forEach(n=>{t.remove(n)})})}resetQueries(e,t){const n=g(this,ye),r={type:"active",...e};return _e.batch(()=>(n.findAll(e).forEach(i=>{i.reset()}),this.refetchQueries(r,t)))}cancelQueries(e,t={}){const n={revert:!0,...t},r=_e.batch(()=>g(this,ye).findAll(e).map(i=>i.cancel(n)));return Promise.all(r).then(Ot).catch(Ot)}invalidateQueries(e,t={}){return _e.batch(()=>{if(g(this,ye).findAll(e).forEach(r=>{r.invalidate()}),(e==null?void 0:e.refetchType)==="none")return Promise.resolve();const n={...e,type:(e==null?void 0:e.refetchType)??(e==null?void 0:e.type)??"active"};return this.refetchQueries(n,t)})}refetchQueries(e,t={}){const n={...t,cancelRefetch:t.cancelRefetch??!0},r=_e.batch(()=>g(this,ye).findAll(e).filter(i=>!i.isDisabled()).map(i=>{let s=i.fetch(void 0,n);return n.throwOnError||(s=s.catch(Ot)),i.state.fetchStatus==="paused"?Promise.resolve():s}));return Promise.all(r).then(Ot)}fetchQuery(e){const t=this.defaultQueryOptions(e);t.retry===void 0&&(t.retry=!1);const n=g(this,ye).build(this,t);return n.isStaleByTime(ki(t.staleTime,n))?n.fetch(t):Promise.resolve(n.state.data)}prefetchQuery(e){return this.fetchQuery(e).then(Ot).catch(Ot)}fetchInfiniteQuery(e){return e.behavior=Mh(e.pages),this.fetchQuery(e)}prefetchInfiniteQuery(e){return this.fetchInfiniteQuery(e).then(Ot).catch(Ot)}ensureInfiniteQueryData(e){return e.behavior=Mh(e.pages),this.ensureQueryData(e)}resumePausedMutations(){return Ll.isOnline()?g(this,Hn).resumePausedMutations():Promise.resolve()}getQueryCache(){return g(this,ye)}getMutationCache(){return g(this,Hn)}getDefaultOptions(){return g(this,Wn)}setDefaultOptions(e){j(this,Wn,e)}setQueryDefaults(e,t){g(this,Pi).set(Qr(e),{queryKey:e,defaultOptions:t})}getQueryDefaults(e){const t=[...g(this,Pi).values()],n={};return t.forEach(r=>{Ks(e,r.queryKey)&&Object.assign(n,r.defaultOptions)}),n}setMutationDefaults(e,t){g(this,Ai).set(Qr(e),{mutationKey:e,defaultOptions:t})}getMutationDefaults(e){const t=[...g(this,Ai).values()];let n={};return t.forEach(r=>{Ks(e,r.mutationKey)&&(n={...n,...r.defaultOptions})}),n}defaultQueryOptions(e){if(e._defaulted)return e;const t={...g(this,Wn).queries,...this.getQueryDefaults(e.queryKey),...e,_defaulted:!0};return t.queryHash||(t.queryHash=Hf(t.queryKey,t)),t.refetchOnReconnect===void 0&&(t.refetchOnReconnect=t.networkMode!=="always"),t.throwOnError===void 0&&(t.throwOnError=!!t.suspense),!t.networkMode&&t.persister&&(t.networkMode="offlineFirst"),t.enabled!==!0&&t.queryFn===Wf&&(t.enabled=!1),t}defaultMutationOptions(e){return e!=null&&e._defaulted?e:{...g(this,Wn).mutations,...(e==null?void 0:e.mutationKey)&&this.getMutationDefaults(e.mutationKey),...e,_defaulted:!0}}clear(){g(this,ye).clear(),g(this,Hn).clear()}},ye=new WeakMap,Hn=new WeakMap,Wn=new WeakMap,Pi=new WeakMap,Ai=new WeakMap,Qn=new WeakMap,ji=new WeakMap,Fi=new WeakMap,Jp),tt,G,no,Ke,Ar,$i,qn,on,ro,Ii,Li,jr,Fr,Kn,Di,ne,vs,vc,wc,xc,Sc,bc,Ec,_c,Tg,em,fx=(em=class extends Zi{constructor(t,n){super();U(this,ne);U(this,tt);U(this,G);U(this,no);U(this,Ke);U(this,Ar);U(this,$i);U(this,qn);U(this,on);U(this,ro);U(this,Ii);U(this,Li);U(this,jr);U(this,Fr);U(this,Kn);U(this,Di,new Set);this.options=n,j(this,tt,t),j(this,on,null),j(this,qn,yc()),this.options.experimental_prefetchInRender||g(this,qn).reject(new Error("experimental_prefetchInRender feature flag is not enabled")),this.bindMethods(),this.setOptions(n)}bindMethods(){this.refetch=this.refetch.bind(this)}onSubscribe(){this.listeners.size===1&&(g(this,G).addObserver(this),Bh(g(this,G),this.options)?q(this,ne,vs).call(this):this.updateResult(),q(this,ne,Sc).call(this))}onUnsubscribe(){this.hasListeners()||this.destroy()}shouldFetchOnReconnect(){return kc(g(this,G),this.options,this.options.refetchOnReconnect)}shouldFetchOnWindowFocus(){return kc(g(this,G),this.options,this.options.refetchOnWindowFocus)}destroy(){this.listeners=new Set,q(this,ne,bc).call(this),q(this,ne,Ec).call(this),g(this,G).removeObserver(this)}setOptions(t,n){const r=this.options,i=g(this,G);if(this.options=g(this,tt).defaultQueryOptions(t),this.options.enabled!==void 0&&typeof this.options.enabled!="boolean"&&typeof this.options.enabled!="function"&&typeof Wt(this.options.enabled,g(this,G))!="boolean")throw new Error("Expected enabled to be a boolean or a callback that returns a boolean");q(this,ne,_c).call(this),g(this,G).setOptions(this.options),r._defaulted&&!Il(this.options,r)&&g(this,tt).getQueryCache().notify({type:"observerOptionsUpdated",query:g(this,G),observer:this});const s=this.hasListeners();s&&Uh(g(this,G),i,this.options,r)&&q(this,ne,vs).call(this),this.updateResult(n),s&&(g(this,G)!==i||Wt(this.options.enabled,g(this,G))!==Wt(r.enabled,g(this,G))||ki(this.options.staleTime,g(this,G))!==ki(r.staleTime,g(this,G)))&&q(this,ne,vc).call(this);const o=q(this,ne,wc).call(this);s&&(g(this,G)!==i||Wt(this.options.enabled,g(this,G))!==Wt(r.enabled,g(this,G))||o!==g(this,Kn))&&q(this,ne,xc).call(this,o)}getOptimisticResult(t){const n=g(this,tt).getQueryCache().build(g(this,tt),t),r=this.createResult(n,t);return hx(this,r)&&(j(this,Ke,r),j(this,$i,this.options),j(this,Ar,g(this,G).state)),r}getCurrentResult(){return g(this,Ke)}trackResult(t,n){const r={};return Object.keys(t).forEach(i=>{Object.defineProperty(r,i,{configurable:!1,enumerable:!0,get:()=>(this.trackProp(i),n==null||n(i),t[i])})}),r}trackProp(t){g(this,Di).add(t)}getCurrentQuery(){return g(this,G)}refetch({...t}={}){return this.fetch({...t})}fetchOptimistic(t){const n=g(this,tt).defaultQueryOptions(t),r=g(this,tt).getQueryCache().build(g(this,tt),n);return r.fetch().then(()=>this.createResult(r,n))}fetch(t){return q(this,ne,vs).call(this,{...t,cancelRefetch:t.cancelRefetch??!0}).then(()=>(this.updateResult(),g(this,Ke)))}createResult(t,n){var R;const r=g(this,G),i=this.options,s=g(this,Ke),o=g(this,Ar),l=g(this,$i),c=t!==r?t.state:g(this,no),{state:f}=t;let u={...f},d=!1,h;if(n._optimisticResults){const I=this.hasListeners(),D=!I&&Bh(t,n),B=I&&Uh(t,r,n,i);(D||B)&&(u={...u,...kg(f.data,t.options)}),n._optimisticResults==="isRestoring"&&(u.fetchStatus="idle")}let{error:v,errorUpdatedAt:w,status:S}=u;if(n.select&&u.data!==void 0)if(s&&u.data===(o==null?void 0:o.data)&&n.select===g(this,ro))h=g(this,Ii);else try{j(this,ro,n.select),h=n.select(u.data),h=gc(s==null?void 0:s.data,h,n),j(this,Ii,h),j(this,on,null)}catch(I){j(this,on,I)}else h=u.data;if(n.placeholderData!==void 0&&h===void 0&&S==="pending"){let I;if(s!=null&&s.isPlaceholderData&&n.placeholderData===(l==null?void 0:l.placeholderData))I=s.data;else if(I=typeof n.placeholderData=="function"?n.placeholderData((R=g(this,Li))==null?void 0:R.state.data,g(this,Li)):n.placeholderData,n.select&&I!==void 0)try{I=n.select(I),j(this,on,null)}catch(D){j(this,on,D)}I!==void 0&&(S="success",h=gc(s==null?void 0:s.data,I,n),d=!0)}g(this,on)&&(v=g(this,on),h=g(this,Ii),w=Date.now(),S="error");const m=u.fetchStatus==="fetching",p=S==="pending",y=S==="error",x=p&&m,C=h!==void 0,k={status:S,fetchStatus:u.fetchStatus,isPending:p,isSuccess:S==="success",isError:y,isInitialLoading:x,isLoading:x,data:h,dataUpdatedAt:u.dataUpdatedAt,error:v,errorUpdatedAt:w,failureCount:u.fetchFailureCount,failureReason:u.fetchFailureReason,errorUpdateCount:u.errorUpdateCount,isFetched:u.dataUpdateCount>0||u.errorUpdateCount>0,isFetchedAfterMount:u.dataUpdateCount>c.dataUpdateCount||u.errorUpdateCount>c.errorUpdateCount,isFetching:m,isRefetching:m&&!p,isLoadingError:y&&!C,isPaused:u.fetchStatus==="paused",isPlaceholderData:d,isRefetchError:y&&C,isStale:qf(t,n),refetch:this.refetch,promise:g(this,qn)};if(this.options.experimental_prefetchInRender){const I=se=>{k.status==="error"?se.reject(k.error):k.data!==void 0&&se.resolve(k.data)},D=()=>{const se=j(this,qn,k.promise=yc());I(se)},B=g(this,qn);switch(B.status){case"pending":t.queryHash===r.queryHash&&I(B);break;case"fulfilled":(k.status==="error"||k.data!==B.value)&&D();break;case"rejected":(k.status!=="error"||k.error!==B.reason)&&D();break}}return k}updateResult(t){const n=g(this,Ke),r=this.createResult(g(this,G),this.options);if(j(this,Ar,g(this,G).state),j(this,$i,this.options),g(this,Ar).data!==void 0&&j(this,Li,g(this,G)),Il(r,n))return;j(this,Ke,r);const i={},s=()=>{if(!n)return!0;const{notifyOnChangeProps:o}=this.options,l=typeof o=="function"?o():o;if(l==="all"||!l&&!g(this,Di).size)return!0;const a=new Set(l??g(this,Di));return this.options.throwOnError&&a.add("error"),Object.keys(g(this,Ke)).some(c=>{const f=c;return g(this,Ke)[f]!==n[f]&&a.has(f)})};(t==null?void 0:t.listeners)!==!1&&s()&&(i.listeners=!0),q(this,ne,Tg).call(this,{...i,...t})}onQueryUpdate(){this.updateResult(),this.hasListeners()&&q(this,ne,Sc).call(this)}},tt=new WeakMap,G=new WeakMap,no=new WeakMap,Ke=new WeakMap,Ar=new WeakMap,$i=new WeakMap,qn=new WeakMap,on=new WeakMap,ro=new WeakMap,Ii=new WeakMap,Li=new WeakMap,jr=new WeakMap,Fr=new WeakMap,Kn=new WeakMap,Di=new WeakMap,ne=new WeakSet,vs=function(t){q(this,ne,_c).call(this);let n=g(this,G).fetch(this.options,t);return t!=null&&t.throwOnError||(n=n.catch(Ot)),n},vc=function(){q(this,ne,bc).call(this);const t=ki(this.options.staleTime,g(this,G));if(Wr||g(this,Ke).isStale||!pc(t))return;const r=vg(g(this,Ke).dataUpdatedAt,t)+1;j(this,jr,setTimeout(()=>{g(this,Ke).isStale||this.updateResult()},r))},wc=function(){return(typeof this.options.refetchInterval=="function"?this.options.refetchInterval(g(this,G)):this.options.refetchInterval)??!1},xc=function(t){q(this,ne,Ec).call(this),j(this,Kn,t),!(Wr||Wt(this.options.enabled,g(this,G))===!1||!pc(g(this,Kn))||g(this,Kn)===0)&&j(this,Fr,setInterval(()=>{(this.options.refetchIntervalInBackground||Qf.isFocused())&&q(this,ne,vs).call(this)},g(this,Kn)))},Sc=function(){q(this,ne,vc).call(this),q(this,ne,xc).call(this,q(this,ne,wc).call(this))},bc=function(){g(this,jr)&&(clearTimeout(g(this,jr)),j(this,jr,void 0))},Ec=function(){g(this,Fr)&&(clearInterval(g(this,Fr)),j(this,Fr,void 0))},_c=function(){const t=g(this,tt).getQueryCache().build(g(this,tt),this.options);if(t===g(this,G))return;const n=g(this,G);j(this,G,t),j(this,no,t.state),this.hasListeners()&&(n==null||n.removeObserver(this),t.addObserver(this))},Tg=function(t){_e.batch(()=>{t.listeners&&this.listeners.forEach(n=>{n(g(this,Ke))}),g(this,tt).getQueryCache().notify({query:g(this,G),type:"observerResultsUpdated"})})},em);function dx(e,t){return Wt(t.enabled,e)!==!1&&e.state.data===void 0&&!(e.state.status==="error"&&t.retryOnMount===!1)}function Bh(e,t){return dx(e,t)||e.state.data!==void 0&&kc(e,t,t.refetchOnMount)}function kc(e,t,n){if(Wt(t.enabled,e)!==!1){const r=typeof n=="function"?n(e):n;return r==="always"||r!==!1&&qf(e,t)}return!1}function Uh(e,t,n,r){return(e!==t||Wt(r.enabled,e)===!1)&&(!n.suspense||e.state.status!=="error")&&qf(e,n)}function qf(e,t){return Wt(t.enabled,e)!==!1&&e.isStaleByTime(ki(t.staleTime,e))}function hx(e,t){return!Il(e.getCurrentResult(),t)}var Yn,Gn,nt,Sn,kn,il,Cc,tm,px=(tm=class extends Zi{constructor(t,n){super();U(this,kn);U(this,Yn);U(this,Gn);U(this,nt);U(this,Sn);j(this,Yn,t),this.setOptions(n),this.bindMethods(),q(this,kn,il).call(this)}bindMethods(){this.mutate=this.mutate.bind(this),this.reset=this.reset.bind(this)}setOptions(t){var r;const n=this.options;this.options=g(this,Yn).defaultMutationOptions(t),Il(this.options,n)||g(this,Yn).getMutationCache().notify({type:"observerOptionsUpdated",mutation:g(this,nt),observer:this}),n!=null&&n.mutationKey&&this.options.mutationKey&&Qr(n.mutationKey)!==Qr(this.options.mutationKey)?this.reset():((r=g(this,nt))==null?void 0:r.state.status)==="pending"&&g(this,nt).setOptions(this.options)}onUnsubscribe(){var t;this.hasListeners()||(t=g(this,nt))==null||t.removeObserver(this)}onMutationUpdate(t){q(this,kn,il).call(this),q(this,kn,Cc).call(this,t)}getCurrentResult(){return g(this,Gn)}reset(){var t;(t=g(this,nt))==null||t.removeObserver(this),j(this,nt,void 0),q(this,kn,il).call(this),q(this,kn,Cc).call(this)}mutate(t,n){var r;return j(this,Sn,n),(r=g(this,nt))==null||r.removeObserver(this),j(this,nt,g(this,Yn).getMutationCache().build(g(this,Yn),this.options)),g(this,nt).addObserver(this),g(this,nt).execute(t)}},Yn=new WeakMap,Gn=new WeakMap,nt=new WeakMap,Sn=new WeakMap,kn=new WeakSet,il=function(){var n;const t=((n=g(this,nt))==null?void 0:n.state)??Cg();j(this,Gn,{...t,isPending:t.status==="pending",isSuccess:t.status==="success",isError:t.status==="error",isIdle:t.status==="idle",mutate:this.mutate,reset:this.reset})},Cc=function(t){_e.batch(()=>{var n,r,i,s,o,l,a,c;if(g(this,Sn)&&this.hasListeners()){const f=g(this,Gn).variables,u=g(this,Gn).context;(t==null?void 0:t.type)==="success"?((r=(n=g(this,Sn)).onSuccess)==null||r.call(n,t.data,f,u),(s=(i=g(this,Sn)).onSettled)==null||s.call(i,t.data,null,f,u)):(t==null?void 0:t.type)==="error"&&((l=(o=g(this,Sn)).onError)==null||l.call(o,t.error,f,u),(c=(a=g(this,Sn)).onSettled)==null||c.call(a,void 0,t.error,f,u))}this.listeners.forEach(f=>{f(g(this,Gn))})})},tm),Og=b.createContext(void 0),Rg=e=>{const t=b.useContext(Og);if(!t)throw new Error("No QueryClient set, use QueryClientProvider to set one");return t},mx=({client:e,children:t})=>(b.useEffect(()=>(e.mount(),()=>{e.unmount()}),[e]),_.jsx(Og.Provider,{value:e,children:t})),Ng=b.createContext(!1),gx=()=>b.useContext(Ng);Ng.Provider;function yx(){let e=!1;return{clearReset:()=>{e=!1},reset:()=>{e=!0},isReset:()=>e}}var vx=b.createContext(yx()),wx=()=>b.useContext(vx);function Pg(e,t){return typeof e=="function"?e(...t):!!e}function Tc(){}var xx=(e,t)=>{(e.suspense||e.throwOnError||e.experimental_prefetchInRender)&&(t.isReset()||(e.retryOnMount=!1))},Sx=e=>{b.useEffect(()=>{e.clearReset()},[e])},bx=({result:e,errorResetBoundary:t,throwOnError:n,query:r})=>e.isError&&!t.isReset()&&!e.isFetching&&r&&Pg(n,[e.error,r]),Ex=e=>{e.suspense&&(e.staleTime===void 0&&(e.staleTime=1e3),typeof e.gcTime=="number"&&(e.gcTime=Math.max(e.gcTime,1e3)))},_x=(e,t)=>e.isLoading&&e.isFetching&&!t,kx=(e,t)=>(e==null?void 0:e.suspense)&&t.isPending,Vh=(e,t,n)=>t.fetchOptimistic(e).catch(()=>{n.clearReset()});function Cx(e,t,n){var f,u,d,h,v;const r=Rg(),i=gx(),s=wx(),o=r.defaultQueryOptions(e);(u=(f=r.getDefaultOptions().queries)==null?void 0:f._experimental_beforeQuery)==null||u.call(f,o),o._optimisticResults=i?"isRestoring":"optimistic",Ex(o),xx(o,s),Sx(s);const l=!r.getQueryCache().get(o.queryHash),[a]=b.useState(()=>new t(r,o)),c=a.getOptimisticResult(o);if(b.useSyncExternalStore(b.useCallback(w=>{const S=i?Tc:a.subscribe(_e.batchCalls(w));return a.updateResult(),S},[a,i]),()=>a.getCurrentResult(),()=>a.getCurrentResult()),b.useEffect(()=>{a.setOptions(o,{listeners:!1})},[o,a]),kx(o,c))throw Vh(o,a,s);if(bx({result:c,errorResetBoundary:s,throwOnError:o.throwOnError,query:r.getQueryCache().get(o.queryHash)}))throw c.error;if((h=(d=r.getDefaultOptions().queries)==null?void 0:d._experimental_afterQuery)==null||h.call(d,o,c),o.experimental_prefetchInRender&&!Wr&&_x(c,i)){const w=l?Vh(o,a,s):(v=r.getQueryCache().get(o.queryHash))==null?void 0:v.promise;w==null||w.catch(Tc).finally(()=>{a.updateResult()})}return o.notifyOnChangeProps?c:a.trackResult(c)}function Tx(e,t){return Cx(e,fx)}function Ox(e,t){const n=Rg(),[r]=b.useState(()=>new px(n,e));b.useEffect(()=>{r.setOptions(e)},[r,e]);const i=b.useSyncExternalStore(b.useCallback(o=>r.subscribe(_e.batchCalls(o)),[r]),()=>r.getCurrentResult(),()=>r.getCurrentResult()),s=b.useCallback((o,l)=>{r.mutate(o,l).catch(Tc)},[r]);if(i.error&&Pg(r.options.throwOnError,[i.error]))throw i.error;return{...i,mutate:s,mutateAsync:i.mutate}}const Rx=e=>Tx({queryKey:["widgets",e],queryFn:()=>Nx(e)}),Nx=e=>oa(`widgets/with-link/${e}`);function Px(e){return!!e&&typeof e.public_id=="string"&&typeof e.link_id=="string"&&typeof e.name=="string"&&typeof e.is_browser_notification_enabled=="boolean"&&typeof e.is_hidden_on_offline=="boolean"&&typeof e.is_upload_disabled=="boolean"}/**
40
+ `+s.stack}return{value:e,source:t,stack:i,digest:null}}function iu(e,t,n){return{value:e,source:null,stack:n??null,digest:t??null}}function ec(e,t){try{console.error(t.value)}catch(n){setTimeout(function(){throw n})}}var cw=typeof WeakMap=="function"?WeakMap:Map;function z0(e,t,n){n=_n(-1,n),n.tag=3,n.payload={element:null};var r=t.value;return n.callback=function(){Al||(Al=!0,cc=r),ec(e,t)},n}function B0(e,t,n){n=_n(-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(){ec(e,t)}}var s=e.stateNode;return s!==null&&typeof s.componentDidCatch=="function"&&(n.callback=function(){ec(e,t),typeof r!="function"&&(sr===null?sr=new Set([this]):sr.add(this));var o=t.stack;this.componentDidCatch(t.value,{componentStack:o!==null?o:""})}),n}function yh(e,t,n){var r=e.pingCache;if(r===null){r=e.pingCache=new cw;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=_w.bind(null,e,t,n),t.then(e,e))}function gh(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 vh(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=_n(-1,1),t.tag=2,ir(n,t,1))),n.lanes|=1),e)}var fw=Nn.ReactCurrentOwner,ot=!1;function Ye(e,t,n,r){t.child=e===null?y0(t,null,n,r):Ui(t,e.child,n,r)}function wh(e,t,n,r,i){n=n.render;var s=t.ref;return Ei(t,i),r=Of(e,t,n,r,s,i),n=Rf(),e!==null&&!ot?(t.updateQueue=e.updateQueue,t.flags&=-2053,e.lanes&=~i,Rn(e,t,i)):(he&&n&&yf(t),t.flags|=1,Ye(e,t,r,i),t.child)}function xh(e,t,n,r,i){if(e===null){var s=n.type;return typeof s=="function"&&!Mf(s)&&s.defaultProps===void 0&&n.compare===null&&n.defaultProps===void 0?(t.tag=15,t.type=s,U0(e,t,s,r,i)):(e=rl(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:Ls,n(o,r)&&e.ref===t.ref)return Rn(e,t,i)}return t.flags|=1,e=lr(s,r),e.ref=t.ref,e.return=t,t.child=e}function U0(e,t,n,r,i){if(e!==null){var s=e.memoizedProps;if(Ls(s,r)&&e.ref===t.ref)if(ot=!1,t.pendingProps=r=s,(e.lanes&i)!==0)e.flags&131072&&(ot=!0);else return t.lanes=e.lanes,Rn(e,t,i)}return tc(e,t,n,r,i)}function V0(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},ae(gi,yt),yt|=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,ae(gi,yt),yt|=e,null;t.memoizedState={baseLanes:0,cachePool:null,transitions:null},r=s!==null?s.baseLanes:n,ae(gi,yt),yt|=r}else s!==null?(r=s.baseLanes|n,t.memoizedState=null):r=n,ae(gi,yt),yt|=r;return Ye(e,t,i,n),t.child}function H0(e,t){var n=t.ref;(e===null&&n!==null||e!==null&&e.ref!==n)&&(t.flags|=512,t.flags|=2097152)}function tc(e,t,n,r,i){var s=at(n)?zr:Ue.current;return s=zi(t,s),Ei(t,i),n=Of(e,t,n,r,s,i),r=Rf(),e!==null&&!ot?(t.updateQueue=e.updateQueue,t.flags&=-2053,e.lanes&=~i,Rn(e,t,i)):(he&&r&&yf(t),t.flags|=1,Ye(e,t,n,i),t.child)}function Sh(e,t,n,r,i){if(at(n)){var s=!0;bl(t)}else s=!1;if(Ei(t,i),t.stateNode===null)el(e,t),M0(t,n,r),Ju(t,n,r,i),r=!0;else if(e===null){var o=t.stateNode,l=t.memoizedProps;o.props=l;var a=o.context,c=n.contextType;typeof c=="object"&&c!==null?c=Ft(c):(c=at(n)?zr:Ue.current,c=zi(t,c));var f=n.getDerivedStateFromProps,u=typeof f=="function"||typeof o.getSnapshotBeforeUpdate=="function";u||typeof o.UNSAFE_componentWillReceiveProps!="function"&&typeof o.componentWillReceiveProps!="function"||(l!==r||a!==c)&&mh(t,o,r,c),Mn=!1;var d=t.memoizedState;o.state=d,Tl(t,r,o,i),a=t.memoizedState,l!==r||d!==a||lt.current||Mn?(typeof f=="function"&&(Zu(t,n,f,r),a=t.memoizedState),(l=Mn||ph(t,n,l,r,d,a,c))?(u||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=c,r=l):(typeof o.componentDidMount=="function"&&(t.flags|=4194308),r=!1)}else{o=t.stateNode,v0(e,t),l=t.memoizedProps,c=t.type===t.elementType?l:zt(t.type,l),o.props=c,u=t.pendingProps,d=o.context,a=n.contextType,typeof a=="object"&&a!==null?a=Ft(a):(a=at(n)?zr:Ue.current,a=zi(t,a));var h=n.getDerivedStateFromProps;(f=typeof h=="function"||typeof o.getSnapshotBeforeUpdate=="function")||typeof o.UNSAFE_componentWillReceiveProps!="function"&&typeof o.componentWillReceiveProps!="function"||(l!==u||d!==a)&&mh(t,o,r,a),Mn=!1,d=t.memoizedState,o.state=d,Tl(t,r,o,i);var v=t.memoizedState;l!==u||d!==v||lt.current||Mn?(typeof h=="function"&&(Zu(t,n,h,r),v=t.memoizedState),(c=Mn||ph(t,n,c,r,d,v,a)||!1)?(f||typeof o.UNSAFE_componentWillUpdate!="function"&&typeof o.componentWillUpdate!="function"||(typeof o.componentWillUpdate=="function"&&o.componentWillUpdate(r,v,a),typeof o.UNSAFE_componentWillUpdate=="function"&&o.UNSAFE_componentWillUpdate(r,v,a)),typeof o.componentDidUpdate=="function"&&(t.flags|=4),typeof o.getSnapshotBeforeUpdate=="function"&&(t.flags|=1024)):(typeof o.componentDidUpdate!="function"||l===e.memoizedProps&&d===e.memoizedState||(t.flags|=4),typeof o.getSnapshotBeforeUpdate!="function"||l===e.memoizedProps&&d===e.memoizedState||(t.flags|=1024),t.memoizedProps=r,t.memoizedState=v),o.props=r,o.state=v,o.context=a,r=c):(typeof o.componentDidUpdate!="function"||l===e.memoizedProps&&d===e.memoizedState||(t.flags|=4),typeof o.getSnapshotBeforeUpdate!="function"||l===e.memoizedProps&&d===e.memoizedState||(t.flags|=1024),r=!1)}return nc(e,t,n,r,s,i)}function nc(e,t,n,r,i,s){H0(e,t);var o=(t.flags&128)!==0;if(!r&&!o)return i&&oh(t,n,!1),Rn(e,t,s);r=t.stateNode,fw.current=t;var l=o&&typeof n.getDerivedStateFromError!="function"?null:r.render();return t.flags|=1,e!==null&&o?(t.child=Ui(t,e.child,null,s),t.child=Ui(t,null,l,s)):Ye(e,t,l,s),t.memoizedState=r.state,i&&oh(t,n,!0),t.child}function W0(e){var t=e.stateNode;t.pendingContext?sh(e,t.pendingContext,t.pendingContext!==t.context):t.context&&sh(e,t.context,!1),_f(e,t.containerInfo)}function bh(e,t,n,r,i){return Bi(),vf(i),t.flags|=256,Ye(e,t,n,r),t.child}var rc={dehydrated:null,treeContext:null,retryLane:0};function ic(e){return{baseLanes:e,cachePool:null,transitions:null}}function Q0(e,t,n){var r=t.pendingProps,i=pe.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),ae(pe,i&1),e===null)return Gu(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=ta(o,r,0,null),e=Ir(e,r,n,null),s.return=t,e.return=t,s.sibling=e,t.child=s,t.child.memoizedState=ic(n),t.memoizedState=rc,e):Af(t,o));if(i=e.memoizedState,i!==null&&(l=i.dehydrated,l!==null))return dw(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=lr(i,a),r.subtreeFlags=i.subtreeFlags&14680064),l!==null?s=lr(l,s):(s=Ir(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?ic(n):{baseLanes:o.baseLanes|n,cachePool:null,transitions:o.transitions},s.memoizedState=o,s.childLanes=e.childLanes&~n,t.memoizedState=rc,r}return s=e.child,e=s.sibling,r=lr(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 Af(e,t){return t=ta({mode:"visible",children:t},e.mode,0,null),t.return=e,e.child=t}function $o(e,t,n,r){return r!==null&&vf(r),Ui(t,e.child,null,n),e=Af(t,t.pendingProps.children),e.flags|=2,t.memoizedState=null,e}function dw(e,t,n,r,i,s,o){if(n)return t.flags&256?(t.flags&=-257,r=iu(Error(O(422))),$o(e,t,o,r)):t.memoizedState!==null?(t.child=e.child,t.flags|=128,null):(s=r.fallback,i=t.mode,r=ta({mode:"visible",children:r.children},i,0,null),s=Ir(s,i,o,null),s.flags|=2,r.return=t,s.return=t,r.sibling=s,t.child=r,t.mode&1&&Ui(t,e.child,null,o),t.child.memoizedState=ic(o),t.memoizedState=rc,s);if(!(t.mode&1))return $o(e,t,o,null);if(i.data==="$!"){if(r=i.nextSibling&&i.nextSibling.dataset,r)var l=r.dgst;return r=l,s=Error(O(419)),r=iu(s,r,void 0),$o(e,t,o,r)}if(l=(o&e.childLanes)!==0,ot||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,On(e,i),Yt(r,e,i,-1))}return Lf(),r=iu(Error(O(421))),$o(e,t,o,r)}return i.data==="$?"?(t.flags|=128,t.child=e.child,t=kw.bind(null,e),i._reactRetry=t,null):(e=s.treeContext,gt=rr(i.nextSibling),xt=t,he=!0,Ht=null,e!==null&&(Rt[Nt++]=bn,Rt[Nt++]=En,Rt[Nt++]=Br,bn=e.id,En=e.overflow,Br=t),t=Af(t,r.children),t.flags|=4096,t)}function Eh(e,t,n){e.lanes|=t;var r=e.alternate;r!==null&&(r.lanes|=t),Xu(e.return,t,n)}function su(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 q0(e,t,n){var r=t.pendingProps,i=r.revealOrder,s=r.tail;if(Ye(e,t,r.children,n),r=pe.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&&Eh(e,n,t);else if(e.tag===19)Eh(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(ae(pe,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&&Ol(e)===null&&(i=n),n=n.sibling;n=i,n===null?(i=t.child,t.child=null):(i=n.sibling,n.sibling=null),su(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&&Ol(e)===null){t.child=i;break}e=i.sibling,i.sibling=n,n=i,i=e}su(t,!0,n,null,s);break;case"together":su(t,!1,null,null,void 0);break;default:t.memoizedState=null}return t.child}function el(e,t){!(t.mode&1)&&e!==null&&(e.alternate=null,t.alternate=null,t.flags|=2)}function Rn(e,t,n){if(e!==null&&(t.dependencies=e.dependencies),Vr|=t.lanes,!(n&t.childLanes))return null;if(e!==null&&t.child!==e.child)throw Error(O(153));if(t.child!==null){for(e=t.child,n=lr(e,e.pendingProps),t.child=n,n.return=t;e.sibling!==null;)e=e.sibling,n=n.sibling=lr(e,e.pendingProps),n.return=t;n.sibling=null}return t.child}function hw(e,t,n){switch(t.tag){case 3:W0(t),Bi();break;case 5:w0(t);break;case 1:at(t.type)&&bl(t);break;case 4:_f(t,t.stateNode.containerInfo);break;case 10:var r=t.type._context,i=t.memoizedProps.value;ae(kl,r._currentValue),r._currentValue=i;break;case 13:if(r=t.memoizedState,r!==null)return r.dehydrated!==null?(ae(pe,pe.current&1),t.flags|=128,null):n&t.child.childLanes?Q0(e,t,n):(ae(pe,pe.current&1),e=Rn(e,t,n),e!==null?e.sibling:null);ae(pe,pe.current&1);break;case 19:if(r=(n&t.childLanes)!==0,e.flags&128){if(r)return q0(e,t,n);t.flags|=128}if(i=t.memoizedState,i!==null&&(i.rendering=null,i.tail=null,i.lastEffect=null),ae(pe,pe.current),r)break;return null;case 22:case 23:return t.lanes=0,V0(e,t,n)}return Rn(e,t,n)}var K0,sc,Y0,G0;K0=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}};sc=function(){};Y0=function(e,t,n,r){var i=e.memoizedProps;if(i!==r){e=t.stateNode,Cr(un.current);var s=null;switch(n){case"input":i=Tu(e,i),r=Tu(e,r),s=[];break;case"select":i=ye({},i,{value:void 0}),r=ye({},r,{value:void 0}),s=[];break;case"textarea":i=Nu(e,i),r=Nu(e,r),s=[];break;default:typeof i.onClick!="function"&&typeof r.onClick=="function"&&(e.onclick=xl)}Au(n,r);var o;n=null;for(c in i)if(!r.hasOwnProperty(c)&&i.hasOwnProperty(c)&&i[c]!=null)if(c==="style"){var l=i[c];for(o in l)l.hasOwnProperty(o)&&(n||(n={}),n[o]="")}else c!=="dangerouslySetInnerHTML"&&c!=="children"&&c!=="suppressContentEditableWarning"&&c!=="suppressHydrationWarning"&&c!=="autoFocus"&&(Ps.hasOwnProperty(c)?s||(s=[]):(s=s||[]).push(c,null));for(c in r){var a=r[c];if(l=i!=null?i[c]:void 0,r.hasOwnProperty(c)&&a!==l&&(a!=null||l!=null))if(c==="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(c,n)),n=a;else c==="dangerouslySetInnerHTML"?(a=a?a.__html:void 0,l=l?l.__html:void 0,a!=null&&l!==a&&(s=s||[]).push(c,a)):c==="children"?typeof a!="string"&&typeof a!="number"||(s=s||[]).push(c,""+a):c!=="suppressContentEditableWarning"&&c!=="suppressHydrationWarning"&&(Ps.hasOwnProperty(c)?(a!=null&&c==="onScroll"&&ue("scroll",e),s||l===a||(s=[])):(s=s||[]).push(c,a))}n&&(s=s||[]).push("style",n);var c=s;(t.updateQueue=c)&&(t.flags|=4)}};G0=function(e,t,n,r){n!==r&&(t.flags|=4)};function cs(e,t){if(!he)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 Me(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 pw(e,t,n){var r=t.pendingProps;switch(gf(t),t.tag){case 2:case 16:case 15:case 0:case 11:case 7:case 8:case 12:case 9:case 14:return Me(t),null;case 1:return at(t.type)&&Sl(),Me(t),null;case 3:return r=t.stateNode,Vi(),fe(lt),fe(Ue),Cf(),r.pendingContext&&(r.context=r.pendingContext,r.pendingContext=null),(e===null||e.child===null)&&(jo(t)?t.flags|=4:e===null||e.memoizedState.isDehydrated&&!(t.flags&256)||(t.flags|=1024,Ht!==null&&(hc(Ht),Ht=null))),sc(e,t),Me(t),null;case 5:kf(t);var i=Cr(Vs.current);if(n=t.type,e!==null&&t.stateNode!=null)Y0(e,t,n,r,i),e.ref!==t.ref&&(t.flags|=512,t.flags|=2097152);else{if(!r){if(t.stateNode===null)throw Error(O(166));return Me(t),null}if(e=Cr(un.current),jo(t)){r=t.stateNode,n=t.type;var s=t.memoizedProps;switch(r[ln]=t,r[Bs]=s,e=(t.mode&1)!==0,n){case"dialog":ue("cancel",r),ue("close",r);break;case"iframe":case"object":case"embed":ue("load",r);break;case"video":case"audio":for(i=0;i<gs.length;i++)ue(gs[i],r);break;case"source":ue("error",r);break;case"img":case"image":case"link":ue("error",r),ue("load",r);break;case"details":ue("toggle",r);break;case"input":Ad(r,s),ue("invalid",r);break;case"select":r._wrapperState={wasMultiple:!!s.multiple},ue("invalid",r);break;case"textarea":Fd(r,s),ue("invalid",r)}Au(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&&Ao(r.textContent,l,e),i=["children",l]):typeof l=="number"&&r.textContent!==""+l&&(s.suppressHydrationWarning!==!0&&Ao(r.textContent,l,e),i=["children",""+l]):Ps.hasOwnProperty(o)&&l!=null&&o==="onScroll"&&ue("scroll",r)}switch(n){case"input":_o(r),jd(r,s,!0);break;case"textarea":_o(r),$d(r);break;case"select":case"option":break;default:typeof s.onClick=="function"&&(r.onclick=xl)}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=_m(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[ln]=t,e[Bs]=r,K0(e,t,!1,!1),t.stateNode=e;e:{switch(o=ju(n,r),n){case"dialog":ue("cancel",e),ue("close",e),i=r;break;case"iframe":case"object":case"embed":ue("load",e),i=r;break;case"video":case"audio":for(i=0;i<gs.length;i++)ue(gs[i],e);i=r;break;case"source":ue("error",e),i=r;break;case"img":case"image":case"link":ue("error",e),ue("load",e),i=r;break;case"details":ue("toggle",e),i=r;break;case"input":Ad(e,r),i=Tu(e,r),ue("invalid",e);break;case"option":i=r;break;case"select":e._wrapperState={wasMultiple:!!r.multiple},i=ye({},r,{value:void 0}),ue("invalid",e);break;case"textarea":Fd(e,r),i=Nu(e,r),ue("invalid",e);break;default:i=r}Au(n,i),l=i;for(s in l)if(l.hasOwnProperty(s)){var a=l[s];s==="style"?Tm(e,a):s==="dangerouslySetInnerHTML"?(a=a?a.__html:void 0,a!=null&&km(e,a)):s==="children"?typeof a=="string"?(n!=="textarea"||a!=="")&&As(e,a):typeof a=="number"&&As(e,""+a):s!=="suppressContentEditableWarning"&&s!=="suppressHydrationWarning"&&s!=="autoFocus"&&(Ps.hasOwnProperty(s)?a!=null&&s==="onScroll"&&ue("scroll",e):a!=null&&tf(e,s,a,o))}switch(n){case"input":_o(e),jd(e,r,!1);break;case"textarea":_o(e),$d(e);break;case"option":r.value!=null&&e.setAttribute("value",""+cr(r.value));break;case"select":e.multiple=!!r.multiple,s=r.value,s!=null?wi(e,!!r.multiple,s,!1):r.defaultValue!=null&&wi(e,!!r.multiple,r.defaultValue,!0);break;default:typeof i.onClick=="function"&&(e.onclick=xl)}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 Me(t),null;case 6:if(e&&t.stateNode!=null)G0(e,t,e.memoizedProps,r);else{if(typeof r!="string"&&t.stateNode===null)throw Error(O(166));if(n=Cr(Vs.current),Cr(un.current),jo(t)){if(r=t.stateNode,n=t.memoizedProps,r[ln]=t,(s=r.nodeValue!==n)&&(e=xt,e!==null))switch(e.tag){case 3:Ao(r.nodeValue,n,(e.mode&1)!==0);break;case 5:e.memoizedProps.suppressHydrationWarning!==!0&&Ao(r.nodeValue,n,(e.mode&1)!==0)}s&&(t.flags|=4)}else r=(n.nodeType===9?n:n.ownerDocument).createTextNode(r),r[ln]=t,t.stateNode=r}return Me(t),null;case 13:if(fe(pe),r=t.memoizedState,e===null||e.memoizedState!==null&&e.memoizedState.dehydrated!==null){if(he&&gt!==null&&t.mode&1&&!(t.flags&128))p0(),Bi(),t.flags|=98560,s=!1;else if(s=jo(t),r!==null&&r.dehydrated!==null){if(e===null){if(!s)throw Error(O(318));if(s=t.memoizedState,s=s!==null?s.dehydrated:null,!s)throw Error(O(317));s[ln]=t}else Bi(),!(t.flags&128)&&(t.memoizedState=null),t.flags|=4;Me(t),s=!1}else Ht!==null&&(hc(Ht),Ht=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||pe.current&1?ke===0&&(ke=3):Lf())),t.updateQueue!==null&&(t.flags|=4),Me(t),null);case 4:return Vi(),sc(e,t),e===null&&Ms(t.stateNode.containerInfo),Me(t),null;case 10:return Sf(t.type._context),Me(t),null;case 17:return at(t.type)&&Sl(),Me(t),null;case 19:if(fe(pe),s=t.memoizedState,s===null)return Me(t),null;if(r=(t.flags&128)!==0,o=s.rendering,o===null)if(r)cs(s,!1);else{if(ke!==0||e!==null&&e.flags&128)for(e=t.child;e!==null;){if(o=Ol(e),o!==null){for(t.flags|=128,cs(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 ae(pe,pe.current&1|2),t.child}e=e.sibling}s.tail!==null&&xe()>Wi&&(t.flags|=128,r=!0,cs(s,!1),t.lanes=4194304)}else{if(!r)if(e=Ol(o),e!==null){if(t.flags|=128,r=!0,n=e.updateQueue,n!==null&&(t.updateQueue=n,t.flags|=4),cs(s,!0),s.tail===null&&s.tailMode==="hidden"&&!o.alternate&&!he)return Me(t),null}else 2*xe()-s.renderingStartTime>Wi&&n!==1073741824&&(t.flags|=128,r=!0,cs(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=xe(),t.sibling=null,n=pe.current,ae(pe,r?n&1|2:n&1),t):(Me(t),null);case 22:case 23:return Df(),r=t.memoizedState!==null,e!==null&&e.memoizedState!==null!==r&&(t.flags|=8192),r&&t.mode&1?yt&1073741824&&(Me(t),t.subtreeFlags&6&&(t.flags|=8192)):Me(t),null;case 24:return null;case 25:return null}throw Error(O(156,t.tag))}function mw(e,t){switch(gf(t),t.tag){case 1:return at(t.type)&&Sl(),e=t.flags,e&65536?(t.flags=e&-65537|128,t):null;case 3:return Vi(),fe(lt),fe(Ue),Cf(),e=t.flags,e&65536&&!(e&128)?(t.flags=e&-65537|128,t):null;case 5:return kf(t),null;case 13:if(fe(pe),e=t.memoizedState,e!==null&&e.dehydrated!==null){if(t.alternate===null)throw Error(O(340));Bi()}return e=t.flags,e&65536?(t.flags=e&-65537|128,t):null;case 19:return fe(pe),null;case 4:return Vi(),null;case 10:return Sf(t.type._context),null;case 22:case 23:return Df(),null;case 24:return null;default:return null}}var Io=!1,Be=!1,yw=typeof WeakSet=="function"?WeakSet:Set,F=null;function yi(e,t){var n=e.ref;if(n!==null)if(typeof n=="function")try{n(null)}catch(r){ve(e,t,r)}else n.current=null}function oc(e,t,n){try{n()}catch(r){ve(e,t,r)}}var _h=!1;function gw(e,t){if(Vu=gl,e=t0(),mf(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,c=0,f=0,u=e,d=null;t:for(;;){for(var h;u!==n||i!==0&&u.nodeType!==3||(l=o+i),u!==s||r!==0&&u.nodeType!==3||(a=o+r),u.nodeType===3&&(o+=u.nodeValue.length),(h=u.firstChild)!==null;)d=u,u=h;for(;;){if(u===e)break t;if(d===n&&++c===i&&(l=o),d===s&&++f===r&&(a=o),(h=u.nextSibling)!==null)break;u=d,d=u.parentNode}u=h}n=l===-1||a===-1?null:{start:l,end:a}}else n=null}n=n||{start:0,end:0}}else n=null;for(Hu={focusedElem:e,selectionRange:n},gl=!1,F=t;F!==null;)if(t=F,e=t.child,(t.subtreeFlags&1028)!==0&&e!==null)e.return=t,F=e;else for(;F!==null;){t=F;try{var v=t.alternate;if(t.flags&1024)switch(t.tag){case 0:case 11:case 15:break;case 1:if(v!==null){var w=v.memoizedProps,S=v.memoizedState,m=t.stateNode,p=m.getSnapshotBeforeUpdate(t.elementType===t.type?w:zt(t.type,w),S);m.__reactInternalSnapshotBeforeUpdate=p}break;case 3:var g=t.stateNode.containerInfo;g.nodeType===1?g.textContent="":g.nodeType===9&&g.documentElement&&g.removeChild(g.documentElement);break;case 5:case 6:case 4:case 17:break;default:throw Error(O(163))}}catch(x){ve(t,t.return,x)}if(e=t.sibling,e!==null){e.return=t.return,F=e;break}F=t.return}return v=_h,_h=!1,v}function Cs(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&&oc(t,n,s)}i=i.next}while(i!==r)}}function Jl(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 lc(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 X0(e){var t=e.alternate;t!==null&&(e.alternate=null,X0(t)),e.child=null,e.deletions=null,e.sibling=null,e.tag===5&&(t=e.stateNode,t!==null&&(delete t[ln],delete t[Bs],delete t[qu],delete t[J1],delete t[ew])),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 Z0(e){return e.tag===5||e.tag===3||e.tag===4}function kh(e){e:for(;;){for(;e.sibling===null;){if(e.return===null||Z0(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 ac(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=xl));else if(r!==4&&(e=e.child,e!==null))for(ac(e,t,n),e=e.sibling;e!==null;)ac(e,t,n),e=e.sibling}function uc(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(uc(e,t,n),e=e.sibling;e!==null;)uc(e,t,n),e=e.sibling}var Fe=null,Ut=!1;function In(e,t,n){for(n=n.child;n!==null;)J0(e,t,n),n=n.sibling}function J0(e,t,n){if(an&&typeof an.onCommitFiberUnmount=="function")try{an.onCommitFiberUnmount(Wl,n)}catch{}switch(n.tag){case 5:Be||yi(n,t);case 6:var r=Fe,i=Ut;Fe=null,In(e,t,n),Fe=r,Ut=i,Fe!==null&&(Ut?(e=Fe,n=n.stateNode,e.nodeType===8?e.parentNode.removeChild(n):e.removeChild(n)):Fe.removeChild(n.stateNode));break;case 18:Fe!==null&&(Ut?(e=Fe,n=n.stateNode,e.nodeType===8?Za(e.parentNode,n):e.nodeType===1&&Za(e,n),Is(e)):Za(Fe,n.stateNode));break;case 4:r=Fe,i=Ut,Fe=n.stateNode.containerInfo,Ut=!0,In(e,t,n),Fe=r,Ut=i;break;case 0:case 11:case 14:case 15:if(!Be&&(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)&&oc(n,t,o),i=i.next}while(i!==r)}In(e,t,n);break;case 1:if(!Be&&(yi(n,t),r=n.stateNode,typeof r.componentWillUnmount=="function"))try{r.props=n.memoizedProps,r.state=n.memoizedState,r.componentWillUnmount()}catch(l){ve(n,t,l)}In(e,t,n);break;case 21:In(e,t,n);break;case 22:n.mode&1?(Be=(r=Be)||n.memoizedState!==null,In(e,t,n),Be=r):In(e,t,n);break;default:In(e,t,n)}}function Ch(e){var t=e.updateQueue;if(t!==null){e.updateQueue=null;var n=e.stateNode;n===null&&(n=e.stateNode=new yw),t.forEach(function(r){var i=Cw.bind(null,e,r);n.has(r)||(n.add(r),r.then(i,i))})}}function Lt(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:Fe=l.stateNode,Ut=!1;break e;case 3:Fe=l.stateNode.containerInfo,Ut=!0;break e;case 4:Fe=l.stateNode.containerInfo,Ut=!0;break e}l=l.return}if(Fe===null)throw Error(O(160));J0(s,o,i),Fe=null,Ut=!1;var a=i.alternate;a!==null&&(a.return=null),i.return=null}catch(c){ve(i,t,c)}}if(t.subtreeFlags&12854)for(t=t.child;t!==null;)ey(t,e),t=t.sibling}function ey(e,t){var n=e.alternate,r=e.flags;switch(e.tag){case 0:case 11:case 14:case 15:if(Lt(t,e),Zt(e),r&4){try{Cs(3,e,e.return),Jl(3,e)}catch(w){ve(e,e.return,w)}try{Cs(5,e,e.return)}catch(w){ve(e,e.return,w)}}break;case 1:Lt(t,e),Zt(e),r&512&&n!==null&&yi(n,n.return);break;case 5:if(Lt(t,e),Zt(e),r&512&&n!==null&&yi(n,n.return),e.flags&32){var i=e.stateNode;try{As(i,"")}catch(w){ve(e,e.return,w)}}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&&bm(i,s),ju(l,o);var c=ju(l,s);for(o=0;o<a.length;o+=2){var f=a[o],u=a[o+1];f==="style"?Tm(i,u):f==="dangerouslySetInnerHTML"?km(i,u):f==="children"?As(i,u):tf(i,f,u,c)}switch(l){case"input":Ou(i,s);break;case"textarea":Em(i,s);break;case"select":var d=i._wrapperState.wasMultiple;i._wrapperState.wasMultiple=!!s.multiple;var h=s.value;h!=null?wi(i,!!s.multiple,h,!1):d!==!!s.multiple&&(s.defaultValue!=null?wi(i,!!s.multiple,s.defaultValue,!0):wi(i,!!s.multiple,s.multiple?[]:"",!1))}i[Bs]=s}catch(w){ve(e,e.return,w)}}break;case 6:if(Lt(t,e),Zt(e),r&4){if(e.stateNode===null)throw Error(O(162));i=e.stateNode,s=e.memoizedProps;try{i.nodeValue=s}catch(w){ve(e,e.return,w)}}break;case 3:if(Lt(t,e),Zt(e),r&4&&n!==null&&n.memoizedState.isDehydrated)try{Is(t.containerInfo)}catch(w){ve(e,e.return,w)}break;case 4:Lt(t,e),Zt(e);break;case 13:Lt(t,e),Zt(e),i=e.child,i.flags&8192&&(s=i.memoizedState!==null,i.stateNode.isHidden=s,!s||i.alternate!==null&&i.alternate.memoizedState!==null||($f=xe())),r&4&&Ch(e);break;case 22:if(f=n!==null&&n.memoizedState!==null,e.mode&1?(Be=(c=Be)||f,Lt(t,e),Be=c):Lt(t,e),Zt(e),r&8192){if(c=e.memoizedState!==null,(e.stateNode.isHidden=c)&&!f&&e.mode&1)for(F=e,f=e.child;f!==null;){for(u=F=f;F!==null;){switch(d=F,h=d.child,d.tag){case 0:case 11:case 14:case 15:Cs(4,d,d.return);break;case 1:yi(d,d.return);var v=d.stateNode;if(typeof v.componentWillUnmount=="function"){r=d,n=d.return;try{t=r,v.props=t.memoizedProps,v.state=t.memoizedState,v.componentWillUnmount()}catch(w){ve(r,n,w)}}break;case 5:yi(d,d.return);break;case 22:if(d.memoizedState!==null){Oh(u);continue}}h!==null?(h.return=d,F=h):Oh(u)}f=f.sibling}e:for(f=null,u=e;;){if(u.tag===5){if(f===null){f=u;try{i=u.stateNode,c?(s=i.style,typeof s.setProperty=="function"?s.setProperty("display","none","important"):s.display="none"):(l=u.stateNode,a=u.memoizedProps.style,o=a!=null&&a.hasOwnProperty("display")?a.display:null,l.style.display=Cm("display",o))}catch(w){ve(e,e.return,w)}}}else if(u.tag===6){if(f===null)try{u.stateNode.nodeValue=c?"":u.memoizedProps}catch(w){ve(e,e.return,w)}}else if((u.tag!==22&&u.tag!==23||u.memoizedState===null||u===e)&&u.child!==null){u.child.return=u,u=u.child;continue}if(u===e)break e;for(;u.sibling===null;){if(u.return===null||u.return===e)break e;f===u&&(f=null),u=u.return}f===u&&(f=null),u.sibling.return=u.return,u=u.sibling}}break;case 19:Lt(t,e),Zt(e),r&4&&Ch(e);break;case 21:break;default:Lt(t,e),Zt(e)}}function Zt(e){var t=e.flags;if(t&2){try{e:{for(var n=e.return;n!==null;){if(Z0(n)){var r=n;break e}n=n.return}throw Error(O(160))}switch(r.tag){case 5:var i=r.stateNode;r.flags&32&&(As(i,""),r.flags&=-33);var s=kh(e);uc(e,s,i);break;case 3:case 4:var o=r.stateNode.containerInfo,l=kh(e);ac(e,l,o);break;default:throw Error(O(161))}}catch(a){ve(e,e.return,a)}e.flags&=-3}t&4096&&(e.flags&=-4097)}function vw(e,t,n){F=e,ty(e)}function ty(e,t,n){for(var r=(e.mode&1)!==0;F!==null;){var i=F,s=i.child;if(i.tag===22&&r){var o=i.memoizedState!==null||Io;if(!o){var l=i.alternate,a=l!==null&&l.memoizedState!==null||Be;l=Io;var c=Be;if(Io=o,(Be=a)&&!c)for(F=i;F!==null;)o=F,a=o.child,o.tag===22&&o.memoizedState!==null?Rh(i):a!==null?(a.return=o,F=a):Rh(i);for(;s!==null;)F=s,ty(s),s=s.sibling;F=i,Io=l,Be=c}Th(e)}else i.subtreeFlags&8772&&s!==null?(s.return=i,F=s):Th(e)}}function Th(e){for(;F!==null;){var t=F;if(t.flags&8772){var n=t.alternate;try{if(t.flags&8772)switch(t.tag){case 0:case 11:case 15:Be||Jl(5,t);break;case 1:var r=t.stateNode;if(t.flags&4&&!Be)if(n===null)r.componentDidMount();else{var i=t.elementType===t.type?n.memoizedProps:zt(t.type,n.memoizedProps);r.componentDidUpdate(i,n.memoizedState,r.__reactInternalSnapshotBeforeUpdate)}var s=t.updateQueue;s!==null&&fh(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}fh(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 c=t.alternate;if(c!==null){var f=c.memoizedState;if(f!==null){var u=f.dehydrated;u!==null&&Is(u)}}}break;case 19:case 17:case 21:case 22:case 23:case 25:break;default:throw Error(O(163))}Be||t.flags&512&&lc(t)}catch(d){ve(t,t.return,d)}}if(t===e){F=null;break}if(n=t.sibling,n!==null){n.return=t.return,F=n;break}F=t.return}}function Oh(e){for(;F!==null;){var t=F;if(t===e){F=null;break}var n=t.sibling;if(n!==null){n.return=t.return,F=n;break}F=t.return}}function Rh(e){for(;F!==null;){var t=F;try{switch(t.tag){case 0:case 11:case 15:var n=t.return;try{Jl(4,t)}catch(a){ve(t,n,a)}break;case 1:var r=t.stateNode;if(typeof r.componentDidMount=="function"){var i=t.return;try{r.componentDidMount()}catch(a){ve(t,i,a)}}var s=t.return;try{lc(t)}catch(a){ve(t,s,a)}break;case 5:var o=t.return;try{lc(t)}catch(a){ve(t,o,a)}}}catch(a){ve(t,t.return,a)}if(t===e){F=null;break}var l=t.sibling;if(l!==null){l.return=t.return,F=l;break}F=t.return}}var ww=Math.ceil,Pl=Nn.ReactCurrentDispatcher,jf=Nn.ReactCurrentOwner,jt=Nn.ReactCurrentBatchConfig,J=0,Ne=null,Se=null,$e=0,yt=0,gi=pr(0),ke=0,qs=null,Vr=0,ea=0,Ff=0,Ts=null,it=null,$f=0,Wi=1/0,vn=null,Al=!1,cc=null,sr=null,Do=!1,Zn=null,jl=0,Os=0,fc=null,tl=-1,nl=0;function Ge(){return J&6?xe():tl!==-1?tl:tl=xe()}function or(e){return e.mode&1?J&2&&$e!==0?$e&-$e:nw.transition!==null?(nl===0&&(nl=Mm()),nl):(e=re,e!==0||(e=window.event,e=e===void 0?16:Qm(e.type)),e):1}function Yt(e,t,n,r){if(50<Os)throw Os=0,fc=null,Error(O(185));so(e,n,r),(!(J&2)||e!==Ne)&&(e===Ne&&(!(J&2)&&(ea|=n),ke===4&&Bn(e,$e)),ut(e,r),n===1&&J===0&&!(t.mode&1)&&(Wi=xe()+500,Gl&&mr()))}function ut(e,t){var n=e.callbackNode;n1(e,t);var r=yl(e,e===Ne?$e:0);if(r===0)n!==null&&Ld(n),e.callbackNode=null,e.callbackPriority=0;else if(t=r&-r,e.callbackPriority!==t){if(n!=null&&Ld(n),t===1)e.tag===0?tw(Nh.bind(null,e)):f0(Nh.bind(null,e)),X1(function(){!(J&6)&&mr()}),n=null;else{switch(zm(r)){case 1:n=lf;break;case 4:n=Dm;break;case 16:n=ml;break;case 536870912:n=Lm;break;default:n=ml}n=uy(n,ny.bind(null,e))}e.callbackPriority=t,e.callbackNode=n}}function ny(e,t){if(tl=-1,nl=0,J&6)throw Error(O(327));var n=e.callbackNode;if(_i()&&e.callbackNode!==n)return null;var r=yl(e,e===Ne?$e:0);if(r===0)return null;if(r&30||r&e.expiredLanes||t)t=Fl(e,r);else{t=r;var i=J;J|=2;var s=iy();(Ne!==e||$e!==t)&&(vn=null,Wi=xe()+500,$r(e,t));do try{bw();break}catch(l){ry(e,l)}while(!0);xf(),Pl.current=s,J=i,Se!==null?t=0:(Ne=null,$e=0,t=ke)}if(t!==0){if(t===2&&(i=Lu(e),i!==0&&(r=i,t=dc(e,i))),t===1)throw n=qs,$r(e,0),Bn(e,r),ut(e,xe()),n;if(t===6)Bn(e,r);else{if(i=e.current.alternate,!(r&30)&&!xw(i)&&(t=Fl(e,r),t===2&&(s=Lu(e),s!==0&&(r=s,t=dc(e,s))),t===1))throw n=qs,$r(e,0),Bn(e,r),ut(e,xe()),n;switch(e.finishedWork=i,e.finishedLanes=r,t){case 0:case 1:throw Error(O(345));case 2:br(e,it,vn);break;case 3:if(Bn(e,r),(r&130023424)===r&&(t=$f+500-xe(),10<t)){if(yl(e,0)!==0)break;if(i=e.suspendedLanes,(i&r)!==r){Ge(),e.pingedLanes|=e.suspendedLanes&i;break}e.timeoutHandle=Qu(br.bind(null,e,it,vn),t);break}br(e,it,vn);break;case 4:if(Bn(e,r),(r&4194240)===r)break;for(t=e.eventTimes,i=-1;0<r;){var o=31-Kt(r);s=1<<o,o=t[o],o>i&&(i=o),r&=~s}if(r=i,r=xe()-r,r=(120>r?120:480>r?480:1080>r?1080:1920>r?1920:3e3>r?3e3:4320>r?4320:1960*ww(r/1960))-r,10<r){e.timeoutHandle=Qu(br.bind(null,e,it,vn),r);break}br(e,it,vn);break;case 5:br(e,it,vn);break;default:throw Error(O(329))}}}return ut(e,xe()),e.callbackNode===n?ny.bind(null,e):null}function dc(e,t){var n=Ts;return e.current.memoizedState.isDehydrated&&($r(e,t).flags|=256),e=Fl(e,t),e!==2&&(t=it,it=n,t!==null&&hc(t)),e}function hc(e){it===null?it=e:it.push.apply(it,e)}function xw(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(!Gt(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 Bn(e,t){for(t&=~Ff,t&=~ea,e.suspendedLanes|=t,e.pingedLanes&=~t,e=e.expirationTimes;0<t;){var n=31-Kt(t),r=1<<n;e[n]=-1,t&=~r}}function Nh(e){if(J&6)throw Error(O(327));_i();var t=yl(e,0);if(!(t&1))return ut(e,xe()),null;var n=Fl(e,t);if(e.tag!==0&&n===2){var r=Lu(e);r!==0&&(t=r,n=dc(e,r))}if(n===1)throw n=qs,$r(e,0),Bn(e,t),ut(e,xe()),n;if(n===6)throw Error(O(345));return e.finishedWork=e.current.alternate,e.finishedLanes=t,br(e,it,vn),ut(e,xe()),null}function If(e,t){var n=J;J|=1;try{return e(t)}finally{J=n,J===0&&(Wi=xe()+500,Gl&&mr())}}function Hr(e){Zn!==null&&Zn.tag===0&&!(J&6)&&_i();var t=J;J|=1;var n=jt.transition,r=re;try{if(jt.transition=null,re=1,e)return e()}finally{re=r,jt.transition=n,J=t,!(J&6)&&mr()}}function Df(){yt=gi.current,fe(gi)}function $r(e,t){e.finishedWork=null,e.finishedLanes=0;var n=e.timeoutHandle;if(n!==-1&&(e.timeoutHandle=-1,G1(n)),Se!==null)for(n=Se.return;n!==null;){var r=n;switch(gf(r),r.tag){case 1:r=r.type.childContextTypes,r!=null&&Sl();break;case 3:Vi(),fe(lt),fe(Ue),Cf();break;case 5:kf(r);break;case 4:Vi();break;case 13:fe(pe);break;case 19:fe(pe);break;case 10:Sf(r.type._context);break;case 22:case 23:Df()}n=n.return}if(Ne=e,Se=e=lr(e.current,null),$e=yt=t,ke=0,qs=null,Ff=ea=Vr=0,it=Ts=null,kr!==null){for(t=0;t<kr.length;t++)if(n=kr[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}kr=null}return e}function ry(e,t){do{var n=Se;try{if(xf(),Zo.current=Nl,Rl){for(var r=me.memoizedState;r!==null;){var i=r.queue;i!==null&&(i.pending=null),r=r.next}Rl=!1}if(Ur=0,Re=Ee=me=null,ks=!1,Hs=0,jf.current=null,n===null||n.return===null){ke=1,qs=t,Se=null;break}e:{var s=e,o=n.return,l=n,a=t;if(t=$e,l.flags|=32768,a!==null&&typeof a=="object"&&typeof a.then=="function"){var c=a,f=l,u=f.tag;if(!(f.mode&1)&&(u===0||u===11||u===15)){var d=f.alternate;d?(f.updateQueue=d.updateQueue,f.memoizedState=d.memoizedState,f.lanes=d.lanes):(f.updateQueue=null,f.memoizedState=null)}var h=gh(o);if(h!==null){h.flags&=-257,vh(h,o,l,s,t),h.mode&1&&yh(s,c,t),t=h,a=c;var v=t.updateQueue;if(v===null){var w=new Set;w.add(a),t.updateQueue=w}else v.add(a);break e}else{if(!(t&1)){yh(s,c,t),Lf();break e}a=Error(O(426))}}else if(he&&l.mode&1){var S=gh(o);if(S!==null){!(S.flags&65536)&&(S.flags|=256),vh(S,o,l,s,t),vf(Hi(a,l));break e}}s=a=Hi(a,l),ke!==4&&(ke=2),Ts===null?Ts=[s]:Ts.push(s),s=o;do{switch(s.tag){case 3:s.flags|=65536,t&=-t,s.lanes|=t;var m=z0(s,a,t);ch(s,m);break e;case 1:l=a;var p=s.type,g=s.stateNode;if(!(s.flags&128)&&(typeof p.getDerivedStateFromError=="function"||g!==null&&typeof g.componentDidCatch=="function"&&(sr===null||!sr.has(g)))){s.flags|=65536,t&=-t,s.lanes|=t;var x=B0(s,l,t);ch(s,x);break e}}s=s.return}while(s!==null)}oy(n)}catch(C){t=C,Se===n&&n!==null&&(Se=n=n.return);continue}break}while(!0)}function iy(){var e=Pl.current;return Pl.current=Nl,e===null?Nl:e}function Lf(){(ke===0||ke===3||ke===2)&&(ke=4),Ne===null||!(Vr&268435455)&&!(ea&268435455)||Bn(Ne,$e)}function Fl(e,t){var n=J;J|=2;var r=iy();(Ne!==e||$e!==t)&&(vn=null,$r(e,t));do try{Sw();break}catch(i){ry(e,i)}while(!0);if(xf(),J=n,Pl.current=r,Se!==null)throw Error(O(261));return Ne=null,$e=0,ke}function Sw(){for(;Se!==null;)sy(Se)}function bw(){for(;Se!==null&&!qv();)sy(Se)}function sy(e){var t=ay(e.alternate,e,yt);e.memoizedProps=e.pendingProps,t===null?oy(e):Se=t,jf.current=null}function oy(e){var t=e;do{var n=t.alternate;if(e=t.return,t.flags&32768){if(n=mw(n,t),n!==null){n.flags&=32767,Se=n;return}if(e!==null)e.flags|=32768,e.subtreeFlags=0,e.deletions=null;else{ke=6,Se=null;return}}else if(n=pw(n,t,yt),n!==null){Se=n;return}if(t=t.sibling,t!==null){Se=t;return}Se=t=e}while(t!==null);ke===0&&(ke=5)}function br(e,t,n){var r=re,i=jt.transition;try{jt.transition=null,re=1,Ew(e,t,n,r)}finally{jt.transition=i,re=r}return null}function Ew(e,t,n,r){do _i();while(Zn!==null);if(J&6)throw Error(O(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(O(177));e.callbackNode=null,e.callbackPriority=0;var s=n.lanes|n.childLanes;if(r1(e,s),e===Ne&&(Se=Ne=null,$e=0),!(n.subtreeFlags&2064)&&!(n.flags&2064)||Do||(Do=!0,uy(ml,function(){return _i(),null})),s=(n.flags&15990)!==0,n.subtreeFlags&15990||s){s=jt.transition,jt.transition=null;var o=re;re=1;var l=J;J|=4,jf.current=null,gw(e,n),ey(n,e),V1(Hu),gl=!!Vu,Hu=Vu=null,e.current=n,vw(n),Kv(),J=l,re=o,jt.transition=s}else e.current=n;if(Do&&(Do=!1,Zn=e,jl=i),s=e.pendingLanes,s===0&&(sr=null),Xv(n.stateNode),ut(e,xe()),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(Al)throw Al=!1,e=cc,cc=null,e;return jl&1&&e.tag!==0&&_i(),s=e.pendingLanes,s&1?e===fc?Os++:(Os=0,fc=e):Os=0,mr(),null}function _i(){if(Zn!==null){var e=zm(jl),t=jt.transition,n=re;try{if(jt.transition=null,re=16>e?16:e,Zn===null)var r=!1;else{if(e=Zn,Zn=null,jl=0,J&6)throw Error(O(331));var i=J;for(J|=4,F=e.current;F!==null;){var s=F,o=s.child;if(F.flags&16){var l=s.deletions;if(l!==null){for(var a=0;a<l.length;a++){var c=l[a];for(F=c;F!==null;){var f=F;switch(f.tag){case 0:case 11:case 15:Cs(8,f,s)}var u=f.child;if(u!==null)u.return=f,F=u;else for(;F!==null;){f=F;var d=f.sibling,h=f.return;if(X0(f),f===c){F=null;break}if(d!==null){d.return=h,F=d;break}F=h}}}var v=s.alternate;if(v!==null){var w=v.child;if(w!==null){v.child=null;do{var S=w.sibling;w.sibling=null,w=S}while(w!==null)}}F=s}}if(s.subtreeFlags&2064&&o!==null)o.return=s,F=o;else e:for(;F!==null;){if(s=F,s.flags&2048)switch(s.tag){case 0:case 11:case 15:Cs(9,s,s.return)}var m=s.sibling;if(m!==null){m.return=s.return,F=m;break e}F=s.return}}var p=e.current;for(F=p;F!==null;){o=F;var g=o.child;if(o.subtreeFlags&2064&&g!==null)g.return=o,F=g;else e:for(o=p;F!==null;){if(l=F,l.flags&2048)try{switch(l.tag){case 0:case 11:case 15:Jl(9,l)}}catch(C){ve(l,l.return,C)}if(l===o){F=null;break e}var x=l.sibling;if(x!==null){x.return=l.return,F=x;break e}F=l.return}}if(J=i,mr(),an&&typeof an.onPostCommitFiberRoot=="function")try{an.onPostCommitFiberRoot(Wl,e)}catch{}r=!0}return r}finally{re=n,jt.transition=t}}return!1}function Ph(e,t,n){t=Hi(n,t),t=z0(e,t,1),e=ir(e,t,1),t=Ge(),e!==null&&(so(e,1,t),ut(e,t))}function ve(e,t,n){if(e.tag===3)Ph(e,e,n);else for(;t!==null;){if(t.tag===3){Ph(t,e,n);break}else if(t.tag===1){var r=t.stateNode;if(typeof t.type.getDerivedStateFromError=="function"||typeof r.componentDidCatch=="function"&&(sr===null||!sr.has(r))){e=Hi(n,e),e=B0(t,e,1),t=ir(t,e,1),e=Ge(),t!==null&&(so(t,1,e),ut(t,e));break}}t=t.return}}function _w(e,t,n){var r=e.pingCache;r!==null&&r.delete(t),t=Ge(),e.pingedLanes|=e.suspendedLanes&n,Ne===e&&($e&n)===n&&(ke===4||ke===3&&($e&130023424)===$e&&500>xe()-$f?$r(e,0):Ff|=n),ut(e,t)}function ly(e,t){t===0&&(e.mode&1?(t=To,To<<=1,!(To&130023424)&&(To=4194304)):t=1);var n=Ge();e=On(e,t),e!==null&&(so(e,t,n),ut(e,n))}function kw(e){var t=e.memoizedState,n=0;t!==null&&(n=t.retryLane),ly(e,n)}function Cw(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(O(314))}r!==null&&r.delete(t),ly(e,n)}var ay;ay=function(e,t,n){if(e!==null)if(e.memoizedProps!==t.pendingProps||lt.current)ot=!0;else{if(!(e.lanes&n)&&!(t.flags&128))return ot=!1,hw(e,t,n);ot=!!(e.flags&131072)}else ot=!1,he&&t.flags&1048576&&d0(t,_l,t.index);switch(t.lanes=0,t.tag){case 2:var r=t.type;el(e,t),e=t.pendingProps;var i=zi(t,Ue.current);Ei(t,n),i=Of(null,t,r,e,i,n);var s=Rf();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,at(r)?(s=!0,bl(t)):s=!1,t.memoizedState=i.state!==null&&i.state!==void 0?i.state:null,Ef(t),i.updater=Zl,t.stateNode=i,i._reactInternals=t,Ju(t,r,e,n),t=nc(null,t,r,!0,s,n)):(t.tag=0,he&&s&&yf(t),Ye(null,t,i,n),t=t.child),t;case 16:r=t.elementType;e:{switch(el(e,t),e=t.pendingProps,i=r._init,r=i(r._payload),t.type=r,i=t.tag=Ow(r),e=zt(r,e),i){case 0:t=tc(null,t,r,e,n);break e;case 1:t=Sh(null,t,r,e,n);break e;case 11:t=wh(null,t,r,e,n);break e;case 14:t=xh(null,t,r,zt(r.type,e),n);break e}throw Error(O(306,r,""))}return t;case 0:return r=t.type,i=t.pendingProps,i=t.elementType===r?i:zt(r,i),tc(e,t,r,i,n);case 1:return r=t.type,i=t.pendingProps,i=t.elementType===r?i:zt(r,i),Sh(e,t,r,i,n);case 3:e:{if(W0(t),e===null)throw Error(O(387));r=t.pendingProps,s=t.memoizedState,i=s.element,v0(e,t),Tl(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=Hi(Error(O(423)),t),t=bh(e,t,r,n,i);break e}else if(r!==i){i=Hi(Error(O(424)),t),t=bh(e,t,r,n,i);break e}else for(gt=rr(t.stateNode.containerInfo.firstChild),xt=t,he=!0,Ht=null,n=y0(t,null,r,n),t.child=n;n;)n.flags=n.flags&-3|4096,n=n.sibling;else{if(Bi(),r===i){t=Rn(e,t,n);break e}Ye(e,t,r,n)}t=t.child}return t;case 5:return w0(t),e===null&&Gu(t),r=t.type,i=t.pendingProps,s=e!==null?e.memoizedProps:null,o=i.children,Wu(r,i)?o=null:s!==null&&Wu(r,s)&&(t.flags|=32),H0(e,t),Ye(e,t,o,n),t.child;case 6:return e===null&&Gu(t),null;case 13:return Q0(e,t,n);case 4:return _f(t,t.stateNode.containerInfo),r=t.pendingProps,e===null?t.child=Ui(t,null,r,n):Ye(e,t,r,n),t.child;case 11:return r=t.type,i=t.pendingProps,i=t.elementType===r?i:zt(r,i),wh(e,t,r,i,n);case 7:return Ye(e,t,t.pendingProps,n),t.child;case 8:return Ye(e,t,t.pendingProps.children,n),t.child;case 12:return Ye(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,ae(kl,r._currentValue),r._currentValue=o,s!==null)if(Gt(s.value,o)){if(s.children===i.children&&!lt.current){t=Rn(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=_n(-1,n&-n),a.tag=2;var c=s.updateQueue;if(c!==null){c=c.shared;var f=c.pending;f===null?a.next=a:(a.next=f.next,f.next=a),c.pending=a}}s.lanes|=n,a=s.alternate,a!==null&&(a.lanes|=n),Xu(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(O(341));o.lanes|=n,l=o.alternate,l!==null&&(l.lanes|=n),Xu(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}Ye(e,t,i.children,n),t=t.child}return t;case 9:return i=t.type,r=t.pendingProps.children,Ei(t,n),i=Ft(i),r=r(i),t.flags|=1,Ye(e,t,r,n),t.child;case 14:return r=t.type,i=zt(r,t.pendingProps),i=zt(r.type,i),xh(e,t,r,i,n);case 15:return U0(e,t,t.type,t.pendingProps,n);case 17:return r=t.type,i=t.pendingProps,i=t.elementType===r?i:zt(r,i),el(e,t),t.tag=1,at(r)?(e=!0,bl(t)):e=!1,Ei(t,n),M0(t,r,i),Ju(t,r,i,n),nc(null,t,r,!0,e,n);case 19:return q0(e,t,n);case 22:return V0(e,t,n)}throw Error(O(156,t.tag))};function uy(e,t){return Im(e,t)}function Tw(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 At(e,t,n,r){return new Tw(e,t,n,r)}function Mf(e){return e=e.prototype,!(!e||!e.isReactComponent)}function Ow(e){if(typeof e=="function")return Mf(e)?1:0;if(e!=null){if(e=e.$$typeof,e===rf)return 11;if(e===sf)return 14}return 2}function lr(e,t){var n=e.alternate;return n===null?(n=At(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 rl(e,t,n,r,i,s){var o=2;if(r=e,typeof e=="function")Mf(e)&&(o=1);else if(typeof e=="string")o=5;else e:switch(e){case li:return Ir(n.children,i,s,t);case nf:o=8,i|=8;break;case Eu:return e=At(12,n,t,i|2),e.elementType=Eu,e.lanes=s,e;case _u:return e=At(13,n,t,i),e.elementType=_u,e.lanes=s,e;case ku:return e=At(19,n,t,i),e.elementType=ku,e.lanes=s,e;case wm:return ta(n,i,s,t);default:if(typeof e=="object"&&e!==null)switch(e.$$typeof){case gm:o=10;break e;case vm:o=9;break e;case rf:o=11;break e;case sf:o=14;break e;case Ln:o=16,r=null;break e}throw Error(O(130,e==null?e:typeof e,""))}return t=At(o,n,t,i),t.elementType=e,t.type=r,t.lanes=s,t}function Ir(e,t,n,r){return e=At(7,e,r,t),e.lanes=n,e}function ta(e,t,n,r){return e=At(22,e,r,t),e.elementType=wm,e.lanes=n,e.stateNode={isHidden:!1},e}function ou(e,t,n){return e=At(6,e,null,t),e.lanes=n,e}function lu(e,t,n){return t=At(4,e.children!==null?e.children:[],e.key,t),t.lanes=n,t.stateNode={containerInfo:e.containerInfo,pendingChildren:null,implementation:e.implementation},t}function Rw(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=Ba(0),this.expirationTimes=Ba(-1),this.entangledLanes=this.finishedLanes=this.mutableReadLanes=this.expiredLanes=this.pingedLanes=this.suspendedLanes=this.pendingLanes=0,this.entanglements=Ba(0),this.identifierPrefix=r,this.onRecoverableError=i,this.mutableSourceEagerHydrationData=null}function zf(e,t,n,r,i,s,o,l,a){return e=new Rw(e,t,n,l,a),t===1?(t=1,s===!0&&(t|=8)):t=0,s=At(3,null,null,t),e.current=s,s.stateNode=e,s.memoizedState={element:r,isDehydrated:n,cache:null,transitions:null,pendingSuspenseBoundaries:null},Ef(s),e}function Nw(e,t,n){var r=3<arguments.length&&arguments[3]!==void 0?arguments[3]:null;return{$$typeof:oi,key:r==null?null:""+r,children:e,containerInfo:t,implementation:n}}function cy(e){if(!e)return fr;e=e._reactInternals;e:{if(Yr(e)!==e||e.tag!==1)throw Error(O(170));var t=e;do{switch(t.tag){case 3:t=t.stateNode.context;break e;case 1:if(at(t.type)){t=t.stateNode.__reactInternalMemoizedMergedChildContext;break e}}t=t.return}while(t!==null);throw Error(O(171))}if(e.tag===1){var n=e.type;if(at(n))return c0(e,n,t)}return t}function fy(e,t,n,r,i,s,o,l,a){return e=zf(n,r,!0,e,i,s,o,l,a),e.context=cy(null),n=e.current,r=Ge(),i=or(n),s=_n(r,i),s.callback=t??null,ir(n,s,i),e.current.lanes=i,so(e,i,r),ut(e,r),e}function na(e,t,n,r){var i=t.current,s=Ge(),o=or(i);return n=cy(n),t.context===null?t.context=n:t.pendingContext=n,t=_n(s,o),t.payload={element:e},r=r===void 0?null:r,r!==null&&(t.callback=r),e=ir(i,t,o),e!==null&&(Yt(e,i,o,s),Xo(e,i,o)),o}function $l(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 Ah(e,t){if(e=e.memoizedState,e!==null&&e.dehydrated!==null){var n=e.retryLane;e.retryLane=n!==0&&n<t?n:t}}function Bf(e,t){Ah(e,t),(e=e.alternate)&&Ah(e,t)}function Pw(){return null}var dy=typeof reportError=="function"?reportError:function(e){console.error(e)};function Uf(e){this._internalRoot=e}ra.prototype.render=Uf.prototype.render=function(e){var t=this._internalRoot;if(t===null)throw Error(O(409));na(e,t,null,null)};ra.prototype.unmount=Uf.prototype.unmount=function(){var e=this._internalRoot;if(e!==null){this._internalRoot=null;var t=e.containerInfo;Hr(function(){na(null,e,null,null)}),t[Tn]=null}};function ra(e){this._internalRoot=e}ra.prototype.unstable_scheduleHydration=function(e){if(e){var t=Vm();e={blockedOn:null,target:e,priority:t};for(var n=0;n<zn.length&&t!==0&&t<zn[n].priority;n++);zn.splice(n,0,e),n===0&&Wm(e)}};function Vf(e){return!(!e||e.nodeType!==1&&e.nodeType!==9&&e.nodeType!==11)}function ia(e){return!(!e||e.nodeType!==1&&e.nodeType!==9&&e.nodeType!==11&&(e.nodeType!==8||e.nodeValue!==" react-mount-point-unstable "))}function jh(){}function Aw(e,t,n,r,i){if(i){if(typeof r=="function"){var s=r;r=function(){var c=$l(o);s.call(c)}}var o=fy(t,r,e,0,null,!1,!1,"",jh);return e._reactRootContainer=o,e[Tn]=o.current,Ms(e.nodeType===8?e.parentNode:e),Hr(),o}for(;i=e.lastChild;)e.removeChild(i);if(typeof r=="function"){var l=r;r=function(){var c=$l(a);l.call(c)}}var a=zf(e,0,!1,null,null,!1,!1,"",jh);return e._reactRootContainer=a,e[Tn]=a.current,Ms(e.nodeType===8?e.parentNode:e),Hr(function(){na(t,a,n,r)}),a}function sa(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=$l(o);l.call(a)}}na(t,o,e,i)}else o=Aw(n,t,e,i,r);return $l(o)}Bm=function(e){switch(e.tag){case 3:var t=e.stateNode;if(t.current.memoizedState.isDehydrated){var n=ys(t.pendingLanes);n!==0&&(af(t,n|1),ut(t,xe()),!(J&6)&&(Wi=xe()+500,mr()))}break;case 13:Hr(function(){var r=On(e,1);if(r!==null){var i=Ge();Yt(r,e,1,i)}}),Bf(e,1)}};uf=function(e){if(e.tag===13){var t=On(e,134217728);if(t!==null){var n=Ge();Yt(t,e,134217728,n)}Bf(e,134217728)}};Um=function(e){if(e.tag===13){var t=or(e),n=On(e,t);if(n!==null){var r=Ge();Yt(n,e,t,r)}Bf(e,t)}};Vm=function(){return re};Hm=function(e,t){var n=re;try{return re=e,t()}finally{re=n}};$u=function(e,t,n){switch(t){case"input":if(Ou(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=Yl(r);if(!i)throw Error(O(90));Sm(r),Ou(r,i)}}}break;case"textarea":Em(e,n);break;case"select":t=n.value,t!=null&&wi(e,!!n.multiple,t,!1)}};Nm=If;Pm=Hr;var jw={usingClientEntryPoint:!1,Events:[lo,fi,Yl,Om,Rm,If]},fs={findFiberByHostInstance:_r,bundleType:0,version:"18.3.1",rendererPackageName:"react-dom"},Fw={bundleType:fs.bundleType,version:fs.version,rendererPackageName:fs.rendererPackageName,rendererConfig:fs.rendererConfig,overrideHookState:null,overrideHookStateDeletePath:null,overrideHookStateRenamePath:null,overrideProps:null,overridePropsDeletePath:null,overridePropsRenamePath:null,setErrorHandler:null,setSuspenseHandler:null,scheduleUpdate:null,currentDispatcherRef:Nn.ReactCurrentDispatcher,findHostInstanceByFiber:function(e){return e=Fm(e),e===null?null:e.stateNode},findFiberByHostInstance:fs.findFiberByHostInstance||Pw,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 Lo=__REACT_DEVTOOLS_GLOBAL_HOOK__;if(!Lo.isDisabled&&Lo.supportsFiber)try{Wl=Lo.inject(Fw),an=Lo}catch{}}bt.__SECRET_INTERNALS_DO_NOT_USE_OR_YOU_WILL_BE_FIRED=jw;bt.createPortal=function(e,t){var n=2<arguments.length&&arguments[2]!==void 0?arguments[2]:null;if(!Vf(t))throw Error(O(200));return Nw(e,t,null,n)};bt.createRoot=function(e,t){if(!Vf(e))throw Error(O(299));var n=!1,r="",i=dy;return t!=null&&(t.unstable_strictMode===!0&&(n=!0),t.identifierPrefix!==void 0&&(r=t.identifierPrefix),t.onRecoverableError!==void 0&&(i=t.onRecoverableError)),t=zf(e,1,!1,null,null,n,!1,r,i),e[Tn]=t.current,Ms(e.nodeType===8?e.parentNode:e),new Uf(t)};bt.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(O(188)):(e=Object.keys(e).join(","),Error(O(268,e)));return e=Fm(t),e=e===null?null:e.stateNode,e};bt.flushSync=function(e){return Hr(e)};bt.hydrate=function(e,t,n){if(!ia(t))throw Error(O(200));return sa(null,e,t,!0,n)};bt.hydrateRoot=function(e,t,n){if(!Vf(e))throw Error(O(405));var r=n!=null&&n.hydratedSources||null,i=!1,s="",o=dy;if(n!=null&&(n.unstable_strictMode===!0&&(i=!0),n.identifierPrefix!==void 0&&(s=n.identifierPrefix),n.onRecoverableError!==void 0&&(o=n.onRecoverableError)),t=fy(t,null,e,1,n??null,i,!1,s,o),e[Tn]=t.current,Ms(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 ra(t)};bt.render=function(e,t,n){if(!ia(t))throw Error(O(200));return sa(null,e,t,!1,n)};bt.unmountComponentAtNode=function(e){if(!ia(e))throw Error(O(40));return e._reactRootContainer?(Hr(function(){sa(null,null,e,!1,function(){e._reactRootContainer=null,e[Tn]=null})}),!0):!1};bt.unstable_batchedUpdates=If;bt.unstable_renderSubtreeIntoContainer=function(e,t,n,r){if(!ia(n))throw Error(O(200));if(e==null||e._reactInternals===void 0)throw Error(O(38));return sa(e,t,n,!1,r)};bt.version="18.3.1-next-f1338f8080-20240426";function hy(){if(!(typeof __REACT_DEVTOOLS_GLOBAL_HOOK__>"u"||typeof __REACT_DEVTOOLS_GLOBAL_HOOK__.checkDCE!="function"))try{__REACT_DEVTOOLS_GLOBAL_HOOK__.checkDCE(hy)}catch(e){console.error(e)}}hy(),hm.exports=bt;var py=hm.exports;const $w=Ki(py);var my,Fh=py;my=Fh.createRoot,Fh.hydrateRoot;const Iw="@alfatech/livechat",Dw="v2025.04.08.1",Lw="module",Mw="https://api-live.alfatek.dev",zw="wss://api-live.alfatek.dev",Bw=["dist","README.md"],Uw="dist/widget.js",Vw={dev:"vite",build:"tsc -b && vite build",lint:"biome lint --write",prepare:"husky",format:"biome format --write && yarn lint"},Hw={"@tanstack/react-query":"^5.59.20",classnames:"^2.5.1",dayjs:"^1.11.13",formik:"^2.4.6",react:"^18.3.1","react-dom":"^18.3.1","react-router-dom":"^6.26.2","socket.io-client":"^4.8.1",sonner:"^2.0.1",yup:"^1.4.0",zustand:"^4.5.5"},Ww={"@biomejs/biome":"^1.8.3","@types/node":"^22.5.4","@types/react":"^18.3.3","@types/react-dom":"^18.3.0","@vitejs/plugin-react-swc":"^3.5.0",globals:"^15.9.0",husky:"^9.1.5",tailwindcss:"^3.4.10",typescript:"^5.5.3",vite:"^5.4.1"},yy={name:Iw,private:!1,version:Dw,type:Lw,apiURL:Mw,wsURL:zw,files:Bw,main:Uw,scripts:Vw,dependencies:Hw,devDependencies:Ww,"lint-staged":{"./**/*.{js,ts,tsx,json}":["npm run format"]}},Qw=yy.apiURL,qw=yy.wsURL,Kw=e=>[{limit:Number.parseInt(e.headers.get("X-Ratelimit-Limit")||"0"),remaining:Number.parseInt(e.headers.get("X-Ratelimit-Remaining")||"0"),reset:Number.parseInt(e.headers.get("X-Ratelimit-Reset")||"0"),retryAfter:Number.parseInt(e.headers.get("Retry-After")||"0")},429],Yw=(e,t)=>[{message:"message"in t?t.message:"Not Found"},404],Gw={429:Kw,404:Yw};async function oa(e,t={}){const n={};!(t.body instanceof FormData)&&t.body&&(n["Content-Type"]="application/json");const r=await fetch(`${Qw}/${e}`,{...t,credentials:"include",headers:{...t.headers,...n}}).catch(s=>(console.log("err::",s),new Response(null,{status:500})));if(!r.ok){let s={};try{return s=await r.json(),[s,r.status]}catch{console.log("response: ",r)}const o=Gw[r.status];return o?o(r,s):[{},r.status]}const i=r.headers.get("Content-Type");return i&&i.includes("application/json")?[await r.json(),r.status]:[await r.text(),r.status]}const gy=e=>[200,201,204].includes(e);var Zi=class{constructor(){this.listeners=new Set,this.subscribe=this.subscribe.bind(this)}subscribe(e){return this.listeners.add(e),this.onSubscribe(),()=>{this.listeners.delete(e),this.onUnsubscribe()}}hasListeners(){return this.listeners.size>0}onSubscribe(){}onUnsubscribe(){}},Wr=typeof window>"u"||"Deno"in globalThis;function Ot(){}function Xw(e,t){return typeof e=="function"?e(t):e}function pc(e){return typeof e=="number"&&e>=0&&e!==1/0}function vy(e,t){return Math.max(e+(t||0)-Date.now(),0)}function ki(e,t){return typeof e=="function"?e(t):e}function Wt(e,t){return typeof e=="function"?e(t):e}function $h(e,t){const{type:n="all",exact:r,fetchStatus:i,predicate:s,queryKey:o,stale:l}=e;if(o){if(r){if(t.queryHash!==Hf(o,t.options))return!1}else if(!Ks(t.queryKey,o))return!1}if(n!=="all"){const a=t.isActive();if(n==="active"&&!a||n==="inactive"&&a)return!1}return!(typeof l=="boolean"&&t.isStale()!==l||i&&i!==t.state.fetchStatus||s&&!s(t))}function Ih(e,t){const{exact:n,status:r,predicate:i,mutationKey:s}=e;if(s){if(!t.options.mutationKey)return!1;if(n){if(Qr(t.options.mutationKey)!==Qr(s))return!1}else if(!Ks(t.options.mutationKey,s))return!1}return!(r&&t.state.status!==r||i&&!i(t))}function Hf(e,t){return((t==null?void 0:t.queryKeyHashFn)||Qr)(e)}function Qr(e){return JSON.stringify(e,(t,n)=>mc(n)?Object.keys(n).sort().reduce((r,i)=>(r[i]=n[i],r),{}):n)}function Ks(e,t){return e===t?!0:typeof e!=typeof t?!1:e&&t&&typeof e=="object"&&typeof t=="object"?!Object.keys(t).some(n=>!Ks(e[n],t[n])):!1}function wy(e,t){if(e===t)return e;const n=Dh(e)&&Dh(t);if(n||mc(e)&&mc(t)){const r=n?e:Object.keys(e),i=r.length,s=n?t:Object.keys(t),o=s.length,l=n?[]:{};let a=0;for(let c=0;c<o;c++){const f=n?c:s[c];(!n&&r.includes(f)||n)&&e[f]===void 0&&t[f]===void 0?(l[f]=void 0,a++):(l[f]=wy(e[f],t[f]),l[f]===e[f]&&e[f]!==void 0&&a++)}return i===o&&a===i?e:l}return t}function Il(e,t){if(!t||Object.keys(e).length!==Object.keys(t).length)return!1;for(const n in e)if(e[n]!==t[n])return!1;return!0}function Dh(e){return Array.isArray(e)&&e.length===Object.keys(e).length}function mc(e){if(!Lh(e))return!1;const t=e.constructor;if(t===void 0)return!0;const n=t.prototype;return!(!Lh(n)||!n.hasOwnProperty("isPrototypeOf")||Object.getPrototypeOf(e)!==Object.prototype)}function Lh(e){return Object.prototype.toString.call(e)==="[object Object]"}function Zw(e){return new Promise(t=>{setTimeout(t,e)})}function yc(e,t,n){return typeof n.structuralSharing=="function"?n.structuralSharing(e,t):n.structuralSharing!==!1?wy(e,t):t}function Jw(e,t,n=0){const r=[...e,t];return n&&r.length>n?r.slice(1):r}function ex(e,t,n=0){const r=[t,...e];return n&&r.length>n?r.slice(0,-1):r}var Wf=Symbol();function xy(e,t){return!e.queryFn&&(t!=null&&t.initialPromise)?()=>t.initialPromise:!e.queryFn||e.queryFn===Wf?()=>Promise.reject(new Error(`Missing queryFn: '${e.queryHash}'`)):e.queryFn}var Or,Un,Ci,Qp,tx=(Qp=class extends Zi{constructor(){super();U(this,Or);U(this,Un);U(this,Ci);j(this,Ci,t=>{if(!Wr&&window.addEventListener){const n=()=>t();return window.addEventListener("visibilitychange",n,!1),()=>{window.removeEventListener("visibilitychange",n)}}})}onSubscribe(){y(this,Un)||this.setEventListener(y(this,Ci))}onUnsubscribe(){var t;this.hasListeners()||((t=y(this,Un))==null||t.call(this),j(this,Un,void 0))}setEventListener(t){var n;j(this,Ci,t),(n=y(this,Un))==null||n.call(this),j(this,Un,t(r=>{typeof r=="boolean"?this.setFocused(r):this.onFocus()}))}setFocused(t){y(this,Or)!==t&&(j(this,Or,t),this.onFocus())}onFocus(){const t=this.isFocused();this.listeners.forEach(n=>{n(t)})}isFocused(){var t;return typeof y(this,Or)=="boolean"?y(this,Or):((t=globalThis.document)==null?void 0:t.visibilityState)!=="hidden"}},Or=new WeakMap,Un=new WeakMap,Ci=new WeakMap,Qp),Qf=new tx,Ti,Vn,Oi,qp,nx=(qp=class extends Zi{constructor(){super();U(this,Ti,!0);U(this,Vn);U(this,Oi);j(this,Oi,t=>{if(!Wr&&window.addEventListener){const n=()=>t(!0),r=()=>t(!1);return window.addEventListener("online",n,!1),window.addEventListener("offline",r,!1),()=>{window.removeEventListener("online",n),window.removeEventListener("offline",r)}}})}onSubscribe(){y(this,Vn)||this.setEventListener(y(this,Oi))}onUnsubscribe(){var t;this.hasListeners()||((t=y(this,Vn))==null||t.call(this),j(this,Vn,void 0))}setEventListener(t){var n;j(this,Oi,t),(n=y(this,Vn))==null||n.call(this),j(this,Vn,t(this.setOnline.bind(this)))}setOnline(t){y(this,Ti)!==t&&(j(this,Ti,t),this.listeners.forEach(r=>{r(t)}))}isOnline(){return y(this,Ti)}},Ti=new WeakMap,Vn=new WeakMap,Oi=new WeakMap,qp),Dl=new nx;function gc(){let e,t;const n=new Promise((i,s)=>{e=i,t=s});n.status="pending",n.catch(()=>{});function r(i){Object.assign(n,i),delete n.resolve,delete n.reject}return n.resolve=i=>{r({status:"fulfilled",value:i}),e(i)},n.reject=i=>{r({status:"rejected",reason:i}),t(i)},n}function rx(e){return Math.min(1e3*2**e,3e4)}function Sy(e){return(e??"online")==="online"?Dl.isOnline():!0}var by=class extends Error{constructor(e){super("CancelledError"),this.revert=e==null?void 0:e.revert,this.silent=e==null?void 0:e.silent}};function au(e){return e instanceof by}function Ey(e){let t=!1,n=0,r=!1,i;const s=gc(),o=w=>{var S;r||(d(new by(w)),(S=e.abort)==null||S.call(e))},l=()=>{t=!0},a=()=>{t=!1},c=()=>Qf.isFocused()&&(e.networkMode==="always"||Dl.isOnline())&&e.canRun(),f=()=>Sy(e.networkMode)&&e.canRun(),u=w=>{var S;r||(r=!0,(S=e.onSuccess)==null||S.call(e,w),i==null||i(),s.resolve(w))},d=w=>{var S;r||(r=!0,(S=e.onError)==null||S.call(e,w),i==null||i(),s.reject(w))},h=()=>new Promise(w=>{var S;i=m=>{(r||c())&&w(m)},(S=e.onPause)==null||S.call(e)}).then(()=>{var w;i=void 0,r||(w=e.onContinue)==null||w.call(e)}),v=()=>{if(r)return;let w;const S=n===0?e.initialPromise:void 0;try{w=S??e.fn()}catch(m){w=Promise.reject(m)}Promise.resolve(w).then(u).catch(m=>{var T;if(r)return;const p=e.retry??(Wr?0:3),g=e.retryDelay??rx,x=typeof g=="function"?g(n,m):g,C=p===!0||typeof p=="number"&&n<p||typeof p=="function"&&p(n,m);if(t||!C){d(m);return}n++,(T=e.onFail)==null||T.call(e,n,m),Zw(x).then(()=>c()?void 0:h()).then(()=>{t?d(m):v()})})};return{promise:s,cancel:o,continue:()=>(i==null||i(),s),cancelRetry:l,continueRetry:a,canStart:f,start:()=>(f()?v():h().then(v),s)}}function ix(){let e=[],t=0,n=l=>{l()},r=l=>{l()},i=l=>setTimeout(l,0);const s=l=>{t?e.push(l):i(()=>{n(l)})},o=()=>{const l=e;e=[],l.length&&i(()=>{r(()=>{l.forEach(a=>{n(a)})})})};return{batch:l=>{let a;t++;try{a=l()}finally{t--,t||o()}return a},batchCalls:l=>(...a)=>{s(()=>{l(...a)})},schedule:s,setNotifyFunction:l=>{n=l},setBatchNotifyFunction:l=>{r=l},setScheduler:l=>{i=l}}}var _e=ix(),Rr,Kp,_y=(Kp=class{constructor(){U(this,Rr)}destroy(){this.clearGcTimeout()}scheduleGc(){this.clearGcTimeout(),pc(this.gcTime)&&j(this,Rr,setTimeout(()=>{this.optionalRemove()},this.gcTime))}updateGcTime(e){this.gcTime=Math.max(this.gcTime||0,e??(Wr?1/0:5*60*1e3))}clearGcTimeout(){y(this,Rr)&&(clearTimeout(y(this,Rr)),j(this,Rr,void 0))}},Rr=new WeakMap,Kp),Ri,Ni,Tt,ze,eo,Nr,Bt,gn,Yp,sx=(Yp=class extends _y{constructor(t){super();U(this,Bt);U(this,Ri);U(this,Ni);U(this,Tt);U(this,ze);U(this,eo);U(this,Nr);j(this,Nr,!1),j(this,eo,t.defaultOptions),this.setOptions(t.options),this.observers=[],j(this,Tt,t.cache),this.queryKey=t.queryKey,this.queryHash=t.queryHash,j(this,Ri,ox(this.options)),this.state=t.state??y(this,Ri),this.scheduleGc()}get meta(){return this.options.meta}get promise(){var t;return(t=y(this,ze))==null?void 0:t.promise}setOptions(t){this.options={...y(this,eo),...t},this.updateGcTime(this.options.gcTime)}optionalRemove(){!this.observers.length&&this.state.fetchStatus==="idle"&&y(this,Tt).remove(this)}setData(t,n){const r=yc(this.state.data,t,this.options);return q(this,Bt,gn).call(this,{data:r,type:"success",dataUpdatedAt:n==null?void 0:n.updatedAt,manual:n==null?void 0:n.manual}),r}setState(t,n){q(this,Bt,gn).call(this,{type:"setState",state:t,setStateOptions:n})}cancel(t){var r,i;const n=(r=y(this,ze))==null?void 0:r.promise;return(i=y(this,ze))==null||i.cancel(t),n?n.then(Ot).catch(Ot):Promise.resolve()}destroy(){super.destroy(),this.cancel({silent:!0})}reset(){this.destroy(),this.setState(y(this,Ri))}isActive(){return this.observers.some(t=>Wt(t.options.enabled,this)!==!1)}isDisabled(){return this.getObserversCount()>0?!this.isActive():this.options.queryFn===Wf||this.state.dataUpdateCount+this.state.errorUpdateCount===0}isStale(){return this.state.isInvalidated?!0:this.getObserversCount()>0?this.observers.some(t=>t.getCurrentResult().isStale):this.state.data===void 0}isStaleByTime(t=0){return this.state.isInvalidated||this.state.data===void 0||!vy(this.state.dataUpdatedAt,t)}onFocus(){var n;const t=this.observers.find(r=>r.shouldFetchOnWindowFocus());t==null||t.refetch({cancelRefetch:!1}),(n=y(this,ze))==null||n.continue()}onOnline(){var n;const t=this.observers.find(r=>r.shouldFetchOnReconnect());t==null||t.refetch({cancelRefetch:!1}),(n=y(this,ze))==null||n.continue()}addObserver(t){this.observers.includes(t)||(this.observers.push(t),this.clearGcTimeout(),y(this,Tt).notify({type:"observerAdded",query:this,observer:t}))}removeObserver(t){this.observers.includes(t)&&(this.observers=this.observers.filter(n=>n!==t),this.observers.length||(y(this,ze)&&(y(this,Nr)?y(this,ze).cancel({revert:!0}):y(this,ze).cancelRetry()),this.scheduleGc()),y(this,Tt).notify({type:"observerRemoved",query:this,observer:t}))}getObserversCount(){return this.observers.length}invalidate(){this.state.isInvalidated||q(this,Bt,gn).call(this,{type:"invalidate"})}fetch(t,n){var a,c,f;if(this.state.fetchStatus!=="idle"){if(this.state.data!==void 0&&(n!=null&&n.cancelRefetch))this.cancel({silent:!0});else if(y(this,ze))return y(this,ze).continueRetry(),y(this,ze).promise}if(t&&this.setOptions(t),!this.options.queryFn){const u=this.observers.find(d=>d.options.queryFn);u&&this.setOptions(u.options)}const r=new AbortController,i=u=>{Object.defineProperty(u,"signal",{enumerable:!0,get:()=>(j(this,Nr,!0),r.signal)})},s=()=>{const u=xy(this.options,n),d={queryKey:this.queryKey,meta:this.meta};return i(d),j(this,Nr,!1),this.options.persister?this.options.persister(u,d,this):u(d)},o={fetchOptions:n,options:this.options,queryKey:this.queryKey,state:this.state,fetchFn:s};i(o),(a=this.options.behavior)==null||a.onFetch(o,this),j(this,Ni,this.state),(this.state.fetchStatus==="idle"||this.state.fetchMeta!==((c=o.fetchOptions)==null?void 0:c.meta))&&q(this,Bt,gn).call(this,{type:"fetch",meta:(f=o.fetchOptions)==null?void 0:f.meta});const l=u=>{var d,h,v,w;au(u)&&u.silent||q(this,Bt,gn).call(this,{type:"error",error:u}),au(u)||((h=(d=y(this,Tt).config).onError)==null||h.call(d,u,this),(w=(v=y(this,Tt).config).onSettled)==null||w.call(v,this.state.data,u,this)),this.scheduleGc()};return j(this,ze,Ey({initialPromise:n==null?void 0:n.initialPromise,fn:o.fetchFn,abort:r.abort.bind(r),onSuccess:u=>{var d,h,v,w;if(u===void 0){l(new Error(`${this.queryHash} data is undefined`));return}try{this.setData(u)}catch(S){l(S);return}(h=(d=y(this,Tt).config).onSuccess)==null||h.call(d,u,this),(w=(v=y(this,Tt).config).onSettled)==null||w.call(v,u,this.state.error,this),this.scheduleGc()},onError:l,onFail:(u,d)=>{q(this,Bt,gn).call(this,{type:"failed",failureCount:u,error:d})},onPause:()=>{q(this,Bt,gn).call(this,{type:"pause"})},onContinue:()=>{q(this,Bt,gn).call(this,{type:"continue"})},retry:o.options.retry,retryDelay:o.options.retryDelay,networkMode:o.options.networkMode,canRun:()=>!0})),y(this,ze).start()}},Ri=new WeakMap,Ni=new WeakMap,Tt=new WeakMap,ze=new WeakMap,eo=new WeakMap,Nr=new WeakMap,Bt=new WeakSet,gn=function(t){const n=r=>{switch(t.type){case"failed":return{...r,fetchFailureCount:t.failureCount,fetchFailureReason:t.error};case"pause":return{...r,fetchStatus:"paused"};case"continue":return{...r,fetchStatus:"fetching"};case"fetch":return{...r,...ky(r.data,this.options),fetchMeta:t.meta??null};case"success":return{...r,data:t.data,dataUpdateCount:r.dataUpdateCount+1,dataUpdatedAt:t.dataUpdatedAt??Date.now(),error:null,isInvalidated:!1,status:"success",...!t.manual&&{fetchStatus:"idle",fetchFailureCount:0,fetchFailureReason:null}};case"error":const i=t.error;return au(i)&&i.revert&&y(this,Ni)?{...y(this,Ni),fetchStatus:"idle"}:{...r,error:i,errorUpdateCount:r.errorUpdateCount+1,errorUpdatedAt:Date.now(),fetchFailureCount:r.fetchFailureCount+1,fetchFailureReason:i,fetchStatus:"idle",status:"error"};case"invalidate":return{...r,isInvalidated:!0};case"setState":return{...r,...t.state}}};this.state=n(this.state),_e.batch(()=>{this.observers.forEach(r=>{r.onQueryUpdate()}),y(this,Tt).notify({query:this,type:"updated",action:t})})},Yp);function ky(e,t){return{fetchFailureCount:0,fetchFailureReason:null,fetchStatus:Sy(t.networkMode)?"fetching":"paused",...e===void 0&&{error:null,status:"pending"}}}function ox(e){const t=typeof e.initialData=="function"?e.initialData():e.initialData,n=t!==void 0,r=n?typeof e.initialDataUpdatedAt=="function"?e.initialDataUpdatedAt():e.initialDataUpdatedAt:0;return{data:t,dataUpdateCount:0,dataUpdatedAt:n?r??Date.now():0,error:null,errorUpdateCount:0,errorUpdatedAt:0,fetchFailureCount:0,fetchFailureReason:null,fetchMeta:null,isInvalidated:!1,status:n?"success":"pending",fetchStatus:"idle"}}var nn,Gp,lx=(Gp=class extends Zi{constructor(t={}){super();U(this,nn);this.config=t,j(this,nn,new Map)}build(t,n,r){const i=n.queryKey,s=n.queryHash??Hf(i,n);let o=this.get(s);return o||(o=new sx({cache:this,queryKey:i,queryHash:s,options:t.defaultQueryOptions(n),state:r,defaultOptions:t.getQueryDefaults(i)}),this.add(o)),o}add(t){y(this,nn).has(t.queryHash)||(y(this,nn).set(t.queryHash,t),this.notify({type:"added",query:t}))}remove(t){const n=y(this,nn).get(t.queryHash);n&&(t.destroy(),n===t&&y(this,nn).delete(t.queryHash),this.notify({type:"removed",query:t}))}clear(){_e.batch(()=>{this.getAll().forEach(t=>{this.remove(t)})})}get(t){return y(this,nn).get(t)}getAll(){return[...y(this,nn).values()]}find(t){const n={exact:!0,...t};return this.getAll().find(r=>$h(n,r))}findAll(t={}){const n=this.getAll();return Object.keys(t).length>0?n.filter(r=>$h(t,r)):n}notify(t){_e.batch(()=>{this.listeners.forEach(n=>{n(t)})})}onFocus(){_e.batch(()=>{this.getAll().forEach(t=>{t.onFocus()})})}onOnline(){_e.batch(()=>{this.getAll().forEach(t=>{t.onOnline()})})}},nn=new WeakMap,Gp),rn,qe,Pr,sn,Dn,Xp,ax=(Xp=class extends _y{constructor(t){super();U(this,sn);U(this,rn);U(this,qe);U(this,Pr);this.mutationId=t.mutationId,j(this,qe,t.mutationCache),j(this,rn,[]),this.state=t.state||Cy(),this.setOptions(t.options),this.scheduleGc()}setOptions(t){this.options=t,this.updateGcTime(this.options.gcTime)}get meta(){return this.options.meta}addObserver(t){y(this,rn).includes(t)||(y(this,rn).push(t),this.clearGcTimeout(),y(this,qe).notify({type:"observerAdded",mutation:this,observer:t}))}removeObserver(t){j(this,rn,y(this,rn).filter(n=>n!==t)),this.scheduleGc(),y(this,qe).notify({type:"observerRemoved",mutation:this,observer:t})}optionalRemove(){y(this,rn).length||(this.state.status==="pending"?this.scheduleGc():y(this,qe).remove(this))}continue(){var t;return((t=y(this,Pr))==null?void 0:t.continue())??this.execute(this.state.variables)}async execute(t){var i,s,o,l,a,c,f,u,d,h,v,w,S,m,p,g,x,C,T,k;j(this,Pr,Ey({fn:()=>this.options.mutationFn?this.options.mutationFn(t):Promise.reject(new Error("No mutationFn found")),onFail:(R,I)=>{q(this,sn,Dn).call(this,{type:"failed",failureCount:R,error:I})},onPause:()=>{q(this,sn,Dn).call(this,{type:"pause"})},onContinue:()=>{q(this,sn,Dn).call(this,{type:"continue"})},retry:this.options.retry??0,retryDelay:this.options.retryDelay,networkMode:this.options.networkMode,canRun:()=>y(this,qe).canRun(this)}));const n=this.state.status==="pending",r=!y(this,Pr).canStart();try{if(!n){q(this,sn,Dn).call(this,{type:"pending",variables:t,isPaused:r}),await((s=(i=y(this,qe).config).onMutate)==null?void 0:s.call(i,t,this));const I=await((l=(o=this.options).onMutate)==null?void 0:l.call(o,t));I!==this.state.context&&q(this,sn,Dn).call(this,{type:"pending",context:I,variables:t,isPaused:r})}const R=await y(this,Pr).start();return await((c=(a=y(this,qe).config).onSuccess)==null?void 0:c.call(a,R,t,this.state.context,this)),await((u=(f=this.options).onSuccess)==null?void 0:u.call(f,R,t,this.state.context)),await((h=(d=y(this,qe).config).onSettled)==null?void 0:h.call(d,R,null,this.state.variables,this.state.context,this)),await((w=(v=this.options).onSettled)==null?void 0:w.call(v,R,null,t,this.state.context)),q(this,sn,Dn).call(this,{type:"success",data:R}),R}catch(R){try{throw await((m=(S=y(this,qe).config).onError)==null?void 0:m.call(S,R,t,this.state.context,this)),await((g=(p=this.options).onError)==null?void 0:g.call(p,R,t,this.state.context)),await((C=(x=y(this,qe).config).onSettled)==null?void 0:C.call(x,void 0,R,this.state.variables,this.state.context,this)),await((k=(T=this.options).onSettled)==null?void 0:k.call(T,void 0,R,t,this.state.context)),R}finally{q(this,sn,Dn).call(this,{type:"error",error:R})}}finally{y(this,qe).runNext(this)}}},rn=new WeakMap,qe=new WeakMap,Pr=new WeakMap,sn=new WeakSet,Dn=function(t){const n=r=>{switch(t.type){case"failed":return{...r,failureCount:t.failureCount,failureReason:t.error};case"pause":return{...r,isPaused:!0};case"continue":return{...r,isPaused:!1};case"pending":return{...r,context:t.context,data:void 0,failureCount:0,failureReason:null,error:null,isPaused:t.isPaused,status:"pending",variables:t.variables,submittedAt:Date.now()};case"success":return{...r,data:t.data,failureCount:0,failureReason:null,error:null,status:"success",isPaused:!1};case"error":return{...r,data:void 0,error:t.error,failureCount:r.failureCount+1,failureReason:t.error,isPaused:!1,status:"error"}}};this.state=n(this.state),_e.batch(()=>{y(this,rn).forEach(r=>{r.onMutationUpdate(t)}),y(this,qe).notify({mutation:this,type:"updated",action:t})})},Xp);function Cy(){return{context:void 0,data:void 0,error:null,failureCount:0,failureReason:null,isPaused:!1,status:"idle",variables:void 0,submittedAt:0}}var mt,to,Zp,ux=(Zp=class extends Zi{constructor(t={}){super();U(this,mt);U(this,to);this.config=t,j(this,mt,new Map),j(this,to,Date.now())}build(t,n,r){const i=new ax({mutationCache:this,mutationId:++So(this,to)._,options:t.defaultMutationOptions(n),state:r});return this.add(i),i}add(t){const n=Mo(t),r=y(this,mt).get(n)??[];r.push(t),y(this,mt).set(n,r),this.notify({type:"added",mutation:t})}remove(t){var r;const n=Mo(t);if(y(this,mt).has(n)){const i=(r=y(this,mt).get(n))==null?void 0:r.filter(s=>s!==t);i&&(i.length===0?y(this,mt).delete(n):y(this,mt).set(n,i))}this.notify({type:"removed",mutation:t})}canRun(t){var r;const n=(r=y(this,mt).get(Mo(t)))==null?void 0:r.find(i=>i.state.status==="pending");return!n||n===t}runNext(t){var r;const n=(r=y(this,mt).get(Mo(t)))==null?void 0:r.find(i=>i!==t&&i.state.isPaused);return(n==null?void 0:n.continue())??Promise.resolve()}clear(){_e.batch(()=>{this.getAll().forEach(t=>{this.remove(t)})})}getAll(){return[...y(this,mt).values()].flat()}find(t){const n={exact:!0,...t};return this.getAll().find(r=>Ih(n,r))}findAll(t={}){return this.getAll().filter(n=>Ih(t,n))}notify(t){_e.batch(()=>{this.listeners.forEach(n=>{n(t)})})}resumePausedMutations(){const t=this.getAll().filter(n=>n.state.isPaused);return _e.batch(()=>Promise.all(t.map(n=>n.continue().catch(Ot))))}},mt=new WeakMap,to=new WeakMap,Zp);function Mo(e){var t;return((t=e.options.scope)==null?void 0:t.id)??String(e.mutationId)}function Mh(e){return{onFetch:(t,n)=>{var f,u,d,h,v;const r=t.options,i=(d=(u=(f=t.fetchOptions)==null?void 0:f.meta)==null?void 0:u.fetchMore)==null?void 0:d.direction,s=((h=t.state.data)==null?void 0:h.pages)||[],o=((v=t.state.data)==null?void 0:v.pageParams)||[];let l={pages:[],pageParams:[]},a=0;const c=async()=>{let w=!1;const S=g=>{Object.defineProperty(g,"signal",{enumerable:!0,get:()=>(t.signal.aborted?w=!0:t.signal.addEventListener("abort",()=>{w=!0}),t.signal)})},m=xy(t.options,t.fetchOptions),p=async(g,x,C)=>{if(w)return Promise.reject();if(x==null&&g.pages.length)return Promise.resolve(g);const T={queryKey:t.queryKey,pageParam:x,direction:C?"backward":"forward",meta:t.options.meta};S(T);const k=await m(T),{maxPages:R}=t.options,I=C?ex:Jw;return{pages:I(g.pages,k,R),pageParams:I(g.pageParams,x,R)}};if(i&&s.length){const g=i==="backward",x=g?cx:zh,C={pages:s,pageParams:o},T=x(r,C);l=await p(C,T,g)}else{const g=e??s.length;do{const x=a===0?o[0]??r.initialPageParam:zh(r,l);if(a>0&&x==null)break;l=await p(l,x),a++}while(a<g)}return l};t.options.persister?t.fetchFn=()=>{var w,S;return(S=(w=t.options).persister)==null?void 0:S.call(w,c,{queryKey:t.queryKey,meta:t.options.meta,signal:t.signal},n)}:t.fetchFn=c}}}function zh(e,{pages:t,pageParams:n}){const r=t.length-1;return t.length>0?e.getNextPageParam(t[r],t,n[r],n):void 0}function cx(e,{pages:t,pageParams:n}){var r;return t.length>0?(r=e.getPreviousPageParam)==null?void 0:r.call(e,t[0],t,n[0],n):void 0}var ge,Hn,Wn,Pi,Ai,Qn,ji,Fi,Jp,fx=(Jp=class{constructor(e={}){U(this,ge);U(this,Hn);U(this,Wn);U(this,Pi);U(this,Ai);U(this,Qn);U(this,ji);U(this,Fi);j(this,ge,e.queryCache||new lx),j(this,Hn,e.mutationCache||new ux),j(this,Wn,e.defaultOptions||{}),j(this,Pi,new Map),j(this,Ai,new Map),j(this,Qn,0)}mount(){So(this,Qn)._++,y(this,Qn)===1&&(j(this,ji,Qf.subscribe(async e=>{e&&(await this.resumePausedMutations(),y(this,ge).onFocus())})),j(this,Fi,Dl.subscribe(async e=>{e&&(await this.resumePausedMutations(),y(this,ge).onOnline())})))}unmount(){var e,t;So(this,Qn)._--,y(this,Qn)===0&&((e=y(this,ji))==null||e.call(this),j(this,ji,void 0),(t=y(this,Fi))==null||t.call(this),j(this,Fi,void 0))}isFetching(e){return y(this,ge).findAll({...e,fetchStatus:"fetching"}).length}isMutating(e){return y(this,Hn).findAll({...e,status:"pending"}).length}getQueryData(e){var n;const t=this.defaultQueryOptions({queryKey:e});return(n=y(this,ge).get(t.queryHash))==null?void 0:n.state.data}ensureQueryData(e){const t=this.getQueryData(e.queryKey);if(t===void 0)return this.fetchQuery(e);{const n=this.defaultQueryOptions(e),r=y(this,ge).build(this,n);return e.revalidateIfStale&&r.isStaleByTime(ki(n.staleTime,r))&&this.prefetchQuery(n),Promise.resolve(t)}}getQueriesData(e){return y(this,ge).findAll(e).map(({queryKey:t,state:n})=>{const r=n.data;return[t,r]})}setQueryData(e,t,n){const r=this.defaultQueryOptions({queryKey:e}),i=y(this,ge).get(r.queryHash),s=i==null?void 0:i.state.data,o=Xw(t,s);if(o!==void 0)return y(this,ge).build(this,r).setData(o,{...n,manual:!0})}setQueriesData(e,t,n){return _e.batch(()=>y(this,ge).findAll(e).map(({queryKey:r})=>[r,this.setQueryData(r,t,n)]))}getQueryState(e){var n;const t=this.defaultQueryOptions({queryKey:e});return(n=y(this,ge).get(t.queryHash))==null?void 0:n.state}removeQueries(e){const t=y(this,ge);_e.batch(()=>{t.findAll(e).forEach(n=>{t.remove(n)})})}resetQueries(e,t){const n=y(this,ge),r={type:"active",...e};return _e.batch(()=>(n.findAll(e).forEach(i=>{i.reset()}),this.refetchQueries(r,t)))}cancelQueries(e,t={}){const n={revert:!0,...t},r=_e.batch(()=>y(this,ge).findAll(e).map(i=>i.cancel(n)));return Promise.all(r).then(Ot).catch(Ot)}invalidateQueries(e,t={}){return _e.batch(()=>{if(y(this,ge).findAll(e).forEach(r=>{r.invalidate()}),(e==null?void 0:e.refetchType)==="none")return Promise.resolve();const n={...e,type:(e==null?void 0:e.refetchType)??(e==null?void 0:e.type)??"active"};return this.refetchQueries(n,t)})}refetchQueries(e,t={}){const n={...t,cancelRefetch:t.cancelRefetch??!0},r=_e.batch(()=>y(this,ge).findAll(e).filter(i=>!i.isDisabled()).map(i=>{let s=i.fetch(void 0,n);return n.throwOnError||(s=s.catch(Ot)),i.state.fetchStatus==="paused"?Promise.resolve():s}));return Promise.all(r).then(Ot)}fetchQuery(e){const t=this.defaultQueryOptions(e);t.retry===void 0&&(t.retry=!1);const n=y(this,ge).build(this,t);return n.isStaleByTime(ki(t.staleTime,n))?n.fetch(t):Promise.resolve(n.state.data)}prefetchQuery(e){return this.fetchQuery(e).then(Ot).catch(Ot)}fetchInfiniteQuery(e){return e.behavior=Mh(e.pages),this.fetchQuery(e)}prefetchInfiniteQuery(e){return this.fetchInfiniteQuery(e).then(Ot).catch(Ot)}ensureInfiniteQueryData(e){return e.behavior=Mh(e.pages),this.ensureQueryData(e)}resumePausedMutations(){return Dl.isOnline()?y(this,Hn).resumePausedMutations():Promise.resolve()}getQueryCache(){return y(this,ge)}getMutationCache(){return y(this,Hn)}getDefaultOptions(){return y(this,Wn)}setDefaultOptions(e){j(this,Wn,e)}setQueryDefaults(e,t){y(this,Pi).set(Qr(e),{queryKey:e,defaultOptions:t})}getQueryDefaults(e){const t=[...y(this,Pi).values()],n={};return t.forEach(r=>{Ks(e,r.queryKey)&&Object.assign(n,r.defaultOptions)}),n}setMutationDefaults(e,t){y(this,Ai).set(Qr(e),{mutationKey:e,defaultOptions:t})}getMutationDefaults(e){const t=[...y(this,Ai).values()];let n={};return t.forEach(r=>{Ks(e,r.mutationKey)&&(n={...n,...r.defaultOptions})}),n}defaultQueryOptions(e){if(e._defaulted)return e;const t={...y(this,Wn).queries,...this.getQueryDefaults(e.queryKey),...e,_defaulted:!0};return t.queryHash||(t.queryHash=Hf(t.queryKey,t)),t.refetchOnReconnect===void 0&&(t.refetchOnReconnect=t.networkMode!=="always"),t.throwOnError===void 0&&(t.throwOnError=!!t.suspense),!t.networkMode&&t.persister&&(t.networkMode="offlineFirst"),t.enabled!==!0&&t.queryFn===Wf&&(t.enabled=!1),t}defaultMutationOptions(e){return e!=null&&e._defaulted?e:{...y(this,Wn).mutations,...(e==null?void 0:e.mutationKey)&&this.getMutationDefaults(e.mutationKey),...e,_defaulted:!0}}clear(){y(this,ge).clear(),y(this,Hn).clear()}},ge=new WeakMap,Hn=new WeakMap,Wn=new WeakMap,Pi=new WeakMap,Ai=new WeakMap,Qn=new WeakMap,ji=new WeakMap,Fi=new WeakMap,Jp),tt,G,no,Ke,Ar,$i,qn,on,ro,Ii,Di,jr,Fr,Kn,Li,ne,vs,vc,wc,xc,Sc,bc,Ec,_c,Ty,em,dx=(em=class extends Zi{constructor(t,n){super();U(this,ne);U(this,tt);U(this,G);U(this,no);U(this,Ke);U(this,Ar);U(this,$i);U(this,qn);U(this,on);U(this,ro);U(this,Ii);U(this,Di);U(this,jr);U(this,Fr);U(this,Kn);U(this,Li,new Set);this.options=n,j(this,tt,t),j(this,on,null),j(this,qn,gc()),this.options.experimental_prefetchInRender||y(this,qn).reject(new Error("experimental_prefetchInRender feature flag is not enabled")),this.bindMethods(),this.setOptions(n)}bindMethods(){this.refetch=this.refetch.bind(this)}onSubscribe(){this.listeners.size===1&&(y(this,G).addObserver(this),Bh(y(this,G),this.options)?q(this,ne,vs).call(this):this.updateResult(),q(this,ne,Sc).call(this))}onUnsubscribe(){this.hasListeners()||this.destroy()}shouldFetchOnReconnect(){return kc(y(this,G),this.options,this.options.refetchOnReconnect)}shouldFetchOnWindowFocus(){return kc(y(this,G),this.options,this.options.refetchOnWindowFocus)}destroy(){this.listeners=new Set,q(this,ne,bc).call(this),q(this,ne,Ec).call(this),y(this,G).removeObserver(this)}setOptions(t,n){const r=this.options,i=y(this,G);if(this.options=y(this,tt).defaultQueryOptions(t),this.options.enabled!==void 0&&typeof this.options.enabled!="boolean"&&typeof this.options.enabled!="function"&&typeof Wt(this.options.enabled,y(this,G))!="boolean")throw new Error("Expected enabled to be a boolean or a callback that returns a boolean");q(this,ne,_c).call(this),y(this,G).setOptions(this.options),r._defaulted&&!Il(this.options,r)&&y(this,tt).getQueryCache().notify({type:"observerOptionsUpdated",query:y(this,G),observer:this});const s=this.hasListeners();s&&Uh(y(this,G),i,this.options,r)&&q(this,ne,vs).call(this),this.updateResult(n),s&&(y(this,G)!==i||Wt(this.options.enabled,y(this,G))!==Wt(r.enabled,y(this,G))||ki(this.options.staleTime,y(this,G))!==ki(r.staleTime,y(this,G)))&&q(this,ne,vc).call(this);const o=q(this,ne,wc).call(this);s&&(y(this,G)!==i||Wt(this.options.enabled,y(this,G))!==Wt(r.enabled,y(this,G))||o!==y(this,Kn))&&q(this,ne,xc).call(this,o)}getOptimisticResult(t){const n=y(this,tt).getQueryCache().build(y(this,tt),t),r=this.createResult(n,t);return px(this,r)&&(j(this,Ke,r),j(this,$i,this.options),j(this,Ar,y(this,G).state)),r}getCurrentResult(){return y(this,Ke)}trackResult(t,n){const r={};return Object.keys(t).forEach(i=>{Object.defineProperty(r,i,{configurable:!1,enumerable:!0,get:()=>(this.trackProp(i),n==null||n(i),t[i])})}),r}trackProp(t){y(this,Li).add(t)}getCurrentQuery(){return y(this,G)}refetch({...t}={}){return this.fetch({...t})}fetchOptimistic(t){const n=y(this,tt).defaultQueryOptions(t),r=y(this,tt).getQueryCache().build(y(this,tt),n);return r.fetch().then(()=>this.createResult(r,n))}fetch(t){return q(this,ne,vs).call(this,{...t,cancelRefetch:t.cancelRefetch??!0}).then(()=>(this.updateResult(),y(this,Ke)))}createResult(t,n){var R;const r=y(this,G),i=this.options,s=y(this,Ke),o=y(this,Ar),l=y(this,$i),c=t!==r?t.state:y(this,no),{state:f}=t;let u={...f},d=!1,h;if(n._optimisticResults){const I=this.hasListeners(),L=!I&&Bh(t,n),B=I&&Uh(t,r,n,i);(L||B)&&(u={...u,...ky(f.data,t.options)}),n._optimisticResults==="isRestoring"&&(u.fetchStatus="idle")}let{error:v,errorUpdatedAt:w,status:S}=u;if(n.select&&u.data!==void 0)if(s&&u.data===(o==null?void 0:o.data)&&n.select===y(this,ro))h=y(this,Ii);else try{j(this,ro,n.select),h=n.select(u.data),h=yc(s==null?void 0:s.data,h,n),j(this,Ii,h),j(this,on,null)}catch(I){j(this,on,I)}else h=u.data;if(n.placeholderData!==void 0&&h===void 0&&S==="pending"){let I;if(s!=null&&s.isPlaceholderData&&n.placeholderData===(l==null?void 0:l.placeholderData))I=s.data;else if(I=typeof n.placeholderData=="function"?n.placeholderData((R=y(this,Di))==null?void 0:R.state.data,y(this,Di)):n.placeholderData,n.select&&I!==void 0)try{I=n.select(I),j(this,on,null)}catch(L){j(this,on,L)}I!==void 0&&(S="success",h=yc(s==null?void 0:s.data,I,n),d=!0)}y(this,on)&&(v=y(this,on),h=y(this,Ii),w=Date.now(),S="error");const m=u.fetchStatus==="fetching",p=S==="pending",g=S==="error",x=p&&m,C=h!==void 0,k={status:S,fetchStatus:u.fetchStatus,isPending:p,isSuccess:S==="success",isError:g,isInitialLoading:x,isLoading:x,data:h,dataUpdatedAt:u.dataUpdatedAt,error:v,errorUpdatedAt:w,failureCount:u.fetchFailureCount,failureReason:u.fetchFailureReason,errorUpdateCount:u.errorUpdateCount,isFetched:u.dataUpdateCount>0||u.errorUpdateCount>0,isFetchedAfterMount:u.dataUpdateCount>c.dataUpdateCount||u.errorUpdateCount>c.errorUpdateCount,isFetching:m,isRefetching:m&&!p,isLoadingError:g&&!C,isPaused:u.fetchStatus==="paused",isPlaceholderData:d,isRefetchError:g&&C,isStale:qf(t,n),refetch:this.refetch,promise:y(this,qn)};if(this.options.experimental_prefetchInRender){const I=se=>{k.status==="error"?se.reject(k.error):k.data!==void 0&&se.resolve(k.data)},L=()=>{const se=j(this,qn,k.promise=gc());I(se)},B=y(this,qn);switch(B.status){case"pending":t.queryHash===r.queryHash&&I(B);break;case"fulfilled":(k.status==="error"||k.data!==B.value)&&L();break;case"rejected":(k.status!=="error"||k.error!==B.reason)&&L();break}}return k}updateResult(t){const n=y(this,Ke),r=this.createResult(y(this,G),this.options);if(j(this,Ar,y(this,G).state),j(this,$i,this.options),y(this,Ar).data!==void 0&&j(this,Di,y(this,G)),Il(r,n))return;j(this,Ke,r);const i={},s=()=>{if(!n)return!0;const{notifyOnChangeProps:o}=this.options,l=typeof o=="function"?o():o;if(l==="all"||!l&&!y(this,Li).size)return!0;const a=new Set(l??y(this,Li));return this.options.throwOnError&&a.add("error"),Object.keys(y(this,Ke)).some(c=>{const f=c;return y(this,Ke)[f]!==n[f]&&a.has(f)})};(t==null?void 0:t.listeners)!==!1&&s()&&(i.listeners=!0),q(this,ne,Ty).call(this,{...i,...t})}onQueryUpdate(){this.updateResult(),this.hasListeners()&&q(this,ne,Sc).call(this)}},tt=new WeakMap,G=new WeakMap,no=new WeakMap,Ke=new WeakMap,Ar=new WeakMap,$i=new WeakMap,qn=new WeakMap,on=new WeakMap,ro=new WeakMap,Ii=new WeakMap,Di=new WeakMap,jr=new WeakMap,Fr=new WeakMap,Kn=new WeakMap,Li=new WeakMap,ne=new WeakSet,vs=function(t){q(this,ne,_c).call(this);let n=y(this,G).fetch(this.options,t);return t!=null&&t.throwOnError||(n=n.catch(Ot)),n},vc=function(){q(this,ne,bc).call(this);const t=ki(this.options.staleTime,y(this,G));if(Wr||y(this,Ke).isStale||!pc(t))return;const r=vy(y(this,Ke).dataUpdatedAt,t)+1;j(this,jr,setTimeout(()=>{y(this,Ke).isStale||this.updateResult()},r))},wc=function(){return(typeof this.options.refetchInterval=="function"?this.options.refetchInterval(y(this,G)):this.options.refetchInterval)??!1},xc=function(t){q(this,ne,Ec).call(this),j(this,Kn,t),!(Wr||Wt(this.options.enabled,y(this,G))===!1||!pc(y(this,Kn))||y(this,Kn)===0)&&j(this,Fr,setInterval(()=>{(this.options.refetchIntervalInBackground||Qf.isFocused())&&q(this,ne,vs).call(this)},y(this,Kn)))},Sc=function(){q(this,ne,vc).call(this),q(this,ne,xc).call(this,q(this,ne,wc).call(this))},bc=function(){y(this,jr)&&(clearTimeout(y(this,jr)),j(this,jr,void 0))},Ec=function(){y(this,Fr)&&(clearInterval(y(this,Fr)),j(this,Fr,void 0))},_c=function(){const t=y(this,tt).getQueryCache().build(y(this,tt),this.options);if(t===y(this,G))return;const n=y(this,G);j(this,G,t),j(this,no,t.state),this.hasListeners()&&(n==null||n.removeObserver(this),t.addObserver(this))},Ty=function(t){_e.batch(()=>{t.listeners&&this.listeners.forEach(n=>{n(y(this,Ke))}),y(this,tt).getQueryCache().notify({query:y(this,G),type:"observerResultsUpdated"})})},em);function hx(e,t){return Wt(t.enabled,e)!==!1&&e.state.data===void 0&&!(e.state.status==="error"&&t.retryOnMount===!1)}function Bh(e,t){return hx(e,t)||e.state.data!==void 0&&kc(e,t,t.refetchOnMount)}function kc(e,t,n){if(Wt(t.enabled,e)!==!1){const r=typeof n=="function"?n(e):n;return r==="always"||r!==!1&&qf(e,t)}return!1}function Uh(e,t,n,r){return(e!==t||Wt(r.enabled,e)===!1)&&(!n.suspense||e.state.status!=="error")&&qf(e,n)}function qf(e,t){return Wt(t.enabled,e)!==!1&&e.isStaleByTime(ki(t.staleTime,e))}function px(e,t){return!Il(e.getCurrentResult(),t)}var Yn,Gn,nt,Sn,kn,il,Cc,tm,mx=(tm=class extends Zi{constructor(t,n){super();U(this,kn);U(this,Yn);U(this,Gn);U(this,nt);U(this,Sn);j(this,Yn,t),this.setOptions(n),this.bindMethods(),q(this,kn,il).call(this)}bindMethods(){this.mutate=this.mutate.bind(this),this.reset=this.reset.bind(this)}setOptions(t){var r;const n=this.options;this.options=y(this,Yn).defaultMutationOptions(t),Il(this.options,n)||y(this,Yn).getMutationCache().notify({type:"observerOptionsUpdated",mutation:y(this,nt),observer:this}),n!=null&&n.mutationKey&&this.options.mutationKey&&Qr(n.mutationKey)!==Qr(this.options.mutationKey)?this.reset():((r=y(this,nt))==null?void 0:r.state.status)==="pending"&&y(this,nt).setOptions(this.options)}onUnsubscribe(){var t;this.hasListeners()||(t=y(this,nt))==null||t.removeObserver(this)}onMutationUpdate(t){q(this,kn,il).call(this),q(this,kn,Cc).call(this,t)}getCurrentResult(){return y(this,Gn)}reset(){var t;(t=y(this,nt))==null||t.removeObserver(this),j(this,nt,void 0),q(this,kn,il).call(this),q(this,kn,Cc).call(this)}mutate(t,n){var r;return j(this,Sn,n),(r=y(this,nt))==null||r.removeObserver(this),j(this,nt,y(this,Yn).getMutationCache().build(y(this,Yn),this.options)),y(this,nt).addObserver(this),y(this,nt).execute(t)}},Yn=new WeakMap,Gn=new WeakMap,nt=new WeakMap,Sn=new WeakMap,kn=new WeakSet,il=function(){var n;const t=((n=y(this,nt))==null?void 0:n.state)??Cy();j(this,Gn,{...t,isPending:t.status==="pending",isSuccess:t.status==="success",isError:t.status==="error",isIdle:t.status==="idle",mutate:this.mutate,reset:this.reset})},Cc=function(t){_e.batch(()=>{var n,r,i,s,o,l,a,c;if(y(this,Sn)&&this.hasListeners()){const f=y(this,Gn).variables,u=y(this,Gn).context;(t==null?void 0:t.type)==="success"?((r=(n=y(this,Sn)).onSuccess)==null||r.call(n,t.data,f,u),(s=(i=y(this,Sn)).onSettled)==null||s.call(i,t.data,null,f,u)):(t==null?void 0:t.type)==="error"&&((l=(o=y(this,Sn)).onError)==null||l.call(o,t.error,f,u),(c=(a=y(this,Sn)).onSettled)==null||c.call(a,void 0,t.error,f,u))}this.listeners.forEach(f=>{f(y(this,Gn))})})},tm),Oy=b.createContext(void 0),Ry=e=>{const t=b.useContext(Oy);if(!t)throw new Error("No QueryClient set, use QueryClientProvider to set one");return t},yx=({client:e,children:t})=>(b.useEffect(()=>(e.mount(),()=>{e.unmount()}),[e]),_.jsx(Oy.Provider,{value:e,children:t})),Ny=b.createContext(!1),gx=()=>b.useContext(Ny);Ny.Provider;function vx(){let e=!1;return{clearReset:()=>{e=!1},reset:()=>{e=!0},isReset:()=>e}}var wx=b.createContext(vx()),xx=()=>b.useContext(wx);function Py(e,t){return typeof e=="function"?e(...t):!!e}function Tc(){}var Sx=(e,t)=>{(e.suspense||e.throwOnError||e.experimental_prefetchInRender)&&(t.isReset()||(e.retryOnMount=!1))},bx=e=>{b.useEffect(()=>{e.clearReset()},[e])},Ex=({result:e,errorResetBoundary:t,throwOnError:n,query:r})=>e.isError&&!t.isReset()&&!e.isFetching&&r&&Py(n,[e.error,r]),_x=e=>{e.suspense&&(e.staleTime===void 0&&(e.staleTime=1e3),typeof e.gcTime=="number"&&(e.gcTime=Math.max(e.gcTime,1e3)))},kx=(e,t)=>e.isLoading&&e.isFetching&&!t,Cx=(e,t)=>(e==null?void 0:e.suspense)&&t.isPending,Vh=(e,t,n)=>t.fetchOptimistic(e).catch(()=>{n.clearReset()});function Tx(e,t,n){var f,u,d,h,v;const r=Ry(),i=gx(),s=xx(),o=r.defaultQueryOptions(e);(u=(f=r.getDefaultOptions().queries)==null?void 0:f._experimental_beforeQuery)==null||u.call(f,o),o._optimisticResults=i?"isRestoring":"optimistic",_x(o),Sx(o,s),bx(s);const l=!r.getQueryCache().get(o.queryHash),[a]=b.useState(()=>new t(r,o)),c=a.getOptimisticResult(o);if(b.useSyncExternalStore(b.useCallback(w=>{const S=i?Tc:a.subscribe(_e.batchCalls(w));return a.updateResult(),S},[a,i]),()=>a.getCurrentResult(),()=>a.getCurrentResult()),b.useEffect(()=>{a.setOptions(o,{listeners:!1})},[o,a]),Cx(o,c))throw Vh(o,a,s);if(Ex({result:c,errorResetBoundary:s,throwOnError:o.throwOnError,query:r.getQueryCache().get(o.queryHash)}))throw c.error;if((h=(d=r.getDefaultOptions().queries)==null?void 0:d._experimental_afterQuery)==null||h.call(d,o,c),o.experimental_prefetchInRender&&!Wr&&kx(c,i)){const w=l?Vh(o,a,s):(v=r.getQueryCache().get(o.queryHash))==null?void 0:v.promise;w==null||w.catch(Tc).finally(()=>{a.updateResult()})}return o.notifyOnChangeProps?c:a.trackResult(c)}function Ox(e,t){return Tx(e,dx)}function Rx(e,t){const n=Ry(),[r]=b.useState(()=>new mx(n,e));b.useEffect(()=>{r.setOptions(e)},[r,e]);const i=b.useSyncExternalStore(b.useCallback(o=>r.subscribe(_e.batchCalls(o)),[r]),()=>r.getCurrentResult(),()=>r.getCurrentResult()),s=b.useCallback((o,l)=>{r.mutate(o,l).catch(Tc)},[r]);if(i.error&&Py(r.options.throwOnError,[i.error]))throw i.error;return{...i,mutate:s,mutateAsync:i.mutate}}const Nx=e=>Ox({queryKey:["widgets",e],queryFn:()=>Px(e)}),Px=e=>oa(`widgets/with-link/${e}`);function Ax(e){return!!e&&typeof e.public_id=="string"&&typeof e.link_id=="string"&&typeof e.name=="string"&&typeof e.is_browser_notification_enabled=="boolean"&&typeof e.is_hidden_on_offline=="boolean"&&typeof e.is_upload_disabled=="boolean"}/**
41
41
  * @remix-run/router v1.21.0
42
42
  *
43
43
  * Copyright (c) Remix Software Inc.
@@ -46,7 +46,7 @@ Error generating stack: `+s.message+`
46
46
  * LICENSE.md file in the root directory of this source tree.
47
47
  *
48
48
  * @license MIT
49
- */function Dl(){return Dl=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},Dl.apply(this,arguments)}var Jn;(function(e){e.Pop="POP",e.Push="PUSH",e.Replace="REPLACE"})(Jn||(Jn={}));function Ax(e){e===void 0&&(e={});let{initialEntries:t=["/"],initialIndex:n,v5Compat:r=!1}=e,i;i=t.map((h,v)=>f(h,typeof h=="string"?null:h.state,v===0?"default":void 0));let s=a(n??i.length-1),o=Jn.Pop,l=null;function a(h){return Math.min(Math.max(h,0),i.length-1)}function c(){return i[s]}function f(h,v,w){v===void 0&&(v=null);let S=Fx(i?c().pathname:"/",h,v,w);return Kf(S.pathname.charAt(0)==="/","relative pathnames are not supported in memory history: "+JSON.stringify(h)),S}function u(h){return typeof h=="string"?h:$x(h)}return{get index(){return s},get action(){return o},get location(){return c()},createHref:u,createURL(h){return new URL(u(h),"http://localhost")},encodeLocation(h){let v=typeof h=="string"?Gr(h):h;return{pathname:v.pathname||"",search:v.search||"",hash:v.hash||""}},push(h,v){o=Jn.Push;let w=f(h,v);s+=1,i.splice(s,i.length,w),r&&l&&l({action:o,location:w,delta:1})},replace(h,v){o=Jn.Replace;let w=f(h,v);i[s]=w,r&&l&&l({action:o,location:w,delta:0})},go(h){o=Jn.Pop;let v=a(s+h),w=i[v];s=v,l&&l({action:o,location:w,delta:h})},listen(h){return l=h,()=>{l=null}}}}function Pe(e,t){if(e===!1||e===null||typeof e>"u")throw new Error(t)}function Kf(e,t){if(!e){typeof console<"u"&&console.warn(t);try{throw new Error(t)}catch{}}}function jx(){return Math.random().toString(36).substr(2,8)}function Fx(e,t,n,r){return n===void 0&&(n=null),Dl({pathname:typeof e=="string"?e:e.pathname,search:"",hash:""},typeof t=="string"?Gr(t):t,{state:n,key:t&&t.key||r||jx()})}function $x(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 Gr(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}var Hh;(function(e){e.data="data",e.deferred="deferred",e.redirect="redirect",e.error="error"})(Hh||(Hh={}));function Ix(e,t,n){return n===void 0&&(n="/"),Lx(e,t,n,!1)}function Lx(e,t,n,r){let i=typeof t=="string"?Gr(t):t,s=Fg(i.pathname||"/",n);if(s==null)return null;let o=Ag(e);Dx(o);let l=null;for(let a=0;l==null&&a<o.length;++a){let c=Yx(s);l=qx(o[a],c,r)}return l}function Ag(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("/")&&(Pe(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 c=Lr([r,a.relativePath]),f=n.concat(a);s.children&&s.children.length>0&&(Pe(s.index!==!0,"Index routes must not have child routes. Please remove "+('all child routes from route path "'+c+'".')),Ag(s.children,t,f,c)),!(s.path==null&&!s.index)&&t.push({path:c,score:Wx(c,s.index),routesMeta:f})};return e.forEach((s,o)=>{var l;if(s.path===""||!((l=s.path)!=null&&l.includes("?")))i(s,o);else for(let a of jg(s.path))i(s,o,a)}),t}function jg(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=jg(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 Dx(e){e.sort((t,n)=>t.score!==n.score?n.score-t.score:Qx(t.routesMeta.map(r=>r.childrenIndex),n.routesMeta.map(r=>r.childrenIndex)))}const Mx=/^:[\w-]+$/,zx=3,Bx=2,Ux=1,Vx=10,Hx=-2,Wh=e=>e==="*";function Wx(e,t){let n=e.split("/"),r=n.length;return n.some(Wh)&&(r+=Hx),t&&(r+=Bx),n.filter(i=>!Wh(i)).reduce((i,s)=>i+(Mx.test(s)?zx:s===""?Ux:Vx),r)}function Qx(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 qx(e,t,n){let{routesMeta:r}=e,i={},s="/",o=[];for(let l=0;l<r.length;++l){let a=r[l],c=l===r.length-1,f=s==="/"?t:t.slice(s.length)||"/",u=Qh({path:a.relativePath,caseSensitive:a.caseSensitive,end:c},f),d=a.route;if(!u&&c&&n&&!r[r.length-1].route.index&&(u=Qh({path:a.relativePath,caseSensitive:a.caseSensitive,end:!1},f)),!u)return null;Object.assign(i,u.params),o.push({params:i,pathname:Lr([s,u.pathname]),pathnameBase:tS(Lr([s,u.pathnameBase])),route:d}),u.pathnameBase!=="/"&&(s=Lr([s,u.pathnameBase]))}return o}function Qh(e,t){typeof e=="string"&&(e={path:e,caseSensitive:!1,end:!0});let[n,r]=Kx(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((c,f,u)=>{let{paramName:d,isOptional:h}=f;if(d==="*"){let w=l[u]||"";o=s.slice(0,s.length-w.length).replace(/(.)\/+$/,"$1")}const v=l[u];return h&&!v?c[d]=void 0:c[d]=(v||"").replace(/%2F/g,"/"),c},{}),pathname:s,pathnameBase:o,pattern:e}}function Kx(e,t,n){t===void 0&&(t=!1),n===void 0&&(n=!0),Kf(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 Yx(e){try{return e.split("/").map(t=>decodeURIComponent(t).replace(/\//g,"%2F")).join("/")}catch(t){return Kf(!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 Fg(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 Gx(e,t){t===void 0&&(t="/");let{pathname:n,search:r="",hash:i=""}=typeof e=="string"?Gr(e):e;return{pathname:n?n.startsWith("/")?n:Xx(n,t):t,search:nS(r),hash:rS(i)}}function Xx(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 uu(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 Zx(e){return e.filter((t,n)=>n===0||t.route.path&&t.route.path.length>0)}function Jx(e,t){let n=Zx(e);return t?n.map((r,i)=>i===n.length-1?r.pathname:r.pathnameBase):n.map(r=>r.pathnameBase)}function eS(e,t,n,r){r===void 0&&(r=!1);let i;typeof e=="string"?i=Gr(e):(i=Dl({},e),Pe(!i.pathname||!i.pathname.includes("?"),uu("?","pathname","search",i)),Pe(!i.pathname||!i.pathname.includes("#"),uu("#","pathname","hash",i)),Pe(!i.search||!i.search.includes("#"),uu("#","search","hash",i)));let s=e===""||i.pathname==="",o=s?"/":i.pathname,l;if(o==null)l=n;else{let u=t.length-1;if(!r&&o.startsWith("..")){let d=o.split("/");for(;d[0]==="..";)d.shift(),u-=1;i.pathname=d.join("/")}l=u>=0?t[u]:"/"}let a=Gx(i,l),c=o&&o!=="/"&&o.endsWith("/"),f=(s||o===".")&&n.endsWith("/");return!a.pathname.endsWith("/")&&(c||f)&&(a.pathname+="/"),a}const Lr=e=>e.join("/").replace(/\/\/+/g,"/"),tS=e=>e.replace(/\/+$/,"").replace(/^\/*/,"/"),nS=e=>!e||e==="?"?"":e.startsWith("?")?e:"?"+e,rS=e=>!e||e==="#"?"":e.startsWith("#")?e:"#"+e;function iS(e){return e!=null&&typeof e.status=="number"&&typeof e.statusText=="string"&&typeof e.internal=="boolean"&&"data"in e}const $g=["post","put","patch","delete"];new Set($g);const sS=["get",...$g];new Set(sS);/**
49
+ */function Ll(){return Ll=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},Ll.apply(this,arguments)}var Jn;(function(e){e.Pop="POP",e.Push="PUSH",e.Replace="REPLACE"})(Jn||(Jn={}));function jx(e){e===void 0&&(e={});let{initialEntries:t=["/"],initialIndex:n,v5Compat:r=!1}=e,i;i=t.map((h,v)=>f(h,typeof h=="string"?null:h.state,v===0?"default":void 0));let s=a(n??i.length-1),o=Jn.Pop,l=null;function a(h){return Math.min(Math.max(h,0),i.length-1)}function c(){return i[s]}function f(h,v,w){v===void 0&&(v=null);let S=$x(i?c().pathname:"/",h,v,w);return Kf(S.pathname.charAt(0)==="/","relative pathnames are not supported in memory history: "+JSON.stringify(h)),S}function u(h){return typeof h=="string"?h:Ix(h)}return{get index(){return s},get action(){return o},get location(){return c()},createHref:u,createURL(h){return new URL(u(h),"http://localhost")},encodeLocation(h){let v=typeof h=="string"?Gr(h):h;return{pathname:v.pathname||"",search:v.search||"",hash:v.hash||""}},push(h,v){o=Jn.Push;let w=f(h,v);s+=1,i.splice(s,i.length,w),r&&l&&l({action:o,location:w,delta:1})},replace(h,v){o=Jn.Replace;let w=f(h,v);i[s]=w,r&&l&&l({action:o,location:w,delta:0})},go(h){o=Jn.Pop;let v=a(s+h),w=i[v];s=v,l&&l({action:o,location:w,delta:h})},listen(h){return l=h,()=>{l=null}}}}function Pe(e,t){if(e===!1||e===null||typeof e>"u")throw new Error(t)}function Kf(e,t){if(!e){typeof console<"u"&&console.warn(t);try{throw new Error(t)}catch{}}}function Fx(){return Math.random().toString(36).substr(2,8)}function $x(e,t,n,r){return n===void 0&&(n=null),Ll({pathname:typeof e=="string"?e:e.pathname,search:"",hash:""},typeof t=="string"?Gr(t):t,{state:n,key:t&&t.key||r||Fx()})}function Ix(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 Gr(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}var Hh;(function(e){e.data="data",e.deferred="deferred",e.redirect="redirect",e.error="error"})(Hh||(Hh={}));function Dx(e,t,n){return n===void 0&&(n="/"),Lx(e,t,n,!1)}function Lx(e,t,n,r){let i=typeof t=="string"?Gr(t):t,s=Fy(i.pathname||"/",n);if(s==null)return null;let o=Ay(e);Mx(o);let l=null;for(let a=0;l==null&&a<o.length;++a){let c=Gx(s);l=Kx(o[a],c,r)}return l}function Ay(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("/")&&(Pe(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 c=Dr([r,a.relativePath]),f=n.concat(a);s.children&&s.children.length>0&&(Pe(s.index!==!0,"Index routes must not have child routes. Please remove "+('all child routes from route path "'+c+'".')),Ay(s.children,t,f,c)),!(s.path==null&&!s.index)&&t.push({path:c,score:Qx(c,s.index),routesMeta:f})};return e.forEach((s,o)=>{var l;if(s.path===""||!((l=s.path)!=null&&l.includes("?")))i(s,o);else for(let a of jy(s.path))i(s,o,a)}),t}function jy(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=jy(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 Mx(e){e.sort((t,n)=>t.score!==n.score?n.score-t.score:qx(t.routesMeta.map(r=>r.childrenIndex),n.routesMeta.map(r=>r.childrenIndex)))}const zx=/^:[\w-]+$/,Bx=3,Ux=2,Vx=1,Hx=10,Wx=-2,Wh=e=>e==="*";function Qx(e,t){let n=e.split("/"),r=n.length;return n.some(Wh)&&(r+=Wx),t&&(r+=Ux),n.filter(i=>!Wh(i)).reduce((i,s)=>i+(zx.test(s)?Bx:s===""?Vx:Hx),r)}function qx(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 Kx(e,t,n){let{routesMeta:r}=e,i={},s="/",o=[];for(let l=0;l<r.length;++l){let a=r[l],c=l===r.length-1,f=s==="/"?t:t.slice(s.length)||"/",u=Qh({path:a.relativePath,caseSensitive:a.caseSensitive,end:c},f),d=a.route;if(!u&&c&&n&&!r[r.length-1].route.index&&(u=Qh({path:a.relativePath,caseSensitive:a.caseSensitive,end:!1},f)),!u)return null;Object.assign(i,u.params),o.push({params:i,pathname:Dr([s,u.pathname]),pathnameBase:nS(Dr([s,u.pathnameBase])),route:d}),u.pathnameBase!=="/"&&(s=Dr([s,u.pathnameBase]))}return o}function Qh(e,t){typeof e=="string"&&(e={path:e,caseSensitive:!1,end:!0});let[n,r]=Yx(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((c,f,u)=>{let{paramName:d,isOptional:h}=f;if(d==="*"){let w=l[u]||"";o=s.slice(0,s.length-w.length).replace(/(.)\/+$/,"$1")}const v=l[u];return h&&!v?c[d]=void 0:c[d]=(v||"").replace(/%2F/g,"/"),c},{}),pathname:s,pathnameBase:o,pattern:e}}function Yx(e,t,n){t===void 0&&(t=!1),n===void 0&&(n=!0),Kf(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 Gx(e){try{return e.split("/").map(t=>decodeURIComponent(t).replace(/\//g,"%2F")).join("/")}catch(t){return Kf(!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 Fy(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 Xx(e,t){t===void 0&&(t="/");let{pathname:n,search:r="",hash:i=""}=typeof e=="string"?Gr(e):e;return{pathname:n?n.startsWith("/")?n:Zx(n,t):t,search:rS(r),hash:iS(i)}}function Zx(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 uu(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 Jx(e){return e.filter((t,n)=>n===0||t.route.path&&t.route.path.length>0)}function eS(e,t){let n=Jx(e);return t?n.map((r,i)=>i===n.length-1?r.pathname:r.pathnameBase):n.map(r=>r.pathnameBase)}function tS(e,t,n,r){r===void 0&&(r=!1);let i;typeof e=="string"?i=Gr(e):(i=Ll({},e),Pe(!i.pathname||!i.pathname.includes("?"),uu("?","pathname","search",i)),Pe(!i.pathname||!i.pathname.includes("#"),uu("#","pathname","hash",i)),Pe(!i.search||!i.search.includes("#"),uu("#","search","hash",i)));let s=e===""||i.pathname==="",o=s?"/":i.pathname,l;if(o==null)l=n;else{let u=t.length-1;if(!r&&o.startsWith("..")){let d=o.split("/");for(;d[0]==="..";)d.shift(),u-=1;i.pathname=d.join("/")}l=u>=0?t[u]:"/"}let a=Xx(i,l),c=o&&o!=="/"&&o.endsWith("/"),f=(s||o===".")&&n.endsWith("/");return!a.pathname.endsWith("/")&&(c||f)&&(a.pathname+="/"),a}const Dr=e=>e.join("/").replace(/\/\/+/g,"/"),nS=e=>e.replace(/\/+$/,"").replace(/^\/*/,"/"),rS=e=>!e||e==="?"?"":e.startsWith("?")?e:"?"+e,iS=e=>!e||e==="#"?"":e.startsWith("#")?e:"#"+e;function sS(e){return e!=null&&typeof e.status=="number"&&typeof e.statusText=="string"&&typeof e.internal=="boolean"&&"data"in e}const $y=["post","put","patch","delete"];new Set($y);const oS=["get",...$y];new Set(oS);/**
50
50
  * React Router v6.28.0
51
51
  *
52
52
  * Copyright (c) Remix Software Inc.
@@ -55,7 +55,7 @@ Error generating stack: `+s.message+`
55
55
  * LICENSE.md file in the root directory of this source tree.
56
56
  *
57
57
  * @license MIT
58
- */function Ys(){return Ys=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},Ys.apply(this,arguments)}const Yf=b.createContext(null),oS=b.createContext(null),la=b.createContext(null),aa=b.createContext(null),Ji=b.createContext({outlet:null,matches:[],isDataRoute:!1}),Ig=b.createContext(null);function ua(){return b.useContext(aa)!=null}function Lg(){return ua()||Pe(!1),b.useContext(aa).location}function Dg(e){b.useContext(la).static||b.useLayoutEffect(e)}function lS(){let{isDataRoute:e}=b.useContext(Ji);return e?xS():aS()}function aS(){ua()||Pe(!1);let e=b.useContext(Yf),{basename:t,future:n,navigator:r}=b.useContext(la),{matches:i}=b.useContext(Ji),{pathname:s}=Lg(),o=JSON.stringify(Jx(i,n.v7_relativeSplatPath)),l=b.useRef(!1);return Dg(()=>{l.current=!0}),b.useCallback(function(c,f){if(f===void 0&&(f={}),!l.current)return;if(typeof c=="number"){r.go(c);return}let u=eS(c,JSON.parse(o),s,f.relative==="path");e==null&&t!=="/"&&(u.pathname=u.pathname==="/"?t:Lr([t,u.pathname])),(f.replace?r.replace:r.push)(u,f.state,f)},[t,r,o,s,e])}function uS(e,t){return cS(e,t)}function cS(e,t,n,r){ua()||Pe(!1);let{navigator:i}=b.useContext(la),{matches:s}=b.useContext(Ji),o=s[s.length-1],l=o?o.params:{};o&&o.pathname;let a=o?o.pathnameBase:"/";o&&o.route;let c=Lg(),f;if(t){var u;let S=typeof t=="string"?Gr(t):t;a==="/"||(u=S.pathname)!=null&&u.startsWith(a)||Pe(!1),f=S}else f=c;let d=f.pathname||"/",h=d;if(a!=="/"){let S=a.replace(/^\//,"").split("/");h="/"+d.replace(/^\//,"").split("/").slice(S.length).join("/")}let v=Ix(e,{pathname:h}),w=mS(v&&v.map(S=>Object.assign({},S,{params:Object.assign({},l,S.params),pathname:Lr([a,i.encodeLocation?i.encodeLocation(S.pathname).pathname:S.pathname]),pathnameBase:S.pathnameBase==="/"?a:Lr([a,i.encodeLocation?i.encodeLocation(S.pathnameBase).pathname:S.pathnameBase])})),s,n,r);return t&&w?b.createElement(aa.Provider,{value:{location:Ys({pathname:"/",search:"",hash:"",state:null,key:"default"},f),navigationType:Jn.Pop}},w):w}function fS(){let e=wS(),t=iS(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 b.createElement(b.Fragment,null,b.createElement("h2",null,"Unexpected Application Error!"),b.createElement("h3",{style:{fontStyle:"italic"}},t),n?b.createElement("pre",{style:i},n):null,null)}const dS=b.createElement(fS,null);class hS extends b.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?b.createElement(Ji.Provider,{value:this.props.routeContext},b.createElement(Ig.Provider,{value:this.state.error,children:this.props.component})):this.props.children}}function pS(e){let{routeContext:t,match:n,children:r}=e,i=b.useContext(Yf);return i&&i.static&&i.staticContext&&(n.route.errorElement||n.route.ErrorBoundary)&&(i.staticContext._deepestRenderedBoundaryId=n.route.id),b.createElement(Ji.Provider,{value:t},r)}function mS(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(!n)return null;if(n.errors)e=n.matches;else if((s=r)!=null&&s.v7_partialHydration&&t.length===0&&!n.initialized&&n.matches.length>0)e=n.matches;else return null}let o=e,l=(i=n)==null?void 0:i.errors;if(l!=null){let f=o.findIndex(u=>u.route.id&&(l==null?void 0:l[u.route.id])!==void 0);f>=0||Pe(!1),o=o.slice(0,Math.min(o.length,f+1))}let a=!1,c=-1;if(n&&r&&r.v7_partialHydration)for(let f=0;f<o.length;f++){let u=o[f];if((u.route.HydrateFallback||u.route.hydrateFallbackElement)&&(c=f),u.route.id){let{loaderData:d,errors:h}=n,v=u.route.loader&&d[u.route.id]===void 0&&(!h||h[u.route.id]===void 0);if(u.route.lazy||v){a=!0,c>=0?o=o.slice(0,c+1):o=[o[0]];break}}}return o.reduceRight((f,u,d)=>{let h,v=!1,w=null,S=null;n&&(h=l&&u.route.id?l[u.route.id]:void 0,w=u.route.errorElement||dS,a&&(c<0&&d===0?(v=!0,S=null):c===d&&(v=!0,S=u.route.hydrateFallbackElement||null)));let m=t.concat(o.slice(0,d+1)),p=()=>{let y;return h?y=w:v?y=S:u.route.Component?y=b.createElement(u.route.Component,null):u.route.element?y=u.route.element:y=f,b.createElement(pS,{match:u,routeContext:{outlet:f,matches:m,isDataRoute:n!=null},children:y})};return n&&(u.route.ErrorBoundary||u.route.errorElement||d===0)?b.createElement(hS,{location:n.location,revalidation:n.revalidation,component:w,error:h,children:p(),routeContext:{outlet:null,matches:m,isDataRoute:!0}}):p()},null)}var Mg=function(e){return e.UseBlocker="useBlocker",e.UseRevalidator="useRevalidator",e.UseNavigateStable="useNavigate",e}(Mg||{}),Ml=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}(Ml||{});function gS(e){let t=b.useContext(Yf);return t||Pe(!1),t}function yS(e){let t=b.useContext(oS);return t||Pe(!1),t}function vS(e){let t=b.useContext(Ji);return t||Pe(!1),t}function zg(e){let t=vS(),n=t.matches[t.matches.length-1];return n.route.id||Pe(!1),n.route.id}function wS(){var e;let t=b.useContext(Ig),n=yS(Ml.UseRouteError),r=zg(Ml.UseRouteError);return t!==void 0?t:(e=n.errors)==null?void 0:e[r]}function xS(){let{router:e}=gS(Mg.UseNavigateStable),t=zg(Ml.UseNavigateStable),n=b.useRef(!1);return Dg(()=>{n.current=!0}),b.useCallback(function(i,s){s===void 0&&(s={}),n.current&&(typeof i=="number"?e.navigate(i):e.navigate(i,Ys({fromRouteId:t},s)))},[e,t])}const qh={};function SS(e,t){qh[t]||(qh[t]=!0,console.warn(t))}const Kh=(e,t,n)=>SS(e,"⚠️ React Router Future Flag Warning: "+t+". "+("You can use the `"+e+"` future flag to opt-in early. ")+("For more information, see "+n+"."));function bS(e,t){e!=null&&e.v7_startTransition||Kh("v7_startTransition","React Router will begin wrapping state updates in `React.startTransition` in v7","https://reactrouter.com/v6/upgrading/future#v7_starttransition"),!(e!=null&&e.v7_relativeSplatPath)&&!t&&Kh("v7_relativeSplatPath","Relative route resolution within Splat routes is changing in v7","https://reactrouter.com/v6/upgrading/future#v7_relativesplatpath")}const ES="startTransition",Yh=Ev[ES];function _S(e){let{basename:t,children:n,initialEntries:r,initialIndex:i,future:s}=e,o=b.useRef();o.current==null&&(o.current=Ax({initialEntries:r,initialIndex:i,v5Compat:!0}));let l=o.current,[a,c]=b.useState({action:l.action,location:l.location}),{v7_startTransition:f}=s||{},u=b.useCallback(d=>{f&&Yh?Yh(()=>c(d)):c(d)},[c,f]);return b.useLayoutEffect(()=>l.listen(u),[l,u]),b.useEffect(()=>bS(s),[s]),b.createElement(kS,{basename:t,children:n,location:a.location,navigationType:a.action,navigator:l,future:s})}function Oc(e){Pe(!1)}function kS(e){let{basename:t="/",children:n=null,location:r,navigationType:i=Jn.Pop,navigator:s,static:o=!1,future:l}=e;ua()&&Pe(!1);let a=t.replace(/^\/*/,"/"),c=b.useMemo(()=>({basename:a,navigator:s,static:o,future:Ys({v7_relativeSplatPath:!1},l)}),[a,l,s,o]);typeof r=="string"&&(r=Gr(r));let{pathname:f="/",search:u="",hash:d="",state:h=null,key:v="default"}=r,w=b.useMemo(()=>{let S=Fg(f,a);return S==null?null:{location:{pathname:S,search:u,hash:d,state:h,key:v},navigationType:i}},[a,f,u,d,h,v,i]);return w==null?null:b.createElement(la.Provider,{value:c},b.createElement(aa.Provider,{children:n,value:w}))}function CS(e){let{children:t,location:n}=e;return uS(Rc(t),n)}new Promise(()=>{});function Rc(e,t){t===void 0&&(t=[]);let n=[];return b.Children.forEach(e,(r,i)=>{if(!b.isValidElement(r))return;let s=[...t,i];if(r.type===b.Fragment){n.push.apply(n,Rc(r.props.children,s));return}r.type!==Oc&&Pe(!1),!r.props.index||!r.props.children||Pe(!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=Rc(r.props.children,s)),n.push(o)}),n}const TS={BASE_URL:"/",DEV:!1,MODE:"production",PROD:!0,SSR:!1},Gh=e=>{let t;const n=new Set,r=(f,u)=>{const d=typeof f=="function"?f(t):f;if(!Object.is(d,t)){const h=t;t=u??(typeof d!="object"||d===null)?d:Object.assign({},t,d),n.forEach(v=>v(t,h))}},i=()=>t,a={setState:r,getState:i,getInitialState:()=>c,subscribe:f=>(n.add(f),()=>n.delete(f)),destroy:()=>{(TS?"production":void 0)!=="production"&&console.warn("[DEPRECATED] The `destroy` method will be unsupported in a future version. Instead use unsubscribe function returned by subscribe. Everything will be garbage-collected if store is garbage-collected."),n.clear()}},c=t=e(r,i,a);return a},OS=e=>e?Gh(e):Gh;var Bg={exports:{}},Ug={},Vg={exports:{}},Hg={};/**
58
+ */function Ys(){return Ys=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},Ys.apply(this,arguments)}const Yf=b.createContext(null),lS=b.createContext(null),la=b.createContext(null),aa=b.createContext(null),Ji=b.createContext({outlet:null,matches:[],isDataRoute:!1}),Iy=b.createContext(null);function ua(){return b.useContext(aa)!=null}function Dy(){return ua()||Pe(!1),b.useContext(aa).location}function Ly(e){b.useContext(la).static||b.useLayoutEffect(e)}function aS(){let{isDataRoute:e}=b.useContext(Ji);return e?SS():uS()}function uS(){ua()||Pe(!1);let e=b.useContext(Yf),{basename:t,future:n,navigator:r}=b.useContext(la),{matches:i}=b.useContext(Ji),{pathname:s}=Dy(),o=JSON.stringify(eS(i,n.v7_relativeSplatPath)),l=b.useRef(!1);return Ly(()=>{l.current=!0}),b.useCallback(function(c,f){if(f===void 0&&(f={}),!l.current)return;if(typeof c=="number"){r.go(c);return}let u=tS(c,JSON.parse(o),s,f.relative==="path");e==null&&t!=="/"&&(u.pathname=u.pathname==="/"?t:Dr([t,u.pathname])),(f.replace?r.replace:r.push)(u,f.state,f)},[t,r,o,s,e])}function cS(e,t){return fS(e,t)}function fS(e,t,n,r){ua()||Pe(!1);let{navigator:i}=b.useContext(la),{matches:s}=b.useContext(Ji),o=s[s.length-1],l=o?o.params:{};o&&o.pathname;let a=o?o.pathnameBase:"/";o&&o.route;let c=Dy(),f;if(t){var u;let S=typeof t=="string"?Gr(t):t;a==="/"||(u=S.pathname)!=null&&u.startsWith(a)||Pe(!1),f=S}else f=c;let d=f.pathname||"/",h=d;if(a!=="/"){let S=a.replace(/^\//,"").split("/");h="/"+d.replace(/^\//,"").split("/").slice(S.length).join("/")}let v=Dx(e,{pathname:h}),w=yS(v&&v.map(S=>Object.assign({},S,{params:Object.assign({},l,S.params),pathname:Dr([a,i.encodeLocation?i.encodeLocation(S.pathname).pathname:S.pathname]),pathnameBase:S.pathnameBase==="/"?a:Dr([a,i.encodeLocation?i.encodeLocation(S.pathnameBase).pathname:S.pathnameBase])})),s,n,r);return t&&w?b.createElement(aa.Provider,{value:{location:Ys({pathname:"/",search:"",hash:"",state:null,key:"default"},f),navigationType:Jn.Pop}},w):w}function dS(){let e=xS(),t=sS(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 b.createElement(b.Fragment,null,b.createElement("h2",null,"Unexpected Application Error!"),b.createElement("h3",{style:{fontStyle:"italic"}},t),n?b.createElement("pre",{style:i},n):null,null)}const hS=b.createElement(dS,null);class pS extends b.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?b.createElement(Ji.Provider,{value:this.props.routeContext},b.createElement(Iy.Provider,{value:this.state.error,children:this.props.component})):this.props.children}}function mS(e){let{routeContext:t,match:n,children:r}=e,i=b.useContext(Yf);return i&&i.static&&i.staticContext&&(n.route.errorElement||n.route.ErrorBoundary)&&(i.staticContext._deepestRenderedBoundaryId=n.route.id),b.createElement(Ji.Provider,{value:t},r)}function yS(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(!n)return null;if(n.errors)e=n.matches;else if((s=r)!=null&&s.v7_partialHydration&&t.length===0&&!n.initialized&&n.matches.length>0)e=n.matches;else return null}let o=e,l=(i=n)==null?void 0:i.errors;if(l!=null){let f=o.findIndex(u=>u.route.id&&(l==null?void 0:l[u.route.id])!==void 0);f>=0||Pe(!1),o=o.slice(0,Math.min(o.length,f+1))}let a=!1,c=-1;if(n&&r&&r.v7_partialHydration)for(let f=0;f<o.length;f++){let u=o[f];if((u.route.HydrateFallback||u.route.hydrateFallbackElement)&&(c=f),u.route.id){let{loaderData:d,errors:h}=n,v=u.route.loader&&d[u.route.id]===void 0&&(!h||h[u.route.id]===void 0);if(u.route.lazy||v){a=!0,c>=0?o=o.slice(0,c+1):o=[o[0]];break}}}return o.reduceRight((f,u,d)=>{let h,v=!1,w=null,S=null;n&&(h=l&&u.route.id?l[u.route.id]:void 0,w=u.route.errorElement||hS,a&&(c<0&&d===0?(v=!0,S=null):c===d&&(v=!0,S=u.route.hydrateFallbackElement||null)));let m=t.concat(o.slice(0,d+1)),p=()=>{let g;return h?g=w:v?g=S:u.route.Component?g=b.createElement(u.route.Component,null):u.route.element?g=u.route.element:g=f,b.createElement(mS,{match:u,routeContext:{outlet:f,matches:m,isDataRoute:n!=null},children:g})};return n&&(u.route.ErrorBoundary||u.route.errorElement||d===0)?b.createElement(pS,{location:n.location,revalidation:n.revalidation,component:w,error:h,children:p(),routeContext:{outlet:null,matches:m,isDataRoute:!0}}):p()},null)}var My=function(e){return e.UseBlocker="useBlocker",e.UseRevalidator="useRevalidator",e.UseNavigateStable="useNavigate",e}(My||{}),Ml=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}(Ml||{});function gS(e){let t=b.useContext(Yf);return t||Pe(!1),t}function vS(e){let t=b.useContext(lS);return t||Pe(!1),t}function wS(e){let t=b.useContext(Ji);return t||Pe(!1),t}function zy(e){let t=wS(),n=t.matches[t.matches.length-1];return n.route.id||Pe(!1),n.route.id}function xS(){var e;let t=b.useContext(Iy),n=vS(Ml.UseRouteError),r=zy(Ml.UseRouteError);return t!==void 0?t:(e=n.errors)==null?void 0:e[r]}function SS(){let{router:e}=gS(My.UseNavigateStable),t=zy(Ml.UseNavigateStable),n=b.useRef(!1);return Ly(()=>{n.current=!0}),b.useCallback(function(i,s){s===void 0&&(s={}),n.current&&(typeof i=="number"?e.navigate(i):e.navigate(i,Ys({fromRouteId:t},s)))},[e,t])}const qh={};function bS(e,t){qh[t]||(qh[t]=!0,console.warn(t))}const Kh=(e,t,n)=>bS(e,"⚠️ React Router Future Flag Warning: "+t+". "+("You can use the `"+e+"` future flag to opt-in early. ")+("For more information, see "+n+"."));function ES(e,t){e!=null&&e.v7_startTransition||Kh("v7_startTransition","React Router will begin wrapping state updates in `React.startTransition` in v7","https://reactrouter.com/v6/upgrading/future#v7_starttransition"),!(e!=null&&e.v7_relativeSplatPath)&&!t&&Kh("v7_relativeSplatPath","Relative route resolution within Splat routes is changing in v7","https://reactrouter.com/v6/upgrading/future#v7_relativesplatpath")}const _S="startTransition",Yh=_v[_S];function kS(e){let{basename:t,children:n,initialEntries:r,initialIndex:i,future:s}=e,o=b.useRef();o.current==null&&(o.current=jx({initialEntries:r,initialIndex:i,v5Compat:!0}));let l=o.current,[a,c]=b.useState({action:l.action,location:l.location}),{v7_startTransition:f}=s||{},u=b.useCallback(d=>{f&&Yh?Yh(()=>c(d)):c(d)},[c,f]);return b.useLayoutEffect(()=>l.listen(u),[l,u]),b.useEffect(()=>ES(s),[s]),b.createElement(CS,{basename:t,children:n,location:a.location,navigationType:a.action,navigator:l,future:s})}function Oc(e){Pe(!1)}function CS(e){let{basename:t="/",children:n=null,location:r,navigationType:i=Jn.Pop,navigator:s,static:o=!1,future:l}=e;ua()&&Pe(!1);let a=t.replace(/^\/*/,"/"),c=b.useMemo(()=>({basename:a,navigator:s,static:o,future:Ys({v7_relativeSplatPath:!1},l)}),[a,l,s,o]);typeof r=="string"&&(r=Gr(r));let{pathname:f="/",search:u="",hash:d="",state:h=null,key:v="default"}=r,w=b.useMemo(()=>{let S=Fy(f,a);return S==null?null:{location:{pathname:S,search:u,hash:d,state:h,key:v},navigationType:i}},[a,f,u,d,h,v,i]);return w==null?null:b.createElement(la.Provider,{value:c},b.createElement(aa.Provider,{children:n,value:w}))}function TS(e){let{children:t,location:n}=e;return cS(Rc(t),n)}new Promise(()=>{});function Rc(e,t){t===void 0&&(t=[]);let n=[];return b.Children.forEach(e,(r,i)=>{if(!b.isValidElement(r))return;let s=[...t,i];if(r.type===b.Fragment){n.push.apply(n,Rc(r.props.children,s));return}r.type!==Oc&&Pe(!1),!r.props.index||!r.props.children||Pe(!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=Rc(r.props.children,s)),n.push(o)}),n}const OS={BASE_URL:"/",DEV:!1,MODE:"production",PROD:!0,SSR:!1},Gh=e=>{let t;const n=new Set,r=(f,u)=>{const d=typeof f=="function"?f(t):f;if(!Object.is(d,t)){const h=t;t=u??(typeof d!="object"||d===null)?d:Object.assign({},t,d),n.forEach(v=>v(t,h))}},i=()=>t,a={setState:r,getState:i,getInitialState:()=>c,subscribe:f=>(n.add(f),()=>n.delete(f)),destroy:()=>{(OS?"production":void 0)!=="production"&&console.warn("[DEPRECATED] The `destroy` method will be unsupported in a future version. Instead use unsubscribe function returned by subscribe. Everything will be garbage-collected if store is garbage-collected."),n.clear()}},c=t=e(r,i,a);return a},RS=e=>e?Gh(e):Gh;var By={exports:{}},Uy={},Vy={exports:{}},Hy={};/**
59
59
  * @license React
60
60
  * use-sync-external-store-shim.production.min.js
61
61
  *
@@ -63,7 +63,7 @@ Error generating stack: `+s.message+`
63
63
  *
64
64
  * This source code is licensed under the MIT license found in the
65
65
  * LICENSE file in the root directory of this source tree.
66
- */var Qi=b;function RS(e,t){return e===t&&(e!==0||1/e===1/t)||e!==e&&t!==t}var NS=typeof Object.is=="function"?Object.is:RS,PS=Qi.useState,AS=Qi.useEffect,jS=Qi.useLayoutEffect,FS=Qi.useDebugValue;function $S(e,t){var n=t(),r=PS({inst:{value:n,getSnapshot:t}}),i=r[0].inst,s=r[1];return jS(function(){i.value=n,i.getSnapshot=t,cu(i)&&s({inst:i})},[e,n,t]),AS(function(){return cu(i)&&s({inst:i}),e(function(){cu(i)&&s({inst:i})})},[e]),FS(n),n}function cu(e){var t=e.getSnapshot;e=e.value;try{var n=t();return!NS(e,n)}catch{return!0}}function IS(e,t){return t()}var LS=typeof window>"u"||typeof window.document>"u"||typeof window.document.createElement>"u"?IS:$S;Hg.useSyncExternalStore=Qi.useSyncExternalStore!==void 0?Qi.useSyncExternalStore:LS;Vg.exports=Hg;var DS=Vg.exports;/**
66
+ */var Qi=b;function NS(e,t){return e===t&&(e!==0||1/e===1/t)||e!==e&&t!==t}var PS=typeof Object.is=="function"?Object.is:NS,AS=Qi.useState,jS=Qi.useEffect,FS=Qi.useLayoutEffect,$S=Qi.useDebugValue;function IS(e,t){var n=t(),r=AS({inst:{value:n,getSnapshot:t}}),i=r[0].inst,s=r[1];return FS(function(){i.value=n,i.getSnapshot=t,cu(i)&&s({inst:i})},[e,n,t]),jS(function(){return cu(i)&&s({inst:i}),e(function(){cu(i)&&s({inst:i})})},[e]),$S(n),n}function cu(e){var t=e.getSnapshot;e=e.value;try{var n=t();return!PS(e,n)}catch{return!0}}function DS(e,t){return t()}var LS=typeof window>"u"||typeof window.document>"u"||typeof window.document.createElement>"u"?DS:IS;Hy.useSyncExternalStore=Qi.useSyncExternalStore!==void 0?Qi.useSyncExternalStore:LS;Vy.exports=Hy;var MS=Vy.exports;/**
67
67
  * @license React
68
68
  * use-sync-external-store-shim/with-selector.production.min.js
69
69
  *
@@ -71,19 +71,19 @@ Error generating stack: `+s.message+`
71
71
  *
72
72
  * This source code is licensed under the MIT license found in the
73
73
  * LICENSE file in the root directory of this source tree.
74
- */var ca=b,MS=DS;function zS(e,t){return e===t&&(e!==0||1/e===1/t)||e!==e&&t!==t}var BS=typeof Object.is=="function"?Object.is:zS,US=MS.useSyncExternalStore,VS=ca.useRef,HS=ca.useEffect,WS=ca.useMemo,QS=ca.useDebugValue;Ug.useSyncExternalStoreWithSelector=function(e,t,n,r,i){var s=VS(null);if(s.current===null){var o={hasValue:!1,value:null};s.current=o}else o=s.current;s=WS(function(){function a(h){if(!c){if(c=!0,f=h,h=r(h),i!==void 0&&o.hasValue){var v=o.value;if(i(v,h))return u=v}return u=h}if(v=u,BS(f,h))return v;var w=r(h);return i!==void 0&&i(v,w)?v:(f=h,u=w)}var c=!1,f,u,d=n===void 0?null:n;return[function(){return a(t())},d===null?void 0:function(){return a(d())}]},[t,n,r,i]);var l=US(e,s[0],s[1]);return HS(function(){o.hasValue=!0,o.value=l},[l]),QS(l),l};Bg.exports=Ug;var qS=Bg.exports;const KS=Ki(qS),Wg={BASE_URL:"/",DEV:!1,MODE:"production",PROD:!0,SSR:!1},{useDebugValue:YS}=N,{useSyncExternalStoreWithSelector:GS}=KS;let Xh=!1;const XS=e=>e;function ZS(e,t=XS,n){(Wg?"production":void 0)!=="production"&&n&&!Xh&&(console.warn("[DEPRECATED] Use `createWithEqualityFn` instead of `create` or use `useStoreWithEqualityFn` instead of `useStore`. They can be imported from 'zustand/traditional'. https://github.com/pmndrs/zustand/discussions/1937"),Xh=!0);const r=GS(e.subscribe,e.getState,e.getServerState||e.getInitialState,t,n);return YS(r),r}const Zh=e=>{(Wg?"production":void 0)!=="production"&&typeof e!="function"&&console.warn("[DEPRECATED] Passing a vanilla store will be unsupported in a future version. Instead use `import { useStore } from 'zustand'`.");const t=typeof e=="function"?OS(e):e,n=(r,i)=>ZS(t,r,i);return Object.assign(n,t),n},JS=e=>e?Zh(e):Zh,gr=JS(e=>({widget:null,open:!1,defaultValues:{},setOpen:t=>e({open:t}),setWidget:t=>e({widget:t}),setDefaultValues:t=>e({defaultValues:t})})),eb={primary:{solid:"lc-text-white lc-btn lc-bg-blue-500 lc-border-blue-500 hover:lc-text-white hover:lc-bg-blue-600 hover:lc-border-blue-600 focus:lc-text-white focus:lc-bg-blue-600 focus:lc-border-blue-600 focus:lc-ring focus:lc-ring-blue-100 active:lc-text-white active:lc-bg-blue-600 active:lc-border-blue-600 active:lc-ring active:lc-ring-blue-100",soft:"lc-text-blue-500 lc-btn lc-bg-blue-100 hover:lc-text-white hover:lc-bg-blue-600 focus:lc-text-white focus:lc-bg-blue-600 focus:lc-ring focus:lc-ring-blue-100 active:lc-text-white active:lc-bg-blue-600 active:lc-ring active:lc-ring-blue-100",dashed:"lc-bg-white lc-border-dashed lc-text-blue-500 lc-btn lc-border-blue-500 hover:lc-text-blue-500 hover:lc-bg-blue-50 hover:lc-border-blue-600 focus:lc-text-blue-600 focus:lc-bg-blue-50 focus:lc-border-blue-600 active:lc-text-blue-600 active:lc-bg-blue-50 active:lc-border-blue-600",outline:"lc-bg-white lc-text-blue-500 lc-btn lc-border-blue-500 hover:lc-text-white hover:lc-bg-blue-600 hover:lc-border-blue-600 focus:lc-text-white focus:lc-bg-blue-600 focus:lc-border-blue-600 focus:lc-ring focus:lc-ring-blue-100 active:lc-text-white active:lc-bg-blue-600 active:lc-border-blue-600 active:lc-ring active:lc-ring-blue-100",ghost:"lc-bg-white lc-text-blue-500 lc-btn hover:lc-text-blue-500 hover:lc-bg-blue-100 focus:lc-text-blue-500 focus:lc-bg-blue-100 active:lc-text-blue-500 active:lc-bg-blue-100"},red:{solid:"lc-text-white lc-btn lc-bg-red-500 lc-border-red-500 hover:lc-text-white hover:lc-bg-red-600 hover:lc-border-red-600 focus:lc-text-white focus:lc-bg-red-600 focus:lc-border-red-600 focus:lc-ring focus:lc-ring-red-100 active:lc-text-white active:lc-bg-red-600 active:lc-border-red-600 active:lc-ring active:lc-ring-red-100",soft:"lc-text-red-500 lc-btn lc-bg-red-100 hover:lc-text-white hover:lc-bg-red-600 focus:lc-text-white focus:lc-bg-red-600 focus:lc-ring focus:lc-ring-red-100 active:lc-text-white active:lc-bg-red-600 active:lc-ring active:lc-ring-red-100",dashed:"lc-bg-white lc-border-dashed lc-text-red-500 lc-btn lc-border-red-500 hover:lc-text-red-500 hover:lc-bg-red-50 hover:lc-border-red-600 focus:lc-text-red-600 focus:lc-bg-red-50 focus:lc-border-red-600 active:lc-text-red-600 active:lc-bg-red-50 active:lc-border-red-600",outline:"lc-bg-white lc-text-red-500 lc-btn lc-border-red-500 hover:lc-text-white hover:lc-bg-red-600 hover:lc-border-red-600 focus:lc-text-white focus:lc-bg-red-600 focus:lc-border-red-600 focus:lc-ring focus:lc-ring-red-100 active:lc-text-white active:lc-bg-red-600 active:lc-border-red-600 active:lc-ring active:lc-ring-red-100",ghost:"lc-bg-white lc-text-red-500 lc-btn hover:lc-text-red-500 hover:lc-bg-red-100 focus:lc-text-red-500 focus:lc-bg-red-100 active:lc-text-red-500 active:lc-bg-red-100"}},tb={xs:{default:"lc-py-1 lc-text-xs lc-px-1.5",rounded:"lc-p-1.5 lc-text-xs"},sm:{default:"lc-px-2 lc-py-1.5 lc-text-xs",rounded:"lc-p-2 lc-text-xs"},md:{default:"lc-px-2.5 lc-py-2 lc-text-sm",rounded:"lc-p-2.5 lc-text-xs"},lg:{default:"lc-px-3 lc-py-2.5",rounded:"lc-p-3"},xl:{default:"lc-px-4 lc-py-2.5 lc-text-15",rounded:"lc-p-4 lc-text-15"},"2xl":{default:"lc-px-5 lc-py-3 lc-text-15",rounded:"lc-p-5 lc-text-15"}};var Qg={exports:{}};/*!
74
+ */var ca=b,zS=MS;function BS(e,t){return e===t&&(e!==0||1/e===1/t)||e!==e&&t!==t}var US=typeof Object.is=="function"?Object.is:BS,VS=zS.useSyncExternalStore,HS=ca.useRef,WS=ca.useEffect,QS=ca.useMemo,qS=ca.useDebugValue;Uy.useSyncExternalStoreWithSelector=function(e,t,n,r,i){var s=HS(null);if(s.current===null){var o={hasValue:!1,value:null};s.current=o}else o=s.current;s=QS(function(){function a(h){if(!c){if(c=!0,f=h,h=r(h),i!==void 0&&o.hasValue){var v=o.value;if(i(v,h))return u=v}return u=h}if(v=u,US(f,h))return v;var w=r(h);return i!==void 0&&i(v,w)?v:(f=h,u=w)}var c=!1,f,u,d=n===void 0?null:n;return[function(){return a(t())},d===null?void 0:function(){return a(d())}]},[t,n,r,i]);var l=VS(e,s[0],s[1]);return WS(function(){o.hasValue=!0,o.value=l},[l]),qS(l),l};By.exports=Uy;var KS=By.exports;const YS=Ki(KS),Wy={BASE_URL:"/",DEV:!1,MODE:"production",PROD:!0,SSR:!1},{useDebugValue:GS}=N,{useSyncExternalStoreWithSelector:XS}=YS;let Xh=!1;const ZS=e=>e;function JS(e,t=ZS,n){(Wy?"production":void 0)!=="production"&&n&&!Xh&&(console.warn("[DEPRECATED] Use `createWithEqualityFn` instead of `create` or use `useStoreWithEqualityFn` instead of `useStore`. They can be imported from 'zustand/traditional'. https://github.com/pmndrs/zustand/discussions/1937"),Xh=!0);const r=XS(e.subscribe,e.getState,e.getServerState||e.getInitialState,t,n);return GS(r),r}const Zh=e=>{(Wy?"production":void 0)!=="production"&&typeof e!="function"&&console.warn("[DEPRECATED] Passing a vanilla store will be unsupported in a future version. Instead use `import { useStore } from 'zustand'`.");const t=typeof e=="function"?RS(e):e,n=(r,i)=>JS(t,r,i);return Object.assign(n,t),n},eb=e=>e?Zh(e):Zh,yr=eb(e=>({widget:null,open:!1,defaultValues:{},setOpen:t=>e({open:t}),setWidget:t=>e({widget:t}),setDefaultValues:t=>e({defaultValues:t})})),tb={primary:{solid:"lc-text-white lc-btn lc-bg-blue-500 lc-border-blue-500 hover:lc-text-white hover:lc-bg-blue-600 hover:lc-border-blue-600 focus:lc-text-white focus:lc-bg-blue-600 focus:lc-border-blue-600 focus:lc-ring focus:lc-ring-blue-100 active:lc-text-white active:lc-bg-blue-600 active:lc-border-blue-600 active:lc-ring active:lc-ring-blue-100",soft:"lc-text-blue-500 lc-btn lc-bg-blue-100 hover:lc-text-white hover:lc-bg-blue-600 focus:lc-text-white focus:lc-bg-blue-600 focus:lc-ring focus:lc-ring-blue-100 active:lc-text-white active:lc-bg-blue-600 active:lc-ring active:lc-ring-blue-100",dashed:"lc-bg-white lc-border-dashed lc-text-blue-500 lc-btn lc-border-blue-500 hover:lc-text-blue-500 hover:lc-bg-blue-50 hover:lc-border-blue-600 focus:lc-text-blue-600 focus:lc-bg-blue-50 focus:lc-border-blue-600 active:lc-text-blue-600 active:lc-bg-blue-50 active:lc-border-blue-600",outline:"lc-bg-white lc-text-blue-500 lc-btn lc-border-blue-500 hover:lc-text-white hover:lc-bg-blue-600 hover:lc-border-blue-600 focus:lc-text-white focus:lc-bg-blue-600 focus:lc-border-blue-600 focus:lc-ring focus:lc-ring-blue-100 active:lc-text-white active:lc-bg-blue-600 active:lc-border-blue-600 active:lc-ring active:lc-ring-blue-100",ghost:"lc-bg-white lc-text-blue-500 lc-btn hover:lc-text-blue-500 hover:lc-bg-blue-100 focus:lc-text-blue-500 focus:lc-bg-blue-100 active:lc-text-blue-500 active:lc-bg-blue-100"},red:{solid:"lc-text-white lc-btn lc-bg-red-500 lc-border-red-500 hover:lc-text-white hover:lc-bg-red-600 hover:lc-border-red-600 focus:lc-text-white focus:lc-bg-red-600 focus:lc-border-red-600 focus:lc-ring focus:lc-ring-red-100 active:lc-text-white active:lc-bg-red-600 active:lc-border-red-600 active:lc-ring active:lc-ring-red-100",soft:"lc-text-red-500 lc-btn lc-bg-red-100 hover:lc-text-white hover:lc-bg-red-600 focus:lc-text-white focus:lc-bg-red-600 focus:lc-ring focus:lc-ring-red-100 active:lc-text-white active:lc-bg-red-600 active:lc-ring active:lc-ring-red-100",dashed:"lc-bg-white lc-border-dashed lc-text-red-500 lc-btn lc-border-red-500 hover:lc-text-red-500 hover:lc-bg-red-50 hover:lc-border-red-600 focus:lc-text-red-600 focus:lc-bg-red-50 focus:lc-border-red-600 active:lc-text-red-600 active:lc-bg-red-50 active:lc-border-red-600",outline:"lc-bg-white lc-text-red-500 lc-btn lc-border-red-500 hover:lc-text-white hover:lc-bg-red-600 hover:lc-border-red-600 focus:lc-text-white focus:lc-bg-red-600 focus:lc-border-red-600 focus:lc-ring focus:lc-ring-red-100 active:lc-text-white active:lc-bg-red-600 active:lc-border-red-600 active:lc-ring active:lc-ring-red-100",ghost:"lc-bg-white lc-text-red-500 lc-btn hover:lc-text-red-500 hover:lc-bg-red-100 focus:lc-text-red-500 focus:lc-bg-red-100 active:lc-text-red-500 active:lc-bg-red-100"}},nb={xs:{default:"lc-py-1 lc-text-xs lc-px-1.5",rounded:"lc-p-1.5 lc-text-xs"},sm:{default:"lc-px-2 lc-py-1.5 lc-text-xs",rounded:"lc-p-2 lc-text-xs"},md:{default:"lc-px-2.5 lc-py-2 lc-text-sm",rounded:"lc-p-2.5 lc-text-xs"},lg:{default:"lc-px-3 lc-py-2.5",rounded:"lc-p-3"},xl:{default:"lc-px-4 lc-py-2.5 lc-text-15",rounded:"lc-p-4 lc-text-15"},"2xl":{default:"lc-px-5 lc-py-3 lc-text-15",rounded:"lc-p-5 lc-text-15"}};var Qy={exports:{}};/*!
75
75
  Copyright (c) 2018 Jed Watson.
76
76
  Licensed under the MIT License (MIT), see
77
77
  http://jedwatson.github.io/classnames
78
- */(function(e){(function(){var t={}.hasOwnProperty;function n(){for(var s="",o=0;o<arguments.length;o++){var l=arguments[o];l&&(s=i(s,r(l)))}return s}function r(s){if(typeof s=="string"||typeof s=="number")return s;if(typeof s!="object")return"";if(Array.isArray(s))return n.apply(null,s);if(s.toString!==Object.prototype.toString&&!s.toString.toString().includes("[native code]"))return s.toString();var o="";for(var l in s)t.call(s,l)&&s[l]&&(o=i(o,l));return o}function i(s,o){return o?s?s+" "+o:s+o:s}e.exports?(n.default=n,e.exports=n):window.classNames=n})()})(Qg);var nb=Qg.exports;const qt=Ki(nb);function Gs({children:e,type:t="button",variant:n="primary",kind:r="solid",size:i="md",rounded:s=!1,className:o,...l}){return _.jsx("button",{type:t,className:qt("lc-flex lc-items-center lc-justify-center",{"lc-rounded-full":s,"lc-rounded-md":!s},o,eb[n][r],tb[i][s?"rounded":"default"]),...l,children:e})}function Ve(){}Ve.Home=function(t){return _.jsx("svg",{viewBox:"0 0 24 24",fill:"currentColor",height:"1em",width:"1em",...t,children:_.jsx("path",{d:"M3 13h1v7c0 1.103.897 2 2 2h12c1.103 0 2-.897 2-2v-7h1a1 1 0 00.707-1.707l-9-9a.999.999 0 00-1.414 0l-9 9A1 1 0 003 13zm7 7v-5h4v5h-4zm2-15.586l6 6V15l.001 5H16v-5c0-1.103-.897-2-2-2h-4c-1.103 0-2 .897-2 2v5H6v-9.586l6-6z"})})};Ve.Chat=e=>_.jsx("svg",{xmlns:"http://www.w3.org/2000/svg",fill:"none",viewBox:"0 0 24 24",strokeWidth:1.5,stroke:"currentColor",...e,children:_.jsx("path",{strokeLinecap:"round",strokeLinejoin:"round",d:"M7.5 8.25h9m-9 3H12m-9.75 1.51c0 1.6 1.123 2.994 2.707 3.227 1.129.166 2.27.293 3.423.379.35.026.67.21.865.501L12 21l2.755-4.133a1.14 1.14 0 0 1 .865-.501 48.172 48.172 0 0 0 3.423-.379c1.584-.233 2.707-1.626 2.707-3.228V6.741c0-1.602-1.123-2.995-2.707-3.228A48.394 48.394 0 0 0 12 3c-2.392 0-4.744.175-7.043.513C3.373 3.746 2.25 5.14 2.25 6.741v6.018Z"})});Ve.MessageTyping=({className:e="lc-size-5",...t})=>_.jsx("svg",{xmlns:"http://www.w3.org/2000/svg",fill:"none",viewBox:"0 0 24 24",strokeWidth:1.5,stroke:"currentColor",className:e,...t,children:_.jsx("path",{strokeLinecap:"round",strokeLinejoin:"round",d:"M8.625 9.75a.375.375 0 1 1-.75 0 .375.375 0 0 1 .75 0Zm0 0H8.25m4.125 0a.375.375 0 1 1-.75 0 .375.375 0 0 1 .75 0Zm0 0H12m4.125 0a.375.375 0 1 1-.75 0 .375.375 0 0 1 .75 0Zm0 0h-.375m-13.5 3.01c0 1.6 1.123 2.994 2.707 3.227 1.087.16 2.185.283 3.293.369V21l4.184-4.183a1.14 1.14 0 0 1 .778-.332 48.294 48.294 0 0 0 5.83-.498c1.585-.233 2.708-1.626 2.708-3.228V6.741c0-1.602-1.123-2.995-2.707-3.228A48.394 48.394 0 0 0 12 3c-2.392 0-4.744.175-7.043.513C3.373 3.746 2.25 5.14 2.25 6.741v6.018Z"})});Ve.Check=function(t){return _.jsx("svg",{fill:"currentColor",viewBox:"0 0 16 16",height:"1em",width:"1em",...t,children:_.jsx("path",{d:"M12.736 3.97a.733.733 0 011.047 0c.286.289.29.756.01 1.05L7.88 12.01a.733.733 0 01-1.065.02L3.217 8.384a.757.757 0 010-1.06.733.733 0 011.047 0l3.052 3.093 5.4-6.425a.247.247 0 01.02-.022z"})})};Ve.Website=function(t){return _.jsxs("svg",{fill:"none",viewBox:"0 0 24 24",height:"1em",width:"1em",...t,children:[_.jsx("path",{fill:"currentColor",fillRule:"evenodd",d:"M14 7a1 1 0 00-1 1v8a1 1 0 001 1h4a1 1 0 001-1V8a1 1 0 00-1-1h-4zm3 2h-2v6h2V9z",clipRule:"evenodd"}),_.jsx("path",{fill:"currentColor",d:"M6 7a1 1 0 000 2h4a1 1 0 100-2H6zM6 11a1 1 0 100 2h4a1 1 0 100-2H6zM5 16a1 1 0 011-1h4a1 1 0 110 2H6a1 1 0 01-1-1z"}),_.jsx("path",{fill:"currentColor",fillRule:"evenodd",d:"M4 3a3 3 0 00-3 3v12a3 3 0 003 3h16a3 3 0 003-3V6a3 3 0 00-3-3H4zm16 2H4a1 1 0 00-1 1v12a1 1 0 001 1h16a1 1 0 001-1V6a1 1 0 00-1-1z",clipRule:"evenodd"})]})};Ve.ArrowDown=e=>_.jsx("svg",{xmlns:"http://www.w3.org/2000/svg",fill:"none",viewBox:"0 0 24 24",strokeWidth:1.5,stroke:"currentColor",...e,children:_.jsx("path",{strokeLinecap:"round",strokeLinejoin:"round",d:"M19.5 13.5 12 21m0 0-7.5-7.5M12 21V3"})});Ve.XCircle=({className:e="lc-size-5",...t})=>_.jsx("svg",{xmlns:"http://www.w3.org/2000/svg",fill:"none",viewBox:"0 0 24 24",strokeWidth:1.5,stroke:"currentColor",className:e,...t,children:_.jsx("path",{strokeLinecap:"round",strokeLinejoin:"round",d:"m9.75 9.75 4.5 4.5m0-4.5-4.5 4.5M21 12a9 9 0 1 1-18 0 9 9 0 0 1 18 0Z"})});Ve.X=({className:e="lc-size-5",...t})=>_.jsx("svg",{xmlns:"http://www.w3.org/2000/svg",fill:"none",viewBox:"0 0 24 24",strokeWidth:1.5,stroke:"currentColor",className:e,...t,children:_.jsx("path",{strokeLinecap:"round",strokeLinejoin:"round",d:"M6 18 18 6M6 6l12 12"})});const dn=Object.create(null);dn.open="0";dn.close="1";dn.ping="2";dn.pong="3";dn.message="4";dn.upgrade="5";dn.noop="6";const sl=Object.create(null);Object.keys(dn).forEach(e=>{sl[dn[e]]=e});const Nc={type:"error",data:"parser error"},qg=typeof Blob=="function"||typeof Blob<"u"&&Object.prototype.toString.call(Blob)==="[object BlobConstructor]",Kg=typeof ArrayBuffer=="function",Yg=e=>typeof ArrayBuffer.isView=="function"?ArrayBuffer.isView(e):e&&e.buffer instanceof ArrayBuffer,Gf=({type:e,data:t},n,r)=>qg&&t instanceof Blob?n?r(t):Jh(t,r):Kg&&(t instanceof ArrayBuffer||Yg(t))?n?r(t):Jh(new Blob([t]),r):r(dn[e]+(t||"")),Jh=(e,t)=>{const n=new FileReader;return n.onload=function(){const r=n.result.split(",")[1];t("b"+(r||""))},n.readAsDataURL(e)};function ep(e){return e instanceof Uint8Array?e:e instanceof ArrayBuffer?new Uint8Array(e):new Uint8Array(e.buffer,e.byteOffset,e.byteLength)}let fu;function rb(e,t){if(qg&&e.data instanceof Blob)return e.data.arrayBuffer().then(ep).then(t);if(Kg&&(e.data instanceof ArrayBuffer||Yg(e.data)))return t(ep(e.data));Gf(e,!1,n=>{fu||(fu=new TextEncoder),t(fu.encode(n))})}const tp="ABCDEFGHIJKLMNOPQRSTUVWXYZabcdefghijklmnopqrstuvwxyz0123456789+/",ws=typeof Uint8Array>"u"?[]:new Uint8Array(256);for(let e=0;e<tp.length;e++)ws[tp.charCodeAt(e)]=e;const ib=e=>{let t=e.length*.75,n=e.length,r,i=0,s,o,l,a;e[e.length-1]==="="&&(t--,e[e.length-2]==="="&&t--);const c=new ArrayBuffer(t),f=new Uint8Array(c);for(r=0;r<n;r+=4)s=ws[e.charCodeAt(r)],o=ws[e.charCodeAt(r+1)],l=ws[e.charCodeAt(r+2)],a=ws[e.charCodeAt(r+3)],f[i++]=s<<2|o>>4,f[i++]=(o&15)<<4|l>>2,f[i++]=(l&3)<<6|a&63;return c},sb=typeof ArrayBuffer=="function",Xf=(e,t)=>{if(typeof e!="string")return{type:"message",data:Gg(e,t)};const n=e.charAt(0);return n==="b"?{type:"message",data:ob(e.substring(1),t)}:sl[n]?e.length>1?{type:sl[n],data:e.substring(1)}:{type:sl[n]}:Nc},ob=(e,t)=>{if(sb){const n=ib(e);return Gg(n,t)}else return{base64:!0,data:e}},Gg=(e,t)=>{switch(t){case"blob":return e instanceof Blob?e:new Blob([e]);case"arraybuffer":default:return e instanceof ArrayBuffer?e:e.buffer}},Xg="",lb=(e,t)=>{const n=e.length,r=new Array(n);let i=0;e.forEach((s,o)=>{Gf(s,!1,l=>{r[o]=l,++i===n&&t(r.join(Xg))})})},ab=(e,t)=>{const n=e.split(Xg),r=[];for(let i=0;i<n.length;i++){const s=Xf(n[i],t);if(r.push(s),s.type==="error")break}return r};function ub(){return new TransformStream({transform(e,t){rb(e,n=>{const r=n.length;let i;if(r<126)i=new Uint8Array(1),new DataView(i.buffer).setUint8(0,r);else if(r<65536){i=new Uint8Array(3);const s=new DataView(i.buffer);s.setUint8(0,126),s.setUint16(1,r)}else{i=new Uint8Array(9);const s=new DataView(i.buffer);s.setUint8(0,127),s.setBigUint64(1,BigInt(r))}e.data&&typeof e.data!="string"&&(i[0]|=128),t.enqueue(i),t.enqueue(n)})}})}let du;function zo(e){return e.reduce((t,n)=>t+n.length,0)}function Bo(e,t){if(e[0].length===t)return e.shift();const n=new Uint8Array(t);let r=0;for(let i=0;i<t;i++)n[i]=e[0][r++],r===e[0].length&&(e.shift(),r=0);return e.length&&r<e[0].length&&(e[0]=e[0].slice(r)),n}function cb(e,t){du||(du=new TextDecoder);const n=[];let r=0,i=-1,s=!1;return new TransformStream({transform(o,l){for(n.push(o);;){if(r===0){if(zo(n)<1)break;const a=Bo(n,1);s=(a[0]&128)===128,i=a[0]&127,i<126?r=3:i===126?r=1:r=2}else if(r===1){if(zo(n)<2)break;const a=Bo(n,2);i=new DataView(a.buffer,a.byteOffset,a.length).getUint16(0),r=3}else if(r===2){if(zo(n)<8)break;const a=Bo(n,8),c=new DataView(a.buffer,a.byteOffset,a.length),f=c.getUint32(0);if(f>Math.pow(2,21)-1){l.enqueue(Nc);break}i=f*Math.pow(2,32)+c.getUint32(4),r=3}else{if(zo(n)<i)break;const a=Bo(n,i);l.enqueue(Xf(s?a:du.decode(a),t)),r=0}if(i===0||i>e){l.enqueue(Nc);break}}}})}const Zg=4;function be(e){if(e)return fb(e)}function fb(e){for(var t in be.prototype)e[t]=be.prototype[t];return e}be.prototype.on=be.prototype.addEventListener=function(e,t){return this._callbacks=this._callbacks||{},(this._callbacks["$"+e]=this._callbacks["$"+e]||[]).push(t),this};be.prototype.once=function(e,t){function n(){this.off(e,n),t.apply(this,arguments)}return n.fn=t,this.on(e,n),this};be.prototype.off=be.prototype.removeListener=be.prototype.removeAllListeners=be.prototype.removeEventListener=function(e,t){if(this._callbacks=this._callbacks||{},arguments.length==0)return this._callbacks={},this;var n=this._callbacks["$"+e];if(!n)return this;if(arguments.length==1)return delete this._callbacks["$"+e],this;for(var r,i=0;i<n.length;i++)if(r=n[i],r===t||r.fn===t){n.splice(i,1);break}return n.length===0&&delete this._callbacks["$"+e],this};be.prototype.emit=function(e){this._callbacks=this._callbacks||{};for(var t=new Array(arguments.length-1),n=this._callbacks["$"+e],r=1;r<arguments.length;r++)t[r-1]=arguments[r];if(n){n=n.slice(0);for(var r=0,i=n.length;r<i;++r)n[r].apply(this,t)}return this};be.prototype.emitReserved=be.prototype.emit;be.prototype.listeners=function(e){return this._callbacks=this._callbacks||{},this._callbacks["$"+e]||[]};be.prototype.hasListeners=function(e){return!!this.listeners(e).length};const fa=typeof Promise=="function"&&typeof Promise.resolve=="function"?t=>Promise.resolve().then(t):(t,n)=>n(t,0),Pt=typeof self<"u"?self:typeof window<"u"?window:Function("return this")(),db="arraybuffer";function Jg(e,...t){return t.reduce((n,r)=>(e.hasOwnProperty(r)&&(n[r]=e[r]),n),{})}const hb=Pt.setTimeout,pb=Pt.clearTimeout;function da(e,t){t.useNativeTimers?(e.setTimeoutFn=hb.bind(Pt),e.clearTimeoutFn=pb.bind(Pt)):(e.setTimeoutFn=Pt.setTimeout.bind(Pt),e.clearTimeoutFn=Pt.clearTimeout.bind(Pt))}const mb=1.33;function gb(e){return typeof e=="string"?yb(e):Math.ceil((e.byteLength||e.size)*mb)}function yb(e){let t=0,n=0;for(let r=0,i=e.length;r<i;r++)t=e.charCodeAt(r),t<128?n+=1:t<2048?n+=2:t<55296||t>=57344?n+=3:(r++,n+=4);return n}function ey(){return Date.now().toString(36).substring(3)+Math.random().toString(36).substring(2,5)}function vb(e){let t="";for(let n in e)e.hasOwnProperty(n)&&(t.length&&(t+="&"),t+=encodeURIComponent(n)+"="+encodeURIComponent(e[n]));return t}function wb(e){let t={},n=e.split("&");for(let r=0,i=n.length;r<i;r++){let s=n[r].split("=");t[decodeURIComponent(s[0])]=decodeURIComponent(s[1])}return t}class xb extends Error{constructor(t,n,r){super(t),this.description=n,this.context=r,this.type="TransportError"}}class Zf extends be{constructor(t){super(),this.writable=!1,da(this,t),this.opts=t,this.query=t.query,this.socket=t.socket,this.supportsBinary=!t.forceBase64}onError(t,n,r){return super.emitReserved("error",new xb(t,n,r)),this}open(){return this.readyState="opening",this.doOpen(),this}close(){return(this.readyState==="opening"||this.readyState==="open")&&(this.doClose(),this.onClose()),this}send(t){this.readyState==="open"&&this.write(t)}onOpen(){this.readyState="open",this.writable=!0,super.emitReserved("open")}onData(t){const n=Xf(t,this.socket.binaryType);this.onPacket(n)}onPacket(t){super.emitReserved("packet",t)}onClose(t){this.readyState="closed",super.emitReserved("close",t)}pause(t){}createUri(t,n={}){return t+"://"+this._hostname()+this._port()+this.opts.path+this._query(n)}_hostname(){const t=this.opts.hostname;return t.indexOf(":")===-1?t:"["+t+"]"}_port(){return this.opts.port&&(this.opts.secure&&+(this.opts.port!==443)||!this.opts.secure&&Number(this.opts.port)!==80)?":"+this.opts.port:""}_query(t){const n=vb(t);return n.length?"?"+n:""}}class Sb extends Zf{constructor(){super(...arguments),this._polling=!1}get name(){return"polling"}doOpen(){this._poll()}pause(t){this.readyState="pausing";const n=()=>{this.readyState="paused",t()};if(this._polling||!this.writable){let r=0;this._polling&&(r++,this.once("pollComplete",function(){--r||n()})),this.writable||(r++,this.once("drain",function(){--r||n()}))}else n()}_poll(){this._polling=!0,this.doPoll(),this.emitReserved("poll")}onData(t){const n=r=>{if(this.readyState==="opening"&&r.type==="open"&&this.onOpen(),r.type==="close")return this.onClose({description:"transport closed by the server"}),!1;this.onPacket(r)};ab(t,this.socket.binaryType).forEach(n),this.readyState!=="closed"&&(this._polling=!1,this.emitReserved("pollComplete"),this.readyState==="open"&&this._poll())}doClose(){const t=()=>{this.write([{type:"close"}])};this.readyState==="open"?t():this.once("open",t)}write(t){this.writable=!1,lb(t,n=>{this.doWrite(n,()=>{this.writable=!0,this.emitReserved("drain")})})}uri(){const t=this.opts.secure?"https":"http",n=this.query||{};return this.opts.timestampRequests!==!1&&(n[this.opts.timestampParam]=ey()),!this.supportsBinary&&!n.sid&&(n.b64=1),this.createUri(t,n)}}let ty=!1;try{ty=typeof XMLHttpRequest<"u"&&"withCredentials"in new XMLHttpRequest}catch{}const bb=ty;function Eb(){}class _b extends Sb{constructor(t){if(super(t),typeof location<"u"){const n=location.protocol==="https:";let r=location.port;r||(r=n?"443":"80"),this.xd=typeof location<"u"&&t.hostname!==location.hostname||r!==t.port}}doWrite(t,n){const r=this.request({method:"POST",data:t});r.on("success",n),r.on("error",(i,s)=>{this.onError("xhr post error",i,s)})}doPoll(){const t=this.request();t.on("data",this.onData.bind(this)),t.on("error",(n,r)=>{this.onError("xhr poll error",n,r)}),this.pollXhr=t}}class cn extends be{constructor(t,n,r){super(),this.createRequest=t,da(this,r),this._opts=r,this._method=r.method||"GET",this._uri=n,this._data=r.data!==void 0?r.data:null,this._create()}_create(){var t;const n=Jg(this._opts,"agent","pfx","key","passphrase","cert","ca","ciphers","rejectUnauthorized","autoUnref");n.xdomain=!!this._opts.xd;const r=this._xhr=this.createRequest(n);try{r.open(this._method,this._uri,!0);try{if(this._opts.extraHeaders){r.setDisableHeaderCheck&&r.setDisableHeaderCheck(!0);for(let i in this._opts.extraHeaders)this._opts.extraHeaders.hasOwnProperty(i)&&r.setRequestHeader(i,this._opts.extraHeaders[i])}}catch{}if(this._method==="POST")try{r.setRequestHeader("Content-type","text/plain;charset=UTF-8")}catch{}try{r.setRequestHeader("Accept","*/*")}catch{}(t=this._opts.cookieJar)===null||t===void 0||t.addCookies(r),"withCredentials"in r&&(r.withCredentials=this._opts.withCredentials),this._opts.requestTimeout&&(r.timeout=this._opts.requestTimeout),r.onreadystatechange=()=>{var i;r.readyState===3&&((i=this._opts.cookieJar)===null||i===void 0||i.parseCookies(r.getResponseHeader("set-cookie"))),r.readyState===4&&(r.status===200||r.status===1223?this._onLoad():this.setTimeoutFn(()=>{this._onError(typeof r.status=="number"?r.status:0)},0))},r.send(this._data)}catch(i){this.setTimeoutFn(()=>{this._onError(i)},0);return}typeof document<"u"&&(this._index=cn.requestsCount++,cn.requests[this._index]=this)}_onError(t){this.emitReserved("error",t,this._xhr),this._cleanup(!0)}_cleanup(t){if(!(typeof this._xhr>"u"||this._xhr===null)){if(this._xhr.onreadystatechange=Eb,t)try{this._xhr.abort()}catch{}typeof document<"u"&&delete cn.requests[this._index],this._xhr=null}}_onLoad(){const t=this._xhr.responseText;t!==null&&(this.emitReserved("data",t),this.emitReserved("success"),this._cleanup())}abort(){this._cleanup()}}cn.requestsCount=0;cn.requests={};if(typeof document<"u"){if(typeof attachEvent=="function")attachEvent("onunload",np);else if(typeof addEventListener=="function"){const e="onpagehide"in Pt?"pagehide":"unload";addEventListener(e,np,!1)}}function np(){for(let e in cn.requests)cn.requests.hasOwnProperty(e)&&cn.requests[e].abort()}const kb=function(){const e=ny({xdomain:!1});return e&&e.responseType!==null}();class Cb extends _b{constructor(t){super(t);const n=t&&t.forceBase64;this.supportsBinary=kb&&!n}request(t={}){return Object.assign(t,{xd:this.xd},this.opts),new cn(ny,this.uri(),t)}}function ny(e){const t=e.xdomain;try{if(typeof XMLHttpRequest<"u"&&(!t||bb))return new XMLHttpRequest}catch{}if(!t)try{return new Pt[["Active"].concat("Object").join("X")]("Microsoft.XMLHTTP")}catch{}}const ry=typeof navigator<"u"&&typeof navigator.product=="string"&&navigator.product.toLowerCase()==="reactnative";class Tb extends Zf{get name(){return"websocket"}doOpen(){const t=this.uri(),n=this.opts.protocols,r=ry?{}:Jg(this.opts,"agent","perMessageDeflate","pfx","key","passphrase","cert","ca","ciphers","rejectUnauthorized","localAddress","protocolVersion","origin","maxPayload","family","checkServerIdentity");this.opts.extraHeaders&&(r.headers=this.opts.extraHeaders);try{this.ws=this.createSocket(t,n,r)}catch(i){return this.emitReserved("error",i)}this.ws.binaryType=this.socket.binaryType,this.addEventListeners()}addEventListeners(){this.ws.onopen=()=>{this.opts.autoUnref&&this.ws._socket.unref(),this.onOpen()},this.ws.onclose=t=>this.onClose({description:"websocket connection closed",context:t}),this.ws.onmessage=t=>this.onData(t.data),this.ws.onerror=t=>this.onError("websocket error",t)}write(t){this.writable=!1;for(let n=0;n<t.length;n++){const r=t[n],i=n===t.length-1;Gf(r,this.supportsBinary,s=>{try{this.doWrite(r,s)}catch{}i&&fa(()=>{this.writable=!0,this.emitReserved("drain")},this.setTimeoutFn)})}}doClose(){typeof this.ws<"u"&&(this.ws.onerror=()=>{},this.ws.close(),this.ws=null)}uri(){const t=this.opts.secure?"wss":"ws",n=this.query||{};return this.opts.timestampRequests&&(n[this.opts.timestampParam]=ey()),this.supportsBinary||(n.b64=1),this.createUri(t,n)}}const hu=Pt.WebSocket||Pt.MozWebSocket;class Ob extends Tb{createSocket(t,n,r){return ry?new hu(t,n,r):n?new hu(t,n):new hu(t)}doWrite(t,n){this.ws.send(n)}}class Rb extends Zf{get name(){return"webtransport"}doOpen(){try{this._transport=new WebTransport(this.createUri("https"),this.opts.transportOptions[this.name])}catch(t){return this.emitReserved("error",t)}this._transport.closed.then(()=>{this.onClose()}).catch(t=>{this.onError("webtransport error",t)}),this._transport.ready.then(()=>{this._transport.createBidirectionalStream().then(t=>{const n=cb(Number.MAX_SAFE_INTEGER,this.socket.binaryType),r=t.readable.pipeThrough(n).getReader(),i=ub();i.readable.pipeTo(t.writable),this._writer=i.writable.getWriter();const s=()=>{r.read().then(({done:l,value:a})=>{l||(this.onPacket(a),s())}).catch(l=>{})};s();const o={type:"open"};this.query.sid&&(o.data=`{"sid":"${this.query.sid}"}`),this._writer.write(o).then(()=>this.onOpen())})})}write(t){this.writable=!1;for(let n=0;n<t.length;n++){const r=t[n],i=n===t.length-1;this._writer.write(r).then(()=>{i&&fa(()=>{this.writable=!0,this.emitReserved("drain")},this.setTimeoutFn)})}}doClose(){var t;(t=this._transport)===null||t===void 0||t.close()}}const Nb={websocket:Ob,webtransport:Rb,polling:Cb},Pb=/^(?:(?![^:@\/?#]+:[^:@\/]*@)(http|https|ws|wss):\/\/)?((?:(([^:@\/?#]*)(?::([^:@\/?#]*))?)?@)?((?:[a-f0-9]{0,4}:){2,7}[a-f0-9]{0,4}|[^:\/?#]*)(?::(\d*))?)(((\/(?:[^?#](?![^?#\/]*\.[^?#\/.]+(?:[?#]|$)))*\/?)?([^?#\/]*))(?:\?([^#]*))?(?:#(.*))?)/,Ab=["source","protocol","authority","userInfo","user","password","host","port","relative","path","directory","file","query","anchor"];function Pc(e){if(e.length>8e3)throw"URI too long";const t=e,n=e.indexOf("["),r=e.indexOf("]");n!=-1&&r!=-1&&(e=e.substring(0,n)+e.substring(n,r).replace(/:/g,";")+e.substring(r,e.length));let i=Pb.exec(e||""),s={},o=14;for(;o--;)s[Ab[o]]=i[o]||"";return n!=-1&&r!=-1&&(s.source=t,s.host=s.host.substring(1,s.host.length-1).replace(/;/g,":"),s.authority=s.authority.replace("[","").replace("]","").replace(/;/g,":"),s.ipv6uri=!0),s.pathNames=jb(s,s.path),s.queryKey=Fb(s,s.query),s}function jb(e,t){const n=/\/{2,9}/g,r=t.replace(n,"/").split("/");return(t.slice(0,1)=="/"||t.length===0)&&r.splice(0,1),t.slice(-1)=="/"&&r.splice(r.length-1,1),r}function Fb(e,t){const n={};return t.replace(/(?:^|&)([^&=]*)=?([^&]*)/g,function(r,i,s){i&&(n[i]=s)}),n}const Ac=typeof addEventListener=="function"&&typeof removeEventListener=="function",ol=[];Ac&&addEventListener("offline",()=>{ol.forEach(e=>e())},!1);class ar extends be{constructor(t,n){if(super(),this.binaryType=db,this.writeBuffer=[],this._prevBufferLen=0,this._pingInterval=-1,this._pingTimeout=-1,this._maxPayload=-1,this._pingTimeoutTime=1/0,t&&typeof t=="object"&&(n=t,t=null),t){const r=Pc(t);n.hostname=r.host,n.secure=r.protocol==="https"||r.protocol==="wss",n.port=r.port,r.query&&(n.query=r.query)}else n.host&&(n.hostname=Pc(n.host).host);da(this,n),this.secure=n.secure!=null?n.secure:typeof location<"u"&&location.protocol==="https:",n.hostname&&!n.port&&(n.port=this.secure?"443":"80"),this.hostname=n.hostname||(typeof location<"u"?location.hostname:"localhost"),this.port=n.port||(typeof location<"u"&&location.port?location.port:this.secure?"443":"80"),this.transports=[],this._transportsByName={},n.transports.forEach(r=>{const i=r.prototype.name;this.transports.push(i),this._transportsByName[i]=r}),this.opts=Object.assign({path:"/engine.io",agent:!1,withCredentials:!1,upgrade:!0,timestampParam:"t",rememberUpgrade:!1,addTrailingSlash:!0,rejectUnauthorized:!0,perMessageDeflate:{threshold:1024},transportOptions:{},closeOnBeforeunload:!1},n),this.opts.path=this.opts.path.replace(/\/$/,"")+(this.opts.addTrailingSlash?"/":""),typeof this.opts.query=="string"&&(this.opts.query=wb(this.opts.query)),Ac&&(this.opts.closeOnBeforeunload&&(this._beforeunloadEventListener=()=>{this.transport&&(this.transport.removeAllListeners(),this.transport.close())},addEventListener("beforeunload",this._beforeunloadEventListener,!1)),this.hostname!=="localhost"&&(this._offlineEventListener=()=>{this._onClose("transport close",{description:"network connection lost"})},ol.push(this._offlineEventListener))),this.opts.withCredentials&&(this._cookieJar=void 0),this._open()}createTransport(t){const n=Object.assign({},this.opts.query);n.EIO=Zg,n.transport=t,this.id&&(n.sid=this.id);const r=Object.assign({},this.opts,{query:n,socket:this,hostname:this.hostname,secure:this.secure,port:this.port},this.opts.transportOptions[t]);return new this._transportsByName[t](r)}_open(){if(this.transports.length===0){this.setTimeoutFn(()=>{this.emitReserved("error","No transports available")},0);return}const t=this.opts.rememberUpgrade&&ar.priorWebsocketSuccess&&this.transports.indexOf("websocket")!==-1?"websocket":this.transports[0];this.readyState="opening";const n=this.createTransport(t);n.open(),this.setTransport(n)}setTransport(t){this.transport&&this.transport.removeAllListeners(),this.transport=t,t.on("drain",this._onDrain.bind(this)).on("packet",this._onPacket.bind(this)).on("error",this._onError.bind(this)).on("close",n=>this._onClose("transport close",n))}onOpen(){this.readyState="open",ar.priorWebsocketSuccess=this.transport.name==="websocket",this.emitReserved("open"),this.flush()}_onPacket(t){if(this.readyState==="opening"||this.readyState==="open"||this.readyState==="closing")switch(this.emitReserved("packet",t),this.emitReserved("heartbeat"),t.type){case"open":this.onHandshake(JSON.parse(t.data));break;case"ping":this._sendPacket("pong"),this.emitReserved("ping"),this.emitReserved("pong"),this._resetPingTimeout();break;case"error":const n=new Error("server error");n.code=t.data,this._onError(n);break;case"message":this.emitReserved("data",t.data),this.emitReserved("message",t.data);break}}onHandshake(t){this.emitReserved("handshake",t),this.id=t.sid,this.transport.query.sid=t.sid,this._pingInterval=t.pingInterval,this._pingTimeout=t.pingTimeout,this._maxPayload=t.maxPayload,this.onOpen(),this.readyState!=="closed"&&this._resetPingTimeout()}_resetPingTimeout(){this.clearTimeoutFn(this._pingTimeoutTimer);const t=this._pingInterval+this._pingTimeout;this._pingTimeoutTime=Date.now()+t,this._pingTimeoutTimer=this.setTimeoutFn(()=>{this._onClose("ping timeout")},t),this.opts.autoUnref&&this._pingTimeoutTimer.unref()}_onDrain(){this.writeBuffer.splice(0,this._prevBufferLen),this._prevBufferLen=0,this.writeBuffer.length===0?this.emitReserved("drain"):this.flush()}flush(){if(this.readyState!=="closed"&&this.transport.writable&&!this.upgrading&&this.writeBuffer.length){const t=this._getWritablePackets();this.transport.send(t),this._prevBufferLen=t.length,this.emitReserved("flush")}}_getWritablePackets(){if(!(this._maxPayload&&this.transport.name==="polling"&&this.writeBuffer.length>1))return this.writeBuffer;let n=1;for(let r=0;r<this.writeBuffer.length;r++){const i=this.writeBuffer[r].data;if(i&&(n+=gb(i)),r>0&&n>this._maxPayload)return this.writeBuffer.slice(0,r);n+=2}return this.writeBuffer}_hasPingExpired(){if(!this._pingTimeoutTime)return!0;const t=Date.now()>this._pingTimeoutTime;return t&&(this._pingTimeoutTime=0,fa(()=>{this._onClose("ping timeout")},this.setTimeoutFn)),t}write(t,n,r){return this._sendPacket("message",t,n,r),this}send(t,n,r){return this._sendPacket("message",t,n,r),this}_sendPacket(t,n,r,i){if(typeof n=="function"&&(i=n,n=void 0),typeof r=="function"&&(i=r,r=null),this.readyState==="closing"||this.readyState==="closed")return;r=r||{},r.compress=r.compress!==!1;const s={type:t,data:n,options:r};this.emitReserved("packetCreate",s),this.writeBuffer.push(s),i&&this.once("flush",i),this.flush()}close(){const t=()=>{this._onClose("forced close"),this.transport.close()},n=()=>{this.off("upgrade",n),this.off("upgradeError",n),t()},r=()=>{this.once("upgrade",n),this.once("upgradeError",n)};return(this.readyState==="opening"||this.readyState==="open")&&(this.readyState="closing",this.writeBuffer.length?this.once("drain",()=>{this.upgrading?r():t()}):this.upgrading?r():t()),this}_onError(t){if(ar.priorWebsocketSuccess=!1,this.opts.tryAllTransports&&this.transports.length>1&&this.readyState==="opening")return this.transports.shift(),this._open();this.emitReserved("error",t),this._onClose("transport error",t)}_onClose(t,n){if(this.readyState==="opening"||this.readyState==="open"||this.readyState==="closing"){if(this.clearTimeoutFn(this._pingTimeoutTimer),this.transport.removeAllListeners("close"),this.transport.close(),this.transport.removeAllListeners(),Ac&&(this._beforeunloadEventListener&&removeEventListener("beforeunload",this._beforeunloadEventListener,!1),this._offlineEventListener)){const r=ol.indexOf(this._offlineEventListener);r!==-1&&ol.splice(r,1)}this.readyState="closed",this.id=null,this.emitReserved("close",t,n),this.writeBuffer=[],this._prevBufferLen=0}}}ar.protocol=Zg;class $b extends ar{constructor(){super(...arguments),this._upgrades=[]}onOpen(){if(super.onOpen(),this.readyState==="open"&&this.opts.upgrade)for(let t=0;t<this._upgrades.length;t++)this._probe(this._upgrades[t])}_probe(t){let n=this.createTransport(t),r=!1;ar.priorWebsocketSuccess=!1;const i=()=>{r||(n.send([{type:"ping",data:"probe"}]),n.once("packet",u=>{if(!r)if(u.type==="pong"&&u.data==="probe"){if(this.upgrading=!0,this.emitReserved("upgrading",n),!n)return;ar.priorWebsocketSuccess=n.name==="websocket",this.transport.pause(()=>{r||this.readyState!=="closed"&&(f(),this.setTransport(n),n.send([{type:"upgrade"}]),this.emitReserved("upgrade",n),n=null,this.upgrading=!1,this.flush())})}else{const d=new Error("probe error");d.transport=n.name,this.emitReserved("upgradeError",d)}}))};function s(){r||(r=!0,f(),n.close(),n=null)}const o=u=>{const d=new Error("probe error: "+u);d.transport=n.name,s(),this.emitReserved("upgradeError",d)};function l(){o("transport closed")}function a(){o("socket closed")}function c(u){n&&u.name!==n.name&&s()}const f=()=>{n.removeListener("open",i),n.removeListener("error",o),n.removeListener("close",l),this.off("close",a),this.off("upgrading",c)};n.once("open",i),n.once("error",o),n.once("close",l),this.once("close",a),this.once("upgrading",c),this._upgrades.indexOf("webtransport")!==-1&&t!=="webtransport"?this.setTimeoutFn(()=>{r||n.open()},200):n.open()}onHandshake(t){this._upgrades=this._filterUpgrades(t.upgrades),super.onHandshake(t)}_filterUpgrades(t){const n=[];for(let r=0;r<t.length;r++)~this.transports.indexOf(t[r])&&n.push(t[r]);return n}}let Ib=class extends $b{constructor(t,n={}){const r=typeof t=="object"?t:n;(!r.transports||r.transports&&typeof r.transports[0]=="string")&&(r.transports=(r.transports||["polling","websocket","webtransport"]).map(i=>Nb[i]).filter(i=>!!i)),super(t,r)}};function Lb(e,t="",n){let r=e;n=n||typeof location<"u"&&location,e==null&&(e=n.protocol+"//"+n.host),typeof e=="string"&&(e.charAt(0)==="/"&&(e.charAt(1)==="/"?e=n.protocol+e:e=n.host+e),/^(https?|wss?):\/\//.test(e)||(typeof n<"u"?e=n.protocol+"//"+e:e="https://"+e),r=Pc(e)),r.port||(/^(http|ws)$/.test(r.protocol)?r.port="80":/^(http|ws)s$/.test(r.protocol)&&(r.port="443")),r.path=r.path||"/";const s=r.host.indexOf(":")!==-1?"["+r.host+"]":r.host;return r.id=r.protocol+"://"+s+":"+r.port+t,r.href=r.protocol+"://"+s+(n&&n.port===r.port?"":":"+r.port),r}const Db=typeof ArrayBuffer=="function",Mb=e=>typeof ArrayBuffer.isView=="function"?ArrayBuffer.isView(e):e.buffer instanceof ArrayBuffer,iy=Object.prototype.toString,zb=typeof Blob=="function"||typeof Blob<"u"&&iy.call(Blob)==="[object BlobConstructor]",Bb=typeof File=="function"||typeof File<"u"&&iy.call(File)==="[object FileConstructor]";function Jf(e){return Db&&(e instanceof ArrayBuffer||Mb(e))||zb&&e instanceof Blob||Bb&&e instanceof File}function ll(e,t){if(!e||typeof e!="object")return!1;if(Array.isArray(e)){for(let n=0,r=e.length;n<r;n++)if(ll(e[n]))return!0;return!1}if(Jf(e))return!0;if(e.toJSON&&typeof e.toJSON=="function"&&arguments.length===1)return ll(e.toJSON(),!0);for(const n in e)if(Object.prototype.hasOwnProperty.call(e,n)&&ll(e[n]))return!0;return!1}function Ub(e){const t=[],n=e.data,r=e;return r.data=jc(n,t),r.attachments=t.length,{packet:r,buffers:t}}function jc(e,t){if(!e)return e;if(Jf(e)){const n={_placeholder:!0,num:t.length};return t.push(e),n}else if(Array.isArray(e)){const n=new Array(e.length);for(let r=0;r<e.length;r++)n[r]=jc(e[r],t);return n}else if(typeof e=="object"&&!(e instanceof Date)){const n={};for(const r in e)Object.prototype.hasOwnProperty.call(e,r)&&(n[r]=jc(e[r],t));return n}return e}function Vb(e,t){return e.data=Fc(e.data,t),delete e.attachments,e}function Fc(e,t){if(!e)return e;if(e&&e._placeholder===!0){if(typeof e.num=="number"&&e.num>=0&&e.num<t.length)return t[e.num];throw new Error("illegal attachments")}else if(Array.isArray(e))for(let n=0;n<e.length;n++)e[n]=Fc(e[n],t);else if(typeof e=="object")for(const n in e)Object.prototype.hasOwnProperty.call(e,n)&&(e[n]=Fc(e[n],t));return e}const Hb=["connect","connect_error","disconnect","disconnecting","newListener","removeListener"],Wb=5;var X;(function(e){e[e.CONNECT=0]="CONNECT",e[e.DISCONNECT=1]="DISCONNECT",e[e.EVENT=2]="EVENT",e[e.ACK=3]="ACK",e[e.CONNECT_ERROR=4]="CONNECT_ERROR",e[e.BINARY_EVENT=5]="BINARY_EVENT",e[e.BINARY_ACK=6]="BINARY_ACK"})(X||(X={}));class Qb{constructor(t){this.replacer=t}encode(t){return(t.type===X.EVENT||t.type===X.ACK)&&ll(t)?this.encodeAsBinary({type:t.type===X.EVENT?X.BINARY_EVENT:X.BINARY_ACK,nsp:t.nsp,data:t.data,id:t.id}):[this.encodeAsString(t)]}encodeAsString(t){let n=""+t.type;return(t.type===X.BINARY_EVENT||t.type===X.BINARY_ACK)&&(n+=t.attachments+"-"),t.nsp&&t.nsp!=="/"&&(n+=t.nsp+","),t.id!=null&&(n+=t.id),t.data!=null&&(n+=JSON.stringify(t.data,this.replacer)),n}encodeAsBinary(t){const n=Ub(t),r=this.encodeAsString(n.packet),i=n.buffers;return i.unshift(r),i}}function rp(e){return Object.prototype.toString.call(e)==="[object Object]"}class ed extends be{constructor(t){super(),this.reviver=t}add(t){let n;if(typeof t=="string"){if(this.reconstructor)throw new Error("got plaintext data when reconstructing a packet");n=this.decodeString(t);const r=n.type===X.BINARY_EVENT;r||n.type===X.BINARY_ACK?(n.type=r?X.EVENT:X.ACK,this.reconstructor=new qb(n),n.attachments===0&&super.emitReserved("decoded",n)):super.emitReserved("decoded",n)}else if(Jf(t)||t.base64)if(this.reconstructor)n=this.reconstructor.takeBinaryData(t),n&&(this.reconstructor=null,super.emitReserved("decoded",n));else throw new Error("got binary data when not reconstructing a packet");else throw new Error("Unknown type: "+t)}decodeString(t){let n=0;const r={type:Number(t.charAt(0))};if(X[r.type]===void 0)throw new Error("unknown packet type "+r.type);if(r.type===X.BINARY_EVENT||r.type===X.BINARY_ACK){const s=n+1;for(;t.charAt(++n)!=="-"&&n!=t.length;);const o=t.substring(s,n);if(o!=Number(o)||t.charAt(n)!=="-")throw new Error("Illegal attachments");r.attachments=Number(o)}if(t.charAt(n+1)==="/"){const s=n+1;for(;++n&&!(t.charAt(n)===","||n===t.length););r.nsp=t.substring(s,n)}else r.nsp="/";const i=t.charAt(n+1);if(i!==""&&Number(i)==i){const s=n+1;for(;++n;){const o=t.charAt(n);if(o==null||Number(o)!=o){--n;break}if(n===t.length)break}r.id=Number(t.substring(s,n+1))}if(t.charAt(++n)){const s=this.tryParse(t.substr(n));if(ed.isPayloadValid(r.type,s))r.data=s;else throw new Error("invalid payload")}return r}tryParse(t){try{return JSON.parse(t,this.reviver)}catch{return!1}}static isPayloadValid(t,n){switch(t){case X.CONNECT:return rp(n);case X.DISCONNECT:return n===void 0;case X.CONNECT_ERROR:return typeof n=="string"||rp(n);case X.EVENT:case X.BINARY_EVENT:return Array.isArray(n)&&(typeof n[0]=="number"||typeof n[0]=="string"&&Hb.indexOf(n[0])===-1);case X.ACK:case X.BINARY_ACK:return Array.isArray(n)}}destroy(){this.reconstructor&&(this.reconstructor.finishedReconstruction(),this.reconstructor=null)}}class qb{constructor(t){this.packet=t,this.buffers=[],this.reconPack=t}takeBinaryData(t){if(this.buffers.push(t),this.buffers.length===this.reconPack.attachments){const n=Vb(this.reconPack,this.buffers);return this.finishedReconstruction(),n}return null}finishedReconstruction(){this.reconPack=null,this.buffers=[]}}const Kb=Object.freeze(Object.defineProperty({__proto__:null,Decoder:ed,Encoder:Qb,get PacketType(){return X},protocol:Wb},Symbol.toStringTag,{value:"Module"}));function Vt(e,t,n){return e.on(t,n),function(){e.off(t,n)}}const Yb=Object.freeze({connect:1,connect_error:1,disconnect:1,disconnecting:1,newListener:1,removeListener:1});class sy extends be{constructor(t,n,r){super(),this.connected=!1,this.recovered=!1,this.receiveBuffer=[],this.sendBuffer=[],this._queue=[],this._queueSeq=0,this.ids=0,this.acks={},this.flags={},this.io=t,this.nsp=n,r&&r.auth&&(this.auth=r.auth),this._opts=Object.assign({},r),this.io._autoConnect&&this.open()}get disconnected(){return!this.connected}subEvents(){if(this.subs)return;const t=this.io;this.subs=[Vt(t,"open",this.onopen.bind(this)),Vt(t,"packet",this.onpacket.bind(this)),Vt(t,"error",this.onerror.bind(this)),Vt(t,"close",this.onclose.bind(this))]}get active(){return!!this.subs}connect(){return this.connected?this:(this.subEvents(),this.io._reconnecting||this.io.open(),this.io._readyState==="open"&&this.onopen(),this)}open(){return this.connect()}send(...t){return t.unshift("message"),this.emit.apply(this,t),this}emit(t,...n){var r,i,s;if(Yb.hasOwnProperty(t))throw new Error('"'+t.toString()+'" is a reserved event name');if(n.unshift(t),this._opts.retries&&!this.flags.fromQueue&&!this.flags.volatile)return this._addToQueue(n),this;const o={type:X.EVENT,data:n};if(o.options={},o.options.compress=this.flags.compress!==!1,typeof n[n.length-1]=="function"){const f=this.ids++,u=n.pop();this._registerAckCallback(f,u),o.id=f}const l=(i=(r=this.io.engine)===null||r===void 0?void 0:r.transport)===null||i===void 0?void 0:i.writable,a=this.connected&&!(!((s=this.io.engine)===null||s===void 0)&&s._hasPingExpired());return this.flags.volatile&&!l||(a?(this.notifyOutgoingListeners(o),this.packet(o)):this.sendBuffer.push(o)),this.flags={},this}_registerAckCallback(t,n){var r;const i=(r=this.flags.timeout)!==null&&r!==void 0?r:this._opts.ackTimeout;if(i===void 0){this.acks[t]=n;return}const s=this.io.setTimeoutFn(()=>{delete this.acks[t];for(let l=0;l<this.sendBuffer.length;l++)this.sendBuffer[l].id===t&&this.sendBuffer.splice(l,1);n.call(this,new Error("operation has timed out"))},i),o=(...l)=>{this.io.clearTimeoutFn(s),n.apply(this,l)};o.withError=!0,this.acks[t]=o}emitWithAck(t,...n){return new Promise((r,i)=>{const s=(o,l)=>o?i(o):r(l);s.withError=!0,n.push(s),this.emit(t,...n)})}_addToQueue(t){let n;typeof t[t.length-1]=="function"&&(n=t.pop());const r={id:this._queueSeq++,tryCount:0,pending:!1,args:t,flags:Object.assign({fromQueue:!0},this.flags)};t.push((i,...s)=>r!==this._queue[0]?void 0:(i!==null?r.tryCount>this._opts.retries&&(this._queue.shift(),n&&n(i)):(this._queue.shift(),n&&n(null,...s)),r.pending=!1,this._drainQueue())),this._queue.push(r),this._drainQueue()}_drainQueue(t=!1){if(!this.connected||this._queue.length===0)return;const n=this._queue[0];n.pending&&!t||(n.pending=!0,n.tryCount++,this.flags=n.flags,this.emit.apply(this,n.args))}packet(t){t.nsp=this.nsp,this.io._packet(t)}onopen(){typeof this.auth=="function"?this.auth(t=>{this._sendConnectPacket(t)}):this._sendConnectPacket(this.auth)}_sendConnectPacket(t){this.packet({type:X.CONNECT,data:this._pid?Object.assign({pid:this._pid,offset:this._lastOffset},t):t})}onerror(t){this.connected||this.emitReserved("connect_error",t)}onclose(t,n){this.connected=!1,delete this.id,this.emitReserved("disconnect",t,n),this._clearAcks()}_clearAcks(){Object.keys(this.acks).forEach(t=>{if(!this.sendBuffer.some(r=>String(r.id)===t)){const r=this.acks[t];delete this.acks[t],r.withError&&r.call(this,new Error("socket has been disconnected"))}})}onpacket(t){if(t.nsp===this.nsp)switch(t.type){case X.CONNECT:t.data&&t.data.sid?this.onconnect(t.data.sid,t.data.pid):this.emitReserved("connect_error",new Error("It seems you are trying to reach a Socket.IO server in v2.x with a v3.x client, but they are not compatible (more information here: https://socket.io/docs/v3/migrating-from-2-x-to-3-0/)"));break;case X.EVENT:case X.BINARY_EVENT:this.onevent(t);break;case X.ACK:case X.BINARY_ACK:this.onack(t);break;case X.DISCONNECT:this.ondisconnect();break;case X.CONNECT_ERROR:this.destroy();const r=new Error(t.data.message);r.data=t.data.data,this.emitReserved("connect_error",r);break}}onevent(t){const n=t.data||[];t.id!=null&&n.push(this.ack(t.id)),this.connected?this.emitEvent(n):this.receiveBuffer.push(Object.freeze(n))}emitEvent(t){if(this._anyListeners&&this._anyListeners.length){const n=this._anyListeners.slice();for(const r of n)r.apply(this,t)}super.emit.apply(this,t),this._pid&&t.length&&typeof t[t.length-1]=="string"&&(this._lastOffset=t[t.length-1])}ack(t){const n=this;let r=!1;return function(...i){r||(r=!0,n.packet({type:X.ACK,id:t,data:i}))}}onack(t){const n=this.acks[t.id];typeof n=="function"&&(delete this.acks[t.id],n.withError&&t.data.unshift(null),n.apply(this,t.data))}onconnect(t,n){this.id=t,this.recovered=n&&this._pid===n,this._pid=n,this.connected=!0,this.emitBuffered(),this.emitReserved("connect"),this._drainQueue(!0)}emitBuffered(){this.receiveBuffer.forEach(t=>this.emitEvent(t)),this.receiveBuffer=[],this.sendBuffer.forEach(t=>{this.notifyOutgoingListeners(t),this.packet(t)}),this.sendBuffer=[]}ondisconnect(){this.destroy(),this.onclose("io server disconnect")}destroy(){this.subs&&(this.subs.forEach(t=>t()),this.subs=void 0),this.io._destroy(this)}disconnect(){return this.connected&&this.packet({type:X.DISCONNECT}),this.destroy(),this.connected&&this.onclose("io client disconnect"),this}close(){return this.disconnect()}compress(t){return this.flags.compress=t,this}get volatile(){return this.flags.volatile=!0,this}timeout(t){return this.flags.timeout=t,this}onAny(t){return this._anyListeners=this._anyListeners||[],this._anyListeners.push(t),this}prependAny(t){return this._anyListeners=this._anyListeners||[],this._anyListeners.unshift(t),this}offAny(t){if(!this._anyListeners)return this;if(t){const n=this._anyListeners;for(let r=0;r<n.length;r++)if(t===n[r])return n.splice(r,1),this}else this._anyListeners=[];return this}listenersAny(){return this._anyListeners||[]}onAnyOutgoing(t){return this._anyOutgoingListeners=this._anyOutgoingListeners||[],this._anyOutgoingListeners.push(t),this}prependAnyOutgoing(t){return this._anyOutgoingListeners=this._anyOutgoingListeners||[],this._anyOutgoingListeners.unshift(t),this}offAnyOutgoing(t){if(!this._anyOutgoingListeners)return this;if(t){const n=this._anyOutgoingListeners;for(let r=0;r<n.length;r++)if(t===n[r])return n.splice(r,1),this}else this._anyOutgoingListeners=[];return this}listenersAnyOutgoing(){return this._anyOutgoingListeners||[]}notifyOutgoingListeners(t){if(this._anyOutgoingListeners&&this._anyOutgoingListeners.length){const n=this._anyOutgoingListeners.slice();for(const r of n)r.apply(this,t.data)}}}function es(e){e=e||{},this.ms=e.min||100,this.max=e.max||1e4,this.factor=e.factor||2,this.jitter=e.jitter>0&&e.jitter<=1?e.jitter:0,this.attempts=0}es.prototype.duration=function(){var e=this.ms*Math.pow(this.factor,this.attempts++);if(this.jitter){var t=Math.random(),n=Math.floor(t*this.jitter*e);e=Math.floor(t*10)&1?e+n:e-n}return Math.min(e,this.max)|0};es.prototype.reset=function(){this.attempts=0};es.prototype.setMin=function(e){this.ms=e};es.prototype.setMax=function(e){this.max=e};es.prototype.setJitter=function(e){this.jitter=e};class $c extends be{constructor(t,n){var r;super(),this.nsps={},this.subs=[],t&&typeof t=="object"&&(n=t,t=void 0),n=n||{},n.path=n.path||"/socket.io",this.opts=n,da(this,n),this.reconnection(n.reconnection!==!1),this.reconnectionAttempts(n.reconnectionAttempts||1/0),this.reconnectionDelay(n.reconnectionDelay||1e3),this.reconnectionDelayMax(n.reconnectionDelayMax||5e3),this.randomizationFactor((r=n.randomizationFactor)!==null&&r!==void 0?r:.5),this.backoff=new es({min:this.reconnectionDelay(),max:this.reconnectionDelayMax(),jitter:this.randomizationFactor()}),this.timeout(n.timeout==null?2e4:n.timeout),this._readyState="closed",this.uri=t;const i=n.parser||Kb;this.encoder=new i.Encoder,this.decoder=new i.Decoder,this._autoConnect=n.autoConnect!==!1,this._autoConnect&&this.open()}reconnection(t){return arguments.length?(this._reconnection=!!t,t||(this.skipReconnect=!0),this):this._reconnection}reconnectionAttempts(t){return t===void 0?this._reconnectionAttempts:(this._reconnectionAttempts=t,this)}reconnectionDelay(t){var n;return t===void 0?this._reconnectionDelay:(this._reconnectionDelay=t,(n=this.backoff)===null||n===void 0||n.setMin(t),this)}randomizationFactor(t){var n;return t===void 0?this._randomizationFactor:(this._randomizationFactor=t,(n=this.backoff)===null||n===void 0||n.setJitter(t),this)}reconnectionDelayMax(t){var n;return t===void 0?this._reconnectionDelayMax:(this._reconnectionDelayMax=t,(n=this.backoff)===null||n===void 0||n.setMax(t),this)}timeout(t){return arguments.length?(this._timeout=t,this):this._timeout}maybeReconnectOnOpen(){!this._reconnecting&&this._reconnection&&this.backoff.attempts===0&&this.reconnect()}open(t){if(~this._readyState.indexOf("open"))return this;this.engine=new Ib(this.uri,this.opts);const n=this.engine,r=this;this._readyState="opening",this.skipReconnect=!1;const i=Vt(n,"open",function(){r.onopen(),t&&t()}),s=l=>{this.cleanup(),this._readyState="closed",this.emitReserved("error",l),t?t(l):this.maybeReconnectOnOpen()},o=Vt(n,"error",s);if(this._timeout!==!1){const l=this._timeout,a=this.setTimeoutFn(()=>{i(),s(new Error("timeout")),n.close()},l);this.opts.autoUnref&&a.unref(),this.subs.push(()=>{this.clearTimeoutFn(a)})}return this.subs.push(i),this.subs.push(o),this}connect(t){return this.open(t)}onopen(){this.cleanup(),this._readyState="open",this.emitReserved("open");const t=this.engine;this.subs.push(Vt(t,"ping",this.onping.bind(this)),Vt(t,"data",this.ondata.bind(this)),Vt(t,"error",this.onerror.bind(this)),Vt(t,"close",this.onclose.bind(this)),Vt(this.decoder,"decoded",this.ondecoded.bind(this)))}onping(){this.emitReserved("ping")}ondata(t){try{this.decoder.add(t)}catch(n){this.onclose("parse error",n)}}ondecoded(t){fa(()=>{this.emitReserved("packet",t)},this.setTimeoutFn)}onerror(t){this.emitReserved("error",t)}socket(t,n){let r=this.nsps[t];return r?this._autoConnect&&!r.active&&r.connect():(r=new sy(this,t,n),this.nsps[t]=r),r}_destroy(t){const n=Object.keys(this.nsps);for(const r of n)if(this.nsps[r].active)return;this._close()}_packet(t){const n=this.encoder.encode(t);for(let r=0;r<n.length;r++)this.engine.write(n[r],t.options)}cleanup(){this.subs.forEach(t=>t()),this.subs.length=0,this.decoder.destroy()}_close(){this.skipReconnect=!0,this._reconnecting=!1,this.onclose("forced close")}disconnect(){return this._close()}onclose(t,n){var r;this.cleanup(),(r=this.engine)===null||r===void 0||r.close(),this.backoff.reset(),this._readyState="closed",this.emitReserved("close",t,n),this._reconnection&&!this.skipReconnect&&this.reconnect()}reconnect(){if(this._reconnecting||this.skipReconnect)return this;const t=this;if(this.backoff.attempts>=this._reconnectionAttempts)this.backoff.reset(),this.emitReserved("reconnect_failed"),this._reconnecting=!1;else{const n=this.backoff.duration();this._reconnecting=!0;const r=this.setTimeoutFn(()=>{t.skipReconnect||(this.emitReserved("reconnect_attempt",t.backoff.attempts),!t.skipReconnect&&t.open(i=>{i?(t._reconnecting=!1,t.reconnect(),this.emitReserved("reconnect_error",i)):t.onreconnect()}))},n);this.opts.autoUnref&&r.unref(),this.subs.push(()=>{this.clearTimeoutFn(r)})}}onreconnect(){const t=this.backoff.attempts;this._reconnecting=!1,this.backoff.reset(),this.emitReserved("reconnect",t)}}const ds={};function al(e,t){typeof e=="object"&&(t=e,e=void 0),t=t||{};const n=Lb(e,t.path||"/socket.io"),r=n.source,i=n.id,s=n.path,o=ds[i]&&s in ds[i].nsps,l=t.forceNew||t["force new connection"]||t.multiplex===!1||o;let a;return l?a=new $c(r,t):(ds[i]||(ds[i]=new $c(r,t)),a=ds[i]),n.query&&!t.query&&(t.query=n.queryKey),a.socket(n.path,t)}Object.assign(al,{Manager:$c,Socket:sy,io:al,connect:al});const ul=e=>{const t=document.cookie.split(";").find(n=>n.includes(e));return t?t.split("=")[1]:null},oy=b.createContext(null),uo=()=>b.useContext(oy),Gb=({children:e})=>{const[t,n]=b.useState(null),[r,i]=b.useState(!1),[s,o]=b.useState({}),l=()=>{const h=al(Qw,{transports:["websocket"],auth:{customer_token:ul("customer_token"),device_id:ul("device_id"),customer_refresh_token:ul("customer_refresh_token")}});h.on("error",v=>{console.error("Websocket error",v)}),h.on("connect",()=>{n(h),i(!0)})},a=()=>{t&&(t.connect(),i(!0))},c=()=>{t&&(t.disconnect(),i(!1))},f=(h,v)=>{t&&(t.on(h,w=>{v(w)}),o({...s,[h]:v}))},u=h=>{t&&s[h]&&(t.off(h,s[h]),delete s[h])},d=(h,v,w)=>{t&&t.emit(h,v,w)};return _.jsx(oy.Provider,{value:{socket:t,connected:r,events:s,connect:l,reconnect:a,disconnect:c,on:f,off:u,emit:d},children:e})};var fn=(e=>(e.ChatView="chat:user:view",e.ChatClose="chat:user:close",e.MessageList="message:list",e.MessageCreate="message:create",e.MessageTyping="message:typing",e.WidgetOpen="widget:open",e.WidgetClose="widget:close",e.PageChange="page-change",e))(fn||{}),Qt=(e=>(e.MessageAgentCreate="message:agent:create",e.MessageAgentTyping="message:agent:typing",e.Banned="banned",e.ChatUserClose="chat:user:close",e.ChatUserAssignee="chat:user:assignee",e))(Qt||{});const td=e=>{const t=lS(),n=(r,i)=>{var o;const s=((o=EO.find(l=>l.name===r))==null?void 0:o.path)??"/";return typeof i=="object"&&s.includes(":")?Object.entries(i).reduce((l,[a,c])=>l.replace(`:${a}`,c),s):i?`${s}?${i}`:s};return{push:(r,i)=>{t(n(r,i),e)},path:n}},Xb=()=>Ox({mutationFn:e=>oa(`clients/${e.client_id}/chats`,{method:"POST",body:JSON.stringify({inputs:e.inputs,client_id:void 0,widget_id:e.widget_id,history:e.history})})}),Zb=e=>oa(`clients/${e}/chats`),zl=e=>oa(`clients/${e}/chats`,{method:"DELETE"});function ly({children:e,defaultOpen:t}){var u,d,h,v;const n=uo(),{open:r,setOpen:i,widget:s}=gr(),o=td(),l=()=>{i(!0),n&&n.emit(fn.WidgetOpen,{})},a=()=>{i(!1),n&&n.emit(fn.WidgetClose,{})},c=()=>{i(!1),zl(s.client_id),o.push("registration")},f=async()=>{i(!1),await zl(s.client_id),o.push("registration")};return b.useEffect(()=>{if(t&&i(!0),!(!n||!s))return n.on(Qt.Banned,c),n.on(Qt.ChatUserClose,f),()=>{n.off(Qt.Banned),n.off(Qt.ChatUserClose)}},[]),_.jsxs("section",{className:"lc-relative lc-w-full lc-h-full",children:[r&&_.jsx("div",{style:{width:((d=(u=s==null?void 0:s.appearance)==null?void 0:u.design)==null?void 0:d.width)||"22.5rem",height:((v=(h=s==null?void 0:s.appearance)==null?void 0:h.design)==null?void 0:v.height)||"32rem"},className:"lc-absolute lc-bottom-8 lc-right-8 lc-z-[300] lc-bg-white lc-rounded-md lc-border",children:e}),_.jsxs("div",{className:"lc-absolute lc-bottom-0 lc-right-0 lc-z-[400]",children:[!r&&_.jsx(Gs,{size:"lg",rounded:!0,onClick:l,children:_.jsx(Ve.Chat,{className:"lc-size-6"})}),r&&_.jsx(Gs,{size:"lg",rounded:!0,onClick:a,children:_.jsx(Ve.X,{className:"lc-size-6"})})]})]})}function Xr(e){this._maxSize=e,this.clear()}Xr.prototype.clear=function(){this._size=0,this._values=Object.create(null)};Xr.prototype.get=function(e){return this._values[e]};Xr.prototype.set=function(e,t){return this._size>=this._maxSize&&this.clear(),e in this._values||this._size++,this._values[e]=t};var Jb=/[^.^\]^[]+|(?=\[\]|\.\.)/g,ay=/^\d+$/,eE=/^\d/,tE=/[~`!#$%\^&*+=\-\[\]\\';,/{}|\\":<>\?]/g,nE=/^\s*(['"]?)(.*?)(\1)\s*$/,nd=512,ip=new Xr(nd),sp=new Xr(nd),op=new Xr(nd),Dr={Cache:Xr,split:Ic,normalizePath:pu,setter:function(e){var t=pu(e);return sp.get(e)||sp.set(e,function(r,i){for(var s=0,o=t.length,l=r;s<o-1;){var a=t[s];if(a==="__proto__"||a==="constructor"||a==="prototype")return r;l=l[t[s++]]}l[t[s]]=i})},getter:function(e,t){var n=pu(e);return op.get(e)||op.set(e,function(i){for(var s=0,o=n.length;s<o;)if(i!=null||!t)i=i[n[s++]];else return;return i})},join:function(e){return e.reduce(function(t,n){return t+(rd(n)||ay.test(n)?"["+n+"]":(t?".":"")+n)},"")},forEach:function(e,t,n){rE(Array.isArray(e)?e:Ic(e),t,n)}};function pu(e){return ip.get(e)||ip.set(e,Ic(e).map(function(t){return t.replace(nE,"$2")}))}function Ic(e){return e.match(Jb)||[""]}function rE(e,t,n){var r=e.length,i,s,o,l;for(s=0;s<r;s++)i=e[s],i&&(oE(i)&&(i='"'+i+'"'),l=rd(i),o=!l&&/^\d+$/.test(i),t.call(n,i,l,o,s,e))}function rd(e){return typeof e=="string"&&e&&["'",'"'].indexOf(e.charAt(0))!==-1}function iE(e){return e.match(eE)&&!e.match(ay)}function sE(e){return tE.test(e)}function oE(e){return!rd(e)&&(iE(e)||sE(e))}const lE=/[A-Z\xc0-\xd6\xd8-\xde]?[a-z\xdf-\xf6\xf8-\xff]+(?:['’](?:d|ll|m|re|s|t|ve))?(?=[\xac\xb1\xd7\xf7\x00-\x2f\x3a-\x40\x5b-\x60\x7b-\xbf\u2000-\u206f \t\x0b\f\xa0\ufeff\n\r\u2028\u2029\u1680\u180e\u2000\u2001\u2002\u2003\u2004\u2005\u2006\u2007\u2008\u2009\u200a\u202f\u205f\u3000]|[A-Z\xc0-\xd6\xd8-\xde]|$)|(?:[A-Z\xc0-\xd6\xd8-\xde]|[^\ud800-\udfff\xac\xb1\xd7\xf7\x00-\x2f\x3a-\x40\x5b-\x60\x7b-\xbf\u2000-\u206f \t\x0b\f\xa0\ufeff\n\r\u2028\u2029\u1680\u180e\u2000\u2001\u2002\u2003\u2004\u2005\u2006\u2007\u2008\u2009\u200a\u202f\u205f\u3000\d+\u2700-\u27bfa-z\xdf-\xf6\xf8-\xffA-Z\xc0-\xd6\xd8-\xde])+(?:['’](?:D|LL|M|RE|S|T|VE))?(?=[\xac\xb1\xd7\xf7\x00-\x2f\x3a-\x40\x5b-\x60\x7b-\xbf\u2000-\u206f \t\x0b\f\xa0\ufeff\n\r\u2028\u2029\u1680\u180e\u2000\u2001\u2002\u2003\u2004\u2005\u2006\u2007\u2008\u2009\u200a\u202f\u205f\u3000]|[A-Z\xc0-\xd6\xd8-\xde](?:[a-z\xdf-\xf6\xf8-\xff]|[^\ud800-\udfff\xac\xb1\xd7\xf7\x00-\x2f\x3a-\x40\x5b-\x60\x7b-\xbf\u2000-\u206f \t\x0b\f\xa0\ufeff\n\r\u2028\u2029\u1680\u180e\u2000\u2001\u2002\u2003\u2004\u2005\u2006\u2007\u2008\u2009\u200a\u202f\u205f\u3000\d+\u2700-\u27bfa-z\xdf-\xf6\xf8-\xffA-Z\xc0-\xd6\xd8-\xde])|$)|[A-Z\xc0-\xd6\xd8-\xde]?(?:[a-z\xdf-\xf6\xf8-\xff]|[^\ud800-\udfff\xac\xb1\xd7\xf7\x00-\x2f\x3a-\x40\x5b-\x60\x7b-\xbf\u2000-\u206f \t\x0b\f\xa0\ufeff\n\r\u2028\u2029\u1680\u180e\u2000\u2001\u2002\u2003\u2004\u2005\u2006\u2007\u2008\u2009\u200a\u202f\u205f\u3000\d+\u2700-\u27bfa-z\xdf-\xf6\xf8-\xffA-Z\xc0-\xd6\xd8-\xde])+(?:['’](?:d|ll|m|re|s|t|ve))?|[A-Z\xc0-\xd6\xd8-\xde]+(?:['’](?:D|LL|M|RE|S|T|VE))?|\d*(?:1ST|2ND|3RD|(?![123])\dTH)(?=\b|[a-z_])|\d*(?:1st|2nd|3rd|(?![123])\dth)(?=\b|[A-Z_])|\d+|(?:[\u2700-\u27bf]|(?:\ud83c[\udde6-\uddff]){2}|[\ud800-\udbff][\udc00-\udfff])[\ufe0e\ufe0f]?(?:[\u0300-\u036f\ufe20-\ufe2f\u20d0-\u20ff]|\ud83c[\udffb-\udfff])?(?:\u200d(?:[^\ud800-\udfff]|(?:\ud83c[\udde6-\uddff]){2}|[\ud800-\udbff][\udc00-\udfff])[\ufe0e\ufe0f]?(?:[\u0300-\u036f\ufe20-\ufe2f\u20d0-\u20ff]|\ud83c[\udffb-\udfff])?)*/g,ha=e=>e.match(lE)||[],pa=e=>e[0].toUpperCase()+e.slice(1),id=(e,t)=>ha(e).join(t).toLowerCase(),uy=e=>ha(e).reduce((t,n)=>`${t}${t?n[0].toUpperCase()+n.slice(1).toLowerCase():n.toLowerCase()}`,""),aE=e=>pa(uy(e)),uE=e=>id(e,"_"),cE=e=>id(e,"-"),fE=e=>pa(id(e," ")),dE=e=>ha(e).map(pa).join(" ");var mu={words:ha,upperFirst:pa,camelCase:uy,pascalCase:aE,snakeCase:uE,kebabCase:cE,sentenceCase:fE,titleCase:dE},sd={exports:{}};sd.exports=function(e){return cy(hE(e),e)};sd.exports.array=cy;function cy(e,t){var n=e.length,r=new Array(n),i={},s=n,o=pE(t),l=mE(e);for(t.forEach(function(c){if(!l.has(c[0])||!l.has(c[1]))throw new Error("Unknown node. There is an unknown node in the supplied edges.")});s--;)i[s]||a(e[s],s,new Set);return r;function a(c,f,u){if(u.has(c)){var d;try{d=", node was:"+JSON.stringify(c)}catch{d=""}throw new Error("Cyclic dependency"+d)}if(!l.has(c))throw new Error("Found unknown node. Make sure to provided all involved nodes. Unknown node: "+JSON.stringify(c));if(!i[f]){i[f]=!0;var h=o.get(c)||new Set;if(h=Array.from(h),f=h.length){u.add(c);do{var v=h[--f];a(v,l.get(v),u)}while(f);u.delete(c)}r[--n]=c}}}function hE(e){for(var t=new Set,n=0,r=e.length;n<r;n++){var i=e[n];t.add(i[0]),t.add(i[1])}return Array.from(t)}function pE(e){for(var t=new Map,n=0,r=e.length;n<r;n++){var i=e[n];t.has(i[0])||t.set(i[0],new Set),t.has(i[1])||t.set(i[1],new Set),t.get(i[0]).add(i[1])}return t}function mE(e){for(var t=new Map,n=0,r=e.length;n<r;n++)t.set(e[n],n);return t}var gE=sd.exports;const yE=Ki(gE),vE=Object.prototype.toString,wE=Error.prototype.toString,xE=RegExp.prototype.toString,SE=typeof Symbol<"u"?Symbol.prototype.toString:()=>"",bE=/^Symbol\((.*)\)(.*)$/;function EE(e){return e!=+e?"NaN":e===0&&1/e<0?"-0":""+e}function lp(e,t=!1){if(e==null||e===!0||e===!1)return""+e;const n=typeof e;if(n==="number")return EE(e);if(n==="string")return t?`"${e}"`:e;if(n==="function")return"[Function "+(e.name||"anonymous")+"]";if(n==="symbol")return SE.call(e).replace(bE,"Symbol($1)");const r=vE.call(e).slice(8,-1);return r==="Date"?isNaN(e.getTime())?""+e:e.toISOString(e):r==="Error"||e instanceof Error?"["+wE.call(e)+"]":r==="RegExp"?xE.call(e):null}function ur(e,t){let n=lp(e,t);return n!==null?n:JSON.stringify(e,function(r,i){let s=lp(this[r],t);return s!==null?s:i},2)}function fy(e){return e==null?[]:[].concat(e)}let dy,hy,py,_E=/\$\{\s*(\w+)\s*\}/g;dy=Symbol.toStringTag;class ap{constructor(t,n,r,i){this.name=void 0,this.message=void 0,this.value=void 0,this.path=void 0,this.type=void 0,this.params=void 0,this.errors=void 0,this.inner=void 0,this[dy]="Error",this.name="ValidationError",this.value=n,this.path=r,this.type=i,this.errors=[],this.inner=[],fy(t).forEach(s=>{if(st.isError(s)){this.errors.push(...s.errors);const o=s.inner.length?s.inner:[s];this.inner.push(...o)}else this.errors.push(s)}),this.message=this.errors.length>1?`${this.errors.length} errors occurred`:this.errors[0]}}hy=Symbol.hasInstance;py=Symbol.toStringTag;class st extends Error{static formatError(t,n){const r=n.label||n.path||"this";return n=Object.assign({},n,{path:r,originalPath:n.path}),typeof t=="string"?t.replace(_E,(i,s)=>ur(n[s])):typeof t=="function"?t(n):t}static isError(t){return t&&t.name==="ValidationError"}constructor(t,n,r,i,s){const o=new ap(t,n,r,i);if(s)return o;super(),this.value=void 0,this.path=void 0,this.type=void 0,this.params=void 0,this.errors=[],this.inner=[],this[py]="Error",this.name=o.name,this.message=o.message,this.type=o.type,this.value=o.value,this.path=o.path,this.errors=o.errors,this.inner=o.inner,Error.captureStackTrace&&Error.captureStackTrace(this,st)}static[hy](t){return ap[Symbol.hasInstance](t)||super[Symbol.hasInstance](t)}}let tn={default:"${path} is invalid",required:"${path} is a required field",defined:"${path} must be defined",notNull:"${path} cannot be null",oneOf:"${path} must be one of the following values: ${values}",notOneOf:"${path} must not be one of the following values: ${values}",notType:({path:e,type:t,value:n,originalValue:r})=>{const i=r!=null&&r!==n?` (cast from the value \`${ur(r,!0)}\`).`:".";return t!=="mixed"?`${e} must be a \`${t}\` type, but the final value was: \`${ur(n,!0)}\``+i:`${e} must match the configured type. The validated value was: \`${ur(n,!0)}\``+i}},et={length:"${path} must be exactly ${length} characters",min:"${path} must be at least ${min} characters",max:"${path} must be at most ${max} characters",matches:'${path} must match the following: "${regex}"',email:"${path} must be a valid email",url:"${path} must be a valid URL",uuid:"${path} must be a valid UUID",datetime:"${path} must be a valid ISO date-time",datetime_precision:"${path} must be a valid ISO date-time with a sub-second precision of exactly ${precision} digits",datetime_offset:'${path} must be a valid ISO date-time with UTC "Z" timezone',trim:"${path} must be a trimmed string",lowercase:"${path} must be a lowercase string",uppercase:"${path} must be a upper case string"},kE={min:"${path} must be greater than or equal to ${min}",max:"${path} must be less than or equal to ${max}",lessThan:"${path} must be less than ${less}",moreThan:"${path} must be greater than ${more}",positive:"${path} must be a positive number",negative:"${path} must be a negative number",integer:"${path} must be an integer"},Lc={min:"${path} field must be later than ${min}",max:"${path} field must be at earlier than ${max}"},CE={isValue:"${path} field must be ${value}"},cl={noUnknown:"${path} field has unspecified keys: ${unknown}",exact:"${path} object contains unknown properties: ${properties}"},TE={min:"${path} field must have at least ${min} items",max:"${path} field must have less than or equal to ${max} items",length:"${path} must have ${length} items"},OE={notType:e=>{const{path:t,value:n,spec:r}=e,i=r.types.length;if(Array.isArray(n)){if(n.length<i)return`${t} tuple value has too few items, expected a length of ${i} but got ${n.length} for value: \`${ur(n,!0)}\``;if(n.length>i)return`${t} tuple value has too many items, expected a length of ${i} but got ${n.length} for value: \`${ur(n,!0)}\``}return st.formatError(tn.notType,e)}};Object.assign(Object.create(null),{mixed:tn,string:et,number:kE,date:Lc,object:cl,array:TE,boolean:CE,tuple:OE});const od=e=>e&&e.__isYupSchema__;class Bl{static fromOptions(t,n){if(!n.then&&!n.otherwise)throw new TypeError("either `then:` or `otherwise:` is required for `when()` conditions");let{is:r,then:i,otherwise:s}=n,o=typeof r=="function"?r:(...l)=>l.every(a=>a===r);return new Bl(t,(l,a)=>{var c;let f=o(...l)?i:s;return(c=f==null?void 0:f(a))!=null?c:a})}constructor(t,n){this.fn=void 0,this.refs=t,this.refs=t,this.fn=n}resolve(t,n){let r=this.refs.map(s=>s.getValue(n==null?void 0:n.value,n==null?void 0:n.parent,n==null?void 0:n.context)),i=this.fn(r,t,n);if(i===void 0||i===t)return t;if(!od(i))throw new TypeError("conditions must return a schema object");return i.resolve(n)}}const Uo={context:"$",value:"."};class Zr{constructor(t,n={}){if(this.key=void 0,this.isContext=void 0,this.isValue=void 0,this.isSibling=void 0,this.path=void 0,this.getter=void 0,this.map=void 0,typeof t!="string")throw new TypeError("ref must be a string, got: "+t);if(this.key=t.trim(),t==="")throw new TypeError("ref must be a non-empty string");this.isContext=this.key[0]===Uo.context,this.isValue=this.key[0]===Uo.value,this.isSibling=!this.isContext&&!this.isValue;let r=this.isContext?Uo.context:this.isValue?Uo.value:"";this.path=this.key.slice(r.length),this.getter=this.path&&Dr.getter(this.path,!0),this.map=n.map}getValue(t,n,r){let i=this.isContext?r:this.isValue?t:n;return this.getter&&(i=this.getter(i||{})),this.map&&(i=this.map(i)),i}cast(t,n){return this.getValue(t,n==null?void 0:n.parent,n==null?void 0:n.context)}resolve(){return this}describe(){return{type:"ref",key:this.key}}toString(){return`Ref(${this.key})`}static isRef(t){return t&&t.__isYupRef}}Zr.prototype.__isYupRef=!0;const Tr=e=>e==null;function si(e){function t({value:n,path:r="",options:i,originalValue:s,schema:o},l,a){const{name:c,test:f,params:u,message:d,skipAbsent:h}=e;let{parent:v,context:w,abortEarly:S=o.spec.abortEarly,disableStackTrace:m=o.spec.disableStackTrace}=i;function p(B){return Zr.isRef(B)?B.getValue(n,v,w):B}function y(B={}){const se=Object.assign({value:n,originalValue:s,label:o.spec.label,path:B.path||r,spec:o.spec,disableStackTrace:B.disableStackTrace||m},u,B.params);for(const He of Object.keys(se))se[He]=p(se[He]);const oe=new st(st.formatError(B.message||d,se),n,se.path,B.type||c,se.disableStackTrace);return oe.params=se,oe}const x=S?l:a;let C={path:r,parent:v,type:c,from:i.from,createError:y,resolve:p,options:i,originalValue:s,schema:o};const T=B=>{st.isError(B)?x(B):B?a(null):x(y())},k=B=>{st.isError(B)?x(B):l(B)};if(h&&Tr(n))return T(!0);let I;try{var D;if(I=f.call(C,n,C),typeof((D=I)==null?void 0:D.then)=="function"){if(i.sync)throw new Error(`Validation test of type: "${C.type}" returned a Promise during a synchronous validate. This test will finish after the validate call has returned`);return Promise.resolve(I).then(T,k)}}catch(B){k(B);return}T(I)}return t.OPTIONS=e,t}function RE(e,t,n,r=n){let i,s,o;return t?(Dr.forEach(t,(l,a,c)=>{let f=a?l.slice(1,l.length-1):l;e=e.resolve({context:r,parent:i,value:n});let u=e.type==="tuple",d=c?parseInt(f,10):0;if(e.innerType||u){if(u&&!c)throw new Error(`Yup.reach cannot implicitly index into a tuple type. the path part "${o}" must contain an index to the tuple element, e.g. "${o}[0]"`);if(n&&d>=n.length)throw new Error(`Yup.reach cannot resolve an array item at index: ${l}, in the path: ${t}. because there is no value at that index. `);i=n,n=n&&n[d],e=u?e.spec.types[d]:e.innerType}if(!c){if(!e.fields||!e.fields[f])throw new Error(`The schema does not contain the path: ${t}. (failed at: ${o} which is a type: "${e.type}")`);i=n,n=n&&n[f],e=e.fields[f]}s=f,o=a?"["+l+"]":"."+l}),{schema:e,parent:i,parentPath:s}):{parent:i,parentPath:t,schema:e}}class Ul extends Set{describe(){const t=[];for(const n of this.values())t.push(Zr.isRef(n)?n.describe():n);return t}resolveAll(t){let n=[];for(const r of this.values())n.push(t(r));return n}clone(){return new Ul(this.values())}merge(t,n){const r=this.clone();return t.forEach(i=>r.add(i)),n.forEach(i=>r.delete(i)),r}}function vi(e,t=new Map){if(od(e)||!e||typeof e!="object")return e;if(t.has(e))return t.get(e);let n;if(e instanceof Date)n=new Date(e.getTime()),t.set(e,n);else if(e instanceof RegExp)n=new RegExp(e),t.set(e,n);else if(Array.isArray(e)){n=new Array(e.length),t.set(e,n);for(let r=0;r<e.length;r++)n[r]=vi(e[r],t)}else if(e instanceof Map){n=new Map,t.set(e,n);for(const[r,i]of e.entries())n.set(r,vi(i,t))}else if(e instanceof Set){n=new Set,t.set(e,n);for(const r of e)n.add(vi(r,t))}else if(e instanceof Object){n={},t.set(e,n);for(const[r,i]of Object.entries(e))n[r]=vi(i,t)}else throw Error(`Unable to clone ${e}`);return n}class hn{constructor(t){this.type=void 0,this.deps=[],this.tests=void 0,this.transforms=void 0,this.conditions=[],this._mutate=void 0,this.internalTests={},this._whitelist=new Ul,this._blacklist=new Ul,this.exclusiveTests=Object.create(null),this._typeCheck=void 0,this.spec=void 0,this.tests=[],this.transforms=[],this.withMutation(()=>{this.typeError(tn.notType)}),this.type=t.type,this._typeCheck=t.check,this.spec=Object.assign({strip:!1,strict:!1,abortEarly:!0,recursive:!0,disableStackTrace:!1,nullable:!1,optional:!0,coerce:!0},t==null?void 0:t.spec),this.withMutation(n=>{n.nonNullable()})}get _type(){return this.type}clone(t){if(this._mutate)return t&&Object.assign(this.spec,t),this;const n=Object.create(Object.getPrototypeOf(this));return n.type=this.type,n._typeCheck=this._typeCheck,n._whitelist=this._whitelist.clone(),n._blacklist=this._blacklist.clone(),n.internalTests=Object.assign({},this.internalTests),n.exclusiveTests=Object.assign({},this.exclusiveTests),n.deps=[...this.deps],n.conditions=[...this.conditions],n.tests=[...this.tests],n.transforms=[...this.transforms],n.spec=vi(Object.assign({},this.spec,t)),n}label(t){let n=this.clone();return n.spec.label=t,n}meta(...t){if(t.length===0)return this.spec.meta;let n=this.clone();return n.spec.meta=Object.assign(n.spec.meta||{},t[0]),n}withMutation(t){let n=this._mutate;this._mutate=!0;let r=t(this);return this._mutate=n,r}concat(t){if(!t||t===this)return this;if(t.type!==this.type&&this.type!=="mixed")throw new TypeError(`You cannot \`concat()\` schema's of different types: ${this.type} and ${t.type}`);let n=this,r=t.clone();const i=Object.assign({},n.spec,r.spec);return r.spec=i,r.internalTests=Object.assign({},n.internalTests,r.internalTests),r._whitelist=n._whitelist.merge(t._whitelist,t._blacklist),r._blacklist=n._blacklist.merge(t._blacklist,t._whitelist),r.tests=n.tests,r.exclusiveTests=n.exclusiveTests,r.withMutation(s=>{t.tests.forEach(o=>{s.test(o.OPTIONS)})}),r.transforms=[...n.transforms,...r.transforms],r}isType(t){return t==null?!!(this.spec.nullable&&t===null||this.spec.optional&&t===void 0):this._typeCheck(t)}resolve(t){let n=this;if(n.conditions.length){let r=n.conditions;n=n.clone(),n.conditions=[],n=r.reduce((i,s)=>s.resolve(i,t),n),n=n.resolve(t)}return n}resolveOptions(t){var n,r,i,s;return Object.assign({},t,{from:t.from||[],strict:(n=t.strict)!=null?n:this.spec.strict,abortEarly:(r=t.abortEarly)!=null?r:this.spec.abortEarly,recursive:(i=t.recursive)!=null?i:this.spec.recursive,disableStackTrace:(s=t.disableStackTrace)!=null?s:this.spec.disableStackTrace})}cast(t,n={}){let r=this.resolve(Object.assign({value:t},n)),i=n.assert==="ignore-optionality",s=r._cast(t,n);if(n.assert!==!1&&!r.isType(s)){if(i&&Tr(s))return s;let o=ur(t),l=ur(s);throw new TypeError(`The value of ${n.path||"field"} could not be cast to a value that satisfies the schema type: "${r.type}".
78
+ */(function(e){(function(){var t={}.hasOwnProperty;function n(){for(var s="",o=0;o<arguments.length;o++){var l=arguments[o];l&&(s=i(s,r(l)))}return s}function r(s){if(typeof s=="string"||typeof s=="number")return s;if(typeof s!="object")return"";if(Array.isArray(s))return n.apply(null,s);if(s.toString!==Object.prototype.toString&&!s.toString.toString().includes("[native code]"))return s.toString();var o="";for(var l in s)t.call(s,l)&&s[l]&&(o=i(o,l));return o}function i(s,o){return o?s?s+" "+o:s+o:s}e.exports?(n.default=n,e.exports=n):window.classNames=n})()})(Qy);var rb=Qy.exports;const qt=Ki(rb);function Gs({children:e,type:t="button",variant:n="primary",kind:r="solid",size:i="md",rounded:s=!1,className:o,...l}){return _.jsx("button",{type:t,className:qt("lc-flex lc-items-center lc-justify-center",{"lc-rounded-full":s,"lc-rounded-md":!s},o,tb[n][r],nb[i][s?"rounded":"default"]),...l,children:e})}function Ve(){}Ve.Home=function(t){return _.jsx("svg",{viewBox:"0 0 24 24",fill:"currentColor",height:"1em",width:"1em",...t,children:_.jsx("path",{d:"M3 13h1v7c0 1.103.897 2 2 2h12c1.103 0 2-.897 2-2v-7h1a1 1 0 00.707-1.707l-9-9a.999.999 0 00-1.414 0l-9 9A1 1 0 003 13zm7 7v-5h4v5h-4zm2-15.586l6 6V15l.001 5H16v-5c0-1.103-.897-2-2-2h-4c-1.103 0-2 .897-2 2v5H6v-9.586l6-6z"})})};Ve.Chat=e=>_.jsx("svg",{xmlns:"http://www.w3.org/2000/svg",fill:"none",viewBox:"0 0 24 24",strokeWidth:1.5,stroke:"currentColor",...e,children:_.jsx("path",{strokeLinecap:"round",strokeLinejoin:"round",d:"M7.5 8.25h9m-9 3H12m-9.75 1.51c0 1.6 1.123 2.994 2.707 3.227 1.129.166 2.27.293 3.423.379.35.026.67.21.865.501L12 21l2.755-4.133a1.14 1.14 0 0 1 .865-.501 48.172 48.172 0 0 0 3.423-.379c1.584-.233 2.707-1.626 2.707-3.228V6.741c0-1.602-1.123-2.995-2.707-3.228A48.394 48.394 0 0 0 12 3c-2.392 0-4.744.175-7.043.513C3.373 3.746 2.25 5.14 2.25 6.741v6.018Z"})});Ve.MessageTyping=({className:e="lc-size-5",...t})=>_.jsx("svg",{xmlns:"http://www.w3.org/2000/svg",fill:"none",viewBox:"0 0 24 24",strokeWidth:1.5,stroke:"currentColor",className:e,...t,children:_.jsx("path",{strokeLinecap:"round",strokeLinejoin:"round",d:"M8.625 9.75a.375.375 0 1 1-.75 0 .375.375 0 0 1 .75 0Zm0 0H8.25m4.125 0a.375.375 0 1 1-.75 0 .375.375 0 0 1 .75 0Zm0 0H12m4.125 0a.375.375 0 1 1-.75 0 .375.375 0 0 1 .75 0Zm0 0h-.375m-13.5 3.01c0 1.6 1.123 2.994 2.707 3.227 1.087.16 2.185.283 3.293.369V21l4.184-4.183a1.14 1.14 0 0 1 .778-.332 48.294 48.294 0 0 0 5.83-.498c1.585-.233 2.708-1.626 2.708-3.228V6.741c0-1.602-1.123-2.995-2.707-3.228A48.394 48.394 0 0 0 12 3c-2.392 0-4.744.175-7.043.513C3.373 3.746 2.25 5.14 2.25 6.741v6.018Z"})});Ve.Check=function(t){return _.jsx("svg",{fill:"currentColor",viewBox:"0 0 16 16",height:"1em",width:"1em",...t,children:_.jsx("path",{d:"M12.736 3.97a.733.733 0 011.047 0c.286.289.29.756.01 1.05L7.88 12.01a.733.733 0 01-1.065.02L3.217 8.384a.757.757 0 010-1.06.733.733 0 011.047 0l3.052 3.093 5.4-6.425a.247.247 0 01.02-.022z"})})};Ve.Website=function(t){return _.jsxs("svg",{fill:"none",viewBox:"0 0 24 24",height:"1em",width:"1em",...t,children:[_.jsx("path",{fill:"currentColor",fillRule:"evenodd",d:"M14 7a1 1 0 00-1 1v8a1 1 0 001 1h4a1 1 0 001-1V8a1 1 0 00-1-1h-4zm3 2h-2v6h2V9z",clipRule:"evenodd"}),_.jsx("path",{fill:"currentColor",d:"M6 7a1 1 0 000 2h4a1 1 0 100-2H6zM6 11a1 1 0 100 2h4a1 1 0 100-2H6zM5 16a1 1 0 011-1h4a1 1 0 110 2H6a1 1 0 01-1-1z"}),_.jsx("path",{fill:"currentColor",fillRule:"evenodd",d:"M4 3a3 3 0 00-3 3v12a3 3 0 003 3h16a3 3 0 003-3V6a3 3 0 00-3-3H4zm16 2H4a1 1 0 00-1 1v12a1 1 0 001 1h16a1 1 0 001-1V6a1 1 0 00-1-1z",clipRule:"evenodd"})]})};Ve.ArrowDown=e=>_.jsx("svg",{xmlns:"http://www.w3.org/2000/svg",fill:"none",viewBox:"0 0 24 24",strokeWidth:1.5,stroke:"currentColor",...e,children:_.jsx("path",{strokeLinecap:"round",strokeLinejoin:"round",d:"M19.5 13.5 12 21m0 0-7.5-7.5M12 21V3"})});Ve.XCircle=({className:e="lc-size-5",...t})=>_.jsx("svg",{xmlns:"http://www.w3.org/2000/svg",fill:"none",viewBox:"0 0 24 24",strokeWidth:1.5,stroke:"currentColor",className:e,...t,children:_.jsx("path",{strokeLinecap:"round",strokeLinejoin:"round",d:"m9.75 9.75 4.5 4.5m0-4.5-4.5 4.5M21 12a9 9 0 1 1-18 0 9 9 0 0 1 18 0Z"})});Ve.X=({className:e="lc-size-5",...t})=>_.jsx("svg",{xmlns:"http://www.w3.org/2000/svg",fill:"none",viewBox:"0 0 24 24",strokeWidth:1.5,stroke:"currentColor",className:e,...t,children:_.jsx("path",{strokeLinecap:"round",strokeLinejoin:"round",d:"M6 18 18 6M6 6l12 12"})});const dn=Object.create(null);dn.open="0";dn.close="1";dn.ping="2";dn.pong="3";dn.message="4";dn.upgrade="5";dn.noop="6";const sl=Object.create(null);Object.keys(dn).forEach(e=>{sl[dn[e]]=e});const Nc={type:"error",data:"parser error"},qy=typeof Blob=="function"||typeof Blob<"u"&&Object.prototype.toString.call(Blob)==="[object BlobConstructor]",Ky=typeof ArrayBuffer=="function",Yy=e=>typeof ArrayBuffer.isView=="function"?ArrayBuffer.isView(e):e&&e.buffer instanceof ArrayBuffer,Gf=({type:e,data:t},n,r)=>qy&&t instanceof Blob?n?r(t):Jh(t,r):Ky&&(t instanceof ArrayBuffer||Yy(t))?n?r(t):Jh(new Blob([t]),r):r(dn[e]+(t||"")),Jh=(e,t)=>{const n=new FileReader;return n.onload=function(){const r=n.result.split(",")[1];t("b"+(r||""))},n.readAsDataURL(e)};function ep(e){return e instanceof Uint8Array?e:e instanceof ArrayBuffer?new Uint8Array(e):new Uint8Array(e.buffer,e.byteOffset,e.byteLength)}let fu;function ib(e,t){if(qy&&e.data instanceof Blob)return e.data.arrayBuffer().then(ep).then(t);if(Ky&&(e.data instanceof ArrayBuffer||Yy(e.data)))return t(ep(e.data));Gf(e,!1,n=>{fu||(fu=new TextEncoder),t(fu.encode(n))})}const tp="ABCDEFGHIJKLMNOPQRSTUVWXYZabcdefghijklmnopqrstuvwxyz0123456789+/",ws=typeof Uint8Array>"u"?[]:new Uint8Array(256);for(let e=0;e<tp.length;e++)ws[tp.charCodeAt(e)]=e;const sb=e=>{let t=e.length*.75,n=e.length,r,i=0,s,o,l,a;e[e.length-1]==="="&&(t--,e[e.length-2]==="="&&t--);const c=new ArrayBuffer(t),f=new Uint8Array(c);for(r=0;r<n;r+=4)s=ws[e.charCodeAt(r)],o=ws[e.charCodeAt(r+1)],l=ws[e.charCodeAt(r+2)],a=ws[e.charCodeAt(r+3)],f[i++]=s<<2|o>>4,f[i++]=(o&15)<<4|l>>2,f[i++]=(l&3)<<6|a&63;return c},ob=typeof ArrayBuffer=="function",Xf=(e,t)=>{if(typeof e!="string")return{type:"message",data:Gy(e,t)};const n=e.charAt(0);return n==="b"?{type:"message",data:lb(e.substring(1),t)}:sl[n]?e.length>1?{type:sl[n],data:e.substring(1)}:{type:sl[n]}:Nc},lb=(e,t)=>{if(ob){const n=sb(e);return Gy(n,t)}else return{base64:!0,data:e}},Gy=(e,t)=>{switch(t){case"blob":return e instanceof Blob?e:new Blob([e]);case"arraybuffer":default:return e instanceof ArrayBuffer?e:e.buffer}},Xy="",ab=(e,t)=>{const n=e.length,r=new Array(n);let i=0;e.forEach((s,o)=>{Gf(s,!1,l=>{r[o]=l,++i===n&&t(r.join(Xy))})})},ub=(e,t)=>{const n=e.split(Xy),r=[];for(let i=0;i<n.length;i++){const s=Xf(n[i],t);if(r.push(s),s.type==="error")break}return r};function cb(){return new TransformStream({transform(e,t){ib(e,n=>{const r=n.length;let i;if(r<126)i=new Uint8Array(1),new DataView(i.buffer).setUint8(0,r);else if(r<65536){i=new Uint8Array(3);const s=new DataView(i.buffer);s.setUint8(0,126),s.setUint16(1,r)}else{i=new Uint8Array(9);const s=new DataView(i.buffer);s.setUint8(0,127),s.setBigUint64(1,BigInt(r))}e.data&&typeof e.data!="string"&&(i[0]|=128),t.enqueue(i),t.enqueue(n)})}})}let du;function zo(e){return e.reduce((t,n)=>t+n.length,0)}function Bo(e,t){if(e[0].length===t)return e.shift();const n=new Uint8Array(t);let r=0;for(let i=0;i<t;i++)n[i]=e[0][r++],r===e[0].length&&(e.shift(),r=0);return e.length&&r<e[0].length&&(e[0]=e[0].slice(r)),n}function fb(e,t){du||(du=new TextDecoder);const n=[];let r=0,i=-1,s=!1;return new TransformStream({transform(o,l){for(n.push(o);;){if(r===0){if(zo(n)<1)break;const a=Bo(n,1);s=(a[0]&128)===128,i=a[0]&127,i<126?r=3:i===126?r=1:r=2}else if(r===1){if(zo(n)<2)break;const a=Bo(n,2);i=new DataView(a.buffer,a.byteOffset,a.length).getUint16(0),r=3}else if(r===2){if(zo(n)<8)break;const a=Bo(n,8),c=new DataView(a.buffer,a.byteOffset,a.length),f=c.getUint32(0);if(f>Math.pow(2,21)-1){l.enqueue(Nc);break}i=f*Math.pow(2,32)+c.getUint32(4),r=3}else{if(zo(n)<i)break;const a=Bo(n,i);l.enqueue(Xf(s?a:du.decode(a),t)),r=0}if(i===0||i>e){l.enqueue(Nc);break}}}})}const Zy=4;function be(e){if(e)return db(e)}function db(e){for(var t in be.prototype)e[t]=be.prototype[t];return e}be.prototype.on=be.prototype.addEventListener=function(e,t){return this._callbacks=this._callbacks||{},(this._callbacks["$"+e]=this._callbacks["$"+e]||[]).push(t),this};be.prototype.once=function(e,t){function n(){this.off(e,n),t.apply(this,arguments)}return n.fn=t,this.on(e,n),this};be.prototype.off=be.prototype.removeListener=be.prototype.removeAllListeners=be.prototype.removeEventListener=function(e,t){if(this._callbacks=this._callbacks||{},arguments.length==0)return this._callbacks={},this;var n=this._callbacks["$"+e];if(!n)return this;if(arguments.length==1)return delete this._callbacks["$"+e],this;for(var r,i=0;i<n.length;i++)if(r=n[i],r===t||r.fn===t){n.splice(i,1);break}return n.length===0&&delete this._callbacks["$"+e],this};be.prototype.emit=function(e){this._callbacks=this._callbacks||{};for(var t=new Array(arguments.length-1),n=this._callbacks["$"+e],r=1;r<arguments.length;r++)t[r-1]=arguments[r];if(n){n=n.slice(0);for(var r=0,i=n.length;r<i;++r)n[r].apply(this,t)}return this};be.prototype.emitReserved=be.prototype.emit;be.prototype.listeners=function(e){return this._callbacks=this._callbacks||{},this._callbacks["$"+e]||[]};be.prototype.hasListeners=function(e){return!!this.listeners(e).length};const fa=typeof Promise=="function"&&typeof Promise.resolve=="function"?t=>Promise.resolve().then(t):(t,n)=>n(t,0),Pt=typeof self<"u"?self:typeof window<"u"?window:Function("return this")(),hb="arraybuffer";function Jy(e,...t){return t.reduce((n,r)=>(e.hasOwnProperty(r)&&(n[r]=e[r]),n),{})}const pb=Pt.setTimeout,mb=Pt.clearTimeout;function da(e,t){t.useNativeTimers?(e.setTimeoutFn=pb.bind(Pt),e.clearTimeoutFn=mb.bind(Pt)):(e.setTimeoutFn=Pt.setTimeout.bind(Pt),e.clearTimeoutFn=Pt.clearTimeout.bind(Pt))}const yb=1.33;function gb(e){return typeof e=="string"?vb(e):Math.ceil((e.byteLength||e.size)*yb)}function vb(e){let t=0,n=0;for(let r=0,i=e.length;r<i;r++)t=e.charCodeAt(r),t<128?n+=1:t<2048?n+=2:t<55296||t>=57344?n+=3:(r++,n+=4);return n}function eg(){return Date.now().toString(36).substring(3)+Math.random().toString(36).substring(2,5)}function wb(e){let t="";for(let n in e)e.hasOwnProperty(n)&&(t.length&&(t+="&"),t+=encodeURIComponent(n)+"="+encodeURIComponent(e[n]));return t}function xb(e){let t={},n=e.split("&");for(let r=0,i=n.length;r<i;r++){let s=n[r].split("=");t[decodeURIComponent(s[0])]=decodeURIComponent(s[1])}return t}class Sb extends Error{constructor(t,n,r){super(t),this.description=n,this.context=r,this.type="TransportError"}}class Zf extends be{constructor(t){super(),this.writable=!1,da(this,t),this.opts=t,this.query=t.query,this.socket=t.socket,this.supportsBinary=!t.forceBase64}onError(t,n,r){return super.emitReserved("error",new Sb(t,n,r)),this}open(){return this.readyState="opening",this.doOpen(),this}close(){return(this.readyState==="opening"||this.readyState==="open")&&(this.doClose(),this.onClose()),this}send(t){this.readyState==="open"&&this.write(t)}onOpen(){this.readyState="open",this.writable=!0,super.emitReserved("open")}onData(t){const n=Xf(t,this.socket.binaryType);this.onPacket(n)}onPacket(t){super.emitReserved("packet",t)}onClose(t){this.readyState="closed",super.emitReserved("close",t)}pause(t){}createUri(t,n={}){return t+"://"+this._hostname()+this._port()+this.opts.path+this._query(n)}_hostname(){const t=this.opts.hostname;return t.indexOf(":")===-1?t:"["+t+"]"}_port(){return this.opts.port&&(this.opts.secure&&+(this.opts.port!==443)||!this.opts.secure&&Number(this.opts.port)!==80)?":"+this.opts.port:""}_query(t){const n=wb(t);return n.length?"?"+n:""}}class bb extends Zf{constructor(){super(...arguments),this._polling=!1}get name(){return"polling"}doOpen(){this._poll()}pause(t){this.readyState="pausing";const n=()=>{this.readyState="paused",t()};if(this._polling||!this.writable){let r=0;this._polling&&(r++,this.once("pollComplete",function(){--r||n()})),this.writable||(r++,this.once("drain",function(){--r||n()}))}else n()}_poll(){this._polling=!0,this.doPoll(),this.emitReserved("poll")}onData(t){const n=r=>{if(this.readyState==="opening"&&r.type==="open"&&this.onOpen(),r.type==="close")return this.onClose({description:"transport closed by the server"}),!1;this.onPacket(r)};ub(t,this.socket.binaryType).forEach(n),this.readyState!=="closed"&&(this._polling=!1,this.emitReserved("pollComplete"),this.readyState==="open"&&this._poll())}doClose(){const t=()=>{this.write([{type:"close"}])};this.readyState==="open"?t():this.once("open",t)}write(t){this.writable=!1,ab(t,n=>{this.doWrite(n,()=>{this.writable=!0,this.emitReserved("drain")})})}uri(){const t=this.opts.secure?"https":"http",n=this.query||{};return this.opts.timestampRequests!==!1&&(n[this.opts.timestampParam]=eg()),!this.supportsBinary&&!n.sid&&(n.b64=1),this.createUri(t,n)}}let tg=!1;try{tg=typeof XMLHttpRequest<"u"&&"withCredentials"in new XMLHttpRequest}catch{}const Eb=tg;function _b(){}class kb extends bb{constructor(t){if(super(t),typeof location<"u"){const n=location.protocol==="https:";let r=location.port;r||(r=n?"443":"80"),this.xd=typeof location<"u"&&t.hostname!==location.hostname||r!==t.port}}doWrite(t,n){const r=this.request({method:"POST",data:t});r.on("success",n),r.on("error",(i,s)=>{this.onError("xhr post error",i,s)})}doPoll(){const t=this.request();t.on("data",this.onData.bind(this)),t.on("error",(n,r)=>{this.onError("xhr poll error",n,r)}),this.pollXhr=t}}class cn extends be{constructor(t,n,r){super(),this.createRequest=t,da(this,r),this._opts=r,this._method=r.method||"GET",this._uri=n,this._data=r.data!==void 0?r.data:null,this._create()}_create(){var t;const n=Jy(this._opts,"agent","pfx","key","passphrase","cert","ca","ciphers","rejectUnauthorized","autoUnref");n.xdomain=!!this._opts.xd;const r=this._xhr=this.createRequest(n);try{r.open(this._method,this._uri,!0);try{if(this._opts.extraHeaders){r.setDisableHeaderCheck&&r.setDisableHeaderCheck(!0);for(let i in this._opts.extraHeaders)this._opts.extraHeaders.hasOwnProperty(i)&&r.setRequestHeader(i,this._opts.extraHeaders[i])}}catch{}if(this._method==="POST")try{r.setRequestHeader("Content-type","text/plain;charset=UTF-8")}catch{}try{r.setRequestHeader("Accept","*/*")}catch{}(t=this._opts.cookieJar)===null||t===void 0||t.addCookies(r),"withCredentials"in r&&(r.withCredentials=this._opts.withCredentials),this._opts.requestTimeout&&(r.timeout=this._opts.requestTimeout),r.onreadystatechange=()=>{var i;r.readyState===3&&((i=this._opts.cookieJar)===null||i===void 0||i.parseCookies(r.getResponseHeader("set-cookie"))),r.readyState===4&&(r.status===200||r.status===1223?this._onLoad():this.setTimeoutFn(()=>{this._onError(typeof r.status=="number"?r.status:0)},0))},r.send(this._data)}catch(i){this.setTimeoutFn(()=>{this._onError(i)},0);return}typeof document<"u"&&(this._index=cn.requestsCount++,cn.requests[this._index]=this)}_onError(t){this.emitReserved("error",t,this._xhr),this._cleanup(!0)}_cleanup(t){if(!(typeof this._xhr>"u"||this._xhr===null)){if(this._xhr.onreadystatechange=_b,t)try{this._xhr.abort()}catch{}typeof document<"u"&&delete cn.requests[this._index],this._xhr=null}}_onLoad(){const t=this._xhr.responseText;t!==null&&(this.emitReserved("data",t),this.emitReserved("success"),this._cleanup())}abort(){this._cleanup()}}cn.requestsCount=0;cn.requests={};if(typeof document<"u"){if(typeof attachEvent=="function")attachEvent("onunload",np);else if(typeof addEventListener=="function"){const e="onpagehide"in Pt?"pagehide":"unload";addEventListener(e,np,!1)}}function np(){for(let e in cn.requests)cn.requests.hasOwnProperty(e)&&cn.requests[e].abort()}const Cb=function(){const e=ng({xdomain:!1});return e&&e.responseType!==null}();class Tb extends kb{constructor(t){super(t);const n=t&&t.forceBase64;this.supportsBinary=Cb&&!n}request(t={}){return Object.assign(t,{xd:this.xd},this.opts),new cn(ng,this.uri(),t)}}function ng(e){const t=e.xdomain;try{if(typeof XMLHttpRequest<"u"&&(!t||Eb))return new XMLHttpRequest}catch{}if(!t)try{return new Pt[["Active"].concat("Object").join("X")]("Microsoft.XMLHTTP")}catch{}}const rg=typeof navigator<"u"&&typeof navigator.product=="string"&&navigator.product.toLowerCase()==="reactnative";class Ob extends Zf{get name(){return"websocket"}doOpen(){const t=this.uri(),n=this.opts.protocols,r=rg?{}:Jy(this.opts,"agent","perMessageDeflate","pfx","key","passphrase","cert","ca","ciphers","rejectUnauthorized","localAddress","protocolVersion","origin","maxPayload","family","checkServerIdentity");this.opts.extraHeaders&&(r.headers=this.opts.extraHeaders);try{this.ws=this.createSocket(t,n,r)}catch(i){return this.emitReserved("error",i)}this.ws.binaryType=this.socket.binaryType,this.addEventListeners()}addEventListeners(){this.ws.onopen=()=>{this.opts.autoUnref&&this.ws._socket.unref(),this.onOpen()},this.ws.onclose=t=>this.onClose({description:"websocket connection closed",context:t}),this.ws.onmessage=t=>this.onData(t.data),this.ws.onerror=t=>this.onError("websocket error",t)}write(t){this.writable=!1;for(let n=0;n<t.length;n++){const r=t[n],i=n===t.length-1;Gf(r,this.supportsBinary,s=>{try{this.doWrite(r,s)}catch{}i&&fa(()=>{this.writable=!0,this.emitReserved("drain")},this.setTimeoutFn)})}}doClose(){typeof this.ws<"u"&&(this.ws.onerror=()=>{},this.ws.close(),this.ws=null)}uri(){const t=this.opts.secure?"wss":"ws",n=this.query||{};return this.opts.timestampRequests&&(n[this.opts.timestampParam]=eg()),this.supportsBinary||(n.b64=1),this.createUri(t,n)}}const hu=Pt.WebSocket||Pt.MozWebSocket;class Rb extends Ob{createSocket(t,n,r){return rg?new hu(t,n,r):n?new hu(t,n):new hu(t)}doWrite(t,n){this.ws.send(n)}}class Nb extends Zf{get name(){return"webtransport"}doOpen(){try{this._transport=new WebTransport(this.createUri("https"),this.opts.transportOptions[this.name])}catch(t){return this.emitReserved("error",t)}this._transport.closed.then(()=>{this.onClose()}).catch(t=>{this.onError("webtransport error",t)}),this._transport.ready.then(()=>{this._transport.createBidirectionalStream().then(t=>{const n=fb(Number.MAX_SAFE_INTEGER,this.socket.binaryType),r=t.readable.pipeThrough(n).getReader(),i=cb();i.readable.pipeTo(t.writable),this._writer=i.writable.getWriter();const s=()=>{r.read().then(({done:l,value:a})=>{l||(this.onPacket(a),s())}).catch(l=>{})};s();const o={type:"open"};this.query.sid&&(o.data=`{"sid":"${this.query.sid}"}`),this._writer.write(o).then(()=>this.onOpen())})})}write(t){this.writable=!1;for(let n=0;n<t.length;n++){const r=t[n],i=n===t.length-1;this._writer.write(r).then(()=>{i&&fa(()=>{this.writable=!0,this.emitReserved("drain")},this.setTimeoutFn)})}}doClose(){var t;(t=this._transport)===null||t===void 0||t.close()}}const Pb={websocket:Rb,webtransport:Nb,polling:Tb},Ab=/^(?:(?![^:@\/?#]+:[^:@\/]*@)(http|https|ws|wss):\/\/)?((?:(([^:@\/?#]*)(?::([^:@\/?#]*))?)?@)?((?:[a-f0-9]{0,4}:){2,7}[a-f0-9]{0,4}|[^:\/?#]*)(?::(\d*))?)(((\/(?:[^?#](?![^?#\/]*\.[^?#\/.]+(?:[?#]|$)))*\/?)?([^?#\/]*))(?:\?([^#]*))?(?:#(.*))?)/,jb=["source","protocol","authority","userInfo","user","password","host","port","relative","path","directory","file","query","anchor"];function Pc(e){if(e.length>8e3)throw"URI too long";const t=e,n=e.indexOf("["),r=e.indexOf("]");n!=-1&&r!=-1&&(e=e.substring(0,n)+e.substring(n,r).replace(/:/g,";")+e.substring(r,e.length));let i=Ab.exec(e||""),s={},o=14;for(;o--;)s[jb[o]]=i[o]||"";return n!=-1&&r!=-1&&(s.source=t,s.host=s.host.substring(1,s.host.length-1).replace(/;/g,":"),s.authority=s.authority.replace("[","").replace("]","").replace(/;/g,":"),s.ipv6uri=!0),s.pathNames=Fb(s,s.path),s.queryKey=$b(s,s.query),s}function Fb(e,t){const n=/\/{2,9}/g,r=t.replace(n,"/").split("/");return(t.slice(0,1)=="/"||t.length===0)&&r.splice(0,1),t.slice(-1)=="/"&&r.splice(r.length-1,1),r}function $b(e,t){const n={};return t.replace(/(?:^|&)([^&=]*)=?([^&]*)/g,function(r,i,s){i&&(n[i]=s)}),n}const Ac=typeof addEventListener=="function"&&typeof removeEventListener=="function",ol=[];Ac&&addEventListener("offline",()=>{ol.forEach(e=>e())},!1);class ar extends be{constructor(t,n){if(super(),this.binaryType=hb,this.writeBuffer=[],this._prevBufferLen=0,this._pingInterval=-1,this._pingTimeout=-1,this._maxPayload=-1,this._pingTimeoutTime=1/0,t&&typeof t=="object"&&(n=t,t=null),t){const r=Pc(t);n.hostname=r.host,n.secure=r.protocol==="https"||r.protocol==="wss",n.port=r.port,r.query&&(n.query=r.query)}else n.host&&(n.hostname=Pc(n.host).host);da(this,n),this.secure=n.secure!=null?n.secure:typeof location<"u"&&location.protocol==="https:",n.hostname&&!n.port&&(n.port=this.secure?"443":"80"),this.hostname=n.hostname||(typeof location<"u"?location.hostname:"localhost"),this.port=n.port||(typeof location<"u"&&location.port?location.port:this.secure?"443":"80"),this.transports=[],this._transportsByName={},n.transports.forEach(r=>{const i=r.prototype.name;this.transports.push(i),this._transportsByName[i]=r}),this.opts=Object.assign({path:"/engine.io",agent:!1,withCredentials:!1,upgrade:!0,timestampParam:"t",rememberUpgrade:!1,addTrailingSlash:!0,rejectUnauthorized:!0,perMessageDeflate:{threshold:1024},transportOptions:{},closeOnBeforeunload:!1},n),this.opts.path=this.opts.path.replace(/\/$/,"")+(this.opts.addTrailingSlash?"/":""),typeof this.opts.query=="string"&&(this.opts.query=xb(this.opts.query)),Ac&&(this.opts.closeOnBeforeunload&&(this._beforeunloadEventListener=()=>{this.transport&&(this.transport.removeAllListeners(),this.transport.close())},addEventListener("beforeunload",this._beforeunloadEventListener,!1)),this.hostname!=="localhost"&&(this._offlineEventListener=()=>{this._onClose("transport close",{description:"network connection lost"})},ol.push(this._offlineEventListener))),this.opts.withCredentials&&(this._cookieJar=void 0),this._open()}createTransport(t){const n=Object.assign({},this.opts.query);n.EIO=Zy,n.transport=t,this.id&&(n.sid=this.id);const r=Object.assign({},this.opts,{query:n,socket:this,hostname:this.hostname,secure:this.secure,port:this.port},this.opts.transportOptions[t]);return new this._transportsByName[t](r)}_open(){if(this.transports.length===0){this.setTimeoutFn(()=>{this.emitReserved("error","No transports available")},0);return}const t=this.opts.rememberUpgrade&&ar.priorWebsocketSuccess&&this.transports.indexOf("websocket")!==-1?"websocket":this.transports[0];this.readyState="opening";const n=this.createTransport(t);n.open(),this.setTransport(n)}setTransport(t){this.transport&&this.transport.removeAllListeners(),this.transport=t,t.on("drain",this._onDrain.bind(this)).on("packet",this._onPacket.bind(this)).on("error",this._onError.bind(this)).on("close",n=>this._onClose("transport close",n))}onOpen(){this.readyState="open",ar.priorWebsocketSuccess=this.transport.name==="websocket",this.emitReserved("open"),this.flush()}_onPacket(t){if(this.readyState==="opening"||this.readyState==="open"||this.readyState==="closing")switch(this.emitReserved("packet",t),this.emitReserved("heartbeat"),t.type){case"open":this.onHandshake(JSON.parse(t.data));break;case"ping":this._sendPacket("pong"),this.emitReserved("ping"),this.emitReserved("pong"),this._resetPingTimeout();break;case"error":const n=new Error("server error");n.code=t.data,this._onError(n);break;case"message":this.emitReserved("data",t.data),this.emitReserved("message",t.data);break}}onHandshake(t){this.emitReserved("handshake",t),this.id=t.sid,this.transport.query.sid=t.sid,this._pingInterval=t.pingInterval,this._pingTimeout=t.pingTimeout,this._maxPayload=t.maxPayload,this.onOpen(),this.readyState!=="closed"&&this._resetPingTimeout()}_resetPingTimeout(){this.clearTimeoutFn(this._pingTimeoutTimer);const t=this._pingInterval+this._pingTimeout;this._pingTimeoutTime=Date.now()+t,this._pingTimeoutTimer=this.setTimeoutFn(()=>{this._onClose("ping timeout")},t),this.opts.autoUnref&&this._pingTimeoutTimer.unref()}_onDrain(){this.writeBuffer.splice(0,this._prevBufferLen),this._prevBufferLen=0,this.writeBuffer.length===0?this.emitReserved("drain"):this.flush()}flush(){if(this.readyState!=="closed"&&this.transport.writable&&!this.upgrading&&this.writeBuffer.length){const t=this._getWritablePackets();this.transport.send(t),this._prevBufferLen=t.length,this.emitReserved("flush")}}_getWritablePackets(){if(!(this._maxPayload&&this.transport.name==="polling"&&this.writeBuffer.length>1))return this.writeBuffer;let n=1;for(let r=0;r<this.writeBuffer.length;r++){const i=this.writeBuffer[r].data;if(i&&(n+=gb(i)),r>0&&n>this._maxPayload)return this.writeBuffer.slice(0,r);n+=2}return this.writeBuffer}_hasPingExpired(){if(!this._pingTimeoutTime)return!0;const t=Date.now()>this._pingTimeoutTime;return t&&(this._pingTimeoutTime=0,fa(()=>{this._onClose("ping timeout")},this.setTimeoutFn)),t}write(t,n,r){return this._sendPacket("message",t,n,r),this}send(t,n,r){return this._sendPacket("message",t,n,r),this}_sendPacket(t,n,r,i){if(typeof n=="function"&&(i=n,n=void 0),typeof r=="function"&&(i=r,r=null),this.readyState==="closing"||this.readyState==="closed")return;r=r||{},r.compress=r.compress!==!1;const s={type:t,data:n,options:r};this.emitReserved("packetCreate",s),this.writeBuffer.push(s),i&&this.once("flush",i),this.flush()}close(){const t=()=>{this._onClose("forced close"),this.transport.close()},n=()=>{this.off("upgrade",n),this.off("upgradeError",n),t()},r=()=>{this.once("upgrade",n),this.once("upgradeError",n)};return(this.readyState==="opening"||this.readyState==="open")&&(this.readyState="closing",this.writeBuffer.length?this.once("drain",()=>{this.upgrading?r():t()}):this.upgrading?r():t()),this}_onError(t){if(ar.priorWebsocketSuccess=!1,this.opts.tryAllTransports&&this.transports.length>1&&this.readyState==="opening")return this.transports.shift(),this._open();this.emitReserved("error",t),this._onClose("transport error",t)}_onClose(t,n){if(this.readyState==="opening"||this.readyState==="open"||this.readyState==="closing"){if(this.clearTimeoutFn(this._pingTimeoutTimer),this.transport.removeAllListeners("close"),this.transport.close(),this.transport.removeAllListeners(),Ac&&(this._beforeunloadEventListener&&removeEventListener("beforeunload",this._beforeunloadEventListener,!1),this._offlineEventListener)){const r=ol.indexOf(this._offlineEventListener);r!==-1&&ol.splice(r,1)}this.readyState="closed",this.id=null,this.emitReserved("close",t,n),this.writeBuffer=[],this._prevBufferLen=0}}}ar.protocol=Zy;class Ib extends ar{constructor(){super(...arguments),this._upgrades=[]}onOpen(){if(super.onOpen(),this.readyState==="open"&&this.opts.upgrade)for(let t=0;t<this._upgrades.length;t++)this._probe(this._upgrades[t])}_probe(t){let n=this.createTransport(t),r=!1;ar.priorWebsocketSuccess=!1;const i=()=>{r||(n.send([{type:"ping",data:"probe"}]),n.once("packet",u=>{if(!r)if(u.type==="pong"&&u.data==="probe"){if(this.upgrading=!0,this.emitReserved("upgrading",n),!n)return;ar.priorWebsocketSuccess=n.name==="websocket",this.transport.pause(()=>{r||this.readyState!=="closed"&&(f(),this.setTransport(n),n.send([{type:"upgrade"}]),this.emitReserved("upgrade",n),n=null,this.upgrading=!1,this.flush())})}else{const d=new Error("probe error");d.transport=n.name,this.emitReserved("upgradeError",d)}}))};function s(){r||(r=!0,f(),n.close(),n=null)}const o=u=>{const d=new Error("probe error: "+u);d.transport=n.name,s(),this.emitReserved("upgradeError",d)};function l(){o("transport closed")}function a(){o("socket closed")}function c(u){n&&u.name!==n.name&&s()}const f=()=>{n.removeListener("open",i),n.removeListener("error",o),n.removeListener("close",l),this.off("close",a),this.off("upgrading",c)};n.once("open",i),n.once("error",o),n.once("close",l),this.once("close",a),this.once("upgrading",c),this._upgrades.indexOf("webtransport")!==-1&&t!=="webtransport"?this.setTimeoutFn(()=>{r||n.open()},200):n.open()}onHandshake(t){this._upgrades=this._filterUpgrades(t.upgrades),super.onHandshake(t)}_filterUpgrades(t){const n=[];for(let r=0;r<t.length;r++)~this.transports.indexOf(t[r])&&n.push(t[r]);return n}}let Db=class extends Ib{constructor(t,n={}){const r=typeof t=="object"?t:n;(!r.transports||r.transports&&typeof r.transports[0]=="string")&&(r.transports=(r.transports||["polling","websocket","webtransport"]).map(i=>Pb[i]).filter(i=>!!i)),super(t,r)}};function Lb(e,t="",n){let r=e;n=n||typeof location<"u"&&location,e==null&&(e=n.protocol+"//"+n.host),typeof e=="string"&&(e.charAt(0)==="/"&&(e.charAt(1)==="/"?e=n.protocol+e:e=n.host+e),/^(https?|wss?):\/\//.test(e)||(typeof n<"u"?e=n.protocol+"//"+e:e="https://"+e),r=Pc(e)),r.port||(/^(http|ws)$/.test(r.protocol)?r.port="80":/^(http|ws)s$/.test(r.protocol)&&(r.port="443")),r.path=r.path||"/";const s=r.host.indexOf(":")!==-1?"["+r.host+"]":r.host;return r.id=r.protocol+"://"+s+":"+r.port+t,r.href=r.protocol+"://"+s+(n&&n.port===r.port?"":":"+r.port),r}const Mb=typeof ArrayBuffer=="function",zb=e=>typeof ArrayBuffer.isView=="function"?ArrayBuffer.isView(e):e.buffer instanceof ArrayBuffer,ig=Object.prototype.toString,Bb=typeof Blob=="function"||typeof Blob<"u"&&ig.call(Blob)==="[object BlobConstructor]",Ub=typeof File=="function"||typeof File<"u"&&ig.call(File)==="[object FileConstructor]";function Jf(e){return Mb&&(e instanceof ArrayBuffer||zb(e))||Bb&&e instanceof Blob||Ub&&e instanceof File}function ll(e,t){if(!e||typeof e!="object")return!1;if(Array.isArray(e)){for(let n=0,r=e.length;n<r;n++)if(ll(e[n]))return!0;return!1}if(Jf(e))return!0;if(e.toJSON&&typeof e.toJSON=="function"&&arguments.length===1)return ll(e.toJSON(),!0);for(const n in e)if(Object.prototype.hasOwnProperty.call(e,n)&&ll(e[n]))return!0;return!1}function Vb(e){const t=[],n=e.data,r=e;return r.data=jc(n,t),r.attachments=t.length,{packet:r,buffers:t}}function jc(e,t){if(!e)return e;if(Jf(e)){const n={_placeholder:!0,num:t.length};return t.push(e),n}else if(Array.isArray(e)){const n=new Array(e.length);for(let r=0;r<e.length;r++)n[r]=jc(e[r],t);return n}else if(typeof e=="object"&&!(e instanceof Date)){const n={};for(const r in e)Object.prototype.hasOwnProperty.call(e,r)&&(n[r]=jc(e[r],t));return n}return e}function Hb(e,t){return e.data=Fc(e.data,t),delete e.attachments,e}function Fc(e,t){if(!e)return e;if(e&&e._placeholder===!0){if(typeof e.num=="number"&&e.num>=0&&e.num<t.length)return t[e.num];throw new Error("illegal attachments")}else if(Array.isArray(e))for(let n=0;n<e.length;n++)e[n]=Fc(e[n],t);else if(typeof e=="object")for(const n in e)Object.prototype.hasOwnProperty.call(e,n)&&(e[n]=Fc(e[n],t));return e}const Wb=["connect","connect_error","disconnect","disconnecting","newListener","removeListener"],Qb=5;var X;(function(e){e[e.CONNECT=0]="CONNECT",e[e.DISCONNECT=1]="DISCONNECT",e[e.EVENT=2]="EVENT",e[e.ACK=3]="ACK",e[e.CONNECT_ERROR=4]="CONNECT_ERROR",e[e.BINARY_EVENT=5]="BINARY_EVENT",e[e.BINARY_ACK=6]="BINARY_ACK"})(X||(X={}));class qb{constructor(t){this.replacer=t}encode(t){return(t.type===X.EVENT||t.type===X.ACK)&&ll(t)?this.encodeAsBinary({type:t.type===X.EVENT?X.BINARY_EVENT:X.BINARY_ACK,nsp:t.nsp,data:t.data,id:t.id}):[this.encodeAsString(t)]}encodeAsString(t){let n=""+t.type;return(t.type===X.BINARY_EVENT||t.type===X.BINARY_ACK)&&(n+=t.attachments+"-"),t.nsp&&t.nsp!=="/"&&(n+=t.nsp+","),t.id!=null&&(n+=t.id),t.data!=null&&(n+=JSON.stringify(t.data,this.replacer)),n}encodeAsBinary(t){const n=Vb(t),r=this.encodeAsString(n.packet),i=n.buffers;return i.unshift(r),i}}function rp(e){return Object.prototype.toString.call(e)==="[object Object]"}class ed extends be{constructor(t){super(),this.reviver=t}add(t){let n;if(typeof t=="string"){if(this.reconstructor)throw new Error("got plaintext data when reconstructing a packet");n=this.decodeString(t);const r=n.type===X.BINARY_EVENT;r||n.type===X.BINARY_ACK?(n.type=r?X.EVENT:X.ACK,this.reconstructor=new Kb(n),n.attachments===0&&super.emitReserved("decoded",n)):super.emitReserved("decoded",n)}else if(Jf(t)||t.base64)if(this.reconstructor)n=this.reconstructor.takeBinaryData(t),n&&(this.reconstructor=null,super.emitReserved("decoded",n));else throw new Error("got binary data when not reconstructing a packet");else throw new Error("Unknown type: "+t)}decodeString(t){let n=0;const r={type:Number(t.charAt(0))};if(X[r.type]===void 0)throw new Error("unknown packet type "+r.type);if(r.type===X.BINARY_EVENT||r.type===X.BINARY_ACK){const s=n+1;for(;t.charAt(++n)!=="-"&&n!=t.length;);const o=t.substring(s,n);if(o!=Number(o)||t.charAt(n)!=="-")throw new Error("Illegal attachments");r.attachments=Number(o)}if(t.charAt(n+1)==="/"){const s=n+1;for(;++n&&!(t.charAt(n)===","||n===t.length););r.nsp=t.substring(s,n)}else r.nsp="/";const i=t.charAt(n+1);if(i!==""&&Number(i)==i){const s=n+1;for(;++n;){const o=t.charAt(n);if(o==null||Number(o)!=o){--n;break}if(n===t.length)break}r.id=Number(t.substring(s,n+1))}if(t.charAt(++n)){const s=this.tryParse(t.substr(n));if(ed.isPayloadValid(r.type,s))r.data=s;else throw new Error("invalid payload")}return r}tryParse(t){try{return JSON.parse(t,this.reviver)}catch{return!1}}static isPayloadValid(t,n){switch(t){case X.CONNECT:return rp(n);case X.DISCONNECT:return n===void 0;case X.CONNECT_ERROR:return typeof n=="string"||rp(n);case X.EVENT:case X.BINARY_EVENT:return Array.isArray(n)&&(typeof n[0]=="number"||typeof n[0]=="string"&&Wb.indexOf(n[0])===-1);case X.ACK:case X.BINARY_ACK:return Array.isArray(n)}}destroy(){this.reconstructor&&(this.reconstructor.finishedReconstruction(),this.reconstructor=null)}}class Kb{constructor(t){this.packet=t,this.buffers=[],this.reconPack=t}takeBinaryData(t){if(this.buffers.push(t),this.buffers.length===this.reconPack.attachments){const n=Hb(this.reconPack,this.buffers);return this.finishedReconstruction(),n}return null}finishedReconstruction(){this.reconPack=null,this.buffers=[]}}const Yb=Object.freeze(Object.defineProperty({__proto__:null,Decoder:ed,Encoder:qb,get PacketType(){return X},protocol:Qb},Symbol.toStringTag,{value:"Module"}));function Vt(e,t,n){return e.on(t,n),function(){e.off(t,n)}}const Gb=Object.freeze({connect:1,connect_error:1,disconnect:1,disconnecting:1,newListener:1,removeListener:1});class sg extends be{constructor(t,n,r){super(),this.connected=!1,this.recovered=!1,this.receiveBuffer=[],this.sendBuffer=[],this._queue=[],this._queueSeq=0,this.ids=0,this.acks={},this.flags={},this.io=t,this.nsp=n,r&&r.auth&&(this.auth=r.auth),this._opts=Object.assign({},r),this.io._autoConnect&&this.open()}get disconnected(){return!this.connected}subEvents(){if(this.subs)return;const t=this.io;this.subs=[Vt(t,"open",this.onopen.bind(this)),Vt(t,"packet",this.onpacket.bind(this)),Vt(t,"error",this.onerror.bind(this)),Vt(t,"close",this.onclose.bind(this))]}get active(){return!!this.subs}connect(){return this.connected?this:(this.subEvents(),this.io._reconnecting||this.io.open(),this.io._readyState==="open"&&this.onopen(),this)}open(){return this.connect()}send(...t){return t.unshift("message"),this.emit.apply(this,t),this}emit(t,...n){var r,i,s;if(Gb.hasOwnProperty(t))throw new Error('"'+t.toString()+'" is a reserved event name');if(n.unshift(t),this._opts.retries&&!this.flags.fromQueue&&!this.flags.volatile)return this._addToQueue(n),this;const o={type:X.EVENT,data:n};if(o.options={},o.options.compress=this.flags.compress!==!1,typeof n[n.length-1]=="function"){const f=this.ids++,u=n.pop();this._registerAckCallback(f,u),o.id=f}const l=(i=(r=this.io.engine)===null||r===void 0?void 0:r.transport)===null||i===void 0?void 0:i.writable,a=this.connected&&!(!((s=this.io.engine)===null||s===void 0)&&s._hasPingExpired());return this.flags.volatile&&!l||(a?(this.notifyOutgoingListeners(o),this.packet(o)):this.sendBuffer.push(o)),this.flags={},this}_registerAckCallback(t,n){var r;const i=(r=this.flags.timeout)!==null&&r!==void 0?r:this._opts.ackTimeout;if(i===void 0){this.acks[t]=n;return}const s=this.io.setTimeoutFn(()=>{delete this.acks[t];for(let l=0;l<this.sendBuffer.length;l++)this.sendBuffer[l].id===t&&this.sendBuffer.splice(l,1);n.call(this,new Error("operation has timed out"))},i),o=(...l)=>{this.io.clearTimeoutFn(s),n.apply(this,l)};o.withError=!0,this.acks[t]=o}emitWithAck(t,...n){return new Promise((r,i)=>{const s=(o,l)=>o?i(o):r(l);s.withError=!0,n.push(s),this.emit(t,...n)})}_addToQueue(t){let n;typeof t[t.length-1]=="function"&&(n=t.pop());const r={id:this._queueSeq++,tryCount:0,pending:!1,args:t,flags:Object.assign({fromQueue:!0},this.flags)};t.push((i,...s)=>r!==this._queue[0]?void 0:(i!==null?r.tryCount>this._opts.retries&&(this._queue.shift(),n&&n(i)):(this._queue.shift(),n&&n(null,...s)),r.pending=!1,this._drainQueue())),this._queue.push(r),this._drainQueue()}_drainQueue(t=!1){if(!this.connected||this._queue.length===0)return;const n=this._queue[0];n.pending&&!t||(n.pending=!0,n.tryCount++,this.flags=n.flags,this.emit.apply(this,n.args))}packet(t){t.nsp=this.nsp,this.io._packet(t)}onopen(){typeof this.auth=="function"?this.auth(t=>{this._sendConnectPacket(t)}):this._sendConnectPacket(this.auth)}_sendConnectPacket(t){this.packet({type:X.CONNECT,data:this._pid?Object.assign({pid:this._pid,offset:this._lastOffset},t):t})}onerror(t){this.connected||this.emitReserved("connect_error",t)}onclose(t,n){this.connected=!1,delete this.id,this.emitReserved("disconnect",t,n),this._clearAcks()}_clearAcks(){Object.keys(this.acks).forEach(t=>{if(!this.sendBuffer.some(r=>String(r.id)===t)){const r=this.acks[t];delete this.acks[t],r.withError&&r.call(this,new Error("socket has been disconnected"))}})}onpacket(t){if(t.nsp===this.nsp)switch(t.type){case X.CONNECT:t.data&&t.data.sid?this.onconnect(t.data.sid,t.data.pid):this.emitReserved("connect_error",new Error("It seems you are trying to reach a Socket.IO server in v2.x with a v3.x client, but they are not compatible (more information here: https://socket.io/docs/v3/migrating-from-2-x-to-3-0/)"));break;case X.EVENT:case X.BINARY_EVENT:this.onevent(t);break;case X.ACK:case X.BINARY_ACK:this.onack(t);break;case X.DISCONNECT:this.ondisconnect();break;case X.CONNECT_ERROR:this.destroy();const r=new Error(t.data.message);r.data=t.data.data,this.emitReserved("connect_error",r);break}}onevent(t){const n=t.data||[];t.id!=null&&n.push(this.ack(t.id)),this.connected?this.emitEvent(n):this.receiveBuffer.push(Object.freeze(n))}emitEvent(t){if(this._anyListeners&&this._anyListeners.length){const n=this._anyListeners.slice();for(const r of n)r.apply(this,t)}super.emit.apply(this,t),this._pid&&t.length&&typeof t[t.length-1]=="string"&&(this._lastOffset=t[t.length-1])}ack(t){const n=this;let r=!1;return function(...i){r||(r=!0,n.packet({type:X.ACK,id:t,data:i}))}}onack(t){const n=this.acks[t.id];typeof n=="function"&&(delete this.acks[t.id],n.withError&&t.data.unshift(null),n.apply(this,t.data))}onconnect(t,n){this.id=t,this.recovered=n&&this._pid===n,this._pid=n,this.connected=!0,this.emitBuffered(),this.emitReserved("connect"),this._drainQueue(!0)}emitBuffered(){this.receiveBuffer.forEach(t=>this.emitEvent(t)),this.receiveBuffer=[],this.sendBuffer.forEach(t=>{this.notifyOutgoingListeners(t),this.packet(t)}),this.sendBuffer=[]}ondisconnect(){this.destroy(),this.onclose("io server disconnect")}destroy(){this.subs&&(this.subs.forEach(t=>t()),this.subs=void 0),this.io._destroy(this)}disconnect(){return this.connected&&this.packet({type:X.DISCONNECT}),this.destroy(),this.connected&&this.onclose("io client disconnect"),this}close(){return this.disconnect()}compress(t){return this.flags.compress=t,this}get volatile(){return this.flags.volatile=!0,this}timeout(t){return this.flags.timeout=t,this}onAny(t){return this._anyListeners=this._anyListeners||[],this._anyListeners.push(t),this}prependAny(t){return this._anyListeners=this._anyListeners||[],this._anyListeners.unshift(t),this}offAny(t){if(!this._anyListeners)return this;if(t){const n=this._anyListeners;for(let r=0;r<n.length;r++)if(t===n[r])return n.splice(r,1),this}else this._anyListeners=[];return this}listenersAny(){return this._anyListeners||[]}onAnyOutgoing(t){return this._anyOutgoingListeners=this._anyOutgoingListeners||[],this._anyOutgoingListeners.push(t),this}prependAnyOutgoing(t){return this._anyOutgoingListeners=this._anyOutgoingListeners||[],this._anyOutgoingListeners.unshift(t),this}offAnyOutgoing(t){if(!this._anyOutgoingListeners)return this;if(t){const n=this._anyOutgoingListeners;for(let r=0;r<n.length;r++)if(t===n[r])return n.splice(r,1),this}else this._anyOutgoingListeners=[];return this}listenersAnyOutgoing(){return this._anyOutgoingListeners||[]}notifyOutgoingListeners(t){if(this._anyOutgoingListeners&&this._anyOutgoingListeners.length){const n=this._anyOutgoingListeners.slice();for(const r of n)r.apply(this,t.data)}}}function es(e){e=e||{},this.ms=e.min||100,this.max=e.max||1e4,this.factor=e.factor||2,this.jitter=e.jitter>0&&e.jitter<=1?e.jitter:0,this.attempts=0}es.prototype.duration=function(){var e=this.ms*Math.pow(this.factor,this.attempts++);if(this.jitter){var t=Math.random(),n=Math.floor(t*this.jitter*e);e=Math.floor(t*10)&1?e+n:e-n}return Math.min(e,this.max)|0};es.prototype.reset=function(){this.attempts=0};es.prototype.setMin=function(e){this.ms=e};es.prototype.setMax=function(e){this.max=e};es.prototype.setJitter=function(e){this.jitter=e};class $c extends be{constructor(t,n){var r;super(),this.nsps={},this.subs=[],t&&typeof t=="object"&&(n=t,t=void 0),n=n||{},n.path=n.path||"/socket.io",this.opts=n,da(this,n),this.reconnection(n.reconnection!==!1),this.reconnectionAttempts(n.reconnectionAttempts||1/0),this.reconnectionDelay(n.reconnectionDelay||1e3),this.reconnectionDelayMax(n.reconnectionDelayMax||5e3),this.randomizationFactor((r=n.randomizationFactor)!==null&&r!==void 0?r:.5),this.backoff=new es({min:this.reconnectionDelay(),max:this.reconnectionDelayMax(),jitter:this.randomizationFactor()}),this.timeout(n.timeout==null?2e4:n.timeout),this._readyState="closed",this.uri=t;const i=n.parser||Yb;this.encoder=new i.Encoder,this.decoder=new i.Decoder,this._autoConnect=n.autoConnect!==!1,this._autoConnect&&this.open()}reconnection(t){return arguments.length?(this._reconnection=!!t,t||(this.skipReconnect=!0),this):this._reconnection}reconnectionAttempts(t){return t===void 0?this._reconnectionAttempts:(this._reconnectionAttempts=t,this)}reconnectionDelay(t){var n;return t===void 0?this._reconnectionDelay:(this._reconnectionDelay=t,(n=this.backoff)===null||n===void 0||n.setMin(t),this)}randomizationFactor(t){var n;return t===void 0?this._randomizationFactor:(this._randomizationFactor=t,(n=this.backoff)===null||n===void 0||n.setJitter(t),this)}reconnectionDelayMax(t){var n;return t===void 0?this._reconnectionDelayMax:(this._reconnectionDelayMax=t,(n=this.backoff)===null||n===void 0||n.setMax(t),this)}timeout(t){return arguments.length?(this._timeout=t,this):this._timeout}maybeReconnectOnOpen(){!this._reconnecting&&this._reconnection&&this.backoff.attempts===0&&this.reconnect()}open(t){if(~this._readyState.indexOf("open"))return this;this.engine=new Db(this.uri,this.opts);const n=this.engine,r=this;this._readyState="opening",this.skipReconnect=!1;const i=Vt(n,"open",function(){r.onopen(),t&&t()}),s=l=>{this.cleanup(),this._readyState="closed",this.emitReserved("error",l),t?t(l):this.maybeReconnectOnOpen()},o=Vt(n,"error",s);if(this._timeout!==!1){const l=this._timeout,a=this.setTimeoutFn(()=>{i(),s(new Error("timeout")),n.close()},l);this.opts.autoUnref&&a.unref(),this.subs.push(()=>{this.clearTimeoutFn(a)})}return this.subs.push(i),this.subs.push(o),this}connect(t){return this.open(t)}onopen(){this.cleanup(),this._readyState="open",this.emitReserved("open");const t=this.engine;this.subs.push(Vt(t,"ping",this.onping.bind(this)),Vt(t,"data",this.ondata.bind(this)),Vt(t,"error",this.onerror.bind(this)),Vt(t,"close",this.onclose.bind(this)),Vt(this.decoder,"decoded",this.ondecoded.bind(this)))}onping(){this.emitReserved("ping")}ondata(t){try{this.decoder.add(t)}catch(n){this.onclose("parse error",n)}}ondecoded(t){fa(()=>{this.emitReserved("packet",t)},this.setTimeoutFn)}onerror(t){this.emitReserved("error",t)}socket(t,n){let r=this.nsps[t];return r?this._autoConnect&&!r.active&&r.connect():(r=new sg(this,t,n),this.nsps[t]=r),r}_destroy(t){const n=Object.keys(this.nsps);for(const r of n)if(this.nsps[r].active)return;this._close()}_packet(t){const n=this.encoder.encode(t);for(let r=0;r<n.length;r++)this.engine.write(n[r],t.options)}cleanup(){this.subs.forEach(t=>t()),this.subs.length=0,this.decoder.destroy()}_close(){this.skipReconnect=!0,this._reconnecting=!1,this.onclose("forced close")}disconnect(){return this._close()}onclose(t,n){var r;this.cleanup(),(r=this.engine)===null||r===void 0||r.close(),this.backoff.reset(),this._readyState="closed",this.emitReserved("close",t,n),this._reconnection&&!this.skipReconnect&&this.reconnect()}reconnect(){if(this._reconnecting||this.skipReconnect)return this;const t=this;if(this.backoff.attempts>=this._reconnectionAttempts)this.backoff.reset(),this.emitReserved("reconnect_failed"),this._reconnecting=!1;else{const n=this.backoff.duration();this._reconnecting=!0;const r=this.setTimeoutFn(()=>{t.skipReconnect||(this.emitReserved("reconnect_attempt",t.backoff.attempts),!t.skipReconnect&&t.open(i=>{i?(t._reconnecting=!1,t.reconnect(),this.emitReserved("reconnect_error",i)):t.onreconnect()}))},n);this.opts.autoUnref&&r.unref(),this.subs.push(()=>{this.clearTimeoutFn(r)})}}onreconnect(){const t=this.backoff.attempts;this._reconnecting=!1,this.backoff.reset(),this.emitReserved("reconnect",t)}}const ds={};function al(e,t){typeof e=="object"&&(t=e,e=void 0),t=t||{};const n=Lb(e,t.path||"/socket.io"),r=n.source,i=n.id,s=n.path,o=ds[i]&&s in ds[i].nsps,l=t.forceNew||t["force new connection"]||t.multiplex===!1||o;let a;return l?a=new $c(r,t):(ds[i]||(ds[i]=new $c(r,t)),a=ds[i]),n.query&&!t.query&&(t.query=n.queryKey),a.socket(n.path,t)}Object.assign(al,{Manager:$c,Socket:sg,io:al,connect:al});const ul=e=>{const t=document.cookie.split(";").find(n=>n.includes(e));return t?t.split("=")[1]:null},og=b.createContext(null),uo=()=>b.useContext(og),Xb=({children:e})=>{const[t,n]=b.useState(null),[r,i]=b.useState(!1),[s,o]=b.useState({}),l=()=>{const h=al(qw,{transports:["websocket"],auth:{customer_token:ul("customer_token"),device_id:ul("device_id"),customer_refresh_token:ul("customer_refresh_token")}});h.on("error",v=>{console.error("Websocket error",v)}),h.on("connect",()=>{n(h),i(!0)})},a=()=>{t&&(t.connect(),i(!0))},c=()=>{t&&(t.disconnect(),i(!1))},f=(h,v)=>{t&&(t.on(h,w=>{v(w)}),o({...s,[h]:v}))},u=h=>{t&&s[h]&&(t.off(h,s[h]),delete s[h])},d=(h,v,w)=>{t&&t.emit(h,v,w)};return _.jsx(og.Provider,{value:{socket:t,connected:r,events:s,connect:l,reconnect:a,disconnect:c,on:f,off:u,emit:d},children:e})};var fn=(e=>(e.ChatView="chat:user:view",e.ChatClose="chat:user:close",e.MessageList="message:list",e.MessageCreate="message:create",e.MessageTyping="message:typing",e.WidgetOpen="widget:open",e.WidgetClose="widget:close",e.PageChange="page-change",e))(fn||{}),Qt=(e=>(e.MessageAgentCreate="message:agent:create",e.MessageAgentTyping="message:agent:typing",e.Banned="banned",e.ChatUserClose="chat:user:close",e.ChatUserAssignee="chat:user:assignee",e))(Qt||{});const td=e=>{const t=aS(),n=(r,i)=>{var o;const s=((o=_O.find(l=>l.name===r))==null?void 0:o.path)??"/";return typeof i=="object"&&s.includes(":")?Object.entries(i).reduce((l,[a,c])=>l.replace(`:${a}`,c),s):i?`${s}?${i}`:s};return{push:(r,i)=>{t(n(r,i),e)},path:n}},Zb=()=>Rx({mutationFn:e=>oa(`clients/${e.client_id}/chats`,{method:"POST",body:JSON.stringify({inputs:e.inputs,client_id:void 0,widget_id:e.widget_id,history:e.history})})}),Jb=e=>oa(`clients/${e}/chats`),zl=e=>oa(`clients/${e}/chats`,{method:"DELETE"});function lg({children:e,defaultOpen:t}){var u,d,h,v;const n=uo(),{open:r,setOpen:i,widget:s}=yr(),o=td(),l=()=>{i(!0),n&&n.emit(fn.WidgetOpen,{})},a=()=>{i(!1),n&&n.emit(fn.WidgetClose,{})},c=()=>{i(!1),zl(s.client_id),o.push("registration")},f=async()=>{i(!1),await zl(s.client_id),o.push("registration")};return b.useEffect(()=>{if(t&&i(!0),!(!n||!s))return n.on(Qt.Banned,c),n.on(Qt.ChatUserClose,f),()=>{n.off(Qt.Banned),n.off(Qt.ChatUserClose)}},[]),_.jsxs("section",{className:"lc-relative lc-w-full lc-h-full",children:[r&&_.jsx("div",{style:{width:((d=(u=s==null?void 0:s.appearance)==null?void 0:u.design)==null?void 0:d.width)||"22.5rem",height:((v=(h=s==null?void 0:s.appearance)==null?void 0:h.design)==null?void 0:v.height)||"32rem"},className:"lc-absolute lc-bottom-8 lc-right-8 lc-z-[300] lc-bg-white lc-rounded-md lc-border",children:e}),_.jsxs("div",{className:"lc-absolute lc-bottom-0 lc-right-0 lc-z-[400]",children:[!r&&_.jsx(Gs,{size:"lg",rounded:!0,onClick:l,children:_.jsx(Ve.Chat,{className:"lc-size-6"})}),r&&_.jsx(Gs,{size:"lg",rounded:!0,onClick:a,children:_.jsx(Ve.X,{className:"lc-size-6"})})]})]})}function Xr(e){this._maxSize=e,this.clear()}Xr.prototype.clear=function(){this._size=0,this._values=Object.create(null)};Xr.prototype.get=function(e){return this._values[e]};Xr.prototype.set=function(e,t){return this._size>=this._maxSize&&this.clear(),e in this._values||this._size++,this._values[e]=t};var eE=/[^.^\]^[]+|(?=\[\]|\.\.)/g,ag=/^\d+$/,tE=/^\d/,nE=/[~`!#$%\^&*+=\-\[\]\\';,/{}|\\":<>\?]/g,rE=/^\s*(['"]?)(.*?)(\1)\s*$/,nd=512,ip=new Xr(nd),sp=new Xr(nd),op=new Xr(nd),Lr={Cache:Xr,split:Ic,normalizePath:pu,setter:function(e){var t=pu(e);return sp.get(e)||sp.set(e,function(r,i){for(var s=0,o=t.length,l=r;s<o-1;){var a=t[s];if(a==="__proto__"||a==="constructor"||a==="prototype")return r;l=l[t[s++]]}l[t[s]]=i})},getter:function(e,t){var n=pu(e);return op.get(e)||op.set(e,function(i){for(var s=0,o=n.length;s<o;)if(i!=null||!t)i=i[n[s++]];else return;return i})},join:function(e){return e.reduce(function(t,n){return t+(rd(n)||ag.test(n)?"["+n+"]":(t?".":"")+n)},"")},forEach:function(e,t,n){iE(Array.isArray(e)?e:Ic(e),t,n)}};function pu(e){return ip.get(e)||ip.set(e,Ic(e).map(function(t){return t.replace(rE,"$2")}))}function Ic(e){return e.match(eE)||[""]}function iE(e,t,n){var r=e.length,i,s,o,l;for(s=0;s<r;s++)i=e[s],i&&(lE(i)&&(i='"'+i+'"'),l=rd(i),o=!l&&/^\d+$/.test(i),t.call(n,i,l,o,s,e))}function rd(e){return typeof e=="string"&&e&&["'",'"'].indexOf(e.charAt(0))!==-1}function sE(e){return e.match(tE)&&!e.match(ag)}function oE(e){return nE.test(e)}function lE(e){return!rd(e)&&(sE(e)||oE(e))}const aE=/[A-Z\xc0-\xd6\xd8-\xde]?[a-z\xdf-\xf6\xf8-\xff]+(?:['’](?:d|ll|m|re|s|t|ve))?(?=[\xac\xb1\xd7\xf7\x00-\x2f\x3a-\x40\x5b-\x60\x7b-\xbf\u2000-\u206f \t\x0b\f\xa0\ufeff\n\r\u2028\u2029\u1680\u180e\u2000\u2001\u2002\u2003\u2004\u2005\u2006\u2007\u2008\u2009\u200a\u202f\u205f\u3000]|[A-Z\xc0-\xd6\xd8-\xde]|$)|(?:[A-Z\xc0-\xd6\xd8-\xde]|[^\ud800-\udfff\xac\xb1\xd7\xf7\x00-\x2f\x3a-\x40\x5b-\x60\x7b-\xbf\u2000-\u206f \t\x0b\f\xa0\ufeff\n\r\u2028\u2029\u1680\u180e\u2000\u2001\u2002\u2003\u2004\u2005\u2006\u2007\u2008\u2009\u200a\u202f\u205f\u3000\d+\u2700-\u27bfa-z\xdf-\xf6\xf8-\xffA-Z\xc0-\xd6\xd8-\xde])+(?:['’](?:D|LL|M|RE|S|T|VE))?(?=[\xac\xb1\xd7\xf7\x00-\x2f\x3a-\x40\x5b-\x60\x7b-\xbf\u2000-\u206f \t\x0b\f\xa0\ufeff\n\r\u2028\u2029\u1680\u180e\u2000\u2001\u2002\u2003\u2004\u2005\u2006\u2007\u2008\u2009\u200a\u202f\u205f\u3000]|[A-Z\xc0-\xd6\xd8-\xde](?:[a-z\xdf-\xf6\xf8-\xff]|[^\ud800-\udfff\xac\xb1\xd7\xf7\x00-\x2f\x3a-\x40\x5b-\x60\x7b-\xbf\u2000-\u206f \t\x0b\f\xa0\ufeff\n\r\u2028\u2029\u1680\u180e\u2000\u2001\u2002\u2003\u2004\u2005\u2006\u2007\u2008\u2009\u200a\u202f\u205f\u3000\d+\u2700-\u27bfa-z\xdf-\xf6\xf8-\xffA-Z\xc0-\xd6\xd8-\xde])|$)|[A-Z\xc0-\xd6\xd8-\xde]?(?:[a-z\xdf-\xf6\xf8-\xff]|[^\ud800-\udfff\xac\xb1\xd7\xf7\x00-\x2f\x3a-\x40\x5b-\x60\x7b-\xbf\u2000-\u206f \t\x0b\f\xa0\ufeff\n\r\u2028\u2029\u1680\u180e\u2000\u2001\u2002\u2003\u2004\u2005\u2006\u2007\u2008\u2009\u200a\u202f\u205f\u3000\d+\u2700-\u27bfa-z\xdf-\xf6\xf8-\xffA-Z\xc0-\xd6\xd8-\xde])+(?:['’](?:d|ll|m|re|s|t|ve))?|[A-Z\xc0-\xd6\xd8-\xde]+(?:['’](?:D|LL|M|RE|S|T|VE))?|\d*(?:1ST|2ND|3RD|(?![123])\dTH)(?=\b|[a-z_])|\d*(?:1st|2nd|3rd|(?![123])\dth)(?=\b|[A-Z_])|\d+|(?:[\u2700-\u27bf]|(?:\ud83c[\udde6-\uddff]){2}|[\ud800-\udbff][\udc00-\udfff])[\ufe0e\ufe0f]?(?:[\u0300-\u036f\ufe20-\ufe2f\u20d0-\u20ff]|\ud83c[\udffb-\udfff])?(?:\u200d(?:[^\ud800-\udfff]|(?:\ud83c[\udde6-\uddff]){2}|[\ud800-\udbff][\udc00-\udfff])[\ufe0e\ufe0f]?(?:[\u0300-\u036f\ufe20-\ufe2f\u20d0-\u20ff]|\ud83c[\udffb-\udfff])?)*/g,ha=e=>e.match(aE)||[],pa=e=>e[0].toUpperCase()+e.slice(1),id=(e,t)=>ha(e).join(t).toLowerCase(),ug=e=>ha(e).reduce((t,n)=>`${t}${t?n[0].toUpperCase()+n.slice(1).toLowerCase():n.toLowerCase()}`,""),uE=e=>pa(ug(e)),cE=e=>id(e,"_"),fE=e=>id(e,"-"),dE=e=>pa(id(e," ")),hE=e=>ha(e).map(pa).join(" ");var mu={words:ha,upperFirst:pa,camelCase:ug,pascalCase:uE,snakeCase:cE,kebabCase:fE,sentenceCase:dE,titleCase:hE},sd={exports:{}};sd.exports=function(e){return cg(pE(e),e)};sd.exports.array=cg;function cg(e,t){var n=e.length,r=new Array(n),i={},s=n,o=mE(t),l=yE(e);for(t.forEach(function(c){if(!l.has(c[0])||!l.has(c[1]))throw new Error("Unknown node. There is an unknown node in the supplied edges.")});s--;)i[s]||a(e[s],s,new Set);return r;function a(c,f,u){if(u.has(c)){var d;try{d=", node was:"+JSON.stringify(c)}catch{d=""}throw new Error("Cyclic dependency"+d)}if(!l.has(c))throw new Error("Found unknown node. Make sure to provided all involved nodes. Unknown node: "+JSON.stringify(c));if(!i[f]){i[f]=!0;var h=o.get(c)||new Set;if(h=Array.from(h),f=h.length){u.add(c);do{var v=h[--f];a(v,l.get(v),u)}while(f);u.delete(c)}r[--n]=c}}}function pE(e){for(var t=new Set,n=0,r=e.length;n<r;n++){var i=e[n];t.add(i[0]),t.add(i[1])}return Array.from(t)}function mE(e){for(var t=new Map,n=0,r=e.length;n<r;n++){var i=e[n];t.has(i[0])||t.set(i[0],new Set),t.has(i[1])||t.set(i[1],new Set),t.get(i[0]).add(i[1])}return t}function yE(e){for(var t=new Map,n=0,r=e.length;n<r;n++)t.set(e[n],n);return t}var gE=sd.exports;const vE=Ki(gE),wE=Object.prototype.toString,xE=Error.prototype.toString,SE=RegExp.prototype.toString,bE=typeof Symbol<"u"?Symbol.prototype.toString:()=>"",EE=/^Symbol\((.*)\)(.*)$/;function _E(e){return e!=+e?"NaN":e===0&&1/e<0?"-0":""+e}function lp(e,t=!1){if(e==null||e===!0||e===!1)return""+e;const n=typeof e;if(n==="number")return _E(e);if(n==="string")return t?`"${e}"`:e;if(n==="function")return"[Function "+(e.name||"anonymous")+"]";if(n==="symbol")return bE.call(e).replace(EE,"Symbol($1)");const r=wE.call(e).slice(8,-1);return r==="Date"?isNaN(e.getTime())?""+e:e.toISOString(e):r==="Error"||e instanceof Error?"["+xE.call(e)+"]":r==="RegExp"?SE.call(e):null}function ur(e,t){let n=lp(e,t);return n!==null?n:JSON.stringify(e,function(r,i){let s=lp(this[r],t);return s!==null?s:i},2)}function fg(e){return e==null?[]:[].concat(e)}let dg,hg,pg,kE=/\$\{\s*(\w+)\s*\}/g;dg=Symbol.toStringTag;class ap{constructor(t,n,r,i){this.name=void 0,this.message=void 0,this.value=void 0,this.path=void 0,this.type=void 0,this.params=void 0,this.errors=void 0,this.inner=void 0,this[dg]="Error",this.name="ValidationError",this.value=n,this.path=r,this.type=i,this.errors=[],this.inner=[],fg(t).forEach(s=>{if(st.isError(s)){this.errors.push(...s.errors);const o=s.inner.length?s.inner:[s];this.inner.push(...o)}else this.errors.push(s)}),this.message=this.errors.length>1?`${this.errors.length} errors occurred`:this.errors[0]}}hg=Symbol.hasInstance;pg=Symbol.toStringTag;class st extends Error{static formatError(t,n){const r=n.label||n.path||"this";return n=Object.assign({},n,{path:r,originalPath:n.path}),typeof t=="string"?t.replace(kE,(i,s)=>ur(n[s])):typeof t=="function"?t(n):t}static isError(t){return t&&t.name==="ValidationError"}constructor(t,n,r,i,s){const o=new ap(t,n,r,i);if(s)return o;super(),this.value=void 0,this.path=void 0,this.type=void 0,this.params=void 0,this.errors=[],this.inner=[],this[pg]="Error",this.name=o.name,this.message=o.message,this.type=o.type,this.value=o.value,this.path=o.path,this.errors=o.errors,this.inner=o.inner,Error.captureStackTrace&&Error.captureStackTrace(this,st)}static[hg](t){return ap[Symbol.hasInstance](t)||super[Symbol.hasInstance](t)}}let tn={default:"${path} is invalid",required:"${path} is a required field",defined:"${path} must be defined",notNull:"${path} cannot be null",oneOf:"${path} must be one of the following values: ${values}",notOneOf:"${path} must not be one of the following values: ${values}",notType:({path:e,type:t,value:n,originalValue:r})=>{const i=r!=null&&r!==n?` (cast from the value \`${ur(r,!0)}\`).`:".";return t!=="mixed"?`${e} must be a \`${t}\` type, but the final value was: \`${ur(n,!0)}\``+i:`${e} must match the configured type. The validated value was: \`${ur(n,!0)}\``+i}},et={length:"${path} must be exactly ${length} characters",min:"${path} must be at least ${min} characters",max:"${path} must be at most ${max} characters",matches:'${path} must match the following: "${regex}"',email:"${path} must be a valid email",url:"${path} must be a valid URL",uuid:"${path} must be a valid UUID",datetime:"${path} must be a valid ISO date-time",datetime_precision:"${path} must be a valid ISO date-time with a sub-second precision of exactly ${precision} digits",datetime_offset:'${path} must be a valid ISO date-time with UTC "Z" timezone',trim:"${path} must be a trimmed string",lowercase:"${path} must be a lowercase string",uppercase:"${path} must be a upper case string"},CE={min:"${path} must be greater than or equal to ${min}",max:"${path} must be less than or equal to ${max}",lessThan:"${path} must be less than ${less}",moreThan:"${path} must be greater than ${more}",positive:"${path} must be a positive number",negative:"${path} must be a negative number",integer:"${path} must be an integer"},Dc={min:"${path} field must be later than ${min}",max:"${path} field must be at earlier than ${max}"},TE={isValue:"${path} field must be ${value}"},cl={noUnknown:"${path} field has unspecified keys: ${unknown}",exact:"${path} object contains unknown properties: ${properties}"},OE={min:"${path} field must have at least ${min} items",max:"${path} field must have less than or equal to ${max} items",length:"${path} must have ${length} items"},RE={notType:e=>{const{path:t,value:n,spec:r}=e,i=r.types.length;if(Array.isArray(n)){if(n.length<i)return`${t} tuple value has too few items, expected a length of ${i} but got ${n.length} for value: \`${ur(n,!0)}\``;if(n.length>i)return`${t} tuple value has too many items, expected a length of ${i} but got ${n.length} for value: \`${ur(n,!0)}\``}return st.formatError(tn.notType,e)}};Object.assign(Object.create(null),{mixed:tn,string:et,number:CE,date:Dc,object:cl,array:OE,boolean:TE,tuple:RE});const od=e=>e&&e.__isYupSchema__;class Bl{static fromOptions(t,n){if(!n.then&&!n.otherwise)throw new TypeError("either `then:` or `otherwise:` is required for `when()` conditions");let{is:r,then:i,otherwise:s}=n,o=typeof r=="function"?r:(...l)=>l.every(a=>a===r);return new Bl(t,(l,a)=>{var c;let f=o(...l)?i:s;return(c=f==null?void 0:f(a))!=null?c:a})}constructor(t,n){this.fn=void 0,this.refs=t,this.refs=t,this.fn=n}resolve(t,n){let r=this.refs.map(s=>s.getValue(n==null?void 0:n.value,n==null?void 0:n.parent,n==null?void 0:n.context)),i=this.fn(r,t,n);if(i===void 0||i===t)return t;if(!od(i))throw new TypeError("conditions must return a schema object");return i.resolve(n)}}const Uo={context:"$",value:"."};class Zr{constructor(t,n={}){if(this.key=void 0,this.isContext=void 0,this.isValue=void 0,this.isSibling=void 0,this.path=void 0,this.getter=void 0,this.map=void 0,typeof t!="string")throw new TypeError("ref must be a string, got: "+t);if(this.key=t.trim(),t==="")throw new TypeError("ref must be a non-empty string");this.isContext=this.key[0]===Uo.context,this.isValue=this.key[0]===Uo.value,this.isSibling=!this.isContext&&!this.isValue;let r=this.isContext?Uo.context:this.isValue?Uo.value:"";this.path=this.key.slice(r.length),this.getter=this.path&&Lr.getter(this.path,!0),this.map=n.map}getValue(t,n,r){let i=this.isContext?r:this.isValue?t:n;return this.getter&&(i=this.getter(i||{})),this.map&&(i=this.map(i)),i}cast(t,n){return this.getValue(t,n==null?void 0:n.parent,n==null?void 0:n.context)}resolve(){return this}describe(){return{type:"ref",key:this.key}}toString(){return`Ref(${this.key})`}static isRef(t){return t&&t.__isYupRef}}Zr.prototype.__isYupRef=!0;const Tr=e=>e==null;function si(e){function t({value:n,path:r="",options:i,originalValue:s,schema:o},l,a){const{name:c,test:f,params:u,message:d,skipAbsent:h}=e;let{parent:v,context:w,abortEarly:S=o.spec.abortEarly,disableStackTrace:m=o.spec.disableStackTrace}=i;function p(B){return Zr.isRef(B)?B.getValue(n,v,w):B}function g(B={}){const se=Object.assign({value:n,originalValue:s,label:o.spec.label,path:B.path||r,spec:o.spec,disableStackTrace:B.disableStackTrace||m},u,B.params);for(const He of Object.keys(se))se[He]=p(se[He]);const oe=new st(st.formatError(B.message||d,se),n,se.path,B.type||c,se.disableStackTrace);return oe.params=se,oe}const x=S?l:a;let C={path:r,parent:v,type:c,from:i.from,createError:g,resolve:p,options:i,originalValue:s,schema:o};const T=B=>{st.isError(B)?x(B):B?a(null):x(g())},k=B=>{st.isError(B)?x(B):l(B)};if(h&&Tr(n))return T(!0);let I;try{var L;if(I=f.call(C,n,C),typeof((L=I)==null?void 0:L.then)=="function"){if(i.sync)throw new Error(`Validation test of type: "${C.type}" returned a Promise during a synchronous validate. This test will finish after the validate call has returned`);return Promise.resolve(I).then(T,k)}}catch(B){k(B);return}T(I)}return t.OPTIONS=e,t}function NE(e,t,n,r=n){let i,s,o;return t?(Lr.forEach(t,(l,a,c)=>{let f=a?l.slice(1,l.length-1):l;e=e.resolve({context:r,parent:i,value:n});let u=e.type==="tuple",d=c?parseInt(f,10):0;if(e.innerType||u){if(u&&!c)throw new Error(`Yup.reach cannot implicitly index into a tuple type. the path part "${o}" must contain an index to the tuple element, e.g. "${o}[0]"`);if(n&&d>=n.length)throw new Error(`Yup.reach cannot resolve an array item at index: ${l}, in the path: ${t}. because there is no value at that index. `);i=n,n=n&&n[d],e=u?e.spec.types[d]:e.innerType}if(!c){if(!e.fields||!e.fields[f])throw new Error(`The schema does not contain the path: ${t}. (failed at: ${o} which is a type: "${e.type}")`);i=n,n=n&&n[f],e=e.fields[f]}s=f,o=a?"["+l+"]":"."+l}),{schema:e,parent:i,parentPath:s}):{parent:i,parentPath:t,schema:e}}class Ul extends Set{describe(){const t=[];for(const n of this.values())t.push(Zr.isRef(n)?n.describe():n);return t}resolveAll(t){let n=[];for(const r of this.values())n.push(t(r));return n}clone(){return new Ul(this.values())}merge(t,n){const r=this.clone();return t.forEach(i=>r.add(i)),n.forEach(i=>r.delete(i)),r}}function vi(e,t=new Map){if(od(e)||!e||typeof e!="object")return e;if(t.has(e))return t.get(e);let n;if(e instanceof Date)n=new Date(e.getTime()),t.set(e,n);else if(e instanceof RegExp)n=new RegExp(e),t.set(e,n);else if(Array.isArray(e)){n=new Array(e.length),t.set(e,n);for(let r=0;r<e.length;r++)n[r]=vi(e[r],t)}else if(e instanceof Map){n=new Map,t.set(e,n);for(const[r,i]of e.entries())n.set(r,vi(i,t))}else if(e instanceof Set){n=new Set,t.set(e,n);for(const r of e)n.add(vi(r,t))}else if(e instanceof Object){n={},t.set(e,n);for(const[r,i]of Object.entries(e))n[r]=vi(i,t)}else throw Error(`Unable to clone ${e}`);return n}class hn{constructor(t){this.type=void 0,this.deps=[],this.tests=void 0,this.transforms=void 0,this.conditions=[],this._mutate=void 0,this.internalTests={},this._whitelist=new Ul,this._blacklist=new Ul,this.exclusiveTests=Object.create(null),this._typeCheck=void 0,this.spec=void 0,this.tests=[],this.transforms=[],this.withMutation(()=>{this.typeError(tn.notType)}),this.type=t.type,this._typeCheck=t.check,this.spec=Object.assign({strip:!1,strict:!1,abortEarly:!0,recursive:!0,disableStackTrace:!1,nullable:!1,optional:!0,coerce:!0},t==null?void 0:t.spec),this.withMutation(n=>{n.nonNullable()})}get _type(){return this.type}clone(t){if(this._mutate)return t&&Object.assign(this.spec,t),this;const n=Object.create(Object.getPrototypeOf(this));return n.type=this.type,n._typeCheck=this._typeCheck,n._whitelist=this._whitelist.clone(),n._blacklist=this._blacklist.clone(),n.internalTests=Object.assign({},this.internalTests),n.exclusiveTests=Object.assign({},this.exclusiveTests),n.deps=[...this.deps],n.conditions=[...this.conditions],n.tests=[...this.tests],n.transforms=[...this.transforms],n.spec=vi(Object.assign({},this.spec,t)),n}label(t){let n=this.clone();return n.spec.label=t,n}meta(...t){if(t.length===0)return this.spec.meta;let n=this.clone();return n.spec.meta=Object.assign(n.spec.meta||{},t[0]),n}withMutation(t){let n=this._mutate;this._mutate=!0;let r=t(this);return this._mutate=n,r}concat(t){if(!t||t===this)return this;if(t.type!==this.type&&this.type!=="mixed")throw new TypeError(`You cannot \`concat()\` schema's of different types: ${this.type} and ${t.type}`);let n=this,r=t.clone();const i=Object.assign({},n.spec,r.spec);return r.spec=i,r.internalTests=Object.assign({},n.internalTests,r.internalTests),r._whitelist=n._whitelist.merge(t._whitelist,t._blacklist),r._blacklist=n._blacklist.merge(t._blacklist,t._whitelist),r.tests=n.tests,r.exclusiveTests=n.exclusiveTests,r.withMutation(s=>{t.tests.forEach(o=>{s.test(o.OPTIONS)})}),r.transforms=[...n.transforms,...r.transforms],r}isType(t){return t==null?!!(this.spec.nullable&&t===null||this.spec.optional&&t===void 0):this._typeCheck(t)}resolve(t){let n=this;if(n.conditions.length){let r=n.conditions;n=n.clone(),n.conditions=[],n=r.reduce((i,s)=>s.resolve(i,t),n),n=n.resolve(t)}return n}resolveOptions(t){var n,r,i,s;return Object.assign({},t,{from:t.from||[],strict:(n=t.strict)!=null?n:this.spec.strict,abortEarly:(r=t.abortEarly)!=null?r:this.spec.abortEarly,recursive:(i=t.recursive)!=null?i:this.spec.recursive,disableStackTrace:(s=t.disableStackTrace)!=null?s:this.spec.disableStackTrace})}cast(t,n={}){let r=this.resolve(Object.assign({value:t},n)),i=n.assert==="ignore-optionality",s=r._cast(t,n);if(n.assert!==!1&&!r.isType(s)){if(i&&Tr(s))return s;let o=ur(t),l=ur(s);throw new TypeError(`The value of ${n.path||"field"} could not be cast to a value that satisfies the schema type: "${r.type}".
79
79
 
80
80
  attempted value: ${o}
81
- `+(l!==o?`result of cast: ${l}`:""))}return s}_cast(t,n){let r=t===void 0?t:this.transforms.reduce((i,s)=>s.call(this,i,t,this),t);return r===void 0&&(r=this.getDefault(n)),r}_validate(t,n={},r,i){let{path:s,originalValue:o=t,strict:l=this.spec.strict}=n,a=t;l||(a=this._cast(a,Object.assign({assert:!1},n)));let c=[];for(let f of Object.values(this.internalTests))f&&c.push(f);this.runTests({path:s,value:a,originalValue:o,options:n,tests:c},r,f=>{if(f.length)return i(f,a);this.runTests({path:s,value:a,originalValue:o,options:n,tests:this.tests},r,i)})}runTests(t,n,r){let i=!1,{tests:s,value:o,originalValue:l,path:a,options:c}=t,f=w=>{i||(i=!0,n(w,o))},u=w=>{i||(i=!0,r(w,o))},d=s.length,h=[];if(!d)return u([]);let v={value:o,originalValue:l,path:a,options:c,schema:this};for(let w=0;w<s.length;w++){const S=s[w];S(v,f,function(p){p&&(Array.isArray(p)?h.push(...p):h.push(p)),--d<=0&&u(h)})}}asNestedTest({key:t,index:n,parent:r,parentPath:i,originalParent:s,options:o}){const l=t??n;if(l==null)throw TypeError("Must include `key` or `index` for nested validations");const a=typeof l=="number";let c=r[l];const f=Object.assign({},o,{strict:!0,parent:r,value:c,originalValue:s[l],key:void 0,[a?"index":"key"]:l,path:a||l.includes(".")?`${i||""}[${a?l:`"${l}"`}]`:(i?`${i}.`:"")+t});return(u,d,h)=>this.resolve(f)._validate(c,f,d,h)}validate(t,n){var r;let i=this.resolve(Object.assign({},n,{value:t})),s=(r=n==null?void 0:n.disableStackTrace)!=null?r:i.spec.disableStackTrace;return new Promise((o,l)=>i._validate(t,n,(a,c)=>{st.isError(a)&&(a.value=c),l(a)},(a,c)=>{a.length?l(new st(a,c,void 0,void 0,s)):o(c)}))}validateSync(t,n){var r;let i=this.resolve(Object.assign({},n,{value:t})),s,o=(r=n==null?void 0:n.disableStackTrace)!=null?r:i.spec.disableStackTrace;return i._validate(t,Object.assign({},n,{sync:!0}),(l,a)=>{throw st.isError(l)&&(l.value=a),l},(l,a)=>{if(l.length)throw new st(l,t,void 0,void 0,o);s=a}),s}isValid(t,n){return this.validate(t,n).then(()=>!0,r=>{if(st.isError(r))return!1;throw r})}isValidSync(t,n){try{return this.validateSync(t,n),!0}catch(r){if(st.isError(r))return!1;throw r}}_getDefault(t){let n=this.spec.default;return n==null?n:typeof n=="function"?n.call(this,t):vi(n)}getDefault(t){return this.resolve(t||{})._getDefault(t)}default(t){return arguments.length===0?this._getDefault():this.clone({default:t})}strict(t=!0){return this.clone({strict:t})}nullability(t,n){const r=this.clone({nullable:t});return r.internalTests.nullable=si({message:n,name:"nullable",test(i){return i===null?this.schema.spec.nullable:!0}}),r}optionality(t,n){const r=this.clone({optional:t});return r.internalTests.optionality=si({message:n,name:"optionality",test(i){return i===void 0?this.schema.spec.optional:!0}}),r}optional(){return this.optionality(!0)}defined(t=tn.defined){return this.optionality(!1,t)}nullable(){return this.nullability(!0)}nonNullable(t=tn.notNull){return this.nullability(!1,t)}required(t=tn.required){return this.clone().withMutation(n=>n.nonNullable(t).defined(t))}notRequired(){return this.clone().withMutation(t=>t.nullable().optional())}transform(t){let n=this.clone();return n.transforms.push(t),n}test(...t){let n;if(t.length===1?typeof t[0]=="function"?n={test:t[0]}:n=t[0]:t.length===2?n={name:t[0],test:t[1]}:n={name:t[0],message:t[1],test:t[2]},n.message===void 0&&(n.message=tn.default),typeof n.test!="function")throw new TypeError("`test` is a required parameters");let r=this.clone(),i=si(n),s=n.exclusive||n.name&&r.exclusiveTests[n.name]===!0;if(n.exclusive&&!n.name)throw new TypeError("Exclusive tests must provide a unique `name` identifying the test");return n.name&&(r.exclusiveTests[n.name]=!!n.exclusive),r.tests=r.tests.filter(o=>!(o.OPTIONS.name===n.name&&(s||o.OPTIONS.test===i.OPTIONS.test))),r.tests.push(i),r}when(t,n){!Array.isArray(t)&&typeof t!="string"&&(n=t,t=".");let r=this.clone(),i=fy(t).map(s=>new Zr(s));return i.forEach(s=>{s.isSibling&&r.deps.push(s.key)}),r.conditions.push(typeof n=="function"?new Bl(i,n):Bl.fromOptions(i,n)),r}typeError(t){let n=this.clone();return n.internalTests.typeError=si({message:t,name:"typeError",skipAbsent:!0,test(r){return this.schema._typeCheck(r)?!0:this.createError({params:{type:this.schema.type}})}}),n}oneOf(t,n=tn.oneOf){let r=this.clone();return t.forEach(i=>{r._whitelist.add(i),r._blacklist.delete(i)}),r.internalTests.whiteList=si({message:n,name:"oneOf",skipAbsent:!0,test(i){let s=this.schema._whitelist,o=s.resolveAll(this.resolve);return o.includes(i)?!0:this.createError({params:{values:Array.from(s).join(", "),resolved:o}})}}),r}notOneOf(t,n=tn.notOneOf){let r=this.clone();return t.forEach(i=>{r._blacklist.add(i),r._whitelist.delete(i)}),r.internalTests.blacklist=si({message:n,name:"notOneOf",test(i){let s=this.schema._blacklist,o=s.resolveAll(this.resolve);return o.includes(i)?this.createError({params:{values:Array.from(s).join(", "),resolved:o}}):!0}}),r}strip(t=!0){let n=this.clone();return n.spec.strip=t,n}describe(t){const n=(t?this.resolve(t):this).clone(),{label:r,meta:i,optional:s,nullable:o}=n.spec;return{meta:i,label:r,optional:s,nullable:o,default:n.getDefault(t),type:n.type,oneOf:n._whitelist.describe(),notOneOf:n._blacklist.describe(),tests:n.tests.map(a=>({name:a.OPTIONS.name,params:a.OPTIONS.params})).filter((a,c,f)=>f.findIndex(u=>u.name===a.name)===c)}}}hn.prototype.__isYupSchema__=!0;for(const e of["validate","validateSync"])hn.prototype[`${e}At`]=function(t,n,r={}){const{parent:i,parentPath:s,schema:o}=RE(this,t,n,r.context);return o[e](i&&i[s],Object.assign({},r,{parent:i,path:t}))};for(const e of["equals","is"])hn.prototype[e]=hn.prototype.oneOf;for(const e of["not","nope"])hn.prototype[e]=hn.prototype.notOneOf;const NE=/^(\d{4}|[+-]\d{6})(?:-?(\d{2})(?:-?(\d{2}))?)?(?:[ T]?(\d{2}):?(\d{2})(?::?(\d{2})(?:[,.](\d{1,}))?)?(?:(Z)|([+-])(\d{2})(?::?(\d{2}))?)?)?$/;function PE(e){const t=Dc(e);if(!t)return Date.parse?Date.parse(e):Number.NaN;if(t.z===void 0&&t.plusMinus===void 0)return new Date(t.year,t.month,t.day,t.hour,t.minute,t.second,t.millisecond).valueOf();let n=0;return t.z!=="Z"&&t.plusMinus!==void 0&&(n=t.hourOffset*60+t.minuteOffset,t.plusMinus==="+"&&(n=0-n)),Date.UTC(t.year,t.month,t.day,t.hour,t.minute+n,t.second,t.millisecond)}function Dc(e){var t,n;const r=NE.exec(e);return r?{year:gn(r[1]),month:gn(r[2],1)-1,day:gn(r[3],1),hour:gn(r[4]),minute:gn(r[5]),second:gn(r[6]),millisecond:r[7]?gn(r[7].substring(0,3)):0,precision:(t=(n=r[7])==null?void 0:n.length)!=null?t:void 0,z:r[8]||void 0,plusMinus:r[9]||void 0,hourOffset:gn(r[10]),minuteOffset:gn(r[11])}:null}function gn(e,t=0){return Number(e)||t}let AE=/^[a-zA-Z0-9.!#$%&'*+\/=?^_`{|}~-]+@[a-zA-Z0-9](?:[a-zA-Z0-9-]{0,61}[a-zA-Z0-9])?(?:\.[a-zA-Z0-9](?:[a-zA-Z0-9-]{0,61}[a-zA-Z0-9])?)*$/,jE=/^((https?|ftp):)?\/\/(((([a-z]|\d|-|\.|_|~|[\u00A0-\uD7FF\uF900-\uFDCF\uFDF0-\uFFEF])|(%[\da-f]{2})|[!\$&'\(\)\*\+,;=]|:)*@)?(((\d|[1-9]\d|1\d\d|2[0-4]\d|25[0-5])\.(\d|[1-9]\d|1\d\d|2[0-4]\d|25[0-5])\.(\d|[1-9]\d|1\d\d|2[0-4]\d|25[0-5])\.(\d|[1-9]\d|1\d\d|2[0-4]\d|25[0-5]))|((([a-z]|\d|[\u00A0-\uD7FF\uF900-\uFDCF\uFDF0-\uFFEF])|(([a-z]|\d|[\u00A0-\uD7FF\uF900-\uFDCF\uFDF0-\uFFEF])([a-z]|\d|-|\.|_|~|[\u00A0-\uD7FF\uF900-\uFDCF\uFDF0-\uFFEF])*([a-z]|\d|[\u00A0-\uD7FF\uF900-\uFDCF\uFDF0-\uFFEF])))\.)+(([a-z]|[\u00A0-\uD7FF\uF900-\uFDCF\uFDF0-\uFFEF])|(([a-z]|[\u00A0-\uD7FF\uF900-\uFDCF\uFDF0-\uFFEF])([a-z]|\d|-|\.|_|~|[\u00A0-\uD7FF\uF900-\uFDCF\uFDF0-\uFFEF])*([a-z]|[\u00A0-\uD7FF\uF900-\uFDCF\uFDF0-\uFFEF])))\.?)(:\d*)?)(\/((([a-z]|\d|-|\.|_|~|[\u00A0-\uD7FF\uF900-\uFDCF\uFDF0-\uFFEF])|(%[\da-f]{2})|[!\$&'\(\)\*\+,;=]|:|@)+(\/(([a-z]|\d|-|\.|_|~|[\u00A0-\uD7FF\uF900-\uFDCF\uFDF0-\uFFEF])|(%[\da-f]{2})|[!\$&'\(\)\*\+,;=]|:|@)*)*)?)?(\?((([a-z]|\d|-|\.|_|~|[\u00A0-\uD7FF\uF900-\uFDCF\uFDF0-\uFFEF])|(%[\da-f]{2})|[!\$&'\(\)\*\+,;=]|:|@)|[\uE000-\uF8FF]|\/|\?)*)?(\#((([a-z]|\d|-|\.|_|~|[\u00A0-\uD7FF\uF900-\uFDCF\uFDF0-\uFFEF])|(%[\da-f]{2})|[!\$&'\(\)\*\+,;=]|:|@)|\/|\?)*)?$/i,FE=/^(?:[0-9a-f]{8}-[0-9a-f]{4}-[1-5][0-9a-f]{3}-[89ab][0-9a-f]{3}-[0-9a-f]{12}|00000000-0000-0000-0000-000000000000)$/i,$E="^\\d{4}-\\d{2}-\\d{2}",IE="\\d{2}:\\d{2}:\\d{2}",LE="(([+-]\\d{2}(:?\\d{2})?)|Z)",DE=new RegExp(`${$E}T${IE}(\\.\\d+)?${LE}$`),ME=e=>Tr(e)||e===e.trim(),zE={}.toString();function Mc(){return new my}class my extends hn{constructor(){super({type:"string",check(t){return t instanceof String&&(t=t.valueOf()),typeof t=="string"}}),this.withMutation(()=>{this.transform((t,n,r)=>{if(!r.spec.coerce||r.isType(t)||Array.isArray(t))return t;const i=t!=null&&t.toString?t.toString():t;return i===zE?t:i})})}required(t){return super.required(t).withMutation(n=>n.test({message:t||tn.required,name:"required",skipAbsent:!0,test:r=>!!r.length}))}notRequired(){return super.notRequired().withMutation(t=>(t.tests=t.tests.filter(n=>n.OPTIONS.name!=="required"),t))}length(t,n=et.length){return this.test({message:n,name:"length",exclusive:!0,params:{length:t},skipAbsent:!0,test(r){return r.length===this.resolve(t)}})}min(t,n=et.min){return this.test({message:n,name:"min",exclusive:!0,params:{min:t},skipAbsent:!0,test(r){return r.length>=this.resolve(t)}})}max(t,n=et.max){return this.test({name:"max",exclusive:!0,message:n,params:{max:t},skipAbsent:!0,test(r){return r.length<=this.resolve(t)}})}matches(t,n){let r=!1,i,s;return n&&(typeof n=="object"?{excludeEmptyString:r=!1,message:i,name:s}=n:i=n),this.test({name:s||"matches",message:i||et.matches,params:{regex:t},skipAbsent:!0,test:o=>o===""&&r||o.search(t)!==-1})}email(t=et.email){return this.matches(AE,{name:"email",message:t,excludeEmptyString:!0})}url(t=et.url){return this.matches(jE,{name:"url",message:t,excludeEmptyString:!0})}uuid(t=et.uuid){return this.matches(FE,{name:"uuid",message:t,excludeEmptyString:!1})}datetime(t){let n="",r,i;return t&&(typeof t=="object"?{message:n="",allowOffset:r=!1,precision:i=void 0}=t:n=t),this.matches(DE,{name:"datetime",message:n||et.datetime,excludeEmptyString:!0}).test({name:"datetime_offset",message:n||et.datetime_offset,params:{allowOffset:r},skipAbsent:!0,test:s=>{if(!s||r)return!0;const o=Dc(s);return o?!!o.z:!1}}).test({name:"datetime_precision",message:n||et.datetime_precision,params:{precision:i},skipAbsent:!0,test:s=>{if(!s||i==null)return!0;const o=Dc(s);return o?o.precision===i:!1}})}ensure(){return this.default("").transform(t=>t===null?"":t)}trim(t=et.trim){return this.transform(n=>n!=null?n.trim():n).test({message:t,name:"trim",test:ME})}lowercase(t=et.lowercase){return this.transform(n=>Tr(n)?n:n.toLowerCase()).test({message:t,name:"string_case",exclusive:!0,skipAbsent:!0,test:n=>Tr(n)||n===n.toLowerCase()})}uppercase(t=et.uppercase){return this.transform(n=>Tr(n)?n:n.toUpperCase()).test({message:t,name:"string_case",exclusive:!0,skipAbsent:!0,test:n=>Tr(n)||n===n.toUpperCase()})}}Mc.prototype=my.prototype;let BE=new Date(""),UE=e=>Object.prototype.toString.call(e)==="[object Date]";class ma extends hn{constructor(){super({type:"date",check(t){return UE(t)&&!isNaN(t.getTime())}}),this.withMutation(()=>{this.transform((t,n,r)=>!r.spec.coerce||r.isType(t)||t===null?t:(t=PE(t),isNaN(t)?ma.INVALID_DATE:new Date(t)))})}prepareParam(t,n){let r;if(Zr.isRef(t))r=t;else{let i=this.cast(t);if(!this._typeCheck(i))throw new TypeError(`\`${n}\` must be a Date or a value that can be \`cast()\` to a Date`);r=i}return r}min(t,n=Lc.min){let r=this.prepareParam(t,"min");return this.test({message:n,name:"min",exclusive:!0,params:{min:t},skipAbsent:!0,test(i){return i>=this.resolve(r)}})}max(t,n=Lc.max){let r=this.prepareParam(t,"max");return this.test({message:n,name:"max",exclusive:!0,params:{max:t},skipAbsent:!0,test(i){return i<=this.resolve(r)}})}}ma.INVALID_DATE=BE;ma.prototype;function VE(e,t=[]){let n=[],r=new Set,i=new Set(t.map(([o,l])=>`${o}-${l}`));function s(o,l){let a=Dr.split(o)[0];r.add(a),i.has(`${l}-${a}`)||n.push([l,a])}for(const o of Object.keys(e)){let l=e[o];r.add(o),Zr.isRef(l)&&l.isSibling?s(l.path,o):od(l)&&"deps"in l&&l.deps.forEach(a=>s(a,o))}return yE.array(Array.from(r),n).reverse()}function up(e,t){let n=1/0;return e.some((r,i)=>{var s;if((s=t.path)!=null&&s.includes(r))return n=i,!0}),n}function gy(e){return(t,n)=>up(e,t)-up(e,n)}const HE=(e,t,n)=>{if(typeof e!="string")return e;let r=e;try{r=JSON.parse(e)}catch{}return n.isType(r)?r:e};function fl(e){if("fields"in e){const t={};for(const[n,r]of Object.entries(e.fields))t[n]=fl(r);return e.setFields(t)}if(e.type==="array"){const t=e.optional();return t.innerType&&(t.innerType=fl(t.innerType)),t}return e.type==="tuple"?e.optional().clone({types:e.spec.types.map(fl)}):"optional"in e?e.optional():e}const WE=(e,t)=>{const n=[...Dr.normalizePath(t)];if(n.length===1)return n[0]in e;let r=n.pop(),i=Dr.getter(Dr.join(n),!0)(e);return!!(i&&r in i)};let cp=e=>Object.prototype.toString.call(e)==="[object Object]";function fp(e,t){let n=Object.keys(e.fields);return Object.keys(t).filter(r=>n.indexOf(r)===-1)}const QE=gy([]);function yy(e){return new vy(e)}class vy extends hn{constructor(t){super({type:"object",check(n){return cp(n)||typeof n=="function"}}),this.fields=Object.create(null),this._sortErrors=QE,this._nodes=[],this._excludedEdges=[],this.withMutation(()=>{t&&this.shape(t)})}_cast(t,n={}){var r;let i=super._cast(t,n);if(i===void 0)return this.getDefault(n);if(!this._typeCheck(i))return i;let s=this.fields,o=(r=n.stripUnknown)!=null?r:this.spec.noUnknown,l=[].concat(this._nodes,Object.keys(i).filter(u=>!this._nodes.includes(u))),a={},c=Object.assign({},n,{parent:a,__validating:n.__validating||!1}),f=!1;for(const u of l){let d=s[u],h=u in i;if(d){let v,w=i[u];c.path=(n.path?`${n.path}.`:"")+u,d=d.resolve({value:w,context:n.context,parent:a});let S=d instanceof hn?d.spec:void 0,m=S==null?void 0:S.strict;if(S!=null&&S.strip){f=f||u in i;continue}v=!n.__validating||!m?d.cast(i[u],c):i[u],v!==void 0&&(a[u]=v)}else h&&!o&&(a[u]=i[u]);(h!==u in a||a[u]!==i[u])&&(f=!0)}return f?a:i}_validate(t,n={},r,i){let{from:s=[],originalValue:o=t,recursive:l=this.spec.recursive}=n;n.from=[{schema:this,value:o},...s],n.__validating=!0,n.originalValue=o,super._validate(t,n,r,(a,c)=>{if(!l||!cp(c)){i(a,c);return}o=o||c;let f=[];for(let u of this._nodes){let d=this.fields[u];!d||Zr.isRef(d)||f.push(d.asNestedTest({options:n,key:u,parent:c,parentPath:n.path,originalParent:o}))}this.runTests({tests:f,value:c,originalValue:o,options:n},r,u=>{i(u.sort(this._sortErrors).concat(a),c)})})}clone(t){const n=super.clone(t);return n.fields=Object.assign({},this.fields),n._nodes=this._nodes,n._excludedEdges=this._excludedEdges,n._sortErrors=this._sortErrors,n}concat(t){let n=super.concat(t),r=n.fields;for(let[i,s]of Object.entries(this.fields)){const o=r[i];r[i]=o===void 0?s:o}return n.withMutation(i=>i.setFields(r,[...this._excludedEdges,...t._excludedEdges]))}_getDefault(t){if("default"in this.spec)return super._getDefault(t);if(!this._nodes.length)return;let n={};return this._nodes.forEach(r=>{var i;const s=this.fields[r];let o=t;(i=o)!=null&&i.value&&(o=Object.assign({},o,{parent:o.value,value:o.value[r]})),n[r]=s&&"getDefault"in s?s.getDefault(o):void 0}),n}setFields(t,n){let r=this.clone();return r.fields=t,r._nodes=VE(t,n),r._sortErrors=gy(Object.keys(t)),n&&(r._excludedEdges=n),r}shape(t,n=[]){return this.clone().withMutation(r=>{let i=r._excludedEdges;return n.length&&(Array.isArray(n[0])||(n=[n]),i=[...r._excludedEdges,...n]),r.setFields(Object.assign(r.fields,t),i)})}partial(){const t={};for(const[n,r]of Object.entries(this.fields))t[n]="optional"in r&&r.optional instanceof Function?r.optional():r;return this.setFields(t)}deepPartial(){return fl(this)}pick(t){const n={};for(const r of t)this.fields[r]&&(n[r]=this.fields[r]);return this.setFields(n,this._excludedEdges.filter(([r,i])=>t.includes(r)&&t.includes(i)))}omit(t){const n=[];for(const r of Object.keys(this.fields))t.includes(r)||n.push(r);return this.pick(n)}from(t,n,r){let i=Dr.getter(t,!0);return this.transform(s=>{if(!s)return s;let o=s;return WE(s,t)&&(o=Object.assign({},s),r||delete o[t],o[n]=i(s)),o})}json(){return this.transform(HE)}exact(t){return this.test({name:"exact",exclusive:!0,message:t||cl.exact,test(n){if(n==null)return!0;const r=fp(this.schema,n);return r.length===0||this.createError({params:{properties:r.join(", ")}})}})}stripUnknown(){return this.clone({noUnknown:!0})}noUnknown(t=!0,n=cl.noUnknown){typeof t!="boolean"&&(n=t,t=!0);let r=this.test({name:"noUnknown",exclusive:!0,message:n,test(i){if(i==null)return!0;const s=fp(this.schema,i);return!t||s.length===0||this.createError({params:{unknown:s.join(", ")}})}});return r.spec.noUnknown=t,r}unknown(t=!0,n=cl.noUnknown){return this.noUnknown(!t,n)}transformKeys(t){return this.transform(n=>{if(!n)return n;const r={};for(const i of Object.keys(n))r[t(i)]=n[i];return r})}camelCase(){return this.transformKeys(mu.camelCase)}snakeCase(){return this.transformKeys(mu.snakeCase)}constantCase(){return this.transformKeys(t=>mu.snakeCase(t).toUpperCase())}describe(t){const n=(t?this.resolve(t):this).clone(),r=super.describe(t);r.fields={};for(const[s,o]of Object.entries(n.fields)){var i;let l=t;(i=l)!=null&&i.value&&(l=Object.assign({},l,{parent:l.value,value:l.value[s]})),r.fields[s]=o.describe(l)}return r}}yy.prototype=vy.prototype;var qE=function(t){return KE(t)&&!YE(t)};function KE(e){return!!e&&typeof e=="object"}function YE(e){var t=Object.prototype.toString.call(e);return t==="[object RegExp]"||t==="[object Date]"||ZE(e)}var GE=typeof Symbol=="function"&&Symbol.for,XE=GE?Symbol.for("react.element"):60103;function ZE(e){return e.$$typeof===XE}function JE(e){return Array.isArray(e)?[]:{}}function Vl(e,t){return t.clone!==!1&&t.isMergeableObject(e)?Xs(JE(e),e,t):e}function e_(e,t,n){return e.concat(t).map(function(r){return Vl(r,n)})}function t_(e,t,n){var r={};return n.isMergeableObject(e)&&Object.keys(e).forEach(function(i){r[i]=Vl(e[i],n)}),Object.keys(t).forEach(function(i){!n.isMergeableObject(t[i])||!e[i]?r[i]=Vl(t[i],n):r[i]=Xs(e[i],t[i],n)}),r}function Xs(e,t,n){n=n||{},n.arrayMerge=n.arrayMerge||e_,n.isMergeableObject=n.isMergeableObject||qE;var r=Array.isArray(t),i=Array.isArray(e),s=r===i;return s?r?n.arrayMerge(e,t,n):t_(e,t,n):Vl(t,n)}Xs.all=function(t,n){if(!Array.isArray(t))throw new Error("first argument should be an array");return t.reduce(function(r,i){return Xs(r,i,n)},{})};var zc=Xs,wy=typeof global=="object"&&global&&global.Object===Object&&global,n_=typeof self=="object"&&self&&self.Object===Object&&self,pn=wy||n_||Function("return this")(),dr=pn.Symbol,xy=Object.prototype,r_=xy.hasOwnProperty,i_=xy.toString,hs=dr?dr.toStringTag:void 0;function s_(e){var t=r_.call(e,hs),n=e[hs];try{e[hs]=void 0;var r=!0}catch{}var i=i_.call(e);return r&&(t?e[hs]=n:delete e[hs]),i}var o_=Object.prototype,l_=o_.toString;function a_(e){return l_.call(e)}var u_="[object Null]",c_="[object Undefined]",dp=dr?dr.toStringTag:void 0;function Jr(e){return e==null?e===void 0?c_:u_:dp&&dp in Object(e)?s_(e):a_(e)}function Sy(e,t){return function(n){return e(t(n))}}var ld=Sy(Object.getPrototypeOf,Object);function ei(e){return e!=null&&typeof e=="object"}var f_="[object Object]",d_=Function.prototype,h_=Object.prototype,by=d_.toString,p_=h_.hasOwnProperty,m_=by.call(Object);function hp(e){if(!ei(e)||Jr(e)!=f_)return!1;var t=ld(e);if(t===null)return!0;var n=p_.call(t,"constructor")&&t.constructor;return typeof n=="function"&&n instanceof n&&by.call(n)==m_}function g_(){this.__data__=[],this.size=0}function Ey(e,t){return e===t||e!==e&&t!==t}function ga(e,t){for(var n=e.length;n--;)if(Ey(e[n][0],t))return n;return-1}var y_=Array.prototype,v_=y_.splice;function w_(e){var t=this.__data__,n=ga(t,e);if(n<0)return!1;var r=t.length-1;return n==r?t.pop():v_.call(t,n,1),--this.size,!0}function x_(e){var t=this.__data__,n=ga(t,e);return n<0?void 0:t[n][1]}function S_(e){return ga(this.__data__,e)>-1}function b_(e,t){var n=this.__data__,r=ga(n,e);return r<0?(++this.size,n.push([e,t])):n[r][1]=t,this}function Pn(e){var t=-1,n=e==null?0:e.length;for(this.clear();++t<n;){var r=e[t];this.set(r[0],r[1])}}Pn.prototype.clear=g_;Pn.prototype.delete=w_;Pn.prototype.get=x_;Pn.prototype.has=S_;Pn.prototype.set=b_;function E_(){this.__data__=new Pn,this.size=0}function __(e){var t=this.__data__,n=t.delete(e);return this.size=t.size,n}function k_(e){return this.__data__.get(e)}function C_(e){return this.__data__.has(e)}function co(e){var t=typeof e;return e!=null&&(t=="object"||t=="function")}var T_="[object AsyncFunction]",O_="[object Function]",R_="[object GeneratorFunction]",N_="[object Proxy]";function _y(e){if(!co(e))return!1;var t=Jr(e);return t==O_||t==R_||t==T_||t==N_}var gu=pn["__core-js_shared__"],pp=function(){var e=/[^.]+$/.exec(gu&&gu.keys&&gu.keys.IE_PROTO||"");return e?"Symbol(src)_1."+e:""}();function P_(e){return!!pp&&pp in e}var A_=Function.prototype,j_=A_.toString;function ti(e){if(e!=null){try{return j_.call(e)}catch{}try{return e+""}catch{}}return""}var F_=/[\\^$.*+?()[\]{}|]/g,$_=/^\[object .+?Constructor\]$/,I_=Function.prototype,L_=Object.prototype,D_=I_.toString,M_=L_.hasOwnProperty,z_=RegExp("^"+D_.call(M_).replace(F_,"\\$&").replace(/hasOwnProperty|(function).*?(?=\\\()| for .+?(?=\\\])/g,"$1.*?")+"$");function B_(e){if(!co(e)||P_(e))return!1;var t=_y(e)?z_:$_;return t.test(ti(e))}function U_(e,t){return e==null?void 0:e[t]}function ni(e,t){var n=U_(e,t);return B_(n)?n:void 0}var Zs=ni(pn,"Map"),Js=ni(Object,"create");function V_(){this.__data__=Js?Js(null):{},this.size=0}function H_(e){var t=this.has(e)&&delete this.__data__[e];return this.size-=t?1:0,t}var W_="__lodash_hash_undefined__",Q_=Object.prototype,q_=Q_.hasOwnProperty;function K_(e){var t=this.__data__;if(Js){var n=t[e];return n===W_?void 0:n}return q_.call(t,e)?t[e]:void 0}var Y_=Object.prototype,G_=Y_.hasOwnProperty;function X_(e){var t=this.__data__;return Js?t[e]!==void 0:G_.call(t,e)}var Z_="__lodash_hash_undefined__";function J_(e,t){var n=this.__data__;return this.size+=this.has(e)?0:1,n[e]=Js&&t===void 0?Z_:t,this}function qr(e){var t=-1,n=e==null?0:e.length;for(this.clear();++t<n;){var r=e[t];this.set(r[0],r[1])}}qr.prototype.clear=V_;qr.prototype.delete=H_;qr.prototype.get=K_;qr.prototype.has=X_;qr.prototype.set=J_;function e2(){this.size=0,this.__data__={hash:new qr,map:new(Zs||Pn),string:new qr}}function t2(e){var t=typeof e;return t=="string"||t=="number"||t=="symbol"||t=="boolean"?e!=="__proto__":e===null}function ya(e,t){var n=e.__data__;return t2(t)?n[typeof t=="string"?"string":"hash"]:n.map}function n2(e){var t=ya(this,e).delete(e);return this.size-=t?1:0,t}function r2(e){return ya(this,e).get(e)}function i2(e){return ya(this,e).has(e)}function s2(e,t){var n=ya(this,e),r=n.size;return n.set(e,t),this.size+=n.size==r?0:1,this}function yr(e){var t=-1,n=e==null?0:e.length;for(this.clear();++t<n;){var r=e[t];this.set(r[0],r[1])}}yr.prototype.clear=e2;yr.prototype.delete=n2;yr.prototype.get=r2;yr.prototype.has=i2;yr.prototype.set=s2;var o2=200;function l2(e,t){var n=this.__data__;if(n instanceof Pn){var r=n.__data__;if(!Zs||r.length<o2-1)return r.push([e,t]),this.size=++n.size,this;n=this.__data__=new yr(r)}return n.set(e,t),this.size=n.size,this}function ts(e){var t=this.__data__=new Pn(e);this.size=t.size}ts.prototype.clear=E_;ts.prototype.delete=__;ts.prototype.get=k_;ts.prototype.has=C_;ts.prototype.set=l2;function a2(e,t){for(var n=-1,r=e==null?0:e.length;++n<r&&t(e[n],n,e)!==!1;);return e}var mp=function(){try{var e=ni(Object,"defineProperty");return e({},"",{}),e}catch{}}();function ky(e,t,n){t=="__proto__"&&mp?mp(e,t,{configurable:!0,enumerable:!0,value:n,writable:!0}):e[t]=n}var u2=Object.prototype,c2=u2.hasOwnProperty;function Cy(e,t,n){var r=e[t];(!(c2.call(e,t)&&Ey(r,n))||n===void 0&&!(t in e))&&ky(e,t,n)}function va(e,t,n,r){var i=!n;n||(n={});for(var s=-1,o=t.length;++s<o;){var l=t[s],a=void 0;a===void 0&&(a=e[l]),i?ky(n,l,a):Cy(n,l,a)}return n}function f2(e,t){for(var n=-1,r=Array(e);++n<e;)r[n]=t(n);return r}var d2="[object Arguments]";function gp(e){return ei(e)&&Jr(e)==d2}var Ty=Object.prototype,h2=Ty.hasOwnProperty,p2=Ty.propertyIsEnumerable,m2=gp(function(){return arguments}())?gp:function(e){return ei(e)&&h2.call(e,"callee")&&!p2.call(e,"callee")},fo=Array.isArray;function g2(){return!1}var Oy=typeof yt=="object"&&yt&&!yt.nodeType&&yt,yp=Oy&&typeof vt=="object"&&vt&&!vt.nodeType&&vt,y2=yp&&yp.exports===Oy,vp=y2?pn.Buffer:void 0,v2=vp?vp.isBuffer:void 0,Ry=v2||g2,w2=9007199254740991,x2=/^(?:0|[1-9]\d*)$/;function S2(e,t){var n=typeof e;return t=t??w2,!!t&&(n=="number"||n!="symbol"&&x2.test(e))&&e>-1&&e%1==0&&e<t}var b2=9007199254740991;function Ny(e){return typeof e=="number"&&e>-1&&e%1==0&&e<=b2}var E2="[object Arguments]",_2="[object Array]",k2="[object Boolean]",C2="[object Date]",T2="[object Error]",O2="[object Function]",R2="[object Map]",N2="[object Number]",P2="[object Object]",A2="[object RegExp]",j2="[object Set]",F2="[object String]",$2="[object WeakMap]",I2="[object ArrayBuffer]",L2="[object DataView]",D2="[object Float32Array]",M2="[object Float64Array]",z2="[object Int8Array]",B2="[object Int16Array]",U2="[object Int32Array]",V2="[object Uint8Array]",H2="[object Uint8ClampedArray]",W2="[object Uint16Array]",Q2="[object Uint32Array]",ce={};ce[D2]=ce[M2]=ce[z2]=ce[B2]=ce[U2]=ce[V2]=ce[H2]=ce[W2]=ce[Q2]=!0;ce[E2]=ce[_2]=ce[I2]=ce[k2]=ce[L2]=ce[C2]=ce[T2]=ce[O2]=ce[R2]=ce[N2]=ce[P2]=ce[A2]=ce[j2]=ce[F2]=ce[$2]=!1;function q2(e){return ei(e)&&Ny(e.length)&&!!ce[Jr(e)]}function ad(e){return function(t){return e(t)}}var Py=typeof yt=="object"&&yt&&!yt.nodeType&&yt,Rs=Py&&typeof vt=="object"&&vt&&!vt.nodeType&&vt,K2=Rs&&Rs.exports===Py,yu=K2&&wy.process,qi=function(){try{var e=Rs&&Rs.require&&Rs.require("util").types;return e||yu&&yu.binding&&yu.binding("util")}catch{}}(),wp=qi&&qi.isTypedArray,Y2=wp?ad(wp):q2,G2=Object.prototype,X2=G2.hasOwnProperty;function Ay(e,t){var n=fo(e),r=!n&&m2(e),i=!n&&!r&&Ry(e),s=!n&&!r&&!i&&Y2(e),o=n||r||i||s,l=o?f2(e.length,String):[],a=l.length;for(var c in e)(t||X2.call(e,c))&&!(o&&(c=="length"||i&&(c=="offset"||c=="parent")||s&&(c=="buffer"||c=="byteLength"||c=="byteOffset")||S2(c,a)))&&l.push(c);return l}var Z2=Object.prototype;function ud(e){var t=e&&e.constructor,n=typeof t=="function"&&t.prototype||Z2;return e===n}var J2=Sy(Object.keys,Object),ek=Object.prototype,tk=ek.hasOwnProperty;function nk(e){if(!ud(e))return J2(e);var t=[];for(var n in Object(e))tk.call(e,n)&&n!="constructor"&&t.push(n);return t}function jy(e){return e!=null&&Ny(e.length)&&!_y(e)}function cd(e){return jy(e)?Ay(e):nk(e)}function rk(e,t){return e&&va(t,cd(t),e)}function ik(e){var t=[];if(e!=null)for(var n in Object(e))t.push(n);return t}var sk=Object.prototype,ok=sk.hasOwnProperty;function lk(e){if(!co(e))return ik(e);var t=ud(e),n=[];for(var r in e)r=="constructor"&&(t||!ok.call(e,r))||n.push(r);return n}function fd(e){return jy(e)?Ay(e,!0):lk(e)}function ak(e,t){return e&&va(t,fd(t),e)}var Fy=typeof yt=="object"&&yt&&!yt.nodeType&&yt,xp=Fy&&typeof vt=="object"&&vt&&!vt.nodeType&&vt,uk=xp&&xp.exports===Fy,Sp=uk?pn.Buffer:void 0,bp=Sp?Sp.allocUnsafe:void 0;function ck(e,t){if(t)return e.slice();var n=e.length,r=bp?bp(n):new e.constructor(n);return e.copy(r),r}function $y(e,t){var n=-1,r=e.length;for(t||(t=Array(r));++n<r;)t[n]=e[n];return t}function fk(e,t){for(var n=-1,r=e==null?0:e.length,i=0,s=[];++n<r;){var o=e[n];t(o,n,e)&&(s[i++]=o)}return s}function Iy(){return[]}var dk=Object.prototype,hk=dk.propertyIsEnumerable,Ep=Object.getOwnPropertySymbols,dd=Ep?function(e){return e==null?[]:(e=Object(e),fk(Ep(e),function(t){return hk.call(e,t)}))}:Iy;function pk(e,t){return va(e,dd(e),t)}function Ly(e,t){for(var n=-1,r=t.length,i=e.length;++n<r;)e[i+n]=t[n];return e}var mk=Object.getOwnPropertySymbols,Dy=mk?function(e){for(var t=[];e;)Ly(t,dd(e)),e=ld(e);return t}:Iy;function gk(e,t){return va(e,Dy(e),t)}function My(e,t,n){var r=t(e);return fo(e)?r:Ly(r,n(e))}function yk(e){return My(e,cd,dd)}function vk(e){return My(e,fd,Dy)}var Bc=ni(pn,"DataView"),Uc=ni(pn,"Promise"),Vc=ni(pn,"Set"),Hc=ni(pn,"WeakMap"),_p="[object Map]",wk="[object Object]",kp="[object Promise]",Cp="[object Set]",Tp="[object WeakMap]",Op="[object DataView]",xk=ti(Bc),Sk=ti(Zs),bk=ti(Uc),Ek=ti(Vc),_k=ti(Hc),xn=Jr;(Bc&&xn(new Bc(new ArrayBuffer(1)))!=Op||Zs&&xn(new Zs)!=_p||Uc&&xn(Uc.resolve())!=kp||Vc&&xn(new Vc)!=Cp||Hc&&xn(new Hc)!=Tp)&&(xn=function(e){var t=Jr(e),n=t==wk?e.constructor:void 0,r=n?ti(n):"";if(r)switch(r){case xk:return Op;case Sk:return _p;case bk:return kp;case Ek:return Cp;case _k:return Tp}return t});var kk=Object.prototype,Ck=kk.hasOwnProperty;function Tk(e){var t=e.length,n=new e.constructor(t);return t&&typeof e[0]=="string"&&Ck.call(e,"index")&&(n.index=e.index,n.input=e.input),n}var Rp=pn.Uint8Array;function hd(e){var t=new e.constructor(e.byteLength);return new Rp(t).set(new Rp(e)),t}function Ok(e,t){var n=t?hd(e.buffer):e.buffer;return new e.constructor(n,e.byteOffset,e.byteLength)}var Rk=/\w*$/;function Nk(e){var t=new e.constructor(e.source,Rk.exec(e));return t.lastIndex=e.lastIndex,t}var Np=dr?dr.prototype:void 0,Pp=Np?Np.valueOf:void 0;function Pk(e){return Pp?Object(Pp.call(e)):{}}function Ak(e,t){var n=t?hd(e.buffer):e.buffer;return new e.constructor(n,e.byteOffset,e.length)}var jk="[object Boolean]",Fk="[object Date]",$k="[object Map]",Ik="[object Number]",Lk="[object RegExp]",Dk="[object Set]",Mk="[object String]",zk="[object Symbol]",Bk="[object ArrayBuffer]",Uk="[object DataView]",Vk="[object Float32Array]",Hk="[object Float64Array]",Wk="[object Int8Array]",Qk="[object Int16Array]",qk="[object Int32Array]",Kk="[object Uint8Array]",Yk="[object Uint8ClampedArray]",Gk="[object Uint16Array]",Xk="[object Uint32Array]";function Zk(e,t,n){var r=e.constructor;switch(t){case Bk:return hd(e);case jk:case Fk:return new r(+e);case Uk:return Ok(e,n);case Vk:case Hk:case Wk:case Qk:case qk:case Kk:case Yk:case Gk:case Xk:return Ak(e,n);case $k:return new r;case Ik:case Mk:return new r(e);case Lk:return Nk(e);case Dk:return new r;case zk:return Pk(e)}}var Ap=Object.create,Jk=function(){function e(){}return function(t){if(!co(t))return{};if(Ap)return Ap(t);e.prototype=t;var n=new e;return e.prototype=void 0,n}}();function eC(e){return typeof e.constructor=="function"&&!ud(e)?Jk(ld(e)):{}}var tC="[object Map]";function nC(e){return ei(e)&&xn(e)==tC}var jp=qi&&qi.isMap,rC=jp?ad(jp):nC,iC="[object Set]";function sC(e){return ei(e)&&xn(e)==iC}var Fp=qi&&qi.isSet,oC=Fp?ad(Fp):sC,lC=1,aC=2,uC=4,zy="[object Arguments]",cC="[object Array]",fC="[object Boolean]",dC="[object Date]",hC="[object Error]",By="[object Function]",pC="[object GeneratorFunction]",mC="[object Map]",gC="[object Number]",Uy="[object Object]",yC="[object RegExp]",vC="[object Set]",wC="[object String]",xC="[object Symbol]",SC="[object WeakMap]",bC="[object ArrayBuffer]",EC="[object DataView]",_C="[object Float32Array]",kC="[object Float64Array]",CC="[object Int8Array]",TC="[object Int16Array]",OC="[object Int32Array]",RC="[object Uint8Array]",NC="[object Uint8ClampedArray]",PC="[object Uint16Array]",AC="[object Uint32Array]",le={};le[zy]=le[cC]=le[bC]=le[EC]=le[fC]=le[dC]=le[_C]=le[kC]=le[CC]=le[TC]=le[OC]=le[mC]=le[gC]=le[Uy]=le[yC]=le[vC]=le[wC]=le[xC]=le[RC]=le[NC]=le[PC]=le[AC]=!0;le[hC]=le[By]=le[SC]=!1;function Ns(e,t,n,r,i,s){var o,l=t&lC,a=t&aC,c=t&uC;if(o!==void 0)return o;if(!co(e))return e;var f=fo(e);if(f){if(o=Tk(e),!l)return $y(e,o)}else{var u=xn(e),d=u==By||u==pC;if(Ry(e))return ck(e,l);if(u==Uy||u==zy||d&&!i){if(o=a||d?{}:eC(e),!l)return a?gk(e,ak(o,e)):pk(e,rk(o,e))}else{if(!le[u])return i?e:{};o=Zk(e,u,l)}}s||(s=new ts);var h=s.get(e);if(h)return h;s.set(e,o),oC(e)?e.forEach(function(S){o.add(Ns(S,t,n,S,e,s))}):rC(e)&&e.forEach(function(S,m){o.set(m,Ns(S,t,n,m,e,s))});var v=c?a?vk:yk:a?fd:cd,w=f?void 0:v(e);return a2(w||e,function(S,m){w&&(m=S,S=e[m]),Cy(o,m,Ns(S,t,n,m,e,s))}),o}var jC=1,FC=4;function Vo(e){return Ns(e,jC|FC)}var $p=Array.isArray,Ip=Object.keys,$C=Object.prototype.hasOwnProperty,IC=typeof Element<"u";function Wc(e,t){if(e===t)return!0;if(e&&t&&typeof e=="object"&&typeof t=="object"){var n=$p(e),r=$p(t),i,s,o;if(n&&r){if(s=e.length,s!=t.length)return!1;for(i=s;i--!==0;)if(!Wc(e[i],t[i]))return!1;return!0}if(n!=r)return!1;var l=e instanceof Date,a=t instanceof Date;if(l!=a)return!1;if(l&&a)return e.getTime()==t.getTime();var c=e instanceof RegExp,f=t instanceof RegExp;if(c!=f)return!1;if(c&&f)return e.toString()==t.toString();var u=Ip(e);if(s=u.length,s!==Ip(t).length)return!1;for(i=s;i--!==0;)if(!$C.call(t,u[i]))return!1;if(IC&&e instanceof Element&&t instanceof Element)return e===t;for(i=s;i--!==0;)if(o=u[i],!(o==="_owner"&&e.$$typeof)&&!Wc(e[o],t[o]))return!1;return!0}return e!==e&&t!==t}var LC=function(t,n){try{return Wc(t,n)}catch(r){if(r.message&&r.message.match(/stack|recursion/i)||r.number===-2146828260)return console.warn("Warning: react-fast-compare does not handle circular references.",r.name,r.message),!1;throw r}};const Er=Ki(LC);var DC=4;function Lp(e){return Ns(e,DC)}function Vy(e,t){for(var n=-1,r=e==null?0:e.length,i=Array(r);++n<r;)i[n]=t(e[n],n,e);return i}var MC="[object Symbol]";function pd(e){return typeof e=="symbol"||ei(e)&&Jr(e)==MC}var zC="Expected a function";function md(e,t){if(typeof e!="function"||t!=null&&typeof t!="function")throw new TypeError(zC);var n=function(){var r=arguments,i=t?t.apply(this,r):r[0],s=n.cache;if(s.has(i))return s.get(i);var o=e.apply(this,r);return n.cache=s.set(i,o)||s,o};return n.cache=new(md.Cache||yr),n}md.Cache=yr;var BC=500;function UC(e){var t=md(e,function(r){return n.size===BC&&n.clear(),r}),n=t.cache;return t}var VC=/[^.[\]]+|\[(?:(-?\d+(?:\.\d+)?)|(["'])((?:(?!\2)[^\\]|\\.)*?)\2)\]|(?=(?:\.|\[\])(?:\.|\[\]|$))/g,HC=/\\(\\)?/g,WC=UC(function(e){var t=[];return e.charCodeAt(0)===46&&t.push(""),e.replace(VC,function(n,r,i,s){t.push(i?s.replace(HC,"$1"):r||n)}),t}),QC=1/0;function qC(e){if(typeof e=="string"||pd(e))return e;var t=e+"";return t=="0"&&1/e==-QC?"-0":t}var KC=1/0,Dp=dr?dr.prototype:void 0,Mp=Dp?Dp.toString:void 0;function Hy(e){if(typeof e=="string")return e;if(fo(e))return Vy(e,Hy)+"";if(pd(e))return Mp?Mp.call(e):"";var t=e+"";return t=="0"&&1/e==-KC?"-0":t}function YC(e){return e==null?"":Hy(e)}function Wy(e){return fo(e)?Vy(e,qC):pd(e)?[e]:$y(WC(YC(e)))}var Qy={exports:{}},ie={};/** @license React v16.13.1
81
+ `+(l!==o?`result of cast: ${l}`:""))}return s}_cast(t,n){let r=t===void 0?t:this.transforms.reduce((i,s)=>s.call(this,i,t,this),t);return r===void 0&&(r=this.getDefault(n)),r}_validate(t,n={},r,i){let{path:s,originalValue:o=t,strict:l=this.spec.strict}=n,a=t;l||(a=this._cast(a,Object.assign({assert:!1},n)));let c=[];for(let f of Object.values(this.internalTests))f&&c.push(f);this.runTests({path:s,value:a,originalValue:o,options:n,tests:c},r,f=>{if(f.length)return i(f,a);this.runTests({path:s,value:a,originalValue:o,options:n,tests:this.tests},r,i)})}runTests(t,n,r){let i=!1,{tests:s,value:o,originalValue:l,path:a,options:c}=t,f=w=>{i||(i=!0,n(w,o))},u=w=>{i||(i=!0,r(w,o))},d=s.length,h=[];if(!d)return u([]);let v={value:o,originalValue:l,path:a,options:c,schema:this};for(let w=0;w<s.length;w++){const S=s[w];S(v,f,function(p){p&&(Array.isArray(p)?h.push(...p):h.push(p)),--d<=0&&u(h)})}}asNestedTest({key:t,index:n,parent:r,parentPath:i,originalParent:s,options:o}){const l=t??n;if(l==null)throw TypeError("Must include `key` or `index` for nested validations");const a=typeof l=="number";let c=r[l];const f=Object.assign({},o,{strict:!0,parent:r,value:c,originalValue:s[l],key:void 0,[a?"index":"key"]:l,path:a||l.includes(".")?`${i||""}[${a?l:`"${l}"`}]`:(i?`${i}.`:"")+t});return(u,d,h)=>this.resolve(f)._validate(c,f,d,h)}validate(t,n){var r;let i=this.resolve(Object.assign({},n,{value:t})),s=(r=n==null?void 0:n.disableStackTrace)!=null?r:i.spec.disableStackTrace;return new Promise((o,l)=>i._validate(t,n,(a,c)=>{st.isError(a)&&(a.value=c),l(a)},(a,c)=>{a.length?l(new st(a,c,void 0,void 0,s)):o(c)}))}validateSync(t,n){var r;let i=this.resolve(Object.assign({},n,{value:t})),s,o=(r=n==null?void 0:n.disableStackTrace)!=null?r:i.spec.disableStackTrace;return i._validate(t,Object.assign({},n,{sync:!0}),(l,a)=>{throw st.isError(l)&&(l.value=a),l},(l,a)=>{if(l.length)throw new st(l,t,void 0,void 0,o);s=a}),s}isValid(t,n){return this.validate(t,n).then(()=>!0,r=>{if(st.isError(r))return!1;throw r})}isValidSync(t,n){try{return this.validateSync(t,n),!0}catch(r){if(st.isError(r))return!1;throw r}}_getDefault(t){let n=this.spec.default;return n==null?n:typeof n=="function"?n.call(this,t):vi(n)}getDefault(t){return this.resolve(t||{})._getDefault(t)}default(t){return arguments.length===0?this._getDefault():this.clone({default:t})}strict(t=!0){return this.clone({strict:t})}nullability(t,n){const r=this.clone({nullable:t});return r.internalTests.nullable=si({message:n,name:"nullable",test(i){return i===null?this.schema.spec.nullable:!0}}),r}optionality(t,n){const r=this.clone({optional:t});return r.internalTests.optionality=si({message:n,name:"optionality",test(i){return i===void 0?this.schema.spec.optional:!0}}),r}optional(){return this.optionality(!0)}defined(t=tn.defined){return this.optionality(!1,t)}nullable(){return this.nullability(!0)}nonNullable(t=tn.notNull){return this.nullability(!1,t)}required(t=tn.required){return this.clone().withMutation(n=>n.nonNullable(t).defined(t))}notRequired(){return this.clone().withMutation(t=>t.nullable().optional())}transform(t){let n=this.clone();return n.transforms.push(t),n}test(...t){let n;if(t.length===1?typeof t[0]=="function"?n={test:t[0]}:n=t[0]:t.length===2?n={name:t[0],test:t[1]}:n={name:t[0],message:t[1],test:t[2]},n.message===void 0&&(n.message=tn.default),typeof n.test!="function")throw new TypeError("`test` is a required parameters");let r=this.clone(),i=si(n),s=n.exclusive||n.name&&r.exclusiveTests[n.name]===!0;if(n.exclusive&&!n.name)throw new TypeError("Exclusive tests must provide a unique `name` identifying the test");return n.name&&(r.exclusiveTests[n.name]=!!n.exclusive),r.tests=r.tests.filter(o=>!(o.OPTIONS.name===n.name&&(s||o.OPTIONS.test===i.OPTIONS.test))),r.tests.push(i),r}when(t,n){!Array.isArray(t)&&typeof t!="string"&&(n=t,t=".");let r=this.clone(),i=fg(t).map(s=>new Zr(s));return i.forEach(s=>{s.isSibling&&r.deps.push(s.key)}),r.conditions.push(typeof n=="function"?new Bl(i,n):Bl.fromOptions(i,n)),r}typeError(t){let n=this.clone();return n.internalTests.typeError=si({message:t,name:"typeError",skipAbsent:!0,test(r){return this.schema._typeCheck(r)?!0:this.createError({params:{type:this.schema.type}})}}),n}oneOf(t,n=tn.oneOf){let r=this.clone();return t.forEach(i=>{r._whitelist.add(i),r._blacklist.delete(i)}),r.internalTests.whiteList=si({message:n,name:"oneOf",skipAbsent:!0,test(i){let s=this.schema._whitelist,o=s.resolveAll(this.resolve);return o.includes(i)?!0:this.createError({params:{values:Array.from(s).join(", "),resolved:o}})}}),r}notOneOf(t,n=tn.notOneOf){let r=this.clone();return t.forEach(i=>{r._blacklist.add(i),r._whitelist.delete(i)}),r.internalTests.blacklist=si({message:n,name:"notOneOf",test(i){let s=this.schema._blacklist,o=s.resolveAll(this.resolve);return o.includes(i)?this.createError({params:{values:Array.from(s).join(", "),resolved:o}}):!0}}),r}strip(t=!0){let n=this.clone();return n.spec.strip=t,n}describe(t){const n=(t?this.resolve(t):this).clone(),{label:r,meta:i,optional:s,nullable:o}=n.spec;return{meta:i,label:r,optional:s,nullable:o,default:n.getDefault(t),type:n.type,oneOf:n._whitelist.describe(),notOneOf:n._blacklist.describe(),tests:n.tests.map(a=>({name:a.OPTIONS.name,params:a.OPTIONS.params})).filter((a,c,f)=>f.findIndex(u=>u.name===a.name)===c)}}}hn.prototype.__isYupSchema__=!0;for(const e of["validate","validateSync"])hn.prototype[`${e}At`]=function(t,n,r={}){const{parent:i,parentPath:s,schema:o}=NE(this,t,n,r.context);return o[e](i&&i[s],Object.assign({},r,{parent:i,path:t}))};for(const e of["equals","is"])hn.prototype[e]=hn.prototype.oneOf;for(const e of["not","nope"])hn.prototype[e]=hn.prototype.notOneOf;const PE=/^(\d{4}|[+-]\d{6})(?:-?(\d{2})(?:-?(\d{2}))?)?(?:[ T]?(\d{2}):?(\d{2})(?::?(\d{2})(?:[,.](\d{1,}))?)?(?:(Z)|([+-])(\d{2})(?::?(\d{2}))?)?)?$/;function AE(e){const t=Lc(e);if(!t)return Date.parse?Date.parse(e):Number.NaN;if(t.z===void 0&&t.plusMinus===void 0)return new Date(t.year,t.month,t.day,t.hour,t.minute,t.second,t.millisecond).valueOf();let n=0;return t.z!=="Z"&&t.plusMinus!==void 0&&(n=t.hourOffset*60+t.minuteOffset,t.plusMinus==="+"&&(n=0-n)),Date.UTC(t.year,t.month,t.day,t.hour,t.minute+n,t.second,t.millisecond)}function Lc(e){var t,n;const r=PE.exec(e);return r?{year:yn(r[1]),month:yn(r[2],1)-1,day:yn(r[3],1),hour:yn(r[4]),minute:yn(r[5]),second:yn(r[6]),millisecond:r[7]?yn(r[7].substring(0,3)):0,precision:(t=(n=r[7])==null?void 0:n.length)!=null?t:void 0,z:r[8]||void 0,plusMinus:r[9]||void 0,hourOffset:yn(r[10]),minuteOffset:yn(r[11])}:null}function yn(e,t=0){return Number(e)||t}let jE=/^[a-zA-Z0-9.!#$%&'*+\/=?^_`{|}~-]+@[a-zA-Z0-9](?:[a-zA-Z0-9-]{0,61}[a-zA-Z0-9])?(?:\.[a-zA-Z0-9](?:[a-zA-Z0-9-]{0,61}[a-zA-Z0-9])?)*$/,FE=/^((https?|ftp):)?\/\/(((([a-z]|\d|-|\.|_|~|[\u00A0-\uD7FF\uF900-\uFDCF\uFDF0-\uFFEF])|(%[\da-f]{2})|[!\$&'\(\)\*\+,;=]|:)*@)?(((\d|[1-9]\d|1\d\d|2[0-4]\d|25[0-5])\.(\d|[1-9]\d|1\d\d|2[0-4]\d|25[0-5])\.(\d|[1-9]\d|1\d\d|2[0-4]\d|25[0-5])\.(\d|[1-9]\d|1\d\d|2[0-4]\d|25[0-5]))|((([a-z]|\d|[\u00A0-\uD7FF\uF900-\uFDCF\uFDF0-\uFFEF])|(([a-z]|\d|[\u00A0-\uD7FF\uF900-\uFDCF\uFDF0-\uFFEF])([a-z]|\d|-|\.|_|~|[\u00A0-\uD7FF\uF900-\uFDCF\uFDF0-\uFFEF])*([a-z]|\d|[\u00A0-\uD7FF\uF900-\uFDCF\uFDF0-\uFFEF])))\.)+(([a-z]|[\u00A0-\uD7FF\uF900-\uFDCF\uFDF0-\uFFEF])|(([a-z]|[\u00A0-\uD7FF\uF900-\uFDCF\uFDF0-\uFFEF])([a-z]|\d|-|\.|_|~|[\u00A0-\uD7FF\uF900-\uFDCF\uFDF0-\uFFEF])*([a-z]|[\u00A0-\uD7FF\uF900-\uFDCF\uFDF0-\uFFEF])))\.?)(:\d*)?)(\/((([a-z]|\d|-|\.|_|~|[\u00A0-\uD7FF\uF900-\uFDCF\uFDF0-\uFFEF])|(%[\da-f]{2})|[!\$&'\(\)\*\+,;=]|:|@)+(\/(([a-z]|\d|-|\.|_|~|[\u00A0-\uD7FF\uF900-\uFDCF\uFDF0-\uFFEF])|(%[\da-f]{2})|[!\$&'\(\)\*\+,;=]|:|@)*)*)?)?(\?((([a-z]|\d|-|\.|_|~|[\u00A0-\uD7FF\uF900-\uFDCF\uFDF0-\uFFEF])|(%[\da-f]{2})|[!\$&'\(\)\*\+,;=]|:|@)|[\uE000-\uF8FF]|\/|\?)*)?(\#((([a-z]|\d|-|\.|_|~|[\u00A0-\uD7FF\uF900-\uFDCF\uFDF0-\uFFEF])|(%[\da-f]{2})|[!\$&'\(\)\*\+,;=]|:|@)|\/|\?)*)?$/i,$E=/^(?:[0-9a-f]{8}-[0-9a-f]{4}-[1-5][0-9a-f]{3}-[89ab][0-9a-f]{3}-[0-9a-f]{12}|00000000-0000-0000-0000-000000000000)$/i,IE="^\\d{4}-\\d{2}-\\d{2}",DE="\\d{2}:\\d{2}:\\d{2}",LE="(([+-]\\d{2}(:?\\d{2})?)|Z)",ME=new RegExp(`${IE}T${DE}(\\.\\d+)?${LE}$`),zE=e=>Tr(e)||e===e.trim(),BE={}.toString();function Mc(){return new mg}class mg extends hn{constructor(){super({type:"string",check(t){return t instanceof String&&(t=t.valueOf()),typeof t=="string"}}),this.withMutation(()=>{this.transform((t,n,r)=>{if(!r.spec.coerce||r.isType(t)||Array.isArray(t))return t;const i=t!=null&&t.toString?t.toString():t;return i===BE?t:i})})}required(t){return super.required(t).withMutation(n=>n.test({message:t||tn.required,name:"required",skipAbsent:!0,test:r=>!!r.length}))}notRequired(){return super.notRequired().withMutation(t=>(t.tests=t.tests.filter(n=>n.OPTIONS.name!=="required"),t))}length(t,n=et.length){return this.test({message:n,name:"length",exclusive:!0,params:{length:t},skipAbsent:!0,test(r){return r.length===this.resolve(t)}})}min(t,n=et.min){return this.test({message:n,name:"min",exclusive:!0,params:{min:t},skipAbsent:!0,test(r){return r.length>=this.resolve(t)}})}max(t,n=et.max){return this.test({name:"max",exclusive:!0,message:n,params:{max:t},skipAbsent:!0,test(r){return r.length<=this.resolve(t)}})}matches(t,n){let r=!1,i,s;return n&&(typeof n=="object"?{excludeEmptyString:r=!1,message:i,name:s}=n:i=n),this.test({name:s||"matches",message:i||et.matches,params:{regex:t},skipAbsent:!0,test:o=>o===""&&r||o.search(t)!==-1})}email(t=et.email){return this.matches(jE,{name:"email",message:t,excludeEmptyString:!0})}url(t=et.url){return this.matches(FE,{name:"url",message:t,excludeEmptyString:!0})}uuid(t=et.uuid){return this.matches($E,{name:"uuid",message:t,excludeEmptyString:!1})}datetime(t){let n="",r,i;return t&&(typeof t=="object"?{message:n="",allowOffset:r=!1,precision:i=void 0}=t:n=t),this.matches(ME,{name:"datetime",message:n||et.datetime,excludeEmptyString:!0}).test({name:"datetime_offset",message:n||et.datetime_offset,params:{allowOffset:r},skipAbsent:!0,test:s=>{if(!s||r)return!0;const o=Lc(s);return o?!!o.z:!1}}).test({name:"datetime_precision",message:n||et.datetime_precision,params:{precision:i},skipAbsent:!0,test:s=>{if(!s||i==null)return!0;const o=Lc(s);return o?o.precision===i:!1}})}ensure(){return this.default("").transform(t=>t===null?"":t)}trim(t=et.trim){return this.transform(n=>n!=null?n.trim():n).test({message:t,name:"trim",test:zE})}lowercase(t=et.lowercase){return this.transform(n=>Tr(n)?n:n.toLowerCase()).test({message:t,name:"string_case",exclusive:!0,skipAbsent:!0,test:n=>Tr(n)||n===n.toLowerCase()})}uppercase(t=et.uppercase){return this.transform(n=>Tr(n)?n:n.toUpperCase()).test({message:t,name:"string_case",exclusive:!0,skipAbsent:!0,test:n=>Tr(n)||n===n.toUpperCase()})}}Mc.prototype=mg.prototype;let UE=new Date(""),VE=e=>Object.prototype.toString.call(e)==="[object Date]";class ma extends hn{constructor(){super({type:"date",check(t){return VE(t)&&!isNaN(t.getTime())}}),this.withMutation(()=>{this.transform((t,n,r)=>!r.spec.coerce||r.isType(t)||t===null?t:(t=AE(t),isNaN(t)?ma.INVALID_DATE:new Date(t)))})}prepareParam(t,n){let r;if(Zr.isRef(t))r=t;else{let i=this.cast(t);if(!this._typeCheck(i))throw new TypeError(`\`${n}\` must be a Date or a value that can be \`cast()\` to a Date`);r=i}return r}min(t,n=Dc.min){let r=this.prepareParam(t,"min");return this.test({message:n,name:"min",exclusive:!0,params:{min:t},skipAbsent:!0,test(i){return i>=this.resolve(r)}})}max(t,n=Dc.max){let r=this.prepareParam(t,"max");return this.test({message:n,name:"max",exclusive:!0,params:{max:t},skipAbsent:!0,test(i){return i<=this.resolve(r)}})}}ma.INVALID_DATE=UE;ma.prototype;function HE(e,t=[]){let n=[],r=new Set,i=new Set(t.map(([o,l])=>`${o}-${l}`));function s(o,l){let a=Lr.split(o)[0];r.add(a),i.has(`${l}-${a}`)||n.push([l,a])}for(const o of Object.keys(e)){let l=e[o];r.add(o),Zr.isRef(l)&&l.isSibling?s(l.path,o):od(l)&&"deps"in l&&l.deps.forEach(a=>s(a,o))}return vE.array(Array.from(r),n).reverse()}function up(e,t){let n=1/0;return e.some((r,i)=>{var s;if((s=t.path)!=null&&s.includes(r))return n=i,!0}),n}function yg(e){return(t,n)=>up(e,t)-up(e,n)}const WE=(e,t,n)=>{if(typeof e!="string")return e;let r=e;try{r=JSON.parse(e)}catch{}return n.isType(r)?r:e};function fl(e){if("fields"in e){const t={};for(const[n,r]of Object.entries(e.fields))t[n]=fl(r);return e.setFields(t)}if(e.type==="array"){const t=e.optional();return t.innerType&&(t.innerType=fl(t.innerType)),t}return e.type==="tuple"?e.optional().clone({types:e.spec.types.map(fl)}):"optional"in e?e.optional():e}const QE=(e,t)=>{const n=[...Lr.normalizePath(t)];if(n.length===1)return n[0]in e;let r=n.pop(),i=Lr.getter(Lr.join(n),!0)(e);return!!(i&&r in i)};let cp=e=>Object.prototype.toString.call(e)==="[object Object]";function fp(e,t){let n=Object.keys(e.fields);return Object.keys(t).filter(r=>n.indexOf(r)===-1)}const qE=yg([]);function gg(e){return new vg(e)}class vg extends hn{constructor(t){super({type:"object",check(n){return cp(n)||typeof n=="function"}}),this.fields=Object.create(null),this._sortErrors=qE,this._nodes=[],this._excludedEdges=[],this.withMutation(()=>{t&&this.shape(t)})}_cast(t,n={}){var r;let i=super._cast(t,n);if(i===void 0)return this.getDefault(n);if(!this._typeCheck(i))return i;let s=this.fields,o=(r=n.stripUnknown)!=null?r:this.spec.noUnknown,l=[].concat(this._nodes,Object.keys(i).filter(u=>!this._nodes.includes(u))),a={},c=Object.assign({},n,{parent:a,__validating:n.__validating||!1}),f=!1;for(const u of l){let d=s[u],h=u in i;if(d){let v,w=i[u];c.path=(n.path?`${n.path}.`:"")+u,d=d.resolve({value:w,context:n.context,parent:a});let S=d instanceof hn?d.spec:void 0,m=S==null?void 0:S.strict;if(S!=null&&S.strip){f=f||u in i;continue}v=!n.__validating||!m?d.cast(i[u],c):i[u],v!==void 0&&(a[u]=v)}else h&&!o&&(a[u]=i[u]);(h!==u in a||a[u]!==i[u])&&(f=!0)}return f?a:i}_validate(t,n={},r,i){let{from:s=[],originalValue:o=t,recursive:l=this.spec.recursive}=n;n.from=[{schema:this,value:o},...s],n.__validating=!0,n.originalValue=o,super._validate(t,n,r,(a,c)=>{if(!l||!cp(c)){i(a,c);return}o=o||c;let f=[];for(let u of this._nodes){let d=this.fields[u];!d||Zr.isRef(d)||f.push(d.asNestedTest({options:n,key:u,parent:c,parentPath:n.path,originalParent:o}))}this.runTests({tests:f,value:c,originalValue:o,options:n},r,u=>{i(u.sort(this._sortErrors).concat(a),c)})})}clone(t){const n=super.clone(t);return n.fields=Object.assign({},this.fields),n._nodes=this._nodes,n._excludedEdges=this._excludedEdges,n._sortErrors=this._sortErrors,n}concat(t){let n=super.concat(t),r=n.fields;for(let[i,s]of Object.entries(this.fields)){const o=r[i];r[i]=o===void 0?s:o}return n.withMutation(i=>i.setFields(r,[...this._excludedEdges,...t._excludedEdges]))}_getDefault(t){if("default"in this.spec)return super._getDefault(t);if(!this._nodes.length)return;let n={};return this._nodes.forEach(r=>{var i;const s=this.fields[r];let o=t;(i=o)!=null&&i.value&&(o=Object.assign({},o,{parent:o.value,value:o.value[r]})),n[r]=s&&"getDefault"in s?s.getDefault(o):void 0}),n}setFields(t,n){let r=this.clone();return r.fields=t,r._nodes=HE(t,n),r._sortErrors=yg(Object.keys(t)),n&&(r._excludedEdges=n),r}shape(t,n=[]){return this.clone().withMutation(r=>{let i=r._excludedEdges;return n.length&&(Array.isArray(n[0])||(n=[n]),i=[...r._excludedEdges,...n]),r.setFields(Object.assign(r.fields,t),i)})}partial(){const t={};for(const[n,r]of Object.entries(this.fields))t[n]="optional"in r&&r.optional instanceof Function?r.optional():r;return this.setFields(t)}deepPartial(){return fl(this)}pick(t){const n={};for(const r of t)this.fields[r]&&(n[r]=this.fields[r]);return this.setFields(n,this._excludedEdges.filter(([r,i])=>t.includes(r)&&t.includes(i)))}omit(t){const n=[];for(const r of Object.keys(this.fields))t.includes(r)||n.push(r);return this.pick(n)}from(t,n,r){let i=Lr.getter(t,!0);return this.transform(s=>{if(!s)return s;let o=s;return QE(s,t)&&(o=Object.assign({},s),r||delete o[t],o[n]=i(s)),o})}json(){return this.transform(WE)}exact(t){return this.test({name:"exact",exclusive:!0,message:t||cl.exact,test(n){if(n==null)return!0;const r=fp(this.schema,n);return r.length===0||this.createError({params:{properties:r.join(", ")}})}})}stripUnknown(){return this.clone({noUnknown:!0})}noUnknown(t=!0,n=cl.noUnknown){typeof t!="boolean"&&(n=t,t=!0);let r=this.test({name:"noUnknown",exclusive:!0,message:n,test(i){if(i==null)return!0;const s=fp(this.schema,i);return!t||s.length===0||this.createError({params:{unknown:s.join(", ")}})}});return r.spec.noUnknown=t,r}unknown(t=!0,n=cl.noUnknown){return this.noUnknown(!t,n)}transformKeys(t){return this.transform(n=>{if(!n)return n;const r={};for(const i of Object.keys(n))r[t(i)]=n[i];return r})}camelCase(){return this.transformKeys(mu.camelCase)}snakeCase(){return this.transformKeys(mu.snakeCase)}constantCase(){return this.transformKeys(t=>mu.snakeCase(t).toUpperCase())}describe(t){const n=(t?this.resolve(t):this).clone(),r=super.describe(t);r.fields={};for(const[s,o]of Object.entries(n.fields)){var i;let l=t;(i=l)!=null&&i.value&&(l=Object.assign({},l,{parent:l.value,value:l.value[s]})),r.fields[s]=o.describe(l)}return r}}gg.prototype=vg.prototype;var KE=function(t){return YE(t)&&!GE(t)};function YE(e){return!!e&&typeof e=="object"}function GE(e){var t=Object.prototype.toString.call(e);return t==="[object RegExp]"||t==="[object Date]"||JE(e)}var XE=typeof Symbol=="function"&&Symbol.for,ZE=XE?Symbol.for("react.element"):60103;function JE(e){return e.$$typeof===ZE}function e_(e){return Array.isArray(e)?[]:{}}function Vl(e,t){return t.clone!==!1&&t.isMergeableObject(e)?Xs(e_(e),e,t):e}function t_(e,t,n){return e.concat(t).map(function(r){return Vl(r,n)})}function n_(e,t,n){var r={};return n.isMergeableObject(e)&&Object.keys(e).forEach(function(i){r[i]=Vl(e[i],n)}),Object.keys(t).forEach(function(i){!n.isMergeableObject(t[i])||!e[i]?r[i]=Vl(t[i],n):r[i]=Xs(e[i],t[i],n)}),r}function Xs(e,t,n){n=n||{},n.arrayMerge=n.arrayMerge||t_,n.isMergeableObject=n.isMergeableObject||KE;var r=Array.isArray(t),i=Array.isArray(e),s=r===i;return s?r?n.arrayMerge(e,t,n):n_(e,t,n):Vl(t,n)}Xs.all=function(t,n){if(!Array.isArray(t))throw new Error("first argument should be an array");return t.reduce(function(r,i){return Xs(r,i,n)},{})};var zc=Xs,wg=typeof global=="object"&&global&&global.Object===Object&&global,r_=typeof self=="object"&&self&&self.Object===Object&&self,pn=wg||r_||Function("return this")(),dr=pn.Symbol,xg=Object.prototype,i_=xg.hasOwnProperty,s_=xg.toString,hs=dr?dr.toStringTag:void 0;function o_(e){var t=i_.call(e,hs),n=e[hs];try{e[hs]=void 0;var r=!0}catch{}var i=s_.call(e);return r&&(t?e[hs]=n:delete e[hs]),i}var l_=Object.prototype,a_=l_.toString;function u_(e){return a_.call(e)}var c_="[object Null]",f_="[object Undefined]",dp=dr?dr.toStringTag:void 0;function Jr(e){return e==null?e===void 0?f_:c_:dp&&dp in Object(e)?o_(e):u_(e)}function Sg(e,t){return function(n){return e(t(n))}}var ld=Sg(Object.getPrototypeOf,Object);function ei(e){return e!=null&&typeof e=="object"}var d_="[object Object]",h_=Function.prototype,p_=Object.prototype,bg=h_.toString,m_=p_.hasOwnProperty,y_=bg.call(Object);function hp(e){if(!ei(e)||Jr(e)!=d_)return!1;var t=ld(e);if(t===null)return!0;var n=m_.call(t,"constructor")&&t.constructor;return typeof n=="function"&&n instanceof n&&bg.call(n)==y_}function g_(){this.__data__=[],this.size=0}function Eg(e,t){return e===t||e!==e&&t!==t}function ya(e,t){for(var n=e.length;n--;)if(Eg(e[n][0],t))return n;return-1}var v_=Array.prototype,w_=v_.splice;function x_(e){var t=this.__data__,n=ya(t,e);if(n<0)return!1;var r=t.length-1;return n==r?t.pop():w_.call(t,n,1),--this.size,!0}function S_(e){var t=this.__data__,n=ya(t,e);return n<0?void 0:t[n][1]}function b_(e){return ya(this.__data__,e)>-1}function E_(e,t){var n=this.__data__,r=ya(n,e);return r<0?(++this.size,n.push([e,t])):n[r][1]=t,this}function Pn(e){var t=-1,n=e==null?0:e.length;for(this.clear();++t<n;){var r=e[t];this.set(r[0],r[1])}}Pn.prototype.clear=g_;Pn.prototype.delete=x_;Pn.prototype.get=S_;Pn.prototype.has=b_;Pn.prototype.set=E_;function __(){this.__data__=new Pn,this.size=0}function k_(e){var t=this.__data__,n=t.delete(e);return this.size=t.size,n}function C_(e){return this.__data__.get(e)}function T_(e){return this.__data__.has(e)}function co(e){var t=typeof e;return e!=null&&(t=="object"||t=="function")}var O_="[object AsyncFunction]",R_="[object Function]",N_="[object GeneratorFunction]",P_="[object Proxy]";function _g(e){if(!co(e))return!1;var t=Jr(e);return t==R_||t==N_||t==O_||t==P_}var yu=pn["__core-js_shared__"],pp=function(){var e=/[^.]+$/.exec(yu&&yu.keys&&yu.keys.IE_PROTO||"");return e?"Symbol(src)_1."+e:""}();function A_(e){return!!pp&&pp in e}var j_=Function.prototype,F_=j_.toString;function ti(e){if(e!=null){try{return F_.call(e)}catch{}try{return e+""}catch{}}return""}var $_=/[\\^$.*+?()[\]{}|]/g,I_=/^\[object .+?Constructor\]$/,D_=Function.prototype,L_=Object.prototype,M_=D_.toString,z_=L_.hasOwnProperty,B_=RegExp("^"+M_.call(z_).replace($_,"\\$&").replace(/hasOwnProperty|(function).*?(?=\\\()| for .+?(?=\\\])/g,"$1.*?")+"$");function U_(e){if(!co(e)||A_(e))return!1;var t=_g(e)?B_:I_;return t.test(ti(e))}function V_(e,t){return e==null?void 0:e[t]}function ni(e,t){var n=V_(e,t);return U_(n)?n:void 0}var Zs=ni(pn,"Map"),Js=ni(Object,"create");function H_(){this.__data__=Js?Js(null):{},this.size=0}function W_(e){var t=this.has(e)&&delete this.__data__[e];return this.size-=t?1:0,t}var Q_="__lodash_hash_undefined__",q_=Object.prototype,K_=q_.hasOwnProperty;function Y_(e){var t=this.__data__;if(Js){var n=t[e];return n===Q_?void 0:n}return K_.call(t,e)?t[e]:void 0}var G_=Object.prototype,X_=G_.hasOwnProperty;function Z_(e){var t=this.__data__;return Js?t[e]!==void 0:X_.call(t,e)}var J_="__lodash_hash_undefined__";function e2(e,t){var n=this.__data__;return this.size+=this.has(e)?0:1,n[e]=Js&&t===void 0?J_:t,this}function qr(e){var t=-1,n=e==null?0:e.length;for(this.clear();++t<n;){var r=e[t];this.set(r[0],r[1])}}qr.prototype.clear=H_;qr.prototype.delete=W_;qr.prototype.get=Y_;qr.prototype.has=Z_;qr.prototype.set=e2;function t2(){this.size=0,this.__data__={hash:new qr,map:new(Zs||Pn),string:new qr}}function n2(e){var t=typeof e;return t=="string"||t=="number"||t=="symbol"||t=="boolean"?e!=="__proto__":e===null}function ga(e,t){var n=e.__data__;return n2(t)?n[typeof t=="string"?"string":"hash"]:n.map}function r2(e){var t=ga(this,e).delete(e);return this.size-=t?1:0,t}function i2(e){return ga(this,e).get(e)}function s2(e){return ga(this,e).has(e)}function o2(e,t){var n=ga(this,e),r=n.size;return n.set(e,t),this.size+=n.size==r?0:1,this}function gr(e){var t=-1,n=e==null?0:e.length;for(this.clear();++t<n;){var r=e[t];this.set(r[0],r[1])}}gr.prototype.clear=t2;gr.prototype.delete=r2;gr.prototype.get=i2;gr.prototype.has=s2;gr.prototype.set=o2;var l2=200;function a2(e,t){var n=this.__data__;if(n instanceof Pn){var r=n.__data__;if(!Zs||r.length<l2-1)return r.push([e,t]),this.size=++n.size,this;n=this.__data__=new gr(r)}return n.set(e,t),this.size=n.size,this}function ts(e){var t=this.__data__=new Pn(e);this.size=t.size}ts.prototype.clear=__;ts.prototype.delete=k_;ts.prototype.get=C_;ts.prototype.has=T_;ts.prototype.set=a2;function u2(e,t){for(var n=-1,r=e==null?0:e.length;++n<r&&t(e[n],n,e)!==!1;);return e}var mp=function(){try{var e=ni(Object,"defineProperty");return e({},"",{}),e}catch{}}();function kg(e,t,n){t=="__proto__"&&mp?mp(e,t,{configurable:!0,enumerable:!0,value:n,writable:!0}):e[t]=n}var c2=Object.prototype,f2=c2.hasOwnProperty;function Cg(e,t,n){var r=e[t];(!(f2.call(e,t)&&Eg(r,n))||n===void 0&&!(t in e))&&kg(e,t,n)}function va(e,t,n,r){var i=!n;n||(n={});for(var s=-1,o=t.length;++s<o;){var l=t[s],a=void 0;a===void 0&&(a=e[l]),i?kg(n,l,a):Cg(n,l,a)}return n}function d2(e,t){for(var n=-1,r=Array(e);++n<e;)r[n]=t(n);return r}var h2="[object Arguments]";function yp(e){return ei(e)&&Jr(e)==h2}var Tg=Object.prototype,p2=Tg.hasOwnProperty,m2=Tg.propertyIsEnumerable,y2=yp(function(){return arguments}())?yp:function(e){return ei(e)&&p2.call(e,"callee")&&!m2.call(e,"callee")},fo=Array.isArray;function g2(){return!1}var Og=typeof vt=="object"&&vt&&!vt.nodeType&&vt,gp=Og&&typeof wt=="object"&&wt&&!wt.nodeType&&wt,v2=gp&&gp.exports===Og,vp=v2?pn.Buffer:void 0,w2=vp?vp.isBuffer:void 0,Rg=w2||g2,x2=9007199254740991,S2=/^(?:0|[1-9]\d*)$/;function b2(e,t){var n=typeof e;return t=t??x2,!!t&&(n=="number"||n!="symbol"&&S2.test(e))&&e>-1&&e%1==0&&e<t}var E2=9007199254740991;function Ng(e){return typeof e=="number"&&e>-1&&e%1==0&&e<=E2}var _2="[object Arguments]",k2="[object Array]",C2="[object Boolean]",T2="[object Date]",O2="[object Error]",R2="[object Function]",N2="[object Map]",P2="[object Number]",A2="[object Object]",j2="[object RegExp]",F2="[object Set]",$2="[object String]",I2="[object WeakMap]",D2="[object ArrayBuffer]",L2="[object DataView]",M2="[object Float32Array]",z2="[object Float64Array]",B2="[object Int8Array]",U2="[object Int16Array]",V2="[object Int32Array]",H2="[object Uint8Array]",W2="[object Uint8ClampedArray]",Q2="[object Uint16Array]",q2="[object Uint32Array]",ce={};ce[M2]=ce[z2]=ce[B2]=ce[U2]=ce[V2]=ce[H2]=ce[W2]=ce[Q2]=ce[q2]=!0;ce[_2]=ce[k2]=ce[D2]=ce[C2]=ce[L2]=ce[T2]=ce[O2]=ce[R2]=ce[N2]=ce[P2]=ce[A2]=ce[j2]=ce[F2]=ce[$2]=ce[I2]=!1;function K2(e){return ei(e)&&Ng(e.length)&&!!ce[Jr(e)]}function ad(e){return function(t){return e(t)}}var Pg=typeof vt=="object"&&vt&&!vt.nodeType&&vt,Rs=Pg&&typeof wt=="object"&&wt&&!wt.nodeType&&wt,Y2=Rs&&Rs.exports===Pg,gu=Y2&&wg.process,qi=function(){try{var e=Rs&&Rs.require&&Rs.require("util").types;return e||gu&&gu.binding&&gu.binding("util")}catch{}}(),wp=qi&&qi.isTypedArray,G2=wp?ad(wp):K2,X2=Object.prototype,Z2=X2.hasOwnProperty;function Ag(e,t){var n=fo(e),r=!n&&y2(e),i=!n&&!r&&Rg(e),s=!n&&!r&&!i&&G2(e),o=n||r||i||s,l=o?d2(e.length,String):[],a=l.length;for(var c in e)(t||Z2.call(e,c))&&!(o&&(c=="length"||i&&(c=="offset"||c=="parent")||s&&(c=="buffer"||c=="byteLength"||c=="byteOffset")||b2(c,a)))&&l.push(c);return l}var J2=Object.prototype;function ud(e){var t=e&&e.constructor,n=typeof t=="function"&&t.prototype||J2;return e===n}var ek=Sg(Object.keys,Object),tk=Object.prototype,nk=tk.hasOwnProperty;function rk(e){if(!ud(e))return ek(e);var t=[];for(var n in Object(e))nk.call(e,n)&&n!="constructor"&&t.push(n);return t}function jg(e){return e!=null&&Ng(e.length)&&!_g(e)}function cd(e){return jg(e)?Ag(e):rk(e)}function ik(e,t){return e&&va(t,cd(t),e)}function sk(e){var t=[];if(e!=null)for(var n in Object(e))t.push(n);return t}var ok=Object.prototype,lk=ok.hasOwnProperty;function ak(e){if(!co(e))return sk(e);var t=ud(e),n=[];for(var r in e)r=="constructor"&&(t||!lk.call(e,r))||n.push(r);return n}function fd(e){return jg(e)?Ag(e,!0):ak(e)}function uk(e,t){return e&&va(t,fd(t),e)}var Fg=typeof vt=="object"&&vt&&!vt.nodeType&&vt,xp=Fg&&typeof wt=="object"&&wt&&!wt.nodeType&&wt,ck=xp&&xp.exports===Fg,Sp=ck?pn.Buffer:void 0,bp=Sp?Sp.allocUnsafe:void 0;function fk(e,t){if(t)return e.slice();var n=e.length,r=bp?bp(n):new e.constructor(n);return e.copy(r),r}function $g(e,t){var n=-1,r=e.length;for(t||(t=Array(r));++n<r;)t[n]=e[n];return t}function dk(e,t){for(var n=-1,r=e==null?0:e.length,i=0,s=[];++n<r;){var o=e[n];t(o,n,e)&&(s[i++]=o)}return s}function Ig(){return[]}var hk=Object.prototype,pk=hk.propertyIsEnumerable,Ep=Object.getOwnPropertySymbols,dd=Ep?function(e){return e==null?[]:(e=Object(e),dk(Ep(e),function(t){return pk.call(e,t)}))}:Ig;function mk(e,t){return va(e,dd(e),t)}function Dg(e,t){for(var n=-1,r=t.length,i=e.length;++n<r;)e[i+n]=t[n];return e}var yk=Object.getOwnPropertySymbols,Lg=yk?function(e){for(var t=[];e;)Dg(t,dd(e)),e=ld(e);return t}:Ig;function gk(e,t){return va(e,Lg(e),t)}function Mg(e,t,n){var r=t(e);return fo(e)?r:Dg(r,n(e))}function vk(e){return Mg(e,cd,dd)}function wk(e){return Mg(e,fd,Lg)}var Bc=ni(pn,"DataView"),Uc=ni(pn,"Promise"),Vc=ni(pn,"Set"),Hc=ni(pn,"WeakMap"),_p="[object Map]",xk="[object Object]",kp="[object Promise]",Cp="[object Set]",Tp="[object WeakMap]",Op="[object DataView]",Sk=ti(Bc),bk=ti(Zs),Ek=ti(Uc),_k=ti(Vc),kk=ti(Hc),xn=Jr;(Bc&&xn(new Bc(new ArrayBuffer(1)))!=Op||Zs&&xn(new Zs)!=_p||Uc&&xn(Uc.resolve())!=kp||Vc&&xn(new Vc)!=Cp||Hc&&xn(new Hc)!=Tp)&&(xn=function(e){var t=Jr(e),n=t==xk?e.constructor:void 0,r=n?ti(n):"";if(r)switch(r){case Sk:return Op;case bk:return _p;case Ek:return kp;case _k:return Cp;case kk:return Tp}return t});var Ck=Object.prototype,Tk=Ck.hasOwnProperty;function Ok(e){var t=e.length,n=new e.constructor(t);return t&&typeof e[0]=="string"&&Tk.call(e,"index")&&(n.index=e.index,n.input=e.input),n}var Rp=pn.Uint8Array;function hd(e){var t=new e.constructor(e.byteLength);return new Rp(t).set(new Rp(e)),t}function Rk(e,t){var n=t?hd(e.buffer):e.buffer;return new e.constructor(n,e.byteOffset,e.byteLength)}var Nk=/\w*$/;function Pk(e){var t=new e.constructor(e.source,Nk.exec(e));return t.lastIndex=e.lastIndex,t}var Np=dr?dr.prototype:void 0,Pp=Np?Np.valueOf:void 0;function Ak(e){return Pp?Object(Pp.call(e)):{}}function jk(e,t){var n=t?hd(e.buffer):e.buffer;return new e.constructor(n,e.byteOffset,e.length)}var Fk="[object Boolean]",$k="[object Date]",Ik="[object Map]",Dk="[object Number]",Lk="[object RegExp]",Mk="[object Set]",zk="[object String]",Bk="[object Symbol]",Uk="[object ArrayBuffer]",Vk="[object DataView]",Hk="[object Float32Array]",Wk="[object Float64Array]",Qk="[object Int8Array]",qk="[object Int16Array]",Kk="[object Int32Array]",Yk="[object Uint8Array]",Gk="[object Uint8ClampedArray]",Xk="[object Uint16Array]",Zk="[object Uint32Array]";function Jk(e,t,n){var r=e.constructor;switch(t){case Uk:return hd(e);case Fk:case $k:return new r(+e);case Vk:return Rk(e,n);case Hk:case Wk:case Qk:case qk:case Kk:case Yk:case Gk:case Xk:case Zk:return jk(e,n);case Ik:return new r;case Dk:case zk:return new r(e);case Lk:return Pk(e);case Mk:return new r;case Bk:return Ak(e)}}var Ap=Object.create,eC=function(){function e(){}return function(t){if(!co(t))return{};if(Ap)return Ap(t);e.prototype=t;var n=new e;return e.prototype=void 0,n}}();function tC(e){return typeof e.constructor=="function"&&!ud(e)?eC(ld(e)):{}}var nC="[object Map]";function rC(e){return ei(e)&&xn(e)==nC}var jp=qi&&qi.isMap,iC=jp?ad(jp):rC,sC="[object Set]";function oC(e){return ei(e)&&xn(e)==sC}var Fp=qi&&qi.isSet,lC=Fp?ad(Fp):oC,aC=1,uC=2,cC=4,zg="[object Arguments]",fC="[object Array]",dC="[object Boolean]",hC="[object Date]",pC="[object Error]",Bg="[object Function]",mC="[object GeneratorFunction]",yC="[object Map]",gC="[object Number]",Ug="[object Object]",vC="[object RegExp]",wC="[object Set]",xC="[object String]",SC="[object Symbol]",bC="[object WeakMap]",EC="[object ArrayBuffer]",_C="[object DataView]",kC="[object Float32Array]",CC="[object Float64Array]",TC="[object Int8Array]",OC="[object Int16Array]",RC="[object Int32Array]",NC="[object Uint8Array]",PC="[object Uint8ClampedArray]",AC="[object Uint16Array]",jC="[object Uint32Array]",le={};le[zg]=le[fC]=le[EC]=le[_C]=le[dC]=le[hC]=le[kC]=le[CC]=le[TC]=le[OC]=le[RC]=le[yC]=le[gC]=le[Ug]=le[vC]=le[wC]=le[xC]=le[SC]=le[NC]=le[PC]=le[AC]=le[jC]=!0;le[pC]=le[Bg]=le[bC]=!1;function Ns(e,t,n,r,i,s){var o,l=t&aC,a=t&uC,c=t&cC;if(o!==void 0)return o;if(!co(e))return e;var f=fo(e);if(f){if(o=Ok(e),!l)return $g(e,o)}else{var u=xn(e),d=u==Bg||u==mC;if(Rg(e))return fk(e,l);if(u==Ug||u==zg||d&&!i){if(o=a||d?{}:tC(e),!l)return a?gk(e,uk(o,e)):mk(e,ik(o,e))}else{if(!le[u])return i?e:{};o=Jk(e,u,l)}}s||(s=new ts);var h=s.get(e);if(h)return h;s.set(e,o),lC(e)?e.forEach(function(S){o.add(Ns(S,t,n,S,e,s))}):iC(e)&&e.forEach(function(S,m){o.set(m,Ns(S,t,n,m,e,s))});var v=c?a?wk:vk:a?fd:cd,w=f?void 0:v(e);return u2(w||e,function(S,m){w&&(m=S,S=e[m]),Cg(o,m,Ns(S,t,n,m,e,s))}),o}var FC=1,$C=4;function Vo(e){return Ns(e,FC|$C)}var $p=Array.isArray,Ip=Object.keys,IC=Object.prototype.hasOwnProperty,DC=typeof Element<"u";function Wc(e,t){if(e===t)return!0;if(e&&t&&typeof e=="object"&&typeof t=="object"){var n=$p(e),r=$p(t),i,s,o;if(n&&r){if(s=e.length,s!=t.length)return!1;for(i=s;i--!==0;)if(!Wc(e[i],t[i]))return!1;return!0}if(n!=r)return!1;var l=e instanceof Date,a=t instanceof Date;if(l!=a)return!1;if(l&&a)return e.getTime()==t.getTime();var c=e instanceof RegExp,f=t instanceof RegExp;if(c!=f)return!1;if(c&&f)return e.toString()==t.toString();var u=Ip(e);if(s=u.length,s!==Ip(t).length)return!1;for(i=s;i--!==0;)if(!IC.call(t,u[i]))return!1;if(DC&&e instanceof Element&&t instanceof Element)return e===t;for(i=s;i--!==0;)if(o=u[i],!(o==="_owner"&&e.$$typeof)&&!Wc(e[o],t[o]))return!1;return!0}return e!==e&&t!==t}var LC=function(t,n){try{return Wc(t,n)}catch(r){if(r.message&&r.message.match(/stack|recursion/i)||r.number===-2146828260)return console.warn("Warning: react-fast-compare does not handle circular references.",r.name,r.message),!1;throw r}};const Er=Ki(LC);var MC=4;function Dp(e){return Ns(e,MC)}function Vg(e,t){for(var n=-1,r=e==null?0:e.length,i=Array(r);++n<r;)i[n]=t(e[n],n,e);return i}var zC="[object Symbol]";function pd(e){return typeof e=="symbol"||ei(e)&&Jr(e)==zC}var BC="Expected a function";function md(e,t){if(typeof e!="function"||t!=null&&typeof t!="function")throw new TypeError(BC);var n=function(){var r=arguments,i=t?t.apply(this,r):r[0],s=n.cache;if(s.has(i))return s.get(i);var o=e.apply(this,r);return n.cache=s.set(i,o)||s,o};return n.cache=new(md.Cache||gr),n}md.Cache=gr;var UC=500;function VC(e){var t=md(e,function(r){return n.size===UC&&n.clear(),r}),n=t.cache;return t}var HC=/[^.[\]]+|\[(?:(-?\d+(?:\.\d+)?)|(["'])((?:(?!\2)[^\\]|\\.)*?)\2)\]|(?=(?:\.|\[\])(?:\.|\[\]|$))/g,WC=/\\(\\)?/g,QC=VC(function(e){var t=[];return e.charCodeAt(0)===46&&t.push(""),e.replace(HC,function(n,r,i,s){t.push(i?s.replace(WC,"$1"):r||n)}),t}),qC=1/0;function KC(e){if(typeof e=="string"||pd(e))return e;var t=e+"";return t=="0"&&1/e==-qC?"-0":t}var YC=1/0,Lp=dr?dr.prototype:void 0,Mp=Lp?Lp.toString:void 0;function Hg(e){if(typeof e=="string")return e;if(fo(e))return Vg(e,Hg)+"";if(pd(e))return Mp?Mp.call(e):"";var t=e+"";return t=="0"&&1/e==-YC?"-0":t}function GC(e){return e==null?"":Hg(e)}function Wg(e){return fo(e)?Vg(e,KC):pd(e)?[e]:$g(QC(GC(e)))}var Qg={exports:{}},ie={};/** @license React v16.13.1
82
82
  * react-is.production.min.js
83
83
  *
84
84
  * Copyright (c) Facebook, Inc. and its affiliates.
85
85
  *
86
86
  * This source code is licensed under the MIT license found in the
87
87
  * LICENSE file in the root directory of this source tree.
88
- */var Ae=typeof Symbol=="function"&&Symbol.for,gd=Ae?Symbol.for("react.element"):60103,yd=Ae?Symbol.for("react.portal"):60106,wa=Ae?Symbol.for("react.fragment"):60107,xa=Ae?Symbol.for("react.strict_mode"):60108,Sa=Ae?Symbol.for("react.profiler"):60114,ba=Ae?Symbol.for("react.provider"):60109,Ea=Ae?Symbol.for("react.context"):60110,vd=Ae?Symbol.for("react.async_mode"):60111,_a=Ae?Symbol.for("react.concurrent_mode"):60111,ka=Ae?Symbol.for("react.forward_ref"):60112,Ca=Ae?Symbol.for("react.suspense"):60113,GC=Ae?Symbol.for("react.suspense_list"):60120,Ta=Ae?Symbol.for("react.memo"):60115,Oa=Ae?Symbol.for("react.lazy"):60116,XC=Ae?Symbol.for("react.block"):60121,ZC=Ae?Symbol.for("react.fundamental"):60117,JC=Ae?Symbol.for("react.responder"):60118,eT=Ae?Symbol.for("react.scope"):60119;function Et(e){if(typeof e=="object"&&e!==null){var t=e.$$typeof;switch(t){case gd:switch(e=e.type,e){case vd:case _a:case wa:case Sa:case xa:case Ca:return e;default:switch(e=e&&e.$$typeof,e){case Ea:case ka:case Oa:case Ta:case ba:return e;default:return t}}case yd:return t}}}function qy(e){return Et(e)===_a}ie.AsyncMode=vd;ie.ConcurrentMode=_a;ie.ContextConsumer=Ea;ie.ContextProvider=ba;ie.Element=gd;ie.ForwardRef=ka;ie.Fragment=wa;ie.Lazy=Oa;ie.Memo=Ta;ie.Portal=yd;ie.Profiler=Sa;ie.StrictMode=xa;ie.Suspense=Ca;ie.isAsyncMode=function(e){return qy(e)||Et(e)===vd};ie.isConcurrentMode=qy;ie.isContextConsumer=function(e){return Et(e)===Ea};ie.isContextProvider=function(e){return Et(e)===ba};ie.isElement=function(e){return typeof e=="object"&&e!==null&&e.$$typeof===gd};ie.isForwardRef=function(e){return Et(e)===ka};ie.isFragment=function(e){return Et(e)===wa};ie.isLazy=function(e){return Et(e)===Oa};ie.isMemo=function(e){return Et(e)===Ta};ie.isPortal=function(e){return Et(e)===yd};ie.isProfiler=function(e){return Et(e)===Sa};ie.isStrictMode=function(e){return Et(e)===xa};ie.isSuspense=function(e){return Et(e)===Ca};ie.isValidElementType=function(e){return typeof e=="string"||typeof e=="function"||e===wa||e===_a||e===Sa||e===xa||e===Ca||e===GC||typeof e=="object"&&e!==null&&(e.$$typeof===Oa||e.$$typeof===Ta||e.$$typeof===ba||e.$$typeof===Ea||e.$$typeof===ka||e.$$typeof===ZC||e.$$typeof===JC||e.$$typeof===eT||e.$$typeof===XC)};ie.typeOf=Et;Qy.exports=ie;var tT=Qy.exports,Ky=tT,nT={$$typeof:!0,render:!0,defaultProps:!0,displayName:!0,propTypes:!0},rT={$$typeof:!0,compare:!0,defaultProps:!0,displayName:!0,propTypes:!0,type:!0},Yy={};Yy[Ky.ForwardRef]=nT;Yy[Ky.Memo]=rT;function Oe(){return Oe=Object.assign||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},Oe.apply(this,arguments)}function Gy(e,t){if(e==null)return{};var n={},r=Object.keys(e),i,s;for(s=0;s<r.length;s++)i=r[s],!(t.indexOf(i)>=0)&&(n[i]=e[i]);return n}var Ra=b.createContext(void 0);Ra.displayName="FormikContext";Ra.Provider;Ra.Consumer;function iT(){var e=b.useContext(Ra);return e}var Mt=function(t){return typeof t=="function"},Na=function(t){return t!==null&&typeof t=="object"},sT=function(t){return String(Math.floor(Number(t)))===t},vu=function(t){return Object.prototype.toString.call(t)==="[object String]"},wu=function(t){return Na(t)&&Mt(t.then)};function ht(e,t,n,r){r===void 0&&(r=0);for(var i=Wy(t);e&&r<i.length;)e=e[i[r++]];return r!==i.length&&!e||e===void 0?n:e}function Mr(e,t,n){for(var r=Lp(e),i=r,s=0,o=Wy(t);s<o.length-1;s++){var l=o[s],a=ht(e,o.slice(0,s+1));if(a&&(Na(a)||Array.isArray(a)))i=i[l]=Lp(a);else{var c=o[s+1];i=i[l]=sT(c)&&Number(c)>=0?[]:{}}}return(s===0?e:i)[o[s]]===n?e:(n===void 0?delete i[o[s]]:i[o[s]]=n,s===0&&n===void 0&&delete r[o[s]],r)}function Xy(e,t,n,r){n===void 0&&(n=new WeakMap),r===void 0&&(r={});for(var i=0,s=Object.keys(e);i<s.length;i++){var o=s[i],l=e[o];Na(l)?n.get(l)||(n.set(l,!0),r[o]=Array.isArray(l)?[]:{},Xy(l,t,n,r[o])):r[o]=t}return r}function oT(e,t){switch(t.type){case"SET_VALUES":return Oe({},e,{values:t.payload});case"SET_TOUCHED":return Oe({},e,{touched:t.payload});case"SET_ERRORS":return Er(e.errors,t.payload)?e:Oe({},e,{errors:t.payload});case"SET_STATUS":return Oe({},e,{status:t.payload});case"SET_ISSUBMITTING":return Oe({},e,{isSubmitting:t.payload});case"SET_ISVALIDATING":return Oe({},e,{isValidating:t.payload});case"SET_FIELD_VALUE":return Oe({},e,{values:Mr(e.values,t.payload.field,t.payload.value)});case"SET_FIELD_TOUCHED":return Oe({},e,{touched:Mr(e.touched,t.payload.field,t.payload.value)});case"SET_FIELD_ERROR":return Oe({},e,{errors:Mr(e.errors,t.payload.field,t.payload.value)});case"RESET_FORM":return Oe({},e,t.payload);case"SET_FORMIK_STATE":return t.payload(e);case"SUBMIT_ATTEMPT":return Oe({},e,{touched:Xy(e.values,!0),isSubmitting:!0,submitCount:e.submitCount+1});case"SUBMIT_FAILURE":return Oe({},e,{isSubmitting:!1});case"SUBMIT_SUCCESS":return Oe({},e,{isSubmitting:!1});default:return e}}var xr={},Ho={};function lT(e){var t=e.validateOnChange,n=t===void 0?!0:t,r=e.validateOnBlur,i=r===void 0?!0:r,s=e.validateOnMount,o=s===void 0?!1:s,l=e.isInitialValid,a=e.enableReinitialize,c=a===void 0?!1:a,f=e.onSubmit,u=Gy(e,["validateOnChange","validateOnBlur","validateOnMount","isInitialValid","enableReinitialize","onSubmit"]),d=Oe({validateOnChange:n,validateOnBlur:i,validateOnMount:o,onSubmit:f},u),h=b.useRef(d.initialValues),v=b.useRef(d.initialErrors||xr),w=b.useRef(d.initialTouched||Ho),S=b.useRef(d.initialStatus),m=b.useRef(!1),p=b.useRef({});b.useEffect(function(){return m.current=!0,function(){m.current=!1}},[]);var y=b.useState(0),x=y[1],C=b.useRef({values:Vo(d.initialValues),errors:Vo(d.initialErrors)||xr,touched:Vo(d.initialTouched)||Ho,status:Vo(d.initialStatus),isSubmitting:!1,isValidating:!1,submitCount:0}),T=C.current,k=b.useCallback(function(E){var A=C.current;C.current=oT(A,E),A!==C.current&&x(function($){return $+1})},[]),R=b.useCallback(function(E,A){return new Promise(function($,z){var W=d.validate(E,A);W==null?$(xr):wu(W)?W.then(function(te){$(te||xr)},function(te){z(te)}):$(W)})},[d.validate]),I=b.useCallback(function(E,A){var $=d.validationSchema,z=Mt($)?$(A):$,W=A&&z.validateAt?z.validateAt(A,E):uT(E,z);return new Promise(function(te,we){W.then(function(){te(xr)},function(ft){ft.name==="ValidationError"?te(aT(ft)):we(ft)})})},[d.validationSchema]),D=b.useCallback(function(E,A){return new Promise(function($){return $(p.current[E].validate(A))})},[]),B=b.useCallback(function(E){var A=Object.keys(p.current).filter(function(z){return Mt(p.current[z].validate)}),$=A.length>0?A.map(function(z){return D(z,ht(E,z))}):[Promise.resolve("DO_NOT_DELETE_YOU_WILL_BE_FIRED")];return Promise.all($).then(function(z){return z.reduce(function(W,te,we){return te==="DO_NOT_DELETE_YOU_WILL_BE_FIRED"||te&&(W=Mr(W,A[we],te)),W},{})})},[D]),se=b.useCallback(function(E){return Promise.all([B(E),d.validationSchema?I(E):{},d.validate?R(E):{}]).then(function(A){var $=A[0],z=A[1],W=A[2],te=zc.all([$,z,W],{arrayMerge:cT});return te})},[d.validate,d.validationSchema,B,R,I]),oe=kt(function(E){return E===void 0&&(E=T.values),k({type:"SET_ISVALIDATING",payload:!0}),se(E).then(function(A){return m.current&&(k({type:"SET_ISVALIDATING",payload:!1}),k({type:"SET_ERRORS",payload:A})),A})});b.useEffect(function(){o&&m.current===!0&&Er(h.current,d.initialValues)&&oe(h.current)},[o,oe]);var He=b.useCallback(function(E){var A=E&&E.values?E.values:h.current,$=E&&E.errors?E.errors:v.current?v.current:d.initialErrors||{},z=E&&E.touched?E.touched:w.current?w.current:d.initialTouched||{},W=E&&E.status?E.status:S.current?S.current:d.initialStatus;h.current=A,v.current=$,w.current=z,S.current=W;var te=function(){k({type:"RESET_FORM",payload:{isSubmitting:!!E&&!!E.isSubmitting,errors:$,touched:z,status:W,values:A,isValidating:!!E&&!!E.isValidating,submitCount:E&&E.submitCount&&typeof E.submitCount=="number"?E.submitCount:0}})};if(d.onReset){var we=d.onReset(T.values,po);wu(we)?we.then(te):te()}else te()},[d.initialErrors,d.initialStatus,d.initialTouched,d.onReset]);b.useEffect(function(){m.current===!0&&!Er(h.current,d.initialValues)&&c&&(h.current=d.initialValues,He(),o&&oe(h.current))},[c,d.initialValues,He,o,oe]),b.useEffect(function(){c&&m.current===!0&&!Er(v.current,d.initialErrors)&&(v.current=d.initialErrors||xr,k({type:"SET_ERRORS",payload:d.initialErrors||xr}))},[c,d.initialErrors]),b.useEffect(function(){c&&m.current===!0&&!Er(w.current,d.initialTouched)&&(w.current=d.initialTouched||Ho,k({type:"SET_TOUCHED",payload:d.initialTouched||Ho}))},[c,d.initialTouched]),b.useEffect(function(){c&&m.current===!0&&!Er(S.current,d.initialStatus)&&(S.current=d.initialStatus,k({type:"SET_STATUS",payload:d.initialStatus}))},[c,d.initialStatus,d.initialTouched]);var We=kt(function(E){if(p.current[E]&&Mt(p.current[E].validate)){var A=ht(T.values,E),$=p.current[E].validate(A);return wu($)?(k({type:"SET_ISVALIDATING",payload:!0}),$.then(function(z){return z}).then(function(z){k({type:"SET_FIELD_ERROR",payload:{field:E,value:z}}),k({type:"SET_ISVALIDATING",payload:!1})})):(k({type:"SET_FIELD_ERROR",payload:{field:E,value:$}}),Promise.resolve($))}else if(d.validationSchema)return k({type:"SET_ISVALIDATING",payload:!0}),I(T.values,E).then(function(z){return z}).then(function(z){k({type:"SET_FIELD_ERROR",payload:{field:E,value:ht(z,E)}}),k({type:"SET_ISVALIDATING",payload:!1})});return Promise.resolve()}),K=b.useCallback(function(E,A){var $=A.validate;p.current[E]={validate:$}},[]),Qe=b.useCallback(function(E){delete p.current[E]},[]),P=kt(function(E,A){k({type:"SET_TOUCHED",payload:E});var $=A===void 0?i:A;return $?oe(T.values):Promise.resolve()}),L=b.useCallback(function(E){k({type:"SET_ERRORS",payload:E})},[]),H=kt(function(E,A){var $=Mt(E)?E(T.values):E;k({type:"SET_VALUES",payload:$});var z=A===void 0?n:A;return z?oe($):Promise.resolve()}),M=b.useCallback(function(E,A){k({type:"SET_FIELD_ERROR",payload:{field:E,value:A}})},[]),V=kt(function(E,A,$){k({type:"SET_FIELD_VALUE",payload:{field:E,value:A}});var z=$===void 0?n:$;return z?oe(Mr(T.values,E,A)):Promise.resolve()}),ee=b.useCallback(function(E,A){var $=A,z=E,W;if(!vu(E)){E.persist&&E.persist();var te=E.target?E.target:E.currentTarget,we=te.type,ft=te.name,Xt=te.id,ri=te.value,Fn=te.checked,xd=te.outerHTML,yo=te.options,vo=te.multiple;$=A||ft||Xt,z=/number|range/.test(we)?(W=parseFloat(ri),isNaN(W)?"":W):/checkbox/.test(we)?dT(ht(T.values,$),Fn,ri):yo&&vo?fT(yo):ri}$&&V($,z)},[V,T.values]),de=kt(function(E){if(vu(E))return function(A){return ee(A,E)};ee(E)}),Ce=kt(function(E,A,$){A===void 0&&(A=!0),k({type:"SET_FIELD_TOUCHED",payload:{field:E,value:A}});var z=$===void 0?i:$;return z?oe(T.values):Promise.resolve()}),Z=b.useCallback(function(E,A){E.persist&&E.persist();var $=E.target,z=$.name,W=$.id,te=$.outerHTML,we=A||z||W;Ce(we,!0)},[Ce]),Je=kt(function(E){if(vu(E))return function(A){return Z(A,E)};Z(E)}),mn=b.useCallback(function(E){Mt(E)?k({type:"SET_FORMIK_STATE",payload:E}):k({type:"SET_FORMIK_STATE",payload:function(){return E}})},[]),An=b.useCallback(function(E){k({type:"SET_STATUS",payload:E})},[]),jn=b.useCallback(function(E){k({type:"SET_ISSUBMITTING",payload:E})},[]),ns=kt(function(){return k({type:"SUBMIT_ATTEMPT"}),oe().then(function(E){var A=E instanceof Error,$=!A&&Object.keys(E).length===0;if($){var z;try{if(z=rs(),z===void 0)return}catch(W){throw W}return Promise.resolve(z).then(function(W){return m.current&&k({type:"SUBMIT_SUCCESS"}),W}).catch(function(W){if(m.current)throw k({type:"SUBMIT_FAILURE"}),W})}else if(m.current&&(k({type:"SUBMIT_FAILURE"}),A))throw E})}),ho=kt(function(E){E&&E.preventDefault&&Mt(E.preventDefault)&&E.preventDefault(),E&&E.stopPropagation&&Mt(E.stopPropagation)&&E.stopPropagation(),ns().catch(function(A){console.warn("Warning: An unhandled error was caught from submitForm()",A)})}),po={resetForm:He,validateForm:oe,validateField:We,setErrors:L,setFieldError:M,setFieldTouched:Ce,setFieldValue:V,setStatus:An,setSubmitting:jn,setTouched:P,setValues:H,setFormikState:mn,submitForm:ns},rs=kt(function(){return f(T.values,po)}),Pa=kt(function(E){E&&E.preventDefault&&Mt(E.preventDefault)&&E.preventDefault(),E&&E.stopPropagation&&Mt(E.stopPropagation)&&E.stopPropagation(),He()}),mo=b.useCallback(function(E){return{value:ht(T.values,E),error:ht(T.errors,E),touched:!!ht(T.touched,E),initialValue:ht(h.current,E),initialTouched:!!ht(w.current,E),initialError:ht(v.current,E)}},[T.errors,T.touched,T.values]),vr=b.useCallback(function(E){return{setValue:function($,z){return V(E,$,z)},setTouched:function($,z){return Ce(E,$,z)},setError:function($){return M(E,$)}}},[V,Ce,M]),go=b.useCallback(function(E){var A=Na(E),$=A?E.name:E,z=ht(T.values,$),W={name:$,value:z,onChange:de,onBlur:Je};if(A){var te=E.type,we=E.value,ft=E.as,Xt=E.multiple;te==="checkbox"?we===void 0?W.checked=!!z:(W.checked=!!(Array.isArray(z)&&~z.indexOf(we)),W.value=we):te==="radio"?(W.checked=z===we,W.value=we):ft==="select"&&Xt&&(W.value=W.value||[],W.multiple=!0)}return W},[Je,de,T.values]),ct=b.useMemo(function(){return!Er(h.current,T.values)},[h.current,T.values]),Aa=b.useMemo(function(){return typeof l<"u"?ct?T.errors&&Object.keys(T.errors).length===0:l!==!1&&Mt(l)?l(d):l:T.errors&&Object.keys(T.errors).length===0},[l,ct,T.errors,d]),ja=Oe({},T,{initialValues:h.current,initialErrors:v.current,initialTouched:w.current,initialStatus:S.current,handleBlur:Je,handleChange:de,handleReset:Pa,handleSubmit:ho,resetForm:He,setErrors:L,setFormikState:mn,setFieldTouched:Ce,setFieldValue:V,setFieldError:M,setStatus:An,setSubmitting:jn,setTouched:P,setValues:H,submitForm:ns,validateForm:oe,validateField:We,isValid:Aa,dirty:ct,unregisterField:Qe,registerField:K,getFieldProps:go,getFieldMeta:mo,getFieldHelpers:vr,validateOnBlur:i,validateOnChange:n,validateOnMount:o});return ja}function aT(e){var t={};if(e.inner){if(e.inner.length===0)return Mr(t,e.path,e.message);for(var i=e.inner,n=Array.isArray(i),r=0,i=n?i:i[Symbol.iterator]();;){var s;if(n){if(r>=i.length)break;s=i[r++]}else{if(r=i.next(),r.done)break;s=r.value}var o=s;ht(t,o.path)||(t=Mr(t,o.path,o.message))}}return t}function uT(e,t,n,r){n===void 0&&(n=!1);var i=Qc(e);return t[n?"validateSync":"validate"](i,{abortEarly:!1,context:i})}function Qc(e){var t=Array.isArray(e)?[]:{};for(var n in e)if(Object.prototype.hasOwnProperty.call(e,n)){var r=String(n);Array.isArray(e[r])===!0?t[r]=e[r].map(function(i){return Array.isArray(i)===!0||hp(i)?Qc(i):i!==""?i:void 0}):hp(e[r])?t[r]=Qc(e[r]):t[r]=e[r]!==""?e[r]:void 0}return t}function cT(e,t,n){var r=e.slice();return t.forEach(function(s,o){if(typeof r[o]>"u"){var l=n.clone!==!1,a=l&&n.isMergeableObject(s);r[o]=a?zc(Array.isArray(s)?[]:{},s,n):s}else n.isMergeableObject(s)?r[o]=zc(e[o],s,n):e.indexOf(s)===-1&&r.push(s)}),r}function fT(e){return Array.from(e).filter(function(t){return t.selected}).map(function(t){return t.value})}function dT(e,t,n){if(typeof e=="boolean")return!!t;var r=[],i=!1,s=-1;if(Array.isArray(e))r=e,s=e.indexOf(n),i=s>=0;else if(!n||n=="true"||n=="false")return!!t;return t&&n&&!i?r.concat(n):i?r.slice(0,s).concat(r.slice(s+1)):r}var hT=typeof window<"u"&&typeof window.document<"u"&&typeof window.document.createElement<"u"?b.useLayoutEffect:b.useEffect;function kt(e){var t=b.useRef(e);return hT(function(){t.current=e}),b.useCallback(function(){for(var n=arguments.length,r=new Array(n),i=0;i<n;i++)r[i]=arguments[i];return t.current.apply(void 0,r)},[])}var pT=b.forwardRef(function(e,t){var n=e.action,r=Gy(e,["action"]),i=n??"#",s=iT(),o=s.handleReset,l=s.handleSubmit;return b.createElement("form",Oe({onSubmit:l,ref:t,onReset:o,action:i},r))});pT.displayName="Form";const mT=({init:e,schema:t,action:n})=>lT({initialValues:e,validationSchema:t,validateOnBlur:!1,enableReinitialize:!0,validateOnChange:!1,validateOnMount:!1,onSubmit:r=>{n(r)}});function gT(e){if(typeof document>"u")return;let t=document.head||document.getElementsByTagName("head")[0],n=document.createElement("style");n.type="text/css",t.appendChild(n),n.styleSheet?n.styleSheet.cssText=e:n.appendChild(document.createTextNode(e))}const yT=e=>{switch(e){case"success":return xT;case"info":return bT;case"warning":return ST;case"error":return ET;default:return null}},vT=Array(12).fill(0),wT=({visible:e,className:t})=>N.createElement("div",{className:["sonner-loading-wrapper",t].filter(Boolean).join(" "),"data-visible":e},N.createElement("div",{className:"sonner-spinner"},vT.map((n,r)=>N.createElement("div",{className:"sonner-loading-bar",key:`spinner-bar-${r}`})))),xT=N.createElement("svg",{xmlns:"http://www.w3.org/2000/svg",viewBox:"0 0 20 20",fill:"currentColor",height:"20",width:"20"},N.createElement("path",{fillRule:"evenodd",d:"M10 18a8 8 0 100-16 8 8 0 000 16zm3.857-9.809a.75.75 0 00-1.214-.882l-3.483 4.79-1.88-1.88a.75.75 0 10-1.06 1.061l2.5 2.5a.75.75 0 001.137-.089l4-5.5z",clipRule:"evenodd"})),ST=N.createElement("svg",{xmlns:"http://www.w3.org/2000/svg",viewBox:"0 0 24 24",fill:"currentColor",height:"20",width:"20"},N.createElement("path",{fillRule:"evenodd",d:"M9.401 3.003c1.155-2 4.043-2 5.197 0l7.355 12.748c1.154 2-.29 4.5-2.599 4.5H4.645c-2.309 0-3.752-2.5-2.598-4.5L9.4 3.003zM12 8.25a.75.75 0 01.75.75v3.75a.75.75 0 01-1.5 0V9a.75.75 0 01.75-.75zm0 8.25a.75.75 0 100-1.5.75.75 0 000 1.5z",clipRule:"evenodd"})),bT=N.createElement("svg",{xmlns:"http://www.w3.org/2000/svg",viewBox:"0 0 20 20",fill:"currentColor",height:"20",width:"20"},N.createElement("path",{fillRule:"evenodd",d:"M18 10a8 8 0 11-16 0 8 8 0 0116 0zm-7-4a1 1 0 11-2 0 1 1 0 012 0zM9 9a.75.75 0 000 1.5h.253a.25.25 0 01.244.304l-.459 2.066A1.75 1.75 0 0010.747 15H11a.75.75 0 000-1.5h-.253a.25.25 0 01-.244-.304l.459-2.066A1.75 1.75 0 009.253 9H9z",clipRule:"evenodd"})),ET=N.createElement("svg",{xmlns:"http://www.w3.org/2000/svg",viewBox:"0 0 20 20",fill:"currentColor",height:"20",width:"20"},N.createElement("path",{fillRule:"evenodd",d:"M18 10a8 8 0 11-16 0 8 8 0 0116 0zm-8-5a.75.75 0 01.75.75v4.5a.75.75 0 01-1.5 0v-4.5A.75.75 0 0110 5zm0 10a1 1 0 100-2 1 1 0 000 2z",clipRule:"evenodd"})),_T=N.createElement("svg",{xmlns:"http://www.w3.org/2000/svg",width:"12",height:"12",viewBox:"0 0 24 24",fill:"none",stroke:"currentColor",strokeWidth:"1.5",strokeLinecap:"round",strokeLinejoin:"round"},N.createElement("line",{x1:"18",y1:"6",x2:"6",y2:"18"}),N.createElement("line",{x1:"6",y1:"6",x2:"18",y2:"18"})),kT=()=>{const[e,t]=N.useState(document.hidden);return N.useEffect(()=>{const n=()=>{t(document.hidden)};return document.addEventListener("visibilitychange",n),()=>window.removeEventListener("visibilitychange",n)},[]),e};let qc=1;class CT{constructor(){this.subscribe=t=>(this.subscribers.push(t),()=>{const n=this.subscribers.indexOf(t);this.subscribers.splice(n,1)}),this.publish=t=>{this.subscribers.forEach(n=>n(t))},this.addToast=t=>{this.publish(t),this.toasts=[...this.toasts,t]},this.create=t=>{var n;const{message:r,...i}=t,s=typeof(t==null?void 0:t.id)=="number"||((n=t.id)==null?void 0:n.length)>0?t.id:qc++,o=this.toasts.find(a=>a.id===s),l=t.dismissible===void 0?!0:t.dismissible;return this.dismissedToasts.has(s)&&this.dismissedToasts.delete(s),o?this.toasts=this.toasts.map(a=>a.id===s?(this.publish({...a,...t,id:s,title:r}),{...a,...t,id:s,dismissible:l,title:r}):a):this.addToast({title:r,...i,dismissible:l,id:s}),s},this.dismiss=t=>(this.dismissedToasts.add(t),t||this.toasts.forEach(n=>{this.subscribers.forEach(r=>r({id:n.id,dismiss:!0}))}),requestAnimationFrame(()=>this.subscribers.forEach(n=>n({id:t,dismiss:!0}))),t),this.message=(t,n)=>this.create({...n,message:t}),this.error=(t,n)=>this.create({...n,message:t,type:"error"}),this.success=(t,n)=>this.create({...n,type:"success",message:t}),this.info=(t,n)=>this.create({...n,type:"info",message:t}),this.warning=(t,n)=>this.create({...n,type:"warning",message:t}),this.loading=(t,n)=>this.create({...n,type:"loading",message:t}),this.promise=(t,n)=>{if(!n)return;let r;n.loading!==void 0&&(r=this.create({...n,promise:t,type:"loading",message:n.loading,description:typeof n.description!="function"?n.description:void 0}));const i=Promise.resolve(t instanceof Function?t():t);let s=r!==void 0,o;const l=i.then(async c=>{if(o=["resolve",c],N.isValidElement(c))s=!1,this.create({id:r,type:"default",message:c});else if(OT(c)&&!c.ok){s=!1;const u=typeof n.error=="function"?await n.error(`HTTP error! status: ${c.status}`):n.error,d=typeof n.description=="function"?await n.description(`HTTP error! status: ${c.status}`):n.description,h=typeof u=="object"?u:{message:u};this.create({id:r,type:"error",description:d,...h})}else if(c instanceof Error){s=!1;const u=typeof n.error=="function"?await n.error(c):n.error,d=typeof n.description=="function"?await n.description(c):n.description,h=typeof u=="object"?u:{message:u};this.create({id:r,type:"error",description:d,...h})}else if(n.success!==void 0){s=!1;const u=typeof n.success=="function"?await n.success(c):n.success,d=typeof n.description=="function"?await n.description(c):n.description,h=typeof u=="object"?u:{message:u};this.create({id:r,type:"success",description:d,...h})}}).catch(async c=>{if(o=["reject",c],n.error!==void 0){s=!1;const f=typeof n.error=="function"?await n.error(c):n.error,u=typeof n.description=="function"?await n.description(c):n.description,d=typeof f=="object"?f:{message:f};this.create({id:r,type:"error",description:u,...d})}}).finally(()=>{s&&(this.dismiss(r),r=void 0),n.finally==null||n.finally.call(n)}),a=()=>new Promise((c,f)=>l.then(()=>o[0]==="reject"?f(o[1]):c(o[1])).catch(f));return typeof r!="string"&&typeof r!="number"?{unwrap:a}:Object.assign(r,{unwrap:a})},this.custom=(t,n)=>{const r=(n==null?void 0:n.id)||qc++;return this.create({jsx:t(r),id:r,...n}),r},this.getActiveToasts=()=>this.toasts.filter(t=>!this.dismissedToasts.has(t.id)),this.subscribers=[],this.toasts=[],this.dismissedToasts=new Set}}const rt=new CT,TT=(e,t)=>{const n=(t==null?void 0:t.id)||qc++;return rt.addToast({title:e,...t,id:n}),n},OT=e=>e&&typeof e=="object"&&"ok"in e&&typeof e.ok=="boolean"&&"status"in e&&typeof e.status=="number",RT=TT,NT=()=>rt.toasts,PT=()=>rt.getActiveToasts(),zp=Object.assign(RT,{success:rt.success,info:rt.info,warning:rt.warning,error:rt.error,custom:rt.custom,message:rt.message,promise:rt.promise,dismiss:rt.dismiss,loading:rt.loading},{getHistory:NT,getToasts:PT});gT("[data-sonner-toaster][dir=ltr],html[dir=ltr]{--toast-icon-margin-start:-3px;--toast-icon-margin-end:4px;--toast-svg-margin-start:-1px;--toast-svg-margin-end:0px;--toast-button-margin-start:auto;--toast-button-margin-end:0;--toast-close-button-start:0;--toast-close-button-end:unset;--toast-close-button-transform:translate(-35%, -35%)}[data-sonner-toaster][dir=rtl],html[dir=rtl]{--toast-icon-margin-start:4px;--toast-icon-margin-end:-3px;--toast-svg-margin-start:0px;--toast-svg-margin-end:-1px;--toast-button-margin-start:0;--toast-button-margin-end:auto;--toast-close-button-start:unset;--toast-close-button-end:0;--toast-close-button-transform:translate(35%, -35%)}[data-sonner-toaster]{position:fixed;width:var(--width);font-family:ui-sans-serif,system-ui,-apple-system,BlinkMacSystemFont,Segoe UI,Roboto,Helvetica Neue,Arial,Noto Sans,sans-serif,Apple Color Emoji,Segoe UI Emoji,Segoe UI Symbol,Noto Color Emoji;--gray1:hsl(0, 0%, 99%);--gray2:hsl(0, 0%, 97.3%);--gray3:hsl(0, 0%, 95.1%);--gray4:hsl(0, 0%, 93%);--gray5:hsl(0, 0%, 90.9%);--gray6:hsl(0, 0%, 88.7%);--gray7:hsl(0, 0%, 85.8%);--gray8:hsl(0, 0%, 78%);--gray9:hsl(0, 0%, 56.1%);--gray10:hsl(0, 0%, 52.3%);--gray11:hsl(0, 0%, 43.5%);--gray12:hsl(0, 0%, 9%);--border-radius:8px;box-sizing:border-box;padding:0;margin:0;list-style:none;outline:0;z-index:999999999;transition:transform .4s ease}[data-sonner-toaster][data-lifted=true]{transform:translateY(-8px)}@media (hover:none) and (pointer:coarse){[data-sonner-toaster][data-lifted=true]{transform:none}}[data-sonner-toaster][data-x-position=right]{right:var(--offset-right)}[data-sonner-toaster][data-x-position=left]{left:var(--offset-left)}[data-sonner-toaster][data-x-position=center]{left:50%;transform:translateX(-50%)}[data-sonner-toaster][data-y-position=top]{top:var(--offset-top)}[data-sonner-toaster][data-y-position=bottom]{bottom:var(--offset-bottom)}[data-sonner-toast]{--y:translateY(100%);--lift-amount:calc(var(--lift) * var(--gap));z-index:var(--z-index);position:absolute;opacity:0;transform:var(--y);touch-action:none;transition:transform .4s,opacity .4s,height .4s,box-shadow .2s;box-sizing:border-box;outline:0;overflow-wrap:anywhere}[data-sonner-toast][data-styled=true]{padding:16px;background:var(--normal-bg);border:1px solid var(--normal-border);color:var(--normal-text);border-radius:var(--border-radius);box-shadow:0 4px 12px rgba(0,0,0,.1);width:var(--width);font-size:13px;display:flex;align-items:center;gap:6px}[data-sonner-toast]:focus-visible{box-shadow:0 4px 12px rgba(0,0,0,.1),0 0 0 2px rgba(0,0,0,.2)}[data-sonner-toast][data-y-position=top]{top:0;--y:translateY(-100%);--lift:1;--lift-amount:calc(1 * var(--gap))}[data-sonner-toast][data-y-position=bottom]{bottom:0;--y:translateY(100%);--lift:-1;--lift-amount:calc(var(--lift) * var(--gap))}[data-sonner-toast][data-styled=true] [data-description]{font-weight:400;line-height:1.4;color:#3f3f3f}[data-sonner-toaster][data-sonner-theme=dark] [data-description]{color:#e8e8e8}[data-sonner-toast][data-styled=true] [data-title]{font-weight:500;line-height:1.5;color:inherit}[data-sonner-toast][data-styled=true] [data-icon]{display:flex;height:16px;width:16px;position:relative;justify-content:flex-start;align-items:center;flex-shrink:0;margin-left:var(--toast-icon-margin-start);margin-right:var(--toast-icon-margin-end)}[data-sonner-toast][data-promise=true] [data-icon]>svg{opacity:0;transform:scale(.8);transform-origin:center;animation:sonner-fade-in .3s ease forwards}[data-sonner-toast][data-styled=true] [data-icon]>*{flex-shrink:0}[data-sonner-toast][data-styled=true] [data-icon] svg{margin-left:var(--toast-svg-margin-start);margin-right:var(--toast-svg-margin-end)}[data-sonner-toast][data-styled=true] [data-content]{display:flex;flex-direction:column;gap:2px}[data-sonner-toast][data-styled=true] [data-button]{border-radius:4px;padding-left:8px;padding-right:8px;height:24px;font-size:12px;color:var(--normal-bg);background:var(--normal-text);margin-left:var(--toast-button-margin-start);margin-right:var(--toast-button-margin-end);border:none;font-weight:500;cursor:pointer;outline:0;display:flex;align-items:center;flex-shrink:0;transition:opacity .4s,box-shadow .2s}[data-sonner-toast][data-styled=true] [data-button]:focus-visible{box-shadow:0 0 0 2px rgba(0,0,0,.4)}[data-sonner-toast][data-styled=true] [data-button]:first-of-type{margin-left:var(--toast-button-margin-start);margin-right:var(--toast-button-margin-end)}[data-sonner-toast][data-styled=true] [data-cancel]{color:var(--normal-text);background:rgba(0,0,0,.08)}[data-sonner-toaster][data-sonner-theme=dark] [data-sonner-toast][data-styled=true] [data-cancel]{background:rgba(255,255,255,.3)}[data-sonner-toast][data-styled=true] [data-close-button]{position:absolute;left:var(--toast-close-button-start);right:var(--toast-close-button-end);top:0;height:20px;width:20px;display:flex;justify-content:center;align-items:center;padding:0;color:var(--gray12);background:var(--normal-bg);border:1px solid var(--gray4);transform:var(--toast-close-button-transform);border-radius:50%;cursor:pointer;z-index:1;transition:opacity .1s,background .2s,border-color .2s}[data-sonner-toast][data-styled=true] [data-close-button]:focus-visible{box-shadow:0 4px 12px rgba(0,0,0,.1),0 0 0 2px rgba(0,0,0,.2)}[data-sonner-toast][data-styled=true] [data-disabled=true]{cursor:not-allowed}[data-sonner-toast][data-styled=true]:hover [data-close-button]:hover{background:var(--gray2);border-color:var(--gray5)}[data-sonner-toast][data-swiping=true]::before{content:'';position:absolute;left:-100%;right:-100%;height:100%;z-index:-1}[data-sonner-toast][data-y-position=top][data-swiping=true]::before{bottom:50%;transform:scaleY(3) translateY(50%)}[data-sonner-toast][data-y-position=bottom][data-swiping=true]::before{top:50%;transform:scaleY(3) translateY(-50%)}[data-sonner-toast][data-swiping=false][data-removed=true]::before{content:'';position:absolute;inset:0;transform:scaleY(2)}[data-sonner-toast]::after{content:'';position:absolute;left:0;height:calc(var(--gap) + 1px);bottom:100%;width:100%}[data-sonner-toast][data-mounted=true]{--y:translateY(0);opacity:1}[data-sonner-toast][data-expanded=false][data-front=false]{--scale:var(--toasts-before) * 0.05 + 1;--y:translateY(calc(var(--lift-amount) * var(--toasts-before))) scale(calc(-1 * var(--scale)));height:var(--front-toast-height)}[data-sonner-toast]>*{transition:opacity .4s}[data-sonner-toast][data-x-position=right]{right:0}[data-sonner-toast][data-x-position=left]{left:0}[data-sonner-toast][data-expanded=false][data-front=false][data-styled=true]>*{opacity:0}[data-sonner-toast][data-visible=false]{opacity:0;pointer-events:none}[data-sonner-toast][data-mounted=true][data-expanded=true]{--y:translateY(calc(var(--lift) * var(--offset)));height:var(--initial-height)}[data-sonner-toast][data-removed=true][data-front=true][data-swipe-out=false]{--y:translateY(calc(var(--lift) * -100%));opacity:0}[data-sonner-toast][data-removed=true][data-front=false][data-swipe-out=false][data-expanded=true]{--y:translateY(calc(var(--lift) * var(--offset) + var(--lift) * -100%));opacity:0}[data-sonner-toast][data-removed=true][data-front=false][data-swipe-out=false][data-expanded=false]{--y:translateY(40%);opacity:0;transition:transform .5s,opacity .2s}[data-sonner-toast][data-removed=true][data-front=false]::before{height:calc(var(--initial-height) + 20%)}[data-sonner-toast][data-swiping=true]{transform:var(--y) translateY(var(--swipe-amount-y,0)) translateX(var(--swipe-amount-x,0));transition:none}[data-sonner-toast][data-swiped=true]{user-select:none}[data-sonner-toast][data-swipe-out=true][data-y-position=bottom],[data-sonner-toast][data-swipe-out=true][data-y-position=top]{animation-duration:.2s;animation-timing-function:ease-out;animation-fill-mode:forwards}[data-sonner-toast][data-swipe-out=true][data-swipe-direction=left]{animation-name:swipe-out-left}[data-sonner-toast][data-swipe-out=true][data-swipe-direction=right]{animation-name:swipe-out-right}[data-sonner-toast][data-swipe-out=true][data-swipe-direction=up]{animation-name:swipe-out-up}[data-sonner-toast][data-swipe-out=true][data-swipe-direction=down]{animation-name:swipe-out-down}@keyframes swipe-out-left{from{transform:var(--y) translateX(var(--swipe-amount-x));opacity:1}to{transform:var(--y) translateX(calc(var(--swipe-amount-x) - 100%));opacity:0}}@keyframes swipe-out-right{from{transform:var(--y) translateX(var(--swipe-amount-x));opacity:1}to{transform:var(--y) translateX(calc(var(--swipe-amount-x) + 100%));opacity:0}}@keyframes swipe-out-up{from{transform:var(--y) translateY(var(--swipe-amount-y));opacity:1}to{transform:var(--y) translateY(calc(var(--swipe-amount-y) - 100%));opacity:0}}@keyframes swipe-out-down{from{transform:var(--y) translateY(var(--swipe-amount-y));opacity:1}to{transform:var(--y) translateY(calc(var(--swipe-amount-y) + 100%));opacity:0}}@media (max-width:600px){[data-sonner-toaster]{position:fixed;right:var(--mobile-offset-right);left:var(--mobile-offset-left);width:100%}[data-sonner-toaster][dir=rtl]{left:calc(var(--mobile-offset-left) * -1)}[data-sonner-toaster] [data-sonner-toast]{left:0;right:0;width:calc(100% - var(--mobile-offset-left) * 2)}[data-sonner-toaster][data-x-position=left]{left:var(--mobile-offset-left)}[data-sonner-toaster][data-y-position=bottom]{bottom:var(--mobile-offset-bottom)}[data-sonner-toaster][data-y-position=top]{top:var(--mobile-offset-top)}[data-sonner-toaster][data-x-position=center]{left:var(--mobile-offset-left);right:var(--mobile-offset-right);transform:none}}[data-sonner-toaster][data-sonner-theme=light]{--normal-bg:#fff;--normal-border:var(--gray4);--normal-text:var(--gray12);--success-bg:hsl(143, 85%, 96%);--success-border:hsl(145, 92%, 87%);--success-text:hsl(140, 100%, 27%);--info-bg:hsl(208, 100%, 97%);--info-border:hsl(221, 91%, 93%);--info-text:hsl(210, 92%, 45%);--warning-bg:hsl(49, 100%, 97%);--warning-border:hsl(49, 91%, 84%);--warning-text:hsl(31, 92%, 45%);--error-bg:hsl(359, 100%, 97%);--error-border:hsl(359, 100%, 94%);--error-text:hsl(360, 100%, 45%)}[data-sonner-toaster][data-sonner-theme=light] [data-sonner-toast][data-invert=true]{--normal-bg:#000;--normal-border:hsl(0, 0%, 20%);--normal-text:var(--gray1)}[data-sonner-toaster][data-sonner-theme=dark] [data-sonner-toast][data-invert=true]{--normal-bg:#fff;--normal-border:var(--gray3);--normal-text:var(--gray12)}[data-sonner-toaster][data-sonner-theme=dark]{--normal-bg:#000;--normal-bg-hover:hsl(0, 0%, 12%);--normal-border:hsl(0, 0%, 20%);--normal-border-hover:hsl(0, 0%, 25%);--normal-text:var(--gray1);--success-bg:hsl(150, 100%, 6%);--success-border:hsl(147, 100%, 12%);--success-text:hsl(150, 86%, 65%);--info-bg:hsl(215, 100%, 6%);--info-border:hsl(223, 43%, 17%);--info-text:hsl(216, 87%, 65%);--warning-bg:hsl(64, 100%, 6%);--warning-border:hsl(60, 100%, 9%);--warning-text:hsl(46, 87%, 65%);--error-bg:hsl(358, 76%, 10%);--error-border:hsl(357, 89%, 16%);--error-text:hsl(358, 100%, 81%)}[data-sonner-toaster][data-sonner-theme=dark] [data-sonner-toast] [data-close-button]{background:var(--normal-bg);border-color:var(--normal-border);color:var(--normal-text)}[data-sonner-toaster][data-sonner-theme=dark] [data-sonner-toast] [data-close-button]:hover{background:var(--normal-bg-hover);border-color:var(--normal-border-hover)}[data-rich-colors=true][data-sonner-toast][data-type=success]{background:var(--success-bg);border-color:var(--success-border);color:var(--success-text)}[data-rich-colors=true][data-sonner-toast][data-type=success] [data-close-button]{background:var(--success-bg);border-color:var(--success-border);color:var(--success-text)}[data-rich-colors=true][data-sonner-toast][data-type=info]{background:var(--info-bg);border-color:var(--info-border);color:var(--info-text)}[data-rich-colors=true][data-sonner-toast][data-type=info] [data-close-button]{background:var(--info-bg);border-color:var(--info-border);color:var(--info-text)}[data-rich-colors=true][data-sonner-toast][data-type=warning]{background:var(--warning-bg);border-color:var(--warning-border);color:var(--warning-text)}[data-rich-colors=true][data-sonner-toast][data-type=warning] [data-close-button]{background:var(--warning-bg);border-color:var(--warning-border);color:var(--warning-text)}[data-rich-colors=true][data-sonner-toast][data-type=error]{background:var(--error-bg);border-color:var(--error-border);color:var(--error-text)}[data-rich-colors=true][data-sonner-toast][data-type=error] [data-close-button]{background:var(--error-bg);border-color:var(--error-border);color:var(--error-text)}.sonner-loading-wrapper{--size:16px;height:var(--size);width:var(--size);position:absolute;inset:0;z-index:10}.sonner-loading-wrapper[data-visible=false]{transform-origin:center;animation:sonner-fade-out .2s ease forwards}.sonner-spinner{position:relative;top:50%;left:50%;height:var(--size);width:var(--size)}.sonner-loading-bar{animation:sonner-spin 1.2s linear infinite;background:var(--gray11);border-radius:6px;height:8%;left:-10%;position:absolute;top:-3.9%;width:24%}.sonner-loading-bar:first-child{animation-delay:-1.2s;transform:rotate(.0001deg) translate(146%)}.sonner-loading-bar:nth-child(2){animation-delay:-1.1s;transform:rotate(30deg) translate(146%)}.sonner-loading-bar:nth-child(3){animation-delay:-1s;transform:rotate(60deg) translate(146%)}.sonner-loading-bar:nth-child(4){animation-delay:-.9s;transform:rotate(90deg) translate(146%)}.sonner-loading-bar:nth-child(5){animation-delay:-.8s;transform:rotate(120deg) translate(146%)}.sonner-loading-bar:nth-child(6){animation-delay:-.7s;transform:rotate(150deg) translate(146%)}.sonner-loading-bar:nth-child(7){animation-delay:-.6s;transform:rotate(180deg) translate(146%)}.sonner-loading-bar:nth-child(8){animation-delay:-.5s;transform:rotate(210deg) translate(146%)}.sonner-loading-bar:nth-child(9){animation-delay:-.4s;transform:rotate(240deg) translate(146%)}.sonner-loading-bar:nth-child(10){animation-delay:-.3s;transform:rotate(270deg) translate(146%)}.sonner-loading-bar:nth-child(11){animation-delay:-.2s;transform:rotate(300deg) translate(146%)}.sonner-loading-bar:nth-child(12){animation-delay:-.1s;transform:rotate(330deg) translate(146%)}@keyframes sonner-fade-in{0%{opacity:0;transform:scale(.8)}100%{opacity:1;transform:scale(1)}}@keyframes sonner-fade-out{0%{opacity:1;transform:scale(1)}100%{opacity:0;transform:scale(.8)}}@keyframes sonner-spin{0%{opacity:1}100%{opacity:.15}}@media (prefers-reduced-motion){.sonner-loading-bar,[data-sonner-toast],[data-sonner-toast]>*{transition:none!important;animation:none!important}}.sonner-loader{position:absolute;top:50%;left:50%;transform:translate(-50%,-50%);transform-origin:center;transition:opacity .2s,transform .2s}.sonner-loader[data-visible=false]{opacity:0;transform:scale(.8) translate(-50%,-50%)}");function Wo(e){return e.label!==void 0}const AT=3,jT="24px",FT="16px",Bp=4e3,$T=356,IT=14,LT=45,DT=200;function Jt(...e){return e.filter(Boolean).join(" ")}function MT(e){const[t,n]=e.split("-"),r=[];return t&&r.push(t),n&&r.push(n),r}const zT=e=>{var t,n,r,i,s,o,l,a,c;const{invert:f,toast:u,unstyled:d,interacting:h,setHeights:v,visibleToasts:w,heights:S,index:m,toasts:p,expanded:y,removeToast:x,defaultRichColors:C,closeButton:T,style:k,cancelButtonStyle:R,actionButtonStyle:I,className:D="",descriptionClassName:B="",duration:se,position:oe,gap:He,expandByDefault:We,classNames:K,icons:Qe,closeButtonAriaLabel:P="Close toast"}=e,[L,H]=N.useState(null),[M,V]=N.useState(null),[ee,de]=N.useState(!1),[Ce,Z]=N.useState(!1),[Je,mn]=N.useState(!1),[An,jn]=N.useState(!1),[ns,ho]=N.useState(!1),[po,rs]=N.useState(0),[Pa,mo]=N.useState(0),vr=N.useRef(u.duration||se||Bp),go=N.useRef(null),ct=N.useRef(null),Aa=m===0,ja=m+1<=w,E=u.type,A=u.dismissible!==!1,$=u.className||"",z=u.descriptionClassName||"",W=N.useMemo(()=>S.findIndex(Q=>Q.toastId===u.id)||0,[S,u.id]),te=N.useMemo(()=>{var Q;return(Q=u.closeButton)!=null?Q:T},[u.closeButton,T]),we=N.useMemo(()=>u.duration||se||Bp,[u.duration,se]),ft=N.useRef(0),Xt=N.useRef(0),ri=N.useRef(0),Fn=N.useRef(null),[xd,yo]=oe.split("-"),vo=N.useMemo(()=>S.reduce((Q,Te,Le)=>Le>=W?Q:Q+Te.height,0),[S,W]),Sd=kT(),iv=u.invert||f,Fa=E==="loading";Xt.current=N.useMemo(()=>W*He+vo,[W,vo]),N.useEffect(()=>{vr.current=we},[we]),N.useEffect(()=>{de(!0)},[]),N.useEffect(()=>{const Q=ct.current;if(Q){const Te=Q.getBoundingClientRect().height;return mo(Te),v(Le=>[{toastId:u.id,height:Te,position:u.position},...Le]),()=>v(Le=>Le.filter(dt=>dt.toastId!==u.id))}},[v,u.id]),N.useLayoutEffect(()=>{if(!ee)return;const Q=ct.current,Te=Q.style.height;Q.style.height="auto";const Le=Q.getBoundingClientRect().height;Q.style.height=Te,mo(Le),v(dt=>dt.find(je=>je.toastId===u.id)?dt.map(je=>je.toastId===u.id?{...je,height:Le}:je):[{toastId:u.id,height:Le,position:u.position},...dt])},[ee,u.title,u.description,v,u.id]);const $n=N.useCallback(()=>{Z(!0),rs(Xt.current),v(Q=>Q.filter(Te=>Te.toastId!==u.id)),setTimeout(()=>{x(u)},DT)},[u,x,v,Xt]);N.useEffect(()=>{if(u.promise&&E==="loading"||u.duration===1/0||u.type==="loading")return;let Q;return y||h||Sd?(()=>{if(ri.current<ft.current){const dt=new Date().getTime()-ft.current;vr.current=vr.current-dt}ri.current=new Date().getTime()})():(()=>{vr.current!==1/0&&(ft.current=new Date().getTime(),Q=setTimeout(()=>{u.onAutoClose==null||u.onAutoClose.call(u,u),$n()},vr.current))})(),()=>clearTimeout(Q)},[y,h,u,E,Sd,$n]),N.useEffect(()=>{u.delete&&$n()},[$n,u.delete]);function sv(){var Q;if(Qe!=null&&Qe.loading){var Te;return N.createElement("div",{className:Jt(K==null?void 0:K.loader,u==null||(Te=u.classNames)==null?void 0:Te.loader,"sonner-loader"),"data-visible":E==="loading"},Qe.loading)}return N.createElement(wT,{className:Jt(K==null?void 0:K.loader,u==null||(Q=u.classNames)==null?void 0:Q.loader),visible:E==="loading"})}var bd,Ed;return N.createElement("li",{tabIndex:0,ref:ct,className:Jt(D,$,K==null?void 0:K.toast,u==null||(t=u.classNames)==null?void 0:t.toast,K==null?void 0:K.default,K==null?void 0:K[E],u==null||(n=u.classNames)==null?void 0:n[E]),"data-sonner-toast":"","data-rich-colors":(bd=u.richColors)!=null?bd:C,"data-styled":!(u.jsx||u.unstyled||d),"data-mounted":ee,"data-promise":!!u.promise,"data-swiped":ns,"data-removed":Ce,"data-visible":ja,"data-y-position":xd,"data-x-position":yo,"data-index":m,"data-front":Aa,"data-swiping":Je,"data-dismissible":A,"data-type":E,"data-invert":iv,"data-swipe-out":An,"data-swipe-direction":M,"data-expanded":!!(y||We&&ee),style:{"--index":m,"--toasts-before":m,"--z-index":p.length-m,"--offset":`${Ce?po:Xt.current}px`,"--initial-height":We?"auto":`${Pa}px`,...k,...u.style},onDragEnd:()=>{mn(!1),H(null),Fn.current=null},onPointerDown:Q=>{Fa||!A||(go.current=new Date,rs(Xt.current),Q.target.setPointerCapture(Q.pointerId),Q.target.tagName!=="BUTTON"&&(mn(!0),Fn.current={x:Q.clientX,y:Q.clientY}))},onPointerUp:()=>{var Q,Te,Le;if(An||!A)return;Fn.current=null;const dt=Number(((Q=ct.current)==null?void 0:Q.style.getPropertyValue("--swipe-amount-x").replace("px",""))||0),wo=Number(((Te=ct.current)==null?void 0:Te.style.getPropertyValue("--swipe-amount-y").replace("px",""))||0),je=new Date().getTime()-((Le=go.current)==null?void 0:Le.getTime()),_t=L==="x"?dt:wo,xo=Math.abs(_t)/je;if(Math.abs(_t)>=LT||xo>.11){rs(Xt.current),u.onDismiss==null||u.onDismiss.call(u,u),V(L==="x"?dt>0?"right":"left":wo>0?"down":"up"),$n(),jn(!0);return}else{var It,Lt;(It=ct.current)==null||It.style.setProperty("--swipe-amount-x","0px"),(Lt=ct.current)==null||Lt.style.setProperty("--swipe-amount-y","0px")}ho(!1),mn(!1),H(null)},onPointerMove:Q=>{var Te,Le,dt;if(!Fn.current||!A||((Te=window.getSelection())==null?void 0:Te.toString().length)>0)return;const je=Q.clientY-Fn.current.y,_t=Q.clientX-Fn.current.x;var xo;const It=(xo=e.swipeDirections)!=null?xo:MT(oe);!L&&(Math.abs(_t)>1||Math.abs(je)>1)&&H(Math.abs(_t)>Math.abs(je)?"x":"y");let Lt={x:0,y:0};const _d=wr=>1/(1.5+Math.abs(wr)/20);if(L==="y"){if(It.includes("top")||It.includes("bottom"))if(It.includes("top")&&je<0||It.includes("bottom")&&je>0)Lt.y=je;else{const wr=je*_d(je);Lt.y=Math.abs(wr)<Math.abs(je)?wr:je}}else if(L==="x"&&(It.includes("left")||It.includes("right")))if(It.includes("left")&&_t<0||It.includes("right")&&_t>0)Lt.x=_t;else{const wr=_t*_d(_t);Lt.x=Math.abs(wr)<Math.abs(_t)?wr:_t}(Math.abs(Lt.x)>0||Math.abs(Lt.y)>0)&&ho(!0),(Le=ct.current)==null||Le.style.setProperty("--swipe-amount-x",`${Lt.x}px`),(dt=ct.current)==null||dt.style.setProperty("--swipe-amount-y",`${Lt.y}px`)}},te&&!u.jsx&&E!=="loading"?N.createElement("button",{"aria-label":P,"data-disabled":Fa,"data-close-button":!0,onClick:Fa||!A?()=>{}:()=>{$n(),u.onDismiss==null||u.onDismiss.call(u,u)},className:Jt(K==null?void 0:K.closeButton,u==null||(r=u.classNames)==null?void 0:r.closeButton)},(Ed=Qe==null?void 0:Qe.close)!=null?Ed:_T):null,E||u.icon||u.promise?N.createElement("div",{"data-icon":"",className:Jt(K==null?void 0:K.icon,u==null||(i=u.classNames)==null?void 0:i.icon)},u.promise||u.type==="loading"&&!u.icon?u.icon||sv():null,u.type!=="loading"?u.icon||(Qe==null?void 0:Qe[E])||yT(E):null):null,N.createElement("div",{"data-content":"",className:Jt(K==null?void 0:K.content,u==null||(s=u.classNames)==null?void 0:s.content)},N.createElement("div",{"data-title":"",className:Jt(K==null?void 0:K.title,u==null||(o=u.classNames)==null?void 0:o.title)},u.jsx?u.jsx:typeof u.title=="function"?u.title():u.title),u.description?N.createElement("div",{"data-description":"",className:Jt(B,z,K==null?void 0:K.description,u==null||(l=u.classNames)==null?void 0:l.description)},typeof u.description=="function"?u.description():u.description):null),N.isValidElement(u.cancel)?u.cancel:u.cancel&&Wo(u.cancel)?N.createElement("button",{"data-button":!0,"data-cancel":!0,style:u.cancelButtonStyle||R,onClick:Q=>{Wo(u.cancel)&&A&&(u.cancel.onClick==null||u.cancel.onClick.call(u.cancel,Q),$n())},className:Jt(K==null?void 0:K.cancelButton,u==null||(a=u.classNames)==null?void 0:a.cancelButton)},u.cancel.label):null,N.isValidElement(u.action)?u.action:u.action&&Wo(u.action)?N.createElement("button",{"data-button":!0,"data-action":!0,style:u.actionButtonStyle||I,onClick:Q=>{Wo(u.action)&&(u.action.onClick==null||u.action.onClick.call(u.action,Q),!Q.defaultPrevented&&$n())},className:Jt(K==null?void 0:K.actionButton,u==null||(c=u.classNames)==null?void 0:c.actionButton)},u.action.label):null)};function Up(){if(typeof window>"u"||typeof document>"u")return"ltr";const e=document.documentElement.getAttribute("dir");return e==="auto"||!e?window.getComputedStyle(document.documentElement).direction:e}function BT(e,t){const n={};return[e,t].forEach((r,i)=>{const s=i===1,o=s?"--mobile-offset":"--offset",l=s?FT:jT;function a(c){["top","right","bottom","left"].forEach(f=>{n[`${o}-${f}`]=typeof c=="number"?`${c}px`:c})}typeof r=="number"||typeof r=="string"?a(r):typeof r=="object"?["top","right","bottom","left"].forEach(c=>{r[c]===void 0?n[`${o}-${c}`]=l:n[`${o}-${c}`]=typeof r[c]=="number"?`${r[c]}px`:r[c]}):a(l)}),n}const UT=N.forwardRef(function(t,n){const{invert:r,position:i="bottom-right",hotkey:s=["altKey","KeyT"],expand:o,closeButton:l,className:a,offset:c,mobileOffset:f,theme:u="light",richColors:d,duration:h,style:v,visibleToasts:w=AT,toastOptions:S,dir:m=Up(),gap:p=IT,icons:y,containerAriaLabel:x="Notifications"}=t,[C,T]=N.useState([]),k=N.useMemo(()=>Array.from(new Set([i].concat(C.filter(M=>M.position).map(M=>M.position)))),[C,i]),[R,I]=N.useState([]),[D,B]=N.useState(!1),[se,oe]=N.useState(!1),[He,We]=N.useState(u!=="system"?u:typeof window<"u"&&window.matchMedia&&window.matchMedia("(prefers-color-scheme: dark)").matches?"dark":"light"),K=N.useRef(null),Qe=s.join("+").replace(/Key/g,"").replace(/Digit/g,""),P=N.useRef(null),L=N.useRef(!1),H=N.useCallback(M=>{T(V=>{var ee;return(ee=V.find(de=>de.id===M.id))!=null&&ee.delete||rt.dismiss(M.id),V.filter(({id:de})=>de!==M.id)})},[]);return N.useEffect(()=>rt.subscribe(M=>{if(M.dismiss){const V=C.map(ee=>ee.id===M.id?{...ee,delete:!0}:ee);requestAnimationFrame(()=>{T(V)});return}setTimeout(()=>{Fw.flushSync(()=>{T(V=>{const ee=V.findIndex(de=>de.id===M.id);return ee!==-1?[...V.slice(0,ee),{...V[ee],...M},...V.slice(ee+1)]:[M,...V]})})})}),[C]),N.useEffect(()=>{if(u!=="system"){We(u);return}if(u==="system"&&(window.matchMedia&&window.matchMedia("(prefers-color-scheme: dark)").matches?We("dark"):We("light")),typeof window>"u")return;const M=window.matchMedia("(prefers-color-scheme: dark)");try{M.addEventListener("change",({matches:V})=>{We(V?"dark":"light")})}catch{M.addListener(({matches:ee})=>{try{We(ee?"dark":"light")}catch(de){console.error(de)}})}},[u]),N.useEffect(()=>{C.length<=1&&B(!1)},[C]),N.useEffect(()=>{const M=V=>{var ee;if(s.every(Z=>V[Z]||V.code===Z)){var Ce;B(!0),(Ce=K.current)==null||Ce.focus()}V.code==="Escape"&&(document.activeElement===K.current||(ee=K.current)!=null&&ee.contains(document.activeElement))&&B(!1)};return document.addEventListener("keydown",M),()=>document.removeEventListener("keydown",M)},[s]),N.useEffect(()=>{if(K.current)return()=>{P.current&&(P.current.focus({preventScroll:!0}),P.current=null,L.current=!1)}},[K.current]),N.createElement("section",{ref:n,"aria-label":`${x} ${Qe}`,tabIndex:-1,"aria-live":"polite","aria-relevant":"additions text","aria-atomic":"false",suppressHydrationWarning:!0},k.map((M,V)=>{var ee;const[de,Ce]=M.split("-");return C.length?N.createElement("ol",{key:M,dir:m==="auto"?Up():m,tabIndex:-1,ref:K,className:a,"data-sonner-toaster":!0,"data-sonner-theme":He,"data-y-position":de,"data-lifted":D&&C.length>1&&!o,"data-x-position":Ce,style:{"--front-toast-height":`${((ee=R[0])==null?void 0:ee.height)||0}px`,"--width":`${$T}px`,"--gap":`${p}px`,...v,...BT(c,f)},onBlur:Z=>{L.current&&!Z.currentTarget.contains(Z.relatedTarget)&&(L.current=!1,P.current&&(P.current.focus({preventScroll:!0}),P.current=null))},onFocus:Z=>{Z.target instanceof HTMLElement&&Z.target.dataset.dismissible==="false"||L.current||(L.current=!0,P.current=Z.relatedTarget)},onMouseEnter:()=>B(!0),onMouseMove:()=>B(!0),onMouseLeave:()=>{se||B(!1)},onDragEnd:()=>B(!1),onPointerDown:Z=>{Z.target instanceof HTMLElement&&Z.target.dataset.dismissible==="false"||oe(!0)},onPointerUp:()=>oe(!1)},C.filter(Z=>!Z.position&&V===0||Z.position===M).map((Z,Je)=>{var mn,An;return N.createElement(zT,{key:Z.id,icons:y,index:Je,toast:Z,defaultRichColors:d,duration:(mn=S==null?void 0:S.duration)!=null?mn:h,className:S==null?void 0:S.className,descriptionClassName:S==null?void 0:S.descriptionClassName,invert:r,visibleToasts:w,closeButton:(An=S==null?void 0:S.closeButton)!=null?An:l,interacting:se,position:M,style:S==null?void 0:S.style,unstyled:S==null?void 0:S.unstyled,classNames:S==null?void 0:S.classNames,cancelButtonStyle:S==null?void 0:S.cancelButtonStyle,actionButtonStyle:S==null?void 0:S.actionButtonStyle,closeButtonAriaLabel:S==null?void 0:S.closeButtonAriaLabel,removeToast:H,toasts:C.filter(jn=>jn.position==Z.position),heights:R.filter(jn=>jn.position==Z.position),setHeights:I,expandByDefault:o,gap:p,expanded:D,swipeDirections:t.swipeDirections})})):null}))});function VT(e){return Array.isArray(e)&&e[0].field!==void 0}const HT=(e,t)=>{var n;if(VT(e)){for(const r of e)(n=t==null?void 0:t.form)==null||n.setFieldError(r.field,r.message);return}if(e&&e.message){t!=null&&t.noToast||zp.error(e.message);return}if(e&&e.error){t!=null&&t.noToast||zp.error(e.error);return}};function WT(e,t,n){let r=n;r||(r=Object.keys(e));for(let i of r){if(Array.isArray(e[i])&&Array.isArray(t[i])){if(e[i].length!==t[i].length)return!1;for(let s=0;s<e[i].length;s++)if(e[i][s]!==t[i][s])return!1;continue}if(e[i]!==t[i])return!1}return!0}function QT({id:e,text:t,required:n,className:r,noMargin:i}){return t?_.jsxs("label",{htmlFor:e,className:qt(r,{"lc-mb-2":!i},"lc-inline-block lc-text-base lc-font-medium lc-text-gray-700"),children:[t," ",n&&_.jsx("span",{className:"lc-text-red-500",children:"*"})]}):null}const xu={sm:"lc-px-3 lc-py-1 lc-text-xs",md:"lc-px-4 lc-py-2 lc-text-sm",lg:"lc-px-5 lc-py-3 lc-text-15"};function Zy({id:e,label:t,suffix:n,prefix:r,size:i="md",type:s="text",noMargin:o=!1,required:l=!1,error:a,ariaDescribedBy:c,className:f,ariaInvalid:u,ariaLabel:d,autoFocus:h,...v}){return _.jsxs("div",{className:qt({"lc-mb-3":!o},f),children:[_.jsx(QT,{id:e,text:t,required:l}),_.jsxs("div",{className:"lc-flex lc-items-center",children:[r&&_.jsx("span",{className:qt("lc-inline-block lc-border lc-border-r-0 lc-border-slate-200 lc-bg-slate-100 lc-rounded-l-md",xu[i],{"!lc-border-red-500":!!a}),children:r}),_.jsx("input",{id:e,className:qt("lc-text-gray-800 lc-border lc-rounded-md lc-block lc-text-base lc-py-2 lc-px-4 lc-w-full lc-border-slate-200 focus:lc-outline-none focus:lc-border-custom-500 disabled:lc-bg-slate-100 disabled:lc-border-slate-300 disabled:lc-text-slate-500 placeholder:lc-text-slate-400",xu[i],{"lc-rounded-l-none":!!r,"lc-rounded-r-none":!!n,"!lc-border-red-500 !lc-text-red-500":!!a}),type:s,required:l,"aria-describedby":c,"aria-invalid":u,"aria-label":d,...v}),n&&_.jsx("span",{className:qt("lc-inline-block lc-border lc-border-l-0 lc-border-slate-200 lc-bg-slate-100 lc-rounded-r-md",xu[i],{"!lc-border-red-500":!!a}),children:n})]}),!!a&&_.jsx("p",{className:"lc-mt-1 lc-text-sm lc-text-red-500",children:a})]})}const qT=(e,t)=>{document.cookie=`${e}=${t}`},Jy=b.createContext({}),ev=()=>`${window.location.pathname}_$$_${document.title}`,KT=()=>{const e=localStorage.getItem("lc-page");return!e||e===""?"/":ev()},YT=()=>{const e=localStorage.getItem("lc-p-history");if(!e||e==="")return[];try{return JSON.parse(e)}catch{return[]}};function GT({children:e}){const[t,n]=b.useState("/"),[r,i]=b.useState(YT());function s(){i([]),localStorage.removeItem("lc-p-history")}const o=l=>{n(l),i(a=>[...new Set([...a,l])]),localStorage.setItem("lc-page",l),localStorage.setItem("lc-p-history",JSON.stringify(r))};return b.useEffect(()=>{o(ev())},[]),_.jsx(Jy.Provider,{value:{page:t,setPage:o,history:r,clearHistory:s},children:e})}function wd(){return b.useContext(Jy)}function XT({label:e,id:t,value:n="",className:r,placeholder:i,children:s,required:o,error:l,...a}){return _.jsxs("div",{className:r||"",children:[e&&_.jsxs("label",{htmlFor:t,className:"lc-inline-block lc-mb-2 lc-text-base lc-font-medium",children:[e," ",o&&_.jsx("span",{className:"lc-text-red-500",children:"*"})]}),_.jsx("select",{id:t,"aria-placeholder":i,value:n,"aria-label":e,className:"lc-bg-light lc-form-select dark:lc-bg-zink-700 dark:lc-border-zink-500 lc-transition-colors lc-duration-200 lc-border lc-text-gray-900 dark:lc-text-gray-200 sm:lc-text-sm lc-rounded-md focus:lc-ring-emerald-500 lc-focus-visible:lc-ring-0 lc-focus-visible:lc-shadow-none lc-outline-none lc-focus-visible:lc-outline-none lc-focus-visible:lc-border-emerald-500 focus:lc-border-emerald-500 lc-block lc-w-full lc-px-2 lc-py-2 lc-placeholder-fuchsia-600 lc-caret-emerald-500",onChange:a.onChange,required:o,...a,children:s}),!!l&&_.jsx("p",{className:"lc-mt-1 lc-text-sm lc-text-red-500",children:l})]})}const Vp={ring:{label:"",input:"lc-relative before:content[''] before:absolute before:top-2/4 before:left-2/4 before:block before:h-12 before:w-12 before:-translate-y-2/4 before:-translate-x-2/4 before:rounded-full before:bg-blue-gray-500 before:opacity-0 before:transition-opacity hover:before:opacity-10"},hover:{label:"hover:lc-bg-secondary lc-transition-colors lc-duration-200 lc-px-2 lc-py-1 lc-rounded-md",input:""}},ZT={blue:"lc-checked:lc-border-blue-500 lc-checked:lc-bg-blue-500 lc-checked:before:lc-bg-blue-500",indigo:"lc-checked:lc-border-indigo-500 lc-checked:lc-bg-indigo-500 lc-checked:before:lc-bg-indigo-500",green:"lc-checked:lc-border-green-500 lc-checked:lc-bg-green-500 lc-checked:before:lc-bg-green-500",red:"lc-checked:lc-border-red-500 lc-checked:lc-bg-red-500 lc-checked:before:lc-bg-red-500",orange:"lc-checked:lc-border-orange-500 lc-checked:lc-bg-orange-500 lc-checked:before:lc-bg-orange-500"},JT={sm:"lc-h-4 lc-w-4 lg:lc-h-3 lg:lc-w-3",md:"lc-h-6 lc-w-6 lg:lc-h-5 lg:lc-w-5",lg:"lc-h-8 lc-w-8 lg:lc-h-7 lg:lc-w-7"},eO={sm:"lc-h-3 lc-w-3 lg:lc-h-2.5 lg:lc-w-2.5",md:"lc-h-5 lc-w-5 lg:lc-h-4 lg:lc-w-4",lg:"lc-h-7 lc-w-7 lg:lc-h-6 lg:lc-w-6"};function tO({children:e,name:t,required:n,value:r,checked:i,onChange:s,onBlur:o,red:l,id:a=t,size:c="md",effect:f="ring",reversed:u=!1,variant:d="blue",...h}){return _.jsxs("div",{children:[_.jsxs("div",{className:`lc-flex lc-items-center lc-justify-between ${u?"lc-flex-row-reverse":""} ${Vp[f].label}`,children:[_.jsxs("label",{className:"lc-disable-highlight lc-relative lc-mr-3 lc-flex lc-cursor-pointer lc-items-center lc-rounded-full",htmlFor:a,children:[_.jsx("input",{id:a,name:t,type:"checkbox",className:`lc-border-blue-gray-200 lc-peer lc-cursor-pointer lc-appearance-none lc-rounded-md lc-border lc-bg-white lc-transition-all dark:lc-bg-inherit ${ZT[d]} ${JT[c]} ${Vp[f].input}`,required:n,checked:i,value:r,onChange:v=>s==null?void 0:s(v.target.checked),onBlur:v=>o==null?void 0:o(v.target.checked),...h}),_.jsx("div",{className:"lc-pointer-events-none lc-absolute lc-left-2/4 lc-top-2/4 lc-translate-x-2/4 lc-translate-y-2/4 lc-text-white lc-opacity-0 lc-transition-opacity lc-peer-checked:lc-opacity-100",children:_.jsx(Ve.Check,{className:eO[c]})})]}),_.jsx("label",{className:"lc-disable-highlight lc-mt-px lc-flex lc-grow lc-cursor-pointer lc-select-none lc-items-center lc-justify-between lc-font-light lc-text-gray-800 dark:lc-text-gray-400",htmlFor:a,children:e})]}),l&&_.jsx("small",{className:"lc-text-xs lc-text-red-500",children:l})]})}const nO={blue:"lc-text-blue-500 lc-border-blue-gray-200 checked:lc-bg-blue-500 checked:lc-border-blue-500 checked:before:lc-bg-blue-500 before:lc-bg-gray-500",red:"lc-text-red-500 lc-border-blue-gray-200 checked:lc-border-red-500 checked:before:lc-bg-red-500 before:lc-bg-blue-gray-500",emerald:"lc-text-emerald-500 lc-border-blue-gray-200 checked:lc-border-emerald-500 checked:before:lc-bg-emerald-500 before:lc-bg-blue-gray-500",orange:"lc-text-orange-500 lc-border-blue-gray-200 checked:lc-border-orange-500 checked:before:lc-bg-orange-500 before:lc-bg-blue-gray-500"},rO={blue:"lc-text-white",red:"lc-text-red-500",emerald:"lc-text-emerald-500",orange:"lc-text-orange-500"},Hp={sm:"lc-h-4 lc-w-4 lg:lc-h-3 lg:lc-w-3",md:"lc-h-6 lc-w-6 lg:lc-h-5 lg:lc-w-5",lg:"lc-h-8 lc-w-8 lg:lc-h-7 lg:lc-w-7"},iO={sm:"lc-size-3",md:"lc-size-4",lg:"lc-size-5"},Wp={ring:{label:"",input:"lc-relative before:lc-content[''] before:lc-absolute before:lc-top-2/4 before:lc-left-2/4 before:lc-block before:lc-h-9 before:lc-w-9 before:-lc-translate-y-2/4 before:-lc-translate-x-2/4 before:lc-rounded-full before:lc-opacity-0 before:lc-transition-opacity hover:before:lc-opacity-10"},hover:{label:"hover:lc-bg-secondary lc-transition-colors lc-duration-200",input:""}};function Kc({children:e,id:t,name:n,size:r="md",variant:i="blue",effect:s="ring",value:o=!1,reverse:l=!1,onChange:a,onBlur:c,onClick:f}){return _.jsxs("label",{className:`lc-disable-highlight lc-flex lc-cursor-pointer lc-items-center lc-rounded-md ${l?"lc-flex-row-reverse lc-justify-between":""} ${Wp[s].label} `,htmlFor:t,children:[_.jsxs("label",{className:"lc-relative lc-flex lc-items-center lc-p-2 lc-rounded-full lc-cursor-pointer lc-disable-highlight",htmlFor:t,children:[_.jsx("input",{id:t,name:n,type:"radio",className:`lc-peer lc-disable-highlight lc-bg-none lc-cursor-pointer lc-appearance-none lc-rounded-full lc-border lc-bg-inherit lc-transition-all ${nO[i]} ${Hp[r]} ${Wp[s].input}`,checked:o,onChange:u=>a==null?void 0:a(u.target.checked),onBlur:u=>c==null?void 0:c(u.target.checked),onClick:()=>f==null?void 0:f(!o)}),_.jsx("div",{className:`lc-pointer-events-none lc-absolute lc-flex lc-items-center lc-justify-center lc-opacity-0 lc-transition-opacity peer-checked:lc-opacity-100 ${rO[i]} ${Hp[r]}`,children:_.jsx(Ve.Check,{className:iO[r]})})]}),_.jsx("label",{className:"lc-text-gray-800 lc-disable-highlight lc-flex lc-cursor-pointer lc-select-none lc-items-center lc-font-light lc-text-gray-500",htmlFor:t,children:e})]})}Kc.Group=function({label:t,id:n,className:r,required:i,children:s}){return _.jsxs("div",{className:r,children:[_.jsxs("label",{htmlFor:n,className:"lc-inline-block lc-mb-2 lc-text-base lc-font-medium",children:[t," ",i&&_.jsx("span",{className:"lc-text-red-500",children:"*"})]}),_.jsx("div",{className:"lc-col-span-12 lc-flex lc-flex-col lc-justify-center",children:s})]})};function sO({onOk:e,clientId:t,widgetId:n,appearance:r}){var d,h,v,w,S,m,p,y;const{defaultValues:i}=gr(),s=wd(),o=Xb(),l=(h=(d=r==null?void 0:r.body)==null?void 0:d.inputs)==null?void 0:h.reduce((x,C)=>{const T=ul(C.name);return x[C.name]=T||(i==null?void 0:i[C.name])||"",x},{}),a=(w=(v=r==null?void 0:r.body)==null?void 0:v.inputs)==null?void 0:w.reduce((x,C)=>(x[C.name]="",x),{}),c=yy((m=(S=r==null?void 0:r.body)==null?void 0:S.inputs)==null?void 0:m.reduce((x,C)=>(x[C.name]=C.required?Mc().required(C.label):Mc(),x),{})),f=mT({init:{...l},schema:c,action:async x=>{var k;const[C,T]=await o.mutateAsync({inputs:x,history:s.history,client_id:t,widget_id:n});if(yg(T)){s.clearHistory();for(const R of((k=r==null?void 0:r.body)==null?void 0:k.inputs)||[])qT(R.name,x[R.name]);e==null||e();return}HT(C,{form:f})}}),u=!WT(a,f.values);return _.jsx("section",{className:"lc-overflow-y-auto lc-p-4",style:{height:"calc(100% - 13rem)"},children:_.jsxs("form",{className:"lc-grid lc-grid-cols-1 lc-gap-4",onSubmit:x=>{x.preventDefault(),f.handleSubmit()},children:[(y=(p=r==null?void 0:r.body)==null?void 0:p.inputs)==null?void 0:y.map(x=>{var C,T;if(["text","email","phone"].includes(x.type))return _.jsx(Zy,{id:x.name,name:x.name,type:x.type,value:f.values[x.name],onChange:f.handleChange,onBlur:f.handleBlur,autoComplete:"off",placeholder:x.placeholder,error:f.errors[x.name],ariaInvalid:f.errors.name?!0:void 0,required:!0,noMargin:!0},x.name);if(x.type==="select")return _.jsx(XT,{id:x.name,name:x.name,value:f.values[x.name],onChange:f.handleChange,label:x.label,children:(C=x.options)==null?void 0:C.map(k=>_.jsx("option",{value:k,children:k},k))},x.name);if(x.type==="checkbox")return _.jsx(tO,{id:x.name,name:x.name,value:f.values[x.name],onChange:f.handleChange,children:x.label},x.name);if(x.type==="radio")return _.jsx(Kc.Group,{id:x.name,label:x.label,required:x.required,children:(T=x.options)==null?void 0:T.map(k=>_.jsx(Kc,{onChange:R=>{R?f.setFieldValue(x.name,k):f.setFieldValue(x.name,"")},id:k,name:x.name,value:k===f.values[x.name],children:k},k))},x.name)}),_.jsx(Gs,{type:"submit",disabled:!u,children:"Sohbet Oluştur"})]})})}function oO({image_url:e,name:t,size:n="lc-size-9"}){return e?_.jsx("img",{src:e,alt:t,className:qt("lc-rounded-md",n)}):_.jsx("div",{className:"lc-flex lc-items-center lc-justify-center lc-gap-1",children:_.jsx(Ve.Website,{className:qt("lc-text-slate-500",n)})})}const tv=(e,t,n)=>{const r=typeof window<"u"?window:void 0;b.useEffect(()=>(r.addEventListener(e,t),()=>{r.removeEventListener(e,t,!1)}),[e,t,r])};function lO(){const e=wd(),t=b.useCallback(()=>{const n=window.location.pathname;n!==e.page&&e.setPage(n)},[e.page]);return tv("popstate",t),null}function aO(){const e=uo(),t=wd(),n=b.useCallback(()=>{const r=window.location.pathname;if(r!==t.page){if(e){e.emit(fn.PageChange,{page:r});return}t.setPage(r)}},[e,t.page]);return tv("popstate",n),b.useEffect(()=>{if(!e)return;const r=setTimeout(()=>{KT()!==t.page&&e.emit(fn.PageChange,{page:t.page})},1e3);return()=>{clearTimeout(r)}},[e,t.page]),null}function uO({children:e}){const{widget:t}=gr();return t?_.jsxs("section",{className:"lc-h-full lc-w-full lc-relative",children:[_.jsx("div",{className:"-lc-z-10 lc-h-52 lc-bg-zink-600 lc-absolute lc-top-0 lc-left-0 lc-w-full lc-rounded-t-md lc-flex lc-flex-col lc-gap-4 lc-items-center lc-justify-center"}),e]}):null}function cO(){return lO(),null}const Su=(e,t)=>{var n;return(n=e.find(r=>r.type===t))==null?void 0:n.content};function fO(){var l,a,c,f,u,d;const{widget:e}=gr(),[t,n]=b.useState(!0),r=td();if(!e||(b.useEffect(()=>{Zb(e.client_id).then(([h,v])=>{yg(v)&&r.push("chat")}).finally(()=>{n(!1)})},[]),t))return null;const i=Su(((a=(l=e.appearance)==null?void 0:l.head)==null?void 0:a.elements)||[],"text"),s=Su(((f=(c=e.appearance)==null?void 0:c.head)==null?void 0:f.elements)||[],"title"),o=Su(((d=(u=e.appearance)==null?void 0:u.head)==null?void 0:d.elements)||[],"logo");return _.jsxs(_.Fragment,{children:[_.jsx(ly,{children:_.jsxs(uO,{children:[_.jsxs("div",{className:"lc-flex lc-flex-col lc-gap-3 lc-items-center lc-justify-center lc-h-52",children:[o&&_.jsx(oO,{name:e.name,image_url:o,size:"lc-size-24"}),s&&_.jsx("div",{className:"lc-text-white lc-text-lg lc-font-bold lc-ml-2",children:s}),i&&_.jsx("div",{className:"lc-text-white lc-text-sm",children:i})]}),_.jsx(sO,{clientId:e.client_id,widgetId:e.link_id,appearance:e.appearance,onOk:()=>{r.push("chat")}})]})}),_.jsx(cO,{})]})}const dO=[{path:"/",component:fO,name:"registration"}];function hO({name:e,avatar:t,className:n="lc-text-neutral-500"}){return _.jsxs("div",{className:"lc-flex lc-gap-2 lc-items-center",children:[_.jsx("div",{className:"lc-min-w-max",children:_.jsxs("span",{children:[t&&_.jsx("img",{className:"lc-size-10 lc-rounded-full",src:t,"aria-label":e}),!t&&_.jsx("div",{className:"lc-size-10 lc-rounded-full lc-bg-neutral-200"})]})}),_.jsx("div",{className:"lc-flex lc-flex-col",children:_.jsx("span",{className:qt("lc-line-clamp-1",n),children:e})})]})}function pO(e,t){let n,r=0;return function(...s){r++;const o=r;clearTimeout(n),n=setTimeout(()=>{o===r&&e(...s)},t)}}function mO({onNewMessage:e}){const t=uo(),[n,r]=b.useState(""),i=()=>{t==null||t.emit(fn.MessageCreate,{content:n},l=>{r(""),e(l),s("")})},s=l=>{t==null||t.emit(fn.MessageTyping,{content:l})},o=pO(s,300);return _.jsxs("form",{className:"lc-border-t lc-p-2 lc-flex lc-items-center lc-gap-2",onSubmit:l=>{l.preventDefault(),i(),l.currentTarget.reset()},children:[_.jsx("div",{className:"lc-grow lc-relative",children:_.jsx(Zy,{id:"message",className:"lc-grow",noMargin:!0,autoComplete:"off",onChange:l=>{r(l.target.value),o(l.target.value)},placeholder:"Bir mesaj yazın"})}),_.jsx("div",{className:"lc-flex lc-items-center lc-justify-center lc-h-full",children:_.jsx(Gs,{className:"lc-rounded-md",type:"submit",children:"Gönder"})})]})}var Ct=(e=>(e.Customer="customer",e.User="user",e.System="system",e.Activity="activity",e))(Ct||{});function gO({messages:e,isTyping:t}){var c,f,u,d;const n=b.useRef(null),r=b.useRef(null),[i,s]=b.useState(!0),{widget:o}=gr(),l=()=>{var h;(h=n.current)==null||h.scrollIntoView({behavior:"smooth"})},a=()=>{if(r.current){const{scrollTop:h,scrollHeight:v,clientHeight:w}=r.current,S=v-h<=w+10;s(S)}};return b.useEffect(()=>{i&&l()},[e,i]),_.jsxs("section",{onScroll:a,ref:r,className:"lc-flex lc-flex-col lc-gap-2 lc-w-full lc-h-full lc-grow lc-pt-4 lc-px-4 lc-overflow-y-auto",style:{height:"calc(100vh - 122px)"},children:[((f=(c=o==null?void 0:o.appearance)==null?void 0:c.design)==null?void 0:f.greeting_message)&&_.jsx("div",{className:"lc-flex lc-w-full lc-items-center lc-justify-start",children:_.jsx("div",{className:"lc-max-w-[85%] lc-whitespace-pre-wrap lc-border lc-rounded-md lc-px-2 lc-py-1 lc-bg-zink-500 lc-text-white",children:(d=(u=o==null?void 0:o.appearance)==null?void 0:u.design)==null?void 0:d.greeting_message})}),e.filter(h=>!!h.content&&h.content!==`
89
- `).map((h,v)=>_.jsxs("div",{className:qt("lc-flex lc-w-full lc-items-center lc-break-all",{"lc-justify-end":h.sender_type===Ct.Customer,"lc-justify-start":h.sender_type===Ct.User,"lc-justify-center":h.sender_type===Ct.System||h.sender_type===Ct.Activity}),children:[h.sender_type===Ct.System&&_.jsx("div",{className:"lc-whitespace-pre-wrap",children:h.content}),[Ct.Customer,Ct.User].includes(h.sender_type)&&_.jsx("div",{className:qt("lc-max-w-[85%] lc-whitespace-pre-wrap lc-border lc-rounded-md lc-px-2 lc-py-1",{"lc-bg-blue-500 lc-text-white":h.sender_type===Ct.Customer,"lc-bg-zink-500 lc-text-white":h.sender_type===Ct.User}),children:h.content}),h.sender_type===Ct.Activity&&(h.content.split("_").length===3?_.jsxs("div",{className:"lc-whitespace-pre-wrap lc-border lc-rounded-md lc-px-2 lc-py-1 lc-text-xs",children:[h.content.split("_")[2]," odaya katıldı"]}):h.content),Ct.System===h.sender_type&&_.jsx("div",{className:"lc-text-xs lc-text-neutral-400",children:h.created_at.toLocaleString()})]},h.id||v)),t&&_.jsx("div",{className:"lc-flex lc-w-full lc-items-center lc-justify-end",children:_.jsx("div",{className:"lc-h-full lc-flex lc-items-center",children:_.jsx(Ve.MessageTyping,{})})}),!i&&_.jsx("div",{className:"lc-fixed lc-bottom-[7.5rem] lc-right-16",children:_.jsx(Gs,{type:"button",className:"lc-size-10 lc-flex lc-items-center lc-justify-center lc-!p-0",onClick:()=>{var h,v;(v=r.current)==null||v.scrollTo({top:(h=r.current)==null?void 0:h.scrollHeight,behavior:"smooth"})},children:_.jsx(Ve.ArrowDown,{className:"lc-size-5"})})}),_.jsx("div",{ref:n})]})}function yO({children:e}){const{widget:t}=gr();return t?_.jsx("section",{className:"lc-h-full lc-w-full lc-relative",children:e}):null}function vO({children:e}){const t=uo();return b.useEffect(()=>{t&&t.connect()},[]),!t||!t.connected?null:e}function wO(){const{widget:e,setOpen:t}=gr(),n=uo(),r=td(),[i,s]=b.useState(null),[o,l]=b.useState([]),[a,c]=b.useState(!1),[f,u]=b.useState(!1),[d,h]=b.useState([]),v=()=>{n==null||n.emit(fn.ChatClose,{}),t(!1),s(null),l([]),h([]),zl(e.client_id).then(()=>{n==null||n.disconnect(),r.push("registration")})};b.useEffect(()=>{n==null||n.emit(fn.ChatView,{},S=>{if(S===null){t(!1),zl(e.client_id),l([]),h([]),r.push("registration");return}s(S)})},[]);const w=b.useCallback(S=>{l([...o,S])},[o]);return b.useEffect(()=>{if(n)return n.on(Qt.MessageAgentCreate,S=>{const m={content:S.content,created_at:S.created_at,files:S.files,id:S._id,sender_type:S.sender_type,answers:S.answers,reply_id:S.reply_id};if(d.length>0){h(p=>[...p,m]);return}S.is_shortcut?h([m]):w(m)}),n.on(Qt.ChatUserAssignee,S=>{s({...i,agent_name:S.name,agent_avatar:S.avatar,is_uploadable:(i==null?void 0:i.is_uploadable)??!1})}),n.on(Qt.MessageAgentTyping,()=>{c(!0)}),()=>{n.off(Qt.MessageAgentCreate),n.off(Qt.ChatUserAssignee),n.off(Qt.MessageAgentTyping)}},[w]),b.useEffect(()=>{n&&n.emit(fn.MessageList,{},S=>{l(S)})},[]),b.useEffect(()=>{const S=setTimeout(()=>{c(!1)},1e3);return()=>clearTimeout(S)},[a]),b.useEffect(()=>{if(!e||d.length===0)return;const S=(e.writing_timeout||650)*d[0].content.split(" ").length,m=setTimeout(()=>{w(d[0]),h(d.slice(1))},S);return()=>clearTimeout(m)},[d,e]),i?_.jsxs(_.Fragment,{children:[f&&_.jsx("div",{className:"lc-absolute lc-top-0 lc-left-0 lc-backdrop-blur-sm lc-bg-slate-950/20 lc-z-50 lc-h-full lc-w-full lc-rounded-md",children:_.jsx("div",{className:"lc-flex lc-flex-col lc-items-center lc-justify-center lc-h-full lc-mx-5",children:_.jsxs("div",{className:"lc-bg-white lc-p-4 lc-rounded-md",children:[_.jsx("div",{className:"lc-text-lg lc-font-semibold lc-text-neutral-900",children:"Sohbeti kapatmak istediğinize emin misiniz?"}),_.jsxs("div",{className:"lc-flex lc-justify-between lc-mt-4",children:[_.jsx("button",{type:"button",className:"lc-bg-red-500 lc-text-white lc-px-4 lc-py-2 lc-rounded-md",onClick:v,children:"Evet"}),_.jsx("button",{type:"button",className:"lc-bg-neutral-200 lc-text-neutral-900 lc-px-4 lc-py-2 lc-rounded-md",onClick:()=>u(!1),children:"Vazgeç"})]})]})})}),_.jsxs("section",{className:"lc-bg-white lc-h-full lc-w-full lc-rounded-md lc-border lc-flex lc-flex-col",children:[_.jsxs("header",{className:"lc-border-b lc-p-4 lc-bg-zink-600 lc-rounded-t-md lc-flex lc-justify-between lc-items-center",children:[i!=null&&i.agent_name?_.jsx(hO,{name:i.agent_name,avatar:i.agent_avatar,className:"lc-text-neutral-300"}):_.jsx("div",{className:"lc-text-white",children:"Chat with us"}),_.jsx("button",{type:"button",className:"lc-text-white",onClick:()=>u(!0),children:_.jsx(Ve.X,{className:"lc-w-6 lc-h-6 lc-cursor-pointer"})})]}),_.jsx(gO,{messages:o,isTyping:a||d.length>0}),_.jsx(mO,{onNewMessage:S=>{w(S)}})]})]}):null}function xO(){return aO(),null}function SO(){return _.jsxs(vO,{children:[_.jsx(ly,{defaultOpen:!0,children:_.jsx(yO,{children:_.jsx(wO,{})})}),_.jsx(xO,{})]})}const bO=[{path:"/chat",component:SO,name:"chat"}],nv=[...bO],rv=[...dO],EO=[...nv,...rv];function _O(){return _.jsx(_S,{future:{v7_startTransition:!0},children:_.jsxs(CS,{children:[nv.map((e,t)=>_.jsx(Oc,{path:e.path,element:_.jsx(e.component,{})},t)),rv.map((e,t)=>_.jsx(Oc,{path:e.path,element:_.jsx(e.component,{})},t))]})})}function kO({link_id:e,defaultValues:t}){const{setWidget:n,widget:r,setDefaultValues:i}=gr(),{data:s,isLoading:o}=Rx(e);return b.useEffect(()=>{Array.isArray(s)&&Px(s[0])&&(n(s[0]),i(t))},[s]),o||!r?null:_.jsx(GT,{children:_.jsx(Gb,{children:_.jsx(_O,{})})})}const CO=new cx;function TO({container:e,link_id:t,defaultValues:n}){mg(e).render(_.jsxs(mx,{client:CO,children:[_.jsx(kO,{link_id:t,defaultValues:n}),_.jsx(UT,{richColors:!0,style:{zIndex:999999},position:"bottom-right"})]}))}window.widget=TO});export default OO();
88
+ */var Ae=typeof Symbol=="function"&&Symbol.for,yd=Ae?Symbol.for("react.element"):60103,gd=Ae?Symbol.for("react.portal"):60106,wa=Ae?Symbol.for("react.fragment"):60107,xa=Ae?Symbol.for("react.strict_mode"):60108,Sa=Ae?Symbol.for("react.profiler"):60114,ba=Ae?Symbol.for("react.provider"):60109,Ea=Ae?Symbol.for("react.context"):60110,vd=Ae?Symbol.for("react.async_mode"):60111,_a=Ae?Symbol.for("react.concurrent_mode"):60111,ka=Ae?Symbol.for("react.forward_ref"):60112,Ca=Ae?Symbol.for("react.suspense"):60113,XC=Ae?Symbol.for("react.suspense_list"):60120,Ta=Ae?Symbol.for("react.memo"):60115,Oa=Ae?Symbol.for("react.lazy"):60116,ZC=Ae?Symbol.for("react.block"):60121,JC=Ae?Symbol.for("react.fundamental"):60117,eT=Ae?Symbol.for("react.responder"):60118,tT=Ae?Symbol.for("react.scope"):60119;function _t(e){if(typeof e=="object"&&e!==null){var t=e.$$typeof;switch(t){case yd:switch(e=e.type,e){case vd:case _a:case wa:case Sa:case xa:case Ca:return e;default:switch(e=e&&e.$$typeof,e){case Ea:case ka:case Oa:case Ta:case ba:return e;default:return t}}case gd:return t}}}function qg(e){return _t(e)===_a}ie.AsyncMode=vd;ie.ConcurrentMode=_a;ie.ContextConsumer=Ea;ie.ContextProvider=ba;ie.Element=yd;ie.ForwardRef=ka;ie.Fragment=wa;ie.Lazy=Oa;ie.Memo=Ta;ie.Portal=gd;ie.Profiler=Sa;ie.StrictMode=xa;ie.Suspense=Ca;ie.isAsyncMode=function(e){return qg(e)||_t(e)===vd};ie.isConcurrentMode=qg;ie.isContextConsumer=function(e){return _t(e)===Ea};ie.isContextProvider=function(e){return _t(e)===ba};ie.isElement=function(e){return typeof e=="object"&&e!==null&&e.$$typeof===yd};ie.isForwardRef=function(e){return _t(e)===ka};ie.isFragment=function(e){return _t(e)===wa};ie.isLazy=function(e){return _t(e)===Oa};ie.isMemo=function(e){return _t(e)===Ta};ie.isPortal=function(e){return _t(e)===gd};ie.isProfiler=function(e){return _t(e)===Sa};ie.isStrictMode=function(e){return _t(e)===xa};ie.isSuspense=function(e){return _t(e)===Ca};ie.isValidElementType=function(e){return typeof e=="string"||typeof e=="function"||e===wa||e===_a||e===Sa||e===xa||e===Ca||e===XC||typeof e=="object"&&e!==null&&(e.$$typeof===Oa||e.$$typeof===Ta||e.$$typeof===ba||e.$$typeof===Ea||e.$$typeof===ka||e.$$typeof===JC||e.$$typeof===eT||e.$$typeof===tT||e.$$typeof===ZC)};ie.typeOf=_t;Qg.exports=ie;var nT=Qg.exports,Kg=nT,rT={$$typeof:!0,render:!0,defaultProps:!0,displayName:!0,propTypes:!0},iT={$$typeof:!0,compare:!0,defaultProps:!0,displayName:!0,propTypes:!0,type:!0},Yg={};Yg[Kg.ForwardRef]=rT;Yg[Kg.Memo]=iT;function Oe(){return Oe=Object.assign||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},Oe.apply(this,arguments)}function Gg(e,t){if(e==null)return{};var n={},r=Object.keys(e),i,s;for(s=0;s<r.length;s++)i=r[s],!(t.indexOf(i)>=0)&&(n[i]=e[i]);return n}var Ra=b.createContext(void 0);Ra.displayName="FormikContext";Ra.Provider;Ra.Consumer;function sT(){var e=b.useContext(Ra);return e}var Mt=function(t){return typeof t=="function"},Na=function(t){return t!==null&&typeof t=="object"},oT=function(t){return String(Math.floor(Number(t)))===t},vu=function(t){return Object.prototype.toString.call(t)==="[object String]"},wu=function(t){return Na(t)&&Mt(t.then)};function ht(e,t,n,r){r===void 0&&(r=0);for(var i=Wg(t);e&&r<i.length;)e=e[i[r++]];return r!==i.length&&!e||e===void 0?n:e}function Mr(e,t,n){for(var r=Dp(e),i=r,s=0,o=Wg(t);s<o.length-1;s++){var l=o[s],a=ht(e,o.slice(0,s+1));if(a&&(Na(a)||Array.isArray(a)))i=i[l]=Dp(a);else{var c=o[s+1];i=i[l]=oT(c)&&Number(c)>=0?[]:{}}}return(s===0?e:i)[o[s]]===n?e:(n===void 0?delete i[o[s]]:i[o[s]]=n,s===0&&n===void 0&&delete r[o[s]],r)}function Xg(e,t,n,r){n===void 0&&(n=new WeakMap),r===void 0&&(r={});for(var i=0,s=Object.keys(e);i<s.length;i++){var o=s[i],l=e[o];Na(l)?n.get(l)||(n.set(l,!0),r[o]=Array.isArray(l)?[]:{},Xg(l,t,n,r[o])):r[o]=t}return r}function lT(e,t){switch(t.type){case"SET_VALUES":return Oe({},e,{values:t.payload});case"SET_TOUCHED":return Oe({},e,{touched:t.payload});case"SET_ERRORS":return Er(e.errors,t.payload)?e:Oe({},e,{errors:t.payload});case"SET_STATUS":return Oe({},e,{status:t.payload});case"SET_ISSUBMITTING":return Oe({},e,{isSubmitting:t.payload});case"SET_ISVALIDATING":return Oe({},e,{isValidating:t.payload});case"SET_FIELD_VALUE":return Oe({},e,{values:Mr(e.values,t.payload.field,t.payload.value)});case"SET_FIELD_TOUCHED":return Oe({},e,{touched:Mr(e.touched,t.payload.field,t.payload.value)});case"SET_FIELD_ERROR":return Oe({},e,{errors:Mr(e.errors,t.payload.field,t.payload.value)});case"RESET_FORM":return Oe({},e,t.payload);case"SET_FORMIK_STATE":return t.payload(e);case"SUBMIT_ATTEMPT":return Oe({},e,{touched:Xg(e.values,!0),isSubmitting:!0,submitCount:e.submitCount+1});case"SUBMIT_FAILURE":return Oe({},e,{isSubmitting:!1});case"SUBMIT_SUCCESS":return Oe({},e,{isSubmitting:!1});default:return e}}var xr={},Ho={};function aT(e){var t=e.validateOnChange,n=t===void 0?!0:t,r=e.validateOnBlur,i=r===void 0?!0:r,s=e.validateOnMount,o=s===void 0?!1:s,l=e.isInitialValid,a=e.enableReinitialize,c=a===void 0?!1:a,f=e.onSubmit,u=Gg(e,["validateOnChange","validateOnBlur","validateOnMount","isInitialValid","enableReinitialize","onSubmit"]),d=Oe({validateOnChange:n,validateOnBlur:i,validateOnMount:o,onSubmit:f},u),h=b.useRef(d.initialValues),v=b.useRef(d.initialErrors||xr),w=b.useRef(d.initialTouched||Ho),S=b.useRef(d.initialStatus),m=b.useRef(!1),p=b.useRef({});b.useEffect(function(){return m.current=!0,function(){m.current=!1}},[]);var g=b.useState(0),x=g[1],C=b.useRef({values:Vo(d.initialValues),errors:Vo(d.initialErrors)||xr,touched:Vo(d.initialTouched)||Ho,status:Vo(d.initialStatus),isSubmitting:!1,isValidating:!1,submitCount:0}),T=C.current,k=b.useCallback(function(E){var A=C.current;C.current=lT(A,E),A!==C.current&&x(function($){return $+1})},[]),R=b.useCallback(function(E,A){return new Promise(function($,z){var W=d.validate(E,A);W==null?$(xr):wu(W)?W.then(function(te){$(te||xr)},function(te){z(te)}):$(W)})},[d.validate]),I=b.useCallback(function(E,A){var $=d.validationSchema,z=Mt($)?$(A):$,W=A&&z.validateAt?z.validateAt(A,E):cT(E,z);return new Promise(function(te,we){W.then(function(){te(xr)},function(ft){ft.name==="ValidationError"?te(uT(ft)):we(ft)})})},[d.validationSchema]),L=b.useCallback(function(E,A){return new Promise(function($){return $(p.current[E].validate(A))})},[]),B=b.useCallback(function(E){var A=Object.keys(p.current).filter(function(z){return Mt(p.current[z].validate)}),$=A.length>0?A.map(function(z){return L(z,ht(E,z))}):[Promise.resolve("DO_NOT_DELETE_YOU_WILL_BE_FIRED")];return Promise.all($).then(function(z){return z.reduce(function(W,te,we){return te==="DO_NOT_DELETE_YOU_WILL_BE_FIRED"||te&&(W=Mr(W,A[we],te)),W},{})})},[L]),se=b.useCallback(function(E){return Promise.all([B(E),d.validationSchema?I(E):{},d.validate?R(E):{}]).then(function(A){var $=A[0],z=A[1],W=A[2],te=zc.all([$,z,W],{arrayMerge:fT});return te})},[d.validate,d.validationSchema,B,R,I]),oe=Ct(function(E){return E===void 0&&(E=T.values),k({type:"SET_ISVALIDATING",payload:!0}),se(E).then(function(A){return m.current&&(k({type:"SET_ISVALIDATING",payload:!1}),k({type:"SET_ERRORS",payload:A})),A})});b.useEffect(function(){o&&m.current===!0&&Er(h.current,d.initialValues)&&oe(h.current)},[o,oe]);var He=b.useCallback(function(E){var A=E&&E.values?E.values:h.current,$=E&&E.errors?E.errors:v.current?v.current:d.initialErrors||{},z=E&&E.touched?E.touched:w.current?w.current:d.initialTouched||{},W=E&&E.status?E.status:S.current?S.current:d.initialStatus;h.current=A,v.current=$,w.current=z,S.current=W;var te=function(){k({type:"RESET_FORM",payload:{isSubmitting:!!E&&!!E.isSubmitting,errors:$,touched:z,status:W,values:A,isValidating:!!E&&!!E.isValidating,submitCount:E&&E.submitCount&&typeof E.submitCount=="number"?E.submitCount:0}})};if(d.onReset){var we=d.onReset(T.values,po);wu(we)?we.then(te):te()}else te()},[d.initialErrors,d.initialStatus,d.initialTouched,d.onReset]);b.useEffect(function(){m.current===!0&&!Er(h.current,d.initialValues)&&c&&(h.current=d.initialValues,He(),o&&oe(h.current))},[c,d.initialValues,He,o,oe]),b.useEffect(function(){c&&m.current===!0&&!Er(v.current,d.initialErrors)&&(v.current=d.initialErrors||xr,k({type:"SET_ERRORS",payload:d.initialErrors||xr}))},[c,d.initialErrors]),b.useEffect(function(){c&&m.current===!0&&!Er(w.current,d.initialTouched)&&(w.current=d.initialTouched||Ho,k({type:"SET_TOUCHED",payload:d.initialTouched||Ho}))},[c,d.initialTouched]),b.useEffect(function(){c&&m.current===!0&&!Er(S.current,d.initialStatus)&&(S.current=d.initialStatus,k({type:"SET_STATUS",payload:d.initialStatus}))},[c,d.initialStatus,d.initialTouched]);var We=Ct(function(E){if(p.current[E]&&Mt(p.current[E].validate)){var A=ht(T.values,E),$=p.current[E].validate(A);return wu($)?(k({type:"SET_ISVALIDATING",payload:!0}),$.then(function(z){return z}).then(function(z){k({type:"SET_FIELD_ERROR",payload:{field:E,value:z}}),k({type:"SET_ISVALIDATING",payload:!1})})):(k({type:"SET_FIELD_ERROR",payload:{field:E,value:$}}),Promise.resolve($))}else if(d.validationSchema)return k({type:"SET_ISVALIDATING",payload:!0}),I(T.values,E).then(function(z){return z}).then(function(z){k({type:"SET_FIELD_ERROR",payload:{field:E,value:ht(z,E)}}),k({type:"SET_ISVALIDATING",payload:!1})});return Promise.resolve()}),K=b.useCallback(function(E,A){var $=A.validate;p.current[E]={validate:$}},[]),Qe=b.useCallback(function(E){delete p.current[E]},[]),P=Ct(function(E,A){k({type:"SET_TOUCHED",payload:E});var $=A===void 0?i:A;return $?oe(T.values):Promise.resolve()}),D=b.useCallback(function(E){k({type:"SET_ERRORS",payload:E})},[]),H=Ct(function(E,A){var $=Mt(E)?E(T.values):E;k({type:"SET_VALUES",payload:$});var z=A===void 0?n:A;return z?oe($):Promise.resolve()}),M=b.useCallback(function(E,A){k({type:"SET_FIELD_ERROR",payload:{field:E,value:A}})},[]),V=Ct(function(E,A,$){k({type:"SET_FIELD_VALUE",payload:{field:E,value:A}});var z=$===void 0?n:$;return z?oe(Mr(T.values,E,A)):Promise.resolve()}),ee=b.useCallback(function(E,A){var $=A,z=E,W;if(!vu(E)){E.persist&&E.persist();var te=E.target?E.target:E.currentTarget,we=te.type,ft=te.name,Xt=te.id,ri=te.value,Fn=te.checked,xd=te.outerHTML,go=te.options,vo=te.multiple;$=A||ft||Xt,z=/number|range/.test(we)?(W=parseFloat(ri),isNaN(W)?"":W):/checkbox/.test(we)?hT(ht(T.values,$),Fn,ri):go&&vo?dT(go):ri}$&&V($,z)},[V,T.values]),de=Ct(function(E){if(vu(E))return function(A){return ee(A,E)};ee(E)}),Ce=Ct(function(E,A,$){A===void 0&&(A=!0),k({type:"SET_FIELD_TOUCHED",payload:{field:E,value:A}});var z=$===void 0?i:$;return z?oe(T.values):Promise.resolve()}),Z=b.useCallback(function(E,A){E.persist&&E.persist();var $=E.target,z=$.name,W=$.id,te=$.outerHTML,we=A||z||W;Ce(we,!0)},[Ce]),Je=Ct(function(E){if(vu(E))return function(A){return Z(A,E)};Z(E)}),mn=b.useCallback(function(E){Mt(E)?k({type:"SET_FORMIK_STATE",payload:E}):k({type:"SET_FORMIK_STATE",payload:function(){return E}})},[]),An=b.useCallback(function(E){k({type:"SET_STATUS",payload:E})},[]),jn=b.useCallback(function(E){k({type:"SET_ISSUBMITTING",payload:E})},[]),ns=Ct(function(){return k({type:"SUBMIT_ATTEMPT"}),oe().then(function(E){var A=E instanceof Error,$=!A&&Object.keys(E).length===0;if($){var z;try{if(z=rs(),z===void 0)return}catch(W){throw W}return Promise.resolve(z).then(function(W){return m.current&&k({type:"SUBMIT_SUCCESS"}),W}).catch(function(W){if(m.current)throw k({type:"SUBMIT_FAILURE"}),W})}else if(m.current&&(k({type:"SUBMIT_FAILURE"}),A))throw E})}),ho=Ct(function(E){E&&E.preventDefault&&Mt(E.preventDefault)&&E.preventDefault(),E&&E.stopPropagation&&Mt(E.stopPropagation)&&E.stopPropagation(),ns().catch(function(A){console.warn("Warning: An unhandled error was caught from submitForm()",A)})}),po={resetForm:He,validateForm:oe,validateField:We,setErrors:D,setFieldError:M,setFieldTouched:Ce,setFieldValue:V,setStatus:An,setSubmitting:jn,setTouched:P,setValues:H,setFormikState:mn,submitForm:ns},rs=Ct(function(){return f(T.values,po)}),Pa=Ct(function(E){E&&E.preventDefault&&Mt(E.preventDefault)&&E.preventDefault(),E&&E.stopPropagation&&Mt(E.stopPropagation)&&E.stopPropagation(),He()}),mo=b.useCallback(function(E){return{value:ht(T.values,E),error:ht(T.errors,E),touched:!!ht(T.touched,E),initialValue:ht(h.current,E),initialTouched:!!ht(w.current,E),initialError:ht(v.current,E)}},[T.errors,T.touched,T.values]),vr=b.useCallback(function(E){return{setValue:function($,z){return V(E,$,z)},setTouched:function($,z){return Ce(E,$,z)},setError:function($){return M(E,$)}}},[V,Ce,M]),yo=b.useCallback(function(E){var A=Na(E),$=A?E.name:E,z=ht(T.values,$),W={name:$,value:z,onChange:de,onBlur:Je};if(A){var te=E.type,we=E.value,ft=E.as,Xt=E.multiple;te==="checkbox"?we===void 0?W.checked=!!z:(W.checked=!!(Array.isArray(z)&&~z.indexOf(we)),W.value=we):te==="radio"?(W.checked=z===we,W.value=we):ft==="select"&&Xt&&(W.value=W.value||[],W.multiple=!0)}return W},[Je,de,T.values]),ct=b.useMemo(function(){return!Er(h.current,T.values)},[h.current,T.values]),Aa=b.useMemo(function(){return typeof l<"u"?ct?T.errors&&Object.keys(T.errors).length===0:l!==!1&&Mt(l)?l(d):l:T.errors&&Object.keys(T.errors).length===0},[l,ct,T.errors,d]),ja=Oe({},T,{initialValues:h.current,initialErrors:v.current,initialTouched:w.current,initialStatus:S.current,handleBlur:Je,handleChange:de,handleReset:Pa,handleSubmit:ho,resetForm:He,setErrors:D,setFormikState:mn,setFieldTouched:Ce,setFieldValue:V,setFieldError:M,setStatus:An,setSubmitting:jn,setTouched:P,setValues:H,submitForm:ns,validateForm:oe,validateField:We,isValid:Aa,dirty:ct,unregisterField:Qe,registerField:K,getFieldProps:yo,getFieldMeta:mo,getFieldHelpers:vr,validateOnBlur:i,validateOnChange:n,validateOnMount:o});return ja}function uT(e){var t={};if(e.inner){if(e.inner.length===0)return Mr(t,e.path,e.message);for(var i=e.inner,n=Array.isArray(i),r=0,i=n?i:i[Symbol.iterator]();;){var s;if(n){if(r>=i.length)break;s=i[r++]}else{if(r=i.next(),r.done)break;s=r.value}var o=s;ht(t,o.path)||(t=Mr(t,o.path,o.message))}}return t}function cT(e,t,n,r){n===void 0&&(n=!1);var i=Qc(e);return t[n?"validateSync":"validate"](i,{abortEarly:!1,context:i})}function Qc(e){var t=Array.isArray(e)?[]:{};for(var n in e)if(Object.prototype.hasOwnProperty.call(e,n)){var r=String(n);Array.isArray(e[r])===!0?t[r]=e[r].map(function(i){return Array.isArray(i)===!0||hp(i)?Qc(i):i!==""?i:void 0}):hp(e[r])?t[r]=Qc(e[r]):t[r]=e[r]!==""?e[r]:void 0}return t}function fT(e,t,n){var r=e.slice();return t.forEach(function(s,o){if(typeof r[o]>"u"){var l=n.clone!==!1,a=l&&n.isMergeableObject(s);r[o]=a?zc(Array.isArray(s)?[]:{},s,n):s}else n.isMergeableObject(s)?r[o]=zc(e[o],s,n):e.indexOf(s)===-1&&r.push(s)}),r}function dT(e){return Array.from(e).filter(function(t){return t.selected}).map(function(t){return t.value})}function hT(e,t,n){if(typeof e=="boolean")return!!t;var r=[],i=!1,s=-1;if(Array.isArray(e))r=e,s=e.indexOf(n),i=s>=0;else if(!n||n=="true"||n=="false")return!!t;return t&&n&&!i?r.concat(n):i?r.slice(0,s).concat(r.slice(s+1)):r}var pT=typeof window<"u"&&typeof window.document<"u"&&typeof window.document.createElement<"u"?b.useLayoutEffect:b.useEffect;function Ct(e){var t=b.useRef(e);return pT(function(){t.current=e}),b.useCallback(function(){for(var n=arguments.length,r=new Array(n),i=0;i<n;i++)r[i]=arguments[i];return t.current.apply(void 0,r)},[])}var mT=b.forwardRef(function(e,t){var n=e.action,r=Gg(e,["action"]),i=n??"#",s=sT(),o=s.handleReset,l=s.handleSubmit;return b.createElement("form",Oe({onSubmit:l,ref:t,onReset:o,action:i},r))});mT.displayName="Form";const yT=({init:e,schema:t,action:n})=>aT({initialValues:e,validationSchema:t,validateOnBlur:!1,enableReinitialize:!0,validateOnChange:!1,validateOnMount:!1,onSubmit:r=>{n(r)}});function gT(e){if(typeof document>"u")return;let t=document.head||document.getElementsByTagName("head")[0],n=document.createElement("style");n.type="text/css",t.appendChild(n),n.styleSheet?n.styleSheet.cssText=e:n.appendChild(document.createTextNode(e))}const vT=e=>{switch(e){case"success":return ST;case"info":return ET;case"warning":return bT;case"error":return _T;default:return null}},wT=Array(12).fill(0),xT=({visible:e,className:t})=>N.createElement("div",{className:["sonner-loading-wrapper",t].filter(Boolean).join(" "),"data-visible":e},N.createElement("div",{className:"sonner-spinner"},wT.map((n,r)=>N.createElement("div",{className:"sonner-loading-bar",key:`spinner-bar-${r}`})))),ST=N.createElement("svg",{xmlns:"http://www.w3.org/2000/svg",viewBox:"0 0 20 20",fill:"currentColor",height:"20",width:"20"},N.createElement("path",{fillRule:"evenodd",d:"M10 18a8 8 0 100-16 8 8 0 000 16zm3.857-9.809a.75.75 0 00-1.214-.882l-3.483 4.79-1.88-1.88a.75.75 0 10-1.06 1.061l2.5 2.5a.75.75 0 001.137-.089l4-5.5z",clipRule:"evenodd"})),bT=N.createElement("svg",{xmlns:"http://www.w3.org/2000/svg",viewBox:"0 0 24 24",fill:"currentColor",height:"20",width:"20"},N.createElement("path",{fillRule:"evenodd",d:"M9.401 3.003c1.155-2 4.043-2 5.197 0l7.355 12.748c1.154 2-.29 4.5-2.599 4.5H4.645c-2.309 0-3.752-2.5-2.598-4.5L9.4 3.003zM12 8.25a.75.75 0 01.75.75v3.75a.75.75 0 01-1.5 0V9a.75.75 0 01.75-.75zm0 8.25a.75.75 0 100-1.5.75.75 0 000 1.5z",clipRule:"evenodd"})),ET=N.createElement("svg",{xmlns:"http://www.w3.org/2000/svg",viewBox:"0 0 20 20",fill:"currentColor",height:"20",width:"20"},N.createElement("path",{fillRule:"evenodd",d:"M18 10a8 8 0 11-16 0 8 8 0 0116 0zm-7-4a1 1 0 11-2 0 1 1 0 012 0zM9 9a.75.75 0 000 1.5h.253a.25.25 0 01.244.304l-.459 2.066A1.75 1.75 0 0010.747 15H11a.75.75 0 000-1.5h-.253a.25.25 0 01-.244-.304l.459-2.066A1.75 1.75 0 009.253 9H9z",clipRule:"evenodd"})),_T=N.createElement("svg",{xmlns:"http://www.w3.org/2000/svg",viewBox:"0 0 20 20",fill:"currentColor",height:"20",width:"20"},N.createElement("path",{fillRule:"evenodd",d:"M18 10a8 8 0 11-16 0 8 8 0 0116 0zm-8-5a.75.75 0 01.75.75v4.5a.75.75 0 01-1.5 0v-4.5A.75.75 0 0110 5zm0 10a1 1 0 100-2 1 1 0 000 2z",clipRule:"evenodd"})),kT=N.createElement("svg",{xmlns:"http://www.w3.org/2000/svg",width:"12",height:"12",viewBox:"0 0 24 24",fill:"none",stroke:"currentColor",strokeWidth:"1.5",strokeLinecap:"round",strokeLinejoin:"round"},N.createElement("line",{x1:"18",y1:"6",x2:"6",y2:"18"}),N.createElement("line",{x1:"6",y1:"6",x2:"18",y2:"18"})),CT=()=>{const[e,t]=N.useState(document.hidden);return N.useEffect(()=>{const n=()=>{t(document.hidden)};return document.addEventListener("visibilitychange",n),()=>window.removeEventListener("visibilitychange",n)},[]),e};let qc=1;class TT{constructor(){this.subscribe=t=>(this.subscribers.push(t),()=>{const n=this.subscribers.indexOf(t);this.subscribers.splice(n,1)}),this.publish=t=>{this.subscribers.forEach(n=>n(t))},this.addToast=t=>{this.publish(t),this.toasts=[...this.toasts,t]},this.create=t=>{var n;const{message:r,...i}=t,s=typeof(t==null?void 0:t.id)=="number"||((n=t.id)==null?void 0:n.length)>0?t.id:qc++,o=this.toasts.find(a=>a.id===s),l=t.dismissible===void 0?!0:t.dismissible;return this.dismissedToasts.has(s)&&this.dismissedToasts.delete(s),o?this.toasts=this.toasts.map(a=>a.id===s?(this.publish({...a,...t,id:s,title:r}),{...a,...t,id:s,dismissible:l,title:r}):a):this.addToast({title:r,...i,dismissible:l,id:s}),s},this.dismiss=t=>(this.dismissedToasts.add(t),t||this.toasts.forEach(n=>{this.subscribers.forEach(r=>r({id:n.id,dismiss:!0}))}),requestAnimationFrame(()=>this.subscribers.forEach(n=>n({id:t,dismiss:!0}))),t),this.message=(t,n)=>this.create({...n,message:t}),this.error=(t,n)=>this.create({...n,message:t,type:"error"}),this.success=(t,n)=>this.create({...n,type:"success",message:t}),this.info=(t,n)=>this.create({...n,type:"info",message:t}),this.warning=(t,n)=>this.create({...n,type:"warning",message:t}),this.loading=(t,n)=>this.create({...n,type:"loading",message:t}),this.promise=(t,n)=>{if(!n)return;let r;n.loading!==void 0&&(r=this.create({...n,promise:t,type:"loading",message:n.loading,description:typeof n.description!="function"?n.description:void 0}));const i=Promise.resolve(t instanceof Function?t():t);let s=r!==void 0,o;const l=i.then(async c=>{if(o=["resolve",c],N.isValidElement(c))s=!1,this.create({id:r,type:"default",message:c});else if(RT(c)&&!c.ok){s=!1;const u=typeof n.error=="function"?await n.error(`HTTP error! status: ${c.status}`):n.error,d=typeof n.description=="function"?await n.description(`HTTP error! status: ${c.status}`):n.description,h=typeof u=="object"?u:{message:u};this.create({id:r,type:"error",description:d,...h})}else if(c instanceof Error){s=!1;const u=typeof n.error=="function"?await n.error(c):n.error,d=typeof n.description=="function"?await n.description(c):n.description,h=typeof u=="object"?u:{message:u};this.create({id:r,type:"error",description:d,...h})}else if(n.success!==void 0){s=!1;const u=typeof n.success=="function"?await n.success(c):n.success,d=typeof n.description=="function"?await n.description(c):n.description,h=typeof u=="object"?u:{message:u};this.create({id:r,type:"success",description:d,...h})}}).catch(async c=>{if(o=["reject",c],n.error!==void 0){s=!1;const f=typeof n.error=="function"?await n.error(c):n.error,u=typeof n.description=="function"?await n.description(c):n.description,d=typeof f=="object"?f:{message:f};this.create({id:r,type:"error",description:u,...d})}}).finally(()=>{s&&(this.dismiss(r),r=void 0),n.finally==null||n.finally.call(n)}),a=()=>new Promise((c,f)=>l.then(()=>o[0]==="reject"?f(o[1]):c(o[1])).catch(f));return typeof r!="string"&&typeof r!="number"?{unwrap:a}:Object.assign(r,{unwrap:a})},this.custom=(t,n)=>{const r=(n==null?void 0:n.id)||qc++;return this.create({jsx:t(r),id:r,...n}),r},this.getActiveToasts=()=>this.toasts.filter(t=>!this.dismissedToasts.has(t.id)),this.subscribers=[],this.toasts=[],this.dismissedToasts=new Set}}const rt=new TT,OT=(e,t)=>{const n=(t==null?void 0:t.id)||qc++;return rt.addToast({title:e,...t,id:n}),n},RT=e=>e&&typeof e=="object"&&"ok"in e&&typeof e.ok=="boolean"&&"status"in e&&typeof e.status=="number",NT=OT,PT=()=>rt.toasts,AT=()=>rt.getActiveToasts(),zp=Object.assign(NT,{success:rt.success,info:rt.info,warning:rt.warning,error:rt.error,custom:rt.custom,message:rt.message,promise:rt.promise,dismiss:rt.dismiss,loading:rt.loading},{getHistory:PT,getToasts:AT});gT("[data-sonner-toaster][dir=ltr],html[dir=ltr]{--toast-icon-margin-start:-3px;--toast-icon-margin-end:4px;--toast-svg-margin-start:-1px;--toast-svg-margin-end:0px;--toast-button-margin-start:auto;--toast-button-margin-end:0;--toast-close-button-start:0;--toast-close-button-end:unset;--toast-close-button-transform:translate(-35%, -35%)}[data-sonner-toaster][dir=rtl],html[dir=rtl]{--toast-icon-margin-start:4px;--toast-icon-margin-end:-3px;--toast-svg-margin-start:0px;--toast-svg-margin-end:-1px;--toast-button-margin-start:0;--toast-button-margin-end:auto;--toast-close-button-start:unset;--toast-close-button-end:0;--toast-close-button-transform:translate(35%, -35%)}[data-sonner-toaster]{position:fixed;width:var(--width);font-family:ui-sans-serif,system-ui,-apple-system,BlinkMacSystemFont,Segoe UI,Roboto,Helvetica Neue,Arial,Noto Sans,sans-serif,Apple Color Emoji,Segoe UI Emoji,Segoe UI Symbol,Noto Color Emoji;--gray1:hsl(0, 0%, 99%);--gray2:hsl(0, 0%, 97.3%);--gray3:hsl(0, 0%, 95.1%);--gray4:hsl(0, 0%, 93%);--gray5:hsl(0, 0%, 90.9%);--gray6:hsl(0, 0%, 88.7%);--gray7:hsl(0, 0%, 85.8%);--gray8:hsl(0, 0%, 78%);--gray9:hsl(0, 0%, 56.1%);--gray10:hsl(0, 0%, 52.3%);--gray11:hsl(0, 0%, 43.5%);--gray12:hsl(0, 0%, 9%);--border-radius:8px;box-sizing:border-box;padding:0;margin:0;list-style:none;outline:0;z-index:999999999;transition:transform .4s ease}[data-sonner-toaster][data-lifted=true]{transform:translateY(-8px)}@media (hover:none) and (pointer:coarse){[data-sonner-toaster][data-lifted=true]{transform:none}}[data-sonner-toaster][data-x-position=right]{right:var(--offset-right)}[data-sonner-toaster][data-x-position=left]{left:var(--offset-left)}[data-sonner-toaster][data-x-position=center]{left:50%;transform:translateX(-50%)}[data-sonner-toaster][data-y-position=top]{top:var(--offset-top)}[data-sonner-toaster][data-y-position=bottom]{bottom:var(--offset-bottom)}[data-sonner-toast]{--y:translateY(100%);--lift-amount:calc(var(--lift) * var(--gap));z-index:var(--z-index);position:absolute;opacity:0;transform:var(--y);touch-action:none;transition:transform .4s,opacity .4s,height .4s,box-shadow .2s;box-sizing:border-box;outline:0;overflow-wrap:anywhere}[data-sonner-toast][data-styled=true]{padding:16px;background:var(--normal-bg);border:1px solid var(--normal-border);color:var(--normal-text);border-radius:var(--border-radius);box-shadow:0 4px 12px rgba(0,0,0,.1);width:var(--width);font-size:13px;display:flex;align-items:center;gap:6px}[data-sonner-toast]:focus-visible{box-shadow:0 4px 12px rgba(0,0,0,.1),0 0 0 2px rgba(0,0,0,.2)}[data-sonner-toast][data-y-position=top]{top:0;--y:translateY(-100%);--lift:1;--lift-amount:calc(1 * var(--gap))}[data-sonner-toast][data-y-position=bottom]{bottom:0;--y:translateY(100%);--lift:-1;--lift-amount:calc(var(--lift) * var(--gap))}[data-sonner-toast][data-styled=true] [data-description]{font-weight:400;line-height:1.4;color:#3f3f3f}[data-sonner-toaster][data-sonner-theme=dark] [data-description]{color:#e8e8e8}[data-sonner-toast][data-styled=true] [data-title]{font-weight:500;line-height:1.5;color:inherit}[data-sonner-toast][data-styled=true] [data-icon]{display:flex;height:16px;width:16px;position:relative;justify-content:flex-start;align-items:center;flex-shrink:0;margin-left:var(--toast-icon-margin-start);margin-right:var(--toast-icon-margin-end)}[data-sonner-toast][data-promise=true] [data-icon]>svg{opacity:0;transform:scale(.8);transform-origin:center;animation:sonner-fade-in .3s ease forwards}[data-sonner-toast][data-styled=true] [data-icon]>*{flex-shrink:0}[data-sonner-toast][data-styled=true] [data-icon] svg{margin-left:var(--toast-svg-margin-start);margin-right:var(--toast-svg-margin-end)}[data-sonner-toast][data-styled=true] [data-content]{display:flex;flex-direction:column;gap:2px}[data-sonner-toast][data-styled=true] [data-button]{border-radius:4px;padding-left:8px;padding-right:8px;height:24px;font-size:12px;color:var(--normal-bg);background:var(--normal-text);margin-left:var(--toast-button-margin-start);margin-right:var(--toast-button-margin-end);border:none;font-weight:500;cursor:pointer;outline:0;display:flex;align-items:center;flex-shrink:0;transition:opacity .4s,box-shadow .2s}[data-sonner-toast][data-styled=true] [data-button]:focus-visible{box-shadow:0 0 0 2px rgba(0,0,0,.4)}[data-sonner-toast][data-styled=true] [data-button]:first-of-type{margin-left:var(--toast-button-margin-start);margin-right:var(--toast-button-margin-end)}[data-sonner-toast][data-styled=true] [data-cancel]{color:var(--normal-text);background:rgba(0,0,0,.08)}[data-sonner-toaster][data-sonner-theme=dark] [data-sonner-toast][data-styled=true] [data-cancel]{background:rgba(255,255,255,.3)}[data-sonner-toast][data-styled=true] [data-close-button]{position:absolute;left:var(--toast-close-button-start);right:var(--toast-close-button-end);top:0;height:20px;width:20px;display:flex;justify-content:center;align-items:center;padding:0;color:var(--gray12);background:var(--normal-bg);border:1px solid var(--gray4);transform:var(--toast-close-button-transform);border-radius:50%;cursor:pointer;z-index:1;transition:opacity .1s,background .2s,border-color .2s}[data-sonner-toast][data-styled=true] [data-close-button]:focus-visible{box-shadow:0 4px 12px rgba(0,0,0,.1),0 0 0 2px rgba(0,0,0,.2)}[data-sonner-toast][data-styled=true] [data-disabled=true]{cursor:not-allowed}[data-sonner-toast][data-styled=true]:hover [data-close-button]:hover{background:var(--gray2);border-color:var(--gray5)}[data-sonner-toast][data-swiping=true]::before{content:'';position:absolute;left:-100%;right:-100%;height:100%;z-index:-1}[data-sonner-toast][data-y-position=top][data-swiping=true]::before{bottom:50%;transform:scaleY(3) translateY(50%)}[data-sonner-toast][data-y-position=bottom][data-swiping=true]::before{top:50%;transform:scaleY(3) translateY(-50%)}[data-sonner-toast][data-swiping=false][data-removed=true]::before{content:'';position:absolute;inset:0;transform:scaleY(2)}[data-sonner-toast]::after{content:'';position:absolute;left:0;height:calc(var(--gap) + 1px);bottom:100%;width:100%}[data-sonner-toast][data-mounted=true]{--y:translateY(0);opacity:1}[data-sonner-toast][data-expanded=false][data-front=false]{--scale:var(--toasts-before) * 0.05 + 1;--y:translateY(calc(var(--lift-amount) * var(--toasts-before))) scale(calc(-1 * var(--scale)));height:var(--front-toast-height)}[data-sonner-toast]>*{transition:opacity .4s}[data-sonner-toast][data-x-position=right]{right:0}[data-sonner-toast][data-x-position=left]{left:0}[data-sonner-toast][data-expanded=false][data-front=false][data-styled=true]>*{opacity:0}[data-sonner-toast][data-visible=false]{opacity:0;pointer-events:none}[data-sonner-toast][data-mounted=true][data-expanded=true]{--y:translateY(calc(var(--lift) * var(--offset)));height:var(--initial-height)}[data-sonner-toast][data-removed=true][data-front=true][data-swipe-out=false]{--y:translateY(calc(var(--lift) * -100%));opacity:0}[data-sonner-toast][data-removed=true][data-front=false][data-swipe-out=false][data-expanded=true]{--y:translateY(calc(var(--lift) * var(--offset) + var(--lift) * -100%));opacity:0}[data-sonner-toast][data-removed=true][data-front=false][data-swipe-out=false][data-expanded=false]{--y:translateY(40%);opacity:0;transition:transform .5s,opacity .2s}[data-sonner-toast][data-removed=true][data-front=false]::before{height:calc(var(--initial-height) + 20%)}[data-sonner-toast][data-swiping=true]{transform:var(--y) translateY(var(--swipe-amount-y,0)) translateX(var(--swipe-amount-x,0));transition:none}[data-sonner-toast][data-swiped=true]{user-select:none}[data-sonner-toast][data-swipe-out=true][data-y-position=bottom],[data-sonner-toast][data-swipe-out=true][data-y-position=top]{animation-duration:.2s;animation-timing-function:ease-out;animation-fill-mode:forwards}[data-sonner-toast][data-swipe-out=true][data-swipe-direction=left]{animation-name:swipe-out-left}[data-sonner-toast][data-swipe-out=true][data-swipe-direction=right]{animation-name:swipe-out-right}[data-sonner-toast][data-swipe-out=true][data-swipe-direction=up]{animation-name:swipe-out-up}[data-sonner-toast][data-swipe-out=true][data-swipe-direction=down]{animation-name:swipe-out-down}@keyframes swipe-out-left{from{transform:var(--y) translateX(var(--swipe-amount-x));opacity:1}to{transform:var(--y) translateX(calc(var(--swipe-amount-x) - 100%));opacity:0}}@keyframes swipe-out-right{from{transform:var(--y) translateX(var(--swipe-amount-x));opacity:1}to{transform:var(--y) translateX(calc(var(--swipe-amount-x) + 100%));opacity:0}}@keyframes swipe-out-up{from{transform:var(--y) translateY(var(--swipe-amount-y));opacity:1}to{transform:var(--y) translateY(calc(var(--swipe-amount-y) - 100%));opacity:0}}@keyframes swipe-out-down{from{transform:var(--y) translateY(var(--swipe-amount-y));opacity:1}to{transform:var(--y) translateY(calc(var(--swipe-amount-y) + 100%));opacity:0}}@media (max-width:600px){[data-sonner-toaster]{position:fixed;right:var(--mobile-offset-right);left:var(--mobile-offset-left);width:100%}[data-sonner-toaster][dir=rtl]{left:calc(var(--mobile-offset-left) * -1)}[data-sonner-toaster] [data-sonner-toast]{left:0;right:0;width:calc(100% - var(--mobile-offset-left) * 2)}[data-sonner-toaster][data-x-position=left]{left:var(--mobile-offset-left)}[data-sonner-toaster][data-y-position=bottom]{bottom:var(--mobile-offset-bottom)}[data-sonner-toaster][data-y-position=top]{top:var(--mobile-offset-top)}[data-sonner-toaster][data-x-position=center]{left:var(--mobile-offset-left);right:var(--mobile-offset-right);transform:none}}[data-sonner-toaster][data-sonner-theme=light]{--normal-bg:#fff;--normal-border:var(--gray4);--normal-text:var(--gray12);--success-bg:hsl(143, 85%, 96%);--success-border:hsl(145, 92%, 87%);--success-text:hsl(140, 100%, 27%);--info-bg:hsl(208, 100%, 97%);--info-border:hsl(221, 91%, 93%);--info-text:hsl(210, 92%, 45%);--warning-bg:hsl(49, 100%, 97%);--warning-border:hsl(49, 91%, 84%);--warning-text:hsl(31, 92%, 45%);--error-bg:hsl(359, 100%, 97%);--error-border:hsl(359, 100%, 94%);--error-text:hsl(360, 100%, 45%)}[data-sonner-toaster][data-sonner-theme=light] [data-sonner-toast][data-invert=true]{--normal-bg:#000;--normal-border:hsl(0, 0%, 20%);--normal-text:var(--gray1)}[data-sonner-toaster][data-sonner-theme=dark] [data-sonner-toast][data-invert=true]{--normal-bg:#fff;--normal-border:var(--gray3);--normal-text:var(--gray12)}[data-sonner-toaster][data-sonner-theme=dark]{--normal-bg:#000;--normal-bg-hover:hsl(0, 0%, 12%);--normal-border:hsl(0, 0%, 20%);--normal-border-hover:hsl(0, 0%, 25%);--normal-text:var(--gray1);--success-bg:hsl(150, 100%, 6%);--success-border:hsl(147, 100%, 12%);--success-text:hsl(150, 86%, 65%);--info-bg:hsl(215, 100%, 6%);--info-border:hsl(223, 43%, 17%);--info-text:hsl(216, 87%, 65%);--warning-bg:hsl(64, 100%, 6%);--warning-border:hsl(60, 100%, 9%);--warning-text:hsl(46, 87%, 65%);--error-bg:hsl(358, 76%, 10%);--error-border:hsl(357, 89%, 16%);--error-text:hsl(358, 100%, 81%)}[data-sonner-toaster][data-sonner-theme=dark] [data-sonner-toast] [data-close-button]{background:var(--normal-bg);border-color:var(--normal-border);color:var(--normal-text)}[data-sonner-toaster][data-sonner-theme=dark] [data-sonner-toast] [data-close-button]:hover{background:var(--normal-bg-hover);border-color:var(--normal-border-hover)}[data-rich-colors=true][data-sonner-toast][data-type=success]{background:var(--success-bg);border-color:var(--success-border);color:var(--success-text)}[data-rich-colors=true][data-sonner-toast][data-type=success] [data-close-button]{background:var(--success-bg);border-color:var(--success-border);color:var(--success-text)}[data-rich-colors=true][data-sonner-toast][data-type=info]{background:var(--info-bg);border-color:var(--info-border);color:var(--info-text)}[data-rich-colors=true][data-sonner-toast][data-type=info] [data-close-button]{background:var(--info-bg);border-color:var(--info-border);color:var(--info-text)}[data-rich-colors=true][data-sonner-toast][data-type=warning]{background:var(--warning-bg);border-color:var(--warning-border);color:var(--warning-text)}[data-rich-colors=true][data-sonner-toast][data-type=warning] [data-close-button]{background:var(--warning-bg);border-color:var(--warning-border);color:var(--warning-text)}[data-rich-colors=true][data-sonner-toast][data-type=error]{background:var(--error-bg);border-color:var(--error-border);color:var(--error-text)}[data-rich-colors=true][data-sonner-toast][data-type=error] [data-close-button]{background:var(--error-bg);border-color:var(--error-border);color:var(--error-text)}.sonner-loading-wrapper{--size:16px;height:var(--size);width:var(--size);position:absolute;inset:0;z-index:10}.sonner-loading-wrapper[data-visible=false]{transform-origin:center;animation:sonner-fade-out .2s ease forwards}.sonner-spinner{position:relative;top:50%;left:50%;height:var(--size);width:var(--size)}.sonner-loading-bar{animation:sonner-spin 1.2s linear infinite;background:var(--gray11);border-radius:6px;height:8%;left:-10%;position:absolute;top:-3.9%;width:24%}.sonner-loading-bar:first-child{animation-delay:-1.2s;transform:rotate(.0001deg) translate(146%)}.sonner-loading-bar:nth-child(2){animation-delay:-1.1s;transform:rotate(30deg) translate(146%)}.sonner-loading-bar:nth-child(3){animation-delay:-1s;transform:rotate(60deg) translate(146%)}.sonner-loading-bar:nth-child(4){animation-delay:-.9s;transform:rotate(90deg) translate(146%)}.sonner-loading-bar:nth-child(5){animation-delay:-.8s;transform:rotate(120deg) translate(146%)}.sonner-loading-bar:nth-child(6){animation-delay:-.7s;transform:rotate(150deg) translate(146%)}.sonner-loading-bar:nth-child(7){animation-delay:-.6s;transform:rotate(180deg) translate(146%)}.sonner-loading-bar:nth-child(8){animation-delay:-.5s;transform:rotate(210deg) translate(146%)}.sonner-loading-bar:nth-child(9){animation-delay:-.4s;transform:rotate(240deg) translate(146%)}.sonner-loading-bar:nth-child(10){animation-delay:-.3s;transform:rotate(270deg) translate(146%)}.sonner-loading-bar:nth-child(11){animation-delay:-.2s;transform:rotate(300deg) translate(146%)}.sonner-loading-bar:nth-child(12){animation-delay:-.1s;transform:rotate(330deg) translate(146%)}@keyframes sonner-fade-in{0%{opacity:0;transform:scale(.8)}100%{opacity:1;transform:scale(1)}}@keyframes sonner-fade-out{0%{opacity:1;transform:scale(1)}100%{opacity:0;transform:scale(.8)}}@keyframes sonner-spin{0%{opacity:1}100%{opacity:.15}}@media (prefers-reduced-motion){.sonner-loading-bar,[data-sonner-toast],[data-sonner-toast]>*{transition:none!important;animation:none!important}}.sonner-loader{position:absolute;top:50%;left:50%;transform:translate(-50%,-50%);transform-origin:center;transition:opacity .2s,transform .2s}.sonner-loader[data-visible=false]{opacity:0;transform:scale(.8) translate(-50%,-50%)}");function Wo(e){return e.label!==void 0}const jT=3,FT="24px",$T="16px",Bp=4e3,IT=356,DT=14,LT=45,MT=200;function Jt(...e){return e.filter(Boolean).join(" ")}function zT(e){const[t,n]=e.split("-"),r=[];return t&&r.push(t),n&&r.push(n),r}const BT=e=>{var t,n,r,i,s,o,l,a,c;const{invert:f,toast:u,unstyled:d,interacting:h,setHeights:v,visibleToasts:w,heights:S,index:m,toasts:p,expanded:g,removeToast:x,defaultRichColors:C,closeButton:T,style:k,cancelButtonStyle:R,actionButtonStyle:I,className:L="",descriptionClassName:B="",duration:se,position:oe,gap:He,expandByDefault:We,classNames:K,icons:Qe,closeButtonAriaLabel:P="Close toast"}=e,[D,H]=N.useState(null),[M,V]=N.useState(null),[ee,de]=N.useState(!1),[Ce,Z]=N.useState(!1),[Je,mn]=N.useState(!1),[An,jn]=N.useState(!1),[ns,ho]=N.useState(!1),[po,rs]=N.useState(0),[Pa,mo]=N.useState(0),vr=N.useRef(u.duration||se||Bp),yo=N.useRef(null),ct=N.useRef(null),Aa=m===0,ja=m+1<=w,E=u.type,A=u.dismissible!==!1,$=u.className||"",z=u.descriptionClassName||"",W=N.useMemo(()=>S.findIndex(Q=>Q.toastId===u.id)||0,[S,u.id]),te=N.useMemo(()=>{var Q;return(Q=u.closeButton)!=null?Q:T},[u.closeButton,T]),we=N.useMemo(()=>u.duration||se||Bp,[u.duration,se]),ft=N.useRef(0),Xt=N.useRef(0),ri=N.useRef(0),Fn=N.useRef(null),[xd,go]=oe.split("-"),vo=N.useMemo(()=>S.reduce((Q,Te,De)=>De>=W?Q:Q+Te.height,0),[S,W]),Sd=CT(),sv=u.invert||f,Fa=E==="loading";Xt.current=N.useMemo(()=>W*He+vo,[W,vo]),N.useEffect(()=>{vr.current=we},[we]),N.useEffect(()=>{de(!0)},[]),N.useEffect(()=>{const Q=ct.current;if(Q){const Te=Q.getBoundingClientRect().height;return mo(Te),v(De=>[{toastId:u.id,height:Te,position:u.position},...De]),()=>v(De=>De.filter(dt=>dt.toastId!==u.id))}},[v,u.id]),N.useLayoutEffect(()=>{if(!ee)return;const Q=ct.current,Te=Q.style.height;Q.style.height="auto";const De=Q.getBoundingClientRect().height;Q.style.height=Te,mo(De),v(dt=>dt.find(je=>je.toastId===u.id)?dt.map(je=>je.toastId===u.id?{...je,height:De}:je):[{toastId:u.id,height:De,position:u.position},...dt])},[ee,u.title,u.description,v,u.id]);const $n=N.useCallback(()=>{Z(!0),rs(Xt.current),v(Q=>Q.filter(Te=>Te.toastId!==u.id)),setTimeout(()=>{x(u)},MT)},[u,x,v,Xt]);N.useEffect(()=>{if(u.promise&&E==="loading"||u.duration===1/0||u.type==="loading")return;let Q;return g||h||Sd?(()=>{if(ri.current<ft.current){const dt=new Date().getTime()-ft.current;vr.current=vr.current-dt}ri.current=new Date().getTime()})():(()=>{vr.current!==1/0&&(ft.current=new Date().getTime(),Q=setTimeout(()=>{u.onAutoClose==null||u.onAutoClose.call(u,u),$n()},vr.current))})(),()=>clearTimeout(Q)},[g,h,u,E,Sd,$n]),N.useEffect(()=>{u.delete&&$n()},[$n,u.delete]);function ov(){var Q;if(Qe!=null&&Qe.loading){var Te;return N.createElement("div",{className:Jt(K==null?void 0:K.loader,u==null||(Te=u.classNames)==null?void 0:Te.loader,"sonner-loader"),"data-visible":E==="loading"},Qe.loading)}return N.createElement(xT,{className:Jt(K==null?void 0:K.loader,u==null||(Q=u.classNames)==null?void 0:Q.loader),visible:E==="loading"})}var bd,Ed;return N.createElement("li",{tabIndex:0,ref:ct,className:Jt(L,$,K==null?void 0:K.toast,u==null||(t=u.classNames)==null?void 0:t.toast,K==null?void 0:K.default,K==null?void 0:K[E],u==null||(n=u.classNames)==null?void 0:n[E]),"data-sonner-toast":"","data-rich-colors":(bd=u.richColors)!=null?bd:C,"data-styled":!(u.jsx||u.unstyled||d),"data-mounted":ee,"data-promise":!!u.promise,"data-swiped":ns,"data-removed":Ce,"data-visible":ja,"data-y-position":xd,"data-x-position":go,"data-index":m,"data-front":Aa,"data-swiping":Je,"data-dismissible":A,"data-type":E,"data-invert":sv,"data-swipe-out":An,"data-swipe-direction":M,"data-expanded":!!(g||We&&ee),style:{"--index":m,"--toasts-before":m,"--z-index":p.length-m,"--offset":`${Ce?po:Xt.current}px`,"--initial-height":We?"auto":`${Pa}px`,...k,...u.style},onDragEnd:()=>{mn(!1),H(null),Fn.current=null},onPointerDown:Q=>{Fa||!A||(yo.current=new Date,rs(Xt.current),Q.target.setPointerCapture(Q.pointerId),Q.target.tagName!=="BUTTON"&&(mn(!0),Fn.current={x:Q.clientX,y:Q.clientY}))},onPointerUp:()=>{var Q,Te,De;if(An||!A)return;Fn.current=null;const dt=Number(((Q=ct.current)==null?void 0:Q.style.getPropertyValue("--swipe-amount-x").replace("px",""))||0),wo=Number(((Te=ct.current)==null?void 0:Te.style.getPropertyValue("--swipe-amount-y").replace("px",""))||0),je=new Date().getTime()-((De=yo.current)==null?void 0:De.getTime()),kt=D==="x"?dt:wo,xo=Math.abs(kt)/je;if(Math.abs(kt)>=LT||xo>.11){rs(Xt.current),u.onDismiss==null||u.onDismiss.call(u,u),V(D==="x"?dt>0?"right":"left":wo>0?"down":"up"),$n(),jn(!0);return}else{var It,Dt;(It=ct.current)==null||It.style.setProperty("--swipe-amount-x","0px"),(Dt=ct.current)==null||Dt.style.setProperty("--swipe-amount-y","0px")}ho(!1),mn(!1),H(null)},onPointerMove:Q=>{var Te,De,dt;if(!Fn.current||!A||((Te=window.getSelection())==null?void 0:Te.toString().length)>0)return;const je=Q.clientY-Fn.current.y,kt=Q.clientX-Fn.current.x;var xo;const It=(xo=e.swipeDirections)!=null?xo:zT(oe);!D&&(Math.abs(kt)>1||Math.abs(je)>1)&&H(Math.abs(kt)>Math.abs(je)?"x":"y");let Dt={x:0,y:0};const _d=wr=>1/(1.5+Math.abs(wr)/20);if(D==="y"){if(It.includes("top")||It.includes("bottom"))if(It.includes("top")&&je<0||It.includes("bottom")&&je>0)Dt.y=je;else{const wr=je*_d(je);Dt.y=Math.abs(wr)<Math.abs(je)?wr:je}}else if(D==="x"&&(It.includes("left")||It.includes("right")))if(It.includes("left")&&kt<0||It.includes("right")&&kt>0)Dt.x=kt;else{const wr=kt*_d(kt);Dt.x=Math.abs(wr)<Math.abs(kt)?wr:kt}(Math.abs(Dt.x)>0||Math.abs(Dt.y)>0)&&ho(!0),(De=ct.current)==null||De.style.setProperty("--swipe-amount-x",`${Dt.x}px`),(dt=ct.current)==null||dt.style.setProperty("--swipe-amount-y",`${Dt.y}px`)}},te&&!u.jsx&&E!=="loading"?N.createElement("button",{"aria-label":P,"data-disabled":Fa,"data-close-button":!0,onClick:Fa||!A?()=>{}:()=>{$n(),u.onDismiss==null||u.onDismiss.call(u,u)},className:Jt(K==null?void 0:K.closeButton,u==null||(r=u.classNames)==null?void 0:r.closeButton)},(Ed=Qe==null?void 0:Qe.close)!=null?Ed:kT):null,E||u.icon||u.promise?N.createElement("div",{"data-icon":"",className:Jt(K==null?void 0:K.icon,u==null||(i=u.classNames)==null?void 0:i.icon)},u.promise||u.type==="loading"&&!u.icon?u.icon||ov():null,u.type!=="loading"?u.icon||(Qe==null?void 0:Qe[E])||vT(E):null):null,N.createElement("div",{"data-content":"",className:Jt(K==null?void 0:K.content,u==null||(s=u.classNames)==null?void 0:s.content)},N.createElement("div",{"data-title":"",className:Jt(K==null?void 0:K.title,u==null||(o=u.classNames)==null?void 0:o.title)},u.jsx?u.jsx:typeof u.title=="function"?u.title():u.title),u.description?N.createElement("div",{"data-description":"",className:Jt(B,z,K==null?void 0:K.description,u==null||(l=u.classNames)==null?void 0:l.description)},typeof u.description=="function"?u.description():u.description):null),N.isValidElement(u.cancel)?u.cancel:u.cancel&&Wo(u.cancel)?N.createElement("button",{"data-button":!0,"data-cancel":!0,style:u.cancelButtonStyle||R,onClick:Q=>{Wo(u.cancel)&&A&&(u.cancel.onClick==null||u.cancel.onClick.call(u.cancel,Q),$n())},className:Jt(K==null?void 0:K.cancelButton,u==null||(a=u.classNames)==null?void 0:a.cancelButton)},u.cancel.label):null,N.isValidElement(u.action)?u.action:u.action&&Wo(u.action)?N.createElement("button",{"data-button":!0,"data-action":!0,style:u.actionButtonStyle||I,onClick:Q=>{Wo(u.action)&&(u.action.onClick==null||u.action.onClick.call(u.action,Q),!Q.defaultPrevented&&$n())},className:Jt(K==null?void 0:K.actionButton,u==null||(c=u.classNames)==null?void 0:c.actionButton)},u.action.label):null)};function Up(){if(typeof window>"u"||typeof document>"u")return"ltr";const e=document.documentElement.getAttribute("dir");return e==="auto"||!e?window.getComputedStyle(document.documentElement).direction:e}function UT(e,t){const n={};return[e,t].forEach((r,i)=>{const s=i===1,o=s?"--mobile-offset":"--offset",l=s?$T:FT;function a(c){["top","right","bottom","left"].forEach(f=>{n[`${o}-${f}`]=typeof c=="number"?`${c}px`:c})}typeof r=="number"||typeof r=="string"?a(r):typeof r=="object"?["top","right","bottom","left"].forEach(c=>{r[c]===void 0?n[`${o}-${c}`]=l:n[`${o}-${c}`]=typeof r[c]=="number"?`${r[c]}px`:r[c]}):a(l)}),n}const VT=N.forwardRef(function(t,n){const{invert:r,position:i="bottom-right",hotkey:s=["altKey","KeyT"],expand:o,closeButton:l,className:a,offset:c,mobileOffset:f,theme:u="light",richColors:d,duration:h,style:v,visibleToasts:w=jT,toastOptions:S,dir:m=Up(),gap:p=DT,icons:g,containerAriaLabel:x="Notifications"}=t,[C,T]=N.useState([]),k=N.useMemo(()=>Array.from(new Set([i].concat(C.filter(M=>M.position).map(M=>M.position)))),[C,i]),[R,I]=N.useState([]),[L,B]=N.useState(!1),[se,oe]=N.useState(!1),[He,We]=N.useState(u!=="system"?u:typeof window<"u"&&window.matchMedia&&window.matchMedia("(prefers-color-scheme: dark)").matches?"dark":"light"),K=N.useRef(null),Qe=s.join("+").replace(/Key/g,"").replace(/Digit/g,""),P=N.useRef(null),D=N.useRef(!1),H=N.useCallback(M=>{T(V=>{var ee;return(ee=V.find(de=>de.id===M.id))!=null&&ee.delete||rt.dismiss(M.id),V.filter(({id:de})=>de!==M.id)})},[]);return N.useEffect(()=>rt.subscribe(M=>{if(M.dismiss){const V=C.map(ee=>ee.id===M.id?{...ee,delete:!0}:ee);requestAnimationFrame(()=>{T(V)});return}setTimeout(()=>{$w.flushSync(()=>{T(V=>{const ee=V.findIndex(de=>de.id===M.id);return ee!==-1?[...V.slice(0,ee),{...V[ee],...M},...V.slice(ee+1)]:[M,...V]})})})}),[C]),N.useEffect(()=>{if(u!=="system"){We(u);return}if(u==="system"&&(window.matchMedia&&window.matchMedia("(prefers-color-scheme: dark)").matches?We("dark"):We("light")),typeof window>"u")return;const M=window.matchMedia("(prefers-color-scheme: dark)");try{M.addEventListener("change",({matches:V})=>{We(V?"dark":"light")})}catch{M.addListener(({matches:ee})=>{try{We(ee?"dark":"light")}catch(de){console.error(de)}})}},[u]),N.useEffect(()=>{C.length<=1&&B(!1)},[C]),N.useEffect(()=>{const M=V=>{var ee;if(s.every(Z=>V[Z]||V.code===Z)){var Ce;B(!0),(Ce=K.current)==null||Ce.focus()}V.code==="Escape"&&(document.activeElement===K.current||(ee=K.current)!=null&&ee.contains(document.activeElement))&&B(!1)};return document.addEventListener("keydown",M),()=>document.removeEventListener("keydown",M)},[s]),N.useEffect(()=>{if(K.current)return()=>{P.current&&(P.current.focus({preventScroll:!0}),P.current=null,D.current=!1)}},[K.current]),N.createElement("section",{ref:n,"aria-label":`${x} ${Qe}`,tabIndex:-1,"aria-live":"polite","aria-relevant":"additions text","aria-atomic":"false",suppressHydrationWarning:!0},k.map((M,V)=>{var ee;const[de,Ce]=M.split("-");return C.length?N.createElement("ol",{key:M,dir:m==="auto"?Up():m,tabIndex:-1,ref:K,className:a,"data-sonner-toaster":!0,"data-sonner-theme":He,"data-y-position":de,"data-lifted":L&&C.length>1&&!o,"data-x-position":Ce,style:{"--front-toast-height":`${((ee=R[0])==null?void 0:ee.height)||0}px`,"--width":`${IT}px`,"--gap":`${p}px`,...v,...UT(c,f)},onBlur:Z=>{D.current&&!Z.currentTarget.contains(Z.relatedTarget)&&(D.current=!1,P.current&&(P.current.focus({preventScroll:!0}),P.current=null))},onFocus:Z=>{Z.target instanceof HTMLElement&&Z.target.dataset.dismissible==="false"||D.current||(D.current=!0,P.current=Z.relatedTarget)},onMouseEnter:()=>B(!0),onMouseMove:()=>B(!0),onMouseLeave:()=>{se||B(!1)},onDragEnd:()=>B(!1),onPointerDown:Z=>{Z.target instanceof HTMLElement&&Z.target.dataset.dismissible==="false"||oe(!0)},onPointerUp:()=>oe(!1)},C.filter(Z=>!Z.position&&V===0||Z.position===M).map((Z,Je)=>{var mn,An;return N.createElement(BT,{key:Z.id,icons:g,index:Je,toast:Z,defaultRichColors:d,duration:(mn=S==null?void 0:S.duration)!=null?mn:h,className:S==null?void 0:S.className,descriptionClassName:S==null?void 0:S.descriptionClassName,invert:r,visibleToasts:w,closeButton:(An=S==null?void 0:S.closeButton)!=null?An:l,interacting:se,position:M,style:S==null?void 0:S.style,unstyled:S==null?void 0:S.unstyled,classNames:S==null?void 0:S.classNames,cancelButtonStyle:S==null?void 0:S.cancelButtonStyle,actionButtonStyle:S==null?void 0:S.actionButtonStyle,closeButtonAriaLabel:S==null?void 0:S.closeButtonAriaLabel,removeToast:H,toasts:C.filter(jn=>jn.position==Z.position),heights:R.filter(jn=>jn.position==Z.position),setHeights:I,expandByDefault:o,gap:p,expanded:L,swipeDirections:t.swipeDirections})})):null}))});function HT(e){return Array.isArray(e)&&e[0].field!==void 0}const WT=(e,t)=>{var n;if(HT(e)){for(const r of e)(n=t==null?void 0:t.form)==null||n.setFieldError(r.field,r.message);return}if(e&&e.message){t!=null&&t.noToast||zp.error(e.message);return}if(e&&e.error){t!=null&&t.noToast||zp.error(e.error);return}};function QT(e,t,n){let r=n;r||(r=Object.keys(e));for(let i of r){if(Array.isArray(e[i])&&Array.isArray(t[i])){if(e[i].length!==t[i].length)return!1;for(let s=0;s<e[i].length;s++)if(e[i][s]!==t[i][s])return!1;continue}if(e[i]!==t[i])return!1}return!0}function qT({id:e,text:t,required:n,className:r,noMargin:i}){return t?_.jsxs("label",{htmlFor:e,className:qt(r,{"lc-mb-2":!i},"lc-inline-block lc-text-base lc-font-medium lc-text-gray-700"),children:[t," ",n&&_.jsx("span",{className:"lc-text-red-500",children:"*"})]}):null}const xu={sm:"lc-px-3 lc-py-1 lc-text-xs",md:"lc-px-4 lc-py-2 lc-text-sm",lg:"lc-px-5 lc-py-3 lc-text-15"};function Zg({id:e,label:t,suffix:n,prefix:r,size:i="md",type:s="text",noMargin:o=!1,required:l=!1,error:a,ariaDescribedBy:c,className:f,ariaInvalid:u,ariaLabel:d,autoFocus:h,...v}){return _.jsxs("div",{className:qt({"lc-mb-3":!o},f),children:[_.jsx(qT,{id:e,text:t,required:l}),_.jsxs("div",{className:"lc-flex lc-items-center",children:[r&&_.jsx("span",{className:qt("lc-inline-block lc-border lc-border-r-0 lc-border-slate-200 lc-bg-slate-100 lc-rounded-l-md",xu[i],{"!lc-border-red-500":!!a}),children:r}),_.jsx("input",{id:e,className:qt("lc-text-gray-800 lc-border lc-rounded-md lc-block lc-text-base lc-py-2 lc-px-4 lc-w-full lc-border-slate-200 focus:lc-outline-none focus:lc-border-custom-500 disabled:lc-bg-slate-100 disabled:lc-border-slate-300 disabled:lc-text-slate-500 placeholder:lc-text-slate-400",xu[i],{"lc-rounded-l-none":!!r,"lc-rounded-r-none":!!n,"!lc-border-red-500 !lc-text-red-500":!!a}),type:s,required:l,"aria-describedby":c,"aria-invalid":u,"aria-label":d,...v}),n&&_.jsx("span",{className:qt("lc-inline-block lc-border lc-border-l-0 lc-border-slate-200 lc-bg-slate-100 lc-rounded-r-md",xu[i],{"!lc-border-red-500":!!a}),children:n})]}),!!a&&_.jsx("p",{className:"lc-mt-1 lc-text-sm lc-text-red-500",children:a})]})}const KT=(e,t)=>{document.cookie=`${e}=${t}`},Jg=b.createContext({}),ev=()=>`${window.location.pathname}_$$_${document.title}`,YT=()=>{const e=localStorage.getItem("lc-page");return!e||e===""?"/":ev()},GT=()=>{const e=localStorage.getItem("lc-p-history");if(!e||e==="")return[];try{return JSON.parse(e)}catch{return[]}};function XT({children:e}){const[t,n]=b.useState("/"),[r,i]=b.useState(GT());function s(){i([]),localStorage.removeItem("lc-p-history")}const o=l=>{n(l),i(a=>[...new Set([...a,l])]),localStorage.setItem("lc-page",l),localStorage.setItem("lc-p-history",JSON.stringify(r))};return b.useEffect(()=>{o(ev())},[]),_.jsx(Jg.Provider,{value:{page:t,setPage:o,history:r,clearHistory:s},children:e})}function wd(){return b.useContext(Jg)}function ZT({label:e,id:t,value:n="",className:r,placeholder:i,children:s,required:o,error:l,...a}){return _.jsxs("div",{className:r||"",children:[e&&_.jsxs("label",{htmlFor:t,className:"lc-inline-block lc-mb-2 lc-text-base lc-font-medium",children:[e," ",o&&_.jsx("span",{className:"lc-text-red-500",children:"*"})]}),_.jsx("select",{id:t,"aria-placeholder":i,value:n,"aria-label":e,className:"lc-bg-light lc-form-select dark:lc-bg-zink-700 dark:lc-border-zink-500 lc-transition-colors lc-duration-200 lc-border lc-text-gray-900 dark:lc-text-gray-200 sm:lc-text-sm lc-rounded-md focus:lc-ring-emerald-500 lc-focus-visible:lc-ring-0 lc-focus-visible:lc-shadow-none lc-outline-none lc-focus-visible:lc-outline-none lc-focus-visible:lc-border-emerald-500 focus:lc-border-emerald-500 lc-block lc-w-full lc-px-2 lc-py-2 lc-placeholder-fuchsia-600 lc-caret-emerald-500",onChange:a.onChange,required:o,...a,children:s}),!!l&&_.jsx("p",{className:"lc-mt-1 lc-text-sm lc-text-red-500",children:l})]})}const Vp={ring:{label:"",input:"lc-relative before:content[''] before:absolute before:top-2/4 before:left-2/4 before:block before:h-12 before:w-12 before:-translate-y-2/4 before:-translate-x-2/4 before:rounded-full before:bg-blue-gray-500 before:opacity-0 before:transition-opacity hover:before:opacity-10"},hover:{label:"hover:lc-bg-secondary lc-transition-colors lc-duration-200 lc-px-2 lc-py-1 lc-rounded-md",input:""}},JT={blue:"lc-checked:lc-border-blue-500 lc-checked:lc-bg-blue-500 lc-checked:before:lc-bg-blue-500",indigo:"lc-checked:lc-border-indigo-500 lc-checked:lc-bg-indigo-500 lc-checked:before:lc-bg-indigo-500",green:"lc-checked:lc-border-green-500 lc-checked:lc-bg-green-500 lc-checked:before:lc-bg-green-500",red:"lc-checked:lc-border-red-500 lc-checked:lc-bg-red-500 lc-checked:before:lc-bg-red-500",orange:"lc-checked:lc-border-orange-500 lc-checked:lc-bg-orange-500 lc-checked:before:lc-bg-orange-500"},eO={sm:"lc-h-4 lc-w-4 lg:lc-h-3 lg:lc-w-3",md:"lc-h-6 lc-w-6 lg:lc-h-5 lg:lc-w-5",lg:"lc-h-8 lc-w-8 lg:lc-h-7 lg:lc-w-7"},tO={sm:"lc-h-3 lc-w-3 lg:lc-h-2.5 lg:lc-w-2.5",md:"lc-h-5 lc-w-5 lg:lc-h-4 lg:lc-w-4",lg:"lc-h-7 lc-w-7 lg:lc-h-6 lg:lc-w-6"};function nO({children:e,name:t,required:n,value:r,checked:i,onChange:s,onBlur:o,red:l,id:a=t,size:c="md",effect:f="ring",reversed:u=!1,variant:d="blue",...h}){return _.jsxs("div",{children:[_.jsxs("div",{className:`lc-flex lc-items-center lc-justify-between ${u?"lc-flex-row-reverse":""} ${Vp[f].label}`,children:[_.jsxs("label",{className:"lc-disable-highlight lc-relative lc-mr-3 lc-flex lc-cursor-pointer lc-items-center lc-rounded-full",htmlFor:a,children:[_.jsx("input",{id:a,name:t,type:"checkbox",className:`lc-border-blue-gray-200 lc-peer lc-cursor-pointer lc-appearance-none lc-rounded-md lc-border lc-bg-white lc-transition-all dark:lc-bg-inherit ${JT[d]} ${eO[c]} ${Vp[f].input}`,required:n,checked:i,value:r,onChange:v=>s==null?void 0:s(v.target.checked),onBlur:v=>o==null?void 0:o(v.target.checked),...h}),_.jsx("div",{className:"lc-pointer-events-none lc-absolute lc-left-2/4 lc-top-2/4 lc-translate-x-2/4 lc-translate-y-2/4 lc-text-white lc-opacity-0 lc-transition-opacity lc-peer-checked:lc-opacity-100",children:_.jsx(Ve.Check,{className:tO[c]})})]}),_.jsx("label",{className:"lc-disable-highlight lc-mt-px lc-flex lc-grow lc-cursor-pointer lc-select-none lc-items-center lc-justify-between lc-font-light lc-text-gray-800 dark:lc-text-gray-400",htmlFor:a,children:e})]}),l&&_.jsx("small",{className:"lc-text-xs lc-text-red-500",children:l})]})}const rO={blue:"lc-text-blue-500 lc-border-blue-gray-200 checked:lc-bg-blue-500 checked:lc-border-blue-500 checked:before:lc-bg-blue-500 before:lc-bg-gray-500",red:"lc-text-red-500 lc-border-blue-gray-200 checked:lc-border-red-500 checked:before:lc-bg-red-500 before:lc-bg-blue-gray-500",emerald:"lc-text-emerald-500 lc-border-blue-gray-200 checked:lc-border-emerald-500 checked:before:lc-bg-emerald-500 before:lc-bg-blue-gray-500",orange:"lc-text-orange-500 lc-border-blue-gray-200 checked:lc-border-orange-500 checked:before:lc-bg-orange-500 before:lc-bg-blue-gray-500"},iO={blue:"lc-text-white",red:"lc-text-red-500",emerald:"lc-text-emerald-500",orange:"lc-text-orange-500"},Hp={sm:"lc-h-4 lc-w-4 lg:lc-h-3 lg:lc-w-3",md:"lc-h-6 lc-w-6 lg:lc-h-5 lg:lc-w-5",lg:"lc-h-8 lc-w-8 lg:lc-h-7 lg:lc-w-7"},sO={sm:"lc-size-3",md:"lc-size-4",lg:"lc-size-5"},Wp={ring:{label:"",input:"lc-relative before:lc-content[''] before:lc-absolute before:lc-top-2/4 before:lc-left-2/4 before:lc-block before:lc-h-9 before:lc-w-9 before:-lc-translate-y-2/4 before:-lc-translate-x-2/4 before:lc-rounded-full before:lc-opacity-0 before:lc-transition-opacity hover:before:lc-opacity-10"},hover:{label:"hover:lc-bg-secondary lc-transition-colors lc-duration-200",input:""}};function Kc({children:e,id:t,name:n,size:r="md",variant:i="blue",effect:s="ring",value:o=!1,reverse:l=!1,onChange:a,onBlur:c,onClick:f}){return _.jsxs("label",{className:`lc-disable-highlight lc-flex lc-cursor-pointer lc-items-center lc-rounded-md lc-text-gray-700 ${l?"lc-flex-row-reverse lc-justify-between":""} ${Wp[s].label} `,htmlFor:t,children:[_.jsxs("label",{className:"lc-relative lc-flex lc-items-center lc-p-2 lc-rounded-full lc-cursor-pointer lc-disable-highlight",htmlFor:t,children:[_.jsx("input",{id:t,name:n,type:"radio",className:`lc-peer lc-disable-highlight lc-bg-none lc-cursor-pointer lc-appearance-none lc-rounded-full lc-border lc-bg-inherit lc-transition-all ${rO[i]} ${Hp[r]} ${Wp[s].input}`,checked:o,onChange:u=>a==null?void 0:a(u.target.checked),onBlur:u=>c==null?void 0:c(u.target.checked),onClick:()=>f==null?void 0:f(!o)}),_.jsx("div",{className:`lc-pointer-events-none lc-absolute lc-flex lc-items-center lc-justify-center lc-opacity-0 lc-transition-opacity peer-checked:lc-opacity-100 ${iO[i]} ${Hp[r]}`,children:_.jsx(Ve.Check,{className:sO[r]})})]}),_.jsx("label",{className:"lc-text-gray-800 lc-disable-highlight lc-flex lc-cursor-pointer lc-select-none lc-items-center lc-font-light",htmlFor:t,children:e})]})}Kc.Group=function({label:t,id:n,className:r,required:i,children:s}){return _.jsxs("div",{className:r,children:[_.jsxs("label",{htmlFor:n,className:"lc-inline-block lc-mb-2 lc-text-base lc-font-medium",children:[t," ",i&&_.jsx("span",{className:"lc-text-red-500",children:"*"})]}),_.jsx("div",{className:"lc-col-span-12 lc-flex lc-flex-col lc-justify-center",children:s})]})};function oO({onOk:e,clientId:t,widgetId:n,appearance:r}){var d,h,v,w,S,m,p,g;const{defaultValues:i}=yr(),s=wd(),o=Zb(),l=(h=(d=r==null?void 0:r.body)==null?void 0:d.inputs)==null?void 0:h.reduce((x,C)=>{const T=ul(C.name);return x[C.name]=T||(i==null?void 0:i[C.name])||"",x},{}),a=(w=(v=r==null?void 0:r.body)==null?void 0:v.inputs)==null?void 0:w.reduce((x,C)=>(x[C.name]="",x),{}),c=gg((m=(S=r==null?void 0:r.body)==null?void 0:S.inputs)==null?void 0:m.reduce((x,C)=>(x[C.name]=C.required?Mc().required(C.label):Mc(),x),{})),f=yT({init:{...l},schema:c,action:async x=>{var k;const[C,T]=await o.mutateAsync({inputs:x,history:s.history,client_id:t,widget_id:n});if(gy(T)){s.clearHistory();for(const R of((k=r==null?void 0:r.body)==null?void 0:k.inputs)||[])KT(R.name,x[R.name]);e==null||e();return}WT(C,{form:f})}}),u=!QT(a,f.values);return _.jsx("section",{className:"lc-overflow-y-auto lc-p-4",style:{height:"calc(100% - 13rem)"},children:_.jsxs("form",{className:"lc-grid lc-grid-cols-1 lc-gap-4",onSubmit:x=>{x.preventDefault(),f.handleSubmit()},children:[(g=(p=r==null?void 0:r.body)==null?void 0:p.inputs)==null?void 0:g.map(x=>{var C,T;if(["text","email","phone"].includes(x.type))return _.jsx(Zg,{id:x.name,name:x.name,type:x.type,value:f.values[x.name],onChange:f.handleChange,onBlur:f.handleBlur,autoComplete:"off",placeholder:x.placeholder,error:f.errors[x.name],ariaInvalid:f.errors.name?!0:void 0,required:!0,noMargin:!0},x.name);if(x.type==="select")return _.jsx(ZT,{id:x.name,name:x.name,value:f.values[x.name],onChange:f.handleChange,label:x.label,children:(C=x.options)==null?void 0:C.map(k=>_.jsx("option",{value:k,children:k},k))},x.name);if(x.type==="checkbox")return _.jsx(nO,{id:x.name,name:x.name,value:f.values[x.name],onChange:f.handleChange,children:x.label},x.name);if(x.type==="radio")return _.jsx(Kc.Group,{id:x.name,label:x.label,required:x.required,children:(T=x.options)==null?void 0:T.map(k=>_.jsx(Kc,{onChange:R=>{R?f.setFieldValue(x.name,k):f.setFieldValue(x.name,"")},id:k,name:x.name,value:k===f.values[x.name],children:k},k))},x.name)}),_.jsx(Gs,{type:"submit",disabled:!u,children:"Sohbet Oluştur"})]})})}function lO({image_url:e,name:t,size:n="lc-size-9"}){return e?_.jsx("img",{src:e,alt:t,className:qt("lc-rounded-md",n)}):_.jsx("div",{className:"lc-flex lc-items-center lc-justify-center lc-gap-1",children:_.jsx(Ve.Website,{className:qt("lc-text-slate-500",n)})})}const tv=(e,t,n)=>{const r=typeof window<"u"?window:void 0;b.useEffect(()=>(r.addEventListener(e,t),()=>{r.removeEventListener(e,t,!1)}),[e,t,r])};function aO(){const e=wd(),t=b.useCallback(()=>{const n=window.location.pathname;n!==e.page&&e.setPage(n)},[e.page]);return tv("popstate",t),null}function uO(){const e=uo(),t=wd(),n=b.useCallback(()=>{const r=window.location.pathname;if(r!==t.page){if(e){e.emit(fn.PageChange,{page:r});return}t.setPage(r)}},[e,t.page]);return tv("popstate",n),b.useEffect(()=>{if(!e)return;const r=setTimeout(()=>{YT()!==t.page&&e.emit(fn.PageChange,{page:t.page})},1e3);return()=>{clearTimeout(r)}},[e,t.page]),null}function cO({children:e}){const{widget:t}=yr();return t?_.jsxs("section",{className:"lc-h-full lc-w-full lc-relative",children:[_.jsx("div",{className:"-lc-z-10 lc-h-52 lc-bg-zink-600 lc-absolute lc-top-0 lc-left-0 lc-w-full lc-rounded-t-md lc-flex lc-flex-col lc-gap-4 lc-items-center lc-justify-center"}),e]}):null}function fO(){return aO(),null}const Su=(e,t)=>{var n;return(n=e.find(r=>r.type===t))==null?void 0:n.content};function dO(){var l,a,c,f,u,d;const{widget:e}=yr(),[t,n]=b.useState(!0),r=td();if(!e||(b.useEffect(()=>{Jb(e.client_id).then(([h,v])=>{gy(v)&&r.push("chat")}).finally(()=>{n(!1)})},[]),t))return null;const i=Su(((a=(l=e.appearance)==null?void 0:l.head)==null?void 0:a.elements)||[],"text"),s=Su(((f=(c=e.appearance)==null?void 0:c.head)==null?void 0:f.elements)||[],"title"),o=Su(((d=(u=e.appearance)==null?void 0:u.head)==null?void 0:d.elements)||[],"logo");return _.jsxs(_.Fragment,{children:[_.jsx(lg,{children:_.jsxs(cO,{children:[_.jsxs("div",{className:"lc-flex lc-flex-col lc-gap-3 lc-items-center lc-justify-center lc-h-52",children:[o&&_.jsx(lO,{name:e.name,image_url:o,size:"lc-size-24"}),s&&_.jsx("div",{className:"lc-text-white lc-text-lg lc-font-bold lc-ml-2",children:s}),i&&_.jsx("div",{className:"lc-text-white lc-text-sm",children:i})]}),_.jsx(oO,{clientId:e.client_id,widgetId:e.link_id,appearance:e.appearance,onOk:()=>{r.push("chat")}})]})}),_.jsx(fO,{})]})}const hO=[{path:"/",component:dO,name:"registration"}];function pO({name:e,avatar:t,className:n="lc-text-neutral-500"}){return _.jsxs("div",{className:"lc-flex lc-gap-2 lc-items-center",children:[_.jsx("div",{className:"lc-min-w-max",children:_.jsxs("span",{children:[t&&_.jsx("img",{className:"lc-size-10 lc-rounded-full",src:t,"aria-label":e}),!t&&_.jsx("div",{className:"lc-size-10 lc-rounded-full lc-bg-neutral-200"})]})}),_.jsx("div",{className:"lc-flex lc-flex-col",children:_.jsx("span",{className:qt("lc-line-clamp-1",n),children:e})})]})}var nv=(e=>(e.AdminJoin="admin_join",e))(nv||{}),pt=(e=>(e.Customer="customer",e.User="user",e.System="system",e.Activity="activity",e))(pt||{});function mO(e,t){let n,r=0;return function(...s){r++;const o=r;clearTimeout(n),n=setTimeout(()=>{o===r&&e(...s)},t)}}function yO({onNewMessage:e}){const t=uo(),[n,r]=b.useState(""),i=()=>{t==null||t.emit(fn.MessageCreate,{content:n},l=>{r(""),e(l),s("")})},s=l=>{t==null||t.emit(fn.MessageTyping,{content:l})},o=mO(s,300);return _.jsxs("form",{className:"lc-border-t lc-p-2 lc-flex lc-items-center lc-gap-2",onSubmit:l=>{l.preventDefault(),i(),l.currentTarget.reset()},children:[_.jsx("div",{className:"lc-grow lc-relative",children:_.jsx(Zg,{id:"message",className:"lc-grow",noMargin:!0,autoComplete:"off",onChange:l=>{r(l.target.value),o(l.target.value)},placeholder:"Bir mesaj yazın"})}),_.jsx("div",{className:"lc-flex lc-items-center lc-justify-center lc-h-full",children:_.jsx(Gs,{className:"lc-rounded-md",type:"submit",children:"Gönder"})})]})}function gO({messages:e,isTyping:t}){var c,f,u,d;const n=b.useRef(null),r=b.useRef(null),[i,s]=b.useState(!0),{widget:o}=yr(),l=()=>{var h;(h=n.current)==null||h.scrollIntoView({behavior:"smooth"})},a=()=>{if(r.current){const{scrollTop:h,scrollHeight:v,clientHeight:w}=r.current,S=v-h<=w+10;s(S)}};return b.useEffect(()=>{i&&l()},[e,i]),_.jsxs("section",{onScroll:a,ref:r,className:"lc-flex lc-flex-col lc-gap-2 lc-w-full lc-h-full lc-grow lc-pt-4 lc-px-4 lc-overflow-y-auto",style:{height:"calc(100vh - 122px)"},children:[((f=(c=o==null?void 0:o.appearance)==null?void 0:c.design)==null?void 0:f.greeting_message)&&_.jsx("div",{className:"lc-flex lc-w-full lc-items-center lc-justify-start",children:_.jsx("div",{className:"lc-max-w-[85%] lc-whitespace-pre-wrap lc-border lc-rounded-md lc-px-2 lc-py-1 lc-bg-zink-500 lc-text-white",children:(d=(u=o==null?void 0:o.appearance)==null?void 0:u.design)==null?void 0:d.greeting_message})}),e.filter(h=>!!h.content&&h.content!==`
89
+ `).map((h,v)=>_.jsxs("div",{className:qt("lc-flex lc-w-full lc-items-center lc-break-all",{"lc-justify-end":h.sender_type===pt.Customer,"lc-justify-start":h.sender_type===pt.User,"lc-justify-center":h.sender_type===pt.System||h.sender_type===pt.Activity}),children:[h.sender_type===pt.System&&_.jsx("div",{className:"lc-whitespace-pre-wrap",children:h.content}),[pt.Customer,pt.User].includes(h.sender_type)&&_.jsx("div",{className:qt("lc-max-w-[85%] lc-whitespace-pre-wrap lc-border lc-rounded-md lc-px-2 lc-py-1",{"lc-bg-blue-500 lc-text-white":h.sender_type===pt.Customer,"lc-bg-zink-500 lc-text-white":h.sender_type===pt.User}),children:h.content}),h.sender_type===pt.Activity&&(h.content.split("_").length===3?_.jsxs("div",{className:"lc-whitespace-pre-wrap lc-border lc-rounded-md lc-px-2 lc-py-1 lc-text-xs",children:[h.content.split("_")[2]," odaya katıldı"]}):h.content),pt.System===h.sender_type&&_.jsx("div",{className:"lc-text-xs lc-text-neutral-400",children:h.created_at.toLocaleString()})]},h.id||v)),t&&_.jsx("div",{className:"lc-flex lc-w-full lc-items-center lc-justify-start",children:_.jsx("div",{className:"lc-h-full lc-flex lc-items-center lc-animate-pulse",children:_.jsx(Ve.MessageTyping,{})})}),!i&&_.jsx("div",{className:"lc-fixed lc-bottom-[7.5rem] lc-right-16",children:_.jsx(Gs,{type:"button",className:"lc-size-10 lc-flex lc-items-center lc-justify-center lc-!p-0",onClick:()=>{var h,v;(v=r.current)==null||v.scrollTo({top:(h=r.current)==null?void 0:h.scrollHeight,behavior:"smooth"})},children:_.jsx(Ve.ArrowDown,{className:"lc-size-5"})})}),_.jsx("div",{ref:n})]})}function vO({children:e}){const{widget:t}=yr();return t?_.jsx("section",{className:"lc-h-full lc-w-full lc-relative",children:e}):null}function wO({children:e}){const t=uo();return b.useEffect(()=>{t&&t.connect()},[]),!t||!t.connected?null:e}function xO(){const{widget:e,setOpen:t}=yr(),n=uo(),r=td(),[i,s]=b.useState(null),[o,l]=b.useState([]),[a,c]=b.useState(!1),[f,u]=b.useState(!1),[d,h]=b.useState([]),v=()=>{n==null||n.emit(fn.ChatClose,{}),t(!1),s(null),l([]),h([]),zl(e.client_id).then(()=>{n==null||n.disconnect(),r.push("registration")})};b.useEffect(()=>{n==null||n.emit(fn.ChatView,{},S=>{if(S===null){t(!1),zl(e.client_id),l([]),h([]),r.push("registration");return}s(S)})},[]);const w=b.useCallback(S=>{l([...o,S])},[o]);return b.useEffect(()=>{if(n)return n.on(Qt.MessageAgentCreate,S=>{const m={content:S.content,created_at:S.created_at,files:S.files,id:S._id,sender_type:S.sender_type,answers:S.answers,reply_id:S.reply_id};if(d.length>0){h(p=>[...p,m]);return}S.is_shortcut?h([m]):w(m)}),n.on(Qt.ChatUserAssignee,S=>{s({...i,agent_name:S.name,agent_avatar:S.avatar,is_uploadable:(i==null?void 0:i.is_uploadable)??!1}),w({content:` _ _${S.name}`,created_at:new Date,files:[],id:Math.random().toString(),sender_type:pt.Activity,activity_type:nv.AdminJoin,sender_name:S.name})}),n.on(Qt.MessageAgentTyping,()=>{c(!0)}),()=>{n.off(Qt.MessageAgentCreate),n.off(Qt.ChatUserAssignee),n.off(Qt.MessageAgentTyping)}},[w]),b.useEffect(()=>{n&&n.emit(fn.MessageList,{},S=>{l(S)})},[]),b.useEffect(()=>{const S=setTimeout(()=>{c(!1)},2e3);return()=>clearTimeout(S)},[a]),b.useEffect(()=>{if(!e||d.length===0)return;const S=(e.writing_timeout||650)*d[0].content.split(" ").length,m=setTimeout(()=>{w(d[0]),h(d.slice(1))},S);return()=>clearTimeout(m)},[d,e]),i?_.jsxs(_.Fragment,{children:[f&&_.jsx("div",{className:"lc-absolute lc-top-0 lc-left-0 lc-backdrop-blur-sm lc-bg-slate-950/20 lc-z-50 lc-h-full lc-w-full lc-rounded-md",children:_.jsx("div",{className:"lc-flex lc-flex-col lc-items-center lc-justify-center lc-h-full lc-mx-5",children:_.jsxs("div",{className:"lc-bg-white lc-p-4 lc-rounded-md",children:[_.jsx("div",{className:"lc-text-lg lc-font-semibold lc-text-neutral-900",children:"Sohbeti kapatmak istediğinize emin misiniz?"}),_.jsxs("div",{className:"lc-flex lc-justify-between lc-mt-4",children:[_.jsx("button",{type:"button",className:"lc-bg-red-500 lc-text-white lc-px-4 lc-py-2 lc-rounded-md",onClick:v,children:"Evet"}),_.jsx("button",{type:"button",className:"lc-bg-neutral-200 lc-text-neutral-900 lc-px-4 lc-py-2 lc-rounded-md",onClick:()=>u(!1),children:"Vazgeç"})]})]})})}),_.jsxs("section",{className:"lc-bg-white lc-h-full lc-w-full lc-rounded-md lc-border lc-flex lc-flex-col",children:[_.jsxs("header",{className:"lc-border-b lc-p-4 lc-bg-zink-600 lc-rounded-t-md lc-flex lc-justify-between lc-items-center",children:[i!=null&&i.agent_name?_.jsx(pO,{name:i.agent_name,avatar:i.agent_avatar,className:"lc-text-neutral-300"}):_.jsx("div",{className:"lc-text-white",children:"Chat with us"}),_.jsx("button",{type:"button",className:"lc-text-white",onClick:()=>u(!0),children:_.jsx(Ve.X,{className:"lc-w-6 lc-h-6 lc-cursor-pointer"})})]}),_.jsx(gO,{messages:o,isTyping:a||d.length>0}),_.jsx(yO,{onNewMessage:S=>{w(S)}})]})]}):null}function SO(){return uO(),null}function bO(){return _.jsxs(wO,{children:[_.jsx(lg,{defaultOpen:!0,children:_.jsx(vO,{children:_.jsx(xO,{})})}),_.jsx(SO,{})]})}const EO=[{path:"/chat",component:bO,name:"chat"}],rv=[...EO],iv=[...hO],_O=[...rv,...iv];function kO(){return _.jsx(kS,{future:{v7_startTransition:!0},children:_.jsxs(TS,{children:[rv.map((e,t)=>_.jsx(Oc,{path:e.path,element:_.jsx(e.component,{})},t)),iv.map((e,t)=>_.jsx(Oc,{path:e.path,element:_.jsx(e.component,{})},t))]})})}function CO({link_id:e,defaultValues:t}){const{setWidget:n,widget:r,setDefaultValues:i}=yr(),{data:s,isLoading:o}=Nx(e);return b.useEffect(()=>{Array.isArray(s)&&Ax(s[0])&&(n(s[0]),i(t))},[s]),o||!r?null:_.jsx(XT,{children:_.jsx(Xb,{children:_.jsx(kO,{})})})}const TO=new fx;function OO({container:e,link_id:t,defaultValues:n}){my(e).render(_.jsxs(yx,{client:TO,children:[_.jsx(CO,{link_id:t,defaultValues:n}),_.jsx(VT,{richColors:!0,style:{zIndex:999999},position:"bottom-right"})]}))}window.widget=OO});export default RO();