PageSourceSearch

https://newise.xyz/assets/index-B1Xt8zKp.js

js newise.xyz collected 2026-10-09 22:02:39 UTC 737,169 bytes, 317 lines download raw bytes

vendor: 4,560 bytes, lines 1-10
1const __vite__mapDeps=(i,m=__vite__mapDeps,d=(m.f||(m.f=["assets/Index-BcxNMWW1.js","assets/tabs-JhkjU6zU.js","assets/input-DdyH9haq.js","assets/progress-BzIieGW0.js","assets/crown-DkS1Gb-X.js","assets/Index-BSTcku12.css","assets/AdminPage-DGzUojCU.js","assets/circle-help-DUOrYbyQ.js","assets/EnrollPage-DTIfrvOV.js","assets/OnboardingPage-Ddepqmy8.js"])))=>i.map(i=>d[i]);
2var rk=Object.defineProperty;var Cv=t=>{throw TypeError(t)};var sk=(t,e,n)=>e in t?rk(t,e,{enumerable:!0,configurable:!0,writable:!0,value:n}):t[e]=n;var br=(t,e,n)=>sk(t,typeof e!="symbol"?e+"":e,n),Mh=(t,e,n)=>e.has(t)||Cv("Cannot "+n);var O=(t,e,n)=>(Mh(t,e,"read from private field"),n?n.call(t):e.get(t)),be=(t,e,n)=>e.has(t)?Cv("Cannot add the same private member more than once"):e instanceof WeakSet?e.add(t):e.set(t,n),se=(t,e,n,r)=>(Mh(t,e,"write to private field"),r?r.call(t,n):e.set(t,n),n),Re=(t,e,n)=>(Mh(t,e,"access private method"),n);var Lu=(t,e,n,r)=>({set _(o){se(t,e,o,n)},get _(){return O(t,e,r)}});function ik(t,e){for(var n=0;n<e.length;n++){const r=e[n];if(typeof r!="string"&&!Array.isArray(r)){for(const o in r)if(o!=="default"&&!(o in t)){const a=Object.getOwnPropertyDescriptor(r,o);a&&Object.defineProperty(t,o,a.get?a:{enumerable:!0,get:()=>r[o]})}}}return Object.freeze(Object.defineProperty(t,Symbol.toStringTag,{value:"Module"}))}(function(){const e=document.createElement("link").relList;if(e&&e.supports&&e.supports("modulepreload"))return;for(const o of document.querySelectorAll('link[rel="modulepreload"]'))r(o);new MutationObserver(o=>{for(const a of o)if(a.type==="childList")for(const l of a.addedNodes)l.tagName==="LINK"&&l.rel==="modulepreload"&&r(l)}).observe(document,{childList:!0,subtree:!0});function n(o){const a={};return o.integrity&&(a.integrity=o.integrity),o.referrerPolicy&&(a.referrerPolicy=o.referrerPolicy),o.crossOrigin==="use-credentials"?a.credentials="include":o.crossOrigin==="anonymous"?a.credentials="omit":a.credentials="same-origin",a}function r(o){if(o.ep)return;o.ep=!0;const a=n(o);fetch(o.href,a)}})();var n$=typeof globalThis<"u"?globalThis:typeof window<"u"?window:typeof global<"u"?global:typeof self<"u"?self:{};function ul(t){return t&&t.__esModule&&Object.prototype.hasOwnProperty.call(t,"default")?t.default:t}var $h={exports:{}},ba={},Fh={exports:{}},Pe={};/**
3 * @license React
4 * react.production.min.js
5 *
6 * Copyright (c) Facebook, Inc. and its affiliates.
7 *
8 * This source code is licensed under the MIT license found in the
9 * LICENSE file in the root directory of this source tree.
10 */var Pv;function ok(){if(Pv)return Pe;Pv=1;var t=Symbol.for("react.element"),e=Symbol.for("react.portal"),n=Symbol.for("react.fragment"),r=Symbol.for("react.strict_mode"),o=Symbol.for("react.profiler"),a=Symbol.for("react.provider"),l=Symbol.for("react.context"),c=Symbol.for("react.forward_ref"),d=Symbol.for("react.suspense"),f=Symbol.for("react.memo"),p=Symbol.for("react.lazy"),g=Symbol.iterator;function x(N){return N===null||typeof N!="object"?null:(N=g&&N[g]||N["@@iterator"],typeof N=="function"?N:null)}var y={isMounted:function(){return!1},enqueueForceUpdate:function(){},enqueueReplaceState:function(){},enqueueSetState:function(){}},_=Object.assign,S={};function b(N,B,ne){this.props=N,this.context=B,this.refs=S,this.updater=ne||y}b.prototype.isReactComponent={},b.prototype.setState=function(N,B){if(typeof N!="object"&&typeof N!="function"&&N!=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,N,B,"setState")},b.prototype.forceUpdate=function(N){this.updater.enqueueForceUpdate(this,N,"forceUpdate")};function k(){}k.prototype=b.prototype;function P(N,B,ne){this.props=N,this.context=B,this.refs=S,this.updater=ne||y}var C=P.prototype=new k;C.constructor=P,_(C,b.prototype),C.isPureReactComponent=!0;var A=Array.isArray,L=Object.prototype.hasOwnProperty,D={current:null},V={key:!0,ref:!0,__self:!0,__source:!0};function z(N,B,ne){var oe,_e={},ke=null,ye=null;if(B!=null)for(oe in B.ref!==void 0&&(ye=B.ref),B.key!==void 0&&(ke=""+B.key),B)L.call(B,oe)&&!V.hasOwnProperty(oe)&&(_e[oe]=B[oe]);var Ae=arguments.length-2;if(Ae===1)_e.children=ne;else if(1<Ae){for(var Ne=Array(Ae),et=0;et<Ae;et++)Ne[et]=arguments[et+2];_e.children=Ne}if(N&&N.defaultProps)for(oe in Ae=N.defaultProps,Ae)_e[oe]===void 0&&(_e[oe]=Ae[oe]);return{$$typeof:t,type:N,key:ke,ref:ye,props:_e,_owner:D.current}}function q(N,B){return{$$typeof:t,type:N.type,key:B,ref:N.ref,props:N.props,_owner:N._owner}}
vendor: 11,563 bytes, lines 10-34
10function H(N){return typeof N=="object"&&N!==null&&N.$$typeof===t}function te(N){var B={"=":"=0",":":"=2"};return"$"+N.replace(/[=:]/g,function(ne){return B[ne]})}var Z=/\/+/g;function me(N,B){return typeof N=="object"&&N!==null&&N.key!=null?te(""+N.key):B.toString(36)}function J(N,B,ne,oe,_e){var ke=typeof N;(ke==="undefined"||ke==="boolean")&&(N=null);var ye=!1;if(N===null)ye=!0;else switch(ke){case"string":case"number":ye=!0;break;case"object":switch(N.$$typeof){case t:case e:ye=!0}}if(ye)return ye=N,_e=_e(ye),N=oe===""?"."+me(ye,0):oe,A(_e)?(ne="",N!=null&&(ne=N.replace(Z,"$&/")+"/"),J(_e,B,ne,"",function(et){return et})):_e!=null&&(H(_e)&&(_e=q(_e,ne+(!_e.key||ye&&ye.key===_e.key?"":(""+_e.key).replace(Z,"$&/")+"/")+N)),B.push(_e)),1;if(ye=0,oe=oe===""?".":oe+":",A(N))for(var Ae=0;Ae<N.length;Ae++){ke=N[Ae];var Ne=oe+me(ke,Ae);ye+=J(ke,B,ne,Ne,_e)}else if(Ne=x(N),typeof Ne=="function")for(N=Ne.call(N),Ae=0;!(ke=N.next()).done;)ke=ke.value,Ne=oe+me(ke,Ae++),ye+=J(ke,B,ne,Ne,_e);else if(ke==="object")throw B=String(N),Error("Objects are not valid as a React child (found: "+(B==="[object Object]"?"object with keys {"+Object.keys(N).join(", ")+"}":B)+"). If you meant to render a collection of children, use an array instead.");return ye}function fe(N,B,ne){if(N==null)return N;var oe=[],_e=0;return J(N,oe,"","",function(ke){return B.call(ne,ke,_e++)}),oe}function ie(N){if(N._status===-1){var B=N._result;B=B(),B.then(function(ne){(N._status===0||N._status===-1)&&(N._status=1,N._result=ne)},function(ne){(N._status===0||N._status===-1)&&(N._status=2,N._result=ne)}),N._status===-1&&(N._status=0,N._result=B)}if(N._status===1)return N._result.default;throw N._result}var de={current:null},U={transition:null},W={ReactCurrentDispatcher:de,ReactCurrentBatchConfig:U,ReactCurrentOwner:D};function G(){throw Error("act(...) is not supported in production builds of React.")}return Pe.Children={map:fe,forEach:function(N,B,ne){fe(N,function(){B.apply(this,arguments)},ne)},count:function(N){var B=0;return fe(N,function(){B++}),B},toArray:function(N){return fe(N,function(B){return B})||[]},only:function(N){if(!H(N))throw Error("React.Children.only expected to receive a single React element child.");return N}},Pe.Component=b,Pe.Fragment=n,Pe.Profiler=o,Pe.PureComponent=P,Pe.StrictMode=r,Pe.Suspense=d,Pe.__SECRET_INTERNALS_DO_NOT_USE_OR_YOU_WILL_BE_FIRED=W,Pe.act=G,Pe.cloneElement=function(N,B,ne){if(N==null)throw Error("React.cloneElement(...): The argument must be a React element, but you passed "+N+".");var oe=_({},N.props),_e=N.key,ke=N.ref,ye=N._owner;if(B!=null){if(B.ref!==void 0&&(ke=B.ref,ye=D.current),B.key!==void 0&&(_e=""+B.key),N.type&&N.type.defaultProps)var Ae=N.type.defaultProps;for(Ne in B)L.call(B,Ne)&&!V.hasOwnProperty(Ne)&&(oe[Ne]=B[Ne]===void 0&&Ae!==void 0?Ae[Ne]:B[Ne])}var Ne=arguments.length-2;if(Ne===1)oe.children=ne;else if(1<Ne){Ae=Array(Ne);for(var et=0;et<Ne;et++)Ae[et]=arguments[et+2];oe.children=Ae}return{$$typeof:t,type:N.type,key:_e,ref:ke,props:oe,_owner:ye}},Pe.createContext=function(N){return N={$$typeof:l,_currentValue:N,_currentValue2:N,_threadCount:0,Provider:null,Consumer:null,_defaultValue:null,_globalName:null},N.Provider={$$typeof:a,_context:N},N.Consumer=N},Pe.createElement=z,Pe.createFactory=function(N){var B=z.bind(null,N);return B.type=N,B},Pe.createRef=function(){return{current:null}},Pe.forwardRef=function(N){return{$$typeof:c,render:N}},Pe.isValidElement=H,Pe.lazy=function(N){return{$$typeof:p,_payload:{_status:-1,_result:N},_init:ie}},Pe.memo=function(N,B){return{$$typeof:f,type:N,compare:B===void 0?null:B}},Pe.startTransition=function(N){var B=U.transition;U.transition={};try{N()}finally{U.transition=B}},Pe.unstable_act=G,Pe.useCallback=function(N,B){return de.current.useCallback(N,B)},Pe.useContext=function(N){return de.current.useContext(N)},Pe.useDebugValue=function(){},Pe.useDeferredValue=function(N){return de.current.useDeferredValue(N)},Pe.useEffect=function(N,B){return de.current.useEffect(N,B)},Pe.useId=function(){return de.current.useId()},Pe.useImperativeHandle=function(N,B,ne){return de.current.useImperativeHandle(N,B,ne)},Pe.useInsertionEffect=function(N,B){return de.current.useInsertionEffect(N,B)},Pe.useLayoutEffect=function(N,B){return de.current.useLayoutEffect(N,B)},Pe.useMemo=function(N,B){return de.current.useMemo(N,B)},Pe.useReducer=function(N,B,ne){return de.current.useReducer(N,B,ne)},Pe.useRef=function(N){return de.current.useRef(N)},Pe.useState=function(N){return de.current.useState(N)},Pe.useSyncExternalStore=function(N,B,ne){return de.current.useSyncExternalStore(N,B,ne)},Pe.useTransition=function(){return de.current.useTransition()},Pe.version="18.3.1",Pe}var Av;function qp(){return Av||(Av=1,Fh.exports=ok()),Fh.exports}/**
11 * @license React
12 * react-jsx-runtime.production.min.js
13 *
14 * Copyright (c) Facebook, Inc. and its affiliates.
15 *
16 * This source code is licensed under the MIT license found in the
17 * LICENSE file in the root directory of this source tree.
18 */var Rv;function ak(){if(Rv)return ba;Rv=1;var t=qp(),e=Symbol.for("react.element"),n=Symbol.for("react.fragment"),r=Object.prototype.hasOwnProperty,o=t.__SECRET_INTERNALS_DO_NOT_USE_OR_YOU_WILL_BE_FIRED.ReactCurrentOwner,a={key:!0,ref:!0,__self:!0,__source:!0};function l(c,d,f){var p,g={},x=null,y=null;f!==void 0&&(x=""+f),d.key!==void 0&&(x=""+d.key),d.ref!==void 0&&(y=d.ref);for(p in d)r.call(d,p)&&!a.hasOwnProperty(p)&&(g[p]=d[p]);if(c&&c.defaultProps)for(p in d=c.defaultProps,d)g[p]===void 0&&(g[p]=d[p]);return{$$typeof:e,type:c,key:x,ref:y,props:g,_owner:o.current}}return ba.Fragment=n,ba.jsx=l,ba.jsxs=l,ba}var jv;function lk(){return jv||(jv=1,$h.exports=ak()),$h.exports}var v=lk(),Du={},Uh={exports:{}},zt={},Vh={exports:{}},Bh={};/**
19 * @license React
20 * scheduler.production.min.js
21 *
22 * Copyright (c) Facebook, Inc. and its affiliates.
23 *
24 * This source code is licensed under the MIT license found in the
25 * LICENSE file in the root directory of this source tree.
26 */var Ov;function uk(){return Ov||(Ov=1,(function(t){function e(U,W){var G=U.length;U.push(W);e:for(;0<G;){var N=G-1>>>1,B=U[N];if(0<o(B,W))U[N]=W,U[G]=B,G=N;else break e}}function n(U){return U.length===0?null:U[0]}function r(U){if(U.length===0)return null;var W=U[0],G=U.pop();if(G!==W){U[0]=G;e:for(var N=0,B=U.length,ne=B>>>1;N<ne;){var oe=2*(N+1)-1,_e=U[oe],ke=oe+1,ye=U[ke];if(0>o(_e,G))ke<B&&0>o(ye,_e)?(U[N]=ye,U[ke]=G,N=ke):(U[N]=_e,U[oe]=G,N=oe);else if(ke<B&&0>o(ye,G))U[N]=ye,U[ke]=G,N=ke;else break e}}return W}function o(U,W){var G=U.sortIndex-W.sortIndex;return G!==0?G:U.id-W.id}if(typeof performance=="object"&&typeof performance.now=="function"){var a=performance;t.unstable_now=function(){return a.now()}}else{var l=Date,c=l.now();t.unstable_now=function(){return l.now()-c}}var d=[],f=[],p=1,g=null,x=3,y=!1,_=!1,S=!1,b=typeof setTimeout=="function"?setTimeout:null,k=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 C(U){for(var W=n(f);W!==null;){if(W.callback===null)r(f);else if(W.startTime<=U)r(f),W.sortIndex=W.expirationTime,e(d,W);else break;W=n(f)}}function A(U){if(S=!1,C(U),!_)if(n(d)!==null)_=!0,ie(L);else{var W=n(f);W!==null&&de(A,W.startTime-U)}}function L(U,W){_=!1,S&&(S=!1,k(z),z=-1),y=!0;var G=x;try{for(C(W),g=n(d);g!==null&&(!(g.expirationTime>W)||U&&!te());){var N=g.callback;if(typeof N=="function"){g.callback=null,x=g.priorityLevel;var B=N(g.expirationTime<=W);W=t.unstable_now(),typeof B=="function"?g.callback=B:g===n(d)&&r(d),C(W)}else r(d);g=n(d)}if(g!==null)var ne=!0;else{var oe=n(f);oe!==null&&de(A,oe.startTime-W),ne=!1}return ne}finally{g=null,x=G,y=!1}}var D=!1,V=null,z=-1,q=5,H=-1;function te(){return!(t.unstable_now()-H<q)}function Z(){if(V!==null){var U=t.unstable_now();H=U;var W=!0;try{W=V(!0,U)}finally{W?me():(D=!1,V=null)}}else D=!1}var me;if(typeof P=="function")me=function(){P(Z)};else if(typeof MessageChannel<"u"){var J=new MessageChannel,fe=J.port2;J.port1.onmessage=Z,me=function(){fe.postMessage(null)}}else me=function(){b(Z,0)};function ie(U){V=U,D||(D=!0,me())}function de(U,W){z=b(function(){U(t.unstable_now())},W)}t.unstable_IdlePriority=5,t.unstable_ImmediatePriority=1,t.unstable_LowPriority=4,t.unstable_NormalPriority=3,t.unstable_Profiling=null,t.unstable_UserBlockingPriority=2,t.unstable_cancelCallback=function(U){U.callback=null},t.unstable_continueExecution=function(){_||y||(_=!0,ie(L))},t.unstable_forceFrameRate=function(U){0>U||125<U?console.error("forceFrameRate takes a positive int between 0 and 125, forcing frame rates higher than 125 fps is not supported"):q=0<U?Math.floor(1e3/U):5},t.unstable_getCurrentPriorityLevel=function(){return x},t.unstable_getFirstCallbackNode=function(){return n(d)},t.unstable_next=function(U){switch(x){case 1:case 2:case 3:var W=3;break;default:W=x}var G=x;x=W;try{return U()}finally{x=G}},t.unstable_pauseExecution=function(){},t.unstable_requestPaint=function(){},t.unstable_runWithPriority=function(U,W){switch(U){case 1:case 2:case 3:case 4:case 5:break;default:U=3}var G=x;x=U;try{return W()}finally{x=G}},t.unstable_scheduleCallback=function(U,W,G){var N=t.unstable_now();switch(typeof G=="object"&&G!==null?(G=G.delay,G=typeof G=="number"&&0<G?N+G:N):G=N,U){case 1:var B=-1;break;case 2:B=250;break;case 5:B=1073741823;break;case 4:B=1e4;break;default:B=5e3}return B=G+B,U={id:p++,callback:W,priorityLevel:U,startTime:G,expirationTime:B,sortIndex:-1},G>N?(U.sortIndex=G,e(f,U),n(d)===null&&U===n(f)&&(S?(k(z),z=-1):S=!0,de(A,G-N))):(U.sortIndex=B,e(d,U),_||y||(_=!0,ie(L))),U},t.unstable_shouldYield=te,t.unstable_wrapCallback=function(U){var W=x;return function(){var G=x;x=W;try{return U.apply(this,arguments)}finally{x=G}}}})(Bh)),Bh}var Nv;function ck(){return Nv||(Nv=1,Vh.exports=uk()),Vh.exports}/**
27 * @license React
28 * react-dom.production.min.js
29 *
30 * Copyright (c) Facebook, Inc. and its affiliates.
31 *
32 * This source code is licensed under the MIT license found in the
33 * LICENSE file in the root directory of this source tree.
34 */var Iv;function dk(){if(Iv)return zt;Iv=1;var t=qp(),e=ck();function n(s){for(var i="https://reactjs.org/docs/error-decoder.html?invariant="+s,u=1;u<arguments.length;u++)i+="&args[]="+encodeURIComponent(arguments[u]);return"Minified React error #"+s+"; visit "+i+" for the full message or use the non-minified dev environment for full errors and additional helpful warnings."}var r=new Set,o={};function a(s,i){l(s,i),l(s+"Capture",i)}function l(s,i){for(o[s]=i,s=0;s<i.length;s++)r.add(i[s])}var c=!(typeof window>"u"||typeof window.document>"u"||typeof window.document.createElement>"u"),d=Object.prototype.hasOwnProperty,f=/^[: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]*$/,p={},g={};function x(s){return d.call(g,s)?!0:d.call(p,s)?!1:f.test(s)?g[s]=!0:(p[s]=!0,!1)}function y(s,i,u,h){if(u!==null&&u.type===0)return!1;switch(typeof i){case"function":case"symbol":return!0;case"boolean":return h?!1:u!==null?!u.acceptsBooleans:(s=s.toLowerCase().slice(0,5),s!=="data-"&&s!=="aria-");default:return!1}}function _(s,i,u,h){if(i===null||typeof i>"u"||y(s,i,u,h))return!0;
vendor: 48,261 bytes, lines 34-39
34if(h)return!1;if(u!==null)switch(u.type){case 3:return!i;case 4:return i===!1;case 5:return isNaN(i);case 6:return isNaN(i)||1>i}return!1}function S(s,i,u,h,m,w,T){this.acceptsBooleans=i===2||i===3||i===4,this.attributeName=h,this.attributeNamespace=m,this.mustUseProperty=u,this.propertyName=s,this.type=i,this.sanitizeURL=w,this.removeEmptyString=T}var b={};"children dangerouslySetInnerHTML defaultValue defaultChecked innerHTML suppressContentEditableWarning suppressHydrationWarning style".split(" ").forEach(function(s){b[s]=new S(s,0,!1,s,null,!1,!1)}),[["acceptCharset","accept-charset"],["className","class"],["htmlFor","for"],["httpEquiv","http-equiv"]].forEach(function(s){var i=s[0];b[i]=new S(i,1,!1,s[1],null,!1,!1)}),["contentEditable","draggable","spellCheck","value"].forEach(function(s){b[s]=new S(s,2,!1,s.toLowerCase(),null,!1,!1)}),["autoReverse","externalResourcesRequired","focusable","preserveAlpha"].forEach(function(s){b[s]=new S(s,2,!1,s,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(s){b[s]=new S(s,3,!1,s.toLowerCase(),null,!1,!1)}),["checked","multiple","muted","selected"].forEach(function(s){b[s]=new S(s,3,!0,s,null,!1,!1)}),["capture","download"].forEach(function(s){b[s]=new S(s,4,!1,s,null,!1,!1)}),["cols","rows","size","span"].forEach(function(s){b[s]=new S(s,6,!1,s,null,!1,!1)}),["rowSpan","start"].forEach(function(s){b[s]=new S(s,5,!1,s.toLowerCase(),null,!1,!1)});var k=/[\-:]([a-z])/g;function P(s){return s[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(s){var i=s.replace(k,P);b[i]=new S(i,1,!1,s,null,!1,!1)}),"xlink:actuate xlink:arcrole xlink:role xlink:show xlink:title xlink:type".split(" ").forEach(function(s){var i=s.replace(k,P);b[i]=new S(i,1,!1,s,"http://www.w3.org/1999/xlink",!1,!1)}),["xml:base","xml:lang","xml:space"].forEach(function(s){var i=s.replace(k,P);b[i]=new S(i,1,!1,s,"http://www.w3.org/XML/1998/namespace",!1,!1)}),["tabIndex","crossOrigin"].forEach(function(s){b[s]=new S(s,1,!1,s.toLowerCase(),null,!1,!1)}),b.xlinkHref=new S("xlinkHref",1,!1,"xlink:href","http://www.w3.org/1999/xlink",!0,!1),["src","href","action","formAction"].forEach(function(s){b[s]=new S(s,1,!1,s.toLowerCase(),null,!0,!0)});function C(s,i,u,h){var m=b.hasOwnProperty(i)?b[i]:null;(m!==null?m.type!==0:h||!(2<i.length)||i[0]!=="o"&&i[0]!=="O"||i[1]!=="n"&&i[1]!=="N")&&(_(i,u,m,h)&&(u=null),h||m===null?x(i)&&(u===null?s.removeAttribute(i):s.setAttribute(i,""+u)):m.mustUseProperty?s[m.propertyName]=u===null?m.type===3?!1:"":u:(i=m.attributeName,h=m.attributeNamespace,u===null?s.removeAttribute(i):(m=m.type,u=m===3||m===4&&u===!0?"":""+u,h?s.setAttributeNS(h,i,u):s.setAttribute(i,u))))}var A=t.__SECRET_INTERNALS_DO_NOT_USE_OR_YOU_WILL_BE_FIRED,L=Symbol.for("react.element"),D=Symbol.for("react.portal"),V=Symbol.for("react.fragment"),z=Symbol.for("react.strict_mode"),q=Symbol.for("react.profiler"),H=Symbol.for("react.provider"),te=Symbol.for("react.context"),Z=Symbol.for("react.forward_ref"),me=Symbol.for("react.suspense"),J=Symbol.for("react.suspense_list"),fe=Symbol.for("react.memo"),ie=Symbol.for("react.lazy"),de=Symbol.for("react.offscreen"),U=Symbol.iterator;function W(s){return s===null||typeof s!="object"?null:(s=U&&s[U]||s["@@iterator"],typeof s=="function"?s:null)}var G=Object.assign,N;function B(s){if(N===void 0)try{throw Error()}catch(u){var i=u.stack.trim().match(/\n( *(at )?)/);N=i&&i[1]||""}return`
35`+N+s}var ne=!1;function oe(s,i){if(!s||ne)return"";ne=!0;var u=Error.prepareStackTrace;Error.prepareStackTrace=void 0;try{if(i)if(i=function(){throw Error()},Object.defineProperty(i.prototype,"props",{set:function(){throw Error()}}),typeof Reflect=="object"&&Reflect.construct){try{Reflect.construct(i,[])}catch(F){var h=F}Reflect.construct(s,[],i)}else{try{i.call()}catch(F){h=F}s.call(i.prototype)}else{try{throw Error()}catch(F){h=F}s()}}catch(F){if(F&&h&&typeof F.stack=="string"){for(var m=F.stack.split(`
36`),w=h.stack.split(`
37`),T=m.length-1,R=w.length-1;1<=T&&0<=R&&m[T]!==w[R];)R--;for(;1<=T&&0<=R;T--,R--)if(m[T]!==w[R]){if(T!==1||R!==1)do if(T--,R--,0>R||m[T]!==w[R]){var j=`
38`+m[T].replace(" at new "," at ");return s.displayName&&j.includes("<anonymous>")&&(j=j.replace("<anonymous>",s.displayName)),j}while(1<=T&&0<=R);break}}}finally{ne=!1,Error.prepareStackTrace=u}return(s=s?s.displayName||s.name:"")?B(s):""}function _e(s){switch(s.tag){case 5:return B(s.type);case 16:return B("Lazy");case 13:return B("Suspense");case 19:return B("SuspenseList");case 0:case 2:case 15:return s=oe(s.type,!1),s;case 11:return s=oe(s.type.render,!1),s;case 1:return s=oe(s.type,!0),s;default:return""}}function ke(s){if(s==null)return null;if(typeof s=="function")return s.displayName||s.name||null;if(typeof s=="string")return s;switch(s){case V:return"Fragment";case D:return"Portal";case q:return"Profiler";case z:return"StrictMode";case me:return"Suspense";case J:return"SuspenseList"}if(typeof s=="object")switch(s.$$typeof){case te:return(s.displayName||"Context")+".Consumer";case H:return(s._context.displayName||"Context")+".Provider";case Z:var i=s.render;return s=s.displayName,s||(s=i.displayName||i.name||"",s=s!==""?"ForwardRef("+s+")":"ForwardRef"),s;case fe:return i=s.displayName||null,i!==null?i:ke(s.type)||"Memo";case ie:i=s._payload,s=s._init;try{return ke(s(i))}catch{}}return null}function ye(s){var i=s.type;switch(s.tag){case 24:return"Cache";case 9:return(i.displayName||"Context")+".Consumer";case 10:return(i._context.displayName||"Context")+".Provider";case 18:return"DehydratedFragment";case 11:return s=i.render,s=s.displayName||s.name||"",i.displayName||(s!==""?"ForwardRef("+s+")":"ForwardRef");case 7:return"Fragment";case 5:return i;case 4:return"Portal";case 3:return"Root";case 6:return"Text";case 16:return ke(i);case 8:return i===z?"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 i=="function")return i.displayName||i.name||null;if(typeof i=="string")return i}return null}function Ae(s){switch(typeof s){case"boolean":case"number":case"string":case"undefined":return s;case"object":return s;default:return""}}function Ne(s){var i=s.type;return(s=s.nodeName)&&s.toLowerCase()==="input"&&(i==="checkbox"||i==="radio")}function et(s){var i=Ne(s)?"checked":"value",u=Object.getOwnPropertyDescriptor(s.constructor.prototype,i),h=""+s[i];if(!s.hasOwnProperty(i)&&typeof u<"u"&&typeof u.get=="function"&&typeof u.set=="function"){var m=u.get,w=u.set;return Object.defineProperty(s,i,{configurable:!0,get:function(){return m.call(this)},set:function(T){h=""+T,w.call(this,T)}}),Object.defineProperty(s,i,{enumerable:u.enumerable}),{getValue:function(){return h},setValue:function(T){h=""+T},stopTracking:function(){s._valueTracker=null,delete s[i]}}}}function Gt(s){s._valueTracker||(s._valueTracker=et(s))}function dr(s){if(!s)return!1;var i=s._valueTracker;if(!i)return!0;var u=i.getValue(),h="";return s&&(h=Ne(s)?s.checked?"true":"false":s.value),s=h,s!==u?(i.setValue(s),!0):!1}function Qt(s){if(s=s||(typeof document<"u"?document:void 0),typeof s>"u")return null;try{return s.activeElement||s.body}catch{return s.body}}function Nr(s,i){var u=i.checked;return G({},i,{defaultChecked:void 0,defaultValue:void 0,value:void 0,checked:u??s._wrapperState.initialChecked})}function wi(s,i){var u=i.defaultValue==null?"":i.defaultValue,h=i.checked!=null?i.checked:i.defaultChecked;u=Ae(i.value!=null?i.value:u),s._wrapperState={initialChecked:h,initialValue:u,controlled:i.type==="checkbox"||i.type==="radio"?i.checked!=null:i.value!=null}}function Cs(s,i){i=i.checked,i!=null&&C(s,"checked",i,!1)}function Ps(s,i){Cs(s,i);var u=Ae(i.value),h=i.type;if(u!=null)h==="number"?(u===0&&s.value===""||s.value!=u)&&(s.value=""+u):s.value!==""+u&&(s.value=""+u);else if(h==="submit"||h==="reset"){s.removeAttribute("value");return}i.hasOwnProperty("value")?zn(s,i.type,u):i.hasOwnProperty("defaultValue")&&zn(s,i.type,Ae(i.defaultValue)),i.checked==null&&i.defaultChecked!=null&&(s.defaultChecked=!!i.defaultChecked)}function Ir(s,i,u){if(i.hasOwnProperty("value")||i.hasOwnProperty("defaultValue")){var h=i.type;if(!(h!=="submit"&&h!=="reset"||i.value!==void 0&&i.value!==null))return;i=""+s._wrapperState.initialValue,u||i===s.value||(s.value=i),s.defaultValue=i}u=s.name,u!==""&&(s.name=""),s.defaultChecked=!!s._wrapperState.initialChecked,u!==""&&(s.name=u)}function zn(s,i,u){(i!=="number"||Qt(s.ownerDocument)!==s)&&(u==null?s.defaultValue=""+s._wrapperState.initialValue:s.defaultValue!==""+u&&(s.defaultValue=""+u))}var Lr=Array.isArray;function on(s,i,u,h){if(s=s.options,i){i={};for(var m=0;m<u.length;m++)i["$"+u[m]]=!0;for(u=0;u<s.length;u++)m=i.hasOwnProperty("$"+s[u].value),s[u].selected!==m&&(s[u].selected=m),m&&h&&(s[u].defaultSelected=!0)}else{for(u=""+Ae(u),i=null,m=0;m<s.length;m++){if(s[m].value===u){s[m].selected=!0,h&&(s[m].defaultSelected=!0);return}i!==null||s[m].disabled||(i=s[m])}i!==null&&(i.selected=!0)}}function xi(s,i){if(i.dangerouslySetInnerHTML!=null)throw Error(n(91));return G({},i,{value:void 0,defaultValue:void 0,children:""+s._wrapperState.initialValue})}function Wn(s,i){var u=i.value;if(u==null){if(u=i.children,i=i.defaultValue,u!=null){if(i!=null)throw Error(n(92));if(Lr(u)){if(1<u.length)throw Error(n(93));u=u[0]}i=u}i==null&&(i=""),u=i}s._wrapperState={initialValue:Ae(u)}}function Sl(s,i){var u=Ae(i.value),h=Ae(i.defaultValue);u!=null&&(u=""+u,u!==s.value&&(s.value=u),i.defaultValue==null&&s.defaultValue!==u&&(s.defaultValue=u)),h!=null&&(s.defaultValue=""+h)}function _l(s){var i=s.textContent;i===s._wrapperState.initialValue&&i!==""&&i!==null&&(s.value=i)}function At(s){switch(s){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 Hn(s,i){return s==null||s==="http://www.w3.org/1999/xhtml"?At(i):s==="http://www.w3.org/2000/svg"&&i==="foreignObject"?"http://www.w3.org/1999/xhtml":s}var bi,El=(function(s){return typeof MSApp<"u"&&MSApp.execUnsafeLocalFunction?function(i,u,h,m){MSApp.execUnsafeLocalFunction(function(){return s(i,u,h,m)})}:s})(function(s,i){if(s.namespaceURI!=="http://www.w3.org/2000/svg"||"innerHTML"in s)s.innerHTML=i;else{for(bi=bi||document.createElement("div"),bi.innerHTML="<svg>"+i.valueOf().toString()+"</svg>",i=bi.firstChild;s.firstChild;)s.removeChild(s.firstChild);for(;i.firstChild;)s.appendChild(i.firstChild)}});function qn(s,i){if(i){var u=s.firstChild;if(u&&u===s.lastChild&&u.nodeType===3){u.nodeValue=i;return}}s.textContent=i}var As={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},Tl=["Webkit","ms","Moz","O"];Object.keys(As).forEach(function(s){Tl.forEach(function(i){i=i+s.charAt(0).toUpperCase()+s.substring(1),As[i]=As[s]})});function Si(s,i,u){return i==null||typeof i=="boolean"||i===""?"":u||typeof i!="number"||i===0||As.hasOwnProperty(s)&&As[s]?(""+i).trim():i+"px"}function hr(s,i){s=s.style;for(var u in i)if(i.hasOwnProperty(u)){var h=u.indexOf("--")===0,m=Si(u,i[u],h);u==="float"&&(u="cssFloat"),h?s.setProperty(u,m):s[u]=m}}var kl=G({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 Kn(s,i){if(i){if(kl[s]&&(i.children!=null||i.dangerouslySetInnerHTML!=null))throw Error(n(137,s));if(i.dangerouslySetInnerHTML!=null){if(i.children!=null)throw Error(n(60));if(typeof i.dangerouslySetInnerHTML!="object"||!("__html"in i.dangerouslySetInnerHTML))throw Error(n(61))}if(i.style!=null&&typeof i.style!="object")throw Error(n(62))}}function Fo(s,i){if(s.indexOf("-")===-1)return typeof i.is=="string";switch(s){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 Uo=null;function _i(s){return s=s.target||s.srcElement||window,s.correspondingUseElement&&(s=s.correspondingUseElement),s.nodeType===3?s.parentNode:s}var Ei=null,Dr=null,Gn=null;function wn(s){if(s=oa(s)){if(typeof Ei!="function")throw Error(n(280));var i=s.stateNode;i&&(i=Yl(i),Ei(s.stateNode,s.type,i))}}function Cl(s){Dr?Gn?Gn.push(s):Gn=[s]:Dr=s}function Te(){if(Dr){var s=Dr,i=Gn;if(Gn=Dr=null,wn(s),i)for(s=0;s<i.length;s++)wn(i[s])}}function De(s,i){return s(i)}function Fe(){}var Rt=!1;function Dt(s,i,u){if(Rt)return s(i,u);Rt=!0;try{return De(s,i,u)}finally{Rt=!1,(Dr!==null||Gn!==null)&&(Fe(),Te())}}function Mt(s,i){var u=s.stateNode;if(u===null)return null;var h=Yl(u);if(h===null)return null;u=h[i];e:switch(i){case"onClick":case"onClickCapture":case"onDoubleClick":case"onDoubleClickCapture":case"onMouseDown":case"onMouseDownCapture":case"onMouseMove":case"onMouseMoveCapture":case"onMouseUp":case"onMouseUpCapture":case"onMouseEnter":(h=!h.disabled)||(s=s.type,h=!(s==="button"||s==="input"||s==="select"||s==="textarea")),s=!h;break e;default:s=!1}if(s)return null;if(u&&typeof u!="function")throw Error(n(231,i,typeof u));return u}var xn=!1;if(c)try{var gt={};Object.defineProperty(gt,"passive",{get:function(){xn=!0}}),window.addEventListener("test",gt,gt),window.removeEventListener("test",gt,gt)}catch{xn=!1}function Qn(s,i,u,h,m,w,T,R,j){var F=Array.prototype.slice.call(arguments,3);try{i.apply(u,F)}catch(Y){this.onError(Y)}}var Vo=!1,Pl=null,Al=!1,nd=null,cE={onError:function(s){Vo=!0,Pl=s}};function dE(s,i,u,h,m,w,T,R,j){Vo=!1,Pl=null,Qn.apply(cE,arguments)}function hE(s,i,u,h,m,w,T,R,j){if(dE.apply(this,arguments),Vo){if(Vo){var F=Pl;Vo=!1,Pl=null}else throw Error(n(198));Al||(Al=!0,nd=F)}}function Rs(s){var i=s,u=s;if(s.alternate)for(;i.return;)i=i.return;else{s=i;do i=s,(i.flags&4098)!==0&&(u=i.return),s=i.return;while(s)}return i.tag===3?u:null}function Ym(s){if(s.tag===13){var i=s.memoizedState;if(i===null&&(s=s.alternate,s!==null&&(i=s.memoizedState)),i!==null)return i.dehydrated}return null}function Jm(s){if(Rs(s)!==s)throw Error(n(188))}function fE(s){var i=s.alternate;if(!i){if(i=Rs(s),i===null)throw Error(n(188));return i!==s?null:s}for(var u=s,h=i;;){var m=u.return;if(m===null)break;var w=m.alternate;if(w===null){if(h=m.return,h!==null){u=h;continue}break}if(m.child===w.child){for(w=m.child;w;){if(w===u)return Jm(m),s;if(w===h)return Jm(m),i;w=w.sibling}throw Error(n(188))}if(u.return!==h.return)u=m,h=w;else{for(var T=!1,R=m.child;R;){if(R===u){T=!0,u=m,h=w;break}if(R===h){T=!0,h=m,u=w;break}R=R.sibling}if(!T){for(R=w.child;R;){if(R===u){T=!0,u=w,h=m;break}if(R===h){T=!0,h=w,u=m;break}R=R.sibling}if(!T)throw Error(n(189))}}if(u.alternate!==h)throw Error(n(190))}if(u.tag!==3)throw Error(n(188));return u.stateNode.current===u?s:i}function Xm(s){return s=fE(s),s!==null?Zm(s):null}function Zm(s){if(s.tag===5||s.tag===6)return s;for(s=s.child;s!==null;){var i=Zm(s);if(i!==null)return i;s=s.sibling}return null}var eg=e.unstable_scheduleCallback,tg=e.unstable_cancelCallback,pE=e.unstable_shouldYield,mE=e.unstable_requestPaint,tt=e.unstable_now,gE=e.unstable_getCurrentPriorityLevel,rd=e.unstable_ImmediatePriority,ng=e.unstable_UserBlockingPriority,Rl=e.unstable_NormalPriority,yE=e.unstable_LowPriority,rg=e.unstable_IdlePriority,jl=null,Yn=null;function vE(s){if(Yn&&typeof Yn.onCommitFiberRoot=="function")try{Yn.onCommitFiberRoot(jl,s,void 0,(s.current.flags&128)===128)}catch{}}var bn=Math.clz32?Math.clz32:bE,wE=Math.log,xE=Math.LN2;function bE(s){return s>>>=0,s===0?32:31-(wE(s)/xE|0)|0}var Ol=64,Nl=4194304;function Bo(s){switch(s&-s){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 s&4194240;case 4194304:case 8388608:case 16777216:case 33554432:case 67108864:return s&130023424;case 134217728:return 134217728;case 268435456:return 268435456;case 536870912:return 536870912;case 1073741824:return 1073741824;default:return s}}function Il(s,i){var u=s.pendingLanes;if(u===0)return 0;var h=0,m=s.suspendedLanes,w=s.pingedLanes,T=u&268435455;if(T!==0){var R=T&~m;R!==0?h=Bo(R):(w&=T,w!==0&&(h=Bo(w)))}else T=u&~m,T!==0?h=Bo(T):w!==0&&(h=Bo(w));if(h===0)return 0;if(i!==0&&i!==h&&(i&m)===0&&(m=h&-h,w=i&-i,m>=w||m===16&&(w&4194240)!==0))return i;if((h&4)!==0&&(h|=u&16),i=s.entangledLanes,i!==0)for(s=s.entanglements,i&=h;0<i;)u=31-bn(i),m=1<<u,h|=s[u],i&=~m;return h}function SE(s,i){switch(s){case 1:case 2:case 4:return i+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 i+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 _E(s,i){for(var u=s.suspendedLanes,h=s.pingedLanes,m=s.expirationTimes,w=s.pendingLanes;0<w;){var T=31-bn(w),R=1<<T,j=m[T];j===-1?((R&u)===0||(R&h)!==0)&&(m[T]=SE(R,i)):j<=i&&(s.expiredLanes|=R),w&=~R}}function sd(s){return s=s.pendingLanes&-1073741825,s!==0?s:s&1073741824?1073741824:0}function sg(){var s=Ol;return Ol<<=1,(Ol&4194240)===0&&(Ol=64),s}function id(s){for(var i=[],u=0;31>u;u++)i.push(s);return i}function zo(s,i,u){s.pendingLanes|=i,i!==536870912&&(s.suspendedLanes=0,s.pingedLanes=0),s=s.eventTimes,i=31-bn(i),s[i]=u}function EE(s,i){var u=s.pendingLanes&~i;s.pendingLanes=i,s.suspendedLanes=0,s.pingedLanes=0,s.expiredLanes&=i,s.mutableReadLanes&=i,s.entangledLanes&=i,i=s.entanglements;var h=s.eventTimes;for(s=s.expirationTimes;0<u;){var m=31-bn(u),w=1<<m;i[m]=0,h[m]=-1,s[m]=-1,u&=~w}}function od(s,i){var u=s.entangledLanes|=i;for(s=s.entanglements;u;){var h=31-bn(u),m=1<<h;m&i|s[h]&i&&(s[h]|=i),u&=~m}}var $e=0;function ig(s){return s&=-s,1<s?4<s?(s&268435455)!==0?16:536870912:4:1}var og,ad,ag,lg,ug,ld=!1,Ll=[],Mr=null,$r=null,Fr=null,Wo=new Map,Ho=new Map,Ur=[],TE="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 cg(s,i){switch(s){case"focusin":case"focusout":Mr=null;break;case"dragenter":case"dragleave":$r=null;break;case"mouseover":case"mouseout":Fr=null;break;case"pointerover":case"pointerout":Wo.delete(i.pointerId);break;case"gotpointercapture":case"lostpointercapture":Ho.delete(i.pointerId)}}function qo(s,i,u,h,m,w){return s===null||s.nativeEvent!==w?(s={blockedOn:i,domEventName:u,eventSystemFlags:h,nativeEvent:w,targetContainers:[m]},i!==null&&(i=oa(i),i!==null&&ad(i)),s):(s.eventSystemFlags|=h,i=s.targetContainers,m!==null&&i.indexOf(m)===-1&&i.push(m),s)}function kE(s,i,u,h,m){switch(i){case"focusin":return Mr=qo(Mr,s,i,u,h,m),!0;case"dragenter":return $r=qo($r,s,i,u,h,m),!0;case"mouseover":return Fr=qo(Fr,s,i,u,h,m),!0;case"pointerover":var w=m.pointerId;return Wo.set(w,qo(Wo.get(w)||null,s,i,u,h,m)),!0;case"gotpointercapture":return w=m.pointerId,Ho.set(w,qo(Ho.get(w)||null,s,i,u,h,m)),!0}return!1}function dg(s){var i=js(s.target);if(i!==null){var u=Rs(i);if(u!==null){if(i=u.tag,i===13){if(i=Ym(u),i!==null){s.blockedOn=i,ug(s.priority,function(){ag(u)});return}}else if(i===3&&u.stateNode.current.memoizedState.isDehydrated){s.blockedOn=u.tag===3?u.stateNode.containerInfo:null;return}}}s.blockedOn=null}function Dl(s){if(s.blockedOn!==null)return!1;for(var i=s.targetContainers;0<i.length;){var u=cd(s.domEventName,s.eventSystemFlags,i[0],s.nativeEvent);if(u===null){u=s.nativeEvent;var h=new u.constructor(u.type,u);Uo=h,u.target.dispatchEvent(h),Uo=null}else return i=oa(u),i!==null&&ad(i),s.blockedOn=u,!1;i.shift()}return!0}function hg(s,i,u){Dl(s)&&u.delete(i)}function CE(){ld=!1,Mr!==null&&Dl(Mr)&&(Mr=null),$r!==null&&Dl($r)&&($r=null),Fr!==null&&Dl(Fr)&&(Fr=null),Wo.forEach(hg),Ho.forEach(hg)}function Ko(s,i){s.blockedOn===i&&(s.blockedOn=null,ld||(ld=!0,e.unstable_scheduleCallback(e.unstable_NormalPriority,CE)))}function Go(s){function i(m){return Ko(m,s)}if(0<Ll.length){Ko(Ll[0],s);for(var u=1;u<Ll.length;u++){var h=Ll[u];h.blockedOn===s&&(h.blockedOn=null)}}for(Mr!==null&&Ko(Mr,s),$r!==null&&Ko($r,s),Fr!==null&&Ko(Fr,s),Wo.forEach(i),Ho.forEach(i),u=0;u<Ur.length;u++)h=Ur[u],h.blockedOn===s&&(h.blockedOn=null);for(;0<Ur.length&&(u=Ur[0],u.blockedOn===null);)dg(u),u.blockedOn===null&&Ur.shift()}var Ti=A.ReactCurrentBatchConfig,Ml=!0;function PE(s,i,u,h){var m=$e,w=Ti.transition;Ti.transition=null;try{$e=1,ud(s,i,u,h)}finally{$e=m,Ti.transition=w}}function AE(s,i,u,h){var m=$e,w=Ti.transition;Ti.transition=null;try{$e=4,ud(s,i,u,h)}finally{$e=m,Ti.transition=w}}function ud(s,i,u,h){if(Ml){var m=cd(s,i,u,h);if(m===null)Cd(s,i,h,$l,u),cg(s,h);else if(kE(m,s,i,u,h))h.stopPropagation();else if(cg(s,h),i&4&&-1<TE.indexOf(s)){for(;m!==null;){var w=oa(m);if(w!==null&&og(w),w=cd(s,i,u,h),w===null&&Cd(s,i,h,$l,u),w===m)break;m=w}m!==null&&h.stopPropagation()}else Cd(s,i,h,null,u)}}var $l=null;function cd(s,i,u,h){if($l=null,s=_i(h),s=js(s),s!==null)if(i=Rs(s),i===null)s=null;else if(u=i.tag,u===13){if(s=Ym(i),s!==null)return s;s=null}else if(u===3){if(i.stateNode.current.memoizedState.isDehydrated)return i.tag===3?i.stateNode.containerInfo:null;s=null}else i!==s&&(s=null);return $l=s,null}function fg(s){switch(s){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(gE()){case rd:return 1;case ng:return 4;case Rl:case yE:return 16;case rg:return 536870912;default:return 16}default:return 16}}var Vr=null,dd=null,Fl=null;function pg(){if(Fl)return Fl;var s,i=dd,u=i.length,h,m="value"in Vr?Vr.value:Vr.textContent,w=m.length;for(s=0;s<u&&i[s]===m[s];s++);var T=u-s;for(h=1;h<=T&&i[u-h]===m[w-h];h++);return Fl=m.slice(s,1<h?1-h:void 0)}function Ul(s){var i=s.keyCode;return"charCode"in s?(s=s.charCode,s===0&&i===13&&(s=13)):s=i,s===10&&(s=13),32<=s||s===13?s:0}function Vl(){return!0}function mg(){return!1}function Yt(s){function i(u,h,m,w,T){this._reactName=u,this._targetInst=m,this.type=h,this.nativeEvent=w,this.target=T,this.currentTarget=null;for(var R in s)s.hasOwnProperty(R)&&(u=s[R],this[R]=u?u(w):w[R]);return this.isDefaultPrevented=(w.defaultPrevented!=null?w.defaultPrevented:w.returnValue===!1)?Vl:mg,this.isPropagationStopped=mg,this}return G(i.prototype,{preventDefault:function(){this.defaultPrevented=!0;var u=this.nativeEvent;u&&(u.preventDefault?u.preventDefault():typeof u.returnValue!="unknown"&&(u.returnValue=!1),this.isDefaultPrevented=Vl)},stopPropagation:function(){var u=this.nativeEvent;u&&(u.stopPropagation?u.stopPropagation():typeof u.cancelBubble!="unknown"&&(u.cancelBubble=!0),this.isPropagationStopped=Vl)},persist:function(){},isPersistent:Vl}),i}var ki={eventPhase:0,bubbles:0,cancelable:0,timeStamp:function(s){return s.timeStamp||Date.now()},defaultPrevented:0,isTrusted:0},hd=Yt(ki),Qo=G({},ki,{view:0,detail:0}),RE=Yt(Qo),fd,pd,Yo,Bl=G({},Qo,{screenX:0,screenY:0,clientX:0,clientY:0,pageX:0,pageY:0,ctrlKey:0,shiftKey:0,altKey:0,metaKey:0,getModifierState:gd,button:0,buttons:0,relatedTarget:function(s){return s.relatedTarget===void 0?s.fromElement===s.srcElement?s.toElement:s.fromElement:s.relatedTarget},movementX:function(s){return"movementX"in s?s.movementX:(s!==Yo&&(Yo&&s.type==="mousemove"?(fd=s.screenX-Yo.screenX,pd=s.screenY-Yo.screenY):pd=fd=0,Yo=s),fd)},movementY:function(s){return"movementY"in s?s.movementY:pd}}),gg=Yt(Bl),jE=G({},Bl,{dataTransfer:0}),OE=Yt(jE),NE=G({},Qo,{relatedTarget:0}),md=Yt(NE),IE=G({},ki,{animationName:0,elapsedTime:0,pseudoElement:0}),LE=Yt(IE),DE=G({},ki,{clipboardData:function(s){return"clipboardData"in s?s.clipboardData:window.clipboardData}}),ME=Yt(DE),$E=G({},ki,{data:0}),yg=Yt($E),FE={Esc:"Escape",Spacebar:" ",Left:"ArrowLeft",Up:"ArrowUp",Right:"ArrowRight",Down:"ArrowDown",Del:"Delete",Win:"OS",Menu:"ContextMenu",Apps:"ContextMenu",Scroll:"ScrollLock",MozPrintableKey:"Unidentified"},UE={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"},VE={Alt:"altKey",Control:"ctrlKey",Meta:"metaKey",Shift:"shiftKey"};function BE(s){var i=this.nativeEvent;return i.getModifierState?i.getModifierState(s):(s=VE[s])?!!i[s]:!1}function gd(){return BE}var zE=G({},Qo,{key:function(s){if(s.key){var i=FE[s.key]||s.key;if(i!=="Unidentified")return i}return s.type==="keypress"?(s=Ul(s),s===13?"Enter":String.fromCharCode(s)):s.type==="keydown"||s.type==="keyup"?UE[s.keyCode]||"Unidentified":""},code:0,location:0,ctrlKey:0,shiftKey:0,altKey:0,metaKey:0,repeat:0,locale:0,getModifierState:gd,charCode:function(s){return s.type==="keypress"?Ul(s):0},keyCode:function(s){return s.type==="keydown"||s.type==="keyup"?s.keyCode:0},which:function(s){return s.type==="keypress"?Ul(s):s.type==="keydown"||s.type==="keyup"?s.keyCode:0}}),WE=Yt(zE),HE=G({},Bl,{pointerId:0,width:0,height:0,pressure:0,tangentialPressure:0,tiltX:0,tiltY:0,twist:0,pointerType:0,isPrimary:0}),vg=Yt(HE),qE=G({},Qo,{touches:0,targetTouches:0,changedTouches:0,altKey:0,metaKey:0,ctrlKey:0,shiftKey:0,getModifierState:gd}),KE=Yt(qE),GE=G({},ki,{propertyName:0,elapsedTime:0,pseudoElement:0}),QE=Yt(GE),YE=G({},Bl,{deltaX:function(s){return"deltaX"in s?s.deltaX:"wheelDeltaX"in s?-s.wheelDeltaX:0},deltaY:function(s){return"deltaY"in s?s.deltaY:"wheelDeltaY"in s?-s.wheelDeltaY:"wheelDelta"in s?-s.wheelDelta:0},deltaZ:0,deltaMode:0}),JE=Yt(YE),XE=[9,13,27,32],yd=c&&"CompositionEvent"in window,Jo=null;c&&"documentMode"in document&&(Jo=document.documentMode);var ZE=c&&"TextEvent"in window&&!Jo,wg=c&&(!yd||Jo&&8<Jo&&11>=Jo),xg=" ",bg=!1;function Sg(s,i){switch(s){case"keyup":return XE.indexOf(i.keyCode)!==-1;case"keydown":return i.keyCode!==229;case"keypress":case"mousedown":case"focusout":return!0;default:return!1}}function _g(s){return s=s.detail,typeof s=="object"&&"data"in s?s.data:null}var Ci=!1;function eT(s,i){switch(s){case"compositionend":return _g(i);case"keypress":return i.which!==32?null:(bg=!0,xg);case"textInput":return s=i.data,s===xg&&bg?null:s;default:return null}}function tT(s,i){if(Ci)return s==="compositionend"||!yd&&Sg(s,i)?(s=pg(),Fl=dd=Vr=null,Ci=!1,s):null;switch(s){case"paste":return null;case"keypress":if(!(i.ctrlKey||i.altKey||i.metaKey)||i.ctrlKey&&i.altKey){if(i.char&&1<i.char.length)return i.char;if(i.which)return String.fromCharCode(i.which)}return null;case"compositionend":return wg&&i.locale!=="ko"?null:i.data;default:return null}}var nT={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 Eg(s){var i=s&&s.nodeName&&s.nodeName.toLowerCase();return i==="input"?!!nT[s.type]:i==="textarea"}function Tg(s,i,u,h){Cl(h),i=Kl(i,"onChange"),0<i.length&&(u=new hd("onChange","change",null,u,h),s.push({event:u,listeners:i}))}var Xo=null,Zo=null;function rT(s){zg(s,0)}function zl(s){var i=Oi(s);if(dr(i))return s}function sT(s,i){if(s==="change")return i}var kg=!1;if(c){var vd;if(c){var wd="oninput"in document;if(!wd){var Cg=document.createElement("div");Cg.setAttribute("oninput","return;"),wd=typeof Cg.oninput=="function"}vd=wd}else vd=!1;kg=vd&&(!document.documentMode||9<document.documentMode)}function Pg(){Xo&&(Xo.detachEvent("onpropertychange",Ag),Zo=Xo=null)}function Ag(s){if(s.propertyName==="value"&&zl(Zo)){var i=[];Tg(i,Zo,s,_i(s)),Dt(rT,i)}}function iT(s,i,u){s==="focusin"?(Pg(),Xo=i,Zo=u,Xo.attachEvent("onpropertychange",Ag)):s==="focusout"&&Pg()}function oT(s){if(s==="selectionchange"||s==="keyup"||s==="keydown")return zl(Zo)}function aT(s,i){if(s==="click")return zl(i)}function lT(s,i){if(s==="input"||s==="change")return zl(i)}function uT(s,i){return s===i&&(s!==0||1/s===1/i)||s!==s&&i!==i}var Sn=typeof Object.is=="function"?Object.is:uT;function ea(s,i){if(Sn(s,i))return!0;if(typeof s!="object"||s===null||typeof i!="object"||i===null)return!1;var u=Object.keys(s),h=Object.keys(i);if(u.length!==h.length)return!1;for(h=0;h<u.length;h++){var m=u[h];if(!d.call(i,m)||!Sn(s[m],i[m]))return!1}return!0}function Rg(s){for(;s&&s.firstChild;)s=s.firstChild;return s}function jg(s,i){var u=Rg(s);s=0;for(var h;u;){if(u.nodeType===3){if(h=s+u.textContent.length,s<=i&&h>=i)return{node:u,offset:i-s};s=h}e:{for(;u;){if(u.nextSibling){u=u.nextSibling;break e}u=u.parentNode}u=void 0}u=Rg(u)}}function Og(s,i){return s&&i?s===i?!0:s&&s.nodeType===3?!1:i&&i.nodeType===3?Og(s,i.parentNode):"contains"in s?s.contains(i):s.compareDocumentPosition?!!(s.compareDocumentPosition(i)&16):!1:!1}function Ng(){for(var s=window,i=Qt();i instanceof s.HTMLIFrameElement;){try{var u=typeof i.contentWindow.location.href=="string"}catch{u=!1}if(u)s=i.contentWindow;else break;i=Qt(s.document)}return i}function xd(s){var i=s&&s.nodeName&&s.nodeName.toLowerCase();return i&&(i==="input"&&(s.type==="text"||s.type==="search"||s.type==="tel"||s.type==="url"||s.type==="password")||i==="textarea"||s.contentEditable==="true")}function cT(s){var i=Ng(),u=s.focusedElem,h=s.selectionRange;if(i!==u&&u&&u.ownerDocument&&Og(u.ownerDocument.documentElement,u)){if(h!==null&&xd(u)){if(i=h.start,s=h.end,s===void 0&&(s=i),"selectionStart"in u)u.selectionStart=i,u.selectionEnd=Math.min(s,u.value.length);else if(s=(i=u.ownerDocument||document)&&i.defaultView||window,s.getSelection){s=s.getSelection();var m=u.textContent.length,w=Math.min(h.start,m);h=h.end===void 0?w:Math.min(h.end,m),!s.extend&&w>h&&(m=h,h=w,w=m),m=jg(u,w);var T=jg(u,h);m&&T&&(s.rangeCount!==1||s.anchorNode!==m.node||s.anchorOffset!==m.offset||s.focusNode!==T.node||s.focusOffset!==T.offset)&&(i=i.createRange(),i.setStart(m.node,m.offset),s.removeAllRanges(),w>h?(s.addRange(i),s.extend(T.node,T.offset)):(i.setEnd(T.node,T.offset),s.addRange(i)))}}for(i=[],s=u;s=s.parentNode;)s.nodeType===1&&i.push({element:s,left:s.scrollLeft,top:s.scrollTop});for(typeof u.focus=="function"&&u.focus(),u=0;u<i.length;u++)s=i[u],s.element.scrollLeft=s.left,s.element.scrollTop=s.top}}var dT=c&&"documentMode"in document&&11>=document.documentMode,Pi=null,bd=null,ta=null,Sd=!1;function Ig(s,i,u){var h=u.window===u?u.document:u.nodeType===9?u:u.ownerDocument;Sd||Pi==null||Pi!==Qt(h)||(h=Pi,"selectionStart"in h&&xd(h)?h={start:h.selectionStart,end:h.selectionEnd}:(h=(h.ownerDocument&&h.ownerDocument.defaultView||window).getSelection(),h={anchorNode:h.anchorNode,anchorOffset:h.anchorOffset,focusNode:h.focusNode,focusOffset:h.focusOffset}),ta&&ea(ta,h)||(ta=h,h=Kl(bd,"onSelect"),0<h.length&&(i=new hd("onSelect","select",null,i,u),s.push({event:i,listeners:h}),i.target=Pi)))}function Wl(s,i){var u={};return u[s.toLowerCase()]=i.toLowerCase(),u["Webkit"+s]="webkit"+i,u["Moz"+s]="moz"+i,u}var Ai={animationend:Wl("Animation","AnimationEnd"),animationiteration:Wl("Animation","AnimationIteration"),animationstart:Wl("Animation","AnimationStart"),transitionend:Wl("Transition","TransitionEnd")},_d={},Lg={};c&&(Lg=document.createElement("div").style,"AnimationEvent"in window||(delete Ai.animationend.animation,delete Ai.animationiteration.animation,delete Ai.animationstart.animation),"TransitionEvent"in window||delete Ai.transitionend.transition);function Hl(s){if(_d[s])return _d[s];if(!Ai[s])return s;var i=Ai[s],u;for(u in i)if(i.hasOwnProperty(u)&&u in Lg)return _d[s]=i[u];return s}var Dg=Hl("animationend"),Mg=Hl("animationiteration"),$g=Hl("animationstart"),Fg=Hl("transitionend"),Ug=new Map,Vg="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 Br(s,i){Ug.set(s,i),a(i,[s])}for(var Ed=0;Ed<Vg.length;Ed++){var Td=Vg[Ed],hT=Td.toLowerCase(),fT=Td[0].toUpperCase()+Td.slice(1);Br(hT,"on"+fT)}Br(Dg,"onAnimationEnd"),Br(Mg,"onAnimationIteration"),Br($g,"onAnimationStart"),Br("dblclick","onDoubleClick"),Br("focusin","onFocus"),Br("focusout","onBlur"),Br(Fg,"onTransitionEnd"),l("onMouseEnter",["mouseout","mouseover"]),l("onMouseLeave",["mouseout","mouseover"]),l("onPointerEnter",["pointerout","pointerover"]),l("onPointerLeave",["pointerout","pointerover"]),a("onChange","change click focusin focusout input keydown keyup selectionchange".split(" ")),a("onSelect","focusout contextmenu dragend focusin keydown keyup mousedown mouseup selectionchange".split(" ")),a("onBeforeInput",["compositionend","keypress","textInput","paste"]),a("onCompositionEnd","compositionend focusout keydown keypress keyup mousedown".split(" ")),a("onCompositionStart","compositionstart focusout keydown keypress keyup mousedown".split(" ")),a("onCompositionUpdate","compositionupdate focusout keydown keypress keyup mousedown".split(" "));var na="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(" "),pT=new Set("cancel close invalid load scroll toggle".split(" ").concat(na));function Bg(s,i,u){var h=s.type||"unknown-event";s.currentTarget=u,hE(h,i,void 0,s),s.currentTarget=null}function zg(s,i){i=(i&4)!==0;for(var u=0;u<s.length;u++){var h=s[u],m=h.event;h=h.listeners;e:{var w=void 0;if(i)for(var T=h.length-1;0<=T;T--){var R=h[T],j=R.instance,F=R.currentTarget;if(R=R.listener,j!==w&&m.isPropagationStopped())break e;Bg(m,R,F),w=j}else for(T=0;T<h.length;T++){if(R=h[T],j=R.instance,F=R.currentTarget,R=R.listener,j!==w&&m.isPropagationStopped())break e;Bg(m,R,F),w=j}}}if(Al)throw s=nd,Al=!1,nd=null,s}function ze(s,i){var u=i[Nd];u===void 0&&(u=i[Nd]=new Set);var h=s+"__bubble";u.has(h)||(Wg(i,s,2,!1),u.add(h))}function kd(s,i,u){var h=0;i&&(h|=4),Wg(u,s,h,i)}var ql="_reactListening"+Math.random().toString(36).slice(2);function ra(s){if(!s[ql]){s[ql]=!0,r.forEach(function(u){u!=="selectionchange"&&(pT.has(u)||kd(u,!1,s),kd(u,!0,s))});var i=s.nodeType===9?s:s.ownerDocument;i===null||i[ql]||(i[ql]=!0,kd("selectionchange",!1,i))}}function Wg(s,i,u,h){switch(fg(i)){case 1:var m=PE;break;case 4:m=AE;break;default:m=ud}u=m.bind(null,i,u,s),m=void 0,!xn||i!=="touchstart"&&i!=="touchmove"&&i!=="wheel"||(m=!0),h?m!==void 0?s.addEventListener(i,u,{capture:!0,passive:m}):s.addEventListener(i,u,!0):m!==void 0?s.addEventListener(i,u,{passive:m}):s.addEventListener(i,u,!1)}function Cd(s,i,u,h,m){var w=h;if((i&1)===0&&(i&2)===0&&h!==null)e:for(;;){if(h===null)return;var T=h.tag;if(T===3||T===4){var R=h.stateNode.containerInfo;if(R===m||R.nodeType===8&&R.parentNode===m)break;if(T===4)for(T=h.return;T!==null;){var j=T.tag;if((j===3||j===4)&&(j=T.stateNode.containerInfo,j===m||j.nodeType===8&&j.parentNode===m))return;T=T.return}for(;R!==null;){if(T=js(R),T===null)return;if(j=T.tag,j===5||j===6){h=w=T;continue e}R=R.parentNode}}h=h.return}Dt(function(){var F=w,Y=_i(u),X=[];e:{var Q=Ug.get(s);if(Q!==void 0){var re=hd,le=s;switch(s){case"keypress":if(Ul(u)===0)break e;case"keydown":case"keyup":re=WE;break;case"focusin":le="focus",re=md;break;case"focusout":le="blur",re=md;break;case"beforeblur":case"afterblur":re=md;break;case"click":if(u.button===2)break e;case"auxclick":case"dblclick":case"mousedown":case"mousemove":case"mouseup":case"mouseout":case"mouseover":case"contextmenu":re=gg;break;case"drag":case"dragend":case"dragenter":case"dragexit":case"dragleave":case"dragover":case"dragstart":case"drop":re=OE;break;case"touchcancel":case"touchend":case"touchmove":case"touchstart":re=KE;break;case Dg:case Mg:case $g:re=LE;break;case Fg:re=QE;break;case"scroll":re=RE;break;case"wheel":re=JE;break;case"copy":case"cut":case"paste":re=ME;break;case"gotpointercapture":case"lostpointercapture":case"pointercancel":case"pointerdown":case"pointermove":case"pointerout":case"pointerover":case"pointerup":re=vg}var he=(i&4)!==0,nt=!he&&s==="scroll",M=he?Q!==null?Q+"Capture":null:Q;he=[];for(var I=F,$;I!==null;){$=I;var ee=$.stateNode;if($.tag===5&&ee!==null&&($=ee,M!==null&&(ee=Mt(I,M),ee!=null&&he.push(sa(I,ee,$)))),nt)break;I=I.return}0<he.length&&(Q=new re(Q,le,null,u,Y),X.push({event:Q,listeners:he}))}}if((i&7)===0){e:{if(Q=s==="mouseover"||s==="pointerover",re=s==="mouseout"||s==="pointerout",Q&&u!==Uo&&(le=u.relatedTarget||u.fromElement)&&(js(le)||le[fr]))break e;if((re||Q)&&(Q=Y.window===Y?Y:(Q=Y.ownerDocument)?Q.defaultView||Q.parentWindow:window,re?(le=u.relatedTarget||u.toElement,re=F,le=le?js(le):null,le!==null&&(nt=Rs(le),le!==nt||le.tag!==5&&le.tag!==6)&&(le=null)):(re=null,le=F),re!==le)){if(he=gg,ee="onMouseLeave",M="onMouseEnter",I="mouse",(s==="pointerout"||s==="pointerover")&&(he=vg,ee="onPointerLeave",M="onPointerEnter",I="pointer"),nt=re==null?Q:Oi(re),$=le==null?Q:Oi(le),Q=new he(ee,I+"leave",re,u,Y),Q.target=nt,Q.relatedTarget=$,ee=null,js(Y)===F&&(he=new he(M,I+"enter",le,u,Y),he.target=$,he.relatedTarget=nt,ee=he),nt=ee,re&&le)t:{for(he=re,M=le,I=0,$=he;$;$=Ri($))I++;for($=0,ee=M;ee;ee=Ri(ee))$++;for(;0<I-$;)he=Ri(he),I--;for(;0<$-I;)M=Ri(M),$--;for(;I--;){if(he===M||M!==null&&he===M.alternate)break t;he=Ri(he),M=Ri(M)}he=null}else he=null;re!==null&&Hg(X,Q,re,he,!1),le!==null&&nt!==null&&Hg(X,nt,le,he,!0)}}e:{if(Q=F?Oi(F):window,re=Q.nodeName&&Q.nodeName.toLowerCase(),re==="select"||re==="input"&&Q.type==="file")var pe=sT;else if(Eg(Q))if(kg)pe=lT;else{pe=oT;var ve=iT}else(re=Q.nodeName)&&re.toLowerCase()==="input"&&(Q.type==="checkbox"||Q.type==="radio")&&(pe=aT);if(pe&&(pe=pe(s,F))){Tg(X,pe,u,Y);break e}ve&&ve(s,Q,F),s==="focusout"&&(ve=Q._wrapperState)&&ve.controlled&&Q.type==="number"&&zn(Q,"number",Q.value)}switch(ve=F?Oi(F):window,s){case"focusin":(Eg(ve)||ve.contentEditable==="true")&&(Pi=ve,bd=F,ta=null);break;case"focusout":ta=bd=Pi=null;break;case"mousedown":Sd=!0;break;case"contextmenu":case"mouseup":case"dragend":Sd=!1,Ig(X,u,Y);break;case"selectionchange":if(dT)break;case"keydown":case"keyup":Ig(X,u,Y)}var we;if(yd)e:{switch(s){case"compositionstart":var Ee="onCompositionStart";break e;case"compositionend":Ee="onCompositionEnd";break e;case"compositionupdate":Ee="onCompositionUpdate";break e}Ee=void 0}else Ci?Sg(s,u)&&(Ee="onCompositionEnd"):s==="keydown"&&u.keyCode===229&&(Ee="onCompositionStart");Ee&&(wg&&u.locale!=="ko"&&(Ci||Ee!=="onCompositionStart"?Ee==="onCompositionEnd"&&Ci&&(we=pg()):(Vr=Y,dd="value"in Vr?Vr.value:Vr.textContent,Ci=!0)),ve=Kl(F,Ee),0<ve.length&&(Ee=new yg(Ee,s,null,u,Y),X.push({event:Ee,listeners:ve}),we?Ee.data=we:(we=_g(u),we!==null&&(Ee.data=we)))),(we=ZE?eT(s,u):tT(s,u))&&(F=Kl(F,"onBeforeInput"),0<F.length&&(Y=new yg("onBeforeInput","beforeinput",null,u,Y),X.push({event:Y,listeners:F}),Y.data=we))}zg(X,i)})}function sa(s,i,u){return{instance:s,listener:i,currentTarget:u}}function Kl(s,i){for(var u=i+"Capture",h=[];s!==null;){var m=s,w=m.stateNode;m.tag===5&&w!==null&&(m=w,w=Mt(s,u),w!=null&&h.unshift(sa(s,w,m)),w=Mt(s,i),w!=null&&h.push(sa(s,w,m))),s=s.return}return h}function Ri(s){if(s===null)return null;do s=s.return;while(s&&s.tag!==5);return s||null}function Hg(s,i,u,h,m){for(var w=i._reactName,T=[];u!==null&&u!==h;){var R=u,j=R.alternate,F=R.stateNode;if(j!==null&&j===h)break;R.tag===5&&F!==null&&(R=F,m?(j=Mt(u,w),j!=null&&T.unshift(sa(u,j,R))):m||(j=Mt(u,w),j!=null&&T.push(sa(u,j,R)))),u=u.return}T.length!==0&&s.push({event:i,listeners:T})}var mT=/\r\n?/g,gT=/\u0000|\uFFFD/g;function qg(s){return(typeof s=="string"?s:""+s).replace(mT,`
39`).replace(gT,"")}function Gl(s,i,u){if(i=qg(i),qg(s)!==i&&u)throw Error(n(425))}function Ql(){}var Pd=null,Ad=null;function Rd(s,i){return s==="textarea"||s==="noscript"||typeof i.children=="string"||typeof i.children=="number"||typeof i.dangerouslySetInnerHTML=="object"&&i.dangerouslySetInnerHTML!==null&&i.dangerouslySetInnerHTML.__html!=null}var jd=typeof setTimeout=="function"?setTimeout:void 0,yT=typeof clearTimeout=="function"?clearTimeout:void 0,Kg=typeof Promise=="function"?Promise:void 0,vT=typeof queueMicrotask=="function"?queueMicrotask:typeof Kg<"u"?function(s){return Kg.resolve(null).then(s).catch(wT)}:jd;function wT(s){setTimeout(function(){throw s})}function Od(s,i){var u=i,h=0;do{var m=u.nextSibling;if(s.removeChild(u),m&&m.nodeType===8)if(u=m.data,u==="/$"){if(h===0){s.removeChild(m),Go(i);return}h--}else u!=="$"&&u!=="$?"&&u!=="$!"||h++;u=m}while(u);Go(i)}function zr(s){for(;s!=null;s=s.nextSibling){var i=s.nodeType;if(i===1||i===3)break;if(i===8){if(i=s.data,i==="$"||i==="$!"||i==="$?")break;if(i==="/$")return null}}return s}function Gg(s){s=s.previousSibling;for(var i=0;s;){if(s.nodeType===8){var u=s.data;if(u==="$"||u==="$!"||u==="$?"){if(i===0)return s;i--}else u==="/$"&&i++}s=s.previousSibling}return null}var ji=Math.random().toString(36).slice(2),Jn="__reactFiber$"+ji,ia="__reactProps$"+ji,fr="__reactContainer$"+ji,Nd="__reactEvents$"+ji,xT="__reactListeners$"+ji,bT="__reactHandles$"+ji;function js(s){var i=s[Jn];if(i)return i;for(var u=s.parentNode;u;){if(i=u[fr]||u[Jn]){if(u=i.alternate,i.child!==null||u!==null&&u.child!==null)for(s=Gg(s);s!==null;){if(u=s[Jn])return u;s=Gg(s)}return i}s=u,u=s.parentNode}return null}function oa(s){return s=s[Jn]||s[fr],!s||s.tag!==5&&s.tag!==6&&s.tag!==13&&s.tag!==3?null:s}function Oi(s){if(s.tag===5||s.tag===6)return s.stateNode;throw Error(n(33))}function Yl(s){return s[ia]||null}var Id=[],Ni=-1;function Wr(s){return{current:s}}function We(s){0>Ni||(s.current=Id[Ni],Id[Ni]=null,Ni--)}function Ve(s,i){Ni++,Id[Ni]=s.current,s.current=i}var Hr={},Et=Wr(Hr),$t=Wr(!1),Os=Hr;function Ii(s,i){var u=s.type.contextTypes;if(!u)return Hr;var h=s.stateNode;if(h&&h.__reactInternalMemoizedUnmaskedChildContext===i)return h.__reactInternalMemoizedMaskedChildContext;var m={},w;for(w in u)m[w]=i[w];return h&&(s=s.stateNode,s.__reactInternalMemoizedUnmaskedChildContext=i,s.__reactInternalMemoizedMaskedChildContext=m),m}function Ft(s){return s=s.childContextTypes,s!=null}function Jl(){We($t),We(Et)}function Qg(s,i,u){if(Et.current!==Hr)throw Error(n(168));Ve(Et,i),Ve($t,u)}function Yg(s,i,u){var h=s.stateNode;if(i=i.childContextTypes,typeof h.getChildContext!="function")return u;h=h.getChildContext();for(var m in h)if(!(m in i))throw Error(n(108,ye(s)||"Unknown",m));return G({},u,h)}function Xl(s){return s=(s=s.stateNode)&&s.__reactInternalMemoizedMergedChildContext||Hr,Os=Et.current,Ve(Et,s),Ve($t,$t.current),!0}function Jg(s,i,u){var h=s.stateNode;if(!h)throw Error(n(169));u?(s=Yg(s,i,Os),h.__reactInternalMemoizedMergedChildContext=s,We($t),We(Et),Ve(Et,s)):We($t),Ve($t,u)}var pr=null,Zl=!1,Ld=!1;function Xg(s){pr===null?pr=[s]:pr.push(s)}function ST(s){Zl=!0,Xg(s)}function qr(){if(!Ld&&pr!==null){Ld=!0;var s=0,i=$e;try{var u=pr;for($e=1;s<u.length;s++){var h=u[s];do h=h(!0);while(h!==null)}pr=null,Zl=!1}catch(m){throw pr!==null&&(pr=pr.slice(s+1)),eg(rd,qr),m}finally{$e=i,Ld=!1}}return null}var Li=[],Di=0,eu=null,tu=0,an=[],ln=0,Ns=null,mr=1,gr="";function Is(s,i){Li[Di++]=tu,Li[Di++]=eu,eu=s,tu=i}function Zg(s,i,u){an[ln++]=mr,an[ln++]=gr,an[ln++]=Ns,Ns=s;var h=mr;s=gr;var m=32-bn(h)-1;h&=~(1<<m),u+=1;var w=32-bn(i)+m;if(30<w){var T=m-m%5;w=(h&(1<<T)-1).toString(32),h>>=T,m-=T,mr=1<<32-bn(i)+m|u<<m|h,gr=w+s}else mr=1<<w|u<<m|h,gr=s}function Dd(s){s.return!==null&&(Is(s,1),Zg(s,1,0))}function Md(s){for(;s===eu;)eu=Li[--Di],Li[Di]=null,tu=Li[--Di],Li[Di]=null;for(;s===Ns;)Ns=an[--ln],an[ln]=null,gr=an[--ln],an[ln]=null,mr=an[--ln],an[ln]=null}var Jt=null,Xt=null,Ke=!1,_n=null;function ey(s,i){var u=hn(5,null,null,0);u.elementType="DELETED",u.stateNode=i,u.return=s,i=s.deletions,i===null?(s.deletions=[u],s.flags|=16):i.push(u)}function ty(s,i){switch(s.tag){case 5:var u=s.type;return i=i.nodeType!==1||u.toLowerCase()!==i.nodeName.toLowerCase()?null:i,i!==null?(s.stateNode=i,Jt=s,Xt=zr(i.firstChild),!0):!1;case 6:return i=s.pendingProps===""||i.nodeType!==3?null:i,i!==null?(s.stateNode=i,Jt=s,Xt=null,!0):!1;case 13:return i=i.nodeType!==8?null:i,i!==null?(u=Ns!==null?{id:mr,overflow:gr}:null,s.memoizedState={dehydrated:i,treeContext:u,retryLane:1073741824},u=hn(18,null,null,0),u.stateNode=i,u.return=s,s.child=u,Jt=s,Xt=null,!0):!1;default:return!1}}function $d(s){return(s.mode&1)!==0&&(s.flags&128)===0}function Fd(s){if(Ke){var i=Xt;if(i){var u=i;if(!ty(s,i)){if($d(s))throw Error(n(418));i=zr(u.nextSibling);var h=Jt;i&&ty(s,i)?ey(h,u):(s.flags=s.flags&-4097|2,Ke=!1,Jt=s)}}else{if($d(s))throw Error(n(418));s.flags=s.flags&-4097|2,Ke=!1,Jt=s}}}function ny(s){for(s=s.return;s!==null&&s.tag!==5&&s.tag!==3&&s.tag!==13;)s=s.return;Jt=s}function nu(s){if(s!==Jt)return!1;if(!Ke)return ny(s),Ke=!0,!1;var i;if((i=s.tag!==3)&&!(i=s.tag!==5)&&(i=s.type,i=i!=="head"&&i!=="body"&&!Rd(s.t
vendor: 2,005 bytes, line 39
39ype,s.memoizedProps)),i&&(i=Xt)){if($d(s))throw ry(),Error(n(418));for(;i;)ey(s,i),i=zr(i.nextSibling)}if(ny(s),s.tag===13){if(s=s.memoizedState,s=s!==null?s.dehydrated:null,!s)throw Error(n(317));e:{for(s=s.nextSibling,i=0;s;){if(s.nodeType===8){var u=s.data;if(u==="/$"){if(i===0){Xt=zr(s.nextSibling);break e}i--}else u!=="$"&&u!=="$!"&&u!=="$?"||i++}s=s.nextSibling}Xt=null}}else Xt=Jt?zr(s.stateNode.nextSibling):null;return!0}function ry(){for(var s=Xt;s;)s=zr(s.nextSibling)}function Mi(){Xt=Jt=null,Ke=!1}function Ud(s){_n===null?_n=[s]:_n.push(s)}var _T=A.ReactCurrentBatchConfig;function aa(s,i,u){if(s=u.ref,s!==null&&typeof s!="function"&&typeof s!="object"){if(u._owner){if(u=u._owner,u){if(u.tag!==1)throw Error(n(309));var h=u.stateNode}if(!h)throw Error(n(147,s));var m=h,w=""+s;return i!==null&&i.ref!==null&&typeof i.ref=="function"&&i.ref._stringRef===w?i.ref:(i=function(T){var R=m.refs;T===null?delete R[w]:R[w]=T},i._stringRef=w,i)}if(typeof s!="string")throw Error(n(284));if(!u._owner)throw Error(n(290,s))}return s}function ru(s,i){throw s=Object.prototype.toString.call(i),Error(n(31,s==="[object Object]"?"object with keys {"+Object.keys(i).join(", ")+"}":s))}function sy(s){var i=s._init;return i(s._payload)}function iy(s){function i(M,I){if(s){var $=M.deletions;$===null?(M.deletions=[I],M.flags|=16):$.push(I)}}function u(M,I){if(!s)return null;for(;I!==null;)i(M,I),I=I.sibling;return null}function h(M,I){for(M=new Map;I!==null;)I.key!==null?M.set(I.key,I):M.set(I.index,I),I=I.sibling;return M}function m(M,I){return M=es(M,I),M.index=0,M.sibling=null,M}function w(M,I,$){return M.index=$,s?($=M.alternate,$!==null?($=$.index,$<I?(M.flags|=2,I):$):(M.flags|=2,I)):(M.flags|=1048576,I)}function T(M){return s&&M.alternate===null&&(M.flags|=2),M}function R(M,I,$,ee){return I===null||I.tag!==6?(I=jh($,M.mode,ee),I.return=M,I):(I=m(I,$),I.return=M,I)}function j(M,I,$,ee){var pe=$.type;return pe===V?Y(M,I,$.props.children,ee,$.key):I!==null&&(I.elementType===pe||typeof pe
vendor: 3,657 bytes, line 39
39=="object"&&pe!==null&&pe.$$typeof===ie&&sy(pe)===I.type)?(ee=m(I,$.props),ee.ref=aa(M,I,$),ee.return=M,ee):(ee=Cu($.type,$.key,$.props,null,M.mode,ee),ee.ref=aa(M,I,$),ee.return=M,ee)}function F(M,I,$,ee){return I===null||I.tag!==4||I.stateNode.containerInfo!==$.containerInfo||I.stateNode.implementation!==$.implementation?(I=Oh($,M.mode,ee),I.return=M,I):(I=m(I,$.children||[]),I.return=M,I)}function Y(M,I,$,ee,pe){return I===null||I.tag!==7?(I=Bs($,M.mode,ee,pe),I.return=M,I):(I=m(I,$),I.return=M,I)}function X(M,I,$){if(typeof I=="string"&&I!==""||typeof I=="number")return I=jh(""+I,M.mode,$),I.return=M,I;if(typeof I=="object"&&I!==null){switch(I.$$typeof){case L:return $=Cu(I.type,I.key,I.props,null,M.mode,$),$.ref=aa(M,null,I),$.return=M,$;case D:return I=Oh(I,M.mode,$),I.return=M,I;case ie:var ee=I._init;return X(M,ee(I._payload),$)}if(Lr(I)||W(I))return I=Bs(I,M.mode,$,null),I.return=M,I;ru(M,I)}return null}function Q(M,I,$,ee){var pe=I!==null?I.key:null;if(typeof $=="string"&&$!==""||typeof $=="number")return pe!==null?null:R(M,I,""+$,ee);if(typeof $=="object"&&$!==null){switch($.$$typeof){case L:return $.key===pe?j(M,I,$,ee):null;case D:return $.key===pe?F(M,I,$,ee):null;case ie:return pe=$._init,Q(M,I,pe($._payload),ee)}if(Lr($)||W($))return pe!==null?null:Y(M,I,$,ee,null);ru(M,$)}return null}function re(M,I,$,ee,pe){if(typeof ee=="string"&&ee!==""||typeof ee=="number")return M=M.get($)||null,R(I,M,""+ee,pe);if(typeof ee=="object"&&ee!==null){switch(ee.$$typeof){case L:return M=M.get(ee.key===null?$:ee.key)||null,j(I,M,ee,pe);case D:return M=M.get(ee.key===null?$:ee.key)||null,F(I,M,ee,pe);case ie:var ve=ee._init;return re(M,I,$,ve(ee._payload),pe)}if(Lr(ee)||W(ee))return M=M.get($)||null,Y(I,M,ee,pe,null);ru(I,ee)}return null}function le(M,I,$,ee){for(var pe=null,ve=null,we=I,Ee=I=0,pt=null;we!==null&&Ee<$.length;Ee++){we.index>Ee?(pt=we,we=null):pt=we.sibling;var Le=Q(M,we,$[Ee],ee);if(Le===null){we===null&&(we=pt);break}s&&we&&Le.alternate===null&&i(M,we),I=w(Le,I,Ee),ve===null?pe=Le:ve.sibling=Le,ve=Le,we=pt}if(Ee===$.length)return u(M,we),Ke&&Is(M,Ee),pe;if(we===null){for(;Ee<$.length;Ee++)we=X(M,$[Ee],ee),we!==null&&(I=w(we,I,Ee),ve===null?pe=we:ve.sibling=we,ve=we);return Ke&&Is(M,Ee),pe}for(we=h(M,we);Ee<$.length;Ee++)pt=re(we,M,Ee,$[Ee],ee),pt!==null&&(s&&pt.alternate!==null&&we.delete(pt.key===null?Ee:pt.key),I=w(pt,I,Ee),ve===null?pe=pt:ve.sibling=pt,ve=pt);return s&&we.forEach(function(ts){return i(M,ts)}),Ke&&Is(M,Ee),pe}function he(M,I,$,ee){var pe=W($);if(typeof pe!="function")throw Error(n(150));if($=pe.call($),$==null)throw Error(n(151));for(var ve=pe=null,we=I,Ee=I=0,pt=null,Le=$.next();we!==null&&!Le.done;Ee++,Le=$.next()){we.index>Ee?(pt=we,we=null):pt=we.sibling;var ts=Q(M,we,Le.value,ee);if(ts===null){we===null&&(we=pt);break}s&&we&&ts.alternate===null&&i(M,we),I=w(ts,I,Ee),ve===null?pe=ts:ve.sibling=ts,ve=ts,we=pt}if(Le.done)return u(M,we),Ke&&Is(M,Ee),pe;if(we===null){for(;!Le.done;Ee++,Le=$.next())Le=X(M,Le.value,ee),Le!==null&&(I=w(Le,I,Ee),ve===null?pe=Le:ve.sibling=Le,ve=Le);return Ke&&Is(M,Ee),pe}for(we=h(M,we);!Le.done;Ee++,Le=$.next())Le=re(we,M,Ee,Le.value,ee),Le!==null&&(s&&Le.alternate!==null&&we.delete(Le.key===null?Ee:Le.key),I=w(Le,I,Ee),ve===null?pe=Le:ve.sibling=Le,ve=Le);return s&&we.forEach(function(nk){return i(M,nk)}),Ke&&Is(M,Ee),pe}function nt(M,I,$,ee){if(typeof $=="object"&&$!==null&&$.type===V&&$.key===null&&($=$.props.children),typeof $=="object"&&$!==null){switch($.$$typeof){case L:e:{for(var pe=$.key,ve=I;ve!==null;){if(ve.key===pe){if(pe=$.type,pe===V){if(ve.tag===7){u(M,ve.sibling),I=m(ve,$.props.children),I.return=M,M=I;break e}}
vendor: 6,195 bytes, line 39
39else if(ve.elementType===pe||typeof pe=="object"&&pe!==null&&pe.$$typeof===ie&&sy(pe)===ve.type){u(M,ve.sibling),I=m(ve,$.props),I.ref=aa(M,ve,$),I.return=M,M=I;break e}u(M,ve);break}else i(M,ve);ve=ve.sibling}$.type===V?(I=Bs($.props.children,M.mode,ee,$.key),I.return=M,M=I):(ee=Cu($.type,$.key,$.props,null,M.mode,ee),ee.ref=aa(M,I,$),ee.return=M,M=ee)}return T(M);case D:e:{for(ve=$.key;I!==null;){if(I.key===ve)if(I.tag===4&&I.stateNode.containerInfo===$.containerInfo&&I.stateNode.implementation===$.implementation){u(M,I.sibling),I=m(I,$.children||[]),I.return=M,M=I;break e}else{u(M,I);break}else i(M,I);I=I.sibling}I=Oh($,M.mode,ee),I.return=M,M=I}return T(M);case ie:return ve=$._init,nt(M,I,ve($._payload),ee)}if(Lr($))return le(M,I,$,ee);if(W($))return he(M,I,$,ee);ru(M,$)}return typeof $=="string"&&$!==""||typeof $=="number"?($=""+$,I!==null&&I.tag===6?(u(M,I.sibling),I=m(I,$),I.return=M,M=I):(u(M,I),I=jh($,M.mode,ee),I.return=M,M=I),T(M)):u(M,I)}return nt}var $i=iy(!0),oy=iy(!1),su=Wr(null),iu=null,Fi=null,Vd=null;function Bd(){Vd=Fi=iu=null}function zd(s){var i=su.current;We(su),s._currentValue=i}function Wd(s,i,u){for(;s!==null;){var h=s.alternate;if((s.childLanes&i)!==i?(s.childLanes|=i,h!==null&&(h.childLanes|=i)):h!==null&&(h.childLanes&i)!==i&&(h.childLanes|=i),s===u)break;s=s.return}}function Ui(s,i){iu=s,Vd=Fi=null,s=s.dependencies,s!==null&&s.firstContext!==null&&((s.lanes&i)!==0&&(Ut=!0),s.firstContext=null)}function un(s){var i=s._currentValue;if(Vd!==s)if(s={context:s,memoizedValue:i,next:null},Fi===null){if(iu===null)throw Error(n(308));Fi=s,iu.dependencies={lanes:0,firstContext:s}}else Fi=Fi.next=s;return i}var Ls=null;function Hd(s){Ls===null?Ls=[s]:Ls.push(s)}function ay(s,i,u,h){var m=i.interleaved;return m===null?(u.next=u,Hd(i)):(u.next=m.next,m.next=u),i.interleaved=u,yr(s,h)}function yr(s,i){s.lanes|=i;var u=s.alternate;for(u!==null&&(u.lanes|=i),u=s,s=s.return;s!==null;)s.childLanes|=i,u=s.alternate,u!==null&&(u.childLanes|=i),u=s,s=s.return;return u.tag===3?u.stateNode:null}var Kr=!1;function qd(s){s.updateQueue={baseState:s.memoizedState,firstBaseUpdate:null,lastBaseUpdate:null,shared:{pending:null,interleaved:null,lanes:0},effects:null}}function ly(s,i){s=s.updateQueue,i.updateQueue===s&&(i.updateQueue={baseState:s.baseState,firstBaseUpdate:s.firstBaseUpdate,lastBaseUpdate:s.lastBaseUpdate,shared:s.shared,effects:s.effects})}function vr(s,i){return{eventTime:s,lane:i,tag:0,payload:null,callback:null,next:null}}function Gr(s,i,u){var h=s.updateQueue;if(h===null)return null;if(h=h.shared,(Ie&2)!==0){var m=h.pending;return m===null?i.next=i:(i.next=m.next,m.next=i),h.pending=i,yr(s,u)}return m=h.interleaved,m===null?(i.next=i,Hd(h)):(i.next=m.next,m.next=i),h.interleaved=i,yr(s,u)}function ou(s,i,u){if(i=i.updateQueue,i!==null&&(i=i.shared,(u&4194240)!==0)){var h=i.lanes;h&=s.pendingLanes,u|=h,i.lanes=u,od(s,u)}}function uy(s,i){var u=s.updateQueue,h=s.alternate;if(h!==null&&(h=h.updateQueue,u===h)){var m=null,w=null;if(u=u.firstBaseUpdate,u!==null){do{var T={eventTime:u.eventTime,lane:u.lane,tag:u.tag,payload:u.payload,callback:u.callback,next:null};w===null?m=w=T:w=w.next=T,u=u.next}while(u!==null);w===null?m=w=i:w=w.next=i}else m=w=i;u={baseState:h.baseState,firstBaseUpdate:m,lastBaseUpdate:w,shared:h.shared,effects:h.effects},s.updateQueue=u;return}s=u.lastBaseUpdate,s===null?u.firstBaseUpdate=i:s.next=i,u.lastBaseUpdate=i}function au(s,i,u,h){var m=s.updateQueue;Kr=!1;var w=m.firstBaseUpdate,T=m.lastBaseUpdate,R=m.shared.pending;if(R!==null){m.shared.pending=null;var j=R,F=j.next;j.next=null,T===null?w=F:T.next=F,T=j;var Y=s.alternate;Y!==null&&(Y=Y.updateQueue,R=Y.lastBaseUpdate,R!==T&&(R===null?Y.firstBaseUpdate=F:R.next=F,Y.lastBaseUpdate=j))}if(w!==null){var X=m.baseState;T=0,Y=F=j=null,R=w;do{var Q=R.lane,re=R.eventTime;if((h&Q)===Q){Y!==null&&(Y=Y.next={eventTime:re,lane:0,tag:R.tag,payload:R.payload,callback:R.callback,next:null});e:{var le=s,he=R;switch(Q=i,re=u,he.tag){case 1:if(le=he.payload,typeof le=="function"){X=le.call(re,X,Q);break e}X=le;break e;case 3:le.flags=le.flags&-65537|128;case 0:if(le=he.payload,Q=typeof le=="function"?le.call(re,X,Q):le,Q==null)break e;X=G({},X,Q);break e;case 2:Kr=!0}}R.callback!==null&&R.lane!==0&&(s.flags|=64,Q=m.effects,Q===null?m.effects=[R]:Q.push(R))}else re={eventTime:re,lane:Q,tag:R.tag,payload:R.payload,callback:R.callback,next:null},Y===null?(F=Y=re,j=X):Y=Y.next=re,T|=Q;if(R=R.next,R===null){if(R=m.shared.pending,R===null)break;Q=R,R=Q.next,Q.next=null,m.lastBaseUpdate=Q,m.shared.pending=null}}while(!0);if(Y===null&&(j=X),m.baseState=j,m.firstBaseUpdate=F,m.lastBaseUpdate=Y,i=m.shared.interleaved,i!==null){m=i;do T|=m.lane,m=m.next;while(m!==i)}else w===null&&(m.shared.lanes=0);$s|=T,s.lanes=T,s.memoizedState=X}}function cy(s,i,u){if(s=i.effects,i.effects=null,s!==null)for(i=0;i<s.length;i++){var h=s[i],m=h.callback;if(m!==null){if(h.callback=null,h=u,typeof m!="function")throw Error(n(191,m));m.call(h)}}}var la={},Xn=Wr(la),ua=Wr(la),ca=Wr(la);function Ds(s){if(s===la)throw Error(n(174));return s}function Kd(s,i){switch(Ve(ca,i),Ve(ua,s),Ve(Xn,la),s=i.nodeType,s){case 9:case 11:i=(i=i.documentElement)?i.namespaceURI:Hn(null,"");break;default:s=s===8?i.parentNode:i,i=s.namespaceURI||null,s=s.tagName,i=Hn(i,s)}We(Xn),Ve(Xn,i)}function Vi(){We(Xn),We(ua),We(ca)}function dy(s){Ds(ca.current);var i=Ds(Xn.current),u=Hn(i,s.type);i!==u&&(Ve(ua,s),Ve(Xn,u))}function Gd(s){ua.current===s&&(We(Xn),We(ua))}var Ge=Wr(0);function lu(s){for(var i=s;i!==null;){if(i.tag===13){var u=i.memoizedState;if(u!==null&&(u=u.dehydrated,u===null||u.data==="$?"||u.data==="$!"))return i}else if(i.tag===19&&i.memoizedProps.revealOrder!==void 0){if((i.flags&128)!==0)return i}else if(i.child!==null){i.child.return=i,i=i.child;continue}if(i===s)break;for(;i.sibling===null;){if(i.return===null||i.return===s)return null;i=i.return}i.sibling.return=i.return,i=i.sibling}return null}var Qd=[];function Yd(){for(var s=0;s<Qd.length;s++)Qd[s]._workInProgressVersionPrimary=null;Qd.length=0}var uu=A.ReactCurrentDispatcher,Jd=A.ReactCurrentBatchConfig,Ms=0,Qe=null,at=null,ht=null,cu=!1,da=!1,ha=0,ET=0;function Tt(){throw Error(n(321))}
vendor: 8,345 bytes, line 39
39function Xd(s,i){if(i===null)return!1;for(var u=0;u<i.length&&u<s.length;u++)if(!Sn(s[u],i[u]))return!1;return!0}function Zd(s,i,u,h,m,w){if(Ms=w,Qe=i,i.memoizedState=null,i.updateQueue=null,i.lanes=0,uu.current=s===null||s.memoizedState===null?PT:AT,s=u(h,m),da){w=0;do{if(da=!1,ha=0,25<=w)throw Error(n(301));w+=1,ht=at=null,i.updateQueue=null,uu.current=RT,s=u(h,m)}while(da)}if(uu.current=fu,i=at!==null&&at.next!==null,Ms=0,ht=at=Qe=null,cu=!1,i)throw Error(n(300));return s}function eh(){var s=ha!==0;return ha=0,s}function Zn(){var s={memoizedState:null,baseState:null,baseQueue:null,queue:null,next:null};return ht===null?Qe.memoizedState=ht=s:ht=ht.next=s,ht}function cn(){if(at===null){var s=Qe.alternate;s=s!==null?s.memoizedState:null}else s=at.next;var i=ht===null?Qe.memoizedState:ht.next;if(i!==null)ht=i,at=s;else{if(s===null)throw Error(n(310));at=s,s={memoizedState:at.memoizedState,baseState:at.baseState,baseQueue:at.baseQueue,queue:at.queue,next:null},ht===null?Qe.memoizedState=ht=s:ht=ht.next=s}return ht}function fa(s,i){return typeof i=="function"?i(s):i}function th(s){var i=cn(),u=i.queue;if(u===null)throw Error(n(311));u.lastRenderedReducer=s;var h=at,m=h.baseQueue,w=u.pending;if(w!==null){if(m!==null){var T=m.next;m.next=w.next,w.next=T}h.baseQueue=m=w,u.pending=null}if(m!==null){w=m.next,h=h.baseState;var R=T=null,j=null,F=w;do{var Y=F.lane;if((Ms&Y)===Y)j!==null&&(j=j.next={lane:0,action:F.action,hasEagerState:F.hasEagerState,eagerState:F.eagerState,next:null}),h=F.hasEagerState?F.eagerState:s(h,F.action);else{var X={lane:Y,action:F.action,hasEagerState:F.hasEagerState,eagerState:F.eagerState,next:null};j===null?(R=j=X,T=h):j=j.next=X,Qe.lanes|=Y,$s|=Y}F=F.next}while(F!==null&&F!==w);j===null?T=h:j.next=R,Sn(h,i.memoizedState)||(Ut=!0),i.memoizedState=h,i.baseState=T,i.baseQueue=j,u.lastRenderedState=h}if(s=u.interleaved,s!==null){m=s;do w=m.lane,Qe.lanes|=w,$s|=w,m=m.next;while(m!==s)}else m===null&&(u.lanes=0);return[i.memoizedState,u.dispatch]}function nh(s){var i=cn(),u=i.queue;if(u===null)throw Error(n(311));u.lastRenderedReducer=s;var h=u.dispatch,m=u.pending,w=i.memoizedState;if(m!==null){u.pending=null;var T=m=m.next;do w=s(w,T.action),T=T.next;while(T!==m);Sn(w,i.memoizedState)||(Ut=!0),i.memoizedState=w,i.baseQueue===null&&(i.baseState=w),u.lastRenderedState=w}return[w,h]}function hy(){}function fy(s,i){var u=Qe,h=cn(),m=i(),w=!Sn(h.memoizedState,m);if(w&&(h.memoizedState=m,Ut=!0),h=h.queue,rh(gy.bind(null,u,h,s),[s]),h.getSnapshot!==i||w||ht!==null&&ht.memoizedState.tag&1){if(u.flags|=2048,pa(9,my.bind(null,u,h,m,i),void 0,null),ft===null)throw Error(n(349));(Ms&30)!==0||py(u,i,m)}return m}function py(s,i,u){s.flags|=16384,s={getSnapshot:i,value:u},i=Qe.updateQueue,i===null?(i={lastEffect:null,stores:null},Qe.updateQueue=i,i.stores=[s]):(u=i.stores,u===null?i.stores=[s]:u.push(s))}function my(s,i,u,h){i.value=u,i.getSnapshot=h,yy(i)&&vy(s)}function gy(s,i,u){return u(function(){yy(i)&&vy(s)})}function yy(s){var i=s.getSnapshot;s=s.value;try{var u=i();return!Sn(s,u)}catch{return!0}}function vy(s){var i=yr(s,1);i!==null&&Cn(i,s,1,-1)}function wy(s){var i=Zn();return typeof s=="function"&&(s=s()),i.memoizedState=i.baseState=s,s={pending:null,interleaved:null,lanes:0,dispatch:null,lastRenderedReducer:fa,lastRenderedState:s},i.queue=s,s=s.dispatch=CT.bind(null,Qe,s),[i.memoizedState,s]}function pa(s,i,u,h){return s={tag:s,create:i,destroy:u,deps:h,next:null},i=Qe.updateQueue,i===null?(i={lastEffect:null,stores:null},Qe.updateQueue=i,i.lastEffect=s.next=s):(u=i.lastEffect,u===null?i.lastEffect=s.next=s:(h=u.next,u.next=s,s.next=h,i.lastEffect=s)),s}function xy(){return cn().memoizedState}function du(s,i,u,h){var m=Zn();Qe.flags|=s,m.memoizedState=pa(1|i,u,void 0,h===void 0?null:h)}function hu(s,i,u,h){var m=cn();h=h===void 0?null:h;var w=void 0;if(at!==null){var T=at.memoizedState;if(w=T.destroy,h!==null&&Xd(h,T.deps)){m.memoizedState=pa(i,u,w,h);return}}Qe.flags|=s,m.memoizedState=pa(1|i,u,w,h)}function by(s,i){return du(8390656,8,s,i)}function rh(s,i){return hu(2048,8,s,i)}function Sy(s,i){return hu(4,2,s,i)}function _y(s,i){return hu(4,4,s,i)}function Ey(s,i){if(typeof i=="function")return s=s(),i(s),function(){i(null)};if(i!=null)return s=s(),i.current=s,function(){i.current=null}}function Ty(s,i,u){return u=u!=null?u.concat([s]):null,hu(4,4,Ey.bind(null,i,s),u)}function sh(){}function ky(s,i){var u=cn();i=i===void 0?null:i;var h=u.memoizedState;return h!==null&&i!==null&&Xd(i,h[1])?h[0]:(u.memoizedState=[s,i],s)}function Cy(s,i){var u=cn();i=i===void 0?null:i;var h=u.memoizedState;return h!==null&&i!==null&&Xd(i,h[1])?h[0]:(s=s(),u.memoizedState=[s,i],s)}function Py(s,i,u){return(Ms&21)===0?(s.baseState&&(s.baseState=!1,Ut=!0),s.memoizedState=u):(Sn(u,i)||(u=sg(),Qe.lanes|=u,$s|=u,s.baseState=!0),i)}function TT(s,i){var u=$e;$e=u!==0&&4>u?u:4,s(!0);var h=Jd.transition;Jd.transition={};try{s(!1),i()}finally{$e=u,Jd.transition=h}}function Ay(){return cn().memoizedState}function kT(s,i,u){var h=Xr(s);if(u={lane:h,action:u,hasEagerState:!1,eagerState:null,next:null},Ry(s))jy(i,u);else if(u=ay(s,i,u,h),u!==null){var m=Ot();Cn(u,s,h,m),Oy(u,i,h)}}function CT(s,i,u){var h=Xr(s),m={lane:h,action:u,hasEagerState:!1,eagerState:null,next:null};if(Ry(s))jy(i,m);else{var w=s.alternate;if(s.lanes===0&&(w===null||w.lanes===0)&&(w=i.lastRenderedReducer,w!==null))try{var T=i.lastRenderedState,R=w(T,u);if(m.hasEagerState=!0,m.eagerState=R,Sn(R,T)){var j=i.interleaved;j===null?(m.next=m,Hd(i)):(m.next=j.next,j.next=m),i.interleaved=m;return}}catch{}finally{}u=ay(s,i,m,h),u!==null&&(m=Ot(),Cn(u,s,h,m),Oy(u,i,h))}}function Ry(s){var i=s.alternate;return s===Qe||i!==null&&i===Qe}function jy(s,i){da=cu=!0;var u=s.pending;u===null?i.next=i:(i.next=u.next,u.next=i),s.pending=i}function Oy(s,i,u){if((u&4194240)!==0){var h=i.lanes;h&=s.pendingLanes,u|=h,i.lanes=u,od(s,u)}}var fu={readContext:un,useCallback:Tt,useContext:Tt,useEffect:Tt,useImperativeHandle:Tt,useInsertionEffect:Tt,useLayoutEffect:Tt,useMemo:Tt,useReducer:Tt,useRef:Tt,useState:Tt,useDebugValue:Tt,useDeferredValue:Tt,useTransition:Tt,useMutableSource:Tt,useSyncExternalStore:Tt,useId:Tt,unstable_isNewReconciler:!1},PT={readContext:un,useCallback:function(s,i){return Zn().memoizedState=[s,i===void 0?null:i],s},useContext:un,useEffect:by,useImperativeHandle:function(s,i,u){return u=u!=null?u.concat([s]):null,du(4194308,4,Ey.bind(null,i,s),u)},useLayoutEffect:function(s,i){return du(4194308,4,s,i)},useInsertionEffect:function(s,i){return du(4,2,s,i)},useMemo:function(s,i){var u=Zn();return i=i===void 0?null:i,s=s(),u.memoizedState=[s,i],s},useReducer:function(s,i,u){var h=Zn();return i=u!==void 0?u(i):i,h.memoizedState=h.baseState=i,s={pending:null,interleaved:null,lanes:0,dispatch:null,lastRenderedReducer:s,lastRenderedState:i},h.queue=s,s=s.dispatch=kT.bind(null,Qe,s),[h.memoizedState,s]},useRef:function(s){var i=Zn();return s={current:s},i.memoizedState=s},useState:wy,useDebugValue:sh,useDeferredValue:function(s){return Zn().memoizedState=s},useTransition:function(){var s=wy(!1),i=s[0];return s=TT.bind(null,s[1]),Zn().memoizedState=s,[i,s]},useMutableSource:function(){},useSyncExternalStore:function(s,i,u){var h=Qe,m=Zn();if(Ke){if(u===void 0)throw Error(n(407));u=u()}else{if(u=i(),ft===null)throw Error(n(349));(Ms&30)!==0||py(h,i,u)}m.memoizedState=u;var w={value:u,getSnapshot:i};return m.queue=w,by(gy.bind(null,h,w,s),[s]),h.flags|=2048,pa(9,my.bind(null,h,w,u,i),void 0,null),u},useId:function(){var s=Zn(),i=ft.identifierPrefix;if(Ke){var u=gr,h=mr;u=(h&~(1<<32-bn(h)-1)).toString(32)+u,i=":"+i+"R"+u,u=ha++,0<u&&(i+="H"+u.toString(32)),i+=":"}else u=ET++,i=":"+i+"r"+u.toString(32)+":";return s.memoizedState=i},unstable_isNewReconciler:!1},AT={readContext:un,useCallback:ky,useContext:un,useEffect:rh,useImperativeHandle:Ty,useInsertionEffect:Sy,useLayoutEffect:_y,useMemo:Cy,useReducer:th,useRef:xy,useState:function(){return th(fa)},useDebugValue:sh,useDeferredValue:function(s){var i=cn();return Py(i,at.memoizedState,s)},useTransition:function(){var s=th(fa)[0],i=cn().memoizedState;return[s,i]},useMutableSource:hy,useSyncExternalStore:fy,useId:Ay,unstable_isNewReconciler:!1},RT={readContext:un,useCallback:ky,useContext:un,useEffect:rh,useImperativeHandle:Ty,useInsertionEffect:Sy,useLayoutEffect:_y,useMemo:Cy,useReducer:nh,useRef
vendor: 5,986 bytes, lines 39-41
39:xy,useState:function(){return nh(fa)},useDebugValue:sh,useDeferredValue:function(s){var i=cn();return at===null?i.memoizedState=s:Py(i,at.memoizedState,s)},useTransition:function(){var s=nh(fa)[0],i=cn().memoizedState;return[s,i]},useMutableSource:hy,useSyncExternalStore:fy,useId:Ay,unstable_isNewReconciler:!1};function En(s,i){if(s&&s.defaultProps){i=G({},i),s=s.defaultProps;for(var u in s)i[u]===void 0&&(i[u]=s[u]);return i}return i}function ih(s,i,u,h){i=s.memoizedState,u=u(h,i),u=u==null?i:G({},i,u),s.memoizedState=u,s.lanes===0&&(s.updateQueue.baseState=u)}var pu={isMounted:function(s){return(s=s._reactInternals)?Rs(s)===s:!1},enqueueSetState:function(s,i,u){s=s._reactInternals;var h=Ot(),m=Xr(s),w=vr(h,m);w.payload=i,u!=null&&(w.callback=u),i=Gr(s,w,m),i!==null&&(Cn(i,s,m,h),ou(i,s,m))},enqueueReplaceState:function(s,i,u){s=s._reactInternals;var h=Ot(),m=Xr(s),w=vr(h,m);w.tag=1,w.payload=i,u!=null&&(w.callback=u),i=Gr(s,w,m),i!==null&&(Cn(i,s,m,h),ou(i,s,m))},enqueueForceUpdate:function(s,i){s=s._reactInternals;var u=Ot(),h=Xr(s),m=vr(u,h);m.tag=2,i!=null&&(m.callback=i),i=Gr(s,m,h),i!==null&&(Cn(i,s,h,u),ou(i,s,h))}};function Ny(s,i,u,h,m,w,T){return s=s.stateNode,typeof s.shouldComponentUpdate=="function"?s.shouldComponentUpdate(h,w,T):i.prototype&&i.prototype.isPureReactComponent?!ea(u,h)||!ea(m,w):!0}function Iy(s,i,u){var h=!1,m=Hr,w=i.contextType;return typeof w=="object"&&w!==null?w=un(w):(m=Ft(i)?Os:Et.current,h=i.contextTypes,w=(h=h!=null)?Ii(s,m):Hr),i=new i(u,w),s.memoizedState=i.state!==null&&i.state!==void 0?i.state:null,i.updater=pu,s.stateNode=i,i._reactInternals=s,h&&(s=s.stateNode,s.__reactInternalMemoizedUnmaskedChildContext=m,s.__reactInternalMemoizedMaskedChildContext=w),i}function Ly(s,i,u,h){s=i.state,typeof i.componentWillReceiveProps=="function"&&i.componentWillReceiveProps(u,h),typeof i.UNSAFE_componentWillReceiveProps=="function"&&i.UNSAFE_componentWillReceiveProps(u,h),i.state!==s&&pu.enqueueReplaceState(i,i.state,null)}function oh(s,i,u,h){var m=s.stateNode;m.props=u,m.state=s.memoizedState,m.refs={},qd(s);var w=i.contextType;typeof w=="object"&&w!==null?m.context=un(w):(w=Ft(i)?Os:Et.current,m.context=Ii(s,w)),m.state=s.memoizedState,w=i.getDerivedStateFromProps,typeof w=="function"&&(ih(s,i,w,u),m.state=s.memoizedState),typeof i.getDerivedStateFromProps=="function"||typeof m.getSnapshotBeforeUpdate=="function"||typeof m.UNSAFE_componentWillMount!="function"&&typeof m.componentWillMount!="function"||(i=m.state,typeof m.componentWillMount=="function"&&m.componentWillMount(),typeof m.UNSAFE_componentWillMount=="function"&&m.UNSAFE_componentWillMount(),i!==m.state&&pu.enqueueReplaceState(m,m.state,null),au(s,u,m,h),m.state=s.memoizedState),typeof m.componentDidMount=="function"&&(s.flags|=4194308)}function Bi(s,i){try{var u="",h=i;do u+=_e(h),h=h.return;while(h);var m=u}catch(w){m=`
40Error generating stack: `+w.message+`
41`+w.stack}return{value:s,source:i,stack:m,digest:null}}function ah(s,i,u){return{value:s,source:null,stack:u??null,digest:i??null}}function lh(s,i){try{console.error(i.value)}catch(u){setTimeout(function(){throw u})}}var jT=typeof WeakMap=="function"?WeakMap:Map;function Dy(s,i,u){u=vr(-1,u),u.tag=3,u.payload={element:null};var h=i.value;return u.callback=function(){bu||(bu=!0,_h=h),lh(s,i)},u}function My(s,i,u){u=vr(-1,u),u.tag=3;var h=s.type.getDerivedStateFromError;if(typeof h=="function"){var m=i.value;u.payload=function(){return h(m)},u.callback=function(){lh(s,i)}}var w=s.stateNode;return w!==null&&typeof w.componentDidCatch=="function"&&(u.callback=function(){lh(s,i),typeof h!="function"&&(Yr===null?Yr=new Set([this]):Yr.add(this));var T=i.stack;this.componentDidCatch(i.value,{componentStack:T!==null?T:""})}),u}function $y(s,i,u){var h=s.pingCache;if(h===null){h=s.pingCache=new jT;var m=new Set;h.set(i,m)}else m=h.get(i),m===void 0&&(m=new Set,h.set(i,m));m.has(u)||(m.add(u),s=HT.bind(null,s,i,u),i.then(s,s))}function Fy(s){do{var i;if((i=s.tag===13)&&(i=s.memoizedState,i=i!==null?i.dehydrated!==null:!0),i)return s;s=s.return}while(s!==null);return null}function Uy(s,i,u,h,m){return(s.mode&1)===0?(s===i?s.flags|=65536:(s.flags|=128,u.flags|=131072,u.flags&=-52805,u.tag===1&&(u.alternate===null?u.tag=17:(i=vr(-1,1),i.tag=2,Gr(u,i,1))),u.lanes|=1),s):(s.flags|=65536,s.lanes=m,s)}var OT=A.ReactCurrentOwner,Ut=!1;function jt(s,i,u,h){i.child=s===null?oy(i,null,u,h):$i(i,s.child,u,h)}function Vy(s,i,u,h,m){u=u.render;var w=i.ref;return Ui(i,m),h=Zd(s,i,u,h,w,m),u=eh(),s!==null&&!Ut?(i.updateQueue=s.updateQueue,i.flags&=-2053,s.lanes&=~m,wr(s,i,m)):(Ke&&u&&Dd(i),i.flags|=1,jt(s,i,h,m),i.child)}function By(s,i,u,h,m){if(s===null){var w=u.type;return typeof w=="function"&&!Rh(w)&&w.defaultProps===void 0&&u.compare===null&&u.defaultProps===void 0?(i.tag=15,i.type=w,zy(s,i,w,h,m)):(s=Cu(u.type,null,h,i,i.mode,m),s.ref=i.ref,s.return=i,i.child=s)}if(w=s.child,(s.lanes&m)===0){var T=w.memoizedProps;if(u=u.compare,u=u!==null?u:ea,u(T,h)&&s.ref===i.ref)return wr(s,i,m)}return i.flags|=1,s=es(w,h),s.ref=i.ref,s.return=i,i.child=s}function zy(s,i,u,h,m){if(s!==null){var w=s.memoizedProps;if(ea(w,h)&&s.ref===i.ref)if(Ut=!1,i.pendingProps=h=w,(s.lanes&m)!==0)(s.flags&131072)!==0&&(Ut=!0);else return i.lanes=s.lanes,wr(s,i,m)}return uh(s,i,u,h,m)}function Wy(s,i,u){var h=i.pendingProps,m=h.children,w=s!==null?s.memoizedState:null;if(h.mode==="hidden")if((i.mode&1)===0)i.memoizedState={baseLanes:0,cachePool:null,transitions:null},Ve(Wi,Zt),Zt|=u;else{if((u&1073741824)===0)return s=w!==null?w.baseLanes|u:u,i.lanes=i.childLanes=1073741824,i.memoizedState={baseLanes:s,cachePool:null,transitions:null},i.updateQueue=null,Ve(Wi,Zt),Zt|=s,null;i.memoizedState={baseLanes:0,cachePool:null,transitions:null},h=w!==null?w.baseLanes:u,Ve(Wi,Zt),Zt|=h}else w!==null?(h=w.baseLanes|u,i.memoizedState=null):h=u,Ve(Wi,Zt),Zt|=h;return jt(s,i,m,u),i.child}function Hy(s,i){var u=i.ref;(s===null&&u!==null||s!==null&&s.ref!==u)&&(i.flags|=512,i.flags|=2097152)}
vendor: 10,646 bytes, line 41
41function uh(s,i,u,h,m){var w=Ft(u)?Os:Et.current;return w=Ii(i,w),Ui(i,m),u=Zd(s,i,u,h,w,m),h=eh(),s!==null&&!Ut?(i.updateQueue=s.updateQueue,i.flags&=-2053,s.lanes&=~m,wr(s,i,m)):(Ke&&h&&Dd(i),i.flags|=1,jt(s,i,u,m),i.child)}function qy(s,i,u,h,m){if(Ft(u)){var w=!0;Xl(i)}else w=!1;if(Ui(i,m),i.stateNode===null)gu(s,i),Iy(i,u,h),oh(i,u,h,m),h=!0;else if(s===null){var T=i.stateNode,R=i.memoizedProps;T.props=R;var j=T.context,F=u.contextType;typeof F=="object"&&F!==null?F=un(F):(F=Ft(u)?Os:Et.current,F=Ii(i,F));var Y=u.getDerivedStateFromProps,X=typeof Y=="function"||typeof T.getSnapshotBeforeUpdate=="function";X||typeof T.UNSAFE_componentWillReceiveProps!="function"&&typeof T.componentWillReceiveProps!="function"||(R!==h||j!==F)&&Ly(i,T,h,F),Kr=!1;var Q=i.memoizedState;T.state=Q,au(i,h,T,m),j=i.memoizedState,R!==h||Q!==j||$t.current||Kr?(typeof Y=="function"&&(ih(i,u,Y,h),j=i.memoizedState),(R=Kr||Ny(i,u,R,h,Q,j,F))?(X||typeof T.UNSAFE_componentWillMount!="function"&&typeof T.componentWillMount!="function"||(typeof T.componentWillMount=="function"&&T.componentWillMount(),typeof T.UNSAFE_componentWillMount=="function"&&T.UNSAFE_componentWillMount()),typeof T.componentDidMount=="function"&&(i.flags|=4194308)):(typeof T.componentDidMount=="function"&&(i.flags|=4194308),i.memoizedProps=h,i.memoizedState=j),T.props=h,T.state=j,T.context=F,h=R):(typeof T.componentDidMount=="function"&&(i.flags|=4194308),h=!1)}else{T=i.stateNode,ly(s,i),R=i.memoizedProps,F=i.type===i.elementType?R:En(i.type,R),T.props=F,X=i.pendingProps,Q=T.context,j=u.contextType,typeof j=="object"&&j!==null?j=un(j):(j=Ft(u)?Os:Et.current,j=Ii(i,j));var re=u.getDerivedStateFromProps;(Y=typeof re=="function"||typeof T.getSnapshotBeforeUpdate=="function")||typeof T.UNSAFE_componentWillReceiveProps!="function"&&typeof T.componentWillReceiveProps!="function"||(R!==X||Q!==j)&&Ly(i,T,h,j),Kr=!1,Q=i.memoizedState,T.state=Q,au(i,h,T,m);var le=i.memoizedState;R!==X||Q!==le||$t.current||Kr?(typeof re=="function"&&(ih(i,u,re,h),le=i.memoizedState),(F=Kr||Ny(i,u,F,h,Q,le,j)||!1)?(Y||typeof T.UNSAFE_componentWillUpdate!="function"&&typeof T.componentWillUpdate!="function"||(typeof T.componentWillUpdate=="function"&&T.componentWillUpdate(h,le,j),typeof T.UNSAFE_componentWillUpdate=="function"&&T.UNSAFE_componentWillUpdate(h,le,j)),typeof T.componentDidUpdate=="function"&&(i.flags|=4),typeof T.getSnapshotBeforeUpdate=="function"&&(i.flags|=1024)):(typeof T.componentDidUpdate!="function"||R===s.memoizedProps&&Q===s.memoizedState||(i.flags|=4),typeof T.getSnapshotBeforeUpdate!="function"||R===s.memoizedProps&&Q===s.memoizedState||(i.flags|=1024),i.memoizedProps=h,i.memoizedState=le),T.props=h,T.state=le,T.context=j,h=F):(typeof T.componentDidUpdate!="function"||R===s.memoizedProps&&Q===s.memoizedState||(i.flags|=4),typeof T.getSnapshotBeforeUpdate!="function"||R===s.memoizedProps&&Q===s.memoizedState||(i.flags|=1024),h=!1)}return ch(s,i,u,h,w,m)}function ch(s,i,u,h,m,w){Hy(s,i);var T=(i.flags&128)!==0;if(!h&&!T)return m&&Jg(i,u,!1),wr(s,i,w);h=i.stateNode,OT.current=i;var R=T&&typeof u.getDerivedStateFromError!="function"?null:h.render();return i.flags|=1,s!==null&&T?(i.child=$i(i,s.child,null,w),i.child=$i(i,null,R,w)):jt(s,i,R,w),i.memoizedState=h.state,m&&Jg(i,u,!0),i.child}function Ky(s){var i=s.stateNode;i.pendingContext?Qg(s,i.pendingContext,i.pendingContext!==i.context):i.context&&Qg(s,i.context,!1),Kd(s,i.containerInfo)}function Gy(s,i,u,h,m){return Mi(),Ud(m),i.flags|=256,jt(s,i,u,h),i.child}var dh={dehydrated:null,treeContext:null,retryLane:0};function hh(s){return{baseLanes:s,cachePool:null,transitions:null}}function Qy(s,i,u){var h=i.pendingProps,m=Ge.current,w=!1,T=(i.flags&128)!==0,R;if((R=T)||(R=s!==null&&s.memoizedState===null?!1:(m&2)!==0),R?(w=!0,i.flags&=-129):(s===null||s.memoizedState!==null)&&(m|=1),Ve(Ge,m&1),s===null)return Fd(i),s=i.memoizedState,s!==null&&(s=s.dehydrated,s!==null)?((i.mode&1)===0?i.lanes=1:s.data==="$!"?i.lanes=8:i.lanes=1073741824,null):(T=h.children,s=h.fallback,w?(h=i.mode,w=i.child,T={mode:"hidden",children:T},(h&1)===0&&w!==null?(w.childLanes=0,w.pendingProps=T):w=Pu(T,h,0,null),s=Bs(s,h,u,null),w.return=i,s.return=i,w.sibling=s,i.child=w,i.child.memoizedState=hh(u),i.memoizedState=dh,s):fh(i,T));if(m=s.memoizedState,m!==null&&(R=m.dehydrated,R!==null))return NT(s,i,T,h,R,m,u);if(w){w=h.fallback,T=i.mode,m=s.child,R=m.sibling;var j={mode:"hidden",children:h.children};return(T&1)===0&&i.child!==m?(h=i.child,h.childLanes=0,h.pendingProps=j,i.deletions=null):(h=es(m,j),h.subtreeFlags=m.subtreeFlags&14680064),R!==null?w=es(R,w):(w=Bs(w,T,u,null),w.flags|=2),w.return=i,h.return=i,h.sibling=w,i.child=h,h=w,w=i.child,T=s.child.memoizedState,T=T===null?hh(u):{baseLanes:T.baseLanes|u,cachePool:null,transitions:T.transitions},w.memoizedState=T,w.childLanes=s.childLanes&~u,i.memoizedState=dh,h}return w=s.child,s=w.sibling,h=es(w,{mode:"visible",children:h.children}),(i.mode&1)===0&&(h.lanes=u),h.return=i,h.sibling=null,s!==null&&(u=i.deletions,u===null?(i.deletions=[s],i.flags|=16):u.push(s)),i.child=h,i.memoizedState=null,h}function fh(s,i){return i=Pu({mode:"visible",children:i},s.mode,0,null),i.return=s,s.child=i}function mu(s,i,u,h){return h!==null&&Ud(h),$i(i,s.child,null,u),s=fh(i,i.pendingProps.children),s.flags|=2,i.memoizedState=null,s}function NT(s,i,u,h,m,w,T){if(u)return i.flags&256?(i.flags&=-257,h=ah(Error(n(422))),mu(s,i,T,h)):i.memoizedState!==null?(i.child=s.child,i.flags|=128,null):(w=h.fallback,m=i.mode,h=Pu({mode:"visible",children:h.children},m,0,null),w=Bs(w,m,T,null),w.flags|=2,h.return=i,w.return=i,h.sibling=w,i.child=h,(i.mode&1)!==0&&$i(i,s.child,null,T),i.child.memoizedState=hh(T),i.memoizedState=dh,w);if((i.mode&1)===0)return mu(s,i,T,null);if(m.data==="$!"){if(h=m.nextSibling&&m.nextSibling.dataset,h)var R=h.dgst;return h=R,w=Error(n(419)),h=ah(w,h,void 0),mu(s,i,T,h)}if(R=(T&s.childLanes)!==0,Ut||R){if(h=ft,h!==null){switch(T&-T){case 4:m=2;break;case 16:m=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:m=32;break;case 536870912:m=268435456;break;default:m=0}m=(m&(h.suspendedLanes|T))!==0?0:m,m!==0&&m!==w.retryLane&&(w.retryLane=m,yr(s,m),Cn(h,s,m,-1))}return Ah(),h=ah(Error(n(421))),mu(s,i,T,h)}return m.data==="$?"?(i.flags|=128,i.child=s.child,i=qT.bind(null,s),m._reactRetry=i,null):(s=w.treeContext,Xt=zr(m.nextSibling),Jt=i,Ke=!0,_n=null,s!==null&&(an[ln++]=mr,an[ln++]=gr,an[ln++]=Ns,mr=s.id,gr=s.overflow,Ns=i),i=fh(i,h.children),i.flags|=4096,i)}function Yy(s,i,u){s.lanes|=i;var h=s.alternate;h!==null&&(h.lanes|=i),Wd(s.return,i,u)}function ph(s,i,u,h,m){var w=s.memoizedState;w===null?s.memoizedState={isBackwards:i,rendering:null,renderingStartTime:0,last:h,tail:u,tailMode:m}:(w.isBackwards=i,w.rendering=null,w.renderingStartTime=0,w.last=h,w.tail=u,w.tailMode=m)}function Jy(s,i,u){var h=i.pendingProps,m=h.revealOrder,w=h.tail;if(jt(s,i,h.children,u),h=Ge.current,(h&2)!==0)h=h&1|2,i.flags|=128;else{if(s!==null&&(s.flags&128)!==0)e:for(s=i.child;s!==null;){if(s.tag===13)s.memoizedState!==null&&Yy(s,u,i);else if(s.tag===19)Yy(s,u,i);else if(s.child!==null){s.child.return=s,s=s.child;continue}if(s===i)break e;for(;s.sibling===null;){if(s.return===null||s.return===i)break e;s=s.return}s.sibling.return=s.return,s=s.sibling}h&=1}if(Ve(Ge,h),(i.mode&1)===0)i.memoizedState=null;else switch(m){case"forwards":for(u=i.child,m=null;u!==null;)s=u.alternate,s!==null&&lu(s)===null&&(m=u),u=u.sibling;u=m,u===null?(m=i.child,i.child=null):(m=u.sibling,u.sibling=null),ph(i,!1,m,u,w);break;case"backwards":for(u=null,m=i.child,i.child=null;m!==null;){if(s=m.alternate,s!==null&&lu(s)===null){i.child=m;break}s=m.sibling,m.sibling=u,u=m,m=s}ph(i,!0,u,null,w);break;case"together":ph(i,!1,null,null,void 0);break;default:i.memoizedState=null}return i.child}function gu(s,i){(i.mode&1)===0&&s!==null&&(s.alternate=null,i.alternate=null,i.flags|=2)}function wr(s,i,u){if(s!==null&&(i.dependencies=s.dependencies),$s|=i.lanes,(u&i.childLanes)===0)return null;if(s!==null&&i.child!==s.child)throw Error(n(153));if(i.child!==null){for(s=i.child,u=es(s,s.pendingProps),i.child=u,u.return=i;s.sibling!==null;)s=s.sibling,u=u.sibling=es(s,s.pendingProps),u.return=i;u.sibling=null}return i.child}function IT(s,i,u){switch(i.tag){case 3:Ky(i),Mi();break;case 5:dy(i);break;case 1:Ft(i.type)&&Xl(i);break;case 4:Kd(i,i.stateNode.containerInfo);break;case 10:var h=i.type._context,m=i.memoizedProps.value;Ve(su,h._currentValue),h._currentValue=m;break;case 13:if(h=i.memoizedState,h!==null)return h.dehydrated!==null?(Ve(Ge,Ge.current&1),i.flags|=128,null):(u&i.child.childLanes)!==0?Qy(s,i,u):(Ve(Ge,Ge.current&1),s=wr(s,i,u),s!==null?s.sibling:null);Ve(Ge,Ge.current&1);break;case 19:if(h=(u&i.childLanes)!==0,(s.flags&128)!==0){if(h)return Jy(s,i,u);i.flags|=128}if(m=i.memoizedState,m!==null&&(m.rendering=null,m.tail=null,m.lastEffect=null),Ve(Ge,Ge.current),h)break;return null;case 22:case 23:return i.lanes=0,Wy(s,i,u)}return wr(s,i,u)}var Xy,mh,Zy,ev;Xy=function(s,i){for(var u=i.child;u!==null;){if(u.tag===5||u.tag===6)s.appendChild(u.stateNode);else if(u.tag!==4&&u.child!==null){u.child.return=u,u=u.child;continue}if(u===i)break;for(;u.sibling===null;){if(u.return===null||u.return===i)return;u=u.return}u.sibling.return=u.return,u=u.sibling}},mh=function(){},Zy=function(s,i,u,h){var m=s.memoizedProps;if(m!==h){s=i.stateNode,Ds(Xn.current);var w=null;switch(u){case"input":m=Nr(s,m),h=Nr(s,h),w=[];break;case"select":m=G({},m,{value:void 0}),h=G({},h,{value:void 0}),w=[];break;case"textarea":m=xi(s,m),h=xi(s,h),w=[];break;default:typeof m.onClick!="function"&&typeof h.onClick=="function"&&(s.onclick=Ql)}Kn(u,h);var T;u=null;for(F in m)if(!h.hasOwnProperty(F)&&m.hasOwnProperty(F)&&m[F]!=null)if(F==="style"){var R=m[F];for(T in R)R.hasOwnProperty(T)&&(u||(u={}),u[T]="")}else F!=="dangerouslySetInnerHTML"&&F!=="children"&&F!=="suppressContentEditableWarning"&&F!=="suppressHydrationWarning"&&F!=="autoFocus"&&(o.hasOwnProperty(F)?w||(w=[]):(w=w||[]).push(F,null));for(F in h){var j=h[F];if(R=m!=null?m[F]:void 0,h.hasOwnProperty(F)&&j!==R&&(j!=null||R!=null))if(F==="style")if(R){for(T in R)!R.hasOwnProperty(T)||j&&j.hasOwnProperty(T)||(u||(u={}),u[T]="");for(T in j)j.hasOwnProperty(T)&&R[T]!==j[T]&&(u||(u={}),u[T]=j[T])}else u||(w||(w=[]),w.push(F,u)),u=j;else F==="dangerouslySetInnerHTML"?(j=j?j.__html:void 0,R=R?R.__html:void 0,j!=null&&R!==j&&(w=w||[]).push(F,j)):F==="children"?typeof j!="str
41ing"&&typeof j!="number"||(w=w||[]).push(F,""+j):F!=="suppressContentEditableWarning"&&F!=="suppressHydrationWarning"&&(o.hasOwnProperty(F)?(j!=null&&F==="onScroll"&&ze("scroll",s),w||R===j||(w=[])):(w=w||[]).push(F,j))}u&&(w=w||[]).push("style",u);var F=w;(i.updateQueue=F)&&(i.flags|=4)}},ev=function(s,i,u,h){u!==h&&(i.flags|=4)};function ma(s,i){if(!Ke)switch(s.tailMode){case"hidden":i=s.tail;for(var u=null;i!==null;)i.alternate!==null&&(u=i),i=i.sibling;u===null?s.tail=null:u.sibling=null;break;case"collapsed":u=s.tail;for(var h=null;u!==null;)u.alternate!==null&&(h=u),u=u.sibling;h===null?i||s.tail===null?s.tail=null:s.tail.sibling=null:h.sibling=null}}function kt(s){var i=s.alternate!==null&&s.alternate.child===s.child,u=0,h=0;if(i)for(var m=s.child;m!==null;)u|=m.lanes|m.childLanes,h|=m.subtreeFlags&14680064,h|=m.flags&14680064,m.return=s,m=m.sibling;else for(m=s.child;m!==null;)u|=m.lanes|m.childLanes,h|=m.subtreeFlags,h|=m.flags,m.return=s,m=m.sibling;return s.subtreeFlags|=h,s.childLanes=u,i}function LT(s,i,u){var h=i.pendingProps;switch(Md(i),i.tag){case 2:case 16:case 15:case 0:case 11:case 7:case 8:case 12:case 9:case 14:return kt(i),null;case 1:return Ft(i.type)&&Jl(),kt(i),null;case 3:return h=i.stateNode,Vi(),We($t),We(Et),Yd(),h.pendingContext&&(h.context=h.pendingContext,h.pendingContext=null),(s===null||s.child===null)&&(nu(i)?i.flags|=4:s===null||s.memoizedState.isDehydrated&&(i.flags&256)===0||(i.flags|=1024,_n!==null&&(kh(_n),_n=null))),mh(s,i),kt(i),null;case 5:Gd(i);var m=Ds(ca.current);if(u=i.type,s!==null&&i.stateNode!=null)Zy(s,i,u,h,m),s.ref!==i.ref&&(i.flags|=512,i.flags|=2097152);else{if(!h){if(i.stateNode===null)throw Error(n(166));return kt(i),null}if(s=Ds(Xn.current),nu(i)){h=i.stateNode,u=i.type;var w=i.memoizedProps;switch(h[Jn]=i,h[ia]=w,s=(i.mode&1)!==0,u){case"dialog":ze("cancel",h),ze("close",h);break;case"iframe":case"object":case"embed":ze("load",h);break;case"video":case"audio":for(m=0;m<na.length;m++)ze(na[m],h);break;case"source":ze("error",h);break;case"img":case"image":case"link":ze("error",h),ze("load",h);break;case"details":ze("toggle",h);break;case"input":wi(h,w),ze("invalid",h);break;case"select":h._wrapperState={wasMultiple:!!w.multiple},ze("invalid",h);break;case"textarea":Wn(h,w),ze("invalid",h)}Kn(u,w),m=null;for(var T in w)if(w.hasOwnProperty(T)){var R=w[T];T==="children"?typeof R=="string"?h.textContent!==R&&(w.suppressHydrationWarning!==!0&&Gl(h.textContent,R,s),m=["children",R]):typeof R=="number"&&h.textContent!==""+R&&(w.suppressHydrationWarning!==!0&&Gl(h.textContent,R,s),m=["children",""+R]):o.hasOwnProperty(T)&&R!=null&&T==="onScroll"&&ze("scroll",h)}switch(u){case"input":Gt(h),Ir(h,w,!0);break;case"textarea":Gt(h),_l(h);break;case"select":case"option":break;default:typeof w.onClick=="function"&&(h.onclick=Ql)}h=m,i.updateQueue=h,h!==null&&(i.flags|=4)}else{T=m.nodeType===9?m:m.ownerDocument,s==="http://www.w3.org/1999/xhtml"&&(s=At(u)),s==="http://www.w3.org/1999/xhtml"?u==="script"?(s=T.createElement("div"),s.innerHTML="<script><\/script>",s=s.removeChild(s.firstChild)):typeof h.is=="string"?s=T.createElement(u,{is:h.is}):(s=T.createElement(u),u==="select"&&(T=s,h.multiple?T.multiple=!0:h.size&&(T.size=h.size))):s=T.createElementNS(s,u),s[Jn]=i,s[ia]=h,Xy(s,i,!1,!1),i.stateNode=s;e:{switch(T=Fo(u,h),u){case"dialog":ze("cancel",s),ze("close",s),m=h;break;case"iframe":case"object":case"embed":ze("load",s),m=h;break;case"video":case"audio":for(m=0;m<na.length;m++)ze(na[m],s);m=h;break;case"source":ze("error",s),m=h;break;case"img":case"image":case"link":ze("error",s),ze("load",s),m=h;break;case"details":ze("toggle",s),m=h;break;case"input":wi(s,h),m=Nr(s,h),ze("invalid",s);break;case"option":m=h;break;case"select":s._wrapperState={wasMultiple:!!h.multiple},m=G({},h,{value:void 0}),ze("invalid",s);break;case"textarea":Wn(s,h),m=xi(s,h),ze("invalid",s);break;default:m=h}Kn(u,m),R=m;for(w in R)if(R.hasOwnProperty(w)){var j=R[w];w==="style"?hr(s,j):w==="dangerouslySetInnerHTML"?(j=j?j.__html:void 0,j!=null&&El(s,j)):w==="children"?typeof j=="string"?(u!=="textarea"||j!=="")&&qn(s,j):typeof j=="number"&&qn(s,""+j):w!=="suppressContentEditableWarning"&&w!=="suppressHydrationWarning"&&w!=="autoFocus"&&(o.hasOwnProperty(w)?j!=null&&w==="onScroll"&&ze("scroll",s):j!=null&&C(s,w,j,T))}switch(u){case"input":Gt(s),Ir(s,h,!1);break;case"textarea":Gt(s),_l(s);break;case"option":h.value!=null&&s.setAttribute("value",""+Ae(h.value));break;case"select":s.multiple=!!h.multiple,w=h.value,w!=null?on(s,!!h.multiple,w,!1):h.defaultValue!=null&&on(s,!!h.multiple,h.defaultValue,!0);break;default:typeof m.onClick=="function"&&(s.onclick=Ql)}switch(u){case"button":case"input":case"select":case"textarea":h=!!h.autoFocus;break e;case"img":h=!0;break e;default:h=!1}}h&&(i.flags|=4)}i.ref!==null&&(i.flags|=512,i.flags|=2097152)}
vendor: 22,962 bytes, line 41
41return kt(i),null;case 6:if(s&&i.stateNode!=null)ev(s,i,s.memoizedProps,h);else{if(typeof h!="string"&&i.stateNode===null)throw Error(n(166));if(u=Ds(ca.current),Ds(Xn.current),nu(i)){if(h=i.stateNode,u=i.memoizedProps,h[Jn]=i,(w=h.nodeValue!==u)&&(s=Jt,s!==null))switch(s.tag){case 3:Gl(h.nodeValue,u,(s.mode&1)!==0);break;case 5:s.memoizedProps.suppressHydrationWarning!==!0&&Gl(h.nodeValue,u,(s.mode&1)!==0)}w&&(i.flags|=4)}else h=(u.nodeType===9?u:u.ownerDocument).createTextNode(h),h[Jn]=i,i.stateNode=h}return kt(i),null;case 13:if(We(Ge),h=i.memoizedState,s===null||s.memoizedState!==null&&s.memoizedState.dehydrated!==null){if(Ke&&Xt!==null&&(i.mode&1)!==0&&(i.flags&128)===0)ry(),Mi(),i.flags|=98560,w=!1;else if(w=nu(i),h!==null&&h.dehydrated!==null){if(s===null){if(!w)throw Error(n(318));if(w=i.memoizedState,w=w!==null?w.dehydrated:null,!w)throw Error(n(317));w[Jn]=i}else Mi(),(i.flags&128)===0&&(i.memoizedState=null),i.flags|=4;kt(i),w=!1}else _n!==null&&(kh(_n),_n=null),w=!0;if(!w)return i.flags&65536?i:null}return(i.flags&128)!==0?(i.lanes=u,i):(h=h!==null,h!==(s!==null&&s.memoizedState!==null)&&h&&(i.child.flags|=8192,(i.mode&1)!==0&&(s===null||(Ge.current&1)!==0?lt===0&&(lt=3):Ah())),i.updateQueue!==null&&(i.flags|=4),kt(i),null);case 4:return Vi(),mh(s,i),s===null&&ra(i.stateNode.containerInfo),kt(i),null;case 10:return zd(i.type._context),kt(i),null;case 17:return Ft(i.type)&&Jl(),kt(i),null;case 19:if(We(Ge),w=i.memoizedState,w===null)return kt(i),null;if(h=(i.flags&128)!==0,T=w.rendering,T===null)if(h)ma(w,!1);else{if(lt!==0||s!==null&&(s.flags&128)!==0)for(s=i.child;s!==null;){if(T=lu(s),T!==null){for(i.flags|=128,ma(w,!1),h=T.updateQueue,h!==null&&(i.updateQueue=h,i.flags|=4),i.subtreeFlags=0,h=u,u=i.child;u!==null;)w=u,s=h,w.flags&=14680066,T=w.alternate,T===null?(w.childLanes=0,w.lanes=s,w.child=null,w.subtreeFlags=0,w.memoizedProps=null,w.memoizedState=null,w.updateQueue=null,w.dependencies=null,w.stateNode=null):(w.childLanes=T.childLanes,w.lanes=T.lanes,w.child=T.child,w.subtreeFlags=0,w.deletions=null,w.memoizedProps=T.memoizedProps,w.memoizedState=T.memoizedState,w.updateQueue=T.updateQueue,w.type=T.type,s=T.dependencies,w.dependencies=s===null?null:{lanes:s.lanes,firstContext:s.firstContext}),u=u.sibling;return Ve(Ge,Ge.current&1|2),i.child}s=s.sibling}w.tail!==null&&tt()>Hi&&(i.flags|=128,h=!0,ma(w,!1),i.lanes=4194304)}else{if(!h)if(s=lu(T),s!==null){if(i.flags|=128,h=!0,u=s.updateQueue,u!==null&&(i.updateQueue=u,i.flags|=4),ma(w,!0),w.tail===null&&w.tailMode==="hidden"&&!T.alternate&&!Ke)return kt(i),null}else 2*tt()-w.renderingStartTime>Hi&&u!==1073741824&&(i.flags|=128,h=!0,ma(w,!1),i.lanes=4194304);w.isBackwards?(T.sibling=i.child,i.child=T):(u=w.last,u!==null?u.sibling=T:i.child=T,w.last=T)}return w.tail!==null?(i=w.tail,w.rendering=i,w.tail=i.sibling,w.renderingStartTime=tt(),i.sibling=null,u=Ge.current,Ve(Ge,h?u&1|2:u&1),i):(kt(i),null);case 22:case 23:return Ph(),h=i.memoizedState!==null,s!==null&&s.memoizedState!==null!==h&&(i.flags|=8192),h&&(i.mode&1)!==0?(Zt&1073741824)!==0&&(kt(i),i.subtreeFlags&6&&(i.flags|=8192)):kt(i),null;case 24:return null;case 25:return null}throw Error(n(156,i.tag))}function DT(s,i){switch(Md(i),i.tag){case 1:return Ft(i.type)&&Jl(),s=i.flags,s&65536?(i.flags=s&-65537|128,i):null;case 3:return Vi(),We($t),We(Et),Yd(),s=i.flags,(s&65536)!==0&&(s&128)===0?(i.flags=s&-65537|128,i):null;case 5:return Gd(i),null;case 13:if(We(Ge),s=i.memoizedState,s!==null&&s.dehydrated!==null){if(i.alternate===null)throw Error(n(340));Mi()}return s=i.flags,s&65536?(i.flags=s&-65537|128,i):null;case 19:return We(Ge),null;case 4:return Vi(),null;case 10:return zd(i.type._context),null;case 22:case 23:return Ph(),null;case 24:return null;default:return null}}var yu=!1,Ct=!1,MT=typeof WeakSet=="function"?WeakSet:Set,ae=null;function zi(s,i){var u=s.ref;if(u!==null)if(typeof u=="function")try{u(null)}catch(h){Ye(s,i,h)}else u.current=null}function gh(s,i,u){try{u()}catch(h){Ye(s,i,h)}}var tv=!1;function $T(s,i){if(Pd=Ml,s=Ng(),xd(s)){if("selectionStart"in s)var u={start:s.selectionStart,end:s.selectionEnd};else e:{u=(u=s.ownerDocument)&&u.defaultView||window;var h=u.getSelection&&u.getSelection();if(h&&h.rangeCount!==0){u=h.anchorNode;var m=h.anchorOffset,w=h.focusNode;h=h.focusOffset;try{u.nodeType,w.nodeType}catch{u=null;break e}var T=0,R=-1,j=-1,F=0,Y=0,X=s,Q=null;t:for(;;){for(var re;X!==u||m!==0&&X.nodeType!==3||(R=T+m),X!==w||h!==0&&X.nodeType!==3||(j=T+h),X.nodeType===3&&(T+=X.nodeValue.length),(re=X.firstChild)!==null;)Q=X,X=re;for(;;){if(X===s)break t;if(Q===u&&++F===m&&(R=T),Q===w&&++Y===h&&(j=T),(re=X.nextSibling)!==null)break;X=Q,Q=X.parentNode}X=re}u=R===-1||j===-1?null:{start:R,end:j}}else u=null}u=u||{start:0,end:0}}else u=null;for(Ad={focusedElem:s,selectionRange:u},Ml=!1,ae=i;ae!==null;)if(i=ae,s=i.child,(i.subtreeFlags&1028)!==0&&s!==null)s.return=i,ae=s;else for(;ae!==null;){i=ae;try{var le=i.alternate;if((i.flags&1024)!==0)switch(i.tag){case 0:case 11:case 15:break;case 1:if(le!==null){var he=le.memoizedProps,nt=le.memoizedState,M=i.stateNode,I=M.getSnapshotBeforeUpdate(i.elementType===i.type?he:En(i.type,he),nt);M.__reactInternalSnapshotBeforeUpdate=I}break;case 3:var $=i.stateNode.containerInfo;$.nodeType===1?$.textContent="":$.nodeType===9&&$.documentElement&&$.removeChild($.documentElement);break;case 5:case 6:case 4:case 17:break;default:throw Error(n(163))}}catch(ee){Ye(i,i.return,ee)}if(s=i.sibling,s!==null){s.return=i.return,ae=s;break}ae=i.return}return le=tv,tv=!1,le}function ga(s,i,u){var h=i.updateQueue;if(h=h!==null?h.lastEffect:null,h!==null){var m=h=h.next;do{if((m.tag&s)===s){var w=m.destroy;m.destroy=void 0,w!==void 0&&gh(i,u,w)}m=m.next}while(m!==h)}}function vu(s,i){if(i=i.updateQueue,i=i!==null?i.lastEffect:null,i!==null){var u=i=i.next;do{if((u.tag&s)===s){var h=u.create;u.destroy=h()}u=u.next}while(u!==i)}}function yh(s){var i=s.ref;if(i!==null){var u=s.stateNode;switch(s.tag){case 5:s=u;break;default:s=u}typeof i=="function"?i(s):i.current=s}}function nv(s){var i=s.alternate;i!==null&&(s.alternate=null,nv(i)),s.child=null,s.deletions=null,s.sibling=null,s.tag===5&&(i=s.stateNode,i!==null&&(delete i[Jn],delete i[ia],delete i[Nd],delete i[xT],delete i[bT])),s.stateNode=null,s.return=null,s.dependencies=null,s.memoizedProps=null,s.memoizedState=null,s.pendingProps=null,s.stateNode=null,s.updateQueue=null}function rv(s){return s.tag===5||s.tag===3||s.tag===4}function sv(s){e:for(;;){for(;s.sibling===null;){if(s.return===null||rv(s.return))return null;s=s.return}for(s.sibling.return=s.return,s=s.sibling;s.tag!==5&&s.tag!==6&&s.tag!==18;){if(s.flags&2||s.child===null||s.tag===4)continue e;s.child.return=s,s=s.child}if(!(s.flags&2))return s.stateNode}}function vh(s,i,u){var h=s.tag;if(h===5||h===6)s=s.stateNode,i?u.nodeType===8?u.parentNode.insertBefore(s,i):u.insertBefore(s,i):(u.nodeType===8?(i=u.parentNode,i.insertBefore(s,u)):(i=u,i.appendChild(s)),u=u._reactRootContainer,u!=null||i.onclick!==null||(i.onclick=Ql));else if(h!==4&&(s=s.child,s!==null))for(vh(s,i,u),s=s.sibling;s!==null;)vh(s,i,u),s=s.sibling}function wh(s,i,u){var h=s.tag;if(h===5||h===6)s=s.stateNode,i?u.insertBefore(s,i):u.appendChild(s);else if(h!==4&&(s=s.child,s!==null))for(wh(s,i,u),s=s.sibling;s!==null;)wh(s,i,u),s=s.sibling}var yt=null,Tn=!1;function Qr(s,i,u){for(u=u.child;u!==null;)iv(s,i,u),u=u.sibling}function iv(s,i,u){if(Yn&&typeof Yn.onCommitFiberUnmount=="function")try{Yn.onCommitFiberUnmount(jl,u)}catch{}switch(u.tag){case 5:Ct||zi(u,i);case 6:var h=yt,m=Tn;yt=null,Qr(s,i,u),yt=h,Tn=m,yt!==null&&(Tn?(s=yt,u=u.stateNode,s.nodeType===8?s.parentNode.removeChild(u):s.removeChild(u)):yt.removeChild(u.stateNode));break;case 18:yt!==null&&(Tn?(s=yt,u=u.stateNode,s.nodeType===8?Od(s.parentNode,u):s.nodeType===1&&Od(s,u),Go(s)):Od(yt,u.stateNode));break;case 4:h=yt,m=Tn,yt=u.stateNode.containerInfo,Tn=!0,Qr(s,i,u),yt=h,Tn=m;break;case 0:case 11:case 14:case 15:if(!Ct&&(h=u.updateQueue,h!==null&&(h=h.lastEffect,h!==null))){m=h=h.next;do{var w=m,T=w.destroy;w=w.tag,T!==void 0&&((w&2)!==0||(w&4)!==0)&&gh(u,i,T),m=m.next}while(m!==h)}Qr(s,i,u);break;case 1:if(!Ct&&(zi(u,i),h=u.stateNode,typeof h.componentWillUnmount=="function"))try{h.props=u.memoizedProps,h.state=u.memoizedState,h.componentWillUnmount()}catch(R){Ye(u,i,R)}Qr(s,i,u);break;case 21:Qr(s,i,u);break;case 22:u.mode&1?(Ct=(h=Ct)||u.memoizedState!==null,Qr(s,i,u),Ct=h):Qr(s,i,u);break;default:Qr(s,i,u)}}function ov(s){var i=s.updateQueue;if(i!==null){s.updateQueue=null;var u=s.stateNode;u===null&&(u=s.stateNode=new MT),i.forEach(function(h){var m=KT.bind(null,s,h);u.has(h)||(u.add(h),h.then(m,m))})}}function kn(s,i){var u=i.deletions;if(u!==null)for(var h=0;h<u.length;h++){var m=u[h];try{var w=s,T=i,R=T;e:for(;R!==null;){switch(R.tag){case 5:yt=R.stateNode,Tn=!1;break e;case 3:yt=R.stateNode.containerInfo,Tn=!0;break e;case 4:yt=R.stateNode.containerInfo,Tn=!0;break e}R=R.return}if(yt===null)throw Error(n(160));iv(w,T,m),yt=null,Tn=!1;var j=m.alternate;j!==null&&(j.return=null),m.return=null}catch(F){Ye(m,i,F)}}if(i.subtreeFlags&12854)for(i=i.child;i!==null;)av(i,s),i=i.sibling}function av(s,i){var u=s.alternate,h=s.flags;switch(s.tag){case 0:case 11:case 14:case 15:if(kn(i,s),er(s),h&4){try{ga(3,s,s.return),vu(3,s)}catch(he){Ye(s,s.return,he)}try{ga(5,s,s.return)}catch(he){Ye(s,s.return,he)}}break;case 1:kn(i,s),er(s),h&512&&u!==null&&zi(u,u.return);break;case 5:if(kn(i,s),er(s),h&512&&u!==null&&zi(u,u.return),s.flags&32){var m=s.stateNode;try{qn(m,"")}catch(he){Ye(s,s.return,he)}}if(h&4&&(m=s.stateNode,m!=null)){var w=s.memoizedProps,T=u!==null?u.memoizedProps:w,R=s.type,j=s.updateQueue;if(s.updateQueue=null,j!==null)try{R==="input"&&w.type==="radio"&&w.name!=null&&Cs(m,w),Fo(R,T);var F=Fo(R,w);for(T=0;T<j.length;T+=2){var Y=j[T],X=j[T+1];Y==="style"?hr(m,X):Y==="dangerouslySetInnerHTML"?El(m,X):Y==="children"?qn(m,X):C(m,Y,X,F)}switch(R){case"input":Ps(m,w);break;case"textarea":Sl(m,w);break;case"select":var Q=m._wrapperState.wasMultiple;m._wrapperState.wasMultiple=!!w.multiple;var re=w.value;re!=null?on(m,!!w.multiple,re,!1):Q!==!!w.multiple&&(w.defaultValue!=null?on(m,!!w.multiple,w.defaultValue,!0):on(m,!!w.multiple,w.multiple?[]:"",!1))}m[ia]=w}catch(he){Ye(s,s.return,he)}}break;case 6:if(kn(i,s),er(s),h&4){if(s.stateNode===null)throw Error(n(162));m=s.stateNode,w=s.memoizedProps;try{m.nodeValue=w}catch(he){Ye(s,s.return,he)}}break;case 3:if(kn(i,s),er(s),h&4&&u!==null&&u.memoizedState.isDehydrated)try{Go(i.containerInfo)}catch(he){Ye(s,s.return,he)}break;case 4:kn(i,s),er(s);break;case 13:kn(i,s),er(s),m=s.child,m.flags&8192&&(w=m.memoizedState!==null,m.stateNode.isHidden=w,!w||m.alternate!==null&&m.alternate.memoizedState!==null||(Sh=tt())),h&4&&ov(s);break;case 22:if(Y=u!==null&&u.memoizedState!==null,s.mode&1?(Ct=(F=Ct)||Y,kn(i,s),Ct=F):kn(i,s),er(s),h&8192){if(F=s.memoizedState!==null,(s.stateNode.isHidden=F)&&!Y&&(s.mode&1)!==0)for(ae=s,Y=s.child;Y!==null;){for(X=ae=Y;ae!==null;){switch(Q=ae,re=Q.child,Q.tag){case 0:case 11:case 14:case 15:ga(4,Q,Q.return);break;case 1:zi(Q,Q.return);var le=Q.stateNode;if(typeof le.componentWillUnmount=="function"){h=Q,u=Q.return;try{i=h,le.props=i.memoizedProps,le.state=i.memoizedState,le.componentWillUnmount()}catch(he){Ye(h,u,he)}}break;case 5:zi(Q,Q.return);break;case 22:if(Q.memoizedState!==null){cv(X);continue}}re!==null?(re.return=Q,ae=re):cv(X)}Y=Y.sibling}e:for(Y=null,X=s;;){if(X.tag===5){if(Y===null){Y=X;try{m=X.stateNode,F?(w=m.style,typeof w.setProperty=="function"?w.setProperty("display","none","important"):w.display="none"):(R=X.stateNode,j=X.memoizedProps.style,T=j!=null&&j.hasOwnProperty("display")?j.display:null,R.style.display=Si("display",T))}catch(he){Ye(s,s.return,he)}}}else if(X.tag===6){if(Y===null)try{X.stateNode.nodeValue=F?"":X.memoizedProps}catch(he){Ye(s,s.return,he)}}else if((X.tag!==22&&X.tag!==23||X.memoizedState===null||X===s)&&X.child!==null){X.child.return=X,X=X.child;continue}if(X===s)break e;for(;X.sibling===null;){if(X.return===null||X.return===s)break e;Y===X&&(Y=null),X=X.return}Y===X&&(Y=null),X.sibling.return=X.return,X=X.sibling}}break;case 19:kn(i,s),er(s),h&4&&ov(s);break;case 21:break;default:kn(i,s),er(s)}}function er(s){var i=s.flags;if(i&2){try{e:{for(var u=s.return;u!==null;){if(rv(u)){var h=u;break e}u=u.return}throw Error(n(160))}switch(h.tag){case 5:var m=h.stateNode;h.flags&32&&(qn(m,""),h.flags&=-33);var w=sv(s);wh(s,w,m);break;case 3:case 4:var T=h.stateNode.containerInfo,R=sv(s);vh(s,R,T);break;default:throw Error(n(161))}}catch(j){Ye(s,s.return,j)}s.flags&=-3}i&4096&&(s.flags&=-4097)}function FT(s,i,u){ae=s,lv(s)}function lv(s,i,u){for(var h=(s.mode&1)!==0;ae!==null;){var m=ae,w=m.child;if(m.tag===22&&h){var T=m.memoizedState!==null||yu;if(!T){var R=m.alternate,j=R!==null&&R.memoizedState!==null||Ct;R=yu;var F=Ct;if(yu=T,(Ct=j)&&!F)for(ae=m;ae!==null;)T=ae,j=T.child,T.tag===22&&T.memoizedState!==null?dv(m):j!==null?(j.return=T,ae=j):dv(m);for(;w!==null;)ae=w,lv(w),w=w.sibling;ae=m,yu=R,Ct=F}uv(s)}else(m.subtreeFlags&8772)!==0&&w!==null?(w.return=m,ae=w):uv(s)}}function uv(s){for(;ae!==null;){var i=ae;if((i.flags&8772)!==0){var u=i.alternate;try{if((i.flags&8772)!==0)switch(i.tag){case 0:case 11:case 15:Ct||vu(5,i);break;case 1:var h=i.stateNode;if(i.flags&4&&!Ct)if(u===null)h.componentDidMount();else{var m=i.elementType===i.type?u.memoizedProps:En(i.type,u.memoizedProps);h.componentDidUpdate(m,u.memoizedState,h.__reactInternalSnapshotBeforeUpdate)}var w=i.updateQueue;w!==null&&cy(i,w,h);break;case 3:var T=i.updateQueue;if(T!==null){if(u=null,i.child!==null)switch(i.child.tag){case 5:u=i.child.stateNode;break;case 1:u=i.child.stateNode}cy(i,T,u)}break;case 5:var R=i.stateNode;if(u===null&&i.flags&4){u=R;var j=i.memoizedProps;switch(i.type){case"button":case"input":case"select":case"textarea":j.autoFocus&&u.focus();break;case"img":j.src&&(u.src=j.src)}}break;case 6:break;case 4:break;case 12:break;case 13:if(i.memoizedState===null){var F=i.alternate;if(F!==null){var Y=F.memoizedState;if(Y!==null){var X=Y.dehydrated;X!==null&&Go(X)}}}break;case 19:case 17:case 21:case 22:case 23:case 25:break;default:throw Error(n(163))}Ct||i.flags&512&&yh(i)}catch(Q){Ye(i,i.return,Q)}}if(i===s){ae=null;break}if(u=i.sibling,u!==null){u.return=i.return,ae=u;break}ae=i.return}}function cv(s){for(;ae!==null;){var i=ae;if(i===s){ae=null;break}var u=i.sibling;if(u!==null){u.return=i.return,ae=u;break}ae=i.return}}function dv(s){for(;ae!==null;){var i=ae;try{switch(i.tag){case 0:case 11:case 15:var u=i.return;try{vu(4,i)}catch(j){Ye(i,u,j)}break;case 1:var h=i.stateNode;if(typeof h.componentDidMount=="function"){var m=i.return;try{h.componentDidMount()}catch(j){Ye(i,m,j)}}var w=i.return;try{yh(i)}catch(j){Ye(i,w,j)}break;case 5:var T=i.return;try{yh(i)}catch(j){Ye(i,T,j)}}}catch(j){Ye(i,i.return,j)}if(i===s){ae=null;break}var R=i.sibling;if(R!==null){R.return=i.return,ae=R;break}ae=i.return}}var UT=Math.ceil,wu=A.ReactCurrentDispatcher,xh=A.ReactCurrentOwner,dn=A.ReactCurrentBatchConfig,Ie=0,ft=null,rt=null,vt=0,Zt=0,Wi=Wr(0),lt=0,ya=null,$s=0,xu=0,bh=0,va=null,Vt=null,Sh=0,Hi=1/0,xr=null,bu=!1,_h=null,Yr=null,Su=!1,Jr=null,_u=0,wa=0,Eh=null,Eu=-1,Tu=0;function Ot(){return(Ie&6)!==0?tt():Eu!==-1?Eu:Eu=tt()}function Xr(s){return(s.mode&1)===0?1:(Ie&2)!==0&&vt!==0?vt&-vt:_T.transition!==null?(Tu===0&&(Tu=sg()),Tu):(s=$e,s!==0||(s=window.event,s=s===void 0?16:fg(s.type)),s)}function Cn(s,i,u,h){if(50<wa)throw wa=0,Eh=null,Error(n(185));zo(s,u,h),((Ie&2)===0||s!==ft)&&(s===ft&&((Ie&2)===0&&(xu|=u),lt===4&&Zr(s,vt)),Bt(s,h),u===1&&Ie===0&&(i.mode&1)===0&&(Hi=tt()+500,Zl&&qr()))}function Bt(s,i){var u=s.callbackNode;_E(s,i);var h=Il(s,s===ft?vt:0);if(h===0)u!==null&&tg(u),s.callbackNode=null,s.callbackPriority=0;else if(i=h&-h,s.callbackPriority!==i){if(u!=null&&tg(u),i===1)s.tag===0?ST(fv.bind(null,s)):Xg(fv.bind(null,s)),vT(function(){(Ie&6)===0&&qr()}),u=null;else{switch(ig(h)){case 1:u=rd;break;case 4:u=ng;break;case 16:u=Rl;break;case 536870912:u=rg;break;default:u=Rl}u=bv(u,hv.bind(null,s))}s.callbackPriority=i,s.callbackNode=u}}function hv(s,i){if(Eu=-1,Tu=0,(Ie&6)!==0)throw Error(n(327));var u=s.callbackNode;if(qi()&&s.callbackNode!==u)return null;var h=Il(s,s===ft?vt:0);if(h===0)return null;if((h&30)!==0||(h&s.expiredLanes)!==0||i)i=ku(s,h);else{i=h;var m=Ie;Ie|=2;var w=mv();(ft!==s||vt!==i)&&(xr=null,Hi=tt()+500,Us(s,i));do try{zT();break}catch(R){pv(s,R)}while(!0);Bd(),wu.current=w,Ie=m,rt!==null?i=0:(ft=null,vt=0,i=lt)}if(i!==0){if(i===2&&(m=sd(s),m!==0&&(h=m,i=Th(s,m))),i===1)throw u=ya,Us(s,0),Zr(s,h),Bt(s,tt()),u;if(i===6)Zr(s,h);else{if(m=s.current.alternate,(h&30)===0&&!VT(m)&&(i=ku(s,h),i===2&&(w=sd(s),w!==0&&(h=w,i=Th(s,w))),i===1))throw u=ya,Us(s,0),Zr(s,h),Bt(s,tt()),u;switch(s.finishedWork=m,s.finishedLanes=h,i){case 0:case 1:throw Error(n(345));case 2:Vs(s,Vt,xr);break;case 3:if(Zr(s,h),(h&130023424)===h&&(i=Sh+500-tt(),10<i)){if(Il(s,0)!==0)break;if(m=s.suspendedLanes,(m&h)!==h){Ot(),s.pingedLanes|=s.suspendedLanes&m;break}s.timeoutHandle=jd(Vs.bind(null,s,Vt,xr),i);break}Vs(s,Vt,xr);break;case 4:if(Zr(s,h),(h&4194240)===h)break;for(i=s.eventTimes,m=-1;0<h;){var T=31-bn(h);w=1<<T,T=i[T],T>m&&(m=T),h&=~w}if(h=m,h=tt()-h,h=(120>h?120:480>h?480:1080>h?1080:1920>h?1920:3e3>h?3e3:4320>h?4320:1960*UT(h/1960))-h,10<h){s.timeoutHandle=jd(Vs.bind(null,s,Vt,xr),h);break}Vs(s,Vt,xr);break;case 5:Vs(s,Vt,xr);break;default:throw Error(n(329))}}}return Bt(s,tt()),s.callbackNode===u?hv.bind(null,s):null}function Th(s,i){var u=va;return s.current.memoizedState.isDehydrated&&(Us(s,i).flags|=256),s=ku(s,i),s!==2&&(i=Vt,Vt=u,i!==null&&kh(i)),s}function kh(s){Vt===null?Vt=s:Vt.push.apply(Vt,s)}function VT(s){for(var i=s;;){if(i.flags&16384){var u=i.updateQueue;if(u!==null&&(u=u.stores,u!==null))for(var h=0;h<u.length;h++){var m=u[h],w=m.getSnapshot;m=m.value;try{if(!Sn(w(),m))return!1}catch{return!1}}}if(u=i.child,i.subtreeFlags&16384&&u!==null)u.return=i,i=u;else{if(i===s)break;for(;i.sibling===null;){if(i.return===null||i.return===s)return!0;i=i.return}i.sibling.return=i.return,i=i.sibling}}return!0}function Zr(s,i){for(i&=~bh,i&=~xu,s.suspendedLanes|=i,s.pingedLanes&=~i,s=s.expirationTimes;0<i;){var u=31-bn(i),h=1<<u;s[u]=-1,i&=~h}}function fv(s){if((Ie&6)!==0)throw Error(n(327));qi();var i=Il(s,0);if((i&1)===0)return Bt(s,tt()),null;var u=ku(s,i);if(s.tag!==0&&u===2){var h=sd(s);h!==0&&(i=h,u=Th(s,h))}if(u===1)throw u=ya,Us(s,0),Zr(s,i),Bt(s,tt()),u;if(u===6)throw Error(n(345));return s.finishedWork=s.current.alternate,s.finishedLanes=i,Vs(s,Vt,xr),Bt(s,tt()),null}function Ch(s,i){var u=Ie;Ie|=1;try{return s(i)}finally{Ie=u,Ie===0&&(Hi=tt()+500,Zl&&qr())}}function Fs(s){Jr!==null&&Jr.tag===0&&(Ie&6)===0&&qi();var i=Ie;Ie|=1;var u=dn.transition,h=$e;try{if(dn.transition=null,$e=1,s)return s()}finally{$e=h,dn.transition=u,Ie=i,(Ie&6)===0&&qr()}}function Ph(){Zt=Wi.current,We(Wi)}function Us(s,i){s.finishedWork=null,s.finishedLanes=0;var u=s.timeoutHandle;if(u!==-1&&(s.timeoutHandle=-1,yT(u)),rt!==null)for(u=rt.return;u!==null;){var h=u;switch(Md(h),h.tag){case 1:h=h.type.childContextTypes,h!=null&&Jl();break;case 3:Vi(),We($t),We(Et),Yd();break;case 5:Gd(h);break;case 4:Vi();break;case 13:We(Ge);break;case 19:We(Ge);break;case 10:zd(h.type._context);break;case 22:case 23:Ph()}u=u.return}if(ft=s,rt=s=es(s.current,null),vt=Zt=i,lt=0,ya=null,bh=xu=$s=0,Vt=va=null,Ls!==null){for(i=0;i<Ls.length;i++)if(u=Ls[i],h=u.interleaved,h!==null){u.interleaved=null;var m=h.next,w=u.pending;if(w!==null){var T=w.next;w.next=m,h.next=T}u.pending=h}Ls=null}return s}function pv(s,i){do{var u=rt;try{if(Bd(),uu.current=fu,cu){for(var h=Qe.memoizedState;h!==null;){var m=h.queue;m!==null&&(m.pending=null),h=h.next}cu=!1}if(Ms=0,ht=at=Qe=null,da=!1,ha=0,xh.current=null,u===null||u.return===null){lt=1,ya=i,rt=null;break}e:{var w=s,T=u.return,R=u,j=i;if(i=vt,R.flags|=32768,j!==null&&typeof j=="object"&&typeof j.then=="function"){var F=j,Y=R,X=Y.tag;if((Y.mode&1)===0&&(X===0||X===11||X===15)){var Q=Y.alternate;Q?(Y.updateQueue=Q.updateQueue,Y.memoizedState=Q.memoizedState,Y.lanes=Q.lanes):(Y.updateQueue=null,Y.memoizedState=null)}var re=Fy(T);if(re!==null){re.flags&=-257,Uy(re,T,R,w,i),re.mode&1&&$y(w,F,i),i=re,j=F;var le=i.updateQueue;if(le===null){var he=new Set;he.add(j),i.updateQueue=he}else le.add(j);break e}else{if((i&1)===0){$y(w,F,i),Ah();break e}j=Error(n(426))}}else if(Ke&&R.mode&1){var nt=Fy(T);if(nt!==null){(nt.flags&65536)===0&&(nt.flags|=256),Uy(nt,T,R,w,i),Ud(Bi(j,R));break e}}w=j=Bi(j,R),lt!==4&&(lt=2),va===null?va=[w]:va.push(w),w=T;do{switch(w.tag){case 3:w.flags|=65536,i&=-i,w.lanes|=i;var M=Dy(w,j,i);uy(w,M);break e;case 1:R=j;var I=w.type,$=w.stateNode;if((w.flags&128)===0&&(typeof I.getDerivedStateFromError=="function"||$!==null&&typeof $.componentDidCatch=="function"&&(Yr===null||!Yr.has($)))){w.flags|=65536,i&=-i,w.lanes|=i;var ee=My(w,R,i);uy(w,ee);break e}}w=w.return}while(w!==null)}yv(u)}catch(pe){i=pe,rt===u&&u!==null&&(rt=u=u.return);continue}break}while(!0)}function mv(){var s=wu.current;return wu.current=fu,s===null?fu:s}function Ah(){(lt===0||lt===3||lt===2)&&(lt=4),ft===null||($s&268435455)===0&&(xu&268435455)===0||Zr(ft,vt)}function ku(s,i){var u=Ie;Ie|=2;var h=mv();(ft!==s||vt!==i)&&(xr=null,Us(s,i));do try{BT();break}catch(m){pv(s,m)}while(!0);if(Bd(),Ie=u,wu.current=h,rt!==null)throw Error(n(261));return ft=null,vt=0,lt}function BT(){for(;rt!==null;)gv(rt)}function zT(){for(;rt!==null&&!pE();)gv(rt)}function gv(s){var i=xv(s.alternate,s,Zt);s.memoizedProps=s.pendingProps,i===null?yv(s):rt=i,xh.current=null}function yv(s){var i=s;do{var u=i.alternate;if(s=i.return,(i.flags&32768)===0){if(u=LT(u,i,Zt),u!==null){rt=u;return}}else{if(u=DT(u,i),u!==null){u.flags&=32767,rt=u;return}if(s!==null)s.flags|=32768,s.subtreeFlags=0,s.deletions=null;else{lt=6,rt=null;return}}if(i=i.sibling,i!==null){rt=i;return}rt=i=s}while(i!==null);lt===0&&(lt=5)}function Vs(s,i,u){var h=$e,m=dn.transition;try{dn.transition=null,$e=1,WT(s,i,u,h)}finally{dn.transition=m,$e=h}return null}function WT(s,i,u,h){do qi();while(Jr!==null);if((Ie&6)!==0)throw Error(n(327));u=s.finishedWork;var m=s.finishedLanes;if(u===null)return null;if(s.finishedWork=null,s.finishedLanes=0,u===s.current)throw Error(n(177));s.callbackNode=null,s.callbackPriority=0;var w=u.lanes|u.childLanes;if(EE(s,w),s===ft&&(rt=ft=null,vt=0),(u.subtreeFlags&2064)===0&&(u.flags&2064)===0||Su||(Su=!0,bv(Rl,function(){return qi(),null})),w=(u.flags&15990)!==0,(u.subtreeFlags&15990)!==0||w){w=dn.transition,dn.transition=null;var T=$e;$e=1;var R=Ie;Ie|=4,xh.current=null,$T(s,u),av(u,s),cT(Ad),Ml=!!Pd,Ad=Pd=null,s.current=u,FT(u),mE(),Ie=R,$e=T,dn.transition=w}else s.current=u;if(Su&&(Su=!1,Jr=s,_u=m),w=s.pendingLanes,w===0&&(Yr=null),vE(u.stateNode),Bt(s,tt()),i!==null)for(h=s.onRecoverableError,u=0;u<i.length;u++)m=i[u],h(m.value,{componentStack:m.stack,digest:m.digest});if(bu)throw bu=!1,s=_h,_h=null,s;
vendor: 6,442 bytes, line 41
41return(_u&1)!==0&&s.tag!==0&&qi(),w=s.pendingLanes,(w&1)!==0?s===Eh?wa++:(wa=0,Eh=s):wa=0,qr(),null}function qi(){if(Jr!==null){var s=ig(_u),i=dn.transition,u=$e;try{if(dn.transition=null,$e=16>s?16:s,Jr===null)var h=!1;else{if(s=Jr,Jr=null,_u=0,(Ie&6)!==0)throw Error(n(331));var m=Ie;for(Ie|=4,ae=s.current;ae!==null;){var w=ae,T=w.child;if((ae.flags&16)!==0){var R=w.deletions;if(R!==null){for(var j=0;j<R.length;j++){var F=R[j];for(ae=F;ae!==null;){var Y=ae;switch(Y.tag){case 0:case 11:case 15:ga(8,Y,w)}var X=Y.child;if(X!==null)X.return=Y,ae=X;else for(;ae!==null;){Y=ae;var Q=Y.sibling,re=Y.return;if(nv(Y),Y===F){ae=null;break}if(Q!==null){Q.return=re,ae=Q;break}ae=re}}}var le=w.alternate;if(le!==null){var he=le.child;if(he!==null){le.child=null;do{var nt=he.sibling;he.sibling=null,he=nt}while(he!==null)}}ae=w}}if((w.subtreeFlags&2064)!==0&&T!==null)T.return=w,ae=T;else e:for(;ae!==null;){if(w=ae,(w.flags&2048)!==0)switch(w.tag){case 0:case 11:case 15:ga(9,w,w.return)}var M=w.sibling;if(M!==null){M.return=w.return,ae=M;break e}ae=w.return}}var I=s.current;for(ae=I;ae!==null;){T=ae;var $=T.child;if((T.subtreeFlags&2064)!==0&&$!==null)$.return=T,ae=$;else e:for(T=I;ae!==null;){if(R=ae,(R.flags&2048)!==0)try{switch(R.tag){case 0:case 11:case 15:vu(9,R)}}catch(pe){Ye(R,R.return,pe)}if(R===T){ae=null;break e}var ee=R.sibling;if(ee!==null){ee.return=R.return,ae=ee;break e}ae=R.return}}if(Ie=m,qr(),Yn&&typeof Yn.onPostCommitFiberRoot=="function")try{Yn.onPostCommitFiberRoot(jl,s)}catch{}h=!0}return h}finally{$e=u,dn.transition=i}}return!1}function vv(s,i,u){i=Bi(u,i),i=Dy(s,i,1),s=Gr(s,i,1),i=Ot(),s!==null&&(zo(s,1,i),Bt(s,i))}function Ye(s,i,u){if(s.tag===3)vv(s,s,u);else for(;i!==null;){if(i.tag===3){vv(i,s,u);break}else if(i.tag===1){var h=i.stateNode;if(typeof i.type.getDerivedStateFromError=="function"||typeof h.componentDidCatch=="function"&&(Yr===null||!Yr.has(h))){s=Bi(u,s),s=My(i,s,1),i=Gr(i,s,1),s=Ot(),i!==null&&(zo(i,1,s),Bt(i,s));break}}i=i.return}}function HT(s,i,u){var h=s.pingCache;h!==null&&h.delete(i),i=Ot(),s.pingedLanes|=s.suspendedLanes&u,ft===s&&(vt&u)===u&&(lt===4||lt===3&&(vt&130023424)===vt&&500>tt()-Sh?Us(s,0):bh|=u),Bt(s,i)}function wv(s,i){i===0&&((s.mode&1)===0?i=1:(i=Nl,Nl<<=1,(Nl&130023424)===0&&(Nl=4194304)));var u=Ot();s=yr(s,i),s!==null&&(zo(s,i,u),Bt(s,u))}function qT(s){var i=s.memoizedState,u=0;i!==null&&(u=i.retryLane),wv(s,u)}function KT(s,i){var u=0;switch(s.tag){case 13:var h=s.stateNode,m=s.memoizedState;m!==null&&(u=m.retryLane);break;case 19:h=s.stateNode;break;default:throw Error(n(314))}h!==null&&h.delete(i),wv(s,u)}var xv;xv=function(s,i,u){if(s!==null)if(s.memoizedProps!==i.pendingProps||$t.current)Ut=!0;else{if((s.lanes&u)===0&&(i.flags&128)===0)return Ut=!1,IT(s,i,u);Ut=(s.flags&131072)!==0}else Ut=!1,Ke&&(i.flags&1048576)!==0&&Zg(i,tu,i.index);switch(i.lanes=0,i.tag){case 2:var h=i.type;gu(s,i),s=i.pendingProps;var m=Ii(i,Et.current);Ui(i,u),m=Zd(null,i,h,s,m,u);var w=eh();return i.flags|=1,typeof m=="object"&&m!==null&&typeof m.render=="function"&&m.$$typeof===void 0?(i.tag=1,i.memoizedState=null,i.updateQueue=null,Ft(h)?(w=!0,Xl(i)):w=!1,i.memoizedState=m.state!==null&&m.state!==void 0?m.state:null,qd(i),m.updater=pu,i.stateNode=m,m._reactInternals=i,oh(i,h,s,u),i=ch(null,i,h,!0,w,u)):(i.tag=0,Ke&&w&&Dd(i),jt(null,i,m,u),i=i.child),i;case 16:h=i.elementType;e:{switch(gu(s,i),s=i.pendingProps,m=h._init,h=m(h._payload),i.type=h,m=i.tag=QT(h),s=En(h,s),m){case 0:i=uh(null,i,h,s,u);break e;case 1:i=qy(null,i,h,s,u);break e;case 11:i=Vy(null,i,h,s,u);break e;case 14:i=By(null,i,h,En(h.type,s),u);break e}throw Error(n(306,h,""))}return i;case 0:return h=i.type,m=i.pendingProps,m=i.elementType===h?m:En(h,m),uh(s,i,h,m,u);case 1:return h=i.type,m=i.pendingProps,m=i.elementType===h?m:En(h,m),qy(s,i,h,m,u);case 3:e:{if(Ky(i),s===null)throw Error(n(387));h=i.pendingProps,w=i.memoizedState,m=w.element,ly(s,i),au(i,h,null,u);var T=i.memoizedState;if(h=T.element,w.isDehydrated)if(w={element:h,isDehydrated:!1,cache:T.cache,pendingSuspenseBoundaries:T.pendingSuspenseBoundaries,transitions:T.transitions},i.updateQueue.baseState=w,i.memoizedState=w,i.flags&256){m=Bi(Error(n(423)),i),i=Gy(s,i,h,u,m);break e}else if(h!==m){m=Bi(Error(n(424)),i),i=Gy(s,i,h,u,m);break e}else for(Xt=zr(i.stateNode.containerInfo.firstChild),Jt=i,Ke=!0,_n=null,u=oy(i,null,h,u),i.child=u;u;)u.flags=u.flags&-3|4096,u=u.sibling;else{if(Mi(),h===m){i=wr(s,i,u);break e}jt(s,i,h,u)}i=i.child}return i;case 5:return dy(i),s===null&&Fd(i),h=i.type,m=i.pendingProps,w=s!==null?s.memoizedProps:null,T=m.children,Rd(h,m)?T=null:w!==null&&Rd(h,w)&&(i.flags|=32),Hy(s,i),jt(s,i,T,u),i.child;case 6:return s===null&&Fd(i),null;case 13:return Qy(s,i,u);case 4:return Kd(i,i.stateNode.containerInfo),h=i.pendingProps,s===null?i.child=$i(i,null,h,u):jt(s,i,h,u),i.child;case 11:return h=i.type,m=i.pendingProps,m=i.elementType===h?m:En(h,m),Vy(s,i,h,m,u);case 7:return jt(s,i,i.pendingProps,u),i.child;case 8:return jt(s,i,i.pendingProps.children,u),i.child;case 12:return jt(s,i,i.pendingProps.children,u),i.child;case 10:e:{if(h=i.type._context,m=i.pendingProps,w=i.memoizedProps,T=m.value,Ve(su,h._currentValue),h._currentValue=T,w!==null)if(Sn(w.value,T)){if(w.children===m.children&&!$t.current){i=wr(s,i,u);break e}}else for(w=i.child,w!==null&&(w.return=i);w!==null;){var R=w.dependencies;if(R!==null){T=w.child;for(var j=R.firstContext;j!==null;){if(j.context===h){if(w.tag===1){j=vr(-1,u&-u),j.tag=2;var F=w.updateQueue;if(F!==null){F=F.shared;var Y=F.pending;Y===null?j.next=j:(j.next=Y.next,Y.next=j),F.pending=j}}w.lanes|=u,j=w.alternate,j!==null&&(j.lanes|=u),Wd(w.return,u,i),R.lanes|=u;break}j=j.next}}else if(w.tag===10)T=w.type===i.type?null:w.child;else if(w.tag===18){if(T=w.return,T===null)throw Error(n(341));T.lanes|=u,R=T.alternate,R!==null&&(R.lanes|=u),Wd(T,u,i),T=w.sibling}else T=w.child;if(T!==null)T.return=w;else for(T=w;T!==null;){if(T===i){T=null;break}if(w=T.sibling,w!==null){w.return=T.return,T=w;break}T=T.return}w=T}jt(s,i,m.children,u),i=i.child}return i;case 9:return m=i.type,h=i.pendingProps.children,Ui(i,u),m=un(m),h=h(m),i.flags|=1,jt(s,i,h,u),i.child;case 14:return h=i.type,m=En(h,i.pendingProps),m=En(h.type,m),By(s,i,h,m,u);case 15:return zy(s,i,i.type,i.pendingProps,u);case 17:return h=i.type,m=i.pendingProps,m=i.elementType===h?m:En(h,m),gu(s,i),i.tag=1,Ft(h)?(s=!0,Xl(i)):s=!1,Ui(i,u),Iy(i,h,m),oh(i,h,m,u),ch(null,i,h,
vendor: 7,550 bytes, line 41
41!0,s,u);case 19:return Jy(s,i,u);case 22:return Wy(s,i,u)}throw Error(n(156,i.tag))};function bv(s,i){return eg(s,i)}function GT(s,i,u,h){this.tag=s,this.key=u,this.sibling=this.child=this.return=this.stateNode=this.type=this.elementType=null,this.index=0,this.ref=null,this.pendingProps=i,this.dependencies=this.memoizedState=this.updateQueue=this.memoizedProps=null,this.mode=h,this.subtreeFlags=this.flags=0,this.deletions=null,this.childLanes=this.lanes=0,this.alternate=null}function hn(s,i,u,h){return new GT(s,i,u,h)}function Rh(s){return s=s.prototype,!(!s||!s.isReactComponent)}function QT(s){if(typeof s=="function")return Rh(s)?1:0;if(s!=null){if(s=s.$$typeof,s===Z)return 11;if(s===fe)return 14}return 2}function es(s,i){var u=s.alternate;return u===null?(u=hn(s.tag,i,s.key,s.mode),u.elementType=s.elementType,u.type=s.type,u.stateNode=s.stateNode,u.alternate=s,s.alternate=u):(u.pendingProps=i,u.type=s.type,u.flags=0,u.subtreeFlags=0,u.deletions=null),u.flags=s.flags&14680064,u.childLanes=s.childLanes,u.lanes=s.lanes,u.child=s.child,u.memoizedProps=s.memoizedProps,u.memoizedState=s.memoizedState,u.updateQueue=s.updateQueue,i=s.dependencies,u.dependencies=i===null?null:{lanes:i.lanes,firstContext:i.firstContext},u.sibling=s.sibling,u.index=s.index,u.ref=s.ref,u}function Cu(s,i,u,h,m,w){var T=2;if(h=s,typeof s=="function")Rh(s)&&(T=1);else if(typeof s=="string")T=5;else e:switch(s){case V:return Bs(u.children,m,w,i);case z:T=8,m|=8;break;case q:return s=hn(12,u,i,m|2),s.elementType=q,s.lanes=w,s;case me:return s=hn(13,u,i,m),s.elementType=me,s.lanes=w,s;case J:return s=hn(19,u,i,m),s.elementType=J,s.lanes=w,s;case de:return Pu(u,m,w,i);default:if(typeof s=="object"&&s!==null)switch(s.$$typeof){case H:T=10;break e;case te:T=9;break e;case Z:T=11;break e;case fe:T=14;break e;case ie:T=16,h=null;break e}throw Error(n(130,s==null?s:typeof s,""))}return i=hn(T,u,i,m),i.elementType=s,i.type=h,i.lanes=w,i}function Bs(s,i,u,h){return s=hn(7,s,h,i),s.lanes=u,s}function Pu(s,i,u,h){return s=hn(22,s,h,i),s.elementType=de,s.lanes=u,s.stateNode={isHidden:!1},s}function jh(s,i,u){return s=hn(6,s,null,i),s.lanes=u,s}function Oh(s,i,u){return i=hn(4,s.children!==null?s.children:[],s.key,i),i.lanes=u,i.stateNode={containerInfo:s.containerInfo,pendingChildren:null,implementation:s.implementation},i}function YT(s,i,u,h,m){this.tag=i,this.containerInfo=s,this.finishedWork=this.pingCache=this.current=this.pendingChildren=null,this.timeoutHandle=-1,this.callbackNode=this.pendingContext=this.context=null,this.callbackPriority=0,this.eventTimes=id(0),this.expirationTimes=id(-1),this.entangledLanes=this.finishedLanes=this.mutableReadLanes=this.expiredLanes=this.pingedLanes=this.suspendedLanes=this.pendingLanes=0,this.entanglements=id(0),this.identifierPrefix=h,this.onRecoverableError=m,this.mutableSourceEagerHydrationData=null}function Nh(s,i,u,h,m,w,T,R,j){return s=new YT(s,i,u,R,j),i===1?(i=1,w===!0&&(i|=8)):i=0,w=hn(3,null,null,i),s.current=w,w.stateNode=s,w.memoizedState={element:h,isDehydrated:u,cache:null,transitions:null,pendingSuspenseBoundaries:null},qd(w),s}function JT(s,i,u){var h=3<arguments.length&&arguments[3]!==void 0?arguments[3]:null;return{$$typeof:D,key:h==null?null:""+h,children:s,containerInfo:i,implementation:u}}function Sv(s){if(!s)return Hr;s=s._reactInternals;e:{if(Rs(s)!==s||s.tag!==1)throw Error(n(170));var i=s;do{switch(i.tag){case 3:i=i.stateNode.context;break e;case 1:if(Ft(i.type)){i=i.stateNode.__reactInternalMemoizedMergedChildContext;break e}}i=i.return}while(i!==null);throw Error(n(171))}if(s.tag===1){var u=s.type;if(Ft(u))return Yg(s,u,i)}return i}function _v(s,i,u,h,m,w,T,R,j){return s=Nh(u,h,!0,s,m,w,T,R,j),s.context=Sv(null),u=s.current,h=Ot(),m=Xr(u),w=vr(h,m),w.callback=i??null,Gr(u,w,m),s.current.lanes=m,zo(s,m,h),Bt(s,h),s}function Au(s,i,u,h){var m=i.current,w=Ot(),T=Xr(m);return u=Sv(u),i.context===null?i.context=u:i.pendingContext=u,i=vr(w,T),i.payload={element:s},h=h===void 0?null:h,h!==null&&(i.callback=h),s=Gr(m,i,T),s!==null&&(Cn(s,m,T,w),ou(s,m,T)),T}function Ru(s){if(s=s.current,!s.child)return null;switch(s.child.tag){case 5:return s.child.stateNode;default:return s.child.stateNode}}function Ev(s,i){if(s=s.memoizedState,s!==null&&s.dehydrated!==null){var u=s.retryLane;s.retryLane=u!==0&&u<i?u:i}}function Ih(s,i){Ev(s,i),(s=s.alternate)&&Ev(s,i)}function XT(){return null}var Tv=typeof reportError=="function"?reportError:function(s){console.error(s)};function Lh(s){this._internalRoot=s}ju.prototype.render=Lh.prototype.render=function(s){var i=this._internalRoot;if(i===null)throw Error(n(409));Au(s,i,null,null)},ju.prototype.unmount=Lh.prototype.unmount=function(){var s=this._internalRoot;if(s!==null){this._internalRoot=null;var i=s.containerInfo;Fs(function(){Au(null,s,null,null)}),i[fr]=null}};function ju(s){this._internalRoot=s}ju.prototype.unstable_scheduleHydration=function(s){if(s){var i=lg();s={blockedOn:null,target:s,priority:i};for(var u=0;u<Ur.length&&i!==0&&i<Ur[u].priority;u++);Ur.splice(u,0,s),u===0&&dg(s)}};function Dh(s){return!(!s||s.nodeType!==1&&s.nodeType!==9&&s.nodeType!==11)}function Ou(s){return!(!s||s.nodeType!==1&&s.nodeType!==9&&s.nodeType!==11&&(s.nodeType!==8||s.nodeValue!==" react-mount-point-unstable "))}function kv(){}function ZT(s,i,u,h,m){if(m){if(typeof h=="function"){var w=h;h=function(){var F=Ru(T);w.call(F)}}var T=_v(i,h,s,0,null,!1,!1,"",kv);return s._reactRootContainer=T,s[fr]=T.current,ra(s.nodeType===8?s.parentNode:s),Fs(),T}for(;m=s.lastChild;)s.removeChild(m);if(typeof h=="function"){var R=h;h=function(){var F=Ru(j);R.call(F)}}var j=Nh(s,0,!1,null,null,!1,!1,"",kv);return s._reactRootContainer=j,s[fr]=j.current,ra(s.nodeType===8?s.parentNode:s),Fs(function(){Au(i,j,u,h)}),j}function Nu(s,i,u,h,m){var w=u._reactRootContainer;if(w){var T=w;if(typeof m=="function"){var R=m;m=function(){var j=Ru(T);R.call(j)}}Au(i,T,s,m)}else T=ZT(u,i,s,m,h);return Ru(T)}og=function(s){switch(s.tag){case 3:var i=s.stateNode;if(i.current.memoizedState.isDehydrated){var u=Bo(i.pendingLanes);u!==0&&(od(i,u|1),Bt(i,tt()),(Ie&6)===0&&(Hi=tt()+500,qr()))}break;case 13:Fs(function(){var h=yr(s,1);if(h!==null){var m=Ot();Cn(h,s,1,m)}}),Ih(s,1)}},ad=function(s){if(s.tag===13){var i=yr(s,134217728);if(i!==null){var u=Ot();Cn(i,s,134217728,u)}Ih(s,134217728)}},ag=function(s){if(s.tag===13){var i=Xr(s),u=yr(s,i);if(u!==null){var h=Ot();Cn(u,s,i,h)}Ih(s,i)}},lg=function(){return $e},ug=function(s,i){var u=$e;try{return $e=s,i()}finally{$e=u}},Ei=function(s,i,u){switch(i){case"input":if(Ps(s,u),i=u.name,u.type==="radio"&&i!=null){for(u=s;u.parentNode;)u=u.parentNode;for(u=u.querySelectorAll("input[name="+JSON.stringify(""+i)+'][type="radio"]'),i=0;i<u.length;i++){var h=u[i];if(h!==s&&h.form===s.form){var m=Yl(h);if(!m)throw Error(n(90));dr(h),Ps(h,m)}}}break;case"textarea":Sl(s,u);break;case"select":i=u.value,i!=null&&on(s,!!u.multiple,i,!1)}},De=Ch,Fe=Fs;var ek={usingClientEntryPoint:!1,Events:[oa,Oi,Yl,Cl,Te,Ch]},xa={findFiberByHostInstance:js,bundleType:0,version:"18.3.1",rendererPackageName:"react-dom"},tk={bundleType:xa.bundleType,version:xa.version,rendererPackageName:xa.rendererPackageName,rendererConfig:xa.rendererConfig,overrideHookState:null,overrideHookStateDeletePath:null,overrideHookStateRenamePath:null,overrideProps:null,overridePropsDeletePath:null,overridePropsRenamePath:null,setErrorHandler:null,setSuspenseHandler:null,scheduleUpdate:null,currentDispatcherRef:A.ReactCurrentDispatcher,findHostInstanceByFiber:function(s){return s=Xm(s),s===null?null:s.stateNode}
41,findFiberByHostInstance:xa.findFiberByHostInstance||XT,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 Iu=__REACT_DEVTOOLS_GLOBAL_HOOK__;if(!Iu.isDisabled&&Iu.supportsFiber)try{jl=Iu.inject(tk),Yn=Iu}catch{}}return zt.__SECRET_INTERNALS_DO_NOT_USE_OR_YOU_WILL_BE_FIRED=ek,zt.createPortal=function(s,i){var u=2<arguments.length&&arguments[2]!==void 0?arguments[2]:null;if(!Dh(i))throw Error(n(200));return JT(s,i,null,u)},zt.createRoot=function(s,i){if(!Dh(s))throw Error(n(299));var u=!1,h="",m=Tv;return i!=null&&(i.unstable_strictMode===!0&&(u=!0),i.identifierPrefix!==void 0&&(h=i.identifierPrefix),i.onRecoverableError!==void 0&&(m=i.onRecoverableError)),i=Nh(s,1,!1,null,null,u,!1,h,m),s[fr]=i.current,ra(s.nodeType===8?s.parentNode:s),new Lh(i)},zt.findDOMNode=function(s){if(s==null)return null;if(s.nodeType===1)return s;var i=s._reactInternals;if(i===void 0)throw typeof s.render=="function"?Error(n(188)):(s=Object.keys(s).join(","),Error(n(268,s)));return s=Xm(i),s=s===null?null:s.stateNode,s},zt.flushSync=function(s){return Fs(s)},zt.hydrate=function(s,i,u){if(!Ou(i))throw Error(n(200));return Nu(null,s,i,!0,u)},zt.hydrateRoot=function(s,i,u){if(!Dh(s))throw Error(n(405));var h=u!=null&&u.hydratedSources||null,m=!1,w="",T=Tv;if(u!=null&&(u.unstable_strictMode===!0&&(m=!0),u.identifierPrefix!==void 0&&(w=u.identifierPrefix),u.onRecoverableError!==void 0&&(T=u.onRecoverableError)),i=_v(i,null,s,1,u??null,m,!1,w,T),s[fr]=i.current,ra(s),h)for(s=0;s<h.length;s++)u=h[s],m=u._getVersion,m=m(u._source),i.mutableSourceEagerHydrationData==null?i.mutableSourceEagerHydrationData=[u,m]:i.mutableSourceEagerHydrationData.push(u,m);return new ju(i)},zt.render=function(s,i,u){if(!Ou(i))throw Error(n(200));return Nu(null,s,i,!1,u)},zt.unmountComponentAtNode=function(s){if(!Ou(s))throw Error(n(40));return s._reactRootContainer?(Fs(function(){Nu(null,null,s,!1,function(){s._reactRootContainer=null,s[fr]=null})}),!0):!1},zt.unstable_batchedUpdates=Ch,zt.unstable_renderSubtreeIntoContainer=function(s,i,u,h){if(!Ou(u))throw Error(n(200));if(s==null||s._reactInternals===void 0)throw Error(n(38));return Nu(s,i,u,!1,h)},zt.version="18.3.1-next-f1338f8080-20240426",zt}var Lv;function rb(){if(Lv)return Uh.exports;Lv=1;function t(){if(!(typeof __REACT_DEVTOOLS_GLOBAL_HOOK__>"u"||typeof __REACT_DEVTOOLS_GLOBAL_HOOK__.checkDCE!="function"))try{__REACT_DEVTOOLS_GLOBAL_HOOK__.checkDCE(t)}catch(e){console.error(e)}}return t(),Uh.exports=dk(),Uh.exports}var Dv;function hk(){if(Dv)return Du;Dv=1;var t=rb();return Du.createRoot=t.createRoot,Du.hydrateRoot=t.hydrateRoot,Du}var fk=hk(),E=qp();const K=ul(E),jc=ik({__proto__:null,default:K},[E]);var zh,Mv;function pk(){if(Mv)return zh;Mv=1;var t=typeof Element<"u",e=typeof Map=="function",n=typeof Set=="function",r=typeof ArrayBuffer=="function"&&!!ArrayBuffer.isView;function o(a,l){if(a===l)return!0;if(a&&l&&typeof a=="object"&&typeof l=="object"){if(a.constructor!==l.constructor)return!1;var c,d,f;if(Array.isArray(a)){if(c=a.length,c!=l.length)return!1;for(d=c;d--!==0;)if(!o(a[d],l[d]))return!1;return!0}var p;if(e&&a instanceof Map&&l instanceof Map){if(a.size!==l.size)return!1;for(p=a.entries();!(d=p.next()).done;)if(!l.has(d.value[0]))return!1;for(p=a.entries();!(d=p.next()).done;)if(!o(d.value[1],l.get(d.value[0])))return!1;return!0}if(n&&a instanceof Set&&l instanceof Set){if(a.size!==l.size)return!1;for(p=a.entries();!(d=p.next()).done;)if(!l.has(d.value[0]))return!1;return!0}if(r&&ArrayBuffer.isView(a)&&ArrayBuffer.isView(l)){if(c=a.length,c!=l.length)return!1;for(d=c;d--!==0;)if(a[d]!==l[d])return!1;return!0}if(a.constructor===RegExp)return a.source===l.source&&a.flags===l.flags;if(a.valueOf!==Object.prototype.valueOf&&typeof a.valueOf=="function"&&typeof l.valueOf=="function")return a.valueOf()===l.valueOf();if(a.toString!==Object.prototype.toString&&typeof a.toString=="function"&&typeof l.toString=="function")return a.toString()===l.toString();if(f=Object.keys(a),c=f.length,c!==Object.keys(l).length)return!1;for(d=c;d--!==0;)if(!Object.prototype.hasOwnProperty.call(l,f[d]))return!1;if(t&&a instanceof Element)return!1;for(d=c;d--!==0;)if(!((f[d]==="_owner"||f[d]==="__v"||f[d]==="__o")&&a.$$typeof)&&!o(a[f[d]],l[f[d]]))return!1;return!0}return a!==a&&l!==l}return zh=function(l,c){try{return o(l,c)}catch(d){if((d.message||"").match(/stack|recursion/i))return console.warn("react-fast-compare cannot handle circular refs"),!1;throw d}},zh}var mk=pk();const gk=ul(mk);var Wh,$v;function yk(){if($v)return Wh;$v=1;var t=function(e,n,r,o,a,l,c,d){if(!e){var f;if(n===void 0)f=new Error("Minified exception occurred; use the non-minified dev environment for the full error message and additional helpful warnings.");else{var p=[r,o,a,l,c,d],g=0;f=new Error(n.replace(/%s/g,function(){return p[g++]}
41)),f.name="Invariant Violation"}throw f.framesToPop=1,f}};return Wh=t,Wh}var vk=yk();const Fv=ul(vk);var Hh,Uv;function wk(){return Uv||(Uv=1,Hh=function(e,n,r,o){var a=r?r.call(o,e,n):void 0;if(a!==void 0)return!!a;if(e===n)return!0;if(typeof e!="object"||!e||typeof n!="object"||!n)return!1;var l=Object.keys(e),c=Object.keys(n);if(l.length!==c.length)return!1;for(var d=Object.prototype.hasOwnProperty.bind(n),f=0;f<l.length;f++){var p=l[f];if(!d(p))return!1;var g=e[p],x=n[p];if(a=r?r.call(o,g,x,p):void 0,a===!1||a===void 0&&g!==x)return!1}return!0}),Hh}var xk=wk();const bk=ul(xk);var sb=(t=>(t.BASE="base",t.BODY="body",t.HEAD="head",t.HTML="html",t.LINK="link",t.META="meta",t.NOSCRIPT="noscript",t.SCRIPT="script",t.STYLE="style",t.TITLE="title",t.FRAGMENT="Symbol(react.fragment)",t))(sb||{}),qh={link:{rel:["amphtml","canonical","alternate"]},script:{type:["application/ld+json"]},meta:{charset:"",name:["generator","robots","description"],property:["og:type","og:title","og:url","og:image","og:image:alt","og:description","twitter:url","twitter:title","twitter:description","twitter:image","twitter:image:alt","twitter:card","twitter:site"]}},Vv=Object.values(sb),Oc={accesskey:"accessKey",charset:"charSet",class:"className",contenteditable:"contentEditable",contextmenu:"contextMenu","http-equiv":"httpEquiv",itemprop:"itemProp",tabindex:"tabIndex"},ib=Object.entries(Oc).reduce((t,[e,n])=>(t[n]=e,t),{}),Mn="data-rh",lo={DEFAULT_TITLE:"defaultTitle",DEFER:"defer",ENCODE_SPECIAL_CHARACTERS:"encodeSpecialCharacters",ON_CHANGE_CLIENT_STATE:"onChangeClientState",TITLE_TEMPLATE:"titleTemplate",PRIORITIZE_SEO_TAGS:"prioritizeSeoTags"},uo=(t,e)=>{for(let n=t.length-1;n>=0;n-=1){const r=t[n];if(Object.prototype.hasOwnProperty.call(r,e))return r[e]}return null},Sk=t=>{let e=uo(t,"title");const n=uo(t,lo.TITLE_TEMPLATE);if(Array.isArray(e)&&(e=e.join("")),n&&e)return n.replace(/%s/g,()=>e);const r=uo(t,lo.DEFAULT_TITLE);return e||r||void 0},_k=t=>uo(t,lo.ON_CHANGE_CLIENT_STATE)||(()=>{}),Kh=(t,e)=>e.filter(n=>typeof n[t]<"u").map(n=>n[t]).reduce((n,r)=>({...n,...r}),{}),Ek=(t,e)=>e.filter(n=>typeof n.base<"u").map(n=>n.base).reverse().reduce((n,r)=>{if(!n.length){const o=Object.keys(r);for(let a=0;a<o.length;a+=1){const c=o[a].toLowerCase();if(t.indexOf(c)!==-1&&r[c])return n.concat(r)}}return n},[]),Tk=t=>console&&typeof console.warn=="function"&&console.warn(t),Sa=(t,e,n)=>{const r={};return n.filter(o=>Array.isArray(o[t])?!0:(typeof o[t]<"u"&&Tk(`Helmet: ${t} should be of type "Array". Instead found type "${typeof o[t]}"`),!1)).map(o=>o[t]).reverse().reduce((o,a)=>{const l={};a.filter(d=>{let f;const p=Object.keys(d);for(let x=0;x<p.length;x+=1){const y=p[x],_=y.toLowerCase();e.indexOf(_)!==-1&&!(f==="rel"&&d[f].toLowerCase()==="canonical")&&!(_==="rel"&&d[_].toLowerCase()==="stylesheet")&&(f=_),e.indexOf(y)!==-1&&(y==="innerHTML"||y==="cssText"||y==="itemprop")&&(f=y)}if(!f||!d[f])return!1;const g=d[f].toLowerCase();return r[f]||(r[f]={}),l[f]||(l[f]={}),r[f][g]?!1:(l[f][g]=!0,!0)}).reverse().forEach(d=>o.push(d));const c=Object.keys(l);for(let d=0;d<c.length;d+=1){const f=c[d],p={...r[f],...l[f]};r[f]=p}return o},[]).reverse()},kk=(t,e)=>{if(Array.isArray(t)&&t.length){for(let n=0;n<t.length;n+=1)if(t[n][e])return!0}return!1},Ck=t=>({baseTag:Ek(["href"],t),bodyAttributes:Kh("bodyAttributes",t),defer:uo(t,lo.DEFER),encode:uo(t,lo.ENCODE_SPECIAL_CHARACTERS),htmlAttributes:Kh("htmlAttributes",t),linkTags:Sa("link",["rel","href"],t),metaTags:Sa("meta",["name","charset","http-equiv","property","itemprop"],t),noscriptTags:Sa("noscript",["innerHTML"],t),onChangeClientState:_k(t),scriptTags:Sa("script",["src","innerHTML"],t),styleTags:Sa("style",["cssText"],t),title:Sk(t),titleAttributes:Kh("titleAttributes",t),prioritizeSeoTags:kk(t,lo.PRIORITIZE_SEO_TAGS)}),ob=t=>Array.isArray(t)?t.join(""):t,Pk=(t,e)=>{const n=Object.keys(t);for(let r=0;r<n.length;r+=1)if(e[n[r]]&&e[n[r]].includes(t[n[r]]))return!0;return!1},Gh=(t,e)=>Array.isArray(t)?t.reduce((n,r)=>(Pk(r,e)?n.priority.push(r):n.default.push(r),n),{priority:[],default:[]}):{default:t,priority:[]},Bv=(t,e)=>({...t,[e]:void 0}),Ak=["noscript","script","style"],Rf=(t,e=!0)=>e===!1?String(t):String(t).replace(/&/g,"&amp;").replace(/</g,"&lt;").replace(/>/g,"&gt;").replace(/"/g,"&quot;").replace(/'/g,"&#x27;"),ab=t=>Object.keys(t).reduce((e,n)=>{const r=typeof t[n]<"u"?`${n}
41="${t[n]}"`:`${n}`;return e?`${e} ${r}`:r},""),Rk=(t,e,n,r)=>{const o=ab(n),a=ob(e);return o?`<${t} ${Mn}="true" ${o}>${Rf(a,r)}</${t}>`:`<${t} ${Mn}="true">${Rf(a,r)}</${t}>`},jk=(t,e,n=!0)=>e.reduce((r,o)=>{const a=o,l=Object.keys(a).filter(f=>!(f==="innerHTML"||f==="cssText")).reduce((f,p)=>{const g=typeof a[p]>"u"?p:`${p}="${Rf(a[p],n)}"`;return f?`${f} ${g}`:g},""),c=a.innerHTML||a.cssText||"",d=Ak.indexOf(t)===-1;return`${r}<${t} ${Mn}="true" ${l}${d?"/>":`>${c}</${t}>`}`},""),lb=(t,e={})=>Object.keys(t).reduce((n,r)=>{const o=Oc[r];return n[o||r]=t[r],n},e),Ok=(t,e,n)=>{const r={key:e,[Mn]:!0},o=lb(n,r);return[K.createElement("title",o,e)]},ec=(t,e)=>e.map((n,r)=>{const o={key:r,[Mn]:!0};return Object.keys(n).forEach(a=>{const c=Oc[a]||a;if(c==="innerHTML"||c==="cssText"){const d=n.innerHTML||n.cssText;o.dangerouslySetInnerHTML={__html:d}}else o[c]=n[a]}),K.createElement(t,o)}),pn=(t,e,n=!0)=>{switch(t){case"title":return{toComponent:()=>Ok(t,e.title,e.titleAttributes),toString:()=>Rk(t,e.title,e.titleAttributes,n)};case"bodyAttributes":case"htmlAttributes":return{toComponent:()=>lb(e),toString:()=>ab(e)};default:return{toComponent:()=>ec(t,e),toString:()=>jk(t,e,n)}}},Nk=({metaTags:t,linkTags:e,scriptTags:n,encode:r})=>{const o=Gh(t,qh.meta),a=Gh(e,qh.link),l=Gh(n,qh.script);return{priorityMethods:{toComponent:()=>[...ec("meta",o.priority),...ec("link",a.priority),...ec("script",l.priority)],toString:()=>`${pn("meta",o.priority,r)} ${pn("link",a.priority,r)} ${pn("script",l.priority,r)}`},metaTags:o.default,linkTags:a.default,scriptTags:l.default}},Ik=t=>{const{baseTag:e,bodyAttributes:n,encode:r=!0,htmlAttributes:o,noscriptTags:a,styleTags:l,title:c="",titleAttributes:d,prioritizeSeoTags:f}=t;let{linkTags:p,metaTags:g,scriptTags:x}=t,y={toComponent:()=>[],toString:()=>""};return f&&({priorityMethods:y,linkTags:p,metaTags:g,scriptTags:x}=Nk(t)),{priority:y,base:pn("base",e,r),bodyAttributes:pn("bodyAttributes",n,r),htmlAttributes:pn("htmlAttributes",o,r),link:pn("link",p,r),meta:pn("meta",g,r),noscript:pn("noscript",a,r),script:pn("script",x,r),style:pn("style",l,r),title:pn("title",{title:c,titleAttributes:d},r)}},jf=Ik,Mu=[],Kp=!!(typeof window<"u"&&window.document&&window.document.createElement),Of=class{constructor(t,e){br(this,"instances",[]);br(this,"canUseDOM",Kp);br(this,"context");br(this,"value",{setHelmet:t=>{this.context.helmet=t},helmetInstances:{get:()=>this.canUseDOM?Mu:this.instances,add:t=>{(this.canUseDOM?Mu:this.instances).push(t)},remove:t=>{const e=(this.canUseDOM?Mu:this.instances).indexOf(t);(this.canUseDOM?Mu:this.instances).splice(e,1)}}});this.context=t,this.canUseDOM=e||!1,e||(t.helmet=jf({baseTag:[],bodyAttributes:{},htmlAttributes:{},linkTags:[],metaTags:[],noscriptTags:[],scriptTags:[],styleTags:[],title:"",titleAttributes:{}}))}},Lk=parseInt(K.version.split(".")[0],10),Nf=Lk>=19,Dk={},ub=K.createContext(Dk),ri,cb=(ri=class extends E.Component{constructor(n){super(n);br(this,"helmetData");Nf?this.helmetData=null:this.helmetData=new Of(this.props.context||{},ri.canUseDOM)}render(){return Nf?K.createElement(K.Fragment,null,this.props.children):K.createElement(ub.Provider,{value:this.helmetData.value},this.props.children)}},br(ri,"canUseDOM",Kp),ri),Ki=(t,e)=>{const n=document.head||document.querySelector("head"),r=n.querySelectorAll(`${t}[${Mn}]`),o=[].slice.call(r),a=[];let l;return e&&e.length&&e.forEach(c=>{const d=document.createElement(t);for(const f in c)if(Object.prototype.hasOwnProperty.call(c,f))if(f==="innerHTML")d.innerHTML=c.innerHTML;else if(f==="cssText"){const p=c.cssText;d.appendChild(document.createTextNode(p))}else{const p=f,g=typeof c[p]>"u"?"":c[p];d.setAttribute(f,g)}d.setAttribute(Mn,"true"),o.some((f,p)=>(l=p,d.isEqualNode(f)))?o.splice(l,1):a.push(d)}),o.forEach(c=>{var d;return(d=c.parentNode)==null?void 0:d.removeChild(c)}),a.forEach(c=>n.appendChild(c)),{oldTags:o,newTags:a}},If=(t,e)=>{const n=document.getElementsByTagName(t)[0];if(!n)return;const r=n.getAttribute(Mn),o=r?r.split(","):[],a=[...o],l=Object.keys(e);for(const c of l){const d=e[c]||"";n.getAttribute(c)!==d&&n.setAttribute(c,d),o.indexOf(c)===-1&&o.push(c);const f=a.indexOf(c);f!==-1&&a.splice(f,1)}for(let c=a.length-1;c>=0;c-=1)n.removeAttribute(a[c]);o.length===a.length?n.removeAttribute(Mn):n.getAttribute(Mn)!==l.join(",")&&n.setAttribute(Mn,l.join(","))},Mk=(t,e)=>{typeof t<"u"&&document.title!==t&&(document.title=ob(t)),If("title",e)},zv=(t,e)=>{const{baseTag:n,bodyAttributes:r,htmlAttributes:o,linkTags:a,metaTags:l,noscriptTags:c,onChangeClientState:d,scriptTags:f,styleTags:p,title:g,titleAttributes:x}=t;If("body",r),If("html",o),Mk(g,x);const y={baseTag:Ki("base",n),linkTags:Ki("link",a),metaTags:Ki("meta",l),noscriptTags:Ki("noscript",c),scriptTags:Ki("script",f),styleTags:Ki("style",p)},_={},S={};
41Object.keys(y).forEach(b=>{const{newTags:k,oldTags:P}=y[b];k.length&&(_[b]=k),P.length&&(S[b]=y[b].oldTags)}),e&&e(),d(t,_,S)},_a=null,$k=t=>{_a&&cancelAnimationFrame(_a),t.defer?_a=requestAnimationFrame(()=>{zv(t,()=>{_a=null})}):(zv(t),_a=null)},Fk=$k,Wv=class extends E.Component{constructor(){super(...arguments);br(this,"rendered",!1)}shouldComponentUpdate(e){return!bk(e,this.props)}componentDidUpdate(){this.emitChange()}componentWillUnmount(){const{helmetInstances:e}=this.props.context;e.remove(this),this.emitChange()}emitChange(){const{helmetInstances:e,setHelmet:n}=this.props.context;let r=null;const o=Ck(e.get().map(a=>{const{context:l,...c}=a.props;return c}));cb.canUseDOM?Fk(o):jf&&(r=jf(o)),n(r)}init(){if(this.rendered)return;this.rendered=!0;const{helmetInstances:e}=this.props.context;e.add(this),this.emitChange()}render(){return this.init(),null}},tc=[],Hv=t=>{const e={};for(const n of Object.keys(t))e[ib[n]||n]=t[n];return e},zs=t=>{const e={};for(const n of Object.keys(t)){const r=Oc[n];e[r||n]=t[n]}return e},qv=(t,e)=>{if(!Kp)return;const n=document.getElementsByTagName(t)[0];if(!n)return;const r="data-rh-managed",o=n.getAttribute(r),a=o?o.split(","):[],l=Object.keys(e);for(const c of a)l.includes(c)||n.removeAttribute(c);for(const c of l){const d=e[c];d==null||d===!1?n.removeAttribute(c):d===!0?n.setAttribute(c,""):n.setAttribute(c,String(d))}l.length>0?n.setAttribute(r,l.join(",")):n.removeAttribute(r)},Qh=()=>{const t={},e={};for(const n of tc){const{htmlAttributes:r,bodyAttributes:o}=n.props;r&&Object.assign(t,Hv(r)),o&&Object.assign(e,Hv(o))}qv("html",t),qv("body",e)},Uk=class extends E.Component{componentDidMount(){tc.push(this),Qh()}componentDidUpdate(){Qh()}componentWillUnmount(){const t=tc.indexOf(this);t!==-1&&tc.splice(t,1),Qh()}resolveTitle(){const{title:t,titleTemplate:e,defaultTitle:n}=this.props;return t&&e?e.replace(/%s/g,()=>Array.isArray(t)?t.join(""):t):t||n||void 0}renderTitle(){const t=this.resolveTitle();if(t===void 0)return null;const e=this.props.titleAttributes||{};return K.createElement("title",zs(e),t)}renderBase(){const{base:t}=this.props;return t?K.createElement("base",zs(t)):null}renderMeta(){const{meta:t}=this.props;return!t||!Array.isArray(t)?null:t.map((e,n)=>K.createElement("meta",{key:n,...zs(e)}))}renderLink(){const{link:t}=this.props;return!t||!Array.isArray(t)?null:t.map((e,n)=>K.createElement("link",{key:n,...zs(e)}))}renderScript(){const{script:t}=this.props;return!t||!Array.isArray(t)?null:t.map((e,n)=>{const{innerHTML:r,...o}=e,a=zs(o);return r&&(a.dangerouslySetInnerHTML={__html:r}),K.createElement("script",{key:n,...a})})}renderStyle(){const{style:t}=this.props;return!t||!Array.isArray(t)?null:t.map((e,n)=>{const{cssText:r,...o}=e,a=zs(o);return r&&(a.dangerouslySetInnerHTML={__html:r}),K.createElement("style",{key:n,...a})})}renderNoscript(){const{noscript:t}=this.props;return!t||!Array.isArray(t)?null:t.map((e,n)=>{const{innerHTML:r,...o}=e,a=zs(o);return r&&(a.dangerouslySetInnerHTML={__html:r}),K.createElement("noscript",{key:n,...a})})}render(){return K.createElement(K.Fragment,null,this.renderTitle(),this.renderBase(),this.renderMeta(),this.renderLink(),this.renderScript(),this.renderStyle(),this.renderNoscript())}},Af,Vk=(Af=class extends E.Component{shouldComponentUpdate(t){return!gk(Bv(this.props,"helmetData"),Bv(t,"helmetData"))}mapNestedChildrenToProps(t,e){if(!e)return null;switch(t.type){case"script":case"noscript":return{innerHTML:e};case"style":return{cssText:e};default:throw new Error(`<${t.type} /> elements are self-closing and can not contain children. Refer to our API for more information.`)}}flattenArrayTypeChildren(t,e,n,r){return{...e,[t.type]:[...e[t.type]||[],{...n,...this.mapNestedChildrenToProps(t,r)}]}}mapObjectTypeChildren(t,e,n,r){switch(t.type){case"title":return{...e,[t.type]:r,titleAttributes:{...n}};case"body":return{...e,bodyAttributes:{...n}};case"html":return{...e,htmlAttributes:{...n}};default:return{...e,[t.type]:{...n}}}}mapArrayTypeChildrenToProps(t,e){let n={...e};return Object.keys(t).forEach(r=>{n={...n,[r]:t[r]}}),n}
41warnOnInvalidChildren(t,e){return Fv(Vv.some(n=>t.type===n),typeof t.type=="function"?"You may be attempting to nest <Helmet> components within each other, which is not allowed. Refer to our API for more information.":`Only elements types ${Vv.join(", ")} are allowed. Helmet does not support rendering <${t.type}> elements. Refer to our API for more information.`),Fv(!e||typeof e=="string"||Array.isArray(e)&&!e.some(n=>typeof n!="string"),`Helmet expects a string as a child of <${t.type}>. Did you forget to wrap your children in braces? ( <${t.type}>{\`\`}</${t.type}> ) Refer to our API for more information.`),!0}mapChildrenToProps(t,e){let n={};return K.Children.forEach(t,r=>{if(!r||!r.props)return;const{children:o,...a}=r.props,l=Object.keys(a).reduce((d,f)=>(d[ib[f]||f]=a[f],d),{});let{type:c}=r;switch(typeof c=="symbol"?c=c.toString():this.warnOnInvalidChildren(r,o),c){case"Symbol(react.fragment)":e=this.mapChildrenToProps(o,e);break;case"link":case"meta":case"noscript":case"script":case"style":n=this.flattenArrayTypeChildren(r,n,l,o);break;default:e=this.mapObjectTypeChildren(r,e,l,o);break}}),this.mapArrayTypeChildrenToProps(n,e)}render(){const{children:t,...e}=this.props;let n={...e},{helmetData:r}=e;if(t&&(n=this.mapChildrenToProps(t,n)),r&&!(r instanceof Of)){const o=r;r=new Of(o.context,!0),delete n.helmetData}return Nf?K.createElement(Uk,{...n}):r?K.createElement(Wv,{...n,context:r.value}):K.createElement(ub.Consumer,null,o=>K.createElement(Wv,{...n,context:o}))}},br(Af,"defaultProps",{defer:!0,encodeSpecialCharacters:!0,prioritizeSeoTags:!1}),Af);const Bk="modulepreload",zk=function(t){return"/"+t},Kv={},Ro=function(e,n,r){let o=Promise.resolve();if(n&&n.length>0){let l=function(f){return Promise.all(f.map(p=>Promise.resolve(p).then(g=>({status:"fulfilled",value:g}),g=>({status:"rejected",reason:g}))))};document.getElementsByTagName("link");const c=document.querySelector("meta[property=csp-nonce]"),d=(c==null?void 0:c.nonce)||(c==null?void 0:c.getAttribute("nonce"));o=l(n.map(f=>{if(f=zk(f),f in Kv)return;Kv[f]=!0;const p=f.endsWith(".css"),g=p?'[rel="stylesheet"]':"";if(document.querySelector(`link[href="${f}"]${g}`))return;const x=document.createElement("link");if(x.rel=p?"stylesheet":Bk,p||(x.as="script"),x.crossOrigin="",x.href=f,d&&x.setAttribute("nonce",d),document.head.appendChild(x),p)return new Promise((y,_)=>{x.addEventListener("load",y),x.addEventListener("error",()=>_(new Error(`Unable to preload CSS for ${f}`)))})}))}function a(l){const c=new Event("vite:preloadError",{cancelable:!0});if(c.payload=l,window.dispatchEvent(c),!c.defaultPrevented)throw l}return o.then(l=>{for(const c of l||[])c.status==="rejected"&&a(c.reason);return e().catch(a)})};var cl=class{constructor(){this.listeners=new Set,this.subscribe=this.subscribe.bind(this)}subscribe(t){return this.listeners.add(t),this.onSubscribe(),()=>{this.listeners.delete(t),this.onUnsubscribe()}}hasListeners(){return this.listeners.size>0}onSubscribe(){}onUnsubscribe(){}},Wk={setTimeout:(t,e)=>setTimeout(t,e),clearTimeout:t=>clearTimeout(t),setInterval:(t,e)=>setInterval(t,e),clearInterval:t=>clearInterval(t)},us,Hp,Kx,Hk=(Kx=class{constructor(){be(this,us,Wk);be(this,Hp,!1)}setTimeoutProvider(t){se(this,us,t)}setTimeout(t,e){return O(this,us).setTimeout(t,e)}clearTimeout(t){O(this,us).clearTimeout(t)}setInterval(t,e){return O(this,us).setInterval(t,e)}clearInterval(t){O(this,us).clearInterval(t)}},us=new WeakMap,Hp=new WeakMap,Kx),Xs=new Hk;function qk(t){setTimeout(t,0)}var gi=typeof window>"u"||"Deno"in globalThis;function qt(){}function Kk(t,e){return typeof t=="function"?t(e):t}function Lf(t){return typeof t=="number"&&t>=0&&t!==1/0}function db(t,e){return Math.max(t+(e||0)-Date.now(),0)}function ws(t,e){return typeof t=="function"?t(e):t}function gn(t,e){return typeof t=="function"?t(e):t}function Gv(t,e){const{type:n="all",exact:r,fetchStatus:o,predicate:a,queryKey:l,stale:c}=t;if(l){if(r){if(e.queryHash!==Gp(l,e.options))return!1}else if(!Va(e.queryKey,l))return!1}if(n!=="all"){const d=e.isActive();if(n==="active"&&!d||n==="inactive"&&d)return!1}return!(typeof c=="boolean"&&e.isStale()!==c||o&&o!==e.state.fetchStatus||a&&!a(e))}function Qv(t,e){const{exact:n,status:r,predicate:o,mutationKey:a}=t;if(a){if(!e.options.mutationKey)return!1;if(n){if(Ua(e.options.mutationKey)!==Ua(a))return!1}else if(!Va(e.options.mutationKey,a))return!1}return!(r&&e.state.status!==r||o&&!o(e))}
41function Gp(t,e){return((e==null?void 0:e.queryKeyHashFn)||Ua)(t)}function Ua(t){return JSON.stringify(t,(e,n)=>Mf(n)?Object.keys(n).sort().reduce((r,o)=>(r[o]=n[o],r),{}):n)}function Va(t,e){return t===e?!0:typeof t!=typeof e?!1:t&&e&&typeof t=="object"&&typeof e=="object"?Object.keys(e).every(n=>Va(t[n],e[n])):!1}var Gk=Object.prototype.hasOwnProperty;function hb(t,e,n=0){if(t===e)return t;if(n>500)return e;const r=Yv(t)&&Yv(e);if(!r&&!(Mf(t)&&Mf(e)))return e;const a=(r?t:Object.keys(t)).length,l=r?e:Object.keys(e),c=l.length,d=r?new Array(c):{};let f=0;for(let p=0;p<c;p++){const g=r?p:l[p],x=t[g],y=e[g];if(x===y){d[g]=x,(r?p<a:Gk.call(t,g))&&f++;continue}if(x===null||y===null||typeof x!="object"||typeof y!="object"){d[g]=y;continue}const _=hb(x,y,n+1);d[g]=_,_===x&&f++}return a===c&&f===a?t:d}function Df(t,e){if(!e||Object.keys(t).length!==Object.keys(e).length)return!1;for(const n in t)if(t[n]!==e[n])return!1;return!0}function Yv(t){return Array.isArray(t)&&t.length===Object.keys(t).length}function Mf(t){if(!Jv(t))return!1;const e=t.constructor;if(e===void 0)return!0;const n=e.prototype;return!(!Jv(n)||!n.hasOwnProperty("isPrototypeOf")||Object.getPrototypeOf(t)!==Object.prototype)}function Jv(t){return Object.prototype.toString.call(t)==="[object Object]"}function Qk(t){return new Promise(e=>{Xs.setTimeout(e,t)})}function $f(t,e,n){return typeof n.structuralSharing=="function"?n.structuralSharing(t,e):n.structuralSharing!==!1?hb(t,e):e}function Yk(t,e,n=0){const r=[...t,e];return n&&r.length>n?r.slice(1):r}function Jk(t,e,n=0){const r=[e,...t];return n&&r.length>n?r.slice(0,-1):r}var Qp=Symbol();function fb(t,e){return!t.queryFn&&(e!=null&&e.initialPromise)?()=>e.initialPromise:!t.queryFn||t.queryFn===Qp?()=>Promise.reject(new Error(`Missing queryFn: '${t.queryHash}'`)):t.queryFn}function pb(t,e){return typeof t=="function"?t(...e):!!t}function Xk(t,e,n){let r=!1,o;return Object.defineProperty(t,"signal",{enumerable:!0,get:()=>(o??(o=e()),r||(r=!0,o.aborted?n():o.addEventListener("abort",n,{once:!0})),o)}),t}var si,cs,po,Gx,Zk=(Gx=class extends cl{constructor(){super();be(this,si);be(this,cs);be(this,po);se(this,po,e=>{if(!gi&&window.addEventListener){const n=()=>e();return window.addEventListener("visibilitychange",n,!1),()=>{window.removeEventListener("visibilitychange",n)}}})}onSubscribe(){O(this,cs)||this.setEventListener(O(this,po))}onUnsubscribe(){var e;this.hasListeners()||((e=O(this,cs))==null||e.call(this),se(this,cs,void 0))}setEventListener(e){var n;se(this,po,e),(n=O(this,cs))==null||n.call(this),se(this,cs,e(r=>{typeof r=="boolean"?this.setFocused(r):this.onFocus()}))}setFocused(e){O(this,si)!==e&&(se(this,si,e),this.onFocus())}onFocus(){const e=this.isFocused();this.listeners.forEach(n=>{n(e)})}isFocused(){var e;return typeof O(this,si)=="boolean"?O(this,si):((e=globalThis.document)==null?void 0:e.visibilityState)!=="hidden"}},si=new WeakMap,cs=new WeakMap,po=new WeakMap,Gx),Yp=new Zk;function Ff(){let t,e;const n=new Promise((o,a)=>{t=o,e=a});n.status="pending",n.catch(()=>{});function r(o){Object.assign(n,o),delete n.resolve,delete n.reject}return n.resolve=o=>{r({status:"fulfilled",value:o}),t(o)},n.reject=o=>{r({status:"rejected",reason:o}),e(o)},n}var eC=qk;function tC(){let t=[],e=0,n=c=>{c()},r=c=>{c()},o=eC;const a=c=>{e?t.push(c):o(()=>{n(c)})},l=()=>{const c=t;t=[],c.length&&o(()=>{r(()=>{c.forEach(d=>{n(d)})})})};return{batch:c=>{let d;e++;try{d=c()}finally{e--,e||l()}return d},batchCalls:c=>(...d)=>{a(()=>{c(...d)})},schedule:a,setNotifyFunction:c=>{n=c},setBatchNotifyFunction:c=>{r=c},setScheduler:c=>{o=c}}}var St=tC(),mo,ds,go,Qx,nC=(Qx=class extends cl{constructor(){super();be(this,mo,!0);be(this,ds);be(this,go);se(this,go,e=>{if(!gi&&window.addEventListener){const n=()=>e(!0),r=()=>e(!1);return window.addEventListener("online",n,!1),window.addEventListener("offline",r,!1),()=>{window.removeEventListener("online",n),window.removeEventListener("offline",r)}}})}onSubscribe(){O(this,ds)||this.setEventListener(O(this,go))}onUnsubscribe(){var e;this.hasListeners()||((e=O(this,ds))==null||e.call(this),se(this,ds,void 0))}setEventListener(e){var n;se(this,go,e),(n=O(this,ds))==null||n.call(this),se(this,ds,e(this.setOnline.bind(this)))}setOnline(e){O(this,mo)!==e&&(se(this,mo,e),this.listeners.forEac
vendor: 4,702 bytes, line 41
41h(r=>{r(e)}))}isOnline(){return O(this,mo)}},mo=new WeakMap,ds=new WeakMap,go=new WeakMap,Qx),fc=new nC;function rC(t){return Math.min(1e3*2**t,3e4)}function mb(t){return(t??"online")==="online"?fc.isOnline():!0}var Uf=class extends Error{constructor(t){super("CancelledError"),this.revert=t==null?void 0:t.revert,this.silent=t==null?void 0:t.silent}};function gb(t){let e=!1,n=0,r;const o=Ff(),a=()=>o.status!=="pending",l=S=>{var b;if(!a()){const k=new Uf(S);x(k),(b=t.onCancel)==null||b.call(t,k)}},c=()=>{e=!0},d=()=>{e=!1},f=()=>Yp.isFocused()&&(t.networkMode==="always"||fc.isOnline())&&t.canRun(),p=()=>mb(t.networkMode)&&t.canRun(),g=S=>{a()||(r==null||r(),o.resolve(S))},x=S=>{a()||(r==null||r(),o.reject(S))},y=()=>new Promise(S=>{var b;r=k=>{(a()||f())&&S(k)},(b=t.onPause)==null||b.call(t)}).then(()=>{var S;r=void 0,a()||(S=t.onContinue)==null||S.call(t)}),_=()=>{if(a())return;let S;const b=n===0?t.initialPromise:void 0;try{S=b??t.fn()}catch(k){S=Promise.reject(k)}Promise.resolve(S).then(g).catch(k=>{var D;if(a())return;const P=t.retry??(gi?0:3),C=t.retryDelay??rC,A=typeof C=="function"?C(n,k):C,L=P===!0||typeof P=="number"&&n<P||typeof P=="function"&&P(n,k);if(e||!L){x(k);return}n++,(D=t.onFail)==null||D.call(t,n,k),Qk(A).then(()=>f()?void 0:y()).then(()=>{e?x(k):_()})})};return{promise:o,status:()=>o.status,cancel:l,continue:()=>(r==null||r(),o),cancelRetry:c,continueRetry:d,canStart:p,start:()=>(p()?_():y().then(_),o)}}var ii,Yx,yb=(Yx=class{constructor(){be(this,ii)}destroy(){this.clearGcTimeout()}scheduleGc(){this.clearGcTimeout(),Lf(this.gcTime)&&se(this,ii,Xs.setTimeout(()=>{this.optionalRemove()},this.gcTime))}updateGcTime(t){this.gcTime=Math.max(this.gcTime||0,t??(gi?1/0:300*1e3))}clearGcTimeout(){O(this,ii)&&(Xs.clearTimeout(O(this,ii)),se(this,ii,void 0))}},ii=new WeakMap,Yx),oi,yo,mn,ai,mt,sl,li,Nn,Er,Jx,sC=(Jx=class extends yb{constructor(e){super();be(this,Nn);be(this,oi);be(this,yo);be(this,mn);be(this,ai);be(this,mt);be(this,sl);be(this,li);se(this,li,!1),se(this,sl,e.defaultOptions),this.setOptions(e.options),this.observers=[],se(this,ai,e.client),se(this,mn,O(this,ai).getQueryCache()),this.queryKey=e.queryKey,this.queryHash=e.queryHash,se(this,oi,Zv(this.options)),this.state=e.state??O(this,oi),this.scheduleGc()}get meta(){return this.options.meta}get promise(){var e;return(e=O(this,mt))==null?void 0:e.promise}setOptions(e){if(this.options={...O(this,sl),...e},this.updateGcTime(this.options.gcTime),this.state&&this.state.data===void 0){const n=Zv(this.options);n.data!==void 0&&(this.setState(Xv(n.data,n.dataUpdatedAt)),se(this,oi,n))}}optionalRemove(){!this.observers.length&&this.state.fetchStatus==="idle"&&O(this,mn).remove(this)}setData(e,n){const r=$f(this.state.data,e,this.options);return Re(this,Nn,Er).call(this,{data:r,type:"success",dataUpdatedAt:n==null?void 0:n.updatedAt,manual:n==null?void 0:n.manual}),r}setState(e,n){Re(this,Nn,Er).call(this,{type:"setState",state:e,setStateOptions:n})}cancel(e){var r,o;const n=(r=O(this,mt))==null?void 0:r.promise;return(o=O(this,mt))==null||o.cancel(e),n?n.then(qt).catch(qt):Promise.resolve()}destroy(){super.destroy(),this.cancel({silent:!0})}reset(){this.destroy(),this.setState(O(this,oi))}isActive(){return this.observers.some(e=>gn(e.options.enabled,this)!==!1)}isDisabled(){return this.getObserversCount()>0?!this.isActive():this.options.queryFn===Qp||this.state.dataUpdateCount+this.state.errorUpdateCount===0}isStatic(){return this.getObserversCount()>0?this.observers.some(e=>ws(e.options.staleTime,this)==="static"):!1}isStale(){return this.getObserversCount()>0?this.observers.some(e=>e.getCurrentResult().isStale):this.state.data===void 0||this.state.isInvalidated}isStaleByTime(e=0){return this.state.data===void 0?!0:e==="static"?!1:this.state.isInvalidated?!0:!db(this.state.dataUpdatedAt,e)}onFocus(){var n;const e=this.observers.find(r=>r.shouldFetchOnWindowFocus());e==null||e.refetch({cancelRefetch:!1}),(n=O(this,mt))==null||n.continue()}onOnline(){var n;const e=this.observers.find(r=>r.shouldFetchOnReconnect());e==null||e.refetch({cancelRefetch:!1}),(n=O(this,mt))==null||n.continue()}addObserver(e){this.observers.includes(e)||(this.observers.push(e),this.clearGcTimeout(),O(this,mn).notify({type:"observerAdded",query:this,observer:e}))}removeObserver(e){this.observers.includes(e)&&(this.observers=this.observers.filter(n=>n!==e),this.observers.length||(O(this,mt)&&(O(this,li)?O(this,mt).cancel({revert:!0}):O(this,mt).cancelRetry()),this.scheduleGc()),O(this,mn).notify({type:"observerRemoved",query:this,observer:e}))}getObserversCount(){return this.observers.length}invalidate(){this.state.isInvalidated||Re(this,Nn,Er).call(this,{type:"invalidate"})}
41async fetch(e,n){var d,f,p,g,x,y,_,S,b,k,P,C;if(this.state.fetchStatus!=="idle"&&((d=O(this,mt))==null?void 0:d.status())!=="rejected"){if(this.state.data!==void 0&&(n!=null&&n.cancelRefetch))this.cancel({silent:!0});else if(O(this,mt))return O(this,mt).continueRetry(),O(this,mt).promise}if(e&&this.setOptions(e),!this.options.queryFn){const A=this.observers.find(L=>L.options.queryFn);A&&this.setOptions(A.options)}const r=new AbortController,o=A=>{Object.defineProperty(A,"signal",{enumerable:!0,get:()=>(se(this,li,!0),r.signal)})},a=()=>{const A=fb(this.options,n),D=(()=>{const V={client:O(this,ai),queryKey:this.queryKey,meta:this.meta};return o(V),V})();return se(this,li,!1),this.options.persister?this.options.persister(A,D,this):A(D)},c=(()=>{const A={fetchOptions:n,options:this.options,queryKey:this.queryKey,client:O(this,ai),state:this.state,fetchFn:a};return o(A),A})();(f=this.options.behavior)==null||f.onFetch(c,this),se(this,yo,this.state),(this.state.fetchStatus==="idle"||this.state.fetchMeta!==((p=c.fetchOptions)==null?void 0:p.meta))&&Re(this,Nn,Er).call(this,{type:"fetch",meta:(g=c.fetchOptions)==null?void 0:g.meta}),se(this,mt,gb({initialPromise:n==null?void 0:n.initialPromise,fn:c.fetchFn,onCancel:A=>{A instanceof Uf&&A.revert&&this.setState({...O(this,yo),fetchStatus:"idle"}),r.abort()},onFail:(A,L)=>{Re(this,Nn,Er).call(this,{type:"failed",failureCount:A,error:L})},onPause:()=>{Re(this,Nn,Er).call(this,{type:"pause"})},onContinue:()=>{Re(this,Nn,Er).call(this,{type:"continue"})},retry:c.options.retry,retryDelay:c.options.retryDelay,networkMode:c.options.networkMode,canRun:()=>!0}));try{const A=await O(this,mt).start();if(A===void 0)throw new Error(`${this.queryHash} data is undefined`);return this.setData(A),(y=(x=O(this,mn).config).onSuccess)==null||y.call(x,A,this),(S=(_=O(this,mn).config).onSettled)==null||S.call(_,A,this.state.error,this),A}catch(A){if(A instanceof Uf){if(A.silent)return O(this,mt).promise;if(A.revert){if(this.state.data===void 0)throw A;return this.state.data}}throw Re(this,Nn,Er).call(this,{type:"error",error:A}),(k=(b=O(this,mn).config).onError)==null||k.call(b,A,this),(C=(P=O(this,mn).config).onSettled)==null||C.call(P,this.state.data,A,this),A}finally{this.scheduleGc()}}},oi=new WeakMap,yo=new WeakMap,mn=new WeakMap,ai=new WeakMap,mt=new WeakMap,sl=new WeakMap,li=new WeakMap,Nn=new WeakSet,Er=function(e){const n=r=>{switch(e.type){case"failed":return{...r,fetchFailureCount:e.failureCount,fetchFailureReason:e.error};case"pause":return{...r,fetchStatus:"paused"};case"continue":return{...r,fetchStatus:"fetching"};case"fetch":return{...r,...vb(r.data,this.options),fetchMeta:e.meta??null};case"success":const o={...r,...Xv(e.data,e.dataUpdatedAt),dataUpdateCount:r.dataUpdateCount+1,...!e.manual&&{fetchStatus:"idle",fetchFailureCount:0,fetchFailureReason:null}};return se(this,yo,e.manual?o:void 0),o;case"error":const a=e.error;return{...r,error:a,errorUpdateCount:r.errorUpdateCount+1,errorUpdatedAt:Date.now(),fetchFailureCount:r.fetchFailureCount+1,fetchFailureReason:a,fetchStatus:"idle",status:"error",isInvalidated:!0};case"invalidate":return{...r,isInvalidated:!0};case"setState":return{...r,...e.state}}};this.state=n(this.state),St.batch(()=>{this.observers.forEach(r=>{r.onQueryUpdate()}),O(this,mn).notify({query:this,type:"updated",action:e})})},Jx);function vb(t,e){return{fetchFailureCount:0,fetchFailureReason:null,fetchStatus:mb(e.networkMode)?"fetching":"paused",...t===void 0&&{error:null,status:"pending"}}}function Xv(t,e){return{data:t,dataUpdatedAt:e??Date.now(),error:null,isInvalidated:!1,status:"success"}}function Zv(t){const e=typeof t.initialData=="function"?t.initialData():t.initialData,n=e!==void 0,r=n?typeof t.initialDataUpdatedAt=="function"?t.initialDataUpdatedAt():t.initialDataUpdatedAt:0;return{data:e,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 Wt,je,il,Nt,ui,vo,kr,hs,ol,wo,xo,ci,di,fs,bo,Me,Aa,Vf,Bf,zf,Wf,Hf,qf,Kf,wb,Xx,iC=(Xx=class extends cl{constructor(e,n){super();be(this,Me);be(this,Wt);
vendor: 4,184 bytes, line 41
41be(this,je);be(this,il);be(this,Nt);be(this,ui);be(this,vo);be(this,kr);be(this,hs);be(this,ol);be(this,wo);be(this,xo);be(this,ci);be(this,di);be(this,fs);be(this,bo,new Set);this.options=n,se(this,Wt,e),se(this,hs,null),se(this,kr,Ff()),this.bindMethods(),this.setOptions(n)}bindMethods(){this.refetch=this.refetch.bind(this)}onSubscribe(){this.listeners.size===1&&(O(this,je).addObserver(this),e0(O(this,je),this.options)?Re(this,Me,Aa).call(this):this.updateResult(),Re(this,Me,Wf).call(this))}onUnsubscribe(){this.hasListeners()||this.destroy()}shouldFetchOnReconnect(){return Gf(O(this,je),this.options,this.options.refetchOnReconnect)}shouldFetchOnWindowFocus(){return Gf(O(this,je),this.options,this.options.refetchOnWindowFocus)}destroy(){this.listeners=new Set,Re(this,Me,Hf).call(this),Re(this,Me,qf).call(this),O(this,je).removeObserver(this)}setOptions(e){const n=this.options,r=O(this,je);if(this.options=O(this,Wt).defaultQueryOptions(e),this.options.enabled!==void 0&&typeof this.options.enabled!="boolean"&&typeof this.options.enabled!="function"&&typeof gn(this.options.enabled,O(this,je))!="boolean")throw new Error("Expected enabled to be a boolean or a callback that returns a boolean");Re(this,Me,Kf).call(this),O(this,je).setOptions(this.options),n._defaulted&&!Df(this.options,n)&&O(this,Wt).getQueryCache().notify({type:"observerOptionsUpdated",query:O(this,je),observer:this});const o=this.hasListeners();o&&t0(O(this,je),r,this.options,n)&&Re(this,Me,Aa).call(this),this.updateResult(),o&&(O(this,je)!==r||gn(this.options.enabled,O(this,je))!==gn(n.enabled,O(this,je))||ws(this.options.staleTime,O(this,je))!==ws(n.staleTime,O(this,je)))&&Re(this,Me,Vf).call(this);const a=Re(this,Me,Bf).call(this);o&&(O(this,je)!==r||gn(this.options.enabled,O(this,je))!==gn(n.enabled,O(this,je))||a!==O(this,fs))&&Re(this,Me,zf).call(this,a)}getOptimisticResult(e){const n=O(this,Wt).getQueryCache().build(O(this,Wt),e),r=this.createResult(n,e);return aC(this,r)&&(se(this,Nt,r),se(this,vo,this.options),se(this,ui,O(this,je).state)),r}getCurrentResult(){return O(this,Nt)}trackResult(e,n){return new Proxy(e,{get:(r,o)=>(this.trackProp(o),n==null||n(o),o==="promise"&&(this.trackProp("data"),!this.options.experimental_prefetchInRender&&O(this,kr).status==="pending"&&O(this,kr).reject(new Error("experimental_prefetchInRender feature flag is not enabled"))),Reflect.get(r,o))})}trackProp(e){O(this,bo).add(e)}getCurrentQuery(){return O(this,je)}refetch({...e}={}){return this.fetch({...e})}fetchOptimistic(e){const n=O(this,Wt).defaultQueryOptions(e),r=O(this,Wt).getQueryCache().build(O(this,Wt),n);return r.fetch().then(()=>this.createResult(r,n))}fetch(e){return Re(this,Me,Aa).call(this,{...e,cancelRefetch:e.cancelRefetch??!0}).then(()=>(this.updateResult(),O(this,Nt)))}createResult(e,n){var q;const r=O(this,je),o=this.options,a=O(this,Nt),l=O(this,ui),c=O(this,vo),f=e!==r?e.state:O(this,il),{state:p}=e;let g={...p},x=!1,y;if(n._optimisticResults){const H=this.hasListeners(),te=!H&&e0(e,n),Z=H&&t0(e,r,n,o);(te||Z)&&(g={...g,...vb(p.data,e.options)}),n._optimisticResults==="isRestoring"&&(g.fetchStatus="idle")}let{error:_,errorUpdatedAt:S,status:b}=g;y=g.data;let k=!1;if(n.placeholderData!==void 0&&y===void 0&&b==="pending"){let H;a!=null&&a.isPlaceholderData&&n.placeholderData===(c==null?void 0:c.placeholderData)?(H=a.data,k=!0):H=typeof n.placeholderData=="function"?n.placeholderData((q=O(this,xo))==null?void 0:q.state.data,O(this,xo)):n.placeholderData,H!==void 0&&(b="success",y=$f(a==null?void 0:a.data,H,n),x=!0)}if(n.select&&y!==void 0&&!k)if(a&&y===(l==null?void 0:l.data)&&n.select===O(this,ol))y=O(this,wo);else try{se(this,ol,n.select),y=n.select(y),y=$f(a==null?void 0:a.data,y,n),se(this,wo,y),se(this,hs,null)}catch(H){se(this,hs,H)}O(this,hs)&&(_=O(this,hs),y=O(this,wo),S=Date.now(),b="error");const P=g.fetchStatus==="fetching",C=b==="pending",A=b==="error",L=C&&P,D=y!==void 0,z={status:b,fetchStatus:g.fetchStatus,isPending:C,isSuccess:b==="success",isError:A,isInitialLoading:L,isLoading:L,data:y,dataUpdatedAt:g.dataUpdatedAt,error:_,errorUpdatedAt:S,failureCount:g.fetchFailureCount,failureReason:g.fetchFailureReason,errorUpdate
vendor: 4,156 bytes, line 41
41Count:g.errorUpdateCount,isFetched:g.dataUpdateCount>0||g.errorUpdateCount>0,isFetchedAfterMount:g.dataUpdateCount>f.dataUpdateCount||g.errorUpdateCount>f.errorUpdateCount,isFetching:P,isRefetching:P&&!C,isLoadingError:A&&!D,isPaused:g.fetchStatus==="paused",isPlaceholderData:x,isRefetchError:A&&D,isStale:Jp(e,n),refetch:this.refetch,promise:O(this,kr),isEnabled:gn(n.enabled,e)!==!1};if(this.options.experimental_prefetchInRender){const H=z.data!==void 0,te=z.status==="error"&&!H,Z=fe=>{te?fe.reject(z.error):H&&fe.resolve(z.data)},me=()=>{const fe=se(this,kr,z.promise=Ff());Z(fe)},J=O(this,kr);switch(J.status){case"pending":e.queryHash===r.queryHash&&Z(J);break;case"fulfilled":(te||z.data!==J.value)&&me();break;case"rejected":(!te||z.error!==J.reason)&&me();break}}return z}updateResult(){const e=O(this,Nt),n=this.createResult(O(this,je),this.options);if(se(this,ui,O(this,je).state),se(this,vo,this.options),O(this,ui).data!==void 0&&se(this,xo,O(this,je)),Df(n,e))return;se(this,Nt,n);const r=()=>{if(!e)return!0;const{notifyOnChangeProps:o}=this.options,a=typeof o=="function"?o():o;if(a==="all"||!a&&!O(this,bo).size)return!0;const l=new Set(a??O(this,bo));return this.options.throwOnError&&l.add("error"),Object.keys(O(this,Nt)).some(c=>{const d=c;return O(this,Nt)[d]!==e[d]&&l.has(d)})};Re(this,Me,wb).call(this,{listeners:r()})}onQueryUpdate(){this.updateResult(),this.hasListeners()&&Re(this,Me,Wf).call(this)}},Wt=new WeakMap,je=new WeakMap,il=new WeakMap,Nt=new WeakMap,ui=new WeakMap,vo=new WeakMap,kr=new WeakMap,hs=new WeakMap,ol=new WeakMap,wo=new WeakMap,xo=new WeakMap,ci=new WeakMap,di=new WeakMap,fs=new WeakMap,bo=new WeakMap,Me=new WeakSet,Aa=function(e){Re(this,Me,Kf).call(this);let n=O(this,je).fetch(this.options,e);return e!=null&&e.throwOnError||(n=n.catch(qt)),n},Vf=function(){Re(this,Me,Hf).call(this);const e=ws(this.options.staleTime,O(this,je));if(gi||O(this,Nt).isStale||!Lf(e))return;const r=db(O(this,Nt).dataUpdatedAt,e)+1;se(this,ci,Xs.setTimeout(()=>{O(this,Nt).isStale||this.updateResult()},r))},Bf=function(){return(typeof this.options.refetchInterval=="function"?this.options.refetchInterval(O(this,je)):this.options.refetchInterval)??!1},zf=function(e){Re(this,Me,qf).call(this),se(this,fs,e),!(gi||gn(this.options.enabled,O(this,je))===!1||!Lf(O(this,fs))||O(this,fs)===0)&&se(this,di,Xs.setInterval(()=>{(this.options.refetchIntervalInBackground||Yp.isFocused())&&Re(this,Me,Aa).call(this)},O(this,fs)))},Wf=function(){Re(this,Me,Vf).call(this),Re(this,Me,zf).call(this,Re(this,Me,Bf).call(this))},Hf=function(){O(this,ci)&&(Xs.clearTimeout(O(this,ci)),se(this,ci,void 0))},qf=function(){O(this,di)&&(Xs.clearInterval(O(this,di)),se(this,di,void 0))},Kf=function(){const e=O(this,Wt).getQueryCache().build(O(this,Wt),this.options);if(e===O(this,je))return;const n=O(this,je);se(this,je,e),se(this,il,e.state),this.hasListeners()&&(n==null||n.removeObserver(this),e.addObserver(this))},wb=function(e){St.batch(()=>{e.listeners&&this.listeners.forEach(n=>{n(O(this,Nt))}),O(this,Wt).getQueryCache().notify({query:O(this,je),type:"observerResultsUpdated"})})},Xx);function oC(t,e){return gn(e.enabled,t)!==!1&&t.state.data===void 0&&!(t.state.status==="error"&&e.retryOnMount===!1)}function e0(t,e){return oC(t,e)||t.state.data!==void 0&&Gf(t,e,e.refetchOnMount)}function Gf(t,e,n){if(gn(e.enabled,t)!==!1&&ws(e.staleTime,t)!=="static"){const r=typeof n=="function"?n(t):n;return r==="always"||r!==!1&&Jp(t,e)}return!1}function t0(t,e,n,r){return(t!==e||gn(r.enabled,t)===!1)&&(!n.suspense||t.state.status!=="error")&&Jp(t,n)}function Jp(t,e){return gn(e.enabled,t)!==!1&&t.isStaleByTime(ws(e.staleTime,t))}function aC(t,e){return!Df(t.getCurrentResult(),e)}function n0(t){return{onFetch:(e,n)=>{var p,g,x,y,_;const r=e.options,o=(x=(g=(p=e.fetchOptions)==null?void 0:p.meta)==null?void 0:g.fetchMore)==null?void 0:x.direction,a=((y=e.state.data)==null?void 0:y.pages)||[],l=((_=e.state.data)==null?void 0:_.pageParams)||[];let c={pages:[],pageParams:[]},d=0;const f=async()=>{let S=!1;const b=C=>{Xk(C,()=>e.signal,()=>S=!0)},k=fb(e.options,e.fetchOptions),P=async(C,A,L)=>{if(S)return Promise.reject();
vendor: 4,262 bytes, line 41
41if(A==null&&C.pages.length)return Promise.resolve(C);const V=(()=>{const te={client:e.client,queryKey:e.queryKey,pageParam:A,direction:L?"backward":"forward",meta:e.options.meta};return b(te),te})(),z=await k(V),{maxPages:q}=e.options,H=L?Jk:Yk;return{pages:H(C.pages,z,q),pageParams:H(C.pageParams,A,q)}};if(o&&a.length){const C=o==="backward",A=C?lC:r0,L={pages:a,pageParams:l},D=A(r,L);c=await P(L,D,C)}else{const C=t??a.length;do{const A=d===0?l[0]??r.initialPageParam:r0(r,c);if(d>0&&A==null)break;c=await P(c,A),d++}while(d<C)}return c};e.options.persister?e.fetchFn=()=>{var S,b;return(b=(S=e.options).persister)==null?void 0:b.call(S,f,{client:e.client,queryKey:e.queryKey,meta:e.options.meta,signal:e.signal},n)}:e.fetchFn=f}}}function r0(t,{pages:e,pageParams:n}){const r=e.length-1;return e.length>0?t.getNextPageParam(e[r],e,n[r],n):void 0}function lC(t,{pages:e,pageParams:n}){var r;return e.length>0?(r=t.getPreviousPageParam)==null?void 0:r.call(t,e[0],e,n[0],n):void 0}var al,nr,Pt,hi,rr,ss,Zx,uC=(Zx=class extends yb{constructor(e){super();be(this,rr);be(this,al);be(this,nr);be(this,Pt);be(this,hi);se(this,al,e.client),this.mutationId=e.mutationId,se(this,Pt,e.mutationCache),se(this,nr,[]),this.state=e.state||cC(),this.setOptions(e.options),this.scheduleGc()}setOptions(e){this.options=e,this.updateGcTime(this.options.gcTime)}get meta(){return this.options.meta}addObserver(e){O(this,nr).includes(e)||(O(this,nr).push(e),this.clearGcTimeout(),O(this,Pt).notify({type:"observerAdded",mutation:this,observer:e}))}removeObserver(e){se(this,nr,O(this,nr).filter(n=>n!==e)),this.scheduleGc(),O(this,Pt).notify({type:"observerRemoved",mutation:this,observer:e})}optionalRemove(){O(this,nr).length||(this.state.status==="pending"?this.scheduleGc():O(this,Pt).remove(this))}continue(){var e;return((e=O(this,hi))==null?void 0:e.continue())??this.execute(this.state.variables)}async execute(e){var l,c,d,f,p,g,x,y,_,S,b,k,P,C,A,L,D,V;const n=()=>{Re(this,rr,ss).call(this,{type:"continue"})},r={client:O(this,al),meta:this.options.meta,mutationKey:this.options.mutationKey};se(this,hi,gb({fn:()=>this.options.mutationFn?this.options.mutationFn(e,r):Promise.reject(new Error("No mutationFn found")),onFail:(z,q)=>{Re(this,rr,ss).call(this,{type:"failed",failureCount:z,error:q})},onPause:()=>{Re(this,rr,ss).call(this,{type:"pause"})},onContinue:n,retry:this.options.retry??0,retryDelay:this.options.retryDelay,networkMode:this.options.networkMode,canRun:()=>O(this,Pt).canRun(this)}));const o=this.state.status==="pending",a=!O(this,hi).canStart();try{if(o)n();else{Re(this,rr,ss).call(this,{type:"pending",variables:e,isPaused:a}),O(this,Pt).config.onMutate&&await O(this,Pt).config.onMutate(e,this,r);const q=await((c=(l=this.options).onMutate)==null?void 0:c.call(l,e,r));q!==this.state.context&&Re(this,rr,ss).call(this,{type:"pending",context:q,variables:e,isPaused:a})}const z=await O(this,hi).start();return await((f=(d=O(this,Pt).config).onSuccess)==null?void 0:f.call(d,z,e,this.state.context,this,r)),await((g=(p=this.options).onSuccess)==null?void 0:g.call(p,z,e,this.state.context,r)),await((y=(x=O(this,Pt).config).onSettled)==null?void 0:y.call(x,z,null,this.state.variables,this.state.context,this,r)),await((S=(_=this.options).onSettled)==null?void 0:S.call(_,z,null,e,this.state.context,r)),Re(this,rr,ss).call(this,{type:"success",data:z}),z}catch(z){try{await((k=(b=O(this,Pt).config).onError)==null?void 0:k.call(b,z,e,this.state.context,this,r))}catch(q){Promise.reject(q)}try{await((C=(P=this.options).onError)==null?void 0:C.call(P,z,e,this.state.context,r))}catch(q){Promise.reject(q)}try{await((L=(A=O(this,Pt).config).onSettled)==null?void 0:L.call(A,void 0,z,this.state.variables,this.state.context,this,r))}catch(q){Promise.reject(q)}try{await((V=(D=this.options).onSettled)==null?void 0:V.call(D,void 0,z,e,this.state.context,r))}catch(q){Promise.reject(q)}throw Re(this,rr,ss).call(this,{type:"error",error:z}),z}finally{O(this,Pt).runNext(this)}}},al=new WeakMap,nr=new WeakMap,Pt=new WeakMap,hi=new WeakMap,rr=new WeakSet,ss=function(e){const n=r=>{switch(e.type){case"failed":return{...r,failureCount:e.failureCount,failureReason:e.error};case"pause":return{...r,isPaused:!0};case"continue":return{...r,isPaused:!1};
41case"pending":return{...r,context:e.context,data:void 0,failureCount:0,failureReason:null,error:null,isPaused:e.isPaused,status:"pending",variables:e.variables,submittedAt:Date.now()};case"success":return{...r,data:e.data,failureCount:0,failureReason:null,error:null,status:"success",isPaused:!1};case"error":return{...r,data:void 0,error:e.error,failureCount:r.failureCount+1,failureReason:e.error,isPaused:!1,status:"error"}}};this.state=n(this.state),St.batch(()=>{O(this,nr).forEach(r=>{r.onMutationUpdate(e)}),O(this,Pt).notify({mutation:this,type:"updated",action:e})})},Zx);function cC(){return{context:void 0,data:void 0,error:null,failureCount:0,failureReason:null,isPaused:!1,status:"idle",variables:void 0,submittedAt:0}}var Cr,In,ll,eb,dC=(eb=class extends cl{constructor(e={}){super();be(this,Cr);be(this,In);be(this,ll);this.config=e,se(this,Cr,new Set),se(this,In,new Map),se(this,ll,0)}build(e,n,r){const o=new uC({client:e,mutationCache:this,mutationId:++Lu(this,ll)._,options:e.defaultMutationOptions(n),state:r});return this.add(o),o}add(e){O(this,Cr).add(e);const n=$u(e);if(typeof n=="string"){const r=O(this,In).get(n);r?r.push(e):O(this,In).set(n,[e])}this.notify({type:"added",mutation:e})}remove(e){if(O(this,Cr).delete(e)){const n=$u(e);if(typeof n=="string"){const r=O(this,In).get(n);if(r)if(r.length>1){const o=r.indexOf(e);o!==-1&&r.splice(o,1)}else r[0]===e&&O(this,In).delete(n)}}this.notify({type:"removed",mutation:e})}canRun(e){const n=$u(e);if(typeof n=="string"){const r=O(this,In).get(n),o=r==null?void 0:r.find(a=>a.state.status==="pending");return!o||o===e}else return!0}runNext(e){var r;const n=$u(e);if(typeof n=="string"){const o=(r=O(this,In).get(n))==null?void 0:r.find(a=>a!==e&&a.state.isPaused);return(o==null?void 0:o.continue())??Promise.resolve()}else return Promise.resolve()}clear(){St.batch(()=>{O(this,Cr).forEach(e=>{this.notify({type:"removed",mutation:e})}),O(this,Cr).clear(),O(this,In).clear()})}getAll(){return Array.from(O(this,Cr))}find(e){const n={exact:!0,...e};return this.getAll().find(r=>Qv(n,r))}findAll(e={}){return this.getAll().filter(n=>Qv(e,n))}notify(e){St.batch(()=>{this.listeners.forEach(n=>{n(e)})})}resumePausedMutations(){const e=this.getAll().filter(n=>n.state.isPaused);return St.batch(()=>Promise.all(e.map(n=>n.continue().catch(qt))))}},Cr=new WeakMap,In=new WeakMap,ll=new WeakMap,eb);function $u(t){var e;return(e=t.options.scope)==null?void 0:e.id}var sr,tb,hC=(tb=class extends cl{constructor(e={}){super();be(this,sr);this.config=e,se(this,sr,new Map)}build(e,n,r){const o=n.queryKey,a=n.queryHash??Gp(o,n);let l=this.get(a);return l||(l=new sC({client:e,queryKey:o,queryHash:a,options:e.defaultQueryOptions(n),state:r,defaultOptions:e.getQueryDefaults(o)}),this.add(l)),l}add(e){O(this,sr).has(e.queryHash)||(O(this,sr).set(e.queryHash,e),this.notify({type:"added",query:e}))}remove(e){const n=O(this,sr).get(e.queryHash);n&&(e.destroy(),n===e&&O(this,sr).delete(e.queryHash),this.notify({type:"removed",query:e}))}clear(){St.batch(()=>{this.getAll().forEach(e=>{this.remove(e)})})}get(e){return O(this,sr).get(e)}getAll(){return[...O(this,sr).values()]}find(e){const n={exact:!0,...e};return this.getAll().find(r=>Gv(n,r))}findAll(e={}){const n=this.getAll();return Object.keys(e).length>0?n.filter(r=>Gv(e,r)):n}notify(e){St.batch(()=>{this.listeners.forEach(n=>{n(e)})})}onFocus(){St.batch(()=>{this.getAll().forEach(e=>{e.onFocus()})})}onOnline(){St.batch(()=>{this.getAll().forEach(e=>{e.onOnline()})})}},sr=new WeakMap,tb),Je,ps,ms,So,_o,gs,Eo,To,nb,fC=(nb=class{constructor(t={}){be(this,Je);be(this,ps);be(this,ms);be(this,So);be(this,_o);be(this,gs);be(this,Eo);be(this,To);se(this,Je,t.queryCache||new hC),se(this,ps,t.mutationCache||new dC),se(this,ms,t.defaultOptions||{}),se(this,So,new Map),se(this,_o,new Map),se(this,gs,0)}mount(){Lu(this,gs)._++,O(this,gs)===1&&(se(this,Eo,Yp.subscribe(async t=>{t&&(await this.resumePausedMutations(),O(this,Je).onFocus())})),se(this,To,fc.subscribe(async t=>{t&&(await this.resumePausedMutations(),O(this,Je).onOnline())})))}unmount(){var t,e;Lu(this,gs)._--,O(this,gs)===0&&((t=O(this,Eo))==null||t.call(this),se(this,Eo,void 0),(e=O(this,To))==null||e.call(this),se(this,To,void 0))}isFetching(t){return O(this,Je).findAll({...t,fetchStatus:"fetching"}).length}isMutating(t){return O(this,ps).findAll({...t,status:"pending"}).length}getQueryData(t){var n;const e=this.defaultQueryOptions({queryKey:t});return(n=O(this,Je).get(e.queryHash))==null?void 0:n.state.data}ensureQueryData(t){const e=this.defaultQueryOptions(t),n=O(this,Je).build(this,e),r=n.state.data;return r===void 0?this.fetchQuery(t):(t.revalidateIfStale&&n.isStaleByTime(ws(e.staleTime,n))&&this.prefetchQuery(e),Promise.resolve(r))}getQueriesData(t){return O(this,Je).findAll(t).map(({queryKey:e,state:n})=>{const r=n.data;return[e,r]})}setQueryData(t,e,n){const r=this.defaultQueryOptions({queryKey:t}),o=O(this,Je).get(r.queryHash),a=o==null?void 0:o.state.data,l=Kk(e,a);if(l!==void 0)return O(this,Je).build(this,r).setData(l,{...n,manual:!0})}
41setQueriesData(t,e,n){return St.batch(()=>O(this,Je).findAll(t).map(({queryKey:r})=>[r,this.setQueryData(r,e,n)]))}getQueryState(t){var n;const e=this.defaultQueryOptions({queryKey:t});return(n=O(this,Je).get(e.queryHash))==null?void 0:n.state}removeQueries(t){const e=O(this,Je);St.batch(()=>{e.findAll(t).forEach(n=>{e.remove(n)})})}resetQueries(t,e){const n=O(this,Je);return St.batch(()=>(n.findAll(t).forEach(r=>{r.reset()}),this.refetchQueries({type:"active",...t},e)))}cancelQueries(t,e={}){const n={revert:!0,...e},r=St.batch(()=>O(this,Je).findAll(t).map(o=>o.cancel(n)));return Promise.all(r).then(qt).catch(qt)}invalidateQueries(t,e={}){return St.batch(()=>(O(this,Je).findAll(t).forEach(n=>{n.invalidate()}),(t==null?void 0:t.refetchType)==="none"?Promise.resolve():this.refetchQueries({...t,type:(t==null?void 0:t.refetchType)??(t==null?void 0:t.type)??"active"},e)))}refetchQueries(t,e={}){const n={...e,cancelRefetch:e.cancelRefetch??!0},r=St.batch(()=>O(this,Je).findAll(t).filter(o=>!o.isDisabled()&&!o.isStatic()).map(o=>{let a=o.fetch(void 0,n);return n.throwOnError||(a=a.catch(qt)),o.state.fetchStatus==="paused"?Promise.resolve():a}));return Promise.all(r).then(qt)}fetchQuery(t){const e=this.defaultQueryOptions(t);e.retry===void 0&&(e.retry=!1);const n=O(this,Je).build(this,e);return n.isStaleByTime(ws(e.staleTime,n))?n.fetch(e):Promise.resolve(n.state.data)}prefetchQuery(t){return this.fetchQuery(t).then(qt).catch(qt)}fetchInfiniteQuery(t){return t.behavior=n0(t.pages),this.fetchQuery(t)}prefetchInfiniteQuery(t){return this.fetchInfiniteQuery(t).then(qt).catch(qt)}ensureInfiniteQueryData(t){return t.behavior=n0(t.pages),this.ensureQueryData(t)}resumePausedMutations(){return fc.isOnline()?O(this,ps).resumePausedMutations():Promise.resolve()}getQueryCache(){return O(this,Je)}getMutationCache(){return O(this,ps)}getDefaultOptions(){return O(this,ms)}setDefaultOptions(t){se(this,ms,t)}setQueryDefaults(t,e){O(this,So).set(Ua(t),{queryKey:t,defaultOptions:e})}getQueryDefaults(t){const e=[...O(this,So).values()],n={};return e.forEach(r=>{Va(t,r.queryKey)&&Object.assign(n,r.defaultOptions)}),n}setMutationDefaults(t,e){O(this,_o).set(Ua(t),{mutationKey:t,defaultOptions:e})}getMutationDefaults(t){const e=[...O(this,_o).values()],n={};return e.forEach(r=>{Va(t,r.mutationKey)&&Object.assign(n,r.defaultOptions)}),n}defaultQueryOptions(t){if(t._defaulted)return t;const e={...O(this,ms).queries,...this.getQueryDefaults(t.queryKey),...t,_defaulted:!0};return e.queryHash||(e.queryHash=Gp(e.queryKey,e)),e.refetchOnReconnect===void 0&&(e.refetchOnReconnect=e.networkMode!=="always"),e.throwOnError===void 0&&(e.throwOnError=!!e.suspense),!e.networkMode&&e.persister&&(e.networkMode="offlineFirst"),e.queryFn===Qp&&(e.enabled=!1),e}defaultMutationOptions(t){return t!=null&&t._defaulted?t:{...O(this,ms).mutations,...(t==null?void 0:t.mutationKey)&&this.getMutationDefaults(t.mutationKey),...t,_defaulted:!0}}clear(){O(this,Je).clear(),O(this,ps).clear()}},Je=new WeakMap,ps=new WeakMap,ms=new WeakMap,So=new WeakMap,_o=new WeakMap,gs=new WeakMap,Eo=new WeakMap,To=new WeakMap,nb),xb=E.createContext(void 0),pC=t=>{const e=E.useContext(xb);if(!e)throw new Error("No QueryClient set, use QueryClientProvider to set one");return e},mC=({client:t,children:e})=>(E.useEffect(()=>(t.mount(),()=>{t.unmount()}),[t]),v.jsx(xb.Provider,{value:t,children:e})),bb=E.createContext(!1),gC=()=>E.useContext(bb);bb.Provider;function yC(){let t=!1;return{clearReset:()=>{t=!1},reset:()=>{t=!0},isReset:()=>t}}var vC=E.createContext(yC()),wC=()=>E.useContext(vC),xC=(t,e,n)=>{const r=n!=null&&n.state.error&&typeof t.throwOnError=="function"?pb(t.throwOnError,[n.state.error,n]):t.throwOnError;(t.suspense||t.experimental_prefetchInRender||r)&&(e.isReset()||(t.retryOnMount=!1))},bC=t=>{E.useEffect(()=>{t.clearReset()},[t])},SC=({result:t,errorResetBoundary:e,throwOnError:n,query:r,suspense:o})=>t.isError&&!e.isReset()&&!t.isFetching&&r&&(o&&t.data===void 0||pb(n,[t.error,r])),_C=t=>{if(t.suspense){const n=o=>o==="static"?o:Math.max(o??1e3,1e3),r=t.staleTime;t.staleTime=typeof r=="function"?(...o)=>n(r(...o)):n(r),typeof t.gcTime=="number"&&(t.gcTime=Math.max(t.gcTime,1e3))}},EC=(t,e)=>t.isLoading&&t.isFetching&&!e,TC=(t,e)=>(t==null?void 0:t.suspense)&&e.isPending,s0=(t,e,n)=>e.fetchOptimistic(t).catch(()=>{n.clearReset()});function kC(t,e,n){var x,y,_,S;const r=gC(),o=wC(),a=pC(),l=a.defaultQueryOptions(t);(y=(x=a.getDefaultOptions().queries)==null?void 0:x._experimental_beforeQuery)==null||y.call(x,l);const c=a.getQueryCache().get(l.queryHash);l._optimisticResults=r?"isRestoring":"optimistic",_C(l),xC(l,o,c),bC(o);const d=!a.getQueryCache().get(l.queryHash),[f]=E.useState(()=>new e(a,l)),p=f.getOptimisticResult(l),g=!r&&t.subscribed!==!1;if(E.useSyncExternalStore(E.useCallback(b=>{const k=g?f.subscribe(St.batchCalls(b)):qt;return f.updateResult(),k},[f,g]),()=>f.getCurrentResult(),()=>f.getCurrentResult()),E.useEffect(()=>{f.setOptions(l)},[l,f]),TC(l,p))throw s0(l,f,o);if(SC({result:p,errorResetBoundary:o,throwOnError:l.throwOnError,query:c,suspense:l.suspense}))throw p.error;if((S=(_=a.getDefaultOptions().queries)==null?void 0:_._experimental_afterQuery)==null||S.call(_,l,p),l.experimental_prefetchInRender&&!gi&&EC(p,r)){const b=d?s0(l,f,o):c==null?void 0:c.promise;b==null||b.catch(qt).finally(()=>{f.updateResult()})}return l.notifyOnChangeProps?p:f.trackResult(p)}function i0(t,e){return kC(t,iC)}var Nc=rb();const Sb=ul(Nc);/**
42 * @remix-run/router v1.23.2
43 *
44 * Copyright (c) Remix Software Inc.
45 *
46 * This source code is licensed under the MIT license found in the
47 * LICENSE.md file in the root directory of this source tree.
48 *
49 * @license MIT
50 */function Ba(){return Ba=Object.assign?Object.assign.bind():function(t){for(var e=1;e<arguments.length;e++){var n=arguments[e];for(var r in n)Object.prototype.hasOwnProperty.call(n,r)&&(t[r]=n[r])}return t},Ba.apply(this,arguments)}var ys;(function(t){t.Pop="POP",t.Push="PUSH",t.Replace="REPLACE"})(ys||(ys={}));const o0="popstate";function CC(t){t===void 0&&(t={});function e(r,o){let{pathname:a,search:l,hash:c}=r.location;return Qf("",{pathname:a,search:l,hash:c},o.state&&o.state.usr||null,o.state&&o.state.key||"default")}
vendor: 4,515 bytes, line 50
50function n(r,o){return typeof o=="string"?o:_b(o)}return AC(e,n,null,t)}function ot(t,e){if(t===!1||t===null||typeof t>"u")throw new Error(e)}function Xp(t,e){if(!t){typeof console<"u"&&console.warn(e);try{throw new Error(e)}catch{}}}function PC(){return Math.random().toString(36).substr(2,8)}function a0(t,e){return{usr:t.state,key:t.key,idx:e}}function Qf(t,e,n,r){return n===void 0&&(n=null),Ba({pathname:typeof t=="string"?t:t.pathname,search:"",hash:""},typeof e=="string"?jo(e):e,{state:n,key:e&&e.key||r||PC()})}function _b(t){let{pathname:e="/",search:n="",hash:r=""}=t;return n&&n!=="?"&&(e+=n.charAt(0)==="?"?n:"?"+n),r&&r!=="#"&&(e+=r.charAt(0)==="#"?r:"#"+r),e}function jo(t){let e={};if(t){let n=t.indexOf("#");n>=0&&(e.hash=t.substr(n),t=t.substr(0,n));let r=t.indexOf("?");r>=0&&(e.search=t.substr(r),t=t.substr(0,r)),t&&(e.pathname=t)}return e}function AC(t,e,n,r){r===void 0&&(r={});let{window:o=document.defaultView,v5Compat:a=!1}=r,l=o.history,c=ys.Pop,d=null,f=p();f==null&&(f=0,l.replaceState(Ba({},l.state,{idx:f}),""));function p(){return(l.state||{idx:null}).idx}function g(){c=ys.Pop;let b=p(),k=b==null?null:b-f;f=b,d&&d({action:c,location:S.location,delta:k})}function x(b,k){c=ys.Push;let P=Qf(S.location,b,k);f=p()+1;let C=a0(P,f),A=S.createHref(P);try{l.pushState(C,"",A)}catch(L){if(L instanceof DOMException&&L.name==="DataCloneError")throw L;o.location.assign(A)}a&&d&&d({action:c,location:S.location,delta:1})}function y(b,k){c=ys.Replace;let P=Qf(S.location,b,k);f=p();let C=a0(P,f),A=S.createHref(P);l.replaceState(C,"",A),a&&d&&d({action:c,location:S.location,delta:0})}function _(b){let k=o.location.origin!=="null"?o.location.origin:o.location.href,P=typeof b=="string"?b:_b(b);return P=P.replace(/ $/,"%20"),ot(k,"No window.location.(origin|href) available to create URL for href: "+P),new URL(P,k)}let S={get action(){return c},get location(){return t(o,l)},listen(b){if(d)throw new Error("A history only accepts one active listener");return o.addEventListener(o0,g),d=b,()=>{o.removeEventListener(o0,g),d=null}},createHref(b){return e(o,b)},createURL:_,encodeLocation(b){let k=_(b);return{pathname:k.pathname,search:k.search,hash:k.hash}},push:x,replace:y,go(b){return l.go(b)}};return S}var l0;(function(t){t.data="data",t.deferred="deferred",t.redirect="redirect",t.error="error"})(l0||(l0={}));function RC(t,e,n){return n===void 0&&(n="/"),jC(t,e,n)}function jC(t,e,n,r){let o=typeof e=="string"?jo(e):e,a=kb(o.pathname||"/",n);if(a==null)return null;let l=Eb(t);OC(l);let c=null;for(let d=0;c==null&&d<l.length;++d){let f=WC(a);c=VC(l[d],f)}return c}function Eb(t,e,n,r){e===void 0&&(e=[]),n===void 0&&(n=[]),r===void 0&&(r="");let o=(a,l,c)=>{let d={relativePath:c===void 0?a.path||"":c,caseSensitive:a.caseSensitive===!0,childrenIndex:l,route:a};d.relativePath.startsWith("/")&&(ot(d.relativePath.startsWith(r),'Absolute route path "'+d.relativePath+'" nested under path '+('"'+r+'" is not valid. An absolute child route path ')+"must start with the combined path of all its parent routes."),d.relativePath=d.relativePath.slice(r.length));let f=fi([r,d.relativePath]),p=n.concat(d);a.children&&a.children.length>0&&(ot(a.index!==!0,"Index routes must not have child routes. Please remove "+('all child routes from route path "'+f+'".')),Eb(a.children,e,p,f)),!(a.path==null&&!a.index)&&e.push({path:f,score:FC(f,a.index),routesMeta:p})};return t.forEach((a,l)=>{var c;if(a.path===""||!((c=a.path)!=null&&c.includes("?")))o(a,l);else for(let d of Tb(a.path))o(a,l,d)}),e}function Tb(t){let e=t.split("/");if(e.length===0)return[];let[n,...r]=e,o=n.endsWith("?"),a=n.replace(/\?$/,"");if(r.length===0)return o?[a,""]:[a];let l=Tb(r.join("/")),c=[];return c.push(...l.map(d=>d===""?a:[a,d].join("/"))),o&&c.push(...l),c.map(d=>t.startsWith("/")&&d===""?"/":d)}function OC(t){t.sort((e,n)=>e.score!==n.score?n.score-e.score:UC(e.routesMeta.map(r=>r.childrenIndex),n.routesMeta.map(r=>r.childrenIndex)))}const NC=/^:[\w-]+$/,IC=3,LC=2,DC=1,MC=10,$C=-2,u0=t=>t==="*";function FC(t,e){let n=t.split("/"),r=n.length;return n.some(u0)&&(r+=$C),e&&(r+=LC),n.filter(o=>!u0(o)).reduce((o,a)=>o+(NC.test(a)?IC:a===""?DC:MC),r)}function UC(t,e){return t.length===e.length&&t.slice(0,-1).every((r,o)=>r===e[o])?t[t.length-1]-e[e.length-1]:0}function VC(t,e,n){let{routesMeta:r}=t,o={},a="/",l=[];for(let c=0;c<r.length;++c){let d=r[c],f=c===r.length-1,p=a==="/"?e:e.slice(a.length)||"/",g=BC({path:d.relativePath,caseSensitive:d.caseSensitive,end:f},p),x=d.route;if(!g)return null;
vendor: 6,609 bytes, lines 50-59
50Object.assign(o,g.params),l.push({params:o,pathname:fi([a,g.pathname]),pathnameBase:QC(fi([a,g.pathnameBase])),route:x}),g.pathnameBase!=="/"&&(a=fi([a,g.pathnameBase]))}return l}function BC(t,e){typeof t=="string"&&(t={path:t,caseSensitive:!1,end:!0});let[n,r]=zC(t.path,t.caseSensitive,t.end),o=e.match(n);if(!o)return null;let a=o[0],l=a.replace(/(.)\/+$/,"$1"),c=o.slice(1);return{params:r.reduce((f,p,g)=>{let{paramName:x,isOptional:y}=p;if(x==="*"){let S=c[g]||"";l=a.slice(0,a.length-S.length).replace(/(.)\/+$/,"$1")}const _=c[g];return y&&!_?f[x]=void 0:f[x]=(_||"").replace(/%2F/g,"/"),f},{}),pathname:a,pathnameBase:l,pattern:t}}function zC(t,e,n){e===void 0&&(e=!1),n===void 0&&(n=!0),Xp(t==="*"||!t.endsWith("*")||t.endsWith("/*"),'Route path "'+t+'" will be treated as if it were '+('"'+t.replace(/\*$/,"/*")+'" because the `*` character must ')+"always follow a `/` in the pattern. To get rid of this warning, "+('please change the route path to "'+t.replace(/\*$/,"/*")+'".'));let r=[],o="^"+t.replace(/\/*\*?$/,"").replace(/^\/*/,"/").replace(/[\\.*+^${}|()[\]]/g,"\\$&").replace(/\/:([\w-]+)(\?)?/g,(l,c,d)=>(r.push({paramName:c,isOptional:d!=null}),d?"/?([^\\/]+)?":"/([^\\/]+)"));return t.endsWith("*")?(r.push({paramName:"*"}),o+=t==="*"||t==="/*"?"(.*)$":"(?:\\/(.+)|\\/*)$"):n?o+="\\/*$":t!==""&&t!=="/"&&(o+="(?:(?=\\/|$))"),[new RegExp(o,e?void 0:"i"),r]}function WC(t){try{return t.split("/").map(e=>decodeURIComponent(e).replace(/\//g,"%2F")).join("/")}catch(e){return Xp(!1,'The URL path "'+t+'" could not be decoded because it is is a malformed URL segment. This is probably due to a bad percent '+("encoding ("+e+").")),t}}function kb(t,e){if(e==="/")return t;if(!t.toLowerCase().startsWith(e.toLowerCase()))return null;let n=e.endsWith("/")?e.length-1:e.length,r=t.charAt(n);return r&&r!=="/"?null:t.slice(n)||"/"}const HC=/^(?:[a-z][a-z0-9+.-]*:|\/\/)/i,qC=t=>HC.test(t);function KC(t,e){e===void 0&&(e="/");let{pathname:n,search:r="",hash:o=""}=typeof t=="string"?jo(t):t,a;if(n)if(qC(n))a=n;else{if(n.includes("//")){let l=n;n=n.replace(/\/\/+/g,"/"),Xp(!1,"Pathnames cannot have embedded double slashes - normalizing "+(l+" -> "+n))}n.startsWith("/")?a=c0(n.substring(1),"/"):a=c0(n,e)}else a=e;return{pathname:a,search:YC(r),hash:JC(o)}}function c0(t,e){let n=e.replace(/\/+$/,"").split("/");return t.split("/").forEach(o=>{o===".."?n.length>1&&n.pop():o!=="."&&n.push(o)}),n.length>1?n.join("/"):"/"}function Yh(t,e,n,r){return"Cannot include a '"+t+"' character in a manually specified "+("`to."+e+"` 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 GC(t){return t.filter((e,n)=>n===0||e.route.path&&e.route.path.length>0)}function Cb(t,e){let n=GC(t);return e?n.map((r,o)=>o===n.length-1?r.pathname:r.pathnameBase):n.map(r=>r.pathnameBase)}function Pb(t,e,n,r){r===void 0&&(r=!1);let o;typeof t=="string"?o=jo(t):(o=Ba({},t),ot(!o.pathname||!o.pathname.includes("?"),Yh("?","pathname","search",o)),ot(!o.pathname||!o.pathname.includes("#"),Yh("#","pathname","hash",o)),ot(!o.search||!o.search.includes("#"),Yh("#","search","hash",o)));let a=t===""||o.pathname==="",l=a?"/":o.pathname,c;if(l==null)c=n;else{let g=e.length-1;if(!r&&l.startsWith("..")){let x=l.split("/");for(;x[0]==="..";)x.shift(),g-=1;o.pathname=x.join("/")}c=g>=0?e[g]:"/"}let d=KC(o,c),f=l&&l!=="/"&&l.endsWith("/"),p=(a||l===".")&&n.endsWith("/");return!d.pathname.endsWith("/")&&(f||p)&&(d.pathname+="/"),d}const fi=t=>t.join("/").replace(/\/\/+/g,"/"),QC=t=>t.replace(/\/+$/,"").replace(/^\/*/,"/"),YC=t=>!t||t==="?"?"":t.startsWith("?")?t:"?"+t,JC=t=>!t||t==="#"?"":t.startsWith("#")?t:"#"+t;function XC(t){return t!=null&&typeof t.status=="number"&&typeof t.statusText=="string"&&typeof t.internal=="boolean"&&"data"in t}const Ab=["post","put","patch","delete"];new Set(Ab);const ZC=["get",...Ab];new Set(ZC);/**
51 * React Router v6.30.3
52 *
53 * Copyright (c) Remix Software Inc.
54 *
55 * This source code is licensed under the MIT license found in the
56 * LICENSE.md file in the root directory of this source tree.
57 *
58 * @license MIT
59 */function za(){return za=Object.assign?Object.assign.bind():function(t){for(var e=1;e<arguments.length;e++){var n=arguments[e];for(var r in n)Object.prototype.hasOwnProperty.call(n,r)&&(t[r]=n[r])}return t},za.apply(this,arguments)}const Zp=E.createContext(null),eP=E.createContext(null),dl=E.createContext(null),Ic=E.createContext(null),vi=E.createContext({outlet:null,matches:[],isDataRoute:!1}),Rb=E.createContext(null);function hl(){return E.useContext(Ic)!=null}function fl(){return hl()||ot(!1),E.useContext(Ic).location}function jb(t){E.useContext(dl).static||E.useLayoutEffect(t)}function em(){let{isDataRoute:t}=E.useContext(vi);return t?fP():tP()}function tP(){hl()||ot(!1);let t=E.useContext(Zp),{basename:e,future:n,navigator:r}=E.useContext(dl),{matches:o}=E.useContext(vi),{pathname:a}=fl(),l=JSON.stringify(Cb(o,n.v7_relativeSplatPath)),c=E.useRef(!1);return jb(()=>{c.current=!0}),E.useCallback(function(f,p){if(p===void 0&&(p={}),!c.current)return;if(typeof f=="number"){r.go(f);return}let g=Pb(f,JSON.parse(l),a,p.relative==="path");t==null&&e!=="/"&&(g.pathname=g.pathname==="/"?e:fi([e,g.pathname])),(p.replace?r.replace:r.push)(g,p.state,p)},[e,r,l,a,t])}function nP(t,e){return rP(t,e)}function rP(t,e,n,r){hl()||ot(!1);let{navigator:o}=E.useContext(dl),{matches:a}=E.useContext(vi),l=a[a.length-1],c=l?l.params:{};l&&l.pathname;let d=l?l.pathnameBase:"/";l&&l.route;let f=fl(),p;if(e){var g;let b=typeof e=="string"?jo(e):e;d==="/"||(g=b.pathname)!=null&&g.startsWith(d)||ot(!1),p=b}else p=f;let x=p.pathname||"/",y=x;if(d!=="/"){let b=d.replace(/^\//,"").split("/");y="/"+x.replace(/^\//,"").split("/").slice(b.length).join("/")}let _=RC(t,{pathname:y}),S=lP(_&&_.map(b=>Object.assign({},b,{params:Object.assign({},c,b.params),pathname:fi([d,o.encodeLocation?o.encodeLocation(b.pathname).pathname:b.pathname]),pathnameBase:b.pathnameBase==="/"?d:fi([d,o.encodeLocation?o.encodeLocation(b.pathnameBase).pathname:b.pathnameBase])})),a,n,r);return e&&S?E.createElement(Ic.Provider,{value:{location:za({pathname:"/",search:"",hash:"",state:null,key:"default"},p),navigationType:ys.Pop}},S):S}function sP(){let t=hP(),e=XC(t)?t.status+" "+t.statusText:t instanceof Error?t.message:JSON.stringify(t),n=t instanceof Error?t.stack:null,o={padding:"0.5rem",backgroundColor:"rgba(200,200,200, 0.5)"};return E.createElement(E.Fragment,null,E.createElement("h2",null,"Unexpected Application 
59Error!"),E.createElement("h3",{style:{fontStyle:"italic"}},e),n?E.createElement("pre",{style:o},n):null,null)}const iP=E.createElement(sP,null);class oP extends E.Component{constructor(e){super(e),this.state={location:e.location,revalidation:e.revalidation,error:e.error}}static getDerivedStateFromError(e){return{error:e}}static getDerivedStateFromProps(e,n){return n.location!==e.location||n.revalidation!=="idle"&&e.revalidation==="idle"?{error:e.error,location:e.location,revalidation:e.revalidation}:{error:e.error!==void 0?e.error:n.error,location:n.location,revalidation:e.revalidation||n.revalidation}}componentDidCatch(e,n){console.error("React Router caught the following error during render",e,n)}render(){return this.state.error!==void 0?E.createElement(vi.Provider,{value:this.props.routeContext},E.createElement(Rb.Provider,{value:this.state.error,children:this.props.component})):this.props.children}}function aP(t){let{routeContext:e,match:n,children:r}=t,o=E.useContext(Zp);return o&&o.static&&o.staticContext&&(n.route.errorElement||n.route.ErrorBoundary)&&(o.staticContext._deepestRenderedBoundaryId=n.route.id),E.createElement(vi.Provider,{value:e},r)}function lP(t,e,n,r){var o;if(e===void 0&&(e=[]),n===void 0&&(n=null),r===void 0&&(r=null),t==null){var a;if(!n)return null;if(n.errors)t=n.matches;else if((a=r)!=null&&a.v7_partialHydration&&e.length===0&&!n.initialized&&n.matches.length>0)t=n.matches;else return null}let l=t,c=(o=n)==null?void 0:o.errors;if(c!=null){let p=l.findIndex(g=>g.route.id&&(c==null?void 0:c[g.route.id])!==void 0);p>=0||ot(!1),l=l.slice(0,Math.min(l.length,p+1))}let d=!1,f=-1;if(n&&r&&r.v7_partialHydration)for(let p=0;p<l.length;p++){let g=l[p];if((g.route.HydrateFallback||g.route.hydrateFallbackElement)&&(f=p),g.route.id){let{loaderData:x,errors:y}=n,_=g.route.loader&&x[g.route.id]===void 0&&(!y||y[g.route.id]===void 0);if(g.route.lazy||_){d=!0,f>=0?l=l.slice(0,f+1):l=[l[0]];break}}}return l.reduceRight((p,g,x)=>{let y,_=!1,S=null,b=null;n&&(y=c&&g.route.id?c[g.route.id]:void 0,S=g.route.errorElement||iP,d&&(f<0&&x===0?(pP("route-fallback"),_=!0,b=null):f===x&&(_=!0,b=g.route.hydrateFallbackElement||null)));let k=e.concat(l.slice(0,x+1)),P=()=>{let C;return y?C=S:_?C=b:g.route.Component?C=E.createElement(g.route.Component,null):g.route.element?C=g.route.element:C=p,E.createElement(aP,{match:g,routeContext:{outlet:p,matches:k,isDataRoute:n!=null},children:C})};return n&&(g.route.ErrorBoundary||g.route.errorElement||x===0)?E.createElement(oP,{location:n.location,revalidation:n.revalidation,component:S,error:y,children:P(),routeContext:{outlet:null,matches:k,isDataRoute:!0}}):P()},null)}var Ob=(function(t){return t.UseBlocker="useBlocker",t.UseRevalidator="useRevalidator",t.UseNavigateStable="useNavigate",t})(Ob||{}),Nb=(function(t){return t.UseBlocker="useBlocker",t.UseLoaderData="useLoaderData",t.UseActionData="useActionData",t.UseRouteError="useRouteError",t.UseNavigation="useNavigation",t.UseRouteLoaderData="useRouteLoaderData",t.UseMatches="useMatches",t.UseRevalidator="useRevalidator",t.UseNavigateStable="useNavigate",t.UseRouteId="useRouteId",t})(Nb||{});function uP(t){let e=E.useContext(Zp);return e||ot(!1),e}function cP(t){let e=E.useContext(eP);return e||ot(!1),e}function dP(t){let e=E.useContext(vi);return e||ot(!1),e}function Ib(t){let e=dP(),n=e.matches[e.matches.length-1];return n.route.id||ot(!1),n.route.id}function hP(){var t;let e=E.useContext(Rb),n=cP(),r=Ib();return e!==void 0?e:(t=n.errors)==null?void 0:t[r]}function fP(){let{router:t}=uP(Ob.UseNavigateStable),e=Ib(Nb.UseNavigateStable),n=E.useRef(!1);return jb(()=>{n.current=!0}),E.useCallback(function(o,a){a===void 0&&(a={}),n.current&&(typeof o=="number"?t.navigate(o):t.navigate(o,za({fromRouteId:e},a)))},[t,e])}const d0={};function pP(t,e,n){d0[t]||(d0[t]=!0)}function mP(t,e){t==null||t.v7_startTransition,t==null||t.v7_relativeSplatPath}function Wa(t){let{to:e,replace:n,state:r,relative:o}=t;hl()||ot(!1);let{future:a,static:l}=E.useContext(dl),{matches:c}=E.useContext(vi),{pathname:d}=fl(),f=em(),p=Pb(e,Cb(c,a.v7_relativeSplatPath),d,o==="path"),g=JSON.stringify(p);return E.useEffect(()=>f(JSON.parse(g),{replace:n,state:r,relative:o}),[f,g,o,n,r]),null}function fn(t){ot(!1)}function gP(t){let{basename:e="/",children:n=null,location:r,navigationType:o=ys.Pop,navigator:a,static:l=!1,future:c}=t;hl()&&ot(!1);let d=e.replace(/^\/*/,"/"),f=E.useMemo(()=>({basename:d,navigator:a,static:l,future:za({v7_relativeSplatPath:!1},c)}),[d,c,a,l]);typeof r=="string"&&(r=jo(r));let{pathname:p="/",search:g="",hash:x="",state:y=null,key:_="default"}=r,S=E.useMemo(()=>{let b=kb(p,d);return b==null?null:{location:{pathname:b,search:g,hash:x,state:y,key:_},navigationType:o}},[d,p,g,x,y,_,o]);return S==null?null:E.createElement(dl.Provider,{value:f},E.createElement(Ic.Provider,{children:n,value:S}))}function yP(t){let{children:e,location:n}=t;return nP(Yf(e),n)}new Promise(()=>{});function Yf(t,e){e===void 0&&(e=[]);let n=[];
59return E.Children.forEach(t,(r,o)=>{if(!E.isValidElement(r))return;let a=[...e,o];if(r.type===E.Fragment){n.push.apply(n,Yf(r.props.children,a));return}r.type!==fn&&ot(!1),!r.props.index||!r.props.children||ot(!1);let l={id:r.props.id||a.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&&(l.children=Yf(r.props.children,a)),n.push(l)}),n}/**
60 * React Router DOM v6.30.3
61 *
62 * Copyright (c) Remix Software Inc.
63 *
64 * This source code is licensed under the MIT license found in the
65 * LICENSE.md file in the root directory of this source tree.
66 *
67 * @license MIT
68 */const vP="6";try{window.__reactRouterVersion=vP}catch{}const wP="startTransition",h0=jc[wP];function xP(t){let{basename:e,children:n,future:r,window:o}=t,a=E.useRef();a.current==null&&(a.current=CC({window:o,v5Compat:!0}));let l=a.current,[c,d]=E.useState({action:l.action,location:l.location}),{v7_startTransition:f}=r||{},p=E.useCallback(g=>{f&&h0?h0(()=>d(g)):d(g)},[d,f]);return E.useLayoutEffect(()=>l.listen(p),[l,p]),E.useEffect(()=>mP(r),[r]),E.createElement(gP,{basename:e,children:n,location:c.location,navigationType:c.action,navigator:l,future:r})}var f0;(function(t){t.UseScrollRestoration="useScrollRestoration",t.UseSubmit="useSubmit",t.UseSubmitFetcher="useSubmitFetcher",t.UseFetcher="useFetcher",t.useViewTransitionState="useViewTransitionState"})(f0||(f0={}));var p0;(function(t){t.UseFetcher="useFetcher",t.UseFetchers="useFetchers",t.UseScrollRestoration="useScrollRestoration"})(p0||(p0={}));var m0=["light","dark"],bP="(prefers-color-scheme: dark)",SP=E.createContext(void 0),_P={setTheme:t=>{},themes:[]},EP=()=>{var t;return(t=E.useContext(SP))!=null?t:_P};E.memo(({forcedTheme:t,storageKey:e,attribute:n,enableSystem:r,enableColorScheme:o,defaultTheme:a,value:l,attrs:c,nonce:d})=>{let f=a==="system",p=n==="class"?`var d=document.documentElement,c=d.classList;${`c.remove(${c.map(_=>`'${_}'`).join(",")})`};`:`var d=document.documentElement,n='${n}',s='setAttribute';`,g=o?m0.includes(a)&&a?`if(e==='light'||e==='dark'||!e)d.style.colorScheme=e||'${a}'`:"if(e==='light'||e==='dark')d.style.colorScheme=e":"",x=(_,S=!1,b=!0)=>{let k=l?l[_]:_,P=S?_+"|| ''":`'${k}'`,C="";return o&&b&&!S&&m0.includes(_)&&(C+=`d.style.colorScheme = '${_}';`),n==="class"?S||k?C+=`c.add(${P})`:C+="null":k&&(C+=`d[s](n,${P})`),C},y=t?`!function(){${p}${x(t)}}()`:r?`!function(){try{${p}var e=localStorage.getItem('${e}');if('system'===e||(!e&&${f})){var t='${bP}',m=window.matchMedia(t);if(m.media!==t||m.matches){${x("dark")}}else{${x("light")}}}else if(e){${l?`var x=${JSON.stringify(l)};`:""}${x(l?"x[e]":"e",!0)}}${f?"":"else{"+x(a,!1,!1)+"}"}${g}}catch(e){}}()`:`!function(){try{${p}var e=localStorage.getItem('${e}');if(e){${l?`var x=${JSON.stringify(l)};`:""}${x(l?"x[e]":"e",!0)}}else{${x(a,!1,!1)};}${g}}catch(t){}}();`;return E.createElement("script",{nonce:d,dangerouslySetInnerHTML:{__html:y}})});var TP=t=>{switch(t){case"success":return PP;case"info":return RP;case"warning":return AP;case"error":return jP;default:return null}},kP=Array(12).fill(0),CP=({visible:t,className:e})=>K.createElement("div",{className:["sonner-loading-wrapper",e].filter(Boolean).join(" "),"data-visible":t},K.createElement("div",{className:"sonner-spinner"},kP.map((n,r)=>K.createElement("div",{className:"sonner-loading-bar",key:`spinner-bar-${r}`})))),PP=K.createElement("svg",{xmlns:"http://www.w3.org/2000/svg",viewBox:"0 0 20 20",fill:"currentColor",height:"20",width:"20"},K.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"})),AP=K.createElement("svg",{xmlns:"http://www.w3.org/2000/svg",viewBox:"0 0 24 24",fill:"
68currentColor",height:"20",width:"20"},K.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"})),RP=K.createElement("svg",{xmlns:"http://www.w3.org/2000/svg",viewBox:"0 0 20 20",fill:"currentColor",height:"20",width:"20"},K.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"})),jP=K.createElement("svg",{xmlns:"http://www.w3.org/2000/svg",viewBox:"0 0 20 20",fill:"currentColor",height:"20",width:"20"},K.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"})),OP=K.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"},K.createElement("line",{x1:"18",y1:"6",x2:"6",y2:"18"}),K.createElement("line",{x1:"6",y1:"6",x2:"18",y2:"18"})),NP=()=>{let[t,e]=K.useState(document.hidden);return K.useEffect(()=>{let n=()=>{e(document.hidden)};return document.addEventListener("visibilitychange",n),()=>window.removeEventListener("visibilitychange",n)},[]),t},Jf=1,IP=class{constructor(){this.subscribe=t=>(this.subscribers.push(t),()=>{let e=this.subscribers.indexOf(t);this.subscribers.splice(e,1)}),this.publish=t=>{this.subscribers.forEach(e=>e(t))},this.addToast=t=>{this.publish(t),this.toasts=[...this.toasts,t]},this.create=t=>{var e;let{message:n,...r}=t,o=typeof(t==null?void 0:t.id)=="number"||((e=t.id)==null?void 0:e.length)>0?t.id:Jf++,a=this.toasts.find(c=>c.id===o),l=t.dismissible===void 0?!0:t.dismissible;return this.dismissedToasts.has(o)&&this.dismissedToasts.delete(o),a?this.toasts=this.toasts.map(c=>c.id===o?(this.publish({...c,...t,id:o,title:n}
68),{...c,...t,id:o,dismissible:l,title:n}):c):this.addToast({title:n,...r,dismissible:l,id:o}),o},this.dismiss=t=>(this.dismissedToasts.add(t),t||this.toasts.forEach(e=>{this.subscribers.forEach(n=>n({id:e.id,dismiss:!0}))}),this.subscribers.forEach(e=>e({id:t,dismiss:!0})),t),this.message=(t,e)=>this.create({...e,message:t}),this.error=(t,e)=>this.create({...e,message:t,type:"error"}),this.success=(t,e)=>this.create({...e,type:"success",message:t}),this.info=(t,e)=>this.create({...e,type:"info",message:t}),this.warning=(t,e)=>this.create({...e,type:"warning",message:t}),this.loading=(t,e)=>this.create({...e,type:"loading",message:t}),this.promise=(t,e)=>{if(!e)return;let n;e.loading!==void 0&&(n=this.create({...e,promise:t,type:"loading",message:e.loading,description:typeof e.description!="function"?e.description:void 0}));let r=t instanceof Promise?t:t(),o=n!==void 0,a,l=r.then(async d=>{if(a=["resolve",d],K.isValidElement(d))o=!1,this.create({id:n,type:"default",message:d});else if(DP(d)&&!d.ok){o=!1;let f=typeof e.error=="function"?await e.error(`HTTP error! status: ${d.status}`):e.error,p=typeof e.description=="function"?await e.description(`HTTP error! status: ${d.status}`):e.description;this.create({id:n,type:"error",message:f,description:p})}else if(e.success!==void 0){o=!1;let f=typeof e.success=="function"?await e.success(d):e.success,p=typeof e.description=="function"?await e.description(d):e.description;this.create({id:n,type:"success",message:f,description:p})}}).catch(async d=>{if(a=["reject",d],e.error!==void 0){o=!1;let f=typeof e.error=="function"?await e.error(d):e.error,p=typeof e.description=="function"?await e.description(d):e.description;this.create({id:n,type:"error",message:f,description:p})}}).finally(()=>{var d;o&&(this.dismiss(n),n=void 0),(d=e.finally)==null||d.call(e)}),c=()=>new Promise((d,f)=>l.then(()=>a[0]==="reject"?f(a[1]):d(a[1])).catch(f));return typeof n!="string"&&typeof n!="number"?{unwrap:c}:Object.assign(n,{unwrap:c})},this.custom=(t,e)=>{let n=(e==null?void 0:e.id)||Jf++;return this.create({jsx:t(n),id:n,...e}),n},this.getActiveToasts=()=>this.toasts.filter(t=>!this.dismissedToasts.has(t.id)),this.subscribers=[],this.toasts=[],this.dismissedToasts=new Set}},Ht=new IP,LP=(t,e)=>{let n=(e==null?void 0:e.id)||Jf++;return Ht.addToast({title:t,...e,id:n}),n},DP=t=>t&&typeof t=="object"&&"ok"in t&&typeof t.ok=="boolean"&&"status"in t&&typeof t.status=="number",MP=LP,$P=()=>Ht.toasts,FP=()=>Ht.getActiveToasts(),Ln=Object.assign(MP,{success:Ht.success,info:Ht.info,warning:Ht.warning,error:Ht.error,custom:Ht.custom,message:Ht.message,promise:Ht.promise,dismiss:Ht.dismiss,loading:Ht.loading},{getHistory:$P,getToasts:FP});function UP(t,{insertAt:e}={}){if(typeof document>"u")return;let n=document.head||document.getElementsByTagName("head")[0],r=document.createElement("style");r.type="text/css",e==="top"&&n.firstChild?n.insertBefore(r,n.firstChild):n.appendChild(r),r.styleSheet?r.styleSheet.cssText=t:r.appendChild(document.createTextNode(t))}UP(`:where(html[dir="ltr"]),:where([data-sonner-toaster][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%)}:where(html[dir="rtl"]),:where([data-sonner-toaster][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%)}:where([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:none;z-index:999999999;transition:transform .4s ease}:where([data-sonner-toaster][data-lifted="true"]){transform:translateY(-10px)}@media (hover: none) and (pointer: coarse){:where([data-sonner-toaster][data-lifted="true"]){transform:none}}:where([data-sonner-toaster][data-x-position="right"]){right:var(--offset-right)}:where([data-sonner-toaster][data-x-position="left"]){left:var(--offset-left)}:where([data-sonner-toaster][data-x-position="center"]){left:50%;transform:translate(-50%)}:where([data-sonner-toaster][data-y-position="top"]){top:var(--offset-top)}:where([data-sonner-toaster][data-y-position="bottom"]){bottom:var(--offset-bottom)}:where([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);filter:blur(0);touch-action:none;transition:transform .4s,opacity .4s,height .4s,box-shadow .2s;box-sizing:border-box;outline:none;overflow-wrap:anywhere}:where([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 #0000001a;width:var(--width);font-size:13px;display:flex;align-items:center;gap:6px}:where([data-sonner-toast]:focus-visible){box-shadow:0 4px 12px #0000001a,0 0 0 2px #0003}:where([data-sonner-toast][data-y-position="top"]){top:0;--y: translateY(-100%);--lift: 1;--lift-amount: calc(1 * var(--gap))}:where([data-sonner-toast][data-y-position="bottom"]){bottom:0;--y: translateY(100%);--lift: -1;--lift-amount: calc(var(--lift) * var(--gap))}:where([data-sonner-toast]) :where([data-description]){font-weight:400;line-height:1.4;color:inherit}:where([data-sonner-toast]) :where([data-title]){font-weight:500;line-height:1.5;color:inherit}:where([data-sonner-toast]) :where([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)}:where([data-sonner-toast][data-promise="true"]) :where([data-icon])>svg{opacity:0;transform:scale(.8);transform-origin:center;animation:sonner-fade-in .3s ease forwards}:where([data-sonner-toast]) :where([data-icon])>*{flex-shrink:0}:where([data-sonner-toast]) :where([data-icon]) svg{margin-left:var(--toast-svg-margin-start);margin-right:var(--toast-svg-margin-end)}:where([data-sonner-toast]) :where([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;cursor:pointer;outline:none;display:flex;align-items:center;flex-shrink:0;transition:opacity .4s,box-shadow .2s}:where([data-sonner-toast]) :where([data-button]):focus-visible{box-shadow:0 0 0 2px #0006}:where([data-sonner-toast]) :where([data-button]):first-of-type{margin-left:var(--toast-button-margin-start);margin-right:var(--toast-button-margin-end)}:where([data-sonner-toast]) :where([data-cancel]){color:var(--normal-text);background:rgba(0,0,0,.08)}:where([data-sonner-toast][data-theme="dark"]) :where([data-cancel]){background:rgba(255,255,255,.3)}:where([data-sonner-toast]) :where([data-close-button]){position:absolute;
68left: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);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-close-button]{background:var(--gray1)}:where([data-sonner-toast]) :where([data-close-button]):focus-visible{box-shadow:0 4px 12px #0000001a,0 0 0 2px #0003}:where([data-sonner-toast]) :where([data-disabled="true"]){cursor:not-allowed}:where([data-sonner-toast]):hover :where([data-close-button]):hover{background:var(--gray2);border-color:var(--gray5)}:where([data-sonner-toast][data-swiping="true"]):before{content:"";position:absolute;left:-50%;right:-50%;height:100%;z-index:-1}:where([data-sonner-toast][data-y-position="top"][data-swiping="true"]):before{bottom:50%;transform:scaleY(3) translateY(50%)}:where([data-sonner-toast][data-y-position="bottom"][data-swiping="true"]):before{top:50%;transform:scaleY(3) translateY(-50%)}:where([data-sonner-toast][data-swiping="false"][data-removed="true"]):before{content:"";position:absolute;inset:0;transform:scaleY(2)}:where([data-sonner-toast]):after{content:"";position:absolute;left:0;height:calc(var(--gap) + 1px);bottom:100%;width:100%}:where([data-sonner-toast][data-mounted="true"]){--y: translateY(0);opacity:1}:where([data-sonner-toast][data-expanded="false"][data-front="false"]){--scale: var(--toasts-before) * .05 + 1;--y: translateY(calc(var(--lift-amount) * var(--toasts-before))) scale(calc(-1 * var(--scale)));height:var(--front-toast-height)}:where([data-sonner-toast])>*{transition:opacity .4s}:where([data-sonner-toast][data-expanded="false"][data-front="false"][data-styled="true"])>*{opacity:0}
68:where([data-sonner-toast][data-visible="false"]){opacity:0;pointer-events:none}:where([data-sonner-toast][data-mounted="true"][data-expanded="true"]){--y: translateY(calc(var(--lift) * var(--offset)));height:var(--initial-height)}:where([data-sonner-toast][data-removed="true"][data-front="true"][data-swipe-out="false"]){--y: translateY(calc(var(--lift) * -100%));opacity:0}:where([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}:where([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}:where([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, 0px)) translate(var(--swipe-amount-x, 0px));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{0%{transform:var(--y) translate(var(--swipe-amount-x));opacity:1}to{transform:var(--y) translate(calc(var(--swipe-amount-x) - 100%));opacity:0}}@keyframes swipe-out-right{0%{transform:var(--y) translate(var(--swipe-amount-x));opacity:1}to{transform:var(--y) translate(calc(var(--swipe-amount-x) + 100%));opacity:0}}@keyframes swipe-out-up{0%{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{0%{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-theme=light]{--normal-bg: #fff;--normal-border: var(--gray4);--normal-text: var(--gray12);--success-bg: hsl(143, 85%, 96%);--success-border: hsl(145, 92%, 91%);--success-text: hsl(140, 100%, 27%);--info-bg: hsl(208, 100%, 97%);--info-border: hsl(221, 91%, 91%);--info-text: hsl(210, 92%, 45%);--warning-bg: hsl(49, 100%, 97%);--warning-border: hsl(49, 91%, 91%);--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-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-theme=dark] [data-sonner-toast][data-invert=true]{--normal-bg: #fff;--normal-border: var(--gray3);--normal-text: var(--gray12)}[data-sonner-toaster][data-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, 100%, 12%);--info-text: hsl(216, 87%, 65%);--warning-bg: hsl(64, 100%, 6%);--warning-border: hsl(60, 100%, 12%);--warning-text: hsl(46, 87%, 65%);--error-bg: hsl(358, 76%, 10%);--error-border: hsl(357, 89%, 16%);
68--error-text: hsl(358, 100%, 81%)}[data-sonner-toaster][data-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-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],[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],[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],[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],[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:nth-child(1){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)}to{opacity:1;transform:scale(1)}}@keyframes sonner-fade-out{0%{opacity:1;transform:scale(1)}to{opacity:0;transform:scale(.8)}}@keyframes sonner-spin{0%{opacity:1}to{opacity:.15}}@media (prefers-reduced-motion){[data-sonner-toast],[data-sonner-toast]>*,.sonner-loading-bar{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%)}
69`);function Fu(t){return t.label!==void 0}var VP=3,BP="32px",zP="16px",g0=4e3,WP=356,HP=14,qP=20,KP=200;function Pn(...t){return t.filter(Boolean).join(" ")}function GP(t){let[e,n]=t.split("-"),r=[];return e&&r.push(e),n&&r.push(n),r}var QP=t=>{var e,n,r,o,a,l,c,d,f,p,g;let{invert:x,toast:y,unstyled:_,interacting:S,setHeights:b,visibleToasts:k,heights:P,index:C,toasts:A,expanded:L,removeToast:D,defaultRichColors:V,closeButton:z,style:q,cancelButtonStyle:H,actionButtonStyle:te,className:Z="",descriptionClassName:me="",duration:J,position:fe,gap:ie,loadingIcon:de,expandByDefault:U,classNames:W,icons:G,closeButtonAriaLabel:N="Close toast",pauseWhenPageIsHidden:B}=t,[ne,oe]=K.useState(null),[_e,ke]=K.useState(null),[ye,Ae]=K.useState(!1),[Ne,et]=K.useState(!1),[Gt,dr]=K.useState(!1),[Qt,Nr]=K.useState(!1),[wi,Cs]=K.useState(!1),[Ps,Ir]=K.useState(0),[zn,Lr]=K.useState(0),on=K.useRef(y.duration||J||g0),xi=K.useRef(null),Wn=K.useRef(null),Sl=C===0,_l=C+1<=k,At=y.type,Hn=y.dismissible!==!1,bi=y.className||"",El=y.descriptionClassName||"",qn=K.useMemo(()=>P.findIndex(Te=>Te.toastId===y.id)||0,[P,y.id]),As=K.useMemo(()=>{var Te;return(Te=y.closeButton)!=null?Te:z},[y.closeButton,z]),Tl=K.useMemo(()=>y.duration||J||g0,[y.duration,J]),Si=K.useRef(0),hr=K.useRef(0),kl=K.useRef(0),Kn=K.useRef(null),[Fo,Uo]=fe.split("-"),_i=K.useMemo(()=>P.reduce((Te,De,Fe)=>Fe>=qn?Te:Te+De.height,0),[P,qn]),Ei=NP(),Dr=y.invert||x,Gn=At==="loading";hr.current=K.useMemo(()=>qn*ie+_i,[qn,_i]),K.useEffect(()=>{on.current=Tl},[Tl]),K.useEffect(()=>{Ae(!0)},[]),K.useEffect(()=>{let Te=Wn.current;if(Te){let De=Te.getBoundingClientRect().height;return Lr(De),b(Fe=>[{toastId:y.id,height:De,position:y.position},...Fe]),()=>b(Fe=>Fe.filter(Rt=>Rt.toastId!==y.id))}},[b,y.id]),K.useLayoutEffect(()=>{if(!ye)return;let Te=Wn.current,De=Te.style.height;Te.style.height="auto";let Fe=Te.getBoundingClientRect().height;Te.style.height=De,Lr(Fe),b(Rt=>Rt.find(Dt=>Dt.toastId===y.id)?Rt.map(Dt=>Dt.toastId===y.id?{...Dt,height:Fe}:Dt):[{toastId:y.id,height:Fe,position:y.position},...Rt])}
69,[ye,y.title,y.description,b,y.id]);let wn=K.useCallback(()=>{et(!0),Ir(hr.current),b(Te=>Te.filter(De=>De.toastId!==y.id)),setTimeout(()=>{D(y)},KP)},[y,D,b,hr]);K.useEffect(()=>{if(y.promise&&At==="loading"||y.duration===1/0||y.type==="loading")return;let Te;return L||S||B&&Ei?(()=>{if(kl.current<Si.current){let De=new Date().getTime()-Si.current;on.current=on.current-De}kl.current=new Date().getTime()})():on.current!==1/0&&(Si.current=new Date().getTime(),Te=setTimeout(()=>{var De;(De=y.onAutoClose)==null||De.call(y,y),wn()},on.current)),()=>clearTimeout(Te)},[L,S,y,At,B,Ei,wn]),K.useEffect(()=>{y.delete&&wn()},[wn,y.delete]);function Cl(){var Te,De,Fe;return G!=null&&G.loading?K.createElement("div",{className:Pn(W==null?void 0:W.loader,(Te=y==null?void 0:y.classNames)==null?void 0:Te.loader,"sonner-loader"),"data-visible":At==="loading"},G.loading):de?K.createElement("div",{className:Pn(W==null?void 0:W.loader,(De=y==null?void 0:y.classNames)==null?void 0:De.loader,"sonner-loader"),"data-visible":At==="loading"},de):K.createElement(CP,{className:Pn(W==null?void 0:W.loader,(Fe=y==null?void 0:y.classNames)==null?void 0:Fe.loader),visible:At==="loading"})}return K.createElement("li",{tabIndex:0,ref:Wn,className:Pn(Z,bi,W==null?void 0:W.toast,(e=y==null?void 0:y.classNames)==null?void 0:e.toast,W==null?void 0:W.default,W==null?void 0:W[At],(n=y==null?void 0:y.classNames)==null?void 0:n[At]),"data-sonner-toast":"","data-rich-colors":(r=y.richColors)!=null?r:V,"data-styled":!(y.jsx||y.unstyled||_),"data-mounted":ye,"data-promise":!!y.promise,"data-swiped":wi,"data-removed":Ne,"data-visible":_l,"data-y-position":Fo,"data-x-position":Uo,"data-index":C,"data-front":Sl,"data-swiping":Gt,"data-dismissible":Hn,"data-type":At,"data-invert":Dr,"data-swipe-out":Qt,"data-swipe-direction":_e,"data-expanded":!!(L||U&&ye),style:{"--index":C,"--toasts-before":C,"--z-index":A.length-C,"--offset":`${Ne?Ps:hr.current}px`,"--initial-height":U?"auto":`${zn}px`,...q,...y.style},onDragEnd:()=>{dr(!1),oe(null),Kn.current=null},onPointerDown:Te=>{Gn||!Hn||(xi.current=new Date,Ir(hr.current),Te.target.setPointerCapture(Te.pointerId),Te.target.tagName!=="BUTTON"&&(dr(!0),Kn.current={x:Te.clientX,y:Te.clientY}))},onPointerUp:()=>{var Te,De,Fe,Rt;if(Qt||!Hn)return;Kn.current=null;let Dt=Number(((Te=Wn.current)==null?void 0:Te.style.getPropertyValue("--swipe-amount-x").replace("px",""))||0),Mt=Number(((De=Wn.current)==null?void 0:De.style.getPropertyValue("--swipe-amount-y").replace("px",""))||0),xn=new Date().getTime()-((Fe=xi.current)==null?void 0:Fe.getTime()),gt=ne==="x"?Dt:Mt,Qn=Math.abs(gt)/xn;if(Math.abs(gt)>=qP||Qn>.11){Ir(hr.current),(Rt=y.onDismiss)==null||Rt.call(y,y),ke(ne==="x"?Dt>0?"right":"left":Mt>0?"down":"up"),wn(),Nr(!0),Cs(!1);return}dr(!1),oe(null)},onPointerMove:Te=>{var De,Fe,Rt,Dt;if(!Kn.current||!Hn||((De=window.getSelection())==null?void 0:De.toString().length)>0)return;let Mt=Te.clientY-Kn.current.y,xn=Te.clientX-Kn.current.x,gt=(Fe=t.swipeDirections)!=null?Fe:GP(fe);!ne&&(Math.abs(xn)>1||Math.abs(Mt)>
691)&&oe(Math.abs(xn)>Math.abs(Mt)?"x":"y");let Qn={x:0,y:0};ne==="y"?(gt.includes("top")||gt.includes("bottom"))&&(gt.includes("top")&&Mt<0||gt.includes("bottom")&&Mt>0)&&(Qn.y=Mt):ne==="x"&&(gt.includes("left")||gt.includes("right"))&&(gt.includes("left")&&xn<0||gt.includes("right")&&xn>0)&&(Qn.x=xn),(Math.abs(Qn.x)>0||Math.abs(Qn.y)>0)&&Cs(!0),(Rt=Wn.current)==null||Rt.style.setProperty("--swipe-amount-x",`${Qn.x}px`),(Dt=Wn.current)==null||Dt.style.setProperty("--swipe-amount-y",`${Qn.y}px`)}},As&&!y.jsx?K.createElement("button",{"aria-label":N,"data-disabled":Gn,"data-close-button":!0,onClick:Gn||!Hn?()=>{}:()=>{var Te;wn(),(Te=y.onDismiss)==null||Te.call(y,y)},className:Pn(W==null?void 0:W.closeButton,(o=y==null?void 0:y.classNames)==null?void 0:o.closeButton)},(a=G==null?void 0:G.close)!=null?a:OP):null,y.jsx||E.isValidElement(y.title)?y.jsx?y.jsx:typeof y.title=="function"?y.title():y.title:K.createElement(K.Fragment,null,At||y.icon||y.promise?K.createElement("div",{"data-icon":"",className:Pn(W==null?void 0:W.icon,(l=y==null?void 0:y.classNames)==null?void 0:l.icon)},y.promise||y.type==="loading"&&!y.icon?y.icon||Cl():null,y.type!=="loading"?y.icon||(G==null?void 0:G[At])||TP(At):null):null,K.createElement("div",{"data-content":"",className:Pn(W==null?void 0:W.content,(c=y==null?void 0:y.classNames)==null?void 0:c.content)},K.createElement("div",{"data-title":"",className:Pn(W==null?void 0:W.title,(d=y==null?void 0:y.classNames)==null?void 0:d.title)},typeof y.title=="function"?y.title():y.title),y.description?K.createElement("div",{"data-description":"",className:Pn(me,El,W==null?void 0:W.description,(f=y==null?void 0:y.classNames)==null?void 0:f.description)},typeof y.description=="function"?y.description():y.description):null),E.isValidElement(y.cancel)?y.cancel:y.cancel&&Fu(y.cancel)?K.createElement("button",{"data-button":!0,"data-cancel":!0,style:y.cancelButtonStyle||H,onClick:Te=>{var De,Fe;Fu(y.cancel)&&Hn&&((Fe=(De=y.cancel).onClick)==null||Fe.call(De,Te),wn())},className:Pn(W==null?void 0:W.cancelButton,(p=y==null?void 0:y.classNames)==null?void 0:p.cancelButton)},y.cancel.label):null,E.isValidElement(y.action)?y.action:y.action&&Fu(y.action)?K.createElement("button",{"data-button":!0,"data-action":!0,style:y.actionButtonStyle||te,onClick:Te=>{var De,Fe;Fu(y.action)&&((Fe=(De=y.action).onClick)==null||Fe.call(De,Te),!Te.defaultPrevented&&wn())},className:Pn(W==null?void 0:W.actionButton,(g=y==null?void 0:y.classNames)==null?void 0:g.actionButton)},y.action.label):null))};function y0(){if(typeof window>"u"||typeof document>"u")return"ltr";let t=document.documentElement.getAttribute("dir");return t==="auto"||!t?window.getComputedStyle(document.documentElement).direction:t}function YP(t,e){let n={};return[t,e].forEach((r,o)=>{let a=o===1,l=a?"--mobile-offset":"--offset",c=a?zP:BP;function d(f){["top","right","bottom","left"].forEach(p=>{n[`${l}-${p}`]=typeof f=="number"?`${f}px`:f})}typeof r=="number"||typeof r=="string"?d(r):typeof r=="object"?["top","right","bottom","left"].forEach(f=>{r[f]===void 0?n[`${l}-${f}`]=c:n[`${l}-${f}`]=typeof r[f]=="number"?`${r[f]}px`:r[f]}):d(c)}),n}var JP=E.forwardRef(function(t,e){let{invert:n,position:r="bottom-right",hotkey:o=["altKey","KeyT"],expand:a,closeButton:l,className:c,offset:d,mobileOffset:f,theme:p="light",richColors:g,duration:x,style:y,visibleToasts:_=VP,toastOptions:S,dir:b=y0(),gap:k=HP,loadingIcon:P,icons:C,containerAriaLabel:A="Notifications",pauseWhenPageIsHidden:L}=t,[D,V]=K.useState([]),z=K.useMemo(()=>Array.from(new Set([r].concat(D.filter(B=>B.position).map(B=>B.position)))),[D,r]),[q,H]=K.useState([]),[te,Z]=K.useState(!1),[me,J]=K.useState(!1),[fe,ie]=K.useState(p!=="system"?p:typeof window<"u"&&window.matchMedia&&window.matchMedia("(prefers-color-scheme: dark)").matches?"dark":"light"),de=K.useRef(null),U=o.join("+").replace(/Key/g,"").replace(/Digit/g,""),W=K.useRef(null),G=K.useRef(!1),N=K.useCallback(B=>{V(ne=>{var oe;return(oe=ne.find(_e=>_e.id===B.id))!=null&&oe.delete||Ht.dismiss(B.id),ne.filter(({id:_e})=>_e!==B.id)})},[]);return K.useEffect(()=>Ht.subscribe(B=>{if(B.dismiss){V(ne=>ne.map(oe=>oe.id===B.id?{...oe,delete:!0}:oe));return}setTimeout(()=>{Sb.flushSync(()=>{V(ne=>{let oe=ne.findIndex(_e=>_e.id===B.id);return oe!==-1?[...ne.slice(0,oe),{...ne[oe],...B},...ne.slice(oe+1)]:[B,...ne]})})})}),[]),K.useEffect(()=>{if(p!=="system"){ie(p);return}if(p==="system"&&(window.matchMedia&&window.matchMedia("(prefers-color-scheme: dark)").matches?ie("dark"):ie("light")),typeof window>"u")return;let B=window.matchMedia("(prefers-color-scheme: dark)");try{B.addEventListener("change",({matches:ne})=>{ie(ne?"dark":"light")})}catch{B.addListener(({matches:oe})=>{try{ie(oe?"dark":"light")}catch(_e){console.error(_e)}})}},[p]),K.useEffect(()=>{D.length<=1&&Z(!1)},[D]),K.useEffect(()=>{let B=ne=>{var oe,_e;o.every(ke=>ne[ke]||ne.code===ke)&&(Z(!0),(oe=de.current)==null||oe.focus()),ne.code==="Escape"&&(document.activeElement===de.current||(_e=de.current)!=null&&_e.contains(document.activeElement))&&Z(!1)};return document.addEventListener("keydown",B),()=>document.removeEventListener("keydown",B)},[o]),K.useEffect(()=>{if(de.current)return()=>{W.current&&(W.current.focus({preventScroll:!0}),W.current=null,G.current=!1)}},[de.current]),K.createElement("section",{ref:e,"aria-label":`${A} ${U}`,tabIndex:-1,"aria-live":"polite","aria-relevant":"additions text","aria-atomic":"false",suppressHydrationWarning:!0},z.map((B,ne)=>{var oe;let[_e,ke]=B.split("-");return D.length?K.createElement("ol",{key:B,dir:b==="auto"?y0():b,tabIndex:-1,ref:de,className:c,"data-sonner-toaster":!0,"data-theme":fe,"data-y-position":_e,"data-lifted":te&&D.length>1&&!a,"data-x-position":ke,style:{"--front-toast-height":`${((oe=q[0])==null?void 0:oe.height)||0}px`,"--width":`${WP}px`,"--gap":`${k}
vendor: 15,349 bytes, line 69
69px`,...y,...YP(d,f)},onBlur:ye=>{G.current&&!ye.currentTarget.contains(ye.relatedTarget)&&(G.current=!1,W.current&&(W.current.focus({preventScroll:!0}),W.current=null))},onFocus:ye=>{ye.target instanceof HTMLElement&&ye.target.dataset.dismissible==="false"||G.current||(G.current=!0,W.current=ye.relatedTarget)},onMouseEnter:()=>Z(!0),onMouseMove:()=>Z(!0),onMouseLeave:()=>{me||Z(!1)},onDragEnd:()=>Z(!1),onPointerDown:ye=>{ye.target instanceof HTMLElement&&ye.target.dataset.dismissible==="false"||J(!0)},onPointerUp:()=>J(!1)},D.filter(ye=>!ye.position&&ne===0||ye.position===B).map((ye,Ae)=>{var Ne,et;return K.createElement(QP,{key:ye.id,icons:C,index:Ae,toast:ye,defaultRichColors:g,duration:(Ne=S==null?void 0:S.duration)!=null?Ne:x,className:S==null?void 0:S.className,descriptionClassName:S==null?void 0:S.descriptionClassName,invert:n,visibleToasts:_,closeButton:(et=S==null?void 0:S.closeButton)!=null?et:l,interacting:me,position:B,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,removeToast:N,toasts:D.filter(Gt=>Gt.position==ye.position),heights:q.filter(Gt=>Gt.position==ye.position),setHeights:H,expandByDefault:a,gap:k,loadingIcon:P,expanded:te,pauseWhenPageIsHidden:L,swipeDirections:t.swipeDirections})})):null}))});const XP=({...t})=>{const{theme:e="system"}=EP();return v.jsx(JP,{theme:e,className:"toaster group",toastOptions:{classNames:{toast:"group toast group-[.toaster]:bg-background group-[.toaster]:text-foreground group-[.toaster]:border-border group-[.toaster]:shadow-lg",description:"group-[.toast]:text-muted-foreground",actionButton:"group-[.toast]:bg-primary group-[.toast]:text-primary-foreground",cancelButton:"group-[.toast]:bg-muted group-[.toast]:text-muted-foreground"}},...t})},ZP=1,eA=1e6;let Jh=0;function tA(){return Jh=(Jh+1)%Number.MAX_SAFE_INTEGER,Jh.toString()}const Xh=new Map,v0=t=>{if(Xh.has(t))return;const e=setTimeout(()=>{Xh.delete(t),Na({type:"REMOVE_TOAST",toastId:t})},eA);Xh.set(t,e)},nA=(t,e)=>{switch(e.type){case"ADD_TOAST":return{...t,toasts:[e.toast,...t.toasts].slice(0,ZP)};case"UPDATE_TOAST":return{...t,toasts:t.toasts.map(n=>n.id===e.toast.id?{...n,...e.toast}:n)};case"DISMISS_TOAST":{const{toastId:n}=e;return n?v0(n):t.toasts.forEach(r=>{v0(r.id)}),{...t,toasts:t.toasts.map(r=>r.id===n||n===void 0?{...r,open:!1}:r)}}case"REMOVE_TOAST":return e.toastId===void 0?{...t,toasts:[]}:{...t,toasts:t.toasts.filter(n=>n.id!==e.toastId)}}},nc=[];let rc={toasts:[]};function Na(t){rc=nA(rc,t),nc.forEach(e=>{e(rc)})}function rA({...t}){const e=tA(),n=o=>Na({type:"UPDATE_TOAST",toast:{...o,id:e}}),r=()=>Na({type:"DISMISS_TOAST",toastId:e});return Na({type:"ADD_TOAST",toast:{...t,id:e,open:!0,onOpenChange:o=>{o||r()}}}),{id:e,dismiss:r,update:n}}function sA(){const[t,e]=E.useState(rc);return E.useEffect(()=>(nc.push(e),()=>{const n=nc.indexOf(e);n>-1&&nc.splice(n,1)}),[t]),{...t,toast:rA,dismiss:n=>Na({type:"DISMISS_TOAST",toastId:n})}}function dt(t,e,{checkForDefaultPrevented:n=!0}={}){return function(o){if(t==null||t(o),n===!1||!o.defaultPrevented)return e==null?void 0:e(o)}}function w0(t,e){if(typeof t=="function")return t(e);t!=null&&(t.current=e)}function Lc(...t){return e=>{let n=!1;const r=t.map(o=>{const a=w0(o,e);return!n&&typeof a=="function"&&(n=!0),a});if(n)return()=>{for(let o=0;o<r.length;o++){const a=r[o];typeof a=="function"?a():w0(t[o],null)}}}}function Un(...t){return E.useCallback(Lc(...t),t)}function r$(t,e){const n=E.createContext(e),r=a=>{const{children:l,...c}=a,d=E.useMemo(()=>c,Object.values(c));return v.jsx(n.Provider,{value:d,children:l})};r.displayName=t+"Provider";function o(a){const l=E.useContext(n);if(l)return l;if(e!==void 0)return e;throw new Error(`\`${a}\` must be used within \`${t}\``)}return[r,o]}function Dc(t,e=[]){let n=[];function r(a,l){const c=E.createContext(l),d=n.length;n=[...n,l];const f=g=>{var k;const{scope:x,children:y,..._}=g,S=((k=x==null?void 0:x[t])==null?void 0:k[d])||c,b=E.useMemo(()=>_,Object.values(_));return v.jsx(S.Provider,{value:b,children:y})};f.displayName=a+"Provider";function p(g,x){var S;const y=((S=x==null?void 0:x[t])==null?void 0:S[d])||c,_=E.useContext(y);if(_)return _;if(l!==void 0)return l;throw new Error(`\`${g}\` must be used within \`${a}\``)}return[f,p]}const o=()=>{const a=n.map(l=>E.createContext(l));return function(c){const d=(c==null?void 0:c[t])||a;return E.useMemo(()=>({[`__scope${t}`]:{...c,[t]:d}}),[c,d])}};return o.scopeName=t,[r,iA(o,...e)]}function iA(...t){const e=t[0];if(t.length===1)return e;const n=()=>{const r=t.map(o=>({useScope:o(),scopeName:o.scopeName}));return function(a){const l=r.reduce((c,{useScope:d,scopeName:f})=>{const g=d(a)[`__scope${f}`];return{...c,...g}},{});return E.useMemo(()=>({[`__scope${e.scopeName}`]:l}),[l])}};return n.scopeName=e.scopeName,n}function x0(t){const e=oA(t),n=E.forwardRef((r,o)=>{const{children:a,...l}=r,c=E.Children.toArray(a),d=c.find(lA);if(d){const f=d.props.children,p=c.map(g=>g===d?E.Children.count(f)>1?E.Children.only(null):E.isValidElement(f)?f.props.children:null:g);return v.jsx(e,{...l,ref:o,children:E.isValidElement(f)?E.cloneElement(f,void 0,p):null})}return v.jsx(e,{...l,ref:o,children:a})});return n.displayName=`${t}.Slot`,n}function oA(t){const e=E.forwardRef((n,r)=>{const{children:o,...a}=n;if(E.isValidElement(o)){const l=cA(o),c=uA(a,o.props);return o.type!==E.Fragment&&(c.ref=r?Lc(r,l):l),E.cloneElement(o,c)}return E.Children.count(o)>1?E.Children.only(null):null});return e.displayName=`${t}.SlotClone`,e}var aA=Symbol("radix.slottable");function lA(t){return E.isValidElement(t)&&typeof t.type=="function"&&"__radixId"in t.type&&t.type.__radixId===aA}function uA(t,e){const n={...e};for(const r in e){const o=t[r],a=e[r];/^on[A-Z]/.test(r)?o&&a?n[r]=(...c)=>{const d=a(...c);return o(...c),d}:o&&(n[r]=o):r==="style"?n[r]={...o,...a}:r==="className"&&(n[r]=[o,a].filter(Boolean).join(" "))}return{...t,...n}}function cA(t){var r,o;let e=(r=Object.getOwnPropertyDescriptor(t.props,"ref"))==null?void 0:r.get,n=e&&"isReactWarning"in e&&e.isReactWarning;return n?t.ref:(e=(o=Object.getOwnPropertyDescriptor(t,"ref"))==null?void 0:o.get,n=e&&"isReactWarning"in e&&e.isReactWarning,n?t.props.ref:t.props.ref||t.ref)}function dA(t){const e=t+"CollectionProvider",[n,r]=Dc(e),[o,a]=n(e,{collectionRef:{current:null},itemMap:new Map}),l=S=>{const{scope:b,children:k}=S,P=K.useRef(null),C=K.useRef(new Map).current;return v.jsx(o,{scope:b,itemMap:C,collectionRef:P,children:k})};l.displayName=e;const c=t+"CollectionSlot",d=x0(c),f=K.forwardRef((S,b)=>{const{scope:k,children:P}=S,C=a(c,k),A=Un(b,C.collectionRef);return v.jsx(d,{ref:A,children:P})});f.displayName=c;const p=t+"CollectionItemSlot",g="data-radix-collection-item",x=x0(p),y=K.forwardRef((S,b)=>{const{scope:k,children:P,...C}=S,A=K.useRef(null),L=Un(b,A),D=a(p,k);return K.useEffect(()=>(D.itemMap.set(A,{ref:A,...C}),()=>void D.itemMap.delete(A))),v.jsx(x,{[g]:"",ref:L,children:P})});y.displayName=p;function _(S){const b=a(t+"CollectionConsumer",S);return K.useCallback(()=>{const P=b.collectionRef.current;if(!P)return[];const C=Array.from(P.querySelectorAll(`[${g}]`));return Array.from(b.itemMap.values()).sort((D,V)=>C.indexOf(D.ref.current)-C.indexOf(V.ref.current))},[b.collectionRef,b.itemMap])}return[{Provider:l,Slot:f,ItemSlot:y},_,r]}function hA(t){const e=fA(t),n=E.forwardRef((r,o)=>{const{children:a,...l}=r,c=E.Children.toArray(a),d=c.find(mA);if(d){const f=d.props.children,p=c.map(g=>g===d?E.Children.count(f)>1?E.Children.only(null):E.isValidElement(f)?f.props.children:null:g);return v.jsx(e,{...l,ref:o,children:E.isValidElement(f)?E.cloneElement(f,void 0,p):null})}return v.jsx(e,{...l,ref:o,children:a})});return n.displayName=`${t}.Slot`,n}function fA(t){const e=E.forwardRef((n,r)=>{const{children:o,...a}=n;if(E.isValidElement(o)){const l=yA(o),c=gA(a,o.props);return o.type!==E.Fragment&&(c.ref=r?Lc(r,l):l),E.cloneElement(o,c)}return E.Children.count(o)>1?E.Children.only(null):null});return e.displayName=`${t}.SlotClone`,e}var pA=Symbol("radix.slottable");function mA(t){return E.isValidElement(t)&&typeof t.type=="function"&&"__radixId"in t.type&&t.type.__radixId===pA}function gA(t,e){const n={...e};for(const r in e){const o=t[r],a=e[r];/^on[A-Z]/.test(r)?o&&a?n[r]=(...c)=>{const d=a(...c);return o(...c),d}:o&&(n[r]=o):r==="style"?n[r]={...o,...a}:r==="className"&&(n[r]=[o,a].filter(Boolean).join(" "))}return{...t,...n}}function yA(t){var r,o;let e=(r=Object.getOwnPropertyDescriptor(t.props,"ref"))==null?void 0:r.get,n=e&&"isReactWarning"in e&&e.isReactWarning;return n?t.ref:(e=(o=Object.getOwnPropertyDescriptor(t,"ref"))==null?void 0:o.get,n=e&&"isReactWarning"in e&&e.isReactWarning,n?t.props.ref:t.props.ref||t.ref)}var vA=["a","button","div","form","h2","h3","img","input","label","li","nav","ol","p","select","span","svg","ul"],Kt=vA.reduce((t,e)=>{const n=hA(`Primitive.${e}`),r=E.forwardRef((o,a)=>{const{asChild:l,...c}=o,d=l?n:e;return typeof window<"u"&&(window[Symbol.for("radix-ui")]=!0),v.jsx(d,{...c,ref:a})});return r.displayName=`Primitive.${e}`,{...t,[e]:r}},{});function Lb(t,e){t&&Nc.flushSync(()=>t.dispatchEvent(e))}function xs(t){const e=E.useRef(t);return E.useEffect(()=>{e.current=t}),E.useMemo(()=>(...n)=>{var r;return(r=e.current)==null?void 0:r.call(e,...n)},[])}function wA(t,e=globalThis==null?void 0:globalThis.document){const n=xs(t);E.useEffect(()=>{const r=o=>{o.key==="Escape"&&n(o)};return e.addEventListener("keydown",r,{capture:!0}),()=>e.removeEventListener("keydown",r,{capture:!0})},[n,e])}var xA="DismissableLayer",Xf="dismissableLayer.update",bA="dismissableLayer.pointerDownOutside",SA="dismissableLayer.focusOutside",b0,Db=E.createContext({layers:new Set,layersWithOutsidePointerEventsDisabled:new Set,branches:new Set}),tm=E.forwardRef((t,e)=>{const{disableOutsidePointerEvents:n=!1,onEscapeKeyDown:r,onPointerDownOutside:o,onFocusOutside:a,onInteractOutside:l,onDismiss:c,...d}=t,f=E.useContext(Db),[p,g]=E.useState(null),x=(p==null?void 0:p.ownerDocument)??(globalThis==null?void 0:globalThis.document),[,y]=E.useState({}),_=Un(e,V=>g(V)),S=Array.from(f.layers),[b]=[...f.layersWithOutsidePointerEventsDisabled].slice(-1),k=S.indexOf(b),P=p?S.indexOf(p):-1,C=f.layersWithOutsidePointerEventsDisabled.size>0,A=P>=k,L=EA(V=>{const z=V.target,q=[...f.branches].some(H=>H.contains(z));!A||q||(o==null||o(V),l==null||l(V),V.defaultPrevented||c==null||c())},x),D=TA(V=>{const z=V.target;[...f.branches].some(H=>H.contains(z))||(a==null||a(V),l==null||l(V),V.defaultPrevented||c==null||c())},x);return wA(V=>{P===f.layers.size-1&&(r==null||r(V),!V.defaultPrevented&&c&&(V.preventDefault(),c()))},x),E.useEffect(()=>{if(p)return n&&(f.layersWithOutsidePointerEventsDisabled.size===0&&(b0=x.body.style.pointerEvents,x.body.style.pointerEvents="none"),f.layersWithOutsidePointerEventsDisabled.add(p)),f.layers.add(p),S0(),()=>{n&&f.layersWithOutsidePointerEventsDisabled.size===1&&(x.body.style.pointerEvents=b0)}},[p,x,n,f]),E.useEffect(()=>()=>{p&&(f.layers.delete(p),f.layersWithOutsidePointerEventsDisabled.delete(p),S0())},[p,f]),E.useEffect(()=>{const V=()=>y({});return document.addEventListener(Xf,V),()=>document.removeEventListener(Xf,V)},[]),v.jsx(Kt.div,{...d,ref:_,style:{pointerEvents:C?A?"auto":"none":void 0,...t.style},onFocusCapture:dt(t.onFocusCapture,D.onFocusCapture),onBlurCapture:dt(t.onBlurCapture,D.onBlurCapture),onPointerDownCapture:dt(t.onPointerDownCapture,L.onPointerDownCapture)})});tm.displayName=xA;var _A="DismissableLayerBranch",Mb=E.forwardRef((t,e)=>{const n=E.useContext(Db),r=E.useRef(null),o=Un(e,r);return E.useEffect(()=>{const a=r.current;if(a)return n.branches.add(a),()=>{n.branches.delete(a)}},[n.branches]),v.jsx(Kt.div,{...t,ref:o})});Mb.displayName=_A;function EA(t,e=globalThis==null?void 0:globalThis.document){const n=xs(t),r=E.useRef(!1),o=E.useRef(()=>{});return E.useEffect(()=>{const a=c=>{if(c.target&&!r.current){let d=function(){$b(bA,n,f,{discrete:!0})};const f={originalEvent:c};c.pointerType==="touch"?(e.removeEventListener("click",o.current),o.current=d,e.addEventListener("click",o.current,{once:!0})):d()}else e.removeEventListener("click",o.current);r.current=!1},l=window.setTimeout(()=>{e.addEventListener("pointerdown",a)},0);return()=>{window.clearTimeout(l),e.removeEventListener("pointerdown",a),e.removeEventListener("click",o.current)}},[e,n]),{onPointerDownCapture:()=>r.current=!0}}function TA(t,e=globalThis==null?void 0:globalThis.document){const n=xs(t),r=E.useRef(!1);return E.useEffect(()=>{const o=a=>{a.target&&!r.current&&$b(SA,n,{originalEvent:a},{discrete:!1})};return e.addEventListener("focusin",o),()=>e.removeEventListener("focusin",o)},[e,n]),{onFocusCapture:()=>r.current=!0,onBlurCapture:()=>r.current=!1}}function S0(){const t=new CustomEvent(Xf);document.dispatchEvent(t)}function $b(t,e,n,{discrete:r}){const o=n.originalEvent.target,a=new CustomEvent(t,{bubbles:!1,cancelable:!0,detail:n});e&&o.addEventListener(t,e,{once:!0}),r?Lb(o,a):o.dispatchEvent(a)}var kA=tm,CA=Mb,Pr=globalThis!=null&&globalThis.document?E.useLayoutEffect:()=>{},PA="Portal",Fb=E.forwardRef((t,e)=>{var c;const{container:n,...r}=t,[o,a]=E.useState(!1);Pr(()=>a(!0),[]);const l=n||o&&((c=globalThis==null?void 0:globalThis.document)==null?void 0:c.body);return l?Sb.createPortal(v.jsx(Kt.div,{...r,ref:e}),l):null});Fb.displayName=PA;function AA(t,e){return E.useReducer((n,r)=>e[n][r]??n,t)}var nm=t=>{const{present:e,children:n}=t,r=RA(e),o=typeof n=="function"?n({present:r.isPresent}):E.Children.only(n),a=Un(r.ref,jA(o));return typeof n=="function"||r.isPresent?E.cloneElement(o,{ref:a}):null};nm.displayName="Presence";function RA(t){const[e,n]=E.useState(),r=E.useRef(null),o=E.useRef(t),a=E.useRef("none"),l=t?"mounted":"unmounted",[c,d]=AA(l,{mounted:{UNMOUNT:"unmounted",ANIMATION_OUT:"unmountSuspended"},unmountSuspended:{MOUNT:"mounted",ANIMATION_END:"unmounted"},unmounted:{MOUNT:"mounted"}});return E.useEffect(()=>{const f=Uu(r.current);a.current=c==="mounted"?f:"none"},[c]),Pr(()=>{const f=r.current,p=o.current;if(p!==t){const x=a.current,y=Uu(f);t?d("MOUNT"):y==="none"||(f==null?void 0:f.display)==="none"?d("UNMOUNT"):d(p&&x!==y?"ANIMATION_OUT":"UNMOUNT"),o.current=t}},[t,d]),Pr(()=>{if(e){let f;const p=e.ownerDocument.defaultView??window,g=y=>{const S=Uu(r.current).includes(CSS.escape(y.animationName));if(y.target===e&&S&&(d("ANIMATION_END"),!o.current)){const b=e.style.animationFillMode;e.style.animationFillMode="forwards",f=p.setTimeout(()=>{e.style.animationFillMode==="forwards"&&(e.style.animationFillMode=b)})}},x=y=>{y.target===e&&(a.current=Uu(r.current))};return e.addEventListener("animationstart",x),e.addEventListener("animationcancel",g),e.addEventListener("animationend",g),()=>{p.clearTimeout(f),e.removeEventListener("animationstart",x),e.removeEventListener("animationcancel",g),e.removeEventListener("animationend",g)}}else d("ANIMATION_END")},[e,d]),{isPresent:["mounted","unmountSuspended"].includes(c),ref:E.useCallback(f=>{r.current=f?getComputedStyle(f):null,n(f)},[])}}function Uu(t){return(t==null?void 0:t.animationName)||"none"}function jA(t){var r,o;let e=(r=Object.getOwnPropertyDescriptor(t.props,"ref"))==null?void 0:r.get,n=e&&"isReactWarning"in e&&e.
69isReactWarning;return n?t.ref:(e=(o=Object.getOwnPropertyDescriptor(t,"ref"))==null?void 0:o.get,n=e&&"isReactWarning"in e&&e.isReactWarning,n?t.props.ref:t.props.ref||t.ref)}var OA=jc[" useInsertionEffect ".trim().toString()]||Pr;function Ub({prop:t,defaultProp:e,onChange:n=()=>{},caller:r}){const[o,a,l]=NA({defaultProp:e,onChange:n}),c=t!==void 0,d=c?t:o;{const p=E.useRef(t!==void 0);E.useEffect(()=>{const g=p.current;g!==c&&console.warn(`${r} is changing from ${g?"controlled":"uncontrolled"} to ${c?"controlled":"uncontrolled"}. Components should not switch from controlled to uncontrolled (or vice versa). Decide between using a controlled or uncontrolled value for the lifetime of the component.`),p.current=c},[c,r])}const f=E.useCallback(p=>{var g;if(c){const x=IA(p)?p(t):p;x!==t&&((g=l.current)==null||g.call(l,x))}else a(p)},[c,t,a,l]);return[d,f]}function NA({defaultProp:t,onChange:e}){const[n,r]=E.useState(t),o=E.useRef(n),a=E.useRef(e);return OA(()=>{a.current=e},[e]),E.useEffect(()=>{var l;o.current!==n&&((l=a.current)==null||l.call(a,n),o.current=n)},[n,o]),[n,r,a]}function IA(t){return typeof t=="function"}var LA=Object.freeze({position:"absolute",border:0,width:1,height:1,padding:0,margin:-1,overflow:"hidden",clip:"rect(0, 0, 0, 0)",whiteSpace:"nowrap",wordWrap:"normal"}),DA="VisuallyHidden",Mc=E.forwardRef((t,e)=>v.jsx(Kt.span,{...t,ref:e,style:{...LA,...t.style}}));Mc.displayName=DA;var MA=Mc,rm="ToastProvider",[sm,$A,FA]=dA("Toast"),[Vb]=Dc("Toast",[FA]),[UA,$c]=Vb(rm),Bb=t=>{const{__scopeToast:e,label:n="Notification",duration:r=5e3,swipeDirection:o="right",swipeThreshold:a=50,children:l}=t,[c,d]=E.useState(null),[f,p]=E.useState(0),g=E.useRef(!1),x=E.useRef(!1);return n.trim()||console.error(`Invalid prop \`label\` supplied to \`${rm}\`. Expected non-empty \`string\`.`),v.jsx(sm.Provider,{scope:e,children:v.jsx(UA,{scope:e,label:n,duration:r,swipeDirection:o,swipeThreshold:a,toastCount:f,viewport:c,onViewportChange:d,onToastAdd:E.useCallback(()=>p(y=>y+1),[]),onToastRemove:E.useCallback(()=>p(y=>y-1),[]),isFocusedToastEscapeKeyDownRef:g,isClosePausedRef:x,children:l})})};Bb.displayName=rm;var zb="ToastViewport",VA=["F8"],Zf="toast.viewportPause",ep="toast.viewportResume",Wb=E.forwardRef((t,e)=>{const{__scopeToast:n,hotkey:r=VA,label:o="Notifications ({hotkey})",...a}=t,l=$c(zb,n),c=$A(n),d=E.useRef(null),f=E.useRef(null),p=E.useRef(null),g=E.useRef(null),x=Un(e,g,l.onViewportChange),y=r.join("+").replace(/Key/g,"").replace(/Digit/g,""),_=l.toastCount>0;E.useEffect(()=>{const b=k=>{var C;r.length!==0&&r.every(A=>k[A]||k.code===A)&&((C=g.current)==null||C.focus())};return document.addEventListener("keydown",b),()=>document.removeEventListener("keydown",b)},[r]),E.useEffect(()=>{const b=d.current,k=g.current;if(_&&b&&k){const P=()=>{if(!l.isClosePausedRef.current){const D=new CustomEvent(Zf);k.dispatchEvent(D),l.isClosePausedRef.current=!0}},C=()=>{if(l.isClosePausedRef.current){const D=new CustomEvent(ep);k.dispatchEvent(D),l.isClosePausedRef.current=!1}},A=D=>{!b.contains(D.relatedTarget)&&C()},L=()=>{b.contains(document.activeElement)||C()};return b.addEventListener("focusin",P),b.addEventListener("focusout",A),b.addEventListener("pointermove",P),b.addEventListener("pointerleave",L),window.addEventListener("blur",P),window.addEventListener("focus",C),()=>{b.removeEventListener("focusin",P),b.removeEventListener("focusout",A),b.removeEventListener("pointermove",P),b.removeEventListener("pointerleave",L),window.removeEventListener("blur",P),window.removeEventListener("focus",C)}}},[_,l.isClosePausedRef]);const S=E.useCallback(({tabbingDirection:b})=>{const P=c().map(C=>{const A=C.ref.current,L=[A,...eR(A)];return b==="forwards"?L:L.reverse()});return(b==="forwards"?P.reverse():P).flat()},[c]);return E.useEffect(()=>{const b=g.current;if(b){const k=P=>{var L,D,V;const C=P.altKey||P.ctrlKey||P.metaKey;if(P.key==="Tab"&&!C){const z=document.activeElement,q=P.shiftKey;if(P.target===b&&q){(L=f.current)==null||L.focus();return}const Z=S({tabbingDirection:q?"backwards":"forwards"}),me=Z.findIndex(J=>J===z);Zh(Z.slice(me+1))?P.preventDefault():q?(D=f.current)==null||D.focus():(V=p.current)==null||V.focus()}};return b.addEventListener("keydown",k),()=>b.removeEventListener("keydown",k)}},[c,S]),v.jsxs(CA,{ref:d,role:"region","aria-label":o.replace("{hotkey}",y),tabIndex:-1,style:{pointerEvents:_?void 0:"none"},children:[_&&v.jsx(tp,{ref:f,onFocusFromOutsideViewport:()=>{const b=S({tabbingDirection:"forwards"});Zh(b)}}),v.jsx(sm.Slot,{scope:n,children:v.jsx(Kt.ol,{tabIndex:-1,...a,ref:x})}),_&&v.jsx(tp,{ref:p,onFocusFromOutsideViewport:()=>{const b=S({tabbingDirection:"backwards"});Zh(b)}})]})});Wb.displayName=zb;var Hb="ToastFocusProxy",tp=E.forwardRef((t,e)=>{const{__scopeToast:n,onFocusFromOutsideViewport:r,...o}=t,a=$c(Hb,n);return v.jsx(Mc,{tabIndex:0,...o,ref:e,style:{position:"fixed"},onFocus:l=>{var f;const c=l.relatedTarget;!((f=a.viewport)!=null&&f.contains(c))&&r()}})});tp.displayName=Hb;var pl="Toast",BA="toast.swipeStart",zA="toast.swipeMove",WA="toast.swipeCancel",HA="toast.swipeEnd",qb=E.forwardRef((t,e)=>{const{forceMount:n,open:r,defaultOpen:o,onOpenChange:a,...l}=t,[c,d]=Ub({prop:r,defaultProp:o??!0,onChange:a,caller:pl});return v.jsx(nm,{present:n||c,children:v.jsx(GA,{open:c,...l,ref:e,onClose:()=>d(!1),onPause:xs(t.onPause),onResume:xs(t.onResume),onSwipeStart:dt(t.onSwipeStart,f=>{f.currentTarget.setAttribute("data-swipe","start")}),onSwipeMove:dt(t.onSwipeMove,f=>{const{x:p,y:g}=f.detail.delta;f.currentTarget.setAttribute("data-swipe","move"),f.currentTarget.style.setProperty("--radix-toast-swipe-move-x",`${p}px`),f.currentTarget.style.setProperty("--radix-toast-swipe-move-y",`${g}px`)}),onSwipeCancel:dt(t.onSwipeCancel,f=>{f.currentTarget.setAttribute("data-swipe","cancel"),f.currentTarget.style.removeProperty("--radix-toast-swipe-move-x"),f.currentTarget.style.removeProperty("--radix-toast-swipe-move-y"),f.currentTarget.style.removeProperty("--radix-toast-swipe-end-x"),f.currentTarget.style.removeProperty("--radix-toast-swipe-end-y")}),onSwipeEnd:dt(t.onSwipeEnd,f=>{const{x:p,y:g}=f.detail.delta;f.currentTarget.setAttribute("data-swipe","end"),f.currentTarget.style.removeProperty("--radix-toast-swipe-move-x"),f.currentTarget.style.removeProperty("--radix-toast-swipe-move-y"),f.currentTarget.style.setProperty("--radix-toast-swipe-end-x",`${p}px`),f.currentTarget.style.setProperty("--radix-toast-swipe-end-y",`${g}px`),d(!1)})})})});qb.displayName=pl;var[qA,KA]=Vb(pl,{onClose(){}}),GA=E.forwardRef((t,e)=>{const{__scopeToast:n,type:r="foreground",duration:o,open:a,onClose:l,onEscapeKeyDown:c,onPause:d,onResume:f,onSwipeStart:p,onSwipeMove:g,onSwipeCancel:x,onSwipeEnd:y,..._}=t,S=$c(pl,n),[b,k]=E.useState(null),P=Un(e,J=>k(J)),C=E.useRef(null),A=E.useRef(null),L=o||S.duration,D=E.useRef(0),V=E.useRef(L),z=E.useRef(0),{onToastAdd:q,onToastRemove:H}=S,te=xs(()=>{var fe;(b==null?void 0:b.contains(document.activeElement))&&((fe=S.viewport)==null||fe.focus()),l()}),Z=E.useCallback(J=>
69{!J||J===1/0||(window.clearTimeout(z.current),D.current=new Date().getTime(),z.current=window.setTimeout(te,J))},[te]);E.useEffect(()=>{const J=S.viewport;if(J){const fe=()=>{Z(V.current),f==null||f()},ie=()=>{const de=new Date().getTime()-D.current;V.current=V.current-de,window.clearTimeout(z.current),d==null||d()};return J.addEventListener(Zf,ie),J.addEventListener(ep,fe),()=>{J.removeEventListener(Zf,ie),J.removeEventListener(ep,fe)}}},[S.viewport,L,d,f,Z]),E.useEffect(()=>{a&&!S.isClosePausedRef.current&&Z(L)},[a,L,S.isClosePausedRef,Z]),E.useEffect(()=>(q(),()=>H()),[q,H]);const me=E.useMemo(()=>b?Zb(b):null,[b]);return S.viewport?v.jsxs(v.Fragment,{children:[me&&v.jsx(QA,{__scopeToast:n,role:"status","aria-live":r==="foreground"?"assertive":"polite",children:me}),v.jsx(qA,{scope:n,onClose:te,children:Nc.createPortal(v.jsx(sm.ItemSlot,{scope:n,children:v.jsx(kA,{asChild:!0,onEscapeKeyDown:dt(c,()=>{S.isFocusedToastEscapeKeyDownRef.current||te(),S.isFocusedToastEscapeKeyDownRef.current=!1}),children:v.jsx(Kt.li,{tabIndex:0,"data-state":a?"open":"closed","data-swipe-direction":S.swipeDirection,..._,ref:P,style:{userSelect:"none",touchAction:"none",...t.style},onKeyDown:dt(t.onKeyDown,J=>{J.key==="Escape"&&(c==null||c(J.nativeEvent),J.nativeEvent.defaultPrevented||(S.isFocusedToastEscapeKeyDownRef.current=!0,te()))}),onPointerDown:dt(t.onPointerDown,J=>{J.button===0&&(C.current={x:J.clientX,y:J.clientY})}),onPointerMove:dt(t.onPointerMove,J=>{if(!C.current)return;const fe=J.clientX-C.current.x,ie=J.clientY-C.current.y,de=!!A.current,U=["left","right"].includes(S.swipeDirection),W=["left","up"].includes(S.swipeDirection)?Math.min:Math.max,G=U?W(0,fe):0,N=U?0:W(0,ie),B=J.pointerType==="touch"?10:2,ne={x:G,y:N},oe={originalEvent:J,delta:ne};de?(A.current=ne,Vu(zA,g,oe,{discrete:!1})):_0(ne,S.swipeDirection,B)?(A.current=ne,Vu(BA,p,oe,{discrete:!1}),J.target.setPointerCapture(J.pointerId)):(Math.abs(fe)>B||Math.abs(ie)>B)&&(C.current=null)}),onPointerUp:dt(t.onPointerUp,J=>{const fe=A.current,ie=J.target;if(ie.hasPointerCapture(J.pointerId)&&ie.releasePointerCapture(J.pointerId),A.current=null,C.current=null,fe){const de=J.currentTarget,U={originalEvent:J,delta:fe};_0(fe,S.swipeDirection,S.swipeThreshold)?Vu(HA,y,U,{discrete:!0}):Vu(WA,x,U,{discrete:!0}),de.addEventListener("click",W=>W.preventDefault(),{once:!0})}})})})}),S.viewport)})]}):null}),QA=t=>{const{__scopeToast:e,children:n,...r}=t,o=$c(pl,e),[a,l]=E.useState(!1),[c,d]=E.useState(!1);return XA(()=>l(!0)),E.useEffect(()=>{const f=window.setTimeout(()=>d(!0),1e3);return()=>window.clearTimeout(f)},[]),c?null:v.jsx(Fb,{asChild:!0,children:v.jsx(Mc,{...r,children:a&&v.jsxs(v.Fragment,{children:[o.label," ",n]})})})},YA="ToastTitle",Kb=E.forwardRef((t,e)=>{const{__scopeToast:n,...r}=t;return v.jsx(Kt.div,{...r,ref:e})});Kb.displayName=YA;var JA="ToastDescription",Gb=E.forwardRef((t,e)=>{const{__scopeToast:n,...r}=t;return v.jsx(Kt.div,{...r,ref:e})});Gb.displayName=JA;var Qb="ToastAction",Yb=E.forwardRef((t,e)=>{const{altText:n,...r}=t;return n.trim()?v.jsx(Xb,{altText:n,asChild:!0,children:v.jsx(im,{...r,ref:e})}):(console.error(`Invalid prop \`altText\` supplied to \`${Qb}\`. Expected non-empty \`string\`.`),null)});Yb.displayName=Qb;var Jb="ToastClose",im=E.forwardRef((t,e)=>{const{__scopeToast:n,...r}=t,o=KA(Jb,n);return v.jsx(Xb,{asChild:!0,children:v.jsx(Kt.button,{type:"button",...r,ref:e,onClick:dt(t.onClick,o.onClose)})})});im.displayName=Jb;var Xb=E.forwardRef((t,e)=>{const{__scopeToast:n,altText:r,...o}=t;return v.jsx(Kt.div,{"data-radix-toast-announce-exclude":"","data-radix-toast-announce-alt":r||void 0,...o,ref:e})});function Zb(t){const e=[];return Array.from(t.childNodes).forEach(r=>{if(r.nodeType===r.TEXT_NODE&&r.textContent&&e.push(r.textContent),ZA(r)){const o=r.ariaHidden||r.hidden||r.style.display==="none",a=r.dataset.radixToastAnnounceExclude==="";if(!o)if(a){const l=r.dataset.radixToastAnnounceAlt;l&&e.push(l)}else e.push(...Zb(r))}}),e}function Vu(t,e,n,{discrete:r}){const o=n.originalEvent.currentTarget,a=new CustomEvent(t,{bubbles:!0,cancelable:!0,detail:n});e&&o.addEventListener(t,e,{once:!0}),r?Lb(o,a):o.dispatchEvent(a)}var _0=(t,e,n=0)=>{const r=Math.abs(t.x),o=Math.abs(t.y),a=r>o;return e==="left"||e==="right"?a&&r>n:!a&&o>n};function XA(t=()=>{}){const e=xs(t);Pr(()=>{let n=0,r=0;return n=window.requestAnimationFrame(()=>r=window.requestAnimationFrame(e)),()=>{window.cancelAnimationFrame(n),window.cancelAnimationFrame(r)}},[e])}function ZA(t){return t.nodeType===t.ELEMENT_NODE}function eR(t){const e=[],n=document.createTreeWalker(t,NodeFilter.SHOW_ELEMENT,{acceptNode:r=>{const o=r.tagName==="INPUT"&&r.type==="hidden";return r.disabled||r.hidden||o?NodeFilter.FILTER_SKIP:r.tabIndex>=0?NodeFilter.FILTER_ACCEPT:NodeFilter.FILTER_SKIP}});for(;n.nextNode();)e.push(n.currentNode);return e}function Zh(t){const e=document.activeElement;return t.some(n=>n===e?!0:(n.focus(),document.activeElement!==e))}var tR=Bb,e1=Wb,t1=qb,n1=Kb,r1=Gb,s1=Yb,i1=im;function o1(t){var e,n,r="";if(typeof t=="string"||typeof t=="number")r+=t;else if(typeof t=="object")if(Array.isArray(t)){var o=t.length;for(e=0;e<o;e++)t[e]&&(n=o1(t[e]))&&(r&&(r+=" "),r+=n)}else for(n in t)t[n]&&(r&&(r+=" "),r+=n);return r}function a1(){for(var t,e,n=0,r="",o=arguments.length;n<o;n++)(t=arguments[n])&&(e=o1(t))&&(r&&(r+=" "),r+=e);return r}const E0=t=>typeof t=="boolean"?`${t}`:t===0?"0":t,T0=a1,l1=(t,e)=>n=>{var r;if((e==null?void 0:e.variants)==null)return T0(t,n==null?void 0:n.class,n==null?void 0:n.className);const{variants:o,defaultVariants:a}=e,l=Object.keys(o).map(f=>{const p=n==null?void 0:n[f],g=a==null?void 0:a[f];if(p===null)return null;const x=E0(p)||E0(g);return o[f][x]}),c=n&&Object.entries(n).reduce((f,p)=>{let[g,x]=p;return x===void 0||(f[g]=x),f},{}),d=e==null||(r=e.compoundVariants)===null||r===void 0?void 0:r.reduce((f,p)=>{let{class:g,className:x,...y}=p;return Object.entries(y).every(_=>{let[S,b]=_;return Array.isArray(b)?b.includes({...a,...c}[S]):{...a,...c}[S]===b})?[...f,g,x]:f},[]);return T0(t,l,d,n==null?void 0:n.class,n==null?void 0:n.className)};/**
70 * @license lucide-react v0.462.0 - ISC
71 *
72 * This source code is licensed under the ISC license.
73 * See the LICENSE file in the root directory of this source tree.
74 */const nR=t=>t.replace(/([a-z0-9])([A-Z])/g,"$1-$2").toLowerCase(),u1=(...t)=>t.filter((e,n,r)=>!!e&&e.trim()!==""&&r.indexOf(e)===n).join(" ").trim();/**
75 * @license lucide-react v0.462.0 - ISC
76 *
77 * This source code is licensed under the ISC license.
78 * See the LICENSE file in the root directory of this source tree.
79 */var rR={xmlns:"http://www.w3.org/2000/svg",width:24,height:24,viewBox:"0 0 24 24",fill:"none",stroke:"currentColor",strokeWidth:2,strokeLinecap:"round",strokeLinejoin:"round"};/**
80 * @license lucide-react v0.462.0 - ISC
81 *
82 * This source code is licensed under the ISC license.
83 * See the LICENSE file in the root directory of this source tree.
84 */const sR=E.forwardRef(({color:t="currentColor",size:e=24,strokeWidth:n=2,absoluteStrokeWidth:r,className:o="",children:a,iconNode:l,...c},d)=>E.createElement("svg",{ref:d,...rR,width:e,height:e,stroke:t,strokeWidth:r?Number(n)*24/Number(e):n,className:u1("lucide",o),...c},[...l.map(([f,p])=>E.createElement(f,p)),...Array.isArray(a)?a:[a]]));/**
85 * @license lucide-react v0.462.0 - ISC
86 *
87 * This source code is licensed under the ISC license.
88 * See the LICENSE file in the root directory of this source tree.
89 */const Oe=(t,e)=>{const n=E.forwardRef(({className:r,...o},a)=>E.createElement(sR,{ref:a,iconNode:e,className:u1(`lucide-${nR(t)}`,r),...o}));return n.displayName=`${t}`,n};/**
90 * @license lucide-react v0.462.0 - ISC
91 *
92 * This source code is licensed under the ISC license.
93 * See the LICENSE file in the root directory of this source tree.
94 */const iR=Oe("Activity",[["path",{d:"M22 12h-2.48a2 2 0 0 0-1.93 1.46l-2.35 8.36a.25.25 0 0 1-.48 0L9.24 2.18a.25.25 0 0 0-.48 0l
94-2.35 8.36A2 2 0 0 1 4.49 12H2",key:"169zse"}]]);/**
95 * @license lucide-react v0.462.0 - ISC
96 *
97 * This source code is licensed under the ISC license.
98 * See the LICENSE file in the root directory of this source tree.
99 */const oR=Oe("ArrowLeft",[["path",{d:"m12 19-7-7 7-7",key:"1l729n"}],["path",{d:"M19 12H5",key:"x3x0zl"}]]);/**
100 * @license lucide-react v0.462.0 - ISC
101 *
102 * This source code is licensed under the ISC license.
103 * See the LICENSE file in the root directory of this source tree.
104 */const Fc=Oe("ArrowRight",[["path",{d:"M5 12h14",key:"1ays0h"}],["path",{d:"m12 5 7 7-7 7",key:"xquz4c"}]]);/**
105 * @license lucide-react v0.462.0 - ISC
106 *
107 * This source code is licensed under the ISC license.
108 * See the LICENSE file in the root directory of this source tree.
109 */const aR=Oe("BookOpen",[["path",{d:"M12 7v14",key:"1akyts"}],["path",{d:"M3 18a1 1 0 0 1-1-1V4a1 1 0 0 1 1-1h5a4 4 0 0 1 4 4 4 4 0 0 1 4-4h5a1 1 0 0 1 1 1v13a1 1 0 0 1-1 1h-6a3 3 0 0 0-3 3 3 3 0 0 0-3-3z",key:"ruj8y"}]]);/**
110 * @license lucide-react v0.462.0 - ISC
111 *
112 * This source code is licensed under the ISC license.
113 * See the LICENSE file in the root directory of this source tree.
114 */const c1=Oe("Bot",[["path",{d:"M12 8V4H8",key:"hb8ula"}],["rect",{width:"16",height:"12",x:"4",y:"8",rx:"2",key:"enze0r"}],["path",{d:"M2 14h2",key:"vft8re"}],["path",{d:"M20 14h2",key:"4cs60a"}],["path",{d:"M15 13v2",key:"1xurst"}],["path",{d:"M9 13v2",key:"rq6x2g"}]]);/**
115 * @license lucide-react v0.462.0 - ISC
116 *
117 * This source code is licensed under the ISC license.
118 * See the LICENSE file in the root directory of this source tree.
119 */const lR=Oe("Brain",[["path",{d:"M12 5a3 3 0 1 0-5.997.125 4 4 0 0 0-2.526 5.77 4 4 0 0 0 .556 6.588A4 4 0 1 0 12 18Z",key:"l5xja"}],["path",{d:"M12 5a3 3 0 1 1 5.997.125 4 4 0 0 1 2.526 5.77 4 4 0 0 1-.556 6.588A4 4 0 1 1 12 18Z",key:"ep3f8r"}],["path",{d:"M15 13a4.5 4.5 0 0 1-3-4 4.5 4.5 0 0 1-3 4",key:"1p4c4q"}],["path",{d:"M17.599 6.5a3 3 0 0 0 .399-1.375",key:"tmeiqw"}],["path",{d:"M6.003 5.125A3 3 0 0 0 6.401 6.5",key:"105sqy"}],["path",{d:"M3.477 10.896a4 4 0 0 1 .585-.396",key:"ql3yin"}],["path",{d:"M19.938 10.5a4 4 0 0 1 .585.396",key:"1qfode"}],["path",{d:"M6 18a4 4 0 0 1-1.967-.516",key:"2e4loj"}],["path",{d:"M19.967 17.484A4 4 0 0 1 18 18",key:"159ez6"}]]);/**
120 * @license lucide-react v0.462.0 - ISC
121 *
122 * This source code is licensed under the ISC license.
123 * See the LICENSE file in the root directory of this source tree.
124 */const om=Oe("ChartColumn",[["path",{d:"M3 3v16a2 2 0 0 0 2 2h16",key:"c24i48"}],["path",{d:"M18 17V9",key:"2bz60n"}],["path",{d:"M13 17V5",key:"1frdt8"}],["path",{d:"M8 17v-3",key:"17ska0"}]]);/**
125 * @license lucide-react v0.462.0 - ISC
126 *
127 * This source code is licensed under the ISC license.
128 * See the LICENSE file in the root directory of this source tree.
129 */const uR=Oe("ChevronDown",[["path",{d:"m6 9 6 6 6-6",key:"qrunsl"}]]);/**
130 * @license lucide-react v0.462.0 - ISC
131 *
132 * This source code is licensed under the ISC license.
133 * See the LICENSE file in the root directory of this source tree.
134 */const cR=Oe("CircleCheckBig",[["path",{d:"M21.801 10A10 10 0 1 1 17 3.335",key:"yps3ct"}],["path",{d:"m9 11 3 3L22 4",key:"1pflzl"}]]);/**
135 * @license lucide-react v0.462.0 - ISC
136 *
137 * This source code is licensed under the ISC license.
138 * See the LICENSE file in the root directory of this source tree.
139 */const dR=Oe("CircleCheck",[["circle",{cx:"12",cy:"12",r:"10",key:"1mglay"}],["path",{d:"m9 12 2 2 4-4",key:"dzmm74"}]]);/**
140 * @license lucide-react v0.462.0 - ISC
141 *
142 * This source code is licensed under the ISC license.
143 * See the LICENSE file in the root directory of this source tree.
144 */const d1=Oe("Clock",[["circle",{cx:"12",cy:"12",r:"10",key:"1mglay"}],["polyline",{points:"12 6 12 12 16 14",key:"68esgv"}]]);/**
145 * @license lucide-react v0.462.0 - ISC
146 *
147 * This source code is licensed under the ISC license.
148 * See the LICENSE file in the root directory of this source tree.
149 */const h1=Oe("CodeXml",[["path",{d:"m18 16 4-4-4-4",key:"1inbqp"}],["path",{d:"m6 8-4 4 4 4",key:"15zrgr"}],["path",{d:"m14.5 4-5 16",key:"e7oirm"}]]);/**
150 * @license lucide-react v0.462.0 - ISC
151 *
152 * This source code is licensed under the ISC license.
153 * See the LICENSE file in the root directory of this source tree.
154 */const hR=Oe("Coins",[["circle",{cx:"8",cy:"8",r:"6",key:"3yglwk"}],["path",{d:"M18.09 10.37A6 6 0 1 1 10.34 18",key:"t5s6rm"}],["path",{d:"M7 6h1v4",key:"1obek4"}],["path",{d:"m16.71 13.88.7.71-2.82 2.82",key:"1rbuyh"}]]);/**
155 * @license lucide-react v0.462.0 - ISC
156 *
157 * This source code is licensed under the ISC license.
158 * See the LICENSE file in the root directory of this source tree.
159 */const fR=Oe("FolderOpen",[["path",{d:"m6 14 1.5-2.9A2 2 0 0 1 9.24 10H20a2 2 0 0 1 1.94 2.5l-1.54 6a2 2 0 0 1-1.95 1.5H4a2 2 0 0 1-2-2V5a2 2 0 0 1 2-2h3.9a2 2 0 0 1 1.69.9l.81 1.2a2 2 0 0 0 1.67.9H18a2 2 0 0 1 2 2v2",key:"usdka0"}]]);/**
160 * @license lucide-react v0.462.0 - ISC
161 *
162 * This source code is licensed under the ISC license.
163 * See the LICENSE file in the root directory of this source tree.
164 */const f1=Oe("LoaderCircle",[["path",{d:"M21 12a9 9 0 1 1-6.219-8.56",key:"13zald"}]]);/**
165 * @license lucide-react v0.462.0 - ISC
166 *
167 * This source code is licensed under the ISC license.
168 * See the LICENSE file in the root directory of this source tree.
169 */const np=Oe("Lock",[["rect",{width:"18",height:"11",x:"3",y:"11",rx:"2",ry:"2",key:"1w4ew1"}],["path",{d:"M7 11V7a5 5 0 0 1 10 0v4",key:"fwvmzm"}]]);/**
170 * @license lucide-react v0.462.0 - ISC
171 *
172 * This source code is licensed under the ISC license.
173 * See the LICENSE file in the root directory of this source tree.
174 */const pR=Oe("LogOut",[["path",{d:"M9 21H5a2 2 0 0 1-2-2V5a2 2 0 0 1 2-2h4",key:"1uf3rs"}],["polyline",{points:"16 17 21 12 16 7",key:"1gabdz"}],["line",{x1:"21",x2:"9",y1:"12",y2:"12",key:"1uyos4"}]]);/**
175 * @license lucide-react v0.462.0 - ISC
176 *
177 * This source code is licensed under the ISC license.
178 * See the LICENSE file in the root directory of this source tree.
179 */const mR=Oe("Mail",[["rect",{width:"20",height:"16",x:"2",y:"4",rx:"2",key:"18n3k1"}],["path",{d:"m22 7-8.97 5.7a1.94 1.94 0 0 1-2.06 0L2 7",key:"1ocrg3"}]]);/**
180 * @license lucide-react v0.462.0 - ISC
181 *
182 * This source code is licensed under the ISC license.
183 * See the LICENSE file in the root directory of this source tree.
184 */const gR=Oe("Quote",[["path",{d:"M16 3a2 2 0 0 0-2 2v6a2 2 0 0 0 2 2 1 1 0 0 1 1 1v1a2 2 0 0 1-2 2 1 1 0 0 0-1 1v2a1 1 0 0 0 1 1 6 6 0 0 0 6-6V5a2 2 0 0 0-2-2z",key:"rib7q0"}],["path",{d:"M5 3a2 2 0 0 0-2 2v6a2 2 0 0 0 2 2 1 1 0 0 1 1 1v1a2 2 0 0 1-2 2 1 1 0 0 0-1 1v2a1 1 0 0 0 1 1 6 6 0 0 0 6-6V5a2 2 0 0 0-2-2z",key:"1ymkrd"}]]);/**
185 * @license lucide-react v0.462.0 - ISC
186 *
187 * This source code is licensed under the ISC license.
188 * See the LICENSE file in the root directory of this source tree.
189 */const yR=Oe("Repeat",[["path",{d:"m17 2 4 4-4 4",key:"nntrym"}],["path",{d:"M3 11v-1a4 4 0 0 1 4-4h14",key:"84bu3i"}],["path",{d:"m7 22-4-4 4-4",key:"1wqhfi"}],["path",{d:"M21 13v1a4 4 0 0 1-4 4H3",key:"1rx37r"}]]);/**
190 * @license lucide-react v0.462.0 - ISC
191 *
192 * This source code is licensed under the ISC license.
193 * See the LICENSE file in the root directory of this source tree.
194 */const vR=Oe("Rocket",[["path",{d:"M4.5 16.5c-1.5 1.26-2 5-2 5s3.74-.5 5-2c.71-.84.7-2.13-.09-2.91a2.18 2.18 0 0 0-2.91-.09z",key:"m3kijz"}],["path",{d:"m12 15-3-3a22 22 0 0 1 2-3.95A12.88 12.88 0 0 1 22 2c0 2.72-.78 7.5-6 11a22.35 22.35 0 0 1-4 2z",key:"1fmvmk"}],["path",{d:"M9 12H4s.55-3.03 2-4c1.62-1.08 5 0 5 0",key:"1f8sc4"}],["path",{d:"M12 15v5s3.03-.55 4-2c1.08-1.62 0-5 0-5",key:"qeys4"}]]);/**
195 * @license lucide-react v0.462.0 - ISC
196 *
197 * This source code is licensed under the ISC license.
198 * See the LICENSE file in the root directory of this source tree.
199 */const wR=Oe("ShieldCheck",[["path",{d:"M20 13c0 5-3.5 7.5-7.66 8.95a1 1 0 0 1-.67-.01C7.5 20.5 4 18 4 13V6a1 1 0 0 1 1-1c2 0 4.5-1.2 6.24-2.72a1.17 1.17 0 0 1 1.52 0C14.51 3.81 17 5 19 5a1 1 0 0 1 1 1z",key:"oel41y"}],["path",{d:"m9 12 2 2 4-4",key:"dzmm74"}]]);/**
200 * @license lucide-react v0.462.0 - ISC
201 *
202 * This source code is licensed under the ISC license.
203 * See the LICENSE file in the root directory of this source tree.
204 */const xR=Oe("Shield",[["path",{d:"M20 13c0 5-3.5 7.5-7.66 8.95a1 1 0 0 1-.67-.01C7.5 20.5 4 18 4 13V6a1 1 0 0 1 1-1c2 0 4.5-1.2 6.24-2.72a1.17 1.17 0 0 1 1.52 0C14.51 3.81 17 5 19 5a1 1 0 0 1 1 1z",key:"oel41y"}]]);/**
205 * @license lucide-react v0.462.0 - ISC
206 *
207 * This source code is licensed under the ISC license.
208 * See the LICENSE file in the root directory of this source tree.
209 */const p1=Oe("Sparkles",[["path",{d:"M9.937 15.5A2 2 0 0 0 8.5 14.063l-6.135-1.582a.5.5 0 0 1 0-.962L8.5 9.936A2 2 0 0 0 9.937 8.5l1.582-6.135a.5.5 0 0 1 .963 0L14.063 8.5A2 2 0 0 0 15.5 9.937l6.135 1.581a.5.5 0 0 1 0 .964L15.5 14.063a2 2 0 0 0-1.437 1.437l-1.582 6.135a.5.5 0 0 1-.963 0z",key:"4pj2yx"}],["path",{d:"M20 3v4",key:"1olli1"}],["path",{d:"M22 5h-4",key:"1gvqau"}],["path",{d:"M4 17v2",key:"vumght"}],["path",{d:"M5 18H3",key:"zchphs"}]]);/**
210 * @license lucide-react v0.462.0 - ISC
211 *
212 * This source code is licensed under the ISC license.
213 * See the LICENSE file in the root directory of this source tree.
214 */const bR=Oe("SquareCheckBig",[["path",{d:"M21 10.5V19a2 2 0 0 1-2 2H5a2 2 0 0 1-2-2V5a2 2 0 0 1 2-2h12.5",key:"1uzm8b"}],["path",{d:"m9 11 3 3L22 4",key:"1pflzl"}]]);/**
215 * @license lucide-react v0.462.0 - ISC
216 *
217 * This source code is licensed under the ISC license.
218 * See the LICENSE file in the root directory of this source tree.
219 */const SR=Oe("Square",[["rect",{width:"18",height:"18",x:"3",y:"3",rx:"2",key:"afitv7"}]]);/**
220 * @license lucide-react v0.462.0 - ISC
221 *
222 * This source code is licensed under the ISC license.
223 * See the LICENSE file in the root directory of this source tree.
224 */const _R=Oe("Star",[["path",{d:"M11.525 2.295a.53.53 0 0 1 .95 0l2.31 4.679a2.123 2.123 0 0 0 1.595 1.16l5.166.756a.53.53 0 0 1 .294.904l-3.736 3.638a2.123 2.123 0 0 0-.611 1.878l.882 5.14a.53.53 0 0 1-.771.56l-4.618-2.428a2.122 2.122 0 0 0-1.973 0L6.396 21.01a.53.53 0 0 1-.77-.56l.881-5.139a2.122 2.122 0 0 0-.611-1.879L2.16 9.795a.53.53 0 0 1 .294-.906l5.165-.755a2.122 2.122 0 0 0 1.597-1.16z",key:"r04s7s"}]]);/**
225 * @license lucide-react v0.462.0 - ISC
226 *
227 * This source code is licensed under the ISC license.
228 * See the LICENSE file in the root directory of this source tree.
229 */const ER=Oe("Target",[["circle",{cx:"12",cy:"12",r:"10",key:"1mglay"}],["circle",{cx:"12",cy:"12",r:"6",key:"1vlfrh"}],["circle",{cx:"12",cy:"12",r:"2",key:"1c9p78"}]]);/**
230 * @license lucide-react v0.462.0 - ISC
231 *
232 * This source code is licensed under the ISC license.
233 * See the LICENSE file in the root directory of this source tree.
234 */const TR=Oe("TrendingDown",[["polyline",{points:"22 17 13.5 8.5 8.5 13.5 2 7",key:"1r2t7k"}],["polyline",{points:"16 17 22 17 22 11",key:"11uiuu"}]]);/**
235 * @license lucide-react v0.462.0 - ISC
236 *
237 * This source code is licensed under the ISC license.
238 * See the LICENSE file in the root directory of this source tree.
239 */const rp=Oe("TrendingUp",[["polyline",{points:"22 7 13.5 15.5 8.5 10.5 2 17",key:"126l90"}],["polyline",{points:"16 7 22 7 22 13",key:"kwv8wd"}]]);/**
240 * @license lucide-react v0.462.0 - ISC
241 *
242 * This source code is licensed under the ISC license.
243 * See the LICENSE file in the root directory of this source tree.
244 */const kR=Oe("UserRound",[["circle",{cx:"12",cy:"8",r:"5",key:"1hypcn"}
vendor: 1,919 bytes, lines 244-264
244],["path",{d:"M20 21a8 8 0 0 0-16 0",key:"rfgkzh"}]]);/**
245 * @license lucide-react v0.462.0 - ISC
246 *
247 * This source code is licensed under the ISC license.
248 * See the LICENSE file in the root directory of this source tree.
249 */const m1=Oe("User",[["path",{d:"M19 21v-2a4 4 0 0 0-4-4H9a4 4 0 0 0-4 4v2",key:"975kel"}],["circle",{cx:"12",cy:"7",r:"4",key:"17ys0d"}]]);/**
250 * @license lucide-react v0.462.0 - ISC
251 *
252 * This source code is licensed under the ISC license.
253 * See the LICENSE file in the root directory of this source tree.
254 */const CR=Oe("Wallet",[["path",{d:"M19 7V4a1 1 0 0 0-1-1H5a2 2 0 0 0 0 4h15a1 1 0 0 1 1 1v4h-3a2 2 0 0 0 0 4h3a1 1 0 0 0 1-1v-2a1 1 0 0 0-1-1",key:"18etb6"}],["path",{d:"M3 5v14a2 2 0 0 0 2 2h15a1 1 0 0 0 1-1v-4",key:"xoc0q4"}]]);/**
255 * @license lucide-react v0.462.0 - ISC
256 *
257 * This source code is licensed under the ISC license.
258 * See the LICENSE file in the root directory of this source tree.
259 */const g1=Oe("X",[["path",{d:"M18 6 6 18",key:"1bl5f8"}],["path",{d:"m6 6 12 12",key:"d8bk6v"}]]);/**
260 * @license lucide-react v0.462.0 - ISC
261 *
262 * This source code is licensed under the ISC license.
263 * See the LICENSE file in the root directory of this source tree.
264 */const PR=Oe("Zap",[["path",{d:"M4 14a1 1 0 0 1-.78-1.63l9.9-10.2a.5.5 0 0 1 .86.46l-1.92 6.02A1 1 0 0 0 13 10h7a1 1 0 0 1 .78 1.63l-9.9 10.2a.5.5 0 0 1-.86-.46l1.92-6.02A1 1 0 0 0 11 14z",key:"1xq2db"}]]),am="-",AR=t=>{const e=jR(t),{conflictingClassGroups:n,conflictingClassGroupModifiers:r}=t;return{getClassGroupId:l=>{const c=l.split(am);return c[0]===""&&c.length!==1&&c.shift(),y1(c,e)||RR(l)},getConflictingClassGroupIds:(l,c)=>{const d=n[l]||[];return c&&r[l]?[...d,...r[l]]:d}}},y1=(t,e)=>{var l;if(t.length===0)return e.classGroupId;const n=t[0],r=e.nextPart.get(n),o=r?y1(t.slice(1),r):void 0;if(o)return o;if(e.validators.length===0)return;const a=t.join(am);return(l=e.validators.find(({validator:c}
vendor: 5,378 bytes, line 264
264)=>c(a)))==null?void 0:l.classGroupId},k0=/^\[(.+)\]$/,RR=t=>{if(k0.test(t)){const e=k0.exec(t)[1],n=e==null?void 0:e.substring(0,e.indexOf(":"));if(n)return"arbitrary.."+n}},jR=t=>{const{theme:e,prefix:n}=t,r={nextPart:new Map,validators:[]};return NR(Object.entries(t.classGroups),n).forEach(([a,l])=>{sp(l,r,a,e)}),r},sp=(t,e,n,r)=>{t.forEach(o=>{if(typeof o=="string"){const a=o===""?e:C0(e,o);a.classGroupId=n;return}if(typeof o=="function"){if(OR(o)){sp(o(r),e,n,r);return}e.validators.push({validator:o,classGroupId:n});return}Object.entries(o).forEach(([a,l])=>{sp(l,C0(e,a),n,r)})})},C0=(t,e)=>{let n=t;return e.split(am).forEach(r=>{n.nextPart.has(r)||n.nextPart.set(r,{nextPart:new Map,validators:[]}),n=n.nextPart.get(r)}),n},OR=t=>t.isThemeGetter,NR=(t,e)=>e?t.map(([n,r])=>{const o=r.map(a=>typeof a=="string"?e+a:typeof a=="object"?Object.fromEntries(Object.entries(a).map(([l,c])=>[e+l,c])):a);return[n,o]}):t,IR=t=>{if(t<1)return{get:()=>{},set:()=>{}};let e=0,n=new Map,r=new Map;const o=(a,l)=>{n.set(a,l),e++,e>t&&(e=0,r=n,n=new Map)};return{get(a){let l=n.get(a);if(l!==void 0)return l;if((l=r.get(a))!==void 0)return o(a,l),l},set(a,l){n.has(a)?n.set(a,l):o(a,l)}}},v1="!",LR=t=>{const{separator:e,experimentalParseClassName:n}=t,r=e.length===1,o=e[0],a=e.length,l=c=>{const d=[];let f=0,p=0,g;for(let b=0;b<c.length;b++){let k=c[b];if(f===0){if(k===o&&(r||c.slice(b,b+a)===e)){d.push(c.slice(p,b)),p=b+a;continue}if(k==="/"){g=b;continue}}k==="["?f++:k==="]"&&f--}const x=d.length===0?c:c.substring(p),y=x.startsWith(v1),_=y?x.substring(1):x,S=g&&g>p?g-p:void 0;return{modifiers:d,hasImportantModifier:y,baseClassName:_,maybePostfixModifierPosition:S}};return n?c=>n({className:c,parseClassName:l}):l},DR=t=>{if(t.length<=1)return t;const e=[];let n=[];return t.forEach(r=>{r[0]==="["?(e.push(...n.sort(),r),n=[]):n.push(r)}),e.push(...n.sort()),e},MR=t=>({cache:IR(t.cacheSize),parseClassName:LR(t),...AR(t)}),$R=/\s+/,FR=(t,e)=>{const{parseClassName:n,getClassGroupId:r,getConflictingClassGroupIds:o}=e,a=[],l=t.trim().split($R);let c="";for(let d=l.length-1;d>=0;d-=1){const f=l[d],{modifiers:p,hasImportantModifier:g,baseClassName:x,maybePostfixModifierPosition:y}=n(f);let _=!!y,S=r(_?x.substring(0,y):x);if(!S){if(!_){c=f+(c.length>0?" "+c:c);continue}if(S=r(x),!S){c=f+(c.length>0?" "+c:c);continue}_=!1}const b=DR(p).join(":"),k=g?b+v1:b,P=k+S;if(a.includes(P))continue;a.push(P);const C=o(S,_);for(let A=0;A<C.length;++A){const L=C[A];a.push(k+L)}c=f+(c.length>0?" "+c:c)}return c};function UR(){let t=0,e,n,r="";for(;t<arguments.length;)(e=arguments[t++])&&(n=w1(e))&&(r&&(r+=" "),r+=n);return r}const w1=t=>{if(typeof t=="string")return t;let e,n="";for(let r=0;r<t.length;r++)t[r]&&(e=w1(t[r]))&&(n&&(n+=" "),n+=e);return n};function VR(t,...e){let n,r,o,a=l;function l(d){const f=e.reduce((p,g)=>g(p),t());return n=MR(f),r=n.cache.get,o=n.cache.set,a=c,c(d)}function c(d){const f=r(d);if(f)return f;const p=FR(d,n);return o(d,p),p}return function(){return a(UR.apply(null,arguments))}}const He=t=>{const e=n=>n[t]||[];return e.isThemeGetter=!0,e},x1=/^\[(?:([a-z-]+):)?(.+)\]$/i,BR=/^\d+\/\d+$/,zR=new Set(["px","full","screen"]),WR=/^(\d+(\.\d+)?)?(xs|sm|md|lg|xl)$/,HR=/\d+(%|px|r?em|[sdl]?v([hwib]|min|max)|pt|pc|in|cm|mm|cap|ch|ex|r?lh|cq(w|h|i|b|min|max))|\b(calc|min|max|clamp)\(.+\)|^0$/,qR=/^(rgba?|hsla?|hwb|(ok)?(lab|lch)|color-mix)\(.+\)$/,KR=/^(inset_)?-?((\d+)?\.?(\d+)[a-z]+|0)_-?((\d+)?\.?(\d+)[a-z]+|0)/,GR=/^(url|image|image-set|cross-fade|element|(repeating-)?(linear|radial|conic)-gradient)\(.+\)$/,Sr=t=>co(t)||zR.has(t)||BR.test(t),ns=t=>Oo(t,"length",nj),co=t=>!!t&&!Number.isNaN(Number(t)),ef=t=>Oo(t,"number",co),Ea=t=>!!t&&Number.isInteger(Number(t)),QR=t=>t.endsWith("%")&&co(t.slice(0,-1)),Ce=t=>x1.test(t),rs=t=>WR.test(t),YR=new Set(["length","size","percentage"]),JR=t=>Oo(t,YR,b1),XR=t=>Oo(t,"position",b1),ZR=new Set(["image","url"]),ej=t=>Oo(t,ZR,sj),tj=t=>Oo(t,"",rj),Ta=()=>!0,Oo=(t,e,n)=>{const r=x1.exec(t);return r?r[1]?typeof e=="string"?r[1]===e:e.has(r[1]):n(r[2]):!1},nj=t=>HR.test(t)&&!qR.test(t),b1=()=>!1,rj=t=>KR.test(t),sj=t=>GR.test(t),ij=()=>{const t=He("colors"),e=He("spacing"),n=He("blur"),r=He("brightness"),o=He("borderColor"),a=He("borderRadius"),l=He("borderSpacing"),c=He("borderWidth"),d=He("contrast"),f=He("grayscale"),p=He("hueRotate"),g=He("invert"),x=He("gap"),y=He("gradientColorStops"),_=He("gradientColorStopPositions"),S=He("inset"),b=He("margin"),k=He("opacity"),P=He("padding"),C=He("saturate"),A=He("scale"),L=He("sepia"),D=He("skew"),V=He("space"),z=He("translate"),q=()=>["auto","contain","none"],H=()=>["auto","hidden","clip","visible","scroll"],te=()=>["auto",Ce,e],Z=()=>[Ce,e],me=()=>["",Sr,ns],J=()=>["auto",co,Ce],fe=()=>["bottom","center","left","left-bottom","left-top","right","right-bottom","right-top","top"],ie=()=>["solid","dashed","dotted","double","none"],de=()=>["normal","multiply","screen","overlay","darken","lighten","color-dodge","color-burn","hard-light","soft-light","difference","exclusion","hue","saturation","color","luminosity"],U=()=>["start","end","center","between","around","evenly","stretch"],W=()=>["","0",Ce],G=()=>["auto","avoid","all","avoid-page","page","left","right","column"],N=()=>[co,Ce];return{cacheSize:500,separator:":",theme:{colors:[Ta],spacing:[Sr,ns],blur:["none","",rs,Ce],brightness:N(),borderColor:[t],borderRadius:["n
264one","","full",rs,Ce],borderSpacing:Z(),borderWidth:me(),contrast:N(),grayscale:W(),hueRotate:N(),invert:W(),gap:Z(),gradientColorStops:[t],gradientColorStopPositions:[QR,ns],inset:te(),margin:te(),opacity:N(),padding:Z(),saturate:N(),scale:N(),sepia:W(),skew:N(),space:Z(),translate:Z()},classGroups:{aspect:[{aspect:["auto","square","video",Ce]}],container:["container"],columns:[{columns:[rs]}],"break-after":[{"break-after":G()}],"break-before":[{"break-before":G()}],"break-inside":[{"break-inside":["auto","avoid","avoid-page","avoid-column"]}],"box-decoration":[{"box-decoration":["slice","clone"]}],box:[{box:["border","content"]}],display:["block","inline-block","inline","flex","inline-flex","table","inline-table","table-caption","table-cell","table-column","table-column-group","table-footer-group","table-header-group","table-row-group","table-row","flow-root","grid","inline-grid","contents","list-item","hidden"],float:[{float:["right","left","none","start","end"]}],clear:[{clear:["left","right","both","none","start","end"]}],isolation:["isolate","isolation-auto"],"object-fit":[{object:["contain","cover","fill","none","scale-down"]}],"object-position":[{object:[...fe(),Ce]}],overflow:[{overflow:H()}],"overflow-x":[{"overflow-x":H()}],"overflow-y":[{"overflow-y":H()}],overscroll:[{overscroll:q()}],"overscroll-x":[{"overscroll-x":q()}],"overscroll-y":[{"overscroll-y":q()}],position:["static","fixed","absolute","relative","sticky"],inset:[{inset:[S]}],"inset-x":[{"inset-x":[S]}],"inset-y":[{"inset-y":[S]}],start:[{start:[S]}],end:[{end:[S]}],top:[{top:[S]}],right:[{right:[S]}],bottom:[{bottom:[S]}],left:[{left:[S]}],visibility:["visible","invisible","collapse"],z:[{z:["auto",Ea,Ce]}],basis:[{basis:te()}],"flex-direction":[{flex:["row","row-reverse","col","col-reverse"]}],"flex-wrap":[{flex:["wrap","wrap-reverse","nowrap"]}],flex:[{flex:["1","auto","initial","none",Ce]}],grow:[{grow:W()}],shrink:[{shrink:W()}],order:[{order:["first","last","none",Ea,Ce]}],"grid-cols":[{"grid-cols":[Ta]}],"col-start-end":[{col:["auto",{span:["full",Ea,Ce]},Ce]}],"col-start":[{"col-start":J()}],"col-end":[{"col-end":J()}],"grid-rows":[{"grid-rows":[Ta]}],"row-start-end":[{row:["auto",{span:[Ea,Ce]},Ce]}],"row-start":[{"row-start":J()}],"row-end":[{"row-end":J()}],"grid-flow":[{"grid-flow":["row","col","dense","row-dense","col-dense"]}],"auto-cols":[{"auto-cols":["auto","min","max","fr",Ce]}],"auto-rows":[{"auto-rows":["auto","min","max","fr",Ce]}],gap:[{gap:[x]}],"gap-x":[{"gap-x":[x]}],"gap-y":[{"gap-y":[x]}],"justify-content":[{justify:["normal",...U()]}],"justify-items":[{"justify-items":["start","end","center","stretch"]}],"justify-self":[{"justify-self":["auto","start","end","center","stretch"]}],"align-content":[{content:["normal",...U(),"baseline"]}],"align-items":[{items:["start","end","center","baseline","stretch"]}],"align-self":[{self:["auto","start","end","center","stretch","baseline"]}],"place-content":[{"place-content":[...U(),"baseline"]}],"place-items":[{"place-items":["start","end","center","baseline","stretch"]}],"place-self":[{"place-self":["auto","start","end","center","stretch"]}],p:[{p:[P]}],px:[{px:[P]}],py:[{py:[P]}],ps:[{ps:[P]}],pe:[{pe:[P]}],pt:[{pt:[P]}],pr:[{pr:[P]}],pb:[{pb:[P]}],pl:[{pl:[P]}],m:[{m:[b]}],mx:[{mx:[b]}],my:[{my:[b]}],ms:[{ms:[b]}],me:[{me:[b]}],mt:[{mt:[b]}],mr:[{mr:[b]}],mb:[{mb:[b]}],ml:[{ml:[b]}],"space-x":[{"space-x":[V]}],"space-x-reverse":["space-x-reverse"],"space-y":[{"space-y":[V]}],"space-y-reverse":["space-y-reverse"],w:[{w:["auto","min","max","fit","svw","lvw","dvw",Ce,e]}],"min-w":[{"min-w":[Ce,e,"min","max","fit"]}],"max-w":[{"max-w":[Ce,e,"none","full","min","max","fit","prose",{screen:[rs]},rs]}],h:[{h:[Ce,e,"auto","min","max","fit","svh","lvh","dvh"]}],"min-h":[{"min-h":[Ce,e,"min","max","fit","svh","lvh","dvh"]}],"max-h":[{"max-h":[Ce,e,"min","max","fit","svh","lvh","dvh"]}],size:[{size:[Ce,e,"auto","min","max","fit"]}],"font-size":[{text:["base",rs,ns]}],"font-smoothing":["antialiased","subpixel-antialiased"],"font-style":["italic","not-italic"],"font-weight":[{font:["thin","extralight","light","normal","medium","semibold","bold","extrabold","black",ef]}],"font-family":[{font:[Ta]}],"fvn-normal":["normal-nums"],"fvn-ordinal":["ordinal"],"fvn-slashed-zero":["slashed-zero"],"fvn-figure":["lining-nums","oldstyle-nums"],"fvn-spacing":["proportional-nums","tabular-nums"],"fvn-fraction":["diagonal-fractions","stacked-fractions"],tracking:[{tracking:["tighter","tight","normal","wide","wider","widest",Ce]}],"line-clamp":[{"line-clamp":["none",co,ef]}],leading:[{leading:["none","tight","snug","normal","relaxed","loose",Sr,Ce]}],"list-image":[{"list-image":["none",Ce]}],"list-style-type":[{list:["none","disc","decimal",Ce]}],"list-style-position":[{list:["inside","outside"]}],"placeholder-color":[{placeholder:[t]}],"placeholder-opacity":[{"placeholder-opacity":[k]}],"text-alignment":[{text:["left","center","right","justify","start","end"]}],"text-color":[{text:[t]}],"text-opacity":[{"text-opacity":[k]}],"text-decoration":["underline","overline","line-through","no-underline"],"text-decoration-style":[{decoration:[...ie(),"wavy"]}],"text-decoration-thickness":[{decoration:["auto","from-font",Sr,ns]}],"underline-offset":[{"underline-offset":["auto",Sr,Ce]}],"text-decoration-color":[{decoration:[t]}],"text-transform":["uppercase","lowercase","capitalize","normal-case"],"text-overflow":["truncate","text-ellipsis","text-clip"],"text-wrap":[{text:["wrap","nowrap","balance","pretty"]}],indent:[{indent:Z()}],"vertical-align":[{align:["baseline","top","middle","bottom","text-top","text-bottom","sub","super",Ce]}],whitespace:[{whitespace:["normal","nowrap","pre","pre-line","pre-wrap","break-spaces"]}],break:[{break:["normal","words","all","keep"]}],hyphens:[{hyphens:["none","manual","auto"]}],content:[{content:["none",Ce]}],"bg-attachment":[{bg:["fixed","local","scroll"]}],"bg-clip":[{"bg-clip":["border","padding","content","text"]}],"bg-opacity":[{"bg-opacity":[k]}],"bg-origin":[{"bg-origin":["border","padding","content"]}],"bg-position":[{bg:[...fe(),XR]}],"bg-repeat":[{bg:["no-repeat",{repeat:["","x","y","round","space"]}]}],"bg-size":[{bg:["auto","cover","contain",JR]}],"bg-image":[{bg:["none",{"gradient-to":["t","tr","r","br","b","bl","l","tl"]},ej]}],"bg-color":[{bg:[t]}],"gradient-from-pos":[{from:[_]}
vendor: 5,186 bytes, line 264
264],"gradient-via-pos":[{via:[_]}],"gradient-to-pos":[{to:[_]}],"gradient-from":[{from:[y]}],"gradient-via":[{via:[y]}],"gradient-to":[{to:[y]}],rounded:[{rounded:[a]}],"rounded-s":[{"rounded-s":[a]}],"rounded-e":[{"rounded-e":[a]}],"rounded-t":[{"rounded-t":[a]}],"rounded-r":[{"rounded-r":[a]}],"rounded-b":[{"rounded-b":[a]}],"rounded-l":[{"rounded-l":[a]}],"rounded-ss":[{"rounded-ss":[a]}],"rounded-se":[{"rounded-se":[a]}],"rounded-ee":[{"rounded-ee":[a]}],"rounded-es":[{"rounded-es":[a]}],"rounded-tl":[{"rounded-tl":[a]}],"rounded-tr":[{"rounded-tr":[a]}],"rounded-br":[{"rounded-br":[a]}],"rounded-bl":[{"rounded-bl":[a]}],"border-w":[{border:[c]}],"border-w-x":[{"border-x":[c]}],"border-w-y":[{"border-y":[c]}],"border-w-s":[{"border-s":[c]}],"border-w-e":[{"border-e":[c]}],"border-w-t":[{"border-t":[c]}],"border-w-r":[{"border-r":[c]}],"border-w-b":[{"border-b":[c]}],"border-w-l":[{"border-l":[c]}],"border-opacity":[{"border-opacity":[k]}],"border-style":[{border:[...ie(),"hidden"]}],"divide-x":[{"divide-x":[c]}],"divide-x-reverse":["divide-x-reverse"],"divide-y":[{"divide-y":[c]}],"divide-y-reverse":["divide-y-reverse"],"divide-opacity":[{"divide-opacity":[k]}],"divide-style":[{divide:ie()}],"border-color":[{border:[o]}],"border-color-x":[{"border-x":[o]}],"border-color-y":[{"border-y":[o]}],"border-color-s":[{"border-s":[o]}],"border-color-e":[{"border-e":[o]}],"border-color-t":[{"border-t":[o]}],"border-color-r":[{"border-r":[o]}],"border-color-b":[{"border-b":[o]}],"border-color-l":[{"border-l":[o]}],"divide-color":[{divide:[o]}],"outline-style":[{outline:["",...ie()]}],"outline-offset":[{"outline-offset":[Sr,Ce]}],"outline-w":[{outline:[Sr,ns]}],"outline-color":[{outline:[t]}],"ring-w":[{ring:me()}],"ring-w-inset":["ring-inset"],"ring-color":[{ring:[t]}],"ring-opacity":[{"ring-opacity":[k]}],"ring-offset-w":[{"ring-offset":[Sr,ns]}],"ring-offset-color":[{"ring-offset":[t]}],shadow:[{shadow:["","inner","none",rs,tj]}],"shadow-color":[{shadow:[Ta]}],opacity:[{opacity:[k]}],"mix-blend":[{"mix-blend":[...de(),"plus-lighter","plus-darker"]}],"bg-blend":[{"bg-blend":de()}],filter:[{filter:["","none"]}],blur:[{blur:[n]}],brightness:[{brightness:[r]}],contrast:[{contrast:[d]}],"drop-shadow":[{"drop-shadow":["","none",rs,Ce]}],grayscale:[{grayscale:[f]}],"hue-rotate":[{"hue-rotate":[p]}],invert:[{invert:[g]}],saturate:[{saturate:[C]}],sepia:[{sepia:[L]}],"backdrop-filter":[{"backdrop-filter":["","none"]}],"backdrop-blur":[{"backdrop-blur":[n]}],"backdrop-brightness":[{"backdrop-brightness":[r]}],"backdrop-contrast":[{"backdrop-contrast":[d]}],"backdrop-grayscale":[{"backdrop-grayscale":[f]}],"backdrop-hue-rotate":[{"backdrop-hue-rotate":[p]}],"backdrop-invert":[{"backdrop-invert":[g]}],"backdrop-opacity":[{"backdrop-opacity":[k]}],"backdrop-saturate":[{"backdrop-saturate":[C]}],"backdrop-sepia":[{"backdrop-sepia":[L]}],"border-collapse":[{border:["collapse","separate"]}],"border-spacing":[{"border-spacing":[l]}],"border-spacing-x":[{"border-spacing-x":[l]}],"border-spacing-y":[{"border-spacing-y":[l]}],"table-layout":[{table:["auto","fixed"]}],caption:[{caption:["top","bottom"]}],transition:[{transition:["none","all","","colors","opacity","shadow","transform",Ce]}],duration:[{duration:N()}],ease:[{ease:["linear","in","out","in-out",Ce]}],delay:[{delay:N()}],animate:[{animate:["none","spin","ping","pulse","bounce",Ce]}],transform:[{transform:["","gpu","none"]}],scale:[{scale:[A]}],"scale-x":[{"scale-x":[A]}],"scale-y":[{"scale-y":[A]}],rotate:[{rotate:[Ea,Ce]}],"translate-x":[{"translate-x":[z]}],"translate-y":[{"translate-y":[z]}],"skew-x":[{"skew-x":[D]}],"skew-y":[{"skew-y":[D]}],"transform-origin":[{origin:["center","top","top-right","right","bottom-right","bottom","bottom-left","left","top-left",Ce]}],accent:[{accent:["auto",t]}],appearance:[{appearance:["none","auto"]}],cursor:[{cursor:["auto","default","pointer","wait","text","move","help","not-allowed","none","context-menu","progress","cell","crosshair","vertical-text","alias","copy","no-drop","grab","grabbing","all-scroll","col-resize","row-resize","n-resize","e-resize","s-resize","w-resize","ne-resize","nw-resize","se-resize","sw-resize","ew-resize","ns-resize","nesw-resize","nwse-resize","zoom-in","zoom-out",Ce]}],"caret-color":[{caret:[t]}],"pointer-events":[{"pointer-events":["none","auto"]}],resize:[{resize:["none","y","x",""]}],"scroll-behavior":[{scroll:["auto","smooth"]}],"scroll-m":[{"scroll-m":Z()}],"scroll-mx":[{"scroll-mx":Z()}],"scroll-my":[{"scroll-my":Z()}],"scroll-ms":[{"scroll-ms":Z()}],"scroll-me":[{"scroll-me":Z()}],"scroll-mt":[{"scroll-mt":Z()}],"scroll-mr":[{"scroll-mr":Z()}],"scroll-mb":[{"scroll-mb":Z()}],"scroll-ml":[{"scroll-ml":Z()}],"scroll-p":[{"scroll-p":Z()}],"scroll-px":[{"scroll-px":Z()}],"scroll-py":[{"scroll-py":Z()}],"scroll-ps":[{"scroll-ps":Z()}],"scroll-pe":[{"scroll-pe":Z()}],"scroll-pt":[{"scroll-pt":Z()}],"scroll-pr":[{"scroll-pr":Z()}],"scroll-pb":[{"scroll-pb":Z()}],"scroll-pl":[{"scroll-pl":Z()}],"snap-align":[{snap:["start","end","center","align-none"]}],"snap-stop":[{snap:["normal","always"]}],"snap-type":[{snap:["none","x","y","both"]}],"snap-strictness":[{snap:["mandatory","proximity"]}
vendor: 4,647 bytes, line 264
264],touch:[{touch:["auto","none","manipulation"]}],"touch-x":[{"touch-pan":["x","left","right"]}],"touch-y":[{"touch-pan":["y","up","down"]}],"touch-pz":["touch-pinch-zoom"],select:[{select:["none","text","all","auto"]}],"will-change":[{"will-change":["auto","scroll","contents","transform",Ce]}],fill:[{fill:[t,"none"]}],"stroke-w":[{stroke:[Sr,ns,ef]}],stroke:[{stroke:[t,"none"]}],sr:["sr-only","not-sr-only"],"forced-color-adjust":[{"forced-color-adjust":["auto","none"]}]},conflictingClassGroups:{overflow:["overflow-x","overflow-y"],overscroll:["overscroll-x","overscroll-y"],inset:["inset-x","inset-y","start","end","top","right","bottom","left"],"inset-x":["right","left"],"inset-y":["top","bottom"],flex:["basis","grow","shrink"],gap:["gap-x","gap-y"],p:["px","py","ps","pe","pt","pr","pb","pl"],px:["pr","pl"],py:["pt","pb"],m:["mx","my","ms","me","mt","mr","mb","ml"],mx:["mr","ml"],my:["mt","mb"],size:["w","h"],"font-size":["leading"],"fvn-normal":["fvn-ordinal","fvn-slashed-zero","fvn-figure","fvn-spacing","fvn-fraction"],"fvn-ordinal":["fvn-normal"],"fvn-slashed-zero":["fvn-normal"],"fvn-figure":["fvn-normal"],"fvn-spacing":["fvn-normal"],"fvn-fraction":["fvn-normal"],"line-clamp":["display","overflow"],rounded:["rounded-s","rounded-e","rounded-t","rounded-r","rounded-b","rounded-l","rounded-ss","rounded-se","rounded-ee","rounded-es","rounded-tl","rounded-tr","rounded-br","rounded-bl"],"rounded-s":["rounded-ss","rounded-es"],"rounded-e":["rounded-se","rounded-ee"],"rounded-t":["rounded-tl","rounded-tr"],"rounded-r":["rounded-tr","rounded-br"],"rounded-b":["rounded-br","rounded-bl"],"rounded-l":["rounded-tl","rounded-bl"],"border-spacing":["border-spacing-x","border-spacing-y"],"border-w":["border-w-s","border-w-e","border-w-t","border-w-r","border-w-b","border-w-l"],"border-w-x":["border-w-r","border-w-l"],"border-w-y":["border-w-t","border-w-b"],"border-color":["border-color-s","border-color-e","border-color-t","border-color-r","border-color-b","border-color-l"],"border-color-x":["border-color-r","border-color-l"],"border-color-y":["border-color-t","border-color-b"],"scroll-m":["scroll-mx","scroll-my","scroll-ms","scroll-me","scroll-mt","scroll-mr","scroll-mb","scroll-ml"],"scroll-mx":["scroll-mr","scroll-ml"],"scroll-my":["scroll-mt","scroll-mb"],"scroll-p":["scroll-px","scroll-py","scroll-ps","scroll-pe","scroll-pt","scroll-pr","scroll-pb","scroll-pl"],"scroll-px":["scroll-pr","scroll-pl"],"scroll-py":["scroll-pt","scroll-pb"],touch:["touch-x","touch-y","touch-pz"],"touch-x":["touch"],"touch-y":["touch"],"touch-pz":["touch"]},conflictingClassGroupModifiers:{"font-size":["leading"]}}},oj=VR(ij);function Ts(...t){return oj(a1(t))}const aj=tR,S1=E.forwardRef(({className:t,...e},n)=>v.jsx(e1,{ref:n,className:Ts("fixed top-0 z-[100] flex max-h-screen w-full flex-col-reverse p-4 sm:bottom-0 sm:right-0 sm:top-auto sm:flex-col md:max-w-[420px]",t),...e}));S1.displayName=e1.displayName;const lj=l1("group pointer-events-auto relative flex w-full items-center justify-between space-x-4 overflow-hidden rounded-md border p-6 pr-8 shadow-lg transition-all data-[swipe=cancel]:translate-x-0 data-[swipe=end]:translate-x-[var(--radix-toast-swipe-end-x)] data-[swipe=move]:translate-x-[var(--radix-toast-swipe-move-x)] data-[swipe=move]:transition-none data-[state=open]:animate-in data-[state=closed]:animate-out data-[swipe=end]:animate-out data-[state=closed]:fade-out-80 data-[state=closed]:slide-out-to-right-full data-[state=open]:slide-in-from-top-full data-[state=open]:sm:slide-in-from-bottom-full",{variants:{variant:{default:"border bg-background text-foreground",destructive:"destructive group border-destructive bg-destructive text-destructive-foreground"}},defaultVariants:{variant:"default"}}),_1=E.forwardRef(({className:t,variant:e,...n},r)=>v.jsx(t1,{ref:r,className:Ts(lj({variant:e}),t),...n}));_1.displayName=t1.displayName;const uj=E.forwardRef(({className:t,...e},n)=>v.jsx(s1,{ref:n,className:Ts("inline-flex h-8 shrink-0 items-center justify-center rounded-md border bg-transparent px-3 text-sm font-medium ring-offset-background transition-colors group-[.destructive]:border-muted/40 hover:bg-secondary group-[.destructive]:hover:border-destructive/30 group-[.destructive]:hover:bg-destructive group-[.destructive]:hover:text-destructive-foreground focus:outline-none focus:ring-2 focus:ring-ring focus:ring-offset-2 group-[.destructive]:focus:ring-destructive disabled:pointer-events-none disabled:opacity-50",t),...e}));uj.displayName=s1.displayName;const E1=E.forwardRef(({className:t,...e},n)=>v.jsx(i1,{ref:n,className:Ts("absolute right-2 top-2 rounded-md p-1 text-foreground
vendor: 4,141 bytes, line 264
264/50 opacity-0 transition-opacity group-hover:opacity-100 group-[.destructive]:text-red-300 hover:text-foreground group-[.destructive]:hover:text-red-50 focus:opacity-100 focus:outline-none focus:ring-2 group-[.destructive]:focus:ring-red-400 group-[.destructive]:focus:ring-offset-red-600",t),"toast-close":"",...e,children:v.jsx(g1,{className:"h-4 w-4"})}));E1.displayName=i1.displayName;const T1=E.forwardRef(({className:t,...e},n)=>v.jsx(n1,{ref:n,className:Ts("text-sm font-semibold",t),...e}));T1.displayName=n1.displayName;const k1=E.forwardRef(({className:t,...e},n)=>v.jsx(r1,{ref:n,className:Ts("text-sm opacity-90",t),...e}));k1.displayName=r1.displayName;function cj(){const{toasts:t}=sA();return v.jsxs(aj,{children:[t.map(function({id:e,title:n,description:r,action:o,...a}){return v.jsxs(_1,{...a,children:[v.jsxs("div",{className:"grid gap-1",children:[n&&v.jsx(T1,{children:n}),r&&v.jsx(k1,{children:r})]}),o,v.jsx(E1,{})]},e)}),v.jsx(S1,{})]})}var dj=jc[" useId ".trim().toString()]||(()=>{}),hj=0;function fj(t){const[e,n]=E.useState(dj());return Pr(()=>{n(r=>r??String(hj++))},[t]),e?`radix-${e}`:""}const pj=["top","right","bottom","left"],bs=Math.min,tn=Math.max,pc=Math.round,Bu=Math.floor,ar=t=>({x:t,y:t}),mj={left:"right",right:"left",bottom:"top",top:"bottom"};function ip(t,e,n){return tn(t,bs(e,n))}function Ar(t,e){return typeof t=="function"?t(e):t}function Rr(t){return t.split("-")[0]}function No(t){return t.split("-")[1]}function lm(t){return t==="x"?"y":"x"}function um(t){return t==="y"?"height":"width"}function or(t){const e=t[0];return e==="t"||e==="b"?"y":"x"}function cm(t){return lm(or(t))}function gj(t,e,n){n===void 0&&(n=!1);const r=No(t),o=cm(t),a=um(o);let l=o==="x"?r===(n?"end":"start")?"right":"left":r==="start"?"bottom":"top";return e.reference[a]>e.floating[a]&&(l=mc(l)),[l,mc(l)]}function yj(t){const e=mc(t);return[op(t),e,op(e)]}function op(t){return t.includes("start")?t.replace("start","end"):t.replace("end","start")}const P0=["left","right"],A0=["right","left"],vj=["top","bottom"],wj=["bottom","top"];function xj(t,e,n){switch(t){case"top":case"bottom":return n?e?A0:P0:e?P0:A0;case"left":case"right":return e?vj:wj;default:return[]}}function bj(t,e,n,r){const o=No(t);let a=xj(Rr(t),n==="start",r);return o&&(a=a.map(l=>l+"-"+o),e&&(a=a.concat(a.map(op)))),a}function mc(t){const e=Rr(t);return mj[e]+t.slice(e.length)}function Sj(t){return{top:0,right:0,bottom:0,left:0,...t}}function C1(t){return typeof t!="number"?Sj(t):{top:t,right:t,bottom:t,left:t}}function gc(t){const{x:e,y:n,width:r,height:o}=t;return{width:r,height:o,top:n,left:e,right:e+r,bottom:n+o,x:e,y:n}}function R0(t,e,n){let{reference:r,floating:o}=t;const a=or(e),l=cm(e),c=um(l),d=Rr(e),f=a==="y",p=r.x+r.width/2-o.width/2,g=r.y+r.height/2-o.height/2,x=r[c]/2-o[c]/2;let y;switch(d){case"top":y={x:p,y:r.y-o.height};break;case"bottom":y={x:p,y:r.y+r.height};break;case"right":y={x:r.x+r.width,y:g};break;case"left":y={x:r.x-o.width,y:g};break;default:y={x:r.x,y:r.y}}switch(No(e)){case"start":y[l]-=x*(n&&f?-1:1);break;case"end":y[l]+=x*(n&&f?-1:1);break}return y}async function _j(t,e){var n;e===void 0&&(e={});const{x:r,y:o,platform:a,rects:l,elements:c,strategy:d}=t,{boundary:f="clippingAncestors",rootBoundary:p="viewport",elementContext:g="floating",altBoundary:x=!1,padding:y=0}=Ar(e,t),_=C1(y),b=c[x?g==="floating"?"reference":"floating":g],k=gc(await a.getClippingRect({element:(n=await(a.isElement==null?void 0:a.isElement(b)))==null||n?b:b.contextElement||await(a.getDocumentElement==null?void 0:a.getDocumentElement(c.floating)),boundary:f,rootBoundary:p,strategy:d})),P=g==="floating"?{x:r,y:o,width:l.floating.width,height:l.floating.height}:l.reference,C=await(a.getOffsetParent==null?void 0:a.getOffsetParent(c.floating)),A=await(a.isElement==null?void 0:a.isElement(C))?await(a.getScale==null?void 0:a.getScale(C))||{x:1,y:1}:{x:1,y:1},L=gc(a.convertOffsetParentRelativeRectToViewportRelativeRect?await a.convertOffsetParentRelativeRectToViewportRelativeRect({elements:c,rect:P,offsetParent:C,strategy:d}):P);return{top:(k.top-L.top+_.top)/A.y,bottom:(L.bottom-k.bottom+_.bottom)/A.y,left
vendor: 8,985 bytes, line 264
264:(k.left-L.left+_.left)/A.x,right:(L.right-k.right+_.right)/A.x}}const Ej=50,Tj=async(t,e,n)=>{const{placement:r="bottom",strategy:o="absolute",middleware:a=[],platform:l}=n,c=l.detectOverflow?l:{...l,detectOverflow:_j},d=await(l.isRTL==null?void 0:l.isRTL(e));let f=await l.getElementRects({reference:t,floating:e,strategy:o}),{x:p,y:g}=R0(f,r,d),x=r,y=0;const _={};for(let S=0;S<a.length;S++){const b=a[S];if(!b)continue;const{name:k,fn:P}=b,{x:C,y:A,data:L,reset:D}=await P({x:p,y:g,initialPlacement:r,placement:x,strategy:o,middlewareData:_,rects:f,platform:c,elements:{reference:t,floating:e}});p=C??p,g=A??g,_[k]={..._[k],...L},D&&y<Ej&&(y++,typeof D=="object"&&(D.placement&&(x=D.placement),D.rects&&(f=D.rects===!0?await l.getElementRects({reference:t,floating:e,strategy:o}):D.rects),{x:p,y:g}=R0(f,x,d)),S=-1)}return{x:p,y:g,placement:x,strategy:o,middlewareData:_}},kj=t=>({name:"arrow",options:t,async fn(e){const{x:n,y:r,placement:o,rects:a,platform:l,elements:c,middlewareData:d}=e,{element:f,padding:p=0}=Ar(t,e)||{};if(f==null)return{};const g=C1(p),x={x:n,y:r},y=cm(o),_=um(y),S=await l.getDimensions(f),b=y==="y",k=b?"top":"left",P=b?"bottom":"right",C=b?"clientHeight":"clientWidth",A=a.reference[_]+a.reference[y]-x[y]-a.floating[_],L=x[y]-a.reference[y],D=await(l.getOffsetParent==null?void 0:l.getOffsetParent(f));let V=D?D[C]:0;(!V||!await(l.isElement==null?void 0:l.isElement(D)))&&(V=c.floating[C]||a.floating[_]);const z=A/2-L/2,q=V/2-S[_]/2-1,H=bs(g[k],q),te=bs(g[P],q),Z=H,me=V-S[_]-te,J=V/2-S[_]/2+z,fe=ip(Z,J,me),ie=!d.arrow&&No(o)!=null&&J!==fe&&a.reference[_]/2-(J<Z?H:te)-S[_]/2<0,de=ie?J<Z?J-Z:J-me:0;return{[y]:x[y]+de,data:{[y]:fe,centerOffset:J-fe-de,...ie&&{alignmentOffset:de}},reset:ie}}}),Cj=function(t){return t===void 0&&(t={}),{name:"flip",options:t,async fn(e){var n,r;const{placement:o,middlewareData:a,rects:l,initialPlacement:c,platform:d,elements:f}=e,{mainAxis:p=!0,crossAxis:g=!0,fallbackPlacements:x,fallbackStrategy:y="bestFit",fallbackAxisSideDirection:_="none",flipAlignment:S=!0,...b}=Ar(t,e);if((n=a.arrow)!=null&&n.alignmentOffset)return{};const k=Rr(o),P=or(c),C=Rr(c)===c,A=await(d.isRTL==null?void 0:d.isRTL(f.floating)),L=x||(C||!S?[mc(c)]:yj(c)),D=_!=="none";!x&&D&&L.push(...bj(c,S,_,A));const V=[c,...L],z=await d.detectOverflow(e,b),q=[];let H=((r=a.flip)==null?void 0:r.overflows)||[];if(p&&q.push(z[k]),g){const J=gj(o,l,A);q.push(z[J[0]],z[J[1]])}if(H=[...H,{placement:o,overflows:q}],!q.every(J=>J<=0)){var te,Z;const J=(((te=a.flip)==null?void 0:te.index)||0)+1,fe=V[J];if(fe&&(!(g==="alignment"?P!==or(fe):!1)||H.every(U=>or(U.placement)===P?U.overflows[0]>0:!0)))return{data:{index:J,overflows:H},reset:{placement:fe}};let ie=(Z=H.filter(de=>de.overflows[0]<=0).sort((de,U)=>de.overflows[1]-U.overflows[1])[0])==null?void 0:Z.placement;if(!ie)switch(y){case"bestFit":{var me;const de=(me=H.filter(U=>{if(D){const W=or(U.placement);return W===P||W==="y"}return!0}).map(U=>[U.placement,U.overflows.filter(W=>W>0).reduce((W,G)=>W+G,0)]).sort((U,W)=>U[1]-W[1])[0])==null?void 0:me[0];de&&(ie=de);break}case"initialPlacement":ie=c;break}if(o!==ie)return{reset:{placement:ie}}}return{}}}};function j0(t,e){return{top:t.top-e.height,right:t.right-e.width,bottom:t.bottom-e.height,left:t.left-e.width}}function O0(t){return pj.some(e=>t[e]>=0)}const Pj=function(t){return t===void 0&&(t={}),{name:"hide",options:t,async fn(e){const{rects:n,platform:r}=e,{strategy:o="referenceHidden",...a}=Ar(t,e);switch(o){case"referenceHidden":{const l=await r.detectOverflow(e,{...a,elementContext:"reference"}),c=j0(l,n.reference);return{data:{referenceHiddenOffsets:c,referenceHidden:O0(c)}}}case"escaped":{const l=await r.detectOverflow(e,{...a,altBoundary:!0}),c=j0(l,n.floating);return{data:{escapedOffsets:c,escaped:O0(c)}}}default:return{}}}}},P1=new Set(["left","top"]);async function Aj(t,e){const{placement:n,platform:r,elements:o}=t,a=await(r.isRTL==null?void 0:r.isRTL(o.floating)),l=Rr(n),c=No(n),d=or(n)==="y",f=P1.has(l)?-1:1,p=a&&d?-1:1,g=Ar(e,t);let{mainAxis:x,crossAxis:y,alignmentAxis:_}=typeof g=="number"?{mainAxis:g,crossAxis:0,alignmentAxis:null}:{mainAxis:g.mainAxis||0,crossAxis:g.crossAxis||0,alignmentAxis:g.alignmentAxis};return c&&typeof _=="number"&&(y=c==="end"?_*-1:_),d?{x:y*p,y:x*f}:{x:x*f,y:y*p}}const Rj=function(t){return t===void 0&&(t=0),{name:"offset",options:t,async fn(e){var n,r;const{x:o,y:a,placement:l,middlewareData:c}=e,d=await Aj(e,t);return l===((n=c.offset)==null?void 0:n.placement)&&(r=c.arrow)!=null&&r.alignmentOffset?{}:{x:o+d.x,y:a+d.y,data:{...d,placement:l}}}}},jj=function(t){return t===void 0&&(t={}),{name:"shift",options:t,async fn(e){const{x:n,y:r,placement:o,platform:a}=e,{mainAxis:l=!0,crossAxis:c=!1,limiter:d={fn:k=>{let{x:P,y:C}=k;return{x:P,y:C}}},...f}=Ar(t,e),p={x:n,y:r},g=await a.detectOverflow(e,f),x=or(Rr(o)),y=lm(x);let _=p[y],S=p[x];if(l){const k=y==="y"?"top":"left",P=y==="y"?"bottom":"right",C=_+g[k],A=_-g[P];_=ip(C,_,A)}if(c){const k=x==="y"?"top":"left",P=x==="y"?"bottom":"right",C=S+g[k],A=S-g[P];S=ip(C,S,A)}const b=d.fn({...e,[y]:_,[x]:S});return{...b,data:{x:b.x-n,y:b.y-r,enabled:{[y]:l,[x]:c}}}}}},Oj=function(t){return t===void 0&&(t={}),{options:t,fn(e){const{x:n,y:r,placement:o,rects:a,middlewareData:l}=e,{offset:c=0,mainAxis:d=!0,crossAxis:f=!0}=Ar(t,e),p={x:n,y:r},g=or(o),x=lm(g);let y=p[x],_=p[g];const S=Ar(c,e),b=typeof S=="number"?{mainAxis:S,crossAxis:0}:{mainAxis:0,crossAxis:0,...S};if(d){const C=x==="y"?"height":"width",A=a.reference[x]-a.floating[C]+b.mainAxis,L=a.reference[x]+a.reference[C]-b.mainAxis;y<A?y=A:y>L&&(y=L)}if(f){var k,P;const C=x==="y"?"width":"height",A=P1.has(Rr(o)),L=a.reference[g]-a.floating[C]+(A&&((k=l.offset)==null?void 0:k[g])||0)+(A?0:b.crossAxis),D=a.reference[g]+a.reference[C]+(A?0:((P=l.offset)==null?void 0:P[g])||0)-(A?b.crossAxis:0);_<L?_=L:_>D&&(_=D)}return{[x]:y,[g]:_}}}},Nj=function(t){return t===void 0&&(t={}),{name:"size",options:t,async fn(e){var n,r;const{placement:o,rects:a,platform:l,elements:c}=e,{apply:d=()=>{},...f}=Ar(t,e),p=await l.detectOverflow(e,f),g=Rr(o),x=No(o),y=or(o)==="y",{width:_,height:S}=a.floating;let b,k;g==="top"||g==="bottom"?(b=g,k=x===(await(l.isRTL==null?void 0:l.isRTL(c.floating))?"start":"end")?"left":"right"):(k=g,b=x==="end"?"top":"bottom");const P=S-p.top-p.bottom,C=_-p.left-p.right,A=bs(S-p[b],P),L=bs(_-p[k],C),D=!e.middlewareData.shift;let V=A,z=L;if((n=e.middlewareData.shift)!=null&&n.enabled.x&&(z=C),(r=e.middlewareData.shift)!=null&&r.enabled.y&&(V=P),D&&!x){const H=tn(p.left,0),te=tn(p.right,0),Z=tn(p.top,0),me=tn(p.bottom,0);y?z=_-2*(H!==0||te!==0?H+te:tn(p.left,p.right)):V=S-2*(Z!==0||me!==0?Z+me:tn(p.top,p.bottom))}await d({...e,availableWidth:z,availableHeight:V});const q=await l.getDimensions(c.floating);return _!==q.width||S!==q.height?{reset:{rects:!0}}:{}}}};function Uc(){return typeof window<"u"}function Io(t){return A1(t)?(t.nodeName||"").toLowerCase():"#document"}function rn(t){var e;return(t==null||(e=t.ownerDocument)==null?void 0:e.defaultView)||window}function cr(t){var e;return(e=(A1(t)?t.ownerDocument:t.document)||window.document)==null?void 0:e.documentElement}function A1(t){return Uc()?t instanceof Node||t instanceof rn(t).Node:!1}function Vn(t){return Uc()?t instanceof Element||t instanceof rn(t).Element:!1}function jr(t){return Uc()?t instanceof HTMLElement||t instanceof rn(t).HTMLElement:!1}function N0(t){return!Uc()||typeof ShadowRoot>"u"?!1:t instanceof ShadowRoot||t instanceof rn(t).ShadowRoot}function ml(t){const{overflow:e,overflowX:n,overflowY:r,display:o}=Bn(t);return/auto|scroll|overlay|hidden|clip/.test(e+r+n)&&o!=="inline"&&o!=="contents"}function Ij(t){return/^(table|td|th)$/.test(Io(t))}function Vc(t){try{if(t.matches(":popover-open"))return!0}catch{}try{return t.matches(":modal")}catch{return!1}}const Lj=/transform|translate|scale|rotate|perspective|filter/,Dj=/paint|layout|strict|content/,Ws=t=>!!t&&t!=="none";let tf;function dm(t){const e=Vn(t)?Bn(t):t;return Ws(e.transform)||Ws(e.translate)||Ws(e.scale)||Ws(e.rotate)||Ws(e.perspective)||!hm()&&(Ws(e.backdropFilter)||Ws(e.filter))||Lj.test(e.willChange||"")||Dj.test(e.contain||"")}function Mj(t){let e=Ss(t);for(;jr(e)&&!ko(e);){if(dm(e))return e;if(Vc(e))return null;e=Ss(e)}return null}function hm(){return tf==null&&(tf=typeof CSS<"u"&&CSS.supports&&CSS.supports("-webkit-backdrop-filter","none")),tf}function ko(t){return/^(html|body|#document)$/.test(Io(t))}function Bn(t){return rn(t).getComputedStyle(t)}function Bc(t){return Vn(t)?{scrollLeft:t.scrollLeft,scrollTop:t.scrollTop}:{scrollLeft:t.scrollX,scrollTop:t.scrollY}}function Ss(t){if(Io(t)==="html")return t;const e=t.assignedSlot||t.parentNode||N0(t)&&t.host||cr(t);return N0(e)?e.host:e}function R1(t){const e=Ss(t);return ko(e)?t.ownerDocument?t.ownerDocument.body:t.body:jr(e)&&ml(e)?e:R1(e)}function Ha(t,e,n){var r;e===void 0&&(e=[]),n===void 0&&(n=!0);const o=R1(t),a=o===((r=t.ownerDocument)==null?void 0:r.body),l=rn(o);if(a){const c=ap(l);
vendor: 14,406 bytes, line 264
264return e.concat(l,l.visualViewport||[],ml(o)?o:[],c&&n?Ha(c):[])}else return e.concat(o,Ha(o,[],n))}function ap(t){return t.parent&&Object.getPrototypeOf(t.parent)?t.frameElement:null}function j1(t){const e=Bn(t);let n=parseFloat(e.width)||0,r=parseFloat(e.height)||0;const o=jr(t),a=o?t.offsetWidth:n,l=o?t.offsetHeight:r,c=pc(n)!==a||pc(r)!==l;return c&&(n=a,r=l),{width:n,height:r,$:c}}function fm(t){return Vn(t)?t:t.contextElement}function ho(t){const e=fm(t);if(!jr(e))return ar(1);const n=e.getBoundingClientRect(),{width:r,height:o,$:a}=j1(e);let l=(a?pc(n.width):n.width)/r,c=(a?pc(n.height):n.height)/o;return(!l||!Number.isFinite(l))&&(l=1),(!c||!Number.isFinite(c))&&(c=1),{x:l,y:c}}const $j=ar(0);function O1(t){const e=rn(t);return!hm()||!e.visualViewport?$j:{x:e.visualViewport.offsetLeft,y:e.visualViewport.offsetTop}}function Fj(t,e,n){return e===void 0&&(e=!1),!n||e&&n!==rn(t)?!1:e}function yi(t,e,n,r){e===void 0&&(e=!1),n===void 0&&(n=!1);const o=t.getBoundingClientRect(),a=fm(t);let l=ar(1);e&&(r?Vn(r)&&(l=ho(r)):l=ho(t));const c=Fj(a,n,r)?O1(a):ar(0);let d=(o.left+c.x)/l.x,f=(o.top+c.y)/l.y,p=o.width/l.x,g=o.height/l.y;if(a){const x=rn(a),y=r&&Vn(r)?rn(r):r;let _=x,S=ap(_);for(;S&&r&&y!==_;){const b=ho(S),k=S.getBoundingClientRect(),P=Bn(S),C=k.left+(S.clientLeft+parseFloat(P.paddingLeft))*b.x,A=k.top+(S.clientTop+parseFloat(P.paddingTop))*b.y;d*=b.x,f*=b.y,p*=b.x,g*=b.y,d+=C,f+=A,_=rn(S),S=ap(_)}}return gc({width:p,height:g,x:d,y:f})}function zc(t,e){const n=Bc(t).scrollLeft;return e?e.left+n:yi(cr(t)).left+n}function N1(t,e){const n=t.getBoundingClientRect(),r=n.left+e.scrollLeft-zc(t,n),o=n.top+e.scrollTop;return{x:r,y:o}}function Uj(t){let{elements:e,rect:n,offsetParent:r,strategy:o}=t;const a=o==="fixed",l=cr(r),c=e?Vc(e.floating):!1;if(r===l||c&&a)return n;let d={scrollLeft:0,scrollTop:0},f=ar(1);const p=ar(0),g=jr(r);if((g||!g&&!a)&&((Io(r)!=="body"||ml(l))&&(d=Bc(r)),g)){const y=yi(r);f=ho(r),p.x=y.x+r.clientLeft,p.y=y.y+r.clientTop}const x=l&&!g&&!a?N1(l,d):ar(0);return{width:n.width*f.x,height:n.height*f.y,x:n.x*f.x-d.scrollLeft*f.x+p.x+x.x,y:n.y*f.y-d.scrollTop*f.y+p.y+x.y}}function Vj(t){return Array.from(t.getClientRects())}function Bj(t){const e=cr(t),n=Bc(t),r=t.ownerDocument.body,o=tn(e.scrollWidth,e.clientWidth,r.scrollWidth,r.clientWidth),a=tn(e.scrollHeight,e.clientHeight,r.scrollHeight,r.clientHeight);let l=-n.scrollLeft+zc(t);const c=-n.scrollTop;return Bn(r).direction==="rtl"&&(l+=tn(e.clientWidth,r.clientWidth)-o),{width:o,height:a,x:l,y:c}}const I0=25;function zj(t,e){const n=rn(t),r=cr(t),o=n.visualViewport;let a=r.clientWidth,l=r.clientHeight,c=0,d=0;if(o){a=o.width,l=o.height;const p=hm();(!p||p&&e==="fixed")&&(c=o.offsetLeft,d=o.offsetTop)}const f=zc(r);if(f<=0){const p=r.ownerDocument,g=p.body,x=getComputedStyle(g),y=p.compatMode==="CSS1Compat"&&parseFloat(x.marginLeft)+parseFloat(x.marginRight)||0,_=Math.abs(r.clientWidth-g.clientWidth-y);_<=I0&&(a-=_)}else f<=I0&&(a+=f);return{width:a,height:l,x:c,y:d}}function Wj(t,e){const n=yi(t,!0,e==="fixed"),r=n.top+t.clientTop,o=n.left+t.clientLeft,a=jr(t)?ho(t):ar(1),l=t.clientWidth*a.x,c=t.clientHeight*a.y,d=o*a.x,f=r*a.y;return{width:l,height:c,x:d,y:f}}function L0(t,e,n){let r;if(e==="viewport")r=zj(t,n);else if(e==="document")r=Bj(cr(t));else if(Vn(e))r=Wj(e,n);else{const o=O1(t);r={x:e.x-o.x,y:e.y-o.y,width:e.width,height:e.height}}return gc(r)}function I1(t,e){const n=Ss(t);return n===e||!Vn(n)||ko(n)?!1:Bn(n).position==="fixed"||I1(n,e)}function Hj(t,e){const n=e.get(t);if(n)return n;let r=Ha(t,[],!1).filter(c=>Vn(c)&&Io(c)!=="body"),o=null;const a=Bn(t).position==="fixed";let l=a?Ss(t):t;for(;Vn(l)&&!ko(l);){const c=Bn(l),d=dm(l);!d&&c.position==="fixed"&&(o=null),(a?!d&&!o:!d&&c.position==="static"&&!!o&&(o.position==="absolute"||o.position==="fixed")||ml(l)&&!d&&I1(t,l))?r=r.filter(p=>p!==l):o=c,l=Ss(l)}return e.set(t,r),r}function qj(t){let{element:e,boundary:n,rootBoundary:r,strategy:o}=t;const l=[...n==="clippingAncestors"?Vc(e)?[]:Hj(e,this._c):[].concat(n),r],c=L0(e,l[0],o);let d=c.top,f=c.right,p=c.bottom,g=c.left;for(let x=1;x<l.length;x++){const y=L0(e,l[x],o);d=tn(y.top,d),f=bs(y.right,f),p=bs(y.bottom,p),g=tn(y.left,g)}return{width:f-g,height:p-d,x:g,y:d}}function Kj(t){const{width:e,height:n}=j1(t);return{width:e,height:n}}function Gj(t,e,n){const r=jr(e),o=cr(e),a=n==="fixed",l=yi(t,!0,a,e);let c={scrollLeft:0,scrollTop:0};const d=ar(0);function f(){d.x=zc(o)}if(r||!r&&!a)if((Io(e)!=="body"||ml(o))&&(c=Bc(e)),r){const y=yi(e,!0,a,e);d.x=y.x+e.clientLeft,d.y=y.y+e.clientTop}else o&&f();a&&!r&&o&&f();const p=o&&!r&&!a?N1(o,c):ar(0),g=l.left+c.scrollLeft-d.x-p.x,x=l.top+c.scrollTop-d.y-p.y;return{x:g,y:x,width:l.width,height:l.height}}function nf(t){return Bn(t).position==="static"}function D0(t,e){if(!jr(t)||Bn(t).position==="fixed")return null;if(e)return e(t);let n=t.offsetParent;return cr(t)===n&&(n=n.ownerDocument.body),n}function L1(t,e){const n=rn(t);if(Vc(t))return n;if(!jr(t)){let o=Ss(t);for(;o&&!ko(o);){if(Vn(o)&&!nf(o))return o;o=Ss(o)}return n}let r=D0(t,e);for(;r&&Ij(r)&&nf(r);)r=D0(r,e);return r&&ko(r)&&nf(r)&&!dm(r)?n:r||Mj(t)||n}const Qj=async function(t){const e=this.getOffsetParent||L1,n=this.getDimensions,r=await n(t.floating);return{reference:Gj(t.reference,await e(t.floating),t.strategy),floating:{x:0,y:0,width:r.width,height:r.height}}};function Yj(t){return Bn(t).direction==="rtl"}const Jj={convertOffsetParentRelativeRectToViewportRelativeRect:Uj,getDocumentElement:cr,getClippingRect:qj,getOffsetParent:L1,getElementRects:Qj,getClientRects:Vj,getDimensions:Kj,getScale:ho,isElement:Vn,isRTL:Yj};function D1(t,e){return t.x===e.x&&t.y===e.y&&t.width===e.width&&t.height===e.height}function Xj(t,e){let n=null,r;const o=cr(t);function a(){var c;clearTimeout(r),(c=n)==null||c.disconnect(),n=null}function l(c,d){c===void 0&&(c=!1),d===void 0&&(d=1),a();const f=t.getBoundingClientRect(),{left:p,top:g,width:x,height:y}=f;if(c||e(),!x||!y)return;const _=Bu(g),S=Bu(o.clientWidth-(p+x)),b=Bu(o.clientHeight-(g+y)),k=Bu(p),C={rootMargin:-_+"px "+-S+"px "+-b+"px "+-k+"px",threshold:tn(0,bs(1,d))||1};let A=!0;function L(D){const V=D[0].intersectionRatio;if(V!==d){if(!A)return l();V?l(!1,V):r=setTimeout(()=>{l(!1,1e-7)},1e3)}V===1&&!D1(f,t.getBoundingClientRect())&&l(),A=!1}try{n=new IntersectionObserver(L,{...C,root:o.ownerDocument})}catch{n=new IntersectionObserver(L,C)}n.observe(t)}return l(!0),a}function Zj(t,e,n,r){r===void 0&&(r={});const{ancestorScroll:o=!0,ancestorResize:a=!0,elementResize:l=typeof ResizeObserver=="function",layoutShift:c=typeof IntersectionObserver=="function",animationFrame:d=!1}=r,f=fm(t),p=o||a?[...f?Ha(f):[],...e?Ha(e):[]]:[];p.forEach(k=>{o&&k.addEventListener("scroll",n,{passive:!0}),a&&k.addEventListener("resize",n)});const g=f&&c?Xj(f,n):null;let x=-1,y=null;l&&(y=new ResizeObserver(k=>{let[P]=k;P&&P.target===f&&y&&e&&(y.unobserve(e),cancelAnimationFrame(x),x=requestAnimationFrame(()=>{var C;(C=y)==null||C.observe(e)})),n()}),f&&!d&&y.observe(f),e&&y.observe(e));let _,S=d?yi(t):null;d&&b();function b(){const k=yi(t);S&&!D1(S,k)&&n(),S=k,_=requestAnimationFrame(b)}return n(),()=>{var k;p.forEach(P=>{o&&P.removeEventListener("scroll",n),a&&P.removeEventListener("resize",n)}),g==null||g(),(k=y)==null||k.disconnect(),y=null,d&&cancelAnimationFrame(_)}}const eO=Rj,tO=jj,nO=Cj,rO=Nj,sO=Pj,M0=kj,iO=Oj,oO=(t,e,n)=>{const r=new Map,o={platform:Jj,...n},a={...o.platform,_c:r};return Tj(t,e,{...o,platform:a})};var aO=typeof document<"u",lO=function(){},sc=aO?E.useLayoutEffect:lO;function yc(t,e){if(t===e)return!0;if(typeof t!=typeof e)return!1;if(typeof t=="function"&&t.toString()===e.toString())return!0;let n,r,o;if(t&&e&&typeof t=="object"){if(Array.isArray(t)){if(n=t.length,n!==e.length)return!1;for(r=n;r--!==0;)if(!yc(t[r],e[r]))return!1;return!0}if(o=Object.keys(t),n=o.length,n!==Object.keys(e).length)return!1;for(r=n;r--!==0;)if(!{}.hasOwnProperty.call(e,o[r]))return!1;for(r=n;r--!==0;){const a=o[r];if(!(a==="_owner"&&t.$$typeof)&&!yc(t[a],e[a]))return!1}return!0}return t!==t&&e!==e}function M1(t){return typeof window>"u"?1:(t.ownerDocument.defaultView||window).devicePixelRatio||1}function $0(t,e){const n=M1(t);return Math.round(e*n)/n}function rf(t){const e=E.useRef(t);return sc(()=>{e.current=t}),e}function uO(t){t===void 0&&(t={});const{placement:e="bottom",strategy:n="absolute",middleware:r=[],platform:o,elements:{reference:a,floating:l}={},transform:c=!0,whileElementsMounted:d,open:f}=t,[p,g]=E.useState({x:0,y:0,strategy:n,placement:e,middlewareData:{},isPositioned:!1}),[x,y]=E.useState(r);yc(x,r)||y(r);const[_,S]=E.useState(null),[b,k]=E.useState(null),P=E.useCallback(U=>{U!==D.current&&(D.current=U,S(U))},[]),C=E.useCallback(U=>{U!==V.current&&(V.current=U,k(U))},[]),A=a||_,L=l||b,D=E.useRef(null),V=E.useRef(null),z=E.useRef(p),q=d!=null,H=rf(d),te=rf(o),Z=rf(f),me=E.useCallback(()=>{if(!D.current||!V.current)return;const U={placement:e,strategy:n,middleware:x};te.current&&(U.platform=te.current),oO(D.current,V.current,U).then(W=>{const G={...W,isPositioned:Z.current!==!1};J.current&&!yc(z.current,G)&&(z.current=G,Nc.flushSync(()=>{g(G)}))})},[x,e,n,te,Z]);sc(()=>{f===!1&&z.current.isPositioned&&(z.current.isPositioned=!1,g(U=>({...U,isPositioned:!1})))},[f]);const J=E.useRef(!1);sc(()=>(J.current=!0,()=>{J.current=!1}),[]),sc(()=>{if(A&&(D.current=A),L&&(V.current=L),A&&L){if(H.current)return H.current(A,L,me);me()}},[A,L,me,H,q]);const fe=E.useMemo(()=>({reference:D,floating:V,setReference:P,setFloating:C}),[P,C]),ie=E.useMemo(()=>({reference:A,floating:L}),[A,L]),de=E.useMemo(()=>{const U={position:n,left:0,top:0};if(!ie.floating)return U;const W=$0(ie.floating,p.x),G=$0(ie.floating,p.y);return c?{...U,transform:"translate("+W+"px, "+G+"px)",...M1(ie.floating)>=1.5&&{willChange:"transform"}}:{position:n,left:W,top:G}},[n,c,ie.floating,p.x,p.y]);return E.useMemo(()=>({...p,update:me,refs:fe,elements:ie,floatingStyles:de}),[p,me,fe,ie,de])}const cO=t=>{function e(n){return{}.hasOwnProperty.call(n,"current")}return{name:"arrow",options:t,fn(n){const{element:r,padding:o}=typeof t=="function"?t(n):t;return r&&e(r)?r.current!=null?M0({element:r.current,padding:o}).fn(n):{}:r?M0({element:r,padding:o}).fn(n):{}}}},dO=(t,e)=>{const n=eO(t);return{name:n.name,fn:n.fn,options:[t,e]}},hO=(t,e)=>{const n=tO(t);return{name:n.name,fn:n.fn,options:[t,e]}},fO=(t,e)=>({fn:iO(t).fn,options:[t,e]}),pO=(t,e)=>{const n=nO(t);return{name:n.name,fn:n.fn,options:[t,e]}},mO=(t,e)=>{const n=rO(t);return{name:n.name,fn:n.fn,options:[t,e]}},gO=(t,e)=>{const n=sO(t);return{name:n.name,fn:n.fn,options:[t,e]}},yO=(t,e)=>{const n=cO(t);return{name:n.name,fn:n.fn,options:[t,e]}};var vO="Arrow",$1=E.forwardRef((t,e)=>{const{children:n,width:r=10,height:o=5,...a}=t;return v.jsx(Kt.svg,{...a,ref:e,width:r,height:o,viewBox:"0 0 30 10",preserveAspectRatio:"none",children:t.asChild?n:v.jsx("polygon",{points:"0,0 30,0 15,10"})})});$1.displayName=vO;var wO=$1;function xO(t){const[e,n]=E.useState(void 0);return Pr(()=>{if(t){n({width:t.offsetWidth,height:t.offsetHeight});const r=new ResizeObserver(o=>{if(!Array.isArray(o)||!o.length)return;const a=o[0];let l,c;if("borderBoxSize"in a){const d=a.borderBoxSize,f=Array.isArray(d)?d[0]:d;l=f.inlineSize,c=f.blockSize}else l=t.offsetWidth,c=t.offsetHeight;n({width:l,height:c})});return r.observe(t,{box:"border-box"}),()=>r.unobserve(t)}else n(void 0)},[t]),e}var pm="Popper",[F1,U1]=Dc(pm),[bO,V1]=F1(pm),B1=t=>{const{__scopePopper:e,children:n}=t,[r,o]=E.useState(null);return v.jsx(bO,{scope:e,anchor:r,onAnchorChange:o,children:n})};B1.displayName=pm;var z1="PopperAnchor",W1=E.forwardRef((t,e)=>{const{__scopePopper:n,virtualRef:r,...o}=t,a=V1(z1,n),l=E.useRef(null),c=Un(e,l),d=E.useRef(null);return E.useEffect(()=>{const f=d.current;d.current=(r==null?void 0:r.current)||l.current,f!==d.current&&a.onAnchorChange(d.current)}),r?null:v.jsx(Kt.div,{...o,ref:c})});W1.displayName=z1;var mm="PopperContent",[SO,_O]=F1(mm),H1=E.forwardRef((t,e)=>{var ye,Ae,Ne,et,Gt,dr;const{__scopePopper:n,side:r="bottom",sideOffset:o=0,align:a="center",alignOffset:l=0,arrowPadding:c=0,avoidCollisions:d=!0,collisionBoundary:f=[],collisionPadding:p=0,sticky:g="partial",hideWhenDetached:x=!1,updatePositionStrategy:y="optimized",onPlaced:_,...S}=t,b=V1(mm,n),[k,P]=E.useState(null),C=Un(e,Qt=>P(Qt)),[A,L]=E.useState(null),D=xO(A),V=(D==null?void 0:D.width)??0,z=(D==null?void 0:D.height)??0,q=r+(a!=="center"?"-"+a:""),H=typeof p=="number"?p:{top:0,right:0,bottom:0,left:0,...p},te=Array.isArray(f)?f:[f],Z=te.length>0,me={padding:H,boundary:te.filter(TO),altBoundary:Z},{refs:J,floatingStyles:fe,placement:ie,isPositioned:de,middlewareData:U}=uO({strategy:"fixed",placement:q,whileElementsMounted:(...Qt)=>Zj(...Qt,{animationFrame:y==="always"}),elements:{reference:b.anchor},middleware:[dO({mainAxis:o+z,alignmentAxis:l}),d&&hO({mainAxis:!0,crossAxis:!1,limiter:g==="partial"?fO():void 0,...me}),d&&pO({...me}),mO({...me,apply:({elements:Qt,rects:Nr,availableWidth:wi,availableHeight:Cs})=>{const{width:Ps,height:Ir}=Nr.reference,zn=Qt.floating.style;zn.setProperty("--radix-popper-available-width",`${wi}px`),zn.setProperty("--radix-popper-available-height",`${Cs}px`),zn.setProperty("--radix-popper-anchor-width",`${Ps}px`),zn.setProperty("--radix-popper-anchor-height",`${Ir}px`)}}),A&&yO({element:A,padding:c}),kO({arrowWidth:V,arrowHeight:z}),x&&gO({strategy:"referenceHidden",...me})]}),[W,G]=G1(ie),N=xs(_);Pr(()=>{de&&(N==null||N())},[de,N]);const B=(ye=U.arrow)==null?void 0:ye.x,ne=(Ae=U.arrow)==null?void 0:Ae.y,oe=((Ne=U.arrow)==null?void 0:Ne.centerOffset)!==0,[_e,ke]=E.useState();return Pr(()=>{k&&ke(window.getComputedStyle(k).zIndex)},[k]),v.jsx("div",{ref:J.setFloating,"data-radix-popper-content-wrapper":"",style:{...fe,transform:de?fe.transform:"translate(0, -200%)",minWidth:"max-content",zIndex:_e,"--radix-popper-transform-origin":[(et=U.transformOrigin)==null?void 0:et.x,(Gt=U.transformOrigin)==null?void 0:Gt.y].join(" "),...((dr=U.hide)==null?void 0:dr.referenceHidden)&&{visibility:"hidden",pointerEvents:"none"}},dir:t.dir,children:v.jsx(SO,{scope:n,placedSide:W,onArrowChange:L,arrowX:B,arrowY:ne,shouldHideArrow:oe,children:v.jsx(Kt.div,{"data-side":W,"data-align":G,...S,ref:C,style:{...S.style,animation:de?void 0:"none"}})})})});H1.displayName=mm;var q1="PopperArrow",EO={top:"bottom",right:"left",bottom:"top",left:"r
264ight"},K1=E.forwardRef(function(e,n){const{__scopePopper:r,...o}=e,a=_O(q1,r),l=EO[a.placedSide];return v.jsx("span",{ref:a.onArrowChange,style:{position:"absolute",left:a.arrowX,top:a.arrowY,[l]:0,transformOrigin:{top:"",right:"0 0",bottom:"center 0",left:"100% 0"}[a.placedSide],transform:{top:"translateY(100%)",right:"translateY(50%) rotate(90deg) translateX(-50%)",bottom:"rotate(180deg)",left:"translateY(50%) rotate(-90deg) translateX(50%)"}[a.placedSide],visibility:a.shouldHideArrow?"hidden":void 0},children:v.jsx(wO,{...o,ref:n,style:{...o.style,display:"block"}})})});K1.displayName=q1;function TO(t){return t!==null}var kO=t=>({name:"transformOrigin",options:t,fn(e){var b,k,P;const{placement:n,rects:r,middlewareData:o}=e,l=((b=o.arrow)==null?void 0:b.centerOffset)!==0,c=l?0:t.arrowWidth,d=l?0:t.arrowHeight,[f,p]=G1(n),g={start:"0%",center:"50%",end:"100%"}[p],x=(((k=o.arrow)==null?void 0:k.x)??0)+c/2,y=(((P=o.arrow)==null?void 0:P.y)??0)+d/2;let _="",S="";return f==="bottom"?(_=l?g:`${x}px`,S=`${-d}px`):f==="top"?(_=l?g:`${x}px`,S=`${r.floating.height+d}px`):f==="right"?(_=`${-d}px`,S=l?g:`${y}px`):f==="left"&&(_=`${r.floating.width+d}px`,S=l?g:`${y}px`),{data:{x:_,y:S}}}});function G1(t){const[e,n="center"]=t.split("-");return[e,n]}var CO=B1,PO=W1,AO=H1,RO=K1,jO=Symbol("radix.slottable");function OO(t){const e=({children:n})=>v.jsx(v.Fragment,{children:n});return e.displayName=`${t}.Slottable`,e.__radixId=jO,e}var[Wc]=Dc("Tooltip",[U1]),Hc=U1(),Q1="TooltipProvider",NO=700,lp="tooltip.open",[IO,gm]=Wc(Q1),Y1=t=>{const{__scopeTooltip:e,delayDuration:n=NO,skipDelayDuration:r=300,disableHoverableContent:o=!1,children:a}=t,l=E.useRef(!0),c=E.useRef(!1),d=E.useRef(0);return E.useEffect(()=>{const f=d.current;return()=>window.clearTimeout(f)},[]),v.jsx(IO,{scope:e,isOpenDelayedRef:l,delayDuration:n,onOpen:E.useCallback(()=>{window.clearTimeout(d.current),l.current=!1},[]),onClose:E.useCallback(()=>{window.clearTimeout(d.current),d.current=window.setTimeout(()=>l.current=!0,r)},[r]),isPointerInTransitRef:c,onPointerInTransitChange:E.useCallback(f=>{c.current=f},[]),disableHoverableContent:o,children:a})};Y1.displayName=Q1;var qa="Tooltip",[LO,qc]=Wc(qa),J1=t=>{const{__scopeTooltip:e,children:n,open:r,defaultOpen:o,onOpenChange:a,disableHoverableContent:l,delayDuration:c}=t,d=gm(qa,t.__scopeTooltip),f=Hc(e),[p,g]=E.useState(null),x=fj(),y=E.useRef(0),_=l??d.disableHoverableContent,S=c??d.delayDuration,b=E.useRef(!1),[k,P]=Ub({prop:r,defaultProp:o??!1,onChange:V=>{V?(d.onOpen(),document.dispatchEvent(new CustomEvent(lp))):d.onClose(),a==null||a(V)},caller:qa}),C=E.useMemo(()=>k?b.current?"delayed-open":"instant-open":"closed",[k]),A=E.useCallback(()=>{window.clearTimeout(y.current),y.current=0,b.current=!1,P(!0)},[P]),L=E.useCallback(()=>{window.clearTimeout(y.current),y.current=0,P(!1)},[P]),D=E.useCallback(()=>{window.clearTimeout(y.current),y.current=window.setTimeout(()=>{b.current=!0,P(!0),y.current=0},S)},[S,P]);return E.useEffect(()=>()=>{y.current&&(window.clearTimeout(y.current),y.current=0)},[]),v.jsx(CO,{...f,children:v.jsx(LO,{scope:e,contentId:x,open:k,stateAttribute:C,trigger:p,onTriggerChange:g,onTriggerEnter:E.useCallback(()=>{d.isOpenDelayedRef.current?D():A()},[d.isOpenDelayedRef,D,A]),onTriggerLeave:E.useCallback(()=>{_?L():(window.clearTimeout(y.current),y.current=0)},[L,_]),onOpen:A,onClose:L,disableHoverableContent:_,children:n})})};J1.displayName=qa;var up="TooltipTrigger",X1=E.forwardRef((t,e)=>{const{__scopeTooltip:n,...r}=t,o=qc(up,n),a=gm(up,n),l=Hc(n),c=E.useRef(null),d=Un(e,c,o.onTriggerChange),f=E.useRef(!1),p=E.useRef(!1),g=E.useCallback(()=>f.current=!1,[]);return E.useEffect(()=>()=>document.removeEventListener("pointerup",g),[g]),v.jsx(PO,{asChild:!0,...l,children:v.jsx(Kt.button,{"aria-describedby":o.open?o.contentId:void 0,"data-state":o.stateAttribute,...r,ref:d,onPointerMove:dt(t.onPointerMove,x=>{x.pointerType!=="touch"&&!p.current&&!a.isPointerInTransitRef.current&&(o.onTriggerEnter(),p.current=!0)}),onPointerLeave:dt(t.onPointerLeave,()=>{o.onTriggerLeave(),p.current=!1}),onPointerDown:dt(t.onPointerDown,()=>{o.open&&o.onClose(),f.current=!0,document.addEventListener("pointerup",g,{once:!0})}),onFocus:dt(t.onFocus,()=>{f.current||o.onOpen()}),onBlur:dt(t.onBlur,o.onClose),onClick:dt(t.onClick,o.onClose)})})});X1.displayName=up;var DO="TooltipPortal",[s$,MO]=Wc(DO,{forceMount:void 0}),Co="TooltipContent",Z1=E.forwardRef((t,e)=>{const n=MO(Co,t.__scopeTooltip),{forceMount:r=n.forceMount,side:o="top",...a}=t,l=qc(Co,t.__scopeTooltip);return v.jsx(nm,{present:r||l.open,children:l.disableHoverableContent?v.jsx(eS,{side:o,...a,ref:e}):v.jsx($O,{side:o,...a,ref:e})})}),$O=E.forwardRef((t,e)=>{const n=qc(Co,t.__scopeTooltip),r=gm(Co,t.__scopeTooltip),o=E.useRef(null),a=Un(e,o),[l,c]=E.useState(null),{trigger:d,onClose:f}=n,p=o.current,{onPointerInTransitChange:g}=r,x=E.useCallback(()=>{c(null),g(!1)},[g]),y=E.useCallback((_,S)=>{const b=_.currentTarget,k={x:_.clientX,y:_.clientY},P=zO(k,b.getBoundingClientRect()),C=WO(k,P),A=HO(S.getBoundingClientRect()),L=KO([...C,...A]);c(L),g(!0)},[g]);return E.useEffect(()=>()=>x(),[x]),E.useEffect(()=>{if(d&&p){const _=b=>y(b,p),S=b=>y(b,d);return d.addEventListener("pointerleave",_),p.addEventListener("pointerleave",S),()=>{d.removeEventListener("pointerleave",_),p.removeEventListener("pointerleave",S)}}},[d,p,y,x]),E.useEffect(()=>{if(l){const _=S=>
vendor: 4,414 bytes, line 264
264{const b=S.target,k={x:S.clientX,y:S.clientY},P=(d==null?void 0:d.contains(b))||(p==null?void 0:p.contains(b)),C=!qO(k,l);P?x():C&&(x(),f())};return document.addEventListener("pointermove",_),()=>document.removeEventListener("pointermove",_)}},[d,p,l,f,x]),v.jsx(eS,{...t,ref:a})}),[FO,UO]=Wc(qa,{isInside:!1}),VO=OO("TooltipContent"),eS=E.forwardRef((t,e)=>{const{__scopeTooltip:n,children:r,"aria-label":o,onEscapeKeyDown:a,onPointerDownOutside:l,...c}=t,d=qc(Co,n),f=Hc(n),{onClose:p}=d;return E.useEffect(()=>(document.addEventListener(lp,p),()=>document.removeEventListener(lp,p)),[p]),E.useEffect(()=>{if(d.trigger){const g=x=>{const y=x.target;y!=null&&y.contains(d.trigger)&&p()};return window.addEventListener("scroll",g,{capture:!0}),()=>window.removeEventListener("scroll",g,{capture:!0})}},[d.trigger,p]),v.jsx(tm,{asChild:!0,disableOutsidePointerEvents:!1,onEscapeKeyDown:a,onPointerDownOutside:l,onFocusOutside:g=>g.preventDefault(),onDismiss:p,children:v.jsxs(AO,{"data-state":d.stateAttribute,...f,...c,ref:e,style:{...c.style,"--radix-tooltip-content-transform-origin":"var(--radix-popper-transform-origin)","--radix-tooltip-content-available-width":"var(--radix-popper-available-width)","--radix-tooltip-content-available-height":"var(--radix-popper-available-height)","--radix-tooltip-trigger-width":"var(--radix-popper-anchor-width)","--radix-tooltip-trigger-height":"var(--radix-popper-anchor-height)"},children:[v.jsx(VO,{children:r}),v.jsx(FO,{scope:n,isInside:!0,children:v.jsx(MA,{id:d.contentId,role:"tooltip",children:o||r})})]})})});Z1.displayName=Co;var tS="TooltipArrow",BO=E.forwardRef((t,e)=>{const{__scopeTooltip:n,...r}=t,o=Hc(n);return UO(tS,n).isInside?null:v.jsx(RO,{...o,...r,ref:e})});BO.displayName=tS;function zO(t,e){const n=Math.abs(e.top-t.y),r=Math.abs(e.bottom-t.y),o=Math.abs(e.right-t.x),a=Math.abs(e.left-t.x);switch(Math.min(n,r,o,a)){case a:return"left";case o:return"right";case n:return"top";case r:return"bottom";default:throw new Error("unreachable")}}function WO(t,e,n=5){const r=[];switch(e){case"top":r.push({x:t.x-n,y:t.y+n},{x:t.x+n,y:t.y+n});break;case"bottom":r.push({x:t.x-n,y:t.y-n},{x:t.x+n,y:t.y-n});break;case"left":r.push({x:t.x+n,y:t.y-n},{x:t.x+n,y:t.y+n});break;case"right":r.push({x:t.x-n,y:t.y-n},{x:t.x-n,y:t.y+n});break}return r}function HO(t){const{top:e,right:n,bottom:r,left:o}=t;return[{x:o,y:e},{x:n,y:e},{x:n,y:r},{x:o,y:r}]}function qO(t,e){const{x:n,y:r}=t;let o=!1;for(let a=0,l=e.length-1;a<e.length;l=a++){const c=e[a],d=e[l],f=c.x,p=c.y,g=d.x,x=d.y;p>r!=x>r&&n<(g-f)*(r-p)/(x-p)+f&&(o=!o)}return o}function KO(t){const e=t.slice();return e.sort((n,r)=>n.x<r.x?-1:n.x>r.x?1:n.y<r.y?-1:n.y>r.y?1:0),GO(e)}function GO(t){if(t.length<=1)return t.slice();const e=[];for(let r=0;r<t.length;r++){const o=t[r];for(;e.length>=2;){const a=e[e.length-1],l=e[e.length-2];if((a.x-l.x)*(o.y-l.y)>=(a.y-l.y)*(o.x-l.x))e.pop();else break}e.push(o)}e.pop();const n=[];for(let r=t.length-1;r>=0;r--){const o=t[r];for(;n.length>=2;){const a=n[n.length-1],l=n[n.length-2];if((a.x-l.x)*(o.y-l.y)>=(a.y-l.y)*(o.x-l.x))n.pop();else break}n.push(o)}return n.pop(),e.length===1&&n.length===1&&e[0].x===n[0].x&&e[0].y===n[0].y?e:e.concat(n)}var QO=Y1,YO=J1,JO=X1,nS=Z1;const XO=QO,i$=YO,o$=JO,ZO=E.forwardRef(({className:t,sideOffset:e=4,...n},r)=>v.jsx(nS,{ref:r,sideOffset:e,className:Ts("z-50 overflow-hidden rounded-md border bg-popover px-3 py-1.5 text-sm text-popover-foreground shadow-md animate-in fade-in-0 zoom-in-95 data-[state=closed]:animate-out data-[state=closed]:fade-out-0 data-[state=closed]:zoom-out-95 data-[side=bottom]:slide-in-from-top-2 data-[side=left]:slide-in-from-right-2 data-[side=right]:slide-in-from-left-2 data-[side=top]:slide-in-from-bottom-2",t),...n}));ZO.displayName=nS.displayName;var F0=function(){return F0=Object.assign||function(e){for(var n,r=1,o=arguments.length;r<o;r++){n=arguments[r];for(var a in n)Object.prototype.hasOwnProperty.call(n,a)&&(e[a]=n[a])}return e},F0.apply(this,arguments)};function Kc(t,e){var n={};for(var r in t)Object.prototype.hasOwnProperty.call(t,r)&&e.indexOf(r)<0&&(n[r]=t[r]);if(t!=null&&typeof Object.getOwnPropertySymbols=="function")for(var o=0,r=Object.getOwnPropertySymbols(t);o<r.length;o++)e.indexOf(r[o])<0&&Object.prototype.propertyIsEnumerable.call(t,r[o])&&(n[r[o]]=t[r[o]]);return n}function e2(t,e,n,r){function o(a){return a instanceof n?a:new n(function(l){l(a)})}
264return new(n||(n=Promise))(function(a,l){function c(p){try{f(r.next(p))}catch(g){l(g)}}function d(p){try{f(r.throw(p))}catch(g){l(g)}}function f(p){p.done?a(p.value):o(p.value).then(c,d)}f((r=r.apply(t,e||[])).next())})}function a$(t,e,n){if(n||arguments.length===2)for(var r=0,o=e.length,a;r<o;r++)(a||!(r in e))&&(a||(a=Array.prototype.slice.call(e,0,r)),a[r]=e[r]);return t.concat(a||Array.prototype.slice.call(e))}const t2=t=>t?(...e)=>t(...e):(...e)=>fetch(...e);class ym extends Error{constructor(e,n="FunctionsError",r){super(e),this.name=n,this.context=r}}class n2 extends ym{constructor(e){super("Failed to send a request to the Edge Function","FunctionsFetchError",e)}}class U0 extends ym{constructor(e){super("Relay Error invoking the Edge Function","FunctionsRelayError",e)}}class V0 extends ym{constructor(e){super("Edge Function returned a non-2xx status code","FunctionsHttpError",e)}}var cp;(function(t){t.Any="any",t.ApNortheast1="ap-northeast-1",t.ApNortheast2="ap-northeast-2",t.ApSouth1="ap-south-1",t.ApSoutheast1="ap-southeast-1",t.ApSoutheast2="ap-southeast-2",t.CaCentral1="ca-central-1",t.EuCentral1="eu-central-1",t.EuWest1="eu-west-1",t.EuWest2="eu-west-2",t.EuWest3="eu-west-3",t.SaEast1="sa-east-1",t.UsEast1="us-east-1",t.UsWest1="us-west-1",t.UsWest2="us-west-2"})(cp||(cp={}));class r2{constructor(e,{headers:n={},customFetch:r,region:o=cp.Any}={}){this.url=e,this.headers=n,this.region=o,this.fetch=t2(r)}setAuth(e){this.headers.Authorization=`Bearer ${e}`}invoke(e){return e2(this,arguments,void 0,function*(n,r={}){var o;let a,l;try{const{headers:c,method:d,body:f,signal:p,timeout:g}=r;let x={},{region:y}=r;y||(y=this.region);const _=new URL(`${this.url}/${n}`);y&&y!=="any"&&(x["x-region"]=y,_.searchParams.set("forceFunctionRegion",y));let S;f&&(c&&!Object.prototype.hasOwnProperty.call(c,"Content-Type")||!c)?typeof Blob<"u"&&f instanceof Blob||f instanceof ArrayBuffer?(x["Content-Type"]="application/octet-stream",S=f):typeof f=="string"?(x["Content-Type"]="text/plain",S=f):typeof FormData<"u"&&f instanceof FormData?S=f:(x["Content-Type"]="application/json",S=JSON.stringify(f)):f&&typeof f!="string"&&!(typeof Blob<"u"&&f instanceof Blob)&&!(f instanceof ArrayBuffer)&&!(typeof FormData<"u"&&f instanceof FormData)?S=JSON.stringify(f):S=f;let b=p;g&&(l=new AbortController,a=setTimeout(()=>l.abort(),g),p?(b=l.signal,p.addEventListener("abort",()=>l.abort())):b=l.signal);const k=yield this.fetch(_.toString(),{method:d||"POST",headers:Object.assign(Object.assign(Object.assign({},x),this.headers),c),body:S,signal:b}).catch(L=>{throw new n2(L)}),P=k.headers.get("x-relay-error");if(P&&P==="true")throw new U0(k);if(!k.ok)throw new V0(k);let C=((o=k.headers.get("Content-Type"))!==null&&o!==void 0?o:"text/plain").split(";")[0].trim(),A;return C==="application/json"?A=yield k.json():C==="application/octet-stream"||C==="application/pdf"?A=yield k.blob():C==="text/event-stream"?A=k:C==="multipart/form-data"?A=yield k.formData():A=yield k.text(),{data:A,error:null,response:k}}catch(c){return{data:null,error:c,response:c instanceof V0||c instanceof U0?c.context:void 0}}finally{a&&clearTimeout(a)}})}}var s2=class extends Error{constructor(t){super(t.message),this.name="PostgrestError",this.details=t.details,this.hint=t.hint,this.co
264de=t.code}},i2=class{constructor(t){var e,n,r;this.shouldThrowOnError=!1,this.method=t.method,this.url=t.url,this.headers=new Headers(t.headers),this.schema=t.schema,this.body=t.body,this.shouldThrowOnError=(e=t.shouldThrowOnError)!==null&&e!==void 0?e:!1,this.signal=t.signal,this.isMaybeSingle=(n=t.isMaybeSingle)!==null&&n!==void 0?n:!1,this.urlLengthLimit=(r=t.urlLengthLimit)!==null&&r!==void 0?r:8e3,t.fetch?this.fetch=t.fetch:this.fetch=fetch}throwOnError(){return this.shouldThrowOnError=!0,this}setHeader(t,e){return this.headers=new Headers(this.headers),this.headers.set(t,e),this}then(t,e){var n=this;this.schema===void 0||(["GET","HEAD"].includes(this.method)?this.headers.set("Accept-Profile",this.schema):this.headers.set("Content-Profile",this.schema)),this.method!=="GET"&&this.method!=="HEAD"&&this.headers.set("Content-Type","application/json");const r=this.fetch;let o=r(this.url.toString(),{method:this.method,headers:this.headers,body:JSON.stringify(this.body),signal:this.signal}).then(async a=>{let l=null,c=null,d=null,f=a.status,p=a.statusText;if(a.ok){var g,x;if(n.method!=="HEAD"){var y;const k=await a.text();k===""||(n.headers.get("Accept")==="text/csv"||n.headers.get("Accept")&&(!((y=n.headers.get("Accept"))===null||y===void 0)&&y.includes("application/vnd.pgrst.plan+text"))?c=k:c=JSON.parse(k))}const S=(g=n.headers.get("Prefer"))===null||g===void 0?void 0:g.match(/count=(exact|planned|estimated)/),b=(x=a.headers.get("content-range"))===null||x===void 0?void 0:x.split("/");S&&b&&b.length>1&&(d=parseInt(b[1])),n.isMaybeSingle&&n.method==="GET"&&Array.isArray(c)&&(c.length>1?(l={code:"PGRST116",details:`Results contain ${c.length} rows, application/vnd.pgrst.object+json requires 1 row`,hint:null,message:"JSON object requested, multiple (or no) rows returned"},c=null,d=null,f=406,p="Not Acceptable"):c.length===1?c=c[0]:c=null)}else{var _;const S=await a.text();try{l=JSON.parse(S),Array.isArray(l)&&a.status===404&&(c=[],l=null,f=200,p="OK")}catch{a.status===404&&S===""?(f=204,p="No Content"):l={message:S}}if(l&&n.isMaybeSingle&&(!(l==null||(_=l.details)===null||_===void 0)&&_.includes("0 rows"))&&(l=null,f=200,p="OK"),l&&n.shouldThrowOnError)throw new s2(l)}return{error:l,data:c,count:d,status:f,statusText:p}});return this.shouldThrowOnError||(o=o.catch(a=>{var l;let c="",d="",f="";const p=a==null?void 0:a.cause;if(p){var g,x,y,_;const k=(g=p==null?void 0:p.message)!==null&&g!==void 0?g:"",P=(x=p==null?void 0:p.code)!==null&&x!==void 0?x:"";c=`${(y=a==null?void 0:a.name)!==null&&y!==void 0?y:"FetchError"}: ${a==null?void 0:a.message}`,c+=`
265
266Caused by: ${(_=p==null?void 0:p.name)!==null&&_!==void 0?_:"Error"}: ${k}`,P&&(c+=` (${P})`),p!=null&&p.stack&&(c+=`
267${p.stack}`)}else{var S;c=(S=a==null?void 0:a.stack)!==null&&S!==void 0?S:""}const b=this.url.toString().length;return(a==null?void 0:a.name)==="AbortError"||(a==null?void 0:a.code)==="ABORT_ERR"?(f="",d="Request was aborted (timeout or manual cancellation)",b>this.urlLengthLimit&&(d+=`. Note: Your request URL is ${b} characters, which may exceed server limits. If selecting many fields, consider using views. If filtering with large arrays (e.g., .in('id', [many IDs])), consider using an RPC function to pass values server-side.`)):((p==null?void 0:p.name)==="HeadersOverflowError"||(p==null?void 0:p.code)==="UND_ERR_HEADERS_OVERFLOW")&&(f="",d="HTTP headers exceeded server limits (typically 16KB)",b>this.urlLengthLimit&&(d+=`. Your request URL is ${b} characters. If selecting many fields, consider using views. If filtering with large arrays (e.g., .in('id', [200+ IDs])), consider using an RPC function instead.`)),{error:{message:`${(l=a==null?void 0:a.name)!==null&&l!==void 0?l:"FetchError"}: ${a==null?void 0:a.message}`,details:c,hint:d,code:f},data:null,count:null,status:0,statusText:""}})),o.then(t,e)}returns(){return this}overrideTypes(){return this}},o2=class extends i2{select(t){let e=!1;const n=(t??"*").split("").map(r=>/\s/.test(r)&&!e?"":(r==='"'&&(e=!e),r)).join("");return this.url.searchParams.set("select",n),this.headers.append("Prefer","return=representation"),this}order(t,{ascending:e=!0,nullsFirst:n,foreignTable:r,referencedTable:o=r}={}){const a=o?`${o}.order`:"order",l=this.url.searchParams.get(a);return this.url.searchParams.set(a,`${l?`${l},`:""}${t}.${e?"asc":"desc"}${n===void 0?"":n?".nullsfirst":".nullslast"}`),this}limit(t,{foreignTable:e,referencedTable:n=e}={}){const r=typeof n>"u"?"limit":`${n}.limit`;return this.url.searchParams.set(r,`${t}`),this}range(t,e,{foreignTable:n,referencedTable:r=n}={}){const o=typeof r>"u"?"offset":`${r}.offset`,a=typeof r>"u"?"limit":`${r}.limit`;return this.url.searchParams.set(o,`${t}`),this.url.searchParams.set(a,`${e-t+1}`),this}abortSignal(t){return this.signal=t,this}single(){return this.headers.set("Accept","application/vnd.pgrst.object+json"),this}maybeSingle(){return this.method==="GET"?this.headers.set("Accept","application/json"):this.headers.set("Accept","application/vnd.pgrst.object+json"),this.isMaybeSingle=!0,this}csv(){return this.headers.set("Accept","text/csv"),this}geojson(){return this.headers.set("Accept","application/geo+json"),this}
267explain({analyze:t=!1,verbose:e=!1,settings:n=!1,buffers:r=!1,wal:o=!1,format:a="text"}={}){var l;const c=[t?"analyze":null,e?"verbose":null,n?"settings":null,r?"buffers":null,o?"wal":null].filter(Boolean).join("|"),d=(l=this.headers.get("Accept"))!==null&&l!==void 0?l:"application/json";return this.headers.set("Accept",`application/vnd.pgrst.plan+${a}; for="${d}"; options=${c};`),a==="json"?this:this}rollback(){return this.headers.append("Prefer","tx=rollback"),this}returns(){return this}maxAffected(t){return this.headers.append("Prefer","handling=strict"),this.headers.append("Prefer",`max-affected=${t}`),this}};const B0=new RegExp("[,()]");var eo=class extends o2{eq(t,e){return this.url.searchParams.append(t,`eq.${e}`),this}neq(t,e){return this.url.searchParams.append(t,`neq.${e}`),this}gt(t,e){return this.url.searchParams.append(t,`gt.${e}`),this}gte(t,e){return this.url.searchParams.append(t,`gte.${e}`),this}lt(t,e){return this.url.searchParams.append(t,`lt.${e}`),this}lte(t,e){return this.url.searchParams.append(t,`lte.${e}`),this}like(t,e){return this.url.searchParams.append(t,`like.${e}`),this}likeAllOf(t,e){return this.url.searchParams.append(t,`like(all).{${e.join(",")}}`),this}likeAnyOf(t,e){return this.url.searchParams.append(t,`like(any).{${e.join(",")}}`),this}ilike(t,e){return this.url.searchParams.append(t,`ilike.${e}`),this}ilikeAllOf(t,e){return this.url.searchParams.append(t,`ilike(all).{${e.join(",")}}`),this}ilikeAnyOf(t,e){return this.url.searchParams.append(t,`ilike(any).{${e.join(",")}}`),this}regexMatch(t,e){return this.url.searchParams.append(t,`match.${e}`),this}regexIMatch(t,e){return this.url.searchParams.append(t,`imatch.${e}`),this}is(t,e){return this.url.searchParams.append(t,`is.${e}`),this}isDistinct(t,e){return this.url.searchParams.append(t,`isdistinct.${e}`),this}in(t,e){const n=Array.from(new Set(e)).map(r=>typeof r=="string"&&B0.test(r)?`"${r}"`:`${r}`).join(",");return this.url.searchParams.append(t,`in.(${n})`),this}notIn(t,e){const n=Array.from(new Set(e)).map(r=>typeof r=="string"&&B0.test(r)?`"${r}"`:`${r}`).join(",");return this.url.searchParams.append(t,`not.in.(${n})`),this}contains(t,e){return typeof e=="string"?this.url.searchParams.append(t,`cs.${e}`):Array.isArray(e)?this.url.searchParams.append(t,`cs.{${e.join(",")}}`):this.url.searchParams.append(t,`cs.${JSON.stringify(e)}`),this}containedBy(t,e){return typeof e=="string"?this.url.searchParams.append(t,`cd.${e}`):Array.isArray(e)?this.url.searchParams.append(t,`cd.{${e.join(",")}}`):this.url.searchParams.append(t,`cd.${JSON.stringify(e)}`),this}rangeGt(t,e){return this.url.searchParams.append(t,`sr.${e}`),this}rangeGte(t,e){return this.url.searchParams.append(t,`nxl.${e}`),this}rangeLt(t,e){return this.url.searchParams.append(t,`sl.${e}`),this}rangeLte(t,e){return this.url.searchParams.append(t,`nxr.${e}`),this}rangeAdjacent(t,e){return this.url.searchParams.append(t,`adj.${e}`),this}overlaps(t,e){return typeof e=="string"?this.url.searchParams.append(t,`ov.${e}`):this.url.searchParams.append(t,`ov.{${e.join(",")}}`),this}textSearch(t,e,{config:n,type:r}={}){let o="";r==="plain"?o="pl":r==="phrase"?o="ph":r==="websearch"&&(o="w");const a=n===void 0?"":`(${n})`;return this.url.searchParams.append(t,`${o}fts${a}.${e}`),this}match(t){return Object.entries(t).forEach(([e,n])=>{this.url.searchParams.append(e,`eq.${n}`)}),this}not(t,e,n){return this.url.searchParams.append(t,`not.${e}.${n}`),this}or(t,{foreignTable:e,referencedTable:n=e}={}){const r=n?`${n}.or`:"or";return this.url.searchParams.append(r,`(${t})`),this}filter(t,e,n){return this.url.searchParams.append(t,`${e}.${n}`),this}},a2=class{constructor(t,{headers:e={},schema:n,fetch:r,urlLengthLimit:o=8e3}){this.url=t,this.headers=new Headers(e),this.schema=n,this.fetch=r,this.urlLengthLimit=o}cloneRequestState(){return{url:new URL(this.url.toString()),headers:new Headers(this.headers)}}select(t,e){const{head:n=!1,count:r}=e??{},o=n?"HEAD":"GET";let a=!1;const l=(t??"*").split("").map(f=>/\s/.test(f)&&!a?"":(f==='"'&&(a=!a),f)).join(""),{url:c,headers:d}=this.cloneRequestState();return c.searchParams.set("select",l),r&&d.append("Prefer",`count=${r}`),new eo({method:o,url:c,headers:d,schema:this.schema,fetch:this.fetch,urlLengthLimit:this.urlLengthLimit})}insert(t,{count:e,defaultToNull:n=!0}={}){var r;const o="POST",{url:a,headers:l}=this.cloneRequestState();if(e&&l.append("Prefer",`count=${e}`),n||l.append("Prefer","missing=default"),Array.isArray(t)){const c=t.reduce((d,f)=>d.concat(Object.keys(f)),[]);if(c.length>0){const d=[...new Set(c)].map(f=>`"${f}"`);a.searchParams.set("columns",d.join(","))}}return new eo({method:o,url:a,headers:l,schema:this.schema,body:t,fetch:(r=this.fetch)!==null&&r!==void 0?r:fetch,urlLengthLimit:this.urlLengthLimit})}upsert(t,{onConflict:e,ignoreDuplicates:n=!1,count:r,defaultToNull:o=!0}={}){var a;const l="POST",{url:c,headers:d}=this.cloneRequestState();if(d.append("Prefer",`resolution=${n?"ignore":"merge"}-duplicates`),e!==void 0&&c.searchParams.set("on_conflict",e),r&&d.append("Prefer",`count=${r}`),o||d.append("Prefer","missing=default"),Array.isArray(t)){const f=t.reduce((p,g)=>p.concat(Object.keys(g)),[]);if(f.length>0){const p=[...new Set(f)].map(g=>`"${g}"`);c.searchParams.set("columns",p.join(","))}}return new eo({method:l,url:c,headers:d,schema:this.schema,body:t,fetch:(a=this.fetch)!==null&&a!==void 0?a:fetch,urlLengthLimit:this.urlLengthLimit})}update(t,{count:e}={}){var n;const r="PATCH",{url:o,headers:a}=this.cloneRequestState();return e&&a.append("Prefer",`count=${e}`),new eo({method:r,url:o,headers:a,schema:this.schema,body:t,fetch:(n=this.fetch)!==null&&n!==void 0?n:fetch,urlLengthLimit:this.urlLengthLimit})}delete({count:t}={}){var e;const n="DELETE",{url:r,headers:o}=this.cloneRequestState();return t&&o.append("Prefer",`count=${t}`),new eo({method:n,url:r,headers:o,schema:this.schema,fetch:(e=this.fetch)!==null&&e!==void 0?e:fetch,urlLengthLimit:this.urlLengthLimit})}};function Ka(t){"@babel/helpers - typeof";return Ka=typeof Symbol=="function"&&typeof Symbol.iterator=="symbol"?function(e){return typeof e}:function(e){return e&&typeof Symbol=="function"&&e.constructor===Symbol&&e!==Symbol.prototype?"symbol":typeof e},Ka(t)}function l2(t,e){if(Ka(t)!="object"||!t)return t;var n=t[Symbol.toPrimitive];if(n!==void 0){var r=n.call(t,e);if(Ka(r)!="object")return r;throw new TypeError("@@toPrimitive must return a primitive value.")}return(e==="string"?String:Number)(t)}function u2(t){var e=l2(t,"string");return Ka(e)=="symbol"?e:e+""}function c2(t,e,n){return(e=u2(e))in t?Object.defineProperty(t,e,{value:n,enumerable:!0,configurable:!0,writable:!0}):t[e]=n,t}function z0(t,e){var n=Object.keys(t);if(Object.getOwnPropertySymbols){var r=Object.getOwnPropertySymbols(t);e&&(r=r.filter(function(o){return Object.getOwnPropertyDescriptor(t,o).enumerable})),n.push.apply(n,r)}return n}function zu(t){for(var e=1;e<arguments.length;e++){var n=arguments[e]!=null?arguments[e]:{};
267e%2?z0(Object(n),!0).forEach(function(r){c2(t,r,n[r])}):Object.getOwnPropertyDescriptors?Object.defineProperties(t,Object.getOwnPropertyDescriptors(n)):z0(Object(n)).forEach(function(r){Object.defineProperty(t,r,Object.getOwnPropertyDescriptor(n,r))})}return t}var d2=class rS{constructor(e,{headers:n={},schema:r,fetch:o,timeout:a,urlLengthLimit:l=8e3}={}){this.url=e,this.headers=new Headers(n),this.schemaName=r,this.urlLengthLimit=l;const c=o??globalThis.fetch;a!==void 0&&a>0?this.fetch=(d,f)=>{const p=new AbortController,g=setTimeout(()=>p.abort(),a),x=f==null?void 0:f.signal;if(x){if(x.aborted)return clearTimeout(g),c(d,f);const y=()=>{clearTimeout(g),p.abort()};return x.addEventListener("abort",y,{once:!0}),c(d,zu(zu({},f),{},{signal:p.signal})).finally(()=>{clearTimeout(g),x.removeEventListener("abort",y)})}return c(d,zu(zu({},f),{},{signal:p.signal})).finally(()=>clearTimeout(g))}:this.fetch=c}from(e){if(!e||typeof e!="string"||e.trim()==="")throw new Error("Invalid relation name: relation must be a non-empty string.");return new a2(new URL(`${this.url}/${e}`),{headers:new Headers(this.headers),schema:this.schemaName,fetch:this.fetch,urlLengthLimit:this.urlLengthLimit})}schema(e){return new rS(this.url,{headers:this.headers,schema:e,fetch:this.fetch,urlLengthLimit:this.urlLengthLimit})}rpc(e,n={},{head:r=!1,get:o=!1,count:a}={}){var l;let c;const d=new URL(`${this.url}/rpc/${e}`);let f;const p=y=>y!==null&&typeof y=="object"&&(!Array.isArray(y)||y.some(p)),g=r&&Object.values(n).some(p);g?(c="POST",f=n):r||o?(c=r?"HEAD":"GET",Object.entries(n).filter(([y,_])=>_!==void 0).map(([y,_])=>[y,Array.isArray(_)?`{${_.join(",")}}`:`${_}`]).forEach(([y,_])=>{d.searchParams.append(y,_)})):(c="POST",f=n);const x=new Headers(this.headers);return g?x.set("Prefer",a?`count=${a},return=minimal`:"return=minimal"):a&&x.set("Prefer",`count=${a}`),new eo({method:c,url:d,headers:x,schema:this.schemaName,body:f,fetch:(l=this.fetch)!==null&&l!==void 0?l:fetch,urlLengthLimit:this.urlLengthLimit})}};class h2{constructor(){}static detectEnvironment(){var e;if(typeof WebSocket<"u")return{type:"native",constructor:WebSocket};if(typeof globalThis<"u"&&typeof globalThis.WebSocket<"u")return{type:"native",constructor:globalThis.WebSocket};if(typeof global<"u"&&typeof global.WebSocket<"u")return{type:"native",constructor:global.WebSocket};if(typeof globalThis<"u"&&typeof globalThis.WebSocketPair<"u"&&typeof globalThis.WebSocket>"u")return{type:"cloudflare",error:"Cloudflare Workers detected. WebSocket clients are not supported in Cloudflare Workers.",workaround:"Use Cloudflare Workers WebSocket API for server-side WebSocket handling, or deploy to a different runtime."};if(typeof globalThis<"u"&&globalThis.EdgeRuntime||typeof navigator<"u"&&(!((e=navigator.userAgent)===null||e===void 0)&&e.includes("Vercel-Edge")))return{type:"unsupported",error:"Edge runtime detected (Vercel Edge/Netlify Edge). WebSockets are not supported in edge functions.",workaround:"Use serverless functions or a different deployment target for WebSocket functionality."};const n=globalThis.process;if(n){const r=n.versions;if(r&&r.node){const o=r.node,a=parseInt(o.replace(/^v/,"").split(".")[0]);return a>=22?typeof globalThis.WebSocket<"u"?{type:"native",constructor:globalThis.WebSocket}:{type:"unsupported",error:`Node.js ${a} detected but native WebSocket not found.`,workaround:"Provide a WebSocket implementation via the transport option."}:{type:"unsupported",error:`Node.js ${a} detected without native WebSocket support.`,workaround:`For Node.js < 22, install "ws" package and provide it via the transport option:
268import ws from "ws"
269new RealtimeClient(url, { transport: ws })`}}}return{type:"unsupported",error:"Unknown JavaScript runtime without WebSocket support.",workaround:"Ensure you're running in a supported environment (browser, Node.js, Deno) or provide a custom WebSocket implementation."}}static getWebSocketConstructor(){const e=this.detectEnvironment();if(e.constructor)return e.constructor;let n=e.error||"WebSocket not supported in this environment.";throw e.workaround&&(n+=`
270
271Suggested solution: ${e.workaround}`),new Error(n)}static createWebSocket(e,n){const r=this.getWebSocketConstructor();return new r(e,n)}static isWebSocketSupported(){try{const e=this.detectEnvironment();return e.type==="native"||e.type==="ws"}catch{return!1}}}const f2="2.99.2",p2=`realtime-js/${f2}`,m2="1.0.0",sS="2.0.0",W0=sS,dp=1e4,g2=1e3,y2=100;var as;(function(t){t[t.connecting=0]="connecting",t[t.open=1]="open",t[t.closing=2]="closing",t[t.closed=3]="closed"})(as||(as={}));var ut;(function(t){t.closed="closed",t.errored="errored",t.joined="joined",t.joining="joining",t.leaving="leaving"})(ut||(ut={}));var Dn;(function(t){t.close="phx_close",t.error="phx_error",t.join="phx_join",t.reply="phx_reply",t.leave="phx_leave",t.access_token="access_token"})(Dn||(Dn={}));var hp;(function(t){t.websocket="websocket"})(hp||(hp={}));var Ys;(function(t){t.Connecting="connecting",t.Open="open",t.Closing="closing",t.Closed="closed"})(Ys||(Ys={}));class v2{constructor(e){this.HEADER_LENGTH=1,this.USER_BROADCAST_PUSH_META_LENGTH=6,this.KINDS={userBroadcastPush:3,userBroadcast:4},this.BINARY_ENCODING=0,this.JSON_ENCODING=1,this.BROADCAST_EVENT="broadcast",this.allowedMetadataKeys=[],this.allowedMetadataKeys=e??[]}encode(e,n){if(e.event===this.BROADCAST_EVENT&&!(e.payload instanceof ArrayBuffer)&&typeof e.payload.event=="string")return n(this._binaryEncodeUserBroadcastPush(e));let r=[e.join_ref,e.ref,e.topic,e.event,e.payload];return n(JSON.stringify(r))}_binaryEncodeUserBroadcastPush(e){var n;return this._isArrayBuffer((n=e.payload)===null||n===void 0?void 0:n.payload)?this._encodeBinaryUserBroadcastPush(e):this._encodeJsonUserBroadcastPush(e)}_encodeBinaryUserBroadcastPush(e){var n,r;const o=(r=(n=e.payload)===null||n===void 0?void 0:n.payload)!==null&&r!==void 0?r:new ArrayBuffer(0);return this._encodeUserBroadcastPush(e,this.BINARY_ENCODING,o)}_encodeJsonUserBroadcastPush(e){var n,r;const o=(r=(n=e.payload)===null||n===void 0?void 0:n.payload)!==null&&r!==void 0?r:{},l=new TextEncoder().encode(JSON.stringify(o)).buffer;return this._encodeUserBroadcastPush(e,this.JSON_ENCODING,l)}_encodeUserBroadcastPush(e,n,r){var o,a;const l=e.topic,c=(o=e.ref)!==null&&o!==void 0?o:"",d=(a=e.join_ref)!==null&&a!==void 0?a:"",f=e.payload.event,p=this.allowedMetadataKeys?this._pick(e.payload,this.allowedMetadataKeys):{},g=Object.keys(p).length===0?"":JSON.stringify(p);if(d.length>255)throw new Error(`joinRef length ${d.length} exceeds maximum of 255`);if(c.length>255)throw new Error(`ref length ${c.length} exceeds maximum of 255`);if(l.length>255)throw new Error(`topic length ${l.length} exceeds maximum of 255`);if(f.length>255)throw new Error(`userEvent length ${f.length} exceeds maximum of 255`);if(g.length>255)throw new Error(`metadata length ${g.length} exceeds maximum of 255`);const x=this.USER_BROADCAST_PUSH_META_LENGTH+d.length+c.length+l.length+f.length+g.length,y=new ArrayBuffer(this.HEADER_LENGTH+x);let _=new DataView(y),S=0;_.setUint8(S++,this.KINDS.userBroadcastPush),_.setUint8(S++,d.length),_.setUint8(S++,c.length),_.setUint8(S++,l.length),_.setUint8(S++,f.length),_.setUint8(S++,g.length),_.setUint8(S++,n),Array.from(d,k=>
271_.setUint8(S++,k.charCodeAt(0))),Array.from(c,k=>_.setUint8(S++,k.charCodeAt(0))),Array.from(l,k=>_.setUint8(S++,k.charCodeAt(0))),Array.from(f,k=>_.setUint8(S++,k.charCodeAt(0))),Array.from(g,k=>_.setUint8(S++,k.charCodeAt(0)));var b=new Uint8Array(y.byteLength+r.byteLength);return b.set(new Uint8Array(y),0),b.set(new Uint8Array(r),y.byteLength),b.buffer}decode(e,n){if(this._isArrayBuffer(e)){let r=this._binaryDecode(e);return n(r)}if(typeof e=="string"){const r=JSON.parse(e),[o,a,l,c,d]=r;return n({join_ref:o,ref:a,topic:l,event:c,payload:d})}return n({})}_binaryDecode(e){const n=new DataView(e),r=n.getUint8(0),o=new TextDecoder;switch(r){case this.KINDS.userBroadcast:return this._decodeUserBroadcast(e,n,o)}}_decodeUserBroadcast(e,n,r){const o=n.getUint8(1),a=n.getUint8(2),l=n.getUint8(3),c=n.getUint8(4);let d=this.HEADER_LENGTH+4;const f=r.decode(e.slice(d,d+o));d=d+o;const p=r.decode(e.slice(d,d+a));d=d+a;const g=r.decode(e.slice(d,d+l));d=d+l;const x=e.slice(d,e.byteLength),y=c===this.JSON_ENCODING?JSON.parse(r.decode(x)):x,_={type:this.BROADCAST_EVENT,event:p,payload:y};return l>0&&(_.meta=JSON.parse(g)),{join_ref:null,ref:null,topic:f,event:this.BROADCAST_EVENT,payload:_}}_isArrayBuffer(e){var n;return e instanceof ArrayBuffer||((n=e==null?void 0:e.constructor)===null||n===void 0?void 0:n.name)==="ArrayBuffer"}_pick(e,n){return!e||typeof e!="object"?{}:Object.fromEntries(Object.entries(e).filter(([r])=>n.includes(r)))}}class iS{constructor(e,n){this.callback=e,this.timerCalc=n,this.timer=void 0,this.tries=0,this.callback=e,this.timerCalc=n}reset(){this.tries=0,clearTimeout(this.timer),this.timer=void 0}scheduleTimeout(){clearTimeout(this.timer),this.timer=setTimeout(()=>{this.tries=this.tries+1,this.callback()},this.timerCalc(this.tries+1))}}var Be;(function(t){t.abstime="abstime",t.bool="bool",t.date="date",t.daterange="daterange",t.float4="float4",t.float8="float8",t.int2="int2",t.int4="int4",t.int4range="int4range",t.int8="int8",t.int8range="int8range",t.json="json",t.jsonb="jsonb",t.money="money",t.numeric="numeric",t.oid="oid",t.reltime="reltime",t.text="text",t.time="time",t.timestamp="timestamp",t.timestamptz="timestamptz",t.timetz="timetz",t.tsrange="tsrange",t.tstzrange="tstzrange"})(Be||(Be={}));const H0=(t,e,n={})=>{var r;const o=(r=n.skipTypes)!==null&&r!==void 0?r:[];return e?Object.keys(e).reduce((a,l)=>(a[l]=w2(l,t,e,o),a),{}):{}},w2=(t,e,n,r)=>{const o=e.find(c=>c.name===t),a=o==null?void 0:o.type,l=n[t];return a&&!r.includes(a)?oS(a,l):fp(l)},oS=(t,e)=>{if(t.charAt(0)==="_"){const n=t.slice(1,t.length);return _2(e,n)}switch(t){case Be.bool:return x2(e);case Be.float4:case Be.float8:case Be.int2:case Be.int4:case Be.int8:case Be.numeric:case Be.oid:return b2(e);case Be.json:case Be.jsonb:return S2(e);case Be.timestamp:return E2(e);case Be.abstime:case Be.date:case Be.daterange:case Be.int4range:case Be.int8range:case Be.money:case Be.reltime:case Be.text:case Be.time:case Be.timestamptz:case Be.timetz:case Be.tsrange:case Be.tstzrange:return fp(e);default:return fp(e)}},fp=t=>t,x2=t=>{switch(t){case"t":return!0;case"f":return!1;default:return t}},b2=t=>{if(typeof t=="string"){const e=parseFloat(t);if(!Number.isNaN(e))return e}return t},S2=t=>{if(typeof t=="string")try{return JSON.parse(t)}catch{return t}return t},_2=(t,e)=>{if(typeof t!="string")return t;const n=t.length-1,r=t[n];if(t[0]==="{"&&r==="}"){let a;const l=t.slice(1,n);try{a=JSON.parse("["+l+"]")}catch{a=l?l.split(","):[]}return a.map(c=>oS(e,c))}return t},E2=t=>typeof t=="string"?t.replace(" ","T"):t,aS=t=>{const e=new URL(t);return e.protocol=e.protocol.replace(/^ws/i,"http"),e.pathname=e.pathname.replace(/\/+$/,"").replace(/\/socket\/websocket$/i,"").replace(/\/socket$/i,"").replace(/\/websocket$/i,""),e.pathname===""||e.pathname==="/"?e.pathname="/api/broadcast":e.pathname=e.pathname+"/api/broadcast",e.href};class sf{constructor(e,n,r={},o=dp){this.channel=e,this.event=n,this.payload=r,this.timeout=o,this.sent=!1,this.timeoutTimer=void 0,this.ref="",this.receivedResp=null,this.recHooks=[],this.refEvent=null}resend(e){this.timeout=e,this._cancelRefEvent(),this.ref="",this.refEvent=null,this.receivedResp=null,this.sent=!1,this.send()}send(){this._hasReceived("timeout")||(this.startTimeout(),this.sent=!0,this.channel.socket.push({topic:this.channel.topic,event:this.event,payload:this.payload,ref:this.ref,j
271oin_ref:this.channel._joinRef()}))}updatePayload(e){this.payload=Object.assign(Object.assign({},this.payload),e)}receive(e,n){var r;return this._hasReceived(e)&&n((r=this.receivedResp)===null||r===void 0?void 0:r.response),this.recHooks.push({status:e,callback:n}),this}startTimeout(){if(this.timeoutTimer)return;this.ref=this.channel.socket._makeRef(),this.refEvent=this.channel._replyEventName(this.ref);const e=n=>{this._cancelRefEvent(),this._cancelTimeout(),this.receivedResp=n,this._matchReceive(n)};this.channel._on(this.refEvent,{},e),this.timeoutTimer=setTimeout(()=>{this.trigger("timeout",{})},this.timeout)}trigger(e,n){this.refEvent&&this.channel._trigger(this.refEvent,{status:e,response:n})}destroy(){this._cancelRefEvent(),this._cancelTimeout()}_cancelRefEvent(){this.refEvent&&this.channel._off(this.refEvent,{})}_cancelTimeout(){clearTimeout(this.timeoutTimer),this.timeoutTimer=void 0}_matchReceive({status:e,response:n}){this.recHooks.filter(r=>r.status===e).forEach(r=>r.callback(n))}_hasReceived(e){return this.receivedResp&&this.receivedResp.status===e}}var q0;(function(t){t.SYNC="sync",t.JOIN="join",t.LEAVE="leave"})(q0||(q0={}));class Ia{constructor(e,n){this.channel=e,this.state={},this.pendingDiffs=[],this.joinRef=null,this.enabled=!1,this.caller={onJoin:()=>{},onLeave:()=>{},onSync:()=>{}};const r=(n==null?void 0:n.events)||{state:"presence_state",diff:"presence_diff"};this.channel._on(r.state,{},o=>{const{onJoin:a,onLeave:l,onSync:c}=this.caller;this.joinRef=this.channel._joinRef(),this.state=Ia.syncState(this.state,o,a,l),this.pendingDiffs.forEach(d=>{this.state=Ia.syncDiff(this.state,d,a,l)}),this.pendingDiffs=[],c()}),this.channel._on(r.diff,{},o=>{const{onJoin:a,onLeave:l,onSync:c}=this.caller;this.inPendingSyncState()?this.pendingDiffs.push(o):(this.state=Ia.syncDiff(this.state,o,a,l),c())}),this.onJoin((o,a,l)=>{this.channel._trigger("presence",{event:"join",key:o,currentPresences:a,newPresences:l})}),this.onLeave((o,a,l)=>{this.channel._trigger("presence",{event:"leave",key:o,currentPresences:a,leftPresences:l})}),this.onSync(()=>{this.channel._trigger("presence",{event:"sync"})})}static syncState(e,n,r,o){const a=this.cloneDeep(e),l=this.transformState(n),c={},d={};return this.map(a,(f,p)=>{l[f]||(d[f]=p)}),this.map(l,(f,p)=>{const g=a[f];if(g){const x=p.map(b=>b.presence_ref),y=g.map(b=>b.presence_ref),_=p.filter(b=>y.indexOf(b.presence_ref)<0),S=g.filter(b=>x.indexOf(b.presence_ref)<0);_.length>0&&(c[f]=_),S.length>0&&(d[f]=S)}else c[f]=p}),this.syncDiff(a,{joins:c,leaves:d},r,o)}static syncDiff(e,n,r,o){const{joins:a,leaves:l}={joins:this.transformState(n.joins),leaves:this.transformState(n.leaves)};return r||(r=()=>{}),o||(o=()=>{}),this.map(a,(c,d)=>{var f;const p=(f=e[c])!==null&&f!==void 0?f:[];if(e[c]=this.cloneDeep(d),p.length>0){const g=e[c].map(y=>y.presence_ref),x=p.filter(y=>g.indexOf(y.presence_ref)<0);e[c].unshift(...x)}r(c,p,d)}),this.map(l,(c,d)=>{let f=e[c];if(!f)return;const p=d.map(g=>g.presence_ref);f=f.filter(g=>p.indexOf(g.presence_ref)<0),e[c]=f,o(c,f,d),f.length===0&&delete e[c]}),e}static map(e,n){return Object.getOwnPropertyNames(e).map(r=>n(r,e[r]))}static transformState(e){return e=this.cloneDeep(e),Object.getOwnPropertyNames(e).reduce((n,r)=>{const o=e[r];return"metas"in o?n[r]=o.metas.map(a=>(a.presence_ref=a.phx_ref,delete a.phx_ref,delete a.phx_ref_prev,a)):n[r]=o,n},{})}static cloneDeep(e){return JSON.parse(JSON.stringify(e))}onJoin(e){this.caller.onJoin=e}onLeave(e){this.caller.onLeave=e}onSync(e){this.caller.onSync=e}inPendingSyncState(){return!this.joinRef||this.joinRef!==this.channel._joinRef()}}var K0;(function(t){t.ALL="*",t.INSERT="INSERT",t.UPDATE="UPDATE",t.DELETE="DELETE"})(K0||(K0={}));var La;(function(t){t.BROADCAST="broadcast",t.PRESENCE="presence",t.POSTGRES_CHANGES="postgres_changes",t.SYSTEM="system"})(La||(La={}));var Tr;(function(t){t.SUBSCRIBED="SUBSCRIBED",t.TIMED_OUT="TIMED_OUT",t.CLOSED="CLOSED",t.CHANNEL_ERROR="CHANNEL_ERROR"})(Tr||(Tr={}));class so{constructor(e,n={config:{}},r){var o,a;if(this.topic=e,this.params=n,this.socket=r,this.bindings={},this.state=ut.closed,this.joinedOnce=!1,this.pushBuffer=[],this.subTopic=e.replace(/^realtime:/i,""),this.params.config=Object.assign({broadcast:{ack:!1,self:!1},presence:{key:"",enabled:!1},private:!1},n.config),this.timeout=this.socket.timeout,this.joinPush=new sf(this,Dn.join,this.params,this.timeout),this.rejoinTimer=new iS(()=>this._rejoinUntilConnected(),this.socket.reconnectAfterMs),this.joinPush.receive("ok",()=>{this.state=ut.joined,this.rejoinTimer.reset(),this.pushBuffer.forEach(l=>l.send()),this.pushBuffer=[]}),this._onClose(()=>{this.rejoinTimer.reset(),this.socket.log("channel",`close ${this.topic} ${this._joinRef()}`),this.state=ut.closed,this.socket._remove(this)}),this._onError(l=>{this._isLeaving()||this._isClosed()||(this.socket.log("channel",`error ${this.topic}`,l),this.state=ut.errored,this.rejoinTimer.scheduleTimeout())}),this.joinPush.receive("timeout",()=>{this._isJoining()&&(this.socket.log("channel",`timeout ${this.topic}`,this.joinPush.timeout),this.state=ut.errored,this.rejoinTimer.scheduleTimeout())}),this.joinPush.receive("error",l=>{this._isLeaving()||this._isClosed()||(this.socket.log("channel",`error ${this.topic}`,l),this.state=ut.errored,this.rejoinTimer.scheduleTimeout())}),this._on(Dn.reply,{},(l,c)=>{this._trigger(this._replyEventName(c),l)}),this.presence=new Ia(this),this.broadcastEndpointURL=aS(this.socket.endPoint),this.private=this.params.config.private||!1,!this.private&&(!((a=(o=this.params.config)===null||o===void 0?void 0:o.broadcast)===null||a===void 0)&&a.replay))throw`tried to use replay on public channel '${this.topic}'. It must be a private channel.`}subscribe(e,n=this.timeout){var r,o,a;if(this.socket.isConnected()||this.socket.connect(),this.state==ut.closed){const{config:{broadcast:l,presence:c,private:d}}=this.params,f=(o=(r=this.bindings.postgres_changes)===null||r===void 0?void 0:r.map(y=>y.filter))!==null&&o!==void 0?o:[],p=!!this.bindings[La.PRESENCE]&&this.bindings[La.PRESENCE].length>0||((a=this.params.config.presence)===null||a===void 0?void 0:a.enabled)===!0,g={},x={broadcast:l,presence:Object.assign(Object.assign({},c),{enabled:p}),postgres_changes:f,private:d};this.socket.accessTokenValue&&(g.access_token=this.socket.accessTokenValue),this._onError(y=>e==null?void 0:e(Tr.CHANNEL_ERROR,y)),this._onClose(()=>e==null?void 0:e(Tr.CLOSED)),this.updateJoinPayload(Object.assign({config:x},g)),this.joinedOnce=!0,this._rejoin(n),this.joinPush.receive("ok",async({postgres_changes:y})=>{var _;if(this.socket._isManualToken()||this.socket.setAuth(),y===void 0){e==null||e(Tr.SUBSCRIBED);return}else{const S=this.bindings.postgres_changes,b=(_=S==null?void 0:S.length)!==null&&_!==void 0?_:0,k=[];for(let P=0;P<b;P++){const C=S[P],{filter:{event:A,schema:L,table:D,filter:V}}=C,z=y&&y[P];if(z&&z.event===A&&so.isFilterValueEqual(z.schema,L)&&so.isFilterValueEqual(z.table,D)&&so.isFilterValueEqual(z.filter,V))k.push(Object.assign(Object.assign({},C),{id:z.id}));else{this.unsubscribe(),this.state=ut.errored,e==null||e(Tr.CHANNEL_ERROR,new Error("mismatch between server and client bindings for postgres changes"));return}}this.bindings.postgres_changes=k,e&&e(Tr.SUBSCRIBED);return}}).receive("error",y=>{this.state=ut.errored,e==null||e(Tr.CHANNEL_ERROR,new Error(JSON.stringify(Object.values(y).join(", ")||"error")))}).receive("timeout",()=>{e==null||e(Tr.TIMED_OUT)})}return this}presenceState(){return this.presence.state}async track(e,n={}){return await this.send({type:"presence",event:"track",payload:e},n.timeout||this.timeout)}async untrack(e={}){return await this.send({type:"presence",event:"untrack"},e)}on(e,n,r){return this.state===ut.joined&&e===La.PRESENCE&&(this.socket.log("channel",`resubscribe to ${this.topic} due to change in presence callbacks on joined channel`),this.unsubscribe().then(async()=>await this.subscribe())),this._on(e,n,r)}async httpSend(e,n,r={}){var o;if(n==null)return Promise.reject("Payload is required for httpSend()");const a={apikey:this.socket.apiKey?this.socket.apiKey:"","Content-Type":"application/json"};this.socket.accessTokenValue&&(a.Authorization=`Bearer ${this.socket.accessTokenValue}`);const l={method:"POST",headers:a,body:JSON.stringify({messages:[{topic:this.subTopic,event:e,payload:n,private:this.private}]})},c=await this._fetchWithTimeout(this.broadcastEndpointURL,l,(o=r.timeout)!==null&&o!==void 0?o:this.timeout);if(c.status===202)return{success:!0};let d=c.statusText;
271try{const f=await c.json();d=f.error||f.message||d}catch{}return Promise.reject(new Error(d))}async send(e,n={}){var r,o;if(!this._canPush()&&e.type==="broadcast"){console.warn("Realtime send() is automatically falling back to REST API. This behavior will be deprecated in the future. Please use httpSend() explicitly for REST delivery.");const{event:a,payload:l}=e,c={apikey:this.socket.apiKey?this.socket.apiKey:"","Content-Type":"application/json"};this.socket.accessTokenValue&&(c.Authorization=`Bearer ${this.socket.accessTokenValue}`);const d={method:"POST",headers:c,body:JSON.stringify({messages:[{topic:this.subTopic,event:a,payload:l,private:this.private}]})};try{const f=await this._fetchWithTimeout(this.broadcastEndpointURL,d,(r=n.timeout)!==null&&r!==void 0?r:this.timeout);return await((o=f.body)===null||o===void 0?void 0:o.cancel()),f.ok?"ok":"error"}catch(f){return f.name==="AbortError"?"timed out":"error"}}else return new Promise(a=>{var l,c,d;const f=this._push(e.type,e,n.timeout||this.timeout);e.type==="broadcast"&&!(!((d=(c=(l=this.params)===null||l===void 0?void 0:l.config)===null||c===void 0?void 0:c.broadcast)===null||d===void 0)&&d.ack)&&a("ok"),f.receive("ok",()=>a("ok")),f.receive("error",()=>a("error")),f.receive("timeout",()=>a("timed out"))})}updateJoinPayload(e){this.joinPush.updatePayload(e)}unsubscribe(e=this.timeout){this.state=ut.leaving;const n=()=>{this.socket.log("channel",`leave ${this.topic}`),this._trigger(Dn.close,"leave",this._joinRef())};this.joinPush.destroy();let r=null;return new Promise(o=>{r=new sf(this,Dn.leave,{},e),r.receive("ok",()=>{n(),o("ok")}).receive("timeout",()=>{n(),o("timed out")}).receive("error",()=>{o("error")}),r.send(),this._canPush()||r.trigger("ok",{})}).finally(()=>{r==null||r.destroy()})}teardown(){this.pushBuffer.forEach(e=>e.destroy()),this.pushBuffer=[],this.rejoinTimer.reset(),this.joinPush.destroy(),this.state=ut.closed,this.bindings={}}async _fetchWithTimeout(e,n,r){const o=new AbortController,a=setTimeout(()=>o.abort(),r),l=await this.socket.fetch(e,Object.assign(Object.assign({},n),{signal:o.signal}));return clearTimeout(a),l}_push(e,n,r=this.timeout){if(!this.joinedOnce)throw`tried to push '${e}' to '${this.topic}' before joining. Use channel.subscribe() before pushing events`;let o=new sf(this,e,n,r);return this._canPush()?o.send():this._addToPushBuffer(o),o}_addToPushBuffer(e){if(e.startTimeout(),this.pushBuffer.push(e),this.pushBuffer.length>y2){const n=this.pushBuffer.shift();n&&(n.destroy(),this.socket.log("channel",`discarded push due to buffer overflow: ${n.event}`,n.payload))}}_onMessage(e,n,r){return n}_isMember(e){return this.topic===e}_joinRef(){return this.joinPush.ref}_trigger(e,n,r){var o,a;const l=e.toLocaleLowerCase(),{close:c,error:d,leave:f,join:p}=Dn;if(r&&[c,d,f,p].indexOf(l)>=0&&r!==this._joinRef())return;let x=this._onMessage(l,n,r);if(n&&!x)throw"channel onMessage callbacks must return the payload, modified or unmodified";["insert","update","delete"].includes(l)?(o=this.bindings.postgres_changes)===null||o===void 0||o.filter(y=>{var _,S,b;return((_=y.filter)===null||_===void 0?void 0:_.event)==="*"||((b=(S=y.filter)===null||S===void 0?void 0:S.event)===null||b===void 0?void 0:b.toLocaleLowerCase())===l}).map(y=>y.callback(x,r)):(a=this.bindings[l])===null||a===void 0||a.filter(y=>{var _,S,b,k,P,C;if(["broadcast","presence","postgres_changes"].includes(l))if("id"in y){const A=y.id,L=(_=y.filter)===null||_===void 0?void 0:_.event;return A&&((S=n.ids)===null||S===void 0?void 0:S.includes(A))&&(L==="*"||(L==null?void 0:L.toLocaleLowerCase())===((b=n.data)===null||b===void 0?void 0:b.type.toLocaleLowerCase()))}else{const A=(P=(k=y==null?void 0:y.filter)===null||k===void 0?void 0:k.event)===null||P===void 0?void 0:P.toLocaleLowerCase();return A==="*"||A===((C=n==null?void 0:n.event)===null||C===void 0?void 0:C.toLocaleLowerCase())}else return y.type.toLocaleLowerCase()===l}).map(y=>{if(typeof x=="object"&&"ids"in x){const _=x.data,{schema:S,table:b,commit_timestamp:k,type:P,errors:C}=_;x=Object.assign(Object.assign({},{schema:S,table:b,commit_timestamp:k,eventType:P,new:{},old:{},errors:C}),this._getPayloadRecords(_))}y.callback(x,r)})}_isClosed(){return this.state===ut.closed}_isJoined(){return this.state===ut.joined}_isJoining(){return this.state===ut.joining}_isLeaving(){return this.state===ut.leaving}_replyEventName(e){return`chan_reply_${e}`}_on(e,n,r){const o=e.toLocaleLowerCase(),a={type:o,filter:n,callback:r};return this.bindings[o]?this.bindings[o].push(a):this.bindings[o]=[a],this}_off(e,n){const r=e.toLocaleLowerCase();return this.bindings[r]&&(this.bindings[r]=this.bindings[r].filter(o=>{var a;return!(((a=o.type)===null||a===void 0?void 0:a.toLocaleLowerCase())===r&&so.isEqual(o.filter,n))})),this}static isEqual(e,n){if(Object.keys(e).length!==Object.keys(n).length)return!1;for(const r in e)if(e[r]!==n[r])return!1;return!0}static isFilterValueEqual(e,n){return(e??void 0)===(n??void 0)}_rejoinUntilConnected(){this.rejoinTimer.scheduleTimeout(),this.socket.isConnected()&&this._rejoin()}_onClose(e){this._on(Dn.close,{},e)}_onError(e){this._on(Dn.error,{},n=>e(n))}_canPush(){return this.socket.isConnected()&&this._isJoined()}_rejoin(e=this.timeout){this._isLeaving()||(this.socket._leaveOpenTopic(this.topic),this.state=ut.joining,this.joinPush.resend(e))}_getPayloadRecords(e){const n={new:{},old:{}};return(e.type==="INSERT"||e.type==="UPDATE")&&(n.new=H0(e.columns,e.record)),(e.type==="UPDATE"||e.type==="DELETE")&&(n.old=H0(e.columns,e.old_record)),n}}const of=()=>{},Wu={HEARTBEAT_INTERVAL:25e3,RECONNECT_DELAY:10,HEARTBEAT_TIMEOUT_FALLBACK:100},T2=[1e3,2e3,5e3,1e4],k2=1e4,C2=`
272  addEventListener("message", (e) => {
273    if (e.data.event === "start") {
274      setInterval(() => postMessage({ event: "keepAlive" }), e.data.interval);
275    }
276  });`;class P2{constructor(e,n){var r;if(this.accessTokenValue=null,this.apiKey=null,this._manuallySetToken=!1,this.channels=new Array,this.endPoint="",this.httpEndpoint="",this.headers={},this.params={}
276,this.timeout=dp,this.transport=null,this.heartbeatIntervalMs=Wu.HEARTBEAT_INTERVAL,this.heartbeatTimer=void 0,this.pendingHeartbeatRef=null,this.heartbeatCallback=of,this.ref=0,this.reconnectTimer=null,this.vsn=W0,this.logger=of,this.conn=null,this.sendBuffer=[],this.serializer=new v2,this.stateChangeCallbacks={open:[],close:[],error:[],message:[]},this.accessToken=null,this._connectionState="disconnected",this._wasManualDisconnect=!1,this._authPromise=null,this._heartbeatSentAt=null,this._resolveFetch=o=>o?(...a)=>o(...a):(...a)=>fetch(...a),!(!((r=n==null?void 0:n.params)===null||r===void 0)&&r.apikey))throw new Error("API key is required to connect to Realtime");this.apiKey=n.params.apikey,this.endPoint=`${e}/${hp.websocket}`,this.httpEndpoint=aS(e),this._initializeOptions(n),this._setupReconnectionTimer(),this.fetch=this._resolveFetch(n==null?void 0:n.fetch)}connect(){if(!(this.isConnecting()||this.isDisconnecting()||this.conn!==null&&this.isConnected())){if(this._setConnectionState("connecting"),this.accessToken&&!this._authPromise&&this._setAuthSafely("connect"),this.transport)this.conn=new this.transport(this.endpointURL());else try{this.conn=h2.createWebSocket(this.endpointURL())}catch(e){this._setConnectionState("disconnected");const n=e.message;throw n.includes("Node.js")?new Error(`${n}
277
278To use Realtime in Node.js, you need to provide a WebSocket implementation:
279
280Option 1: Use Node.js 22+ which has native WebSocket support
281Option 2: Install and provide the "ws" package:
282
283  npm install ws
284
285  import ws from "ws"
286  const client = new RealtimeClient(url, {
287    ...options,
288    transport: ws
289  })`):new Error(`WebSocket not available: ${n}`)}this._setupConnectionHandlers()}}endpointURL(){return this._appendParams(this.endPoint,Object.assign({},this.params,{vsn:this.vsn}))}disconnect(e,n){if(!this.isDisconnecting())if(this._setConnectionState("disconnecting",!0),this.conn){const r=setTimeout(()=>{this._setConnectionState("disconnected")},100);this.conn.onclose=()=>{clearTimeout(r),this._setConnectionState("disconnected")},typeof this.conn.close=="function"&&(e?this.conn.close(e,n??""):this.conn.close()),this._teardownConnection()}else this._setConnectionState("disconnected")}getChannels(){return this.channels}async removeChannel(e){const n=await e.unsubscribe();return this.channels.length===0&&this.disconnect(),n}async removeAllChannels(){const e=await Promise.all(this.channels.map(n=>n.unsubscribe()));return this.channels=[],this.disconnect(),e}log(e,n,r){this.logger(e,n,r)}connectionState(){switch(this.conn&&this.conn.readyState){case as.connecting:return Ys.Connecting;case as.open:return Ys.Open;case as.closing:return Ys.Closing;default:return Ys.Closed}}isConnected(){return this.connectionState()===Ys.Open}isConnecting(){return this._connectionState==="connecting"}isDisconnecting(){return this._connectionState==="disconnecting"}channel(e,n={config:{}}){const r=`realtime:${e}`,o=this.getChannels().find(a=>a.topic===r);if(o)return o;{const a=new so(`realtime:${e}`,n,this);return this.channels.push(a),a}}push(e){const{topic:n,event:r,payload:o,ref:a}=e,l=()=>{this.encode(e,c=>{var d;(d=this.conn)===null||d===void 0||d.send(c)})};this.log("push",`${n} ${r} (${a})`,o),this.isConnected()?l():this.sendBuffer.push(l)}async setAuth(e=null){this._authPromise=this._performAuth(e);try{await this._authPromise}finally{this._authPromise=null}}_isManualToken(){return this._manuallySetToken}async sendHeartbeat(){var e;if(!this.isConnected()){try{this.heartbeatCallback("disconnected")}catch(n){this.log("error","error in heartbeat callback",n)}return}if(this.pendingHeartbeatRef){this.pendingHeartbeatRef=null,this._heartbeatSentAt=null,this.log("transport","heartbeat timeout. Attempting to re-establish connection");try{this.heartbeatCallback("timeout")}catch(n){this.log("error","error in heartbeat callback",n)}this._wasManualDisconnect=!1,(e=this.conn)===null||e===void 0||e.close(g2,"heartbeat timeout"),setTimeout(()=>{var n;this.isConnected()||(n=this.reconnectTimer)===null||n===void 0||n.scheduleTimeout()},Wu.HEARTBEAT_TIMEOUT_FALLBACK);return}this._heartbeatSentAt=Date.now(),this.pendingHeartbeatRef=this._makeRef(),this.push({topic:"phoenix",event:"heartbeat",payload:{},ref:this.pendingHeartbeatRef});try{this.heartbeatCallback("sent")}catch(n){this.log("error","error in heartbeat callback",n)}this._setAuthSafely("heartbeat")}onHeartbeat(e){this.heartbeatCallback=e}flushSendBuffer(){this.isConnected()&&this.sendBuffer.length>
2890&&(this.sendBuffer.forEach(e=>e()),this.sendBuffer=[])}_makeRef(){let e=this.ref+1;return e===this.ref?this.ref=0:this.ref=e,this.ref.toString()}_leaveOpenTopic(e){let n=this.channels.find(r=>r.topic===e&&(r._isJoined()||r._isJoining()));n&&(this.log("transport",`leaving duplicate topic "${e}"`),n.unsubscribe())}_remove(e){this.channels=this.channels.filter(n=>n.topic!==e.topic)}_onConnMessage(e){this.decode(e.data,n=>{if(n.topic==="phoenix"&&n.event==="phx_reply"&&n.ref&&n.ref===this.pendingHeartbeatRef){const f=this._heartbeatSentAt?Date.now()-this._heartbeatSentAt:void 0;try{this.heartbeatCallback(n.payload.status==="ok"?"ok":"error",f)}catch(p){this.log("error","error in heartbeat callback",p)}this._heartbeatSentAt=null,this.pendingHeartbeatRef=null}const{topic:r,event:o,payload:a,ref:l}=n,c=l?`(${l})`:"",d=a.status||"";this.log("receive",`${d} ${r} ${o} ${c}`.trim(),a),this.channels.filter(f=>f._isMember(r)).forEach(f=>f._trigger(o,a,l)),this._triggerStateCallbacks("message",n)})}_clearTimer(e){var n;e==="heartbeat"&&this.heartbeatTimer?(clearInterval(this.heartbeatTimer),this.heartbeatTimer=void 0):e==="reconnect"&&((n=this.reconnectTimer)===null||n===void 0||n.reset())}_clearAllTimers(){this._clearTimer("heartbeat"),this._clearTimer("reconnect")}_setupConnectionHandlers(){this.conn&&("binaryType"in this.conn&&(this.conn.binaryType="arraybuffer"),this.conn.onopen=()=>this._onConnOpen(),this.conn.onerror=e=>this._onConnError(e),this.conn.onmessage=e=>this._onConnMessage(e),this.conn.onclose=e=>this._onConnClose(e),this.conn.readyState===as.open&&this._onConnOpen())}_teardownConnection(){if(this.conn){if(this.conn.readyState===as.open||this.conn.readyState===as.connecting)try{this.conn.close()}catch(e){this.log("error","Error closing connection",e)}this.conn.onopen=null,this.conn.onerror=null,this.conn.onmessage=null,this.conn.onclose=null,this.conn=null}this._clearAllTimers(),this._terminateWorker(),this.channels.forEach(e=>e.teardown())}_onConnOpen(){this._setConnectionState("connected"),this.log("transport",`connected to ${this.endpointURL()}`),(this._authPromise||(this.accessToken&&!this.accessTokenValue?this.setAuth():Promise.resolve())).then(()=>{this.accessTokenValue&&(this.channels.forEach(n=>{n.updateJoinPayload({access_token:this.accessTokenValue})}),this.sendBuffer=[],this.channels.forEach(n=>{n._isJoining()&&(n.joinPush.sent=!1,n.joinPush.send())})),this.flushSendBuffer()}).catch(n=>{this.log("error","error waiting for auth on connect",n),this.flushSendBuffer()}),this._clearTimer("reconnect"),this.worker?this.workerRef||this._startWorkerHeartbeat():this._startHeartbeat(),this._triggerStateCallbacks("open")}_startHeartbeat(){this.heartbeatTimer&&clearInterval(this.heartbeatTimer),this.heartbeatTimer=setInterval(()=>this.sendHeartbeat(),this.heartbeatIntervalMs)}_startWorkerHeartbeat(){this.workerUrl?this.log("worker",`starting worker for from ${this.workerUrl}`):this.log("worker","starting default worker");const e=this._workerObjectUrl(this.workerUrl);this.workerRef=new Worker(e),this.workerRef.onerror=n=>{this.log("worker","worker error",n.message),this._terminateWorker()},this.workerRef.onmessage=n=>{n.data.event==="keepAlive"&&this.sendHeartbeat()},this.workerRef.postMessage({event:"start",interval:this.heartbeatIntervalMs})}_terminateWorker(){this.workerRef&&(this.log("worker","terminating worker"),this.workerRef.terminate(),this.workerRef=void 0)}_onConnClose(e){var n;this._setConnectionState("disconnected"),this.log("transport","close",e),this._triggerChanError(),this._clearTimer("heartbeat"),this._wasManualDisconnect||(n=this.reconnectTimer)===null||n===void 0||n.scheduleTimeout(),this._triggerStateCallbacks("close",e)}_onConnError(e){this._setConnectionState("disconnected"),this.log("transport",`${e}`),this._triggerChanError(),this._triggerStateCallbacks("error",e);try{this.heartbeatCallback("error")}catch(n){this.log("error","error in heartbeat callback",n)}}_triggerChanError(){this.channels.forEach(e=>e._trigger(Dn.error))}_appendParams(e,n){if(Object.keys(n).length===0)return e;const r=e.match(/\?/)?"&":"?",o=new URLSearchParams(n);return`${e}${r}${o}`}_workerObjectUrl(e){let n;if(e)n=e;else{const r=new Blob([C2],{type:"application/javascript"});n=URL.createObjectURL(r)}return n}_setConnectionState(e,n=!1){this._connectionState=e,e==="connecting"?this._wasManualDisconnect=!1:e==="disconnecting"&&(this._wasManualDisconnect=n)}async _performAuth(e=null){let n,r=!1;if(e)n=e,r=!0;else if(this.accessToken)try{n=await this.accessToken()}catch(o){this.log("error","Error fetching access token from callback",o),n=this.accessTokenValue}else n=this.accessTokenValue;r?this._manuallySetToken=!0:this.accessToken&&(this._manuallySetToken=!1),this.accessTokenValue!=n&&(this.accessTokenValue=n,this.channels.forEac
289h(o=>{const a={access_token:n,version:p2};n&&o.updateJoinPayload(a),o.joinedOnce&&o._isJoined()&&o._push(Dn.access_token,{access_token:n})}))}async _waitForAuthIfNeeded(){this._authPromise&&await this._authPromise}_setAuthSafely(e="general"){this._isManualToken()||this.setAuth().catch(n=>{this.log("error",`Error setting auth in ${e}`,n)})}_triggerStateCallbacks(e,n){try{this.stateChangeCallbacks[e].forEach(r=>{try{r(n)}catch(o){this.log("error",`error in ${e} callback`,o)}})}catch(r){this.log("error",`error triggering ${e} callbacks`,r)}}_setupReconnectionTimer(){this.reconnectTimer=new iS(async()=>{setTimeout(async()=>{await this._waitForAuthIfNeeded(),this.isConnected()||this.connect()},Wu.RECONNECT_DELAY)},this.reconnectAfterMs)}_initializeOptions(e){var n,r,o,a,l,c,d,f,p,g,x,y;switch(this.transport=(n=e==null?void 0:e.transport)!==null&&n!==void 0?n:null,this.timeout=(r=e==null?void 0:e.timeout)!==null&&r!==void 0?r:dp,this.heartbeatIntervalMs=(o=e==null?void 0:e.heartbeatIntervalMs)!==null&&o!==void 0?o:Wu.HEARTBEAT_INTERVAL,this.worker=(a=e==null?void 0:e.worker)!==null&&a!==void 0?a:!1,this.accessToken=(l=e==null?void 0:e.accessToken)!==null&&l!==void 0?l:null,this.heartbeatCallback=(c=e==null?void 0:e.heartbeatCallback)!==null&&c!==void 0?c:of,this.vsn=(d=e==null?void 0:e.vsn)!==null&&d!==void 0?d:W0,e!=null&&e.params&&(this.params=e.params),e!=null&&e.logger&&(this.logger=e.logger),(e!=null&&e.logLevel||e!=null&&e.log_level)&&(this.logLevel=e.logLevel||e.log_level,this.params=Object.assign(Object.assign({},this.params),{log_level:this.logLevel})),this.reconnectAfterMs=(f=e==null?void 0:e.reconnectAfterMs)!==null&&f!==void 0?f:(_=>T2[_-1]||k2),this.vsn){case m2:this.encode=(p=e==null?void 0:e.encode)!==null&&p!==void 0?p:((_,S)=>S(JSON.stringify(_))),this.decode=(g=e==null?void 0:e.decode)!==null&&g!==void 0?g:((_,S)=>S(JSON.parse(_)));break;case sS:this.encode=(x=e==null?void 0:e.encode)!==null&&x!==void 0?x:this.serializer.encode.bind(this.serializer),this.decode=(y=e==null?void 0:e.decode)!==null&&y!==void 0?y:this.serializer.decode.bind(this.serializer);break;default:throw new Error(`Unsupported serializer version: ${this.vsn}`)}if(this.worker){if(typeof window<"u"&&!window.Worker)throw new Error("Web Worker is not supported");this.workerUrl=e==null?void 0:e.workerUrl}}}var Ga=class extends Error{constructor(t,e){var n;super(t),this.name="IcebergError",this.status=e.status,this.icebergType=e.icebergType,this.icebergCode=e.icebergCode,this.details=e.details,this.isCommitStateUnknown=e.icebergType==="CommitStateUnknownException"||[500,502,504].includes(e.status)&&((n=e.icebergType)==null?void 0:n.includes("CommitState"))===!0}isNotFound(){return this.status===404}isConflict(){return this.status===409}isAuthenticationTimeout(){return this.status===419}};function A2(t,e,n){const r=new URL(e,t);if(n)for(const[o,a]of Object.entries(n))a!==void 0&&r.searchParams.set(o,a);return r.toString()}async function R2(t){return!t||t.type==="none"?{}:t.type==="bearer"?{Authorization:`Bearer ${t.token}`}:t.type==="header"?{[t.name]:t.value}:t.type==="custom"?await t.getHeaders():{}}function j2(t){const e=t.fetchImpl??globalThis.fetch;return{async request({method:n,path:r,query:o,body:a,headers:l}){const c=A2(t.baseUrl,r,o),d=await R2(t.auth),f=await e(c,{method:n,headers:{...a?{"Content-Type":"application/json"}:{},...d,...l},body:a?JSON.stringify(a):void 0}),p=await f.text(),g=(f.headers.get("content-type")||"").includes("application/json"),x=g&&p?JSON.parse(p):p;if(!f.ok){const y=g?x:void 0,_=y==null?void 0:y.error;throw new Ga((_==null?void 0:_.message)??`Request failed with status ${f.status}`,{status:f.status,icebergType:_==null?void 0:_.type,icebergCode:_==null?void 0:_.code,details:y})}return{status:f.status,headers:f.headers,data:x}}}}function Hu(t){return t.join("�")}var O2=class{constructor(t,e=""){this.client=t,this.prefix=e}async listNamespaces(t){const e=t?{parent:Hu(t.namespace)}:void 0;return(await this.client.request({method:"GET",path:`${this.prefix}/namespaces`,query:e})).data.namespaces.map(r=>({namespace:r}))}async createNamespace(t,e){const n={namespace:t.namespace,properties:e==null?void 0:e.properties};return(await this.client.request({method:"POST",path:`${this.prefix}/namespaces`,body:n})).data}async dropNamespace(t){await this.client.request({method:"DELETE",path:`${this.prefix}/namespaces/${Hu(t.namespace)}`})}async loadNamespaceMetadata(t){return{properties:(await this.client.request({method:"GET",path:`${this.prefix}/namespaces/${Hu(t.namespace)}`})).data.properties}}async namespaceExists(t){try{return await this.client.request({method:"HEAD",path:`${this.prefix}/namespaces/${Hu(t.namespace)}`}),!0}catch(e){if(e instanceof Ga&&e.status===404)return!1;throw e}}async createNamespaceIfNotExists(t,e){try{return await this.createNamespace(t,e)}catch(n){if(n instanceof Ga&&n.status===409)return;throw n}}};function Gi(t){return t.join("�")}var N2=class{constructor(t,e="",n){this.client=t,this.prefix=e,this.accessDelegation=n}async listTables(t){return(await this.client.request({method:"GET",path:`${this.prefix}/namespaces/${Gi(t.namespace)}/tables`})).data.identifiers}async createTable(t,e){const n={};return this.accessDelegation&&(n["X-Iceberg-Access-Delegation"]=this.accessDelegation),(await this.client.request({method:"POST",path:`${this.prefix}/namespaces/${Gi(t.namespace)}/tables`,body:e,headers:n})).data.metadata}async updateTable(t,e){const n=await this.client.request({method:"POST",path:`${this.prefix}/namespaces/${Gi(t.namespace)}
289/tables/${t.name}`,body:e});return{"metadata-location":n.data["metadata-location"],metadata:n.data.metadata}}async dropTable(t,e){await this.client.request({method:"DELETE",path:`${this.prefix}/namespaces/${Gi(t.namespace)}/tables/${t.name}`,query:{purgeRequested:String((e==null?void 0:e.purge)??!1)}})}async loadTable(t){const e={};return this.accessDelegation&&(e["X-Iceberg-Access-Delegation"]=this.accessDelegation),(await this.client.request({method:"GET",path:`${this.prefix}/namespaces/${Gi(t.namespace)}/tables/${t.name}`,headers:e})).data.metadata}async tableExists(t){const e={};this.accessDelegation&&(e["X-Iceberg-Access-Delegation"]=this.accessDelegation);try{return await this.client.request({method:"HEAD",path:`${this.prefix}/namespaces/${Gi(t.namespace)}/tables/${t.name}`,headers:e}),!0}catch(n){if(n instanceof Ga&&n.status===404)return!1;throw n}}async createTableIfNotExists(t,e){try{return await this.createTable(t,e)}catch(n){if(n instanceof Ga&&n.status===409)return await this.loadTable({namespace:t.namespace,name:e.name});throw n}}},I2=class{constructor(t){var r;let e="v1";t.catalogName&&(e+=`/${t.catalogName}`);const n=t.baseUrl.endsWith("/")?t.baseUrl:`${t.baseUrl}/`;this.client=j2({baseUrl:n,auth:t.auth,fetchImpl:t.fetch}),this.accessDelegation=(r=t.accessDelegation)==null?void 0:r.join(","),this.namespaceOps=new O2(this.client,e),this.tableOps=new N2(this.client,e,this.accessDelegation)}async listNamespaces(t){return this.namespaceOps.listNamespaces(t)}async createNamespace(t,e){return this.namespaceOps.createNamespace(t,e)}async dropNamespace(t){await this.namespaceOps.dropNamespace(t)}async loadNamespaceMetadata(t){return this.namespaceOps.loadNamespaceMetadata(t)}async listTables(t){return this.tableOps.listTables(t)}async createTable(t,e){return this.tableOps.createTable(t,e)}async updateTable(t,e){return this.tableOps.updateTable(t,e)}async dropTable(t,e){await this.tableOps.dropTable(t,e)}async loadTable(t){return this.tableOps.loadTable(t)}async namespaceExists(t){return this.namespaceOps.namespaceExists(t)}async tableExists(t){return this.tableOps.tableExists(t)}async createNamespaceIfNotExists(t,e){return this.namespaceOps.createNamespaceIfNotExists(t,e)}async createTableIfNotExists(t,e){return this.tableOps.createTableIfNotExists(t,e)}},Gc=class extends Error{constructor(t,e="storage",n,r){super(t),this.__isStorageError=!0,this.namespace=e,this.name=e==="vectors"?"StorageVectorsError":"StorageError",this.status=n,this.statusCode=r}};function Qc(t){return typeof t=="object"&&t!==null&&"__isStorageError"in t}var Ra=class extends Gc{constructor(t,e,n,r="storage"){super(t,r,e,n),this.name=r==="vectors"?"StorageVectorsApiError":"StorageApiError",this.status=e,this.statusCode=n}toJSON(){return{name:this.name,message:this.message,status:this.status,statusCode:this.statusCode}}},lS=class extends Gc{constructor(t,e,n="storage"){super(t,n),this.name=n==="vectors"?"StorageVectorsUnknownError":"StorageUnknownError",this.originalError=e}};const L2=t=>t?(...e)=>t(...e):(...e)=>fetch(...e),D2=t=>{if(typeof t!="object"||t===null)return!1;const e=Object.getPrototypeOf(t);return(e===null||e===Object.prototype||Object.getPrototypeOf(e)===null)&&!(Symbol.toStringTag in t)&&!(Symbol.iterator in t)},pp=t=>{if(Array.isArray(t))return t.map(n=>pp(n));if(typeof t=="function"||t!==Object(t))return t;const e={};return Object.entries(t).forEach(([n,r])=>{const o=n.replace(/([-_][a-z])/gi,a=>a.toUpperCase().replace(/[-_]/g,""));e[o]=pp(r)}),e},M2=t=>!t||typeof t!="string"||t.length===0||t.length>100||t.trim()!==t||t.includes("/")||t.includes("\\")?!1:/^[\w!.\*'() &$@=;:+,?-]+$/.test(t);function Qa(t){"@babel/helpers - typeof";return Qa=typeof Symbol=="function"&&typeof Symbol.iterator=="symbol"?function(e){return typeof e}:function(e){return e&&typeof Symbol=="function"&&e.constructor===Symbol&&e!==Symbol.prototype?"symbol":typeof e},Qa(t)}function $2(t,e){if(Qa(t)!="object"||!t)return t;var n=t[Symbol.toPrimitive];if(n!==void 0){var r=n.call(t,e);if(Qa(r)!="object")return r;throw new TypeError("@@toPrimitive must return a primitive value.")}return(e==="string"?String:Number)(t)}function F2(t){var e=$2(t,"string");return Qa(e)=="symbol"?e:e+""}function U2(t,e,n){return(e=F2(e))in t?Object.defineProperty(t,e,{value:n,enumerable:!0,configurable:!0,writable:!0}):t[e]=n,t}function G0(t,e){var n=Object.keys(t);if(Object.getOwnPropertySymbols){var r=Object.getOwnPropertySymbols(t);e&&(r=r.filter(function(o){return Object.getOwnPropertyDescriptor(t,o).enumerable})),n.push.apply(n,r)}return n}function Se(t){for(var e=1;e<arguments.length;e++){var n=arguments[e]!=null?arguments[e]:{};
289e%2?G0(Object(n),!0).forEach(function(r){U2(t,r,n[r])}):Object.getOwnPropertyDescriptors?Object.defineProperties(t,Object.getOwnPropertyDescriptors(n)):G0(Object(n)).forEach(function(r){Object.defineProperty(t,r,Object.getOwnPropertyDescriptor(n,r))})}return t}const Q0=t=>{var e;return t.msg||t.message||t.error_description||(typeof t.error=="string"?t.error:(e=t.error)===null||e===void 0?void 0:e.message)||JSON.stringify(t)},V2=async(t,e,n,r)=>{if(t&&typeof t=="object"&&"status"in t&&"ok"in t&&typeof t.status=="number"){const o=t,a=o.status||500;if(typeof o.json=="function")o.json().then(l=>{const c=(l==null?void 0:l.statusCode)||(l==null?void 0:l.code)||a+"";e(new Ra(Q0(l),a,c,r))}).catch(()=>{if(r==="vectors"){const l=a+"";e(new Ra(o.statusText||`HTTP ${a} error`,a,l,r))}else{const l=a+"";e(new Ra(o.statusText||`HTTP ${a} error`,a,l,r))}});else{const l=a+"";e(new Ra(o.statusText||`HTTP ${a} error`,a,l,r))}}else e(new lS(Q0(t),t,r))},B2=(t,e,n,r)=>{const o={method:t,headers:(e==null?void 0:e.headers)||{}};return t==="GET"||t==="HEAD"||!r?Se(Se({},o),n):(D2(r)?(o.headers=Se({"Content-Type":"application/json"},e==null?void 0:e.headers),o.body=JSON.stringify(r)):o.body=r,e!=null&&e.duplex&&(o.duplex=e.duplex),Se(Se({},o),n))};async function ka(t,e,n,r,o,a,l){return new Promise((c,d)=>{t(n,B2(e,r,o,a)).then(f=>{if(!f.ok)throw f;if(r!=null&&r.noResolveJson)return f;if(l==="vectors"){const p=f.headers.get("content-type");if(f.headers.get("content-length")==="0"||f.status===204)return{};if(!p||!p.includes("application/json"))return{}}return f.json()}).then(f=>c(f)).catch(f=>V2(f,d,r,l))})}function uS(t="storage"){return{get:async(e,n,r,o)=>ka(e,"GET",n,r,o,void 0,t),post:async(e,n,r,o,a)=>ka(e,"POST",n,o,a,r,t),put:async(e,n,r,o,a)=>ka(e,"PUT",n,o,a,r,t),head:async(e,n,r,o)=>ka(e,"HEAD",n,Se(Se({},r),{},{noResolveJson:!0}),o,void 0,t),remove:async(e,n,r,o,a)=>ka(e,"DELETE",n,o,a,r,t)}}const z2=uS("storage"),{get:Ya,post:On,put:mp,head:W2,remove:vm}=z2,nn=uS("vectors");var Lo=class{constructor(t,e={},n,r="storage"){this.shouldThrowOnError=!1,this.url=t,this.headers=e,this.fetch=L2(n),this.namespace=r}throwOnError(){return this.shouldThrowOnError=!0,this}setHeader(t,e){return this.headers=Se(Se({},this.headers),{},{[t]:e}),this}async handleOperation(t){var e=this;try{return{data:await t(),error:null}}catch(n){if(e.shouldThrowOnError)throw n;if(Qc(n))return{data:null,error:n};throw n}}},H2=class{constructor(t,e){this.downloadFn=t,this.shouldThrowOnError=e}then(t,e){return this.execute().then(t,e)}async execute(){var t=this;try{return{data:(await t.downloadFn()).body,error:null}}catch(e){if(t.shouldThrowOnError)throw e;if(Qc(e))return{data:null,error:e};throw e}}};let cS;cS=Symbol.toStringTag;var q2=class{constructor(t,e){this.downloadFn=t,this.shouldThrowOnError=e,this[cS]="BlobDownloadBuilder",this.promise=null}asStream(){return new H2(this.downloadFn,this.shouldThrowOnError)}then(t,e){return this.getPromise().then(t,e)}catch(t){return this.getPromise().catch(t)}finally(t){return this.getPromise().finally(t)}getPromise(){return this.promise||(this.promise=this.execute()),this.promise}async execute(){var t=this;try{return{data:await(await t.downloadFn()).blob(),error:null}}catch(e){if(t.shouldThrowOnError)throw e;if(Qc(e))return{data:null,error:e};throw e}}};const K2={limit:100,offset:0,sortBy:{column:"name",order:"asc"}},Y0={cacheControl:"3600",contentType:"text/plain;charset=UTF-8",upsert:!1};var G2=class extends Lo{constructor(t,e={},n,r){super(t,e,r,"storage"),this.bucketId=n}async uploadOrUpdate(t,e,n,r){var o=this;return o.handleOperation(async()=>{let a;const l=Se(Se({},Y0),r);let c=Se(Se({},o.headers),t==="POST"&&{"x-upsert":String(l.upsert)});const d=l.metadata;typeof Blob<"u"&&n instanceof Blob?(a=new FormData,a.append("cacheControl",l.cacheControl),d&&a.append("metadata",o.encodeMetadata(d)),a.append("",n)):typeof FormData<"u"&&n instanceof FormData?(a=n,a.has("cacheControl")||a.append("cacheControl",l.cacheControl),d&&!a.has("metadata")&&a.append("metadata",o.encodeMetadata(d))):(a=n,c["cache-control"]=`max-age=${l.cacheControl}`,c["content-type"]=l.contentType,d&&(c["x-metadata"]=o.toBase64(o.encodeMetadata(d))),(typeof ReadableStream<"u"&&a 
289instanceof ReadableStream||a&&typeof a=="object"&&"pipe"in a&&typeof a.pipe=="function")&&!l.duplex&&(l.duplex="half")),r!=null&&r.headers&&(c=Se(Se({},c),r.headers));const f=o._removeEmptyFolders(e),p=o._getFinalPath(f),g=await(t=="PUT"?mp:On)(o.fetch,`${o.url}/object/${p}`,a,Se({headers:c},l!=null&&l.duplex?{duplex:l.duplex}:{}));return{path:f,id:g.Id,fullPath:g.Key}})}async upload(t,e,n){return this.uploadOrUpdate("POST",t,e,n)}async uploadToSignedUrl(t,e,n,r){var o=this;const a=o._removeEmptyFolders(t),l=o._getFinalPath(a),c=new URL(o.url+`/object/upload/sign/${l}`);return c.searchParams.set("token",e),o.handleOperation(async()=>{let d;const f=Se({upsert:Y0.upsert},r),p=Se(Se({},o.headers),{"x-upsert":String(f.upsert)});return typeof Blob<"u"&&n instanceof Blob?(d=new FormData,d.append("cacheControl",f.cacheControl),d.append("",n)):typeof FormData<"u"&&n instanceof FormData?(d=n,d.append("cacheControl",f.cacheControl)):(d=n,p["cache-control"]=`max-age=${f.cacheControl}`,p["content-type"]=f.contentType),{path:a,fullPath:(await mp(o.fetch,c.toString(),d,{headers:p})).Key}})}async createSignedUploadUrl(t,e){var n=this;return n.handleOperation(async()=>{let r=n._getFinalPath(t);const o=Se({},n.headers);e!=null&&e.upsert&&(o["x-upsert"]="true");const a=await On(n.fetch,`${n.url}/object/upload/sign/${r}`,{},{headers:o}),l=new URL(n.url+a.url),c=l.searchParams.get("token");if(!c)throw new Gc("No token returned by API");return{signedUrl:l.toString(),path:t,token:c}})}async update(t,e,n){return this.uploadOrUpdate("PUT",t,e,n)}async move(t,e,n){var r=this;return r.handleOperation(async()=>await On(r.fetch,`${r.url}/object/move`,{bucketId:r.bucketId,sourceKey:t,destinationKey:e,destinationBucket:n==null?void 0:n.destinationBucket},{headers:r.headers}))}async copy(t,e,n){var r=this;return r.handleOperation(async()=>({path:(await On(r.fetch,`${r.url}/object/copy`,{bucketId:r.bucketId,sourceKey:t,destinationKey:e,destinationBucket:n==null?void 0:n.destinationBucket},{headers:r.headers})).Key}))}async createSignedUrl(t,e,n){var r=this;return r.handleOperation(async()=>{let o=r._getFinalPath(t);const a=typeof(n==null?void 0:n.transform)=="object"&&n.transform!==null&&Object.keys(n.transform).length>0;let l=await On(r.fetch,`${r.url}/object/sign/${o}`,Se({expiresIn:e},a?{transform:n.transform}:{}),{headers:r.headers});const c=n!=null&&n.download?`&download=${n.download===!0?"":n.download}`:"",d=a&&l.signedURL.includes("/object/sign/")?l.signedURL.replace("/object/sign/","/render/image/sign/"):l.signedURL;return{signedUrl:encodeURI(`${r.url}${d}${c}`)}})}async createSignedUrls(t,e,n){var r=this;return r.handleOperation(async()=>{const o=await On(r.fetch,`${r.url}/object/sign/${r.bucketId}`,{expiresIn:e,paths:t},{headers:r.headers}),a=n!=null&&n.download?`&download=${n.download===!0?"":n.download}`:"";return o.map(l=>Se(Se({},l),{},{signedUrl:l.signedURL?encodeURI(`${r.url}${l.signedURL}${a}`):null}))})}download(t,e,n){const r=typeof(e==null?void 0:e.transform)<"u"?"render/image/authenticated":"object",o=this.transformOptsToQueryString((e==null?void 0:e.transform)||{}),a=o?`?${o}`:"",l=this._getFinalPath(t),c=()=>Ya(this.fetch,`${this.url}/${r}/${l}${a}`,{headers:this.headers,noResolveJson:!0},n);return new q2(c,this.shouldThrowOnError)}async info(t){var e=this;const n=e._getFinalPath(t);return e.handleOperation(async()=>pp(await Ya(e.fetch,`${e.url}/object/info/${n}`,{headers:e.headers})))}async exists(t){var e=this;const n=e._getFinalPath(t);try{return await W2(e.fetch,`${e.url}/object/${n}`,{headers:e.headers}),{data:!0,error:null}}catch(o){if(e.shouldThrowOnError)throw o;if(Qc(o)){var r;const a=o instanceof Ra?o.status:o instanceof lS?(r=o.originalError)===null||r===void 0?void 0:r.status:void 0;if(a!==void 0&&[400,404].includes(a))return{data:!1,error:o}}throw o}}getPublicUrl(t,e){const n=this._getFinalPath(t),r=[],o=e!=null&&e.download?`download=${e.download===!0?"":e.download}`:"";o!==""&&r.push(o);const a=typeof(e==null?void 0:e.transform)<"u"?"render/image":"object",l=this.transformOptsToQueryString((e==null?void 0:e.transform)||{});l!==""&&r.push(l);let c=r.join("&");return c!==""&&(c=`?${c}`),{data:{publicUrl:encodeURI(`${this.url}/${a}/public/${n}${c}`)}}}async remove(t){var e=this;return e.handleOperation(async()=>await vm(e.fetch,`${e.url}/object/${e.bucketId}`,{prefixes:t},{headers:e.headers}))}async list(t,e,n){var r=this;return r.handleOperation(async()=>{const o=Se(Se(Se({},K2),e),{},{prefix:t||""});return await On(r.fetch,`${r.url}/object/list/${r.bucketId}`,o,{headers:r.headers},n)})}async listV2(t,e){var n=this;return n.handleOperation(async()=>{const r=Se({},t);return await On(n.fetch,`${n.url}/object/list-v2/${n.bucketId}`,r,{headers:n.headers},e)})}encodeMetadata(t){return JSON.stringify(t)}toBase64(t){return typeof Buffer<"u"?Buffer.from(t).toString("base64"):btoa(t)}_getFinalPath(t){return`${this.bucketId}/${t.replace(/^\/+/,"")}`}_removeEmptyFolders(t){return t.replace(/^\/|\/$/g,"").replace(/\/+/g,"/")}transformOptsToQueryString(t){const e=[];return t.width&&e.push(`width=${t.width}`),t.height&&e.push(`height=${t.height}`),t.resize&&e.push(`resize=${t.resize}`),t.format&&e.push(`format=${t.format}`),t.quality&&e.push(`quality=${t.quality}`),e.join("&")}};const Q2="2.99.2",gl={"X-Client-Info":`storage-js/${Q2}`};var Y2=class extends Lo{constructor(t,e={},n,r){const o=new URL(t);r!=null&&r.useNewHostname&&/supabase\.(co|in|red)$/.test(o.hostname)&&!o.hostname.includes("storage.supabase.")&&(o.hostname=o.hostname.replace("supabase.","storage.supabase."));const a=o.href.replace(/\/$/,""),l=Se(Se({},gl),e);super(a,l,n,"storage")}async listBuckets(t){var e=this;return e.handleOperation(async()=>{const n=e.listBucketOptionsToQueryString(t);return await Ya(e.fetch,`${e.url}/bucket${n}`,{headers:e.headers})})}async getBucket(t){var e=this;return e.handleOperation(async()=>await Ya(e.fetch,`${e.url}/bucket/${t}`,{headers:e.headers}))}async createBucket(t,e={public:!1}){var n=this;return n.handleOperation(async()=>await On(n.fetch,`${n.url}/bucket`,{id:t,name:t,type:e.type,public:e.public,file_size_limit:e.fileSizeLimit,allowed_mime_types:e.allowedMimeTypes},{headers:n.headers}))}async updateBucket(t,e){var n=this;return n.handleOperation(async()=>await mp(n.fetch,`${n.url}/bucket/${t}`,{id:t,name:t,public:e.public,file_size_limit:e.fileSizeLimit,allowed_mime_types:e.allowedMimeTypes},{headers:n.headers}))}async emptyBucket(t){var e=this;return e.handleOperation(async()=>await On(e.fetch,`${e.url}/bucket/${t}/empty`,{},{headers:e.headers}))}async deleteBucket(t){var e=this;return e.handleOperation(async()=>await vm(e.fetch,`${e.url}/bucket/${t}`,{},{headers:e.headers}))}listBucketOptionsToQueryString(t){const e={};return t&&("limit"in t&&(e.limit=String(t.limit)),"offset"in t&&(e.offset=String(t.offset)),t.search&&(e.search=t.search),t.sortColumn&&(e.sortColumn=t.sortColumn),t.sortOrder&&(e.sortOrder=t.sortOrder)),Object.keys(e).length>0?"?"+new URLSearchParams(e).toString():""}},J2=class extends Lo{constructor(t,e={},n){const r=t.replace(/\/$/,""),o=Se(Se({},gl),e);super(r,o,n,"storage")}async createBucket(t){var e=this;return e.handleOperation(async()=>await On(e.fetch,`${e.url}/bucket`,{name:t},{headers:e.headers}))}async listBuckets(t){var e=this;return e.handleOperation(async()=>{const n=new URLSearchParams;(t==null?void 0:t.limit)!==void 0&&n.set("limit",t.limit.toString()),(t==null?void 0:t.offset)!==void 0&&n.set("offset",t.offset.toString()),t!=null&&t.sortColumn&&n.set("sortColumn",t.sortColumn),t!=null&&t.sortOrder&&n.set("sortOrder",t.sortOrder),t!=null&&t.search&&n.set("search",t.search);const r=n.toString(),o=r?`${e.url}/bucket?${r}`:`${e.url}/bucket`;return await Ya(e.fetch,o,{headers:e.headers})})}async deleteBucket(t){var e=this;return e.handleOperation(async()=>await vm(e.fetch,`${e.url}/bucket/${t}`,{},{headers:e.headers}))}from(t){var e=this;if(!M2(t))throw new Gc("Invalid bucket name: File, folder, and bucket names must follow AWS object key naming guidelines and should avoid the use of any other characters.");const n=new I2({baseUrl:this.url,catalogName:t,auth:{type:"custom",getHeaders:async()=>e.headers},fetch:this.fetch}
289),r=this.shouldThrowOnError;return new Proxy(n,{get(o,a){const l=o[a];return typeof l!="function"?l:async(...c)=>{try{return{data:await l.apply(o,c),error:null}}catch(d){if(r)throw d;return{data:null,error:d}}}}})}},X2=class extends Lo{constructor(t,e={},n){const r=t.replace(/\/$/,""),o=Se(Se({},gl),{},{"Content-Type":"application/json"},e);super(r,o,n,"vectors")}async createIndex(t){var e=this;return e.handleOperation(async()=>await nn.post(e.fetch,`${e.url}/CreateIndex`,t,{headers:e.headers})||{})}async getIndex(t,e){var n=this;return n.handleOperation(async()=>await nn.post(n.fetch,`${n.url}/GetIndex`,{vectorBucketName:t,indexName:e},{headers:n.headers}))}async listIndexes(t){var e=this;return e.handleOperation(async()=>await nn.post(e.fetch,`${e.url}/ListIndexes`,t,{headers:e.headers}))}async deleteIndex(t,e){var n=this;return n.handleOperation(async()=>await nn.post(n.fetch,`${n.url}/DeleteIndex`,{vectorBucketName:t,indexName:e},{headers:n.headers})||{})}},Z2=class extends Lo{constructor(t,e={},n){const r=t.replace(/\/$/,""),o=Se(Se({},gl),{},{"Content-Type":"application/json"},e);super(r,o,n,"vectors")}async putVectors(t){var e=this;if(t.vectors.length<1||t.vectors.length>500)throw new Error("Vector batch size must be between 1 and 500 items");return e.handleOperation(async()=>await nn.post(e.fetch,`${e.url}/PutVectors`,t,{headers:e.headers})||{})}async getVectors(t){var e=this;return e.handleOperation(async()=>await nn.post(e.fetch,`${e.url}/GetVectors`,t,{headers:e.headers}))}async listVectors(t){var e=this;if(t.segmentCount!==void 0){if(t.segmentCount<1||t.segmentCount>16)throw new Error("segmentCount must be between 1 and 16");if(t.segmentIndex!==void 0&&(t.segmentIndex<0||t.segmentIndex>=t.segmentCount))throw new Error(`segmentIndex must be between 0 and ${t.segmentCount-1}`)}return e.handleOperation(async()=>await nn.post(e.fetch,`${e.url}/ListVectors`,t,{headers:e.headers}))}async queryVectors(t){var e=this;return e.handleOperation(async()=>await nn.post(e.fetch,`${e.url}/QueryVectors`,t,{headers:e.headers}))}async deleteVectors(t){var e=this;if(t.keys.length<1||t.keys.length>500)throw new Error("Keys batch size must be between 1 and 500 items");return e.handleOperation(async()=>await nn.post(e.fetch,`${e.url}/DeleteVectors`,t,{headers:e.headers})||{})}},eN=class extends Lo{constructor(t,e={},n){const r=t.replace(/\/$/,""),o=Se(Se({},gl),{},{"Content-Type":"application/json"},e);super(r,o,n,"vectors")}async createBucket(t){var e=this;return e.handleOperation(async()=>await nn.post(e.fetch,`${e.url}/CreateVectorBucket`,{vectorBucketName:t},{headers:e.headers})||{})}async getBucket(t){var e=this;return e.handleOperation(async()=>await nn.post(e.fetch,`${e.url}/GetVectorBucket`,{vectorBucketName:t},{headers:e.headers}))}async listBuckets(t={}){var e=this;return e.handleOperation(async()=>await nn.post(e.fetch,`${e.url}/ListVectorBuckets`,t,{headers:e.headers}))}async deleteBucket(t){var e=this;return e.handleOperation(async()=>await nn.post(e.fetch,`${e.url}/DeleteVectorBucket`,{vectorBucketName:t},{headers:e.headers})||{})}},tN=class extends eN{constructor(t,e={}){super(t,e.headers||{},e.fetch)}from(t){return new nN(this.url,this.headers,t,this.fetch)}async createBucket(t){var e=()=>super.createBucket,n=this;return e().call(n,t)}async getBucket(t){var e=()=>super.getBucket,n=this;return e().call(n,t)}async listBuckets(t={}){var e=()=>super.listBuckets,n=this;return e().call(n,t)}async deleteBucket(t){var e=()=>super.deleteBucket,n=this;return e().call(n,t)}},nN=class extends X2{constructor(t,e,n,r){super(t,e,r),this.vectorBucketName=n}async createIndex(t){var e=()=>super.createIndex,n=this;return e().call(n,Se(Se({},t),{},{vectorBucketName:n.vectorBucketName}))}async listIndexes(t={}){var e=()=>super.listIndexes,n=this;return e().call(n,Se(Se({},t),{},{vectorBucketName:n.vectorBucketName}))}async getIndex(t){var e=()=>super.getIndex,n=this;return e().call(n,n.vectorBucketName,t)}async deleteIndex(t){var e=()=>super.deleteIndex,n=this;return e().call(n,n.vectorBucketName,t)}index(t){return new rN(this.url,this.headers,this.vectorBucketName,t,this.fetch)}},rN=class extends Z2{constructor(t,e,n,r,o){super(t,e,o),this.vectorBucketName=n,this.indexName=r}async putVectors(t){var e=()=>super.putVectors,n=this;return e().call(n,Se(Se({},t),{},{vectorBucketName:n.vectorBucketName,indexName:n.indexName}))}async getVectors(t){var e=()=>super.getVectors,n=this;return e().call(n,Se(Se({},t),{},{vectorBucketName:n.vectorBucketName,indexName:n.indexName}))}async listVectors(t={}){var e=()=>super.listVectors,n=this;return e().call(n,Se(Se({},t),{},{vectorBucketName:n.vectorBucketName,indexName:n.indexName}))}async queryVectors(t){var e=()=>super.queryVectors,n=this;return e().call(n,Se(Se({},t),{},{vectorBucketName:n.vectorBucketName,indexName:n.indexName}))}async deleteVectors(t){var e=()=>super.deleteVectors,n=this;return e().call(n,Se(Se({},t),{},{vectorBucketName:n.vectorBucketName,indexName:n.indexName}))}},sN=class extends Y2{constructor(t,e={},n,r){super(t,e,n,r)}from(t){return new G2(this.url,this.headers,t,this.fetch)}get vectors(){return new tN(this.url+"/vector",{headers:this.headers,fetch:this.fetch})}get analytics(){return new J2(this.url+"/iceberg",this.headers,this.fetch)}};const dS="2.99.2",to=30*1e3,gp=3,af=gp*to,iN="http://localhost:9999",oN="supabase.auth.token",aN={"X-Client-Info":`gotrue-js/${dS}`},yp="X-Supabase-Api-Version",hS={"2024-01-01":{timestamp:Date.parse("2024-01-01T00:00:00.0Z"),name:"2024-01-01"}},lN=/^([a-z0-9_-]{4})*($|[a-z0-9_-]{3}$|[a-z0-9_-]{2}$)$/i,uN=600*1e3;
289class Ja extends Error{constructor(e,n,r){super(e),this.__isAuthError=!0,this.name="AuthError",this.status=n,this.code=r}}function ce(t){return typeof t=="object"&&t!==null&&"__isAuthError"in t}class cN extends Ja{constructor(e,n,r){super(e,n,r),this.name="AuthApiError",this.status=n,this.code=r}}function dN(t){return ce(t)&&t.name==="AuthApiError"}class Js extends Ja{constructor(e,n){super(e),this.name="AuthUnknownError",this.originalError=n}}class Or extends Ja{constructor(e,n,r,o){super(e,r,o),this.name=n,this.status=r}}class en extends Or{constructor(){super("Auth session missing!","AuthSessionMissingError",400,void 0)}}function lf(t){return ce(t)&&t.name==="AuthSessionMissingError"}class Qi extends Or{constructor(){super("Auth session or user missing","AuthInvalidTokenResponseError",500,void 0)}}class qu extends Or{constructor(e){super(e,"AuthInvalidCredentialsError",400,void 0)}}class Ku extends Or{constructor(e,n=null){super(e,"AuthImplicitGrantRedirectError",500,void 0),this.details=null,this.details=n}toJSON(){return{name:this.name,message:this.message,status:this.status,details:this.details}}}function hN(t){return ce(t)&&t.name==="AuthImplicitGrantRedirectError"}class J0 extends Or{constructor(e,n=null){super(e,"AuthPKCEGrantCodeExchangeError",500,void 0),this.details=null,this.details=n}toJSON(){return{name:this.name,message:this.message,status:this.status,details:this.details}}}class fN extends Or{constructor(){super("PKCE code verifier not found in storage. This can happen if the auth flow was initiated in a different browser or device, or if the storage was cleared. For SSR frameworks (Next.js, SvelteKit, etc.), use @supabase/ssr on both the server and client to store the code verifier in cookies.","AuthPKCECodeVerifierMissingError",400,"pkce_code_verifier_not_found")}}class vp extends Or{constructor(e,n){super(e,"AuthRetryableFetchError",n,void 0)}}function uf(t){return ce(t)&&t.name==="AuthRetryableFetchError"}class X0 extends Or{constructor(e,n,r){super(e,"AuthWeakPasswordError",n,"weak_password"),this.reasons=r}}class wp extends Or{constructor(e){super(e,"AuthInvalidJwtError",400,"invalid_jwt")}}const vc="ABCDEFGHIJKLMNOPQRSTUVWXYZabcdefghijklmnopqrstuvwxyz0123456789-_".split(""),Z0=` 	
290\r=`.split(""),pN=(()=>{const t=new Array(128);for(let e=0;e<t.length;e+=1)t[e]=-1;for(let e=0;e<Z0.length;e+=1)t[Z0[e].charCodeAt(0)]=-2;for(let e=0;e<vc.length;e+=1)t[vc[e].charCodeAt(0)]=e;return t})();function ew(t,e,n){if(t!==null)for(e.queue=e.queue<<8|t,e.queuedBits+=8;e.queuedBits>=6;){const r=e.queue>>e.queuedBits-6&63;n(vc[r]),e.queuedBits-=6}else if(e.queuedBits>0)for(e.queue=e.queue<<6-e.queuedBits,e.queuedBits=6;e.queuedBits>=6;){const r=e.queue>>e.queuedBits-6&63;n(vc[r]),e.queuedBits-=6}}function fS(t,e,n){const r=pN[t];if(r>-1)for(e.queue=e.queue<<6|r,e.queuedBits+=6;e.queuedBits>=8;)n(e.queue>>e.queuedBits-8&255),e.queuedBits-=8;else{if(r===-2)return;throw new Error(`Invalid Base64-URL character "${String.fromCharCode(t)}"`)}}function tw(t){const e=[],n=l=>{e.push(String.fromCodePoint(l))},r={utf8seq:0,codepoint:0},o={queue:0,queuedBits:0},a=l=>{yN(l,r,n)};for(let l=0;l<t.length;l+=1)fS(t.charCodeAt(l),o,a);return e.join("")}function mN(t,e){if(t<=127){e(t);return}else if(t<=2047){e(192|t>>6),e(128|t&63);return}else if(t<=65535){e(224|t>>12),e(128|t>>6&63),e(128|t&63);return}else if(t<=1114111){e(240|t>>18),e(128|t>>12&63),e(128|t>>6&63),e(128|t&63);return}throw new Error(`Unrecognized Unicode codepoint: ${t.toString(16)}`)}function gN(t,e){for(let n=0;n<t.length;n+=1){let r=t.charCodeAt(n);if(r>55295&&r<=56319){const o=(r-55296)*1024&65535;r=(t.charCodeAt(n+1)-56320&65535|o)+65536,n+=1}mN(r,e)}}function yN(t,e,n){if(e.utf8seq===0){if(t<=127){n(t);return}for(let r=1;r<6;r+=1)if((t>>7-r&1)===0){e.utf8seq=r;break}if(e.utf8seq===2)e.codepoint=t&31;else if(e.utf8seq===3)e.codepoint=t&15;else if(e.utf8seq===4)e.codepoint=t&7;else throw new Error("Invalid UTF-8 sequence");e.utf8seq-=1}else if(e.utf8seq>0){if(t<=127)throw new Error("Invalid UTF-8 sequence");e.codepoint=e.codepoint<<6|t&63,e.utf8seq-=1,e.utf8seq===0&&n(e.codepoint)}}function fo(t){const e=[],n={queue:0,queuedBits:0},r=o=>{e.push(o)};for(let o=0;o<t.length;o+=1)fS(t.charCodeAt(o),n,r);return new Uint8Array(e)}function vN(t){const e=[];return gN(t,n=>e.push(n)),new Uint8Array(e)}function Zs(t){const e=[],n={queue:0,queuedBits:0},r=o=>{e.push(o)};return t.forEach(o=>ew(o,n,r)),ew(null,n,r),e.join("")}function wN(t){return Math.round(Date.now()/1e3)+t}function xN(){return Symbol("auth-callback")}const xt=()=>typeof window<"u"&&typeof document<"u",Hs={tested:!1,writable:!1},pS=()=>
290{if(!xt())return!1;try{if(typeof globalThis.localStorage!="object")return!1}catch{return!1}if(Hs.tested)return Hs.writable;const t=`lswt-${Math.random()}${Math.random()}`;try{globalThis.localStorage.setItem(t,t),globalThis.localStorage.removeItem(t),Hs.tested=!0,Hs.writable=!0}catch{Hs.tested=!0,Hs.writable=!1}return Hs.writable};function bN(t){const e={},n=new URL(t);if(n.hash&&n.hash[0]==="#")try{new URLSearchParams(n.hash.substring(1)).forEach((o,a)=>{e[a]=o})}catch{}return n.searchParams.forEach((r,o)=>{e[o]=r}),e}const mS=t=>t?(...e)=>t(...e):(...e)=>fetch(...e),SN=t=>typeof t=="object"&&t!==null&&"status"in t&&"ok"in t&&"json"in t&&typeof t.json=="function",no=async(t,e,n)=>{await t.setItem(e,JSON.stringify(n))},qs=async(t,e)=>{const n=await t.getItem(e);if(!n)return null;try{return JSON.parse(n)}catch{return n}},wt=async(t,e)=>{await t.removeItem(e)};class Yc{constructor(){this.promise=new Yc.promiseConstructor((e,n)=>{this.resolve=e,this.reject=n})}}Yc.promiseConstructor=Promise;function Gu(t){const e=t.split(".");if(e.length!==3)throw new wp("Invalid JWT structure");for(let r=0;r<e.length;r++)if(!lN.test(e[r]))throw new wp("JWT not in base64url format");return{header:JSON.parse(tw(e[0])),payload:JSON.parse(tw(e[1])),signature:fo(e[2]),raw:{header:e[0],payload:e[1]}}}async function _N(t){return await new Promise(e=>{setTimeout(()=>e(null),t)})}function EN(t,e){return new Promise((r,o)=>{(async()=>{for(let a=0;a<1/0;a++)try{const l=await t(a);if(!e(a,null,l)){r(l);return}}catch(l){if(!e(a,l)){o(l);return}}})()})}function TN(t){return("0"+t.toString(16)).substr(-2)}function kN(){const e=new Uint32Array(56);if(typeof crypto>"u"){const n="ABCDEFGHIJKLMNOPQRSTUVWXYZabcdefghijklmnopqrstuvwxyz0123456789-._~",r=n.length;let o="";for(let a=0;a<56;a++)o+=n.charAt(Math.floor(Math.random()*r));return o}return crypto.getRandomValues(e),Array.from(e,TN).join("")}async function CN(t){const n=new TextEncoder().encode(t),r=await crypto.subtle.digest("SHA-256",n),o=new Uint8Array(r);return Array.from(o).map(a=>String.fromCharCode(a)).join("")}async function PN(t){if(!(typeof crypto<"u"&&typeof crypto.subtle<"u"&&typeof TextEncoder<"u"))return console.warn("WebCrypto API is not supported. Code challenge method will default to use plain instead of sha256."),t;const n=await CN(t);return btoa(n).replace(/\+/g,"-").replace(/\//g,"_").replace(/=+$/,"")}async function Yi(t,e,n=!1){const r=kN();let o=r;n&&(o+="/PASSWORD_RECOVERY"),await no(t,`${e}-code-verifier`,o);const a=await PN(r);return[a,r===a?"plain":"s256"]}const AN=/^2[0-9]{3}-(0[1-9]|1[0-2])-(0[1-9]|1[0-9]|2[0-9]|3[0-1])$/i;function RN(t){const e=t.headers.get(yp);if(!e||!e.match(AN))return null;try{return new Date(`${e}T00:00:00.0Z`)}catch{return null}}function jN(t){if(!t)throw new Error("Missing exp claim");const e=Math.floor(Date.now()/1e3);if(t<=e)throw new Error("JWT has expired")}function ON(t){switch(t){case"RS256":return{name:"RSASSA-PKCS1-v1_5",hash:{name:"SHA-256"}};case"ES256":return{name:"ECDSA",namedCurve:"P-256",hash:{name:"SHA-256"}};default:throw new Error("Invalid alg claim")}}const NN=/^[0-9a-f]{8}-[0-9a-f]{4}-[0-9a-f]{4}-[0-9a-f]{4}-[0-9a-f]{12}$/;function Ji(t){if(!NN.test(t))throw new Error("@supabase/auth-js: Expected parameter to be UUID but is not")}function cf(){const t={};return new Proxy(t,{get:(e,n)=>{if(n==="__isUserNotAvailableProxy")return!0;if(typeof n=="symbol"){const r=n.toString();if(r==="Symbol(Symbol.toPrimitive)"||r==="Symbol(Symbol.toStringTag)"||r==="Symbol(util.inspect.custom)")return}throw new Error(`@supabase/auth-js: client was created with userStorage option and there was no user stored in the user storage. Accessing the "${n}" property of the session object is not supported. Please use getUser() instead.`)},set:(e,n)=>{throw new Error(`@supabase/auth-js: client was created with userStorage option and there was no user stored in the user storage. Setting the "${n}" property of the session object is not supported. Please use getUser() to fetch a user object you can manipulate.`)},deleteProperty:(e,n)=>{throw new Error(`@supabase/auth-js: client was created with userStorage option and there was no user stored in the user storage. Deleting the "${n}" property of the session object is not supported. Please use getUser() to fetch a user object you can manipulate.`)}})}function IN(t,e){return new Proxy(t,{get:(n,r,o)=>{if(r==="__isInsecureUserWarningProxy")return!0;
290if(typeof r=="symbol"){const a=r.toString();if(a==="Symbol(Symbol.toPrimitive)"||a==="Symbol(Symbol.toStringTag)"||a==="Symbol(util.inspect.custom)"||a==="Symbol(nodejs.util.inspect.custom)")return Reflect.get(n,r,o)}return!e.value&&typeof r=="string"&&(console.warn("Using the user object as returned from supabase.auth.getSession() or from some supabase.auth.onAuthStateChange() events could be insecure! This value comes directly from the storage medium (usually cookies on the server) and may not be authentic. Use supabase.auth.getUser() instead which authenticates the data by contacting the Supabase Auth server."),e.value=!0),Reflect.get(n,r,o)}})}function nw(t){return JSON.parse(JSON.stringify(t))}const Gs=t=>t.msg||t.message||t.error_description||t.error||JSON.stringify(t),LN=[502,503,504];async function rw(t){var e;if(!SN(t))throw new vp(Gs(t),0);if(LN.includes(t.status))throw new vp(Gs(t),t.status);let n;try{n=await t.json()}catch(a){throw new Js(Gs(a),a)}let r;const o=RN(t);if(o&&o.getTime()>=hS["2024-01-01"].timestamp&&typeof n=="object"&&n&&typeof n.code=="string"?r=n.code:typeof n=="object"&&n&&typeof n.error_code=="string"&&(r=n.error_code),r){if(r==="weak_password")throw new X0(Gs(n),t.status,((e=n.weak_password)===null||e===void 0?void 0:e.reasons)||[]);if(r==="session_not_found")throw new en}else if(typeof n=="object"&&n&&typeof n.weak_password=="object"&&n.weak_password&&Array.isArray(n.weak_password.reasons)&&n.weak_password.reasons.length&&n.weak_password.reasons.reduce((a,l)=>a&&typeof l=="string",!0))throw new X0(Gs(n),t.status,n.weak_password.reasons);throw new cN(Gs(n),t.status||500,r)}const DN=(t,e,n,r)=>{const o={method:t,headers:(e==null?void 0:e.headers)||{}};return t==="GET"?o:(o.headers=Object.assign({"Content-Type":"application/json;charset=UTF-8"},e==null?void 0:e.headers),o.body=JSON.stringify(r),Object.assign(Object.assign({},o),n))};async function ge(t,e,n,r){var o;const a=Object.assign({},r==null?void 0:r.headers);a[yp]||(a[yp]=hS["2024-01-01"].name),r!=null&&r.jwt&&(a.Authorization=`Bearer ${r.jwt}`);const l=(o=r==null?void 0:r.query)!==null&&o!==void 0?o:{};r!=null&&r.redirectTo&&(l.redirect_to=r.redirectTo);const c=Object.keys(l).length?"?"+new URLSearchParams(l).toString():"",d=await MN(t,e,n+c,{headers:a,noResolveJson:r==null?void 0:r.noResolveJson},{},r==null?void 0:r.body);return r!=null&&r.xform?r==null?void 0:r.xform(d):{data:Object.assign({},d),error:null}}async function MN(t,e,n,r,o,a){const l=DN(e,r,o,a);let c;try{c=await t(n,Object.assign({},l))}catch(d){throw console.error(d),new vp(Gs(d),0)}if(c.ok||await rw(c),r!=null&&r.noResolveJson)return c;try{return await c.json()}catch(d){await rw(d)}}function Rn(t){var e;let n=null;UN(t)&&(n=Object.assign({},t),t.expires_at||(n.expires_at=wN(t.expires_in)));const r=(e=t.user)!==null&&e!==void 0?e:t;return{data:{session:n,user:r},error:null}}function sw(t){const e=Rn(t);return!e.error&&t.weak_password&&typeof t.weak_password=="object"&&Array.isArray(t.weak_password.reasons)&&t.weak_password.reasons.length&&t.weak_password.message&&typeof t.weak_password.message=="string"&&t.weak_password.reasons.reduce((n,r)=>n&&typeof r=="string",!0)&&(e.data.weak_password=t.weak_password),e}function ls(t){var e;return{data:{user:(e=t.user)!==null&&e!==void 0?e:t},error:null}}function $N(t){return{data:t,error:null}}function FN(t){const{action_link:e,email_otp:n,hashed_token:r,redirect_to:o,verification_type:a}=t,l=Kc(t,["action_link","email_otp","hashed_token","redirect_to","verification_type"]),c={action_link:e,email_otp:n,hashed_token:r,redirect_to:o,verification_type:a},d=Object.assign({},l);return{data:{properties:c,user:d},error:null}}function iw(t){return t}function UN(t){return t.access_token&&t.refresh_token&&t.expires_in}const df=["global","local","others"];class VN{constructor({url:e="",headers:n={},fetch:r}){this.url=e,this.headers=n,this.fetch=mS(r),this.mfa={listFactors:this._listFactors.bind(this),deleteFactor:this._deleteFactor.bind(this)},this.oauth={listClients:this._listOAuthClients.bind(this),createClient:this._createOAuthClient.bind(this),getClient:this._getOAuthClient.bind(this),updateClient:this._updateOAuthClient.bind(this),deleteClient:this._deleteOAuthClient.bind(this),regenerateClientSecret:this._regenerateOAuthClientSecret.bind(this)},this.customProviders={listProviders:this._listCustomProviders.bind(this),createProvider:this._createCustomProvider.bind(this),getProvider:this._getCustomProvider.bind(this),updateProvider:this._updateCustomProvider.bind(this),deleteProvider:this._deleteCustomProvider.bind(this)}}async signOut(e,n=df[0]){if(df.indexOf(n)<0)throw new Error(`@supabase/auth-js: Parameter scope must be one of ${df.join(", ")}`);try{return await ge(this.fetch,"POST",`${this.url}/logout?scope=${n}`,{headers:this.headers,jwt:e,noResolveJson:!0}),{data:null,error:null}}catch(r){if(ce(r))return{data:null,error:r};throw r}}async inviteUserByEmail(e,n={}){try{return await ge(this.fetch,"POST",`${this.url}/invite`,{body:{email:e,data:n.data},headers:this.headers,redirectTo:n.redirectTo,xform:ls})}catch(r){if(ce(r))return{data:{user:null},error:r};throw r}}async generateLink(e){try{const{options:n}=e,r=Kc(e,["options"]),o=Object.assign(Object.assign({},r),n);return"newEmail"in r&&(o.new_email=r==null?void 0:r.newEmail,delete o.newEmail),await ge(this.fetch,"POST",`${this.url}/admin/generate_link`,{body:o,headers:this.headers,xform:FN,redirectTo:n==null?void 0:n.redirectTo})}catch(n){if(ce(n))return{data:{properties:null,user:null},error:n};throw n}}async createUser(e){try{return await ge(this.fetch,"POST",`${this.url}/admin/users`,{body:e,headers:this.headers,xform:ls})}catch(n){if(ce(n))return{data:{user:null},error:n};throw n}}async listUsers(e){var n,r,o,a,l,c,d;try{const f={nextPage:null,lastPage:0,total:0},p=await ge(this.fetch,"GET",`${this.url}/admin/users`,{headers:this.headers,noResolveJson:!0,query:{page:(r=(n=e==null?void 0:e.page)===null||n===void 0?void 0:n.toString())!==null&&r!==void 0?r:"",per_page:(a=(o=e==null?void 0:e.perPage)===null||o===void 0?void 0:o.toString())!==null&&a!==void 0?a:""},xform:iw});if(p.error)throw p.error;const g=await p.json(),x=(l=p.headers.get("x-total-count"))!==null&&l!==void 0?l:0,y=(d=(c=p.headers.get("link"))===null||c===void 0?void 0:c.split(","))!==null&&d!==void 0?d:[];return y.length>0&&(y.forEach(_=>{const S=parseInt(_.split(";")[0].split("=")[1].substring(0,1)),b=JSON.parse(_.split(";")[1].split("=")[1]);f[`${b}Page`]=S}),f.total=parseInt(x)),{data:Object.assign(Object.assign({},g),f),error:null}}catch(f){if(ce(f))return{data:{users:[]},error:f};throw f}}async getUserById(e){Ji(e);try{return await ge(this.fetch,"GET",`${this.url}/admin/users/${e}`,{headers:this.headers,xform:ls})}catch(n){if(ce(n))return{data:{user:null},error:n};throw n}}async updateUserById(e,n){Ji(e);try{return await ge(this.fetch,"PUT",`${this.url}/admin/users/${e}`,{body:n,headers:this.headers,xform:ls})}catch(r){if(ce(r))return{data:{user:null},error:r};throw r}}async deleteUser(e,n=!1){Ji(e);
290try{return await ge(this.fetch,"DELETE",`${this.url}/admin/users/${e}`,{headers:this.headers,body:{should_soft_delete:n},xform:ls})}catch(r){if(ce(r))return{data:{user:null},error:r};throw r}}async _listFactors(e){Ji(e.userId);try{const{data:n,error:r}=await ge(this.fetch,"GET",`${this.url}/admin/users/${e.userId}/factors`,{headers:this.headers,xform:o=>({data:{factors:o},error:null})});return{data:n,error:r}}catch(n){if(ce(n))return{data:null,error:n};throw n}}async _deleteFactor(e){Ji(e.userId),Ji(e.id);try{return{data:await ge(this.fetch,"DELETE",`${this.url}/admin/users/${e.userId}/factors/${e.id}`,{headers:this.headers}),error:null}}catch(n){if(ce(n))return{data:null,error:n};throw n}}async _listOAuthClients(e){var n,r,o,a,l,c,d;try{const f={nextPage:null,lastPage:0,total:0},p=await ge(this.fetch,"GET",`${this.url}/admin/oauth/clients`,{headers:this.headers,noResolveJson:!0,query:{page:(r=(n=e==null?void 0:e.page)===null||n===void 0?void 0:n.toString())!==null&&r!==void 0?r:"",per_page:(a=(o=e==null?void 0:e.perPage)===null||o===void 0?void 0:o.toString())!==null&&a!==void 0?a:""},xform:iw});if(p.error)throw p.error;const g=await p.json(),x=(l=p.headers.get("x-total-count"))!==null&&l!==void 0?l:0,y=(d=(c=p.headers.get("link"))===null||c===void 0?void 0:c.split(","))!==null&&d!==void 0?d:[];return y.length>0&&(y.forEach(_=>{const S=parseInt(_.split(";")[0].split("=")[1].substring(0,1)),b=JSON.parse(_.split(";")[1].split("=")[1]);f[`${b}Page`]=S}),f.total=parseInt(x)),{data:Object.assign(Object.assign({},g),f),error:null}}catch(f){if(ce(f))return{data:{clients:[]},error:f};throw f}}async _createOAuthClient(e){try{return await ge(this.fetch,"POST",`${this.url}/admin/oauth/clients`,{body:e,headers:this.headers,xform:n=>({data:n,error:null})})}catch(n){if(ce(n))return{data:null,error:n};throw n}}async _getOAuthClient(e){try{return await ge(this.fetch,"GET",`${this.url}/admin/oauth/clients/${e}`,{headers:this.headers,xform:n=>({data:n,error:null})})}catch(n){if(ce(n))return{data:null,error:n};throw n}}async _updateOAuthClient(e,n){try{return await ge(this.fetch,"PUT",`${this.url}/admin/oauth/clients/${e}`,{body:n,headers:this.headers,xform:r=>({data:r,error:null})})}catch(r){if(ce(r))return{data:null,error:r};throw r}}async _deleteOAuthClient(e){try{return await ge(this.fetch,"DELETE",`${this.url}/admin/oauth/clients/${e}`,{headers:this.headers,noResolveJson:!0}),{data:null,error:null}}catch(n){if(ce(n))return{data:null,error:n};throw n}}async _regenerateOAuthClientSecret(e){try{return await ge(this.fetch,"POST",`${this.url}/admin/oauth/clients/${e}/regenerate_secret`,{headers:this.headers,xform:n=>({data:n,error:null})})}catch(n){if(ce(n))return{data:null,error:n};throw n}}async _listCustomProviders(e){try{const n={};return e!=null&&e.type&&(n.type=e.type),await ge(this.fetch,"GET",`${this.url}/admin/custom-providers`,{headers:this.headers,query:n,xform:r=>{var o;return{data:{providers:(o=r==null?void 0:r.providers)!==null&&o!==void 0?o:[]},error:null}}})}catch(n){if(ce(n))return{data:{providers:[]},error:n};throw n}}async _createCustomProvider(e){try{return await ge(this.fetch,"POST",`${this.url}/admin/custom-providers`,{body:e,headers:this.headers,xform:n=>({data:n,error:null})})}catch(n){if(ce(n))return{data:null,error:n};throw n}}async _getCustomProvider(e){try{return await ge(this.fetch,"GET",`${this.url}/admin/custom-providers/${e}`,{headers:this.headers,xform:n=>({data:n,error:null})})}catch(n){if(ce(n))return{data:null,error:n};throw n}}async _updateCustomProvider(e,n){try{return await ge(this.fetch,"PUT",`${this.url}/admin/custom-providers/${e}`,{body:n,headers:this.headers,xform:r=>({data:r,error:null})})}catch(r){if(ce(r))return{data:null,error:r};throw r}}async _deleteCustomProvider(e){try{return await ge(this.fetch,"DELETE",`${this.url}/admin/custom-providers/${e}`,{headers:this.headers,noResolveJson:!0}),{data:null,error:null}}catch(n){if(ce(n))return{data:null,error:n};throw n}}}function ow(t={}){return{getItem:e=>t[e]||null,setItem:(e,n)=>{t[e]=n},removeItem:e=>{delete t[e]}}}const _r={debug:!!(globalThis&&pS()&&globalThis.localStorage&&globalThis.localStorage.getItem("supabase.gotrue-js.locks.debug")==="true")};
290class gS extends Error{constructor(e){super(e),this.isAcquireTimeout=!0}}class BN extends gS{}async function zN(t,e,n){_r.debug&&console.log("@supabase/gotrue-js: navigatorLock: acquire lock",t,e);const r=new globalThis.AbortController;e>0&&setTimeout(()=>{r.abort(),_r.debug&&console.log("@supabase/gotrue-js: navigatorLock acquire timed out",t)},e),await Promise.resolve();try{return await globalThis.navigator.locks.request(t,e===0?{mode:"exclusive",ifAvailable:!0}:{mode:"exclusive",signal:r.signal},async o=>{if(o){_r.debug&&console.log("@supabase/gotrue-js: navigatorLock: acquired",t,o.name);try{return await n()}finally{_r.debug&&console.log("@supabase/gotrue-js: navigatorLock: released",t,o.name)}}else{if(e===0)throw _r.debug&&console.log("@supabase/gotrue-js: navigatorLock: not immediately available",t),new BN(`Acquiring an exclusive Navigator LockManager lock "${t}" immediately failed`);if(_r.debug)try{const a=await globalThis.navigator.locks.query();console.log("@supabase/gotrue-js: Navigator LockManager state",JSON.stringify(a,null,"  "))}catch(a){console.warn("@supabase/gotrue-js: Error when querying Navigator LockManager state",a)}return console.warn("@supabase/gotrue-js: Navigator LockManager returned a null lock when using #request without ifAvailable set to true, it appears this browser is not following the LockManager spec https://developer.mozilla.org/en-US/docs/Web/API/LockManager/request"),await n()}})}catch(o){if((o==null?void 0:o.name)==="AbortError"&&e>0)return _r.debug&&console.log("@supabase/gotrue-js: navigatorLock: acquire timeout, recovering by stealing lock",t),console.warn(`@supabase/gotrue-js: Lock "${t}" was not released within ${e}ms. This may indicate an orphaned lock from a component unmount (e.g., React Strict Mode). Forcefully acquiring the lock to recover.`),await Promise.resolve().then(()=>globalThis.navigator.locks.request(t,{mode:"exclusive",steal:!0},async a=>{if(a){_r.debug&&console.log("@supabase/gotrue-js: navigatorLock: recovered (stolen)",t,a.name);try{return await n()}finally{_r.debug&&console.log("@supabase/gotrue-js: navigatorLock: released (stolen)",t,a.name)}}else return console.warn("@supabase/gotrue-js: Navigator LockManager returned null lock even with steal: true"),await n()}));throw o}}function WN(){if(typeof globalThis!="object")try{Object.defineProperty(Object.prototype,"__magic__",{get:function(){return this},configurable:!0}),__magic__.globalThis=__magic__,delete Object.prototype.__magic__}catch{typeof self<"u"&&(self.globalThis=self)}}function yS(t){if(!/^0x[a-fA-F0-9]{40}$/.test(t))throw new Error(`@supabase/auth-js: Address "${t}" is invalid.`);return t.toLowerCase()}function HN(t){return parseInt(t,16)}function qN(t){const e=new TextEncoder().encode(t);return"0x"+Array.from(e,r=>r.toString(16).padStart(2,"0")).join("")}function KN(t){var e;const{chainId:n,domain:r,expirationTime:o,issuedAt:a=new Date,nonce:l,notBefore:c,requestId:d,resources:f,scheme:p,uri:g,version:x}=t;{if(!Number.isInteger(n))throw new Error(`@supabase/auth-js: Invalid SIWE message field "chainId". Chain ID must be a EIP-155 chain ID. Provided value: ${n}`);if(!r)throw new Error('@supabase/auth-js: Invalid SIWE message field "domain". Domain must be provided.');if(l&&l.length<8)throw new Error(`@supabase/auth-js: Invalid SIWE message field "nonce". Nonce must be at least 8 characters. Provided value: ${l}`);if(!g)throw new Error('@supabase/auth-js: Invalid SIWE message field "uri". URI must be provided.');if(x!=="1")throw new Error(`@supabase/auth-js: Invalid SIWE message field "version". Version must be '1'. Provided value: ${x}`);if(!((e=t.statement)===null||e===void 0)&&e.includes(`
291`))throw new Error(`@supabase/auth-js: Invalid SIWE message field "statement". Statement must not include '\\n'. Provided value: ${t.statement}`)}const y=yS(t.address),_=p?`${p}://${r}`:r,S=t.statement?`${t.statement}
292`:"",b=`${_} wants you to sign in with your Ethereum account:
293${y}
294
295${S}`;let k=`URI: ${g}
296Version: ${x}
297Chain ID: ${n}${l?`
298Nonce: ${l}`:""}
299Issued At: ${a.toISOString()}`;if(o&&(k+=`
300Expiration Time: ${o.toISOString()}
300`),c&&(k+=`
301Not Before: ${c.toISOString()}`),d&&(k+=`
302Request ID: ${d}`),f){let P=`
303Resources:`;for(const C of f){if(!C||typeof C!="string")throw new Error(`@supabase/auth-js: Invalid SIWE message field "resources". Every resource must be a valid string. Provided value: ${C}`);P+=`
304- ${C}`}k+=P}return`${b}
305${k}`}class st extends Error{constructor({message:e,code:n,cause:r,name:o}){var a;super(e,{cause:r}),this.__isWebAuthnError=!0,this.name=(a=o??(r instanceof Error?r.name:void 0))!==null&&a!==void 0?a:"Unknown Error",this.code=n}}class wc extends st{constructor(e,n){super({code:"ERROR_PASSTHROUGH_SEE_CAUSE_PROPERTY",cause:n,message:e}),this.name="WebAuthnUnknownError",this.originalError=n}}function GN({error:t,options:e}){var n,r,o;const{publicKey:a}=e;if(!a)throw Error("options was missing required publicKey property");if(t.name==="AbortError"){if(e.signal instanceof AbortSignal)return new st({message:"Registration ceremony was sent an abort signal",code:"ERROR_CEREMONY_ABORTED",cause:t})}else if(t.name==="ConstraintError"){if(((n=a.authenticatorSelection)===null||n===void 0?void 0:n.requireResidentKey)===!0)return new st({message:"Discoverable credentials were required but no available authenticator supported it",code:"ERROR_AUTHENTICATOR_MISSING_DISCOVERABLE_CREDENTIAL_SUPPORT",cause:t});if(e.mediation==="conditional"&&((r=a.authenticatorSelection)===null||r===void 0?void 0:r.userVerification)==="required")return new st({message:"User verification was required during automatic registration but it could not be performed",code:"ERROR_AUTO_REGISTER_USER_VERIFICATION_FAILURE",cause:t});if(((o=a.authenticatorSelection)===null||o===void 0?void 0:o.userVerification)==="required")return new st({message:"User verification was required but no available authenticator supported it",code:"ERROR_AUTHENTICATOR_MISSING_USER_VERIFICATION_SUPPORT",cause:t})}else{if(t.name==="InvalidStateError")return new st({message:"The authenticator was previously registered",code:"ERROR_AUTHENTICATOR_PREVIOUSLY_REGISTERED",cause:t});if(t.name==="NotAllowedError")return new st({message:t.message,code:"ERROR_PASSTHROUGH_SEE_CAUSE_PROPERTY",cause:t});if(t.name==="NotSupportedError")return a.pubKeyCredParams.filter(c=>c.type==="public-key").length===0?new st({message:'No entry in pubKeyCredParams was of type "public-key"',code:"ERROR_MALFORMED_PUBKEYCREDPARAMS",cause:t}):new st({message:"No available authenticator supported any of the specified pubKeyCredParams algorithms",code:"ERROR_AUTHENTICATOR_NO_SUPPORTED_PUBKEYCREDPARAMS_ALG",cause:t});if(t.name==="SecurityError"){const l=window.location.hostname;if(vS(l)){if(a.rp.id!==l)return new st({message:`The RP ID "${a.rp.id}" is invalid for this domain`,code:"ERROR_INVALID_RP_ID",cause:t})}else return new st({message:`${window.location.hostname} is an invalid domain`,code:"ERROR_INVALID_DOMAIN",cause:t})}else if(t.name==="TypeError"){if(a.user.id.byteLength<1||a.user.id.byteLength>64)return new st({message:"User ID was not between 1 and 64 characters",code:"ERROR_INVALID_USER_ID_LENGTH",cause:t})}else if(t.name==="UnknownError")return new st({message:"The authenticator was unable to process the specified options, or could not create a new credential",code:"ERROR_AUTHENTICATOR_GENERAL_ERROR",cause:t})}return new st({message:"a Non-Webauthn related error has occurred",code:"ERROR_PASSTHROUGH_SEE_CAUSE_PROPERTY",cause:t})}function QN({error:t,options:e}){const{publicKey:n}=e;if(!n)throw Error("options was missing required publicKey property");if(t.name==="AbortError"){if(e.signal instanceof AbortSignal)return new st({message:"Authentication ceremony was sent an abort signal",code:"ERROR_CEREMONY_ABORTED",cause:t})}else{if(t.name==="NotAllowedError")return new st({message:t.message,code:"ERROR_PASSTHROUGH_SEE_CAUSE_PROPERTY",cause:t});if(t.name==="SecurityError"){const r=window.location.hostname;if(vS(r)){if(n.rpId!==r)return new st({message:`The RP ID "${n.rpId}" is invalid for this domain`,code:"ERROR_INVALID_RP_ID",cause:t})}else return new st({message:`${window.location.hostname} is an invalid domain`,code:"ERROR_INVALID_DOMAIN",cause:t})}else if(t.name==="UnknownError")return new st({message:"The authenticator was unable to process the specified options, or could not create a new assertion signature",code:"ERROR_AUTHENTICATOR_GENERAL_ER
305ROR",cause:t})}return new st({message:"a Non-Webauthn related error has occurred",code:"ERROR_PASSTHROUGH_SEE_CAUSE_PROPERTY",cause:t})}class YN{createNewAbortSignal(){if(this.controller){const n=new Error("Cancelling existing WebAuthn API call for new one");n.name="AbortError",this.controller.abort(n)}const e=new AbortController;return this.controller=e,e.signal}cancelCeremony(){if(this.controller){const e=new Error("Manually cancelling existing WebAuthn API call");e.name="AbortError",this.controller.abort(e),this.controller=void 0}}}const JN=new YN;function XN(t){if(!t)throw new Error("Credential creation options are required");if(typeof PublicKeyCredential<"u"&&"parseCreationOptionsFromJSON"in PublicKeyCredential&&typeof PublicKeyCredential.parseCreationOptionsFromJSON=="function")return PublicKeyCredential.parseCreationOptionsFromJSON(t);const{challenge:e,user:n,excludeCredentials:r}=t,o=Kc(t,["challenge","user","excludeCredentials"]),a=fo(e).buffer,l=Object.assign(Object.assign({},n),{id:fo(n.id).buffer}),c=Object.assign(Object.assign({},o),{challenge:a,user:l});if(r&&r.length>0){c.excludeCredentials=new Array(r.length);for(let d=0;d<r.length;d++){const f=r[d];c.excludeCredentials[d]=Object.assign(Object.assign({},f),{id:fo(f.id).buffer,type:f.type||"public-key",transports:f.transports})}}return c}function ZN(t){if(!t)throw new Error("Credential request options are required");if(typeof PublicKeyCredential<"u"&&"parseRequestOptionsFromJSON"in PublicKeyCredential&&typeof PublicKeyCredential.parseRequestOptionsFromJSON=="function")return PublicKeyCredential.parseRequestOptionsFromJSON(t);const{challenge:e,allowCredentials:n}=t,r=Kc(t,["challenge","allowCredentials"]),o=fo(e).buffer,a=Object.assign(Object.assign({},r),{challenge:o});if(n&&n.length>0){a.allowCredentials=new Array(n.length);for(let l=0;l<n.length;l++){const c=n[l];a.allowCredentials[l]=Object.assign(Object.assign({},c),{id:fo(c.id).buffer,type:c.type||"public-key",transports:c.transports})}}return a}function eI(t){var e;if("toJSON"in t&&typeof t.toJSON=="function")return t.toJSON();const n=t;return{id:t.id,rawId:t.id,response:{attestationObject:Zs(new Uint8Array(t.response.attestationObject)),clientDataJSON:Zs(new Uint8Array(t.response.clientDataJSON))},type:"public-key",clientExtensionResults:t.getClientExtensionResults(),authenticatorAttachment:(e=n.authenticatorAttachment)!==null&&e!==void 0?e:void 0}}function tI(t){var e;if("toJSON"in t&&typeof t.toJSON=="function")return t.toJSON();const n=t,r=t.getClientExtensionResults(),o=t.response;return{id:t.id,rawId:t.id,response:{authenticatorData:Zs(new Uint8Array(o.authenticatorData)),clientDataJSON:Zs(new Uint8Array(o.clientDataJSON)),signature:Zs(new Uint8Array(o.signature)),userHandle:o.userHandle?Zs(new Uint8Array(o.userHandle)):void 0},type:"public-key",clientExtensionResults:r,authenticatorAttachment:(e=n.authenticatorAttachment)!==null&&e!==void 0?e:void 0}}function vS(t){return t==="localhost"||/^([a-z0-9]+(-[a-z0-9]+)*\.)+[a-z]{2,}$/i.test(t)}function aw(){var t,e;return!!(xt()&&"PublicKeyCredential"in window&&window.PublicKeyCredential&&"credentials"in navigator&&typeof((t=navigator==null?void 0:navigator.credentials)===null||t===void 0?void 0:t.create)=="function"&&typeof((e=navigator==null?void 0:navigator.credentials)===null||e===void 0?void 0:e.get)=="function")}async function nI(t){try{const e=await navigator.credentials.create(t);return e?e instanceof PublicKeyCredential?{data:e,error:null}:{data:null,error:new wc("Browser returned unexpected credential type",e)}:{data:null,error:new wc("Empty credential response",e)}}catch(e){return{data:null,error:GN({error:e,options:t})}}}async function rI(t){try{const e=await navigator.credentials.get(t);return e?e instanceof PublicKeyCredential?{data:e,error:null}:{data:null,error:new wc("Browser returned unexpected credential type",e)}:{data:null,error:new wc("Empty credential response",e)}}catch(e){return{data:null,error:QN({error:e,options:t})}}}const sI={hints:["security-key"],authenticatorSelection:{authenticatorAttachment:"cross-platform",requireResidentKey:!1,userVerification:"preferred",residentKey:"discouraged"},attestation:"direct"},iI={userVerification:"preferred",hints:["security-key"],attestation:"direct"};function xc(...t){const e=o=>o!==null&&typeof o=="object"&&!Array.isArray(o),n=o=>o instanceof ArrayBuffer||ArrayBuffer.isView(o),r={};
305for(const o of t)if(o)for(const a in o){const l=o[a];if(l!==void 0)if(Array.isArray(l))r[a]=l;else if(n(l))r[a]=l;else if(e(l)){const c=r[a];e(c)?r[a]=xc(c,l):r[a]=xc(l)}else r[a]=l}return r}function oI(t,e){return xc(sI,t,e||{})}function aI(t,e){return xc(iI,t,e||{})}class lI{constructor(e){this.client=e,this.enroll=this._enroll.bind(this),this.challenge=this._challenge.bind(this),this.verify=this._verify.bind(this),this.authenticate=this._authenticate.bind(this),this.register=this._register.bind(this)}async _enroll(e){return this.client.mfa.enroll(Object.assign(Object.assign({},e),{factorType:"webauthn"}))}async _challenge({factorId:e,webauthn:n,friendlyName:r,signal:o},a){var l;try{const{data:c,error:d}=await this.client.mfa.challenge({factorId:e,webauthn:n});if(!c)return{data:null,error:d};const f=o??JN.createNewAbortSignal();if(c.webauthn.type==="create"){const{user:p}=c.webauthn.credential_options.publicKey;if(!p.name){const g=r;if(g)p.name=`${p.id}:${g}`;else{const y=(await this.client.getUser()).data.user,_=((l=y==null?void 0:y.user_metadata)===null||l===void 0?void 0:l.name)||(y==null?void 0:y.email)||(y==null?void 0:y.id)||"User";p.name=`${p.id}:${_}`}}p.displayName||(p.displayName=p.name)}switch(c.webauthn.type){case"create":{const p=oI(c.webauthn.credential_options.publicKey,a==null?void 0:a.create),{data:g,error:x}=await nI({publicKey:p,signal:f});return g?{data:{factorId:e,challengeId:c.id,webauthn:{type:c.webauthn.type,credential_response:g}},error:null}:{data:null,error:x}}case"request":{const p=aI(c.webauthn.credential_options.publicKey,a==null?void 0:a.request),{data:g,error:x}=await rI(Object.assign(Object.assign({},c.webauthn.credential_options),{publicKey:p,signal:f}));return g?{data:{factorId:e,challengeId:c.id,webauthn:{type:c.webauthn.type,credential_response:g}},error:null}:{data:null,error:x}}}}catch(c){return ce(c)?{data:null,error:c}:{data:null,error:new Js("Unexpected error in challenge",c)}}}async _verify({challengeId:e,factorId:n,webauthn:r}){return this.client.mfa.verify({factorId:n,challengeId:e,webauthn:r})}async _authenticate({factorId:e,webauthn:{rpId:n=typeof window<"u"?window.location.hostname:void 0,rpOrigins:r=typeof window<"u"?[window.location.origin]:void 0,signal:o}={}},a){if(!n)return{data:null,error:new Ja("rpId is required for WebAuthn authentication")};try{if(!aw())return{data:null,error:new Js("Browser does not support WebAuthn",null)};const{data:l,error:c}=await this.challenge({factorId:e,webauthn:{rpId:n,rpOrigins:r},signal:o},{request:a});if(!l)return{data:null,error:c};const{webauthn:d}=l;return this._verify({factorId:e,challengeId:l.challengeId,webauthn:{type:d.type,rpId:n,rpOrigins:r,credential_response:d.credential_response}})}catch(l){return ce(l)?{data:null,error:l}:{data:null,error:new Js("Unexpected error in authenticate",l)}}}async _register({friendlyName:e,webauthn:{rpId:n=typeof window<"u"?window.location.hostname:void 0,rpOrigins:r=typeof window<"u"?[window.location.origin]:void 0,signal:o}={}},a){if(!n)return{data:null,error:new Ja("rpId is required for WebAuthn registration")};try{if(!aw())return{data:null,error:new Js("Browser does not support WebAuthn",null)};const{data:l,error:c}=await this._enroll({friendlyName:e});if(!l)return await this.client.mfa.listFactors().then(p=>{var g;return(g=p.data)===null||g===void 0?void 0:g.all.find(x=>x.factor_type==="webauthn"&&x.friendly_name===e&&x.status!=="unverified")}).then(p=>p?this.client.mfa.unenroll({factorId:p==null?void 0:p.id}):void 0),{data:null,error:c};const{data:d,error:f}=await this._challenge({factorId:l.id,friendlyName:l.friendly_name,webauthn:{rpId:n,rpOrigins:r},signal:o},{create:a});return d?this._verify({factorId:l.id,challengeId:d.challengeId,webauthn:{rpId:n,rpOrigins:r,type:d.webauthn.type,credential_response:d.webauthn.credential_response}}):{data:null,error:f}}catch(l){return ce(l)?{data:null,error:l}:{data:null,error:new Js("Unexpected error in register",l)}}}}WN();const uI={url:iN,storageKey:oN,autoRefreshToken:!0,persistSession:!0,detectSessionInUrl:!0,headers:aN,flowType:"implicit",debug:!1,hasCustomAuthorizationHeader:!1,throwOnError:!1,lockAcquireTimeout:5e3,skipAutoInitialize:!1};async function lw(t,e,n){return await n()}const Xi={};class Xa{get jwks(){var e,n;return(n=(e=Xi[this.storageKey])===null||e===void 0?void 0:e.jwks)!==null&&n!==void 0?n:{keys:[]}}set jwks(e){Xi[this.storageKey]=Object.assign(Object.assign({}
305,Xi[this.storageKey]),{jwks:e})}get jwks_cached_at(){var e,n;return(n=(e=Xi[this.storageKey])===null||e===void 0?void 0:e.cachedAt)!==null&&n!==void 0?n:Number.MIN_SAFE_INTEGER}set jwks_cached_at(e){Xi[this.storageKey]=Object.assign(Object.assign({},Xi[this.storageKey]),{cachedAt:e})}constructor(e){var n,r,o;this.userStorage=null,this.memoryStorage=null,this.stateChangeEmitters=new Map,this.autoRefreshTicker=null,this.autoRefreshTickTimeout=null,this.visibilityChangedCallback=null,this.refreshingDeferred=null,this.initializePromise=null,this.detectSessionInUrl=!0,this.hasCustomAuthorizationHeader=!1,this.suppressGetSessionWarning=!1,this.lockAcquired=!1,this.pendingInLock=[],this.broadcastChannel=null,this.logger=console.log;const a=Object.assign(Object.assign({},uI),e);if(this.storageKey=a.storageKey,this.instanceID=(n=Xa.nextInstanceID[this.storageKey])!==null&&n!==void 0?n:0,Xa.nextInstanceID[this.storageKey]=this.instanceID+1,this.logDebugMessages=!!a.debug,typeof a.debug=="function"&&(this.logger=a.debug),this.instanceID>0&&xt()){const l=`${this._logPrefix()} Multiple GoTrueClient instances detected in the same browser context. It is not an error, but this should be avoided as it may produce undefined behavior when used concurrently under the same storage key.`;console.warn(l),this.logDebugMessages&&console.trace(l)}if(this.persistSession=a.persistSession,this.autoRefreshToken=a.autoRefreshToken,this.admin=new VN({url:a.url,headers:a.headers,fetch:a.fetch}),this.url=a.url,this.headers=a.headers,this.fetch=mS(a.fetch),this.lock=a.lock||lw,this.detectSessionInUrl=a.detectSessionInUrl,this.flowType=a.flowType,this.hasCustomAuthorizationHeader=a.hasCustomAuthorizationHeader,this.throwOnError=a.throwOnError,this.lockAcquireTimeout=a.lockAcquireTimeout,a.lock?this.lock=a.lock:this.persistSession&&xt()&&(!((r=globalThis==null?void 0:globalThis.navigator)===null||r===void 0)&&r.locks)?this.lock=zN:this.lock=lw,this.jwks||(this.jwks={keys:[]},this.jwks_cached_at=Number.MIN_SAFE_INTEGER),this.mfa={verify:this._verify.bind(this),enroll:this._enroll.bind(this),unenroll:this._unenroll.bind(this),challenge:this._challenge.bind(this),listFactors:this._listFactors.bind(this),challengeAndVerify:this._challengeAndVerify.bind(this),getAuthenticatorAssuranceLevel:this._getAuthenticatorAssuranceLevel.bind(this),webauthn:new lI(this)},this.oauth={getAuthorizationDetails:this._getAuthorizationDetails.bind(this),approveAuthorization:this._approveAuthorization.bind(this),denyAuthorization:this._denyAuthorization.bind(this),listGrants:this._listOAuthGrants.bind(this),revokeGrant:this._revokeOAuthGrant.bind(this)},this.persistSession?(a.storage?this.storage=a.storage:pS()?this.storage=globalThis.localStorage:(this.memoryStorage={},this.storage=ow(this.memoryStorage)),a.userStorage&&(this.userStorage=a.userStorage)):(this.memoryStorage={},this.storage=ow(this.memoryStorage)),xt()&&globalThis.BroadcastChannel&&this.persistSession&&this.storageKey){try{this.broadcastChannel=new globalThis.BroadcastChannel(this.storageKey)}catch(l){console.error("Failed to create a new BroadcastChannel, multi-tab state changes will not be available",l)}(o=this.broadcastChannel)===null||o===void 0||o.addEventListener("message",async l=>{this._debug("received broadcast notification from other tab or client",l);try{await this._notifyAllSubscribers(l.data.event,l.data.session,!1)}catch(c){this._debug("#broadcastChannel","error",c)}})}a.skipAutoInitialize||this.initialize().catch(l=>{this._debug("#initialize()","error",l)})}isThrowOnErrorEnabled(){return this.throwOnError}_returnResult(e){if(this.throwOnError&&e&&e.error)throw e.error;return e}_logPrefix(){return`GoTrueClient@${this.storageKey}:${this.instanceID} (${dS}) ${new Date().toISOString()}`}_debug(...e){return this.logDebugMessages&&this.logger(this._logPrefix(),...e),this}async initialize(){return this.initializePromise?await this.initializePromise:(this.initializePromise=(async()=>await this._acquireLock(this.lockAcquireTimeout,async()=>await this._initialize()))(),await this.initializePromise)}async _initialize(){var e;try{let n={},r="none";if(xt()&&(n=bN(window.location.href),this._isImplicitGrantCallback(n)?r="implicit":await this._isPKCECallback(n)&&(r="pkce")),xt()&&this.detectSessionInUrl&&r!=="none"){const{data:o,error:a}=await this._getSessionFromURL(n,r);if(a){if(this._debug("#_initialize()","error detecting session from URL",a),hN(a)){const d=(e=a.details)===null||e===void 0?void 0:e.code;
305if(d==="identity_already_exists"||d==="identity_not_found"||d==="single_identity_not_deletable")return{error:a}}return{error:a}}const{session:l,redirectType:c}=o;return this._debug("#_initialize()","detected session in URL",l,"redirect type",c),await this._saveSession(l),setTimeout(async()=>{c==="recovery"?await this._notifyAllSubscribers("PASSWORD_RECOVERY",l):await this._notifyAllSubscribers("SIGNED_IN",l)},0),{error:null}}return await this._recoverAndRefresh(),{error:null}}catch(n){return ce(n)?this._returnResult({error:n}):this._returnResult({error:new Js("Unexpected error during initialization",n)})}finally{await this._handleVisibilityChange(),this._debug("#_initialize()","end")}}async signInAnonymously(e){var n,r,o;try{const a=await ge(this.fetch,"POST",`${this.url}/signup`,{headers:this.headers,body:{data:(r=(n=e==null?void 0:e.options)===null||n===void 0?void 0:n.data)!==null&&r!==void 0?r:{},gotrue_meta_security:{captcha_token:(o=e==null?void 0:e.options)===null||o===void 0?void 0:o.captchaToken}},xform:Rn}),{data:l,error:c}=a;if(c||!l)return this._returnResult({data:{user:null,session:null},error:c});const d=l.session,f=l.user;return l.session&&(await this._saveSession(l.session),await this._notifyAllSubscribers("SIGNED_IN",d)),this._returnResult({data:{user:f,session:d},error:null})}catch(a){if(ce(a))return this._returnResult({data:{user:null,session:null},error:a});throw a}}async signUp(e){var n,r,o;try{let a;if("email"in e){const{email:p,password:g,options:x}=e;let y=null,_=null;this.flowType==="pkce"&&([y,_]=await Yi(this.storage,this.storageKey)),a=await ge(this.fetch,"POST",`${this.url}/signup`,{headers:this.headers,redirectTo:x==null?void 0:x.emailRedirectTo,body:{email:p,password:g,data:(n=x==null?void 0:x.data)!==null&&n!==void 0?n:{},gotrue_meta_security:{captcha_token:x==null?void 0:x.captchaToken},code_challenge:y,code_challenge_method:_},xform:Rn})}else if("phone"in e){const{phone:p,password:g,options:x}=e;a=await ge(this.fetch,"POST",`${this.url}/signup`,{headers:this.headers,body:{phone:p,password:g,data:(r=x==null?void 0:x.data)!==null&&r!==void 0?r:{},channel:(o=x==null?void 0:x.channel)!==null&&o!==void 0?o:"sms",gotrue_meta_security:{captcha_token:x==null?void 0:x.captchaToken}},xform:Rn})}else throw new qu("You must provide either an email or phone number and a password");const{data:l,error:c}=a;if(c||!l)return await wt(this.storage,`${this.storageKey}-code-verifier`),this._returnResult({data:{user:null,session:null},error:c});const d=l.session,f=l.user;return l.session&&(await this._saveSession(l.session),await this._notifyAllSubscribers("SIGNED_IN",d)),this._returnResult({data:{user:f,session:d},error:null})}catch(a){if(await wt(this.storage,`${this.storageKey}-code-verifier`),ce(a))return this._returnResult({data:{user:null,session:null},error:a});throw a}}async signInWithPassword(e){try{let n;if("email"in e){const{email:a,password:l,options:c}=e;n=await ge(this.fetch,"POST",`${this.url}/token?grant_type=password`,{headers:this.headers,body:{email:a,password:l,gotrue_meta_security:{captcha_token:c==null?void 0:c.captchaToken}},xform:sw})}else if("phone"in e){const{phone:a,password:l,options:c}=e;n=await ge(this.fetch,"POST",`${this.url}/token?grant_type=password`,{headers:this.headers,body:{phone:a,password:l,gotrue_meta_security:{captcha_token:c==null?void 0:c.captchaToken}},xform:sw})}else throw new qu("You must provide either an email or phone number and a password");const{data:r,error:o}=n;if(o)return this._returnResult({data:{user:null,session:null},error:o});if(!r||!r.session||!r.user){const a=new Qi;return this._returnResult({data:{user:null,session:null},error:a})}return r.session&&(await this._saveSession(r.session),await this._notifyAllSubscribers("SIGNED_IN",r.session)),this._returnResult({data:Object.assign({user:r.user,session:r.session},r.weak_password?{weakPassword:r.weak_password}:null),error:o})}catch(n){if(ce(n))return this._returnResult({data:{user:null,session:null},error:n});throw n}}async signInWithOAuth(e){var n,r,o,a;return await this._handleProviderSignIn(e.provider,{redirectTo:(n=e.options)===null||n===void 0?void 0:n.redirectTo,scopes:(r=e.options)===null||r===void 0?void 0:r.scopes,queryParams:(o=e.options)===null||o===void 0?void 0:o.queryParams,skipBrowserRedirect:(a=e.options)===null||a===void 0?void 0:a.skipBrowserRedirect})}async exchangeCodeForSession(e){return await this.initializePromise,this._acquireLock(this.lockAcquireTimeout,async()=>this._exchangeCodeForSession(e))}async signInWithWeb3(e){const{chain:n}=e;switch(n){case"ethereum":return await this.signInWithEthereum(e);case"solana":return await this.signInWithSolana(e);default:throw new Error(`@supabase/auth-js: Unsupported chain "${n}"`)}}async signInWithEthereum(e){var n,r,o,a,l,c,d,f,p,g,x;let y,_;if("message"in e)y=e.message,_=e.signature;else{const{chain:S,wallet:b,statement:k,options:P}=e;let C;if(xt())if(typeof b=="object")C=b;else{const q=window;if("ethereum"in q&&typeof q.ethereum=="object"&&"request"in q.ethereum&&typeof q.ethereum.request=="function")C=q.ethereum;else throw new Error("@supabase/auth-js: No compatible Ethereum wallet interface on the window object (window.ethereum) detected. Make sure the user already has a wallet installed and connected for this app. Prefer passing the wallet interface object directly to signInWithWeb3({ chain: 'ethereum', wallet: resolvedUserWallet }) instead.")}else{if(typeof b!="object"||!(P!=null&&P.url))throw new Error("@supabase/auth-js: Both wallet and url must be specified in non-browser environments.");C=b}const A=new URL((n=P==null?void 0:P.url)!==null&&n!==void 0?n:window.location.href),L=await C.request({method:"eth_requestAccounts"}).then(q=>q).catch(()=>{throw new Error("@supabase/auth-js: Wallet method eth_requestAccounts is missing or invalid")});if(!L||L.length===0)throw new Error("@supabase/auth-js: No accounts available. Please ensure the wallet is connected.");const D=yS(L[0]);let V=(r=P==null?void 0:P.signInWithEthereum)===null||r===void 0?void 0:r.chainId;if(!V){const q=await C.request({method:"eth_chainId"});V=HN(q)}const z={domain:A.host,address:D,statement:k,uri:A.href,version:"1",chainId:V,nonce:(o=P==null?void 0:P.signInWithEthereum)===null||o===void 0?void 0:o.nonce,issuedAt:(l=(a=P==null?void 0:P.signInWithEthereum)===null||a===void 0?void 0:a.issuedAt)!==null&&l!==void 0?l:new Date,expirationTime:(c=P==null?void 0:P.signInWithEthereum)===null||c===void 0?void 0:c.expirationTime,notBefore:(d=P==null?void 0:P.signInWithEthereum)===null||d===void 0?void 0:d.notBefore,requestId:(f=P==null?void 0:P.signInWithEthereum)===null||f===void 0?void 0:f.requestId,resources:(p=P==null?void 0:P.signInWithEthereum)===null||p===void 0?void 0:p.resources};y=KN(z),_=await C.request({method:"personal_sign",params:[qN(y),D]})}try{const{data:S,error:b}=await ge(this.fetch,"POST",`${this.url}/token?grant_type=web3`,{headers:this.headers,body:Object.assign({chain:"ethereum",message:y,signature:_},!((g=e.options)===null||g===void 0)&&g.captchaToken?{gotrue_meta_security:{captcha_token:(x=e.options)===null||x===void 0?void 0:x.captchaToken}}:null),xform:Rn});if(b)throw b;if(!S||!S.session||!S.user){const k=new Qi;return this._returnResult({data:{user:null,session:null},error:k})}return S.session&&(await this._saveSession(S.session),await this._notifyAllSubscribers("SIGNED_IN",S.session)),this._returnResult({data:Object.assign({},S),error:b})}catch(S){if(ce(S))return this._returnResult({data:{user:null,session:null},error:S});throw S}}async signInWithSolana(e){var n,r,o,a,l,c,d,f,p,g,x,y;let _,S;if("message"in e)_=e.message,S=e.signature;else{const{chain:b,wallet:k,statement:P,options:C}=e;let A;if(xt())if(typeof k=="object")A=k;else{const D=window;
305if("solana"in D&&typeof D.solana=="object"&&("signIn"in D.solana&&typeof D.solana.signIn=="function"||"signMessage"in D.solana&&typeof D.solana.signMessage=="function"))A=D.solana;else throw new Error("@supabase/auth-js: No compatible Solana wallet interface on the window object (window.solana) detected. Make sure the user already has a wallet installed and connected for this app. Prefer passing the wallet interface object directly to signInWithWeb3({ chain: 'solana', wallet: resolvedUserWallet }) instead.")}else{if(typeof k!="object"||!(C!=null&&C.url))throw new Error("@supabase/auth-js: Both wallet and url must be specified in non-browser environments.");A=k}const L=new URL((n=C==null?void 0:C.url)!==null&&n!==void 0?n:window.location.href);if("signIn"in A&&A.signIn){const D=await A.signIn(Object.assign(Object.assign(Object.assign({issuedAt:new Date().toISOString()},C==null?void 0:C.signInWithSolana),{version:"1",domain:L.host,uri:L.href}),P?{statement:P}:null));let V;if(Array.isArray(D)&&D[0]&&typeof D[0]=="object")V=D[0];else if(D&&typeof D=="object"&&"signedMessage"in D&&"signature"in D)V=D;else throw new Error("@supabase/auth-js: Wallet method signIn() returned unrecognized value");if("signedMessage"in V&&"signature"in V&&(typeof V.signedMessage=="string"||V.signedMessage instanceof Uint8Array)&&V.signature instanceof Uint8Array)_=typeof V.signedMessage=="string"?V.signedMessage:new TextDecoder().decode(V.signedMessage),S=V.signature;else throw new Error("@supabase/auth-js: Wallet method signIn() API returned object without signedMessage and signature fields")}else{if(!("signMessage"in A)||typeof A.signMessage!="function"||!("publicKey"in A)||typeof A!="object"||!A.publicKey||!("toBase58"in A.publicKey)||typeof A.publicKey.toBase58!="function")throw new Error("@supabase/auth-js: Wallet does not have a compatible signMessage() and publicKey.toBase58() API");_=[`${L.host} wants you to sign in with your Solana account:`,A.publicKey.toBase58(),...P?["",P,""]:[""],"Version: 1",`URI: ${L.href}`,`Issued At: ${(o=(r=C==null?void 0:C.signInWithSolana)===null||r===void 0?void 0:r.issuedAt)!==null&&o!==void 0?o:new Date().toISOString()}`,...!((a=C==null?void 0:C.signInWithSolana)===null||a===void 0)&&a.notBefore?[`Not Before: ${C.signInWithSolana.notBefore}`]:[],...!((l=C==null?void 0:C.signInWithSolana)===null||l===void 0)&&l.expirationTime?[`Expiration Time: ${C.signInWithSolana.expirationTime}`]:[],...!((c=C==null?void 0:C.signInWithSolana)===null||c===void 0)&&c.chainId?[`Chain ID: ${C.signInWithSolana.chainId}`]:[],...!((d=C==null?void 0:C.signInWithSolana)===null||d===void 0)&&d.nonce?[`Nonce: ${C.signInWithSolana.nonce}`]:[],...!((f=C==null?void 0:C.signInWithSolana)===null||f===void 0)&&f.requestId?[`Request ID: ${C.signInWithSolana.requestId}`]:[],...!((g=(p=C==null?void 0:C.signInWithSolana)===null||p===void 0?void 0:p.resources)===null||g===void 0)&&g.length?["Resources",...C.signInWithSolana.resources.map(V=>`- ${V}`)]:[]].join(`
306`);const D=await A.signMessage(new TextEncoder().encode(_),"utf8");if(!D||!(D instanceof Uint8Array))throw new Error("@supabase/auth-js: Wallet signMessage() API returned an recognized value");S=D}}try{const{data:b,error:k}=await ge(this.fetch,"POST",`${this.url}/token?grant_type=web3`,{headers:this.headers,body:Object.assign({chain:"solana",message:_,signature:Zs(S)},!((x=e.options)===null||x===void 0)&&x.captchaToken?{gotrue_meta_security:{captcha_token:(y=e.options)===null||y===void 0?void 0:y.captchaToken}}:null),xform:Rn});if(k)throw k;if(!b||!b.session||!b.user){const P=new Qi;return this._returnResult({data:{user:null,session:null},error:P})}return b.session&&(await this._saveSession(b.session),await this._notifyAllSubscribers("SIGNED_IN",b.session)),this._returnResult({data:Object.assign({},b),error:k})}catch(b){if(ce(b))return this._returnResult({data:{user:null,session:null},error:b});throw b}}async _exchangeCodeForSession(e){const n=await qs(this.storage,`${this.storageKey}-code-verifier`),[r,o]=(n??"").split("/");try{if(!r&&this.flowType==="pkce")throw new fN;const{data:a,error:l}=await ge(this.fetch,"POST",`${this.url}/token?grant_type=pkce`,{headers:this.headers,body:{auth_code:e,code_verifier:r},xform:Rn});if(await wt(this.storage,`${this.storageKey}-code-verifier`),l)throw l;if(!a||!a.session||!a.user){const c=new Qi;return this._returnResult({data:{user:null,session:null,redirectType:null},error:c})}return a.session&&(await this._saveSession(a.session),await this._notifyAllSubscribers("SIGNED_IN",a.session)),this._returnResult({data:Object.assign(Object.assign({},a),{redirectType:o??null}),error:l})}catch(a){if(await wt(this.storage,`${this.storageKey}-code-verifier`),ce(a))return this._returnResult({data:{user:null,session:null,redirectType:null},error:a});throw a}}async signInWithIdToken(e){try{const{options:n,provider:r,token:o,access_token:a,nonce:l}=e,c=await ge(this.fetch,"POST",`${this.url}/token?grant_type=id_token`,{headers:this.headers,body:{provider:r,id_token:o,access_token:a,nonce:l,gotrue_meta_security:{captcha_token:n==null?void 0:n.captchaToken}},xform:Rn}),{data:d,error:f}=c;if(f)return this._returnResult({data:{user:null,session:null},error:f});if(!d||!d.session||!d.user){const p=new Qi;return this._returnResult({data:{user:null,session:null},error:p})}return d.session&&(await this._saveSession(d.session),await this._notifyAllSubscribers("SIGNED_IN",d.session)),this._returnResult({data:d,error:f})}catch(n){if(ce(n))return this._returnResult({data:{user:null,session:null},error:n});throw n}}async signInWithOtp(e){var n,r,o,a,l;try{if("email"in e){const{email:c,options:d}=e;let f=null,p=null;this.flowType==="pkce"&&([f,p]=await Yi(this.storage,this.storageKey));const{error:g}=await ge(this.fetch,"POST",`${this.url}/otp`,{headers:this.headers,body:{email:c,data:(n=d==null?void 0:d.data)!==null&&n!==void 0?n:{},create_user:(r=d==null?void 0:d.shouldCreateUser)!==null&&r!==void 0?r:!0,gotrue_meta_security:{captcha_token:d==null?void 0:d.captchaToken},code_challenge:f,code_challenge_method:p},redirectTo:d==null?void 0:d.emailRedirectTo});return this._returnResult({data:{user:null,session:null},error:g})}if("phone"in e){const{phone:c,options:d}=e,{data:f,error:p}=await ge(this.fetch,"POST",`${this.url}/otp`,{headers:this.headers,body:{phone:c,data:(o=d==null?void 0:d.data)!==null&&o!==void 0?o:{},create_user:(a=d==null?void 0:d.shouldCreateUser)!==null&&a!==void 0?a:!0,gotrue_meta_security:{captcha_token:d==null?void 0:d.captchaToken},channel:(l=d==null?void 0:d.channel)!==null&&l!==void 0?l:"sms"}});return this._returnResult({data:{user:null,session:null,messageId:f==null?void 0:f.message_id},error:p})}throw new qu("You must provide either an email or phone number.")}catch(c){if(await wt(this.storage,`${this.storageKey}-code-verifier`),ce(c))return this._returnResult({data:{user:null,session:null},error:c});throw c}}async verifyOtp(e){var n,r;try{let o,a;"options"in e&&(o=(n=e.options)===null||n===void 0?void 0:n.redirectTo,a=(r=e.options)===null||r===void 0?void 0:r.captchaToken);const{data:l,error:c}=await ge(this.fetch,"POST",`${this.url}/verify`,{headers:this.headers,body:Object.assign(Object.assign({},e),{gotrue_meta_security:{captcha_token:a}}),redirectTo:o,xform:Rn});if(c)throw c;if(!l)throw new Error("An error occurred on token verification.");const d=l.session,f=l.user;return d!=null&&d.access_token&&(await this._saveSession(d),await this._notifyAllSubscribers(e.type=="recovery"?"PASSWORD_RECOVERY":"SIGNED_IN",d)),this._returnResult({data:{user:f,session:d},error:null})}catch(o){if(ce(o))return this._returnResult({data:{user:null,session:null},error:o});throw o}}async signInWithSSO(e){var n,r,o,a,l;try{let c=null,d=null;this.flowType==="pkce"&&([c,d]=await Yi(this.storage,this.storageKey));const f=await ge(this.fetch,"POST",`${this.url}/sso`,{body:Object.assign(Object.assign(Object.assign(Object.assign(Object.assign({},"providerId"in e?{provider_id:e.providerId}:null),"domain"in e?{domain:e.domain}:null),{redirect_to:(r=(n=e.options)===null||n===void 0?void 0:n.redirectTo)!==null&&r!==void 0?r:void 0}),!((o=e==null?void 0:e.options)===null||o===void 0)&&o.captchaToken?{gotrue_meta_security:{captcha_token:e.options.captchaToken}}:null),{skip_http_redirect:!0,code_challenge:c,code_challenge_method:d}),headers:this.headers,xform:$N});return!((a=f.data)===null||a===void 0)&&a.url&&xt()&&!(!((l=e.options)===null||l===void 0)&&l.skipBrowserRedirect)&&window.location.assign(f.data.url),this._returnResult(f)}catch(c){if(await wt(this.storage,`${this.storageKey}-code-verifier`),ce(c))return this._returnResult({data:null,error:c});throw c}}async reauthenticate(){return await this.initializePromise,await this._acquireLock(this.lockAcquireTimeout,async()=>await this._reauthenticate())}async _reauthenticate(){try{return await this._useSession(async e=>{const{data:{session:n},error:r}=e;if(r)throw r;if(!n)throw new en;const{error:o}=await ge(this.fetch,"GET",`${this.url}/reauthenticate`,{headers:this.headers,jwt:n.access_token});return this._returnResult({data:{user:null,session:null},error:o})})}catch(e){if(ce(e))return this._returnResult({data:{user:null,session:null},error:e});throw e}}async resend(e){try{const n=`${this.url}/resend`;if("email"in e){const{email:r,type:o,options:a}=e,{error:l}=await ge(this.fetch,"POST",n,{headers:this.headers,body:{email:r,type:o,gotrue_meta_security:{captcha_token:a==null?void 0:a.captchaToken}},redirectTo:a==null?void 0:a.emailRedirectTo});return this._returnResult({data:{user:null,session:null},error:l})}else if("phone"in e){const{phone:r,type:o,options:a}=e,{data:l,error:c}=await ge(this.fetch,"POST",n,{headers:this.headers,body:{phone:r,type:o,gotrue_meta_security:{captcha_token:a==null?void 0:a.captchaToken}}});return this._returnResult({data:{user:null,session:null,messageId:l==null?void 0:l.message_id},error:c})}throw new qu("You must provide either an email or phone number and a type")}catch(n){if(ce(n))return this._returnResult({data:{user:null,session:null},error:n});throw n}}async getSession(){return await this.initializePromise,await this._acquireLock(this.lockAcquireTimeout,async()=>this._useSession(async n=>n))}async _acquireLock(e,n){this._debug("#_acquireLock","begin",e);try{if(this.lockAcquired){const r=this.pendingInLock.length?this.pendingInLock[this.pendingInLock.length-1]:Promise.resolve(),o=(async()=>(await r,await n()))();return this.pendingInLock.push((async()=>{try{await o}catch{}})()),o}return await this.lock(`lock:${this.storageKey}`,e,async()=>{this._debug("#_acquireLock","lock acquired for storage key",this.storageKey);try{this.lockAcquired=!0;const r=n();for(this.pendingInLock.push((async()=>{try{await r}catch{}})()),await r;this.pendingInLock.length;){const o=[...this.pendingInLock];await Promise.all(o),this.pendingInLock.splice(0,o.length)}return await r}finally{this._debug("#_acquireLock","lock released for storage key",this.storageKey),this.lockAcquired=!1}})}finally{this._debug("#_acquireLock","end")}}async _useSession(e){this._debug("#_useSession","begin");try{const n=await this.__loadSession();return await e(n)}finally{this._debug("#_useSession","end")}}async __loadSession(){this._debug("#__loadSession()","begin"),this.lockAcquired||this._debug("#__loadSession()","used outside of an acquired lock!",new Error().stack);try{let e=null;const n=await qs(this.storage,this.storageKey);if(this._debug("#getSession()","session from storage",n),n!==null&&(this._isValidSession(n)?e=n:(this._debug("#getSession()","session from storage is not val
306id"),await this._removeSession())),!e)return{data:{session:null},error:null};const r=e.expires_at?e.expires_at*1e3-Date.now()<af:!1;if(this._debug("#__loadSession()",`session has${r?"":" not"} expired`,"expires_at",e.expires_at),!r){if(this.userStorage){const l=await qs(this.userStorage,this.storageKey+"-user");l!=null&&l.user?e.user=l.user:e.user=cf()}if(this.storage.isServer&&e.user&&!e.user.__isUserNotAvailableProxy){const l={value:this.suppressGetSessionWarning};e.user=IN(e.user,l),l.value&&(this.suppressGetSessionWarning=!0)}return{data:{session:e},error:null}}const{data:o,error:a}=await this._callRefreshToken(e.refresh_token);return a?this._returnResult({data:{session:null},error:a}):this._returnResult({data:{session:o},error:null})}finally{this._debug("#__loadSession()","end")}}async getUser(e){if(e)return await this._getUser(e);await this.initializePromise;const n=await this._acquireLock(this.lockAcquireTimeout,async()=>await this._getUser());return n.data.user&&(this.suppressGetSessionWarning=!0),n}async _getUser(e){try{return e?await ge(this.fetch,"GET",`${this.url}/user`,{headers:this.headers,jwt:e,xform:ls}):await this._useSession(async n=>{var r,o,a;const{data:l,error:c}=n;if(c)throw c;return!(!((r=l.session)===null||r===void 0)&&r.access_token)&&!this.hasCustomAuthorizationHeader?{data:{user:null},error:new en}:await ge(this.fetch,"GET",`${this.url}/user`,{headers:this.headers,jwt:(a=(o=l.session)===null||o===void 0?void 0:o.access_token)!==null&&a!==void 0?a:void 0,xform:ls})})}catch(n){if(ce(n))return lf(n)&&(await this._removeSession(),await wt(this.storage,`${this.storageKey}-code-verifier`)),this._returnResult({data:{user:null},error:n});throw n}}async updateUser(e,n={}){return await this.initializePromise,await this._acquireLock(this.lockAcquireTimeout,async()=>await this._updateUser(e,n))}async _updateUser(e,n={}){try{return await this._useSession(async r=>{const{data:o,error:a}=r;if(a)throw a;if(!o.session)throw new en;const l=o.session;let c=null,d=null;this.flowType==="pkce"&&e.email!=null&&([c,d]=await Yi(this.storage,this.storageKey));const{data:f,error:p}=await ge(this.fetch,"PUT",`${this.url}/user`,{headers:this.headers,redirectTo:n==null?void 0:n.emailRedirectTo,body:Object.assign(Object.assign({},e),{code_challenge:c,code_challenge_method:d}),jwt:l.access_token,xform:ls});if(p)throw p;return l.user=f.user,await this._saveSession(l),await this._notifyAllSubscribers("USER_UPDATED",l),this._returnResult({data:{user:l.user},error:null})})}catch(r){if(await wt(this.storage,`${this.storageKey}-code-verifier`),ce(r))return this._returnResult({data:{user:null},error:r});throw r}}async setSession(e){return await this.initializePromise,await this._acquireLock(this.lockAcquireTimeout,async()=>await this._setSession(e))}async _setSession(e){try{if(!e.access_token||!e.refresh_token)throw new en;const n=Date.now()/1e3;let r=n,o=!0,a=null;const{payload:l}=Gu(e.access_token);if(l.exp&&(r=l.exp,o=r<=n),o){const{data:c,error:d}=await this._callRefreshToken(e.refresh_token);if(d)return this._returnResult({data:{user:null,session:null},error:d});if(!c)return{data:{user:null,session:null},error:null};a=c}else{const{data:c,error:d}=await this._getUser(e.access_token);if(d)return this._returnResult({data:{user:null,session:null},error:d});a={access_token:e.access_token,refresh_token:e.refresh_token,user:c.user,token_type:"bearer",expires_in:r-n,expires_at:r},await this._saveSession(a),await this._notifyAllSubscribers("SIGNED_IN",a)}return this._returnResult({data:{user:a.user,session:a},error:null})}catch(n){if(ce(n))return this._returnResult({data:{session:null,user:null},error:n});throw n}}async refreshSession(e){return await this.initializePromise,await this._acquireLock(this.lockAcquireTimeout,async()=>await this._refreshSession(e))}async _refreshSession(e){try{return await this._useSession(async n=>{var r;if(!e){const{data:l,error:c}=n;if(c)throw c;e=(r=l.session)!==null&&r!==void 0?r:void 0}if(!(e!=null&&e.refresh_token))throw new en;const{data:o,error:a}=await this._callRefreshToken(e.refresh_token);return a?this._returnResult({data:{user:null,session:null},error:a}):o?this._returnResult({data:{user:o.user,session:o},error:null}):this._returnResult({data:{user:null,session:null},error:null})})}catch(n){if(ce(n))return this._returnResult({data:{user:null,session:null},error:n});throw n}}async _getSessionFromURL(e,n){try{if(!xt())throw new Ku("No browser detected.");
306if(e.error||e.error_description||e.error_code)throw new Ku(e.error_description||"Error in URL with unspecified error_description",{error:e.error||"unspecified_error",code:e.error_code||"unspecified_code"});switch(n){case"implicit":if(this.flowType==="pkce")throw new J0("Not a valid PKCE flow url.");break;case"pkce":if(this.flowType==="implicit")throw new Ku("Not a valid implicit grant flow url.");break;default:}if(n==="pkce"){if(this._debug("#_initialize()","begin","is PKCE flow",!0),!e.code)throw new J0("No code detected.");const{data:P,error:C}=await this._exchangeCodeForSession(e.code);if(C)throw C;const A=new URL(window.location.href);return A.searchParams.delete("code"),window.history.replaceState(window.history.state,"",A.toString()),{data:{session:P.session,redirectType:null},error:null}}const{provider_token:r,provider_refresh_token:o,access_token:a,refresh_token:l,expires_in:c,expires_at:d,token_type:f}=e;if(!a||!c||!l||!f)throw new Ku("No session defined in URL");const p=Math.round(Date.now()/1e3),g=parseInt(c);let x=p+g;d&&(x=parseInt(d));const y=x-p;y*1e3<=to&&console.warn(`@supabase/gotrue-js: Session as retrieved from URL expires in ${y}s, should have been closer to ${g}s`);const _=x-g;p-_>=120?console.warn("@supabase/gotrue-js: Session as retrieved from URL was issued over 120s ago, URL could be stale",_,x,p):p-_<0&&console.warn("@supabase/gotrue-js: Session as retrieved from URL was issued in the future? Check the device clock for skew",_,x,p);const{data:S,error:b}=await this._getUser(a);if(b)throw b;const k={provider_token:r,provider_refresh_token:o,access_token:a,expires_in:g,expires_at:x,refresh_token:l,token_type:f,user:S.user};return window.location.hash="",this._debug("#_getSessionFromURL()","clearing window.location.hash"),this._returnResult({data:{session:k,redirectType:e.type},error:null})}catch(r){if(ce(r))return this._returnResult({data:{session:null,redirectType:null},error:r});throw r}}_isImplicitGrantCallback(e){return typeof this.detectSessionInUrl=="function"?this.detectSessionInUrl(new URL(window.location.href),e):!!(e.access_token||e.error_description)}async _isPKCECallback(e){const n=await qs(this.storage,`${this.storageKey}-code-verifier`);return!!(e.code&&n)}async signOut(e={scope:"global"}){return await this.initializePromise,await this._acquireLock(this.lockAcquireTimeout,async()=>await this._signOut(e))}async _signOut({scope:e}={scope:"global"}){return await this._useSession(async n=>{var r;const{data:o,error:a}=n;if(a&&!lf(a))return this._returnResult({error:a});const l=(r=o.session)===null||r===void 0?void 0:r.access_token;if(l){const{error:c}=await this.admin.signOut(l,e);if(c&&!(dN(c)&&(c.status===404||c.status===401||c.status===403)||lf(c)))return this._returnResult({error:c})}return e!=="others"&&(await this._removeSession(),await wt(this.storage,`${this.storageKey}-code-verifier`)),this._returnResult({error:null})})}onAuthStateChange(e){const n=xN(),r={id:n,callback:e,unsubscribe:()=>{this._debug("#unsubscribe()","state change callback with id removed",n),this.stateChangeEmitters.delete(n)}};return this._debug("#onAuthStateChange()","registered callback with id",n),this.stateChangeEmitters.set(n,r),(async()=>(await this.initializePromise,await this._acquireLock(this.lockAcquireTimeout,async()=>{this._emitInitialSession(n)})))(),{data:{subscription:r}}}async _emitInitialSession(e){return await this._useSession(async n=>{var r,o;try{const{data:{session:a},error:l}=n;if(l)throw l;await((r=this.stateChangeEmitters.get(e))===null||r===void 0?void 0:r.callback("INITIAL_SESSION",a)),this._debug("INITIAL_SESSION","callback id",e,"session",a)}catch(a){await((o=this.stateChangeEmitters.get(e))===null||o===void 0?void 0:o.callback("INITIAL_SESSION",null)),this._debug("INITIAL_SESSION","callback id",e,"error",a),console.error(a)}})}async resetPasswordForEmail(e,n={}){let r=null,o=null;this.flowType==="pkce"&&([r,o]=await Yi(this.storage,this.storageKey,!0));try{return await ge(this.fetch,"POST",`${this.url}/recover`,{body:{email:e,code_challenge:r,code_challenge_method:o,gotrue_meta_security:{captcha_token:n.captchaToken}},headers:this.headers,redirectTo:n.redirectTo})}catch(a){if(await wt(this.storage,`${this.storageKey}-code-verifier`),ce(a))return this._returnResult({data:null,error:a});throw a}}async getUserIdentities(){var e;try{const{data:n,error:r}=await this.getUser();if(r)throw r;return this._returnResult({data:{identities:(e=n.user.identities)!==null&&e!==void 0?e:[]},error:null})}catch(n){if(ce(n))return this._returnResult({data:null,error:n});throw n}}async linkIdentity(e){return"token"in e?this.linkIdentityIdToken(e):this.linkIdentityOAuth(e)}async linkIdentityOAuth(e){var n;try{const{data:r,error:o}=await this._useSession(async a=>{var l,c,d,f,p;const{data:g,error:x}=a;if(x)throw x;const y=await this._getUrlForProvider(`${this.url}/user/identities/authorize`,e.provider,{redirectTo:(l=e.options)===null||l===void 0?void 0:l.redirectTo,scopes:(c=e.options)===null||c===void 0?void 0:c.scopes,queryParams:(d=e.options)===null||d===void 0?void 0:d.queryParams,skipBrowserRedirect:!0});return await ge(this.fetch,"GET",y,{headers:this.headers,jwt:(p=(f=g.session)===null||f===void 0?void 0:f.access_token)!==null&&p!==void 0?p:void 0})});if(o)throw o;return xt()&&!(!((n=e.options)===null||n===void 0)&&n.skipBrowserRedirect)&&window.location.assign(r==null?void 0:r.url),this._returnResult({data:{provider:e.provider,url:r==null?void 0:r.url},error:null})}catch(r){if(ce(r))return this._returnResult({data:{provider:e.provider,url:null},error:r});throw r}}async linkIdentityIdToken(e){return await this._useSession(async n=>{var r;try{const{error:o,data:{session:a}}=n;if(o)throw o;const{options:l,provider:c,token:d,access_token:f,nonce:p}=e,g=await ge(this.fetch,"POST",`${this.url}/token?grant_type=id_token`,{headers:this.headers,jwt:(r=a==null?void 0:a.access_token)!==null&&r!==void 0?r:void 0,body:{provider:c,id_token:d,access_token:f,nonce:p,link_identity:!0,gotrue_meta_security:{captcha_token:l==null?void 0:l.captchaToken}},xform:Rn}),{data:x,error:y}=g;return y?this._returnResult({data:{user:null,session:null},error:y}):!x||!x.session||!x.user?this._returnResult({data:{user:null,session:null},error:new Qi}):(x.session&&(await this._saveSession(x.session),await this._notifyAllSubscribers("USER_UPDATED",x.session)),this._returnResult({data:x,error:y}))}catch(o){if(await wt(this.storage,`${this.storageKey}-code-verifier`),ce(o))return this._returnResult({data:{user:null,session:null},error:o});throw o}})}async unlinkIdentity(e){try{return await this._useSession(async n=>{var r,o;const{data:a,error:l}=n;if(l)throw l;
306return await ge(this.fetch,"DELETE",`${this.url}/user/identities/${e.identity_id}`,{headers:this.headers,jwt:(o=(r=a.session)===null||r===void 0?void 0:r.access_token)!==null&&o!==void 0?o:void 0})})}catch(n){if(ce(n))return this._returnResult({data:null,error:n});throw n}}async _refreshAccessToken(e){const n=`#_refreshAccessToken(${e.substring(0,5)}...)`;this._debug(n,"begin");try{const r=Date.now();return await EN(async o=>(o>0&&await _N(200*Math.pow(2,o-1)),this._debug(n,"refreshing attempt",o),await ge(this.fetch,"POST",`${this.url}/token?grant_type=refresh_token`,{body:{refresh_token:e},headers:this.headers,xform:Rn})),(o,a)=>{const l=200*Math.pow(2,o);return a&&uf(a)&&Date.now()+l-r<to})}catch(r){if(this._debug(n,"error",r),ce(r))return this._returnResult({data:{session:null,user:null},error:r});throw r}finally{this._debug(n,"end")}}_isValidSession(e){return typeof e=="object"&&e!==null&&"access_token"in e&&"refresh_token"in e&&"expires_at"in e}async _handleProviderSignIn(e,n){const r=await this._getUrlForProvider(`${this.url}/authorize`,e,{redirectTo:n.redirectTo,scopes:n.scopes,queryParams:n.queryParams});return this._debug("#_handleProviderSignIn()","provider",e,"options",n,"url",r),xt()&&!n.skipBrowserRedirect&&window.location.assign(r),{data:{provider:e,url:r},error:null}}async _recoverAndRefresh(){var e,n;const r="#_recoverAndRefresh()";this._debug(r,"begin");try{const o=await qs(this.storage,this.storageKey);if(o&&this.userStorage){let l=await qs(this.userStorage,this.storageKey+"-user");!this.storage.isServer&&Object.is(this.storage,this.userStorage)&&!l&&(l={user:o.user},await no(this.userStorage,this.storageKey+"-user",l)),o.user=(e=l==null?void 0:l.user)!==null&&e!==void 0?e:cf()}else if(o&&!o.user&&!o.user){const l=await qs(this.storage,this.storageKey+"-user");l&&(l!=null&&l.user)?(o.user=l.user,await wt(this.storage,this.storageKey+"-user"),await no(this.storage,this.storageKey,o)):o.user=cf()}if(this._debug(r,"session from storage",o),!this._isValidSession(o)){this._debug(r,"session is not valid"),o!==null&&await this._removeSession();return}const a=((n=o.expires_at)!==null&&n!==void 0?n:1/0)*1e3-Date.now()<af;if(this._debug(r,`session has${a?"":" not"} expired with margin of ${af}s`),a){if(this.autoRefreshToken&&o.refresh_token){const{error:l}=await this._callRefreshToken(o.refresh_token);l&&(console.error(l),uf(l)||(this._debug(r,"refresh failed with a non-retryable error, removing the session",l),await this._removeSession()))}}else if(o.user&&o.user.__isUserNotAvailableProxy===!0)try{const{data:l,error:c}=await this._getUser(o.access_token);!c&&(l!=null&&l.user)?(o.user=l.user,await this._saveSession(o),await this._notifyAllSubscribers("SIGNED_IN",o)):this._debug(r,"could not get user data, skipping SIGNED_IN notification")}catch(l){console.error("Error getting user data:",l),this._debug(r,"error getting user data, skipping SIGNED_IN notification",l)}else await this._notifyAllSubscribers("SIGNED_IN",o)}catch(o){this._debug(r,"error",o),console.error(o);return}finally{this._debug(r,"end")}}async _callRefreshToken(e){var n,r;if(!e)throw new en;if(this.refreshingDeferred)return this.refreshingDeferred.promise;const o=`#_callRefreshToken(${e.substring(0,5)}...)`;this._debug(o,"begin");try{this.refreshingDeferred=new Yc;const{data:a,error:l}=await this._refreshAccessToken(e);if(l)throw l;if(!a.session)throw new en;await this._saveSession(a.session),await this._notifyAllSubscribers("TOKEN_REFRESHED",a.session);const c={data:a.session,error:null};return this.refreshingDeferred.resolve(c),c}catch(a){if(this._debug(o,"error",a),ce(a)){const l={data:null,error:a};return uf(a)||await this._removeSession(),(n=this.refreshingDeferred)===null||n===void 0||n.resolve(l),l}throw(r=this.refreshingDeferred)===null||r===void 0||r.reject(a),a}finally{this.refreshingDeferred=null,this._debug(o,"end")}}async _notifyAllSubscribers(e,n,r=!0){const o=`#_notifyAllSubscribers(${e})`;this._debug(o,"begin",n,`broadcast = ${r}`);try{this.broadcastChannel&&r&&this.broadcastChannel.postMessage({event:e,session:n});const a=[],l=Array.from(this.stateChangeEmitters.values()).map(async c=>{try{await c.callback(e,n)}catch(d){a.push(d)}});if(await Promise.all(l),a.length>0){for(let c=0;c<a.length;c+=1)console.error(a[c]);throw a[0]}}finally{this._debug(o,"end")}}async _saveSession(e){this._debug("#_saveSession()",e),this.suppressGetSessionWarning=!0,await wt(this.storage,`${this.storageKey}-code-verifier`);const n=Object.assign({},e),r=n.user&&n.user.__isUserNotAvailableProxy===!0;if(this.userStorage){!r&&n.user&&await no(this.userStorage,this.storageKey+"-user",{user:n.user});const o=Object.assign({},n);delete o.user;const a=nw(o);await no(this.storage,this.storageKey,a)}else{const o=nw(n);await no(this.storage,this.storageKey,o)}}async _removeSession(){this._debug("#_removeSession()"),this.suppressGetSessionWarning=!1,await wt(this.storage,this.storageKey),await wt(this.storage,this.storageKey+"-code-verifier"),await wt(this.storage,this.storageKey+"-user"),this.userStorage&&await wt(this.userStorage,this.storageKey+"-user"),await this._notifyAllSubscribers("SIGNED_OUT",null)}_removeVisibilityChangedCallback(){this._debug("#_removeVisibilityChangedCallback()");const e=this.visibilityChangedCallback;this.visibilityChangedCallback=null;try{e&&xt()&&(window!=null&&window.removeEventListener)&&window.removeEventListener("visibilitychange",e)}
306catch(n){console.error("removing visibilitychange callback failed",n)}}async _startAutoRefresh(){await this._stopAutoRefresh(),this._debug("#_startAutoRefresh()");const e=setInterval(()=>this._autoRefreshTokenTick(),to);this.autoRefreshTicker=e,e&&typeof e=="object"&&typeof e.unref=="function"?e.unref():typeof Deno<"u"&&typeof Deno.unrefTimer=="function"&&Deno.unrefTimer(e);const n=setTimeout(async()=>{await this.initializePromise,await this._autoRefreshTokenTick()},0);this.autoRefreshTickTimeout=n,n&&typeof n=="object"&&typeof n.unref=="function"?n.unref():typeof Deno<"u"&&typeof Deno.unrefTimer=="function"&&Deno.unrefTimer(n)}async _stopAutoRefresh(){this._debug("#_stopAutoRefresh()");const e=this.autoRefreshTicker;this.autoRefreshTicker=null,e&&clearInterval(e);const n=this.autoRefreshTickTimeout;this.autoRefreshTickTimeout=null,n&&clearTimeout(n)}async startAutoRefresh(){this._removeVisibilityChangedCallback(),await this._startAutoRefresh()}async stopAutoRefresh(){this._removeVisibilityChangedCallback(),await this._stopAutoRefresh()}async _autoRefreshTokenTick(){this._debug("#_autoRefreshTokenTick()","begin");try{await this._acquireLock(0,async()=>{try{const e=Date.now();try{return await this._useSession(async n=>{const{data:{session:r}}=n;if(!r||!r.refresh_token||!r.expires_at){this._debug("#_autoRefreshTokenTick()","no session");return}const o=Math.floor((r.expires_at*1e3-e)/to);this._debug("#_autoRefreshTokenTick()",`access token expires in ${o} ticks, a tick lasts ${to}ms, refresh threshold is ${gp} ticks`),o<=gp&&await this._callRefreshToken(r.refresh_token)})}catch(n){console.error("Auto refresh tick failed with error. This is likely a transient error.",n)}}finally{this._debug("#_autoRefreshTokenTick()","end")}})}catch(e){if(e.isAcquireTimeout||e instanceof gS)this._debug("auto refresh token tick lock not available");else throw e}}async _handleVisibilityChange(){if(this._debug("#_handleVisibilityChange()"),!xt()||!(window!=null&&window.addEventListener))return this.autoRefreshToken&&this.startAutoRefresh(),!1;try{this.visibilityChangedCallback=async()=>{try{await this._onVisibilityChanged(!1)}catch(e){this._debug("#visibilityChangedCallback","error",e)}},window==null||window.addEventListener("visibilitychange",this.visibilityChangedCallback),await this._onVisibilityChanged(!0)}catch(e){console.error("_handleVisibilityChange",e)}}async _onVisibilityChanged(e){const n=`#_onVisibilityChanged(${e})`;this._debug(n,"visibilityState",document.visibilityState),document.visibilityState==="visible"?(this.autoRefreshToken&&this._startAutoRefresh(),e||(await this.initializePromise,await this._acquireLock(this.lockAcquireTimeout,async()=>{if(document.visibilityState!=="visible"){this._debug(n,"acquired the lock to recover the session, but the browser visibilityState is no longer visible, aborting");return}await this._recoverAndRefresh()}))):document.visibilityState==="hidden"&&this.autoRefreshToken&&this._stopAutoRefresh()}async _getUrlForProvider(e,n,r){const o=[`provider=${encodeURIComponent(n)}`];if(r!=null&&r.redirectTo&&o.push(`redirect_to=${encodeURIComponent(r.redirectTo)}`),r!=null&&r.scopes&&o.push(`scopes=${encodeURIComponent(r.scopes)}`),this.flowType==="pkce"){const[a,l]=await Yi(this.storage,this.storageKey),c=new URLSearchParams({code_challenge:`${encodeURIComponent(a)}`,code_challenge_method:`${encodeURIComponent(l)}`});o.push(c.toString())}if(r!=null&&r.queryParams){const a=new URLSearchParams(r.queryParams);o.push(a.toString())}return r!=null&&r.skipBrowserRedirect&&o.push(`skip_http_redirect=${r.skipBrowserRedirect}`),`${e}?${o.join("&")}`}async _unenroll(e){try{return await this._useSession(async n=>{var r;const{data:o,error:a}=n;return a?this._returnResult({data:null,error:a}):await ge(this.fetch,"DELETE",`${this.url}/factors/${e.factorId}`,{headers:this.headers,jwt:(r=o==null?void 0:o.session)===null||r===void 0?void 0:r.access_token})})}catch(n){if(ce(n))return this._returnResult({data:null,error:n});throw n}}async _enroll(e){try{return await this._useSession(async n=>{var r,o;const{data:a,error:l}=n;if(l)return this._returnResult({data:null,error:l});const c=Object.assign({friendly_name:e.friendlyName,factor_type:e.factorType},e.factorType==="phone"?{phone:e.phone}:e.factorType==="totp"?{issuer:e.issuer}:{}),{data:d,error:f}=await ge(this.fetch,"POST",`${this.url}/factors`,{body:c,headers:this.headers,jwt:(r=a==null?void 0:a.session)===null||r===void 0?void 0:r.access_token});return f?this._returnResult({data:null,error:f}):(e.factorType==="totp"&&d.type==="totp"&&(!((o=d==null?void 0:d.totp)===null||o===void 0)&&o.qr_code)&&(d.totp.qr_code=`data:image/svg+xml;utf-8,${d.totp.qr_code}`),this._returnResult({data:d,error:null}))})}catch(n){if(ce(n))return this._returnResult({data:null,error:n});throw n}}async _verify(e){return this._acquireLock(this.lockAcquireTimeout,async()=>{try{return await this._useSession(async n=>{var r;const{data:o,error:a}=n;
306if(a)return this._returnResult({data:null,error:a});const l=Object.assign({challenge_id:e.challengeId},"webauthn"in e?{webauthn:Object.assign(Object.assign({},e.webauthn),{credential_response:e.webauthn.type==="create"?eI(e.webauthn.credential_response):tI(e.webauthn.credential_response)})}:{code:e.code}),{data:c,error:d}=await ge(this.fetch,"POST",`${this.url}/factors/${e.factorId}/verify`,{body:l,headers:this.headers,jwt:(r=o==null?void 0:o.session)===null||r===void 0?void 0:r.access_token});return d?this._returnResult({data:null,error:d}):(await this._saveSession(Object.assign({expires_at:Math.round(Date.now()/1e3)+c.expires_in},c)),await this._notifyAllSubscribers("MFA_CHALLENGE_VERIFIED",c),this._returnResult({data:c,error:d}))})}catch(n){if(ce(n))return this._returnResult({data:null,error:n});throw n}})}async _challenge(e){return this._acquireLock(this.lockAcquireTimeout,async()=>{try{return await this._useSession(async n=>{var r;const{data:o,error:a}=n;if(a)return this._returnResult({data:null,error:a});const l=await ge(this.fetch,"POST",`${this.url}/factors/${e.factorId}/challenge`,{body:e,headers:this.headers,jwt:(r=o==null?void 0:o.session)===null||r===void 0?void 0:r.access_token});if(l.error)return l;const{data:c}=l;if(c.type!=="webauthn")return{data:c,error:null};switch(c.webauthn.type){case"create":return{data:Object.assign(Object.assign({},c),{webauthn:Object.assign(Object.assign({},c.webauthn),{credential_options:Object.assign(Object.assign({},c.webauthn.credential_options),{publicKey:XN(c.webauthn.credential_options.publicKey)})})}),error:null};case"request":return{data:Object.assign(Object.assign({},c),{webauthn:Object.assign(Object.assign({},c.webauthn),{credential_options:Object.assign(Object.assign({},c.webauthn.credential_options),{publicKey:ZN(c.webauthn.credential_options.publicKey)})})}),error:null}}})}catch(n){if(ce(n))return this._returnResult({data:null,error:n});throw n}})}async _challengeAndVerify(e){const{data:n,error:r}=await this._challenge({factorId:e.factorId});return r?this._returnResult({data:null,error:r}):await this._verify({factorId:e.factorId,challengeId:n.id,code:e.code})}async _listFactors(){var e;const{data:{user:n},error:r}=await this.getUser();if(r)return{data:null,error:r};const o={all:[],phone:[],totp:[],webauthn:[]};for(const a of(e=n==null?void 0:n.factors)!==null&&e!==void 0?e:[])o.all.push(a),a.status==="verified"&&o[a.factor_type].push(a);return{data:o,error:null}}async _getAuthenticatorAssuranceLevel(e){var n,r,o,a;if(e)try{const{payload:y}=Gu(e);let _=null;y.aal&&(_=y.aal);let S=_;const{data:{user:b},error:k}=await this.getUser(e);if(k)return this._returnResult({data:null,error:k});((r=(n=b==null?void 0:b.factors)===null||n===void 0?void 0:n.filter(A=>A.status==="verified"))!==null&&r!==void 0?r:[]).length>0&&(S="aal2");const C=y.amr||[];return{data:{currentLevel:_,nextLevel:S,currentAuthenticationMethods:C},error:null}}catch(y){if(ce(y))return this._returnResult({data:null,error:y});throw y}const{data:{session:l},error:c}
306=await this.getSession();if(c)return this._returnResult({data:null,error:c});if(!l)return{data:{currentLevel:null,nextLevel:null,currentAuthenticationMethods:[]},error:null};const{payload:d}=Gu(l.access_token);let f=null;d.aal&&(f=d.aal);let p=f;((a=(o=l.user.factors)===null||o===void 0?void 0:o.filter(y=>y.status==="verified"))!==null&&a!==void 0?a:[]).length>0&&(p="aal2");const x=d.amr||[];return{data:{currentLevel:f,nextLevel:p,currentAuthenticationMethods:x},error:null}}async _getAuthorizationDetails(e){try{return await this._useSession(async n=>{const{data:{session:r},error:o}=n;return o?this._returnResult({data:null,error:o}):r?await ge(this.fetch,"GET",`${this.url}/oauth/authorizations/${e}`,{headers:this.headers,jwt:r.access_token,xform:a=>({data:a,error:null})}):this._returnResult({data:null,error:new en})})}catch(n){if(ce(n))return this._returnResult({data:null,error:n});throw n}}async _approveAuthorization(e,n){try{return await this._useSession(async r=>{const{data:{session:o},error:a}=r;if(a)return this._returnResult({data:null,error:a});if(!o)return this._returnResult({data:null,error:new en});const l=await ge(this.fetch,"POST",`${this.url}/oauth/authorizations/${e}/consent`,{headers:this.headers,jwt:o.access_token,body:{action:"approve"},xform:c=>({data:c,error:null})});return l.data&&l.data.redirect_url&&xt()&&!(n!=null&&n.skipBrowserRedirect)&&window.location.assign(l.data.redirect_url),l})}catch(r){if(ce(r))return this._returnResult({data:null,error:r});throw r}}async _denyAuthorization(e,n){try{return await this._useSession(async r=>{const{data:{session:o},error:a}=r;if(a)return this._returnResult({data:null,error:a});if(!o)return this._returnResult({data:null,error:new en});const l=await ge(this.fetch,"POST",`${this.url}/oauth/authorizations/${e}/consent`,{headers:this.headers,jwt:o.access_token,body:{action:"deny"},xform:c=>({data:c,error:null})});return l.data&&l.data.redirect_url&&xt()&&!(n!=null&&n.skipBrowserRedirect)&&window.location.assign(l.data.redirect_url),l})}catch(r){if(ce(r))return this._returnResult({data:null,error:r});throw r}}async _listOAuthGrants(){try{return await this._useSession(async e=>{const{data:{session:n},error:r}=e;return r?this._returnResult({data:null,error:r}):n?await ge(this.fetch,"GET",`${this.url}/user/oauth/grants`,{headers:this.headers,jwt:n.access_token,xform:o=>({data:o,error:null})}):this._returnResult({data:null,error:new en})})}catch(e){if(ce(e))return this._returnResult({data:null,error:e});throw e}}async _revokeOAuthGrant(e){try{return await this._useSession(async n=>{const{data:{session:r},error:o}=n;return o?this._returnResult({data:null,error:o}):r?(await ge(this.fetch,"DELETE",`${this.url}/user/oauth/grants`,{headers:this.headers,jwt:r.access_token,query:{client_id:e.clientId},noResolveJson:!0}),{data:{},error:null}):this._returnResult({data:null,error:new en})})}catch(n){if(ce(n))return this._returnResult({data:null,error:n});throw n}}async fetchJwk(e,n={keys:[]}){let r=n.keys.find(c=>c.kid===e);if(r)return r;const o=Date.now();if(r=this.jwks.keys.find(c=>c.kid===e),r&&this.jwks_cached_at+uN>o)return r;const{data:a,error:l}=await ge(this.fetch,"GET",`${this.url}/.well-known/jwks.json`,{headers:this.headers});if(l)throw l;return!a.keys||a.keys.length===0||(this.jwks=a,this.jwks_cached_at=o,r=a.keys.find(c=>c.kid===e),!r)?null:r}async getClaims(e,n={}){try{let r=e;if(!r){const{data:y,error:_}
306=await this.getSession();if(_||!y.session)return this._returnResult({data:null,error:_});r=y.session.access_token}const{header:o,payload:a,signature:l,raw:{header:c,payload:d}}=Gu(r);n!=null&&n.allowExpired||jN(a.exp);const f=!o.alg||o.alg.startsWith("HS")||!o.kid||!("crypto"in globalThis&&"subtle"in globalThis.crypto)?null:await this.fetchJwk(o.kid,n!=null&&n.keys?{keys:n.keys}:n==null?void 0:n.jwks);if(!f){const{error:y}=await this.getUser(r);if(y)throw y;return{data:{claims:a,header:o,signature:l},error:null}}const p=ON(o.alg),g=await crypto.subtle.importKey("jwk",f,p,!0,["verify"]);if(!await crypto.subtle.verify(p,g,l,vN(`${c}.${d}`)))throw new wp("Invalid JWT signature");return{data:{claims:a,header:o,signature:l},error:null}}catch(r){if(ce(r))return this._returnResult({data:null,error:r});throw r}}}Xa.nextInstanceID={};const cI=Xa,dI="2.99.2";let ja="";typeof Deno<"u"?ja="deno":typeof document<"u"?ja="web":typeof navigator<"u"&&navigator.product==="ReactNative"?ja="react-native":ja="node";const hI={"X-Client-Info":`supabase-js-${ja}/${dI}`},fI={headers:hI},pI={schema:"public"},mI={autoRefreshToken:!0,persistSession:!0,detectSessionInUrl:!0,flowType:"implicit"},gI={};function Za(t){"@babel/helpers - typeof";return Za=typeof Symbol=="function"&&typeof Symbol.iterator=="symbol"?function(e){return typeof e}:function(e){return e&&typeof Symbol=="function"&&e.constructor===Symbol&&e!==Symbol.prototype?"symbol":typeof e},Za(t)}function yI(t,e){if(Za(t)!="object"||!t)return t;var n=t[Symbol.toPrimitive];if(n!==void 0){var r=n.call(t,e);if(Za(r)!="object")return r;throw new TypeError("@@toPrimitive must return a primitive value.")}return(e==="string"?String:Number)(t)}function vI(t){var e=yI(t,"string");return Za(e)=="symbol"?e:e+""}function wI(t,e,n){return(e=vI(e))in t?Object.defineProperty(t,e,{value:n,enumerable:!0,configurable:!0,writable:!0}):t[e]=n,t}function uw(t,e){var n=Object.keys(t);if(Object.getOwnPropertySymbols){var r=Object.getOwnPropertySymbols(t);e&&(r=r.filter(function(o){return Object.getOwnPropertyDescriptor(t,o).enumerable})),n.push.apply(n,r)}return n}function Xe(t){for(var e=1;e<arguments.length;e++){var n=arguments[e]!=null?arguments[e]:{};e%2?uw(Object(n),!0).forEach(function(r){wI(t,r,n[r])}):Object.getOwnPropertyDescriptors?Object.defineProperties(t,Object.getOwnPropertyDescriptors(n)):uw(Object(n)).forEach(function(r){Object.defineProperty(t,r,Object.getOwnPropertyDescriptor(n,r))})}return t}const xI=t=>t?(...e)=>t(...e):(...e)=>fetch(...e),bI=()=>Headers,SI=(t,e,n)=>{const r=xI(n),o=bI();return async(a,l)=>{var c;const d=(c=await e())!==null&&c!==void 0?c:t;let f=new o(l==null?void 0:l.headers);return f.has("apikey")||f.set("apikey",t),f.has("Authorization")||f.set("Authorization",`Bearer ${d}`),r(a,Xe(Xe({},l),{},{headers:f}))}};function _I(t){return t.endsWith("/")?t:t+"/"}function EI(t,e){var n,r;const{db:o,auth:a,realtime:l,global:c}=t,{db:d,auth:f,realtime:p,global:g}=e,x={db:Xe(Xe({},d),o),auth:Xe(Xe({},f),a),realtime:Xe(Xe({},p),l),storage:{},global:Xe(Xe(Xe({},g),c),{},{headers:Xe(Xe({},(n=g==null?void 0:g.headers)!==null&&n!==void 0?n:{}),(r=c==null?void 0:c.headers)!==null&&r!==void 0?r:{})}),accessToken:async()=>""};return t.accessToken?x.accessToken=t.accessToken:delete x.accessToken,x}function TI(t){const e=t==null?void 0:t.trim();if(!e)throw new Error("supabaseUrl is required.");if(!e.match(/^https?:\/\//i))throw new Error("Invalid supabaseUrl: Must be a valid HTTP or HTTPS URL.");try{return new URL(_I(e))}catch{throw Error("Invalid supabaseUrl: Provided URL is malformed.")}}var kI=class extends cI{constructor(t){super(t)}},CI=class{constructor(t,e,n){var r,o;this.supabaseUrl=t,this.supabaseKey=e;const a=TI(t);if(!e)throw new Error("supabaseKey is required.");this.realtimeUrl=new URL("realtime/v1",a),this.realtimeUrl.protocol=this.realtimeUrl.protocol.replace("http","ws"),this.authUrl=new URL("auth/v1",a),this.storageUrl=new URL("storage/v1",a),this.functionsUrl=new URL("functions/v1",a);const l=`sb-${a.hostname.split(".")[0]}-auth-token`,c={db:pI,realtime:gI,auth:Xe(Xe({},mI),{},{storageKey:l}),global:fI},d=EI(n??{},c);if(this.storageKey=(r=d.auth.storageKey)!==null&&r!==void 0?r:"",this.headers=(o=d.global.headers)!==null&&o!==void 0?o:{},d.accessToken)this.accessToken=d.accessToken,this.auth=new Proxy({},{get:(p,g)=>{throw new Error(`@supabase/supabase-js: Supabase Client is configured with the accessToken option, accessing supabase.auth.${String(g)} is not possible`)}});else{var f;this.auth=this._initSupabaseAuthClient((f=d.auth)!==null&&f!==void 0?f:{},this.headers,d.global.fetch)}this.fetch=SI(e,this._getAccessToken.bind(this),d.global.fetch),this.realtime=this._initRealtimeClient(Xe({headers:this.headers,accessToken:this._getAccessToken.bind(this)},d.realtime)),this.accessToken&&Promise.resolve(this.accessToken()).then(p=>this.realtime.setAuth(p)).catch(p=>console.warn("Failed to set initial Realtime auth token:",p)),this.rest=new d2(new URL("rest/v1",a).href,{headers:this.headers,schema:d.db.schema,fetch:this.fetch,timeout:d.db.timeout,urlLengthLimit:d.db.urlLengthLimit}),this.storage=new sN(this.storageUrl.href,this.headers,this.fetch,n==null?void 0:n.storage),d.accessToken||this._listenForAuthEvents()}get functions(){return new r2(this.functionsUrl.href,{headers:this.headers,customFetch:this.fetch})}from(t){return this.rest.from(t)}schema(t){return this.rest.schema(t)}rpc(t,e={},n={head:!1,get:!1,count:void 0}){return this.rest.rpc(t,e,n)}channel(t,e={config:{}}){return this.realtime.channel(t,e)}getChannels(){return this.realtime.getChannels()}removeChannel(t){return this.realtime.removeChannel(t)}removeAllChannels(){return this.realtime.removeAllChannels()}async _getAccessToken(){var t=this,e,n;if(t.accessToken)return await t.accessToken();const{data:r}=await t.auth.getSession();
306return(e=(n=r.session)===null||n===void 0?void 0:n.access_token)!==null&&e!==void 0?e:t.supabaseKey}_initSupabaseAuthClient({autoRefreshToken:t,persistSession:e,detectSessionInUrl:n,storage:r,userStorage:o,storageKey:a,flowType:l,lock:c,debug:d,throwOnError:f},p,g){const x={Authorization:`Bearer ${this.supabaseKey}`,apikey:`${this.supabaseKey}`};return new kI({url:this.authUrl.href,headers:Xe(Xe({},x),p),storageKey:a,autoRefreshToken:t,persistSession:e,detectSessionInUrl:n,storage:r,userStorage:o,flowType:l,lock:c,debug:d,throwOnError:f,fetch:g,hasCustomAuthorizationHeader:Object.keys(this.headers).some(y=>y.toLowerCase()==="authorization")})}_initRealtimeClient(t){return new P2(this.realtimeUrl.href,Xe(Xe({},t),{},{params:Xe(Xe({},{apikey:this.supabaseKey}),t==null?void 0:t.params)}))}_listenForAuthEvents(){return this.auth.onAuthStateChange((t,e)=>{this._handleTokenChanged(t,"CLIENT",e==null?void 0:e.access_token)})}_handleTokenChanged(t,e,n){(t==="TOKEN_REFRESHED"||t==="SIGNED_IN")&&this.changedAccessToken!==n?(this.changedAccessToken=n,this.realtime.setAuth(n)):t==="SIGNED_OUT"&&(this.realtime.setAuth(),e=="STORAGE"&&this.auth.signOut(),this.changedAccessToken=void 0)}};const PI=(t,e,n)=>new CI(t,e,n);function AI(){if(typeof window<"u")return!1;const t=globalThis.process;if(!t)return!1;const e=t.version;if(e==null)return!1;const n=e.match(/^v(\d+)\./);return n?parseInt(n[1],10)<=18:!1}AI()&&console.warn("⚠️  Node.js 18 and below are deprecated and will no longer be supported in future versions of @supabase/supabase-js. Please upgrade to Node.js 20 or later. For more information, visit: https://github.com/orgs/supabase/discussions/37217");const RI="https://cuqfhigxhmwhyvfbyrjj.supabase.co",jI="eyJhbGciOiJIUzI1NiIsInR5cCI6IkpXVCJ9.eyJpc3MiOiJzdXBhYmFzZSIsInJlZiI6ImN1cWZoaWd4aG13aHl2ZmJ5cmpqIiwicm9sZSI6ImFub24iLCJpYXQiOjE3NzQzNDMyNTgsImV4cCI6MjA4OTkxOTI1OH0.5Z021daeiCNKiibx33hMHOsQZPql2gbmnnrHQKsDs0Q",$n=PI(RI,jI,{auth:{storage:localStorage,persistSession:!0,autoRefreshToken:!0}}),wS=E.createContext({user:null,session:null,loading:!0,signOut:async()=>{}}),yl=()=>E.useContext(wS),OI=({children:t})=>{const[e,n]=E.useState(null),[r,o]=E.useState(null),[a,l]=E.useState(!0);E.useEffect(()=>{const{data:{subscription:d}}=$n.auth.onAuthStateChange((f,p)=>{o(p),n((p==null?void 0:p.user)??null),l(!1)});return $n.auth.getSession().then(({data:{session:f}})=>{o(f),n((f==null?void 0:f.user)??null),l(!1)}),()=>d.unsubscribe()},[]);const c=async()=>{await $n.auth.signOut()};return v.jsx(wS.Provider,{value:{user:e,session:r,loading:a,signOut:c},children:t})},wm=E.createContext({});function xm(t){const e=E.useRef(null);return e.current===null&&(e.current=t()),e.current}const NI=typeof window<"u",xS=NI?E.useLayoutEffect:E.useEffect,Jc=E.createContext(null);function bm(t,e){t.indexOf(e)===-1&&t.push(e)}function bc(t,e){const n=t.indexOf(e);n>-1&&t.splice(n,1)}const ur=(t,e,n)=>n>e?e:n<t?t:n;let Sm=()=>{};const _s={},bS=t=>/^-?(?:\d+(?:\.\d+)?|\.\d+)$/u.test(t);function SS(t){return typeof t=="object"&&t!==null}const _S=t=>/^0[^.\s]+$/u.test(t);function ES(t){let e;return()=>(e===void 0&&(e=t()),e)}const vn=t=>t,II=(t,e)=>n=>e(t(n)),vl=(...t)=>t.reduce(II),el=(t,e,n)=>{const r=e-t;return r===0?1:(n-t)/r};class _m{constructor(){this.subscriptions=[]}add(e){return bm(this.subscriptions,e),()=>bc(this.subscriptions,e)}notify(e,n,r){const o=this.subscriptions.length;if(o)if(o===1)this.subscriptions[0](e,n,r);else for(let a=0;a<o;a++){const l=this.subscriptions[a];l&&l(e,n,r)}}getSize(){return this.subscriptions.length}clear(){this.subscriptions.length=0}}const sn=t=>t*1e3,yn=t=>t/1e3;function TS(t,e){return e?t*(1e3/e):0}const kS=(t,e,n)=>(((1-3*n+3*e)*t+(3*n-6*e))*t+3*e)*t,LI=1e-7,DI=12;function MI(t,e,n,r,o){let a,l,c=0;do l=e+(n-e)/2,a=kS(l,r,o)-t,a>0?n=l:e=l;while(Math.abs(a)>LI&&++c<DI);return l}function wl(t,e,n,r){if(t===e&&n===r)return vn;const o=a=>MI(a,0,1,t,n);return a=>a===0||a===1?a:kS(o(a),e,r)}const CS=t=>e=>e<=.5?t(2*e)/2:(2-t(2*(1-e)))/2,PS=t=>e=>1-t(1-e),AS=wl(.33,1.53,.69,.99),Em=PS(AS),RS=CS(Em),jS=t=>t>=1?1:(t*=2)<1?.5*Em(t):.5*(2-Math.pow(2,-10*(t-1))),Tm=t=>1-Math.sin(Math.acos(t)),OS=PS(Tm),NS=CS(Tm),$I=wl(.42,0,1,1),FI=wl(0,0,.58,1),IS=wl(.42,0,.58,1),UI=t=>Array.isArray(t)&&typeof t[0]!="number",LS=t=>Array.isArray(t)&&typeof t[0]=="number",VI={linear:vn,easeIn:$I,easeInOut:IS,easeOut:FI,circIn:Tm,circInOut:NS,circOut:OS,backIn:Em,backInOut:RS,backOut:AS,anticipate:jS},BI=t=>typeof t=="string",cw=t=>{if(LS(t)){Sm(t.length===4);const[e,n,r,o]=t;return wl(e,n,r,o)}else if(BI(t))return VI[t];return t},Qu=["setup","read","resolveKeyframes","preUpdate","update","preRender","render","postRender"];function zI(t,e){let n=new Set,r=new Set,o=!1,a=!1;const l=new WeakSet;let c={delta:0,timestamp:0,isProcessing:!1};function d(p){l.has(p)&&(f.schedule(p),t()),p(c)}const f={schedule:(p,g=!1,x=!1)=>{const _=x&&o?n:r;return g&&l.add(p),_.add(p),p},cancel:p=>{r.delete(p),l.delete(p)},process:p=>{if(c=p,o){a=!0;return}o=!0;const g=n;
vendor: 26,995 bytes, line 306
306n=r,r=g,n.forEach(d),n.clear(),o=!1,a&&(a=!1,f.process(p))}};return f}const WI=40;function DS(t,e){let n=!1,r=!0;const o={delta:0,timestamp:0,isProcessing:!1},a=()=>n=!0,l=Qu.reduce((C,A)=>(C[A]=zI(a),C),{}),{setup:c,read:d,resolveKeyframes:f,preUpdate:p,update:g,preRender:x,render:y,postRender:_}=l,S=()=>{const C=_s.useManualTiming,A=C?o.timestamp:performance.now();n=!1,C||(o.delta=r?1e3/60:Math.max(Math.min(A-o.timestamp,WI),1)),o.timestamp=A,o.isProcessing=!0,c.process(o),d.process(o),f.process(o),p.process(o),g.process(o),x.process(o),y.process(o),_.process(o),o.isProcessing=!1,n&&e&&(r=!1,t(S))},b=()=>{n=!0,r=!0,o.isProcessing||t(S)};return{schedule:Qu.reduce((C,A)=>{const L=l[A];return C[A]=(D,V=!1,z=!1)=>(n||b(),L.schedule(D,V,z)),C},{}),cancel:C=>{for(let A=0;A<Qu.length;A++)l[Qu[A]].cancel(C)},state:o,steps:l}}const{schedule:Ue,cancel:Es,state:bt,steps:hf}=DS(typeof requestAnimationFrame<"u"?requestAnimationFrame:vn,!0);let ic;function HI(){ic=void 0}const It={now:()=>(ic===void 0&&It.set(bt.isProcessing||_s.useManualTiming?bt.timestamp:performance.now()),ic),set:t=>{ic=t,queueMicrotask(HI)}},MS=t=>e=>typeof e=="string"&&e.startsWith(t),$S=MS("--"),qI=MS("var(--"),km=t=>qI(t)?KI.test(t.split("/*")[0].trim()):!1,KI=/var\(--(?:[\w-]+\s*|[\w-]+\s*,(?:\s*[^)(\s]|\s*\((?:[^)(]|\([^)(]*\))*\))+\s*)\)$/iu;function dw(t){return typeof t!="string"?!1:t.split("/*")[0].includes("var(--")}const Do={test:t=>typeof t=="number",parse:parseFloat,transform:t=>t},tl={...Do,transform:t=>ur(0,1,t)},Yu={...Do,default:1},Da=t=>Math.round(t*1e5)/1e5,Cm=/-?(?:\d+(?:\.\d+)?|\.\d+)/gu;function GI(t){return t==null}const QI=/^(?:#[\da-f]{3,8}|(?:rgb|hsl)a?\((?:-?[\d.]+%?[,\s]+){2}-?[\d.]+%?\s*(?:[,/]\s*)?(?:\b\d+(?:\.\d+)?|\.\d+)?%?\))$/iu,Pm=(t,e)=>n=>!!(typeof n=="string"&&QI.test(n)&&n.startsWith(t)||e&&!GI(n)&&Object.prototype.hasOwnProperty.call(n,e)),FS=(t,e,n)=>r=>{if(typeof r!="string")return r;const[o,a,l,c]=r.match(Cm);return{[t]:parseFloat(o),[e]:parseFloat(a),[n]:parseFloat(l),alpha:c!==void 0?parseFloat(c):1}},YI=t=>ur(0,255,t),ff={...Do,transform:t=>Math.round(YI(t))},ei={test:Pm("rgb","red"),parse:FS("red","green","blue"),transform:({red:t,green:e,blue:n,alpha:r=1})=>"rgba("+ff.transform(t)+", "+ff.transform(e)+", "+ff.transform(n)+", "+Da(tl.transform(r))+")"};function JI(t){let e="",n="",r="",o="";return t.length>5?(e=t.substring(1,3),n=t.substring(3,5),r=t.substring(5,7),o=t.substring(7,9)):(e=t.substring(1,2),n=t.substring(2,3),r=t.substring(3,4),o=t.substring(4,5),e+=e,n+=n,r+=r,o+=o),{red:parseInt(e,16),green:parseInt(n,16),blue:parseInt(r,16),alpha:o?parseInt(o,16)/255:1}}const xp={test:Pm("#"),parse:JI,transform:ei.transform},xl=t=>({test:e=>typeof e=="string"&&e.endsWith(t)&&e.split(" ").length===1,parse:parseFloat,transform:e=>`${e}${t}`}),is=xl("deg"),lr=xl("%"),ue=xl("px"),XI=xl("vh"),ZI=xl("vw"),hw={...lr,parse:t=>lr.parse(t)/100,transform:t=>lr.transform(t*100)},io={test:Pm("hsl","hue"),parse:FS("hue","saturation","lightness"),transform:({hue:t,saturation:e,lightness:n,alpha:r=1})=>"hsla("+Math.round(t)+", "+lr.transform(Da(e))+", "+lr.transform(Da(n))+", "+Da(tl.transform(r))+")"},it={test:t=>ei.test(t)||xp.test(t)||io.test(t),parse:t=>ei.test(t)?ei.parse(t):io.test(t)?io.parse(t):xp.parse(t),transform:t=>typeof t=="string"?t:t.hasOwnProperty("red")?ei.transform(t):io.transform(t),getAnimatableNone:t=>{const e=it.parse(t);return e.alpha=0,it.transform(e)}},eL=/(?:#[\da-f]{3,8}|(?:rgb|hsl)a?\((?:-?[\d.]+%?[,\s]+){2}-?[\d.]+%?\s*(?:[,/]\s*)?(?:\b\d+(?:\.\d+)?|\.\d+)?%?\))/giu;function tL(t){var e,n;return isNaN(t)&&typeof t=="string"&&(((e=t.match(Cm))==null?void 0:e.length)||0)+(((n=t.match(eL))==null?void 0:n.length)||0)>0}const US="number",VS="color",nL="var",rL="var(",fw="${}",sL=/var\s*\(\s*--(?:[\w-]+\s*|[\w-]+\s*,(?:\s*[^)(\s]|\s*\((?:[^)(]|\([^)(]*\))*\))+\s*)\)|#[\da-f]{3,8}|(?:rgb|hsl)a?\((?:-?[\d.]+%?[,\s]+){2}-?[\d.]+%?\s*(?:[,/]\s*)?(?:\b\d+(?:\.\d+)?|\.\d+)?%?\)|-?(?:\d+(?:\.\d+)?|\.\d+)/giu;function Po(t){const e=t.toString(),n=[],r={color:[],number:[],var:[]},o=[];let a=0;const c=e.replace(sL,d=>(it.test(d)?(r.color.push(a),o.push(VS),n.push(it.parse(d))):d.startsWith(rL)?(r.var.push(a),o.push(nL),n.push(d)):(r.number.push(a),o.push(US),n.push(parseFloat(d))),++a,fw)).split(fw);return{values:n,split:c,indexes:r,types:o}}function iL(t){return Po(t).values}function BS({split:t,types:e}){const n=t.length;return r=>{let o="";for(let a=0;a<n;a++)if(o+=t[a],r[a]!==void 0){const l=e[a];l===US?o+=Da(r[a]):l===VS?o+=it.transform(r[a]):o+=r[a]}return o}}function oL(t){return BS(Po(t))}const aL=t=>typeof t=="number"?0:it.test(t)?it.getAnimatableNone(t):t,lL=(t,e)=>typeof t=="number"?e!=null&&e.trim().endsWith("/")?t:0:aL(t);function uL(t){const e=Po(t);return BS(e)(e.values.map((r,o)=>lL(r,e.split[o])))}const Fn={test:tL,parse:iL,createTransformer:oL,getAnimatableNone:uL};function pf(t,e,n){return n<0&&(n+=1),n>1&&(n-=1),n<1/6?t+(e-t)*6*n:n<1/2?e:n<2/3?t+(e-t)*(2/3-n)*6:t}function cL({hue:t,saturation:e,lightness:n,alpha:r}){t/=360,e/=100,n/=100;let o=0,a=0,l=0;if(!e)o=a=l=n;else{const c=n<.5?n*(1+e):n+e-n*e,d=2*n-c;o=pf(d,c,t+1/3),a=pf(d,c,t),l=pf(d,c,t-1/3)}return{red:Math.round(o*255),green:Math.round(a*255),blue:Math.round(l*255),alpha:r}}function Sc(t,e){return n=>n>0?e:t}const qe=(t,e,n)=>t+(e-t)*n,mf=(t,e,n)=>{const r=t*t,o=n*(e*e-r)+r;return o<0?0:Math.sqrt(o)},dL=[xp,ei,io],hL=t=>dL.find(e=>e.test(t));function pw(t){const e=hL(t);if(!e)return!1;let n=e.parse(t);return e===io&&(n=cL(n)),n}const mw=(t,e)=>{const n=pw(t),r=pw(e);if(!n||!r)return Sc(t,e);const o={...n};return a=>(o.red=mf(n.red,r.red,a),o.green=mf(n.green,r.green,a),o.blue=mf(n.blue,r.blue,a),o.alpha=qe(n.alpha,r.alpha,a),ei.transform(o))},bp=new Set(["none","hidden"]);function fL(t,e){return bp.has(t)?n=>n<=0?t:e:n=>n>=1?e:t}function pL(t,e){return n=>qe(t,e,n)}function Am(t){return typeof t=="number"?pL:typeof t=="string"?km(t)?Sc:it.test(t)?mw:yL:Array.isArray(t)?zS:typeof t=="object"?it.test(t)?mw:mL:Sc}function zS(t,e){const n=[...t],r=n.length,o=t.map((a,l)=>Am(a)(a,e[l]));return a=>{for(let l=0;l<r;l++)n[l]=o[l](a);return n}}function mL(t,e){const n={...t,...e},r={};for(const o in n)t[o]!==void 0&&e[o]!==void 0&&(r[o]=Am(t[o])(t[o],e[o]));return o=>{for(const a in r)n[a]=r[a](o);return n}}function gL(t,e){const n=[],r={color:0,var:0,number:0};for(let o=0;o<e.values.length;o++){const a=e.types[o],l=t.indexes[a][r[a]],c=t.values[l]??0;n[o]=c,r[a]++}return n}const yL=(t,e)=>{const n=Fn.createTransformer(e),r=Po(t),o=Po(e);return r.indexes.var.length===o.indexes.var.length&&r.indexes.color.length===o.indexes.color.length&&r.indexes.number.length>=o.indexes.number.length?bp.has(t)&&!o.values.length||bp.has(e)&&!r.values.length?fL(t,e):vl(zS(gL(r,o),o.values),n):Sc(t,e)};function WS(t,e,n){return typeof t=="number"&&typeof e=="number"&&typeof n=="number"?qe(t,e,n):Am(t)(t,e)}const vL=t=>{const e=({timestamp:n})=>t(n);return{start:(n=!0)=>Ue.update(e,n),stop:()=>Es(e),now:()=>bt.isProcessing?bt.timestamp:It.now()}},HS=(t,e,n=10)=>{let r="";const o=Math.max(Math.round(e/n),2);for(let a=0;a<o;a++)r+=Math.round(t(a/(o-1))*1e4)/1e4+", ";return`linear(${r.substring(0,r.length-2)})`},_c=2e4;function Rm(t){let e=0;const n=50;let r=t.next(e);for(;!r.done&&e<_c;)e+=n,r=t.next(e);return e>=_c?1/0:e}function wL(t,e=100,n){const r=n({...t,keyframes:[0,e]}),o=Math.min(Rm(r),_c);return{type:"keyframes",ease:a=>r.next(o*a).value/e,duration:yn(o)}}const Ze={stiffness:100,damping:10,mass:1,velocity:0,duration:800,bounce:.3,visualDuration:.3,restSpeed:{granular:.01,default:2},restDelta:{granular:.005,default:.5},minDuration:.01,maxDuration:10,minDamping:.05,maxDamping:1};function Sp(t,e){return t*Math.sqrt(1-e*e)}const xL=12;function bL(t,e,n){let r=n;for(let o=1;o<xL;o++)r=r-t(r)/e(r);return r}const gf=.001;function SL({duration:t=Ze.duration,bounce:e=Ze.bounce,velocity:n=Ze.velocity,mass:r=Ze.mass}){let o,a,l=1-e;l=ur(Ze.minDamping,Ze.maxDamping,l),t=ur(Ze.minDuration,Ze.maxDuration,yn(t)),l<1?(o=f=>{const p=f*l,g=p*t,x=p-n,y=Sp(f,l),_=Math.exp(-g);return gf-x/y*_},a=f=>{const g=f*l*t,x=g*n+n,y=Math.pow(l,2)*Math.pow(f,2)*t,_=Math.exp(-g),S=Sp(Math.pow(f,2),l);return(-o(f)+gf>0?-1:1)*((x-y)*_)/S}):(o=f=>{const p=Math.exp(-f*t),g=(f-n)*t+1;return-gf+p*g},a=f=>{const p=Math.exp(-f*t),g=(n-f)*(t*t);return p*g});const c=5/t,d=bL(o,a,c);if(t=sn(t),isNaN(d))return{stiffness:Ze.stiffness,damping:Ze.damping,duration:t};{const f=Math.pow(d,2)*r;return{stiffness:f,damping:l*2*Math.sqrt(r*f),duration:t}}}const _L=["duration","bounce"],EL=["stiffness","damping","mass"];function gw(t,e){return e.some(n=>t[n]!==void 0)}function TL(t){let e={velocity:Ze.velocity,stiffness:Ze.stiffness,damping:Ze.damping,mass:Ze.mass,isResolvedFromDuration:!1,...t};if(!gw(t,EL)&&gw(t,_L))if(e.velocity=0,t.visualDuration){const n=t.visualDuration,r=2*Math.PI/(n*1.2),o=r*r,a=2*ur(.05,1,1-(t.bounce||0))*Math.sqrt(o);e={...e,mass:Ze.mass,stiffness:o,damping:a}}else{const n=SL({...t,velocity:0});e={...e,...n,mass:Ze.mass},e.isResolvedFromDuration=!0}return e}function Ec(t=Ze.visualDuration,e=Ze.bounce){const n=typeof t!="object"?{visualDuration:t,keyframes:[0,1],bounce:e}:t;let{restSpeed:r,restDelta:o}=n;const a=n.keyframes[0],l=n.keyframes[n.keyframes.length-1],c={done:!1,value:a},{stiffness:d,damping:f,mass:p,duration:g,velocity:x,isResolvedFromDuration:y}=TL({...n,velocity:-yn(n.velocity||0)}),_=x||0,S=f/(2*Math.sqrt(d*p)),b=l-a,k=yn(Math.sqrt(d/p)),P=Math.abs(b)<5;r||(r=P?Ze.restSpeed.granular:Ze.restSpeed.default),o||(o=P?Ze.restDelta.granular:Ze.restDelta.default);let C,A,L,D,V,z;if(S<1)L=Sp(k,S),D=(_+S*k*b)/L,C=H=>{const te=Math.exp(-S*k*H);return l-te*(D*Math.sin(L*H)+b*Math.cos(L*H))},V=S*k*D+b*L,z=S*k*b-D*L,A=H=>Math.exp(-S*k*H)*(V*Math.sin(L*H)+z*Math.cos(L*H));else if(S===1){C=te=>l-Math.exp(-k*te)*(b+(_+k*b)*te);const H=_+k*b;A=te=>Math.exp(-k*te)*(k*H*te-_)}else{const H=k*Math.sqrt(S*S-1);C=J=>{const fe=Math.exp(-S*k*J),ie=Math.min(H*J,300);return l-fe*((_+S*k*b)*Math.sinh(ie)+H*b*Math.cosh(ie))/H};const te=(_+S*k*b)/H,Z=S*k*te-b*H,me=S*k*b-te*H;A=J=>{const fe=Math.exp(-S*k*J),ie=Math.min(H*J,300);return fe*(Z*Math.sinh(ie)+me*Math.cosh(ie))}}const q={calculatedDuration:y&&g||null,velocity:H=>sn(A(H)),next:H=>{if(!y&&S<1){const Z=Math.exp(-S*k*H),me=Math.sin(L*H),J=Math.cos(L*H),fe=l-Z*(D*me+b*J),ie=sn(Z*(V*me+z*J));return c.done=Math.abs(ie)<=r&&Math.abs(l-fe)<=o,c.value=c.done?l:fe,c}const te=C(H);if(y)c.done=H>=g;else{const Z=sn(A(H));c.done=Math.abs(Z)<=r&&Math.abs(l-te)<=o}return c.value=c.done?l:te,c},toString:()=>{const H=Math.min(Rm(q),_c),te=HS(Z=>q.next(H*Z).value,H,30);return H+"ms "+te},toTransition:()=>{}};return q}Ec.applyToOptions=t=>{const e=wL(t,100,Ec);return t.ease=e.ease,t.duration=sn(e.duration),t.type="keyframes",t};const kL=5;function qS(t,e,n){const r=Math.max(e-kL,0);return TS(n-t(r),e-r)}function _p({keyframes:t,velocity:e=0,power:n=.8,timeConstant:r=325,bounceDamping:o=10,bounceStiffness:a=500,modifyTarget:l,min:c,max:d,restDelta:f=.5,restSpeed:p}){const g=t[0],x={done:!1,value:g},y=z=>c!==void 0&&z<c||d!==void 0&&z>d,_=z=>c===void 0?d:d===void 0||Math.abs(c-z)<Math.abs(d-z)?c:d;let S=n*e;const b=g+S,k=l===void 0?b:l(b);k!==b&&(S=k-g);const P=z=>-S*Math.exp(-z/r),C=z=>k+P(z),A=z=>{const q=P(z),H=C(z);x.done=Math.abs(q)<=f,x.value=x.done?k:H};let L,D;const V=z=>{y(x.value)&&(L=z,D=Ec({keyframes:[x.value,_(x.value)],velocity:qS(C,z,x.value),damping:o,stiffness:a,restDelta:f,restSpeed:p}))};return V(0),{calculatedDuration:null,next:z=>{let q=!1;return!D&&L===void 0&&(q=!0,A(z),V(z)),L!==void 0&&z>=L?D.next(z-L):(!q&&A(z),x)}}}function CL(t,e,n){const r=[],o=n||_s.mix||WS,a=t.length-1;for(let l=0;l<a;l++){let c=o(t[l],t[l+1]);if(e){const d=Array.isArray(e)?e[l]||vn:e;c=vl(d,c)}r.push(c)}return r}function PL(t,e,{clamp:n=!0,ease:r,mixer:o}={}){const a=t.length;if(Sm(a===e.length),a===1)return()=>e[0];if(a===2&&e[0]===e[1])return()=>e[1];const l=t[0]===t[1];t[0]>t[a-1]&&(t=[...t].reverse(),e=[...e].reverse());const c=CL(e,r,o),d=c.length,f=p=>{if(l&&p<t[0])return e[0];let g=0;if(d>1)for(;g<t.length-2&&!(p<t[g+1]);g++);const x=el(t[g],t[g+1],p);return c[g](x)};return n?p=>f(ur(t[0],t[a-1],p)):f}function AL(t,e){const n=t[t.length-1];for(let r=1;r<=e;r++){const o=el(0,e,r);t.push(qe(n,1,o))}}function RL(t){const e=[0];return AL(e,t.length-1),e}function jL(t,e){return t.map(n=>n*e)}function OL(t,e){return t.map(()=>e||IS).splice(0,t.length-1)}function Ma({duration:t=300,keyframes:e,times:n,ease:r="easeInOut"}){const o=UI(r)?r.map(cw):cw(r),a={done:!1,value:e[0]},l=jL(n&&n.length===e.length?n:RL(e),t),c=PL(l,e,{ease:Array.isArray(o)?o:OL(e,o)});return{calculatedDuration:t,next:d=>(a.value=c(d),a.done=d>=t,a)}}const NL=t=>t!==null;function Xc(t,{repeat:e,repeatType:n="loop"},r,o=1){const a=t.filter(NL),c=o<0||e&&n!=="loop"&&e%2===1?0:a.length-1;return!c||r===void 0?a[c]:r}const IL={decay:_p,inertia:_p,tween:Ma,keyframes:Ma,spring:Ec};function KS(t){typeof t.type=="string"&&(t.type=IL[t.type])}class jm{constructor(){this.updateFinished()}get finished(){return this._finished}updateFinished(){this._finished=new Promise(e=>{this.resolve=e})}notifyFinished(){this.resolve()}then(e,n){return this.finished.then(e,n)}}const LL=t=>t/100;class Tc extends jm{constructor(e){super(),this.state="idle",this.startTime=null,this.isStopped=!1,this.currentTime=0,this.holdTime=null,this.playbackSpeed=1,this.delayState={done:!1,value:void 0},this.stop=()=>{var r,o;const{motionValue:n}=this.options;n&&n.updatedAt!==It.now()&&this.tick(It.now()),this.isStopped=!0,this.state!=="idle"&&(this.teardown(),(o=(r=this.options).onStop)==null||o.call(r))},this.options=e,this.initAnimation(),this.play(),e.autoplay===!1&&this.pause()}initAnimation(){const{options:e}=this;KS(e);const{type:n=Ma,repeat:r=0,repeatDelay:o=0,repeatType:a,velocity:l=0}=e;let{keyframes:c}=e;const d=n||Ma;d!==Ma&&typeof c[0]!="number"&&(this.mixKeyframes=vl(LL,WS(c[0],c[1])),c=[0,100]);const f=d({...e,keyframes:c});a==="mirror"&&(this.mirroredGenerator=d({...e,keyframes:[...c].reverse(),velocity:-l})),f.calculatedDuration===null&&(f.calculatedDuration=Rm(f));const{calculatedDuration:p}=f;this.calculatedDuration=p,this.resolvedDuration=p+o,this.totalDuration=this.resolvedDuration*(r+1)-o,this.generator=f}updateTime(e){const n=Math.round(e-this.startTime)*this.playbackSpeed;this.holdTime!==null?this.currentTime=this.holdTime:this.currentTime=n}tick(e,n=!1){const{generator:r,totalDuration:o,mixKeyframes:a,mirroredGenerator:l,resolvedDuration:c,calculatedDuration:d}=this;if(this.startTime===null)return r.next(0);const{delay:f=0,keyframes:p,repeat:g,repeatType:x,repeatDelay:y,type:_,onUpdate:S,finalKeyframe:b}=this.options;this.speed>0?this.startTime=Math.min(this.startTime,e):this.speed<0&&(this.startTime=Math.min(e-o/this.speed,this.startTime)),n?this.currentTime=e:this.updateTime(e);const k=this.currentTime-f*(this.playbackSpeed>=0?1:-1),P=this.playbackSpeed>=0?k<0:k>o;this.currentTime=Math.max(k,0),this.state==="finished"&&this.holdTime===null&&(this.currentTime=o);let C=this.currentTime,A=r;if(g){const z=Math.min(this.currentTime,o)/c;let q=Math.floor(z),H=z%1;!H&&z>=1&&(H=1),H===1&&q--,q=Math.min(q,g+1),!!(q%2)&&(x==="reverse"?(H=1-H,y&&(H-=y/c)):x==="mirror"&&(A=l)),C=ur(0,1,H)*c}let L;P?(this.delayState.value=p[0],L=this.delayState):L=A.next(C),a&&!P&&(L.value=a(L.value));let{done:D}=L;!P&&d!==null&&(D=this.playbackSpeed>=0?this.currentTime>=o:this.currentTime<=0);const V=this.holdTime===null&&(this.state==="finished"||this.state==="running"&&D);return V&&_!==_p&&(L.value=Xc(p,this.options,b,this.speed)),S&&S(L.value),V&&this.finish(),L}then(e,n){return this.finished.then(e,n)}get duration(){return yn(this.calculatedDuration)}get iterationDuration(){const{delay:e=0}=this.options||{};return this.duration+yn(e)}get time(){return yn(this.currentTime)}set time(e){e=sn(e),this.currentTime=e,this.startTime===null||this.holdTime!==null||this.playbackSpeed===0?this.holdTime=e:this.driver&&(this.startTime=this.driver.now()-e/this.playbackSpeed),this.driver?this.driver.start(!1):(this.startTime=0,this.state="paused",this.holdTime=e,this.tick(e))}getGeneratorVelocity(){const e=this.currentTime;if(e<=0)return this.options.velocity||0;if(this.generator.velocity)return this.generator.velocity(e);const n=this.generator.next(e).value;return qS(r=>this.generator.next(r).value,e,n)}get speed(){return this.playbackSpeed}set speed(e){const n=this.playbackSpeed!==e;n&&this.driver&&this.updateTime(It.now()),this.playbackSpeed=e,n&&this.driver&&(this.time=yn(this.currentTime))}play(){var o,a;if(this.isStopped)return;const{driver:e=vL,startTime:n}=this.options;this.driver||(this.driver=e(l=>this.tick(l))),(a=(o=this.options).onPlay)==null||a.call(o);const r=this.driver.now();this.state==="finished"?(this.updateFinished(),this.startTime=r):this.holdTime!==null?this.startTime=r-this.holdTime:this.startTime||(this.startTime=n??r),this.state==="finished"&&this.speed<0&&(this.startTime+=this.calculatedDuration),this.holdTime=null,this.state="running",this.driver.start()}pause(){this.state="paused",this.updateTime(It.now()),this.holdTime=this.currentTime}complete(){this.state!=="running"&&this.play(),this.state="finished",this.holdTime=null}finish(){var e,n;this.notifyFinished(),this.teardown(),this.state="finished",(n=(e=this.options).onComplete)==null||n.call(e)}cancel(){var e,n;this.holdTime=null,this.startTime=0,this.tick(0),this.teardown(),(n=(e=this.options).onCancel)==null||n.call(e)}teardown(){this.state="idle",this.stopDriver(),this.startTime=this.holdTime=null}stopDriver(){this.driver&&(this.driver.stop(),this.driver=void 0)}sample(e){return this.startTime=0,this.tick(e,!0)}attachTimeline(e){var n;return this.options.allowFlatten&&(this.options.type="keyframes",this.options.ease="linear",this.initAnimation()),(n=this.driver)==null||n.stop(),e.observe(this)}}function DL(t){for(let e=1;e<t.length;e++)t[e]??(t[e]=t[e-1])}const ti=t=>t*180/Math.PI,Ep=t=>{const e=ti(Math.atan2(t[1],t[0]));return Tp(e)},ML={x:4,y:5,translateX:4,translateY:5,scaleX:0,scaleY:3,scale:t=>(Math.abs(t[0])+Math.abs(t[3]))/2,rotate:Ep,rotateZ:Ep,skewX:t=>ti(Math.atan(t[1])),skewY:t=>ti(Math.atan(t[2])),skew:t=>(Math.abs(t[1])+Math.abs(t[2]))/2},Tp=t=>(t=t%360,t<0&&(t+=360),t),yw=Ep,vw=t=>Math.sqrt(t[0]*t[0]+t[1]*t[1]),ww=t=>Math.sqrt(t[4]*t[4]+t[5]*t[5]),$L={x:12,y:13,z:14,translateX:12,translateY:13,translateZ:14,scaleX:vw,scaleY:ww,scale:t=>(vw(t)+ww(t))/2,rotateX:t=>Tp(ti(Math.atan2(t[6],t[5]))),rotateY:t=>Tp(ti(Math.atan2(-t[2],t[0]))),rotateZ:yw,rotate:yw,skewX:t=>ti(Math.atan(t[4])),skewY:t=>ti(Math.atan(t[1])),skew:t=>(Math.abs(t[1])+Math.abs(t[4]))/2};function kp(t){return t.includes("scale")?1:0}function Cp(t,e){if(!t||t==="none")return kp(e);const n=t.match(/^matrix3d\(([-\d.e\s,]+)\)$/u);let r,o;if(n)r=$L,o=n;else{const c=t.match(/^matrix\(([-\d.e\s,]+)\)$/u);r=ML,o=c}if(!o)return kp(e);const a=r[e],l=o[1].split(",").map(UL);return typeof a=="function"?a(l):l[a]}const FL=(t,e)=>{const{transform:n="none"}=getComputedStyle(t);return Cp(n,e)};function UL(t){return parseFloat(t.trim())}const Mo=["transformPerspective","x","y","z","translateX","translateY","translateZ","scale","scaleX","scaleY","rotate","rotateX","rotateY","rotateZ","skew","skewX","skewY"],$o=new Set(Mo),xw=t=>t===Do||t===ue,VL=new Set(["x","y","z"]),BL=Mo.filter(t=>!VL.has(t));function zL(t){const e=[];return BL.forEach(n=>{const r=t.getValue(n);r!==void 0&&(e.push([n,r.get()]),r.set(n.startsWith("scale")?1:0))}),e}const vs={width:({x:t},{paddingLeft:e="0",paddingRight:n="0",boxSizing:r})=>{const o=t.max-t.min;return r==="border-box"?o:o-parseFloat(e)-parseFloat(n)},height:({y:t},{paddingTop:e="0",paddingBottom:n="0",boxSizing:r})=>{const o=t.max-t.min;return r==="border-box"?o:o-parseFloat(e)-parseFloat(n)},top:(t,{top:e})=>parseFloat(e),left:(t,{left:e})=>parseFloat(e),bottom:({y:t},{top:e})=>parseFloat(e)+(t.max-t.min),right:({x:t},{left:e})=>parseFloat(e)+(t.max-t.min),x:(t,{transform:e})=>Cp(e,"x"),y:(t,{transform:e})=>Cp(e,"y")};vs.translateX=vs.x;vs.translateY=vs.y;const pi=new Set;let Pp=!1,Ap=!1,Rp=!1;function GS(){if(Ap){const t=Array.from(pi).filter(r=>r.needsMeasurement),e=new Set(t.map(r=>r.element)),n=new Map;e.forEach(r=>{const o=zL(r);o.length&&(n.set(r,o),r.render())}),t.forEach(r=>r.measureInitialState()),e.forEach(r=>{r.render();const o=n.get(r);o&&o.forEach(([a,l])=>{var c;(c=r.getValue(a))==null||c.set(l)})}),t.forEach(r=>r.measureEndState()),t.forEach(r=>{r.suspendedScrollY!==void 0&&window.scrollTo(0,r.suspendedScrollY)})}Ap=!1,Pp=!1,pi.forEach(t=>t.complete(Rp)),pi.clear()}function QS(){pi.forEach(t=>{t.readKeyframes(),t.needsMeasurement&&(Ap=!0)})}function WL(){Rp=!0,QS(),GS(),Rp=!1}class Om{constructor(e,n,r,o,a,l=!1){this.state="pending",this.isAsync=!1,this.needsMeasurement=!1,this.unresolvedKeyframes=[...e],this.onComplete=n,this.name=r,this.motionValue=o,this.element=a,this.isAsync=l}scheduleResolve(){this.state="scheduled",this.isAsync?(pi.add(this),Pp||(Pp=!0,Ue.read(QS),Ue.resolveKeyframes(GS))):(this.readKeyframes(),this.complete())}readKeyframes(){const{unresolvedKeyframes:e,name:n,element:r,motionValue:o}=this;if(e[0]===null){const a=o==null?void 0:o.get(),l=e[e.length-1];if(a!==void 0)e[0]=a;else if(r&&n){const c=r.readValue(n,l);c!=null&&(e[0]=c)}e[0]===void 0&&(e[0]=l),o&&a===void 0&&o.set(e[0])}DL(e)}setFinalKeyframe(){}measureInitialState(){}renderEndStyles(){}measureEndState(){}complete(e=!1){this.state="complete",this.onComplete(this.unresolvedKeyframes,this.finalKeyframe,e),pi.delete(this)}cancel(){this.state==="scheduled"&&(pi.delete(this),this.state="pending")}resume(){this.state==="pending"&&this.scheduleResolve()}}const HL=t=>t.startsWith("--");function YS(t,e,n){HL(e)?t.style.setProperty(e,n):t.style[e]=n}const qL={};function JS(t,e){const n=ES(t);return()=>qL[e]??n()}const KL=JS(()=>window.ScrollTimeline!==void 0,"scrollTimeline"),XS=JS(()=>{try{document.createElement("div").animate({opacity:0},{easing:"linear(0, 1)"})}catch{return!1}return!0},"linearEasing"),Oa=([t,e,n,r])=>`cubic-bezier(${t}, ${e}, ${n}, ${r})`,bw={linear:"linear",ease:"ease",easeIn:"ease-in",easeOut:"ease-out",easeInOut:"ease-in-out",circIn:Oa([0,.65,.55,1]),circOut:Oa([.55,0,1,.45]),backIn:Oa([.31,.01,.66,-.59]),backOut:Oa([.33,1.53,.69,.99])};function ZS(t,e){if(t)return typeof t=="function"?XS()?HS(t,e):"ease-out":LS(t)?Oa(t):Array.isArray(t)?t.map(n=>ZS(n,e)||bw.easeOut):bw[t]}function GL(t,e,n,{delay:r=0,duration:o=300,repeat:a=0,repeatType:l="loop",ease:c="easeOut",times:d}={},f=void 0){const p={[e]:n};d&&(p.offset=d);const g=ZS(c,o);Array.isArray(g)&&(p.easing=g);const x={delay:r,duration:o,easing:Array.isArray(g)?"linear":g,fill:"both",iterations:a+1,direction:l==="reverse"?"alternate":"normal"};return f&&(x.pseudoElement=f),t.animate(p,x)}function e_(t){return typeof t=="function"&&"applyToOptions"in t}function QL({type:t,...e}){return e_(t)&&XS()?t.applyToOptions(e):(e.duration??(e.duration=300),e.ease??(e.ease="easeOut"),e)}class t_ extends jm{constructor(e){if(super(),this.finishedTime=null,this.isStopped=!1,this.manualStartTime=null,!e)return;const{element:n,name:r,keyframes:o,pseudoElement:a,allowFlatten:l=!1,finalKeyframe:c,onComplete:d}=e;this.isPseudoElement=!!a,this.allowFlatten=l,this.options=e,Sm(typeof e.type!="string");const f=QL(e);this.animation=GL(n,r,o,f,a),f.autoplay===!1&&this.animation.pause(),this.animation.onfinish=()=>{if(this.finishedTime=this.time,!a){const p=Xc(o,this.options,c,this.speed);this.updateMotionValue&&this.updateMotionValue(p),YS(n,r,p),this.animation.cancel()}d==null||d(),this.notifyFinished()}}play(){this.isStopped||(this.manualStartTime=null,this.animation.play(),this.state==="finished"&&this.updateFinished())}pause(){this.animation.pause()}complete(){var e,n;(n=(e=this.animation).finish)==null||n.call(e)}cancel(){try{this.animation.cancel()}catch{}}stop(){if(this.isStopped)return;this.isStopped=!0;const{state:e}=this;e==="idle"||e==="finished"||(this.updateMotionValue?this.updateMotionValue():this.commitStyles(),this.isPseudoElement||this.cancel())}commitStyles(){var n,r,o;const e=(n=this.options)==null?void 0:n.element;!this.isPseudoElement&&(e!=null&&e.isConnected)&&((o=(r=this.animation).commitStyles)==null||o.call(r))}get duration(){var n,r;const e=((r=(n=this.animation.effect)==null?void 0:n.getComputedTiming)==null?void 0:r.call(n).duration)||0;return yn(Number(e))}get iterationDuration(){const{delay:e=0}=this.options||{};return this.duration+yn(e)}get time(){return yn(Number(this.animation.currentTime)||0)}set time(e){const n=this.finishedTime!==null;this.manualStartTime=null,this.finishedTime=null,this.animation.currentTime=sn(e),n&&this.animation.pause()}get speed(){return this.animation.playbackRate}set speed(e){e<0&&(this.finishedTime=null),this.animation.playbackRate=e}get state(){return this.finishedTime!==null?"finished":this.animation.playState}get startTime(){return this.manualStartTime??Number(this.animation.startTime)}set startTime(e){this.manualStartTime=this.animation.startTime=e}attachTimeline({timeline:e,rangeStart:n,rangeEnd:r,observe:o}){var a;return this.allowFlatten&&((a=this.animation.effect)==null||a.updateTiming({easing:"linear"})),this.animation.onfinish=null,e&&KL()?(this.animation.timeline=e,n&&(this.animation.rangeStart=n),r&&(this.animation.rangeEnd=r),vn):o(this)}}const n_={anticipate:jS,backInOut:RS,circInOut:NS};function YL(t){return t in n_}function JL(t){typeof t.ease=="string"&&YL(t.ease)&&(t.ease=n_[t.ease])}const yf=10;class XL extends t_{constructor(e){JL(e),KS(e),super(e),e.startTime!==void 0&&e.autoplay!==!1&&(this.startTime=e.startTime),this.options=e}updateMotionValue(e){const{motionValue:n,onUpdate:r,onComplete:o,element:a,...l}=this.options;if(!n)return;if(e!==void 0){n.set(e);return}const c=new Tc({...l,autoplay:!1}),d=Math.max(yf,It.now()-this.startTime),f=ur(0,yf,d-yf),p=c.sample(d).value,{name:g}=this.options;a&&g&&YS(a,g,p),n.setWithVelocity(c.sample(Math.max(0,d-f)).value,p,f),c.stop()}}const Sw=(t,e)=>e==="zIndex"?!1:!!(typeof t=="number"||Array.isArray(t)||typeof t=="string"&&(Fn.test(t)||t==="0")&&!t.startsWith("url("));function ZL(t){const e=t[0];if(t.length===1)return!0;for(let n=0;n<t.length;n++)if(t[n]!==e)return!0}function eD(t,e,n,r){const o=t[0];if(o===null)return!1;if(e==="display"||e==="visibility")return!0;const a=t[t.length-1],l=Sw(o,e),c=Sw(a,e);return!l||!c?!1:ZL(t)||(n==="spring"||e_(n))&&r}function jp(t){t.duration=0,t.type="keyframes"}const r_=new Set(["opacity","clipPath","filter","transform"]),tD=/^(?:oklch|oklab|lab|lch|color|color-mix|light-dark)\(/;function nD(t){for(let e=0;e<t.length;e++)if(typeof t[e]=="string"&&tD.test(t[e]))return!0;return!1}const rD=new Set(["color","backgroundColor","outlineColor","fill","stroke","borderColor","borderTopColor","borderRightColor","borderBottomColor","borderLeftColor"]),sD=ES(()=>Object.hasOwnProperty.call(Element.prototype,"animate"));function iD(t){var g;
306const{motionValue:e,name:n,repeatDelay:r,repeatType:o,damping:a,type:l,keyframes:c}=t;if(!(((g=e==null?void 0:e.owner)==null?void 0:g.current)instanceof HTMLElement))return!1;const{onUpdate:f,transformTemplate:p}=e.owner.getProps();return sD()&&n&&(r_.has(n)||rD.has(n)&&nD(c))&&(n!=="transform"||!p)&&!f&&!r&&o!=="mirror"&&a!==0&&l!=="inertia"}const oD=40;class aD extends jm{constructor({autoplay:e=!0,delay:n=0,type:r="keyframes",repeat:o=0,repeatDelay:a=0,repeatType:l="loop",keyframes:c,name:d,motionValue:f,element:p,...g}){var _;super(),this.stop=()=>{var S,b;this._animation&&(this._animation.stop(),(S=this.stopTimeline)==null||S.call(this)),(b=this.keyframeResolver)==null||b.cancel()},this.createdAt=It.now();const x={autoplay:e,delay:n,type:r,repeat:o,repeatDelay:a,repeatType:l,name:d,motionValue:f,element:p,...g},y=(p==null?void 0:p.KeyframeResolver)||Om;this.keyframeResolver=new y(c,(S,b,k)=>this.onKeyframesResolved(S,b,x,!k),d,f,p),(_=this.keyframeResolver)==null||_.scheduleResolve()}onKeyframesResolved(e,n,r,o){var k,P;this.keyframeResolver=void 0;const{name:a,type:l,velocity:c,delay:d,isHandoff:f,onUpdate:p}=r;this.resolvedAt=It.now();let g=!0;eD(e,a,l,c)||(g=!1,(_s.instantAnimations||!d)&&(p==null||p(Xc(e,r,n))),e[0]=e[e.length-1],jp(r),r.repeat=0);const y={startTime:o?this.resolvedAt?this.resolvedAt-this.createdAt>oD?this.resolvedAt:this.createdAt:this.createdAt:void 0,finalKeyframe:n,...r,keyframes:e},_=g&&!f&&iD(y),S=(P=(k=y.motionValue)==null?void 0:k.owner)==null?void 0:P.current;let b;if(_)try{b=new XL({...y,element:S})}catch{b=new Tc(y)}else b=new Tc(y);b.finished.then(()=>{this.notifyFinished()}).catch(vn),this.pendingTimeline&&(this.stopTimeline=b.attachTimeline(this.pendingTimeline),this.pendingTimeline=void 0),this._animation=b}get finished(){return this._animation?this.animation.finished:this._finished}then(e,n){return this.finished.finally(e).then(()=>{})}get animation(){var e;return this._animation||((e=this.keyframeResolver)==null||e.resume(),WL()),this._animation}get duration(){return this.animation.duration}get iterationDuration(){return this.animation.iterationDuration}get time(){return this.animation.time}set time(e){this.animation.time=e}get speed(){return this.animation.speed}get state(){return this.animation.state}set speed(e){this.animation.speed=e}get startTime(){return this.animation.startTime}attachTimeline(e){return this._animation?this.stopTimeline=this.animation.attachTimeline(e):this.pendingTimeline=e,()=>this.stop()}play(){this.animation.play()}pause(){this.animation.pause()}complete(){this.animation.complete()}cancel(){var e;this._animation&&this.animation.cancel(),(e=this.keyframeResolver)==null||e.cancel()}}function s_(t,e,n,r=0,o=1){const a=Array.from(t).sort((f,p)=>f.sortNodePosition(p)).indexOf(e),l=t.size,c=(l-1)*r;return typeof n=="function"?n(a,l):o===1?a*r:c-a*r}const lD=/^var\(--(?:([\w-]+)|([\w-]+), ?([a-zA-Z\d ()%#.,-]+))\)/u;function uD(t){const e=lD.exec(t);if(!e)return[,];const[,n,r,o]=e;return[`--${n??r}`,o]}function i_(t,e,n=1){const[r,o]=uD(t);if(!r)return;const a=window.getComputedStyle(e).getPropertyValue(r);if(a){const l=a.trim();return bS(l)?parseFloat(l):l}return km(o)?i_(o,e,n+1):o}const cD={type:"spring",stiffness:500,damping:25,restSpeed:10},dD=t=>({type:"spring",stiffness:550,damping:t===0?2*Math.sqrt(550):30,restSpeed:10}),hD={type:"keyframes",duration:.8},fD={type:"keyframes",ease:[.25,.1,.35,1],duration:.3},pD=(t,{keyframes:e})=>e.length>2?hD:$o.has(t)?t.startsWith("scale")?dD(e[1]):cD:fD;function o_(t,e){if(t!=null&&t.inherit&&e){const{inherit:n,...r}=t;return{...e,...r}}return t}function Nm(t,e){const n=(t==null?void 0:t[e])??(t==null?void 0:t.default)??t;return n!==t?o_(n,t):n}const mD=new Set(["when","delay","delayChildren","staggerChildren","staggerDirection","repeat","repeatType","repeatDelay","from","elapsed"]);function gD(t){for(const e in t)if(!mD.has(e))return!0;return!1}const Im=(t,e,n,r={},o,a)=>l=>{const c=Nm(r,t)||{},d=c.delay||r.delay||0;let{elapsed:f=0}=r;f=f-sn(d);const p={keyframes:Array.isArray(n)?n:[null,n],ease:"easeOut",velocity:e.getVelocity(),...c,delay:-f,onUpdate:x=>{e.set(x),c.onUpdate&&c.onUpdate(x)},onComplete:()=>{l(),c.onComplete&&c.onComplete()},name:t,motionValue:e,element:a?void 0:o};gD(c)||Object.assign(p,pD(t,p)),p.duration&&(p.duration=sn(p.duration)),p.repeatDelay&&(p.repeatDelay=sn(p.repeatDelay)),p.from!==void 0&&(p.keyframes[0]=p.from);let g=!1;if((p.type===!1||p.duration===0&&!p.repeatDelay)&&(jp(p),p.delay===0&&(g=!0)),(_s.instantAnimations||_s.skipAnimations||o!=null&&o.shouldSkipAnimations)&&(g=!0,jp(p),p.delay=0),p.allowFlatten=!c.type&&!c.ease,g&&!a&&e.get()!==void 0){const x=Xc(p.keyframes,c);if(x!==void 0){Ue.update(()=>{p.onUpdate(x),p.onComplete()});return}}return c.isSync?new Tc(p):new aD(p)};function _w(t){const e=[{},{}];
vendor: 8,048 bytes, line 306
306return t==null||t.values.forEach((n,r)=>{e[0][r]=n.get(),e[1][r]=n.getVelocity()}),e}function Lm(t,e,n,r){if(typeof e=="function"){const[o,a]=_w(r);e=e(n!==void 0?n:t.custom,o,a)}if(typeof e=="string"&&(e=t.variants&&t.variants[e]),typeof e=="function"){const[o,a]=_w(r);e=e(n!==void 0?n:t.custom,o,a)}return e}function mi(t,e,n){const r=t.getProps();return Lm(r,e,n!==void 0?n:r.custom,t)}const a_=new Set(["width","height","top","left","right","bottom",...Mo]),Ew=30,yD=t=>!isNaN(parseFloat(t));class vD{constructor(e,n={}){this.canTrackVelocity=null,this.events={},this.updateAndNotify=r=>{var a;const o=It.now();if(this.updatedAt!==o&&this.setPrevFrameValue(),this.prev=this.current,this.setCurrent(r),this.current!==this.prev&&((a=this.events.change)==null||a.notify(this.current),this.dependents))for(const l of this.dependents)l.dirty()},this.hasAnimated=!1,this.setCurrent(e),this.owner=n.owner}setCurrent(e){this.current=e,this.updatedAt=It.now(),this.canTrackVelocity===null&&e!==void 0&&(this.canTrackVelocity=yD(this.current))}setPrevFrameValue(e=this.current){this.prevFrameValue=e,this.prevUpdatedAt=this.updatedAt}onChange(e){return this.on("change",e)}on(e,n){this.events[e]||(this.events[e]=new _m);const r=this.events[e].add(n);return e==="change"?()=>{r(),Ue.read(()=>{this.events.change.getSize()||this.stop()})}:r}clearListeners(){for(const e in this.events)this.events[e].clear()}attach(e,n){this.passiveEffect=e,this.stopPassiveEffect=n}set(e){this.passiveEffect?this.passiveEffect(e,this.updateAndNotify):this.updateAndNotify(e)}setWithVelocity(e,n,r){this.set(n),this.prev=void 0,this.prevFrameValue=e,this.prevUpdatedAt=this.updatedAt-r}jump(e,n=!0){this.updateAndNotify(e),this.prev=e,this.prevUpdatedAt=this.prevFrameValue=void 0,n&&this.stop(),this.stopPassiveEffect&&this.stopPassiveEffect()}dirty(){var e;(e=this.events.change)==null||e.notify(this.current)}addDependent(e){this.dependents||(this.dependents=new Set),this.dependents.add(e)}removeDependent(e){this.dependents&&this.dependents.delete(e)}get(){return this.current}getPrevious(){return this.prev}getVelocity(){const e=It.now();if(!this.canTrackVelocity||this.prevFrameValue===void 0||e-this.updatedAt>Ew)return 0;const n=Math.min(this.updatedAt-this.prevUpdatedAt,Ew);return TS(parseFloat(this.current)-parseFloat(this.prevFrameValue),n)}start(e){return this.stop(),new Promise(n=>{this.hasAnimated=!0,this.animation=e(n),this.events.animationStart&&this.events.animationStart.notify()}).then(()=>{this.events.animationComplete&&this.events.animationComplete.notify(),this.clearAnimation()})}stop(){this.animation&&(this.animation.stop(),this.events.animationCancel&&this.events.animationCancel.notify()),this.clearAnimation()}isAnimating(){return!!this.animation}clearAnimation(){delete this.animation}destroy(){var e,n;(e=this.dependents)==null||e.clear(),(n=this.events.destroy)==null||n.notify(),this.clearListeners(),this.stop(),this.stopPassiveEffect&&this.stopPassiveEffect()}}function Ao(t,e){return new vD(t,e)}const Op=t=>Array.isArray(t);function wD(t,e,n){t.hasValue(e)?t.getValue(e).set(n):t.addValue(e,Ao(n))}function xD(t){return Op(t)?t[t.length-1]||0:t}function bD(t,e){const n=mi(t,e);let{transitionEnd:r={},transition:o={},...a}=n||{};a={...a,...r};for(const l in a){const c=xD(a[l]);wD(t,l,c)}}const _t=t=>!!(t&&t.getVelocity);function SD(t){return!!(_t(t)&&t.add)}function Np(t,e){const n=t.getValue("willChange");if(SD(n))return n.add(e);if(!n&&_s.WillChange){const r=new _s.WillChange("auto");t.addValue("willChange",r),r.add(e)}}function Dm(t){return t.replace(/([A-Z])/g,e=>`-${e.toLowerCase()}`)}const _D="framerAppearId",l_="data-"+Dm(_D);function u_(t){return t.props[l_]}function ED({protectedKeys:t,needsAnimating:e},n){const r=t.hasOwnProperty(n)&&e[n]!==!0;return e[n]=!1,r}function c_(t,e,{delay:n=0,transitionOverride:r,type:o}={}){let{transition:a,transitionEnd:l,...c}=e;const d=t.getDefaultTransition();a=a?o_(a,d):d;const f=a==null?void 0:a.reduceMotion;r&&(a=r);const p=[],g=o&&t.animationState&&t.animationState.getState()[o];for(const x in c){const y=t.getValue(x,t.latestValues[x]??null),_=c[x];if(_===void 0||g&&ED(g,x))continue;const S={delay:n,...Nm(a||{},x)},b=y.get();if(b!==void 0&&!y.isAnimating()&&!Array.isArray(_)&&_===b&&!S.velocity){Ue.update(()=>y.set(_));continue}let k=!1;if(window.MotionHandoffAnimation){const A=u_(t);if(A){const L=window.MotionHandoffAnimation(A,x,Ue);L!==null&&(S.startTime=L,k=!0)}}Np(t,x);const P=f??t.shouldReduceMotion;y.start(Im(x,y,_,P&&a_.has(x)?{type:!1}:S,t,k));const C=y.animation;C&&p.push(C)}if(l){const x=()=>Ue.update(()=>{l&&bD(t,l)});p.length?Promise.all(p).then(x):x()}return p}function Ip(t,e,n={}){var d;const r=mi(t,e,n.type==="exit"?(d=t.presenceContext)==null?void 0:d.custom:void 0);let{transition:o=t.getDefaultTransition()||{}}=r||{};n.transitionOverride&&(o=n.transitionOverride);const a=r?()=>Promise.all(c_(t,r,n)):()=>Promise.resolve(),l=t.variantChildren&&t.variantChildren.size?(f=0)=>{const{delayChildren:p=0,staggerChildren:g,staggerDirection:x}=o;return TD(t,e,f,p,g,x,n)}:()=>Promise.resolve(),{when:c}=o;if(c){const[f,p]=c==="beforeChildren"?[a,l]:[l,a];return f().then(()=>p())}else return Promise.all([a(),l(n.delay)])}function TD(t,e,n=0,r=0,o=0,a=1,l){const c=[];for(const d of t.variantChildren)d.notify("AnimationStart",e),c.push(Ip(d,e,{...l,delay:n+(typeof r=="function"?0:r)+s_(t.variantChildren,d,r,o,a)}).then(()=>d.notify("AnimationComplete",e)));return Promise.all(c)}function kD(t,e,n={}){t.notify("AnimationStart",e);let r;if(Array.isArray(e)){const o=e.map(a=>Ip(t,a,n));r=Promise.all(o)}else if(typeof e=="string")r=Ip(t,e,n);else{const o=typeof e=="function"?mi(t,e,n.custom):e;r=Promise.all(c_(t,o,n))}return r.then(()=>{t.notify("AnimationComplete",e)})}const CD={test:t=>t==="auto",parse:t=>t},d_=t=>e=>e.test(t),h_=[Do,ue,lr,is,ZI,XI,CD],Tw=t=>h_.find(d_(t));function PD(t){return typeof t=="number"?t===0:t!==null?t==="none"||t==="0"||_S(t):!0}const AD=new Set(["brightness","contrast","saturate","opacity"]);function RD(t){const[e,n]=t.slice(0,-1).split("(");if(e==="drop-shadow")return t;const[r]=n.match(Cm)||[];if(!r)return t;const o=n.replace(r,"");let a=AD.has(e)?1:0;return r!==n&&(a*=100),e+"("+a+o+")"}const jD=/\b([a-z-]*)\(.*?\)/gu,Lp={...Fn,getAnimatableNone:t=>{const e=t.match(jD);return e?e.map(RD).join(" "):t}},Dp={...Fn,getAnimatableNone:t=>{const e=Fn.parse(t);return Fn.createTransformer(t)(e.map(r=>typeof r=="number"?0:typeof r=="object"?{...r,alpha:1}:r))}},kw={...Do,transform:Math.round},OD={rotate:is,rotateX:is,rotateY:is,rotateZ:is,scale:Yu,scaleX:Yu,scaleY:Yu,scaleZ:Yu,skew:is,skewX:is,skewY:is,distance:ue,translateX:ue,translateY:ue,translateZ:ue,x:ue,y:ue,z:ue,perspective:ue,transformPerspective:ue,opacity:tl,originX:hw,originY:hw,originZ:ue},Mm={borderWidth:ue,borderTopWidth:ue,borderRightWidth:ue,borderBottomWidth:ue,borderLeftWidth:ue,borderRadius:ue,borderTopLeftRadius:ue,borderTopRightRadius:ue,borderBottomRightRadius:ue,borderBottomLeftRadius:ue,width:ue,maxWidth:ue,height:ue,maxHeight:ue,top:ue,right:ue,bottom:ue,left:ue,inset:ue,insetBlock:ue,insetBlockStart:ue,insetBlockEnd:ue,insetInline:ue,insetInlineStart:ue,insetInlineEnd:ue,padding:ue,paddingTop:ue,paddingRight:ue,paddingBottom:ue,paddingLeft:ue,paddingBlock:ue,paddingBlockStart:ue,paddingBlockEnd:ue,paddingInline:ue,paddingInlineStart:ue,paddingInlineEnd:ue,margin:ue,marginTop:ue,marginRight:ue,marginBottom:ue,marginLeft:ue,marginBlock:ue,marginBlockStart:ue,marginBlockEnd:ue,marginInline:ue,marginInlineStart:ue,marginInlineEnd:ue,fontSize:ue,backgroundPositionX:ue,backgroundPositionY:ue,...OD,zIndex:kw,fillOpacity:tl,strokeOpacity:tl,numOctaves:kw},ND={...Mm,color:it,backgroundColor:it,outlineColor:it,fill:it,stroke:it,borderColor:it,borderTopColor:it,borderRightColor:it,borderBottomColor:it,borderLeftColor:it,filter:Lp,WebkitFilter:Lp,mask:Dp,WebkitMask:Dp},f_=t=>ND[t],ID=new Set([Lp,Dp]);function p_(t,e){let n=f_(t);return ID.has(n)||(n=Fn),n.getAnimatableNone?n.getAnimatableNone(e):void 0}
vendor: 1,717 bytes, line 306
306const LD=new Set(["auto","none","0"]);function DD(t,e,n){let r=0,o;for(;r<t.length&&!o;){const a=t[r];typeof a=="string"&&!LD.has(a)&&Po(a).values.length&&(o=t[r]),r++}if(o&&n)for(const a of e)t[a]=p_(n,o)}class MD extends Om{constructor(e,n,r,o,a){super(e,n,r,o,a,!0)}readKeyframes(){const{unresolvedKeyframes:e,element:n,name:r}=this;if(!n||!n.current)return;super.readKeyframes();for(let p=0;p<e.length;p++){let g=e[p];if(typeof g=="string"&&(g=g.trim(),km(g))){const x=i_(g,n.current);x!==void 0&&(e[p]=x),p===e.length-1&&(this.finalKeyframe=g)}}if(this.resolveNoneKeyframes(),!a_.has(r)||e.length!==2)return;const[o,a]=e,l=Tw(o),c=Tw(a),d=dw(o),f=dw(a);if(d!==f&&vs[r]){this.needsMeasurement=!0;return}if(l!==c)if(xw(l)&&xw(c))for(let p=0;p<e.length;p++){const g=e[p];typeof g=="string"&&(e[p]=parseFloat(g))}else vs[r]&&(this.needsMeasurement=!0)}resolveNoneKeyframes(){const{unresolvedKeyframes:e,name:n}=this,r=[];for(let o=0;o<e.length;o++)(e[o]===null||PD(e[o]))&&r.push(o);r.length&&DD(e,r,n)}measureInitialState(){const{element:e,unresolvedKeyframes:n,name:r}=this;if(!e||!e.current)return;r==="height"&&(this.suspendedScrollY=window.pageYOffset),this.measuredOrigin=vs[r](e.measureViewportBox(),window.getComputedStyle(e.current)),n[0]=this.measuredOrigin;const o=n[n.length-1];o!==void 0&&e.getValue(r,o).jump(o,!1)}measureEndState(){var c;const{element:e,name:n,unresolvedKeyframes:r}=this;if(!e||!e.current)return;const o=e.getValue(n);o&&o.jump(this.measuredOrigin,!1);const a=r.length-1,l=r[a];r[a]=vs[n](e.measureViewportBox(),window.getComputedStyle(e.current)),l!==null&&this.finalKeyframe===void 0&&(this.finalKeyframe=l),(c=this.removedTransforms)!=null&&c.length&&this.removedTransforms.forEac
vendor: 40,884 bytes, line 306
306h(([d,f])=>{e.getValue(d).set(f)}),this.resolveNoneKeyframes()}}function m_(t,e,n){if(t==null)return[];if(t instanceof EventTarget)return[t];if(typeof t=="string"){let r=document;const o=(n==null?void 0:n[t])??r.querySelectorAll(t);return o?Array.from(o):[]}return Array.from(t).filter(r=>r!=null)}const g_=(t,e)=>e&&typeof t=="number"?e.transform(t):t;function oc(t){return SS(t)&&"offsetHeight"in t&&!("ownerSVGElement"in t)}const{schedule:$m}=DS(queueMicrotask,!1),jn={x:!1,y:!1};function y_(){return jn.x||jn.y}function $D(t){return t==="x"||t==="y"?jn[t]?null:(jn[t]=!0,()=>{jn[t]=!1}):jn.x||jn.y?null:(jn.x=jn.y=!0,()=>{jn.x=jn.y=!1})}function v_(t,e){const n=m_(t),r=new AbortController,o={passive:!0,...e,signal:r.signal};return[n,o,()=>r.abort()]}function FD(t){return!(t.pointerType==="touch"||y_())}function UD(t,e,n={}){const[r,o,a]=v_(t,n);return r.forEach(l=>{let c=!1,d=!1,f;const p=()=>{l.removeEventListener("pointerleave",_)},g=b=>{f&&(f(b),f=void 0),p()},x=b=>{c=!1,window.removeEventListener("pointerup",x),window.removeEventListener("pointercancel",x),d&&(d=!1,g(b))},y=()=>{c=!0,window.addEventListener("pointerup",x,o),window.addEventListener("pointercancel",x,o)},_=b=>{if(b.pointerType!=="touch"){if(c){d=!0;return}g(b)}},S=b=>{if(!FD(b))return;d=!1;const k=e(l,b);typeof k=="function"&&(f=k,l.addEventListener("pointerleave",_,o))};l.addEventListener("pointerenter",S,o),l.addEventListener("pointerdown",y,o)}),a}const w_=(t,e)=>e?t===e?!0:w_(t,e.parentElement):!1,Fm=t=>t.pointerType==="mouse"?typeof t.button!="number"||t.button<=0:t.isPrimary!==!1,VD=new Set(["BUTTON","INPUT","SELECT","TEXTAREA","A"]);function BD(t){return VD.has(t.tagName)||t.isContentEditable===!0}const zD=new Set(["INPUT","SELECT","TEXTAREA"]);function WD(t){return zD.has(t.tagName)||t.isContentEditable===!0}const ac=new WeakSet;function Cw(t){return e=>{e.key==="Enter"&&t(e)}}function vf(t,e){t.dispatchEvent(new PointerEvent("pointer"+e,{isPrimary:!0,bubbles:!0}))}const HD=(t,e)=>{const n=t.currentTarget;if(!n)return;const r=Cw(()=>{if(ac.has(n))return;vf(n,"down");const o=Cw(()=>{vf(n,"up")}),a=()=>vf(n,"cancel");n.addEventListener("keyup",o,e),n.addEventListener("blur",a,e)});n.addEventListener("keydown",r,e),n.addEventListener("blur",()=>n.removeEventListener("keydown",r),e)};function Pw(t){return Fm(t)&&!y_()}const Aw=new WeakSet;function qD(t,e,n={}){const[r,o,a]=v_(t,n),l=c=>{const d=c.currentTarget;if(!Pw(c)||Aw.has(c))return;ac.add(d),n.stopPropagation&&Aw.add(c);const f=e(d,c),p=(y,_)=>{window.removeEventListener("pointerup",g),window.removeEventListener("pointercancel",x),ac.has(d)&&ac.delete(d),Pw(y)&&typeof f=="function"&&f(y,{success:_})},g=y=>{p(y,d===window||d===document||n.useGlobalTarget||w_(d,y.target))},x=y=>{p(y,!1)};window.addEventListener("pointerup",g,o),window.addEventListener("pointercancel",x,o)};return r.forEach(c=>{(n.useGlobalTarget?window:c).addEventListener("pointerdown",l,o),oc(c)&&(c.addEventListener("focus",f=>HD(f,o)),!BD(c)&&!c.hasAttribute("tabindex")&&(c.tabIndex=0))}),a}function Um(t){return SS(t)&&"ownerSVGElement"in t}const lc=new WeakMap;let os;const x_=(t,e,n)=>(r,o)=>o&&o[0]?o[0][t+"Size"]:Um(r)&&"getBBox"in r?r.getBBox()[e]:r[n],KD=x_("inline","width","offsetWidth"),GD=x_("block","height","offsetHeight");function QD({target:t,borderBoxSize:e}){var n;(n=lc.get(t))==null||n.forEach(r=>{r(t,{get width(){return KD(t,e)},get height(){return GD(t,e)}})})}function YD(t){t.forEach(QD)}function JD(){typeof ResizeObserver>"u"||(os=new ResizeObserver(YD))}function XD(t,e){os||JD();const n=m_(t);return n.forEach(r=>{let o=lc.get(r);o||(o=new Set,lc.set(r,o)),o.add(e),os==null||os.observe(r)}),()=>{n.forEach(r=>{const o=lc.get(r);o==null||o.delete(e),o!=null&&o.size||os==null||os.unobserve(r)})}}const uc=new Set;let oo;function ZD(){oo=()=>{const t={get width(){return window.innerWidth},get height(){return window.innerHeight}};uc.forEach(e=>e(t))},window.addEventListener("resize",oo)}function eM(t){return uc.add(t),oo||ZD(),()=>{uc.delete(t),!uc.size&&typeof oo=="function"&&(window.removeEventListener("resize",oo),oo=void 0)}}function Rw(t,e){return typeof t=="function"?eM(t):XD(t,e)}function tM(t){return Um(t)&&t.tagName==="svg"}const nM=[...h_,it,Fn],rM=t=>nM.find(d_(t)),jw=()=>({translate:0,scale:1,origin:0,originPoint:0}),ao=()=>({x:jw(),y:jw()}),Ow=()=>({min:0,max:0}),ct=()=>({x:Ow(),y:Ow()}),sM=new WeakMap;function Zc(t){return t!==null&&typeof t=="object"&&typeof t.start=="function"}function nl(t){return typeof t=="string"||Array.isArray(t)}const Vm=["animate","whileInView","whileFocus","whileHover","whileTap","whileDrag","exit"],Bm=["initial",...Vm];function ed(t){return Zc(t.animate)||Bm.some(e=>nl(t[e]))}function b_(t){return!!(ed(t)||t.variants)}function iM(t,e,n){for(const r in e){const o=e[r],a=n[r];if(_t(o))t.addValue(r,o);else if(_t(a))t.addValue(r,Ao(o,{owner:t}));else if(a!==o)if(t.hasValue(r)){const l=t.getValue(r);l.liveStyle===!0?l.jump(o):l.hasAnimated||l.set(o)}else{const l=t.getStaticValue(r);t.addValue(r,Ao(l!==void 0?l:o,{owner:t}))}}for(const r in n)e[r]===void 0&&t.removeValue(r);return e}const Mp={current:null},S_={current:!1},oM=typeof window<"u";function aM(){if(S_.current=!0,!!oM)if(window.matchMedia){const t=window.matchMedia("(prefers-reduced-motion)"),e=()=>Mp.current=t.matches;t.addEventListener("change",e),e()}else Mp.current=!1}const Nw=["AnimationStart","AnimationComplete","Update","BeforeLayoutMeasure","LayoutMeasure","LayoutAnimationStart","LayoutAnimationComplete"];let kc={};function __(t){kc=t}function lM(){return kc}class uM{scrapeMotionValuesFromProps(e,n,r){return{}}constructor({parent:e,props:n,presenceContext:r,reducedMotionConfig:o,skipAnimations:a,blockInitialAnimation:l,visualState:c},d={}){this.current=null,this.children=new Set,this.isVariantNode=!1,this.isControllingVariants=!1,this.shouldReduceMotion=null,this.shouldSkipAnimations=!1,this.values=new Map,this.KeyframeResolver=Om,this.features={},this.valueSubscriptions=new Map,this.prevMotionValues={},this.hasBeenMounted=!1,this.events={},this.propEventSubscriptions={},this.notifyUpdate=()=>this.notify("Update",this.latestValues),this.render=()=>{this.current&&(this.triggerBuild(),this.renderInstance(this.current,this.renderState,this.props.style,this.projection))},this.renderScheduledAt=0,this.scheduleRender=()=>{const y=It.now();this.renderScheduledAt<y&&(this.renderScheduledAt=y,Ue.render(this.render,!1,!0))};const{latestValues:f,renderState:p}=c;this.latestValues=f,this.baseTarget={...f},this.initialValues=n.initial?{...f}:{},this.renderState=p,this.parent=e,this.props=n,this.presenceContext=r,this.depth=e?e.depth+1:0,this.reducedMotionConfig=o,this.skipAnimationsConfig=a,this.options=d,this.blockInitialAnimation=!!l,this.isControllingVariants=ed(n),this.isVariantNode=b_(n),this.isVariantNode&&(this.variantChildren=new Set),this.manuallyAnimateOnMount=!!(e&&e.current);const{willChange:g,...x}=this.scrapeMotionValuesFromProps(n,{},this);for(const y in x){const _=x[y];f[y]!==void 0&&_t(_)&&_.set(f[y])}}mount(e){var n,r;if(this.hasBeenMounted)for(const o in this.initialValues)(n=this.values.get(o))==null||n.jump(this.initialValues[o]),this.latestValues[o]=this.initialValues[o];this.current=e,sM.set(e,this),this.projection&&!this.projection.instance&&this.projection.mount(e),this.parent&&this.isVariantNode&&!this.isControllingVariants&&(this.removeFromVariantTree=this.parent.addVariantChild(this)),this.values.forEach((o,a)=>this.bindToMotionValue(a,o)),this.reducedMotionConfig==="never"?this.shouldReduceMotion=!1:this.reducedMotionConfig==="always"?this.shouldReduceMotion=!0:(S_.current||aM(),this.shouldReduceMotion=Mp.current),this.shouldSkipAnimations=this.skipAnimationsConfig??!1,(r=this.parent)==null||r.addChild(this),this.update(this.props,this.presenceContext),this.hasBeenMounted=!0}unmount(){var e;this.projection&&this.projection.unmount(),Es(this.notifyUpdate),Es(this.render),this.valueSubscriptions.forEach(n=>n()),this.valueSubscriptions.clear(),this.removeFromVariantTree&&this.removeFromVariantTree(),(e=this.parent)==null||e.removeChild(this);for(const n in this.events)this.events[n].clear();for(const n in this.features){const r=this.features[n];r&&(r.unmount(),r.isMounted=!1)}this.current=null}addChild(e){this.children.add(e),this.enteringChildren??(this.enteringChildren=new Set),this.enteringChildren.add(e)}removeChild(e){this.children.delete(e),this.enteringChildren&&this.enteringChildren.delete(e)}bindToMotionValue(e,n){if(this.valueSubscriptions.has(e)&&this.valueSubscriptions.get(e)(),n.accelerate&&r_.has(e)&&this.current instanceof HTMLElement){const{factory:l,keyframes:c,times:d,ease:f,duration:p}=n.accelerate,g=new t_({element:this.current,name:e,keyframes:c,times:d,ease:f,duration:sn(p)}),x=l(g);this.valueSubscriptions.set(e,()=>{x(),g.cancel()});return}const r=$o.has(e);r&&this.onBindTransform&&this.onBindTransform();const o=n.on("change",l=>{this.latestValues[e]=l,this.props.onUpdate&&Ue.preRender(this.notifyUpdate),r&&this.projection&&(this.projection.isTransformDirty=!0),this.scheduleRender()});let a;typeof window<"u"&&window.MotionCheckAppearSync&&(a=window.MotionCheckAppearSync(this,e,n)),this.valueSubscriptions.set(e,()=>{o(),a&&a(),n.owner&&n.stop()})}sortNodePosition(e){return!this.current||!this.sortInstanceNodePosition||this.type!==e.type?0:this.sortInstanceNodePosition(this.current,e.current)}updateFeatures(){let e="animation";for(e in kc){const n=kc[e];if(!n)continue;const{isEnabled:r,Feature:o}=n;if(!this.features[e]&&o&&r(this.props)&&(this.features[e]=new o(this)),this.features[e]){const a=this.features[e];a.isMounted?a.update():(a.mount(),a.isMounted=!0)}}}triggerBuild(){this.build(this.renderState,this.latestValues,this.props)}measureViewportBox(){return this.current?this.measureInstanceViewportBox(this.current,this.props):ct()}getStaticValue(e){return this.latestValues[e]}setStaticValue(e,n){this.latestValues[e]=n}update(e,n){(e.transformTemplate||this.props.transformTemplate)&&this.scheduleRender(),this.prevProps=this.props,this.props=e,this.prevPresenceContext=this.presenceContext,this.presenceContext=n;for(let r=0;r<Nw.length;r++){const o=Nw[r];this.propEventSubscriptions[o]&&(this.propEventSubscriptions[o](),delete this.propEventSubscriptions[o]);const a="on"+o,l=e[a];l&&(this.propEventSubscriptions[o]=this.on(o,l))}this.prevMotionValues=iM(this,this.scrapeMotionValuesFromProps(e,this.prevProps||{},this),this.prevMotionValues),this.handleChildMotionValue&&this.handleChildMotionValue()}getProps(){return this.props}getVariant(e){return this.props.variants?this.props.variants[e]:void 0}getDefaultTransition(){return this.props.transition}getTransformPagePoint(){return this.props.transformPagePoint}getClosestVariantNode(){return this.isVariantNode?this:this.parent?this.parent.getClosestVariantNode():void 0}addVariantChild(e){const n=this.getClosestVariantNode();if(n)return n.variantChildren&&n.variantChildren.add(e),()=>n.variantChildren.delete(e)}addValue(e,n){const r=this.values.get(e);n!==r&&(r&&this.removeValue(e),this.bindToMotionValue(e,n),this.values.set(e,n),this.latestValues[e]=n.get())}removeValue(e){this.values.delete(e);const n=this.valueSubscriptions.get(e);n&&(n(),this.valueSubscriptions.delete(e)),delete this.latestValues[e],this.removeValueFromRenderState(e,this.renderState)}hasValue(e){return this.values.has(e)}getValue(e,n){if(this.props.values&&this.props.values[e])return this.props.values[e];let r=this.values.get(e);return r===void 0&&n!==void 0&&(r=Ao(n===null?void 0:n,{owner:this}),this.addValue(e,r)),r}readValue(e,n){let r=this.latestValues[e]!==void 0||!this.current?this.latestValues[e]:this.getBaseTargetFromProps(this.props,e)??this.readValueFromInstance(this.current,e,this.options);return r!=null&&(typeof r=="string"&&(bS(r)||_S(r))?r=parseFloat(r):!rM(r)&&Fn.test(n)&&(r=p_(e,n)),this.setBaseTarget(e,_t(r)?r.get():r)),_t(r)?r.get():r}setBaseTarget(e,n){this.baseTarget[e]=n}getBaseTarget(e){var a;const{initial:n}=this.props;let r;if(typeof n=="string"||typeof n=="object"){const l=Lm(this.props,n,(a=this.presenceContext)==null?void 0:a.custom);l&&(r=l[e])}if(n&&r!==void 0)return r;const o=this.getBaseTargetFromProps(this.props,e);return o!==void 0&&!_t(o)?o:this.initialValues[e]!==void 0&&r===void 0?void 0:this.baseTarget[e]}on(e,n){return this.events[e]||(this.events[e]=new _m),this.events[e].add(n)}notify(e,...n){this.events[e]&&this.events[e].notify(...n)}scheduleRenderMicrotask(){$m.render(this.render)}}class E_ extends uM{constructor(){super(...arguments),this.KeyframeResolver=MD}sortInstanceNodePosition(e,n){return e.compareDocumentPosition(n)&2?1:-1}getBaseTargetFromProps(e,n){const r=e.style;return r?r[n]:void 0}removeValueFromRenderState(e,{vars:n,style:r}){delete n[e],delete r[e]}handleChildMotionValue(){this.childSubscription&&(this.childSubscription(),delete this.childSubscription);const{children:e}=this.props;_t(e)&&(this.childSubscription=e.on("change",n=>{this.current&&(this.current.textContent=`${n}`)}))}}class ks{constructor(e){this.isMounted=!1,this.node=e}update(){}}function T_({top:t,left:e,right:n,bottom:r}){return{x:{min:e,max:n},y:{min:t,max:r}}}function cM({x:t,y:e}){return{top:e.min,right:t.max,bottom:e.max,left:t.min}}function dM(t,e){if(!e)return t;const n=e({x:t.left,y:t.top}),r=e({x:t.right,y:t.bottom});return{top:n.y,left:n.x,bottom:r.y,right:r.x}}function wf(t){return t===void 0||t===1}function $p({scale:t,scaleX:e,scaleY:n}){return!wf(t)||!wf(e)||!wf(n)}function Qs(t){return $p(t)||k_(t)||t.z||t.rotate||t.rotateX||t.rotateY||t.skewX||t.skewY}function k_(t){return Iw(t.x)||Iw(t.y)}function Iw(t){return t&&t!=="0%"}function Cc(t,e,n){const r=t-n,o=e*r;return n+o}function Lw(t,e,n,r,o){return o!==void 0&&(t=Cc(t,o,r)),Cc(t,n,r)+e}function Fp(t,e=0,n=1,r,o){t.min=Lw(t.min,e,n,r,o),t.max=Lw(t.max,e,n,r,o)}function C_(t,{x:e,y:n}){Fp(t.x,e.translate,e.scale,e.originPoint),Fp(t.y,n.translate,n.scale,n.originPoint)}const Dw=.999999999999,Mw=1.0000000000001;function hM(t,e,n,r=!1){var c;const o=n.length;if(!o)return;e.x=e.y=1;let a,l;for(let d=0;d<o;d++){a=n[d],l=a.projectionDelta;const{visualElement:f}=a.options;f&&f.props.style&&f.props.style.display==="contents"||(r&&a.options.layoutScroll&&a.scroll&&a!==a.root&&(ir(t.x,-a.scroll.offset.x),ir(t.y,-a.scroll.offset.y)),l&&(e.x*=l.x.scale,e.y*=l.y.scale,C_(t,l)),r&&Qs(a.latestValues)&&cc(t,a.latestValues,(c=a.layout)==null?void 0:c.layoutBox))}e.x<Mw&&e.x>Dw&&(e.x=1),e.y<Mw&&e.y>Dw&&(e.y=1)}function ir(t,e){t.min+=e,t.max+=e}function $w(t,e,n,r,o=.5){const a=qe(t.min,t.max,o);Fp(t,e,n,a,r)}function Fw(t,e){return typeof t=="string"?parseFloat(t)/100*(e.max-e.min):t}function cc(t,e,n){const r=n??t;$w(t.x,Fw(e.x,r.x),e.scaleX,e.scale,e.originX),$w(t.y,Fw(e.y,r.y),e.scaleY,e.scale,e.originY)}function P_(t,e){return T_(dM(t.getBoundingClientRect(),e))}function fM(t,e,n){const r=P_(t,n),{scroll:o}=e;return o&&(ir(r.x,o.offset.x),ir(r.y,o.offset.y)),r}const pM={x:"translateX",y:"translateY",z:"translateZ",transformPerspective:"perspective"},mM=Mo.length;function gM(t,e,n){let r="",o=!0;for(let a=0;a<mM;a++){const l=Mo[a],c=t[l];if(c===void 0)continue;let d=!0;if(typeof c=="number")d=c===(l.startsWith("scale")?1:0);else{const f=parseFloat(c);d=l.startsWith("scale")?f===1:f===0}if(!d||n){const f=g_(c,Mm[l]);if(!d){o=!1;const p=pM[l]||l;r+=`${p}(${f}) `}n&&(e[l]=f)}}return r=r.trim(),n?r=n(e,o?"":r):o&&(r="none"),r}function zm(t,e,n){const{style:r,vars:o,transformOrigin:a}=t;let l=!1,c=!1;for(const d in e){const f=e[d];if($o.has(d)){l=!0;continue}else if($S(d)){o[d]=f;continue}else{const p=g_(f,Mm[d]);d.startsWith("origin")?(c=!0,a[d]=p):r[d]=p}}if(e.transform||(l||n?r.transform=gM(e,t.transform,n):r.transform&&(r.transform="none")),c){const{originX:d="50%",originY:f="50%",originZ:p=0}=a;r.transformOrigin=`${d} ${f} ${p}`}}function A_(t,{style:e,vars:n},r,o){const a=t.style;let l;for(l in e)a[l]=e[l];o==null||o.applyProjectionStyles(a,r);for(l in n)a.setProperty(l,n[l])}function Uw(t,e){return e.max===e.min?0:t/(e.max-e.min)*100}const Ca={correct:(t,e)=>{if(!e.target)return t;if(typeof t=="string")if(ue.test(t))t=parseFloat(t);else return t;const n=Uw(t,e.target.x),r=Uw(t,e.target.y);return`${n}% ${r}%`}},yM={correct:(t,{treeScale:e,projectionDelta:n})=>{const r=t,o=Fn.parse(t);if(o.length>5)return r;const a=Fn.createTransformer(t),l=typeof o[0]!="number"?1:0,c=n.x.scale*e.x,d=n.y.scale*e.y;o[0+l]/=c,o[1+l]/=d;const f=qe(c,d,.5);return typeof o[2+l]=="number"&&(o[2+l]/=f),typeof o[3+l]=="number"&&(o[3+l]/=f),a(o)}},Up={borderRadius:{...Ca,applyTo:["borderTopLeftRadius","borderTopRightRadius","borderBottomLeftRadius","borderBottomRightRadius"]},borderTopLeftRadius:Ca,borderTopRightRadius:Ca,borderBottomLeftRadius:Ca,borderBottomRightRadius:Ca,boxShadow:yM};function R_(t,{layout:e,layoutId:n}){return $o.has(t)||t.startsWith("origin")||(e||n!==void 0)&&(!!Up[t]||t==="opacity")}function Wm(t,e,n){var l;const r=t.style,o=e==null?void 0:e.style,a={};if(!r)return a;for(const c in r)(_t(r[c])||o&&_t(o[c])||R_(c,t)||((l=n==null?void 0:n.getValue(c))==null?void 0:l.liveStyle)!==void 0)&&(a[c]=r[c]);return a}function vM(t){return window.getComputedStyle(t)}class wM extends E_{constructor(){super(...arguments),this.type="html",this.renderInstance=A_}readValueFromInstance(e,n){var r;if($o.has(n))return(r=this.projection)!=null&&r.isProjecting?kp(n):FL(e,n);{const o=vM(e),a=($S(n)?o.getPropertyValue(n):o[n])||0;return typeof a=="string"?a.trim():a}}measureInstanceViewportBox(e,{transformPagePoint:n}){return P_(e,n)}build(e,n,r){zm(e,n,r.transformTemplate)}scrapeMotionValuesFromProps(e,n,r){return Wm(e,n,r)}}const xM={offset:"stroke-dashoffset",array:"stroke-dasharray"},bM={offset:"strokeDashoffset",array:"strokeDasharray"};function SM(t,e,n=1,r=0,o=!0){t.pathLength=1;const a=o?xM:bM;t[a.offset]=`${-r}`,t[a.array]=`${e} ${n}`}const _M=["offsetDistance","offsetPath","offsetRotate","offsetAnchor"];function j_(t,{attrX:e,attrY:n,attrScale:r,pathLength:o,pathSpacing:a=1,pathOffset:l=0,...c},d,f,p){if(zm(t,c,f),d){t.style.viewBox&&(t.attrs.viewBox=t.style.viewBox);return}t.attrs=t.style,t.style={};const{attrs:g,style:x}=t;g.transform&&(x.transform=g.transform,delete g.transform),(x.transform||g.transformOrigin)&&(x.transformOrigin=g.transformOrigin??"50% 50%",delete g.transformOrigin),x.transform&&(x.transformBox=(p==null?void 0:p.transformBox)??"fill-box",delete g.transformBox);for(const y of _M)g[y]!==void 0&&(x[y]=g[y],delete g[y]);e!==void 0&&(g.x=e),n!==void 0&&(g.y=n),r!==void 0&&(g.scale=r),o!==void 0&&SM(g,o,a,l,!1)}const O_=new Set(["baseFrequency","diffuseConstant","kernelMatrix","kernelUnitLength","keySplines","keyTimes","limitingConeAngle","markerHeight","markerWidth","numOctaves","targetX","targetY","surfaceScale","specularConstant","specularExponent","stdDeviation","tableValues","viewBox","gradientTransform","pathLength","startOffset","textLength","lengthAdjust"]),N_=t=>typeof t=="string"&&t.toLowerCase()==="svg";function EM(t,e,n,r){A_(t,e,void 0,r);for(const o in e.attrs)t.setAttribute(O_.has(o)?o:Dm(o),e.attrs[o])}function I_(t,e,n){const r=Wm(t,e,n);for(const o in t)if(_t(t[o])||_t(e[o])){const a=Mo.indexOf(o)!==-1?"attr"+o.charAt(0).toUpperCase()+o.substring(1):o;r[a]=t[o]}return r}class TM extends E_{constructor(){super(...arguments),this.type="svg",this.isSVGTag=!1,this.measureInstanceViewportBox=ct}getBaseTargetFromProps(e,n){return e[n]}readValueFromInstance(e,n){if($o.has(n)){const r=f_(n);return r&&r.default||0}return n=O_.has(n)?n:Dm(n),e.getAttribute(n)}scrapeMotionValuesFromProps(e,n,r){return I_(e,n,r)}build(e,n,r){j_(e,n,this.isSVGTag,r.transformTemplate,r.style)}renderInstance(e,n,r,o){EM(e,n,r,o)}mount(e){this.isSVGTag=N_(e.tagName),super.mount(e)}}const kM=Bm.length;function L_(t){if(!t)return;if(!t.isControllingVariants){const n=t.parent?L_(t.parent)||{}:{};return t.props.initial!==void 0&&(n.initial=t.props.initial),n}const e={};for(let n=0;n<kM;n++){const r=Bm[n],o=t.props[r];(nl(o)||o===!1)&&(e[r]=o)}return e}function D_(t,e){if(!Array.isArray(e))return!1;const n=e.length;if(n!==t.length)return!1;for(let r=0;r<n;r++)if(e[r]!==t[r])return!1;return!0}const CM=[...Vm].reverse(),PM=Vm.length;function AM(t){return e=>Promise.all(e.map(({animation:n,options:r})=>kD(t,n,r)))}function RM(t){let e=AM(t),n=Vw(),r=!0,o=!1;const a=f=>(p,g)=>{var y;const x=mi(t,g,f==="exit"?(y=t.presenceContext)==null?void 0:y.custom:void 0);if(x){const{transition:_,transitionEnd:S,...b}=x;p={...p,...b,...S}}return p};function l(f){e=f(t)}function c(f){const{props:p}=t,g=L_(t.parent)||{},x=[],y=new Set;let _={},S=1/0;for(let k=0;k<PM;k++){const P=CM[k],C=n[P],A=p[P]!==void 0?p[P]:g[P],L=nl(A),D=P===f?C.isActive:null;D===!1&&(S=k);let V=A===g[P]&&A!==p[P]&&L;if(V&&(r||o)&&t.manuallyAnimateOnMount&&(V=!1),C.protectedKeys={..._},!C.isActive&&D===null||!A&&!C.prevProp||Zc(A)||typeof A=="boolean")continue;if(P==="exit"&&C.isActive&&D!==!0){C.prevResolvedValues&&(_={..._,...C.prevResolvedValues});continue}const z=jM(C.prevProp,A);let q=z||P===f&&C.isActive&&!V&&L||k>S&&L,H=!1;const te=Array.isArray(A)?A:[A];let Z=te.reduce(a(P),{});D===!1&&(Z={});const{prevResolvedValues:me={}}=C,J={...me,...Z},fe=U=>{q=!0,y.has(U)&&(H=!0,y.delete(U)),C.needsAnimating[U]=!0;const W=t.getValue(U);W&&(W.liveStyle=!1)};for(const U in J){const W=Z[U],G=me[U];if(_.hasOwnProperty(U))continue;let N=!1;Op(W)&&Op(G)?N=!D_(W,G):N=W!==G,N?W!=null?fe(U):y.add(U):W!==void 0&&y.has(U)?fe(U):C.protectedKeys[U]=!0}C.prevProp=A,C.prevResolvedValues=Z,C.isActive&&(_={..._,...Z}),(r||o)&&t.blockInitialAnimation&&(q=!1);const ie=V&&z;q&&(!ie||H)&&x.push(...te.map(U=>{const W={type:P};if(typeof U=="string"&&(r||o)&&!ie&&t.manuallyAnimateOnMount&&t.parent){const{parent:G}=t,N=mi(G,U);if(G.enteringChildren&&N){const{delayChildren:B}=N.transition||{};W.delay=s_(G.enteringChildren,t,B)}}return{animation:U,options:W}}))}if(y.size){const k={};if(typeof p.initial!="boolean"){const P=mi(t,Array.isArray(p.initial)?p.initial[0]:p.initial);P&&P.transition&&(k.transition=P.transition)}y.forEach(P=>{const C=t.getBaseTarget(P),A=t.getValue(P);A&&(A.liveStyle=!0),k[P]=C??null}),x.push({animation:k})}let b=!!x.length;return r&&(p.initial===!1||p.initial===p.animate)&&!t.manuallyAnimateOnMount&&(b=!1),r=!1,o=!1,b?e(x):Promise.resolve()}function d(f,p){var x;if(n[f].isActive===p)return Promise.resolve();(x=t.variantChildren)==null||x.forEach(y=>{var _;return(_=y.animationState)==null?void 0:_.setActive(f,p)}),n[f].isActive=p;const g=c(f);for(const y in n)n[y].protectedKeys={};return g}return{animateChanges:c,setActive:d,setAnimateFunction:l,getState:()=>n,reset:()=>{n=Vw(),o=!0}}}function jM(t,e){return typeof e=="string"?e!==t:Array.isArray(e)?!D_(e,t):!1}function Ks(t=!1){return{isActive:t,protectedKeys:{},needsAnimating:{},prevResolvedValues:{}}}function Vw(){return{animate:Ks(!0),whileInView:Ks(),whileHover:Ks(),whileTap:Ks(),whileDrag:Ks(),whileFocus:Ks(),exit:Ks()}}function Vp(t,e){t.min=e.min,t.max=e.max}function An(t,e){Vp(t.x,e.x),Vp(t.y,e.y)}function Bw(t,e){t.translate=e.translate,t.scale=e.scale,t.originPoint=e.originPoint,t.origin=e.origin}const M_=1e-4,OM=1-M_,NM=1+M_,$_=.01,IM=0-$_,LM=0+$_;function Lt(t){return t.max-t.min}function DM(t,e,n){return Math.abs(t-e)<=n}function zw(t,e,n,r=.5){t.origin=r,t.originPoint=qe(e.min,e.max,t.origin),t.scale=Lt(n)/Lt(e),t.translate=qe(n.min,n.max,t.origin)-t.originPoint,(t.scale>=OM&&t.scale<=NM||isNaN(t.scale))&&(t.scale=1),(t.translate>=IM&&t.translate<=LM||isNaN(t.translate))&&(t.translate=0)}function $a(t,e,n,r){zw(t.x,e.x,n.x,r?r.originX:void 0),zw(t.y,e.y,n.y,r?r.originY:void 0)}function Ww(t,e,n,r=0){const o=r?qe(n.min,n.max,r):n.min;t.min=o+e.min,t.max=t.min+Lt(e)}function MM(t,e,n,r){Ww(t.x,e.x,n.x,r==null?void 0:r.x),Ww(t.y,e.y,n.y,r==null?void 0:r.y)}function Hw(t,e,n,r=0){const o=r?qe(n.min,n.max,r):n.min;t.min=e.min-o,t.max=t.min+Lt(e)}function Pc(t,e,n,r){Hw(t.x,e.x,n.x,r==null?void 0:r.x),Hw(t.y,e.y,n.y,r==null?void 0:r.y)}function qw(t,e,n,r,o){return t-=e,t=Cc(t,1/n,r),o!==void 0&&(t=Cc(t,1/o,r)),t}function $M(t,e=0,n=1,r=.5,o,a=t,l=t){if(lr.test(e)&&(e=parseFloat(e),e=qe(l.min,l.max,e/100)-l.min),typeof e!="number")return;let c=qe(a.min,a.max,r);t===a&&(c-=e),t.min=qw(t.min,e,n,c,o),t.max=qw(t.max,e,n,c,o)}function Kw(t,e,[n,r,o],a,l){$M(t,e[n],e[r],e[o],e.scale,a,l)}const FM=["x","scaleX","originX"],UM=["y","scaleY","originY"];function Gw(t,e,n,r){Kw(t.x,e,FM,n?n.x:void 0,r?r.x:void 0),Kw(t.y,e,UM,n?n.y:void 0,r?r.y:void 0)}function Qw(t){return t.translate===0&&t.scale===1}function F_(t){return Qw(t.x)&&Qw(t.y)}function Yw(t,e){return t.min===e.min&&t.max===e.max}function VM(t,e){return Yw(t.x,e.x)&&Yw(t.y,e.y)}function Jw(t,e){return Math.round(t.min)===Math.round(e.min)&&Math.round(t.max)===Math.round(e.max)}function U_(t,e){return Jw(t.x,e.x)&&Jw(t.y,e.y)}function Xw(t){return Lt(t.x)/Lt(t.y)}function Zw(t,e){return t.translate===e.translate&&t.scale===e.scale&&t.originPoint===e.originPoint}function tr(t){return[t("x"),t("y")]}function BM(t,e,n){let r="";const o=t.x.translate/e.x,a=t.y.translate/e.y,l=(n==null?void 0:n.z)||0;if((o||a||l)&&(r=`translate3d(${o}px, ${a}px, ${l}px) `),(e.x!==1||e.y!==1)&&(r+=`scale(${1/e.x}, ${1/e.y}) `),n){const{transformPerspective:f,rotate:p,rotateX:g,rotateY:x,skewX:y,skewY:_}=n;f&&(r=`perspective(${f}px) ${r}`),p&&(r+=`rotate(${p}deg) `),g&&(r+=`rotateX(${g}deg) `),x&&(r+=`rotateY(${x}deg) `),y&&(r+=`skewX(${y}deg) `),_&&(r+=`skewY(${_}deg) `)}const c=t.x.scale*e.x,d=t.y.scale*e.y;return(c!==1||d!==1)&&(r+=`scale(${c}, ${d})`),r||"none"}const V_=["borderTopLeftRadius","borderTopRightRadius","borderBottomLeftRadius","borderBottomRightRadius"],zM=V_.length,ex=t=>typeof t=="string"?parseFloat(t):t,tx=t=>typeof t=="number"||ue.test(t);function WM(t,e,n,r,o,a){o?(t.opacity=qe(0,n.opacity??1,HM(r)),t.opacityExit=qe(e.opacity??1,0,qM(r))):a&&(t.opacity=qe(e.opacity??1,n.opacity??1,r));for(let l=0;l<zM;l++){const c=V_[l];let d=nx(e,c),f=nx(n,c);if(d===void 0&&f===void 0)continue;d||(d=0),f||(f=0),d===0||f===0||tx(d)===tx(f)?(t[c]=Math.max(qe(ex(d),ex(f),r),0),(lr.test(f)||lr.test(d))&&(t[c]+="%")):t[c]=f}(e.rotate||n.rotate)&&(t.rotate=qe(e.rotate||0,n.rotate||0,r))}function nx(t,e){return t[e]!==void 0?t[e]:t.borderRadius}const HM=B_(0,.5,OS),qM=B_(.5,.95,vn);function B_(t,e,n){return r=>r<t?0:r>e?1:n(el(t,e,r))}function KM(t,e,n){const r=_t(t)?t:Ao(t);return r.start(Im("",r,e,n)),r.animation}function rl(t,e,n,r={passive:!0}){return t.addEventListener(e,n,r),()=>t.removeEventListener(e,n)}const GM=(t,e)=>t.depth-e.depth;class QM{constructor(){this.children=[],this.isDirty=!1}add(e){bm(this.children,e),this.isDirty=!0}remove(e){bc(this.children,e),this.isDirty=!0}forEach(e){this.isDirty&&this.children.sort(GM),this.isDirty=!1,this.children.forEach(e)}}function YM(t,e){const n=It.now(),r=({timestamp:o})=>{const a=o-n;a>=e&&(Es(r),t(a-e))};return Ue.setup(r,!0),()=>Es(r)}function dc(t){return _t(t)?t.get():t}class JM{constructor(){this.members=[]}add(e){bm(this.members,e);for(let n=this.members.length-1;n>=0;n--){const r=this.members[n];if(r===e||r===this.lead||r===this.prevLead)continue;const o=r.instance;(!o||o.isConnected===!1)&&!r.snapshot&&(bc(this.members,r),r.unmount())}e.scheduleRender()}remove(e){if(bc(this.members,e),e===this.prevLead&&(this.prevLead=void 0),e===this.lead){const n=this.members[this.members.length-1];n&&this.promote(n)}}relegate(e){var n;for(let r=this.members.indexOf(e)-1;r>=0;r--){const o=this.members[r];if(o.isPresent!==!1&&((n=o.instance)==null?void 0:n.isConnected)!==!1)return this.promote(o),!0}return!1}promote(e,n){var o;const r=this.lead;if(e!==r&&(this.prevLead=r,this.lead=e,e.show(),r)){r.updateSnapshot(),e.scheduleRender();const{layoutDependency:a}=r.options,{layoutDependency:l}=e.options;(a===void 0||a!==l)&&(e.resumeFrom=r,n&&(r.preserveOpacity=!0),r.snapshot&&(e.snapshot=r.snapshot,e.snapshot.latestValues=r.animationValues||r.latestValues),(o=e.root)!=null&&o.isUpdating&&(e.isLayoutDirty=!0)),e.options.crossfade===!1&&r.hide()}}exitAnimationComplete(){this.members.forEach(e=>{var n,r,o,a,l;(r=(n=e.options).onExitComplete)==null||r.call(n),(l=(o=e.resumingFrom)==null?void 0:(a=o.options).onExitComplete)==null||l.call(a)})}scheduleRender(){this.members.forEach(e=>e.instance&&e.scheduleRender(!1))}removeLeadSnapshot(){var e;(e=this.lead)!=null&&e.snapshot&&(this.lead.snapshot=void 0)}}const hc={hasAnimatedSinceResize:!0,hasEverUpdated:!1},xf=["","X","Y","Z"],XM=1e3;let ZM=0;function bf(t,e,n,r){const{latestValues:o}=e;o[t]&&(n[t]=o[t],e.setStaticValue(t,0),r&&(r[t]=0))}function z_(t){if(t.hasCheckedOptimisedAppear=!0,t.root===t)return;const{visualElement:e}=t.options;if(!e)return;const n=u_(e);if(window.MotionHasOptimisedAnimation(n,"transform")){const{layout:o,layoutId:a}=t.options;window.MotionCancelOptimisedAnimation(n,"transform",Ue,!(o||a))}const{parent:r}=t;r&&!r.hasCheckedOptimisedAppear&&z_(r)}function W_({attachResizeListener:t,defaultParent:e,measureScroll:n,checkIsScrollRoot:r,resetTransform:o}){return class{constructor(l={},c=e==null?void 0:e()){this.id=ZM++,this.animationId=0,this.animationCommitId=0,this.children=new Set,this.options={},this.isTreeAnimating=!1,this.isAnimationBlocked=!1,this.isLayoutDirty=!1,this.isProjectionDirty=!1,this.isSharedProjectionDirty=!1,this.isTransformDirty=!1,this.updateManuallyBlocked=!1,this.updateBlockedByResize=!1,this.isUpdating=!1,this.isSVG=!1,this.needsReset=!1,this.shouldResetTransform=!1,this.hasCheckedOptimisedAppear=!1,this.treeScale={x:1,y:1},this.eventHandlers=new Map,this.hasTreeAnimated=!1,this.layoutVersion=0,this.updateScheduled=!1,this.scheduleUpdate=()=>this.update(),this.projectionUpdateScheduled=!1,this.checkUpdateFailed=()=>{this.isUpdating&&(this.isUpdating=!1,this.clearAllSnapshots())},this.updateProjection=()=>{this.projectionUpdateScheduled=!1,this.nodes.forEach(n5),this.nodes.forEach(l5),this.nodes.forEach(u5),this.nodes.forEach(r5)},this.resolvedRelativeTargetAt=0,this.linkedParentVersion=0,this.hasProjected=!1,this.isVisible=!0,this.animationProgress=0,this.sharedNodes=new Map,this.latestValues=l,this.root=c?c.root||c:this,this.path=c?[...c.path,c]:[],this.parent=c,this.depth=c?c.depth+1:0;for(let d=0;d<this.path.length;d++)this.path[d].shouldResetTransform=!0;this.root===this&&(this.nodes=new QM)}addEventListener(l,c){return this.eventHandlers.has(l)||this.eventHandlers.set(l,new _m),this.eventHandlers.get(l).add(c)}notifyListeners(l,...c){const d=this.eventHandlers.get(l);d&&d.notify(...c)}hasListeners(l){return this.eventHandlers.has(l)}mount(l){if(this.instance)return;this.isSVG=Um(l)&&!tM(l),this.instance=l;const{layoutId:c,layout:d,visualElement:f}=this.options;if(f&&!f.current&&f.mount(l),this.root.nodes.add(this),this.parent&&this.parent.children.add(this),this.root.hasTreeAnimated&&(d||c)&&(this.isLayoutDirty=!0),t){let p,g=0;const x=()=>this.root.updateBlockedByResize=!1;Ue.read(()=>{g=window.innerWidth}),t(l,()=>{const y=window.innerWidth;y!==g&&(g=y,this.root.updateBlockedByResize=!0,p&&p(),p=YM(x,250),hc.hasAnimatedSinceResize&&(hc.hasAnimatedSinceResize=!1,this.nodes.forEach(ix)))})}c&&this.root.registerSharedNode(c,this),this.options.animate!==!1&&f&&(c||d)&&this.addEventListener("didUpdate",({delta:p,hasLayoutChanged:g,hasRelativeLayoutChanged:x,layout:y})=>{if(this.isTreeAnimationBlocked()){this.target=void 0,this.relativeTarget=void 0;return}const _=this.options.transition||f.getDefaultTransition()||p5,{onLayoutAnimationStart:S,onLayoutAnimationComplete:b}=f.getProps(),k=!this.targetLayout||!U_(this.targetLayout,y),P=!g&&x;if(this.options.layoutRoot||this.resumeFrom||P||g&&(k||!this.currentAnimation)){this.resumeFrom&&(this.resumingFrom=this.resumeFrom,this.resumingFrom.resumingFrom=void 0);const C={...Nm(_,"layout"),onPlay:S,onComplete:b};(f.shouldReduceMotion||this.options.layoutRoot)&&(C.delay=0,C.type=!1),this.startAnimation(C),this.setAnimationOrigin(p,P)}else g||ix(this),this.isLead()&&this.options.onExitComplete&&this.options.onExitComplete();this.targetLayout=y})}unmount(){this.options.layoutId&&this.willUpdate(),this.root.nodes.remove(this);const l=this.getStack();l&&l.remove(this),this.parent&&this.parent.children.delete(this),this.instance=void 0,this.eventHandlers.clear(),Es(this.updateProjection)}blockUpdate(){this.updateManuallyBlocked=!0}unblockUpdate(){this.updateManuallyBlocked=!1}isUpdateBlocked(){return this.updateManuallyBlocked||this.updateBlockedByResize}isTreeAnimationBlocked(){return this.isAnimationBlocked||this.parent&&this.parent.isTreeAnimationBlocked()||!1}startUpdate(){this.isUpdateBlocked()||(this.isUpdating=!0,this.nodes&&this.nodes.forEach(c5),this.animationId++)}getTransformTemplate(){const{visualElement:l}=this.options;return l&&l.getProps().transformTemplate}willUpdate(l=!0){if(this.root.hasTreeAnimated=!0,this.root.isUpdateBlocked()){this.options.onExitComplete&&this.options.onExitComplete();return}if(window.MotionCancelOptimisedAnimation&&!this.hasCheckedOptimisedAppear&&z_(this),!this.root.isUpdating&&this.root.startUpdate(),this.isLayoutDirty)return;this.isLayoutDirty=!0;for(let p=0;p<this.path.length;p++){const g=this.path[p];g.shouldResetTransform=!0,(typeof g.latestValues.x=="string"||typeof g.latestValues.y=="string")&&(g.isLayoutDirty=!0),g.updateScroll("snapshot"),g.options.layoutRoot&&g.willUpdate(!1)}const{layoutId:c,layout:d}=this.options;if(c===void 0&&!d)return;const f=this.getTransformTemplate();this.prevTransformTemplateValue=f?f(this.latestValues,""):void 0,this.updateSnapshot(),l&&this.notifyListeners("willUpdate")}update(){if(this.updateScheduled=!1,this.isUpdateBlocked()){const d=this.updateBlockedByResize;this.unblockUpdate(),this.updateBlockedByResize=!1,this.clearAllSnapshots(),d&&this.nodes.forEach(i5),this.nodes.forEach(rx);return}if(this.animationId<=this.animationCommitId){this.nodes.forEach(sx);return}this.animationCommitId=this.animationId,this.isUpdating?(this.isUpdating=!1,this.nodes.forEach(o5),this.nodes.forEach(a5),this.nodes.forEach(e5),this.nodes.forEach(t5)):this.nodes.forEach(sx),this.clearAllSnapshots();const c=It.now();bt.delta=ur(0,1e3/60,c-bt.timestamp),bt.timestamp=c,bt.isProcessing=!0,hf.update.process(bt),hf.preRender.process(bt),hf.render.process(bt),bt.isProcessing=!1}didUpdate(){this.updateScheduled||(this.updateScheduled=!0,$m.read(this.scheduleUpdate))}clearAllSnapshots(){this.nodes.forEach(s5),this.sharedNodes.forEach(d5)}scheduleUpdateProjection(){this.projectionUpdateScheduled||(this.projectionUpdateScheduled=!0,Ue.preRender(this.updateProjection,!1,!0))}scheduleCheckAfterUnmount(){Ue.postRender(()=>{this.isLayoutDirty?this.root.didUpdate():this.root.checkUpdateFailed()})}updateSnapshot(){this.snapshot||!this.instance||(this.snapshot=this.measure(),this.snapshot&&!Lt(this.snapshot.measuredBox.x)&&!Lt(this.snapshot.measuredBox.y)&&(this.snapshot=void 0))}updateLayout(){if(!this.instance||(this.updateScroll(),!(this.options.alwaysMeasureLayout&&this.isLead())&&!this.isLayoutDirty))return;if(this.resumeFrom&&!this.resumeFrom.instance)for(let d=0;d<this.path.length;d++)this.path[d].updateScroll();const l=this.layout;this.layout=this.measure(!1),this.layoutVersion++,this.layoutCorrected||(this.layoutCorrected=ct()),this.isLayoutDirty=!1,this.projectionDelta=void 0,this.notifyListeners("measure",this.layout.layoutBox);const{visualElement:c}=this.options;c&&c.notify("LayoutMeasure",this.layout.layoutBox,l?l.layoutBox:void 0)}updateScroll(l="measure"){let c=!!(this.options.layoutScroll&&this.instance);if(this.scroll&&this.scroll.animationId===this.root.animationId&&this.scroll.phase===l&&(c=!1),c&&this.instance){const d=r(this.instance);this.scroll={animationId:this.root.animationId,phase:l,isRoot:d,offset:n(this.instance),wasRoot:this.scroll?this.scroll.isRoot:d}}}resetTransform(){if(!o)return;const l=this.isLayoutDirty||this.shouldResetTransform||this.options.alwaysMeasureLayout,c=this.projectionDelta&&!F_(this.projectionDelta),d=this.getTransformTemplate(),f=d?d(this.latestValues,""):void 0,p=f!==this.prevTransformTemplateValue;l&&this.instance&&(c||Qs(this.latestValues)||p)&&(o(this.instance,f),this.shouldResetTransform=!1,this.scheduleRender())}measure(l=!0){const c=this.measurePageBox();let d=this.removeElementScroll(c);return l&&(d=this.removeTransform(d)),m5(d),{animationId:this.root.animationId,measuredBox:c,layoutBox:d,latestValues:{},source:this.id}}measurePageBox(){var f;const{visualElement:l}=this.options;if(!l)return ct();const c=l.measureViewportBox();if(!(((f=this.scroll)==null?void 0:f.wasRoot)||this.path.some(g5))){const{scroll:p}=this.root;p&&(ir(c.x,p.offset.x),ir(c.y,p.offset.y))}return c}removeElementScroll(l){var d;const c=ct();if(An(c,l),(d=this.scroll)!=null&&d.wasRoot)return c;for(let f=0;f<this.path.length;f++){const p=this.path[f],{scroll:g,options:x}=p;p!==this.root&&g&&x.layoutScroll&&(g.wasRoot&&An(c,l),ir(c.x,g.offset.x),ir(c.y,g.offset.y))}return c}applyTransform(l,c=!1,d){var p,g;const f=d||ct();An(f,l);for(let x=0;x<this.path.length;x++){const y=this.path[x];!c&&y.options.layoutScroll&&y.scroll&&y!==y.root&&(ir(f.x,-y.scroll.offset.x),ir(f.y,-y.scroll.offset.y)),Qs(y.latestValues)&&cc(f,y.latestValues,(p=y.layout)==null?void 0:p.layoutBox)}return Qs(this.latestValues)&&cc(f,this.latestValues,(g=this.layout)==null?void 0:g.layoutBox),f}removeTransform(l){var d;const c=ct();An(c,l);for(let f=0;f<this.path.length;f++){const p=this.path[f];if(!Qs(p.latestValues))continue;let g;p.instance&&($p(p.latestValues)&&p.updateSnapshot(),g=ct(),An(g,p.measurePageBox())),Gw(c,p.latestValues,(d=p.snapshot)==null?void 0:d.layoutBox,g)}return Qs(this.latestValues)&&Gw(c,this.latestValues),c}setTargetDelta(l){this.targetDelta=l,this.root.scheduleUpdateProjection(),this.isProjectionDirty=!0}setOptions(l){this.options={...this.options,...l,crossfade:l.crossfade!==void 0?l.crossfade:!0}}clearMeasurements(){this.scroll=void 0,this.layout=void 0,this.snapshot=void 0,this.prevTransformTemplateValue=void 0,this.targetDelta=void 0,this.target=void 0,this.isLayoutDirty=!1}forceRelativeParentToResolveTarget(){this.relativeParent&&this.relativeParent.resolvedRelativeTargetAt!==bt.timestamp&&this.relativeParent.resolveTargetDelta(!0)}resolveTargetDelta(l=!1){var y;const c=this.getLead();this.isProjectionDirty||(this.isProjectionDirty=c.isProjectionDirty),this.isTransformDirty||(this.isTransformDirty=c.isTransformDirty),this.isSharedProjectionDirty||(this.isSharedProjectionDirty=c.isSharedProjectionDirty);const d=!!this.resumingFrom||this!==c;if(!(l||d&&this.isSharedProjectionDirty||this.isProjectionDirty||(y=this.parent)!=null&&y.isProjectionDirty||this.attemptToResolveRelativeTarget||this.root.updateBlockedByResize))return;const{layout:p,layoutId:g}=this.options;if(!this.layout||!(p||g))return;this.resolvedRelativeTargetAt=bt.timestamp;const x=this.getClosestProjectingParent();x&&this.linkedParentVersion!==x.layoutVersion&&!x.options.layoutRoot&&this.removeRelativeTarget(),!this.targetDelta&&!this.relativeTarget&&(this.options.layoutAnchor!==!1&&x&&x.layout?this.createRelativeTarget(x,this.layout.layoutBox,x.layout.layoutBox):this.removeRelativeTarget()),!(!this.relativeTarget&&!this.targetDelta)&&(this.target||(this.target=ct(),this.targetWithTransforms=ct()),this.relativeTarget&&this.relativeTargetOrigin&&this.relativeParent&&this.relativeParent.target?(this.forceRelativeParentToResolveTarget(),MM(this.target,this.relativeTarget,this.relativeParent.target,this.options.layoutAnchor||void 0)):this.targetDelta?(this.resumingFrom?this.applyTransform(this.layout.layoutBox,!1,this.target):An(this.target,this.layout.layoutBox),C_(this.target,this.targetDelta)):An(this.target,this.layout.layoutBox),this.attemptToResolveRelativeTarget&&(this.attemptToResolveRelativeTarget=!1,this.options.layoutAnchor!==!1&&x&&!!x.resumingFrom==!!this.resumingFrom&&!x.options.layoutScroll&&x.target&&this.animationProgress!==1?this.createRelativeTarget(x,this.target,x.target):this.relativeParent=this.relativeTarget=void 0))}getClosestProjectingParent(){if(!(!this.parent||$p(this.parent.latestValues)||k_(this.parent.latestValues)))return this.parent.isProjecting()?this.parent:this.parent.getClosestProjectingParent()}isProjecting(){return!!((this.relativeTarget||this.targetDelta||this.options.layoutRoot)&&this.layout)}createRelativeTarget(l,c,d){this.relativeParent=l,this.linkedParentVersion=l.layoutVersion,this.forceRelativeParentToResolveTarget(),this.relativeTarget=ct(),this.relativeTargetOrigin=ct(),Pc(this.relativeTargetOrigin,c,d,this.options.layoutAnchor||void 0),An(this.relativeTarget,this.relativeTargetOrigin)}removeRelativeTarget(){this.relativeParent=this.relativeTarget=void 0}calcProjection(){var _;const l=this.getLead(),c=!!this.resumingFrom||this!==l;let d=!0;if((this.isProjectionDirty||(_=this.parent)!=null&&_.isProjectionDirty)&&
vendor: 5,333 bytes, line 306
306(d=!1),c&&(this.isSharedProjectionDirty||this.isTransformDirty)&&(d=!1),this.resolvedRelativeTargetAt===bt.timestamp&&(d=!1),d)return;const{layout:f,layoutId:p}=this.options;if(this.isTreeAnimating=!!(this.parent&&this.parent.isTreeAnimating||this.currentAnimation||this.pendingAnimation),this.isTreeAnimating||(this.targetDelta=this.relativeTarget=void 0),!this.layout||!(f||p))return;An(this.layoutCorrected,this.layout.layoutBox);const g=this.treeScale.x,x=this.treeScale.y;hM(this.layoutCorrected,this.treeScale,this.path,c),l.layout&&!l.target&&(this.treeScale.x!==1||this.treeScale.y!==1)&&(l.target=l.layout.layoutBox,l.targetWithTransforms=ct());const{target:y}=l;if(!y){this.prevProjectionDelta&&(this.createProjectionDeltas(),this.scheduleRender());return}!this.projectionDelta||!this.prevProjectionDelta?this.createProjectionDeltas():(Bw(this.prevProjectionDelta.x,this.projectionDelta.x),Bw(this.prevProjectionDelta.y,this.projectionDelta.y)),$a(this.projectionDelta,this.layoutCorrected,y,this.latestValues),(this.treeScale.x!==g||this.treeScale.y!==x||!Zw(this.projectionDelta.x,this.prevProjectionDelta.x)||!Zw(this.projectionDelta.y,this.prevProjectionDelta.y))&&(this.hasProjected=!0,this.scheduleRender(),this.notifyListeners("projectionUpdate",y))}hide(){this.isVisible=!1}show(){this.isVisible=!0}scheduleRender(l=!0){var c;if((c=this.options.visualElement)==null||c.scheduleRender(),l){const d=this.getStack();d&&d.scheduleRender()}this.resumingFrom&&!this.resumingFrom.instance&&(this.resumingFrom=void 0)}createProjectionDeltas(){this.prevProjectionDelta=ao(),this.projectionDelta=ao(),this.projectionDeltaWithTransform=ao()}setAnimationOrigin(l,c=!1){const d=this.snapshot,f=d?d.latestValues:{},p={...this.latestValues},g=ao();(!this.relativeParent||!this.relativeParent.options.layoutRoot)&&(this.relativeTarget=this.relativeTargetOrigin=void 0),this.attemptToResolveRelativeTarget=!c;const x=ct(),y=d?d.source:void 0,_=this.layout?this.layout.source:void 0,S=y!==_,b=this.getStack(),k=!b||b.members.length<=1,P=!!(S&&!k&&this.options.crossfade===!0&&!this.path.some(f5));this.animationProgress=0;let C;this.mixTargetDelta=A=>{const L=A/1e3;ox(g.x,l.x,L),ox(g.y,l.y,L),this.setTargetDelta(g),this.relativeTarget&&this.relativeTargetOrigin&&this.layout&&this.relativeParent&&this.relativeParent.layout&&(Pc(x,this.layout.layoutBox,this.relativeParent.layout.layoutBox,this.options.layoutAnchor||void 0),h5(this.relativeTarget,this.relativeTargetOrigin,x,L),C&&VM(this.relativeTarget,C)&&(this.isProjectionDirty=!1),C||(C=ct()),An(C,this.relativeTarget)),S&&(this.animationValues=p,WM(p,f,this.latestValues,L,P,k)),this.root.scheduleUpdateProjection(),this.scheduleRender(),this.animationProgress=L},this.mixTargetDelta(this.options.layoutRoot?1e3:0)}startAnimation(l){var c,d,f;this.notifyListeners("animationStart"),(c=this.currentAnimation)==null||c.stop(),(f=(d=this.resumingFrom)==null?void 0:d.currentAnimation)==null||f.stop(),this.pendingAnimation&&(Es(this.pendingAnimation),this.pendingAnimation=void 0),this.pendingAnimation=Ue.update(()=>{hc.hasAnimatedSinceResize=!0,this.motionValue||(this.motionValue=Ao(0)),this.motionValue.jump(0,!1),this.currentAnimation=KM(this.motionValue,[0,1e3],{...l,velocity:0,isSync:!0,onUpdate:p=>{this.mixTargetDelta(p),l.onUpdate&&l.onUpdate(p)},onStop:()=>{},onComplete:()=>{l.onComplete&&l.onComplete(),this.completeAnimation()}}),this.resumingFrom&&(this.resumingFrom.currentAnimation=this.currentAnimation),this.pendingAnimation=void 0})}completeAnimation(){this.resumingFrom&&(this.resumingFrom.currentAnimation=void 0,this.resumingFrom.preserveOpacity=void 0);const l=this.getStack();l&&l.exitAnimationComplete(),this.resumingFrom=this.currentAnimation=this.animationValues=void 0,this.notifyListeners("animationComplete")}finishAnimation(){this.currentAnimation&&(this.mixTargetDelta&&this.mixTargetDelta(XM),this.currentAnimation.stop()),this.completeAnimation()}applyTransformsToTarget(){const l=this.getLead();let{targetWithTransforms:c,target:d,layout:f,latestValues:p}=l;if(!(!c||!d||!f)){if(this!==l&&this.layout&&f&&H_(this.options.animationType,this.layout.layoutBox,f.layoutBox)){d=this.target||ct();const g=Lt(this.layout.layoutBox.x);d.x.min=l.target.x.min,d.x.max=d.x.min+g;const x=Lt(this.layout.layoutBox.y);d.y.min=l.target.y.min,d.y.max=d.y.min+x}An(c,d),cc(c,p),$a(this.projectionDeltaWithTransform,this.layoutCorrected,c,p)}}registerSharedNode(l,c){this.sharedNodes.has(l)||this.sharedNodes.set(l,new JM),this.sharedNodes.get(l).add(c);const f=c.options.initialPromotionConfig;c.promote({transition:f?f.transition:void 0,preserveFollowOpacity:f&&f.shouldPreserveFollowOpacity?f.shouldPreserveFollowOpacity(c):void 0})}isLead(){const l=this.getStack();return l?l.lead===this:!0}getLead(){var c;const{layoutId:l}=this.options;return l?((c=this.getStack())==null?void 0:c.lead)||this:this}getPrevLead(){var c;const{layoutId:l}=this.options;return l?(c=this.getStack())==null?void 0:c.prevLead:void 0}getStack(){const{layoutId:l}=this.options;if(l)return this.root.sharedNodes.get(l)}promote({needsReset:l,transition:c,preserveFollowOpacity:d}={}){const f=this.getStack();f&&f.promote(this,d),l&&(this.projectionDelta=void 0,this.needsReset=!0),c&&this.setOptions({transition:c})}relegate(){const l=this.getStack();return l?l.relegate(this):!1}
vendor: 4,502 bytes, line 306
306resetSkewAndRotation(){const{visualElement:l}=this.options;if(!l)return;let c=!1;const{latestValues:d}=l;if((d.z||d.rotate||d.rotateX||d.rotateY||d.rotateZ||d.skewX||d.skewY)&&(c=!0),!c)return;const f={};d.z&&bf("z",l,f,this.animationValues);for(let p=0;p<xf.length;p++)bf(`rotate${xf[p]}`,l,f,this.animationValues),bf(`skew${xf[p]}`,l,f,this.animationValues);l.render();for(const p in f)l.setStaticValue(p,f[p]),this.animationValues&&(this.animationValues[p]=f[p]);l.scheduleRender()}applyProjectionStyles(l,c){if(!this.instance||this.isSVG)return;if(!this.isVisible){l.visibility="hidden";return}const d=this.getTransformTemplate();if(this.needsReset){this.needsReset=!1,l.visibility="",l.opacity="",l.pointerEvents=dc(c==null?void 0:c.pointerEvents)||"",l.transform=d?d(this.latestValues,""):"none";return}const f=this.getLead();if(!this.projectionDelta||!this.layout||!f.target){this.options.layoutId&&(l.opacity=this.latestValues.opacity!==void 0?this.latestValues.opacity:1,l.pointerEvents=dc(c==null?void 0:c.pointerEvents)||""),this.hasProjected&&!Qs(this.latestValues)&&(l.transform=d?d({},""):"none",this.hasProjected=!1);return}l.visibility="";const p=f.animationValues||f.latestValues;this.applyTransformsToTarget();let g=BM(this.projectionDeltaWithTransform,this.treeScale,p);d&&(g=d(p,g)),l.transform=g;const{x,y}=this.projectionDelta;l.transformOrigin=`${x.origin*100}% ${y.origin*100}% 0`,f.animationValues?l.opacity=f===this?p.opacity??this.latestValues.opacity??1:this.preserveOpacity?this.latestValues.opacity:p.opacityExit:l.opacity=f===this?p.opacity!==void 0?p.opacity:"":p.opacityExit!==void 0?p.opacityExit:0;for(const _ in Up){if(p[_]===void 0)continue;const{correct:S,applyTo:b,isCSSVariable:k}=Up[_],P=g==="none"?p[_]:S(p[_],f);if(b){const C=b.length;for(let A=0;A<C;A++)l[b[A]]=P}else k?this.options.visualElement.renderState.vars[_]=P:l[_]=P}this.options.layoutId&&(l.pointerEvents=f===this?dc(c==null?void 0:c.pointerEvents)||"":"none")}clearSnapshot(){this.resumeFrom=this.snapshot=void 0}resetTree(){this.root.nodes.forEach(l=>{var c;return(c=l.currentAnimation)==null?void 0:c.stop()}),this.root.nodes.forEach(rx),this.root.sharedNodes.clear()}}}function e5(t){t.updateLayout()}function t5(t){var n;const e=((n=t.resumeFrom)==null?void 0:n.snapshot)||t.snapshot;if(t.isLead()&&t.layout&&e&&t.hasListeners("didUpdate")){const{layoutBox:r,measuredBox:o}=t.layout,{animationType:a}=t.options,l=e.source!==t.layout.source;if(a==="size")tr(g=>{const x=l?e.measuredBox[g]:e.layoutBox[g],y=Lt(x);x.min=r[g].min,x.max=x.min+y});else if(a==="x"||a==="y"){const g=a==="x"?"y":"x";Vp(l?e.measuredBox[g]:e.layoutBox[g],r[g])}else H_(a,e.layoutBox,r)&&tr(g=>{const x=l?e.measuredBox[g]:e.layoutBox[g],y=Lt(r[g]);x.max=x.min+y,t.relativeTarget&&!t.currentAnimation&&(t.isProjectionDirty=!0,t.relativeTarget[g].max=t.relativeTarget[g].min+y)});const c=ao();$a(c,r,e.layoutBox);const d=ao();l?$a(d,t.applyTransform(o,!0),e.measuredBox):$a(d,r,e.layoutBox);const f=!F_(c);let p=!1;if(!t.resumeFrom){const g=t.getClosestProjectingParent();if(g&&!g.resumeFrom){const{snapshot:x,layout:y}=g;if(x&&y){const _=t.options.layoutAnchor||void 0,S=ct();Pc(S,e.layoutBox,x.layoutBox,_);const b=ct();Pc(b,r,y.layoutBox,_),U_(S,b)||(p=!0),g.options.layoutRoot&&(t.relativeTarget=b,t.relativeTargetOrigin=S,t.relativeParent=g)}}}t.notifyListeners("didUpdate",{layout:r,snapshot:e,delta:d,layoutDelta:c,hasLayoutChanged:f,hasRelativeLayoutChanged:p})}else if(t.isLead()){const{onExitComplete:r}=t.options;r&&r()}t.options.transition=void 0}function n5(t){t.parent&&(t.isProjecting()||(t.isProjectionDirty=t.parent.isProjectionDirty),t.isSharedProjectionDirty||(t.isSharedProjectionDirty=!!(t.isProjectionDirty||t.parent.isProjectionDirty||t.parent.isSharedProjectionDirty)),t.isTransformDirty||(t.isTransformDirty=t.parent.isTransformDirty))}function r5(t){t.isProjectionDirty=t.isSharedProjectionDirty=t.isTransformDirty=!1}function s5(t){t.clearSnapshot()}function rx(t){t.clearMeasurements()}function i5(t){t.isLayoutDirty=!0,t.updateLayout()}function sx(t){t.isLayoutDirty=!1}function o5(t){t.isAnimationBlocked&&t.layout&&!t.isLayoutDirty&&(t.snapshot=t.layout,t.isLayoutDirty=!0)}function a5(t){const{visualElement:e}=t.options;e&&e.getProps().onBeforeLayoutMeasure&&e.notify("BeforeLayoutMeasure"),t.resetTransform()}function ix(t){t.finishAnimation(),t.targetDelta=t.relativeTarget=t.target=void 0,t.isProjectionDirty=!0}function l5(t){t.resolveTargetDelta()}function u5(t){t.calcProjection()}
306function c5(t){t.resetSkewAndRotation()}function d5(t){t.removeLeadSnapshot()}function ox(t,e,n){t.translate=qe(e.translate,0,n),t.scale=qe(e.scale,1,n),t.origin=e.origin,t.originPoint=e.originPoint}function ax(t,e,n,r){t.min=qe(e.min,n.min,r),t.max=qe(e.max,n.max,r)}function h5(t,e,n,r){ax(t.x,e.x,n.x,r),ax(t.y,e.y,n.y,r)}function f5(t){return t.animationValues&&t.animationValues.opacityExit!==void 0}const p5={duration:.45,ease:[.4,0,.1,1]},lx=t=>typeof navigator<"u"&&navigator.userAgent&&navigator.userAgent.toLowerCase().includes(t),ux=lx("applewebkit/")&&!lx("chrome/")?Math.round:vn;function cx(t){t.min=ux(t.min),t.max=ux(t.max)}function m5(t){cx(t.x),cx(t.y)}function H_(t,e,n){return t==="position"||t==="preserve-aspect"&&!DM(Xw(e),Xw(n),.2)}function g5(t){var e;return t!==t.root&&((e=t.scroll)==null?void 0:e.wasRoot)}const y5=W_({attachResizeListener:(t,e)=>rl(t,"resize",e),measureScroll:()=>{var t,e;return{x:document.documentElement.scrollLeft||((t=document.body)==null?void 0:t.scrollLeft)||0,y:document.documentElement.scrollTop||((e=document.body)==null?void 0:e.scrollTop)||0}},checkIsScrollRoot:()=>!0}),Sf={current:void 0},q_=W_({measureScroll:t=>({x:t.scrollLeft,y:t.scrollTop}),defaultParent:()=>{if(!Sf.current){const t=new y5({});t.mount(window),t.setOptions({layoutScroll:!0}),Sf.current=t}return Sf.current},resetTransform:(t,e)=>{t.style.transform=e!==void 0?e:"none"},checkIsScrollRoot:t=>window.getComputedStyle(t).position==="fixed"}),Hm=E.createContext({transformPagePoint:t=>t,isStatic:!1,reducedMotion:"never"});function dx(t,e){if(typeof t=="function")return t(e);t!=null&&(t.current=e)}function v5(...t){return e=>{let n=!1;const r=t.map(o=>{const a=dx(o,e);return!n&&typeof a=="function"&&(n=!0),a});if(n)return()=>{for(let o=0;o<r.length;o++){const a=r[o];typeof a=="function"?a():dx(t[o],null)}}}}function w5(...t){return E.useCallback(v5(...t),t)}class x5 extends E.Component{getSnapshotBeforeUpdate(e){const n=this.props.childRef.current;if(oc(n)&&e.isPresent&&!this.props.isPresent&&this.props.pop!==!1){const r=n.offsetParent,o=oc(r)&&r.offsetWidth||0,a=oc(r)&&r.offsetHeight||0,l=getComputedStyle(n),c=this.props.sizeRef.current;c.height=parseFloat(l.height),c.width=parseFloat(l.width),c.top=n.offsetTop,c.left=n.offsetLeft,c.right=o-c.width-c.left,c.bottom=a-c.height-c.top}return null}componentDidUpdate(){}render(){return this.props.children}}function b5({children:t,isPresent:e,anchorX:n,anchorY:r,root:o,pop:a}){var x;const l=E.useId(),c=E.useRef(null),d=E.useRef({width:0,height:0,top:0,left:0,right:0,bottom:0}),{nonce:f}=E.useContext(Hm),p=((x=t.props)==null?void 0:x.ref)??(t==null?void 0:t.ref),g=w5(c,p);return E.useInsertionEffect(()=>{const{width:y,height:_,top:S,left:b,right:k,bottom:P}=d.current;if(e||a===!1||!c.current||!y||!_)return;const C=n==="left"?`left: ${b}`:`right: ${k}`,A=r==="bottom"?`bottom: ${P}`:`top: ${S}`;c.current.dataset.motionPopId=l;const L=document.createElement("style");f&&(L.nonce=f);const D=o??document.head;return D.appendChild(L),L.sheet&&L.sheet.insertRule(`
307          [data-motion-pop-id="${l}"] {
308            position: absolute !important;
309            width: ${y}px !important;
310            height: ${_}px !important;
311            ${C}px !important;
312            ${A}px !important;
313          }
314        `),()=>{var V;(V=c.current)==null||V.removeAttribute("data-motion-pop-id"),D.contains(L)&&D.removeChild(L)}},[e]),v.jsx(x5,{isPresent:e,childRef:c,sizeRef:d,pop:a,children:a===!1?t:E.cloneElement(t,{ref:g})})}const S5=({children:t,initial:e,isPresent:n,onExitComplete:r,custom:o,presenceAffectsLayout:a,mode:l,anchorX:c,anchorY:d,root:f})=>{const p=xm(_5),g=E.useId();let x=!0,y=E.useMemo(()=>(x=!1,{id:g,initial:e,isPresent:n,custom:o,onExitComplete:_=>{p.set(_,!0);for(const S of p.values())if(!S)return;r&&r()},register:_=>(p.set(_,!1),()=>p.delete(_))}),[n,p,r]);return a&&x&&(y={...y}),E.useMemo(()=>{p.forEach((_,S)=>p.set(S,!1))},[n]),E.useEffect(()=>{!n&&!p.size&&r&&r()},[n]),t=v.jsx(b5,{pop:l==="popLayout",isPresent:n,anchorX:c,anchorY:d,root:f,children:t}),v.jsx(Jc.Provider,{value:y,children:t})};function _5(){return new Map}function K_(t=!0){const e=E.useContext(Jc);if(e===null)return[!0,null];const{isPresent:n,onExitComplete:r,register:o}=e,a=E.useId();E.useEffect(()=>{if(t)return o(a)},[t]);const l=E.useCallback(()=>t&&r&&r(a),[a,r,t]);return!n&&r?[!1,l]:[!0]}const Ju=t=>t.key||"";function hx(t){const e=[];
vendor: 5,402 bytes, line 314
314return E.Children.forEach(t,n=>{E.isValidElement(n)&&e.push(n)}),e}const fx=({children:t,custom:e,initial:n=!0,onExitComplete:r,presenceAffectsLayout:o=!0,mode:a="sync",propagate:l=!1,anchorX:c="left",anchorY:d="top",root:f})=>{const[p,g]=K_(l),x=E.useMemo(()=>hx(t),[t]),y=l&&!p?[]:x.map(Ju),_=E.useRef(!0),S=E.useRef(x),b=xm(()=>new Map),k=E.useRef(new Set),[P,C]=E.useState(x),[A,L]=E.useState(x);xS(()=>{_.current=!1,S.current=x;for(let z=0;z<A.length;z++){const q=Ju(A[z]);y.includes(q)?(b.delete(q),k.current.delete(q)):b.get(q)!==!0&&b.set(q,!1)}},[A,y.length,y.join("-")]);const D=[];if(x!==P){let z=[...x];for(let q=0;q<A.length;q++){const H=A[q],te=Ju(H);y.includes(te)||(z.splice(q,0,H),D.push(H))}return a==="wait"&&D.length&&(z=D),L(hx(z)),C(x),null}const{forceRender:V}=E.useContext(wm);return v.jsx(v.Fragment,{children:A.map(z=>{const q=Ju(z),H=l&&!p?!1:x===A||y.includes(q),te=()=>{if(k.current.has(q))return;if(b.has(q))k.current.add(q),b.set(q,!0);else return;let Z=!0;b.forEach(me=>{me||(Z=!1)}),Z&&(V==null||V(),L(S.current),l&&(g==null||g()),r&&r())};return v.jsx(S5,{isPresent:H,initial:!_.current||n?void 0:!1,custom:e,presenceAffectsLayout:o,mode:a,root:f,onExitComplete:H?void 0:te,anchorX:c,anchorY:d,children:z},q)})})},G_=E.createContext({strict:!1}),px={animation:["animate","variants","whileHover","whileTap","exit","whileInView","whileFocus","whileDrag"],exit:["exit"],drag:["drag","dragControls"],focus:["whileFocus"],hover:["whileHover","onHoverStart","onHoverEnd"],tap:["whileTap","onTap","onTapStart","onTapCancel"],pan:["onPan","onPanStart","onPanSessionStart","onPanEnd"],inView:["whileInView","onViewportEnter","onViewportLeave"],layout:["layout","layoutId"]};let mx=!1;function E5(){if(mx)return;const t={};for(const e in px)t[e]={isEnabled:n=>px[e].some(r=>!!n[r])};__(t),mx=!0}function Q_(){return E5(),lM()}function T5(t){const e=Q_();for(const n in t)e[n]={...e[n],...t[n]};__(e)}const k5=new Set(["animate","exit","variants","initial","style","values","variants","transition","transformTemplate","custom","inherit","onBeforeLayoutMeasure","onAnimationStart","onAnimationComplete","onUpdate","onDragStart","onDrag","onDragEnd","onMeasureDragConstraints","onDirectionLock","onDragTransitionEnd","_dragX","_dragY","onHoverStart","onHoverEnd","onViewportEnter","onViewportLeave","globalTapTarget","propagate","ignoreStrict","viewport"]);function Ac(t){return t.startsWith("while")||t.startsWith("drag")&&t!=="draggable"||t.startsWith("layout")||t.startsWith("onTap")||t.startsWith("onPan")||t.startsWith("onLayout")||k5.has(t)}let Y_=t=>!Ac(t);function C5(t){typeof t=="function"&&(Y_=e=>e.startsWith("on")?!Ac(e):t(e))}try{C5(require("@emotion/is-prop-valid").default)}catch{}function P5(t,e,n){const r={};for(const o in t)o==="values"&&typeof t.values=="object"||_t(t[o])||(Y_(o)||n===!0&&Ac(o)||!e&&!Ac(o)||t.draggable&&o.startsWith("onDrag"))&&(r[o]=t[o]);return r}const td=E.createContext({});function A5(t,e){if(ed(t)){const{initial:n,animate:r}=t;return{initial:n===!1||nl(n)?n:void 0,animate:nl(r)?r:void 0}}return t.inherit!==!1?e:{}}function R5(t){const{initial:e,animate:n}=A5(t,E.useContext(td));return E.useMemo(()=>({initial:e,animate:n}),[gx(e),gx(n)])}function gx(t){return Array.isArray(t)?t.join(" "):t}const qm=()=>({style:{},transform:{},transformOrigin:{},vars:{}});function J_(t,e,n){for(const r in e)!_t(e[r])&&!R_(r,n)&&(t[r]=e[r])}function j5({transformTemplate:t},e){return E.useMemo(()=>{const n=qm();return zm(n,e,t),Object.assign({},n.vars,n.style)},[e])}function O5(t,e){const n=t.style||{},r={};return J_(r,n,t),Object.assign(r,j5(t,e)),r}function N5(t,e){const n={},r=O5(t,e);return t.drag&&t.dragListener!==!1&&(n.draggable=!1,r.userSelect=r.WebkitUserSelect=r.WebkitTouchCallout="none",r.touchAction=t.drag===!0?"none":`pan-${t.drag==="x"?"y":"x"}`),t.tabIndex===void 0&&(t.onTap||t.onTapStart||t.whileTap)&&(n.tabIndex=0),n.style=r,n}const X_=()=>({...qm(),attrs:{}});function I5(t,e,n,r){const o=E.useMemo(()=>{const a=X_();return j_(a,e,N_(r),t.transformTemplate,t.style),{...a.attrs,style:{...a.style}}},[e]);if(t.style){const a={};J_(a,t.style,t),o.style={...a,...o.style}}return o}const L5=["animate","circle","defs","desc","ellipse","g","image","line","filter","marker","mask","metadata","path","pattern","polygon","polyline","rect","stop","switch","symbol","svg","text","tspan","use","view"];function Km(t){return typeof t!="string"||t.includes("-")?!1:!!(L5.indexOf(t)>-1||/[A-Z]/u.test(t))}function D5(t,e,n,{latestValues:r},o,a=!1,l){const d=(l??Km(t)?I5:N5)(e,r,o,t),f=P5(e,typeof t=="string",a),p=t!==E.Fragment?{...f,...d,ref:n}:{},{children:g}=e,x=E.useMemo(()=>_t(g)?g.get():g,[g]);return E.createElement(t,{...p,children:x})}function M5({scrapeMotionValuesFromProps:t,createRenderState:e},n,r,o){return{latestValues:$5(n,r,o,t),renderState:e()}}function $5(t,e,n,r){const o={},a=r(t,{});for(const x in a)o[x]=dc(a[x]);let{initial:l,animate:c}=t;const d=ed(t),f=b_(t);e&&f&&!d&&t.inherit!==!1&&(l===void 0&&(l=e.initial),c===void 0&&(c=e.animate));let p=n?n.initial===!1:!1;p=p||l===!1;const g=p?c:l;if(g&&typeof g!="boolean"&&!Zc(g)){const x=Array.isArray(g)?g:[g];for(let y=0;y<x.length;y++){const _=Lm(t,x[y]);if(_){const{transitionEnd:S,transition:b,...k}=_;for(const P in k){let C=k[P];if(Array.isArray(C)){const A=p?C.length-1:0;C=C[A]}C!==null&&(o[P]=C)}for(const P in S)o[P]=S[P]}}}return o}const Z_=t=>
vendor: 27,478 bytes, line 314
314(e,n)=>{const r=E.useContext(td),o=E.useContext(Jc),a=()=>M5(t,e,r,o);return n?a():xm(a)},F5=Z_({scrapeMotionValuesFromProps:Wm,createRenderState:qm}),U5=Z_({scrapeMotionValuesFromProps:I_,createRenderState:X_}),V5=Symbol.for("motionComponentSymbol");function B5(t,e,n){const r=E.useRef(n);E.useInsertionEffect(()=>{r.current=n});const o=E.useRef(null);return E.useCallback(a=>{var c;a&&((c=t.onMount)==null||c.call(t,a));const l=r.current;if(typeof l=="function")if(a){const d=l(a);typeof d=="function"&&(o.current=d)}else o.current?(o.current(),o.current=null):l(a);else l&&(l.current=a);e&&(a?e.mount(a):e.unmount())},[e])}const eE=E.createContext({});function ro(t){return t&&typeof t=="object"&&Object.prototype.hasOwnProperty.call(t,"current")}function z5(t,e,n,r,o,a){var C,A;const{visualElement:l}=E.useContext(td),c=E.useContext(G_),d=E.useContext(Jc),f=E.useContext(Hm),p=f.reducedMotion,g=f.skipAnimations,x=E.useRef(null),y=E.useRef(!1);r=r||c.renderer,!x.current&&r&&(x.current=r(t,{visualState:e,parent:l,props:n,presenceContext:d,blockInitialAnimation:d?d.initial===!1:!1,reducedMotionConfig:p,skipAnimations:g,isSVG:a}),y.current&&x.current&&(x.current.manuallyAnimateOnMount=!0));const _=x.current,S=E.useContext(eE);_&&!_.projection&&o&&(_.type==="html"||_.type==="svg")&&W5(x.current,n,o,S);const b=E.useRef(!1);E.useInsertionEffect(()=>{_&&b.current&&_.update(n,d)});const k=n[l_],P=E.useRef(!!k&&typeof window<"u"&&!((C=window.MotionHandoffIsComplete)!=null&&C.call(window,k))&&((A=window.MotionHasOptimisedAnimation)==null?void 0:A.call(window,k)));return xS(()=>{y.current=!0,_&&(b.current=!0,window.MotionIsMounted=!0,_.updateFeatures(),_.scheduleRenderMicrotask(),P.current&&_.animationState&&_.animationState.animateChanges())}),E.useEffect(()=>{_&&(!P.current&&_.animationState&&_.animationState.animateChanges(),P.current&&(queueMicrotask(()=>{var L;(L=window.MotionHandoffMarkAsComplete)==null||L.call(window,k)}),P.current=!1),_.enteringChildren=void 0)}),_}function W5(t,e,n,r){const{layoutId:o,layout:a,drag:l,dragConstraints:c,layoutScroll:d,layoutRoot:f,layoutAnchor:p,layoutCrossfade:g}=e;t.projection=new n(t.latestValues,e["data-framer-portal-id"]?void 0:tE(t.parent)),t.projection.setOptions({layoutId:o,layout:a,alwaysMeasureLayout:!!l||c&&ro(c),visualElement:t,animationType:typeof a=="string"?a:"both",initialPromotionConfig:r,crossfade:g,layoutScroll:d,layoutRoot:f,layoutAnchor:p})}function tE(t){if(t)return t.options.allowProjection!==!1?t.projection:tE(t.parent)}function _f(t,{forwardMotionProps:e=!1,type:n}={},r,o){r&&T5(r);const a=n?n==="svg":Km(t),l=a?U5:F5;function c(f,p){let g;const x={...E.useContext(Hm),...f,layoutId:H5(f)},{isStatic:y}=x,_=R5(f),S=l(f,y);if(!y&&typeof window<"u"){q5();const b=K5(x);g=b.MeasureLayout,_.visualElement=z5(t,S,x,o,b.ProjectionNode,a)}return v.jsxs(td.Provider,{value:_,children:[g&&_.visualElement?v.jsx(g,{visualElement:_.visualElement,...x}):null,D5(t,f,B5(S,_.visualElement,p),S,y,e,a)]})}c.displayName=`motion.${typeof t=="string"?t:`create(${t.displayName??t.name??""})`}`;const d=E.forwardRef(c);return d[V5]=t,d}function H5({layoutId:t}){const e=E.useContext(wm).id;return e&&t!==void 0?e+"-"+t:t}function q5(t,e){E.useContext(G_).strict}function K5(t){const e=Q_(),{drag:n,layout:r}=e;if(!n&&!r)return{};const o={...n,...r};return{MeasureLayout:n!=null&&n.isEnabled(t)||r!=null&&r.isEnabled(t)?o.MeasureLayout:void 0,ProjectionNode:o.ProjectionNode}}function G5(t,e){if(typeof Proxy>"u")return _f;const n=new Map,r=(a,l)=>_f(a,l,t,e),o=(a,l)=>r(a,l);return new Proxy(o,{get:(a,l)=>l==="create"?r:(n.has(l)||n.set(l,_f(l,void 0,t,e)),n.get(l))})}const Q5=(t,e)=>e.isSVG??Km(t)?new TM(e):new wM(e,{allowProjection:t!==E.Fragment});class Y5 extends ks{constructor(e){super(e),e.animationState||(e.animationState=RM(e))}updateAnimationControlsSubscription(){const{animate:e}=this.node.getProps();Zc(e)&&(this.unmountControls=e.subscribe(this.node))}mount(){this.updateAnimationControlsSubscription()}update(){const{animate:e}=this.node.getProps(),{animate:n}=this.node.prevProps||{};e!==n&&this.updateAnimationControlsSubscription()}unmount(){var e;this.node.animationState.reset(),(e=this.unmountControls)==null||e.call(this)}}let J5=0;class X5 extends ks{constructor(){super(...arguments),this.id=J5++,this.isExitComplete=!1}update(){var a;if(!this.node.presenceContext)return;const{isPresent:e,onExitComplete:n}=this.node.presenceContext,{isPresent:r}=this.node.prevPresenceContext||{};if(!this.node.animationState||e===r)return;if(e&&r===!1){if(this.isExitComplete){const{initial:l,custom:c}=this.node.getProps();if(typeof l=="string"){const d=mi(this.node,l,c);if(d){const{transition:f,transitionEnd:p,...g}=d;for(const x in g)(a=this.node.getValue(x))==null||a.jump(g[x])}}this.node.animationState.reset(),this.node.animationState.animateChanges()}else this.node.animationState.setActive("exit",!1);this.isExitComplete=!1;return}const o=this.node.animationState.setActive("exit",!e);n&&!e&&o.then(()=>{this.isExitComplete=!0,n(this.id)})}mount(){const{register:e,onExitComplete:n}=this.node.presenceContext||{};n&&n(this.id),e&&(this.unmount=e(this.id))}unmount(){}}const Z5={animation:{Feature:Y5},exit:{Feature:X5}};function bl(t){return{point:{x:t.pageX,y:t.pageY}}}const e4=t=>e=>Fm(e)&&t(e,bl(e));function Fa(t,e,n,r){return rl(t,e,e4(n),r)}const nE=({current:t})=>t?t.ownerDocument.defaultView:null,yx=(t,e)=>Math.abs(t-e);function t4(t,e){const n=yx(t.x,e.x),r=yx(t.y,e.y);return Math.sqrt(n**2+r**2)}const vx=new Set(["auto","scroll"]);class rE{constructor(e,n,{transformPagePoint:r,contextWindow:o=window,dragSnapToOrigin:a=!1,distanceThreshold:l=3,element:c}={}){if(this.startEvent=null,this.lastMoveEvent=null,this.lastMoveEventInfo=null,this.lastRawMoveEventInfo=null,this.handlers={},this.contextWindow=window,this.scrollPositions=new Map,this.removeScrollListeners=null,this.onElementScroll=y=>{this.handleScroll(y.target)},this.onWindowScroll=()=>{this.handleScroll(window)},this.updatePoint=()=>{if(!(this.lastMoveEvent&&this.lastMoveEventInfo))return;this.lastRawMoveEventInfo&&(this.lastMoveEventInfo=Xu(this.lastRawMoveEventInfo,this.transformPagePoint));const y=Ef(this.lastMoveEventInfo,this.history),_=this.startEvent!==null,S=t4(y.offset,{x:0,y:0})>=this.distanceThreshold;if(!_&&!S)return;const{point:b}=y,{timestamp:k}=bt;this.history.push({...b,timestamp:k});const{onStart:P,onMove:C}=this.handlers;_||(P&&P(this.lastMoveEvent,y),this.startEvent=this.lastMoveEvent),C&&C(this.lastMoveEvent,y)},this.handlePointerMove=(y,_)=>{this.lastMoveEvent=y,this.lastRawMoveEventInfo=_,this.lastMoveEventInfo=Xu(_,this.transformPagePoint),Ue.update(this.updatePoint,!0)},this.handlePointerUp=(y,_)=>{this.end();const{onEnd:S,onSessionEnd:b,resumeAnimation:k}=this.handlers;if((this.dragSnapToOrigin||!this.startEvent)&&k&&k(),!(this.lastMoveEvent&&this.lastMoveEventInfo))return;const P=Ef(y.type==="pointercancel"?this.lastMoveEventInfo:Xu(_,this.transformPagePoint),this.history);this.startEvent&&S&&S(y,P),b&&b(y,P)},!Fm(e))return;this.dragSnapToOrigin=a,this.handlers=n,this.transformPagePoint=r,this.distanceThreshold=l,this.contextWindow=o||window;const d=bl(e),f=Xu(d,this.transformPagePoint),{point:p}=f,{timestamp:g}=bt;this.history=[{...p,timestamp:g}];const{onSessionStart:x}=n;x&&x(e,Ef(f,this.history)),this.removeListeners=vl(Fa(this.contextWindow,"pointermove",this.handlePointerMove),Fa(this.contextWindow,"pointerup",this.handlePointerUp),Fa(this.contextWindow,"pointercancel",this.handlePointerUp)),c&&this.startScrollTracking(c)}startScrollTracking(e){let n=e.parentElement;for(;n;){const r=getComputedStyle(n);(vx.has(r.overflowX)||vx.has(r.overflowY))&&this.scrollPositions.set(n,{x:n.scrollLeft,y:n.scrollTop}),n=n.parentElement}this.scrollPositions.set(window,{x:window.scrollX,y:window.scrollY}),window.addEventListener("scroll",this.onElementScroll,{capture:!0}),window.addEventListener("scroll",this.onWindowScroll),this.removeScrollListeners=()=>{window.removeEventListener("scroll",this.onElementScroll,{capture:!0}),window.removeEventListener("scroll",this.onWindowScroll)}}handleScroll(e){const n=this.scrollPositions.get(e);if(!n)return;const r=e===window,o=r?{x:window.scrollX,y:window.scrollY}:{x:e.scrollLeft,y:e.scrollTop},a={x:o.x-n.x,y:o.y-n.y};a.x===0&&a.y===0||(r?this.lastMoveEventInfo&&(this.lastMoveEventInfo.point.x+=a.x,this.lastMoveEventInfo.point.y+=a.y):this.history.length>0&&(this.history[0].x-=a.x,this.history[0].y-=a.y),this.scrollPositions.set(e,o),Ue.update(this.updatePoint,!0))}updateHandlers(e){this.handlers=e}end(){this.removeListeners&&this.removeListeners(),this.removeScrollListeners&&this.removeScrollListeners(),this.scrollPositions.clear(),Es(this.updatePoint)}}function Xu(t,e){return e?{point:e(t.point)}:t}function wx(t,e){return{x:t.x-e.x,y:t.y-e.y}}function Ef({point:t},e){return{point:t,delta:wx(t,sE(e)),offset:wx(t,n4(e)),velocity:r4(e,.1)}}function n4(t){return t[0]}function sE(t){return t[t.length-1]}function r4(t,e){if(t.length<2)return{x:0,y:0};let n=t.length-1,r=null;const o=sE(t);for(;n>=0&&(r=t[n],!(o.timestamp-r.timestamp>sn(e)));)n--;if(!r)return{x:0,y:0};r===t[0]&&t.length>2&&o.timestamp-r.timestamp>sn(e)*2&&(r=t[1]);const a=yn(o.timestamp-r.timestamp);if(a===0)return{x:0,y:0};const l={x:(o.x-r.x)/a,y:(o.y-r.y)/a};return l.x===1/0&&(l.x=0),l.y===1/0&&(l.y=0),l}function s4(t,{min:e,max:n},r){return e!==void 0&&t<e?t=r?qe(e,t,r.min):Math.max(t,e):n!==void 0&&t>n&&(t=r?qe(n,t,r.max):Math.min(t,n)),t}function xx(t,e,n){return{min:e!==void 0?t.min+e:void 0,max:n!==void 0?t.max+n-(t.max-t.min):void 0}}function i4(t,{top:e,left:n,bottom:r,right:o}){return{x:xx(t.x,n,o),y:xx(t.y,e,r)}}function bx(t,e){let n=e.min-t.min,r=e.max-t.max;return e.max-e.min<t.max-t.min&&([n,r]=[r,n]),{min:n,max:r}}function o4(t,e){return{x:bx(t.x,e.x),y:bx(t.y,e.y)}}function a4(t,e){let n=.5;const r=Lt(t),o=Lt(e);return o>r?n=el(e.min,e.max-r,t.min):r>o&&(n=el(t.min,t.max-o,e.min)),ur(0,1,n)}function l4(t,e){const n={};return e.min!==void 0&&(n.min=e.min-t.min),e.max!==void 0&&(n.max=e.max-t.min),n}const Bp=.35;function u4(t=Bp){return t===!1?t=0:t===!0&&(t=Bp),{x:Sx(t,"left","right"),y:Sx(t,"top","bottom")}}function Sx(t,e,n){return{min:_x(t,e),max:_x(t,n)}}function _x(t,e){return typeof t=="number"?t:t[e]||0}const c4=new WeakMap;class d4{constructor(e){this.openDragLock=null,this.isDragging=!1,this.currentDirection=null,this.originPoint={x:0,y:0},this.constraints=!1,this.hasMutatedConstraints=!1,this.elastic=ct(),this.latestPointerEvent=null,this.latestPanInfo=null,this.visualElement=e}start(e,{snapToCursor:n=!1,distanceThreshold:r}={}){const{presenceContext:o}=this.visualElement;if(o&&o.isPresent===!1)return;const a=g=>{n&&this.snapToCursor(bl(g).point),this.stopAnimation()},l=(g,x)=>{const{drag:y,dragPropagation:_,onDragStart:S}=this.getProps();if(y&&!_&&(this.openDragLock&&this.openDragLock(),this.openDragLock=$D(y),!this.openDragLock))return;this.latestPointerEvent=g,this.latestPanInfo=x,this.isDragging=!0,this.currentDirection=null,this.resolveConstraints(),this.visualElement.projection&&(this.visualElement.projection.isAnimationBlocked=!0,this.visualElement.projection.target=void 0),tr(k=>{let P=this.getAxisMotionValue(k).get()||0;if(lr.test(P)){const{projection:C}=this.visualElement;if(C&&C.layout){const A=C.layout.layoutBox[k];A&&(P=Lt(A)*(parseFloat(P)/100))}}this.originPoint[k]=P}),S&&Ue.update(()=>S(g,x),!1,!0),Np(this.visualElement,"transform");const{animationState:b}=this.visualElement;b&&b.setActive("whileDrag",!0)},c=(g,x)=>{this.latestPointerEvent=g,this.latestPanInfo=x;const{dragPropagation:y,dragDirectionLock:_,onDirectionLock:S,onDrag:b}=this.getProps();if(!y&&!this.openDragLock)return;const{offset:k}=x;if(_&&this.currentDirection===null){this.currentDirection=f4(k),this.currentDirection!==null&&S&&S(this.currentDirection);return}this.updateAxis("x",x.point,k),this.updateAxis("y",x.point,k),this.visualElement.render(),b&&Ue.update(()=>b(g,x),!1,!0)},d=(g,x)=>{this.latestPointerEvent=g,this.latestPanInfo=x,this.stop(g,x),this.latestPointerEvent=null,this.latestPanInfo=null},f=()=>{const{dragSnapToOrigin:g}=this.getProps();(g||this.constraints)&&this.startAnimation({x:0,y:0})},{dragSnapToOrigin:p}=this.getProps();this.panSession=new rE(e,{onSessionStart:a,onStart:l,onMove:c,onSessionEnd:d,resumeAnimation:f},{transformPagePoint:this.visualElement.getTransformPagePoint(),dragSnapToOrigin:p,distanceThreshold:r,contextWindow:nE(this.visualElement),element:this.visualElement.current})}stop(e,n){const r=e||this.latestPointerEvent,o=n||this.latestPanInfo,a=this.isDragging;if(this.cancel(),!a||!o||!r)return;const{velocity:l}=o;this.startAnimation(l);const{onDragEnd:c}=this.getProps();c&&Ue.postRender(()=>c(r,o))}cancel(){this.isDragging=!1;const{projection:e,animationState:n}=this.visualElement;e&&(e.isAnimationBlocked=!1),this.endPanSession();const{dragPropagation:r}=this.getProps();!r&&this.openDragLock&&(this.openDragLock(),this.openDragLock=null),n&&n.setActive("whileDrag",!1)}endPanSession(){this.panSession&&this.panSession.end(),this.panSession=void 0}updateAxis(e,n,r){const{drag:o}=this.getProps();if(!r||!Zu(e,o,this.currentDirection))return;const a=this.getAxisMotionValue(e);let l=this.originPoint[e]+r[e];this.constraints&&this.constraints[e]&&(l=s4(l,this.constraints[e],this.elastic[e])),a.set(l)}resolveConstraints(){var a;const{dragConstraints:e,dragElastic:n}=this.getProps(),r=this.visualElement.projection&&!this.visualElement.projection.layout?this.visualElement.projection.measure(!1):(a=this.visualElement.projection)==null?void 0:a.layout,o=this.constraints;e&&ro(e)?this.constraints||(this.constraints=this.resolveRefConstraints()):e&&r?this.constraints=i4(r.layoutBox,e):this.constraints=!1,this.elastic=u4(n),o!==this.constraints&&!ro(e)&&r&&this.constraints&&!this.hasMutatedConstraints&&tr(l=>{this.constraints!==!1&&this.getAxisMotionValue(l)&&(this.constraints[l]=l4(r.layoutBox[l],this.constraints[l]))})}resolveRefConstraints(){const{dragConstraints:e,onMeasureDragConstraints:n}=this.getProps();if(!e||!ro(e))return!1;const r=e.current,{projection:o}=this.visualElement;if(!o||!o.layout)return!1;const a=fM(r,o.root,this.visualElement.getTransformPagePoint());let l=o4(o.layout.layoutBox,a);if(n){const c=n(cM(l));this.hasMutatedConstraints=!!c,c&&(l=T_(c))}return l}startAnimation(e){const{drag:n,dragMomentum:r,dragElastic:o,dragTransition:a,dragSnapToOrigin:l,onDragTransitionEnd:c}=this.getProps(),d=this.constraints||{},f=tr(p=>{if(!Zu(p,n,this.currentDirection))return;let g=d&&d[p]||{};(l===!0||l===p)&&(g={min:0,max:0});const x=o?200:1e6,y=o?40:1e7,_={type:"inertia",velocity:r?e[p]:0,bounceStiffness:x,bounceDamping:y,timeConstant:750,restDelta:1,restSpeed:10,...a,...g};return this.startAxisValueAnimation(p,_)});return Promise.all(f).then(c)}startAxisValueAnimation(e,n){const r=this.getAxisMotionValue(e);return Np(this.visualElement,e),r.start(Im(e,r,0,n,this.visualElement,!1))}stopAnimation(){tr(e=>this.getAxisMotionValue(e).stop())}getAxisMotionValue(e){const n=`_drag${e.toUpperCase()}`,r=this.visualElement.getProps(),o=r[n];return o||this.visualElement.getValue(e,(r.initial?r.initial[e]:void 0)||0)}snapToCursor(e){tr(n=>{const{drag:r}=this.getProps();if(!Zu(n,r,this.currentDirection))return;const{projection:o}=this.visualElement,a=this.getAxisMotionValue(n);if(o&&o.layout){const{min:l,max:c}=o.layout.layoutBox[n],d=a.get()||0;a.set(e[n]-qe(l,c,.5)+d)}})}scalePositionWithinConstraints(){if(!this.visualElement.current)return;const{drag:e,dragConstraints:n}=this.getProps(),{projection:r}=this.visualElement;if(!ro(n)||!r||!this.constraints)return;this.stopAnimation();const o={x:0,y:0};tr(l=>{const c=this.getAxisMotionValue(l);if(c&&this.constraints!==!1){const d=c.get();o[l]=a4({min:d,max:d},this.constraints[l])}});const{transformTemplate:a}=this.visualElement.getProps();this.visualElement.current.style.transform=a?a({},""):"none",r.root&&r.root.updateScroll(),r.updateLayout(),this.constraints=!1,this.resolveConstraints(),tr(l=>{if(!Zu(l,e,null))return;const c=this.getAxisMotionValue(l),{min:d,max:f}=this.constraints[l];c.set(qe(d,f,o[l]))}),this.visualElement.render()}addListeners(){if(!this.visualElement.current)return;c4.set(this.visualElement,this);const e=this.visualElement.current,n=Fa(e,"pointerdown",f=>{const{drag:p,dragListener:g=!0}=this.getProps(),x=f.target,y=x!==e&&WD(x);p&&g&&!y&&this.start(f)});let r;const o=()=>{const{dragConstraints:f}=this.getProps();ro(f)&&f.current&&(this.constraints=this.resolveRefConstraints(),r||(r=h4(e,f.current,()=>this.scalePositionWithinConstraints())))},{projection:a}=this.visualElement,l=a.addEventListener("measure",o);a&&!a.layout&&(a.root&&a.root.updateScroll(),a.updateLayout()),Ue.read(o);const c=rl(window,"resize",()=>this.scalePositionWithinConstraints()),d=a.addEventListener("didUpdate",(({delta:f,hasLayoutChanged:p})=>{this.isDragging&&p&&(tr(g=>{const x=this.getAxisMotionValue(g);x&&(this.originPoint[g]+=f[g].translate,x.set(x.get()+f[g].translate))}),this.visualElement.render())}));return()=>{c(),n(),l(),d&&d(),r&&r()}}getProps(){const e=this.visualElement.getProps(),{drag:n=!1,dragDirectionLock:r=!1,dragPropagation:o=!1,dragConstraints:a=!1,dragElastic:l=Bp,dragMomentum:c=!0}=e;return{...e,drag:n,dragDirectionLock:r,dragPropagation:o,dragConstraints:a,dragElastic:l,dragMomentum:c}}}function Ex(t){let e=!0;return()=>{if(e){e=!1;return}t()}}function h4(t,e,n){const r=Rw(t,Ex(n)),o=Rw(e,Ex(n));return()=>{r(),o()}}function Zu(t,e,n){return(e===!0||e===t)&&(n===null||n===t)}function f4(t,e=10){let n=null;return Math.abs(t.y)>e?n="y":Math.abs(t.x)>e&&(n="x"),n}class p4 extends ks{constructor(e){super(e),this.removeGroupControls=vn,this.removeListeners=vn,this.controls=new d4(e)}mount(){const{dragControls:e}=this.node.getProps();e&&(this.removeGroupControls=e.subscribe(this.controls)),this.removeListeners=this.controls.addListeners()||vn}update(){const{dragControls:e}=this.node.getProps(),{dragControls:n}=this.node.prevProps||{};e!==n&&(this.removeGroupControls(),e&&(this.removeGroupControls=e.subscribe(this.controls)))}unmount(){this.removeGroupControls(),this.removeListeners(),this.controls.isDragging||this.controls.endPanSession()}}const Tf=t=>(e,n)=>{t&&Ue.update(()=>t(e,n),!1,!0)};class m4 extends ks{constructor(){super(...arguments),this.removePointerDownListener=vn}onPointerDown(e){this.session=new rE(e,this.createPanHandlers(),{transformPagePoint:this.node.getTransformPagePoint(),contextWindow:nE(this.node)})}createPanHandlers(){const{onPanSessionStart:e,onPanStart:n,onPan:r,onPanEnd:o}=this.node.getProps();return{onSessionStart:Tf(e),onStart:Tf(n),onMove:Tf(r),onEnd:(a,l)=>{delete this.session,o&&Ue.postRender(()=>o(a,l))}}}mount(){this.removePointerDownListener=Fa(this.node.current,"pointerdown",e=>this.onPointerDown(e))}update(){this.session&&this.session.updateHandlers(this.createPanHandlers())}unmount(){this.removePointerDownListener(),this.session&&this.session.end()}}let kf=!1;class g4 extends E.Component{componentDidMount(){const{visualElement:e,layoutGroup:n,switchLayoutGroup:r,layoutId:o}=this.props,{projection:a}=e;a&&(n.group&&n.group.add(a),r&&r.register&&o&&r.register(a),kf&&a.root.didUpdate(),a.addEventListener("animationComplete",()=>{this.safeToRemove()}),a.setOptions({...a.options,layoutDependency:this.props.layoutDependency,onExitComplete:()=>this.safeToRemove()})),hc.hasEverUpdated=!0}getSnapshotBeforeUpdate(e){const{layoutDependency:n,visualElement:r,drag:o,isPresent:a}=this.props,{projection:l}=r;return l&&(l.isPresent=a,e.layoutDependency!==n&&l.setOptions({...l.options,layoutDependency:n}),kf=!0,o||e.layoutDependency!==n||n===void 0||e.isPresent!==a?l.willUpdate():this.safeToRemove(),e.isPresent!==a&&(a?l.promote():l.relegate()||Ue.postRender(()=>{const c=l.getStack();(!c||!c.members.length)&&this.safeToRemove()}))),null}componentDidUpdate(){const{visualElement:e,layoutAnchor:n}=this.props,{projection:r}=e;r&&(r.options.layoutAnchor=n,r.root.didUpdate(),$m.postRender(()=>{!r.currentAnimation&&r.isLead()&&this.safeToRemove()}))}componentWillUnmount(){const{visualElement:e,layoutGroup:n,switchLayoutGroup:r}=this.props,{projection:o}=e;kf=!0,o&&(o.scheduleCheckAfterUnmount(),n&&n.group&&n.group.remove(o),r&&r.deregister&&r.deregister(o))}safeToRemove(){const{safeToRemove:e}=this.props;e&&e()}render(){return null}}function iE(t){const[e,n]=K_(),r=E.useContext(wm);return v.jsx(g4,{...t,layoutGroup:r,switchLayoutGroup:E.useContext(eE),isPresent:e,safeToRemove:n})}const y4={pan:{Feature:m4},drag:{Feature:p4,ProjectionNode:q_,MeasureLayout:iE}};function Tx(t,e,n){const{props:r}=t;t.animationState&&r.whileHover&&t.animationState.setActive("whileHover",n==="Start");const o="onHover"+n,a=r[o];a&&Ue.postRender(()=>a(e,bl(e)))}class v4 extends ks{mount(){const{current:e}=this.node;e&&(this.unmount=UD(e,(n,r)=>(Tx(this.node,r,"Start"),o=>Tx(this.node,o,"End"))))}unmount(){}}class w4 extends ks{constructor(){super(...arguments),this.isActive=!1}onFocus(){let e=!1;try{e=this.node.current.matches(":focus-visible")}catch{e=!0}!e||!this.node.animationState||(this.node.animationState.setActive("whileFocus",!0),this.isActive=!0)}onBlur(){!this.isActive||!this.node.animationState||(this.node.animationState.setActive("whileFocus",!1),this.isActive=!1)}mount(){this.unmount=vl(rl(this.node.current,"focus",()=>this.onFocus()),rl(this.node.current,"blur",()=>this.onBlur()))}unmount(){}}function kx(t,e,n){const{props:r}=t;if(t.current instanceof HTMLButtonElement&&t.current.disabled)return;t.animationState&&r.whileTap&&t.animationState.setActive("whileTap",n==="Start");const o="onTap"+(n==="End"?"":n),a=r[o];a&&Ue.postRender(()=>a(e,bl(e)))}class x4 extends ks{mount(){const{current:e}=this.node;if(!e)return;const{globalTapTarget:n,propagate:r}=this.node.props;this.unmount=qD(e,(o,a)=>(kx(this.node,a,"Start"),(l,{success:c})=>kx(this.node,l,c?"End":"Cancel")),{useGlobalTarget:n,stopPropagation:(r==null?void 0:r.tap)===!1})}unmount(){}}const zp=new WeakMap,Cf=new WeakMap,b4=t=>{const e=zp.get(t.target);e&&e(t)},S4=t=>{t.forEach(b4)};function _4({root:t,...e}){const n=t||document;Cf.has(n)||Cf.set(n,{});const r=Cf.get(n),o=JSON.stringify(e);return r[o]||(r[o]=new IntersectionObserver(S4,{root:t,...e})),r[o]}function E4(t,e,n){const r=_4(e);return zp.set(t,n),r.observe(t),()=>{zp.delete(t),r.unobserve(t)}}const T4={some:0,all:1};class k4 extends ks{constructor(){super(...arguments),this.hasEnteredView=!1,this.isInView=!1}startObserver(){var d;(d=this.stopObserver)==null||d.call(this);const{viewport:e={}}=this.node.getProps(),{root:n,margin:r,amount:o="some",once:a}=e,l={root:n?n.current:void 0,rootMargin:r,threshold:typeof o=="number"?o:T4[o]},c=f=>{const{isIntersecting:p}=f;if(this.isInView===p||(this.isInView=p,a&&!p&&this.hasEnteredView))return;p&&(this.hasEnteredView=!0),this.node.animationState&&this.node.animationState.setActive("whileInView",p);const{onViewportEnter:g,onViewportLeave:x}=this.node.getProps(),y=p?g:x;y&&y(f)};this.stopObserver=E4(this.node.current,l,c)}mount(){this.startObserver()}update(){if(typeof IntersectionObserver>"u")return;const{props:e,prevProps:n}=this.node;["amount","margin","root"].some(C4(e,n))&&this.startObserver()}unmount(){var e;(e=this.stopObserver)==null||e.call(this),this.hasEnteredView=!1,this.isInView=!1}}function C4({viewport:t={}},{viewport:e={}}={}){return n=>t[n]!==e[n]}const P4={inView:{Feature:k4},tap:{Feature:x4},focus:{Feature:w4},hover:{Feature:v4}},A4={layout:{ProjectionNode:q_,MeasureLayout:iE}},R4={...Z5,...P4,...y4,...A4},xe=G5(R4,Q5),j4={bronze:{label:"Bronze",color:"hsl(30, 60%, 50%)",gradient:"linear-gradient(135deg, hsl(30, 50%, 45%), hsl(25, 70%, 60%))",glowColor:"hsl(30, 60%, 50%)"},silver:{label:"Silver",color:"hsl(210, 10%, 65%)",gradient:"linear-gradient(135deg, hsl(210, 15%, 55%), hsl(210, 20%, 80%))",glowColor:"hsl(210, 15%, 70%)"},gold:{label:"Gold",color:"hsl(45, 90%, 50%)",gradient:"linear-gradient(135deg, hsl(40, 80%, 45%), hsl(50, 95%, 60%))",glowColor:"hsl(45, 90%, 55%)"},platinum:{label:"Platinum",color:"hsl(260, 60%, 60%)",gradient:"linear-gradient(135deg, hsl(260, 50%, 50%), hsl(280, 70%, 70%))",glowColor:"hsl(270, 60%, 65%)"}},O4=[{id:"first_agent",label:"첫 에이전트",description:"첫 번째 AI 투자 에이전트를 생성했습니다",condition:"에이전트 1개 생성",tier:"bronze",emoji:"🤖"},{id:"first_backtest",label:"첫 백테스트",description:"첫 백테스트를 실행했습니다",condition:"백테스트 1회 실행",tier:"bronze",emoji:"📊"},{id:"first_api",label:"API 연동 시작",description:"첫 금융 API를 연동했습니다",condition:"API 1개 연동",tier:"bronze",emoji:"🔗"},{id:"agents_5",label:"에이전트 빌더",description:"5개의 에이전트를 완성했습니다",condition:"에이전트 5개 완성",tier:"silver",emoji:"⚙️"},{id:"streak_3",label:"꾸준한 트레이더",description:"3일 연속 실습에 성공했습니다",condition:"3일 연속 실습",tier:"silver",emoji:"🔥"},{id:"first_profit_sim",label:"첫 수익 시뮬레이션",description:"수익 시뮬레이션을 처음 완료했습니다",condition:"수익 시뮬레이션 완료",tier:"silver",emoji:"💰"},{id:"layer1_master",label:"분석 마스터",description:"레이어 1 분석형 에이전트를 모두 완성했습니다",condition:"레이어 1 마스터",tier:"gold",emoji:"🏔️"},{id:"portfolio_build",label:"포트폴리오 설계자",description:"실전 포트폴리오를 구성했습니다",condition:"실전 포트폴리오 구성",tier:"gold",emoji:"📈"},{id:"quiz_perfect",label:"완벽한 분석",description:"퀴즈에서 만점을 받았습니다",condition:"퀴즈 만점 달성",tier:"gold",emoji:"💎"},{id:"all_agents",label:"에이전트 아키텍트",description:"12개 에이전트를 모두 완성했습니다",condition:"12개 에이전트 완성",tier:"platinum",emoji:"🏆"},{id:"grand_master",label:"그랜드 마스터",description:"모든 학습 콘텐츠를 완료했습니다",condition:"전체 과정 완료",tier:"platinum",emoji:"🌟"},{id:"certificate",label:"수료 마스터",description:"과정 수료증을 획득했습니다",condition:"수료증 획득",tier:"platinum",emoji:"👑"}],Cx=[{minLevel:1,title:"입문자",emoji:"🌱"},{minLevel:3,title:"트레이더",emoji:"📈"},{minLevel:5,title:"애널리스트",emoji:"🔬"},{minLevel:7,title:"퀀트",emoji:"🧮"},{minLevel:10,title:"전략가",emoji:"🎯"},{minLevel:13,title:"포트폴리오 매니저",emoji:"💼"},{minLevel:15,title:"에이전트 마스터",emoji:"🤖"},{minLevel:18,title:"투자 현자",emoji:"🧙"},{minLevel:20,title:"그랜드마스터",emoji:"👑"}];function N4(t){return[...Cx].reverse().find(n=>t>=n.minLevel)||Cx[0]}function u$(t){return(t-1)*(t-1)*100}function c$(t){return t*t*100}const oE=E.createContext({triggerLevelUp:()=>{},triggerBadgeEarned:()=>{}}),d$=()=>E.useContext(oE),Px=["hsl(45, 90%, 55%)","hsl(260, 60%, 60%)","hsl(221, 83%, 53%)","hsl(142, 71%, 45%)","hsl(0, 84%, 60%)","hsl(30, 80%, 55%)"];function aE(t){return Array.from({length:t},(e,n)=>({id:n,x:50+(Math.random()-.5)*60,y:40,rotation:Math.random()*360,color:Px[Math.floor(Math.random()*Px.length)],size:6+Math.random()*8,delay:Math.random()*.3,dx:(Math.random()-.5)*80,shape:["square","circle","triangle"][Math.floor(Math.random()*3)]}))}const lE=({particle:t})=>{const e=t.shape==="circle"?{borderRadius:"50%"}
314:t.shape==="triangle"?{clipPath:"polygon(50% 0%, 0% 100%, 100% 100%)"}:{};return v.jsx(xe.div,{className:"pointer-events-none absolute",style:{left:`${t.x}%`,top:`${t.y}%`,width:t.size,height:t.size,backgroundColor:t.color,...e},initial:{opacity:1,y:0,x:0,rotate:0,scale:1},animate:{opacity:[1,1,0],y:[0,-120-Math.random()*80,300+Math.random()*200],x:[0,t.dx*.5,t.dx],rotate:[0,t.rotation,t.rotation*2],scale:[0,1.2,.6]},transition:{duration:2,delay:t.delay,ease:[.2,0,.2,1]}})},I4=({level:t,onClose:e})=>{const n=N4(t),[r]=E.useState(()=>aE(50));return E.useEffect(()=>{const o=setTimeout(e,3500);return()=>clearTimeout(o)},[e]),v.jsxs(xe.div,{className:"fixed inset-0 z-[9999] flex items-center justify-center",initial:{opacity:0},animate:{opacity:1},exit:{opacity:0},transition:{duration:.3},onClick:e,children:[v.jsx(xe.div,{className:"absolute inset-0 bg-black/60 backdrop-blur-sm",initial:{opacity:0},animate:{opacity:1},exit:{opacity:0}}),v.jsx("div",{className:"absolute inset-0 overflow-hidden pointer-events-none",children:r.map(o=>v.jsx(lE,{particle:o},o.id))}),v.jsxs(xe.div,{className:"relative flex flex-col items-center gap-4",initial:{scale:.3,opacity:0,y:40},animate:{scale:1,opacity:1,y:0},exit:{scale:.8,opacity:0,y:-20},transition:{type:"spring",stiffness:200,damping:15},children:[v.jsx(xe.div,{className:"absolute -inset-16 rounded-full",style:{background:"radial-gradient(circle, hsl(45, 90%, 55% / 0.3) 0%, transparent 70%)"},animate:{scale:[1,1.2,1],opacity:[.5,.8,.5]},transition:{duration:2,repeat:1/0,ease:"easeInOut"}}),v.jsx(xe.div,{className:"relative flex h-28 w-28 items-center justify-center rounded-full",style:{background:"linear-gradient(135deg, hsl(45, 90%, 50%), hsl(40, 80%, 60%))",boxShadow:"0 0 40px hsl(45, 90%, 50% / 0.5), 0 0 80px hsl(45, 90%, 50% / 0.2)"},animate:{rotate:[0,5,-5,0]},transition:{duration:.6,delay:.3},children:v.jsxs("div",{className:"text-center",children:[v.jsx(xe.span,{className:"block text-4xl font-bold text-white",initial:{scale:0},animate:{scale:[0,1.3,1]},transition:{duration:.5,delay:.2},children:t}),v.jsx("span",{className:"block text-[10px] font-bold uppercase tracking-widest text-white/80",children:"LEVEL UP"})]})}),v.jsxs(xe.div,{className:"text-center",initial:{opacity:0,y:16},animate:{opacity:1,y:0},transition:{delay:.4},children:[v.jsx("h2",{className:"text-2xl font-bold text-white",children:"레벨 업!"}),v.jsxs("p",{className:"mt-1 text-lg text-white/80",children:[n.emoji," ",n.title]}),v.jsx(xe.p,{className:"mt-2 text-sm text-white/50",initial:{opacity:0}
314,animate:{opacity:1},transition:{delay:.8},children:"탭하여 계속하기"})]})]})]})},L4=({badge:t,onClose:e})=>{const n=j4[t.tier];return E.useEffect(()=>{const r=setTimeout(e,3e3);return()=>clearTimeout(r)},[e]),v.jsxs(xe.div,{className:"fixed inset-0 z-[9998] flex items-center justify-center",initial:{opacity:0},animate:{opacity:1},exit:{opacity:0},transition:{duration:.3},onClick:e,children:[v.jsx(xe.div,{className:"absolute inset-0 bg-black/50 backdrop-blur-sm"}),v.jsx("div",{className:"absolute inset-0 overflow-hidden pointer-events-none",children:aE(25).map(r=>v.jsx(lE,{particle:r},r.id))}),v.jsxs(xe.div,{className:"relative flex flex-col items-center gap-4",initial:{scale:.3,opacity:0,y:30},animate:{scale:1,opacity:1,y:0},exit:{scale:.8,opacity:0},transition:{type:"spring",stiffness:220,damping:16},children:[v.jsx(xe.div,{className:"absolute -inset-12 rounded-full",style:{background:`radial-gradient(circle, ${n.glowColor}40 0%, transparent 70%)`},animate:{scale:[1,1.15,1],opacity:[.4,.7,.4]},transition:{duration:1.5,repeat:1/0,ease:"easeInOut"}}),v.jsx(xe.div,{className:"relative flex h-24 w-24 items-center justify-center rounded-full text-5xl",style:{background:n.gradient,boxShadow:`0 0 30px ${n.glowColor}60, 0 0 60px ${n.glowColor}20`},animate:{rotate:[0,8,-8,0]},transition:{duration:.5,delay:.3},children:t.emoji}),v.jsxs(xe.div,{className:"text-center",initial:{opacity:0,y:12},animate:{opacity:1,y:0},transition:{delay:.3},children:[v.jsx("h2",{className:"text-xl font-bold text-white",children:"배지 획득!"}),v.jsx("p",{className:"mt-1 text-lg font-semibold text-white",children:t.label}),v.jsx("p",{className:"mt-0.5 text-sm text-white/60",children:t.description}),v.jsx("span",{className:"mt-2 inline-block rounded-full px-3 py-0.5 text-xs font-bold text-white",style:{background:n.color},children:n.label})]})]})]})},D4=({children:t})=>{const[e,n]=E.useState(null),[r,o]=E.useState(null),a=E.useCallback(c=>{n(c)},[]),l=E.useCallback(c=>{const d=O4.find(f=>f.id===c);d&&(e!==null?setTimeout(()=>o(d),3600):o(d))},[e]);return v.jsxs(oE.Provider,{value:{triggerLevelUp:a,triggerBadgeEarned:l},children:[t,v.jsx(fx,{children:e!==null&&v.jsx(I4,{level:e,onClose:()=>n(null)})}),v.jsx(fx,{children:r!==null&&e===null&&v.jsx(L4,{badge:r,onClose:()=>o(null)})})]})},h$={admin:"메인 관리자",moderator:"일반 관리자",instructor:"강사",developer:"개발자",manager:"매니저",user:"사용자",student:"학생",parent:"학부모"},M4={admin:["users","courses","stats","content","approvals","settings","classes","reports"],moderator:["courses","stats","content","reports","users","settings"],instructor:["courses","stats","classes","assignments","grading","reports"],developer:["content","settings"],manager:["users","stats","reports"],user:[],student:["assignments","projects","growth","portfolio"],parent:["child_status","growth_reports","assignments_view"]},$4=()=>{const{user:t}=yl(),{data:e,isLoading:n}=i0({queryKey:["user-role",t==null?void 0:t.id],queryFn:async()=>{const{data:l,error:c}=await $n.rpc("get_user_role",{_user_id:t.id});if(c)throw c;return l||"user"},enabled:!!t,staleTime:300*1e3}),{data:r=!1}=i0({queryKey:["is-main-admin",t==null?void 0:t.id],queryFn:async()=>{const{data:l,error:c}=await $n.rpc("is_main_admin",{_user_id:t.id});return c?!1:!!l},enabled:!!t,staleTime:300*1e3}),o=e||"user",a=M4[o]||[];return{role:o,isAdmin:o==="admin",isStaff:["admin","moderator","instructor","developer","manager"].includes(o),isStudent:o==="student"||o==="user",isParent:o==="parent",isInstructor:o==="instructor",isMainAdmin:r,isLoading:n,permissions:a,hasPermission:l=>a.includes(l)}},Ax="G-8D305SXQMB",F4=()=>{E.useEffect(()=>{const t=document.createElement("script");return t.src=`https://www.googletagmanager.com/gtag/js?id=${Ax}`,t.async=!0,document.head.appendChild(t),window.dataLayer=window.dataLayer||[],window.gtag=function(){window.dataLayer.push(arguments)},window.gtag("js",new Date),window.gtag("config",Ax),()=>{document.head.removeChild(t)}},[])},f$=(t,e)=>{window.gtag&&window.gtag("event",t,e)};var U4=Symbol.for("react.lazy"),Rc=jc[" use ".trim().toString()];function V4(t){return typeof t=="object"&&t!==null&&"then"in t}function uE(t){return t!=null&&typeof t=="object"&&"$$typeof"in t&&t.$$typeof===U4&&"_payload"in t&&V4(t._payload)}function B4(t){const e=W4(t),n=E.forwardRef((r,o)=>{let{children:a,...l}=r;uE(a)&&typeof Rc=="function"&&(a=Rc(a._payload));const c=E.Children.toArray(a),d=c.find(q4);
314if(d){const f=d.props.children,p=c.map(g=>g===d?E.Children.count(f)>1?E.Children.only(null):E.isValidElement(f)?f.props.children:null:g);return v.jsx(e,{...l,ref:o,children:E.isValidElement(f)?E.cloneElement(f,void 0,p):null})}return v.jsx(e,{...l,ref:o,children:a})});return n.displayName=`${t}.Slot`,n}var z4=B4("Slot");function W4(t){const e=E.forwardRef((n,r)=>{let{children:o,...a}=n;if(uE(o)&&typeof Rc=="function"&&(o=Rc(o._payload)),E.isValidElement(o)){const l=G4(o),c=K4(a,o.props);return o.type!==E.Fragment&&(c.ref=r?Lc(r,l):l),E.cloneElement(o,c)}return E.Children.count(o)>1?E.Children.only(null):null});return e.displayName=`${t}.SlotClone`,e}var H4=Symbol("radix.slottable");function q4(t){return E.isValidElement(t)&&typeof t.type=="function"&&"__radixId"in t.type&&t.type.__radixId===H4}function K4(t,e){const n={...e};for(const r in e){const o=t[r],a=e[r];/^on[A-Z]/.test(r)?o&&a?n[r]=(...c)=>{const d=a(...c);return o(...c),d}:o&&(n[r]=o):r==="style"?n[r]={...o,...a}:r==="className"&&(n[r]=[o,a].filter(Boolean).join(" "))}return{...t,...n}}function G4(t){var r,o;let e=(r=Object.getOwnPropertyDescriptor(t.props,"ref"))==null?void 0:r.get,n=e&&"isReactWarning"in e&&e.isReactWarning;return n?t.ref:(e=(o=Object.getOwnPropertyDescriptor(t,"ref"))==null?void 0:o.get,n=e&&"isReactWarning"in e&&e.isReactWarning,n?t.props.ref:t.props.ref||t.ref)}const Q4=l1("inline-flex items-center justify-center gap-2 whitespace-nowrap rounded-md text-sm font-medium ring-offset-background transition-colors focus-visible:outline-none focus-visible:ring-2 focus-visible:ring-ring focus-visible:ring-offset-2 disabled:pointer-events-none disabled:opacity-50 [&_svg]:pointer-events-none [&_svg]:size-4 [&_svg]:shrink-0",{variants:{variant:{default:"bg-primary text-primary-foreground hover:bg-primary/90",destructive:"bg-destructive text-destructive-foreground hover:bg-destructive/90",outline:"border border-input bg-background hover:bg-accent hover:text-accent-foreground",secondary:"bg-secondary text-secondary-foreground hover:bg-secondary/80",ghost:"hover:bg-accent hover:text-accent-foreground",link:"text-primary underline-offset-4 hover:underline"},size:{default:"h-10 px-4 py-2",sm:"h-9 rounded-md px-3",lg:"h-11 rounded-md px-8",icon:"h-10 w-10"}},defaultVariants:{variant:"default",size:"default"}}),ni=E.forwardRef(({className:t,variant:e,size:n,asChild:r=!1,...o},a)=>{const l=r?z4:"button";return v.jsx(l,{className:Ts(Q4({variant:e,size:n,className:t})),ref:a,...o})});ni.displayName="Button";const Y4={duration:.7,ease:[.2,0,0,1]},J4={hidden:{},show:{transition:{staggerChildren:.12}}},Pa={hidden:{opacity:0,y:28},show:{opacity:1,y:0,transition:Y4}},X4=({onEnroll:t,onExplore:e,onDiagnostic:n})=>{const r=E.useRef(null),[o,a]=E.useState({x:0,y:0}),l=E.useCallback(c=>{var f;const d=(f=r.current)==null?void 0:f.getBoundingClientRect();d&&a({x:c.clientX-d.left,y:c.clientY-d.top})},[]);return v.jsxs("section",{ref:r,onMouseMove:l,className:"relative overflow-hidden hero-gradient","aria-label":"AI 투자 에이전트 교육 플랫폼 뉴와이즈 소개",children:[v.jsx("div",{className:"pointer-events-none absolute h-[900px] w-[900px] rounded-full blur-[180px] transition-transform duration-200 ease-out",style:{transform:`translate(${o.x-450}px, ${o.y-450}px)`,background:"radial-gradient(circle, hsl(45 93% 47% / 0.45) 0%, hsl(45 93% 47% / 0.2) 40%, transparent 70%)"}}),v.jsx("div",{className:"pointer-events-none absolute -top-20 -left-20 h-[600px] w-[600px] rounded-full blur-[160px]",style:{background:"radial-gradient(circle, hsl(45 93% 47% / 0.15) 0%, hsl(45 93% 47% / 0.05) 50%, transparent 70%)"}}),v.jsx("div",{className:"pointer-events-none absolute -bottom-20 -right-20 h-[600px] w-[600px] rounded-full blur-[160px]",style:{background:"radial-gradient(circle, hsl(45 93% 47% / 0.12) 0%, hsl(45 93% 47% / 0.04) 50%, transparent 70%)"}}),v.jsxs(xe.div,{variants:J4,initial:"hidden",animate:"show",className:"relative mx-auto grid max-w-6xl gap-10 px-5 pb-16 pt-14 sm:pb-20 sm:pt-20 md:grid-cols-2 md:items-center md:gap-16 md:pb-24 md:pt-32",children:[v.jsxs("div",{children:[v.jsxs(xe.div,{variants:Pa,children:[v.jsxs("h1",{className:"text-4xl font-bold tracking-tight text-foreground sm:text-5xl lg:text-7xl",children:[v.jsxs("span",{className:"inline sm:hidden",children:["AI 투자",v.jsx("br",{}),"에이전트 교육"]}),v.jsxs("span",{className:"hidden sm:inline",children:["AI 투자 에이전트",v.jsx("br",{}),"교육 플랫폼"]})]}),v.jsx("div",{className:"mt-8",children:v.jsx("span",{className:"text-4xl font-black tracking-tight bg-gradient-to-r from-accent via-[hsl(38,90%,55%)] to-[hsl(30,85%,50%)] bg-clip-text text-transparent sm:text-5xl md:text-6xl lg:text-8xl",children:"뉴와이즈"})})]}),v.jsxs(xe.p,{variants:Pa,className:"mt-6 max-w-md text-base leading-relaxed text-muted-foreground md:text-lg",children:["12개 실전 에이전트를 직접 만들면서",v.jsx("br",{}),"투자 분석력과 AI 개발 실력을 동시에 키우세요."]}),v.jsxs(xe.div,{variants:Pa,className:"mt-6 flex flex-col gap-3 sm:mt-8 sm:flex-row",children:[v.jsx("button",{className:"hero-glow-btn h-12 min-w-[180px] transition-all duration-300 sm:h-14 sm:min-w-[220px]",onClick:n||t,children:v.jsxs("span",{className:"button-face h-full px-6 text-sm sm:px-8 sm:text-base",children:[v.jsx(p1,{size:16,className:"text-accent sm:size-[18px]"}),"무료 분석 테스트"]})}),v.jsxs("button",{className:"hero-glass-btn h-12 min-w-[180px] gap-2 px-6 text-sm font-bold text-white transition-all duration-300 hover:bg-white/15 sm:h-14 sm:min-w-[220px] sm:px-8 sm:text-base",onClick:t,children:["얼리버드 신청",v.jsx(Fc,{size:16})]})]}),v.jsx(xe.div,{variants:Pa,className:"mt-8 flex gap-10 sm:mt-10 sm:gap-14",children:[{value:"12개",label:"실전 에이전트"},{value:"4개",label:"카테고리"},{value:"4주",label:"완성 커리큘럼"}].map((c,d)=>v.jsxs("div",{children:[v.jsx("div",{className:"text-xl font-black tabular-nums text-foreground sm:text-2xl",children:c.value}),v.jsx("div",{className:"text-[11px] text-muted-foreground sm:text-xs",children:c.label})]},d))})]}),v.jsxs(xe.div,{variants:Pa,className:"relative hidden md:block",children:[v.jsxs("div",{className:"relative rounded-2xl border border-gray-200 bg-white/90 p-5 shadow-2xl backdrop-blur-md",children:[v.jsx("div",{className:"mb-4 flex items-center justify-between",children:v.jsxs("div",{className:"flex items-center gap-2",children:[v.jsx("div",{className:"h-3 w-3 rounded-full bg-accent animate-pulse"}),v.jsx("span",{className:"text-xs font-semibold text-gray-900",children:"에이전트 대시보드"})]})}),v.jsxs("div",{className:"grid grid-cols-2 gap-3",children:[v.jsxs("div",{className:"rounded-xl border border-gray-200 bg-gray-100/80 p-3",children:[v.jsxs("div",{className:"mb-2 flex items-center gap-2",children:[v.jsx(om,{size:14,className:"text-red-500"}),v.jsx("span",{className:"text-[11px] font-semibold text-gray-900",children:"뉴스 감성 분석"})]}),v.jsx("div",{className:"text-xl font-black text-red-500",children:"87%"}),v.jsx("div",{className:"text-[10px] text-gray-500",children:"긍정 뉴스 비율"}),v.jsx("div",{className:"mt-2 h-1.5 rounded-full bg-gray-200",children:v.jsx("div",{className:"h-full w-[87%] rounded-full bg-red-500"})})]}),v.jsxs("div",{className:"rounded-xl border border-gray-200 bg-gray-100/80 p-3",children:[v.jsxs("div",{className:"mb-2 flex items-center gap-2",children:[v.jsx(rp,{size:14,className:"text-red-500"}),v.jsx("span",{className:"text-[11px] font-semibold text-gray-900",children:"RSI 경보봇"})]}),v.jsx("div",{className:"text-xl font-black text-red-500",children:"매수 신호"}),v.jsx("div",{className:"text-[10px] text-gray-500",children:"RSI 28.4 감지"}),v.jsx("div",{className:"mt-2 flex gap-1",children:[40,55,30,65,28].map((c,d)=>v.jsx("div",{className:"flex-1 rounded-sm bg-red-100",style:{height:`${c*.4}px`},children:v.jsx("div",{className:"mt-auto h-full rounded-sm bg-red-400",style:{height:`${c}%`}})},d))})]}),v.jsxs("div",{className:"rounded-xl border border-gray-200 bg-gray-100/80 p-3",children:[v.jsxs("div",{className:"mb-2 flex items-center gap-2",children:[v.jsx(xR,{size:14,className:"text-blue-500"}),v.jsx("span",{className:"text-[11px] font-semibold text-gray-900",children:"리스크 감지"})]}),v.jsx("div",{className:"text-xl font-black text-blue-500",children:"안전"}),v.jsx("div",{className:"text-[10px] text-gray-500",children:"집중 리스크 12%"})]}),v.jsxs("div",{className:"rounded-xl border border-gray-200 bg-gray-100/80 p-3",children:[v.jsxs("div",{className:"mb-2 flex items-center gap-2",children:[v.jsx(iR,{size:14,className:"text-red-500"}),v.jsx("span",{className:"text-[11px] font-semibold text-gray-900",children:"포트폴리오"})]}),v.jsx("div",{className:"text-xl font-black text-red-500",children:"+12.4%"}),v.jsx("div",{className:"text-[10px] text-gray-500",children:"월간 수익률"})]})]}),v.jsxs("div",{className:"mt-3 flex items-center gap-2 rounded-lg border border-accent/20 bg-accent/5 px-3 py-2",children:[v.jsx(c1,{size:14,className:"shrink-0 text-accent"}),v.jsxs("span",{className:"text-[11px] text-gray-500",children:[v.jsx("strong",{className:"text-gray-900",children:"배당 캘린더봇:"})," 삼성전자 배당금 1,444원 입금 예정 (D-3)"]})]})]}),v.jsx(xe.div,{animate:{y:[0,-8,0]},transition:{duration:3,repeat:1/0,ease:"easeInOut"},className:"absolute -top-10 -right-4 rounded-xl border border-white/20 bg-white/15 p-3 shadow-lg backdrop-blur-xl",children:v.jsxs("div",{className:"flex items-center gap-2",children:[v.jsx("div",{className:"h-8 w-8 rounded-lg bg-accent/10 flex items-center justify-center",children:v.jsx(rp,{size:14,className:"text-accent"})}),v.jsxs("div",{children:[v.jsx("div",{className:"text-[11px] font-semibold text-foreground",children:"수강생 만족도"}),v.jsx("div",{className:"text-sm font-black text-accent",children:"4.8 / 5.0"})]})]})})]})]})]})},Wp="/assets/newise-logo-C9VU5GU5.png",Rx={duration:.5,ease:[.2,0,0,1]},Z4=[{icon:v.jsx(kR,{size:28}),emoji:"😰",role:"투자 입문자",pain:`매일 뉴스는 보는데
315뭘 사야 할지 모르겠어요`,solution:"분석형 에이전트가 뉴스·재무제표를 자동 분석해 판단을 도와줍니다."},{icon:v.jsx(TR,{size:28}
315),emoji:"😤",role:"개인 투자자",pain:`감에 의존한 투자,
316매번 후회만 반복돼요`,solution:"기술적 분석 에이전트가 데이터 기반 매매 신호를 자동으로 알려줍니다."},{icon:v.jsx(h1,{size:28}),emoji:"🤔",role:"개발자",pain:`AI를 배웠는데
317어디에 적용할지 모르겠어요`,solution:"12개 실전 에이전트를 만들며 AI 활용 능력과 투자 지식을 함께 키울 수 있습니다."}],e3=()=>v.jsx("section",{className:"py-24",children:v.jsxs("div",{className:"mx-auto max-w-5xl px-5",children:[v.jsxs(xe.div,{initial:{opacity:0,y:16},whileInView:{opacity:1,y:0},viewport:{once:!0},transition:Rx,className:"mb-14 text-center",children:[v.jsx("h2",{className:"text-3xl font-bold tracking-tight md:text-4xl",children:"이런 고민, 하고 계시죠?"}),v.jsx("p",{className:"mx-auto mt-3 max-w-lg text-muted-foreground",children:"더 이상 우연에 맡기지 마세요. AI 에이전트가 투자를 바꿔줍니다."})]}),v.jsx("div",{className:"grid gap-4 sm:grid-cols-2 md:grid-cols-3 sm:gap-6",children:Z4.map((t,e)=>v.jsxs(xe.div,{initial:{opacity:0,y:24},whileInView:{opacity:1,y:0},viewport:{once:!0},transition:{...Rx,delay:e*.12},className:"group relative overflow-hidden rounded-2xl border border-border bg-card p-7 transition-all hover:border-accent/30 hover:shadow-xl hover:shadow-accent/5",children:[v.jsx("div",{className:"mb-5 text-4xl",children:t.emoji}),v.jsx("div",{className:"mb-2 inline-block rounded-full bg-accent/10 px-3 py-1 text-xs font-semibold text-accent",children:t.role}),v.jsx("p",{className:"mt-3 whitespace-pre-line text-lg font-bold leading-snug",children:t.pain}),v.jsx("div",{className:"mt-4 border-t border-border pt-4",children:v.jsx("p",{className:"text-sm leading-relaxed text-muted-foreground",children:t.solution})})]},e))})]})}),t3="/assets/slack-9Z_GJoae.png",n3="/assets/openai-BAlzRzUw.png",r3="/assets/kis-DXEaa04V.png",s3="/assets/yahoo-D3qywVXn.png",i3="/assets/aws-BjQ8CDcH.png",o3={duration:.5,ease:[.2,0,0,1]},jx=[{name:"Python",slug:"python"},{name:"OpenAI",image:n3},{name:"LangChain",slug:"langchain"},{name:"Pandas",slug:"pandas"},{name:"TensorFlow",slug:"tensorflow"},{name:"HuggingFace",slug:"huggingface"},{name:"KIS API",image:r3},{name:"Yahoo Finance",image:s3},{name:"Slack",image:t3},{name:"Telegram",slug:"telegram"},{name:"Kakao",slug:"kakaotalk"},{name:"AWS",image:i3}],a3=()=>v.jsxs("section",{className:"border-y border-border bg-card/30 py-16 overflow-hidden",children:[v.jsx("div",{className:"mx-auto max-w-5xl px-5",children:v.jsx(xe.p,{initial:{opacity:0}
317,whileInView:{opacity:1},viewport:{once:!0},transition:o3,className:"mb-8 text-center text-sm font-medium text-muted-foreground",children:"에이전트 개발에 활용하는 기술 · 플랫폼"})}),v.jsxs("div",{className:"pause-on-hover relative",children:[v.jsx("div",{className:"pointer-events-none absolute inset-y-0 left-0 z-10 w-24 bg-gradient-to-r from-background to-transparent"}),v.jsx("div",{className:"pointer-events-none absolute inset-y-0 right-0 z-10 w-24 bg-gradient-to-l from-background to-transparent"}),v.jsx("div",{className:"marquee-track animate-marquee",style:{animationDuration:"25s"},children:[...jx,...jx].map((t,e)=>v.jsxs("div",{className:"mx-3 flex shrink-0 items-center gap-2 rounded-lg border border-border bg-card px-3 py-2.5 sm:mx-6 sm:px-5 sm:py-3",children:[t.image?v.jsx("img",{src:t.image,alt:t.name,className:"h-6 w-auto max-w-[2rem] object-contain",loading:"lazy"}):t.slug?v.jsx("img",{src:`https://cdn.simpleicons.org/${t.slug}`,alt:t.name,className:"h-6 w-6 dark:invert",loading:"lazy"}):v.jsx("div",{className:"flex h-6 w-6 items-center justify-center rounded-md bg-accent/10 font-mono text-[10px] font-bold text-accent",children:t.name.slice(0,2).toUpperCase()}),v.jsx("span",{className:"whitespace-nowrap text-xs font-semibold text-foreground sm:text-sm",children:t.name})]},e))})]})]}),l3="https://newise.lovable.app",Ox="https://storage.googleapis.com/gpt-engineer-file-uploads/v5o4wx2QDDV4YJHKc19NfEPmpQH3/social-images/social-1774422804353-newise_og_image.webp",Gm=({title:t,description:e,path:n,jsonLd:r,noindex:o})=>{const a=fl(),l=`${l3}${n??a.pathname}`,c=r?Array.isArray(r)?r:[r]:[];return v.jsxs(Vk,{children:[v.jsx("title",{children:t}),v.jsx("meta",{name:"description",content:e}),v.jsx("link",{rel:"canonical",href:l}),v.jsx("meta",{property:"og:title",content:t}),v.jsx("meta",{property:"og:description",content:e}),v.jsx("meta",{property:"og:url",content:l}),v.jsx("meta",{property:"og:image",content:Ox}),v.jsx("meta",{name:"twitter:title",content:t}),v.jsx("meta",{name:"twitter:description",content:e}),v.jsx("meta",{name:"twitter:image",content:Ox}),o?v.jsx("meta",{name:"robots",content:"noindex,nofollow"}):null,c.map((d,f)=>v.jsx("script",{type:"application/ld+json",children:JSON.stringify(d)},f))]})},Nx={duration:.5,ease:[.2,0,0,1]},Ix=[{icon:v.jsx(aR,{size:24}),num:"01",title:"투자 개념 학습",desc:"에이전트 개발에 필요한 투자 기초 지식과 핵심 지표를 배워요."},{icon:v.jsx(h1,{size:24}),num:"02",title:"에이전트 설계 · 개발",desc:"AI 투자 에이전트를 직접 기획하고 코딩으로 만들어요."},{icon:v.jsx(vR,{size:24}),num:"03",title:"실전 적용",desc:"만든 에이전트를 실제 투자 환경에서 테스트하고 활용해요."},{icon:v.jsx(fR,{size:24}),num:"04",title:"포트폴리오 완성",desc:"나만의 에이전트 포트폴리오를 구성하고 커리어에 활용해요."}],u3=()=>v.jsx("section",{className:"py-24",children:v.jsxs("div",{className:"mx-auto max-w-5xl px-5",children:[v.jsxs(xe.div,{initial:{opacity:0,y:16},whileInView:{opacity:1,y:0},viewport:{once:!0},transition:Nx,className:"mb-14 text-center",children:[v.jsx("h2",{className:"text-3xl font-bold tracking-tight md:text-4xl",children:"이렇게 배워요"}),v.jsx("p",{className:"mx-auto mt-3 max-w-md text-muted-foreground",children:"4단계 프로세스로 투자와 AI 개발을 동시에 마스터해요."})]}),v.jsx("div",{className:"grid gap-6 md:grid-cols-4",children:Ix.map((t,e)=>v.jsxs(xe.div,{initial:{opacity:0,y:20},whileInView:{opacity:1,y:0},viewport:{once:!0},transition:{...Nx,delay:e*.1},className:"group relative rounded-2xl border border-border bg-card p-6 transition-all hover:border-accent/30 hover:shadow-lg",children:[v.jsx("div",{className:"mb-4 font-mono text-5xl font-black text-accent/15 transition-colors group-hover:text-accent/25",children:t.num}),v.jsx("div",{className:"mb-3 flex h-12 w-12 items-center justify-center rounded-xl bg-accent/10 text-accent transition-colors group-hover:bg-accent group-hover:text-accent-foreground",children:t.icon}),v.jsx("h3",{className:"text-base font-bold",children:t.title}),v.jsx("p",{className:"mt-2 text-sm leading-relaxed text-muted-foreground",children:t.desc}),e<Ix.length-1&&v.jsx("div",{className:"absolute -right-3 top-1/2 z-10 hidden h-6 
317w-6 -translate-y-1/2 items-center justify-center rounded-full border border-border bg-card text-muted-foreground md:flex",children:"→"})]},e))})]})}),Lx={duration:.5,ease:[.2,0,0,1]},c3=[{num:"01",icon:v.jsx(om,{size:24}),title:"분석형 에이전트",subtitle:"기업과 시장을 분석하는 기본적 분석 에이전트",agents:[{name:"재무제표 요약봇",desc:"PER·PBR·ROE 핵심 지표 자동 요약"},{name:"뉴스 감성 분석봇",desc:"종목 뉴스 긍정/부정/중립 분류"},{name:"섹터 흐름 리포터",desc:"주요 섹터 동향 3줄 요약 발송"}],duration:"약 1주"},{num:"02",icon:v.jsx(rp,{size:24}),title:"기술적 분석 에이전트",subtitle:"차트와 기술적 지표를 활용하는 에이전트",agents:[{name:"매수/매도 신호봇",desc:"골든크로스·데드크로스 자동 감지"},{name:"RSI 과매수 경보봇",desc:"RSI 70↑/30↓ 진입 시 알림"},{name:"52주 신고가 알림봇",desc:"관심 종목 신고가 돌파 즉시 알림"}],duration:"약 1주"},{num:"03",icon:v.jsx(CR,{size:24}),title:"자산관리 에이전트",subtitle:"개인 자산을 체계적으로 관리하는 에이전트",agents:[{name:"현금흐름 계산봇",desc:"배당+이자 수익 자동 집계"},{name:"ETF 비교봇",desc:"수수료·수익률·구성종목 비교표"},{name:"연금 시뮬레이터",desc:"합산 예상 수령액 계산"}],duration:"약 1주"},{num:"04",icon:v.jsx(wR,{size:24}),title:"리스크 관리 에이전트",subtitle:"투자 리스크를 사전에 감지·관리하는 에이전트",agents:[{name:"손실 한도 경보봇",desc:"설정 손절선 도달 시 즉시 알림"},{name:"집중 리스크 감지봇",desc:"특정 종목·섹터 비중 30%↑ 경고"},{name:"사기 패턴 감지봇",desc:"투자 정보 사기 키워드 필터링"}],duration:"약 1주"}],d3=()=>v.jsx("section",{id:"curriculum",className:"py-24",children:v.jsxs("div",{className:"mx-auto max-w-5xl px-5",children:[v.jsxs(xe.div,{initial:{opacity:0,y:16},whileInView:{opacity:1,y:0},viewport:{once:!0},transition:Lx,className:"mb-16 text-center",children:[v.jsx("h2",{className:"text-3xl font-bold tracking-tight md:text-4xl",children:"커리큘럼"}),v.jsx("p",{className:"mx-auto mt-3 max-w-lg text-muted-foreground",children:"분석 → 기술 → 자산관리 → 리스크, 4단계로 에이전트 개발 역량을 키워요."})]}),v.jsx("div",{className:"space-y-16",children:c3.map((t,e)=>v.jsxs(xe.div,{initial:{opacity:0,y:30},whileInView:{opacity:1,y:0},viewport:{once:!0,margin:"-50px"},transition:{...Lx,delay:.1},children:[v.jsxs("div",{className:"mb-6 flex items-start gap-5",children:[v.jsx("div",{className:"font-mono text-6xl font-black text-accent/15 leading-none md:text-7xl",children:t.num}),v.jsxs("div",{children:[v.jsxs("div",{className:"flex items-center gap-2",children:[v.jsx("div",{className:"flex h-10 w-10 items-center justify-center rounded-xl bg-accent/10 text-accent",children:t.icon}),v.jsx("h3",{className:"text-xl font-bold md:text-2xl",children:t.title})]}),v.jsx("p",{className:"mt-1 text-sm text-muted-foreground",children:t.subtitle}),v.jsxs("span",{className:"mt-2 inline-block text-xs font-semibold text-accent",children:["3개 에이전트 · ",t.duration]})]})]}),v.jsx("div",{className:"grid grid-cols-2 gap-2 sm:gap-3 lg:grid-cols-3",children:t.agents.map((n,r)=>v.jsxs(xe.div,{whileHover:{y:-4,boxShadow:"0 10px 25px -5px rgba(0,0,0,0.1)"},transition:{duration:.3},className:"group rounded-xl border border-border bg-card p-4 transition-colors duration-300 hover:border-accent/30",children:[v.jsx("h4",{className:"text-sm font-bold",children:n.name}),v.jsx("p",{className:"mt-1 text-xs leading-relaxed text-muted-foreground",children:n.desc})]},r))})]},e))})]})}),Dx={duration:.5,ease:[.2,0,0,1]},h3=[{icon:v.jsx(d1,{size:20}),label:"분석 시간",before:"하루 2시간+",after:"자동 실시간",improvement:"90% 단축"},{icon:v.jsx(ER,{size:20}),label:"의사결정",before:"감과 경험",after:"데이터 기반",improvement:"정확도 UP"},{icon:v.jsx(om,{size:20}),label:"리스크 관리",before:"수동 체크",after:"24/7 자동 감시",improvement:"실시간 알림"},{icon:v.jsx(lR,{size:20}),label:"뉴스 분석",before:"일일이 읽기",after:"AI 감성 분류",improvement:"100배 빠르게"}],f3=()=>v.jsx("section",{className:"border-y border-border bg-card/30 py-24",children:v.jsxs("div",{className:"mx-auto max-w-5xl px-5",children:[v.jsxs(xe.div,{initial:{opacity:0,y:16},whileInView:{opacity:1,y:0},viewport:{once:!0},transition:Dx,className:"mb-14 text-center",children:[v.jsx("h2",{className:"text-3xl font-bold tracking-tight md:text-4xl",children:"에이전트가 만드는 변화"}),v.jsx("p",{className:"mx-auto mt-3 max-w-lg text-muted-foreground",children:"수동 투자 vs AI 에이전트 활용, 이렇게 달라집니다."})]}),v.jsx("div",{className:"grid gap-3 sm:grid-cols-2 sm:gap-4",children:h3.map((t,e)=>v.jsxs(xe.div,{initial:{opacity:0,y:20},whileInView:{opacity:1,y:0},viewport:{once:!0},transition:{...Dx,delay:e*.08},className:"group rounded-2xl border border-border bg-card p-6 transition-all hover:border-accent/30 hover:shadow-lg",children:[v.jsxs("div",{className:"mb-4 flex items-center gap-3",children:[v.jsx("div",{className:"flex h-10 w-10 items-center justify-center rounded-xl bg-accent/10 text-accent",children:t.icon}),v.jsx("h3",{className:"text-base font-bold",children:t.label})]}),v.jsxs("div",{className:"flex items-center gap-3",children:[v.jsxs("div",{className:"flex-1 rounded-lg bg-muted/50 p-3 text-center",children:[v.jsx("div",{className:"text-[10px] font-semibold uppercase tracking-wider text-muted-foreground",children:"Before"}),v.jsx("div",{className:"mt-1 text-sm font-bold text-muted-foreground",children:t.before})]}),v.jsx(Fc,{size:16,className:"shrink-0 text-accent"}),v.jsxs("div",{className:"flex-1 rounded-lg border border-accent/20 bg-accent/5 p-3 text-center",children:[v.jsx("div",{className:"text-[10px] font-semibold uppercase tracking-wider text-accent",children:"After"}),v.jsx("div",{className:"mt-1 text-sm font-bold text-foreground",children:t.after})]})]}),v.jsx("div",{className:"mt-3 text-center",children:v.jsx("span",{className:"inline-block rounded-full bg-accent/10 px-3 py-1 text-xs font-bold text-accent",children:t.improvement})})]},e))})]})}),Mx={duration:.5,ease:[.2,0,0,1]},$x=["AI 에이전트에 관심이 있다","투자를 체계적으로 하고 싶다","코딩 경험은 없지만 자동화에 관심 있다","나만의 투자 도구를 만들고 싶다","투자와 AI 역량을 동시에 키우고 싶다"],p3=({onDiagnostic:t})=>{const[e,n]=E.useState(new Array($x.length).fill(!1)),r=e.filter(Boolean).length,o=l=>{n(c=>c.map((d,f)=>f===l?!d:d))},a=()=>r>=4?"뉴와이즈가 딱 맞는 분이시네요! 🎉":r>=2?"좋은 시작점이에요! 에이전트 만들면서 투자를 배워보세요.":"하나라도 해당된다면 시작할 준비가 된 겁니다!";return v.jsx("section",{className:"py-24",children:v.jsxs("div",{className:"mx-auto max-w-2xl px-5",children:[v.jsxs(xe.div,{initial:{opacity:0,y:16},whileInView:{opacity:1,y:0},viewport:{once:!0},transition:Mx,className:"mb-10 text-center",children:[v.jsx("h2",{className:"text-3xl font-bold tracking-tight md:text-4xl",children:"나에게 맞을까?"}),v.jsx("p",{className:"mx-auto mt-3 max-w-md text-muted-foreground",children:"아래 항목에 해당되는지 체크해보세요."})]}),v.jsxs(xe.div,{initial:{opacity:0,y:16},whileInView:{opacity:1,y:0},viewport:{once:!0},transition:{...Mx,delay:.1},className:"rounded-2xl border border-border bg-card p-6 md:p-8",children:[v.jsx("ul",{className:"space-y-4",children:$x.map((l,c)=>v.jsx("li",{children:v.jsxs("button",{onClick:()=>o(c),className:"flex w-full items-center gap-3 text-left text-sm transition-colors hover:text-foreground",children:[e[c]?v.jsx(bR,{size:20,className:"shrink-0 text-accent"}
317):v.jsx(SR,{size:20,className:"shrink-0 text-muted-foreground/40"}),v.jsx("span",{className:e[c]?"text-foreground font-medium":"text-muted-foreground",children:l})]})},c))}),r>0&&v.jsxs(xe.div,{initial:{opacity:0,y:8},animate:{opacity:1,y:0},className:"mt-6 rounded-xl bg-accent/5 border border-accent/10 p-4 text-center",children:[v.jsx("p",{className:"text-sm font-medium text-accent",children:a()}),r>=2&&v.jsxs(ni,{size:"sm",className:"mt-3 gap-1.5",onClick:t,children:["무료 체험 시작",v.jsx(Fc,{size:14})]})]})]})]})})},Fx={duration:.5,ease:[.2,0,0,1]},m3=[{label:"🌱 입문",desc:"코딩 경험 없이도 시작 가능",tools:[{name:"재무제표 요약봇",category:"분석형"},{name:"배당 캘린더봇",category:"분석형"},{name:"뉴스 감성 분석봇",category:"분석형"},{name:"현금흐름 계산봇",category:"자산관리"}]},{label:"📊 중급",desc:"기술적 분석과 자동화 도전",tools:[{name:"매수/매도 신호봇",category:"기술적"},{name:"RSI 경보봇",category:"기술적"},{name:"ETF 비교봇",category:"자산관리"},{name:"리밸런싱봇",category:"기술적"}]},{label:"🏆 고급",desc:"리스크 관리와 통합 시스템",tools:[{name:"금융사기 감지봇",category:"리스크"},{name:"환율 리스크봇",category:"리스크"},{name:"세금 최적화봇",category:"자산관리"},{name:"총자산 대시보드봇",category:"리스크"}]}],g3=()=>v.jsx("section",{className:"py-24",children:v.jsxs("div",{className:"mx-auto max-w-4xl px-5",children:[v.jsxs(xe.div,{initial:{opacity:0,y:16},whileInView:{opacity:1,y:0},viewport:{once:!0},transition:Fx,className:"mb-14 text-center",children:[v.jsx("h2",{className:"text-3xl font-bold tracking-tight md:text-4xl",children:"난이도별 학습 로드맵"}),v.jsx("p",{className:"mx-auto mt-3 max-w-md text-muted-foreground",children:"경험에 맞는 단계부터 시작해서 전문가 수준까지 성장해요."})]}),v.jsx("div",{className:"grid gap-4 sm:grid-cols-2 sm:gap-6 md:grid-cols-3",children:m3.map((t,e)=>v.jsxs(xe.div,{initial:{opacity:0,y:20},whileInView:{opacity:1,y:0},viewport:{once:!0},transition:{...Fx,delay:e*.1},whileHover:{y:-4,boxShadow:"0 10px 25px -5px rgba(0,0,0,0.1)"},className:"rounded-2xl border border-border bg-card p-5",children:[v.jsx("div",{className:"mb-1 text-lg font-bold",children:t.label}),v.jsx("p",{className:"mb-4 text-xs text-muted-foreground",children:t.desc}),v.jsx("div",{className:"space-y-2",children:t.tools.map((n,r)=>v.jsxs(xe.div,{whileHover:{y:-2,boxShadow:"0 4px 12px -2px rgba(0,0,0,0.08)"},transition:{duration:.3},className:"flex items-center justify-between rounded-lg border border-border bg-background px-3 py-2",children:[v.jsx("span",{className:"text-sm font-semibold",children:n.name}),v.jsx("span",{className:"text-[11px] text-muted-foreground",children:n.category})]},r))})]},e))})]})}),Ux={duration:.5,ease:[.2,0,0,1]},y3=[{icon:v.jsx(d1,{size:28}),title:"시간 절약",stat:"90%",desc:"투자 분석에 들이는 시간을 에이전트가 대신합니다."},{icon:v.jsx(hR,{size:28}),title:"효율적 학습",stat:"12개",desc:"실전 에이전트를 만들며 투자와 AI를 동시에 마스터."},{icon:v.jsx(PR,{size:28}),title:"실전 성과",stat:"24/7",desc:"에이전트가 시장을 실시간으로 모니터링하고 알려줍니다."},{icon:v.jsx(yR,{size:28}),title:"재현 가능",stat:"∞",desc:"한번 만든 에이전트를 계속 재사용하고 확장할 수 있어요."}],v3=()=>v.jsx("section",{className:"py-24",children:v.jsxs("div",{className:"mx-auto max-w-5xl px-5",children:[v.jsxs(xe.div,{initial:{opacity:0,y:16},whileInView:{opacity:1,y:0},viewport:{once:!0},transition:Ux,className:"mb-14 text-center",children:[v.jsx("h2",{className:"text-3xl font-bold tracking-tight md:text-4xl",children:"핵심 가치"}),v.jsx("p",{className:"mx-auto mt-3 max-w-md text-muted-foreground",children:"NEWISE에서 에이전트를 배우면 이런 가치를 얻을 수 있어요."})]}),v.jsx("div",{className:"grid grid-cols-2 gap-3 sm:gap-6 lg:grid-cols-4",children:y3.map((t,e)=>v.jsxs(xe.div,{initial:{opacity:0,y:20},whileInView:{opacity:1,y:0},viewport:{once:!0},transition:{...Ux,delay:e*.08},className:"group rounded-2xl border border-border bg-card p-6 text-center transition-all hover:border-accent/30 hover:shadow-lg",children:[v.jsx("div",{className:"mx-auto mb-4 flex h-14 w-14 items-center justify-center rounded-2xl bg-accent/10 text-accent transition-colors group-hover:bg-accent group-hover:text-accent-foreground",children:t.icon}),v.jsx("div",{className:"mb-2 text-3xl font-black text-accent",children:t.stat}),v.jsx("h3",{className:"text-base font-bold",children:t.title}),v.jsx("p",{className:"mt-2 text-sm leading-relaxed text-muted-foreground",children:t.desc})]},e))})]})}),w3={duration:.5,ease:[.2,0,0,1]},Zi=[{name:"김민수",role:"30대 · 직장인",rating:5,text:"코딩 경험 없이 시작했는데, 재무제표 요약봇을 만들면서 투자도 자연스럽게 배웠어요. 지금은 5개 에이전트를 실전에서 쓰고 있습니다.",tags:["#코딩입문","#에이전트개발"]},{name:"이지은",role:"40대 · 사업가",rating:5,text:"바쁜 일상에서 RSI 경보봇이 매수/매도 타이밍을 자동으로 알려주니 정말 편해요. 직접 만든 도구라 더 신뢰가 갑니다.",tags:["#자동알림","#실전활용"]},{name:"박서준",role:"20대 · 대학생",rating:5,text:"AI 개발 포트폴리오도 만들고, 투자 지식도 쌓고! 취업 면접에서 에이전트 프로젝트 이야기하니 면접관이 매우 관심있어했어요.",tags:["#포트폴리오","#취업준비"]},{name:"최수아",role:"30대 · 프리랜서",rating:5,text:"총자산 대시보드봇 덕분에 예금, 주식, 연금 현황을 한눈에 ë³¼ 수 있어요. 자산관리가 이렇게 쉬울 줄 몰랐네요.",tags:["#자산관리","#대시보드"]},{name:"한지우",role:"40대 · 전업 투자자",rating:5,text:"뉴스 감성 분석봇으로 시장 분위기를 빠르게 파악하고, 변동성 경보봇으로 리스크도 관리해요. 투자의 질이 확 달라졌습니다.",tags:["#감성분석","#리스크관리"]},{name:"정다은",role:"50대 · 은퇴 준비",rating:5,text:"연금 시뮬레이터를 직접 만들어보니 은퇴 계획이 구체적으로 잡혔어요. 세금 최적화봇도 정말 유용합니다.",tags:["#은퇴준비","#세금최적화"]}],Vx=({t})=>v.jsxs("div",{className:"mx-3 w-80 shrink-0 rounded-2xl border border-white/15 bg-white/[0.07] p-6 backdrop-blur-2xl shadow-[0_8px_32px_rgba(0,0,0,0.12),inset_0_1px_0_rgba(255,255,255,0.08)]",children:[v.jsx(gR,{size:20,className:"mb-3 text-accent/30"}),v.jsx("div",{className:"mb-3 flex gap-0.5",children:[...Array(t.rating)].map((e,n)=>v.jsx(_R,{size:13,className:"fill-star text-star"},n))}),v.jsxs("p",{className:"text-sm leading-relaxed text-muted-foreground",children:['"',t.text,'"']}),v.jsx("div",{className:"mt-3 flex flex-wrap gap-1.5",children:t.tags.map(e=>v.jsx("span",{className:"text-[11px] font-medium text-accent",children:e},e))}),v.jsxs("div",{className:"mt-4 flex items-center gap-3 border-t border-border pt-4",children:[v.jsx("div",{className:"flex h-9 w-9 items-center justify-center rounded-full bg-accent/10 text-sm font-semibold text-accent",children:t.name[0]}),v.jsxs("div",{children:[v.jsx("div",{className:"text-sm font-medium",children:t.name}),v.jsx("div",{className:"text-xs text-muted-foreground",children:t.role})]})]})]}),x3=()=>v.jsxs("section",{className:"py-24 overflow-hidden",children:[v.jsx("div",{className:"mx-auto max-w-5xl px-5",children:v.jsxs(xe.div,{initial:{opacity:0,y:16},whileInView:{opacity:1,y:0},viewport:{once:!0},transition:w3,className:"mb-12 text-center",children:[v.jsx("h2",{className:"text-3xl font-bold tracking-tight md:text-4xl",children:"수강생들의 이야기"}),v.jsx("p",{className:"mx-auto mt-3 max-w-md text-muted-foreground",children:"에이전트를 만들면서 투자도 배운 수강생들의 생생한 후기입니다."})]})}),v.jsx("div",{className:"pause-on-hover mb-4",children:v.jsx("div",{className:"marquee-track animate-marquee",children:[...Zi,...Zi].map((t,e)=>v.jsx(Vx,{t},e))})}),v.jsx("div",{className:"pause-on-hover",children:v.jsx("div",{className:"marquee-track animate-marquee-reverse",children:[...Zi.slice(3),...Zi.slice(0,3),...Zi.slice(3),...Zi.slice(0,3)].map((t,e)=>v.jsx(Vx,{t},e))})})]}),Bx={duration:.5,ease:[.2,0,0,1]},b3=[{id:"starter",name:"입문 패키지",price:"490,000원",period:"4주 온라인",desc:v.jsxs(v.Fragment,{children:["AI 투자 에이전트의 기초를 빠르게 익히는",v.jsx("br",{}),"입문 과정"]}),features:["기본 에이전트 5종 실습","온라인 VOD 무제한 수강","AI 튜터 질의응답","기본 데이터 API 제공","수료증 발급"],popular:!1},{id:"professional",name:"완성 패키지",price:"1,490,000원",period:"4주 블렌디드",desc:"12개 에이전트를 모두 완성하는 심화 과정",features:["전체 12개 에이전트 커리큘럼","온라인 + 오프라인 블렌디드 수업","AI 튜터 무제한 질문","프리미엄 데이터 API","에이전트 템플릿 제공","수료증 발급"],popular:!0},{id:"premium",name:"프리미엄 패키지",price:"2,990,000원",period:"4주 + 1:1 컨설íŒ
317…",desc:v.jsxs(v.Fragment,{children:["1:1 AI 에이전트 세팅 컨설팅까지 포함된",v.jsx("br",{}),"최상위 과정"]}),features:["완성 패키지 전체 포함","1:1 AI 에이전트 세팅 컨설팅","커스텀 에이전트 설계 지원","전담 매니저 배정","우선 기술 지원"],popular:!1}],S3=({onEnroll:t,onContact:e})=>v.jsx("section",{className:"border-y border-border bg-card/30 py-24",children:v.jsxs("div",{className:"mx-auto max-w-5xl px-5",children:[v.jsxs(xe.div,{initial:{opacity:0,y:16},whileInView:{opacity:1,y:0},viewport:{once:!0},transition:Bx,className:"mb-14 text-center",children:[v.jsx("h2",{className:"text-3xl font-bold tracking-tight md:text-4xl",children:"수강 플랜"}),v.jsxs("p",{className:"mx-auto mt-3 max-w-md text-muted-foreground",children:["나에게 맞는 플랜으로 에이전트 개발을 시작하세요.",v.jsx("br",{}),v.jsx("span",{className:"text-accent font-semibold",children:"얼리버드 신청 시 정식 런칭 할인 혜택 제공!"})]})]}),v.jsx("div",{className:"grid gap-4 sm:gap-6 md:grid-cols-3",children:b3.map((n,r)=>v.jsxs(xe.div,{initial:{opacity:0,y:20},whileInView:{opacity:1,y:0},viewport:{once:!0},transition:{...Bx,delay:r*.1},whileHover:{y:-4},className:`group relative rounded-2xl border p-7 transition-colors duration-300 ${n.popular?"border-accent bg-card shadow-lg shadow-accent/10 hover:shadow-accent/20":"border-border bg-card hover:border-accent/30"}`,children:[n.popular&&v.jsx("span",{className:"absolute -top-3 left-1/2 -translate-x-1/2 rounded-full bg-accent px-3 py-1 text-xs font-semibold text-accent-foreground",children:"가장 인기"}),v.jsx("h3",{className:"text-lg font-bold",children:n.name}),v.jsx("p",{className:"mt-1 text-sm text-muted-foreground",children:n.desc}),v.jsx("div",{className:"mt-4",children:v.jsx("span",{className:"text-3xl font-extrabold",children:n.price})}),v.jsx("ul",{className:"mt-6 space-y-3",children:n.features.map((o,a)=>v.jsxs("li",{className:"flex items-center gap-2 text-sm",children:[v.jsx(dR,{size:16,className:"shrink-0 text-accent"}),o]},a))}),v.jsx(ni,{className:`mt-8 w-full ${n.popular?"bg-black text-white hover:bg-accent hover:text-accent-foreground":""}`,variant:n.popular?"default":"outline",onClick:()=>t(n.id),children:"얼리버드 사전 신청"})]},r))})]})}),Pf={duration:.5,ease:[.2,0,0,1]},zx=[{q:"코딩 경험이 없어도 에이전트를 만들 수 있나요?",a:"네! 코딩 경험이 전혀 없어도 시작할 수 있습니다. 입문 단계에서 기초부터 차근차근 안내하고, 에이전트 템플릿을 제공해 쉽게 따라할 수 있어요."},{q:"만든 에이전트를 실전 투자에 바로 활용할 수 있나요?",a:"물론이에요! 커리큘럼에서 만드는 12개 에이전트는 모두 실전 투자에 활용할 수 있도록 설계되어 있습니다."},{q:"어떤 프로그래밍 언어를 사용하나요?",a:"주로 Python을 사용하며, AI/ML 라이브러리와 금융 데이터 API를 함께 활용합니다. 프로그래밍 기초부터 가르쳐드리니 걱정 마세요."},{q:"학습 기간은 얼마나 걸리나요?",a:"전체 커리큘럼은 약 4주로 구성되어 있습니다. 각 레이어가 약 1주씩이며, 본인 페이스에 맞게 조절 가능합니다."},{q:"수료증이 취업에 도움이 되나요?",a:"수료증과 함께 직접 만든 에이전트 포트폴리오가 제공됩니다. AI 개발 역량과 금융 도메인 지식을 동시에 보여줄 수 있어 핀테크 분야 취업에 큰 도움이 됩니다."},{q:"수강 시작 후 환불이 가능한가요?",a:"수강 시작 후 7일 이내, 1회에 한해 전액 환불이 가능합니다. 환불 요청은 이메일([email protected])로 접수해 주세요."}],_3=({onEnroll:t})=>{const[e,n]=E.useState(null),r=E.useRef(null),[o,a]=E.useState({x:0,y:0}),l=E.useCallback(c=>{var f;const d=(f=r.current)==null?void 0:f.getBoundingClientRect();d&&a({x:c.clientX-d.left,y:c.clientY-d.top})},[]);return E.useEffect(()=>{const c=document.createElement("script");return c.type="application/ld+json",c.id="faq-jsonld",c.textContent=JSON.stringify({"@context":"https://schema.org","@type":"FAQPage",mainEntity:zx.map(d=>
317({"@type":"Question",name:d.q,acceptedAnswer:{"@type":"Answer",text:d.a}}))}),document.head.appendChild(c),()=>{var d;(d=document.getElementById("faq-jsonld"))==null||d.remove()}},[]),v.jsx("section",{className:"py-24","aria-label":"자주 묻는 질문",children:v.jsxs("div",{className:"mx-auto max-w-3xl px-5",children:[v.jsx(xe.div,{initial:{opacity:0,y:16},whileInView:{opacity:1,y:0},viewport:{once:!0},transition:Pf,className:"mb-14 text-center",children:v.jsx("h2",{className:"text-3xl font-bold tracking-tight md:text-4xl",children:"자주 묻는 질문"})}),v.jsx("div",{className:"space-y-3",role:"list",children:zx.map((c,d)=>{const f=e===d;return v.jsxs(xe.div,{role:"listitem",initial:{opacity:0,y:12},whileInView:{opacity:1,y:0},viewport:{once:!0},transition:{...Pf,delay:d*.05},className:"rounded-xl border border-border bg-card",children:[v.jsxs("button",{onClick:()=>n(f?null:d),"aria-expanded":f,className:"flex w-full items-center justify-between gap-3 p-5 text-left text-sm font-medium",children:[c.q,v.jsx(uR,{size:18,className:`shrink-0 text-muted-foreground transition-transform ${f?"rotate-180":""}`})]}),f&&v.jsx("div",{className:"border-t border-border px-5 pb-5 pt-3 text-sm leading-relaxed text-muted-foreground",children:c.a})]},d)})}),v.jsxs(xe.div,{ref:r,onMouseMove:l,initial:{opacity:0,y:20},whileInView:{opacity:1,y:0},viewport:{once:!0},transition:Pf,className:"relative mt-16 overflow-hidden rounded-2xl hero-gradient p-6 text-center sm:mt-20 sm:p-10 md:p-14",children:[v.jsx("div",{className:"pointer-events-none absolute h-[700px] w-[700px] rounded-full blur-[160px] transition-transform duration-200 ease-out",style:{transform:`translate(${o.x-350}px, ${o.y-350}px)`,background:"radial-gradient(circle, hsl(45 93% 47% / 0.4) 0%, hsl(45 93% 47% / 0.15) 40%, transparent 70%)"}}),v.jsx("div",{className:"pointer-events-none absolute -top-20 right-0 h-[300px] w-[300px] rounded-full bg-accent/4 blur-[120px]"}),v.jsx("div",{className:"pointer-events-none absolute bottom-0 left-0 h-[200px] w-[250px] rounded-full bg-accent/3 blur-[100px]"}),v.jsxs("div",{className:"relative",children:[v.jsx(c1,{size:40,className:"mx-auto mb-6 text-accent"}),v.jsxs("h2",{className:"text-3xl font-bold tracking-tight text-foreground md:text-4xl",children:["나만의 AI 투자 에이전트,",v.jsx("br",{}),"지금 만들어보세요"]}),v.jsx("div",{className:"mx-auto mt-6 flex max-w-sm justify-center gap-3 sm:mt-8 sm:gap-6",children:[{value:"12개",label:"에이전트"},{value:"4개",label:"카테고리"},{value:"4주",label:"커리큘럼"}].map((c,d)=>v.jsxs("div",{className:"rounded-xl border border-white/10 bg-white/5 px-3 py-2 text-center backdrop-blur-sm sm:px-5 sm:py-3",children:[v.jsx("div",{className:"text-lg font-black tabular-nums text-accent sm:text-2xl",children:c.value}),v.jsx("div",{className:"text-[10px] text-muted-foreground sm:text-xs",children:c.label})]},d))}),v.jsxs("div",{className:"mt-8 flex flex-col items-center gap-3",children:[v.jsx("button",{className:"hero-glow-btn h-12 min-w-[180px] transition-all duration-300 sm:h-14 sm:min-w-[220px]",onClick:t,children:v.jsxs("span",{className:"button-face h-full px-6 text-sm sm:px-8 sm:text-base",children:[v.jsx(p1,{size:16,className:"text-accent"}),"얼리버드 신청",v.jsx(Fc,{size:16})]})}),v.jsx("p",{className:"text-xs text-muted-foreground/70",children:"코딩 경험 불필요 · 간단 가입 후 바로 시작"})]})]})]})]})})},E3=()=>{const t=em(),{user:e,signOut:n}=yl();F4();const[r,o]=E.useState(()=>{try{return localStorage.getItem("landing-banner-dismissed")==="1"}catch{return!1}}),a=()=>{o(!0);try{localStorage.setItem("landing-banner-dismissed","1")}catch{}},l=(f="signup")=>{t(`/auth?mode=${f}`)},c=f=>{t(f?`/enroll?plan=${f}`:"/enroll")},d=()=>{t(e?"/onboarding":"/auth?mode=signup&redirect=/onboarding")};return v.jsxs("div",{className:"min-h-screen bg-background text-foreground overflow-x-hidden",children:[v.jsx(Gm,{title:"뉴와이즈 | AI 투자 에이전트 교육 플랫폼 — NEWISE",description:"12개 실전 AI 투자 에이전트를 직접 만들면서 투자 분석력과 AI 개발 실력을 동시에 키우세요. 코딩 경험 불필요, 4주 완성 커리큘럼.",path:"/",jsonLd:[{"@context":"https://schema.org","@type":"WebSite",name:"NEWISE (뉴와이즈)",url:"https://newise.lovable.app",inLanguage:"ko"},{"@context":"https://schema.org","@type":"Course",name:"AI 투자 에이전트 실전 교육",description:"12개 실전 AI 투자 에이전트를 직접 만들면서 투자 분석력과 AI 개발 실력을 동시에 키우는 4주 커리큘럼",provider:{"@type":"Organization",name:"NEWISE (뉴와이즈)",url:"https://newise.lovable.app"},educationalLevel:"Beginner to Advanced",inLanguage:"ko",numberOfCredits:"12",hasCourseInstance:{"@type":"CourseInstance",courseMode:"online",duration:"P4W"}}]}),!r&&v.jsxs("div",{className:"relative z-50 flex items-center justify-center gap-2 bg-gradient-to-r from-primary to-accent px-10 py-2 text-xs font-medium text-primary-foreground sm:gap-3 sm:px-5 sm:py-2.5 sm:text-sm",children:[v.jsxs("span",{className:"text-center leading-snug",children:["🎉 얼리버드 사전 모집 중 — 지금 신청하면 ",v.jsx("strong",{children:"정식 런칭 시 특별 할인 혜택!"})]}),v.jsx("button",{onClick:()=>
317c(),className:"rounded-full bg-primary-foreground/20 px-3 py-0.5 text-xs font-bold hover:bg-primary-foreground/30 transition-colors",children:"얼리버드 신청 →"}),v.jsx("button",{onClick:a,className:"absolute right-3 top-1/2 -translate-y-1/2 rounded-full p-1 hover:bg-primary-foreground/20 transition-colors","aria-label":"닫기",children:v.jsx(g1,{size:14})})]}),v.jsx("nav",{className:"sticky top-0 z-40 border-b border-border/50 bg-background/80 backdrop-blur-xl safe-bottom","aria-label":"메인 내비게이션",children:v.jsxs("div",{className:"mx-auto flex h-14 max-w-6xl items-center justify-between px-4 sm:h-16 sm:px-5",children:[v.jsx("div",{className:"flex items-center gap-2.5",children:v.jsx("img",{src:Wp,alt:"NEWISE",className:"h-5 w-auto object-contain sm:h-6",width:72,height:24})}),v.jsx("div",{className:"flex items-center gap-2",children:e?v.jsxs(v.Fragment,{children:[v.jsxs(ni,{variant:"ghost",size:"sm",onClick:()=>t("/dashboard"),children:[v.jsx(m1,{size:16,className:"mr-1.5"}),"마이페이지"]}
317),v.jsxs(ni,{variant:"outline",size:"sm",onClick:n,children:[v.jsx(pR,{size:16,className:"mr-1.5"}),"로그아웃"]})]}):v.jsxs(v.Fragment,{children:[v.jsx(ni,{variant:"ghost",size:"sm",onClick:()=>l("login"),children:"로그인"}),v.jsx(ni,{size:"sm",onClick:d,children:"무료 분석"})]})})]})}),v.jsxs("main",{children:[v.jsx(X4,{onEnroll:()=>c(),onExplore:()=>{var f;return(f=document.getElementById("curriculum"))==null?void 0:f.scrollIntoView({behavior:"smooth"})},onDiagnostic:d}),v.jsx(a3,{}),v.jsx(e3,{}),v.jsx(u3,{}),v.jsx(d3,{}),v.jsx(f3,{}),v.jsx(p3,{onDiagnostic:d}),v.jsx(g3,{}),v.jsx(v3,{}),v.jsx(x3,{}),v.jsx(S3,{onEnroll:f=>c(f),onContact:()=>l("signup")}),v.jsx(_3,{onEnroll:()=>c()})]}),v.jsx("footer",{className:"border-t border-border bg-card/50 py-8 sm:py-10","aria-label":"사이트 정보",children:v.jsx("div",{className:"mx-auto max-w-6xl px-4 sm:px-5",children:v.jsxs("div",{className:"flex flex-col gap-5 sm:gap-6 md:flex-row md:items-start md:justify-between",children:[v.jsxs("div",{className:"space-y-3",children:[v.jsxs("div",{className:"flex items-center gap-2",children:[v.jsx("img",{src:Wp,alt:"NEWISE",className:"h-6 w-auto object-contain"}),v.jsx("span",{className:"text-xs text-muted-foreground",children:"© 2026 NEWISE"})]}),v.jsxs("div",{className:"space-y-1 text-xs text-muted-foreground",children:[v.jsx("p",{children:"주식회사 글로윗"}),v.jsx("p",{children:"문의: [email protected]"})]})]}),v.jsxs("div",{className:"flex flex-wrap gap-x-6 gap-y-2 text-xs text-muted-foreground",children:[v.jsx("button",{onClick:()=>t("/terms"),className:"hover:text-foreground transition-colors",children:"이용약관"}),v.jsx("button",{onClick:()=>t("/privacy"),className:"hover:text-foreground transition-colors",children:"개인정보처리방침"}),e?v.jsxs(v.Fragment,{children:[v.jsx("button",{onClick:()=>t("/dashboard"),className:"hover:text-foreground transition-colors",children:"마이페이지"}),v.jsx("button",{onClick:n,className:"hover:text-foreground transition-colors",children:"로그아웃"})]}):v.jsxs(v.Fragment,{children:[v.jsx("button",{onClick:()=>l("login"),className:"hover:text-foreground transition-colors",children:"로그인"}),v.jsx("button",{onClick:()=>l("signup"),className:"hover:text-foreground transition-colors",children:"회원가입"})]})]})]})})})]})};var T3={version:"1.1.2"},k3="authorization_response",C3="/~oauth/initiate",P3=["https://oauth.lovable.app","https://lovable.dev"],A3="lovable://oauth-callback",R3="http://127.0.0.1/iframe-oauth/callback",j3=500,O3=12e4;function N3(t){let e;const n=new Promise(a=>{e=a}),r=a=>{if(!t.some(d=>a.origin===d))return;const c=a.data;!c||typeof c!="object"||c.type===k3&&e(c.response)},o=()=>{window.removeEventListener("message",r)};return window.addEventListener("message",r),{cleanup:o,messagePromise:n}}function I3(t){const e=window.screenX!==0||window.screenY!==0||!t,n=e?window.outerWidth*.5:window.screen.width*.5,r=e?window.outerHeight*.5:window.screen.height*.5,o=e?window.screenX+(window.outerWidth-n)/2:(window.screen.width-n)/2,a=e?window.screenY+(window.outerHeight-r)/2:(window.screen.height-r)/2;return{width:n,height:r,left:o,top:a}}function Wx(t,e){return t.state!==e?{error:new Error("State is invalid")}:t.error?t.error==="legacy_flow"?{error:new Error("This flow is not supported in Preview mode. Please open the app in a new tab to sign in.")}:{error:new Error(t.error_description??"Sign in failed")}:!t.access_token||!t.refresh_token?{error:new Error("No tokens received")}:{tokens:{access_token:t.access_token,refresh_token:t.refresh_token},error:null}}function L3(){const t=navigator.userAgent;return!!(/iPhone|iPad|iPod|Android/i.test(t)||/Macintosh/i.test(t)&&navigator.maxTouchPoints>1)}function D3(){return typeof crypto<"u"&&crypto.getRandomValues?[...crypto.getRandomValues(new Uint8Array(16))].map(t=>t.toString(16).padStart(2,"0")).join(""):Math.random().toString(36).substring(2)+Date.now().toString(36)}function M3(t={}){const e=t.oauthBrokerUrl??C3,n=t.supportedOAuthOrigins??P3;async function r(o,a={}){let l=!1;try{l=window.self!==window.top}catch{l=!0}const c=navigator.userAgent,d=/LovableApp\//.test(c),f=!d&&/lovable/i.test(c),p=D3();let g=a.redirect_uri??window.location.origin;d&&l?g=A3:f&&l&&(g=R3);const x=new URLSearchParams({...a.extraParams,provider:o,redirect_uri:g,state:p});if(!l)return window.location.href=`${e}?${x.toString()}`,{error:null,redirected:!0};!d&&!f&&x.set("response_mode","web_message");const y=`${e}?${x.toString()}`,_=f?[...n,window.location.origin]:n,{messagePromise:S,cleanup:b}=N3(_);let k;if(L3())k=window.open(y,"_blank");else{const{width:A,height:L,left:D,top:V}=I3(l);k=window.open(y,"oauth",`width=${A},height=${L},left=${D},top=${V}`)}if(!k&&(d||f)){let A;const L=new Promise((D,V)=>{A=setTimeout(()=>{V(new Error("OAuth timed out waiting for response"))},O3)});try{const D=await Promise.race([S,L]);return Wx(D,p)}catch(D){return{error:D instanceof Error?D:new Error(String(D))}}finally{A&&clearTimeout(A),b()}}if(!k)return b(),{error:new Error("Popup was blocked")};let P;const C=new Promise((A,L)=>{P=setInterval(()=>{k.closed&&(clearInterval(P),L(new Error("Sign in was cancelled")))},j3)});try{const A=await Promise.race([S,C]);return Wx(A,p)}catch(A){return{error:A instanceof Error?A:new Error(String(A))}}finally{clearInterval(P),b(),k==null||k.close()}}return{signInWithOAuth:r}}typeof window<"u"&&(window.__lovable_cloud_auth_js_version=T3.version);function $3(t={}){return M3(t)}const F3=$3(),U3={auth:{signInWithOAuth:async(t,e)=>{const n=await F3.signInWithOAuth(t,{redirect_uri:e==null?void 0:e.redirect_uri,extraParams:{...e==null?void 0:e.extraParams}});if(n.redirected||n.error)return n;try{await $n.auth.setSession(n.tokens)}catch(r){return{error:r instanceof Error?r:new Error(String(r))}}return n}}},Hx={duration:.2,ease:[.2,0,0,1]},V3=()=>{const[t,e]=E.useState("login"),[n,r]=E.useState(""),[o,a]=E.useState(""),[l,c]=E.useState(""),[d,f]=E.useState(!1),p=t==="login",g=t==="forgot",x=async S=>{S.preventDefault(),f(!0);try{const{error:b}=await $n.auth.resetPasswordForEmail(n,{redirectTo:`${window.location.origin}/reset-password`});if(b)throw b;Ln.success("비밀번호 재설정 이메일을 발송했습니다. 이메일을 확인해주세요."),e("login")}catch(b){Ln.error(b.message||"이메일 발송에 실패했습니다.")}finally{f(!1)}},y=async S=>{S.preventDefault(),f(!0);try{if(p){const{error:b}=await $n.auth.signInWithPassword({email:n,password:o});if(b)throw b;Ln.success("로그인 성공!")}else{const{error:b}=await $n.auth.signUp({email:n,password:o,options:{data:{full_name:l},emailRedirectTo:window.location.origin}});if(b)throw b;Ln.success("회원가입 완료! 이메일을 확인해주세요.")}}catch(b){Ln.error(b.message||"인증 오류가 발생했습니다.")}finally{f(!1)}},_=async()=>{try{const S=await U3.auth.signInWithOAuth("google",{redirect_uri:window.location.origin});S.error&&(console.error("Google OAuth error:",S.error),Ln.error("Google 로그인에 실패했습니다: "+(S.error.message||"알 수 없는 오류")))}catch(S){console.error("Google OAuth exception:",S),Ln.error("Google 로그인에 실패했습니다.")}};return v.jsxs("div",{className:"flex min-h-screen items-center justify-center bg-background p-4",children:[v.jsx(Gm,{title:"로그인 · 회원가입 | NEWISE 뉴와이즈",description:"NEWISE 계정으로 로그인하거나 새 계정을 만들어 AI 투자 에이전트 교육 커리큘럼을 시작하세요.",noindex:!0}),v.jsxs(xe.div,{initial:{opacity:0,y:12}
317,animate:{opacity:1,y:0},transition:{duration:.3,ease:[.2,0,0,1]},className:"w-full max-w-[380px]",children:[v.jsxs("div",{className:"mb-8 text-center",children:[v.jsx("img",{src:Wp,alt:"NEWISE",className:"mx-auto mb-4 h-12 w-auto object-contain"}),v.jsx("h1",{className:"text-2xl font-semibold tracking-tight",children:g?"비밀번호 재설정":p?"다시 오신 것을 환영합니다":"투자를 시작하세요"}),v.jsx("p",{className:"mt-1.5 text-sm text-muted-foreground",children:g?"가입한 이메일을 입력해주세요":p?"계정에 로그인하세요":"무료 계정을 만들어보세요"})]}),v.jsxs(xe.button,{whileHover:{y:-1},whileTap:{scale:.98},transition:Hx,onClick:_,className:"flex w-full items-center justify-center gap-2 rounded-xl bg-card py-3 text-sm font-medium shadow-smooth transition-colors hover:bg-secondary",children:[v.jsxs("svg",{width:"18",height:"18",viewBox:"0 0 24 24",children:[v.jsx("path",{d:"M22.56 12.25c0-.78-.07-1.53-.2-2.25H12v4.26h5.92a5.06 5.06 0 01-2.2 3.32v2.77h3.57c2.08-1.92 3.28-4.74 3.28-8.1z",fill:"#4285F4"}),v.jsx("path",{d:"M12 23c2.97 0 5.46-.98 7.28-2.66l-3.57-2.77c-.98.66-2.23 1.06-3.71 1.06-2.86 0-5.29-1.93-6.16-4.53H2.18v2.84C3.99 20.53 7.7 23 12 23z",fill:"#34A853"}),v.jsx("path",{d:"M5.84 14.09c-.22-.66-.35-1.36-.35-2.09s.13-1.43.35-2.09V7.07H2.18C1.43 8.55 1 10.22 1 12s.43 3.45 1.18 4.93l2.85-2.22.81-.62z",fill:"#FBBC05"}),v.jsx("path",{d:"M12 5.38c1.62 0 3.06.56 4.21 1.64l3.15-3.15C17.45 2.09 14.97 1 12 1 7.7 1 3.99 3.47 2.18 7.07l3.66 2.84c.87-2.6 3.3-4.53 6.16-4.53z",fill:"#EA4335"})]}),"Google로 계속하기"]}),v.jsxs("div",{className:"my-5 flex items-center gap-3",children:[v.jsx("div",{className:"h-px flex-1 bg-border"}),v.jsx("span",{className:"text-xs text-muted-foreground",children:"또는"}),v.jsx("div",{className:"h-px flex-1 bg-border"})]}),v.jsxs("form",{onSubmit:g?x:y,className:"space-y-3",children:[t==="signup"&&v.jsxs("div",{className:"relative",children:[v.jsx(m1,{size:16,className:"absolute left-3 top-1/2 -translate-y-1/2 text-muted-foreground"}),v.jsx("input",{type:"text",value:l,onChange:S=>c(S.target.value),placeholder:"이름",required:!0,className:"w-full rounded-lg bg-card py-2.5 pl-10 pr-3 text-sm shadow-smooth outline-none transition-shadow focus:shadow-focus placeholder:text-muted-foreground/60"})]}),v.jsxs("div",{className:"relative",children:[v.jsx(mR,{size:16,className:"absolute left-3 top-1/2 -translate-y-1/2 text-muted-foreground"}),v.jsx("input",{type:"email",value:n,onChange:S=>r(S.target.value),placeholder:"이메일",required:!0,className:"w-full rounded-lg bg-card py-2.5 pl-10 pr-3 text-sm shadow-smooth outline-none transition-shadow focus:shadow-focus placeholder:text-muted-foreground/60"})]}),!g&&v.jsxs("div",{className:"relative",children:[v.jsx(np,{size:16,className:"absolute left-3 top-1/2 -translate-y-1/2 text-muted-foreground"}),v.jsx("input",{type:"password",value:o,onChange:S=>a(S.target.value),placeholder:"비밀번호",required:!0,minLength:6,className:"w-full rounded-lg bg-card py-2.5 pl-10 pr-3 text-sm shadow-smooth outline-none transition-shadow focus:shadow-focus placeholder:text-muted-foreground/60"})]}),p&&!g&&v.jsx("div",{className:"text-right",children:v.jsx("button",{type:"button",onClick:()=>e("forgot"),className:"text-xs text-muted-foreground hover:text-primary",children:"비밀번호를 잊으셨나요?"})}),v.jsxs(xe.button,{whileHover:{y:-1},whileTap:{scale:.98},transition:Hx,type:"submit",disabled:d,className:"flex w-full items-center justify-center gap-2 rounded-lg bg-primary py-2.5 text-sm font-medium text-primary-foreground transition-opacity disabled:opacity-60",children:[d&&v.jsx(f1,{size:16,className:"animate-spin"}),g?"재설정 이메일 발송":p?"로그인":"회원가입"]})]}),v.jsx("p",{className:"mt-5 text-center text-xs text-muted-foreground",children:g?v.jsx("button",{onClick:()=>e("login"),className:"font-medium text-primary hover:underline",children:"로그인으로 돌아가기"}):v.jsxs(v.Fragment,{children:[p?"계정이 없으신가요?":"이미 계정이 있으신가요?"," ",v.jsx("button",{onClick:()=>e(p?"signup":"login"),className:"font-medium text-primary hover:underline",children:p?"회원가입":"로그인"})]})})]})]})},B3={duration:.2,ease:[.2,0,0,1]},z3=()=>{const[t,e]=E.useState(""),[n,r]=E.useState(""),[o,a]=E.useState(!1),[l,c]=E.useState(!1),[d,f]=E.useState(!1),p=em();E.useEffect(()=>{window.location.hash.includes("type=recovery")&&f(!0);const{data:{subscription:y}}=$n.auth.onAuthStateChange(_=>{_==="PASSWORD_RECOVERY"&&f(!0)});return()=>y.unsubscribe()},[]);const g=async x=>{if(x.preventDefault(),t!==n){Ln.error("비밀번호가 일치하지 않습니다.");return}if(t.length<6){Ln.error("비밀번호는 6자 이상이어야 합니다.");return}a(!0);try{const{error:y}=await $n.auth.updateUser({password:t});if(y)throw y;c(!0),Ln.success("비밀번호가 변경되었습니다!"),setTimeout(()=>p("/dashboard"),2e3)}catch(y){Ln.error(y.message||"비밀번호 변경에 실패했습니다.")}finally{a(!1)}};return d?l?v.jsx("div",{className:"flex min-h-screen items-center justify-center bg-background p-4",children:v.jsxs(xe.div,{initial:{opacity:0,scale:.95}
317,animate:{opacity:1,scale:1},className:"text-center",children:[v.jsx(cR,{size:48,className:"mx-auto mb-4 text-accent"}),v.jsx("h2",{className:"text-lg font-semibold",children:"비밀번호가 변경되었습니다"}),v.jsx("p",{className:"mt-1 text-sm text-muted-foreground",children:"잠시 후 대시보드로 이동합니다..."})]})}):v.jsxs("div",{className:"flex min-h-screen items-center justify-center bg-background p-4",children:[v.jsx(Gm,{title:"비밀번호 재설정 | NEWISE",description:"이메일로 받은 링크를 통해 NEWISE 계정의 새 비밀번호를 설정하세요.",noindex:!0}),v.jsxs(xe.div,{initial:{opacity:0,y:12},animate:{opacity:1,y:0},transition:{duration:.3,ease:[.2,0,0,1]},className:"w-full max-w-[380px]",children:[v.jsxs("div",{className:"mb-8 text-center",children:[v.jsx("div",{className:"mx-auto mb-4 flex h-12 w-12 items-center justify-center rounded-xl bg-primary font-mono text-lg font-semibold text-primary-foreground",children:"AI"}),v.jsx("h1",{className:"text-2xl font-semibold tracking-tight",children:"새 비밀번호 설정"}),v.jsx("p",{className:"mt-1.5 text-sm text-muted-foreground",children:"새로운 비밀번호를 입력해주세요."})]}),v.jsxs("form",{onSubmit:g,className:"space-y-3",children:[v.jsxs("div",{className:"relative",children:[v.jsx(np,{size:16,className:"absolute left-3 top-1/2 -translate-y-1/2 text-muted-foreground"}),v.jsx("input",{type:"password",value:t,onChange:x=>e(x.target.value),placeholder:"새 비밀번호",required:!0,minLength:6,className:"w-full rounded-lg bg-card py-2.5 pl-10 pr-3 text-sm shadow-smooth outline-none transition-shadow focus:shadow-focus placeholder:text-muted-foreground/60"})]}),v.jsxs("div",{className:"relative",children:[v.jsx(np,{size:16,className:"absolute left-3 top-1/2 -translate-y-1/2 text-muted-foreground"}),v.jsx("input",{type:"password",value:n,onChange:x=>r(x.target.value),placeholder:"비밀번호 확인",required:!0,minLength:6,className:"w-full rounded-lg bg-card py-2.5 pl-10 pr-3 text-sm shadow-smooth outline-none transition-shadow focus:shadow-focus placeholder:text-muted-foreground/60"})]}),v.jsxs(xe.button,{whileHover:{y:-1},whileTap:{scale:.98},transition:B3,type:"submit",disabled:o,className:"flex w-full items-center justify-center gap-2 rounded-lg bg-primary py-2.5 text-sm font-medium text-primary-foreground transition-opacity disabled:opacity-60",children:[o&&v.jsx(f1,{size:16,className:"animate-spin"}),"비밀번호 변경"]})]}),v.jsx("p",{className:"mt-5 text-center",children:v.jsxs("button",{onClick:()=>p("/auth"),className:"flex items-center justify-center gap-1 mx-auto text-xs text-muted-foreground hover:text-foreground",children:[v.jsx(oR,{size:12}),"로그인으로 돌아가기"]})})]})]}):v.jsx("div",{className:"flex min-h-screen items-center justify-center bg-background p-4",children:v.jsxs("div",{className:"text-center",children:[v.jsx("p",{className:"text-sm text-muted-foreground",children:"유효하지 않은 링크입니다."}),v.jsx("button",{onClick:()=>p("/auth"),className:"mt-3 text-sm font-medium text-primary hover:underline",children:"로그인으로 돌아가기"})]})})},W3=()=>{const t=fl();return E.useEffect(()=>{console.error("404 Error: User attempted to access non-existent route:",t.pathname)},[t.pathname]),v.jsx("div",{className:"flex min-h-screen items-center justify-center bg-muted",children:v.jsxs("div",{className:"text-center",children:[v.jsx("h1",{className:"mb-4 text-4xl font-bold",children:"404"}),v.jsx("p",{className:"mb-4 text-xl text-muted-foreground",children:"Oops! Page not found"}),v.jsx("a",{href:"/",className:"text-primary underline hover:text-primary/90",children:"Return to Home"})]})})},H3=E.lazy(()=>Ro(()=>import("./Index-BcxNMWW1.js"),__vite__mapDeps([0,1,2,3,4,5]))),q3=E.lazy(()=>Ro(()=>import("./AdminPage-DGzUojCU.js"),__vite__mapDeps([6,1,2,7]))),K3=E.lazy(()=>Ro(()=>import("./EnrollPage-DTIfrvOV.js"),__vite__mapDeps([8,4,7]))),G3=E.lazy(()=>Ro(()=>import("./OnboardingPage-Ddepqmy8.js"),__vite__mapDeps([9,3,2]))),Q3=E.lazy(()=>Ro(()=>import("./TermsPage-CZKZ2qnF.js"),[])),Y3=E.lazy(()=>Ro(()=>import("./PrivacyPage-BJ7NudD9.js"),[])),J3=new fC,Qm=()=>v.jsx("div",{className:"flex min-h-screen items-center justify-center bg-background",children:v.jsx("div",{className:"h-6 w-6 animate-spin rounded-full border-2 border-primary border-t-transparent"})}),qx=({children:t})=>{const{user:e,loading:n}=yl();return n?v.jsx(Qm,{}):e?v.jsx(v.Fragment,{children:t}):v.jsx(Wa,{to:"/auth",replace:!0})},X3=({children:t})=>{const{user:e,loading:n}=yl(),{isStaff:r,isLoading:o}=$4();return n||o?v.jsx(Qm,{}):e?r?v.jsx(v.Fragment,{children:t}):v.jsx(Wa,{to:"/dashboard",replace:!0}):v.jsx(Wa,{to:"/auth",replace:!0})},Z3=({children:t})=>{const{user:e,loading:n}=yl();return n?null:e?v.jsx(Wa,{to:"/dashboard",replace:!0}):v.jsx(v.Fragment,{children:t})},e$=()=>v.jsx(mC,{client:J3,children:v.jsx(OI,{children:v.jsx(D4,{children:v.jsxs(XO,{delayDuration:0,
317children:[v.jsx(cj,{}),v.jsx(XP,{}),v.jsx(xP,{children:v.jsx(E.Suspense,{fallback:v.jsx(Qm,{}),children:v.jsxs(yP,{children:[v.jsx(fn,{path:"/",element:v.jsx(E3,{})}),v.jsx(fn,{path:"/landing",element:v.jsx(Wa,{to:"/",replace:!0})}),v.jsx(fn,{path:"/enroll",element:v.jsx(K3,{})}),v.jsx(fn,{path:"/terms",element:v.jsx(Q3,{})}),v.jsx(fn,{path:"/privacy",element:v.jsx(Y3,{})}),v.jsx(fn,{path:"/auth",element:v.jsx(Z3,{children:v.jsx(V3,{})})}),v.jsx(fn,{path:"/reset-password",element:v.jsx(z3,{})}),v.jsx(fn,{path:"/onboarding",element:v.jsx(qx,{children:v.jsx(G3,{})})}),v.jsx(fn,{path:"/admin",element:v.jsx(X3,{children:v.jsx(q3,{})})}),v.jsx(fn,{path:"/dashboard",element:v.jsx(qx,{children:v.jsx(H3,{})})}),v.jsx(fn,{path:"*",element:v.jsx(W3,{})})]})})})]})})})});fk.createRoot(document.getElementById("root")).render(v.jsx(cb,{children:v.jsx(e$,{})}));export{B4 as $,fx as A,lR as B,uR as C,dt as D,xO as E,Dc as F,Ts as G,Lc as H,fj as I,PO as J,U1 as K,f1 as L,Fb as M,tm as N,AO as O,nm as P,RO as Q,CO as R,xR as S,ER as T,h1 as U,ni as V,dR as W,g1 as X,p1 as Y,PR as Z,Fc as _,pC as a,qp as a0,xs as a1,Pr as a2,N4 as a3,O4 as a4,j4 as a5,rA as a6,oR as a7,u$ as a8,c$ as a9,vR as aA,Gm as aB,Wp as aC,F4 as aa,dA as ab,LA as ac,Nc as ad,Q4 as ae,h$ as af,m1 as ag,n$ as ah,a1 as ai,K as aj,mR as ak,iR as al,om as am,_R as an,cl as ao,Df as ap,Ua as aq,cC as ar,St as as,qt as at,pb as au,l1 as av,F0 as aw,Kc as ax,a$ as ay,r$ as az,i0 as b,Oe as c,Ln as d,d$ as e,$4 as f,em as g,i$ as h,o$ as i,v as j,ZO as k,pR as l,xe as m,rp as n,aR as o,c1 as p,ul as q,E as r,$n as s,f$ as t,yl as u,np as v,d1 as w,Kt as x,Ub as y,Un as z};

Line numbers count LF bytes from the start of the resource, as the search results do. Vendor segments are library code the classifier recognised; they are stored but not indexed. Bytes are shown as Latin1 characters, one per byte.