vendor: 4,138 bytes, lines 1-9
1var Gp=e=>{throw TypeError(e)};var eu=(e,t,n)=>t.has(e)||Gp("Cannot "+n);var P=(e,t,n)=>(eu(e,t,"read from private field"),n?n.call(e):t.get(e)),re=(e,t,n)=>t.has(e)?Gp("Cannot add the same private member more than once"):t instanceof WeakSet?t.add(e):t.set(e,n),Y=(e,t,n,r)=>(eu(e,t,"write to private field"),r?r.call(e,n):t.set(e,n),n),Ye=(e,t,n)=>(eu(e,t,"access private method"),n);var Pa=(e,t,n,r)=>({set _(s){Y(e,t,s,n)},get _(){return P(e,t,r)}});function JS(e,t){for(var n=0;n<t.length;n++){const r=t[n];if(typeof r!="string"&&!Array.isArray(r)){for(const s in r)if(s!=="default"&&!(s in e)){const i=Object.getOwnPropertyDescriptor(r,s);i&&Object.defineProperty(e,s,i.get?i:{enumerable:!0,get:()=>r[s]})}}}return Object.freeze(Object.defineProperty(e,Symbol.toStringTag,{value:"Module"}))}(function(){const t=document.createElement("link").relList;if(t&&t.supports&&t.supports("modulepreload"))return;for(const s of document.querySelectorAll('link[rel="modulepreload"]'))r(s);new MutationObserver(s=>{for(const i of s)if(i.type==="childList")for(const o of i.addedNodes)o.tagName==="LINK"&&o.rel==="modulepreload"&&r(o)}).observe(document,{childList:!0,subtree:!0});function n(s){const i={};return s.integrity&&(i.integrity=s.integrity),s.referrerPolicy&&(i.referrerPolicy=s.referrerPolicy),s.crossOrigin==="use-credentials"?i.credentials="include":s.crossOrigin==="anonymous"?i.credentials="omit":i.credentials="same-origin",i}function r(s){if(s.ep)return;s.ep=!0;const i=n(s);fetch(s.href,i)}})();function Dv(e){return e&&e.__esModule&&Object.prototype.hasOwnProperty.call(e,"default")?e.default:e}var Lv={exports:{}},pc={},Mv={exports:{}},ee={};/** 2 * @license React 3 * react.production.min.js 4 * 5 * Copyright (c) Facebook, Inc. and its affiliates. 6 * 7 * This source code is licensed under the MIT license found in the 8 * LICENSE file in the root directory of this source tree. 9 */var ca=Symbol.for("react.element"),XS=Symbol.for("react.portal"),ZS=Symbol.for("react.fragment"),e_=Symbol.for("react.strict_mode"),t_=Symbol.for("react.profiler"),n_=Symbol.for("react.provider"),r_=Symbol.for("react.context"),s_=Symbol.for("react.forward_ref"),i_=Symbol.for("react.suspense"),o_=Symbol.for("react.memo"),a_=Symbol.for("react.lazy"),Yp=Symbol.iterator;function l_(e){return e===null||typeof e!="object"?null:(e=Yp&&e[Yp]||e["@@iterator"],typeof e=="function"?e:null)}var $v={isMounted:function(){return!1},enqueueForceUpdate:function(){},enqueueReplaceState:function(){},enqueueSetState:function(){}},Vv=Object.assign,Fv={};function ji(e,t,n){this.props=e,this.context=t,this.refs=Fv,this.updater=n||$v}ji.prototype.isReactComponent={};ji.prototype.setState=function(e,t){if(typeof e!="object"&&typeof e!="function"&&e!=null)throw Error("setState(...): takes an object of state variables to update or a function which returns an object of state variables.");this.updater.enqueueSetState(this,e,t,"setState")};ji.prototype.forceUpdate=function(e){this.updater.enqueueForceUpdate(this,e,"forceUpdate")};function Uv(){}Uv.prototype=ji.prototype;function Wh(e,t,n){this.props=e,this.context=t,this.refs=Fv,this.updater=n||$v}var Hh=Wh.prototype=new Uv;Hh.constructor=Wh;Vv(Hh,ji.prototype);Hh.isPureReactComponent=!0;var Qp=Array.isArray,Bv=Object.prototype.hasOwnProperty,Kh={current:null},zv={key:!0,ref:!0,__self:!0,__source:!0};function Wv(e,t,n){var r,s={},i=null,o=null;if(t!=null)for(r in t.ref!==void 0&&(o=t.ref),t.key!==void 0&&(i=""+t.key),t)Bv.call(t,r)&&!zv.hasOwnProperty(r)&&(s[r]=t[r]);var a=arguments.length-2;if(a===1)s.children=n;else if(1<a){for(var l=Array(a),c=0;c<a;c++)l[c]=arguments[c+2];s.children=l}if(e&&e.defaultProps)for(r in a=e.defaultProps,a)s[r]===void 0&&(s[r]=a[r]);return{$$typeof:ca,type:e,key:i,ref:o,props:s,_owner:Kh.current}}function c_(e,t){return{$$typeof:ca,type:e.type,key:t,ref:e.ref,props:e.props,_owner:e._owner}}function qh(e){return typeof e=="object"&&e!==null&&e.$$typeof===ca}function u_(e){var t={"=":"=0",":":"=2"};return"$"+e.replace(/[=:]/g,function(n){return t[n]})}var Jp=/\/+/g;function tu(e,t){return typeof e=="object"&&e!==null&&e.key!=null?u_(""+e.key):t.toString(36)}
vendor: 4,786 bytes, lines 9-17
9function al(e,t,n,r,s){var i=typeof e;(i==="undefined"||i==="boolean")&&(e=null);var o=!1;if(e===null)o=!0;else switch(i){case"string":case"number":o=!0;break;case"object":switch(e.$$typeof){case ca:case XS:o=!0}}if(o)return o=e,s=s(o),e=r===""?"."+tu(o,0):r,Qp(s)?(n="",e!=null&&(n=e.replace(Jp,"$&/")+"/"),al(s,t,n,"",function(c){return c})):s!=null&&(qh(s)&&(s=c_(s,n+(!s.key||o&&o.key===s.key?"":(""+s.key).replace(Jp,"$&/")+"/")+e)),t.push(s)),1;if(o=0,r=r===""?".":r+":",Qp(e))for(var a=0;a<e.length;a++){i=e[a];var l=r+tu(i,a);o+=al(i,t,n,l,s)}else if(l=l_(e),typeof l=="function")for(e=l.call(e),a=0;!(i=e.next()).done;)i=i.value,l=r+tu(i,a++),o+=al(i,t,n,l,s);else if(i==="object")throw t=String(e),Error("Objects are not valid as a React child (found: "+(t==="[object Object]"?"object with keys {"+Object.keys(e).join(", ")+"}":t)+"). If you meant to render a collection of children, use an array instead.");return o}function Aa(e,t,n){if(e==null)return e;var r=[],s=0;return al(e,r,"","",function(i){return t.call(n,i,s++)}),r}function d_(e){if(e._status===-1){var t=e._result;t=t(),t.then(function(n){(e._status===0||e._status===-1)&&(e._status=1,e._result=n)},function(n){(e._status===0||e._status===-1)&&(e._status=2,e._result=n)}),e._status===-1&&(e._status=0,e._result=t)}if(e._status===1)return e._result.default;throw e._result}var at={current:null},ll={transition:null},h_={ReactCurrentDispatcher:at,ReactCurrentBatchConfig:ll,ReactCurrentOwner:Kh};function Hv(){throw Error("act(...) is not supported in production builds of React.")}ee.Children={map:Aa,forEach:function(e,t,n){Aa(e,function(){t.apply(this,arguments)},n)},count:function(e){var t=0;return Aa(e,function(){t++}),t},toArray:function(e){return Aa(e,function(t){return t})||[]},only:function(e){if(!qh(e))throw Error("React.Children.only expected to receive a single React element child.");return e}};ee.Component=ji;ee.Fragment=ZS;ee.Profiler=t_;ee.PureComponent=Wh;ee.StrictMode=e_;ee.Suspense=i_;ee.__SECRET_INTERNALS_DO_NOT_USE_OR_YOU_WILL_BE_FIRED=h_;ee.act=Hv;ee.cloneElement=function(e,t,n){if(e==null)throw Error("React.cloneElement(...): The argument must be a React element, but you passed "+e+".");var r=Vv({},e.props),s=e.key,i=e.ref,o=e._owner;if(t!=null){if(t.ref!==void 0&&(i=t.ref,o=Kh.current),t.key!==void 0&&(s=""+t.key),e.type&&e.type.defaultProps)var a=e.type.defaultProps;for(l in t)Bv.call(t,l)&&!zv.hasOwnProperty(l)&&(r[l]=t[l]===void 0&&a!==void 0?a[l]:t[l])}var l=arguments.length-2;if(l===1)r.children=n;else if(1<l){a=Array(l);for(var c=0;c<l;c++)a[c]=arguments[c+2];r.children=a}return{$$typeof:ca,type:e.type,key:s,ref:i,props:r,_owner:o}};ee.createContext=function(e){return e={$$typeof:r_,_currentValue:e,_currentValue2:e,_threadCount:0,Provider:null,Consumer:null,_defaultValue:null,_globalName:null},e.Provider={$$typeof:n_,_context:e},e.Consumer=e};ee.createElement=Wv;ee.createFactory=function(e){var t=Wv.bind(null,e);return t.type=e,t};ee.createRef=function(){return{current:null}};ee.forwardRef=function(e){return{$$typeof:s_,render:e}};ee.isValidElement=qh;ee.lazy=function(e){return{$$typeof:a_,_payload:{_status:-1,_result:e},_init:d_}};ee.memo=function(e,t){return{$$typeof:o_,type:e,compare:t===void 0?null:t}};ee.startTransition=function(e){var t=ll.transition;ll.transition={};try{e()}finally{ll.transition=t}};ee.unstable_act=Hv;ee.useCallback=function(e,t){return at.current.useCallback(e,t)};ee.useContext=function(e){return at.current.useContext(e)};ee.useDebugValue=function(){};ee.useDeferredValue=function(e){return at.current.useDeferredValue(e)};ee.useEffect=function(e,t){return at.current.useEffect(e,t)};ee.useId=function(){return at.current.useId()};ee.useImperativeHandle=function(e,t,n){return at.current.useImperativeHandle(e,t,n)};ee.useInsertionEffect=function(e,t){return at.current.useInsertionEffect(e,t)};ee.useLayoutEffect=function(e,t){return at.current.useLayoutEffect(e,t)};ee.useMemo=function(e,t){return at.current.useMemo(e,t)};ee.useReducer=function(e,t,n){return at.current.useReducer(e,t,n)};ee.useRef=function(e){return at.current.useRef(e)};ee.useState=function(e){return at.current.useState(e)};ee.useSyncExternalStore=function(e,t,n){return at.current.useSyncExternalStore(e,t,n)};ee.useTransition=function(){return at.current.useTransition()};ee.version="18.3.1";Mv.exports=ee;var b=Mv.exports;const I=Dv(b),Kv=JS({__proto__:null,default:I},[b]);/** 10 * @license React 11 * react-jsx-runtime.production.min.js 12 * 13 * Copyright (c) Facebook, Inc. and its affiliates. 14 * 15 * This source code is licensed under the MIT license found in the 16 * LICENSE file in the root directory of this source tree. 17 */var f_=b,p_=Symbol.for("react.element"),m_=Symbol.for("react.fragment"),g_=Object.prototype.hasOwnProperty,y_=f_.__SECRET_INT
vendor: 11,413 bytes, lines 17-34
17ERNALS_DO_NOT_USE_OR_YOU_WILL_BE_FIRED.ReactCurrentOwner,v_={key:!0,ref:!0,__self:!0,__source:!0};function qv(e,t,n){var r,s={},i=null,o=null;n!==void 0&&(i=""+n),t.key!==void 0&&(i=""+t.key),t.ref!==void 0&&(o=t.ref);for(r in t)g_.call(t,r)&&!v_.hasOwnProperty(r)&&(s[r]=t[r]);if(e&&e.defaultProps)for(r in t=e.defaultProps,t)s[r]===void 0&&(s[r]=t[r]);return{$$typeof:p_,type:e,key:i,ref:o,props:s,_owner:y_.current}}pc.Fragment=m_;pc.jsx=qv;pc.jsxs=qv;Lv.exports=pc;var p=Lv.exports,Gv={exports:{}},kt={},Yv={exports:{}},Qv={};/** 18 * @license React 19 * scheduler.production.min.js 20 * 21 * Copyright (c) Facebook, Inc. and its affiliates. 22 * 23 * This source code is licensed under the MIT license found in the 24 * LICENSE file in the root directory of this source tree. 25 */(function(e){function t(C,A){var L=C.length;C.push(A);e:for(;0<L;){var q=L-1>>>1,B=C[q];if(0<s(B,A))C[q]=A,C[L]=B,L=q;else break e}}function n(C){return C.length===0?null:C[0]}function r(C){if(C.length===0)return null;var A=C[0],L=C.pop();if(L!==A){C[0]=L;e:for(var q=0,B=C.length,Z=B>>>1;q<Z;){var te=2*(q+1)-1,Pe=C[te],Ge=te+1,se=C[Ge];if(0>s(Pe,L))Ge<B&&0>s(se,Pe)?(C[q]=se,C[Ge]=L,q=Ge):(C[q]=Pe,C[te]=L,q=te);else if(Ge<B&&0>s(se,L))C[q]=se,C[Ge]=L,q=Ge;else break e}}return A}function s(C,A){var L=C.sortIndex-A.sortIndex;return L!==0?L:C.id-A.id}if(typeof performance=="object"&&typeof performance.now=="function"){var i=performance;e.unstable_now=function(){return i.now()}}else{var o=Date,a=o.now();e.unstable_now=function(){return o.now()-a}}var l=[],c=[],u=1,d=null,h=3,f=!1,w=!1,y=!1,x=typeof setTimeout=="function"?setTimeout:null,m=typeof clearTimeout=="function"?clearTimeout:null,g=typeof setImmediate<"u"?setImmediate:null;typeof navigator<"u"&&navigator.scheduling!==void 0&&navigator.scheduling.isInputPending!==void 0&&navigator.scheduling.isInputPending.bind(navigator.scheduling);function v(C){for(var A=n(c);A!==null;){if(A.callback===null)r(c);else if(A.startTime<=C)r(c),A.sortIndex=A.expirationTime,t(l,A);else break;A=n(c)}}function S(C){if(y=!1,v(C),!w)if(n(l)!==null)w=!0,K(_);else{var A=n(c);A!==null&&V(S,A.startTime-C)}}function _(C,A){w=!1,y&&(y=!1,m(T),T=-1),f=!0;var L=h;try{for(v(A),d=n(l);d!==null&&(!(d.expirationTime>A)||C&&!U());){var q=d.callback;if(typeof q=="function"){d.callback=null,h=d.priorityLevel;var B=q(d.expirationTime<=A);A=e.unstable_now(),typeof B=="function"?d.callback=B:d===n(l)&&r(l),v(A)}else r(l);d=n(l)}if(d!==null)var Z=!0;else{var te=n(c);te!==null&&V(S,te.startTime-A),Z=!1}return Z}finally{d=null,h=L,f=!1}}var k=!1,E=null,T=-1,j=5,O=-1;function U(){return!(e.unstable_now()-O<j)}function M(){if(E!==null){var C=e.unstable_now();O=C;var A=!0;try{A=E(!0,C)}finally{A?J():(k=!1,E=null)}}else k=!1}var J;if(typeof g=="function")J=function(){g(M)};else if(typeof MessageChannel<"u"){var D=new MessageChannel,X=D.port2;D.port1.onmessage=M,J=function(){X.postMessage(null)}}else J=function(){x(M,0)};function K(C){E=C,k||(k=!0,J())}function V(C,A){T=x(function(){C(e.unstable_now())},A)}e.unstable_IdlePriority=5,e.unstable_ImmediatePriority=1,e.unstable_LowPriority=4,e.unstable_NormalPriority=3,e.unstable_Profiling=null,e.unstable_UserBlockingPriority=2,e.unstable_cancelCallback=function(C){C.callback=null},e.unstable_continueExecution=function(){w||f||(w=!0,K(_))},e.unstable_forceFrameRate=function(C){0>C||125<C?console.error("forceFrameRate takes a positive int between 0 and 125, forcing frame rates higher than 125 fps is not supported"):j=0<C?Math.floor(1e3/C):5},e.unstable_getCurrentPriorityLevel=function(){return h},e.unstable_getFirstCallbackNode=function(){return n(l)},e.unstable_next=function(C){switch(h){case 1:case 2:case 3:var A=3;break;default:A=h}var L=h;h=A;try{return C()}finally{h=L}},e.unstable_pauseExecution=function(){},e.unstable_requestPaint=function(){},e.unstable_runWithPriority=function(C,A){switch(C){case 1:case 2:case 3:case 4:case 5:break;default:C=3}var L=h;h=C;try{return A()}finally{h=L}},e.unstable_scheduleCallback=function(C,A,L){var q=e.unstable_now();switch(typeof L=="object"&&L!==null?(L=L.delay,L=typeof L=="number"&&0<L?q+L:q):L=q,C){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=L+B,C={id:u++,callback:A,priorityLevel:C,startTime:L,expirationTime:B,sortIndex:-1},L>q?(C.sortIndex=L,t(c,C),n(l)===null&&C===n(c)&&(y?(m(T),T=-1):y=!0,V(S,L-q))):(C.sortIndex=B,t(l,C),w||f||(w=!0,K(_))),C},e.unstable_shouldYield=U,e.unstable_wrapCallback=function(C){var A=h;return function(){var L=h;h=A;try{return C.apply(this,arguments)}finally{h=L}}}})(Qv);Yv.exports=Qv;var w_=Yv.exports;/** 26 * @license React 27 * react-dom.production.min.js 28 * 29 * Copyright (c) Facebook, Inc. and its affiliates. 30 * 31 * This source code is licensed under the MIT license found in the 32 * LICENSE file in the root directory of this source tree. 33 */var x_=b,St=w_;function N(e){for(var t="https://reactjs.org/docs/error-decoder.html?invariant="+e,n=1;n<arguments.length;n++)t+="&args[]="+encodeURIComponent(arguments[n]);return"Minified React error #"+e+"; visit "+t+" for the full message or use the non-minified dev environment for full errors and additional helpful warnings."}var Jv=new Set,Co={};function ys(e,t){xi(e,t),xi(e+"Capture",t)}function xi(e,t){for(Co[e]=t,e=0;e<t.length;e++)Jv.add(t[e])}var Rn=!(typeof window>"u"||typeof window.document>"u"||typeof window.document.createElement>"u"),sd=Object.prototype.hasOwnProperty,b_=/^[: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]*$/,Xp={},Zp={};function S_(e){return sd.call(Zp,e)?!0:sd.call(Xp,e)?!1:b_.test(e)?Zp[e]=!0:(Xp[e]=!0,!1)}function __(e,t,n,r){if(n!==null&&n.type===0)return!1;switch(typeof t){case"function":case"symbol":return!0;case"boolean":return r?!1:n!==null?!n.acceptsBooleans:(e=e.toLowerCase().slice(0,5),e!=="data-"&&e!=="aria-");default:return!1}}function k_(e,t,n,r){if(t===null||typeof t>"u"||__(e,t,n,r))return!0;if(r)return!1;if(n!==null)switch(n.type){case 3:return!t;case 4:return t===!1;case 5:return isNaN(t);case 6:return isNaN(t)||1>t}return!1}function lt(e,t,n,r,s,i,o){this.acceptsBooleans=t===2||t===3||t===4,this.attributeName=r,this.attributeNamespace=s,this.mustUseProperty=n,this.propertyName=e,this.type=t,this.sanitizeURL=i,this.removeEmptyString=o}var Ke={};"children dangerouslySetInnerHTML defaultValue defaultChecked innerHTML suppressContentEditableWarning suppressHydrationWarning style".split(" ").forEach(function(e){Ke[e]=new lt(e,0,!1,e,null,!1,!1)});[["acceptCharset","accept-charset"],["className","class"],["htmlFor","for"],["httpEquiv","http-equiv"]].forEach(function(e){var t=e[0];Ke[t]=new lt(t,1,!1,e[1],null,!1,!1)});["contentEditable","draggable","spellCheck","value"].forEach(function(e){Ke[e]=new lt(e,2,!1,e.toLowerCase(),null,!1,!1)});["autoReverse","externalResourcesRequired","focusable","preserveAlpha"].forEach(function(e){Ke[e]=new lt(e,2,!1,e,null,!1,!1)});"allowFullScreen async autoFocus autoPlay controls default defer disabled disablePictureInPicture disableRemotePlayback formNoValidate hidden loop noModule noValidate open playsInline readOnly required reversed scoped seamless itemScope".split(" ").forEach(function(e){Ke[e]=new lt(e,3,!1,e.toLowerCase(),null,!1,!1)});["checked","multiple","muted","selected"].forEach(function(e){Ke[e]=new lt(e,3,!0,e,null,!1,!1)});["capture","download"].forEach(function(e){Ke[e]=new lt(e,4,!1,e,null,!1,!1)});["cols","rows","size","span"].forEach(function(e){Ke[e]=new lt(e,6,!1,e,null,!1,!1)});["rowSpan","start"].forEach(function(e){Ke[e]=new lt(e,5,!1,e.toLowerCase(),null,!1,!1)});var Gh=/[\-:]([a-z])/g;function Yh(e){return e[1].toUpperCase()}"accent-height alignment-baseline arabic-form baseline-shift cap-height clip-path clip-rule color-interpolation color-interpolation-filters color-profile color-rendering dominant-baseline enable-background fill-opacity fill-rule flood-color flood-opacity font-family font-size font-size-adjust font-stretch font-style font-variant font-weight glyph-name glyph-orientation-horizontal glyph-orientation-vertical horiz-adv-x horiz-origin-x image-rendering letter-spacing lighting-color marker-end marker-mid marker-start overline-position overline-thickness paint-order panose-1 pointer-events rendering-intent shape-rendering stop-color stop-opacity strikethrough-position strikethrough-thickness stroke-dasharray stroke-dashoffset stroke-linecap stroke-linejoin stroke-miterlimit stroke-opacity stroke-width text-anchor text-decoration text-rendering underline-position underline-thickness unicode-bidi unicode-range units-per-em v-alphabetic v-hanging v-ideographic v-mathematical vector-effect vert-adv-y vert-origin-x vert-origin-y word-spacing writing-mode xmlns:xlink x-height".split(" ").forEach(function(e){var t=e.replace(Gh,Yh);Ke[t]=new lt(t,1,!1,e,null,!1,!1)});"xlink:actuate xlink:arcrole xlink:role xlink:show xlink:title xlink:type".split(" ").forEach(function(e){var t=e.replace(Gh,Yh);Ke[t]=new lt(t,1,!1,e,"http://www.w3.org/1999/xlink",!1,!1)});["xml:base","xml:lang","xml:space"].forEach(function(e){var t=e.replace(Gh,Yh);Ke[t]=new lt(t,1,!1,e,"http://www.w3.org/XML/1998/namespace",!1,!1)});["tabIndex","crossOrigin"].forEach(function(e){Ke[e]=new lt(e,1,!1,e.toLowerCase(),null,!1,!1)});Ke.xlinkHref=new lt("xlinkHref",1,!1,"xlink:href","http://www.w3.org/1999/xlink",!0,!1);["src","href","action","formAction"].forEach(function(e){Ke[e]=new lt(e,1,!1,e.toLowerCase(),null,!0,!0)});function Qh(e,t,n,r){var s=Ke.hasOwnProperty(t)?Ke[t]:null;(s!==null?s.type!==0:r||!(2<t.length)||t[0]!=="o"&&t[0]!=="O"||t[1]!=="n"&&t[1]!=="N")&&(k_(t,n,s,r)&&(n=null),r||s===null?S_(t)&&(n===null?e.removeAttribute(t):e.setAttribute(t,""+n)):s.mustUseProperty?e[s.propertyName]=n===null?s.type===3?!1:"":n:(t=s.attributeName,r=s.attributeNamespace,n===null?e.removeAttribute(t):(s=s.type,n=s===3||s===4&&n===!0?"":""+n,r?e.setAttributeNS(r,t,n):e.setAttribute(t,n))))}var Vn=x_.__SECRET_INTERNALS_DO_NOT_USE_OR_YOU_WILL_BE_FIRED,Ra=Symbol.for("react.element"),$s=Symbol.for("react.portal"),Vs=Symbol.for("react.fragment"),Jh=Symbol.for("react.strict_mode"),id=Symbol.for("react.profiler"),Xv=Symbol.for("react.provider"),Zv=Symbol.for("react.context"),Xh=Symbol.for("react.forward_ref"),od=Symbol.for("react.suspense"),ad=Symbol.for("react.suspense_list"),Zh=Symbol.for("react.memo"),Zn=Symbol.for("react.lazy"),e0=Symbol.for("react.offscreen"),em=Symbol.iterator;function Hi(e){return e===null||typeof e!="object"?null:(e=em&&e[em]||e["@@iterator"],typeof e=="function"?e:null)}var be=Object.assign,nu;function so(e){if(nu===void 0)try{throw Error()}catch(n){var t=n.stack.trim().match(/\n( *(at )?)/);nu=t&&t[1]||""}return` 34`+nu+e}var ru=!1;function su(e,t){if(!e||ru)return"";ru=!0;var n=Error.prepareStackTrace;Error.prepareStackTrace=void 0;try{if(t)if(t=function(){throw Error()},Object.defineProperty(t.prototype,"props",{set:function(){throw Error()}}),typeof Reflect=="object"&&Reflect.construct){try{Reflect.construct(t,[])}catch(c){var r=c}Reflect.construct(e,[],t)}else{try{t.call()}catch(c){r=c}e.call(t.prototype)}else{try{throw Error()}catch(c){r=c}e()}}
vendor: 4,643 bytes, lines 34-37
34catch(c){if(c&&r&&typeof c.stack=="string"){for(var s=c.stack.split(` 35`),i=r.stack.split(` 36`),o=s.length-1,a=i.length-1;1<=o&&0<=a&&s[o]!==i[a];)a--;for(;1<=o&&0<=a;o--,a--)if(s[o]!==i[a]){if(o!==1||a!==1)do if(o--,a--,0>a||s[o]!==i[a]){var l=` 37`+s[o].replace(" at new "," at ");return e.displayName&&l.includes("<anonymous>")&&(l=l.replace("<anonymous>",e.displayName)),l}while(1<=o&&0<=a);break}}}finally{ru=!1,Error.prepareStackTrace=n}return(e=e?e.displayName||e.name:"")?so(e):""}function E_(e){switch(e.tag){case 5:return so(e.type);case 16:return so("Lazy");case 13:return so("Suspense");case 19:return so("SuspenseList");case 0:case 2:case 15:return e=su(e.type,!1),e;case 11:return e=su(e.type.render,!1),e;case 1:return e=su(e.type,!0),e;default:return""}}function ld(e){if(e==null)return null;if(typeof e=="function")return e.displayName||e.name||null;if(typeof e=="string")return e;switch(e){case Vs:return"Fragment";case $s:return"Portal";case id:return"Profiler";case Jh:return"StrictMode";case od:return"Suspense";case ad:return"SuspenseList"}if(typeof e=="object")switch(e.$$typeof){case Zv:return(e.displayName||"Context")+".Consumer";case Xv:return(e._context.displayName||"Context")+".Provider";case Xh:var t=e.render;return e=e.displayName,e||(e=t.displayName||t.name||"",e=e!==""?"ForwardRef("+e+")":"ForwardRef"),e;case Zh:return t=e.displayName||null,t!==null?t:ld(e.type)||"Memo";case Zn:t=e._payload,e=e._init;try{return ld(e(t))}catch{}}return null}function T_(e){var t=e.type;switch(e.tag){case 24:return"Cache";case 9:return(t.displayName||"Context")+".Consumer";case 10:return(t._context.displayName||"Context")+".Provider";case 18:return"DehydratedFragment";case 11:return e=t.render,e=e.displayName||e.name||"",t.displayName||(e!==""?"ForwardRef("+e+")":"ForwardRef");case 7:return"Fragment";case 5:return t;case 4:return"Portal";case 3:return"Root";case 6:return"Text";case 16:return ld(t);case 8:return t===Jh?"StrictMode":"Mode";case 22:return"Offscreen";case 12:return"Profiler";case 21:return"Scope";case 13:return"Suspense";case 19:return"SuspenseList";case 25:return"TracingMarker";case 1:case 0:case 17:case 2:case 14:case 15:if(typeof t=="function")return t.displayName||t.name||null;if(typeof t=="string")return t}return null}function Sr(e){switch(typeof e){case"boolean":case"number":case"string":case"undefined":return e;case"object":return e;default:return""}}function t0(e){var t=e.type;return(e=e.nodeName)&&e.toLowerCase()==="input"&&(t==="checkbox"||t==="radio")}function C_(e){var t=t0(e)?"checked":"value",n=Object.getOwnPropertyDescriptor(e.constructor.prototype,t),r=""+e[t];if(!e.hasOwnProperty(t)&&typeof n<"u"&&typeof n.get=="function"&&typeof n.set=="function"){var s=n.get,i=n.set;return Object.defineProperty(e,t,{configurable:!0,get:function(){return s.call(this)},set:function(o){r=""+o,i.call(this,o)}}),Object.defineProperty(e,t,{enumerable:n.enumerable}),{getValue:function(){return r},setValue:function(o){r=""+o},stopTracking:function(){e._valueTracker=null,delete e[t]}}}}function ja(e){e._valueTracker||(e._valueTracker=C_(e))}function n0(e){if(!e)return!1;var t=e._valueTracker;if(!t)return!0;var n=t.getValue(),r="";return e&&(r=t0(e)?e.checked?"true":"false":e.value),e=r,e!==n?(t.setValue(e),!0):!1}function Tl(e){if(e=e||(typeof document<"u"?document:void 0),typeof e>"u")return null;try{return e.activeElement||e.body}catch{return e.body}}function cd(e,t){var n=t.checked;return be({},t,{defaultChecked:void 0,defaultValue:void 0,value:void 0,checked:n??e._wrapperState.initialChecked})}function tm(e,t){var n=t.defaultValue==null?"":t.defaultValue,r=t.checked!=null?t.checked:t.defaultChecked;n=Sr(t.value!=null?t.value:n),e._wrapperState={initialChecked:r,initialValue:n,controlled:t.type==="checkbox"||t.type==="radio"?t.checked!=null:t.value!=null}}function r0(e,t){t=t.checked,t!=null&&Qh(e,"checked",t,!1)}function ud(e,t){r0(e,t);var n=Sr(t.value),r=t.type;if(n!=null)r==="number"?(n===0&&e.value===""||e.value!=n)&&(e.value=""+n):e.value!==""+n&&(e.value=""+n);else if(r==="submit"||r==="reset"){e.removeAttribute("value");return}t.hasOwnProperty("value")?dd(e,t.type,n):t.hasOwnProperty("defaultValue")&&dd(e,t.type,Sr(t.defaultValue)),t.checked==null&&t.defaultChecked!=null&&(e.defaultChecked=!!t.defaultChecked)}function nm(e,t,n){if(t.hasOwnProperty("value")||t.hasOwnProperty("defaultValue")){var r=t.type;if(!(r!=="submit"&&r!=="reset"||t.value!==void 0&&t.value!==null))return;t=""+e._wrapperState.initialValue,n||t===e.value||(e.value=t),e.defaultValue=t}n=e.name,n!==""&&(e.name=""),e.defaultChecked=!!e._wrapperState.initialChecked,n!==""&&(e.name=n)}
vendor: 10,954 bytes, line 37
37function dd(e,t,n){(t!=="number"||Tl(e.ownerDocument)!==e)&&(n==null?e.defaultValue=""+e._wrapperState.initialValue:e.defaultValue!==""+n&&(e.defaultValue=""+n))}var io=Array.isArray;function ni(e,t,n,r){if(e=e.options,t){t={};for(var s=0;s<n.length;s++)t["$"+n[s]]=!0;for(n=0;n<e.length;n++)s=t.hasOwnProperty("$"+e[n].value),e[n].selected!==s&&(e[n].selected=s),s&&r&&(e[n].defaultSelected=!0)}else{for(n=""+Sr(n),t=null,s=0;s<e.length;s++){if(e[s].value===n){e[s].selected=!0,r&&(e[s].defaultSelected=!0);return}t!==null||e[s].disabled||(t=e[s])}t!==null&&(t.selected=!0)}}function hd(e,t){if(t.dangerouslySetInnerHTML!=null)throw Error(N(91));return be({},t,{value:void 0,defaultValue:void 0,children:""+e._wrapperState.initialValue})}function rm(e,t){var n=t.value;if(n==null){if(n=t.children,t=t.defaultValue,n!=null){if(t!=null)throw Error(N(92));if(io(n)){if(1<n.length)throw Error(N(93));n=n[0]}t=n}t==null&&(t=""),n=t}e._wrapperState={initialValue:Sr(n)}}function s0(e,t){var n=Sr(t.value),r=Sr(t.defaultValue);n!=null&&(n=""+n,n!==e.value&&(e.value=n),t.defaultValue==null&&e.defaultValue!==n&&(e.defaultValue=n)),r!=null&&(e.defaultValue=""+r)}function sm(e){var t=e.textContent;t===e._wrapperState.initialValue&&t!==""&&t!==null&&(e.value=t)}function i0(e){switch(e){case"svg":return"http://www.w3.org/2000/svg";case"math":return"http://www.w3.org/1998/Math/MathML";default:return"http://www.w3.org/1999/xhtml"}}function fd(e,t){return e==null||e==="http://www.w3.org/1999/xhtml"?i0(t):e==="http://www.w3.org/2000/svg"&&t==="foreignObject"?"http://www.w3.org/1999/xhtml":e}var Na,o0=function(e){return typeof MSApp<"u"&&MSApp.execUnsafeLocalFunction?function(t,n,r,s){MSApp.execUnsafeLocalFunction(function(){return e(t,n,r,s)})}:e}(function(e,t){if(e.namespaceURI!=="http://www.w3.org/2000/svg"||"innerHTML"in e)e.innerHTML=t;else{for(Na=Na||document.createElement("div"),Na.innerHTML="<svg>"+t.valueOf().toString()+"</svg>",t=Na.firstChild;e.firstChild;)e.removeChild(e.firstChild);for(;t.firstChild;)e.appendChild(t.firstChild)}});function Po(e,t){if(t){var n=e.firstChild;if(n&&n===e.lastChild&&n.nodeType===3){n.nodeValue=t;return}}e.textContent=t}var uo={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},P_=["Webkit","ms","Moz","O"];Object.keys(uo).forEach(function(e){P_.forEach(function(t){t=t+e.charAt(0).toUpperCase()+e.substring(1),uo[t]=uo[e]})});function a0(e,t,n){return t==null||typeof t=="boolean"||t===""?"":n||typeof t!="number"||t===0||uo.hasOwnProperty(e)&&uo[e]?(""+t).trim():t+"px"}function l0(e,t){e=e.style;for(var n in t)if(t.hasOwnProperty(n)){var r=n.indexOf("--")===0,s=a0(n,t[n],r);n==="float"&&(n="cssFloat"),r?e.setProperty(n,s):e[n]=s}}var A_=be({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 pd(e,t){if(t){if(A_[e]&&(t.children!=null||t.dangerouslySetInnerHTML!=null))throw Error(N(137,e));if(t.dangerouslySetInnerHTML!=null){if(t.children!=null)throw Error(N(60));if(typeof t.dangerouslySetInnerHTML!="object"||!("__html"in t.dangerouslySetInnerHTML))throw Error(N(61))}if(t.style!=null&&typeof t.style!="object")throw Error(N(62))}}function md(e,t){if(e.indexOf("-")===-1)return typeof t.is=="string";switch(e){case"annotation-xml":case"color-profile":case"font-face":case"font-face-src":case"font-face-uri":case"font-face-format":case"font-face-name":case"missing-glyph":return!1;default:return!0}}var gd=null;function ef(e){return e=e.target||e.srcElement||window,e.correspondingUseElement&&(e=e.correspondingUseElement),e.nodeType===3?e.parentNode:e}var yd=null,ri=null,si=null;function im(e){if(e=ha(e)){if(typeof yd!="function")throw Error(N(280));var t=e.stateNode;t&&(t=wc(t),yd(e.stateNode,e.type,t))}}function c0(e){ri?si?si.push(e):si=[e]:ri=e}function u0(){if(ri){var e=ri,t=si;if(si=ri=null,im(e),t)for(e=0;e<t.length;e++)im(t[e])}}function d0(e,t){return e(t)}function h0(){}var iu=!1;function f0(e,t,n){if(iu)return e(t,n);iu=!0;try{return d0(e,t,n)}finally{iu=!1,(ri!==null||si!==null)&&(h0(),u0())}}function Ao(e,t){var n=e.stateNode;if(n===null)return null;var r=wc(n);if(r===null)return null;n=r[t];e:switch(t){case"onClick":case"onClickCapture":case"onDoubleClick":case"onDoubleClickCapture":case"onMouseDown":case"onMouseDownCapture":case"onMouseMove":case"onMouseMoveCapture":case"onMouseUp":case"onMouseUpCapture":case"onMouseEnter":(r=!r.disabled)||(e=e.type,r=!(e==="button"||e==="input"||e==="select"||e==="textarea")),e=!r;break e;default:e=!1}if(e)return null;if(n&&typeof n!="function")throw Error(N(231,t,typeof n));return n}var vd=!1;if(Rn)try{var Ki={};Object.defineProperty(Ki,"passive",{get:function(){vd=!0}}),window.addEventListener("test",Ki,Ki),window.removeEventListener("test",Ki,Ki)}catch{vd=!1}function R_(e,t,n,r,s,i,o,a,l){var c=Array.prototype.slice.call(arguments,3);try{t.apply(n,c)}catch(u){this.onError(u)}}var ho=!1,Cl=null,Pl=!1,wd=null,j_={onError:function(e){ho=!0,Cl=e}};function N_(e,t,n,r,s,i,o,a,l){ho=!1,Cl=null,R_.apply(j_,arguments)}function O_(e,t,n,r,s,i,o,a,l){if(N_.apply(this,arguments),ho){if(ho){var c=Cl;ho=!1,Cl=null}else throw Error(N(198));Pl||(Pl=!0,wd=c)}}function vs(e){var t=e,n=e;if(e.alternate)for(;t.return;)t=t.return;else{e=t;do t=e,t.flags&4098&&(n=t.return),e=t.return;while(e)}return t.tag===3?n:null}function p0(e){if(e.tag===13){var t=e.memoizedState;if(t===null&&(e=e.alternate,e!==null&&(t=e.memoizedState)),t!==null)return t.dehydrated}return null}function om(e){if(vs(e)!==e)throw Error(N(188))}function I_(e){var t=e.alternate;if(!t){if(t=vs(e),t===null)throw Error(N(188));return t!==e?null:e}for(var n=e,r=t;;){var s=n.return;if(s===null)break;var i=s.alternate;if(i===null){if(r=s.return,r!==null){n=r;continue}break}if(s.child===i.child){for(i=s.child;i;){if(i===n)return om(s),e;if(i===r)return om(s),t;i=i.sibling}throw Error(N(188))}if(n.return!==r.return)n=s,r=i;else{for(var o=!1,a=s.child;a;){if(a===n){o=!0,n=s,r=i;break}if(a===r){o=!0,r=s,n=i;break}a=a.sibling}if(!o){for(a=i.child;a;){if(a===n){o=!0,n=i,r=s;break}if(a===r){o=!0,r=i,n=s;break}a=a.sibling}if(!o)throw Error(N(189))}}if(n.alternate!==r)throw Error(N(190))}if(n.tag!==3)throw Error(N(188));return n.stateNode.current===n?e:t}function m0(e){return e=I_(e),e!==null?g0(e):null}function g0(e){if(e.tag===5||e.tag===6)return e;for(e=e.child;e!==null;){var t=g0(e);if(t!==null)return t;e=e.sibling}return null}var y0=St.unstable_scheduleCallback,am=St.unstable_cancelCallback,D_=St.unstable_shouldYield,L_=St.unstable_requestPaint,Te=St.unstable_now,M_=St.unstable_getCurrentPriorityLevel,tf=St.unstable_ImmediatePriority,v0=St.unstable_UserBlockingPriority,Al=St.unstable_NormalPriority,$_=St.unstable_LowPriority,w0=St.unstable_IdlePriority,mc=null,pn=null;function V_(e){if(pn&&typeof pn.onCommitFiberRoot=="function")try{pn.onCommitFiberRoot(mc,e,void 0,(e.current.flags&128)===128)}catch{}}var en=Math.clz32?Math.clz32:B_,F_=Math.log,U_=Math.LN2;function B_(e){return e>>>=0,e===0?32:31-(F_(e)/U_|0)|0}var Oa=64,Ia=4194304;function oo(e){switch(e&-e){case 1:return 1;case 2:return 2;case 4:return 4;case 8:return 8;case 16:return 16;case 32:return 32;case 64:case 128:case 256:case 512:case 1024:case 2048:case 4096:case 8192:case 16384:case 32768:case 65536:case 131072:case 262144:case 524288:case 1048576:case 2097152:return e&4194240;case 4194304:case 8388608:case 16777216:case 33554432:case 67108864:return e&130023424;case 134217728:return 134217728;case 268435456:return 268435456;case 536870912:return 536870912;case 1073741824:return 1073741824;default:return e}}function Rl(e,t){var n=e.pendingLanes;if(n===0)return 0;var r=0,s=e.suspendedLanes,i=e.pingedLanes,o=n&268435455;if(o!==0){var a=o&~s;a!==0?r=oo(a):(i&=o,i!==0&&(r=oo(i)))}else o=n&~s,o!==0?r=oo(o):i!==0&&(r=oo(i));if(r===0)return 0;if(t!==0&&t!==r&&!(t&s)&&(s=r&-r,i=t&-t,s>=i||s===16&&(i&4194240)!==0))return t;if(r&4&&(r|=n&16),t=e.entangledLanes,t!==0)for(e=e.entanglements,t&=r;0<t;)n=31-en(t),s=1<<n,r|=e[n],t&=~s;return r}function z_(e,t){switch(e){case 1:case 2:case 4:return t+250;case 8:case 16:case 32:case 64:case 128:case 256:case 512:case 1024:case 2048:case 4096:case 8192:case 16384:case 32768:case 65536:case 131072:case 262144:case 524288:case 1048576:case 2097152:return t+5e3;case 4194304:case 8388608:case 16777216:case 33554432:case 67108864:return-1;case 134217728:case 268435456:case 536870912:case 1073741824:return-1;default:return-1}}function W_(e,t){for(var n=e.suspendedLanes,r=e.pingedLanes,s=e.expirationTimes,i=e.pendingLanes;0<i;){var o=31-en(i),a=1<<o,l=s[o];l===-1?(!(a&n)||a&r)&&(s[o]=z_(a,t)):l<=t&&(e.expiredLanes|=a),i&=~a}}function xd(e){return e=e.pendingLanes&-1073741825,e!==0?e:e&1073741824?1073741824:0}function x0(){var e=Oa;return Oa<<=1,!(Oa&4194240)&&(Oa=64),e}function ou(e){for(var t=[],n=0;31>n;n++)t.push(e);return t}function ua(e,t,n){e.pendingLanes|=t,t!==536870912&&(e.suspendedLanes=0,e.pingedLanes=0),e=e.eventTimes,t=31-en(t),e[t]=n}function H_(e,t){var n=e.pendingLanes&~t;e.pendingLanes=t,e.suspendedLanes=0,e.pingedLanes=0,e.expiredLanes&=t,e.mutableReadLanes&=t,e.entangledLanes&=t,t=e.entanglements;var r=e.eventTimes;for(e=e.expirationTimes;0<n;){var s=31-en(n),i=1<<s;t[s]=0,r[s]=-1,e[s]=-1,n&=~i}}function nf(e,t){var n=e.entangledLanes|=t;for(e=e.entanglements;n;){var r=31-en(n),s=1<<r;s&t|e[r]&t&&(e[r]|=t),n&=~s}}var ie=0;function b0(e){return e&=-e,1<e?4<e?e&268435455?16:536870912:4:1}var S0,rf,_0,k0,E0,bd=!1,Da=[],fr=null,pr=null,mr=null,Ro=new Map,jo=new Map,nr=[],K_="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 lm(e,t){switch(e){case"focusin":case"focusout":fr=null;break;case"dragenter":case"dragleave":pr=null;break;case"mouseover":case"mouseout":mr=null;break;case"pointerover":case"pointerout":Ro.delete(t.pointerId);break;case"gotpointercapture":case"lostpointercapture":jo.delete(t.pointerId)}}function qi(e,t,n,r,s,i){return e===null||e.nativeEvent!==i?(e={blockedOn:t,domEventName:n,eventSystemFlags:r,nativeEvent:i,targetContainers:[s]},t!==null&&(t=ha(t),t!==null&&rf(t)),e):(e.eventSystemFlags|=r,t=e.targetContainers,s!==null&&t.indexOf(s)===-1&&t.push(s),e)}
vendor: 12,981 bytes, line 37
37function q_(e,t,n,r,s){switch(t){case"focusin":return fr=qi(fr,e,t,n,r,s),!0;case"dragenter":return pr=qi(pr,e,t,n,r,s),!0;case"mouseover":return mr=qi(mr,e,t,n,r,s),!0;case"pointerover":var i=s.pointerId;return Ro.set(i,qi(Ro.get(i)||null,e,t,n,r,s)),!0;case"gotpointercapture":return i=s.pointerId,jo.set(i,qi(jo.get(i)||null,e,t,n,r,s)),!0}return!1}function T0(e){var t=Gr(e.target);if(t!==null){var n=vs(t);if(n!==null){if(t=n.tag,t===13){if(t=p0(n),t!==null){e.blockedOn=t,E0(e.priority,function(){_0(n)});return}}else if(t===3&&n.stateNode.current.memoizedState.isDehydrated){e.blockedOn=n.tag===3?n.stateNode.containerInfo:null;return}}}e.blockedOn=null}function cl(e){if(e.blockedOn!==null)return!1;for(var t=e.targetContainers;0<t.length;){var n=Sd(e.domEventName,e.eventSystemFlags,t[0],e.nativeEvent);if(n===null){n=e.nativeEvent;var r=new n.constructor(n.type,n);gd=r,n.target.dispatchEvent(r),gd=null}else return t=ha(n),t!==null&&rf(t),e.blockedOn=n,!1;t.shift()}return!0}function cm(e,t,n){cl(e)&&n.delete(t)}function G_(){bd=!1,fr!==null&&cl(fr)&&(fr=null),pr!==null&&cl(pr)&&(pr=null),mr!==null&&cl(mr)&&(mr=null),Ro.forEach(cm),jo.forEach(cm)}function Gi(e,t){e.blockedOn===t&&(e.blockedOn=null,bd||(bd=!0,St.unstable_scheduleCallback(St.unstable_NormalPriority,G_)))}function No(e){function t(s){return Gi(s,e)}if(0<Da.length){Gi(Da[0],e);for(var n=1;n<Da.length;n++){var r=Da[n];r.blockedOn===e&&(r.blockedOn=null)}}for(fr!==null&&Gi(fr,e),pr!==null&&Gi(pr,e),mr!==null&&Gi(mr,e),Ro.forEach(t),jo.forEach(t),n=0;n<nr.length;n++)r=nr[n],r.blockedOn===e&&(r.blockedOn=null);for(;0<nr.length&&(n=nr[0],n.blockedOn===null);)T0(n),n.blockedOn===null&&nr.shift()}var ii=Vn.ReactCurrentBatchConfig,jl=!0;function Y_(e,t,n,r){var s=ie,i=ii.transition;ii.transition=null;try{ie=1,sf(e,t,n,r)}finally{ie=s,ii.transition=i}}function Q_(e,t,n,r){var s=ie,i=ii.transition;ii.transition=null;try{ie=4,sf(e,t,n,r)}finally{ie=s,ii.transition=i}}function sf(e,t,n,r){if(jl){var s=Sd(e,t,n,r);if(s===null)gu(e,t,r,Nl,n),lm(e,r);else if(q_(s,e,t,n,r))r.stopPropagation();else if(lm(e,r),t&4&&-1<K_.indexOf(e)){for(;s!==null;){var i=ha(s);if(i!==null&&S0(i),i=Sd(e,t,n,r),i===null&&gu(e,t,r,Nl,n),i===s)break;s=i}s!==null&&r.stopPropagation()}else gu(e,t,r,null,n)}}var Nl=null;function Sd(e,t,n,r){if(Nl=null,e=ef(r),e=Gr(e),e!==null)if(t=vs(e),t===null)e=null;else if(n=t.tag,n===13){if(e=p0(t),e!==null)return e;e=null}else if(n===3){if(t.stateNode.current.memoizedState.isDehydrated)return t.tag===3?t.stateNode.containerInfo:null;e=null}else t!==e&&(e=null);return Nl=e,null}function C0(e){switch(e){case"cancel":case"click":case"close":case"contextmenu":case"copy":case"cut":case"auxclick":case"dblclick":case"dragend":case"dragstart":case"drop":case"focusin":case"focusout":case"input":case"invalid":case"keydown":case"keypress":case"keyup":case"mousedown":case"mouseup":case"paste":case"pause":case"play":case"pointercancel":case"pointerdown":case"pointerup":case"ratechange":case"reset":case"resize":case"seeked":case"submit":case"touchcancel":case"touchend":case"touchstart":case"volumechange":case"change":case"selectionchange":case"textInput":case"compositionstart":case"compositionend":case"compositionupdate":case"beforeblur":case"afterblur":case"beforeinput":case"blur":case"fullscreenchange":case"focus":case"hashchange":case"popstate":case"select":case"selectstart":return 1;case"drag":case"dragenter":case"dragexit":case"dragleave":case"dragover":case"mousemove":case"mouseout":case"mouseover":case"pointermove":case"pointerout":case"pointerover":case"scroll":case"toggle":case"touchmove":case"wheel":case"mouseenter":case"mouseleave":case"pointerenter":case"pointerleave":return 4;case"message":switch(M_()){case tf:return 1;case v0:return 4;case Al:case $_:return 16;case w0:return 536870912;default:return 16}default:return 16}}var ur=null,of=null,ul=null;function P0(){if(ul)return ul;var e,t=of,n=t.length,r,s="value"in ur?ur.value:ur.textContent,i=s.length;for(e=0;e<n&&t[e]===s[e];e++);var o=n-e;for(r=1;r<=o&&t[n-r]===s[i-r];r++);return ul=s.slice(e,1<r?1-r:void 0)}function dl(e){var t=e.keyCode;return"charCode"in e?(e=e.charCode,e===0&&t===13&&(e=13)):e=t,e===10&&(e=13),32<=e||e===13?e:0}function La(){return!0}function um(){return!1}function Et(e){function t(n,r,s,i,o){this._reactName=n,this._targetInst=s,this.type=r,this.nativeEvent=i,this.target=o,this.currentTarget=null;for(var a in e)e.hasOwnProperty(a)&&(n=e[a],this[a]=n?n(i):i[a]);return this.isDefaultPrevented=(i.defaultPrevented!=null?i.defaultPrevented:i.returnValue===!1)?La:um,this.isPropagationStopped=um,this}return be(t.prototype,{preventDefault:function(){this.defaultPrevented=!0;var n=this.nativeEvent;n&&(n.preventDefault?n.preventDefault():typeof n.returnValue!="unknown"&&(n.returnValue=!1),this.isDefaultPrevented=La)},stopPropagation:function(){var n=this.nativeEvent;n&&(n.stopPropagation?n.stopPropagation():typeof n.cancelBubble!="unknown"&&(n.cancelBubble=!0),this.isPropagationStopped=La)},persist:function(){},isPersistent:La}),t}var Ni={eventPhase:0,bubbles:0,cancelable:0,timeStamp:function(e){return e.timeStamp||Date.now()},defaultPrevented:0,isTrusted:0},af=Et(Ni),da=be({},Ni,{view:0,detail:0}),J_=Et(da),au,lu,Yi,gc=be({},da,{screenX:0,screenY:0,clientX:0,clientY:0,pageX:0,pageY:0,ctrlKey:0,shiftKey:0,altKey:0,metaKey:0,getModifierState:lf,button:0,buttons:0,relatedTarget:function(e){return e.relatedTarget===void 0?e.fromElement===e.srcElement?e.toElement:e.fromElement:e.relatedTarget},movementX:function(e){return"movementX"in e?e.movementX:(e!==Yi&&(Yi&&e.type==="mousemove"?(au=e.screenX-Yi.screenX,lu=e.screenY-Yi.screenY):lu=au=0,Yi=e),au)},movementY:function(e){return"movementY"in e?e.movementY:lu}}),dm=Et(gc),X_=be({},gc,{dataTransfer:0}),Z_=Et(X_),ek=be({},da,{relatedTarget:0}),cu=Et(ek),tk=be({},Ni,{animationName:0,elapsedTime:0,pseudoElement:0}),nk=Et(tk),rk=be({},Ni,{clipboardData:function(e){return"clipboardData"in e?e.clipboardData:window.clipboardData}}),sk=Et(rk),ik=be({},Ni,{data:0}),hm=Et(ik),ok={Esc:"Escape",Spacebar:" ",Left:"ArrowLeft",Up:"ArrowUp",Right:"ArrowRight",Down:"ArrowDown",Del:"Delete",Win:"OS",Menu:"ContextMenu",Apps:"ContextMenu",Scroll:"ScrollLock",MozPrintableKey:"Unidentified"},ak={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"},lk={Alt:"altKey",Control:"ctrlKey",Meta:"metaKey",Shift:"shiftKey"};function ck(e){var t=this.nativeEvent;return t.getModifierState?t.getModifierState(e):(e=lk[e])?!!t[e]:!1}function lf(){return ck}var uk=be({},da,{key:function(e){if(e.key){var t=ok[e.key]||e.key;if(t!=="Unidentified")return t}return e.type==="keypress"?(e=dl(e),e===13?"Enter":String.fromCharCode(e)):e.type==="keydown"||e.type==="keyup"?ak[e.keyCode]||"Unidentified":""},code:0,location:0,ctrlKey:0,shiftKey:0,altKey:0,metaKey:0,repeat:0,locale:0,getModifierState:lf,charCode:function(e){return e.type==="keypress"?dl(e):0},keyCode:function(e){return e.type==="keydown"||e.type==="keyup"?e.keyCode:0},which:function(e){return e.type==="keypress"?dl(e):e.type==="keydown"||e.type==="keyup"?e.keyCode:0}}),dk=Et(uk),hk=be({},gc,{pointerId:0,width:0,height:0,pressure:0,tangentialPressure:0,tiltX:0,tiltY:0,twist:0,pointerType:0,isPrimary:0}),fm=Et(hk),fk=be({},da,{touches:0,targetTouches:0,changedTouches:0,altKey:0,metaKey:0,ctrlKey:0,shiftKey:0,getModifierState:lf}),pk=Et(fk),mk=be({},Ni,{propertyName:0,elapsedTime:0,pseudoElement:0}),gk=Et(mk),yk=be({},gc,{deltaX:function(e){return"deltaX"in e?e.deltaX:"wheelDeltaX"in e?-e.wheelDeltaX:0},deltaY:function(e){return"deltaY"in e?e.deltaY:"wheelDeltaY"in e?-e.wheelDeltaY:"wheelDelta"in e?-e.wheelDelta:0},deltaZ:0,deltaMode:0}),vk=Et(yk),wk=[9,13,27,32],cf=Rn&&"CompositionEvent"in window,fo=null;Rn&&"documentMode"in document&&(fo=document.documentMode);var xk=Rn&&"TextEvent"in window&&!fo,A0=Rn&&(!cf||fo&&8<fo&&11>=fo),pm=" ",mm=!1;function R0(e,t){switch(e){case"keyup":return wk.indexOf(t.keyCode)!==-1;case"keydown":return t.keyCode!==229;case"keypress":case"mousedown":case"focusout":return!0;default:return!1}}function j0(e){return e=e.detail,typeof e=="object"&&"data"in e?e.data:null}var Fs=!1;function bk(e,t){switch(e){case"compositionend":return j0(t);case"keypress":return t.which!==32?null:(mm=!0,pm);case"textInput":return e=t.data,e===pm&&mm?null:e;default:return null}}function Sk(e,t){if(Fs)return e==="compositionend"||!cf&&R0(e,t)?(e=P0(),ul=of=ur=null,Fs=!1,e):null;switch(e){case"paste":return null;case"keypress":if(!(t.ctrlKey||t.altKey||t.metaKey)||t.ctrlKey&&t.altKey){if(t.char&&1<t.char.length)return t.char;if(t.which)return String.fromCharCode(t.which)}return null;case"compositionend":return A0&&t.locale!=="ko"?null:t.data;default:return null}}var _k={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 gm(e){var t=e&&e.nodeName&&e.nodeName.toLowerCase();return t==="input"?!!_k[e.type]:t==="textarea"}function N0(e,t,n,r){c0(r),t=Ol(t,"onChange"),0<t.length&&(n=new af("onChange","change",null,n,r),e.push({event:n,listeners:t}))}var po=null,Oo=null;function kk(e){z0(e,0)}function yc(e){var t=zs(e);if(n0(t))return e}function Ek(e,t){if(e==="change")return t}var O0=!1;if(Rn){var uu;if(Rn){var du="oninput"in document;if(!du){var ym=document.createElement("div");ym.setAttribute("oninput","return;"),du=typeof ym.oninput=="function"}uu=du}else uu=!1;O0=uu&&(!document.documentMode||9<document.documentMode)}function vm(){po&&(po.detachEvent("onpropertychange",I0),Oo=po=null)}function I0(e){if(e.propertyName==="value"&&yc(Oo)){var t=[];N0(t,Oo,e,ef(e)),f0(kk,t)}}function Tk(e,t,n){e==="focusin"?(vm(),po=t,Oo=n,po.attachEvent("onpropertychange",I0)):e==="focusout"&&vm()}function Ck(e){if(e==="selectionchange"||e==="keyup"||e==="keydown")return yc(Oo)}function Pk(e,t){if(e==="click")return yc(t)}function Ak(e,t){if(e==="input"||e==="change")return yc(t)}function Rk(e,t){return e===t&&(e!==0||1/e===1/t)||e!==e&&t!==t}var nn=typeof Object.is=="function"?Object.is:Rk;function Io(e,t){if(nn(e,t))return!0;if(typeof e!="object"||e===null||typeof t!="object"||t===null)return!1;var n=Object.keys(e),r=Object.keys(t);if(n.length!==r.length)return!1;for(r=0;r<n.length;r++){var s=n[r];if(!sd.call(t,s)||!nn(e[s],t[s]))return!1}return!0}function wm(e){for(;e&&e.firstChild;)e=e.firstChild;return e}function xm(e,t){var n=wm(e);e=0;for(var r;n;){if(n.nodeType===3){if(r=e+n.textContent.length,e<=t&&r>=t)return{node:n,offset:t-e};e=r}e:{for(;n;){if(n.nextSibling){n=n.nextSibling;break e}n=n.parentNode}n=void 0}n=wm(n)}}function D0(e,t){return e&&t?e===t?!0:e&&e.nodeType===3?!1:t&&t.nodeType===3?D0(e,t.parentNode):"contains"in e?e.contains(t):e.compareDocumentPosition?!!(e.compareDocumentPosition(t)&16):!1:!1}function L0(){for(var e=window,t=Tl();t instanceof e.HTMLIFrameElement;){try{var n=typeof t.contentWindow.location.href=="string"}catch{n=!1}if(n)e=t.contentWindow;else break;t=Tl(e.document)}return t}function uf(e){var t=e&&e.nodeName&&e.nodeName.toLowerCase();return t&&(t==="input"&&(e.type==="text"||e.type==="search"||e.type==="tel"||e.type==="url"||e.type==="password")||t==="textarea"||e.contentEditable==="true")}function jk(e){var t=L0(),n=e.focusedElem,r=e.selectionRange;if(t!==n&&n&&n.ownerDocument&&D0(n.ownerDocument.documentElement,n)){if(r!==null&&uf(n)){if(t=r.start,e=r.end,e===void 0&&(e=t),"selectionStart"in n)n.selectionStart=t,n.selectionEnd=Math.min(e,n.value.length);else if(e=(t=n.ownerDocument||document)&&t.defaultView||window,e.getSelection){e=e.getSelection();var s=n.textContent.length,i=Math.min(r.start,s);r=r.end===void 0?i:Math.min(r.end,s),!e.extend&&i>r&&(s=r,r=i,i=s),s=xm(n,i);var o=xm(n,r);s&&o&&(e.rangeCount!==1||e.anchorNode!==s.node||e.anchorOffset!==s.offset||e.focusNode!==o.node||e.focusOffset!==o.offset)&&(t=t.createRange(),t.setStart(s.node,s.offset),e.removeAllRanges(),i>r?(e.addRange(t),e.extend(o.node,o.offset)):(t.setEnd(o.node,o.offset),e.addRange(t)))}}for(t=[],e=n;e=e.parentNode;)e.nodeType===1&&t.push({element:e,left:e.scrollLeft,top:e.scrollTop});for(typeof n.focus=="function"&&n.focus(),n=0;n<t.length;n++)e=t[n],e.element.scrollLeft=e.left,e.element.scrollTop=e.top}}var Nk=Rn&&"documentMode"in document&&11>=document.documentMode,Us=null,_d=null,mo=null,kd=!1;function bm(e,t,n){var r=n.window===n?n.document:n.nodeType===9?n:n.ownerDocument;kd||Us==null||Us!==Tl(r)||(r=Us,"selectionStart"in r&&uf(r)?r={start:r.selectionStart,end:r.selectionEnd}:(r=(r.ownerDocument&&r.ownerDocument.defaultView||window).getSelection(),r={anchorNode:r.anchorNode,anchorOffset:r.anchorOffset,focu
vendor: 3,150 bytes, line 37
37sNode:r.focusNode,focusOffset:r.focusOffset}),mo&&Io(mo,r)||(mo=r,r=Ol(_d,"onSelect"),0<r.length&&(t=new af("onSelect","select",null,t,n),e.push({event:t,listeners:r}),t.target=Us)))}function Ma(e,t){var n={};return n[e.toLowerCase()]=t.toLowerCase(),n["Webkit"+e]="webkit"+t,n["Moz"+e]="moz"+t,n}var Bs={animationend:Ma("Animation","AnimationEnd"),animationiteration:Ma("Animation","AnimationIteration"),animationstart:Ma("Animation","AnimationStart"),transitionend:Ma("Transition","TransitionEnd")},hu={},M0={};Rn&&(M0=document.createElement("div").style,"AnimationEvent"in window||(delete Bs.animationend.animation,delete Bs.animationiteration.animation,delete Bs.animationstart.animation),"TransitionEvent"in window||delete Bs.transitionend.transition);function vc(e){if(hu[e])return hu[e];if(!Bs[e])return e;var t=Bs[e],n;for(n in t)if(t.hasOwnProperty(n)&&n in M0)return hu[e]=t[n];return e}var $0=vc("animationend"),V0=vc("animationiteration"),F0=vc("animationstart"),U0=vc("transitionend"),B0=new Map,Sm="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 Rr(e,t){B0.set(e,t),ys(t,[e])}for(var fu=0;fu<Sm.length;fu++){var pu=Sm[fu],Ok=pu.toLowerCase(),Ik=pu[0].toUpperCase()+pu.slice(1);Rr(Ok,"on"+Ik)}Rr($0,"onAnimationEnd");Rr(V0,"onAnimationIteration");Rr(F0,"onAnimationStart");Rr("dblclick","onDoubleClick");Rr("focusin","onFocus");Rr("focusout","onBlur");Rr(U0,"onTransitionEnd");xi("onMouseEnter",["mouseout","mouseover"]);xi("onMouseLeave",["mouseout","mouseover"]);xi("onPointerEnter",["pointerout","pointerover"]);xi("onPointerLeave",["pointerout","pointerover"]);ys("onChange","change click focusin focusout input keydown keyup selectionchange".split(" "));ys("onSelect","focusout contextmenu dragend focusin keydown keyup mousedown mouseup selectionchange".split(" "));ys("onBeforeInput",["compositionend","keypress","textInput","paste"]);ys("onCompositionEnd","compositionend focusout keydown keypress keyup mousedown".split(" "));ys("onCompositionStart","compositionstart focusout keydown keypress keyup mousedown".split(" "));ys("onCompositionUpdate","compositionupdate focusout keydown keypress keyup mousedown".split(" "));var ao="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(" "),Dk=new Set("cancel close invalid load scroll toggle".split(" ").concat(ao));function _m(e,t,n){var r=e.type||"unknown-event";e.currentTarget=n,O_(r,t,void 0,e),e.currentTarget=null}
vendor: 4,441 bytes, line 37
37function z0(e,t){t=(t&4)!==0;for(var n=0;n<e.length;n++){var r=e[n],s=r.event;r=r.listeners;e:{var i=void 0;if(t)for(var o=r.length-1;0<=o;o--){var a=r[o],l=a.instance,c=a.currentTarget;if(a=a.listener,l!==i&&s.isPropagationStopped())break e;_m(s,a,c),i=l}else for(o=0;o<r.length;o++){if(a=r[o],l=a.instance,c=a.currentTarget,a=a.listener,l!==i&&s.isPropagationStopped())break e;_m(s,a,c),i=l}}}if(Pl)throw e=wd,Pl=!1,wd=null,e}function ue(e,t){var n=t[Ad];n===void 0&&(n=t[Ad]=new Set);var r=e+"__bubble";n.has(r)||(W0(t,e,2,!1),n.add(r))}function mu(e,t,n){var r=0;t&&(r|=4),W0(n,e,r,t)}var $a="_reactListening"+Math.random().toString(36).slice(2);function Do(e){if(!e[$a]){e[$a]=!0,Jv.forEach(function(n){n!=="selectionchange"&&(Dk.has(n)||mu(n,!1,e),mu(n,!0,e))});var t=e.nodeType===9?e:e.ownerDocument;t===null||t[$a]||(t[$a]=!0,mu("selectionchange",!1,t))}}function W0(e,t,n,r){switch(C0(t)){case 1:var s=Y_;break;case 4:s=Q_;break;default:s=sf}n=s.bind(null,t,n,e),s=void 0,!vd||t!=="touchstart"&&t!=="touchmove"&&t!=="wheel"||(s=!0),r?s!==void 0?e.addEventListener(t,n,{capture:!0,passive:s}):e.addEventListener(t,n,!0):s!==void 0?e.addEventListener(t,n,{passive:s}):e.addEventListener(t,n,!1)}function gu(e,t,n,r,s){var i=r;if(!(t&1)&&!(t&2)&&r!==null)e:for(;;){if(r===null)return;var o=r.tag;if(o===3||o===4){var a=r.stateNode.containerInfo;if(a===s||a.nodeType===8&&a.parentNode===s)break;if(o===4)for(o=r.return;o!==null;){var l=o.tag;if((l===3||l===4)&&(l=o.stateNode.containerInfo,l===s||l.nodeType===8&&l.parentNode===s))return;o=o.return}for(;a!==null;){if(o=Gr(a),o===null)return;if(l=o.tag,l===5||l===6){r=i=o;continue e}a=a.parentNode}}r=r.return}f0(function(){var c=i,u=ef(n),d=[];e:{var h=B0.get(e);if(h!==void 0){var f=af,w=e;switch(e){case"keypress":if(dl(n)===0)break e;case"keydown":case"keyup":f=dk;break;case"focusin":w="focus",f=cu;break;case"focusout":w="blur",f=cu;break;case"beforeblur":case"afterblur":f=cu;break;case"click":if(n.button===2)break e;case"auxclick":case"dblclick":case"mousedown":case"mousemove":case"mouseup":case"mouseout":case"mouseover":case"contextmenu":f=dm;break;case"drag":case"dragend":case"dragenter":case"dragexit":case"dragleave":case"dragover":case"dragstart":case"drop":f=Z_;break;case"touchcancel":case"touchend":case"touchmove":case"touchstart":f=pk;break;case $0:case V0:case F0:f=nk;break;case U0:f=gk;break;case"scroll":f=J_;break;case"wheel":f=vk;break;case"copy":case"cut":case"paste":f=sk;break;case"gotpointercapture":case"lostpointercapture":case"pointercancel":case"pointerdown":case"pointermove":case"pointerout":case"pointerover":case"pointerup":f=fm}var y=(t&4)!==0,x=!y&&e==="scroll",m=y?h!==null?h+"Capture":null:h;y=[];for(var g=c,v;g!==null;){v=g;var S=v.stateNode;if(v.tag===5&&S!==null&&(v=S,m!==null&&(S=Ao(g,m),S!=null&&y.push(Lo(g,S,v)))),x)break;g=g.return}0<y.length&&(h=new f(h,w,null,n,u),d.push({event:h,listeners:y}))}}if(!(t&7)){e:{if(h=e==="mouseover"||e==="pointerover",f=e==="mouseout"||e==="pointerout",h&&n!==gd&&(w=n.relatedTarget||n.fromElement)&&(Gr(w)||w[jn]))break e;if((f||h)&&(h=u.window===u?u:(h=u.ownerDocument)?h.defaultView||h.parentWindow:window,f?(w=n.relatedTarget||n.toElement,f=c,w=w?Gr(w):null,w!==null&&(x=vs(w),w!==x||w.tag!==5&&w.tag!==6)&&(w=null)):(f=null,w=c),f!==w)){if(y=dm,S="onMouseLeave",m="onMouseEnter",g="mouse",(e==="pointerout"||e==="pointerover")&&(y=fm,S="onPointerLeave",m="onPointerEnter",g="pointer"),x=f==null?h:zs(f),v=w==null?h:zs(w),h=new y(S,g+"leave",f,n,u),h.target=x,h.relatedTarget=v,S=null,Gr(u)===c&&(y=new y(m,g+"enter",w,n,u),y.target=v,y.relatedTarget=x,S=y),x=S,f&&w)t:{for(y=f,m=w,g=0,v=y;v;v=Ts(v))g++;for(v=0,S=m;S;S=Ts(S))v++;for(;0<g-v;)y=Ts(y),g--;for(;0<v-g;)m=Ts(m),v--;for(;g--;){if(y===m||m!==null&&y===m.alternate)break t;y=Ts(y),m=Ts(m)}y=null}else y=null;f!==null&&km(d,h,f,y,!1),w!==null&&x!==null&&km(d,x,w,y,!0)}}e:{if(h=c?zs(c):window,f=h.nodeName&&h.nodeName.toLowerCase(),f==="select"||f==="input"&&h.type==="file")var _=Ek;else if(gm(h))if(O0)_=Ak;else{_=Ck;var k=Tk}else(f=h.nodeName)&&f.toLowerCase()==="input"&&(h.type==="checkbox"||h.type==="radio")&&(_=Pk);if(_&&(_=_(e,c))){N0(d,_,n,u);break e}k&&k(e,h,c),e==="focusout"&&(k=h._wrapperState)&&k.controlled&&h.type==="number"&&dd(h,"number",h.value)}switch(k=c?zs(c):window,e){case"focusin":(gm(k)||k.contentEditable==="true")&&(Us=k,_d=c,mo=null);break;case"focusout":mo=_d=Us=null;break;case"mousedown":kd=!0;break;
vendor: 5,242 bytes, lines 37-38
37case"contextmenu":case"mouseup":case"dragend":kd=!1,bm(d,n,u);break;case"selectionchange":if(Nk)break;case"keydown":case"keyup":bm(d,n,u)}var E;if(cf)e:{switch(e){case"compositionstart":var T="onCompositionStart";break e;case"compositionend":T="onCompositionEnd";break e;case"compositionupdate":T="onCompositionUpdate";break e}T=void 0}else Fs?R0(e,n)&&(T="onCompositionEnd"):e==="keydown"&&n.keyCode===229&&(T="onCompositionStart");T&&(A0&&n.locale!=="ko"&&(Fs||T!=="onCompositionStart"?T==="onCompositionEnd"&&Fs&&(E=P0()):(ur=u,of="value"in ur?ur.value:ur.textContent,Fs=!0)),k=Ol(c,T),0<k.length&&(T=new hm(T,e,null,n,u),d.push({event:T,listeners:k}),E?T.data=E:(E=j0(n),E!==null&&(T.data=E)))),(E=xk?bk(e,n):Sk(e,n))&&(c=Ol(c,"onBeforeInput"),0<c.length&&(u=new hm("onBeforeInput","beforeinput",null,n,u),d.push({event:u,listeners:c}),u.data=E))}z0(d,t)})}function Lo(e,t,n){return{instance:e,listener:t,currentTarget:n}}function Ol(e,t){for(var n=t+"Capture",r=[];e!==null;){var s=e,i=s.stateNode;s.tag===5&&i!==null&&(s=i,i=Ao(e,n),i!=null&&r.unshift(Lo(e,i,s)),i=Ao(e,t),i!=null&&r.push(Lo(e,i,s))),e=e.return}return r}function Ts(e){if(e===null)return null;do e=e.return;while(e&&e.tag!==5);return e||null}function km(e,t,n,r,s){for(var i=t._reactName,o=[];n!==null&&n!==r;){var a=n,l=a.alternate,c=a.stateNode;if(l!==null&&l===r)break;a.tag===5&&c!==null&&(a=c,s?(l=Ao(n,i),l!=null&&o.unshift(Lo(n,l,a))):s||(l=Ao(n,i),l!=null&&o.push(Lo(n,l,a)))),n=n.return}o.length!==0&&e.push({event:t,listeners:o})}var Lk=/\r\n?/g,Mk=/\u0000|\uFFFD/g;function Em(e){return(typeof e=="string"?e:""+e).replace(Lk,` 38`).replace(Mk,"")}function Va(e,t,n){if(t=Em(t),Em(e)!==t&&n)throw Error(N(425))}function Il(){}var Ed=null,Td=null;function Cd(e,t){return e==="textarea"||e==="noscript"||typeof t.children=="string"||typeof t.children=="number"||typeof t.dangerouslySetInnerHTML=="object"&&t.dangerouslySetInnerHTML!==null&&t.dangerouslySetInnerHTML.__html!=null}var Pd=typeof setTimeout=="function"?setTimeout:void 0,$k=typeof clearTimeout=="function"?clearTimeout:void 0,Tm=typeof Promise=="function"?Promise:void 0,Vk=typeof queueMicrotask=="function"?queueMicrotask:typeof Tm<"u"?function(e){return Tm.resolve(null).then(e).catch(Fk)}:Pd;function Fk(e){setTimeout(function(){throw e})}function yu(e,t){var n=t,r=0;do{var s=n.nextSibling;if(e.removeChild(n),s&&s.nodeType===8)if(n=s.data,n==="/$"){if(r===0){e.removeChild(s),No(t);return}r--}else n!=="$"&&n!=="$?"&&n!=="$!"||r++;n=s}while(n);No(t)}function gr(e){for(;e!=null;e=e.nextSibling){var t=e.nodeType;if(t===1||t===3)break;if(t===8){if(t=e.data,t==="$"||t==="$!"||t==="$?")break;if(t==="/$")return null}}return e}function Cm(e){e=e.previousSibling;for(var t=0;e;){if(e.nodeType===8){var n=e.data;if(n==="$"||n==="$!"||n==="$?"){if(t===0)return e;t--}else n==="/$"&&t++}e=e.previousSibling}return null}var Oi=Math.random().toString(36).slice(2),hn="__reactFiber$"+Oi,Mo="__reactProps$"+Oi,jn="__reactContainer$"+Oi,Ad="__reactEvents$"+Oi,Uk="__reactListeners$"+Oi,Bk="__reactHandles$"+Oi;function Gr(e){var t=e[hn];if(t)return t;for(var n=e.parentNode;n;){if(t=n[jn]||n[hn]){if(n=t.alternate,t.child!==null||n!==null&&n.child!==null)for(e=Cm(e);e!==null;){if(n=e[hn])return n;e=Cm(e)}return t}e=n,n=e.parentNode}return null}function ha(e){return e=e[hn]||e[jn],!e||e.tag!==5&&e.tag!==6&&e.tag!==13&&e.tag!==3?null:e}function zs(e){if(e.tag===5||e.tag===6)return e.stateNode;throw Error(N(33))}function wc(e){return e[Mo]||null}var Rd=[],Ws=-1;function jr(e){return{current:e}}function de(e){0>Ws||(e.current=Rd[Ws],Rd[Ws]=null,Ws--)}function le(e,t){Ws++,Rd[Ws]=e.current,e.current=t}var _r={},tt=jr(_r),ft=jr(!1),ds=_r;function bi(e,t){var n=e.type.contextTypes;if(!n)return _r;var r=e.stateNode;if(r&&r.__reactInternalMemoizedUnmaskedChildContext===t)return r.__reactInternalMemoizedMaskedChildContext;var s={},i;for(i in n)s[i]=t[i];return r&&(e=e.stateNode,e.__reactInternalMemoizedUnmaskedChildContext=t,e.__reactInternalMemoizedMaskedChildContext=s),s}function pt(e){return e=e.childContextTypes,e!=null}function Dl(){de(ft),de(tt)}function Pm(e,t,n){if(tt.current!==_r)throw Error(N(168));le(tt,t),le(ft,n)}function H0(e,t,n){var r=e.stateNode;if(t=t.childContextTypes,typeof r.getChildContext!="function")return n;r=r.getChildContext();for(var s in r)if(!(s in t))throw Error(N(108,T_(e)||"Unknown",s));return be({},n,r)}function Ll(e){return e=(e=e.stateNode)&&e.__reactInternalMemoizedMergedChildContext||_r,ds=tt.current,le(tt,e),le(ft,ft.current),!0}function Am(e,t,n){var r=e.stateNode;if(!r)throw Error(N(169));n?(e=H0(e,t,ds),r.__reactInternalMemoizedMergedChildContext=e,de(ft),de(tt),le(tt,e)):de(ft),le(ft,n)}var En=null,xc=!1,vu=!1;function K0(e){En===null?En=[e]:En.push(e)}function zk(e){xc=!0,K0(e)}function Nr(){if(!vu&&En!==null){vu=!0;var e=0,t=ie;try{var n=En;for(ie=1;e<n.length;e++){var r=n[e];do r=r(!0);while(r!==null)}En=null,xc=!1}catch(s){throw En!==null&&(En=En.slice(e+1)),y0(tf,Nr),s}finally{ie=t,vu=!1}}return null}var Hs=[],Ks=0,Ml=null,$l=0,At=[],Rt=0,hs=null,Cn=1,Pn="";function Br(e,t){Hs[Ks++]=$l,Hs[Ks++]=Ml,Ml=e,$l=t}function q0(e,t,n){At[Rt++]=Cn,At[Rt++]=Pn,At[Rt++]=hs,hs=e;var r=Cn;e=Pn;var s=32-en(r)-1;r&=~(1<<s),n+=1;var i=32-en(t)+s;
vendor: 5,860 bytes, line 38
38if(30<i){var o=s-s%5;i=(r&(1<<o)-1).toString(32),r>>=o,s-=o,Cn=1<<32-en(t)+s|n<<s|r,Pn=i+e}else Cn=1<<i|n<<s|r,Pn=e}function df(e){e.return!==null&&(Br(e,1),q0(e,1,0))}function hf(e){for(;e===Ml;)Ml=Hs[--Ks],Hs[Ks]=null,$l=Hs[--Ks],Hs[Ks]=null;for(;e===hs;)hs=At[--Rt],At[Rt]=null,Pn=At[--Rt],At[Rt]=null,Cn=At[--Rt],At[Rt]=null}var xt=null,wt=null,me=!1,Xt=null;function G0(e,t){var n=jt(5,null,null,0);n.elementType="DELETED",n.stateNode=t,n.return=e,t=e.deletions,t===null?(e.deletions=[n],e.flags|=16):t.push(n)}function Rm(e,t){switch(e.tag){case 5:var n=e.type;return t=t.nodeType!==1||n.toLowerCase()!==t.nodeName.toLowerCase()?null:t,t!==null?(e.stateNode=t,xt=e,wt=gr(t.firstChild),!0):!1;case 6:return t=e.pendingProps===""||t.nodeType!==3?null:t,t!==null?(e.stateNode=t,xt=e,wt=null,!0):!1;case 13:return t=t.nodeType!==8?null:t,t!==null?(n=hs!==null?{id:Cn,overflow:Pn}:null,e.memoizedState={dehydrated:t,treeContext:n,retryLane:1073741824},n=jt(18,null,null,0),n.stateNode=t,n.return=e,e.child=n,xt=e,wt=null,!0):!1;default:return!1}}function jd(e){return(e.mode&1)!==0&&(e.flags&128)===0}function Nd(e){if(me){var t=wt;if(t){var n=t;if(!Rm(e,t)){if(jd(e))throw Error(N(418));t=gr(n.nextSibling);var r=xt;t&&Rm(e,t)?G0(r,n):(e.flags=e.flags&-4097|2,me=!1,xt=e)}}else{if(jd(e))throw Error(N(418));e.flags=e.flags&-4097|2,me=!1,xt=e}}}function jm(e){for(e=e.return;e!==null&&e.tag!==5&&e.tag!==3&&e.tag!==13;)e=e.return;xt=e}function Fa(e){if(e!==xt)return!1;if(!me)return jm(e),me=!0,!1;var t;if((t=e.tag!==3)&&!(t=e.tag!==5)&&(t=e.type,t=t!=="head"&&t!=="body"&&!Cd(e.type,e.memoizedProps)),t&&(t=wt)){if(jd(e))throw Y0(),Error(N(418));for(;t;)G0(e,t),t=gr(t.nextSibling)}if(jm(e),e.tag===13){if(e=e.memoizedState,e=e!==null?e.dehydrated:null,!e)throw Error(N(317));e:{for(e=e.nextSibling,t=0;e;){if(e.nodeType===8){var n=e.data;if(n==="/$"){if(t===0){wt=gr(e.nextSibling);break e}t--}else n!=="$"&&n!=="$!"&&n!=="$?"||t++}e=e.nextSibling}wt=null}}else wt=xt?gr(e.stateNode.nextSibling):null;return!0}function Y0(){for(var e=wt;e;)e=gr(e.nextSibling)}function Si(){wt=xt=null,me=!1}function ff(e){Xt===null?Xt=[e]:Xt.push(e)}var Wk=Vn.ReactCurrentBatchConfig;function Qi(e,t,n){if(e=n.ref,e!==null&&typeof e!="function"&&typeof e!="object"){if(n._owner){if(n=n._owner,n){if(n.tag!==1)throw Error(N(309));var r=n.stateNode}if(!r)throw Error(N(147,e));var s=r,i=""+e;return t!==null&&t.ref!==null&&typeof t.ref=="function"&&t.ref._stringRef===i?t.ref:(t=function(o){var a=s.refs;o===null?delete a[i]:a[i]=o},t._stringRef=i,t)}if(typeof e!="string")throw Error(N(284));if(!n._owner)throw Error(N(290,e))}return e}function Ua(e,t){throw e=Object.prototype.toString.call(t),Error(N(31,e==="[object Object]"?"object with keys {"+Object.keys(t).join(", ")+"}":e))}function Nm(e){var t=e._init;return t(e._payload)}function Q0(e){function t(m,g){if(e){var v=m.deletions;v===null?(m.deletions=[g],m.flags|=16):v.push(g)}}function n(m,g){if(!e)return null;for(;g!==null;)t(m,g),g=g.sibling;return null}function r(m,g){for(m=new Map;g!==null;)g.key!==null?m.set(g.key,g):m.set(g.index,g),g=g.sibling;return m}function s(m,g){return m=xr(m,g),m.index=0,m.sibling=null,m}function i(m,g,v){return m.index=v,e?(v=m.alternate,v!==null?(v=v.index,v<g?(m.flags|=2,g):v):(m.flags|=2,g)):(m.flags|=1048576,g)}function o(m){return e&&m.alternate===null&&(m.flags|=2),m}function a(m,g,v,S){return g===null||g.tag!==6?(g=Eu(v,m.mode,S),g.return=m,g):(g=s(g,v),g.return=m,g)}function l(m,g,v,S){var _=v.type;return _===Vs?u(m,g,v.props.children,S,v.key):g!==null&&(g.elementType===_||typeof _=="object"&&_!==null&&_.$$typeof===Zn&&Nm(_)===g.type)?(S=s(g,v.props),S.ref=Qi(m,g,v),S.return=m,S):(S=vl(v.type,v.key,v.props,null,m.mode,S),S.ref=Qi(m,g,v),S.return=m,S)}function c(m,g,v,S){return g===null||g.tag!==4||g.stateNode.containerInfo!==v.containerInfo||g.stateNode.implementation!==v.implementation?(g=Tu(v,m.mode,S),g.return=m,g):(g=s(g,v.children||[]),g.return=m,g)}function u(m,g,v,S,_){return g===null||g.tag!==7?(g=as(v,m.mode,S,_),g.return=m,g):(g=s(g,v),g.return=m,g)}function d(m,g,v){if(typeof g=="string"&&g!==""||typeof g=="number")return g=Eu(""+g,m.mode,v),g.return=m,g;if(typeof g=="object"&&g!==null){switch(g.$$typeof){case Ra:return v=vl(g.type,g.key,g.props,null,m.mode,v),v.ref=Qi(m,null,g),v.return=m,v;case $s:return g=Tu(g,m.mode,v),g.return=m,g;case Zn:var S=g._init;return d(m,S(g._payload),v)}if(io(g)||Hi(g))return g=as(g,m.mode,v,null),g.return=m,g;Ua(m,g)}return null}function h(m,g,v,S){var _=g!==null?g.key:null;if(typeof v=="string"&&v!==""||typeof v=="number")return _!==null?null:a(m,g,""+v,S);if(typeof v=="object"&&v!==null){switch(v.$$typeof){case Ra:return v.key===_?l(m,g,v,S):null;case $s:return v.key===_?c(m,g,v,S):null;case Zn:return _=v._init,h(m,g,_(v._payload),S)}if(io(v)||Hi(v))return _!==null?null:u(m,g,v,S,null);Ua(m,v)}return null}function f(m,g,v,S,_){if(typeof S=="string"&&S!==""||typeof S=="number")return m=m.get(v)||null,a(g,m,""+S,_);if(typeof S=="object"&&S!==null){switch(S.$$typeof){case Ra:return m=m.get(S.key===null?v:S.key)||null,l(g,m,S,_);case $s:return m=m.get(S.key===null?v:S.key)||null,c(g,m,S,_);case Zn:var k=S._init;return f(m,g,v,k(S._payload),_)}if(io(S)||Hi(S))return m=m.get(v)||null,u(g,m,S,_,null);Ua(g,S)}return null}function w(m,g,v,S){for(var _=null,k=null,E=g,T=g=0,j=null;E!==null&&T<v.length;T++){E.index>T?(j=E,E=null):j=E.sibling;var O=h(m,E,v[T],S);if(O===null){E===null&&(E=j);break}e&&E&&O.alternate===null&&t(m,E),g=i(O,g,T),k===null?_=O:k.sibling=O,k=O,E=j}if(T===v.length)return n(m,E),me&&Br(m,T),_;if(E===null){for(;T<v.length;T++)E=d(m,v[T],S),E!==null&&(g=i(E,g,T),k===null?_=E:k.sibling=E,k=E);return me&&Br(m,T),_}for(E=r(m,E);T<v.length;T++)j=f(E,m,T,v[T],S),j!==null&&(e&&j.alternate!==null&&E.delete(j.key===null?T:j.key),g=i(j,g,T),k===null?_=j:k.sibling=j,k=j);
vendor: 1,476 bytes, line 38
38return e&&E.forEach(function(U){return t(m,U)}),me&&Br(m,T),_}function y(m,g,v,S){var _=Hi(v);if(typeof _!="function")throw Error(N(150));if(v=_.call(v),v==null)throw Error(N(151));for(var k=_=null,E=g,T=g=0,j=null,O=v.next();E!==null&&!O.done;T++,O=v.next()){E.index>T?(j=E,E=null):j=E.sibling;var U=h(m,E,O.value,S);if(U===null){E===null&&(E=j);break}e&&E&&U.alternate===null&&t(m,E),g=i(U,g,T),k===null?_=U:k.sibling=U,k=U,E=j}if(O.done)return n(m,E),me&&Br(m,T),_;if(E===null){for(;!O.done;T++,O=v.next())O=d(m,O.value,S),O!==null&&(g=i(O,g,T),k===null?_=O:k.sibling=O,k=O);return me&&Br(m,T),_}for(E=r(m,E);!O.done;T++,O=v.next())O=f(E,m,T,O.value,S),O!==null&&(e&&O.alternate!==null&&E.delete(O.key===null?T:O.key),g=i(O,g,T),k===null?_=O:k.sibling=O,k=O);return e&&E.forEach(function(M){return t(m,M)}),me&&Br(m,T),_}function x(m,g,v,S){if(typeof v=="object"&&v!==null&&v.type===Vs&&v.key===null&&(v=v.props.children),typeof v=="object"&&v!==null){switch(v.$$typeof){case Ra:e:{for(var _=v.key,k=g;k!==null;){if(k.key===_){if(_=v.type,_===Vs){if(k.tag===7){n(m,k.sibling),g=s(k,v.props.children),g.return=m,m=g;break e}}else if(k.elementType===_||typeof _=="object"&&_!==null&&_.$$typeof===Zn&&Nm(_)===k.type){n(m,k.sibling),g=s(k,v.props),g.ref=Qi(m,k,v),g.return=m,m=g;break e}n(m,k);break}else t(m,k);k=k.sibling}v.type===Vs?(g=as(v.props.children,m.mode,S,v.key),g.return=m,m=g):(S=vl(v.type,v.key,v.props,null,m.mode,S),S.ref=Qi(m,g,v),S.return=m,m=S)}return o(m);
vendor: 20,068 bytes, lines 38-40
38case $s:e:{for(k=v.key;g!==null;){if(g.key===k)if(g.tag===4&&g.stateNode.containerInfo===v.containerInfo&&g.stateNode.implementation===v.implementation){n(m,g.sibling),g=s(g,v.children||[]),g.return=m,m=g;break e}else{n(m,g);break}else t(m,g);g=g.sibling}g=Tu(v,m.mode,S),g.return=m,m=g}return o(m);case Zn:return k=v._init,x(m,g,k(v._payload),S)}if(io(v))return w(m,g,v,S);if(Hi(v))return y(m,g,v,S);Ua(m,v)}return typeof v=="string"&&v!==""||typeof v=="number"?(v=""+v,g!==null&&g.tag===6?(n(m,g.sibling),g=s(g,v),g.return=m,m=g):(n(m,g),g=Eu(v,m.mode,S),g.return=m,m=g),o(m)):n(m,g)}return x}var _i=Q0(!0),J0=Q0(!1),Vl=jr(null),Fl=null,qs=null,pf=null;function mf(){pf=qs=Fl=null}function gf(e){var t=Vl.current;de(Vl),e._currentValue=t}function Od(e,t,n){for(;e!==null;){var r=e.alternate;if((e.childLanes&t)!==t?(e.childLanes|=t,r!==null&&(r.childLanes|=t)):r!==null&&(r.childLanes&t)!==t&&(r.childLanes|=t),e===n)break;e=e.return}}function oi(e,t){Fl=e,pf=qs=null,e=e.dependencies,e!==null&&e.firstContext!==null&&(e.lanes&t&&(dt=!0),e.firstContext=null)}function Dt(e){var t=e._currentValue;if(pf!==e)if(e={context:e,memoizedValue:t,next:null},qs===null){if(Fl===null)throw Error(N(308));qs=e,Fl.dependencies={lanes:0,firstContext:e}}else qs=qs.next=e;return t}var Yr=null;function yf(e){Yr===null?Yr=[e]:Yr.push(e)}function X0(e,t,n,r){var s=t.interleaved;return s===null?(n.next=n,yf(t)):(n.next=s.next,s.next=n),t.interleaved=n,Nn(e,r)}function Nn(e,t){e.lanes|=t;var n=e.alternate;for(n!==null&&(n.lanes|=t),n=e,e=e.return;e!==null;)e.childLanes|=t,n=e.alternate,n!==null&&(n.childLanes|=t),n=e,e=e.return;return n.tag===3?n.stateNode:null}var er=!1;function vf(e){e.updateQueue={baseState:e.memoizedState,firstBaseUpdate:null,lastBaseUpdate:null,shared:{pending:null,interleaved:null,lanes:0},effects:null}}function Z0(e,t){e=e.updateQueue,t.updateQueue===e&&(t.updateQueue={baseState:e.baseState,firstBaseUpdate:e.firstBaseUpdate,lastBaseUpdate:e.lastBaseUpdate,shared:e.shared,effects:e.effects})}function An(e,t){return{eventTime:e,lane:t,tag:0,payload:null,callback:null,next:null}}function yr(e,t,n){var r=e.updateQueue;if(r===null)return null;if(r=r.shared,ne&2){var s=r.pending;return s===null?t.next=t:(t.next=s.next,s.next=t),r.pending=t,Nn(e,n)}return s=r.interleaved,s===null?(t.next=t,yf(r)):(t.next=s.next,s.next=t),r.interleaved=t,Nn(e,n)}function hl(e,t,n){if(t=t.updateQueue,t!==null&&(t=t.shared,(n&4194240)!==0)){var r=t.lanes;r&=e.pendingLanes,n|=r,t.lanes=n,nf(e,n)}}function Om(e,t){var n=e.updateQueue,r=e.alternate;if(r!==null&&(r=r.updateQueue,n===r)){var s=null,i=null;if(n=n.firstBaseUpdate,n!==null){do{var o={eventTime:n.eventTime,lane:n.lane,tag:n.tag,payload:n.payload,callback:n.callback,next:null};i===null?s=i=o:i=i.next=o,n=n.next}while(n!==null);i===null?s=i=t:i=i.next=t}else s=i=t;n={baseState:r.baseState,firstBaseUpdate:s,lastBaseUpdate:i,shared:r.shared,effects:r.effects},e.updateQueue=n;return}e=n.lastBaseUpdate,e===null?n.firstBaseUpdate=t:e.next=t,n.lastBaseUpdate=t}function Ul(e,t,n,r){var s=e.updateQueue;er=!1;var i=s.firstBaseUpdate,o=s.lastBaseUpdate,a=s.shared.pending;if(a!==null){s.shared.pending=null;var l=a,c=l.next;l.next=null,o===null?i=c:o.next=c,o=l;var u=e.alternate;u!==null&&(u=u.updateQueue,a=u.lastBaseUpdate,a!==o&&(a===null?u.firstBaseUpdate=c:a.next=c,u.lastBaseUpdate=l))}if(i!==null){var d=s.baseState;o=0,u=c=l=null,a=i;do{var h=a.lane,f=a.eventTime;if((r&h)===h){u!==null&&(u=u.next={eventTime:f,lane:0,tag:a.tag,payload:a.payload,callback:a.callback,next:null});e:{var w=e,y=a;switch(h=t,f=n,y.tag){case 1:if(w=y.payload,typeof w=="function"){d=w.call(f,d,h);break e}d=w;break e;case 3:w.flags=w.flags&-65537|128;case 0:if(w=y.payload,h=typeof w=="function"?w.call(f,d,h):w,h==null)break e;d=be({},d,h);break e;case 2:er=!0}}a.callback!==null&&a.lane!==0&&(e.flags|=64,h=s.effects,h===null?s.effects=[a]:h.push(a))}else f={eventTime:f,lane:h,tag:a.tag,payload:a.payload,callback:a.callback,next:null},u===null?(c=u=f,l=d):u=u.next=f,o|=h;if(a=a.next,a===null){if(a=s.shared.pending,a===null)break;h=a,a=h.next,h.next=null,s.lastBaseUpdate=h,s.shared.pending=null}}while(!0);if(u===null&&(l=d),s.baseState=l,s.firstBaseUpdate=c,s.lastBaseUpdate=u,t=s.shared.interleaved,t!==null){s=t;do o|=s.lane,s=s.next;while(s!==t)}else i===null&&(s.shared.lanes=0);ps|=o,e.lanes=o,e.memoizedState=d}}function Im(e,t,n){if(e=t.effects,t.effects=null,e!==null)for(t=0;t<e.length;t++){var r=e[t],s=r.callback;if(s!==null){if(r.callback=null,r=n,typeof s!="function")throw Error(N(191,s));s.call(r)}}}var fa={},mn=jr(fa),$o=jr(fa),Vo=jr(fa);function Qr(e){if(e===fa)throw Error(N(174));return e}function wf(e,t){switch(le(Vo,t),le($o,e),le(mn,fa),e=t.nodeType,e){case 9:case 11:t=(t=t.documentElement)?t.namespaceURI:fd(null,"");break;default:e=e===8?t.parentNode:t,t=e.namespaceURI||null,e=e.tagName,t=fd(t,e)}de(mn),le(mn,t)}function ki(){de(mn),de($o),de(Vo)}function ew(e){Qr(Vo.current);var t=Qr(mn.current),n=fd(t,e.type);t!==n&&(le($o,e),le(mn,n))}function xf(e){$o.current===e&&(de(mn),de($o))}var ve=jr(0);function Bl(e){for(var t=e;t!==null;){if(t.tag===13){var n=t.memoizedState;if(n!==null&&(n=n.dehydrated,n===null||n.data==="$?"||n.data==="$!"))return t}else if(t.tag===19&&t.memoizedProps.revealOrder!==void 0){if(t.flags&128)return t}else if(t.child!==null){t.child.return=t,t=t.child;continue}if(t===e)break;for(;t.sibling===null;){if(t.return===null||t.return===e)return null;t=t.return}t.sibling.return=t.return,t=t.sibling}return null}var wu=[];function bf(){for(var e=0;e<wu.length;e++)wu[e]._workInProgressVersionPrimary=null;wu.length=0}var fl=Vn.ReactCurrentDispatcher,xu=Vn.ReactCurrentBatchConfig,fs=0,xe=null,Le=null,$e=null,zl=!1,go=!1,Fo=0,Hk=0;function Qe(){throw Error(N(321))}function Sf(e,t){if(t===null)return!1;for(var n=0;n<t.length&&n<e.length;n++)if(!nn(e[n],t[n]))return!1;return!0}function _f(e,t,n,r,s,i){if(fs=i,xe=t,t.memoizedState=null,t.updateQueue=null,t.lanes=0,fl.current=e===null||e.memoizedState===null?Yk:Qk,e=n(r,s),go){i=0;do{if(go=!1,Fo=0,25<=i)throw Error(N(301));i+=1,$e=Le=null,t.updateQueue=null,fl.current=Jk,e=n(r,s)}while(go)}if(fl.current=Wl,t=Le!==null&&Le.next!==null,fs=0,$e=Le=xe=null,zl=!1,t)throw Error(N(300));return e}function kf(){var e=Fo!==0;return Fo=0,e}function ln(){var e={memoizedState:null,baseState:null,baseQueue:null,queue:null,next:null};return $e===null?xe.memoizedState=$e=e:$e=$e.next=e,$e}function Lt(){if(Le===null){var e=xe.alternate;e=e!==null?e.memoizedState:null}else e=Le.next;var t=$e===null?xe.memoizedState:$e.next;if(t!==null)$e=t,Le=e;else{if(e===null)throw Error(N(310));Le=e,e={memoizedState:Le.memoizedState,baseState:Le.baseState,baseQueue:Le.baseQueue,queue:Le.queue,next:null},$e===null?xe.memoizedState=$e=e:$e=$e.next=e}return $e}function Uo(e,t){return typeof t=="function"?t(e):t}function bu(e){var t=Lt(),n=t.queue;if(n===null)throw Error(N(311));n.lastRenderedReducer=e;var r=Le,s=r.baseQueue,i=n.pending;if(i!==null){if(s!==null){var o=s.next;s.next=i.next,i.next=o}r.baseQueue=s=i,n.pending=null}if(s!==null){i=s.next,r=r.baseState;var a=o=null,l=null,c=i;do{var u=c.lane;if((fs&u)===u)l!==null&&(l=l.next={lane:0,action:c.action,hasEagerState:c.hasEagerState,eagerState:c.eagerState,next:null}),r=c.hasEagerState?c.eagerState:e(r,c.action);else{var d={lane:u,action:c.action,hasEagerState:c.hasEagerState,eagerState:c.eagerState,next:null};l===null?(a=l=d,o=r):l=l.next=d,xe.lanes|=u,ps|=u}c=c.next}while(c!==null&&c!==i);l===null?o=r:l.next=a,nn(r,t.memoizedState)||(dt=!0),t.memoizedState=r,t.baseState=o,t.baseQueue=l,n.lastRenderedState=r}if(e=n.interleaved,e!==null){s=e;do i=s.lane,xe.lanes|=i,ps|=i,s=s.next;while(s!==e)}else s===null&&(n.lanes=0);return[t.memoizedState,n.dispatch]}function Su(e){var t=Lt(),n=t.queue;if(n===null)throw Error(N(311));n.lastRenderedReducer=e;var r=n.dispatch,s=n.pending,i=t.memoizedState;if(s!==null){n.pending=null;var o=s=s.next;do i=e(i,o.action),o=o.next;while(o!==s);nn(i,t.memoizedState)||(dt=!0),t.memoizedState=i,t.baseQueue===null&&(t.baseState=i),n.lastRenderedState=i}return[i,r]}function tw(){}function nw(e,t){var n=xe,r=Lt(),s=t(),i=!nn(r.memoizedState,s);if(i&&(r.memoizedState=s,dt=!0),r=r.queue,Ef(iw.bind(null,n,r,e),[e]),r.getSnapshot!==t||i||$e!==null&&$e.memoizedState.tag&1){if(n.flags|=2048,Bo(9,sw.bind(null,n,r,s,t),void 0,null),Ve===null)throw Error(N(349));fs&30||rw(n,t,s)}return s}function rw(e,t,n){e.flags|=16384,e={getSnapshot:t,value:n},t=xe.updateQueue,t===null?(t={lastEffect:null,stores:null},xe.updateQueue=t,t.stores=[e]):(n=t.stores,n===null?t.stores=[e]:n.push(e))}function sw(e,t,n,r){t.value=n,t.getSnapshot=r,ow(t)&&aw(e)}function iw(e,t,n){return n(function(){ow(t)&&aw(e)})}function ow(e){var t=e.getSnapshot;e=e.value;try{var n=t();return!nn(e,n)}catch{return!0}}function aw(e){var t=Nn(e,1);t!==null&&tn(t,e,1,-1)}function Dm(e){var t=ln();return typeof e=="function"&&(e=e()),t.memoizedState=t.baseState=e,e={pending:null,interleaved:null,lanes:0,dispatch:null,lastRenderedReducer:Uo,lastRenderedState:e},t.queue=e,e=e.dispatch=Gk.bind(null,xe,e),[t.memoizedState,e]}function Bo(e,t,n,r){return e={tag:e,create:t,destroy:n,deps:r,next:null},t=xe.updateQueue,t===null?(t={lastEffect:null,stores:null},xe.updateQueue=t,t.lastEffect=e.next=e):(n=t.lastEffect,n===null?t.lastEffect=e.next=e:(r=n.next,n.next=e,e.next=r,t.lastEffect=e)),e}function lw(){return Lt().memoizedState}function pl(e,t,n,r){var s=ln();xe.flags|=e,s.memoizedState=Bo(1|t,n,void 0,r===void 0?null:r)}function bc(e,t,n,r){var s=Lt();r=r===void 0?null:r;var i=void 0;if(Le!==null){var o=Le.memoizedState;if(i=o.destroy,r!==null&&Sf(r,o.deps)){s.memoizedState=Bo(t,n,i,r);return}}xe.flags|=e,s.memoizedState=Bo(1|t,n,i,r)}function Lm(e,t){return pl(8390656,8,e,t)}function Ef(e,t){return bc(2048,8,e,t)}function cw(e,t){return bc(4,2,e,t)}function uw(e,t){return bc(4,4,e,t)}function dw(e,t){if(typeof t=="function")return e=e(),t(e),function(){t(null)};if(t!=null)return e=e(),t.current=e,function(){t.current=null}}function hw(e,t,n){return n=n!=null?n.concat([e]):null,bc(4,4,dw.bind(null,t,e),n)}function Tf(){}function fw(e,t){var n=Lt();t=t===void 0?null:t;var r=n.memoizedState;return r!==null&&t!==null&&Sf(t,r[1])?r[0]:(n.memoizedState=[e,t],e)}function pw(e,t){var n=Lt();t=t===void 0?null:t;var r=n.memoizedState;return r!==null&&t!==null&&Sf(t,r[1])?r[0]:(e=e(),n.memoizedState=[e,t],e)}function mw(e,t,n){return fs&21?(nn(n,t)||(n=x0(),xe.lanes|=n,ps|=n,e.baseState=!0),t):(e.baseState&&(e.baseState=!1,dt=!0),e.memoizedState=n)}function Kk(e,t){var n=ie;ie=n!==0&&4>n?n:4,e(!0);var r=xu.transition;xu.transition={};try{e(!1),t()}finally{ie=n,xu.transition=r}}function gw(){return Lt().memoizedState}function qk(e,t,n){var r=wr(e);if(n={lane:r,action:n,hasEagerState:!1,eagerState:null,next:null},yw(e))vw(t,n);else if(n=X0(e,t,n,r),n!==null){var s=ot();tn(n,e,r,s),ww(n,t,r)}}function Gk(e,t,n){var r=wr(e),s={lane:r,action:n,hasEagerState:!1,eagerState:null,next:null};if(yw(e))vw(t,s);else{var i=e.alternate;if(e.lanes===0&&(i===null||i.lanes===0)&&(i=t.lastRenderedReducer,i!==null))try{var o=t.lastRenderedState,a=i(o,n);if(s.hasEagerState=!0,s.eagerState=a,nn(a,o)){var l=t.interleaved;l===null?(s.next=s,yf(t)):(s.next=l.next,l.next=s),t.interleaved=s;return}}catch{}finally{}n=X0(e,t,s,r),n!==null&&(s=ot(),tn(n,e,r,s),ww(n,t,r))}}function yw(e){var t=e.alternate;return e===xe||t!==null&&t===xe}function vw(e,t){go=zl=!0;var n=e.pending;n===null?t.next=t:(t.next=n.next,n.next=t),e.pending=t}function ww(e,t,n){if(n&4194240){var r=t.lanes;r&=e.pendingLanes,n|=r,t.lanes=n,nf(e,n)}}var Wl={readContext:Dt,useCallback:Qe,useContext:Qe,useEffect:Qe,useImperativeHandle:Qe,useInsertionEffect:Qe,useLayoutEffect:Qe,useMemo:Qe,useReducer:Qe,useRef:Qe,useState:Qe,useDebugValue:Qe,useDeferredValue:Qe,useTransition:Qe,useMutableSource:Qe,useSyncExternalStore:Qe,useId:Qe,unstable_isNewReconciler:!1},Yk={readContext:Dt,useCallback:function(e,t){return ln().memoizedState=[e,t===void 0?null:t],e},useContext:Dt,useEffect:Lm,useImperativeHandle:function(e,t,n){return n=n!=null?n.concat([e]):null,pl(4194308,4,dw.bind(null,t,e),n)},useLayoutEffect:function(e,t){return pl(4194308,4,e,t)},useInsertionEffect:function(e,t){return pl(4,2,e,t)},useMemo:function(e,t){var n=ln();return t=t===void 0?null:t,e=e(),n.memoizedState=[e,t],e},useReducer:function(e,t,n){var r=ln();return t=n!==void 0?n(t):t,r.memoizedState=r.baseState=t,e={pending:null,interleaved:null,lanes:0,dispatch:null,lastRenderedReducer:e,lastRenderedState:t},r.queue=e,e=e.dispatch=qk.bind(null,xe,e),[r.memoizedState,e]},useRef:function(e){var t=ln();return e={current:e},t.memoizedState=e},useState:Dm,useDebugValue:Tf,useDeferredValue:function(e){return ln().memoizedState=e},useTransition:function(){var e=Dm(!1),t=e[0];return e=Kk.bind(null,e[1]),ln().memoizedState=e,[t,e]},useMutableSource:function(){},useSyncExternalStore:function(e,t,n){var r=xe,s=ln();if(me){if(n===void 0)throw Error(N(407));n=n()}else{if(n=t(),Ve===null)throw Error(N(349));fs&30||rw(r,t,n)}s.memoizedState=n;var i={value:n,getSnapshot:t};return s.queue=i,Lm(iw.bind(null,r,i,e),[e]),r.flags|=2048,Bo(9,sw.bind(null,r,i,n,t),void 0,null),n},useId:function(){var e=ln(),t=Ve.identifierPrefix;if(me){var n=Pn,r=Cn;n=(r&~(1<<32-en(r)-1)).toString(32)+n,t=":"+t+"R"+n,n=Fo++,0<n&&(t+="H"+n.toString(32)),t+=":"}else n=Hk++,t=":"+t+"r"+n.toString(32)+":";return e.memoizedState=t},unstable_isNewReconciler:!1},Qk={readContext:Dt,useCallback:fw,useContext:Dt,useEffect:Ef,useImperativeHandle:hw,useInsertionEffect:cw,useLayoutEffect:uw,useMemo:pw,useReducer:bu,useRef:lw,useState:function(){return bu(Uo)},useDebugValue:Tf,useDeferredValue:function(e){var t=Lt();return mw(t,Le.memoizedState,e)},useTransition:function(){var e=bu(Uo)[0],t=Lt().memoizedState;return[e,t]},useMutableSource:tw,useSyncExternalStore:nw,useId:gw,unstable_isNewReconciler:!1},Jk={readContext:Dt,useCallback:fw,useContext:Dt,useEffect:Ef,useImperativeHandle:hw,useInsertionEffect:cw,useLayoutEffect:uw,useMemo:pw,useReducer:Su,useRef:lw,useState:function(){return Su(Uo)},useDebugValue:Tf,useDeferredValue:function(e){var t=Lt();return Le===null?t.memoizedState=e:mw(t,Le.memoizedState,e)},useTransition:function(){var e=Su(Uo)[0],t=Lt().memoizedState;return[e,t]},useMutableSource:tw,useSyncExternalStore:nw,useId:gw,unstable_isNewReconciler:!1};function Kt(e,t){if(e&&e.defaultProps){t=be({},t),e=e.defaultProps;for(var n in e)t[n]===void 0&&(t[n]=e[n]);return t}return t}function Id(e,t,n,r){t=e.memoizedState,n=n(r,t),n=n==null?t:be({},t,n),e.memoizedState=n,e.lanes===0&&(e.updateQueue.baseState=n)}var Sc={isMounted:function(e){return(e=e._reactInternals)?vs(e)===e:!1},enqueueSetState:function(e,t,n){e=e._reactInternals;var r=ot(),s=wr(e),i=An(r,s);i.payload=t,n!=null&&(i.callback=n),t=yr(e,i,s),t!==null&&(tn(t,e,s,r),hl(t,e,s))},enqueueReplaceState:function(e,t,n){e=e._reactInternals;var r=ot(),s=wr(e),i=An(r,s);i.tag=1,i.payload=t,n!=null&&(i.callback=n),t=yr(e,i,s),t!==null&&(tn(t,e,s,r),hl(t,e,s))},enqueueForceUpdate:function(e,t){e=e._reactInternals;var n=ot(),r=wr(e),s=An(n,r);s.tag=2,t!=null&&(s.callback=t),t=yr(e,s,r),t!==null&&(tn(t,e,r,n),hl(t,e,r))}};function Mm(e,t,n,r,s,i,o){return e=e.stateNode,typeof e.shouldComponentUpdate=="function"?e.shouldComponentUpdate(r,i,o):t.prototype&&t.prototype.isPureReactComponent?!Io(n,r)||!Io(s,i):!0}function xw(e,t,n){var r=!1,s=_r,i=t.contextType;return typeof i=="object"&&i!==null?i=Dt(i):(s=pt(t)?ds:tt.current,r=t.contextTypes,i=(r=r!=null)?bi(e,s):_r),t=new t(n,i),e.memoizedState=t.state!==null&&t.state!==void 0?t.state:null,t.updater=Sc,e.stateNode=t,t._reactInternals=e,r&&(e=e.stateNode,e.__reactInternalMemoizedUnmaskedChildContext=s,e.__reactInternalMemoizedMaskedChildContext=i),t}function $m(e,t,n,r){e=t.state,typeof t.componentWillReceiveProps=="function"&&t.componentWillReceiveProps(n,r),typeof t.UNSAFE_componentWillReceiveProps=="function"&&t.UNSAFE_componentWillReceiveProps(n,r),t.state!==e&&Sc.enqueueReplaceState(t,t.state,null)}function Dd(e,t,n,r){var s=e.stateNode;s.props=n,s.state=e.memoizedState,s.refs={},vf(e);var i=t.contextType;typeof i=="object"&&i!==null?s.context=Dt(i):(i=pt(t)?ds:tt.current,s.context=bi(e,i)),s.state=e.memoizedState,i=t.getDerivedStateFromProps,typeof i=="function"&&(Id(e,t,i,n),s.state=e.memoizedState),typeof t.getDerivedStateFromProps=="function"||typeof s.getSnapshotBeforeUpdate=="function"||typeof s.UNSAFE_componentWillMount!="function"&&typeof s.componentWillMount!="function"||(t=s.state,typeof s.componentWillMount=="function"&&s.componentWillMount(),typeof s.UNSAFE_componentWillMount=="function"&&s.UNSAFE_componentWillMount(),t!==s.state&&Sc.enqueueReplaceState(s,s.state,null),Ul(e,n,s,r),s.state=e.memoizedState),typeof s.componentDidMount=="function"&&(e.flags|=4194308)}function Ei(e,t){try{var n="",r=t;do n+=E_(r),r=r.return;while(r);var s=n}catch(i){s=` 39Error generating stack: `+i.message+` 40`+i.stack}return{value:e,source:t,stack:s,digest:null}}function _u(e,t,n){return{value:e,source:null,stack:n??null,digest:t??null}}function Ld(e,t){try{console.error(t.value)}catch(n){setTimeout(function(){throw n})}}var Xk=typeof WeakMap=="function"?WeakMap:Map;function bw(e,t,n){n=An(-1,n),n.tag=3,n.payload={element:null};var r=t.value;return n.callback=function(){Kl||(Kl=!0,Kd=r),Ld(e,t)},n}function Sw(e,t,n){n=An(-1,n),n.tag=3;var r=e.type.getDerivedStateFromError;if(typeof r=="function"){var s=t.value;n.payload=function(){return r(s)},n.callback=function(){Ld(e,t)}}var i=e.stateNode;return i!==null&&typeof i.componentDidCatch=="function"&&(n.callback=function(){Ld(e,t),typeof r!="function"&&(vr===null?vr=new Set([this]):vr.add(this));var o=t.stack;this.componentDidCatch(t.value,{componentStack:o!==null?o:""})}),n}function Vm(e,t,n){var r=e.pingCache;if(r===null){r=e.pingCache=new Xk;var s=new Set;r.set(t,s)}else s=r.get(t),s===void 0&&(s=new Set,r.set(t,s));s.has(n)||(s.add(n),e=hE.bind(null,e,t,n),t.then(e,e))}function Fm(e){do{var t;if((t=e.tag===13)&&(t=e.memoizedState,t=t!==null?t.dehydrated!==null:!0),t)return e;e=e.return}while(e!==null);return null}function Um(e,t,n,r,s){return e.mode&1?(e.flags|=65536,e.lanes=s,e):(e===t?e.flags|=65536:(e.flags|=128,n.flags|=131072,n.flags&=-52805,n.tag===1&&(n.alternate===null?n.tag=17:(t=An(-1,1),t.tag=2,yr(n,t,1))),n.lanes|=1),e)}var Zk=Vn.ReactCurrentOwner,dt=!1;function rt(e,t,n,r){t.child=e===null?J0(t,null,n,r):_i(t,e.child,n,r)}function Bm(e,t,n,r,s){n=n.render;var i=t.ref;return oi(t,s),r=_f(e,t,n,r,i,s),n=kf(),e!==null&&!dt?(t.updateQueue=e.updateQueue,t.flags&=-2053,e.lanes&=~s,On(e,t,s)):(me&&n&&df(t),t.flags|=1,rt(e,t,r,s),t.child)}function zm(e,t,n,r,s){if(e===null){var i=n.type;return typeof i=="function"&&!If(i)&&i.defaultProps===void 0&&n.compare===null&&n.defaultProps===void 0?(t.tag=15,t.type=i,_w(e,t,i,r,s)):(e=vl(n.type,null,r,t,t.mode,s),e.ref=t.ref,e.return=t,t.child=e)}if(i=e.child,!(e.lanes&s)){var o=i.memoizedProps;if(n=n.compare,n=n!==null?n:Io,n(o,r)&&e.ref===t.ref)return On(e,t,s)}return t.flags|=1,e=xr(i,r),e.ref=t.ref,e.return=t,t.child=e}function _w(e,t,n,r,s){if(e!==null){var i=e.memoizedProps;if(Io(i,r)&&e.ref===t.ref)if(dt=!1,t.pendingProps=r=i,(e.lanes&s)!==0)e.flags&131072&&(dt=!0);else return t.lanes=e.lanes,On(e,t,s)}return Md(e,t,n,r,s)}function kw(e,t,n){var r=t.pendingProps,s=r.children,i=e!==null?e.memoizedState:null;if(r.mode==="hidden")if(!(t.mode&1))t.memoizedState={baseLanes:0,cachePool:null,transitions:null},le(Ys,yt),yt|=n;else{if(!(n&1073741824))return e=i!==null?i.baseLanes|n:n,t.lanes=t.childLanes=1073741824,t.memoizedState={baseLanes:e,cachePool:null,transitions:null},t.updateQueue=null,le(Ys,yt),yt|=e,null;t.memoizedState={baseLanes:0,cachePool:null,transitions:null},r=i!==null?i.baseLanes:n,le(Ys,yt),yt|=r}else i!==null?(r=i.baseLanes|n,t.memoizedState=null):r=n,le(Ys,yt),yt|=r;return rt(e,t,s,n),t.child}function Ew(e,t){var n=t.ref;(e===null&&n!==null||e!==null&&e.ref!==n)&&(t.flags|=512,t.flags|=2097152)}
vendor: 6,726 bytes, line 40
40function Md(e,t,n,r,s){var i=pt(n)?ds:tt.current;return i=bi(t,i),oi(t,s),n=_f(e,t,n,r,i,s),r=kf(),e!==null&&!dt?(t.updateQueue=e.updateQueue,t.flags&=-2053,e.lanes&=~s,On(e,t,s)):(me&&r&&df(t),t.flags|=1,rt(e,t,n,s),t.child)}function Wm(e,t,n,r,s){if(pt(n)){var i=!0;Ll(t)}else i=!1;if(oi(t,s),t.stateNode===null)ml(e,t),xw(t,n,r),Dd(t,n,r,s),r=!0;else if(e===null){var o=t.stateNode,a=t.memoizedProps;o.props=a;var l=o.context,c=n.contextType;typeof c=="object"&&c!==null?c=Dt(c):(c=pt(n)?ds:tt.current,c=bi(t,c));var u=n.getDerivedStateFromProps,d=typeof u=="function"||typeof o.getSnapshotBeforeUpdate=="function";d||typeof o.UNSAFE_componentWillReceiveProps!="function"&&typeof o.componentWillReceiveProps!="function"||(a!==r||l!==c)&&$m(t,o,r,c),er=!1;var h=t.memoizedState;o.state=h,Ul(t,r,o,s),l=t.memoizedState,a!==r||h!==l||ft.current||er?(typeof u=="function"&&(Id(t,n,u,r),l=t.memoizedState),(a=er||Mm(t,n,a,r,h,l,c))?(d||typeof o.UNSAFE_componentWillMount!="function"&&typeof o.componentWillMount!="function"||(typeof o.componentWillMount=="function"&&o.componentWillMount(),typeof o.UNSAFE_componentWillMount=="function"&&o.UNSAFE_componentWillMount()),typeof o.componentDidMount=="function"&&(t.flags|=4194308)):(typeof o.componentDidMount=="function"&&(t.flags|=4194308),t.memoizedProps=r,t.memoizedState=l),o.props=r,o.state=l,o.context=c,r=a):(typeof o.componentDidMount=="function"&&(t.flags|=4194308),r=!1)}else{o=t.stateNode,Z0(e,t),a=t.memoizedProps,c=t.type===t.elementType?a:Kt(t.type,a),o.props=c,d=t.pendingProps,h=o.context,l=n.contextType,typeof l=="object"&&l!==null?l=Dt(l):(l=pt(n)?ds:tt.current,l=bi(t,l));var f=n.getDerivedStateFromProps;(u=typeof f=="function"||typeof o.getSnapshotBeforeUpdate=="function")||typeof o.UNSAFE_componentWillReceiveProps!="function"&&typeof o.componentWillReceiveProps!="function"||(a!==d||h!==l)&&$m(t,o,r,l),er=!1,h=t.memoizedState,o.state=h,Ul(t,r,o,s);var w=t.memoizedState;a!==d||h!==w||ft.current||er?(typeof f=="function"&&(Id(t,n,f,r),w=t.memoizedState),(c=er||Mm(t,n,c,r,h,w,l)||!1)?(u||typeof o.UNSAFE_componentWillUpdate!="function"&&typeof o.componentWillUpdate!="function"||(typeof o.componentWillUpdate=="function"&&o.componentWillUpdate(r,w,l),typeof o.UNSAFE_componentWillUpdate=="function"&&o.UNSAFE_componentWillUpdate(r,w,l)),typeof o.componentDidUpdate=="function"&&(t.flags|=4),typeof o.getSnapshotBeforeUpdate=="function"&&(t.flags|=1024)):(typeof o.componentDidUpdate!="function"||a===e.memoizedProps&&h===e.memoizedState||(t.flags|=4),typeof o.getSnapshotBeforeUpdate!="function"||a===e.memoizedProps&&h===e.memoizedState||(t.flags|=1024),t.memoizedProps=r,t.memoizedState=w),o.props=r,o.state=w,o.context=l,r=c):(typeof o.componentDidUpdate!="function"||a===e.memoizedProps&&h===e.memoizedState||(t.flags|=4),typeof o.getSnapshotBeforeUpdate!="function"||a===e.memoizedProps&&h===e.memoizedState||(t.flags|=1024),r=!1)}return $d(e,t,n,r,i,s)}function $d(e,t,n,r,s,i){Ew(e,t);var o=(t.flags&128)!==0;if(!r&&!o)return s&&Am(t,n,!1),On(e,t,i);r=t.stateNode,Zk.current=t;var a=o&&typeof n.getDerivedStateFromError!="function"?null:r.render();return t.flags|=1,e!==null&&o?(t.child=_i(t,e.child,null,i),t.child=_i(t,null,a,i)):rt(e,t,a,i),t.memoizedState=r.state,s&&Am(t,n,!0),t.child}function Tw(e){var t=e.stateNode;t.pendingContext?Pm(e,t.pendingContext,t.pendingContext!==t.context):t.context&&Pm(e,t.context,!1),wf(e,t.containerInfo)}function Hm(e,t,n,r,s){return Si(),ff(s),t.flags|=256,rt(e,t,n,r),t.child}var Vd={dehydrated:null,treeContext:null,retryLane:0};function Fd(e){return{baseLanes:e,cachePool:null,transitions:null}}function Cw(e,t,n){var r=t.pendingProps,s=ve.current,i=!1,o=(t.flags&128)!==0,a;if((a=o)||(a=e!==null&&e.memoizedState===null?!1:(s&2)!==0),a?(i=!0,t.flags&=-129):(e===null||e.memoizedState!==null)&&(s|=1),le(ve,s&1),e===null)return Nd(t),e=t.memoizedState,e!==null&&(e=e.dehydrated,e!==null)?(t.mode&1?e.data==="$!"?t.lanes=8:t.lanes=1073741824:t.lanes=1,null):(o=r.children,e=r.fallback,i?(r=t.mode,i=t.child,o={mode:"hidden",children:o},!(r&1)&&i!==null?(i.childLanes=0,i.pendingProps=o):i=Ec(o,r,0,null),e=as(e,r,n,null),i.return=t,e.return=t,i.sibling=e,t.child=i,t.child.memoizedState=Fd(n),t.memoizedState=Vd,e):Cf(t,o));if(s=e.memoizedState,s!==null&&(a=s.dehydrated,a!==null))return eE(e,t,o,r,a,s,n);if(i){i=r.fallback,o=t.mode,s=e.child,a=s.sibling;var l={mode:"hidden",children:r.children};return!(o&1)&&t.child!==s?(r=t.child,r.childLanes=0,r.pendingProps=l,t.deletions=null):(r=xr(s,l),r.subtreeFlags=s.subtreeFlags&14680064),a!==null?i=xr(a,i):(i=as(i,o,n,null),i.flags|=2),i.return=t,r.return=t,r.sibling=i,t.child=r,r=i,i=t.child,o=e.child.memoizedState,o=o===null?Fd(n):{baseLanes:o.baseLanes|n,cachePool:null,transitions:o.transitions},i.memoizedState=o,i.childLanes=e.childLanes&~n,t.memoizedState=Vd,r}return i=e.child,e=i.sibling,r=xr(i,{mode:"visible",children:r.children}),!(t.mode&1)&&(r.lanes=n),r.return=t,r.sibling=null,e!==null&&(n=t.deletions,n===null?(t.deletions=[e],t.flags|=16):n.push(e)),t.child=r,t.memoizedState=null,r}function Cf(e,t){return t=Ec({mode:"visible",children:t},e.mode,0,null),t.return=e,e.child=t}function Ba(e,t,n,r){return r!==null&&ff(r),_i(t,e.child,null,n),e=Cf(t,t.pendingProps.children),e.flags|=2,t.memoizedState=null,e}function eE(e,t,n,r,s,i,o){if(n)return t.flags&256?(t.flags&=-257,r=_u(Error(N(422))),Ba(e,t,o,r)):t.memoizedState!==null?(t.child=e.child,t.flags|=128,null):(i=r.fallback,s=t.mode,r=Ec({mode:"visible",children:r.children},s,0,null),i=as(i,s,o,null),i.flags|=2,r.return=t,i.return=t,r.sibling=i,t.child=r,t.mode&1&&_i(t,e.child,null,o),t.child.memoizedState=Fd(o),t.memoizedState=Vd,i);if(!(t.mode&1))return Ba(e,t,o,null);if(s.data==="$!"){if(r=s.nextSibling&&s.nextSibling.dataset,r)var a=r.dgst;return r=a,i=Error(N(419)),r=_u(i,r,void 0),Ba(e,t,o,r)}if(a=(o&e.childLanes)!==0,dt||a){if(r=Ve,r!==null){switch(o&-o){case 4:s=2;break;case 16:s=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:s=32;break;case 536870912:s=268435456;break;default:s=0}s=s&(r.suspendedLanes|o)?0:s,s!==0&&s!==i.retryLane&&(i.retryLane=s,Nn(e,s),tn(r,e,s,-1))}return Of(),r=_u(Error(N(421))),Ba(e,t,o,r)}return s.data==="$?"?(t.flags|=128,t.child=e.child,t=fE.bind(null,e),s._reactRetry=t,null):(e=i.treeContext,wt=gr(s.nextSibling),xt=t,me=!0,Xt=null,e!==null&&(At[Rt++]=Cn,At[Rt++]=Pn,At[Rt++]=hs,Cn=e.id,Pn=e.overflow,hs=t),t=Cf(t,r.children),t.flags|=4096,t)}function Km(e,t,n){e.lanes|=t;var r=e.alternate;r!==null&&(r.lanes|=t),Od(e.return,t,n)}
vendor: 5,381 bytes, line 40
40function ku(e,t,n,r,s){var i=e.memoizedState;i===null?e.memoizedState={isBackwards:t,rendering:null,renderingStartTime:0,last:r,tail:n,tailMode:s}:(i.isBackwards=t,i.rendering=null,i.renderingStartTime=0,i.last=r,i.tail=n,i.tailMode=s)}function Pw(e,t,n){var r=t.pendingProps,s=r.revealOrder,i=r.tail;if(rt(e,t,r.children,n),r=ve.current,r&2)r=r&1|2,t.flags|=128;else{if(e!==null&&e.flags&128)e:for(e=t.child;e!==null;){if(e.tag===13)e.memoizedState!==null&&Km(e,n,t);else if(e.tag===19)Km(e,n,t);else if(e.child!==null){e.child.return=e,e=e.child;continue}if(e===t)break e;for(;e.sibling===null;){if(e.return===null||e.return===t)break e;e=e.return}e.sibling.return=e.return,e=e.sibling}r&=1}if(le(ve,r),!(t.mode&1))t.memoizedState=null;else switch(s){case"forwards":for(n=t.child,s=null;n!==null;)e=n.alternate,e!==null&&Bl(e)===null&&(s=n),n=n.sibling;n=s,n===null?(s=t.child,t.child=null):(s=n.sibling,n.sibling=null),ku(t,!1,s,n,i);break;case"backwards":for(n=null,s=t.child,t.child=null;s!==null;){if(e=s.alternate,e!==null&&Bl(e)===null){t.child=s;break}e=s.sibling,s.sibling=n,n=s,s=e}ku(t,!0,n,null,i);break;case"together":ku(t,!1,null,null,void 0);break;default:t.memoizedState=null}return t.child}function ml(e,t){!(t.mode&1)&&e!==null&&(e.alternate=null,t.alternate=null,t.flags|=2)}function On(e,t,n){if(e!==null&&(t.dependencies=e.dependencies),ps|=t.lanes,!(n&t.childLanes))return null;if(e!==null&&t.child!==e.child)throw Error(N(153));if(t.child!==null){for(e=t.child,n=xr(e,e.pendingProps),t.child=n,n.return=t;e.sibling!==null;)e=e.sibling,n=n.sibling=xr(e,e.pendingProps),n.return=t;n.sibling=null}return t.child}function tE(e,t,n){switch(t.tag){case 3:Tw(t),Si();break;case 5:ew(t);break;case 1:pt(t.type)&&Ll(t);break;case 4:wf(t,t.stateNode.containerInfo);break;case 10:var r=t.type._context,s=t.memoizedProps.value;le(Vl,r._currentValue),r._currentValue=s;break;case 13:if(r=t.memoizedState,r!==null)return r.dehydrated!==null?(le(ve,ve.current&1),t.flags|=128,null):n&t.child.childLanes?Cw(e,t,n):(le(ve,ve.current&1),e=On(e,t,n),e!==null?e.sibling:null);le(ve,ve.current&1);break;case 19:if(r=(n&t.childLanes)!==0,e.flags&128){if(r)return Pw(e,t,n);t.flags|=128}if(s=t.memoizedState,s!==null&&(s.rendering=null,s.tail=null,s.lastEffect=null),le(ve,ve.current),r)break;return null;case 22:case 23:return t.lanes=0,kw(e,t,n)}return On(e,t,n)}var Aw,Ud,Rw,jw;Aw=function(e,t){for(var n=t.child;n!==null;){if(n.tag===5||n.tag===6)e.appendChild(n.stateNode);else if(n.tag!==4&&n.child!==null){n.child.return=n,n=n.child;continue}if(n===t)break;for(;n.sibling===null;){if(n.return===null||n.return===t)return;n=n.return}n.sibling.return=n.return,n=n.sibling}};Ud=function(){};Rw=function(e,t,n,r){var s=e.memoizedProps;if(s!==r){e=t.stateNode,Qr(mn.current);var i=null;switch(n){case"input":s=cd(e,s),r=cd(e,r),i=[];break;case"select":s=be({},s,{value:void 0}),r=be({},r,{value:void 0}),i=[];break;case"textarea":s=hd(e,s),r=hd(e,r),i=[];break;default:typeof s.onClick!="function"&&typeof r.onClick=="function"&&(e.onclick=Il)}pd(n,r);var o;n=null;for(c in s)if(!r.hasOwnProperty(c)&&s.hasOwnProperty(c)&&s[c]!=null)if(c==="style"){var a=s[c];for(o in a)a.hasOwnProperty(o)&&(n||(n={}),n[o]="")}else c!=="dangerouslySetInnerHTML"&&c!=="children"&&c!=="suppressContentEditableWarning"&&c!=="suppressHydrationWarning"&&c!=="autoFocus"&&(Co.hasOwnProperty(c)?i||(i=[]):(i=i||[]).push(c,null));for(c in r){var l=r[c];if(a=s!=null?s[c]:void 0,r.hasOwnProperty(c)&&l!==a&&(l!=null||a!=null))if(c==="style")if(a){for(o in a)!a.hasOwnProperty(o)||l&&l.hasOwnProperty(o)||(n||(n={}),n[o]="");for(o in l)l.hasOwnProperty(o)&&a[o]!==l[o]&&(n||(n={}),n[o]=l[o])}else n||(i||(i=[]),i.push(c,n)),n=l;else c==="dangerouslySetInnerHTML"?(l=l?l.__html:void 0,a=a?a.__html:void 0,l!=null&&a!==l&&(i=i||[]).push(c,l)):c==="children"?typeof l!="string"&&typeof l!="number"||(i=i||[]).push(c,""+l):c!=="suppressContentEditableWarning"&&c!=="suppressHydrationWarning"&&(Co.hasOwnProperty(c)?(l!=null&&c==="onScroll"&&ue("scroll",e),i||a===l||(i=[])):(i=i||[]).push(c,l))}n&&(i=i||[]).push("style",n);var c=i;(t.updateQueue=c)&&(t.flags|=4)}};jw=function(e,t,n,r){n!==r&&(t.flags|=4)};function Ji(e,t){if(!me)switch(e.tailMode){case"hidden":t=e.tail;for(var n=null;t!==null;)t.alternate!==null&&(n=t),t=t.sibling;n===null?e.tail=null:n.sibling=null;break;case"collapsed":n=e.tail;for(var r=null;n!==null;)n.alternate!==null&&(r=n),n=n.sibling;r===null?t||e.tail===null?e.tail=null:e.tail.sibling=null:r.sibling=null}}function Je(e){var t=e.alternate!==null&&e.alternate.child===e.child,n=0,r=0;if(t)for(var s=e.child;s!==null;)n|=s.lanes|s.childLanes,r|=s.subtreeFlags&14680064,r|=s.flags&14680064,s.return=e,s=s.sibling;else for(s=e.child;s!==null;)n|=s.lanes|s.childLanes,r|=s.subtreeFlags,r|=s.flags,s.return=e,s=s.sibling;return e.subtreeFlags|=r,e.childLanes=n,t}function nE(e,t,n){var r=t.pendingProps;switch(hf(t),t.tag){case 2:case 16:case 15:case 0:case 11:case 7:case 8:case 12:case 9:case 14:return Je(t),null;case 1:return pt(t.type)&&Dl(),Je(t),null;case 3:return r=t.stateNode,ki(),de(ft),de(tt),bf(),r.pendingContext&&(r.context=r.pendingContext,r.pendingContext=null),(e===null||e.child===null)&&(Fa(t)?t.flags|=4:e===null||e.memoizedState.isDehydrated&&!(t.flags&256)||(t.flags|=1024,Xt!==null&&(Yd(Xt),Xt=null))),Ud(e,t),Je(t),null;case 5:xf(t);var s=Qr(Vo.current);
vendor: 29,564 bytes, line 40
40if(n=t.type,e!==null&&t.stateNode!=null)Rw(e,t,n,r,s),e.ref!==t.ref&&(t.flags|=512,t.flags|=2097152);else{if(!r){if(t.stateNode===null)throw Error(N(166));return Je(t),null}if(e=Qr(mn.current),Fa(t)){r=t.stateNode,n=t.type;var i=t.memoizedProps;switch(r[hn]=t,r[Mo]=i,e=(t.mode&1)!==0,n){case"dialog":ue("cancel",r),ue("close",r);break;case"iframe":case"object":case"embed":ue("load",r);break;case"video":case"audio":for(s=0;s<ao.length;s++)ue(ao[s],r);break;case"source":ue("error",r);break;case"img":case"image":case"link":ue("error",r),ue("load",r);break;case"details":ue("toggle",r);break;case"input":tm(r,i),ue("invalid",r);break;case"select":r._wrapperState={wasMultiple:!!i.multiple},ue("invalid",r);break;case"textarea":rm(r,i),ue("invalid",r)}pd(n,i),s=null;for(var o in i)if(i.hasOwnProperty(o)){var a=i[o];o==="children"?typeof a=="string"?r.textContent!==a&&(i.suppressHydrationWarning!==!0&&Va(r.textContent,a,e),s=["children",a]):typeof a=="number"&&r.textContent!==""+a&&(i.suppressHydrationWarning!==!0&&Va(r.textContent,a,e),s=["children",""+a]):Co.hasOwnProperty(o)&&a!=null&&o==="onScroll"&&ue("scroll",r)}switch(n){case"input":ja(r),nm(r,i,!0);break;case"textarea":ja(r),sm(r);break;case"select":case"option":break;default:typeof i.onClick=="function"&&(r.onclick=Il)}r=s,t.updateQueue=r,r!==null&&(t.flags|=4)}else{o=s.nodeType===9?s:s.ownerDocument,e==="http://www.w3.org/1999/xhtml"&&(e=i0(n)),e==="http://www.w3.org/1999/xhtml"?n==="script"?(e=o.createElement("div"),e.innerHTML="<script><\/script>",e=e.removeChild(e.firstChild)):typeof r.is=="string"?e=o.createElement(n,{is:r.is}):(e=o.createElement(n),n==="select"&&(o=e,r.multiple?o.multiple=!0:r.size&&(o.size=r.size))):e=o.createElementNS(e,n),e[hn]=t,e[Mo]=r,Aw(e,t,!1,!1),t.stateNode=e;e:{switch(o=md(n,r),n){case"dialog":ue("cancel",e),ue("close",e),s=r;break;case"iframe":case"object":case"embed":ue("load",e),s=r;break;case"video":case"audio":for(s=0;s<ao.length;s++)ue(ao[s],e);s=r;break;case"source":ue("error",e),s=r;break;case"img":case"image":case"link":ue("error",e),ue("load",e),s=r;break;case"details":ue("toggle",e),s=r;break;case"input":tm(e,r),s=cd(e,r),ue("invalid",e);break;case"option":s=r;break;case"select":e._wrapperState={wasMultiple:!!r.multiple},s=be({},r,{value:void 0}),ue("invalid",e);break;case"textarea":rm(e,r),s=hd(e,r),ue("invalid",e);break;default:s=r}pd(n,s),a=s;for(i in a)if(a.hasOwnProperty(i)){var l=a[i];i==="style"?l0(e,l):i==="dangerouslySetInnerHTML"?(l=l?l.__html:void 0,l!=null&&o0(e,l)):i==="children"?typeof l=="string"?(n!=="textarea"||l!=="")&&Po(e,l):typeof l=="number"&&Po(e,""+l):i!=="suppressContentEditableWarning"&&i!=="suppressHydrationWarning"&&i!=="autoFocus"&&(Co.hasOwnProperty(i)?l!=null&&i==="onScroll"&&ue("scroll",e):l!=null&&Qh(e,i,l,o))}switch(n){case"input":ja(e),nm(e,r,!1);break;case"textarea":ja(e),sm(e);break;case"option":r.value!=null&&e.setAttribute("value",""+Sr(r.value));break;case"select":e.multiple=!!r.multiple,i=r.value,i!=null?ni(e,!!r.multiple,i,!1):r.defaultValue!=null&&ni(e,!!r.multiple,r.defaultValue,!0);break;default:typeof s.onClick=="function"&&(e.onclick=Il)}switch(n){case"button":case"input":case"select":case"textarea":r=!!r.autoFocus;break e;case"img":r=!0;break e;default:r=!1}}r&&(t.flags|=4)}t.ref!==null&&(t.flags|=512,t.flags|=2097152)}return Je(t),null;case 6:if(e&&t.stateNode!=null)jw(e,t,e.memoizedProps,r);else{if(typeof r!="string"&&t.stateNode===null)throw Error(N(166));if(n=Qr(Vo.current),Qr(mn.current),Fa(t)){if(r=t.stateNode,n=t.memoizedProps,r[hn]=t,(i=r.nodeValue!==n)&&(e=xt,e!==null))switch(e.tag){case 3:Va(r.nodeValue,n,(e.mode&1)!==0);break;case 5:e.memoizedProps.suppressHydrationWarning!==!0&&Va(r.nodeValue,n,(e.mode&1)!==0)}i&&(t.flags|=4)}else r=(n.nodeType===9?n:n.ownerDocument).createTextNode(r),r[hn]=t,t.stateNode=r}return Je(t),null;case 13:if(de(ve),r=t.memoizedState,e===null||e.memoizedState!==null&&e.memoizedState.dehydrated!==null){if(me&&wt!==null&&t.mode&1&&!(t.flags&128))Y0(),Si(),t.flags|=98560,i=!1;else if(i=Fa(t),r!==null&&r.dehydrated!==null){if(e===null){if(!i)throw Error(N(318));if(i=t.memoizedState,i=i!==null?i.dehydrated:null,!i)throw Error(N(317));i[hn]=t}else Si(),!(t.flags&128)&&(t.memoizedState=null),t.flags|=4;Je(t),i=!1}else Xt!==null&&(Yd(Xt),Xt=null),i=!0;if(!i)return t.flags&65536?t:null}return t.flags&128?(t.lanes=n,t):(r=r!==null,r!==(e!==null&&e.memoizedState!==null)&&r&&(t.child.flags|=8192,t.mode&1&&(e===null||ve.current&1?Me===0&&(Me=3):Of())),t.updateQueue!==null&&(t.flags|=4),Je(t),null);case 4:return ki(),Ud(e,t),e===null&&Do(t.stateNode.containerInfo),Je(t),null;case 10:return gf(t.type._context),Je(t),null;case 17:return pt(t.type)&&Dl(),Je(t),null;case 19:if(de(ve),i=t.memoizedState,i===null)return Je(t),null;if(r=(t.flags&128)!==0,o=i.rendering,o===null)if(r)Ji(i,!1);else{if(Me!==0||e!==null&&e.flags&128)for(e=t.child;e!==null;){if(o=Bl(e),o!==null){for(t.flags|=128,Ji(i,!1),r=o.updateQueue,r!==null&&(t.updateQueue=r,t.flags|=4),t.subtreeFlags=0,r=n,n=t.child;n!==null;)i=n,e=r,i.flags&=14680066,o=i.alternate,o===null?(i.childLanes=0,i.lanes=e,i.child=null,i.subtreeFlags=0,i.memoizedProps=null,i.memoizedState=null,i.updateQueue=null,i.dependencies=null,i.stateNode=null):(i.childLanes=o.childLanes,i.lanes=o.lanes,i.child=o.child,i.subtreeFlags=0,i.deletions=null,i.memoizedProps=o.memoizedProps,i.memoizedState=o.memoizedState,i.updateQueue=o.updateQueue,i.type=o.type,e=o.dependencies,i.dependencies=e===null?null:{lanes:e.lanes,firstContext:e.firstContext}),n=n.sibling;return le(ve,ve.current&1|2),t.child}e=e.sibling}i.tail!==null&&Te()>Ti&&(t.flags|=128,r=!0,Ji(i,!1),t.lanes=4194304)}else{if(!r)if(e=Bl(o),e!==null){if(t.flags|=128,r=!0,n=e.updateQueue,n!==null&&(t.updateQueue=n,t.flags|=4),Ji(i,!0),i.tail===null&&i.tailMode==="hidden"&&!o.alternate&&!me)return Je(t),null}else 2*Te()-i.renderingStartTime>Ti&&n!==1073741824&&(t.flags|=128,r=!0,Ji(i,!1),t.lanes=4194304);i.isBackwards?(o.sibling=t.child,t.child=o):(n=i.last,n!==null?n.sibling=o:t.child=o,i.last=o)}return i.tail!==null?(t=i.tail,i.rendering=t,i.tail=t.sibling,i.renderingStartTime=Te(),t.sibling=null,n=ve.current,le(ve,r?n&1|2:n&1),t):(Je(t),null);case 22:case 23:return Nf(),r=t.memoizedState!==null,e!==null&&e.memoizedState!==null!==r&&(t.flags|=8192),r&&t.mode&1?yt&1073741824&&(Je(t),t.subtreeFlags&6&&(t.flags|=8192)):Je(t),null;case 24:return null;case 25:return null}throw Error(N(156,t.tag))}function rE(e,t){switch(hf(t),t.tag){case 1:return pt(t.type)&&Dl(),e=t.flags,e&65536?(t.flags=e&-65537|128,t):null;case 3:return ki(),de(ft),de(tt),bf(),e=t.flags,e&65536&&!(e&128)?(t.flags=e&-65537|128,t):null;case 5:return xf(t),null;case 13:if(de(ve),e=t.memoizedState,e!==null&&e.dehydrated!==null){if(t.alternate===null)throw Error(N(340));Si()}return e=t.flags,e&65536?(t.flags=e&-65537|128,t):null;case 19:return de(ve),null;case 4:return ki(),null;case 10:return gf(t.type._context),null;case 22:case 23:return Nf(),null;case 24:return null;default:return null}}var za=!1,Ze=!1,sE=typeof WeakSet=="function"?WeakSet:Set,$=null;function Gs(e,t){var n=e.ref;if(n!==null)if(typeof n=="function")try{n(null)}catch(r){Ee(e,t,r)}else n.current=null}function Bd(e,t,n){try{n()}catch(r){Ee(e,t,r)}}var qm=!1;function iE(e,t){if(Ed=jl,e=L0(),uf(e)){if("selectionStart"in e)var n={start:e.selectionStart,end:e.selectionEnd};else e:{n=(n=e.ownerDocument)&&n.defaultView||window;var r=n.getSelection&&n.getSelection();if(r&&r.rangeCount!==0){n=r.anchorNode;var s=r.anchorOffset,i=r.focusNode;r=r.focusOffset;try{n.nodeType,i.nodeType}catch{n=null;break e}var o=0,a=-1,l=-1,c=0,u=0,d=e,h=null;t:for(;;){for(var f;d!==n||s!==0&&d.nodeType!==3||(a=o+s),d!==i||r!==0&&d.nodeType!==3||(l=o+r),d.nodeType===3&&(o+=d.nodeValue.length),(f=d.firstChild)!==null;)h=d,d=f;for(;;){if(d===e)break t;if(h===n&&++c===s&&(a=o),h===i&&++u===r&&(l=o),(f=d.nextSibling)!==null)break;d=h,h=d.parentNode}d=f}n=a===-1||l===-1?null:{start:a,end:l}}else n=null}n=n||{start:0,end:0}}else n=null;for(Td={focusedElem:e,selectionRange:n},jl=!1,$=t;$!==null;)if(t=$,e=t.child,(t.subtreeFlags&1028)!==0&&e!==null)e.return=t,$=e;else for(;$!==null;){t=$;try{var w=t.alternate;if(t.flags&1024)switch(t.tag){case 0:case 11:case 15:break;case 1:if(w!==null){var y=w.memoizedProps,x=w.memoizedState,m=t.stateNode,g=m.getSnapshotBeforeUpdate(t.elementType===t.type?y:Kt(t.type,y),x);m.__reactInternalSnapshotBeforeUpdate=g}break;case 3:var v=t.stateNode.containerInfo;v.nodeType===1?v.textContent="":v.nodeType===9&&v.documentElement&&v.removeChild(v.documentElement);break;case 5:case 6:case 4:case 17:break;default:throw Error(N(163))}}catch(S){Ee(t,t.return,S)}if(e=t.sibling,e!==null){e.return=t.return,$=e;break}$=t.return}return w=qm,qm=!1,w}function yo(e,t,n){var r=t.updateQueue;if(r=r!==null?r.lastEffect:null,r!==null){var s=r=r.next;do{if((s.tag&e)===e){var i=s.destroy;s.destroy=void 0,i!==void 0&&Bd(t,n,i)}s=s.next}while(s!==r)}}function _c(e,t){if(t=t.updateQueue,t=t!==null?t.lastEffect:null,t!==null){var n=t=t.next;do{if((n.tag&e)===e){var r=n.create;n.destroy=r()}n=n.next}while(n!==t)}}function zd(e){var t=e.ref;if(t!==null){var n=e.stateNode;switch(e.tag){case 5:e=n;break;default:e=n}typeof t=="function"?t(e):t.current=e}}function Nw(e){var t=e.alternate;t!==null&&(e.alternate=null,Nw(t)),e.child=null,e.deletions=null,e.sibling=null,e.tag===5&&(t=e.stateNode,t!==null&&(delete t[hn],delete t[Mo],delete t[Ad],delete t[Uk],delete t[Bk])),e.stateNode=null,e.return=null,e.dependencies=null,e.memoizedProps=null,e.memoizedState=null,e.pendingProps=null,e.stateNode=null,e.updateQueue=null}function Ow(e){return e.tag===5||e.tag===3||e.tag===4}function Gm(e){e:for(;;){for(;e.sibling===null;){if(e.return===null||Ow(e.return))return null;e=e.return}for(e.sibling.return=e.return,e=e.sibling;e.tag!==5&&e.tag!==6&&e.tag!==18;){if(e.flags&2||e.child===null||e.tag===4)continue e;e.child.return=e,e=e.child}if(!(e.flags&2))return e.stateNode}}function Wd(e,t,n){var r=e.tag;if(r===5||r===6)e=e.stateNode,t?n.nodeType===8?n.parentNode.insertBefore(e,t):n.insertBefore(e,t):(n.nodeType===8?(t=n.parentNode,t.insertBefore(e,n)):(t=n,t.appendChild(e)),n=n._reactRootContainer,n!=null||t.onclick!==null||(t.onclick=Il));else if(r!==4&&(e=e.child,e!==null))for(Wd(e,t,n),e=e.sibling;e!==null;)Wd(e,t,n),e=e.sibling}function Hd(e,t,n){var r=e.tag;if(r===5||r===6)e=e.stateNode,t?n.insertBefore(e,t):n.appendChild(e);else if(r!==4&&(e=e.child,e!==null))for(Hd(e,t,n),e=e.sibling;e!==null;)Hd(e,t,n),e=e.sibling}var ze=null,Qt=!1;function qn(e,t,n){for(n=n.child;n!==null;)Iw(e,t,n),n=n.sibling}function Iw(e,t,n){if(pn&&typeof pn.onCommitFiberUnmount=="function")try{pn.onCommitFiberUnmount(mc,n)}catch{}switch(n.tag){case 5:Ze||Gs(n,t);case 6:var r=ze,s=Qt;ze=null,qn(e,t,n),ze=r,Qt=s,ze!==null&&(Qt?(e=ze,n=n.stateNode,e.nodeType===8?e.parentNode.removeChild(n):e.removeChild(n)):ze.removeChild(n.stateNode));break;case 18:ze!==null&&(Qt?(e=ze,n=n.stateNode,e.nodeType===8?yu(e.parentNode,n):e.nodeType===1&&yu(e,n),No(e)):yu(ze,n.stateNode));break;case 4:r=ze,s=Qt,ze=n.stateNode.containerInfo,Qt=!0,qn(e,t,n),ze=r,Qt=s;break;case 0:case 11:case 14:case 15:if(!Ze&&(r=n.updateQueue,r!==null&&(r=r.lastEffect,r!==null))){s=r=r.next;do{var i=s,o=i.destroy;i=i.tag,o!==void 0&&(i&2||i&4)&&Bd(n,t,o),s=s.next}while(s!==r)}qn(e,t,n);break;case 1:if(!Ze&&(Gs(n,t),r=n.stateNode,typeof r.componentWillUnmount=="function"))try{r.props=n.memoizedProps,r.state=n.memoizedState,r.componentWillUnmount()}catch(a){Ee(n,t,a)}qn(e,t,n);break;case 21:qn(e,t,n);break;case 22:n.mode&1?(Ze=(r=Ze)||n.memoizedState!==null,qn(e,t,n),Ze=r):qn(e,t,n);break;default:qn(e,t,n)}}function Ym(e){var t=e.updateQueue;if(t!==null){e.updateQueue=null;var n=e.stateNode;n===null&&(n=e.stateNode=new sE),t.forEach(function(r){var s=pE.bind(null,e,r);n.has(r)||(n.add(r),r.then(s,s))})}}function Ut(e,t){var n=t.deletions;if(n!==null)for(var r=0;r<n.length;r++){var s=n[r];try{var i=e,o=t,a=o;e:for(;a!==null;){switch(a.tag){case 5:ze=a.stateNode,Qt=!1;break e;case 3:ze=a.stateNode.containerInfo,Qt=!0;break e;case 4:ze=a.stateNode.containerInfo,Qt=!0;break e}a=a.return}if(ze===null)throw Error(N(160));Iw(i,o,s),ze=null,Qt=!1;var l=s.alternate;l!==null&&(l.return=null),s.return=null}catch(c){Ee(s,t,c)}}if(t.subtreeFlags&12854)for(t=t.child;t!==null;)Dw(t,e),t=t.sibling}function Dw(e,t){var n=e.alternate,r=e.flags;switch(e.tag){case 0:case 11:case 14:case 15:if(Ut(t,e),on(e),r&4){try{yo(3,e,e.return),_c(3,e)}catch(y){Ee(e,e.return,y)}try{yo(5,e,e.return)}catch(y){Ee(e,e.return,y)}}break;case 1:Ut(t,e),on(e),r&512&&n!==null&&Gs(n,n.return);break;case 5:if(Ut(t,e),on(e),r&512&&n!==null&&Gs(n,n.return),e.flags&32){var s=e.stateNode;try{Po(s,"")}catch(y){Ee(e,e.return,y)}}if(r&4&&(s=e.stateNode,s!=null)){var i=e.memoizedProps,o=n!==null?n.memoizedProps:i,a=e.type,l=e.updateQueue;if(e.updateQueue=null,l!==null)try{a==="input"&&i.type==="radio"&&i.name!=null&&r0(s,i),md(a,o);var c=md(a,i);for(o=0;o<l.length;o+=2){var u=l[o],d=l[o+1];u==="style"?l0(s,d):u==="dangerouslySetInnerHTML"?o0(s,d):u==="children"?Po(s,d):Qh(s,u,d,c)}switch(a){case"input":ud(s,i);break;case"textarea":s0(s,i);break;case"select":var h=s._wrapperState.wasMultiple;s._wrapperState.wasMultiple=!!i.multiple;var f=i.value;f!=null?ni(s,!!i.multiple,f,!1):h!==!!i.multiple&&(i.defaultValue!=null?ni(s,!!i.multiple,i.defaultValue,!0):ni(s,!!i.multiple,i.multiple?[]:"",!1))}s[Mo]=i}catch(y){Ee(e,e.return,y)}}break;case 6:if(Ut(t,e),on(e),r&4){if(e.stateNode===null)throw Error(N(162));s=e.stateNode,i=e.memoizedProps;try{s.nodeValue=i}catch(y){Ee(e,e.return,y)}}break;case 3:if(Ut(t,e),on(e),r&4&&n!==null&&n.memoizedState.isDehydrated)try{No(t.containerInfo)}catch(y){Ee(e,e.return,y)}break;case 4:Ut(t,e),on(e);break;case 13:Ut(t,e),on(e),s=e.child,s.flags&8192&&(i=s.memoizedState!==null,s.stateNode.isHidden=i,!i||s.alternate!==null&&s.alternate.memoizedState!==null||(Rf=Te())),r&4&&Ym(e);break;case 22:if(u=n!==null&&n.memoizedState!==null,e.mode&1?(Ze=(c=Ze)||u,Ut(t,e),Ze=c):Ut(t,e),on(e),r&8192){if(c=e.memoizedState!==null,(e.stateNode.isHidden=c)&&!u&&e.mode&1)for($=e,u=e.child;u!==null;){for(d=$=u;$!==null;){switch(h=$,f=h.child,h.tag){case 0:case 11:case 14:case 15:yo(4,h,h.return);break;case 1:Gs(h,h.return);var w=h.stateNode;if(typeof w.componentWillUnmount=="function"){r=h,n=h.return;try{t=r,w.props=t.memoizedProps,w.state=t.memoizedState,w.componentWillUnmount()}catch(y){Ee(r,n,y)}}break;case 5:Gs(h,h.return);break;case 22:if(h.memoizedState!==null){Jm(d);continue}}f!==null?(f.return=h,$=f):Jm(d)}u=u.sibling}e:for(u=null,d=e;;){if(d.tag===5){if(u===null){u=d;try{s=d.stateNode,c?(i=s.style,typeof i.setProperty=="function"?i.setProperty("display","none","important"):i.display="none"):(a=d.stateNode,l=d.memoizedProps.style,o=l!=null&&l.hasOwnProperty("display")?l.display:null,a.style.display=a0("display",o))}catch(y){Ee(e,e.return,y)}}}else if(d.tag===6){if(u===null)try{d.stateNode.nodeValue=c?"":d.memoizedProps}catch(y){Ee(e,e.return,y)}}else if((d.tag!==22&&d.tag!==23||d.memoizedState===null||d===e)&&d.child!==null){d.child.return=d,d=d.child;continue}if(d===e)break e;for(;d.sibling===null;){if(d.return===null||d.return===e)break e;u===d&&(u=null),d=d.return}u===d&&(u=null),d.sibling.return=d.return,d=d.sibling}}break;case 19:Ut(t,e),on(e),r&4&&Ym(e);break;case 21:break;default:Ut(t,e),on(e)}}function on(e){var t=e.flags;if(t&2){try{e:{for(var n=e.return;n!==null;){if(Ow(n)){var r=n;break e}n=n.return}throw Error(N(160))}switch(r.tag){case 5:var s=r.stateNode;r.flags&32&&(Po(s,""),r.flags&=-33);var i=Gm(e);Hd(e,i,s);break;case 3:case 4:var o=r.stateNode.containerInfo,a=Gm(e);Wd(e,a,o);break;default:throw Error(N(161))}}catch(l){Ee(e,e.return,l)}e.flags&=-3}t&4096&&(e.flags&=-4097)}function oE(e,t,n){$=e,Lw(e)}function Lw(e,t,n){for(var r=(e.mode&1)!==0;$!==null;){var s=$,i=s.child;if(s.tag===22&&r){var o=s.memoizedState!==null||za;if(!o){var a=s.alternate,l=a!==null&&a.memoizedState!==null||Ze;a=za;var c=Ze;if(za=o,(Ze=l)&&!c)for($=s;$!==null;)o=$,l=o.child,o.tag===22&&o.memoizedState!==null?Xm(s):l!==null?(l.return=o,$=l):Xm(s);for(;i!==null;)$=i,Lw(i),i=i.sibling;$=s,za=a,Ze=c}Qm(e)}else s.subtreeFlags&8772&&i!==null?(i.return=s,$=i):Qm(e)}}function Qm(e){for(;$!==null;){var t=$;if(t.flags&8772){var n=t.alternate;try{if(t.flags&8772)switch(t.tag){case 0:case 11:case 15:Ze||_c(5,t);break;case 1:var r=t.stateNode;if(t.flags&4&&!Ze)if(n===null)r.componentDidMount();else{var s=t.elementType===t.type?n.memoizedProps:Kt(t.type,n.memoizedProps);r.componentDidUpdate(s,n.memoizedState,r.__reactInternalSnapshotBeforeUpdate)}var i=t.updateQueue;i!==null&&Im(t,i,r);break;case 3:var o=t.updateQueue;if(o!==null){if(n=null,t.child!==null)switch(t.child.tag){case 5:n=t.child.stateNode;break;case 1:n=t.child.stateNode}Im(t,o,n)}break;case 5:var a=t.stateNode;if(n===null&&t.flags&4){n=a;var l=t.memoizedProps;switch(t.type){case"button":case"input":case"select":case"textarea":l.autoFocus&&n.focus();break;case"img":l.src&&(n.src=l.src)}}break;case 6:break;case 4:break;case 12:break;case 13:if(t.memoizedState===null){var c=t.alternate;if(c!==null){var u=c.memoizedState;if(u!==null){var d=u.dehydrated;d!==null&&No(d)}}}break;case 19:case 17:case 21:case 22:case 23:case 25:break;default:throw Error(N(163))}Ze||t.flags&512&&zd(t)}catch(h){Ee(t,t.return,h)}}if(t===e){$=null;break}if(n=t.sibling,n!==null){n.return=t.return,$=n;break}$=t.return}}function Jm(e){for(;$!==null;){var t=$;if(t===e){$=null;break}var n=t.sibling;if(n!==null){n.return=t.return,$=n;break}$=t.return}}function Xm(e){for(;$!==null;){var t=$;try{switch(t.tag){case 0:case 11:case 15:var n=t.return;try{_c(4,t)}catch(l){Ee(t,n,l)}break;case 1:var r=t.stateNode;if(typeof r.componentDidMount=="function"){var s=t.return;try{r.componentDidMount()}catch(l){Ee(t,s,l)}}var i=t.return;try{zd(t)}catch(l){Ee(t,i,l)}break;case 5:var o=t.return;try{zd(t)}catch(l){Ee(t,o,l)}}}catch(l){Ee(t,t.return,l)}if(t===e){$=null;break}var a=t.sibling;if(a!==null){a.return=t.return,$=a;break}$=t.return}}var aE=Math.ceil,Hl=Vn.ReactCurrentDispatcher,Pf=Vn.ReactCurrentOwner,Ot=Vn.ReactCurrentBatchConfig,ne=0,Ve=null,Ne=null,He=0,yt=0,Ys=jr(0),Me=0,zo=null,ps=0,kc=0,Af=0,vo=null,ut=null,Rf=0,Ti=1/0,_n=null,Kl=!1,Kd=null,vr=null,Wa=!1,dr=null,ql=0,wo=0,qd=null,gl=-1,yl=0;function ot(){return ne&6?Te():gl!==-1?gl:gl=Te()}function wr(e){return e.mode&1?ne&2&&He!==0?He&-He:Wk.transition!==null?(yl===0&&(yl=x0()),yl):(e=ie,e!==0||(e=window.event,e=e===void 0?16:C0(e.type)),e):1}function tn(e,t,n,r){if(50<wo)throw wo=0,qd=null,Error(N(185));ua(e,n,r),(!(ne&2)||e!==Ve)&&(e===Ve&&(!(ne&2)&&(kc|=n),Me===4&&rr(e,He)),mt(e,r),n===1&&ne===0&&!(t.mode&1)&&(Ti=Te()+500,xc&&Nr()))}function mt(e,t){var n=e.callbackNode;W_(e,t);var r=Rl(e,e===Ve?He:0);if(r===0)n!==null&&am(n),e.callbackNode=null,e.callbackPriority=0;else if(t=r&-r,e.callbackPriority!==t){if(n!=null&&am(n),t===1)e.tag===0?zk(Zm.bind(null,e)):K0(Zm.bind(null,e)),Vk(function(){!(ne&6)&&Nr()}),n=null;else{switch(b0(r)){case 1:n=tf;break;case 4:n=v0;break;case 16:n=Al;break;case 536870912:n=w0;break;default:n=Al}n=Ww(n,Mw.bind(null,e))}e.callbackPriority=t,e.callbackNode=n}}function Mw(e,t){if(gl=-1,yl=0,ne&6)throw Error(N(327));var n=e.callbackNode;if(ai()&&e.callbackNode!==n)return null;var r=Rl(e,e===Ve?He:0);if(r===0)return null;if(r&30||r&e.expiredLanes||t)t=Gl(e,r);else{t=r;var s=ne;ne|=2;var i=Vw();(Ve!==e||He!==t)&&(_n=null,Ti=Te()+500,os(e,t));do try{uE();break}catch(a){$w(e,a)}while(!0);mf(),Hl.current=i,ne=s,Ne!==null?t=0:(Ve=null,He=0,t=Me)}if(t!==0){if(t===2&&(s=xd(e),s!==0&&(r=s,t=Gd(e,s))),t===1)throw n=zo,os(e,0),rr(e,r),mt(e,Te()),n;if(t===6)rr(e,r);else{if(s=e.current.alternate,!(r&30)&&!lE(s)&&(t=Gl(e,r),t===2&&(i=xd(e),i!==0&&(r=i,t=Gd(e,i))),t===1))throw n=zo,os(e,0),rr(e,r),mt(e,Te()),n;switch(e.finishedWork=s,e.finishedLanes=r,t){case 0:case 1:throw Error(N(345));case 2:zr(e,ut,_n);break;case 3:if(rr(e,r),(r&130023424)===r&&(t=Rf+500-Te(),10<t)){if(Rl(e,0)!==0)break;if(s=e.suspendedLanes,(s&r)!==r){ot(),e.pingedLanes|=e.suspendedLanes&s;break}e.timeoutHandle=Pd(zr.bind(null,e,ut,_n),t);break}zr(e,ut,_n);break;case 4:if(rr(e,r),(r&4194240)===r)break;for(t=e.eventTimes,s=-1;0<r;){var o=31-en(r);i=1<<o,o=t[o],o>s&&(s=o),r&=~i}if(r=s,r=Te()-r,r=(120>r?120:480>r?480:1080>r?1080:1920>r?1920:3e3>r?3e3:4320>r?4320:1960*aE(r/1960))-r,10<r){e.timeoutHandle=Pd(zr.bind(null,e,ut,_n),r);break}zr(e,ut,_n);break;case 5:zr(e,ut,_n);break;default:throw Error(N(329))}}}return mt(e,Te()),e.callbackNode===n?Mw.bind(null,e):null}function Gd(e,t){var n=vo;return e.current.memoizedState.isDehydrated&&(os(e,t).flags|=256),e=Gl(e,t),e!==2&&(t=ut,ut=n,t!==null&&Yd(t)),e}function Yd(e){ut===null?ut=e:ut.push.apply(ut,e)}function lE(e){for(var t=e;;){if(t.flags&16384){var n=t.updateQueue;if(n!==null&&(n=n.stores,n!==null))for(var r=0;r<n.length;r++){var s=n[r],i=s.getSnapshot;s=s.value;try{if(!nn(i(),s))return!1}catch{return!1}}}if(n=t.child,t.subtreeFlags&16384&&n!==null)n.return=t,t=n;else{if(t===e)break;for(;t.sibling===null;){if(t.return===null||t.return===e)return!0;t=t.return}t.sibling.return=t.return,t=t.sibling}}return!0}function rr(e,t){for(t&=~Af,t&=~kc,e.suspendedLanes|=t,e.pingedLanes&=~t,e=e.expirationTimes;0<t;){var n=31-en(t),r=1<<n;e[n]=-1,t&=~r}}function Zm(e){if(ne&6)throw Error(N(327));ai();var t=Rl(e,0);if(!(t&1))return mt(e,Te()),null;var n=Gl(e,t);if(e.tag!==0&&n===2){var r=xd(e);r!==0&&(t=r,n=Gd(e,r))}if(n===1)throw n=zo,os(e,0),rr(e,t),mt(e,Te()),n;if(n===6)throw Error(N(345));return e.finishedWork=e.current.alternate,e.finishedLanes=t,zr(e,ut,_n),mt(e,Te()),null}function jf(e,t){var n=ne;ne|=1;try{return e(t)}finally{ne=n,ne===0&&(Ti=Te()+500,xc&&Nr())}}function ms(e){dr!==null&&dr.tag===0&&!(ne&6)&&ai();var t=ne;ne|=1;var n=Ot.transition,r=ie;try{if(Ot.transition=null,ie=1,e)return e()}finally{ie=r,Ot.transition=n,ne=t,!(ne&6)&&Nr()}}function Nf(){yt=Ys.current,de(Ys)}function os(e,t){e.finishedWork=null,e.finishedLanes=0;var n=e.timeoutHandle;if(n!==-1&&(e.timeoutHandle=-1,$k(n)),Ne!==null)for(n=Ne.return;n!==null;){var r=n;switch(hf(r),r.tag){case 1:r=r.type.childContextTypes,r!=null&&Dl();break;case 3:ki(),de(ft),de(tt),bf();break;case 5:xf(r);break;case 4:ki();break;case 13:de(ve);break;case 19:de(ve);break;case 10:gf(r.type._context);break;case 22:case 23:Nf()}n=n.return}if(Ve=e,Ne=e=xr(e.current,null),He=yt=t,Me=0,zo=null,Af=kc=ps=0,ut=vo=null,Yr!==null){for(t=0;t<Yr.length;t++)if(n=Yr[t],r=n.interleaved,r!==null){n.interleaved=null;var s=r.next,i=n.pending;if(i!==null){var o=i.next;i.next=s,r.next=o}n.pending=r}Yr=null}return e}function $w(e,t){do{var n=Ne;try{if(mf(),fl.current=Wl,zl){for(var r=xe.memoizedState;r!==null;){var s=r.queue;s!==null&&(s.pending=null),r=r.next}zl=!1}if(fs=0,$e=Le=xe=null,go=!1,Fo=0,Pf.current=null,n===null||n.return===null){Me=1,zo=t,Ne=null;break}e:{var i=e,o=n.return,a=n,l=t;if(t=He,a.flags|=32768,l!==null&&typeof l=="object"&&typeof l.then=="function"){var c=l,u=a,d=u.tag;if(!(u.mode&1)&&(d===0||d===11||d===15)){var h=u.alternate;h?(u.updateQueue=h.updateQueue,u.memoizedState=h.memoizedState,u.lanes=h.lanes):(u.updateQueue=null,u.memoizedState=null)}var f=Fm(o);if(f!==null){f.flags&=-257,Um(f,o,a,i,t),f.mode&1&&Vm(i,c,t),t=f,l=c;var w=t.updateQueue;if(w===null){var y=new Set;y.add(l),t.updateQueue=y}else w.add(l);break e}else{if(!(t&1)){Vm(i,c,t),Of();break e}l=Error(N(426))}}else if(me&&a.mode&1){var x=Fm(o);if(x!==null){!(x.flags&65536)&&(x.flags|=256),Um(x,o,a,i,t),ff(Ei(l,a));break e}}i=l=Ei(l,a),Me!==4&&(Me=2),vo===null?vo=[i]:vo.push(i),i=o;do{switch(i.tag){case 3:i.flags|=65536,t&=-t,i.lanes|=t;var m=bw(i,l,t);Om(i,m);break e;case 1:a=l;var g=i.type,v=i.stateNode;if(!(i.flags&128)&&(typeof g.getDerivedStateFromError=="function"||v!==null&&typeof v.componentDidCatch=="function"&&(vr===null||!vr.has(v)))){i.flags|=65536,t&=-t,i.lanes|=t;var S=Sw(i,a,t);Om(i,S);break e}}i=i.return}while(i!==null)}Uw(n)}catch(_){t=_,Ne===n&&n!==null&&(Ne=n=n.return);continue}break}while(!0)}function Vw(){var e=Hl.current;return Hl.current=Wl,e===null?Wl:e}function Of(){(Me===0||Me===3||Me===2)&&(Me=4),Ve===null||!(ps&268435455)&&!(kc&268435455)||rr(Ve,He)}function Gl(e,t){var n=ne;ne|=2;var r=Vw();(Ve!==e||He!==t)&&(_n=null,os(e,t));do try{cE();break}catch(s){$w(e,s)}while(!0);if(mf(),ne=n,Hl.current=r,Ne!==null)throw Error(N(261));return Ve=null,He=0,Me}function cE(){for(;Ne!==null;)Fw(Ne)}function uE(){for(;Ne!==null&&!D_();)Fw(Ne)}function Fw(e){var t=zw(e.alternate,e,yt);e.memoizedProps=e.pendingProps,t===null?Uw(e):Ne=t,Pf.current=null}function Uw(e){var t=e;do{var n=t.alternate;if(e=t.return,t.flags&32768){if(n=rE(n,t),n!==null){n.flags&=32767,Ne=n;return}if(e!==null)e.flags|=32768,e.subtreeFlags=0,e.deletions=null;else{Me=6,Ne=null;return}}else if(n=nE(n,t,yt),n!==null){Ne=n;return}if(t=t.sibling,t!==null){Ne=t;return}Ne=t=e}while(t!==null);Me===0&&(Me=5)}function zr(e,t,n){var r=ie,s=Ot.transition;try{Ot.transition=null,ie=1,dE(e,t,n,r)}finally{Ot.transition=s,ie=r}return null}function dE(e,t,n,r){do ai();while(dr!==null);if(ne&6)throw Error(N(327));n=e.finishedWork;var s=e.finishedLanes;if(n===null)return null;if(e.finishedWork=null,e.finishedLanes=0,n===e.current)throw Error(N(177));e.callbackNode=null,e.callbackPriority=0;var i=n.lanes|n.childLanes;if(H_(e,i),e===Ve&&(Ne=Ve=null,He=0),!(n.subtreeFlags&2064)&&!(n.flags&2064)||Wa||(Wa=!0,Ww(Al,function(){return ai(),null})),i=(n.flags&15990)!==0,n.subtreeFlags&15990||i){i=Ot.transition,Ot.transition=null;var o=ie;ie=1;var a=ne;ne|=4,Pf.current=null,iE(e,n),Dw(n,e),jk(Td),jl=!!Ed,Td=Ed=null,e.current=n,oE(n),L_(),ne=a,ie=o,Ot.transition=i}else e.current=n;if(Wa&&(Wa=!1,dr=e,ql=s),i=e.pendingLanes,i===0&&(vr=null),V_(n.stateNode),mt(e,Te()),t!==null)for(r=e.onRecoverableError,n=0;n<t.length;n++)s=t[n],r(s.value,{componentStack:s.stack,digest:s.digest});if(Kl)throw Kl=!1,e=Kd,Kd=null,e;return ql&1&&e.tag!==0&&ai(),i=e.pendingLanes,i&1?e===qd?wo++:(wo=0,qd=e):wo=0,Nr(),null}function ai(){if(dr!==null){var e=b0(ql),t=Ot.transition,n=ie;try{if(Ot.transition=null,ie=16>e?16:e,dr===null)var r=!1;else{if(e=dr,dr=null,ql=0,ne&6)throw Error(N(331));var s=ne;for(ne|=4,$=e.current;$!==null;){var i=$,o=i.child;if($.flags&16){var a=i.deletions;if(a!==null){for(var l=0;l<a.length;l++){var c=a[l];for($=c;$!==null;){var u=$;switch(u.tag){case 0:case 11:case 15:yo(8,u,i)}var d=u.child;if(d!==null)d.return=u,$=d;else for(;$!==null;){u=$;var h=u.sibling,f=u.return;if(Nw(u),u===c){$=null;break}if(h!==null){h.return=f,$=h;break}$=f}}}var w=i.alternate;if(w!==null){var y=w.child;if(y!==null){w.child=null;do{var x=y.sibling;y.sibling=null,y=x}while(y!==null)}}$=i}}if(i.subtreeFlags&2064&&o!==null)o.return=i,$=o;else e:for(;$!==null;){if(i=$,i.flags&2048)switch(i.tag){case 0:case 11:case 15:yo(9,i,i.return)}var m=i.sibling;if(m!==null){m.return=i.return,$=m;break e}$=i.return}}var g=e.current;for($=g;$!==null;){o=$;var v=o.child;if(o.subtreeFlags&2064&&v!==null)v.return=o,$=v;else e:for(o=g;$!==null;){if(a=$,a.flags&2048)try{switch(a.tag){case 0:case 11:case 15:_c(9,a)}}catch(_){Ee(a,a.return,_)}if(a===o){$=null;break e}var S=a.sibling;if(S!==null){S.return=a.return,$=S;break e}$=a.return}}if(ne=s,Nr(),pn&&typeof pn.onPostCommitFiberRoot=="function")try{pn.onPostCommitFiberRoot(mc,e)}catch{}r=!0}return r}finally{ie=n,Ot.transition=t}}return!1}function eg(e,t,n){t=Ei(n,t),t=bw(e,t,1),e=yr(e,t,1),t=ot(),e!==null&&(ua(e,1,t),mt(e,t))}function Ee(e,t,n){if(e.tag===3)eg(e,e,n);else for(;t!==null;){if(t.tag===3){eg(t,e,n);break}else if(t.tag===1){var r=t.stateNode;if(typeof t.type.getDerivedStateFromError=="function"||typeof r.componentDidCatch=="function"&&(vr===null||!vr.has(r))){e=Ei(n,e),e=Sw(t,e,1),t=yr(t,e,1),e=ot(),t!==null&&(ua(t,1,e),mt(t,e));break}}t=t.return}}function hE(e,t,n){var r=e.pingCache;r!==null&&r.delete(t),t=ot(),e.pingedLanes|=e.suspendedLanes&n,Ve===e&&(He&n)===n&&(Me===4||Me===3&&(He&130023424)===He&&500>Te()-Rf?os(e,0):Af|=n),mt(e,t)}function Bw(e,t){t===0&&(e.mode&1?(t=Ia,Ia<<=1,!(Ia&130023424)&&(Ia=4194304)):t=1);var n=ot();e=Nn(e,t),e!==null&&(ua(e,t,n),mt(e,n))}function fE(e){var t=e.memoizedState,n=0;t!==null&&(n=t.retryLane),Bw(e,n)}function pE(e,t){var n=0;switch(e.tag){case 13:var r=e.stateNode,s=e.memoizedState;s!==null&&(n=s.retryLane);break;case 19:r=e.stateNode;break;default:throw Error(N(314))}r!==null&&r.delete(t),Bw(e,n)}var zw;zw=function(e,t,n){if(e!==null)if(e.memoizedProps!==t.pendingProps||ft.current)dt=!0;else{if(!(e.lanes&n)&&!(t.flags&128))return dt=!1,tE(e,t,n);dt=!!(e.flags&131072)}else dt=!1,me&&t.flags&1048576&&q0(t,$l,t.index);switch(t.lanes=0,t.tag){case 2:var r=t.type;ml(e,t),e=t.pendingProps;var s=bi(t,tt.current);oi(t,n),s=_f(null,t,r,e,s,n);var i=kf();return t.flags|=1,typeof s=="object"&&s!==null&&typeof s.render=="function"&&s.$$typeof===void 0?(t.tag=1,t.memoizedState=null,t.updateQueue=null,pt(r)?(i=!0,Ll(t)):i=!1,t.memoizedState=s.state!==null&&s.state!==void 0?s.state:null,vf(t),s.updater=Sc,t.stateNode=s,s._reactInternals=t,Dd(t,r,e,n),t=$d(null,t,r,!0,i,n)):(t.tag=0,me&&i&&df(t),rt(null,t,s,n),t=t.child),t;case 16:r=t.elementType;e:{switch(ml(e,t),e=t.pendingProps,s=r._init,r=s(r._payload),t.type=r,s=t.tag=gE(r),e=Kt(r,e),s){case 0:t=Md(null,t,r,e,n);break e;case 1:t=Wm(null,t,r,e,n);break e;case 11:t=Bm(null,t,r,e,n);break e;case 14:t=zm(null,t,r,Kt(r.type,e),n);break e}throw Error(N(306,r,""))}return t;case 0:return r=t.type,s=t.pendingProps,s=t.elementType===r?s:Kt(r,
vendor: 4,256 bytes, line 40
40s),Md(e,t,r,s,n);case 1:return r=t.type,s=t.pendingProps,s=t.elementType===r?s:Kt(r,s),Wm(e,t,r,s,n);case 3:e:{if(Tw(t),e===null)throw Error(N(387));r=t.pendingProps,i=t.memoizedState,s=i.element,Z0(e,t),Ul(t,r,null,n);var o=t.memoizedState;if(r=o.element,i.isDehydrated)if(i={element:r,isDehydrated:!1,cache:o.cache,pendingSuspenseBoundaries:o.pendingSuspenseBoundaries,transitions:o.transitions},t.updateQueue.baseState=i,t.memoizedState=i,t.flags&256){s=Ei(Error(N(423)),t),t=Hm(e,t,r,n,s);break e}else if(r!==s){s=Ei(Error(N(424)),t),t=Hm(e,t,r,n,s);break e}else for(wt=gr(t.stateNode.containerInfo.firstChild),xt=t,me=!0,Xt=null,n=J0(t,null,r,n),t.child=n;n;)n.flags=n.flags&-3|4096,n=n.sibling;else{if(Si(),r===s){t=On(e,t,n);break e}rt(e,t,r,n)}t=t.child}return t;case 5:return ew(t),e===null&&Nd(t),r=t.type,s=t.pendingProps,i=e!==null?e.memoizedProps:null,o=s.children,Cd(r,s)?o=null:i!==null&&Cd(r,i)&&(t.flags|=32),Ew(e,t),rt(e,t,o,n),t.child;case 6:return e===null&&Nd(t),null;case 13:return Cw(e,t,n);case 4:return wf(t,t.stateNode.containerInfo),r=t.pendingProps,e===null?t.child=_i(t,null,r,n):rt(e,t,r,n),t.child;case 11:return r=t.type,s=t.pendingProps,s=t.elementType===r?s:Kt(r,s),Bm(e,t,r,s,n);case 7:return rt(e,t,t.pendingProps,n),t.child;case 8:return rt(e,t,t.pendingProps.children,n),t.child;case 12:return rt(e,t,t.pendingProps.children,n),t.child;case 10:e:{if(r=t.type._context,s=t.pendingProps,i=t.memoizedProps,o=s.value,le(Vl,r._currentValue),r._currentValue=o,i!==null)if(nn(i.value,o)){if(i.children===s.children&&!ft.current){t=On(e,t,n);break e}}else for(i=t.child,i!==null&&(i.return=t);i!==null;){var a=i.dependencies;if(a!==null){o=i.child;for(var l=a.firstContext;l!==null;){if(l.context===r){if(i.tag===1){l=An(-1,n&-n),l.tag=2;var c=i.updateQueue;if(c!==null){c=c.shared;var u=c.pending;u===null?l.next=l:(l.next=u.next,u.next=l),c.pending=l}}i.lanes|=n,l=i.alternate,l!==null&&(l.lanes|=n),Od(i.return,n,t),a.lanes|=n;break}l=l.next}}else if(i.tag===10)o=i.type===t.type?null:i.child;else if(i.tag===18){if(o=i.return,o===null)throw Error(N(341));o.lanes|=n,a=o.alternate,a!==null&&(a.lanes|=n),Od(o,n,t),o=i.sibling}else o=i.child;if(o!==null)o.return=i;else for(o=i;o!==null;){if(o===t){o=null;break}if(i=o.sibling,i!==null){i.return=o.return,o=i;break}o=o.return}i=o}rt(e,t,s.children,n),t=t.child}return t;case 9:return s=t.type,r=t.pendingProps.children,oi(t,n),s=Dt(s),r=r(s),t.flags|=1,rt(e,t,r,n),t.child;case 14:return r=t.type,s=Kt(r,t.pendingProps),s=Kt(r.type,s),zm(e,t,r,s,n);case 15:return _w(e,t,t.type,t.pendingProps,n);case 17:return r=t.type,s=t.pendingProps,s=t.elementType===r?s:Kt(r,s),ml(e,t),t.tag=1,pt(r)?(e=!0,Ll(t)):e=!1,oi(t,n),xw(t,r,s),Dd(t,r,s,n),$d(null,t,r,!0,e,n);case 19:return Pw(e,t,n);case 22:return kw(e,t,n)}throw Error(N(156,t.tag))};function Ww(e,t){return y0(e,t)}function mE(e,t,n,r){this.tag=e,this.key=n,this.sibling=this.child=this.return=this.stateNode=this.type=this.elementType=null,this.index=0,this.ref=null,this.pendingProps=t,this.dependencies=this.memoizedState=this.updateQueue=this.memoizedProps=null,this.mode=r,this.subtreeFlags=this.flags=0,this.deletions=null,this.childLanes=this.lanes=0,this.alternate=null}function jt(e,t,n,r){return new mE(e,t,n,r)}function If(e){return e=e.prototype,!(!e||!e.isReactComponent)}function gE(e){if(typeof e=="function")return If(e)?1:0;if(e!=null){if(e=e.$$typeof,e===Xh)return 11;if(e===Zh)return 14}return 2}function xr(e,t){var n=e.alternate;return n===null?(n=jt(e.tag,t,e.key,e.mode),n.elementType=e.elementType,n.type=e.type,n.stateNode=e.stateNode,n.alternate=e,e.alternate=n):(n.pendingProps=t,n.type=e.type,n.flags=0,n.subtreeFlags=0,n.deletions=null),n.flags=e.flags&14680064,n.childLanes=e.childLanes,n.lanes=e.lanes,n.child=e.child,n.memoizedProps=e.memoizedProps,n.memoizedState=e.memoizedState,n.updateQueue=e.updateQueue,t=e.dependencies,n.dependencies=t===null?null:{lanes:t.lanes,firstContext:t.firstContext},n.sibling=e.sibling,n.index=e.index,n.ref=e.ref,n}function vl(e,t,n,r,s,i){var o=2;if(r=e,typeof e=="function")If(e)&&(o=1);else if(typeof e=="string")o=5;else e:switch(e){case Vs:return as(n.children,s,i,t);case Jh:o=8,s|=8;break;case id:return e=jt(12,n,t,s|2),e.elementType=id,e.lanes=i,e;
vendor: 8,374 bytes, line 40
40case od:return e=jt(13,n,t,s),e.elementType=od,e.lanes=i,e;case ad:return e=jt(19,n,t,s),e.elementType=ad,e.lanes=i,e;case e0:return Ec(n,s,i,t);default:if(typeof e=="object"&&e!==null)switch(e.$$typeof){case Xv:o=10;break e;case Zv:o=9;break e;case Xh:o=11;break e;case Zh:o=14;break e;case Zn:o=16,r=null;break e}throw Error(N(130,e==null?e:typeof e,""))}return t=jt(o,n,t,s),t.elementType=e,t.type=r,t.lanes=i,t}function as(e,t,n,r){return e=jt(7,e,r,t),e.lanes=n,e}function Ec(e,t,n,r){return e=jt(22,e,r,t),e.elementType=e0,e.lanes=n,e.stateNode={isHidden:!1},e}function Eu(e,t,n){return e=jt(6,e,null,t),e.lanes=n,e}function Tu(e,t,n){return t=jt(4,e.children!==null?e.children:[],e.key,t),t.lanes=n,t.stateNode={containerInfo:e.containerInfo,pendingChildren:null,implementation:e.implementation},t}function yE(e,t,n,r,s){this.tag=t,this.containerInfo=e,this.finishedWork=this.pingCache=this.current=this.pendingChildren=null,this.timeoutHandle=-1,this.callbackNode=this.pendingContext=this.context=null,this.callbackPriority=0,this.eventTimes=ou(0),this.expirationTimes=ou(-1),this.entangledLanes=this.finishedLanes=this.mutableReadLanes=this.expiredLanes=this.pingedLanes=this.suspendedLanes=this.pendingLanes=0,this.entanglements=ou(0),this.identifierPrefix=r,this.onRecoverableError=s,this.mutableSourceEagerHydrationData=null}function Df(e,t,n,r,s,i,o,a,l){return e=new yE(e,t,n,a,l),t===1?(t=1,i===!0&&(t|=8)):t=0,i=jt(3,null,null,t),e.current=i,i.stateNode=e,i.memoizedState={element:r,isDehydrated:n,cache:null,transitions:null,pendingSuspenseBoundaries:null},vf(i),e}function vE(e,t,n){var r=3<arguments.length&&arguments[3]!==void 0?arguments[3]:null;return{$$typeof:$s,key:r==null?null:""+r,children:e,containerInfo:t,implementation:n}}function Hw(e){if(!e)return _r;e=e._reactInternals;e:{if(vs(e)!==e||e.tag!==1)throw Error(N(170));var t=e;do{switch(t.tag){case 3:t=t.stateNode.context;break e;case 1:if(pt(t.type)){t=t.stateNode.__reactInternalMemoizedMergedChildContext;break e}}t=t.return}while(t!==null);throw Error(N(171))}if(e.tag===1){var n=e.type;if(pt(n))return H0(e,n,t)}return t}function Kw(e,t,n,r,s,i,o,a,l){return e=Df(n,r,!0,e,s,i,o,a,l),e.context=Hw(null),n=e.current,r=ot(),s=wr(n),i=An(r,s),i.callback=t??null,yr(n,i,s),e.current.lanes=s,ua(e,s,r),mt(e,r),e}function Tc(e,t,n,r){var s=t.current,i=ot(),o=wr(s);return n=Hw(n),t.context===null?t.context=n:t.pendingContext=n,t=An(i,o),t.payload={element:e},r=r===void 0?null:r,r!==null&&(t.callback=r),e=yr(s,t,o),e!==null&&(tn(e,s,o,i),hl(e,s,o)),o}function Yl(e){if(e=e.current,!e.child)return null;switch(e.child.tag){case 5:return e.child.stateNode;default:return e.child.stateNode}}function tg(e,t){if(e=e.memoizedState,e!==null&&e.dehydrated!==null){var n=e.retryLane;e.retryLane=n!==0&&n<t?n:t}}function Lf(e,t){tg(e,t),(e=e.alternate)&&tg(e,t)}function wE(){return null}var qw=typeof reportError=="function"?reportError:function(e){console.error(e)};function Mf(e){this._internalRoot=e}Cc.prototype.render=Mf.prototype.render=function(e){var t=this._internalRoot;if(t===null)throw Error(N(409));Tc(e,t,null,null)};Cc.prototype.unmount=Mf.prototype.unmount=function(){var e=this._internalRoot;if(e!==null){this._internalRoot=null;var t=e.containerInfo;ms(function(){Tc(null,e,null,null)}),t[jn]=null}};function Cc(e){this._internalRoot=e}Cc.prototype.unstable_scheduleHydration=function(e){if(e){var t=k0();e={blockedOn:null,target:e,priority:t};for(var n=0;n<nr.length&&t!==0&&t<nr[n].priority;n++);nr.splice(n,0,e),n===0&&T0(e)}};function $f(e){return!(!e||e.nodeType!==1&&e.nodeType!==9&&e.nodeType!==11)}function Pc(e){return!(!e||e.nodeType!==1&&e.nodeType!==9&&e.nodeType!==11&&(e.nodeType!==8||e.nodeValue!==" react-mount-point-unstable "))}function ng(){}function xE(e,t,n,r,s){if(s){if(typeof r=="function"){var i=r;r=function(){var c=Yl(o);i.call(c)}}var o=Kw(t,r,e,0,null,!1,!1,"",ng);return e._reactRootContainer=o,e[jn]=o.current,Do(e.nodeType===8?e.parentNode:e),ms(),o}for(;s=e.lastChild;)e.removeChild(s);if(typeof r=="function"){var a=r;r=function(){var c=Yl(l);a.call(c)}}var l=Df(e,0,!1,null,null,!1,!1,"",ng);return e._reactRootContainer=l,e[jn]=l.current,Do(e.nodeType===8?e.parentNode:e),ms(function(){Tc(t,l,n,r)}),l}function Ac(e,t,n,r,s){var i=n._reactRootContainer;if(i){var o=i;if(typeof s=="function"){var a=s;s=function(){var l=Yl(o);a.call(l)}}Tc(t,o,e,s)}else o=xE(n,t,e,s,r);return Yl(o)}S0=function(e){switch(e.tag){case 3:var t=e.stateNode;if(t.current.memoizedState.isDehydrated){var n=oo(t.pendingLanes);n!==0&&(nf(t,n|1),mt(t,Te()),!(ne&6)&&(Ti=Te()+500,Nr()))}break;case 13:ms(function(){var r=Nn(e,1);if(r!==null){var s=ot();tn(r,e,1,s)}}),Lf(e,1)}};rf=function(e){if(e.tag===13){var t=Nn(e,134217728);if(t!==null){var n=ot();tn(t,e,134217728,n)}Lf(e,134217728)}};_0=function(e){if(e.tag===13){var t=wr(e),n=Nn(e,t);if(n!==null){var r=ot();tn(n,e,t,r)}Lf(e,t)}};k0=function(){return ie};E0=function(e,t){var n=ie;try{return ie=e,t()}finally{ie=n}};yd=function(e,t,n){switch(t){case"input":if(ud(e,n),t=n.name,n.type==="radio"&&t!=null){for(n=e;n.parentNode;)n=n.parentNode;for(n=n.querySelectorAll("input[name="+JSON.stringify(""+t)+'][type="radio"]'),t=0;t<n.length;t++){var r=n[t];if(r!==e&&r.form===e.form){var s=wc(r);if(!s)throw Error(N(90));n0(r),ud(r,s)}}}break;case"textarea":s0(e,n);break;case"select":t=n.value,t!=null&&ni(e,!!n.multiple,t,!1)}};d0=jf;h0=ms;var bE={usingClientEntryPoint:!1,Events:[ha,zs,wc,c0,u0,jf]},Xi={findFiberByHostInstance:Gr,bundleType:0,version:"18.3.1",rendererPackageName:"react-dom"},SE={bundleType:Xi.bundleType,version:Xi.version,rendererPackageName:Xi.rendererPackageName,rendererConfig:Xi.rendererConfig,overrideHookState:null,overrideHookStateDeletePath:null,overrideHookStateRenamePath:null,overrideProps:null,overridePropsDeletePath:null,overridePropsRenamePath:null,setErrorHandler:null,setSuspenseHandler:null,scheduleUpdate:null,currentDispatcherRef:Vn.ReactCurrentDispatcher,findHostInstanceByFiber:function(e){return e=m0(e),e===null?null:e.stateNode},findFiberByHostInstance:Xi.findFiberByHostInstance||wE,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 Ha=__REACT_DEVTOOLS_GLOBAL_HOOK__;if(!Ha.isDisabled&&Ha.supportsFiber)try{mc=Ha.inject(SE),pn=Ha}catch{}}kt.__SECRET_INTERNALS_DO_NOT_USE_OR_YOU_WILL_BE_FIRED=bE;kt.createPortal=function(e,t){var n=2<arguments.length&&arguments[2]!==void 0?arguments[2]:null;if(!$f(t))throw Error(N(200));return vE(e,t,null,n)};kt.createRoot=function(e,t){if(!$f(e))throw Error(N(299));var n=!1,r="",s=qw;return t!=null&&(t.unstable_strictMode===!0&&(n=!0),t.identifierPrefix!==void 0&&(r=t.identifierPrefix),t.onRecoverableError!==void 0&&(s=t.onRecoverableError)),t=Df(e,1,!1,null,null,n,!1,r,s),e[jn]=t.current,Do(e.nodeType===8?e.parentNode:e),new Mf(t)};kt.findDOMNode=function(e){if(e==null)return null;if(e.nodeType===1)return e;var t=e._reactInternals;if(t===void 0)throw typeof e.render=="function"?Error(N(188)):(e=Object.keys(e).join(","),Error(N(268,e)));return e=m0(t),e=e===null?null:e.stateNode,e};kt.flushSync=function(e){return ms(e)};kt.hydrate=function(e,t,n){if(!Pc(t))throw Error(N(200));return Ac(null,e,t,!0,n)};kt.hydrateRoot=function(e,t,n){if(!$f(e))throw Error(N(405));var r=n!=null&&n.hydratedSources||null,s=!1,i="",o=qw;if(n!=null&&(n.unstable_strictMode===!0&&(s=!0),n.identifierPrefix!==void 0&&(i=n.identifierPrefix),n.onRecoverableError!==void 0&&(o=n.onRecoverableError)),t=Kw(t,null,e,1,n??null,s,!1,i,o),e[jn]=t.current,Do(e),r)for(e=0;e<r.length;e++)n=r[e],s=n._getVersion,s=s(n._source),t.mutableSourceEagerHydrationData==null?t.mutableSourceEagerHydrationData=[n,s]:t.mutableSourceEagerHydrationData.push(n,s);return new Cc(t)};kt.render=function(e,t,n){if(!Pc(t))throw Error(N(200));return Ac(null,e,t,!1,n)};kt.unmountComponentAtNode=function(e){if(!Pc(e))throw Error(N(40));return e._reactRootContainer?(ms(function(){Ac(null,null,e,!1,function(){e._reactRootContainer=null,e[jn]=null})}),!0):!1};kt.unstable_batchedUpdates=jf;kt.unstable_renderSubtreeIntoContainer=function(e,t,n,r){if(!Pc(n))throw Error(N(200));if(e==null||e._reactInternals===void 0)throw Error(N(38));return Ac(e,t,n,!1,r)};kt.version="18.3.1-next-f1338f8080-20240426";
40function Gw(){if(!(typeof __REACT_DEVTOOLS_GLOBAL_HOOK__>"u"||typeof __REACT_DEVTOOLS_GLOBAL_HOOK__.checkDCE!="function"))try{__REACT_DEVTOOLS_GLOBAL_HOOK__.checkDCE(Gw)}catch(e){console.error(e)}}Gw(),Gv.exports=kt;var pa=Gv.exports;const Yw=Dv(pa);var Qw,rg=pa;Qw=rg.createRoot,rg.hydrateRoot;const _E=1,kE=1e6;let Cu=0;function EE(){return Cu=(Cu+1)%Number.MAX_SAFE_INTEGER,Cu.toString()}const Pu=new Map,sg=e=>{if(Pu.has(e))return;const t=setTimeout(()=>{Pu.delete(e),xo({type:"REMOVE_TOAST",toastId:e})},kE);Pu.set(e,t)},TE=(e,t)=>{switch(t.type){case"ADD_TOAST":return{...e,toasts:[t.toast,...e.toasts].slice(0,_E)};case"UPDATE_TOAST":return{...e,toasts:e.toasts.map(n=>n.id===t.toast.id?{...n,...t.toast}:n)};case"DISMISS_TOAST":{const{toastId:n}=t;return n?sg(n):e.toasts.forEach(r=>{sg(r.id)}),{...e,toasts:e.toasts.map(r=>r.id===n||n===void 0?{...r,open:!1}:r)}}case"REMOVE_TOAST":return t.toastId===void 0?{...e,toasts:[]}:{...e,toasts:e.toasts.filter(n=>n.id!==t.toastId)}}},wl=[];let xl={toasts:[]};function xo(e){xl=TE(xl,e),wl.forEach(t=>{t(xl)})}function CE({...e}){const t=EE(),n=s=>xo({type:"UPDATE_TOAST",toast:{...s,id:t}}),r=()=>xo({type:"DISMISS_TOAST",toastId:t});return xo({type:"ADD_TOAST",toast:{...e,id:t,open:!0,onOpenChange:s=>{s||r()}}}),{id:t,dismiss:r,update:n}}function Vf(){const[e,t]=b.useState(xl);return b.useEffect(()=>(wl.push(t),()=>{const n=wl.indexOf(t);n>-1&&wl.splice(n,1)}),[e]),{...e,toast:CE,dismiss:n=>xo({type:"DISMISS_TOAST",toastId:n})}}function Ce(e,t,{checkForDefaultPrevented:n=!0}={}){return function(s){if(e==null||e(s),n===!1||!s.defaultPrevented)return t==null?void 0:t(s)}}function ig(e,t){if(typeof e=="function")return e(t);e!=null&&(e.current=t)}function Jw(...e){return t=>{let n=!1;const r=e.map(s=>{const i=ig(s,t);return!n&&typeof i=="function"&&(n=!0),i});if(n)return()=>{for(let s=0;s<r.length;s++){const i=r[s];typeof i=="function"?i():ig(e[s],null)}}}}function _t(...e){return b.useCallback(Jw(...e),e)}function ma(e,t=[]){let n=[];function r(i,o){const a=b.createContext(o),l=n.length;n=[...n,o];const c=d=>{var m;const{scope:h,children:f,...w}=d,y=((m=h==null?void 0:h[e])==null?void 0:m[l])||a,x=b.useMemo(()=>w,Object.values(w));return p.jsx(y.Provider,{value:x,children:f})};c.displayName=i+"Provider";function u(d,h){var y;const f=((y=h==null?void 0:h[e])==null?void 0:y[l])||a,w=b.useContext(f);if(w)return w;if(o!==void 0)return o;throw new Error(`\`${d}\` must be used within \`${i}\``)}return[c,u]}const s=()=>{const i=n.map(o=>b.createContext(o));return function(a){const l=(a==null?void 0:a[e])||i;return b.useMemo(()=>({[`__scope${e}`]:{...a,[e]:l}}),[a,l])}};return s.scopeName=e,[r,PE(s,...t)]}function PE(...e){const t=e[0];if(e.length===1)return t;const n=()=>{const r=e.map(s=>({useScope:s(),scopeName:s.scopeName}));return function(i){const o=r.reduce((a,{useScope:l,scopeName:c})=>{const d=l(i)[`__scope${c}`];return{...a,...d}},{});return b.useMemo(()=>({[`__scope${t.scopeName}`]:o}),[o])}};return n.scopeName=t.scopeName,n}function Ql(e){const t=RE(e),n=b.forwardRef((r,s)=>{const{children:i,...o}=r,a=b.Children.toArray(i),l=a.find(NE);if(l){const c=l.props.children,u=a.map(d=>d===l?b.Children.count(c)>1?b.Children.only(null):b.isValidElement(c)?c.props.children:null:d);return p.jsx(t,{...o,ref:s,children:b.isValidElement(c)?b.cloneElement(c,void 0,u):null})}return p.jsx(t,{...o,ref:s,children:i})});return n.displayName=`${e}.Slot`,n}var AE=Ql("Slot");function RE(e){const t=b.forwardRef((n,r)=>{const{children:s,...i}=n;if(b.isValidElement(s)){const o=IE(s),a=OE(i,s.props);return s.type!==b.Fragment&&(a.ref=r?Jw(r,o):o),b.cloneElement(s,a)}return b.Children.count(s)>1?b.Children.only(null):null});return t.displayName=`${e}.SlotClone`,t}var Xw=Symbol("radix.slottable");function jE(e){const t=({children:n})=>p.jsx(p.Fragment,{children:n});return t.displayName=`${e}.Slottable`,t.__radixId=Xw,t}function NE(e){return b.isValidElement(e)&&typeof e.type=="function"&&"__radixId"in e.type&&e.type.__radixId===Xw}function OE(e,t){const n={...t};for(const r in t){const s=e[r],i=t[r];/^on[A-Z]/.test(r)?s&&i?n[r]=(...a)=>{const l=i(...a);return s(...a),l}:s&&(n[r]=s):r==="style"?n[r]={...s,...i}
vendor: 9,308 bytes, line 40
40:r==="className"&&(n[r]=[s,i].filter(Boolean).join(" "))}return{...e,...n}}function IE(e){var r,s;let t=(r=Object.getOwnPropertyDescriptor(e.props,"ref"))==null?void 0:r.get,n=t&&"isReactWarning"in t&&t.isReactWarning;return n?e.ref:(t=(s=Object.getOwnPropertyDescriptor(e,"ref"))==null?void 0:s.get,n=t&&"isReactWarning"in t&&t.isReactWarning,n?e.props.ref:e.props.ref||e.ref)}function DE(e){const t=e+"CollectionProvider",[n,r]=ma(t),[s,i]=n(t,{collectionRef:{current:null},itemMap:new Map}),o=y=>{const{scope:x,children:m}=y,g=I.useRef(null),v=I.useRef(new Map).current;return p.jsx(s,{scope:x,itemMap:v,collectionRef:g,children:m})};o.displayName=t;const a=e+"CollectionSlot",l=Ql(a),c=I.forwardRef((y,x)=>{const{scope:m,children:g}=y,v=i(a,m),S=_t(x,v.collectionRef);return p.jsx(l,{ref:S,children:g})});c.displayName=a;const u=e+"CollectionItemSlot",d="data-radix-collection-item",h=Ql(u),f=I.forwardRef((y,x)=>{const{scope:m,children:g,...v}=y,S=I.useRef(null),_=_t(x,S),k=i(u,m);return I.useEffect(()=>(k.itemMap.set(S,{ref:S,...v}),()=>void k.itemMap.delete(S))),p.jsx(h,{[d]:"",ref:_,children:g})});f.displayName=u;function w(y){const x=i(e+"CollectionConsumer",y);return I.useCallback(()=>{const g=x.collectionRef.current;if(!g)return[];const v=Array.from(g.querySelectorAll(`[${d}]`));return Array.from(x.itemMap.values()).sort((k,E)=>v.indexOf(k.ref.current)-v.indexOf(E.ref.current))},[x.collectionRef,x.itemMap])}return[{Provider:o,Slot:c,ItemSlot:f},w,r]}var LE=["a","button","div","form","h2","h3","img","input","label","li","nav","ol","p","select","span","svg","ul"],qe=LE.reduce((e,t)=>{const n=Ql(`Primitive.${t}`),r=b.forwardRef((s,i)=>{const{asChild:o,...a}=s,l=o?n:t;return typeof window<"u"&&(window[Symbol.for("radix-ui")]=!0),p.jsx(l,{...a,ref:i})});return r.displayName=`Primitive.${t}`,{...e,[t]:r}},{});function Zw(e,t){e&&pa.flushSync(()=>e.dispatchEvent(t))}function kr(e){const t=b.useRef(e);return b.useEffect(()=>{t.current=e}),b.useMemo(()=>(...n)=>{var r;return(r=t.current)==null?void 0:r.call(t,...n)},[])}function ME(e,t=globalThis==null?void 0:globalThis.document){const n=kr(e);b.useEffect(()=>{const r=s=>{s.key==="Escape"&&n(s)};return t.addEventListener("keydown",r,{capture:!0}),()=>t.removeEventListener("keydown",r,{capture:!0})},[n,t])}var $E="DismissableLayer",Qd="dismissableLayer.update",VE="dismissableLayer.pointerDownOutside",FE="dismissableLayer.focusOutside",og,ex=b.createContext({layers:new Set,layersWithOutsidePointerEventsDisabled:new Set,branches:new Set}),Ff=b.forwardRef((e,t)=>{const{disableOutsidePointerEvents:n=!1,onEscapeKeyDown:r,onPointerDownOutside:s,onFocusOutside:i,onInteractOutside:o,onDismiss:a,...l}=e,c=b.useContext(ex),[u,d]=b.useState(null),h=(u==null?void 0:u.ownerDocument)??(globalThis==null?void 0:globalThis.document),[,f]=b.useState({}),w=_t(t,E=>d(E)),y=Array.from(c.layers),[x]=[...c.layersWithOutsidePointerEventsDisabled].slice(-1),m=y.indexOf(x),g=u?y.indexOf(u):-1,v=c.layersWithOutsidePointerEventsDisabled.size>0,S=g>=m,_=BE(E=>{const T=E.target,j=[...c.branches].some(O=>O.contains(T));!S||j||(s==null||s(E),o==null||o(E),E.defaultPrevented||a==null||a())},h),k=zE(E=>{const T=E.target;[...c.branches].some(O=>O.contains(T))||(i==null||i(E),o==null||o(E),E.defaultPrevented||a==null||a())},h);return ME(E=>{g===c.layers.size-1&&(r==null||r(E),!E.defaultPrevented&&a&&(E.preventDefault(),a()))},h),b.useEffect(()=>{if(u)return n&&(c.layersWithOutsidePointerEventsDisabled.size===0&&(og=h.body.style.pointerEvents,h.body.style.pointerEvents="none"),c.layersWithOutsidePointerEventsDisabled.add(u)),c.layers.add(u),ag(),()=>{n&&c.layersWithOutsidePointerEventsDisabled.size===1&&(h.body.style.pointerEvents=og)}},[u,h,n,c]),b.useEffect(()=>()=>{u&&(c.layers.delete(u),c.layersWithOutsidePointerEventsDisabled.delete(u),ag())},[u,c]),b.useEffect(()=>{const E=()=>f({});return document.addEventListener(Qd,E),()=>document.removeEventListener(Qd,E)},[]),p.jsx(qe.div,{...l,ref:w,style:{pointerEvents:v?S?"auto":"none":void 0,...e.style},onFocusCapture:Ce(e.onFocusCapture,k.onFocusCapture),onBlurCapture:Ce(e.onBlurCapture,k.onBlurCapture),onPointerDownCapture:Ce(e.onPointerDownCapture,_.onPointerDownCapture)})});Ff.displayName=$E;var UE="DismissableLayerBranch",tx=b.forwardRef((e,t)=>{const n=b.useContext(ex),r=b.useRef(null),s=_t(t,r);return b.useEffect(()=>{const i=r.current;if(i)return n.branches.add(i),()=>{n.branches.delete(i)}},[n.branches]),p.jsx(qe.div,{...e,ref:s})});tx.displayName=UE;function BE(e,t=globalThis==null?void 0:globalThis.document){const n=kr(e),r=b.useRef(!1),s=b.useRef(()=>{});return b.useEffect(()=>{const i=a=>{if(a.target&&!r.current){let l=function(){nx(VE,n,c,{discrete:!0})};const c={originalEvent:a};a.pointerType==="touch"?(t.removeEventListener("click",s.current),s.current=l,t.addEventListener("click",s.current,{once:!0})):l()}else t.removeEventListener("click",s.current);r.current=!1},o=window.setTimeout(()=>{t.addEventListener("pointerdown",i)},0);return()=>{window.clearTimeout(o),t.removeEventListener("pointerdown",i),t.removeEventListener("click",s.current)}},[t,n]),{onPointerDownCapture:()=>r.current=!0}}function zE(e,t=globalThis==null?void 0:globalThis.document){const n=kr(e),r=b.useRef(!1);return b.useEffect(()=>{const s=i=>{i.target&&!r.current&&nx(FE,n,{originalEvent:i},{discrete:!1})};return t.addEventListener("focusin",s),()=>t.removeEventListener("focusin",s)},[t,n]),{onFocusCapture:()=>r.current=!0,onBlurCapture:()=>r.current=!1}}function ag(){const e=new CustomEvent(Qd);document.dispatchEvent(e)}function nx(e,t,n,{discrete:r}){const s=n.originalEvent.target,i=new CustomEvent(e,{bubbles:!1,cancelable:!0,detail:n});t&&s.addEventListener(e,t,{once:!0}),r?Zw(s,i):s.dispatchEvent(i)}var WE=Ff,HE=tx,Er=globalThis!=null&&globalThis.document?b.useLayoutEffect:()=>{},KE="Portal",rx=b.forwardRef((e,t)=>{var a;const{container:n,...r}=e,[s,i]=b.useState(!1);Er(()=>i(!0),[]);const o=n||s&&((a=globalThis==null?void 0:globalThis.document)==null?void 0:a.body);return o?Yw.createPortal(p.jsx(qe.div,{...r,ref:t}),o):null});rx.displayName=KE;function qE(e,t){return b.useReducer((n,r)=>t[n][r]??n,e)}var Rc=e=>{const{present:t,children:n}=e,r=GE(t),s=typeof n=="function"?n({present:r.isPresent}):b.Children.only(n),i=_t(r.ref,YE(s));return typeof n=="function"||r.isPresent?b.cloneElement(s,{ref:i}):null};Rc.displayName="Presence";function GE(e){const[t,n]=b.useState(),r=b.useRef(null),s=b.useRef(e),i=b.useRef("none"),o=e?"mounted":"unmounted",[a,l]=qE(o,{mounted:{UNMOUNT:"unmounted",ANIMATION_OUT:"unmountSuspended"},unmountSuspended:{MOUNT:"mounted",ANIMATION_END:"unmounted"},unmounted:{MOUNT:"mounted"}});return b.useEffect(()=>{const c=Ka(r.current);i.current=a==="mounted"?c:"none"},[a]),Er(()=>{const c=r.current,u=s.current;if(u!==e){const h=i.current,f=Ka(c);e?l("MOUNT"):f==="none"||(c==null?void 0:c.display)==="none"?l("UNMOUNT"):l(u&&h!==f?"ANIMATION_OUT":"UNMOUNT"),s.current=e}},[e,l]),Er(()=>{if(t){let c;const u=t.ownerDocument.defaultView??window,d=f=>{const y=Ka(r.current).includes(f.animationName);if(f.target===t&&y&&(l("ANIMATION_END"),!s.current)){const x=t.style.animationFillMode;t.style.animationFillMode="forwards",c=u.setTimeout(()=>{t.style.animationFillMode==="forwards"&&(t.style.animationFillMode=x)})}},h=f=>{f.target===t&&(i.current=Ka(r.current))};return t.addEventListener("animationstart",h),t.addEventListener("animationcancel",d),t.addEventListener("animationend",d),()=>{u.clearTimeout(c),t.removeEventListener("animationstart",h),t.removeEventListener("animationcancel",d),t.removeEventListener("animationend",d)}}else l("ANIMATION_END")},[t,l]),{isPresent:["mounted","unmountSuspended"].includes(a),ref:b.useCallback(c=>{r.current=c?getComputedStyle(c):null,n(c)},[])}}function Ka(e){return(e==null?void 0:e.animationName)||"none"}function YE(e){var r,s;let t=(r=Object.getOwnPropertyDescriptor(e.props,"ref"))==null?void 0:r.get,n=t&&"isReactWarning"in t&&t.isReactWarning;return n?e.ref:(t=(s=Object.getOwnPropertyDescriptor(e,"ref"))==null?void 0:s.get,n=t&&"isReactWarning"in t&&t.isReactWarning,n?e.props.ref:e.props.ref||e.ref)}var QE=Kv[" useInsertionEffect ".trim().toString()]||Er;function sx({prop:e,defaultProp:t,onChange:n=()=>{},caller:r}){const[s,i,o]=JE({defaultProp:t,onChange:n}),a=e!==void 0,l=a?e:s;{const u=b.useRef(e!==void 0);b.useEffect(()=>{const d=u.current;d!==a&&console.warn(`${r} is changing from ${d?"controlled":"uncontrolled"} to ${a?"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.`),u.current=a},[a,r])}const c=b.useCallback(u=>{var d;if(a){const h=XE(u)?u(e):u;h!==e&&((d=o.current)==null||d.call(o,h))}else i(u)},[a,e,i,o]);return[l,c]}function JE({defaultProp:e,onChange:t}){const[n,r]=b.useState(e),s=b.useRef(n),i=b.useRef(t);return QE(()=>{i.current=t},[t]),b.useEffect(()=>{var o;s.current!==n&&((o=i.current)==null||o.call(i,n),s.current=n)},[n,s]),[n,r,i]}function XE(e){return typeof e=="function"}var ZE=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"}),eT="VisuallyHidden",jc=b.forwardRef((e,t)=>
40p.jsx(qe.span,{...e,ref:t,style:{...ZE,...e.style}}));jc.displayName=eT;var tT=jc,Uf="ToastProvider",[Bf,nT,rT]=DE("Toast"),[ix,jM]=ma("Toast",[rT]),[sT,Nc]=ix(Uf),ox=e=>{const{__scopeToast:t,label:n="Notification",duration:r=5e3,swipeDirection:s="right",swipeThreshold:i=50,children:o}=e,[a,l]=b.useState(null),[c,u]=b.useState(0),d=b.useRef(!1),h=b.useRef(!1);return n.trim()||console.error(`Invalid prop \`label\` supplied to \`${Uf}\`. Expected non-empty \`string\`.`),p.jsx(Bf.Provider,{scope:t,children:p.jsx(sT,{scope:t,label:n,duration:r,swipeDirection:s,swipeThreshold:i,toastCount:c,viewport:a,onViewportChange:l,onToastAdd:b.useCallback(()=>u(f=>f+1),[]),onToastRemove:b.useCallback(()=>u(f=>f-1),[]),isFocusedToastEscapeKeyDownRef:d,isClosePausedRef:h,children:o})})};ox.displayName=Uf;var ax="ToastViewport",iT=["F8"],Jd="toast.viewportPause",Xd="toast.viewportResume",lx=b.forwardRef((e,t)=>{const{__scopeToast:n,hotkey:r=iT,label:s="Notifications ({hotkey})",...i}=e,o=Nc(ax,n),a=nT(n),l=b.useRef(null),c=b.useRef(null),u=b.useRef(null),d=b.useRef(null),h=_t(t,d,o.onViewportChange),f=r.join("+").replace(/Key/g,"").replace(/Digit/g,""),w=o.toastCount>0;b.useEffect(()=>{const x=m=>{var v;r.length!==0&&r.every(S=>m[S]||m.code===S)&&((v=d.current)==null||v.focus())};return document.addEventListener("keydown",x),()=>document.removeEventListener("keydown",x)},[r]),b.useEffect(()=>{const x=l.current,m=d.current;if(w&&x&&m){const g=()=>{if(!o.isClosePausedRef.current){const k=new CustomEvent(Jd);m.dispatchEvent(k),o.isClosePausedRef.current=!0}},v=()=>{if(o.isClosePausedRef.current){const k=new CustomEvent(Xd);m.dispatchEvent(k),o.isClosePausedRef.current=!1}},S=k=>{!x.contains(k.relatedTarget)&&v()},_=()=>{x.contains(document.activeElement)||v()};return x.addEventListener("focusin",g),x.addEventListener("focusout",S),x.addEventListener("pointermove",g),x.addEventListener("pointerleave",_),window.addEventListener("blur",g),window.addEventListener("focus",v),()=>{x.removeEventListener("focusin",g),x.removeEventListener("focusout",S),x.removeEventListener("pointermove",g),x.removeEventListener("pointerleave",_),window.removeEventListener("blur",g),window.removeEventListener("focus",v)}}},[w,o.isClosePausedRef]);const y=b.useCallback(({tabbingDirection:x})=>{const g=a().map(v=>{const S=v.ref.current,_=[S,...vT(S)];return x==="forwards"?_:_.reverse()});return(x==="forwards"?g.reverse():g).flat()},[a]);return b.useEffect(()=>{const x=d.current;if(x){const m=g=>{var _,k,E;const v=g.altKey||g.ctrlKey||g.metaKey;if(g.key==="Tab"&&!v){const T=document.activeElement,j=g.shiftKey;if(g.target===x&&j){(_=c.current)==null||_.focus();return}const M=y({tabbingDirection:j?"backwards":"forwards"}),J=M.findIndex(D=>D===T);Au(M.slice(J+1))?g.preventDefault():j?(k=c.current)==null||k.focus():(E=u.current)==null||E.focus()}};return x.addEventListener("keydown",m),()=>x.removeEventListener("keydown",m)}},[a,y]),p.jsxs(HE,{ref:l,role:"region","aria-label":s.replace("{hotkey}",f),tabIndex:-1,style:{pointerEvents:w?void 0:"none"},children:[w&&p.jsx(Zd,{ref:c,onFocusFromOutsideViewport:()=>{const x=y({tabbingDirection:"forwards"});Au(x)}}),p.jsx(Bf.Slot,{scope:n,children:p.jsx(qe.ol,{tabIndex:-1,...i,ref:h})}),w&&p.jsx(Zd,{ref:u,onFocusFromOutsideViewport:()=>{const x=y({tabbingDirection:"backwards"});Au(x)}})]})});lx.displayName=ax;var cx="ToastFocusProxy",Zd=b.forwardRef((e,t)=>{const{__scopeToast:n,onFocusFromOutsideViewport:r,...s}=e,i=Nc(cx,n);return p.jsx(jc,{"aria-hidden":!0,tabIndex:0,...s,ref:t,style:{position:"fixed"},onFocus:o=>{var c;const a=o.relatedTarget;!((c=i.viewport)!=null&&c.contains(a))&&r()}})});Zd.displayName=cx;var ga="Toast",oT="toast.swipeStart",aT="toast.swipeMove",lT="toast.swipeCancel",cT="toast.swipeEnd",ux=b.forwardRef((e,t)=>{const{forceMount:n,open:r,defaultOpen:s,onOpenChange:i,...o}=e,[a,l]=sx({prop:r,defaultProp:s??!0,onChange:i,caller:ga});return p.jsx(Rc,{present:n||a,children:p.jsx(hT,{open:a,...o,ref:t,onClose:()=>l(!1),onPause:kr(e.onPause),onResume:kr(e.onResume),onSwipeStart:Ce(e.onSwipeStart,c=>{c.currentTarget.setAttribute("data-swipe","start")}),onSwipeMove:Ce(e.onSwipeMove,c=>{const{x:u,y:d}=c.detail.delta;c.currentTarget.setAttribute("data-swipe","move"),c.currentTarget.style.setProperty("--radix-toast-swipe-move-x",`${u}px`),c.currentTarget.style.setProperty("--radix-toast-swipe-move-y",`${d}px`)}),onSwipeCancel:Ce(e.onSwipeCancel,c=>{c.currentTarget.setAttribute("data-swipe","cancel"),c.currentTarget.style.removeProperty("--radix-toast-swipe-move-x"),c.currentTarget.style.removeProperty("--radix-toast-swipe-move-y"),c.currentTarget.style.removeProperty("--radix-toast-swipe-end-x"),c.currentTarget.style.removeProperty("--radix-toast-swipe-end-y")}),onSwipeEnd:Ce(e.onSwipeEnd,c=>{const{x:u,y:d}=c.detail.delta;c.currentTarget.setAttribute("data-swipe","end"),c.currentTarget.style.removeProperty("--radix-toast-swipe-move-x"),c.currentTarget.style.removeProperty("--radix-toast-swipe-move-y"),c.currentTarget.style.setProperty("--radix-toast-swipe-end-x",`${u}px`),c.currentTarget.style.setProperty("--radix-toast-swipe-end-y",`${d}px`),l(!1)})})})});ux.displayName=ga;var[uT,dT]=ix(ga,{onClose(){}}),hT=b.forwardRef((e,t)=>
40{const{__scopeToast:n,type:r="foreground",duration:s,open:i,onClose:o,onEscapeKeyDown:a,onPause:l,onResume:c,onSwipeStart:u,onSwipeMove:d,onSwipeCancel:h,onSwipeEnd:f,...w}=e,y=Nc(ga,n),[x,m]=b.useState(null),g=_t(t,D=>m(D)),v=b.useRef(null),S=b.useRef(null),_=s||y.duration,k=b.useRef(0),E=b.useRef(_),T=b.useRef(0),{onToastAdd:j,onToastRemove:O}=y,U=kr(()=>{var X;(x==null?void 0:x.contains(document.activeElement))&&((X=y.viewport)==null||X.focus()),o()}),M=b.useCallback(D=>{!D||D===1/0||(window.clearTimeout(T.current),k.current=new Date().getTime(),T.current=window.setTimeout(U,D))},[U]);b.useEffect(()=>{const D=y.viewport;if(D){const X=()=>{M(E.current),c==null||c()},K=()=>{const V=new Date().getTime()-k.current;E.current=E.current-V,window.clearTimeout(T.current),l==null||l()};return D.addEventListener(Jd,K),D.addEventListener(Xd,X),()=>{D.removeEventListener(Jd,K),D.removeEventListener(Xd,X)}}},[y.viewport,_,l,c,M]),b.useEffect(()=>{i&&!y.isClosePausedRef.current&&M(_)},[i,_,y.isClosePausedRef,M]),b.useEffect(()=>(j(),()=>O()),[j,O]);const J=b.useMemo(()=>x?yx(x):null,[x]);return y.viewport?p.jsxs(p.Fragment,{children:[J&&p.jsx(fT,{__scopeToast:n,role:"status","aria-live":r==="foreground"?"assertive":"polite","aria-atomic":!0,children:J}),p.jsx(uT,{scope:n,onClose:U,children:pa.createPortal(p.jsx(Bf.ItemSlot,{scope:n,children:p.jsx(WE,{asChild:!0,onEscapeKeyDown:Ce(a,()=>{y.isFocusedToastEscapeKeyDownRef.current||U(),y.isFocusedToastEscapeKeyDownRef.current=!1}),children:p.jsx(qe.li,{role:"status","aria-live":"off","aria-atomic":!0,tabIndex:0,"data-state":i?"open":"closed","data-swipe-direction":y.swipeDirection,...w,ref:g,style:{userSelect:"none",touchAction:"none",...e.style},onKeyDown:Ce(e.onKeyDown,D=>{D.key==="Escape"&&(a==null||a(D.nativeEvent),D.nativeEvent.defaultPrevented||(y.isFocusedToastEscapeKeyDownRef.current=!0,U()))}),onPointerDown:Ce(e.onPointerDown,D=>{D.button===0&&(v.current={x:D.clientX,y:D.clientY})}),onPointerMove:Ce(e.onPointerMove,D=>{if(!v.current)return;const X=D.clientX-v.current.x,K=D.clientY-v.current.y,V=!!S.current,C=["left","right"].includes(y.swipeDirection),A=["left","up"].includes(y.swipeDirection)?Math.min:Math.max,L=C?A(0,X):0,q=C?0:A(0,K),B=D.pointerType==="touch"?10:2,Z={x:L,y:q},te={originalEvent:D,delta:Z};V?(S.current=Z,qa(aT,d,te,{discrete:!1})):lg(Z,y.swipeDirection,B)?(S.current=Z,qa(oT,u,te,{discrete:!1}),D.target.setPointerCapture(D.pointerId)):(Math.abs(X)>B||Math.abs(K)>B)&&(v.current=null)}),onPointerUp:Ce(e.onPointerUp,D=>{const X=S.current,K=D.target;if(K.hasPointerCapture(D.pointerId)&&K.releasePointerCapture(D.pointerId),S.current=null,v.current=null,X){const V=D.currentTarget,C={originalEvent:D,delta:X};lg(X,y.swipeDirection,y.swipeThreshold)?qa(cT,f,C,{discrete:!0}):qa(lT,h,C,{discrete:!0}),V.addEventListener("click",A=>A.preventDefault(),{once:!0})}})})})}),y.viewport)})]}):null}),fT=e=>{const{__scopeToast:t,children:n,...r}=e,s=Nc(ga,t),[i,o]=b.useState(!1),[a,l]=b.useState(!1);return gT(()=>o(!0)),b.useEffect(()=>{const c=window.setTimeout(()=>l(!0),1e3);return()=>window.clearTimeout(c)},[]),a?null:p.jsx(rx,{asChild:!0,children:p.jsx(jc,{...r,children:i&&p.jsxs(p.Fragment,{children:[s.label," ",n]})})})},pT="ToastTitle",dx=b.forwardRef((e,t)=>{const{__scopeToast:n,...r}=e;return p.jsx(qe.div,{...r,ref:t})});dx.displayName=pT;var mT="ToastDescription",hx=b.forwardRef((e,t)=>{const{__scopeToast:n,...r}=e;return p.jsx(qe.div,{...r,ref:t})});hx.displayName=mT;var fx="ToastAction",px=b.forwardRef((e,t)=>{const{altText:n,...r}=e;return n.trim()?p.jsx(gx,{altText:n,asChild:!0,children:p.jsx(zf,{...r,ref:t})}):(console.error(`Invalid prop \`altText\` supplied to \`${fx}\`. Expected non-empty \`string\`.`),null)});px.displayName=fx;var mx="ToastClose",zf=b.forwardRef((e,t)=>{const{__scopeToast:n,...r}=e,s=dT(mx,n);return p.jsx(gx,{asChild:!0,children:p.jsx(qe.button,{type:"button",...r,ref:t,onClick:Ce(e.onClick,s.onClose)})})});zf.displayName=mx;var gx=b.forwardRef((e,t)=>{const{__scopeToast:n,altText:r,...s}=e;return p.jsx(qe.div,{"data-radix-toast-announce-exclude":"","data-radix-toast-announce-alt":r||void 0,...s,ref:t})});function yx(e){const t=[];
vendor: 5,504 bytes, lines 40-89
40return Array.from(e.childNodes).forEach(r=>{if(r.nodeType===r.TEXT_NODE&&r.textContent&&t.push(r.textContent),yT(r)){const s=r.ariaHidden||r.hidden||r.style.display==="none",i=r.dataset.radixToastAnnounceExclude==="";if(!s)if(i){const o=r.dataset.radixToastAnnounceAlt;o&&t.push(o)}else t.push(...yx(r))}}),t}function qa(e,t,n,{discrete:r}){const s=n.originalEvent.currentTarget,i=new CustomEvent(e,{bubbles:!0,cancelable:!0,detail:n});t&&s.addEventListener(e,t,{once:!0}),r?Zw(s,i):s.dispatchEvent(i)}var lg=(e,t,n=0)=>{const r=Math.abs(e.x),s=Math.abs(e.y),i=r>s;return t==="left"||t==="right"?i&&r>n:!i&&s>n};function gT(e=()=>{}){const t=kr(e);Er(()=>{let n=0,r=0;return n=window.requestAnimationFrame(()=>r=window.requestAnimationFrame(t)),()=>{window.cancelAnimationFrame(n),window.cancelAnimationFrame(r)}},[t])}function yT(e){return e.nodeType===e.ELEMENT_NODE}function vT(e){const t=[],n=document.createTreeWalker(e,NodeFilter.SHOW_ELEMENT,{acceptNode:r=>{const s=r.tagName==="INPUT"&&r.type==="hidden";return r.disabled||r.hidden||s?NodeFilter.FILTER_SKIP:r.tabIndex>=0?NodeFilter.FILTER_ACCEPT:NodeFilter.FILTER_SKIP}});for(;n.nextNode();)t.push(n.currentNode);return t}function Au(e){const t=document.activeElement;return e.some(n=>n===t?!0:(n.focus(),document.activeElement!==t))}var wT=ox,vx=lx,wx=ux,xx=dx,bx=hx,Sx=px,_x=zf;function kx(e){var t,n,r="";if(typeof e=="string"||typeof e=="number")r+=e;else if(typeof e=="object")if(Array.isArray(e)){var s=e.length;for(t=0;t<s;t++)e[t]&&(n=kx(e[t]))&&(r&&(r+=" "),r+=n)}else for(n in e)e[n]&&(r&&(r+=" "),r+=n);return r}function Ex(){for(var e,t,n=0,r="",s=arguments.length;n<s;n++)(e=arguments[n])&&(t=kx(e))&&(r&&(r+=" "),r+=t);return r}const cg=e=>typeof e=="boolean"?`${e}`:e===0?"0":e,ug=Ex,Tx=(e,t)=>n=>{var r;if((t==null?void 0:t.variants)==null)return ug(e,n==null?void 0:n.class,n==null?void 0:n.className);const{variants:s,defaultVariants:i}=t,o=Object.keys(s).map(c=>{const u=n==null?void 0:n[c],d=i==null?void 0:i[c];if(u===null)return null;const h=cg(u)||cg(d);return s[c][h]}),a=n&&Object.entries(n).reduce((c,u)=>{let[d,h]=u;return h===void 0||(c[d]=h),c},{}),l=t==null||(r=t.compoundVariants)===null||r===void 0?void 0:r.reduce((c,u)=>{let{class:d,className:h,...f}=u;return Object.entries(f).every(w=>{let[y,x]=w;return Array.isArray(x)?x.includes({...i,...a}[y]):{...i,...a}[y]===x})?[...c,d,h]:c},[]);return ug(e,o,l,n==null?void 0:n.class,n==null?void 0:n.className)};/** 41 * @license lucide-react v0.462.0 - ISC 42 * 43 * This source code is licensed under the ISC license. 44 * See the LICENSE file in the root directory of this source tree. 45 */const xT=e=>e.replace(/([a-z0-9])([A-Z])/g,"$1-$2").toLowerCase(),Cx=(...e)=>e.filter((t,n,r)=>!!t&&t.trim()!==""&&r.indexOf(t)===n).join(" ").trim();/** 46 * @license lucide-react v0.462.0 - ISC 47 * 48 * This source code is licensed under the ISC license. 49 * See the LICENSE file in the root directory of this source tree. 50 */var bT={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"};/** 51 * @license lucide-react v0.462.0 - ISC 52 * 53 * This source code is licensed under the ISC license. 54 * See the LICENSE file in the root directory of this source tree. 55 */const ST=b.forwardRef(({color:e="currentColor",size:t=24,strokeWidth:n=2,absoluteStrokeWidth:r,className:s="",children:i,iconNode:o,...a},l)=>b.createElement("svg",{ref:l,...bT,width:t,height:t,stroke:e,strokeWidth:r?Number(n)*24/Number(t):n,className:Cx("lucide",s),...a},[...o.map(([c,u])=>b.createElement(c,u)),...Array.isArray(i)?i:[i]]));/** 56 * @license lucide-react v0.462.0 - ISC 57 * 58 * This source code is licensed under the ISC license. 59 * See the LICENSE file in the root directory of this source tree. 60 */const he=(e,t)=>{const n=b.forwardRef(({className:r,...s},i)=>b.createElement(ST,{ref:i,iconNode:t,className:Cx(`lucide-${xT(e)}`,r),...s}));return n.displayName=`${e}`,n};/** 61 * @license lucide-react v0.462.0 - ISC 62 * 63 * This source code is licensed under the ISC license. 64 * See the LICENSE file in the root directory of this source tree. 65 */const Px=he("Battery",[["rect",{width:"16",height:"10",x:"2",y:"7",rx:"2",ry:"2",key:"1w10f2"}],["line",{x1:"22",x2:"22",y1:"11",y2:"13",key:"4dh1rd"}]]);/** 66 * @license lucide-react v0.462.0 - ISC 67 * 68 * This source code is licensed under the ISC license. 69 * See the LICENSE file in the root directory of this source tree. 70 */const Ax=he("Check",[["path",{d:"M20 6 9 17l-5-5",key:"1gmf2c"}]]);/** 71 * @license lucide-react v0.462.0 - ISC 72 * 73 * This source code is licensed under the ISC license. 74 * See the LICENSE file in the root directory of this source tree. 75 */const _T=he("ChevronDown",[["path",{d:"m6 9 6 6 6-6",key:"qrunsl"}]]);/** 76 * @license lucide-react v0.462.0 - ISC 77 * 78 * This source code is licensed under the ISC license. 79 * See the LICENSE file in the root directory of this source tree. 80 */const kT=he("ChevronUp",[["path",{d:"m18 15-6-6-6 6",key:"153udz"}]]);/** 81 * @license lucide-react v0.462.0 - ISC 82 * 83 * This source code is licensed under the ISC license. 84 * See the LICENSE file in the root directory of this source tree. 85 */const ET=he("CircleCheckBig",[["path",{d:"M21.801 10A10 10 0 1 1 17 3.335",key:"yps3ct"}],["path",{d:"m9 11 3 3L22 4",key:"1pflzl"}]]);/** 86 * @license lucide-react v0.462.0 - ISC 87 * 88 * This source code is licensed under the ISC license. 89 * See the LICENSE file in the root directory of this source tree.
90 */const TT=he("ClipboardCheck",[["rect",{width:"8",height:"4",x:"8",y:"2",rx:"1",ry:"1",key:"tgr4d6"}],["path",{d:"M16 4h2a2 2 0 0 1 2 2v14a2 2 0 0 1-2 2H6a2 2 0 0 1-2-2V6a2 2 0 0 1 2-2h2",key:"116196"}],["path",{d:"m9 14 2 2 4-4",key:"df797q"}]]);/** 91 * @license lucide-react v0.462.0 - ISC 92 * 93 * This source code is licensed under the ISC license. 94 * See the LICENSE file in the root directory of this source tree. 95 */const Wf=he("Clock",[["circle",{cx:"12",cy:"12",r:"10",key:"1mglay"}],["polyline",{points:"12 6 12 12 16 14",key:"68esgv"}]]);/** 96 * @license lucide-react v0.462.0 - ISC 97 * 98 * This source code is licensed under the ISC license. 99 * See the LICENSE file in the root directory of this source tree. 100 */const Rx=he("ExternalLink",[["path",{d:"M15 3h6v6",key:"1q9fwt"}],["path",{d:"M10 14 21 3",key:"gplh6r"}],["path",{d:"M18 13v6a2 2 0 0 1-2 2H5a2 2 0 0 1-2-2V8a2 2 0 0 1 2-2h6",key:"a6xqqp"}]]);/** 101 * @license lucide-react v0.462.0 - ISC 102 * 103 * This source code is licensed under the ISC license. 104 * See the LICENSE file in the root directory of this source tree. 105 */const CT=he("LoaderCircle",[["path",{d:"M21 12a9 9 0 1 1-6.219-8.56",key:"13zald"}]]);/** 106 * @license lucide-react v0.462.0 - ISC 107 * 108 * This source code is licensed under the ISC license. 109 * See the LICENSE file in the root directory of this source tree. 110 */const Hf=he("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"}]]);/** 111 * @license lucide-react v0.462.0 - ISC 112 * 113 * This source code is licensed under the ISC license. 114 * See the LICENSE file in the root directory of this source tree. 115 */const PT=he("MapPin",[["path",{d:"M20 10c0 4.993-5.539 10.193-7.399 11.799a1 1 0 0 1-1.202 0C9.539 20.193 4 14.993 4 10a8 8 0 0 1 16 0",key:"1r0f0z"}],["circle",{cx:"12",cy:"10",r:"3",key:"ilqhr7"}]]);/** 116 * @license lucide-react v0.462.0 - ISC 117 * 118 * This source code is licensed under the ISC license. 119 * See the LICENSE file in the root directory of this source tree. 120 */const AT=he("MessageSquare",[["path",{d:"M21 15a2 2 0 0 1-2 2H7l-4 4V5a2 2 0 0 1 2-2h14a2 2 0 0 1 2 2z",key:"1lielz"}]]);/** 121 * @license lucide-react v0.462.0 - ISC 122 * 123 * This source code is licensed under the ISC license. 124 * See the LICENSE file in the root directory of this source tree. 125 */const dg=he("Navigation",[["polygon",{points:"3 11 22 2 13 21 11 13 3 11",key:"1ltx0t"}]]);/** 126 * @license lucide-react v0.462.0 - ISC 127 * 128 * This source code is licensed under the ISC license. 129 * See the LICENSE file in the root directory of this source tree. 130 */const Jl=he("Phone",[["path",{d:"M22 16.92v3a2 2 0 0 1-2.18 2 19.79 19.79 0 0 1-8.63-3.07 19.5 19.5 0 0 1-6-6 19.79 19.79 0 0 1-3.07-8.67A2 2 0 0 1 4.11 2h3a2 2 0 0 1 2 1.72 12.84 12.84 0 0 0 .7 2.81 2 2 0 0 1-.45 2.11L8.09 9.91a16 16 0 0 0 6 6l1.27-1.27a2 2 0 0 1 2.11-.45 12.84 12.84 0 0 0 2.81.7A2 2 0 0 1 22 16.92z",key:"foiqr5"}]]);/** 131 * @license lucide-react v0.462.0 - ISC 132 * 133 * This source code is licensed under the ISC license. 134 * See the LICENSE file in the root directory of this source tree. 135 */const eh=he("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"}]]);/** 136 * @license lucide-react v0.462.0 - ISC 137 * 138 * This source code is licensed under the ISC license. 139 * See the LICENSE file in the root directory of this source tree. 140 */const RT=he("Send",[["path",{d:"M14.536 21.686a.5.5 0 0 0 .937-.024l6.5-19a.496.496 0 0 0-.635-.635l-19 6.5a.5.5 0 0 0-.024.937l7.93 3.18a2 2 0 0 1 1.112 1.11z",key:"1ffxy3"}],["path",{d:"m21.854 2.147-10.94 10.939",key:"12cjpa"}]]);/** 141 * @license lucide-react v0.462.0 - ISC 142 * 143 * This source code is licensed under the ISC license. 144 * See the LICENSE file in the root directory of this source tree. 145 */const Kf=he("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",ke
vendor: 9,061 bytes, lines 145-185
145y:"oel41y"}]]);/** 146 * @license lucide-react v0.462.0 - ISC 147 * 148 * This source code is licensed under the ISC license. 149 * See the LICENSE file in the root directory of this source tree. 150 */const jx=he("Smartphone",[["rect",{width:"14",height:"20",x:"5",y:"2",rx:"2",ry:"2",key:"1yt0o3"}],["path",{d:"M12 18h.01",key:"mhygvu"}]]);/** 151 * @license lucide-react v0.462.0 - ISC 152 * 153 * This source code is licensed under the ISC license. 154 * See the LICENSE file in the root directory of this source tree. 155 */const th=he("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"}]]);/** 156 * @license lucide-react v0.462.0 - ISC 157 * 158 * This source code is licensed under the ISC license. 159 * See the LICENSE file in the root directory of this source tree. 160 */const Nx=he("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"}]]);/** 161 * @license lucide-react v0.462.0 - ISC 162 * 163 * This source code is licensed under the ISC license. 164 * See the LICENSE file in the root directory of this source tree. 165 */const jT=he("TriangleAlert",[["path",{d:"m21.73 18-8-14a2 2 0 0 0-3.48 0l-8 14A2 2 0 0 0 4 21h16a2 2 0 0 0 1.73-3",key:"wmoenq"}],["path",{d:"M12 9v4",key:"juzpu7"}],["path",{d:"M12 17h.01",key:"p32p05"}]]);/** 166 * @license lucide-react v0.462.0 - ISC 167 * 168 * This source code is licensed under the ISC license. 169 * See the LICENSE file in the root directory of this source tree. 170 */const Ox=he("Truck",[["path",{d:"M14 18V6a2 2 0 0 0-2-2H4a2 2 0 0 0-2 2v11a1 1 0 0 0 1 1h2",key:"wrbu53"}],["path",{d:"M15 18H9",key:"1lyqi6"}],["path",{d:"M19 18h2a1 1 0 0 0 1-1v-3.65a1 1 0 0 0-.22-.624l-3.48-4.35A1 1 0 0 0 17.52 8H14",key:"lysw3i"}],["circle",{cx:"17",cy:"18",r:"2",key:"332jqn"}],["circle",{cx:"7",cy:"18",r:"2",key:"19iecd"}]]);/** 171 * @license lucide-react v0.462.0 - ISC 172 * 173 * This source code is licensed under the ISC license. 174 * See the LICENSE file in the root directory of this source tree. 175 */const NT=he("Users",[["path",{d:"M16 21v-2a4 4 0 0 0-4-4H6a4 4 0 0 0-4 4v2",key:"1yyitq"}],["circle",{cx:"9",cy:"7",r:"4",key:"nufk8"}],["path",{d:"M22 21v-2a4 4 0 0 0-3-3.87",key:"kshegd"}],["path",{d:"M16 3.13a4 4 0 0 1 0 7.75",key:"1da9ce"}]]);/** 176 * @license lucide-react v0.462.0 - ISC 177 * 178 * This source code is licensed under the ISC license. 179 * See the LICENSE file in the root directory of this source tree. 180 */const OT=he("X",[["path",{d:"M18 6 6 18",key:"1bl5f8"}],["path",{d:"m6 6 12 12",key:"d8bk6v"}]]);/** 181 * @license lucide-react v0.462.0 - ISC 182 * 183 * This source code is licensed under the ISC license. 184 * See the LICENSE file in the root directory of this source tree. 185 */const hg=he("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"}]]),qf="-",IT=e=>{const t=LT(e),{conflictingClassGroups:n,conflictingClassGroupModifiers:r}=e;return{getClassGroupId:o=>{const a=o.split(qf);return a[0]===""&&a.length!==1&&a.shift(),Ix(a,t)||DT(o)},getConflictingClassGroupIds:(o,a)=>{const l=n[o]||[];return a&&r[o]?[...l,...r[o]]:l}}},Ix=(e,t)=>{var o;if(e.length===0)return t.classGroupId;const n=e[0],r=t.nextPart.get(n),s=r?Ix(e.slice(1),r):void 0;if(s)return s;if(t.validators.length===0)return;const i=e.join(qf);return(o=t.validators.find(({validator:a})=>a(i)))==null?void 0:o.classGroupId},fg=/^\[(.+)\]$/,DT=e=>{if(fg.test(e)){const t=fg.exec(e)[1],n=t==null?void 0:t.substring(0,t.indexOf(":"));if(n)return"arbitrary.."+n}},LT=e=>{const{theme:t,prefix:n}=e,r={nextPart:new Map,validators:[]};return $T(Object.entries(e.classGroups),n).forEach(([i,o])=>{nh(o,r,i,t)}),r},nh=(e,t,n,r)=>{e.forEach(s=>{if(typeof s=="string"){const i=s===""?t:pg(t,s);i.classGroupId=n;return}if(typeof s=="function"){if(MT(s)){nh(s(r),t,n,r);return}t.validators.push({validator:s,classGroupId:n});return}Object.entries(s).forEach(([i,o])=>{nh(o,pg(t,i),n,r)})})},pg=(e,t)=>{let n=e;return t.split(qf).forEach(r=>{n.nextPart.has(r)||n.nextPart.set(r,{nextPart:new Map,validators:[]}),n=n.nextPart.get(r)}),n},MT=e=>e.isThemeGetter,$T=(e,t)=>t?e.map(([n,r])=>{const s=r.map(i=>typeof i=="string"?t+i:typeof i=="object"?Object.fromEntries(Object.entries(i).map(([o,a])=>[t+o,a])):i);return[n,s]}):e,VT=e=>{if(e<1)return{get:()=>{},set:()=>{}};let t=0,n=new Map,r=new Map;const s=(i,o)=>{n.set(i,o),t++,t>e&&(t=0,r=n,n=new Map)};return{get(i){let o=n.get(i);if(o!==void 0)return o;if((o=r.get(i))!==void 0)return s(i,o),o},set(i,o){n.has(i)?n.set(i,o):s(i,o)}}},Dx="!",FT=e=>{const{separator:t,experimentalParseClassName:n}=e,r=t.length===1,s=t[0],i=t.length,o=a=>{const l=[];let c=0,u=0,d;for(let x=0;x<a.length;x++){let m=a[x];if(c===0){if(m===s&&(r||a.slice(x,x+i)===t)){l.push(a.slice(u,x)),u=x+i;continue}if(m==="/"){d=x;continue}}m==="["?c++:m==="]"&&c--}const h=l.length===0?a:a.substring(u),f=h.startsWith(Dx),w=f?h.substring(1):h,y=d&&d>u?d-u:void 0;return{modifiers:l,hasImportantModifier:f,baseClassName:w,maybePostfixModifierPosition:y}};return n?a=>n({className:a,parseClassName:o}):o},UT=e=>{if(e.length<=1)return e;const t=[];let n=[];return e.forEach(r=>{r[0]==="["?(t.push(...n.sort(),r),n=[]):n.push(r)}),t.push(...n.sort()),t},BT=e=>({cache:VT(e.cacheSize),parseClassName:FT(e),...IT(e)}),zT=/\s+/,WT=(e,t)=>{const{parseClassName:n,getClassGroupId:r,getConflictingClassGroupIds:s}=t,i=[],o=e.trim().split(zT);let a="";for(let l=o.length-1;l>=0;l-=1){const c=o[l],{modifiers:u,hasImportantModifier:d,baseClassName:h,maybePostfixModifierPosition:f}=n(c);let w=!!f,y=r(w?h.substring(0,f):h);if(!y){if(!w){a=c+(a.length>0?" "+a:a);continue}if(y=r(h),!y){a=c+(a.length>0?" "+a:a);continue}w=!1}const x=UT(u).join(":"),m=d?x+Dx:x,g=m+y;if(i.includes(g))continue;i.push(g);const v=s(y,w);for(let S=0;S<v.length;++S){const _=v[S];i.push(m+_)}a=c+(a.length>0?" "+a:a)}return a};function HT(){let e=0,t,n,r="";for(;e<arguments.length;)(t=arguments[e++])&&(n=Lx(t))&&(r&&(r+=" "),r+=n);return r}const Lx=e=>{if(typeof e=="string")return e;let t,n="";for(let r=0;r<e.length;r++)e[r]&&(t=Lx(e[r]))&&(n&&(n+=" "),n+=t);return n};function KT(e,...t){let n,r,s,i=o;function o(l){const c=t.reduce((u,d)=>d(u),e());return n=BT(c),r=n.cache.get,s=n.cache.set,i=a,a(l)}function a(l){const c=r(l);if(c)return c;const u=WT(l,n);return s(l,u),u}return function(){return i(HT.apply(null,arguments))}}const ce=e=>{const t=n=>n[e]||[];return t.isThemeGetter=!0,t},Mx=/^\[(?:([a-z-]+):)?(.+)\]$/i,qT=/^\d+\/\d+$/,GT=new Set(["px","full","screen"]),YT=/^(\d+(\.\d+)?)?(xs|sm|md|lg|xl)$/,QT=/\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$/,JT=/^(rgba?|hsla?|hwb|(ok)?(lab|lch))\(.+\)$/,XT=/^(inset_)?-?((\d+)?\.?(\d+)[a-z]+|0)_-?((\d+)?\.?(\d+)[a-z]+|0)/,ZT=/^(url|image|image-set|cross-fade|element|(repeating-)?(linear|radial|conic)-gradient)\(.+\)$/,bn=e=>li(e)||GT.has(e)||qT.test(e),Gn=e=>Ii(e,"length",aC),li=e=>!!e&&!Number.isNaN(Number(e)),Ru=e=>Ii(e,"number",li),Zi=e=>!!e&&Number.isInteger(Number(e)),eC=e=>e.endsWith("%")&&li(e.slice(0,-1)),Q=e=>Mx.test(e),Yn=e=>YT.test(e),tC=new Set(["length","size","percentage"]),nC=e=>Ii(e,tC,$x),rC=e=>Ii(e,"position",$x),sC=new Set(["image","url"]),iC=e=>Ii(e,sC,cC),oC=e=>Ii(e,"",lC),eo=()=>!0,Ii=(e,t,n)=>{const r=Mx.exec(e);return r?r[1]?typeof t=="string"?r[1]===t:t.has(r[1]):n(r[2]):!1},aC=e=>QT.test(e)&&!JT.test(e),$x=()=>!1,lC=e=>XT.test(e),cC=e=>ZT.test(e),uC=()=>{const e=ce("colors"),t=ce("spacing"),n=ce("blur"),r=ce("brightness"),s=ce("borderColor"),i=ce("borderRadius"),o=ce("borderSpacing"),a=ce("borderWidth"),l=ce("contrast"),c=ce("grayscale"),u=ce("hueRotate"),d=ce("invert"),h=ce("gap"),f=ce("gradientColorStops"),w=ce("gradientColorStopPositions"),y=ce("inset"),x=ce("margin"),m=ce("opacity"),g=ce("padding"),v=ce("saturate"),S=ce("scale"),_=ce("sepia"),k=ce("skew"),E=ce("space"),T=ce("translate"),j=()=>["auto","contain","none"],O=()=>["auto","hidden","clip","visible","scroll"],U=()=>["auto",Q,t],M=()=>[Q,t],J=()=>["",bn,Gn],D=()=>["auto",li,Q],X=()=>["bottom","center","left","left-bottom","left-top","right","right-bottom","right-top","top"],K=()=>["solid","dashed","dotted","double","none"],V=()=>["normal","multiply","screen","overlay","darken","lighten","color-dodge","color-burn","hard-light","soft-light","difference","exclusion","hue","saturation","color","luminosity"],C=()=>["start","end","center","between","around","evenly","stretch"],A=()=>["","0",Q],L=()=>["auto","avoid","all","avoid-page","page","left","right","column"],q=()=>[li,Q];return{cacheSize:500,separator:":",theme:{colors:[eo],spacing:[bn,Gn],blur:["none","",Yn,Q],brightness:q(),borderColor:[e],borderRadius:["n
vendor: 2,059 bytes, line 185
185one","","full",Yn,Q],borderSpacing:M(),borderWidth:J(),contrast:q(),grayscale:A(),hueRotate:q(),invert:A(),gap:M(),gradientColorStops:[e],gradientColorStopPositions:[eC,Gn],inset:U(),margin:U(),opacity:q(),padding:M(),saturate:q(),scale:q(),sepia:A(),skew:q(),space:M(),translate:M()},classGroups:{aspect:[{aspect:["auto","square","video",Q]}],container:["container"],columns:[{columns:[Yn]}],"break-after":[{"break-after":L()}],"break-before":[{"break-before":L()}],"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:[...X(),Q]}],overflow:[{overflow:O()}],"overflow-x":[{"overflow-x":O()}],"overflow-y":[{"overflow-y":O()}],overscroll:[{overscroll:j()}],"overscroll-x":[{"overscroll-x":j()}],"overscroll-y":[{"overscroll-y":j()}],position:["static","fixed","absolute","relative","sticky"],inset:[{inset:[y]}],"inset-x":[{"inset-x":[y]}],"inset-y":[{"inset-y":[y]}],start:[{start:[y]}],end:[{end:[y]}],top:[{top:[y]}],right:[{right:[y]}],bottom:[{bottom:[y]}],left:[{left:[y]}],visibility:["visible","invisible","collapse"],z:[{z:["auto",Zi,Q]}],basis:[{basis:U()}],"flex-direction":[{flex:["row","row-reverse","col","col-reverse"]}],"flex-wrap":[{flex:["wrap","wrap-reverse","nowrap"]}],flex:[{flex:["1","auto","initial","none",Q]}],grow:[{grow:A()}],shrink:[{shrink:A()}],order:[{order:["first","last","none",Zi,Q]}],"grid-cols":[{"grid-cols":[eo]}],"col-start-end":[{col:["auto",{span:["full",Zi,Q]}
vendor: 9,430 bytes, line 185
185,Q]}],"col-start":[{"col-start":D()}],"col-end":[{"col-end":D()}],"grid-rows":[{"grid-rows":[eo]}],"row-start-end":[{row:["auto",{span:[Zi,Q]},Q]}],"row-start":[{"row-start":D()}],"row-end":[{"row-end":D()}],"grid-flow":[{"grid-flow":["row","col","dense","row-dense","col-dense"]}],"auto-cols":[{"auto-cols":["auto","min","max","fr",Q]}],"auto-rows":[{"auto-rows":["auto","min","max","fr",Q]}],gap:[{gap:[h]}],"gap-x":[{"gap-x":[h]}],"gap-y":[{"gap-y":[h]}],"justify-content":[{justify:["normal",...C()]}],"justify-items":[{"justify-items":["start","end","center","stretch"]}],"justify-self":[{"justify-self":["auto","start","end","center","stretch"]}],"align-content":[{content:["normal",...C(),"baseline"]}],"align-items":[{items:["start","end","center","baseline","stretch"]}],"align-self":[{self:["auto","start","end","center","stretch","baseline"]}],"place-content":[{"place-content":[...C(),"baseline"]}],"place-items":[{"place-items":["start","end","center","baseline","stretch"]}],"place-self":[{"place-self":["auto","start","end","center","stretch"]}],p:[{p:[g]}],px:[{px:[g]}],py:[{py:[g]}],ps:[{ps:[g]}],pe:[{pe:[g]}],pt:[{pt:[g]}],pr:[{pr:[g]}],pb:[{pb:[g]}],pl:[{pl:[g]}],m:[{m:[x]}],mx:[{mx:[x]}],my:[{my:[x]}],ms:[{ms:[x]}],me:[{me:[x]}],mt:[{mt:[x]}],mr:[{mr:[x]}],mb:[{mb:[x]}],ml:[{ml:[x]}],"space-x":[{"space-x":[E]}],"space-x-reverse":["space-x-reverse"],"space-y":[{"space-y":[E]}],"space-y-reverse":["space-y-reverse"],w:[{w:["auto","min","max","fit","svw","lvw","dvw",Q,t]}],"min-w":[{"min-w":[Q,t,"min","max","fit"]}],"max-w":[{"max-w":[Q,t,"none","full","min","max","fit","prose",{screen:[Yn]},Yn]}],h:[{h:[Q,t,"auto","min","max","fit","svh","lvh","dvh"]}],"min-h":[{"min-h":[Q,t,"min","max","fit","svh","lvh","dvh"]}],"max-h":[{"max-h":[Q,t,"min","max","fit","svh","lvh","dvh"]}],size:[{size:[Q,t,"auto","min","max","fit"]}],"font-size":[{text:["base",Yn,Gn]}],"font-smoothing":["antialiased","subpixel-antialiased"],"font-style":["italic","not-italic"],"font-weight":[{font:["thin","extralight","light","normal","medium","semibold","bold","extrabold","black",Ru]}],"font-family":[{font:[eo]}],"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",Q]}],"line-clamp":[{"line-clamp":["none",li,Ru]}],leading:[{leading:["none","tight","snug","normal","relaxed","loose",bn,Q]}],"list-image":[{"list-image":["none",Q]}],"list-style-type":[{list:["none","disc","decimal",Q]}],"list-style-position":[{list:["inside","outside"]}],"placeholder-color":[{placeholder:[e]}],"placeholder-opacity":[{"placeholder-opacity":[m]}],"text-alignment":[{text:["left","center","right","justify","start","end"]}],"text-color":[{text:[e]}],"text-opacity":[{"text-opacity":[m]}],"text-decoration":["underline","overline","line-through","no-underline"],"text-decoration-style":[{decoration:[...K(),"wavy"]}],"text-decoration-thickness":[{decoration:["auto","from-font",bn,Gn]}],"underline-offset":[{"underline-offset":["auto",bn,Q]}],"text-decoration-color":[{decoration:[e]}],"text-transform":["uppercase","lowercase","capitalize","normal-case"],"text-overflow":["truncate","text-ellipsis","text-clip"],"text-wrap":[{text:["wrap","nowrap","balance","pretty"]}],indent:[{indent:M()}],"vertical-align":[{align:["baseline","top","middle","bottom","text-top","text-bottom","sub","super",Q]}],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",Q]}],"bg-attachment":[{bg:["fixed","local","scroll"]}],"bg-clip":[{"bg-clip":["border","padding","content","text"]}],"bg-opacity":[{"bg-opacity":[m]}],"bg-origin":[{"bg-origin":["border","padding","content"]}],"bg-position":[{bg:[...X(),rC]}],"bg-repeat":[{bg:["no-repeat",{repeat:["","x","y","round","space"]}]}],"bg-size":[{bg:["auto","cover","contain",nC]}],"bg-image":[{bg:["none",{"gradient-to":["t","tr","r","br","b","bl","l","tl"]},iC]}],"bg-color":[{bg:[e]}],"gradient-from-pos":[{from:[w]}],"gradient-via-pos":[{via:[w]}],"gradient-to-pos":[{to:[w]}],"gradient-from":[{from:[f]}],"gradient-via":[{via:[f]}],"gradient-to":[{to:[f]}],rounded:[{rounded:[i]}],"rounded-s":[{"rounded-s":[i]}],"rounded-e":[{"rounded-e":[i]}],"rounded-t":[{"rounded-t":[i]}],"rounded-r":[{"rounded-r":[i]}],"rounded-b":[{"rounded-b":[i]}],"rounded-l":[{"rounded-l":[i]}],"rounded-ss":[{"rounded-ss":[i]}],"rounded-se":[{"rounded-se":[i]}],"rounded-ee":[{"rounded-ee":[i]}],"rounded-es":[{"rounded-es":[i]}],"rounded-tl":[{"rounded-tl":[i]}],"rounded-tr":[{"rounded-tr":[i]}],"rounded-br":[{"rounded-br":[i]}],"rounded-bl":[{"rounded-bl":[i]}],"border-w":[{border:[a]}],"border-w-x":[{"border-x":[a]}],"border-w-y":[{"border-y":[a]}],"border-w-s":[{"border-s":[a]}],"border-w-e":[{"border-e":[a]}],"border-w-t":[{"border-t":[a]}],"border-w-r":[{"border-r":[a]}],"border-w-b":[{"border-b":[a]}],"border-w-l":[{"border-l":[a]}],"border-opacity":[{"border-opacity":[m]}],"border-style":[{border:[...K(),"hidden"]}],"divide-x":[{"divide-x":[a]}],"divide-x-reverse":["divide-x-reverse"],"divide-y":[{"divide-y":[a]}],"divide-y-reverse":["divide-y-reverse"],"divide-opacity":[{"divide-opacity":[m]}],"divide-style":[{divide:K()}],"border-color":[{border:[s]}],"border-color-x":[{"border-x":[s]}],"border-color-y":[{"border-y":[s]}],"border-color-s":[{"border-s":[s]}],"border-color-e":[{"border-e":[s]}],"border-color-t":[{"border-t":[s]}],"border-color-r":[{"border-r":[s]}],"border-color-b":[{"border-b":[s]}],"border-color-l":[{"border-l":[s]}],"divide-color":[{divide:[s]}],"outline-style":[{outline:["",...K()]}],"outline-offset":[{"outline-offset":[bn,Q]}],"outline-w":[{outline:[bn,Gn]}],"outline-color":[{outline:[e]}],"ring-w":[{ring:J()}],"ring-w-inset":["ring-inset"],"ring-color":[{ring:[e]}],"ring-opacity":[{"ring-opacity":[m]}],"ring-offset-w":[{"ring-offset":[bn,Gn]}],"ring-offset-color":[{"ring-offset":[e]}],shadow:[{shadow:["","inner","none",Yn,oC]}],"shadow-color":[{shadow:[eo]}],opacity:[{opacity:[m]}],"mix-blend":[{"mix-blend":[...V(),"plus-lighter","plus-darker"]}],"bg-blend":[{"bg-blend":V()}],filter:[{filter:["","none"]}],blur:[{blur:[n]}],brightness:[{brightness:[r]}],contrast:[{contrast:[l]}],"drop-shadow":[{"drop-shadow":["","none",Yn,Q]}],grayscale:[{grayscale:[c]}],"hue-rotate":[{"hue-rotate":[u]}],invert:[{invert:[d]}],saturate:[{saturate:[v]}],sepia:[{sepia:[_]}],"backdrop-filter":[{"backdrop-filter":["","none"]}],"backdrop-blur":[{"backdrop-blur":[n]}],"backdrop-brightness":[{"backdrop-brightness":[r]}],"backdrop-contrast":[{"backdrop-contrast":[l]}],"backdrop-grayscale":[{"backdrop-grayscale":[c]}],"backdrop-hue-rotate":[{"backdrop-hue-rotate":[u]}],"backdrop-invert":[{"backdrop-invert":[d]}],"backdrop-opacity":[{"backdrop-opacity":[m]}],"backdrop-saturate":[{"backdrop-saturate":[v]}],"backdrop-sepia":[{"backdrop-sepia":[_]}],"border-collapse":[{border:["collapse","separate"]}],"border-spacing":[{"border-spacing":[o]}],"border-spacing-x":[{"border-spacing-x":[o]}],"border-spacing-y":[{"border-spacing-y":[o]}],"table-layout":[{table:["auto","fixed"]}],caption:[{caption:["top","bottom"]}],transition:[{transition:["none","all","","colors","opacity","shadow","transform",Q]}],duration:[{duration:q()}],ease:[{ease:["linear","in","out","in-out",Q]}],delay:[{delay:q()}],animate:[{animate:["none","spin","ping","pulse","bounce",Q]}],transform:[{transform:["","gpu","none"]}],scale:[{scale:[S]}],"scale-x":[{"scale-x":[S]}],"scale-y":[{"scale-y":[S]}],rotate:[{rotate:[Zi,Q]}],"translate-x":[{"translate-x":[T]}],"translate-y":[{"translate-y":[T]}],"skew-x":[{"skew-x":[k]}],"skew-y":[{"skew-y":[k]}],"transform-origin":[{origin:["center","top","top-right","right","bottom-right","bottom","bottom-left","left","top-left",Q]}],accent:[{accent:["auto",e]}],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",Q]}],"caret-color":[{caret:[e]}],"pointer-events":[{"pointer-events":["none","auto"]}],resize:[{resize:["none","y","x",""]}],"scroll-behavior":[{scroll:["auto","smooth"]}],"scroll-m":[{"scroll-m":M()}],"scroll-mx":[{"scroll-mx":M()}],"scroll-my":[{"scroll-my":M()}],"scroll-ms":[{"scroll-ms":M()}],"scroll-me":[{"scroll-me":M()}],"scroll-mt":[{"scroll-mt":M()}],"scroll-mr":[{"scroll-mr":M()}],"scroll-mb":[{"scroll-mb":M()}],"scroll-ml":[{"scroll-ml":M()}],"scroll-p":[{"scroll-p":M()}],"scroll-px":[{"scroll-px":M()}],"scroll-py":[{"scroll-py":M()}],"scroll-ps":[{"scroll-ps":M()}],"scroll-pe":[{"scroll-pe":M()}],"scroll-pt":[{"scroll-pt":M()}],"scroll-pr":[{"scroll-pr":M()}],"scroll-pb":[{"scroll-pb":M()}],"scroll-pl":[{"scroll-pl":M()}],"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,646 bytes, line 185
185],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",Q]}],fill:[{fill:[e,"none"]}],"stroke-w":[{stroke:[bn,Gn,Ru]}],stroke:[{stroke:[e,"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"]}}},dC=KT(uC);function Mt(...e){return dC(Ex(e))}const hC=wT,Vx=b.forwardRef(({className:e,...t},n)=>p.jsx(vx,{ref:n,className:Mt("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]",e),...t}));Vx.displayName=vx.displayName;const fC=Tx("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"}}),Fx=b.forwardRef(({className:e,variant:t,...n},r)=>p.jsx(wx,{ref:r,className:Mt(fC({variant:t}),e),...n}));Fx.displayName=wx.displayName;const pC=b.forwardRef(({className:e,...t},n)=>p.jsx(Sx,{ref:n,className:Mt("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",e),...t}));pC.displayName=Sx.displayName;const Ux=b.forwardRef(({className:e,...t},n)=>p.jsx(_x,{ref:n,className:Mt("absolute right-2 top-2 rounded-md p-1 text-foreground
185/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",e),"toast-close":"",...t,children:p.jsx(OT,{className:"h-4 w-4"})}));Ux.displayName=_x.displayName;const Bx=b.forwardRef(({className:e,...t},n)=>p.jsx(xx,{ref:n,className:Mt("text-sm font-semibold",e),...t}));Bx.displayName=xx.displayName;const zx=b.forwardRef(({className:e,...t},n)=>p.jsx(bx,{ref:n,className:Mt("text-sm opacity-90",e),...t}));zx.displayName=bx.displayName;function mC(){const{toasts:e}=Vf();return p.jsxs(hC,{children:[e.map(function({id:t,title:n,description:r,action:s,...i}){return p.jsxs(Fx,{...i,children:[p.jsxs("div",{className:"grid gap-1",children:[n&&p.jsx(Bx,{children:n}),r&&p.jsx(zx,{children:r})]}),s,p.jsx(Ux,{})]},t)}),p.jsx(Vx,{})]})}var mg=["light","dark"],gC="(prefers-color-scheme: dark)",yC=b.createContext(void 0),vC={setTheme:e=>{},themes:[]},wC=()=>{var e;return(e=b.useContext(yC))!=null?e:vC};b.memo(({forcedTheme:e,storageKey:t,attribute:n,enableSystem:r,enableColorScheme:s,defaultTheme:i,value:o,attrs:a,nonce:l})=>{let c=i==="system",u=n==="class"?`var d=document.documentElement,c=d.classList;${`c.remove(${a.map(w=>`'${w}'`).join(",")})`};`:`var d=document.documentElement,n='${n}',s='setAttribute';`,d=s?mg.includes(i)&&i?`if(e==='light'||e==='dark'||!e)d.style.colorScheme=e||'${i}'`:"if(e==='light'||e==='dark')d.style.colorScheme=e":"",h=(w,y=!1,x=!0)=>{let m=o?o[w]:w,g=y?w+"|| ''":`'${m}'`,v="";return s&&x&&!y&&mg.includes(w)&&(v+=`d.style.colorScheme = '${w}';`),n==="class"?y||m?v+=`c.add(${g})`:v+="null":m&&(v+=`d[s](n,${g})`),v},f=e?`!function(){${u}${h(e)}}()`:r?`!function(){try{${u}var e=localStorage.getItem('${t}');if('system'===e||(!e&&${c})){var t='${gC}',m=window.matchMedia(t);if(m.media!==t||m.matches){${h("dark")}}else{${h("light")}}}else if(e){${o?`var x=${JSON.stringify(o)};`:""}${h(o?"x[e]":"e",!0)}}${c?"":"else{"+h(i,!1,!1)+"}"}${d}}catch(e){}}()`:`!function(){try{${u}var e=localStorage.getItem('${t}');if(e){${o?`var x=${JSON.stringify(o)};`:""}${h(o?"x[e]":"e",!0)}}else{${h(i,!1,!1)};}${d}}catch(t){}}();`;return b.createElement("script",{nonce:l,dangerouslySetInnerHTML:{__html:f}})});var xC=e=>{switch(e){case"success":return _C;case"info":return EC;case"warning":return kC;case"error":return TC;default:return null}},bC=Array(12).fill(0),SC=({visible:e,className:t})=>I.createElement("div",{className:["sonner-loading-wrapper",t].filter(Boolean).join(" "),"data-visible":e},I.createElement("div",{className:"sonner-spinner"},bC.map((n,r)=>I.createElement("div",{className:"sonner-loading-bar",key:`spinner-bar-${r}`})))),_C=I.createElement("svg",{xmlns:"http://www.w3.org/2000/svg",viewBox:"0 0 20 20",fill:"currentColor",height:"20",width:"20"},I.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"})),kC=I.createElement("svg",{xmlns:"http://www.w3.org/2000/svg",viewBox:"0 0 24 24",fill:"currentColor",height:"20",width:"20"},I.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"})),EC=I.createElement("svg",{xmlns:"http://www.w3.org/2000/svg",viewBox:"0 0 20 20",fill:"currentColor",height:"20",width:"20"},I.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"})),TC=I.createElement("svg",{xmlns:"http://www.w3.org/2000/svg",viewBox:"0 0 20 20",fill:"currentColor",height:"20",width:"20"},I.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"})),CC=I.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"},I.createElement("line",{x1:"18",y1:"6",x2:"6",y2:"18"}),I.createElement("line",{x1:"6",y1:"6",x2:"18",y2:"18"})),PC=()=>
185{let[e,t]=I.useState(document.hidden);return I.useEffect(()=>{let n=()=>{t(document.hidden)};return document.addEventListener("visibilitychange",n),()=>window.removeEventListener("visibilitychange",n)},[]),e},rh=1,AC=class{constructor(){this.subscribe=e=>(this.subscribers.push(e),()=>{let t=this.subscribers.indexOf(e);this.subscribers.splice(t,1)}),this.publish=e=>{this.subscribers.forEach(t=>t(e))},this.addToast=e=>{this.publish(e),this.toasts=[...this.toasts,e]},this.create=e=>{var t;let{message:n,...r}=e,s=typeof(e==null?void 0:e.id)=="number"||((t=e.id)==null?void 0:t.length)>0?e.id:rh++,i=this.toasts.find(a=>a.id===s),o=e.dismissible===void 0?!0:e.dismissible;return this.dismissedToasts.has(s)&&this.dismissedToasts.delete(s),i?this.toasts=this.toasts.map(a=>a.id===s?(this.publish({...a,...e,id:s,title:n}),{...a,...e,id:s,dismissible:o,title:n}):a):this.addToast({title:n,...r,dismissible:o,id:s}),s},this.dismiss=e=>(this.dismissedToasts.add(e),e||this.toasts.forEach(t=>{this.subscribers.forEach(n=>n({id:t.id,dismiss:!0}))}),this.subscribers.forEach(t=>t({id:e,dismiss:!0})),e),this.message=(e,t)=>this.create({...t,message:e}),this.error=(e,t)=>this.create({...t,message:e,type:"error"}),this.success=(e,t)=>this.create({...t,type:"success",message:e}),this.info=(e,t)=>this.create({...t,type:"info",message:e}),this.warning=(e,t)=>this.create({...t,type:"warning",message:e}),this.loading=(e,t)=>
185this.create({...t,type:"loading",message:e}),this.promise=(e,t)=>{if(!t)return;let n;t.loading!==void 0&&(n=this.create({...t,promise:e,type:"loading",message:t.loading,description:typeof t.description!="function"?t.description:void 0}));let r=e instanceof Promise?e:e(),s=n!==void 0,i,o=r.then(async l=>{if(i=["resolve",l],I.isValidElement(l))s=!1,this.create({id:n,type:"default",message:l});else if(jC(l)&&!l.ok){s=!1;let c=typeof t.error=="function"?await t.error(`HTTP error! status: ${l.status}`):t.error,u=typeof t.description=="function"?await t.description(`HTTP error! status: ${l.status}`):t.description;this.create({id:n,type:"error",message:c,description:u})}else if(t.success!==void 0){s=!1;let c=typeof t.success=="function"?await t.success(l):t.success,u=typeof t.description=="function"?await t.description(l):t.description;this.create({id:n,type:"success",message:c,description:u})}}).catch(async l=>{if(i=["reject",l],t.error!==void 0){s=!1;let c=typeof t.error=="function"?await t.error(l):t.error,u=typeof t.description=="function"?await t.description(l):t.description;this.create({id:n,type:"error",message:c,description:u})}}).finally(()=>{var l;s&&(this.dismiss(n),n=void 0),(l=t.finally)==null||l.call(t)}),a=()=>new Promise((l,c)=>o.then(()=>i[0]==="reject"?c(i[1]):l(i[1])).catch(c));return typeof n!="string"&&typeof n!="number"?{unwrap:a}:Object.assign(n,{unwrap:a})},this.custom=(e,t)=>{let n=(t==null?void 0:t.id)||rh++;return this.create({jsx:e(n),id:n,...t}),n},this.getActiveToasts=()=>this.toasts.filter(e=>!this.dismissedToasts.has(e.id)),this.subscribers=[],this.toasts=[],this.dismissedToasts=new Set}},ct=new AC,RC=(e,t)=>{let n=(t==null?void 0:t.id)||rh++;return ct.addToast({title:e,...t,id:n}),n},jC=e=>e&&typeof e=="object"&&"ok"in e&&typeof e.ok=="boolean"&&"status"in e&&typeof e.status=="number",NC=RC,OC=()=>ct.toasts,IC=()=>ct.getActiveToasts();Object.assign(NC,{success:ct.success,info:ct.info,warning:ct.warning,error:ct.error,custom:ct.custom,message:ct.message,promise:ct.promise,dismiss:ct.dismiss,loading:ct.loading},{getHistory:OC,getToasts:IC});function DC(e,{insertAt:t}={}){if(typeof document>"u")return;let n=document.head||document.getElementsByTagName("head")[0],r=document.createElement("style");r.type="text/css",t==="top"&&n.firstChild?n.insertBefore(r,n.firstChild):n.appendChild(r),r.styleSheet?r.styleSheet.cssText=e:r.appendChild(document.createTextNode(e))}DC(`: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;
185left: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}
185: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%);
185--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%)} 186`);function Ga(e){return e.label!==void 0}var LC=3,MC="32px",$C="16px",gg=4e3,VC=356,FC=14,UC=20,BC=200;function Bt(...e){return e.filter(Boolean).join(" ")}function zC(e){let[t,n]=e.split("-"),r=[];return t&&r.push(t),n&&r.push(n),r}var WC=e=>{var t,n,r,s,i,o,a,l,c,u,d;let{invert:h,toast:f,unstyled:w,interacting:y,setHeights:x,visibleToasts:m,heights:g,index:v,toasts:S,expanded:_,removeToast:k,defaultRichColors:E,closeButton:T,style:j,cancelButtonStyle:O,actionButtonStyle:U,className:M="",descriptionClassName:J="",duration:D,position:X,gap:K,loadingIcon:V,expandByDefault:C,classNames:A,icons:L,closeButtonAriaLabel:q="Close toast",pauseWhenPageIsHidden:B}=e,[Z,te]=I.useState(null),[Pe,Ge]=I.useState(null),[se,xs]=I.useState(!1),[Un,Ir]=I.useState(!1),[Bn,bs]=I.useState(!1),[zn,Ea]=I.useState(!1),[Qc,Ta]=I.useState(!1),[Jc,zi]=I.useState(0),[Ss,Bp]=I.useState(0),Wi=I.useRef(f.duration||D||gg),zp=I.useRef(null),Dr=I.useRef(null),BS=v===0,zS=v+1<=m,Tt=f.type,_s=f.dismissible!==!1,WS=f.className||"",HS=f.descriptionClassName||"",Ca=I.useMemo(()=>g.findIndex(G=>G.toastId===f.id)||0,[g,f.id]),KS=I.useMemo(()=>{var G;return(G=f.closeButton)!=null?G:T},[f.closeButton,T]),Wp=I.useMemo(()=>f.duration||D||gg,[f.duration,D]),Xc=I.useRef(0),ks=I.useRef(0),Hp=I.useRef(0),Es=I.useRef(null),[qS,GS]=X.split("-"),Kp=I.useMemo(()=>g.reduce((G,oe,fe)=>fe>=Ca?G:G+oe.height,0),[g,Ca]),qp=PC(),YS=f.invert||h,Zc=Tt==="loading";ks.current=I.useMemo(()=>Ca*K+Kp,[Ca,Kp]),I.useEffect(()=>{Wi.current=Wp},[Wp]),I.useEffect(()=>{xs(!0)},[]),I.useEffect(()=>{let G=Dr.current;if(G){let oe=G.getBoundingClientRect().height;return Bp(oe),x(fe=>[{toastId:f.id,height:oe,position:f.position},...fe]),()=>x(fe=>fe.filter($t=>$t.toastId!==f.id))}},[x,f.id]),I.useLayoutEffect(()=>{if(!se)return;let G=Dr.current,oe=G.style.height;G.style.height="auto";let fe=G.getBoundingClientRect().height;G.style.height=oe,Bp(fe),x($t=>$t.find(Vt=>Vt.toastId===f.id)?$t.map(Vt=>Vt.toastId===f.id?{...Vt,height:fe}:Vt):[{toastId:f.id,height:fe,position:f.position},...$t])},[se,f.title,f.description,x,f.id]);let Wn=I.useCallback(()=>
186{Ir(!0),zi(ks.current),x(G=>G.filter(oe=>oe.toastId!==f.id)),setTimeout(()=>{k(f)},BC)},[f,k,x,ks]);I.useEffect(()=>{if(f.promise&&Tt==="loading"||f.duration===1/0||f.type==="loading")return;let G;return _||y||B&&qp?(()=>{if(Hp.current<Xc.current){let oe=new Date().getTime()-Xc.current;Wi.current=Wi.current-oe}Hp.current=new Date().getTime()})():Wi.current!==1/0&&(Xc.current=new Date().getTime(),G=setTimeout(()=>{var oe;(oe=f.onAutoClose)==null||oe.call(f,f),Wn()},Wi.current)),()=>clearTimeout(G)},[_,y,f,Tt,B,qp,Wn]),I.useEffect(()=>{f.delete&&Wn()},[Wn,f.delete]);function QS(){var G,oe,fe;return L!=null&&L.loading?I.createElement("div",{className:Bt(A==null?void 0:A.loader,(G=f==null?void 0:f.classNames)==null?void 0:G.loader,"sonner-loader"),"data-visible":Tt==="loading"},L.loading):V?I.createElement("div",{className:Bt(A==null?void 0:A.loader,(oe=f==null?void 0:f.classNames)==null?void 0:oe.loader,"sonner-loader"),"data-visible":Tt==="loading"},V):I.createElement(SC,{className:Bt(A==null?void 0:A.loader,(fe=f==null?void 0:f.classNames)==null?void 0:fe.loader),visible:Tt==="loading"})}return I.createElement("li",{tabIndex:0,ref:Dr,className:Bt(M,WS,A==null?void 0:A.toast,(t=f==null?void 0:f.classNames)==null?void 0:t.toast,A==null?void 0:A.default,A==null?void 0:A[Tt],(n=f==null?void 0:f.classNames)==null?void 0:n[Tt]),"data-sonner-toast":"","data-rich-colors":(r=f.richColors)!=null?r:E,"data-styled":!(f.jsx||f.unstyled||w),"data-mounted":se,"data-promise":!!f.promise,"data-swiped":Qc,"data-removed":Un,"data-visible":zS,"data-y-position":qS,"data-x-position":GS,"data-index":v,"data-front":BS,"data-swiping":Bn,"data-dismissible":_s,"data-type":Tt,"data-invert":YS,"data-swipe-out":zn,"data-swipe-direction":Pe,"data-expanded":!!(_||C&&se),style:{"--index":v,"--toasts-before":v,"--z-index":S.length-v,"--offset":`${Un?Jc:ks.current}px`,"--initial-height":C?"auto":`${Ss}px`,...j,...f.style},onDragEnd:()=>{bs(!1),te(null),Es.current=null},onPointerDown:G=>{Zc||!_s||(zp.current=new Date,zi(ks.current),G.target.setPointerCapture(G.pointerId),G.target.tagName!=="BUTTON"&&(bs(!0),Es.current={x:G.clientX,y:G.clientY}))},onPointerUp:()=>{var G,oe,fe,$t;if(zn||!_s)return;Es.current=null;let Vt=Number(((G=Dr.current)==null?void 0:G.style.getPropertyValue("--swipe-amount-x").replace("px",""))||0),Hn=Number(((oe=Dr.current)==null?void 0:oe.style.getPropertyValue("--swipe-amount-y").replace("px",""))||0),Lr=new Date().getTime()-((fe=zp.current)==null?void 0:fe.getTime()),Ft=Z==="x"?Vt:Hn,Kn=Math.abs(Ft)/Lr;if(Math.abs(Ft)>=UC||Kn>.11){zi(ks.current),($t=f.onDismiss)==null||$t.call(f,f),Ge(Z==="x"?Vt>0?"right":"left":Hn>0?"down":"up"),Wn(),Ea(!0),Ta(!1);return}bs(!1),te(null)},onPointerMove:G=>{var oe,fe,$t,Vt;if(!Es.current||!_s||((oe=window.getSelection())==null?void 0:oe.toString().length)>0)return;let Hn=G.clientY-Es.current.y,Lr=G.clientX-Es.current.x,Ft=(fe=e.swipeDirections)!=null?fe:zC(X);!Z&&(Math.abs(Lr)>1||Math.abs(Hn)>1)&&te(Math.abs(Lr)>Math.abs(Hn)?"x":"y");let Kn={x:0,y:0};Z==="y"?(Ft.includes("top")||Ft.includes("bottom"))&&(Ft.includes("top")&&Hn<0||Ft.includes("bottom")&&Hn>0)&&(Kn.y=Hn):Z==="x"&&(Ft.includes("left")||Ft.includes("right"))&&(Ft.includes("left")&&Lr<0||Ft.includes("right")&&Lr>0)&&(Kn.x=Lr),(Math.abs(Kn.x)>0||Math.abs(Kn.y)>0)&&Ta(!0),($t=Dr.current)==null||$t.style.setProperty("--swipe-amount-x",`${Kn.x}px`),(Vt=Dr.current)==null||Vt.style.setProperty("--swipe-amount-y",`${Kn.y}px`)}},KS&&!f.jsx?I.createElement("button",{"aria-label":q,"data-disabled":Zc,"data-close-button":!0,onClick:Zc||!_s?()=>{}:()=>{var G;Wn(),(G=f.onDismiss)==null||G.call(f,f)},className:Bt(A==null?void 0:A.closeButton,(s=f==null?void 0:f.classNames)==null?void 0:s.closeButton)},(i=L==null?void 0:L.close)!=null?i:CC):null,f.jsx||b.isValidElement(f.title)?f.jsx?f.jsx:typeof f.title=="function"?f.title():f.title:I.createElement(I.Fragment,null,Tt||f.icon||f.promise?I.createElement("div",{"data-icon":"",className:Bt(A==null?void 0:A.icon,(o=f==null?void 0:f.classNames)==null?void 0:o.icon)},f.promise||f.type==="loading"&&!f.icon?f.icon||QS():null,f.type!=="loading"?f.icon||(L==null?void 0:L[Tt])||xC(Tt):null):null,I.createElement("div",{"data-content":"",className:Bt(A==null?void 0:A.content,(a=f==null?void 0:f.classNames)==null?void 0:a.content)},I.createElement("div",{"data-title":"",className:Bt(A==null?void 0:A.title,(l=f==null?void 0:f.classNames)==null?void 0:l.title)},typeof f.title=="function"?f.title():f.title),f.description?I.createElement("div",{"data-description":"",className:Bt(J,HS,A==null?void 0:A.description,(c=f==null?void 0:f.classNames)==null?void 0:c.description)},typeof f.description=="function"?f.description():f.description):null),b.isValidElement(f.cancel)?f.cancel:f.cancel&&Ga(f.cancel)?I.createElement("button",{"data-button":!0,"data-cancel":!0,style:f.cancelButtonStyle||O,onClick:G=>{var oe,fe;Ga(f.cancel)&&_s&&((fe=(oe=f.cancel).onClick)==null||fe.call(oe,G),Wn())},className:Bt(A==null?void 0:A.cancelButton,(u=f==null?void 0:f.classNames)==null?void 0:u.cancelButton)},f.cancel.label):null,b.isValidElement(f.action)?f.action:f.action&&Ga(f.action)?I.createElement("button",{"data-button":!0,"data-action":!0,style:f.actionButtonStyle||U,onClick:G=>{var oe,fe;Ga(f.action)&&((fe=(oe=f.action).onClick)==null||fe.call(oe,G),!G.defaultPrevented&&Wn())},className:Bt(A==null?void 0:A.actionButton,(d=f==null?void 0:f.classNames)==null?void 0:d.actionButton)},f.action.label):null))};function yg(){if(typeof window>"u"||typeof document>"u")return"ltr";let e=document.documentElement.getAttribute("dir");return e==="auto"||!e?window.getComputedStyle(document.documentElement).direction:e}function HC(e,t){let n={};return[e,t].forEach((r,s)=>{let i=s===1,o=i?"--mobile-offset":"--offset",a=i?$C:MC;function l(c){["top","right","bottom","left"].forEach(u=>{n[`${o}-${u}`]=typeof c=="number"?`${c}px`:c})}typeof r=="number"||typeof r=="string"?l(r):typeof r=="object"?["top","right","bottom","left"].forEach(c=>{r[c]===void 0?n[`${o}-${c}`]=a:n[`${o}-${c}`]=typeof r[c]=="number"?`${r[c]}px`:r[c]}):l(a)}),n}var KC=b.forwardRef(function(e,t){let{invert:n,position:r="bottom-right",hotkey:s=["altKey","KeyT"],expand:i,closeButton:o,className:a,offset:l,mobileOffset:c,theme:u="light",richColors:d,duration:h,style:f,visibleToasts:w=LC,toastOptions:y,dir:x=yg(),gap:m=FC,loadingIcon:g,icons:v,containerAriaLabel:S="Notifications",pauseWhenPageIsHidden:_}=e,[k,E]=I.useState([]),T=I.useMemo(()=>
vendor: 3,455 bytes, line 186
186Array.from(new Set([r].concat(k.filter(B=>B.position).map(B=>B.position)))),[k,r]),[j,O]=I.useState([]),[U,M]=I.useState(!1),[J,D]=I.useState(!1),[X,K]=I.useState(u!=="system"?u:typeof window<"u"&&window.matchMedia&&window.matchMedia("(prefers-color-scheme: dark)").matches?"dark":"light"),V=I.useRef(null),C=s.join("+").replace(/Key/g,"").replace(/Digit/g,""),A=I.useRef(null),L=I.useRef(!1),q=I.useCallback(B=>{E(Z=>{var te;return(te=Z.find(Pe=>Pe.id===B.id))!=null&&te.delete||ct.dismiss(B.id),Z.filter(({id:Pe})=>Pe!==B.id)})},[]);return I.useEffect(()=>ct.subscribe(B=>{if(B.dismiss){E(Z=>Z.map(te=>te.id===B.id?{...te,delete:!0}:te));return}setTimeout(()=>{Yw.flushSync(()=>{E(Z=>{let te=Z.findIndex(Pe=>Pe.id===B.id);return te!==-1?[...Z.slice(0,te),{...Z[te],...B},...Z.slice(te+1)]:[B,...Z]})})})}),[]),I.useEffect(()=>{if(u!=="system"){K(u);return}if(u==="system"&&(window.matchMedia&&window.matchMedia("(prefers-color-scheme: dark)").matches?K("dark"):K("light")),typeof window>"u")return;let B=window.matchMedia("(prefers-color-scheme: dark)");try{B.addEventListener("change",({matches:Z})=>{K(Z?"dark":"light")})}catch{B.addListener(({matches:te})=>{try{K(te?"dark":"light")}catch(Pe){console.error(Pe)}})}},[u]),I.useEffect(()=>{k.length<=1&&M(!1)},[k]),I.useEffect(()=>{let B=Z=>{var te,Pe;s.every(Ge=>Z[Ge]||Z.code===Ge)&&(M(!0),(te=V.current)==null||te.focus()),Z.code==="Escape"&&(document.activeElement===V.current||(Pe=V.current)!=null&&Pe.contains(document.activeElement))&&M(!1)};return document.addEventListener("keydown",B),()=>document.removeEventListener("keydown",B)},[s]),I.useEffect(()=>{if(V.current)return()=>{A.current&&(A.current.focus({preventScroll:!0}),A.current=null,L.current=!1)}},[V.current]),I.createElement("section",{ref:t,"aria-label":`${S} ${C}`,tabIndex:-1,"aria-live":"polite","aria-relevant":"additions text","aria-atomic":"false",suppressHydrationWarning:!0},T.map((B,Z)=>{var te;let[Pe,Ge]=B.split("-");return k.length?I.createElement("ol",{key:B,dir:x==="auto"?yg():x,tabIndex:-1,ref:V,className:a,"data-sonner-toaster":!0,"data-theme":X,"data-y-position":Pe,"data-lifted":U&&k.length>1&&!i,"data-x-position":Ge,style:{"--front-toast-height":`${((te=j[0])==null?void 0:te.height)||0}px`,"--width":`${VC}px`,"--gap":`${m}px`,...f,...HC(l,c)},onBlur:se=>{L.current&&!se.currentTarget.contains(se.relatedTarget)&&(L.current=!1,A.current&&(A.current.focus({preventScroll:!0}),A.current=null))},onFocus:se=>{se.target instanceof HTMLElement&&se.target.dataset.dismissible==="false"||L.current||(L.current=!0,A.current=se.relatedTarget)},onMouseEnter:()=>M(!0),onMouseMove:()=>M(!0),onMouseLeave:()=>{J||M(!1)},onDragEnd:()=>M(!1),onPointerDown:se=>{se.target instanceof HTMLElement&&se.target.dataset.dismissible==="false"||D(!0)},onPointerUp:()=>D(!1)},k.filter(se=>!se.position&&Z===0||se.position===B).map((se,xs)=>{var Un,Ir;return I.createElement(WC,{key:se.id,icons:v,index:xs,toast:se,defaultRichColors:d,duration:(Un=y==null?void 0:y.duration)!=null?Un:h,className:y==null?void 0:y.className,descriptionClassName:y==null?void 0:y.descriptionClassName,invert:n,visibleToasts:w,closeButton:(Ir=y==null?void 0:y.closeButton)!=null?Ir:o,interacting:J,position:B,style:y==null?void 0:y.style,unstyled:y==null?void 0:y.unstyled,classNames:y==null?void 0:y.classNames,cancelButtonStyle:y==null?void 0:y.cancelButtonStyle,actionButtonStyle:y==null?void 0:y.actionButtonStyle,removeToast:q,toasts:k.filter(Bn=>
vendor: 3,105 bytes, line 186
186Bn.position==se.position),heights:j.filter(Bn=>Bn.position==se.position),setHeights:O,expandByDefault:i,gap:m,loadingIcon:g,expanded:U,pauseWhenPageIsHidden:_,swipeDirections:e.swipeDirections})})):null}))});const qC=({...e})=>{const{theme:t="system"}=wC();return p.jsx(KC,{theme:t,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"}},...e})},GC=["top","right","bottom","left"],Tr=Math.min,vt=Math.max,Xl=Math.round,Ya=Math.floor,gn=e=>({x:e,y:e}),YC={left:"right",right:"left",bottom:"top",top:"bottom"},QC={start:"end",end:"start"};function sh(e,t,n){return vt(e,Tr(t,n))}function In(e,t){return typeof e=="function"?e(t):e}function Dn(e){return e.split("-")[0]}function Di(e){return e.split("-")[1]}function Gf(e){return e==="x"?"y":"x"}function Yf(e){return e==="y"?"height":"width"}const JC=new Set(["top","bottom"]);function fn(e){return JC.has(Dn(e))?"y":"x"}function Qf(e){return Gf(fn(e))}function XC(e,t,n){n===void 0&&(n=!1);const r=Di(e),s=Qf(e),i=Yf(s);let o=s==="x"?r===(n?"end":"start")?"right":"left":r==="start"?"bottom":"top";return t.reference[i]>t.floating[i]&&(o=Zl(o)),[o,Zl(o)]}function ZC(e){const t=Zl(e);return[ih(e),t,ih(t)]}function ih(e){return e.replace(/start|end/g,t=>QC[t])}const vg=["left","right"],wg=["right","left"],eP=["top","bottom"],tP=["bottom","top"];function nP(e,t,n){switch(e){case"top":case"bottom":return n?t?wg:vg:t?vg:wg;case"left":case"right":return t?eP:tP;default:return[]}}function rP(e,t,n,r){const s=Di(e);let i=nP(Dn(e),n==="start",r);return s&&(i=i.map(o=>o+"-"+s),t&&(i=i.concat(i.map(ih)))),i}function Zl(e){return e.replace(/left|right|bottom|top/g,t=>YC[t])}function sP(e){return{top:0,right:0,bottom:0,left:0,...e}}function Wx(e){return typeof e!="number"?sP(e):{top:e,right:e,bottom:e,left:e}}function ec(e){const{x:t,y:n,width:r,height:s}=e;return{width:r,height:s,top:n,left:t,right:t+r,bottom:n+s,x:t,y:n}}function xg(e,t,n){let{reference:r,floating:s}=e;const i=fn(t),o=Qf(t),a=Yf(o),l=Dn(t),c=i==="y",u=r.x+r.width/2-s.width/2,d=r.y+r.height/2-s.height/2,h=r[a]/2-s[a]/2;let f;switch(l){case"top":f={x:u,y:r.y-s.height};break;case"bottom":f={x:u,y:r.y+r.height};break;case"right":f={x:r.x+r.width,y:d};break;case"left":f={x:r.x-s.width,y:d};break;default:f={x:r.x,y:r.y}}switch(Di(t)){case"start":f[o]-=h*(n&&c?-1:1);break;case"end":f[o]+=h*(n&&c?-1:1);break}return f}const iP=async(e,t,n)=>{const{placement:r="bottom",strategy:s="absolute",middleware:i=[],platform:o}=n,a=i.filter(Boolean),l=await(o.isRTL==null?void 0:o.isRTL(t));let c=await o.getElementRects({reference:e,floating:t,strategy:s}),{x:u,y:d}=xg(c,r,l),h=r,f={},w=0;for(let y=0;y<a.length;y++){const{name:x,fn:m}=a[y],{x:g,y:v,data:S,reset:_}=await m({x:u,y:d,initialPlacement:r,placement:h,strategy:s,middlewareData:f,re
vendor: 16,748 bytes, line 186
186cts:c,platform:o,elements:{reference:e,floating:t}});u=g??u,d=v??d,f={...f,[x]:{...f[x],...S}},_&&w<=50&&(w++,typeof _=="object"&&(_.placement&&(h=_.placement),_.rects&&(c=_.rects===!0?await o.getElementRects({reference:e,floating:t,strategy:s}):_.rects),{x:u,y:d}=xg(c,h,l)),y=-1)}return{x:u,y:d,placement:h,strategy:s,middlewareData:f}};async function Wo(e,t){var n;t===void 0&&(t={});const{x:r,y:s,platform:i,rects:o,elements:a,strategy:l}=e,{boundary:c="clippingAncestors",rootBoundary:u="viewport",elementContext:d="floating",altBoundary:h=!1,padding:f=0}=In(t,e),w=Wx(f),x=a[h?d==="floating"?"reference":"floating":d],m=ec(await i.getClippingRect({element:(n=await(i.isElement==null?void 0:i.isElement(x)))==null||n?x:x.contextElement||await(i.getDocumentElement==null?void 0:i.getDocumentElement(a.floating)),boundary:c,rootBoundary:u,strategy:l})),g=d==="floating"?{x:r,y:s,width:o.floating.width,height:o.floating.height}:o.reference,v=await(i.getOffsetParent==null?void 0:i.getOffsetParent(a.floating)),S=await(i.isElement==null?void 0:i.isElement(v))?await(i.getScale==null?void 0:i.getScale(v))||{x:1,y:1}:{x:1,y:1},_=ec(i.convertOffsetParentRelativeRectToViewportRelativeRect?await i.convertOffsetParentRelativeRectToViewportRelativeRect({elements:a,rect:g,offsetParent:v,strategy:l}):g);return{top:(m.top-_.top+w.top)/S.y,bottom:(_.bottom-m.bottom+w.bottom)/S.y,left:(m.left-_.left+w.left)/S.x,right:(_.right-m.right+w.right)/S.x}}const oP=e=>({name:"arrow",options:e,async fn(t){const{x:n,y:r,placement:s,rects:i,platform:o,elements:a,middlewareData:l}=t,{element:c,padding:u=0}=In(e,t)||{};if(c==null)return{};const d=Wx(u),h={x:n,y:r},f=Qf(s),w=Yf(f),y=await o.getDimensions(c),x=f==="y",m=x?"top":"left",g=x?"bottom":"right",v=x?"clientHeight":"clientWidth",S=i.reference[w]+i.reference[f]-h[f]-i.floating[w],_=h[f]-i.reference[f],k=await(o.getOffsetParent==null?void 0:o.getOffsetParent(c));let E=k?k[v]:0;(!E||!await(o.isElement==null?void 0:o.isElement(k)))&&(E=a.floating[v]||i.floating[w]);const T=S/2-_/2,j=E/2-y[w]/2-1,O=Tr(d[m],j),U=Tr(d[g],j),M=O,J=E-y[w]-U,D=E/2-y[w]/2+T,X=sh(M,D,J),K=!l.arrow&&Di(s)!=null&&D!==X&&i.reference[w]/2-(D<M?O:U)-y[w]/2<0,V=K?D<M?D-M:D-J:0;return{[f]:h[f]+V,data:{[f]:X,centerOffset:D-X-V,...K&&{alignmentOffset:V}},reset:K}}}),aP=function(e){return e===void 0&&(e={}),{name:"flip",options:e,async fn(t){var n,r;const{placement:s,middlewareData:i,rects:o,initialPlacement:a,platform:l,elements:c}=t,{mainAxis:u=!0,crossAxis:d=!0,fallbackPlacements:h,fallbackStrategy:f="bestFit",fallbackAxisSideDirection:w="none",flipAlignment:y=!0,...x}=In(e,t);if((n=i.arrow)!=null&&n.alignmentOffset)return{};const m=Dn(s),g=fn(a),v=Dn(a)===a,S=await(l.isRTL==null?void 0:l.isRTL(c.floating)),_=h||(v||!y?[Zl(a)]:ZC(a)),k=w!=="none";!h&&k&&_.push(...rP(a,y,w,S));const E=[a,..._],T=await Wo(t,x),j=[];let O=((r=i.flip)==null?void 0:r.overflows)||[];if(u&&j.push(T[m]),d){const D=XC(s,o,S);j.push(T[D[0]],T[D[1]])}if(O=[...O,{placement:s,overflows:j}],!j.every(D=>D<=0)){var U,M;const D=(((U=i.flip)==null?void 0:U.index)||0)+1,X=E[D];if(X&&(!(d==="alignment"?g!==fn(X):!1)||O.every(C=>C.overflows[0]>0&&fn(C.placement)===g)))return{data:{index:D,overflows:O},reset:{placement:X}};let K=(M=O.filter(V=>V.overflows[0]<=0).sort((V,C)=>V.overflows[1]-C.overflows[1])[0])==null?void 0:M.placement;if(!K)switch(f){case"bestFit":{var J;const V=(J=O.filter(C=>{if(k){const A=fn(C.placement);return A===g||A==="y"}return!0}).map(C=>[C.placement,C.overflows.filter(A=>A>0).reduce((A,L)=>A+L,0)]).sort((C,A)=>C[1]-A[1])[0])==null?void 0:J[0];V&&(K=V);break}case"initialPlacement":K=a;break}if(s!==K)return{reset:{placement:K}}}return{}}}};function bg(e,t){return{top:e.top-t.height,right:e.right-t.width,bottom:e.bottom-t.height,left:e.left-t.width}}function Sg(e){return GC.some(t=>e[t]>=0)}const lP=function(e){return e===void 0&&(e={}),{name:"hide",options:e,async fn(t){const{rects:n}=t,{strategy:r="referenceHidden",...s}=In(e,t);switch(r){case"referenceHidden":{const i=await Wo(t,{...s,elementContext:"reference"}),o=bg(i,n.reference);return{data:{referenceHiddenOffsets:o,referenceHidden:Sg(o)}}}case"escaped":{const i=await Wo(t,{...s,altBoundary:!0}),o=bg(i,n.floating);return{data:{escapedOffsets:o,escaped:Sg(o)}}}default:return{}}}}},Hx=new Set(["left","top"]);async function cP(e,t){const{placement:n,platform:r,elements:s}=e,i=await(r.isRTL==null?void 0:r.isRTL(s.floating)),o=Dn(n),a=Di(n),l=fn(n)==="y",c=Hx.has(o)?-1:1,u=i&&l?-1:1,d=In(t,e);let{mainAxis:h,crossAxis:f,alignmentAxis:w}=typeof d=="number"?{mainAxis:d,crossAxis:0,alignmentAxis:null}:{mainAxis:d.mainAxis||0,crossAxis:d.crossAxis||0,alignmentAxis:d.alignmentAxis};return a&&typeof w=="number"&&(f=a==="end"?w*-1:w),l?{x:f*u,y:h*c}:{x:h*c,y:f*u}}const uP=function(e){return e===void 0&&(e=0),{name:"offset",options:e,async fn(t){var n,r;const{x:s,y:i,placement:o,middlewareData:a}=t,l=await cP(t,e);return o===((n=a.offset)==null?void 0:n.placement)&&(r=a.arrow)!=null&&r.alignmentOffset?{}:{x:s+l.x,y:i+l.y,data:{...l,placement:o}}}}},dP=function(e){return e===void 0&&(e={}),{name:"shift",options:e,async fn(t){const{x:n,y:r,placement:s}=t,{mainAxis:i=!0,crossAxis:o=!1,limiter:a={fn:x=>{let{x:m,y:g}=x;return{x:m,y:g}}},...l}=In(e,t),c={x:n,y:r},u=await Wo(t,l),d=fn(Dn(s)),h=Gf(d);let f=c[h],w=c[d];if(i){const x=h==="y"?"top":"left",m=h==="y"?"bottom":"right",g=f+u[x],v=f-u[m];f=sh(g,f,v)}if(o){const x=d==="y"?"top":"left",m=d==="y"?"bottom":"right",g=w+u[x],v=w-u[m];w=sh(g,w,v)}const y=a.fn({...t,[h]:f,[d]:w});return{...y,data:{x:y.x-n,y:y.y-r,enabled:{[h]:i,[d]:o}}}}}},hP=function(e){return e===void 0&&(e={}),{options:e,fn(t){const{x:n,y:r,placement:s,rects:i,middlewareData:o}=t,{offset:a=0,mainAxis:l=!0,crossAxis:c=!0}=In(e,t),u={x:n,y:r},d=fn(s),h=Gf(d);let f=u[h],w=u[d];const y=In(a,t),x=typeof y=="number"?{mainAxis:y,crossAxis:0}:{mainAxis:0,crossAxis:0,...y};if(l){const v=h==="y"?"height":"width",S=i.reference[h]-i.floating[v]+x.mainAxis,_=i.reference[h]+i.reference[v]-x.mainAxis;f<S?f=S:f>_&&(f=_)}if(c){var m,g;const v=h==="y"?"width":"height",S=Hx.has(Dn(s)),_=i.reference[d]-i.floating[v]+(S&&((m=o.offset)==null?void 0:m[d])||0)+(S?0:x.crossAxis),k=i.reference[d]+i.reference[v]+(S?0:((g=o.offset)==null?void 0:g[d])||0)-(S?x.crossAxis:0);w<_?w=_:w>k&&(w=k)}return{[h]:f,[d]:w}}}},fP=function(e){return e===void 0&&(e={}),{name:"size",options:e,async fn(t){var n,r;const{placement:s,rects:i,platform:o,elements:a}=t,{apply:l=()=>{},...c}=In(e,t),u=await Wo(t,c),d=Dn(s),h=Di(s),f=fn(s)==="y",{width:w,height:y}=i.floating;let x,m;d==="top"||d==="bottom"?(x=d,m=h===(await(o.isRTL==null?void 0:o.isRTL(a.floating))?"start":"end")?"left":"right"):(m=d,x=h==="end"?"top":"bottom");const g=y-u.top-u.bottom,v=w-u.left-u.right,S=Tr(y-u[x],g),_=Tr(w-u[m],v),k=!t.middlewareData.shift;let E=S,T=_;if((n=t.middlewareData.shift)!=null&&n.enabled.x&&(T=v),(r=t.middlewareData.shift)!=null&&r.enabled.y&&(E=g),k&&!h){const O=vt(u.left,0),U=vt(u.right,0),M=vt(u.top,0),J=vt(u.bottom,0);f?T=w-2*(O!==0||U!==0?O+U:vt(u.left,u.right)):E=y-2*(M!==0||J!==0?M+J:vt(u.top,u.bottom))}await l({...t,availableWidth:T,availableHeight:E});const j=await o.getDimensions(a.floating);return w!==j.width||y!==j.height?{reset:{rects:!0}}:{}}}};function Oc(){return typeof window<"u"}function Li(e){return Kx(e)?(e.nodeName||"").toLowerCase():"#document"}function bt(e){var t;return(e==null||(t=e.ownerDocument)==null?void 0:t.defaultView)||window}function xn(e){var t;return(t=(Kx(e)?e.ownerDocument:e.document)||window.document)==null?void 0:t.documentElement}function Kx(e){return Oc()?e instanceof Node||e instanceof bt(e).Node:!1}function rn(e){return Oc()?e instanceof Element||e instanceof bt(e).Element:!1}function wn(e){return Oc()?e instanceof HTMLElement||e instanceof bt(e).HTMLElement:!1}function _g(e){return!Oc()||typeof ShadowRoot>"u"?!1:e instanceof ShadowRoot||e instanceof bt(e).ShadowRoot}const pP=new Set(["inline","contents"]);function ya(e){const{overflow:t,overflowX:n,overflowY:r,display:s}=sn(e);return/auto|scroll|overlay|hidden|clip/.test(t+r+n)&&!pP.has(s)}const mP=new Set(["table","td","th"]);function gP(e){return mP.has(Li(e))}const yP=[":popover-open",":modal"];function Ic(e){return yP.some(t=>{try{return e.matches(t)}catch{return!1}})}const vP=["transform","translate","scale","rotate","perspective"],wP=["transform","translate","scale","rotate","perspective","filter"],xP=["paint","layout","strict","content"];function Jf(e){const t=Xf(),n=rn(e)?sn(e):e;return vP.some(r=>n[r]?n[r]!=="none":!1)||(n.containerType?n.containerType!=="normal":!1)||!t&&(n.backdropFilter?n.backdropFilter!=="none":!1)||!t&&(n.filter?n.filter!=="none":!1)||wP.some(r=>(n.willChange||"").includes(r))||xP.some(r=>(n.contain||"").includes(r))}function bP(e){let t=Cr(e);for(;wn(t)&&!Ci(t);){if(Jf(t))return t;if(Ic(t))return null;t=Cr(t)}return null}function Xf(){return typeof CSS>"u"||!CSS.supports?!1:CSS.supports("-webkit-backdrop-filter","none")}const SP=new Set(["html","body","#document"]);function Ci(e){return SP.has(Li(e))}function sn(e){return bt(e).getComputedStyle(e)}function Dc(e){return rn(e)?{scrollLeft:e.scrollLeft,scrollTop:e.scrollTop}:{scrollLeft:e.scrollX,scrollTop:e.scrollY}}function Cr(e){if(Li(e)==="html")return e;const t=e.assignedSlot||e.parentNode||_g(e)&&e.host||xn(e);return _g(t)?t.host:t}function qx(e){const t=Cr(e);return Ci(t)?e.ownerDocument?e.ownerDocument.body:e.body:wn(t)&&ya(t)?t:qx(t)}function Ho(e,t,n){var r;t===void 0&&(t=[]),n===void 0&&(n=!0);const s=qx(e),i=s===((r=e.ownerDocument)==null?void 0:r.body),o=bt(s);if(i){const a=oh(o);return t.concat(o,o.visualViewport||[],ya(s)?s:[],a&&n?Ho(a):[])}return t.concat(s,Ho(s,[],n))}function oh(e){return e.parent&&Object.getPrototypeOf(e.parent)?e.frameElement:null}function Gx(e){const t=sn(e);let n=parseFloat(t.width)||0,r=parseFloat(t.height)||0;const s=wn(e),i=s?e.offsetWidth:n,o=s?e.offsetHeight:r,a=Xl(n)!==i||Xl(r)!==o;return a&&(n=i,r=o),{width:n,height:r,$:a}}function Zf(e){return rn(e)?e:e.contextElement}function ci(e){const t=Zf(e);if(!wn(t))return gn(1);const n=t.getBoundingClientRect(),{width:r,height:s,$:i}=Gx(t);let o=(i?Xl(n.width):n.width)/r,a=(i?Xl(n.height):n.height)/s;return(!o||!Number.isFinite(o))&&(o=1),(!a||!Number.isFinite(a))&&(a=1),{x:o,y:a}}const _P=gn(0);function Yx(e){const t=bt(e);return!Xf()||!t.visualViewport?_P:{x:t.visualViewport.offsetLeft,y:t.visualViewport.offsetTop}}function kP(e,t,n){return t===void 0&&(t=!1),!n||t&&n!==bt(e)?!1:t}function gs(e,t,n,r){t===void 0&&(t=!1),n===void 0&&(n=!1);const s=e.getBoundingClientRect(),i=Zf(e);let o=gn(1);t&&(r?rn(r)&&(o=ci(r)):o=ci(e));const a=kP(i,n,r)?Yx(i):gn(0);let l=(s.left+a.x)/o.x,c=(s.top+a.y)/o.y,u=s.width/o.x,d=s.height/o.y;if(i){const h=bt(i),f=r&&rn(r)?bt(r):r;let w=h,y=oh(w);for(;y&&r&&f!==w;){const x=ci(y),m=y.getBoundingClientRect(),g=sn(y),v=m.left+(y.clientLeft+parseFloat(g.paddingLeft))*x.x,S=m.top+(y.clientTop+parseFloat(g.paddingTop))*x.y;l*=x.x,c*=x.y,u*=x.x,d*=x.y,l+=v,c+=S,w=bt(y),y=oh(w)}}return ec({width:u,height:d,x:l,y:c})}function ep(e,t){const n=Dc(e).scrollLeft;return t?t.left+n:gs(xn(e)).left+n}function Qx(e,t,n){n===void 0&&(n=!1);const r=e.getBoundingClientRect(),s=r.left+t.scrollLeft-(n?0:ep(e,r)),i=r.top+t.scrollTop;return{x:s,y:i}}function EP(e){let{elements:t,rect:n,offsetParent:r,strategy:s}=e;const i=s==="fixed",o=xn(r),a=t?Ic(t.floating):!1;if(r===o||a&&i)return n;let l={scrollLeft:0,scrollTop:0},c=gn(1);const u=gn(0),d=wn(r);if((d||!d&&!i)&&((Li(r)!=="body"||ya(o))&&(l=Dc(r)),wn(r))){const f=gs(r);c=ci(r),u.x=f.x+r.clientLeft,u.y=f.y+r.clientTop}const h=o&&!d&&!i?Qx(o,l,!0):gn(0);return{width:n.width*c.x,height:n.height*c.y,x:n.x*c.x-l.scrollLeft*c.x+u.x+h.x,y:n.y*c.y-l.scrollTop*c.y+u.y+h.y}}function TP(e){return Array.from(e.getClientRects())}function CP(e){const t=xn(e),n=Dc(e),r=e.ownerDocument.body,s=vt(t.scrollWidth,t.clientWidth,r.scrollWidth,r.clientWidth),i=vt(t.scrollHeight,t.clientHeight,r.scrollHeight,r.clientHeight);let o=-n.scrollLeft+ep(e);const a=-n.scrollTop;return sn(r).direction==="rtl"&&(o+=vt(t.clientWidth,r.clientWidth)-s),{width:s,height:i,x:o,y:a}}function PP(e,t){const n=bt(e),r=xn(e),s=n.visualViewport;let i=r.clientWidth,o=r.clientHeight,a=0,l=0;if(s){i=s.width,o=s.height;const c=Xf();(!c||c&&t==="fixed")&&(a=s.offsetLeft,l=s.offsetTop)}return{width:i,height:o,x:a,y:l}}const AP=new Set(["absolute","fixed"]);function RP(e,t){const n=gs(e,!0,t==="fixed"),r=n.top+e.clientTop,s=n.left+e.clientLeft,i=wn(e)?ci(e):gn(1),o=e.clientWidth*i.x,a=e.clientHeight*i.y,l=s*i.x,c=r*i.y;return{width:o,height:a,x:l,y:c}}function kg(e,t,n){let r;if(t==="viewport")r=PP(e,n);else if(t==="document")r=CP(xn(e));else if(rn(t))r=RP(t,n);else{const s=Yx(e);r={x:t.x-s.x,y:t.y-s.y,width:t.width,height:t.height}}return ec(r)}function Jx(e,t){const n=Cr(e);return n===t||!rn(n)||Ci(n)?!1:sn(n).position==="fixed"||Jx(n,t)}function jP(e,t){const n=t.get(e);if(n)return n;let r=Ho(e,[],!1).filter(a=>rn(a)&&Li(a)!=="body"),s=null;const i=sn(e).position==="fixed";let o=i?Cr(e):e;for(;rn(o)&&!Ci(o);){const a=sn(o),l=Jf(o);!l&&a.position==="fixed"&&(s=null),(i?!l&&!s:!l&&a.position==="static"&&!!s&&AP.has(s.position)||ya(o)&&!l&&Jx(e,o))?r=r.filter(u=>u!==o):s=a,o=Cr(o)}return t.set(e,r),r}function NP(e){let{element:t,boundary:n,rootBoundary:r,strategy:s}=e;const o=[...n==="clippingAncestors"?Ic(t)?[]:jP(t,this._c):[].concat(n),r],a=o[0],l=o.reduce((c,u)=>{const d=kg(t,u,s);return c.top=vt(d.top,c.top),c.right=Tr(d.right,c.right),c.bottom=Tr(d.bottom,c.bottom),c.left=vt(d.left,c.left),c},kg(t,a,s));return{width:l.right-l.left,height:l.bottom-l.top,x:l.left,y:l.top}}function OP(e){const{width:t,height:n}=Gx(e);return{width:t,height:n}}function IP(e,t,n){const r=wn(t),s=xn(t),i=n==="fixed",o=gs(e,!0,i,t);let a={scrollLeft:0,scrollTop:0};const l=gn(0);function c(){l.x=ep(s)}if(r||!r&&!i)if((Li(t)!=="body"||ya(s))&&(a=Dc(t)),r){const f=gs(t,!0,i,t);l.x=f.x+t.clientLeft,l.y=f.y+t.clientTop}else s&&c();i&&!r&&s&&c();const u=s&&!r&&!i?Qx(s,a):gn(0),d=o.left+a.scrollLeft-l.x-u.x,h=o.top+a.scrollTop-l.y-u.y;return{x:d,y:h,width:o.width,height:o.height}}function ju(e){return sn(e).position==="static"}function Eg(e,t){if(!wn(e)||sn(e).position==="fixed")return null;if(t)return t(e);let n=e.offsetParent;return xn(e)===n&&(n=n.ownerDocument.body),n}function Xx(e,t){const n=bt(e);if(Ic(e))return n;if(!wn(e)){let s=Cr(e);for(;s&&!Ci(s);){if(rn(s)&&!ju(s))return s;s=Cr(s)}return n}let r=Eg(e,t);for(;r&&gP(r)&&ju(r);)r=Eg(r,t);return r&&Ci(r)&&ju(r)&&!Jf(r)?n:r||bP(e)||n}const DP=async function(e){const t=this.getOffsetParent||Xx,n=this.getDimensions,r=await n(e.floating);return{reference:IP(e.reference,await t(e.floating),e.strategy),floating:{x:0,y:0,width:r.width,height:r.height}}};function LP(e){return sn(e).direction==="rtl"}const MP={convertOffsetParentRelativeRectToViewportRelativeRect:EP,getDocumentElement:xn,getClippingRect:NP,getOffsetParent:Xx,getElementRects:DP,getClientRects:TP,getDimensions:OP,getScale:ci,isElement:rn,isRTL:LP};function Zx(e,t){return e.x===t.x&&e.y===t.y&&e.width===t.width&&e.height===t.height}function $P(e,t){let n=null,r;const s=xn(e);function i(){var a;clearTimeout(r),(a=n)==null||a.disconnect(),n=null}function o(a,l){a===void 0&&(a=!1),l===void 0&&(l=1),i();const c=e.getBoundingClientRect(),{left:u,top:d,width:h,height:f}=c;if(a||t(),!h||!f)return;const w=Ya(d),y=Ya(s.clientWidth-(u+h)),x=Ya(s.clientHeight-(d+f)),m=Ya(u),v={rootMargin:-w+"px "+-y+"px "+-x+"px "+-m+"px",threshold:vt(0,Tr(1,l))||1};let S=!0;function _(k){const E=k[0].intersectionRatio;if(E!==l){if(!S)return o();E?o(!1,E):r=setTimeout(()=>{o(!1,1e-7)},1e3)}E===1&&!Zx(c,e.getBoundingClientRect())&&o(),S=!1}try{n=new IntersectionObserver(_,{...v,root:s.ownerDocument})}catch{n=new IntersectionObserver(_,v)}n.observe(e)}return o(!0),i}function VP(e,t,n,r){r===void 0&&(r={});const{ancestorScroll:s=!0,ancestorResize:i=!0,elementResize:o=typeof ResizeObserver=="function",layoutShift:a=typeof IntersectionObserver=="function",animationFrame:l=!1}=r,c=Zf(e),u=s||i?[...c?Ho(c):[],...Ho(t)]:[];u.forEach(m=>{s&&m.addEventListener("scroll",n,{passive:!0}),i&&m.addEventListener("resize",n)});const d=c&&a?$P(c,n):null;let h=-1,f=null;o&&(f=new ResizeObserver(m=>{let[g]=m;g&&g.target===c&&f&&(f.unobserve(t),cancelAnimationFrame(h),h=requestAnimationFrame(()=>{var v;(v=f)==null||v.observe(t)})),n()}),c&&!l&&f.observe(c),f.observe(t));let w,y=l?gs(e):null;l&&x();function x(){const m=gs(e);y&&!Zx(y,m)&&n(),y=m,w=requestAnimationFrame(x)}return n(),()=>{var m;u.forEach(g=>{s&&g.removeEventListener("scroll",n),i&&g.removeEventListener("resize",n)}),d==null||d(),(m=f)==null||m.disconnect(),f=null,l&&cancelAnimationFrame(w)}}
vendor: 4,171 bytes, line 186
186const FP=uP,UP=dP,BP=aP,zP=fP,WP=lP,Tg=oP,HP=hP,KP=(e,t,n)=>{const r=new Map,s={platform:MP,...n},i={...s.platform,_c:r};return iP(e,t,{...s,platform:i})};var qP=typeof document<"u",GP=function(){},bl=qP?b.useLayoutEffect:GP;function tc(e,t){if(e===t)return!0;if(typeof e!=typeof t)return!1;if(typeof e=="function"&&e.toString()===t.toString())return!0;let n,r,s;if(e&&t&&typeof e=="object"){if(Array.isArray(e)){if(n=e.length,n!==t.length)return!1;for(r=n;r--!==0;)if(!tc(e[r],t[r]))return!1;return!0}if(s=Object.keys(e),n=s.length,n!==Object.keys(t).length)return!1;for(r=n;r--!==0;)if(!{}.hasOwnProperty.call(t,s[r]))return!1;for(r=n;r--!==0;){const i=s[r];if(!(i==="_owner"&&e.$$typeof)&&!tc(e[i],t[i]))return!1}return!0}return e!==e&&t!==t}function eb(e){return typeof window>"u"?1:(e.ownerDocument.defaultView||window).devicePixelRatio||1}function Cg(e,t){const n=eb(e);return Math.round(t*n)/n}function Nu(e){const t=b.useRef(e);return bl(()=>{t.current=e}),t}function YP(e){e===void 0&&(e={});const{placement:t="bottom",strategy:n="absolute",middleware:r=[],platform:s,elements:{reference:i,floating:o}={},transform:a=!0,whileElementsMounted:l,open:c}=e,[u,d]=b.useState({x:0,y:0,strategy:n,placement:t,middlewareData:{},isPositioned:!1}),[h,f]=b.useState(r);tc(h,r)||f(r);const[w,y]=b.useState(null),[x,m]=b.useState(null),g=b.useCallback(C=>{C!==k.current&&(k.current=C,y(C))},[]),v=b.useCallback(C=>{C!==E.current&&(E.current=C,m(C))},[]),S=i||w,_=o||x,k=b.useRef(null),E=b.useRef(null),T=b.useRef(u),j=l!=null,O=Nu(l),U=Nu(s),M=Nu(c),J=b.useCallback(()=>{if(!k.current||!E.current)return;const C={placement:t,strategy:n,middleware:h};U.current&&(C.platform=U.current),KP(k.current,E.current,C).then(A=>{const L={...A,isPositioned:M.current!==!1};D.current&&!tc(T.current,L)&&(T.current=L,pa.flushSync(()=>{d(L)}))})},[h,t,n,U,M]);bl(()=>{c===!1&&T.current.isPositioned&&(T.current.isPositioned=!1,d(C=>({...C,isPositioned:!1})))},[c]);const D=b.useRef(!1);bl(()=>(D.current=!0,()=>{D.current=!1}),[]),bl(()=>{if(S&&(k.current=S),_&&(E.current=_),S&&_){if(O.current)return O.current(S,_,J);J()}},[S,_,J,O,j]);const X=b.useMemo(()=>({reference:k,floating:E,setReference:g,setFloating:v}),[g,v]),K=b.useMemo(()=>({reference:S,floating:_}),[S,_]),V=b.useMemo(()=>{const C={position:n,left:0,top:0};if(!K.floating)return C;const A=Cg(K.floating,u.x),L=Cg(K.floating,u.y);return a?{...C,transform:"translate("+A+"px, "+L+"px)",...eb(K.floating)>=1.5&&{willChange:"transform"}}:{position:n,left:A,top:L}},[n,a,K.floating,u.x,u.y]);return b.useMemo(()=>({...u,update:J,refs:X,elements:K,floatingStyles:V}),[u,J,X,K,V])}const QP=e=>{function t(n){return{}.hasOwnProperty.call(n,"current")}return{name:"arrow",options:e,fn(n){const{element:r,padding:s}=typeof e=="function"?e(n):e;return r&&t(r)?r.current!=null?Tg({element:r.current,padding:s}).fn(n):{}:r?Tg({element:r,padding:s}).fn(n):{}}}},JP=(e,t)=>({...FP(e),options:[e,t]}),XP=(e,t)=>({...UP(e),options:[e,t]}),ZP=(e,t)=>({...HP(e),options:[e,t]}),eA=(e,t)=>({...BP(e),options:[e,t]}),tA=(e,t)=>({...zP(e),options:[e,t]}),nA=(e,t)=>({...WP(e),options:[e,t]}),rA=(e,t)=>({...QP(e),options:[e,t]});var sA="Arrow",tb=b.forwardRef((e,t)=>{const{children:n,width:r=10,height:s=5,...i}=e;return p.jsx(qe.svg,{...i,ref:t,width:r,height:s,viewBox:"0 0 30 10",preserveAspectRatio:"none",children:e.asChild?n:p.jsx("polygon",{points:"0,0 30,0 15,10"})})});tb.displayName=sA;var iA=tb;function nb(e){const[t,n]=b.useState(void 0);return Er(()=>{if(e){n({width:e.offsetWidth,height:e.offsetHeight});const r=new ResizeObserver(s=>{if(!Array.isArray(s)||!s.length)return;const i=s[0];let o,a;if("borderBoxSize"in i){const l=i.borderBoxSize,c=Array.isArray(l)?l[0]:l;o=c.inlineSize,a=c.blockSize}else o=e.offsetWidth,a=e.offsetHeight;n({width:o,height:a})});return r.observe(e,{box:"border-box"}),()=>r.unobserve(e)}else n(void 0)},[e]),t}var rb="Popper",[sb,ib]=ma(rb),[NM,ob]=sb(rb),ab="PopperAnchor",lb=b.forwardRef((e,t)=>{const{__scopePopper:n,virtualRef:r,...s}=e,i=ob(ab,n),o=b.useRef(null),a=_t(t,o);return b.useEffect(()=>{i.onAnchorChange((r==null?void 0:r.current)||o.current)}),r?null:p.jsx(qe.div,{...s,ref:a})});
vendor: 4,287 bytes, line 186
186lb.displayName=ab;var tp="PopperContent",[oA,aA]=sb(tp),cb=b.forwardRef((e,t)=>{var se,xs,Un,Ir,Bn,bs;const{__scopePopper:n,side:r="bottom",sideOffset:s=0,align:i="center",alignOffset:o=0,arrowPadding:a=0,avoidCollisions:l=!0,collisionBoundary:c=[],collisionPadding:u=0,sticky:d="partial",hideWhenDetached:h=!1,updatePositionStrategy:f="optimized",onPlaced:w,...y}=e,x=ob(tp,n),[m,g]=b.useState(null),v=_t(t,zn=>g(zn)),[S,_]=b.useState(null),k=nb(S),E=(k==null?void 0:k.width)??0,T=(k==null?void 0:k.height)??0,j=r+(i!=="center"?"-"+i:""),O=typeof u=="number"?u:{top:0,right:0,bottom:0,left:0,...u},U=Array.isArray(c)?c:[c],M=U.length>0,J={padding:O,boundary:U.filter(cA),altBoundary:M},{refs:D,floatingStyles:X,placement:K,isPositioned:V,middlewareData:C}=YP({strategy:"fixed",placement:j,whileElementsMounted:(...zn)=>VP(...zn,{animationFrame:f==="always"}),elements:{reference:x.anchor},middleware:[JP({mainAxis:s+T,alignmentAxis:o}),l&&XP({mainAxis:!0,crossAxis:!1,limiter:d==="partial"?ZP():void 0,...J}),l&&eA({...J}),tA({...J,apply:({elements:zn,rects:Ea,availableWidth:Qc,availableHeight:Ta})=>{const{width:Jc,height:zi}=Ea.reference,Ss=zn.floating.style;Ss.setProperty("--radix-popper-available-width",`${Qc}px`),Ss.setProperty("--radix-popper-available-height",`${Ta}px`),Ss.setProperty("--radix-popper-anchor-width",`${Jc}px`),Ss.setProperty("--radix-popper-anchor-height",`${zi}px`)}}),S&&rA({element:S,padding:a}),uA({arrowWidth:E,arrowHeight:T}),h&&nA({strategy:"referenceHidden",...J})]}),[A,L]=hb(K),q=kr(w);Er(()=>{V&&(q==null||q())},[V,q]);const B=(se=C.arrow)==null?void 0:se.x,Z=(xs=C.arrow)==null?void 0:xs.y,te=((Un=C.arrow)==null?void 0:Un.centerOffset)!==0,[Pe,Ge]=b.useState();return Er(()=>{m&&Ge(window.getComputedStyle(m).zIndex)},[m]),p.jsx("div",{ref:D.setFloating,"data-radix-popper-content-wrapper":"",style:{...X,transform:V?X.transform:"translate(0, -200%)",minWidth:"max-content",zIndex:Pe,"--radix-popper-transform-origin":[(Ir=C.transformOrigin)==null?void 0:Ir.x,(Bn=C.transformOrigin)==null?void 0:Bn.y].join(" "),...((bs=C.hide)==null?void 0:bs.referenceHidden)&&{visibility:"hidden",pointerEvents:"none"}},dir:e.dir,children:p.jsx(oA,{scope:n,placedSide:A,onArrowChange:_,arrowX:B,arrowY:Z,shouldHideArrow:te,children:p.jsx(qe.div,{"data-side":A,"data-align":L,...y,ref:v,style:{...y.style,animation:V?void 0:"none"}})})})});cb.displayName=tp;var ub="PopperArrow",lA={top:"bottom",right:"left",bottom:"top",left:"right"},db=b.forwardRef(function(t,n){const{__scopePopper:r,...s}=t,i=aA(ub,r),o=lA[i.placedSide];return p.jsx("span",{ref:i.onArrowChange,style:{position:"absolute",left:i.arrowX,top:i.arrowY,[o]:0,transformOrigin:{top:"",right:"0 0",bottom:"center 0",left:"100% 0"}[i.placedSide],transform:{top:"translateY(100%)",right:"translateY(50%) rotate(90deg) translateX(-50%)",bottom:"rotate(180deg)",left:"translateY(50%) rotate(-90deg) translateX(50%)"}[i.placedSide],visibility:i.shouldHideArrow?"hidden":void 0},children:p.jsx(iA,{...s,ref:n,style:{...s.style,display:"block"}})})});db.displayName=ub;function cA(e){return e!==null}var uA=e=>({name:"transformOrigin",options:e,fn(t){var x,m,g;const{placement:n,rects:r,middlewareData:s}=t,o=((x=s.arrow)==null?void 0:x.centerOffset)!==0,a=o?0:e.arrowWidth,l=o?0:e.arrowHeight,[c,u]=hb(n),d={start:"0%",center:"50%",end:"100%"}[u],h=(((m=s.arrow)==null?void 0:m.x)??0)+a/2,f=(((g=s.arrow)==null?void 0:g.y)??0)+l/2;let w="",y="";return c==="bottom"?(w=o?d:`${h}px`,y=`${-l}px`):c==="top"?(w=o?d:`${h}px`,y=`${r.floating.height+l}px`):c==="right"?(w=`${-l}px`,y=o?d:`${f}px`):c==="left"&&(w=`${r.floating.width+l}px`,y=o?d:`${f}px`),{data:{x:w,y}}}});function hb(e){const[t,n="center"]=e.split("-");return[t,n]}var dA=lb,hA=cb,fA=db,[Lc,OM]=ma("Tooltip",[ib]),np=ib(),fb="TooltipProvider",pA=700,Pg="tooltip.open",[mA,pb]=Lc(fb),mb=e=>{const{__scopeTooltip:t,delayDuration:n=pA,skipDelayDuration:r=300,disableHoverableContent:s=!1,children:i}=e,o=b.useRef(!0),a=b.useRef(!1),l=b.useRef(0);return b.useEffect(()=>{const c=l.current;return()=>window.clearTimeout(c)},[]),p.jsx(mA,{scope:t,isOpenDelayedRef:o,delayDuration:n,onOpen:b.useCallback(()=>{window.clearTimeout(l.current),o.current=!1},[]),onClose:b.useCallback(()=>{window.clearTimeout(l.current),l.current=window.setTimeout(()=>
vendor: 5,382 bytes, line 186
186o.current=!0,r)},[r]),isPointerInTransitRef:a,onPointerInTransitChange:b.useCallback(c=>{a.current=c},[]),disableHoverableContent:s,children:i})};mb.displayName=fb;var gb="Tooltip",[IM,Mc]=Lc(gb),ah="TooltipTrigger",gA=b.forwardRef((e,t)=>{const{__scopeTooltip:n,...r}=e,s=Mc(ah,n),i=pb(ah,n),o=np(n),a=b.useRef(null),l=_t(t,a,s.onTriggerChange),c=b.useRef(!1),u=b.useRef(!1),d=b.useCallback(()=>c.current=!1,[]);return b.useEffect(()=>()=>document.removeEventListener("pointerup",d),[d]),p.jsx(dA,{asChild:!0,...o,children:p.jsx(qe.button,{"aria-describedby":s.open?s.contentId:void 0,"data-state":s.stateAttribute,...r,ref:l,onPointerMove:Ce(e.onPointerMove,h=>{h.pointerType!=="touch"&&!u.current&&!i.isPointerInTransitRef.current&&(s.onTriggerEnter(),u.current=!0)}),onPointerLeave:Ce(e.onPointerLeave,()=>{s.onTriggerLeave(),u.current=!1}),onPointerDown:Ce(e.onPointerDown,()=>{s.open&&s.onClose(),c.current=!0,document.addEventListener("pointerup",d,{once:!0})}),onFocus:Ce(e.onFocus,()=>{c.current||s.onOpen()}),onBlur:Ce(e.onBlur,s.onClose),onClick:Ce(e.onClick,s.onClose)})})});gA.displayName=ah;var yA="TooltipPortal",[DM,vA]=Lc(yA,{forceMount:void 0}),Pi="TooltipContent",yb=b.forwardRef((e,t)=>{const n=vA(Pi,e.__scopeTooltip),{forceMount:r=n.forceMount,side:s="top",...i}=e,o=Mc(Pi,e.__scopeTooltip);return p.jsx(Rc,{present:r||o.open,children:o.disableHoverableContent?p.jsx(vb,{side:s,...i,ref:t}):p.jsx(wA,{side:s,...i,ref:t})})}),wA=b.forwardRef((e,t)=>{const n=Mc(Pi,e.__scopeTooltip),r=pb(Pi,e.__scopeTooltip),s=b.useRef(null),i=_t(t,s),[o,a]=b.useState(null),{trigger:l,onClose:c}=n,u=s.current,{onPointerInTransitChange:d}=r,h=b.useCallback(()=>{a(null),d(!1)},[d]),f=b.useCallback((w,y)=>{const x=w.currentTarget,m={x:w.clientX,y:w.clientY},g=kA(m,x.getBoundingClientRect()),v=EA(m,g),S=TA(y.getBoundingClientRect()),_=PA([...v,...S]);a(_),d(!0)},[d]);return b.useEffect(()=>()=>h(),[h]),b.useEffect(()=>{if(l&&u){const w=x=>f(x,u),y=x=>f(x,l);return l.addEventListener("pointerleave",w),u.addEventListener("pointerleave",y),()=>{l.removeEventListener("pointerleave",w),u.removeEventListener("pointerleave",y)}}},[l,u,f,h]),b.useEffect(()=>{if(o){const w=y=>{const x=y.target,m={x:y.clientX,y:y.clientY},g=(l==null?void 0:l.contains(x))||(u==null?void 0:u.contains(x)),v=!CA(m,o);g?h():v&&(h(),c())};return document.addEventListener("pointermove",w),()=>document.removeEventListener("pointermove",w)}},[l,u,o,c,h]),p.jsx(vb,{...e,ref:i})}),[xA,bA]=Lc(gb,{isInside:!1}),SA=jE("TooltipContent"),vb=b.forwardRef((e,t)=>{const{__scopeTooltip:n,children:r,"aria-label":s,onEscapeKeyDown:i,onPointerDownOutside:o,...a}=e,l=Mc(Pi,n),c=np(n),{onClose:u}=l;return b.useEffect(()=>(document.addEventListener(Pg,u),()=>document.removeEventListener(Pg,u)),[u]),b.useEffect(()=>{if(l.trigger){const d=h=>{const f=h.target;f!=null&&f.contains(l.trigger)&&u()};return window.addEventListener("scroll",d,{capture:!0}),()=>window.removeEventListener("scroll",d,{capture:!0})}},[l.trigger,u]),p.jsx(Ff,{asChild:!0,disableOutsidePointerEvents:!1,onEscapeKeyDown:i,onPointerDownOutside:o,onFocusOutside:d=>d.preventDefault(),onDismiss:u,children:p.jsxs(hA,{"data-state":l.stateAttribute,...c,...a,ref:t,style:{...a.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:[p.jsx(SA,{children:r}),p.jsx(xA,{scope:n,isInside:!0,children:p.jsx(tT,{id:l.contentId,role:"tooltip",children:s||r})})]})})});yb.displayName=Pi;var wb="TooltipArrow",_A=b.forwardRef((e,t)=>{const{__scopeTooltip:n,...r}=e,s=np(n);return bA(wb,n).isInside?null:p.jsx(fA,{...s,...r,ref:t})});_A.displayName=wb;function kA(e,t){const n=Math.abs(t.top-e.y),r=Math.abs(t.bottom-e.y),s=Math.abs(t.right-e.x),i=Math.abs(t.left-e.x);switch(Math.min(n,r,s,i)){case i:return"left";case s:return"right";case n:return"top";case r:return"bottom";default:throw new Error("unreachable")}}function EA(e,t,n=5){const r=[];switch(t){case"top":r.push({x:e.x-n,y:e.y+n},{x:e.x+n,y:e.y+n});break;case"bottom":r.push({x:e.x-n,y:e.y-n},{x:e.x+n,y:e.y-n});break;case"left":r.push({x:e.x+n,y:e.y-n},{x:e.x+n,y:e.y+n});break;case"right":r.push({x:e.x-n,y:e.y-n},{x:e.x-n,y:e.y+n});break}return r}function TA(e){const{top:t,right:n,bottom:r,left:s}=e;return[{x:s,y:t},{x:n,y:t},{x:n,y:r},{x:s,y:r}]}function CA(e,t){const{x:n,y:r}=e;let s=!1;for(let i=0,o=t.length-1;i<t.length;o=i++){const a=t[i],l=t[o],c=a.x,u=a.y,d=l.x,h=l.y;u>r!=h>r&&n<(d-c)*(r-u)/(h-u)+c&&(s=!s)}return s}function PA(e){const t=e.slice();return t.sort((n,r)=>n.x<r.x?-1:n.x>r.x?1:n.y<r.y?-1:n.y>r.y?1:0),AA(t)}function AA(e){if(e.length<=1)return e.slice();const t=[];for(let r=0;r<e.length;r++){const s=e[r];for(;t.length>=2;){const i=t[t.length-1],o=t[t.length-2];if((i.x-o.x)*(s.y-o.y)>=(i.y-o.y)*(s.x-o.x))t.pop();else break}t.push(s)}t.pop();const n=[];for(let r=e.length-1;r>=0;r--){const s=e[r];for(;n.length>=2;){const i=n[n.length-1],o=n[n.length-2];if((i.x-o.x)*(s.y-o.y)>=(i.y-o.y)*(s.x-o.x))n.pop();else break}n.push(s)}return n.pop(),t.length===1&&n.length===1&&t[0].x===n[0].x&&t[0].y===n[0].y?t:t.concat(n)}
vendor: 18,940 bytes, line 186
186var RA=mb,xb=yb;const jA=RA,NA=b.forwardRef(({className:e,sideOffset:t=4,...n},r)=>p.jsx(xb,{ref:r,sideOffset:t,className:Mt("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",e),...n}));NA.displayName=xb.displayName;var $c=class{constructor(){this.listeners=new Set,this.subscribe=this.subscribe.bind(this)}subscribe(e){return this.listeners.add(e),this.onSubscribe(),()=>{this.listeners.delete(e),this.onUnsubscribe()}}hasListeners(){return this.listeners.size>0}onSubscribe(){}onUnsubscribe(){}},Vc=typeof window>"u"||"Deno"in globalThis;function qt(){}function OA(e,t){return typeof e=="function"?e(t):e}function IA(e){return typeof e=="number"&&e>=0&&e!==1/0}function DA(e,t){return Math.max(e+(t||0)-Date.now(),0)}function lh(e,t){return typeof e=="function"?e(t):e}function LA(e,t){return typeof e=="function"?e(t):e}function Ag(e,t){const{type:n="all",exact:r,fetchStatus:s,predicate:i,queryKey:o,stale:a}=e;if(o){if(r){if(t.queryHash!==rp(o,t.options))return!1}else if(!qo(t.queryKey,o))return!1}if(n!=="all"){const l=t.isActive();if(n==="active"&&!l||n==="inactive"&&l)return!1}return!(typeof a=="boolean"&&t.isStale()!==a||s&&s!==t.state.fetchStatus||i&&!i(t))}function Rg(e,t){const{exact:n,status:r,predicate:s,mutationKey:i}=e;if(i){if(!t.options.mutationKey)return!1;if(n){if(Ko(t.options.mutationKey)!==Ko(i))return!1}else if(!qo(t.options.mutationKey,i))return!1}return!(r&&t.state.status!==r||s&&!s(t))}function rp(e,t){return((t==null?void 0:t.queryKeyHashFn)||Ko)(e)}function Ko(e){return JSON.stringify(e,(t,n)=>ch(n)?Object.keys(n).sort().reduce((r,s)=>(r[s]=n[s],r),{}):n)}function qo(e,t){return e===t?!0:typeof e!=typeof t?!1:e&&t&&typeof e=="object"&&typeof t=="object"?Object.keys(t).every(n=>qo(e[n],t[n])):!1}function bb(e,t){if(e===t)return e;const n=jg(e)&&jg(t);if(n||ch(e)&&ch(t)){const r=n?e:Object.keys(e),s=r.length,i=n?t:Object.keys(t),o=i.length,a=n?[]:{},l=new Set(r);let c=0;for(let u=0;u<o;u++){const d=n?u:i[u];(!n&&l.has(d)||n)&&e[d]===void 0&&t[d]===void 0?(a[d]=void 0,c++):(a[d]=bb(e[d],t[d]),a[d]===e[d]&&e[d]!==void 0&&c++)}return s===o&&c===s?e:a}return t}function jg(e){return Array.isArray(e)&&e.length===Object.keys(e).length}function ch(e){if(!Ng(e))return!1;const t=e.constructor;if(t===void 0)return!0;const n=t.prototype;return!(!Ng(n)||!n.hasOwnProperty("isPrototypeOf")||Object.getPrototypeOf(e)!==Object.prototype)}function Ng(e){return Object.prototype.toString.call(e)==="[object Object]"}function MA(e){return new Promise(t=>{setTimeout(t,e)})}function $A(e,t,n){return typeof n.structuralSharing=="function"?n.structuralSharing(e,t):n.structuralSharing!==!1?bb(e,t):t}function VA(e,t,n=0){const r=[...e,t];return n&&r.length>n?r.slice(1):r}function FA(e,t,n=0){const r=[t,...e];return n&&r.length>n?r.slice(0,-1):r}var sp=Symbol();function Sb(e,t){return!e.queryFn&&(t!=null&&t.initialPromise)?()=>t.initialPromise:!e.queryFn||e.queryFn===sp?()=>Promise.reject(new Error(`Missing queryFn: '${e.queryHash}'`)):e.queryFn}var es,ir,hi,Cv,UA=(Cv=class extends $c{constructor(){super();re(this,es);re(this,ir);re(this,hi);Y(this,hi,t=>{if(!Vc&&window.addEventListener){const n=()=>t();return window.addEventListener("visibilitychange",n,!1),()=>{window.removeEventListener("visibilitychange",n)}}})}onSubscribe(){P(this,ir)||this.setEventListener(P(this,hi))}onUnsubscribe(){var t;this.hasListeners()||((t=P(this,ir))==null||t.call(this),Y(this,ir,void 0))}setEventListener(t){var n;Y(this,hi,t),(n=P(this,ir))==null||n.call(this),Y(this,ir,t(r=>{typeof r=="boolean"?this.setFocused(r):this.onFocus()}))}setFocused(t){P(this,es)!==t&&(Y(this,es,t),this.onFocus())}onFocus(){const t=this.isFocused();this.listeners.forEach(n=>{n(t)})}isFocused(){var t;return typeof P(this,es)=="boolean"?P(this,es):((t=globalThis.document)==null?void 0:t.visibilityState)!=="hidden"}},es=new WeakMap,ir=new WeakMap,hi=new WeakMap,Cv),_b=new UA,fi,or,pi,Pv,BA=(Pv=class extends $c{constructor(){super();re(this,fi,!0);re(this,or);re(this,pi);Y(this,pi,t=>{if(!Vc&&window.addEventListener){const n=()=>t(!0),r=()=>t(!1);return window.addEventListener("online",n,!1),window.addEventListener("offline",r,!1),()=>{window.removeEventListener("online",n),window.removeEventListener("offline",r)}}})}onSubscribe(){P(this,or)||this.setEventListener(P(this,pi))}onUnsubscribe(){var t;this.hasListeners()||((t=P(this,or))==null||t.call(this),Y(this,or,void 0))}setEventListener(t){var n;Y(this,pi,t),(n=P(this,or))==null||n.call(this),Y(this,or,t(this.setOnline.bind(this)))}setOnline(t){P(this,fi)!==t&&(Y(this,fi,t),this.listeners.forEach(r=>{r(t)}))}isOnline(){return P(this,fi)}},fi=new WeakMap,or=new WeakMap,pi=new WeakMap,Pv),nc=new BA;function zA(){let e,t;const n=new Promise((s,i)=>{e=s,t=i});n.status="pending",n.catch(()=>{});function r(s){Object.assign(n,s),delete n.resolve,delete n.reject}return n.resolve=s=>{r({status:"fulfilled",value:s}),e(s)},n.reject=s=>{r({status:"rejected",reason:s}),t(s)},n}function WA(e){return Math.min(1e3*2**e,3e4)}function kb(e){return(e??"online")==="online"?nc.isOnline():!0}var Eb=class extends Error{constructor(e){super("CancelledError"),this.revert=e==null?void 0:e.revert,this.silent=e==null?void 0:e.silent}};function Ou(e){return e instanceof Eb}function Tb(e){let t=!1,n=0,r=!1,s;const i=zA(),o=y=>{var x;r||(h(new Eb(y)),(x=e.abort)==null||x.call(e))},a=()=>{t=!0},l=()=>{t=!1},c=()=>_b.isFocused()&&(e.networkMode==="always"||nc.isOnline())&&e.canRun(),u=()=>kb(e.networkMode)&&e.canRun(),d=y=>{var x;r||(r=!0,(x=e.onSuccess)==null||x.call(e,y),s==null||s(),i.resolve(y))},h=y=>{var x;r||(r=!0,(x=e.onError)==null||x.call(e,y),s==null||s(),i.reject(y))},f=()=>new Promise(y=>{var x;s=m=>{(r||c())&&y(m)},(x=e.onPause)==null||x.call(e)}).then(()=>{var y;s=void 0,r||(y=e.onContinue)==null||y.call(e)}),w=()=>{if(r)return;let y;const x=n===0?e.initialPromise:void 0;try{y=x??e.fn()}catch(m){y=Promise.reject(m)}Promise.resolve(y).then(d).catch(m=>{var k;if(r)return;const g=e.retry??(Vc?0:3),v=e.retryDelay??WA,S=typeof v=="function"?v(n,m):v,_=g===!0||typeof g=="number"&&n<g||typeof g=="function"&&g(n,m);if(t||!_){h(m);return}n++,(k=e.onFail)==null||k.call(e,n,m),MA(S).then(()=>c()?void 0:f()).then(()=>{t?h(m):w()})})};return{promise:i,cancel:o,continue:()=>(s==null||s(),i),cancelRetry:a,continueRetry:l,canStart:u,start:()=>(u()?w():f().then(w),i)}}var HA=e=>setTimeout(e,0);function KA(){let e=[],t=0,n=a=>{a()},r=a=>{a()},s=HA;const i=a=>{t?e.push(a):s(()=>{n(a)})},o=()=>{const a=e;e=[],a.length&&s(()=>{r(()=>{a.forEach(l=>{n(l)})})})};return{batch:a=>{let l;t++;try{l=a()}finally{t--,t||o()}return l},batchCalls:a=>(...l)=>{i(()=>{a(...l)})},schedule:i,setNotifyFunction:a=>{n=a},setBatchNotifyFunction:a=>{r=a},setScheduler:a=>{s=a}}}var st=KA(),ts,Av,Cb=(Av=class{constructor(){re(this,ts)}destroy(){this.clearGcTimeout()}scheduleGc(){this.clearGcTimeout(),IA(this.gcTime)&&Y(this,ts,setTimeout(()=>{this.optionalRemove()},this.gcTime))}updateGcTime(e){this.gcTime=Math.max(this.gcTime||0,e??(Vc?1/0:5*60*1e3))}clearGcTimeout(){P(this,ts)&&(clearTimeout(P(this,ts)),Y(this,ts,void 0))}},ts=new WeakMap,Av),mi,ns,Pt,rs,Xe,aa,ss,Gt,Sn,Rv,qA=(Rv=class extends Cb{constructor(t){super();re(this,Gt);re(this,mi);re(this,ns);re(this,Pt);re(this,rs);re(this,Xe);re(this,aa);re(this,ss);Y(this,ss,!1),Y(this,aa,t.defaultOptions),this.setOptions(t.options),this.observers=[],Y(this,rs,t.client),Y(this,Pt,P(this,rs).getQueryCache()),this.queryKey=t.queryKey,this.queryHash=t.queryHash,Y(this,mi,YA(this.options)),this.state=t.state??P(this,mi),this.scheduleGc()}get meta(){return this.options.meta}get promise(){var t;return(t=P(this,Xe))==null?void 0:t.promise}setOptions(t){this.options={...P(this,aa),...t},this.updateGcTime(this.options.gcTime)}optionalRemove(){!this.observers.length&&this.state.fetchStatus==="idle"&&P(this,Pt).remove(this)}setData(t,n){const r=$A(this.state.data,t,this.options);return Ye(this,Gt,Sn).call(this,{data:r,type:"success",dataUpdatedAt:n==null?void 0:n.updatedAt,manual:n==null?void 0:n.manual}),r}setState(t,n){Ye(this,Gt,Sn).call(this,{type:"setState",state:t,setStateOptions:n})}cancel(t){var r,s;const n=(r=P(this,Xe))==null?void 0:r.promise;return(s=P(this,Xe))==null||s.cancel(t),n?n.then(qt).catch(qt):Promise.resolve()}destroy(){super.destroy(),this.cancel({silent:!0})}reset(){this.destroy(),this.setState(P(this,mi))}isActive(){return this.observers.some(t=>LA(t.options.enabled,this)!==!1)}isDisabled(){return this.getObserversCount()>0?!this.isActive():this.options.queryFn===sp||this.state.dataUpdateCount+this.state.errorUpdateCount===0}isStatic(){return this.getObserversCount()>0?this.observers.some(t=>lh(t.options.staleTime,this)==="static"):!1}isStale(){return this.getObserversCount()>0?this.observers.some(t=>t.getCurrentResult().isStale):this.state.data===void 0||this.state.isInvalidated}isStaleByTime(t=0){return this.state.data===void 0?!0:t==="static"?!1:this.state.isInvalidated?!0:!DA(this.state.dataUpdatedAt,t)}onFocus(){var n;const t=this.observers.find(r=>r.shouldFetchOnWindowFocus());t==null||t.refetch({cancelRefetch:!1}),(n=P(this,Xe))==null||n.continue()}onOnline(){var n;const t=this.observers.find(r=>r.shouldFetchOnReconnect());t==null||t.refetch({cancelRefetch:!1}),(n=P(this,Xe))==null||n.continue()}addObserver(t){this.observers.includes(t)||(this.observers.push(t),this.clearGcTimeout(),P(this,Pt).notify({type:"observerAdded",query:this,observer:t}))}removeObserver(t){this.observers.includes(t)&&(this.observers=this.observers.filter(n=>n!==t),this.observers.length||(P(this,Xe)&&(P(this,ss)?P(this,Xe).cancel({revert:!0}):P(this,Xe).cancelRetry()),this.scheduleGc()),P(this,Pt).notify({type:"observerRemoved",query:this,observer:t}))}getObserversCount(){return this.observers.length}invalidate(){this.state.isInvalidated||Ye(this,Gt,Sn).call(this,{type:"invalidate"})}fetch(t,n){var c,u,d;if(this.state.fetchStatus!=="idle"){if(this.state.data!==void 0&&(n!=null&&n.cancelRefetch))this.cancel({silent:!0});else if(P(this,Xe))return P(this,Xe).continueRetry(),P(this,Xe).promise}if(t&&this.setOptions(t),!this.options.queryFn){const h=this.observers.find(f=>f.options.queryFn);h&&this.setOptions(h.options)}const r=new AbortController,s=h=>{Object.defineProperty(h,"signal",{enumerable:!0,get:()=>(Y(this,ss,!0),r.signal)})},i=()=>{const h=Sb(this.options,n),w=(()=>{const y={client:P(this,rs),queryKey:this.queryKey,meta:this.meta};return s(y),y})();return Y(this,ss,!1),this.options.persister?this.options.persister(h,w,this):h(w)},a=(()=>{const h={fetchOptions:n,options:this.options,queryKey:this.queryKey,client:P(this,rs),state:this.state,fetchFn:i};return s(h),h})();(c=this.options.behavior)==null||c.onFetch(a,this),Y(this,ns,this.state),(this.state.fetchStatus==="idle"||this.state.fetchMeta!==((u=a.fetchOptions)==null?void 0:u.meta))&&Ye(this,Gt,Sn).call(this,{type:"fetch",meta:(d=a.fetchOptions)==null?void 0:d.meta});const l=h=>{var f,w,y,x;Ou(h)&&h.silent||Ye(this,Gt,Sn).call(this,{type:"error",error:h}),Ou(h)||((w=(f=P(this,Pt).config).onError)==null||w.call(f,h,this),(x=(y=P(this,Pt).config).onSettled)==null||x.call(y,this.state.data,h,this)),this.scheduleGc()};return Y(this,Xe,Tb({initialPromise:n==null?void 0:n.initialPromise,fn:a.fetchFn,abort:r.abort.bind(r),onSuccess:h=>{var f,w,y,x;if(h===void 0){l(new Error(`${this.queryHash} data is undefined`));return}try{this.setData(h)}catch(m){l(m);return}(w=(f=P(this,Pt).config).onSuccess)==null||w.call(f,h,this),(x=(y=P(this,Pt).config).onSettled)==null||x.call(y,h,this.state.error,this),this.scheduleGc()},onError:l,onFail:(h,f)=>{Ye(this,Gt,Sn).call(this,{type:"failed",failureCount:h,error:f})},onPause:()=>{Ye(this,Gt,Sn).call(this,{type:"pause"})},onContinue:()=>{Ye(this,Gt,Sn).call(this,{type:"continue"})},retry:a.options.retry,retryDelay:a.options.retryDelay,networkMode:a.options.networkMode,canRun:()=>!0})),P(this,Xe).start()}},mi=new WeakMap,ns=new WeakMap,Pt=new WeakMap,rs=new WeakMap,Xe=new WeakMap,aa=new WeakMap,ss=new WeakMap,Gt=new WeakSet,Sn=function(t){const n=r=>{switch(t.type){case"failed":return{...r,fetchFailureCount:t.failureCount,fetchFailureReason:t.error};case"pause":return{...r,fetchStatus:"paused"};case"continue":return{...r,fetchStatus:"fetching"};case"fetch":return{...r,...GA(r.data,this.options),fetchMeta:t.meta??null};case"success":return Y(this,ns,void 0),{...r,data:t.data,dataUpdateCount:r.dataUpdateCount+1,dataUpdatedAt:t.dataUpdatedAt??Date.now(),error:null,isInvalidated:!1,status:"success",...!t.manual&&{fetchStatus:"idle",fetchFailureCount:0,fetchFailureReason:null}};case"error":const s=t.error;return Ou(s)&&s.revert&&P(this,ns)?{...P(this,ns),fetchStatus:"idle"}:{...r,error:s,errorUpdateCount:r.errorUpdateCount+1,errorUpdatedAt:Date.now(),fetchFailureCount:r.fetchFailureCount+1,fetchFailureReason:s,fetchStatus:"idle",status:"error"};case"invalidate":return{...r,isInvalidated:!0};case"setState":return{...r,...t.state}}};this.state=n(this.state),st.batch(()=>{this.observers.forEach(r=>{r.onQueryUpdate()}),P(this,Pt).notify({query:this,type:"updated",action:t})})},Rv);function GA(e,t){return{fetchFailureCount:0,fetchFailureReason:null,fetchStatus:kb(t.networkMode)?"fetching":"paused",...e===void 0&&{error:null,status:"pending"}}}function YA(e){const t=typeof e.initialData=="function"?e.initialData():e.initialData,n=t!==void 0,r=n?typeof e.initialDataUpdatedAt=="function"?e.initialDataUpdatedAt():e.initialDataUpdatedAt:0;return{data:t,dataUpdateCount:0,dataUpdatedAt:n?r??Date.now():0,error:null,errorUpdateCount:0,errorUpdatedAt:0,fetchFailureCount:0,fetchFailureReason:null,fetchMeta:null,isInvalidated:!1,status:n?"success":"pending",fetchStatus:"idle"}}var cn,jv,QA=(jv=class extends $c{constructor(t={}){super();re(this,cn);this.config=t,Y(this,cn,new Map)}build(t,n,r){const s=n.queryKey,i=n.queryHash??rp(s,n);let o=this.get(i);return o||(o=new qA({client:t,queryKey:s,queryHash:i,options:t.defaultQueryOptions(n),state:r,defaultOptions:t.getQueryDefaults(s)}),this.add(o)),o}add(t){P(this,cn).has(t.queryHash)||(P(this,cn).set(t.queryHash,t),this.notify({type:"added",query:t}))}remove(t){const n=P(this,cn).get(t.queryHash);n&&(t.destroy(),n===t&&P(this,cn).delete(t.queryHash),this.notify({type:"removed",query:t}))}clear(){st.batch(()=>{this.getAll().forEach(t=>{this.remove(t)})})}get(t){return P(this,cn).get(t)}getAll(){return[...P(this,cn).values()]}find(t){const n={exact:!0,...t};return this.getAll().find(r=>Ag(n,r))}findAll(t={}){const n=this.getAll();return Object.keys(t).length>0?n.filter(r=>Ag(t,r)):n}notify(t){st.batch(()=>{this.listeners.forEach(n=>{n(t)})})}onFocus(){st.batch(()=>{this.getAll().forEach(t=>{t.onFocus()})})}onOnline(){st.batch(()=>{this.getAll().forEach(t=>{t.onOnline()})})}},cn=new WeakMap,jv),un,nt,is,dn,Qn,Nv,JA=(Nv=class extends Cb{constructor(t){super();re(this,dn);re(this,un);re(this,nt);re(this,is);this.mutationId=t.mutationId,Y(this,nt,t.mutationCache),Y(this,un,[]),this.state=t.state||XA(),this.setOptions(t.options),this.scheduleGc()}setOptions(t){this.options=t,this.updateGcTime(this.options.gcTime)}get meta(){return this.options.meta}addObserver(t){P(this,un).includes(t)||(P(this,un).push(t),this.clearGcTimeout(),P(this,nt).notify({type:"observerAdded",mutation:this,observer:t}))}removeObserver(t){Y(this,un,P(this,un).filter(n=>n!==t)),this.scheduleGc(),P(this,nt).notify({type:"observerRemoved",mutation:this,observer:t})}optionalRemove(){P(this,un).length||(this.state.status==="pending"?this.scheduleGc():P(this,nt).remove(this))}continue(){var t;return((t=P(this,is))==null?void 0:t.continue())??this.execute(this.state.variables)}async execute(t){var i,o,a,l,c,u,d,h,f,w,y,x,m,g,v,S,_,k,E,T;const n=()=>{Ye(this,dn,Qn).call(this,{type:"continue"})};Y(this,is,Tb({fn:()=>this.options.mutationFn?this.options.mutationFn(t):Promise.reject(new Error("No mutationFn found")),onFail:(j,O)=>{Ye(this,dn,Qn).call(this,{type:"failed",failureCount:j,error:O})},onPause:()=>{Ye(this,dn,Qn).call(this,{type:"pause"})},onContinue:n,retry:this.options.retry??0,retryDelay:this.options.retryDelay,networkMode:this.options.networkMode,canRun:()=>P(this,nt).canRun(this)}));const r=this.state.status==="pending",s=!P(this,is).canStart();try{if(r)n();else{Ye(this,dn,Qn).call(this,{type:"pending",variables:t,isPaused:s}),await((o=(i=P(this,nt).config).onMutate)==null?void 0:o.call(i,t,this));const O=await((l=(a=this.options).onMutate)==null?void 0:l.call(a,t));O!==this.state.context&&Ye(this,dn,Qn).call(this,{type:"pending",context:O,variables:t,isPaused:s})}const j=await P(this,is).start();return await((u=(c=P(this,nt).config).onSuccess)==null?void 0:u.call(c,j,t,this.state.context,this)),await((h=(d=this.options).onSuccess)==null?void 0:h.call(d,j,t,this.state.context)),await((w=(f=P(this,nt).config).onSettled)==null?void 0:w.call(f,j,null,this.state.variables,this.state.context,this)),await((x=(y=this.options).onSettled)==null?void 0:x.call(y,j,null,t,this.state.context)),Ye(this,dn,Qn).call(this,{type:"success",data:j}),j}catch(j){try{throw await((g=(m=P(this,nt).config).onError)==null?void 0:g.call(m,j,t,this.state.context,this)),await((S=(v=this.options).onError)==null?void 0:S.call(v,j,t,this.state.context)),await((k=(_=P(this,nt).config).onSettled)==null?void 0:k.call(_,void 0,j,this.state.variables,this.state.context,this)),await((T=(E=this.options).onSettled)==null?void 0:T.call(E,void 0,j,t,this.state.context)),j}finally{Ye(this,dn,Qn).call(this,{type:"error",error:j})}}finally{P(this,nt).runNext(this)}}},un=new WeakMap,nt=new WeakMap,is=new WeakMap,dn=new WeakSet,Qn=function(t){const n=r=>{switch(t.type){case"failed":return{...r,failureCount:t.failureCount,failureReason:t.error};case"pause":return{...r,isPaused:!0};case"continue":return{...r,isPaused:!1};case"pending":return{...r,context:t.context,data:void 0,failureCount:0,failureReason:null,error:null,isPaused:t.isPaused,status:"pending",variables:t.variables,submittedAt:Date.now()};case"success":return{...r,data:t.data,failureCount:0,failureReason:null,error:null,status:"success",isPaused:!1};case"error":return{...r,data:void 0,error:t.error,failureCount:r.failureCount+1,failureReason:t.error,isPaused:!1,status:"error"}}};this.state=n(this.state),st.batch(()=>{P(this,un).forEach(r=>{r.onMutationUpdate(t)}),P(this,nt).notify({mutation:this,type:"updated",action:t})})},Nv);function XA(){return{context:void 0,data:void 0,error:null,failureCount:0,failureReason:null,isPaused:!1,status:"idle",variables:void 0,submittedAt:0}}var Tn,Yt,la,Ov,ZA=(Ov=class extends $c{constructor(t={}){super();re(this,Tn);re(this,Yt);re(this,la);
186this.config=t,Y(this,Tn,new Set),Y(this,Yt,new Map),Y(this,la,0)}build(t,n,r){const s=new JA({mutationCache:this,mutationId:++Pa(this,la)._,options:t.defaultMutationOptions(n),state:r});return this.add(s),s}add(t){P(this,Tn).add(t);const n=Qa(t);if(typeof n=="string"){const r=P(this,Yt).get(n);r?r.push(t):P(this,Yt).set(n,[t])}this.notify({type:"added",mutation:t})}remove(t){if(P(this,Tn).delete(t)){const n=Qa(t);if(typeof n=="string"){const r=P(this,Yt).get(n);if(r)if(r.length>1){const s=r.indexOf(t);s!==-1&&r.splice(s,1)}else r[0]===t&&P(this,Yt).delete(n)}}this.notify({type:"removed",mutation:t})}canRun(t){const n=Qa(t);if(typeof n=="string"){const r=P(this,Yt).get(n),s=r==null?void 0:r.find(i=>i.state.status==="pending");return!s||s===t}else return!0}runNext(t){var r;const n=Qa(t);if(typeof n=="string"){const s=(r=P(this,Yt).get(n))==null?void 0:r.find(i=>i!==t&&i.state.isPaused);return(s==null?void 0:s.continue())??Promise.resolve()}else return Promise.resolve()}clear(){st.batch(()=>{P(this,Tn).forEach(t=>{this.notify({type:"removed",mutation:t})}),P(this,Tn).clear(),P(this,Yt).clear()})}getAll(){return Array.from(P(this,Tn))}find(t){const n={exact:!0,...t};return this.getAll().find(r=>Rg(n,r))}findAll(t={}){return this.getAll().filter(n=>Rg(t,n))}notify(t){st.batch(()=>{this.listeners.forEach(n=>{n(t)})})}resumePausedMutations(){const t=this.getAll().filter(n=>n.state.isPaused);return st.batch(()=>Promise.all(t.map(n=>n.continue().catch(qt))))}},Tn=new WeakMap,Yt=new WeakMap,la=new WeakMap,Ov);function Qa(e){var t;return(t=e.options.scope)==null?void 0:t.id}function Og(e){return{onFetch:(t,n)=>{var u,d,h,f,w;const r=t.options,s=(h=(d=(u=t.fetchOptions)==null?void 0:u.meta)==null?void 0:d.fetchMore)==null?void 0:h.direction,i=((f=t.state.data)==null?void 0:f.pages)||[],o=((w=t.state.data)==null?void 0:w.pageParams)||[];let a={pages:[],pageParams:[]},l=0;const c=async()=>{let y=!1;const x=v=>{Object.defineProperty(v,"signal",{enumerable:!0,get:()=>(t.signal.aborted?y=!0:t.signal.addEventListener("abort",()=>{y=!0}),t.signal)})},m=Sb(t.options,t.fetchOptions),g=async(v,S,_)=>{if(y)return Promise.reject();if(S==null&&v.pages.length)return Promise.resolve(v);const E=(()=>{const U={client:t.client,queryKey:t.queryKey,pageParam:S,direction:_?"backward":"forward",meta:t.options.meta};return x(U),U})(),T=await m(E),{maxPages:j}=t.options,O=_?FA:VA;return{pages:O(v.pages,T,j),pageParams:O(v.pageParams,S,j)}};if(s&&i.length){const v=s==="backward",S=v?eR:Ig,_={pages:i,pageParams:o},k=S(r,_);a=await g(_,k,v)}else{const v=e??i.length;do{const S=l===0?o[0]??r.initialPageParam:Ig(r,a);if(l>0&&S==null)break;a=await g(a,S),l++}while(l<v)}return a};t.options.persister?t.fetchFn=()=>{var y,x;return(x=(y=t.options).persister)==null?void 0:x.call(y,c,{client:t.client,queryKey:t.queryKey,meta:t.options.meta,signal:t.signal},n)}:t.fetchFn=c}}}function Ig(e,{pages:t,pageParams:n}){const r=t.length-1;return t.length>0?e.getNextPageParam(t[r],t,n[r],n):void 0}function eR(e,{pages:t,pageParams:n}){var r;return t.length>0?(r=e.getPreviousPageParam)==null?void 0:r.call(e,t[0],t,n[0],n):void 0}var Se,ar,lr,gi,yi,cr,vi,wi,Iv,tR=(Iv=class{constructor(e={}){re(this,Se);re(this,ar);re(this,lr);re(this,gi);re(this,yi);re(this,cr);re(this,vi);re(this,wi);Y(this,Se,e.queryCache||new QA),Y(this,ar,e.mutationCache||new ZA),Y(this,lr,e.defaultOptions||{}),Y(this,gi,new Map),Y(this,yi,new Map),Y(this,cr,0)}mount(){Pa(this,cr)._++,P(this,cr)===1&&(Y(this,vi,_b.subscribe(async e=>{e&&(await this.resumePausedMutations(),P(this,Se).onFocus())})),Y(this,wi,nc.subscribe(async e=>{e&&(await this.resumePausedMutations(),P(this,Se).onOnline())})))}unmount(){var e,t;Pa(this,cr)._--,P(this,cr)===0&&((e=P(this,vi))==null||e.call(this),Y(this,vi,void 0),(t=P(this,wi))==null||t.call(this),Y(this,wi,void 0))}isFetching(e){return P(this,Se).findAll({...e,fetchStatus:"fetching"}).length}isMutating(e){return P(this,ar).findAll({...e,status:"pending"}).length}getQueryData(e){var n;const t=this.defaultQueryOptions({queryKey:e});return(n=P(this,Se).get(t.queryHash))==null?void 0:n.state.data}ensureQueryData(e){const t=this.defaultQueryOptions(e),n=P(this,Se).build(this,t),r=n.state.data;return r===void 0?this.fetchQuery(e):(e.revalidateIfStale&&n.isStaleByTime(lh(t.staleTime,n))&&this.prefetchQuery(t),Promise.resolve(r))}getQueriesData(e){return P(this,Se).findAll(e).map(({queryKey:t,state:n})=>{const r=n.data;return[t,r]})}setQueryData(e,t,n){const r=this.defaultQueryOptions({queryKey:e}),s=P(this,Se).get(r.queryHash),i=s==null?void 0:s.state.data,o=OA(t,i);if(o!==void 0)return P(this,Se).build(this,r).setData(o,{...n,manual:!0})}
186setQueriesData(e,t,n){return st.batch(()=>P(this,Se).findAll(e).map(({queryKey:r})=>[r,this.setQueryData(r,t,n)]))}getQueryState(e){var n;const t=this.defaultQueryOptions({queryKey:e});return(n=P(this,Se).get(t.queryHash))==null?void 0:n.state}removeQueries(e){const t=P(this,Se);st.batch(()=>{t.findAll(e).forEach(n=>{t.remove(n)})})}resetQueries(e,t){const n=P(this,Se);return st.batch(()=>(n.findAll(e).forEach(r=>{r.reset()}),this.refetchQueries({type:"active",...e},t)))}cancelQueries(e,t={}){const n={revert:!0,...t},r=st.batch(()=>P(this,Se).findAll(e).map(s=>s.cancel(n)));return Promise.all(r).then(qt).catch(qt)}invalidateQueries(e,t={}){return st.batch(()=>(P(this,Se).findAll(e).forEach(n=>{n.invalidate()}),(e==null?void 0:e.refetchType)==="none"?Promise.resolve():this.refetchQueries({...e,type:(e==null?void 0:e.refetchType)??(e==null?void 0:e.type)??"active"},t)))}refetchQueries(e,t={}){const n={...t,cancelRefetch:t.cancelRefetch??!0},r=st.batch(()=>P(this,Se).findAll(e).filter(s=>!s.isDisabled()&&!s.isStatic()).map(s=>{let i=s.fetch(void 0,n);return n.throwOnError||(i=i.catch(qt)),s.state.fetchStatus==="paused"?Promise.resolve():i}));return Promise.all(r).then(qt)}fetchQuery(e){const t=this.defaultQueryOptions(e);t.retry===void 0&&(t.retry=!1);const n=P(this,Se).build(this,t);return n.isStaleByTime(lh(t.staleTime,n))?n.fetch(t):Promise.resolve(n.state.data)}prefetchQuery(e){return this.fetchQuery(e).then(qt).catch(qt)}fetchInfiniteQuery(e){return e.behavior=Og(e.pages),this.fetchQuery(e)}prefetchInfiniteQuery(e){return this.fetchInfiniteQuery(e).then(qt).catch(qt)}ensureInfiniteQueryData(e){return e.behavior=Og(e.pages),this.ensureQueryData(e)}resumePausedMutations(){return nc.isOnline()?P(this,ar).resumePausedMutations():Promise.resolve()}getQueryCache(){return P(this,Se)}getMutationCache(){return P(this,ar)}getDefaultOptions(){return P(this,lr)}setDefaultOptions(e){Y(this,lr,e)}setQueryDefaults(e,t){P(this,gi).set(Ko(e),{queryKey:e,defaultOptions:t})}getQueryDefaults(e){const t=[...P(this,gi).values()],n={};return t.forEach(r=>{qo(e,r.queryKey)&&Object.assign(n,r.defaultOptions)}),n}setMutationDefaults(e,t){P(this,yi).set(Ko(e),{mutationKey:e,defaultOptions:t})}getMutationDefaults(e){const t=[...P(this,yi).values()],n={};return t.forEach(r=>{qo(e,r.mutationKey)&&Object.assign(n,r.defaultOptions)}),n}defaultQueryOptions(e){if(e._defaulted)return e;const t={...P(this,lr).queries,...this.getQueryDefaults(e.queryKey),...e,_defaulted:!0};return t.queryHash||(t.queryHash=rp(t.queryKey,t)),t.refetchOnReconnect===void 0&&(t.refetchOnReconnect=t.networkMode!=="always"),t.throwOnError===void 0&&(t.throwOnError=!!t.suspense),!t.networkMode&&t.persister&&(t.networkMode="offlineFirst"),t.queryFn===sp&&(t.enabled=!1),t}defaultMutationOptions(e){return e!=null&&e._defaulted?e:{...P(this,lr).mutations,...(e==null?void 0:e.mutationKey)&&this.getMutationDefaults(e.mutationKey),...e,_defaulted:!0}}clear(){P(this,Se).clear(),P(this,ar).clear()}},Se=new WeakMap,ar=new WeakMap,lr=new WeakMap,gi=new WeakMap,yi=new WeakMap,cr=new WeakMap,vi=new WeakMap,wi=new WeakMap,Iv),nR=b.createContext(void 0),rR=({client:e,children:t})=>(b.useEffect(()=>(e.mount(),()=>{e.unmount()}),[e]),p.jsx(nR.Provider,{value:e,children:t}));/** 187 * @remix-run/router v1.23.0 188 * 189 * Copyright (c) Remix Software Inc. 190 * 191 * This source code is licensed under the MIT license found in the 192 * LICENSE.md file in the root directory of this source tree. 193 * 194 * @license MIT 195 */function Go(){return Go=Object.assign?Object.assign.bind():function(e){for(var t=1;t<arguments.length;t++){var n=arguments[t];for(var r in n)Object.prototype.hasOwnProperty.call(n,r)&&(e[r]=n[r])}return e},Go.apply(this,arguments)}var hr;(function(e){e.Pop="POP",e.Push="PUSH",e.Replace="REPLACE"})(hr||(hr={}));const Dg="popstate";function sR(e){e===void 0&&(e={});function t(r,s){let{pathname:i,search:o,hash:a}=r.location;return uh("",{pathname:i,search:o,hash:a},s.state&&s.state.usr||null,s.state&&s.state.key||"default")}function n(r,s){return typeof s=="string"?s:Ab(s)}return oR(t,n,null,e)}function Oe(e,t){if(e===!1||e===null||typeof e>"u")throw new Error(t)}function Pb(e,t){if(!e){typeof console<"u"&&console.warn(t);try{throw new Error(t)}catch{}}}function iR(){return Math.random().toString(36).substr(2,8)}function Lg(e,t){return{usr:e.state,key:e.key,idx:t}}function uh(e,t,n,r){return n===void 0&&(n=null),Go({pathname:typeof e=="string"?e:e.pathname,search:"",hash:""},typeof t=="string"?Mi(t):t,{state:n,key:t&&t.key||r||iR()})}function Ab(e){let{pathname:t="/",search:n="",hash:r=""}=e;return n&&n!=="?"&&(t+=n.charAt(0)==="?"?n:"?"+n),r&&r!=="#"&&(t+=r.charAt(0)==="#"?r:"#"+r),t}function Mi(e){let t={};if(e){let n=e.indexOf("#");n>=0&&(t.hash=e.substr(n),e=e.substr(0,n));let r=e.indexOf("?");r>=0&&(t.search=e.substr(r),e=e.substr(0,r)),e&&(t.pathname=e)}return t}function oR(e,t,n,r){r===void 0&&(r={});let{window:s=document.defaultView,v5Compat:i=!1}=r,o=s.history,a=hr.Pop,l=null,c=u();c==null&&(c=0,o.replaceState(Go({},o.state,{idx:c}),""));function u(){return(o.state||{idx:null}).idx}function d(){a=hr.Pop;let x=u(),m=x==null?null:x-c;c=x,l&&l({action:a,location:y.location,delta:m})}function h(x,m){a=hr.Push;let g=uh(y.location,x,m);c=u()+1;let v=Lg(g,c),S=y.createHref(g);try{o.pushState(v,"",S)}catch(_){if(_ instanceof DOMException&&_.name==="DataCloneError")throw _;s.location.assign(S)}i&&l&&l({action:a,location:y.location,delta:1})}function f(x,m){a=hr.Replace;let g=uh(y.location,x,m);c=u();let v=Lg(g,c),S=y.createHref(g);o.replaceState(v,"",S),i&&l&&l({action:a,location:y.location,delta:0})}function w(x){let m=s.location.origin!=="null"?s.location.origin:s.location.href,g=typeof x=="str
195ing"?x:Ab(x);return g=g.replace(/ $/,"%20"),Oe(m,"No window.location.(origin|href) available to create URL for href: "+g),new URL(g,m)}let y={get action(){return a},get location(){return e(s,o)},listen(x){if(l)throw new Error("A history only accepts one active listener");return s.addEventListener(Dg,d),l=x,()=>{s.removeEventListener(Dg,d),l=null}},createHref(x){return t(s,x)},createURL:w,encodeLocation(x){let m=w(x);return{pathname:m.pathname,search:m.search,hash:m.hash}},push:h,replace:f,go(x){return o.go(x)}};return y}var Mg;(function(e){e.data="data",e.deferred="deferred",e.redirect="redirect",e.error="error"})(Mg||(Mg={}));function aR(e,t,n){return n===void 0&&(n="/"),lR(e,t,n,!1)}function lR(e,t,n,r){let s=typeof t=="string"?Mi(t):t,i=Nb(s.pathname||"/",n);if(i==null)return null;let o=Rb(e);cR(o);let a=null;for(let l=0;a==null&&l<o.length;++l){let c=xR(i);a=vR(o[l],c,r)}return a}function Rb(e,t,n,r){t===void 0&&(t=[]),n===void 0&&(n=[]),r===void 0&&(r="");let s=(i,o,a)=>{let l={relativePath:a===void 0?i.path||"":a,caseSensitive:i.caseSensitive===!0,childrenIndex:o,route:i};l.relativePath.startsWith("/")&&(Oe(l.relativePath.startsWith(r),'Absolute route path "'+l.relativePath+'" nested under path '+('"'+r+'" is not valid. An absolute child route path ')+"must start with the combined path of all its parent routes."),l.relativePath=l.relativePath.slice(r.length));let c=ls([r,l.relativePath]),u=n.concat(l);i.children&&i.children.length>0&&(Oe(i.index!==!0,"Index routes must not have child routes. Please remove "+('all child routes from route path "'+c+'".')),Rb(i.children,t,u,c)),!(i.path==null&&!i.index)&&t.push({path:c,score:gR(c,i.index),routesMeta:u})};return e.forEach((i,o)=>{var a;if(i.path===""||!((a=i.path)!=null&&a.includes("?")))s(i,o);else for(let l of jb(i.path))s(i,o,l)}),t}function jb(e){let t=e.split("/");if(t.length===0)return[];let[n,...r]=t,s=n.endsWith("?"),i=n.replace(/\?$/,"");if(r.length===0)return s?[i,""]:[i];let o=jb(r.join("/")),a=[];return a.push(...o.map(l=>l===""?i:[i,l].join("/"))),s&&a.push(...o),a.map(l=>e.startsWith("/")&&l===""?"/":l)}function cR(e){e.sort((t,n)=>t.score!==n.score?n.score-t.score:yR(t.routesMeta.map(r=>r.childrenIndex),n.routesMeta.map(r=>r.childrenIndex)))}const uR=/^:[\w-]+$/,dR=3,hR=2,fR=1,pR=10,mR=-2,$g=e=>e==="*";function gR(e,t){let n=e.split("/"),r=n.length;return n.some($g)&&(r+=mR),t&&(r+=hR),n.filter(s=>!$g(s)).reduce((s,i)=>s+(uR.test(i)?dR:i===""?fR:pR),r)}function yR(e,t){return e.length===t.length&&e.slice(0,-1).every((r,s)=>r===t[s])?e[e.length-1]-t[t.length-1]:0}function vR(e,t,n){let{routesMeta:r}=e,s={},i="/",o=[];for(let a=0;a<r.length;++a){let l=r[a],c=a===r.length-1,u=i==="/"?t:t.slice(i.length)||"/",d=Vg({path:l.relativePath,caseSensitive:l.caseSensitive,end:c},u),h=l.route;if(!d&&c&&n&&!r[r.length-1].route.index&&(d=Vg({path:l.relativePath,caseSensitive:l.caseSensitive,end:!1},u)),!d)return null;
vendor: 6,356 bytes, lines 195-204
195Object.assign(s,d.params),o.push({params:s,pathname:ls([i,d.pathname]),pathnameBase:kR(ls([i,d.pathnameBase])),route:h}),d.pathnameBase!=="/"&&(i=ls([i,d.pathnameBase]))}return o}function Vg(e,t){typeof e=="string"&&(e={path:e,caseSensitive:!1,end:!0});let[n,r]=wR(e.path,e.caseSensitive,e.end),s=t.match(n);if(!s)return null;let i=s[0],o=i.replace(/(.)\/+$/,"$1"),a=s.slice(1);return{params:r.reduce((c,u,d)=>{let{paramName:h,isOptional:f}=u;if(h==="*"){let y=a[d]||"";o=i.slice(0,i.length-y.length).replace(/(.)\/+$/,"$1")}const w=a[d];return f&&!w?c[h]=void 0:c[h]=(w||"").replace(/%2F/g,"/"),c},{}),pathname:i,pathnameBase:o,pattern:e}}function wR(e,t,n){t===void 0&&(t=!1),n===void 0&&(n=!0),Pb(e==="*"||!e.endsWith("*")||e.endsWith("/*"),'Route path "'+e+'" will be treated as if it were '+('"'+e.replace(/\*$/,"/*")+'" because the `*` character must ')+"always follow a `/` in the pattern. To get rid of this warning, "+('please change the route path to "'+e.replace(/\*$/,"/*")+'".'));let r=[],s="^"+e.replace(/\/*\*?$/,"").replace(/^\/*/,"/").replace(/[\\.*+^${}|()[\]]/g,"\\$&").replace(/\/:([\w-]+)(\?)?/g,(o,a,l)=>(r.push({paramName:a,isOptional:l!=null}),l?"/?([^\\/]+)?":"/([^\\/]+)"));return e.endsWith("*")?(r.push({paramName:"*"}),s+=e==="*"||e==="/*"?"(.*)$":"(?:\\/(.+)|\\/*)$"):n?s+="\\/*$":e!==""&&e!=="/"&&(s+="(?:(?=\\/|$))"),[new RegExp(s,t?void 0:"i"),r]}function xR(e){try{return e.split("/").map(t=>decodeURIComponent(t).replace(/\//g,"%2F")).join("/")}catch(t){return Pb(!1,'The URL path "'+e+'" could not be decoded because it is is a malformed URL segment. This is probably due to a bad percent '+("encoding ("+t+").")),e}}function Nb(e,t){if(t==="/")return e;if(!e.toLowerCase().startsWith(t.toLowerCase()))return null;let n=t.endsWith("/")?t.length-1:t.length,r=e.charAt(n);return r&&r!=="/"?null:e.slice(n)||"/"}function bR(e,t){t===void 0&&(t="/");let{pathname:n,search:r="",hash:s=""}=typeof e=="string"?Mi(e):e;return{pathname:n?n.startsWith("/")?n:SR(n,t):t,search:ER(r),hash:TR(s)}}function SR(e,t){let n=t.replace(/\/+$/,"").split("/");return e.split("/").forEach(s=>{s===".."?n.length>1&&n.pop():s!=="."&&n.push(s)}),n.length>1?n.join("/"):"/"}function Iu(e,t,n,r){return"Cannot include a '"+e+"' character in a manually specified "+("`to."+t+"` field ["+JSON.stringify(r)+"]. Please separate it out to the ")+("`to."+n+"` field. Alternatively you may provide the full path as ")+'a string in <Link to="..."> and the router will parse it for you.'}function _R(e){return e.filter((t,n)=>n===0||t.route.path&&t.route.path.length>0)}function Ob(e,t){let n=_R(e);return t?n.map((r,s)=>s===n.length-1?r.pathname:r.pathnameBase):n.map(r=>r.pathnameBase)}function Ib(e,t,n,r){r===void 0&&(r=!1);let s;typeof e=="string"?s=Mi(e):(s=Go({},e),Oe(!s.pathname||!s.pathname.includes("?"),Iu("?","pathname","search",s)),Oe(!s.pathname||!s.pathname.includes("#"),Iu("#","pathname","hash",s)),Oe(!s.search||!s.search.includes("#"),Iu("#","search","hash",s)));let i=e===""||s.pathname==="",o=i?"/":s.pathname,a;if(o==null)a=n;else{let d=t.length-1;if(!r&&o.startsWith("..")){let h=o.split("/");for(;h[0]==="..";)h.shift(),d-=1;s.pathname=h.join("/")}a=d>=0?t[d]:"/"}let l=bR(s,a),c=o&&o!=="/"&&o.endsWith("/"),u=(i||o===".")&&n.endsWith("/");return!l.pathname.endsWith("/")&&(c||u)&&(l.pathname+="/"),l}const ls=e=>e.join("/").replace(/\/\/+/g,"/"),kR=e=>e.replace(/\/+$/,"").replace(/^\/*/,"/"),ER=e=>!e||e==="?"?"":e.startsWith("?")?e:"?"+e,TR=e=>!e||e==="#"?"":e.startsWith("#")?e:"#"+e;function CR(e){return e!=null&&typeof e.status=="number"&&typeof e.statusText=="string"&&typeof e.internal=="boolean"&&"data"in e}const Db=["post","put","patch","delete"];new Set(Db);const PR=["get",...Db];new Set(PR);/** 196 * React Router v6.30.1 197 * 198 * Copyright (c) Remix Software Inc. 199 * 200 * This source code is licensed under the MIT license found in the 201 * LICENSE.md file in the root directory of this source tree. 202 * 203 * @license MIT 204 */function Yo(){return Yo=Object.assign?Object.assign.bind():function(e){for(var t=1;t<arguments.length;t++){var n=arguments[t];for(var r in n)Object.prototype.hasOwnProperty.call(n,r)&&(e[r]=n[r])}return e},Yo.apply(this,arguments)}const ip=b.createContext(null),AR=b.createContext(null),va=b.createContext(null),Fc=b.createContext(null),ws=b.createContext({outlet:null,matches:[],isDataRoute:!1}),Lb=b.createContext(null);function wa(){return b.useContext(Fc)!=null}function Uc(){return wa()||Oe(!1),b.useContext(Fc).location}function Mb(e){b.useContext(va).static||b.useLayoutEffect(e)}function RR(){let{isDataRoute:e}=b.useContext(ws);return e?zR():jR()}function jR(){wa()||Oe(!1);let e=b.useContext(ip),{basename:t,future:n,navigator:r}=b.useContext(va),{matches:s}=b.useContext(ws),{pathname:i}=Uc(),o=JSON.stringify(Ob(s,n.v7_relativeSplatPath)),a=b.useRef(!1);return Mb(()=>{a.current=!0}),b.useCallback(function(c,u){if(u===void 0&&(u={}),!a.current)return;if(typeof c=="number"){r.go(c);return}let d=Ib(c,JSON.parse(o),i,u.relative==="path");e==null&&t!=="/"&&(d.pathname=d.pathname==="/"?t:ls([t,d.pathname])),(u.replace?r.replace:r.push)(d,u.state,u)},[t,r,o,i,e])}function NR(e,t){return OR(e,t)}function OR(e,t,n,r){wa()||Oe(!1);let{navigator:s}=b.useContext(va),{matches:i}=b.useContext(ws),o=i[i.length-1],a=o?o.params:{};o&&o.pathname;let l=o?o.pathnameBase:"/";o&&o.route;let c=Uc(),u;if(t){var d;let x=typeof t=="string"?Mi(t):t;l==="/"||(d=x.pathname)!=null&&d.startsWith(l)||Oe(!1),u=x}else u=c;let h=u.pathname||"/",f=h;if(l!=="/"){let x=l.replace(/^\//,"").split("/");f="/"+h.replace(/^\//,"").split("/").slice(x.length).join("/")}let w=aR(e,{pathname:f}),y=$R(w&&w.map(x=>Object.assign({},x,{params:Object.assign({},a,x.params),pathname:ls([l,s.encodeLocation?s.encodeLocation(x.pathname).pathname:x.pathname]),pathnameBase:x.pathnameBase==="/"?l:ls([l,s.encodeLocation?s.encodeLocation(x.pathnameBase).pathname:x.pathnameBase])})),i,n,r);return t&&y?b.createElement(Fc.Provider,{value:{location:Yo({pathname:"/",search:"",hash:"",state:null,key:"default"},u),navigationType:hr.Pop}},y):y}function IR(){let e=BR(),t=CR(e)?e.status+" "+e.statusText:e instanceof Error?e.message:JSON.stringify(e),n=e instanceof Error?e.stack:null,s={padding:"0.5rem",backgroundColor:"rgba(200,200,200, 0.5)"};return b.createElement(b.Fragment,null,b.createElement("h2",null,"Unexpected Application
204Error!"),b.createElement("h3",{style:{fontStyle:"italic"}},t),n?b.createElement("pre",{style:s},n):null,null)}const DR=b.createElement(IR,null);class LR extends b.Component{constructor(t){super(t),this.state={location:t.location,revalidation:t.revalidation,error:t.error}}static getDerivedStateFromError(t){return{error:t}}static getDerivedStateFromProps(t,n){return n.location!==t.location||n.revalidation!=="idle"&&t.revalidation==="idle"?{error:t.error,location:t.location,revalidation:t.revalidation}:{error:t.error!==void 0?t.error:n.error,location:n.location,revalidation:t.revalidation||n.revalidation}}componentDidCatch(t,n){console.error("React Router caught the following error during render",t,n)}render(){return this.state.error!==void 0?b.createElement(ws.Provider,{value:this.props.routeContext},b.createElement(Lb.Provider,{value:this.state.error,children:this.props.component})):this.props.children}}function MR(e){let{routeContext:t,match:n,children:r}=e,s=b.useContext(ip);return s&&s.static&&s.staticContext&&(n.route.errorElement||n.route.ErrorBoundary)&&(s.staticContext._deepestRenderedBoundaryId=n.route.id),b.createElement(ws.Provider,{value:t},r)}function $R(e,t,n,r){var s;if(t===void 0&&(t=[]),n===void 0&&(n=null),r===void 0&&(r=null),e==null){var i;if(!n)return null;if(n.errors)e=n.matches;else if((i=r)!=null&&i.v7_partialHydration&&t.length===0&&!n.initialized&&n.matches.length>0)e=n.matches;else return null}let o=e,a=(s=n)==null?void 0:s.errors;if(a!=null){let u=o.findIndex(d=>d.route.id&&(a==null?void 0:a[d.route.id])!==void 0);u>=0||Oe(!1),o=o.slice(0,Math.min(o.length,u+1))}let l=!1,c=-1;if(n&&r&&r.v7_partialHydration)for(let u=0;u<o.length;u++){let d=o[u];if((d.route.HydrateFallback||d.route.hydrateFallbackElement)&&(c=u),d.route.id){let{loaderData:h,errors:f}=n,w=d.route.loader&&h[d.route.id]===void 0&&(!f||f[d.route.id]===void 0);if(d.route.lazy||w){l=!0,c>=0?o=o.slice(0,c+1):o=[o[0]];break}}}return o.reduceRight((u,d,h)=>{let f,w=!1,y=null,x=null;n&&(f=a&&d.route.id?a[d.route.id]:void 0,y=d.route.errorElement||DR,l&&(c<0&&h===0?(w=!0,x=null):c===h&&(w=!0,x=d.route.hydrateFallbackElement||null)));let m=t.concat(o.slice(0,h+1)),g=()=>{let v;return f?v=y:w?v=x:d.route.Component?v=b.createElement(d.route.Component,null):d.route.element?v=d.route.element:v=u,b.createElement(MR,{match:d,routeContext:{outlet:u,matches:m,isDataRoute:n!=null},children:v})};return n&&(d.route.ErrorBoundary||d.route.errorElement||h===0)?b.createElement(LR,{location:n.location,revalidation:n.revalidation,component:y,error:f,children:g(),routeContext:{outlet:null,matches:m,isDataRoute:!0}}):g()},null)}var $b=function(e){return e.UseBlocker="useBlocker",e.UseRevalidator="useRevalidator",e.UseNavigateStable="useNavigate",e}($b||{}),rc=function(e){return e.UseBlocker="useBlocker",e.UseLoaderData="useLoaderData",e.UseActionData="useActionData",e.UseRouteError="useRouteError",e.UseNavigation="useNavigation",e.UseRouteLoaderData="useRouteLoaderData",e.UseMatches="useMatches",e.UseRevalidator="useRevalidator",e.UseNavigateStable="useNavigate",e.UseRouteId="useRouteId",e}(rc||{});function VR(e){let t=b.useContext(ip);return t||Oe(!1),t}function FR(e){let t=b.useContext(AR);return t||Oe(!1),t}function UR(e){let t=b.useContext(ws);return t||Oe(!1),t}function Vb(e){let t=UR(),n=t.matches[t.matches.length-1];return n.route.id||Oe(!1),n.route.id}function BR(){var e;let t=b.useContext(Lb),n=FR(rc.UseRouteError),r=Vb(rc.UseRouteError);return t!==void 0?t:(e=n.errors)==null?void 0:e[r]}function zR(){let{router:e}=VR($b.UseNavigateStable),t=Vb(rc.UseNavigateStable),n=b.useRef(!1);return Mb(()=>{n.current=!0}),b.useCallback(function(s,i){i===void 0&&(i={}),n.current&&(typeof s=="number"?e.navigate(s):e.navigate(s,Yo({fromRouteId:t},i)))},[e,t])}function WR(e,t){e==null||e.v7_startTransition,e==null||e.v7_relativeSplatPath}function HR(e){let{to:t,replace:n,state:r,relative:s}=e;wa()||Oe(!1);let{future:i,static:o}=b.useContext(va),{matches:a}=b.useContext(ws),{pathname:l}=Uc(),c=RR(),u=Ib(t,Ob(a,i.v7_relativeSplatPath),l,s==="path"),d=JSON.stringify(u);return b.useEffect(()=>c(JSON.parse(d),{replace:n,state:r,relative:s}),[c,d,s,n,r]),null}function Jn(e){Oe(!1)}function KR(e){let{basename:t="/",children:n=null,location:r,navigationType:s=hr.Pop,navigator:i,static:o=!1,future:a}=e;wa()&&Oe(!1);let l=t.replace(/^\/*/,"/"),c=b.useMemo(()=>({basename:l,navigator:i,static:o,future:Yo({v7_relativeSplatPath:!1},a)}),[l,a,i,o]);typeof r=="string"&&(r=Mi(r));
204let{pathname:u="/",search:d="",hash:h="",state:f=null,key:w="default"}=r,y=b.useMemo(()=>{let x=Nb(u,l);return x==null?null:{location:{pathname:x,search:d,hash:h,state:f,key:w},navigationType:s}},[l,u,d,h,f,w,s]);return y==null?null:b.createElement(va.Provider,{value:c},b.createElement(Fc.Provider,{children:n,value:y}))}function qR(e){let{children:t,location:n}=e;return NR(dh(t),n)}new Promise(()=>{});function dh(e,t){t===void 0&&(t=[]);let n=[];return b.Children.forEach(e,(r,s)=>{if(!b.isValidElement(r))return;let i=[...t,s];if(r.type===b.Fragment){n.push.apply(n,dh(r.props.children,i));return}r.type!==Jn&&Oe(!1),!r.props.index||!r.props.children||Oe(!1);let o={id:r.props.id||i.join("-"),caseSensitive:r.props.caseSensitive,element:r.props.element,Component:r.props.Component,index:r.props.index,path:r.props.path,loader:r.props.loader,action:r.props.action,errorElement:r.props.errorElement,ErrorBoundary:r.props.ErrorBoundary,hasErrorBoundary:r.props.ErrorBoundary!=null||r.props.errorElement!=null,shouldRevalidate:r.props.shouldRevalidate,handle:r.props.handle,lazy:r.props.lazy};r.props.children&&(o.children=dh(r.props.children,i)),n.push(o)}),n}/** 205 * React Router DOM v6.30.1 206 * 207 * Copyright (c) Remix Software Inc. 208 * 209 * This source code is licensed under the MIT license found in the 210 * LICENSE.md file in the root directory of this source tree. 211 * 212 * @license MIT 213 */const GR="6";try{window.__reactRouterVersion=GR}catch{}const YR="startTransition",Fg=Kv[YR];function QR(e){let{basename:t,children:n,future:r,window:s}=e,i=b.useRef();i.current==null&&(i.current=sR({window:s,v5Compat:!0}));let o=i.current,[a,l]=b.useState({action:o.action,location:o.location}),{v7_startTransition:c}=r||{},u=b.useCallback(d=>{c&&Fg?Fg(()=>l(d)):l(d)},[l,c]);return b.useLayoutEffect(()=>o.listen(u),[o,u]),b.useEffect(()=>WR(r),[r]),b.createElement(KR,{basename:t,children:n,location:a.location,navigationType:a.action,navigator:o,future:r})}var Ug;(function(e){e.UseScrollRestoration="useScrollRestoration",e.UseSubmit="useSubmit",e.UseSubmitFetcher="useSubmitFetcher",e.UseFetcher="useFetcher",e.useViewTransitionState="useViewTransitionState"})(Ug||(Ug={}));var Bg;(function(e){e.UseFetcher="useFetcher",e.UseFetchers="useFetchers",e.UseScrollRestoration="useScrollRestoration"})(Bg||(Bg={}));const Fb=b.createContext({});function JR(e){const t=b.useRef(null);return t.current===null&&(t.current=e()),t.current}const op=typeof window<"u",XR=op?b.useLayoutEffect:b.useEffect,ap=b.createContext(null);function lp(e,t){e.indexOf(t)===-1&&e.push(t)}function cp(e,t){const n=e.indexOf(t);n>-1&&e.splice(n,1)}const Ln=(e,t,n)=>n>t?t:n<e?e:n;let sc=()=>{};const Mn={},Ub=e=>/^-?(?:\d+(?:\.\d+)?|\.\d+)$/u.test(e);function Bb(e){return typeof e=="object"&&e!==null}const zb=e=>/^0[^.\s]+$/u.test(e);function up(e){let t;return()=>(t===void 0&&(t=e()),t)}const It=e=>e,ZR=(e,t)=>n=>t(e(n)),xa=(...e)=>e.reduce(ZR),Qo=(e,t,n)=>{const r=t-e;return r===0?1:(n-e)/r};class dp{constructor(){this.subscriptions=[]}add(t){return lp(this.subscriptions,t),()=>cp(this.subscriptions,t)}notify(t,n,r){const s=this.subscriptions.length;if(s)if(s===1)this.subscriptions[0](t,n,r);else for(let i=0;i<s;i++){const o=this.subscriptions[i];o&&o(t,n,r)}}getSize(){return this.subscriptions.length}clear(){this.subscriptions.length=0}}const yn=e=>e*1e3,Nt=e=>e/1e3;function Wb(e,t){return t?e*(1e3/t):0}const Hb=(e,t,n)=>(((1-3*n+3*t)*e+(3*n-6*t))*e+3*t)*e,ej=1e-7,tj=12;function nj(e,t,n,r,s){let i,o,a=0;do o=t+(n-t)/2,i=Hb(o,r,s)-e,i>0?n=o:t=o;while(Math.abs(i)>ej&&++a<tj);return o}function ba(e,t,n,r){if(e===t&&n===r)return It;const s=i=>nj(i,0,1,e,n);return i=>i===0||i===1?i:Hb(s(i),t,r)}const Kb=e=>t=>t<=.5?e(2*t)/2:(2-e(2*(1-t)))/2,qb=e=>t=>1-e(1-t),Gb=ba(.33,1.53,.69,.99),hp=qb(Gb),Yb=Kb(hp),Qb=e=>(e*=2)<1?.5*hp(e):.5*(2-Math.pow(2,-10*(e-1))),fp=e=>1-Math.sin(Math.acos(e)),Jb=qb(fp),Xb=Kb(fp),rj=ba(.42,0,1,1),sj=ba(0,0,.58,1),Zb=ba(.42,0,.58,1),ij=e=>Array.isArray(e)&&typeof e[0]!="number",e1=e=>Array.isArray(e)&&typeof e[0]=="number",zg={linear:It,easeIn:rj,easeInOut:Zb,easeOut:sj,circIn:fp,circInOut:Xb,circOut:Jb,backIn:hp,backInOut:Yb,backOut:Gb,anticipate:Qb},oj=e=>typeof e=="string",Wg=e=>{if(e1(e)){sc(e.length===4);const[t,n,r,s]=e;return ba(t,n,r,s)}else if(oj(e))return sc(zg[e]!==void 0),zg[e];return e},Ja=["setup","read","resolveKeyframes","preUpdate","update","preRender","render","postRender"],Hg={value:null,addProjectionMetrics:null};function aj(e,t){let n=new Set,r=new Set,s=!1,i=!1;const o=new WeakSet;let a={delta:0,timestamp:0,isProcessing:!1},l=0;function c(d){o.has(d)&&(u.schedule(d),e()),l++,d(a)}const u={schedule:(d,h=!1,f=!1)=>{const y=f&&s?n:r;return h&&o.add(d),y.has(d)||y.add(d),d},cancel:d=>
vendor: 5,238 bytes, line 213
213{r.delete(d),o.delete(d)},process:d=>{if(a=d,s){i=!0;return}s=!0,[n,r]=[r,n],n.forEach(c),t&&Hg.value&&Hg.value.frameloop[t].push(l),l=0,n.clear(),s=!1,i&&(i=!1,u.process(d))}};return u}const lj=40;function t1(e,t){let n=!1,r=!0;const s={delta:0,timestamp:0,isProcessing:!1},i=()=>n=!0,o=Ja.reduce((v,S)=>(v[S]=aj(i,t?S:void 0),v),{}),{setup:a,read:l,resolveKeyframes:c,preUpdate:u,update:d,preRender:h,render:f,postRender:w}=o,y=()=>{const v=Mn.useManualTiming?s.timestamp:performance.now();n=!1,Mn.useManualTiming||(s.delta=r?1e3/60:Math.max(Math.min(v-s.timestamp,lj),1)),s.timestamp=v,s.isProcessing=!0,a.process(s),l.process(s),c.process(s),u.process(s),d.process(s),h.process(s),f.process(s),w.process(s),s.isProcessing=!1,n&&t&&(r=!1,e(y))},x=()=>{n=!0,r=!0,s.isProcessing||e(y)};return{schedule:Ja.reduce((v,S)=>{const _=o[S];return v[S]=(k,E=!1,T=!1)=>(n||x(),_.schedule(k,E,T)),v},{}),cancel:v=>{for(let S=0;S<Ja.length;S++)o[Ja[S]].cancel(v)},state:s,steps:o}}const{schedule:ge,cancel:Pr,state:We,steps:Du}=t1(typeof requestAnimationFrame<"u"?requestAnimationFrame:It,!0);let Sl;function cj(){Sl=void 0}const ht={now:()=>(Sl===void 0&&ht.set(We.isProcessing||Mn.useManualTiming?We.timestamp:performance.now()),Sl),set:e=>{Sl=e,queueMicrotask(cj)}},n1=e=>t=>typeof t=="string"&&t.startsWith(e),r1=n1("--"),uj=n1("var(--"),pp=e=>uj(e)?dj.test(e.split("/*")[0].trim()):!1,dj=/var\(--(?:[\w-]+\s*|[\w-]+\s*,(?:\s*[^)(\s]|\s*\((?:[^)(]|\([^)(]*\))*\))+\s*)\)$/iu,$i={test:e=>typeof e=="number",parse:parseFloat,transform:e=>e},Jo={...$i,transform:e=>Ln(0,1,e)},Xa={...$i,default:1},bo=e=>Math.round(e*1e5)/1e5,mp=/-?(?:\d+(?:\.\d+)?|\.\d+)/gu;function hj(e){return e==null}const fj=/^(?:#[\da-f]{3,8}|(?:rgb|hsl)a?\((?:-?[\d.]+%?[,\s]+){2}-?[\d.]+%?\s*(?:[,/]\s*)?(?:\b\d+(?:\.\d+)?|\.\d+)?%?\))$/iu,gp=(e,t)=>n=>!!(typeof n=="string"&&fj.test(n)&&n.startsWith(e)||t&&!hj(n)&&Object.prototype.hasOwnProperty.call(n,t)),s1=(e,t,n)=>r=>{if(typeof r!="string")return r;const[s,i,o,a]=r.match(mp);return{[e]:parseFloat(s),[t]:parseFloat(i),[n]:parseFloat(o),alpha:a!==void 0?parseFloat(a):1}},pj=e=>Ln(0,255,e),Lu={...$i,transform:e=>Math.round(pj(e))},Jr={test:gp("rgb","red"),parse:s1("red","green","blue"),transform:({red:e,green:t,blue:n,alpha:r=1})=>"rgba("+Lu.transform(e)+", "+Lu.transform(t)+", "+Lu.transform(n)+", "+bo(Jo.transform(r))+")"};function mj(e){let t="",n="",r="",s="";return e.length>5?(t=e.substring(1,3),n=e.substring(3,5),r=e.substring(5,7),s=e.substring(7,9)):(t=e.substring(1,2),n=e.substring(2,3),r=e.substring(3,4),s=e.substring(4,5),t+=t,n+=n,r+=r,s+=s),{red:parseInt(t,16),green:parseInt(n,16),blue:parseInt(r,16),alpha:s?parseInt(s,16)/255:1}}const hh={test:gp("#"),parse:mj,transform:Jr.transform},Sa=e=>({test:t=>typeof t=="string"&&t.endsWith(e)&&t.split(" ").length===1,parse:parseFloat,transform:t=>`${t}${e}`}),Xn=Sa("deg"),vn=Sa("%"),H=Sa("px"),gj=Sa("vh"),yj=Sa("vw"),Kg={...vn,parse:e=>vn.parse(e)/100,transform:e=>vn.transform(e*100)},Qs={test:gp("hsl","hue"),parse:s1("hue","saturation","lightness"),transform:({hue:e,saturation:t,lightness:n,alpha:r=1})=>"hsla("+Math.round(e)+", "+vn.transform(bo(t))+", "+vn.transform(bo(n))+", "+bo(Jo.transform(r))+")"},je={test:e=>Jr.test(e)||hh.test(e)||Qs.test(e),parse:e=>Jr.test(e)?Jr.parse(e):Qs.test(e)?Qs.parse(e):hh.parse(e),transform:e=>typeof e=="string"?e:e.hasOwnProperty("red")?Jr.transform(e):Qs.transform(e),getAnimatableNone:e=>{const t=je.parse(e);return t.alpha=0,je.transform(t)}},vj=/(?:#[\da-f]{3,8}|(?:rgb|hsl)a?\((?:-?[\d.]+%?[,\s]+){2}-?[\d.]+%?\s*(?:[,/]\s*)?(?:\b\d+(?:\.\d+)?|\.\d+)?%?\))/giu;function wj(e){var t,n;return isNaN(e)&&typeof e=="string"&&(((t=e.match(mp))==null?void 0:t.length)||0)+(((n=e.match(vj))==null?void 0:n.length)||0)>0}const i1="number",o1="color",xj="var",bj="var(",qg="${}",Sj=/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 Xo(e){const t=e.toString(),n=[],r={color:[],number:[],var:[]},s=[];let i=0;const a=t.replace(Sj,l=>(je.test(l)?(r.color.push(i),s.push(o1),n.push(je.parse(l))):l.startsWith(bj)?(r.var.push(i),s.push(xj),n.push(l)):(r.number.push(i),s.push(i1),n.push(parseFloat(l))),++i,qg)).split(qg);return{values:n,split:a,indexes:r,types:s}}function a1(e){return Xo(e).values}function l1(e){const{split:t,types:n}=Xo(e),r=t.length;return s=>{let i="";for(let o=0;o<r;o++)if(i+=t[o],s[o]!==void 0){const a=n[o];a===i1?i+=bo(s[o]):a===o1?i+=je.transform(s[o]):i+=s[o]}return i}}const _j=e=>typeof e=="number"?0:je.test(e)?je.getAnimatableNone(e):e;function kj(e){const t=a1(e);return l1(e)(t.map(_j))}const Ar={test:wj,parse:a1,createTransformer:l1,getAnimatableNone:kj};function Mu(e,t,n){return n<0&&(n+=1),n>1&&(n-=1),n<1/6?e+(t-e)*6*n:n<1/2?t:n<2/3?e+(t-e)*(2/3-n)*6:e}function Ej({hue:e,saturation:t,lightness:n,alpha:r}){e/=360,t/=100,n/=100;let s=0,i=0,o=0;if(!t)s=i=o=n;else{const a=n<.5?n*(1+t):n+t-n*t,l=2*n-a;s=Mu(l,a,e+1/3),i=Mu(l,a,e),o=Mu(l,a,e-1/3)}return{red:Math.round(s*255),green:Math.round(i*255),blue:Math.round(o*255),alpha:r}}function ic(e,t){return n=>n>0?t:e}const we=(e,t,n)=>
vendor: 20,357 bytes, line 213
213e+(t-e)*n,$u=(e,t,n)=>{const r=e*e,s=n*(t*t-r)+r;return s<0?0:Math.sqrt(s)},Tj=[hh,Jr,Qs],Cj=e=>Tj.find(t=>t.test(e));function Gg(e){const t=Cj(e);if(!t)return!1;let n=t.parse(e);return t===Qs&&(n=Ej(n)),n}const Yg=(e,t)=>{const n=Gg(e),r=Gg(t);if(!n||!r)return ic(e,t);const s={...n};return i=>(s.red=$u(n.red,r.red,i),s.green=$u(n.green,r.green,i),s.blue=$u(n.blue,r.blue,i),s.alpha=we(n.alpha,r.alpha,i),Jr.transform(s))},fh=new Set(["none","hidden"]);function Pj(e,t){return fh.has(e)?n=>n<=0?e:t:n=>n>=1?t:e}function Aj(e,t){return n=>we(e,t,n)}function yp(e){return typeof e=="number"?Aj:typeof e=="string"?pp(e)?ic:je.test(e)?Yg:Nj:Array.isArray(e)?c1:typeof e=="object"?je.test(e)?Yg:Rj:ic}function c1(e,t){const n=[...e],r=n.length,s=e.map((i,o)=>yp(i)(i,t[o]));return i=>{for(let o=0;o<r;o++)n[o]=s[o](i);return n}}function Rj(e,t){const n={...e,...t},r={};for(const s in n)e[s]!==void 0&&t[s]!==void 0&&(r[s]=yp(e[s])(e[s],t[s]));return s=>{for(const i in r)n[i]=r[i](s);return n}}function jj(e,t){const n=[],r={color:0,var:0,number:0};for(let s=0;s<t.values.length;s++){const i=t.types[s],o=e.indexes[i][r[i]],a=e.values[o]??0;n[s]=a,r[i]++}return n}const Nj=(e,t)=>{const n=Ar.createTransformer(t),r=Xo(e),s=Xo(t);return r.indexes.var.length===s.indexes.var.length&&r.indexes.color.length===s.indexes.color.length&&r.indexes.number.length>=s.indexes.number.length?fh.has(e)&&!s.values.length||fh.has(t)&&!r.values.length?Pj(e,t):xa(c1(jj(r,s),s.values),n):ic(e,t)};function u1(e,t,n){return typeof e=="number"&&typeof t=="number"&&typeof n=="number"?we(e,t,n):yp(e)(e,t)}const Oj=e=>{const t=({timestamp:n})=>e(n);return{start:(n=!0)=>ge.update(t,n),stop:()=>Pr(t),now:()=>We.isProcessing?We.timestamp:ht.now()}},d1=(e,t,n=10)=>{let r="";const s=Math.max(Math.round(t/n),2);for(let i=0;i<s;i++)r+=Math.round(e(i/(s-1))*1e4)/1e4+", ";return`linear(${r.substring(0,r.length-2)})`},oc=2e4;function vp(e){let t=0;const n=50;let r=e.next(t);for(;!r.done&&t<oc;)t+=n,r=e.next(t);return t>=oc?1/0:t}function Ij(e,t=100,n){const r=n({...e,keyframes:[0,t]}),s=Math.min(vp(r),oc);return{type:"keyframes",ease:i=>r.next(s*i).value/t,duration:Nt(s)}}const Dj=5;function h1(e,t,n){const r=Math.max(t-Dj,0);return Wb(n-e(r),t-r)}const ke={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},Vu=.001;function Lj({duration:e=ke.duration,bounce:t=ke.bounce,velocity:n=ke.velocity,mass:r=ke.mass}){let s,i,o=1-t;o=Ln(ke.minDamping,ke.maxDamping,o),e=Ln(ke.minDuration,ke.maxDuration,Nt(e)),o<1?(s=c=>{const u=c*o,d=u*e,h=u-n,f=ph(c,o),w=Math.exp(-d);return Vu-h/f*w},i=c=>{const d=c*o*e,h=d*n+n,f=Math.pow(o,2)*Math.pow(c,2)*e,w=Math.exp(-d),y=ph(Math.pow(c,2),o);return(-s(c)+Vu>0?-1:1)*((h-f)*w)/y}):(s=c=>{const u=Math.exp(-c*e),d=(c-n)*e+1;return-Vu+u*d},i=c=>{const u=Math.exp(-c*e),d=(n-c)*(e*e);return u*d});const a=5/e,l=$j(s,i,a);if(e=yn(e),isNaN(l))return{stiffness:ke.stiffness,damping:ke.damping,duration:e};{const c=Math.pow(l,2)*r;return{stiffness:c,damping:o*2*Math.sqrt(r*c),duration:e}}}const Mj=12;function $j(e,t,n){let r=n;for(let s=1;s<Mj;s++)r=r-e(r)/t(r);return r}function ph(e,t){return e*Math.sqrt(1-t*t)}const Vj=["duration","bounce"],Fj=["stiffness","damping","mass"];function Qg(e,t){return t.some(n=>e[n]!==void 0)}function Uj(e){let t={velocity:ke.velocity,stiffness:ke.stiffness,damping:ke.damping,mass:ke.mass,isResolvedFromDuration:!1,...e};if(!Qg(e,Fj)&&Qg(e,Vj))if(e.visualDuration){const n=e.visualDuration,r=2*Math.PI/(n*1.2),s=r*r,i=2*Ln(.05,1,1-(e.bounce||0))*Math.sqrt(s);t={...t,mass:ke.mass,stiffness:s,damping:i}}else{const n=Lj(e);t={...t,...n,mass:ke.mass},t.isResolvedFromDuration=!0}return t}function ac(e=ke.visualDuration,t=ke.bounce){const n=typeof e!="object"?{visualDuration:e,keyframes:[0,1],bounce:t}:e;let{restSpeed:r,restDelta:s}=n;const i=n.keyframes[0],o=n.keyframes[n.keyframes.length-1],a={done:!1,value:i},{stiffness:l,damping:c,mass:u,duration:d,velocity:h,isResolvedFromDuration:f}=Uj({...n,velocity:-Nt(n.velocity||0)}),w=h||0,y=c/(2*Math.sqrt(l*u)),x=o-i,m=Nt(Math.sqrt(l/u)),g=Math.abs(x)<5;r||(r=g?ke.restSpeed.granular:ke.restSpeed.default),s||(s=g?ke.restDelta.granular:ke.restDelta.default);let v;if(y<1){const _=ph(m,y);v=k=>{const E=Math.exp(-y*m*k);return o-E*((w+y*m*x)/_*Math.sin(_*k)+x*Math.cos(_*k))}}else if(y===1)v=_=>o-Math.exp(-m*_)*(x+(w+m*x)*_);else{const _=m*Math.sqrt(y*y-1);v=k=>{const E=Math.exp(-y*m*k),T=Math.min(_*k,300);return o-E*((w+y*m*x)*Math.sinh(T)+_*x*Math.cosh(T))/_}}const S={calculatedDuration:f&&d||null,next:_=>{const k=v(_);if(f)a.done=_>=d;else{let E=_===0?w:0;y<1&&(E=_===0?yn(w):h1(v,_,k));const T=Math.abs(E)<=r,j=Math.abs(o-k)<=s;a.done=T&&j}return a.value=a.done?o:k,a},toString:()=>{const _=Math.min(vp(S),oc),k=d1(E=>S.next(_*E).value,_,30);return _+"ms "+k},toTransition:()=>{}};return S}ac.applyToOptions=e=>{const t=Ij(e,100,ac);return e.ease=t.ease,e.duration=yn(t.duration),e.type="keyframes",e};function mh({keyframes:e,velocity:t=0,power:n=.8,timeConstant:r=325,bounceDamping:s=10,bounceStiffness:i=500,modifyTarget:o,min:a,max:l,restDelta:c=.5,restSpeed:u}){const d=e[0],h={done:!1,value:d},f=T=>a!==void 0&&T<a||l!==void 0&&T>l,w=T=>a===void 0?l:l===void 0||Math.abs(a-T)<Math.abs(l-T)?a:l;let y=n*t;const x=d+y,m=o===void 0?x:o(x);m!==x&&(y=m-d);const g=T=>-y*Math.exp(-T/r),v=T=>m+g(T),S=T=>{const j=g(T),O=v(T);h.done=Math.abs(j)<=c,h.value=h.done?m:O};let _,k;const E=T=>{f(h.value)&&(_=T,k=ac({keyframes:[h.value,w(h.value)],velocity:h1(v,T,h.value),damping:s,stiffness:i,restDelta:c,restSpeed:u}))};return E(0),{calculatedDuration:null,next:T=>{let j=!1;return!k&&_===void 0&&(j=!0,S(T),E(T)),_!==void 0&&T>=_?k.next(T-_):(!j&&S(T),h)}}}function Bj(e,t,n){const r=[],s=n||Mn.mix||u1,i=e.length-1;for(let o=0;o<i;o++){let a=s(e[o],e[o+1]);if(t){const l=Array.isArray(t)?t[o]||It:t;a=xa(l,a)}r.push(a)}return r}function zj(e,t,{clamp:n=!0,ease:r,mixer:s}={}){const i=e.length;if(sc(i===t.length),i===1)return()=>t[0];if(i===2&&t[0]===t[1])return()=>t[1];const o=e[0]===e[1];e[0]>e[i-1]&&(e=[...e].reverse(),t=[...t].reverse());const a=Bj(t,r,s),l=a.length,c=u=>{if(o&&u<e[0])return t[0];let d=0;if(l>1)for(;d<e.length-2&&!(u<e[d+1]);d++);const h=Qo(e[d],e[d+1],u);return a[d](h)};return n?u=>c(Ln(e[0],e[i-1],u)):c}function Wj(e,t){const n=e[e.length-1];for(let r=1;r<=t;r++){const s=Qo(0,t,r);e.push(we(n,1,s))}}function Hj(e){const t=[0];return Wj(t,e.length-1),t}function Kj(e,t){return e.map(n=>n*t)}function qj(e,t){return e.map(()=>t||Zb).splice(0,e.length-1)}function So({duration:e=300,keyframes:t,times:n,ease:r="easeInOut"}){const s=ij(r)?r.map(Wg):Wg(r),i={done:!1,value:t[0]},o=Kj(n&&n.length===t.length?n:Hj(t),e),a=zj(o,t,{ease:Array.isArray(s)?s:qj(t,s)});return{calculatedDuration:e,next:l=>(i.value=a(l),i.done=l>=e,i)}}const Gj=e=>e!==null;function wp(e,{repeat:t,repeatType:n="loop"},r,s=1){const i=e.filter(Gj),a=s<0||t&&n!=="loop"&&t%2===1?0:i.length-1;return!a||r===void 0?i[a]:r}const Yj={decay:mh,inertia:mh,tween:So,keyframes:So,spring:ac};function f1(e){typeof e.type=="string"&&(e.type=Yj[e.type])}class xp{constructor(){this.updateFinished()}get finished(){return this._finished}updateFinished(){this._finished=new Promise(t=>{this.resolve=t})}notifyFinished(){this.resolve()}then(t,n){return this.finished.then(t,n)}}const Qj=e=>e/100;class bp extends xp{constructor(t){super(),this.state="idle",this.startTime=null,this.isStopped=!1,this.currentTime=0,this.holdTime=null,this.playbackSpeed=1,this.stop=()=>{var r,s;const{motionValue:n}=this.options;n&&n.updatedAt!==ht.now()&&this.tick(ht.now()),this.isStopped=!0,this.state!=="idle"&&(this.teardown(),(s=(r=this.options).onStop)==null||s.call(r))},this.options=t,this.initAnimation(),this.play(),t.autoplay===!1&&this.pause()}initAnimation(){const{options:t}=this;f1(t);const{type:n=So,repeat:r=0,repeatDelay:s=0,repeatType:i,velocity:o=0}=t;let{keyframes:a}=t;const l=n||So;l!==So&&typeof a[0]!="number"&&(this.mixKeyframes=xa(Qj,u1(a[0],a[1])),a=[0,100]);const c=l({...t,keyframes:a});i==="mirror"&&(this.mirroredGenerator=l({...t,keyframes:[...a].reverse(),velocity:-o})),c.calculatedDuration===null&&(c.calculatedDuration=vp(c));const{calculatedDuration:u}=c;this.calculatedDuration=u,this.resolvedDuration=u+s,this.totalDuration=this.resolvedDuration*(r+1)-s,this.generator=c}updateTime(t){const n=Math.round(t-this.startTime)*this.playbackSpeed;this.holdTime!==null?this.currentTime=this.holdTime:this.currentTime=n}tick(t,n=!1){const{generator:r,totalDuration:s,mixKeyframes:i,mirroredGenerator:o,resolvedDuration:a,calculatedDuration:l}=this;if(this.startTime===null)return r.next(0);const{delay:c=0,keyframes:u,repeat:d,repeatType:h,repeatDelay:f,type:w,onUpdate:y,finalKeyframe:x}=this.options;this.speed>0?this.startTime=Math.min(this.startTime,t):this.speed<0&&(this.startTime=Math.min(t-s/this.speed,this.startTime)),n?this.currentTime=t:this.updateTime(t);const m=this.currentTime-c*(this.playbackSpeed>=0?1:-1),g=this.playbackSpeed>=0?m<0:m>s;this.currentTime=Math.max(m,0),this.state==="finished"&&this.holdTime===null&&(this.currentTime=s);let v=this.currentTime,S=r;if(d){const T=Math.min(this.currentTime,s)/a;let j=Math.floor(T),O=T%1;!O&&T>=1&&(O=1),O===1&&j--,j=Math.min(j,d+1),!!(j%2)&&(h==="reverse"?(O=1-O,f&&(O-=f/a)):h==="mirror"&&(S=o)),v=Ln(0,1,O)*a}const _=g?{done:!1,value:u[0]}:S.next(v);i&&(_.value=i(_.value));let{done:k}=_;!g&&l!==null&&(k=this.playbackSpeed>=0?this.currentTime>=s:this.currentTime<=0);const E=this.holdTime===null&&(this.state==="finished"||this.state==="running"&&k);return E&&w!==mh&&(_.value=wp(u,this.options,x,this.speed)),y&&y(_.value),E&&this.finish(),_}then(t,n){return this.finished.then(t,n)}get duration(){return Nt(this.calculatedDuration)}get iterationDuration(){const{delay:t=0}=this.options||{};return this.duration+Nt(t)}get time(){return Nt(this.currentTime)}set time(t){var n;t=yn(t),this.currentTime=t,this.startTime===null||this.holdTime!==null||this.playbackSpeed===0?this.holdTime=t:this.driver&&(this.startTime=this.driver.now()-t/this.playbackSpeed),(n=this.driver)==null||n.start(!1)}get speed(){return this.playbackSpeed}set speed(t){this.updateTime(ht.now());const n=this.playbackSpeed!==t;this.playbackSpeed=t,n&&(this.time=Nt(this.currentTime))}play(){var s,i;if(this.isStopped)return;const{driver:t=Oj,startTime:n}=this.options;this.driver||(this.driver=t(o=>this.tick(o))),(i=(s=this.options).onPlay)==null||i.call(s);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(ht.now()),this.holdTime=this.currentTime}complete(){this.state!=="running"&&this.play(),this.state="finished",this.holdTime=null}finish(){var t,n;this.notifyFinished(),this.teardown(),this.state="finished",(n=(t=this.options).onComplete)==null||n.call(t)}cancel(){var t,n;this.holdTime=null,this.startTime=0,this.tick(0),this.teardown(),(n=(t=this.options).onCancel)==null||n.call(t)}teardown(){this.state="idle",this.stopDriver(),this.startTime=this.holdTime=null}stopDriver(){this.driver&&(this.driver.stop(),this.driver=void 0)}sample(t){return this.startTime=0,this.tick(t,!0)}attachTimeline(t){var n;return this.options.allowFlatten&&(this.options.type="keyframes",this.options.ease="linear",this.initAnimation()),(n=this.driver)==null||n.stop(),t.observe(this)}}function Jj(e){for(let t=1;t<e.length;t++)e[t]??(e[t]=e[t-1])}const Xr=e=>e*180/Math.PI,gh=e=>{const t=Xr(Math.atan2(e[1],e[0]));return yh(t)},Xj={x:4,y:5,translateX:4,translateY:5,scaleX:0,scaleY:3,scale:e=>(Math.abs(e[0])+Math.abs(e[3]))/2,rotate:gh,rotateZ:gh,skewX:e=>Xr(Math.atan(e[1])),skewY:e=>Xr(Math.atan(e[2])),skew:e=>(Math.abs(e[1])+Math.abs(e[2]))/2},yh=e=>(e=e%360,e<0&&(e+=360),e),Jg=gh,Xg=e=>Math.sqrt(e[0]*e[0]+e[1]*e[1]),Zg=e=>Math.sqrt(e[4]*e[4]+e[5]*e[5]),Zj={x:12,y:13,z:14,translateX:12,translateY:13,translateZ:14,scaleX:Xg,scaleY:Zg,scale:e=>(Xg(e)+Zg(e))/2,rotateX:e=>yh(Xr(Math.atan2(e[6],e[5]))),rotateY:e=>yh(Xr(Math.atan2(-e[2],e[0]))),rotateZ:Jg,rotate:Jg,skewX:e=>Xr(Math.atan(e[4])),skewY:e=>Xr(Math.atan(e[1])),skew:e=>(Math.abs(e[1])+Math.abs(e[4]))/2};function vh(e){return e.includes("scale")?1:0}function wh(e,t){if(!e||e==="none")return vh(t);const n=e.match(/^matrix3d\(([-\d.e\s,]+)\)$/u);let r,s;if(n)r=Zj,s=n;else{const a=e.match(/^matrix\(([-\d.e\s,]+)\)$/u);r=Xj,s=a}if(!s)return vh(t);const i=r[t],o=s[1].split(",").map(tN);return typeof i=="function"?i(o):o[i]}const eN=(e,t)=>{const{transform:n="none"}=getComputedStyle(e);return wh(n,t)};function tN(e){return parseFloat(e.trim())}const Vi=["transformPerspective","x","y","z","translateX","translateY","translateZ","scale","scaleX","scaleY","rotate","rotateX","rotateY","rotateZ","skew","skewX","skewY"],Fi=new Set(Vi),ey=e=>e===$i||e===H,nN=new Set(["x","y","z"]),rN=Vi.filter(e=>!nN.has(e));function sN(e){const t=[];return rN.forEach(n=>{const r=e.getValue(n);r!==void 0&&(t.push([n,r.get()]),r.set(n.startsWith("scale")?1:0))}),t}const cs={width:({x:e},{paddingLeft:t="0",paddingRight:n="0"})=>e.max-e.min-parseFloat(t)-parseFloat(n),height:({y:e},{paddingTop:t="0",paddingBottom:n="0"})=>e.max-e.min-parseFloat(t)-parseFloat(n),top:(e,{top:t})=>parseFloat(t),left:(e,{left:t})=>parseFloat(t),bottom:({y:e},{top:t})=>parseFloat(t)+(e.max-e.min),right:({x:e},{left:t})=>parseFloat(t)+(e.max-e.min),x:(e,{transform:t})=>wh(t,"x"),y:(e,{transform:t})=>wh(t,"y")};cs.translateX=cs.x;cs.translateY=cs.y;const us=new Set;let xh=!1,bh=!1,Sh=!1;function p1(){if(bh){const e=Array.from(us).filter(r=>r.needsMeasurement),t=new Set(e.map(r=>r.element)),n=new Map;t.forEach(r=>{const s=sN(r);s.length&&(n.set(r,s),r.render())}),e.forEach(r=>r.measureInitialState()),t.forEach(r=>{r.render();const s=n.get(r);s&&s.forEach(([i,o])=>{var a;(a=r.getValue(i))==null||a.set(o)})}),e.forEach(r=>r.measureEndState()),e.forEach(r=>{r.suspendedScrollY!==void 0&&window.scrollTo(0,r.suspendedScrollY)})}bh=!1,xh=!1,us.forEach(e=>e.complete(Sh)),us.clear()}function m1(){us.forEach(e=>{e.readKeyframes(),e.needsMeasurement&&(bh=!0)})}function iN(){Sh=!0,m1(),p1(),Sh=!1}class Sp{constructor(t,n,r,s,i,o=!1){this.state="pending",this.isAsync=!1,this.needsMeasurement=!1,this.unresolvedKeyframes=[...t],this.onComplete=n,this.name=r,this.motionValue=s,this.element=i,this.isAsync=o}scheduleResolve(){this.state="scheduled",this.isAsync?(us.add(this),xh||(xh=!0,ge.read(m1),ge.resolveKeyframes(p1))):(this.readKeyframes(),this.complete())}readKeyframes(){const{unresolvedKeyframes:t,name:n,element:r,motionValue:s}=this;if(t[0]===null){const i=s==null?void 0:s.get(),o=t[t.length-1];if(i!==void 0)t[0]=i;else if(r&&n){const a=r.readValue(n,o);a!=null&&(t[0]=a)}t[0]===void 0&&(t[0]=o),s&&i===void 0&&s.set(t[0])}Jj(t)}setFinalKeyframe(){}measureInitialState(){}renderEndStyles(){}measureEndState(){}complete(t=!1){this.state="complete",this.onComplete(this.unresolvedKeyframes,this.finalKeyframe,t),us.delete(this)}cancel(){this.state==="scheduled"&&(us.delete(this),this.state="pending")}resume(){this.state==="pending"&&this.scheduleResolve()}}const oN=e=>e.startsWith("--");function aN(e,t,n){oN(t)?e.style.setProperty(t,n):e.style[t]=n}const lN=up(()=>window.ScrollTimeline!==void 0),cN={};function uN(e,t){const n=up(e);return()=>cN[t]??n()}const g1=uN(()=>{try{document.createElement("div").animate({opacity:0},{easing:"linear(0, 1)"})}catch{return!1}return!0},"linearEasing"),lo=([e,t,n,r])=>`cubic-bezier(${e}, ${t}, ${n}, ${r})`,ty={linear:"linear",ease:"ease",easeIn:"ease-in",easeOut:"ease-out",easeInOut:"ease-in-out",circIn:lo([0,.65,.55,1]),circOut:lo([.55,0,1,.45]),backIn:lo([.31,.01,.66,-.59]),backOut:lo([.33,1.53,.69,.99])};function y1(e,t){if(e)return typeof e=="function"?g1()?d1(e,t):"ease-out":e1(e)?lo(e):Array.isArray(e)?e.map(n=>y1(n,t)||ty.easeOut):ty[e]}function dN(e,t,n,{delay:r=0,duration:s=300,repeat:i=0,repeatType:o="loop",ease:a="easeOut",times:l}={},c=void 0){const u={[t]:n};l&&(u.offset=l);const d=y1(a,s);Array.isArray(d)&&(u.easing=d);const h={delay:r,duration:s,easing:Array.isArray(d)?"linear":d,fill:"both",iterations:i+1,direction:o==="reverse"?"alternate":"normal"};return c&&(h.pseudoElement=c),e.animate(u,h)}function v1(e){return typeof e=="function"&&"applyToOptions"in e}function hN({type:e,...t}){return v1(e)&&g1()?e.applyToOptions(t):(t.duration??(t.duration=300),t.ease??(t.ease="easeOut"),t)}class fN extends xp{constructor(t){if(super(),this.finishedTime=null,this.isStopped=!1,!t)return;const{element:n,name:r,keyframes:s,pseudoElement:i,allowFlatten:o=!1,finalKeyframe:a,onComplete:l}=t;this.isPseudoElement=!!i,this.allowFlatten=o,this.options=t,sc(typeof t.type!="string");const c=hN(t);this.animation=dN(n,r,s,c,i),c.autoplay===!1&&this.animation.pause(),this.animation.onfinish=()=>{if(this.finishedTime=this.time,!i){const u=wp(s,this.options,a,this.speed);this.updateMotionValue?this.updateMotionValue(u):aN(n,r,u),this.animation.cancel()}l==null||l(),this.notifyFinished()}}play(){this.isStopped||(this.animation.play(),this.state==="finished"&&this.updateFinished())}pause(){this.animation.pause()}complete(){var t,n;(n=(t=this.animation).finish)==null||n.call(t)}cancel(){try{this.animation.cancel()}catch{}}stop(){if(this.isStopped)return;this.isStopped=!0;const{state:t}=this;t==="idle"||t==="finished"||(this.updateMotionValue?this.updateMotionValue():this.commitStyles(),this.isPseudoElement||this.cancel())}commitStyles(){var t,n;this.isPseudoElement||(n=(t=this.animation).commitStyles)==null||n.call(t)}get duration(){var n,r;const t=((r=(n=this.animation.effect)==null?void 0:n.getComputedTiming)==null?void 0:r.call(n).duration)||0;return Nt(Number(t))}get iterationDuration(){const{delay:t=0}=this.options||{};return this.duration+Nt(t)}get time(){return Nt(Number(this.animation.currentTime)||0)}set time(t){this.finishedTime=null,this.animation.currentTime=yn(t)}get speed(){return this.animation.playbackRate}set speed(t){t<0&&(this.finishedTime=null),this.animation.playbackRate=t}get state(){return this.finishedTime!==null?"finished":this.animation.playState}get startTime(){return Number(this.animation.startTime)}set startTime(t){this.animation.startTime=t}attachTimeline({timeline:t,observe:n}){var r;return this.allowFlatten&&((r=this.animation.effect)==null||r.updateTiming({easing:"linear"})),this.animation.onfinish=null,t&&lN()?(this.animation.timeline=t,It):n(this)}}const w1={anticipate:Qb,backInOut:Yb,circInOut:Xb};function pN(e){return e in w1}function mN(e){typeof e.ease=="string"&&pN(e.ease)&&(e.ease=w1[e.ease])}const ny=10;class gN extends fN{constructor(t){mN(t),f1(t),super(t),t.startTime&&(this.startTime=t.startTime),this.options=t}updateMotionValue(t){const{motionValue:n,onUpdate:r,onComplete:s,element:i,...o}=this.options;if(!n)return;if(t!==void 0){n.set(t);return}const a=new bp({...o,autoplay:!1}),l=yn(this.finishedTime??this.time);n.setWithVelocity(a.sample(l-ny).value,a.sample(l).value,ny),a.stop()}}const ry=(e,t)=>t==="zIndex"?!1:!!(typeof e=="number"||Array.isArray(e)||typeof e=="string"&&(Ar.test(e)||e==="0")&&!e.startsWith("url("));function yN(e){const t=e[0];if(e.length===1)return!0;for(let n=0;n<e.length;n++)if(e[n]!==t)return!0}function vN(e,t,n,r){const s=e[0];if(s===null)return!1;if(t==="display"||t==="visibility")return!0;const i=e[e.length-1],o=ry(s,t),a=ry(i,t);return!o||!a?!1:yN(e)||(n==="spring"||v1(n))&&r}function _h(e){e.duration=0,e.type="keyframes"}const wN=new Set(["opacity","clipPath","filter","transform"]),xN=up(()=>Object.hasOwnProperty.call(Element.prototype,"animate"));function bN(e){var u;const{motionValue:t,name:n,repeatDelay:r,repeatType:s,damping:i,type:o}=e;if(!(((u=t==null?void 0:t.owner)==null?void 0:u.current)instanceof HTMLElement))return!1;const{onUpdate:l,transformTemplate:c}=t.owner.getProps();return xN()&&n&&wN.has(n)&&(n!=="transform"||!c)&&!l&&!r&&s!=="mirror"&&i!==0&&o!=="inertia"}const SN=40;class _N extends xp{constructor({autoplay:t=!0,delay:n=0,type:r="keyframes",repeat:s=0,repeatDelay:i=0,repeatType:
213o="loop",keyframes:a,name:l,motionValue:c,element:u,...d}){var w;super(),this.stop=()=>{var y,x;this._animation&&(this._animation.stop(),(y=this.stopTimeline)==null||y.call(this)),(x=this.keyframeResolver)==null||x.cancel()},this.createdAt=ht.now();const h={autoplay:t,delay:n,type:r,repeat:s,repeatDelay:i,repeatType:o,name:l,motionValue:c,element:u,...d},f=(u==null?void 0:u.KeyframeResolver)||Sp;this.keyframeResolver=new f(a,(y,x,m)=>this.onKeyframesResolved(y,x,h,!m),l,c,u),(w=this.keyframeResolver)==null||w.scheduleResolve()}onKeyframesResolved(t,n,r,s){this.keyframeResolver=void 0;const{name:i,type:o,velocity:a,delay:l,isHandoff:c,onUpdate:u}=r;this.resolvedAt=ht.now(),vN(t,i,o,a)||((Mn.instantAnimations||!l)&&(u==null||u(wp(t,r,n))),t[0]=t[t.length-1],_h(r),r.repeat=0);const h={startTime:s?this.resolvedAt?this.resolvedAt-this.createdAt>SN?this.resolvedAt:this.createdAt:this.createdAt:void 0,finalKeyframe:n,...r,keyframes:t},f=!c&&bN(h)?new gN({...h,element:h.motionValue.owner.current}):new bp(h);f.finished.then(()=>this.notifyFinished()).catch(It),this.pendingTimeline&&(this.stopTimeline=f.attachTimeline(this.pendingTimeline),this.pendingTimeline=void 0),this._animation=f}get finished(){return this._animation?this.animation.finished:this._finished}then(t,n){return this.finished.finally(t).then(()=>{})}get animation(){var t;return this._animation||((t=this.keyframeResolver)==null||t.resume(),iN()),this._animation}get duration(){return this.animation.duration}get iterationDuration(){return this.animation.iterationDuration}get time(){return this.animation.time}set time(t){this.animation.time=t}get speed(){return this.animation.speed}get state(){return this.animation.state}set speed(t){this.animation.speed=t}get startTime(){return this.animation.startTime}attachTimeline(t){return this._animation?this.stopTimeline=this.animation.attachTimeline(t):this.pendingTimeline=t,()=>this.stop()}play(){this.animation.play()}pause(){this.animation.pause()}complete(){this.animation.complete()}cancel(){var t;this._animation&&this.animation.cancel(),(t=this.keyframeResolver)==null||t.cancel()}}const kN=/^var\(--(?:([\w-]+)|([\w-]+), ?([a-zA-Z\d ()%#.,-]+))\)/u;function EN(e){const t=kN.exec(e);if(!t)return[,];const[,n,r,s]=t;return[`--${n??r}`,s]}function x1(e,t,n=1){const[r,s]=EN(e);if(!r)return;const i=window.getComputedStyle(t).getPropertyValue(r);if(i){const o=i.trim();return Ub(o)?parseFloat(o):o}return pp(s)?x1(s,t,n+1):s}function _p(e,t){return(e==null?void 0:e[t])??(e==null?void 0:e.default)??e}const b1=new Set(["width","height","top","left","right","bottom",...Vi]),TN={test:e=>e==="auto",parse:e=>e},S1=e=>t=>t.test(e),_1=[$i,H,vn,Xn,yj,gj,TN],sy=e=>_1.find(S1(e));function CN(e){return typeof e=="number"?e===0:e!==null?e==="none"||e==="0"||zb(e):!0}const PN=new Set(["brightness","contrast","saturate","opacity"]);function AN(e){const[t,n]=e.slice(0,-1).split("(");if(t==="drop-shadow")return e;const[r]=n.match(mp)||[];if(!r)return e;const s=n.replace(r,"");let i=PN.has(t)?1:0;return r!==n&&(i*=100),t+"("+i+s+")"}const RN=/\b([a-z-]*)\(.*?\)/gu,kh={...Ar,getAnimatableNone:e=>{const t=e.match(RN);return t?t.map(AN).join(" "):e}},iy={...$i,transform:Math.round},jN={rotate:Xn,rotateX:Xn,rotateY:Xn,rotateZ:Xn,scale:Xa,scaleX:Xa,scaleY:Xa,scaleZ:Xa,skew:Xn,skewX:Xn,skewY:Xn,distance:H,translateX:H,translateY:H,translateZ:H,x:H,y:H,z:H,perspective:H,transformPerspective:H,opacity:Jo,originX:Kg,originY:Kg,originZ:H},kp={borderWidth:H,borderTopWidth:H,borderRightWidth:H,borderBottomWidth:H,borderLeftWidth:H,borderRadius:H,radius:H,borderTopLeftRadius:H,borderTopRightRadius:H,borderBottomRightRadius:H,borderBottomLeftRadius:H,width:H,maxWidth:H,height:H,maxHeight:H,top:H,right:H,bottom:H,left:H,padding:H,paddingTop:H,paddingRight:H,paddingBottom:H,paddingLeft:H,margin:H,marginTop:H,marginRight:H,marginBottom:H,marginLeft:H,backgroundPositionX:H,backgroundPositionY:H,...jN,zIndex:iy,fillOpacity:Jo,strokeOpacity:Jo,numOctaves:iy},NN={...kp,color:je,backgroundColor:je,outlineColor:je,fill:je,stroke:je,borderColor:je,borderTopColor:je,borderRightColor:je,borderBottomColor:je,borderLeftColor:je,filter:kh,WebkitFilter:kh},k1=e=>NN[e];function E1(e,t){let n=k1(e);return n!==kh&&(n=Ar),n.getAnimatableNone?n.getAnimatableNone(t):void 0}
vendor: 9,470 bytes, line 213
213const ON=new Set(["auto","none","0"]);function IN(e,t,n){let r=0,s;for(;r<e.length&&!s;){const i=e[r];typeof i=="string"&&!ON.has(i)&&Xo(i).values.length&&(s=e[r]),r++}if(s&&n)for(const i of t)e[i]=E1(n,s)}class DN extends Sp{constructor(t,n,r,s,i){super(t,n,r,s,i,!0)}readKeyframes(){const{unresolvedKeyframes:t,element:n,name:r}=this;if(!n||!n.current)return;super.readKeyframes();for(let l=0;l<t.length;l++){let c=t[l];if(typeof c=="string"&&(c=c.trim(),pp(c))){const u=x1(c,n.current);u!==void 0&&(t[l]=u),l===t.length-1&&(this.finalKeyframe=c)}}if(this.resolveNoneKeyframes(),!b1.has(r)||t.length!==2)return;const[s,i]=t,o=sy(s),a=sy(i);if(o!==a)if(ey(o)&&ey(a))for(let l=0;l<t.length;l++){const c=t[l];typeof c=="string"&&(t[l]=parseFloat(c))}else cs[r]&&(this.needsMeasurement=!0)}resolveNoneKeyframes(){const{unresolvedKeyframes:t,name:n}=this,r=[];for(let s=0;s<t.length;s++)(t[s]===null||CN(t[s]))&&r.push(s);r.length&&IN(t,r,n)}measureInitialState(){const{element:t,unresolvedKeyframes:n,name:r}=this;if(!t||!t.current)return;r==="height"&&(this.suspendedScrollY=window.pageYOffset),this.measuredOrigin=cs[r](t.measureViewportBox(),window.getComputedStyle(t.current)),n[0]=this.measuredOrigin;const s=n[n.length-1];s!==void 0&&t.getValue(r,s).jump(s,!1)}measureEndState(){var a;const{element:t,name:n,unresolvedKeyframes:r}=this;if(!t||!t.current)return;const s=t.getValue(n);s&&s.jump(this.measuredOrigin,!1);const i=r.length-1,o=r[i];r[i]=cs[n](t.measureViewportBox(),window.getComputedStyle(t.current)),o!==null&&this.finalKeyframe===void 0&&(this.finalKeyframe=o),(a=this.removedTransforms)!=null&&a.length&&this.removedTransforms.forEach(([l,c])=>{t.getValue(l).set(c)}),this.resolveNoneKeyframes()}}function LN(e,t,n){if(e instanceof EventTarget)return[e];if(typeof e=="string"){const s=document.querySelectorAll(e);return s?Array.from(s):[]}return Array.from(e)}const T1=(e,t)=>t&&typeof e=="number"?t.transform(e):e;function MN(e){return Bb(e)&&"offsetHeight"in e}const oy=30,$N=e=>!isNaN(parseFloat(e));class VN{constructor(t,n={}){this.canTrackVelocity=null,this.events={},this.updateAndNotify=r=>{var i;const s=ht.now();if(this.updatedAt!==s&&this.setPrevFrameValue(),this.prev=this.current,this.setCurrent(r),this.current!==this.prev&&((i=this.events.change)==null||i.notify(this.current),this.dependents))for(const o of this.dependents)o.dirty()},this.hasAnimated=!1,this.setCurrent(t),this.owner=n.owner}setCurrent(t){this.current=t,this.updatedAt=ht.now(),this.canTrackVelocity===null&&t!==void 0&&(this.canTrackVelocity=$N(this.current))}setPrevFrameValue(t=this.current){this.prevFrameValue=t,this.prevUpdatedAt=this.updatedAt}onChange(t){return this.on("change",t)}on(t,n){this.events[t]||(this.events[t]=new dp);const r=this.events[t].add(n);return t==="change"?()=>{r(),ge.read(()=>{this.events.change.getSize()||this.stop()})}:r}clearListeners(){for(const t in this.events)this.events[t].clear()}attach(t,n){this.passiveEffect=t,this.stopPassiveEffect=n}set(t){this.passiveEffect?this.passiveEffect(t,this.updateAndNotify):this.updateAndNotify(t)}setWithVelocity(t,n,r){this.set(n),this.prev=void 0,this.prevFrameValue=t,this.prevUpdatedAt=this.updatedAt-r}jump(t,n=!0){this.updateAndNotify(t),this.prev=t,this.prevUpdatedAt=this.prevFrameValue=void 0,n&&this.stop(),this.stopPassiveEffect&&this.stopPassiveEffect()}dirty(){var t;(t=this.events.change)==null||t.notify(this.current)}addDependent(t){this.dependents||(this.dependents=new Set),this.dependents.add(t)}removeDependent(t){this.dependents&&this.dependents.delete(t)}get(){return this.current}getPrevious(){return this.prev}getVelocity(){const t=ht.now();if(!this.canTrackVelocity||this.prevFrameValue===void 0||t-this.updatedAt>oy)return 0;const n=Math.min(this.updatedAt-this.prevUpdatedAt,oy);return Wb(parseFloat(this.current)-parseFloat(this.prevFrameValue),n)}start(t){return this.stop(),new Promise(n=>{this.hasAnimated=!0,this.animation=t(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 t,n;(t=this.dependents)==null||t.clear(),(n=this.events.destroy)==null||n.notify(),this.clearListeners(),this.stop(),this.stopPassiveEffect&&this.stopPassiveEffect()}}function Ai(e,t){return new VN(e,t)}const{schedule:Ep,cancel:LM}=t1(queueMicrotask,!1),Ht={x:!1,y:!1};function C1(){return Ht.x||Ht.y}function FN(e){return e==="x"||e==="y"?Ht[e]?null:(Ht[e]=!0,()=>{Ht[e]=!1}):Ht.x||Ht.y?null:(Ht.x=Ht.y=!0,()=>{Ht.x=Ht.y=!1})}function P1(e,t){const n=LN(e),r=new AbortController,s={passive:!0,...t,signal:r.signal};return[n,s,()=>r.abort()]}function ay(e){return!(e.pointerType==="touch"||C1())}function UN(e,t,n={}){const[r,s,i]=P1(e,n),o=a=>{if(!ay(a))return;const{target:l}=a,c=t(l,a);if(typeof c!="function"||!l)return;const u=d=>{ay(d)&&(c(d),l.removeEventListener("pointerleave",u))};l.addEventListener("pointerleave",u,s)};return r.forEach(a=>{a.addEventListener("pointerenter",o,s)}),i}const A1=(e,t)=>t?e===t?!0:A1(e,t.parentElement):!1,Tp=e=>e.pointerType==="mouse"?typeof e.button!="number"||e.button<=0:e.isPrimary!==!1,BN=new Set(["BUTTON","INPUT","SELECT","TEXTAREA","A"]);function zN(e){return BN.has(e.tagName)||e.tabIndex!==-1}const _l=new WeakSet;function ly(e){return t=>{t.key==="Enter"&&e(t)}}function Fu(e,t){e.dispatchEvent(new PointerEvent("pointer"+t,{isPrimary:!0,bubbles:!0}))}const WN=(e,t)=>{const n=e.currentTarget;if(!n)return;const r=ly(()=>{if(_l.has(n))return;Fu(n,"down");const s=ly(()=>{Fu(n,"up")}),i=()=>Fu(n,"cancel");n.addEventListener("keyup",s,t),n.addEventListener("blur",i,t)});n.addEventListener("keydown",r,t),n.addEventListener("blur",()=>n.removeEventListener("keydown",r),t)};function cy(e){return Tp(e)&&!C1()}function HN(e,t,n={}){const[r,s,i]=P1(e,n),o=a=>{const l=a.currentTarget;if(!cy(a))return;_l.add(l);const c=t(l,a),u=(f,w)=>{window.removeEventListener("pointerup",d),window.removeEventListener("pointercancel",h),_l.has(l)&&_l.delete(l),cy(f)&&typeof c=="function"&&c(f,{success:w})},d=f=>{u(f,l===window||l===document||n.useGlobalTarget||A1(l,f.target))},h=f=>{u(f,!1)};window.addEventListener("pointerup",d,s),window.addEventListener("pointercancel",h,s)};return r.forEach(a=>{(n.useGlobalTarget?window:a).addEventListener("pointerdown",o,s),MN(a)&&(a.addEventListener("focus",c=>WN(c,s)),!zN(a)&&!a.hasAttribute("tabindex")&&(a.tabIndex=0))}),i}function R1(e){return Bb(e)&&"ownerSVGElement"in e}function KN(e){return R1(e)&&e.tagName==="svg"}const et=e=>!!(e&&e.getVelocity),qN=[..._1,je,Ar],GN=e=>qN.find(S1(e)),j1=b.createContext({transformPagePoint:e=>e,isStatic:!1,reducedMotion:"never"});function YN(e=!0){const t=b.useContext(ap);if(t===null)return[!0,null];const{isPresent:n,onExitComplete:r,register:s}=t,i=b.useId();b.useEffect(()=>{if(e)return s(i)},[e]);const o=b.useCallback(()=>e&&r&&r(i),[i,r,e]);return!n&&r?[!1,o]:[!0]}const N1=b.createContext({strict:!1}),uy={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"]},Ri={};for(const e in uy)Ri[e]={isEnabled:t=>uy[e].some(n=>!!t[n])};function QN(e){for(const t in e)Ri[t]={...Ri[t],...e[t]}}const JN=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","ignoreStrict","viewport"]);function lc(e){return e.startsWith("while")||e.startsWith("drag")&&e!=="draggable"||e.startsWith("layout")||e.startsWith("onTap")||e.startsWith("onPan")||e.startsWith("onLayout")||JN.has(e)}let O1=e=>!lc(e);function XN(e){typeof e=="function"&&(O1=t=>t.startsWith("on")?!lc(t):e(t))}try{XN(require("@emotion/is-prop-valid").default)}catch{}function ZN(e,t,n){const r={};for(const s in e)s==="values"&&typeof e.values=="object"||(O1(s)||n===!0&&lc(s)||!t&&!lc(s)||e.draggable&&s.startsWith("onDrag"))&&(r[s]=e[s]);return r}const Bc=b.createContext({});function zc(e){return e!==null&&typeof e=="object"&&typeof e.start=="function"}function Zo(e){return typeof e=="string"||Array.isArray(e)}const Cp=["animate","whileInView","whileFocus","whileHover","whileTap","whileDrag","exit"],Pp=["initial",...Cp];function Wc(e){return zc(e.animate)||Pp.some(t=>Zo(e[t]))}function I1(e){return!!(Wc(e)||e.variants)}function eO(e,t){if(Wc(e)){const{initial:n,animate:r}=e;return{initial:n===!1||Zo(n)?n:void 0,animate:Zo(r)?r:void 0}}return e.inherit!==!1?t:{}}function tO(e){const{initial:t,animate:n}=eO(e,b.useContext(Bc));return b.useMemo(()=>({initial:t,animate:n}),[dy(t),dy(n)])}function dy(e){return Array.isArray(e)?e.join(" "):e}function hy(e,t){return t.max===t.min?0:e/(t.max-t.min)*100}const to={correct:(e,t)=>
vendor: 6,106 bytes, line 213
213{if(!t.target)return e;if(typeof e=="string")if(H.test(e))e=parseFloat(e);else return e;const n=hy(e,t.target.x),r=hy(e,t.target.y);return`${n}% ${r}%`}},nO={correct:(e,{treeScale:t,projectionDelta:n})=>{const r=e,s=Ar.parse(e);if(s.length>5)return r;const i=Ar.createTransformer(e),o=typeof s[0]!="number"?1:0,a=n.x.scale*t.x,l=n.y.scale*t.y;s[0+o]/=a,s[1+o]/=l;const c=we(a,l,.5);return typeof s[2+o]=="number"&&(s[2+o]/=c),typeof s[3+o]=="number"&&(s[3+o]/=c),i(s)}},Eh={borderRadius:{...to,applyTo:["borderTopLeftRadius","borderTopRightRadius","borderBottomLeftRadius","borderBottomRightRadius"]},borderTopLeftRadius:to,borderTopRightRadius:to,borderBottomLeftRadius:to,borderBottomRightRadius:to,boxShadow:nO};function D1(e,{layout:t,layoutId:n}){return Fi.has(e)||e.startsWith("origin")||(t||n!==void 0)&&(!!Eh[e]||e==="opacity")}const rO={x:"translateX",y:"translateY",z:"translateZ",transformPerspective:"perspective"},sO=Vi.length;function iO(e,t,n){let r="",s=!0;for(let i=0;i<sO;i++){const o=Vi[i],a=e[o];if(a===void 0)continue;let l=!0;if(typeof a=="number"?l=a===(o.startsWith("scale")?1:0):l=parseFloat(a)===0,!l||n){const c=T1(a,kp[o]);if(!l){s=!1;const u=rO[o]||o;r+=`${u}(${c}) `}n&&(t[o]=c)}}return r=r.trim(),n?r=n(t,s?"":r):s&&(r="none"),r}function Ap(e,t,n){const{style:r,vars:s,transformOrigin:i}=e;let o=!1,a=!1;for(const l in t){const c=t[l];if(Fi.has(l)){o=!0;continue}else if(r1(l)){s[l]=c;continue}else{const u=T1(c,kp[l]);l.startsWith("origin")?(a=!0,i[l]=u):r[l]=u}}if(t.transform||(o||n?r.transform=iO(t,e.transform,n):r.transform&&(r.transform="none")),a){const{originX:l="50%",originY:c="50%",originZ:u=0}=i;r.transformOrigin=`${l} ${c} ${u}`}}const Rp=()=>({style:{},transform:{},transformOrigin:{},vars:{}});function L1(e,t,n){for(const r in t)!et(t[r])&&!D1(r,n)&&(e[r]=t[r])}function oO({transformTemplate:e},t){return b.useMemo(()=>{const n=Rp();return Ap(n,t,e),Object.assign({},n.vars,n.style)},[t])}function aO(e,t){const n=e.style||{},r={};return L1(r,n,e),Object.assign(r,oO(e,t)),r}function lO(e,t){const n={},r=aO(e,t);return e.drag&&e.dragListener!==!1&&(n.draggable=!1,r.userSelect=r.WebkitUserSelect=r.WebkitTouchCallout="none",r.touchAction=e.drag===!0?"none":`pan-${e.drag==="x"?"y":"x"}`),e.tabIndex===void 0&&(e.onTap||e.onTapStart||e.whileTap)&&(n.tabIndex=0),n.style=r,n}const cO={offset:"stroke-dashoffset",array:"stroke-dasharray"},uO={offset:"strokeDashoffset",array:"strokeDasharray"};function dO(e,t,n=1,r=0,s=!0){e.pathLength=1;const i=s?cO:uO;e[i.offset]=H.transform(-r);const o=H.transform(t),a=H.transform(n);e[i.array]=`${o} ${a}`}function M1(e,{attrX:t,attrY:n,attrScale:r,pathLength:s,pathSpacing:i=1,pathOffset:o=0,...a},l,c,u){if(Ap(e,a,c),l){e.style.viewBox&&(e.attrs.viewBox=e.style.viewBox);return}e.attrs=e.style,e.style={};const{attrs:d,style:h}=e;d.transform&&(h.transform=d.transform,delete d.transform),(h.transform||d.transformOrigin)&&(h.transformOrigin=d.transformOrigin??"50% 50%",delete d.transformOrigin),h.transform&&(h.transformBox=(u==null?void 0:u.transformBox)??"fill-box",delete d.transformBox),t!==void 0&&(d.x=t),n!==void 0&&(d.y=n),r!==void 0&&(d.scale=r),s!==void 0&&dO(d,s,i,o,!1)}const $1=()=>({...Rp(),attrs:{}}),V1=e=>typeof e=="string"&&e.toLowerCase()==="svg";function hO(e,t,n,r){const s=b.useMemo(()=>{const i=$1();return M1(i,t,V1(r),e.transformTemplate,e.style),{...i.attrs,style:{...i.style}}},[t]);if(e.style){const i={};L1(i,e.style,e),s.style={...i,...s.style}}return s}const fO=["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 jp(e){return typeof e!="string"||e.includes("-")?!1:!!(fO.indexOf(e)>-1||/[A-Z]/u.test(e))}function pO(e,t,n,{latestValues:r},s,i=!1){const a=(jp(e)?hO:lO)(t,r,s,e),l=ZN(t,typeof e=="string",i),c=e!==b.Fragment?{...l,...a,ref:n}:{},{children:u}=t,d=b.useMemo(()=>et(u)?u.get():u,[u]);return b.createElement(e,{...c,children:d})}function fy(e){const t=[{},{}];return e==null||e.values.forEach((n,r)=>{t[0][r]=n.get(),t[1][r]=n.getVelocity()}),t}function Np(e,t,n,r){if(typeof t=="function"){const[s,i]=fy(r);t=t(n!==void 0?n:e.custom,s,i)}if(typeof t=="string"&&(t=e.variants&&e.variants[t]),typeof t=="function"){const[s,i]=fy(r);t=t(n!==void 0?n:e.custom,s,i)}return t}function kl(e){return et(e)?e.get():e}function mO({scrapeMotionValuesFromProps:e,createRenderState:t},n,r,s){return{latestValues:gO(n,r,s,e),renderState:t()}}function gO(e,t,n,r){const s={},i=r(e,{});for(const h in i)s[h]=kl(i[h]);let{initial:o,animate:a}=e;const l=Wc(e),c=I1(e);t&&c&&!l&&e.inherit!==!1&&(o===void 0&&(o=t.initial),a===void 0&&(a=t.animate));let u=n?n.initial===!1:!1;u=u||o===!1;const d=u?a:o;if(d&&typeof d!="boolean"&&!zc(d)){const h=Array.isArray(d)?d:[d];for(let f=0;f<h.length;f++){const w=Np(e,h[f]);if(w){const{transitionEnd:y,transition:x,...m}=w;for(const g in m){let v=m[g];if(Array.isArray(v)){const S=u?v.length-1:0;v=v[S]}v!==null&&(s[g]=v)}for(const g in y)s[g]=y[g]}}}return s}const F1=e=>(t,n)=>{const r=b.useContext(Bc),s=b.useContext(ap),i=()=>mO(e,t,r,s);return n?i():JR(i)};function Op(e,t,n){var i;const{style:r}=e,s={};for(const o in r)(et(r[o])||t.style&&et(t.style[o])||D1(o,e)||((i=n==null?void 0:n.getValue(o))==null?void 0:i.liveStyle)!==void 0)&&(s[o]=r[o]);return s}const yO=F1({scrapeMotionValuesFromProps:Op,createRenderState:Rp});function U1(e,t,n){const r=Op(e,t,n);for(const s in e)if(et(e[s])||et(t[s])){const i=Vi.indexOf(s)!==-1?"attr"+s.charAt(0).toUpperCase()+s.substring(1):s;r[i]=e[s]}return r}const vO=F1({scrapeMotionValuesFromProps:U1,createRenderState:$1}),wO=Symbol.for("motionComponentSymbol");function Js(e){return e&&typeof e=="object"&&Object.prototype.hasOwnProperty.call(e,"current")}function xO(e,t,n){return b.useCallback(r=>{r&&e.onMount&&e.onMount(r),t&&(r?t.mount(r):t.unmount()),n&&(typeof n=="function"?n(r):Js(n)&&(n.current=r))},[t])}const Ip=e=>e.replace(/([a-z])([A-Z])/gu,"$1-$2").toLowerCase(),bO="framerAppearId",B1="data-"+Ip(bO),z1=b.createContext({});
vendor: 17,932 bytes, line 213
213function SO(e,t,n,r,s){var y,x;const{visualElement:i}=b.useContext(Bc),o=b.useContext(N1),a=b.useContext(ap),l=b.useContext(j1).reducedMotion,c=b.useRef(null);r=r||o.renderer,!c.current&&r&&(c.current=r(e,{visualState:t,parent:i,props:n,presenceContext:a,blockInitialAnimation:a?a.initial===!1:!1,reducedMotionConfig:l}));const u=c.current,d=b.useContext(z1);u&&!u.projection&&s&&(u.type==="html"||u.type==="svg")&&_O(c.current,n,s,d);const h=b.useRef(!1);b.useInsertionEffect(()=>{u&&h.current&&u.update(n,a)});const f=n[B1],w=b.useRef(!!f&&!((y=window.MotionHandoffIsComplete)!=null&&y.call(window,f))&&((x=window.MotionHasOptimisedAnimation)==null?void 0:x.call(window,f)));return XR(()=>{u&&(h.current=!0,window.MotionIsMounted=!0,u.updateFeatures(),u.scheduleRenderMicrotask(),w.current&&u.animationState&&u.animationState.animateChanges())}),b.useEffect(()=>{u&&(!w.current&&u.animationState&&u.animationState.animateChanges(),w.current&&(queueMicrotask(()=>{var m;(m=window.MotionHandoffMarkAsComplete)==null||m.call(window,f)}),w.current=!1),u.enteringChildren=void 0)}),u}function _O(e,t,n,r){const{layoutId:s,layout:i,drag:o,dragConstraints:a,layoutScroll:l,layoutRoot:c,layoutCrossfade:u}=t;e.projection=new n(e.latestValues,t["data-framer-portal-id"]?void 0:W1(e.parent)),e.projection.setOptions({layoutId:s,layout:i,alwaysMeasureLayout:!!o||a&&Js(a),visualElement:e,animationType:typeof i=="string"?i:"both",initialPromotionConfig:r,crossfade:u,layoutScroll:l,layoutRoot:c})}function W1(e){if(e)return e.options.allowProjection!==!1?e.projection:W1(e.parent)}function Uu(e,{forwardMotionProps:t=!1}={},n,r){n&&QN(n);const s=jp(e)?vO:yO;function i(a,l){let c;const u={...b.useContext(j1),...a,layoutId:kO(a)},{isStatic:d}=u,h=tO(a),f=s(a,d);if(!d&&op){EO();const w=TO(u);c=w.MeasureLayout,h.visualElement=SO(e,f,u,r,w.ProjectionNode)}return p.jsxs(Bc.Provider,{value:h,children:[c&&h.visualElement?p.jsx(c,{visualElement:h.visualElement,...u}):null,pO(e,a,xO(f,h.visualElement,l),f,d,t)]})}i.displayName=`motion.${typeof e=="string"?e:`create(${e.displayName??e.name??""})`}`;const o=b.forwardRef(i);return o[wO]=e,o}function kO({layoutId:e}){const t=b.useContext(Fb).id;return t&&e!==void 0?t+"-"+e:e}function EO(e,t){b.useContext(N1).strict}function TO(e){const{drag:t,layout:n}=Ri;if(!t&&!n)return{};const r={...t,...n};return{MeasureLayout:t!=null&&t.isEnabled(e)||n!=null&&n.isEnabled(e)?r.MeasureLayout:void 0,ProjectionNode:r.ProjectionNode}}function CO(e,t){if(typeof Proxy>"u")return Uu;const n=new Map,r=(i,o)=>Uu(i,o,e,t),s=(i,o)=>r(i,o);return new Proxy(s,{get:(i,o)=>o==="create"?r:(n.has(o)||n.set(o,Uu(o,void 0,e,t)),n.get(o))})}function H1({top:e,left:t,right:n,bottom:r}){return{x:{min:t,max:n},y:{min:e,max:r}}}function PO({x:e,y:t}){return{top:t.min,right:e.max,bottom:t.max,left:e.min}}function AO(e,t){if(!t)return e;const n=t({x:e.left,y:e.top}),r=t({x:e.right,y:e.bottom});return{top:n.y,left:n.x,bottom:r.y,right:r.x}}function Bu(e){return e===void 0||e===1}function Th({scale:e,scaleX:t,scaleY:n}){return!Bu(e)||!Bu(t)||!Bu(n)}function Wr(e){return Th(e)||K1(e)||e.z||e.rotate||e.rotateX||e.rotateY||e.skewX||e.skewY}function K1(e){return py(e.x)||py(e.y)}function py(e){return e&&e!=="0%"}function cc(e,t,n){const r=e-n,s=t*r;return n+s}function my(e,t,n,r,s){return s!==void 0&&(e=cc(e,s,r)),cc(e,n,r)+t}function Ch(e,t=0,n=1,r,s){e.min=my(e.min,t,n,r,s),e.max=my(e.max,t,n,r,s)}function q1(e,{x:t,y:n}){Ch(e.x,t.translate,t.scale,t.originPoint),Ch(e.y,n.translate,n.scale,n.originPoint)}const gy=.999999999999,yy=1.0000000000001;function RO(e,t,n,r=!1){const s=n.length;if(!s)return;t.x=t.y=1;let i,o;for(let a=0;a<s;a++){i=n[a],o=i.projectionDelta;const{visualElement:l}=i.options;l&&l.props.style&&l.props.style.display==="contents"||(r&&i.options.layoutScroll&&i.scroll&&i!==i.root&&Zs(e,{x:-i.scroll.offset.x,y:-i.scroll.offset.y}),o&&(t.x*=o.x.scale,t.y*=o.y.scale,q1(e,o)),r&&Wr(i.latestValues)&&Zs(e,i.latestValues))}t.x<yy&&t.x>gy&&(t.x=1),t.y<yy&&t.y>gy&&(t.y=1)}function Xs(e,t){e.min=e.min+t,e.max=e.max+t}function vy(e,t,n,r,s=.5){const i=we(e.min,e.max,s);Ch(e,t,n,i,r)}function Zs(e,t){vy(e.x,t.x,t.scaleX,t.scale,t.originX),vy(e.y,t.y,t.scaleY,t.scale,t.originY)}function G1(e,t){return H1(AO(e.getBoundingClientRect(),t))}function jO(e,t,n){const r=G1(e,n),{scroll:s}=t;return s&&(Xs(r.x,s.offset.x),Xs(r.y,s.offset.y)),r}const wy=()=>({translate:0,scale:1,origin:0,originPoint:0}),ei=()=>({x:wy(),y:wy()}),xy=()=>({min:0,max:0}),De=()=>({x:xy(),y:xy()}),Ph={current:null},Y1={current:!1};function NO(){if(Y1.current=!0,!!op)if(window.matchMedia){const e=window.matchMedia("(prefers-reduced-motion)"),t=()=>Ph.current=e.matches;e.addEventListener("change",t),t()}else Ph.current=!1}const OO=new WeakMap;function IO(e,t,n){for(const r in t){const s=t[r],i=n[r];if(et(s))e.addValue(r,s);else if(et(i))e.addValue(r,Ai(s,{owner:e}));else if(i!==s)if(e.hasValue(r)){const o=e.getValue(r);o.liveStyle===!0?o.jump(s):o.hasAnimated||o.set(s)}else{const o=e.getStaticValue(r);e.addValue(r,Ai(o!==void 0?o:s,{owner:e}))}}for(const r in n)t[r]===void 0&&e.removeValue(r);return t}const by=["AnimationStart","AnimationComplete","Update","BeforeLayoutMeasure","LayoutMeasure","LayoutAnimationStart","LayoutAnimationComplete"];class DO{scrapeMotionValuesFromProps(t,n,r){return{}}constructor({parent:t,props:n,presenceContext:r,reducedMotionConfig:s,blockInitialAnimation:i,visualState:o},a={}){this.current=null,this.children=new Set,this.isVariantNode=!1,this.isControllingVariants=!1,this.shouldReduceMotion=null,this.values=new Map,this.KeyframeResolver=Sp,this.features={},this.valueSubscriptions=new Map,this.prevMotionValues={},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 h=ht.now();this.renderScheduledAt<h&&(this.renderScheduledAt=h,ge.render(this.render,!1,!0))};const{latestValues:l,renderState:c}=o;this.latestValues=l,this.baseTarget={...l},this.initialValues=n.initial?{...l}:{},this.renderState=c,this.parent=t,this.props=n,this.presenceContext=r,this.depth=t?t.depth+1:0,this.reducedMotionConfig=s,this.options=a,this.blockInitialAnimation=!!i,this.isControllingVariants=Wc(n),this.isVariantNode=I1(n),this.isVariantNode&&(this.variantChildren=new Set),this.manuallyAnimateOnMount=!!(t&&t.current);const{willChange:u,...d}=this.scrapeMotionValuesFromProps(n,{},this);for(const h in d){const f=d[h];l[h]!==void 0&&et(f)&&f.set(l[h])}}mount(t){var n;this.current=t,OO.set(t,this),this.projection&&!this.projection.instance&&this.projection.mount(t),this.parent&&this.isVariantNode&&!this.isControllingVariants&&(this.removeFromVariantTree=this.parent.addVariantChild(this)),this.values.forEach((r,s)=>this.bindToMotionValue(s,r)),Y1.current||NO(),this.shouldReduceMotion=this.reducedMotionConfig==="never"?!1:this.reducedMotionConfig==="always"?!0:Ph.current,(n=this.parent)==null||n.addChild(this),this.update(this.props,this.presenceContext)}unmount(){var t;this.projection&&this.projection.unmount(),Pr(this.notifyUpdate),Pr(this.render),this.valueSubscriptions.forEach(n=>n()),this.valueSubscriptions.clear(),this.removeFromVariantTree&&this.removeFromVariantTree(),(t=this.parent)==null||t.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(t){this.children.add(t),this.enteringChildren??(this.enteringChildren=new Set),this.enteringChildren.add(t)}removeChild(t){this.children.delete(t),this.enteringChildren&&this.enteringChildren.delete(t)}bindToMotionValue(t,n){this.valueSubscriptions.has(t)&&this.valueSubscriptions.get(t)();const r=Fi.has(t);r&&this.onBindTransform&&this.onBindTransform();const s=n.on("change",o=>{this.latestValues[t]=o,this.props.onUpdate&&ge.preRender(this.notifyUpdate),r&&this.projection&&(this.projection.isTransformDirty=!0),this.scheduleRender()});let i;window.MotionCheckAppearSync&&(i=window.MotionCheckAppearSync(this,t,n)),this.valueSubscriptions.set(t,()=>{s(),i&&i(),n.owner&&n.stop()})}sortNodePosition(t){return!this.current||!this.sortInstanceNodePosition||this.type!==t.type?0:this.sortInstanceNodePosition(this.current,t.current)}updateFeatures(){let t="animation";for(t in Ri){const n=Ri[t];if(!n)continue;const{isEnabled:r,Feature:s}=n;if(!this.features[t]&&s&&r(this.props)&&(this.features[t]=new s(this)),this.features[t]){const i=this.features[t];i.isMounted?i.update():(i.mount(),i.isMounted=!0)}}}triggerBuild(){this.build(this.renderState,this.latestValues,this.props)}measureViewportBox(){return this.current?this.measureInstanceViewportBox(this.current,this.props):De()}getStaticValue(t){return this.latestValues[t]}setStaticValue(t,n){this.latestValues[t]=n}update(t,n){(t.transformTemplate||this.props.transformTemplate)&&this.scheduleRender(),this.prevProps=this.props,this.props=t,this.prevPresenceContext=this.presenceContext,this.presenceContext=n;for(let r=0;r<by.length;r++){const s=by[r];this.propEventSubscriptions[s]&&(this.propEventSubscriptions[s](),delete this.propEventSubscriptions[s]);const i="on"+s,o=t[i];o&&(this.propEventSubscriptions[s]=this.on(s,o))}this.prevMotionValues=IO(this,this.scrapeMotionValuesFromProps(t,this.prevProps,this),this.prevMotionValues),this.handleChildMotionValue&&this.handleChildMotionValue()}getProps(){return this.props}getVariant(t){return this.props.variants?this.props.variants[t]: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(t){const n=this.getClosestVariantNode();if(n)return n.variantChildren&&n.variantChildren.add(t),()=>n.variantChildren.delete(t)}addValue(t,n){const r=this.values.get(t);n!==r&&(r&&this.removeValue(t),this.bindToMotionValue(t,n),this.values.set(t,n),this.latestValues[t]=n.get())}removeValue(t){this.values.delete(t);const n=this.valueSubscriptions.get(t);n&&(n(),this.valueSubscriptions.delete(t)),delete this.latestValues[t],this.removeValueFromRenderState(t,this.renderState)}hasValue(t){return this.values.has(t)}getValue(t,n){if(this.props.values&&this.props.values[t])return this.props.values[t];let r=this.values.get(t);return r===void 0&&n!==void 0&&(r=Ai(n===null?void 0:n,{owner:this}),this.addValue(t,r)),r}readValue(t,n){let r=this.latestValues[t]!==void 0||!this.current?this.latestValues[t]:this.getBaseTargetFromProps(this.props,t)??this.readValueFromInstance(this.current,t,this.options);return r!=null&&(typeof r=="string"&&(Ub(r)||zb(r))?r=parseFloat(r):!GN(r)&&Ar.test(n)&&(r=E1(t,n)),this.setBaseTarget(t,et(r)?r.get():r)),et(r)?r.get():r}setBaseTarget(t,n){this.baseTarget[t]=n}getBaseTarget(t){var i;const{initial:n}=this.props;let r;if(typeof n=="string"||typeof n=="object"){const o=Np(this.props,n,(i=this.presenceContext)==null?void 0:i.custom);o&&(r=o[t])}if(n&&r!==void 0)return r;const s=this.getBaseTargetFromProps(this.props,t);return s!==void 0&&!et(s)?s:this.initialValues[t]!==void 0&&r===void 0?void 0:this.baseTarget[t]}on(t,n){return this.events[t]||(this.events[t]=new dp),this.events[t].add(n)}notify(t,...n){this.events[t]&&this.events[t].notify(...n)}scheduleRenderMicrotask(){Ep.render(this.render)}}class Q1 extends DO{constructor(){super(...arguments),this.KeyframeResolver=DN}sortInstanceNodePosition(t,n){return t.compareDocumentPosition(n)&2?1:-1}getBaseTargetFromProps(t,n){return t.style?t.style[n]:void 0}removeValueFromRenderState(t,{vars:n,style:r}){delete n[t],delete r[t]}handleChildMotionValue(){this.childSubscription&&(this.childSubscription(),delete this.childSubscription);const{children:t}=this.props;et(t)&&(this.childSubscription=t.on("change",n=>{this.current&&(this.current.textContent=`${n}`)}))}}function J1(e,{style:t,vars:n},r,s){const i=e.style;let o;for(o in t)i[o]=t[o];s==null||s.applyProjectionStyles(i,r);for(o in n)i.setProperty(o,n[o])}function LO(e){return window.getComputedStyle(e)}class MO extends Q1{constructor(){super(...arguments),this.type="html",this.renderInstance=J1}readValueFromInstance(t,n){var r;if(Fi.has(n))return(r=this.projection)!=null&&r.isProjecting?vh(n):eN(t,n);{const s=LO(t),i=(r1(n)?s.getPropertyValue(n):s[n])||0;return typeof i=="string"?i.trim():i}}measureInstanceViewportBox(t,{transformPagePoint:n}){return G1(t,n)}build(t,n,r){Ap(t,n,r.transformTemplate)}scrapeMotionValuesFromProps(t,n,r){return Op(t,n,r)}}const X1=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"]);function $O(e,t,n,r){J1(e,t,void 0,r);for(const s in t.attrs)e.setAttribute(X1.has(s)?s:Ip(s),t.attrs[s])}class VO extends Q1{constructor(){super(...arguments),this.type="svg",this.isSVGTag=!1,this.measureInstanceViewportBox=De}getBaseTargetFromProps(t,n){return t[n]}readValueFromInstance(t,n){if(Fi.has(n)){const r=k1(n);return r&&r.default||0}return n=X1.has(n)?n:Ip(n),t.getAttribute(n)}scrapeMotionValuesFromProps(t,n,r){return U1(t,n,r)}build(t,n,r){M1(t,n,this.isSVGTag,r.transformTemplate,r.style)}renderInstance(t,n,r,s){$O(t,n,r,s)}mount(t){this.isSVGTag=V1(t.tagName),super.mount(t)}}const FO=(e,t)=>jp(e)?new VO(t):new MO(t,{allowProjection:e!==b.Fragment});function ui(e,t,n){const r=e.getProps();return Np(r,t,n!==void 0?n:r.custom,e)}const Ah=e=>Array.isArray(e);function UO(e,t,n){e.hasValue(t)?e.getValue(t).set(n):e.addValue(t,Ai(n))}function BO(e){return Ah(e)?e[e.length-1]||0:e}function zO(e,t){const n=ui(e,t);let{transitionEnd:r={},transition:s={},...i}=n||{};i={...i,...r};for(const o in i){const a=BO(i[o]);UO(e,o,a)}}function WO(e){return!!(et(e)&&e.add)}function Rh(e,t){const n=e.getValue("willChange");if(WO(n))return n.add(t);if(!n&&Mn.WillChange){const r=new Mn.WillChange("auto");e.addValue("willChange",r),r.add(t)}}function Z1(e){return e.props[B1]}const HO=e=>e!==null;function KO(e,{repeat:t,repeatType:n="loop"},r){const s=e.filter(HO),i=t&&n!=="loop"&&t%2===1?0:s.length-1;return!i||r===void 0?s[i]:r}const qO={type:"spring",stiffness:500,damping:25,restSpeed:10},GO=e=>({type:"spring",stiffness:550,damping:e===0?2*Math.sqrt(550):30,restSpeed:10}),YO={type:"keyframes",duration:.8},QO={type:"keyframes",ease:[.25,.1,.35,1],duration:.3},JO=(e,{keyframes:t})=>t.length>2?YO:Fi.has(e)?e.startsWith("scale")?GO(t[1]):qO:QO;function XO({when:e,delay:t,delayChildren:n,staggerChildren:r,staggerDirection:s,repeat:i,repeatType:o,repeatDelay:a,from:l,elapsed:c,...u}){return!!Object.keys(u).length}const Dp=(e,t,n,r={},s,i)=>o=>{const a=_p(r,e)||{},l=a.delay||r.delay||0;let{elapsed:c=0}=r;c=c-yn(l);const u={keyframes:Array.isArray(n)?n:[null,n],ease:"easeOut",velocity:t.getVelocity(),...a,delay:-c,onUpdate:h=>{t.set(h),a.onUpdate&&a.onUpdate(h)},onComplete:()=>{o(),a.onComplete&&a.onComplete()},name:e,motionValue:t,element:i?void 0:s};XO(a)||Object.assign(u,JO(e,u)),u.duration&&(u.duration=yn(u.duration)),u.repeatDelay&&(u.repeatDelay=yn(u.repeatDelay)),u.from!==void 0&&(u.keyframes[0]=u.from);let d=!1;if((u.type===!1||u.duration===0&&!u.repeatDelay)&&(_h(u),u.delay===0&&(d=!0)),(Mn.instantAnimations||Mn.skipAnimations)&&(d=!0,_h(u),u.delay=0),u.allowFlatten=!a.type&&!a.ease,d&&!i&&t.get()!==void 0){const h=KO(u.keyframes,a);if(h!==void 0){ge.update(()=>{u.onUpdate(h),u.onComplete()});return}}return a.isSync?new bp(u):new _N(u)};function ZO({protectedKeys:e,needsAnimating:t},n){const r=e.hasOwnProperty(n)&&t[n]!==!0;return t[n]=!1,r}function eS(e,t,{delay:n=0,transitionOverride:r,type:s}={}){let{transition:i=e.getDefaultTransition(),transitionEnd:o,...a}=t;r&&(i=r);const l=[],c=s&&e.animationState&&e.animationState.getState()[s];for(const u in a){const d=e.getValue(u,e.latestValues[u]??null),h=a[u];if(h===void 0||c&&ZO(c,u))continue;const f={delay:n,..._p(i||{},u)},w=d.get();if(w!==void 0&&!d.isAnimating&&!Array.isArray(h)&&h===w&&!f.velocity)continue;let y=!1;if(window.MotionHandoffAnimation){const m=Z1(e);if(m){const g=window.MotionHandoffAnimation(m,u,ge);g!==null&&(f.startTime=g,y=!0)}}Rh(e,u),d.start(Dp(u,d,h,e.shouldReduceMotion&&b1.has(u)?{type:!1}:f,e,y));const x=d.animation;x&&l.push(x)}return o&&Promise.all(l).then(()=>{ge.update(()=>{o&&zO(e,o)})}),l}function tS(e,t,n,r=0,s=1){const i=Array.from(e).sort((c,u)=>c.sortNodePosition(u)).indexOf(t),o=e.size,a=(o-1)*r;return typeof n=="function"?n(i,o):s===1?i*r:a-i*r}function jh(e,t,n={}){var l;const r=ui(e,t,n.type==="exit"?(l=e.presenceContext)==null?void 0:l.custom:void 0);let{transition:s=e.getDefaultTransition()||{}}=r||{};n.transitionOverride&&(s=n.transitionOverride);const i=r?()=>Promise.all(eS(e,r,n)):()=>Promise.resolve(),o=e.variantChildren&&e.variantChildren.size?(c=0)=>{const{delayChildren:u=0,staggerChildren:d,staggerDirection:h}=s;return e2(e,t,c,u,d,h,n)}:()=>Promise.resolve(),{when:a}=s;if(a){const[c,u]=a==="beforeChildren"?[i,o]:[o,i];return c().then(()=>u())}else return Promise.all([i(),o(n.delay)])}function e2(e,t,n=0,r=0,s=0,i=1,o){const a=[];for(const l of e.variantChildren)l.notify("AnimationStart",t),a.push(jh(l,t,{...o,delay:n+(typeof r=="function"?0:r)+tS(e.variantChildren,l,r,s,i)}).then(()=>l.notify("AnimationComplete",t)));return Promise.all(a)}function t2(e,t,n={}){e.notify("AnimationStart",t);let r;if(Array.isArray(t)){const s=t.map(i=>jh(e,i,n));r=Promise.all(s)}else if(typeof t=="string")r=jh(e,t,n);else{const s=typeof t=="function"?ui(e,t,n.custom):t;r=Promise.all(eS(e,s,n))}return r.then(()=>
vendor: 15,635 bytes, line 213
213{e.notify("AnimationComplete",t)})}function nS(e,t){if(!Array.isArray(t))return!1;const n=t.length;if(n!==e.length)return!1;for(let r=0;r<n;r++)if(t[r]!==e[r])return!1;return!0}const n2=Pp.length;function rS(e){if(!e)return;if(!e.isControllingVariants){const n=e.parent?rS(e.parent)||{}:{};return e.props.initial!==void 0&&(n.initial=e.props.initial),n}const t={};for(let n=0;n<n2;n++){const r=Pp[n],s=e.props[r];(Zo(s)||s===!1)&&(t[r]=s)}return t}const r2=[...Cp].reverse(),s2=Cp.length;function i2(e){return t=>Promise.all(t.map(({animation:n,options:r})=>t2(e,n,r)))}function o2(e){let t=i2(e),n=Sy(),r=!0;const s=l=>(c,u)=>{var h;const d=ui(e,u,l==="exit"?(h=e.presenceContext)==null?void 0:h.custom:void 0);if(d){const{transition:f,transitionEnd:w,...y}=d;c={...c,...y,...w}}return c};function i(l){t=l(e)}function o(l){const{props:c}=e,u=rS(e.parent)||{},d=[],h=new Set;let f={},w=1/0;for(let x=0;x<s2;x++){const m=r2[x],g=n[m],v=c[m]!==void 0?c[m]:u[m],S=Zo(v),_=m===l?g.isActive:null;_===!1&&(w=x);let k=v===u[m]&&v!==c[m]&&S;if(k&&r&&e.manuallyAnimateOnMount&&(k=!1),g.protectedKeys={...f},!g.isActive&&_===null||!v&&!g.prevProp||zc(v)||typeof v=="boolean")continue;const E=a2(g.prevProp,v);let T=E||m===l&&g.isActive&&!k&&S||x>w&&S,j=!1;const O=Array.isArray(v)?v:[v];let U=O.reduce(s(m),{});_===!1&&(U={});const{prevResolvedValues:M={}}=g,J={...M,...U},D=V=>{T=!0,h.has(V)&&(j=!0,h.delete(V)),g.needsAnimating[V]=!0;const C=e.getValue(V);C&&(C.liveStyle=!1)};for(const V in J){const C=U[V],A=M[V];if(f.hasOwnProperty(V))continue;let L=!1;Ah(C)&&Ah(A)?L=!nS(C,A):L=C!==A,L?C!=null?D(V):h.add(V):C!==void 0&&h.has(V)?D(V):g.protectedKeys[V]=!0}g.prevProp=v,g.prevResolvedValues=U,g.isActive&&(f={...f,...U}),r&&e.blockInitialAnimation&&(T=!1);const X=k&&E;T&&(!X||j)&&d.push(...O.map(V=>{const C={type:m};if(typeof V=="string"&&r&&!X&&e.manuallyAnimateOnMount&&e.parent){const{parent:A}=e,L=ui(A,V);if(A.enteringChildren&&L){const{delayChildren:q}=L.transition||{};C.delay=tS(A.enteringChildren,e,q)}}return{animation:V,options:C}}))}if(h.size){const x={};if(typeof c.initial!="boolean"){const m=ui(e,Array.isArray(c.initial)?c.initial[0]:c.initial);m&&m.transition&&(x.transition=m.transition)}h.forEach(m=>{const g=e.getBaseTarget(m),v=e.getValue(m);v&&(v.liveStyle=!0),x[m]=g??null}),d.push({animation:x})}let y=!!d.length;return r&&(c.initial===!1||c.initial===c.animate)&&!e.manuallyAnimateOnMount&&(y=!1),r=!1,y?t(d):Promise.resolve()}function a(l,c){var d;if(n[l].isActive===c)return Promise.resolve();(d=e.variantChildren)==null||d.forEach(h=>{var f;return(f=h.animationState)==null?void 0:f.setActive(l,c)}),n[l].isActive=c;const u=o(l);for(const h in n)n[h].protectedKeys={};return u}return{animateChanges:o,setActive:a,setAnimateFunction:i,getState:()=>n,reset:()=>{n=Sy()}}}function a2(e,t){return typeof t=="string"?t!==e:Array.isArray(t)?!nS(t,e):!1}function Mr(e=!1){return{isActive:e,protectedKeys:{},needsAnimating:{},prevResolvedValues:{}}}function Sy(){return{animate:Mr(!0),whileInView:Mr(),whileHover:Mr(),whileTap:Mr(),whileDrag:Mr(),whileFocus:Mr(),exit:Mr()}}class Or{constructor(t){this.isMounted=!1,this.node=t}update(){}}class l2 extends Or{constructor(t){super(t),t.animationState||(t.animationState=o2(t))}updateAnimationControlsSubscription(){const{animate:t}=this.node.getProps();zc(t)&&(this.unmountControls=t.subscribe(this.node))}mount(){this.updateAnimationControlsSubscription()}update(){const{animate:t}=this.node.getProps(),{animate:n}=this.node.prevProps||{};t!==n&&this.updateAnimationControlsSubscription()}unmount(){var t;this.node.animationState.reset(),(t=this.unmountControls)==null||t.call(this)}}let c2=0;class u2 extends Or{constructor(){super(...arguments),this.id=c2++}update(){if(!this.node.presenceContext)return;const{isPresent:t,onExitComplete:n}=this.node.presenceContext,{isPresent:r}=this.node.prevPresenceContext||{};if(!this.node.animationState||t===r)return;const s=this.node.animationState.setActive("exit",!t);n&&!t&&s.then(()=>{n(this.id)})}mount(){const{register:t,onExitComplete:n}=this.node.presenceContext||{};n&&n(this.id),t&&(this.unmount=t(this.id))}unmount(){}}const d2={animation:{Feature:l2},exit:{Feature:u2}};function ea(e,t,n,r={passive:!0}){return e.addEventListener(t,n,r),()=>e.removeEventListener(t,n)}function _a(e){return{point:{x:e.pageX,y:e.pageY}}}const h2=e=>t=>Tp(t)&&e(t,_a(t));function _o(e,t,n,r){return ea(e,t,h2(n),r)}const sS=1e-4,f2=1-sS,p2=1+sS,iS=.01,m2=0-iS,g2=0+iS;function it(e){return e.max-e.min}function y2(e,t,n){return Math.abs(e-t)<=n}function _y(e,t,n,r=.5){e.origin=r,e.originPoint=we(t.min,t.max,e.origin),e.scale=it(n)/it(t),e.translate=we(n.min,n.max,e.origin)-e.originPoint,(e.scale>=f2&&e.scale<=p2||isNaN(e.scale))&&(e.scale=1),(e.translate>=m2&&e.translate<=g2||isNaN(e.translate))&&(e.translate=0)}function ko(e,t,n,r){_y(e.x,t.x,n.x,r?r.originX:void 0),_y(e.y,t.y,n.y,r?r.originY:void 0)}function ky(e,t,n){e.min=n.min+t.min,e.max=e.min+it(t)}function v2(e,t,n){ky(e.x,t.x,n.x),ky(e.y,t.y,n.y)}function Ey(e,t,n){e.min=t.min-n.min,e.max=e.min+it(t)}function uc(e,t,n){Ey(e.x,t.x,n.x),Ey(e.y,t.y,n.y)}function Ct(e){return[e("x"),e("y")]}const oS=({current:e})=>e?e.ownerDocument.defaultView:null,Ty=(e,t)=>Math.abs(e-t);function w2(e,t){const n=Ty(e.x,t.x),r=Ty(e.y,t.y);return Math.sqrt(n**2+r**2)}class aS{constructor(t,n,{transformPagePoint:r,contextWindow:s=window,dragSnapToOrigin:i=!1,distanceThreshold:o=3}={}){if(this.startEvent=null,this.lastMoveEvent=null,this.lastMoveEventInfo=null,this.handlers={},this.contextWindow=window,this.updatePoint=()=>{if(!(this.lastMoveEvent&&this.lastMoveEventInfo))return;const h=Wu(this.lastMoveEventInfo,this.history),f=this.startEvent!==null,w=w2(h.offset,{x:0,y:0})>=this.distanceThreshold;if(!f&&!w)return;const{point:y}=h,{timestamp:x}=We;this.history.push({...y,timestamp:x});const{onStart:m,onMove:g}=this.handlers;f||(m&&m(this.lastMoveEvent,h),this.startEvent=this.lastMoveEvent),g&&g(this.lastMoveEvent,h)},this.handlePointerMove=(h,f)=>{this.lastMoveEvent=h,this.lastMoveEventInfo=zu(f,this.transformPagePoint),ge.update(this.updatePoint,!0)},this.handlePointerUp=(h,f)=>{this.end();const{onEnd:w,onSessionEnd:y,resumeAnimation:x}=this.handlers;if(this.dragSnapToOrigin&&x&&x(),!(this.lastMoveEvent&&this.lastMoveEventInfo))return;const m=Wu(h.type==="pointercancel"?this.lastMoveEventInfo:zu(f,this.transformPagePoint),this.history);this.startEvent&&w&&w(h,m),y&&y(h,m)},!Tp(t))return;this.dragSnapToOrigin=i,this.handlers=n,this.transformPagePoint=r,this.distanceThreshold=o,this.contextWindow=s||window;const a=_a(t),l=zu(a,this.transformPagePoint),{point:c}=l,{timestamp:u}=We;this.history=[{...c,timestamp:u}];const{onSessionStart:d}=n;d&&d(t,Wu(l,this.history)),this.removeListeners=xa(_o(this.contextWindow,"pointermove",this.handlePointerMove),_o(this.contextWindow,"pointerup",this.handlePointerUp),_o(this.contextWindow,"pointercancel",this.handlePointerUp))}updateHandlers(t){this.handlers=t}end(){this.removeListeners&&this.removeListeners(),Pr(this.updatePoint)}}function zu(e,t){return t?{point:t(e.point)}:e}function Cy(e,t){return{x:e.x-t.x,y:e.y-t.y}}function Wu({point:e},t){return{point:e,delta:Cy(e,lS(t)),offset:Cy(e,x2(t)),velocity:b2(t,.1)}}function x2(e){return e[0]}function lS(e){return e[e.length-1]}function b2(e,t){if(e.length<2)return{x:0,y:0};let n=e.length-1,r=null;const s=lS(e);for(;n>=0&&(r=e[n],!(s.timestamp-r.timestamp>yn(t)));)n--;if(!r)return{x:0,y:0};const i=Nt(s.timestamp-r.timestamp);if(i===0)return{x:0,y:0};const o={x:(s.x-r.x)/i,y:(s.y-r.y)/i};return o.x===1/0&&(o.x=0),o.y===1/0&&(o.y=0),o}function S2(e,{min:t,max:n},r){return t!==void 0&&e<t?e=r?we(t,e,r.min):Math.max(e,t):n!==void 0&&e>n&&(e=r?we(n,e,r.max):Math.min(e,n)),e}function Py(e,t,n){return{min:t!==void 0?e.min+t:void 0,max:n!==void 0?e.max+n-(e.max-e.min):void 0}}function _2(e,{top:t,left:n,bottom:r,right:s}){return{x:Py(e.x,n,s),y:Py(e.y,t,r)}}function Ay(e,t){let n=t.min-e.min,r=t.max-e.max;return t.max-t.min<e.max-e.min&&([n,r]=[r,n]),{min:n,max:r}}function k2(e,t){return{x:Ay(e.x,t.x),y:Ay(e.y,t.y)}}function E2(e,t){let n=.5;const r=it(e),s=it(t);return s>r?n=Qo(t.min,t.max-r,e.min):r>s&&(n=Qo(e.min,e.max-s,t.min)),Ln(0,1,n)}function T2(e,t){const n={};return t.min!==void 0&&(n.min=t.min-e.min),t.max!==void 0&&(n.max=t.max-e.min),n}const Nh=.35;function C2(e=Nh){return e===!1?e=0:e===!0&&(e=Nh),{x:Ry(e,"left","right"),y:Ry(e,"top","bottom")}}function Ry(e,t,n){return{min:jy(e,t),max:jy(e,n)}}function jy(e,t){return typeof e=="number"?e:e[t]||0}const P2=new WeakMap;class A2{constructor(t){this.openDragLock=null,this.isDragging=!1,this.currentDirection=null,this.originPoint={x:0,y:0},this.constraints=!1,this.hasMutatedConstraints=!1,this.elastic=De(),this.latestPointerEvent=null,this.latestPanInfo=null,this.visualElement=t}start(t,{snapToCursor:n=!1,distanceThreshold:r}={}){const{presenceContext:s}=this.visualElement;if(s&&s.isPresent===!1)return;const i=d=>{const{dragSnapToOrigin:h}=this.getProps();h?this.pauseAnimation():this.stopAnimation(),n&&this.snapToCursor(_a(d).point)},o=(d,h)=>{const{drag:f,dragPropagation:w,onDragStart:y}=this.getProps();if(f&&!w&&(this.openDragLock&&this.openDragLock(),this.openDragLock=FN(f),!this.openDragLock))return;this.latestPointerEvent=d,this.latestPanInfo=h,this.isDragging=!0,this.currentDirection=null,this.resolveConstraints(),this.visualElement.projection&&(this.visualElement.projection.isAnimationBlocked=!0,this.visualElement.projection.target=void 0),Ct(m=>{let g=this.getAxisMotionValue(m).get()||0;if(vn.test(g)){const{projection:v}=this.visualElement;if(v&&v.layout){const S=v.layout.layoutBox[m];S&&(g=it(S)*(parseFloat(g)/100))}}this.originPoint[m]=g}),y&&ge.postRender(()=>y(d,h)),Rh(this.visualElement,"transform");const{animationState:x}=this.visualElement;x&&x.setActive("whileDrag",!0)},a=(d,h)=>{this.latestPointerEvent=d,this.latestPanInfo=h;const{dragPropagation:f,dragDirectionLock:w,onDirectionLock:y,onDrag:x}=this.getProps();if(!f&&!this.openDragLock)return;const{offset:m}=h;if(w&&this.currentDirection===null){this.currentDirection=R2(m),this.currentDirection!==null&&y&&y(this.currentDirection);return}this.updateAxis("x",h.point,m),this.updateAxis("y",h.point,m),this.visualElement.render(),x&&x(d,h)},l=(d,h)=>{this.latestPointerEvent=d,this.latestPanInfo=h,this.stop(d,h),this.latestPointerEvent=null,this.latestPanInfo=null},c=()=>Ct(d=>{var h;return this.getAnimationState(d)==="paused"&&((h=this.getAxisMotionValue(d).animation)==null?void 0:h.play())}),{dragSnapToOrigin:u}=this.getProps();this.panSession=new aS(t,{onSessionStart:i,onStart:o,onMove:a,onSessionEnd:l,resumeAnimation:c},{transformPagePoint:this.visualElement.getTransformPagePoint(),dragSnapToOrigin:u,distanceThreshold:r,contextWindow:oS(this.visualElement)})}stop(t,n){const r=t||this.latestPointerEvent,s=n||this.latestPanInfo,i=this.isDragging;if(this.cancel(),!i||!s||!r)return;const{velocity:o}=s;this.startAnimation(o);const{onDragEnd:a}=this.getProps();a&&ge.postRender(()=>a(r,s))}cancel(){this.isDragging=!1;const{projection:t,animationState:n}=this.visualElement;t&&(t.isAnimationBlocked=!1),this.panSession&&this.panSession.end(),this.panSession=void 0;const{dragPropagation:r}=this.getProps();!r&&this.openDragLock&&(this.openDragLock(),this.openDragLock=null),n&&n.setActive("whileDrag",!1)}updateAxis(t,n,r){const{drag:s}=this.getProps();if(!r||!Za(t,s,this.currentDirection))return;const i=this.getAxisMotionValue(t);let o=this.originPoint[t]+r[t];this.constraints&&this.constraints[t]&&(o=S2(o,this.constraints[t],this.elastic[t])),i.set(o)}resolveConstraints(){var i;const{dragConstraints:t,dragElastic:n}=this.getProps(),r=this.visualElement.projection&&!this.visualElement.projection.layout?this.visualElement.projection.measure(!1):(i=this.visualElement.projection)==null?void 0:i.layout,s=this.constraints;t&&Js(t)?this.constraints||(this.constraints=this.resolveRefConstraints()):t&&r?this.constraints=_2(r.layoutBox,t):this.constraints=!1,this.elastic=C2(n),s!==this.constraints&&r&&this.constraints&&!this.hasMutatedConstraints&&Ct(o=>{this.constraints!==!1&&this.getAxisMotionValue(o)&&(this.constraints[o]=T2(r.layoutBox[o],this.constraints[o]))})}resolveRefConstraints(){const{dragConstraints:t,onMeasureDragConstraints:n}=this.getProps();if(!t||!Js(t))return!1;const r=t.current,{projection:s}=this.visualElement;if(!s||!s.layout)return!1;const i=jO(r,s.root,this.visualElement.getTransformPagePoint());let o=k2(s.layout.layoutBox,i);if(n){const a=n(PO(o));this.hasMutatedConstraints=!!a,a&&(o=H1(a))}return o}startAnimation(t){const{drag:n,dragMomentum:r,dragElastic:s,dragTransition:i,dragSnapToOrigin:o,onDragTransitionEnd:a}=this.getProps(),l=this.constraints||{},c=Ct(u=>{if(!Za(u,n,this.currentDirection))return;let d=l&&l[u]||{};o&&(d={min:0,max:0});const h=s?200:1e6,f=s?40:1e7,w={type:"inertia",velocity:r?t[u]:0,bounceStiffness:h,bounceDamping:f,timeConstant:750,restDelta:1,restSpeed:10,...i,...d};return this.startAxisValueAnimation(u,w)});return Promise.all(c).then(a)}startAxisValueAnimation(t,n){const r=this.getAxisMotionValue(t);return Rh(this.visualElement,t),r.start(Dp(t,r,0,n,this.visualElement,!1))}stopAnimation(){Ct(t=>this.getAxisMotionValue(t).stop())}pauseAnimation(){Ct(t=>{var n;return(n=this.getAxisMotionValue(t).animation)==null?void 0:n.pause()})}getAnimationState(t){var n;return(n=this.getAxisMotionValue(t).animation)==null?void 0:n.state}getAxisMotionValue(t){const n=`_drag${t.toUpperCase()}`,r=this.visualElement.getProps(),s=r[n];return s||this.visualElement.getValue(t,(r.initial?r.initial[t]:void 0)||0)}snapToCursor(t){Ct(n=>{const{drag:r}=this.getProps();if(!Za(n,r,this.currentDirection))return;const{projection:s}=this.visualElement,i=this.getAxisMotionValue(n);if(s&&s.layout){const{min:o,max:a}=s.layout.layoutBox[n];i.set(t[n]-we(o,a,.5))}})}scalePositionWithinConstraints(){if(!this.visualElement.current)return;const{drag:t,dragConstraints:n}=this.getProps(),{projection:r}=this.visualElement;if(!Js(n)||!r||!this.constraints)return;this.stopAnimation();const s={x:0,y:0};Ct(o=>{const a=this.getAxisMotionValue(o);if(a&&this.constraints!==!1){const l=a.get();s[o]=E2({min:l,max:l},this.constraints[o])}});const{transformTemplate:i}=this.visualElement.getProps();this.visualElement.current.style.transform=i?i({},""):"none",r.root&&r.root.updateScroll(),r.updateLayout(),this.resolveConstraints(),Ct(o=>{if(!Za(o,t,null))return;const a=this.getAxisMotionValue(o),{min:l,max:c}=this.constraints[o];a.set(we(l,c,s[o]))})}addListeners(){if(!this.visualElement.current)return;P2.set(this.visualElement,this);const t=this.visualElement.current,n=_o(t,"pointerdown",l=>{const{drag:c,dragListener:u=!0}=this.getProps();c&&u&&this.start(l)}),r=()=>{const{dragConstraints:l}=this.getProps();Js(l)&&l.current&&(this.constraints=this.resolveRefConstraints())},{projection:s}=this.visualElement,i=s.addEventListener("measure",r);s&&!s.layout&&(s.root&&s.root.updateScroll(),s.updateLayout()),ge.read(r);const o=ea(window,"resize",()=>this.scalePositionWithinConstraints()),a=s.addEventListener("didUpdate",({delta:l,hasLayoutChanged:c})=>{this.isDragging&&c&&(Ct(u=>{const d=this.getAxisMotionValue(u);d&&(this.originPoint[u]+=l[u].translate,d.set(d.get()+l[u].translate))}),this.visualElement.render())});return()=>{o(),n(),i(),a&&a()}}getProps(){const t=this.visualElement.getProps(),{drag:n=!1,dragDirectionLock:r=!1,dragPropagation:s=!1,dragConstraints:i=!1,dragElastic:o=Nh,dragMomentum:a=!0}=t;return{...t,drag:n,dragDirectionLock:r,dragPropagation:s,dragConstraints:i,dragElastic:o,dragMomentum:a}}}
vendor: 4,081 bytes, line 213
213function Za(e,t,n){return(t===!0||t===e)&&(n===null||n===e)}function R2(e,t=10){let n=null;return Math.abs(e.y)>t?n="y":Math.abs(e.x)>t&&(n="x"),n}class j2 extends Or{constructor(t){super(t),this.removeGroupControls=It,this.removeListeners=It,this.controls=new A2(t)}mount(){const{dragControls:t}=this.node.getProps();t&&(this.removeGroupControls=t.subscribe(this.controls)),this.removeListeners=this.controls.addListeners()||It}unmount(){this.removeGroupControls(),this.removeListeners()}}const Ny=e=>(t,n)=>{e&&ge.postRender(()=>e(t,n))};class N2 extends Or{constructor(){super(...arguments),this.removePointerDownListener=It}onPointerDown(t){this.session=new aS(t,this.createPanHandlers(),{transformPagePoint:this.node.getTransformPagePoint(),contextWindow:oS(this.node)})}createPanHandlers(){const{onPanSessionStart:t,onPanStart:n,onPan:r,onPanEnd:s}=this.node.getProps();return{onSessionStart:Ny(t),onStart:Ny(n),onMove:r,onEnd:(i,o)=>{delete this.session,s&&ge.postRender(()=>s(i,o))}}}mount(){this.removePointerDownListener=_o(this.node.current,"pointerdown",t=>this.onPointerDown(t))}update(){this.session&&this.session.updateHandlers(this.createPanHandlers())}unmount(){this.removePointerDownListener(),this.session&&this.session.end()}}const El={hasAnimatedSinceResize:!0,hasEverUpdated:!1};let Hu=!1;class O2 extends b.Component{componentDidMount(){const{visualElement:t,layoutGroup:n,switchLayoutGroup:r,layoutId:s}=this.props,{projection:i}=t;i&&(n.group&&n.group.add(i),r&&r.register&&s&&r.register(i),Hu&&i.root.didUpdate(),i.addEventListener("animationComplete",()=>{this.safeToRemove()}),i.setOptions({...i.options,onExitComplete:()=>this.safeToRemove()})),El.hasEverUpdated=!0}getSnapshotBeforeUpdate(t){const{layoutDependency:n,visualElement:r,drag:s,isPresent:i}=this.props,{projection:o}=r;return o&&(o.isPresent=i,Hu=!0,s||t.layoutDependency!==n||n===void 0||t.isPresent!==i?o.willUpdate():this.safeToRemove(),t.isPresent!==i&&(i?o.promote():o.relegate()||ge.postRender(()=>{const a=o.getStack();(!a||!a.members.length)&&this.safeToRemove()}))),null}componentDidUpdate(){const{projection:t}=this.props.visualElement;t&&(t.root.didUpdate(),Ep.postRender(()=>{!t.currentAnimation&&t.isLead()&&this.safeToRemove()}))}componentWillUnmount(){const{visualElement:t,layoutGroup:n,switchLayoutGroup:r}=this.props,{projection:s}=t;Hu=!0,s&&(s.scheduleCheckAfterUnmount(),n&&n.group&&n.group.remove(s),r&&r.deregister&&r.deregister(s))}safeToRemove(){const{safeToRemove:t}=this.props;t&&t()}render(){return null}}function cS(e){const[t,n]=YN(),r=b.useContext(Fb);return p.jsx(O2,{...e,layoutGroup:r,switchLayoutGroup:b.useContext(z1),isPresent:t,safeToRemove:n})}function I2(e,t,n){const r=et(e)?e:Ai(e);return r.start(Dp("",r,t,n)),r.animation}const D2=(e,t)=>e.depth-t.depth;class L2{constructor(){this.children=[],this.isDirty=!1}add(t){lp(this.children,t),this.isDirty=!0}remove(t){cp(this.children,t),this.isDirty=!0}forEach(t){this.isDirty&&this.children.sort(D2),this.isDirty=!1,this.children.forEach(t)}}function M2(e,t){const n=ht.now(),r=({timestamp:s})=>{const i=s-n;i>=t&&(Pr(r),e(i-t))};return ge.setup(r,!0),()=>Pr(r)}const uS=["TopLeft","TopRight","BottomLeft","BottomRight"],$2=uS.length,Oy=e=>typeof e=="string"?parseFloat(e):e,Iy=e=>typeof e=="number"||H.test(e);function V2(e,t,n,r,s,i){s?(e.opacity=we(0,n.opacity??1,F2(r)),e.opacityExit=we(t.opacity??1,0,U2(r))):i&&(e.opacity=we(t.opacity??1,n.opacity??1,r));for(let o=0;o<$2;o++){const a=`border${uS[o]}Radius`;let l=Dy(t,a),c=Dy(n,a);if(l===void 0&&c===void 0)continue;l||(l=0),c||(c=0),l===0||c===0||Iy(l)===Iy(c)?(e[a]=Math.max(we(Oy(l),Oy(c),r),0),(vn.test(c)||vn.test(l))&&(e[a]+="%")):e[a]=c}(t.rotate||n.rotate)&&(e.rotate=we(t.rotate||0,n.rotate||0,r))}function Dy(e,t){return e[t]!==void 0?e[t]:e.borderRadius}const F2=dS(0,.5,Jb),U2=dS(.5,.95,It);function dS(e,t,n){return r=>r<e?0:r>t?1:n(Qo(e,t,r))}function Ly(e,t){e.min=t.min,e.max=t.max}function zt(e,t){Ly(e.x,t.x),Ly(e.y,t.y)}function My(e,t){e.translate=t.translate,e.scale=t.scale,e.originPoint=t.originPoint,e.origin=t.origin}
vendor: 4,059 bytes, line 213
213function $y(e,t,n,r,s){return e-=t,e=cc(e,1/n,r),s!==void 0&&(e=cc(e,1/s,r)),e}function B2(e,t=0,n=1,r=.5,s,i=e,o=e){if(vn.test(t)&&(t=parseFloat(t),t=we(o.min,o.max,t/100)-o.min),typeof t!="number")return;let a=we(i.min,i.max,r);e===i&&(a-=t),e.min=$y(e.min,t,n,a,s),e.max=$y(e.max,t,n,a,s)}function Vy(e,t,[n,r,s],i,o){B2(e,t[n],t[r],t[s],t.scale,i,o)}const z2=["x","scaleX","originX"],W2=["y","scaleY","originY"];function Fy(e,t,n,r){Vy(e.x,t,z2,n?n.x:void 0,r?r.x:void 0),Vy(e.y,t,W2,n?n.y:void 0,r?r.y:void 0)}function Uy(e){return e.translate===0&&e.scale===1}function hS(e){return Uy(e.x)&&Uy(e.y)}function By(e,t){return e.min===t.min&&e.max===t.max}function H2(e,t){return By(e.x,t.x)&&By(e.y,t.y)}function zy(e,t){return Math.round(e.min)===Math.round(t.min)&&Math.round(e.max)===Math.round(t.max)}function fS(e,t){return zy(e.x,t.x)&&zy(e.y,t.y)}function Wy(e){return it(e.x)/it(e.y)}function Hy(e,t){return e.translate===t.translate&&e.scale===t.scale&&e.originPoint===t.originPoint}class K2{constructor(){this.members=[]}add(t){lp(this.members,t),t.scheduleRender()}remove(t){if(cp(this.members,t),t===this.prevLead&&(this.prevLead=void 0),t===this.lead){const n=this.members[this.members.length-1];n&&this.promote(n)}}relegate(t){const n=this.members.findIndex(s=>t===s);if(n===0)return!1;let r;for(let s=n;s>=0;s--){const i=this.members[s];if(i.isPresent!==!1){r=i;break}}return r?(this.promote(r),!0):!1}promote(t,n){const r=this.lead;if(t!==r&&(this.prevLead=r,this.lead=t,t.show(),r)){r.instance&&r.scheduleRender(),t.scheduleRender(),t.resumeFrom=r,n&&(t.resumeFrom.preserveOpacity=!0),r.snapshot&&(t.snapshot=r.snapshot,t.snapshot.latestValues=r.animationValues||r.latestValues),t.root&&t.root.isUpdating&&(t.isLayoutDirty=!0);const{crossfade:s}=t.options;s===!1&&r.hide()}}exitAnimationComplete(){this.members.forEach(t=>{const{options:n,resumingFrom:r}=t;n.onExitComplete&&n.onExitComplete(),r&&r.options.onExitComplete&&r.options.onExitComplete()})}scheduleRender(){this.members.forEach(t=>{t.instance&&t.scheduleRender(!1)})}removeLeadSnapshot(){this.lead&&this.lead.snapshot&&(this.lead.snapshot=void 0)}}function q2(e,t,n){let r="";const s=e.x.translate/t.x,i=e.y.translate/t.y,o=(n==null?void 0:n.z)||0;if((s||i||o)&&(r=`translate3d(${s}px, ${i}px, ${o}px) `),(t.x!==1||t.y!==1)&&(r+=`scale(${1/t.x}, ${1/t.y}) `),n){const{transformPerspective:c,rotate:u,rotateX:d,rotateY:h,skewX:f,skewY:w}=n;c&&(r=`perspective(${c}px) ${r}`),u&&(r+=`rotate(${u}deg) `),d&&(r+=`rotateX(${d}deg) `),h&&(r+=`rotateY(${h}deg) `),f&&(r+=`skewX(${f}deg) `),w&&(r+=`skewY(${w}deg) `)}const a=e.x.scale*t.x,l=e.y.scale*t.y;return(a!==1||l!==1)&&(r+=`scale(${a}, ${l})`),r||"none"}const Ku=["","X","Y","Z"],G2=1e3;let Y2=0;function qu(e,t,n,r){const{latestValues:s}=t;s[e]&&(n[e]=s[e],t.setStaticValue(e,0),r&&(r[e]=0))}function pS(e){if(e.hasCheckedOptimisedAppear=!0,e.root===e)return;const{visualElement:t}=e.options;if(!t)return;const n=Z1(t);if(window.MotionHasOptimisedAnimation(n,"transform")){const{layout:s,layoutId:i}=e.options;window.MotionCancelOptimisedAnimation(n,"transform",ge,!(s||i))}const{parent:r}=e;r&&!r.hasCheckedOptimisedAppear&&pS(r)}function mS({attachResizeListener:e,defaultParent:t,measureScroll:n,checkIsScrollRoot:r,resetTransform:s}){return class{constructor(o={},a=t==null?void 0:t()){this.id=Y2++,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=()=>
vendor: 14,838 bytes, line 213
213{this.projectionUpdateScheduled=!1,this.nodes.forEach(X2),this.nodes.forEach(nI),this.nodes.forEach(rI),this.nodes.forEach(Z2)},this.resolvedRelativeTargetAt=0,this.linkedParentVersion=0,this.hasProjected=!1,this.isVisible=!0,this.animationProgress=0,this.sharedNodes=new Map,this.latestValues=o,this.root=a?a.root||a:this,this.path=a?[...a.path,a]:[],this.parent=a,this.depth=a?a.depth+1:0;for(let l=0;l<this.path.length;l++)this.path[l].shouldResetTransform=!0;this.root===this&&(this.nodes=new L2)}addEventListener(o,a){return this.eventHandlers.has(o)||this.eventHandlers.set(o,new dp),this.eventHandlers.get(o).add(a)}notifyListeners(o,...a){const l=this.eventHandlers.get(o);l&&l.notify(...a)}hasListeners(o){return this.eventHandlers.has(o)}mount(o){if(this.instance)return;this.isSVG=R1(o)&&!KN(o),this.instance=o;const{layoutId:a,layout:l,visualElement:c}=this.options;if(c&&!c.current&&c.mount(o),this.root.nodes.add(this),this.parent&&this.parent.children.add(this),this.root.hasTreeAnimated&&(l||a)&&(this.isLayoutDirty=!0),e){let u,d=0;const h=()=>this.root.updateBlockedByResize=!1;ge.read(()=>{d=window.innerWidth}),e(o,()=>{const f=window.innerWidth;f!==d&&(d=f,this.root.updateBlockedByResize=!0,u&&u(),u=M2(h,250),El.hasAnimatedSinceResize&&(El.hasAnimatedSinceResize=!1,this.nodes.forEach(Gy)))})}a&&this.root.registerSharedNode(a,this),this.options.animate!==!1&&c&&(a||l)&&this.addEventListener("didUpdate",({delta:u,hasLayoutChanged:d,hasRelativeLayoutChanged:h,layout:f})=>{if(this.isTreeAnimationBlocked()){this.target=void 0,this.relativeTarget=void 0;return}const w=this.options.transition||c.getDefaultTransition()||lI,{onLayoutAnimationStart:y,onLayoutAnimationComplete:x}=c.getProps(),m=!this.targetLayout||!fS(this.targetLayout,f),g=!d&&h;if(this.options.layoutRoot||this.resumeFrom||g||d&&(m||!this.currentAnimation)){this.resumeFrom&&(this.resumingFrom=this.resumeFrom,this.resumingFrom.resumingFrom=void 0);const v={..._p(w,"layout"),onPlay:y,onComplete:x};(c.shouldReduceMotion||this.options.layoutRoot)&&(v.delay=0,v.type=!1),this.startAnimation(v),this.setAnimationOrigin(u,g)}else d||Gy(this),this.isLead()&&this.options.onExitComplete&&this.options.onExitComplete();this.targetLayout=f})}unmount(){this.options.layoutId&&this.willUpdate(),this.root.nodes.remove(this);const o=this.getStack();o&&o.remove(this),this.parent&&this.parent.children.delete(this),this.instance=void 0,this.eventHandlers.clear(),Pr(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(sI),this.animationId++)}getTransformTemplate(){const{visualElement:o}=this.options;return o&&o.getProps().transformTemplate}willUpdate(o=!0){if(this.root.hasTreeAnimated=!0,this.root.isUpdateBlocked()){this.options.onExitComplete&&this.options.onExitComplete();return}if(window.MotionCancelOptimisedAnimation&&!this.hasCheckedOptimisedAppear&&pS(this),!this.root.isUpdating&&this.root.startUpdate(),this.isLayoutDirty)return;this.isLayoutDirty=!0;for(let u=0;u<this.path.length;u++){const d=this.path[u];d.shouldResetTransform=!0,d.updateScroll("snapshot"),d.options.layoutRoot&&d.willUpdate(!1)}const{layoutId:a,layout:l}=this.options;if(a===void 0&&!l)return;const c=this.getTransformTemplate();this.prevTransformTemplateValue=c?c(this.latestValues,""):void 0,this.updateSnapshot(),o&&this.notifyListeners("willUpdate")}update(){if(this.updateScheduled=!1,this.isUpdateBlocked()){this.unblockUpdate(),this.clearAllSnapshots(),this.nodes.forEach(Ky);return}if(this.animationId<=this.animationCommitId){this.nodes.forEach(qy);return}this.animationCommitId=this.animationId,this.isUpdating?(this.isUpdating=!1,this.nodes.forEach(tI),this.nodes.forEach(Q2),this.nodes.forEach(J2)):this.nodes.forEach(qy),this.clearAllSnapshots();const a=ht.now();We.delta=Ln(0,1e3/60,a-We.timestamp),We.timestamp=a,We.isProcessing=!0,Du.update.process(We),Du.preRender.process(We),Du.render.process(We),We.isProcessing=!1}didUpdate(){this.updateScheduled||(this.updateScheduled=!0,Ep.read(this.scheduleUpdate))}clearAllSnapshots(){this.nodes.forEach(eI),this.sharedNodes.forEach(iI)}scheduleUpdateProjection(){this.projectionUpdateScheduled||(this.projectionUpdateScheduled=!0,ge.preRender(this.updateProjection,!1,!0))}scheduleCheckAfterUnmount(){ge.postRender(()=>{this.isLayoutDirty?this.root.didUpdate():this.root.checkUpdateFailed()})}updateSnapshot(){this.snapshot||!this.instance||(this.snapshot=this.measure(),this.snapshot&&!it(this.snapshot.measuredBox.x)&&!it(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 l=0;l<this.path.length;l++)this.path[l].updateScroll();const o=this.layout;this.layout=this.measure(!1),this.layoutVersion++,this.layoutCorrected=De(),this.isLayoutDirty=!1,this.projectionDelta=void 0,this.notifyListeners("measure",this.layout.layoutBox);const{visualElement:a}=this.options;a&&a.notify("LayoutMeasure",this.layout.layoutBox,o?o.layoutBox:void 0)}updateScroll(o="measure"){let a=!!(this.options.layoutScroll&&this.instance);if(this.scroll&&this.scroll.animationId===this.root.animationId&&this.scroll.phase===o&&(a=!1),a&&this.instance){const l=r(this.instance);this.scroll={animationId:this.root.animationId,phase:o,isRoot:l,offset:n(this.instance),wasRoot:this.scroll?this.scroll.isRoot:l}}}resetTransform(){if(!s)return;const o=this.isLayoutDirty||this.shouldResetTransform||this.options.alwaysMeasureLayout,a=this.projectionDelta&&!hS(this.projectionDelta),l=this.getTransformTemplate(),c=l?l(this.latestValues,""):void 0,u=c!==this.prevTransformTemplateValue;o&&this.instance&&(a||Wr(this.latestValues)||u)&&(s(this.instance,c),this.shouldResetTransform=!1,this.scheduleRender())}measure(o=!0){const a=this.measurePageBox();let l=this.removeElementScroll(a);return o&&(l=this.removeTransform(l)),cI(l),{animationId:this.root.animationId,measuredBox:a,layoutBox:l,latestValues:{},source:this.id}}measurePageBox(){var c;const{visualElement:o}=this.options;if(!o)return De();const a=o.measureViewportBox();if(!(((c=this.scroll)==null?void 0:c.wasRoot)||this.path.some(uI))){const{scroll:u}=this.root;u&&(Xs(a.x,u.offset.x),Xs(a.y,u.offset.y))}return a}removeElementScroll(o){var l;const a=De();if(zt(a,o),(l=this.scroll)!=null&&l.wasRoot)return a;for(let c=0;c<this.path.length;c++){const u=this.path[c],{scroll:d,options:h}=u;u!==this.root&&d&&h.layoutScroll&&(d.wasRoot&&zt(a,o),Xs(a.x,d.offset.x),Xs(a.y,d.offset.y))}return a}applyTransform(o,a=!1){const l=De();zt(l,o);for(let c=0;c<this.path.length;c++){const u=this.path[c];!a&&u.options.layoutScroll&&u.scroll&&u!==u.root&&Zs(l,{x:-u.scroll.offset.x,y:-u.scroll.offset.y}),Wr(u.latestValues)&&Zs(l,u.latestValues)}return Wr(this.latestValues)&&Zs(l,this.latestValues),l}removeTransform(o){const a=De();zt(a,o);for(let l=0;l<this.path.length;l++){const c=this.path[l];if(!c.instance||!Wr(c.latestValues))continue;Th(c.latestValues)&&c.updateSnapshot();const u=De(),d=c.measurePageBox();zt(u,d),Fy(a,c.latestValues,c.snapshot?c.snapshot.layoutBox:void 0,u)}return Wr(this.latestValues)&&Fy(a,this.latestValues),a}setTargetDelta(o){this.targetDelta=o,this.root.scheduleUpdateProjection(),this.isProjectionDirty=!0}setOptions(o){this.options={...this.options,...o,crossfade:o.crossfade!==void 0?o.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!==We.timestamp&&this.relativeParent.resolveTargetDelta(!0)}resolveTargetDelta(o=!1){var f;const a=this.getLead();this.isProjectionDirty||(this.isProjectionDirty=a.isProjectionDirty),this.isTransformDirty||(this.isTransformDirty=a.isTransformDirty),this.isSharedProjectionDirty||(this.isSharedProjectionDirty=a.isSharedProjectionDirty);const l=!!this.resumingFrom||this!==a;if(!(o||l&&this.isSharedProjectionDirty||this.isProjectionDirty||(f=this.parent)!=null&&f.isProjectionDirty||this.attemptToResolveRelativeTarget||this.root.updateBlockedByResize))return;const{layout:u,layoutId:d}=this.options;if(!this.layout||!(u||d))return;this.resolvedRelativeTargetAt=We.timestamp;const h=this.getClosestProjectingParent();h&&this.linkedParentVersion!==h.layoutVersion&&!h.options.layoutRoot&&this.removeRelativeTarget(),!this.targetDelta&&!this.relativeTarget&&(h&&h.layout?this.createRelativeTarget(h,this.layout.layoutBox,h.layout.layoutBox):this.removeRelativeTarget()),!(!this.relativeTarget&&!this.targetDelta)&&(this.target||(this.target=De(),this.targetWithTransforms=De()),this.relativeTarget&&this.relativeTargetOrigin&&this.relativeParent&&this.relativeParent.target?(this.forceRelativeParentToResolveTarget(),v2(this.target,this.relativeTarget,this.relativeParent.target)):this.targetDelta?(this.resumingFrom?this.target=this.applyTransform(this.layout.layoutBox):zt(this.target,this.layout.layoutBox),q1(this.target,this.targetDelta)):zt(this.target,this.layout.layoutBox),this.attemptToResolveRelativeTarget&&(this.attemptToResolveRelativeTarget=!1,h&&!!h.resumingFrom==!!this.resumingFrom&&!h.options.layoutScroll&&h.target&&this.animationProgress!==1?this.createRelativeTarget(h,this.target,h.target):this.relativeParent=this.relativeTarget=void 0))}getClosestProjectingParent(){if(!(!this.parent||Th(this.parent.latestValues)||K1(this.parent.latestValues)))return this.parent.isProjecting()?this.parent:this.parent.getClosestProjectingParent()}isProjecting(){return!!((this.relativeTarget||this.targetDelta||this.options.layoutRoot)&&this.layout)}createRelativeTarget(o,a,l){this.relativeParent=o,this.linkedParentVersion=o.layoutVersion,this.forceRelativeParentToResolveTarget(),this.relativeTarget=De(),this.relativeTargetOrigin=De(),uc(this.relativeTargetOrigin,a,l),zt(this.relativeTarget,this.relativeTargetOrigin)}removeRelativeTarget(){this.relativeParent=this.relativeTarget=void 0}calcProjection(){var w;const o=this.getLead(),a=!!this.resumingFrom||this!==o;let l=!0;if((this.isProjectionDirty||(w=this.parent)!=null&&w.isProjectionDirty)&&(l=!1),a&&(this.isSharedProjectionDirty||this.isTransformDirty)&&(l=!1),this.resolvedRelativeTargetAt===We.timestamp&&(l=!1),l)return;const{layout:c,layoutId:u}=this.options;if(this.isTreeAnimating=!!(this.parent&&this.parent.isTreeAnimating||this.currentAnimation||this.pendingAnimation),this.isTreeAnimating||(this.targetDelta=this.relativeTarget=void 0),!this.layout||!(c||u))return;zt(this.layoutCorrected,this.layout.layoutBox);const d=this.treeScale.x,h=this.treeScale.y;RO(this.layoutCorrected,this.treeScale,this.path,a),o.layout&&!o.target&&(this.treeScale.x!==1||this.treeScale.y!==1)&&(o.target=o.layout.layoutBox,o.targetWithTransforms=De());const{target:f}=o;if(!f){this.prevProjectionDelta&&(this.createProjectionDeltas(),this.scheduleRender());return}!this.projectionDelta||!this.prevProjectionDelta?this.createProjectionDeltas():(My(this.prevProjectionDelta.x,this.projectionDelta.x),My(this.prevProjectionDelta.y,this.projectionDelta.y)),ko(this.projectionDelta,this.layoutCorrected,f,this.latestValues),(this.treeScale.x!==d||this.treeScale.y!==h||!Hy(this.projectionDelta.x,this.prevProjectionDelta.x)||!Hy(this.projectionDelta.y,this.prevProjectionDelta.y))&&(this.hasProjected=!0,this.scheduleRender(),this.notifyListeners("projectionUpdate",f))}hide(){this.isVisible=!1}show(){this.isVisible=!0}scheduleRender(o=!0){var a;if((a=this.options.visualElement)==null||a.scheduleRender(),o){const l=this.getStack();l&&l.scheduleRender()}this.resumingFrom&&!this.resumingFrom.instance&&(this.resumingFrom=void 0)}createProjectionDeltas(){this.prevProjectionDelta=ei(),this.projectionDelta=ei(),this.projectionDeltaWithTransform=ei()}setAnimationOrigin(o,a=!1){const l=this.snapshot,c=l?l.latestValues:{},u={...this.latestValues},d=ei();(!this.relativeParent||!this.relativeParent.options.layoutRoot)&&(this.relativeTarget=this.relativeTargetOrigin=void 0),this.attemptToResolveRelativeTarget=!a;const h=De(),f=l?l.source:void 0,w=this.layout?this.layout.source:void 0,y=f!==w,x=this.getStack(),m=!x||x.members.length<=1,g=!!(y&&!m&&this.options.crossfade===!0&&!this.path.some(aI));this.animationProgress=0;let v;this.mixTargetDelta=S=>{const _=S/1e3;Yy(d.x,o.x,_),Yy(d.y,o.y,_),this.setTargetDelta(d),this.relativeTarget&&this.relativeTargetOrigin&&this.layout&&this.relativeParent&&this.relativeParent.layout&&(uc(h,this.layout.layoutBox,this.relativeParent.layout.layoutBox),oI(this.relativeTarget,this.relativeTargetOrigin,h,_),v&&H2(this.relativeTarget,v)&&(this.isProjectionDirty=!1),v||(v=De()),zt(v,this.relativeTarget)),y&&(this.animationValues=u,V2(u,c,this.latestValues,_,g,m)),this.root.scheduleUpdateProjection(),this.scheduleRender(),this.animationProgress=_},this.mixTargetDelta(this.options.layoutRoot?1e3:0)}startAnimation(o){var a,l,c;this.notifyListeners("animationStart"),(a=this.currentAnimation)==null||a.stop(),(c=(l=this.resumingFrom)==null?void 0:l.currentAnimation)==null||c.stop(),this.pendingAnimation&&(Pr(this.pendingAnimation),this.pendingAnimation=void 0),this.pendingAnimation=ge.update(()=>{El.hasAnimatedSinceResize=!0,this.motionValue||(this.motionValue=Ai(0)),this.currentAnimation=I2(this.motionValue,[0,1e3],{...o,velocity:0,isSync:!0,onUpdate:u=>{this.mixTargetDelta(u),o.onUpdate&&o.onUpdate(u)},onStop:()=>{},onComplete:()=>{o.onComplete&&o.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 o=this.getStack();o&&o.exitAnimationComplete(),this.resumingFrom=this.currentAnimation=this.animationValues=void 0,this.notifyListeners("animationComplete")}finishAnimation(){this.currentAnimation&&(this.mixTargetDelta&&this.mixTargetDelta(G2),this.currentAnimation.stop()),this.completeAnimation()}applyTransformsToTarget(){const o=this.getLead();let{targetWithTransforms:a,target:l,layout:c,latestValues:u}=o;if(!(!a||!l||!c)){if(this!==o&&this.layout&&c&&gS(this.options.animationType,this.layout.layoutBox,c.layoutBox)){l=this.target||De();const d=it(this.layout.layoutBox.x);l.x.min=o.target.x.min,l.x.max=l.x.min+d;const h=it(this.layout.layoutBox.y);l.y.min=o.target.y.min,l.y.max=l.y.min+h}
vendor: 11,127 bytes, line 213
213zt(a,l),Zs(a,u),ko(this.projectionDeltaWithTransform,this.layoutCorrected,a,u)}}registerSharedNode(o,a){this.sharedNodes.has(o)||this.sharedNodes.set(o,new K2),this.sharedNodes.get(o).add(a);const c=a.options.initialPromotionConfig;a.promote({transition:c?c.transition:void 0,preserveFollowOpacity:c&&c.shouldPreserveFollowOpacity?c.shouldPreserveFollowOpacity(a):void 0})}isLead(){const o=this.getStack();return o?o.lead===this:!0}getLead(){var a;const{layoutId:o}=this.options;return o?((a=this.getStack())==null?void 0:a.lead)||this:this}getPrevLead(){var a;const{layoutId:o}=this.options;return o?(a=this.getStack())==null?void 0:a.prevLead:void 0}getStack(){const{layoutId:o}=this.options;if(o)return this.root.sharedNodes.get(o)}promote({needsReset:o,transition:a,preserveFollowOpacity:l}={}){const c=this.getStack();c&&c.promote(this,l),o&&(this.projectionDelta=void 0,this.needsReset=!0),a&&this.setOptions({transition:a})}relegate(){const o=this.getStack();return o?o.relegate(this):!1}resetSkewAndRotation(){const{visualElement:o}=this.options;if(!o)return;let a=!1;const{latestValues:l}=o;if((l.z||l.rotate||l.rotateX||l.rotateY||l.rotateZ||l.skewX||l.skewY)&&(a=!0),!a)return;const c={};l.z&&qu("z",o,c,this.animationValues);for(let u=0;u<Ku.length;u++)qu(`rotate${Ku[u]}`,o,c,this.animationValues),qu(`skew${Ku[u]}`,o,c,this.animationValues);o.render();for(const u in c)o.setStaticValue(u,c[u]),this.animationValues&&(this.animationValues[u]=c[u]);o.scheduleRender()}applyProjectionStyles(o,a){if(!this.instance||this.isSVG)return;if(!this.isVisible){o.visibility="hidden";return}const l=this.getTransformTemplate();if(this.needsReset){this.needsReset=!1,o.visibility="",o.opacity="",o.pointerEvents=kl(a==null?void 0:a.pointerEvents)||"",o.transform=l?l(this.latestValues,""):"none";return}const c=this.getLead();if(!this.projectionDelta||!this.layout||!c.target){this.options.layoutId&&(o.opacity=this.latestValues.opacity!==void 0?this.latestValues.opacity:1,o.pointerEvents=kl(a==null?void 0:a.pointerEvents)||""),this.hasProjected&&!Wr(this.latestValues)&&(o.transform=l?l({},""):"none",this.hasProjected=!1);return}o.visibility="";const u=c.animationValues||c.latestValues;this.applyTransformsToTarget();let d=q2(this.projectionDeltaWithTransform,this.treeScale,u);l&&(d=l(u,d)),o.transform=d;const{x:h,y:f}=this.projectionDelta;o.transformOrigin=`${h.origin*100}% ${f.origin*100}% 0`,c.animationValues?o.opacity=c===this?u.opacity??this.latestValues.opacity??1:this.preserveOpacity?this.latestValues.opacity:u.opacityExit:o.opacity=c===this?u.opacity!==void 0?u.opacity:"":u.opacityExit!==void 0?u.opacityExit:0;for(const w in Eh){if(u[w]===void 0)continue;const{correct:y,applyTo:x,isCSSVariable:m}=Eh[w],g=d==="none"?u[w]:y(u[w],c);if(x){const v=x.length;for(let S=0;S<v;S++)o[x[S]]=g}else m?this.options.visualElement.renderState.vars[w]=g:o[w]=g}this.options.layoutId&&(o.pointerEvents=c===this?kl(a==null?void 0:a.pointerEvents)||"":"none")}clearSnapshot(){this.resumeFrom=this.snapshot=void 0}resetTree(){this.root.nodes.forEach(o=>{var a;return(a=o.currentAnimation)==null?void 0:a.stop()}),this.root.nodes.forEach(Ky),this.root.sharedNodes.clear()}}}function Q2(e){e.updateLayout()}function J2(e){var n;const t=((n=e.resumeFrom)==null?void 0:n.snapshot)||e.snapshot;if(e.isLead()&&e.layout&&t&&e.hasListeners("didUpdate")){const{layoutBox:r,measuredBox:s}=e.layout,{animationType:i}=e.options,o=t.source!==e.layout.source;i==="size"?Ct(d=>{const h=o?t.measuredBox[d]:t.layoutBox[d],f=it(h);h.min=r[d].min,h.max=h.min+f}):gS(i,t.layoutBox,r)&&Ct(d=>{const h=o?t.measuredBox[d]:t.layoutBox[d],f=it(r[d]);h.max=h.min+f,e.relativeTarget&&!e.currentAnimation&&(e.isProjectionDirty=!0,e.relativeTarget[d].max=e.relativeTarget[d].min+f)});const a=ei();ko(a,r,t.layoutBox);const l=ei();o?ko(l,e.applyTransform(s,!0),t.measuredBox):ko(l,r,t.layoutBox);const c=!hS(a);let u=!1;if(!e.resumeFrom){const d=e.getClosestProjectingParent();if(d&&!d.resumeFrom){const{snapshot:h,layout:f}=d;if(h&&f){const w=De();uc(w,t.layoutBox,h.layoutBox);const y=De();uc(y,r,f.layoutBox),fS(w,y)||(u=!0),d.options.layoutRoot&&(e.relativeTarget=y,e.relativeTargetOrigin=w,e.relativeParent=d)}}}e.notifyListeners("didUpdate",{layout:r,snapshot:t,delta:l,layoutDelta:a,hasLayoutChanged:c,hasRelativeLayoutChanged:u})}else if(e.isLead()){const{onExitComplete:r}=e.options;r&&r()}e.options.transition=void 0}function X2(e){e.parent&&(e.isProjecting()||(e.isProjectionDirty=e.parent.isProjectionDirty),e.isSharedProjectionDirty||(e.isSharedProjectionDirty=!!(e.isProjectionDirty||e.parent.isProjectionDirty||e.parent.isSharedProjectionDirty)),e.isTransformDirty||(e.isTransformDirty=e.parent.isTransformDirty))}function Z2(e){e.isProjectionDirty=e.isSharedProjectionDirty=e.isTransformDirty=!1}function eI(e){e.clearSnapshot()}function Ky(e){e.clearMeasurements()}function qy(e){e.isLayoutDirty=!1}function tI(e){const{visualElement:t}=e.options;t&&t.getProps().onBeforeLayoutMeasure&&t.notify("BeforeLayoutMeasure"),e.resetTransform()}function Gy(e){e.finishAnimation(),e.targetDelta=e.relativeTarget=e.target=void 0,e.isProjectionDirty=!0}function nI(e){e.resolveTargetDelta()}function rI(e){e.calcProjection()}function sI(e){e.resetSkewAndRotation()}function iI(e){e.removeLeadSnapshot()}function Yy(e,t,n){e.translate=we(t.translate,0,n),e.scale=we(t.scale,1,n),e.origin=t.origin,e.originPoint=t.originPoint}function Qy(e,t,n,r){e.min=we(t.min,n.min,r),e.max=we(t.max,n.max,r)}function oI(e,t,n,r){Qy(e.x,t.x,n.x,r),Qy(e.y,t.y,n.y,r)}function aI(e){return e.animationValues&&e.animationValues.opacityExit!==void 0}const lI={duration:.45,ease:[.4,0,.1,1]},Jy=e=>typeof navigator<"u"&&navigator.userAgent&&navigator.userAgent.toLowerCase().includes(e),Xy=Jy("applewebkit/")&&!Jy("chrome/")?Math.round:It;function Zy(e){e.min=Xy(e.min),e.max=Xy(e.max)}function cI(e){Zy(e.x),Zy(e.y)}function gS(e,t,n){return e==="position"||e==="preserve-aspect"&&!y2(Wy(t),Wy(n),.2)}function uI(e){var t;return e!==e.root&&((t=e.scroll)==null?void 0:t.wasRoot)}const dI=mS({attachResizeListener:(e,t)=>ea(e,"resize",t),measureScroll:()=>({x:document.documentElement.scrollLeft||document.body.scrollLeft,y:document.documentElement.scrollTop||document.body.scrollTop}),checkIsScrollRoot:()=>!0}),Gu={current:void 0},yS=mS({measureScroll:e=>({x:e.scrollLeft,y:e.scrollTop}),defaultParent:()=>{if(!Gu.current){const e=new dI({});e.mount(window),e.setOptions({layoutScroll:!0}),Gu.current=e}return Gu.current},resetTransform:(e,t)=>{e.style.transform=t!==void 0?t:"none"},checkIsScrollRoot:e=>window.getComputedStyle(e).position==="fixed"}),hI={pan:{Feature:N2},drag:{Feature:j2,ProjectionNode:yS,MeasureLayout:cS}};function ev(e,t,n){const{props:r}=e;e.animationState&&r.whileHover&&e.animationState.setActive("whileHover",n==="Start");const s="onHover"+n,i=r[s];i&&ge.postRender(()=>i(t,_a(t)))}class fI extends Or{mount(){const{current:t}=this.node;t&&(this.unmount=UN(t,(n,r)=>(ev(this.node,r,"Start"),s=>ev(this.node,s,"End"))))}unmount(){}}class pI extends Or{constructor(){super(...arguments),this.isActive=!1}onFocus(){let t=!1;try{t=this.node.current.matches(":focus-visible")}catch{t=!0}!t||!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=xa(ea(this.node.current,"focus",()=>this.onFocus()),ea(this.node.current,"blur",()=>this.onBlur()))}unmount(){}}function tv(e,t,n){const{props:r}=e;if(e.current instanceof HTMLButtonElement&&e.current.disabled)return;e.animationState&&r.whileTap&&e.animationState.setActive("whileTap",n==="Start");const s="onTap"+(n==="End"?"":n),i=r[s];i&&ge.postRender(()=>i(t,_a(t)))}class mI extends Or{mount(){const{current:t}=this.node;t&&(this.unmount=HN(t,(n,r)=>(tv(this.node,r,"Start"),(s,{success:i})=>tv(this.node,s,i?"End":"Cancel")),{useGlobalTarget:this.node.props.globalTapTarget}))}unmount(){}}const Oh=new WeakMap,Yu=new WeakMap,gI=e=>{const t=Oh.get(e.target);t&&t(e)},yI=e=>{e.forEach(gI)};function vI({root:e,...t}){const n=e||document;Yu.has(n)||Yu.set(n,{});const r=Yu.get(n),s=JSON.stringify(t);return r[s]||(r[s]=new IntersectionObserver(yI,{root:e,...t})),r[s]}function wI(e,t,n){const r=vI(t);return Oh.set(e,n),r.observe(e),()=>{Oh.delete(e),r.unobserve(e)}}const xI={some:0,all:1};class bI extends Or{constructor(){super(...arguments),this.hasEnteredView=!1,this.isInView=!1}startObserver(){this.unmount();const{viewport:t={}}=this.node.getProps(),{root:n,margin:r,amount:s="some",once:i}=t,o={root:n?n.current:void 0,rootMargin:r,threshold:typeof s=="number"?s:xI[s]},a=l=>{const{isIntersecting:c}=l;if(this.isInView===c||(this.isInView=c,i&&!c&&this.hasEnteredView))return;c&&(this.hasEnteredView=!0),this.node.animationState&&this.node.animationState.setActive("whileInView",c);const{onViewportEnter:u,onViewportLeave:d}=this.node.getProps(),h=c?u:d;h&&h(l)};return wI(this.node.current,o,a)}mount(){this.startObserver()}update(){if(typeof IntersectionObserver>"u")return;const{props:t,prevProps:n}=this.node;["amount","margin","root"].some(SI(t,n))&&this.startObserver()}unmount(){}}function SI({viewport:e={}},{viewport:t={}}={}){return n=>e[n]!==t[n]}const _I={inView:{Feature:bI},tap:{Feature:mI},focus:{Feature:pI},hover:{Feature:fI}},kI={layout:{ProjectionNode:yS,MeasureLayout:cS}},EI={...d2,..._I,...hI,...kI},R=CO(EI,FO),TI=Tx("inline-flex items-center justify-center gap-2 whitespace-nowrap rounded-md text-sm font-semibold ring-offset-background transition-all duration-300 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",accent:"bg-gradient-to-r from-[hsl(8,85%,55%)] to-[hsl(25,95%,55%)] text-[hsl(0,0%,100%)] shadow-[0_8px_30px_hsla(8,85%,55%,0.3)] hover:shadow-[0_12px_50px_hsla(8,85%,55%,0.4)] hover:-translate-y-0.5",hero:"bg-gradient-to-r from-[hsl(8,85%,55%)] to-[hsl(25,95%,55%)] text-[hsl(0,0%,100%)] shadow-[0_12px_50px_hsla(8,85%,55%,0.4)] hover:shadow-[0_16px_60px_hsla(8,85%,55%,0.5)] hover:-translate-y-1 font-display uppercase tracking-wider",dark:"bg-[hsl(0,0%,8%)] text-[hsl(0,0%,100%)] hover:bg-[hsl(0,0%,12%)]","outline-dark":"border-2 border-[hsl(0,0%,8%)] text-[hsl(0,0%,8%)] hover:bg-[hsl(0,0%,8%)] hover:text-[hsl(0,0%,100%)]","outline-accent":"border-2 border-[hsl(8,85%,55%)] text-[hsl(8,85%,55%)] hover:bg-[hsl(8,85%,55%)] hover:text-[hsl(0,0%,100%)]"},size:{default:"h-10 px-4 py-2",sm:"h-9 rounded-md px-3",lg:"h-12 rounded-md px-8 text-base",xl:"h-14 roun
213ded-lg px-10 text-lg",icon:"h-10 w-10"}},defaultVariants:{variant:"default",size:"default"}}),$n=b.forwardRef(({className:e,variant:t,size:n,asChild:r=!1,...s},i)=>{const o=r?AE:"button";return p.jsx(o,{className:Mt(TI({variant:t,size:n,className:e})),ref:i,...s})});$n.displayName="Button";const Zt=b.forwardRef(({className:e,type:t,...n},r)=>p.jsx("input",{type:t,className:Mt("flex h-10 w-full rounded-md border border-input bg-background px-3 py-2 text-base ring-offset-background file:border-0 file:bg-transparent file:text-sm file:font-medium file:text-foreground placeholder:text-muted-foreground focus-visible:outline-none focus-visible:ring-2 focus-visible:ring-ring focus-visible:ring-offset-2 disabled:cursor-not-allowed disabled:opacity-50 md:text-sm",e),ref:r,...n}));Zt.displayName="Input";const Lp=b.forwardRef(({className:e,...t},n)=>p.jsx("textarea",{className:Mt("flex min-h-[80px] w-full rounded-md border border-input bg-background px-3 py-2 text-sm ring-offset-background placeholder:text-muted-foreground focus-visible:outline-none focus-visible:ring-2 focus-visible:ring-ring focus-visible:ring-offset-2 disabled:cursor-not-allowed disabled:opacity-50",e),ref:n,...t}));Lp.displayName="Textarea";function CI(e){const t=b.useRef({value:e,previous:e});return b.useMemo(()=>(t.current.value!==e&&(t.current.previous=t.current.value,t.current.value=e),t.current.previous),[e])}var Hc="Checkbox",[PI,$M]=ma(Hc),[AI,Mp]=PI(Hc);function RI(e){const{__scopeCheckbox:t,checked:n,children:r,defaultChecked:s,disabled:i,form:o,name:a,onCheckedChange:l,required:c,value:u="on",internal_do_not_use_render:d}=e,[h,f]=sx({prop:n,defaultProp:s??!1,onChange:l,caller:Hc}),[w,y]=b.useState(null),[x,m]=b.useState(null),g=b.useRef(!1),v=w?!!o||!!w.closest("form"):!0,S={checked:h,disabled:i,setChecked:f,control:w,setControl:y,name:a,form:o,value:u,hasConsumerStoppedPropagationRef:g,required:c,defaultChecked:br(s)?!1:s,isFormControl:v,bubbleInput:x,setBubbleInput:m};return p.jsx(AI,{scope:t,...S,children:jI(d)?d(S):r})}var vS="CheckboxTrigger",wS=b.forwardRef(({__scopeCheckbox:e,onKeyDown:t,onClick:n,...r},s)=>{const{control:i,value:o,disabled:a,checked:l,required:c,setControl:u,setChecked:d,hasConsumerStoppedPropagationRef:h,isFormControl:f,bubbleInput:w}=Mp(vS,e),y=_t(s,u),x=b.useRef(l);return b.useEffect(()=>{const m=i==null?void 0:i.form;if(m){const g=()=>d(x.current);return m.addEventListener("reset",g),()=>m.removeEventListener("reset",g)}},[i,d]),p.jsx(qe.button,{type:"button",role:"checkbox","aria-checked":br(l)?"mixed":l,"aria-required":c,"data-state":kS(l),"data-disabled":a?"":void 0,disabled:a,value:o,...r,ref:y,onKeyDown:Ce(t,m=>{m.key==="Enter"&&m.preventDefault()}),onClick:Ce(n,m=>{d(g=>br(g)?!0:!g),w&&f&&(h.current=m.isPropagationStopped(),h.current||m.stopPropagation())})})});wS.displayName=vS;var $p=b.forwardRef((e,t)=>{const{__scopeCheckbox:n,name:r,checked:s,defaultChecked:i,required:o,disabled:a,value:l,onCheckedChange:c,form:u,...d}=e;return p.jsx(RI,{__scopeCheckbox:n,checked:s,defaultChecked:i,disabled:a,required:o,onCheckedChange:c,name:r,form:u,value:l,internal_do_not_use_render:({isFormControl:h})=>p.jsxs(p.Fragment,{children:[p.jsx(wS,{...d,ref:t,__scopeCheckbox:n}),h&&p.jsx(_S,{__scopeCheckbox:n})]})})});$p.displayName=Hc;var xS="CheckboxIndicator",bS=b.forwardRef((e,t)=>{const{__scopeCheckbox:n,forceMount:r,...s}=e,i=Mp(xS,n);return p.jsx(Rc,{present:r||br(i.checked)||i.checked===!0,children:p.jsx(qe.span,{"data-state":kS(i.checked),"data-disabled":i.disabled?"":void 0,...s,ref:t,style:{pointerEvents:"none",...e.style}})})});bS.displayName=xS;var SS="CheckboxBubbleInput",_S=b.forwardRef(({__scopeCheckbox:e,...t},n)=>{const{control:r,hasConsumerStoppedPropagationRef:s,checked:i,defaultChecked:o,required:a,disabled:l,name:c,value:u,form:d,bubbleInput:h,setBubbleInput:f}=Mp(SS,e),w=_t(n,f),y=CI(i),x=nb(r);b.useEffect(()=>{const g=h;if(!g)return;const v=window.HTMLInputElement.prototype,_=Object.getOwnPropertyDescriptor(v,"checked").set,k=!s.current;if(y!==i&&_){const E=new Event("click",{bubbles:k});g.indeterminate=br(i),_.call(g,br(i)?!1:i),g.dispatchEvent(E)}},[h,y,i,s]);const m=b.useRef(br(i)?!1:i);return p.jsx(qe.input,{type:"checkbox","aria-hidden":!0,defaultChecked:o??m.current,required:a,disabled:l,name:c,value:u,form:d,...t,tabIndex:-1,ref:w,style:{...t.style,...x,position:"absolute",pointerEvents:"none",opacity:0,margin:0,transform:"translateX(-100%)"}})});_S.displayName=SS;function jI(e){return typeof e=="function"}function br(e){return e==="indeterminate"}function kS(e){return br(e)?"indeterminate":e?"checked":"unchecked"}const Vp=b.forwardRef(({className:e,...t},n)=>p.jsx($p,{ref:n,className:Mt("peer h-4 w-4 shrink-0 rounded-sm border border-primary ring-offset-background data-[state=checked]:bg-primary data-[state=checked]:text-primary-foreground focus-visible:outline-none focus-visible:ring-2 focus-visible:ring-ring focus-visible:ring-offset-2 disabled:cursor-not-allowed disabled:opacity-50",e),...t,children:p.jsx(bS,{className:Mt("flex items-center justify-center text-current"),children:p.jsx(Ax,{className:"h-4 w-4"})})}));Vp.displayName=$p.displayName;const Ui=()=>(b.useEffect(()=>{const e=()=>{const n=document.documentElement.scrollHeight;
213window.parent.postMessage({type:"container_height",height:n},"*")};e();const t=new ResizeObserver(()=>{e()});return t.observe(document.body),()=>{t.disconnect()}},[]),p.jsx(p.Fragment,{}));function Kc(e,t){var n={};for(var r in e)Object.prototype.hasOwnProperty.call(e,r)&&t.indexOf(r)<0&&(n[r]=e[r]);if(e!=null&&typeof Object.getOwnPropertySymbols=="function")for(var s=0,r=Object.getOwnPropertySymbols(e);s<r.length;s++)t.indexOf(r[s])<0&&Object.prototype.propertyIsEnumerable.call(e,r[s])&&(n[r[s]]=e[r[s]]);return n}function NI(e,t,n,r){function s(i){return i instanceof n?i:new n(function(o){o(i)})}return new(n||(n=Promise))(function(i,o){function a(u){try{c(r.next(u))}catch(d){o(d)}}function l(u){try{c(r.throw(u))}catch(d){o(d)}}function c(u){u.done?i(u.value):s(u.value).then(a,l)}c((r=r.apply(e,t||[])).next())})}const OI=e=>e?(...t)=>e(...t):(...t)=>fetch(...t);class Fp extends Error{constructor(t,n="FunctionsError",r){super(t),this.name=n,this.context=r}}class II extends Fp{constructor(t){super("Failed to send a request to the Edge Function","FunctionsFetchError",t)}}class nv extends Fp{constructor(t){super("Relay Error invoking the Edge Function","FunctionsRelayError",t)}}class rv extends Fp{constructor(t){super("Edge Function returned a non-2xx status code","FunctionsHttpError",t)}}var Ih;(function(e){e.Any="any",e.ApNortheast1="ap-northeast-1",e.ApNortheast2="ap-northeast-2",e.ApSouth1="ap-south-1",e.ApSoutheast1="ap-southeast-1",e.ApSoutheast2="ap-southeast-2",e.CaCentral1="ca-central-1",e.EuCentral1="eu-central-1",e.EuWest1="eu-west-1",e.EuWest2="eu-west-2",e.EuWest3="eu-west-3",e.SaEast1="sa-east-1",e.UsEast1="us-east-1",e.UsWest1="us-west-1",e.UsWest2="us-west-2"})(Ih||(Ih={}));class DI{constructor(t,{headers:n={},customFetch:r,region:s=Ih.Any}={}){this.url=t,this.headers=n,this.region=s,this.fetch=OI(r)}setAuth(t){this.headers.Authorization=`Bearer ${t}`}invoke(t){return NI(this,arguments,void 0,function*(n,r={}){var s;let i,o;try{const{headers:a,method:l,body:c,signal:u,timeout:d}=r;let h={},{region:f}=r;f||(f=this.region);const w=new URL(`${this.url}/${n}`);f&&f!=="any"&&(h["x-region"]=f,w.searchParams.set("forceFunctionRegion",f));let y;c&&(a&&!Object.prototype.hasOwnProperty.call(a,"Content-Type")||!a)?typeof Blob<"u"&&c instanceof Blob||c instanceof ArrayBuffer?(h["Content-Type"]="application/octet-stream",y=c):typeof c=="string"?(h["Content-Type"]="text/plain",y=c):typeof FormData<"u"&&c instanceof FormData?y=c:(h["Content-Type"]="application/json",y=JSON.stringify(c)):c&&typeof c!="string"&&!(typeof Blob<"u"&&c instanceof Blob)&&!(c instanceof ArrayBuffer)&&!(typeof FormData<"u"&&c instanceof FormData)?y=JSON.stringify(c):y=c;let x=u;d&&(o=new AbortController,i=setTimeout(()=>o.abort(),d),u?(x=o.signal,u.addEventListener("abort",()=>o.abort())):x=o.signal);const m=yield this.fetch(w.toString(),{method:l||"POST",headers:Object.assign(Object.assign(Object.assign({},h),this.headers),a),body:y,signal:x}).catch(_=>{throw new II(_)}),g=m.headers.get("x-relay-error");if(g&&g==="true")throw new nv(m);if(!m.ok)throw new rv(m);let v=((s=m.headers.get("Content-Type"))!==null&&s!==void 0?s:"text/plain").split(";")[0].trim(),S;return v==="application/json"?S=yield m.json():v==="application/octet-stream"||v==="application/pdf"?S=yield m.blob():v==="text/event-stream"?S=m:v==="multipart/form-data"?S=yield m.formData():S=yield m.text(),{data:S,error:null,response:m}}catch(a){return{data:null,error:a,response:a instanceof rv||a instanceof nv?a.context:void 0}}finally{i&&clearTimeout(i)}})}}var LI=class extends Error{constructor(e){super(e.message),this.name="PostgrestError",this.details=e.details,this.hint=e.hint,this.co
213de=e.code}},MI=class{constructor(e){var t,n;this.shouldThrowOnError=!1,this.method=e.method,this.url=e.url,this.headers=new Headers(e.headers),this.schema=e.schema,this.body=e.body,this.shouldThrowOnError=(t=e.shouldThrowOnError)!==null&&t!==void 0?t:!1,this.signal=e.signal,this.isMaybeSingle=(n=e.isMaybeSingle)!==null&&n!==void 0?n:!1,e.fetch?this.fetch=e.fetch:this.fetch=fetch}throwOnError(){return this.shouldThrowOnError=!0,this}setHeader(e,t){return this.headers=new Headers(this.headers),this.headers.set(e,t),this}then(e,t){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 s=r(this.url.toString(),{method:this.method,headers:this.headers,body:JSON.stringify(this.body),signal:this.signal}).then(async i=>{let o=null,a=null,l=null,c=i.status,u=i.statusText;if(i.ok){var d,h;if(n.method!=="HEAD"){var f;const m=await i.text();m===""||(n.headers.get("Accept")==="text/csv"||n.headers.get("Accept")&&(!((f=n.headers.get("Accept"))===null||f===void 0)&&f.includes("application/vnd.pgrst.plan+text"))?a=m:a=JSON.parse(m))}const y=(d=n.headers.get("Prefer"))===null||d===void 0?void 0:d.match(/count=(exact|planned|estimated)/),x=(h=i.headers.get("content-range"))===null||h===void 0?void 0:h.split("/");y&&x&&x.length>1&&(l=parseInt(x[1])),n.isMaybeSingle&&n.method==="GET"&&Array.isArray(a)&&(a.length>1?(o={code:"PGRST116",details:`Results contain ${a.length} rows, application/vnd.pgrst.object+json requires 1 row`,hint:null,message:"JSON object requested, multiple (or no) rows returned"},a=null,l=null,c=406,u="Not Acceptable"):a.length===1?a=a[0]:a=null)}else{var w;const y=await i.text();try{o=JSON.parse(y),Array.isArray(o)&&i.status===404&&(a=[],o=null,c=200,u="OK")}catch{i.status===404&&y===""?(c=204,u="No Content"):o={message:y}}if(o&&n.isMaybeSingle&&(!(o==null||(w=o.details)===null||w===void 0)&&w.includes("0 rows"))&&(o=null,c=200,u="OK"),o&&n.shouldThrowOnError)throw new LI(o)}return{error:o,data:a,count:l,status:c,statusText:u}});return this.shouldThrowOnError||(s=s.catch(i=>{var o;let a="";const l=i==null?void 0:i.cause;if(l){var c,u,d,h;const w=(c=l==null?void 0:l.message)!==null&&c!==void 0?c:"",y=(u=l==null?void 0:l.code)!==null&&u!==void 0?u:"";a=`${(d=i==null?void 0:i.name)!==null&&d!==void 0?d:"FetchError"}: ${i==null?void 0:i.message}`,a+=` 214 215Caused by: ${(h=l==null?void 0:l.name)!==null&&h!==void 0?h:"Error"}: ${w}`,y&&(a+=` (${y})`),l!=null&&l.stack&&(a+=` 216${l.stack}`)}else{var f;a=(f=i==null?void 0:i.stack)!==null&&f!==void 0?f:""}return{error:{message:`${(o=i==null?void 0:i.name)!==null&&o!==void 0?o:"FetchError"}: ${i==null?void 0:i.message}`,details:a,hint:"",code:""},data:null,count:null,status:0,statusText:""}})),s.then(e,t)}returns(){return this}overrideTypes(){return this}},$I=class extends MI{select(e){let t=!1;const n=(e??"*").split("").map(r=>/\s/.test(r)&&!t?"":(r==='"'&&(t=!t),r)).join("");return this.url.searchParams.set("select",n),this.headers.append("Prefer","return=representation"),this}order(e,{ascending:t=!0,nullsFirst:n,foreignTable:r,referencedTable:s=r}={}){const i=s?`${s}.order`:"order",o=this.url.searchParams.get(i);return this.url.searchParams.set(i,`${o?`${o},`:""}${e}.${t?"asc":"desc"}${n===void 0?"":n?".nullsfirst":".nullslast"}`),this}limit(e,{foreignTable:t,referencedTable:n=t}={}){const r=typeof n>"u"?"limit":`${n}.limit`;return this.url.searchParams.set(r,`${e}`),this}range(e,t,{foreignTable:n,referencedTable:r=n}={}){const s=typeof r>"u"?"offset":`${r}.offset`,i=typeof r>"u"?"limit":`${r}.limit`;return this.url.searchParams.set(s,`${e}`),this.url.searchParams.set(i,`${t-e+1}`),this}abortSignal(e){return this.signal=e,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}
216explain({analyze:e=!1,verbose:t=!1,settings:n=!1,buffers:r=!1,wal:s=!1,format:i="text"}={}){var o;const a=[e?"analyze":null,t?"verbose":null,n?"settings":null,r?"buffers":null,s?"wal":null].filter(Boolean).join("|"),l=(o=this.headers.get("Accept"))!==null&&o!==void 0?o:"application/json";return this.headers.set("Accept",`application/vnd.pgrst.plan+${i}; for="${l}"; options=${a};`),i==="json"?this:this}rollback(){return this.headers.append("Prefer","tx=rollback"),this}returns(){return this}maxAffected(e){return this.headers.append("Prefer","handling=strict"),this.headers.append("Prefer",`max-affected=${e}`),this}};const sv=new RegExp("[,()]");var Ds=class extends $I{eq(e,t){return this.url.searchParams.append(e,`eq.${t}`),this}neq(e,t){return this.url.searchParams.append(e,`neq.${t}`),this}gt(e,t){return this.url.searchParams.append(e,`gt.${t}`),this}gte(e,t){return this.url.searchParams.append(e,`gte.${t}`),this}lt(e,t){return this.url.searchParams.append(e,`lt.${t}`),this}lte(e,t){return this.url.searchParams.append(e,`lte.${t}`),this}like(e,t){return this.url.searchParams.append(e,`like.${t}`),this}likeAllOf(e,t){return this.url.searchParams.append(e,`like(all).{${t.join(",")}}`),this}likeAnyOf(e,t){return this.url.searchParams.append(e,`like(any).{${t.join(",")}}`),this}ilike(e,t){return this.url.searchParams.append(e,`ilike.${t}`),this}ilikeAllOf(e,t){return this.url.searchParams.append(e,`ilike(all).{${t.join(",")}}`),this}ilikeAnyOf(e,t){return this.url.searchParams.append(e,`ilike(any).{${t.join(",")}}`),this}regexMatch(e,t){return this.url.searchParams.append(e,`match.${t}`),this}regexIMatch(e,t){return this.url.searchParams.append(e,`imatch.${t}`),this}is(e,t){return this.url.searchParams.append(e,`is.${t}`),this}isDistinct(e,t){return this.url.searchParams.append(e,`isdistinct.${t}`),this}in(e,t){const n=Array.from(new Set(t)).map(r=>typeof r=="string"&&sv.test(r)?`"${r}"`:`${r}`).join(",");return this.url.searchParams.append(e,`in.(${n})`),this}notIn(e,t){const n=Array.from(new Set(t)).map(r=>typeof r=="string"&&sv.test(r)?`"${r}"`:`${r}`).join(",");return this.url.searchParams.append(e,`not.in.(${n})`),this}contains(e,t){return typeof t=="string"?this.url.searchParams.append(e,`cs.${t}`):Array.isArray(t)?this.url.searchParams.append(e,`cs.{${t.join(",")}}`):this.url.searchParams.append(e,`cs.${JSON.stringify(t)}`),this}containedBy(e,t){return typeof t=="string"?this.url.searchParams.append(e,`cd.${t}`):Array.isArray(t)?this.url.searchParams.append(e,`cd.{${t.join(",")}}`):this.url.searchParams.append(e,`cd.${JSON.stringify(t)}`),this}rangeGt(e,t){return this.url.searchParams.append(e,`sr.${t}`),this}rangeGte(e,t){return this.url.searchParams.append(e,`nxl.${t}`),this}rangeLt(e,t){return this.url.searchParams.append(e,`sl.${t}`),this}rangeLte(e,t){return this.url.searchParams.append(e,`nxr.${t}`),this}rangeAdjacent(e,t){return this.url.searchParams.append(e,`adj.${t}`),this}overlaps(e,t){return typeof t=="string"?this.url.searchParams.append(e,`ov.${t}`):this.url.searchParams.append(e,`ov.{${t.join(",")}}`),this}textSearch(e,t,{config:n,type:r}={}){let s="";r==="plain"?s="pl":r==="phrase"?s="ph":r==="websearch"&&(s="w");const i=n===void 0?"":`(${n})`;return this.url.searchParams.append(e,`${s}fts${i}.${t}`),this}match(e){return Object.entries(e).forEach(([t,n])=>{this.url.searchParams.append(t,`eq.${n}`)}),this}not(e,t,n){return this.url.searchParams.append(e,`not.${t}.${n}`),this}or(e,{foreignTable:t,referencedTable:n=t}={}){const r=n?`${n}.or`:"or";return this.url.searchParams.append(r,`(${e})`),this}filter(e,t,n){return this.url.searchParams.append(e,`${t}.${n}`),this}},VI=class{constructor(e,{headers:t={},schema:n,fetch:r}){this.url=e,this.headers=new Headers(t),this.schema=n,this.fetch=r}cloneRequestState(){return{url:new URL(this.url.toString()),headers:new Headers(this.headers)}}select(e,t){const{head:n=!1,count:r}=t??{},s=n?"HEAD":"GET";let i=!1;const o=(e??"*").split("").map(c=>/\s/.test(c)&&!i?"":(c==='"'&&(i=!i),c)).join(""),{url:a,headers:l}=this.cloneRequestState();return a.searchParams.set("select",o),r&&l.append("Prefer",`count=${r}`),new Ds({method:s,url:a,headers:l,schema:this.schema,fetch:this.fetch})}insert(e,{count:t,defaultToNull:n=!0}={}){var r;const s="POST",{url:i,headers:o}=this.cloneRequestState();if(t&&o.append("Prefer",`count=${t}`),n||o.append("Prefer","missing=default"),Array.isArray(e)){const a=e.reduce((l,c)=>l.concat(Object.keys(c)),[]);if(a.length>
2160){const l=[...new Set(a)].map(c=>`"${c}"`);i.searchParams.set("columns",l.join(","))}}return new Ds({method:s,url:i,headers:o,schema:this.schema,body:e,fetch:(r=this.fetch)!==null&&r!==void 0?r:fetch})}upsert(e,{onConflict:t,ignoreDuplicates:n=!1,count:r,defaultToNull:s=!0}={}){var i;const o="POST",{url:a,headers:l}=this.cloneRequestState();if(l.append("Prefer",`resolution=${n?"ignore":"merge"}-duplicates`),t!==void 0&&a.searchParams.set("on_conflict",t),r&&l.append("Prefer",`count=${r}`),s||l.append("Prefer","missing=default"),Array.isArray(e)){const c=e.reduce((u,d)=>u.concat(Object.keys(d)),[]);if(c.length>0){const u=[...new Set(c)].map(d=>`"${d}"`);a.searchParams.set("columns",u.join(","))}}return new Ds({method:o,url:a,headers:l,schema:this.schema,body:e,fetch:(i=this.fetch)!==null&&i!==void 0?i:fetch})}update(e,{count:t}={}){var n;const r="PATCH",{url:s,headers:i}=this.cloneRequestState();return t&&i.append("Prefer",`count=${t}`),new Ds({method:r,url:s,headers:i,schema:this.schema,body:e,fetch:(n=this.fetch)!==null&&n!==void 0?n:fetch})}delete({count:e}={}){var t;const n="DELETE",{url:r,headers:s}=this.cloneRequestState();return e&&s.append("Prefer",`count=${e}`),new Ds({method:n,url:r,headers:s,schema:this.schema,fetch:(t=this.fetch)!==null&&t!==void 0?t:fetch})}},FI=class ES{constructor(t,{headers:n={},schema:r,fetch:s}={}){this.url=t,this.headers=new Headers(n),this.schemaName=r,this.fetch=s}from(t){if(!t||typeof t!="string"||t.trim()==="")throw new Error("Invalid relation name: relation must be a non-empty string.");return new VI(new URL(`${this.url}/${t}`),{headers:new Headers(this.headers),schema:this.schemaName,fetch:this.fetch})}schema(t){return new ES(this.url,{headers:this.headers,schema:t,fetch:this.fetch})}rpc(t,n={},{head:r=!1,get:s=!1,count:i}={}){var o;let a;const l=new URL(`${this.url}/rpc/${t}`);let c;const u=f=>f!==null&&typeof f=="object"&&(!Array.isArray(f)||f.some(u)),d=r&&Object.values(n).some(u);d?(a="POST",c=n):r||s?(a=r?"HEAD":"GET",Object.entries(n).filter(([f,w])=>w!==void 0).map(([f,w])=>[f,Array.isArray(w)?`{${w.join(",")}}`:`${w}`]).forEach(([f,w])=>{l.searchParams.append(f,w)})):(a="POST",c=n);const h=new Headers(this.headers);return d?h.set("Prefer",i?`count=${i},return=minimal`:"return=minimal"):i&&h.set("Prefer",`count=${i}`),new Ds({method:a,url:l,headers:h,schema:this.schemaName,body:c,fetch:(o=this.fetch)!==null&&o!==void 0?o:fetch})}};class UI{constructor(){}static detectEnvironment(){var t;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"&&(!((t=navigator.userAgent)===null||t===void 0)&&t.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 s=r.node,i=parseInt(s.replace(/^v/,"").split(".")[0]);return i>=22?typeof globalThis.WebSocket<"u"?{type:"native",constructor:globalThis.WebSocket}:{type:"unsupported",error:`Node.js ${i} detected but native WebSocket not found.`,workaround:"Provide a WebSocket implementation via the transport option."}:{type:"unsupported",error:`Node.js ${i} detected without native WebSocket support.`,workaround:`For Node.js < 22, install "ws" package and provide it via the transport option: 217import ws from "ws" 218new 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 t=this.detectEnvironment();if(t.constructor)return t.constructor;let n=t.error||"WebSocket not supported in this environment.";throw t.workaround&&(n+=` 219 220Suggested solution: ${t.workaround}`),new Error(n)}static createWebSocket(t,n){const r=this.getWebSocketConstructor();return new r(t,n)}static isWebSocketSupported(){try{const t=this.detectEnvironment();return t.type==="native"||t.type==="ws"}catch{return!1}}}const BI="2.93.2",zI=`realtime-js/${BI}`,WI="1.0.0",TS="2.0.0",iv=TS,Dh=1e4,HI=1e3,KI=100;var tr;(function(e){e[e.connecting=0]="connecting",e[e.open=1]="open",e[e.closing=2]="closing",e[e.closed=3]="closed"})(tr||(tr={}));var Ie;(function(e){e.closed="closed",e.errored="errored",e.joined="joined",e.joining="joining",e.leaving="leaving"})(Ie||(Ie={}));var Jt;(function(e){e.close="phx_close",e.error="phx_error",e.join="phx_join",e.reply="phx_reply",e.leave="phx_leave",e.access_token="access_token"})(Jt||(Jt={}));var Lh;(function(e){e.websocket="websocket"})(Lh||(Lh={}));var Kr;(function(e){e.Connecting="connecting",e.Open="open",e.Closing="closing",e.Closed="closed"})(Kr||(Kr={}));class qI{constructor(t){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=t??[]}encode(t,n){if(t.event===this.BROADCAST_EVENT&&!(t.payload instanceof ArrayBuffer)&&typeof t.payload.event=="string")return n(this._binaryEncodeUserBroadcastPush(t));let r=[t.join_ref,t.ref,t.topic,t.event,t.payload];return n(JSON.stringify(r))}_binaryEncodeUserBroadcastPush(t){var n;return this._isArrayBuffer((n=t.payload)===null||n===void 0?void 0:n.payload)?this._encodeBinaryUserBroadcastPush(t):this._encodeJsonUserBroadcastPush(t)}_encodeBinaryUserBroadcastPush(t){var n,r;const s=(r=(n=t.payload)===null||n===void 0?void 0:n.payload)!==null&&r!==void 0?r:new ArrayBuffer(0);return this._encodeUserBroadcastPush(t,this.BINARY_ENCODING,s)}_encodeJsonUserBroadcastPush(t){var n,r;const s=(r=(n=t.payload)===null||n===void 0?void 0:n.payload)!==null&&r!==void 0?r:{},o=new TextEncoder().encode(JSON.stringify(s)).buffer;return this._encodeUserBroadcastPush(t,this.JSON_ENCODING,o)}_encodeUserBroadcastPush(t,n,r){var s,i;const o=t.topic,a=(s=t.ref)!==null&&s!==void 0?s:"",l=(i=t.join_ref)!==null&&i!==void 0?i:"",c=t.payload.event,u=this.allowedMetadataKeys?this._pick(t.payload,this.allowedMetadataKeys):{},d=Object.keys(u).length===0?"":JSON.stringify(u);if(l.length>255)throw new Error(`joinRef length ${l.length} exceeds maximum of 255`);if(a.length>255)throw new Error(`ref length ${a.length} exceeds maximum of 255`);if(o.length>255)throw new Error(`topic length ${o.length} exceeds maximum of 255`);if(c.length>255)throw new Error(`userEvent length ${c.length} exceeds maximum of 255`);if(d.length>255)throw new Error(`metadata length ${d.length} exceeds maximum of 255`);const h=this.USER_BROADCAST_PUSH_META_LENGTH+l.length+a.length+o.length+c.length+d.length,f=new ArrayBuffer(this.HEADER_LENGTH+h);let w=new DataView(f),y=0;w.setUint8(y++,this.KINDS.userBroadcastPush),w.setUint8(y++,l.length),w.setUint8(y++,a.length),w.setUint8(y++,o.length),w.setUint8(y++,c.length),w.setUint8(y++,d.length),w.setUint8(y++,n),Array.from(l,m=>w.setUint8(y++,m.charCodeAt(0))),Array.from(a,m=>w.setUint8(y++,m.charCodeAt(0))),Array.from(o,m=>w.setUint8(y++,m.charCodeAt(0))),Array.from(c,m=>w.setUint8(y++,m.charCodeAt(0))),Array.from(d,m=>w.setUint8(y++,m.charCodeAt(0)));var x=new Uint8Array(f.byteLength+r.byteLength);return x.set(new Uint8Array(f),0),x.set(new Uint8Array(r),f.byteLength),x.buffer}decode(t,n){if(this._isArrayBuffer(t)){let r=this._binaryDecode(t);return n(r)}if(typeof t=="string"){const r=JSON.parse(t),[s,i,o,a,l]=r;
220return n({join_ref:s,ref:i,topic:o,event:a,payload:l})}return n({})}_binaryDecode(t){const n=new DataView(t),r=n.getUint8(0),s=new TextDecoder;switch(r){case this.KINDS.userBroadcast:return this._decodeUserBroadcast(t,n,s)}}_decodeUserBroadcast(t,n,r){const s=n.getUint8(1),i=n.getUint8(2),o=n.getUint8(3),a=n.getUint8(4);let l=this.HEADER_LENGTH+4;const c=r.decode(t.slice(l,l+s));l=l+s;const u=r.decode(t.slice(l,l+i));l=l+i;const d=r.decode(t.slice(l,l+o));l=l+o;const h=t.slice(l,t.byteLength),f=a===this.JSON_ENCODING?JSON.parse(r.decode(h)):h,w={type:this.BROADCAST_EVENT,event:u,payload:f};return o>0&&(w.meta=JSON.parse(d)),{join_ref:null,ref:null,topic:c,event:this.BROADCAST_EVENT,payload:w}}_isArrayBuffer(t){var n;return t instanceof ArrayBuffer||((n=t==null?void 0:t.constructor)===null||n===void 0?void 0:n.name)==="ArrayBuffer"}_pick(t,n){return!t||typeof t!="object"?{}:Object.fromEntries(Object.entries(t).filter(([r])=>n.includes(r)))}}class CS{constructor(t,n){this.callback=t,this.timerCalc=n,this.timer=void 0,this.tries=0,this.callback=t,this.timerCalc=n}reset(){this.tries=0,clearTimeout(this.timer),this.timer=void 0}scheduleTimeout(){clearTimeout(this.timer),this.timer=setTimeout(()=>{this.tries=this.tries+1,this.callback()},this.timerCalc(this.tries+1))}}var ae;(function(e){e.abstime="abstime",e.bool="bool",e.date="date",e.daterange="daterange",e.float4="float4",e.float8="float8",e.int2="int2",e.int4="int4",e.int4range="int4range",e.int8="int8",e.int8range="int8range",e.json="json",e.jsonb="jsonb",e.money="money",e.numeric="numeric",e.oid="oid",e.reltime="reltime",e.text="text",e.time="time",e.timestamp="timestamp",e.timestamptz="timestamptz",e.timetz="timetz",e.tsrange="tsrange",e.tstzrange="tstzrange"})(ae||(ae={}));const ov=(e,t,n={})=>{var r;const s=(r=n.skipTypes)!==null&&r!==void 0?r:[];return t?Object.keys(t).reduce((i,o)=>(i[o]=GI(o,e,t,s),i),{}):{}},GI=(e,t,n,r)=>{const s=t.find(a=>a.name===e),i=s==null?void 0:s.type,o=n[e];return i&&!r.includes(i)?PS(i,o):Mh(o)},PS=(e,t)=>{if(e.charAt(0)==="_"){const n=e.slice(1,e.length);return XI(t,n)}switch(e){case ae.bool:return YI(t);case ae.float4:case ae.float8:case ae.int2:case ae.int4:case ae.int8:case ae.numeric:case ae.oid:return QI(t);case ae.json:case ae.jsonb:return JI(t);case ae.timestamp:return ZI(t);case ae.abstime:case ae.date:case ae.daterange:case ae.int4range:case ae.int8range:case ae.money:case ae.reltime:case ae.text:case ae.time:case ae.timestamptz:case ae.timetz:case ae.tsrange:case ae.tstzrange:return Mh(t);default:return Mh(t)}},Mh=e=>e,YI=e=>{switch(e){case"t":return!0;case"f":return!1;default:return e}},QI=e=>{if(typeof e=="string"){const t=parseFloat(e);if(!Number.isNaN(t))return t}return e},JI=e=>{if(typeof e=="string")try{return JSON.parse(e)}catch{return e}return e},XI=(e,t)=>{if(typeof e!="string")return e;const n=e.length-1,r=e[n];if(e[0]==="{"&&r==="}"){let i;const o=e.slice(1,n);try{i=JSON.parse("["+o+"]")}catch{i=o?o.split(","):[]}return i.map(a=>PS(t,a))}return e},ZI=e=>typeof e=="string"?e.replace(" ","T"):e,AS=e=>{const t=new URL(e);return t.protocol=t.protocol.replace(/^ws/i,"http"),t.pathname=t.pathname.replace(/\/+$/,"").replace(/\/socket\/websocket$/i,"").replace(/\/socket$/i,"").replace(/\/websocket$/i,""),t.pathname===""||t.pathname==="/"?t.pathname="/api/broadcast":t.pathname=t.pathname+"/api/broadcast",t.href};class Qu{constructor(t,n,r={},s=Dh){this.channel=t,this.event=n,this.payload=r,this.timeout=s,this.sent=!1,this.timeoutTimer=void 0,this.ref="",this.receivedResp=null,this.recHooks=[],this.refEvent=null}resend(t){this.timeout=t,this._cancelRefEvent(),this.ref="",this.refEvent=null,this.receivedResp=null,this.sent=!1,this.send()}send(){this._hasReceived("timeout")||(this.startTimeout(),this.sent=!0,this.channel.socket.push({topic:this.channel.topic,event:this.event,payload:this.payload,ref:this.ref,join_ref:this.channel._joinRef()}))}updatePayload(t){this.payload=Object.assign(Object.assign({},this.payload),t)}receive(t,n){var r;return this._hasReceived(t)&&n((r=this.receivedResp)===null||r===void 0?void 0:r.response),this.recHo
220oks.push({status:t,callback:n}),this}startTimeout(){if(this.timeoutTimer)return;this.ref=this.channel.socket._makeRef(),this.refEvent=this.channel._replyEventName(this.ref);const t=n=>{this._cancelRefEvent(),this._cancelTimeout(),this.receivedResp=n,this._matchReceive(n)};this.channel._on(this.refEvent,{},t),this.timeoutTimer=setTimeout(()=>{this.trigger("timeout",{})},this.timeout)}trigger(t,n){this.refEvent&&this.channel._trigger(this.refEvent,{status:t,response:n})}destroy(){this._cancelRefEvent(),this._cancelTimeout()}_cancelRefEvent(){this.refEvent&&this.channel._off(this.refEvent,{})}_cancelTimeout(){clearTimeout(this.timeoutTimer),this.timeoutTimer=void 0}_matchReceive({status:t,response:n}){this.recHooks.filter(r=>r.status===t).forEach(r=>r.callback(n))}_hasReceived(t){return this.receivedResp&&this.receivedResp.status===t}}var av;(function(e){e.SYNC="sync",e.JOIN="join",e.LEAVE="leave"})(av||(av={}));class Eo{constructor(t,n){this.channel=t,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,{},s=>{const{onJoin:i,onLeave:o,onSync:a}=this.caller;this.joinRef=this.channel._joinRef(),this.state=Eo.syncState(this.state,s,i,o),this.pendingDiffs.forEach(l=>{this.state=Eo.syncDiff(this.state,l,i,o)}),this.pendingDiffs=[],a()}),this.channel._on(r.diff,{},s=>{const{onJoin:i,onLeave:o,onSync:a}=this.caller;this.inPendingSyncState()?this.pendingDiffs.push(s):(this.state=Eo.syncDiff(this.state,s,i,o),a())}),this.onJoin((s,i,o)=>{this.channel._trigger("presence",{event:"join",key:s,currentPresences:i,newPresences:o})}),this.onLeave((s,i,o)=>{this.channel._trigger("presence",{event:"leave",key:s,currentPresences:i,leftPresences:o})}),this.onSync(()=>{this.channel._trigger("presence",{event:"sync"})})}static syncState(t,n,r,s){const i=this.cloneDeep(t),o=this.transformState(n),a={},l={};return this.map(i,(c,u)=>{o[c]||(l[c]=u)}),this.map(o,(c,u)=>{const d=i[c];if(d){const h=u.map(x=>x.presence_ref),f=d.map(x=>x.presence_ref),w=u.filter(x=>f.indexOf(x.presence_ref)<0),y=d.filter(x=>h.indexOf(x.presence_ref)<0);w.length>0&&(a[c]=w),y.length>0&&(l[c]=y)}else a[c]=u}),this.syncDiff(i,{joins:a,leaves:l},r,s)}static syncDiff(t,n,r,s){const{joins:i,leaves:o}={joins:this.transformState(n.joins),leaves:this.transformState(n.leaves)};return r||(r=()=>{}),s||(s=()=>{}),this.map(i,(a,l)=>{var c;const u=(c=t[a])!==null&&c!==void 0?c:[];if(t[a]=this.cloneDeep(l),u.length>0){const d=t[a].map(f=>f.presence_ref),h=u.filter(f=>d.indexOf(f.presence_ref)<0);t[a].unshift(...h)}r(a,u,l)}),this.map(o,(a,l)=>{let c=t[a];if(!c)return;const u=l.map(d=>d.presence_ref);c=c.filter(d=>u.indexOf(d.presence_ref)<0),t[a]=c,s(a,c,l),c.length===0&&delete t[a]}),t}static map(t,n){return Object.getOwnPropertyNames(t).map(r=>n(r,t[r]))}static transformState(t){return t=this.cloneDeep(t),Object.getOwnPropertyNames(t).reduce((n,r)=>{const s=t[r];return"metas"in s?n[r]=s.metas.map(i=>(i.presence_ref=i.phx_ref,delete i.phx_ref,delete i.phx_ref_prev,i)):n[r]=s,n},{})}static cloneDeep(t){return JSON.parse(JSON.stringify(t))}onJoin(t){this.caller.onJoin=t}onLeave(t){this.caller.onLeave=t}onSync(t){this.caller.onSync=t}inPendingSyncState(){return!this.joinRef||this.joinRef!==this.channel._joinRef()}}var lv;(function(e){e.ALL="*",e.INSERT="INSERT",e.UPDATE="UPDATE",e.DELETE="DELETE"})(lv||(lv={}));var To;(function(e){e.BROADCAST="broadcast",e.PRESENCE="presence",e.POSTGRES_CHANGES="postgres_changes",e.SYSTEM="system"})(To||(To={}));var kn;(function(e){e.SUBSCRIBED="SUBSCRIBED",e.TIMED_OUT="TIMED_OUT",e.CLOSED="CLOSED",e.CHANNEL_ERROR="CHANNEL_ERROR"})(kn||(kn={}));class ti{constructor(t,n={config:{}},r){var s,i;if(this.topic=t,this.params=n,this.socket=r,this.bindings={},this.state=Ie.closed,this.joinedOnce=!1,this.pushBuffer=[],this.subTopic=t.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 Qu(this,Jt.join,this.params,this.timeout),this.rejoinTimer=new CS(()=>this._rejoinUntilConnected(),this.socket.reconnectAfterMs),this.joinPush.receive("ok",()=>{this.state=Ie.joined,this.rejoinTimer.reset(),this.pushBuffer.forEach(o=>o.send()),this.pushBuffer=[]}),this._onClose(()=>{this.rejoinTimer.reset(),this.socket.log("channel",`close ${this.topic} ${this._joinRef()}`),this.state=Ie.closed,this.socket._remove(this)}),this._onError(o=>{this._isLeaving()||this._isClosed()||(this.socket.log("channel",`error ${this.topic}`,o),this.state=Ie.errored,this.rejoinTimer.scheduleTimeout())}),this.joinPush.receive("timeout",()=>{this._isJoining()&&(this.socket.log("channel",`timeout ${this.topic}`,this.joinPush.timeout),this.state=Ie.errored,this.rejoinTimer.scheduleTimeout())}),this.joinPush.receive("error",o=>{this._isLeaving()||this._isClosed()||(this.socket.log("channel",`error ${this.topic}`,o),this.state=Ie.errored,this.rejoinTimer.scheduleTimeout())}),this._on(Jt.reply,{},(o,a)=>{this._trigger(this._replyEventName(a),o)}),this.presence=new Eo(this),this.broadcastEndpointURL=AS(this.socket.endPoint),this.private=this.params.config.private||!1,!this.private&&(!((i=(s=this.params.config)===null||s===void 0?void 0:s.broadcast)===null||i===void 0)&&i.replay))throw`tried to use replay on public channel '${this.topic}'. It must be a private channel.`}subscribe(t,n=this.timeout){var r,s,i;if(this.socket.isConnected()||this.socket.connect(),this.state==Ie.closed){const{config:{broadcast:o,presence:a,private:l}}=this.params,c=(s=(r=this.bindings.postgres_changes)===null||r===void 0?void 0:r.map(f=>f.filter))!==null&&s!==void 0?s:[],u=!!this.bindings[To.PRESENCE]&&this.bindings[To.PRESENCE].length>0||((i=this.params.config.presence)===null||i===void 0?void 0:i.enabled)===!0,d={},h={broadcast:o,presence:Object.assign(Object.assign({},a),{enabled:u}),postgres_changes:c,private:l};this.socket.accessTokenValue&&(d.access_token=this.socket.accessTokenValue),this._onError(f=>t==null?void 0:t(kn.CHANNEL_ERROR,f)),this._onClose(()=>t==null?void 0:t(kn.CLOSED)),this.updateJoinPayload(Object.assign({config:h},d)),this.joinedOnce=!0,this._rejoin(n),this.joinPush.receive("ok",async({postgres_changes:f})=>{var w;if(this.socket._isManualToken()||this.socket.setAuth(),f===void 0){t==null||t(kn.SUBSCRIBED);return}else{const y=this.bindings.postgres_changes,x=(w=y==null?void 0:y.length)!==null&&w!==void 0?w:0,m=[];for(let g=0;g<x;g++){const v=y[g],{filter:{event:S,schema:_,table:k,filter:E}}=v,T=f&&f[g];if(T&&T.event===S&&ti.isFilterValueEqual(T.schema,_)&&ti.isFilterValueEqual(T.table,k)&&ti.isFilterValueEqual(T.filter,E))m.push(Object.assign(Object.assign({},v),{id:T.id}));else{this.unsubscribe(),this.state=Ie.errored,t==null||t(kn.CHANNEL_ERROR,new Error("mismatch between server and client bindings for postgres changes"));return}}this.bindings.postgres_changes=m,t&&t(kn.SUBSCRIBED);return}}).receive("error",f=>{this.state=Ie.errored,t==null||t(kn.CHANNEL_ERROR,new Error(JSON.stringify(Object.values(f).join(", ")||"error")))}).receive("timeout",()=>{t==null||t(kn.TIMED_OUT)})}return this}presenceState(){return this.presence.state}async track(t,n={}){return await this.send({type:"presence",event:"track",payload:t},n.timeout||this.timeout)}async untrack(t={}){return await this.send({type:"presence",event:"untrack"},t)}on(t,n,r){return this.state===Ie.joined&&t===To.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(t,n,r)}async httpSend(t,n,r={}){var s;if(n==null)return Promise.reject("Payload is required for httpSend()");const i={apikey:this.socket.apiKey?this.socket.apiKey:"","Content-Type":"application/json"};this.socket.accessTokenValue&&(i.Authorization=`Bearer ${this.socket.accessTokenValue}`);const o={method:"POST",headers:i,body:JSON.stringify({messages:[{topic:this.subTopic,event:t,payload:n,private:this.private}]})},a=await this._fetchWithTimeout(this.broadcastEndpointURL,o,(s=r.timeout)!==null&&s!==void 0?s:this.timeout);if(a.status===202)return{success:!0};let l=a.statusText;
220try{const c=await a.json();l=c.error||c.message||l}catch{}return Promise.reject(new Error(l))}async send(t,n={}){var r,s;if(!this._canPush()&&t.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:i,payload:o}=t,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:i,payload:o,private:this.private}]})};try{const c=await this._fetchWithTimeout(this.broadcastEndpointURL,l,(r=n.timeout)!==null&&r!==void 0?r:this.timeout);return await((s=c.body)===null||s===void 0?void 0:s.cancel()),c.ok?"ok":"error"}catch(c){return c.name==="AbortError"?"timed out":"error"}}else return new Promise(i=>{var o,a,l;const c=this._push(t.type,t,n.timeout||this.timeout);t.type==="broadcast"&&!(!((l=(a=(o=this.params)===null||o===void 0?void 0:o.config)===null||a===void 0?void 0:a.broadcast)===null||l===void 0)&&l.ack)&&i("ok"),c.receive("ok",()=>i("ok")),c.receive("error",()=>i("error")),c.receive("timeout",()=>i("timed out"))})}updateJoinPayload(t){this.joinPush.updatePayload(t)}unsubscribe(t=this.timeout){this.state=Ie.leaving;const n=()=>{this.socket.log("channel",`leave ${this.topic}`),this._trigger(Jt.close,"leave",this._joinRef())};this.joinPush.destroy();let r=null;return new Promise(s=>{r=new Qu(this,Jt.leave,{},t),r.receive("ok",()=>{n(),s("ok")}).receive("timeout",()=>{n(),s("timed out")}).receive("error",()=>{s("error")}),r.send(),this._canPush()||r.trigger("ok",{})}).finally(()=>{r==null||r.destroy()})}teardown(){this.pushBuffer.forEach(t=>t.destroy()),this.pushBuffer=[],this.rejoinTimer.reset(),this.joinPush.destroy(),this.state=Ie.closed,this.bindings={}}async _fetchWithTimeout(t,n,r){const s=new AbortController,i=setTimeout(()=>s.abort(),r),o=await this.socket.fetch(t,Object.assign(Object.assign({},n),{signal:s.signal}));return clearTimeout(i),o}_push(t,n,r=this.timeout){if(!this.joinedOnce)throw`tried to push '${t}' to '${this.topic}' before joining. Use channel.subscribe() before pushing events`;let s=new Qu(this,t,n,r);return this._canPush()?s.send():this._addToPushBuffer(s),s}_addToPushBuffer(t){if(t.startTimeout(),this.pushBuffer.push(t),this.pushBuffer.length>KI){const n=this.pushBuffer.shift();n&&(n.destroy(),this.socket.log("channel",`discarded push due to buffer overflow: ${n.event}`,n.payload))}}_onMessage(t,n,r){return n}_isMember(t){return this.topic===t}_joinRef(){return this.joinPush.ref}_trigger(t,n,r){var s,i;const o=t.toLocaleLowerCase(),{close:a,error:l,leave:c,join:u}=Jt;if(r&&[a,l,c,u].indexOf(o)>=0&&r!==this._joinRef())return;let h=this._onMessage(o,n,r);if(n&&!h)throw"channel onMessage callbacks must return the payload, modified or unmodified";["insert","update","delete"].includes(o)?(s=this.bindings.postgres_changes)===null||s===void 0||s.filter(f=>{var w,y,x;return((w=f.filter)===null||w===void 0?void 0:w.event)==="*"||((x=(y=f.filter)===null||y===void 0?void 0:y.event)===null||x===void 0?void 0:x.toLocaleLowerCase())===o}).map(f=>f.callback(h,r)):(i=this.bindings[o])===null||i===void 0||i.filter(f=>{var w,y,x,m,g,v;if(["broadcast","presence","postgres_changes"].includes(o))if("id"in f){const S=f.id,_=(w=f.filter)===null||w===void 0?void 0:w.event;return S&&((y=n.ids)===null||y===void 0?void 0:y.includes(S))&&(_==="*"||(_==null?void 0:_.toLocaleLowerCase())===((x=n.data)===null||x===void 0?void 0:x.type.toLocaleLowerCase()))}else{const S=(g=(m=f==null?void 0:f.filter)===null||m===void 0?void 0:m.event)===null||g===void 0?void 0:g.toLocaleLowerCase();return S==="*"||S===((v=n==null?void 0:n.event)===null||v===void 0?void 0:v.toLocaleLowerCase())}else return f.type.toLocaleLowerCase()===o}).map(f=>{if(typeof h=="object"&&"ids"in h){const w=h.data,{schema:y,table:x,commit_timestamp:m,type:g,errors:v}=w;h=Object.assign(Object.assign({},{schema:y,table:x,commit_timestamp:m,eventType:g,new:{},old:{},errors:v}),this._getPayloadRecords(w))}f.callback(h,r)})}_isClosed(){return this.state===Ie.closed}_isJoined(){return this.state===Ie.joined}_isJoining(){return this.state===Ie.joining}_isLeaving(){return this.state===Ie.leaving}_replyEventName(t){return`chan_reply_${t}`}_on(t,n,r){const s=t.toLocaleLowerCase(),i={type:s,filter:n,callback:r};return this.bindings[s]?this.bindings[s].push(i):this.bindings[s]=[i],this}_off(t,n){const r=t.toLocaleLowerCase();return this.bindings[r]&&(this.bindings[r]=this.bindings[r].filter(s=>{var i;return!(((i=s.type)===null||i===void 0?void 0:i.toLocaleLowerCase())===r&&ti.isEqual(s.filter,n))})),this}static isEqual(t,n){if(Object.keys(t).length!==Object.keys(n).length)return!1;for(const r in t)if(t[r]!==n[r])return!1;return!0}static isFilterValueEqual(t,n){return(t??void 0)===(n??void 0)}_rejoinUntilConnected(){this.rejoinTimer.scheduleTimeout(),this.socket.isConnected()&&this._rejoin()}_onClose(t){this._on(Jt.close,{},t)}_onError(t){this._on(Jt.error,{},n=>t(n))}_canPush(){return this.socket.isConnected()&&this._isJoined()}_rejoin(t=this.timeout){this._isLeaving()||(this.socket._leaveOpenTopic(this.topic),this.state=Ie.joining,this.joinPush.resend(t))}_getPayloadRecords(t){const n={new:{},old:{}};return(t.type==="INSERT"||t.type==="UPDATE")&&(n.new=ov(t.columns,t.record)),(t.type==="UPDATE"||t.type==="DELETE")&&(n.old=ov(t.columns,t.old_record)),n}}const Ju=()=>{},el={HEARTBEAT_INTERVAL:25e3,RECONNECT_DELAY:10,HEARTBEAT_TIMEOUT_FALLBACK:100},eD=[1e3,2e3,5e3,1e4],tD=1e4,nD=` 221 addEventListener("message", (e) => { 222 if (e.data.event === "start") { 223 setInterval(() => postMessage({ event: "keepAlive" }), e.data.interval); 224 } 225 });`;class rD{constructor(t,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={},this.timeout=Dh,this.transport=null,this.heartbeatIntervalMs=el.HEARTBEAT_INTERVAL,this.heartbeatTimer=void 0,this.pendingHeartbeatRef=null,this.heartbeatCallback=Ju,this.ref=0,this.reconnectTimer=null,this.vsn=iv,this.logger=Ju,this.conn=null,this.sendBuffer=[],this.serializer
225=new qI,this.stateChangeCallbacks={open:[],close:[],error:[],message:[]},this.accessToken=null,this._connectionState="disconnected",this._wasManualDisconnect=!1,this._authPromise=null,this._heartbeatSentAt=null,this._resolveFetch=s=>s?(...i)=>s(...i):(...i)=>fetch(...i),!(!((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=`${t}/${Lh.websocket}`,this.httpEndpoint=AS(t),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=UI.createWebSocket(this.endpointURL())}catch(t){this._setConnectionState("disconnected");const n=t.message;throw n.includes("Node.js")?new Error(`${n} 226 227To use Realtime in Node.js, you need to provide a WebSocket implementation: 228 229Option 1: Use Node.js 22+ which has native WebSocket support 230Option 2: Install and provide the "ws" package: 231 232 npm install ws 233 234 import ws from "ws" 235 const client = new RealtimeClient(url, { 236 ...options, 237 transport: ws 238 })`):new Error(`WebSocket not available: ${n}`)}this._setupConnectionHandlers()}}endpointURL(){return this._appendParams(this.endPoint,Object.assign({},this.params,{vsn:this.vsn}))}disconnect(t,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"&&(t?this.conn.close(t,n??""):this.conn.close()),this._teardownConnection()}else this._setConnectionState("disconnected")}getChannels(){return this.channels}async removeChannel(t){const n=await t.unsubscribe();return this.channels.length===0&&this.disconnect(),n}async removeAllChannels(){const t=await Promise.all(this.channels.map(n=>n.unsubscribe()));return this.channels=[],this.disconnect(),t}log(t,n,r){this.logger(t,n,r)}connectionState(){switch(this.conn&&this.conn.readyState){case tr.connecting:return Kr.Connecting;case tr.open:return Kr.Open;case tr.closing:return Kr.Closing;default:return Kr.Closed}}isConnected(){return this.connectionState()===Kr.Open}isConnecting(){return this._connectionState==="connecting"}isDisconnecting(){return this._connectionState==="disconnecting"}channel(t,n={config:{}}){const r=`realtime:${t}`,s=this.getChannels().find(i=>i.topic===r);if(s)return s;{const i=new ti(`realtime:${t}`,n,this);return this.channels.push(i),i}}push(t){const{topic:n,event:r,payload:s,ref:i}=t,o=()=>{this.encode(t,a=>{var l;(l=this.conn)===null||l===void 0||l.send(a)})};this.log("push",`${n} ${r} (${i})`,s),this.isConnected()?o():this.sendBuffer.push(o)}async setAuth(t=null){this._authPromise=this._performAuth(t);try{await this._authPromise}finally{this._authPromise=null}}_isManualToken(){return this._manuallySetToken}async sendHeartbeat(){var t;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,(t=this.conn)===null||t===void 0||t.close(HI,"heartbeat timeout"),setTimeout(()=>{var n;this.isConnected()||(n=this.reconnectTimer)===null||n===void 0||n.scheduleTimeout()},el.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(t){this.heartbeatCallback=t}flushSendBuffer(){this.isConnected()&&this.sendBuffer.length>0&&(this.sendBuffer.forEach(t=>t()),this.sendBuffer=[])}_makeRef(){let t=this.ref+1;return t===this.ref?this.ref=0:this.ref=t,this.ref.toString()}_leaveOpenTopic(t){let n=this.channels.find(r=>r.topic===t&&(r._isJoined()||r._isJoining()));n&&(this.log("transport",`leaving duplicate topic "${t}"`),n.unsubscribe())}_remove(t){this.channels=this.channels.filter(n=>n.topic!==t.topic)}_onConnMessage(t){this.decode(t.data,n=>
238{if(n.topic==="phoenix"&&n.event==="phx_reply"&&n.ref&&n.ref===this.pendingHeartbeatRef){const c=this._heartbeatSentAt?Date.now()-this._heartbeatSentAt:void 0;try{this.heartbeatCallback(n.payload.status==="ok"?"ok":"error",c)}catch(u){this.log("error","error in heartbeat callback",u)}this._heartbeatSentAt=null,this.pendingHeartbeatRef=null}const{topic:r,event:s,payload:i,ref:o}=n,a=o?`(${o})`:"",l=i.status||"";this.log("receive",`${l} ${r} ${s} ${a}`.trim(),i),this.channels.filter(c=>c._isMember(r)).forEach(c=>c._trigger(s,i,o)),this._triggerStateCallbacks("message",n)})}_clearTimer(t){var n;t==="heartbeat"&&this.heartbeatTimer?(clearInterval(this.heartbeatTimer),this.heartbeatTimer=void 0):t==="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=t=>this._onConnError(t),this.conn.onmessage=t=>this._onConnMessage(t),this.conn.onclose=t=>this._onConnClose(t),this.conn.readyState===tr.open&&this._onConnOpen())}_teardownConnection(){if(this.conn){if(this.conn.readyState===tr.open||this.conn.readyState===tr.connecting)try{this.conn.close()}catch(t){this.log("error","Error closing connection",t)}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(t=>t.teardown())}_onConnOpen(){this._setConnectionState("connected"),this.log("transport",`connected to ${this.endpointURL()}`),(this._authPromise||(this.accessToken&&!this.accessTokenValue?this.setAuth():Promise.resolve())).then(()=>{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 t=this._workerObjectUrl(this.workerUrl);this.workerRef=new Worker(t),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(t){var n;this._setConnectionState("disconnected"),this.log("transport","close",t),this._triggerChanError(),this._clearTimer("heartbeat"),this._wasManualDisconnect||(n=this.reconnectTimer)===null||n===void 0||n.scheduleTimeout(),this._triggerStateCallbacks("close",t)}_onConnError(t){this._setConnectionState("disconnected"),this.log("transport",`${t}`),this._triggerChanError(),this._triggerStateCallbacks("error",t);try{this.heartbeatCallback("error")}catch(n){this.log("error","error in heartbeat callback",n)}}_triggerChanError(){this.channels.forEach(t=>t._trigger(Jt.error))}_appendParams(t,n){if(Object.keys(n).length===0)return t;const r=t.match(/\?/)?"&":"?",s=new URLSearchParams(n);return`${t}${r}${s}`}_workerObjectUrl(t){let n;if(t)n=t;else{const r=new Blob([nD],{type:"application/javascript"});n=URL.createObjectURL(r)}return n}_setConnectionState(t,n=!1){this._connectionState=t,t==="connecting"?this._wasManualDisconnect=!1:t==="disconnecting"&&(this._wasManualDisconnect=n)}async _performAuth(t=null){let n,r=!1;if(t)n=t,r=!0;else if(this.accessToken)try{n=await this.accessToken()}catch(s){this.log("error","Error fetching access token from callback",s),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
238h(s=>{const i={access_token:n,version:zI};n&&s.updateJoinPayload(i),s.joinedOnce&&s._isJoined()&&s._push(Jt.access_token,{access_token:n})}))}async _waitForAuthIfNeeded(){this._authPromise&&await this._authPromise}_setAuthSafely(t="general"){this._isManualToken()||this.setAuth().catch(n=>{this.log("error",`Error setting auth in ${t}`,n)})}_triggerStateCallbacks(t,n){try{this.stateChangeCallbacks[t].forEach(r=>{try{r(n)}catch(s){this.log("error",`error in ${t} callback`,s)}})}catch(r){this.log("error",`error triggering ${t} callbacks`,r)}}_setupReconnectionTimer(){this.reconnectTimer=new CS(async()=>{setTimeout(async()=>{await this._waitForAuthIfNeeded(),this.isConnected()||this.connect()},el.RECONNECT_DELAY)},this.reconnectAfterMs)}_initializeOptions(t){var n,r,s,i,o,a,l,c,u,d,h,f;switch(this.transport=(n=t==null?void 0:t.transport)!==null&&n!==void 0?n:null,this.timeout=(r=t==null?void 0:t.timeout)!==null&&r!==void 0?r:Dh,this.heartbeatIntervalMs=(s=t==null?void 0:t.heartbeatIntervalMs)!==null&&s!==void 0?s:el.HEARTBEAT_INTERVAL,this.worker=(i=t==null?void 0:t.worker)!==null&&i!==void 0?i:!1,this.accessToken=(o=t==null?void 0:t.accessToken)!==null&&o!==void 0?o:null,this.heartbeatCallback=(a=t==null?void 0:t.heartbeatCallback)!==null&&a!==void 0?a:Ju,this.vsn=(l=t==null?void 0:t.vsn)!==null&&l!==void 0?l:iv,t!=null&&t.params&&(this.params=t.params),t!=null&&t.logger&&(this.logger=t.logger),(t!=null&&t.logLevel||t!=null&&t.log_level)&&(this.logLevel=t.logLevel||t.log_level,this.params=Object.assign(Object.assign({},this.params),{log_level:this.logLevel})),this.reconnectAfterMs=(c=t==null?void 0:t.reconnectAfterMs)!==null&&c!==void 0?c:w=>eD[w-1]||tD,this.vsn){case WI:this.encode=(u=t==null?void 0:t.encode)!==null&&u!==void 0?u:(w,y)=>y(JSON.stringify(w)),this.decode=(d=t==null?void 0:t.decode)!==null&&d!==void 0?d:(w,y)=>y(JSON.parse(w));break;case TS:this.encode=(h=t==null?void 0:t.encode)!==null&&h!==void 0?h:this.serializer.encode.bind(this.serializer),this.decode=(f=t==null?void 0:t.decode)!==null&&f!==void 0?f: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=t==null?void 0:t.workerUrl}}}var ta=class extends Error{constructor(e,t){var n;super(e),this.name="IcebergError",this.status=t.status,this.icebergType=t.icebergType,this.icebergCode=t.icebergCode,this.details=t.details,this.isCommitStateUnknown=t.icebergType==="CommitStateUnknownException"||[500,502,504].includes(t.status)&&((n=t.icebergType)==null?void 0:n.includes("CommitState"))===!0}isNotFound(){return this.status===404}isConflict(){return this.status===409}isAuthenticationTimeout(){return this.status===419}};function sD(e,t,n){const r=new URL(t,e);if(n)for(const[s,i]of Object.entries(n))i!==void 0&&r.searchParams.set(s,i);return r.toString()}async function iD(e){return!e||e.type==="none"?{}:e.type==="bearer"?{Authorization:`Bearer ${e.token}`}:e.type==="header"?{[e.name]:e.value}:e.type==="custom"?await e.getHeaders():{}}function oD(e){const t=e.fetchImpl??globalThis.fetch;return{async request({method:n,path:r,query:s,body:i,headers:o}){const a=sD(e.baseUrl,r,s),l=await iD(e.auth),c=await t(a,{method:n,headers:{...i?{"Content-Type":"application/json"}:{},...l,...o},body:i?JSON.stringify(i):void 0}),u=await c.text(),d=(c.headers.get("content-type")||"").includes("application/json"),h=d&&u?JSON.parse(u):u;if(!c.ok){const f=d?h:void 0,w=f==null?void 0:f.error;throw new ta((w==null?void 0:w.message)??`Request failed with status ${c.status}`,{status:c.status,icebergType:w==null?void 0:w.type,icebergCode:w==null?void 0:w.code,details:f})}return{status:c.status,headers:c.headers,data:h}}}}function tl(e){return e.join("�")}var aD=class{constructor(e,t=""){this.client=e,this.prefix=t}async listNamespaces(e){const t=e?{parent:tl(e.namespace)}:void 0;return(await this.client.request({method:"GET",path:`${this.prefix}/namespaces`,query:t})).data.namespaces.map(r=>({namespace:r}))}async createNamespace(e,t){const n={namespace:e.namespace,properties:t==null?void 0:t.properties};return(await this.client.request({method:"POST",path:`${this.prefix}/namespaces`,body:n})).data}async dropNamespace(e){await this.client.request({method:"DELETE",path:`${this.prefix}/namespaces/${tl(e.namespace)}`})}async loadNamespaceMetadata(e){return{properties:(await this.client.request({method:"GET",path:`${this.prefix}/namespaces/${tl(e.namespace)}`})).data.properties}}async namespaceExists(e){try{return await this.client.request({method:"HEAD",path:`${this.prefix}/namespaces/${tl(e.namespace)}`}),!0}catch(t){if(t instanceof ta&&t.status===404)return!1;throw t}}async createNamespaceIfNotExists(e,t){try{return await this.createNamespace(e,t)}catch(n){if(n instanceof ta&&n.status===409)return;throw n}}};function Cs(e){return e.join("�")}var lD=class{constructor(e,t="",n){this.client=e,this.prefix=t,this.accessDelegation=n}async listTables(e){return(await this.client.request({method:"GET",path:`${this.prefix}/namespaces/${Cs(e.namespace)}/tables`})).data.identifiers}async createTable(e,t){const n={};return this.accessDelegation&&(n["X-Iceberg-Access-Delegation"]=this.accessDelegation),(await this.client.request({method:"POST",path:`${this.prefix}/namespaces/${Cs(e.namespace)}/tables`,body:t,headers:n})).data.metadata}async updateTable(e,t){const n=await this.client.request({method:"POST",path:`${this.prefix}/namespaces/${Cs(e.namespace)}/tables/${e.name}`,body:t});return{"metadata-location":n.data["metadata-location"],metadata:n.data.metadata}}async dropTable(e,t){await this.client.request({method:"DELETE",path:`${this.prefix}/namespaces/${Cs(e.namespace)}/tables/${e.name}`,query:{purgeRequested:String((t==null?void 0:t.purge)??!1)}})}async loadTable(e){const t={};return this.accessDelegation&&(t["X-Iceberg-Access-Delegation"]=this.accessDelegation),(await this.client.request({method:"GET",path:`${this.prefix}/namespaces/${Cs(e.namespace)}/tables/${e.name}`,headers:t})).data.metadata}async tableExists(e){const t={};this.accessDelegation&&(t["X-Iceberg-Access-Delegation"]=this.accessDelegation);try{return await this.client.request({method:"HEAD",path:`${this.prefix}/namespaces/${Cs(e.namespace)}/tables/${e.name}`,headers:t}),!0}catch(n){if(n instanceof ta&&n.status===404)return!1;throw n}}async createTableIfNotExists(e,t){try{return await this.createTable(e,t)}catch(n){if(n instanceof ta&&n.status===409)return await this.loadTable({namespace:e.namespace,name:t.name});throw n}}},cD=class{constructor(e){var r;let t="v1";e.catalogName&&(t+=`/${e.catalogName}`);const n=e.baseUrl.endsWith("/")?e.baseUrl:`${e.baseUrl}/`;this.client=oD({baseUrl:n,auth:e.auth,fetchImpl:e.fetch}),this.accessDelegation=(r=e.accessDelegation)==null?void 0:r.join(","),this.namespaceOps=new aD(this.client,t),this.tableOps=new lD(this.client,t,this.accessDelegation)}async listNamespaces(e){return this.namespaceOps.listNamespaces(e)}async createNamespace(e,t){return this.namespaceOps.createNamespace(e,t)}async dropNamespace(e){await this.namespaceOps.dropNamespace(e)}async loadNamespaceMetadata(e){return this.namespaceOps.loadNamespaceMetadata(e)}async listTables(e){return this.tableOps.listTables(e)}
238async createTable(e,t){return this.tableOps.createTable(e,t)}async updateTable(e,t){return this.tableOps.updateTable(e,t)}async dropTable(e,t){await this.tableOps.dropTable(e,t)}async loadTable(e){return this.tableOps.loadTable(e)}async namespaceExists(e){return this.namespaceOps.namespaceExists(e)}async tableExists(e){return this.tableOps.tableExists(e)}async createNamespaceIfNotExists(e,t){return this.namespaceOps.createNamespaceIfNotExists(e,t)}async createTableIfNotExists(e,t){return this.tableOps.createTableIfNotExists(e,t)}},qc=class extends Error{constructor(e,t="storage",n,r){super(e),this.__isStorageError=!0,this.namespace=t,this.name=t==="vectors"?"StorageVectorsError":"StorageError",this.status=n,this.statusCode=r}};function Gc(e){return typeof e=="object"&&e!==null&&"__isStorageError"in e}var nl=class extends qc{constructor(e,t,n,r="storage"){super(e,r,t,n),this.name=r==="vectors"?"StorageVectorsApiError":"StorageApiError",this.status=t,this.statusCode=n}toJSON(){return{name:this.name,message:this.message,status:this.status,statusCode:this.statusCode}}},RS=class extends qc{constructor(e,t,n="storage"){super(e,n),this.name=n==="vectors"?"StorageVectorsUnknownError":"StorageUnknownError",this.originalError=t}};const uD=e=>e?(...t)=>e(...t):(...t)=>fetch(...t),dD=e=>{if(typeof e!="object"||e===null)return!1;const t=Object.getPrototypeOf(e);return(t===null||t===Object.prototype||Object.getPrototypeOf(t)===null)&&!(Symbol.toStringTag in e)&&!(Symbol.iterator in e)},$h=e=>{if(Array.isArray(e))return e.map(n=>$h(n));if(typeof e=="function"||e!==Object(e))return e;const t={};return Object.entries(e).forEach(([n,r])=>{const s=n.replace(/([-_][a-z])/gi,i=>i.toUpperCase().replace(/[-_]/g,""));t[s]=$h(r)}),t},hD=e=>!e||typeof e!="string"||e.length===0||e.length>100||e.trim()!==e||e.includes("/")||e.includes("\\")?!1:/^[\w!.\*'() &$@=;:+,?-]+$/.test(e);function na(e){"@babel/helpers - typeof";return na=typeof Symbol=="function"&&typeof Symbol.iterator=="symbol"?function(t){return typeof t}:function(t){return t&&typeof Symbol=="function"&&t.constructor===Symbol&&t!==Symbol.prototype?"symbol":typeof t},na(e)}function fD(e,t){if(na(e)!="object"||!e)return e;var n=e[Symbol.toPrimitive];if(n!==void 0){var r=n.call(e,t||"default");if(na(r)!="object")return r;throw new TypeError("@@toPrimitive must return a primitive value.")}return(t==="string"?String:Number)(e)}function pD(e){var t=fD(e,"string");return na(t)=="symbol"?t:t+""}function mD(e,t,n){return(t=pD(t))in e?Object.defineProperty(e,t,{value:n,enumerable:!0,configurable:!0,writable:!0}):e[t]=n,e}function cv(e,t){var n=Object.keys(e);if(Object.getOwnPropertySymbols){var r=Object.getOwnPropertySymbols(e);t&&(r=r.filter(function(s){return Object.getOwnPropertyDescriptor(e,s).enumerable})),n.push.apply(n,r)}return n}function W(e){for(var t=1;t<arguments.length;t++){var n=arguments[t]!=null?arguments[t]:{};t%2?cv(Object(n),!0).forEach(function(r){mD(e,r,n[r])}):Object.getOwnPropertyDescriptors?Object.defineProperties(e,Object.getOwnPropertyDescriptors(n)):cv(Object(n)).forEach(function(r){Object.defineProperty(e,r,Object.getOwnPropertyDescriptor(n,r))})}return e}const uv=e=>{var t;return e.msg||e.message||e.error_description||(typeof e.error=="string"?e.error:(t=e.error)===null||t===void 0?void 0:t.message)||JSON.stringify(e)},gD=async(e,t,n,r)=>{if(e&&typeof e=="object"&&"status"in e&&"ok"in e&&typeof e.status=="number"&&!(n!=null&&n.noResolveJson)){const s=e,i=s.status||500;if(typeof s.json=="function")s.json().then(o=>{const a=(o==null?void 0:o.statusCode)||(o==null?void 0:o.code)||i+"";t(new nl(uv(o),i,a,r))}).catch(()=>{if(r==="vectors"){const o=i+"";t(new nl(s.statusText||`HTTP ${i} error`,i,o,r))}else{const o=i+"";t(new nl(s.statusText||`HTTP ${i} error`,i,o,r))}});else{const o=i+"";t(new nl(s.statusText||`HTTP ${i} error`,i,o,r))}}else t(new RS(uv(e),e,r))},yD=(e,t,n,r)=>{const s={method:e,headers:(t==null?void 0:t.headers)||{}};return e==="GET"||e==="HEAD"||!r?W(W({},s),n):(dD(r)?(s.headers=W({"Content-Type":"application/json"},t==null?void 0:t.headers),s.body=JSON.stringify(r)):s.body=r,t!=null&&t.duplex&&(s.duplex=t.duplex),W(W({},s),n))};async function no(e,t,n,r,s,i,o){return new Promise((a,l)=>{e(n,yD(t,r,s,i)).then(c=>{if(!c.ok)throw c;if(r!=null&&r.noResolveJson)return c;if(o==="vectors"){const u=c.headers.get("content-type");if(!u||!u.includes("application/json"))return{}}return c.json()}).then(c=>a(c)).catch(c=>gD(c,l,r,o))})}function vD(e="storage"){return{get:async(t,n,r,s)=>no(t,"GET",n,r,s,void 0,e),post:async(t,n,r,s,i)=>no(t,"POST",n,s,i,r,e),put:async(t,n,r,s,i)=>no(t,"PUT",n,s,i,r,e),head:async(t,n,r,s)=>no(t,"HEAD",n,W(W({},r),{},{noResolveJson:!0}),s,void 0,e),remove:async(t,n,r,s,i)=>no(t,"DELETE",n,s,i,r,e)}}const wD=vD("storage"),{get:ra,post:pe,put:Vh,head:xD,remove:Up}=wD;var Bi=class{constructor(e,t={},n,r="storage"){this.shouldThrowOnError=!1,this.url=e,this.headers=t,this.fetch=uD(n),this.namespace=r}throwOnError(){return this.shouldThrowOnError=!0,this}async handleOperation(e){var t=this;try{return{data:await e(),error:null}}catch(n){if(t.shouldThrowOnError)throw n;if(Gc(n))return{data:null,error:n};throw n}}},bD=class{constructor(e,t){this.downloadFn=e,this.shouldThrowOnError=t}then(e,t){return this.execute().then(e,t)}async execute(){var e=this;try{return{data:(await e.downloadFn()).body,error:null}}catch(t){if(e.shouldThrowOnError)throw t;
238if(Gc(t))return{data:null,error:t};throw t}}};let jS;jS=Symbol.toStringTag;var SD=class{constructor(e,t){this.downloadFn=e,this.shouldThrowOnError=t,this[jS]="BlobDownloadBuilder",this.promise=null}asStream(){return new bD(this.downloadFn,this.shouldThrowOnError)}then(e,t){return this.getPromise().then(e,t)}catch(e){return this.getPromise().catch(e)}finally(e){return this.getPromise().finally(e)}getPromise(){return this.promise||(this.promise=this.execute()),this.promise}async execute(){var e=this;try{return{data:await(await e.downloadFn()).blob(),error:null}}catch(t){if(e.shouldThrowOnError)throw t;if(Gc(t))return{data:null,error:t};throw t}}};const _D={limit:100,offset:0,sortBy:{column:"name",order:"asc"}},dv={cacheControl:"3600",contentType:"text/plain;charset=UTF-8",upsert:!1};var kD=class extends Bi{constructor(e,t={},n,r){super(e,t,r,"storage"),this.bucketId=n}async uploadOrUpdate(e,t,n,r){var s=this;return s.handleOperation(async()=>{let i;const o=W(W({},dv),r);let a=W(W({},s.headers),e==="POST"&&{"x-upsert":String(o.upsert)});const l=o.metadata;typeof Blob<"u"&&n instanceof Blob?(i=new FormData,i.append("cacheControl",o.cacheControl),l&&i.append("metadata",s.encodeMetadata(l)),i.append("",n)):typeof FormData<"u"&&n instanceof FormData?(i=n,i.has("cacheControl")||i.append("cacheControl",o.cacheControl),l&&!i.has("metadata")&&i.append("metadata",s.encodeMetadata(l))):(i=n,a["cache-control"]=`max-age=${o.cacheControl}`,a["content-type"]=o.contentType,l&&(a["x-metadata"]=s.toBase64(s.encodeMetadata(l))),(typeof ReadableStream<"u"&&i instanceof ReadableStream||i&&typeof i=="object"&&"pipe"in i&&typeof i.pipe=="function")&&!o.duplex&&(o.duplex="half")),r!=null&&r.headers&&(a=W(W({},a),r.headers));const c=s._removeEmptyFolders(t),u=s._getFinalPath(c),d=await(e=="PUT"?Vh:pe)(s.fetch,`${s.url}/object/${u}`,i,W({headers:a},o!=null&&o.duplex?{duplex:o.duplex}:{}));return{path:c,id:d.Id,fullPath:d.Key}})}async upload(e,t,n){return this.uploadOrUpdate("POST",e,t,n)}async uploadToSignedUrl(e,t,n,r){var s=this;const i=s._removeEmptyFolders(e),o=s._getFinalPath(i),a=new URL(s.url+`/object/upload/sign/${o}`);return a.searchParams.set("token",t),s.handleOperation(async()=>{let l;const c=W({upsert:dv.upsert},r),u=W(W({},s.headers),{"x-upsert":String(c.upsert)});return typeof Blob<"u"&&n instanceof Blob?(l=new FormData,l.append("cacheControl",c.cacheControl),l.append("",n)):typeof FormData<"u"&&n instanceof FormData?(l=n,l.append("cacheControl",c.cacheControl)):(l=n,u["cache-control"]=`max-age=${c.cacheControl}`,u["content-type"]=c.contentType),{path:i,fullPath:(await Vh(s.fetch,a.toString(),l,{headers:u})).Key}})}async createSignedUploadUrl(e,t){var n=this;return n.handleOperation(async()=>{let r=n._getFinalPath(e);const s=W({},n.headers);t!=null&&t.upsert&&(s["x-upsert"]="true");const i=await pe(n.fetch,`${n.url}/object/upload/sign/${r}`,{},{headers:s}),o=new URL(n.url+i.url),a=o.searchParams.get("token");if(!a)throw new qc("No token returned by API");return{signedUrl:o.toString(),path:e,token:a}})}async update(e,t,n){return this.uploadOrUpdate("PUT",e,t,n)}async move(e,t,n){var r=this;return r.handleOperation(async()=>await pe(r.fetch,`${r.url}/object/move`,{bucketId:r.bucketId,sourceKey:e,destinationKey:t,de
238stinationBucket:n==null?void 0:n.destinationBucket},{headers:r.headers}))}async copy(e,t,n){var r=this;return r.handleOperation(async()=>({path:(await pe(r.fetch,`${r.url}/object/copy`,{bucketId:r.bucketId,sourceKey:e,destinationKey:t,destinationBucket:n==null?void 0:n.destinationBucket},{headers:r.headers})).Key}))}async createSignedUrl(e,t,n){var r=this;return r.handleOperation(async()=>{let s=r._getFinalPath(e),i=await pe(r.fetch,`${r.url}/object/sign/${s}`,W({expiresIn:t},n!=null&&n.transform?{transform:n.transform}:{}),{headers:r.headers});const o=n!=null&&n.download?`&download=${n.download===!0?"":n.download}`:"";return{signedUrl:encodeURI(`${r.url}${i.signedURL}${o}`)}})}async createSignedUrls(e,t,n){var r=this;return r.handleOperation(async()=>{const s=await pe(r.fetch,`${r.url}/object/sign/${r.bucketId}`,{expiresIn:t,paths:e},{headers:r.headers}),i=n!=null&&n.download?`&download=${n.download===!0?"":n.download}`:"";return s.map(o=>W(W({},o),{},{signedUrl:o.signedURL?encodeURI(`${r.url}${o.signedURL}${i}`):null}))})}download(e,t){const n=typeof(t==null?void 0:t.transform)<"u"?"render/image/authenticated":"object",r=this.transformOptsToQueryString((t==null?void 0:t.transform)||{}),s=r?`?${r}`:"",i=this._getFinalPath(e),o=()=>ra(this.fetch,`${this.url}/${n}/${i}${s}`,{headers:this.headers,noResolveJson:!0});return new SD(o,this.shouldThrowOnError)}async info(e){var t=this;const n=t._getFinalPath(e);return t.handleOperation(async()=>$h(await ra(t.fetch,`${t.url}/object/info/${n}`,{headers:t.headers})))}async exists(e){var t=this;const n=t._getFinalPath(e);try{return await xD(t.fetch,`${t.url}/object/${n}`,{headers:t.headers}),{data:!0,error:null}}catch(r){if(t.shouldThrowOnError)throw r;if(Gc(r)&&r instanceof RS){const s=r.originalError;if([400,404].includes(s==null?void 0:s.status))return{data:!1,error:r}}throw r}}getPublicUrl(e,t){const n=this._getFinalPath(e),r=[],s=t!=null&&t.download?`download=${t.download===!0?"":t.download}`:"";s!==""&&r.push(s);const i=typeof(t==null?void 0:t.transform)<"u"?"render/image":"object",o=this.transformOptsToQueryString((t==null?void 0:t.transform)||{});o!==""&&r.push(o);let a=r.join("&");return a!==""&&(a=`?${a}`),{data:{publicUrl:encodeURI(`${this.url}/${i}/public/${n}${a}`)}}}async remove(e){var t=this;return t.handleOperation(async()=>await Up(t.fetch,`${t.url}/object/${t.bucketId}`,{prefixes:e},{headers:t.headers}))}async list(e,t,n){var r=this;return r.handleOperation(async()=>{const s=W(W(W({},_D),t),{},{prefix:e||""});return await pe(r.fetch,`${r.url}/object/list/${r.bucketId}`,s,{headers:r.headers},n)})}async listV2(e,t){var n=this;return n.handleOperation(async()=>{const r=W({},e);return await pe(n.fetch,`${n.url}/object/list-v2/${n.bucketId}`,r,{headers:n.headers},t)})}encodeMetadata(e){return JSON.stringify(e)}toBase64(e){return typeof Buffer<"u"?Buffer.from(e).toString("base64"):btoa(e)}_getFinalPath(e){return`${this.bucketId}/${e.replace(/^\/+/,"")}`}_removeEmptyFolders(e){return e.replace(/^\/|\/$/g,"").replace(/\/+/g,"/")}transformOptsToQueryString(e){const t=[];return e.width&&t.push(`width=${e.width}`),e.height&&t.push(`height=${e.height}`),e.resize&&t.push(`resize=${e.resize}`),e.format&&t.push(`format=${e.format}`),e.quality&&t.push(`quality=${e.quality}`),t.join("&")}};const ED="2.93.2",ka={"X-Client-Info":`storage-js/${ED}`};var TD=class extends Bi{constructor(e,t={},n,r){const s=new URL(e);r!=null&&r.useNewHostname&&/supabase\.(co|in|red)$/.test(s.hostname)&&!s.hostname.includes("storage.supabase.")&&(s.hostname=s.hostname.replace("supabase.","storage.supabase."));const i=s.href.replace(/\/$/,""),o=W(W({},ka),t);super(i,o,n,"storage")}async listBuckets(e){var t=this;return t.handleOperation(async()=>{const n=t.listBucketOptionsToQueryString(e);return await ra(t.fetch,`${t.url}/bucket${n}`,{headers:t.headers})})}async getBucket(e){var t=this;return t.handleOperation(async()=>await ra(t.fetch,`${t.url}/bucket/${e}`,{headers:t.headers}))}async createBucket(e,t={public:!1}){var n=this;return n.handleOperation(async()=>await pe(n.fetch,`${n.url}/bucket`,{id:e,name:e,type:t.type,public:t.public,file_size_limit:t.fileSizeLimit,allowed_mime_types:t.allowedMimeTypes},{headers:n.headers}))}async updateBucket(e,t){var n=this;return n.handleOperation(async()=>await Vh(n.fetch,`${n.url}/bucket/${e}`,{id:e,name:e,public:t.public,file_size_limit:t.fileSizeLimit,allowed_mime_types:t.allowedMimeTypes},{headers:n.headers}))}async emptyBucket(e){var t=this;return t.handleOperation(async()=>await pe(t.fetch,`${t.url}/bucket/${e}/empty`,{},{headers:t.headers}))}async deleteBucket(e){var t=this;return t.handleOperation(async()=>await Up(t.fetch,`${t.url}/bucket/${e}`,{},{headers:t.headers}))}listBucketOptionsToQueryString(e){const t={};return e&&("limit"in e&&(t.limit=String(e.limit)),"offset"in e&&(t.offset=String(e.offset)),e.search&&(t.search=e.search),e.sortColumn&&(t.sortColumn=e.sortColumn),e.sortOrder&&(t.sortOrder=e.sortOrder)),Object.keys(t).length>0?"?"+new URLSearchParams(t).toString():""}},CD=class extends Bi{constructor(e,t={},n){const r=e.replace(/\/$/,""),s=W(W({},ka),t);super(r,s,n,"storage")}async createBucket(e){var t=this;return t.handleOperation(async()=>await pe(t.fetch,`${t.url}/bucket`,{name:e},{headers:t.headers}))}async listBuckets(e){var t=this;return t.handleOperation(async()=>{const n=new URLSearchParams;(e==null?void 0:e.limit)!==void 0&&n.set("limit",e.limit.toString()),(e==null?void 0:e.offset)!==void 0&&n.set("offset",e.offset.toString()),e!=null&&e.sortColumn&&n.set("sortColumn",e.sortColumn),e!=null&&e.sortOrder&&n.set("sortOrder",e.sortOrder),e!=null&&e.search&&n.set("search",e.search);const r=n.toString(),s=r?`${t.url}/bucket?${r}`:`${t.url}/bucket`;return await ra(t.fetch,s,{headers:t.headers})})}async deleteBucket(e){var t=this;return t.handleOperation(async()=>await Up(t.fetch,`${t.url}/bucket/${e}`,{},{headers:t.headers}))}from(e){var t=this;if(!hD(e))throw new qc("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 cD({baseUrl:this.url,catalogName:e,auth:{type:"custom",getHeaders:async()=>t.headers},fetch:this.fetch}
238),r=this.shouldThrowOnError;return new Proxy(n,{get(s,i){const o=s[i];return typeof o!="function"?o:async(...a)=>{try{return{data:await o.apply(s,a),error:null}}catch(l){if(r)throw l;return{data:null,error:l}}}}})}},PD=class extends Bi{constructor(e,t={},n){const r=e.replace(/\/$/,""),s=W(W({},ka),{},{"Content-Type":"application/json"},t);super(r,s,n,"vectors")}async createIndex(e){var t=this;return t.handleOperation(async()=>await pe(t.fetch,`${t.url}/CreateIndex`,e,{headers:t.headers})||{})}async getIndex(e,t){var n=this;return n.handleOperation(async()=>await pe(n.fetch,`${n.url}/GetIndex`,{vectorBucketName:e,indexName:t},{headers:n.headers}))}async listIndexes(e){var t=this;return t.handleOperation(async()=>await pe(t.fetch,`${t.url}/ListIndexes`,e,{headers:t.headers}))}async deleteIndex(e,t){var n=this;return n.handleOperation(async()=>await pe(n.fetch,`${n.url}/DeleteIndex`,{vectorBucketName:e,indexName:t},{headers:n.headers})||{})}},AD=class extends Bi{constructor(e,t={},n){const r=e.replace(/\/$/,""),s=W(W({},ka),{},{"Content-Type":"application/json"},t);super(r,s,n,"vectors")}async putVectors(e){var t=this;if(e.vectors.length<1||e.vectors.length>500)throw new Error("Vector batch size must be between 1 and 500 items");return t.handleOperation(async()=>await pe(t.fetch,`${t.url}/PutVectors`,e,{headers:t.headers})||{})}async getVectors(e){var t=this;return t.handleOperation(async()=>await pe(t.fetch,`${t.url}/GetVectors`,e,{headers:t.headers}))}async listVectors(e){var t=this;if(e.segmentCount!==void 0){if(e.segmentCount<1||e.segmentCount>16)throw new Error("segmentCount must be between 1 and 16");if(e.segmentIndex!==void 0&&(e.segmentIndex<0||e.segmentIndex>=e.segmentCount))throw new Error(`segmentIndex must be between 0 and ${e.segmentCount-1}`)}return t.handleOperation(async()=>await pe(t.fetch,`${t.url}/ListVectors`,e,{headers:t.headers}))}async queryVectors(e){var t=this;return t.handleOperation(async()=>await pe(t.fetch,`${t.url}/QueryVectors`,e,{headers:t.headers}))}async deleteVectors(e){var t=this;if(e.keys.length<1||e.keys.length>500)throw new Error("Keys batch size must be between 1 and 500 items");return t.handleOperation(async()=>await pe(t.fetch,`${t.url}/DeleteVectors`,e,{headers:t.headers})||{})}},RD=class extends Bi{constructor(e,t={},n){const r=e.replace(/\/$/,""),s=W(W({},ka),{},{"Content-Type":"application/json"},t);super(r,s,n,"vectors")}async createBucket(e){var t=this;return t.handleOperation(async()=>await pe(t.fetch,`${t.url}/CreateVectorBucket`,{vectorBucketName:e},{headers:t.headers})||{})}async getBucket(e){var t=this;return t.handleOperation(async()=>await pe(t.fetch,`${t.url}/GetVectorBucket`,{vectorBucketName:e},{headers:t.headers}))}async listBuckets(e={}){var t=this;return t.handleOperation(async()=>await pe(t.fetch,`${t.url}/ListVectorBuckets`,e,{headers:t.headers}))}async deleteBucket(e){var t=this;return t.handleOperation(async()=>await pe(t.fetch,`${t.url}/DeleteVectorBucket`,{vectorBucketName:e},{headers:t.headers})||{})}},jD=class extends RD{constructor(e,t={}){super(e,t.headers||{},t.fetch)}from(e){return new ND(this.url,this.headers,e,this.fetch)}async createBucket(e){var t=()=>super.createBucket,n=this;return t().call(n,e)}async getBucket(e){var t=()=>super.getBucket,n=this;return t().call(n,e)}async listBuckets(e={}){var t=()=>super.listBuckets,n=this;return t().call(n,e)}async deleteBucket(e){var t=()=>super.deleteBucket,n=this;return t().call(n,e)}},ND=class extends PD{constructor(e,t,n,r){super(e,t,r),this.vectorBucketName=n}async createIndex(e){var t=()=>super.createIndex,n=this;return t().call(n,W(W({},e),{},{vectorBucketName:n.vectorBucketName}))}async listIndexes(e={}){var t=()=>super.listIndexes,n=this;return t().call(n,W(W({},e),{},{vectorBucketName:n.vectorBucketName}))}async getIndex(e){var t=()=>super.getIndex,n=this;return t().call(n,n.vectorBucketName,e)}async deleteIndex(e){var t=()=>super.deleteIndex,n=this;return t().call(n,n.vectorBucketName,e)}index(e){return new OD(this.url,this.headers,this.vectorBucketName,e,this.fetch)}}
238,OD=class extends AD{constructor(e,t,n,r,s){super(e,t,s),this.vectorBucketName=n,this.indexName=r}async putVectors(e){var t=()=>super.putVectors,n=this;return t().call(n,W(W({},e),{},{vectorBucketName:n.vectorBucketName,indexName:n.indexName}))}async getVectors(e){var t=()=>super.getVectors,n=this;return t().call(n,W(W({},e),{},{vectorBucketName:n.vectorBucketName,indexName:n.indexName}))}async listVectors(e={}){var t=()=>super.listVectors,n=this;return t().call(n,W(W({},e),{},{vectorBucketName:n.vectorBucketName,indexName:n.indexName}))}async queryVectors(e){var t=()=>super.queryVectors,n=this;return t().call(n,W(W({},e),{},{vectorBucketName:n.vectorBucketName,indexName:n.indexName}))}async deleteVectors(e){var t=()=>super.deleteVectors,n=this;return t().call(n,W(W({},e),{},{vectorBucketName:n.vectorBucketName,indexName:n.indexName}))}},ID=class extends TD{constructor(e,t={},n,r){super(e,t,n,r)}from(e){return new kD(this.url,this.headers,e,this.fetch)}get vectors(){return new jD(this.url+"/vector",{headers:this.headers,fetch:this.fetch})}get analytics(){return new CD(this.url+"/iceberg",this.headers,this.fetch)}};const NS="2.93.2",Ls=30*1e3,Fh=3,Xu=Fh*Ls,DD="http://localhost:9999",LD="supabase.auth.token",MD={"X-Client-Info":`gotrue-js/${NS}`},Uh="X-Supabase-Api-Version",OS={"2024-01-01":{timestamp:Date.parse("2024-01-01T00:00:00.0Z"),name:"2024-01-01"}},$D=/^([a-z0-9_-]{4})*($|[a-z0-9_-]{3}$|[a-z0-9_-]{2}$)$/i,VD=10*60*1e3;class sa extends Error{constructor(t,n,r){super(t),this.__isAuthError=!0,this.name="AuthError",this.status=n,this.code=r}}function F(e){return typeof e=="object"&&e!==null&&"__isAuthError"in e}class FD extends sa{constructor(t,n,r){super(t,n,r),this.name="AuthApiError",this.status=n,this.code=r}}function UD(e){return F(e)&&e.name==="AuthApiError"}class qr extends sa{constructor(t,n){super(t),this.name="AuthUnknownError",this.originalError=n}}class Fn extends sa{constructor(t,n,r,s){super(t,r,s),this.name=n,this.status=r}}class gt extends Fn{constructor(){super("Auth session missing!","AuthSessionMissingError",400,void 0)}}function Zu(e){return F(e)&&e.name==="AuthSessionMissingError"}class Ps extends Fn{constructor(){super("Auth session or user missing","AuthInvalidToken
238ResponseError",500,void 0)}}class rl extends Fn{constructor(t){super(t,"AuthInvalidCredentialsError",400,void 0)}}class sl extends Fn{constructor(t,n=null){super(t,"AuthImplicitGrantRedirectError",500,void 0),this.details=null,this.details=n}toJSON(){return{name:this.name,message:this.message,status:this.status,details:this.details}}}function BD(e){return F(e)&&e.name==="AuthImplicitGrantRedirectError"}class hv extends Fn{constructor(t,n=null){super(t,"AuthPKCEGrantCodeExchangeError",500,void 0),this.details=null,this.details=n}toJSON(){return{name:this.name,message:this.message,status:this.status,details:this.details}}}class zD extends Fn{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 Bh extends Fn{constructor(t,n){super(t,"AuthRetryableFetchError",n,void 0)}}function ed(e){return F(e)&&e.name==="AuthRetryableFetchError"}class fv extends Fn{constructor(t,n,r){super(t,"AuthWeakPasswordError",n,"weak_password"),this.reasons=r}}class zh extends Fn{constructor(t){super(t,"AuthInvalidJwtError",400,"invalid_jwt")}}const dc="ABCDEFGHIJKLMNOPQRSTUVWXYZabcdefghijklmnopqrstuvwxyz0123456789-_".split(""),pv=` 239\r=`.split(""),WD=(()=>{const e=new Array(128);for(let t=0;t<e.length;t+=1)e[t]=-1;for(let t=0;t<pv.length;t+=1)e[pv[t].charCodeAt(0)]=-2;for(let t=0;t<dc.length;t+=1)e[dc[t].charCodeAt(0)]=t;return e})();function mv(e,t,n){if(e!==null)for(t.queue=t.queue<<8|e,t.queuedBits+=8;t.queuedBits>=6;){const r=t.queue>>t.queuedBits-6&63;n(dc[r]),t.queuedBits-=6}else if(t.queuedBits>0)for(t.queue=t.queue<<6-t.queuedBits,t.queuedBits=6;t.queuedBits>=6;){const r=t.queue>>t.queuedBits-6&63;n(dc[r]),t.queuedBits-=6}}function IS(e,t,n){const r=WD[e];if(r>-1)for(t.queue=t.queue<<6|r,t.queuedBits+=6;t.queuedBits>=8;)n(t.queue>>t.queuedBits-8&255),t.queuedBits-=8;else{if(r===-2)return;throw new Error(`Invalid Base64-URL character "${String.fromCharCode(e)}"`)}}function gv(e){const t=[],n=o=>{t.push(String.fromCodePoint(o))},r={utf8seq:0,codepoint:0},s={queue:0,queuedBits:0},i=o=>{qD(o,r,n)};for(let o=0;o<e.length;o+=1)IS(e.charCodeAt(o),s,i);return t.join("")}function HD(e,t){if(e<=127){t(e);return}else if(e<=2047){t(192|e>>6),t(128|e&63);return}else if(e<=65535){t(224|e>>12),t(128|e>>6&63),t(128|e&63);return}else if(e<=1114111){t(240|e>>18),t(128|e>>12&63),t(128|e>>6&63),t(128|e&63);return}throw new Error(`Unrecognized Unicode codepoint: ${e.toString(16)}`)}function KD(e,t){for(let n=0;n<e.length;n+=1){let r=e.charCodeAt(n);if(r>55295&&r<=56319){const s=(r-55296)*1024&65535;r=(e.charCodeAt(n+1)-56320&65535|s)+65536,n+=1}HD(r,t)}}function qD(e,t,n){if(t.utf8seq===0){if(e<=127){n(e);return}for(let r=1;r<6;r+=1)if(!(e>>7-r&1)){t.utf8seq=r;break}if(t.utf8seq===2)t.codepoint=e&31;else if(t.utf8seq===3)t.codepoint=e&15;else if(t.utf8seq===4)t.codepoint=e&7;else throw new Error("Invalid UTF-8 sequence");t.utf8seq-=1}else if(t.utf8seq>0){if(e<=127)throw new Error("Invalid UTF-8 sequence");t.codepoint=t.codepoint<<6|e&63,t.utf8seq-=1,t.utf8seq===0&&n(t.codepoint)}}function di(e){const t=[],n={queue:0,queuedBits:0},r=s=>{t.push(s)};for(let s=0;s<e.length;s+=1)IS(e.charCodeAt(s),n,r);return new Uint8Array(t)}function GD(e){const t=[];return KD(e,n=>t.push(n)),new Uint8Array(t)}function Zr(e){const t=[],n={queue:0,queuedBits:0},r=s=>{t.push(s)};return e.forEach(s=>mv(s,n,r)),mv(null,n,r),t.join("")}function YD(e){return Math.round(Date.now()/1e3)+e}function QD(){return Symbol("auth-callback")}const Be=()=>typeof window<"u"&&typeof document<"u",$r={tested:!1,writable:!1},DS=()=>{if(!Be())return!1;try{if(typeof globalThis.localStorage!="object")return!1}catch{return!1}if($r.tested)return $r.writable;const e=`lswt-${Math.random()}${Math.random()}`;try{globalThis.localStorage.setItem(e,e),globalThis.localStorage.removeItem(e),$r.tested=!0,$r.writable=!0}catch{$r.tested=!0,$r.writable=!1}return $r.writable};function JD(e){const t={},n=new URL(e);if(n.hash&&n.hash[0]==="#")try{new URLSearchParams(n.hash.substring(1)).forEac
239h((s,i)=>{t[i]=s})}catch{}return n.searchParams.forEach((r,s)=>{t[s]=r}),t}const LS=e=>e?(...t)=>e(...t):(...t)=>fetch(...t),XD=e=>typeof e=="object"&&e!==null&&"status"in e&&"ok"in e&&"json"in e&&typeof e.json=="function",Ms=async(e,t,n)=>{await e.setItem(t,JSON.stringify(n))},Vr=async(e,t)=>{const n=await e.getItem(t);if(!n)return null;try{return JSON.parse(n)}catch{return n}},Fe=async(e,t)=>{await e.removeItem(t)};class Yc{constructor(){this.promise=new Yc.promiseConstructor((t,n)=>{this.resolve=t,this.reject=n})}}Yc.promiseConstructor=Promise;function il(e){const t=e.split(".");if(t.length!==3)throw new zh("Invalid JWT structure");for(let r=0;r<t.length;r++)if(!$D.test(t[r]))throw new zh("JWT not in base64url format");return{header:JSON.parse(gv(t[0])),payload:JSON.parse(gv(t[1])),signature:di(t[2]),raw:{header:t[0],payload:t[1]}}}async function ZD(e){return await new Promise(t=>{setTimeout(()=>t(null),e)})}function eL(e,t){return new Promise((r,s)=>{(async()=>{for(let i=0;i<1/0;i++)try{const o=await e(i);if(!t(i,null,o)){r(o);return}}catch(o){if(!t(i,o)){s(o);return}}})()})}function tL(e){return("0"+e.toString(16)).substr(-2)}function nL(){const t=new Uint32Array(56);if(typeof crypto>"u"){const n="ABCDEFGHIJKLMNOPQRSTUVWXYZabcdefghijklmnopqrstuvwxyz0123456789-._~",r=n.length;let s="";for(let i=0;i<56;i++)s+=n.charAt(Math.floor(Math.random()*r));return s}return crypto.getRandomValues(t),Array.from(t,tL).join("")}async function rL(e){const n=new TextEncoder().encode(e),r=await crypto.subtle.digest("SHA-256",n),s=new Uint8Array(r);return Array.from(s).map(i=>String.fromCharCode(i)).join("")}async function sL(e){if(!(typeof crypto<"u"&&typeof crypto.subtle<"u"&&typeof TextEncoder<"u"))return console.warn("WebCrypto API is not supported. Code challenge method will default to use plain instead of sha256."),e;const n=await rL(e);return btoa(n).replace(/\+/g,"-").replace(/\//g,"_").replace(/=+$/,"")}async function As(e,t,n=!1){const r=nL();let s=r;n&&(s+="/PASSWORD_RECOVERY"),await Ms(e,`${t}-code-verifier`,s);const i=await sL(r);return[i,r===i?"plain":"s256"]}const iL=/^2[0-9]{3}-(0[1-9]|1[0-2])-(0[1-9]|1[0-9]|2[0-9]|3[0-1])$/i;function oL(e){const t=e.headers.get(Uh);if(!t||!t.match(iL))return null;try{return new Date(`${t}T00:00:00.0Z`)}catch{return null}}function aL(e){if(!e)throw new Error("Missing exp claim");const t=Math.floor(Date.now()/1e3);if(e<=t)throw new Error("JWT has expired")}function lL(e){switch(e){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 cL=/^[0-9a-f]{8}-[0-9a-f]{4}-[0-9a-f]{4}-[0-9a-f]{4}-[0-9a-f]{12}$/;function Rs(e){if(!cL.test(e))throw new Error("@supabase/auth-js: Expected parameter to be UUID but is not")}function td(){const e={};return new Proxy(e,{get:(t,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:(t,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:(t,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 uL(e,t){return new Proxy(e,{get:(n,r,s)=>{if(r==="__isInsecureUserWarningProxy")return!0;if(typeof r=="symbol"){const i=r.toString();if(i==="Symbol(Symbol.toPrimitive)"||i==="Symbol(Symbol.toStringTag)"||i==="Symbol(util.inspect.custom)"||i==="Symbol(nodejs.util.inspect.custom)")return Reflect.get(n,r,s)}return!t.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."),t.value=!0),Reflect.get(n,r,s)}})}function yv(e){return JSON.parse(JSON.stringify(e))}const Hr=e=>e.msg||e.message||e.error_description||e.error||JSON.stringify(e),dL=[502,503,504];async function vv(e){var t;if(!XD(e))throw new Bh(Hr(e),0);if(dL.includes(e.status))throw new Bh(Hr(e),e.status);let n;try{n=await e.json()}catch(i){throw new qr(Hr(i),i)}let r;const s=oL(e);if(s&&s.getTime()>=OS["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 fv(Hr(n),e.status,((t=n.weak_password)===null||t===void 0?void 0:t.reasons)||[]);if(r==="session_not_found")throw new gt}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((i,o)=>
239i&&typeof o=="string",!0))throw new fv(Hr(n),e.status,n.weak_password.reasons);throw new FD(Hr(n),e.status||500,r)}const hL=(e,t,n,r)=>{const s={method:e,headers:(t==null?void 0:t.headers)||{}};return e==="GET"?s:(s.headers=Object.assign({"Content-Type":"application/json;charset=UTF-8"},t==null?void 0:t.headers),s.body=JSON.stringify(r),Object.assign(Object.assign({},s),n))};async function z(e,t,n,r){var s;const i=Object.assign({},r==null?void 0:r.headers);i[Uh]||(i[Uh]=OS["2024-01-01"].name),r!=null&&r.jwt&&(i.Authorization=`Bearer ${r.jwt}`);const o=(s=r==null?void 0:r.query)!==null&&s!==void 0?s:{};r!=null&&r.redirectTo&&(o.redirect_to=r.redirectTo);const a=Object.keys(o).length?"?"+new URLSearchParams(o).toString():"",l=await fL(e,t,n+a,{headers:i,noResolveJson:r==null?void 0:r.noResolveJson},{},r==null?void 0:r.body);return r!=null&&r.xform?r==null?void 0:r.xform(l):{data:Object.assign({},l),error:null}}async function fL(e,t,n,r,s,i){const o=hL(t,r,s,i);let a;try{a=await e(n,Object.assign({},o))}catch(l){throw console.error(l),new Bh(Hr(l),0)}if(a.ok||await vv(a),r!=null&&r.noResolveJson)return a;try{return await a.json()}catch(l){await vv(l)}}function Wt(e){var t;let n=null;gL(e)&&(n=Object.assign({},e),e.expires_at||(n.expires_at=YD(e.expires_in)));const r=(t=e.user)!==null&&t!==void 0?t:e;return{data:{session:n,user:r},error:null}}function wv(e){const t=Wt(e);return!t.error&&e.weak_password&&typeof e.weak_password=="object"&&Array.isArray(e.weak_password.reasons)&&e.weak_password.reasons.length&&e.weak_password.message&&typeof e.weak_password.message=="string"&&e.weak_password.reasons.reduce((n,r)=>n&&typeof r=="string",!0)&&(t.data.weak_password=e.weak_password),t}function sr(e){var t;return{data:{user:(t=e.user)!==null&&t!==void 0?t:e},error:null}}function pL(e){return{data:e,error:null}}function mL(e){const{action_link:t,email_otp:n,hashed_token:r,redirect_to:s,verification_type:i}=e,o=Kc(e,["action_link","email_otp","hashed_token","redirect_to","verification_type"]),a={action_link:t,email_otp:n,hashed_token:r,redirect_to:s,verification_type:i},l=Object.assign({},o);return{data:{properties:a,user:l},error:null}}function xv(e){return e}function gL(e){return e.access_token&&e.refresh_token&&e.expires_in}const nd=["global","local","others"];class yL{constructor({url:t="",headers:n={},fetch:r}){this.url=t,this.headers=n,this.fetch=LS(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)}}async signOut(t,n=nd[0]){if(nd.indexOf(n)<0)throw new Error(`@supabase/auth-js: Parameter scope must be one of ${nd.join(", ")}`);try{return await z(this.fetch,"POST",`${this.url}/logout?scope=${n}`,{headers:this.headers,jwt:t,noResolveJson:!0}),{data:null,error:null}}catch(r){if(F(r))return{data:null,error:r};throw r}}async inviteUserByEmail(t,n={}){try{return await z(this.fetch,"POST",`${this.url}/invite`,{body:{email:t,data:n.data},headers:this.headers,redirectTo:n.redirectTo,xform:sr})}catch(r){if(F(r))return{data:{user:null},error:r};throw r}}async generateLink(t){try{const{options:n}=t,r=Kc(t,["options"]),s=Object.assign(Object.assign({},r),n);return"newEmail"in r&&(s.new_email=r==null?void 0:r.newEmail,delete s.newEmail),await z(this.fetch,"POST",`${this.url}/admin/generate_link`,{body:s,headers:this.headers,xform:mL,redirectTo:n==null?void 0:n.redirectTo})}catch(n){if(F(n))return{data:{properties:null,user:null},error:n};throw n}}async createUser(t){try{return await z(this.fetch,"POST",`${this.url}/admin/users`,{body:t,headers:this.headers,xform:sr})}catch(n){if(F(n))return{data:{user:null},error:n};throw n}}async listUsers(t){var n,r,s,i,o,a,l;try{const c={nextPage:null,lastPage:0,total:0},u=await z(this.fetch,"GET",`${this.url}/admin/users`,{headers:this.headers,noResolveJson:!0,query:{page:(r=(n=t==null?void 0:t.page)===null||n===void 0?void 0:n.toString())!==null&&r!==void 0?r:"",per_page:(i=(s=t==null?void 0:t.perPage)===null||s===void 0?void 0:s.toString())!==null&&i!==void 0?i:""},xform:xv});if(u.error)throw u.error;const d=await u.json(),h=(o=u.headers.get("x-total-count"))!==null&&o!==void 0?o:0,f=(l=(a=u.headers.get("link"))===null||a===void 0?void 0:a.split(","))!==null&&l!==void 0?l:[];return f.length>0&&(f.forEach(w=>{const y=parseInt(w.split(";")[0].split("=")[1].substring(0,1)),x=JSON.parse(w.split(";")[1].split("=")[1]);c[`${x}Page`]=y}),c.total=parseInt(h)),{data:Object.assign(Object.assign({},d),c),error:null}}catch(c){if(F(c))return{data:{users:[]},error:c};throw c}}async getUserById(t){Rs(t);try{return await z(this.fetch,"GET",`${this.url}/admin/users/${t}`,{headers:this.headers,xform:sr})}catch(n){if(F(n))return{data:{user:null},error:n};throw n}}async updateUserById(t,n){Rs(t);try{return await z(this.fetch,"PUT",`${this.url}/admin/users/${t}`,{body:n,headers:this.headers,xform:sr})}catch(r){if(F(r))return{data:{user:null},error:r};throw r}}async deleteUser(t,n=!1){Rs(t);
239try{return await z(this.fetch,"DELETE",`${this.url}/admin/users/${t}`,{headers:this.headers,body:{should_soft_delete:n},xform:sr})}catch(r){if(F(r))return{data:{user:null},error:r};throw r}}async _listFactors(t){Rs(t.userId);try{const{data:n,error:r}=await z(this.fetch,"GET",`${this.url}/admin/users/${t.userId}/factors`,{headers:this.headers,xform:s=>({data:{factors:s},error:null})});return{data:n,error:r}}catch(n){if(F(n))return{data:null,error:n};throw n}}async _deleteFactor(t){Rs(t.userId),Rs(t.id);try{return{data:await z(this.fetch,"DELETE",`${this.url}/admin/users/${t.userId}/factors/${t.id}`,{headers:this.headers}),error:null}}catch(n){if(F(n))return{data:null,error:n};throw n}}async _listOAuthClients(t){var n,r,s,i,o,a,l;try{const c={nextPage:null,lastPage:0,total:0},u=await z(this.fetch,"GET",`${this.url}/admin/oauth/clients`,{headers:this.headers,noResolveJson:!0,query:{page:(r=(n=t==null?void 0:t.page)===null||n===void 0?void 0:n.toString())!==null&&r!==void 0?r:"",per_page:(i=(s=t==null?void 0:t.perPage)===null||s===void 0?void 0:s.toString())!==null&&i!==void 0?i:""},xform:xv});if(u.error)throw u.error;const d=await u.json(),h=(o=u.headers.get("x-total-count"))!==null&&o!==void 0?o:0,f=(l=(a=u.headers.get("link"))===null||a===void 0?void 0:a.split(","))!==null&&l!==void 0?l:[];return f.length>0&&(f.forEach(w=>{const y=parseInt(w.split(";")[0].split("=")[1].substring(0,1)),x=JSON.parse(w.split(";")[1].split("=")[1]);c[`${x}Page`]=y}),c.total=parseInt(h)),{data:Object.assign(Object.assign({},d),c),error:null}}catch(c){if(F(c))return{data:{clients:[]},error:c};throw c}}async _createOAuthClient(t){try{return await z(this.fetch,"POST",`${this.url}/admin/oauth/clients`,{body:t,headers:this.headers,xform:n=>({data:n,error:null})})}catch(n){if(F(n))return{data:null,error:n};throw n}}async _getOAuthClient(t){try{return await z(this.fetch,"GET",`${this.url}/admin/oauth/clients/${t}`,{headers:this.headers,xform:n=>({data:n,error:null})})}catch(n){if(F(n))return{data:null,error:n};throw n}}async _updateOAuthClient(t,n){try{return await z(this.fetch,"PUT",`${this.url}/admin/oauth/clients/${t}`,{body:n,headers:this.headers,xform:r=>({data:r,error:null})})}catch(r){if(F(r))return{data:null,error:r};throw r}}async _deleteOAuthClient(t){try{return await z(this.fetch,"DELETE",`${this.url}/admin/oauth/clients/${t}`,{headers:this.headers,noResolveJson:!0}),{data:null,error:null}}catch(n){if(F(n))return{data:null,error:n};throw n}}async _regenerateOAuthClientSecret(t){try{return await z(this.fetch,"POST",`${this.url}/admin/oauth/clients/${t}/regenerate_secret`,{headers:this.headers,xform:n=>({data:n,error:null})})}catch(n){if(F(n))return{data:null,error:n};throw n}}}function bv(e={}){return{getItem:t=>e[t]||null,setItem:(t,n)=>{e[t]=n},removeItem:t=>{delete e[t]}}}const js={debug:!!(globalThis&&DS()&&globalThis.localStorage&&globalThis.localStorage.getItem("supabase.gotrue-js.locks.debug")==="true")};class MS extends Error{constructor(t){super(t),this.isAcquireTimeout=!0}}class vL extends MS{}async function wL(e,t,n){js.debug&&console.log("@supabase/gotrue-js: navigatorLock: acquire lock",e,t);const r=new globalThis.AbortController;return t>0&&setTimeout(()=>{r.abort(),js.debug&&console.log("@supabase/gotrue-js: navigatorLock acquire timed out",e)},t),await Promise.resolve().then(()=>globalThis.navigator.locks.request(e,t===0?{mode:"exclusive",ifAvailable:!0}:{mode:"exclusive",signal:r.signal},async s=>{if(s){js.debug&&console.log("@supabase/gotrue-js: navigatorLock: acquired",e,s.name);try{return await n()}finally{js.debug&&console.log("@supabase/gotrue-js: navigatorLock: released",e,s.name)}}else{if(t===0)throw js.debug&&console.log("@supabase/gotrue-js: navigatorLock: not immediately available",e),new vL(`Acquiring an exclusive Navigator LockManager lock "${e}" immediately failed`);if(js.debug)try{const i=await globalThis.navigator.locks.query();console.log("@supabase/gotrue-js: Navigator LockManager state",JSON.stringify(i,null," "))}catch(i){console.warn("@supabase/gotrue-js: Error when querying Navigator LockManager state",i)}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()}}))}function xL(){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 $S(e){if(!/^0x[a-fA-F0-9]{40}$/.test(e))throw new Error(`@supabase/auth-js: Address "${e}
239" is invalid.`);return e.toLowerCase()}function bL(e){return parseInt(e,16)}function SL(e){const t=new TextEncoder().encode(e);return"0x"+Array.from(t,r=>r.toString(16).padStart(2,"0")).join("")}function _L(e){var t;const{chainId:n,domain:r,expirationTime:s,issuedAt:i=new Date,nonce:o,notBefore:a,requestId:l,resources:c,scheme:u,uri:d,version:h}=e;{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(o&&o.length<8)throw new Error(`@supabase/auth-js: Invalid SIWE message field "nonce". Nonce must be at least 8 characters. Provided value: ${o}`);if(!d)throw new Error('@supabase/auth-js: Invalid SIWE message field "uri". URI must be provided.');if(h!=="1")throw new Error(`@supabase/auth-js: Invalid SIWE message field "version". Version must be '1'. Provided value: ${h}`);if(!((t=e.statement)===null||t===void 0)&&t.includes(` 240`))throw new Error(`@supabase/auth-js: Invalid SIWE message field "statement". Statement must not include '\\n'. Provided value: ${e.statement}`)}const f=$S(e.address),w=u?`${u}://${r}`:r,y=e.statement?`${e.statement} 241`:"",x=`${w} wants you to sign in with your Ethereum account: 242${f} 243 244${y}`;let m=`URI: ${d} 245Version: ${h} 246Chain ID: ${n}${o?` 247Nonce: ${o}`:""} 248Issued At: ${i.toISOString()}`;if(s&&(m+=` 249Expiration Time: ${s.toISOString()}`),a&&(m+=` 250Not Before: ${a.toISOString()}`),l&&(m+=` 251Request ID: ${l}`),c){let g=` 252Resources:`;for(const v of c){if(!v||typeof v!="string")throw new Error(`@supabase/auth-js: Invalid SIWE message field "resources". Every resource must be a valid string. Provided value: ${v}`);g+=` 253- ${v}`}m+=g}return`${x} 254${m}`}class Re extends Error{constructor({message:t,code:n,cause:r,name:s}){var i;super(t,{cause:r}),this.__isWebAuthnError=!0,this.name=(i=s??(r instanceof Error?r.name:void 0))!==null&&i!==void 0?i:"Unknown Error",this.code=n}}class hc extends Re{constructor(t,n){super({code:"ERROR_PASSTHROUGH_SEE_CAUSE_PROPERTY",cause:n,message:t}),this.name="WebAuthnUnknownError",this.originalError=n}}function kL({error:e,options:t}){var n,r,s;const{publicKey:i}=t;if(!i)throw Error("options was missing required publicKey property");if(e.name==="AbortError"){if(t.signal instanceof AbortSignal)return new Re({message:"Registration ceremony was sent an abort signal",code:"ERROR_CEREMONY_ABORTED",cause:e})}else if(e.name==="ConstraintError"){if(((n=i.authenticatorSelection)===null||n===void 0?void 0:n.requireResidentKey)===!0)return new Re({message:"Discoverable credentials were required but no available authenticator supported it",code:"ERROR_AUTHENTICATOR_MISSING_DISCOVERABLE_CREDENTIAL_SUPPORT",cause:e});if(t.mediation==="conditional"&&((r=i.authenticatorSelection)===null||r===void 0?void 0:r.userVerification)==="required")return new Re({message:"User verification was required during automatic registration but it could not be performed",code:"ERROR_AUTO_REGISTER_USER_VERIFICATION_FAILURE",cause:e});if(((s=i.authenticatorSelection)===null||s===void 0?void 0:s.userVerification)==="required")return new Re({message:"User verification was required but no available authenticator supported it",code:"ERROR_AUTHENTICATOR_MISSING_USER_VERIFICATION_SUPPORT",cause:e})}else{if(e.name==="InvalidStateError")return new Re({message:"The authenticator was previously registered",code:"ERROR_AUTHENTICATOR_PREVIOUSLY_REGISTERED",cause:e});if(e.name==="NotAllowedError")return new Re({message:e.message,code:"ERROR_PASSTHROUGH_SEE_CAUSE_PROPERTY",cause:e});if(e.name==="NotSupportedError")return i.pubKeyCredParams.filter(a=>a.type==="public-key").length===0?new Re({message:'No entry in pubKeyCredParams was of type "public-key"',code:"ERROR_MALFORMED_PUBKEYCREDPARAMS",cause:e}):new Re({message:"No available authenticator supported any of the specified pubKeyCredParams algorithms",code:"ERROR_AUTHENTICATOR_NO_SUPPORTED_PUBKEYCREDPARAMS_ALG",cause:e});if(e.name==="SecurityError"){const o=window.location.hostname;if(VS(o)){if(i.rp.id!==o)return new Re({message:`The RP ID "${i.rp.id}
254" is invalid for this domain`,code:"ERROR_INVALID_RP_ID",cause:e})}else return new Re({message:`${window.location.hostname} is an invalid domain`,code:"ERROR_INVALID_DOMAIN",cause:e})}else if(e.name==="TypeError"){if(i.user.id.byteLength<1||i.user.id.byteLength>64)return new Re({message:"User ID was not between 1 and 64 characters",code:"ERROR_INVALID_USER_ID_LENGTH",cause:e})}else if(e.name==="UnknownError")return new Re({message:"The authenticator was unable to process the specified options, or could not create a new credential",code:"ERROR_AUTHENTICATOR_GENERAL_ERROR",cause:e})}return new Re({message:"a Non-Webauthn related error has occurred",code:"ERROR_PASSTHROUGH_SEE_CAUSE_PROPERTY",cause:e})}function EL({error:e,options:t}){const{publicKey:n}=t;if(!n)throw Error("options was missing required publicKey property");if(e.name==="AbortError"){if(t.signal instanceof AbortSignal)return new Re({message:"Authentication ceremony was sent an abort signal",code:"ERROR_CEREMONY_ABORTED",cause:e})}else{if(e.name==="NotAllowedError")return new Re({message:e.message,code:"ERROR_PASSTHROUGH_SEE_CAUSE_PROPERTY",cause:e});if(e.name==="SecurityError"){const r=window.location.hostname;if(VS(r)){if(n.rpId!==r)return new Re({message:`The RP ID "${n.rpId}" is invalid for this domain`,code:"ERROR_INVALID_RP_ID",cause:e})}else return new Re({message:`${window.location.hostname} is an invalid domain`,code:"ERROR_INVALID_DOMAIN",cause:e})}else if(e.name==="UnknownError")return new Re({message:"The authenticator was unable to process the specified options, or could not create a new assertion signature",code:"ERROR_AUTHENTICATOR_GENERAL_ERROR",cause:e})}return new Re({message:"a Non-Webauthn related error has occurred",code:"ERROR_PASSTHROUGH_SEE_CAUSE_PROPERTY",cause:e})}class TL{createNewAbortSignal(){if(this.controller){const n=new Error("Cancelling existing WebAuthn API call for new one");n.name="AbortError",this.controller.abort(n)}const t=new AbortController;return this.controller=t,t.signal}cancelCeremony(){if(this.controller){const t=new Error("Manually cancelling existing WebAuthn API call");t.name="AbortError",this.controller.abort(t),this.controller=void 0}}}const CL=new TL;function PL(e){if(!e)throw new Error("Credential creation options are required");if(typeof PublicKeyCredential<"u"&&"parseCreationOptionsFromJSON"in PublicKeyCredential&&typeof PublicKeyCredential.parseCreationOptionsFromJSON=="function")return PublicKeyCredential.parseCreationOptionsFromJSON(e);const{challenge:t,user:n,excludeCredentials:r}=e,s=Kc(e,["challenge","user","excludeCredentials"]),i=di(t).buffer,o=Object.assign(Object.assign({},n),{id:di(n.id).buffer}),a=Object.assign(Object.assign({},s),{challenge:i,user:o});if(r&&r.length>0){a.excludeCredentials=new Array(r.length);for(let l=0;l<r.length;l++){const c=r[l];a.excludeCredentials[l]=Object.assign(Object.assign({},c),{id:di(c.id).buffer,type:c.type||"public-key",transports:c.transports})}}return a}function AL(e){if(!e)throw new Error("Credential request options are required");if(typeof PublicKeyCredential<"u"&&"parseRequestOptionsFromJSON"in PublicKeyCredential&&typeof PublicKeyCredential.parseRequestOptionsFromJSON=="function")return PublicKeyCredential.parseRequestOptionsFromJSON(e);const{challenge:t,allowCredentials:n}=e,r=Kc(e,["challenge","allowCredentials"]),s=di(t).buffer,i=Object.assign(Object.assign({},r),{challenge:s});if(n&&n.length>0){i.allowCredentials=new Array(n.length);for(let o=0;o<n.length;o++){const a=n[o];i.allowCredentials[o]=Object.assign(Object.assign({},a),{id:di(a.id).buffer,type:a.type||"public-key",transports:a.transports})}}return i}function RL(e){var t;if("toJSON"in e&&typeof e.toJSON=="function")return e.toJSON();const n=e;return{id:e.id,rawId:e.id,response:{attestationObject:Zr(new Uint8Array(e.response.attestationObject)),clientDataJSON:Zr(new Uint8Array(e.response.clientDataJSON))},type:"public-key",clientExtensionResults:e.getClientExtensionResults(),authenticatorAttachment:(t=n.authenticatorAttachment)!==null&&t!==void 0?t:void 0}}function jL(e){var t;if("toJSON"in e&&typeof e.toJSON=="function")return e.toJSON();const n=e,r=e.getClientExtensionResults(),s=e.response;return{id:e.id,rawId:e.id,response:{authenticatorData:Zr(new Uint8Array(s.authenticatorData)),clientDataJSON:Zr(new Uint8Array(s.clientDataJSON)),signature:Zr(new Uint8Array(s.signature)),userHandle:s.userHandle?Zr(new
254Uint8Array(s.userHandle)):void 0},type:"public-key",clientExtensionResults:r,authenticatorAttachment:(t=n.authenticatorAttachment)!==null&&t!==void 0?t:void 0}}function VS(e){return e==="localhost"||/^([a-z0-9]+(-[a-z0-9]+)*\.)+[a-z]{2,}$/i.test(e)}function Sv(){var e,t;return!!(Be()&&"PublicKeyCredential"in window&&window.PublicKeyCredential&&"credentials"in navigator&&typeof((e=navigator==null?void 0:navigator.credentials)===null||e===void 0?void 0:e.create)=="function"&&typeof((t=navigator==null?void 0:navigator.credentials)===null||t===void 0?void 0:t.get)=="function")}async function NL(e){try{const t=await navigator.credentials.create(e);return t?t instanceof PublicKeyCredential?{data:t,error:null}:{data:null,error:new hc("Browser returned unexpected credential type",t)}:{data:null,error:new hc("Empty credential response",t)}}catch(t){return{data:null,error:kL({error:t,options:e})}}}async function OL(e){try{const t=await navigator.credentials.get(e);return t?t instanceof PublicKeyCredential?{data:t,error:null}:{data:null,error:new hc("Browser returned unexpected credential type",t)}:{data:null,error:new hc("Empty credential response",t)}}catch(t){return{data:null,error:EL({error:t,options:e})}}}const IL={hints:["security-key"],authenticatorSelection:{authenticatorAttachment:"cross-platform",requireResidentKey:!1,userVerification:"preferred",residentKey:"discouraged"},attestation:"direct"},DL={userVerification:"preferred",hints:["security-key"],attestation:"direct"};function fc(...e){const t=s=>s!==null&&typeof s=="object"&&!Array.isArray(s),n=s=>s instanceof ArrayBuffer||ArrayBuffer.isView(s),r={};for(const s of e)if(s)for(const i in s){const o=s[i];if(o!==void 0)if(Array.isArray(o))r[i]=o;else if(n(o))r[i]=o;else if(t(o)){const a=r[i];t(a)?r[i]=fc(a,o):r[i]=fc(o)}else r[i]=o}return r}function LL(e,t){return fc(IL,e,t||{})}function ML(e,t){return fc(DL,e,t||{})}class $L{constructor(t){this.client=t,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(t){return this.client.mfa.enroll(Object.assign(Object.assign({},t),{factorType:"webauthn"}))}async _challenge({factorId:t,webauthn:n,friendlyName:r,signal:s},i){try{const{data:o,error:a}=await this.client.mfa.challenge({factorId:t,webauthn:n});if(!o)return{data:null,error:a};const l=s??CL.createNewAbortSignal();if(o.webauthn.type==="create"){const{user:c}=o.webauthn.credential_options.publicKey;c.name||(c.name=`${c.id}:${r}`),c.displayName||(c.displayName=c.name)}switch(o.webauthn.type){case"create":{const c=LL(o.webauthn.credential_options.publicKey,i==null?void 0:i.create),{data:u,error:d}=await NL({publicKey:c,signal:l});return u?{data:{factorId:t,challengeId:o.id,webauthn:{type:o.webauthn.type,credential_response:u}},error:null}:{data:null,error:d}}case"request":{const c=ML(o.webauthn.credential_options.publicKey,i==null?void 0:i.request),{data:u,error:d}=await OL(Object.assign(Object.assign({},o.webauthn.credential_options),{publicKey:c,signal:l}));return u?{data:{factorId:t,challengeId:o.id,webauthn:{type:o.webauthn.type,credential_response:u}},error:null}:{data:null,error:d}}}}catch(o){return F(o)?{data:null,error:o}:{data:null,error:new qr("Unexpected error in challenge",o)}}}async _verify({challengeId:t,factorId:n,webauthn:r}){return this.client.mfa.verify({factorId:n,challengeId:t,webauthn:r})}async _authenticate({factorId:t,webauthn:{rpId:n=typeof window<"u"?window.location.hostname:void 0,rpOrigins:r=typeof window<"u"?[window.location.origin]:void 0,signal:s}={}},i){if(!n)return{data:null,error:new sa("rpId is required for WebAuthn authentication")};
254try{if(!Sv())return{data:null,error:new qr("Browser does not support WebAuthn",null)};const{data:o,error:a}=await this.challenge({factorId:t,webauthn:{rpId:n,rpOrigins:r},signal:s},{request:i});if(!o)return{data:null,error:a};const{webauthn:l}=o;return this._verify({factorId:t,challengeId:o.challengeId,webauthn:{type:l.type,rpId:n,rpOrigins:r,credential_response:l.credential_response}})}catch(o){return F(o)?{data:null,error:o}:{data:null,error:new qr("Unexpected error in authenticate",o)}}}async _register({friendlyName:t,webauthn:{rpId:n=typeof window<"u"?window.location.hostname:void 0,rpOrigins:r=typeof window<"u"?[window.location.origin]:void 0,signal:s}={}},i){if(!n)return{data:null,error:new sa("rpId is required for WebAuthn registration")};try{if(!Sv())return{data:null,error:new qr("Browser does not support WebAuthn",null)};const{data:o,error:a}=await this._enroll({friendlyName:t});if(!o)return await this.client.mfa.listFactors().then(u=>{var d;return(d=u.data)===null||d===void 0?void 0:d.all.find(h=>h.factor_type==="webauthn"&&h.friendly_name===t&&h.status!=="unverified")}).then(u=>u?this.client.mfa.unenroll({factorId:u==null?void 0:u.id}):void 0),{data:null,error:a};const{data:l,error:c}=await this._challenge({factorId:o.id,friendlyName:o.friendly_name,webauthn:{rpId:n,rpOrigins:r},signal:s},{create:i});return l?this._verify({factorId:o.id,challengeId:l.challengeId,webauthn:{rpId:n,rpOrigins:r,type:l.webauthn.type,credential_response:l.webauthn.credential_response}}):{data:null,error:c}}catch(o){return F(o)?{data:null,error:o}:{data:null,error:new qr("Unexpected error in register",o)}}}}xL();const VL={url:DD,storageKey:LD,autoRefreshToken:!0,persistSession:!0,detectSessionInUrl:!0,headers:MD,flowType:"implicit",debug:!1,hasCustomAuthorizationHeader:!1,throwOnError:!1,lockAcquireTimeout:1e4};async function _v(e,t,n){return await n()}const Ns={};class ia{get jwks(){var t,n;return(n=(t=Ns[this.storageKey])===null||t===void 0?void 0:t.jwks)!==null&&n!==void 0?n:{keys:[]}}set jwks(t){Ns[this.storageKey]=Object.assign(Object.assign({},Ns[this.storageKey]),{jwks:t})}get jwks_cached_at(){var t,n;return(n=(t=Ns[this.storageKey])===null||t===void 0?void 0:t.cachedAt)!==null&&n!==void 0?n:Number.MIN_SAFE_INTEGER}set jwks_cached_at(t){Ns[this.storageKey]=Object.assign(Object.assign({},Ns[this.storageKey]),{cachedAt:t})}constructor(t){var n,r,s;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 i=Object.assign(Object.assign({},VL),t);if(this.storageKey=i.storageKey,this.instanceID=(n=ia.nextInstanceID[this.storageKey])!==null&&n!==void 0?n:0,ia.nextInstanceID[this.storageKey]=this.instanceID+1,this.logDebugMessages=!!i.debug,typeof i.debug=="function"&&(this.logger=i.debug),this.instanceID>0&&Be()){const o=`${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(o),this.logDebugMessages&&console.trace(o)}if(this.persistSession=i.persistSession,this.autoRefreshToken=i.autoRefreshToken,this.admin=new yL({url:i.url,headers:i.headers,fetch:i.fetch}),this.url=i.url,this.headers=i.headers,this.fetch=LS(i.fetch),this.lock=i.lock||_v,this.detectSessionInUrl=i.detectSessionInUrl,this.flowType=i.flowType,this.hasCustomAuthorizationHeader=i.hasCustomAuthorizationHeader,this.throwOnError=i.throwOnError,this.lockAcquireTimeout=i.lockAcquireTimeout,i.lock?this.lock=i.lock:this.persistSession&&Be()&&(!((r=globalThis==null?void 0:globalThis.navigator)===null||r===void 0)&&r.locks)?this.lock=wL:this.lock=_v,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 $L(this)}
254,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?(i.storage?this.storage=i.storage:DS()?this.storage=globalThis.localStorage:(this.memoryStorage={},this.storage=bv(this.memoryStorage)),i.userStorage&&(this.userStorage=i.userStorage)):(this.memoryStorage={},this.storage=bv(this.memoryStorage)),Be()&&globalThis.BroadcastChannel&&this.persistSession&&this.storageKey){try{this.broadcastChannel=new globalThis.BroadcastChannel(this.storageKey)}catch(o){console.error("Failed to create a new BroadcastChannel, multi-tab state changes will not be available",o)}(s=this.broadcastChannel)===null||s===void 0||s.addEventListener("message",async o=>{this._debug("received broadcast notification from other tab or client",o);try{await this._notifyAllSubscribers(o.data.event,o.data.session,!1)}catch(a){this._debug("#broadcastChannel","error",a)}})}this.initialize().catch(o=>{this._debug("#initialize()","error",o)})}isThrowOnErrorEnabled(){return this.throwOnError}_returnResult(t){if(this.throwOnError&&t&&t.error)throw t.error;return t}_logPrefix(){return`GoTrueClient@${this.storageKey}:${this.instanceID} (${NS}) ${new Date().toISOString()}`}_debug(...t){return this.logDebugMessages&&this.logger(this._logPrefix(),...t),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 t;try{let n={},r="none";if(Be()&&(n=JD(window.location.href),this._isImplicitGrantCallback(n)?r="implicit":await this._isPKCECallback(n)&&(r="pkce")),Be()&&this.detectSessionInUrl&&r!=="none"){const{data:s,error:i}=await this._getSessionFromURL(n,r);if(i){if(this._debug("#_initialize()","error detecting session from URL",i),BD(i)){const l=(t=i.details)===null||t===void 0?void 0:t.code;if(l==="identity_already_exists"||l==="identity_not_found"||l==="single_identity_not_deletable")return{error:i}}return{error:i}}const{session:o,redirectType:a}=s;return this._debug("#_initialize()","detected session in URL",o,"redirect type",a),await this._saveSession(o),setTimeout(async()=>{a==="recovery"?await this._notifyAllSubscribers("PASSWORD_RECOVERY",o):await this._notifyAllSubscribers("SIGNED_IN",o)},0),{error:null}}return await this._recoverAndRefresh(),{error:null}}catch(n){return F(n)?this._returnResult({error:n}):this._returnResult({error:new qr("Unexpected error during initialization",n)})}finally{await this._handleVisibilityChange(),this._debug("#_initialize()","end")}}async signInAnonymously(t){var n,r,s;try{const i=await z(this.fetch,"POST",`${this.url}/signup`,{headers:this.headers,body:{data:(r=(n=t==null?void 0:t.options)===null||n===void 0?void 0:n.data)!==null&&r!==void 0?r:{},gotrue_meta_security:{captcha_token:(s=t==null?void 0:t.options)===null||s===void 0?void 0:s.captchaToken}},xform:Wt}),{data:o,error:a}=i;if(a||!o)return this._returnResult({data:{user:null,session:null},error:a});const l=o.session,c=o.user;return o.session&&(await this._saveSession(o.session),await this._notifyAllSubscribers("SIGNED_IN",l)),this._returnResult({data:{user:c,session:l},error:null})}catch(i){if(F(i))return this._returnResult({data:{user:null,session:null},error:i});throw i}}async signUp(t){var n,r,s;try{let i;if("email"in t){const{email:u,password:d,options:h}=t;let f=null,w=null;this.flowType==="pkce"&&([f,w]=await As(this.storage,this.storageKey)),i=await z(this.fetch,"POST",`${this.url}/signup`,{headers:this.headers,redirectTo:h==null?void 0:h.emailRedirectTo,body:{email:u,password:d,data:(n=h==null?void 0:h.data)!==null&&n!==void 0?n:{},gotrue_meta_security:{captcha_token:h==null?void 0:h.captchaToken},code_challenge:f,code_challenge_method:w},xform:Wt})}else if("phone"in t){const{phone:u,password:d,options:h}=t;i=await z(this.fetch,"POST",`${this.url}/signup`,{headers:this.headers,body:{phone:u,password:d,data:(r=h==null?void 0:h.data)!==null&&r!==void 0?r:{},channel:(s=h==null?void 0:h.channel)!==null&&s!==void 0?s:"sms",gotrue_meta_security:{captcha_token:h==null?void 0:h.captchaToken}},xform:Wt})}else throw new rl("You must provide either an email or phone number and a password");const{data:o,error:a}=i;if(a||!o)return await Fe(this.storage,`${this.storageKey}-code-verifier`),this._returnResult({data:{user:null,session:null},error:a});const l=o.session,c=o.user;return o.session&&(await this._saveSession(o.session),await this._notifyAllSubscribers("SIGNED_IN",l)),this._returnResult({data:{user:c,session:l},error:null})}catch(i){if(await Fe(this.storage,`${this.storageKey}-code-verifier`),F(i))return this._returnResult({data:{user:null,session:null},error:i});throw i}}async signInWithPassword(t){try{let n;if("email"in t){const{email:i,password:o,options:a}=t;n=await z(this.fetch,"POST",`${this.url}/token?grant_type=password`,{headers:this.headers,body:{email:i,password:o,gotrue_meta_security:{captcha_token:a==null?void 0:a.captchaToken}},xform:wv})}else if("phone"in t){const{phone:i,password:o,options:a}=t;n=await z(this.fetch,"POST",`${this.url}/token?grant_type=password`,{headers:this.headers,body:{phone:i,password:o,gotrue_meta_security:{captcha_token:a==null?void 0:a.captchaToken}},xform:wv})}else throw new rl("You must provide either an email or phone number and a password");const{data:r,error:s}=n;if(s)return this._returnResult({data:{user:null,session:null},error:s});if(!r||!r.session||!r.user){const i=new Ps;return this._returnResult({data:{user:null,session:null},error:i})}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:s})}catch(n){if(F(n))return this._returnResult({data:{user:null,session:null},error:n});throw n}}async signInWithOAuth(t){var n,r,s,i;return await this._handleProviderSignIn(t.provider,{redirectTo:(n=t.options)===null||n===void 0?void 0:n.redirectTo,scopes:(r=t.options)===null||r===void 0?void 0:r.scopes,queryParams:(s=t.options)===null||s===void 0?void 0:s.queryParams,skipBrowserRedirect:(i=t.options)===null||i===void 0?void 0:i.skipBrowserRedirect})}async exchangeCodeForSession(t){return await this.initializePromise,this._acquireLock(this.lockAcquireTimeout,async()=>this._exchangeCodeForSession(t))}async signInWithWeb3(t){const{chain:n}=t;switch(n){case"ethereum":return await this.signInWithEthereum(t);case"solana":return await this.signInWithSolana(t);default:throw new Error(`@supabase/auth-js: Unsupported chain "${n}"`)}}async signInWithEthereum(t){var n,r,s,i,o,a,l,c,u,d,h;let f,w;if("message"in t)f=t.message,w=t.signature;else{const{chain:y,wallet:x,statement:m,options:g}=t;let v;if(Be())if(typeof x=="object")v=x;else{const j=window;if("ethereum"in j&&typeof j.ethereum=="object"&&"request"in j.ethereum&&typeof j.ethereum.request=="function")v=j.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 x!="object"||!(g!=null&&g.url))throw new Error("@supabase/auth-js: Both wallet and url must be specified in non-browser environments.");v=x}const S=new URL((n=g==null?void 0:g.url)!==null&&n!==void 0?n:window.location.href),_=await v.request({method:"eth_requestAccounts"}).then(j=>j).catch(()=>{throw new Error("@supabase/auth-js: Wallet method eth_requestAccounts is missing or invalid")});if(!_||_.length===0)throw new Error("@supabase/auth-js: No accounts available. Please ensure the wallet is connected.");const k=$S(_[0]);let E=(r=g==null?void 0:g.signInWithEthereum)===null||r===void 0?void 0:r.chainId;if(!E){const j=await v.request({method:"eth_chainId"});E=bL(j)}const T={domain:S.host,address:k,statement:m,uri:S.href,version:"1",chainId:E,nonce:(s=g==null?void 0:g.signInWithEthereum)===null||s===void 0?void 0:s.nonce,issuedAt:(o=(i=g==null?void 0:g.signInWithEthereum)===null||i===void 0?void 0:i.issuedAt)!==null&&o!==void 0?o:new Date,expirationTime:(a=g==null?void 0:g.signInWithEthereum)===null||a===void 0?void 0:a.expirationTime,notBefore:(l=g==null?void 0:g.signInWithEthereum)===null||l===void 0?void 0:l.notBefore,requestId:(c=g==null?void 0:g.signInWithEthereum)===null||c===void 0?void 0:c.requestId,resources:(u=g==null?void 0:g.signInWithEthereum)===null||u===void 0?void 0:u.resources};f=_L(T),w=await v.request({method:"personal_sign",params:[SL(f),k]})}try{const{data:y,error:x}=await z(this.fetch,"POST",`${this.url}/token?grant_type=web3`,{headers:this.headers,body:Object.assign({chain:"ethereum",message:f,signature:w},!((d=t.options)===null||d===void 0)&&d.captchaToken?{gotrue_meta_security:{captcha_token:(h=t.options)===null||h===void 0?void 0:h.captchaToken}}:null),xform:Wt});if(x)throw x;if(!y||!y.session||!y.user){const m=new Ps;return this._returnResult({data:{user:null,session:null},error:m})}return y.session&&(await this._saveSession(y.session),await this._notifyAllSubscribers("SIGNED_IN",y.session)),this._returnResult({data:Object.assign({},y),error:x})}catch(y){if(F(y))return this._returnResult({data:{user:null,session:null},error:y});throw y}}async signInWithSolana(t){var n,r,s,i,o,a,l,c,u,d,h,f;let w,y;if("message"in t)w=t.message,y=t.signature;else{const{chain:x,wallet:m,statement:g,options:v}=t;let S;if(Be())if(typeof m=="object")S=m;
254else{const k=window;if("solana"in k&&typeof k.solana=="object"&&("signIn"in k.solana&&typeof k.solana.signIn=="function"||"signMessage"in k.solana&&typeof k.solana.signMessage=="function"))S=k.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 m!="object"||!(v!=null&&v.url))throw new Error("@supabase/auth-js: Both wallet and url must be specified in non-browser environments.");S=m}const _=new URL((n=v==null?void 0:v.url)!==null&&n!==void 0?n:window.location.href);if("signIn"in S&&S.signIn){const k=await S.signIn(Object.assign(Object.assign(Object.assign({issuedAt:new Date().toISOString()},v==null?void 0:v.signInWithSolana),{version:"1",domain:_.host,uri:_.href}),g?{statement:g}:null));let E;if(Array.isArray(k)&&k[0]&&typeof k[0]=="object")E=k[0];else if(k&&typeof k=="object"&&"signedMessage"in k&&"signature"in k)E=k;else throw new Error("@supabase/auth-js: Wallet method signIn() returned unrecognized value");if("signedMessage"in E&&"signature"in E&&(typeof E.signedMessage=="string"||E.signedMessage instanceof Uint8Array)&&E.signature instanceof Uint8Array)w=typeof E.signedMessage=="string"?E.signedMessage:new TextDecoder().decode(E.signedMessage),y=E.signature;else throw new Error("@supabase/auth-js: Wallet method signIn() API returned object without signedMessage and signature fields")}else{if(!("signMessage"in S)||typeof S.signMessage!="function"||!("publicKey"in S)||typeof S!="object"||!S.publicKey||!("toBase58"in S.publicKey)||typeof S.publicKey.toBase58!="function")throw new Error("@supabase/auth-js: Wallet does not have a compatible signMessage() and publicKey.toBase58() API");w=[`${_.host} wants you to sign in with your Solana account:`,S.publicKey.toBase58(),...g?["",g,""]:[""],"Version: 1",`URI: ${_.href}`,`Issued At: ${(s=(r=v==null?void 0:v.signInWithSolana)===null||r===void 0?void 0:r.issuedAt)!==null&&s!==void 0?s:new Date().toISOString()}`,...!((i=v==null?void 0:v.signInWithSolana)===null||i===void 0)&&i.notBefore?[`Not Before: ${v.signInWithSolana.notBefore}`]:[],...!((o=v==null?void 0:v.signInWithSolana)===null||o===void 0)&&o.expirationTime?[`Expiration Time: ${v.signInWithSolana.expirationTime}`]:[],...!((a=v==null?void 0:v.signInWithSolana)===null||a===void 0)&&a.chainId?[`Chain ID: ${v.signInWithSolana.chainId}`]:[],...!((l=v==null?void 0:v.signInWithSolana)===null||l===void 0)&&l.nonce?[`Nonce: ${v.signInWithSolana.nonce}`]:[],...!((c=v==null?void 0:v.signInWithSolana)===null||c===void 0)&&c.requestId?[`Request ID: ${v.signInWithSolana.requestId}`]:[],...!((d=(u=v==null?void 0:v.signInWithSolana)===null||u===void 0?void 0:u.resources)===null||d===void 0)&&d.length?["Resources",...v.signInWithSolana.resources.map(E=>`- ${E}`)]:[]].join(` 255`);const k=await S.signMessage(new TextEncoder().encode(w),"utf8");if(!k||!(k instanceof Uint8Array))throw new Error("@supabase/auth-js: Wallet signMessage() API returned an recognized value");y=k}}try{const{data:x,error:m}=await z(this.fetch,"POST",`${this.url}/token?grant_type=web3`,{headers:this.headers,body:Object.assign({chain:"solana",message:w,signature:Zr(y)},!((h=t.options)===null||h===void 0)&&h.captchaToken?{gotrue_meta_security:{captcha_token:(f=t.options)===null||f===void 0?void 0:f.captchaToken}}:null),xform:Wt});if(m)throw m;if(!x||!x.session||!x.user){const g=new Ps;return this._returnResult({data:{user:null,session:null},error:g})}return x.session&&(await this._saveSession(x.session),await this._notifyAllSubscribers("SIGNED_IN",x.session)),this._returnResult({data:Object.assign({},x),error:m})}catch(x){if(F(x))return this._returnResult({data:{user:null,session:null},error:x});throw x}}async _exchangeCodeForSession(t){const n=await Vr(this.storage,`${this.storageKey}-code-verifier`),[r,s]=(n??"").split("/");try{if(!r&&this.flowType==="pkce")throw new zD;const{data:i,error:o}=await z(this.fetch,"POST",`${this.url}/token?grant_type=pkce`,{headers:this.headers,body:{auth_code:t,code_verifier:r},xform:Wt});if(await Fe(this.storage,`${this.storageKey}-code-verifier`),o)throw o;if(!i||!i.session||!i.user){const a=new Ps;return this._returnResult({data:{user:null,session:null,redirectType:null},error:a})}return i.session&&(await this._saveSession(i.session),await this._notifyAllSubscribers("SIGNED_IN",i.session)),this._returnResult({data:Object.assign(Object.assign({},i),{redirectType:s??null}),error:o})}catch(i){if(await Fe(this.storage,`${this.storageKey}-code-verifier`),F(i))return this._returnResult({data:{user:null,session:null,redirectType:null},error:i});throw i}}async signInWithIdToken(t){try{const{options:n,provider:r,token:s,access_token:i,nonce:o}=t,a=await z(this.fetch,"POST",`${this.url}/token?grant_type=id_token`,{headers:this.headers,body:{provider:r,id_token:s,access_token:i,nonce:o,gotrue_meta_security:{captcha_token:n==null?void 0:n.captchaToken}},xform:Wt}),{data:l,error:c}=a;if(c)return this._returnResult({data:{user:null,session:null},error:c});if(!l||!l.session||!l.user){const u=new Ps;return this._returnResult({data:{user:null,session:null},error:u})}return l.session&&(await this._saveSession(l.session),await this._notifyAllSubscribers("SIGNED_IN",l.session)),this._returnResult({data:l,error:c})}catch(n){if(F(n))return this._returnResult({data:{user:null,session:null},error:n});throw n}}async signInWithOtp(t){var n,r,s,i,o;try{if("email"in t){const{email:a,options:l}=t;
255let c=null,u=null;this.flowType==="pkce"&&([c,u]=await As(this.storage,this.storageKey));const{error:d}=await z(this.fetch,"POST",`${this.url}/otp`,{headers:this.headers,body:{email:a,data:(n=l==null?void 0:l.data)!==null&&n!==void 0?n:{},create_user:(r=l==null?void 0:l.shouldCreateUser)!==null&&r!==void 0?r:!0,gotrue_meta_security:{captcha_token:l==null?void 0:l.captchaToken},code_challenge:c,code_challenge_method:u},redirectTo:l==null?void 0:l.emailRedirectTo});return this._returnResult({data:{user:null,session:null},error:d})}if("phone"in t){const{phone:a,options:l}=t,{data:c,error:u}=await z(this.fetch,"POST",`${this.url}/otp`,{headers:this.headers,body:{phone:a,data:(s=l==null?void 0:l.data)!==null&&s!==void 0?s:{},create_user:(i=l==null?void 0:l.shouldCreateUser)!==null&&i!==void 0?i:!0,gotrue_meta_security:{captcha_token:l==null?void 0:l.captchaToken},channel:(o=l==null?void 0:l.channel)!==null&&o!==void 0?o:"sms"}});return this._returnResult({data:{user:null,session:null,messageId:c==null?void 0:c.message_id},error:u})}throw new rl("You must provide either an email or phone number.")}catch(a){if(await Fe(this.storage,`${this.storageKey}-code-verifier`),F(a))return this._returnResult({data:{user:null,session:null},error:a});throw a}}async verifyOtp(t){var n,r;try{let s,i;"options"in t&&(s=(n=t.options)===null||n===void 0?void 0:n.redirectTo,i=(r=t.options)===null||r===void 0?void 0:r.captchaToken);const{data:o,error:a}=await z(this.fetch,"POST",`${this.url}/verify`,{headers:this.headers,body:Object.assign(Object.assign({},t),{gotrue_meta_security:{captcha_token:i}}),redirectTo:s,xform:Wt});if(a)throw a;if(!o)throw new Error("An error occurred on token verification.");const l=o.session,c=o.user;return l!=null&&l.access_token&&(await this._saveSession(l),await this._notifyAllSubscribers(t.type=="recovery"?"PASSWORD_RECOVERY":"SIGNED_IN",l)),this._returnResult({data:{user:c,session:l},error:null})}catch(s){if(F(s))return this._returnResult({data:{user:null,session:null},error:s});throw s}}async signInWithSSO(t){var n,r,s,i,o;try{let a=null,l=null;this.flowType==="pkce"&&([a,l]=await As(this.storage,this.storageKey));const c=await z(this.fetch,"POST",`${this.url}/sso`,{body:Object.assign(Object.assign(Object.assign(Object.assign(Object.assign({},"providerId"in t?{provider_id:t.providerId}:null),"domain"in t?{domain:t.domain}:null),{redirect_to:(r=(n=t.options)===null||n===void 0?void 0:n.redirectTo)!==null&&r!==void 0?r:void 0}),!((s=t==null?void 0:t.options)===null||s===void 0)&&s.captchaToken?{gotrue_meta_security:{captcha_token:t.options.captchaToken}}:null),{skip_http_redirect:!0,code_challenge:a,code_challenge_method:l}),headers:this.headers,xform:pL});return!((i=c.data)===null||i===void 0)&&i.url&&Be()&&!(!((o=t.options)===null||o===void 0)&&o.skipBrowserRedirect)&&window.location.assign(c.data.url),this._returnResult(c)}catch(a){if(await Fe(this.storage,`${this.storageKey}-code-verifier`),F(a))return this._returnResult({data:null,error:a});throw a}}async reauthenticate(){return await this.initializePromise,await this._acquireLock(this.lockAcquireTimeout,async()=>await this._reauthenticate())}async _reauthenticate(){try{return await this._useSession(async t=>{const{data:{session:n},error:r}=t;if(r)throw r;if(!n)throw new gt;const{error:s}=await z(this.fetch,"GET",`${this.url}/reauthenticate`,{headers:this.headers,jwt:n.access_token});return this._returnResult({data:{user:null,session:null},error:s})})}catch(t){if(F(t))return this._returnResult({data:{user:null,session:null},error:t});throw t}}async resend(t){try{const n=`${this.url}/resend`;if("email"in t){const{email:r,type:s,options:i}=t,{error:o}=await z(this.fetch,"POST",n,{headers:this.headers,body:{email:r,type:s,gotrue_meta_security:{captcha_token:i==null?void 0:i.captchaToken}},redirectTo:i==null?void 0:i.emailRedirectTo});return this._returnResult({data:{user:null,session:null},error:o})}else if("phone"in t){const{phone:r,type:s,options:i}=t,{data:o,error:a}=await z(this.fetch,"POST",n,{headers:this.headers,body:{phone:r,type:s,gotrue_meta_security:{captcha_token:i==null?void 0:i.captchaToken}}});return this._returnResult({data:{user:null,session:null,messageId:o==null?void 0:o.message_id},error:a})}throw new rl("You must provide either an email or phone number and a type")}catch(n){if(F(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(t,n){this._debug("#_acquireLock","begin",t);try{if(this.lockAcquired){const r=this.pendingInLock.length?this.pendingInLock[this.pendingInLock.length-1]:Promise.resolve(),s=(async()=>(await r,await n()))();return this.pendingInLock.push((async()=>{try{await s}catch{}})()),s}return await this.lock(`lock:${this.storageKey}`,t,async()=>{this._debug("#_acquireLock","lock acquired for storage key",this.storageKey);try{this.lockAcquired=!0;const r=n();for(this.pendingInLock.push((async()=>{try{await r}catch{}})()),await r;this.pendingInLock.length;){const s=[...this.pendingInLock];await Promise.all(s),this.pendingInLock.splice(0,s.length)}return await r}finally{this._debug("#_acquireLock","lock released for storage key",this.storageKey),this.lockAcquired=!1}})}finally{this._debug("#_acquireLock","end")}}async _useSession(t){this._debug("#_useSession","begin");try{const n=await this.__loadSession();return await t(n)}finally{this._debug("#_useSession","end")}}async __loadSession(){this._debug("#__loadSession()","begin"),this.lockAcquired||this._debug("#__loadSession()","used outside of an acquired lock!",new Error().stack);try{let t=null;const n=await Vr(this.storage,this.storageKey);if(this._debug("#getSession()","session from storage",n),n!==null&&(this._isValidSession(n)?t=n:(this._debug("#getSession()","session from storage is not val
255id"),await this._removeSession())),!t)return{data:{session:null},error:null};const r=t.expires_at?t.expires_at*1e3-Date.now()<Xu:!1;if(this._debug("#__loadSession()",`session has${r?"":" not"} expired`,"expires_at",t.expires_at),!r){if(this.userStorage){const o=await Vr(this.userStorage,this.storageKey+"-user");o!=null&&o.user?t.user=o.user:t.user=td()}if(this.storage.isServer&&t.user&&!t.user.__isUserNotAvailableProxy){const o={value:this.suppressGetSessionWarning};t.user=uL(t.user,o),o.value&&(this.suppressGetSessionWarning=!0)}return{data:{session:t},error:null}}const{data:s,error:i}=await this._callRefreshToken(t.refresh_token);return i?this._returnResult({data:{session:null},error:i}):this._returnResult({data:{session:s},error:null})}finally{this._debug("#__loadSession()","end")}}async getUser(t){if(t)return await this._getUser(t);await this.initializePromise;const n=await this._acquireLock(this.lockAcquireTimeout,async()=>await this._getUser());return n.data.user&&(this.suppressGetSessionWarning=!0),n}async _getUser(t){try{return t?await z(this.fetch,"GET",`${this.url}/user`,{headers:this.headers,jwt:t,xform:sr}):await this._useSession(async n=>{var r,s,i;const{data:o,error:a}=n;if(a)throw a;return!(!((r=o.session)===null||r===void 0)&&r.access_token)&&!this.hasCustomAuthorizationHeader?{data:{user:null},error:new gt}:await z(this.fetch,"GET",`${this.url}/user`,{headers:this.headers,jwt:(i=(s=o.session)===null||s===void 0?void 0:s.access_token)!==null&&i!==void 0?i:void 0,xform:sr})})}catch(n){if(F(n))return Zu(n)&&(await this._removeSession(),await Fe(this.storage,`${this.storageKey}-code-verifier`)),this._returnResult({data:{user:null},error:n});throw n}}async updateUser(t,n={}){return await this.initializePromise,await this._acquireLock(this.lockAcquireTimeout,async()=>await this._updateUser(t,n))}async _updateUser(t,n={}){try{return await this._useSession(async r=>{const{data:s,error:i}=r;if(i)throw i;if(!s.session)throw new gt;const o=s.session;let a=null,l=null;this.flowType==="pkce"&&t.email!=null&&([a,l]=await As(this.storage,this.storageKey));const{data:c,error:u}=await z(this.fetch,"PUT",`${this.url}/user`,{headers:this.headers,redirectTo:n==null?void 0:n.emailRedirectTo,body:Object.assign(Object.assign({},t),{code_challenge:a,code_challenge_method:l}),jwt:o.access_token,xform:sr});if(u)throw u;return o.user=c.user,await this._saveSession(o),await this._notifyAllSubscribers("USER_UPDATED",o),this._returnResult({data:{user:o.user},error:null})})}catch(r){if(await Fe(this.storage,`${this.storageKey}-code-verifier`),F(r))return this._returnResult({data:{user:null},error:r});throw r}}async setSession(t){return await this.initializePromise,await this._acquireLock(this.lockAcquireTimeout,async()=>await this._setSession(t))}async _setSession(t){try{if(!t.access_token||!t.refresh_token)throw new gt;const n=Date.now()/1e3;let r=n,s=!0,i=null;const{payload:o}=il(t.access_token);if(o.exp&&(r=o.exp,s=r<=n),s){const{data:a,error:l}=await this._callRefreshToken(t.refresh_token);if(l)return this._returnResult({data:{user:null,session:null},error:l});if(!a)return{data:{user:null,session:null},error:null};i=a}else{const{data:a,error:l}=await this._getUser(t.access_token);if(l)return this._returnResult({data:{user:null,session:null},error:l});i={access_token:t.access_token,refresh_token:t.refresh_token,user:a.user,token_type:"bearer",expires_in:r-n,expires_at:r},await this._saveSession(i),await this._notifyAllSubscribers("SIGNED_IN",i)}return this._returnResult({data:{user:i.user,session:i},error:null})}catch(n){if(F(n))return this._returnResult({data:{session:null,user:null},error:n});throw n}}async refreshSession(t){return await this.initializePromise,await this._acquireLock(this.lockAcquireTimeout,async()=>await this._refreshSession(t))}async _refreshSession(t){try{return await this._useSession(async n=>{var r;if(!t){const{data:o,error:a}=n;if(a)throw a;t=(r=o.session)!==null&&r!==void 0?r:void 0}if(!(t!=null&&t.refresh_token))throw new gt;const{data:s,error:i}=await this._callRefreshToken(t.refresh_token);return i?this._returnResult({data:{user:null,session:null},error:i}):s?this._returnResult({data:{user:s.user,session:s},error:null}):this._returnResult({data:{user:null,session:null},error:null})})}catch(n){if(F(n))return this._returnResult({data:{user:null,session:null},error:n});throw n}}async _getSessionFromURL(t,n){try{if(!Be())throw new sl("No browser detected.");
255if(t.error||t.error_description||t.error_code)throw new sl(t.error_description||"Error in URL with unspecified error_description",{error:t.error||"unspecified_error",code:t.error_code||"unspecified_code"});switch(n){case"implicit":if(this.flowType==="pkce")throw new hv("Not a valid PKCE flow url.");break;case"pkce":if(this.flowType==="implicit")throw new sl("Not a valid implicit grant flow url.");break;default:}if(n==="pkce"){if(this._debug("#_initialize()","begin","is PKCE flow",!0),!t.code)throw new hv("No code detected.");const{data:g,error:v}=await this._exchangeCodeForSession(t.code);if(v)throw v;const S=new URL(window.location.href);return S.searchParams.delete("code"),window.history.replaceState(window.history.state,"",S.toString()),{data:{session:g.session,redirectType:null},error:null}}const{provider_token:r,provider_refresh_token:s,access_token:i,refresh_token:o,expires_in:a,expires_at:l,token_type:c}=t;if(!i||!a||!o||!c)throw new sl("No session defined in URL");const u=Math.round(Date.now()/1e3),d=parseInt(a);let h=u+d;l&&(h=parseInt(l));const f=h-u;f*1e3<=Ls&&console.warn(`@supabase/gotrue-js: Session as retrieved from URL expires in ${f}s, should have been closer to ${d}s`);const w=h-d;u-w>=120?console.warn("@supabase/gotrue-js: Session as retrieved from URL was issued over 120s ago, URL could be stale",w,h,u):u-w<0&&console.warn("@supabase/gotrue-js: Session as retrieved from URL was issued in the future? Check the device clock for skew",w,h,u);const{data:y,error:x}=await this._getUser(i);if(x)throw x;const m={provider_token:r,provider_refresh_token:s,access_token:i,expires_in:d,expires_at:h,refresh_token:o,token_type:c,user:y.user};return window.location.hash="",this._debug("#_getSessionFromURL()","clearing window.location.hash"),this._returnResult({data:{session:m,redirectType:t.type},error:null})}catch(r){if(F(r))return this._returnResult({data:{session:null,redirectType:null},error:r});throw r}}_isImplicitGrantCallback(t){return typeof this.detectSessionInUrl=="function"?this.detectSessionInUrl(new URL(window.location.href),t):!!(t.access_token||t.error_description)}async _isPKCECallback(t){const n=await Vr(this.storage,`${this.storageKey}-code-verifier`);return!!(t.code&&n)}async signOut(t={scope:"global"}){return await this.initializePromise,await this._acquireLock(this.lockAcquireTimeout,async()=>await this._signOut(t))}async _signOut({scope:t}={scope:"global"}){return await this._useSession(async n=>{var r;const{data:s,error:i}=n;if(i&&!Zu(i))return this._returnResult({error:i});const o=(r=s.session)===null||r===void 0?void 0:r.access_token;if(o){const{error:a}=await this.admin.signOut(o,t);if(a&&!(UD(a)&&(a.status===404||a.status===401||a.status===403)||Zu(a)))return this._returnResult({error:a})}return t!=="others"&&(await this._removeSession(),await Fe(this.storage,`${this.storageKey}-code-verifier`)),this._returnResult({error:null})})}onAuthStateChange(t){const n=QD(),r={id:n,callback:t,unsubscribe:()=>{this._debug("#unsubscribe()","state change callback with id removed",n),this.stateChangeEmitters.delete(n)}};return this._debug("#onAuthStateChange()","registered callback with id",n),this.stateChangeEmitters.set(n,r),(async()=>(await this.initializePromise,await this._acquireLock(this.lockAcquireTimeout,async()=>{this._emitInitialSession(n)})))(),{data:{subscription:r}}}async _emitInitialSession(t){return await this._useSession(async n=>{var r,s;try{const{data:{session:i},error:o}=n;if(o)throw o;await((r=this.stateChangeEmitters.get(t))===null||r===void 0?void 0:r.callback("INITIAL_SESSION",i)),this._debug("INITIAL_SESSION","callback id",t,"session",i)}catch(i){await((s=this.stateChangeEmitters.get(t))===null||s===void 0?void 0:s.callback("INITIAL_SESSION",null)),this._debug("INITIAL_SESSION","callback id",t,"error",i),console.error(i)}})}async resetPasswordForEmail(t,n={}){let r=null,s=null;this.flowType==="pkce"&&([r,s]=await As(this.storage,this.storageKey,!0));try{return await z(this.fetch,"POST",`${this.url}/recover`,{body:{email:t,code_challenge:r,code_challenge_method:s,gotrue_meta_security:{captcha_token:n.captchaToken}},headers:this.headers,redirectTo:n.redirectTo})}catch(i){if(await Fe(this.storage,`${this.storageKey}-code-verifier`),F(i))return this._returnResult({data:null,error:i});throw i}}async getUserIdentities(){var t;try{const{data:n,error:r}=await this.getUser();if(r)throw r;return this._returnResult({data:{identities:(t=n.user.identities)!==null&&t!==void 0?t:[]},error:null})}catch(n){if(F(n))return this._returnResult({data:null,error:n});throw n}}async linkIdentity(t){return"token"in t?this.linkIdentityIdToken(t):this.linkIdentityOAuth(t)}async linkIdentityOAuth(t){var n;try{const{data:r,error:s}=await this._useSession(async i=>{var o,a,l,c,u;const{data:d,error:h}=i;if(h)throw h;const f=await this._getUrlForProvider(`${this.url}/user/identities/authorize`,t.provider,{redirectTo:(o=t.options)===null||o===void 0?void 0:o.redirectTo,scopes:(a=t.options)===null||a===void 0?void 0:a.scopes,queryParams:(l=t.options)===null||l===void 0?void 0:l.queryParams,skipBrowserRedirect:!0});return await z(this.fetch,"GET",f,{headers:this.headers,jwt:(u=(c=d.session)===null||c===void 0?void 0:c.access_token)!==null&&u!==void 0?u:void 0})});if(s)throw s;return Be()&&!(!((n=t.options)===null||n===void 0)&&n.skipBrowserRedirect)&&window.location.assign(r==null?void 0:r.url),this._returnResult({data:{provider:t.provider,url:r==null?void 0:r.url},error:null})}catch(r){if(F(r))return this._returnResult({data:{provider:t.provider,url:null},error:r});throw r}}async linkIdentityIdToken(t){return await this._useSession(async n=>{var r;try{const{error:s,data:{session:i}}=n;
255if(s)throw s;const{options:o,provider:a,token:l,access_token:c,nonce:u}=t,d=await z(this.fetch,"POST",`${this.url}/token?grant_type=id_token`,{headers:this.headers,jwt:(r=i==null?void 0:i.access_token)!==null&&r!==void 0?r:void 0,body:{provider:a,id_token:l,access_token:c,nonce:u,link_identity:!0,gotrue_meta_security:{captcha_token:o==null?void 0:o.captchaToken}},xform:Wt}),{data:h,error:f}=d;return f?this._returnResult({data:{user:null,session:null},error:f}):!h||!h.session||!h.user?this._returnResult({data:{user:null,session:null},error:new Ps}):(h.session&&(await this._saveSession(h.session),await this._notifyAllSubscribers("USER_UPDATED",h.session)),this._returnResult({data:h,error:f}))}catch(s){if(await Fe(this.storage,`${this.storageKey}-code-verifier`),F(s))return this._returnResult({data:{user:null,session:null},error:s});throw s}})}async unlinkIdentity(t){try{return await this._useSession(async n=>{var r,s;const{data:i,error:o}=n;if(o)throw o;return await z(this.fetch,"DELETE",`${this.url}/user/identities/${t.identity_id}`,{headers:this.headers,jwt:(s=(r=i.session)===null||r===void 0?void 0:r.access_token)!==null&&s!==void 0?s:void 0})})}catch(n){if(F(n))return this._returnResult({data:null,error:n});throw n}}async _refreshAccessToken(t){const n=`#_refreshAccessToken(${t.substring(0,5)}...)`;this._debug(n,"begin");try{const r=Date.now();return await eL(async s=>(s>
2550&&await ZD(200*Math.pow(2,s-1)),this._debug(n,"refreshing attempt",s),await z(this.fetch,"POST",`${this.url}/token?grant_type=refresh_token`,{body:{refresh_token:t},headers:this.headers,xform:Wt})),(s,i)=>{const o=200*Math.pow(2,s);return i&&ed(i)&&Date.now()+o-r<Ls})}catch(r){if(this._debug(n,"error",r),F(r))return this._returnResult({data:{session:null,user:null},error:r});throw r}finally{this._debug(n,"end")}}_isValidSession(t){return typeof t=="object"&&t!==null&&"access_token"in t&&"refresh_token"in t&&"expires_at"in t}async _handleProviderSignIn(t,n){const r=await this._getUrlForProvider(`${this.url}/authorize`,t,{redirectTo:n.redirectTo,scopes:n.scopes,queryParams:n.queryParams});return this._debug("#_handleProviderSignIn()","provider",t,"options",n,"url",r),Be()&&!n.skipBrowserRedirect&&window.location.assign(r),{data:{provider:t,url:r},error:null}}async _recoverAndRefresh(){var t,n;const r="#_recoverAndRefresh()";this._debug(r,"begin");try{const s=await Vr(this.storage,this.storageKey);if(s&&this.userStorage){let o=await Vr(this.userStorage,this.storageKey+"-user");!this.storage.isServer&&Object.is(this.storage,this.userStorage)&&!o&&(o={user:s.user},await Ms(this.userStorage,this.storageKey+"-user",o)),s.user=(t=o==null?void 0:o.user)!==null&&t!==void 0?t:td()}else if(s&&!s.user&&!s.user){const o=await Vr(this.storage,this.storageKey+"-user");o&&(o!=null&&o.user)?(s.user=o.user,await Fe(this.storage,this.storageKey+"-user"),await Ms(this.storage,this.storageKey,s)):s.user=td()}if(this._debug(r,"session from storage",s),!this._isValidSession(s)){this._debug(r,"session is not valid"),s!==null&&await this._removeSession();return}const i=((n=s.expires_at)!==null&&n!==void 0?n:1/0)*1e3-Date.now()<Xu;if(this._debug(r,`session has${i?"":" not"} expired with margin of ${Xu}s`),i){if(this.autoRefreshToken&&s.refresh_token){const{error:o}=await this._callRefreshToken(s.refresh_token);o&&(console.error(o),ed(o)||(this._debug(r,"refresh failed with a non-retryable error, removing the session",o),await this._removeSession()))}}else if(s.user&&s.user.__isUserNotAvailableProxy===!0)try{const{data:o,error:a}=await this._getUser(s.access_token);!a&&(o!=null&&o.user)?(s.user=o.user,await this._saveSession(s),await this._notifyAllSubscribers("SIGNED_IN",s)):this._debug(r,"could not get user data, skipping SIGNED_IN notification")}catch(o){console.error("Error getting user data:",o),this._debug(r,"error getting user data, skipping SIGNED_IN notification",o)}else await this._notifyAllSubscribers("SIGNED_IN",s)}catch(s){this._debug(r,"error",s),console.error(s);return}finally{this._debug(r,"end")}}async _callRefreshToken(t){var n,r;if(!t)throw new gt;if(this.refreshingDeferred)return this.refreshingDeferred.promise;const s=`#_callRefreshToken(${t.substring(0,5)}...)`;this._debug(s,"begin");try{this.refreshingDeferred=new Yc;const{data:i,error:o}=await this._refreshAccessToken(t);if(o)throw o;if(!i.session)throw new gt;await this._saveSession(i.session),await this._notifyAllSubscribers("TOKEN_REFRESHED",i.session);const a={data:i.session,error:null};return this.refreshingDeferred.resolve(a),a}catch(i){if(this._debug(s,"error",i),F(i)){const o={data:null,error:i};return ed(i)||await this._removeSession(),(n=this.refreshingDeferred)===null||n===void 0||n.resolve(o),o}throw(r=this.refreshingDeferred)===null||r===void 0||r.reject(i),i}finally{this.refreshingDeferred=null,this._debug(s,"end")}}async _notifyAllSubscribers(t,n,r=!0){const s=`#_notifyAllSubscribers(${t})`;this._debug(s,"begin",n,`broadcast = ${r}`);try{this.broadcastChannel&&r&&this.broadcastChannel.postMessage({event:t,session:n});const i=[],o=Array.from(this.stateChangeEmitters.values()).map(async a=>{try{await a.callback(t,n)}catch(l){i.push(l)}});if(await Promise.all(o),i.length>0){for(let a=0;a<i.length;a+=1)console.error(i[a]);throw i[0]}}finally{this._debug(s,"end")}}async _saveSession(t){this._debug("#_saveSession()",t),this.suppressGetSessionWarning=!0,await Fe(this.storage,`${this.storageKey}-code-verifier`);const n=Object.assign({},t),r=n.user&&n.user.__isUserNotAvailableProxy===!0;if(this.userStorage){!r&&n.user&&await Ms(this.userStorage,this.storageKey+"-user",{user:n.user});const s=Object.assign({},n);delete s.user;const i=yv(s);await Ms(this.storage,this.storageKey,i)}else{const s=yv(n);await Ms(this.storage,this.storageKey,s)}}async _removeSession(){this._debug("#_removeSession()"),this.suppressGetSessionWarning=!1,await Fe(this.storage,this.storageKey),await Fe(this.storage,this.storageKey+"-code-verifier"),await Fe(this.storage,this.storageKey+"-user"),this.userStorage&&await Fe(this.userStorage,this.storageKey+"-user"),await this._notifyAllSubscribers("SIGNED_OUT",null)}_removeVisibilityChangedCallback(){this._debug("#_removeVisibilityChangedCallback()");const t=this.visibilityChangedCallback;this.visibilityChangedCallback=null;try{t&&Be()&&(window!=null&&window.removeEventListener)&&window.removeEventListener("visibilitychange",t)}
255catch(n){console.error("removing visibilitychange callback failed",n)}}async _startAutoRefresh(){await this._stopAutoRefresh(),this._debug("#_startAutoRefresh()");const t=setInterval(()=>this._autoRefreshTokenTick(),Ls);this.autoRefreshTicker=t,t&&typeof t=="object"&&typeof t.unref=="function"?t.unref():typeof Deno<"u"&&typeof Deno.unrefTimer=="function"&&Deno.unrefTimer(t);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 t=this.autoRefreshTicker;this.autoRefreshTicker=null,t&&clearInterval(t);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 t=Date.now();try{return await this._useSession(async n=>{const{data:{session:r}}=n;if(!r||!r.refresh_token||!r.expires_at){this._debug("#_autoRefreshTokenTick()","no session");return}const s=Math.floor((r.expires_at*1e3-t)/Ls);this._debug("#_autoRefreshTokenTick()",`access token expires in ${s} ticks, a tick lasts ${Ls}ms, refresh threshold is ${Fh} ticks`),s<=Fh&&await this._callRefreshToken(r.refresh_token)})}catch(n){console.error("Auto refresh tick failed with error. This is likely a transient error.",n)}}finally{this._debug("#_autoRefreshTokenTick()","end")}})}catch(t){if(t.isAcquireTimeout||t instanceof MS)this._debug("auto refresh token tick lock not available");else throw t}}async _handleVisibilityChange(){if(this._debug("#_handleVisibilityChange()"),!Be()||!(window!=null&&window.addEventListener))return this.autoRefreshToken&&this.startAutoRefresh(),!1;try{this.visibilityChangedCallback=async()=>{try{await this._onVisibilityChanged(!1)}catch(t){this._debug("#visibilityChangedCallback","error",t)}},window==null||window.addEventListener("visibilitychange",this.visibilityChangedCallback),await this._onVisibilityChanged(!0)}catch(t){console.error("_handleVisibilityChange",t)}}async _onVisibilityChanged(t){const n=`#_onVisibilityChanged(${t})`;this._debug(n,"visibilityState",document.visibilityState),document.visibilityState==="visible"?(this.autoRefreshToken&&this._startAutoRefresh(),t||(await this.initializePromise,await this._acquireLock(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(t,n,r){const s=[`provider=${encodeURIComponent(n)}`];if(r!=null&&r.redirectTo&&s.push(`redirect_to=${encodeURIComponent(r.redirectTo)}`),r!=null&&r.scopes&&s.push(`scopes=${encodeURIComponent(r.scopes)}`),this.flowType==="pkce"){const[i,o]=await As(this.storage,this.storageKey),a=new URLSearchParams({code_challenge:`${encodeURIComponent(i)}`,code_challenge_method:`${encodeURIComponent(o)}`});s.push(a.toString())}if(r!=null&&r.queryParams){const i=new URLSearchParams(r.queryParams);s.push(i.toString())}return r!=null&&r.skipBrowserRedirect&&s.push(`skip_http_redirect=${r.skipBrowserRedirect}`),`${t}?${s.join("&")}`}async _unenroll(t){try{return await this._useSession(async n=>{var r;const{data:s,error:i}=n;return i?this._returnResult({data:null,error:i}):await z(this.fetch,"DELETE",`${this.url}/factors/${t.factorId}`,{headers:this.headers,jwt:(r=s==null?void 0:s.session)===null||r===void 0?void 0:r.access_token})})}catch(n){if(F(n))return this._returnResult({data:null,error:n});throw n}}async _enroll(t){try{return await this._useSession(async n=>{var r,s;const{data:i,error:o}=n;if(o)return this._returnResult({data:null,error:o});const a=Object.assign({friendly_name:t.friendlyName,factor_type:t.factorType},t.factorType==="phone"?{phone:t.phone}:t.factorType==="totp"?{issuer:t.issuer}:{}),{data:l,error:c}=await z(this.fetch,"POST",`${this.url}/factors`,{body:a,headers:this.headers,jwt:(r=i==null?void 0:i.session)===null||r===void 0?void 0:r.access_token});return c?this._returnResult({data:null,error:c}):(t.factorType==="totp"&&l.type==="totp"&&(!((s=l==null?void 0:l.totp)===null||s===void 0)&&s.qr_code)&&(l.totp.qr_code=`data:image/svg+xml;utf-8,${l.totp.qr_code}`),this._returnResult({data:l,error:null}))})}catch(n){if(F(n))return this._returnResult({data:null,error:n});throw n}}async _verify(t){return this._acquireLock(this.lockAcquireTimeout,async()=>{try{return await this._useSession(async n=>{var r;const{data:s,error:i}=n;if(i)return this._returnResult({data:null,error:i});const o=Object.assign({challenge_id:t.challengeId},"webauthn"in t?{webauthn:Object.assign(Object.assign({},t.webauthn),{credential_response:t.webauthn.type==="create"?RL(t.webauthn.credential_response):jL(t.webauthn.credential_response)})}:{code:t.code}),{data:a,error:l}=await z(this.fetch,"POST",`${this.url}/factors/${t.factorId}/verify`,{body:o,headers:this.headers,jwt:(r=s==null?void 0:s.session)===null||r===void 0?void 0:r.access_token});return l?this._returnResult({data:null,error:l}):(await this._saveSession(Object.assign({expires_at:Math.round(Date.now()/1e3)+a.expires_in},a)),await this._notifyAllSubscribers("MFA_CHALLENGE_VERIFIED",a),this._returnResult({data:a,error:l}))})}catch(n){if(F(n))return this._returnResult({data:null,error:n});throw n}})}async _challenge(t){return this._acquireLock(this.lockAcquireTimeout,async()=>{try{return await this._useSession(async n=>{var r;const{data:s,error:i}=n;if(i)return this._returnResult({data:null,error:i});const o=await z(this.fetch,"POST",`${this.url}/factors/${t.factorId}/challenge`,{body:t,headers:this.headers,jwt:(r=s==null?void 0:s.session)===null||r===void 0?void 0:r.access_token});if(o.error)return o;const{data:a}=o;if(a.type!=="webauthn")return{data:a,error:null};switch(a.webauthn.type){case"create":return{data:Object.assign(Object.assign({},a),{webauthn:Object.assign(Object.assign({},a.webauthn),{credential_options:Object.assign(Object.assign({},a.webauthn.credential_options),{publicKey:PL(a.webauthn.credential_options.publicKey)})})}),error:null};case"request":return{data:Object.assign(Object.assign({},a),{webauthn:Object.assign(Object.assign({},a.webauthn),{credential_options:Object.assign(Object.assign({},a.webauthn.credential_options),{publicKey:AL(a.webauthn.credential_options.publicKey)})})}),error:null}}})}catch(n){if(F(n))return this._returnResult({data:null,error:n});throw n}})}async _challengeAndVerify(t){const{data:n,error:r}=await this._challenge({factorId:t.factorId});return r?this._returnResult({data:null,error:r}):await this._verify({factorId:t.factorId,challengeId:n.id,code:t.code})}async _listFactors(){var t;const{data:{user:n},error:r}=await this.getUser();if(r)return{data:null,error:r};const s={all:[],phone:[],totp:[],webauthn:[]};for(const i of(t=n==null?void 0:n.factors)!==null&&t!==void 0?t:[])s.all.push(i),i.status==="verified"&&s[i.factor_type].push(i);return{data:s,error:null}}async _getAuthenticatorAssuranceLevel(t){var n,r,s,i;if(t)try{const{payload:f}=il(t);let w=null;f.aal&&(w=f.aal);let y=w;const{data:{user:x},error:m}=await this.getUser(t);if(m)return this._returnResult({data:null,error:m});((r=(n=x==null?void 0:x.factors)===null||n===void 0?void 0:n.filter(S=>S.status==="verified"))!==null&&r!==void 0?r:[]).length>0&&(y="aal2");const v=f.amr||[];return{data:{currentLevel:w,nextLevel:y,currentAuthenticationMethods:v},error:null}}catch(f){if(F(f))return this._returnResult({data:null,error:f});throw f}const{data:{session:o},error:a}
255=await this.getSession();if(a)return this._returnResult({data:null,error:a});if(!o)return{data:{currentLevel:null,nextLevel:null,currentAuthenticationMethods:[]},error:null};const{payload:l}=il(o.access_token);let c=null;l.aal&&(c=l.aal);let u=c;((i=(s=o.user.factors)===null||s===void 0?void 0:s.filter(f=>f.status==="verified"))!==null&&i!==void 0?i:[]).length>0&&(u="aal2");const h=l.amr||[];return{data:{currentLevel:c,nextLevel:u,currentAuthenticationMethods:h},error:null}}async _getAuthorizationDetails(t){try{return await this._useSession(async n=>{const{data:{session:r},error:s}=n;return s?this._returnResult({data:null,error:s}):r?await z(this.fetch,"GET",`${this.url}/oauth/authorizations/${t}`,{headers:this.headers,jwt:r.access_token,xform:i=>({data:i,error:null})}):this._returnResult({data:null,error:new gt})})}catch(n){if(F(n))return this._returnResult({data:null,error:n});throw n}}async _approveAuthorization(t,n){try{return await this._useSession(async r=>{const{data:{session:s},error:i}=r;if(i)return this._returnResult({data:null,error:i});if(!s)return this._returnResult({data:null,error:new gt});const o=await z(this.fetch,"POST",`${this.url}/oauth/authorizations/${t}/consent`,{headers:this.headers,jwt:s.access_token,body:{action:"approve"},xform:a=>({data:a,error:null})});return o.data&&o.data.redirect_url&&Be()&&!(n!=null&&n.skipBrowserRedirect)&&window.location.assign(o.data.redirect_url),o})}catch(r){if(F(r))return this._returnResult({data:null,error:r});throw r}}async _denyAuthorization(t,n){try{return await this._useSession(async r=>{const{data:{session:s},error:i}=r;if(i)return this._returnResult({data:null,error:i});if(!s)return this._returnResult({data:null,error:new gt});const o=await z(this.fetch,"POST",`${this.url}/oauth/authorizations/${t}/consent`,{headers:this.headers,jwt:s.access_token,body:{action:"deny"},xform:a=>({data:a,error:null})});return o.data&&o.data.redirect_url&&Be()&&!(n!=null&&n.skipBrowserRedirect)&&window.location.assign(o.data.redirect_url),o})}catch(r){if(F(r))return this._returnResult({data:null,error:r});throw r}}async _listOAuthGrants(){try{return await this._useSession(async t=>{const{data:{session:n},error:r}=t;return r?this._returnResult({data:null,error:r}):n?await z(this.fetch,"GET",`${this.url}/user/oauth/grants`,{headers:this.headers,jwt:n.access_token,xform:s=>({data:s,error:null})}):this._returnResult({data:null,error:new gt})})}catch(t){if(F(t))return this._returnResult({data:null,error:t});throw t}}async _revokeOAuthGrant(t){try{return await this._useSession(async n=>{const{data:{session:r},error:s}=n;return s?this._returnResult({data:null,error:s}):r?(await z(this.fetch,"DELETE",`${this.url}/user/oauth/grants`,{headers:this.headers,jwt:r.access_token,query:{client_id:t.clientId},noResolveJson:!0}),{data:{},error:null}):this._returnResult({data:null,error:new gt})})}catch(n){if(F(n))return this._returnResult({data:null,error:n});throw n}}async fetchJwk(t,n={keys:[]}){let r=n.keys.find(a=>a.kid===t);if(r)return r;const s=Date.now();if(r=this.jwks.keys.find(a=>a.kid===t),r&&this.jwks_cached_at+VD>s)return r;const{data:i,error:o}=await z(this.fetch,"GET",`${this.url}/.well-known/jwks.json`,{headers:this.headers});if(o)throw o;return!i.keys||i.keys.length===0||(this.jwks=i,this.jwks_cached_at=s,r=i.keys.find(a=>a.kid===t),!r)?null:r}async getClaims(t,n={}){try{let r=t;if(!r){const{data:f,error:w}
255=await this.getSession();if(w||!f.session)return this._returnResult({data:null,error:w});r=f.session.access_token}const{header:s,payload:i,signature:o,raw:{header:a,payload:l}}=il(r);n!=null&&n.allowExpired||aL(i.exp);const c=!s.alg||s.alg.startsWith("HS")||!s.kid||!("crypto"in globalThis&&"subtle"in globalThis.crypto)?null:await this.fetchJwk(s.kid,n!=null&&n.keys?{keys:n.keys}:n==null?void 0:n.jwks);if(!c){const{error:f}=await this.getUser(r);if(f)throw f;return{data:{claims:i,header:s,signature:o},error:null}}const u=lL(s.alg),d=await crypto.subtle.importKey("jwk",c,u,!0,["verify"]);if(!await crypto.subtle.verify(u,d,o,GD(`${a}.${l}`)))throw new zh("Invalid JWT signature");return{data:{claims:i,header:s,signature:o},error:null}}catch(r){if(F(r))return this._returnResult({data:null,error:r});throw r}}}ia.nextInstanceID={};const FL=ia,UL="2.93.2";let co="";typeof Deno<"u"?co="deno":typeof document<"u"?co="web":typeof navigator<"u"&&navigator.product==="ReactNative"?co="react-native":co="node";const BL={"X-Client-Info":`supabase-js-${co}/${UL}`},zL={headers:BL},WL={schema:"public"},HL={autoRefreshToken:!0,persistSession:!0,detectSessionInUrl:!0,flowType:"implicit"},KL={};function oa(e){"@babel/helpers - typeof";return oa=typeof Symbol=="function"&&typeof Symbol.iterator=="symbol"?function(t){return typeof t}:function(t){return t&&typeof Symbol=="function"&&t.constructor===Symbol&&t!==Symbol.prototype?"symbol":typeof t},oa(e)}function qL(e,t){if(oa(e)!="object"||!e)return e;var n=e[Symbol.toPrimitive];if(n!==void 0){var r=n.call(e,t||"default");if(oa(r)!="object")return r;throw new TypeError("@@toPrimitive must return a primitive value.")}return(t==="string"?String:Number)(e)}function GL(e){var t=qL(e,"string");return oa(t)=="symbol"?t:t+""}function YL(e,t,n){return(t=GL(t))in e?Object.defineProperty(e,t,{value:n,enumerable:!0,configurable:!0,writable:!0}):e[t]=n,e}function kv(e,t){var n=Object.keys(e);if(Object.getOwnPropertySymbols){var r=Object.getOwnPropertySymbols(e);t&&(r=r.filter(function(s){return Object.getOwnPropertyDescriptor(e,s).enumerable})),n.push.apply(n,r)}return n}function _e(e){for(var t=1;t<arguments.length;t++){var n=arguments[t]!=null?arguments[t]:{};t%2?kv(Object(n),!0).forEach(function(r){YL(e,r,n[r])}):Object.getOwnPropertyDescriptors?Object.defineProperties(e,Object.getOwnPropertyDescriptors(n)):kv(Object(n)).forEach(function(r){Object.defineProperty(e,r,Object.getOwnPropertyDescriptor(n,r))})}return e}const QL=e=>e?(...t)=>e(...t):(...t)=>fetch(...t),JL=()=>Headers,XL=(e,t,n)=>{const r=QL(n),s=JL();return async(i,o)=>{var a;const l=(a=await t())!==null&&a!==void 0?a:e;let c=new s(o==null?void 0:o.headers);return c.has("apikey")||c.set("apikey",e),c.has("Authorization")||c.set("Authorization",`Bearer ${l}`),r(i,_e(_e({},o),{},{headers:c}))}};function ZL(e){return e.endsWith("/")?e:e+"/"}function eM(e,t){var n,r;const{db:s,auth:i,realtime:o,global:a}=e,{db:l,auth:c,realtime:u,global:d}=t,h={db:_e(_e({},l),s),auth:_e(_e({},c),i),realtime:_e(_e({},u),o),storage:{},global:_e(_e(_e({},d),a),{},{headers:_e(_e({},(n=d==null?void 0:d.headers)!==null&&n!==void 0?n:{}),(r=a==null?void 0:a.headers)!==null&&r!==void 0?r:{})}),accessToken:async()=>""};return e.accessToken?h.accessToken=e.accessToken:delete h.accessToken,h}function tM(e){const t=e==null?void 0:e.trim();if(!t)throw new Error("supabaseUrl is required.");if(!t.match(/^https?:\/\//i))throw new Error("Invalid supabaseUrl: Must be a valid HTTP or HTTPS URL.");try{return new URL(ZL(t))}catch{throw Error("Invalid supabaseUrl: Provided URL is malformed.")}}var nM=class extends FL{constructor(e){super(e)}},rM=class{constructor(e,t,n){var r,s;this.supabaseUrl=e,this.supabaseKey=t;const i=tM(e);if(!t)throw new Error("supabaseKey is required.");this.realtimeUrl=new URL("realtime/v1",i),this.realtimeUrl.protocol=this.realtimeUrl.protocol.replace("http","ws"),this.authUrl=new URL("auth/v1",i),this.storageUrl=new URL("storage/v1",i),this.functionsUrl=new URL("functions/v1",i);const o=`sb-${i.hostname.split(".")[0]}-auth-token`,a={db:WL,realtime:KL,auth:_e(_e({},HL),{},{storageKey:o}),global:zL},l=eM(n??{},a);if(this.storageKey=(r=l.auth.storageKey)!==null&&r!==void 0?r:"",this.headers=(s=l.global.headers)!==null&&s!==void 0?s:{},l.accessToken)this.accessToken=l.accessToken,this.auth=new Proxy({},{get:(u,d)=>{throw new Error(`@supabase/supabase-js: Supabase Client is configured with the accessToken option, accessing supabase.auth.${String(d)} is not possible`)}});else{var c;this.auth=this._initSupabaseAuthClient((c=l.auth)!==null&&c!==void 0?c:{},this.headers,l.global.fetch)}this.fetch=XL(t,this._getAccessToken.bind(this),l.global.fetch),this.realtime=this._initRealtimeClient(_e({headers:this.headers,accessToken:this._getAccessToken.bind(this)},l.realtime)),this.accessToken&&Promise.resolve(this.accessToken()).then(u=>this.realtime.setAuth(u)).catch(u=>console.warn("Failed to set initial Realtime auth token:",u)),this.rest=new FI(new URL("rest/v1",i).href,{headers:this.headers,schema:l.db.schema,fetch:this.fetch}),this.storage=new ID(this.storageUrl.href,this.headers,this.fetch,n==null?void 0:n.storage),l.accessToken||this._listenForAuthEvents()}get functions(){return new DI(this.functionsUrl.href,{headers:this.headers,customFetch:this.fetch})}from(e){return this.rest.from(e)}schema(e){return this.rest.schema(e)}rpc(e,t={},n={head:!1,get:!1,count:void 0}){return this.rest.rpc(e,t,n)}
255channel(e,t={config:{}}){return this.realtime.channel(e,t)}getChannels(){return this.realtime.getChannels()}removeChannel(e){return this.realtime.removeChannel(e)}removeAllChannels(){return this.realtime.removeAllChannels()}async _getAccessToken(){var e=this,t,n;if(e.accessToken)return await e.accessToken();const{data:r}=await e.auth.getSession();return(t=(n=r.session)===null||n===void 0?void 0:n.access_token)!==null&&t!==void 0?t:e.supabaseKey}_initSupabaseAuthClient({autoRefreshToken:e,persistSession:t,detectSessionInUrl:n,storage:r,userStorage:s,storageKey:i,flowType:o,lock:a,debug:l,throwOnError:c},u,d){const h={Authorization:`Bearer ${this.supabaseKey}`,apikey:`${this.supabaseKey}`};return new nM({url:this.authUrl.href,headers:_e(_e({},h),u),storageKey:i,autoRefreshToken:e,persistSession:t,detectSessionInUrl:n,storage:r,userStorage:s,flowType:o,lock:a,debug:l,throwOnError:c,fetch:d,hasCustomAuthorizationHeader:Object.keys(this.headers).some(f=>f.toLowerCase()==="authorization")})}_initRealtimeClient(e){return new rD(this.realtimeUrl.href,_e(_e({},e),{},{params:_e(_e({},{apikey:this.supabaseKey}),e==null?void 0:e.params)}))}_listenForAuthEvents(){return this.auth.onAuthStateChange((e,t)=>{this._handleTokenChanged(e,"CLIENT",t==null?void 0:t.access_token)})}_handleTokenChanged(e,t,n){(e==="TOKEN_REFRESHED"||e==="SIGNED_IN")&&this.changedAccessToken!==n?(this.changedAccessToken=n,this.realtime.setAuth(n)):e==="SIGNED_OUT"&&(this.realtime.setAuth(),t=="STORAGE"&&this.auth.signOut(),this.changedAccessToken=void 0)}};const sM=(e,t,n)=>new rM(e,t,n);function iM(){if(typeof window<"u")return!1;const e=globalThis.process;if(!e)return!1;const t=e.version;if(t==null)return!1;const n=t.match(/^v(\d+)\./);return n?parseInt(n[1],10)<=18:!1}iM()&&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 oM="https://wdbagjrzrlossgyhkatc.supabase.co",aM="eyJhbGciOiJIUzI1NiIsInR5cCI6IkpXVCJ9.eyJpc3MiOiJzdXBhYmFzZSIsInJlZiI6IndkYmFnanJ6cmxvc3NneWhrYXRjIiwicm9sZSI6ImFub24iLCJpYXQiOjE3Njk2MDE2MjksImV4cCI6MjA4NTE3NzYyOX0.w0XR1_TLW_cPrFidlduT2c6S_FMvaJqh5m-vedoZGDw",FS=sM(oM,aM,{auth:{storage:localStorage,persistSession:!0,autoRefreshToken:!0}}),Ev="/assets/ev-charging-hero-oSa8V_Mn.jpg",lM="/assets/pod-point-charger-CO-9O4Yu.jpg",cM="/assets/mobile-app-C2oy2jC_.jpg",ye={hidden:{opacity:0,y:30},visible:{opacity:1,y:0,transition:{duration:.6}}},an={hidden:{opacity:0},visible:{opacity:1,transition:{staggerChildren:.15}}},uM=[{icon:Kf,title:"3-Year Warranty",description:"Pod Point Solo chargers feature 3-year warranty as standard. Full breakdown assistance is included to give you peace of mind."},{icon:jx,title:"Feature-Rich Mobile App",description:"Manage your Pod Point via the responsive smartphone app. Schedule charging, monitor energy usage, and track your savings."},{icon:Wf,title:"Standard Installation",description:"Our OZEV-approved installers typically complete installations in just one day, minimizing disruption to your routine."}],dM=[{question:"What's the difference between tethered and untethered?",answer:"Tethered chargers have the cable permanently attached, so you never need to worry about carrying cables. Untethered chargers require you to plug in your own cable each time, which gives flexibility if you have multiple cable types."},{question:"How much does it cost to charge an EV at home?",answer:"On average, it costs around £8-12 to fully charge an electric vehicle at home, depending on your electricity tariff and battery size. This is significantly cheaper than using public charging stations."},{question:"How long does it take to charge on 7kW at home?",answer:"A 7kW home charger typically adds around 30 miles of range per hour of charging. For most EVs, a full charge takes 6-12 hours, making overnight charging ideal."},{question:"Is the Pod Point Solo 3S compatible with solar panels?",answer:"Yes! The Pod Point Solo 3S is compatible with solar panels, allowing you to charge your EV using renewable energy and maximize your savings."},{question:"Can I charge overnight with my electric tariff at cheaper rates?",answer:"Absolutely. The Pod Point app allows you to schedule charging during off-peak hours, taking advantage of cheaper electricity rates overnight."},{question:"Can I control my Pod Point charger with an app?",answer:"Yes, the Pod Point app gives you full control over your charger. Monitor usage, schedule charging, view charging history, and more."},{question:"Can a charger plug in fast enough with Pod Point Solo 3S?",answer:"The Pod Point Solo 3S delivers up to 7kW of power, which is the fastest AC charging speed available for home installations in the UK."},{question:"How much does a home charging point cost?",answer:"The Pod Point Solo 3S is available from £1099 installed (untethered) or £1149 installed (tethered). This includes standard installation and VAT."}];function hM(){const[e,t]=b.useState(null),[n,r]=b.useState({firstName:"",lastName:"",telephone:"",email:"",message:"",consent:!1}),[s,i]=b.useState(!1),{toast:o}=Vf(),a=async l=>{if(l.preventDefault(),!n.consent){o({title:"Consent Required",description:"Please provide consent to proceed with the enquiry.",variant:"destructive"});return}i(!0);try{const{data:c,error:u}
255=await FS.functions.invoke("submit-lead",{body:{firstName:n.firstName,lastName:n.lastName,email:n.email,mobile:n.telephone,message:n.message||"I would like to get a quote for Pod Point EV charger installation."}});if(u){console.error("Error submitting lead:",u),o({title:"Submission Failed",description:"There was an error sending your enquiry. Please try again.",variant:"destructive"});return}console.log("Lead submitted successfully:",c),o({title:"Enquiry Sent",description:"Thank you for your interest. We'll be in touch shortly."}),r({firstName:"",lastName:"",telephone:"",email:"",message:"",consent:!1})}catch(c){console.error("Unexpected error:",c),o({title:"Submission Failed",description:"There was an error sending your enquiry. Please try again.",variant:"destructive"})}finally{i(!1)}};return p.jsxs("div",{className:"min-h-[900px] bg-background",children:[p.jsx(Ui,{}),p.jsxs("section",{className:"relative h-[700px] min-h-[600px] flex items-center justify-center overflow-hidden",children:[p.jsxs("div",{className:"absolute inset-0",children:[p.jsx("img",{src:Ev,alt:"EV Charging",className:"w-full h-full object-cover"}),p.jsx("div",{className:"absolute inset-0 bg-gradient-to-r from-kk-dark/90 via-kk-dark/70 to-transparent"})]}),p.jsx("div",{className:"relative z-10 container-wide section-padding",children:p.jsxs(R.div,{initial:"hidden",animate:"visible",variants:an,className:"max-w-2xl",children:[p.jsx(R.p,{variants:ye,className:"text-[hsl(8,85%,55%)] font-semibold uppercase tracking-widest mb-4",children:"Home Charger Solutions"}),p.jsx(R.h1,{variants:ye,className:"text-5xl md:text-7xl font-display text-[hsl(0,0%,100%)] mb-6",children:"POD POINT"}),p.jsx(R.div,{variants:ye,className:"accent-bar mb-8"}),p.jsx(R.p,{variants:ye,className:"text-lg text-[hsl(0,0%,100%)]/80 mb-8 leading-relaxed",children:"K.K.L Motors are delighted to offer Pod Point EV Home Charging Solutions for customers looking to embrace the future of electric vehicles. Our OZEV-approved installation service ensures a seamless transition to home EV charging."}),p.jsx(R.div,{variants:ye,children:p.jsx($n,{variant:"hero",size:"xl",onClick:()=>{var l;return(l=document.getElementById("enquiry-form"))==null?void 0:l.scrollIntoView({behavior:"smooth"})},children:"Get Started Today"})})]})})]}),p.jsx("section",{className:"section-padding bg-kk-light",children:p.jsx("div",{className:"container-wide",children:p.jsxs(R.div,{initial:"hidden",whileInView:"visible",viewport:{once:!0},variants:an,className:"grid lg:grid-cols-2 gap-16 items-center",children:[p.jsxs(R.div,{variants:ye,children:[p.jsxs("h2",{className:"text-3xl md:text-5xl font-display text-kk-dark mb-6",children:["Get Started with ",p.jsx("span",{className:"text-gradient",children:"Home EV Charging"})]}),p.jsx("div",{className:"accent-bar mb-8"}),p.jsx("p",{className:"text-muted-foreground leading-relaxed mb-6",children:"EV ownership is increasing exponentially as motorists seek to make the switch to a greener alternative. With Pod Point's OLEV-eligible charging solutions, you can conveniently and cost-effectively charge your electric vehicle at home."}),p.jsx("p",{className:"text-muted-foreground leading-relaxed mb-6",children:"To get started, all you need is a driveway, garage, or dedicated parking space near your property. Our team will handle the rest, from survey to installation, ensuring your home charging point is set up correctly and safely."}),p.jsx("p",{className:"text-muted-foreground leading-relaxed",children:"With the government OZEV grant, eligible customers can receive up to £350 off the cost of installation, making home charging more accessible than ever."})]}),p.jsxs(R.div,{variants:ye,className:"relative",children:[p.jsx("div",{className:"absolute -top-4 -left-4 w-full h-full bg-gradient-accent rounded-2xl opacity-20"}),p.jsx("img",{src:lM,alt:"Pod Point Solo 3S Charger",className:"relative rounded-2xl shadow-lg w-full"}),p.jsxs("div",{className:"absolute -bottom-6 -right-6 bg-kk-dark text-primary-foreground p-6 rounded-xl shadow-lg",children:[p.jsx("p",{className:"text-sm text-accent font-semibold uppercase tracking-wider mb-2",children:"Solo 3S Charger"}),p.jsx("p",{className:"text-2xl font-display",children:"From £1099"}
255),p.jsx("p",{className:"text-sm text-primary-foreground/70",children:"Installed"})]})]})]})})}),p.jsx("section",{className:"section-padding bg-kk-dark",children:p.jsxs("div",{className:"container-wide",children:[p.jsxs(R.div,{initial:"hidden",whileInView:"visible",viewport:{once:!0},variants:an,className:"text-center mb-16",children:[p.jsxs(R.h2,{variants:ye,className:"text-3xl md:text-5xl font-display text-primary-foreground mb-6",children:["Pod Point Home Charging ",p.jsx("span",{className:"text-gradient",children:"Solutions"})]}),p.jsx(R.div,{variants:ye,className:"accent-bar mx-auto"})]}),p.jsxs(R.div,{initial:"hidden",whileInView:"visible",viewport:{once:!0},variants:an,className:"grid md:grid-cols-2 gap-8 items-center",children:[p.jsxs(R.div,{variants:ye,className:"space-y-6",children:[p.jsx("p",{className:"text-primary-foreground/80 leading-relaxed",children:"K.K.L Motors are proud to offer the Pod Point Solo 3S charger - a premium home charging solution that delivers up to 7kW of power. Whether you choose the tethered or untethered version, you'll enjoy reliable, efficient charging every time."}),p.jsxs("div",{className:"bg-kk-charcoal rounded-xl p-6 border border-accent/20",children:[p.jsx("h3",{className:"font-display text-xl text-primary-foreground mb-4",children:"Solo 3S Charger"}),p.jsxs("div",{className:"space-y-3",children:[p.jsxs("div",{className:"flex justify-between items-center",children:[p.jsx("span",{className:"text-primary-foreground/70",children:"Universal (Untethered)"}),p.jsx("span",{className:"text-accent font-bold",children:"£1099 Installed"})]}),p.jsxs("div",{className:"flex justify-between items-center",children:[p.jsx("span",{className:"text-primary-foreground/70",children:"Tethered"}),p.jsx("span",{className:"text-accent font-bold",children:"£1149 Installed"})]})]}),p.jsx("p",{className:"text-sm text-primary-foreground/60 mt-4",children:"3x faster than a 3-pin plug. Perfect for overnight charging."})]})]}),p.jsx(R.div,{variants:ye,className:"grid grid-cols-1 gap-4",children:uM.map((l,c)=>p.jsx("div",{className:"bg-kk-charcoal/50 backdrop-blur-sm border border-primary-foreground/10 rounded-xl p-6 hover:border-accent/50 transition-all duration-300",children:p.jsxs("div",{className:"flex items-start gap-4",children:[p.jsx("div",{className:"flex-shrink-0 w-12 h-12 rounded-lg bg-gradient-accent flex items-center justify-center",children:p.jsx(l.icon,{className:"w-6 h-6 text-accent-foreground"})}),p.jsxs("div",{children:[p.jsx("h3",{className:"font-display text-lg text-primary-foreground mb-2",children:l.title}),p.jsx("p",{className:"text-sm text-primary-foreground/70 leading-relaxed",children:l.description})]})]})},c))})]})]})}),p.jsx("section",{className:"section-padding bg-background",children:p.jsx("div",{className:"container-wide",children:p.jsxs(R.div,{initial:"hidden",whileInView:"visible",viewport:{once:!0},variants:an,className:"grid lg:grid-cols-2 gap-16 items-center",children:[p.jsx(R.div,{variants:ye,className:"order-2 lg:order-1",children:p.jsxs("div",{className:"relative",children:[p.jsx("img",{src:Ev,alt:"EV Installation",className:"rounded-2xl shadow-lg w-full"}),p.jsx("div",{className:"absolute top-6 left-6 bg-accent text-accent-foreground px-6 py-3 rounded-lg font-display text-2xl shadow-accent",children:"15 DAY"})]})}),p.jsxs(R.div,{variants:ye,className:"order-1 lg:order-2",children:[p.jsxs("h2",{className:"text-3xl md:text-5xl font-display text-kk-dark mb-6",children:["15 Day ",p.jsx("span",{className:"text-gradient",children:"Installation"})]}),p.jsx("div",{className:"accent-bar mb-8"}),p.jsxs("div",{className:"space-y-4 text-muted-foreground leading-relaxed",children:[p.jsx("p",{children:"This fast turnaround includes an on-site survey, so you can rest easy knowing that your installation will be assessed before we quote. Our OZEV-approved installers ensure your charger is fitted safely and efficiently."}),p.jsx("p",{children:"There are no extra call-out charges. You'll get a home EV charger solution that's tailored to your home and your vehicle, with everything included in the quoted price."}),p.jsx("div",{className:"pt-4 space-y-3",children:["Home survey included in quote","OZEV-approved installation team","Installation usually completed in one day","Full support before, during and after"].map((l,c)=>p.jsxs("div",{className:"flex items-center gap-3",children:[p.jsx("div",{className:"flex-shrink-0 w-6 h-6 rounded-full bg-accent/20 flex items-center justify-center",children:p.jsx(Ax,{className:"w-4 h-4 text-accent"})}),p.jsx("span",{className:"text-foreground",children:l})]},c))})]})]})]})})}),p.jsx("section",{className:"section-padding bg-kk-light",children:p.jsx("div",{className:"container-wide",children:p.jsxs(R.div,{initial:"hidden",
255whileInView:"visible",viewport:{once:!0},variants:an,className:"grid lg:grid-cols-2 gap-16 items-center",children:[p.jsxs(R.div,{variants:ye,children:[p.jsxs("h2",{className:"text-3xl md:text-5xl font-display text-kk-dark mb-6",children:["Feature Rich ",p.jsx("span",{className:"text-gradient",children:"Mobile App"})]}),p.jsx("div",{className:"accent-bar mb-8"}),p.jsx("p",{className:"text-muted-foreground leading-relaxed mb-6",children:"Optimize your EV ownership with the Pod Point mobile app. If you have a standard energy tariff with the power to switch, the Pod Point app enables you to maximize your cost savings by charging smarter."}),p.jsx("p",{className:"text-muted-foreground leading-relaxed mb-6",children:"You can also use the app to schedule overnight charging, so your vehicle is fully charged when you wake up. Set reminders, track your energy consumption, and monitor your charging schedule with ease."}),p.jsx("div",{className:"space-y-3",children:["Schedule charging during off-peak hours","Track energy usage and cost savings","Receive notifications and reminders","View complete charging history"].map((l,c)=>p.jsxs("div",{className:"flex items-center gap-3",children:[p.jsx("div",{className:"flex-shrink-0 w-6 h-6 rounded-full bg-accent/20 flex items-center justify-center",children:p.jsx(hg,{className:"w-4 h-4 text-accent"})}),p.jsx("span",{className:"text-foreground",children:l})]},c))})]}),p.jsx(R.div,{variants:ye,className:"flex justify-center",children:p.jsxs("div",{className:"relative",children:[p.jsx("div",{className:"absolute inset-0 bg-gradient-accent rounded-full blur-3xl op
255acity-20 scale-75"}),p.jsx("img",{src:cM,alt:"Pod Point Mobile App",className:"relative rounded-3xl shadow-lg max-w-sm animate-float"})]})})]})})}),p.jsx("section",{className:"section-padding bg-kk-dark",children:p.jsx("div",{className:"container-wide",children:p.jsxs(R.div,{initial:"hidden",whileInView:"visible",viewport:{once:!0},variants:an,className:"grid lg:grid-cols-2 gap-16 items-center",children:[p.jsx(R.div,{variants:ye,className:"order-2 lg:order-1",children:p.jsx("div",{className:"grid grid-cols-2 gap-6",children:[{icon:hg,label:"7kW Power",desc:"Fast home charging"},{icon:Kf,label:"3-Year Warranty",desc:"Full protection"},{icon:jx,label:"App Control",desc:"Smart features"},{icon:Wf,label:"Scheduled Charging",desc:"Off-peak savings"}].map((l,c)=>p.jsxs("div",{className:"bg-kk-charcoal/50 border border-primary-foreground/10 rounded-xl p-6 text-center hover:border-accent/50 transition-all duration-300",children:[p.jsx("div",{className:"w-12 h-12 rounded-lg bg-gradient-accent mx-auto mb-4 flex items-center justify-center",children:p.jsx(l.icon,{className:"w-6 h-6 text-accent-foreground"})}),p.jsx("h4",{className:"font-display text-primary-foreground mb-1",children:l.label}),p.jsx("p",{className:"text-sm text-primary-foreground/60",children:l.desc})]},c))})}),p.jsxs(R.div,{variants:ye,className:"order-1 lg:order-2",children:[p.jsxs("h2",{className:"text-3xl md:text-5xl font-display text-primary-foreground mb-6",children:["Packed with the ",p.jsx("span",{className:"text-gradient",children:"Latest Technology"})]}),p.jsx("div",{className:"accent-bar mb-8"}),p.jsx("p",{className:"text-primary-foreground/80 leading-relaxed mb-6",children:"Pod Point chargers are designed with cutting-edge technology. From smart connectivity to energy management features, the Solo 3S provides everything you need for efficient home charging."}),p.jsx("p",{className:"text-primary-foreground/80 leading-relaxed",children:"Compatible with all electric vehicles, the Pod Point Solo 3S integrates seamlessly with your home's electrical system and smart home devices. Future-proof your EV charging with technology that evolves with you."})]})]})})}),p.jsx("section",{className:"section-padding bg-background",children:p.jsxs("div",{className:"container-wide",children:[p.jsxs(R.div,{initial:"hidden",whileInView:"visible",viewport:{once:!0},variants:an,className:"text-center mb-16",children:[p.jsxs(R.h2,{variants:ye,className:"text-3xl md:text-5xl font-display text-kk-dark mb-6",children:["Frequently Asked ",p.jsx("span",{className:"text-gradient",children:"Questions"})]}),p.jsx(R.div,{variants:ye,className:"accent-bar mx-auto"})]}),p.jsx(R.div,{initial:"hidden",whileInView:"visible",viewport:{once:!0},variants:an,className:"max-w-3xl mx-auto space-y-4",children:dM.map((l,c)=>p.jsxs(R.div,{variants:ye,className:"border border-border rounded-xl overflow-hidden",children:[p.jsxs("button",{onClick:()=>t(e===c?null:c),className:"w-full flex items-center justify-between p-6 text-left hover:bg-muted/50 transition-colors",children:[p.jsx("span",{className:"font-semibold text-foreground pr-4",children:l.question}),e===c?p.jsx(kT,{className:"w-5 h-5 text-accent flex-shrink-0"}):p.jsx(_T,{className:"w-5 h-5 text-muted-foreground flex-shrink-0"})]}),e===c&&p.jsx("div",{className:"px-6 pb-6",children:p.jsx("p",{className:"text-muted-foreground leading-relaxed",children:l.answer})})]},c))})]})}),p.jsx("section",{id:"enquiry-form",className:"section-padding bg-kk-light",children:p.jsx("div",{className:"container-wide",children:p.jsxs(R.div,{initial:"hidden",whileInView:"visible",viewport:{once:!0},variants:an,className:"max-w-2xl mx-auto",children:[p.jsxs(R.div,{variants:ye,className:"text-center mb-12",children:[p.jsxs("h2",{className:"text-3xl md:text-5xl font-display text-kk-dark mb-6",children:["Get Your ",p.jsx("span",{className:"text-gradient",children:"Quote Today"})]}),p.jsx("div",{className:"accent-bar mx-auto mb-6"}),p.jsx("p",{className:"text-muted-foreground",children:"Complete the form below and our team will be in touch to discuss your home EV charging needs."})]}),p.jsxs(R.form,{variants:ye,onSubmit:a,className:"space-y-6 bg-card p-8 rounded-2xl shadow-md",children:[p.jsxs("div",{className:"grid md:grid-cols-2 gap-6",children:[p.jsxs("div",{children:[p.jsx("label",{className:"block text-sm font-medium text-foreground mb-2",children:"First Name*"}),p.jsx(Zt,{required:!0,value:n.firstName,onChange:l=>r({...n,firstName:l.target.value}),placeholder:"First name",className:"bg-background"})]}),p.jsxs("div",{children:[p.jsx("label",{className:"block text-sm font-medium text-foreground mb-2",children:"Last Name*"}),p.jsx(Zt,{required:!0,value:n.lastName,onChange:l=>r({...n,lastName:l.target.value}),placeholder:"Last name",className:"bg-background"})]})]}),p.jsxs("div",{className:"grid md:grid-cols-2 gap-6",children:[p.jsxs("div",{children:[p.jsx("label",{className:"block text-sm font-medium text-foreground mb-2",children:"Telephone*"}
255),p.jsx(Zt,{required:!0,type:"tel",value:n.telephone,onChange:l=>r({...n,telephone:l.target.value}),placeholder:"Your phone number",className:"bg-background"})]}),p.jsxs("div",{children:[p.jsx("label",{className:"block text-sm font-medium text-foreground mb-2",children:"Email*"}),p.jsx(Zt,{required:!0,type:"email",value:n.email,onChange:l=>r({...n,email:l.target.value}),placeholder:"Your email address",className:"bg-background"})]})]}),p.jsxs("div",{children:[p.jsx("label",{className:"block text-sm font-medium text-foreground mb-2",children:"Message"}),p.jsx(Lp,{value:n.message,onChange:l=>r({...n,message:l.target.value}),placeholder:"Tell us about your requirements...",className:"bg-background min-h-[120px]"})]}),p.jsxs("div",{className:"flex items-start gap-3",children:[p.jsx(Vp,{id:"consent",checked:n.consent,onCheckedChange:l=>r({...n,consent:l})}),p.jsx("label",{htmlFor:"consent",className:"text-sm text-muted-foreground leading-relaxed",children:"Please click to give us consent to store your data and contact you about the product requested and our services in the future via phone and email."})]}),p.jsx($n,{type:"submit",variant:"accent",size:"lg",className:"w-full",disabled:s,children:s?"Sending...":"Send Enquiry"})]}),p.jsxs(R.div,{variants:ye,className:"mt-8 flex flex-wrap justify-center gap-6 text-muted-foreground",children:[p.jsxs("a",{href:"tel:07725464383",className:"flex items-center gap-2 hover:text-accent transition-colors",children:[p.jsx(Jl,{className:"w-4 h-4"}),"07725 464383"]}),p.jsxs("a",{href:"mailto:[email protected]",className:"flex items-center gap-2 hover:text-accent transition-colors",children:[p.jsx(Hf,{className:"w-4 h-4"}),"[email protected]"]})]})]})})})]})}const US=[{id:1,name:"Chris Sherwin",rating:5,text:"Kim and her husband are a great family run business. Extremely helpful and made the process of buying our new car a breeze. Would highly recommend to anyone looking for a used car in the Nottingham area.",source:"AutoTrader"},{id:2,name:"Sarah Mitchell",rating:5,text:"Excellent service from start to finish. The car was exactly as described and Kim was very helpful with all my questions. The whole buying process was smooth and stress-free.",source:"Google"},{id:3,name:"David Thompson",rating:5,text:"Bought a lovely car from KKL Motors. Very professional service, no pressure sales tactics, just honest advice. Would definitely recommend and will be back for my next car.",source:"AutoTrader"},{id:4,name:"Emma Watson",rating:5,text:"Fantastic experience! Kim was so patient and helpful, answering all our questions. The car was in immaculate condition. Couldn't be happier with our purchase.",source:"Google"},{id:5,name:"Michael Brown",rating:5,text:"Great little dealership with excellent customer service. Kim and her team really go the extra mile. The car was well prepared and the paperwork was handled efficiently.",source:"AutoTrader"},{id:6,name:"Lisa Johnson",rating:5,text:"Second car we have bought from KKL Motors and once again the service has been fantastic. Highly recommend to anyone looking for a quality used car.",source:"Google"},{id:7,name:"James Wilson",rating:5,text:"Very impressed with the service. Car was exactly as described online. Kim was very professional and made the whole process easy. Would recommend without hesitation.",source:"AutoTrader"},{id:8,name:"Rachel Davies",rating:5,text:"Brilliant service from Kim. She was so helpful and made buying my first car a really positive experience. The car is perfect and I couldn't be happier!",source:"Google"},{id:9,name:"Andrew Clarke",rating:5,text:"Top quality service. Kim and her husband are genuine people who care about their customers. Car was spotless and drives beautifully. Highly recommended.",source:"AutoTrader"},{id:10,name:"Sophie Taylor",rating:5,text:"Excellent dealership! Very friendly and professional. They took the time to explain everything and made sure I was completely happy before driving away.",source:"Google"}],Os=()=>US[0],fM="/assets/testimonials-hero-BJOaQ3bh.jpg",Ue={hidden:{opacity:0,y:30},visible:{opacity:1,y:0,transition:{duration:.6}}},Fr={hidden:{opacity:0}
255,visible:{opacity:1,transition:{staggerChildren:.1}}},pM=[{name:"Google Reviews",icon:"ð",url:"https://www.google.com/search?q=KKL+Motors+Nottingham+reviews",description:"Leave a review on our Google Business profile"},{name:"AutoTrader",icon:"ð",url:"https://www.autotrader.co.uk/dealers/nottinghamshire/nottingham/k-k-l-motors-10022171#reviews",description:"Share your experience on AutoTrader"},{name:"Facebook",icon:"ð",url:"#",description:"Review us on our Facebook page"}];function mM(){return p.jsxs("div",{className:"min-h-[900px] bg-background",children:[p.jsx(Ui,{}),p.jsxs("section",{className:"relative h-[450px] min-h-[400px] flex items-center justify-center overflow-hidden",children:[p.jsxs("div",{className:"absolute inset-0",children:[p.jsx("img",{src:fM,alt:"Customer Testimonials",className:"w-full h-full object-cover"}),p.jsx("div",{className:"absolute inset-0 bg-kk-dark/80"})]}),p.jsx("div",{className:"relative z-10 text-center px-4",children:p.jsxs(R.div,{initial:"hidden",animate:"visible",variants:Fr,children:[p.jsx(R.p,{variants:Ue,className:"text-accent font-semibold uppercase tracking-widest mb-4",children:"What Our Customers Say"}),p.jsx(R.h1,{variants:Ue,className:"text-5xl md:text-7xl font-display text-primary-foreground mb-6",children:"TESTIMONIALS"}),p.jsx(R.div,{variants:Ue,className:"accent-bar mx-auto"})]})})]}),p.jsx("section",{className:"section-padding bg-background",children:p.jsxs("div",{className:"container-wide",children:[p.jsxs(R.div,{initial:"hidden",whileInView:"visible",viewport:{once:!0},variants:Fr,className:"text-center mb-12",children:[p.jsx(R.h2,{variants:Ue,className:"text-3xl md:text-4xl font-display text-foreground mb-4",children:"Customer Reviews"}),p.jsx(R.div,{variants:Ue,className:"accent-bar mx-auto"})]}),p.jsx(R.div,{initial:"hidden",whileInView:"visible",viewport:{once:!0},variants:Fr,className:"grid md:grid-cols-2 gap-6",children:US.map(e=>p.jsxs(R.div,{variants:Ue,className:"bg-card rounded-xl p-6 shadow-sm border border-border/50 relative",children:[p.jsx(eh,{className:"w-8 h-8 text-accent/30 absolute top-4 right-4"}),p.jsx("div",{className:"flex gap-1 mb-3",children:[...Array(e.rating)].map((t,n)=>p.jsx(th,{className:"w-4 h-4 fill-accent text-accent"},n))}),p.jsx("p",{className:"text-muted-foreground text-sm leading-relaxed mb-4",children:e.text}),p.jsxs("div",{className:"flex items-center justify-between",children:[p.jsx("p",{className:"font-display text-foreground",children:e.name}),p.jsx("span",{className:"text-xs text-muted-foreground bg-muted px-2 py-1 rounded",children:e.source})]})]},e.id))})]})}),p.jsx("section",{className:"section-padding bg-kk-light",children:p.jsxs("div",{className:"container-wide",children:[p.jsxs(R.div,{initial:"hidden",whileInView:"visible",viewport:{once:!0},variants:Fr,className:"text-center max-w-3xl mx-auto mb-12",children:[p.jsx(R.div,{variants:Ue,className:"mb-6",children:p.jsx(AT,{className:"w-16 h-16 text-accent mx-auto mb-4"})}),p.jsx(R.h2,{variants:Ue,className:"text-3xl md:text-4xl font-display text-foreground mb-4",children:"Share Your Experience"}),p.jsx(R.div,{variants:Ue,className:"accent-bar mx-auto mb-6"}),p.jsx(R.p,{variants:Ue,className:"text-muted-foreground leading-relaxed mb-8",children:"We value your feedback! If you have purchased a vehicle from us, we would love to hear about your experience. Your review helps other customers make informed decisions and helps us continue to improve our service."})]}),p.jsx(R.div,{initial:"hidden",whileInView:"visible",viewport:{once:!0},variants:Fr,className:"grid md:grid-cols-3 gap-6 max-w-4xl mx-auto",children:pM.map((e,t)=>p.jsxs(R.a,{href:e.url,target:"_blank",rel:"noopener noreferrer",variants:Ue,className:"bg-card rounded-2xl p-8 shadow-sm hover:shadow-lg transition-all duration-300 border border-border/50 text-center group hover:border-accent/50",children:[p.jsx("div",{className:"text-5xl mb-4",children:e.icon}),p.jsx("h3",{className:"font-display text-xl text-foreground mb-2 group-hover:text-accent transition-colors",children:e.name}),p.jsx("p",{className:"text-muted-foreground text-sm mb-4",children:e.description}),p.jsxs("div",{className:"flex items-center justify-center gap-2 text-accent font-semibold",children:[p.jsx("span",{children:"Leave a Review"}),p.jsx(Rx,{className:"w-4 h-4"})]})]},t))})]})}),p.jsx("section",{className:"section-padding bg-kk-dark",children:p.jsx("div",{className:"container-wide",children:p.jsxs(R.div,{initial:"hidden",
255whileInView:"visible",viewport:{once:!0},variants:Fr,className:"text-center max-w-3xl mx-auto",children:[p.jsx(R.h2,{variants:Ue,className:"text-3xl md:text-4xl font-display text-primary-foreground mb-4",children:"How to Submit a Review"}),p.jsx(R.div,{variants:Ue,className:"accent-bar mx-auto mb-12"}),p.jsxs(R.div,{variants:Ue,className:"grid md:grid-cols-3 gap-8 text-left",children:[p.jsxs("div",{className:"text-center",children:[p.jsx("div",{className:"w-12 h-12 rounded-full bg-accent text-accent-foreground flex items-center justify-center text-xl font-bold mx-auto mb-4",children:"1"}),p.jsx("h3",{className:"font-display text-lg text-primary-foreground mb-2",children:"Choose a Platform"}),p.jsx("p",{className:"text-primary-foreground/70 text-sm",children:"Select one of the review platforms above where you would like to share your experience."})]}),p.jsxs("div",{className:"text-center",children:[p.jsx("div",{className:"w-12 h-12 rounded-full bg-accent text-accent-foreground flex items-center justify-center text-xl font-bold mx-auto mb-4",children:"2"}),p.jsx("h3",{className:"font-display text-lg text-primary-foreground mb-2",children:"Write Your Review"}),p.jsx("p",{className:"text-primary-foreground/70 text-sm",children:"Share details about your experience, the vehicle you purchased, and our service."})]}),p.jsxs("div",{className:"text-center",children:[p.jsx("div",{className:"w-12 h-12 rounded-full bg-accent text-accent-foreground flex items-center justify-center text-xl font-bold mx-auto mb-4",children:"3"}),p.jsx("h3",{className:"font-display text-lg text-primary-foreground mb-2",children:"Submit & Help Others"}),p.jsx("p",{className:"text-primary-foreground/70 text-sm",children:"Your honest feedback helps future customers and helps us improve our services."})]})]})]})})}),p.jsx("section",{className:"section-padding bg-gradient-accent",children:p.jsx("div",{className:"container-wide",children:p.jsxs(R.div,{initial:"hidden",whileInView:"visible",viewport:{once:!0},variants:Fr,className:"text-center max-w-2xl mx-auto",children:[p.jsx(R.div,{variants:Ue,className:"flex justify-center gap-1 mb-6",children:[...Array(5)].map((e,t)=>p.jsx(th,{className:"w-8 h-8 fill-accent-foreground text-accent-foreground"},t))}),p.jsx(R.h2,{variants:Ue,className:"text-2xl md:text-3xl font-display text-accent-foreground mb-4",children:"Your Feedback Matters"}),p.jsx(R.p,{variants:Ue,className:"text-accent-foreground/80 leading-relaxed mb-8",children:"Every review helps us serve you better. Thank you for taking the time to share your experience with K.K.L Motors."})]})})})]})}const gM="/assets/find-us-hero-Cio5s4MY.jpg",Ur={hidden:{opacity:0,y:30},visible:{opacity:1,y:0,transition:{duration:.6}}},rd={hidden:{opacity:0},visible:{opacity:1,transition:{staggerChildren:.15}}},yM=[{day:"Monday",hours:"09:30 - 17:00",isToday:!1},{day:"Tuesday",hours:"09:30 - 17:00",isToday:!1},{day:"Wednesday",hours:"09:30 - 17:00",isToday:!1},{day:"Thursday",hours:"09:30 - 17:00",isToday:!1},{day:"Friday",hours:"09:30 - 17:00",isToday:!0},{day:"Saturday",hours:"Appointments Only",isToday:!1},{day:"Sunday",hours:"Appointments Only - 17:00",isToday:!1}];function vM(){const[e,t]=b.useState({firstName:"",lastName:"",telephone:"",email:"",message:"",consent:!1}),[n,r]=b.useState(""),{toast:s}=Vf(),[i,o]=b.useState(!1),a=async c=>{if(c.preventDefault(),!e.consent){s({title:"Consent Required",description:"Please provide consent to proceed with the enquiry.",variant:"destructive"});return}o(!0);try{const{data:u,error:d}=await FS.functions.invoke("submit-lead",{body:{firstName:e.firstName,lastName:e.lastName,email:e.email,mobile:e.telephone,message:e.message||"I would like to get in touch"}});if(d){console.error("Error submitting lead:",d),s({title:"Submission Failed",description:"There was an error sending your enquiry. Please try again.",variant:"destructive"});return}console.log("Lead submitted successfully:",u),s({title:"Enquiry Sent",description:"Thank you for your message. We'll be in touch shortly."}),t({firstName:"",lastName:"",telephone:"",email:"",message:"",consent:!1})}catch(u){console.error("Unexpected error:",u),s({title:"Submission Failed",description:"There was an error sending your enquiry. Please try again.",variant:"destructive"})}finally{o(!1)}},l=c=>{c.preventDefault(),n&&window.open(`https://www.google.com/maps/dir/${encodeURIComponent(n)}/167+Castle+Blvd,+Nottingham+NG7+1FU`,"_blank")};return p.jsxs("div",{className:"min-h-[900px] bg-background",children:[p.jsx(Ui,{}),p.jsxs("section",{className:"relative h-[450px] min-h-[400px] flex items-center justify-center overflow-hidden",children:[p.jsxs("div",{className:"absolute inset-0",children:[p.jsx("img",{src:gM,alt:"Find K.K.L Motors",className:"w-full h-full object-cover"}),p.jsx("div",{className:"absolute inset-0 bg-kk-dark/80"})]}),p.jsx("div",{className:"relative z-10 text-center px-4",children:p.jsxs(R.div,{initial:"hidden",animate:"visible",variants:rd,children:[p.jsx(R.p,{variants:Ur,className:"text-accent font-semibold uppercase tracking-widest mb-4",children:"Visit Our Showroom"}),p.jsx(R.h1,{variants:Ur,className:"text-5xl md:text-7xl font-display text-primary-foreground mb-6",children:"FIND K.K.L MOTORS"}),p.jsx(R.div,{variants:Ur,className:"accent-bar mx-auto"})]})})]}),p.jsxs("section",{className:"relative h-[400px] md:h-[500px]",children:[p.jsx("iframe",{src:"https://www.google.com/maps/embed?pb=!1m18!1m12!1m3!1d2404.0893168067!2d-1.1652!3d52.9489!2m3!1f0!2f0!3f0!3m2!1i1024!2i768!4f13.1!3m3!1m2!1s0x4879c3c4d7c3d3d3%3A0x0!2s167%20Castle%2
2550Blvd%2C%20Nottingham%20NG7%201FU!5e0!3m2!1sen!2suk!4v1703000000000",width:"100%",height:"100%",style:{border:0},allowFullScreen:!0,loading:"lazy",referrerPolicy:"no-referrer-when-downgrade",className:"grayscale contrast-125"}),p.jsxs("div",{className:"absolute top-4 left-4 bg-card p-4 rounded-xl shadow-lg max-w-xs",children:[p.jsx("h3",{className:"font-display text-lg text-foreground mb-2",children:"167 Castle Blvd"}),p.jsx("p",{className:"text-sm text-muted-foreground mb-3",children:"167 Castle Blvd, Nottingham NG7 1FU, UK"}),p.jsxs("a",{href:"https://www.google.com/maps/dir//167+Castle+Blvd,+Nottingham+NG7+1FU",target:"_blank",rel:"noopener noreferrer",className:"text-accent text-sm font-semibold hover:underline flex items-center gap-1",children:[p.jsx(dg,{className:"w-4 h-4"}),"Get Directions"]})]})]}),p.jsx("section",{className:"section-padding bg-kk-light",children:p.jsx("div",{className:"container-wide",children:p.jsxs(R.div,{initial:"hidden",whileInView:"visible",viewport:{once:!0},variants:rd,className:"grid md:grid-cols-2 gap-12",children:[p.jsxs(R.div,{variants:Ur,children:[p.jsx("h2",{className:"text-2xl font-display text-kk-dark mb-2",children:"Phone Us On:"}),p.jsx("div",{className:"accent-bar mb-6"}),p.jsxs("div",{className:"space-y-4 mb-8",children:[p.jsxs("a",{href:"tel:07725464383",className:"flex items-center gap-4 p-4 bg-card rounded-xl shadow-sm hover:shadow-md transition-shadow group",children:[p.jsx("div",{className:"w-12 h-12 rounded-lg bg-kk-dark flex items-center justify-center group-hover:bg-accent transition-colors",children:p.jsx(Jl,{className:"w-5 h-5 text-primary-foreground"})}),p.jsxs("div",{children:[p.jsx("p",{className:"text-sm text-muted-foreground",children:"Mobile"}),p.jsx("p",{className:"text-xl font-display text-foreground",children:"07725 464383"})]})]}),p.jsxs("a",{href:"tel:07732670211",className:"flex items-center gap-4 p-4 bg-card rounded-xl shadow-sm hover:shadow-md transition-shadow group",children:[p.jsx("div",{className:"w-12 h-12 rounded-lg bg-kk-dark flex items-center justify-center group-hover:bg-accent transition-colors",children:p.jsx(Jl,{className:"w-5 h-5 text-primary-foreground"})}),p.jsxs("div",{children:[p.jsx("p",{className:"text-sm text-muted-foreground",children:"Landline"}),p.jsx("p",{className:"text-xl font-display text-foreground",children:"07732 670211"})]})]}),p.jsxs("a",{href:"mailto:[email protected]",className:"flex items-center gap-4 p-4 bg-card rounded-xl shadow-sm hover:shadow-md transition-shadow group",children:[p.jsx("div",{className:"w-12 h-12 rounded-lg bg-kk-dark flex items-center justify-center group-hover:bg-accent transition-colors",children:p.jsx(Hf,{className:"w-5 h-5 text-primary-foreground"})}),p.jsxs("div",{children:[p.jsx("p",{className:"text-sm text-muted-foreground",children:"Email"}),p.jsx("p",{className:"text-lg font-semibold text-foreground",children:"[email protected]"})]})]})]}),p.jsx("div",{className:"p-4 bg-accent/10 border border-accent/20 rounded-xl",children:p.jsxs("p",{className:"text-sm text-foreground font-medium",children:[p.jsx("span",{className:"text-accent",children:"ð"})," Please call/message prior to visiting to check availability. This is to avoid disappointment."]})})]}),p.jsxs(R.div,{variants:Ur,children:[p.jsx("h2",{className:"text-2xl font-display text-kk-dark mb-2",children:"Our Opening Hours Are:"}),p.jsx("div",{className:"accent-bar mb-6"}),p.jsx("div",{className:"bg-card rounded-xl shadow-sm overflow-hidden",children:yM.map((c,u)=>p.jsxs("div",{className:`flex justify-between items-center px-6 py-4 border-b border-border last:border-b-0 ${c.isToday?"bg-accent text-accent-foreground":""}`,children:[p.jsxs("div",{className:"flex items-center gap-3",children:[p.jsx(Wf,{className:`w-4 h-4 ${c.isToday?"text-accent-foreground":"text-muted-foreground"}`}),p.jsx("span",{className:`font-semibold ${c.isToday?"text-accent-foreground":"text-foreground"}`,children:c.day})]}),p.jsx("span",{className:c.isToday?"text-accent-foreground font-bold":"text-muted-foreground",children:c.hours})]},u))})]})]})})}),p.jsx("section",{className:"section-padding bg-background",children:p.jsx("div",{className:"container-wide",children:p.jsxs(R.div,{initial:"hidden",
255whileInView:"visible",viewport:{once:!0},variants:rd,children:[p.jsxs(R.div,{variants:Ur,className:"mb-12",children:[p.jsxs("h2",{className:"text-3xl md:text-5xl font-display text-kk-dark mb-4",children:["CONTACT ",p.jsx("span",{className:"text-gradient",children:"US"})]}),p.jsx("div",{className:"accent-bar"})]}),p.jsxs(R.form,{variants:Ur,onSubmit:a,className:"max-w-4xl space-y-6",children:[p.jsxs("div",{className:"grid md:grid-cols-2 gap-6",children:[p.jsxs("div",{children:[p.jsx("label",{className:"block text-sm font-medium text-foreground mb-2",children:"First Name*"}),p.jsx(Zt,{required:!0,value:e.firstName,onChange:c=>t({...e,firstName:c.target.value}),placeholder:"First name",className:"bg-muted/50"})]}),p.jsxs("div",{children:[p.jsx("label",{className:"block text-sm font-medium text-foreground mb-2",children:"Last Name*"}),p.jsx(Zt,{required:!0,value:e.lastName,onChange:c=>t({...e,lastName:c.target.value}),placeholder:"Last name",className:"bg-muted/50"})]})]}),p.jsxs("div",{className:"grid md:grid-cols-2 gap-6",children:[p.jsxs("div",{children:[p.jsx("label",{className:"block text-sm font-medium text-foreground mb-2",children:"Telephone*"}),p.jsx(Zt,{required:!0,type:"tel",value:e.telephone,onChange:c=>t({...e,telephone:c.target.value}),placeholder:"Phone number",className:"bg-muted/50"})]}),p.jsxs("div",{children:[p.jsx("label",{className:"block text-sm font-medium text-foreground mb-2",children:"Email*"}),p.jsx(Zt,{required:!0,type:"email",value:e.email,onChange:c=>t({...e,email:c.target.value}),placeholder:"Email address",className:"bg-muted/50"})]})]}),p.jsxs("div",{children:[p.jsx("label",{className:"block text-sm font-medium text-foreground mb-2",children:"Message*"}),p.jsx(Lp,{required:!0,value:e.message,onChange:c=>t({...e,message:c.target.value}),placeholder:"How can we help you?",className:"bg-muted/50 min-h-[150px]"})]}),p.jsxs("div",{className:"flex items-start gap-3",children:[p.jsx(Vp,{id:"consent",checked:e.consent,onCheckedChange:c=>t({...e,consent:c})}),p.jsx("label",{htmlFor:"consent",className:"text-sm text-muted-foreground leading-relaxed",children:"Please click to give us consent to store your data and contact you about the product requested and our services in the future via phone and email. Please see our privacy policy."})]}),p.jsxs($n,{type:"submit",variant:"dark",size:"lg",disabled:i,children:[i?p.jsx(CT,{className:"w-4 h-4 mr-2 animate-spin"}):p.jsx(RT,{className:"w-4 h-4 mr-2"}),i?"Sending...":"Send Enquiry"]})]})]})})}),p.jsx("section",{className:"py-6 bg-gradient-accent",children:p.jsx("div",{className:"container-wide section-padding py-0",children:p.jsxs("form",{onSubmit:l,className:"flex flex-col md:flex-row items-center justify-center gap-4",children:[p.jsx("p",{className:"text-accent-foreground font-semibold",children:"Get Directions"}),p.jsxs("div",{className:"flex gap-2",children:[p.jsx(Zt,{value:n,onChange:c=>r(c.target.value),placeholder:"Enter your postcode",className:"bg-accent-foreground/20 border-accent-foreground/30 text-accent-foreground placeholder:text-accent-foreground/60 w-48"}),p.jsx($n,{type:"submit",variant:"dark",size:"default",children:p.jsx(dg,{className:"w-4 h-4"})})]})]})})})]})}const wM="/assets/book-services-hero-Dods6TYS.jpg",ro={hidden:{opacity:0,y:30},visible:{opacity:1,y:0,transition:{duration:.6}}},Tv={hidden:{opacity:0},visible:{opacity:1,transition:{staggerChildren:.1}}},xM=[{title:"MOT",description:"Annual MOT testing to keep your vehicle roadworthy and legal.",buttonText:"Book MOT"},{title:"Wheel Alignment",description:"Precise wheel alignment for better handling and tyre longevity.",buttonText:"Book Wheel Alignment"},{title:"Re-Gas",description:"Air conditioning re-gas service to keep you cool.",buttonText:"Book Re-gas"},{title:"Service",description:"Full vehicle servicing to maintain peak performance.",buttonText:"Book Service"},{title:"Mechanical Repair",description:"Expert mechanical repairs for all vehicle issues.",buttonText:"Book Mechanical Repair"}],ol={address:["167 Castle Boulevard","Nottingham","Nottinghamshire","NG7 1GN"],phones:["07725 464383","07732 670211"],email:"[email protected]"};function bM(){const[e,t]=b.useState(""),n=()=>{e&&window.open(`https://www.google.com/maps/dir/${encodeURIComponent(e)}/167+Castle+Boulevard,+Nottingham+NG7+1GN`,"_blank")},r=s=>{const i=encodeURIComponent(`I would like to book ${s==="MOT"?"an":"a"} ${s}, please contact me`);
255window.open(`https://api.whatsapp.com/send/?phone=447427892497&text=${i}`,"_blank")};return p.jsxs("div",{className:"min-h-[900px] bg-background",children:[p.jsx(Ui,{}),p.jsxs("section",{className:"relative h-[350px] min-h-[300px] flex items-center justify-center overflow-hidden",children:[p.jsxs("div",{className:"absolute inset-0",children:[p.jsx("img",{src:wM,alt:"Book Services",className:"w-full h-full object-cover"}),p.jsx("div",{className:"absolute inset-0 bg-kk-dark/80"})]}),p.jsx("div",{className:"relative z-10 text-center px-4",children:p.jsxs(R.div,{initial:"hidden",animate:"visible",variants:Tv,children:[p.jsx(R.h1,{variants:ro,className:"text-4xl md:text-6xl font-display text-primary-foreground mb-4",children:"BOOK NOW"}),p.jsx(R.div,{variants:ro,className:"accent-bar mx-auto"})]})})]}),p.jsx("section",{className:"section-padding bg-kk-light",children:p.jsx("div",{className:"container-wide",children:p.jsxs("div",{className:"grid lg:grid-cols-3 gap-8",children:[p.jsx("div",{className:"lg:col-span-2",children:p.jsx(R.div,{initial:"hidden",whileInView:"visible",viewport:{once:!0},variants:Tv,className:"grid md:grid-cols-2 gap-6",children:xM.map((s,i)=>p.jsxs(R.div,{variants:ro,className:"bg-card rounded-lg p-6 shadow-sm border border-border/50",children:[p.jsx("h3",{className:"font-display text-xl text-foreground mb-1",children:s.title}),p.jsx("div",{className:"w-12 h-1 bg-accent mb-4"}),p.jsx("p",{className:"text-muted-foreground text-sm mb-6",children:s.description}),p.jsx($n,{variant:"default",className:"w-full bg-accent hover:bg-accent/90 text-accent-foreground",onClick:()=>r(s.title),children:s.buttonText})]},i))})}),p.jsxs("div",{className:"space-y-6",children:[p.jsxs(R.div,{initial:"hidden",whileInView:"visible",viewport:{once:!0},variants:ro,className:"bg-card rounded-lg p-6 shadow-sm border border-border/50",children:[p.jsxs("div",{className:"flex items-center justify-between mb-4",children:[p.jsx("h3",{className:"font-display text-xl text-foreground",children:"Customer Reviews"}),p.jsx("a",{href:"/testimonials",className:"text-xs bg-accent text-accent-foreground px-3 py-1 rounded hover:bg-accent/90 transition-colors",children:"SEE ALL"})]}),p.jsxs("div",{className:"relative",children:[p.jsx(eh,{className:"w-6 h-6 text-accent mb-2"}),p.jsx("div",{className:"flex gap-1 mb-3",children:[...Array(Os().rating)].map((s,i)=>p.jsx(th,{className:"w-4 h-4 fill-accent text-accent"},i))}),p.jsx("p",{className:"text-muted-foreground text-sm mb-3 leading-relaxed",children:Os().text.length>150?Os().text.substring(0,150)+"...":Os().text}),p.jsxs("div",{className:"flex items-center justify-between",children:[p.jsx("p",{className:"font-display text-foreground",children:Os().name}),p.jsx("span",{className:"text-xs text-muted-foreground",children:Os().source})]}),p.jsx(eh,{className:"w-6 h-6 text-accent absolute right-0 bottom-0 rotate-180"})]})]}),p.jsxs(R.div,{initial:"hidden",whileInView:"visible",viewport:{once:!0},variants:ro,className:"bg-card rounded-lg p-6 shadow-sm border border-border/50",children:[p.jsx("h3",{className:"font-display text-xl text-foreground mb-4",children:"Contact Details"}),p.jsxs("div",{className:"space-y-4",children:[p.jsxs("div",{className:"flex items-start gap-3",children:[p.jsx(PT,{className:"w-5 h-5 text-accent flex-shrink-0 mt-0.5"}),p.jsx("div",{className:"text-sm text-muted-foreground",children:ol.address.map((s,i)=>p.jsx("p",{children:s},i))})]}),ol.phones.map((s,i)=>p.jsxs("a",{href:`tel:${s.replace(/\s/g,"")}`,className:"flex items-center gap-3 text-sm text-muted-foreground hover:text-accent transition-colors",children:[p.jsx(Jl,{className:"w-5 h-5 text-accent flex-shrink-0"}),s]},i)),p.jsxs("a",{href:`mailto:${ol.email}`,className:"flex items-center gap-3 text-sm text-muted-foreground hover:text-accent transition-colors",children:[p.jsx(Hf,{className:"w-5 h-5 text-accent flex-shrink-0"}),ol.email]})]}),p.jsxs("div",{className:"mt-6 pt-4 border-t border-border",children:[p.jsx("h4",{className:"font-semibold text-foreground text-sm mb-3",children:"GET DIRECTIONS"}),p.jsxs("div",{className:"flex gap-2",children:[p.jsx(Zt,{placeholder:"Enter your postcode",value:e,onCh
255ange:s=>t(s.target.value),className:"flex-1"}),p.jsx($n,{onClick:n,className:"bg-kk-dark hover:bg-kk-dark/90",children:p.jsx(Rx,{className:"w-4 h-4"})})]})]})]})]})]})})})]})}const SM="/assets/aviloo-hero-X6ePbASD.jpg",_M="/assets/aviloo-device-CUIaWQ3b.png",kM="/assets/aviloo-case-open-B3HPK9Rk.png",Ae={hidden:{opacity:0,y:30},visible:{opacity:1,y:0,transition:{duration:.6}}},Is={hidden:{opacity:0},visible:{opacity:1,transition:{staggerChildren:.1}}},EM=[{icon:ET,text:"Accurate State of Health (SoH) measurement based on real-world driving, not estimates"},{icon:Kf,text:"Independent and manufacturer-neutral testing for unbiased results"},{icon:TT,text:"Certified, easy-to-understand battery health report suitable for retail, trade, and fleet use"},{icon:Nx,text:"Supports stronger resale values and builds buyer confidence in used EVs"},{icon:jT,text:"Reduces risk for trade and fleet operators when purchasing, remarketing, or managing EVs"},{icon:Px,text:"Early detection of battery degradation to support maintenance planning and cost control"},{icon:Ox,text:"Ideal for fleet audits, procurement decisions, and end-of-lease assessments"}];function TM(){const e=()=>{const t=encodeURIComponent("I would like to book an AVILOO Battery Test, please contact me");window.open(`https://api.whatsapp.com/send/?phone=447427892497&text=${t}`,"_blank")};return p.jsxs("div",{className:"min-h-[900px] bg-background",children:[p.jsx(Ui,{}),p.jsxs("section",{className:"relative h-[450px] min-h-[400px] flex items-center justify-center overflow-hidden",children:[p.jsxs("div",{className:"absolute inset-0",children:[p.jsx("img",{src:SM,alt:"AVILOO Battery Test",className:"w-full h-full object-cover"}),p.jsx("div",{className:"absolute inset-0 bg-kk-dark/80"})]}),p.jsx("div",{className:"relative z-10 text-center px-4",children:p.jsxs(R.div,{initial:"hidden",animate:"visible",variants:Is,children:[p.jsx(R.p,{variants:Ae,className:"text-accent font-semibold uppercase tracking-widest mb-4",children:"EV Battery Diagnostics"}),p.jsx(R.h1,{variants:Ae,className:"text-5xl md:text-7xl font-display text-primary-foreground mb-6",children:"AVILOO BATTERY TEST"}),p.jsx(R.div,{variants:Ae,className:"accent-bar mx-auto"})]})})]}),p.jsx("section",{className:"section-padding bg-kk-light",children:p.jsx("div",{className:"container-wide",children:p.jsxs("div",{className:"grid lg:grid-cols-2 gap-12 items-start",children:[p.jsxs(R.div,{initial:"hidden",whileInView:"visible",viewport:{once:!0},variants:Is,children:[p.jsx(R.h2,{variants:Ae,className:"text-3xl md:text-4xl font-display text-foreground mb-4",children:"Market-Leading Battery Diagnostics"}),p.jsx(R.div,{variants:Ae,className:"accent-bar mb-6"}),p.jsx(R.p,{variants:Ae,className:"text-muted-foreground leading-relaxed mb-6",children:"KKL Motors Nottingham now offers the AVILOO battery test, the market-leading, manufacturer-independent diagnostic solution for electric vehicle high-voltage batteries. Using real-world driving data, the AVILOO test accurately measures usable battery capacity and State of Health (SoH), producing a detailed, certified battery health report."}),p.jsx(R.p,{variants:Ae,className:"text-muted-foreground leading-relaxed mb-8",children:"Designed for private owners, used-EV buyers and sellers, trade professionals, and fleet operators, the AVILOO battery test delivers complete transparency and confidence in EV battery condition."}),p.jsx(R.div,{variants:Ae,children:p.jsx($n,{onClick:e,className:"bg-accent hover:bg-accent/90 text-accent-foreground font-display uppercase tracking-wider px-8 py-6 text-lg",children:"Book a Battery Test"})})]}),p.jsx(R.div,{initial:"hidden",whileInView:"visible",viewport:{once:!0},variants:Ae,className:"flex items-center justify-center",children:p.jsx("div",{className:"rounded-2xl overflow-hidden shadow-lg border border-border/50 bg-card p-8",children:p.jsx("img",{src:_M,alt:"AVILOO Battery Diagnostics device and case",className:"w-full max-w-md h-auto object-contain mx-auto"})})})]})})}),p.jsx("section",{className:"section-padding bg-kk-dark",children:p.jsx("div",{className:"container-wide",children:p.jsx(R.div,{initial:"hidden",
255whileInView:"visible",viewport:{once:!0},variants:Ae,className:"max-w-4xl mx-auto",children:p.jsx("div",{className:"rounded-2xl overflow-hidden shadow-lg border border-border/50",children:p.jsx("img",{src:kM,alt:"AVILOO Battery Diagnostics kit â case, cables, and testing box",className:"w-full h-auto object-cover"})})})})}),p.jsx("section",{className:"section-padding bg-background",children:p.jsxs("div",{className:"container-wide",children:[p.jsxs(R.div,{initial:"hidden",whileInView:"visible",viewport:{once:!0},variants:Is,className:"text-center mb-12",children:[p.jsx(R.h2,{variants:Ae,className:"text-3xl md:text-4xl font-display text-foreground mb-4",children:"Key Benefits"}),p.jsx(R.div,{variants:Ae,className:"accent-bar mx-auto"})]}),p.jsx(R.div,{initial:"hidden",whileInView:"visible",viewport:{once:!0},variants:Is,className:"grid md:grid-cols-2 gap-6 max-w-5xl mx-auto",children:EM.map((t,n)=>p.jsxs(R.div,{variants:Ae,className:"flex gap-4 items-start bg-card rounded-xl p-6 shadow-sm border border-border/50",children:[p.jsx(t.icon,{className:"w-6 h-6 text-accent flex-shrink-0 mt-0.5"}),p.jsx("p",{className:"text-muted-foreground text-sm leading-relaxed",children:t.text})]},n))})]})}),p.jsx("section",{className:"section-padding bg-kk-dark",children:p.jsx("div",{className:"container-wide",children:p.jsxs(R.div,{initial:"visible",animate:"visible",variants:Is,className:"text-center max-w-3xl mx-auto",children:[p.jsx(R.h2,{variants:Ae,className:"text-3xl md:text-4xl font-display text-primary-foreground mb-4",children:"Who Is It For?"}),p.jsx(R.div,{variants:Ae,className:"accent-bar mx-auto mb-12"}),p.jsx(R.div,{variants:Ae,className:"grid md:grid-cols-3 gap-8",children:[{icon:NT,title:"Private Owners",desc:"Know the true health of your EV battery before selling or for peace of mind."},{icon:Nx,title:"Trade Professionals",desc:"Make informed purchasing and remarketing decisions with certified data."},{icon:Ox,title:"Fleet Operators",desc:"Audit fleets, plan maintenance, and manage end-of-lease assessments."}].map((t,n)=>p.jsxs("div",{className:"text-center",children:[p.jsx("div",{className:"w-14 h-14 rounded-full bg-accent text-accent-foreground flex items-center justify-center mx-auto mb-4",children:p.jsx(t.icon,{className:"w-7 h-7"})}),p.jsx("h3",{className:"font-display text-lg text-primary-foreground mb-2",children:t.title}),p.jsx("p",{className:"text-primary-foreground/70 text-sm",children:t.desc})]},n))})]})})}),p.jsx("section",{className:"section-padding bg-gradient-accent",children:p.jsx("div",{className:"container-wide",children:p.jsxs(R.div,{initial:"hidden",whileInView:"visible",viewport:{once:!0},variants:Is,className:"text-center max-w-2xl mx-auto",children:[p.jsx(R.div,{variants:Ae,className:"mb-6",children:p.jsx(Px,{className:"w-16 h-16 text-accent-foreground mx-auto"})}),p.jsx(R.h2,{variants:Ae,className:"text-2xl md:text-3xl font-display text-accent-foreground mb-4",children:"Get Your Battery Tested Today"}),p.jsx(R.p,{variants:Ae,className:"text-accent-foreground/80 leading-relaxed mb-8",children:"Book your AVILOO battery test at KKL Motors Nottingham and get a certified, independent report on your EV's battery health."}),p.jsx(R.div,{variants:Ae,children:p.jsx($n,{onClick:e,className:"bg-kk-dark text-primary-foreground hover:bg-kk-charcoal font-display uppercase tracking-wider px-8 py-6 text-lg",children:"Book via WhatsApp"})})]})})})]})}const CM=()=>{const e=Uc();return b.useEffect(()=>{console.error("404 Error: User attempted to access non-existent route:",e.pathname)},[e.pathname]),p.jsxs("div",{className:"flex min-h-[900px] items-center justify-center bg-muted",children:[p.jsx(Ui,{}),p.jsxs("div",{className:"text-center",children:[p.jsx("h1",{className:"mb-4 text-4xl font-bold",children:"404"}),p.jsx("p",{className:"mb-4 text-xl text-muted-foreground",children:"Oops! Page not found"}),p.jsx("a",{href:"/",className:"text-primary underline hover:text-primary/90",children:"Return to Home"})]})]})},PM=new tR,AM=()=>p.jsx(rR,{client:PM,children:p.jsxs(jA,{children:[p.jsx(mC,{}),p.jsx(qC,{}),p.jsx(QR,{children:p.jsxs(qR,{children:[p.jsx(Jn,{path:"/",element:p.jsx(HR,{to:"/pod-point",replace:!0})}),p.jsx(Jn,{path:"/pod-point",element:p.jsx(hM,{})}),p.jsx(Jn,{path:"/testimonials",element:p.jsx(mM,{})}),p.jsx(Jn,{path:"/find-us",element:p.jsx(vM,{})}),p.jsx(Jn,{path:"/book-services",element:p.jsx(bM,{})}),p.jsx(Jn,{path:"/aviloo-battery-test",element:p.jsx(TM,{})}),p.jsx(Jn,{path:"*",element:p.jsx(CM,{})})]})})]})});Qw(document.getElementById("root")).render(p.jsx(AM,{}));
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.