PageSourceSearch

https://jumaintauber.lovable.app/assets/index-Cpynoz2c.js

js jumaintauber.lovable.app collected 2026-10-03 03:30:55 UTC 843,605 bytes, 254 lines download raw bytes

vendor: 4,868 bytes, lines 1-9
1var xA=Object.defineProperty;var hy=e=>{throw TypeError(e)};var bA=(e,t,n)=>t in e?xA(e,t,{enumerable:!0,configurable:!0,writable:!0,value:n}):e[t]=n;var pr=(e,t,n)=>bA(e,typeof t!="symbol"?t+"":t,n),yf=(e,t,n)=>t.has(e)||hy("Cannot "+n);var N=(e,t,n)=>(yf(e,t,"read from private field"),n?n.call(e):t.get(e)),me=(e,t,n)=>t.has(e)?hy("Cannot add the same private member more than once"):t instanceof WeakSet?t.add(e):t.set(e,n),oe=(e,t,n,r)=>(yf(e,t,"write to private field"),r?r.call(e,n):t.set(e,n),n),at=(e,t,n)=>(yf(e,t,"access private method"),n);var cc=(e,t,n,r)=>({set _(s){oe(e,t,s,n)},get _(){return N(e,t,r)}});function _A(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)}})();var an=typeof globalThis<"u"?globalThis:typeof window<"u"?window:typeof global<"u"?global:typeof self<"u"?self:{};function Il(e){return e&&e.__esModule&&Object.prototype.hasOwnProperty.call(e,"default")?e.default:e}function SA(e){if(e.__esModule)return e;var t=e.default;if(typeof t=="function"){var n=function r(){return this instanceof r?Reflect.construct(t,arguments,this.constructor):t.apply(this,arguments)};n.prototype=t.prototype}else n={};return Object.defineProperty(n,"__esModule",{value:!0}),Object.keys(e).forEach(function(r){var s=Object.getOwnPropertyDescriptor(e,r);Object.defineProperty(n,r,s.get?s:{enumerable:!0,get:function(){return e[r]}})}),n}var Zb={exports:{}},Sd={},Jb={exports:{}},ue={};/**
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 Ll=Symbol.for("react.element"),kA=Symbol.for("react.portal"),EA=Symbol.for("react.fragment"),CA=Symbol.for("react.strict_mode"),TA=Symbol.for("react.profiler"),AA=Symbol.for("react.provider"),PA=Symbol.for("react.context"),jA=Symbol.for("react.forward_ref"),NA=Symbol.for("react.suspense"),RA=Symbol.for("react.memo"),OA=Symbol.for("react.lazy"),py=Symbol.iterator;function MA(e){return e===null||typeof e!="object"?null:(e=py&&e[py]||e["@@iterator"],typeof e=="function"?e:null)}var Xb={isMounted:function(){return!1},enqueueForceUpdate:function(){},enqueueReplaceState:function(){},enqueueSetState:function(){}},e1=Object.assign,t1={};function Go(e,t,n){this.props=e,this.context=t,this.refs=t1,this.updater=n||Xb}Go.prototype.isReactComponent={};Go.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")};Go.prototype.forceUpdate=function(e){this.updater.enqueueForceUpdate(this,e,"forceUpdate")};function n1(){}n1.prototype=Go.prototype;function Gm(e,t,n){this.props=e,this.context=t,this.refs=t1,this.updater=n||Xb}var Qm=Gm.prototype=new n1;Qm.constructor=Gm;e1(Qm,Go.prototype);Qm.isPureReactComponent=!0;var my=Array.isArray,r1=Object.prototype.hasOwnProperty,Zm={current:null},s1={key:!0,ref:!0,__self:!0,__source:!0};function i1(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)r1.call(t,r)&&!s1.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:Ll,type:e,key:i,ref:o,props:s,_owner:Zm.current}}function DA(e,t){return{$$typeof:Ll,type:e.type,key:t,ref:e.ref,props:e.props,_owner:e._owner}}function Jm(e){return typeof e=="object"&&e!==null&&e.$$typeof===Ll}function IA(e){var t={"=":"=0",":":"=2"};return"$"+e.replace(/[=:]/g,function(n){return t[n]})}var gy=/\/+/g;function wf(e,t){return typeof e=="object"&&e!==null&&e.key!=null?IA(""+e.key):t.toString(36)}
vendor: 4,786 bytes, lines 9-17
9function Gc(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 Ll:case kA:o=!0}}if(o)return o=e,s=s(o),e=r===""?"."+wf(o,0):r,my(s)?(n="",e!=null&&(n=e.replace(gy,"$&/")+"/"),Gc(s,t,n,"",function(c){return c})):s!=null&&(Jm(s)&&(s=DA(s,n+(!s.key||o&&o.key===s.key?"":(""+s.key).replace(gy,"$&/")+"/")+e)),t.push(s)),1;if(o=0,r=r===""?".":r+":",my(e))for(var a=0;a<e.length;a++){i=e[a];var l=r+wf(i,a);o+=Gc(i,t,n,l,s)}else if(l=MA(e),typeof l=="function")for(e=l.call(e),a=0;!(i=e.next()).done;)i=i.value,l=r+wf(i,a++),o+=Gc(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 uc(e,t,n){if(e==null)return e;var r=[],s=0;return Gc(e,r,"","",function(i){return t.call(n,i,s++)}),r}function LA(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 bt={current:null},Qc={transition:null},FA={ReactCurrentDispatcher:bt,ReactCurrentBatchConfig:Qc,ReactCurrentOwner:Zm};function o1(){throw Error("act(...) is not supported in production builds of React.")}ue.Children={map:uc,forEach:function(e,t,n){uc(e,function(){t.apply(this,arguments)},n)},count:function(e){var t=0;return uc(e,function(){t++}),t},toArray:function(e){return uc(e,function(t){return t})||[]},only:function(e){if(!Jm(e))throw Error("React.Children.only expected to receive a single React element child.");return e}};ue.Component=Go;ue.Fragment=EA;ue.Profiler=TA;ue.PureComponent=Gm;ue.StrictMode=CA;ue.Suspense=NA;ue.__SECRET_INTERNALS_DO_NOT_USE_OR_YOU_WILL_BE_FIRED=FA;ue.act=o1;ue.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=e1({},e.props),s=e.key,i=e.ref,o=e._owner;if(t!=null){if(t.ref!==void 0&&(i=t.ref,o=Zm.current),t.key!==void 0&&(s=""+t.key),e.type&&e.type.defaultProps)var a=e.type.defaultProps;for(l in t)r1.call(t,l)&&!s1.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:Ll,type:e.type,key:s,ref:i,props:r,_owner:o}};ue.createContext=function(e){return e={$$typeof:PA,_currentValue:e,_currentValue2:e,_threadCount:0,Provider:null,Consumer:null,_defaultValue:null,_globalName:null},e.Provider={$$typeof:AA,_context:e},e.Consumer=e};ue.createElement=i1;ue.createFactory=function(e){var t=i1.bind(null,e);return t.type=e,t};ue.createRef=function(){return{current:null}};ue.forwardRef=function(e){return{$$typeof:jA,render:e}};ue.isValidElement=Jm;ue.lazy=function(e){return{$$typeof:OA,_payload:{_status:-1,_result:e},_init:LA}};ue.memo=function(e,t){return{$$typeof:RA,type:e,compare:t===void 0?null:t}};ue.startTransition=function(e){var t=Qc.transition;Qc.transition={};try{e()}finally{Qc.transition=t}};ue.unstable_act=o1;ue.useCallback=function(e,t){return bt.current.useCallback(e,t)};ue.useContext=function(e){return bt.current.useContext(e)};ue.useDebugValue=function(){};ue.useDeferredValue=function(e){return bt.current.useDeferredValue(e)};ue.useEffect=function(e,t){return bt.current.useEffect(e,t)};ue.useId=function(){return bt.current.useId()};ue.useImperativeHandle=function(e,t,n){return bt.current.useImperativeHandle(e,t,n)};ue.useInsertionEffect=function(e,t){return bt.current.useInsertionEffect(e,t)};ue.useLayoutEffect=function(e,t){return bt.current.useLayoutEffect(e,t)};ue.useMemo=function(e,t){return bt.current.useMemo(e,t)};ue.useReducer=function(e,t,n){return bt.current.useReducer(e,t,n)};ue.useRef=function(e){return bt.current.useRef(e)};ue.useState=function(e){return bt.current.useState(e)};ue.useSyncExternalStore=function(e,t,n){return bt.current.useSyncExternalStore(e,t,n)};ue.useTransition=function(){return bt.current.useTransition()};ue.version="18.3.1";Jb.exports=ue;var w=Jb.exports;const D=Il(w),Xm=_A({__proto__:null,default:D},[w]);/**
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 $A=w,BA=Symbol.for("react.element"),VA=Symbol.for("react.fragment"),UA=Object.prototype.hasOwnProperty,zA=$A.__SECRET_INT
vendor: 15,231 bytes, lines 17-37
17ERNALS_DO_NOT_USE_OR_YOU_WILL_BE_FIRED.ReactCurrentOwner,WA={key:!0,ref:!0,__self:!0,__source:!0};function a1(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)UA.call(t,r)&&!WA.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:BA,type:e,key:i,ref:o,props:s,_owner:zA.current}}Sd.Fragment=VA;Sd.jsx=a1;Sd.jsxs=a1;Zb.exports=Sd;var f=Zb.exports,l1={exports:{}},Kt={},c1={exports:{}},u1={};/**
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,j){var $=C.length;C.push(j);e:for(;0<$;){var Q=$-1>>>1,Y=C[Q];if(0<s(Y,j))C[Q]=j,C[$]=Y,$=Q;else break e}}function n(C){return C.length===0?null:C[0]}function r(C){if(C.length===0)return null;var j=C[0],$=C.pop();if($!==j){C[0]=$;e:for(var Q=0,Y=C.length,F=Y>>>1;Q<F;){var W=2*(Q+1)-1,le=C[W],xe=W+1,te=C[xe];if(0>s(le,$))xe<Y&&0>s(te,le)?(C[Q]=te,C[xe]=$,Q=xe):(C[Q]=le,C[W]=$,Q=W);else if(xe<Y&&0>s(te,$))C[Q]=te,C[xe]=$,Q=xe;else break e}}return j}function s(C,j){var $=C.sortIndex-j.sortIndex;return $!==0?$:C.id-j.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,p=!1,b=!1,g=!1,x=typeof setTimeout=="function"?setTimeout:null,y=typeof clearTimeout=="function"?clearTimeout:null,m=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 j=n(c);j!==null;){if(j.callback===null)r(c);else if(j.startTime<=C)r(c),j.sortIndex=j.expirationTime,t(l,j);else break;j=n(c)}}function _(C){if(g=!1,v(C),!b)if(n(l)!==null)b=!0,V(S);else{var j=n(c);j!==null&&O(_,j.startTime-C)}}function S(C,j){b=!1,g&&(g=!1,y(T),T=-1),p=!0;var $=h;try{for(v(j),d=n(l);d!==null&&(!(d.expirationTime>j)||C&&!B());){var Q=d.callback;if(typeof Q=="function"){d.callback=null,h=d.priorityLevel;var Y=Q(d.expirationTime<=j);j=e.unstable_now(),typeof Y=="function"?d.callback=Y:d===n(l)&&r(l),v(j)}else r(l);d=n(l)}if(d!==null)var F=!0;else{var W=n(c);W!==null&&O(_,W.startTime-j),F=!1}return F}finally{d=null,h=$,p=!1}}var k=!1,E=null,T=-1,P=5,A=-1;function B(){return!(e.unstable_now()-A<P)}function I(){if(E!==null){var C=e.unstable_now();A=C;var j=!0;try{j=E(!0,C)}finally{j?Z():(k=!1,E=null)}}else k=!1}var Z;if(typeof m=="function")Z=function(){m(I)};else if(typeof MessageChannel<"u"){var R=new MessageChannel,U=R.port2;R.port1.onmessage=I,Z=function(){U.postMessage(null)}}else Z=function(){x(I,0)};function V(C){E=C,k||(k=!0,Z())}function O(C,j){T=x(function(){C(e.unstable_now())},j)}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(){b||p||(b=!0,V(S))},e.unstable_forceFrameRate=function(C){0>C||125<C?console.error("forceFrameRate takes a positive int between 0 and 125, forcing frame rates higher than 125 fps is not supported"):P=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 j=3;break;default:j=h}var $=h;h=j;try{return C()}finally{h=$}},e.unstable_pauseExecution=function(){},e.unstable_requestPaint=function(){},e.unstable_runWithPriority=function(C,j){switch(C){case 1:case 2:case 3:case 4:case 5:break;default:C=3}var $=h;h=C;try{return j()}finally{h=$}},e.unstable_scheduleCallback=function(C,j,$){var Q=e.unstable_now();switch(typeof $=="object"&&$!==null?($=$.delay,$=typeof $=="number"&&0<$?Q+$:Q):$=Q,C){case 1:var Y=-1;break;case 2:Y=250;break;case 5:Y=1073741823;break;case 4:Y=1e4;break;default:Y=5e3}return Y=$+Y,C={id:u++,callback:j,priorityLevel:C,startTime:$,expirationTime:Y,sortIndex:-1},$>Q?(C.sortIndex=$,t(c,C),n(l)===null&&C===n(c)&&(g?(y(T),T=-1):g=!0,O(_,$-Q))):(C.sortIndex=Y,t(l,C),b||p||(b=!0,V(S))),C},e.unstable_shouldYield=B,e.unstable_wrapCallback=function(C){var j=h;return function(){var $=h;h=j;try{return C.apply(this,arguments)}finally{h=$}}}})(u1);c1.exports=u1;var HA=c1.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 KA=w,zt=HA;function M(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 d1=new Set,Xa={};function bi(e,t){jo(e,t),jo(e+"Capture",t)}function jo(e,t){for(Xa[e]=t,e=0;e<t.length;e++)d1.add(t[e])}var Er=!(typeof window>"u"||typeof window.document>"u"||typeof window.document.createElement>"u"),Kh=Object.prototype.hasOwnProperty,qA=/^[: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]*$/,vy={},yy={};function YA(e){return Kh.call(yy,e)?!0:Kh.call(vy,e)?!1:qA.test(e)?yy[e]=!0:(vy[e]=!0,!1)}function GA(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 QA(e,t,n,r){if(t===null||typeof t>"u"||GA(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 _t(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 st={};"children dangerouslySetInnerHTML defaultValue defaultChecked innerHTML suppressContentEditableWarning suppressHydrationWarning style".split(" ").forEach(function(e){st[e]=new _t(e,0,!1,e,null,!1,!1)});[["acceptCharset","accept-charset"],["className","class"],["htmlFor","for"],["httpEquiv","http-equiv"]].forEach(function(e){var t=e[0];st[t]=new _t(t,1,!1,e[1],null,!1,!1)});["contentEditable","draggable","spellCheck","value"].forEach(function(e){st[e]=new _t(e,2,!1,e.toLowerCase(),null,!1,!1)});["autoReverse","externalResourcesRequired","focusable","preserveAlpha"].forEach(function(e){st[e]=new _t(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){st[e]=new _t(e,3,!1,e.toLowerCase(),null,!1,!1)});["checked","multiple","muted","selected"].forEach(function(e){st[e]=new _t(e,3,!0,e,null,!1,!1)});["capture","download"].forEach(function(e){st[e]=new _t(e,4,!1,e,null,!1,!1)});["cols","rows","size","span"].forEach(function(e){st[e]=new _t(e,6,!1,e,null,!1,!1)});["rowSpan","start"].forEach(function(e){st[e]=new _t(e,5,!1,e.toLowerCase(),null,!1,!1)});var eg=/[\-:]([a-z])/g;function tg(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(eg,tg);st[t]=new _t(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(eg,tg);st[t]=new _t(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(eg,tg);st[t]=new _t(t,1,!1,e,"http://www.w3.org/XML/1998/namespace",!1,!1)});["tabIndex","crossOrigin"].forEach(function(e){st[e]=new _t(e,1,!1,e.toLowerCase(),null,!1,!1)});st.xlinkHref=new _t("xlinkHref",1,!1,"xlink:href","http://www.w3.org/1999/xlink",!0,!1);["src","href","action","formAction"].forEach(function(e){st[e]=new _t(e,1,!1,e.toLowerCase(),null,!0,!0)});function ng(e,t,n,r){var s=st.hasOwnProperty(t)?st[t]:null;(s!==null?s.type!==0:r||!(2<t.length)||t[0]!=="o"&&t[0]!=="O"||t[1]!=="n"&&t[1]!=="N")&&(QA(t,n,s,r)&&(n=null),r||s===null?YA(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 Rr=KA.__SECRET_INTERNALS_DO_NOT_USE_OR_YOU_WILL_BE_FIRED,dc=Symbol.for("react.element"),Yi=Symbol.for("react.portal"),Gi=Symbol.for("react.fragment"),rg=Symbol.for("react.strict_mode"),qh=Symbol.for("react.profiler"),f1=Symbol.for("react.provider"),h1=Symbol.for("react.context"),sg=Symbol.for("react.forward_ref"),Yh=Symbol.for("react.suspense"),Gh=Symbol.for("react.suspense_list"),ig=Symbol.for("react.memo"),qr=Symbol.for("react.lazy"),p1=Symbol.for("react.offscreen"),wy=Symbol.iterator;function ca(e){return e===null||typeof e!="object"?null:(e=wy&&e[wy]||e["@@iterator"],typeof e=="function"?e:null)}var Le=Object.assign,xf;function Ca(e){if(xf===void 0)try{throw Error()}catch(n){var t=n.stack.trim().match(/\n( *(at )?)/);xf=t&&t[1]||""}return`
34`+xf+e}var bf=!1;function _f(e,t){if(!e||bf)return"";bf=!0;var n=Error.prepareStackTrace;Error.prepareStackTrace=void 0;try{if(t)if(t=function(){throw Error()},Object.defineProperty(t.prototype,"props",{set:function(){throw Error()}}),typeof Reflect=="object"&&Reflect.construct){try{Reflect.construct(t,[])}catch(c){var r=c}Reflect.construct(e,[],t)}else{try{t.call()}catch(c){r=c}e.call(t.prototype)}else{try{throw Error()}catch(c){r=c}e()}}catch(c){if(c&&r&&typeof c.stack=="string"){for(var 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{bf=!1,Error.prepareStackTrace=n}return(e=e?e.displayName||e.name:"")?Ca(e):""}function ZA(e){switch(e.tag){case 5:return Ca(e.type);case 16:return Ca("Lazy");case 13:return Ca("Suspense");case 19:return Ca("SuspenseList");case 0:case 2:case 15:return e=_f(e.type,!1),e;case 11:return e=_f(e.type.render,!1),e;case 1:return e=_f(e.type,!0),e;default:return""}}function Qh(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 Gi:return"Fragment";case Yi:return"Portal";case qh:return"Profiler";case rg:return"StrictMode";case Yh:return"Suspense";case Gh:return"SuspenseList"}if(typeof e=="object")switch(e.$$typeof){case h1:return(e.displayName||"Context")+".Consumer";case f1:return(e._context.displayName||"Context")+".Provider";case sg:var t=e.render;return e=e.displayName,e||(e=t.displayName||t.name||"",e=e!==""?"ForwardRef("+e+")":"ForwardRef"),e;case ig:return t=e.displayName||null,t!==null?t:Qh(e.type)||"Memo";case qr:t=e._payload,e=e._init;try{return Qh(e(t))}catch{}}return null}function JA(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 Qh(t);case 8:return t===rg?"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 ws(e){switch(typeof e){case"boolean":case"number":case"string":case"undefined":return e;case"object":return e;default:return""}}function m1(e){var t=e.type;return(e=e.nodeName)&&e.toLowerCase()==="input"&&(t==="checkbox"||t==="radio")}function XA(e){var t=m1(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 fc(e){e._valueTracker||(e._valueTracker=XA(e))}function g1(e){if(!e)return!1;var t=e._valueTracker;if(!t)return!0;var n=t.getValue(),r="";return e&&(r=m1(e)?e.checked?"true":"false":e.value),e=r,e!==n?(t.setValue(e),!0):!1}function Su(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 Zh(e,t){var n=t.checked;return Le({},t,{defaultChecked:void 0,defaultValue:void 0,value:void 0,checked:n??e._wrapperState.initialChecked})}function xy(e,t){var n=t.defaultValue==null?"":t.defaultValue,r=t.checked!=null?t.checked:t.defaultChecked;n=ws(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}}
vendor: 4,651 bytes, line 37
37function v1(e,t){t=t.checked,t!=null&&ng(e,"checked",t,!1)}function Jh(e,t){v1(e,t);var n=ws(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")?Xh(e,t.type,n):t.hasOwnProperty("defaultValue")&&Xh(e,t.type,ws(t.defaultValue)),t.checked==null&&t.defaultChecked!=null&&(e.defaultChecked=!!t.defaultChecked)}function by(e,t,n){if(t.hasOwnProperty("value")||t.hasOwnProperty("defaultValue")){var r=t.type;if(!(r!=="submit"&&r!=="reset"||t.value!==void 0&&t.value!==null))return;t=""+e._wrapperState.initialValue,n||t===e.value||(e.value=t),e.defaultValue=t}n=e.name,n!==""&&(e.name=""),e.defaultChecked=!!e._wrapperState.initialChecked,n!==""&&(e.name=n)}function Xh(e,t,n){(t!=="number"||Su(e.ownerDocument)!==e)&&(n==null?e.defaultValue=""+e._wrapperState.initialValue:e.defaultValue!==""+n&&(e.defaultValue=""+n))}var Ta=Array.isArray;function co(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=""+ws(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 ep(e,t){if(t.dangerouslySetInnerHTML!=null)throw Error(M(91));return Le({},t,{value:void 0,defaultValue:void 0,children:""+e._wrapperState.initialValue})}function _y(e,t){var n=t.value;if(n==null){if(n=t.children,t=t.defaultValue,n!=null){if(t!=null)throw Error(M(92));if(Ta(n)){if(1<n.length)throw Error(M(93));n=n[0]}t=n}t==null&&(t=""),n=t}e._wrapperState={initialValue:ws(n)}}function y1(e,t){var n=ws(t.value),r=ws(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 Sy(e){var t=e.textContent;t===e._wrapperState.initialValue&&t!==""&&t!==null&&(e.value=t)}function w1(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 tp(e,t){return e==null||e==="http://www.w3.org/1999/xhtml"?w1(t):e==="http://www.w3.org/2000/svg"&&t==="foreignObject"?"http://www.w3.org/1999/xhtml":e}var hc,x1=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(hc=hc||document.createElement("div"),hc.innerHTML="<svg>"+t.valueOf().toString()+"</svg>",t=hc.firstChild;e.firstChild;)e.removeChild(e.firstChild);for(;t.firstChild;)e.appendChild(t.firstChild)}});function el(e,t){if(t){var n=e.firstChild;if(n&&n===e.lastChild&&n.nodeType===3){n.nodeValue=t;return}}e.textContent=t}var Ma={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},eP=["Webkit","ms","Moz","O"];Object.keys(Ma).forEach(function(e){eP.forEach(function(t){t=t+e.charAt(0).toUpperCase()+e.substring(1),Ma[t]=Ma[e]})});function b1(e,t,n){return t==null||typeof t=="boolean"||t===""?"":n||typeof t!="number"||t===0||Ma.hasOwnProperty(e)&&Ma[e]?(""+t).trim():t+"px"}function _1(e,t){e=e.style;for(var n in t)if(t.hasOwnProperty(n)){var r=n.indexOf("--")===0,s=b1(n,t[n],r);n==="float"&&(n="cssFloat"),r?e.setProperty(n,s):e[n]=s}}var tP=Le({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 np(e,t){if(t){if(tP[e]&&(t.children!=null||t.dangerouslySetInnerHTML!=null))throw Error(M(137,e));if(t.dangerouslySetInnerHTML!=null){if(t.children!=null)throw Error(M(60));if(typeof t.dangerouslySetInnerHTML!="object"||!("__html"in t.dangerouslySetInnerHTML))throw Error(M(61))}if(t.style!=null&&typeof t.style!="object")throw Error(M(62))}}function rp(e,t){if(e.indexOf("-")===-1)return typeof t.is=="str
37ing";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 sp=null;function og(e){return e=e.target||e.srcElement||window,e.correspondingUseElement&&(e=e.correspondingUseElement),e.nodeType===3?e.parentNode:e}var ip=null,uo=null,fo=null;function ky(e){if(e=Bl(e)){if(typeof ip!="function")throw Error(M(280));var t=e.stateNode;t&&(t=Ad(t),ip(e.stateNode,e.type,t))}}function S1(e){uo?fo?fo.push(e):fo=[e]:uo=e}function k1(){if(uo){var e=uo,t=fo;if(fo=uo=null,ky(e),t)for(e=0;e<t.length;e++)ky(t[e])}}function E1(e,t){return e(t)}function C1(){}var Sf=!1;function T1(e,t,n){if(Sf)return e(t,n);Sf=!0;try{return E1(e,t,n)}finally{Sf=!1,(uo!==null||fo!==null)&&(C1(),k1())}}function tl(e,t){var n=e.stateNode;if(n===null)return null;var r=Ad(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(M(231,t,typeof n));return n}var op=!1;if(Er)try{var ua={};Object.defineProperty(ua,"passive",{get:function(){op=!0}}),window.addEventListener("test",ua,ua),window.removeEventListener("test",ua,ua)}catch{op=!1}function nP(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 Da=!1,ku=null,Eu=!1,ap=null,rP={onError:function(e){Da=!0,ku=e}};function sP(e,t,n,r,s,i,o,a,l){Da=!1,ku=null,nP.apply(rP,arguments)}function iP(e,t,n,r,s,i,o,a,l){if(sP.apply(this,arguments),Da){if(Da){var c=ku;Da=!1,ku=null}else throw Error(M(198));Eu||(Eu=!0,ap=c)}}function _i(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 A1(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 Ey(e){if(_i(e)!==e)throw Error(M(188))}function oP(e){var t=e.alternate;if(!t){if(t=_i(e),t===null)throw Error(M(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 Ey(s),e;if(i===r)return Ey(s),t;i=i.sibling}throw Error(M(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(M(189))}}if(n.alternate!==r)throw Error(M(190))}if(n.tag!==3)throw Error(M(188));return n.stateNode.current===n?e:t}function P1(e){return e=oP(e),e!==null?j1(e):null}function j1(e){if(e.tag===5||e.tag===6)return e;for(e=e.child;e!==null;){var t=j1(e);if(t!==null)return t;e=e.sibling}return null}var N1=zt.unstable_scheduleCallback,Cy=zt.unstable_cancelCallback,aP=zt.unstable_shouldYield,lP=zt.unstable_requestPaint,Ve=zt.unstable_now,cP=zt.unstable_getCurrentPriorityLevel,ag=zt.unstable_ImmediatePriority,R1=zt.unstable_UserBlockingPriority,Cu=zt.unstable_NormalPriority,uP=zt.unstable_LowPriority,O1=zt.unstable_IdlePriority,kd=null,tr=null;function dP(e){if(tr&&typeof tr.onCommitFiberRoot=="function")try{tr.onCommitFiberRoot(kd,e,void 0,(e.current.flags&128)===128)}catch{}}var Pn=Math.clz32?Math.clz32:pP,fP=Math.log,hP=Math.LN2;function pP(e){return e>>>=0,e===0?32:31-(fP(e)/hP|0)|0}var pc=64,mc=4194304;function Aa(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 Tu(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=Aa(a):(i&=o,i!==0&&(r=Aa(i)))}else o=n&~s,o!==0?r=Aa(o):i!==0&&(r=Aa(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-Pn(t),s=1<<n,r|=e[n],t&=~s;return r}function mP(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 gP(e,t){for(var n=e.suspendedLanes,r=e.pingedLanes,s=e.expirationTimes,i=e.pendingLanes;0<i;){var o=31-Pn(i),a=1<<o,l=s[o];l===-1?(!(a&n)||a&r)&&(s[o]=mP(a,t)):l<=t&&(e.expiredLanes|=a),i&=~a}}function lp(e){return e=e.pendingLanes&-1073741825,e!==0?e:e&1073741824?1073741824:0}function M1(){var e=pc;return pc<<=1,!(pc&4194240)&&(pc=64),e}function kf(e){for(var t=[],n=0;31>n;n++)t.push(e);return t}function Fl(e,t,n){e.pendingLanes|=t,t!==536870912&&(e.suspendedLanes=0,e.pingedLanes=0),e=e.eventTimes,t=31-Pn(t),e[t]=n}function vP(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-Pn(n),i=1<<s;t[s]=0,r[s]=-1,e[s]=-1,n&=~i}}function lg(e,t){var n=e.entangledLanes|=t;for(e=e.entanglements;n;){var r=31-Pn(n),s=1<<r;s&t|e[r]&t&&(e[r]|=t),n&=~s}}var ye=0;function D1(e){return e&=-e,1<e?4<e?e&268435455?16:536870912:4:1}var I1,cg,L1,F1,$1,cp=!1,gc=[],cs=null,us=null,ds=null,nl=new Map,rl=new Map,Qr=[],yP="mou
37sedown 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 Ty(e,t){switch(e){case"focusin":case"focusout":cs=null;break;case"dragenter":case"dragleave":us=null;break;case"mouseover":case"mouseout":ds=null;break;case"pointerover":case"pointerout":nl.delete(t.pointerId);break;case"gotpointercapture":case"lostpointercapture":rl.delete(t.pointerId)}}function da(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=Bl(t),t!==null&&cg(t)),e):(e.eventSystemFlags|=r,t=e.targetContainers,s!==null&&t.indexOf(s)===-1&&t.push(s),e)}function wP(e,t,n,r,s){switch(t){case"focusin":return cs=da(cs,e,t,n,r,s),!0;case"dragenter":return us=da(us,e,t,n,r,s),!0;case"mouseover":return ds=da(ds,e,t,n,r,s),!0;case"pointerover":var i=s.pointerId;return nl.set(i,da(nl.get(i)||null,e,t,n,r,s)),!0;case"gotpointercapture":return i=s.pointerId,rl.set(i,da(rl.get(i)||null,e,t,n,r,s)),!0}return!1}function B1(e){var t=Ys(e.target);if(t!==null){var n=_i(t);if(n!==null){if(t=n.tag,t===13){if(t=A1(n),t!==null){e.blockedOn=t,$1(e.priority,function(){L1(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 Zc(e){if(e.blockedOn!==null)return!1;for(var t=e.targetContainers;0<t.length;){var n=up(e.domEventName,e.eventSystemFlags,t[0],e.nativeEvent);if(n===null){n=e.nativeEvent;var r=new n.constructor(n.type,n);sp=r,n.target.dispatchEvent(r),sp=null}else return t=Bl(n),t!==null&&cg(t),e.blockedOn=n,!1;t.shift()}return!0}function Ay(e,t,n){Zc(e)&&n.delete(t)}function xP(){cp=!1,cs!==null&&Zc(cs)&&(cs=null),us!==null&&Zc(us)&&(us=null),ds!==null&&Zc(ds)&&(ds=null),nl.forEach(Ay),rl.forEach(Ay)}function fa(e,t){e.blockedOn===t&&(e.blockedOn=null,cp||(cp=!0,zt.unstable_scheduleCallback(zt.unstable_NormalPriority,xP)))}function sl(e){function t(s){return fa(s,e)}if(0<gc.length){fa(gc[0],e);for(var n=1;n<gc.length;n++){var r=gc[n];r.blockedOn===e&&(r.blockedOn=null)}}for(cs!==null&&fa(cs,e),us!==null&&fa(us,e),ds!==null&&fa(ds,e),nl.forEach(t),rl.forEach(t),n=0;n<Qr.length;n++)r=Qr[n],r.blockedOn===e&&(r.blockedOn=null);for(;0<Qr.length&&(n=Qr[0],n.blockedOn===null);)B1(n),n.blockedOn===null&&Qr.shift()}var ho=Rr.ReactCurrentBatchConfig,Au=!0;function bP(e,t,n,r){var s=ye,i=ho.transition;ho.transition=null;try{ye=1,ug(e,t,n,r)}finally{ye=s,ho.transition=i}}function _P(e,t,n,r){var s=ye,i=ho.transition;ho.transition=null;try{ye=4,ug(e,t,n,r)}finally{ye=s,ho.transition=i}}function ug(e,t,n,r){if(Au){var s=up(e,t,n,r);if(s===null)Mf(e,t,r,Pu,n),Ty(e,r);else if(wP(s,e,t,n,r))r.stopPropagation();else if(Ty(e,r),t&4&&-1<yP.indexOf(e)){for(;s!==null;){var i=Bl(s);if(i!==null&&I1(i),i=up(e,t,n,r),i===null&&Mf(e,t,r,Pu,n),i===s)break;s=i}s!==null&&r.stopPropagation()}else Mf(e,t,r,null,n)}}var Pu=null;function up(e,t,n,r){if(Pu=null,e=og(r),e=Ys(e),e!==null)if(t=_i(e),t===null)e=null;else if(n=t.tag,n===13){if(e=A1(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 Pu=e,null}function V1(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(cP()){case ag:return 1;case R1:return 4;case Cu:case uP:return 16;case O1:return 536870912;default:return 16}default:return 16}}var ss=null,dg=null,Jc=null;function U1(){if(Jc)return Jc;var e,t=dg,n=t.length,r,s="value"in ss?ss.value:ss.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 Jc=s.slice(e,1<r?1-r:void 0)}function Xc(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 vc(){return!0}function Py(){return!1}function qt(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)?vc:Py,this.isPropagationStopped=Py,this}return Le(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=vc)},stopPropagation:function(){var n=this.nativeEvent;n&&(n.stopPropagation?n.stopPropagation():typeof n.cancelBubble!="unknown"&&(n.cancelBubble=!0),this.isPropagationStopped=vc)},persist:function(){},isPersistent:vc}),t}var Qo={eventPhase:0,bubbles:0,cancelable:0,timeStamp:function(e){return e.timeStamp||Date.now()},defaultPrevented:0,isTrusted:0},fg=qt(Qo),$l=Le({},Qo,{view:0,detail:0}),SP=qt($l),Ef,Cf,ha,Ed=Le({},$l,{screenX:0,screenY:0,clientX:0,clientY:0,pageX:0,pageY:0,ctrlKey:0,shiftKey:0,altKey:0,metaKey:0,getModifierState:hg,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!==ha&&(ha&&e.type==="mousemove"?(Ef=e.screenX-ha.screenX,Cf=e.screenY-ha.screenY):Cf=Ef=0,ha=e),Ef)},movementY:function(e){return"movementY"in e?e.movementY:Cf}}),jy=qt(Ed),kP=Le({},Ed,{dataTransfer:0}),EP=qt(kP),CP=Le({},$l,{relatedTarget:0}),Tf=qt(CP),TP=Le({},Qo,{animationName:0,elapsedTime:0,pseudoElement:0}),AP=qt(TP),PP=Le({},Qo,{clipboardData:function(e){return"clipboardData"in e?e.clipboardData:window.clipboardData}}),jP=qt(PP),NP=Le({},Qo,{data:0}),Ny=qt(NP),RP={Esc:"Escape",Spacebar:" ",Left:"ArrowLeft",Up:"ArrowUp",Right:"ArrowRight",Down:"ArrowDown",Del:"Delete",Win:"OS",Menu:"ContextMenu",Apps:"ContextMenu",Scroll:"ScrollLock",MozPrintableKey:"Unidentified"},OP={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"},MP={Alt:"altKey",Control:"ctrlKey",Meta:"metaKey",Shift:"shiftKey"};function DP(e){var t=this.nativeEvent;return t.getModifierState?t.getModifierState(e):(e=MP[e])?!!t[e]:!1}function hg(){return DP}var IP=Le({},$l,{key:function(e){if(e.key){var t=RP[e.key]||e.key;if(t!=="Unidentified")return t}
vendor: 6,028 bytes, line 37
37return e.type==="keypress"?(e=Xc(e),e===13?"Enter":String.fromCharCode(e)):e.type==="keydown"||e.type==="keyup"?OP[e.keyCode]||"Unidentified":""},code:0,location:0,ctrlKey:0,shiftKey:0,altKey:0,metaKey:0,repeat:0,locale:0,getModifierState:hg,charCode:function(e){return e.type==="keypress"?Xc(e):0},keyCode:function(e){return e.type==="keydown"||e.type==="keyup"?e.keyCode:0},which:function(e){return e.type==="keypress"?Xc(e):e.type==="keydown"||e.type==="keyup"?e.keyCode:0}}),LP=qt(IP),FP=Le({},Ed,{pointerId:0,width:0,height:0,pressure:0,tangentialPressure:0,tiltX:0,tiltY:0,twist:0,pointerType:0,isPrimary:0}),Ry=qt(FP),$P=Le({},$l,{touches:0,targetTouches:0,changedTouches:0,altKey:0,metaKey:0,ctrlKey:0,shiftKey:0,getModifierState:hg}),BP=qt($P),VP=Le({},Qo,{propertyName:0,elapsedTime:0,pseudoElement:0}),UP=qt(VP),zP=Le({},Ed,{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}),WP=qt(zP),HP=[9,13,27,32],pg=Er&&"CompositionEvent"in window,Ia=null;Er&&"documentMode"in document&&(Ia=document.documentMode);var KP=Er&&"TextEvent"in window&&!Ia,z1=Er&&(!pg||Ia&&8<Ia&&11>=Ia),Oy=" ",My=!1;function W1(e,t){switch(e){case"keyup":return HP.indexOf(t.keyCode)!==-1;case"keydown":return t.keyCode!==229;case"keypress":case"mousedown":case"focusout":return!0;default:return!1}}function H1(e){return e=e.detail,typeof e=="object"&&"data"in e?e.data:null}var Qi=!1;function qP(e,t){switch(e){case"compositionend":return H1(t);case"keypress":return t.which!==32?null:(My=!0,Oy);case"textInput":return e=t.data,e===Oy&&My?null:e;default:return null}}function YP(e,t){if(Qi)return e==="compositionend"||!pg&&W1(e,t)?(e=U1(),Jc=dg=ss=null,Qi=!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 z1&&t.locale!=="ko"?null:t.data;default:return null}}var GP={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 Dy(e){var t=e&&e.nodeName&&e.nodeName.toLowerCase();return t==="input"?!!GP[e.type]:t==="textarea"}function K1(e,t,n,r){S1(r),t=ju(t,"onChange"),0<t.length&&(n=new fg("onChange","change",null,n,r),e.push({event:n,listeners:t}))}var La=null,il=null;function QP(e){r_(e,0)}function Cd(e){var t=Xi(e);if(g1(t))return e}function ZP(e,t){if(e==="change")return t}var q1=!1;if(Er){var Af;if(Er){var Pf="oninput"in document;if(!Pf){var Iy=document.createElement("div");Iy.setAttribute("oninput","return;"),Pf=typeof Iy.oninput=="function"}Af=Pf}else Af=!1;q1=Af&&(!document.documentMode||9<document.documentMode)}function Ly(){La&&(La.detachEvent("onpropertychange",Y1),il=La=null)}function Y1(e){if(e.propertyName==="value"&&Cd(il)){var t=[];K1(t,il,e,og(e)),T1(QP,t)}}function JP(e,t,n){e==="focusin"?(Ly(),La=t,il=n,La.attachEvent("onpropertychange",Y1)):e==="focusout"&&Ly()}function XP(e){if(e==="selectionchange"||e==="keyup"||e==="keydown")return Cd(il)}function ej(e,t){if(e==="click")return Cd(t)}function tj(e,t){if(e==="input"||e==="change")return Cd(t)}function nj(e,t){return e===t&&(e!==0||1/e===1/t)||e!==e&&t!==t}var Rn=typeof Object.is=="function"?Object.is:nj;function ol(e,t){if(Rn(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(!Kh.call(t,s)||!Rn(e[s],t[s]))return!1}return!0}function Fy(e){for(;e&&e.firstChild;)e=e.firstChild;return e}function $y(e,t){var n=Fy(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=Fy(n)}}function G1(e,t){return e&&t?e===t?!0:e&&e.nodeType===3?!1:t&&t.nodeType===3?G1(e,t.parentNode):"contains"in e?e.contains(t):e.compareDocumentPosition?!!(e.compareDocumentPosition(t)&16):!1:!1}function Q1(){for(var e=window,t=Su();t instanceof e.HTMLIFrameElement;){try{var n=typeof t.contentWindow.location.href=="string"}catch{n=!1}if(n)e=t.contentWindow;else break;t=Su(e.document)}return t}function mg(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 rj(e){var t=Q1(),n=e.focusedElem,r=e.selectionRange;if(t!==n&&n&&n.ownerDocument&&G1(n.ownerDocument.documentElement,n)){if(r!==null&&mg(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=$y(n,i);var o=$y(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 sj=Er&&"documentMode"in document&&11>=document.documentMode,Zi=null,dp=null,Fa=null,fp=!1;function By(e,t,n){var r=n.window===n?n.document:n.nodeType===9?n:n.ownerDocument;fp||Zi==null||Zi!==Su(r)||(r=Zi,"selectionStart"in r&&mg(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: 4,352 bytes, line 37
37sNode:r.focusNode,focusOffset:r.focusOffset}),Fa&&ol(Fa,r)||(Fa=r,r=ju(dp,"onSelect"),0<r.length&&(t=new fg("onSelect","select",null,t,n),e.push({event:t,listeners:r}),t.target=Zi)))}function yc(e,t){var n={};return n[e.toLowerCase()]=t.toLowerCase(),n["Webkit"+e]="webkit"+t,n["Moz"+e]="moz"+t,n}var Ji={animationend:yc("Animation","AnimationEnd"),animationiteration:yc("Animation","AnimationIteration"),animationstart:yc("Animation","AnimationStart"),transitionend:yc("Transition","TransitionEnd")},jf={},Z1={};Er&&(Z1=document.createElement("div").style,"AnimationEvent"in window||(delete Ji.animationend.animation,delete Ji.animationiteration.animation,delete Ji.animationstart.animation),"TransitionEvent"in window||delete Ji.transitionend.transition);function Td(e){if(jf[e])return jf[e];if(!Ji[e])return e;var t=Ji[e],n;for(n in t)if(t.hasOwnProperty(n)&&n in Z1)return jf[e]=t[n];return e}var J1=Td("animationend"),X1=Td("animationiteration"),e_=Td("animationstart"),t_=Td("transitionend"),n_=new Map,Vy="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 As(e,t){n_.set(e,t),bi(t,[e])}for(var Nf=0;Nf<Vy.length;Nf++){var Rf=Vy[Nf],ij=Rf.toLowerCase(),oj=Rf[0].toUpperCase()+Rf.slice(1);As(ij,"on"+oj)}As(J1,"onAnimationEnd");As(X1,"onAnimationIteration");As(e_,"onAnimationStart");As("dblclick","onDoubleClick");As("focusin","onFocus");As("focusout","onBlur");As(t_,"onTransitionEnd");jo("onMouseEnter",["mouseout","mouseover"]);jo("onMouseLeave",["mouseout","mouseover"]);jo("onPointerEnter",["pointerout","pointerover"]);jo("onPointerLeave",["pointerout","pointerover"]);bi("onChange","change click focusin focusout input keydown keyup selectionchange".split(" "));bi("onSelect","focusout contextmenu dragend focusin keydown keyup mousedown mouseup selectionchange".split(" "));bi("onBeforeInput",["compositionend","keypress","textInput","paste"]);bi("onCompositionEnd","compositionend focusout keydown keypress keyup mousedown".split(" "));bi("onCompositionStart","compositionstart focusout keydown keypress keyup mousedown".split(" "));bi("onCompositionUpdate","compositionupdate focusout keydown keypress keyup mousedown".split(" "));var Pa="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(" "),aj=new Set("cancel close invalid load scroll toggle".split(" ").concat(Pa));function Uy(e,t,n){var r=e.type||"unknown-event";e.currentTarget=n,iP(r,t,void 0,e),e.currentTarget=null}function r_(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;Uy(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;Uy(s,a,c),i=l}}}if(Eu)throw e=ap,Eu=!1,ap=null,e}function Ce(e,t){var n=t[vp];n===void 0&&(n=t[vp]=new Set);var r=e+"__bubble";n.has(r)||(s_(t,e,2,!1),n.add(r))}function Of(e,t,n){var r=0;t&&(r|=4),s_(n,e,r,t)}var wc="_reactListening"+Math.random().toString(36).slice(2);function al(e){if(!e[wc]){e[wc]=!0,d1.forEach(function(n){n!=="selectionchange"&&(aj.has(n)||Of(n,!1,e),Of(n,!0,e))});var t=e.nodeType===9?e:e.ownerDocument;t===null||t[wc]||(t[wc]=!0,Of("selectionchange",!1,t))}}function s_(e,t,n,r){switch(V1(t)){case 1:var s=bP;break;case 4:s=_P;break;default:s=ug}n=s.bind(null,t,n,e),s=void 0,!op||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)}
vendor: 2,676 bytes, line 37
37function Mf(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=Ys(a),o===null)return;if(l=o.tag,l===5||l===6){r=i=o;continue e}a=a.parentNode}}r=r.return}T1(function(){var c=i,u=og(n),d=[];e:{var h=n_.get(e);if(h!==void 0){var p=fg,b=e;switch(e){case"keypress":if(Xc(n)===0)break e;case"keydown":case"keyup":p=LP;break;case"focusin":b="focus",p=Tf;break;case"focusout":b="blur",p=Tf;break;case"beforeblur":case"afterblur":p=Tf;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":p=jy;break;case"drag":case"dragend":case"dragenter":case"dragexit":case"dragleave":case"dragover":case"dragstart":case"drop":p=EP;break;case"touchcancel":case"touchend":case"touchmove":case"touchstart":p=BP;break;case J1:case X1:case e_:p=AP;break;case t_:p=UP;break;case"scroll":p=SP;break;case"wheel":p=WP;break;case"copy":case"cut":case"paste":p=jP;break;case"gotpointercapture":case"lostpointercapture":case"pointercancel":case"pointerdown":case"pointermove":case"pointerout":case"pointerover":case"pointerup":p=Ry}var g=(t&4)!==0,x=!g&&e==="scroll",y=g?h!==null?h+"Capture":null:h;g=[];for(var m=c,v;m!==null;){v=m;var _=v.stateNode;if(v.tag===5&&_!==null&&(v=_,y!==null&&(_=tl(m,y),_!=null&&g.push(ll(m,_,v)))),x)break;m=m.return}0<g.length&&(h=new p(h,b,null,n,u),d.push({event:h,listeners:g}))}}if(!(t&7)){e:{if(h=e==="mouseover"||e==="pointerover",p=e==="mouseout"||e==="pointerout",h&&n!==sp&&(b=n.relatedTarget||n.fromElement)&&(Ys(b)||b[Cr]))break e;if((p||h)&&(h=u.window===u?u:(h=u.ownerDocument)?h.defaultView||h.parentWindow:window,p?(b=n.relatedTarget||n.toElement,p=c,b=b?Ys(b):null,b!==null&&(x=_i(b),b!==x||b.tag!==5&&b.tag!==6)&&(b=null)):(p=null,b=c),p!==b)){if(g=jy,_="onMouseLeave",y="onMouseEnter",m="mouse",(e==="pointerout"||e==="pointerover")&&(g=Ry,_="onPointerLeave",y="onPointerEnter",m="pointer"),x=p==null?h:Xi(p),v=b==null?h:Xi(b),h=new g(_,m+"leave",p,n,u),h.target=x,h.relatedTarget=v,_=null,Ys(u)===c&&(g=new g(y,m+"enter",b,n,u),g.target=v,g.relatedTarget=x,_=g),x=_,p&&b)t:{for(g=p,y=b,m=0,v=g;v;v=Ni(v))m++;for(v=0,_=y;_;_=Ni(_))v++;for(;0<m-v;)g=Ni(g),m--;for(;0<v-m;)y=Ni(y),v--;for(;m--;){if(g===y||y!==null&&g===y.alternate)break t;g=Ni(g),y=Ni(y)}g=null}else g=null;p!==null&&zy(d,h,p,g,!1),b!==null&&x!==null&&zy(d,x,b,g,!0)}}
vendor: 4,658 bytes, lines 37-38
37e:{if(h=c?Xi(c):window,p=h.nodeName&&h.nodeName.toLowerCase(),p==="select"||p==="input"&&h.type==="file")var S=ZP;else if(Dy(h))if(q1)S=tj;else{S=XP;var k=JP}else(p=h.nodeName)&&p.toLowerCase()==="input"&&(h.type==="checkbox"||h.type==="radio")&&(S=ej);if(S&&(S=S(e,c))){K1(d,S,n,u);break e}k&&k(e,h,c),e==="focusout"&&(k=h._wrapperState)&&k.controlled&&h.type==="number"&&Xh(h,"number",h.value)}switch(k=c?Xi(c):window,e){case"focusin":(Dy(k)||k.contentEditable==="true")&&(Zi=k,dp=c,Fa=null);break;case"focusout":Fa=dp=Zi=null;break;case"mousedown":fp=!0;break;case"contextmenu":case"mouseup":case"dragend":fp=!1,By(d,n,u);break;case"selectionchange":if(sj)break;case"keydown":case"keyup":By(d,n,u)}var E;if(pg)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 Qi?W1(e,n)&&(T="onCompositionEnd"):e==="keydown"&&n.keyCode===229&&(T="onCompositionStart");T&&(z1&&n.locale!=="ko"&&(Qi||T!=="onCompositionStart"?T==="onCompositionEnd"&&Qi&&(E=U1()):(ss=u,dg="value"in ss?ss.value:ss.textContent,Qi=!0)),k=ju(c,T),0<k.length&&(T=new Ny(T,e,null,n,u),d.push({event:T,listeners:k}),E?T.data=E:(E=H1(n),E!==null&&(T.data=E)))),(E=KP?qP(e,n):YP(e,n))&&(c=ju(c,"onBeforeInput"),0<c.length&&(u=new Ny("onBeforeInput","beforeinput",null,n,u),d.push({event:u,listeners:c}),u.data=E))}r_(d,t)})}function ll(e,t,n){return{instance:e,listener:t,currentTarget:n}}function ju(e,t){for(var n=t+"Capture",r=[];e!==null;){var s=e,i=s.stateNode;s.tag===5&&i!==null&&(s=i,i=tl(e,n),i!=null&&r.unshift(ll(e,i,s)),i=tl(e,t),i!=null&&r.push(ll(e,i,s))),e=e.return}return r}function Ni(e){if(e===null)return null;do e=e.return;while(e&&e.tag!==5);return e||null}function zy(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=tl(n,i),l!=null&&o.unshift(ll(n,l,a))):s||(l=tl(n,i),l!=null&&o.push(ll(n,l,a)))),n=n.return}o.length!==0&&e.push({event:t,listeners:o})}var lj=/\r\n?/g,cj=/\u0000|\uFFFD/g;function Wy(e){return(typeof e=="string"?e:""+e).replace(lj,`
38`).replace(cj,"")}function xc(e,t,n){if(t=Wy(t),Wy(e)!==t&&n)throw Error(M(425))}function Nu(){}var hp=null,pp=null;function mp(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 gp=typeof setTimeout=="function"?setTimeout:void 0,uj=typeof clearTimeout=="function"?clearTimeout:void 0,Hy=typeof Promise=="function"?Promise:void 0,dj=typeof queueMicrotask=="function"?queueMicrotask:typeof Hy<"u"?function(e){return Hy.resolve(null).then(e).catch(fj)}:gp;function fj(e){setTimeout(function(){throw e})}function Df(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),sl(t);return}r--}else n!=="$"&&n!=="$?"&&n!=="$!"||r++;n=s}while(n);sl(t)}function fs(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 Ky(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 Zo=Math.random().toString(36).slice(2),Zn="__reactFiber$"+Zo,cl="__reactProps$"+Zo,Cr="__reactContainer$"+Zo,vp="__reactEvents$"+Zo,hj="__reactListeners$"+Zo,pj="__reactHandles$"+Zo;function Ys(e){var t=e[Zn];if(t)return t;for(var n=e.parentNode;n;){if(t=n[Cr]||n[Zn]){if(n=t.alternate,t.child!==null||n!==null&&n.child!==null)for(e=Ky(e);e!==null;){if(n=e[Zn])return n;e=Ky(e)}return t}e=n,n=e.parentNode}return null}function Bl(e){return e=e[Zn]||e[Cr],!e||e.tag!==5&&e.tag!==6&&e.tag!==13&&e.tag!==3?null:e}function Xi(e){if(e.tag===5||e.tag===6)return e.stateNode;throw Error(M(33))}function Ad(e){return e[cl]||null}var yp=[],eo=-1;function Ps(e){return{current:e}}function Pe(e){0>eo||(e.current=yp[eo],yp[eo]=null,eo--)}function Se(e,t){eo++,yp[eo]=e.current,e.current=t}var xs={},ft=Ps(xs),Pt=Ps(!1),di=xs;function No(e,t){var n=e.type.contextTypes;if(!n)return xs;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 jt(e){return e=e.childContextTypes,e!=null}function Ru(){Pe(Pt),Pe(ft)}
vendor: 6,245 bytes, line 38
38function qy(e,t,n){if(ft.current!==xs)throw Error(M(168));Se(ft,t),Se(Pt,n)}function i_(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(M(108,JA(e)||"Unknown",s));return Le({},n,r)}function Ou(e){return e=(e=e.stateNode)&&e.__reactInternalMemoizedMergedChildContext||xs,di=ft.current,Se(ft,e),Se(Pt,Pt.current),!0}function Yy(e,t,n){var r=e.stateNode;if(!r)throw Error(M(169));n?(e=i_(e,t,di),r.__reactInternalMemoizedMergedChildContext=e,Pe(Pt),Pe(ft),Se(ft,e)):Pe(Pt),Se(Pt,n)}var xr=null,Pd=!1,If=!1;function o_(e){xr===null?xr=[e]:xr.push(e)}function mj(e){Pd=!0,o_(e)}function js(){if(!If&&xr!==null){If=!0;var e=0,t=ye;try{var n=xr;for(ye=1;e<n.length;e++){var r=n[e];do r=r(!0);while(r!==null)}xr=null,Pd=!1}catch(s){throw xr!==null&&(xr=xr.slice(e+1)),N1(ag,js),s}finally{ye=t,If=!1}}return null}var to=[],no=0,Mu=null,Du=0,tn=[],nn=0,fi=null,_r=1,Sr="";function Vs(e,t){to[no++]=Du,to[no++]=Mu,Mu=e,Du=t}function a_(e,t,n){tn[nn++]=_r,tn[nn++]=Sr,tn[nn++]=fi,fi=e;var r=_r;e=Sr;var s=32-Pn(r)-1;r&=~(1<<s),n+=1;var i=32-Pn(t)+s;if(30<i){var o=s-s%5;i=(r&(1<<o)-1).toString(32),r>>=o,s-=o,_r=1<<32-Pn(t)+s|n<<s|r,Sr=i+e}else _r=1<<i|n<<s|r,Sr=e}function gg(e){e.return!==null&&(Vs(e,1),a_(e,1,0))}function vg(e){for(;e===Mu;)Mu=to[--no],to[no]=null,Du=to[--no],to[no]=null;for(;e===fi;)fi=tn[--nn],tn[nn]=null,Sr=tn[--nn],tn[nn]=null,_r=tn[--nn],tn[nn]=null}var Vt=null,Bt=null,Re=!1,Cn=null;function l_(e,t){var n=rn(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 Gy(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,Vt=e,Bt=fs(t.firstChild),!0):!1;case 6:return t=e.pendingProps===""||t.nodeType!==3?null:t,t!==null?(e.stateNode=t,Vt=e,Bt=null,!0):!1;case 13:return t=t.nodeType!==8?null:t,t!==null?(n=fi!==null?{id:_r,overflow:Sr}:null,e.memoizedState={dehydrated:t,treeContext:n,retryLane:1073741824},n=rn(18,null,null,0),n.stateNode=t,n.return=e,e.child=n,Vt=e,Bt=null,!0):!1;default:return!1}}function wp(e){return(e.mode&1)!==0&&(e.flags&128)===0}function xp(e){if(Re){var t=Bt;if(t){var n=t;if(!Gy(e,t)){if(wp(e))throw Error(M(418));t=fs(n.nextSibling);var r=Vt;t&&Gy(e,t)?l_(r,n):(e.flags=e.flags&-4097|2,Re=!1,Vt=e)}}else{if(wp(e))throw Error(M(418));e.flags=e.flags&-4097|2,Re=!1,Vt=e}}}function Qy(e){for(e=e.return;e!==null&&e.tag!==5&&e.tag!==3&&e.tag!==13;)e=e.return;Vt=e}function bc(e){if(e!==Vt)return!1;if(!Re)return Qy(e),Re=!0,!1;var t;if((t=e.tag!==3)&&!(t=e.tag!==5)&&(t=e.type,t=t!=="head"&&t!=="body"&&!mp(e.type,e.memoizedProps)),t&&(t=Bt)){if(wp(e))throw c_(),Error(M(418));for(;t;)l_(e,t),t=fs(t.nextSibling)}if(Qy(e),e.tag===13){if(e=e.memoizedState,e=e!==null?e.dehydrated:null,!e)throw Error(M(317));e:{for(e=e.nextSibling,t=0;e;){if(e.nodeType===8){var n=e.data;if(n==="/$"){if(t===0){Bt=fs(e.nextSibling);break e}t--}else n!=="$"&&n!=="$!"&&n!=="$?"||t++}e=e.nextSibling}Bt=null}}else Bt=Vt?fs(e.stateNode.nextSibling):null;return!0}function c_(){for(var e=Bt;e;)e=fs(e.nextSibling)}function Ro(){Bt=Vt=null,Re=!1}function yg(e){Cn===null?Cn=[e]:Cn.push(e)}var gj=Rr.ReactCurrentBatchConfig;function pa(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(M(309));var r=n.stateNode}if(!r)throw Error(M(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(M(284));if(!n._owner)throw Error(M(290,e))}return e}function _c(e,t){throw e=Object.prototype.toString.call(t),Error(M(31,e==="[object Object]"?"object with keys {"+Object.keys(t).join(", ")+"}":e))}function Zy(e){var t=e._init;return t(e._payload)}function u_(e){function t(y,m){if(e){var v=y.deletions;v===null?(y.deletions=[m],y.flags|=16):v.push(m)}}function n(y,m){if(!e)return null;for(;m!==null;)t(y,m),m=m.sibling;return null}function r(y,m){for(y=new Map;m!==null;)m.key!==null?y.set(m.key,m):y.set(m.index,m),m=m.sibling;return y}function s(y,m){return y=gs(y,m),y.index=0,y.sibling=null,y}function i(y,m,v){return y.index=v,e?(v=y.alternate,v!==null?(v=v.index,v<m?(y.flags|=2,m):v):(y.flags|=2,m)):(y.flags|=1048576,m)}function o(y){return e&&y.alternate===null&&(y.flags|=2),y}function a(y,m,v,_){return m===null||m.tag!==6?(m=zf(v,y.mode,_),m.return=y,m):(m=s(m,v),m.return=y,m)}function l(y,m,v,_){var S=v.type;return S===Gi?u(y,m,v.props.children,_,v.key):m!==null&&(m.elementType===S||typeof S=="object"&&S!==null&&S.$$typeof===qr&&Zy(S)===m.type)?(_=s(m,v.props),_.ref=pa(y,m,v),_.return=y,_):(_=ou(v.type,v.key,v.props,null,y.mode,_),_.ref=pa(y,m,v),_.return=y,_)}function c(y,m,v,_){return m===null||m.tag!==4||m.stateNode.containerInfo!==v.containerInfo||m.stateNode.implementation!==v.implementation?(m=Wf(v,y.mode,_),m.return=y,m):(m=s(m,v.children||[]),m.return=y,m)}function u(y,m,v,_,S){return m===null||m.tag!==7?(m=li(v,y.mode,_,S),m.return=y,m):(m=s(m,v),m.return=y,m)}function d(y,m,v){if(typeof m=="string"&&m!==""||typeof m=="number")return m=zf(""+m,y.mode,v),m.return=y,m;if(typeof m=="object"&&m!==null){switch(m.$$typeof){case dc:return v=ou(m.type,m.key,m.props,null,y.mode,v),v.ref=pa(y,null,m),v.return=y,v;case Yi:return m=Wf(m,y.mode,v),m.return=y,m;case qr:var _=m._init;return d(y,_(m._payload),v)}if(Ta(m)||ca(m))return m=li(m,y.mode,v,null),m.return=y,m;_c(y,m)}return null}function h(y,m,v,_){var S=m!==null?m.key:null;if(typeof v=="string"&&v!==""||typeof v=="number")return S!==null?null:a(y,m,""+v,_);if(typeof v=="object"&&v!==null){switch(v.$$typeof){case dc:return v.key===S?l(y,m,v,_):null;case Yi:return v.key===S?c(y,m,v,_):null;case qr:return S=v._init,h(y,m,S(v._payload),_)}if(Ta(v)||ca(v))return S!==null?null:u(y,m,v,_,null);_c(y,v)}return null}function p(y,m,v,_,S){if(typeof _=="string"&&_!==""||typeof _=="number")return y=y.get(v)||null,a(m,y,""+_,S);if(typeof _=="object"&&_!==null){switch(_.$$typeof){case dc:return y=y.get(_.key===null?v:_.key)||null,l(m,y,_,S
vendor: 2,238 bytes, line 38
38);case Yi:return y=y.get(_.key===null?v:_.key)||null,c(m,y,_,S);case qr:var k=_._init;return p(y,m,v,k(_._payload),S)}if(Ta(_)||ca(_))return y=y.get(v)||null,u(m,y,_,S,null);_c(m,_)}return null}function b(y,m,v,_){for(var S=null,k=null,E=m,T=m=0,P=null;E!==null&&T<v.length;T++){E.index>T?(P=E,E=null):P=E.sibling;var A=h(y,E,v[T],_);if(A===null){E===null&&(E=P);break}e&&E&&A.alternate===null&&t(y,E),m=i(A,m,T),k===null?S=A:k.sibling=A,k=A,E=P}if(T===v.length)return n(y,E),Re&&Vs(y,T),S;if(E===null){for(;T<v.length;T++)E=d(y,v[T],_),E!==null&&(m=i(E,m,T),k===null?S=E:k.sibling=E,k=E);return Re&&Vs(y,T),S}for(E=r(y,E);T<v.length;T++)P=p(E,y,T,v[T],_),P!==null&&(e&&P.alternate!==null&&E.delete(P.key===null?T:P.key),m=i(P,m,T),k===null?S=P:k.sibling=P,k=P);return e&&E.forEach(function(B){return t(y,B)}),Re&&Vs(y,T),S}function g(y,m,v,_){var S=ca(v);if(typeof S!="function")throw Error(M(150));if(v=S.call(v),v==null)throw Error(M(151));for(var k=S=null,E=m,T=m=0,P=null,A=v.next();E!==null&&!A.done;T++,A=v.next()){E.index>T?(P=E,E=null):P=E.sibling;var B=h(y,E,A.value,_);if(B===null){E===null&&(E=P);break}e&&E&&B.alternate===null&&t(y,E),m=i(B,m,T),k===null?S=B:k.sibling=B,k=B,E=P}if(A.done)return n(y,E),Re&&Vs(y,T),S;if(E===null){for(;!A.done;T++,A=v.next())A=d(y,A.value,_),A!==null&&(m=i(A,m,T),k===null?S=A:k.sibling=A,k=A);return Re&&Vs(y,T),S}for(E=r(y,E);!A.done;T++,A=v.next())A=p(E,y,T,A.value,_),A!==null&&(e&&A.alternate!==null&&E.delete(A.key===null?T:A.key),m=i(A,m,T),k===null?S=A:k.sibling=A,k=A);return e&&E.forEach(function(I){return t(y,I)}),Re&&Vs(y,T),S}function x(y,m,v,_){if(typeof v=="object"&&v!==null&&v.type===Gi&&v.key===null&&(v=v.props.children),typeof v=="object"&&v!==null){switch(v.$$typeof){case dc:e:{for(var S=v.key,k=m;k!==null;){if(k.key===S){if(S=v.type,S===Gi){if(k.tag===7){n(y,k.sibling),m=s(k,v.props.children),m.return=y,y=m;break e}}else if(k.elementType===S||typeof S=="object"&&S!==null&&S.$$typeof===qr&&Zy(S)===k.type){n(y,k.sibling),m=s(k,v.props),m.ref=pa(y,k,v),m.return=y,y=m;break e}n(y,k);break}else t(y,k);k=k.sibling}v.type===Gi?(m=li(v.props.children,y.mode,_,v.key),m.return=y,y=m):(_=ou(v.type,v.key,v.props,null,y.mode,_),_.ref=pa(y,m,v),_.return=y,y=_)}return o(y);
vendor: 18,185 bytes, lines 38-40
38case Yi:e:{for(k=v.key;m!==null;){if(m.key===k)if(m.tag===4&&m.stateNode.containerInfo===v.containerInfo&&m.stateNode.implementation===v.implementation){n(y,m.sibling),m=s(m,v.children||[]),m.return=y,y=m;break e}else{n(y,m);break}else t(y,m);m=m.sibling}m=Wf(v,y.mode,_),m.return=y,y=m}return o(y);case qr:return k=v._init,x(y,m,k(v._payload),_)}if(Ta(v))return b(y,m,v,_);if(ca(v))return g(y,m,v,_);_c(y,v)}return typeof v=="string"&&v!==""||typeof v=="number"?(v=""+v,m!==null&&m.tag===6?(n(y,m.sibling),m=s(m,v),m.return=y,y=m):(n(y,m),m=zf(v,y.mode,_),m.return=y,y=m),o(y)):n(y,m)}return x}var Oo=u_(!0),d_=u_(!1),Iu=Ps(null),Lu=null,ro=null,wg=null;function xg(){wg=ro=Lu=null}function bg(e){var t=Iu.current;Pe(Iu),e._currentValue=t}function bp(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 po(e,t){Lu=e,wg=ro=null,e=e.dependencies,e!==null&&e.firstContext!==null&&(e.lanes&t&&(Tt=!0),e.firstContext=null)}function ln(e){var t=e._currentValue;if(wg!==e)if(e={context:e,memoizedValue:t,next:null},ro===null){if(Lu===null)throw Error(M(308));ro=e,Lu.dependencies={lanes:0,firstContext:e}}else ro=ro.next=e;return t}var Gs=null;function _g(e){Gs===null?Gs=[e]:Gs.push(e)}function f_(e,t,n,r){var s=t.interleaved;return s===null?(n.next=n,_g(t)):(n.next=s.next,s.next=n),t.interleaved=n,Tr(e,r)}function Tr(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 Yr=!1;function Sg(e){e.updateQueue={baseState:e.memoizedState,firstBaseUpdate:null,lastBaseUpdate:null,shared:{pending:null,interleaved:null,lanes:0},effects:null}}function h_(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 kr(e,t){return{eventTime:e,lane:t,tag:0,payload:null,callback:null,next:null}}function hs(e,t,n){var r=e.updateQueue;if(r===null)return null;if(r=r.shared,de&2){var s=r.pending;return s===null?t.next=t:(t.next=s.next,s.next=t),r.pending=t,Tr(e,n)}return s=r.interleaved,s===null?(t.next=t,_g(r)):(t.next=s.next,s.next=t),r.interleaved=t,Tr(e,n)}function eu(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,lg(e,n)}}function Jy(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 Fu(e,t,n,r){var s=e.updateQueue;Yr=!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,p=a.eventTime;if((r&h)===h){u!==null&&(u=u.next={eventTime:p,lane:0,tag:a.tag,payload:a.payload,callback:a.callback,next:null});e:{var b=e,g=a;switch(h=t,p=n,g.tag){case 1:if(b=g.payload,typeof b=="function"){d=b.call(p,d,h);break e}d=b;break e;case 3:b.flags=b.flags&-65537|128;case 0:if(b=g.payload,h=typeof b=="function"?b.call(p,d,h):b,h==null)break e;d=Le({},d,h);break e;case 2:Yr=!0}}a.callback!==null&&a.lane!==0&&(e.flags|=64,h=s.effects,h===null?s.effects=[a]:h.push(a))}else p={eventTime:p,lane:h,tag:a.tag,payload:a.payload,callback:a.callback,next:null},u===null?(c=u=p,l=d):u=u.next=p,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);pi|=o,e.lanes=o,e.memoizedState=d}}function Xy(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(M(191,s));s.call(r)}}}var Vl={},nr=Ps(Vl),ul=Ps(Vl),dl=Ps(Vl);function Qs(e){if(e===Vl)throw Error(M(174));return e}function kg(e,t){switch(Se(dl,t),Se(ul,e),Se(nr,Vl),e=t.nodeType,e){case 9:case 11:t=(t=t.documentElement)?t.namespaceURI:tp(null,"");break;default:e=e===8?t.parentNode:t,t=e.namespaceURI||null,e=e.tagName,t=tp(t,e)}Pe(nr),Se(nr,t)}function Mo(){Pe(nr),Pe(ul),Pe(dl)}function p_(e){Qs(dl.current);var t=Qs(nr.current),n=tp(t,e.type);t!==n&&(Se(ul,e),Se(nr,n))}function Eg(e){ul.current===e&&(Pe(nr),Pe(ul))}var De=Ps(0);function $u(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 Lf=[];function Cg(){for(var e=0;e<Lf.length;e++)Lf[e]._workInProgressVersionPrimary=null;Lf.length=0}var tu=Rr.ReactCurrentDispatcher,Ff=Rr.ReactCurrentBatchConfig,hi=0,Ie=null,Ge=null,Je=null,Bu=!1,$a=!1,fl=0,vj=0;function lt(){throw Error(M(321))}function Tg(e,t){if(t===null)return!1;for(var n=0;n<t.length&&n<e.length;n++)if(!Rn(e[n],t[n]))return!1;return!0}function Ag(e,t,n,r,s,i){if(hi=i,Ie=t,t.memoizedState=null,t.updateQueue=null,t.lanes=0,tu.current=e===null||e.memoizedState===null?bj:_j,e=n(r,s),$a){i=0;do{if($a=!1,fl=0,25<=i)throw Error(M(301));i+=1,Je=Ge=null,t.updateQueue=null,tu.current=Sj,e=n(r,s)}while($a)}if(tu.current=Vu,t=Ge!==null&&Ge.next!==null,hi=0,Je=Ge=Ie=null,Bu=!1,t)throw Error(M(300));return e}function Pg(){var e=fl!==0;return fl=0,e}function zn(){var e={memoizedState:null,baseState:null,baseQueue:null,queue:null,next:null};return Je===null?Ie.memoizedState=Je=e:Je=Je.next=e,Je}function cn(){if(Ge===null){var e=Ie.alternate;e=e!==null?e.memoizedState:null}else e=Ge.next;var t=Je===null?Ie.memoizedState:Je.next;if(t!==null)Je=t,Ge=e;else{if(e===null)throw Error(M(310));Ge=e,e={memoizedState:Ge.memoizedState,baseState:Ge.baseState,baseQueue:Ge.baseQueue,queue:Ge.queue,next:null},Je===null?Ie.memoizedState=Je=e:Je=Je.next=e}return Je}function hl(e,t){return typeof t=="function"?t(e):t}function $f(e){var t=cn(),n=t.queue;if(n===null)throw Error(M(311));n.lastRenderedReducer=e;var r=Ge,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((hi&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,Ie.lanes|=u,pi|=u}c=c.next}while(c!==null&&c!==i);l===null?o=r:l.next=a,Rn(r,t.memoizedState)||(Tt=!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,Ie.lanes|=i,pi|=i,s=s.next;while(s!==e)}else s===null&&(n.lanes=0);return[t.memoizedState,n.dispatch]}function Bf(e){var t=cn(),n=t.queue;if(n===null)throw Error(M(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);Rn(i,t.memoizedState)||(Tt=!0),t.memoizedState=i,t.baseQueue===null&&(t.baseState=i),n.lastRenderedState=i}return[i,r]}function m_(){}function g_(e,t){var n=Ie,r=cn(),s=t(),i=!Rn(r.memoizedState,s);if(i&&(r.memoizedState=s,Tt=!0),r=r.queue,jg(w_.bind(null,n,r,e),[e]),r.getSnapshot!==t||i||Je!==null&&Je.memoizedState.tag&1){if(n.flags|=2048,pl(9,y_.bind(null,n,r,s,t),void 0,null),Xe===null)throw Error(M(349));hi&30||v_(n,t,s)}return s}function v_(e,t,n){e.flags|=16384,e={getSnapshot:t,value:n},t=Ie.updateQueue,t===null?(t={lastEffect:null,stores:null},Ie.updateQueue=t,t.stores=[e]):(n=t.stores,n===null?t.stores=[e]:n.push(e))}function y_(e,t,n,r){t.value=n,t.getSnapshot=r,x_(t)&&b_(e)}function w_(e,t,n){return n(function(){x_(t)&&b_(e)})}function x_(e){var t=e.getSnapshot;e=e.value;try{var n=t();return!Rn(e,n)}catch{return!0}}function b_(e){var t=Tr(e,1);t!==null&&jn(t,e,1,-1)}function e0(e){var t=zn();return typeof e=="function"&&(e=e()),t.memoizedState=t.baseState=e,e={pending:null,interleaved:null,lanes:0,dispatch:null,lastRenderedReducer:hl,lastRenderedState:e},t.queue=e,e=e.dispatch=xj.bind(null,Ie,e),[t.memoizedState,e]}function pl(e,t,n,r){return e={tag:e,create:t,destroy:n,deps:r,next:null},t=Ie.updateQueue,t===null?(t={lastEffect:null,stores:null},Ie.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 __(){return cn().memoizedState}function nu(e,t,n,r){var s=zn();Ie.flags|=e,s.memoizedState=pl(1|t,n,void 0,r===void 0?null:r)}function jd(e,t,n,r){var s=cn();r=r===void 0?null:r;var i=void 0;if(Ge!==null){var o=Ge.memoizedState;if(i=o.destroy,r!==null&&Tg(r,o.deps)){s.memoizedState=pl(t,n,i,r);return}}Ie.flags|=e,s.memoizedState=pl(1|t,n,i,r)}function t0(e,t){return nu(8390656,8,e,t)}function jg(e,t){return jd(2048,8,e,t)}function S_(e,t){return jd(4,2,e,t)}function k_(e,t){return jd(4,4,e,t)}function E_(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 C_(e,t,n){return n=n!=null?n.concat([e]):null,jd(4,4,E_.bind(null,t,e),n)}function Ng(){}function T_(e,t){var n=cn();t=t===void 0?null:t;var r=n.memoizedState;return r!==null&&t!==null&&Tg(t,r[1])?r[0]:(n.memoizedState=[e,t],e)}function A_(e,t){var n=cn();t=t===void 0?null:t;var r=n.memoizedState;return r!==null&&t!==null&&Tg(t,r[1])?r[0]:(e=e(),n.memoizedState=[e,t],e)}function P_(e,t,n){return hi&21?(Rn(n,t)||(n=M1(),Ie.lanes|=n,pi|=n,e.baseState=!0),t):(e.baseState&&(e.baseState=!1,Tt=!0),e.memoizedState=n)}function yj(e,t){var n=ye;ye=n!==0&&4>n?n:4,e(!0);var r=Ff.transition;Ff.transition={};try{e(!1),t()}finally{ye=n,Ff.transition=r}}function j_(){return cn().memoizedState}function wj(e,t,n){var r=ms(e);if(n={lane:r,action:n,hasEagerState:!1,eagerState:null,next:null},N_(e))R_(t,n);else if(n=f_(e,t,n,r),n!==null){var s=xt();jn(n,e,r,s),O_(n,t,r)}}function xj(e,t,n){var r=ms(e),s={lane:r,action:n,hasEagerState:!1,eagerState:null,next:null};if(N_(e))R_(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,Rn(a,o)){var l=t.interleaved;l===null?(s.next=s,_g(t)):(s.next=l.next,l.next=s),t.interleaved=s;return}}catch{}finally{}n=f_(e,t,s,r),n!==null&&(s=xt(),jn(n,e,r,s),O_(n,t,r))}}function N_(e){var t=e.alternate;return e===Ie||t!==null&&t===Ie}function R_(e,t){$a=Bu=!0;var n=e.pending;n===null?t.next=t:(t.next=n.next,n.next=t),e.pending=t}function O_(e,t,n){if(n&4194240){var r=t.lanes;r&=e.pendingLanes,n|=r,t.lanes=n,lg(e,n)}}var Vu={readContext:ln,useCallback:lt,useContext:lt,useEffect:lt,useImperativeHandle:lt,useInsertionEffect:lt,useLayoutEffect:lt,useMemo:lt,useReducer:lt,useRef:lt,useState:lt,useDebugValue:lt,useDeferredValue:lt,useTransition:lt,useMutableSource:lt,useSyncExternalStore:lt,useId:lt,unstable_isNewReconciler:!1},bj={readContext:ln,useCallback:function(e,t){return zn().memoizedState=[e,t===void 0?null:t],e},useContext:ln,useEffect:t0,useImperativeHandle:function(e,t,n){return n=n!=null?n.concat([e]):null,nu(4194308,4,E_.bind(null,t,e),n)},useLayoutEffect:function(e,t){return nu(4194308,4,e,t)},useInsertionEffect:function(e,t){return nu(4,2,e,t)},useMemo:function(e,t){var n=zn();return t=t===void 0?null:t,e=e(),n.memoizedState=[e,t],e},useReducer:function(e,t,n){var r=zn();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=wj.bind(null,Ie,e),[r.memoizedState,e]},useRef:function(e){var t=zn();return e={current:e},t.memoizedState=e},useState:e0,useDebugValue:Ng,useDeferredValue:function(e){return zn().memoizedState=e},useTransition:function(){var e=e0(!1),t=e[0];return e=yj.bind(null,e[1]),zn().memoizedState=e,[t,e]},useMutableSource:function(){},useSyncExternalStore:function(e,t,n){var r=Ie,s=zn();if(Re){if(n===void 0)throw Error(M(407));n=n()}else{if(n=t(),Xe===null)throw Error(M(349));hi&30||v_(r,t,n)}s.memoizedState=n;var i={value:n,getSnapshot:t};return s.queue=i,t0(w_.bind(null,r,i,e),[e]),r.flags|=2048,pl(9,y_.bind(null,r,i,n,t),void 0,null),n},useId:function(){var e=zn(),t=Xe.identifierPrefix;if(Re){var n=Sr,r=_r;n=(r&~(1<<32-Pn(r)-1)).toString(32)+n,t=":"+t+"R"+n,n=fl++,0<n&&(t+="H"+n.toString(32)),t+=":"}else n=vj++,t=":"+t+"r"+n.toString(32)+":";return e.memoizedState=t},unstable_isNewReconciler:!1},_j={readContext:ln,useCallback:T_,useContext:ln,useEffect:jg,useImperativeHandle:C_,useInsertionEffect:S_,useLayoutEffect:k_,useMemo:A_,useReducer:$f,useRef:__,useState:function(){return $f(hl)},useDebugValue:Ng,useDeferredValue:function(e){var t=cn();return P_(t,Ge.memoizedState,e)},useTransition:function(){var e=$f(hl)[0],t=cn().memoizedState;return[e,t]},useMutableSource:m_,useSyncExternalStore:g_,useId:j_,unstable_isNewReconciler:!1},Sj={readContext:ln,useCallback:T_,useContext:ln,useEffect:jg,useImperativeHandle:C_,useInsertionEffect:S_,useLayoutEffect:k_,useMemo:A_,useReducer:Bf,useRef:__,useState:function(){return Bf(hl)},useDebugValue:Ng,useDeferredValue:function(e){var t=cn();return Ge===null?t.memoizedState=e:P_(t,Ge.memoizedState,e)},useTransition:function(){var e=Bf(hl)[0],t=cn().memoizedState;return[e,t]},useMutableSource:m_,useSyncExternalStore:g_,useId:j_,unstable_isNewReconciler:!1};function xn(e,t){if(e&&e.defaultProps){t=Le({},t),e=e.defaultProps;for(var n in e)t[n]===void 0&&(t[n]=e[n]);return t}return t}function _p(e,t,n,r){t=e.memoizedState,n=n(r,t),n=n==null?t:Le({},t,n),e.memoizedState=n,e.lanes===0&&(e.updateQueue.baseState=n)}var Nd={isMounted:function(e){return(e=e._reactInternals)?_i(e)===e:!1},enqueueSetState:function(e,t,n){e=e._reactInternals;var r=xt(),s=ms(e),i=kr(r,s);i.payload=t,n!=null&&(i.callback=n),t=hs(e,i,s),t!==null&&(jn(t,e,s,r),eu(t,e,s))},enqueueReplaceState:function(e,t,n){e=e._reactInternals;var r=xt(),s=ms(e),i=kr(r,s);i.tag=1,i.payload=t,n!=null&&(i.callback=n),t=hs(e,i,s),t!==null&&(jn(t,e,s,r),eu(t,e,s))},enqueueForceUpdate:function(e,t){e=e._reactInternals;var n=xt(),r=ms(e),s=kr(n,r);s.tag=2,t!=null&&(s.callback=t),t=hs(e,s,r),t!==null&&(jn(t,e,r,n),eu(t,e,r))}};function n0(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?!ol(n,r)||!ol(s,i):!0}function M_(e,t,n){var r=!1,s=xs,i=t.contextType;return typeof i=="object"&&i!==null?i=ln(i):(s=jt(t)?di:ft.current,r=t.contextTypes,i=(r=r!=null)?No(e,s):xs),t=new t(n,i),e.memoizedState=t.state!==null&&t.state!==void 0?t.state:null,t.updater=Nd,e.stateNode=t,t._reactInternals=e,r&&(e=e.stateNode,e.__reactInternalMemoizedUnmaskedChildContext=s,e.__reactInternalMemoizedMaskedChildContext=i),t}function r0(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&&Nd.enqueueReplaceState(t,t.state,null)}function Sp(e,t,n,r){var s=e.stateNode;s.props=n,s.state=e.memoizedState,s.refs={},Sg(e);var i=t.contextType;typeof i=="object"&&i!==null?s.context=ln(i):(i=jt(t)?di:ft.current,s.context=No(e,i)),s.state=e.memoizedState,i=t.getDerivedStateFromProps,typeof i=="function"&&(_p(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&&Nd.enqueueReplaceState(s,s.state,null),Fu(e,n,s,r),s.state=e.memoizedState),typeof s.componentDidMount=="function"&&(e.flags|=4194308)}function Do(e,t){try{var n="",r=t;do n+=ZA(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 Vf(e,t,n){return{value:e,source:null,stack:n??null,digest:t??null}}function kp(e,t){try{console.error(t.value)}catch(n){setTimeout(function(){throw n})}}var kj=typeof WeakMap=="function"?WeakMap:Map;function D_(e,t,n){n=kr(-1,n),n.tag=3,n.payload={element:null};var r=t.value;return n.callback=function(){zu||(zu=!0,Mp=r),kp(e,t)},n}function I_(e,t,n){n=kr(-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(){kp(e,t)}}var i=e.stateNode;return i!==null&&typeof i.componentDidCatch=="function"&&(n.callback=function(){kp(e,t),typeof r!="function"&&(ps===null?ps=new Set([this]):ps.add(this));var o=t.stack;this.componentDidCatch(t.value,{componentStack:o!==null?o:""})}),n}function s0(e,t,n){var r=e.pingCache;if(r===null){r=e.pingCache=new kj;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=Fj.bind(null,e,t,n),t.then(e,e))}function i0(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}
vendor: 10,242 bytes, line 40
40function o0(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=kr(-1,1),t.tag=2,hs(n,t,1))),n.lanes|=1),e)}var Ej=Rr.ReactCurrentOwner,Tt=!1;function pt(e,t,n,r){t.child=e===null?d_(t,null,n,r):Oo(t,e.child,n,r)}function a0(e,t,n,r,s){n=n.render;var i=t.ref;return po(t,s),r=Ag(e,t,n,r,i,s),n=Pg(),e!==null&&!Tt?(t.updateQueue=e.updateQueue,t.flags&=-2053,e.lanes&=~s,Ar(e,t,s)):(Re&&n&&gg(t),t.flags|=1,pt(e,t,r,s),t.child)}function l0(e,t,n,r,s){if(e===null){var i=n.type;return typeof i=="function"&&!$g(i)&&i.defaultProps===void 0&&n.compare===null&&n.defaultProps===void 0?(t.tag=15,t.type=i,L_(e,t,i,r,s)):(e=ou(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:ol,n(o,r)&&e.ref===t.ref)return Ar(e,t,s)}return t.flags|=1,e=gs(i,r),e.ref=t.ref,e.return=t,t.child=e}function L_(e,t,n,r,s){if(e!==null){var i=e.memoizedProps;if(ol(i,r)&&e.ref===t.ref)if(Tt=!1,t.pendingProps=r=i,(e.lanes&s)!==0)e.flags&131072&&(Tt=!0);else return t.lanes=e.lanes,Ar(e,t,s)}return Ep(e,t,n,r,s)}function F_(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},Se(io,Ft),Ft|=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,Se(io,Ft),Ft|=e,null;t.memoizedState={baseLanes:0,cachePool:null,transitions:null},r=i!==null?i.baseLanes:n,Se(io,Ft),Ft|=r}else i!==null?(r=i.baseLanes|n,t.memoizedState=null):r=n,Se(io,Ft),Ft|=r;return pt(e,t,s,n),t.child}function $_(e,t){var n=t.ref;(e===null&&n!==null||e!==null&&e.ref!==n)&&(t.flags|=512,t.flags|=2097152)}function Ep(e,t,n,r,s){var i=jt(n)?di:ft.current;return i=No(t,i),po(t,s),n=Ag(e,t,n,r,i,s),r=Pg(),e!==null&&!Tt?(t.updateQueue=e.updateQueue,t.flags&=-2053,e.lanes&=~s,Ar(e,t,s)):(Re&&r&&gg(t),t.flags|=1,pt(e,t,n,s),t.child)}function c0(e,t,n,r,s){if(jt(n)){var i=!0;Ou(t)}else i=!1;if(po(t,s),t.stateNode===null)ru(e,t),M_(t,n,r),Sp(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=ln(c):(c=jt(n)?di:ft.current,c=No(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)&&r0(t,o,r,c),Yr=!1;var h=t.memoizedState;o.state=h,Fu(t,r,o,s),l=t.memoizedState,a!==r||h!==l||Pt.current||Yr?(typeof u=="function"&&(_p(t,n,u,r),l=t.memoizedState),(a=Yr||n0(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,h_(e,t),a=t.memoizedProps,c=t.type===t.elementType?a:xn(t.type,a),o.props=c,d=t.pendingProps,h=o.context,l=n.contextType,typeof l=="object"&&l!==null?l=ln(l):(l=jt(n)?di:ft.current,l=No(t,l));var p=n.getDerivedStateFromProps;(u=typeof p=="function"||typeof o.getSnapshotBeforeUpdate=="function")||typeof o.UNSAFE_componentWillReceiveProps!="function"&&typeof o.componentWillReceiveProps!="function"||(a!==d||h!==l)&&r0(t,o,r,l),Yr=!1,h=t.memoizedState,o.state=h,Fu(t,r,o,s);var b=t.memoizedState;a!==d||h!==b||Pt.current||Yr?(typeof p=="function"&&(_p(t,n,p,r),b=t.memoizedState),(c=Yr||n0(t,n,c,r,h,b,l)||!1)?(u||typeof o.UNSAFE_componentWillUpdate!="function"&&typeof o.componentWillUpdate!="function"||(typeof o.componentWillUpdate=="function"&&o.componentWillUpdate(r,b,l),typeof o.UNSAFE_componentWillUpdate=="function"&&o.UNSAFE_componentWillUpdate(r,b,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=b),o.props=r,o.state=b,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 Cp(e,t,n,r,i,s)}function Cp(e,t,n,r,s,i){$_(e,t);var o=(t.flags&128)!==0;if(!r&&!o)return s&&Yy(t,n,!1),Ar(e,t,i);r=t.stateNode,Ej.current=t;var a=o&&typeof n.getDerivedStateFromError!="function"?null:r.render();return t.flags|=1,e!==null&&o?(t.child=Oo(t,e.child,null,i),t.child=Oo(t,null,a,i)):pt(e,t,a,i),t.memoizedState=r.state,s&&Yy(t,n,!0),t.child}function B_(e){var t=e.stateNode;t.pendingContext?qy(e,t.pendingContext,t.pendingContext!==t.context):t.context&&qy(e,t.context,!1),kg(e,t.containerInfo)}function u0(e,t,n,r,s){return Ro(),yg(s),t.flags|=256,pt(e,t,n,r),t.child}var Tp={dehydrated:null,treeContext:null,retryLane:0};function Ap(e){return{baseLanes:e,cachePool:null,transitions:null}}function V_(e,t,n){var r=t.pendingProps,s=De.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),Se(De,s&1),e===null)return xp(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=Md(o,r,0,null),e=li(e,r,n,null),i.return=t,e.return=t,i.sibling=e,t.child=i,t.child.memoizedState=Ap(n),t.memoizedState=Tp,e):Rg(t,o));if(s=e.memoizedState,s!==null&&(a=s.dehydrated,a!==null))return Cj(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=gs(s,l),r.subtreeFlags=s.subtreeFlags&14680064),a!==null?i=gs(a,i):(i=li(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?Ap(n):{baseLanes:o.baseLanes|n,cachePool:null,transitions:o.transitions},i.memoizedState=o,i.childLanes=e.childLanes&~n,t.memoizedState=Tp,r}return i=e.child,e=i.sibling,r=gs(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 Rg(e,t){return t=Md({mode:"visible",children:t},e.mode,0,null),t.return=e,e.child=t}function Sc(e,t,n,r){return r!==null&&yg(r),Oo(t,e.child,null,n),e=Rg(t,t.pendingProps.children),e.flags|=2,t.memoizedState=null,e}function Cj(e,t,n,r,s,i,o){if(n)return t.flags&256?(t.flags&=-257,r=Vf(Error(M(422))),Sc(e,t,o,r)):t.memoizedState!==null?(t.child=e.child,t.flags|=128,null):(i=r.fallback,s=t.mode,r=Md({mode:"visible",children:r.children},s,0,null),i=li(i,s,o,null),i.flags|=2,r.return=t,i.return=t,r.sibling=i,t.child=r,t.mode&1&&Oo(t,e.child,null,o),t.child.memoizedState=Ap(o),t.memoizedState=Tp,i);if(!(t.mode&1))return Sc(e,t,o,null);if(s.data==="$!"){if(r=s.nextSibling&&s.nextSibling.dataset,r)var a=r.dgst;return r=a,i=Error(M(419)),r=Vf(i,r,void 0),Sc(e,t,o,r)}if(a=(o&e.childLanes)!==0,Tt||a){if(r=Xe,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,Tr(e,s),jn(r,e,s,-1))}return Fg(),r=Vf(Error(M(421))),Sc(e,t,o,r)}return s.data==="$?"?(t.flags|=128,t.child=e.child,t=$j.bind(null,e),s._reactRetry=t,null):(e=i.treeContext,Bt=fs(s.nextSibling),Vt=t,Re=!0,Cn=null,e!==null&&(tn[nn++]=_r,tn[nn++]=Sr,tn[nn++]=fi,_r=e.id,Sr=e.overflow,fi=t),t=Rg(t,r.children),t.flags|=4096,t)}function d0(e,t,n){e.lanes|=t;var r=e.alternate;r!==null&&(r.lanes|=t),bp(e.return,t,n)}function Uf(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 U_(e,t,n){var r=t.pendingProps,s=r.revealOrder,i=r.tail;if(pt(e,t,r.children,n),r=De.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&&d0(e,n,t);else if(e.tag===19)d0(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(Se(De,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&&$u(e)===null&&(s=n),n=n.sibling;n=s,n===null?(s=t.child,t.child=null):(s=n.sibling,n.sibling=null),Uf(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&&$u(e)===null){t.child=s;break}e=s.sibling,s.sibling=n,n=s,s=e}Uf(t,!0,n,null,i);break;case"together":Uf(t,!1,null,null,void 0);break;default:t.memoizedState=null}return t.child}function ru(e,t){!(t.mode&1)&&e!==null&&(e.alternate=null,t.alternate=null,t.flags|=2)}function Ar(e,t,n){if(e!==null&&(t.dependencies=e.dependencies),pi|=t.lanes,!(n&t.childLanes))return null;if(e!==null&&t.child!==e.child)throw Error(M(153));if(t.child!==null){for(e=t.child,n=gs(e,e.pendingProps),t.child=n,n.return=t;e.sibling!==null;)e=e.sibling,n=n.sibling=gs(e,e.pendingProps),n.return=t;n.sibling=null}return t.child}
vendor: 4,565 bytes, line 40
40function Tj(e,t,n){switch(t.tag){case 3:B_(t),Ro();break;case 5:p_(t);break;case 1:jt(t.type)&&Ou(t);break;case 4:kg(t,t.stateNode.containerInfo);break;case 10:var r=t.type._context,s=t.memoizedProps.value;Se(Iu,r._currentValue),r._currentValue=s;break;case 13:if(r=t.memoizedState,r!==null)return r.dehydrated!==null?(Se(De,De.current&1),t.flags|=128,null):n&t.child.childLanes?V_(e,t,n):(Se(De,De.current&1),e=Ar(e,t,n),e!==null?e.sibling:null);Se(De,De.current&1);break;case 19:if(r=(n&t.childLanes)!==0,e.flags&128){if(r)return U_(e,t,n);t.flags|=128}if(s=t.memoizedState,s!==null&&(s.rendering=null,s.tail=null,s.lastEffect=null),Se(De,De.current),r)break;return null;case 22:case 23:return t.lanes=0,F_(e,t,n)}return Ar(e,t,n)}var z_,Pp,W_,H_;z_=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}};Pp=function(){};W_=function(e,t,n,r){var s=e.memoizedProps;if(s!==r){e=t.stateNode,Qs(nr.current);var i=null;switch(n){case"input":s=Zh(e,s),r=Zh(e,r),i=[];break;case"select":s=Le({},s,{value:void 0}),r=Le({},r,{value:void 0}),i=[];break;case"textarea":s=ep(e,s),r=ep(e,r),i=[];break;default:typeof s.onClick!="function"&&typeof r.onClick=="function"&&(e.onclick=Nu)}np(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"&&(Xa.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"&&(Xa.hasOwnProperty(c)?(l!=null&&c==="onScroll"&&Ce("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)}};H_=function(e,t,n,r){n!==r&&(t.flags|=4)};function ma(e,t){if(!Re)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 ct(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 Aj(e,t,n){var r=t.pendingProps;switch(vg(t),t.tag){case 2:case 16:case 15:case 0:case 11:case 7:case 8:case 12:case 9:case 14:return ct(t),null;case 1:return jt(t.type)&&Ru(),ct(t),null;case 3:return r=t.stateNode,Mo(),Pe(Pt),Pe(ft),Cg(),r.pendingContext&&(r.context=r.pendingContext,r.pendingContext=null),(e===null||e.child===null)&&(bc(t)?t.flags|=4:e===null||e.memoizedState.isDehydrated&&!(t.flags&256)||(t.flags|=1024,Cn!==null&&(Lp(Cn),Cn=null))),Pp(e,t),ct(t),null;case 5:Eg(t);var s=Qs(dl.current);if(n=t.type,e!==null&&t.stateNode!=null)W_(e,t,n,r,s),e.ref!==t.ref&&(t.flags|=512,t.flags|=2097152);else{if(!r){if(t.stateNode===null)throw Error(M(166));return ct(t),null}if(e=Qs(nr.current),bc(t)){r=t.stateNode,n=t.type;var i=t.memoizedProps;switch(r[Zn]=t,r[cl]=i,e=(t.mode&1)!==0,n){case"dialog":Ce("cancel",r),Ce("close",r);break;case"iframe":case"object":case"embed":Ce("load",r);break;case"video":case"audio":for(s=0;s<Pa.length;s++)Ce(Pa[s],r);break;case"source":Ce("error",r);break;case"img":case"image":case"link":Ce("error",r),Ce("load",r);break;case"details":Ce("toggle",r);break;case"input":xy(r,i),Ce("invalid",r);break;case"select":r._wrapperState={wasMultiple:!!i.multiple},Ce("invalid",r);break;case"textarea":_y(r,i),Ce("invalid",r)}np(n,i),s=null;for(var o in i)if(i.hasOwnProperty(o)){var a=i[o];
vendor: 28,896 bytes, line 40
40o==="children"?typeof a=="string"?r.textContent!==a&&(i.suppressHydrationWarning!==!0&&xc(r.textContent,a,e),s=["children",a]):typeof a=="number"&&r.textContent!==""+a&&(i.suppressHydrationWarning!==!0&&xc(r.textContent,a,e),s=["children",""+a]):Xa.hasOwnProperty(o)&&a!=null&&o==="onScroll"&&Ce("scroll",r)}switch(n){case"input":fc(r),by(r,i,!0);break;case"textarea":fc(r),Sy(r);break;case"select":case"option":break;default:typeof i.onClick=="function"&&(r.onclick=Nu)}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=w1(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[Zn]=t,e[cl]=r,z_(e,t,!1,!1),t.stateNode=e;e:{switch(o=rp(n,r),n){case"dialog":Ce("cancel",e),Ce("close",e),s=r;break;case"iframe":case"object":case"embed":Ce("load",e),s=r;break;case"video":case"audio":for(s=0;s<Pa.length;s++)Ce(Pa[s],e);s=r;break;case"source":Ce("error",e),s=r;break;case"img":case"image":case"link":Ce("error",e),Ce("load",e),s=r;break;case"details":Ce("toggle",e),s=r;break;case"input":xy(e,r),s=Zh(e,r),Ce("invalid",e);break;case"option":s=r;break;case"select":e._wrapperState={wasMultiple:!!r.multiple},s=Le({},r,{value:void 0}),Ce("invalid",e);break;case"textarea":_y(e,r),s=ep(e,r),Ce("invalid",e);break;default:s=r}np(n,s),a=s;for(i in a)if(a.hasOwnProperty(i)){var l=a[i];i==="style"?_1(e,l):i==="dangerouslySetInnerHTML"?(l=l?l.__html:void 0,l!=null&&x1(e,l)):i==="children"?typeof l=="string"?(n!=="textarea"||l!=="")&&el(e,l):typeof l=="number"&&el(e,""+l):i!=="suppressContentEditableWarning"&&i!=="suppressHydrationWarning"&&i!=="autoFocus"&&(Xa.hasOwnProperty(i)?l!=null&&i==="onScroll"&&Ce("scroll",e):l!=null&&ng(e,i,l,o))}switch(n){case"input":fc(e),by(e,r,!1);break;case"textarea":fc(e),Sy(e);break;case"option":r.value!=null&&e.setAttribute("value",""+ws(r.value));break;case"select":e.multiple=!!r.multiple,i=r.value,i!=null?co(e,!!r.multiple,i,!1):r.defaultValue!=null&&co(e,!!r.multiple,r.defaultValue,!0);break;default:typeof s.onClick=="function"&&(e.onclick=Nu)}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 ct(t),null;case 6:if(e&&t.stateNode!=null)H_(e,t,e.memoizedProps,r);else{if(typeof r!="string"&&t.stateNode===null)throw Error(M(166));if(n=Qs(dl.current),Qs(nr.current),bc(t)){if(r=t.stateNode,n=t.memoizedProps,r[Zn]=t,(i=r.nodeValue!==n)&&(e=Vt,e!==null))switch(e.tag){case 3:xc(r.nodeValue,n,(e.mode&1)!==0);break;case 5:e.memoizedProps.suppressHydrationWarning!==!0&&xc(r.nodeValue,n,(e.mode&1)!==0)}i&&(t.flags|=4)}else r=(n.nodeType===9?n:n.ownerDocument).createTextNode(r),r[Zn]=t,t.stateNode=r}return ct(t),null;case 13:if(Pe(De),r=t.memoizedState,e===null||e.memoizedState!==null&&e.memoizedState.dehydrated!==null){if(Re&&Bt!==null&&t.mode&1&&!(t.flags&128))c_(),Ro(),t.flags|=98560,i=!1;else if(i=bc(t),r!==null&&r.dehydrated!==null){if(e===null){if(!i)throw Error(M(318));if(i=t.memoizedState,i=i!==null?i.dehydrated:null,!i)throw Error(M(317));i[Zn]=t}else Ro(),!(t.flags&128)&&(t.memoizedState=null),t.flags|=4;ct(t),i=!1}else Cn!==null&&(Lp(Cn),Cn=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||De.current&1?Qe===0&&(Qe=3):Fg())),t.updateQueue!==null&&(t.flags|=4),ct(t),null);case 4:return Mo(),Pp(e,t),e===null&&al(t.stateNode.containerInfo),ct(t),null;case 10:return bg(t.type._context),ct(t),null;case 17:return jt(t.type)&&Ru(),ct(t),null;case 19:if(Pe(De),i=t.memoizedState,i===null)return ct(t),null;if(r=(t.flags&128)!==0,o=i.rendering,o===null)if(r)ma(i,!1);else{if(Qe!==0||e!==null&&e.flags&128)for(e=t.child;e!==null;){if(o=$u(e),o!==null){for(t.flags|=128,ma(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 Se(De,De.current&1|2),t.child}e=e.sibling}i.tail!==null&&Ve()>Io&&(t.flags|=128,r=!0,ma(i,!1),t.lanes=4194304)}else{if(!r)if(e=$u(o),e!==null){if(t.flags|=128,r=!0,n=e.updateQueue,n!==null&&(t.updateQueue=n,t.flags|=4),ma(i,!0),i.tail===null&&i.tailMode==="hidden"&&!o.alternate&&!Re)return ct(t),null}else 2*Ve()-i.renderingStartTime>Io&&n!==1073741824&&(t.flags|=128,r=!0,ma(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=Ve(),t.sibling=null,n=De.current,Se(De,r?n&1|2:n&1),t):(ct(t),null);case 22:case 23:return Lg(),r=t.memoizedState!==null,e!==null&&e.memoizedState!==null!==r&&(t.flags|=8192),r&&t.mode&1?Ft&1073741824&&(ct(t),t.subtreeFlags&6&&(t.flags|=8192)):ct(t),null;case 24:return null;case 25:return null}throw Error(M(156,t.tag))}function Pj(e,t){switch(vg(t),t.tag){case 1:return jt(t.type)&&Ru(),e=t.flags,e&65536?(t.flags=e&-65537|128,t):null;case 3:return Mo(),Pe(Pt),Pe(ft),Cg(),e=t.flags,e&65536&&!(e&128)?(t.flags=e&-65537|128,t):null;case 5:return Eg(t),null;case 13:if(Pe(De),e=t.memoizedState,e!==null&&e.dehydrated!==null){if(t.alternate===null)throw Error(M(340));Ro()}return e=t.flags,e&65536?(t.flags=e&-65537|128,t):null;case 19:return Pe(De),null;case 4:return Mo(),null;case 10:return bg(t.type._context),null;case 22:case 23:return Lg(),null;case 24:return null;default:return null}}var kc=!1,dt=!1,jj=typeof WeakSet=="function"?WeakSet:Set,H=null;function so(e,t){var n=e.ref;if(n!==null)if(typeof n=="function")try{n(null)}catch(r){Be(e,t,r)}else n.current=null}function jp(e,t,n){try{n()}catch(r){Be(e,t,r)}}var f0=!1;function Nj(e,t){if(hp=Au,e=Q1(),mg(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 p;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),(p=d.firstChild)!==null;)h=d,d=p;for(;;){if(d===e)break t;if(h===n&&++c===s&&(a=o),h===i&&++u===r&&(l=o),(p=d.nextSibling)!==null)break;d=h,h=d.parentNode}d=p}n=a===-1||l===-1?null:{start:a,end:l}}else n=null}n=n||{start:0,end:0}}else n=null;for(pp={focusedElem:e,selectionRange:n},Au=!1,H=t;H!==null;)if(t=H,e=t.child,(t.subtreeFlags&1028)!==0&&e!==null)e.return=t,H=e;else for(;H!==null;){t=H;try{var b=t.alternate;if(t.flags&1024)switch(t.tag){case 0:case 11:case 15:break;case 1:if(b!==null){var g=b.memoizedProps,x=b.memoizedState,y=t.stateNode,m=y.getSnapshotBeforeUpdate(t.elementType===t.type?g:xn(t.type,g),x);y.__reactInternalSnapshotBeforeUpdate=m}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(M(163))}}catch(_){Be(t,t.return,_)}if(e=t.sibling,e!==null){e.return=t.return,H=e;break}H=t.return}return b=f0,f0=!1,b}function Ba(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&&jp(t,n,i)}s=s.next}while(s!==r)}}function Rd(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 Np(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 K_(e){var t=e.alternate;t!==null&&(e.alternate=null,K_(t)),e.child=null,e.deletions=null,e.sibling=null,e.tag===5&&(t=e.stateNode,t!==null&&(delete t[Zn],delete t[cl],delete t[vp],delete t[hj],delete t[pj])),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 q_(e){return e.tag===5||e.tag===3||e.tag===4}function h0(e){e:for(;;){for(;e.sibling===null;){if(e.return===null||q_(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 Rp(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=Nu));else if(r!==4&&(e=e.child,e!==null))for(Rp(e,t,n),e=e.sibling;e!==null;)Rp(e,t,n),e=e.sibling}function Op(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(Op(e,t,n),e=e.sibling;e!==null;)Op(e,t,n),e=e.sibling}var et=null,kn=!1;function Ir(e,t,n){for(n=n.child;n!==null;)Y_(e,t,n),n=n.sibling}function Y_(e,t,n){if(tr&&typeof tr.onCommitFiberUnmount=="function")try{tr.onCommitFiberUnmount(kd,n)}catch{}switch(n.tag){case 5:dt||so(n,t);case 6:var r=et,s=kn;et=null,Ir(e,t,n),et=r,kn=s,et!==null&&(kn?(e=et,n=n.stateNode,e.nodeType===8?e.parentNode.removeChild(n):e.removeChild(n)):et.removeChild(n.stateNode));break;case 18:et!==null&&(kn?(e=et,n=n.stateNode,e.nodeType===8?Df(e.parentNode,n):e.nodeType===1&&Df(e,n),sl(e)):Df(et,n.stateNode));break;case 4:r=et,s=kn,et=n.stateNode.containerInfo,kn=!0,Ir(e,t,n),et=r,kn=s;break;case 0:case 11:case 14:case 15:if(!dt&&(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)&&jp(n,t,o),s=s.next}while(s!==r)}Ir(e,t,n);break;case 1:if(!dt&&(so(n,t),r=n.stateNode,typeof r.componentWillUnmount=="function"))try{r.props=n.memoizedProps,r.state=n.memoizedState,r.componentWillUnmount()}catch(a){Be(n,t,a)}Ir(e,t,n);break;case 21:Ir(e,t,n);break;case 22:n.mode&1?(dt=(r=dt)||n.memoizedState!==null,Ir(e,t,n),dt=r):Ir(e,t,n);break;default:Ir(e,t,n)}}function p0(e){var t=e.updateQueue;if(t!==null){e.updateQueue=null;var n=e.stateNode;n===null&&(n=e.stateNode=new jj),t.forEach(function(r){var s=Bj.bind(null,e,r);n.has(r)||(n.add(r),r.then(s,s))})}}function mn(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:et=a.stateNode,kn=!1;break e;case 3:et=a.stateNode.containerInfo,kn=!0;break e;case 4:et=a.stateNode.containerInfo,kn=!0;break e}a=a.return}if(et===null)throw Error(M(160));Y_(i,o,s),et=null,kn=!1;var l=s.alternate;l!==null&&(l.return=null),s.return=null}catch(c){Be(s,t,c)}}if(t.subtreeFlags&12854)for(t=t.child;t!==null;)G_(t,e),t=t.sibling}function G_(e,t){var n=e.alternate,r=e.flags;switch(e.tag){case 0:case 11:case 14:case 15:if(mn(t,e),Vn(e),r&4){try{Ba(3,e,e.return),Rd(3,e)}catch(g){Be(e,e.return,g)}try{Ba(5,e,e.return)}catch(g){Be(e,e.return,g)}}break;case 1:mn(t,e),Vn(e),r&512&&n!==null&&so(n,n.return);break;case 5:if(mn(t,e),Vn(e),r&512&&n!==null&&so(n,n.return),e.flags&32){var s=e.stateNode;try{el(s,"")}catch(g){Be(e,e.return,g)}}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&&v1(s,i),rp(a,o);var c=rp(a,i);for(o=0;o<l.length;o+=2){var u=l[o],d=l[o+1];u==="style"?_1(s,d):u==="dangerouslySetInnerHTML"?x1(s,d):u==="children"?el(s,d):ng(s,u,d,c)}switch(a){case"input":Jh(s,i);break;case"textarea":y1(s,i);break;case"select":var h=s._wrapperState.wasMultiple;s._wrapperState.wasMultiple=!!i.multiple;var p=i.value;p!=null?co(s,!!i.multiple,p,!1):h!==!!i.multiple&&(i.defaultValue!=null?co(s,!!i.multiple,i.defaultValue,!0):co(s,!!i.multiple,i.multiple?[]:"",!1))}s[cl]=i}catch(g){Be(e,e.return,g)}}break;case 6:if(mn(t,e),Vn(e),r&4){if(e.stateNode===null)throw Error(M(162));s=e.stateNode,i=e.memoizedProps;try{s.nodeValue=i}catch(g){Be(e,e.return,g)}}break;case 3:if(mn(t,e),Vn(e),r&4&&n!==null&&n.memoizedState.isDehydrated)try{sl(t.containerInfo)}catch(g){Be(e,e.return,g)}break;case 4:mn(t,e),Vn(e);break;case 13:mn(t,e),Vn(e),s=e.child,s.flags&8192&&(i=s.memoizedState!==null,s.stateNode.isHidden=i,!i||s.alternate!==null&&s.alternate.memoizedState!==null||(Dg=Ve())),r&4&&p0(e);break;case 22:if(u=n!==null&&n.memoizedState!==null,e.mode&1?(dt=(c=dt)||u,mn(t,e),dt=c):mn(t,e),Vn(e),r&8192){if(c=e.memoizedState!==null,(e.stateNode.isHidden=c)&&!u&&e.mode&1)for(H=e,u=e.child;u!==null;){for(d=H=u;H!==null;){switch(h=H,p=h.child,h.tag){case 0:case 11:case 14:case 15:Ba(4,h,h.return);break;case 1:so(h,h.return);var b=h.stateNode;if(typeof b.componentWillUnmount=="function"){r=h,n=h.return;try{t=r,b.props=t.memoizedProps,b.state=t.memoizedState,b.componentWillUnmount()}catch(g){Be(r,n,g)}}break;case 5:so(h,h.return);break;case 22:if(h.memoizedState!==null){g0(d);continue}}p!==null?(p.return=h,H=p):g0(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=b1("display",o))}catch(g){Be(e,e.return,g)}}}else if(d.tag===6){if(u===null)try{d.stateNode.nodeValue=c?"":d.memoizedProps}catch(g){Be(e,e.return,g)}}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:mn(t,e),Vn(e),r&4&&p0(e);break;case 21:break;default:mn(t,e),Vn(e)}}function Vn(e){var t=e.flags;if(t&2){try{e:{for(var n=e.return;n!==null;){if(q_(n)){var r=n;break e}n=n.return}throw Error(M(160))}switch(r.tag){case 5:var s=r.stateNode;r.flags&32&&(el(s,""),r.flags&=-33);var i=h0(e);Op(e,i,s);break;case 3:case 4:var o=r.stateNode.containerInfo,a=h0(e);Rp(e,a,o);break;default:throw Error(M(161))}}catch(l){Be(e,e.return,l)}e.flags&=-3}t&4096&&(e.flags&=-4097)}function Rj(e,t,n){H=e,Q_(e)}function Q_(e,t,n){for(var r=(e.mode&1)!==0;H!==null;){var s=H,i=s.child;if(s.tag===22&&r){var o=s.memoizedState!==null||kc;if(!o){var a=s.alternate,l=a!==null&&a.memoizedState!==null||dt;a=kc;var c=dt;if(kc=o,(dt=l)&&!c)for(H=s;H!==null;)o=H,l=o.child,o.tag===22&&o.memoizedState!==null?v0(s):l!==null?(l.return=o,H=l):v0(s);for(;i!==null;)H=i,Q_(i),i=i.sibling;H=s,kc=a,dt=c}m0(e)}else s.subtreeFlags&8772&&i!==null?(i.return=s,H=i):m0(e)}}function m0(e){for(;H!==null;){var t=H;if(t.flags&8772){var n=t.alternate;try{if(t.flags&8772)switch(t.tag){case 0:case 11:case 15:dt||Rd(5,t);break;case 1:var r=t.stateNode;if(t.flags&4&&!dt)if(n===null)r.componentDidMount();else{var s=t.elementType===t.type?n.memoizedProps:xn(t.type,n.memoizedProps);r.componentDidUpdate(s,n.memoizedState,r.__reactInternalSnapshotBeforeUpdate)}var i=t.updateQueue;i!==null&&Xy(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}Xy(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&&sl(d)}}}break;case 19:case 17:case 21:case 22:case 23:case 25:break;default:throw Error(M(163))}dt||t.flags&512&&Np(t)}catch(h){Be(t,t.return,h)}}if(t===e){H=null;break}if(n=t.sibling,n!==null){n.return=t.return,H=n;break}H=t.return}}function g0(e){for(;H!==null;){var t=H;if(t===e){H=null;break}var n=t.sibling;if(n!==null){n.return=t.return,H=n;break}H=t.return}}function v0(e){for(;H!==null;){var t=H;try{switch(t.tag){case 0:case 11:case 15:var n=t.return;try{Rd(4,t)}catch(l){Be(t,n,l)}break;case 1:var r=t.stateNode;if(typeof r.componentDidMount=="function"){var s=t.return;try{r.componentDidMount()}catch(l){Be(t,s,l)}}var i=t.return;try{Np(t)}catch(l){Be(t,i,l)}break;case 5:var o=t.return;try{Np(t)}catch(l){Be(t,o,l)}}}catch(l){Be(t,t.return,l)}if(t===e){H=null;break}var a=t.sibling;if(a!==null){a.return=t.return,H=a;break}H=t.return}}var Oj=Math.ceil,Uu=Rr.ReactCurrentDispatcher,Og=Rr.ReactCurrentOwner,on=Rr.ReactCurrentBatchConfig,de=0,Xe=null,He=null,rt=0,Ft=0,io=Ps(0),Qe=0,ml=null,pi=0,Od=0,Mg=0,Va=null,Et=null,Dg=0,Io=1/0,yr=null,zu=!1,Mp=null,ps=null,Ec=!1,is=null,Wu=0,Ua=0,Dp=null,su=-1,iu=0;function xt(){return de&6?Ve():su!==-1?su:su=Ve()}function ms(e){return e.mode&1?de&2&&rt!==0?rt&-rt:gj.transition!==null?(iu===0&&(iu=M1()),iu):(e=ye,e!==0||(e=window.event,e=e===void 0?16:V1(e.type)),e):1}function jn(e,t,n,r){if(50<Ua)throw Ua=0,Dp=null,Error(M(185));Fl(e,n,r),(!(de&2)||e!==Xe)&&(e===Xe&&(!(de&2)&&(Od|=n),Qe===4&&Zr(e,rt)),Nt(e,r),n===1&&de===0&&!(t.mode&1)&&(Io=Ve()+500,Pd&&js()))}function Nt(e,t){var n=e.callbackNode;gP(e,t);var r=Tu(e,e===Xe?rt:0);if(r===0)n!==null&&Cy(n),e.callbackNode=null,e.callbackPriority=0;else if(t=r&-r,e.callbackPriority!==t){if(n!=null&&Cy(n),t===1)e.tag===0?mj(y0.bind(null,e)):o_(y0.bind(null,e)),dj(function(){!(de&6)&&js()}),n=null;else{switch(D1(r)){case 1:n=ag;break;case 4:n=R1;break;case 16:n=Cu;break;case 536870912:n=O1;break;default:n=Cu}n=sS(n,Z_.bind(null,e))}e.callbackPriority=t,e.callbackNode=n}}function Z_(e,t){if(su=-1,iu=0,de&6)throw Error(M(327));var n=e.callbackNode;if(mo()&&e.callbackNode!==n)return null;var r=Tu(e,e===Xe?rt:0);if(r===0)return null;if(r&30||r&e.expiredLanes||t)t=Hu(e,r);else{t=r;var s=de;de|=2;var i=X_();(Xe!==e||rt!==t)&&(yr=null,Io=Ve()+500,ai(e,t));do try{Ij();break}catch(a){J_(e,a)}while(!0);xg(),Uu.current=i,de=s,He!==null?t=0:(Xe=null,rt=0,t=Qe)}if(t!==0){if(t===2&&(s=lp(e),s!==0&&(r=s,t=Ip(e,s))),t===1)throw n=ml,ai(e,0),Zr(e,r),Nt(e,Ve()),n;if(t===6)Zr(e,r);else{if(s=e.current.alternate,!(r&30)&&!Mj(s)&&(t=Hu(e,r),t===2&&(i=lp(e),i!==0&&(r=i,t=Ip(e,i))),t===1))throw n=ml,ai(e,0),Zr(e,r),Nt(e,Ve()),n;switch(e.finishedWork=s,e.finishedLanes=r,t){case 0:case 1:throw Error(M(345));case 2:Us(e,Et,yr);break;case 3:if(Zr(e,r),(r&130023424)===r&&(t=Dg+500-Ve(),10<t)){if(Tu(e,0)!==0)break;if(s=e.suspendedLanes,(s&r)!==r){xt(),e.pingedLanes|=e.suspendedLanes&s;break}e.timeoutHandle=gp(Us.bind(null,e,Et,yr),t);break}Us(e,Et,yr);break;case 4:if(Zr(e,r),(r&4194240)===r)break;for(t=e.eventTimes,s=-1;0<r;){var o=31-Pn(r);i=1<<o,o=t[o],o>s&&(s=o),r&=~i}if(r=s,r=Ve()-r,r=(120>r?120:480>r?480:1080>r?1080:1920>r?1920:3e3>r?3e3:4320>r?4320:1960*Oj(r/1960))-r,10<r){e.timeoutHandle=gp(Us.bind(null,e,Et,yr),r);break}Us(e,Et,yr);break;case 5:Us(e,Et,yr);break;default:throw Error(M(329))}}}return Nt(e,Ve()),e.callbackNode===n?Z_.bind(null,e):null}function Ip(e,t){var n=Va;return e.current.memoizedState.isDehydrated&&(ai(e,t).flags|=256),e=Hu(e,t),e!==2&&(t=Et,Et=n,t!==null&&Lp(t)),e}function Lp(e){Et===null?Et=e:Et.push.apply(Et,e)}function Mj(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(!Rn(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 Zr(e,t){for(t&=~Mg,t&=~Od,e.suspendedLanes|=t,e.pingedLanes&=~t,e=e.expirationTimes;0<t;){var n=31-Pn(t),r=1<<n;e[n]=-1,t&=~r}}function y0(e){if(de&6)throw Error(M(327));mo();var t=Tu(e,0);if(!(t&1))return Nt(e,Ve()),null;var n=Hu(e,t);if(e.tag!==0&&n===2){var r=lp(e);r!==0&&(t=r,n=Ip(e,r))}if(n===1)throw n=ml,ai(e,0),Zr(e,t),Nt(e,Ve()),n;if(n===6)throw Error(M(345));return e.finishedWork=e.current.alternate,e.finishedLanes=t,Us(e,Et,yr),Nt(e,Ve()),null}function Ig(e,t){var n=de;de|=1;try{return e(t)}finally{de=n,de===0&&(Io=Ve()+500,Pd&&js())}}function mi(e){is!==null&&is.tag===0&&!(de&6)&&mo();var t=de;de|=1;var n=on.transition,r=ye;try{if(on.transition=null,ye=1,e)return e()}finally{ye=r,on.transition=n,de=t,!(de&6)&&js()}}function Lg(){Ft=io.current,Pe(io)}function ai(e,t){e.finishedWork=null,e.finishedLanes=0;var n=e.timeoutHandle;if(n!==-1&&(e.timeoutHandle=-1,uj(n)),He!==null)for(n=He.return;n!==null;){var r=n;switch(vg(r),r.tag){case 1:r=r.type.childContextTypes,r!=null&&Ru();break;case 3:Mo(),Pe(Pt),Pe(ft),Cg();break;case 5:Eg(r);break;case 4:Mo();break;case 13:Pe(De);break;case 19:Pe(De);break;case 10:bg(r.type._context);break;case 22:case 23:Lg()}n=n.return}if(Xe=e,He=e=gs(e.current,null),rt=Ft=t,Qe=0,ml=null,Mg=Od=pi=0,Et=Va=null,Gs!==null){for(t=0;t<Gs.length;t++)if(n=Gs[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}Gs=null}return e}function J_(e,t){do{var n=He;try{if(xg(),tu.current=Vu,Bu){for(var r=Ie.memoizedState;r!==null;){var s=r.queue;s!==null&&(s.pending=null),r=r.next}Bu=!1}if(hi=0,Je=Ge=Ie=null,$a=!1,fl=0,Og.current=null,n===null||n.return===null){Qe=1,ml=t,He=null;break}e:{var i=e,o=n.return,a=n,l=t;if(t=rt,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 p=i0(o);if(p!==null){p.flags&=-257,o0(p,o,a,i,t),p.mode&1&&s0(i,c,t),t=p,l=c;var b=t.updateQueue;if(b===null){var g=new Set;g.add(l),t.updateQueue=g}else b.add(l);break e}else{if(!(t&1)){s0(i,c,t),Fg();break e}l=Error(M(426))}}else if(Re&&a.mode&1){var x=i0(o);if(x!==null){!(x.flags&65536)&&(x.flags|=256),o0(x,o,a,i,t),yg(Do(l,a));break e}}i=l=Do(l,a),Qe!==4&&(Qe=2),Va===null?Va=[i]:Va.push(i),i=o;do{switch(i.tag){case 3:i.flags|=65536,t&=-t,i.lanes|=t;var y=D_(i,l,t);Jy(i,y);break e;case 1:a=l;var m=i.type,v=i.stateNode;if(!(i.flags&128)&&(typeof m.getDerivedStateFromError=="function"||v!==null&&typeof v.componentDidCatch=="function"&&(ps===null||!ps.has(v)))){i.flags|=65536,t&=-t,i.lanes|=t;var _=I_(i,a,t);Jy(i,_);break e}}i=i.return}while(i!==null)}tS(n)}catch(S){t=S,He===n&&n!==null&&(He=n=n.return);continue}break}while(!0)}function X_(){var e=Uu.current;return Uu.current=Vu,e===null?Vu:e}function Fg(){(Qe===0||Qe===3||Qe===2)&&(Qe=4),Xe===null||!(pi&268435455)&&!(Od&268435455)||Zr(Xe,rt)}function Hu(e,t){var n=de;de|=2;var r=X_();(Xe!==e||rt!==t)&&(yr=null,ai(e,t));do try{Dj();break}catch(s){J_(e,s)}while(!0);if(xg(),de=n,Uu.current=r,He!==null)throw Error(M(261));return Xe=null,rt=0,Qe}function Dj(){for(;He!==null;)eS(He)}function Ij(){for(;He!==null&&!aP();)eS(He)}function eS(e){var t=rS(e.alternate,e,Ft);e.memoizedProps=e.pendingProps,t===null?tS(e):He=t,Og.current=null}function tS(e){var t=e;do{var n=t.alternate;if(e=t.return,t.flags&32768){if(n=Pj(n,t),n!==null){n.flags&=32767,He=n;return}if(e!==null)e.flags|=32768,e.subtreeFlags=0,e.deletions=null;else{Qe=6,He=null;return}}else if(n=Aj(n,t,Ft),n!==null){He=n;return}if(t=t.sibling,t!==null){He=t;return}He=t=e}while(t!==null);Qe===0&&(Qe=5)}function Us(e,t,n){var r=ye,s=on.transition;try{on.transition=null,ye=1,Lj(e,t,n,r)}finally{on.transition=s,ye=r}return null}function Lj(e,t,n,r){do mo();while(is!==null);if(de&6)throw Error(M(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(M(177));e.callbackNode=null,e.callbackPriority=0;var i=n.lanes|n.childLanes;if(vP(e,i),e===Xe&&(He=Xe=null,rt=0),!(n.subtreeFlags&2064)&&!(n.flags&2064)||Ec||(Ec=!0,sS(Cu,function(){return mo(),null})),i=(n.flags&15990)!==0,n.subtreeFlags&15990||i){i=on.transition,on.transition=null;var o=ye;ye=1;var a=de;de|=4,Og.current=null,Nj(e,n),G_(n,e),rj(pp),Au=!!hp,pp=hp=null,e.current=n,Rj(n),lP(),de=a,ye=o,on.transition=i}else e.current=n;if(Ec&&(Ec=!1,is=e,Wu=s),i=e.pendingLanes,i===0&&(ps=null),dP(n.stateNode),Nt(e,Ve()),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(zu)throw zu=!1,e=Mp,Mp=null,e;return Wu&1&&e.tag!==0&&mo(),i=e.pendingLanes,i&1?e===Dp?Ua++:(Ua=0,Dp=e):Ua=0,js(),null}function mo(){if(is!==null){var e=D1(Wu),t=on.transition,n=ye;try{if(on.transition=null,ye=16>e?16:e,is===null)var r=!1;else{if(e=is,is=null,Wu=0,de&6)throw Error(M(331));var s=de;for(de|=4,H=e.current;H!==null;){var i=H,o=i.child;if(H.flags&16){var a=i.deletions;if(a!==null){for(var l=0;l<a.length;l++){var c=a[l];for(H=c;H!==null;){var u=H;switch(u.tag){case 0:case 11:case 15:Ba(8,u,i)}var d=u.child;if(d!==null)d.return=u,H=d;else for(;H!==null;){u=H;var h=u.sibling,p=u.return;if(K_(u),u===c){H=null;break}if(h!==null){h.return=p,H=h;break}H=p}}}var b=i.alternate;if(b!==null){var g=b.child;if(g!==null){b.child=null;do{var x=g.sibling;g.sibling=null,g=x}while(g!==null)}}H=i}}if(i.subtreeFlags&2064&&o!==null)o.return=i,H=o;else e:for(;H!==null;){if(i=H,i.flags&2048)switch(i.tag){case 0:case 11:case 15:Ba(9,i,i.return)}var y=i.sibling;if(y!==null){y.return=i.return,H=y;break e}H=i.return}}var m=e.current;for(H=m;H!==null;){o=H;var v=o.child;if(o.subtreeFlags&2064&&v!==null)v.return=o,H=v;else e:for(o=m;H!==null;){if(a=H,a.flags&2048)try{switch(a.tag){case 0:case 11:case 15:Rd(9,a)}}catch(S){Be(a,a.return,S)}if(a===o){H=null;break e}var _=a.sibling;if(_!==null){_.return=a.return,H=_;break e}H=a.return}}if(de=s,js(),tr&&typeof tr.onPostCommitFiberRoot=="function")try{tr.onPostCommitFiberRoot(kd,e)}catch{}r=!0}return r}finally{ye=n,on.transition=t}}return!1}function w0(e,t,n){t=Do(n,t),t=D_(e,t,1),e=hs(e,t,1),t=xt(),e!==null&&(Fl(e,1,t),Nt(e,t))}function Be(e,t,n){if(e.tag===3)w0(e,e,n);else for(;t!==null;){if(t.tag===3){w0(t,e,n);break}else if(t.tag===1){var r=t.stateNode;if(typeof t.type.getDerivedStateFromError=="function"||typeof r.componentDidCatch=="function"&&(ps===null||!ps.has(r))){e=Do(n,e),e=I_(t,e,1),t=hs(t,e,1),e=xt(),t!==null&&(Fl(t,1,e),Nt(t,e));break}}t=t.return}}function Fj(e,t,n){var r=e.pingCache;r!==null&&r.delete(t),t=xt(),e.pingedLanes|=e.suspendedLanes&n,Xe===e&&(rt&n)===n&&(Qe===4||Qe===3&&(rt&130023424)===rt&&500>Ve()-Dg?ai(e,0):Mg|=n),Nt(e,t)}function nS(e,t){t===0&&(e.mode&1?(t=mc,mc<<=1,!(mc&130023424)&&(mc=4194304)):t=1);var n=xt();e=Tr(e,t),e!==null&&(Fl(e,t,n),Nt(e,n))}function $j(e){var t=e.memoizedState,n=0;t!==null&&(n=t.retryLane),nS(e,n)}function Bj(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(M(314))}r!==null&&r.delete(t),nS(e,n)}var rS;rS=function(e,t,n){if(e!==null)if(e.memoizedProps!==t.pendingProps||Pt.current)Tt=!0;else{if(!(e.lanes&n)&&!(t.flags&128))return Tt=!1,Tj(e,t,n);Tt=!!(e.flags&131072)}else Tt=!1,Re&&t.flags&1048576&&a_(t,Du,t.index);switch(t.lanes=0,t.tag){case 2:var r=t.type;ru(e,t),e=t.pendingProps;var s=No(t,ft.current);po(t,n),s=Ag(null,t,r,e,s,n);var i=Pg();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,jt(r)?(i=!0,Ou(t)):i=!1,t.memoizedState=s.state!==null&&s.state!==void 0?s.state:null,Sg(t),s.updater=Nd,t.stateNode=s,s._reactInternals=t,Sp(t,r,e,n),t=Cp(null,t,r,!0,i,n)):(t.tag=0,Re&&i&&gg(t),pt(null,t,s,n),t=t.child),t;case 16:r=t.elementType;e:{switch(ru(e,t),e=t.pendingProps,s=r._init,r=s(r._payload),t.type=r,s=t.tag=Uj(r),e=xn(r,e),s){case 0:t=Ep(null,t,r,e,n);break e;case 1:t=c0(null,t,r,e,n);break e;case 11:t=a0(null,t,r,e,n);break e;case 14:t=l0(null,t,r,xn(r.type,e),n);break e}throw Error(M(306,r,""))}return t;case 0:return r=t.type,s=t.pendingProps,s=t.elementType===r?s:xn(r,s),Ep(e,t,r,s,n);case 1:return r=t.type,s=t.pendingProps,s=t.elementType===r?s:xn(r,s),c0(e,t,r,s,n);case 3:e:{if(B_(t),e===null)throw Error(M(387));
vendor: 4,912 bytes, line 40
40r=t.pendingProps,i=t.memoizedState,s=i.element,h_(e,t),Fu(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=Do(Error(M(423)),t),t=u0(e,t,r,n,s);break e}else if(r!==s){s=Do(Error(M(424)),t),t=u0(e,t,r,n,s);break e}else for(Bt=fs(t.stateNode.containerInfo.firstChild),Vt=t,Re=!0,Cn=null,n=d_(t,null,r,n),t.child=n;n;)n.flags=n.flags&-3|4096,n=n.sibling;else{if(Ro(),r===s){t=Ar(e,t,n);break e}pt(e,t,r,n)}t=t.child}return t;case 5:return p_(t),e===null&&xp(t),r=t.type,s=t.pendingProps,i=e!==null?e.memoizedProps:null,o=s.children,mp(r,s)?o=null:i!==null&&mp(r,i)&&(t.flags|=32),$_(e,t),pt(e,t,o,n),t.child;case 6:return e===null&&xp(t),null;case 13:return V_(e,t,n);case 4:return kg(t,t.stateNode.containerInfo),r=t.pendingProps,e===null?t.child=Oo(t,null,r,n):pt(e,t,r,n),t.child;case 11:return r=t.type,s=t.pendingProps,s=t.elementType===r?s:xn(r,s),a0(e,t,r,s,n);case 7:return pt(e,t,t.pendingProps,n),t.child;case 8:return pt(e,t,t.pendingProps.children,n),t.child;case 12:return pt(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,Se(Iu,r._currentValue),r._currentValue=o,i!==null)if(Rn(i.value,o)){if(i.children===s.children&&!Pt.current){t=Ar(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=kr(-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),bp(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(M(341));o.lanes|=n,a=o.alternate,a!==null&&(a.lanes|=n),bp(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}pt(e,t,s.children,n),t=t.child}return t;case 9:return s=t.type,r=t.pendingProps.children,po(t,n),s=ln(s),r=r(s),t.flags|=1,pt(e,t,r,n),t.child;case 14:return r=t.type,s=xn(r,t.pendingProps),s=xn(r.type,s),l0(e,t,r,s,n);case 15:return L_(e,t,t.type,t.pendingProps,n);case 17:return r=t.type,s=t.pendingProps,s=t.elementType===r?s:xn(r,s),ru(e,t),t.tag=1,jt(r)?(e=!0,Ou(t)):e=!1,po(t,n),M_(t,r,s),Sp(t,r,s,n),Cp(null,t,r,!0,e,n);case 19:return U_(e,t,n);case 22:return F_(e,t,n)}throw Error(M(156,t.tag))};function sS(e,t){return N1(e,t)}function Vj(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 rn(e,t,n,r){return new Vj(e,t,n,r)}function $g(e){return e=e.prototype,!(!e||!e.isReactComponent)}function Uj(e){if(typeof e=="function")return $g(e)?1:0;if(e!=null){if(e=e.$$typeof,e===sg)return 11;if(e===ig)return 14}return 2}function gs(e,t){var n=e.alternate;return n===null?(n=rn(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 ou(e,t,n,r,s,i){var o=2;if(r=e,typeof e=="function")$g(e)&&(o=1);else if(typeof e=="string")o=5;else e:switch(e){case Gi:return li(n.children,s,i,t);case rg:o=8,s|=8;break;case qh:return e=rn(12,n,t,s|2),e.elementType=qh,e.lanes=i,e;case Yh:return e=rn(13,n,t,s),e.elementType=Yh,e.lanes=i,e;case Gh:return e=rn(19,n,t,s),e.elementType=Gh,e.lanes=i,e;case p1:return Md(n,s,i,t);default:if(typeof e=="object"&&e!==null)switch(e.$$typeof){case f1:o=10;break e;case h1:o=9;break e;case sg:o=11;break e;case ig:o=14;break e;case qr:o=16,r=null;break e}throw Error(M(130,e==null?e:typeof e,""))}return t=rn(o,n,t,s),t.elementType=e,t.type=r,t.lanes=i,t}function li(e,t,n,r){return e=rn(7,e,r,t),e.lanes=n,e}function Md(e,t,n,r){return e=rn(22,e,r,t),e.elementType=p1,e.lanes=n,e.stateNode={isHidden:!1},e}function zf(e,t,n){return e=rn(6,e,null,t),e.lanes=n,e}function Wf(e,t,n){return t=rn(4,e.children!==null?e.children:[],e.key,t),t.lanes=n,t.stateNode={containerInfo:e.containerInfo,pendingChildren:null,implementation:e.implementation},t}
vendor: 5,453 bytes, line 40
40function zj(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=kf(0),this.expirationTimes=kf(-1),this.entangledLanes=this.finishedLanes=this.mutableReadLanes=this.expiredLanes=this.pingedLanes=this.suspendedLanes=this.pendingLanes=0,this.entanglements=kf(0),this.identifierPrefix=r,this.onRecoverableError=s,this.mutableSourceEagerHydrationData=null}function Bg(e,t,n,r,s,i,o,a,l){return e=new zj(e,t,n,a,l),t===1?(t=1,i===!0&&(t|=8)):t=0,i=rn(3,null,null,t),e.current=i,i.stateNode=e,i.memoizedState={element:r,isDehydrated:n,cache:null,transitions:null,pendingSuspenseBoundaries:null},Sg(i),e}function Wj(e,t,n){var r=3<arguments.length&&arguments[3]!==void 0?arguments[3]:null;return{$$typeof:Yi,key:r==null?null:""+r,children:e,containerInfo:t,implementation:n}}function iS(e){if(!e)return xs;e=e._reactInternals;e:{if(_i(e)!==e||e.tag!==1)throw Error(M(170));var t=e;do{switch(t.tag){case 3:t=t.stateNode.context;break e;case 1:if(jt(t.type)){t=t.stateNode.__reactInternalMemoizedMergedChildContext;break e}}t=t.return}while(t!==null);throw Error(M(171))}if(e.tag===1){var n=e.type;if(jt(n))return i_(e,n,t)}return t}function oS(e,t,n,r,s,i,o,a,l){return e=Bg(n,r,!0,e,s,i,o,a,l),e.context=iS(null),n=e.current,r=xt(),s=ms(n),i=kr(r,s),i.callback=t??null,hs(n,i,s),e.current.lanes=s,Fl(e,s,r),Nt(e,r),e}function Dd(e,t,n,r){var s=t.current,i=xt(),o=ms(s);return n=iS(n),t.context===null?t.context=n:t.pendingContext=n,t=kr(i,o),t.payload={element:e},r=r===void 0?null:r,r!==null&&(t.callback=r),e=hs(s,t,o),e!==null&&(jn(e,s,o,i),eu(e,s,o)),o}function Ku(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 x0(e,t){if(e=e.memoizedState,e!==null&&e.dehydrated!==null){var n=e.retryLane;e.retryLane=n!==0&&n<t?n:t}}function Vg(e,t){x0(e,t),(e=e.alternate)&&x0(e,t)}function Hj(){return null}var aS=typeof reportError=="function"?reportError:function(e){console.error(e)};function Ug(e){this._internalRoot=e}Id.prototype.render=Ug.prototype.render=function(e){var t=this._internalRoot;if(t===null)throw Error(M(409));Dd(e,t,null,null)};Id.prototype.unmount=Ug.prototype.unmount=function(){var e=this._internalRoot;if(e!==null){this._internalRoot=null;var t=e.containerInfo;mi(function(){Dd(null,e,null,null)}),t[Cr]=null}};function Id(e){this._internalRoot=e}Id.prototype.unstable_scheduleHydration=function(e){if(e){var t=F1();e={blockedOn:null,target:e,priority:t};for(var n=0;n<Qr.length&&t!==0&&t<Qr[n].priority;n++);Qr.splice(n,0,e),n===0&&B1(e)}};function zg(e){return!(!e||e.nodeType!==1&&e.nodeType!==9&&e.nodeType!==11)}function Ld(e){return!(!e||e.nodeType!==1&&e.nodeType!==9&&e.nodeType!==11&&(e.nodeType!==8||e.nodeValue!==" react-mount-point-unstable "))}function b0(){}function Kj(e,t,n,r,s){if(s){if(typeof r=="function"){var i=r;r=function(){var c=Ku(o);i.call(c)}}var o=oS(t,r,e,0,null,!1,!1,"",b0);return e._reactRootContainer=o,e[Cr]=o.current,al(e.nodeType===8?e.parentNode:e),mi(),o}for(;s=e.lastChild;)e.removeChild(s);if(typeof r=="function"){var a=r;r=function(){var c=Ku(l);a.call(c)}}var l=Bg(e,0,!1,null,null,!1,!1,"",b0);return e._reactRootContainer=l,e[Cr]=l.current,al(e.nodeType===8?e.parentNode:e),mi(function(){Dd(t,l,n,r)}),l}function Fd(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=Ku(o);a.call(l)}}Dd(t,o,e,s)}else o=Kj(n,t,e,s,r);return Ku(o)}I1=function(e){switch(e.tag){case 3:var t=e.stateNode;if(t.current.memoizedState.isDehydrated){var n=Aa(t.pendingLanes);n!==0&&(lg(t,n|1),Nt(t,Ve()),!(de&6)&&(Io=Ve()+500,js()))}break;case 13:mi(function(){var r=Tr(e,1);if(r!==null){var s=xt();jn(r,e,1,s)}}),Vg(e,1)}};cg=function(e){if(e.tag===13){var t=Tr(e,134217728);if(t!==null){var n=xt();jn(t,e,134217728,n)}Vg(e,134217728)}};L1=function(e){if(e.tag===13){var t=ms(e),n=Tr(e,t);if(n!==null){var r=xt();jn(n,e,t,r)}Vg(e,t)}};F1=function(){return ye};$1=function(e,t){var n=ye;try{return ye=e,t()}finally{ye=n}};ip=function(e,t,n){switch(t){case"input":if(Jh(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=Ad(r);if(!s)throw Error(M(90));g1(r),Jh(r,s)}}}break;case"textarea":y1(e,n);break;case"select":t=n.value,t!=null&&co(e,!!n.multiple,t,!1)}};E1=Ig;C1=mi;var qj={usingClientEntryPoint:!1,Events:[Bl,Xi,Ad,S1,k1,Ig]},ga={findFiberByHostInstance:Ys,bundleType:0,version:"18.3.1",rendererPackageName:"react-dom"},Yj={bundleType:ga.bundleType,version:ga.version,rendererPackageName:ga.rendererPackageName,rendererConfig:ga.rendererConfig,overrideHookState:null,overrideHookStateDeletePath:null,overrideHookStateRenamePath:null,overrideProps:null,overridePropsDeletePath:null,overridePropsRenamePath:null,setErrorHandler:null,setSuspenseHandler:null,scheduleUpdate:null,currentDispatcherRef:Rr.ReactCurrentDispatcher,findHostInstanceByFiber:function(e){return e=P1(e),e===null?null:e.stateNode},findFiberByHostInstance:ga.findFiberByHostInstance||Hj,findHostInstancesForRefresh:null,scheduleRefresh:null,scheduleRoot:null,setRefreshHandler:null,getCurrentFiber:null,reconcilerVersion:"18.3.1-next-f1338f8080-20240426"};
40if(typeof __REACT_DEVTOOLS_GLOBAL_HOOK__<"u"){var Cc=__REACT_DEVTOOLS_GLOBAL_HOOK__;if(!Cc.isDisabled&&Cc.supportsFiber)try{kd=Cc.inject(Yj),tr=Cc}catch{}}Kt.__SECRET_INTERNALS_DO_NOT_USE_OR_YOU_WILL_BE_FIRED=qj;Kt.createPortal=function(e,t){var n=2<arguments.length&&arguments[2]!==void 0?arguments[2]:null;if(!zg(t))throw Error(M(200));return Wj(e,t,null,n)};Kt.createRoot=function(e,t){if(!zg(e))throw Error(M(299));var n=!1,r="",s=aS;return t!=null&&(t.unstable_strictMode===!0&&(n=!0),t.identifierPrefix!==void 0&&(r=t.identifierPrefix),t.onRecoverableError!==void 0&&(s=t.onRecoverableError)),t=Bg(e,1,!1,null,null,n,!1,r,s),e[Cr]=t.current,al(e.nodeType===8?e.parentNode:e),new Ug(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(M(188)):(e=Object.keys(e).join(","),Error(M(268,e)));return e=P1(t),e=e===null?null:e.stateNode,e};Kt.flushSync=function(e){return mi(e)};Kt.hydrate=function(e,t,n){if(!Ld(t))throw Error(M(200));return Fd(null,e,t,!0,n)};Kt.hydrateRoot=function(e,t,n){if(!zg(e))throw Error(M(405));var r=n!=null&&n.hydratedSources||null,s=!1,i="",o=aS;if(n!=null&&(n.unstable_strictMode===!0&&(s=!0),n.identifierPrefix!==void 0&&(i=n.identifierPrefix),n.onRecoverableError!==void 0&&(o=n.onRecoverableError)),t=oS(t,null,e,1,n??null,s,!1,i,o),e[Cr]=t.current,al(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 Id(t)};Kt.render=function(e,t,n){if(!Ld(t))throw Error(M(200));return Fd(null,e,t,!1,n)};Kt.unmountComponentAtNode=function(e){if(!Ld(e))throw Error(M(40));return e._reactRootContainer?(mi(function(){Fd(null,null,e,!1,function(){e._reactRootContainer=null,e[Cr]=null})}),!0):!1};Kt.unstable_batchedUpdates=Ig;Kt.unstable_renderSubtreeIntoContainer=function(e,t,n,r){if(!Ld(n))throw Error(M(200));if(e==null||e._reactInternals===void 0)throw Error(M(38));return Fd(e,t,n,!1,r)};Kt.version="18.3.1-next-f1338f8080-20240426";function lS(){if(!(typeof __REACT_DEVTOOLS_GLOBAL_HOOK__>"u"||typeof __REACT_DEVTOOLS_GLOBAL_HOOK__.checkDCE!="function"))try{__REACT_DEVTOOLS_GLOBAL_HOOK__.checkDCE(lS)}catch(e){console.error(e)}}lS(),l1.exports=Kt;var Si=l1.exports;const cS=Il(Si);var uS,_0=Si;uS=_0.createRoot,_0.hydrateRoot;/**
41 * @remix-run/router v1.23.0
42 *
43 * Copyright (c) Remix Software Inc.
44 *
45 * This source code is licensed under the MIT license found in the
46 * LICENSE.md file in the root directory of this source tree.
47 *
48 * @license MIT
49 */function gl(){return gl=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},gl.apply(this,arguments)}var os;(function(e){e.Pop="POP",e.Push="PUSH",e.Replace="REPLACE"})(os||(os={}));const S0="popstate";function Gj(e){e===void 0&&(e={});function t(r,s){let{pathname:i,search:o,hash:a}=r.location;return Fp("",{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:qu(s)}return Zj(t,n,null,e)}function Ke(e,t){if(e===!1||e===null||typeof e>"u")throw new Error(t)}function dS(e,t){if(!e){typeof console<"u"&&console.warn(t);try{throw new Error(t)}catch{}}}function Qj(){return Math.random().toString(36).substr(2,8)}function k0(e,t){return{usr:e.state,key:e.key,idx:t}}function Fp(e,t,n,r){return n===void 0&&(n=null),gl({pathname:typeof e=="string"?e:e.pathname,search:"",hash:""},typeof t=="string"?Jo(t):t,{state:n,key:t&&t.key||r||Qj()})}function qu(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 Jo(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 Zj(e,t,n,r){r===void 0&&(r={});let{window:s=document.defaultView,v5Compat:i=!1}=r,o=s.history,a=os.Pop,l=null,c=u();c==null&&(c=0,o.replaceState(gl({},o.state,{idx:c}),""));function u(){return(o.state||{idx:null}).idx}function d(){a=os.Pop;let x=u(),y=x==null?null:x-c;c=x,l&&l({action:a,location:g.location,delta:y})}function h(x,y){a=os.Push;let m=Fp(g.location,x,y);c=u()+1;let v=k0(m,c),_=g.createHref(m);try{o.pushState(v,"",_)}catch(S){if(S instanceof DOMException&&S.name==="DataCloneError")throw S;s.location.assign(_)}i&&l&&l({action:a,location:g.location,delta:1})}function p(x,y){a=os.Replace;let m=Fp(g.location,x,y);c=u();let v=k0(m,c),_=g.createHref(m);o.replaceState(v,"",_),i&&l&&l({action:a,location:g.location,delta:0})}function b(x){let y=s.location.origin!=="null"?s.location.origin:s.location.href,m=typeof x=="str
49ing"?x:qu(x);return m=m.replace(/ $/,"%20"),Ke(y,"No window.location.(origin|href) available to create URL for href: "+m),new URL(m,y)}let g={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(S0,d),l=x,()=>{s.removeEventListener(S0,d),l=null}},createHref(x){return t(s,x)},createURL:b,encodeLocation(x){let y=b(x);return{pathname:y.pathname,search:y.search,hash:y.hash}},push:h,replace:p,go(x){return o.go(x)}};return g}var E0;(function(e){e.data="data",e.deferred="deferred",e.redirect="redirect",e.error="error"})(E0||(E0={}));function Jj(e,t,n){return n===void 0&&(n="/"),Xj(e,t,n,!1)}function Xj(e,t,n,r){let s=typeof t=="string"?Jo(t):t,i=Wg(s.pathname||"/",n);if(i==null)return null;let o=fS(e);eN(o);let a=null;for(let l=0;a==null&&l<o.length;++l){let c=dN(i);a=cN(o[l],c,r)}return a}function fS(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("/")&&(Ke(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=vs([r,l.relativePath]),u=n.concat(l);i.children&&i.children.length>0&&(Ke(i.index!==!0,"Index routes must not have child routes. Please remove "+('all child routes from route path "'+c+'".')),fS(i.children,t,u,c)),!(i.path==null&&!i.index)&&t.push({path:c,score:aN(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 hS(i.path))s(i,o,l)}),t}function hS(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=hS(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 eN(e){e.sort((t,n)=>t.score!==n.score?n.score-t.score:lN(t.routesMeta.map(r=>r.childrenIndex),n.routesMeta.map(r=>r.childrenIndex)))}const tN=/^:[\w-]+$/,nN=3,rN=2,sN=1,iN=10,oN=-2,C0=e=>e==="*";function aN(e,t){let n=e.split("/"),r=n.length;return n.some(C0)&&(r+=oN),t&&(r+=rN),n.filter(s=>!C0(s)).reduce((s,i)=>s+(tN.test(i)?nN:i===""?sN:iN),r)}function lN(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 cN(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=T0({path:l.relativePath,caseSensitive:l.caseSensitive,end:c},u),h=l.route;if(!d&&c&&n&&!r[r.length-1].route.index&&(d=T0({path:l.relativePath,caseSensitive:l.caseSensitive,end:!1},u)),!d)return null;
vendor: 13,539 bytes, lines 49-67
49Object.assign(s,d.params),o.push({params:s,pathname:vs([i,d.pathname]),pathnameBase:mN(vs([i,d.pathnameBase])),route:h}),d.pathnameBase!=="/"&&(i=vs([i,d.pathnameBase]))}return o}function T0(e,t){typeof e=="string"&&(e={path:e,caseSensitive:!1,end:!0});let[n,r]=uN(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:p}=u;if(h==="*"){let g=a[d]||"";o=i.slice(0,i.length-g.length).replace(/(.)\/+$/,"$1")}const b=a[d];return p&&!b?c[h]=void 0:c[h]=(b||"").replace(/%2F/g,"/"),c},{}),pathname:i,pathnameBase:o,pattern:e}}function uN(e,t,n){t===void 0&&(t=!1),n===void 0&&(n=!0),dS(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 dN(e){try{return e.split("/").map(t=>decodeURIComponent(t).replace(/\//g,"%2F")).join("/")}catch(t){return dS(!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 Wg(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 fN(e,t){t===void 0&&(t="/");let{pathname:n,search:r="",hash:s=""}=typeof e=="string"?Jo(e):e;return{pathname:n?n.startsWith("/")?n:hN(n,t):t,search:gN(r),hash:vN(s)}}function hN(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 Hf(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 pN(e){return e.filter((t,n)=>n===0||t.route.path&&t.route.path.length>0)}function pS(e,t){let n=pN(e);return t?n.map((r,s)=>s===n.length-1?r.pathname:r.pathnameBase):n.map(r=>r.pathnameBase)}function mS(e,t,n,r){r===void 0&&(r=!1);let s;typeof e=="string"?s=Jo(e):(s=gl({},e),Ke(!s.pathname||!s.pathname.includes("?"),Hf("?","pathname","search",s)),Ke(!s.pathname||!s.pathname.includes("#"),Hf("#","pathname","hash",s)),Ke(!s.search||!s.search.includes("#"),Hf("#","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=fN(s,a),c=o&&o!=="/"&&o.endsWith("/"),u=(i||o===".")&&n.endsWith("/");return!l.pathname.endsWith("/")&&(c||u)&&(l.pathname+="/"),l}const vs=e=>e.join("/").replace(/\/\/+/g,"/"),mN=e=>e.replace(/\/+$/,"").replace(/^\/*/,"/"),gN=e=>!e||e==="?"?"":e.startsWith("?")?e:"?"+e,vN=e=>!e||e==="#"?"":e.startsWith("#")?e:"#"+e;function yN(e){return e!=null&&typeof e.status=="number"&&typeof e.statusText=="string"&&typeof e.internal=="boolean"&&"data"in e}const gS=["post","put","patch","delete"];new Set(gS);const wN=["get",...gS];new Set(wN);/**
50 * React Router v6.30.1
51 *
52 * Copyright (c) Remix Software Inc.
53 *
54 * This source code is licensed under the MIT license found in the
55 * LICENSE.md file in the root directory of this source tree.
56 *
57 * @license MIT
58 */function vl(){return vl=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},vl.apply(this,arguments)}const Hg=w.createContext(null),xN=w.createContext(null),ki=w.createContext(null),$d=w.createContext(null),Ns=w.createContext({outlet:null,matches:[],isDataRoute:!1}),vS=w.createContext(null);function bN(e,t){let{relative:n}=t===void 0?{}:t;Ul()||Ke(!1);let{basename:r,navigator:s}=w.useContext(ki),{hash:i,pathname:o,search:a}=xS(e,{relative:n}),l=o;return r!=="/"&&(l=o==="/"?r:vs([r,o])),s.createHref({pathname:l,search:a,hash:i})}function Ul(){return w.useContext($d)!=null}function zl(){return Ul()||Ke(!1),w.useContext($d).location}function yS(e){w.useContext(ki).static||w.useLayoutEffect(e)}function Fn(){let{isDataRoute:e}=w.useContext(Ns);return e?MN():_N()}function _N(){Ul()||Ke(!1);let e=w.useContext(Hg),{basename:t,future:n,navigator:r}=w.useContext(ki),{matches:s}=w.useContext(Ns),{pathname:i}=zl(),o=JSON.stringify(pS(s,n.v7_relativeSplatPath)),a=w.useRef(!1);return yS(()=>{a.current=!0}),w.useCallback(function(c,u){if(u===void 0&&(u={}),!a.current)return;if(typeof c=="number"){r.go(c);return}let d=mS(c,JSON.parse(o),i,u.relative==="path");e==null&&t!=="/"&&(d.pathname=d.pathname==="/"?t:vs([t,d.pathname])),(u.replace?r.replace:r.push)(d,u.state,u)},[t,r,o,i,e])}function wS(){let{matches:e}=w.useContext(Ns),t=e[e.length-1];return t?t.params:{}}function xS(e,t){let{relative:n}=t===void 0?{}:t,{future:r}=w.useContext(ki),{matches:s}=w.useContext(Ns),{pathname:i}=zl(),o=JSON.stringify(pS(s,r.v7_relativeSplatPath));return w.useMemo(()=>mS(e,JSON.parse(o),i,n==="path"),[e,o,i,n])}function SN(e,t){return kN(e,t)}function kN(e,t,n,r){Ul()||Ke(!1);let{navigator:s}=w.useContext(ki),{matches:i}=w.useContext(Ns),o=i[i.length-1],a=o?o.params:{};o&&o.pathname;let l=o?o.pathnameBase:"/";o&&o.route;let c=zl(),u;if(t){var d;let x=typeof t=="string"?Jo(t):t;l==="/"||(d=x.pathname)!=null&&d.startsWith(l)||Ke(!1),u=x}else u=c;let h=u.pathname||"/",p=h;if(l!=="/"){let x=l.replace(/^\//,"").split("/");p="/"+h.replace(/^\//,"").split("/").slice(x.length).join("/")}let b=Jj(e,{pathname:p}),g=PN(b&&b.map(x=>Object.assign({},x,{params:Object.assign({},a,x.params),pathname:vs([l,s.encodeLocation?s.encodeLocation(x.pathname).pathname:x.pathname]),pathnameBase:x.pathnameBase==="/"?l:vs([l,s.encodeLocation?s.encodeLocation(x.pathnameBase).pathname:x.pathnameBase])})),i,n,r);return t&&g?w.createElement($d.Provider,{value:{location:vl({pathname:"/",search:"",hash:"",state:null,key:"default"},u),navigationType:os.Pop}},g):g}function EN(){let e=ON(),t=yN(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 w.createElement(w.Fragment,null,w.createElement("h2",null,"Unexpected Application Error!"),w.createElement("h3",{style:{fontStyle:"italic"}},t),n?w.createElement("pre",{style:s},n):null,null)}const CN=w.createElement(EN,null);class TN extends w.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?w.createElement(Ns.Provider,{value:this.props.routeContext},w.createElement(vS.Provider,{value:this.state.error,children:this.props.component})):this.props.children}}function AN(e){let{routeContext:t,match:n,children:r}=e,s=w.useContext(Hg);return s&&s.static&&s.staticContext&&(n.route.errorElement||n.route.ErrorBoundary)&&(s.staticContext._deepestRenderedBoundaryId=n.route.id),w.createElement(Ns.Provider,{value:t},r)}function PN(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||Ke(!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:p}=n,b=d.route.loader&&h[d.route.id]===void 0&&(!p||p[d.route.id]===void 0);if(d.route.lazy||b){l=!0,c>=0?o=o.slice(0,c+1):o=[o[0]];break}}}return o.reduceRight((u,d,h)=>{let p,b=!1,g=null,x=null;n&&(p=a&&d.route.id?a[d.route.id]:void 0,g=d.route.errorElement||CN,l&&(c<0&&h===0?(b=!0,x=null):c===h&&(b=!0,x=d.route.hydrateFallbackElement||null)));let y=t.concat(o.slice(0,h+1)),m=()=>{let v;return p?v=g:b?v=x:d.route.Component?v=w.createElement(d.route.Component,null):d.route.element?v=d.route.element:v=u,w.createElement(AN,{match:d,routeContext:{outlet:u,matches:y,isDataRoute:n!=null},children:v})};return n&&(d.route.ErrorBoundary||d.route.errorElement||h===0)?w.createElement(TN,{location:n.location,revalidation:n.revalidation,component:g,error:p,children:m(),routeContext:{outlet:null,matches:y,isDataRoute:!0}}):m()},null)}var bS=function(e){return e.UseBlocker="useBlocker",e.UseRevalidator="useRevalidator",e.UseNavigateStable="useNavigate",e}(bS||{}),Yu=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}(Yu||{});function jN(e){let t=w.useContext(Hg);return t||Ke(!1),t}function NN(e){let t=w.useContext(xN);return t||Ke(!1),t}function RN(e){let t=w.useContext(Ns);return t||Ke(!1),t}function _S(e){let t=RN(),n=t.matches[t.matches.length-1];return n.route.id||Ke(!1),n.route.id}function ON(){var e;let t=w.useContext(vS),n=NN(Yu.UseRouteError),r=_S(Yu.UseRouteError);return t!==void 0?t:(e=n.errors)==null?void 0:e[r]}function MN(){let{router:e}=jN(bS.UseNavigateStable),t=_S(Yu.UseNavigateStable),n=w.useRef(!1);return yS(()=>{n.current=!0}),w.useCallback(function(s,i){i===void 0&&(i={}),n.current&&(typeof s=="number"?e.navigate(s):e.navigate(s,vl({fromRouteId:t},i)))},[e,t])}function DN(e,t){e==null||e.v7_startTransition,e==null||e.v7_relativeSplatPath}function Un(e){Ke(!1)}function IN(e){let{basename:t="/",children:n=null,location:r,navigationType:s=os.Pop,navigator:i,static:o=!1,future:a}=e;Ul()&&Ke(!1);let l=t.replace(/^\/*/,"/"),c=w.useMemo(()=>({basename:l,navigator:i,static:o,future:vl({v7_relativeSplatPath:!1},a)}),[l,a,i,o]);typeof r=="string"&&(r=Jo(r));let{pathname:u="/",search:d="",hash:h="",state:p=null,key:b="default"}=r,g=w.useMemo(()=>{let x=Wg(u,l);return x==null?null:{location:{pathname:x,search:d,hash:h,state:p,key:b},navigationType:s}},[l,u,d,h,p,b,s]);return g==null?null:w.createElement(ki.Provider,{value:c},w.createElement($d.Provider,{children:n,value:g}))}function LN(e){let{children:t,location:n}=e;return SN($p(t),n)}new Promise(()=>{});function $p(e,t){t===void 0&&(t=[]);let n=[];return w.Children.forEach(e,(r,s)=>{if(!w.isValidElement(r))return;let i=[...t,s];if(r.type===w.Fragment){n.push.apply(n,$p(r.props.children,i));return}r.type!==Un&&Ke(!1),!r.props.index||!r.props.children||Ke(!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=$p(r.props.children,i)),n.push(o)}),n}/**
59 * React Router DOM v6.30.1
60 *
61 * Copyright (c) Remix Software Inc.
62 *
63 * This source code is licensed under the MIT license found in the
64 * LICENSE.md file in the root directory of this source tree.
65 *
66 * @license MIT
67 */function Bp(){return Bp=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},Bp.apply(this,arguments)}function FN(e,t){if(e==null)return{};var n={},r=Object.keys(e),s,i;for(i=0;i<r.length;i++)s=r[i],!(t.indexOf(s)>=0)&&(n[s]=e[s]);return n}function $N(e){return!!(e.metaKey||e.altKey||e.ctrlKey||e.shiftKey)}function BN(e,t){return e.button===0&&(!t||t==="_self")&&!$N(e)}const VN=["onClick","relative","reloadDocument","replace","state","target","to","preventScrollReset","viewTransition"],UN="6";try{window.__reactRouterVersion=UN}catch{}const zN="startTransition",A0=Xm[zN];function WN(e){let{basename:t,children:n,future:r,window:s}=e,i=w.useRef();i.current==null&&(i.current=Gj({window:s,v5Compat:!0}));let o=i.current,[a,l]=w.useState({action:o.action,location:o.location}),{v7_startTransition:c}=r||{},u=w.useCallback(d=>{c&&A0?A0(()=>l(d)):l(d)},[l,c]);return w.useLayoutEffect(()=>o.listen(u),[o,u]),w.useEffect(()=>
67DN(r),[r]),w.createElement(IN,{basename:t,children:n,location:a.location,navigationType:a.action,navigator:o,future:r})}const HN=typeof window<"u"&&typeof window.document<"u"&&typeof window.document.createElement<"u",KN=/^(?:[a-z][a-z0-9+.-]*:|\/\/)/i,Tc=w.forwardRef(function(t,n){let{onClick:r,relative:s,reloadDocument:i,replace:o,state:a,target:l,to:c,preventScrollReset:u,viewTransition:d}=t,h=FN(t,VN),{basename:p}=w.useContext(ki),b,g=!1;if(typeof c=="string"&&KN.test(c)&&(b=c,HN))try{let v=new URL(window.location.href),_=c.startsWith("//")?new URL(v.protocol+c):new URL(c),S=Wg(_.pathname,p);_.origin===v.origin&&S!=null?c=S+_.search+_.hash:g=!0}catch{}let x=bN(c,{relative:s}),y=qN(c,{replace:o,state:a,target:l,preventScrollReset:u,relative:s,viewTransition:d});function m(v){r&&r(v),v.defaultPrevented||y(v)}return w.createElement("a",Bp({},h,{href:b||x,onClick:g||i?r:m,ref:n,target:l}))});var P0;(function(e){e.UseScrollRestoration="useScrollRestoration",e.UseSubmit="useSubmit",e.UseSubmitFetcher="useSubmitFetcher",e.UseFetcher="useFetcher",e.useViewTransitionState="useViewTransitionState"})(P0||(P0={}));var j0;(function(e){e.UseFetcher="useFetcher",e.UseFetchers="useFetchers",e.UseScrollRestoration="useScrollRestoration"})(j0||(j0={}));function qN(e,t){let{target:n,replace:r,state:s,preventScrollReset:i,relative:o,viewTransition:a}=t===void 0?{}:t,l=Fn(),c=zl(),u=xS(e,{relative:o});return w.useCallback(d=>{if(BN(d,n)){d.preventDefault();let h=r!==void 0?r:qu(c)===qu(u);l(e,{replace:h,state:s,preventScrollReset:i,relative:o,viewTransition:a})}},[c,l,u,r,s,n,e,i,o,a])}var Bd=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(){}},Vd=typeof window>"u"||"Deno"in globalThis;function bn(){}function YN(e,t){return typeof e=="function"?e(t):e}function GN(e){return typeof e=="number"&&e>=0&&e!==1/0}function QN(e,t){return Math.max(e+(t||0)-Date.now(),0)}function Vp(e,t){return typeof e=="function"?e(t):e}function ZN(e,t){return typeof e=="function"?e(t):e}function N0(e,t){const{type:n="all",exact:r,fetchStatus:s,predicate:i,queryKey:o,stale:a}=e;if(o){if(r){if(t.queryHash!==Kg(o,t.options))return!1}else if(!wl(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 R0(e,t){const{exact:n,status:r,predicate:s,mutationKey:i}=e;if(i){if(!t.options.mutationKey)return!1;if(n){if(yl(t.options.mutationKey)!==yl(i))return!1}else if(!wl(t.options.mutationKey,i))return!1}return!(r&&t.state.status!==r||s&&!s(t))}function Kg(e,t){return((t==null?void 0:t.queryKeyHashFn)||yl)(e)}function yl(e){return JSON.stringify(e,(t,n)=>Up(n)?Object.keys(n).sort().reduce((r,s)=>(r[s]=n[s],r),{}):n)}function wl(e,t){return e===t?!0:typeof e!=typeof t?!1:e&&t&&typeof e=="object"&&typeof t=="object"?Object.keys(t).every(n=>wl(e[n],t[n])):!1}function SS(e,t){if(e===t)return e;const n=O0(e)&&O0(t);if(n||Up(e)&&Up(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]=SS(e[d],t[d]),a[d]===e[d]&&e[d]!==void 0&&c++)}return s===o&&c===s?e:a}return t}function O0(e){return Array.isArray(e)&&e.length===Object.keys(e).length}function Up(e){if(!M0(e))return!1;const t=e.constructor;if(t===void 0)return!0;const n=t.prototype;return!(!M0(n)||!n.hasOwnProperty("isPrototypeOf")||Object.getPrototypeOf(e)!==Object.prototype)}function M0(e){return Object.prototype.toString.call(e)==="[object Object]"}function JN(e){return new Promise(t=>{setTimeout(t,e)})}function XN(e,t,n){return typeof n.structuralSharing=="function"?n.structuralSharing(e,t):n.structuralSharing!==!1?SS(e,t):t}function eR(e,t,n=0){const r=[...e,t];return n&&r.length>n?r.slice(1):r}function tR(e,t,n=0){const r=[t,...e];return n&&r.length>n?r.slice(0,-1):r}var qg=Symbol();function kS(e,t){return!e.queryFn&&(t!=null&&t.initialPromise)?()=>t.initialPromise:!e.queryFn||e.queryFn===qg?()=>Promise.reject(new Error(`Missing queryFn: '${e.queryHash}'`)):e.queryFn}var ei,Xr,_o,zb,nR=(zb=class extends Bd{constructor(){super();me(this,ei);me(this,Xr);me(this,_o);oe(this,_o,t=>{if(!Vd&&window.addEventListener){const n=()=>t();return window.addEventListener("visibilitychange",n,!1),()=>{window.removeEventListener("visibilitychange",n)}}})}onSubscribe(){N(this,Xr)||this.setEventListener(N(this,_o))}onUnsubscribe(){var t;this.hasListeners()||((t=N(this,Xr))==null||t.call(this),oe(this,Xr,void 0))}setEventListener(t){var n;
vendor: 5,143 bytes, line 67
67oe(this,_o,t),(n=N(this,Xr))==null||n.call(this),oe(this,Xr,t(r=>{typeof r=="boolean"?this.setFocused(r):this.onFocus()}))}setFocused(t){N(this,ei)!==t&&(oe(this,ei,t),this.onFocus())}onFocus(){const t=this.isFocused();this.listeners.forEach(n=>{n(t)})}isFocused(){var t;return typeof N(this,ei)=="boolean"?N(this,ei):((t=globalThis.document)==null?void 0:t.visibilityState)!=="hidden"}},ei=new WeakMap,Xr=new WeakMap,_o=new WeakMap,zb),ES=new nR,So,es,ko,Wb,rR=(Wb=class extends Bd{constructor(){super();me(this,So,!0);me(this,es);me(this,ko);oe(this,ko,t=>{if(!Vd&&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(){N(this,es)||this.setEventListener(N(this,ko))}onUnsubscribe(){var t;this.hasListeners()||((t=N(this,es))==null||t.call(this),oe(this,es,void 0))}setEventListener(t){var n;oe(this,ko,t),(n=N(this,es))==null||n.call(this),oe(this,es,t(this.setOnline.bind(this)))}setOnline(t){N(this,So)!==t&&(oe(this,So,t),this.listeners.forEach(r=>{r(t)}))}isOnline(){return N(this,So)}},So=new WeakMap,es=new WeakMap,ko=new WeakMap,Wb),Gu=new rR;function sR(){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 iR(e){return Math.min(1e3*2**e,3e4)}function CS(e){return(e??"online")==="online"?Gu.isOnline():!0}var TS=class extends Error{constructor(e){super("CancelledError"),this.revert=e==null?void 0:e.revert,this.silent=e==null?void 0:e.silent}};function Kf(e){return e instanceof TS}function AS(e){let t=!1,n=0,r=!1,s;const i=sR(),o=g=>{var x;r||(h(new TS(g)),(x=e.abort)==null||x.call(e))},a=()=>{t=!0},l=()=>{t=!1},c=()=>ES.isFocused()&&(e.networkMode==="always"||Gu.isOnline())&&e.canRun(),u=()=>CS(e.networkMode)&&e.canRun(),d=g=>{var x;r||(r=!0,(x=e.onSuccess)==null||x.call(e,g),s==null||s(),i.resolve(g))},h=g=>{var x;r||(r=!0,(x=e.onError)==null||x.call(e,g),s==null||s(),i.reject(g))},p=()=>new Promise(g=>{var x;s=y=>{(r||c())&&g(y)},(x=e.onPause)==null||x.call(e)}).then(()=>{var g;s=void 0,r||(g=e.onContinue)==null||g.call(e)}),b=()=>{if(r)return;let g;const x=n===0?e.initialPromise:void 0;try{g=x??e.fn()}catch(y){g=Promise.reject(y)}Promise.resolve(g).then(d).catch(y=>{var k;if(r)return;const m=e.retry??(Vd?0:3),v=e.retryDelay??iR,_=typeof v=="function"?v(n,y):v,S=m===!0||typeof m=="number"&&n<m||typeof m=="function"&&m(n,y);if(t||!S){h(y);return}n++,(k=e.onFail)==null||k.call(e,n,y),JN(_).then(()=>c()?void 0:p()).then(()=>{t?h(y):b()})})};return{promise:i,cancel:o,continue:()=>(s==null||s(),i),cancelRetry:a,continueRetry:l,canStart:u,start:()=>(u()?b():p().then(b),i)}}var oR=e=>setTimeout(e,0);function aR(){let e=[],t=0,n=a=>{a()},r=a=>{a()},s=oR;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 gt=aR(),ti,Hb,PS=(Hb=class{constructor(){me(this,ti)}destroy(){this.clearGcTimeout()}scheduleGc(){this.clearGcTimeout(),GN(this.gcTime)&&oe(this,ti,setTimeout(()=>{this.optionalRemove()},this.gcTime))}updateGcTime(e){this.gcTime=Math.max(this.gcTime||0,e??(Vd?1/0:5*60*1e3))}clearGcTimeout(){N(this,ti)&&(clearTimeout(N(this,ti)),oe(this,ti,void 0))}},ti=new WeakMap,Hb),Eo,ni,en,ri,ut,Ml,si,_n,vr,Kb,lR=(Kb=class extends PS{constructor(t){super();me(this,_n);me(this,Eo);me(this,ni);me(this,en);me(this,ri);me(this,ut);me(this,Ml);me(this,si);oe(this,si,!1),oe(this,Ml,t.defaultOptions),this.setOptions(t.options),this.observers=[],oe(this,ri,t.client),oe(this,en,N(this,ri).getQueryCache()),this.queryKey=t.queryKey,this.queryHash=t.queryHash,oe(this,Eo,uR(this.options)),this.state=t.state??N(this,Eo),this.scheduleGc()}get meta(){return this.options.meta}get promise(){var t;return(t=N(this,ut))==null?void 0:t.promise}setOptions(t){this.options={...N(this,Ml),...t},this.updateGcTime(this.options.gcTime)}optionalRemove(){!this.observers.length&&this.state.fetchStatus==="idle"&&N(this,en).remove(this)}setData(t,n){const r=XN(this.state.data,t,this.options);return at(this,_n,vr).call(this,{data:r,type:"success",dataUpdatedAt:n==null?void 0:n.updatedAt,manual:n==null?void 0:n.manual}),r}setState(t,n){at(this,_n,vr).call(this,{type:"setState",state:t,setStateOptions:n})}cancel(t){var r,s;const n=(r=N(this,ut))==null?void 0:r.promise;return(s=N(this,ut))==null||s.cancel(t),n?n.then(bn).catch(bn):Promise.resolve()}destroy(){super.destroy(),this.cancel({silent:!0})}reset(){this.destroy(),this.setState(N(this,Eo))}isActive(){return this.observers.some(t=>ZN(t.options.enabled,this)!==!1)}isDisabled(){return this.getObserversCount()>0?!this.isActive():this.options.queryFn===qg||this.state.dataUpdateCount+this.state.errorUpdate
vendor: 1,274 bytes, line 67
67Count===0}isStatic(){return this.getObserversCount()>0?this.observers.some(t=>Vp(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:!QN(this.state.dataUpdatedAt,t)}onFocus(){var n;const t=this.observers.find(r=>r.shouldFetchOnWindowFocus());t==null||t.refetch({cancelRefetch:!1}),(n=N(this,ut))==null||n.continue()}onOnline(){var n;const t=this.observers.find(r=>r.shouldFetchOnReconnect());t==null||t.refetch({cancelRefetch:!1}),(n=N(this,ut))==null||n.continue()}addObserver(t){this.observers.includes(t)||(this.observers.push(t),this.clearGcTimeout(),N(this,en).notify({type:"observerAdded",query:this,observer:t}))}removeObserver(t){this.observers.includes(t)&&(this.observers=this.observers.filter(n=>n!==t),this.observers.length||(N(this,ut)&&(N(this,si)?N(this,ut).cancel({revert:!0}):N(this,ut).cancelRetry()),this.scheduleGc()),N(this,en).notify({type:"observerRemoved",query:this,observer:t}))}getObserversCount(){return this.observers.length}invalidate(){this.state.isInvalidated||at(this,_n,vr).call(this,{type:"invalidate"})}
vendor: 6,533 bytes, line 67
67fetch(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(N(this,ut))return N(this,ut).continueRetry(),N(this,ut).promise}if(t&&this.setOptions(t),!this.options.queryFn){const h=this.observers.find(p=>p.options.queryFn);h&&this.setOptions(h.options)}const r=new AbortController,s=h=>{Object.defineProperty(h,"signal",{enumerable:!0,get:()=>(oe(this,si,!0),r.signal)})},i=()=>{const h=kS(this.options,n),b=(()=>{const g={client:N(this,ri),queryKey:this.queryKey,meta:this.meta};return s(g),g})();return oe(this,si,!1),this.options.persister?this.options.persister(h,b,this):h(b)},a=(()=>{const h={fetchOptions:n,options:this.options,queryKey:this.queryKey,client:N(this,ri),state:this.state,fetchFn:i};return s(h),h})();(c=this.options.behavior)==null||c.onFetch(a,this),oe(this,ni,this.state),(this.state.fetchStatus==="idle"||this.state.fetchMeta!==((u=a.fetchOptions)==null?void 0:u.meta))&&at(this,_n,vr).call(this,{type:"fetch",meta:(d=a.fetchOptions)==null?void 0:d.meta});const l=h=>{var p,b,g,x;Kf(h)&&h.silent||at(this,_n,vr).call(this,{type:"error",error:h}),Kf(h)||((b=(p=N(this,en).config).onError)==null||b.call(p,h,this),(x=(g=N(this,en).config).onSettled)==null||x.call(g,this.state.data,h,this)),this.scheduleGc()};return oe(this,ut,AS({initialPromise:n==null?void 0:n.initialPromise,fn:a.fetchFn,abort:r.abort.bind(r),onSuccess:h=>{var p,b,g,x;if(h===void 0){l(new Error(`${this.queryHash} data is undefined`));return}try{this.setData(h)}catch(y){l(y);return}(b=(p=N(this,en).config).onSuccess)==null||b.call(p,h,this),(x=(g=N(this,en).config).onSettled)==null||x.call(g,h,this.state.error,this),this.scheduleGc()},onError:l,onFail:(h,p)=>{at(this,_n,vr).call(this,{type:"failed",failureCount:h,error:p})},onPause:()=>{at(this,_n,vr).call(this,{type:"pause"})},onContinue:()=>{at(this,_n,vr).call(this,{type:"continue"})},retry:a.options.retry,retryDelay:a.options.retryDelay,networkMode:a.options.networkMode,canRun:()=>!0})),N(this,ut).start()}},Eo=new WeakMap,ni=new WeakMap,en=new WeakMap,ri=new WeakMap,ut=new WeakMap,Ml=new WeakMap,si=new WeakMap,_n=new WeakSet,vr=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,...cR(r.data,this.options),fetchMeta:t.meta??null};case"success":return oe(this,ni,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 Kf(s)&&s.revert&&N(this,ni)?{...N(this,ni),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),gt.batch(()=>{this.observers.forEach(r=>{r.onQueryUpdate()}),N(this,en).notify({query:this,type:"updated",action:t})})},Kb);function cR(e,t){return{fetchFailureCount:0,fetchFailureReason:null,fetchStatus:CS(t.networkMode)?"fetching":"paused",...e===void 0&&{error:null,status:"pending"}}}function uR(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 qn,qb,dR=(qb=class extends Bd{constructor(t={}){super();me(this,qn);this.config=t,oe(this,qn,new Map)}build(t,n,r){const s=n.queryKey,i=n.queryHash??Kg(s,n);let o=this.get(i);return o||(o=new lR({client:t,queryKey:s,queryHash:i,options:t.defaultQueryOptions(n),state:r,defaultOptions:t.getQueryDefaults(s)}),this.add(o)),o}add(t){N(this,qn).has(t.queryHash)||(N(this,qn).set(t.queryHash,t),this.notify({type:"added",query:t}))}remove(t){const n=N(this,qn).get(t.queryHash);n&&(t.destroy(),n===t&&N(this,qn).delete(t.queryHash),this.notify({type:"removed",query:t}))}clear(){gt.batch(()=>{this.getAll().forEach(t=>{this.remove(t)})})}get(t){return N(this,qn).get(t)}getAll(){return[...N(this,qn).values()]}find(t){const n={exact:!0,...t};return this.getAll().find(r=>N0(n,r))}findAll(t={}){const n=this.getAll();return Object.keys(t).length>0?n.filter(r=>N0(t,r)):n}notify(t){gt.batch(()=>{this.listeners.forEach(n=>{n(t)})})}onFocus(){gt.batch(()=>{this.getAll().forEach(t=>{t.onFocus()})})}onOnline(){gt.batch(()=>{this.getAll().forEach(t=>{t.onOnline()})})}},qn=new WeakMap,qb),Yn,ht,ii,Gn,Vr,Yb,fR=(Yb=class extends PS{constructor(t){super();me(this,Gn);me(this,Yn);me(this,ht);me(this,ii);this.mutationId=t.mutationId,oe(this,ht,t.mutationCache),oe(this,Yn,[]),this.state=t.state||hR(),this.setOptions(t.options),this.scheduleGc()}setOptions(t){this.options=t,this.updateGcTime(this.options.gcTime)}get meta(){return this.options.meta}addObserver(t){N(this,Yn).includes(t)||(N(this,Yn).push(t),this.clearGcTimeout(),N(this,ht).notify({type:"observerAdded",mutation:this,observer:t}))}removeObserver(t){oe(this,Yn,N(this,Yn).filter(n=>n!==t)),this.scheduleGc(),N(this,ht).notify({type:"observerRemoved",mutation:this,observer:t})}optionalRemove(){N(this,Yn).length||(this.state.status==="pending"?this.scheduleGc():N(this,ht).remove(this))}continue(){var t;return((t=N(this,ii))==null?void 0:t.continue())??this.execute(this.state.variables)}async execute(t){var i,o,a,l,c,u,d,h,p,b,g,x,y,m,v,_,S,k,E,T;const n=()=>{at(this,Gn,Vr).call(this,{type:"continue"})};oe(this,ii,AS({fn:()=>this.options.mutationFn?this.options.mutationFn(t):Promise.reject(new Error("No mutationFn found")),onFail:(P,A)=>{at(this,Gn,Vr).call(this,{type:"failed",failureCount:P,error:A})},onPause:()=>{at(this,Gn,Vr).call(this,{type:"pause"})},onContinue:n,retry:this.options.retry??0,retryDelay:this.options.retryDelay,networkMode:this.options.networkMode,canRun:()=>N(this,ht).canRun(this)}));const r=this.state.status==="pending",s=!N(this,ii).canStart();try{if(r)n();else{at(this,Gn,Vr).call(this,{type:"pending",variables:t,isPaused:s}),await((o=(i=N(this,ht).config).onMutate)==null?void 0:o.call(i,t,this));
67const A=await((l=(a=this.options).onMutate)==null?void 0:l.call(a,t));A!==this.state.context&&at(this,Gn,Vr).call(this,{type:"pending",context:A,variables:t,isPaused:s})}const P=await N(this,ii).start();return await((u=(c=N(this,ht).config).onSuccess)==null?void 0:u.call(c,P,t,this.state.context,this)),await((h=(d=this.options).onSuccess)==null?void 0:h.call(d,P,t,this.state.context)),await((b=(p=N(this,ht).config).onSettled)==null?void 0:b.call(p,P,null,this.state.variables,this.state.context,this)),await((x=(g=this.options).onSettled)==null?void 0:x.call(g,P,null,t,this.state.context)),at(this,Gn,Vr).call(this,{type:"success",data:P}),P}catch(P){try{throw await((m=(y=N(this,ht).config).onError)==null?void 0:m.call(y,P,t,this.state.context,this)),await((_=(v=this.options).onError)==null?void 0:_.call(v,P,t,this.state.context)),await((k=(S=N(this,ht).config).onSettled)==null?void 0:k.call(S,void 0,P,this.state.variables,this.state.context,this)),await((T=(E=this.options).onSettled)==null?void 0:T.call(E,void 0,P,t,this.state.context)),P}finally{at(this,Gn,Vr).call(this,{type:"error",error:P})}}finally{N(this,ht).runNext(this)}}},Yn=new WeakMap,ht=new WeakMap,ii=new WeakMap,Gn=new WeakSet,Vr=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),gt.batch(()=>{N(this,Yn).forEach(r=>{r.onMutationUpdate(t)}),N(this,ht).notify({mutation:this,type:"updated",action:t})})},Yb);function hR(){return{context:void 0,data:void 0,error:null,failureCount:0,failureReason:null,isPaused:!1,status:"idle",variables:void 0,submittedAt:0}}var br,Sn,Dl,Gb,pR=(Gb=class extends Bd{constructor(t={}){super();me(this,br);me(this,Sn);me(this,Dl);this.config=t,oe(this,br,new Set),oe(this,Sn,new Map),oe(this,Dl,0)}build(t,n,r){const s=new fR({mutationCache:this,mutationId:++cc(this,Dl)._,options:t.defaultMutationOptions(n),state:r});return this.add(s),s}add(t){N(this,br).add(t);const n=Ac(t);if(typeof n=="string"){const r=N(this,Sn).get(n);r?r.push(t):N(this,Sn).set(n,[t])}this.notify({type:"added",mutation:t})}remove(t){if(N(this,br).delete(t)){const n=Ac(t);if(typeof n=="string"){const r=N(this,Sn).get(n);if(r)if(r.length>1){const s=r.indexOf(t);s!==-1&&r.splice(s,1)}else r[0]===t&&N(this,Sn).delete(n)}}this.notify({type:"removed",mutation:t})}canRun(t){const n=Ac(t);if(typeof n=="string"){const r=N(this,Sn).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=Ac(t);if(typeof n=="string"){const s=(r=N(this,Sn).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(){gt.batch(()=>{N(this,br).forEach(t=>{this.notify({type:"removed",mutation:t})}),N(this,br).clear(),N(this,Sn).clear()})}getAll(){return Array.from(N(this,br))}find(t){const n={exact:!0,...t};return this.getAll().find(r=>R0(n,r))}findAll(t={}){return this.getAll().filter(n=>R0(t,n))}notify(t){gt.batch(()=>{this.listeners.forEach(n=>{n(t)})})}resumePausedMutations(){const t=this.getAll().filter(n=>n.state.isPaused);return gt.batch(()=>Promise.all(t.map(n=>n.continue().catch(bn))))}},br=new WeakMap,Sn=new WeakMap,Dl=new WeakMap,Gb);function Ac(e){var t;return(t=e.options.scope)==null?void 0:t.id}function D0(e){return{onFetch:(t,n)=>{var u,d,h,p,b;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=((p=t.state.data)==null?void 0:p.pages)||[],o=((b=t.state.data)==null?void 0:b.pageParams)||[];let a={pages:[],pageParams:[]},l=0;const c=async()=>{let g=!1;const x=v=>{Object.defineProperty(v,"signal",{enumerable:!0,get:()=>(t.signal.aborted?g=!0:t.signal.addEventListener("abort",()=>{g=!0}),t.signal)}
vendor: 4,527 bytes, line 67
67)},y=kS(t.options,t.fetchOptions),m=async(v,_,S)=>{if(g)return Promise.reject();if(_==null&&v.pages.length)return Promise.resolve(v);const E=(()=>{const B={client:t.client,queryKey:t.queryKey,pageParam:_,direction:S?"backward":"forward",meta:t.options.meta};return x(B),B})(),T=await y(E),{maxPages:P}=t.options,A=S?tR:eR;return{pages:A(v.pages,T,P),pageParams:A(v.pageParams,_,P)}};if(s&&i.length){const v=s==="backward",_=v?mR:I0,S={pages:i,pageParams:o},k=_(r,S);a=await m(S,k,v)}else{const v=e??i.length;do{const _=l===0?o[0]??r.initialPageParam:I0(r,a);if(l>0&&_==null)break;a=await m(a,_),l++}while(l<v)}return a};t.options.persister?t.fetchFn=()=>{var g,x;return(x=(g=t.options).persister)==null?void 0:x.call(g,c,{client:t.client,queryKey:t.queryKey,meta:t.options.meta,signal:t.signal},n)}:t.fetchFn=c}}}function I0(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 mR(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 Fe,ts,ns,Co,To,rs,Ao,Po,Qb,gR=(Qb=class{constructor(e={}){me(this,Fe);me(this,ts);me(this,ns);me(this,Co);me(this,To);me(this,rs);me(this,Ao);me(this,Po);oe(this,Fe,e.queryCache||new dR),oe(this,ts,e.mutationCache||new pR),oe(this,ns,e.defaultOptions||{}),oe(this,Co,new Map),oe(this,To,new Map),oe(this,rs,0)}mount(){cc(this,rs)._++,N(this,rs)===1&&(oe(this,Ao,ES.subscribe(async e=>{e&&(await this.resumePausedMutations(),N(this,Fe).onFocus())})),oe(this,Po,Gu.subscribe(async e=>{e&&(await this.resumePausedMutations(),N(this,Fe).onOnline())})))}unmount(){var e,t;cc(this,rs)._--,N(this,rs)===0&&((e=N(this,Ao))==null||e.call(this),oe(this,Ao,void 0),(t=N(this,Po))==null||t.call(this),oe(this,Po,void 0))}isFetching(e){return N(this,Fe).findAll({...e,fetchStatus:"fetching"}).length}isMutating(e){return N(this,ts).findAll({...e,status:"pending"}).length}getQueryData(e){var n;const t=this.defaultQueryOptions({queryKey:e});return(n=N(this,Fe).get(t.queryHash))==null?void 0:n.state.data}ensureQueryData(e){const t=this.defaultQueryOptions(e),n=N(this,Fe).build(this,t),r=n.state.data;return r===void 0?this.fetchQuery(e):(e.revalidateIfStale&&n.isStaleByTime(Vp(t.staleTime,n))&&this.prefetchQuery(t),Promise.resolve(r))}getQueriesData(e){return N(this,Fe).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=N(this,Fe).get(r.queryHash),i=s==null?void 0:s.state.data,o=YN(t,i);if(o!==void 0)return N(this,Fe).build(this,r).setData(o,{...n,manual:!0})}setQueriesData(e,t,n){return gt.batch(()=>N(this,Fe).findAll(e).map(({queryKey:r})=>[r,this.setQueryData(r,t,n)]))}getQueryState(e){var n;const t=this.defaultQueryOptions({queryKey:e});return(n=N(this,Fe).get(t.queryHash))==null?void 0:n.state}removeQueries(e){const t=N(this,Fe);gt.batch(()=>{t.findAll(e).forEach(n=>{t.remove(n)})})}resetQueries(e,t){const n=N(this,Fe);return gt.batch(()=>(n.findAll(e).forEach(r=>{r.reset()}),this.refetchQueries({type:"active",...e},t)))}cancelQueries(e,t={}){const n={revert:!0,...t},r=gt.batch(()=>N(this,Fe).findAll(e).map(s=>s.cancel(n)));return Promise.all(r).then(bn).catch(bn)}invalidateQueries(e,t={}){return gt.batch(()=>(N(this,Fe).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=gt.batch(()=>N(this,Fe).findAll(e).filter(s=>!s.isDisabled()&&!s.isStatic()).map(s=>{let i=s.fetch(void 0,n);return n.throwOnError||(i=i.catch(bn)),s.state.fetchStatus==="paused"?Promise.resolve():i}));return Promise.all(r).then(bn)}fetchQuery(e){const t=this.defaultQueryOptions(e);t.retry===void 0&&(t.retry=!1);const n=N(this,Fe).build(this,t);return n.isStaleByTime(Vp(t.staleTime,n))?n.fetch(t):Promise.resolve(n.state.data)}prefetchQuery(e){return this.fetchQuery(e).then(bn).catch(bn)}fetchInfiniteQuery(e){return e.behavior=D0(e.pages),this.fetchQuery(e)}prefetchInfiniteQuery(e){return this.fetchInfiniteQuery(e).then(bn).catch(bn)}ensureInfiniteQueryData(e){return e.behavior=D0(e.pages),this.ensureQueryData(e)}resumePausedMutations(){return Gu.isOnline()?N(this,ts).resumePausedMutations():Promise.resolve()}getQueryCache(){return N(this,Fe)}getMutationCache(){return N(this,ts)}getDefaultOptions(){return N(this,ns)}setDefaultOptions(e){oe(this,ns,e)}
67setQueryDefaults(e,t){N(this,Co).set(yl(e),{queryKey:e,defaultOptions:t})}getQueryDefaults(e){const t=[...N(this,Co).values()],n={};return t.forEach(r=>{wl(e,r.queryKey)&&Object.assign(n,r.defaultOptions)}),n}setMutationDefaults(e,t){N(this,To).set(yl(e),{mutationKey:e,defaultOptions:t})}getMutationDefaults(e){const t=[...N(this,To).values()],n={};return t.forEach(r=>{wl(e,r.mutationKey)&&Object.assign(n,r.defaultOptions)}),n}defaultQueryOptions(e){if(e._defaulted)return e;const t={...N(this,ns).queries,...this.getQueryDefaults(e.queryKey),...e,_defaulted:!0};return t.queryHash||(t.queryHash=Kg(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===qg&&(t.enabled=!1),t}defaultMutationOptions(e){return e!=null&&e._defaulted?e:{...N(this,ns).mutations,...(e==null?void 0:e.mutationKey)&&this.getMutationDefaults(e.mutationKey),...e,_defaulted:!0}}clear(){N(this,Fe).clear(),N(this,ts).clear()}},Fe=new WeakMap,ts=new WeakMap,ns=new WeakMap,Co=new WeakMap,To=new WeakMap,rs=new WeakMap,Ao=new WeakMap,Po=new WeakMap,Qb),vR=w.createContext(void 0),yR=({client:e,children:t})=>(w.useEffect(()=>(e.mount(),()=>{e.unmount()}),[e]),f.jsx(vR.Provider,{value:e,children:t})),wR=typeof Element<"u",xR=typeof Map=="function",bR=typeof Set=="function",_R=typeof ArrayBuffer=="function"&&!!ArrayBuffer.isView;function au(e,t){if(e===t)return!0;if(e&&t&&typeof e=="object"&&typeof t=="object"){if(e.constructor!==t.constructor)return!1;var n,r,s;if(Array.isArray(e)){if(n=e.length,n!=t.length)return!1;for(r=n;r--!==0;)if(!au(e[r],t[r]))return!1;return!0}var i;if(xR&&e instanceof Map&&t instanceof Map){if(e.size!==t.size)return!1;for(i=e.entries();!(r=i.next()).done;)if(!t.has(r.value[0]))return!1;for(i=e.entries();!(r=i.next()).done;)if(!au(r.value[1],t.get(r.value[0])))return!1;return!0}if(bR&&e instanceof Set&&t instanceof Set){if(e.size!==t.size)return!1;for(i=e.entries();!(r=i.next()).done;)if(!t.has(r.value[0]))return!1;return!0}if(_R&&ArrayBuffer.isView(e)&&ArrayBuffer.isView(t)){if(n=e.length,n!=t.length)return!1;for(r=n;r--!==0;)if(e[r]!==t[r])return!1;return!0}if(e.constructor===RegExp)return e.source===t.source&&e.flags===t.flags;if(e.valueOf!==Object.prototype.valueOf&&typeof e.valueOf=="function"&&typeof t.valueOf=="function")return e.valueOf()===t.valueOf();if(e.toString!==Object.prototype.toString&&typeof e.toString=="function"&&typeof t.toString=="function")return e.toString()===t.toString();if(s=Object.keys(e),n=s.length,n!==Object.keys(t).length)return!1;for(r=n;r--!==0;)if(!Object.prototype.hasOwnProperty.call(t,s[r]))return!1;if(wR&&e instanceof Element)return!1;for(r=n;r--!==0;)if(!((s[r]==="_owner"||s[r]==="__v"||s[r]==="__o")&&e.$$typeof)&&!au(e[s[r]],t[s[r]]))return!1;return!0}return e!==e&&t!==t}var SR=function(t,n){try{return au(t,n)}catch(r){if((r.message||"").match(/stack|recursion/i))return console.warn("react-fast-compare cannot handle circular refs"),!1;throw r}};const kR=Il(SR);var ER=function(e,t,n,r,s,i,o,a){if(!e){var l;if(t===void 0)l=new Error("Minified exception occurred; use the non-minified dev environment for the full error message and additional helpful warnings.");else{var c=[n,r,s,i,o,a],u=0;l=new Error(t.replace(/%s/g,function(){return c[u++]})),l.name="Invariant Violation"}throw l.framesToPop=1,l}},CR=ER;const L0=Il(CR);var TR=function(t,n,r,s){var i=r?r.call(s,t,n):void 0;if(i!==void 0)return!!i;if(t===n)return!0;if(typeof t!="object"||!t||typeof n!="object"||!n)return!1;var o=Object.keys(t),a=Object.keys(n);if(o.length!==a.length)return!1;for(var l=Object.prototype.hasOwnProperty.bind(n),c=0;c<o.length;c++){var u=o[c];if(!l(u))return!1;var d=t[u],h=n[u];if(i=r?r.call(s,d,h,u):void 0,i===!1||i===void 0&&d!==h)return!1}return!0};const AR=Il(TR);var jS=(e=>(e.BASE="base",e.BODY="body",e.HEAD="head",e.HTML="html",e.LINK="link",e.META="meta",e.NOSCRIPT="noscript",e.SCRIPT="script",e.STYLE="style",e.TITLE="title",e.FRAGMENT="Symbol(react.fragment)",e))(jS||{}),qf={link:{rel:["amphtml","canonical","alternate"]},script:{type:["application/ld+json"]}
67,meta:{charset:"",name:["generator","robots","description"],property:["og:type","og:title","og:url","og:image","og:image:alt","og:description","twitter:url","twitter:title","twitter:description","twitter:image","twitter:image:alt","twitter:card","twitter:site"]}},F0=Object.values(jS),Yg={accesskey:"accessKey",charset:"charSet",class:"className",contenteditable:"contentEditable",contextmenu:"contextMenu","http-equiv":"httpEquiv",itemprop:"itemProp",tabindex:"tabIndex"},PR=Object.entries(Yg).reduce((e,[t,n])=>(e[n]=t,e),{}),Tn="data-rh",go={DEFAULT_TITLE:"defaultTitle",DEFER:"defer",ENCODE_SPECIAL_CHARACTERS:"encodeSpecialCharacters",ON_CHANGE_CLIENT_STATE:"onChangeClientState",TITLE_TEMPLATE:"titleTemplate",PRIORITIZE_SEO_TAGS:"prioritizeSeoTags"},vo=(e,t)=>{for(let n=e.length-1;n>=0;n-=1){const r=e[n];if(Object.prototype.hasOwnProperty.call(r,t))return r[t]}return null},jR=e=>{let t=vo(e,"title");const n=vo(e,go.TITLE_TEMPLATE);if(Array.isArray(t)&&(t=t.join("")),n&&t)return n.replace(/%s/g,()=>t);const r=vo(e,go.DEFAULT_TITLE);return t||r||void 0},NR=e=>vo(e,go.ON_CHANGE_CLIENT_STATE)||(()=>{}),Yf=(e,t)=>t.filter(n=>typeof n[e]<"u").map(n=>n[e]).reduce((n,r)=>({...n,...r}),{}),RR=(e,t)=>t.filter(n=>typeof n.base<"u").map(n=>n.base).reverse().reduce((n,r)=>{if(!n.length){const s=Object.keys(r);for(let i=0;i<s.length;i+=1){const a=s[i].toLowerCase();if(e.indexOf(a)!==-1&&r[a])return n.concat(r)}}return n},[]),OR=e=>console&&typeof console.warn=="function"&&console.warn(e),va=(e,t,n)=>{const r={};return n.filter(s=>Array.isArray(s[e])?!0:(typeof s[e]<"u"&&OR(`Helmet: ${e} should be of type "Array". Instead found type "${typeof s[e]}"`),!1)).map(s=>s[e]).reverse().reduce((s,i)=>{const o={};i.filter(l=>{let c;const u=Object.keys(l);for(let h=0;h<u.length;h+=1){const p=u[h],b=p.toLowerCase();t.indexOf(b)!==-1&&!(c==="rel"&&l[c].toLowerCase()==="canonical")&&!(b==="rel"&&l[b].toLowerCase()==="stylesheet")&&(c=b),t.indexOf(p)!==-1&&(p==="innerHTML"||p==="cssText"||p==="itemprop")&&(c=p)}if(!c||!l[c])return!1;const d=l[c].toLowerCase();return r[c]||(r[c]={}),o[c]||(o[c]={}),r[c][d]?!1:(o[c][d]=!0,!0)}).reverse().forEach(l=>s.push(l));const a=Object.keys(o);for(let l=0;l<a.length;l+=1){const c=a[l],u={...r[c],...o[c]};r[c]=u}return s},[]).reverse()},MR=(e,t)=>{if(Array.isArray(e)&&e.length){for(let n=0;n<e.length;n+=1)if(e[n][t])return!0}return!1},DR=e=>({baseTag:RR(["href"],e),bodyAttributes:Yf("bodyAttributes",e),defer:vo(e,go.DEFER),encode:vo(e,go.ENCODE_SPECIAL_CHARACTERS),htmlAttributes:Yf("htmlAttributes",e),linkTags:va("link",["rel","href"],e),metaTags:va("meta",["name","charset","http-equiv","property","itemprop"],e),noscriptTags:va("noscript",["innerHTML"],e),onChangeClientState:NR(e),scriptTags:va("script",["src","innerHTML"],e),styleTags:va("style",["cssText"],e),title:jR(e),titleAttributes:Yf("titleAttributes",e),prioritizeSeoTags:MR(e,go.PRIORITIZE_SEO_TAGS)}),NS=e=>Array.isArray(e)?e.join(""):e,IR=(e,t)=>{const n=Object.keys(e);for(let r=0;r<n.length;r+=1)if(t[n[r]]&&t[n[r]].includes(e[n[r]]))return!0;return!1},Gf=(e,t)=>Array.isArray(e)?e.reduce((n,r)=>(IR(r,t)?n.priority.push(r):n.default.push(r),n),{priority:[],default:[]}):{default:e,priority:[]},$0=(e,t)=>({...e,[t]:void 0}),LR=["noscript","script","style"],zp=(e,t=!0)=>t===!1?String(e):String(e).replace(/&/g,"&amp;").replace(/</g,"&lt;").replace(/>/g,"&gt;").replace(/"/g,"&quot;").replace(/'/g,"&#x27;"),RS=e=>Object.keys(e).reduce((t,n)=>{const r=typeof e[n]<"u"?`${n}="${e[n]}"`:`${n}`;return t?`${t} ${r}`:r},""),FR=(e,t,n,r)=>{const s=RS(n),i=NS(t);return s?`<${e} ${Tn}="true" ${s}>${zp(i,r)}</${e}>`:`<${e} ${Tn}="true">${zp(i,r)}</${e}>`},$R=(e,t,n=!0)=>t.reduce((r,s)=>{const i=s,o=Object.keys(i).filter(c=>!(c==="innerHTML"||c==="cssText")).reduce((c,u)=>{const d=typeof i[u]>"u"?u:`${u}="${zp(i[u],n)}"`;return c?`${c} ${d}`:d},""),a=i.innerHTML||i.cssText||"",l=LR.indexOf(e)===-1;return`${r}<${e} ${Tn}="true" ${o}${l?"/>":`>${a}</${e}>`}`},""),OS=(e,t={})=>Object.keys(e).reduce((n,r)=>{const s=Yg[r];return n[s||r]=e[r],n},t),BR=(e,t,n)=>{const r={key:t,[Tn]:!0},s=OS(n,r);return[D.createElement("title",s,t)]},lu=(e,t)=>
67t.map((n,r)=>{const s={key:r,[Tn]:!0};return Object.keys(n).forEach(i=>{const a=Yg[i]||i;if(a==="innerHTML"||a==="cssText"){const l=n.innerHTML||n.cssText;s.dangerouslySetInnerHTML={__html:l}}else s[a]=n[i]}),D.createElement(e,s)}),Xt=(e,t,n=!0)=>{switch(e){case"title":return{toComponent:()=>BR(e,t.title,t.titleAttributes),toString:()=>FR(e,t.title,t.titleAttributes,n)};case"bodyAttributes":case"htmlAttributes":return{toComponent:()=>OS(t),toString:()=>RS(t)};default:return{toComponent:()=>lu(e,t),toString:()=>$R(e,t,n)}}},VR=({metaTags:e,linkTags:t,scriptTags:n,encode:r})=>{const s=Gf(e,qf.meta),i=Gf(t,qf.link),o=Gf(n,qf.script);return{priorityMethods:{toComponent:()=>[...lu("meta",s.priority),...lu("link",i.priority),...lu("script",o.priority)],toString:()=>`${Xt("meta",s.priority,r)} ${Xt("link",i.priority,r)} ${Xt("script",o.priority,r)}`},metaTags:s.default,linkTags:i.default,scriptTags:o.default}},UR=e=>{const{baseTag:t,bodyAttributes:n,encode:r=!0,htmlAttributes:s,noscriptTags:i,styleTags:o,title:a="",titleAttributes:l,prioritizeSeoTags:c}=e;let{linkTags:u,metaTags:d,scriptTags:h}=e,p={toComponent:()=>{},toString:()=>""};return c&&({priorityMethods:p,linkTags:u,metaTags:d,scriptTags:h}=VR(e)),{priority:p,base:Xt("base",t,r),bodyAttributes:Xt("bodyAttributes",n,r),htmlAttributes:Xt("htmlAttributes",s,r),link:Xt("link",u,r),meta:Xt("meta",d,r),noscript:Xt("noscript",i,r),script:Xt("script",h,r),style:Xt("style",o,r),title:Xt("title",{title:a,titleAttributes:l},r)}},Wp=UR,Pc=[],MS=!!(typeof window<"u"&&window.document&&window.document.createElement),Hp=class{constructor(e,t){pr(this,"instances",[]);pr(this,"canUseDOM",MS);pr(this,"context");pr(this,"value",{setHelmet:e=>{this.context.helmet=e},helmetInstances:{get:()=>this.canUseDOM?Pc:this.instances,add:e=>{(this.canUseDOM?Pc:this.instances).push(e)},remove:e=>{const t=(this.canUseDOM?Pc:this.instances).indexOf(e);(this.canUseDOM?Pc:this.instances).splice(t,1)}}});this.context=e,this.canUseDOM=t||!1,t||(e.helmet=Wp({baseTag:[],bodyAttributes:{},encodeSpecialCharacters:!0,htmlAttributes:{},linkTags:[],metaTags:[],noscriptTags:[],scriptTags:[],styleTags:[],title:"",titleAttributes:{}}))}},zR={},DS=D.createContext(zR),oi,IS=(oi=class extends w.Component{constructor(n){super(n);pr(this,"helmetData");this.helmetData=new Hp(this.props.context||{},oi.canUseDOM)}render(){return D.createElement(DS.Provider,{value:this.helmetData.value},this.props.children)}},pr(oi,"canUseDOM",MS),oi),Ri=(e,t)=>{const n=document.head||document.querySelector("head"),r=n.querySelectorAll(`${e}[${Tn}]`),s=[].slice.call(r),i=[];let o;return t&&t.length&&t.forEach(a=>{const l=document.createElement(e);for(const c in a)if(Object.prototype.hasOwnProperty.call(a,c))if(c==="innerHTML")l.innerHTML=a.innerHTML;else if(c==="cssText")l.styleSheet?l.styleSheet.cssText=a.cssText:l.appendChild(document.createTextNode(a.cssText));else{const u=c,d=typeof a[u]>
67"u"?"":a[u];l.setAttribute(c,d)}l.setAttribute(Tn,"true"),s.some((c,u)=>(o=u,l.isEqualNode(c)))?s.splice(o,1):i.push(l)}),s.forEach(a=>{var l;return(l=a.parentNode)==null?void 0:l.removeChild(a)}),i.forEach(a=>n.appendChild(a)),{oldTags:s,newTags:i}},Kp=(e,t)=>{const n=document.getElementsByTagName(e)[0];if(!n)return;const r=n.getAttribute(Tn),s=r?r.split(","):[],i=[...s],o=Object.keys(t);for(const a of o){const l=t[a]||"";n.getAttribute(a)!==l&&n.setAttribute(a,l),s.indexOf(a)===-1&&s.push(a);const c=i.indexOf(a);c!==-1&&i.splice(c,1)}for(let a=i.length-1;a>=0;a-=1)n.removeAttribute(i[a]);s.length===i.length?n.removeAttribute(Tn):n.getAttribute(Tn)!==o.join(",")&&n.setAttribute(Tn,o.join(","))},WR=(e,t)=>{typeof e<"u"&&document.title!==e&&(document.title=NS(e)),Kp("title",t)},B0=(e,t)=>{const{baseTag:n,bodyAttributes:r,htmlAttributes:s,linkTags:i,metaTags:o,noscriptTags:a,onChangeClientState:l,scriptTags:c,styleTags:u,title:d,titleAttributes:h}=e;Kp("body",r),Kp("html",s),WR(d,h);const p={baseTag:Ri("base",n),linkTags:Ri("link",i),metaTags:Ri("meta",o),noscriptTags:Ri("noscript",a),scriptTags:Ri("script",c),styleTags:Ri("style",u)},b={},g={};Object.keys(p).forEach(x=>{const{newTags:y,oldTags:m}=p[x];y.length&&(b[x]=y),m.length&&(g[x]=p[x].oldTags)}),t&&t(),l(e,b,g)},ya=null,HR=e=>{ya&&cancelAnimationFrame(ya),e.defer?ya=requestAnimationFrame(()=>{B0(e,()=>{ya=null})}):(B0(e),ya=null)},KR=HR,V0=class extends w.Component{constructor(){super(...arguments);pr(this,"rendered",!1)}shouldComponentUpdate(t){return!AR(t,this.props)}componentDidUpdate(){this.emitChange()}componentWillUnmount(){const{helmetInstances:t}=this.props.context;t.remove(this),this.emitChange()}emitChange(){const{helmetInstances:t,setHelmet:n}=this.props.context;let r=null;const s=DR(t.get().map(i=>{const o={...i.props};return delete o.context,o}));IS.canUseDOM?KR(s):Wp&&(r=Wp(s)),n(r)}init(){if(this.rendered)return;this.rendered=!0;const{helmetInstances:t}=this.props.context;t.add(this),this.emitChange()}render(){return this.init(),null}},Hh,qR=(Hh=class extends w.Component{shouldComponentUpdate(e){return!kR($0(this.props,"helmetData"),$0(e,"helmetData"))}mapNestedChildrenToProps(e,t){if(!t)return null;switch(e.type){case"script":case"noscript":return{innerHTML:t};case"style":return{cssText:t};default:throw new Error(`<${e.type} /> elements are self-closing and can not contain children. Refer to our API for more information.`)}}flattenArrayTypeChildren(e,t,n,r){return{...t,[e.type]:[...t[e.type]||[],{...n,...this.mapNestedChildrenToProps(e,r)}]}}mapObjectTypeChildren(e,t,n,r){switch(e.type){case"title":return{...t,[e.type]:r,titleAttributes:{...n}};case"body":return{...t,bodyAttributes:{...n}};case"html":return{...t,htmlAttributes:{...n}};default:return{...t,[e.type]:{...n}}}}mapArrayTypeChildrenToProps(e,t){let n={...t};return Object.keys(e).forEach(r=>{n={...n,[r]:e[r]}}),n}warnOnInvalidChildren(e,t){return L0(F0.some(n=>e.type===n),typeof e.type=="function"?"You may be attempting to nest <Helmet> components within each other, which is not allowed. Refer to our API for more information.":`Only elements types ${F0.join(", ")} are allowed. Helmet does not support rendering <${e.type}> elements. Refer to our API for more information.`),L0(!t||typeof t=="string"||Array.isArray(t)&&!t.some(n=>typeof n!="string"),`Helmet expects a string as a child of <${e.type}>. Did you forget to wrap your children in braces? ( <${e.type}>{\`\`}</${e.type}> ) Refer to our API for more information.`),!0}mapChildrenToProps(e,t){let n={};return D.Children.forEach(e,r=>{if(!r||!r.props)return;const{children:s,...i}=r.props,o=Object.keys(i).reduce((l,c)=>(l[PR[c]||c]=i[c],l),{});let{type:a}=r;
67switch(typeof a=="symbol"?a=a.toString():this.warnOnInvalidChildren(r,s),a){case"Symbol(react.fragment)":t=this.mapChildrenToProps(s,t);break;case"link":case"meta":case"noscript":case"script":case"style":n=this.flattenArrayTypeChildren(r,n,o,s);break;default:t=this.mapObjectTypeChildren(r,t,o,s);break}}),this.mapArrayTypeChildrenToProps(n,t)}render(){const{children:e,...t}=this.props;let n={...t},{helmetData:r}=t;if(e&&(n=this.mapChildrenToProps(e,n)),r&&!(r instanceof Hp)){const s=r;r=new Hp(s.context,!0),delete n.helmetData}return r?D.createElement(V0,{...n,context:r.value}):D.createElement(DS.Consumer,null,s=>D.createElement(V0,{...n,context:s}))}},pr(Hh,"defaultProps",{defer:!0,encodeSpecialCharacters:!0,prioritizeSeoTags:!1}),Hh);const YR=1,GR=1e6;let Qf=0;function QR(){return Qf=(Qf+1)%Number.MAX_SAFE_INTEGER,Qf.toString()}const Zf=new Map,U0=e=>{if(Zf.has(e))return;const t=setTimeout(()=>{Zf.delete(e),za({type:"REMOVE_TOAST",toastId:e})},GR);Zf.set(e,t)},ZR=(e,t)=>{switch(t.type){case"ADD_TOAST":return{...e,toasts:[t.toast,...e.toasts].slice(0,YR)};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?U0(n):e.toasts.forEach(r=>{U0(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)}}},cu=[];let uu={toasts:[]};function za(e){uu=ZR(uu,e),cu.forEach(t=>{t(uu)})}function JR({...e}){const t=QR(),n=s=>za({type:"UPDATE_TOAST",toast:{...s,id:t}}),r=()=>za({type:"DISMISS_TOAST",toastId:t});return za({type:"ADD_TOAST",toast:{...e,id:t,open:!0,onOpenChange:s=>{s||r()}}}),{id:t,dismiss:r,update:n}}function Wl(){const[e,t]=w.useState(uu);return w.useEffect(()=>(cu.push(t),()=>{const n=cu.indexOf(t);n>-1&&cu.splice(n,1)}),[e]),{...e,toast:JR,dismiss:n=>za({type:"DISMISS_TOAST",toastId:n})}}function Oe(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 z0(e,t){if(typeof e=="function")return e(t);e!=null&&(e.current=t)}function LS(...e){return t=>{let n=!1;const r=e.map(s=>{const i=z0(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():z0(e[s],null)}}}}function Dt(...e){return w.useCallback(LS(...e),e)}function Hl(e,t=[]){let n=[];function r(i,o){const a=w.createContext(o),l=n.length;n=[...n,o];const c=d=>{var y;const{scope:h,children:p,...b}=d,g=((y=h==null?void 0:h[e])==null?void 0:y[l])||a,x=w.useMemo(()=>b,Object.values(b));return f.jsx(g.Provider,{value:x,children:p})};c.displayName=i+"Provider";function u(d,h){var g;const p=((g=h==null?void 0:h[e])==null?void 0:g[l])||a,b=w.useContext(p);if(b)return b;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=>w.createContext(o));return function(a){const l=(a==null?void 0:a[e])||i;return w.useMemo(()=>({[`__scope${e}`]:{...a,[e]:l}}),[a,l])}};return s.scopeName=e,[r,XR(s,...t)]}function XR(...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 w.useMemo(()=>({[`__scope${t.scopeName}`]:o}),[o])}};return n.scopeName=t.scopeName,n}function xl(e){const t=tO(e),n=w.forwardRef((r,s)=>{const{children:i,...o}=r,a=w.Children.toArray(i),l=a.find(rO);if(l){const c=l.props.children,u=a.map(d=>d===l?w.Children.count(c)>1?w.Children.only(null):w.isValidElement(c)?c.props.children:null:d);return f.jsx(t,{...o,ref:s,children:w.isValidElement(c)?w.cloneElement(c,void 0,u):null})}return f.jsx(t,{...o,ref:s,children:i})});return n.displayName=`${e}.Slot`,n}var eO=xl("Slot");function tO(e){const t=w.forwardRef((n,r)=>{const{children:s,...i}=n;if(w.isValidElement(s)){const o=iO(s),a=sO(i,s.props);return s.type!==w.Fragment&&(a.ref=r?LS(r,o):o),w.cloneElement(s,a)}return w.Children.count(s)>1?w.Children.only(null):null});return t.displayName=`${e}.SlotClone`,t}var FS=Symbol("radix.slottable");function nO(e){const t=({children:n})=>f.jsx(f.Fragment,{children:n});return t.displayName=`${e}.Slottable`,t.__radixId=FS,t}function rO(e){return w.isValidElement(e)&&typeof e.type=="function"&&"__radixId"in e.type&&e.type.__radixId===FS}function sO(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 67
67:r==="className"&&(n[r]=[s,i].filter(Boolean).join(" "))}return{...e,...n}}function iO(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 oO(e){const t=e+"CollectionProvider",[n,r]=Hl(t),[s,i]=n(t,{collectionRef:{current:null},itemMap:new Map}),o=g=>{const{scope:x,children:y}=g,m=D.useRef(null),v=D.useRef(new Map).current;return f.jsx(s,{scope:x,itemMap:v,collectionRef:m,children:y})};o.displayName=t;const a=e+"CollectionSlot",l=xl(a),c=D.forwardRef((g,x)=>{const{scope:y,children:m}=g,v=i(a,y),_=Dt(x,v.collectionRef);return f.jsx(l,{ref:_,children:m})});c.displayName=a;const u=e+"CollectionItemSlot",d="data-radix-collection-item",h=xl(u),p=D.forwardRef((g,x)=>{const{scope:y,children:m,...v}=g,_=D.useRef(null),S=Dt(x,_),k=i(u,y);return D.useEffect(()=>(k.itemMap.set(_,{ref:_,...v}),()=>void k.itemMap.delete(_))),f.jsx(h,{[d]:"",ref:S,children:m})});p.displayName=u;function b(g){const x=i(e+"CollectionConsumer",g);return D.useCallback(()=>{const m=x.collectionRef.current;if(!m)return[];const v=Array.from(m.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:p},b,r]}var aO=["a","button","div","form","h2","h3","img","input","label","li","nav","ol","p","select","span","svg","ul"],it=aO.reduce((e,t)=>{const n=xl(`Primitive.${t}`),r=w.forwardRef((s,i)=>{const{asChild:o,...a}=s,l=o?n:t;return typeof window<"u"&&(window[Symbol.for("radix-ui")]=!0),f.jsx(l,{...a,ref:i})});return r.displayName=`Primitive.${t}`,{...e,[t]:r}},{});function $S(e,t){e&&Si.flushSync(()=>e.dispatchEvent(t))}function or(e){const t=w.useRef(e);return w.useEffect(()=>{t.current=e}),w.useMemo(()=>(...n)=>{var r;return(r=t.current)==null?void 0:r.call(t,...n)},[])}function lO(e,t=globalThis==null?void 0:globalThis.document){const n=or(e);w.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 cO="DismissableLayer",qp="dismissableLayer.update",uO="dismissableLayer.pointerDownOutside",dO="dismissableLayer.focusOutside",W0,BS=w.createContext({layers:new Set,layersWithOutsidePointerEventsDisabled:new Set,branches:new Set}),Ud=w.forwardRef((e,t)=>{const{disableOutsidePointerEvents:n=!1,onEscapeKeyDown:r,onPointerDownOutside:s,onFocusOutside:i,onInteractOutside:o,onDismiss:a,...l}=e,c=w.useContext(BS),[u,d]=w.useState(null),h=(u==null?void 0:u.ownerDocument)??(globalThis==null?void 0:globalThis.document),[,p]=w.useState({}),b=Dt(t,E=>d(E)),g=Array.from(c.layers),[x]=[...c.layersWithOutsidePointerEventsDisabled].slice(-1),y=g.indexOf(x),m=u?g.indexOf(u):-1,v=c.layersWithOutsidePointerEventsDisabled.size>0,_=m>=y,S=hO(E=>{const T=E.target,P=[...c.branches].some(A=>A.contains(T));!_||P||(s==null||s(E),o==null||o(E),E.defaultPrevented||a==null||a())},h),k=pO(E=>{const T=E.target;[...c.branches].some(A=>A.contains(T))||(i==null||i(E),o==null||o(E),E.defaultPrevented||a==null||a())},h);return lO(E=>{m===c.layers.size-1&&(r==null||r(E),!E.defaultPrevented&&a&&(E.preventDefault(),a()))},h),w.useEffect(()=>{if(u)return n&&(c.layersWithOutsidePointerEventsDisabled.size===0&&(W0=h.body.style.pointerEvents,h.body.style.pointerEvents="none"),c.layersWithOutsidePointerEventsDisabled.add(u)),c.layers.add(u),H0(),()=>{n&&c.layersWithOutsidePointerEventsDisabled.size===1&&(h.body.style.pointerEvents=W0)}},[u,h,n,c]),w.useEffect(()=>()=>{u&&(c.layers.delete(u),c.layersWithOutsidePointerEventsDisabled.delete(u),H0())},[u,c]),w.useEffect(()=>{const E=()=>p({});return document.addEventListener(qp,E),()=>document.removeEventListener(qp,E)},[]),f.jsx(it.div,{...l,ref:b,style:{pointerEvents:v?_?"auto":"none":void 0,...e.style},onFocusCapture:Oe(e.onFocusCapture,k.onFocusCapture),onBlurCapture:Oe(e.onBlurCapture,k.onBlurCapture),onPointerDownCapture:Oe(e.onPointerDownCapture,S.onPointerDownCapture)})});Ud.displayName=cO;var fO="DismissableLayerBranch",VS=w.forwardRef((e,t)=>{const n=w.useContext(BS),r=w.useRef(null),s=Dt(t,r);return w.useEffect(()=>{const i=r.current;if(i)return n.branches.add(i),()=>{n.branches.delete(i)}},[n.branches]),f.jsx(it.div,{...e,ref:s})});VS.displayName=fO;function hO(e,t=globalThis==null?void 0:globalThis.document){const n=or(e),r=w.useRef(!1),s=w.useRef(()=>{});return w.useEffect(()=>{const i=a=>{if(a.target&&!r.current){let l=function(){US(uO,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 pO(e,t=globalThis==null?void 0:globalThis.document){const n=or(e),r=w.useRef(!1);return w.useEffect(()=>{const s=i=>{i.target&&!r.current&&US(dO,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 H0(){const e=new CustomEvent(qp);document.dispatchEvent(e)}function US(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?$S(s,i):s.dispatchEvent(i)}var mO=Ud,gO=VS,Pr=globalThis!=null&&globalThis.document?w.useLayoutEffect:()=>{},vO="Portal",Gg=w.forwardRef((e,t)=>{var a;const{container:n,...r}=e,[s,i]=w.useState(!1);Pr(()=>i(!0),[]);const o=n||s&&((a=globalThis==null?void 0:globalThis.document)==null?void 0:a.body);return o?cS.createPortal(f.jsx(it.div,{...r,ref:t}),o):null});Gg.displayName=vO;function yO(e,t){return w.useReducer((n,r)=>t[n][r]??n,e)}var Kl=e=>{const{present:t,children:n}=e,r=wO(t),s=typeof n=="function"?n({present:r.isPresent}):w.Children.only(n),i=Dt(r.ref,xO(s));return typeof n=="function"||r.isPresent?w.cloneElement(s,{ref:i}):null};Kl.displayName="Presence";function wO(e){const[t,n]=w.useState(),r=w.useRef(null),s=w.useRef(e),i=w.useRef("none"),o=e?"mounted":"unmounted",[a,l]=yO(o,{mounted:{UNMOUNT:"unmounted",ANIMATION_OUT:"unmountSuspended"},unmountSuspended:{MOUNT:"mounted",ANIMATION_END:"unmounted"},unmounted:{MOUNT:"mounted"}});return w.useEffect(()=>{const c=jc(r.current);i.current=a==="mounted"?c:"none"},[a]),Pr(()=>{const c=r.current,u=s.current;if(u!==e){const h=i.current,p=jc(c);e?l("MOUNT"):p==="none"||(c==null?void 0:c.display)==="none"?l("UNMOUNT"):l(u&&h!==p?"ANIMATION_OUT":"UNMOUNT"),s.current=e}},[e,l]),Pr(()=>{if(t){let c;const u=t.ownerDocument.defaultView??window,d=p=>{const g=jc(r.current).includes(p.animationName);if(p.target===t&&g&&(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=p=>{p.target===t&&(i.current=jc(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:w.useCallback(c=>{r.current=c?getComputedStyle(c):null,n(c)},[])}}function jc(e){return(e==null?void 0:e.animationName)||"none"}function xO(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 bO=Xm[" useInsertionEffect ".trim().toString()]||Pr;function zS({prop:e,defaultProp:t,onChange:n=()=>{},caller:r}){const[s,i,o]=_O({defaultProp:t,onChange:n}),a=e!==void 0,l=a?e:s;{const u=w.useRef(e!==void 0);w.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=w.useCallback(u=>{var d;if(a){const h=SO(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 _O({defaultProp:e,onChange:t}){const[n,r]=w.useState(e),s=w.useRef(n),i=w.useRef(t);return bO(()=>{i.current=t},[t]),w.useEffect(()=>{var o;s.current!==n&&((o=i.current)==null||o.call(i,n),s.current=n)},[n,s]),[n,r,i]}function SO(e){return typeof e=="function"}var kO=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"}),EO="VisuallyHidden",zd=w.forwardRef((e,t)=>
67f.jsx(it.span,{...e,ref:t,style:{...kO,...e.style}}));zd.displayName=EO;var CO=zd,Qg="ToastProvider",[Zg,TO,AO]=oO("Toast"),[WS,fW]=Hl("Toast",[AO]),[PO,Wd]=WS(Qg),HS=e=>{const{__scopeToast:t,label:n="Notification",duration:r=5e3,swipeDirection:s="right",swipeThreshold:i=50,children:o}=e,[a,l]=w.useState(null),[c,u]=w.useState(0),d=w.useRef(!1),h=w.useRef(!1);return n.trim()||console.error(`Invalid prop \`label\` supplied to \`${Qg}\`. Expected non-empty \`string\`.`),f.jsx(Zg.Provider,{scope:t,children:f.jsx(PO,{scope:t,label:n,duration:r,swipeDirection:s,swipeThreshold:i,toastCount:c,viewport:a,onViewportChange:l,onToastAdd:w.useCallback(()=>u(p=>p+1),[]),onToastRemove:w.useCallback(()=>u(p=>p-1),[]),isFocusedToastEscapeKeyDownRef:d,isClosePausedRef:h,children:o})})};HS.displayName=Qg;var KS="ToastViewport",jO=["F8"],Yp="toast.viewportPause",Gp="toast.viewportResume",qS=w.forwardRef((e,t)=>{const{__scopeToast:n,hotkey:r=jO,label:s="Notifications ({hotkey})",...i}=e,o=Wd(KS,n),a=TO(n),l=w.useRef(null),c=w.useRef(null),u=w.useRef(null),d=w.useRef(null),h=Dt(t,d,o.onViewportChange),p=r.join("+").replace(/Key/g,"").replace(/Digit/g,""),b=o.toastCount>0;w.useEffect(()=>{const x=y=>{var v;r.length!==0&&r.every(_=>y[_]||y.code===_)&&((v=d.current)==null||v.focus())};return document.addEventListener("keydown",x),()=>document.removeEventListener("keydown",x)},[r]),w.useEffect(()=>{const x=l.current,y=d.current;if(b&&x&&y){const m=()=>{if(!o.isClosePausedRef.current){const k=new CustomEvent(Yp);y.dispatchEvent(k),o.isClosePausedRef.current=!0}},v=()=>{if(o.isClosePausedRef.current){const k=new CustomEvent(Gp);y.dispatchEvent(k),o.isClosePausedRef.current=!1}},_=k=>{!x.contains(k.relatedTarget)&&v()},S=()=>{x.contains(document.activeElement)||v()};return x.addEventListener("focusin",m),x.addEventListener("focusout",_),x.addEventListener("pointermove",m),x.addEventListener("pointerleave",S),window.addEventListener("blur",m),window.addEventListener("focus",v),()=>{x.removeEventListener("focusin",m),x.removeEventListener("focusout",_),x.removeEventListener("pointermove",m),x.removeEventListener("pointerleave",S),window.removeEventListener("blur",m),window.removeEventListener("focus",v)}}},[b,o.isClosePausedRef]);const g=w.useCallback(({tabbingDirection:x})=>{const m=a().map(v=>{const _=v.ref.current,S=[_,...zO(_)];return x==="forwards"?S:S.reverse()});return(x==="forwards"?m.reverse():m).flat()},[a]);return w.useEffect(()=>{const x=d.current;if(x){const y=m=>{var S,k,E;const v=m.altKey||m.ctrlKey||m.metaKey;if(m.key==="Tab"&&!v){const T=document.activeElement,P=m.shiftKey;if(m.target===x&&P){(S=c.current)==null||S.focus();return}const I=g({tabbingDirection:P?"backwards":"forwards"}),Z=I.findIndex(R=>R===T);Jf(I.slice(Z+1))?m.preventDefault():P?(k=c.current)==null||k.focus():(E=u.current)==null||E.focus()}};return x.addEventListener("keydown",y),()=>x.removeEventListener("keydown",y)}},[a,g]),f.jsxs(gO,{ref:l,role:"region","aria-label":s.replace("{hotkey}",p),tabIndex:-1,style:{pointerEvents:b?void 0:"none"},children:[b&&f.jsx(Qp,{ref:c,onFocusFromOutsideViewport:()=>{const x=g({tabbingDirection:"forwards"});Jf(x)}}),f.jsx(Zg.Slot,{scope:n,children:f.jsx(it.ol,{tabIndex:-1,...i,ref:h})}),b&&f.jsx(Qp,{ref:u,onFocusFromOutsideViewport:()=>{const x=g({tabbingDirection:"backwards"});Jf(x)}})]})});qS.displayName=KS;var YS="ToastFocusProxy",Qp=w.forwardRef((e,t)=>{const{__scopeToast:n,onFocusFromOutsideViewport:r,...s}=e,i=Wd(YS,n);return f.jsx(zd,{"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()}})});Qp.displayName=YS;var ql="Toast",NO="toast.swipeStart",RO="toast.swipeMove",OO="toast.swipeCancel",MO="toast.swipeEnd",GS=w.forwardRef((e,t)=>{const{forceMount:n,open:r,defaultOpen:s,onOpenChange:i,...o}=e,[a,l]=zS({prop:r,defaultProp:s??!0,onChange:i,caller:ql});return f.jsx(Kl,{present:n||a,children:f.jsx(LO,{open:a,...o,ref:t,onClose:()=>l(!1),onPause:or(e.onPause),onResume:or(e.onResume),onSwipeStart:Oe(e.onSwipeStart,c=>{c.currentTarget.setAttribute("data-swipe","start")}),onSwipeMove:Oe(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:Oe(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:Oe(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)})})})});GS.displayName=ql;var[DO,IO]=WS(ql,{onClose(){}}),LO=w.forwardRef((e,t)=>
67{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:p,...b}=e,g=Wd(ql,n),[x,y]=w.useState(null),m=Dt(t,R=>y(R)),v=w.useRef(null),_=w.useRef(null),S=s||g.duration,k=w.useRef(0),E=w.useRef(S),T=w.useRef(0),{onToastAdd:P,onToastRemove:A}=g,B=or(()=>{var U;(x==null?void 0:x.contains(document.activeElement))&&((U=g.viewport)==null||U.focus()),o()}),I=w.useCallback(R=>{!R||R===1/0||(window.clearTimeout(T.current),k.current=new Date().getTime(),T.current=window.setTimeout(B,R))},[B]);w.useEffect(()=>{const R=g.viewport;if(R){const U=()=>{I(E.current),c==null||c()},V=()=>{const O=new Date().getTime()-k.current;E.current=E.current-O,window.clearTimeout(T.current),l==null||l()};return R.addEventListener(Yp,V),R.addEventListener(Gp,U),()=>{R.removeEventListener(Yp,V),R.removeEventListener(Gp,U)}}},[g.viewport,S,l,c,I]),w.useEffect(()=>{i&&!g.isClosePausedRef.current&&I(S)},[i,S,g.isClosePausedRef,I]),w.useEffect(()=>(P(),()=>A()),[P,A]);const Z=w.useMemo(()=>x?nk(x):null,[x]);return g.viewport?f.jsxs(f.Fragment,{children:[Z&&f.jsx(FO,{__scopeToast:n,role:"status","aria-live":r==="foreground"?"assertive":"polite","aria-atomic":!0,children:Z}),f.jsx(DO,{scope:n,onClose:B,children:Si.createPortal(f.jsx(Zg.ItemSlot,{scope:n,children:f.jsx(mO,{asChild:!0,onEscapeKeyDown:Oe(a,()=>{g.isFocusedToastEscapeKeyDownRef.current||B(),g.isFocusedToastEscapeKeyDownRef.current=!1}),children:f.jsx(it.li,{role:"status","aria-live":"off","aria-atomic":!0,tabIndex:0,"data-state":i?"open":"closed","data-swipe-direction":g.swipeDirection,...b,ref:m,style:{userSelect:"none",touchAction:"none",...e.style},onKeyDown:Oe(e.onKeyDown,R=>{R.key==="Escape"&&(a==null||a(R.nativeEvent),R.nativeEvent.defaultPrevented||(g.isFocusedToastEscapeKeyDownRef.current=!0,B()))}),onPointerDown:Oe(e.onPointerDown,R=>{R.button===0&&(v.current={x:R.clientX,y:R.clientY})}),onPointerMove:Oe(e.onPointerMove,R=>{if(!v.current)return;const U=R.clientX-v.current.x,V=R.clientY-v.current.y,O=!!_.current,C=["left","right"].includes(g.swipeDirection),j=["left","up"].includes(g.swipeDirection)?Math.min:Math.max,$=C?j(0,U):0,Q=C?0:j(0,V),Y=R.pointerType==="touch"?10:2,F={x:$,y:Q},W={originalEvent:R,delta:F};O?(_.current=F,Nc(RO,d,W,{discrete:!1})):K0(F,g.swipeDirection,Y)?(_.current=F,Nc(NO,u,W,{discrete:!1}),R.target.setPointerCapture(R.pointerId)):(Math.abs(U)>Y||Math.abs(V)>Y)&&(v.current=null)}),onPointerUp:Oe(e.onPointerUp,R=>{const U=_.current,V=R.target;if(V.hasPointerCapture(R.pointerId)&&V.releasePointerCapture(R.pointerId),_.current=null,v.current=null,U){const O=R.currentTarget,C={originalEvent:R,delta:U};K0(U,g.swipeDirection,g.swipeThreshold)?Nc(MO,p,C,{discrete:!0}):Nc(OO,h,C,{discrete:!0}),O.addEventListener("click",j=>j.preventDefault(),{once:!0})}})})})}),g.viewport)})]}):null}),FO=e=>{const{__scopeToast:t,children:n,...r}=e,s=Wd(ql,t),[i,o]=w.useState(!1),[a,l]=w.useState(!1);return VO(()=>o(!0)),w.useEffect(()=>{const c=window.setTimeout(()=>l(!0),1e3);return()=>window.clearTimeout(c)},[]),a?null:f.jsx(Gg,{asChild:!0,children:f.jsx(zd,{...r,children:i&&f.jsxs(f.Fragment,{children:[s.label," ",n]})})})},$O="ToastTitle",QS=w.forwardRef((e,t)=>{const{__scopeToast:n,...r}=e;return f.jsx(it.div,{...r,ref:t})});QS.displayName=$O;var BO="ToastDescription",ZS=w.forwardRef((e,t)=>{const{__scopeToast:n,...r}=e;return f.jsx(it.div,{...r,ref:t})});ZS.displayName=BO;var JS="ToastAction",XS=w.forwardRef((e,t)=>{const{altText:n,...r}=e;return n.trim()?f.jsx(tk,{altText:n,asChild:!0,children:f.jsx(Jg,{...r,ref:t})}):(console.error(`Invalid prop \`altText\` supplied to \`${JS}\`. Expected non-empty \`string\`.`),null)});XS.displayName=JS;var ek="ToastClose",Jg=w.forwardRef((e,t)=>{const{__scopeToast:n,...r}=e,s=IO(ek,n);return f.jsx(tk,{asChild:!0,children:f.jsx(it.button,{type:"button",...r,ref:t,onClick:Oe(e.onClick,s.onClose)})})});Jg.displayName=ek;var tk=w.forwardRef((e,t)=>{const{__scopeToast:n,altText:r,...s}=e;return f.jsx(it.div,{"data-radix-toast-announce-exclude":"","data-radix-toast-announce-alt":r||void 0,...s,ref:t})});function nk(e){const t=[];
vendor: 5,787 bytes, lines 67-121
67return Array.from(e.childNodes).forEach(r=>{if(r.nodeType===r.TEXT_NODE&&r.textContent&&t.push(r.textContent),UO(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(...nk(r))}}),t}function Nc(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?$S(s,i):s.dispatchEvent(i)}var K0=(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 VO(e=()=>{}){const t=or(e);Pr(()=>{let n=0,r=0;return n=window.requestAnimationFrame(()=>r=window.requestAnimationFrame(t)),()=>{window.cancelAnimationFrame(n),window.cancelAnimationFrame(r)}},[t])}function UO(e){return e.nodeType===e.ELEMENT_NODE}function zO(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 Jf(e){const t=document.activeElement;return e.some(n=>n===t?!0:(n.focus(),document.activeElement!==t))}var WO=HS,rk=qS,sk=GS,ik=QS,ok=ZS,ak=XS,lk=Jg;function ck(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=ck(e[t]))&&(r&&(r+=" "),r+=n)}else for(n in e)e[n]&&(r&&(r+=" "),r+=n);return r}function uk(){for(var e,t,n=0,r="",s=arguments.length;n<s;n++)(e=arguments[n])&&(t=ck(e))&&(r&&(r+=" "),r+=t);return r}const q0=e=>typeof e=="boolean"?`${e}`:e===0?"0":e,Y0=uk,dk=(e,t)=>n=>{var r;if((t==null?void 0:t.variants)==null)return Y0(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=q0(u)||q0(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,...p}=u;return Object.entries(p).every(b=>{let[g,x]=b;return Array.isArray(x)?x.includes({...i,...a}[g]):{...i,...a}[g]===x})?[...c,d,h]:c},[]);return Y0(e,o,l,n==null?void 0:n.class,n==null?void 0:n.className)};/**
68 * @license lucide-react v0.462.0 - ISC
69 *
70 * This source code is licensed under the ISC license.
71 * See the LICENSE file in the root directory of this source tree.
72 */const HO=e=>e.replace(/([a-z0-9])([A-Z])/g,"$1-$2").toLowerCase(),fk=(...e)=>e.filter((t,n,r)=>!!t&&t.trim()!==""&&r.indexOf(t)===n).join(" ").trim();/**
73 * @license lucide-react v0.462.0 - ISC
74 *
75 * This source code is licensed under the ISC license.
76 * See the LICENSE file in the root directory of this source tree.
77 */var KO={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"};/**
78 * @license lucide-react v0.462.0 - ISC
79 *
80 * This source code is licensed under the ISC license.
81 * See the LICENSE file in the root directory of this source tree.
82 */const qO=w.forwardRef(({color:e="currentColor",size:t=24,strokeWidth:n=2,absoluteStrokeWidth:r,className:s="",children:i,iconNode:o,...a},l)=>w.createElement("svg",{ref:l,...KO,width:t,height:t,stroke:e,strokeWidth:r?Number(n)*24/Number(t):n,className:fk("lucide",s),...a},[...o.map(([c,u])=>w.createElement(c,u)),...Array.isArray(i)?i:[i]]));/**
83 * @license lucide-react v0.462.0 - ISC
84 *
85 * This source code is licensed under the ISC license.
86 * See the LICENSE file in the root directory of this source tree.
87 */const Yt=(e,t)=>{const n=w.forwardRef(({className:r,...s},i)=>w.createElement(qO,{ref:i,iconNode:t,className:fk(`lucide-${HO(e)}`,r),...s}));return n.displayName=`${e}`,n};/**
88 * @license lucide-react v0.462.0 - ISC
89 *
90 * This source code is licensed under the ISC license.
91 * See the LICENSE file in the root directory of this source tree.
92 */const hk=Yt("Calendar",[["path",{d:"M8 2v4",key:"1cmpym"}],["path",{d:"M16 2v4",key:"4m81vk"}],["rect",{width:"18",height:"18",x:"3",y:"4",rx:"2",key:"1hopcy"}],["path",{d:"M3 10h18",key:"8toen8"}]]);/**
93 * @license lucide-react v0.462.0 - ISC
94 *
95 * This source code is licensed under the ISC license.
96 * See the LICENSE file in the root directory of this source tree.
97 */const YO=Yt("Check",[["path",{d:"M20 6 9 17l-5-5",key:"1gmf2c"}]]);/**
98 * @license lucide-react v0.462.0 - ISC
99 *
100 * This source code is licensed under the ISC license.
101 * See the LICENSE file in the root directory of this source tree.
102 */const G0=Yt("ChevronDown",[["path",{d:"m6 9 6 6 6-6",key:"qrunsl"}]]);/**
103 * @license lucide-react v0.462.0 - ISC
104 *
105 * This source code is licensed under the ISC license.
106 * See the LICENSE file in the root directory of this source tree.
107 */const GO=Yt("ChevronLeft",[["path",{d:"m15 18-6-6 6-6",key:"1wnfg3"}]]);/**
108 * @license lucide-react v0.462.0 - ISC
109 *
110 * This source code is licensed under the ISC license.
111 * See the LICENSE file in the root directory of this source tree.
112 */const QO=Yt("ChevronRight",[["path",{d:"m9 18 6-6-6-6",key:"mthhwq"}]]);/**
113 * @license lucide-react v0.462.0 - ISC
114 *
115 * This source code is licensed under the ISC license.
116 * See the LICENSE file in the root directory of this source tree.
117 */const ZO=Yt("Clock",[["circle",{cx:"12",cy:"12",r:"10",key:"1mglay"}],["polyline",{points:"12 6 12 12 16 14",key:"68esgv"}]]);/**
118 * @license lucide-react v0.462.0 - ISC
119 *
120 * This source code is licensed under the ISC license.
121 * See the LICENSE file in the root directory of this source tree.
vendor: 9,781 bytes, lines 122-152
122 */const JO=Yt("Copy",[["rect",{width:"14",height:"14",x:"8",y:"8",rx:"2",ry:"2",key:"17jyea"}],["path",{d:"M4 16c-1.1 0-2-.9-2-2V4c0-1.1.9-2 2-2h10c1.1 0 2 .9 2 2",key:"zix9uf"}]]);/**
123 * @license lucide-react v0.462.0 - ISC
124 *
125 * This source code is licensed under the ISC license.
126 * See the LICENSE file in the root directory of this source tree.
127 */const pk=Yt("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"}]]);/**
128 * @license lucide-react v0.462.0 - ISC
129 *
130 * This source code is licensed under the ISC license.
131 * See the LICENSE file in the root directory of this source tree.
132 */const Xf=Yt("Heart",[["path",{d:"M19 14c1.49-1.46 3-3.21 3-5.5A5.5 5.5 0 0 0 16.5 3c-1.76 0-3 .5-4.5 2-1.5-1.5-2.74-2-4.5-2A5.5 5.5 0 0 0 2 8.5c0 2.3 1.5 4.05 3 5.5l7 7Z",key:"c3ymky"}]]);/**
133 * @license lucide-react v0.462.0 - ISC
134 *
135 * This source code is licensed under the ISC license.
136 * See the LICENSE file in the root directory of this source tree.
137 */const XO=Yt("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"}]]);/**
138 * @license lucide-react v0.462.0 - ISC
139 *
140 * This source code is licensed under the ISC license.
141 * See the LICENSE file in the root directory of this source tree.
142 */const Qu=Yt("RotateCcw",[["path",{d:"M3 12a9 9 0 1 0 9-9 9.75 9.75 0 0 0-6.74 2.74L3 8",key:"1357e3"}],["path",{d:"M3 3v5h5",key:"1xhq8a"}]]);/**
143 * @license lucide-react v0.462.0 - ISC
144 *
145 * This source code is licensed under the ISC license.
146 * See the LICENSE file in the root directory of this source tree.
147 */const mk=Yt("Trash2",[["path",{d:"M3 6h18",key:"d0wm0j"}],["path",{d:"M19 6v14c0 1-1 2-2 2H7c-1 0-2-1-2-2V6",key:"4alrt4"}],["path",{d:"M8 6V4c0-1 1-2 2-2h4c1 0 2 1 2 2v2",key:"v07s0e"}],["line",{x1:"10",x2:"10",y1:"11",y2:"17",key:"1uufr5"}],["line",{x1:"14",x2:"14",y1:"11",y2:"17",key:"xtxkd"}]]);/**
148 * @license lucide-react v0.462.0 - ISC
149 *
150 * This source code is licensed under the ISC license.
151 * See the LICENSE file in the root directory of this source tree.
152 */const Xg=Yt("X",[["path",{d:"M18 6 6 18",key:"1bl5f8"}],["path",{d:"m6 6 12 12",key:"d8bk6v"}]]),ev="-",e2=e=>{const t=n2(e),{conflictingClassGroups:n,conflictingClassGroupModifiers:r}=e;return{getClassGroupId:o=>{const a=o.split(ev);return a[0]===""&&a.length!==1&&a.shift(),gk(a,t)||t2(o)},getConflictingClassGroupIds:(o,a)=>{const l=n[o]||[];return a&&r[o]?[...l,...r[o]]:l}}},gk=(e,t)=>{var o;if(e.length===0)return t.classGroupId;const n=e[0],r=t.nextPart.get(n),s=r?gk(e.slice(1),r):void 0;if(s)return s;if(t.validators.length===0)return;const i=e.join(ev);return(o=t.validators.find(({validator:a})=>a(i)))==null?void 0:o.classGroupId},Q0=/^\[(.+)\]$/,t2=e=>{if(Q0.test(e)){const t=Q0.exec(e)[1],n=t==null?void 0:t.substring(0,t.indexOf(":"));if(n)return"arbitrary.."+n}},n2=e=>{const{theme:t,prefix:n}=e,r={nextPart:new Map,validators:[]};return s2(Object.entries(e.classGroups),n).forEach(([i,o])=>{Zp(o,r,i,t)}),r},Zp=(e,t,n,r)=>{e.forEach(s=>{if(typeof s=="string"){const i=s===""?t:Z0(t,s);i.classGroupId=n;return}if(typeof s=="function"){if(r2(s)){Zp(s(r),t,n,r);return}t.validators.push({validator:s,classGroupId:n});return}Object.entries(s).forEach(([i,o])=>{Zp(o,Z0(t,i),n,r)})})},Z0=(e,t)=>{let n=e;return t.split(ev).forEach(r=>{n.nextPart.has(r)||n.nextPart.set(r,{nextPart:new Map,validators:[]}),n=n.nextPart.get(r)}),n},r2=e=>e.isThemeGetter,s2=(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,i2=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)}}},vk="!",o2=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 y=a[x];if(c===0){if(y===s&&(r||a.slice(x,x+i)===t)){l.push(a.slice(u,x)),u=x+i;continue}if(y==="/"){d=x;continue}}y==="["?c++:y==="]"&&c--}const h=l.length===0?a:a.substring(u),p=h.startsWith(vk),b=p?h.substring(1):h,g=d&&d>u?d-u:void 0;return{modifiers:l,hasImportantModifier:p,baseClassName:b,maybePostfixModifierPosition:g}};return n?a=>n({className:a,parseClassName:o}):o},a2=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},l2=e=>({cache:i2(e.cacheSize),parseClassName:o2(e),...e2(e)}),c2=/\s+/,u2=(e,t)=>{const{parseClassName:n,getClassGroupId:r,getConflictingClassGroupIds:s}=t,i=[],o=e.trim().split(c2);let a="";for(let l=o.length-1;l>=0;l-=1){const c=o[l],{modifiers:u,hasImportantModifier:d,baseClassName:h,maybePostfixModifierPosition:p}=n(c);let b=!!p,g=r(b?h.substring(0,p):h);if(!g){if(!b){a=c+(a.length>0?" "+a:a);continue}if(g=r(h),!g){a=c+(a.length>0?" "+a:a);continue}b=!1}const x=a2(u).join(":"),y=d?x+vk:x,m=y+g;if(i.includes(m))continue;i.push(m);const v=s(g,b);for(let _=0;_<v.length;++_){const S=v[_];i.push(y+S)}a=c+(a.length>0?" "+a:a)}return a};function d2(){let e=0,t,n,r="";for(;e<arguments.length;)(t=arguments[e++])&&(n=yk(t))&&(r&&(r+=" "),r+=n);return r}const yk=e=>{if(typeof e=="string")return e;let t,n="";for(let r=0;r<e.length;r++)e[r]&&(t=yk(e[r]))&&(n&&(n+=" "),n+=t);return n};function f2(e,...t){let n,r,s,i=o;function o(l){const c=t.reduce((u,d)=>d(u),e());return n=l2(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=u2(l,n);return s(l,u),u}return function(){return i(d2.apply(null,arguments))}}const Ee=e=>{const t=n=>n[e]||[];return t.isThemeGetter=!0,t},wk=/^\[(?:([a-z-]+):)?(.+)\]$/i,h2=/^\d+\/\d+$/,p2=new Set(["px","full","screen"]),m2=/^(\d+(\.\d+)?)?(xs|sm|md|lg|xl)$/,g2=/\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$/,v2=/^(rgba?|hsla?|hwb|(ok)?(lab|lch))\(.+\)$/,y2=/^(inset_)?-?((\d+)?\.?(\d+)[a-z]+|0)_-?((\d+)?\.?(\d+)[a-z]+|0)/,w2=/^(url|image|image-set|cross-fade|element|(repeating-)?(linear|radial|conic)-gradient)\(.+\)$/,mr=e=>yo(e)||p2.has(e)||h2.test(e),Lr=e=>Xo(e,"length",T2),yo=e=>!!e&&!Number.isNaN(Number(e)),eh=e=>Xo(e,"number",yo),wa=e=>!!e&&Number.isInteger(Number(e)),x2=e=>e.endsWith("%")&&yo(e.slice(0,-1)),ae=e=>wk.test(e),Fr=e=>m2.test(e),b2=new Set(["length","size","percentage"]),_2=e=>Xo(e,b2,xk),S2=e=>Xo(e,"position",xk),k2=new Set(["image","url"]),E2=e=>Xo(e,k2,P2),C2=e=>Xo(e,"",A2),xa=()=>!0,Xo=(e,t,n)=>{const r=wk.exec(e);return r?r[1]?typeof t=="string"?r[1]===t:t.has(r[1]):n(r[2]):!1},T2=e=>g2.test(e)&&!v2.test(e),xk=()=>!1,A2=e=>y2.test(e),P2=e=>w2.test(e),j2=()=>{const e=Ee("colors"),t=Ee("spacing"),n=Ee("blur"),r=Ee("brightness"),s=Ee("borderColor"),i=Ee("borderRadius"),o=Ee("borderSpacing"),a=Ee("borderWidth"),l=Ee("contrast"),c=Ee("grayscale"),u=Ee("hueRotate"),d=Ee("invert"),h=Ee("gap"),p=Ee("gradientColorStops"),b=Ee("gradientColorStopPositions"),g=Ee("inset"),x=Ee("margin"),y=Ee("opacity"),m=Ee("padding"),v=Ee("saturate"),_=Ee("scale"),S=Ee("sepia"),k=Ee("skew"),E=Ee("space"),T=Ee("translate"),P=()=>["auto","contain","none"],A=()=>["auto","hidden","clip","visible","scroll"],B=()=>["auto",ae,t],I=()=>[ae,t],Z=()=>["",mr,Lr],R=()=>["auto",yo,ae],U=()=>["bottom","center","left","left-bottom","left-top","right","right-bottom","right-top","top"],V=()=>["solid","dashed","dotted","double","none"],O=()=>["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"],j=()=>["","0",ae],$=()=>["auto","avoid","all","avoid-page","page","left","right","column"],Q=()=>[yo,ae];return{cacheSize:500,separator:":",theme:{colors:[xa],spacing:[mr,Lr],blur:["none","",Fr,ae],brightness:Q(),borderColor:[e],borderRadius:["none","","full",Fr,ae],borderSpacing:I(),borderWidth:Z(),contrast:Q(),grayscale:j(),hueRotate:Q(),invert:j(),gap:I(),gradientColorStops:[e],gradientColorStopPositions:[x2,Lr],inset:B(),margin:B(),opacity:Q(),padding:I(),saturate:Q(),scale:Q(),sepia:j(),skew:Q(),space:I(),translate:I()},classGroups:{aspect:[{aspect:["auto","square","video",ae]}],container:["container"],columns:[{columns:[Fr]}],"break-after":[{"break-after":$()}],"break-before":[{"break-before":$()}],"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:[...U(),ae]}],overflow:[{overflow:A()}],"overflow-x":[{"overflow-x":A()}],"overflow-y":[{"overflow-y":A()}],overscroll:[{overscroll:P()}],"overscroll-x":[{"overscroll-x":P()}],"overscroll-y":[{"overscroll-y":P()}],position:["static","fixed","absolute","relative","sticky"],inset:[{inset:[g]}],"inset-x":[{"inset-x":[g]}],"inset-y":[{"inset-y":[g]}],start:[{start:[g]}],end:[{end:[g]}],top:[{top:[g]}
vendor: 4,767 bytes, line 152
152],right:[{right:[g]}],bottom:[{bottom:[g]}],left:[{left:[g]}],visibility:["visible","invisible","collapse"],z:[{z:["auto",wa,ae]}],basis:[{basis:B()}],"flex-direction":[{flex:["row","row-reverse","col","col-reverse"]}],"flex-wrap":[{flex:["wrap","wrap-reverse","nowrap"]}],flex:[{flex:["1","auto","initial","none",ae]}],grow:[{grow:j()}],shrink:[{shrink:j()}],order:[{order:["first","last","none",wa,ae]}],"grid-cols":[{"grid-cols":[xa]}],"col-start-end":[{col:["auto",{span:["full",wa,ae]},ae]}],"col-start":[{"col-start":R()}],"col-end":[{"col-end":R()}],"grid-rows":[{"grid-rows":[xa]}],"row-start-end":[{row:["auto",{span:[wa,ae]},ae]}],"row-start":[{"row-start":R()}],"row-end":[{"row-end":R()}],"grid-flow":[{"grid-flow":["row","col","dense","row-dense","col-dense"]}],"auto-cols":[{"auto-cols":["auto","min","max","fr",ae]}],"auto-rows":[{"auto-rows":["auto","min","max","fr",ae]}],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:[m]}],px:[{px:[m]}],py:[{py:[m]}],ps:[{ps:[m]}],pe:[{pe:[m]}],pt:[{pt:[m]}],pr:[{pr:[m]}],pb:[{pb:[m]}],pl:[{pl:[m]}],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",ae,t]}],"min-w":[{"min-w":[ae,t,"min","max","fit"]}],"max-w":[{"max-w":[ae,t,"none","full","min","max","fit","prose",{screen:[Fr]},Fr]}],h:[{h:[ae,t,"auto","min","max","fit","svh","lvh","dvh"]}],"min-h":[{"min-h":[ae,t,"min","max","fit","svh","lvh","dvh"]}],"max-h":[{"max-h":[ae,t,"min","max","fit","svh","lvh","dvh"]}],size:[{size:[ae,t,"auto","min","max","fit"]}],"font-size":[{text:["base",Fr,Lr]}],"font-smoothing":["antialiased","subpixel-antialiased"],"font-style":["italic","not-italic"],"font-weight":[{font:["thin","extralight","light","normal","medium","semibold","bold","extrabold","black",eh]}],"font-family":[{font:[xa]}],"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",ae]}],"line-clamp":[{"line-clamp":["none",yo,eh]}],leading:[{leading:["none","tight","snug","normal","relaxed","loose",mr,ae]}],"list-image":[{"list-image":["none",ae]}],"list-style-type":[{list:["none","disc","decimal",ae]}],"list-style-position":[{list:["inside","outside"]}],"placeholder-color":[{placeholder:[e]}],"placeholder-opacity":[{"placeholder-opacity":[y]}],"text-alignment":[{text:["left","center","right","justify","start","end"]}],"text-color":[{text:[e]}],"text-opacity":[{"text-opacity":[y]}],"text-decoration":["underline","overline","line-through","no-underline"],"text-decoration-style":[{decoration:[...V(),"wavy"]}],"text-decoration-thickness":[{decoration:["auto","from-font",mr,Lr]}],"underline-offset":[{"underline-offset":["auto",mr,ae]}],"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:I()}],"vertical-align":[{align:["baseline","top","middle","bottom","text-top","text-bottom","sub","super",ae]}],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",ae]}],"bg-attachment":[{bg:["fixed","local","scroll"]}],"bg-clip":[{"bg-clip":["border","padding","content","text"]}],"bg-opacity":[{"bg-opacity":[y]}],"bg-origin":[{"bg-origin":["border","padding","content"]}],"bg-position":[{bg:[...U(),S2]}],"bg-repeat":[{bg:["no-repeat",{repeat:["","x","y","round","space"]}]}],"bg-size":[{bg:["auto","cover","contain",_2]}],"bg-image":[{bg:["none",{"gradient-to":["t","tr","r","br","b","bl","l","tl"]},E2]}],"bg-color":[{bg:[e]}],"gradient-from-pos":[{from:[b]}
152],"gradient-via-pos":[{via:[b]}],"gradient-to-pos":[{to:[b]}],"gradient-from":[{from:[p]}],"gradient-via":[{via:[p]}],"gradient-to":[{to:[p]}],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":[y]}],"border-style":[{border:[...V(),"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":[y]}
vendor: 4,467 bytes, line 152
152],"divide-style":[{divide:V()}],"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:["",...V()]}],"outline-offset":[{"outline-offset":[mr,ae]}],"outline-w":[{outline:[mr,Lr]}],"outline-color":[{outline:[e]}],"ring-w":[{ring:Z()}],"ring-w-inset":["ring-inset"],"ring-color":[{ring:[e]}],"ring-opacity":[{"ring-opacity":[y]}],"ring-offset-w":[{"ring-offset":[mr,Lr]}],"ring-offset-color":[{"ring-offset":[e]}],shadow:[{shadow:["","inner","none",Fr,C2]}],"shadow-color":[{shadow:[xa]}],opacity:[{opacity:[y]}],"mix-blend":[{"mix-blend":[...O(),"plus-lighter","plus-darker"]}],"bg-blend":[{"bg-blend":O()}],filter:[{filter:["","none"]}],blur:[{blur:[n]}],brightness:[{brightness:[r]}],contrast:[{contrast:[l]}],"drop-shadow":[{"drop-shadow":["","none",Fr,ae]}],grayscale:[{grayscale:[c]}],"hue-rotate":[{"hue-rotate":[u]}],invert:[{invert:[d]}],saturate:[{saturate:[v]}],sepia:[{sepia:[S]}],"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":[y]}],"backdrop-saturate":[{"backdrop-saturate":[v]}],"backdrop-sepia":[{"backdrop-sepia":[S]}],"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",ae]}],duration:[{duration:Q()}],ease:[{ease:["linear","in","out","in-out",ae]}],delay:[{delay:Q()}],animate:[{animate:["none","spin","ping","pulse","bounce",ae]}],transform:[{transform:["","gpu","none"]}],scale:[{scale:[_]}],"scale-x":[{"scale-x":[_]}],"scale-y":[{"scale-y":[_]}],rotate:[{rotate:[wa,ae]}],"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",ae]}],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",ae]}],"caret-color":[{caret:[e]}],"pointer-events":[{"pointer-events":["none","auto"]}],resize:[{resize:["none","y","x",""]}],"scroll-behavior":[{scroll:["auto","smooth"]}],"scroll-m":[{"scroll-m":I()}],"scroll-mx":[{"scroll-mx":I()}],"scroll-my":[{"scroll-my":I()}],"scroll-ms":[{"scroll-ms":I()}],"scroll-me":[{"scroll-me":I()}],"scroll-mt":[{"scroll-mt":I()}],"scroll-mr":[{"scroll-mr":I()}],"scroll-mb":[{"scroll-mb":I()}],"scroll-ml":[{"scroll-ml":I()}],"scroll-p":[{"scroll-p":I()}],"scroll-px":[{"scroll-px":I()}],"scroll-py":[{"scroll-py":I()}],"scroll-ps":[{"scroll-ps":I()}],"scroll-pe":[{"scroll-pe":I()}],"scroll-pt":[{"scroll-pt":I()}],"scroll-pr":[{"scroll-pr":I()}],"scroll-pb":[{"scroll-pb":I()}],"scroll-pl":[{"scroll-pl":I()}],"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"]}],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",ae]}],fill:[{fill:[e,"none"]}],"stroke-w":[{stroke:[mr,Lr,eh]}],stroke:[{stroke:[e,"none"]}],sr:["sr-only","not-sr-only"],"forced-color-adjust":[{"forced-color-adjust":["auto","
152none"]}]},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"]}}},N2=f2(j2);function Te(...e){return N2(uk(e))}const R2=WO,bk=w.forwardRef(({className:e,...t},n)=>f.jsx(rk,{ref:n,className:Te("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}));bk.displayName=rk.displayName;const O2=dk("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"}}),_k=w.forwardRef(({className:e,variant:t,...n},r)=>f.jsx(sk,{ref:r,className:Te(O2({variant:t}),e),...n}));_k.displayName=sk.displayName;const M2=w.forwardRef(({className:e,...t},n)=>f.jsx(ak,{ref:n,className:Te("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}));M2.displayName=ak.displayName;const Sk=w.forwardRef(({className:e,...t},n)=>f.jsx(lk,{ref:n,className:Te("absolute right-2 top-2 rounded-md p-1 text-foreground
152/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:f.jsx(Xg,{className:"h-4 w-4"})}));Sk.displayName=lk.displayName;const kk=w.forwardRef(({className:e,...t},n)=>f.jsx(ik,{ref:n,className:Te("text-sm font-semibold",e),...t}));kk.displayName=ik.displayName;const Ek=w.forwardRef(({className:e,...t},n)=>f.jsx(ok,{ref:n,className:Te("text-sm opacity-90",e),...t}));Ek.displayName=ok.displayName;function D2(){const{toasts:e}=Wl();return f.jsxs(R2,{children:[e.map(function({id:t,title:n,description:r,action:s,...i}){return f.jsxs(_k,{...i,children:[f.jsxs("div",{className:"grid gap-1",children:[n&&f.jsx(kk,{children:n}),r&&f.jsx(Ek,{children:r})]}),s,f.jsx(Sk,{})]},t)}),f.jsx(bk,{})]})}var J0=["light","dark"],I2="(prefers-color-scheme: dark)",L2=w.createContext(void 0),F2={setTheme:e=>{},themes:[]},$2=()=>{var e;return(e=w.useContext(L2))!=null?e:F2};w.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(b=>`'${b}'`).join(",")})`};`:`var d=document.documentElement,n='${n}',s='setAttribute';`,d=s?J0.includes(i)&&i?`if(e==='light'||e==='dark'||!e)d.style.colorScheme=e||'${i}'`:"if(e==='light'||e==='dark')d.style.colorScheme=e":"",h=(b,g=!1,x=!0)=>{let y=o?o[b]:b,m=g?b+"|| ''":`'${y}'`,v="";return s&&x&&!g&&J0.includes(b)&&(v+=`d.style.colorScheme = '${b}';`),n==="class"?g||y?v+=`c.add(${m})`:v+="null":y&&(v+=`d[s](n,${m})`),v},p=e?`!function(){${u}${h(e)}}()`:r?`!function(){try{${u}var e=localStorage.getItem('${t}');if('system'===e||(!e&&${c})){var t='${I2}',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 w.createElement("script",{nonce:l,dangerouslySetInnerHTML:{__html:p}})});var B2=e=>{switch(e){case"success":return z2;case"info":return H2;
152case"warning":return W2;case"error":return K2;default:return null}},V2=Array(12).fill(0),U2=({visible:e,className:t})=>D.createElement("div",{className:["sonner-loading-wrapper",t].filter(Boolean).join(" "),"data-visible":e},D.createElement("div",{className:"sonner-spinner"},V2.map((n,r)=>D.createElement("div",{className:"sonner-loading-bar",key:`spinner-bar-${r}`})))),z2=D.createElement("svg",{xmlns:"http://www.w3.org/2000/svg",viewBox:"0 0 20 20",fill:"currentColor",height:"20",width:"20"},D.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"})),W2=D.createElement("svg",{xmlns:"http://www.w3.org/2000/svg",viewBox:"0 0 24 24",fill:"currentColor",height:"20",width:"20"},D.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"})),H2=D.createElement("svg",{xmlns:"http://www.w3.org/2000/svg",viewBox:"0 0 20 20",fill:"currentColor",height:"20",width:"20"},D.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"})),K2=D.createElement("svg",{xmlns:"http://www.w3.org/2000/svg",viewBox:"0 0 20 20",fill:"currentColor",height:"20",width:"20"},D.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"})),q2=D.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"},D.createElement("line",{x1:"18",y1:"6",x2:"6",y2:"18"}),D.createElement("line",{x1:"6",y1:"6",x2:"18",y2:"18"})),Y2=()=>{let[e,t]=D.useState(document.hidden);return D.useEffect(()=>{let n=()=>{t(document.hidden)};return document.addEventListener("visibilitychange",n),()=>window.removeEventListener("visibilitychange",n)},[]),e},Jp=1,G2=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:Jp++,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)=>
152this.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],D.isValidElement(l))s=!1,this.create({id:n,type:"default",message:l});else if(Z2(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)||Jp++;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}},kt=new G2,Q2=(e,t)=>{let n=(t==null?void 0:t.id)||Jp++;return kt.addToast({title:e,...t,id:n}),n},Z2=e=>e&&typeof e=="object"&&"ok"in e&&typeof e.ok=="boolean"&&"status"in e&&typeof e.status=="number",J2=Q2,X2=()=>kt.toasts,eM=()=>kt.getActiveToasts(),Ne=Object.assign(J2,{success:kt.success,info:kt.info,warning:kt.warning,error:kt.error,custom:kt.custom,message:kt.message,promise:kt.promise,dismiss:kt.dismiss,loading:kt.loading},{getHistory:X2,getToasts:eM});function tM(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))}tM(`: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;
152left: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}
152: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%);
152--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%)}
153`);function Rc(e){return e.label!==void 0}var nM=3,rM="32px",sM="16px",X0=4e3,iM=356,oM=14,aM=20,lM=200;function gn(...e){return e.filter(Boolean).join(" ")}function cM(e){let[t,n]=e.split("-"),r=[];return t&&r.push(t),n&&r.push(n),r}var uM=e=>{var t,n,r,s,i,o,a,l,c,u,d;let{invert:h,toast:p,unstyled:b,interacting:g,setHeights:x,visibleToasts:y,heights:m,index:v,toasts:_,expanded:S,removeToast:k,defaultRichColors:E,closeButton:T,style:P,cancelButtonStyle:A,actionButtonStyle:B,className:I="",descriptionClassName:Z="",duration:R,position:U,gap:V,loadingIcon:O,expandByDefault:C,classNames:j,icons:$,closeButtonAriaLabel:Q="Close toast",pauseWhenPageIsHidden:Y}=e,[F,W]=D.useState(null),[le,xe]=D.useState(null),[te,$n]=D.useState(!1),[Gt,Qt]=D.use
153State(!1),[ot,It]=D.useState(!1),[Zt,fr]=D.useState(!1),[aa,Ci]=D.useState(!1),[Ds,Is]=D.useState(0),[hr,ac]=D.useState(0),Ti=D.useRef(p.duration||R||X0),la=D.useRef(null),Bn=D.useRef(null),mf=v===0,fA=v+1<=y,Jt=p.type,Ai=p.dismissible!==!1,hA=p.className||"",pA=p.descriptionClassName||"",lc=D.useMemo(()=>m.findIndex(ie=>ie.toastId===p.id)||0,[m,p.id]),mA=D.useMemo(()=>{var ie;return(ie=p.closeButton)!=null?ie:T},[p.closeButton,T]),cy=D.useMemo(()=>p.duration||R||X0,[p.duration,R]),gf=D.useRef(0),Pi=D.useRef(0),uy=D.useRef(0),ji=D.useRef(null),[gA,vA]=U.split("-"),dy=D.useMemo(()=>m.reduce((ie,we,je)=>je>=lc?ie:ie+we.height,0),[m,lc]),fy=Y2(),yA=p.invert||h,vf=Jt==="loading";Pi.current=D.useMemo(()=>lc*V+dy,[lc,dy]),D.useEffect(()=>{Ti.current=cy},[cy]),D.useEffect(()=>{$n(!0)},[]),D.useEffect(()=>{let ie=Bn.current;if(ie){let we=ie.getBoundingClientRect().height;return ac(we),x(je=>[{toastId:p.id,height:we,position:p.position},...je]),()=>x(je=>je.filter(fn=>fn.toastId!==p.id))}},[x,p.id]),D.useLayoutEffect(()=>{if(!te)return;let ie=Bn.current,we=ie.style.height;ie.style.height="auto";let je=ie.getBoundingClientRect().height;ie.style.height=we,ac(je),x(fn=>fn.find(hn=>hn.toastId===p.id)?fn.map(hn=>hn.toastId===p.id?{...hn,height:je}:hn):[{toastId:p.id,height:je,position:p.position},...fn])},[te,p.title,p.description,x,p.id]);let Or=D.useCallback(()=>{Qt(!0),Is(Pi.current),x(ie=>ie.filter(we=>we.toastId!==p.id)),setTimeout(()=>{k(p)},lM)},[p,k,x,Pi]);D.useEffect(()=>{if(p.promise&&Jt==="loading"||p.duration===1/0||p.type==="loading")return;let ie;return S||g||Y&&fy?(()=>{if(uy.current<gf.current){let we=new Date().getTime()-gf.current;Ti.current=Ti.current-we}uy.current=new Date().getTime()})():Ti.current!==1/0&&(gf.current=new Date().getTime(),ie=setTimeout(()=>{var we;(we=p.onAutoClose)==null||we.call(p,p),Or()},Ti.current)),()=>clearTimeout(ie)},[S,g,p,Jt,Y,fy,Or]),D.useEffect(()=>{p.delete&&Or()},[Or,p.delete]);function wA(){var ie,we,je;return $!=null&&$.loading?D.createElement("div",{className:gn(j==null?void 0:j.loader,(ie=p==null?void 0:p.classNames)==null?void 0:ie.loader,"sonner-loader"),"data-visible":Jt==="loading"},$.loading):O?D.createElement("div",{className:gn(j==null?void 0:j.loader,(we=p==null?void 0:p.classNames)==null?void 0:we.loader,"sonner-loader"),"data-visible":Jt==="loading"},O):D.createElement(U2,{className:gn(j==null?void 0:j.loader,(je=p==null?void 0:p.classNames)==null?void 0:je.loader),visible:Jt==="loading"})}return D.createElement("li",{tabIndex:0,ref:Bn,className:gn(I,hA,j==null?void 0:j.toast,(t=p==null?void 0:p.classNames)==null?void 0:t.toast,j==null?void 0:j.default,j==null?void 0:j[Jt],(n=p==null?void 0:p.classNames)==null?void 0:n[Jt]),"data-sonner-toast":"","data-rich-colors":(r=p.richColors)!=null?r:E,"data-styled":!(p.jsx||p.unstyled||b),"data-mounted":te,"data-promise":!!p.promise,"data-swiped":aa,"data-removed":Gt,"data-visible":fA,"data-y-position":gA,"data-x-position":vA,"data-index":v,"data-front":mf,"data-swiping":ot,"data-dismissible":Ai,"data-type":Jt,"data-invert":yA,"data-swipe-out":Zt,"data-swipe-direction":le,"data-expanded":!!(S||C&&te),style:{"--index":v,"--toasts-before":v,"--z-index":_.length-v,"--offset":`${Gt?Ds:Pi.current}px`,"--initial-height":C?"auto":`${hr}px`,...P,...p.style},onDragEnd:()=>{It(!1),W(null),ji.current=null},onPointerDown:ie=>{vf||!Ai||(la.current=new Date,Is(Pi.current),ie.target.setPointerCapture(ie.pointerId),ie.target.tagName!=="BUTTON"&&(It(!0),ji.current={x:ie.clientX,y:ie.clientY}))},onPointerUp:()=>{var ie,we,je,fn;if(Zt||!Ai)return;ji.current=null;let hn=Number(((ie=Bn.current)==null?void 0:ie.style.getPropertyValue("--swipe-amount-x").replace("px",""))||0),Mr=Number(((we=Bn.current)==null?void 0:we.style.getPropertyValue("--swipe-amount-y").replace("px",""))||0),Ls=new Date().getTime()-((je=la.current)==null?void 0:je.getTime()),pn=F==="x"?hn:Mr,Dr=Math.abs(pn)/Ls;if(Math.abs(pn)>=aM||Dr>.11){Is(Pi.current),(fn=p.onDismiss)==null||fn.call(p,p),xe(F==="x"?hn>0?"right":"left":Mr>0?"down":"up"),Or(),fr(!0),Ci(!1);return}It(!1),W(null)},onPointerMove:ie=>{var we,je,fn,hn;if(!ji.current||!Ai||((we=window.getSelection())==null?void 0:we.toString().length)>0)return;let Mr=ie.clientY-ji.current.y,Ls=ie.clientX-ji.current.x,pn=(je=e.swipeDirections)!=null?je:cM(U);!F&&(Math.abs(Ls)>1||Math.abs(Mr)>1)&&W(Math.abs(Ls)>Math.abs(Mr)?"x":"y");let Dr={x:0,y:0};F==="y"?(pn.includes("top")||pn.includes("bottom"))&&(pn.includes("top")&&Mr<0||pn.includes("bottom")&&Mr>0)&&(Dr.y=Mr):F==="x"&&(pn.includes("left")||pn.includes("right"))&&(pn.includes("left")&&Ls<0||pn.includes("right")&&Ls>0)&&(Dr.x=Ls),(Math.abs(Dr.x)>0||Math.abs(Dr.y)>0)&&Ci(!0),(fn=Bn.current)==null||fn.style.setProperty("--swipe-amount-x",`${Dr.x}px`),(hn=Bn.current)==null||hn.style.setProperty("--swipe-amount-y",`${Dr.y}px`)}},mA&&!p.jsx?D.createElement("button",{"aria-label":Q,"data-disabled":vf,"data-close-button":!0,onClick:vf||!Ai?()=>{}:()=>{var ie;Or(),(ie=p.onDismiss)==null||ie.call(p,p)},className:gn(j==null?void 0:j.closeButton,(s=p==null?void 0:p.classNames)==null?void 0:s.closeButton)},(i=$==null?void 0:$.close)!=null?i:q2):null,p.jsx||w.isValidElement(p.title)?p.jsx?p.jsx:typeof p.title=="function"?p.title():p.title:D.createElement(D.Fragment,null,Jt||p.icon||p.promise?D.createElement("div",{"data-icon":"",className:gn(j==null?void 0:j.icon,(o=p==null?void 0:p.classNames)==null?void 0:o.icon)}
153,p.promise||p.type==="loading"&&!p.icon?p.icon||wA():null,p.type!=="loading"?p.icon||($==null?void 0:$[Jt])||B2(Jt):null):null,D.createElement("div",{"data-content":"",className:gn(j==null?void 0:j.content,(a=p==null?void 0:p.classNames)==null?void 0:a.content)},D.createElement("div",{"data-title":"",className:gn(j==null?void 0:j.title,(l=p==null?void 0:p.classNames)==null?void 0:l.title)},typeof p.title=="function"?p.title():p.title),p.description?D.createElement("div",{"data-description":"",className:gn(Z,pA,j==null?void 0:j.description,(c=p==null?void 0:p.classNames)==null?void 0:c.description)},typeof p.description=="function"?p.description():p.description):null),w.isValidElement(p.cancel)?p.cancel:p.cancel&&Rc(p.cancel)?D.createElement("button",{"data-button":!0,"data-cancel":!0,style:p.cancelButtonStyle||A,onClick:ie=>{var we,je;Rc(p.cancel)&&Ai&&((je=(we=p.cancel).onClick)==null||je.call(we,ie),Or())},className:gn(j==null?void 0:j.cancelButton,(u=p==null?void 0:p.classNames)==null?void 0:u.cancelButton)},p.cancel.label):null,w.isValidElement(p.action)?p.action:p.action&&Rc(p.action)?D.createElement("button",{"data-button":!0,"data-action":!0,style:p.actionButtonStyle||B,onClick:ie=>{var we,je;Rc(p.action)&&((je=(we=p.action).onClick)==null||je.call(we,ie),!ie.defaultPrevented&&Or())},className:gn(j==null?void 0:j.actionButton,(d=p==null?void 0:p.classNames)==null?void 0:d.actionButton)},p.action.label):null))};function ew(){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 dM(e,t){let n={};return[e,t].forEach((r,s)=>{let i=s===1,o=i?"--mobile-offset":"--offset",a=i?sM:rM;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 fM=w.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:p,visibleToasts:b=nM,toastOptions:g,dir:x=ew(),gap:y=oM,loadingIcon:m,icons:v,containerAriaLabel:_="Notifications",pauseWhenPageIsHidden:S}=e,[k,E]=D.useState([]),T=D.useMemo(()=>Array.from(new Set([r].concat(k.filter(Y=>Y.position).map(Y=>Y.position)))),[k,r]),[P,A]=D.useState([]),[B,I]=D.useState(!1),[Z,R]=D.useState(!1),[U,V]=D.useState(u!=="system"?u:typeof window<"u"&&window.matchMedia&&window.matchMedia("(prefers-color-scheme: dark)").matches?"dark":"light"),O=D.useRef(null),C=s.join("+").replace(/Key/g,"").replace(/Digit/g,""),j=D.useRef(null),$=D.useRef(!1),Q=D.useCallback(Y=>{E(F=>{var W;return(W=F.find(le=>le.id===Y.id))!=null&&W.delete||kt.dismiss(Y.id),F.filter(({id:le})=>le!==Y.id)})},[]);return D.useEffect(()=>kt.subscribe(Y=>{if(Y.dismiss){E(F=>F.map(W=>W.id===Y.id?{...W,delete:!0}:W));return}setTimeout(()=>{cS.flushSync(()=>{E(F=>{let W=F.findIndex(le=>le.id===Y.id);return W!==-1?[...F.slice(0,W),{...F[W],...Y},...F.slice(W+1)]:[Y,...F]})})})}),[]),D.useEffect(()=>{if(u!=="system"){V(u);return}if(u==="system"&&(window.matchMedia&&window.matchMedia("(prefers-color-scheme: dark)").matches?V("dark"):V("light")),typeof window>"u")return;let Y=window.matchMedia("(prefers-color-scheme: dark)");try{Y.addEventListener("change",({matches:F})=>{V(F?"dark":"light")})}catch{Y.addListener(({matches:W})=>{try{V(W?"dark":"light")}catch(le){console.error(le)}})}},[u]),D.useEffect(()=>{k.length<=1&&I(!1)},[k]),D.useEffect(()=>{let Y=F=>{var W,le;s.every(xe=>F[xe]||F.code===xe)&&(I(!0),(W=O.current)==null||W.focus()),F.code==="Escape"&&(document.activeElement===O.current||(le=O.current)!=null&&le.contains(document.activeElement))&&I(!1)};return document.addEventListener("keydown",Y),()=>document.removeEventListener("keydown",Y)},[s]),D.useEffect(()=>{if(O.current)return()=>{j.current&&(j.current.focus({preventScroll:!0}),j.current=null,$.current=!1)}},[O.current]),D.createElement("section",{ref:t,"aria-label":`${_} ${C}`,tabIndex:-1,"aria-live":"polite","aria-relevant":"additions text","aria-atomic":"false",suppressHydrationWarning:!0},T.map((Y,F)=>{var W;let[le,xe]=Y.split("-");return k.length?D.createElement("ol",{key:Y,dir:x==="auto"?ew():x,tabIndex:-1,ref:O,className:a,"data-sonner-toaster":!0,"data-theme":U,"data-y-position":le,"data-lifted":B&&k.length>1&&!i,"data-x-position":xe,style:{"--front-toast-height":`${((W=P[0])==null?void 0:W.height)||0}px`,"--width":`${iM}px`,"--gap":`${y}px`,...p,...dM(l,c)},onBlur:te=>{$.current&&!te.currentTarget.contains(te.relatedTarget)&&($.current=!1,j.current&&(j.current.focus({preventScroll:!0}),j.current=null))},onFocus:te=>{te.target instanceof HTMLElement&&te.target.dataset.dismissible==="false"||$.current||($.current=!0,j.current=te.relatedTarget)},onMouseEnter:()=>I(!0),onMouseMove:()=>I(!0),onMouseLeave:()=>{Z||I(!1)},onDragEnd:()=>I(!1),onPointerDown:te=>{te.target instanceof HTMLElement&&te.target.dataset.dismissible==="false"||R(!0)},onPointerUp:()=>R(!1)},k.filter(te=>!te.position&&F===0||te.position===Y).map((te,$n)=>{var Gt,Qt;return D.createElement(uM,{key:te.id,icons:v,index:$n,toast:te,defaultRichColors:d,duration:(Gt=g==null?void 0:g.duration)!=null?Gt:h,className:g==null?void 0:g.className,descriptionClassName:g==null?void 0:g.descriptionClassName,invert:n,visibleToasts:b,closeButton:(Qt=g==null?void 0:g.closeButton)!=null?Qt:o,interacting:Z,position:Y,style:g==null?void 0:g.style,unstyled:g==null?void 0:g.unstyled,classNames:g==null?void 0:g.classNames,cancelButtonStyle:g==null?void 0:g.cancelButtonStyle,actionButtonStyle:g==null?void 0:g.actionButtonStyle,removeToast:Q,toasts:k.filter(ot=>ot.position==te.position),heights:P.filter(ot=>ot.position==te.position),setHeights:A,expandByDefault:i,gap:y,loadingIcon:m,expanded:B,pauseWhenPageIsHidden:S,swipeDirections:e.swipeDirections})})):null}))});const hM=({...e})=>{const{theme:t="system"}=$2();return f.jsx(fM,{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})};var pM=Xm[" useId ".trim().toString()]||(()=>{}),mM=0;function gM(e){const[t,n]=w.useState(pM());return Pr(()=>{e||n(r=>r??String(mM++))},[e]),e||(t?`radix-${t}`:"")}const vM=["top","right","bottom","left"],bs=Math.min,$t=Math.max,Zu=Math.round,Oc=Math.floor,rr=e=>({x:e,y:e}
vendor: 10,346 bytes, line 153
153),yM={left:"right",right:"left",bottom:"top",top:"bottom"},wM={start:"end",end:"start"};function Xp(e,t,n){return $t(e,bs(t,n))}function jr(e,t){return typeof e=="function"?e(t):e}function Nr(e){return e.split("-")[0]}function ea(e){return e.split("-")[1]}function tv(e){return e==="x"?"y":"x"}function nv(e){return e==="y"?"height":"width"}const xM=new Set(["top","bottom"]);function Xn(e){return xM.has(Nr(e))?"y":"x"}function rv(e){return tv(Xn(e))}function bM(e,t,n){n===void 0&&(n=!1);const r=ea(e),s=rv(e),i=nv(s);let o=s==="x"?r===(n?"end":"start")?"right":"left":r==="start"?"bottom":"top";return t.reference[i]>t.floating[i]&&(o=Ju(o)),[o,Ju(o)]}function _M(e){const t=Ju(e);return[em(e),t,em(t)]}function em(e){return e.replace(/start|end/g,t=>wM[t])}const tw=["left","right"],nw=["right","left"],SM=["top","bottom"],kM=["bottom","top"];function EM(e,t,n){switch(e){case"top":case"bottom":return n?t?nw:tw:t?tw:nw;case"left":case"right":return t?SM:kM;default:return[]}}function CM(e,t,n,r){const s=ea(e);let i=EM(Nr(e),n==="start",r);return s&&(i=i.map(o=>o+"-"+s),t&&(i=i.concat(i.map(em)))),i}function Ju(e){return e.replace(/left|right|bottom|top/g,t=>yM[t])}function TM(e){return{top:0,right:0,bottom:0,left:0,...e}}function Ck(e){return typeof e!="number"?TM(e):{top:e,right:e,bottom:e,left:e}}function Xu(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 rw(e,t,n){let{reference:r,floating:s}=e;const i=Xn(t),o=rv(t),a=nv(o),l=Nr(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 p;switch(l){case"top":p={x:u,y:r.y-s.height};break;case"bottom":p={x:u,y:r.y+r.height};break;case"right":p={x:r.x+r.width,y:d};break;case"left":p={x:r.x-s.width,y:d};break;default:p={x:r.x,y:r.y}}switch(ea(t)){case"start":p[o]-=h*(n&&c?-1:1);break;case"end":p[o]+=h*(n&&c?-1:1);break}return p}const AM=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}=rw(c,r,l),h=r,p={},b=0;for(let g=0;g<a.length;g++){const{name:x,fn:y}=a[g],{x:m,y:v,data:_,reset:S}=await y({x:u,y:d,initialPlacement:r,placement:h,strategy:s,middlewareData:p,rects:c,platform:o,elements:{reference:e,floating:t}});u=m??u,d=v??d,p={...p,[x]:{...p[x],..._}},S&&b<=50&&(b++,typeof S=="object"&&(S.placement&&(h=S.placement),S.rects&&(c=S.rects===!0?await o.getElementRects({reference:e,floating:t,strategy:s}):S.rects),{x:u,y:d}=rw(c,h,l)),g=-1)}return{x:u,y:d,placement:h,strategy:s,middlewareData:p}};async function bl(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:p=0}=jr(t,e),b=Ck(p),x=a[h?d==="floating"?"reference":"floating":d],y=Xu(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})),m=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)),_=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},S=Xu(i.convertOffsetParentRelativeRectToViewportRelativeRect?await i.convertOffsetParentRelativeRectToViewportRelativeRect({elements:a,rect:m,offsetParent:v,strategy:l}):m);return{top:(y.top-S.top+b.top)/_.y,bottom:(S.bottom-y.bottom+b.bottom)/_.y,left:(y.left-S.left+b.left)/_.x,right:(S.right-y.right+b.right)/_.x}}const PM=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}=jr(e,t)||{};if(c==null)return{};const d=Ck(u),h={x:n,y:r},p=rv(s),b=nv(p),g=await o.getDimensions(c),x=p==="y",y=x?"top":"left",m=x?"bottom":"right",v=x?"clientHeight":"clientWidth",_=i.reference[b]+i.reference[p]-h[p]-i.floating[b],S=h[p]-i.reference[p],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[b]);const T=_/2-S/2,P=E/2-g[b]/2-1,A=bs(d[y],P),B=bs(d[m],P),I=A,Z=E-g[b]-B,R=E/2-g[b]/2+T,U=Xp(I,R,Z),V=!l.arrow&&ea(s)!=null&&R!==U&&i.reference[b]/2-(R<I?A:B)-g[b]/2<0,O=V?R<I?R-I:R-Z:0;return{[p]:h[p]+O,data:{[p]:U,centerOffset:R-U-O,...V&&{alignmentOffset:O}},reset:V}}}),jM=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:p="bestFit",fallbackAxisSideDirection:b="none",flipAlignment:g=!0,...x}=jr(e,t);if((n=i.arrow)!=null&&n.alignmentOffset)return{};const y=Nr(s),m=Xn(a),v=Nr(a)===a,_=await(l.isRTL==null?void 0:l.isRTL(c.floating)),S=h||(v||!g?[Ju(a)]:_M(a)),k=b!=="none";!h&&k&&S.push(...CM(a,g,b,_));const E=[a,...S],T=await bl(t,x),P=[];let A=((r=i.flip)==null?void 0:r.overflows)||[];if(u&&P.push(T[y]),d){const R=bM(s,o,_);P.push(T[R[0]],T[R[1]])}if(A=[...A,{placement:s,overflows:P}],!P.every(R=>R<=0)){var B,I;const R=(((B=i.flip)==null?void 0:B.index)||0)+1,U=E[R];if(U&&(!(d==="alignment"?m!==Xn(U):!1)||A.every(C=>C.overflows[0]>0&&Xn(C.placement)===m)))return{data:{index:R,overflows:A},reset:{placement:U}};let V=(I=A.filter(O=>O.overflows[0]<=0).sort((O,C)=>O.overflows[1]-C.overflows[1])[0])==null?void 0:I.placement;if(!V)switch(p){case"bestFit":{var Z;const O=(Z=A.filter(C=>{if(k){const j=Xn(C.placement);return j===m||j==="y"}return!0}).map(C=>[C.placement,C.overflows.filter(j=>j>0).reduce((j,$)=>j+$,0)]).sort((C,j)=>C[1]-j[1])[0])==null?void 0:Z[0];O&&(V=O);break}case"initialPlacement":V=a;break}if(s!==V)return{reset:{placement:V}}}return{}}}};function sw(e,t){return{top:e.top-t.height,right:e.right-t.width,bottom:e.bottom-t.height,left:e.left-t.width}}function iw(e){return vM.some(t=>e[t]>=0)}const NM=function(e){return e===void 0&&(e={}),{name:"hide",options:e,async fn(t){const{rects:n}=t,{strategy:r="referenceHidden",...s}=jr(e,t);switch(r){case"referenceHidden":{const i=await bl(t,{...s,elementContext:"reference"}),o=sw(i,n.reference);return{data:{referenceHiddenOffsets:o,referenceHidden:iw(o)}}}case"escaped":{const i=await bl(t,{...s,altBoundary:!0}),o=sw(i,n.floating);return{data:{escapedOffsets:o,escaped:iw(o)}}}default:return{}}}}},Tk=new Set(["left","top"]);async function RM(e,t){const{placement:n,platform:r,elements:s}=e,i=await(r.isRTL==null?void 0:r.isRTL(s.floating)),o=Nr(n),a=ea(n),l=Xn(n)==="y",c=Tk.has(o)?-1:1,u=i&&l?-1:1,d=jr(t,e);let{mainAxis:h,crossAxis:p,alignmentAxis:b}=typeof d=="number"?{mainAxis:d,crossAxis:0,alignmentAxis:null}:{mainAxis:d.mainAxis||0,crossAxis:d.crossAxis||0,alignmentAxis:d.alignmentAxis};return a&&typeof b=="number"&&(p=a==="end"?b*-1:b),l?{x:p*u,y:h*c}:{x:h*c,y:p*u}}const OM=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 RM(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}}}}},MM=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:y,y:m}=x;return{x:y,y:m}}},...l}=jr(e,t),c={x:n,y:r},u=await bl(t,l),d=Xn(Nr(s)),h=tv(d);let p=c[h],b=c[d];if(i){const x=h==="y"?"top":"left",y=h==="y"?"bottom":"right",m=p+u[x],v=p-u[y];p=Xp(m,p,v)}if(o){const x=d==="y"?"top":"left",y=d==="y"?"bottom":"right",m=b+u[x],v=b-u[y];b=Xp(m,b,v)}const g=a.fn({...t,[h]:p,[d]:b});return{...g,data:{x:g.x-n,y:g.y-r,enabled:{[h]:i,[d]:o}}}}}},DM=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}=jr(e,t),u={x:n,y:r},d=Xn(s),h=tv(d);let p=u[h],b=u[d];const g=jr(a,t),x=typeof g=="number"?{mainAxis:g,crossAxis:0}:{mainAxis:0,crossAxis:0,...g};if(l){const v=h==="y"?"height":"width",_=i.reference[h]-i.floating[v]+x.mainAxis,S=i.reference[h]+i.reference[v]-x.mainAxis;p<_?p=_:p>S&&(p=S)}if(c){var y,m;const v=h==="y"?"width":"height",_=Tk.has(Nr(s)),S=i.reference[d]-i.floating[v]+(_&&((y=o.offset)==null?void 0:y[d])||0)+(_?0:x.crossAxis),k=i.reference[d]+i.reference[v]+(_?0:((m=o.offset)==null?void 0:m[d])||0)-(_?x.crossAxis:0);b<S?b=S:b>k&&(b=k)}return{[h]:p,[d]:b}}}},IM=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}=jr(e,t),u=await bl(t,c),d=Nr(s),h=ea(s),p=Xn(s)==="y",{width:b,height:g}=i.floating;let x,y;d==="top"||d==="bottom"?(x=d,y=h===(await(o.isRTL==null?void 0:o.isRTL(a.floating))?"start":"end")?"left":"right"):(y=d,x=h==="end"?"top":"bottom");const m=g-u.top-u.bottom,v=b-u.left-u.right,_=bs(g-u[x],m),S=bs(b-u[y],v),k=!t.middlewareData.shift;let E=_,T=S;if((n=t.middlewareData.shift)!=null&&n.enabled.x&&(T=v),(r=t.middlewareData.shift)!=null&&r.enabled.y&&(E=m),k&&!h){const A=$t(u.left,0),B=$t(u.right,0),I=$t(u.top,0),Z=$t(u.bottom,0);p?T=b-2*(A!==0||B!==0?A+B:$t(u.left,u.right)):E=g-2*(I!==0||Z!==0?I+Z:$t(u.top,u.bottom))}await l({...t,availableWidth:T,availableHeight:E});const P=await o.getDimensions(a.floating);return b!==P.width||g!==P.height?{reset:{rects:!0}}:{}}}};function Hd(){return typeof window<"u"}function ta(e){return Ak(e)?(e.nodeName||"").toLowerCase():"#document"}function Ut(e){var t;return(e==null||(t=e.ownerDocument)==null?void 0:t.defaultView)||window}function dr(e){var t;return(t=(Ak(e)?e.ownerDocument:e.document)||window.document)==null?void 0:t.documentElement}function Ak(e){return Hd()?e instanceof Node||e instanceof Ut(e).Node:!1}function On(e){return Hd()?e instanceof Element||e instanceof Ut(e).Element:!1}function ar(e){return Hd()?e instanceof HTMLElement||e instanceof Ut(e).HTMLElement:!1}function ow(e){return!Hd()||typeof ShadowRoot>"u"?!1:e instanceof ShadowRoot||e instanceof Ut(e).ShadowRoot}const LM=new Set(["inline","contents"]);function Yl(e){const{overflow:t,overflowX:n,overflowY:r,display:s}=Mn(e);
vendor: 4,121 bytes, line 153
153return/auto|scroll|overlay|hidden|clip/.test(t+r+n)&&!LM.has(s)}const FM=new Set(["table","td","th"]);function $M(e){return FM.has(ta(e))}const BM=[":popover-open",":modal"];function Kd(e){return BM.some(t=>{try{return e.matches(t)}catch{return!1}})}const VM=["transform","translate","scale","rotate","perspective"],UM=["transform","translate","scale","rotate","perspective","filter"],zM=["paint","layout","strict","content"];function sv(e){const t=iv(),n=On(e)?Mn(e):e;return VM.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)||UM.some(r=>(n.willChange||"").includes(r))||zM.some(r=>(n.contain||"").includes(r))}function WM(e){let t=_s(e);for(;ar(t)&&!Lo(t);){if(sv(t))return t;if(Kd(t))return null;t=_s(t)}return null}function iv(){return typeof CSS>"u"||!CSS.supports?!1:CSS.supports("-webkit-backdrop-filter","none")}const HM=new Set(["html","body","#document"]);function Lo(e){return HM.has(ta(e))}function Mn(e){return Ut(e).getComputedStyle(e)}function qd(e){return On(e)?{scrollLeft:e.scrollLeft,scrollTop:e.scrollTop}:{scrollLeft:e.scrollX,scrollTop:e.scrollY}}function _s(e){if(ta(e)==="html")return e;const t=e.assignedSlot||e.parentNode||ow(e)&&e.host||dr(e);return ow(t)?t.host:t}function Pk(e){const t=_s(e);return Lo(t)?e.ownerDocument?e.ownerDocument.body:e.body:ar(t)&&Yl(t)?t:Pk(t)}function _l(e,t,n){var r;t===void 0&&(t=[]),n===void 0&&(n=!0);const s=Pk(e),i=s===((r=e.ownerDocument)==null?void 0:r.body),o=Ut(s);if(i){const a=tm(o);return t.concat(o,o.visualViewport||[],Yl(s)?s:[],a&&n?_l(a):[])}return t.concat(s,_l(s,[],n))}function tm(e){return e.parent&&Object.getPrototypeOf(e.parent)?e.frameElement:null}function jk(e){const t=Mn(e);let n=parseFloat(t.width)||0,r=parseFloat(t.height)||0;const s=ar(e),i=s?e.offsetWidth:n,o=s?e.offsetHeight:r,a=Zu(n)!==i||Zu(r)!==o;return a&&(n=i,r=o),{width:n,height:r,$:a}}function ov(e){return On(e)?e:e.contextElement}function wo(e){const t=ov(e);if(!ar(t))return rr(1);const n=t.getBoundingClientRect(),{width:r,height:s,$:i}=jk(t);let o=(i?Zu(n.width):n.width)/r,a=(i?Zu(n.height):n.height)/s;return(!o||!Number.isFinite(o))&&(o=1),(!a||!Number.isFinite(a))&&(a=1),{x:o,y:a}}const KM=rr(0);function Nk(e){const t=Ut(e);return!iv()||!t.visualViewport?KM:{x:t.visualViewport.offsetLeft,y:t.visualViewport.offsetTop}}function qM(e,t,n){return t===void 0&&(t=!1),!n||t&&n!==Ut(e)?!1:t}function gi(e,t,n,r){t===void 0&&(t=!1),n===void 0&&(n=!1);const s=e.getBoundingClientRect(),i=ov(e);let o=rr(1);t&&(r?On(r)&&(o=wo(r)):o=wo(e));const a=qM(i,n,r)?Nk(i):rr(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=Ut(i),p=r&&On(r)?Ut(r):r;let b=h,g=tm(b);for(;g&&r&&p!==b;){const x=wo(g),y=g.getBoundingClientRect(),m=Mn(g),v=y.left+(g.clientLeft+parseFloat(m.paddingLeft))*x.x,_=y.top+(g.clientTop+parseFloat(m.paddingTop))*x.y;l*=x.x,c*=x.y,u*=x.x,d*=x.y,l+=v,c+=_,b=Ut(g),g=tm(b)}}return Xu({width:u,height:d,x:l,y:c})}function av(e,t){const n=qd(e).scrollLeft;return t?t.left+n:gi(dr(e)).left+n}function Rk(e,t,n){n===void 0&&(n=!1);const r=e.getBoundingClientRect(),s=r.left+t.scrollLeft-(n?0:av(e,r)),i=r.top+t.scrollTop;return{x:s,y:i}}function YM(e){let{elements:t,rect:n,offsetParent:r,strategy:s}=e;const i=s==="fixed",o=dr(r),a=t?Kd(t.floating):!1;if(r===o||a&&i)return n;let l={scrollLeft:0,scrollTop:0},c=rr(1);const u=rr(0),d=ar(r);if((d||!d&&!i)&&((ta(r)!=="body"||Yl(o))&&(l=qd(r)),ar(r))){const p=gi(r);c=wo(r),u.x=p.x+r.clientLeft,u.y=p.y+r.clientTop}const h=o&&!d&&!i?Rk(o,l,!0):rr(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 GM(e){return Array.from(e.getClientRects())}function QM(e){const t=dr(e),n=qd(e),r=e.ownerDocument.body,s=$t(t.scrollWidth,t.clientWidth,r.scrollWidth,r.clientWidth),i=$t(t.scrollHeight,t.clientHeight,r.scrollHeight,r.clientHeight);let o=-n.scrollLeft+av(e);const a=-n.scrollTop;return Mn(r).direction==="rtl"&&(o+=$t(t.clientWidth,r.clientWidth)-s),{width:s,height:i,x:o,y:a}}
vendor: 4,850 bytes, line 153
153function ZM(e,t){const n=Ut(e),r=dr(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=iv();(!c||c&&t==="fixed")&&(a=s.offsetLeft,l=s.offsetTop)}return{width:i,height:o,x:a,y:l}}const JM=new Set(["absolute","fixed"]);function XM(e,t){const n=gi(e,!0,t==="fixed"),r=n.top+e.clientTop,s=n.left+e.clientLeft,i=ar(e)?wo(e):rr(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 aw(e,t,n){let r;if(t==="viewport")r=ZM(e,n);else if(t==="document")r=QM(dr(e));else if(On(t))r=XM(t,n);else{const s=Nk(e);r={x:t.x-s.x,y:t.y-s.y,width:t.width,height:t.height}}return Xu(r)}function Ok(e,t){const n=_s(e);return n===t||!On(n)||Lo(n)?!1:Mn(n).position==="fixed"||Ok(n,t)}function eD(e,t){const n=t.get(e);if(n)return n;let r=_l(e,[],!1).filter(a=>On(a)&&ta(a)!=="body"),s=null;const i=Mn(e).position==="fixed";let o=i?_s(e):e;for(;On(o)&&!Lo(o);){const a=Mn(o),l=sv(o);!l&&a.position==="fixed"&&(s=null),(i?!l&&!s:!l&&a.position==="static"&&!!s&&JM.has(s.position)||Yl(o)&&!l&&Ok(e,o))?r=r.filter(u=>u!==o):s=a,o=_s(o)}return t.set(e,r),r}function tD(e){let{element:t,boundary:n,rootBoundary:r,strategy:s}=e;const o=[...n==="clippingAncestors"?Kd(t)?[]:eD(t,this._c):[].concat(n),r],a=o[0],l=o.reduce((c,u)=>{const d=aw(t,u,s);return c.top=$t(d.top,c.top),c.right=bs(d.right,c.right),c.bottom=bs(d.bottom,c.bottom),c.left=$t(d.left,c.left),c},aw(t,a,s));return{width:l.right-l.left,height:l.bottom-l.top,x:l.left,y:l.top}}function nD(e){const{width:t,height:n}=jk(e);return{width:t,height:n}}function rD(e,t,n){const r=ar(t),s=dr(t),i=n==="fixed",o=gi(e,!0,i,t);let a={scrollLeft:0,scrollTop:0};const l=rr(0);function c(){l.x=av(s)}if(r||!r&&!i)if((ta(t)!=="body"||Yl(s))&&(a=qd(t)),r){const p=gi(t,!0,i,t);l.x=p.x+t.clientLeft,l.y=p.y+t.clientTop}else s&&c();i&&!r&&s&&c();const u=s&&!r&&!i?Rk(s,a):rr(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 th(e){return Mn(e).position==="static"}function lw(e,t){if(!ar(e)||Mn(e).position==="fixed")return null;if(t)return t(e);let n=e.offsetParent;return dr(e)===n&&(n=n.ownerDocument.body),n}function Mk(e,t){const n=Ut(e);if(Kd(e))return n;if(!ar(e)){let s=_s(e);for(;s&&!Lo(s);){if(On(s)&&!th(s))return s;s=_s(s)}return n}let r=lw(e,t);for(;r&&$M(r)&&th(r);)r=lw(r,t);return r&&Lo(r)&&th(r)&&!sv(r)?n:r||WM(e)||n}const sD=async function(e){const t=this.getOffsetParent||Mk,n=this.getDimensions,r=await n(e.floating);return{reference:rD(e.reference,await t(e.floating),e.strategy),floating:{x:0,y:0,width:r.width,height:r.height}}};function iD(e){return Mn(e).direction==="rtl"}const oD={convertOffsetParentRelativeRectToViewportRelativeRect:YM,getDocumentElement:dr,getClippingRect:tD,getOffsetParent:Mk,getElementRects:sD,getClientRects:GM,getDimensions:nD,getScale:wo,isElement:On,isRTL:iD};function Dk(e,t){return e.x===t.x&&e.y===t.y&&e.width===t.width&&e.height===t.height}function aD(e,t){let n=null,r;const s=dr(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:p}=c;if(a||t(),!h||!p)return;const b=Oc(d),g=Oc(s.clientWidth-(u+h)),x=Oc(s.clientHeight-(d+p)),y=Oc(u),v={rootMargin:-b+"px "+-g+"px "+-x+"px "+-y+"px",threshold:$t(0,bs(1,l))||1};let _=!0;function S(k){const E=k[0].intersectionRatio;if(E!==l){if(!_)return o();E?o(!1,E):r=setTimeout(()=>{o(!1,1e-7)},1e3)}E===1&&!Dk(c,e.getBoundingClientRect())&&o(),_=!1}try{n=new IntersectionObserver(S,{...v,root:s.ownerDocument})}catch{n=new IntersectionObserver(S,v)}n.observe(e)}return o(!0),i}function lD(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=ov(e),u=s||i?[...c?_l(c):[],..._l(t)]:[];u.forEach(y=>{s&&y.addEventListener("scroll",n,{passive:!0}),i&&y.addEventListener("resize",n)});const d=c&&a?aD(c,n):null;let h=-1,p=null;o&&(p=new ResizeObserver(y=>{let[m]=y;m&&m.target===c&&p&&(p.unobserve(t),cancelAnimationFrame(h),h=requestAnimationFrame(()=>{var v;(v=p)==null||v.observe(t)})),n()}),c&&!l&&p.observe(c),p.observe(t));let b,g=l?gi(e):null;l&&x();function x(){const y=gi(e);g&&!Dk(g,y)&&n(),g=y,b=requestAnimationFrame(x)}return n(),()=>{var y;u.forEach(m=>{s&&m.removeEventListener("scroll",n),i&&m.removeEventListener("resize",n)}),d==null||d(),(y=p)==null||y.disconnect(),p=null,l&&cancelAnimationFrame(b)}}const cD=OM,uD=MM,dD=jM,fD=IM,hD=NM,cw=PM,pD=DM,mD=(e,t,n)=>{const r=new Map,s={platform:oD,...n},i={...s.platform,_c:r};return AM(e,t,{...s,platform:i})};var gD=typeof document<"u",vD=function(){},du=gD?w.useLayoutEffect:vD;function ed(e,t){if(e===t)return!0;
vendor: 4,143 bytes, line 153
153if(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(!ed(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)&&!ed(e[i],t[i]))return!1}return!0}return e!==e&&t!==t}function Ik(e){return typeof window>"u"?1:(e.ownerDocument.defaultView||window).devicePixelRatio||1}function uw(e,t){const n=Ik(e);return Math.round(t*n)/n}function nh(e){const t=w.useRef(e);return du(()=>{t.current=e}),t}function yD(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]=w.useState({x:0,y:0,strategy:n,placement:t,middlewareData:{},isPositioned:!1}),[h,p]=w.useState(r);ed(h,r)||p(r);const[b,g]=w.useState(null),[x,y]=w.useState(null),m=w.useCallback(C=>{C!==k.current&&(k.current=C,g(C))},[]),v=w.useCallback(C=>{C!==E.current&&(E.current=C,y(C))},[]),_=i||b,S=o||x,k=w.useRef(null),E=w.useRef(null),T=w.useRef(u),P=l!=null,A=nh(l),B=nh(s),I=nh(c),Z=w.useCallback(()=>{if(!k.current||!E.current)return;const C={placement:t,strategy:n,middleware:h};B.current&&(C.platform=B.current),mD(k.current,E.current,C).then(j=>{const $={...j,isPositioned:I.current!==!1};R.current&&!ed(T.current,$)&&(T.current=$,Si.flushSync(()=>{d($)}))})},[h,t,n,B,I]);du(()=>{c===!1&&T.current.isPositioned&&(T.current.isPositioned=!1,d(C=>({...C,isPositioned:!1})))},[c]);const R=w.useRef(!1);du(()=>(R.current=!0,()=>{R.current=!1}),[]),du(()=>{if(_&&(k.current=_),S&&(E.current=S),_&&S){if(A.current)return A.current(_,S,Z);Z()}},[_,S,Z,A,P]);const U=w.useMemo(()=>({reference:k,floating:E,setReference:m,setFloating:v}),[m,v]),V=w.useMemo(()=>({reference:_,floating:S}),[_,S]),O=w.useMemo(()=>{const C={position:n,left:0,top:0};if(!V.floating)return C;const j=uw(V.floating,u.x),$=uw(V.floating,u.y);return a?{...C,transform:"translate("+j+"px, "+$+"px)",...Ik(V.floating)>=1.5&&{willChange:"transform"}}:{position:n,left:j,top:$}},[n,a,V.floating,u.x,u.y]);return w.useMemo(()=>({...u,update:Z,refs:U,elements:V,floatingStyles:O}),[u,Z,U,V,O])}const wD=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?cw({element:r.current,padding:s}).fn(n):{}:r?cw({element:r,padding:s}).fn(n):{}}}},xD=(e,t)=>({...cD(e),options:[e,t]}),bD=(e,t)=>({...uD(e),options:[e,t]}),_D=(e,t)=>({...pD(e),options:[e,t]}),SD=(e,t)=>({...dD(e),options:[e,t]}),kD=(e,t)=>({...fD(e),options:[e,t]}),ED=(e,t)=>({...hD(e),options:[e,t]}),CD=(e,t)=>({...wD(e),options:[e,t]});var TD="Arrow",Lk=w.forwardRef((e,t)=>{const{children:n,width:r=10,height:s=5,...i}=e;return f.jsx(it.svg,{...i,ref:t,width:r,height:s,viewBox:"0 0 30 10",preserveAspectRatio:"none",children:e.asChild?n:f.jsx("polygon",{points:"0,0 30,0 15,10"})})});Lk.displayName=TD;var AD=Lk;function PD(e){const[t,n]=w.useState(void 0);return Pr(()=>{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 lv="Popper",[Fk,Yd]=Hl(lv),[jD,$k]=Fk(lv),Bk=e=>{const{__scopePopper:t,children:n}=e,[r,s]=w.useState(null);return f.jsx(jD,{scope:t,anchor:r,onAnchorChange:s,children:n})};Bk.displayName=lv;var Vk="PopperAnchor",Uk=w.forwardRef((e,t)=>{const{__scopePopper:n,virtualRef:r,...s}=e,i=$k(Vk,n),o=w.useRef(null),a=Dt(t,o);return w.useEffect(()=>{i.onAnchorChange((r==null?void 0:r.current)||o.current)}),r?null:f.jsx(it.div,{...s,ref:a})});Uk.displayName=Vk;var cv="PopperContent",[ND,RD]=Fk(cv),zk=w.forwardRef((e,t)=>
vendor: 4,214 bytes, line 153
153{var te,$n,Gt,Qt,ot,It;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:p="optimized",onPlaced:b,...g}=e,x=$k(cv,n),[y,m]=w.useState(null),v=Dt(t,Zt=>m(Zt)),[_,S]=w.useState(null),k=PD(_),E=(k==null?void 0:k.width)??0,T=(k==null?void 0:k.height)??0,P=r+(i!=="center"?"-"+i:""),A=typeof u=="number"?u:{top:0,right:0,bottom:0,left:0,...u},B=Array.isArray(c)?c:[c],I=B.length>0,Z={padding:A,boundary:B.filter(MD),altBoundary:I},{refs:R,floatingStyles:U,placement:V,isPositioned:O,middlewareData:C}=yD({strategy:"fixed",placement:P,whileElementsMounted:(...Zt)=>lD(...Zt,{animationFrame:p==="always"}),elements:{reference:x.anchor},middleware:[xD({mainAxis:s+T,alignmentAxis:o}),l&&bD({mainAxis:!0,crossAxis:!1,limiter:d==="partial"?_D():void 0,...Z}),l&&SD({...Z}),kD({...Z,apply:({elements:Zt,rects:fr,availableWidth:aa,availableHeight:Ci})=>{const{width:Ds,height:Is}=fr.reference,hr=Zt.floating.style;hr.setProperty("--radix-popper-available-width",`${aa}px`),hr.setProperty("--radix-popper-available-height",`${Ci}px`),hr.setProperty("--radix-popper-anchor-width",`${Ds}px`),hr.setProperty("--radix-popper-anchor-height",`${Is}px`)}}),_&&CD({element:_,padding:a}),DD({arrowWidth:E,arrowHeight:T}),h&&ED({strategy:"referenceHidden",...Z})]}),[j,$]=Kk(V),Q=or(b);Pr(()=>{O&&(Q==null||Q())},[O,Q]);const Y=(te=C.arrow)==null?void 0:te.x,F=($n=C.arrow)==null?void 0:$n.y,W=((Gt=C.arrow)==null?void 0:Gt.centerOffset)!==0,[le,xe]=w.useState();return Pr(()=>{y&&xe(window.getComputedStyle(y).zIndex)},[y]),f.jsx("div",{ref:R.setFloating,"data-radix-popper-content-wrapper":"",style:{...U,transform:O?U.transform:"translate(0, -200%)",minWidth:"max-content",zIndex:le,"--radix-popper-transform-origin":[(Qt=C.transformOrigin)==null?void 0:Qt.x,(ot=C.transformOrigin)==null?void 0:ot.y].join(" "),...((It=C.hide)==null?void 0:It.referenceHidden)&&{visibility:"hidden",pointerEvents:"none"}},dir:e.dir,children:f.jsx(ND,{scope:n,placedSide:j,onArrowChange:S,arrowX:Y,arrowY:F,shouldHideArrow:W,children:f.jsx(it.div,{"data-side":j,"data-align":$,...g,ref:v,style:{...g.style,animation:O?void 0:"none"}})})})});zk.displayName=cv;var Wk="PopperArrow",OD={top:"bottom",right:"left",bottom:"top",left:"right"},Hk=w.forwardRef(function(t,n){const{__scopePopper:r,...s}=t,i=RD(Wk,r),o=OD[i.placedSide];return f.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:f.jsx(AD,{...s,ref:n,style:{...s.style,display:"block"}})})});Hk.displayName=Wk;function MD(e){return e!==null}var DD=e=>({name:"transformOrigin",options:e,fn(t){var x,y,m;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]=Kk(n),d={start:"0%",center:"50%",end:"100%"}[u],h=(((y=s.arrow)==null?void 0:y.x)??0)+a/2,p=(((m=s.arrow)==null?void 0:m.y)??0)+l/2;let b="",g="";return c==="bottom"?(b=o?d:`${h}px`,g=`${-l}px`):c==="top"?(b=o?d:`${h}px`,g=`${r.floating.height+l}px`):c==="right"?(b=`${-l}px`,g=o?d:`${p}px`):c==="left"&&(b=`${r.floating.width+l}px`,g=o?d:`${p}px`),{data:{x:b,y:g}}}});function Kk(e){const[t,n="center"]=e.split("-");return[t,n]}var ID=Bk,uv=Uk,qk=zk,Yk=Hk,[Gd,hW]=Hl("Tooltip",[Yd]),dv=Yd(),Gk="TooltipProvider",LD=700,dw="tooltip.open",[FD,Qk]=Gd(Gk),Zk=e=>{const{__scopeTooltip:t,delayDuration:n=LD,skipDelayDuration:r=300,disableHoverableContent:s=!1,children:i}=e,o=w.useRef(!0),a=w.useRef(!1),l=w.useRef(0);return w.useEffect(()=>{const c=l.current;return()=>window.clearTimeout(c)},[]),f.jsx(FD,{scope:t,isOpenDelayedRef:o,delayDuration:n,onOpen:w.useCallback(()=>{window.clearTimeout(l.current),o.current=!1},[]),onClose:w.useCallback(()=>{window.clearTimeout(l.current),l.current=window.setTimeout(()=>
vendor: 5,838 bytes, line 153
153o.current=!0,r)},[r]),isPointerInTransitRef:a,onPointerInTransitChange:w.useCallback(c=>{a.current=c},[]),disableHoverableContent:s,children:i})};Zk.displayName=Gk;var Jk="Tooltip",[pW,Qd]=Gd(Jk),nm="TooltipTrigger",$D=w.forwardRef((e,t)=>{const{__scopeTooltip:n,...r}=e,s=Qd(nm,n),i=Qk(nm,n),o=dv(n),a=w.useRef(null),l=Dt(t,a,s.onTriggerChange),c=w.useRef(!1),u=w.useRef(!1),d=w.useCallback(()=>c.current=!1,[]);return w.useEffect(()=>()=>document.removeEventListener("pointerup",d),[d]),f.jsx(uv,{asChild:!0,...o,children:f.jsx(it.button,{"aria-describedby":s.open?s.contentId:void 0,"data-state":s.stateAttribute,...r,ref:l,onPointerMove:Oe(e.onPointerMove,h=>{h.pointerType!=="touch"&&!u.current&&!i.isPointerInTransitRef.current&&(s.onTriggerEnter(),u.current=!0)}),onPointerLeave:Oe(e.onPointerLeave,()=>{s.onTriggerLeave(),u.current=!1}),onPointerDown:Oe(e.onPointerDown,()=>{s.open&&s.onClose(),c.current=!0,document.addEventListener("pointerup",d,{once:!0})}),onFocus:Oe(e.onFocus,()=>{c.current||s.onOpen()}),onBlur:Oe(e.onBlur,s.onClose),onClick:Oe(e.onClick,s.onClose)})})});$D.displayName=nm;var BD="TooltipPortal",[mW,VD]=Gd(BD,{forceMount:void 0}),Fo="TooltipContent",Xk=w.forwardRef((e,t)=>{const n=VD(Fo,e.__scopeTooltip),{forceMount:r=n.forceMount,side:s="top",...i}=e,o=Qd(Fo,e.__scopeTooltip);return f.jsx(Kl,{present:r||o.open,children:o.disableHoverableContent?f.jsx(eE,{side:s,...i,ref:t}):f.jsx(UD,{side:s,...i,ref:t})})}),UD=w.forwardRef((e,t)=>{const n=Qd(Fo,e.__scopeTooltip),r=Qk(Fo,e.__scopeTooltip),s=w.useRef(null),i=Dt(t,s),[o,a]=w.useState(null),{trigger:l,onClose:c}=n,u=s.current,{onPointerInTransitChange:d}=r,h=w.useCallback(()=>{a(null),d(!1)},[d]),p=w.useCallback((b,g)=>{const x=b.currentTarget,y={x:b.clientX,y:b.clientY},m=qD(y,x.getBoundingClientRect()),v=YD(y,m),_=GD(g.getBoundingClientRect()),S=ZD([...v,..._]);a(S),d(!0)},[d]);return w.useEffect(()=>()=>h(),[h]),w.useEffect(()=>{if(l&&u){const b=x=>p(x,u),g=x=>p(x,l);return l.addEventListener("pointerleave",b),u.addEventListener("pointerleave",g),()=>{l.removeEventListener("pointerleave",b),u.removeEventListener("pointerleave",g)}}},[l,u,p,h]),w.useEffect(()=>{if(o){const b=g=>{const x=g.target,y={x:g.clientX,y:g.clientY},m=(l==null?void 0:l.contains(x))||(u==null?void 0:u.contains(x)),v=!QD(y,o);m?h():v&&(h(),c())};return document.addEventListener("pointermove",b),()=>document.removeEventListener("pointermove",b)}},[l,u,o,c,h]),f.jsx(eE,{...e,ref:i})}),[zD,WD]=Gd(Jk,{isInside:!1}),HD=nO("TooltipContent"),eE=w.forwardRef((e,t)=>{const{__scopeTooltip:n,children:r,"aria-label":s,onEscapeKeyDown:i,onPointerDownOutside:o,...a}=e,l=Qd(Fo,n),c=dv(n),{onClose:u}=l;return w.useEffect(()=>(document.addEventListener(dw,u),()=>document.removeEventListener(dw,u)),[u]),w.useEffect(()=>{if(l.trigger){const d=h=>{const p=h.target;p!=null&&p.contains(l.trigger)&&u()};return window.addEventListener("scroll",d,{capture:!0}),()=>window.removeEventListener("scroll",d,{capture:!0})}},[l.trigger,u]),f.jsx(Ud,{asChild:!0,disableOutsidePointerEvents:!1,onEscapeKeyDown:i,onPointerDownOutside:o,onFocusOutside:d=>d.preventDefault(),onDismiss:u,children:f.jsxs(qk,{"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:[f.jsx(HD,{children:r}),f.jsx(zD,{scope:n,isInside:!0,children:f.jsx(CO,{id:l.contentId,role:"tooltip",children:s||r})})]})})});Xk.displayName=Fo;var tE="TooltipArrow",KD=w.forwardRef((e,t)=>{const{__scopeTooltip:n,...r}=e,s=dv(n);return WD(tE,n).isInside?null:f.jsx(Yk,{...s,...r,ref:t})});KD.displayName=tE;function qD(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 YD(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 GD(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 QD(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 ZD(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),JD(t)}function JD(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)}var XD=Zk,nE=Xk;const eI=XD,tI=w.forwardRef(({className:e,sideOffset:t=4,...n},r)=>f.jsx(nE,{ref:r,sideOffset:t,className:Te("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]:sli
153de-in-from-left-2 data-[side=top]:slide-in-from-bottom-2",e),...n}));tI.displayName=nE.displayName;const nI="modulepreload",rI=function(e){return"/"+e},fw={},Gl=function(t,n,r){let s=Promise.resolve();if(n&&n.length>0){document.getElementsByTagName("link");const o=document.querySelector("meta[property=csp-nonce]"),a=(o==null?void 0:o.nonce)||(o==null?void 0:o.getAttribute("nonce"));s=Promise.allSettled(n.map(l=>{if(l=rI(l),l in fw)return;fw[l]=!0;const c=l.endsWith(".css"),u=c?'[rel="stylesheet"]':"";if(document.querySelector(`link[href="${l}"]${u}`))return;const d=document.createElement("link");if(d.rel=c?"stylesheet":nI,c||(d.as="script"),d.crossOrigin="",d.href=l,a&&d.setAttribute("nonce",a),document.head.appendChild(d),c)return new Promise((h,p)=>{d.addEventListener("load",h),d.addEventListener("error",()=>p(new Error(`Unable to preload CSS for ${l}`)))})}))}function i(o){const a=new Event("vite:preloadError",{cancelable:!0});if(a.payload=o,window.dispatchEvent(a),!a.defaultPrevented)throw o}return s.then(o=>{for(const a of o||[])a.status==="rejected"&&i(a.reason);return t().catch(i)})},sI=e=>{let t;return e?t=e:typeof fetch>"u"?t=(...n)=>Gl(async()=>{const{default:r}=await Promise.resolve().then(()=>na);return{default:r}},void 0).then(({default:r})=>r(...n)):t=fetch,(...n)=>t(...n)};class fv extends Error{constructor(t,n="FunctionsError",r){super(t),this.name=n,this.context=r}}class hw extends fv{constructor(t){super("Failed to send a request to the Edge Function","FunctionsFetchError",t)}}class pw extends fv{constructor(t){super("Relay Error invoking the Edge Function","FunctionsRelayError",t)}}class mw extends fv{constructor(t){super("Edge Function returned a non-2xx status code","FunctionsHttpError",t)}}var rm;(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"})(rm||(rm={}));var iI=function(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())})};class oI{constructor(t,{headers:n={},customFetch:r,region:s=rm.Any}={}){this.url=t,this.headers=n,this.region=s,this.fetch=sI(r)}setAuth(t){this.headers.Authorization=`Bearer ${t}`}invoke(t){return iI(this,arguments,void 0,function*(n,r={}){var s;try{const{headers:i,method:o,body:a,signal:l}=r;let c={},{region:u}=r;u||(u=this.region);const d=new URL(`${this.url}/${n}`);u&&u!=="any"&&(c["x-region"]=u,d.searchParams.set("forceFunctionRegion",u));let h;a&&(i&&!Object.prototype.hasOwnProperty.call(i,"Content-Type")||!i)&&(typeof Blob<"u"&&a instanceof Blob||a instanceof ArrayBuffer?(c["Content-Type"]="application/octet-stream",h=a):typeof a=="string"?(c["Content-Type"]="text/plain",h=a):typeof FormData<"u"&&a instanceof FormData?h=a:(c["Content-Type"]="application/json",h=JSON.stringify(a)));const p=yield this.fetch(d.toString(),{method:o||"POST",headers:Object.assign(Object.assign(Object.assign({},c),this.headers),i),body:h,signal:l}).catch(y=>{throw y.name==="AbortError"?y:new hw(y)}),b=p.headers.get("x-relay-error");if(b&&b==="true")throw new pw(p);if(!p.ok)throw new mw(p);let g=((s=p.headers.get("Content-Type"))!==null&&s!==void 0?s:"text/plain").split(";")[0].trim(),x;return g==="application/json"?x=yield p.json():g==="application/octet-stream"?x=yield p.blob():g==="text/event-stream"?x=p:g==="multipart/form-data"?x=yield p.formData():x=yield p.text(),{data:x,error:null,response:p}}catch(i){return i instanceof Error&&i.name==="AbortError"?{data:null,error:new hw(i)}:{data:null,error:i,response:i instanceof mw||i instanceof pw?i.context:void 0}}})}}var Ct={},hv={},Zd={},Ql={},Jd={},Xd={},aI=function(){if(typeof self<"u")return self;if(typeof window<"u")return window;if(typeof global<"u")return global;throw new Error("unable to locate global object")},$o=aI();const lI=$o.fetch,rE=$o.fetch.bind($o),sE=$o.Headers,cI=$o.Request,uI=$o.Response,na=Object.freeze(Object.defineProperty({__proto__:null,Headers:sE,Request:cI,Response:uI,default:rE,fetch:lI},Symbol.toStringTag,{value:"Module"})),dI=SA(na);var ef={};
153Object.defineProperty(ef,"__esModule",{value:!0});let fI=class extends Error{constructor(t){super(t.message),this.name="PostgrestError",this.details=t.details,this.hint=t.hint,this.code=t.code}};ef.default=fI;var iE=an&&an.__importDefault||function(e){return e&&e.__esModule?e:{default:e}};Object.defineProperty(Xd,"__esModule",{value:!0});const hI=iE(dI),pI=iE(ef);let mI=class{constructor(t){var n,r;this.shouldThrowOnError=!1,this.method=t.method,this.url=t.url,this.headers=new Headers(t.headers),this.schema=t.schema,this.body=t.body,this.shouldThrowOnError=(n=t.shouldThrowOnError)!==null&&n!==void 0?n:!1,this.signal=t.signal,this.isMaybeSingle=(r=t.isMaybeSingle)!==null&&r!==void 0?r:!1,t.fetch?this.fetch=t.fetch:typeof fetch>"u"?this.fetch=hI.default:this.fetch=fetch}throwOnError(){return this.shouldThrowOnError=!0,this}setHeader(t,n){return this.headers=new Headers(this.headers),this.headers.set(t,n),this}then(t,n){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=>{var o,a,l,c;let u=null,d=null,h=null,p=i.status,b=i.statusText;if(i.ok){if(this.method!=="HEAD"){const m=await i.text();m===""||(this.headers.get("Accept")==="text/csv"||this.headers.get("Accept")&&(!((o=this.headers.get("Accept"))===null||o===void 0)&&o.includes("application/vnd.pgrst.plan+text"))?d=m:d=JSON.parse(m))}const x=(a=this.headers.get("Prefer"))===null||a===void 0?void 0:a.match(/count=(exact|planned|estimated)/),y=(l=i.headers.get("content-range"))===null||l===void 0?void 0:l.split("/");x&&y&&y.length>1&&(h=parseInt(y[1])),this.isMaybeSingle&&this.method==="GET"&&Array.isArray(d)&&(d.length>1?(u={code:"PGRST116",details:`Results contain ${d.length} rows, application/vnd.pgrst.object+json requires 1 row`,hint:null,message:"JSON object requested, multiple (or no) rows returned"},d=null,h=null,p=406,b="Not Acceptable"):d.length===1?d=d[0]:d=null)}else{const x=await i.text();try{u=JSON.parse(x),Array.isArray(u)&&i.status===404&&(d=[],u=null,p=200,b="OK")}catch{i.status===404&&x===""?(p=204,b="No Content"):u={message:x}}if(u&&this.isMaybeSingle&&(!((c=u==null?void 0:u.details)===null||c===void 0)&&c.includes("0 rows"))&&(u=null,p=200,b="OK"),u&&this.shouldThrowOnError)throw new pI.default(u)}return{error:u,data:d,count:h,status:p,statusText:b}});return this.shouldThrowOnError||(s=s.catch(i=>{var o,a,l;return{error:{message:`${(o=i==null?void 0:i.name)!==null&&o!==void 0?o:"FetchError"}: ${i==null?void 0:i.message}`,details:`${(a=i==null?void 0:i.stack)!==null&&a!==void 0?a:""}`,hint:"",code:`${(l=i==null?void 0:i.code)!==null&&l!==void 0?l:""}`},data:null,count:null,status:0,statusText:""}})),s.then(t,n)}returns(){return this}overrideTypes(){return this}};Xd.default=mI;var gI=an&&an.__importDefault||function(e){return e&&e.__esModule?e:{default:e}};Object.defineProperty(Jd,"__esModule",{value:!0});const vI=gI(Xd);let yI=class extends vI.default{select(t){let n=!1;const r=(t??"*").split("").map(s=>/\s/.test(s)&&!n?"":(s==='"'&&(n=!n),s)).join("");return this.url.searchParams.set("select",r),this.headers.append("Prefer","return=representation"),this}order(t,{ascending:n=!0,nullsFirst:r,foreignTable:s,referencedTable:i=s}={}){const o=i?`${i}.order`:"order",a=this.url.searchParams.get(o);return this.url.searchParams.set(o,`${a?`${a},`:""}${t}.${n?"asc":"desc"}${r===void 0?"":r?".nullsfirst":".nullslast"}`),this}limit(t,{foreignTable:n,referencedTable:r=n}={}){const s=typeof r>"u"?"limit":`${r}.limit`;return this.url.searchParams.set(s,`${t}`),this}range(t,n,{foreignTable:r,referencedTable:s=r}={}){const i=typeof s>"u"?"offset":`${s}.offset`,o=typeof s>"u"?"limit":`${s}.limit`;return this.url.searchParams.set(i,`${t}`),this.url.searchParams.set(o,`${n-t+1}`),this}abortSignal(t){return this.signal=t,this}single(){return this.headers.set("Accept","application/vnd.pgrst.object+json"),this}maybeSingle(){return this.method==="GET"?this.headers.set("Accept","application/json"):this.headers.set("Accept","application/vnd.pgrst.object+json"),this.isMaybeSingle=!0,this}csv(){return this.headers.set("Accept","text/csv"),this}geojson(){return this.headers.set("Accept","application/geo+json"),this}
153explain({analyze:t=!1,verbose:n=!1,settings:r=!1,buffers:s=!1,wal:i=!1,format:o="text"}={}){var a;const l=[t?"analyze":null,n?"verbose":null,r?"settings":null,s?"buffers":null,i?"wal":null].filter(Boolean).join("|"),c=(a=this.headers.get("Accept"))!==null&&a!==void 0?a:"application/json";return this.headers.set("Accept",`application/vnd.pgrst.plan+${o}; for="${c}"; options=${l};`),o==="json"?this:this}rollback(){return this.headers.append("Prefer","tx=rollback"),this}returns(){return this}maxAffected(t){return this.headers.append("Prefer","handling=strict"),this.headers.append("Prefer",`max-affected=${t}`),this}};Jd.default=yI;var wI=an&&an.__importDefault||function(e){return e&&e.__esModule?e:{default:e}};Object.defineProperty(Ql,"__esModule",{value:!0});const xI=wI(Jd);let bI=class extends xI.default{eq(t,n){return this.url.searchParams.append(t,`eq.${n}`),this}neq(t,n){return this.url.searchParams.append(t,`neq.${n}`),this}gt(t,n){return this.url.searchParams.append(t,`gt.${n}`),this}gte(t,n){return this.url.searchParams.append(t,`gte.${n}`),this}lt(t,n){return this.url.searchParams.append(t,`lt.${n}`),this}lte(t,n){return this.url.searchParams.append(t,`lte.${n}`),this}like(t,n){return this.url.searchParams.append(t,`like.${n}`),this}likeAllOf(t,n){return this.url.searchParams.append(t,`like(all).{${n.join(",")}}`),this}likeAnyOf(t,n){return this.url.searchParams.append(t,`like(any).{${n.join(",")}}`),this}ilike(t,n){return this.url.searchParams.append(t,`ilike.${n}`),this}ilikeAllOf(t,n){return this.url.searchParams.append(t,`ilike(all).{${n.join(",")}}`),this}ilikeAnyOf(t,n){return this.url.searchParams.append(t,`ilike(any).{${n.join(",")}}`),this}is(t,n){return this.url.searchParams.append(t,`is.${n}`),this}in(t,n){const r=Array.from(new Set(n)).map(s=>typeof s=="string"&&new RegExp("[,()]").test(s)?`"${s}"`:`${s}`).join(",");return this.url.searchParams.append(t,`in.(${r})`),this}contains(t,n){return typeof n=="string"?this.url.searchParams.append(t,`cs.${n}`):Array.isArray(n)?this.url.searchParams.append(t,`cs.{${n.join(",")}}`):this.url.searchParams.append(t,`cs.${JSON.stringify(n)}`),this}containedBy(t,n){return typeof n=="string"?this.url.searchParams.append(t,`cd.${n}`):Array.isArray(n)?this.url.searchParams.append(t,`cd.{${n.join(",")}}`):this.url.searchParams.append(t,`cd.${JSON.stringify(n)}`),this}rangeGt(t,n){return this.url.searchParams.append(t,`sr.${n}`),this}rangeGte(t,n){return this.url.searchParams.append(t,`nxl.${n}`),this}rangeLt(t,n){return this.url.searchParams.append(t,`sl.${n}`),this}rangeLte(t,n){return this.url.searchParams.append(t,`nxr.${n}`),this}rangeAdjacent(t,n){return this.url.searchParams.append(t,`adj.${n}`),this}overlaps(t,n){return typeof n=="string"?this.url.searchParams.append(t,`ov.${n}`):this.url.searchParams.append(t,`ov.{${n.join(",")}}`),this}textSearch(t,n,{config:r,type:s}={}){let i="";s==="plain"?i="pl":s==="phrase"?i="ph":s==="websearch"&&(i="w");const o=r===void 0?"":`(${r})`;return this.url.searchParams.append(t,`${i}fts${o}.${n}`),this}match(t){return Object.entries(t).forEach(([n,r])=>{this.url.searchParams.append(n,`eq.${r}`)}),this}not(t,n,r){return this.url.searchParams.append(t,`not.${n}.${r}`),this}or(t,{foreignTable:n,referencedTable:r=n}={}){const s=r?`${r}.or`:"or";return this.url.searchParams.append(s,`(${t})`),this}filter(t,n,r){return this.url.searchParams.append(t,`${n}.${r}`),this}};Ql.default=bI;var _I=an&&an.__importDefault||function(e){return e&&e.__esModule?e:{default:e}};Object.defineProperty(Zd,"__esModule",{value:!0});const ba=_I(Ql);let SI=class{constructor(t,{headers:n={},schema:r,fetch:s}){this.url=t,this.headers=new Headers(n),this.schema=r,this.fetch=s}select(t,n){const{head:r=!1,count:s}=n??{},i=r?"HEAD":"GET";let o=!1;const a=(t??"*").split("").map(l=>/\s/.test(l)&&!o?"":(l==='"'&&(o=!o),l)).join("");return this.url.searchParams.set("select",a),s&&this.headers.append("Prefer",`count=${s}`),new ba.default({method:i,url:this.url,headers:this.headers,schema:this.schema,fetch:this.fetch})}insert(t,{count:n,defaultToNull:r=!0}={}){var s;const i="POST";if(n&&this.headers.append("Prefer",`count=${n}`),r||this.headers.append("Prefer","missing=default"),Array.isArray(t)){const o=t.reduce((a,l)=>a.concat(Object.keys(l)),[]);if(o.length>
1530){const a=[...new Set(o)].map(l=>`"${l}"`);this.url.searchParams.set("columns",a.join(","))}}return new ba.default({method:i,url:this.url,headers:this.headers,schema:this.schema,body:t,fetch:(s=this.fetch)!==null&&s!==void 0?s:fetch})}upsert(t,{onConflict:n,ignoreDuplicates:r=!1,count:s,defaultToNull:i=!0}={}){var o;const a="POST";if(this.headers.append("Prefer",`resolution=${r?"ignore":"merge"}-duplicates`),n!==void 0&&this.url.searchParams.set("on_conflict",n),s&&this.headers.append("Prefer",`count=${s}`),i||this.headers.append("Prefer","missing=default"),Array.isArray(t)){const l=t.reduce((c,u)=>c.concat(Object.keys(u)),[]);if(l.length>0){const c=[...new Set(l)].map(u=>`"${u}"`);this.url.searchParams.set("columns",c.join(","))}}return new ba.default({method:a,url:this.url,headers:this.headers,schema:this.schema,body:t,fetch:(o=this.fetch)!==null&&o!==void 0?o:fetch})}update(t,{count:n}={}){var r;const s="PATCH";return n&&this.headers.append("Prefer",`count=${n}`),new ba.default({method:s,url:this.url,headers:this.headers,schema:this.schema,body:t,fetch:(r=this.fetch)!==null&&r!==void 0?r:fetch})}delete({count:t}={}){var n;const r="DELETE";return t&&this.headers.append("Prefer",`count=${t}`),new ba.default({method:r,url:this.url,headers:this.headers,schema:this.schema,fetch:(n=this.fetch)!==null&&n!==void 0?n:fetch})}};Zd.default=SI;var oE=an&&an.__importDefault||function(e){return e&&e.__esModule?e:{default:e}};Object.defineProperty(hv,"__esModule",{value:!0});const kI=oE(Zd),EI=oE(Ql);let CI=class aE{constructor(t,{headers:n={},schema:r,fetch:s}={}){this.url=t,this.headers=new Headers(n),this.schemaName=r,this.fetch=s}from(t){const n=new URL(`${this.url}/${t}`);return new kI.default(n,{headers:new Headers(this.headers),schema:this.schemaName,fetch:this.fetch})}schema(t){return new aE(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;r||s?(a=r?"HEAD":"GET",Object.entries(n).filter(([d,h])=>h!==void 0).map(([d,h])=>[d,Array.isArray(h)?`{${h.join(",")}}`:`${h}`]).forEach(([d,h])=>{l.searchParams.append(d,h)})):(a="POST",c=n);const u=new Headers(this.headers);return i&&u.set("Prefer",`count=${i}`),new EI.default({method:a,url:l,headers:u,schema:this.schemaName,body:c,fetch:(o=this.fetch)!==null&&o!==void 0?o:fetch})}};hv.default=CI;var ra=an&&an.__importDefault||function(e){return e&&e.__esModule?e:{default:e}};Object.defineProperty(Ct,"__esModule",{value:!0});Ct.PostgrestError=Ct.PostgrestBuilder=Ct.PostgrestTransformBuilder=Ct.PostgrestFilterBuilder=Ct.PostgrestQueryBuilder=Ct.PostgrestClient=void 0;const lE=ra(hv);Ct.PostgrestClient=lE.default;const cE=ra(Zd);Ct.PostgrestQueryBuilder=cE.default;const uE=ra(Ql);Ct.PostgrestFilterBuilder=uE.default;const dE=ra(Jd);Ct.PostgrestTransformBuilder=dE.default;const fE=ra(Xd);Ct.PostgrestBuilder=fE.default;const hE=ra(ef);Ct.PostgrestError=hE.default;var TI=Ct.default={PostgrestClient:lE.default,PostgrestQueryBuilder:cE.default,PostgrestFilterBuilder:uE.default,PostgrestTransformBuilder:dE.default,PostgrestBuilder:fE.default,PostgrestError:hE.default};const{PostgrestClient:AI,PostgrestQueryBuilder:bW,PostgrestFilterBuilder:_W,PostgrestTransformBuilder:SW,PostgrestBuilder:kW,PostgrestError:EW}=TI;class PI{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."};if(typeof process<"u"){const n=process.versions;if(n&&n.node){const r=n.node,s=parseInt(r.replace(/^v/,"").split(".")[0]);return s>=22?typeof globalThis.WebSocket<"u"?{type:"native",constructor:globalThis.WebSocket}:{type:"unsupported",error:`Node.js ${s} detected but native WebSocket not found.`,workaround:"Provide a WebSocket implementation via the transport option."}:{type:"unsupported",error:`Node.js ${s} detected without native WebSocket support.`,workaround:`For Node.js < 22, install "ws" package and provide it via the transport option:
154import ws from "ws"
155new 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+=`
156
157Suggested 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 jI="2.75.1",NI=`realtime-js/${jI}`,RI="1.0.0",sm=1e4,OI=1e3,MI=100;var Wa;(function(e){e[e.connecting=0]="connecting",e[e.open=1]="open",e[e.closing=2]="closing",e[e.closed=3]="closed"})(Wa||(Wa={}));var qe;(function(e){e.closed="closed",e.errored="errored",e.joined="joined",e.joining="joining",e.leaving="leaving"})(qe||(qe={}));var En;(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"})(En||(En={}));var im;(function(e){e.websocket="websocket"})(im||(im={}));var Ks;(function(e){e.Connecting="connecting",e.Open="open",e.Closing="closing",e.Closed="closed"})(Ks||(Ks={}));class DI{constructor(){this.HEADER_LENGTH=1}decode(t,n){return t.constructor===ArrayBuffer?n(this._binaryDecode(t)):n(typeof t=="string"?JSON.parse(t):{})}_binaryDecode(t){const n=new DataView(t),r=new TextDecoder;return this._decodeBroadcast(t,n,r)}_decodeBroadcast(t,n,r){const s=n.getUint8(1),i=n.getUint8(2);let o=this.HEADER_LENGTH+2;const a=r.decode(t.slice(o,o+s));o=o+s;const l=r.decode(t.slice(o,o+i));o=o+i;const c=JSON.parse(r.decode(t.slice(o,t.byteLength)));return{ref:null,topic:a,event:l,payload:c}}}class pE{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 be;(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"})(be||(be={}));const gw=(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]=II(o,e,t,s),i),{}):{}},II=(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)?mE(i,o):om(o)},mE=(e,t)=>{if(e.charAt(0)==="_"){const n=e.slice(1,e.length);return BI(t,n)}switch(e){case be.bool:return LI(t);case be.float4:case be.float8:case be.int2:case be.int4:case be.int8:case be.numeric:case be.oid:return FI(t);case be.json:case be.jsonb:return $I(t);case be.timestamp:return VI(t);case be.abstime:case be.date:case be.daterange:case be.int4range:case be.int8range:case be.money:case be.reltime:case be.text:case be.time:case be.timestamptz:case be.timetz:case be.tsrange:case be.tstzrange:return om(t);default:return om(t)}},om=e=>e,LI=e=>{switch(e){case"t":return!0;case"f":return!1;default:return e}},FI=e=>{if(typeof e=="string"){const t=parseFloat(e);
157if(!Number.isNaN(t))return t}return e},$I=e=>{if(typeof e=="string")try{return JSON.parse(e)}catch(t){return console.log(`JSON parse error: ${t}`),e}return e},BI=(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=>mE(t,a))}return e},VI=e=>typeof e=="string"?e.replace(" ","T"):e,gE=e=>{let t=e;return t=t.replace(/^ws/i,"http"),t=t.replace(/(\/socket\/websocket|\/socket|\/websocket)\/?$/i,""),t.replace(/\/+$/,"")+"/api/broadcast"};class rh{constructor(t,n,r={},s=sm){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.recHooks.push({status:t,callback:n}),this}startTimeout(){if(this.timeoutTimer)return;this.ref=this.channel.socket._makeRef(),this.refEvent=this.channel._replyEventName(this.ref);const t=n=>{this._cancelRefEvent(),this._cancelTimeout(),this.receivedResp=n,this._matchReceive(n)};this.channel._on(this.refEvent,{},t),this.timeoutTimer=setTimeout(()=>{this.trigger("timeout",{})},this.timeout)}trigger(t,n){this.refEvent&&this.channel._trigger(this.refEvent,{status:t,response:n})}destroy(){this._cancelRefEvent(),this._cancelTimeout()}_cancelRefEvent(){this.refEvent&&this.channel._off(this.refEvent,{})}_cancelTimeout(){clearTimeout(this.timeoutTimer),this.timeoutTimer=void 0}_matchReceive({status:t,response:n}){this.recHooks.filter(r=>r.status===t).forEach(r=>r.callback(n))}_hasReceived(t){return this.receivedResp&&this.receivedResp.status===t}}var vw;(function(e){e.SYNC="sync",e.JOIN="join",e.LEAVE="leave"})(vw||(vw={}));class Ha{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=Ha.syncState(this.state,s,i,o),this.pendingDiffs.forEach(l=>{this.state=Ha.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=Ha.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),p=d.map(x=>x.presence_ref),b=u.filter(x=>p.indexOf(x.presence_ref)<0),g=d.filter(x=>h.indexOf(x.presence_ref)<0);b.length>0&&(a[c]=b),g.length>0&&(l[c]=g)}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(p=>p.presence_ref),h=u.filter(p=>d.indexOf(p.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 yw;(function(e){e.ALL="*",e.INSERT="INSERT",e.UPDATE="UPDATE",e.DELETE="DELETE"})(yw||(yw={}));var Ka;(function(e){e.BROADCAST="broadcast",e.PRESENCE="presence",e.POSTGRES_CHANGES="postgres_changes",e.SYSTEM="system"})(Ka||(Ka={}));var wr;(function(e){e.SUBSCRIBED="SUBSCRIBED",e.TIMED_OUT="TIMED_OUT",e.CLOSED="CLOSED",e.CHANNEL_ERROR="CHANNEL_ERROR"})(wr||(wr={}));class pv{constructor(t,n={config:{}},r){var s,i;if(this.topic=t,this.params=n,this.socket=r,this.bindings={},this.state=qe.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 rh(this,En.join,this.params,this.timeout),this.rejoinTimer=new pE(()=>this._rejoinUntilConnected(),this.socket.reconnectAfterMs),this.joinPush.receive("ok",()=>{this.state=qe.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=qe.closed,this.socket._remove(this)}),this._onError(o=>{this._isLeaving()||this._isClosed()||(this.socket.log("channel",`error ${this.topic}`,o),this.state=qe.errored,this.rejoinTimer.scheduleTimeout())}),this.joinPush.receive("timeout",()=>{this._isJoining()&&(this.socket.log("channel",`timeout ${this.topic}`,this.joinPush.timeout),this.state=qe.errored,this.rejoinTimer.scheduleTimeout())}),this.joinPush.receive("error",o=>{this._isLeaving()||this._isClosed()||(this.socket.log("channel",`error ${this.topic}`,o),this.state=qe.errored,this.rejoinTimer.scheduleTimeout())}),this._on(En.reply,{},(o,a)=>{this._trigger(this._replyEventName(a),o)}),this.presence=new Ha(this),this.broadcastEndpointURL=gE(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==qe.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(p=>p.filter))!==null&&s!==void 0?s:[],u=!!this.bindings[Ka.PRESENCE]&&this.bindings[Ka.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(p=>t==null?void 0:t(wr.CHANNEL_ERROR,p)),this._onClose(()=>t==null?void 0:t(wr.CLOSED)),this.updateJoinPayload(Object.assign({config:h},d)),this.joinedOnce=!0,this._rejoin(n),this.joinPush.receive("ok",async({postgres_changes:p})=>{var b;if(this.socket.setAuth(),p===void 0){t==null||t(wr.SUBSCRIBED);return}else{const g=this.bindings.postgres_changes,x=(b=g==null?void 0:g.length)!==null&&b!==void 0?b:0,y=[];for(let m=0;m<x;m++){const v=g[m],{filter:{event:_,schema:S,table:k,filter:E}}=v,T=p&&p[m];if(T&&T.event===_&&T.schema===S&&T.table===k&&T.filter===E)y.push(Object.assign(Object.assign({},v),{id:T.id}));else{this.unsubscribe(),this.state=qe.errored,t==null||t(wr.CHANNEL_ERROR,new Error("mismatch between server and client bindings for postgres changes"));return}}this.bindings.postgres_changes=y,t&&t(wr.SUBSCRIBED);return}}).receive("error",p=>{this.state=qe.errored,t==null||t(wr.CHANNEL_ERROR,new Error(JSON.stringify(Object.values(p).join(", ")||"error")))}).receive("timeout",()=>{t==null||t(wr.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===qe.joined&&t===Ka.PRESENCE&&(this.socket.log("channel",`resubscribe to ${this.topic} due to change in presence callbacks on joined channel`),this.unsubscribe().then(()=>this.subscribe())),this._on(t,n,r)}async send(t,n={}){var r,s;if(!this._canPush()&&t.type==="broadcast"){const{event:i,payload:o}=t,l={method:"POST",headers:{Authorization:this.socket.accessTokenValue?`Bearer ${this.socket.accessTokenValue}`:"",apikey:this.socket.apiKey?this.socket.apiKey:"","Content-Type":"application/json"},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=qe.leaving;const n=()=>{this.socket.log("channel",`leave ${this.topic}`),this._trigger(En.close,"leave",this._joinRef())};this.joinPush.destroy();let r=null;return new Promise(s=>{r=new rh(this,En.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=qe.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 rh(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>MI){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}=En;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(p=>{var b,g,x;return((b=p.filter)===null||b===void 0?void 0:b.event)==="*"||((x=(g=p.filter)===null||g===void 0?void 0:g.event)===null||x===void 0?void 0:x.toLocaleLowerCase())===o}).map(p=>p.callback(h,r)):(i=this.bindings[o])===null||i===void 0||i.filter(p=>{var b,g,x,y,m,v;if(["broadcast","presence","postgres_changes"].includes(o))if("id"in p){const _=p.id,S=(b=p.filter)===null||b===void 0?void 0:b.event;return _&&((g=n.ids)===null||g===void 0?void 0:g.includes(_))&&(S==="*"||(S==null?void 0:S.toLocaleLowerCase())===((x=n.data)===null||x===void 0?void 0:x.type.toLocaleLowerCase()))}else{const _=(m=(y=p==null?void 0:p.filter)===null||y===void 0?void 0:y.event)===null||m===void 0?void 0:m.toLocaleLowerCase();return _==="*"||_===((v=n==null?void 0:n.event)===null||v===void 0?void 0:v.toLocaleLowerCase())}else return p.type.toLocaleLowerCase()===o}).map(p=>{if(typeof h=="object"&&"ids"in h){const b=h.data,{schema:g,table:x,commit_timestamp:y,type:m,errors:v}=b;h=Object.assign(Object.assign({},{schema:g,table:x,commit_timestamp:y,eventType:m,new:{},old:{},errors:v}),this._getPayloadRecords(b))}p.callback(h,r)})}_isClosed(){return this.state===qe.closed}_isJoined(){return this.state===qe.joined}_isJoining(){return this.state===qe.joining}_isLeaving(){return this.state===qe.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&&pv.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}_rejoinUntilConnected(){this.rejoinTimer.scheduleTimeout(),this.socket.isConnected()&&this._rejoin()}_onClose(t){this._on(En.close,{},t)}_onError(t){this._on(En.error,{},n=>t(n))}_canPush(){return this.socket.isConnected()&&this._isJoined()}_rejoin(t=this.timeout){this._isLeaving()||(this.socket._leaveOpenTopic(this.topic),this.state=qe.joining,this.joinPush.resend(t))}_getPayloadRecords(t){const n={new:{},old:{}};return(t.type==="INSERT"||t.type==="UPDATE")&&(n.new=gw(t.columns,t.record)),(t.type==="UPDATE"||t.type==="DELETE")&&(n.old=gw(t.columns,t.old_record)),n}}const sh=()=>{},Mc={HEARTBEAT_INTERVAL:25e3,RECONNECT_DELAY:10,HEARTBEAT_TIMEOUT_FALLBACK:100},UI=[1e3,2e3,5e3,1e4],zI=1e4,WI=`
158  addEventListener("message", (e) => {
159    if (e.data.event === "start") {
160      setInterval(() => postMessage({ event: "keepAlive" }), e.data.interval);
161    }
162  });`;class HI{constructor(t,n){var r;if(this.accessTokenValue=null,this.apiKey=null,this.channels=new Array,this.endPoint="",this.httpEndpoint="",this.headers={},this.params={},this.timeout=sm,this.transport=null,this.heartbeatIntervalMs=Mc.HEARTBEAT_INTERVAL,this.heartbeatTimer=void 0,this.pendingHeartbeatRef=null,this.heartbeatCallback=sh,this.ref=0,this.reconnectTimer=null,this.logger=sh,this.conn=null,this.sendBuffer=[],this.serializer
162=new DI,this.stateChangeCallbacks={open:[],close:[],error:[],message:[]},this.accessToken=null,this._connectionState="disconnected",this._wasManualDisconnect=!1,this._authPromise=null,this._resolveFetch=s=>{let i;return s?i=s:typeof fetch>"u"?i=(...o)=>Gl(async()=>{const{default:a}=await Promise.resolve().then(()=>na);return{default:a}},void 0).then(({default:a})=>a(...o)).catch(a=>{throw new Error(`Failed to load @supabase/node-fetch: ${a.message}. This is required for HTTP requests in Node.js environments without native fetch.`)}):i=fetch,(...o)=>i(...o)},!(!((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}/${im.websocket}`,this.httpEndpoint=gE(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._setAuthSafely("connect"),this.transport)this.conn=new this.transport(this.endpointURL());else try{this.conn=PI.createWebSocket(this.endpointURL())}catch(t){this._setConnectionState("disconnected");const n=t.message;throw n.includes("Node.js")?new Error(`${n}
163
164To use Realtime in Node.js, you need to provide a WebSocket implementation:
165
166Option 1: Use Node.js 22+ which has native WebSocket support
167Option 2: Install and provide the "ws" package:
168
169  npm install ws
170
171  import ws from "ws"
172  const client = new RealtimeClient(url, {
173    ...options,
174    transport: ws
175  })`):new Error(`WebSocket not available: ${n}`)}this._setupConnectionHandlers()}}endpointURL(){return this._appendParams(this.endPoint,Object.assign({},this.params,{vsn:RI}))}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")},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 Wa.connecting:return Ks.Connecting;case Wa.open:return Ks.Open;case Wa.closing:return Ks.Closing;default:return Ks.Closed}}isConnected(){return this.connectionState()===Ks.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 pv(`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}}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.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(OI,"heartbeat timeout"),setTimeout(()=>{var n;this.isConnected()||(n=this.reconnectTimer)===null||n===void 0||n.scheduleTimeout()},Mc.HEARTBEAT_TIMEOUT_FALLBACK);return}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=>
175{if(n.topic==="phoenix"&&n.event==="phx_reply")try{this.heartbeatCallback(n.payload.status==="ok"?"ok":"error")}catch(c){this.log("error","error in heartbeat callback",c)}n.ref&&n.ref===this.pendingHeartbeatRef&&(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))}_teardownConnection(){this.conn&&(this.conn.onopen=null,this.conn.onerror=null,this.conn.onmessage=null,this.conn.onclose=null,this.conn=null),this._clearAllTimers(),this.channels.forEach(t=>t.teardown())}_onConnOpen(){this._setConnectionState("connected"),this.log("transport",`connected to ${this.endpointURL()}`),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.workerRef.terminate()},this.workerRef.onmessage=n=>{n.data.event==="keepAlive"&&this.sendHeartbeat()},this.workerRef.postMessage({event:"start",interval:this.heartbeatIntervalMs})}_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)}_triggerChanError(){this.channels.forEach(t=>t._trigger(En.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([WI],{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;t?n=t:this.accessToken?n=await this.accessToken():n=this.accessTokenValue,this.accessTokenValue!=n&&(this.accessTokenValue=n,this.channels.forEach(r=>{const s={access_token:n,version:NI};n&&r.updateJoinPayload(s),r.joinedOnce&&r._isJoined()&&r._push(En.access_token,{access_token:n})}))}async _waitForAuthIfNeeded(){this._authPromise&&await this._authPromise}_setAuthSafely(t="general"){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 pE(async()=>{setTimeout(async()=>{await this._waitForAuthIfNeeded(),this.isConnected()||this.connect()},Mc.RECONNECT_DELAY)},this.reconnectAfterMs)}_initializeOptions(t){var n,r,s,i,o,a,l,c,u;if(this.transport=(n=t==null?void 0:t.transport)!==null&&n!==void 0?n:null,this.timeout=(r=t==null?void 0:t.t
175imeout)!==null&&r!==void 0?r:sm,this.heartbeatIntervalMs=(s=t==null?void 0:t.heartbeatIntervalMs)!==null&&s!==void 0?s:Mc.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:sh,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=(l=t==null?void 0:t.reconnectAfterMs)!==null&&l!==void 0?l:d=>UI[d-1]||zI,this.encode=(c=t==null?void 0:t.encode)!==null&&c!==void 0?c:(d,h)=>h(JSON.stringify(d)),this.decode=(u=t==null?void 0:t.decode)!==null&&u!==void 0?u:this.serializer.decode.bind(this.serializer),this.worker){if(typeof window<"u"&&!window.Worker)throw new Error("Web Worker is not supported");this.workerUrl=t==null?void 0:t.workerUrl}}}class mv extends Error{constructor(t){super(t),this.__isStorageError=!0,this.name="StorageError"}}function ze(e){return typeof e=="object"&&e!==null&&"__isStorageError"in e}class KI extends mv{constructor(t,n,r){super(t),this.name="StorageApiError",this.status=n,this.statusCode=r}toJSON(){return{name:this.name,message:this.message,status:this.status,statusCode:this.statusCode}}}class am extends mv{constructor(t,n){super(t),this.name="StorageUnknownError",this.originalError=n}}var qI=function(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 vE=e=>{let t;return e?t=e:typeof fetch>"u"?t=(...n)=>Gl(async()=>{const{default:r}=await Promise.resolve().then(()=>na);return{default:r}},void 0).then(({default:r})=>r(...n)):t=fetch,(...n)=>t(...n)},YI=()=>qI(void 0,void 0,void 0,function*(){return typeof Response>"u"?(yield Gl(()=>Promise.resolve().then(()=>na),void 0)).Response:Response}),lm=e=>{if(Array.isArray(e))return e.map(n=>lm(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]=lm(r)}),t},GI=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)};var Ei=function(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 ih=e=>e.msg||e.message||e.error_description||e.error||JSON.stringify(e),QI=(e,t,n)=>Ei(void 0,void 0,void 0,function*(){const r=yield YI();e instanceof r&&!(n!=null&&n.noResolveJson)?e.json().then(s=>{const i=e.status||500,o=(s==null?void 0:s.statusCode)||i+"";t(new KI(ih(s),i,o))}).catch(s=>{t(new am(ih(s),s))}):t(new am(ih(e),e))}),ZI=(e,t,n,r)=>{const s={method:e,headers:(t==null?void 0:t.headers)||{}};return e==="GET"||!r?s:(GI(r)?(s.headers=Object.assign({"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),Object.assign(Object.assign({},s),n))};function Zl(e,t,n,r,s,i){return Ei(this,void 0,void 0,function*(){return new Promise((o,a)=>{e(n,ZI(t,r,s,i)).then(l=>{if(!l.ok)throw l;return r!=null&&r.noResolveJson?l:l.json()}).then(l=>o(l)).catch(l=>QI(l,a,r))})})}function td(e,t,n,r){return Ei(this,void 0,void 0,function*(){return Zl(e,"GET",t,n,r)})}function Wn(e,t,n,r,s){return Ei(this,void 0,void 0,function*(){return Zl(e,"POST",t,r,s,n)})}function cm(e,t,n,r,s){return Ei(this,void 0,void 0,function*(){return Zl(e,"PUT",t,r,s,n)})}function JI(e,t,n,r){return Ei(this,void 0,void 0,function*(){return Zl(e,"HEAD",t,Object.assign(Object.assign({},n),{noResolveJson:!0}),r)})}
175function yE(e,t,n,r,s){return Ei(this,void 0,void 0,function*(){return Zl(e,"DELETE",t,r,s,n)})}var XI=function(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())})};class eL{constructor(t,n){this.downloadFn=t,this.shouldThrowOnError=n}then(t,n){return this.execute().then(t,n)}execute(){return XI(this,void 0,void 0,function*(){try{return{data:(yield this.downloadFn()).body,error:null}}catch(t){if(this.shouldThrowOnError)throw t;if(ze(t))return{data:null,error:t};throw t}})}}var tL=function(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())})},wE;class nL{constructor(t,n){this.downloadFn=t,this.shouldThrowOnError=n,this[wE]="BlobDownloadBuilder",this.promise=null}asStream(){return new eL(this.downloadFn,this.shouldThrowOnError)}then(t,n){return this.getPromise().then(t,n)}catch(t){return this.getPromise().catch(t)}finally(t){return this.getPromise().finally(t)}getPromise(){return this.promise||(this.promise=this.execute()),this.promise}execute(){return tL(this,void 0,void 0,function*(){try{return{data:yield(yield this.downloadFn()).blob(),error:null}}catch(t){if(this.shouldThrowOnError)throw t;if(ze(t))return{data:null,error:t};throw t}})}}wE=Symbol.toStringTag;var St=function(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 rL={limit:100,offset:0,sortBy:{column:"name",order:"asc"}},ww={cacheControl:"3600",contentType:"text/plain;charset=UTF-8",upsert:!1};class sL{constructor(t,n={},r,s){this.shouldThrowOnError=!1,this.url=t,this.headers=n,this.bucketId=r,this.fetch=vE(s)}throwOnError(){return this.shouldThrowOnError=!0,this}uploadOrUpdate(t,n,r,s){return St(this,void 0,void 0,function*(){try{let i;const o=Object.assign(Object.assign({},ww),s);let a=Object.assign(Object.assign({},this.headers),t==="POST"&&{"x-upsert":String(o.upsert)});const l=o.metadata;typeof Blob<"u"&&r instanceof Blob?(i=new FormData,i.append("cacheControl",o.cacheControl),l&&i.append("metadata",this.encodeMetadata(l)),i.append("",r)):typeof FormData<"u"&&r instanceof FormData?(i=r,i.append("cacheControl",o.cacheControl),l&&i.append("metadata",this.encodeMetadata(l))):(i=r,a["cache-control"]=`max-age=${o.cacheControl}`,a["content-type"]=o.contentType,l&&(a["x-metadata"]=this.toBase64(this.encodeMetadata(l)))),s!=null&&s.headers&&(a=Object.assign(Object.assign({},a),s.headers));const c=this._removeEmptyFolders(n),u=this._getFinalPath(c),d=yield(t=="PUT"?cm:Wn)(this.fetch,`${this.url}/object/${u}`,i,Object.assign({headers:a},o!=null&&o.duplex?{duplex:o.duplex}:{}));return{data:{path:c,id:d.Id,fullPath:d.Key},error:null}}catch(i){if(this.shouldThrowOnError)throw i;if(ze(i))return{data:null,error:i};throw i}})}upload(t,n,r){return St(this,void 0,void 0,function*(){return this.uploadOrUpdate("POST",t,n,r)})}uploadToSignedUrl(t,n,r,s){return St(this,void 0,void 0,function*(){const i=this._removeEmptyFolders(t),o=this._getFinalPath(i),a=new URL(this.url+`/object/upload/sign/${o}`);a.searchParams.set("token",n);try{let l;const c=Object.assign({upsert:ww.upsert},s),u=Object.assign(Object.assign({},this.headers),{"x-upsert":String(c.upsert)});typeof Blob<"u"&&r instanceof Blob?(l=new FormData,l.append("cacheControl",c.cacheControl),l.append("",r)):typeof FormData<"u"&&r instanceof FormData?(l=r,l.append("cacheControl",c.cacheControl)):(l=r,u["cache-control"]=`max-age=${c.cacheControl}`,u["content-type"]=c.contentType);const d=yield cm(this.fetch,a.toString(),l,{headers:u});return{data:{path:i,fullPath:d.Key},error:null}}catch(l){if(this.shouldThrowOnError)throw l;if(ze(l))return{data:null,error:l};throw l}})}createSignedUploadUrl(t,n){return St(this,void 0,void 0,function*(){try{let r=this._getFinalPath(t);const s=Object.assign({},this.headers);n!=null&&n.upsert&&(s["x-upsert"]="true");const i=yield Wn(this.fetch,`${this.url}/object/upload/sign/${r}`,{},{headers:s}),o=new URL(this.url+i.url),a=o.searchParams.get("token");if(!a)throw new mv("No token returned by API");return{data:{signedUrl:o.toString(),path:t,token:a},error:null}}catch(r){if(this.shouldThrowOnError)throw r;if(ze(r))return{data:null,error:r};throw r}})}update(t,n,r){return St(this,void 0,void 0,function*(){return this.uploadOrUpdate("PUT",t,n,r)})}move(t,n,r){return St(this,void 0,void 0,function*(){try{return{data:yield Wn(this.fetch,`${this.url}/object/move`,{bucketId:this.bucketId,sourceKey:t,destinationKey:n,destinationBucket:r==null?void 0:r.destinationBucket},{headers:this.headers}),error:null}}catch(s){if(this.shouldThrowOnError)throw s;if(ze(s))return{data:null,error:s};throw s}})}copy(t,n,r){return St(this,void 0,void 0,function*(){try{return{data:{path:(yield Wn(this.fetch,`${this.url}/object/copy`,{bucketId:this.bucketId,sourceKey:t,destinationKey:n,destinationBucket:r==null?void 0:r.destinationBucket},{headers:this.headers})).Key},error:null}}catch(s){if(this.shouldThrowOnError)throw s;if(ze(s))return{data:null,error:s};throw s}})}createSignedUrl(t,n,r){return St(this,void 0,void 0,function*(){try{let s=this._getFinalPath(t),i=yield Wn(this.fetch,`${this.url}/object/sign/${s}
175`,Object.assign({expiresIn:n},r!=null&&r.transform?{transform:r.transform}:{}),{headers:this.headers});const o=r!=null&&r.download?`&download=${r.download===!0?"":r.download}`:"";return i={signedUrl:encodeURI(`${this.url}${i.signedURL}${o}`)},{data:i,error:null}}catch(s){if(this.shouldThrowOnError)throw s;if(ze(s))return{data:null,error:s};throw s}})}createSignedUrls(t,n,r){return St(this,void 0,void 0,function*(){try{const s=yield Wn(this.fetch,`${this.url}/object/sign/${this.bucketId}`,{expiresIn:n,paths:t},{headers:this.headers}),i=r!=null&&r.download?`&download=${r.download===!0?"":r.download}`:"";return{data:s.map(o=>Object.assign(Object.assign({},o),{signedUrl:o.signedURL?encodeURI(`${this.url}${o.signedURL}${i}`):null})),error:null}}catch(s){if(this.shouldThrowOnError)throw s;if(ze(s))return{data:null,error:s};throw s}})}download(t,n){const s=typeof(n==null?void 0:n.transform)<"u"?"render/image/authenticated":"object",i=this.transformOptsToQueryString((n==null?void 0:n.transform)||{}),o=i?`?${i}`:"",a=this._getFinalPath(t),l=()=>td(this.fetch,`${this.url}/${s}/${a}${o}`,{headers:this.headers,noResolveJson:!0});return new nL(l,this.shouldThrowOnError)}info(t){return St(this,void 0,void 0,function*(){const n=this._getFinalPath(t);try{const r=yield td(this.fetch,`${this.url}/object/info/${n}`,{headers:this.headers});return{data:lm(r),error:null}}catch(r){if(this.shouldThrowOnError)throw r;if(ze(r))return{data:null,error:r};throw r}})}exists(t){return St(this,void 0,void 0,function*(){const n=this._getFinalPath(t);try{return yield JI(this.fetch,`${this.url}/object/${n}`,{headers:this.headers}),{data:!0,error:null}}catch(r){if(this.shouldThrowOnError)throw r;if(ze(r)&&r instanceof am){const s=r.originalError;if([400,404].includes(s==null?void 0:s.status))return{data:!1,error:r}}throw r}})}getPublicUrl(t,n){const r=this._getFinalPath(t),s=[],i=n!=null&&n.download?`download=${n.download===!0?"":n.download}`:"";i!==""&&s.push(i);const a=typeof(n==null?void 0:n.transform)<"u"?"render/image":"object",l=this.transformOptsToQueryString((n==null?void 0:n.transform)||{});l!==""&&s.push(l);let c=s.join("&");return c!==""&&(c=`?${c}`),{data:{publicUrl:encodeURI(`${this.url}/${a}/public/${r}${c}`)}}}remove(t){return St(this,void 0,void 0,function*(){try{return{data:yield yE(this.fetch,`${this.url}/object/${this.bucketId}`,{prefixes:t},{headers:this.headers}),error:null}}catch(n){if(this.shouldThrowOnError)throw n;if(ze(n))return{data:null,error:n};throw n}})}list(t,n,r){return St(this,void 0,void 0,function*(){try{const s=Object.assign(Object.assign(Object.assign({},rL),n),{prefix:t||""});return{data:yield Wn(this.fetch,`${this.url}/object/list/${this.bucketId}`,s,{headers:this.headers},r),error:null}}catch(s){if(this.shouldThrowOnError)throw s;if(ze(s))return{data:null,error:s};throw s}})}listV2(t,n){return St(this,void 0,void 0,function*(){try{const r=Object.assign({},t);return{data:yield Wn(this.fetch,`${this.url}/object/list-v2/${this.bucketId}`,r,{headers:this.headers},n),error:null}}catch(r){if(this.shouldThrowOnError)throw r;if(ze(r))return{data:null,error:r};throw r}})}encodeMetadata(t){return JSON.stringify(t)}toBase64(t){return typeof Buffer<"u"?Buffer.from(t).toString("base64"):btoa(t)}_getFinalPath(t){return`${this.bucketId}/${t.replace(/^\/+/,"")}`}_removeEmptyFolders(t){return t.replace(/^\/|\/$/g,"").replace(/\/+/g,"/")}transformOptsToQueryString(t){const n=[];return t.width&&n.push(`width=${t.width}`),t.height&&n.push(`height=${t.height}`),t.resize&&n.push(`resize=${t.resize}`),t.format&&n.push(`format=${t.format}`),t.quality&&n.push(`quality=${t.quality}`),n.join("&")}}const iL="2.75.1",oL={"X-Client-Info":`storage-js/${iL}`};var Oi=function(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())})};class aL{constructor(t,n={},r,s){this.shouldThrowOnError=!1;const i=new URL(t);s!=null&&s.useNewHostname&&/supabase\.(co|in|red)$/.test(i.hostname)&&!i.hostname.includes("storage.supabase.")&&(i.hostname=i.hostname.replace("supabase.","storage.supabase.")),this.url=i.href.replace(/\/$/,""),this.headers=Object.assign(Object.assign({},oL),n),this.fetch=vE(r)}throwOnError(){return this.shouldThrowOnError=!0,this}listBuckets(){return Oi(this,void 0,void 0,function*(){try{return{data:yield td(this.fetch,`${this.url}/bucket`,{headers:this.headers}),error:null}}catch(t){if(this.shouldThrowOnError)throw t;if(ze(t))return{data:null,error:t};throw t}})}getBucket(t){return Oi(this,void 0,void 0,function*(){try{return{data:yield td(this.fetch,`${this.url}/bucket/${t}`,{headers:this.headers}),error:null}}catch(n){if(this.shouldThrowOnError)throw n;if(ze(n))return{data:null,error:n};throw n}})}createBucket(t){return Oi(this,arguments,void 0,function*(n,r={public:!1}){try{return{data:yield Wn(this.fetch,`${this.url}/bucket`,{id:n,name:n,type:r.type,public:r.public,file_size_limit:r.fileSizeLimit,allowed_mime_types:r.allowedMimeTypes},{headers:this.headers}),error:null}}catch(s){if(this.shouldThrowOnError)throw s;if(ze(s))return{data:null,error:s};throw s}})}updateBucket(t,n){return Oi(this,void 0,void 0,function*(){try{return{data:yield cm(this.fetch,`${this.url}/bucket/${t}`,{id:t,name:t,public:n.public,file_size_limit:n.fileSizeLimit,allowed_mime_types:n.allowedMimeTypes},{headers:this.headers}),error:null}}catch(r){if(this.shouldThrowOnError)throw r;if(ze(r))return{data:null,error:r};throw r}})}emptyBucket(t){return Oi(this,void 0,void 0,function*(){try{return{data:yield Wn(this.fetch,`${this.url}/bucket/${t}/empty`,{},{headers:this.headers}),error:null}}catch(n){if(this.shouldThrowOnError)throw n;if(ze(n))return{data:null,error:n};throw n}})}deleteBucket(t){return Oi(this,void 0,void 0,function*(){try{return{data:yield yE(this.fetch,`${this.url}/bucket/${t}`,{},{headers:this.headers}),error:null}}catch(n){if(this.shouldThrowOnError)throw n;if(ze(n))return{data:null,error:n};throw n}})}}class lL extends aL{constructor(t,n={},r,s){super(t,n,r,s)}from(t){return new sL(this.url,this.headers,t,this.fetch)}}const cL="2.75.1";let ja="";typeof Deno<"u"?ja="deno":typeof document<"u"?ja="web":typeof navigator<"u"&&navigator.product==="ReactNative"?ja="react-native":ja="node";const uL={"X-Client-Info":`supabase-js-${ja}/${cL}`},dL={headers:uL},fL={schema:"public"},hL={autoRefreshToken:!0,persistSession:!0,detectSessionInUrl:!0,flowType:"implicit"},pL={};var mL=function(e,t,n,r){function s(i){return i instanceof n?i:new n(function(o){o(i)})}
175return 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 gL=e=>{let t;return e?t=e:typeof fetch>"u"?t=rE:t=fetch,(...n)=>t(...n)},vL=()=>typeof Headers>"u"?sE:Headers,yL=(e,t,n)=>{const r=gL(n),s=vL();return(i,o)=>mL(void 0,void 0,void 0,function*(){var a;const l=(a=yield 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,Object.assign(Object.assign({},o),{headers:c}))})};var wL=function(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())})};function xL(e){return e.endsWith("/")?e:e+"/"}function bL(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:Object.assign(Object.assign({},l),s),auth:Object.assign(Object.assign({},c),i),realtime:Object.assign(Object.assign({},u),o),storage:{},global:Object.assign(Object.assign(Object.assign({},d),a),{headers:Object.assign(Object.assign({},(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:()=>wL(this,void 0,void 0,function*(){return""})};return e.accessToken?h.accessToken=e.accessToken:delete h.accessToken,h}function _L(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(xL(t))}catch{throw Error("Invalid supabaseUrl: Provided URL is malformed.")}}const xE="2.75.1",Wi=30*1e3,um=3,oh=um*Wi,SL="http://localhost:9999",kL="supabase.auth.token",EL={"X-Client-Info":`gotrue-js/${xE}`},dm="X-Supabase-Api-Version",bE={"2024-01-01":{timestamp:Date.parse("2024-01-01T00:00:00.0Z"),name:"2024-01-01"}},CL=/^([a-z0-9_-]{4})*($|[a-z0-9_-]{3}$|[a-z0-9_-]{2}$)$/i,TL=10*60*1e3;class Sl extends Error{constructor(t,n,r){super(t),this.__isAuthError=!0,this.name="AuthError",this.status=n,this.code=r}}function J(e){return typeof e=="object"&&e!==null&&"__isAuthError"in e}class AL extends Sl{constructor(t,n,r){super(t,n,r),this.name="AuthApiError",this.status=n,this.code=r}}function PL(e){return J(e)&&e.name==="AuthApiError"}class qs extends Sl{constructor(t,n){super(t),this.name="AuthUnknownError",this.originalError=n}}class Rs extends Sl{constructor(t,n,r,s){super(t,r,s),this.name=n,this.status=r}}class Ur extends Rs{constructor(){super("Auth session missing!","AuthSessionMissingError",400,void 0)}}function jL(e){return J(e)&&e.name==="AuthSessionMissingError"}class Mi extends Rs{constructor(){super("Auth session or user missing","AuthInvalidToken
175ResponseError",500,void 0)}}class Dc extends Rs{constructor(t){super(t,"AuthInvalidCredentialsError",400,void 0)}}class Ic extends Rs{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 NL(e){return J(e)&&e.name==="AuthImplicitGrantRedirectError"}class xw extends Rs{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 fm extends Rs{constructor(t,n){super(t,"AuthRetryableFetchError",n,void 0)}}function ah(e){return J(e)&&e.name==="AuthRetryableFetchError"}class bw extends Rs{constructor(t,n,r){super(t,"AuthWeakPasswordError",n,"weak_password"),this.reasons=r}}class hm extends Rs{constructor(t){super(t,"AuthInvalidJwtError",400,"invalid_jwt")}}const nd="ABCDEFGHIJKLMNOPQRSTUVWXYZabcdefghijklmnopqrstuvwxyz0123456789-_".split(""),_w=` 	
176\r=`.split(""),RL=(()=>{const e=new Array(128);for(let t=0;t<e.length;t+=1)e[t]=-1;for(let t=0;t<_w.length;t+=1)e[_w[t].charCodeAt(0)]=-2;for(let t=0;t<nd.length;t+=1)e[nd[t].charCodeAt(0)]=t;return e})();function Sw(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(nd[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(nd[r]),t.queuedBits-=6}}function _E(e,t,n){const r=RL[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 kw(e){const t=[],n=o=>{t.push(String.fromCodePoint(o))},r={utf8seq:0,codepoint:0},s={queue:0,queuedBits:0},i=o=>{DL(o,r,n)};for(let o=0;o<e.length;o+=1)_E(e.charCodeAt(o),s,i);return t.join("")}function OL(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 ML(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}OL(r,t)}}function DL(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 xo(e){const t=[],n={queue:0,queuedBits:0},r=s=>{t.push(s)};for(let s=0;s<e.length;s+=1)_E(e.charCodeAt(s),n,r);return new Uint8Array(t)}function IL(e){const t=[];return ML(e,n=>t.push(n)),new Uint8Array(t)}function Zs(e){const t=[],n={queue:0,queuedBits:0},r=s=>{t.push(s)};return e.forEach(s=>Sw(s,n,r)),Sw(null,n,r),t.join("")}function LL(e){return Math.round(Date.now()/1e3)+e}function FL(){return"xxxxxxxx-xxxx-4xxx-yxxx-xxxxxxxxxxxx".replace(/[xy]/g,function(e){const t=Math.random()*16|0;return(e=="x"?t:t&3|8).toString(16)})}const Lt=()=>typeof window<"u"&&typeof document<"u",Fs={tested:!1,writable:!1},SE=()=>{if(!Lt())return!1;try{if(typeof globalThis.localStorage!="object")return!1}catch{return!1}if(Fs.tested)return Fs.writable;const e=`lswt-${Math.random()}${Math.random()}`;try{globalThis.localStorage.setItem(e,e),globalThis.localStorage.removeItem(e),Fs.tested=!0,Fs.writable=!0}catch{Fs.tested=!0,Fs.writable=!1}return Fs.writable};function $L(e){const t={},n=new URL(e);if(n.hash&&n.hash[0]==="#")try{new URLSearchParams(n.hash.substring(1)).forEach((s,i)=>{t[i]=s})}catch{}return n.searchParams.forEach((r,s)=>{t[s]=r}),t}const kE=e=>{let t;return e?t=e:typeof fetch>"u"?t=(...n)=>
176Gl(async()=>{const{default:r}=await Promise.resolve().then(()=>na);return{default:r}},void 0).then(({default:r})=>r(...n)):t=fetch,(...n)=>t(...n)},BL=e=>typeof e=="object"&&e!==null&&"status"in e&&"ok"in e&&"json"in e&&typeof e.json=="function",Hi=async(e,t,n)=>{await e.setItem(t,JSON.stringify(n))},$s=async(e,t)=>{const n=await e.getItem(t);if(!n)return null;try{return JSON.parse(n)}catch{return n}},$r=async(e,t)=>{await e.removeItem(t)};class tf{constructor(){this.promise=new tf.promiseConstructor((t,n)=>{this.resolve=t,this.reject=n})}}tf.promiseConstructor=Promise;function lh(e){const t=e.split(".");if(t.length!==3)throw new hm("Invalid JWT structure");for(let r=0;r<t.length;r++)if(!CL.test(t[r]))throw new hm("JWT not in base64url format");return{header:JSON.parse(kw(t[0])),payload:JSON.parse(kw(t[1])),signature:xo(t[2]),raw:{header:t[0],payload:t[1]}}}async function VL(e){return await new Promise(t=>{setTimeout(()=>t(null),e)})}function UL(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 zL(e){return("0"+e.toString(16)).substr(-2)}function WL(){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,zL).join("")}async function HL(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 KL(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 HL(e);return btoa(n).replace(/\+/g,"-").replace(/\//g,"_").replace(/=+$/,"")}async function Di(e,t,n=!1){const r=WL();let s=r;n&&(s+="/PASSWORD_RECOVERY"),await Hi(e,`${t}-code-verifier`,s);const i=await KL(r);return[i,r===i?"plain":"s256"]}const qL=/^2[0-9]{3}-(0[1-9]|1[0-2])-(0[1-9]|1[0-9]|2[0-9]|3[0-1])$/i;function YL(e){const t=e.headers.get(dm);if(!t||!t.match(qL))return null;try{return new Date(`${t}T00:00:00.0Z`)}catch{return null}}function GL(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 QL(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 ZL=/^[0-9a-f]{8}-[0-9a-f]{4}-[0-9a-f]{4}-[0-9a-f]{4}-[0-9a-f]{12}$/;function Ii(e){if(!ZL.test(e))throw new Error("@supabase/auth-js: Expected parameter to be UUID but is not")}function ch(){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 Ew(e){return JSON.parse(JSON.stringify(e))}var JL=function(e,t){var n={};for(var r in e)Object.prototype.hasOwnProperty.call(e,r)&&t.indexOf(r)<0&&(n[r]=e[r]);if(e!=null&&typeof Object.getOwnPropertySymbols=="function")for(var 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};const zs=e=>e.msg||e.message||e.error_description||e.error||JSON.stringify(e),XL=[502,503,504];async function Cw(e){var t;if(!BL(e))throw new fm(zs(e),0);if(XL.includes(e.status))throw new fm(zs(e),e.status);let n;try{n=await e.json()}catch(i){throw new qs(zs(i),i)}let r;const s=YL(e);if(s&&s.getTime()>=bE["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 bw(zs(n),e.status,((t=n.weak_password)===null||t===void 0?void 0:t.reasons)||[]);if(r==="session_not_found")throw new Ur}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)=>
176i&&typeof o=="string",!0))throw new bw(zs(n),e.status,n.weak_password.reasons);throw new AL(zs(n),e.status||500,r)}const e4=(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 ne(e,t,n,r){var s;const i=Object.assign({},r==null?void 0:r.headers);i[dm]||(i[dm]=bE["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 t4(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 t4(e,t,n,r,s,i){const o=e4(t,r,s,i);let a;try{a=await e(n,Object.assign({},o))}catch(l){throw console.error(l),new fm(zs(l),0)}if(a.ok||await Cw(a),r!=null&&r.noResolveJson)return a;try{return await a.json()}catch(l){await Cw(l)}}function yn(e){var t;let n=null;s4(e)&&(n=Object.assign({},e),e.expires_at||(n.expires_at=LL(e.expires_in)));const r=(t=e.user)!==null&&t!==void 0?t:e;return{data:{session:n,user:r},error:null}}function Tw(e){const t=yn(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 Jr(e){var t;return{data:{user:(t=e.user)!==null&&t!==void 0?t:e},error:null}}function n4(e){return{data:e,error:null}}function r4(e){const{action_link:t,email_otp:n,hashed_token:r,redirect_to:s,verification_type:i}=e,o=JL(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 Aw(e){return e}function s4(e){return e.access_token&&e.refresh_token&&e.expires_in}const uh=["global","local","others"];var i4=function(e,t){var n={};for(var r in e)Object.prototype.hasOwnProperty.call(e,r)&&t.indexOf(r)<0&&(n[r]=e[r]);if(e!=null&&typeof Object.getOwnPropertySymbols=="function")for(var 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};class o4{constructor({url:t="",headers:n={},fetch:r}){this.url=t,this.headers=n,this.fetch=kE(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),deleteClient:this._deleteOAuthClient.bind(this),regenerateClientSecret:this._regenerateOAuthClientSecret.bind(this)}}async signOut(t,n=uh[0]){if(uh.indexOf(n)<0)throw new Error(`@supabase/auth-js: Parameter scope must be one of ${uh.join(", ")}`);try{return await ne(this.fetch,"POST",`${this.url}/logout?scope=${n}`,{headers:this.headers,jwt:t,noResolveJson:!0}),{data:null,error:null}}catch(r){if(J(r))return{data:null,error:r};throw r}}async inviteUserByEmail(t,n={}){try{return await ne(this.fetch,"POST",`${this.url}/invite`,{body:{email:t,data:n.data},headers:this.headers,redirectTo:n.redirectTo,xform:Jr})}catch(r){if(J(r))return{data:{user:null},error:r};throw r}}async generateLink(t){try{const{options:n}=t,r=i4(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 ne(this.fetch,"POST",`${this.url}/admin/generate_link`,{body:s,headers:this.headers,xform:r4,redirectTo:n==null?void 0:n.redirectTo})}catch(n){if(J(n))return{data:{properties:null,user:null},error:n};throw n}}async createUser(t){try{return await ne(this.fetch,"POST",`${this.url}/admin/users`,{body:t,headers:this.headers,xform:Jr})}catch(n){if(J(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 ne(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:Aw});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,p=(l=(a=u.headers.get("link"))===null||a===void 0?void 0:a.split(","))!==null&&l!==void 0?l:[];return p.length>
1760&&(p.forEach(b=>{const g=parseInt(b.split(";")[0].split("=")[1].substring(0,1)),x=JSON.parse(b.split(";")[1].split("=")[1]);c[`${x}Page`]=g}),c.total=parseInt(h)),{data:Object.assign(Object.assign({},d),c),error:null}}catch(c){if(J(c))return{data:{users:[]},error:c};throw c}}async getUserById(t){Ii(t);try{return await ne(this.fetch,"GET",`${this.url}/admin/users/${t}`,{headers:this.headers,xform:Jr})}catch(n){if(J(n))return{data:{user:null},error:n};throw n}}async updateUserById(t,n){Ii(t);try{return await ne(this.fetch,"PUT",`${this.url}/admin/users/${t}`,{body:n,headers:this.headers,xform:Jr})}catch(r){if(J(r))return{data:{user:null},error:r};throw r}}async deleteUser(t,n=!1){Ii(t);try{return await ne(this.fetch,"DELETE",`${this.url}/admin/users/${t}`,{headers:this.headers,body:{should_soft_delete:n},xform:Jr})}catch(r){if(J(r))return{data:{user:null},error:r};throw r}}async _listFactors(t){Ii(t.userId);try{const{data:n,error:r}=await ne(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(J(n))return{data:null,error:n};throw n}}async _deleteFactor(t){Ii(t.userId),Ii(t.id);try{return{data:await ne(this.fetch,"DELETE",`${this.url}/admin/users/${t.userId}/factors/${t.id}`,{headers:this.headers}),error:null}}catch(n){if(J(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 ne(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:Aw});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,p=(l=(a=u.headers.get("link"))===null||a===void 0?void 0:a.split(","))!==null&&l!==void 0?l:[];return p.length>0&&(p.forEach(b=>{const g=parseInt(b.split(";")[0].split("=")[1].substring(0,1)),x=JSON.parse(b.split(";")[1].split("=")[1]);c[`${x}Page`]=g}),c.total=parseInt(h)),{data:Object.assign(Object.assign({},d),c),error:null}}catch(c){if(J(c))return{data:{clients:[]},error:c};throw c}}async _createOAuthClient(t){try{return await ne(this.fetch,"POST",`${this.url}/admin/oauth/clients`,{body:t,headers:this.headers,xform:n=>({data:n,error:null})})}catch(n){if(J(n))return{data:null,error:n};throw n}}async _getOAuthClient(t){try{return await ne(this.fetch,"GET",`${this.url}/admin/oauth/clients/${t}`,{headers:this.headers,xform:n=>({data:n,error:null})})}catch(n){if(J(n))return{data:null,error:n};throw n}}async _deleteOAuthClient(t){try{return await ne(this.fetch,"DELETE",`${this.url}/admin/oauth/clients/${t}`,{headers:this.headers,xform:n=>({data:n,error:null})})}catch(n){if(J(n))return{data:null,error:n};throw n}}async _regenerateOAuthClientSecret(t){try{return await ne(this.fetch,"POST",`${this.url}/admin/oauth/clients/${t}/regenerate_secret`,{headers:this.headers,xform:n=>({data:n,error:null})})}catch(n){if(J(n))return{data:null,error:n};throw n}}}function Pw(e={}){return{getItem:t=>e[t]||null,setItem:(t,n)=>{e[t]=n},removeItem:t=>{delete e[t]}}}const Li={debug:!!(globalThis&&SE()&&globalThis.localStorage&&globalThis.localStorage.getItem("supabase.gotrue-js.locks.debug")==="true")};
176class EE extends Error{constructor(t){super(t),this.isAcquireTimeout=!0}}class a4 extends EE{}async function l4(e,t,n){Li.debug&&console.log("@supabase/gotrue-js: navigatorLock: acquire lock",e,t);const r=new globalThis.AbortController;return t>0&&setTimeout(()=>{r.abort(),Li.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){Li.debug&&console.log("@supabase/gotrue-js: navigatorLock: acquired",e,s.name);try{return await n()}finally{Li.debug&&console.log("@supabase/gotrue-js: navigatorLock: released",e,s.name)}}else{if(t===0)throw Li.debug&&console.log("@supabase/gotrue-js: navigatorLock: not immediately available",e),new a4(`Acquiring an exclusive Navigator LockManager lock "${e}" immediately failed`);if(Li.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 c4(){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 CE(e){if(!/^0x[a-fA-F0-9]{40}$/.test(e))throw new Error(`@supabase/auth-js: Address "${e}" is invalid.`);return e.toLowerCase()}function u4(e){return parseInt(e,16)}function d4(e){const t=new TextEncoder().encode(e);return"0x"+Array.from(t,r=>r.toString(16).padStart(2,"0")).join("")}function f4(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(`
177`))throw new Error(`@supabase/auth-js: Invalid SIWE message field "statement". Statement must not include '\\n'. Provided value: ${e.statement}`)}const p=CE(e.address),b=u?`${u}://${r}
177`:r,g=e.statement?`${e.statement}
178`:"",x=`${b} wants you to sign in with your Ethereum account:
179${p}
180
181${g}`;let y=`URI: ${d}
182Version: ${h}
183Chain ID: ${n}${o?`
184Nonce: ${o}`:""}
185Issued At: ${i.toISOString()}`;if(s&&(y+=`
186Expiration Time: ${s.toISOString()}`),a&&(y+=`
187Not Before: ${a.toISOString()}`),l&&(y+=`
188Request ID: ${l}`),c){let m=`
189Resources:`;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}`);m+=`
190- ${v}`}y+=m}return`${x}
191${y}`}class Ue 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 rd extends Ue{constructor(t,n){super({code:"ERROR_PASSTHROUGH_SEE_CAUSE_PROPERTY",cause:n,message:t}),this.name="WebAuthnUnknownError",this.originalError=n}}function h4({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 Ue({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 Ue({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 Ue({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 Ue({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 Ue({message:"The authenticator was previously registered",code:"ERROR_AUTHENTICATOR_PREVIOUSLY_REGISTERED",cause:e});if(e.name==="NotAllowedError")return new Ue({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 Ue({message:'No entry in pubKeyCredParams was of type "public-key"',code:"ERROR_MALFORMED_PUBKEYCREDPARAMS",cause:e}):new Ue({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(AE(o)){if(i.rp.id!==o)return new Ue({message:`The RP ID "${i.rp.id}" is invalid for this domain`,code:"ERROR_INVALID_RP_ID",cause:e})}else return new Ue({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 Ue({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 Ue({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 Ue({message:"a Non-Webauthn related error has occurred",code:"ERROR_PASSTHROUGH_SEE_CAUSE_PROPERTY",cause:e})}function p4({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 Ue({message:"Authentication ceremony was sent an abort signal",code:"ERROR_CEREMONY_ABORTED",cause:e})}else{if(e.name==="NotAllowedError")return new Ue({message:e.message,code:"ERROR_PASSTHROUGH_SEE_CAUSE_PROPERTY",cause:e});if(e.name==="SecurityError"){const r=window.location.hostname;if(AE(r)){if(n.rpId!==r)return new Ue({message:`The RP ID "${n.rpId}
191" is invalid for this domain`,code:"ERROR_INVALID_RP_ID",cause:e})}else return new Ue({message:`${window.location.hostname} is an invalid domain`,code:"ERROR_INVALID_DOMAIN",cause:e})}else if(e.name==="UnknownError")return new Ue({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 Ue({message:"a Non-Webauthn related error has occurred",code:"ERROR_PASSTHROUGH_SEE_CAUSE_PROPERTY",cause:e})}var TE=function(e,t){var n={};for(var r in e)Object.prototype.hasOwnProperty.call(e,r)&&t.indexOf(r)<0&&(n[r]=e[r]);if(e!=null&&typeof Object.getOwnPropertySymbols=="function")for(var 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};class m4{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 g4=new m4;function v4(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=TE(e,["challenge","user","excludeCredentials"]),i=xo(t).buffer,o=Object.assign(Object.assign({},n),{id:xo(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:xo(c.id).buffer,type:c.type||"public-key",transports:c.transports})}}return a}function y4(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=TE(e,["challenge","allowCredentials"]),s=xo(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:xo(a.id).buffer,type:a.type||"public-key",transports:a.transports})}}return i}function w4(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:Zs(new Uint8Array(e.response.attestationObject)),clientDataJSON:Zs(new Uint8Array(e.response.clientDataJSON))},type:"public-key",clientExtensionResults:e.getClientExtensionResults(),authenticatorAttachment:(t=n.authenticatorAttachment)!==null&&t!==void 0?t:void 0}}function x4(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:Zs(new Uint8Array(s.authenticatorData)),clientDataJSON:Zs(new Uint8Array(s.clientDataJSON)),signature:Zs(new Uint8Array(s.signature)),userHandle:s.userHandle?Zs(new Uint8Array(s.userHandle)):void 0},type:"public-key",clientExtensionResults:r,authenticatorAttachment:(t=n.authenticatorAttachment)!==null&&t!==void 0?t:void 0}}function AE(e){return e==="localhost"||/^([a-z0-9]+(-[a-z0-9]+)*\.)+[a-z]{2,}$/i.test(e)}function jw(){var e,t;return!!(Lt()&&"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 b4(e){try{const t=await navigator.credentials.create(e);return t?t instanceof PublicKeyCredential?{data:t,error:null}:{data:null,error:new rd("Browser returned unexpected credential type",t)}:{data:null,error:new rd("Empty credential response",t)}}
191catch(t){return{data:null,error:h4({error:t,options:e})}}}async function _4(e){try{const t=await navigator.credentials.get(e);return t?t instanceof PublicKeyCredential?{data:t,error:null}:{data:null,error:new rd("Browser returned unexpected credential type",t)}:{data:null,error:new rd("Empty credential response",t)}}catch(t){return{data:null,error:p4({error:t,options:e})}}}const S4={hints:["security-key"],authenticatorSelection:{authenticatorAttachment:"cross-platform",requireResidentKey:!1,userVerification:"preferred",residentKey:"discouraged"},attestation:"none"},k4={userVerification:"preferred",hints:["security-key"]};function sd(...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]=sd(a,o):r[i]=sd(o)}else r[i]=o}return r}function E4(e,t){return sd(S4,e,t||{})}function C4(e,t){return sd(k4,e,t||{})}class T4{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??g4.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=E4(o.webauthn.credential_options.publicKey,i==null?void 0:i.create),{data:u,error:d}=await b4({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=C4(o.webauthn.credential_options.publicKey,i==null?void 0:i.request),{data:u,error:d}=await _4(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 J(o)?{data:null,error:o}:{data:null,error:new qs("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 Sl("rpId is required for WebAuthn authentication")};try{if(!jw())return{data:null,error:new qs("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 J(o)?{data:null,error:o}:{data:null,error:new qs("Unexpected error in authenticate",o)}}}async _register({friendlyName:t,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 Sl("rpId is required for WebAuthn registration")};try{if(!jw())return{data:null,error:new qs("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 J(o)?{data:null,error:o}:{data:null,error:new qs("Unexpected error in register",o)}}}}c4();const A4={url:SL,storageKey:kL,autoRefreshToken:!0,persistSession:!0,detectSessionInUrl:!0,headers:EL,flowType:"implicit",debug:!1,hasCustomAuthorizationHeader:!1};async function Nw(e,t,n){return await n()}const Fi={};class kl{get jwks(){var t,n;return(n=(t=Fi[this.storageKey])===null||t===void 0?void 0:t.jwks)!==null&&n!==void 0?n:{keys:[]}}set jwks(t){Fi[this.storageKey]=Object.assign(Object.assign({},Fi[this.storageKey]),{jwks:t})}get jwks_cached_at(){var t,n;return(n=(t=Fi[this.storageKey])===null||t===void 0?void 0:t.cachedAt)!==null&&n!==void 0?n:Number.MIN_SAFE_INTEGER}set jwks_cached_at(t){Fi[this.storageKey]=Object.assign(Object.assign({},Fi[this.storageKey]),{cachedAt:t})}constructor(t){var n,r;this.userStorage=null,this.memoryStorage=null,this.stateChangeEmitters=new Map,this.autoRefreshTicker=null,this.visibilityChangedCallback=null,this.refreshingDeferred=null,this.initializePromise=null,this.detectSessionInUrl=!0,this.hasCustomAuthorizationHeader=!1,this.suppressGetSessionWarning=!1,this.lockAcquired=!1,this.pendingInLock=[],this.broadcastChannel=null,this.logger=console.log,this.instanceID=kl.nextInstanceID,kl.nextInstanceID+=1,this.instanceID>0&&Lt()&&console.warn("Multiple GoTrueClient instances detected in the same browser context. It is not an error, but this should be avoided as it may produce undefined behavior when used concurrently under the same storage key.");const s=Object.assign(Object.assign({},A4),t);if(this.logDebugMessages=!!s.debug,typeof s.debug=="function"&&(this.logger=s.debug),this.persistSession=s.persistSession,this.storageKey=s.storageKey,this.autoRefreshToken=s.autoRefreshToken,this.admin=new o4({url:s.url,headers:s.headers,fetch:s.fetch}),this.url=s.url,this.headers=s.headers,this.fetch=kE(s.fetch),this.lock=s.lock||Nw,this.detectSessionInUrl=s.detectSessionInUrl,this.flowType=s.flowType,this.hasCustomAuthorizationHeader=s.hasCustomAuthorizationHeader,s.lock?this.lock=s.lock:Lt()&&(!((n=globalThis==null?void 0:globalThis.navigator)===null||n===void 0)&&n.locks)?this.lock=l4:this.lock=Nw,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 T4(this)},this.persistSession?(s.storage?this.storage=s.storage:SE()?this.storage=globalThis.localStorage:(this.memoryStorage={},this.storage=Pw(this.memoryStorage)),s.userStorage&&(this.userStorage=s.userStorage)):(this.memoryStorage={},this.storage=Pw(this.memoryStorage)),Lt()&&globalThis.BroadcastChannel&&this.persistSession&&this.storageKey){try{this.broadcastChannel=new globalThis.BroadcastChannel(this.storageKey)}catch(i){console.error("Failed to create a new BroadcastChannel, multi-tab state changes will not be available",i)}(r=this.broadcastChannel)===null||r===void 0||r.addEventListener("message",async i=>{this._debug("received broadcast notification from other tab or client",i),await this._notifyAllSubscribers(i.data.event,i.data.session,!1)})}this.initialize()}_debug(...t){return this.logDebugMessages&&this.logger(`GoTrueClient@${this.instanceID} (${xE}) ${new Date().toISOString()}`,...t),this}async initialize(){return this.initializePromise?await this.initializePromise:(this.initializePromise=(async()=>await this._acquireLock(-1,async()=>await this._initialize()))(),await this.initializePromise)}async _initialize(){var t;try{const n=$L(window.location.href);let r="none";if(this._isImplicitGrantCallback(n)?r="implicit":await this._isPKCECallback(n)&&(r="pkce"),Lt()&&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),NL(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 await this._removeSession(),{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 J(n)?{error:n}:{error:new qs("Unexpected error during initialization",n)}}finally{await this._handleVisibilityChange(),this._debug("#_initialize()","end")}}async signInAnonymously(t){var n,r,s;try{const i=await ne(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:yn}),{data:o,error:a}=i;if(a||!o)return{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)),{data:{user:c,session:l},error:null}}catch(i){if(J(i))return{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 p=null,b=null;this.flowType==="pkce"&&([p,b]=await Di(this.storage,this.storageKey)),i=await ne(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:p,code_challenge_method:b},xform:yn})}else if("phone"in t){const{phone:u,password:d,options:h}=t;i=await ne(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:yn})}else throw new Dc("You must provide either an email or phone number and a password");const{data:o,error:a}=i;if(a||!o)return{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)),{data:{user:c,session:l},error:null}}catch(i){if(J(i))return{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 ne(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:Tw})}else if("phone"in t){const{phone:i,password:o,options:a}=t;n=await ne(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:Tw})}else throw new Dc("You must provide either an email or phone number and a password");const{data:r,error:s}=n;return s?{data:{user:null,session:null},error:s}:!r||!r.session||!r.user?{data:{user:null,session:null},error:new Mi}:(r.session&&(await this._saveSession(r.session),await this._notifyAllSubscribers("SIGNED_IN",r.session)),{data:Object.assign({user:r.user,session:r.session},r.weak_password?{weakPassword:r.weak_password}:null),error:s})}catch(n){if(J(n))return{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(-1,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 p,b;if("message"in t)p=t.message,b=t.signature;else{const{chain:g,wallet:x,statement:y,options:m}=t;let v;if(Lt())if(typeof x=="object")v=x;else{const P=window;if("ethereum"in P&&typeof P.ethereum=="object"&&"request"in P.ethereum&&typeof P.ethereum.request=="function")v=P.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"||!(m!=null&&m.url))throw new Error("@supabase/auth-js: Both wallet and url must be specified in non-browser environments.");v=x}const _=new URL((n=m==null?void 0:m.url)!==null&&n!==void 0?n:window.location.href),S=await v.request({method:"eth_requestAccounts"}).then(P=>P).catch(()=>{throw new Error("@supabase/auth-js: Wallet method eth_requestAccounts is missing or invalid")});if(!S||S.length===0)throw new Error("@supabase/auth-js: No accounts available. Please ensure the wallet is connected.");const k=CE(S[0]);let E=(r=m==null?void 0:m.signInWithEthereum)===null||r===void 0?void 0:r.chainId;if(!E){const P=await v.request({method:"eth_chainId"});E=u4(P)}const T={domain:_.host,address:k,statement:y,uri:_.href,version:"1",chainId:E,nonce:(s=m==null?void 0:m.signInWithEthereum)===null||s===void 0?void 0:s.nonce,issuedAt:(o=(i=m==null?void 0:m.signInWithEthereum)===null||i===void 0?void 0:i.issuedAt)!==null&&o!==void 0?o:new Date,expirationTime:(a=m==null?void 0:m.signInWithEthereum)===null||a===void 0?void 0:a.expirationTime,notBefore:(l=m==null?void 0:m.signInWithEthereum)===null||l===void 0?void 0:l.notBefore,requestId:(c=m==null?void 0:m.signInWithEthereum)===null||c===void 0?void 0:c.requestId,resources:(u=m==null?void 0:m.signInWithEthereum)===null||u===void 0?void 0:u.resources};p=f4(T),b=await v.request({method:"personal_sign",params:[d4(p),k]})}try{const{data:g,error:x}=await ne(this.fetch,"POST",`${this.url}/token?grant_type=web3`,{headers:this.headers,body:Object.assign({chain:"ethereum",message:p,signature:b},!((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:yn});if(x)throw x;return!g||!g.session||!g.user?{data:{user:null,session:null},error:new Mi}:(g.session&&(await this._saveSession(g.session),await this._notifyAllSubscribers("SIGNED_IN",g.session)),{data:Object.assign({},g),error:x})}catch(g){if(J(g))return{data:{user:null,session:null},error:g};throw g}}async signInWithSolana(t){var n,r,s,i,o,a,l,c,u,d,h,p;let b,g;if("message"in t)b=t.message,g=t.signature;else{const{chain:x,wallet:y,statement:m,options:v}=t;let _;if(Lt())if(typeof y=="object")_=y;
191else{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"))_=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 y!="object"||!(v!=null&&v.url))throw new Error("@supabase/auth-js: Both wallet and url must be specified in non-browser environments.");_=y}const S=new URL((n=v==null?void 0:v.url)!==null&&n!==void 0?n:window.location.href);if("signIn"in _&&_.signIn){const k=await _.signIn(Object.assign(Object.assign(Object.assign({issuedAt:new Date().toISOString()},v==null?void 0:v.signInWithSolana),{version:"1",domain:S.host,uri:S.href}),m?{statement:m}: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)b=typeof E.signedMessage=="string"?E.signedMessage:new TextDecoder().decode(E.signedMessage),g=E.signature;else throw new Error("@supabase/auth-js: Wallet method signIn() API returned object without signedMessage and signature fields")}else{if(!("signMessage"in _)||typeof _.signMessage!="function"||!("publicKey"in _)||typeof _!="object"||!_.publicKey||!("toBase58"in _.publicKey)||typeof _.publicKey.toBase58!="function")throw new Error("@supabase/auth-js: Wallet does not have a compatible signMessage() and publicKey.toBase58() API");b=[`${S.host} wants you to sign in with your Solana account:`,_.publicKey.toBase58(),...m?["",m,""]:[""],"Version: 1",`URI: ${S.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(`
192`);const k=await _.signMessage(new TextEncoder().encode(b),"utf8");if(!k||!(k instanceof Uint8Array))throw new Error("@supabase/auth-js: Wallet signMessage() API returned an recognized value");g=k}}try{const{data:x,error:y}=await ne(this.fetch,"POST",`${this.url}/token?grant_type=web3`,{headers:this.headers,body:Object.assign({chain:"solana",message:b,signature:Zs(g)},!((h=t.options)===null||h===void 0)&&h.captchaToken?{gotrue_meta_security:{captcha_token:(p=t.options)===null||p===void 0?void 0:p.captchaToken}}:null),xform:yn});if(y)throw y;return!x||!x.session||!x.user?{data:{user:null,session:null},error:new Mi}:(x.session&&(await this._saveSession(x.session),await this._notifyAllSubscribers("SIGNED_IN",x.session)),{data:Object.assign({},x),error:y})}catch(x){if(J(x))return{data:{user:null,session:null},error:x};throw x}}async _exchangeCodeForSession(t){const n=await $s(this.storage,`${this.storageKey}-code-verifier`),[r,s]=(n??"").split("/");try{const{data:i,error:o}=await ne(this.fetch,"POST",`${this.url}/token?grant_type=pkce`,{headers:this.headers,body:{auth_code:t,code_verifier:r},xform:yn});if(await $r(this.storage,`${this.storageKey}-code-verifier`),o)throw o;return!i||!i.session||!i.user?{data:{user:null,session:null,redirectType:null},error:new Mi}:(i.session&&(await this._saveSession(i.session),await this._notifyAllSubscribers("SIGNED_IN",i.session)),{data:Object.assign(Object.assign({},i),{redirectType:s??null}),error:o})}catch(i){if(J(i))return{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 ne(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:yn}),{data:l,error:c}=a;return c?{data:{user:null,session:null},error:c}:!l||!l.session||!l.user?{data:{user:null,session:null},error:new Mi}:(l.session&&(await this._saveSession(l.session),await this._notifyAllSubscribers("SIGNED_IN",l.session)),{data:l,error:c})}catch(n){if(J(n))return{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;
192let c=null,u=null;this.flowType==="pkce"&&([c,u]=await Di(this.storage,this.storageKey));const{error:d}=await ne(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{data:{user:null,session:null},error:d}}if("phone"in t){const{phone:a,options:l}=t,{data:c,error:u}=await ne(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{data:{user:null,session:null,messageId:c==null?void 0:c.message_id},error:u}}throw new Dc("You must provide either an email or phone number.")}catch(a){if(J(a))return{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 ne(this.fetch,"POST",`${this.url}/verify`,{headers:this.headers,body:Object.assign(Object.assign({},t),{gotrue_meta_security:{captcha_token:i}}),redirectTo:s,xform:yn});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)),{data:{user:c,session:l},error:null}}catch(s){if(J(s))return{data:{user:null,session:null},error:s};throw s}}async signInWithSSO(t){var n,r,s;try{let i=null,o=null;return this.flowType==="pkce"&&([i,o]=await Di(this.storage,this.storageKey)),await ne(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:i,code_challenge_method:o}),headers:this.headers,xform:n4})}catch(i){if(J(i))return{data:null,error:i};throw i}}async reauthenticate(){return await this.initializePromise,await this._acquireLock(-1,async()=>await this._reauthenticate())}async _reauthenticate(){try{return await this._useSession(async t=>{const{data:{session:n},error:r}=t;if(r)throw r;if(!n)throw new Ur;const{error:s}=await ne(this.fetch,"GET",`${this.url}/reauthenticate`,{headers:this.headers,jwt:n.access_token});return{data:{user:null,session:null},error:s}})}catch(t){if(J(t))return{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 ne(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{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 ne(this.fetch,"POST",n,{headers:this.headers,body:{phone:r,type:s,gotrue_meta_security:{captcha_token:i==null?void 0:i.captchaToken}}});return{data:{user:null,session:null,messageId:o==null?void 0:o.message_id},error:a}}throw new Dc("You must provide either an email or phone number and a type")}catch(n){if(J(n))return{data:{user:null,session:null},error:n};throw n}}async getSession(){return await this.initializePromise,await this._acquireLock(-1,async()=>this._useSession(async n=>n))}async _acquireLock(t,n){this._debug("#_acquireLock","begin",t);try{if(this.lockAcquired){const r=this.pendingInLock.length?this.pendingInLock[this.pendingInLock.length-1]:Promise.resolve(),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 $s(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
192id"),await this._removeSession())),!t)return{data:{session:null},error:null};const r=t.expires_at?t.expires_at*1e3-Date.now()<oh:!1;if(this._debug("#__loadSession()",`session has${r?"":" not"} expired`,"expires_at",t.expires_at),!r){if(this.userStorage){const o=await $s(this.userStorage,this.storageKey+"-user");o!=null&&o.user?t.user=o.user:t.user=ch()}if(this.storage.isServer&&t.user){let o=this.suppressGetSessionWarning;t=new Proxy(t,{get:(l,c,u)=>(!o&&c==="user"&&(console.warn("Using the user object as returned from supabase.auth.getSession() or from some supabase.auth.onAuthStateChange() events could be insecure! This value comes directly from the storage medium (usually cookies on the server) and may not be authentic. Use supabase.auth.getUser() instead which authenticates the data by contacting the Supabase Auth server."),o=!0,this.suppressGetSessionWarning=!0),Reflect.get(l,c,u))})}return{data:{session:t},error:null}}const{data:s,error:i}=await this._callRefreshToken(t.refresh_token);return i?{data:{session:null},error:i}:{data:{session:s},error:null}}finally{this._debug("#__loadSession()","end")}}async getUser(t){return t?await this._getUser(t):(await this.initializePromise,await this._acquireLock(-1,async()=>await this._getUser()))}async _getUser(t){try{return t?await ne(this.fetch,"GET",`${this.url}/user`,{headers:this.headers,jwt:t,xform:Jr}):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 Ur}:await ne(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:Jr})})}catch(n){if(J(n))return jL(n)&&(await this._removeSession(),await $r(this.storage,`${this.storageKey}-code-verifier`)),{data:{user:null},error:n};throw n}}async updateUser(t,n={}){return await this.initializePromise,await this._acquireLock(-1,async()=>await this._updateUser(t,n))}async _updateUser(t,n={}){try{return await this._useSession(async r=>{const{data:s,error:i}=r;if(i)throw i;if(!s.session)throw new Ur;const o=s.session;let a=null,l=null;this.flowType==="pkce"&&t.email!=null&&([a,l]=await Di(this.storage,this.storageKey));const{data:c,error:u}=await ne(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:Jr});if(u)throw u;return o.user=c.user,await this._saveSession(o),await this._notifyAllSubscribers("USER_UPDATED",o),{data:{user:o.user},error:null}})}catch(r){if(J(r))return{data:{user:null},error:r};throw r}}async setSession(t){return await this.initializePromise,await this._acquireLock(-1,async()=>await this._setSession(t))}async _setSession(t){try{if(!t.access_token||!t.refresh_token)throw new Ur;const n=Date.now()/1e3;let r=n,s=!0,i=null;const{payload:o}=lh(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{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)throw 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{data:{user:i.user,session:i},error:null}}catch(n){if(J(n))return{data:{session:null,user:null},error:n};throw n}}async refreshSession(t){return await this.initializePromise,await this._acquireLock(-1,async()=>await this._refreshSession(t))}async _refreshSession(t){try{return await this._useSession(async n=>{var r;if(!t){const{data:o,error: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 Ur;const{data:s,error:i}=await this._callRefreshToken(t.refresh_token);return i?{data:{user:null,session:null},error:i}:s?{data:{user:s.user,session:s},error:null}:{data:{user:null,session:null},error:null}})}catch(n){if(J(n))return{data:{user:null,session:null},error:n};throw n}}async _getSessionFromURL(t,n){try{if(!Lt())throw new Ic("No browser detected.");
192if(t.error||t.error_description||t.error_code)throw new Ic(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 xw("Not a valid PKCE flow url.");break;case"pkce":if(this.flowType==="implicit")throw new Ic("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 xw("No code detected.");const{data:m,error:v}=await this._exchangeCodeForSession(t.code);if(v)throw v;const _=new URL(window.location.href);return _.searchParams.delete("code"),window.history.replaceState(window.history.state,"",_.toString()),{data:{session:m.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 Ic("No session defined in URL");const u=Math.round(Date.now()/1e3),d=parseInt(a);let h=u+d;l&&(h=parseInt(l));const p=h-u;p*1e3<=Wi&&console.warn(`@supabase/gotrue-js: Session as retrieved from URL expires in ${p}s, should have been closer to ${d}s`);const b=h-d;u-b>=120?console.warn("@supabase/gotrue-js: Session as retrieved from URL was issued over 120s ago, URL could be stale",b,h,u):u-b<0&&console.warn("@supabase/gotrue-js: Session as retrieved from URL was issued in the future? Check the device clock for skew",b,h,u);const{data:g,error:x}=await this._getUser(i);if(x)throw x;const y={provider_token:r,provider_refresh_token:s,access_token:i,expires_in:d,expires_at:h,refresh_token:o,token_type:c,user:g.user};return window.location.hash="",this._debug("#_getSessionFromURL()","clearing window.location.hash"),{data:{session:y,redirectType:t.type},error:null}}catch(r){if(J(r))return{data:{session:null,redirectType:null},error:r};throw r}}_isImplicitGrantCallback(t){return!!(t.access_token||t.error_description)}async _isPKCECallback(t){const n=await $s(this.storage,`${this.storageKey}-code-verifier`);return!!(t.code&&n)}async signOut(t={scope:"global"}){return await this.initializePromise,await this._acquireLock(-1,async()=>await this._signOut(t))}async _signOut({scope:t}={scope:"global"}){return await this._useSession(async n=>{var r;const{data:s,error:i}=n;if(i)return{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&&!(PL(a)&&(a.status===404||a.status===401||a.status===403)))return{error:a}}return t!=="others"&&(await this._removeSession(),await $r(this.storage,`${this.storageKey}-code-verifier`)),{error:null}})}onAuthStateChange(t){const n=FL(),r={id:n,callback:t,unsubscribe:()=>{this._debug("#unsubscribe()","state change callback with id removed",n),this.stateChangeEmitters.delete(n)}};return this._debug("#onAuthStateChange()","registered callback with id",n),this.stateChangeEmitters.set(n,r),(async()=>(await this.initializePromise,await this._acquireLock(-1,async()=>{this._emitInitialSession(n)})))(),{data:{subscription:r}}}async _emitInitialSession(t){return await this._useSession(async n=>{var r,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 Di(this.storage,this.storageKey,!0));try{return await ne(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(J(i))return{data:null,error:i};throw i}}async getUserIdentities(){var t;try{const{data:n,error:r}=await this.getUser();if(r)throw r;return{data:{identities:(t=n.user.identities)!==null&&t!==void 0?t:[]},error:null}}catch(n){if(J(n))return{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 p=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 ne(this.fetch,"GET",p,{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 Lt()&&!(!((n=t.options)===null||n===void 0)&&n.skipBrowserRedirect)&&window.location.assign(r==null?void 0:r.url),{data:{provider:t.provider,url:r==null?void 0:r.url},error:null}}catch(r){if(J(r))return{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;
192if(s)throw s;const{options:o,provider:a,token:l,access_token:c,nonce:u}=t,d=await ne(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:yn}),{data:h,error:p}=d;return p?{data:{user:null,session:null},error:p}:!h||!h.session||!h.user?{data:{user:null,session:null},error:new Mi}:(h.session&&(await this._saveSession(h.session),await this._notifyAllSubscribers("USER_UPDATED",h.session)),{data:h,error:p})}catch(s){if(J(s))return{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 ne(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(J(n))return{data:null,error:n};throw n}}async _refreshAccessToken(t){const n=`#_refreshAccessToken(${t.substring(0,5)}...)`;this._debug(n,"begin");try{const r=Date.now();return await UL(async s=>(s>
1920&&await VL(200*Math.pow(2,s-1)),this._debug(n,"refreshing attempt",s),await ne(this.fetch,"POST",`${this.url}/token?grant_type=refresh_token`,{body:{refresh_token:t},headers:this.headers,xform:yn})),(s,i)=>{const o=200*Math.pow(2,s);return i&&ah(i)&&Date.now()+o-r<Wi})}catch(r){if(this._debug(n,"error",r),J(r))return{data:{session:null,user:null},error:r};throw r}finally{this._debug(n,"end")}}_isValidSession(t){return typeof t=="object"&&t!==null&&"access_token"in t&&"refresh_token"in t&&"expires_at"in t}async _handleProviderSignIn(t,n){const r=await this._getUrlForProvider(`${this.url}/authorize`,t,{redirectTo:n.redirectTo,scopes:n.scopes,queryParams:n.queryParams});return this._debug("#_handleProviderSignIn()","provider",t,"options",n,"url",r),Lt()&&!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 $s(this.storage,this.storageKey);if(s&&this.userStorage){let o=await $s(this.userStorage,this.storageKey+"-user");!this.storage.isServer&&Object.is(this.storage,this.userStorage)&&!o&&(o={user:s.user},await Hi(this.userStorage,this.storageKey+"-user",o)),s.user=(t=o==null?void 0:o.user)!==null&&t!==void 0?t:ch()}else if(s&&!s.user&&!s.user){const o=await $s(this.storage,this.storageKey+"-user");o&&(o!=null&&o.user)?(s.user=o.user,await $r(this.storage,this.storageKey+"-user"),await Hi(this.storage,this.storageKey,s)):s.user=ch()}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()<oh;if(this._debug(r,`session has${i?"":" not"} expired with margin of ${oh}s`),i){if(this.autoRefreshToken&&s.refresh_token){const{error:o}=await this._callRefreshToken(s.refresh_token);o&&(console.error(o),ah(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 Ur;if(this.refreshingDeferred)return this.refreshingDeferred.promise;const s=`#_callRefreshToken(${t.substring(0,5)}...)`;this._debug(s,"begin");try{this.refreshingDeferred=new tf;const{data:i,error:o}=await this._refreshAccessToken(t);if(o)throw o;if(!i.session)throw new Ur;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),J(i)){const o={data:null,error:i};return ah(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;const n=Object.assign({},t),r=n.user&&n.user.__isUserNotAvailableProxy===!0;if(this.userStorage){!r&&n.user&&await Hi(this.userStorage,this.storageKey+"-user",{user:n.user});const s=Object.assign({},n);delete s.user;const i=Ew(s);await Hi(this.storage,this.storageKey,i)}else{const s=Ew(n);await Hi(this.storage,this.storageKey,s)}}async _removeSession(){this._debug("#_removeSession()"),await $r(this.storage,this.storageKey),await $r(this.storage,this.storageKey+"-code-verifier"),await $r(this.storage,this.storageKey+"-user"),this.userStorage&&await $r(this.userStorage,this.storageKey+"-user"),await this._notifyAllSubscribers("SIGNED_OUT",null)}_removeVisibilityChangedCallback(){this._debug("#_removeVisibilityChangedCallback()");const t=this.visibilityChangedCallback;this.visibilityChangedCallback=null;
192try{t&&Lt()&&(window!=null&&window.removeEventListener)&&window.removeEventListener("visibilitychange",t)}catch(n){console.error("removing visibilitychange callback failed",n)}}async _startAutoRefresh(){await this._stopAutoRefresh(),this._debug("#_startAutoRefresh()");const t=setInterval(()=>this._autoRefreshTokenTick(),Wi);this.autoRefreshTicker=t,t&&typeof t=="object"&&typeof t.unref=="function"?t.unref():typeof Deno<"u"&&typeof Deno.unrefTimer=="function"&&Deno.unrefTimer(t),setTimeout(async()=>{await this.initializePromise,await this._autoRefreshTokenTick()},0)}async _stopAutoRefresh(){this._debug("#_stopAutoRefresh()");const t=this.autoRefreshTicker;this.autoRefreshTicker=null,t&&clearInterval(t)}async startAutoRefresh(){this._removeVisibilityChangedCallback(),await this._startAutoRefresh()}async stopAutoRefresh(){this._removeVisibilityChangedCallback(),await this._stopAutoRefresh()}async _autoRefreshTokenTick(){this._debug("#_autoRefreshTokenTick()","begin");try{await this._acquireLock(0,async()=>{try{const t=Date.now();try{return await this._useSession(async n=>{const{data:{session:r}}=n;if(!r||!r.refresh_token||!r.expires_at){this._debug("#_autoRefreshTokenTick()","no session");return}const s=Math.floor((r.expires_at*1e3-t)/Wi);this._debug("#_autoRefreshTokenTick()",`access token expires in ${s} ticks, a tick lasts ${Wi}ms, refresh threshold is ${um} ticks`),s<=um&&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 EE)this._debug("auto refresh token tick lock not available");else throw t}}async _handleVisibilityChange(){if(this._debug("#_handleVisibilityChange()"),!Lt()||!(window!=null&&window.addEventListener))return this.autoRefreshToken&&this.startAutoRefresh(),!1;try{this.visibilityChangedCallback=async()=>await this._onVisibilityChanged(!1),window==null||window.addEventListener("visibilitychange",this.visibilityChangedCallback),await this._onVisibilityChanged(!0)}catch(t){console.error("_handleVisibilityChange",t)}}async _onVisibilityChanged(t){const n=`#_onVisibilityChanged(${t})`;this._debug(n,"visibilityState",document.visibilityState),document.visibilityState==="visible"?(this.autoRefreshToken&&this._startAutoRefresh(),t||(await this.initializePromise,await this._acquireLock(-1,async()=>{if(document.visibilityState!=="visible"){this._debug(n,"acquired the lock to recover the session, but the browser visibilityState is no longer visible, aborting");return}await this._recoverAndRefresh()}))):document.visibilityState==="hidden"&&this.autoRefreshToken&&this._stopAutoRefresh()}async _getUrlForProvider(t,n,r){const 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 Di(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?{data:null,error:i}:await ne(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(J(n))return{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{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 ne(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?{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}`),{data:l,error:null})})}catch(n){if(J(n))return{data:null,error:n};throw n}}async _verify(t){return this._acquireLock(-1,async()=>{try{return await this._useSession(async n=>{var r;const{data:s,error:i}=n;if(i)return{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"?w4(t.webauthn.credential_response):x4(t.webauthn.credential_response)})}:{code:t.code}),{data:a,error:l}=await ne(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?{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),{data:a,error:l})})}catch(n){if(J(n))return{data:null,error:n};throw n}})}async _challenge(t){return this._acquireLock(-1,async()=>{try{return await this._useSession(async n=>{var r;const{data:s,error:i}=n;if(i)return{data:null,error:i};const o=await ne(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:v4(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:y4(a.webauthn.credential_options.publicKey)})})}),error:null}}})}catch(n){if(J(n))return{data:null,error:n};throw n}})}async _challengeAndVerify(t){const{data:n,error:r}=await this._challenge({factorId:t.factorId});return r?{data:null,error:r}:await this._verify({factorId:t.factorId,challengeId:n.id,code:t.code})}async _listFactors(){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(){return this._acquireLock(-1,async()=>await this._useSession(async t=>{var n,r;const{data:{session:s},error:i}=t;if(i)return{data:null,error:i};if(!s)return{data:{currentLevel:null,nextLevel:null,currentAuthenticationMethods:[]},error:null};const{payload:o}=lh(s.access_token);let a=null;o.aal&&(a=o.aal);let l=a;((r=(n=s.user.factors)===null||n===void 0?void 0:n.filter(d=>d.status==="verified"))!==null&&r!==void 0?r:[]).length>0&&(l="aal2");const u=o.amr||[];return{data:{currentLevel:a,nextLevel:l,currentAuthenticationMethods:u},error:null}}))}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+TL>s)return r;const{data:i,error:o}=await ne(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:p,error:b}
192=await this.getSession();if(b||!p.session)return{data:null,error:b};r=p.session.access_token}const{header:s,payload:i,signature:o,raw:{header:a,payload:l}}=lh(r);n!=null&&n.allowExpired||GL(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:p}=await this.getUser(r);if(p)throw p;return{data:{claims:i,header:s,signature:o},error:null}}const u=QL(s.alg),d=await crypto.subtle.importKey("jwk",c,u,!0,["verify"]);if(!await crypto.subtle.verify(u,d,o,IL(`${a}.${l}`)))throw new hm("Invalid JWT signature");return{data:{claims:i,header:s,signature:o},error:null}}catch(r){if(J(r))return{data:null,error:r};throw r}}}kl.nextInstanceID=0;const P4=kl;class j4 extends P4{constructor(t){super(t)}}var N4=function(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())})};class R4{constructor(t,n,r){var s,i,o;this.supabaseUrl=t,this.supabaseKey=n;const a=_L(t);if(!n)throw new Error("supabaseKey is required.");this.realtimeUrl=new URL("realtime/v1",a),this.realtimeUrl.protocol=this.realtimeUrl.protocol.replace("http","ws"),this.authUrl=new URL("auth/v1",a),this.storageUrl=new URL("storage/v1",a),this.functionsUrl=new URL("functions/v1",a);const l=`sb-${a.hostname.split(".")[0]}-auth-token`,c={db:fL,realtime:pL,auth:Object.assign(Object.assign({},hL),{storageKey:l}),global:dL},u=bL(r??{},c);this.storageKey=(s=u.auth.storageKey)!==null&&s!==void 0?s:"",this.headers=(i=u.global.headers)!==null&&i!==void 0?i:{},u.accessToken?(this.accessToken=u.accessToken,this.auth=new Proxy({},{get:(d,h)=>{throw new Error(`@supabase/supabase-js: Supabase Client is configured with the accessToken option, accessing supabase.auth.${String(h)} is not possible`)}})):this.auth=this._initSupabaseAuthClient((o=u.auth)!==null&&o!==void 0?o:{},this.headers,u.global.fetch),this.fetch=yL(n,this._getAccessToken.bind(this),u.global.fetch),this.realtime=this._initRealtimeClient(Object.assign({headers:this.headers,accessToken:this._getAccessToken.bind(this)},u.realtime)),this.rest=new AI(new URL("rest/v1",a).href,{headers:this.headers,schema:u.db.schema,fetch:this.fetch}),this.storage=new lL(this.storageUrl.href,this.headers,this.fetch,r==null?void 0:r.storage),u.accessToken||this._listenForAuthEvents()}get functions(){return new oI(this.functionsUrl.href,{headers:this.headers,customFetch:this.fetch})}from(t){return this.rest.from(t)}schema(t){return this.rest.schema(t)}rpc(t,n={},r={head:!1,get:!1,count:void 0}){return this.rest.rpc(t,n,r)}channel(t,n={config:{}}){return this.realtime.channel(t,n)}getChannels(){return this.realtime.getChannels()}removeChannel(t){return this.realtime.removeChannel(t)}removeAllChannels(){return this.realtime.removeAllChannels()}_getAccessToken(){return N4(this,void 0,void 0,function*(){var t,n;if(this.accessToken)return yield this.accessToken();const{data:r}=yield this.auth.getSession();return(n=(t=r.session)===null||t===void 0?void 0:t.access_token)!==null&&n!==void 0?n:this.supabaseKey})}_initSupabaseAuthClient({autoRefreshToken:t,persistSession:n,detectSessionInUrl:r,storage:s,userStorage:i,storageKey:o,flowType:a,lock:l,debug:c},u,d){const h={Authorization:`Bearer ${this.supabaseKey}`,apikey:`${this.supabaseKey}`};return new j4({url:this.authUrl.href,headers:Object.assign(Object.assign({},h),u),storageKey:o,autoRefreshToken:t,persistSession:n,detectSessionInUrl:r,storage:s,userStorage:i,flowType:a,lock:l,debug:c,fetch:d,hasCustomAuthorizationHeader:Object.keys(this.headers).some(p=>p.toLowerCase()==="authorization")})}_initRealtimeClient(t){return new HI(this.realtimeUrl.href,Object.assign(Object.assign({},t),{params:Object.assign({apikey:this.supabaseKey},t==null?void 0:t.params)}))}_listenForAuthEvents(){return this.auth.onAuthStateChange((n,r)=>{this._handleTokenChanged(n,"CLIENT",r==null?void 0:r.access_token)})}_handleTokenChanged(t,n,r){(t==="TOKEN_REFRESHED"||t==="SIGNED_IN")&&this.changedAccessToken!==r?(this.changedAccessToken=r,this.realtime.setAuth(r)):t==="SIGNED_OUT"&&(this.realtime.setAuth(),n=="STORAGE"&&this.auth.signOut(),this.changedAccessToken=void 0)}}const O4=(e,t,n)=>new R4(e,t,n);function M4(){if(typeof window<"u"||typeof process>"u")return!1;const e=process.version;if(e==null)return!1;const t=e.match(/^v(\d+)\./);return t?parseInt(t[1],10)<=18:!1}M4()&&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 N
192ode.js 20 or later. For more information, visit: https://github.com/orgs/supabase/discussions/37217");const D4="https://dmwsftsazbbdcqfhufho.supabase.co",I4="eyJhbGciOiJIUzI1NiIsInR5cCI6IkpXVCJ9.eyJpc3MiOiJzdXBhYmFzZSIsInJlZiI6ImRtd3NmdHNhemJiZGNxZmh1ZmhvIiwicm9sZSI6ImFub24iLCJpYXQiOjE3NzQyNzc0NjQsImV4cCI6MjA4OTg1MzQ2NH0.HhKXvtTgakPEKK0zIlGSdKV8x4eVVetWGyd83yRVaGY",X=O4(D4,I4,{auth:{storage:localStorage,persistSession:!0,autoRefreshToken:!0}}),nf=({isOpen:e,onClose:t})=>{const[n,r]=w.useState(!1),[s,i]=w.useState(""),[o,a]=w.useState(""),[l,c]=w.useState(!1),{toast:u}=Wl(),d=async h=>{h.preventDefault(),c(!0);try{if(n){const{error:p}=await X.auth.signUp({email:s,password:o,options:{emailRedirectTo:`${window.location.origin}/`}});if(p)throw p;u({title:"Account created!",description:"You can now sign in with your credentials."}),r(!1)}else{const{error:p}=await X.auth.signInWithPassword({email:s,password:o});if(p)throw p;u({title:"Welcome back!",description:"You have successfully signed in."}),t()}}catch(p){u({title:"Error",description:p.message,variant:"destructive"})}finally{c(!1)}};return e?Si.createPortal(f.jsxs(f.Fragment,{children:[f.jsx("div",{className:"fixed inset-0 bg-black opacity-50 z-[1000]",onClick:t}),f.jsxs("div",{className:`fixed right-0 top-0 h-full w-full max-w-md bg-[#1A1A1A] z-[1001] shadow-2xl transition-transform duration-300 ${e?"animate-slide-in-right":""}`,children:[f.jsx("button",{onClick:t,className:"absolute top-8 right-8 text-white hover:text-gray-300 transition-colors",children:f.jsx(Xg,{size:24})}),f.jsxs("div",{className:"flex flex-col h-full px-10 pt-24 pb-10",children:[f.jsx("h2",{className:"text-white text-4xl font-medium mb-2",children:n?"Create Account":"Sign In"}),f.jsx("p",{className:"text-gray-400 text-sm mb-8",children:n?"Join us to create and manage your events":"Welcome back! Please sign in to continue"}),f.jsxs("form",{onSubmit:d,className:"flex flex-col gap-6",children:[f.jsxs("div",{children:[f.jsx("label",{htmlFor:"email",className:"block text-white text-sm font-medium mb-2 uppercase tracking-wide",children:"Email"}),f.jsx("input",{id:"email",type:"email",value:s,onChange:h=>i(h.target.value),required:!0,className:"w-full bg-white/10 border border-white/20 text-white px-4 py-3 focus:outline-none focus:border-[#FA76FF] transition-colors",placeholder:"[email protected]"})]}),f.jsxs("div",{children:[f.jsx("label",{htmlFor:"password",className:"block text-white text-sm font-medium mb-2 uppercase tracking-wide",children:"Password"}),f.jsx("input",{id:"password",type:"password",value:o,onChange:h=>a(h.target.value),required:!0,minLength:6,className:"w-full bg-white/10 border border-white/20 text-white px-4 py-3 focus:outline-none focus:border-[#FA76FF] transition-colors",placeholder:"••••••••"})]}),f.jsx("button",{type:"submit",disabled:l,className:"w-full bg-[#FA76FF] text-black font-medium py-3 px-6 uppercase text-sm border border-black hover:bg-[#ff8fff] transition-colors disabled:opacity-50 disabled:cursor-not-allowed",children:l?"Please wait...":n?"Create Account":"Sign In"})]}),f.jsx("div",{className:"mt-6 text-center",children:f.jsx("button",{onClick:()=>r(!n),className:"text-gray-400 hover:text-white transition-colors text-sm",children:n?"Already have an account? Sign in":"Don't have an account? Create one"})})]})]})]}),document.body):null},vi=()=>{const[e,t]=w.useState(null),[n,r]=w.useState(!1),[s,i]=w.useState(!1),o=Fn(),[a,l]=w.useState(null);return w.useEffect(()=>{X.auth.getSession().then(({data:{session:u}})=>{t((u==null?void 0:u.user)??null)});const{data:{subscription:c}}=X.auth.onAuthStateChange((u,d)=>{t((d==null?void 0:d.user)??null)});return()=>c.unsubscribe()},[]),w.useEffect(()=>{e&&a&&(o(a),l(null),r(!1))},[e,a,o]),Si.createPortal(f.jsxs(f.Fragment,{children:[f.jsxs("nav",{className:"fixed top-8 left-4 md:left-8 z-[2000] flex items-center gap-0",children:[f.jsx("div",{className:"bg-black text-white h-[34px] w-[34px] border border-black flex items-center justify-center",children:f.jsx("svg",{xmlns:"http://www.w3.org/2000/svg",fill:"none",viewBox:"0 0 14 14",className:"w-4 h-4",children:f.jsx("g",{id:"smiley-smirk",children:f.jsx("path",{id:"Subtract",fill:"
192currentColor",stroke:"currentColor",strokeWidth:"0.5",fillRule:"evenodd",d:"M1.83645 1.83645C3.06046 0.612432 4.82797 0 7 0s3.9395 0.612432 5.1636 1.83645C13.3876 3.06046 14 4.82797 14 7s-0.6124 3.9395 -1.8364 5.1636C10.9395 13.3876 9.17203 14 7 14s-3.93954 -0.6124 -5.16355 -1.8364C0.612432 10.9395 0 9.17203 0 7s0.612432 -3.93954 1.83645 -5.16355ZM5.0769 4.98816c0 -0.34518 -0.27982 -0.625 -0.625 -0.625 -0.34517 0 -0.625 0.27982 -0.625 0.625v0.7c0 0.34518 0.27983 0.625 0.625 0.625 0.34518 0 0.625 -0.27982 0.625 -0.625v-0.7Zm5.0962 0c0 -0.34518 -0.27983 -0.625 -0.625 -0.625 -0.34518 0 -0.625 0.27982 -0.625 0.625v0.7c0 0.34518 0.27982 0.625 0.625 0.625 0.34517 0 0.625 -0.27982 0.625 -0.625v-0.7Zm0.1787 2.42929c0.3217 0.12505 0.4812 0.48724 0.3561 0.80897 -0.2805 0.72182 -0.75537 1.29603 -1.40641 1.68306 -0.64416 0.38292 -1.4264 0.56282 -2.30149 0.56282 -0.34518 0 -0.625 -0.2798 -0.625 -0.62501 0 -0.34518 0.27982 -0.625 0.625 -0.625 0.7083 0 1.25628 -0.14564 1.66273 -0.38728 0.39956 -0.23753 0.69571 -0.58697 0.88012 -1.06143 0.12505 -0.32173 0.48725 -0.48117 0.80895 -0.35613Z",clipRule:"evenodd"})})})}),f.jsxs("div",{className:"hidden md:flex items-center",children:[f.jsxs(Tc,{to:"/",className:"relative overflow-hidden bg-white text-black h-[34px] px-3 flex items-center text-[11px] font-medium uppercase border border-black leading-none group",children:[f.jsx("span",{className:"relative z-10",children:"DISCOVER"}),f.jsx("span",{className:"absolute inset-0 bg-[#FA76FF] translate-y-full group-hover:translate-y-0 transition-transform duration-300 ease-out"})]}),f.jsxs("button",{onClick:()=>{e?o("/create-event"):(l("/create-event"),r(!0))},className:"relative overflow-hidden bg-white text-black h-[34px] px-3 flex items-center text-[11px] font-medium uppercase border-l-0 border border-black leading-none group",children:[f.jsx("span",{className:"relative z-10",children:"CREATE EVENT"}),f.jsx("span",{className:"absolute inset-0 bg-[#FA76FF] translate-y-full group-hover:translate-y-0 transition-transform duration-300 ease-out"})]}),e?f.jsxs(f.Fragment,{children:[f.jsxs(Tc,{to:"/my-events",className:"relative overflow-hidden bg-white text-black h-[34px] px-3 flex items-center text-[11px] font-medium uppercase border-l-0 border border-black leading-none group",children:[f.jsx("span",{className:"relative z-10",children:"MY EVENTS"}),f.jsx("span",{className:"absolute inset-0 bg-[#FA76FF] translate-y-full group-hover:translate-y-0 transition-transform duration-300 ease-out"})]}),f.jsxs("button",{onClick:async()=>{await X.auth.signOut()},className:"relative overflow-hidden bg-white text-black h-[34px] px-3 flex items-center text-[11px] font-medium uppercase border-l-0 border border-black leading-none group",children:[f.jsx("span",{className:"relative z-10",children:"SIGN OUT"}),f.jsx("span",{className:"absolute inset-0 bg-[#FA76FF] translate-y-full group-hover:translate-y-0 transition-transform duration-300 ease-out"})]})]}):f.jsxs("button",{onClick:()=>r(!0),className:"relative overflow-hidden bg-white text-black h-[34px] px-3 flex items-center text-[11px] font-medium uppercase border-l-0 border border-black leading-none group",children:[f.jsx("span",{className:"relative z-10",children:"SIGN IN"}),f.jsx("span",{className:"absolute inset-0 bg-[#FA76FF] translate-y-full group-hover:translate-y-0 transition-transform duration-300 ease-out"})]})]}),s&&f.jsxs("div",{className:"md:hidden fixed inset-0 z-[3000] flex flex-col animate-in slide-in-from-top duration-300",children:[f.jsx("div",{className:"bg-[#1A1A1A] flex items-center justify-center py-16 animate-in fade-in duration-500",children:f.jsx("button",{onClick:()=>i(!1),className:"text-white text-[11px] font-medium uppercase tracking-wider",children:"CLOSE"})}),f.jsxs("div",{className:"flex-1 flex flex-col bg-white",children:[f.jsx(Tc,{to:"/",onClick:()=>i(!1),className:"flex-1 flex items-center justify-center text-[#1A1A1A] text-[17px] font-medium uppercase border-b border-black tracking-[-0.34px] animate-fade-in",style:{animationDelay:"0.1s",animationFillMode:"both"},children:"DISCOVER"}),f.jsx("button",{onClick:()=>{e?o("/create-event"):(l("/create-event"),r(!0)),i(!1)},className:"flex-1 flex items-center justify-center text-[#1A1A1A] text-[17px] font-medium uppercase border-b border-black tracking-[-0.34px] animate-fade-in",style:{animationDelay:"0.2s",animationFillMode:"both"},children:"CREATE EVENT"}),e?f.jsxs(f.Fragment,{children:[f.jsx(Tc,{to:"/my-events",onClick:()=>i(!1),className:"flex-1 flex items-center justify-center text-[#1A1A1A] text-[17px] font-medium uppercase border-b border-black tracking-[-0.34px] animate-fade-in",style:{animationDelay:"0.3s",animationFillMode:"both"},children:"MY EVENTS"}),f.jsx("button",{onClick:async()=>{await X.auth.signOut(),i(!1)},className:"flex-1 flex items-center justify-center text-[#1A1A1A] text-[17px] font-medium uppercase tracking-[-0.34px] animate-fade-in",style:{animationDelay:"0.4s",animationFillMode:"both"},children:"SIGN OUT"})]}):f.jsx("button",{onClick:()=>{r(!0),i(!1)},className:"flex-1 flex items-center justify-center text-[#1A1A1A] text-[17px] font-medium uppercase tracking-[-0.34px] animate-fade-in",style:{animationDelay:"0.3s",animationFillMode:"both"},children:"SIGN IN"})]})]}),f.jsxs("button",{onClick:()=>i(!s),className:"md:hidden relative overflow-hidden bg-white text-black h-[34px] px-3 border border-l-0 border-black flex items-center justify-center text-[11px] font-medium uppercase leading-none group",children:[f.jsx("span",{className:"relative z-10",children:"MENU"}),f.jsx("span",{className:"absolute inset-0 bg-[#FA76FF] translate-y-full group-hover:translate-y-0 transition-transform duration-300 ease-out"})]})]}),f.jsx(nf,{isOpen:n,onClose:()=>{r(!1),l(null)}})]}),document.body)},L4="/assets/badge-BNx_Ssz7.png",PE=({text:e,onClick:t,showIcon:n=!1,icon:r,className:s="fixed top-4 right-4 md:top-8 md:right-8"})=>{const o=(l=>{const u=l.length;return u<=4?8:u<=6?6:5})(e),a=100/o;return f.jsxs("div",{className:`${s} w-[60px] h-[60px] md:w-[72px] md:h-[72px] lg:w-[154px] lg:h-[154px] ${t?"cursor-pointer":""} z-40 animate-fade-in`,style:{animationDelay:"0.2s",animationFillMode:"both"},onClick:t,children:[f.jsxs("div",{className:"w-full h-full animate-[spin_20s_linear_infinite]",children:[f.jsx("img",{src:L4,alt:"Badge",className:"w-full h-full"}),f.jsxs("svg",{viewBox:"0 0 200 200",className:"w-full h-full absolute inset-0",children:[f.jsx("defs",{children:f.jsx("path",{id:"circlePath",d:"M 100, 30 a 70,70 0 1,1 0,140 a 70,70 0 1,1 0,-14
1920"})}),Array.from({length:o}).map((l,c)=>f.jsx("text",{className:"text-[16px] font-bold uppercase",fill:"black",children:f.jsx("textPath",{href:"#circlePath",startOffset:`${c*a}%`,children:e})},c))]})]}),n&&r&&f.jsx("div",{className:"absolute inset-0 flex items-center justify-center pointer-events-none",children:r})]})},F4=({targetDate:e=new Date(Date.now()+132*24*60*60*1e3+12*60*60*1e3+51*60*1e3+2*1e3)})=>{const t=a=>{const l=new Date().getTime(),c=a.getTime()-l;return c>0?{days:Math.floor(c/864e5),hours:Math.floor(c%864e5/36e5),minutes:Math.floor(c%36e5/6e4),seconds:Math.floor(c%6e4/1e3)}:{days:0,hours:0,minutes:0,seconds:0}},r=(()=>{const a=new Date().getTime(),c=e.getTime()-a,u=1e3*60*60;return c<-u?"ended":c>=-u&&c<=u?"happening":"upcoming"})(),[s,i]=w.useState(()=>t(e));w.useEffect(()=>{const a=setInterval(()=>{i(t(e))},1e3);return()=>clearInterval(a)},[e]);const o=(a,l)=>`${a.toString().padStart(l==="D"?1:2,"0")}${l}`;return r==="ended"?null:r==="happening"?f.jsx(PE,{text:"LIVE",showIcon:!1,className:"relative w-[80px] h-[80px] md:w-[100px] md:h-[100px] lg:w-[120px] lg:h-[120px]"}):f.jsxs("div",{className:"flex items-center gap-[2px] w-[409px] h-[49px] max-md:static max-md:w-auto max-md:justify-center max-sm:flex-wrap",children:[f.jsx("div",{className:"flex justify-center items-center gap-[5px] relative bg-white px-4 py-2.5 max-sm:px-3 max-sm:py-2 animate-fade-in",style:{animationDelay:"0.1s",animationFillMode:"both"},children:f.jsx("div",{className:"text-[#1A1A1A] text-[42px] font-medium tracking-[-1.68px] relative max-md:text-[32px] max-md:tracking-[-1.28px] max-sm:text-2xl max-sm:tracking-[-0.96px]",children:o(s.days,"D")})}),f.jsx("div",{className:"flex justify-center items-center gap-[5px] relative bg-white px-4 py-2.5 max-sm:px-3 max-sm:py-2 animate-fade-in",style:{animationDelay:"0.2s",animationFillMode:"both"},children:f.jsx("div",{className:"text-[#1A1A1A] text-[42px] font-medium tracking-[-1.68px] relative max-md:text-[32px] max-md:tracking-[-1.28px] max-sm:text-2xl max-sm:tracking-[-0.96px]",children:o(s.hours,"H")})}),f.jsx("div",{className:"flex justify-center items-center gap-[5px] relative bg-white px-4 py-2.5 max-sm:px-3 max-sm:py-2 mx-0 animate-fade-in",style:{animationDelay:"0.3s",animationFillMode:"both"},children:f.jsx("div",{className:"text-[#1A1A1A] text-[42px] font-medium tracking-[-1.68px] relative max-md:text-[32px] max-md:tracking-[-1.28px] max-sm:text-2xl max-sm:tracking-[-0.96px]",children:o(s.minutes,"M")})}),f.jsx("div",{className:"flex justify-center items-center gap-[5px] relative bg-white px-4 py-2.5 max-sm:px-3 max-sm:py-2 animate-fade-in",style:{animationDelay:"0.4s",animationFillMode:"both"},children:f.jsx("div",{className:"text-[#1A1A1A] text-[42px] font-medium tracking-[-1.68px] relative max-md:text-[32px] max-md:tracking-[-1.28px] max-sm:text-2xl max-sm:tracking-[-0.96px]",children:o(s.seconds,"S")})})]})},$4=({date:e,time:t})=>f.jsxs("div",{className:"flex items-start gap-[-1px] relative",children:[f.jsx("div",{className:"flex justify-center items-center gap-2.5 relative bg-[#1A1A1A] px-2 h-[24px]",children:f.jsx("time",{className:"text-white text-[11px] font-normal uppercase relative",children:e})}),f.jsx("div",{className:"flex justify-center items-center gap-2.5 border relative px-2 h-[24px] border-solid border-[#1A1A1A]",children:f.jsx("time",{className:"text-[#1A1A1A] text-[11px] font-normal uppercase relative",children:t})})]}),B4=({title:e,creator:t})=>f.jsxs("div",{className:"flex flex-col items-start gap-4 self-stretch relative",children:[f.jsx("header",{children:f.jsx("h1",{className:"self-stretch text-[#1A1A1A] text-[56px] font-medium leading-[54.88px] tracking-[-2.24px] relative max-md:text-[42px] max-md:leading-[38px] max-md:tracking-[-1.68px] max-sm:text-[32px] max-sm:leading-[30px] max-sm:tracking-[-1.28px]",children:e})}),f.jsxs("div",{className:"self-stretch text-[#1A1A1A] text-[11px] font-normal uppercase relative",children:["BY ",t]})]}),V4=({description:e})=>f.jsxs("section",{className:"flex flex-col items-start gap-4 self-stretch relative",children:[f.jsxs("div",{className:"flex flex-col items-start gap-5 self-stretch relative my-0",children:[f.jsx("hr",{className:"h-px self-stretch relative bg-[#1A1A1A] border-0"}),f.jsx("h2",{className:"self-stretch text-[#1A1A1A] text-[11px] font-normal uppercase relative",children:"ABOUT THIS EVENT"})]}),f.jsx("p",{className:"self-stretch text-[#1A1A1A] text-[17px] font-normal leading-[20.74px] tracking-[-0.34px] relative",children:e})]}),U4="data:image/svg+xml,%3csvg%20width='8'%20height='10'%20viewBox='0%200%208%2010'%20fill='none'%20xmlns='http://www.w3.org/2000/svg'%3e%3cpath%20d='M5.45701e-07%209.33333L8%204.9L9.53674e-07%20-3.49691e-07L1.82857%204.9L5.45701e-07%209.33333Z'%20fill='%231A1A1A'/%3e%3c/svg%3e",z4=({address:e,onGetDirections:t})=>{const n=encodeURIComponent(e);return f.jsxs("section",{className:"flex flex-col items-start gap-4 self-stretch relative",children:[f.jsxs("div",{className:"flex flex-col items-start gap-5 self-stretch relative",children:[f.jsx("hr",{className:"h-px self-stretch relative bg-[#1A1A1A] border-0"}),f.jsx("h2",{className:"self-stretch text-[#1A1A1A] text-[11px] font-normal uppercase relative",children:"LOCATION"})]}),f.jsxs("div",{className:"flex items-start gap-8 self-stretch relative max-sm:flex-col max-sm:gap-4",children:[f.jsx("address",{className:"flex-1 text-[#1A1A1A] text-[17px] font-normal leading-[20.74px] tracking-[-0.34px] relative not-italic",children:e}),f.jsxs("a",{href:`https://maps.google.com/?q=${n}`,target:"_blank",rel:"noopener noreferrer",className:"text-[#1A1A1A] text-[11px] font-normal uppercase relative bg-transparent cursor-pointer hover:opacity-70 transition-opacity flex items-center gap-2 no-underline whitespace-nowrap",children:[f.jsx("img",{src:U4,alt:"",className:"w-2 h-2.5"}),"GET DIRECTIONS"]})]}),f.jsx("iframe",{src:`https://www.google.com/maps?q=${n}&output=embed`,className:"h-[214px] self-stretch relative w-full max-sm:h-[180px] border-0",loading:"lazy",title:"Event location map"})]})}
192,W4=({eventId:e,onRegister:t,isRegistered:n,className:r="",onAuthRequired:s,targetDate:i})=>{const[o,a]=w.useState(null),[l,c]=w.useState(n),[u,d]=w.useState(!1),{toast:h}=Wl();w.useEffect(()=>{X.auth.getSession().then(({data:{session:v}})=>{a((v==null?void 0:v.user)??null),v!=null&&v.user&&p(v.user.id)});const{data:{subscription:m}}=X.auth.onAuthStateChange((v,_)=>{a((_==null?void 0:_.user)??null),_!=null&&_.user&&p(_.user.id)});return()=>m.unsubscribe()},[e]);const p=async m=>{const{data:v}=await X.from("event_registrations").select("id").eq("user_id",m).eq("event_id",e).maybeSingle();c(!!v)},x=(()=>{if(!i)return"upcoming";const m=new Date().getTime(),_=i.getTime()-m,S=1e3*60*60;return _<-S?"ended":_>=-S&&_<=S?"happening":"upcoming"})()==="ended",y=async()=>{if(x){h({title:"Event has ended",description:"You cannot register for past events",variant:"destructive"});return}if(!o){s?s():h({title:"Sign in required",description:"Please sign in to register for events",variant:"destructive"});return}d(!0);try{if(l){const{error:m}=await X.from("event_registrations").delete().eq("user_id",o.id).eq("event_id",e);if(m)throw m;c(!1),h({title:"Unregistered",description:"You have been unregistered from this event"})}else{const{error:m}=await X.from("event_registrations").insert({user_id:o.id,event_id:e});if(m)throw m;c(!0),t(),h({title:"Registered!",description:"You have successfully registered for this event"})}}catch(m){h({title:"Error",description:m.message,variant:"destructive"})}finally{d(!1)}};return f.jsxs("div",{className:`group flex items-center self-stretch relative overflow-hidden ${r}`,children:[f.jsxs("button",{onClick:y,disabled:u||x,className:`flex h-[50px] justify-center items-center gap-2.5 border relative px-2.5 py-3.5 border-solid transition-all duration-300 ease-in-out disabled:opacity-50 disabled:cursor-not-allowed w-[calc(100%-50px)] z-10 ${x?"bg-gray-400 border-gray-400 cursor-not-allowed":"bg-[#1A1A1A] border-[#1A1A1A] group-hover:w-full group-hover:bg-[#FA76FF] group-hover:border-[#FA76FF]"}`,"aria-label":x?"Event has ended":l?"Unregister from event":"Register for event",children:[f.jsx("span",{className:`text-white text-[13px] font-normal uppercase relative transition-colors duration-300 ${!x&&"group-hover:text-black"}`,children:u?"LOADING...":x?"EVENT ENDED":l?"UNREGISTER":"REGISTER"}),f.jsxs("svg",{width:"12",height:"12",viewBox:"0 0 12 12",fill:"none",xmlns:"http://www.w3.org/2000/svg",className:"absolute right-[18px] opacity-0 transition-all duration-300 ease-in-out group-hover:opacity-100","aria-hidden":"true",children:[f.jsx("path",{d:"M0.857178 6H10.3929",stroke:"#1A1A1A",strokeWidth:"1.5"}),f.jsx("path",{d:"M6.39282 10L10.3928 6L6.39282 2",stroke:"#1A1A1A",strokeWidth:"1.5"})]})]}),!x&&f.jsx("div",{className:"flex w-[50px] h-[50px] justify-center items-center border absolute right-0 bg-white rounded-[99px] border-solid border-[#1A1A1A] transition-all duration-300 ease-in-out group-hover:opacity-0 group-hover:scale-50 pointer-events-none z-0",children:f.jsxs("svg",{width:"12",height:"12",viewBox:"0 0 12 12",fill:"none",xmlns:"http://www.w3.org/2000/svg",className:"arrow-icon","aria-hidden":"true",children:[f.jsx("path",{d:"M0.857178 6H10.3929",stroke:"#1A1A1A",strokeWidth:"1.5"}),f.jsx("path",{d:"M6.39282 10L10.3928 6L6.39282 2",stroke:"#1A1A1A",strokeWidth:"1.5"})]})})]})},lr=({title:e,description:t,keywords:n="events, discover events, event management, community events",image:r="/placeholder.svg",url:s=window.location.href})=>{const i=`${e} | EventHub`;return f.jsxs(qR,{children:[f.jsx("title",{children:i}),f.jsx("meta",{name:"title",content:i}),f.jsx("meta",{name:"description",content:t}),n&&f.jsx("meta",{name:"keywords",content:n}),f.jsx("meta",{name:"viewport",content:"width=device-width, initial-scale=1.0"}),f.jsx("link",{rel:"canonical",href:s}),f.jsx("meta",{property:"og:type",content:"website"}),f.jsx("meta",{property:"og:url",content:s}),f.jsx("meta",{property:"og:title",content:i}),f.jsx("meta",{property:"og:description",content:t}),f.jsx("meta",{property:"og:image",content:r}),f.jsx("meta",{name:"twitter:card",content:"summary_large_image"}),f.jsx("meta",{name:"twitter:url",content:s}),f.jsx("meta",{name:"twitter:title",content:i}),f.jsx("meta",{name:"twitter:description",content:t}),f.jsx("meta",{name:"twitter:image",content:r})]})},H4=()=>{const{id:e}=wS(),t=Fn(),[n,r]=w.useState(!1),[s,i]=w.useState(null),[o,a]=w.useState(!0),[l,c]=w.useState(!1),[u,d]=w.useState(!1);w.useEffect(()=>{h(),p()},[e]);const h=async()=>{const{data:g,error:x}=e?await X.from("events").select("*").eq("id",e).maybeSingle():await X.from("events").select("*").limit(1).maybeSingle();x?d(!0):g?i(g):d(!0),a(!1)},p=async()=>
192{if(!e)return;const{data:{session:g}}=await X.auth.getSession();if(!(g!=null&&g.user))return;const{data:x}=await X.from("event_registrations").select("id").eq("user_id",g.user.id).eq("event_id",e).maybeSingle();r(!!x)},b=()=>{console.log("Opening directions"),window.open("https://maps.google.com","_blank")};return o?f.jsx("div",{className:"flex h-screen items-center justify-center bg-white",children:f.jsx("div",{className:"text-[#1A1A1A] text-2xl",children:"Loading..."})}):u||!s?f.jsxs("div",{className:"flex flex-col h-screen items-center justify-center bg-white px-4",children:[f.jsx(lr,{title:"Event Not Found",description:"The event you're looking for doesn't exist or has been removed."}),f.jsx(vi,{}),f.jsxs("div",{className:"text-center mt-20",children:[f.jsx("h1",{className:"text-4xl font-medium mb-4 text-[#1A1A1A]",children:"Event Not Found"}),f.jsx("p",{className:"text-lg text-[#1A1A1A] opacity-70 mb-8",children:"The event you're looking for doesn't exist or has been removed."}),f.jsx("button",{onClick:()=>t("/discover"),className:"px-6 py-3 bg-[#1A1A1A] text-white border border-[#1A1A1A] hover:bg-white hover:text-[#1A1A1A] transition-colors uppercase text-sm font-medium",children:"Browse Events"})]})]}):f.jsxs(f.Fragment,{children:[f.jsx(lr,{title:s.title,description:s.description.substring(0,160),image:s.background_image_url,keywords:`event, ${s.title}, ${s.address}, community event`}),f.jsx("link",{href:"https://fonts.googleapis.com/css2?family=Host+Grotesk:wght@400;500;600;700&display=swap",rel:"stylesheet"}),f.jsx(vi,{}),f.jsxs("main",{className:"flex h-screen justify-center items-start w-full relative bg-white mx-auto my-0 max-lg:flex-col max-lg:h-auto",children:[f.jsxs("div",{className:"flex flex-col justify-end items-start fixed h-screen w-[calc(100%-540px)] pl-[49px] pr-[590px] pt-[calc(100vh-97px)] pb-12 left-0 top-0 overflow-hidden max-lg:relative max-lg:w-full max-lg:h-[400px] max-lg:bg-cover max-lg:bg-center max-lg:pt-80 max-lg:pb-6 max-lg:px-4 max-lg:right-0 max-sm:h-[300px] max-sm:pt-60 max-sm:pb-6 max-sm:px-4",role:"img","aria-label":"Event background image",children:[f.jsx("div",{className:"absolute inset-0 animate-[zoom-in_1.2s_ease-out_forwards]",style:{backgroundImage:`url("${s.background_image_url}")`,backgroundSize:"cover",backgroundPosition:"center"}}),f.jsx("div",{className:"relative z-10 animate-fade-in",style:{animationDelay:"0.5s",animationFillMode:"both"},children:f.jsx(F4,{targetDate:new Date(s.target_date)})})]}),f.jsxs("aside",{className:"flex w-[540px] flex-col justify-start items-start fixed h-screen box-border right-0 top-0 bg-white overflow-y-auto max-lg:relative max-lg:w-full max-lg:h-auto max-lg:right-auto max-lg:top-0 max-lg:overflow-y-visible",children:[f.jsxs("div",{className:"flex w-full flex-col items-start gap-10 relative p-10 pb-24 max-lg:w-full max-lg:px-4 max-lg:py-6 max-lg:pb-6 max-lg:gap-8 opacity-0 animate-fade-in [animation-delay:200ms]",children:[f.jsxs("div",{className:"flex flex-col items-start gap-4 self-stretch relative",children:[f.jsx($4,{date:s.date,time:s.time}),f.jsx(B4,{title:s.title,creator:s.creator})]}),f.jsx(V4,{description:s.description}),f.jsx(z4,{address:s.address,onGetDirections:b})]}),f.jsx("div",{className:"fixed bottom-0 right-0 w-[540px] bg-white py-6 border-t border-border max-lg:relative max-lg:w-full max-lg:py-6 max-lg:border-t-0",children:f.jsx("div",{className:"px-10 max-lg:px-4",children:f.jsx(W4,{eventId:s.id,onRegister:p,isRegistered:n,onAuthRequired:()=>c(!0),targetDate:new Date(s.target_date),className:"opacity-0 animate-fade-in [animation-delay:400ms]"})})})]})]}),f.jsx(nf,{isOpen:l,onClose:()=>c(!1)})]})},K4=()=>f.jsx(H4,{});function he(e){const t=Object.prototype.toString.call(e);return e instanceof Date||typeof e=="object"&&t==="[object Date]"?new e.constructor(+e):typeof e=="number"||t==="[object Number]"||typeof e=="string"||t==="[object String]"?new Date(e):new Date(NaN)}function Wt(e,t){return e instanceof Date?new e.constructor(t):new Date(t)}function mt(e,t){const n=he(e);return isNaN(t)?Wt(e,NaN):(t&&n.setDate(n.getDate()+t),n)}function Dn(e,t){const n=he(e);if(isNaN(t))return Wt(e,NaN);if(!t)return n;const r=n.getDate(),s=Wt(e,n.getTime());s.setMonth(n.getMonth()+t+1,0);const i=s.getDate();return r>=i?s:(n.setFullYear(s.getFullYear(),s.getMonth(),r),n)}const gv=6048e5,q4=864e5;let Y4={};function Jl(){return Y4}function cr(e,t){var a,l,c,u;
192const n=Jl(),r=(t==null?void 0:t.weekStartsOn)??((l=(a=t==null?void 0:t.locale)==null?void 0:a.options)==null?void 0:l.weekStartsOn)??n.weekStartsOn??((u=(c=n.locale)==null?void 0:c.options)==null?void 0:u.weekStartsOn)??0,s=he(e),i=s.getDay(),o=(i<r?7:0)+i-r;return s.setDate(s.getDate()-o),s.setHours(0,0,0,0),s}function yi(e){return cr(e,{weekStartsOn:1})}function jE(e){const t=he(e),n=t.getFullYear(),r=Wt(e,0);r.setFullYear(n+1,0,4),r.setHours(0,0,0,0);const s=yi(r),i=Wt(e,0);i.setFullYear(n,0,4),i.setHours(0,0,0,0);const o=yi(i);return t.getTime()>=s.getTime()?n+1:t.getTime()>=o.getTime()?n:n-1}function Bo(e){const t=he(e);return t.setHours(0,0,0,0),t}function id(e){const t=he(e),n=new Date(Date.UTC(t.getFullYear(),t.getMonth(),t.getDate(),t.getHours(),t.getMinutes(),t.getSeconds(),t.getMilliseconds()));return n.setUTCFullYear(t.getFullYear()),+e-+n}function er(e,t){const n=Bo(e),r=Bo(t),s=+n-id(n),i=+r-id(r);return Math.round((s-i)/q4)}function G4(e){const t=jE(e),n=Wt(e,0);return n.setFullYear(t,0,4),n.setHours(0,0,0,0),yi(n)}function pm(e,t){const n=t*7;return mt(e,n)}function Q4(e,t){return Dn(e,t*12)}function Z4(e){let t;return e.forEach(function(n){const r=he(n);(t===void 0||t<r||isNaN(Number(r)))&&(t=r)}),t||new Date(NaN)}function J4(e){let t;return e.forEach(n=>{const r=he(n);(!t||t>r||isNaN(+r))&&(t=r)}),t||new Date(NaN)}function At(e,t){const n=Bo(e),r=Bo(t);return+n==+r}function vv(e){return e instanceof Date||typeof e=="object"&&Object.prototype.toString.call(e)==="[object Date]"}function X4(e){if(!vv(e)&&typeof e!="number")return!1;const t=he(e);return!isNaN(Number(t))}function El(e,t){const n=he(e),r=he(t),s=n.getFullYear()-r.getFullYear(),i=n.getMonth()-r.getMonth();return s*12+i}function e3(e,t,n){const r=cr(e,n),s=cr(t,n),i=+r-id(r),o=+s-id(s);return Math.round((i-o)/gv)}function yv(e){const t=he(e),n=t.getMonth();return t.setFullYear(t.getFullYear(),n+1,0),t.setHours(23,59,59,999),t}function Rt(e){const t=he(e);return t.setDate(1),t.setHours(0,0,0,0),t}function NE(e){const t=he(e),n=Wt(e,0);return n.setFullYear(t.getFullYear(),0,1),n.setHours(0,0,0,0),n}function wv(e,t){var a,l,c,u;const n=Jl(),r=(t==null?void 0:t.weekStartsOn)??((l=(a=t==null?void 0:t.locale)==null?void 0:a.options)==null?void 0:l.weekStartsOn)??n.weekStartsOn??((u=(c=n.locale)==null?void 0:c.options)==null?void 0:u.weekStartsOn)??0,s=he(e),i=s.getDay(),o=(i<r?-7:0)+6-(i-r);return s.setDate(s.getDate()+o),s.setHours(23,59,59,999),s}function RE(e){return wv(e,{weekStartsOn:1})}const t3={lessThanXSeconds:{one:"less than a second",other:"less than {{count}} seconds"},xSeconds:{one:"1 second",other:"{{count}} seconds"},halfAMinute:"half a minute",lessThanXMinutes:{one:"less than a minute",other:"less than {{count}} minutes"},xMinutes:{one:"1 minute",other:"{{count}} minutes"},aboutXHours:{one:"about 1 hour",other:"about {{count}} hours"},xHours:{one:"1 hour",other:"{{count}} hours"},xDays:{one:"1 day",other:"{{count}} days"},aboutXWeeks:{one:"about 1 week",other:"about {{count}} weeks"},xWeeks:{one:"1 week",other:"{{count}} weeks"},aboutXMonths:{one:"about 1 month",other:"about {{count}} months"},xMonths:{one:"1 month",other:"{{count}} months"},aboutXYears:{one:"about 1 year",other:"about {{count}} years"},xYears:{one:"1 year",other:"{{count}} years"},overXYears:{one:"over 1 year",other:"over {{count}} years"},almostXYears:{one:"almost 1 year",other:"almost {{count}} years"}},n3=(e,t,n)=>{let r;const s=t3[e];return typeof s=="string"?r=s:t===1?r=s.one:r=s.other.replace("{{count}}",t.toString()),n!=null&&n.addSuffix?n.comparison&&n.comparison>0?"in "+r:r+" ago":r};function dh(e){return(t={})=>{const n=t.width?String(t.width):e.defaultWidth;return e.formats[n]||e.formats[e.defaultWidth]}}const r3={full:"EEEE, MMMM do, y",long:"MMMM do, y",medium:"MMM d, y",short:"MM/dd/yyyy"},s3={full:"h:mm:ss a zzzz",long:"h:mm:ss a z",medium:"h:mm:ss a",short:"h:mm a"},i3={full:"{{date}} 'at' {{time}}",long:"{{date}} 'at' {{time}}",medium:"{{date}}, {{time}}",short:"{{date}}, {{time}}"},o3={date:dh({formats:r3,defaultWidth:"full"}),time:dh({formats:s3,defaultWidth:"full"}),dateTime:dh({formats:i3,defaultWidth:"full"})},a3={lastWeek:"'last' eeee 'at' p",yesterday:"'yesterday at' p",today:"'today at' p",tomorrow:"'tomorrow at' p",nextWeek:"eeee 'at' p",other:"P"},l3=(e,t,n,r)=>a3[e];function _a(e){return(t,n)=>{const r=n!=null&&n.context?String(n.context):"standalone";let s;if(r==="formatting"&&e.formattingValues){const o=e.defaultFormattingWidth||e.defaultWidth,a=n!=null&&n.width?String(n.width):o;s=e.formattingValues[a]||e.formattingValues[o]}else{const o=e.defaultWidth,a=n!=null&&n.width?String(n.width):e.defaultWidth;s=e.values[a]||e.values[o]}const i=e.argumentCallback?e.argumentCallback(t):t;return s[i]}}const c3={narrow:["B","A"],abbreviated:["BC","AD"],wide:["Before Christ","Anno Domini"]},u3={narrow:["1","2","3","4"],abbreviated:["Q1","Q2","Q3","Q4"],wide:["1st quarter","2nd quarter","3rd quarter","4th quarter"]},d3={narrow:["J","F","M","A","M","J","J","A","S","O","N","D"],abbreviated:["Jan","Feb","Mar","Apr","May","Jun","Jul","Aug","Sep","Oct","Nov","Dec"],wide:["January","February","March","April","May","June","July","August","September","October","November","December"]},f3={narrow:["S","M","T","W","T","F","S"],short:["Su","Mo","Tu","We","Th","Fr","Sa"],abbreviated:["Sun","Mon","Tue","Wed","Thu","Fri","Sat"],wide:["Sunday","Monday","Tuesday","Wednesday","Thursday","Frid
192ay","Saturday"]},h3={narrow:{am:"a",pm:"p",midnight:"mi",noon:"n",morning:"morning",afternoon:"afternoon",evening:"evening",night:"night"},abbreviated:{am:"AM",pm:"PM",midnight:"midnight",noon:"noon",morning:"morning",afternoon:"afternoon",evening:"evening",night:"night"},wide:{am:"a.m.",pm:"p.m.",midnight:"midnight",noon:"noon",morning:"morning",afternoon:"afternoon",evening:"evening",night:"night"}},p3={narrow:{am:"a",pm:"p",midnight:"mi",noon:"n",morning:"in the morning",afternoon:"in the afternoon",evening:"in the evening",night:"at night"},abbreviated:{am:"AM",pm:"PM",midnight:"midnight",noon:"noon",morning:"in the morning",afternoon:"in the afternoon",evening:"in the evening",night:"at night"},wide:{am:"a.m.",pm:"p.m.",midnight:"midnight",noon:"noon",morning:"in the morning",afternoon:"in the afternoon",evening:"in the evening",night:"at night"}},m3=(e,t)=>{const n=Number(e),r=n%100;if(r>20||r<10)switch(r%10){case 1:return n+"st";case 2:return n+"nd";case 3:return n+"rd"}return n+"th"},g3={ordinalNumber:m3,era:_a({values:c3,defaultWidth:"wide"}),quarter:_a({values:u3,defaultWidth:"wide",argumentCallback:e=>e-1}),month:_a({values:d3,defaultWidth:"wide"}),day:_a({values:f3,defaultWidth:"wide"}),dayPeriod:_a({values:h3,defaultWidth:"wide",formattingValues:p3,defaultFormattingWidth:"wide"})};function Sa(e){return(t,n={})=>{const r=n.width,s=r&&e.matchPatterns[r]||e.matchPatterns[e.defaultMatchWidth],i=t.match(s);if(!i)return null;const o=i[0],a=r&&e.parsePatterns[r]||e.parsePatterns[e.defaultParseWidth],l=Array.isArray(a)?y3(a,d=>d.test(o)):v3(a,d=>d.test(o));let c;c=e.valueCallback?e.valueCallback(l):l,c=n.valueCallback?n.valueCallback(c):c;const u=t.slice(o.length);return{value:c,rest:u}}}function v3(e,t){for(const n in e)if(Object.prototype.hasOwnProperty.call(e,n)&&t(e[n]))return n}function y3(e,t){for(let n=0;n<e.length;n++)if(t(e[n]))return n}function w3(e){return(t,n={})=>{const r=t.match(e.matchPattern);if(!r)return null;const s=r[0],i=t.match(e.parsePattern);if(!i)return null;let o=e.valueCallback?e.valueCallback(i[0]):i[0];o=n.valueCallback?n.valueCallback(o):o;const a=t.slice(s.length);return{value:o,rest:a}}}const x3=/^(\d+)(th|st|nd|rd)?/i,b3=/\d+/i,_3={narrow:/^(b|a)/i,abbreviated:/^(b\.?\s?c\.?|b\.?\s?c\.?\s?e\.?|a\.?\s?d\.?|c\.?\s?e\.?)/i,wide:/^(before christ|before common era|anno domini|common era)/i},S3={any:[/^b/i,/^(a|c)/i]},k3={narrow:/^[1234]/i,abbreviated:/^q[1234]/i,wide:/^[1234](th|st|nd|rd)? quarter/i},E3={any:[/1/i,/2/i,/3/i,/4/i]},C3={narrow:/^[jfmasond]/i,abbreviated:/^(jan|feb|mar|apr|may|jun|jul|aug|sep|oct|nov|dec)/i,wide:/^(january|february|march|april|may|june|july|august|september|october|november|december)/i},T3={narrow:[/^j/i,/^f/i,/^m/i,/^a/i,/^m/i,/^j/i,/^j/i,/^a/i,/^s/i,/^o/i,/^n/i,/^d/i],any:[/^ja/i,/^f/i,/^mar/i,/^ap/i,/^may/i,/^jun/i,/^jul/i,/^au/i,/^s/i,/^o/i,/^n/i,/^d/i]},A3={narrow:/^[smtwf]/i,short:/^(su|mo|tu|we|th|fr|sa)/i,abbreviated:/^(sun|mon|tue|wed|thu|fri|sat)/i,wide:/^(sunday|monday|tuesday|wednesday|thursday|friday|saturday)/i},P3={narrow:[/^s/i,/^m/i,/^t/i,/^w/i,/^t/i,/^f/i,/^s/i],any:[/^su/i,/^m/i,/^tu/i,/^w/i,/^th/i,/^f/i,/^sa/i]},j3={narrow:/^(a|p|mi|n|(in the|at) (morning|afternoon|evening|night))/i,any:/^([ap]\.?\s?m\.?|midnight|noon|(in the|at) (morning|afternoon|evening|night))/i},N3={any:{am:/^a/i,pm:/^p/i,midnight:/^mi/i,noon:/^no/i,morning:/morning/i,afternoon:/afternoon/i,evening:/evening/i,night:/night/i}},R3={ordinalNumber:w3({matchPattern:x3,parsePattern:b3,valueCallback:e=>parseInt(e,10)}),era:Sa({matchPatterns:_3,defaultMatchWidth:"wide",parsePatterns:S3,defaultParseWidth:"any"}),quarter:Sa({matchPatterns:k3,defaultMatchWidth:"wide",parsePatterns:E3,defaultParseWidth:"any",valueCallback:e=>e+1}),month:Sa({matchPatterns:C3,defaultMatchWidth:"wide",parsePatterns:T3,defaultParseWidth:"any"}),day:Sa({matchPatterns:A3,defaultMatchWidth:"wide",parsePatterns:P3,defaultParseWidth:"any"}),dayPeriod:Sa({matchPatterns:j3,defaultMatchWidth:"any",parsePatterns:N3,defaultParseWidth:"any"})},OE={code:"en-US",formatDistance:n3,formatLong:o3,formatRelative:l3,localize:g3,match:R3,options:{weekStartsOn:0,firstWeekContainsDate:1}};function O3(e){const t=he(e);return er(t,NE(t))+1}function ME(e){const t=he(e),n=+yi(t)-+G4(t);return Math.round(n/gv)+1}function DE(e,t){var u,d,h,p;const n=he(e),r=n.getFullYear(),s=Jl(),i=(t==null?void 0:t.firstWeekContainsDate)??((d=(u=t==null?void 0:t.locale)==null?void 0:u.options)==null?void 0:d.firstWeekContainsDate)??s.firstWeekContainsDate??((p=(h=s.locale)==null?void 0:h.options)==null?void 0:p.firstWeekContainsDate)??1,o=Wt(e,0);o.setFullYear(r+1,0,i),o.setHours(0,0,0,0);const a=cr(o,t),l=Wt(e,0);l.setFullYear(r,0,i),l.setHours(0,0,0,0);const c=cr(l,t);return n.getTime()>=a.getTime()?r+1:n.getTime()>=c.getTime()?r:r-1}function M3(e,t){var a,l,c,u;
vendor: 5,948 bytes, line 192
192const n=Jl(),r=(t==null?void 0:t.firstWeekContainsDate)??((l=(a=t==null?void 0:t.locale)==null?void 0:a.options)==null?void 0:l.firstWeekContainsDate)??n.firstWeekContainsDate??((u=(c=n.locale)==null?void 0:c.options)==null?void 0:u.firstWeekContainsDate)??1,s=DE(e,t),i=Wt(e,0);return i.setFullYear(s,0,r),i.setHours(0,0,0,0),cr(i,t)}function IE(e,t){const n=he(e),r=+cr(n,t)-+M3(n,t);return Math.round(r/gv)+1}function ve(e,t){const n=e<0?"-":"",r=Math.abs(e).toString().padStart(t,"0");return n+r}const Br={y(e,t){const n=e.getFullYear(),r=n>0?n:1-n;return ve(t==="yy"?r%100:r,t.length)},M(e,t){const n=e.getMonth();return t==="M"?String(n+1):ve(n+1,2)},d(e,t){return ve(e.getDate(),t.length)},a(e,t){const n=e.getHours()/12>=1?"pm":"am";switch(t){case"a":case"aa":return n.toUpperCase();case"aaa":return n;case"aaaaa":return n[0];case"aaaa":default:return n==="am"?"a.m.":"p.m."}},h(e,t){return ve(e.getHours()%12||12,t.length)},H(e,t){return ve(e.getHours(),t.length)},m(e,t){return ve(e.getMinutes(),t.length)},s(e,t){return ve(e.getSeconds(),t.length)},S(e,t){const n=t.length,r=e.getMilliseconds(),s=Math.trunc(r*Math.pow(10,n-3));return ve(s,t.length)}},$i={am:"am",pm:"pm",midnight:"midnight",noon:"noon",morning:"morning",afternoon:"afternoon",evening:"evening",night:"night"},Rw={G:function(e,t,n){const r=e.getFullYear()>0?1:0;switch(t){case"G":case"GG":case"GGG":return n.era(r,{width:"abbreviated"});case"GGGGG":return n.era(r,{width:"narrow"});case"GGGG":default:return n.era(r,{width:"wide"})}},y:function(e,t,n){if(t==="yo"){const r=e.getFullYear(),s=r>0?r:1-r;return n.ordinalNumber(s,{unit:"year"})}return Br.y(e,t)},Y:function(e,t,n,r){const s=DE(e,r),i=s>0?s:1-s;if(t==="YY"){const o=i%100;return ve(o,2)}return t==="Yo"?n.ordinalNumber(i,{unit:"year"}):ve(i,t.length)},R:function(e,t){const n=jE(e);return ve(n,t.length)},u:function(e,t){const n=e.getFullYear();return ve(n,t.length)},Q:function(e,t,n){const r=Math.ceil((e.getMonth()+1)/3);switch(t){case"Q":return String(r);case"QQ":return ve(r,2);case"Qo":return n.ordinalNumber(r,{unit:"quarter"});case"QQQ":return n.quarter(r,{width:"abbreviated",context:"formatting"});case"QQQQQ":return n.quarter(r,{width:"narrow",context:"formatting"});case"QQQQ":default:return n.quarter(r,{width:"wide",context:"formatting"})}},q:function(e,t,n){const r=Math.ceil((e.getMonth()+1)/3);switch(t){case"q":return String(r);case"qq":return ve(r,2);case"qo":return n.ordinalNumber(r,{unit:"quarter"});case"qqq":return n.quarter(r,{width:"abbreviated",context:"standalone"});case"qqqqq":return n.quarter(r,{width:"narrow",context:"standalone"});case"qqqq":default:return n.quarter(r,{width:"wide",context:"standalone"})}},M:function(e,t,n){const r=e.getMonth();switch(t){case"M":case"MM":return Br.M(e,t);case"Mo":return n.ordinalNumber(r+1,{unit:"month"});case"MMM":return n.month(r,{width:"abbreviated",context:"formatting"});case"MMMMM":return n.month(r,{width:"narrow",context:"formatting"});case"MMMM":default:return n.month(r,{width:"wide",context:"formatting"})}},L:function(e,t,n){const r=e.getMonth();switch(t){case"L":return String(r+1);case"LL":return ve(r+1,2);case"Lo":return n.ordinalNumber(r+1,{unit:"month"});case"LLL":return n.month(r,{width:"abbreviated",context:"standalone"});case"LLLLL":return n.month(r,{width:"narrow",context:"standalone"});case"LLLL":default:return n.month(r,{width:"wide",context:"standalone"})}},w:function(e,t,n,r){const s=IE(e,r);return t==="wo"?n.ordinalNumber(s,{unit:"week"}):ve(s,t.length)},I:function(e,t,n){const r=ME(e);return t==="Io"?n.ordinalNumber(r,{unit:"week"}):ve(r,t.length)},d:function(e,t,n){return t==="do"?n.ordinalNumber(e.getDate(),{unit:"date"}):Br.d(e,t)},D:function(e,t,n){const r=O3(e);return t==="Do"?n.ordinalNumber(r,{unit:"dayOfYear"}):ve(r,t.length)},E:function(e,t,n){const r=e.getDay();switch(t){case"E":case"EE":case"EEE":return n.day(r,{width:"abbreviated",context:"formatting"});case"EEEEE":return n.day(r,{width:"narrow",context:"formatting"});case"EEEEEE":return n.day(r,{width:"short",context:"formatting"});case"EEEE":default:return n.day(r,{width:"wide",context:"formatting"})}},e:function(e,t,n,r){const s=e.getDay(),i=(s-r.weekStartsOn+8)%7||7;switch(t){case"e":return String(i);case"ee":return ve(i,2);case"eo":return n.ordinalNumber(i,{unit:"day"});case"eee":return n.day(s,{width:"abbreviated",context:"formatting"});case"eeeee":return n.day(s,{width:"narrow",context:"formatting"});case"eeeeee":return n.day(s,{width:"short",context:"formatting"});case"eeee":default:return n.day(s,{width:"wide",context:"formatting"})}},c:function(e,t,n,r){const s=e.getDay(),i=(s-r.weekStartsOn+8)%7||7;switch(t){case"c":return String(i);case"cc":return ve(i,t.length);case"co":return n.ordinalNumber(i,{unit:"day"});case"ccc":return n.day(s,{width:"abbreviated",context:"standalone"});case"ccccc":return n.day(s,{width:"narrow",context:"standalone"});case"cccccc":return n.day(s,{width:"short",context:"standalone"});case"cccc":default:return n.day(s,{width:"wide",context:"standalone"})}},i:function(e,t,n){const r=e.getDay(),s=r===0?7:r;switch(t){case"i":return String(s);case"ii":return ve(s,t.length);case"io":return n.ordinalNumber(s,{unit:"day"});case"iii":return n.day(r,{width:"abbreviated",context:"formatting"});case"iiiii":return n.day(r,{width:"narrow",context:"formatting"});case"iiiiii":return n.day(r,{width:"short",context:"formatting"});case"iiii":default:return n.day(r,{width:"wide",context:"formatting"})}},a:function(e,t,n){const s=e.getHours()/12>=1?"pm":"am";switch(t){case"a":case"aa":return n.dayPeriod(s,{width:"abbreviated",context:"formatting"});case"aaa":return n.dayPeriod(s,{width:"abbreviated",context:"formatting"}).toLowerCase();case"aaaaa":return n.dayPeriod(s,{width:"narrow",context:"formatting"});case"aaaa":default:return n.dayPeriod(s,{width:"wide",context:"formatting"})}},b:function(e,t,n){const r=e.getHours();let s;switch(r===12?s=$i.noon:r===0?s=$i.midnight:s=r/12>
vendor: 4,693 bytes, line 192
192=1?"pm":"am",t){case"b":case"bb":return n.dayPeriod(s,{width:"abbreviated",context:"formatting"});case"bbb":return n.dayPeriod(s,{width:"abbreviated",context:"formatting"}).toLowerCase();case"bbbbb":return n.dayPeriod(s,{width:"narrow",context:"formatting"});case"bbbb":default:return n.dayPeriod(s,{width:"wide",context:"formatting"})}},B:function(e,t,n){const r=e.getHours();let s;switch(r>=17?s=$i.evening:r>=12?s=$i.afternoon:r>=4?s=$i.morning:s=$i.night,t){case"B":case"BB":case"BBB":return n.dayPeriod(s,{width:"abbreviated",context:"formatting"});case"BBBBB":return n.dayPeriod(s,{width:"narrow",context:"formatting"});case"BBBB":default:return n.dayPeriod(s,{width:"wide",context:"formatting"})}},h:function(e,t,n){if(t==="ho"){let r=e.getHours()%12;return r===0&&(r=12),n.ordinalNumber(r,{unit:"hour"})}return Br.h(e,t)},H:function(e,t,n){return t==="Ho"?n.ordinalNumber(e.getHours(),{unit:"hour"}):Br.H(e,t)},K:function(e,t,n){const r=e.getHours()%12;return t==="Ko"?n.ordinalNumber(r,{unit:"hour"}):ve(r,t.length)},k:function(e,t,n){let r=e.getHours();return r===0&&(r=24),t==="ko"?n.ordinalNumber(r,{unit:"hour"}):ve(r,t.length)},m:function(e,t,n){return t==="mo"?n.ordinalNumber(e.getMinutes(),{unit:"minute"}):Br.m(e,t)},s:function(e,t,n){return t==="so"?n.ordinalNumber(e.getSeconds(),{unit:"second"}):Br.s(e,t)},S:function(e,t){return Br.S(e,t)},X:function(e,t,n){const r=e.getTimezoneOffset();if(r===0)return"Z";switch(t){case"X":return Mw(r);case"XXXX":case"XX":return Ws(r);case"XXXXX":case"XXX":default:return Ws(r,":")}},x:function(e,t,n){const r=e.getTimezoneOffset();switch(t){case"x":return Mw(r);case"xxxx":case"xx":return Ws(r);case"xxxxx":case"xxx":default:return Ws(r,":")}},O:function(e,t,n){const r=e.getTimezoneOffset();switch(t){case"O":case"OO":case"OOO":return"GMT"+Ow(r,":");case"OOOO":default:return"GMT"+Ws(r,":")}},z:function(e,t,n){const r=e.getTimezoneOffset();switch(t){case"z":case"zz":case"zzz":return"GMT"+Ow(r,":");case"zzzz":default:return"GMT"+Ws(r,":")}},t:function(e,t,n){const r=Math.trunc(e.getTime()/1e3);return ve(r,t.length)},T:function(e,t,n){const r=e.getTime();return ve(r,t.length)}};function Ow(e,t=""){const n=e>0?"-":"+",r=Math.abs(e),s=Math.trunc(r/60),i=r%60;return i===0?n+String(s):n+String(s)+t+ve(i,2)}function Mw(e,t){return e%60===0?(e>0?"-":"+")+ve(Math.abs(e)/60,2):Ws(e,t)}function Ws(e,t=""){const n=e>0?"-":"+",r=Math.abs(e),s=ve(Math.trunc(r/60),2),i=ve(r%60,2);return n+s+t+i}const Dw=(e,t)=>{switch(e){case"P":return t.date({width:"short"});case"PP":return t.date({width:"medium"});case"PPP":return t.date({width:"long"});case"PPPP":default:return t.date({width:"full"})}},LE=(e,t)=>{switch(e){case"p":return t.time({width:"short"});case"pp":return t.time({width:"medium"});case"ppp":return t.time({width:"long"});case"pppp":default:return t.time({width:"full"})}},D3=(e,t)=>{const n=e.match(/(P+)(p+)?/)||[],r=n[1],s=n[2];if(!s)return Dw(e,t);let i;switch(r){case"P":i=t.dateTime({width:"short"});break;case"PP":i=t.dateTime({width:"medium"});break;case"PPP":i=t.dateTime({width:"long"});break;case"PPPP":default:i=t.dateTime({width:"full"});break}return i.replace("{{date}}",Dw(r,t)).replace("{{time}}",LE(s,t))},I3={p:LE,P:D3},L3=/^D+$/,F3=/^Y+$/,$3=["D","DD","YY","YYYY"];function B3(e){return L3.test(e)}function V3(e){return F3.test(e)}function U3(e,t,n){const r=z3(e,t,n);if(console.warn(r),$3.includes(e))throw new RangeError(r)}function z3(e,t,n){const r=e[0]==="Y"?"years":"days of the month";return`Use \`${e.toLowerCase()}\` instead of \`${e}\` (in \`${t}\`) for formatting ${r} to the input \`${n}\`; see: https://github.com/date-fns/date-fns/blob/master/docs/unicodeTokens.md`}const W3=/[yYQqMLwIdDecihHKkms]o|(\w)\1*|''|'(''|[^'])+('|$)|./g,H3=/P+p+|P+|p+|''|'(''|[^'])+('|$)|./g,K3=/^'([^]*?)'?$/,q3=/''/g,Y3=/[a-zA-Z]/;function vt(e,t,n){var u,d,h,p,b,g,x,y;const r=Jl(),s=(n==null?void 0:n.locale)??r.locale??OE,i=(n==null?void 0:n.firstWeekContainsDate)??((d=(u=n==null?void 0:n.locale)==null?void 0:u.options)==null?void 0:d.firstWeekContainsDate)??r.firstWeekContainsDate??((p=(h=r.locale)==null?void 0:h.options)==null?void 0:p.firstWeekContainsDate)??1,o=(n==null?void 0:n.weekStartsOn)??((g=(b=n==null?void 0:n.locale)==null?void 0:b.options)==null?void 0:g.weekStartsOn)??r.weekStartsOn??((y=(x=r.locale)==null?void 0:x.options)==null?void 0:y.weekStartsOn)??0,a=he(e);if(!X4(a))throw new RangeError("Invalid time value");let l=t.match(H3).map(m=>{const v=m[0];if(v==="p"||v==="P"){const _=I3[v];return _(m,s.formatLong)}return m}).join("").match(W3).map(m=>{if(m==="''")return{isToken:!1,value:"'"};const v=m[0];if(v==="'")return{isToken:!1,value:G3(m)};if(Rw[v])return{isToken:!0,value:m};
192if(v.match(Y3))throw new RangeError("Format string contains an unescaped latin alphabet character `"+v+"`");return{isToken:!1,value:m}});s.localize.preprocessor&&(l=s.localize.preprocessor(a,l));const c={firstWeekContainsDate:i,weekStartsOn:o,locale:s};return l.map(m=>{if(!m.isToken)return m.value;const v=m.value;(!(n!=null&&n.useAdditionalWeekYearTokens)&&V3(v)||!(n!=null&&n.useAdditionalDayOfYearTokens)&&B3(v))&&U3(v,t,String(e));const _=Rw[v[0]];return _(a,v,s.localize,c)}).join("")}function G3(e){const t=e.match(K3);return t?t[1].replace(q3,"'"):e}function Q3(e){const t=he(e),n=t.getFullYear(),r=t.getMonth(),s=Wt(e,0);return s.setFullYear(n,r+1,0),s.setHours(0,0,0,0),s.getDate()}function Z3(e){return Math.trunc(+he(e)/1e3)}function J3(e){const t=he(e),n=t.getMonth();return t.setFullYear(t.getFullYear(),n+1,0),t.setHours(0,0,0,0),t}function X3(e,t){return e3(J3(e),Rt(e),t)+1}function mm(e,t){const n=he(e),r=he(t);return n.getTime()>r.getTime()}function FE(e,t){const n=he(e),r=he(t);return+n<+r}function xv(e,t){const n=he(e),r=he(t);return n.getFullYear()===r.getFullYear()&&n.getMonth()===r.getMonth()}function eF(e,t){const n=he(e),r=he(t);return n.getFullYear()===r.getFullYear()}function fh(e,t){return mt(e,-t)}function hh(e,t){const n=he(e),r=n.getFullYear(),s=n.getDate(),i=Wt(e,0);i.setFullYear(r,t,15),i.setHours(0,0,0,0);const o=Q3(i);return n.setMonth(t,Math.min(s,o)),n}function Iw(e,t){const n=he(e);return isNaN(+n)?Wt(e,NaN):(n.setFullYear(t),n)}var ee=function(){return ee=Object.assign||function(t){for(var n,r=1,s=arguments.length;r<s;r++){n=arguments[r];for(var i in n)Object.prototype.hasOwnProperty.call(n,i)&&(t[i]=n[i])}return t},ee.apply(this,arguments)};function tF(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 $E(e,t,n){for(var r=0,s=t.length,i;r<s;r++)(i||!(r in t))&&(i||(i=Array.prototype.slice.call(t,0,r)),i[r]=t[r]);return e.concat(i||Array.prototype.slice.call(t))}function Xl(e){return e.mode==="multiple"}function ec(e){return e.mode==="range"}function rf(e){return e.mode==="single"}var nF={root:"rdp",multiple_months:"rdp-multiple_months",with_weeknumber:"rdp-with_weeknumber",vhidden:"rdp-vhidden",button_reset:"rdp-button_reset",button:"rdp-button",caption:"rdp-caption",caption_start:"rdp-caption_start",caption_end:"rdp-caption_end",caption_between:"rdp-caption_between",caption_label:"rdp-caption_label",caption_dropdowns:"rdp-caption_dropdowns",dropdown:"rdp-dropdown",dropdown_month:"rdp-dropdown_month",dropdown_year:"rdp-dropdown_year",dropdown_icon:"rdp-dropdown_icon",months:"rdp-months",month:"rdp-month",table:"rdp-table",tbody:"rdp-tbody",tfoot:"rdp-tfoot",head:"rdp-head",head_row:"rdp-head_row",head_cell:"rdp-head_cell",nav:"rdp-nav",nav_button:"rdp-nav_button",nav_button_previous:"rdp-nav_button_previous",nav_button_next:"rdp-nav_button_next",nav_icon:"rdp-nav_icon",row:"rdp-row",weeknumber:"rdp-weeknumber",cell:"rdp-cell",day:"rdp-day",day_today:"rdp-day_today",day_outside:"rdp-day_outside",day_selected:"rdp-day_selected",day_disabled:"rdp-day_disabled",day_hidden:"rdp-day_hidden",day_range_start:"rdp-day_range_start",day_range_end:"rdp-day_range_end",day_range_middle:"rdp-day_range_middle"};function rF(e,t){return vt(e,"LLLL y",t)}function sF(e,t){return vt(e,"d",t)}function iF(e,t){return vt(e,"LLLL",t)}function oF(e){return"".concat(e)}function aF(e,t){return vt(e,"cccccc",t)}function lF(e,t){return vt(e,"yyyy",t)}var cF=Object.freeze({__proto__:null,formatCaption:rF,formatDay:sF,formatMonthCaption:iF,formatWeekNumber:oF,formatWeekdayName:aF,formatYearCaption:lF}),uF=function(e,t,n){return vt(e,"do MMMM (EEEE)",n)},dF=function(){return"Month: "},fF=function(){return"Go to next month"},hF=function(){return"Go to previous month"},pF=function(e,t){return vt(e,"cccc",t)},mF=function(e){return"Week n. ".concat(e)},gF=function(){return"Year: "},vF=Object.freeze({__proto__:null,labelDay:uF,labelMonthDropdown:dF,labelNext:fF,labelPrevious:hF,labelWeekNumber:mF,labelWeekday:pF,labelYearDropdown:gF});function yF(){var e="buttons",t=nF,n=OE,r={},s={},i=1,o={},a=new Date;return{captionLayout:e,classNames:t,formatters:cF,labels:vF,locale:n,modifiersClassNames:r,modifiers:s,numberOfMonths:i,styles:o,today:a,mode:"default"}}function wF(e){var t=e.fromYear,n=e.toYear,r=e.fromMonth,s=e.toMonth,i=e.fromDate,o=e.toDate;return r?i=Rt(r):t&&(i=new Date(t,0,1)),s?o=yv(s):n&&(o=new Date(n,11,31)),{fromDate:i?Bo(i):void 0,toDate:o?Bo(o):void 0}}var BE=w.createContext(void 0);function xF(e){var t,n=e.initialProps,r=yF(),s=wF(n),i=s.fromDate,o=s.toDate,a=(t=n.captionLayout)!==null&&t!==void 0?t:r.captionLayout;a!=="buttons"&&(!i||!o)&&(a="buttons");var l;(rf(n)||Xl(n)||ec(n))&&(l=n.onSelect);var c=ee(ee(ee({},r),n),{captionLayout:a,classNames:ee(ee({},r.classNames),n.classNames),components:ee({},n.components),formatters:ee(ee({},r.formatters),n.formatters),fromDate:i,labels:ee(ee({},r.labels),n.labels),mode:n.mode||r.mode,modifiers:ee(ee({},r.modifiers),n.modifiers),modifiersClassNames:ee(ee({},r.modifiersClassNames),n.modifiersClassNames),onSelect:l,styles:ee(ee({},r.styles),n.styles),toDate:o});return f.jsx(BE.Provider,{value:c,children:e.children})}function ke(){var e=w.useContext(BE);if(!e)throw new Error("useDayPicker must be used within a DayPickerProvider.");return e}function VE(e){var t=ke(),n=t.locale,r=t.classNames,s=t.styles,i=t.formatters.formatCaption;return f.jsx("div",{className:r.caption_label,style:s.caption_label,"aria-live":"polite",role:"presentation",id:e.id,children:i(e.displayMonth,{locale:n})})}function bF(e){return f.jsx("svg",ee({width:"8px",height:"8px",viewBox:"0 0 120 120","data-testid":"iconDropdown"},e,{children:f.jsx("path",{d:"M4.22182541,48.2218254 C8.44222828,44.0014225 15.2388494,43.9273804 19.5496459,47.9996989 L19.7781746,48.2218254 L60,88.443 L100.221825,48.2218254 C104.442228,44.0014225 111.238849,43.9273804 115.549646,47.9996989 L115.7
19278175,48.2218254 C119.998577,52.4422283 120.07262,59.2388494 116.000301,63.5496459 L115.778175,63.7781746 L67.7781746,111.778175 C63.5577717,115.998577 56.7611506,116.07262 52.4503541,112.000301 L52.2218254,111.778175 L4.22182541,63.7781746 C-0.0739418023,59.4824074 -0.0739418023,52.5175926 4.22182541,48.2218254 Z",fill:"currentColor",fillRule:"nonzero"})}))}function UE(e){var t,n,r=e.onChange,s=e.value,i=e.children,o=e.caption,a=e.className,l=e.style,c=ke(),u=(n=(t=c.components)===null||t===void 0?void 0:t.IconDropdown)!==null&&n!==void 0?n:bF;return f.jsxs("div",{className:a,style:l,children:[f.jsx("span",{className:c.classNames.vhidden,children:e["aria-label"]}),f.jsx("select",{name:e.name,"aria-label":e["aria-label"],className:c.classNames.dropdown,style:c.styles.dropdown,value:s,onChange:r,children:i}),f.jsxs("div",{className:c.classNames.caption_label,style:c.styles.caption_label,"aria-hidden":"true",children:[o,f.jsx(u,{className:c.classNames.dropdown_icon,style:c.styles.dropdown_icon})]})]})}function _F(e){var t,n=ke(),r=n.fromDate,s=n.toDate,i=n.styles,o=n.locale,a=n.formatters.formatMonthCaption,l=n.classNames,c=n.components,u=n.labels.labelMonthDropdown;if(!r)return f.jsx(f.Fragment,{});if(!s)return f.jsx(f.Fragment,{});var d=[];if(eF(r,s))for(var h=Rt(r),p=r.getMonth();p<=s.getMonth();p++)d.push(hh(h,p));else for(var h=Rt(new Date),p=0;p<=11;p++)d.push(hh(h,p));var b=function(x){var y=Number(x.target.value),m=hh(Rt(e.displayMonth),y);e.onChange(m)},g=(t=c==null?void 0:c.Dropdown)!==null&&t!==void 0?t:UE;return f.jsx(g,{name:"months","aria-label":u(),className:l.dropdown_month,style:i.dropdown_month,onChange:b,value:e.displayMonth.getMonth(),caption:a(e.displayMonth,{locale:o}),children:d.map(function(x){return f.jsx("option",{value:x.getMonth(),children:a(x,{locale:o})},x.getMonth())})})}function SF(e){var t,n=e.displayMonth,r=ke(),s=r.fromDate,i=r.toDate,o=r.locale,a=r.styles,l=r.classNames,c=r.components,u=r.formatters.formatYearCaption,d=r.labels.labelYearDropdown,h=[];if(!s)return f.jsx(f.Fragment,{});if(!i)return f.jsx(f.Fragment,{});for(var p=s.getFullYear(),b=i.getFullYear(),g=p;g<=b;g++)h.push(Iw(NE(new Date),g));var x=function(m){var v=Iw(Rt(n),Number(m.target.value));e.onChange(v)},y=(t=c==null?void 0:c.Dropdown)!==null&&t!==void 0?t:UE;return f.jsx(y,{name:"years","aria-label":d(),className:l.dropdown_year,style:a.dropdown_year,onChange:x,value:n.getFullYear(),caption:u(n,{locale:o}),children:h.map(function(m){return f.jsx("option",{value:m.getFullYear(),children:u(m,{locale:o})},m.getFullYear())})})}function kF(e,t){var n=w.useState(e),r=n[0],s=n[1],i=t===void 0?r:t;return[i,s]}function EF(e){var t=e.month,n=e.defaultMonth,r=e.today,s=t||n||r||new Date,i=e.toDate,o=e.fromDate,a=e.numberOfMonths,l=a===void 0?1:a;if(i&&El(i,s)<0){var c=-1*(l-1);s=Dn(i,c)}return o&&El(s,o)<0&&(s=o),Rt(s)}function CF(){var e=ke(),t=EF(e),n=kF(t,e.month),r=n[0],s=n[1],i=function(o){var a;if(!e.disableNavigation){var l=Rt(o);s(l),(a=e.onMonthChange)===null||a===void 0||a.call(e,l)}};return[r,i]}function TF(e,t){for(var n=t.reverseMonths,r=t.numberOfMonths,s=Rt(e),i=Rt(Dn(s,r)),o=El(i,s),a=[],l=0;l<o;l++){var c=Dn(s,l);a.push(c)}return n&&(a=a.reverse()),a}function AF(e,t){if(!t.disableNavigation){var n=t.toDate,r=t.pagedNavigation,s=t.numberOfMonths,i=s===void 0?1:s,o=r?i:1,a=Rt(e);if(!n)return Dn(a,o);var l=El(n,e);if(!(l<i))return Dn(a,o)}}function PF(e,t){if(!t.disableNavigation){var n=t.fromDate,r=t.pagedNavigation,s=t.numberOfMonths,i=s===void 0?1:s,o=r?i:1,a=Rt(e);if(!n)return Dn(a,-o);var l=El(a,n);if(!(l<=0))return Dn(a,-o)}}var zE=w.createContext(void 0);function jF(e){var t=ke(),n=CF(),r=n[0],s=n[1],i=TF(r,t),o=AF(r,t),a=PF(r,t),l=function(d){return i.some(function(h){return xv(d,h)})},c=function(d,h){l(d)||(h&&FE(d,h)?s(Dn(d,1+t.numberOfMonths*-1)):s(d))},u={currentMonth:r,displayMonths:i,goToMonth:s,goToDate:c,previousMonth:a,nextMonth:o,isDateDisplayed:l};return f.jsx(zE.Provider,{value:u,children:e.children})}function tc(){var e=w.useContext(zE);if(!e)throw new Error("useNavigation must be used within a NavigationProvider");return e}function Lw(e){var t,n=ke(),r=n.classNames,s=n.styles,i=n.components,o=tc().goToMonth,a=function(u){o(Dn(u,e.displayIndex?-e.dis
192playIndex:0))},l=(t=i==null?void 0:i.CaptionLabel)!==null&&t!==void 0?t:VE,c=f.jsx(l,{id:e.id,displayMonth:e.displayMonth});return f.jsxs("div",{className:r.caption_dropdowns,style:s.caption_dropdowns,children:[f.jsx("div",{className:r.vhidden,children:c}),f.jsx(_F,{onChange:a,displayMonth:e.displayMonth}),f.jsx(SF,{onChange:a,displayMonth:e.displayMonth})]})}function NF(e){return f.jsx("svg",ee({width:"16px",height:"16px",viewBox:"0 0 120 120"},e,{children:f.jsx("path",{d:"M69.490332,3.34314575 C72.6145263,0.218951416 77.6798462,0.218951416 80.8040405,3.34314575 C83.8617626,6.40086786 83.9268205,11.3179931 80.9992143,14.4548388 L80.8040405,14.6568542 L35.461,60 L80.8040405,105.343146 C83.8617626,108.400868 83.9268205,113.317993 80.9992143,116.454839 L80.8040405,116.656854 C77.7463184,119.714576 72.8291931,119.779634 69.6923475,116.852028 L69.490332,116.656854 L18.490332,65.6568542 C15.4326099,62.5991321 15.367552,57.6820069 18.2951583,54.5451612 L18.490332,54.3431458 L69.490332,3.34314575 Z",fill:"currentColor",fillRule:"nonzero"})}))}function RF(e){return f.jsx("svg",ee({width:"16px",height:"16px",viewBox:"0 0 120 120"},e,{children:f.jsx("path",{d:"M49.8040405,3.34314575 C46.6798462,0.218951416 41.6145263,0.218951416 38.490332,3.34314575 C35.4326099,6.40086786 35.367552,11.3179931 38.2951583,14.4548388 L38.490332,14.6568542 L83.8333725,60 L38.490332,105.343146 C35.4326099,108.400868 35.367552,113.317993 38.2951583,116.454839 L38.490332,116.656854 C41.5480541,119.714576 46.4651794,119.779634 49.602025,116.852028 L49.8040405,116.656854 L100.804041,65.6568542 C103.861763,62.5991321 103.926821,57.6820069 100.999214,54.5451612 L100.804041,54.3431458 L49.8040405,3.34314575 Z",fill:"currentColor"})}))}var od=w.forwardRef(function(e,t){var n=ke(),r=n.classNames,s=n.styles,i=[r.button_reset,r.button];e.className&&i.push(e.className);var o=i.join(" "),a=ee(ee({},s.button_reset),s.button);return e.style&&Object.assign(a,e.style),f.jsx("button",ee({},e,{ref:t,type:"button",className:o,style:a}))});function OF(e){var t,n,r=ke(),s=r.dir,i=r.locale,o=r.classNames,a=r.styles,l=r.labels,c=l.labelPrevious,u=l.labelNext,d=r.components;if(!e.nextMonth&&!e.previousMonth)return f.jsx(f.Fragment,{});var h=c(e.previousMonth,{locale:i}),p=[o.nav_button,o.nav_button_previous].join(" "),b=u(e.nextMonth,{locale:i}),g=[o.nav_button,o.nav_button_next].join(" "),x=(t=d==null?void 0:d.IconRight)!==null&&t!==void 0?t:RF,y=(n=d==null?void 0:d.IconLeft)!==null&&n!==void 0?n:NF;return f.jsxs("div",{className:o.nav,style:a.nav,children:[!e.hidePrevious&&f.jsx(od,{name:"previous-month","aria-label":h,className:p,style:a.nav_button_previous,disabled:!e.previousMonth,onClick:e.onPreviousClick,children:s==="rtl"?f.jsx(x,{className:o.nav_icon,style:a.nav_icon}):f.jsx(y,{className:o.nav_icon,style:a.nav_icon})}),!e.hideNext&&f.jsx(od,{name:"next-month","aria-label":b,className:g,style:a.nav_button_next,disabled:!e.nextMonth,onClick:e.onNextClick,children:s==="rtl"?f.jsx(y,{className:o.nav_icon,style:a.nav_icon}):f.jsx(x,{className:o.nav_icon,style:a.nav_icon})})]})}function Fw(e){var t=ke().numberOfMonths,n=tc(),r=n.previousMonth,s=n.nextMonth,i=n.goToMonth,o=n.displayMonths,a=o.findIndex(function(b){return xv(e.displayMonth,b)}),l=a===0,c=a===o.length-1,u=t>1&&(l||!c),d=t>1&&(c||!l),h=function(){r&&i(r)},p=function(){s&&i(s)};return f.jsx(OF,{displayMonth:e.displayMonth,hideNext:u,hidePrevious:d,nextMonth:s,previousMonth:r,onPreviousClick:h,onNextClick:p})}function MF(e){var t,n=ke(),r=n.classNames,s=n.disableNavigation,i=n.styles,o=n.captionLayout,a=n.components,l=(t=a==null?void 0:a.CaptionLabel)!==null&&t!==void 0?t:VE,c;return s?c=f.jsx(l,{id:e.id,displayMonth:e.displayMonth}):o==="dropdown"?c=f.jsx(Lw,{displayMonth:e.displayMonth,id:e.id}):o==="dropdown-buttons"?c=f.jsxs(f.Fragment,{children:[f.jsx(Lw,{displayMonth:e.displayMonth,displayIndex:e.displayIndex,id:e.id}),f.jsx(Fw,{displayMonth:e.displayMonth,displayIndex:e.displayIndex,id:e.id})]}):c=f.jsxs(f.Fragment,{children:[f.jsx(l,{id:e.id,displayMonth:e.displayMonth,displayIndex:e.displayIndex}),f.jsx(Fw,{displayMonth:e.displayMonth,id:e.id})]}),f.jsx("div",{className:r.caption,style:i.caption,children:c})}function DF(e){var t=ke(),n=t.footer,r=t.styles,s=t.classNames.tfoot;return n?f.jsx("tfoot",{className:s,style:r.tfoot,children:f.jsx("tr",{children:f.jsx("td",{colSpan:8,children:n})})}):f.jsx(f.Fragment,{})}function IF(e,t,n){for(var r=n?yi(new Date):cr(new Date,{locale:e,weekStartsOn:t}),s=[],i=0;i<7;i++){var o=mt(r,i);s.push(o)}return s}function LF(){var e=ke(),t=e.classNames,n=e.styles,r=e.showWeekNumber,s=e.locale,i=e.weekStartsOn,o=e.ISOWeek,a=e.formatters.formatWeekdayName,l=e.labels.labelWeekday,c=IF(s,i,o);return f.jsxs("tr",{style:n.head_row,className:t.head_row,children:[r&&f.jsx("td",{style:n.head_cell,className:t.head_cell}),c.map(function(u,d){return f.jsx("th",{scope:"col",className:t.head_cell,style:n.head_cell,"aria-label":l(u,{locale:s}),children:a(u,{locale:s})},d)})]})}function FF(){var e,t=ke(),n=t.classNames,r=t.styles,s=t.components,i=(e=s==null?void 0:s.HeadRow)!==null&&e!==void 0?e:LF;return f.jsx("thead",{style:r.head,className:n.head,children:f.jsx(i,{})})}function $F(e){var t=ke(),n=t.locale,r=t.formatters.formatDay;return f.jsx(f.Fragment,{children:r(e.date,{locale:n})})}var bv=w.createContext(void 0);function BF(e){if(!Xl(e.initialProps)){var t={selected:void 0,modifiers:{disabled:[]}};return f.jsx(bv.Provider,{value:t,children:e.children})}return f.jsx(VF,{initialProps:e.initialProps,children:e.children})}function VF(e){var t=e.initialProps,n=e.children,r=t.selected,s=t.min,i=t.max,o=function(c,u,d){var h,p;(h=t.onDayClick)===null||h===void 0||h.call(t,c,u,d);var b=!!(u.selected&&s&&(r==null?void 0:r.length)===s);if(!b){var g=!!(!u.selected&&i&&(r==null?void 0:r.length)===i);if(!g){var x=r?$E([],r):[];if(u.selected){var y=x.findIndex(function(m){return At(c,m)});x.splice(y,1)}else x.push(c);(p=t.onSelect)===null||p===void 0||p.call(t,x,c,u,d)}}},a={disabled:[]};r&&a.disabled.push(function(c){var u=i&&r.length>i-1,d=r.some(function(h){return At(h,c)});return!!(u&&!d)});var l={selected:r,onDayClick:o,modifiers:a};return f.jsx(bv.Provider,{value:l,children:n})}function _v(){var e=w.useContext(bv);if(!e)throw new Error("useSelectMultiple must be used within a SelectMultipleProvider");return e}function UF(e,t){var n=t||{},r=n.from,s=n.to;return r&&s?At(s,e)&&At(r,e)?void 0:At(s,e)?{from:s,to:void 0}:At(r,e)?void 0:mm(r,e)?{from:e,to:s}:{from:r,to:e}:s?mm(e,s)?{from:s,to:e}:{from:e,to:s}:r?FE(e,r)?{from:e,to:r}:{from:r,to:e}:{from:e,to:void 0}}var Sv=w.createContext(void 0);function zF(e){if(!ec(e.initialProps)){var t={selected:void 0,modifiers:{range_start:[],range_end:[],range_middle:[],disabled:[]}};return f.jsx(Sv.Provider,{value:t,children:e.children})}return f.jsx(WF,{initialProps:e.initialProps,children:e.children})}function WF(e){var t=e.initialProps,n=e.children,r=t.selected,s=r||{},i=s.from,o=s.to,a=t.min,l=t.max,c=function(p,b,g){var x,y;(x=t.onDayClick)===null||x===void 0||x.call(t,p,b,g);var m=UF(p,r);(y=t.onSelect)===null||y===void 0||y.call(t,m,p,b,g)},u={range_start:[],range_end:[],range_middle:[],disabled:[]};if(i?(u.range_start=[i],o?(u.range_end=[o],At(i,o)||(u.range_middle=[{after:i,before:o}])):u.range_end=[i]):o&&(u.range_start=[o],u.range_end=[o]),a&&(i&&!o&&u.disabled.push({after:fh(i,a-1),before:mt(i,a-1)}),i&&o&&u.disabled.push({after:i,before:mt(i,a-1)}),!i&&o&&u.disabled.push({after:fh(o,a-1),before:mt(o,a-1)})),l){if(i&&!o&&(u.disabled.push({before:mt(i,-l+1)}),u.disabled.push({after:mt(i,l-1)})),i&&o){var d=er(o,i)+1,h=l-d;u.disabled.push({before:fh(i,h)}),u.disabled.push({after:mt(o,h)})}!i&&o&&(u.disabled.push({before:mt(o,-l+1)}),u.disabled.push({after:mt(o,l-1)}))}return f.jsx(Sv.Provider,{value:{selected:r,onDayClick:c,modifiers:u},children:n})}function kv(){var e=w.useContext(Sv);if(!e)throw new Error("useSelectRange must be used within a SelectRangeProvider");return e}function fu(e){return Array.isArray(e)?$E([],e):e!==void 0?[e]:[]}function HF(e){var t={};return Object.entries(e).forEach(function(n){var r=n[0],s=n[1];t[r]=fu(s)}),t}var In;(function(e){e.Outside="outside",e.Disabled="disabled",e.Selected="selected",e.Hidden="hidden",e.Today="today",e.RangeStart="range_start",e.RangeEnd="range_end",e.RangeMiddle="range_middle"})(In||(In={}));var KF=In.Selected,gr=In.Disabled,qF=In.Hidden,YF=In.Today,ph=In.RangeEnd,mh=In.RangeMiddle,gh=In.RangeStart,GF=In.Outside;function QF(e,t,n){var r,s=(r={},r[KF]=fu(e.selected),r[gr]=fu(e.disabled),r[qF]=fu(e.hidden),r[YF]=[e.today],r[ph]=[],r[mh]=[],r[gh]=[],r[GF]=[],r);return e.fromDate&&s[gr].push({before:e.fromDate}),e.toDate&&s[gr].push({after:e.toDate}),Xl(e)?s[gr]=s[gr].concat(t.modifiers[gr]):ec(e)&&(s[gr]=s[gr].concat(n.modifiers[gr]),s[gh]=n.modifiers[gh],s[mh]=n.modifiers[mh],s[ph]=n.modifiers[ph]),s}var WE=w.createContext(void 0);function ZF(e){var t=ke(),n=_v(),r=kv(),s=QF(t,n,r),i=HF(t.modifiers),o=ee(ee({},s),i);return f.jsx(WE.Provider,{value:o,children:e.children})}function HE(){var e=w.useContext(WE);if(!e)throw new Error("useModifiers must be used within a ModifiersProvider");return e}function JF(e){return!!(e&&typeof e=="object"&&"before"in e&&"after"in e)}function XF(e){return!!(e&&typeof e=="object"&&"from"in e)}function e$(e){return!!(e&&typeof e=="object"&&"after"in e)}function t$(e){return!!(e&&typeof e=="object"&&"before"in e)}function n$(e){return!!(e&&typeof e=="object"&&"dayOfWeek"in e)}function r$(e,t){var n,r=t.from,s=t.to;if(r&&s){var i=er(s,r)<0;i&&(n=[s,r],r=n[0],s=n[1]);var o=er(e,r)>=0&&er(s,e)>=0;return o}return s?At(s,e):r?At(r,e):!1}function s$(e){return vv(e)}function i$(e){return Array.isArray(e)&&e.every(vv)}function o$(e,t){return t.some(function(n){if(typeof n=="boolean")return n;if(s$(n))return At(e,n);if(i$(n))return n.includes(e);if(XF(n))return r$(e,n);if(n$(n))return n.dayOfWeek.includes(e.getDay());if(JF(n)){var r=er(n.before,e),s=er(n.after,e),i=r>0,o=s<0,a=mm(n.before,n.after);return a?o&&i:i||o}return e$(n)?er(e,n.after)>0:t$(n)?er(n.before,e)>0:typeof n=="function"?n(e):!1})}function Ev(e,t,n){var r=Object.keys(t).reduce(function(i,o){var a=t[o];return o$(e,a)&&i.push(o),i},[]),s={};return r.forEach(function(i){return s[i]=!0}),n&&!xv(e,n)&&(s.outside=!0),s}function a$(e,t){for(var n=Rt(e[0]),r=yv(e[e.length-1]),s,i,o=n;o<=r;){var a=Ev(o,t),l=!a.disabled&&!a.hidden;if(!l){o=mt(o,1);continue}if(a.selected)return o;a.today&&!i&&(i=o),s||(s=o),o=mt(o,1)}return i||s}var l$=365;function KE(e,t){var n=t.moveBy,r=t.direction,s=t.context,i=t.modifiers,o=t.retry,a=o===void 0?{count:0,lastFocused:e}:o,l=s.weekStartsOn,c=s.fromDate,u=s.toDate,d=s.locale,h={day:mt,week:pm,month:Dn,year:Q4,startOfWeek:function(x){return s.ISOWeek?yi(x):cr(x,{locale:d,weekStartsOn:l})},endOfWeek:function(x){return s.ISOWeek?RE(x):wv(x,{locale:d,weekStartsOn:l})}},p=h[n](e,r==="after"?1:-1);r==="before"&&c?p=Z4([c,p]):r==="after"&&u&&(p=J4([u,p]));var b=!0;if(i){var g=Ev(p,i);b=!g.disabled&&!g.hidden}return b?p:a.count>l$?a.lastFocused:KE(p,{moveBy:n,direction:r,context:s,modifiers:i,retry:ee(ee({},a),{count:a.count+1})})}var qE=w.createContext(void 0);function c$(e){var t=tc(),n=HE(),r=w.useState(),s=r[0],i=r[1],o=w.useState(),a=o[0],l=o[1],c=a$(t.displayMonths,n),u=s??(a&&t.isDateDisplayed(a))?a:c,d=function(){l(s),i(void 0)},h=function(x){i(x)},p=ke(),b=function(x,y){if(s){var m=KE(s,{moveBy:x,direction:y,context:p,modifiers:n});At(s,m)||(t.goToDate(m,s),h(m))}},g={focusedDay:s,focusTarget:u,blur:d,focus:h,focusDayAfter:function(){return b("day","after")},focusDayBefore:function(){return b("day","before")},focusWeekAfter:function(){return b("week","after")},focusWeekBefore:function(){return b("week","before")},focusMonthBefore:function(){return b("month","before")},focusMonthAfter:function(){return b("month","after")},focusYearBefore:function(){return b("year","before")},focusYearAfter:function(){return b("year","after")},focusStartOfWeek:function(){return b("startOfWeek","before")},focusEndOfWeek:function(){return b("endOfWeek","after")}};return f.jsx(qE.Provider,{value:g,children:e.children})}function Cv(){var e=w.useContext(qE);if(!e)throw new Error("useFocusContext must be used within a FocusProvider");return e}function u$(e,t){var n=HE(),r=Ev(e,n,t);return r}var Tv=w.createContext(void 0);function d$(e){if(!rf(e.initialProps)){var t={selected:void 0};return f.jsx(Tv.Provider,{value:t,children:e.children})}return f.jsx(f$,{initialProps:e.initialProps,children:e.children})}function f$(e){var t=e.initialProps,n=e.children,r=function(i,o,a){var l,c,u;if((l=t.onDayClick)===null||l===void 0||l.call(t,i,o,a),o.selected&&!t.required){(c=t.onSelect)===null||c===void 0||c.c
192all(t,void 0,i,o,a);return}(u=t.onSelect)===null||u===void 0||u.call(t,i,i,o,a)},s={selected:t.selected,onDayClick:r};return f.jsx(Tv.Provider,{value:s,children:n})}function YE(){var e=w.useContext(Tv);if(!e)throw new Error("useSelectSingle must be used within a SelectSingleProvider");return e}function h$(e,t){var n=ke(),r=YE(),s=_v(),i=kv(),o=Cv(),a=o.focusDayAfter,l=o.focusDayBefore,c=o.focusWeekAfter,u=o.focusWeekBefore,d=o.blur,h=o.focus,p=o.focusMonthBefore,b=o.focusMonthAfter,g=o.focusYearBefore,x=o.focusYearAfter,y=o.focusStartOfWeek,m=o.focusEndOfWeek,v=function(O){var C,j,$,Q;rf(n)?(C=r.onDayClick)===null||C===void 0||C.call(r,e,t,O):Xl(n)?(j=s.onDayClick)===null||j===void 0||j.call(s,e,t,O):ec(n)?($=i.onDayClick)===null||$===void 0||$.call(i,e,t,O):(Q=n.onDayClick)===null||Q===void 0||Q.call(n,e,t,O)},_=function(O){var C;h(e),(C=n.onDayFocus)===null||C===void 0||C.call(n,e,t,O)},S=function(O){var C;d(),(C=n.onDayBlur)===null||C===void 0||C.call(n,e,t,O)},k=function(O){var C;(C=n.onDayMouseEnter)===null||C===void 0||C.call(n,e,t,O)},E=function(O){var C;(C=n.onDayMouseLeave)===null||C===void 0||C.call(n,e,t,O)},T=function(O){var C;(C=n.onDayPointerEnter)===null||C===void 0||C.call(n,e,t,O)},P=function(O){var C;(C=n.onDayPointerLeave)===null||C===void 0||C.call(n,e,t,O)},A=function(O){var C;(C=n.onDayTouchCancel)===null||C===void 0||C.call(n,e,t,O)},B=function(O){var C;(C=n.onDayTouchEnd)===null||C===void 0||C.call(n,e,t,O)},I=function(O){var C;(C=n.onDayTouchMove)===null||C===void 0||C.call(n,e,t,O)},Z=function(O){var C;(C=n.onDayTouchStart)===null||C===void 0||C.call(n,e,t,O)},R=function(O){var C;(C=n.onDayKeyUp)===null||C===void 0||C.call(n,e,t,O)},U=function(O){var C;switch(O.key){case"ArrowLeft":O.preventDefault(),O.stopPropagation(),n.dir==="rtl"?a():l();break;case"ArrowRight":O.preventDefault(),O.stopPropagation(),n.dir==="rtl"?l():a();break;case"ArrowDown":O.preventDefault(),O.stopPropagation(),c();break;case"ArrowUp":O.preventDefault(),O.stopPropagation(),u();break;case"PageUp":O.preventDefault(),O.stopPropagation(),O.shiftKey?g():p();break;case"PageDown":O.preventDefault(),O.stopPropagation(),O.shiftKey?x():b();break;case"Home":O.preventDefault(),O.stopPropagation(),y();break;case"End":O.preventDefault(),O.stopPropagation(),m();break}(C=n.onDayKeyDown)===null||C===void 0||C.call(n,e,t,O)},V={onClick:v,onFocus:_,onBlur:S,onKeyDown:U,onKeyUp:R,onMouseEnter:k,onMouseLeave:E,onPointerEnter:T,onPointerLeave:P,onTouchCancel:A,onTouchEnd:B,onTouchMove:I,onTouchStart:Z};return V}function p$(){var e=ke(),t=YE(),n=_v(),r=kv(),s=rf(e)?t.selected:Xl(e)?n.selected:ec(e)?r.selected:void 0;return s}function m$(e){return Object.values(In).includes(e)}function g$(e,t){var n=[e.classNames.day];return Object.keys(t).forEach(function(r){var s=e.modifiersClassNames[r];if(s)n.push(s);else if(m$(r)){var i=e.classNames["day_".concat(r)];i&&n.push(i)}}),n}function v$(e,t){var n=ee({},e.styles.day);return Object.keys(t).forEach(function(r){var s;n=ee(ee({},n),(s=e.modifiersStyles)===null||s===void 0?void 0:s[r])}),n}function y$(e,t,n){var r,s,i,o=ke(),a=Cv(),l=u$(e,t),c=h$(e,l),u=p$(),d=!!(o.onDayCl
192ick||o.mode!=="default");w.useEffect(function(){var k;l.outside||a.focusedDay&&d&&At(a.focusedDay,e)&&((k=n.current)===null||k===void 0||k.focus())},[a.focusedDay,e,n,d,l.outside]);var h=g$(o,l).join(" "),p=v$(o,l),b=!!(l.outside&&!o.showOutsideDays||l.hidden),g=(i=(s=o.components)===null||s===void 0?void 0:s.DayContent)!==null&&i!==void 0?i:$F,x=f.jsx(g,{date:e,displayMonth:t,activeModifiers:l}),y={style:p,className:h,children:x,role:"gridcell"},m=a.focusTarget&&At(a.focusTarget,e)&&!l.outside,v=a.focusedDay&&At(a.focusedDay,e),_=ee(ee(ee({},y),(r={disabled:l.disabled,role:"gridcell"},r["aria-selected"]=l.selected,r.tabIndex=v||m?0:-1,r)),c),S={isButton:d,isHidden:b,activeModifiers:l,selectedDays:u,buttonProps:_,divProps:y};return S}function w$(e){var t=w.useRef(null),n=y$(e.date,e.displayMonth,t);return n.isHidden?f.jsx("div",{role:"gridcell"}):n.isButton?f.jsx(od,ee({name:"day",ref:t},n.buttonProps)):f.jsx("div",ee({},n.divProps))}function x$(e){var t=e.number,n=e.dates,r=ke(),s=r.onWeekNumberClick,i=r.styles,o=r.classNames,a=r.locale,l=r.labels.labelWeekNumber,c=r.formatters.formatWeekNumber,u=c(Number(t),{locale:a});if(!s)return f.jsx("span",{className:o.weeknumber,style:i.weeknumber,children:u});var d=l(Number(t),{locale:a}),h=function(p){s(t,n,p)};return f.jsx(od,{name:"week-number","aria-label":d,className:o.weeknumber,style:i.weeknumber,onClick:h,children:u})}function b$(e){var t,n,r=ke(),s=r.styles,i=r.classNames,o=r.showWeekNumber,a=r.components,l=(t=a==null?void 0:a.Day)!==null&&t!==void 0?t:w$,c=(n=a==null?void 0:a.WeekNumber)!==null&&n!==void 0?n:x$,u;return o&&(u=f.jsx("td",{className:i.cell,style:s.cell,children:f.jsx(c,{number:e.weekNumber,dates:e.dates})})),f.jsxs("tr",{className:i.row,style:s.row,children:[u,e.dates.map(function(d){return f.jsx("td",{className:i.cell,style:s.cell,role:"presentation",children:f.jsx(l,{displayMonth:e.displayMonth,date:d})},Z3(d))})]})}function $w(e,t,n){for(var r=n!=null&&n.ISOWeek?RE(t):wv(t,n),s=n!=null&&n.ISOWeek?yi(e):cr(e,n),i=er(r,s),o=[],a=0;a<=i;a++)o.push(mt(s,a));var l=o.reduce(function(c,u){var d=n!=null&&n.ISOWeek?ME(u):IE(u,n),h=c.find(function(p){return p.weekNumber===d});return h?(h.dates.push(u),c):(c.push({weekNumber:d,dates:[u]}),c)},[]);return l}function _$(e,t){var n=$w(Rt(e),yv(e),t);if(t!=null&&t.useFixedWeeks){var r=X3(e,t);if(r<6){var s=n[n.length-1],i=s.dates[s.dates.length-1],o=pm(i,6-r),a=$w(pm(i,1),o,t);n.push.apply(n,a)}}return n}function S$(e){var t,n,r,s=ke(),i=s.locale,o=s.classNames,a=s.styles,l=s.hideHead,c=s.fixedWeeks,u=s.components,d=s.weekStartsOn,h=s.firstWeekContainsDate,p=s.ISOWeek,b=_$(e.displayMonth,{useFixedWeeks:!!c,ISOWeek:p,locale:i,weekStartsOn:d,firstWeekContainsDate:h}),g=(t=u==null?void 0:u.Head)!==null&&t!==void 0?t:FF,x=(n=u==null?void 0:u.Row)!==null&&n!==void 0?n:b$,y=(r=u==null?void 0:u.Footer)!==null&&r!==void 0?r:DF;return f.jsxs("table",{id:e.id,className:o.table,style:a.table,role:"grid","aria-labelledby":e["aria-labelledby"],children:[!l&&f.jsx(g,{}),f.jsx("tbody",{className:o.tbody,style:a.tbody,children:b.map(function(m){return f.jsx(x,{displayMonth:e.displayMonth,dates:m.dates,weekNumber:m.weekNumber},m.weekNumber)})}),f.jsx(y,{displayMonth:e.displayMonth})]})}function k$(){return!!(typeof window<"u"&&window.document&&window.document.createElement)}var E$=k$()?w.useLayoutEffect:w.useEffect,vh=!1,C$=0;function Bw(){return"react-day-picker-".concat(++C$)}function T$(e){var t,n=e??(vh?Bw():null),r=w.useState(n),s=r[0],i=r[1];return E$(function(){s===null&&i(Bw())},[]),w.useEffect(function(){vh===!1&&(vh=!0)},[]),(t=e??s)!==null&&t!==void 0?t:void 0}function A$(e){var t,n,r=ke(),s=r.dir,i=r.classNames,o=r.styles,a=r.components,l=tc().displayMonths,c=T$(r.id?"".concat(r.id,"-").concat(e.displayIndex):void 0),u=r.id?"".concat(r.id,"-grid-").concat(e.displayIndex):void 0,d=[i.month],h=o.month,p=e.displayIndex===0,b=e.displayIndex===l.length-1,g=!p&&!b;s==="rtl"&&(t=[p,b],b=t[0],p=t[1]),p&&(d.push(i.caption_start),h=ee(ee({},h),o.caption_start)),b&&(d.push(i.caption_end),h=ee(ee({},h),o.caption_end)),g&&(d.push(i.caption_between),h=ee(ee({},h),o.caption_between));var x=(n=a==null?void 0:a.Caption)!==null&&n!==void 0?n:MF;return f.jsxs("div",{className:d.join(" "),style:h,children:[f.jsx(x,{id:c,displayMonth:e.displayMonth,displayIndex:e.displayIndex}),f.jsx(S$,{id:u,"aria-labelledby":c,displayMonth:e.displayMonth})]},e.displayIndex)}function P$(e){var t=ke(),n=t.classNames,r=t.styles;return f.jsx("div",{className:n.months,style:r.months,children:e.children})}function j$(e){var t,n,r=e.initialProps,s=ke(),i=Cv(),o=tc(),a=w.useState(!1),l=a[0],c=a[1];w.useEffect(function(){s.initialFocus&&i.focusTarget&&(l||(i.focus(i.focusTarget),c(!0)))},[s.initialFocus,l,i.focus,i.focusTarget,i]);var u=[s.classNames.root,s.className];s.numberOfMonths>1&&u.push(s.classNames.multiple_months),s.showWeekNumber&&u.push(s.classNames.with_weeknumber);var d=ee(ee({},s.styles.root),s.style),h=Object.keys(r).filter(function(b){return b.startsWith("data-")}).reduce(function(b,g){var x;return ee(ee({},b),(x={},x[g]=r[g],x))},{}),p=(n=(t=r.components)===null||t===void 0?void 0:t.Months)!==null&&n!==void 0?n:P$;return f.jsx("div",ee({className:u.join(" "),style:d,dir:s.dir,id:s.id,nonce:r.nonce,title:r.title,lang:r.lang},h,{children:f.jsx(p,{children:o.displayMonths.map(function(b,g){return f.jsx(A$,{displayIndex:g,displayMonth:b},g)})})}))}function N$(e){var t=e.children,n=tF(e,["children"]);
vendor: 5,243 bytes, line 192
192return f.jsx(xF,{initialProps:n,children:f.jsx(jF,{children:f.jsx(d$,{initialProps:n,children:f.jsx(BF,{initialProps:n,children:f.jsx(zF,{initialProps:n,children:f.jsx(ZF,{children:f.jsx(c$,{children:t})})})})})})})}function R$(e){return f.jsx(N$,ee({},e,{children:f.jsx(j$,{initialProps:e})}))}const gm=dk("inline-flex items-center justify-center gap-2 whitespace-nowrap rounded-md text-sm font-medium ring-offset-background transition-colors focus-visible:outline-none focus-visible:ring-2 focus-visible:ring-ring focus-visible:ring-offset-2 disabled:pointer-events-none disabled:opacity-50 [&_svg]:pointer-events-none [&_svg]:size-4 [&_svg]:shrink-0",{variants:{variant:{default:"bg-primary text-primary-foreground hover:bg-primary/90",destructive:"bg-destructive text-destructive-foreground hover:bg-destructive/90",outline:"border border-input bg-background hover:bg-accent hover:text-accent-foreground",secondary:"bg-secondary text-secondary-foreground hover:bg-secondary/80",ghost:"hover:bg-accent hover:text-accent-foreground",link:"text-primary underline-offset-4 hover:underline"},size:{default:"h-10 px-4 py-2",sm:"h-9 rounded-md px-3",lg:"h-11 rounded-md px-8",icon:"h-10 w-10"}},defaultVariants:{variant:"default",size:"default"}}),ad=w.forwardRef(({className:e,variant:t,size:n,asChild:r=!1,...s},i)=>{const o=r?eO:"button";return f.jsx(o,{className:Te(gm({variant:t,size:n,className:e})),ref:i,...s})});ad.displayName="Button";function wi({className:e,classNames:t,showOutsideDays:n=!0,...r}){return f.jsx(R$,{showOutsideDays:n,className:Te("p-3",e),classNames:{months:"flex flex-col sm:flex-row space-y-4 sm:space-x-4 sm:space-y-0",month:"space-y-4",caption:"flex justify-center pt-1 relative items-center",caption_label:"text-sm font-medium",nav:"space-x-1 flex items-center",nav_button:Te(gm({variant:"outline"}),"h-7 w-7 bg-transparent p-0 opacity-50 hover:opacity-100 rounded-none"),nav_button_previous:"absolute left-1",nav_button_next:"absolute right-1",table:"w-full border-collapse space-y-1",head_row:"flex",head_cell:"text-muted-foreground w-9 font-normal text-[0.8rem]",row:"flex w-full mt-2",cell:"h-9 w-9 text-center text-sm p-0 relative [&:has([aria-selected].day-range-end)]:rounded-none [&:has([aria-selected].day-outside)]:bg-accent/50 [&:has([aria-selected])]:bg-accent first:[&:has([aria-selected])]:rounded-none last:[&:has([aria-selected])]:rounded-none focus-within:relative focus-within:z-20",day:Te(gm({variant:"ghost"}),"h-9 w-9 p-0 font-normal aria-selected:opacity-100 rounded-none"),day_range_end:"day-range-end",day_selected:"bg-primary !text-white hover:bg-primary hover:!text-white focus:bg-primary focus:!text-white",day_today:"border border-black aria-selected:!bg-primary aria-selected:!text-white bg-transparent",day_outside:"day-outside text-muted-foreground opacity-50 aria-selected:bg-accent/50 aria-selected:text-muted-foreground aria-selected:opacity-30",day_disabled:"text-muted-foreground opacity-50",day_range_middle:"aria-selected:bg-accent aria-selected:text-accent-foreground",day_hidden:"invisible",...t},components:{IconLeft:({...s})=>f.jsx(GO,{className:"h-4 w-4"}),IconRight:({...s})=>f.jsx(QO,{className:"h-4 w-4"})},...r})}wi.displayName="Calendar";var yh=0;function O$(){w.useEffect(()=>{const e=document.querySelectorAll("[data-radix-focus-guard]");return document.body.insertAdjacentElement("afterbegin",e[0]??Vw()),document.body.insertAdjacentElement("beforeend",e[1]??Vw()),yh++,()=>{yh===1&&document.querySelectorAll("[data-radix-focus-guard]").forEach(t=>t.remove()),yh--}},[])}function Vw(){const e=document.createElement("span");return e.setAttribute("data-radix-focus-guard",""),e.tabIndex=0,e.style.outline="none",e.style.opacity="0",e.style.position="fixed",e.style.pointerEvents="none",e}var wh="focusScope.autoFocusOnMount",xh="focusScope.autoFocusOnUnmount",Uw={bubbles:!1,cancelable:!0},M$="FocusScope",GE=w.forwardRef((e,t)=>{const{loop:n=!1,trapped:r=!1,onMountAutoFocus:s,onUnmountAutoFocus:i,...o}=e,[a,l]=w.useState(null),c=or(s),u=or(i),d=w.useRef(null),h=Dt(t,g=>l(g)),p=w.useRef({paused:!1,pause(){this.paused=!0},resume(){this.paused=!1}}).current;w.useEffect(()=>{if(r){let g=function(v){if(p.paused||!a)return;const _=v.target;a.contains(_)?d.current=_:zr(d.current,{select:!0})},x=function(v){if(p.paused||!a)return;const _=v.relatedTarget;_!==null&&(a.contains(_)||zr(d.current,{select:!0}))},y=function(v){if(document.activeElement===document.body)for(const S of v)S.removedNodes.length>0&&zr(a)};document.addEventListener("focusin",g),document.addEventListener("focusout",x);const m=new MutationObserver(y);return a&&m.observe(a,{childList:!0,subtree:!0}),()=>{document.removeEventListener("focusin",g),document.removeEventListener("focusout",x),m.disconnect()}}},[r,a,p.paused]),w.useEffect(()=>{if(a){Ww.add(p);const g=document.activeElement;if(!a.contains(g)){const y=new CustomEvent(wh,Uw);a.addEventListener(wh,c),a.dispatchEvent(y),y.defaultPrevented||(D$(B$(QE(a)),{select:!0}),document.activeElement===g&&zr(a))}return()=>{a.removeEventListener(wh,c),setTimeout(()=>{const y=new CustomEvent(xh,Uw);a.addEventListener(xh,u),a.dispatchEvent(y),y.defaultPrevented||zr(g??document.body,{select:!0}),a.removeEventListener(xh,u),Ww.remove(p)}
vendor: 4,594 bytes, line 192
192,0)}}},[a,c,u,p]);const b=w.useCallback(g=>{if(!n&&!r||p.paused)return;const x=g.key==="Tab"&&!g.altKey&&!g.ctrlKey&&!g.metaKey,y=document.activeElement;if(x&&y){const m=g.currentTarget,[v,_]=I$(m);v&&_?!g.shiftKey&&y===_?(g.preventDefault(),n&&zr(v,{select:!0})):g.shiftKey&&y===v&&(g.preventDefault(),n&&zr(_,{select:!0})):y===m&&g.preventDefault()}},[n,r,p.paused]);return f.jsx(it.div,{tabIndex:-1,...o,ref:h,onKeyDown:b})});GE.displayName=M$;function D$(e,{select:t=!1}={}){const n=document.activeElement;for(const r of e)if(zr(r,{select:t}),document.activeElement!==n)return}function I$(e){const t=QE(e),n=zw(t,e),r=zw(t.reverse(),e);return[n,r]}function QE(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 zw(e,t){for(const n of e)if(!L$(n,{upTo:t}))return n}function L$(e,{upTo:t}){if(getComputedStyle(e).visibility==="hidden")return!0;for(;e;){if(t!==void 0&&e===t)return!1;if(getComputedStyle(e).display==="none")return!0;e=e.parentElement}return!1}function F$(e){return e instanceof HTMLInputElement&&"select"in e}function zr(e,{select:t=!1}={}){if(e&&e.focus){const n=document.activeElement;e.focus({preventScroll:!0}),e!==n&&F$(e)&&t&&e.select()}}var Ww=$$();function $$(){let e=[];return{add(t){const n=e[0];t!==n&&(n==null||n.pause()),e=Hw(e,t),e.unshift(t)},remove(t){var n;e=Hw(e,t),(n=e[0])==null||n.resume()}}}function Hw(e,t){const n=[...e],r=n.indexOf(t);return r!==-1&&n.splice(r,1),n}function B$(e){return e.filter(t=>t.tagName!=="A")}var V$=function(e){if(typeof document>"u")return null;var t=Array.isArray(e)?e[0]:e;return t.ownerDocument.body},Bi=new WeakMap,Lc=new WeakMap,Fc={},bh=0,ZE=function(e){return e&&(e.host||ZE(e.parentNode))},U$=function(e,t){return t.map(function(n){if(e.contains(n))return n;var r=ZE(n);return r&&e.contains(r)?r:(console.error("aria-hidden",n,"in not contained inside",e,". Doing nothing"),null)}).filter(function(n){return!!n})},z$=function(e,t,n,r){var s=U$(t,Array.isArray(e)?e:[e]);Fc[n]||(Fc[n]=new WeakMap);var i=Fc[n],o=[],a=new Set,l=new Set(s),c=function(d){!d||a.has(d)||(a.add(d),c(d.parentNode))};s.forEach(c);var u=function(d){!d||l.has(d)||Array.prototype.forEach.call(d.children,function(h){if(a.has(h))u(h);else try{var p=h.getAttribute(r),b=p!==null&&p!=="false",g=(Bi.get(h)||0)+1,x=(i.get(h)||0)+1;Bi.set(h,g),i.set(h,x),o.push(h),g===1&&b&&Lc.set(h,!0),x===1&&h.setAttribute(n,"true"),b||h.setAttribute(r,"true")}catch(y){console.error("aria-hidden: cannot operate on ",h,y)}})};return u(t),a.clear(),bh++,function(){o.forEach(function(d){var h=Bi.get(d)-1,p=i.get(d)-1;Bi.set(d,h),i.set(d,p),h||(Lc.has(d)||d.removeAttribute(r),Lc.delete(d)),p||d.removeAttribute(n)}),bh--,bh||(Bi=new WeakMap,Bi=new WeakMap,Lc=new WeakMap,Fc={})}},W$=function(e,t,n){n===void 0&&(n="data-aria-hidden");var r=Array.from(Array.isArray(e)?e:[e]),s=V$(e);return s?(r.push.apply(r,Array.from(s.querySelectorAll("[aria-live]"))),z$(r,s,n,"aria-hidden")):function(){return null}},Jn=function(){return Jn=Object.assign||function(t){for(var n,r=1,s=arguments.length;r<s;r++){n=arguments[r];for(var i in n)Object.prototype.hasOwnProperty.call(n,i)&&(t[i]=n[i])}return t},Jn.apply(this,arguments)};function JE(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 H$(e,t,n){if(n||arguments.length===2)for(var r=0,s=t.length,i;r<s;r++)(i||!(r in t))&&(i||(i=Array.prototype.slice.call(t,0,r)),i[r]=t[r]);return e.concat(i||Array.prototype.slice.call(t))}var hu="right-scroll-bar-position",pu="width-before-scroll-bar",K$="with-scroll-bars-hidden",q$="--removed-body-scroll-bar-size";function _h(e,t){return typeof e=="function"?e(t):e&&(e.current=t),e}function Y$(e,t){var n=w.useState(function(){return{value:e,callback:t,facade:{get current(){return n.value},set current(r){var s=n.value;s!==r&&(n.value=r,n.callback(r,s))}}}})[0];return n.callback=t,n.facade}var G$=typeof window<"u"?w.useLayoutEffect:w.useEffect,Kw=new WeakMap;function Q$(e,t){var n=Y$(null,function(r){return e.forEach(function(s){return _h(s,r)})});return G$(function(){var r=Kw.get(n);if(r){var s=new Set(r),i=new Set(e),o=n.current;
vendor: 4,196 bytes, lines 192-207
192s.forEach(function(a){i.has(a)||_h(a,null)}),i.forEach(function(a){s.has(a)||_h(a,o)})}Kw.set(n,e)},[e]),n}function Z$(e){return e}function J$(e,t){t===void 0&&(t=Z$);var n=[],r=!1,s={read:function(){if(r)throw new Error("Sidecar: could not `read` from an `assigned` medium. `read` could be used only with `useMedium`.");return n.length?n[n.length-1]:e},useMedium:function(i){var o=t(i,r);return n.push(o),function(){n=n.filter(function(a){return a!==o})}},assignSyncMedium:function(i){for(r=!0;n.length;){var o=n;n=[],o.forEach(i)}n={push:function(a){return i(a)},filter:function(){return n}}},assignMedium:function(i){r=!0;var o=[];if(n.length){var a=n;n=[],a.forEach(i),o=n}var l=function(){var u=o;o=[],u.forEach(i)},c=function(){return Promise.resolve().then(l)};c(),n={push:function(u){o.push(u),c()},filter:function(u){return o=o.filter(u),n}}}};return s}function X$(e){e===void 0&&(e={});var t=J$(null);return t.options=Jn({async:!0,ssr:!1},e),t}var XE=function(e){var t=e.sideCar,n=JE(e,["sideCar"]);if(!t)throw new Error("Sidecar: please provide `sideCar` property to import the right car");var r=t.read();if(!r)throw new Error("Sidecar medium not found");return w.createElement(r,Jn({},n))};XE.isSideCarExport=!0;function e5(e,t){return e.useMedium(t),XE}var eC=X$(),Sh=function(){},sf=w.forwardRef(function(e,t){var n=w.useRef(null),r=w.useState({onScrollCapture:Sh,onWheelCapture:Sh,onTouchMoveCapture:Sh}),s=r[0],i=r[1],o=e.forwardProps,a=e.children,l=e.className,c=e.removeScrollBar,u=e.enabled,d=e.shards,h=e.sideCar,p=e.noRelative,b=e.noIsolation,g=e.inert,x=e.allowPinchZoom,y=e.as,m=y===void 0?"div":y,v=e.gapMode,_=JE(e,["forwardProps","children","className","removeScrollBar","enabled","shards","sideCar","noRelative","noIsolation","inert","allowPinchZoom","as","gapMode"]),S=h,k=Q$([n,t]),E=Jn(Jn({},_),s);return w.createElement(w.Fragment,null,u&&w.createElement(S,{sideCar:eC,removeScrollBar:c,shards:d,noRelative:p,noIsolation:b,inert:g,setCallbacks:i,allowPinchZoom:!!x,lockRef:n,gapMode:v}),o?w.cloneElement(w.Children.only(a),Jn(Jn({},E),{ref:k})):w.createElement(m,Jn({},E,{className:l,ref:k}),a))});sf.defaultProps={enabled:!0,removeScrollBar:!0,inert:!1};sf.classNames={fullWidth:pu,zeroRight:hu};var t5=function(){if(typeof __webpack_nonce__<"u")return __webpack_nonce__};function n5(){if(!document)return null;var e=document.createElement("style");e.type="text/css";var t=t5();return t&&e.setAttribute("nonce",t),e}function r5(e,t){e.styleSheet?e.styleSheet.cssText=t:e.appendChild(document.createTextNode(t))}function s5(e){var t=document.head||document.getElementsByTagName("head")[0];t.appendChild(e)}var i5=function(){var e=0,t=null;return{add:function(n){e==0&&(t=n5())&&(r5(t,n),s5(t)),e++},remove:function(){e--,!e&&t&&(t.parentNode&&t.parentNode.removeChild(t),t=null)}}},o5=function(){var e=i5();return function(t,n){w.useEffect(function(){return e.add(t),function(){e.remove()}},[t&&n])}},tC=function(){var e=o5(),t=function(n){var r=n.styles,s=n.dynamic;return e(r,s),null};return t},a5={left:0,top:0,right:0,gap:0},kh=function(e){return parseInt(e||"",10)||0},l5=function(e){var t=window.getComputedStyle(document.body),n=t[e==="padding"?"paddingLeft":"marginLeft"],r=t[e==="padding"?"paddingTop":"marginTop"],s=t[e==="padding"?"paddingRight":"marginRight"];return[kh(n),kh(r),kh(s)]},c5=function(e){if(e===void 0&&(e="margin"),typeof window>"u")return a5;var t=l5(e),n=document.documentElement.clientWidth,r=window.innerWidth;return{left:t[0],top:t[1],right:t[2],gap:Math.max(0,r-n+t[2]-t[0])}},u5=tC(),bo="data-scroll-locked",d5=function(e,t,n,r){var s=e.left,i=e.top,o=e.right,a=e.gap;return n===void 0&&(n="margin"),`
193  .`.concat(K$,` {
194   overflow: hidden `).concat(r,`;
195   padding-right: `).concat(a,"px ").concat(r,`;
196  }
197  body[`).concat(bo,`] {
198    overflow: hidden `).concat(r,`;
199    overscroll-behavior: contain;
200    `).concat([t&&"position: relative ".concat(r,";"),n==="margin"&&`
201    padding-left: `.concat(s,`px;
202    padding-top: `).concat(i,`px;
203    padding-right: `).concat(o,`px;
204    margin-left:0;
205    margin-top:0;
206    margin-right: `).concat(a,"px ").concat(r,`;
207    `),n==="padding"&&"padding-right: ".concat(a,"px ").concat(r,";
207")].filter(Boolean).join(""),`
208  }
209  
210  .`).concat(hu,` {
211    right: `).concat(a,"px ").concat(r,`;
212  }
213  
214  .`).concat(pu,` {
215    margin-right: `).concat(a,"px ").concat(r,`;
216  }
217  
218  .`).concat(hu," .").concat(hu,` {
219    right: 0 `).concat(r,`;
220  }
221  
222  .`).concat(pu," .").concat(pu,` {
223    margin-right: 0 `).concat(r,`;
224  }
225  
226  body[`).concat(bo,`] {
227    `).concat(q$,": ").concat(a,`px;
228  }
229`)},qw=function(){var e=parseInt(document.body.getAttribute(bo)||"0",10);return isFinite(e)?e:0},f5=function(){w.useEffect(function(){return document.body.setAttribute(bo,(qw()+1).toString()),function(){var e=qw()-1;e<=0?document.body.removeAttribute(bo):document.body.setAttribute(bo,e.toString())}},[])},h5=function(e){var t=e.noRelative,n=e.noImportant,r=e.gapMode,s=r===void 0?"margin":r;f5();var i=w.useMemo(function(){return c5(s)},[s]);return w.createElement(u5,{styles:d5(i,!t,s,n?"":"!important")})},vm=!1;if(typeof window<"u")try{var $c=Object.defineProperty({},"passive",{get:function(){return vm=!0,!0}});window.addEventListener("test",$c,$c),window.removeEventListener("test",$c,$c)}catch{vm=!1}var Vi=vm?{passive:!1}:!1,p5=function(e){return e.tagName==="TEXTAREA"},nC=function(e,t){if(!(e instanceof Element))return!1;var n=window.getComputedStyle(e);return n[t]!=="hidden"&&!(n.overflowY===n.overflowX&&!p5(e)&&n[t]==="visible")},m5=function(e){return nC(e,"overflowY")},g5=function(e){return nC(e,"overflowX")},Yw=function(e,t){var n=t.ownerDocument,r=t;do{typeof ShadowRoot<"u"&&r instanceof ShadowRoot&&(r=r.host);var s=rC(e,r);if(s){var i=sC(e,r),o=i[1],a=i[2];if(o>a)return!0}r=r.parentNode}while(r&&r!==n.body);return!1},v5=function(e){var t=e.scrollTop,n=e.scrollHeight,r=e.clientHeight;return[t,n,r]},y5=function(e){var t=e.scrollLeft,n=e.scrollWidth,r=e.clientWidth;return[t,n,r]},rC=function(e,t){return e==="v"?m5(t):g5(t)},sC=function(e,t){return e==="v"?v5(t):y5(t)},w5=function(e,t){return e==="h"&&t==="rtl"?-1:1},x5=function(e,t,n,r,s){var i=w5(e,window.getComputedStyle(t).direction),o=i*r,a=n.target,l=t.contains(a),c=!1,u=o>0,d=0,h=0;do{if(!a)break;var p=sC(e,a),b=p[0],g=p[1],x=p[2],y=g-x-i*b;(b||y)&&rC(e,a)&&(d+=y,h+=b);var m=a.parentNode;a=m&&m.nodeType===Node.DOCUMENT_FRAGMENT_NODE?m.host:m}while(!l&&a!==document.body||l&&(t.contains(a)||t===a));return(u&&(Math.abs(d)<1||!s)||!u&&(Math.abs(h)<1||!s))&&(c=!0),c},Bc=function(e){return"changedTouches"in e?[e.changedTouches[0].clientX,e.changedTouches[0].clientY]:[0,0]},Gw=function(e){return[e.deltaX,e.deltaY]},Qw=function(e){return e&&"current"in e?e.current:e},b5=function(e,t){return e[0]===t[0]&&e[1]===t[1]},_5=function(e){return`
230  .block-interactivity-`.concat(e,` {pointer-events: none;}
231  .allow-interactivity-`).concat(e,` {pointer-events: all;}
232`)},S5=0,Ui=[];function k5(e){var t=w.useRef([]),n=w.useRef([0,0]),r=w.useRef(),s=w.useState(S5++)[0],i=w.useState(tC)[0],o=w.useRef(e);w.useEffect(function(){o.current=e},[e]),w.useEffect(function(){if(e.inert){document.body.classList.add("block-interactivity-".concat(s));var g=H$([e.lockRef.current],(e.shards||[]).map(Qw),!0).filter(Boolean);return g.forEach(function(x){return x.classList.add("allow-interactivity-".concat(s))}),function(){document.body.classList.remove("block-interactivity-".concat(s)),g.forEach(function(x){return x.classList.remove("allow-interactivity-".concat(s))})}}},[e.inert,e.lockRef.current,e.shards]);var a=w.useCallback(function(g,x){if("touches"in g&&g.touches.length===2||g.type==="wheel"&&g.ctrlKey)return!o.current.allowPinchZoom;var y=Bc(g),m=n.current,v="deltaX"in g?g.deltaX:m[0]-y[0],_="deltaY"in g?g.deltaY:m[1]-y[1],S,k=g.target,E=Math.abs(v)>Math.abs(_)?"h":"v";if("touches"in g&&E==="h"&&k.type==="range")return!1;var T=Yw(E,k);if(!T)return!0;if(T?S=E:(S=E==="v"?"h":"v",T=Yw(E,k)),!T)return!1;if(!r.current&&"changedTouches"in g&&(v||_)&&(r.current=S),!S)return!0;var P=r.current||S;return x5(P,x,g,P==="h"?v:_,!0)},[]),l=w.useCallback(function(g){var x=g;if(!(!Ui.length||Ui[Ui.length-1]!==i)){var y="deltaY"in x?Gw(x):Bc(x),m=t.current.filter(function(S){return S.name===x.type&&(S.target===x.target||x.target===S.shadowParent)&&b5(S.delta,y)})[0];if(m&&m.should){x.cancelable&&x.preventDefault();return}
vendor: 4,641 bytes, line 232
232if(!m){var v=(o.current.shards||[]).map(Qw).filter(Boolean).filter(function(S){return S.contains(x.target)}),_=v.length>0?a(x,v[0]):!o.current.noIsolation;_&&x.cancelable&&x.preventDefault()}}},[]),c=w.useCallback(function(g,x,y,m){var v={name:g,delta:x,target:y,should:m,shadowParent:E5(y)};t.current.push(v),setTimeout(function(){t.current=t.current.filter(function(_){return _!==v})},1)},[]),u=w.useCallback(function(g){n.current=Bc(g),r.current=void 0},[]),d=w.useCallback(function(g){c(g.type,Gw(g),g.target,a(g,e.lockRef.current))},[]),h=w.useCallback(function(g){c(g.type,Bc(g),g.target,a(g,e.lockRef.current))},[]);w.useEffect(function(){return Ui.push(i),e.setCallbacks({onScrollCapture:d,onWheelCapture:d,onTouchMoveCapture:h}),document.addEventListener("wheel",l,Vi),document.addEventListener("touchmove",l,Vi),document.addEventListener("touchstart",u,Vi),function(){Ui=Ui.filter(function(g){return g!==i}),document.removeEventListener("wheel",l,Vi),document.removeEventListener("touchmove",l,Vi),document.removeEventListener("touchstart",u,Vi)}},[]);var p=e.removeScrollBar,b=e.inert;return w.createElement(w.Fragment,null,b?w.createElement(i,{styles:_5(s)}):null,p?w.createElement(h5,{noRelative:e.noRelative,gapMode:e.gapMode}):null)}function E5(e){for(var t=null;e!==null;)e instanceof ShadowRoot&&(t=e.host,e=e.host),e=e.parentNode;return t}const C5=e5(eC,k5);var iC=w.forwardRef(function(e,t){return w.createElement(sf,Jn({},e,{ref:t,sideCar:C5}))});iC.classNames=sf.classNames;var of="Popover",[oC,CW]=Hl(of,[Yd]),nc=Yd(),[T5,Os]=oC(of),aC=e=>{const{__scopePopover:t,children:n,open:r,defaultOpen:s,onOpenChange:i,modal:o=!1}=e,a=nc(t),l=w.useRef(null),[c,u]=w.useState(!1),[d,h]=zS({prop:r,defaultProp:s??!1,onChange:i,caller:of});return f.jsx(ID,{...a,children:f.jsx(T5,{scope:t,contentId:gM(),triggerRef:l,open:d,onOpenChange:h,onOpenToggle:w.useCallback(()=>h(p=>!p),[h]),hasCustomAnchor:c,onCustomAnchorAdd:w.useCallback(()=>u(!0),[]),onCustomAnchorRemove:w.useCallback(()=>u(!1),[]),modal:o,children:n})})};aC.displayName=of;var lC="PopoverAnchor",A5=w.forwardRef((e,t)=>{const{__scopePopover:n,...r}=e,s=Os(lC,n),i=nc(n),{onCustomAnchorAdd:o,onCustomAnchorRemove:a}=s;return w.useEffect(()=>(o(),()=>a()),[o,a]),f.jsx(uv,{...i,...r,ref:t})});A5.displayName=lC;var cC="PopoverTrigger",uC=w.forwardRef((e,t)=>{const{__scopePopover:n,...r}=e,s=Os(cC,n),i=nc(n),o=Dt(t,s.triggerRef),a=f.jsx(it.button,{type:"button","aria-haspopup":"dialog","aria-expanded":s.open,"aria-controls":s.contentId,"data-state":mC(s.open),...r,ref:o,onClick:Oe(e.onClick,s.onOpenToggle)});return s.hasCustomAnchor?a:f.jsx(uv,{asChild:!0,...i,children:a})});uC.displayName=cC;var Av="PopoverPortal",[P5,j5]=oC(Av,{forceMount:void 0}),dC=e=>{const{__scopePopover:t,forceMount:n,children:r,container:s}=e,i=Os(Av,t);return f.jsx(P5,{scope:t,forceMount:n,children:f.jsx(Kl,{present:n||i.open,children:f.jsx(Gg,{asChild:!0,container:s,children:r})})})};dC.displayName=Av;var Vo="PopoverContent",fC=w.forwardRef((e,t)=>{const n=j5(Vo,e.__scopePopover),{forceMount:r=n.forceMount,...s}=e,i=Os(Vo,e.__scopePopover);return f.jsx(Kl,{present:r||i.open,children:i.modal?f.jsx(R5,{...s,ref:t}):f.jsx(O5,{...s,ref:t})})});fC.displayName=Vo;var N5=xl("PopoverContent.RemoveScroll"),R5=w.forwardRef((e,t)=>{const n=Os(Vo,e.__scopePopover),r=w.useRef(null),s=Dt(t,r),i=w.useRef(!1);return w.useEffect(()=>{const o=r.current;if(o)return W$(o)},[]),f.jsx(iC,{as:N5,allowPinchZoom:!0,children:f.jsx(hC,{...e,ref:s,trapFocus:n.open,disableOutsidePointerEvents:!0,onCloseAutoFocus:Oe(e.onCloseAutoFocus,o=>{var a;o.preventDefault(),i.current||(a=n.triggerRef.current)==null||a.focus()}),onPointerDownOutside:Oe(e.onPointerDownOutside,o=>{const a=o.detail.originalEvent,l=a.button===0&&a.ctrlKey===!0,c=a.button===2||l;i.current=c},{checkForDefaultPrevented:!1}),onFocusOutside:Oe(e.onFocusOutside,o=>o.preventDefault(),{checkForDefaultPrevented:!1})})})}),O5=w.forwardRef((e,t)=>{const n=Os(Vo,e.__scopePopover),r=w.useRef(!1),s=w.useRef(!1);return f.jsx(hC,{...e,ref:t,trapFocus:!1,disableOutsidePointerEvents:!1,onCloseAutoFocus:i=>{var o,a;(o=e.onCloseAutoFocus)==null||o.call(e,i),i.defaultPrevented||(r.current||(a=n.triggerRef.current)==null||a.focus(),i.preventDefault()),r.current=!1,s.current=!1},onInteractOutside:i=>{var l,c;(l=e.onInteractOutside)==null||l.call(e,i),i.defaultPrevented||(r.current=!0,i.detail.originalEvent.type==="pointerdown"&&(s.current=!0));const o=i.target;((c=n.triggerRef.current)==null?void 0:c.contains(o))&&i.preventDefault(),i.detail.originalEvent.type==="focusin"&&s.current&&i.preventDefault()}})}),hC=w.forwardRef((e,t)=>
232{const{__scopePopover:n,trapFocus:r,onOpenAutoFocus:s,onCloseAutoFocus:i,disableOutsidePointerEvents:o,onEscapeKeyDown:a,onPointerDownOutside:l,onFocusOutside:c,onInteractOutside:u,...d}=e,h=Os(Vo,n),p=nc(n);return O$(),f.jsx(GE,{asChild:!0,loop:!0,trapped:r,onMountAutoFocus:s,onUnmountAutoFocus:i,children:f.jsx(Ud,{asChild:!0,disableOutsidePointerEvents:o,onInteractOutside:u,onEscapeKeyDown:a,onPointerDownOutside:l,onFocusOutside:c,onDismiss:()=>h.onOpenChange(!1),children:f.jsx(qk,{"data-state":mC(h.open),role:"dialog",id:h.contentId,...p,...d,ref:t,style:{...d.style,"--radix-popover-content-transform-origin":"var(--radix-popper-transform-origin)","--radix-popover-content-available-width":"var(--radix-popper-available-width)","--radix-popover-content-available-height":"var(--radix-popper-available-height)","--radix-popover-trigger-width":"var(--radix-popper-anchor-width)","--radix-popover-trigger-height":"var(--radix-popper-anchor-height)"}})})})}),pC="PopoverClose",M5=w.forwardRef((e,t)=>{const{__scopePopover:n,...r}=e,s=Os(pC,n);return f.jsx(it.button,{type:"button",...r,ref:t,onClick:Oe(e.onClick,()=>s.onOpenChange(!1))})});M5.displayName=pC;var D5="PopoverArrow",I5=w.forwardRef((e,t)=>{const{__scopePopover:n,...r}=e,s=nc(n);return f.jsx(Yk,{...s,...r,ref:t})});I5.displayName=D5;function mC(e){return e?"open":"closed"}var L5=aC,F5=uC,$5=dC,gC=fC;const Cl=L5,Tl=F5,Uo=w.forwardRef(({className:e,align:t="center",sideOffset:n=4,...r},s)=>f.jsx($5,{children:f.jsx(gC,{ref:s,align:t,sideOffset:n,className:Te("z-50 w-72 rounded-md border bg-popover p-4 text-popover-foreground shadow-md outline-none data-[state=open]:animate-in data-[state=closed]:animate-out data-[state=closed]:fade-out-0 data-[state=open]:fade-in-0 data-[state=closed]:zoom-out-95 data-[state=open]:zoom-in-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),...r})}));Uo.displayName=gC.displayName;const B5="data:image/png;base64,iVBORw0KGgoAAAANSUhEUgAAAEQAAABSCAYAAADtnHI0AAAAAXNSR0IArs4c6QAAAERlWElmTU0AKgAAAAgAAYdpAAQAAAABAAAAGgAAAAAAA6ABAAMAAAABAAEAAKACAAQAAAABAAAARKADAAQAAAABAAAAUgAAAAAveaGdAAADoElEQVR4Ae1agVHjQAwE5gtICdcBlHAlUIKpADrAHeQ7eL6CfAdJB+QrsKkAOuB3Mz7mRkiOneRziSPNLHfSSSdpLQcYuL4qK3dI/6iU8KDYLsIU0eWngmLN3xTLfKKJnRDxYJwQJ0QwIFSfECdEMCBUnxAnRDAgVJ8QJ0QwIFSfECdEMCBUnxAnRDAgVJ8QJ0QwIFSfECdEMCBUnxAnRDAgVJ8QJ0QwIFSfECdEMCBUnxAnRDAgVJ8QJ0QwIFSfECdEMCBUnxAnRDAgVJ8QJ0QwIFSfECdEMCBUnxAnRDAgVJ8QJ0QwIFSfECdEMCDUH9BnwDvQdlhjfQO4roApCnu+63DbrbRtJOCr9v/mybbE+RPACw4tERemPPl66Dy8LwJz4BXIc+V7DsbGMTf27Rv4PwMBOIREXKLlO8TdvCMCJIGNank02yhC8gsWSBKBfSQiOL8z7fe5k7EVsATSfWPWq/sdA1OSBvEVsItEBKV78nWXuxhTAawnv2vU/hrBoQM/I7i/BbifAWNkBecHoAWGSoTjUnFmXWMkwvkXEIAx0sJ5DfwFuP8ATCEpFcBXYwzLc/gPJTMad8M8SAK8SOjQ+t7hS+IqYGiNcP0uDK6Aockb+JLQbRLhoDWzLY7njwAb1OJzG30WQAT+iwTc+gLkSa39M/z6JOJQi+2L4cOZG3H5XSSiBvaaBMQPlgDPFyAvQtuzeKuoaMTDrEqA9RXQ8iTb0YmQlbLIxZYi2YRGSjTiYP4mAZYGSI1r60+ca3lgPr5USMmnoxVKWwMEIJcIRfPPfbgPAOM1X9p4FoGTk4CK+gqXkxLhrzUJ85cE7Pru5HSezFR8VZ1tWBxHV2uUtmXmGw2/5BKw6SOjTo7nsLJYi5R510A0fLrj3m/zT8npnNYaxVqk3OMsGucwb36JtGIrOpyrWK8PP4BJitZ0MOz0rYGzlyU60BpvRtrrs2eiayBgtZrXiNJsjJ+URHSjNTrExtcrAJMT/swwhADpU0+Oia6hgJVPWzbcpzdd7GSXeiQh1WSZ6BqbYR06JZOfjvSwh36WVClg6mtEg32fG+ksTJ2IvL9tr82f3PlY+5tjJVLy/FZsuakIIXkBx95bv8dc5OtC8vndJjUv1+bYTyflK/nKfKCINhUiVv7hqIiUJIQNr42uLbvhfjhzaULejFYulpDWIISvUxEpPSFW420RNpC0NCHFGrcIL02IVVcxovhPdyWFr8yqZAEy9z/pEicRvbF87wAAAABJRU5ErkJggg==",V5=()=>{const[e,t]=w.useState([]),n=Fn();if(w.useEffect(()=>{(async()=>{const{data:i,error:o}=await X.from("events").select("id, title, background_image_url, address, date, time").order("target_date",{ascending:!1}).limit(10);i&&!o&&t(i)})()},[]),e.length===0)return null;const r=[...e,...e];return f.jsx("div",{className:"w-full overflow-hidden py-12 pb-20 md:pb-24 bg-background",children:f.jsx("div",{className:"relative overflow-hidden",children:f.jsx("div",{className:"flex gap-px w-max animate-scroll-left-fast will-change-[transform]",children:r.map((s,i)=>f.jsxs("div",{onClick:o=>{o.stopPropagation(),n(`/event/${s.id}`)},className:"relative flex-shrink-0 w-[65vw] md:w-[calc(40vw-0.5px)] aspect-[4/5] max-h-[800px] cursor-pointer overflow-hidden animate-fade-in",style:{animationDelay:`${i*.1}s`,animationFillMode:"both"},children:[f.jsx("img",{src:s.background_image_url,alt:s.title,className:"w-full h-full object-cover",loading:"lazy"}),f.jsx("div",{className:"absolute inset-0 bg-gradient-to-t from-black/50 via-black/10 to-transparent"}),f.jsxs("div",{className:"absolute top-4 left-4 flex flex-col gap-0",children:[f.jsx("div",{className:"bg-white border border-black px-3 h-[23px] flex items-center",children:f.jsx("div",{className:"text-[11px] font-medium uppercase leading-none",children:s.date})}),f.jsx("div",{className:"bg-white border border-t-0 border-black px-3 h-[23px] flex items-center",children:f.jsx("div",{className:"text-[11px] font-medium uppercase leading-none",children:s.time})})]}),f.jsxs("div",{className:"absolute bottom-0 left-0 right-0 p-6 md:p-8 text-white",children:[f.jsx("h3",{className:"text-xl md:text-2xl font-medium mb-1 tracking-tight",children:s.title}),f.jsx("p",{className:"text-sm md:text-base text-white/80",children:s.address})]})]},`${s.id}-${i}`))})})})},U5=({event:e})=>{const t=Fn(),r=(()=>{const s=new Date().getTime(),i=new Date(e.target_date).getTime(),o=1e3*60*60;return s>=i&&s<=i+o})();return f.jsxs("div",{className:"relative cursor-pointer group",onClick:()=>t(`/event/${e.id}`),children:[f.jsx("div",{className:"overflow-hidden mb-3",children:f.jsx("div",{className:"aspect-square bg-gray-300 bg-cover bg-center transition-transform duration-500 ease-out group-hover:scale-110",style:{backgroundImage:`url(${e.background_image_url})`}})}),f.jsxs("div",{className:"absolute top-4 left-4 flex flex-col gap-0",children:[f.jsx("div",{className:"bg-white border border-black px-3 h-[23px] flex items-center",children:f.jsx("div",{className:"text-[11px] font-medium uppercase leading-none",children:e.date})}),f.jsx("div",{className:"bg-white border border-t-0 border-black px-3 h-[23px] flex items-center",children:f.jsx("div",{className:"text-[11px] font-medium leading-none",children:e.time})}),r&&f.jsx("div",{className:"bg-white border border-t-0 border-black px-3 h-[23px] flex items-center",children:f.jsx("div",{className:"text-[11px] font-medium uppercase leading-none",children:"LIVE NOW"})})]}),f.jsx("h3",{className:"text-lg font-medium",children:e.title}),f.jsx("p",{className:"text-sm text-gray-500 mt-1",children:e.address})]})},z5=()=>{const[e,t]=w.useState(void 0),[n,r]=w.useState([]),[s,i]=w.useState(!0),[o,a]=w.useState("the world"),[l,c]=w.useState(!1);w.useEffect(()=>{d(),u()},[]),w.useEffect(()=>{if(!l&&n.length>0){const b=new Date,g=b.getTime(),x=1e3*60*60;n.some(m=>{const v=new Date(m.target_date);return v.getTime()<g-x?!1:v.getFullYear()===b.getFullYear()&&v.getMonth()===b.getMonth()&&v.getDate()===b.getDate()})&&t(b),c(!0)}},[n,l]);const u=async()=>{try{const x=(await(await fetch("https://www.cloudflare.com/cdn-cgi/trace")).text()).match(/loc=([A-Z]{2})/);if(x&&x[1]){const y=x[1];a({US:"United States",GB:"United Kingdom",CA:"Canada",AU:"Australia",DE:"Germany",FR:"France",IT:"Italy",ES:"Spain",NL:"Netherlands",BE:"Belgium",SE:"Sweden",NO:"Norway",DK:"Denmark",FI:"Finland",PL:"Poland",CH:"Switzerland",AT:"Austria",IE:"Ireland",PT:"Portugal",IN:"India",JP:"Japan",CN:"China",KR:"South Korea",BR:"Brazil",MX:"Mexico",AR:"Argentina",CL:"Chile",CO:"Colombia",SG:"Singapore",NZ:"New Zealand",ZA:"South Africa",RU:"Russia",TR:"Turkey",GR:"Greece"}[y]||y)}}catch{a("the world")}},d=async()=>{try{const{data:b,error:g}=await X.from("events").select("id, title, date, time, background_image_url, target_date, address").order("target_date",{ascending:!0});if(g)throw g;r(b||[])}catch{}finally{i(!1)}},h=n.filter(b=>{const g=new Date().getTime(),x=new Date(b.target_date).getTime(),y=1e3*60*60;if(x<g-y)return!1;if(!e)return!0;const v=new Date(b.target_date),_=new Date(e);return v.getFullYear()===_.getFullYear()&&v.getMonth()===_.getMonth()&&v.getDate()===_.getDate()}),p=()=>{const b=document.getElementById("events-section");b==null||b.scrollIntoView({behavior:"smooth"})};return f.jsxs("div",{className:"min-h-screen bg-white",children:[f.jsx(lr,{title:"Discover Events",description:"Explore popular events near you, browse by category, or check out some of the great community calendars.",keywords:"events, discover events, community events, local events, event calendar"}),f.jsx("div",{className:"animate-fade-in",style:{animationDelay:"0.1s",animationFillMode:"both"},children:f.jsx(vi,{})}),f.jsx(PE,{text:"BROWSE",onClick:p,showIcon:!0,icon:f.jsx("img",{src:B5,alt:"Arrow down",className:"w-6 h-6 md:w-7 md:h-7 lg:w-12 lg:h-12"})}),f.jsx("section",{className:"pt-32 md:pt-40 lg:pt-48 pb-6 md:pb-16 lg:pb-24 px-4 md:px-8",children:f.jsxs("div",{className:"max-w-4xl mx-auto text-center",children:[f.jsxs("h1",{className:"text-3xl sm:text-4xl md:text-5xl lg:text-6xl font-medium mb-6 md:mb-10 inline-flex flex-col items-center",style:{animationDelay:"0.3s",animationFillMode:"both"},children:[f.jsxs("div",{className:"flex items-center",children:[f.jsx("span",{className:"border border-black px-3 md:px-6 py-2 md:py-4 animate-fade-in",style:{animationDelay:"0.3s",animationFillMode:"both"},children:"Discover"}),f.jsx("span",{className:"bg-[#ff6bff] border border-black px-3 md:px-6 py-2 md:py-4 rounded-[20px] md:rounded-[40px] -ml-px animate-fade-in",style:{animationDelay:"0.4s",animationFillMode:"both"},children:"events"})]}),f.jsxs("div",{className:"flex items-center -mt-px",children:[f.jsx("span",{className:"border border-black px-3 md:px-6 py-2 md:py-4 animate-fade-in",style:{animationDelay:"0.5s",animationFillMode:"both"},children:"near"}),f.jsx("span",{className:"border border-l-0 border-black px-3 md:px-6 py-2 md:py-4 animate-fade-in",style:{animationDelay:"0.6s",animationFillMode:"both"},children:"you"})]})]}),f.jsx("p",{className:"text-sm md:text-base lg:text-[18px] text-black max-w-2xl mx-auto animate-fade-in",style:{animationDelay:"0.7s",animationFillMode:"both"},children:"Explore popular events near you, browse by category, or check out some of the great community calendars."})]})}),f.jsx(V5,{}),f.jsx("section",{id:"events-section",className:"px-4 md:px-8 pb-16 pt-6 md:pt-16",children:f.jsxs("div",{children:[f.jsxs("div",{className:"flex flex-wrap items-center gap-0 mb-6 md:mb-8 animate-fade-in",style:{animationDelay:"0.8s",animationFillMode:"both"},children:[f.jsx("h2",{className:"text-base md:text-lg lg:text-xl font-normal w-full sm:w-auto mb-2 sm:mb-0",children:"Browsing events in"}),f.jsx("span",{className:"text-base md:text-lg lg:text-xl font-normal border border-black px-2 py-1 sm:ml-2",children:o}),f.jsx("div",{className:"lg:hidden",children:f.jsxs(Cl,{children:[f.jsx(Tl,{asChild:!0,children:f.jsxs("button",{className:Te("text-base md:text-lg lg:text-xl font-normal border border-l-0 border-black px-2 py-1 flex items-center bg-white hover:bg-gray-50 transition-colors",!e&&"text-muted-foreground"),children:[f.jsx(hk,{className:"mr-2 h-4 w-4"}),e?vt(e,"MMM do, yyyy"):f.jsx("span",{children:"Pick a date"})]})}),f.jsx(Uo,{className:"w-auto p-0",align:"start",children:f.jsx(wi,{mode:"single",selected:e,onSelect:t,className:Te("p-3 pointer-events-auto")})})]})})]}),f.jsxs("div",{className:"grid grid-cols-1 lg:grid-cols-[280px_1fr] gap-8 lg:gap-12 mt-8 md:mt-16",children:[f.jsx("div",{className:"hidden lg:block animate-fade-in lg:sticky lg:top-24 self-start",style:{animationDelay:"0.9s",animationFillMode:"both"},children:f.jsx(wi,{mode:"single",selected:e,onSelect:t,className:"mx-auto"})}),f.jsx("div",{className:"grid grid-cols-1 sm:grid-cols-2 lg:grid-cols-3 lg:col-start-2 gap-5",children:s?f.jsx("div",{className:"col-span-full text-center py-12",children:"Loading events..."}):h.length===0?f.jsx("div",{className:"col-span-full text-center py-12",children:e?`No events found for ${e.toLocaleDateString("en-US",{weekday:"long",month:"long",day:"numeric"})}`:"No events found"}):h.map((b,g)=>f.jsx("div",{className:"animate-fade-in",style:{animationDelay:`${1+g*.1}s`,animationFillMode:"both"},children:f.jsx(U5,{event:b})},b.id))})]})]})})]})},Kn=w.forwardRef(({className:e,type:t,...n},r)=>f.jsx("input",{type:t,className:Te("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}));Kn.displayName="Input";const W5=()=>{const[e,t]=w.useState(""),[n,r]=w.useState(""),[s,i]=w.useState(!0),[o,a]=w.useState(!1),l=Fn(),{toast:c}=Wl();w.useEffect(()=>{X.auth.getSession().then(({data:{session:h}})=>{h&&l("/admin")});const{data:{subscription:d}}=X.auth.onAuthStateChange((h,p)=>{p&&l("/admin")});return()=>d.unsubscribe()},[l]);const u=async d=>{d.preventDefault(),a(!0);try{if(s){const{error:h}=await X.auth.signInWithPassword({email:e,password:n});if(h)throw h;c({title:"Success",description:"Logged in successfully"})}else{const{error:h}=await X.auth.signUp({email:e,password:n,options:{emailRedirectTo:`${window.location.origin}/admin`}});if(h)throw h;c({title:"Success",description:"Account created successfully"})}}catch(h){c({title:"Error",description:h.message,variant:"destructive"})}finally{a(!1)}};return f.jsxs("div",{className:"min-h-screen flex items-center justify-center bg-white px-4",children:[f.jsx(lr,{title:s?"Sign In":"Sign Up",description:s?"Sign in to manage your events and registrations":"Create an account to manage events and register for upcoming events"}
232),f.jsxs("div",{className:"w-full max-w-md space-y-8",children:[f.jsxs("div",{children:[f.jsx("h2",{className:"text-4xl font-normal text-[#1A1A1A] tracking-[-0.02em]",children:s?"Sign In":"Sign Up"}),f.jsx("p",{className:"mt-2 text-sm text-[#1A1A1A] opacity-50",children:s?"Sign in to manage events":"Create an account to manage events"})]}),f.jsxs("form",{onSubmit:u,className:"space-y-6",children:[f.jsx("div",{children:f.jsx(Kn,{type:"email",placeholder:"Email",value:e,onChange:d=>t(d.target.value),required:!0,className:"border-[#1A1A1A] text-[#1A1A1A]"})}),f.jsx("div",{children:f.jsx(Kn,{type:"password",placeholder:"Password",value:n,onChange:d=>r(d.target.value),required:!0,className:"border-[#1A1A1A] text-[#1A1A1A]"})}),f.jsx(ad,{type:"submit",disabled:o,className:"w-full bg-[#1A1A1A] text-white hover:bg-opacity-90",children:o?"Loading...":s?"Sign In":"Sign Up"})]}),f.jsx("button",{onClick:()=>i(!s),className:"text-sm text-[#1A1A1A] hover:opacity-70 transition-opacity",children:s?"Don't have an account? Sign up":"Already have an account? Sign in"})]})]})},vC=w.forwardRef(({className:e,...t},n)=>f.jsx("textarea",{className:Te("flex min-h-[80px] w-full rounded-md border border-input bg-background px-3 py-2 text-sm r
232ing-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}));vC.displayName="Textarea";var ge;(function(e){e.assertEqual=s=>{};function t(s){}e.assertIs=t;function n(s){throw new Error}e.assertNever=n,e.arrayToEnum=s=>{const i={};for(const o of s)i[o]=o;return i},e.getValidEnumValues=s=>{const i=e.objectKeys(s).filter(a=>typeof s[s[a]]!="number"),o={};for(const a of i)o[a]=s[a];return e.objectValues(o)},e.objectValues=s=>e.objectKeys(s).map(function(i){return s[i]}),e.objectKeys=typeof Object.keys=="function"?s=>Object.keys(s):s=>{const i=[];for(const o in s)Object.prototype.hasOwnProperty.call(s,o)&&i.push(o);return i},e.find=(s,i)=>{for(const o of s)if(i(o))return o},e.isInteger=typeof Number.isInteger=="function"?s=>Number.isInteger(s):s=>typeof s=="number"&&Number.isFinite(s)&&Math.floor(s)===s;function r(s,i=" | "){return s.map(o=>typeof o=="string"?`'${o}'`:o).join(i)}e.joinValues=r,e.jsonStringifyReplacer=(s,i)=>typeof i=="bigint"?i.toString():i})(ge||(ge={}));var Zw;(function(e){e.mergeShapes=(t,n)=>({...t,...n})})(Zw||(Zw={}));const q=ge.arrayToEnum(["string","nan","number","integer","float","boolean","date","bigint","symbol","function","undefined","null","array","object","unknown","promise","void","never","map","set"]),Gr=e=>{switch(typeof e){case"undefined":return q.undefined;case"string":return q.string;case"number":return Number.isNaN(e)?q.nan:q.number;case"boolean":return q.boolean;case"function":return q.function;case"bigint":return q.bigint;case"symbol":return q.symbol;case"object":return Array.isArray(e)?q.array:e===null?q.null:e.then&&typeof e.then=="function"&&e.catch&&typeof e.catch=="function"?q.promise:typeof Map<"u"&&e instanceof Map?q.map:typeof Set<"u"&&e instanceof Set?q.set:typeof Date<"u"&&e instanceof Date?q.date:q.object;default:return q.unknown}}
vendor: 4,673 bytes, line 232
232,L=ge.arrayToEnum(["invalid_type","invalid_literal","custom","invalid_union","invalid_union_discriminator","invalid_enum_value","unrecognized_keys","invalid_arguments","invalid_return_type","invalid_date","invalid_string","too_small","too_big","invalid_intersection_types","not_multiple_of","not_finite"]);class ur extends Error{get errors(){return this.issues}constructor(t){super(),this.issues=[],this.addIssue=r=>{this.issues=[...this.issues,r]},this.addIssues=(r=[])=>{this.issues=[...this.issues,...r]};const n=new.target.prototype;Object.setPrototypeOf?Object.setPrototypeOf(this,n):this.__proto__=n,this.name="ZodError",this.issues=t}format(t){const n=t||function(i){return i.message},r={_errors:[]},s=i=>{for(const o of i.issues)if(o.code==="invalid_union")o.unionErrors.map(s);else if(o.code==="invalid_return_type")s(o.returnTypeError);else if(o.code==="invalid_arguments")s(o.argumentsError);else if(o.path.length===0)r._errors.push(n(o));else{let a=r,l=0;for(;l<o.path.length;){const c=o.path[l];l===o.path.length-1?(a[c]=a[c]||{_errors:[]},a[c]._errors.push(n(o))):a[c]=a[c]||{_errors:[]},a=a[c],l++}}};return s(this),r}static assert(t){if(!(t instanceof ur))throw new Error(`Not a ZodError: ${t}`)}toString(){return this.message}get message(){return JSON.stringify(this.issues,ge.jsonStringifyReplacer,2)}get isEmpty(){return this.issues.length===0}flatten(t=n=>n.message){const n={},r=[];for(const s of this.issues)if(s.path.length>0){const i=s.path[0];n[i]=n[i]||[],n[i].push(t(s))}else r.push(t(s));return{formErrors:r,fieldErrors:n}}get formErrors(){return this.flatten()}}ur.create=e=>new ur(e);const ym=(e,t)=>{let n;switch(e.code){case L.invalid_type:e.received===q.undefined?n="Required":n=`Expected ${e.expected}, received ${e.received}`;break;case L.invalid_literal:n=`Invalid literal value, expected ${JSON.stringify(e.expected,ge.jsonStringifyReplacer)}`;break;case L.unrecognized_keys:n=`Unrecognized key(s) in object: ${ge.joinValues(e.keys,", ")}`;break;case L.invalid_union:n="Invalid input";break;case L.invalid_union_discriminator:n=`Invalid discriminator value. Expected ${ge.joinValues(e.options)}`;break;case L.invalid_enum_value:n=`Invalid enum value. Expected ${ge.joinValues(e.options)}, received '${e.received}'`;break;case L.invalid_arguments:n="Invalid function arguments";break;case L.invalid_return_type:n="Invalid function return type";break;case L.invalid_date:n="Invalid date";break;case L.invalid_string:typeof e.validation=="object"?"includes"in e.validation?(n=`Invalid input: must include "${e.validation.includes}"`,typeof e.validation.position=="number"&&(n=`${n} at one or more positions greater than or equal to ${e.validation.position}`)):"startsWith"in e.validation?n=`Invalid input: must start with "${e.validation.startsWith}"`:"endsWith"in e.validation?n=`Invalid input: must end with "${e.validation.endsWith}"`:ge.assertNever(e.validation):e.validation!=="regex"?n=`Invalid ${e.validation}`:n="Invalid";break;case L.too_small:e.type==="array"?n=`Array must contain ${e.exact?"exactly":e.inclusive?"at least":"more than"} ${e.minimum} element(s)`:e.type==="string"?n=`String must contain ${e.exact?"exactly":e.inclusive?"at least":"over"} ${e.minimum} character(s)`:e.type==="number"?n=`Number must be ${e.exact?"exactly equal to ":e.inclusive?"greater than or equal to ":"greater than "}${e.minimum}`:e.type==="bigint"?n=`Number must be ${e.exact?"exactly equal to ":e.inclusive?"greater than or equal to ":"greater than "}${e.minimum}`:e.type==="date"?n=`Date must be ${e.exact?"exactly equal to ":e.inclusive?"greater than or equal to ":"greater than "}${new Date(Number(e.minimum))}`:n="Invalid input";break;case L.too_big:e.type==="array"?n=`Array must contain ${e.exact?"exactly":e.inclusive?"at most":"less than"} ${e.maximum} element(s)`:e.type==="string"?n=`String must contain ${e.exact?"exactly":e.inclusive?"at most":"under"} ${e.maximum} character(s)`:e.type==="number"?n=`Number must be ${e.exact?"exactly":e.inclusive?"less than or equal to":"less than"} ${e.maximum}`:e.type==="bigint"?n=`BigInt must be ${e.exact?"exactly":e.inclusive?"less than or equal to":"less than"} ${e.maximum}`:e.type==="date"?n=`Date must be ${e.exact?"exactly":e.inclusive?"smaller than or equal to":"smaller than"} ${new Date(Number(e.maximum))}`:n="Invalid input";break;case L.custom:n="Invalid input";break;case L.invalid_intersection_types:n="Intersection results could not be merged";break;case L.not_multiple_of:n=`Number must be a multiple of ${e.multipleOf}`;break;case L.not_finite:n="Number must be finite";break;default:n=t.defaultError,ge.assertNever(e)}return{message:n}};let H5=ym;function K5(){return H5}
vendor: 17,783 bytes, line 232
232const q5=e=>{const{data:t,path:n,errorMaps:r,issueData:s}=e,i=[...n,...s.path||[]],o={...s,path:i};if(s.message!==void 0)return{...s,path:i,message:s.message};let a="";const l=r.filter(c=>!!c).slice().reverse();for(const c of l)a=c(o,{data:t,defaultError:a}).message;return{...s,path:i,message:a}};function z(e,t){const n=K5(),r=q5({issueData:t,data:e.data,path:e.path,errorMaps:[e.common.contextualErrorMap,e.schemaErrorMap,n,n===ym?void 0:ym].filter(s=>!!s)});e.common.issues.push(r)}class Ht{constructor(){this.value="valid"}dirty(){this.value==="valid"&&(this.value="dirty")}abort(){this.value!=="aborted"&&(this.value="aborted")}static mergeArray(t,n){const r=[];for(const s of n){if(s.status==="aborted")return re;s.status==="dirty"&&t.dirty(),r.push(s.value)}return{status:t.value,value:r}}static async mergeObjectAsync(t,n){const r=[];for(const s of n){const i=await s.key,o=await s.value;r.push({key:i,value:o})}return Ht.mergeObjectSync(t,r)}static mergeObjectSync(t,n){const r={};for(const s of n){const{key:i,value:o}=s;if(i.status==="aborted"||o.status==="aborted")return re;i.status==="dirty"&&t.dirty(),o.status==="dirty"&&t.dirty(),i.value!=="__proto__"&&(typeof o.value<"u"||s.alwaysSet)&&(r[i.value]=o.value)}return{status:t.value,value:r}}}const re=Object.freeze({status:"aborted"}),Na=e=>({status:"dirty",value:e}),dn=e=>({status:"valid",value:e}),Jw=e=>e.status==="aborted",Xw=e=>e.status==="dirty",zo=e=>e.status==="valid",ld=e=>typeof Promise<"u"&&e instanceof Promise;var G;(function(e){e.errToObj=t=>typeof t=="string"?{message:t}:t||{},e.toString=t=>typeof t=="string"?t:t==null?void 0:t.message})(G||(G={}));class Ss{constructor(t,n,r,s){this._cachedPath=[],this.parent=t,this.data=n,this._path=r,this._key=s}get path(){return this._cachedPath.length||(Array.isArray(this._key)?this._cachedPath.push(...this._path,...this._key):this._cachedPath.push(...this._path,this._key)),this._cachedPath}}const ex=(e,t)=>{if(zo(t))return{success:!0,data:t.value};if(!e.common.issues.length)throw new Error("Validation failed but no issues detected.");return{success:!1,get error(){if(this._error)return this._error;const n=new ur(e.common.issues);return this._error=n,this._error}}};function ce(e){if(!e)return{};const{errorMap:t,invalid_type_error:n,required_error:r,description:s}=e;if(t&&(n||r))throw new Error(`Can't use "invalid_type_error" or "required_error" in conjunction with custom error map.`);return t?{errorMap:t,description:s}:{errorMap:(o,a)=>{const{message:l}=e;return o.code==="invalid_enum_value"?{message:l??a.defaultError}:typeof a.data>"u"?{message:l??r??a.defaultError}:o.code!=="invalid_type"?{message:a.defaultError}:{message:l??n??a.defaultError}},description:s}}class pe{get description(){return this._def.description}_getType(t){return Gr(t.data)}_getOrReturnCtx(t,n){return n||{common:t.parent.common,data:t.data,parsedType:Gr(t.data),schemaErrorMap:this._def.errorMap,path:t.path,parent:t.parent}}_processInputParams(t){return{status:new Ht,ctx:{common:t.parent.common,data:t.data,parsedType:Gr(t.data),schemaErrorMap:this._def.errorMap,path:t.path,parent:t.parent}}}_parseSync(t){const n=this._parse(t);if(ld(n))throw new Error("Synchronous parse encountered promise.");return n}_parseAsync(t){const n=this._parse(t);return Promise.resolve(n)}parse(t,n){const r=this.safeParse(t,n);if(r.success)return r.data;throw r.error}safeParse(t,n){const r={common:{issues:[],async:(n==null?void 0:n.async)??!1,contextualErrorMap:n==null?void 0:n.errorMap},path:(n==null?void 0:n.path)||[],schemaErrorMap:this._def.errorMap,parent:null,data:t,parsedType:Gr(t)},s=this._parseSync({data:t,path:r.path,parent:r});return ex(r,s)}"~validate"(t){var r,s;const n={common:{issues:[],async:!!this["~standard"].async},path:[],schemaErrorMap:this._def.errorMap,parent:null,data:t,parsedType:Gr(t)};if(!this["~standard"].async)try{const i=this._parseSync({data:t,path:[],parent:n});return zo(i)?{value:i.value}:{issues:n.common.issues}}catch(i){(s=(r=i==null?void 0:i.message)==null?void 0:r.toLowerCase())!=null&&s.includes("encountered")&&(this["~standard"].async=!0),n.common={issues:[],async:!0}}return this._parseAsync({data:t,path:[],parent:n}).then(i=>zo(i)?{value:i.value}:{issues:n.common.issues})}async parseAsync(t,n){const r=await this.safeParseAsync(t,n);if(r.success)return r.data;throw r.error}async safeParseAsync(t,n){const r={common:{issues:[],contextualErrorMap:n==null?void 0:n.errorMap,async:!0},path:(n==null?void 0:n.path)||[],schemaErrorMap:this._def.errorMap,parent:null,data:t,parsedType:Gr(t)},s=this._parse({data:t,path:r.path,parent:r}),i=await(ld(s)?s:Promise.resolve(s));return ex(r,i)}refine(t,n){const r=s=>typeof n=="string"||typeof n>"u"?{message:n}:typeof n=="function"?n(s):n;return this._refinement((s,i)=>{const o=t(s),a=()=>i.addIssue({code:L.custom,...r(s)});return typeof Promise<"u"&&o instanceof Promise?o.then(l=>l?!0:(a(),!1)):o?!0:(a(),!1)})}refinement(t,n){return this._refinement((r,s)=>t(r)?!0:(s.addIssue(typeof n=="function"?n(r,s):n),!1))}_refinement(t){return new Ho({schema:this,typeName:se.ZodEffects,effect:{type:"refinement",refinement:t}})}superRefine(t){return this._refinement(t)}constructor(t){this.spa=this.safeParseAsync,this._def=t,this.parse=this.parse.bind(this),this.safeParse=this.safeParse.bind(this),this.parseAsync=this.parseAsync.bind(this),this.safeParseAsync=this.safeParseAsync.bind(this),this.spa=this.spa.bind(this),this.refine=this.refine.bind(this),this.refinement=this.refinement.bind(this),this.superRefine=this.superRefine.bind(this),this.optional=this.optional.bind(this),this.nullable=this.nullable.bind(this),this.nullish=this.nullish.bind(this),this.array=this.array.bind(this),this.promise=this.promise.bind(this),this.or=this.or.bind(this),this.and=this.and.bind(this),this.transform=this.transform.bind(this),this.brand=this.brand.bind(this),this.default=this.default.bind(this),this.catch=this.catch.bind(this),this.describe=this.describe.bind(this),this.pipe=this.pipe.bind(this),this.readonly=this.readonly.bind(this),this.isNullable=this.isNullable.bind(this),this.isOptional=this.isOptional.bind(this),this["~standard"]={version:1,vendor:"zod",validate:n=>this["~validate"](n)}}optional(){return ys.create(this,this._def)}nullable(){return Ko.create(this,this._def)}nullish(){return this.nullable().optional()}array(){return sr.create(this)}promise(){return fd.create(this,this._def)}or(t){return ud.create([this,t],this._def)}and(t){return dd.create(this,t,this._def)}transform(t){return new Ho({...ce(this._def),schema:this,typeName:se.ZodEffects,effect:{type:"transform",transform:t}})}default(t){const n=typeof t=="function"?t:()=>t;return new xm({...ce(this._def),innerType:this,defaultValue:n,typeName:se.ZodDefault})}brand(){return new g6({typeName:se.ZodBranded,type:this,...ce(this._def)})}catch(t){const n=typeof t=="function"?t:()=>t;return new bm({...ce(this._def),innerType:this,catchValue:n,typeName:se.ZodCatch})}describe(t){const n=this.constructor;return new n({...this._def,description:t})}pipe(t){return Pv.create(this,t)}readonly(){return _m.create(this)}isOptional(){return this.safeParse(void 0).success}isNullable(){return this.safeParse(null).success}}const Y5=/^c[^\s-]{8,}$/i,G5=/^[0-9a-z]+$/,Q5=/^[0-9A-HJKMNP-TV-Z]{26}$/i,Z5=/^[0-9a-fA-F]{8}\b-[0-9a-fA-F]{4}\b-[0-9a-fA-F]{4}\b-[0-9a-fA-F]{4}\b-[0-9a-fA-F]{12}$/i,J5=/^[a-z0-9_-]{21}$/i,X5=/^[A-Za-z0-9-_]+\.[A-Za-z0-9-_]+\.[A-Za-z0-9-_]*$/,e6=/^[-+]?P(?!$)(?:(?:[-+]?\d+Y)|(?:[-+]?\d+[.,]\d+Y$))?(?:(?:[-+]?\d+M)|(?:[-+]?\d+[.,]\d+M$))?(?:(?:[-+]?\d+W)|(?:[-+]?\d+[.,]\d+W$))?(?:(?:[-+]?\d+D)|(?:[-+]?\d+[.,]\d+D$))?(?:T(?=[\d+-])(?:(?:[-+]?\d+H)|(?:[-+]?\d+[.,]\d+H$))?(?:(?:[-+]?\d+M)|(?:[-+]?\d+[.,]\d+M$))?(?:[-+]?\d+(?:[.,]\d+)?S)?)??$/,t6=/^(?!\.)(?!.*\.\.)([A-Z0-9_'+\-\.]*)[A-Z0-9_+-]@([A-Z0-9][A-Z0-9\-]*\.)+[A-Z]{2,}$/i,n6="^(\\p{Extended_Pictographic}|\\p{Emoji_Component})+$";let Eh;const r6=/^(?:(?:25[0-5]|2[0-4][0-9]|1[0-9][0-9]|[1-9][0-9]|[0-9])\.){3}(?:25[0-5]|2[0-4][0-9]|1[0-9][0-9]|[1-9][0-9]|[0-9])$/,s6=/^(?:(?:25[0-5]|2[0-4][0-9]|1[0-9][0-9]|[1-9][0-9]|[0-9])\.){3}(?:25[0-5]|2[0-4][0-9]|1[0-9][0-9]|[1-9][0-9]|[0-9])\/(3[0-2]|[12]?[0-9])$/,i6=/^(([0-9a-fA-F]{1,4}:){7,7}[0-9a-fA-F]{1,4}|([0-9a-fA-F]{1,4}:){1,7}:|([0-9a-fA-F]{1,4}:){1,6}:[0-9a-fA-F]{1,4}|([0-9a-fA-F]{1,4}:){1,5}(:[0-9a-fA-F]{1,4}){1,2}|([0-9a-fA-F]{1,4}:){1,4}(:[0-9a-fA-F]{1,4}){1,3}|([0-9a-fA-F]{1,4}:){1,3}(:[0-9a-fA-F]{1,4}){1,4}|([0-9a-fA-F]{1,4}:){1,2}(:[0-9a-fA-F]{1,4}){1,5}|[0-9a-fA-F]{1,4}:((:[0-9a-fA-F]{1,4}){1,6})|:((:[0-9a-fA-F]{1,4}){1,7}|:)|fe80:(:[0-9a-fA-F]{0,4}){0,4}%[0-9a-zA-Z]{1,}|::(ffff(:0{1,4}){0,1}:){0,1}((25[0-5]|(2[0-4]|1{0,1}[0-9]){0,1}[0-9])\.){3,3}(25[0-5]|(2[0-4]|1{0,1}[0-9]){0,1}[0-9])|([0-9a-fA-F]{1,4}:){1,4}:((25[0-5]|(2[0-4]|1{0,1}[0-9]){0,1}[0-9])\.){3,3}(25[0-5]|(2[0-4]|1{0,1}[0-9]){0,1}[0-9]))$/,o6=/^(([0-9a-fA-F]{1,4}:){7,7}[0-9a-fA-F]{1,4}|([0-9a-fA-F]{1,4}:){1,7}:|([0-9a-fA-F]{1,4}:){1,6}:[0-9a-fA-F]{1,4}|([0-9a-fA-F]{1,4}:){1,5}(:[0-9a-fA-F]{1,4}){1,2}|([0-9a-fA-F]{1,4}:){1,4}(:[0-9a-fA-F]{1,4}){1,3}|([0-9a-fA-F]{1,4}:){1,3}(:[0-9a-fA-F]{1,4}){1,4}|([0-9a-fA-F]{1,4}:){1,2}(:[0-9a-fA-F]{1,4}){1,5}|[0-9a-fA-F]{1,4}:((:[0-9a-fA-F]{1,4}){1,6})|:((:[0-9a-fA-F]{1,4}){1,7}|:)|fe80:(:[0-9a-fA-F]{0,4}){0,4}%[0-9a-zA-Z]{1,}|::(ffff(:0{1,4}){0,1}:){0,1}((25[0-5]|(2[0-4]|1{0,1}[0-9]){0,1}[0-9])\.){3,3}(25[0-5]|(2[0-4]|1{0,1}[0-9]){0,1}[0-9])|([0-9a-fA-F]{1,4}:){1,4}:((25[0-5]|(2[0-4]|1{0,1}[0-9]){0,1}[0-9])\.){3,3}(25[0-5]|(2[0-4]|1{0,1}[0-9]){0,1}[0-9]))\/(12[0-8]|1[01][0-9]|[1-9]?[0-9])$/,a6=/^([0-9a-zA-Z+/]{4})*(([0-9a-zA-Z+/]{2}==)|([0-9a-zA-Z+/]{3}=))?$/,l6=/^([0-9a-zA-Z-_]{4})*(([0-9a-zA-Z-_]{2}(==)?)|([0-9a-zA-Z-_]{3}(=)?))?$/,yC="((\\d\\d[2468][048]|\\d\\d[13579][26]|\\d\\d0[48]|[02468][048]00|[13579][26]00)-02-29|\\d{4}-((0[13578]|1[02])-(0[1-9]|[12]\\d|3[01])|(0[469]|11)-(0[1-9]|[12]\\d|30)|(02)-(0[1-9]|1\\d|2[0-8])))",c6=new RegExp(`^${yC}$`);function wC(e){let t="[0-5]\\d";e.precision?t=`${t}\\.\\d{${e.precision}}`:e.precision==null&&(t=`${t}(\\.\\d+)?`);const n=e.precision?"+":"?";return`([01]\\d|2[0-3]):[0-5]\\d(:${t})${n}`}function u6(e){return new RegExp(`^${wC(e)}$`)}function d6(e){let t=`${yC}T${wC(e)}`;const n=[];return n.push(e.local?"Z?":"Z"),e.offset&&n.push("([+-]\\d{2}:?\\d{2})"),t=`${t}(${n.join("|")})`,new RegExp(`^${t}$`)}function f6(e,t){return!!((t==="v4"||!t)&&r6.test(e)||(t==="v6"||!t)&&i6.test(e))}function h6(e,t){if(!X5.test(e))return!1;try{const[n]=e.split(".");if(!n)return!1;const r=n.replace(/-/g,"+").replace(/_/g,"/").padEnd(n.length+(4-n.length%4)%4,"="),s=JSON.parse(atob(r));return!(typeof s!="object"||s===null||"typ"in s&&(s==null?void 0:s.typ)!=="JWT"||!s.alg||t&&s.alg!==t)}catch{return!1}}function p6(e,t){return!!((t==="v4"||!t)&&s6.test(e)||(t==="v6"||!t)&&o6.test(e))}class as extends pe{_parse(t){if(this._def.coerce&&(t.data=String(t.data)),this._getType(t)!==q.string){const i=this._getOrReturnCtx(t);return z(i,{code:L.invalid_type,expected:q.string,received:i.parsedType}),re}const r=new Ht;let s;for(const i of this._def.checks)if(i.kind==="min")t.data.length<i.value&&(s=this._getOrReturnCtx(t,s),z(s,{code:L.too_small,minimum:i.value,type:"string",inclusive:!0,exact:!1,message:i.message}),r.dirty());else if(i.kind==="max")t.data.length>i.value&&(s=this._getOrReturnCtx(t,s),z(s,{code:L.too_big,maximum:i.value,type:"string",inclusive:!0,exact:!1,message:i.message}),r.dirty());else if(i.kind==="length"){const o=t.data.length>i.value,a=t.data.length<i.value;(o||a)&&(s=this._getOrReturnCtx(t,s),o?z(s,{code:L.too_big,maximum:i.value,type:"string",inclusive:!0,exact:!0,message:i.message}):a&&z(s,{code:L.too_small,minimum:i.value,type:"string",inclusive:!0,exact:!0,message:i.message}),r.dirty())}else if(i.kind==="email")t6.test(t.data)||(s=this._getOrReturnCtx(t,s),z(s,{validation:"email",code:L.invalid_string,message:i.message}),r.dirty());else if(i.kind==="emoji")Eh||(Eh=new RegExp(n6,"u")),Eh.test(t.data)||(s=this._getOrReturnCtx(t,s),z(s,{validation:"emoji",code:L.invalid_string,message:i.message}),r.dirty());else if(i.kind==="uuid")Z5.test(t.data)||(s=this._getOrReturnCtx(t,s),z(s,{validation:"uuid",code:L.invalid_string,message:i.message}),r.dirty());else if(i.kind==="nanoid")J5.test(t.data)||(s=this._getOrReturnCtx(t,s),z(s,{validation:"nanoid",code:L.invalid_string,message:i.message}),r.dirty());else if(i.kind==="cuid")Y5.test(t.data)||(s=this._getOrReturnCtx(t,s),z(s,{validation:"cuid",code:L.invalid_string,message:i.message}),r.dirty());else if(i.kind==="cuid2")G5.test(t.data)||(s=this._getOrReturnCtx(t,s),z(s,{validation:"cuid2",code:L.invalid_string,message:i.message}),r.dirty());else if(i.kind==="ulid")Q5.test(t.data)||(s=this._getOrReturnCtx(t,s),z(s,{validation:"ulid",code:L.invalid_string,message:i.message}),r.dirty());else if(i.kind==="url")try{new URL(t.data)}catch{s=this._getOrReturnCtx(t,s),z(s,{validation:"url",code:L.invalid_string,message:i.message}),r.dirty()}else i.kind==="regex"?(i.regex.lastIndex=0,i.regex.test(t.data)||(s=this._getOrReturnCtx(t,s),z(s,{validation:"regex",code:L.invalid_string,message:i.message}),r.dirty())):i.kind==="trim"?t.data=t.data.trim():i.kind==="includes"?t.data.includes(i.value,i.position)||(s=this._getOrReturnCtx(t,s),z(s,{code:L.invalid_string,validation:{includes:i.value,position:i.position},message:i.message}),r.dirty()):i.kind==="toLowerCase"?t.data=t.data.toLowerCase():i.kind==="toUpperCase"?t.data=t.data.toUpperCase():i.kind==="startsWith"?t.data.startsWith(i.value)||(s=this._getOrReturnCtx(t,s),z(s,{code:L.invalid_string,validation:{startsWith:i.value},message:i.message}),r.dirty()):i.kind==="endsWith"?t.data.endsWith(i.value)||(s=this._getOrReturnCtx(t,s),z(s,{code:L.invalid_string,validation:{endsWith:i.value},message:i.message}),r.dirty()):i.kind==="datetime"?d6(i).test(t.data)||(s=this._getOrReturnCtx(t,s),z(s,{code:L.invalid_string,validation:"datetime",message:i.message}),r.dirty()):i.kind==="date"?c6.test(t.data)||(s=this._getOrReturnCtx(t,s),z(s,{code:L.invalid_string,validation:"date",message:i.message}),r.dirty()):i.kind==="time"?u6(i).test(t.data)||(s=this._getOrReturnCtx(t,s),z(s,{code:L.invalid_string,validation:"time",message:i.message}),r.dirty()):i.kind==="duration"?e6.test(t.data)||(s=this._getOrReturnCtx(t,s),z(s,{validation:"duration",code:L.invalid_string,message:i.message}),r.dirty()):i.kind==="ip"?f6(t.data,i.version)||(s=this._getOrReturnCtx(t,s),z(s,{validation:"ip",code:L.invalid_string,message:i.message}),r.dirty()):i.kind==="jwt"?h6(t.data,i.alg)||(s=this._getOrReturnCtx(t,s),z(s,{validation:"jwt",code:L.invalid_string,message:i.message}),r.dirty()):i.kind==="cidr"?p6(t.data,i.version)||(s=this._getOrReturnCtx(t,s),z(s,{validation:"cidr",code:L.invalid_string,message:i.message}),r.dirty()):i.kind==="base64"?a6.test(t.data)||(s=this._getOrReturnCtx(t,s),z(s,{validation:"base64",code:L.invalid_string,message:i.message}),r.dirty()):i.kind==="base64url"?l6.test(t.data)||(s=this._getOrReturnCtx(t,s),z(s,{validation:"base64url",code:L.invalid_string,message:i.message}),r.dirty()):ge.assertNever(i);return{status:r.value,value:t.data}}_regex(t,n,r){return this.refinement(s=>t.test(s),{validation:n,code:L.invalid_string,...G.errToObj(r)})}_addCheck(t){return new as({...this._def,checks:[...this._def.checks,t]})}email(t){return this._addCheck({kind:"email",...G.errToObj(t)})}url(t){return this._addCheck({kind:"url",...G.errToObj(t)})}emoji(t){return this._addCheck({kind:"emoji",...G.errToObj(t)})}uuid(t){return this._addCheck({kind:"uuid",...G.errToObj(t)})}nanoid(t){return this._addCheck({kind:"nanoid",...G.errToObj(t)})}cuid(t){return this._addCheck({kind:"cuid",...G.errToObj(t)})}cuid2(t){return this._addCheck({kind:"cuid2",...G.errToObj(t)})}ulid(t){return this._addCheck({kind:"ulid",...G.errToObj(t)})}base64(t){return this._addCheck({kind:"base64",...G.errToObj(t)})}base64url(t){return this._addCheck({kind:"base64url",...G.errToObj(t)})}jwt(t){return this._addCheck({kind:"jwt",...G.errToObj(t)})}ip(t){return this._addCheck({kind:"ip",...G.errToObj(t)})}cidr(t){return this._addCheck({kind:"cidr",...G.errToObj(t)})}datetime(t){return typeof t=="string"?this._addCheck({kind:"datetime",precision:null,offset:!1,local:!1,message:t}):this._addCheck({kind:"datetime",precision:typeof(t==null?void 0:t.precision)>"u"?null:t==null?void 0:t.precision,offset:(t==null?void 0:t.offset)??!1,local:(t==null?void 0:t.local)??!1,...G.errToObj(t==null?void 0:t.message)})}date(t){return this._addCheck({kind:"date",message:t})}time(t){return typeof t=="string"?this._addCheck({kind:"time",precision:null,message:t}):this._addCheck({kind:"time",precision:typeof(t==null?void 0:t.precision)>"u"?null:t==null?void 0:t.precision,...G.errToObj(t==null?void 0:t.message)})}duration(t){return this._addCheck({kind:"duration",...G.errToObj(t)})}regex(t,n){return this._addCheck({kind:"regex",regex:t,...G.errToObj(n)})}includes(t,n){return this._addCheck({kind:"includes",value:t,position:n==null?void 0:n.position,...G.errToObj(n==null?void 0:n.message)})}startsWith(t,n){return this._addCheck({kind:"startsWith",value:t,...G.errToObj(n)})}endsWith(t,n){return this._addCheck({kind:"endsWith",value:t,...G.errToObj(n)})}min(t,n){return this._addCheck({kind:"min",value:t,...G.errToObj(n)})}max(t,n){return this._addCheck({kind:"max",value:t,...G.errToObj(n)})}length(t,n){return this._addCheck({kind:"length",value:t,...G.errToObj(n)})}nonempty(t){return this.min(1,G.errToObj(t))}trim(){return new as({...this._def,checks:[...this._def.checks,{kind:"trim"}]})}toLowerCase(){return new as({...this._def,checks:[...this._def.checks,{kind:"toLowerCase"}]})}toUpperCase(){return new as({...this._def,checks:[...this._def.checks,{kind:"toUpperCase"}]})}get isDatetime(){return!!this._def.checks.find(t=>t.kind==="datetime")}
vendor: 4,642 bytes, line 232
232get isDate(){return!!this._def.checks.find(t=>t.kind==="date")}get isTime(){return!!this._def.checks.find(t=>t.kind==="time")}get isDuration(){return!!this._def.checks.find(t=>t.kind==="duration")}get isEmail(){return!!this._def.checks.find(t=>t.kind==="email")}get isURL(){return!!this._def.checks.find(t=>t.kind==="url")}get isEmoji(){return!!this._def.checks.find(t=>t.kind==="emoji")}get isUUID(){return!!this._def.checks.find(t=>t.kind==="uuid")}get isNANOID(){return!!this._def.checks.find(t=>t.kind==="nanoid")}get isCUID(){return!!this._def.checks.find(t=>t.kind==="cuid")}get isCUID2(){return!!this._def.checks.find(t=>t.kind==="cuid2")}get isULID(){return!!this._def.checks.find(t=>t.kind==="ulid")}get isIP(){return!!this._def.checks.find(t=>t.kind==="ip")}get isCIDR(){return!!this._def.checks.find(t=>t.kind==="cidr")}get isBase64(){return!!this._def.checks.find(t=>t.kind==="base64")}get isBase64url(){return!!this._def.checks.find(t=>t.kind==="base64url")}get minLength(){let t=null;for(const n of this._def.checks)n.kind==="min"&&(t===null||n.value>t)&&(t=n.value);return t}get maxLength(){let t=null;for(const n of this._def.checks)n.kind==="max"&&(t===null||n.value<t)&&(t=n.value);return t}}as.create=e=>new as({checks:[],typeName:se.ZodString,coerce:(e==null?void 0:e.coerce)??!1,...ce(e)});function m6(e,t){const n=(e.toString().split(".")[1]||"").length,r=(t.toString().split(".")[1]||"").length,s=n>r?n:r,i=Number.parseInt(e.toFixed(s).replace(".","")),o=Number.parseInt(t.toFixed(s).replace(".",""));return i%o/10**s}class Al extends pe{constructor(){super(...arguments),this.min=this.gte,this.max=this.lte,this.step=this.multipleOf}_parse(t){if(this._def.coerce&&(t.data=Number(t.data)),this._getType(t)!==q.number){const i=this._getOrReturnCtx(t);return z(i,{code:L.invalid_type,expected:q.number,received:i.parsedType}),re}let r;const s=new Ht;for(const i of this._def.checks)i.kind==="int"?ge.isInteger(t.data)||(r=this._getOrReturnCtx(t,r),z(r,{code:L.invalid_type,expected:"integer",received:"float",message:i.message}),s.dirty()):i.kind==="min"?(i.inclusive?t.data<i.value:t.data<=i.value)&&(r=this._getOrReturnCtx(t,r),z(r,{code:L.too_small,minimum:i.value,type:"number",inclusive:i.inclusive,exact:!1,message:i.message}),s.dirty()):i.kind==="max"?(i.inclusive?t.data>i.value:t.data>=i.value)&&(r=this._getOrReturnCtx(t,r),z(r,{code:L.too_big,maximum:i.value,type:"number",inclusive:i.inclusive,exact:!1,message:i.message}),s.dirty()):i.kind==="multipleOf"?m6(t.data,i.value)!==0&&(r=this._getOrReturnCtx(t,r),z(r,{code:L.not_multiple_of,multipleOf:i.value,message:i.message}),s.dirty()):i.kind==="finite"?Number.isFinite(t.data)||(r=this._getOrReturnCtx(t,r),z(r,{code:L.not_finite,message:i.message}),s.dirty()):ge.assertNever(i);return{status:s.value,value:t.data}}gte(t,n){return this.setLimit("min",t,!0,G.toString(n))}gt(t,n){return this.setLimit("min",t,!1,G.toString(n))}lte(t,n){return this.setLimit("max",t,!0,G.toString(n))}lt(t,n){return this.setLimit("max",t,!1,G.toString(n))}setLimit(t,n,r,s){return new Al({...this._def,checks:[...this._def.checks,{kind:t,value:n,inclusive:r,message:G.toString(s)}]})}_addCheck(t){return new Al({...this._def,checks:[...this._def.checks,t]})}int(t){return this._addCheck({kind:"int",message:G.toString(t)})}positive(t){return this._addCheck({kind:"min",value:0,inclusive:!1,message:G.toString(t)})}negative(t){return this._addCheck({kind:"max",value:0,inclusive:!1,message:G.toString(t)})}nonpositive(t){return this._addCheck({kind:"max",value:0,inclusive:!0,message:G.toString(t)})}nonnegative(t){return this._addCheck({kind:"min",value:0,inclusive:!0,message:G.toString(t)})}multipleOf(t,n){return this._addCheck({kind:"multipleOf",value:t,message:G.toString(n)})}finite(t){return this._addCheck({kind:"finite",message:G.toString(t)})}safe(t){return this._addCheck({kind:"min",inclusive:!0,value:Number.MIN_SAFE_INTEGER,message:G.toString(t)})._addCheck({kind:"max",inclusive:!0,value:Number.MAX_SAFE_INTEGER,message:G.toString(t)})}get minValue(){let t=null;for(const n of this._def.checks)n.kind==="min"&&(t===null||n.value>t)&&(t=n.value);return t}get maxValue(){let t=null;for(const n of this._def.checks)n.kind==="max"&&(t===null||n.value<t)&&(t=n.value);return t}get isInt(){return!!this._def.checks.find(t=>t.kind==="int"||t.kind==="multipleOf"&&ge.isInteger(t.value))}get isFinite(){let t=null,n=null;for(const r of this._def.checks){if(r.kind==="finite"||r.kind==="int"||r.kind==="multipleOf")return!0;r.kind==="min"?(n===null||r.value>n)&&(n=r.value):r.kind==="max"&&(t===null||r.value<t)&&(t=r.value)}return Number.isFinite(n)&&Number.isFinite(t)}
vendor: 4,098 bytes, line 232
232}Al.create=e=>new Al({checks:[],typeName:se.ZodNumber,coerce:(e==null?void 0:e.coerce)||!1,...ce(e)});class Pl extends pe{constructor(){super(...arguments),this.min=this.gte,this.max=this.lte}_parse(t){if(this._def.coerce)try{t.data=BigInt(t.data)}catch{return this._getInvalidInput(t)}if(this._getType(t)!==q.bigint)return this._getInvalidInput(t);let r;const s=new Ht;for(const i of this._def.checks)i.kind==="min"?(i.inclusive?t.data<i.value:t.data<=i.value)&&(r=this._getOrReturnCtx(t,r),z(r,{code:L.too_small,type:"bigint",minimum:i.value,inclusive:i.inclusive,message:i.message}),s.dirty()):i.kind==="max"?(i.inclusive?t.data>i.value:t.data>=i.value)&&(r=this._getOrReturnCtx(t,r),z(r,{code:L.too_big,type:"bigint",maximum:i.value,inclusive:i.inclusive,message:i.message}),s.dirty()):i.kind==="multipleOf"?t.data%i.value!==BigInt(0)&&(r=this._getOrReturnCtx(t,r),z(r,{code:L.not_multiple_of,multipleOf:i.value,message:i.message}),s.dirty()):ge.assertNever(i);return{status:s.value,value:t.data}}_getInvalidInput(t){const n=this._getOrReturnCtx(t);return z(n,{code:L.invalid_type,expected:q.bigint,received:n.parsedType}),re}gte(t,n){return this.setLimit("min",t,!0,G.toString(n))}gt(t,n){return this.setLimit("min",t,!1,G.toString(n))}lte(t,n){return this.setLimit("max",t,!0,G.toString(n))}lt(t,n){return this.setLimit("max",t,!1,G.toString(n))}setLimit(t,n,r,s){return new Pl({...this._def,checks:[...this._def.checks,{kind:t,value:n,inclusive:r,message:G.toString(s)}]})}_addCheck(t){return new Pl({...this._def,checks:[...this._def.checks,t]})}positive(t){return this._addCheck({kind:"min",value:BigInt(0),inclusive:!1,message:G.toString(t)})}negative(t){return this._addCheck({kind:"max",value:BigInt(0),inclusive:!1,message:G.toString(t)})}nonpositive(t){return this._addCheck({kind:"max",value:BigInt(0),inclusive:!0,message:G.toString(t)})}nonnegative(t){return this._addCheck({kind:"min",value:BigInt(0),inclusive:!0,message:G.toString(t)})}multipleOf(t,n){return this._addCheck({kind:"multipleOf",value:t,message:G.toString(n)})}get minValue(){let t=null;for(const n of this._def.checks)n.kind==="min"&&(t===null||n.value>t)&&(t=n.value);return t}get maxValue(){let t=null;for(const n of this._def.checks)n.kind==="max"&&(t===null||n.value<t)&&(t=n.value);return t}}Pl.create=e=>new Pl({checks:[],typeName:se.ZodBigInt,coerce:(e==null?void 0:e.coerce)??!1,...ce(e)});class tx extends pe{_parse(t){if(this._def.coerce&&(t.data=!!t.data),this._getType(t)!==q.boolean){const r=this._getOrReturnCtx(t);return z(r,{code:L.invalid_type,expected:q.boolean,received:r.parsedType}),re}return dn(t.data)}}tx.create=e=>new tx({typeName:se.ZodBoolean,coerce:(e==null?void 0:e.coerce)||!1,...ce(e)});class cd extends pe{_parse(t){if(this._def.coerce&&(t.data=new Date(t.data)),this._getType(t)!==q.date){const i=this._getOrReturnCtx(t);return z(i,{code:L.invalid_type,expected:q.date,received:i.parsedType}),re}if(Number.isNaN(t.data.getTime())){const i=this._getOrReturnCtx(t);return z(i,{code:L.invalid_date}),re}const r=new Ht;let s;for(const i of this._def.checks)i.kind==="min"?t.data.getTime()<i.value&&(s=this._getOrReturnCtx(t,s),z(s,{code:L.too_small,message:i.message,inclusive:!0,exact:!1,minimum:i.value,type:"date"}),r.dirty()):i.kind==="max"?t.data.getTime()>i.value&&(s=this._getOrReturnCtx(t,s),z(s,{code:L.too_big,message:i.message,inclusive:!0,exact:!1,maximum:i.value,type:"date"}),r.dirty()):ge.assertNever(i);return{status:r.value,value:new Date(t.data.getTime())}}_addCheck(t){return new cd({...this._def,checks:[...this._def.checks,t]})}min(t,n){return this._addCheck({kind:"min",value:t.getTime(),message:G.toString(n)})}max(t,n){return this._addCheck({kind:"max",value:t.getTime(),message:G.toString(n)})}get minDate(){let t=null;for(const n of this._def.checks)n.kind==="min"&&(t===null||n.value>t)&&(t=n.value);return t!=null?new Date(t):null}get maxDate(){let t=null;for(const n of this._def.checks)n.kind==="max"&&(t===null||n.value<t)&&(t=n.value);return t!=null?new Date(t):null}}cd.create=e=>new cd({checks:[],coerce:(e==null?void 0:e.coerce)||!1,typeName:se.ZodD
vendor: 8,492 bytes, line 232
232ate,...ce(e)});class nx extends pe{_parse(t){if(this._getType(t)!==q.symbol){const r=this._getOrReturnCtx(t);return z(r,{code:L.invalid_type,expected:q.symbol,received:r.parsedType}),re}return dn(t.data)}}nx.create=e=>new nx({typeName:se.ZodSymbol,...ce(e)});class rx extends pe{_parse(t){if(this._getType(t)!==q.undefined){const r=this._getOrReturnCtx(t);return z(r,{code:L.invalid_type,expected:q.undefined,received:r.parsedType}),re}return dn(t.data)}}rx.create=e=>new rx({typeName:se.ZodUndefined,...ce(e)});class sx extends pe{_parse(t){if(this._getType(t)!==q.null){const r=this._getOrReturnCtx(t);return z(r,{code:L.invalid_type,expected:q.null,received:r.parsedType}),re}return dn(t.data)}}sx.create=e=>new sx({typeName:se.ZodNull,...ce(e)});class ix extends pe{constructor(){super(...arguments),this._any=!0}_parse(t){return dn(t.data)}}ix.create=e=>new ix({typeName:se.ZodAny,...ce(e)});class ox extends pe{constructor(){super(...arguments),this._unknown=!0}_parse(t){return dn(t.data)}}ox.create=e=>new ox({typeName:se.ZodUnknown,...ce(e)});class ks extends pe{_parse(t){const n=this._getOrReturnCtx(t);return z(n,{code:L.invalid_type,expected:q.never,received:n.parsedType}),re}}ks.create=e=>new ks({typeName:se.ZodNever,...ce(e)});class ax extends pe{_parse(t){if(this._getType(t)!==q.undefined){const r=this._getOrReturnCtx(t);return z(r,{code:L.invalid_type,expected:q.void,received:r.parsedType}),re}return dn(t.data)}}ax.create=e=>new ax({typeName:se.ZodVoid,...ce(e)});class sr extends pe{_parse(t){const{ctx:n,status:r}=this._processInputParams(t),s=this._def;if(n.parsedType!==q.array)return z(n,{code:L.invalid_type,expected:q.array,received:n.parsedType}),re;if(s.exactLength!==null){const o=n.data.length>s.exactLength.value,a=n.data.length<s.exactLength.value;(o||a)&&(z(n,{code:o?L.too_big:L.too_small,minimum:a?s.exactLength.value:void 0,maximum:o?s.exactLength.value:void 0,type:"array",inclusive:!0,exact:!0,message:s.exactLength.message}),r.dirty())}if(s.minLength!==null&&n.data.length<s.minLength.value&&(z(n,{code:L.too_small,minimum:s.minLength.value,type:"array",inclusive:!0,exact:!1,message:s.minLength.message}),r.dirty()),s.maxLength!==null&&n.data.length>s.maxLength.value&&(z(n,{code:L.too_big,maximum:s.maxLength.value,type:"array",inclusive:!0,exact:!1,message:s.maxLength.message}),r.dirty()),n.common.async)return Promise.all([...n.data].map((o,a)=>s.type._parseAsync(new Ss(n,o,n.path,a)))).then(o=>Ht.mergeArray(r,o));const i=[...n.data].map((o,a)=>s.type._parseSync(new Ss(n,o,n.path,a)));return Ht.mergeArray(r,i)}get element(){return this._def.type}min(t,n){return new sr({...this._def,minLength:{value:t,message:G.toString(n)}})}max(t,n){return new sr({...this._def,maxLength:{value:t,message:G.toString(n)}})}length(t,n){return new sr({...this._def,exactLength:{value:t,message:G.toString(n)}})}nonempty(t){return this.min(1,t)}}sr.create=(e,t)=>new sr({type:e,minLength:null,maxLength:null,exactLength:null,typeName:se.ZodArray,...ce(t)});function Ki(e){if(e instanceof $e){const t={};for(const n in e.shape){const r=e.shape[n];t[n]=ys.create(Ki(r))}return new $e({...e._def,shape:()=>t})}else return e instanceof sr?new sr({...e._def,type:Ki(e.element)}):e instanceof ys?ys.create(Ki(e.unwrap())):e instanceof Ko?Ko.create(Ki(e.unwrap())):e instanceof xi?xi.create(e.items.map(t=>Ki(t))):e}class $e extends pe{constructor(){super(...arguments),this._cached=null,this.nonstrict=this.passthrough,this.augment=this.extend}_getCached(){if(this._cached!==null)return this._cached;const t=this._def.shape(),n=ge.objectKeys(t);return this._cached={shape:t,keys:n},this._cached}_parse(t){if(this._getType(t)!==q.object){const c=this._getOrReturnCtx(t);return z(c,{code:L.invalid_type,expected:q.object,received:c.parsedType}),re}const{status:r,ctx:s}=this._processInputParams(t),{shape:i,keys:o}=this._getCached(),a=[];if(!(this._def.catchall instanceof ks&&this._def.unknownKeys==="strip"))for(const c in s.data)o.includes(c)||a.push(c);const l=[];for(const c of o){const u=i[c],d=s.data[c];l.push({key:{status:"valid",value:c},value:u._parse(new Ss(s,d,s.path,c)),alwaysSet:c in s.data})}if(this._def.catchall instanceof ks){const c=this._def.unknownKeys;if(c==="passthrough")for(const u of a)l.push({key:{status:"valid",value:u},value:{status:"valid",value:s.data[u]}});else if(c==="strict")a.length>0&&(z(s,{code:L.unrecognized_keys,keys:a}),r.dirty());else if(c!=="strip")throw new Error("Internal ZodObject error: invalid unknownKeys value.")}else{const c=this._def.catchall;for(const u of a){const d=s.data[u];l.push({key:{status:"valid",value:u},value:c._parse(new Ss(s,d,s.path,u)),alwaysSet:u in s.data})}}return s.common.async?Promise.resolve().then(async()=>{const c=[];for(const u of l){const d=await u.key,h=await u.value;c.push({key:d,value:h,alwaysSet:u.alwaysSet})}return c}).then(c=>Ht.mergeObjectSync(r,c)):Ht.mergeObjectSync(r,l)}get shape(){return this._def.shape()}strict(t){return G.errToObj,new $e({...this._def,unknownKeys:"strict",...t!==void 0?{errorMap:(n,r)=>{var i,o;const s=((o=(i=this._def).errorMap)==null?void 0:o.call(i,n,r).message)??r.defaultError;return n.code==="unrecognized_keys"?{message:G.errToObj(t).message??s}:{message:s}}}:{}})}strip(){return new $e({...this._def,unknownKeys:"strip"})}passthrough(){return new $e({...this._def,unknownKeys:"passthrough"})}extend(t){return new $e({...this._def,shape:()=>({...this._def.shape(),...t})})}merge(t){return new $e({unknownKeys:t._def.unknownKeys,catchall:t._def.catchall,shape:()=>({...this._def.shape(),...t._def.shape()}),typeName:se.ZodObject})}setKey(t,n){return this.augment({[t]:n})}catchall(t){return new $e({...this._def,catchall:t})}pick(t){const n={};for(const r of ge.objectKeys(t))t[r]&&this.shape[r]&&(n[r]=this.shape[r]);return new $e({...this._def,shape:()=>n})}omit(t){const n={};for(const r of ge.objectKeys(this.shape))t[r]||(n[r]=this.shape[r]);return new $e({...this._def,shape:()=>n})}deepPartial(){return Ki(this)}partial(t){const n={};for(const r of ge.objectKeys(this.shape)){const s=this.shape[r];t&&!t[r]?n[r]=s:n[r]=s.optional()}return new $e({...this._def,shape:()=>n})}required(t){const n={};for(const r of ge.objectKeys(this.shape))if(t&&!t[r])n[r]=this.shape[r];else{let i=this.shape[r];for(;i instanceof ys;)i=i._def.innerType;n[r]=i}return new $e({...this._def,shape:()=>n})}keyof(){return xC(ge.objectKeys(this.shape))}}$e.create=(e,t)=>new $e({shape:()=>e,unknownKeys:"strip",catchall:ks.create(),typeName:se.ZodObject,...ce(t)});$e.strictCreate=(e,t)=>new $e({shape:()=>e,unknownKeys:"strict",catchall:ks.create(),typeName:se.ZodObject,...ce(t)});$e.lazycreate=(e,t)=>new $e({shape:e,unknownKeys:"strip",catchall:ks.create(),typeName:se.ZodObject,...ce(t)});class ud extends pe{_parse(t){const{ctx:n}=this._processInputParams(t),r=this._def.options;function s(i){for(const a of i)if(a.result.status==="valid")return a.result;for(const a of i)if(a.result.status==="dirty")return n.common.issues.push(...a.ctx.common.issues),a.result;const o=i.map(a=>new ur(a.ctx.common.issues));return z(n,{code:L.invalid_union,unionErrors:o}),re}if(n.common.async)return Promise.all(r.map(async i=>{const o={...n,common:{...n.common,issues:[]},parent:null};return{result:await i._parseAsync({data:n.data,path:n.path,parent:o}),ctx:o}})).then(s);{let i;const o=[];for(const l of r){const c={...n,common:{...n.common,issues:[]},parent:null},u=l._parseSync({data:n.data,path:n.path,parent:c});if(u.status==="valid")return u;u.status==="dirty"&&!i&&(i={result:u,ctx:c}),c.common.issues.length&&o.push(c.common.issues)}if(i)return n.common.issues.push(...i.ctx.common.issues),i.result;const a=o.map(l=>new ur(l));return z(n,{code:L.invalid_union,unionErrors:a}),re}}get options(){return this._def.options}}ud.create=(e,t)=>new ud({options:e,typeName:se.ZodUnion,...ce(t)});function wm(e,t){const n=Gr(e),r=Gr(t);if(e===t)return{valid:!0,data:e};if(n===q.object&&r===q.object){const s=ge.objectKeys(t),i=ge.objectKeys(e).filter(a=>s.indexOf(a)!==-1),o={...e,...t};for(const a of i){const l=wm(e[a],t[a]);if(!l.valid)return{valid:!1};o[a]=l.data}return{valid:!0,data:o}}else if(n===q.array&&r===q.array){if(e.length!==t.length)return{valid:!1};const s=[];for(let i=0;i<e.length;i++){const o=e[i],a=t[i],l=wm(o,a);if(!l.valid)return{valid:!1};s.push(l.data)}return{valid:!0,data:s}}else return n===q.date&&r===q.date&&+e==+t?{valid:!0,data:e}:{valid:!1}}class dd extends pe{_parse(t){const{status:n,ctx:r}=this._processInputParams(t),s=(i,o)=>
vendor: 4,155 bytes, line 232
232{if(Jw(i)||Jw(o))return re;const a=wm(i.value,o.value);return a.valid?((Xw(i)||Xw(o))&&n.dirty(),{status:n.value,value:a.data}):(z(r,{code:L.invalid_intersection_types}),re)};return r.common.async?Promise.all([this._def.left._parseAsync({data:r.data,path:r.path,parent:r}),this._def.right._parseAsync({data:r.data,path:r.path,parent:r})]).then(([i,o])=>s(i,o)):s(this._def.left._parseSync({data:r.data,path:r.path,parent:r}),this._def.right._parseSync({data:r.data,path:r.path,parent:r}))}}dd.create=(e,t,n)=>new dd({left:e,right:t,typeName:se.ZodIntersection,...ce(n)});class xi extends pe{_parse(t){const{status:n,ctx:r}=this._processInputParams(t);if(r.parsedType!==q.array)return z(r,{code:L.invalid_type,expected:q.array,received:r.parsedType}),re;if(r.data.length<this._def.items.length)return z(r,{code:L.too_small,minimum:this._def.items.length,inclusive:!0,exact:!1,type:"array"}),re;!this._def.rest&&r.data.length>this._def.items.length&&(z(r,{code:L.too_big,maximum:this._def.items.length,inclusive:!0,exact:!1,type:"array"}),n.dirty());const i=[...r.data].map((o,a)=>{const l=this._def.items[a]||this._def.rest;return l?l._parse(new Ss(r,o,r.path,a)):null}).filter(o=>!!o);return r.common.async?Promise.all(i).then(o=>Ht.mergeArray(n,o)):Ht.mergeArray(n,i)}get items(){return this._def.items}rest(t){return new xi({...this._def,rest:t})}}xi.create=(e,t)=>{if(!Array.isArray(e))throw new Error("You must pass an array of schemas to z.tuple([ ... ])");return new xi({items:e,typeName:se.ZodTuple,rest:null,...ce(t)})};class lx extends pe{get keySchema(){return this._def.keyType}get valueSchema(){return this._def.valueType}_parse(t){const{status:n,ctx:r}=this._processInputParams(t);if(r.parsedType!==q.map)return z(r,{code:L.invalid_type,expected:q.map,received:r.parsedType}),re;const s=this._def.keyType,i=this._def.valueType,o=[...r.data.entries()].map(([a,l],c)=>({key:s._parse(new Ss(r,a,r.path,[c,"key"])),value:i._parse(new Ss(r,l,r.path,[c,"value"]))}));if(r.common.async){const a=new Map;return Promise.resolve().then(async()=>{for(const l of o){const c=await l.key,u=await l.value;if(c.status==="aborted"||u.status==="aborted")return re;(c.status==="dirty"||u.status==="dirty")&&n.dirty(),a.set(c.value,u.value)}return{status:n.value,value:a}})}else{const a=new Map;for(const l of o){const c=l.key,u=l.value;if(c.status==="aborted"||u.status==="aborted")return re;(c.status==="dirty"||u.status==="dirty")&&n.dirty(),a.set(c.value,u.value)}return{status:n.value,value:a}}}}lx.create=(e,t,n)=>new lx({valueType:t,keyType:e,typeName:se.ZodMap,...ce(n)});class jl extends pe{_parse(t){const{status:n,ctx:r}=this._processInputParams(t);if(r.parsedType!==q.set)return z(r,{code:L.invalid_type,expected:q.set,received:r.parsedType}),re;const s=this._def;s.minSize!==null&&r.data.size<s.minSize.value&&(z(r,{code:L.too_small,minimum:s.minSize.value,type:"set",inclusive:!0,exact:!1,message:s.minSize.message}),n.dirty()),s.maxSize!==null&&r.data.size>s.maxSize.value&&(z(r,{code:L.too_big,maximum:s.maxSize.value,type:"set",inclusive:!0,exact:!1,message:s.maxSize.message}),n.dirty());const i=this._def.valueType;function o(l){const c=new Set;for(const u of l){if(u.status==="aborted")return re;u.status==="dirty"&&n.dirty(),c.add(u.value)}return{status:n.value,value:c}}const a=[...r.data.values()].map((l,c)=>i._parse(new Ss(r,l,r.path,c)));return r.common.async?Promise.all(a).then(l=>o(l)):o(a)}min(t,n){return new jl({...this._def,minSize:{value:t,message:G.toString(n)}})}max(t,n){return new jl({...this._def,maxSize:{value:t,message:G.toString(n)}})}size(t,n){return this.min(t,n).max(t,n)}nonempty(t){return this.min(1,t)}}jl.create=(e,t)=>new jl({valueType:e,minSize:null,maxSize:null,typeName:se.ZodSet,...ce(t)});class cx extends pe{get schema(){return this._def.getter()}_parse(t){const{ctx:n}=this._processInputParams(t);return this._def.getter()._parse({data:n.data,path:n.path,parent:n})}}cx.create=(e,t)=>new cx({getter:e,typeName:se.ZodLazy,...ce(t)});class ux extends pe{_parse(t){if(t.data!==this._def.value){const n=this._getOrReturnCtx(t);return z(n,{received:n.data,code:L.invalid_literal,expected:this._def.value}),re}
vendor: 4,144 bytes, line 232
232return{status:"valid",value:t.data}}get value(){return this._def.value}}ux.create=(e,t)=>new ux({value:e,typeName:se.ZodLiteral,...ce(t)});function xC(e,t){return new Wo({values:e,typeName:se.ZodEnum,...ce(t)})}class Wo extends pe{_parse(t){if(typeof t.data!="string"){const n=this._getOrReturnCtx(t),r=this._def.values;return z(n,{expected:ge.joinValues(r),received:n.parsedType,code:L.invalid_type}),re}if(this._cache||(this._cache=new Set(this._def.values)),!this._cache.has(t.data)){const n=this._getOrReturnCtx(t),r=this._def.values;return z(n,{received:n.data,code:L.invalid_enum_value,options:r}),re}return dn(t.data)}get options(){return this._def.values}get enum(){const t={};for(const n of this._def.values)t[n]=n;return t}get Values(){const t={};for(const n of this._def.values)t[n]=n;return t}get Enum(){const t={};for(const n of this._def.values)t[n]=n;return t}extract(t,n=this._def){return Wo.create(t,{...this._def,...n})}exclude(t,n=this._def){return Wo.create(this.options.filter(r=>!t.includes(r)),{...this._def,...n})}}Wo.create=xC;class dx extends pe{_parse(t){const n=ge.getValidEnumValues(this._def.values),r=this._getOrReturnCtx(t);if(r.parsedType!==q.string&&r.parsedType!==q.number){const s=ge.objectValues(n);return z(r,{expected:ge.joinValues(s),received:r.parsedType,code:L.invalid_type}),re}if(this._cache||(this._cache=new Set(ge.getValidEnumValues(this._def.values))),!this._cache.has(t.data)){const s=ge.objectValues(n);return z(r,{received:r.data,code:L.invalid_enum_value,options:s}),re}return dn(t.data)}get enum(){return this._def.values}}dx.create=(e,t)=>new dx({values:e,typeName:se.ZodNativeEnum,...ce(t)});class fd extends pe{unwrap(){return this._def.type}_parse(t){const{ctx:n}=this._processInputParams(t);if(n.parsedType!==q.promise&&n.common.async===!1)return z(n,{code:L.invalid_type,expected:q.promise,received:n.parsedType}),re;const r=n.parsedType===q.promise?n.data:Promise.resolve(n.data);return dn(r.then(s=>this._def.type.parseAsync(s,{path:n.path,errorMap:n.common.contextualErrorMap})))}}fd.create=(e,t)=>new fd({type:e,typeName:se.ZodPromise,...ce(t)});class Ho extends pe{innerType(){return this._def.schema}sourceType(){return this._def.schema._def.typeName===se.ZodEffects?this._def.schema.sourceType():this._def.schema}_parse(t){const{status:n,ctx:r}=this._processInputParams(t),s=this._def.effect||null,i={addIssue:o=>{z(r,o),o.fatal?n.abort():n.dirty()},get path(){return r.path}};if(i.addIssue=i.addIssue.bind(i),s.type==="preprocess"){const o=s.transform(r.data,i);if(r.common.async)return Promise.resolve(o).then(async a=>{if(n.value==="aborted")return re;const l=await this._def.schema._parseAsync({data:a,path:r.path,parent:r});return l.status==="aborted"?re:l.status==="dirty"||n.value==="dirty"?Na(l.value):l});{if(n.value==="aborted")return re;const a=this._def.schema._parseSync({data:o,path:r.path,parent:r});return a.status==="aborted"?re:a.status==="dirty"||n.value==="dirty"?Na(a.value):a}}if(s.type==="refinement"){const o=a=>{const l=s.refinement(a,i);if(r.common.async)return Promise.resolve(l);if(l instanceof Promise)throw new Error("Async refinement encountered during synchronous parse operation. Use .parseAsync instead.");return a};if(r.common.async===!1){const a=this._def.schema._parseSync({data:r.data,path:r.path,parent:r});return a.status==="aborted"?re:(a.status==="dirty"&&n.dirty(),o(a.value),{status:n.value,value:a.value})}else return this._def.schema._parseAsync({data:r.data,path:r.path,parent:r}).then(a=>a.status==="aborted"?re:(a.status==="dirty"&&n.dirty(),o(a.value).then(()=>({status:n.value,value:a.value}))))}if(s.type==="transform")if(r.common.async===!1){const o=this._def.schema._parseSync({data:r.data,path:r.path,parent:r});if(!zo(o))return re;const a=s.transform(o.value,i);if(a instanceof Promise)throw new Error("Asynchronous transform encountered during synchronous parse operation. Use .parseAsync instead.");return{status:n.value,value:a}}else return this._def.schema._parseAsync({data:r.data,path:r.path,parent:r}).then(o=>zo(o)?Promise.resolve(s.transform(o.value,i)).then(a=>({status:n.value,value:a})):re);ge.assertNever(s)}}
232Ho.create=(e,t,n)=>new Ho({schema:e,typeName:se.ZodEffects,effect:t,...ce(n)});Ho.createWithPreprocess=(e,t,n)=>new Ho({schema:t,effect:{type:"preprocess",transform:e},typeName:se.ZodEffects,...ce(n)});class ys extends pe{_parse(t){return this._getType(t)===q.undefined?dn(void 0):this._def.innerType._parse(t)}unwrap(){return this._def.innerType}}ys.create=(e,t)=>new ys({innerType:e,typeName:se.ZodOptional,...ce(t)});class Ko extends pe{_parse(t){return this._getType(t)===q.null?dn(null):this._def.innerType._parse(t)}unwrap(){return this._def.innerType}}Ko.create=(e,t)=>new Ko({innerType:e,typeName:se.ZodNullable,...ce(t)});class xm extends pe{_parse(t){const{ctx:n}=this._processInputParams(t);let r=n.data;return n.parsedType===q.undefined&&(r=this._def.defaultValue()),this._def.innerType._parse({data:r,path:n.path,parent:n})}removeDefault(){return this._def.innerType}}xm.create=(e,t)=>new xm({innerType:e,typeName:se.ZodDefault,defaultValue:typeof t.default=="function"?t.default:()=>t.default,...ce(t)});class bm extends pe{_parse(t){const{ctx:n}=this._processInputParams(t),r={...n,common:{...n.common,issues:[]}},s=this._def.innerType._parse({data:r.data,path:r.path,parent:{...r}});return ld(s)?s.then(i=>({status:"valid",value:i.status==="valid"?i.value:this._def.catchValue({get error(){return new ur(r.common.issues)},input:r.data})})):{status:"valid",value:s.status==="valid"?s.value:this._def.catchValue({get error(){return new ur(r.common.issues)},input:r.data})}}removeCatch(){return this._def.innerType}}bm.create=(e,t)=>new bm({innerType:e,typeName:se.ZodCatch,catchValue:typeof t.catch=="function"?t.catch:()=>t.catch,...ce(t)});class fx extends pe{_parse(t){if(this._getType(t)!==q.nan){const r=this._getOrReturnCtx(t);return z(r,{code:L.invalid_type,expected:q.nan,received:r.parsedType}),re}return{status:"valid",value:t.data}}}fx.create=e=>new fx({typeName:se.ZodNaN,...ce(e)});class g6 extends pe{_parse(t){const{ctx:n}=this._processInputParams(t),r=n.data;return this._def.type._parse({data:r,path:n.path,parent:n})}unwrap(){return this._def.type}}class Pv extends pe{_parse(t){const{status:n,ctx:r}=this._processInputParams(t);if(r.common.async)return(async()=>{const i=await this._def.in._parseAsync({data:r.data,path:r.path,parent:r});return i.status==="aborted"?re:i.status==="dirty"?(n.dirty(),Na(i.value)):this._def.out._parseAsync({data:i.value,path:r.path,parent:r})})();{const s=this._def.in._parseSync({data:r.data,path:r.path,parent:r});return s.status==="aborted"?re:s.status==="dirty"?(n.dirty(),{status:"dirty",value:s.value}):this._def.out._parseSync({data:s.value,path:r.path,parent:r})}}static create(t,n){return new Pv({in:t,out:n,typeName:se.ZodPipeline})}}class _m extends pe{_parse(t){const n=this._def.innerType._parse(t),r=s=>(zo(s)&&(s.value=Object.freeze(s.value)),s);return ld(n)?n.then(s=>r(s)):r(n)}unwrap(){return this._def.innerType}}_m.create=(e,t)=>new _m({innerType:e,typeName:se.ZodReadonly,...ce(t)});$e.lazycreate;var se;(function(e){e.ZodString="ZodString",e.ZodNumber="ZodNumber",e.ZodNaN="ZodNaN",e.ZodBigInt="ZodBigInt",e.ZodBoolean="ZodBoolean",e.ZodDate="ZodDate",e.ZodSymbol="ZodSymbol",e.ZodUndefined="ZodUndefined",e.ZodNull="ZodNull",e.ZodAny="ZodAny",e.ZodUnknown="ZodUnknown",e.ZodNever="ZodNever",e.ZodVoid="ZodVoid",e.ZodArray="ZodArray",e.ZodObject="ZodObject",e.ZodUnion="ZodUnion",e.ZodDiscriminatedUnion="ZodDiscriminatedUnion",e.ZodIntersection="ZodIntersection",e.ZodTuple="ZodTuple",e.ZodRecord="ZodRecord",e.ZodMap="ZodMap",e.ZodSet="ZodSet",e.ZodFunction="ZodFunction",e.ZodLazy="ZodLazy",e.ZodLiteral="ZodLiteral",e.ZodEnum="ZodEnum",e.ZodEffects="ZodEffects",e.ZodNativeEnum="ZodNativeEnum",e.ZodOptional="ZodOptional",e.ZodNullable="ZodNullable",e.ZodDefault="ZodDefault",e.ZodCatch="ZodCatch",e.ZodPromise="ZodPromise",e.ZodBranded="ZodBranded",e.ZodPipeline="ZodPipeline",e.ZodReadonly="ZodReadonly"})(se||(se={}));const tt=as.create;ks.create;sr.create;const jv=$e.create;$e.strictCreate;ud.create;dd.create;xi.create;Wo.create;fd.create;ys.create;Ko.create;const v6=jv({title:tt().trim().min(1,"Title is required").max(200,"Title must be less than 200 characters"),creator:tt().trim().min(1,"Creator is required").max(100,"Creator must be less than 100 characters"),description:tt().trim().min(1,"Description is required").max(2e3,"Description must be less than 2000 characters"),date:tt().trim().min(1,"Date is required").max(50,"Date must be less than 50 characters"),time:tt().trim().min(1,"Time is required").max(50,"Time must be less than 50 characters"),address:tt().trim().min(1,"Address is required").max(300,"Address must be less than 300 characters"),target_date:tt().refine(e=>{const t=new Date(e);return!isNaN(t.getTime())},"Invalid date format")}),y6=()=>{const[e,t]=w.useState(!0),[n,r]=w.useState([]),[s,i]=w.useState(null),[o,a]=w.useState(!1),[l,c]=w.useState(!1),u=Fn(),{toast:d}=Wl();w.useEffect(()=>{h()},[]);const h=async()=>{const{data:{session:y}}=await X.auth.getSession();if(!y){u("/auth");return}const{data:m,error:v}=await X.from("user_roles").select("role").eq("user_id",y.user.id).eq("role","admin").single();if(v||!m){d({title:"Access Denied",description:"You do not have admin privileges",variant:"destructive"}),u("/");return}c(!0),t(!1),p()},p=async()=>{const{data:y,error:m}=await X.from("events").select("*");m?d({title:"Error",description:m.message,variant:"destructive"}):(r(y||[]),y&&y.length>0&&i(y[0]))},b=async()=>{await X.auth.signOut(),u("/auth")},g=async y=>{if(!y.target.files||!y.target.files[0]||!s)return;const m=y.target.files[0];
232if(!["image/jpeg","image/jpg","image/png","image/gif","image/webp"].includes(m.type)){d({title:"Invalid file type",description:"Please upload a JPG, PNG, GIF, or WebP image",variant:"destructive"});return}if(m.size>5*1024*1024){d({title:"File too large",description:"Image must be less than 5MB",variant:"destructive"});return}a(!0);try{const{data:{session:_}}=await X.auth.getSession();if(!_)throw new Error("Not authenticated");const S=m.name.split(".").pop(),k=`${_.user.id}/${s.id}-${Date.now()}.${S}`,{error:E}=await X.storage.from("event-images").upload(k,m,{upsert:!0});if(E)throw E;const{data:{publicUrl:T}}=X.storage.from("event-images").getPublicUrl(k);i({...s,background_image_url:T}),d({title:"Success",description:"Image uploaded successfully"})}catch(_){d({title:"Error",description:_.message,variant:"destructive"})}finally{a(!1)}},x=async y=>{if(y.preventDefault(),!s)return;const m=s.target_date.includes("T")?new Date(s.target_date).toISOString():s.target_date;try{v6.parse({title:s.title,creator:s.creator,description:s.description,date:s.date,time:s.time,address:s.address,target_date:m})}catch(_){if(_ instanceof ur){d({title:"Validation Error",description:_.errors[0].message,variant:"destructive"});return}}const{error:v}=await X.from("events").update({title:s.title.trim(),creator:s.creator.trim(),description:s.description.trim(),date:s.date.trim(),time:s.time.trim(),address:s.address.trim(),background_image_url:s.background_image_url,target_date:m}).eq("id",s.id);v?d({title:"Error",description:v.message,variant:"destructive"}):(d({title:"Success",description:"Event updated successfully"}),p())};return e?f.jsx("div",{className:"min-h-screen flex items-center justify-center",children:"Loading..."}):l?f.jsxs("div",{className:"min-h-screen bg-white p-8",children:[f.jsx(lr,{title:"Admin Dashboard",description:"Manage events and content for your event platform"}),f.jsxs("div",{className:"max-w-4xl mx-auto",children:[f.jsxs("div",{className:"flex justify-between items-center mb-8",children:[f.jsx("h1",{className:"text-4xl font-normal text-[#1A1A1A] tracking-[-0.02em]",children:"Event CMS"}),f.jsx(ad,{onClick:b,variant:"outline",children:"Sign Out"})]}),s&&f.jsxs("form",{onSubmit:x,className:"space-y-6",children:[f.jsxs("div",{children:[f.jsx("label",{className:"text-[#1A1A1A] text-sm font-normal uppercase mb-2 block",children:"Event Title"}),f.jsx(Kn,{value:s.title,onChange:y=>i({...s,title:y.target.value}),className:"border-[#1A1A1A]"})]}),f.jsxs("div",{children:[f.jsx("label",{className:"text-[#1A1A1A] text-sm font-normal uppercase mb-2 block",children:"Creator"}),f.jsx(Kn,{value:s.creator,onChange:y=>i({...s,creator:y.target.value}),className:"border-[#1A1A1A]"})]}),f.jsxs("div",{children:[f.jsx("label",{className:"text-[#1A1A1A] text-sm font-normal uppercase mb-2 block",children:"Description"}),f.jsx(vC,{value:s.description,onChange:y=>i({...s,description:y.target.value}),className:"border-[#1A1A1A] min-h-[120px]"})]}),f.jsxs("div",{className:"grid grid-cols-2 gap-4",children:[f.jsxs("div",{children:[f.jsx("label",{className:"text-[#1A1A1A] text-sm font-normal uppercase mb-2 block",children:"Date"}),f.jsx(Kn,{value:s.date,onChange:y=>i({...s,date:y.target.value}),className:"border-[#1A1A1A]"})]}),f.jsxs("div",{children:[f.jsx("label",{className:"text-[#1A1A1A] text-sm font-normal uppercase mb-2 block",children:"Time"}),f.jsx(Kn,{value:s.time,onChange:y=>i({...s,time:y.target.value}),className:"border-[#1A1A1A]"})]})]}),f.jsxs("div",{children:[f.jsx("label",{className:"text-[#1A1A1A] text-sm font-normal uppercase mb-2 block",children:"Address"}),f.jsx(Kn,{value:s.address,onChange:y=>i({...s,address:y.target.value}),className:"border-[#1A1A1A]"})]}),f.jsxs("div",{children:[f.jsx("label",{className:"text-[#1A1A1A] text-sm font-normal uppercase mb-2 block",children:"Backgroun
232d Image"}),s.background_image_url&&f.jsx("img",{src:s.background_image_url,alt:"Current background",className:"w-full h-32 object-cover mb-2 rounded"}),f.jsx(Kn,{type:"file",accept:"image/*",onChange:g,disabled:o,className:"border-[#1A1A1A]"}),o&&f.jsx("p",{className:"text-sm text-[#1A1A1A] mt-1",children:"Uploading..."})]}),f.jsxs("div",{children:[f.jsx("label",{className:"text-[#1A1A1A] text-sm font-normal uppercase mb-2 block",children:"Target Date (YYYY-MM-DD HH:MM:SS)"}),f.jsx(Kn,{type:"datetime-local",value:s.target_date.slice(0,16),onChange:y=>i({...s,target_date:y.target.value}),className:"border-[#1A1A1A]"})]}),f.jsx(ad,{type:"submit",className:"w-full bg-[#1A1A1A] text-white hover:bg-opacity-90",children:"Save Changes"})]})]})]}):null},w6=({event:e,isCreated:t,onDelete:n})=>{const r=Fn(),s=async i=>{i.stopPropagation(),window.confirm("Are you sure you want to delete this event?")&&(n==null||n(e.id))};return f.jsxs("div",{className:"relative cursor-pointer group",onClick:()=>r(t?`/event/${e.id}/edit`:`/event/${e.id}`),children:[f.jsx("div",{className:"overflow-hidden mb-3",children:f.jsx("div",{className:"aspect-[4/3] bg-gray-300 bg-cover bg-center transition-transform duration-500 ease-out group-hover:scale-110",style:{backgroundImage:`url(${e.background_image_url})`}})}),f.jsxs("div",{className:"absolute top-4 left-4 flex flex-col gap-0",children:[f.jsx("div",{className:"bg-white border border-black px-3 h-[23px] flex items-center",children:f.jsx("div",{className:"text-[11px] font-medium uppercase leading-none",children:e.date})}),f.jsx("div",{className:"bg-white border border-t-0 border-black px-3 h-[23px] flex items-center",children:f.jsx("div",{className:"text-[11px] font-medium leading-none",children:e.time})})]}),t&&f.jsx("button",{onClick:s,className:"absolute top-4 right-4 bg-white border border-black p-2 hover:bg-red-500 hover:text-white hover:border-red-500 transition-colors opacity-0 group-hover:opacity-100","aria-label":"Delete event",children:f.jsx(mk,{className:"w-4 h-4"})}),f.jsx("h3",{className:"text-base font-medium",children:e.title})]})},x6=()=>{const[e,t]=w.useState(null),[n,r]=w.useState([]),[s,i]=w.useState([]),[o,a]=w.useState(!0),[l,c]=w.useState("created"),[u,d]=w.useState({width:0,transform:"translateX(0)"}),h=w.useRef(null),p=w.useRef(null),b=Fn();w.useEffect(()=>{X.auth.getSession().then(({data:{session:v}})=>{if(!v){b("/");return}t(v.user)});const{data:{subscription:m}}=X.auth.onAuthStateChange((v,_)=>{if(!_){b("/");return}t(_.user)});return()=>m.unsubscribe()},[b]),w.useEffect(()=>{e&&g()},[e]),w.useEffect(()=>{const m=()=>{l==="created"&&h.current?d({width:h.current.offsetWidth,transform:"translateX(0)"}):l==="registered"&&p.current&&h.current&&d({width:p.current.offsetWidth,transform:`translateX(${h.current.offsetWidth}px)`})};return m(),window.addEventListener("resize",m),()=>window.removeEventListener("resize",m)},[l,n.length,s.length]);const g=async()=>{if(e){a(!0);try{const{data:m,error:v}=await X.from("events").select("id, title, date, time, background_image_url").eq("created_by",e.id).order("target_date",{ascending:!0});if(v)throw v;r(m||[]);const{data:_,error:S}=await X.from("event_registrations").select(`
233          event_id,
234          events (
235            id,
236            title,
237            date,
238            time,
239            background_image_url
240          )
241        `).eq("user_id",e.id);if(S)throw S;const k=(_==null?void 0:_.map(E=>E.events).filter(Boolean))||[];i(k)}catch{}finally{a(!1)}}},x=async m=>{try{const{error:v}=await X.from("events").delete().eq("id",m);if(v)throw v;Ne.success("Event deleted successfully"),g()}catch{Ne.error("Failed to delete event")}},y=l==="created"?n:s;return f.jsxs(f.Fragment,{children:[f.jsx(lr,{title:"My Events",description:"Manage your created events and view events you've registered for"}),f.jsx("link",{href:"https://fonts.googleapis.com/css2?family=Host+Grotesk:wght@400;500;600;700&display=swap",rel:"stylesheet"}),f.jsxs("div",{className:"min-h-screen bg-white",children:[f.jsx(vi,{}),f.jsx("div",{className:"pt-32 pb-20 px-4 md:px-8",children:f.jsxs("div",{children:[f.jsx("h1",{className:"text-3xl sm:text-4xl md:text-5xl lg:text-6xl font-medium leading-tight mb-8",children:"My Events"}),f.jsxs("div",{className:"relative flex gap-0 mb-12",children:[f.jsx("div",{className:"absolute top-0 left-0 h-full bg-[#ff6bff] border border-black transition-all duration-300 ease-out pointer-events-none",style:{width:`${u.width}px`,transform:u.transform}}),f.jsxs("button",{ref:h,onClick:()=>
241c("created"),className:"relative z-10 px-6 py-3 text-[11px] font-medium uppercase text-black border border-black transition-colors max-sm:flex-1 bg-transparent",children:["Created by me (",n.length,")"]}),f.jsxs("button",{ref:p,onClick:()=>c("registered"),className:"relative z-10 px-6 py-3 text-[11px] font-medium uppercase text-black border border-l-0 border-black transition-colors max-sm:flex-1 bg-transparent",children:["Registered (",s.length,")"]})]}),f.jsx("div",{className:"grid grid-cols-1 md:grid-cols-2 xl:grid-cols-3 2xl:grid-cols-4 gap-8",children:o?f.jsx("div",{className:"col-span-full text-center py-12",children:"Loading events..."}):y.length===0?f.jsx("div",{className:"col-span-full text-center py-12",children:l==="created"?"You haven't created any events yet":"You haven't registered for any events yet"}):y.map(m=>f.jsx(w6,{event:m,isCreated:l==="created",onDelete:l==="created"?x:void 0},m.id))})]})})]})]})},bC=e=>{const[t,n]=w.useState(!1),r=w.useRef(null);return w.useEffect(()=>{{console.warn("Google Maps API key not configured. Place autocomplete will not work.");return}},[]),w.useEffect(()=>{if(!t||!e.current||!window.google)return;const i=window.google;return r.current=new i.maps.places.Autocomplete(e.current,{types:["establishment","geocode"],fields:["formatted_address","name","geometry"]}),()=>{r.current&&window.google&&window.google.maps.event.clearInstanceListeners(r.current)}},[t,e]),{isLoaded:t,onPlaceSelected:i=>{r.current&&r.current.addListener("place_changed",()=>{var a;const o=(a=r.current)==null?void 0:a.getPlace();o&&i(o)})}}},b6=jv({eventName:tt().trim().min(1,"Event name is required").max(200,"Event name must be less than 200 characters"),startTime:tt().regex(/^([0-1]?[0-9]|2[0-3]):[0-5][0-9]$/,"Start time must be in HH:MM format (e.g., 15:00)"),endTime:tt().regex(/^([0-1]?[0-9]|2[0-3]):[0-5][0-9]$/,"End time must be in HH:MM format (e.g., 16:00)"),location:tt().trim().min(1,"Location is required").max(300,"Location must be less than 300 characters"),description:tt().trim().min(1,"Description is required").max(2e3,"Description must be less than 2000 characters")}),_6=()=>{const[e,t]=w.useState(""),[n,r]=w.useState(),[s,i]=w.useState(""),[o,a]=w.useState(),[l,c]=w.useState(""),[u,d]=w.useState(""),[h,p]=w.useState(""),[b,g]=w.useState(null),[x,y]=w.useState(null),[m,v]=w.useState(null),[_,S]=w.useState(!1),[k,E]=w.useState(!1),T=w.useRef(null),P=w.useRef(null),A=Fn(),{onPlaceSelected:B}=bC(T);w.useEffect(()=>{X.auth.getSession().then(({data:{session:U}})=>{v((U==null?void 0:U.user)||null),U!=null&&U.user||E(!0)});const{data:{subscription:R}}=X.auth.onAuthStateChange((U,V)=>{v((V==null?void 0:V.user)||null),V!=null&&V.user?E(!1):E(!0)});return()=>R.unsubscribe()},[]),w.useEffect(()=>{B(R=>{const U=R.formatted_address||R.name||"";d(U)})},[B]);const I=R=>{var V;const U=(V=R.target.files)==null?void 0:V[0];if(U){if(!["image/jpeg","image/jpg","image/png","image/gif","image/webp"].includes(U.type)){Ne.error("Please upload a JPG, PNG, GIF, or WebP image");return}if(U.size>5*1024*1024){Ne.error("Image must be less than 5MB");return}y(U);const C=new FileReader;C.onloadend=()=>{g(C.result)},C.readAsDataURL(U)}},Z=async()=>{var Q;if(!m){E(!0);return}if(!n){Ne.error("Please select a start date");return}if(!o){Ne.error("Please select an end date");return}if(!x){Ne.error("Please add an event image");return}const R=b6.safeParse({eventName:e,startTime:s,endTime:l,location:u,description:h});if(!R.success){const Y=R.error.errors[0];Ne.error(Y.message);return}const U=new Date(n),[V,O]=s.split(":");U.setHours(parseInt(V),parseInt(O),0,0);const C=new Date(o),[j,$]=l.split(":");if(C.setHours(parseInt(j),parseInt($),0,0),C<=U){Ne.error("End date/time must be after start date/time");return}S(!0);try{const Y=x.name.split(".").pop(),W=`${`${Math.random()}.${Y}`}`,{error:le}=await X.storage.from("event-images").upload(W,x);if(le)throw le;const{data:{publicUrl:xe}}=X.storage.from("event-images").getPublicUrl(W),te=new Date(n),[$n,Gt]=s.split(":");te.setHours(parseInt($n)||0,parseInt(Gt)||0);const Qt=vt(n,"MMMM dd, yyyy"),ot=`${s} - ${l}`,{data:It}=await X.from("profiles").select("display_name").eq("user_id",m.id).single(),Zt=(It==null?void 0:It.display_name)||((Q=m.email)==null?void 0:Q.split("@")[0])||"Anonymous",{error:fr}=await X.from("events").insert({title:e,description:h,date:Qt,time:ot,address:u,background_image_url:xe,target_date:te.toISOString(),creator:Zt});if(fr)throw fr;Ne.success("Event created successfully!"),A("/my-events")}catch{Ne.error("Failed to create event. Please try again.")}finally{S(!1)}};return f.jsxs(f.Fragment,{children:[f.jsx(lr,{title:"Create Event",description:"Create and publish a new event for your community to discover and join"}),f.jsx(nf,{isOpen:k,onClose:()=>E(!1)}),f.jsxs("div",{className:"min-h-screen bg-white",children:[f.jsx(vi,{}),m?f.jsx("div",{className:"max-w-7xl mx-auto pt-24 md:pt-32 pb-8 md:pb-16 px-4 md:px-8",children:f.jsxs("div",{className:"grid lg:grid-cols-2 gap-8 md:gap-16 items-start",children:[f.jsxs("div",{className:"flex flex-col gap-3 md:gap-4",children:[f.jsxs("label",{className:"w-full aspect-[4/3] border border-black bg-[#D9D9D9] flex items-center justify-center cursor-pointer hover:bg-[#CECECE
241] transition-colors",children:[b?f.jsx("img",{src:b,alt:"Event preview",className:"w-full h-full object-cover"}):f.jsx("span",{className:"text-black text-[11px] font-medium uppercase tracking-wider",children:"ADD IMAGE"}),f.jsx("input",{ref:P,type:"file",accept:"image/*",className:"hidden",onChange:I})]}),b&&f.jsx("button",{onClick:()=>{var R;return(R=P.current)==null?void 0:R.click()},className:"px-4 py-3 text-[13px] font-medium uppercase tracking-wider border border-black bg-white hover:bg-black hover:text-white transition-colors",children:"Change image"})]}),f.jsxs("div",{className:"space-y-4 md:space-y-6",children:[f.jsx("input",{type:"text",placeholder:"Event name",className:"w-full text-black text-[32px] md:text-[48px] lg:text-[56px] font-medium leading-none mb-4 md:mb-8 focus:outline-none bg-transparent border-none p-0 placeholder:text-[#C4C4C4]",value:e,onChange:R=>t(R.target.value)}),f.jsxs("div",{className:"relative",children:[f.jsxs("div",{className:"grid grid-cols-[80px_1fr_80px] md:grid-cols-[100px_1fr_100px] gap-0 border border-black mb-4 md:mb-6",children:[f.jsxs("div",{className:"flex items-center justify-start gap-1.5 md:gap-2 border-r border-black px-2 md:px-3 py-2 md:py-3",children:[f.jsx("div",{className:"w-1.5 md:w-2 h-1.5 md:h-2 bg-black rounded-full"}),f.jsx("span",{className:"text-[14px] md:text-[17px] font-medium",children:"Start"})]}),f.jsxs(Cl,{children:[f.jsx(Tl,{asChild:!0,children:f.jsx("button",{className:Te("px-2 md:px-4 py-2 md:py-3 text-[14px] md:text-[17px] text-left border-r border-black focus:outline-none bg-white",!n&&"text-[#C4C4C4]"),children:n?vt(n,"EEE, dd MMM"):"Thu, 28 Oct"})}),f.jsx(Uo,{className:"w-auto p-0",align:"start",children:f.jsx(wi,{mode:"single",selected:n,onSelect:r,initialFocus:!0,className:Te("p-3 pointer-events-auto")})})]}),f.jsx("input",{type:"text",placeholder:"15:00",className:"px-2 md:px-4 py-2 md:py-3 text-[14px] md:text-[17px] text-black text-center focus:outline-none placeholder:text-[#C4C4C4]",value:s,onChange:R=>i(R.target.value)})]}),f.jsxs("div",{className:"grid grid-cols-[80px_1fr_80px] md:grid-cols-[100px_1fr_100px] gap-0 border border-black",children:[f.jsxs("div",{className:"flex items-center justify-start gap-1.5 md:gap-2 border-r border-black px-2 md:px-3 py-2 md:py-3",children:[f.jsx("div",{className:"w-1.5 md:w-2 h-1.5 md:h-2 bg-black rounded-full"}),f.jsx("span",{className:"text-[14px] md:text-[17px] font-medium",children:"End"})]}),f.jsxs(Cl,{children:[f.jsx(Tl,{asChild:!0,children:f.jsx("button",{className:Te("px-2 md:px-4 py-2 md:py-3 text-[14px] md:text-[17px] text-left border-r border-black focus:outline-none bg-white",!o&&"text-[#C4C4C4]"),children:o?vt(o,"EEE, dd MMM"):"Thu, 28 Oct"})}),f.jsx(Uo,{className:"w-auto p-0",align:"start",children:f.jsx(wi,{mode:"single",selected:o,onSelect:a,initialFocus:!0,className:Te("p-3 pointer-events-auto")})})]}),f.jsx("input",{type:"text",placeholder:"16:00",className:"px-2 md:px-4 py-2 md:py-3 text-[14px] md:text-[17px] text-black text-center focus:outline-none placeholder:text-[#C4C4C4]",value:l,onChange:R=>c(R.target.value)})]})]}),f.jsx("input",{ref:T,type:"text",placeholder:"Add event location",className:"w-full px-3 md:px-4 py-2 md:py-3 text-[14px] md:text-[17px] text-black border border-black focus:outline-none placeholder:text-[#C4C4C4]",value:u,onChange:R=>d(R.target.value)}),f.jsx("textarea",{placeholder:"Add description",rows:6,className:"w-full px-3 md:px-4 py-2 md:py-3 text-[14px] md:text-[17px] text-black border border-black focus:outline-none resize-none placeholder:text-[#C4C4C4]",value:h,onChange:R=>p(R.target.value)}),f.jsxs("div",{className:"group flex items-center self-stretch relative overflow-hidden mt-4 md:mt-8",children:[f.jsxs("button",{onClick:Z,disabled:_,className:"flex h-[50px] justify-center items-center gap-2.5 border relative px-2.5 py-3.5 border-solid transition-all duration-300 ease-in-out w-[calc(100%-50px)] z-10 bg-[#1A1A1A] border-[#1A1A1A] group-hover:w-full group-hover:bg-[#FA76FF] group-hover:border-[#FA76FF] disabled:opacity-50 disabled:cursor-not-allowed","aria-label":"Create event",children:[f.jsx("span",{className:"text-white text-[13px] font-normal uppercase relative transition-colors duration-300 group-hover:text-black",children:_?"CREATING...":"CREATE EVENT"}),f.jsxs("svg",{width:"12",height:"12",viewBox:"0 0 12 12",fill:"none",xmlns:"http://www.w3.org/2000/svg",className:"absolute right-[18px] opacity-0 transition-all duration-300 ease-in-out group-hover:opacity-100","aria-hidden":"true",children:[f.jsx("path",{d:"M0.857178 6H10.3929",stroke:"#1A1A1A",strokeWidth:"1.5"}),f.jsx("path",{d:"M6.39282 10L10.3928 6L6.39282 2",stroke:"#1A1A1A",strokeWidth:"1.5"})]})]}),f.jsx("div",{className:"flex w-[50px] h-[50px] justify-center items-center border absolute right-0 bg-white rounded-[99px] border-solid border-[#1A1A1A] transition-all duration-300 ease-in-out group-hover:opacity-0 group-hover:scale-50 pointer-events-none z-0",children:f.jsxs("svg",{width:"12",height:"12",viewBox:"0 0 12 12",fill:"none",xmlns:"http://www.w3.org/2000/svg",className:"arrow-icon","aria-hidden":"true",children:[f.jsx("path",{d:"M0.857178 6H10.3929",stroke:"#1A1A1A",strokeWidth:"1.5"}),f.jsx("path",{d:"M6.39282 10L10.3928 6L6.39282 2",stroke:"#1A1A1A",strokeWidth:"1.5"})]})})]})]})]})}):null]})]})},S6=jv({eventName:tt().trim().min(1,"Event name is required").max(200,"Event name must be less than 200 characters"),startTime:tt().regex(/^([0-1]?[0-9]|2[0-3]):[0-5][0-9]$/,"Start time must be in HH:MM format (e.g., 15:00)"),endTime:tt().regex(/^([0-1]?[0-9]|2[0-3]):[0-5][0-9]$/,"End time must be in HH:MM format (e.g., 16:00)"),location:tt().trim().min(1,"Location is required").max(300,"Location must be less than 300 characters"),description:tt().trim().min(1,"Description is required").max(2e3,"Description must be less than 2000 characters")}),k6=()=>{const{id:e}=wS(),[t,n]=w.useState(""),[r,s]=w.useState(),[i,o]=w.useState(""),[a,l]=w.useState(),[c,u]=w.useState(""),[d,h]=w.useState(""),[p,b]=w.useState(""),[g,x]=w.useState(null),[y,m]=w.useState(null),[v,_]=w.useState(null),[S,k]=w.useState(!1),[E,T]=w.useState(!1),[P,A]=w.useState(!0),[B,I]=w.useState([]),Z=w.useRef(null),R=w.useRef(null),U=w.useRef(null),V=Fn(),{onPlaceSelected:O}=bC(Z);w.useEffect(()=>{X.auth.getSession().then(({data:{session:W}})=>{_((W==null?void 0:W.user)||null),W!=null&&W.user||T(!0)});const{data:{subscription:F}}=X.auth.onAuthStateChange((W,le)=>{_((le==null?void 0:le.user)||null),le!=null&&le.user?T(!1):T(!0)});return()=>F.unsubscribe()},[]),w.useEffect(()=>{v&&e&&C()},[v,e]),w.useEffect(()=>{O(F=>{const W=F.formatted_address||F.name||"";h(W)})},[O]),w.useEffect(()=>{const F=U.current;F&&(F.style.height="auto",F.style.height=`${F.scrollHeight}px`)},[t]);const C=async()=>{try{const{data:F,error:W}=await X.from("events").select("*").eq("id",e).single();if(W)throw W;if(!F){Ne.error("Event not found"),V("/my-events");return}if(F.created_by!==(v==null?void 0:v.id)){Ne.error("You do not have permission to edit this event"),V("/my-events");return}n(F.title),b(F.description),h(F.address),x(F.background_image_url);const le=new Date(F.target_date);s(le);const[xe,te]=F.time.split(" - ");o(xe),u(te),l(le),await j(),A(!1)}catch{Ne.error("Failed to load event"),V("/my-events")}},j=async()=>{try{const{data:F,error:W}=await X.from("event_registrations").select(`
242          registered_at,
243          profiles:user_id (display_name)
244        `).eq("event_id",e).order("registered_at",{ascending:!1});if(W)throw W;if(F){const le=F.map(xe=>{var te;
244return{display_name:((te=xe.profiles)==null?void 0:te.display_name)||"Anonymous",registered_at:xe.registered_at}});I(le)}}catch{}},$=F=>{var le;const W=(le=F.target.files)==null?void 0:le[0];if(W){if(!["image/jpeg","image/jpg","image/png","image/gif","image/webp"].includes(W.type)){Ne.error("Please upload a JPG, PNG, GIF, or WebP image");return}if(W.size>5*1024*1024){Ne.error("Image must be less than 5MB");return}m(W);const te=new FileReader;te.onloadend=()=>{x(te.result)},te.readAsDataURL(W)}},Q=async()=>{var Qt;if(!v){T(!0);return}if(!r){Ne.error("Please select a start date");return}if(!a){Ne.error("Please select an end date");return}const F=S6.safeParse({eventName:t,startTime:i,endTime:c,location:d,description:p});if(!F.success){const ot=F.error.errors[0];Ne.error(ot.message);return}const W=new Date(r),[le,xe]=i.split(":");W.setHours(parseInt(le),parseInt(xe),0,0);const te=new Date(a),[$n,Gt]=c.split(":");if(te.setHours(parseInt($n),parseInt(Gt),0,0),te<=W){Ne.error("End date/time must be after start date/time");return}k(!0);try{let ot=g;if(y){const ac=y.name.split(".").pop(),la=`${`${Math.random()}.${ac}`}`,{error:Bn}=await X.storage.from("event-images").upload(la,y);if(Bn)throw Bn;const{data:{publicUrl:mf}}=X.storage.from("event-images").getPublicUrl(la);ot=mf}const It=new Date(r),[Zt,fr]=i.split(":");It.setHours(parseInt(Zt)||0,parseInt(fr)||0);const aa=vt(r,"MMMM dd, yyyy"),Ci=`${i} - ${c}`,{data:Ds}=await X.from("profiles").select("display_name").eq("user_id",v.id).single(),Is=(Ds==null?void 0:Ds.display_name)||((Qt=v.email)==null?void 0:Qt.split("@")[0])||"Anonymous",{error:hr}=await X.from("events").update({title:t,description:p,date:aa,time:Ci,address:d,background_image_url:ot,target_date:It.toISOString(),creator:Is}).eq("id",e);if(hr)throw hr;Ne.success("Event updated successfully!"),V("/my-events")}catch{Ne.error("Failed to update event. Please try again.")}finally{k(!1)}},Y=async()=>{if(window.confirm("Are you sure you want to delete this event? This action cannot be undone."))try{const{error:F}=await X.from("events").delete().eq("id",e);if(F)throw F;Ne.success("Event deleted successfully"),V("/my-events")}catch{Ne.error("Failed to delete event")}};return P?f.jsxs("div",{className:"min-h-screen bg-white",children:[f.jsx(vi,{}),f.jsx("div",{className:"flex h-screen items-center justify-center",children:f.jsx("div",{className:"text-[#1A1A1A] text-2xl",children:"Loading..."})})]}):f.jsxs(f.Fragment,{children:[f.jsx(lr,{title:"Edit Event",description:"Update your event details and settings"}),f.jsx(nf,{isOpen:E,onClose:()=>T(!1)}),f.jsxs("div",{className:"min-h-screen bg-white",children:[f.jsx(vi,{}),v?f.jsx("div",{className:"max-w-7xl mx-auto pt-24 md:pt-32 pb-8 md:pb-16 px-4 md:px-8",children:f.jsxs("div",{className:"grid lg:grid-cols-2 gap-8 md:gap-16 items-start",children:[f.jsxs("div",{className:"flex flex-col gap-3 md:gap-4",children:[f.jsxs("label",{className:"w-full aspect-[4/3] border border-black bg-[#D9D9D9] flex items-center justify-center cursor-pointer hover:bg-[#CECECE] transition-colors",children:[g?f.jsx("img",{src:g,alt:"Event preview",className:"w-full h-full object-cover"}):f.jsx("span",{className:"text-black text-[11px] font-medium uppercase tracking-wider",children:"ADD IMAGE"}),f.jsx("input",{ref:R,type:"file",accept:"image/*",className:"hidden",onChange:$})]}),g&&f.jsx("button",{onClick:()=>{var F;return(F=R.current)==null?void 0:F.click()},className:"px-4 py-3 text-[13px] font-medium uppercase tracking-wider border border-black bg-white hover:bg-black hover:text-white transition-colors",children:"Change image"})]}),f.jsxs("div",{className:"space-y-4 md:space-y-6",children:[f.jsx("textarea",{ref:U,placeholder:"Event name",className:"w-full text-black text-[32px] md:text-[48px] lg:text-[56px] font-medium leading-[1.2] mb-4 md:mb-8 focus:outline-none bg-transparent border-none p-0 placeholder:text-[#C4C4C4] resize-none overflow-hidden whitespace-pre-wrap break-words",value:t,onChange:F=>n(F.target.value),rows:1}),f.jsxs("div",{className:"relative",children:[f.jsxs("div",{className:"grid grid-cols-[80px_1fr_80px] md:grid-cols-[100px_1fr_100px] gap-0 border border-black mb-4 md:mb-6",children:[f.jsxs("div",{className:"flex items-center justify-start gap-1.5 md:gap-2 border-r border-black px-2 md:px-3 py-2 md:py-3",children:[f.jsx("div",{className:"w-1.5 md:w-2 h-1.5 md:h-2 bg-black rounded-full"}),f.jsx("span",{className:"text-[14px] md:text-[17px] font-medium",children:"Start"})]}),f.jsxs(Cl,{children:[f.jsx(Tl,{asChild:!0,children:f.jsx("button",{className:Te("px-2 md:px-4 py-2 md:py-3 text-[14px] md:text-[17px] text-left border-r border-black focus:outline-none bg-white",!r&&"text-[#C4C4C4]"),children:r?vt(r,"EEE, dd MMM"):"Thu, 28 Oct"})}),f.jsx(Uo,{className:"w-auto p-0",align:"start",children:f.jsx(wi,{mode:"single",selected:r,onSelect:s,initialFocus:!0,className:Te("p-3 pointer-events-auto")})})]}),f.jsx("input",{type:"text",placeholder:"15:00",className:"px-2 md:px-4 py-2 md:py-3 text-[14px] md:text-[17px] text-black text-center focus:outline-none placeholder:text-[#C4C4C4]",value:i,onChange:F=>o(F.target.value)})]}),f.jsxs("div",{className:"grid grid-cols-[80px_1fr_80px] md:grid-cols-[100px_1fr_100px] gap-0 border border-black",children:[f.jsxs("div",{className:"flex items-center justify-start gap-1.5 md:gap-2 border-r border-black px-2 md:px-3 py-2 md:py-3",children:[f.jsx("div",{className:"w-1.5 md:w-2 h-1.5 md:h-2 bg-black rounded-full"}),f.jsx("span",{className:"text-[14px] md:text-[17px] font-medium",children:"End"})]}),f.jsxs(Cl,{children:[f.jsx(Tl,{asChild:!0,children:f.jsx("button",{className:Te("px-2 md:px-4 py-2 md:py-3 text-[14px] md:text-[17px] text-left border-r border-black focus:outline-none bg-white",!a&&"text-[#C4C4C4]"),children:a?vt(a,"EEE, dd MMM"):"Thu, 28 Oct"})}),f.jsx(Uo,{className:"w-auto p-0",align:"start",children:f.jsx(wi,{mode:"single",selected:a,onSelect:l,initialFocus:!0,className:Te("p-3 pointer-events-auto")})})]}),f.jsx("input",{type:"text",placeholder:"16:00",className:"px-2 md:px-4 py-2 md:py-3 text-[14px] md:text-[17px] text-black text-center focus:outline-none placeholder:text-[#C4C4C4]",value:c,onChange:F=>u(F.target.value)})]})]}),f.jsx("input",{ref:Z,type:"text",placeholder:"Add event location",className:"w-full px-3 md:px-4 py-2 md:py-3 text-[14px] md:text-[17px] text-black border border-black focus:outline-none placeholder:text-[#C4C4C4]",value:d,onChange:F=>h(F.target.value)}),f.jsx("textarea",{placeholder:"Add description",rows:6,className:"w-full px-3 md:px-4 py-2 md:py-3 text-[14px] md:text-[17px] text-black border border-black focus:outline-none resize-none placeholder:text-[#C4C4C4]",value:p,onChange:F=>b(F.target.value)}),B.length>0&&f.jsxs("div",{className:"mt-8",children:[f.jsxs("h3",{className:"text-[18px] font-medium mb-4",children:["Registrations (",B.length,")"]}),f.jsx("div",{className:"border border-black",children:B.map((F,W)=>f.jsxs("div",{className:Te("px-3 md:px-4 py-2 md:py-3 flex justify-between items-center",W!==B.length-1&&"border-b border-black"),children:[f.jsx("span",{className:"text-[14px] md:text-[17px] font-medium",children:F.display_name}),f.jsx("span",{className:"text-[12px] md:text-[14px] text-gray-500",children:vt(new Date(F.registered_at),"MMM d, yyyy")})]},W))})]}),f.jsxs("div",{className:"flex gap-3 items-center mt-4 md:mt-8",children:[f.jsxs("div",{className:"group flex items-center self-stretch relative overflow-hidden flex-1",children:[f.jsxs("button",{onClick:Q,disabled:S,className:"flex h-[50px] justify-center items-center gap-2.5 border relative px-2.5 py-3.5 border-solid transition-all duration-300 ease-in-out w-[c
244alc(100%-50px)] z-10 bg-[#1A1A1A] border-[#1A1A1A] group-hover:w-full group-hover:bg-[#FA76FF] group-hover:border-[#FA76FF] disabled:opacity-50 disabled:cursor-not-allowed","aria-label":"Update event",children:[f.jsx("span",{className:"text-white text-[13px] font-normal uppercase relative transition-colors duration-300 group-hover:text-black",children:S?"UPDATING...":"UPDATE EVENT"}),f.jsxs("svg",{width:"12",height:"12",viewBox:"0 0 12 12",fill:"none",xmlns:"http://www.w3.org/2000/svg",className:"absolute right-[18px] opacity-0 transition-all duration-300 ease-in-out group-hover:opacity-100","aria-hidden":"true",children:[f.jsx("path",{d:"M0.857178 6H10.3929",stroke:"#1A1A1A",strokeWidth:"1.5"}),f.jsx("path",{d:"M6.39282 10L10.3928 6L6.39282 2",stroke:"#1A1A1A",strokeWidth:"1.5"})]})]}),f.jsx("div",{className:"flex w-[50px] h-[50px] justify-center items-center border absolute right-0 bg-white rounded-[99px] border-solid border-[#1A1A1A] transition-all duration-300 ease-in-out group-hover:opacity-0 group-hover:scale-50 pointer-events-none z-0",children:f.jsxs("svg",{width:"12",height:"12",viewBox:"0 0 12 12",fill:"none",xmlns:"http://www.w3.org/2000/svg",className:"arrow-icon","aria-hidden":"true",children:[f.jsx("path",{d:"M0.857178 6H10.3929",stroke:"#1A1A1A",strokeWidth:"1.5"}),f.jsx("path",{d:"M6.39282 10L10.3928 6L6.39282 2",stroke:"#1A1A1A",strokeWidth:"1.5"})]})})]}),f.jsx("button",{onClick:Y,className:"flex w-[50px] h-[50px] justify-center items-center border border-red-500 bg-red-500 text-white transition-all duration-300 hover:bg-red-600 hover:border-red-600","aria-label":"Delete event",children:f.jsx(mk,{className:"w-5 h-5"})})]})]})]})}):null]})]})},E6=()=>{const e=zl();return w.useEffect(()=>{},[e.pathname]),f.jsxs("div",{className:"flex min-h-screen items-center justify-center bg-gray-100",children:[f.jsx(lr,{title:"404 - Page Not Found",description:"The page you're looking for doesn't exist. Return to discover events and community calendars."}),f.jsxs("div",{className:"text-center",children:[f.jsx("h1",{className:"mb-4 text-4xl font-bold",children:"404"}),f.jsx("p",{className:"mb-4 text-xl text-gray-600",children:"Oops! Page not found"}),f.jsx("a",{href:"/",className:"text-blue-500 underline hover:text-blue-700",children:"Return to Home"})]})]})},Nv=w.createContext({});function Es(e){const t=w.useRef(null);return t.current===null&&(t.current=e()),t.current}const C6=typeof window<"u",af=C6?w.useLayoutEffect:w.useEffect,lf=w.createContext(null);function Rv(e,t){e.indexOf(t)===-1&&e.push(t)}function hd(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 cf=()=>{},Cs=()=>{};const Ts={},_C=e=>/^-?(?:\d+(?:\.\d+)?|\.\d+)$/u.test(e);function SC(e){return typeof e=="object"&&e!==null}const kC=e=>/^0[^.\s]+$/u.test(e);function EC(e){let t;return()=>(t===void 0&&(t=e()),t)}const Ot=e=>e,T6=(e,t)=>n=>t(e(n)),rc=(...e)=>e.reduce(T6),qo=(e,t,n)=>{const r=t-e;return r===0?1:(n-e)/r};class Ov{constructor(){this.subscriptions=[]}add(t){return Rv(this.subscriptions,t),()=>hd(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 Mt=e=>e*1e3,sn=e=>e/1e3;function Mv(e,t){return t?e*(1e3/t):0}const CC=(e,t,n)=>(((1-3*n+3*t)*e+(3*n-6*t))*e+3*t)*e,A6=1e-7,P6=12;function j6(e,t,n,r,s){let i,o,a=0;do o=t+(n-t)/2,i=CC(o,r,s)-e,i>0?n=o:t=o;while(Math.abs(i)>A6&&++a<P6);return o}function sc(e,t,n,r){if(e===t&&n===r)return Ot;const s=i=>j6(i,0,1,e,n);return i=>i===0||i===1?i:CC(s(i),t,r)}const TC=e=>t=>t<=.5?e(2*t)/2:(2-e(2*(1-t)))/2,AC=e=>t=>1-e(1-t),PC=sc(.33,1.53,.69,.99),Dv=AC(PC),jC=TC(Dv),NC=e=>e>=1?1:(e*=2)<1?.5*Dv(e):.5*(2-Math.pow(2,-10*(e-1))),Iv=e=>1-Math.sin(Math.acos(e)),RC=AC(Iv),OC=TC(Iv),N6=sc(.42,0,1,1),R6=sc(0,0,.58,1),MC=sc(.42,0,.58,1),O6=e=>Array.isArray(e)&&typeof e[0]!="number",DC=e=>Array.isArray(e)&&typeof e[0]=="number",hx={linear:Ot,easeIn:N6,easeInOut:MC,easeOut:R6,circIn:Iv,circInOut:OC,circOut:RC,backIn:Dv,backInOut:jC,backOut:PC,anticipate:NC},M6=e=>typeof e=="string",px=e=>{if(DC(e)){Cs(e.length===4,"Cubic bezier arrays must contain four numerical values.","cubic-bezier-length");const[t,n,r,s]=e;return sc(t,n,r,s)}else if(M6(e))return Cs(hx[e]!==void 0,`Invalid easing type '${e}
244'`,"invalid-easing-type"),hx[e];return e},Vc=["setup","read","resolveKeyframes","preUpdate","update","preRender","render","postRender"],mx={value:null,addProjectionMetrics:null};function D6(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,p=!1)=>{const g=p&&s?n:r;return h&&o.add(d),g.add(d),d},cancel:d=>{r.delete(d),o.delete(d)},process:d=>{if(a=d,s){i=!0;return}s=!0;const h=n;n=r,r=h,n.forEach(c),t&&mx.value&&mx.value.frameloop[t].push(l),l=0,n.clear(),s=!1,i&&(i=!1,u.process(d))}};return u}const I6=40;function IC(e,t){let n=!1,r=!0;const s={delta:0,timestamp:0,isProcessing:!1},i=()=>n=!0,o=Vc.reduce((v,_)=>(v[_]=D6(i,t?_:void 0),v),{}),{setup:a,read:l,resolveKeyframes:c,preUpdate:u,update:d,preRender:h,render:p,postRender:b}=o,g=()=>{const v=Ts.useManualTiming,_=v?s.timestamp:performance.now();n=!1,v||(s.delta=r?1e3/60:Math.max(Math.min(_-s.timestamp,I6),1)),s.timestamp=_,s.isProcessing=!0,a.process(s),l.process(s),c.process(s),u.process(s),d.process(s),h.process(s),p.process(s),b.process(s),s.isProcessing=!1,n&&t&&(r=!1,e(g))},x=()=>{n=!0,r=!0,s.isProcessing||e(g)};return{schedule:Vc.reduce((v,_)=>{const S=o[_];return v[_]=(k,E=!1,T=!1)=>(n||x(),S.schedule(k,E,T)),v},{}),cancel:v=>{for(let _=0;_<Vc.length;_++)o[Vc[_]].cancel(v)},state:s,steps:o}}const{schedule:fe,cancel:un,state:Ze,steps:Ch}=IC(typeof requestAnimationFrame<"u"?requestAnimationFrame:Ot,!0);let mu;function L6(){mu=void 0}const yt={now:()=>(mu===void 0&&yt.set(Ze.isProcessing||Ts.useManualTiming?Ze.timestamp:performance.now()),mu),set:e=>{mu=e,queueMicrotask(L6)}},LC=e=>t=>typeof t=="string"&&t.startsWith(e),FC=LC("--"),F6=LC("var(--"),Lv=e=>F6(e)?$6.test(e.split("/*")[0].trim()):!1,$6=/var\(--(?:[\w-]+\s*|[\w-]+\s*,(?:\s*[^)(\s]|\s*\((?:[^)(]|\([^)(]*\))*\))+\s*)\)$/iu;function gx(e){return typeof e!="string"?!1:e.split("/*")[0].includes("var(--")}const sa={test:e=>typeof e=="number",parse:parseFloat,transform:e=>e},Nl={...sa,transform:e=>Ln(0,1,e)},Uc={...sa,default:1},qa=e=>Math.round(e*1e5)/1e5,Fv=/-?(?:\d+(?:\.\d+)?|\.\d+)/gu;function B6(e){return e==null}const V6=/^(?:#[\da-f]{3,8}|(?:rgb|hsl)a?\((?:-?[\d.]+%?[,\s]+){2}-?[\d.]+%?\s*(?:[,/]\s*)?(?:\b\d+(?:\.\d+)?|\.\d+)?%?\))$/iu,$v=(e,t)=>n=>!!(typeof n=="string"&&V6.test(n)&&n.startsWith(e)||t&&!B6(n)&&Object.prototype.hasOwnProperty.call(n,t)),$C=(e,t,n)=>r=>{if(typeof r!="string")return r;const[s,i,o,a]=r.match(Fv);return{[e]:parseFloat(s),[t]:parseFloat(i),[n]:parseFloat(o),alpha:a!==void 0?parseFloat(a):1}},U6=e=>Ln(0,255,e),Th={...sa,transform:e=>Math.round(U6(e))},Js={test:$v("rgb","red"),parse:$C("red","green","blue"),transform:({red:e,green:t,blue:n,alpha:r=1})=>"rgba("+Th.transform(e)+", "+Th.transform(t)+", "+Th.transform(n)+", "+qa(Nl.transform(r))+")"};function z6(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 Sm={test:$v("#"),parse:z6,transform:Js.transform},ic=e=>({test:t=>typeof t=="string"&&t.endsWith(e)&&t.split(" ").length===1,parse:parseFloat,transform:t=>`${t}${e}`}),Wr=ic("deg"),ir=ic("%"),K=ic("px"),W6=ic("vh"),H6=ic("vw"),vx={...ir,parse:e=>ir.parse(e)/100,transform:e=>ir.transform(e*100)},oo={test:$v("hsl","hue"),parse:$C("hue","saturation","lightness"),transform:({hue:e,saturation:t,lightness:n,alpha:r=1})=>"hsla("+Math.round(e)+", "+ir.transform(qa(t))+", "+ir.transform(qa(n))+", "+qa(Nl.transform(r))+")"},We={test:e=>Js.test(e)||Sm.test(e)||oo.test(e),parse:e=>Js.test(e)?Js.parse(e):oo.test(e)?oo.parse(e):Sm.parse(e),transform:e=>typeof e=="string"?e:e.hasOwnProperty("red")?Js.transform(e):oo.transform(e),getAnimatableNone:e=>{const t=We.parse(e);return t.alpha=0,We.transform(t)}},K6=/(?:#[\da-f]{3,8}|(?:rgb|hsl)a?\((?:-?[\d.]+%?[,\s]+){2}-?[\d.]+%?\s*(?:[,/]\s*)?(?:\b\d+(?:\.\d+)?|\.\d+)?%?\))/giu;function q6(e){var t,n;return isNaN(e)&&typeof e=="string"&&(((t=e.match(Fv))==null?void 0:t.length)||0)+(((n=e.match(K6))==null?void 0:n.length)||0)>0}const BC="number",VC="color",Y6="var",G6="var(",yx="${}",Q6=/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 Yo(e){const t=e.toString(),n=[],r={color:[],number:[],var:[]},s=[];let i=0;const a=t.replace(Q6,l=>(We.test(l)?(r.color.push(i),s.push(VC),n.push(We.parse(l))):l.startsWith(G6)?(r.var.push(i),s.push(Y6),n.push(l)):(r.number.push(i),s.push(BC),n.push(parseFloat(l))),++i,yx)).split(yx);return{values:n,split:a,indexes:r,types:s}}function Z6(e){return Yo(e).values}function UC({split:e,types:t}){const n=e.length;return r=>{let s="";for(let i=0;i<n;i++)if(s+=e[i],r[i]!==void 0){const o=t[i];o===BC?s+=qa(r[i]):o===VC?s+=We.transform(r[i]):s+=r[i]}return s}}function J6(e){return UC(Yo(e))}const X6=e=>typeof e=="number"?0:We.test(e)?We.getAnimatableNone(e):e,eB=(e,t)=>typeof e=="number"?t!=null&&t.trim().endsWith("/")?e:0:X6(e);function tB(e){const t=Yo(e);return UC(t)(t.values.map((r,s)=>eB(r,t.split[s])))}const Nn={test:q6,parse:Z6,createTransformer:J6,getAnimatableNone:tB};function Ah(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 nB({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=Ah(l,a,e+1/3),i=Ah(l,a,e),o=Ah(l,a,e-1/3)}return{red:Math.round(s*255),green:Math.round(i*255),blue:Math.round(o*255),alpha:r}}function pd(e,t){return n=>n>0?t:e}
vendor: 22,117 bytes, line 244
244const Ae=(e,t,n)=>e+(t-e)*n,Ph=(e,t,n)=>{const r=e*e,s=n*(t*t-r)+r;return s<0?0:Math.sqrt(s)},rB=[Sm,Js,oo],sB=e=>rB.find(t=>t.test(e));function wx(e){const t=sB(e);if(cf(!!t,`'${e}' is not an animatable color. Use the equivalent color code instead.`,"color-not-animatable"),!t)return!1;let n=t.parse(e);return t===oo&&(n=nB(n)),n}const xx=(e,t)=>{const n=wx(e),r=wx(t);if(!n||!r)return pd(e,t);const s={...n};return i=>(s.red=Ph(n.red,r.red,i),s.green=Ph(n.green,r.green,i),s.blue=Ph(n.blue,r.blue,i),s.alpha=Ae(n.alpha,r.alpha,i),Js.transform(s))},km=new Set(["none","hidden"]);function iB(e,t){return km.has(e)?n=>n<=0?e:t:n=>n>=1?t:e}function oB(e,t){return n=>Ae(e,t,n)}function Bv(e){return typeof e=="number"?oB:typeof e=="string"?Lv(e)?pd:We.test(e)?xx:cB:Array.isArray(e)?zC:typeof e=="object"?We.test(e)?xx:aB:pd}function zC(e,t){const n=[...e],r=n.length,s=e.map((i,o)=>Bv(i)(i,t[o]));return i=>{for(let o=0;o<r;o++)n[o]=s[o](i);return n}}function aB(e,t){const n={...e,...t},r={};for(const s in n)e[s]!==void 0&&t[s]!==void 0&&(r[s]=Bv(e[s])(e[s],t[s]));return s=>{for(const i in r)n[i]=r[i](s);return n}}function lB(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 cB=(e,t)=>{const n=Nn.createTransformer(t),r=Yo(e),s=Yo(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?km.has(e)&&!s.values.length||km.has(t)&&!r.values.length?iB(e,t):rc(zC(lB(r,s),s.values),n):(cf(!0,`Complex values '${e}' and '${t}' too different to mix. Ensure all colors are of the same type, and that each contains the same quantity of number and color values. Falling back to instant transition.`,"complex-values-different"),pd(e,t))};function WC(e,t,n){return typeof e=="number"&&typeof t=="number"&&typeof n=="number"?Ae(e,t,n):Bv(e)(e,t)}const uB=e=>{const t=({timestamp:n})=>e(n);return{start:(n=!0)=>fe.update(t,n),stop:()=>un(t),now:()=>Ze.isProcessing?Ze.timestamp:yt.now()}},HC=(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)})`},md=2e4;function Vv(e){let t=0;const n=50;let r=e.next(t);for(;!r.done&&t<md;)t+=n,r=e.next(t);return t>=md?1/0:t}function dB(e,t=100,n){const r=n({...e,keyframes:[0,t]}),s=Math.min(Vv(r),md);return{type:"keyframes",ease:i=>r.next(s*i).value/t,duration:sn(s)}}const Me={stiffness:100,damping:10,mass:1,velocity:0,duration:800,bounce:.3,visualDuration:.3,restSpeed:{granular:.01,default:2},restDelta:{granular:.005,default:.5},minDuration:.01,maxDuration:10,minDamping:.05,maxDamping:1};function Em(e,t){return e*Math.sqrt(1-t*t)}const fB=12;function hB(e,t,n){let r=n;for(let s=1;s<fB;s++)r=r-e(r)/t(r);return r}const jh=.001;function pB({duration:e=Me.duration,bounce:t=Me.bounce,velocity:n=Me.velocity,mass:r=Me.mass}){let s,i;cf(e<=Mt(Me.maxDuration),"Spring duration must be 10 seconds or less","spring-duration-limit");let o=1-t;o=Ln(Me.minDamping,Me.maxDamping,o),e=Ln(Me.minDuration,Me.maxDuration,sn(e)),o<1?(s=c=>{const u=c*o,d=u*e,h=u-n,p=Em(c,o),b=Math.exp(-d);return jh-h/p*b},i=c=>{const d=c*o*e,h=d*n+n,p=Math.pow(o,2)*Math.pow(c,2)*e,b=Math.exp(-d),g=Em(Math.pow(c,2),o);return(-s(c)+jh>0?-1:1)*((h-p)*b)/g}):(s=c=>{const u=Math.exp(-c*e),d=(c-n)*e+1;return-jh+u*d},i=c=>{const u=Math.exp(-c*e),d=(n-c)*(e*e);return u*d});const a=5/e,l=hB(s,i,a);if(e=Mt(e),isNaN(l))return{stiffness:Me.stiffness,damping:Me.damping,duration:e};{const c=Math.pow(l,2)*r;return{stiffness:c,damping:o*2*Math.sqrt(r*c),duration:e}}}const mB=["duration","bounce"],gB=["stiffness","damping","mass"];function bx(e,t){return t.some(n=>e[n]!==void 0)}function vB(e){let t={velocity:Me.velocity,stiffness:Me.stiffness,damping:Me.damping,mass:Me.mass,isResolvedFromDuration:!1,...e};if(!bx(e,gB)&&bx(e,mB))if(t.velocity=0,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:Me.mass,stiffness:s,damping:i}}else{const n=pB({...e,velocity:0});t={...t,...n,mass:Me.mass},t.isResolvedFromDuration=!0}return t}function gd(e=Me.visualDuration,t=Me.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:p}=vB({...n,velocity:-sn(n.velocity||0)}),b=h||0,g=c/(2*Math.sqrt(l*u)),x=o-i,y=sn(Math.sqrt(l/u)),m=Math.abs(x)<5;r||(r=m?Me.restSpeed.granular:Me.restSpeed.default),s||(s=m?Me.restDelta.granular:Me.restDelta.default);let v,_,S,k,E,T;if(g<1)S=Em(y,g),k=(b+g*y*x)/S,v=A=>{const B=Math.exp(-g*y*A);return o-B*(k*Math.sin(S*A)+x*Math.cos(S*A))},E=g*y*k+x*S,T=g*y*x-k*S,_=A=>Math.exp(-g*y*A)*(E*Math.sin(S*A)+T*Math.cos(S*A));else if(g===1){v=B=>o-Math.exp(-y*B)*(x+(b+y*x)*B);const A=b+y*x;_=B=>Math.exp(-y*B)*(y*A*B-b)}else{const A=y*Math.sqrt(g*g-1);v=R=>{const U=Math.exp(-g*y*R),V=Math.min(A*R,300);return o-U*((b+g*y*x)*Math.sinh(V)+A*x*Math.cosh(V))/A};const B=(b+g*y*x)/A,I=g*y*B-x*A,Z=g*y*x-B*A;_=R=>{const U=Math.exp(-g*y*R),V=Math.min(A*R,300);return U*(I*Math.sinh(V)+Z*Math.cosh(V))}}const P={calculatedDuration:p&&d||null,velocity:A=>Mt(_(A)),next:A=>{if(!p&&g<1){const I=Math.exp(-g*y*A),Z=Math.sin(S*A),R=Math.cos(S*A),U=o-I*(k*Z+x*R),V=Mt(I*(E*Z+T*R));return a.done=Math.abs(V)<=r&&Math.abs(o-U)<=s,a.value=a.done?o:U,a}const B=v(A);if(p)a.done=A>=d;else{const I=Mt(_(A));a.done=Math.abs(I)<=r&&Math.abs(o-B)<=s}return a.value=a.done?o:B,a},toString:()=>{const A=Math.min(Vv(P),md),B=HC(I=>P.next(A*I).value,A,30);return A+"ms "+B},toTransition:()=>{}};return P}gd.applyToOptions=e=>{const t=dB(e,100,gd);return e.ease=t.ease,e.duration=Mt(t.duration),e.type="keyframes",e};const yB=5;function KC(e,t,n){const r=Math.max(t-yB,0);return Mv(n-e(r),t-r)}function Cm({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},p=T=>a!==void 0&&T<a||l!==void 0&&T>l,b=T=>a===void 0?l:l===void 0||Math.abs(a-T)<Math.abs(l-T)?a:l;let g=n*t;const x=d+g,y=o===void 0?x:o(x);y!==x&&(g=y-d);const m=T=>-g*Math.exp(-T/r),v=T=>y+m(T),_=T=>{const P=m(T),A=v(T);h.done=Math.abs(P)<=c,h.value=h.done?y:A};let S,k;const E=T=>{p(h.value)&&(S=T,k=gd({keyframes:[h.value,b(h.value)],velocity:KC(v,T,h.value),damping:s,stiffness:i,restDelta:c,restSpeed:u}))};return E(0),{calculatedDuration:null,next:T=>{let P=!1;return!k&&S===void 0&&(P=!0,_(T),E(T)),S!==void 0&&T>=S?k.next(T-S):(!P&&_(T),h)}}}function wB(e,t,n){const r=[],s=n||Ts.mix||WC,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]||Ot:t;a=rc(l,a)}r.push(a)}return r}function Uv(e,t,{clamp:n=!0,ease:r,mixer:s}={}){const i=e.length;if(Cs(i===t.length,"Both input and output ranges must be the same length","range-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=wB(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 xB(e,t){const n=e[e.length-1];for(let r=1;r<=t;r++){const s=qo(0,t,r);e.push(Ae(n,1,s))}}function qC(e){const t=[0];return xB(t,e.length-1),t}function bB(e,t){return e.map(n=>n*t)}function _B(e,t){return e.map(()=>t||MC).splice(0,e.length-1)}function Ya({duration:e=300,keyframes:t,times:n,ease:r="easeInOut"}){const s=O6(r)?r.map(px):px(r),i={done:!1,value:t[0]},o=bB(n&&n.length===t.length?n:qC(t),e),a=Uv(o,t,{ease:Array.isArray(s)?s:_B(t,s)});return{calculatedDuration:e,next:l=>(i.value=a(l),i.done=l>=e,i)}}const SB=e=>e!==null;function uf(e,{repeat:t,repeatType:n="loop"},r,s=1){const i=e.filter(SB),a=s<0||t&&n!=="loop"&&t%2===1?0:i.length-1;return!a||r===void 0?i[a]:r}const kB={decay:Cm,inertia:Cm,tween:Ya,keyframes:Ya,spring:gd};function YC(e){typeof e.type=="string"&&(e.type=kB[e.type])}class zv{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 EB=e=>e/100;class vd extends zv{constructor(t){super(),this.state="idle",this.startTime=null,this.isStopped=!1,this.currentTime=0,this.holdTime=null,this.playbackSpeed=1,this.delayState={done:!1,value:void 0},this.stop=()=>{var r,s;const{motionValue:n}=this.options;n&&n.updatedAt!==yt.now()&&this.tick(yt.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;YC(t);const{type:n=Ya,repeat:r=0,repeatDelay:s=0,repeatType:i,velocity:o=0}=t;let{keyframes:a}=t;const l=n||Ya;l!==Ya&&typeof a[0]!="number"&&(this.mixKeyframes=rc(EB,WC(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=Vv(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:p,type:b,onUpdate:g,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 y=this.currentTime-c*(this.playbackSpeed>=0?1:-1),m=this.playbackSpeed>=0?y<0:y>s;this.currentTime=Math.max(y,0),this.state==="finished"&&this.holdTime===null&&(this.currentTime=s);let v=this.currentTime,_=r;if(d){const T=Math.min(this.currentTime,s)/a;let P=Math.floor(T),A=T%1;!A&&T>=1&&(A=1),A===1&&P--,P=Math.min(P,d+1),!!(P%2)&&(h==="reverse"?(A=1-A,p&&(A-=p/a)):h==="mirror"&&(_=o)),v=Ln(0,1,A)*a}let S;m?(this.delayState.value=u[0],S=this.delayState):S=_.next(v),i&&!m&&(S.value=i(S.value));let{done:k}=S;!m&&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&&b!==Cm&&(S.value=uf(u,this.options,x,this.speed)),g&&g(S.value),E&&this.finish(),S}then(t,n){return this.finished.then(t,n)}get duration(){return sn(this.calculatedDuration)}get iterationDuration(){const{delay:t=0}=this.options||{};return this.duration+sn(t)}get time(){return sn(this.currentTime)}set time(t){t=Mt(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),this.driver?this.driver.start(!1):(this.startTime=0,this.state="paused",this.holdTime=t,this.tick(t))}getGeneratorVelocity(){const t=this.currentTime;if(t<=0)return this.options.velocity||0;if(this.generator.velocity)return this.generator.velocity(t);const n=this.generator.next(t).value;return KC(r=>this.generator.next(r).value,t,n)}get speed(){return this.playbackSpeed}set speed(t){const n=this.playbackSpeed!==t;n&&this.driver&&this.updateTime(yt.now()),this.playbackSpeed=t,n&&this.driver&&(this.time=sn(this.currentTime))}play(){var s,i;if(this.isStopped)return;const{driver:t=uB,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(yt.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 CB(e){for(let t=1;t<e.length;t++)e[t]??(e[t]=e[t-1])}const Xs=e=>e*180/Math.PI,Tm=e=>{const t=Xs(Math.atan2(e[1],e[0]));return Am(t)},TB={x:4,y:5,translateX:4,translateY:5,scaleX:0,scaleY:3,scale:e=>(Math.abs(e[0])+Math.abs(e[3]))/2,rotate:Tm,rotateZ:Tm,skewX:e=>Xs(Math.atan(e[1])),skewY:e=>Xs(Math.atan(e[2])),skew:e=>(Math.abs(e[1])+Math.abs(e[2]))/2},Am=e=>(e=e%360,e<0&&(e+=360),e),_x=Tm,Sx=e=>Math.sqrt(e[0]*e[0]+e[1]*e[1]),kx=e=>Math.sqrt(e[4]*e[4]+e[5]*e[5]),AB={x:12,y:13,z:14,translateX:12,translateY:13,translateZ:14,scaleX:Sx,scaleY:kx,scale:e=>(Sx(e)+kx(e))/2,rotateX:e=>Am(Xs(Math.atan2(e[6],e[5]))),rotateY:e=>Am(Xs(Math.atan2(-e[2],e[0]))),rotateZ:_x,rotate:_x,skewX:e=>Xs(Math.atan(e[4])),skewY:e=>Xs(Math.atan(e[1])),skew:e=>(Math.abs(e[1])+Math.abs(e[4]))/2};function Pm(e){return e.includes("scale")?1:0}function jm(e,t){if(!e||e==="none")return Pm(t);const n=e.match(/^matrix3d\(([-\d.e\s,]+)\)$/u);let r,s;if(n)r=AB,s=n;else{const a=e.match(/^matrix\(([-\d.e\s,]+)\)$/u);r=TB,s=a}if(!s)return Pm(t);const i=r[t],o=s[1].split(",").map(jB);return typeof i=="function"?i(o):o[i]}const PB=(e,t)=>{const{transform:n="none"}=getComputedStyle(e);return jm(n,t)};function jB(e){return parseFloat(e.trim())}const ia=["transformPerspective","x","y","z","translateX","translateY","translateZ","scale","scaleX","scaleY","rotate","rotateX","rotateY","rotateZ","skew","skewX","skewY"],oa=new Set(ia),Ex=e=>e===sa||e===K,NB=new Set(["x","y","z"]),RB=ia.filter(e=>!NB.has(e));function OB(e){const t=[];return RB.forEach(n=>{const r=e.getValue(n);r!==void 0&&(t.push([n,r.get()]),r.set(n.startsWith("scale")?1:0))}),t}const ls={width:({x:e},{paddingLeft:t="0",paddingRight:n="0",boxSizing:r})=>{const s=e.max-e.min;return r==="border-box"?s:s-parseFloat(t)-parseFloat(n)},height:({y:e},{paddingTop:t="0",paddingBottom:n="0",boxSizing:r})=>{const s=e.max-e.min;return r==="border-box"?s:s-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})=>jm(t,"x"),y:(e,{transform:t})=>jm(t,"y")};ls.translateX=ls.x;ls.translateY=ls.y;const ci=new Set;let Nm=!1,Rm=!1,Om=!1;function GC(){if(Rm){const e=Array.from(ci).filter(r=>r.needsMeasurement),t=new Set(e.map(r=>r.element)),n=new Map;t.forEach(r=>{const s=OB(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)})}Rm=!1,Nm=!1,ci.forEach(e=>e.complete(Om)),ci.clear()}function QC(){ci.forEach(e=>{e.readKeyframes(),e.needsMeasurement&&(Rm=!0)})}function MB(){Om=!0,QC(),GC(),Om=!1}class Wv{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?(ci.add(this),Nm||(Nm=!0,fe.read(QC),fe.resolveKeyframes(GC))):(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])}CB(t)}setFinalKeyframe(){}measureInitialState(){}renderEndStyles(){}measureEndState(){}complete(t=!1){this.state="complete",this.onComplete(this.unresolvedKeyframes,this.finalKeyframe,t),ci.delete(this)}cancel(){this.state==="scheduled"&&(ci.delete(this),this.state="pending")}resume(){this.state==="pending"&&this.scheduleResolve()}}const DB=e=>e.startsWith("--");function ZC(e,t,n){DB(t)?e.style.setProperty(t,n):e.style[t]=n}const IB={};function Hv(e,t){const n=EC(e);return()=>IB[t]??n()}const Kv=Hv(()=>window.ScrollTimeline!==void 0,"scrollTimeline"),JC=Hv(()=>window.ViewTimeline!==void 0,"viewTimeline"),XC=Hv(()=>{try{document.createElement("div").animate({opacity:0},{easing:"linear(0, 1)"})}catch{return!1}return!0},"linearEasing"),Ra=([e,t,n,r])=>`cubic-bezier(${e}, ${t}, ${n}, ${r})`,Cx={linear:"linear",ease:"ease",easeIn:"ease-in",easeOut:"ease-out",easeInOut:"ease-in-out",circIn:Ra([0,.65,.55,1]),circOut:Ra([.55,0,1,.45]),backIn:Ra([.31,.01,.66,-.59]),backOut:Ra([.33,1.53,.69,.99])};function eT(e,t){if(e)return typeof e=="function"?XC()?HC(e,t):"ease-out":DC(e)?Ra(e):Array.isArray(e)?e.map(n=>eT(n,t)||Cx.easeOut):Cx[e]}function LB(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=eT(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 tT(e){return typeof e=="function"&&"applyToOptions"in e}function FB({type:e,...t}){return tT(e)&&XC()?e.applyToOptions(t):(t.duration??(t.duration=300),t.ease??(t.ease="easeOut"),t)}class nT extends zv{constructor(t){if(super(),this.finishedTime=null,this.isStopped=!1,this.manualStartTime=null,!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,Cs(typeof t.type!="string",`Mini animate() doesn't support "type" as a string.`,"mini-spring");const c=FB(t);this.animation=LB(n,r,s,c,i),c.autoplay===!1&&this.animation.pause(),this.animation.onfinish=()=>{if(this.finishedTime=this.time,!i){const u=uf(s,this.options,a,this.speed);this.updateMotionValue&&this.updateMotionValue(u),ZC(n,r,u),this.animation.cancel()}l==null||l(),this.notifyFinished()}}play(){this.isStopped||(this.manualStartTime=null,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 n,r,s;const t=(n=this.options)==null?void 0:n.element;!this.isPseudoElement&&(t!=null&&t.isConnected)&&((s=(r=this.animation).commitStyles)==null||s.call(r))}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 sn(Number(t))}get iterationDuration(){const{delay:t=0}=this.options||{};return this.duration+sn(t)}get time(){return sn(Number(this.animation.currentTime)||0)}set time(t){const n=this.finishedTime!==null;this.manualStartTime=null,this.finishedTime=null,this.animation.currentTime=Mt(t),n&&this.animation.pause()}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 this.manualStartTime??Number(this.animation.startTime)}set startTime(t){this.manualStartTime=this.animation.startTime=t}attachTimeline({timeline:t,rangeStart:n,rangeEnd:r,observe:s}){var i;return this.allowFlatten&&((i=this.animation.effect)==null||i.updateTiming({easing:"linear"})),this.animation.onfinish=null,t&&Kv()?(this.animation.timeline=t,n&&(this.animation.rangeStart=n),r&&(this.animation.rangeEnd=r),Ot):s(this)}}const rT={anticipate:NC,backInOut:jC,circInOut:OC};function $B(e){return e in rT}function BB(e){typeof e.ease=="string"&&$B(e.ease)&&(e.ease=rT[e.ease])}const Nh=10;class VB extends nT{constructor(t){BB(t),YC(t),super(t),t.startTime!==void 0&&t.autoplay!==!1&&(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 vd({...o,autoplay:!1}),l=Math.max(Nh,yt.now()-this.startTime),c=Ln(0,Nh,l-Nh),u=a.sample(l).value,{name:d}=this.options;i&&d&&ZC(i,d,u),n.setWithVelocity(a.sample(Math.max(0,l-c)).value,u,c),a.stop()}}const Tx=(e,t)=>t==="zIndex"?!1:!!(typeof e=="number"||Array.isArray(e)||typeof e=="string"&&(Nn.test(e)||e==="0")&&!e.startsWith("url("));function UB(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 zB(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=Tx(s,t),a=Tx(i,t);return cf(o===a,`You are trying to animate ${t} from "${s}" to "${i}". "${o?i:s}" is not an animatable value.`,"value-not-animatable"),!o||!a?!1:UB(e)||(n==="spring"||tT(n))&&r}function Mm(e){e.duration=0,e.type="keyframes"}const sT=new Set(["opacity","clipPath","filter","transform"]),WB=/^(?:oklch|oklab|lab|lch|color|color-mix|light-dark)\(/;function HB(e){for(let t=0;t<e.length;
244t++)if(typeof e[t]=="string"&&WB.test(e[t]))return!0;return!1}const KB=new Set(["color","backgroundColor","outlineColor","fill","stroke","borderColor","borderTopColor","borderRightColor","borderBottomColor","borderLeftColor"]),qB=EC(()=>Object.hasOwnProperty.call(Element.prototype,"animate"));function YB(e){var d;const{motionValue:t,name:n,repeatDelay:r,repeatType:s,damping:i,type:o,keyframes:a}=e;if(!(((d=t==null?void 0:t.owner)==null?void 0:d.current)instanceof HTMLElement))return!1;const{onUpdate:c,transformTemplate:u}=t.owner.getProps();return qB()&&n&&(sT.has(n)||KB.has(n)&&HB(a))&&(n!=="transform"||!u)&&!c&&!r&&s!=="mirror"&&i!==0&&o!=="inertia"}const GB=40;class QB extends zv{constructor({autoplay:t=!0,delay:n=0,type:r="keyframes",repeat:s=0,repeatDelay:i=0,repeatType:o="loop",keyframes:a,name:l,motionValue:c,element:u,...d}){var b;super(),this.stop=()=>{var g,x;this._animation&&(this._animation.stop(),(g=this.stopTimeline)==null||g.call(this)),(x=this.keyframeResolver)==null||x.cancel()},this.createdAt=yt.now();const h={autoplay:t,delay:n,type:r,repeat:s,repeatDelay:i,repeatType:o,name:l,motionValue:c,element:u,...d},p=(u==null?void 0:u.KeyframeResolver)||Wv;this.keyframeResolver=new p(a,(g,x,y)=>this.onKeyframesResolved(g,x,h,!y),l,c,u),(b=this.keyframeResolver)==null||b.scheduleResolve()}onKeyframesResolved(t,n,r,s){var y,m;this.keyframeResolver=void 0;const{name:i,type:o,velocity:a,delay:l,isHandoff:c,onUpdate:u}=r;this.resolvedAt=yt.now();let d=!0;zB(t,i,o,a)||(d=!1,(Ts.instantAnimations||!l)&&(u==null||u(uf(t,r,n))),t[0]=t[t.length-1],Mm(r),r.repeat=0);const p={startTime:s?this.resolvedAt?this.resolvedAt-this.createdAt>GB?this.resolvedAt:this.createdAt:this.createdAt:void 0,finalKeyframe:n,...r,keyframes:t},b=d&&!c&&YB(p),g=(m=(y=p.motionValue)==null?void 0:y.owner)==null?void 0:m.current;let x;if(b)try{x=new VB({...p,element:g})}catch{x=new vd(p)}else x=new vd(p);x.finished.then(()=>{this.notifyFinished()}).catch(Ot),this.pendingTimeline&&(this.stopTimeline=x.attachTimeline(this.pendingTimeline),this.pendingTimeline=void 0),this._animation=x}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(),MB()),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()}}function iT(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}const ZB=/^var\(--(?:([\w-]+)|([\w-]+), ?([a-zA-Z\d ()%#.,-]+))\)/u;function JB(e){const t=ZB.exec(e);if(!t)return[,];const[,n,r,s]=t;return[`--${n??r}`,s]}const XB=4;function oT(e,t,n=1){Cs(n<=XB,`Max CSS variable fallback depth detected in property "${e}". This may indicate a circular fallback dependency.`,"max-css-var-depth");const[r,s]=JB(e);if(!r)return;const i=window.getComputedStyle(t).getPropertyValue(r);if(i){const o=i.trim();return _C(o)?parseFloat(o):o}return Lv(s)?oT(s,t,n+1):s}const eV={type:"spring",stiffness:500,damping:25,restSpeed:10},tV=e=>({type:"spring",stiffness:550,damping:e===0?2*Math.sqrt(550):30,restSpeed:10}),nV={type:"keyframes",duration:.8},rV={type:"keyframes",ease:[.25,.1,.35,1],duration:.3},sV=(e,{keyframes:t})=>t.length>2?nV:oa.has(e)?e.startsWith("scale")?tV(t[1]):eV:rV;function aT(e,t){if(e!=null&&e.inherit&&t){const{inherit:n,...r}=e;return{...t,...r}}return e}function qv(e,t){const n=(e==null?void 0:e[t])??(e==null?void 0:e.default)??e;return n!==e?aT(n,e):n}const iV=new Set(["when","delay","delayChildren","staggerChildren","staggerDirection","repeat","repeatType","repeatDelay","from","elapsed"]);function oV(e){for(const t in e)if(!iV.has(t))return!0;return!1}const Yv=(e,t,n,r={},s,i)=>o=>{const a=qv(r,e)||{},l=a.delay||r.delay||0;let{elapsed:c=0}=r;c=c-Mt(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};oV(a)||Object.assign(u,sV(e,u)),u.duration&&(u.duration=Mt(u.duration)),u.repeatDelay&&(u.repeatDelay=Mt(u.repeatDelay)),u.from!==void 0&&(u.keyframes[0]=u.from);let d=!1;if((u.type===!1||u.duration===0&&!u.repeatDelay)&&(Mm(u),u.delay===0&&(
vendor: 8,789 bytes, line 244
244d=!0)),(Ts.instantAnimations||Ts.skipAnimations||s!=null&&s.shouldSkipAnimations)&&(d=!0,Mm(u),u.delay=0),u.allowFlatten=!a.type&&!a.ease,d&&!i&&t.get()!==void 0){const h=uf(u.keyframes,a);if(h!==void 0){fe.update(()=>{u.onUpdate(h),u.onComplete()});return}}return a.isSync?new vd(u):new QB(u)};function Ax(e){const t=[{},{}];return e==null||e.values.forEach((n,r)=>{t[0][r]=n.get(),t[1][r]=n.getVelocity()}),t}function Gv(e,t,n,r){if(typeof t=="function"){const[s,i]=Ax(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]=Ax(r);t=t(n!==void 0?n:e.custom,s,i)}return t}function ui(e,t,n){const r=e.getProps();return Gv(r,t,n!==void 0?n:r.custom,e)}const lT=new Set(["width","height","top","left","right","bottom",...ia]),Px=30,aV=e=>!isNaN(parseFloat(e)),Ga={current:void 0};class lV{constructor(t,n={}){this.canTrackVelocity=null,this.events={},this.updateAndNotify=r=>{var i;const s=yt.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=yt.now(),this.canTrackVelocity===null&&t!==void 0&&(this.canTrackVelocity=aV(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 Ov);const r=this.events[t].add(n);return t==="change"?()=>{r(),fe.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 Ga.current&&Ga.current.push(this),this.current}getPrevious(){return this.prev}getVelocity(){const t=yt.now();if(!this.canTrackVelocity||this.prevFrameValue===void 0||t-this.updatedAt>Px)return 0;const n=Math.min(this.updatedAt-this.prevUpdatedAt,Px);return Mv(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 An(e,t){return new lV(e,t)}const Dm=e=>Array.isArray(e);function cV(e,t,n){e.hasValue(t)?e.getValue(t).set(n):e.addValue(t,An(n))}function uV(e){return Dm(e)?e[e.length-1]||0:e}function dV(e,t){const n=ui(e,t);let{transitionEnd:r={},transition:s={},...i}=n||{};i={...i,...r};for(const o in i){const a=uV(i[o]);cV(e,o,a)}}const nt=e=>!!(e&&e.getVelocity);function fV(e){return!!(nt(e)&&e.add)}function Im(e,t){const n=e.getValue("willChange");if(fV(n))return n.add(t);if(!n&&Ts.WillChange){const r=new Ts.WillChange("auto");e.addValue("willChange",r),r.add(t)}}function Qv(e){return e.replace(/([A-Z])/g,t=>`-${t.toLowerCase()}`)}const hV="framerAppearId",cT="data-"+Qv(hV);function uT(e){return e.props[cT]}function pV({protectedKeys:e,needsAnimating:t},n){const r=e.hasOwnProperty(n)&&t[n]!==!0;return t[n]=!1,r}function dT(e,t,{delay:n=0,transitionOverride:r,type:s}={}){let{transition:i,transitionEnd:o,...a}=t;const l=e.getDefaultTransition();i=i?aT(i,l):l;const c=i==null?void 0:i.reduceMotion;r&&(i=r);const u=[],d=s&&e.animationState&&e.animationState.getState()[s];for(const h in a){const p=e.getValue(h,e.latestValues[h]??null),b=a[h];if(b===void 0||d&&pV(d,h))continue;const g={delay:n,...qv(i||{},h)},x=p.get();if(x!==void 0&&!p.isAnimating()&&!Array.isArray(b)&&b===x&&!g.velocity){fe.update(()=>p.set(b));continue}let y=!1;if(window.MotionHandoffAnimation){const _=uT(e);if(_){const S=window.MotionHandoffAnimation(_,h,fe);S!==null&&(g.startTime=S,y=!0)}}Im(e,h);const m=c??e.shouldReduceMotion;p.start(Yv(h,p,b,m&&lT.has(h)?{type:!1}:g,e,y));const v=p.animation;v&&u.push(v)}if(o){const h=()=>fe.update(()=>{o&&dV(e,o)});u.length?Promise.all(u).then(h):h()}return u}function Lm(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(dT(e,r,n)):()=>Promise.resolve(),o=e.variantChildren&&e.variantChildren.size?(c=0)=>{const{delayChildren:u=0,staggerChildren:d,staggerDirection:h}=s;return mV(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 mV(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(Lm(l,t,{...o,delay:n+(typeof r=="function"?0:r)+iT(e.variantChildren,l,r,s,i)}).then(()=>l.notify("AnimationComplete",t)));return Promise.all(a)}function gV(e,t,n={}){e.notify("AnimationStart",t);let r;if(Array.isArray(t)){const s=t.map(i=>Lm(e,i,n));r=Promise.all(s)}else if(typeof t=="string")r=Lm(e,t,n);else{const s=typeof t=="function"?ui(e,t,n.custom):t;r=Promise.all(dT(e,s,n))}return r.then(()=>{e.notify("AnimationComplete",t)})}const vV={test:e=>e==="auto",parse:e=>e},fT=e=>t=>t.test(e),hT=[sa,K,ir,Wr,H6,W6,vV],jx=e=>hT.find(fT(e));function yV(e){return typeof e=="number"?e===0:e!==null?e==="none"||e==="0"||kC(e):!0}const wV=new Set(["brightness","contrast","saturate","opacity"]);function xV(e){const[t,n]=e.slice(0,-1).split("(");if(t==="drop-shadow")return e;const[r]=n.match(Fv)||[];if(!r)return e;const s=n.replace(r,"");let i=wV.has(t)?1:0;return r!==n&&(i*=100),t+"("+i+s+")"}const bV=/\b([a-z-]*)\(.*?\)/gu,Fm={...Nn,getAnimatableNone:e=>{const t=e.match(bV);return t?t.map(xV).join(" "):e}},$m={...Nn,getAnimatableNone:e=>{const t=Nn.parse(e);return Nn.createTransformer(e)(t.map(r=>typeof r=="number"?0:typeof r=="object"?{...r,alpha:1}:r))}},Nx={...sa,transform:Math.round},_V={rotate:Wr,rotateX:Wr,rotateY:Wr,rotateZ:Wr,scale:Uc,scaleX:Uc,scaleY:Uc,scaleZ:Uc,skew:Wr,skewX:Wr,skewY:Wr,distance:K,translateX:K,translateY:K,translateZ:K,x:K,y:K,z:K,perspective:K,transformPerspective:K,opacity:Nl,originX:vx,originY:vx,originZ:K},Zv={borderWidth:K,borderTopWidth:K,borderRightWidth:K,borderBottomWidth:K,borderLeftWidth:K,borderRadius:K,borderTopLeftRadius:K,borderTopRightRadius:K,borderBottomRightRadius:K,borderBottomLeftRadius:K,width:K,maxWidth:K,height:K,maxHeight:K,top:K,right:K,bottom:K,left:K,inset:K,insetBlock:K,insetBlockStart:K,insetBlockEnd:K,insetInline:K,insetInlineStart:K,insetInlineEnd:K,padding:K,paddingTop:K,paddingRight:K,paddingBottom:K,paddingLeft:K,paddingBlock:K,paddingBlockStart:K,paddingBlockEnd:K,paddingInline:K,paddingInlineStart:K,paddingInlineEnd:K,margin:K,marginTop:K,marginRight:K,marginBottom:K,marginLeft:K,marginBlock:K,marginBlockStart:K,marginBlockEnd:K,marginInline:K,marginInlineStart:K,marginInlineEnd:K,fontSize:K,backgroundPositionX:K,backgroundPositionY:K,..._V,zIndex:Nx,fillOpacity:Nl,strokeOpacity:Nl,numOctaves:Nx},SV={...Zv,color:We,backgroundColor:We,outlineColor:We,fill:We,stroke:We,borderColor:We,borderTopColor:We,borderRightColor:We,borderBottomColor:We,borderLeftColor:We,filter:Fm,WebkitFilter:Fm,mask:$m,WebkitMask:$m},pT=e=>SV[e],kV=new Set([Fm,$m]);function mT(e,t){let n=pT(e);return kV.has(n)||(n=Nn),n.getAnimatableNone?n.getAnimatableNone(t):void 0}const EV=new Set(["auto","none","0"]);function CV(e,t,n){let r=0,s;for(;r<e.length&&!s;){const i=e[r];typeof i=="string"&&!EV.has(i)&&Yo(i).values.length&&(s=e[r]),r++}if(s&&n)for(const i of t)e[i]=mT(n,s)}class TV extends Wv{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 u=0;u<t.length;u++){let d=t[u];
vendor: 1,295 bytes, line 244
244if(typeof d=="string"&&(d=d.trim(),Lv(d))){const h=oT(d,n.current);h!==void 0&&(t[u]=h),u===t.length-1&&(this.finalKeyframe=d)}}if(this.resolveNoneKeyframes(),!lT.has(r)||t.length!==2)return;const[s,i]=t,o=jx(s),a=jx(i),l=gx(s),c=gx(i);if(l!==c&&ls[r]){this.needsMeasurement=!0;return}if(o!==a)if(Ex(o)&&Ex(a))for(let u=0;u<t.length;u++){const d=t[u];typeof d=="string"&&(t[u]=parseFloat(d))}else ls[r]&&(this.needsMeasurement=!0)}resolveNoneKeyframes(){const{unresolvedKeyframes:t,name:n}=this,r=[];for(let s=0;s<t.length;s++)(t[s]===null||yV(t[s]))&&r.push(s);r.length&&CV(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=ls[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]=ls[n](t.measureViewportBox(),window.getComputedStyle(t.current)),o!==null&&this.finalKeyframe===void 0&&(this.finalKeyframe=o),(a=this.removedTransforms)!=null&&a.length&&this.removedTransforms.forEac
vendor: 41,108 bytes, line 244
244h(([l,c])=>{t.getValue(l).set(c)}),this.resolveNoneKeyframes()}}function Jv(e,t,n){if(e==null)return[];if(e instanceof EventTarget)return[e];if(typeof e=="string"){const s=document.querySelectorAll(e);return s?Array.from(s):[]}return Array.from(e).filter(r=>r!=null)}const gT=(e,t)=>t&&typeof e=="number"?t.transform(e):e;function Qa(e){return SC(e)&&"offsetHeight"in e&&!("ownerSVGElement"in e)}const{schedule:Xv,cancel:TW}=IC(queueMicrotask,!1),wn={x:!1,y:!1};function vT(){return wn.x||wn.y}function AV(e){return e==="x"||e==="y"?wn[e]?null:(wn[e]=!0,()=>{wn[e]=!1}):wn.x||wn.y?null:(wn.x=wn.y=!0,()=>{wn.x=wn.y=!1})}function yT(e,t){const n=Jv(e),r=new AbortController,s={passive:!0,...t,signal:r.signal};return[n,s,()=>r.abort()]}function PV(e){return!(e.pointerType==="touch"||vT())}function jV(e,t,n={}){const[r,s,i]=yT(e,n);return r.forEach(o=>{let a=!1,l=!1,c;const u=()=>{o.removeEventListener("pointerleave",b)},d=x=>{c&&(c(x),c=void 0),u()},h=x=>{a=!1,window.removeEventListener("pointerup",h),window.removeEventListener("pointercancel",h),l&&(l=!1,d(x))},p=()=>{a=!0,window.addEventListener("pointerup",h,s),window.addEventListener("pointercancel",h,s)},b=x=>{if(x.pointerType!=="touch"){if(a){l=!0;return}d(x)}},g=x=>{if(!PV(x))return;l=!1;const y=t(o,x);typeof y=="function"&&(c=y,o.addEventListener("pointerleave",b,s))};o.addEventListener("pointerenter",g,s),o.addEventListener("pointerdown",p,s)}),i}const wT=(e,t)=>t?e===t?!0:wT(e,t.parentElement):!1,ey=e=>e.pointerType==="mouse"?typeof e.button!="number"||e.button<=0:e.isPrimary!==!1,NV=new Set(["BUTTON","INPUT","SELECT","TEXTAREA","A"]);function RV(e){return NV.has(e.tagName)||e.isContentEditable===!0}const OV=new Set(["INPUT","SELECT","TEXTAREA"]);function MV(e){return OV.has(e.tagName)||e.isContentEditable===!0}const gu=new WeakSet;function Rx(e){return t=>{t.key==="Enter"&&e(t)}}function Rh(e,t){e.dispatchEvent(new PointerEvent("pointer"+t,{isPrimary:!0,bubbles:!0}))}const DV=(e,t)=>{const n=e.currentTarget;if(!n)return;const r=Rx(()=>{if(gu.has(n))return;Rh(n,"down");const s=Rx(()=>{Rh(n,"up")}),i=()=>Rh(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 Ox(e){return ey(e)&&!vT()}const Mx=new WeakSet;function IV(e,t,n={}){const[r,s,i]=yT(e,n),o=a=>{const l=a.currentTarget;if(!Ox(a)||Mx.has(a))return;gu.add(l),n.stopPropagation&&Mx.add(a);const c=t(l,a),u=(p,b)=>{window.removeEventListener("pointerup",d),window.removeEventListener("pointercancel",h),gu.has(l)&&gu.delete(l),Ox(p)&&typeof c=="function"&&c(p,{success:b})},d=p=>{u(p,l===window||l===document||n.useGlobalTarget||wT(l,p.target))},h=p=>{u(p,!1)};window.addEventListener("pointerup",d,s),window.addEventListener("pointercancel",h,s)};return r.forEach(a=>{(n.useGlobalTarget?window:a).addEventListener("pointerdown",o,s),Qa(a)&&(a.addEventListener("focus",c=>DV(c,s)),!RV(a)&&!a.hasAttribute("tabindex")&&(a.tabIndex=0))}),i}function ty(e){return SC(e)&&"ownerSVGElement"in e}const vu=new WeakMap;let Hr;const xT=(e,t,n)=>(r,s)=>s&&s[0]?s[0][e+"Size"]:ty(r)&&"getBBox"in r?r.getBBox()[t]:r[n],LV=xT("inline","width","offsetWidth"),FV=xT("block","height","offsetHeight");function $V({target:e,borderBoxSize:t}){var n;(n=vu.get(e))==null||n.forEach(r=>{r(e,{get width(){return LV(e,t)},get height(){return FV(e,t)}})})}function BV(e){e.forEach($V)}function VV(){typeof ResizeObserver>"u"||(Hr=new ResizeObserver(BV))}function UV(e,t){Hr||VV();const n=Jv(e);return n.forEach(r=>{let s=vu.get(r);s||(s=new Set,vu.set(r,s)),s.add(t),Hr==null||Hr.observe(r)}),()=>{n.forEach(r=>{const s=vu.get(r);s==null||s.delete(t),s!=null&&s.size||Hr==null||Hr.unobserve(r)})}}const yu=new Set;let ao;function zV(){ao=()=>{const e={get width(){return window.innerWidth},get height(){return window.innerHeight}};yu.forEach(t=>t(e))},window.addEventListener("resize",ao)}function WV(e){return yu.add(e),ao||zV(),()=>{yu.delete(e),!yu.size&&typeof ao=="function"&&(window.removeEventListener("resize",ao),ao=void 0)}}function Bm(e,t){return typeof e=="function"?WV(e):UV(e,t)}function bT(e,t){let n;const r=()=>{const{currentTime:s}=t,o=(s===null?0:s.value)/100;n!==o&&e(o),n=o};return fe.preUpdate(r,!0),()=>un(r)}function HV(e){return ty(e)&&e.tagName==="svg"}function KV(...e){const t=!Array.isArray(e[0]),n=t?0:-1,r=e[0+n],s=e[1+n],i=e[2+n],o=e[3+n],a=Uv(s,i,o);return t?a(r):a}const qV=[...hT,We,Nn],YV=e=>qV.find(fT(e)),Dx=()=>({translate:0,scale:1,origin:0,originPoint:0}),lo=()=>({x:Dx(),y:Dx()}),Ix=()=>({min:0,max:0}),Ye=()=>({x:Ix(),y:Ix()}),GV=new WeakMap;function df(e){return e!==null&&typeof e=="object"&&typeof e.start=="function"}function Rl(e){return typeof e=="string"||Array.isArray(e)}const ny=["animate","whileInView","whileFocus","whileHover","whileTap","whileDrag","exit"],ry=["initial",...ny];function ff(e){return df(e.animate)||ry.some(t=>Rl(e[t]))}function _T(e){return!!(ff(e)||e.variants)}function QV(e,t,n){for(const r in t){const s=t[r],i=n[r];if(nt(s))e.addValue(r,s);else if(nt(i))e.addValue(r,An(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,An(o!==void 0?o:s,{owner:e}))}}for(const r in n)t[r]===void 0&&e.removeValue(r);return t}const Vm={current:null},ST={current:!1},ZV=typeof window<"u";function JV(){if(ST.current=!0,!!ZV)if(window.matchMedia){const e=window.matchMedia("(prefers-reduced-motion)"),t=()=>Vm.current=e.matches;e.addEventListener("change",t),t()}else Vm.current=!1}const Lx=["AnimationStart","AnimationComplete","Update","BeforeLayoutMeasure","LayoutMeasure","LayoutAnimationStart","LayoutAnimationComplete"];let yd={};function kT(e){yd=e}function XV(){return yd}class eU{scrapeMotionValuesFromProps(t,n,r){return{}}constructor({parent:t,props:n,presenceContext:r,reducedMotionConfig:s,skipAnimations:i,blockInitialAnimation:o,visualState:a},l={}){this.current=null,this.children=new Set,this.isVariantNode=!1,this.isControllingVariants=!1,this.shouldReduceMotion=null,this.shouldSkipAnimations=!1,this.values=new Map,this.KeyframeResolver=Wv,this.features={},this.valueSubscriptions=new Map,this.prevMotionValues={},this.hasBeenMounted=!1,this.events={},this.propEventSubscriptions={},this.notifyUpdate=()=>this.notify("Update",this.latestValues),this.render=()=>{this.current&&(this.triggerBuild(),this.renderInstance(this.current,this.renderState,this.props.style,this.projection))},this.renderScheduledAt=0,this.scheduleRender=()=>{const p=yt.now();this.renderScheduledAt<p&&(this.renderScheduledAt=p,fe.render(this.render,!1,!0))};const{latestValues:c,renderState:u}=a;this.latestValues=c,this.baseTarget={...c},this.initialValues=n.initial?{...c}:{},this.renderState=u,this.parent=t,this.props=n,this.presenceContext=r,this.depth=t?t.depth+1:0,this.reducedMotionConfig=s,this.skipAnimationsConfig=i,this.options=l,this.blockInitialAnimation=!!o,this.isControllingVariants=ff(n),this.isVariantNode=_T(n),this.isVariantNode&&(this.variantChildren=new Set),this.manuallyAnimateOnMount=!!(t&&t.current);const{willChange:d,...h}=this.scrapeMotionValuesFromProps(n,{},this);for(const p in h){const b=h[p];c[p]!==void 0&&nt(b)&&b.set(c[p])}}mount(t){var n,r;if(this.hasBeenMounted)for(const s in this.initialValues)(n=this.values.get(s))==null||n.jump(this.initialValues[s]),this.latestValues[s]=this.initialValues[s];this.current=t,GV.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((s,i)=>this.bindToMotionValue(i,s)),this.reducedMotionConfig==="never"?this.shouldReduceMotion=!1:this.reducedMotionConfig==="always"?this.shouldReduceMotion=!0:(ST.current||JV(),this.shouldReduceMotion=Vm.current),this.shouldSkipAnimations=this.skipAnimationsConfig??!1,(r=this.parent)==null||r.addChild(this),this.update(this.props,this.presenceContext),this.hasBeenMounted=!0}unmount(){var t;this.projection&&this.projection.unmount(),un(this.notifyUpdate),un(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){if(this.valueSubscriptions.has(t)&&this.valueSubscriptions.get(t)(),n.accelerate&&sT.has(t)&&this.current instanceof HTMLElement){const{factory:o,keyframes:a,times:l,ease:c,duration:u}=n.accelerate,d=new nT({element:this.current,name:t,keyframes:a,times:l,ease:c,duration:Mt(u)}),h=o(d);this.valueSubscriptions.set(t,()=>{h(),d.cancel()});return}const r=oa.has(t);r&&this.onBindTransform&&this.onBindTransform();const s=n.on("change",o=>{this.latestValues[t]=o,this.props.onUpdate&&fe.preRender(this.notifyUpdate),r&&this.projection&&(this.projection.isTransformDirty=!0),this.scheduleRender()});let i;typeof window<"u"&&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 yd){const n=yd[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):Ye()}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<Lx.length;r++){const s=Lx[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=QV(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=An(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"&&(_C(r)||kC(r))?r=parseFloat(r):!YV(r)&&Nn.test(n)&&(r=mT(t,n)),this.setBaseTarget(t,nt(r)?r.get():r)),nt(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=Gv(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&&!nt(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 Ov),this.events[t].add(n)}notify(t,...n){this.events[t]&&this.events[t].notify(...n)}scheduleRenderMicrotask(){Xv.render(this.render)}}class ET extends eU{constructor(){super(...arguments),this.KeyframeResolver=TV}sortInstanceNodePosition(t,n){return t.compareDocumentPosition(n)&2?1:-1}getBaseTargetFromProps(t,n){const r=t.style;return r?r[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;nt(t)&&(this.childSubscription=t.on("change",n=>{this.current&&(this.current.textContent=`${n}`)}))}}class Ms{constructor(t){this.isMounted=!1,this.node=t}update(){}}function CT({top:e,left:t,right:n,bottom:r}){return{x:{min:t,max:n},y:{min:e,max:r}}}function tU({x:e,y:t}){return{top:t.min,right:e.max,bottom:t.max,left:e.min}}function nU(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 Oh(e){return e===void 0||e===1}function Um({scale:e,scaleX:t,scaleY:n}){return!Oh(e)||!Oh(t)||!Oh(n)}function Hs(e){return Um(e)||TT(e)||e.z||e.rotate||e.rotateX||e.rotateY||e.skewX||e.skewY}function TT(e){return Fx(e.x)||Fx(e.y)}function Fx(e){return e&&e!=="0%"}function wd(e,t,n){const r=e-n,s=t*r;return n+s}function $x(e,t,n,r,s){return s!==void 0&&(e=wd(e,s,r)),wd(e,n,r)+t}function zm(e,t=0,n=1,r,s){e.min=$x(e.min,t,n,r,s),e.max=$x(e.max,t,n,r,s)}function AT(e,{x:t,y:n}){zm(e.x,t.translate,t.scale,t.originPoint),zm(e.y,n.translate,n.scale,n.originPoint)}const Bx=.999999999999,Vx=1.0000000000001;function rU(e,t,n,r=!1){var a;const s=n.length;if(!s)return;t.x=t.y=1;let i,o;for(let l=0;l<s;l++){i=n[l],o=i.projectionDelta;const{visualElement:c}=i.options;c&&c.props.style&&c.props.style.display==="contents"||(r&&i.options.layoutScroll&&i.scroll&&i!==i.root&&(Qn(e.x,-i.scroll.offset.x),Qn(e.y,-i.scroll.offset.y)),o&&(t.x*=o.x.scale,t.y*=o.y.scale,AT(e,o)),r&&Hs(i.latestValues)&&wu(e,i.latestValues,(a=i.layout)==null?void 0:a.layoutBox))}t.x<Vx&&t.x>Bx&&(t.x=1),t.y<Vx&&t.y>Bx&&(t.y=1)}function Qn(e,t){e.min+=t,e.max+=t}function Ux(e,t,n,r,s=.5){const i=Ae(e.min,e.max,s);zm(e,t,n,i,r)}function zx(e,t){return typeof e=="string"?parseFloat(e)/100*(t.max-t.min):e}function wu(e,t,n){const r=n??e;Ux(e.x,zx(t.x,r.x),t.scaleX,t.scale,t.originX),Ux(e.y,zx(t.y,r.y),t.scaleY,t.scale,t.originY)}function PT(e,t){return CT(nU(e.getBoundingClientRect(),t))}function sU(e,t,n){const r=PT(e,n),{scroll:s}=t;return s&&(Qn(r.x,s.offset.x),Qn(r.y,s.offset.y)),r}const iU={x:"translateX",y:"translateY",z:"translateZ",transformPerspective:"perspective"},oU=ia.length;function aU(e,t,n){let r="",s=!0;for(let i=0;i<oU;i++){const o=ia[i],a=e[o];if(a===void 0)continue;let l=!0;if(typeof a=="number")l=a===(o.startsWith("scale")?1:0);else{const c=parseFloat(a);l=o.startsWith("scale")?c===1:c===0}if(!l||n){const c=gT(a,Zv[o]);if(!l){s=!1;const u=iU[o]||o;r+=`${u}(${c}) `}n&&(t[o]=c)}}return r=r.trim(),n?r=n(t,s?"":r):s&&(r="none"),r}function sy(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(oa.has(l)){o=!0;continue}else if(FC(l)){s[l]=c;continue}else{const u=gT(c,Zv[l]);l.startsWith("origin")?(a=!0,i[l]=u):r[l]=u}}if(t.transform||(o||n?r.transform=aU(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}`}}function jT(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 Wx(e,t){return t.max===t.min?0:e/(t.max-t.min)*100}const ka={correct:(e,t)=>{if(!t.target)return e;if(typeof e=="string")if(K.test(e))e=parseFloat(e);else return e;const n=Wx(e,t.target.x),r=Wx(e,t.target.y);return`${n}% ${r}%`}},lU={correct:(e,{treeScale:t,projectionDelta:n})=>{const r=e,s=Nn.parse(e);if(s.length>5)return r;const i=Nn.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=Ae(a,l,.5);return typeof s[2+o]=="number"&&(s[2+o]/=c),typeof s[3+o]=="number"&&(s[3+o]/=c),i(s)}},Wm={borderRadius:{...ka,applyTo:["borderTopLeftRadius","borderTopRightRadius","borderBottomLeftRadius","borderBottomRightRadius"]},borderTopLeftRadius:ka,borderTopRightRadius:ka,borderBottomLeftRadius:ka,borderBottomRightRadius:ka,boxShadow:lU};function NT(e,{layout:t,layoutId:n}){return oa.has(e)||e.startsWith("origin")||(t||n!==void 0)&&(!!Wm[e]||e==="opacity")}function iy(e,t,n){var o;const r=e.style,s=t==null?void 0:t.style,i={};if(!r)return i;for(const a in r)(nt(r[a])||s&&nt(s[a])||NT(a,e)||((o=n==null?void 0:n.getValue(a))==null?void 0:o.liveStyle)!==void 0)&&(i[a]=r[a]);return i}function cU(e){return window.getComputedStyle(e)}class uU extends ET{constructor(){super(...arguments),this.type="html",this.renderInstance=jT}readValueFromInstance(t,n){var r;if(oa.has(n))return(r=this.projection)!=null&&r.isProjecting?Pm(n):PB(t,n);{const s=cU(t),i=(FC(n)?s.getPropertyValue(n):s[n])||0;return typeof i=="string"?i.trim():i}}measureInstanceViewportBox(t,{transformPagePoint:n}){return PT(t,n)}build(t,n,r){sy(t,n,r.transformTemplate)}scrapeMotionValuesFromProps(t,n,r){return iy(t,n,r)}}const dU={offset:"stroke-dashoffset",array:"stroke-dasharray"},fU={offset:"strokeDashoffset",array:"strokeDasharray"};function hU(e,t,n=1,r=0,s=!0){e.pathLength=1;const i=s?dU:fU;e[i.offset]=`${-r}`,e[i.array]=`${t} ${n}`}const pU=["offsetDistance","offsetPath","offsetRotate","offsetAnchor"];function RT(e,{attrX:t,attrY:n,attrScale:r,pathLength:s,pathSpacing:i=1,pathOffset:o=0,...a},l,c,u){if(sy(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);for(const p of pU)d[p]!==void 0&&(h[p]=d[p],delete d[p]);t!==void 0&&(d.x=t),n!==void 0&&(d.y=n),r!==void 0&&(d.scale=r),s!==void 0&&hU(d,s,i,o,!1)}const OT=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"]),MT=e=>typeof e=="string"&&e.toLowerCase()==="svg";function mU(e,t,n,r){jT(e,t,void 0,r);for(const s in t.attrs)e.setAttribute(OT.has(s)?s:Qv(s),t.attrs[s])}function DT(e,t,n){const r=iy(e,t,n);for(const s in e)if(nt(e[s])||nt(t[s])){const i=ia.indexOf(s)!==-1?"attr"+s.charAt(0).toUpperCase()+s.substring(1):s;r[i]=e[s]}return r}class gU extends ET{constructor(){super(...arguments),this.type="svg",this.isSVGTag=!1,this.measureInstanceViewportBox=Ye}getBaseTargetFromProps(t,n){return t[n]}readValueFromInstance(t,n){if(oa.has(n)){const r=pT(n);return r&&r.default||0}return n=OT.has(n)?n:Qv(n),t.getAttribute(n)}scrapeMotionValuesFromProps(t,n,r){return DT(t,n,r)}build(t,n,r){RT(t,n,this.isSVGTag,r.transformTemplate,r.style)}renderInstance(t,n,r,s){mU(t,n,r,s)}mount(t){this.isSVGTag=MT(t.tagName),super.mount(t)}}const vU=ry.length;function IT(e){if(!e)return;if(!e.isControllingVariants){const n=e.parent?IT(e.parent)||{}:{};return e.props.initial!==void 0&&(n.initial=e.props.initial),n}const t={};for(let n=0;n<vU;n++){const r=ry[n],s=e.props[r];(Rl(s)||s===!1)&&(t[r]=s)}return t}function LT(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 yU=[...ny].reverse(),wU=ny.length;function xU(e){return t=>Promise.all(t.map(({animation:n,options:r})=>gV(e,n,r)))}function bU(e){let t=xU(e),n=Hx(),r=!0,s=!1;const i=c=>(u,d)=>{var p;const h=ui(e,d,c==="exit"?(p=e.presenceContext)==null?void 0:p.custom:void 0);if(h){const{transition:b,transitionEnd:g,...x}=h;u={...u,...x,...g}}return u};function o(c){t=c(e)}function a(c){const{props:u}=e,d=IT(e.parent)||{},h=[],p=new Set;let b={},g=1/0;for(let y=0;y<wU;y++){const m=yU[y],v=n[m],_=u[m]!==void 0?u[m]:d[m],S=Rl(_),k=m===c?v.isActive:null;k===!1&&(g=y);let E=_===d[m]&&_!==u[m]&&S;if(E&&(r||s)&&e.manuallyAnimateOnMount&&(E=!1),v.protectedKeys={...b},!v.isActive&&k===null||!_&&!v.prevProp||df(_)||typeof _=="boolean")continue;if(m==="exit"&&v.isActive&&k!==!0){v.prevResolvedValues&&(b={...b,...v.prevResolvedValues});continue}const T=_U(v.prevProp,_);let P=T||m===c&&v.isActive&&!E&&S||y>g&&S,A=!1;const B=Array.isArray(_)?_:[_];let I=B.reduce(i(m),{});k===!1&&(I={});const{prevResolvedValues:Z={}}=v,R={...Z,...I},U=C=>{P=!0,p.has(C)&&(A=!0,p.delete(C)),v.needsAnimating[C]=!0;const j=e.getValue(C);j&&(j.liveStyle=!1)};for(const C in R){const j=I[C],$=Z[C];if(b.hasOwnProperty(C))continue;let Q=!1;Dm(j)&&Dm($)?Q=!LT(j,$):Q=j!==$,Q?j!=null?U(C):p.add(C):j!==void 0&&p.has(C)?U(C):v.protectedKeys[C]=!0}v.prevProp=_,v.prevResolvedValues=I,v.isActive&&(b={...b,...I}),(r||s)&&e.blockInitialAnimation&&(P=!1);const V=E&&T;P&&(!V||A)&&h.push(...B.map(C=>{const j={type:m};if(typeof C=="string"&&(r||s)&&!V&&e.manuallyAnimateOnMount&&e.parent){const{parent:$}=e,Q=ui($,C);if($.enteringChildren&&Q){const{delayChildren:Y}=Q.transition||{};j.delay=iT($.enteringChildren,e,Y)}}return{animation:C,options:j}}))}if(p.size){const y={};if(typeof u.initial!="boolean"){const m=ui(e,Array.isArray(u.initial)?u.initial[0]:u.initial);m&&m.transition&&(y.transition=m.transition)}p.forEach(m=>{const v=e.getBaseTarget(m),_=e.getValue(m);_&&(_.liveStyle=!0),y[m]=v??null}),h.push({animation:y})}let x=!!h.length;return r&&(u.initial===!1||u.initial===u.animate)&&!e.manuallyAnimateOnMount&&(x=!1),r=!1,s=!1,x?t(h):Promise.resolve()}function l(c,u){var h;if(n[c].isActive===u)return Promise.resolve();(h=e.variantChildren)==null||h.forEach(p=>{var b;return(b=p.animationState)==null?void 0:b.setActive(c,u)}),n[c].isActive=u;const d=a(c);for(const p in n)n[p].protectedKeys={};return d}return{animateChanges:a,setActive:l,setAnimateFunction:o,getState:()=>n,reset:()=>{n=Hx(),s=!0}}}function _U(e,t){return typeof t=="string"?t!==e:Array.isArray(t)?!LT(t,e):!1}function Bs(e=!1){return{isActive:e,protectedKeys:{},needsAnimating:{},prevResolvedValues:{}}}function Hx(){return{animate:Bs(!0),whileInView:Bs(),whileHover:Bs(),whileTap:Bs(),whileDrag:Bs(),whileFocus:Bs(),exit:Bs()}}function Hm(e,t){e.min=t.min,e.max=t.max}function vn(e,t){Hm(e.x,t.x),Hm(e.y,t.y)}function Kx(e,t){e.translate=t.translate,e.scale=t.scale,e.originPoint=t.originPoint,e.origin=t.origin}const FT=1e-4,SU=1-FT,kU=1+FT,$T=.01,EU=0-$T,CU=0+$T;function wt(e){return e.max-e.min}function TU(e,t,n){return Math.abs(e-t)<=n}function qx(e,t,n,r=.5){e.origin=r,e.originPoint=Ae(t.min,t.max,e.origin),e.scale=wt(n)/wt(t),e.translate=Ae(n.min,n.max,e.origin)-e.originPoint,(e.scale>=SU&&e.scale<=kU||isNaN(e.scale))&&(e.scale=1),(e.translate>=EU&&e.translate<=CU||isNaN(e.translate))&&(e.translate=0)}function Za(e,t,n,r){qx(e.x,t.x,n.x,r?r.originX:void 0),qx(e.y,t.y,n.y,r?r.originY:void 0)}function Yx(e,t,n,r=0){const s=r?Ae(n.min,n.max,r):n.min;e.min=s+t.min,e.max=e.min+wt(t)}function AU(e,t,n,r){Yx(e.x,t.x,n.x,r==null?void 0:r.x),Yx(e.y,t.y,n.y,r==null?void 0:r.y)}function Gx(e,t,n,r=0){const s=r?Ae(n.min,n.max,r):n.min;e.min=t.min-s,e.max=e.min+wt(t)}function xd(e,t,n,r){Gx(e.x,t.x,n.x,r==null?void 0:r.x),Gx(e.y,t.y,n.y,r==null?void 0:r.y)}function Qx(e,t,n,r,s){return e-=t,e=wd(e,1/n,r),s!==void 0&&(e=wd(e,1/s,r)),e}function PU(e,t=0,n=1,r=.5,s,i=e,o=e){if(ir.test(t)&&(t=parseFloat(t),t=Ae(o.min,o.max,t/100)-o.min),typeof t!="number")return;let a=Ae(i.min,i.max,r);e===i&&(a-=t),e.min=Qx(e.min,t,n,a,s),e.max=Qx(e.max,t,n,a,s)}function Zx(e,t,[n,r,s],i,o){PU(e,t[n],t[r],t[s],t.scale,i,o)}const jU=["x","scaleX","originX"],NU=["y","scaleY","originY"];function Jx(e,t,n,r){Zx(e.x,t,jU,n?n.x:void 0,r?r.x:void 0),Zx(e.y,t,NU,n?n.y:void 0,r?r.y:void 0)}function Xx(e){return e.translate===0&&e.scale===1}function BT(e){return Xx(e.x)&&Xx(e.y)}function eb(e,t){return e.min===t.min&&e.max===t.max}function RU(e,t){return eb(e.x,t.x)&&eb(e.y,t.y)}function tb(e,t){return Math.round(e.min)===Math.round(t.min)&&Math.round(e.max)===Math.round(t.max)}function VT(e,t){return tb(e.x,t.x)&&tb(e.y,t.y)}function nb(e){return wt(e.x)/wt(e.y)}function rb(e,t){return e.translate===t.translate&&e.scale===t.scale&&e.originPoint===t.originPoint}function Hn(e){return[e("x"),e("y")]}function OU(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:p,skewY:b}=n;c&&(r=`perspective(${c}px) ${r}`),u&&(r+=`rotate(${u}deg) `),d&&(r+=`rotateX(${d}deg) `),h&&(r+=`rotateY(${h}deg) `),p&&(r+=`skewX(${p}deg) `),b&&(r+=`skewY(${b}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 UT=["borderTopLeftRadius","borderTopRightRadius","borderBottomLeftRadius","borderBottomRightRadius"],MU=UT.length,sb=e=>typeof e=="string"?parseFloat(e):e,ib=e=>typeof e=="number"||K.test(e);function DU(e,t,n,r,s,i){s?(e.opacity=Ae(0,n.opacity??1,IU(r)),e.opacityExit=Ae(t.opacity??1,0,LU(r))):i&&(e.opacity=Ae(t.opacity??1,n.opacity??1,r));for(let o=0;o<MU;o++){const a=UT[o];let l=ob(t,a),c=ob(n,a);if(l===void 0&&c===void 0)continue;l||(l=0),c||(c=0),l===0||c===0||ib(l)===ib(c)?(e[a]=Math.max(Ae(sb(l),sb(c),r),0),(ir.test(c)||ir.test(l))&&(e[a]+="%")):e[a]=c}(t.rotate||n.rotate)&&(e.rotate=Ae(t.rotate||0,n.rotate||0,r))}function ob(e,t){return e[t]!==void 0?e[t]:e.borderRadius}const IU=zT(0,.5,RC),LU=zT(.5,.95,Ot);function zT(e,t,n){return r=>r<e?0:r>t?1:n(qo(e,t,r))}function FU(e,t,n){const r=nt(e)?e:An(e);return r.start(Yv("",r,t,n)),r.animation}function Ol(e,t,n,r={passive:!0}){return e.addEventListener(t,n,r),()=>e.removeEventListener(t,n)}const $U=(e,t)=>e.depth-t.depth;class BU{constructor(){this.children=[],this.isDirty=!1}add(t){Rv(this.children,t),this.isDirty=!0}remove(t){hd(this.children,t),this.isDirty=!0}forEach(t){this.isDirty&&this.children.sort($U),this.isDirty=!1,this.children.forEach(t)}}function VU(e,t){const n=yt.now(),r=({timestamp:s})=>{const i=s-n;i>=t&&(un(r),e(i-t))};return fe.setup(r,!0),()=>un(r)}function xu(e){return nt(e)?e.get():e}class UU{constructor(){this.members=[]}add(t){Rv(this.members,t);for(let n=this.members.length-1;n>=0;n--){const r=this.members[n];if(r===t||r===this.lead||r===this.prevLead)continue;const s=r.instance;(!s||s.isConnected===!1)&&!r.snapshot&&(hd(this.members,r),r.unmount())}t.scheduleRender()}remove(t){if(hd(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){var n;for(let r=this.members.indexOf(t)-1;r>=0;r--){const s=this.members[r];if(s.isPresent!==!1&&((n=s.instance)==null?void 0:n.isConnected)!==!1)return this.promote(s),!0}return!1}promote(t,n){var s;const r=this.lead;if(t!==r&&(this.prevLead=r,this.lead=t,t.show(),r)){r.updateSnapshot(),t.scheduleRender();const{layoutDependency:i}=r.options,{layoutDependency:o}=t.options;(i===void 0||i!==o)&&(t.resumeFrom=r,n&&(r.preserveOpacity=!0),r.snapshot&&(t.snapshot=r.snapshot,t.snapshot.latestValues=r.animationValues||r.latestValues),(s=t.root)!=null&&s.isUpdating&&(t.isLayoutDirty=!0)),t.options.crossfade===!1&&r.hide()}}exitAnimationComplete(){this.members.forEach(t=>{var n,r,s,i,o;(r=(n=t.options).onExitComplete)==null||r.call(n),(o=(s=t.resumingFrom)==null?void 0:(i=s.options).onExitComplete)==null||o.call(i)})}scheduleRender(){this.members.forEach(t=>t.instance&&t.scheduleRender(!1))}removeLeadSnapshot(){var t;(t=this.lead)!=null&&t.snapshot&&(this.lead.snapshot=void 0)}}const bu={hasAnimatedSinceResize:!0,hasEverUpdated:!1},Mh=["","X","Y","Z"],zU=1e3;let WU=0;function Dh(e,t,n,r){const{latestValues:s}=t;s[e]&&(n[e]=s[e],t.setStaticValue(e,0),r&&(r[e]=0))}function WT(e){if(e.hasCheckedOptimisedAppear=!0,e.root===e)return;const{visualElement:t}=e.options;if(!t)return;const n=uT(t);if(window.MotionHasOptimisedAnimation(n,"transform")){const{layout:s,layoutId:i}=e.options;window.MotionCancelOptimisedAnimation(n,"transform",fe,!(s||i))}const{parent:r}=e;r&&!r.hasCheckedOptimisedAppear&&WT(r)}function HT({attachResizeListener:e,defaultParent:t,measureScroll:n,checkIsScrollRoot:r,resetTransform:s}){return class{constructor(o={},a=t==null?void 0:t()){this.id=WU++,this.animationId=0,this.animationCommitId=0,this.children=new Set,this.options={},this.isTreeAnimating=!1,this.isAnimationBlocked=!1,this.isLayoutDirty=!1,this.isProjectionDirty=!1,this.isSharedProjectionDirty=!1,this.isTransformDirty=!1,this.updateManuallyBlocked=!1,this.updateBlockedByResize=!1,this.isUpdating=!1,this.isSVG=!1,this.needsReset=!1,this.shouldResetTransform=!1,this.hasCheckedOptimisedAppear=!1,this.treeScale={x:1,y:1},this.eventHandlers=new Map,this.hasTreeAnimated=!1,this.layoutVersion=0,this.updateScheduled=!1,this.scheduleUpdate=()=>this.update(),this.projectionUpdateScheduled=!1,this.checkUpdateFailed=()=>{this.isUpdating&&(this.isUpdating=!1,this.clearAllSnapshots())},this.updateProjection=()=>{this.projectionUpdateScheduled=!1,this.nodes.forEach(qU),this.nodes.forEach(XU),this.nodes.forEach(e8),this.nodes.forEach(YU)},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 BU)}addEventListener(o,a){return this.eventHandlers.has(o)||this.eventHandlers.set(o,new Ov),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=ty(o)&&!HV(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;fe.read(()=>{d=window.innerWidth}),e(o,()=>{const p=window.innerWidth;p!==d&&(d=p,this.root.updateBlockedByResize=!0,u&&u(),u=VU(h,250),bu.hasAnimatedSinceResize&&(bu.hasAnimatedSinceResize=!1,this.nodes.forEach(cb)))})}a&&this.root.registerSharedNode(a,this),this.options.animate!==!1&&c&&(a||l)&&this.addEventListener("didUpdate",({delta:u,hasLayoutChanged:d,hasRelativeLayoutChanged:h,layout:p})=>{if(this.isTreeAnimationBlocked()){this.target=void 0,this.relativeTarget=void 0;return}const b=this.options.transition||c.getDefaultTransition()||i8,{onLayoutAnimationStart:g,onLayoutAnimationComplete:x}=c.getProps(),y=!this.targetLayout||!VT(this.targetLayout,p),m=!d&&h;if(this.options.layoutRoot||this.resumeFrom||m||d&&(y||!this.currentAnimation)){this.resumeFrom&&(this.resumingFrom=this.resumeFrom,this.resumingFrom.resumingFrom=void 0);const v={...qv(b,"layout"),onPlay:g,onComplete:x};(c.shouldReduceMotion||this.options.layoutRoot)&&(v.delay=0,v.type=!1),this.startAnimation(v),this.setAnimationOrigin(u,m)}else d||cb(this),this.isLead()&&this.options.onExitComplete&&this.options.onExitComplete();this.targetLayout=p})}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(),un(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(t8),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&&WT(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,(typeof d.latestValues.x=="string"||typeof d.latestValues.y=="string")&&(d.isLayoutDirty=!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()){const l=this.updateBlockedByResize;this.unblockUpdate(),this.updateBlockedByResize=!1,this.clearAllSnapshots(),l&&this.nodes.forEach(QU),this.nodes.forEach(ab);return}if(this.animationId<=this.animationCommitId){this.nodes.forEach(lb);return}this.animationCommitId=this.animationId,this.isUpdating?(this.isUpdating=!1,this.nodes.forEach(ZU),this.nodes.forEach(JU),this.nodes.forEach(HU),this.nodes.forEach(KU)):this.nodes.forEach(lb),this.clearAllSnapshots();const a=yt.now();Ze.delta=Ln(0,1e3/60,a-Ze.timestamp),Ze.timestamp=a,Ze.isProcessing=!0,Ch.update.process(Ze),Ch.preRender.process(Ze),Ch.render.process(Ze),Ze.isProcessing=!1}didUpdate(){this.updateScheduled||(this.updateScheduled=!0,Xv.read(this.scheduleUpdate))}clearAllSnapshots(){this.nodes.forEach(GU),this.sharedNodes.forEach(n8)}scheduleUpdateProjection(){this.projectionUpdateScheduled||(this.projectionUpdateScheduled=!0,fe.preRender(this.updateProjection,!1,!0))}scheduleCheckAfterUnmount(){fe.postRender(()=>{this.isLayoutDirty?this.root.didUpdate():this.root.checkUpdateFailed()})}updateSnapshot(){this.snapshot||!this.instance||(this.snapshot=this.measure(),this.snapshot&&!wt(this.snapshot.measuredBox.x)&&!wt(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||(this.layoutCorrected=Ye()),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&&!BT(this.projectionDelta),l=this.getTransformTemplate(),c=l?l(this.latestValues,""):void 0,u=c!==this.prevTransformTemplateValue;o&&this.instance&&(a||Hs(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)),o8(l),{animationId:this.root.animationId,measuredBox:a,layoutBox:l,latestValues:{},source:this.id}}measurePageBox(){var c;const{visualElement:o}=this.options;if(!o)return Ye();const a=o.measureViewportBox();if(!(((c=this.scroll)==null?void 0:c.wasRoot)||this.path.some(a8))){const{scroll:u}=this.root;u&&(Qn(a.x,u.offset.x),Qn(a.y,u.offset.y))}return a}removeElementScroll(o){var l;const a=Ye();if(vn(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&&vn(a,o),Qn(a.x,d.offset.x),Qn(a.y,d.offset.y))}return a}applyTransform(o,a=!1,l){var u,d;const c=l||Ye();vn(c,o);for(let h=0;h<this.path.length;h++){const p=this.path[h];!a&&p.options.layoutScroll&&p.scroll&&p!==p.root&&(Qn(c.x,-p.scroll.offset.x),Qn(c.y,-p.scroll.offset.y)),Hs(p.latestValues)&&wu(c,p.latestValues,(u=p.layout)==null?void 0:u.layoutBox)}return Hs(this.latestValues)&&wu(c,this.latestValues,(d=this.layout)==null?void 0:d.layoutBox),c}removeTransform(o){var l;const a=Ye();vn(a,o);for(let c=0;c<this.path.length;c++){const u=this.path[c];if(!Hs(u.latestValues))continue;let d;u.instance&&(Um(u.latestValues)&&u.updateSnapshot(),d=Ye(),vn(d,u.measurePageBox())),Jx(a,u.latestValues,(l=u.snapshot)==null?void 0:l.layoutBox,d)}return Hs(this.latestValues)&&Jx(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!==Ze.timestamp&&this.relativeParent.resolveTargetDelta(!0)}resolveTargetDelta(o=!1){var p;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||(p=this.parent)!=null&&p.isProjectionDirty||this.attemptToResolveRelativeTarget||this.root.updateBlockedByResize))return;const{layout:u,layoutId:d}=this.options;if(!this.layout||!(u||d))return;this.resolvedRelativeTargetAt=Ze.timestamp;const h=this.getClosestProjectingParent();h&&this.linkedParentVersion!==h.layoutVersion&&!h.options.layoutRoot&&this.removeRelativeTarget(),!this.targetDelta&&!this.relativeTarget&&(this.options.layoutAnchor!==!1&&h&&h.layout?this.createRelativeTarget(h,this.layout.layoutBox,h.layout.layoutBox):this.removeRelativeTarget()),!(!this.relativeTarget&&!this.targetDelta)&&(this.target||(this.target=Ye(),this.targetWithTransforms=Ye()),this.relativeTarget&&this.relativeTargetOrigin&&this.relativeParent&&this.relativeParent.target?(this.forceRelativeParentToResolveTarget(),AU(this.target,this.relativeTarget,this.relativeParent.target,this.options.layoutAnchor||void 0)):this.targetDelta?(this.resumingFrom?this.applyTransform(this.layout.layoutBox,!1,this.target):vn(this.target,this.layout.layoutBox),AT(this.target,this.targetDelta)):vn(this.target,this.layout.layoutBox),this.attemptToResolveRelativeTarget&&(this.attemptToResolveRelativeTarget=!1,this.options.layoutAnchor!==!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||Um(this.parent.latestValues)||TT(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=Ye(),this.relativeTargetOrigin=Ye(),xd(this.relativeTargetOrigin,a,l,this.options.layoutAnchor||void 0),vn(this.relativeTarget,this.relativeTargetOrigin)}removeRelativeTarget(){this.relativeParent=this.relativeTarget=void 0}calcProjection(){var b;const o=this.getLead(),a=!!this.resumingFrom||this!==o;let l=!0;if((this.isProjectionDirty||(b=this.parent)!=null&&b.isProjectionDirty)&&
vendor: 5,333 bytes, line 244
244(l=!1),a&&(this.isSharedProjectionDirty||this.isTransformDirty)&&(l=!1),this.resolvedRelativeTargetAt===Ze.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;vn(this.layoutCorrected,this.layout.layoutBox);const d=this.treeScale.x,h=this.treeScale.y;rU(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=Ye());const{target:p}=o;if(!p){this.prevProjectionDelta&&(this.createProjectionDeltas(),this.scheduleRender());return}!this.projectionDelta||!this.prevProjectionDelta?this.createProjectionDeltas():(Kx(this.prevProjectionDelta.x,this.projectionDelta.x),Kx(this.prevProjectionDelta.y,this.projectionDelta.y)),Za(this.projectionDelta,this.layoutCorrected,p,this.latestValues),(this.treeScale.x!==d||this.treeScale.y!==h||!rb(this.projectionDelta.x,this.prevProjectionDelta.x)||!rb(this.projectionDelta.y,this.prevProjectionDelta.y))&&(this.hasProjected=!0,this.scheduleRender(),this.notifyListeners("projectionUpdate",p))}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=lo(),this.projectionDelta=lo(),this.projectionDeltaWithTransform=lo()}setAnimationOrigin(o,a=!1){const l=this.snapshot,c=l?l.latestValues:{},u={...this.latestValues},d=lo();(!this.relativeParent||!this.relativeParent.options.layoutRoot)&&(this.relativeTarget=this.relativeTargetOrigin=void 0),this.attemptToResolveRelativeTarget=!a;const h=Ye(),p=l?l.source:void 0,b=this.layout?this.layout.source:void 0,g=p!==b,x=this.getStack(),y=!x||x.members.length<=1,m=!!(g&&!y&&this.options.crossfade===!0&&!this.path.some(s8));this.animationProgress=0;let v;this.mixTargetDelta=_=>{const S=_/1e3;ub(d.x,o.x,S),ub(d.y,o.y,S),this.setTargetDelta(d),this.relativeTarget&&this.relativeTargetOrigin&&this.layout&&this.relativeParent&&this.relativeParent.layout&&(xd(h,this.layout.layoutBox,this.relativeParent.layout.layoutBox,this.options.layoutAnchor||void 0),r8(this.relativeTarget,this.relativeTargetOrigin,h,S),v&&RU(this.relativeTarget,v)&&(this.isProjectionDirty=!1),v||(v=Ye()),vn(v,this.relativeTarget)),g&&(this.animationValues=u,DU(u,c,this.latestValues,S,m,y)),this.root.scheduleUpdateProjection(),this.scheduleRender(),this.animationProgress=S},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&&(un(this.pendingAnimation),this.pendingAnimation=void 0),this.pendingAnimation=fe.update(()=>{bu.hasAnimatedSinceResize=!0,this.motionValue||(this.motionValue=An(0)),this.motionValue.jump(0,!1),this.currentAnimation=FU(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(zU),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&&KT(this.options.animationType,this.layout.layoutBox,c.layoutBox)){l=this.target||Ye();const d=wt(this.layout.layoutBox.x);l.x.min=o.target.x.min,l.x.max=l.x.min+d;const h=wt(this.layout.layoutBox.y);l.y.min=o.target.y.min,l.y.max=l.y.min+h}vn(a,l),wu(a,u),Za(this.projectionDeltaWithTransform,this.layoutCorrected,a,u)}}registerSharedNode(o,a){this.sharedNodes.has(o)||this.sharedNodes.set(o,new UU),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}
vendor: 4,506 bytes, line 244
244resetSkewAndRotation(){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&&Dh("z",o,c,this.animationValues);for(let u=0;u<Mh.length;u++)Dh(`rotate${Mh[u]}`,o,c,this.animationValues),Dh(`skew${Mh[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=xu(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=xu(a==null?void 0:a.pointerEvents)||""),this.hasProjected&&!Hs(this.latestValues)&&(o.transform=l?l({},""):"none",this.hasProjected=!1);return}o.visibility="";const u=c.animationValues||c.latestValues;this.applyTransformsToTarget();let d=OU(this.projectionDeltaWithTransform,this.treeScale,u);l&&(d=l(u,d)),o.transform=d;const{x:h,y:p}=this.projectionDelta;o.transformOrigin=`${h.origin*100}% ${p.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 b in Wm){if(u[b]===void 0)continue;const{correct:g,applyTo:x,isCSSVariable:y}=Wm[b],m=d==="none"?u[b]:g(u[b],c);if(x){const v=x.length;for(let _=0;_<v;_++)o[x[_]]=m}else y?this.options.visualElement.renderState.vars[b]=m:o[b]=m}this.options.layoutId&&(o.pointerEvents=c===this?xu(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(ab),this.root.sharedNodes.clear()}}}function HU(e){e.updateLayout()}function KU(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;if(i==="size")Hn(d=>{const h=o?t.measuredBox[d]:t.layoutBox[d],p=wt(h);h.min=r[d].min,h.max=h.min+p});else if(i==="x"||i==="y"){const d=i==="x"?"y":"x";Hm(o?t.measuredBox[d]:t.layoutBox[d],r[d])}else KT(i,t.layoutBox,r)&&Hn(d=>{const h=o?t.measuredBox[d]:t.layoutBox[d],p=wt(r[d]);h.max=h.min+p,e.relativeTarget&&!e.currentAnimation&&(e.isProjectionDirty=!0,e.relativeTarget[d].max=e.relativeTarget[d].min+p)});const a=lo();Za(a,r,t.layoutBox);const l=lo();o?Za(l,e.applyTransform(s,!0),t.measuredBox):Za(l,r,t.layoutBox);const c=!BT(a);let u=!1;if(!e.resumeFrom){const d=e.getClosestProjectingParent();if(d&&!d.resumeFrom){const{snapshot:h,layout:p}=d;if(h&&p){const b=e.options.layoutAnchor||void 0,g=Ye();xd(g,t.layoutBox,h.layoutBox,b);const x=Ye();xd(x,r,p.layoutBox,b),VT(g,x)||(u=!0),d.options.layoutRoot&&(e.relativeTarget=x,e.relativeTargetOrigin=g,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 qU(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 YU(e){e.isProjectionDirty=e.isSharedProjectionDirty=e.isTransformDirty=!1}function GU(e){e.clearSnapshot()}function ab(e){e.clearMeasurements()}function QU(e){e.isLayoutDirty=!0,e.updateLayout()}function lb(e){e.isLayoutDirty=!1}function ZU(e){e.isAnimationBlocked&&e.layout&&!e.isLayoutDirty&&(e.snapshot=e.layout,e.isLayoutDirty=!0)}function JU(e){const{visualElement:t}=e.options;t&&t.getProps().onBeforeLayoutMeasure&&t.notify("BeforeLayoutMeasure"),e.resetTransform()}function cb(e){e.finishAnimation(),e.targetDelta=e.relativeTarget=e.target=void 0,e.isProjectionDirty=!0}function XU(e){e.resolveTargetDelta()}function e8(e){e.calcProjection()}
244function t8(e){e.resetSkewAndRotation()}function n8(e){e.removeLeadSnapshot()}function ub(e,t,n){e.translate=Ae(t.translate,0,n),e.scale=Ae(t.scale,1,n),e.origin=t.origin,e.originPoint=t.originPoint}function db(e,t,n,r){e.min=Ae(t.min,n.min,r),e.max=Ae(t.max,n.max,r)}function r8(e,t,n,r){db(e.x,t.x,n.x,r),db(e.y,t.y,n.y,r)}function s8(e){return e.animationValues&&e.animationValues.opacityExit!==void 0}const i8={duration:.45,ease:[.4,0,.1,1]},fb=e=>typeof navigator<"u"&&navigator.userAgent&&navigator.userAgent.toLowerCase().includes(e),hb=fb("applewebkit/")&&!fb("chrome/")?Math.round:Ot;function pb(e){e.min=hb(e.min),e.max=hb(e.max)}function o8(e){pb(e.x),pb(e.y)}function KT(e,t,n){return e==="position"||e==="preserve-aspect"&&!TU(nb(t),nb(n),.2)}function a8(e){var t;return e!==e.root&&((t=e.scroll)==null?void 0:t.wasRoot)}const l8=HT({attachResizeListener:(e,t)=>Ol(e,"resize",t),measureScroll:()=>{var e,t;return{x:document.documentElement.scrollLeft||((e=document.body)==null?void 0:e.scrollLeft)||0,y:document.documentElement.scrollTop||((t=document.body)==null?void 0:t.scrollTop)||0}},checkIsScrollRoot:()=>!0}),Ih={current:void 0},qT=HT({measureScroll:e=>({x:e.scrollLeft,y:e.scrollTop}),defaultParent:()=>{if(!Ih.current){const e=new l8({});e.mount(window),e.setOptions({layoutScroll:!0}),Ih.current=e}return Ih.current},resetTransform:(e,t)=>{e.style.transform=t!==void 0?t:"none"},checkIsScrollRoot:e=>window.getComputedStyle(e).position==="fixed"}),hf=w.createContext({transformPagePoint:e=>e,isStatic:!1,reducedMotion:"never"});function mb(e,t){if(typeof e=="function")return e(t);e!=null&&(e.current=t)}function c8(...e){return t=>{let n=!1;const r=e.map(s=>{const i=mb(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():mb(e[s],null)}}}}function u8(...e){return w.useCallback(c8(...e),e)}class d8 extends w.Component{getSnapshotBeforeUpdate(t){const n=this.props.childRef.current;if(Qa(n)&&t.isPresent&&!this.props.isPresent&&this.props.pop!==!1){const r=n.offsetParent,s=Qa(r)&&r.offsetWidth||0,i=Qa(r)&&r.offsetHeight||0,o=getComputedStyle(n),a=this.props.sizeRef.current;a.height=parseFloat(o.height),a.width=parseFloat(o.width),a.top=n.offsetTop,a.left=n.offsetLeft,a.right=s-a.width-a.left,a.bottom=i-a.height-a.top}return null}componentDidUpdate(){}render(){return this.props.children}}function f8({children:e,isPresent:t,anchorX:n,anchorY:r,root:s,pop:i}){var h;const o=w.useId(),a=w.useRef(null),l=w.useRef({width:0,height:0,top:0,left:0,right:0,bottom:0}),{nonce:c}=w.useContext(hf),u=((h=e.props)==null?void 0:h.ref)??(e==null?void 0:e.ref),d=u8(a,u);return w.useInsertionEffect(()=>{const{width:p,height:b,top:g,left:x,right:y,bottom:m}=l.current;if(t||i===!1||!a.current||!p||!b)return;const v=n==="left"?`left: ${x}`:`right: ${y}`,_=r==="bottom"?`bottom: ${m}`:`top: ${g}`;a.current.dataset.motionPopId=o;const S=document.createElement("style");c&&(S.nonce=c);const k=s??document.head;return k.appendChild(S),S.sheet&&S.sheet.insertRule(`
245          [data-motion-pop-id="${o}"] {
246            position: absolute !important;
247            width: ${p}px !important;
248            height: ${b}px !important;
249            ${v}px !important;
250            ${_}px !important;
251          }
252        `),()=>{var E;(E=a.current)==null||E.removeAttribute("data-motion-pop-id"),k.contains(S)&&k.removeChild(S)}},[t]),f.jsx(d8,{isPresent:t,childRef:a,sizeRef:l,pop:i,children:i===!1?e:w.cloneElement(e,{ref:d})})}const h8=({children:e,initial:t,isPresent:n,onExitComplete:r,custom:s,presenceAffectsLayout:i,mode:o,anchorX:a,anchorY:l,root:c})=>{const u=Es(p8),d=w.useId();let h=!0,p=w.useMemo(()=>(h=!1,{id:d,initial:t,isPresent:n,custom:s,onExitComplete:b=>{u.set(b,!0);for(const g of u.values())if(!g)return;r&&r()},register:b=>(u.set(b,!1),()=>u.delete(b))}),[n,u,r]);return i&&h&&(p={...p}),w.useMemo(()=>{u.forEach((b,g)=>u.set(g,!1))},[n]),w.useEffect(()=>{!n&&!u.size&&r&&r()},[n]),e=f.jsx(f8,{pop:o==="popLayout",isPresent:n,anchorX:a,anchorY:l,root:c,children:e}),f.jsx(lf.Provider,{value:p,children:e})};function p8(){return new Map}function YT(e=!0){const t=w.useContext(lf);if(t===null)return[!0,null];const{isPresent:n,onExitComplete:r,register:s}=t,i=w.useId();w.useEffect(()=>{if(e)return s(i)},[e]);const o=w.useCallback(()=>e&&r&&r(i),[i,r,e]);return!n&&r?[!1,o]:[!0]}const zc=e=>e.key||"";function gb(e){const t=[];
vendor: 8,843 bytes, line 252
252return w.Children.forEach(e,n=>{w.isValidElement(n)&&t.push(n)}),t}const Lh=({children:e,custom:t,initial:n=!0,onExitComplete:r,presenceAffectsLayout:s=!0,mode:i="sync",propagate:o=!1,anchorX:a="left",anchorY:l="top",root:c})=>{const[u,d]=YT(o),h=w.useMemo(()=>gb(e),[e]),p=o&&!u?[]:h.map(zc),b=w.useRef(!0),g=w.useRef(h),x=Es(()=>new Map),y=w.useRef(new Set),[m,v]=w.useState(h),[_,S]=w.useState(h);af(()=>{b.current=!1,g.current=h;for(let T=0;T<_.length;T++){const P=zc(_[T]);p.includes(P)?(x.delete(P),y.current.delete(P)):x.get(P)!==!0&&x.set(P,!1)}},[_,p.length,p.join("-")]);const k=[];if(h!==m){let T=[...h];for(let P=0;P<_.length;P++){const A=_[P],B=zc(A);p.includes(B)||(T.splice(P,0,A),k.push(A))}return i==="wait"&&k.length&&(T=k),S(gb(T)),v(h),null}const{forceRender:E}=w.useContext(Nv);return f.jsx(f.Fragment,{children:_.map(T=>{const P=zc(T),A=o&&!u?!1:h===_||p.includes(P),B=()=>{if(y.current.has(P))return;if(x.has(P))y.current.add(P),x.set(P,!0);else return;let I=!0;x.forEach(Z=>{Z||(I=!1)}),I&&(E==null||E(),S(g.current),o&&(d==null||d()),r&&r())};return f.jsx(h8,{isPresent:A,initial:!b.current||n?void 0:!1,custom:t,presenceAffectsLayout:s,mode:i,root:c,onExitComplete:A?void 0:B,anchorX:a,anchorY:l,children:T},P)})})},GT=w.createContext({strict:!1}),vb={animation:["animate","variants","whileHover","whileTap","exit","whileInView","whileFocus","whileDrag"],exit:["exit"],drag:["drag","dragControls"],focus:["whileFocus"],hover:["whileHover","onHoverStart","onHoverEnd"],tap:["whileTap","onTap","onTapStart","onTapCancel"],pan:["onPan","onPanStart","onPanSessionStart","onPanEnd"],inView:["whileInView","onViewportEnter","onViewportLeave"],layout:["layout","layoutId"]};let yb=!1;function m8(){if(yb)return;const e={};for(const t in vb)e[t]={isEnabled:n=>vb[t].some(r=>!!n[r])};kT(e),yb=!0}function QT(){return m8(),XV()}function g8(e){const t=QT();for(const n in e)t[n]={...t[n],...e[n]};kT(t)}const v8=new Set(["animate","exit","variants","initial","style","values","variants","transition","transformTemplate","custom","inherit","onBeforeLayoutMeasure","onAnimationStart","onAnimationComplete","onUpdate","onDragStart","onDrag","onDragEnd","onMeasureDragConstraints","onDirectionLock","onDragTransitionEnd","_dragX","_dragY","onHoverStart","onHoverEnd","onViewportEnter","onViewportLeave","globalTapTarget","propagate","ignoreStrict","viewport"]);function bd(e){return e.startsWith("while")||e.startsWith("drag")&&e!=="draggable"||e.startsWith("layout")||e.startsWith("onTap")||e.startsWith("onPan")||e.startsWith("onLayout")||v8.has(e)}let ZT=e=>!bd(e);function y8(e){typeof e=="function"&&(ZT=t=>t.startsWith("on")?!bd(t):e(t))}try{y8(require("@emotion/is-prop-valid").default)}catch{}function w8(e,t,n){const r={};for(const s in e)s==="values"&&typeof e.values=="object"||nt(e[s])||(ZT(s)||n===!0&&bd(s)||!t&&!bd(s)||e.draggable&&s.startsWith("onDrag"))&&(r[s]=e[s]);return r}const pf=w.createContext({});function x8(e,t){if(ff(e)){const{initial:n,animate:r}=e;return{initial:n===!1||Rl(n)?n:void 0,animate:Rl(r)?r:void 0}}return e.inherit!==!1?t:{}}function b8(e){const{initial:t,animate:n}=x8(e,w.useContext(pf));return w.useMemo(()=>({initial:t,animate:n}),[wb(t),wb(n)])}function wb(e){return Array.isArray(e)?e.join(" "):e}const oy=()=>({style:{},transform:{},transformOrigin:{},vars:{}});function JT(e,t,n){for(const r in t)!nt(t[r])&&!NT(r,n)&&(e[r]=t[r])}function _8({transformTemplate:e},t){return w.useMemo(()=>{const n=oy();return sy(n,t,e),Object.assign({},n.vars,n.style)},[t])}function S8(e,t){const n=e.style||{},r={};return JT(r,n,e),Object.assign(r,_8(e,t)),r}function k8(e,t){const n={},r=S8(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 XT=()=>({...oy(),attrs:{}});function E8(e,t,n,r){const s=w.useMemo(()=>{const i=XT();return RT(i,t,MT(r),e.transformTemplate,e.style),{...i.attrs,style:{...i.style}}},[t]);if(e.style){const i={};JT(i,e.style,e),s.style={...i,...s.style}}return s}const C8=["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 ay(e){return typeof e!="string"||e.includes("-")?!1:!!(C8.indexOf(e)>-1||/[A-Z]/u.test(e))}function T8(e,t,n,{latestValues:r},s,i=!1,o){const l=(o??ay(e)?E8:k8)(t,r,s,e),c=w8(t,typeof e=="string",i),u=e!==w.Fragment?{...c,...l,ref:n}:{},{children:d}=t,h=w.useMemo(()=>nt(d)?d.get():d,[d]);return w.createElement(e,{...u,children:h})}function A8({scrapeMotionValuesFromProps:e,createRenderState:t},n,r,s){return{latestValues:P8(n,r,s,e),renderState:t()}}function P8(e,t,n,r){const s={},i=r(e,{});for(const h in i)s[h]=xu(i[h]);let{initial:o,animate:a}=e;const l=ff(e),c=_T(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"&&!df(d)){const h=Array.isArray(d)?d:[d];for(let p=0;p<h.length;p++){const b=Gv(e,h[p]);if(b){const{transitionEnd:g,transition:x,...y}=b;for(const m in y){let v=y[m];if(Array.isArray(v)){const _=u?v.length-1:0;v=v[_]}v!==null&&(s[m]=v)}for(const m in g)s[m]=g[m]}}}return s}const eA=e=>(t,n)=>{const r=w.useContext(pf),s=w.useContext(lf),i=()=>A8(e,t,r,s);return n?i():Es(i)},j8=eA({scrapeMotionValuesFromProps:iy,createRenderState:oy}),N8=eA({scrapeMotionValuesFromProps:DT,createRenderState:XT}),R8=Symbol.for("motionComponentSymbol");function O8(e,t,n){const r=w.useRef(n);w.useInsertionEffect(()=>{r.current=n});const s=w.useRef(null);return w.useCallback(i=>{var a;i&&((a=e.onMount)==null||a.call(e,i));const o=r.current;if(typeof o=="function")if(i){const l=o(i);typeof l=="function"&&(s.current=l)}else s.current?(s.current(),s.current=null):o(i);else o&&(o.current=i);t&&(i?t.mount(i):t.unmount())},[t])}const tA=w.createContext({});function qi(e){return e&&typeof e=="object"&&Object.prototype.hasOwnProperty.call(e,"current")}function M8(e,t,n,r,s,i){var v,_;const{visualElement:o}=w.useContext(pf),a=w.useContext(GT),l=w.useContext(lf),c=w.useContext(hf),u=c.reducedMotion,d=c.skipAnimations,h=w.useRef(null),p=w.useRef(!1);r=r||a.renderer,!h.current&&r&&(h.current=r(e,{visualState:t,parent:o,props:n,presenceContext:l,blockInitialAnimation:l?l.initial===!1:!1,reducedMotionConfig:u,skipAnimations:d,isSVG:i}),p.current&&h.current&&(h.current.manuallyAnimateOnMount=!0));const b=h.current,g=w.useContext(tA);b&&!b.projection&&s&&(b.type==="html"||b.type==="svg")&&D8(h.current,n,s,g);const x=w.useRef(!1);w.useInsertionEffect(()=>{b&&x.current&&b.update(n,l)});const y=n[cT],m=w.useRef(!!y&&typeof window<"u"&&!((v=window.MotionHandoffIsComplete)!=null&&v.call(window,y))&&((_=window.MotionHasOptimisedAnimation)==null?void 0:_.call(window,y)));return af(()=>{p.current=!0,b&&(x.current=!0,window.MotionIsMounted=!0,b.updateFeatures(),b.scheduleRenderMicrotask(),m.current&&b.animationState&&b.animationState.animateChanges())}),w.useEffect(()=>{b&&(!m.current&&b.animationState&&b.animationState.animateChanges(),m.current&&(queueMicrotask(()=>{var S;(S=window.MotionHandoffMarkAsComplete)==null||S.call(window,y)}),m.current=!1),b.enteringChildren=void 0)}),b}function D8(e,t,n,r){const{layoutId:s,layout:i,drag:o,dragConstraints:a,layoutScroll:l,layoutRoot:c,layoutAnchor:u,layoutCrossfade:d}=t;e.projection=new n(e.latestValues,t["data-framer-portal-id"]?void 0:nA(e.parent)),e.projection.setOptions({layoutId:s,layout:i,alwaysMeasureLayout:!!o||a&&qi(a),visualElement:e,animationType:typeof i=="string"?i:"both",initialPromotionConfig:r,crossfade:d,layoutScroll:l,layoutRoot:c,layoutAnchor:u})}function nA(e){if(e)return e.options.allowProjection!==!1?e.projection:nA(e.parent)}function Fh(e,{forwardMotionProps:t=!1,type:n}={},r,s){r&&g8(r);const i=n?n==="svg":ay(e),o=i?N8:j8;function a(c,u){let d;const h={...w.useContext(hf),...c,layoutId:I8(c)},{isStatic:p}=h,b=b8(c),g=o(c,p);if(!p&&typeof window<"u"){L8();const x=F8(h);d=x.MeasureLayout,b.visualElement=M8(e,g,h,s,x.ProjectionNode,i)}return f.jsxs(pf.Provider,{value:b,children:[d&&b.visualElement?f.jsx(d,{visualElement:b.visualElement,...h}):null,T8(e,c,O8(g,b.visualElement,u),g,p,t,i)]})}a.displayName=`motion.${typeof e=="string"?e:`create(${e.displayName??e.name??""})`}`;const l=w.forwardRef(a);return l[R8]=e,l}function I8({layoutId:e}){const t=w.useContext(Nv).id;return t&&e!==void 0?t+"-"+e:e}function L8(e,t){w.useContext(GT).strict}function F8(e){const t=QT(),{drag:n,layout:r}=t;if(!n&&!r)return{};const s={...n,...r};return{MeasureLayout:n!=null&&n.isEnabled(e)||r!=null&&r.isEnabled(e)?s.MeasureLayout:void 0,ProjectionNode:s.ProjectionNode}}
vendor: 18,495 bytes, line 252
252function $8(e,t){if(typeof Proxy>"u")return Fh;const n=new Map,r=(i,o)=>Fh(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,Fh(o,void 0,e,t)),n.get(o))})}const B8=(e,t)=>t.isSVG??ay(e)?new gU(t):new uU(t,{allowProjection:e!==w.Fragment});class V8 extends Ms{constructor(t){super(t),t.animationState||(t.animationState=bU(t))}updateAnimationControlsSubscription(){const{animate:t}=this.node.getProps();df(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 U8=0;class z8 extends Ms{constructor(){super(...arguments),this.id=U8++,this.isExitComplete=!1}update(){var i;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;if(t&&r===!1){if(this.isExitComplete){const{initial:o,custom:a}=this.node.getProps();if(typeof o=="string"){const l=ui(this.node,o,a);if(l){const{transition:c,transitionEnd:u,...d}=l;for(const h in d)(i=this.node.getValue(h))==null||i.jump(d[h])}}this.node.animationState.reset(),this.node.animationState.animateChanges()}else this.node.animationState.setActive("exit",!1);this.isExitComplete=!1;return}const s=this.node.animationState.setActive("exit",!t);n&&!t&&s.then(()=>{this.isExitComplete=!0,n(this.id)})}mount(){const{register:t,onExitComplete:n}=this.node.presenceContext||{};n&&n(this.id),t&&(this.unmount=t(this.id))}unmount(){}}const W8={animation:{Feature:V8},exit:{Feature:z8}};function oc(e){return{point:{x:e.pageX,y:e.pageY}}}const H8=e=>t=>ey(t)&&e(t,oc(t));function Ja(e,t,n,r){return Ol(e,t,H8(n),r)}const rA=({current:e})=>e?e.ownerDocument.defaultView:null,xb=(e,t)=>Math.abs(e-t);function K8(e,t){const n=xb(e.x,t.x),r=xb(e.y,t.y);return Math.sqrt(n**2+r**2)}const bb=new Set(["auto","scroll"]);class sA{constructor(t,n,{transformPagePoint:r,contextWindow:s=window,dragSnapToOrigin:i=!1,distanceThreshold:o=3,element:a}={}){if(this.startEvent=null,this.lastMoveEvent=null,this.lastMoveEventInfo=null,this.lastRawMoveEventInfo=null,this.handlers={},this.contextWindow=window,this.scrollPositions=new Map,this.removeScrollListeners=null,this.onElementScroll=p=>{this.handleScroll(p.target)},this.onWindowScroll=()=>{this.handleScroll(window)},this.updatePoint=()=>{if(!(this.lastMoveEvent&&this.lastMoveEventInfo))return;this.lastRawMoveEventInfo&&(this.lastMoveEventInfo=Wc(this.lastRawMoveEventInfo,this.transformPagePoint));const p=$h(this.lastMoveEventInfo,this.history),b=this.startEvent!==null,g=K8(p.offset,{x:0,y:0})>=this.distanceThreshold;if(!b&&!g)return;const{point:x}=p,{timestamp:y}=Ze;this.history.push({...x,timestamp:y});const{onStart:m,onMove:v}=this.handlers;b||(m&&m(this.lastMoveEvent,p),this.startEvent=this.lastMoveEvent),v&&v(this.lastMoveEvent,p)},this.handlePointerMove=(p,b)=>{this.lastMoveEvent=p,this.lastRawMoveEventInfo=b,this.lastMoveEventInfo=Wc(b,this.transformPagePoint),fe.update(this.updatePoint,!0)},this.handlePointerUp=(p,b)=>{this.end();const{onEnd:g,onSessionEnd:x,resumeAnimation:y}=this.handlers;if((this.dragSnapToOrigin||!this.startEvent)&&y&&y(),!(this.lastMoveEvent&&this.lastMoveEventInfo))return;const m=$h(p.type==="pointercancel"?this.lastMoveEventInfo:Wc(b,this.transformPagePoint),this.history);this.startEvent&&g&&g(p,m),x&&x(p,m)},!ey(t))return;this.dragSnapToOrigin=i,this.handlers=n,this.transformPagePoint=r,this.distanceThreshold=o,this.contextWindow=s||window;const l=oc(t),c=Wc(l,this.transformPagePoint),{point:u}=c,{timestamp:d}=Ze;this.history=[{...u,timestamp:d}];const{onSessionStart:h}=n;h&&h(t,$h(c,this.history)),this.removeListeners=rc(Ja(this.contextWindow,"pointermove",this.handlePointerMove),Ja(this.contextWindow,"pointerup",this.handlePointerUp),Ja(this.contextWindow,"pointercancel",this.handlePointerUp)),a&&this.startScrollTracking(a)}startScrollTracking(t){let n=t.parentElement;for(;n;){const r=getComputedStyle(n);(bb.has(r.overflowX)||bb.has(r.overflowY))&&this.scrollPositions.set(n,{x:n.scrollLeft,y:n.scrollTop}),n=n.parentElement}this.scrollPositions.set(window,{x:window.scrollX,y:window.scrollY}),window.addEventListener("scroll",this.onElementScroll,{capture:!0}),window.addEventListener("scroll",this.onWindowScroll),this.removeScrollListeners=()=>{window.removeEventListener("scroll",this.onElementScroll,{capture:!0}),window.removeEventListener("scroll",this.onWindowScroll)}}handleScroll(t){const n=this.scrollPositions.get(t);if(!n)return;const r=t===window,s=r?{x:window.scrollX,y:window.scrollY}:{x:t.scrollLeft,y:t.scrollTop},i={x:s.x-n.x,y:s.y-n.y};i.x===0&&i.y===0||(r?this.lastMoveEventInfo&&(this.lastMoveEventInfo.point.x+=i.x,this.lastMoveEventInfo.point.y+=i.y):this.history.length>0&&(this.history[0].x-=i.x,this.history[0].y-=i.y),this.scrollPositions.set(t,s),fe.update(this.updatePoint,!0))}updateHandlers(t){this.handlers=t}end(){this.removeListeners&&this.removeListeners(),this.removeScrollListeners&&this.removeScrollListeners(),this.scrollPositions.clear(),un(this.updatePoint)}}function Wc(e,t){return t?{point:t(e.point)}:e}function _b(e,t){return{x:e.x-t.x,y:e.y-t.y}}function $h({point:e},t){return{point:e,delta:_b(e,iA(t)),offset:_b(e,q8(t)),velocity:Y8(t,.1)}}function q8(e){return e[0]}function iA(e){return e[e.length-1]}function Y8(e,t){if(e.length<2)return{x:0,y:0};let n=e.length-1,r=null;const s=iA(e);for(;n>=0&&(r=e[n],!(s.timestamp-r.timestamp>Mt(t)));)n--;if(!r)return{x:0,y:0};r===e[0]&&e.length>2&&s.timestamp-r.timestamp>Mt(t)*2&&(r=e[1]);const i=sn(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 G8(e,{min:t,max:n},r){return t!==void 0&&e<t?e=r?Ae(t,e,r.min):Math.max(e,t):n!==void 0&&e>n&&(e=r?Ae(n,e,r.max):Math.min(e,n)),e}function Sb(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 Q8(e,{top:t,left:n,bottom:r,right:s}){return{x:Sb(e.x,n,s),y:Sb(e.y,t,r)}}function kb(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 Z8(e,t){return{x:kb(e.x,t.x),y:kb(e.y,t.y)}}function J8(e,t){let n=.5;const r=wt(e),s=wt(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 X8(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 Km=.35;function ez(e=Km){return e===!1?e=0:e===!0&&(e=Km),{x:Eb(e,"left","right"),y:Eb(e,"top","bottom")}}function Eb(e,t,n){return{min:Cb(e,t),max:Cb(e,n)}}function Cb(e,t){return typeof e=="number"?e:e[t]||0}const tz=new WeakMap;class nz{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=Ye(),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=>{n&&this.snapToCursor(oc(d).point),this.stopAnimation()},o=(d,h)=>{const{drag:p,dragPropagation:b,onDragStart:g}=this.getProps();if(p&&!b&&(this.openDragLock&&this.openDragLock(),this.openDragLock=AV(p),!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),Hn(y=>{let m=this.getAxisMotionValue(y).get()||0;if(ir.test(m)){const{projection:v}=this.visualElement;if(v&&v.layout){const _=v.layout.layoutBox[y];_&&(m=wt(_)*(parseFloat(m)/100))}}this.originPoint[y]=m}),g&&fe.update(()=>g(d,h),!1,!0),Im(this.visualElement,"transform");const{animationState:x}=this.visualElement;x&&x.setActive("whileDrag",!0)},a=(d,h)=>{this.latestPointerEvent=d,this.latestPanInfo=h;const{dragPropagation:p,dragDirectionLock:b,onDirectionLock:g,onDrag:x}=this.getProps();if(!p&&!this.openDragLock)return;const{offset:y}=h;if(b&&this.currentDirection===null){this.currentDirection=sz(y),this.currentDirection!==null&&g&&g(this.currentDirection);return}this.updateAxis("x",h.point,y),this.updateAxis("y",h.point,y),this.visualElement.render(),x&&fe.update(()=>x(d,h),!1,!0)},l=(d,h)=>{this.latestPointerEvent=d,this.latestPanInfo=h,this.stop(d,h),this.latestPointerEvent=null,this.latestPanInfo=null},c=()=>{const{dragSnapToOrigin:d}=this.getProps();(d||this.constraints)&&this.startAnimation({x:0,y:0})},{dragSnapToOrigin:u}=this.getProps();this.panSession=new sA(t,{onSessionStart:i,onStart:o,onMove:a,onSessionEnd:l,resumeAnimation:c},{transformPagePoint:this.visualElement.getTransformPagePoint(),dragSnapToOrigin:u,distanceThreshold:r,contextWindow:rA(this.visualElement),element:this.visualElement.current})}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&&fe.postRender(()=>a(r,s))}cancel(){this.isDragging=!1;const{projection:t,animationState:n}=this.visualElement;t&&(t.isAnimationBlocked=!1),this.endPanSession();const{dragPropagation:r}=this.getProps();!r&&this.openDragLock&&(this.openDragLock(),this.openDragLock=null),n&&n.setActive("whileDrag",!1)}endPanSession(){this.panSession&&this.panSession.end(),this.panSession=void 0}updateAxis(t,n,r){const{drag:s}=this.getProps();if(!r||!Hc(t,s,this.currentDirection))return;const i=this.getAxisMotionValue(t);let o=this.originPoint[t]+r[t];this.constraints&&this.constraints[t]&&(o=G8(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&&qi(t)?this.constraints||(this.constraints=this.resolveRefConstraints()):t&&r?this.constraints=Q8(r.layoutBox,t):this.constraints=!1,this.elastic=ez(n),s!==this.constraints&&!qi(t)&&r&&this.constraints&&!this.hasMutatedConstraints&&Hn(o=>{this.constraints!==!1&&this.getAxisMotionValue(o)&&(this.constraints[o]=X8(r.layoutBox[o],this.constraints[o]))})}resolveRefConstraints(){const{dragConstraints:t,onMeasureDragConstraints:n}=this.getProps();if(!t||!qi(t))return!1;const r=t.current;Cs(r!==null,"If `dragConstraints` is set as a React ref, that ref must be passed to another component's `ref` prop.","drag-constraints-ref");const{projection:s}=this.visualElement;if(!s||!s.layout)return!1;const i=sU(r,s.root,this.visualElement.getTransformPagePoint());let o=Z8(s.layout.layoutBox,i);if(n){const a=n(tU(o));this.hasMutatedConstraints=!!a,a&&(o=CT(a))}return o}startAnimation(t){const{drag:n,dragMomentum:r,dragElastic:s,dragTransition:i,dragSnapToOrigin:o,onDragTransitionEnd:a}=this.getProps(),l=this.constraints||{},c=Hn(u=>{if(!Hc(u,n,this.currentDirection))return;let d=l&&l[u]||{};(o===!0||o===u)&&(d={min:0,max:0});const h=s?200:1e6,p=s?40:1e7,b={type:"inertia",velocity:r?t[u]:0,bounceStiffness:h,bounceDamping:p,timeConstant:750,restDelta:1,restSpeed:10,...i,...d};return this.startAxisValueAnimation(u,b)});return Promise.all(c).then(a)}startAxisValueAnimation(t,n){const r=this.getAxisMotionValue(t);return Im(this.visualElement,t),r.start(Yv(t,r,0,n,this.visualElement,!1))}stopAnimation(){Hn(t=>this.getAxisMotionValue(t).stop())}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){Hn(n=>{const{drag:r}=this.getProps();if(!Hc(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],l=i.get()||0;i.set(t[n]-Ae(o,a,.5)+l)}})}scalePositionWithinConstraints(){if(!this.visualElement.current)return;const{drag:t,dragConstraints:n}=this.getProps(),{projection:r}=this.visualElement;if(!qi(n)||!r||!this.constraints)return;this.stopAnimation();const s={x:0,y:0};Hn(o=>{const a=this.getAxisMotionValue(o);if(a&&this.constraints!==!1){const l=a.get();s[o]=J8({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.constraints=!1,this.resolveConstraints(),Hn(o=>{if(!Hc(o,t,null))return;const a=this.getAxisMotionValue(o),{min:l,max:c}=this.constraints[o];a.set(Ae(l,c,s[o]))}),this.visualElement.render()}addListeners(){if(!this.visualElement.current)return;tz.set(this.visualElement,this);const t=this.visualElement.current,n=Ja(t,"pointerdown",c=>{const{drag:u,dragListener:d=!0}=this.getProps(),h=c.target,p=h!==t&&MV(h);u&&d&&!p&&this.start(c)});let r;const s=()=>{const{dragConstraints:c}=this.getProps();qi(c)&&c.current&&(this.constraints=this.resolveRefConstraints(),r||(r=rz(t,c.current,()=>this.scalePositionWithinConstraints())))},{projection:i}=this.visualElement,o=i.addEventListener("measure",s);i&&!i.layout&&(i.root&&i.root.updateScroll(),i.updateLayout()),fe.read(s);const a=Ol(window,"resize",()=>this.scalePositionWithinConstraints()),l=i.addEventListener("didUpdate",({delta:c,hasLayoutChanged:u})=>{this.isDragging&&u&&(Hn(d=>{const h=this.getAxisMotionValue(d);h&&(this.originPoint[d]+=c[d].translate,h.set(h.get()+c[d].translate))}),this.visualElement.render())});return()=>{a(),n(),o(),l&&l(),r&&r()}}getProps(){const t=this.visualElement.getProps(),{drag:n=!1,dragDirectionLock:r=!1,dragPropagation:s=!1,dragConstraints:i=!1,dragElastic:o=Km,dragMomentum:a=!0}=t;return{...t,drag:n,dragDirectionLock:r,dragPropagation:s,dragConstraints:i,dragElastic:o,dragMomentum:a}}}function Tb(e){let t=!0;return()=>{if(t){t=!1;return}e()}}function rz(e,t,n){const r=Bm(e,Tb(n)),s=Bm(t,Tb(n));return()=>{r(),s()}}function Hc(e,t,n){return(t===!0||t===e)&&(n===null||n===e)}function sz(e,t=10){let n=null;return Math.abs(e.y)>t?n="y":Math.abs(e.x)>t&&(n="x"),n}class iz extends Ms{constructor(t){super(t),this.removeGroupControls=Ot,this.removeListeners=Ot,this.controls=new nz(t)}mount(){const{dragControls:t}=this.node.getProps();t&&(this.removeGroupControls=t.subscribe(this.controls)),this.removeListeners=this.controls.addListeners()||Ot}update(){const{dragControls:t}=this.node.getProps(),{dragControls:n}=this.node.prevProps||{};t!==n&&(this.removeGroupControls(),t&&(this.removeGroupControls=t.subscribe(this.controls)))}unmount(){this.removeGroupControls(),this.removeListeners(),this.controls.isDragging||this.controls.endPanSession()}}const Bh=e=>(t,n)=>{e&&fe.update(()=>e(t,n),!1,!0)};class oz extends Ms{constructor(){super(...arguments),this.removePointerDownListener=Ot}onPointerDown(t){this.session=new sA(t,this.createPanHandlers(),{transformPagePoint:this.node.getTransformPagePoint(),contextWindow:rA(this.node)})}createPanHandlers(){const{onPanSessionStart:t,onPanStart:n,onPan:r,onPanEnd:s}=this.node.getProps();return{onSessionStart:Bh(t),onStart:Bh(n),onMove:Bh(r),onEnd:(i,o)=>{delete this.session,s&&fe.postRender(()=>s(i,o))}}}mount(){this.removePointerDownListener=Ja(this.node.current,"pointerdown",t=>this.onPointerDown(t))}update(){this.session&&this.session.updateHandlers(this.createPanHandlers())}unmount(){this.removePointerDownListener(),this.session&&this.session.end()}}let Vh=!1;class az extends w.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),Vh&&i.root.didUpdate(),i.addEventListener("animationComplete",()=>{this.safeToRemove()}),i.setOptions({...i.options,layoutDependency:this.props.layoutDependency,onExitComplete:()=>this.safeToRemove()})),bu.hasEverUpdated=!0}getSnapshotBeforeUpdate(t){const{layoutDependency:n,visualElement:r,drag:s,isPresent:i}=this.props,{projection:o}=r;return o&&(o.isPresent=i,t.layoutDependency!==n&&o.setOptions({...o.options,layoutDependency:n}),Vh=!0,s||t.layoutDependency!==n||n===void 0||t.isPresent!==i?o.willUpdate():this.safeToRemove(),t.isPresent!==i&&(i?o.promote():o.relegate()||fe.postRender(()=>{const a=o.getStack();(!a||!a.members.length)&&this.safeToRemove()}))),null}componentDidUpdate(){const{visualElement:t,layoutAnchor:n}=this.props,{projection:r}=t;r&&(r.options.layoutAnchor=n,r.root.didUpdate(),Xv.postRender(()=>{!r.currentAnimation&&r.isLead()&&this.safeToRemove()}))}componentWillUnmount(){const{visualElement:t,layoutGroup:n,switchLayoutGroup:r}=this.props,{projection:s}=t;Vh=!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 oA(e){const[t,n]=YT(),r=w.useContext(Nv);return f.jsx(az,{...e,layoutGroup:r,switchLayoutGroup:w.useContext(tA),isPresent:t,safeToRemove:n})}const lz={pan:{Feature:oz},drag:{Feature:iz,ProjectionNode:qT,MeasureLayout:oA}};function Ab(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&&fe.postRender(()=>i(t,oc(t)))}class cz extends Ms{mount(){const{current:t}=this.node;t&&(this.unmount=jV(t,(n,r)=>(Ab(this.node,r,"Start"),s=>Ab(this.node,s,"End"))))}unmount(){}}class uz extends Ms{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=rc(Ol(this.node.current,"focus",()=>this.onFocus()),Ol(this.node.current,"blur",()=>this.onBlur()))}unmount(){}}function Pb(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&&fe.postRender(()=>i(t,oc(t)))}class dz extends Ms{mount(){const{current:t}=this.node;if(!t)return;
252const{globalTapTarget:n,propagate:r}=this.node.props;this.unmount=IV(t,(s,i)=>(Pb(this.node,i,"Start"),(o,{success:a})=>Pb(this.node,o,a?"End":"Cancel")),{useGlobalTarget:n,stopPropagation:(r==null?void 0:r.tap)===!1})}unmount(){}}const qm=new WeakMap,Uh=new WeakMap,fz=e=>{const t=qm.get(e.target);t&&t(e)},hz=e=>{e.forEach(fz)};function pz({root:e,...t}){const n=e||document;Uh.has(n)||Uh.set(n,{});const r=Uh.get(n),s=JSON.stringify(t);return r[s]||(r[s]=new IntersectionObserver(hz,{root:e,...t})),r[s]}function mz(e,t,n){const r=pz(t);return qm.set(e,n),r.observe(e),()=>{qm.delete(e),r.unobserve(e)}}const gz={some:0,all:1};class vz extends Ms{constructor(){super(...arguments),this.hasEnteredView=!1,this.isInView=!1}startObserver(){var l;(l=this.stopObserver)==null||l.call(this);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:gz[s]},a=c=>{const{isIntersecting:u}=c;if(this.isInView===u||(this.isInView=u,i&&!u&&this.hasEnteredView))return;u&&(this.hasEnteredView=!0),this.node.animationState&&this.node.animationState.setActive("whileInView",u);const{onViewportEnter:d,onViewportLeave:h}=this.node.getProps(),p=u?d:h;p&&p(c)};this.stopObserver=mz(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(yz(t,n))&&this.startObserver()}unmount(){var t;(t=this.stopObserver)==null||t.call(this),this.hasEnteredView=!1,this.isInView=!1}}function yz({viewport:e={}},{viewport:t={}}={}){return n=>e[n]!==t[n]}const wz={inView:{Feature:vz},tap:{Feature:dz},focus:{Feature:uz},hover:{Feature:cz}},xz={layout:{ProjectionNode:qT,MeasureLayout:oA}},bz={...W8,...wz,...lz,...xz},_e=$8(bz,B8);function _d(e){return typeof window>"u"?!1:e?JC():Kv()}const _z=50,jb=()=>({current:0,offset:[],progress:0,scrollLength:0,targetOffset:0,targetLength:0,containerLength:0,velocity:0}),Sz=()=>({time:0,x:jb(),y:jb()}),kz={x:{length:"Width",position:"Left"},y:{length:"Height",position:"Top"}};function Nb(e,t,n,r){const s=n[t],{length:i,position:o}=kz[t],a=s.current,l=n.time;s.current=Math.abs(e[`scroll${o}`]),s.scrollLength=e[`scroll${i}`]-e[`client${i}`],s.offset.length=0,s.offset[0]=0,s.offset[1]=s.scrollLength,s.progress=qo(0,s.scrollLength,s.current);const c=r-l;s.velocity=c>_z?0:Mv(s.current-a,c)}function Ez(e,t,n){Nb(e,"x",t,n),Nb(e,"y",t,n),t.time=n}function Cz(e,t){const n={x:0,y:0};let r=e;for(;r&&r!==t;)if(Qa(r))n.x+=r.offsetLeft,n.y+=r.offsetTop,r=r.offsetParent;else if(r.tagName==="svg"){const s=r.getBoundingClientRect();r=r.parentElement;const i=r.getBoundingClientRect();n.x+=s.left-i.left,n.y+=s.top-i.top}else if(r instanceof SVGGraphicsElement){const{x:s,y:i}=r.getBBox();n.x+=s,n.y+=i;let o=null,a=r.parentNode;for(;!o;)a.tagName==="svg"&&(o=a),a=r.parentNode;r=o}else break;return n}const Ym={start:0,center:.5,end:1};function Rb(e,t,n=0){let r=0;if(e in Ym&&(e=Ym[e]),typeof e=="string"){const s=parseFloat(e);e.endsWith("px")?r=s:e.endsWith("%")?e=s/100:e.endsWith("vw")?r=s/100*document.documentElement.clientWidth:e.endsWith("vh")?r=s/100*document.documentElement.clientHeight:e=s}return typeof e=="number"&&(r=t*e),n+r}const Tz=[0,0];function Az(e,t,n,r){let s=Array.isArray(e)?e:Tz,i=0,o=0;return typeof e=="number"?s=[e,e]:typeof e=="string"&&(e=e.trim(),e.includes(" ")?s=e.split(" "):s=[e,Ym[e]?e:"0"]),i=Rb(s[0],n,r),o=Rb(s[1],t),i-o}const Oa={Enter:[[0,1],[1,1]],Exit:[[0,0],[1,0]],Any:[[1,0],[0,1]],All:[[0,0],[1,1]]},Pz={x:0,y:0};function jz(e){return"getBBox"in e&&e.tagName!=="svg"?e.getBBox():{width:e.clientWidth,height:e.clientHeight}}function Nz(e,t,n){const{offset:r=Oa.All}=n,{target:s=e,axis:i="y"}=n,o=i==="y"?"height":"width",a=s!==e?Cz(s,e):Pz,l=s===e?{width:e.scrollWidth,height:e.scrollHeight}:jz(s),c={width:e.clientWidth,height:e.clientHeight};t[i].offset.length=0;let u=!t[i].interpolate;const d=r.length;for(let h=0;h<d;h++){const p=Az(r[h],c[o],l[o],a[i]);!u&&p!==t[i].interpolatorOffsets[h]&&(u=!0),t[i].offset[h]=p}u&&(t[i].interpolate=Uv(t[i].offset,qC(r),{clamp:!1}
252),t[i].interpolatorOffsets=[...t[i].offset]),t[i].progress=Ln(0,1,t[i].interpolate(t[i].current))}function Rz(e,t=e,n){if(n.x.targetOffset=0,n.y.targetOffset=0,t!==e){let r=t;for(;r&&r!==e;)n.x.targetOffset+=r.offsetLeft,n.y.targetOffset+=r.offsetTop,r=r.offsetParent}n.x.targetLength=t===e?t.scrollWidth:t.clientWidth,n.y.targetLength=t===e?t.scrollHeight:t.clientHeight,n.x.containerLength=e.clientWidth,n.y.containerLength=e.clientHeight}function Oz(e,t,n,r={}){return{measure:s=>{Rz(e,r.target,n),Ez(e,n,s),(r.offset||r.target)&&Nz(e,n,r)},notify:()=>t(n)}}const zi=new WeakMap,Ob=new WeakMap,zh=new WeakMap,Mb=new WeakMap,Kc=new WeakMap,Db=e=>e===document.scrollingElement?window:e;function aA(e,{container:t=document.scrollingElement,trackContentSize:n=!1,...r}={}){if(!t)return Ot;let s=zh.get(t);s||(s=new Set,zh.set(t,s));const i=Sz(),o=Oz(t,e,i,r);if(s.add(o),!zi.has(t)){const l=()=>{for(const h of s)h.measure(Ze.timestamp);fe.preUpdate(c)},c=()=>{for(const h of s)h.notify()},u=()=>fe.read(l);zi.set(t,u);const d=Db(t);window.addEventListener("resize",u),t!==document.documentElement&&Ob.set(t,Bm(t,u)),d.addEventListener("scroll",u),u()}if(n&&!Kc.has(t)){const l=zi.get(t),c={width:t.scrollWidth,height:t.scrollHeight};Mb.set(t,c);const u=()=>{const h=t.scrollWidth,p=t.scrollHeight;(c.width!==h||c.height!==p)&&(l(),c.width=h,c.height=p)},d=fe.read(u,!0);Kc.set(t,d)}const a=zi.get(t);return fe.read(a,!1,!0),()=>{var d;un(a);const l=zh.get(t);if(!l||(l.delete(o),l.size))return;const c=zi.get(t);zi.delete(t),c&&(Db(t).removeEventListener("scroll",c),(d=Ob.get(t))==null||d(),window.removeEventListener("resize",c));const u=Kc.get(t);u&&(un(u),Kc.delete(t)),Mb.delete(t)}}const Mz=[[Oa.Enter,"entry"],[Oa.Exit,"exit"],[Oa.Any,"cover"],[Oa.All,"contain"]],Ib={start:0,end:1};function Dz(e){const t=e.trim().split(/\s+/);if(t.length!==2)return;const n=Ib[t[0]],r=Ib[t[1]];if(!(n===void 0||r===void 0))return[n,r]}function Iz(e){if(e.length!==2)return;const t=[];for(const n of e)if(Array.isArray(n))t.push(n);else if(typeof n=="string"){const r=Dz(n);if(!r)return;t.push(r)}else return;return t}function Lz(e,t){const n=Iz(e);if(!n)return!1;for(let r=0;r<2;r++){const s=n[r],i=t[r];if(s[0]!==i[0]||s[1]!==i[1])return!1}return!0}function ly(e){if(!e)return{rangeStart:"contain 0%",rangeEnd:"contain 100%"};for(const[t,n]of Mz)if(Lz(e,t))return{rangeStart:`${n} 0%`,rangeEnd:`${n} 100%`}}const Lb=new Map;function Fb(e){const t={value:0},n=aA(r=>
252{t.value=r[e.axis].progress*100},e);return{currentTime:t,cancel:n}}function lA({source:e,container:t,...n}){const{axis:r}=n;e&&(t=e);let s=Lb.get(t);s||(s=new Map,Lb.set(t,s));const i=n.target??"self";let o=s.get(i);o||(o={},s.set(i,o));const a=r+(n.offset??[]).join(",");return o[a]||(n.target&&_d(n.target)?ly(n.offset)?o[a]=new ViewTimeline({subject:n.target,axis:r}):o[a]=Fb({container:t,...n}):_d()?o[a]=new ScrollTimeline({source:t,axis:r}):o[a]=Fb({container:t,...n})),o[a]}function Fz(e,t){const n=lA(t),r=t.target?ly(t.offset):void 0,s=t.target?_d(t.target)&&!!r:_d();return e.attachTimeline({timeline:s?n:void 0,...r&&s&&{rangeStart:r.rangeStart,rangeEnd:r.rangeEnd},observe:i=>(i.pause(),bT(o=>{i.time=i.iterationDuration*o},n))})}function $z(e){return e.length===2}function Bz(e,t){return $z(e)?aA(n=>{e(n[t.axis].progress,n)},t):bT(e,lA(t))}function cA(e,{axis:t="y",container:n=document.scrollingElement,...r}={}){if(!n)return Ot;const s={axis:t,container:n,...r};return typeof e=="function"?Bz(e,s):Fz(e,s)}const Vz=()=>({scrollX:An(0),scrollY:An(0),scrollXProgress:An(0),scrollYProgress:An(0)}),qc=e=>e?!e.current:!1;function $b(e,t,n,r){return{factory:s=>cA(s,{...t,axis:e,container:(n==null?void 0:n.current)||void 0,target:(r==null?void 0:r.current)||void 0}),times:[0,1],keyframes:[0,1],ease:s=>s,duration:1}}function Uz(e,t){return typeof window>"u"?!1:e?JC()&&!!ly(t):Kv()}function Bb({container:e,target:t,...n}={}){const r=Es(Vz);Uz(t,n.offset)&&(r.scrollXProgress.accelerate=$b("x",n,e,t),r.scrollYProgress.accelerate=$b("y",n,e,t));const s=w.useRef(null),i=w.useRef(!1),o=w.useCallback(()=>(s.current=cA((a,{x:l,y:c})=>{r.scrollX.set(l.current),r.scrollXProgress.set(l.progress),r.scrollY.set(c.current),r.scrollYProgress.set(c.progress)},{...n,container:(e==null?void 0:e.current)||void 0,target:(t==null?void 0:t.current)||void 0}),()=>{var a;(a=s.current)==null||a.call(s)}),[e,t,JSON.stringify(n.offset)]);return af(()=>{if(i.current=!1,qc(e)||qc(t)){i.current=!0;return}else return o()},[o]),w.useEffect(()=>{if(i.current)return Cs(!qc(e),"Container ref is defined but not hydrated","use-scroll-ref"),Cs(!qc(t),"Target ref is defined but not hydrated","use-scroll-ref"),o()},[o]),r}function zz(e){const t=Es(()=>An(e)),{isStatic:n}=w.useContext(hf);if(n){const[,r]=w.useState(e);w.useEffect(()=>t.on("change",r),[])}return t}function uA(e,t){const n=zz(t()),r=()=>n.set(t());return r(),af(()=>{const s=()=>fe.preRender(r,!1,!0),i=e.map(o=>o.on("change",s));return()=>{i.forEach(o=>o()),un(r)}}),n}function Wz(e){Ga.current=[],e();const t=uA(Ga.current,e);return Ga.current=void 0,t}function _u(e,t,n,r){if(typeof e=="function")return Wz(e);if(n!==void 0&&!Array.isArray(n)&&typeof t!="function")return Hz(e,t,n,r);const o=typeof t=="function"?t:KV(t,n,r),a=Array.isArray(e)?Vb(e,o):Vb([e],([c])=>o(c)),l=Array.isArray(e)?void 0:e.accelerate;return l&&!l.isTransformed&&typeof t!="function"&&Array.isArray(n)&&(r==null?void 0:r.clamp)!==!1&&(a.accelerate={...l,times:t,keyframes:n,isTransformed:!0}),a}function Vb(e,t){const n=Es(()=>[]);return uA(e,()=>{n.length=0;const r=e.length;for(let s=0;s<r;s++)n[s]=e[s].get();return t(n)})}function Hz(e,t,n,r){const s=Es(()=>Object.keys(n)),i=Es(()=>({}));for(const o of s)i[o]=_u(e,t,n[o],r);return i}const Kz={some:0,all:1};function qz(e,t,{root:n,margin:r,amount:s="some"}={}){const i=Jv(e),o=new WeakMap,a=c=>{c.forEach(u=>{const d=o.get(u.target);if(u.isIntersecting!==!!d)if(u.isIntersecting){const h=t(u.target,u);typeof h=="function"?o.set(u.target,h):l.unobserve(u.target)}else typeof d=="function"&&(d(u),o.delete(u.target))})},l=new IntersectionObserver(a,{root:n,rootMargin:r,threshold:typeof s=="number"?s:Kz[s]});return i.forEach(c=>l.observe(c)),()=>l.disconnect()}function Yz(e,{root:t,margin:n,amount:r,once:s=!1,initial:i=!1}={}){const[o,a]=w.useState(i);return w.useEffect(()=>{if(!e.current||s&&o)return;const l=()=>(a(!0),s?void 0:()=>a(!1)),c={root:t&&t.current||void 0,margin:n,amount:r};return qz(e.current,l,c)},[t,e,n,s,r]),o}const Gz="/assets/venue-rwh-D88bVgbu.jpg",Qz="/assets/speaker-geiss-DrPNYaSP.jpg",Zz="/assets/speaker-reuss-BbQFUTmG.jpg",Jz="/assets/speaker-linsenmayer
252-B2hhtFfr.jpg",Xz="/assets/speaker-strobl-DJ08R8_g.jpg",eW="/assets/moderator-gantert-DrYykMUr.jpg",tW="/assets/moderator-herz-BaTAHjH6.jpg",nW="/assets/moderator-naber-Q7vU4OTb.jpg",Wh=[{id:"welcome",label:"Start"},{id:"programm",label:"Programm"},{id:"speaker",label:"Speaker"},{id:"moderation",label:"Moderation"},{id:"insights",label:"Insights"}],rW=[{time:"18:00",label:"Einlass & Registrierung",accent:!1},{time:"18:30",label:"Begrüßung & politische Grußworte",accent:!1},{time:"19:00",label:"Keynote: Stefan Reuss (Würth Industrie)",accent:!0},{time:"19:30",label:"Keynote: Andreas Geiss (Ex Hoechst AG, Siemens AG & Aleph Alpha)",accent:!0},{time:"20:00",label:'Podiumsdiskussion „KI im Mittelstand - Praxis, Perspektiven, Potenziale"',accent:!0},{time:"21:00",label:"Get-together & Networking",accent:!1}],sW=[{name:"Andreas Geiss",role:"Senior Executive",org:`Ex Hoechst AG, Siemens AG &
253Aleph Alpha
254`,photo:Xz,photoPosition:"center 20%",bio:"Vernetzt als globaler Experte über 25 Jahre Industrieerfahrung mit Künstlicher Intelligenz, um klassische Produktionstechnik effizienter zu machen.",linkedin:"https://www.linkedin.com/in/andreas-geiss/"},{name:"Stefan Reuss",role:"Head of Digital Solutions & IT",org:"Würth Industrie Service",photo:Zz,photoPosition:"center 20%",bio:"Treibt die digitale Transformation bei einem der größten Industrieserviceanbieter Europas voran – mit Fokus auf KI-gestützte Logistik.",linkedin:"https://www.linkedin.com/in/stefan-reuss-97943914b/"},{name:"Prof. Dr. Kim Linsenmayer",role:"Leitung des Campus",org:"DHBW Bad Mergentheim",photo:Jz,photoPosition:"center 20%",bio:"Verbindet als DHBW-Campusleiterin Wissenschaft und Praxis, um Belegschaften gezielt auf die KI-gestützte Arbeitswelt von morgen vorzubereiten.",linkedin:"https://www.linkedin.com/in/prof-dr-kim-linsenmayer/"},{name:"Thomas Strobl",role:"Stellv. Ministerpräsident",org:"Minister des Inneren, für Digitalisierung und Kommunen",photo:Qz,photoPosition:"center 20%",bio:"Schafft als Digitalisierungsminister die politischen Rahmenbedingungen, um den ländlichen Raum als innovativen und sicheren KI-Standort zu stärken.",linkedin:"https://im.baden-wuerttemberg.de/de/ministerium/innenminister-thomas-strobl"}],iW=[{name:"Marco Gantert",role:"Kreisvorsitzender",org:"JU Main-Tauber",photo:eW,photoPosition:"center 20%",bio:"Marco ist Business Development Manager und Kreisvorsitzender der JU Main-Tauber. Er verbindet Industrieerfahrung mit regionaler Politik, um die technologische Zukunftsfähigkeit voranzutreiben.",linkedin:"https://www.linkedin.com/in/marcogantert/"},{name:"Maximilian Herz",role:"Mitgliederreferent",org:"JU Main-Tauber",photo:tW,photoPosition:"center 20%",bio:"Maximilian ist Masterabsolvent der Uni Innsbruck in Strategic Management and Innovation, Er setzt akademische Impulse für regionale Netzwerke und technologische Entwicklung in seiner Heimat.",linkedin:"https://www.linkedin.com/in/maximilian-herz-902151228/"},{name:"Mario Mamodaly Naber",role:"Geschäftsführer",org:"JU Main-Tauber",photo:nW,photoPosition:"center 20%",bio:"Mario ist Masterstudent der Uni Heidelberg in Health Service Research. Er analysiert die Schnittstelle von KI und Politik sowie deren praktische Umsetzung unter bestehenden Rahmenbedingungen.",linkedin:"https://www.linkedin.com/in/mario-mamodaly-naber-248423271/"}],oW=[{title:"Die Realitätsfalle – Warum KI-Projekte scheitern",facts:["95 Prozent aller KI-Projekte scheitern nicht an der Technologie. Das eigentliche Hindernis sind unaufgeräumte Daten und veraltete IT-Systeme in den Betrieben. Es herrscht weniger eine Technologie-, sondern vielmehr eine Wissenskrise.","Die deutsche Wirtschaft probiert KI zwar intensiv aus, schöpft daraus aber kaum echten, langfristigen Nutzen. Meist bleibt es bei kleinen Arbeitserleichterungen im Alltag, weil die übergreifende Strategie fehlt und die Verantwortung oft nur an die IT-Abteilung abgegeben wird.","Wer schnelle Wunder erwartet, wird oft enttäuscht. Daten zeigen, dass Unternehmen im Schnitt zwei bis drei Jahre brauchen, bis sich die anfänglichen Investitionen in Künstliche Intelligenz wirklich in zählbarem betrieblichen Erfolg niederschlagen."],linkLabels:["Materna: Warum 95% der KI-Projekte scheitern – und was der Mittelstand daraus lernen muss","Deloitte: Deutschland im KI‑Paradox: Hohe Nutzung – begrenzter strategischer Nutzen"],links:["https://www.materna.de/newshub/blog/data-and-ai/warum-95-der-ki-projekte-scheitern-und-was-der-mittelstand-daraus-lernen-muss/","https://www.deloitte.com/de/de/issues/innovation-ai/deutschland-im-ki-paradox.html?id=de:2sm:3li:4__CBI-AI_AI-ROI-Report-German-Cut:5:6abt:20260303::19726732703"]},{title:"Arbeitsmarkt & Innovation – Die echten Effekte von KI",facts:["Auf dem deutschen Arbeitsmarkt weisen bereits heute rund 34 Prozent der Beschäftigten – das sind fast 12 Millionen Menschen – eine hohe Berührung mit Künstlicher Intelligenz in ihrem Berufsalltag auf.","Entgegen vieler Befürchtungen führt dies laut aktuellen Wirtschaftsdaten bisher nicht zu mehr Arbeitslosigkeit. Allerdings gibt es erste Anzeichen dafür, dass in stark betroffenen Berufsfeldern spürbar weniger Berufseinsteiger neu eingestellt werden.","Während Europa stark auf Regulierung und Risikovermeidung achtet, übernehmen in den USA bereits autonom handelnde KI-Systeme komplexe Aufgaben. Analysten warnen vor einer globalen Verschiebung, bei der zögerliche Regionen technologisch den Anschluss verpassen könnten."],linkLabels:["Anthropic: Labor market impacts of AI: A new measure and early evidence","Karpathy Methode: Mapping AI Exposure Across 35 Million German Jobs","Citrini Research: The 2028 Global Intelligence Crisis"],links:["https://www.anthropic.com/research/labor-market-impacts","https://philipphartmann.substack.com/p/mapping-ai-exposure-across-35-million","https://www.citriniresearch.com/p/2028gic"]},{title:"Faktor Mensch & Ökosysteme – Der Weg zum Erfolg",facts:["Technologie allein reicht nicht. Unternehmen sind nur dann wirklich erfolgreich mit KI, wenn sie den Menschen konsequent in den Mittelpunkt stellen – also die neue Technik einführen und gleichzeitig ihre Belegschaft intensiv dafür schulen und begleiten.","Der weltweite Markt für unabhängige und sichere KI-Lösungen ist enorm und wächst aktuellen SchÃ
254¤tzungen zufolge bis zum Jahr 2030 auf ein Volumen von bis zu 600 Milliarden Dollar an.","Erfolgreiche digitale Souveränität bedeutet nicht, dass sich Europa komplett abschotten muss. Es geht vielmehr um ein kluges Ökosystem: Man nutzt globale Standards, behält aber die absolute Kontrolle und Sicherheit über die eigenen, kritischen Daten."],linkLabels:["Bain & Company: Want More Out of Your AI Investments? Think People First","McKinsey: Losing from day one: Why even successful transformations fall short"],links:["https://www.bain.com/insights/want-more-out-of-your-ai-investments-think-people-first/","https://www.mckinsey.com/capabilities/people-and-organizational-performance/our-insights/successful-transformations#/"]}],Kr={hidden:{opacity:0,y:40},visible:{opacity:1,y:0,transition:{duration:.7,ease:"easeOut"}}},Ea={hidden:{},visible:{transition:{staggerChildren:.15}}},dA={hidden:{opacity:0,scale:.85},visible:{opacity:1,scale:1,transition:{duration:.6,ease:"easeOut"}}},aW={hidden:{opacity:0,x:-30},visible:{opacity:1,x:0,transition:{duration:.5,ease:"easeOut"}}},Yc=({children:e})=>{const t=w.useRef(null),n=Yz(t,{margin:"-20% 0px -70% 0px"});return f.jsx("div",{ref:t,children:f.jsx(_e.h2,{initial:"hidden",whileInView:"visible",viewport:{once:!0,margin:"-80px"},variants:Kr,className:"text-2xl sm:text-4xl font-bold mb-12 sm:mb-16 text-center sticky top-16 z-20 py-4",style:{background:n?"rgba(247,249,252,0.85)":"transparent",backdropFilter:n?"blur(16px)":"none",WebkitBackdropFilter:n?"blur(16px)":"none",transition:"background 0.4s, backdrop-filter 0.4s"},children:f.jsx("span",{className:"wg-text-gradient",children:e})})})},Ub=({speaker:e})=>{var r;const[t,n]=w.useState(!1);return f.jsx(_e.div,{variants:dA,className:`wg-flip-card cursor-pointer ${t?"flipped":""}`,style:{height:"280px"},onClick:()=>n(!t),whileTap:{scale:.98},transition:{type:"spring",stiffness:400,damping:25},children:f.jsxs("div",{className:"wg-flip-card-inner",children:[f.jsxs("div",{className:"wg-flip-card-front wg-glass-panel p-5 sm:p-6 flex flex-col items-center justify-center text-center",children:[f.jsx("div",{className:"w-20 h-20 sm:w-24 sm:h-24 rounded-full mx-auto mb-4 wg-glass-avatar overflow-hidden flex items-center justify-center",children:f.jsx("img",{src:e.photo,alt:e.name,className:"w-full h-full object-cover",style:{objectPosition:e.photoPosition}})}),f.jsx("h3",{className:"text-sm sm:text-base font-bold mb-1 text-[var(--wg-text)]",children:e.name}),f.jsx("p",{className:"text-xs sm:text-sm text-[var(--wg-text-secondary)]",children:e.role}),f.jsx("p",{className:"text-xs text-[var(--wg-blue)] mt-1 font-medium whitespace-pre-line",children:e.org}),f.jsx(Qu,{className:"w-3.5 h-3.5 text-[var(--wg-blue)] opacity-40 mt-3"})]}),f.jsxs("div",{className:"wg-flip-card-back wg-glass-panel p-5 sm:p-6 flex flex-col items-center justify-center text-center",children:[f.jsx("h3",{className:"text-sm sm:text-base font-bold mb-3 text-[var(--wg-text)]",children:e.name}),f.jsx("p",{className:"text-xs sm:text-sm text-[var(--wg-text-secondary)] leading-relaxed",children:e.bio}),e.linkedin&&f.jsxs("a",{href:e.linkedin,target:"_blank",rel:"noopener noreferrer",onClick:s=>s.stopPropagation(),className:"text-xs font-semibold text-wg-blue hover:text-[var(--wg-blue-deep)] transition-colors inline-flex items-center gap-1.5 mt-2",children:[f.jsx(pk,{className:"w-3 h-3"}),(r=e.linkedin)!=null&&r.includes("linkedin.com")?`LinkedIn ${e.name.split(" ")[0]} ${e.name.split(" ").slice(1).join(" ")}`:"Innenministerium Baden-Württemberg"]}),f.jsx(Qu,{className:"w-3.5 h-3.5 text-[var(--wg-blue)] opacity-40 mt-3"})]})]})})},lW=()=>{const[e,t]=w.useState("welcome"),[n,r]=w.useState(null),[s,i]=w.useState(0),[o,a]=w.useState(!1),[l,c]=w.useState(!1),u="DE70 6735 2565 0002 0273 99",d=w.useCallback(async()=>{try{await navigator.clipboard.writeText(u.replace(/\s/g,"")),c(!0),setTimeout(()=>c(!1),2e3)}catch{const v=document.createElement("textarea");v.value=u.replace(/\s/g,""),document.body.appendChild(v),v.select(),document.execCommand("copy"),document.body.removeChild(v),c(!0),setTimeout(()=>c(!1),2e3)}},[]),{scrollYProgress:h}=Bb(),p=w.useRef(null),{scrollYProgress:b}=Bb({target:p,offset:["start start","end start"]}),g=_u(b,[0,.7],[1,0]),x=_u(b,[0,.7],[1,.92]),y=_u(b,[0,1],[0,80]);w.useEffect(()=>{const v=()=>{i(window.scrollY);const _=Wh.map(S=>document.getElementById(S.id));for(let S=_.length-1;S>=0;S--){const k=_[S];if(k&&k.getBoundingClientRect().top<=100){t(Wh[S].id);break}}};return window.addEventListener("scroll",v,{passive:!0}),()=>window.removeEventListener("scroll",v)},[]);const m=v=>{var _;(_=document.getElementById(v))==null||_.scrollIntoView({behavior:"smooth"})};return f.jsxs(f.Fragment,{children:[f.jsx(lr,{title:"KI Wissensgipfel 2026 – KI im Mittelstand",description:"KI im Mittelstand – Praxis, Perspektiven, Potenziale. Der Wissensgipfel des CDU Kreisverbands Main-Tauber am 27. März 2026."}),f.jsxs("div",{className:"wg-page min-h-screen text-[var(--wg-text)] relative overflow-x-hidden",children:[f.jsx("div",{className:"fixed inset-0 wg-bg -z-10"}),f.jsx("div",{className:"fixed inset-0 -z-10 opacity-30",style:{backgroundImage:"radial-gradient(circle at 20% 50%, rgba(59,130,246,0.12) 0%, transparent 50%), radial-gradient(circle at 80% 20%, rgba(59,130,246,0.08) 0%, transparent 50%)"}}),f.jsx(_e.div,{className:"fixed top-0 left-0 right-0 h-[2px] z-[60] origin-left",style:{scaleX:h,background:"linear-gradient(90deg, #3B82F6, #1E40AF)"}}),f.jsx(_e.nav,{initial:{y:-80},animate:{y:0},transition:{duration:.6,ease:"easeOut"},className:`fixed top-0 left-0 right-0 z-50 transition-all duration-500 ${s>50?"wg-glass-nav":""}`,children:f.jsxs("div",{className:"max-w-6xl mx-auto px-4 sm:px-6 flex items-center justify-between h-14 sm:h-16",children:[f.jsxs("span",{className:"font-bold text-sm sm:text-base tracking-wider text-[var(--wg-blue-deep)]",children:[f.jsx("span",{className:"text-wg-blue",children:"JU"})," WISSENSGIPFEL"]}),f.jsx("div",{className:"hidden sm:flex items-center gap-1",children:Wh.map(v=>f.jsx("button",{onClick:()=>m(v.id),className:`px-3 py-1.5 rounded-full text-xs font-medium uppercase tracking-wider transition-all duration-300 ${e===v.id?"wg-glass-pill-active":"hover:bg-[var(--wg-blue-50)] text-[var(--wg-text-secondary)]"}`,children:v.label},v.id))}),f.jsxs("button",{onClick:()=>a(!0),className:"wg-glass-btn-primary text-xs px-4 py-2 rounded-full font-semibold uppercase tracking-wider inline-flex items-center gap-1.5",children:[f.jsx(Xf,{className:"w-3.5 h-3.5"}),"Jetzt spenden"]})]})}),f.jsxs("section",{id:"welcome",ref:p,className:"min-h-screen flex items-center relative pt-16",children:[f.jsx(_e.div,{style:{opacity:g,scale:x,y},className:"max-w-6xl mx-auto px-4 sm:px-6 w-full py-16 sm:py-24",children:f.jsxs(_e.div,{initial:"hidden",animate:"visible",variants:Ea,className:"wg-glass-panel p-6 sm:p-10 md:p-14 roun
254ded-3xl max-w-3xl",children:[f.jsx(_e.p,{variants:Kr,className:"text-wg-blue text-xs sm:text-sm font-semibold uppercase tracking-[0.2em] mb-4",children:"27. März 2026 · Reinhold-Würth-Haus, Bad Mergentheim"}),f.jsxs(_e.h1,{variants:Kr,className:"text-3xl sm:text-5xl md:text-6xl font-bold leading-[1.1] mb-6 text-[var(--wg-text)]",children:["KI im Mittelstand –"," ",f.jsx("span",{className:"wg-text-gradient",children:"Praxis, Perspektiven, Potenziale."})]}),f.jsx(_e.p,{variants:Kr,className:"text-base sm:text-lg text-[var(--wg-text-secondary)] mb-6",children:"Der Wissensgipfel des JU Kreisverbands Main-Tauber."}),f.jsx(_e.p,{variants:Kr,className:"text-sm sm:text-base text-[var(--wg-text-secondary)] leading-relaxed mb-8 max-w-xl",children:"Künstliche Intelligenz wird unser Arbeiten und Zusammenleben tiefgreifend verändern. Lassen Sie uns gemeinsam einen Blick in die Zukunft werfen und diskutieren, wie wir diese Technologie verantwortungsvoll und zum Wohl unserer Region gestalten können."}),f.jsxs(_e.div,{variants:Kr,className:"flex flex-wrap gap-3",children:[f.jsxs("span",{className:"wg-badge",children:[f.jsx(hk,{className:"w-3.5 h-3.5 text-wg-blue"})," 27. März 2026"]}),f.jsxs("span",{className:"wg-badge",children:[f.jsx(XO,{className:"w-3.5 h-3.5 text-wg-blue"})," Reinhold-Würth-Haus"]}),f.jsxs("span",{className:"wg-badge",children:[f.jsx(ZO,{className:"w-3.5 h-3.5 text-wg-blue"})," 18:00 Uhr Einlass"]})]})]})}),f.jsx("div",{className:"absolute inset-0 -z-[1] overflow-hidden",children:f.jsx("img",{src:Gz,alt:"Reinhold-Würth-Haus",className:"w-full h-full object-cover opacity-[0.06]"})}),f.jsx(_e.div,{className:"absolute bottom-8 left-1/2 -translate-x-1/2",animate:{y:[0,8,0]},transition:{repeat:1/0,duration:2,ease:"easeInOut"},children:f.jsx(G0,{className:"w-6 h-6 text-[var(--wg-blue)] opacity-40"})})]}),f.jsx("section",{id:"programm",className:"py-20 sm:py-28 relative",children:f.jsxs("div",{className:"max-w-4xl mx-auto px-4 sm:px-6",children:[f.jsx(Yc,{children:"Programm"}),f.jsxs("div",{className:"relative",children:[f.jsx("div",{className:"absolute left-5 sm:left-8 top-0 bottom-0 w-px bg-gradient-to-b from-[var(--wg-blue)]/40 via-[var(--wg-blue-100)] to-transparent"}),f.jsx(_e.div,{initial:"hidden",whileInView:"visible",viewport:{once:!0,margin:"-50px"},variants:Ea,className:"space-y-0",children:rW.map((v,_)=>f.jsxs(_e.div,{variants:aW,className:"relative flex items-start gap-6 sm:gap-8 group py-5",children:[f.jsx("div",{className:"relative z-10 flex-shrink-0",children:f.jsx("div",{className:`w-10 h-10 sm:w-16 sm:h-16 rounded-full flex items-center justify-center text-xs sm:text-sm font-bold transition-all duration-300 ${v.accent?"wg-glass-node-active text-[var(--wg-blue-deep)]":"wg-glass-node text-[var(--wg-text-secondary)]"}`,children:v.time})}),f.jsx("div",{className:"wg-glass-panel-light px-4 sm:px-6 py-3 sm:py-4 rounded-2xl flex-1 group-hover:bg-white/70 transition-all duration-300",children:f.jsx("p",{className:"text-sm sm:text-base font-medium text-[var(--wg-text)]",children:v.label})})]},_))})]})]})}),f.jsx("section",{id:"speaker",className:"py-20 sm:py-28 relative",children:f.jsxs("div",{className:"max-w-6xl mx-auto px-4 sm:px-6",children:[f.jsx(Yc,{children:"Speaker"}),f.jsxs("p",{className:"text-center text-xs text-[var(--wg-text-secondary)] mb-12 sm:mb-16 -mt-8 sm:-mt-12 flex items-center justify-center gap-1.5",children:[f.jsx(Qu,{className:"w-3 h-3"})," Antippen zum Drehen"]}),f.jsx(_e.div,{initial:"hidden",whileInView:"visible",viewport:{once:!0,margin:"-50px"},variants:Ea,className:"grid grid-cols-2 lg:grid-cols-4 gap-4 sm:gap-6",children:sW.map((v,_)=>f.jsx(Ub,{speaker:v},_))})]})}),f.jsx("section",{id:"moderation",className:"py-20 sm:py-28 relative",children:f.jsxs("div",{className:"max-w-6xl mx-auto px-4 sm:px-6",children:[f.jsx(Yc,{children:"Moderation"}),f.jsxs("p",{className:"text-center text-xs text-[var(--wg-text-secondary)] mb-12 sm:mb-16 -mt-8 sm:-mt-12 flex items-center justify-center gap-1.5",children:[f.jsx(Qu,{className:"w-3 h-3"})," Antippen zum Drehen"]}
254),f.jsx(_e.div,{initial:"hidden",whileInView:"visible",viewport:{once:!0,margin:"-50px"},variants:Ea,className:"grid grid-cols-2 lg:grid-cols-3 gap-4 sm:gap-6 max-w-4xl mx-auto",children:iW.map((v,_)=>f.jsx(Ub,{speaker:v},_))})]})}),f.jsx("section",{id:"insights",className:"py-20 sm:py-28 relative",children:f.jsxs("div",{className:"max-w-3xl mx-auto px-4 sm:px-6",children:[f.jsx(Yc,{children:"Panel-Insights"}),f.jsx(_e.div,{initial:"hidden",whileInView:"visible",viewport:{once:!0,margin:"-50px"},variants:Kr,className:"mb-6",children:f.jsx("a",{href:"https://app.sli.do/event/4frExtfQLxHZJXMjPwAawa",target:"_blank",rel:"noopener noreferrer",className:"flex items-center gap-2 w-full px-5 py-4 sm:py-5 wg-glass-panel rounded-2xl text-sm sm:text-base font-semibold text-wg-blue hover:bg-white/10 transition-colors duration-300",children:"Fragen an das Panel - Hier Fragen online einreichen"})}),f.jsx(_e.div,{initial:"hidden",whileInView:"visible",viewport:{once:!0,margin:"-50px"},variants:Ea,className:"space-y-4",children:oW.map((v,_)=>f.jsxs(_e.div,{variants:Kr,className:"wg-glass-panel rounded-2xl overflow-hidden transition-all duration-300",children:[f.jsxs("button",{onClick:()=>r(n===_?null:_),className:"w-full px-5 sm:px-7 py-4 sm:py-5 flex items-center justify-between text-left",children:[f.jsx("span",{className:"text-sm sm:text-base font-semibold pr-4 text-[var(--wg-text)]",children:v.title}),f.jsx(_e.div,{animate:{rotate:n===_?180:0},transition:{duration:.3},children:f.jsx(G0,{className:"w-5 h-5 flex-shrink-0 text-wg-blue"})})]}),f.jsx(Lh,{initial:!1,children:n===_&&f.jsx(_e.div,{initial:{height:0,opacity:0},animate:{height:"auto",opacity:1},exit:{height:0,opacity:0},transition:{duration:.4,ease:[.25,.46,.45,.94]},className:"overflow-hidden",children:f.jsxs("div",{className:"px-5 sm:px-7 pb-5 space-y-3",children:[f.jsx("ul",{className:"space-y-2",children:v.facts.map((S,k)=>f.jsxs("li",{className:"text-sm text-[var(--wg-text-secondary)] leading-relaxed flex gap-2",children:[f.jsx("span",{className:"text-wg-blue mt-1 flex-shrink-0",children:"•"}),f.jsx("span",{children:S})]},k))}),f.jsx("div",{className:"flex flex-wrap gap-2 items-center",children:v.links.map((S,k)=>f.jsxs("a",{href:S,target:"_blank",rel:"noopener noreferrer",className:"text-xs font-semibold text-wg-blue hover:text-[var(--wg-blue-deep)] transition-colors normal-case tracking-wider inline-flex items-center gap-1.5",children:[f.jsx(pk,{className:"w-3.5 h-3.5"}),"🔗 ",v.linkLabels[k]]},k))})]})})})]},_))})]})}),f.jsx("section",{className:"py-16 sm:py-24",children:f.jsx("div",{className:"max-w-3xl mx-auto px-4 sm:px-6 text-center",children:f.jsxs(_e.div,{initial:"hidden",whileInView:"visible",viewport:{once:!0,margin:"-80px"},variants:dA,className:"wg-glass-panel p-8 sm:p-12 rounded-3xl",children:[f.jsx("h2",{className:"text-2xl sm:text-3xl font-bold mb-4 text-[var(--wg-text)]",children:"Jetzt unterstützen!"}),f.jsx("p",{className:"text-[var(--wg-text-secondary)] text-sm sm:text-base mb-6",children:"Helfen Sie uns, den KI Wissensgipfel 2026 zu ermöglichen."}),f.jsxs(_e.button,{whileHover:{scale:1.05,boxShadow:"0 0 40px rgba(59,130,246,0.25)"},whileTap:{scale:.97},onClick:()=>a(!0),className:"wg-glass-btn-primary inline-flex items-center gap-2 px-8 py-3 rounded-full text-sm font-bold uppercase tracking-wider",children:[f.jsx(Xf,{className:"w-4 h-4"}),"Jetzt spenden"]})]})})}),f.jsx("footer",{className:"py-8 border-t border-[var(--wg-gray-200)]",children:f.jsxs("div",{className:"max-w-6xl mx-auto px-4 sm:px-6 flex flex-col sm:flex-row items-center justify-between gap-4 text-xs text-[var(--wg-text-secondary)]",children:[f.jsx("span",{children:"© 2026 CDU Kreisverband Main-Tauber"}),f.jsx("span",{children:"Reinhold-Würth-Haus · Ketterberg 4 · 97980 Bad Mergentheim"})]})})]}),f.jsx(Lh,{children:o&&f.jsxs(f.Fragment,{children:[f.jsx(_e.div,{initial:{opacity:0}
254,animate:{opacity:1},exit:{opacity:0},className:"fixed inset-0 z-[100] bg-black/40 backdrop-blur-sm",onClick:()=>a(!1)}),f.jsx(_e.div,{initial:{opacity:0,scale:.92,y:20},animate:{opacity:1,scale:1,y:0},exit:{opacity:0,scale:.92,y:20},transition:{type:"spring",damping:25,stiffness:350},className:"fixed inset-0 z-[101] flex items-center justify-center p-4 pointer-events-none",children:f.jsxs("div",{className:"pointer-events-auto w-full max-w-sm rounded-2xl border border-white/30 bg-white/70 backdrop-blur-xl shadow-2xl p-6 sm:p-8 relative",children:[f.jsx("button",{onClick:()=>a(!1),className:"absolute top-4 right-4 text-[var(--wg-text-secondary)] hover:text-[var(--wg-text)] transition-colors",children:f.jsx(Xg,{className:"w-5 h-5"})}),f.jsxs("div",{className:"flex items-center gap-2 mb-4",children:[f.jsx(Xf,{className:"w-5 h-5 text-wg-blue"}),f.jsx("h3",{className:"text-lg font-bold text-[var(--wg-text)]",children:"Spende"})]}),f.jsx("p",{className:"text-sm text-[var(--wg-text-secondary)] mb-6",children:"Unterstützen Sie unsere Arbeit für die Region."}),f.jsxs("div",{className:"space-y-3 mb-6",children:[f.jsx("div",{className:"text-xs text-[var(--wg-text-secondary)] uppercase tracking-wider font-medium",children:"Empfänger"}),f.jsx("div",{className:"text-sm font-semibold text-[var(--wg-text)]",children:"CDU Kreisverband Main-Tauber"}),f.jsx("div",{className:"text-xs text-[var(--wg-text-secondary)] uppercase tracking-wider font-medium mt-3",children:"Verwendungszweck"}),f.jsx("div",{className:"text-sm font-semibold text-[var(--wg-text)]",children:"JU-Main-Tauber"})]}),f.jsx("div",{className:"text-xs text-[var(--wg-text-secondary)] uppercase tracking-wider font-medium mb-2",children:"IBAN"}),f.jsxs("button",{onClick:d,className:"w-full flex items-center justify-between gap-3 rounded-xl border border-[var(--wg-blue-100)] bg-[var(--wg-blue-50)] px-4 py-3 group transition-all hover:border-[var(--wg-blue)] hover:shadow-md",children:[f.jsx("span",{className:"text-sm sm:text-base font-mono font-semibold text-[var(--wg-text)] tracking-wide",children:u}),f.jsx("span",{className:"flex-shrink-0",children:l?f.jsx(YO,{className:"w-5 h-5 text-green-600"}):f.jsx(JO,{className:"w-5 h-5 text-[var(--wg-blue)] group-hover:scale-110 transition-transform"})})]}),f.jsx(Lh,{children:l&&f.jsx(_e.p,{initial:{opacity:0,y:-4},animate:{opacity:1,y:0},exit:{opacity:0},className:"text-xs text-green-600 font-medium mt-2 text-center",children:"✓ IBAN kopiert!"})})]})})]})})]})},cW=()=>f.jsxs(eI,{children:[f.jsx(D2,{}),f.jsx(hM,{}),f.jsxs(LN,{children:[f.jsx(Un,{path:"/",element:f.jsx(z5,{})}),f.jsx(Un,{path:"/event/:id",element:f.jsx(K4,{})}),f.jsx(Un,{path:"/event/:id/edit",element:f.jsx(k6,{})}),f.jsx(Un,{path:"/my-events",element:f.jsx(x6,{})}),f.jsx(Un,{path:"/create-event",element:f.jsx(_6,{})}),f.jsx(Un,{path:"/auth",element:f.jsx(W5,{})}),f.jsx(Un,{path:"/admin",element:f.jsx(y6,{})}),f.jsx(Un,{path:"/wissensgipfel",element:f.jsx(lW,{})}),f.jsx(Un,{path:"*",element:f.jsx(E6,{})})]})]}),uW=new gR;uS(document.getElementById("root")).render(f.jsx(w.StrictMode,{children:f.jsx(IS,{children:f.jsx(WN,{children:f.jsx(yR,{client:uW,children:f.jsx(cW,{})})})})}));

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.