PageSourceSearch

https://www.coachchristensen.com/assets/index-BPaDRyN8.js

js coachchristensen.com collected 2026-10-08 12:19:33 UTC 521,206 bytes, 299 lines download raw bytes

vendor: 18,217 bytes, lines 1-33
1(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 ed={exports:{}},Ui={},td={exports:{}},L={};/**
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 fs=Symbol.for("react.element"),ip=Symbol.for("react.portal"),ap=Symbol.for("react.fragment"),op=Symbol.for("react.strict_mode"),lp=Symbol.for("react.profiler"),cp=Symbol.for("react.provider"),up=Symbol.for("react.context"),dp=Symbol.for("react.forward_ref"),hp=Symbol.for("react.suspense"),fp=Symbol.for("react.memo"),pp=Symbol.for("react.lazy"),uc=Symbol.iterator;function mp(e){return e===null||typeof e!="object"?null:(e=uc&&e[uc]||e["@@iterator"],typeof e=="function"?e:null)}var nd={isMounted:function(){return!1},enqueueForceUpdate:function(){},enqueueReplaceState:function(){},enqueueSetState:function(){}},rd=Object.assign,sd={};function ar(e,t,n){this.props=e,this.context=t,this.refs=sd,this.updater=n||nd}ar.prototype.isReactComponent={};ar.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")};ar.prototype.forceUpdate=function(e){this.updater.enqueueForceUpdate(this,e,"forceUpdate")};function id(){}id.prototype=ar.prototype;function al(e,t,n){this.props=e,this.context=t,this.refs=sd,this.updater=n||nd}var ol=al.prototype=new id;ol.constructor=al;rd(ol,ar.prototype);ol.isPureReactComponent=!0;var dc=Array.isArray,ad=Object.prototype.hasOwnProperty,ll={current:null},od={key:!0,ref:!0,__self:!0,__source:!0};function ld(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)ad.call(t,r)&&!od.hasOwnProperty(r)&&(s[r]=t[r]);var l=arguments.length-2;if(l===1)s.children=n;else if(1<l){for(var c=Array(l),u=0;u<l;u++)c[u]=arguments[u+2];s.children=c}if(e&&e.defaultProps)for(r in l=e.defaultProps,l)s[r]===void 0&&(s[r]=l[r]);return{$$typeof:fs,type:e,key:i,ref:o,props:s,_owner:ll.current}}function gp(e,t){return{$$typeof:fs,type:e.type,key:t,ref:e.ref,props:e.props,_owner:e._owner}}function cl(e){return typeof e=="object"&&e!==null&&e.$$typeof===fs}function yp(e){var t={"=":"=0",":":"=2"};return"$"+e.replace(/[=:]/g,function(n){return t[n]})}var hc=/\/+/g;function ha(e,t){return typeof e=="object"&&e!==null&&e.key!=null?yp(""+e.key):t.toString(36)}function Ys(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 fs:case ip:o=!0}}if(o)return o=e,s=s(o),e=r===""?"."+ha(o,0):r,dc(s)?(n="",e!=null&&(n=e.replace(hc,"$&/")+"/"),Ys(s,t,n,"",function(u){return u})):s!=null&&(cl(s)&&(s=gp(s,n+(!s.key||o&&o.key===s.key?"":(""+s.key).replace(hc,"$&/")+"/")+e)),t.push(s)),1;if(o=0,r=r===""?".":r+":",dc(e))for(var l=0;l<e.length;l++){i=e[l];var c=r+ha(i,l);o+=Ys(i,t,n,c,s)}else if(c=mp(e),typeof c=="function")for(e=c.call(e),l=0;!(i=e.next()).done;)i=i.value,c=r+ha(i,l++),o+=Ys(i,t,n,c,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 js(e,t,n){if(e==null)return e;var r=[],s=0;return Ys(e,r,"","",function(i){return t.call(n,i,s++)}),r}function vp(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 je={current:null},Js={transition:null},wp={ReactCurrentDispatcher:je,ReactCurrentBatchConfig:Js,ReactCurrentOwner:ll};function cd(){throw Error("act(...) is not supported in production builds of React.")}L.Children={map:js,forEach:function(e,t,n){js(e,function(){t.apply(this,arguments)},n)},count:function(e){var t=0;return js(e,function(){t++}),t},toArray:function(e){return js(e,function(t){return t})||[]},only:function(e){if(!cl(e))throw Error("React.Children.only expected to receive a single React element child.");return e}};L.Component=ar;L.Fragment=ap;L.Profiler=lp;L.PureComponent=al;L.StrictMode=op;L.Suspense=hp;L.__SECRET_INTERNALS_DO_NOT_USE_OR_YOU_WILL_BE_FIRED=wp;L.act=cd;L.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=rd({},e.props),s=e.key,i=e.ref,o=e._owner;if(t!=null){if(t.ref!==void 0&&(i=t.ref,o=ll.current),t.key!==void 0&&(s=""+t.key),e.type&&e.type.defaultProps)var l=e.type.defaultProps;for(c in t)ad.call(t,c)&&!od.hasOwnProperty(c)&&(r[c]=t[c]===void 0&&l!==void 0?l[c]:t[c])}var c=arguments.length-2;if(c===1)r.children=n;else if(1<c){l=Array(c);for(var u=0;u<c;u++)l[u]=arguments[u+2];r.children=l}return{$$typeof:fs,type:e.type,key:s,ref:i,props:r,_owner:o}};L.createContext=function(e){return e={$$typeof:up,_currentValue:e,_currentValue2:e,_threadCount:0,Provider:null,Consumer:null,_defaultValue:null,_globalName:null},e.Provider={$$typeof:cp,_context:e},e.Consumer=e};L.createElement=ld;L.createFactory=function(e){var t=ld.bind(null,e);return t.type=e,t};L.createRef=function(){return{current:null}};L.forwardRef=function(e){return{$$typeof:dp,render:e}};L.isValidElement=cl;L.lazy=function(e){return{$$typeof:pp,_payload:{_status:-1,_result:e},_init:vp}};L.memo=function(e,t){return{$$typeof:fp,type:e,compare:t===void 0?null:t}};L.startTransition=function(e){var t=Js.transition;Js.transition={};try{e()}finally{Js.transition=t}};L.unstable_act=cd;L.useCallback=function(e,t){return je.current.useCallback(e,t)};L.useContext=function(e){return je.current.useContext(e)};L.useDebugValue=function(){};L.useDeferredValue=function(e){return je.current.useDeferredValue(e)};L.useEffect=function(e,t){return je.current.useEffect(e,t)};L.useId=function(){return je.current.useId()};L.useImperativeHandle=function(e,t,n){return je.current.useImperativeHandle(e,t,n)};L.useInsertionEffect=function(e,t){return je.current.useInsertionEffect(e,t)};L.useLayoutEffect=function(e,t){return je.current.useLayoutEffect(e,t)};L.useMemo=function(e,t){return je.current.useMemo(e,t)};L.useReducer=function(e,t,n){return je.current.useReducer(e,t,n)};L.useRef=function(e){return je.current.useRef(e)};L.useState=function(e){return je.current.useState(e)};L.useSyncExternalStore=function(e,t,n){return je.current.useSyncExternalStore(e,t,n)};L.useTransition=function(){return je.current.useTransition()};L.version="18.3.1";td.exports=L;var x=td.exports;/**
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 xp=x,bp=Symbol.for("react.element"),_p=Symbol.for("react.fragment"),kp=Object.prototype.hasOwnProperty,jp=xp.__SECRET_INTERNALS_DO_NOT_USE_OR_YOU_WILL_BE_FIRED.ReactCurrentOwner,Sp={key:!0,ref:!0,__self:!0,__source:!0};function ud(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)kp.call(t,r)&&!Sp.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:bp,type:e,key:i,ref:o,props:s,_owner:jp.current}}Ui.Fragment=_p;Ui.jsx=ud;Ui.jsxs=ud;ed.exports=Ui;var a=ed.exports,dd={exports:{}},Le={},hd={exports:{}},fd={};/**
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(P,D){var F=P.length;P.push(D);e:for(;0<F;){var te=F-1>>>1,le=P[te];if(0<s(le,D))P[te]=D,P[F]=le,F=te;else break e}}function n(P){return P.length===0?null:P[0]}function r(P){if(P.length===0)return null;var D=P[0],F=P.pop();if(F!==D){P[0]=F;e:for(var te=0,le=P.length,_s=le>>>1;te<_s;){var Yt=2*(te+1)-1,da=P[Yt],Jt=Yt+1,ks=P[Jt];if(0>s(da,F))Jt<le&&0>s(ks,da)?(P[te]=ks,P[Jt]=F,te=Jt):(P[te]=da,P[Yt]=F,te=Yt);else if(Jt<le&&0>s(ks,F))P[te]=ks,P[Jt]=F,te=Jt;else break e}}return D}function s(P,D){var F=P.sortIndex-D.sortIndex;return F!==0?F:P.id-D.id}if(typeof performance=="object"&&typeof performance.now=="function"){var i=performance;e.unstable_now=function(){return i.now()}}else{var o=Date,l=o.now();e.unstable_now=function(){return o.now()-l}}var c=[],u=[],d=1,f=null,h=3,m=!1,v=!1,w=!1,b=typeof setTimeout=="function"?setTimeout:null,y=typeof clearTimeout=="function"?clearTimeout:null,p=typeof setImmediate<"u"?setImmediate:null;typeof navigator<"u"&&navigator.scheduling!==void 0&&navigator.scheduling.isInputPending!==void 0&&navigator.scheduling.isInputPending.bind(navigator.scheduling);function g(P){for(var D=n(u);D!==null;){if(D.callback===null)r(u);else if(D.startTime<=P)r(u),D.sortIndex=D.expirationTime,t(c,D);else break;D=n(u)}}function _(P){if(w=!1,g(P),!v)if(n(c)!==null)v=!0,ca(j);else{var D=n(u);D!==null&&ua(_,D.startTime-P)}}function j(P,D){v=!1,w&&(w=!1,y(C),C=-1),m=!0;var F=h;try{for(g(D),f=n(c);f!==null&&(!(f.expirationTime>D)||P&&!M());){var te=f.callback;if(typeof te=="function"){f.callback=null,h=f.priorityLevel;var le=te(f.expirationTime<=D);D=e.unstable_now(),typeof le=="function"?f.callback=le:f===n(c)&&r(c),g(D)}else r(c);f=n(c)}if(f!==null)var _s=!0;else{var Yt=n(u);Yt!==null&&ua(_,Yt.startTime-D),_s=!1}return _s}finally{f=null,h=F,m=!1}}var S=!1,E=null,C=-1,k=5,A=-1;function M(){return!(e.unstable_now()-A<k)}function xe(){if(E!==null){var P=e.unstable_now();A=P;var D=!0;try{D=E(!0,P)}finally{D?rt():(S=!1,E=null)}}else S=!1}var rt;if(typeof p=="function")rt=function(){p(xe)};else if(typeof MessageChannel<"u"){var hr=new MessageChannel,sp=hr.port2;hr.port1.onmessage=xe,rt=function(){sp.postMessage(null)}}else rt=function(){b(xe,0)};function ca(P){E=P,S||(S=!0,rt())}function ua(P,D){C=b(function(){P(e.unstable_now())},D)}e.unstable_IdlePriority=5,e.unstable_ImmediatePriority=1,e.unstable_LowPriority=4,e.unstable_NormalPriority=3,e.unstable_Profiling=null,e.unstable_UserBlockingPriority=2,e.unstable_cancelCallback=function(P){P.callback=null},e.unstable_continueExecution=function(){v||m||(v=!0,ca(j))},e.unstable_forceFrameRate=function(P){0>P||125<P?console.error("forceFrameRate takes a positive int between 0 and 125, forcing frame rates higher than 125 fps is not supported"):k=0<P?Math.floor(1e3/P):5},e.unstable_getCurrentPriorityLevel=function(){return h},e.unstable_getFirstCallbackNode=function(){return n(c)},e.unstable_next=function(P){switch(h){case 1:case 2:case 3:var D=3;break;default:D=h}var F=h;h=D;try{return P()}finally{h=F}},e.unstable_pauseExecution=function(){},e.unstable_requestPaint=function(){},e.unstable_runWithPriority=function(P,D){switch(P){case 1:case 2:case 3:case 4:case 5:break;default:P=3}var F=h;h=P;try{return D()}finally{h=F}},e.unstable_scheduleCallback=function(P,D,F){var te=e.unstable_now();switch(typeof F=="object"&&F!==null?(F=F.delay,F=typeof F=="number"&&0<F?te+F:te):F=te,P){case 1:var le=-1;break;case 2:le=250;break;case 5:le=1073741823;break;case 4:le=1e4;break;default:le=5e3}return le=F+le,P={id:d++,callback:D,priorityLevel:P,startTime:F,expirationTime:le,sortIndex:-1},F>te?(P.sortIndex=F,t(u,P),n(c)===null&&P===n(u)&&(w?(y(C),C=-1):w=!0,ua(_,F-te))):(P.sortIndex=le,t(c,P),v||m||(v=!0,ca(j))),P},e.unstable_shouldYield=M,e.unstable_wrapCallback=function(P){var D=h;return function(){var F=h;h=D;try{return P.apply(this,arguments)}finally{h=F}}}})(fd);hd.exports=fd;var Np=hd.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 Ep=x,Fe=Np;function N(e){for(var t="https://reactjs.org/docs/error-decoder.html?invariant="+e,n=1;n<arguments.length;n++)t+="&args[]="+encodeURIComponent(arguments[n]);return"Minified React error #"+e+"; visit "+t+" for the full message or use the non-minified dev environment for full errors and additional helpful warnings."}var pd=new Set,zr={};function yn(e,t){Xn(e,t),Xn(e+"Capture",t)}function Xn(e,t){for(zr[e]=t,e=0;e<t.length;e++)pd.add(t[e])}var vt=!(typeof window>"u"||typeof window.document>"u"||typeof window.document.createElement>"u"),Za=Object.prototype.hasOwnProperty,Cp=/^[: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]*$/,fc={},pc={};function Tp(e){return Za.call(pc,e)?!0:Za.call(fc,e)?!1:Cp.test(e)?pc[e]=!0:(fc[e]=!0,!1)}function Ap(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 Pp(e,t,n,r){if(t===null||typeof t>"u"||Ap(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 Se(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 me={};"children dangerouslySetInnerHTML defaultValue defaultChecked innerHTML suppressContentEditableWarning suppressHydrationWarning style".split(" ").forEach(function(e){me[e]=new Se(e,0,!1,e,null,!1,!1)});[["acceptCharset","accept-charset"],["className","class"],["htmlFor","for"],["httpEquiv","http-equiv"]].forEach(function(e){var t=e[0];me[t]=new Se(t,1,!1,e[1],null,!1,!1)});["contentEditable","draggable","spellCheck","value"].forEach(function(e){me[e]=new Se(e,2,!1,e.toLowerCase(),null,!1,!1)});["autoReverse","externalResourcesRequired","focusable","preserveAlpha"].forEach(function(e){me[e]=new Se(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){me[e]=new Se(e,3,!1,e.toLowerCase(),null,!1,!1)});["checked","multiple","muted","selected"].forEach(function(e){me[e]=new Se(e,3,!0,e,null,!1,!1)});["capture","download"].forEach(function(e){me[e]=new Se(e,4,!1,e,null,!1,!1)});["cols","rows","size","span"].forEach(function(e){me[e]=new Se(e,6,!1,e,null,!1,!1)});["rowSpan","start"].forEach(function(e){me[e]=new Se(e,5,!1,e.toLowerCase(),null,!1,!1)});var ul=/[\-:]([a-z])/g;function dl(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(ul,dl);me[t]=new Se(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(ul,dl);me[t]=new Se(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(ul,dl);me[t]=new Se(t,1,!1,e,"http://www.w3.org/XML/1998/namespace",!1,!1)});["tabIndex","crossOrigin"].forEach(function(e){me[e]=new Se(e,1,!1,e.toLowerCase(),null,!1,!1)});me.xlinkHref=new Se("xlinkHref",1,!1,"xlink:href","http://www.w3.org/1999/xlink",!0,!1);["src","href","action","formAction"].forEach(function(e){me[e]=new Se(e,1,!1,e.toLowerCase(),null,!0,!0)});function hl(e,t,n,r){var s=me.hasOwnProperty(t)?me[t]:null;(s!==null?s.type!==0:r||!(2<t.length)||t[0]!=="o"&&t[0]!=="O"||t[1]!=="n"&&t[1]!=="N")&&(Pp(t,n,s,r)&&(n=null),r||s===null?Tp(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))))}
vendor: 5,025 bytes, lines 33-37
33var kt=Ep.__SECRET_INTERNALS_DO_NOT_USE_OR_YOU_WILL_BE_FIRED,Ss=Symbol.for("react.element"),Rn=Symbol.for("react.portal"),On=Symbol.for("react.fragment"),fl=Symbol.for("react.strict_mode"),eo=Symbol.for("react.profiler"),md=Symbol.for("react.provider"),gd=Symbol.for("react.context"),pl=Symbol.for("react.forward_ref"),to=Symbol.for("react.suspense"),no=Symbol.for("react.suspense_list"),ml=Symbol.for("react.memo"),Nt=Symbol.for("react.lazy"),yd=Symbol.for("react.offscreen"),mc=Symbol.iterator;function fr(e){return e===null||typeof e!="object"?null:(e=mc&&e[mc]||e["@@iterator"],typeof e=="function"?e:null)}var X=Object.assign,fa;function kr(e){if(fa===void 0)try{throw Error()}catch(n){var t=n.stack.trim().match(/\n( *(at )?)/);fa=t&&t[1]||""}return`
34`+fa+e}var pa=!1;function ma(e,t){if(!e||pa)return"";pa=!0;var n=Error.prepareStackTrace;Error.prepareStackTrace=void 0;try{if(t)if(t=function(){throw Error()},Object.defineProperty(t.prototype,"props",{set:function(){throw Error()}}),typeof Reflect=="object"&&Reflect.construct){try{Reflect.construct(t,[])}catch(u){var r=u}Reflect.construct(e,[],t)}else{try{t.call()}catch(u){r=u}e.call(t.prototype)}else{try{throw Error()}catch(u){r=u}e()}}catch(u){if(u&&r&&typeof u.stack=="string"){for(var s=u.stack.split(`
35`),i=r.stack.split(`
36`),o=s.length-1,l=i.length-1;1<=o&&0<=l&&s[o]!==i[l];)l--;for(;1<=o&&0<=l;o--,l--)if(s[o]!==i[l]){if(o!==1||l!==1)do if(o--,l--,0>l||s[o]!==i[l]){var c=`
37`+s[o].replace(" at new "," at ");return e.displayName&&c.includes("<anonymous>")&&(c=c.replace("<anonymous>",e.displayName)),c}while(1<=o&&0<=l);break}}}finally{pa=!1,Error.prepareStackTrace=n}return(e=e?e.displayName||e.name:"")?kr(e):""}function Rp(e){switch(e.tag){case 5:return kr(e.type);case 16:return kr("Lazy");case 13:return kr("Suspense");case 19:return kr("SuspenseList");case 0:case 2:case 15:return e=ma(e.type,!1),e;case 11:return e=ma(e.type.render,!1),e;case 1:return e=ma(e.type,!0),e;default:return""}}function ro(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 On:return"Fragment";case Rn:return"Portal";case eo:return"Profiler";case fl:return"StrictMode";case to:return"Suspense";case no:return"SuspenseList"}if(typeof e=="object")switch(e.$$typeof){case gd:return(e.displayName||"Context")+".Consumer";case md:return(e._context.displayName||"Context")+".Provider";case pl:var t=e.render;return e=e.displayName,e||(e=t.displayName||t.name||"",e=e!==""?"ForwardRef("+e+")":"ForwardRef"),e;case ml:return t=e.displayName||null,t!==null?t:ro(e.type)||"Memo";case Nt:t=e._payload,e=e._init;try{return ro(e(t))}catch{}}return null}function Op(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 ro(t);case 8:return t===fl?"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 Bt(e){switch(typeof e){case"boolean":case"number":case"string":case"undefined":return e;case"object":return e;default:return""}}function vd(e){var t=e.type;return(e=e.nodeName)&&e.toLowerCase()==="input"&&(t==="checkbox"||t==="radio")}function Ip(e){var t=vd(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 Ns(e){e._valueTracker||(e._valueTracker=Ip(e))}function wd(e){if(!e)return!1;var t=e._valueTracker;if(!t)return!0;var n=t.getValue(),r="";return e&&(r=vd(e)?e.checked?"true":"false":e.value),e=r,e!==n?(t.setValue(e),!0):!1}function ci(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 so(e,t){var n=t.checked;return X({},t,{defaultChecked:void 0,defaultValue:void 0,value:void 0,checked:n??e._wrapperState.initialChecked})}function gc(e,t){var n=t.defaultValue==null?"":t.defaultValue,r=t.checked!=null?t.checked:t.defaultChecked;n=Bt(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: 12,105 bytes, line 37
37function xd(e,t){t=t.checked,t!=null&&hl(e,"checked",t,!1)}function io(e,t){xd(e,t);var n=Bt(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")?ao(e,t.type,n):t.hasOwnProperty("defaultValue")&&ao(e,t.type,Bt(t.defaultValue)),t.checked==null&&t.defaultChecked!=null&&(e.defaultChecked=!!t.defaultChecked)}function yc(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 ao(e,t,n){(t!=="number"||ci(e.ownerDocument)!==e)&&(n==null?e.defaultValue=""+e._wrapperState.initialValue:e.defaultValue!==""+n&&(e.defaultValue=""+n))}var jr=Array.isArray;function Vn(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=""+Bt(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 oo(e,t){if(t.dangerouslySetInnerHTML!=null)throw Error(N(91));return X({},t,{value:void 0,defaultValue:void 0,children:""+e._wrapperState.initialValue})}function vc(e,t){var n=t.value;if(n==null){if(n=t.children,t=t.defaultValue,n!=null){if(t!=null)throw Error(N(92));if(jr(n)){if(1<n.length)throw Error(N(93));n=n[0]}t=n}t==null&&(t=""),n=t}e._wrapperState={initialValue:Bt(n)}}function bd(e,t){var n=Bt(t.value),r=Bt(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 wc(e){var t=e.textContent;t===e._wrapperState.initialValue&&t!==""&&t!==null&&(e.value=t)}function _d(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 lo(e,t){return e==null||e==="http://www.w3.org/1999/xhtml"?_d(t):e==="http://www.w3.org/2000/svg"&&t==="foreignObject"?"http://www.w3.org/1999/xhtml":e}var Es,kd=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(Es=Es||document.createElement("div"),Es.innerHTML="<svg>"+t.valueOf().toString()+"</svg>",t=Es.firstChild;e.firstChild;)e.removeChild(e.firstChild);for(;t.firstChild;)e.appendChild(t.firstChild)}});function Mr(e,t){if(t){var n=e.firstChild;if(n&&n===e.lastChild&&n.nodeType===3){n.nodeValue=t;return}}e.textContent=t}var Cr={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},Dp=["Webkit","ms","Moz","O"];Object.keys(Cr).forEach(function(e){Dp.forEach(function(t){t=t+e.charAt(0).toUpperCase()+e.substring(1),Cr[t]=Cr[e]})});function jd(e,t,n){return t==null||typeof t=="boolean"||t===""?"":n||typeof t!="number"||t===0||Cr.hasOwnProperty(e)&&Cr[e]?(""+t).trim():t+"px"}function Sd(e,t){e=e.style;for(var n in t)if(t.hasOwnProperty(n)){var r=n.indexOf("--")===0,s=jd(n,t[n],r);n==="float"&&(n="cssFloat"),r?e.setProperty(n,s):e[n]=s}}var Fp=X({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 co(e,t){if(t){if(Fp[e]&&(t.children!=null||t.dangerouslySetInnerHTML!=null))throw Error(N(137,e));if(t.dangerouslySetInnerHTML!=null){if(t.children!=null)throw Error(N(60));if(typeof t.dangerouslySetInnerHTML!="object"||!("__html"in t.dangerouslySetInnerHTML))throw Error(N(61))}if(t.style!=null&&typeof t.style!="object")throw Error(N(62))}}function uo(e,t){if(e.indexOf("-")===-1)return typeof t.is=="string";switch(e){case"annotation-xml":case"color-profile":case"font-face":case"font-face-src":case"font-face-uri":case"font-face-format":case"font-face-name":case"missing-glyph":return!1;default:return!0}}var ho=null;function gl(e){return e=e.target||e.srcElement||window,e.correspondingUseElement&&(e=e.correspondingUseElement),e.nodeType===3?e.parentNode:e}var fo=null,qn=null,Gn=null;function xc(e){if(e=gs(e)){if(typeof fo!="function")throw Error(N(280));var t=e.stateNode;t&&(t=Hi(t),fo(e.stateNode,e.type,t))}}function Nd(e){qn?Gn?Gn.push(e):Gn=[e]:qn=e}function Ed(){if(qn){var e=qn,t=Gn;if(Gn=qn=null,xc(e),t)for(e=0;e<t.length;e++)xc(t[e])}}function Cd(e,t){return e(t)}function Td(){}var ga=!1;function Ad(e,t,n){if(ga)return e(t,n);ga=!0;try{return Cd(e,t,n)}finally{ga=!1,(qn!==null||Gn!==null)&&(Td(),Ed())}}function Br(e,t){var n=e.stateNode;if(n===null)return null;var r=Hi(n);if(r===null)return null;n=r[t];e:switch(t){case"onClick":case"onClickCapture":case"onDoubleClick":case"onDoubleClickCapture":case"onMouseDown":case"onMouseDownCapture":case"onMouseMove":case"onMouseMoveCapture":case"onMouseUp":case"onMouseUpCapture":case"onMouseEnter":(r=!r.disabled)||(e=e.type,r=!(e==="button"||e==="input"||e==="select"||e==="textarea")),e=!r;break e;default:e=!1}if(e)return null;if(n&&typeof n!="function")throw Error(N(231,t,typeof n));return n}var po=!1;if(vt)try{var pr={};Object.defineProperty(pr,"passive",{get:function(){po=!0}}),window.addEventListener("test",pr,pr),window.removeEventListener("test",pr,pr)}catch{po=!1}function Lp(e,t,n,r,s,i,o,l,c){var u=Array.prototype.slice.call(arguments,3);try{t.apply(n,u)}catch(d){this.onError(d)}}var Tr=!1,ui=null,di=!1,mo=null,$p={onError:function(e){Tr=!0,ui=e}};function Up(e,t,n,r,s,i,o,l,c){Tr=!1,ui=null,Lp.apply($p,arguments)}function zp(e,t,n,r,s,i,o,l,c){if(Up.apply(this,arguments),Tr){if(Tr){var u=ui;Tr=!1,ui=null}else throw Error(N(198));di||(di=!0,mo=u)}}function vn(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 Pd(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 bc(e){if(vn(e)!==e)throw Error(N(188))}function Mp(e){var t=e.alternate;if(!t){if(t=vn(e),t===null)throw Error(N(188));return t!==e?null:e}for(var n=e,r=t;;){var s=n.return;if(s===null)break;var i=s.alternate;if(i===null){if(r=s.return,r!==null){n=r;continue}break}if(s.child===i.child){for(i=s.child;i;){if(i===n)return bc(s),e;if(i===r)return bc(s),t;i=i.sibling}throw Error(N(188))}if(n.return!==r.return)n=s,r=i;else{for(var o=!1,l=s.child;l;){if(l===n){o=!0,n=s,r=i;break}if(l===r){o=!0,r=s,n=i;break}l=l.sibling}if(!o){for(l=i.child;l;){if(l===n){o=!0,n=i,r=s;break}if(l===r){o=!0,r=i,n=s;break}l=l.sibling}if(!o)throw Error(N(189))}}if(n.alternate!==r)throw Error(N(190))}if(n.tag!==3)throw Error(N(188));return n.stateNode.current===n?e:t}function Rd(e){return e=Mp(e),e!==null?Od(e):null}function Od(e){if(e.tag===5||e.tag===6)return e;for(e=e.child;e!==null;){var t=Od(e);if(t!==null)return t;e=e.sibling}return null}var Id=Fe.unstable_scheduleCallback,_c=Fe.unstable_cancelCallback,Bp=Fe.unstable_shouldYield,Wp=Fe.unstable_requestPaint,ne=Fe.unstable_now,Hp=Fe.unstable_getCurrentPriorityLevel,yl=Fe.unstable_ImmediatePriority,Dd=Fe.unstable_UserBlockingPriority,hi=Fe.unstable_NormalPriority,Vp=Fe.unstable_LowPriority,Fd=Fe.unstable_IdlePriority,zi=null,ot=null;function qp(e){if(ot&&typeof ot.onCommitFiberRoot=="function")try{ot.onCommitFiberRoot(zi,e,void 0,(e.current.flags&128)===128)}catch{}}var Ze=Math.clz32?Math.clz32:Yp,Gp=Math.log,Kp=Math.LN2;function Yp(e){return e>>>=0,e===0?32:31-(Gp(e)/Kp|0)|0}var Cs=64,Ts=4194304;function Sr(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 fi(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 l=o&~s;l!==0?r=Sr(l):(i&=o,i!==0&&(r=Sr(i)))}else o=n&~s,o!==0?r=Sr(o):i!==0&&(r=Sr(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-Ze(t),s=1<<n,r|=e[n],t&=~s;return r}function Jp(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 Qp(e,t){for(var n=e.suspendedLanes,r=e.pingedLanes,s=e.expirationTimes,i=e.pendingLanes;0<i;){var o=31-Ze(i),l=1<<o,c=s[o];c===-1?(!(l&n)||l&r)&&(s[o]=Jp(l,t)):c<=t&&(e.expiredLanes|=l),i&=~l}}function go(e){return e=e.pendingLanes&-1073741825,e!==0?e:e&1073741824?1073741824:0}function Ld(){var e=Cs;return Cs<<=1,!(Cs&4194240)&&(Cs=64),e}function ya(e){for(var t=[],n=0;31>n;n++)t.push(e);return t}function ps(e,t,n){e.pendingLanes|=t,t!==536870912&&(e.suspendedLanes=0,e.pingedLanes=0),e=e.eventTimes,t=31-Ze(t),e[t]=n}function Xp(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-Ze(n),i=1<<s;t[s]=0,r[s]=-1,e[s]=-1,n&=~i}}function vl(e,t){var n=e.entangledLanes|=t;for(e=e.entanglements;n;){var r=31-Ze(n),s=1<<r;s&t|e[r]&t&&(e[r]|=t),n&=~s}}var z=0;function $d(e){return e&=-e,1<e?4<e?e&268435455?16:536870912:4:1}var Ud,wl,zd,Md,Bd,yo=!1,As=[],It=null,Dt=null,Ft=null,Wr=new Map,Hr=new Map,Tt=[],Zp="mousedown mouseup touchcancel touchend touchstart auxclick dblclick pointercancel pointerdown pointerup dragend dragstart drop compositionend compositionstart keydown keypress keyup input textInput copy cut paste click change contextmenu reset submit".split(" ");function kc(e,t){switch(e){case"focusin":case"focusout":It=null;break;case"dragenter":case"dragleave":Dt=null;break;case"mouseover":case"mouseout":Ft=null;break;case"pointerover":case"pointerout":Wr.delete(t.pointerId);break;case"gotpointercapture":case"lostpointercapture":Hr.delete(t.pointerId)}}function mr(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=gs(t),t!==null&&wl(t)),e):(e.eventSystemFlags|=r,t=e.targetContainers,s!==null&&t.indexOf(s)===-1&&t.push(s),e)}function em(e,t,n,r,s){switch(t){case"focusin":return It=mr(It,e,t,n,r,s),!0;case"dragenter":return Dt=mr(Dt,e,t,n,r,s),!0;case"mouseover":return Ft=mr(Ft,e,t,n,r,s),!0;case"pointerover":var i=s.pointerId;return Wr.set(i,mr(Wr.get(i)||null,e,t,n,r,s)),!0;case"gotpointercapture":return i=s.pointerId,Hr.set(i,mr(Hr.get(i)||null,e,t,n,r,s
vendor: 9,630 bytes, line 37
37)),!0}return!1}function Wd(e){var t=an(e.target);if(t!==null){var n=vn(t);if(n!==null){if(t=n.tag,t===13){if(t=Pd(n),t!==null){e.blockedOn=t,Bd(e.priority,function(){zd(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 Qs(e){if(e.blockedOn!==null)return!1;for(var t=e.targetContainers;0<t.length;){var n=vo(e.domEventName,e.eventSystemFlags,t[0],e.nativeEvent);if(n===null){n=e.nativeEvent;var r=new n.constructor(n.type,n);ho=r,n.target.dispatchEvent(r),ho=null}else return t=gs(n),t!==null&&wl(t),e.blockedOn=n,!1;t.shift()}return!0}function jc(e,t,n){Qs(e)&&n.delete(t)}function tm(){yo=!1,It!==null&&Qs(It)&&(It=null),Dt!==null&&Qs(Dt)&&(Dt=null),Ft!==null&&Qs(Ft)&&(Ft=null),Wr.forEach(jc),Hr.forEach(jc)}function gr(e,t){e.blockedOn===t&&(e.blockedOn=null,yo||(yo=!0,Fe.unstable_scheduleCallback(Fe.unstable_NormalPriority,tm)))}function Vr(e){function t(s){return gr(s,e)}if(0<As.length){gr(As[0],e);for(var n=1;n<As.length;n++){var r=As[n];r.blockedOn===e&&(r.blockedOn=null)}}for(It!==null&&gr(It,e),Dt!==null&&gr(Dt,e),Ft!==null&&gr(Ft,e),Wr.forEach(t),Hr.forEach(t),n=0;n<Tt.length;n++)r=Tt[n],r.blockedOn===e&&(r.blockedOn=null);for(;0<Tt.length&&(n=Tt[0],n.blockedOn===null);)Wd(n),n.blockedOn===null&&Tt.shift()}var Kn=kt.ReactCurrentBatchConfig,pi=!0;function nm(e,t,n,r){var s=z,i=Kn.transition;Kn.transition=null;try{z=1,xl(e,t,n,r)}finally{z=s,Kn.transition=i}}function rm(e,t,n,r){var s=z,i=Kn.transition;Kn.transition=null;try{z=4,xl(e,t,n,r)}finally{z=s,Kn.transition=i}}function xl(e,t,n,r){if(pi){var s=vo(e,t,n,r);if(s===null)Ea(e,t,r,mi,n),kc(e,r);else if(em(s,e,t,n,r))r.stopPropagation();else if(kc(e,r),t&4&&-1<Zp.indexOf(e)){for(;s!==null;){var i=gs(s);if(i!==null&&Ud(i),i=vo(e,t,n,r),i===null&&Ea(e,t,r,mi,n),i===s)break;s=i}s!==null&&r.stopPropagation()}else Ea(e,t,r,null,n)}}var mi=null;function vo(e,t,n,r){if(mi=null,e=gl(r),e=an(e),e!==null)if(t=vn(e),t===null)e=null;else if(n=t.tag,n===13){if(e=Pd(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 mi=e,null}function Hd(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(Hp()){case yl:return 1;case Dd:return 4;case hi:case Vp:return 16;case Fd:return 536870912;default:return 16}default:return 16}}var Rt=null,bl=null,Xs=null;function Vd(){if(Xs)return Xs;var e,t=bl,n=t.length,r,s="value"in Rt?Rt.value:Rt.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 Xs=s.slice(e,1<r?1-r:void 0)}function Zs(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 Ps(){return!0}function Sc(){return!1}function $e(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 l in e)e.hasOwnProperty(l)&&(n=e[l],this[l]=n?n(i):i[l]);return this.isDefaultPrevented=(i.defaultPrevented!=null?i.defaultPrevented:i.returnValue===!1)?Ps:Sc,this.isPropagationStopped=Sc,this}return X(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=Ps)},stopPropagation:function(){var n=this.nativeEvent;n&&(n.stopPropagation?n.stopPropagation():typeof n.cancelBubble!="unknown"&&(n.cancelBubble=!0),this.isPropagationStopped=Ps)},persist:function(){},isPersistent:Ps}),t}var or={eventPhase:0,bubbles:0,cancelable:0,timeStamp:function(e){return e.timeStamp||Date.now()},defaultPrevented:0,isTrusted:0},_l=$e(or),ms=X({},or,{view:0,detail:0}),sm=$e(ms),va,wa,yr,Mi=X({},ms,{screenX:0,screenY:0,clientX:0,clientY:0,pageX:0,pageY:0,ctrlKey:0,shiftKey:0,altKey:0,metaKey:0,getModifierState:kl,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!==yr&&(yr&&e.type==="mousemove"?(va=e.screenX-yr.screenX,wa=e.screenY-yr.screenY):wa=va=0,yr=e),va)},movementY:function(e){return"movementY"in e?e.movementY:wa}}),Nc=$e(Mi),im=X({},Mi,{dataTransfer:0}),am=$e(im),om=X({},ms,{relatedTarget:0}),xa=$e(om),lm=X({},or,{animationName:0,elapsedTime:0,pseudoElement:0}),cm=$e(lm),um=X({},or,{clipboardData:function(e){return"clipboardData"in e?e.clipboardData:window.clipboardData}}),dm=$e(um),hm=X({},or,{data:0}),Ec=$e(hm),fm={Esc:"Escape",Spacebar:" ",Left:"ArrowLeft",Up:"ArrowUp",Right:"ArrowRight",Down:"ArrowDown",Del:"Delete",Win:"OS",Menu:"ContextMenu",Apps:"ContextMenu",Scroll:"ScrollLock",MozPrintableKey:"Unidentified"},pm={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"},mm={Alt:"altKey",Control:"ctrlKey",Meta:"metaKey",Shift:"shiftKey"};function gm(e){var t=this.nativeEvent;return t.getModifierState?t.getModifierState(e):(e=mm[e])?!!t[e]:!1}function kl(){return gm}var ym=X({},ms,{key:function(e){if(e.key){var t=fm[e.key]||e.key;if(t!=="Unidentified")return t}return e.type==="keypress"?(e=Zs(e),e===13?"Enter":String.fromCharCode(e)):e.type==="keydown"||e.type==="keyup"?pm[e.keyCode]||"Unidentified":""},code:0,location:0,ctrlKey:0,shiftKey:0,altKey:0,metaKey:0,repeat:0,locale:0,getModifierState:kl,charCode:function(e){return e.type==="keypress"?Zs(e):0},keyCode:function(e){return e.type==="keydown"||e.type==="keyup"?e.keyCode:0},which:function(e){return e.type==="keypress"?Zs(e):e.type==="keydown"||e.type==="keyup"?e.keyCode:0}}),vm=$e(ym),wm=X({},Mi,{pointerId:0,width:0,height:0,pressure:0,tangentialPressure:0,tiltX:0,tiltY:0,twist:0,pointerType:0,isPrimary:0}),Cc=$e(wm),xm=X({},ms,{touches:0,targetTouches:0,changedTouches:0,altKey:0,metaKey:0,ctrlKey:0,shiftKey:0,getModifierState:kl}),bm=$e(xm),_m=X({},or,{propertyName:0,elapsedTime:0,pseudoElement:0}),km=$e(_m),jm=X({},Mi,{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}),Sm=$e(jm),Nm=[9,13,27,32],jl=vt&&"CompositionEvent"in window,Ar=null;vt&&"documentMode"in document&&(Ar=document.documentMode);var Em=vt&&"TextEvent"in window&&!Ar,qd=vt&&(!jl||Ar&&8<Ar&&11>=Ar),Tc=" ",Ac=!1;function Gd(e,t){switch(e){case"keyup":return Nm.indexOf(t.keyCode)!==-1;case"keydown":return t.keyCode!==229;case"keypress":case"mousedown":case"focusout":return!0;default:return!1}}function Kd(e){return e=e.detail,typeof e=="object"&&"data"in e?e.data:null}var In=!1;function Cm(e,t){switch(e){case"compositionend":return Kd(t);case"keypress":return t.which!==32?null:(Ac=!0,Tc);case"textInput":return e=t.data,e===Tc&&Ac?null:e;default:return null}}function Tm(e,t){if(In)return e==="compositionend"||!jl&&Gd(e,t)?(e=Vd(),Xs=bl=Rt=null,In=!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 qd&&t.locale!=="ko"?null:t.data;default:return null}}var Am={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 Pc(e){var t=e&&e.nodeName&&e.nodeName.toLowerCase();return t==="input"?!!Am[e.type]:t==="textarea"}function Yd(e,t,n,r){Nd(r),t=gi(t,"onChange"),0<t.length&&(n=new _l("onChange","change",null,n,r),e.push({event:n,listeners:t}))}var Pr=null,qr=null;function Pm(e){ah(e,0)}function Bi(e){var t=Ln(e);if(wd(t))return e}function Rm(e,t){if(e==="change")return t}var Jd=!1;if(vt){var ba;if(vt){var _a="oninput"in document;if(!_a){var Rc=document.createElement("div");Rc.setAttribute("oninput","return;"),_a=typeof Rc.oninput=="function"}ba=_a}else ba=!1;Jd=ba&&(!document.documentMode||9<document.documentMode)}function Oc(){Pr&&(Pr.detachEvent("onpropertychange",Qd),qr=Pr=null)}function Qd(e){if(e.propertyName==="value"&&Bi(qr)){var t=[];Yd(t,qr,e,gl(e)),Ad(Pm,t)}}
vendor: 5,253 bytes, line 37
37function Om(e,t,n){e==="focusin"?(Oc(),Pr=t,qr=n,Pr.attachEvent("onpropertychange",Qd)):e==="focusout"&&Oc()}function Im(e){if(e==="selectionchange"||e==="keyup"||e==="keydown")return Bi(qr)}function Dm(e,t){if(e==="click")return Bi(t)}function Fm(e,t){if(e==="input"||e==="change")return Bi(t)}function Lm(e,t){return e===t&&(e!==0||1/e===1/t)||e!==e&&t!==t}var tt=typeof Object.is=="function"?Object.is:Lm;function Gr(e,t){if(tt(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(!Za.call(t,s)||!tt(e[s],t[s]))return!1}return!0}function Ic(e){for(;e&&e.firstChild;)e=e.firstChild;return e}function Dc(e,t){var n=Ic(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=Ic(n)}}function Xd(e,t){return e&&t?e===t?!0:e&&e.nodeType===3?!1:t&&t.nodeType===3?Xd(e,t.parentNode):"contains"in e?e.contains(t):e.compareDocumentPosition?!!(e.compareDocumentPosition(t)&16):!1:!1}function Zd(){for(var e=window,t=ci();t instanceof e.HTMLIFrameElement;){try{var n=typeof t.contentWindow.location.href=="string"}catch{n=!1}if(n)e=t.contentWindow;else break;t=ci(e.document)}return t}function Sl(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 $m(e){var t=Zd(),n=e.focusedElem,r=e.selectionRange;if(t!==n&&n&&n.ownerDocument&&Xd(n.ownerDocument.documentElement,n)){if(r!==null&&Sl(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=Dc(n,i);var o=Dc(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 Um=vt&&"documentMode"in document&&11>=document.documentMode,Dn=null,wo=null,Rr=null,xo=!1;function Fc(e,t,n){var r=n.window===n?n.document:n.nodeType===9?n:n.ownerDocument;xo||Dn==null||Dn!==ci(r)||(r=Dn,"selectionStart"in r&&Sl(r)?r={start:r.selectionStart,end:r.selectionEnd}:(r=(r.ownerDocument&&r.ownerDocument.defaultView||window).getSelection(),r={anchorNode:r.anchorNode,anchorOffset:r.anchorOffset,focusNode:r.focusNode,focusOffset:r.focusOffset}),Rr&&Gr(Rr,r)||(Rr=r,r=gi(wo,"onSelect"),0<r.length&&(t=new _l("onSelect","select",null,t,n),e.push({event:t,listeners:r}),t.target=Dn)))}function Rs(e,t){var n={};return n[e.toLowerCase()]=t.toLowerCase(),n["Webkit"+e]="webkit"+t,n["Moz"+e]="moz"+t,n}var Fn={animationend:Rs("Animation","AnimationEnd"),animationiteration:Rs("Animation","AnimationIteration"),animationstart:Rs("Animation","AnimationStart"),transitionend:Rs("Transition","TransitionEnd")},ka={},eh={};vt&&(eh=document.createElement("div").style,"AnimationEvent"in window||(delete Fn.animationend.animation,delete Fn.animationiteration.animation,delete Fn.animationstart.animation),"TransitionEvent"in window||delete Fn.transitionend.transition);function Wi(e){if(ka[e])return ka[e];if(!Fn[e])return e;var t=Fn[e],n;for(n in t)if(t.hasOwnProperty(n)&&n in eh)return ka[e]=t[n];return e}var th=Wi("animationend"),nh=Wi("animationiteration"),rh=Wi("animationstart"),sh=Wi("transitionend"),ih=new Map,Lc="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 Ht(e,t){ih.set(e,t),yn(t,[e])}for(var ja=0;ja<Lc.length;ja++){var Sa=Lc[ja],zm=Sa.toLowerCase(),Mm=Sa[0].toUpperCase()+Sa.slice(1);Ht(zm,"on"+Mm)}Ht(th,"onAnimationEnd");Ht(nh,"onAnimationIteration");Ht(rh,"onAnimationStart");Ht("dblclick","onDoubleClick");Ht("focusin","onFocus");Ht("focusout","onBlur");Ht(sh,"onTransitionEnd");Xn("onMouseEnter",["mouseout","mouseover"]);Xn("onMouseLeave",["mouseout","mouseover"]);Xn("onPointerEnter",["pointerout","pointerover"]);Xn("onPointerLeave",["pointerout","pointerover"]);yn("onChange","change click focusin focusout input keydown keyup selectionchange".split(" "));
vendor: 4,769 bytes, line 37
37yn("onSelect","focusout contextmenu dragend focusin keydown keyup mousedown mouseup selectionchange".split(" "));yn("onBeforeInput",["compositionend","keypress","textInput","paste"]);yn("onCompositionEnd","compositionend focusout keydown keypress keyup mousedown".split(" "));yn("onCompositionStart","compositionstart focusout keydown keypress keyup mousedown".split(" "));yn("onCompositionUpdate","compositionupdate focusout keydown keypress keyup mousedown".split(" "));var Nr="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(" "),Bm=new Set("cancel close invalid load scroll toggle".split(" ").concat(Nr));function $c(e,t,n){var r=e.type||"unknown-event";e.currentTarget=n,zp(r,t,void 0,e),e.currentTarget=null}function ah(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 l=r[o],c=l.instance,u=l.currentTarget;if(l=l.listener,c!==i&&s.isPropagationStopped())break e;$c(s,l,u),i=c}else for(o=0;o<r.length;o++){if(l=r[o],c=l.instance,u=l.currentTarget,l=l.listener,c!==i&&s.isPropagationStopped())break e;$c(s,l,u),i=c}}}if(di)throw e=mo,di=!1,mo=null,e}function H(e,t){var n=t[So];n===void 0&&(n=t[So]=new Set);var r=e+"__bubble";n.has(r)||(oh(t,e,2,!1),n.add(r))}function Na(e,t,n){var r=0;t&&(r|=4),oh(n,e,r,t)}var Os="_reactListening"+Math.random().toString(36).slice(2);function Kr(e){if(!e[Os]){e[Os]=!0,pd.forEach(function(n){n!=="selectionchange"&&(Bm.has(n)||Na(n,!1,e),Na(n,!0,e))});var t=e.nodeType===9?e:e.ownerDocument;t===null||t[Os]||(t[Os]=!0,Na("selectionchange",!1,t))}}function oh(e,t,n,r){switch(Hd(t)){case 1:var s=nm;break;case 4:s=rm;break;default:s=xl}n=s.bind(null,t,n,e),s=void 0,!po||t!=="touchstart"&&t!=="touchmove"&&t!=="wheel"||(s=!0),r?s!==void 0?e.addEventListener(t,n,{capture:!0,passive:s}):e.addEventListener(t,n,!0):s!==void 0?e.addEventListener(t,n,{passive:s}):e.addEventListener(t,n,!1)}function Ea(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 l=r.stateNode.containerInfo;if(l===s||l.nodeType===8&&l.parentNode===s)break;if(o===4)for(o=r.return;o!==null;){var c=o.tag;if((c===3||c===4)&&(c=o.stateNode.containerInfo,c===s||c.nodeType===8&&c.parentNode===s))return;o=o.return}for(;l!==null;){if(o=an(l),o===null)return;if(c=o.tag,c===5||c===6){r=i=o;continue e}l=l.parentNode}}r=r.return}Ad(function(){var u=i,d=gl(n),f=[];e:{var h=ih.get(e);if(h!==void 0){var m=_l,v=e;switch(e){case"keypress":if(Zs(n)===0)break e;case"keydown":case"keyup":m=vm;break;case"focusin":v="focus",m=xa;break;case"focusout":v="blur",m=xa;break;case"beforeblur":case"afterblur":m=xa;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":m=Nc;break;case"drag":case"dragend":case"dragenter":case"dragexit":case"dragleave":case"dragover":case"dragstart":case"drop":m=am;break;case"touchcancel":case"touchend":case"touchmove":case"touchstart":m=bm;break;case th:case nh:case rh:m=cm;break;case sh:m=km;break;case"scroll":m=sm;break;case"wheel":m=Sm;break;case"copy":case"cut":case"paste":m=dm;break;case"gotpointercapture":case"lostpointercapture":case"pointercancel":case"pointerdown":case"pointermove":case"pointerout":case"pointerover":case"pointerup":m=Cc}var w=(t&4)!==0,b=!w&&e==="scroll",y=w?h!==null?h+"Capture":null:h;w=[];for(var p=u,g;p!==null;){g=p;var _=g.stateNode;if(g.tag===5&&_!==null&&(g=_,y!==null&&(_=Br(p,y),_!=null&&w.push(Yr(p,_,g)))),b)break;p=p.return}0<w.length&&(h=new m(h,v,null,n,d),f.push({event:h,listeners:w}))}}if(!(t&7)){e:{if(h=e==="mouseover"||e==="pointerover",m=e==="mouseout"||e==="pointerout",h&&n!==ho&&(v=n.relatedTarget||n.fromElement)&&(an(v)||v[wt]))break e;if((m||h)&&(h=d.window===d?d:(h=d.ownerDocument)?h.defaultView||h.parentWindow:window,m?(v=n.relatedTarget||n.toElement,m=u,v=v?an(v):null,v!==null&&(b=vn(v),v!==b||v.tag!==5&&v.tag!==6)&&(v=null)):(m=null,v=u),m!==v)){if(w=Nc,_="onMouseLeave",y="onMouseEnter",p="mouse",(e==="pointerout"||e==="pointerover")&&(w=Cc,_="onPointerLeave",y="onPointerEnter",p="pointer"),b=m==null?h:Ln(m),g=v==null?h:Ln(v),h=new w(_,p+"leave",m,n,d),h.target=b,h.relatedTarget=g,_=null,an(d)===u&&(w=new w(y,p+"enter",v,n,d),w.target=g,w.relatedTarget=b,_=w),b=_,m&&v)t:{for(w=m,y=v,p=0,g=w;g;g=wn(g))p++;for(g=0,_=y;_;_=wn(_))g++;for(;0<p-g;)w=wn(w),p--;for(;0<g-p;)y=wn(y),g--;for(;p--;){if(w===y||y!==null&&w===y.alternate)break t;w=wn(w),y=wn(y)}w=null}else w=null;m!==null&&Uc(f,h,m,w,!1),v!==null&&b!==null&&Uc(f,b,v,w,!0)}}
vendor: 4,654 bytes, lines 37-38
37e:{if(h=u?Ln(u):window,m=h.nodeName&&h.nodeName.toLowerCase(),m==="select"||m==="input"&&h.type==="file")var j=Rm;else if(Pc(h))if(Jd)j=Fm;else{j=Im;var S=Om}else(m=h.nodeName)&&m.toLowerCase()==="input"&&(h.type==="checkbox"||h.type==="radio")&&(j=Dm);if(j&&(j=j(e,u))){Yd(f,j,n,d);break e}S&&S(e,h,u),e==="focusout"&&(S=h._wrapperState)&&S.controlled&&h.type==="number"&&ao(h,"number",h.value)}switch(S=u?Ln(u):window,e){case"focusin":(Pc(S)||S.contentEditable==="true")&&(Dn=S,wo=u,Rr=null);break;case"focusout":Rr=wo=Dn=null;break;case"mousedown":xo=!0;break;case"contextmenu":case"mouseup":case"dragend":xo=!1,Fc(f,n,d);break;case"selectionchange":if(Um)break;case"keydown":case"keyup":Fc(f,n,d)}var E;if(jl)e:{switch(e){case"compositionstart":var C="onCompositionStart";break e;case"compositionend":C="onCompositionEnd";break e;case"compositionupdate":C="onCompositionUpdate";break e}C=void 0}else In?Gd(e,n)&&(C="onCompositionEnd"):e==="keydown"&&n.keyCode===229&&(C="onCompositionStart");C&&(qd&&n.locale!=="ko"&&(In||C!=="onCompositionStart"?C==="onCompositionEnd"&&In&&(E=Vd()):(Rt=d,bl="value"in Rt?Rt.value:Rt.textContent,In=!0)),S=gi(u,C),0<S.length&&(C=new Ec(C,e,null,n,d),f.push({event:C,listeners:S}),E?C.data=E:(E=Kd(n),E!==null&&(C.data=E)))),(E=Em?Cm(e,n):Tm(e,n))&&(u=gi(u,"onBeforeInput"),0<u.length&&(d=new Ec("onBeforeInput","beforeinput",null,n,d),f.push({event:d,listeners:u}),d.data=E))}ah(f,t)})}function Yr(e,t,n){return{instance:e,listener:t,currentTarget:n}}function gi(e,t){for(var n=t+"Capture",r=[];e!==null;){var s=e,i=s.stateNode;s.tag===5&&i!==null&&(s=i,i=Br(e,n),i!=null&&r.unshift(Yr(e,i,s)),i=Br(e,t),i!=null&&r.push(Yr(e,i,s))),e=e.return}return r}function wn(e){if(e===null)return null;do e=e.return;while(e&&e.tag!==5);return e||null}function Uc(e,t,n,r,s){for(var i=t._reactName,o=[];n!==null&&n!==r;){var l=n,c=l.alternate,u=l.stateNode;if(c!==null&&c===r)break;l.tag===5&&u!==null&&(l=u,s?(c=Br(n,i),c!=null&&o.unshift(Yr(n,c,l))):s||(c=Br(n,i),c!=null&&o.push(Yr(n,c,l)))),n=n.return}o.length!==0&&e.push({event:t,listeners:o})}var Wm=/\r\n?/g,Hm=/\u0000|\uFFFD/g;function zc(e){return(typeof e=="string"?e:""+e).replace(Wm,`
38`).replace(Hm,"")}function Is(e,t,n){if(t=zc(t),zc(e)!==t&&n)throw Error(N(425))}function yi(){}var bo=null,_o=null;function ko(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 jo=typeof setTimeout=="function"?setTimeout:void 0,Vm=typeof clearTimeout=="function"?clearTimeout:void 0,Mc=typeof Promise=="function"?Promise:void 0,qm=typeof queueMicrotask=="function"?queueMicrotask:typeof Mc<"u"?function(e){return Mc.resolve(null).then(e).catch(Gm)}:jo;function Gm(e){setTimeout(function(){throw e})}function Ca(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),Vr(t);return}r--}else n!=="$"&&n!=="$?"&&n!=="$!"||r++;n=s}while(n);Vr(t)}function Lt(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 Bc(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 lr=Math.random().toString(36).slice(2),at="__reactFiber$"+lr,Jr="__reactProps$"+lr,wt="__reactContainer$"+lr,So="__reactEvents$"+lr,Km="__reactListeners$"+lr,Ym="__reactHandles$"+lr;function an(e){var t=e[at];if(t)return t;for(var n=e.parentNode;n;){if(t=n[wt]||n[at]){if(n=t.alternate,t.child!==null||n!==null&&n.child!==null)for(e=Bc(e);e!==null;){if(n=e[at])return n;e=Bc(e)}return t}e=n,n=e.parentNode}return null}function gs(e){return e=e[at]||e[wt],!e||e.tag!==5&&e.tag!==6&&e.tag!==13&&e.tag!==3?null:e}function Ln(e){if(e.tag===5||e.tag===6)return e.stateNode;throw Error(N(33))}function Hi(e){return e[Jr]||null}var No=[],$n=-1;function Vt(e){return{current:e}}function V(e){0>$n||(e.current=No[$n],No[$n]=null,$n--)}function W(e,t){$n++,No[$n]=e.current,e.current=t}var Wt={},we=Vt(Wt),Ce=Vt(!1),hn=Wt;function Zn(e,t){var n=e.type.contextTypes;if(!n)return Wt;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 Te(e){return e=e.childContextTypes,e!=null}function vi(){V(Ce),V(we)}
vendor: 14,977 bytes, line 38
38function Wc(e,t,n){if(we.current!==Wt)throw Error(N(168));W(we,t),W(Ce,n)}function lh(e,t,n){var r=e.stateNode;if(t=t.childContextTypes,typeof r.getChildContext!="function")return n;r=r.getChildContext();for(var s in r)if(!(s in t))throw Error(N(108,Op(e)||"Unknown",s));return X({},n,r)}function wi(e){return e=(e=e.stateNode)&&e.__reactInternalMemoizedMergedChildContext||Wt,hn=we.current,W(we,e),W(Ce,Ce.current),!0}function Hc(e,t,n){var r=e.stateNode;if(!r)throw Error(N(169));n?(e=lh(e,t,hn),r.__reactInternalMemoizedMergedChildContext=e,V(Ce),V(we),W(we,e)):V(Ce),W(Ce,n)}var ft=null,Vi=!1,Ta=!1;function ch(e){ft===null?ft=[e]:ft.push(e)}function Jm(e){Vi=!0,ch(e)}function qt(){if(!Ta&&ft!==null){Ta=!0;var e=0,t=z;try{var n=ft;for(z=1;e<n.length;e++){var r=n[e];do r=r(!0);while(r!==null)}ft=null,Vi=!1}catch(s){throw ft!==null&&(ft=ft.slice(e+1)),Id(yl,qt),s}finally{z=t,Ta=!1}}return null}var Un=[],zn=0,xi=null,bi=0,Ue=[],ze=0,fn=null,pt=1,mt="";function en(e,t){Un[zn++]=bi,Un[zn++]=xi,xi=e,bi=t}function uh(e,t,n){Ue[ze++]=pt,Ue[ze++]=mt,Ue[ze++]=fn,fn=e;var r=pt;e=mt;var s=32-Ze(r)-1;r&=~(1<<s),n+=1;var i=32-Ze(t)+s;if(30<i){var o=s-s%5;i=(r&(1<<o)-1).toString(32),r>>=o,s-=o,pt=1<<32-Ze(t)+s|n<<s|r,mt=i+e}else pt=1<<i|n<<s|r,mt=e}function Nl(e){e.return!==null&&(en(e,1),uh(e,1,0))}function El(e){for(;e===xi;)xi=Un[--zn],Un[zn]=null,bi=Un[--zn],Un[zn]=null;for(;e===fn;)fn=Ue[--ze],Ue[ze]=null,mt=Ue[--ze],Ue[ze]=null,pt=Ue[--ze],Ue[ze]=null}var De=null,Ie=null,G=!1,Xe=null;function dh(e,t){var n=Me(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 Vc(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,De=e,Ie=Lt(t.firstChild),!0):!1;case 6:return t=e.pendingProps===""||t.nodeType!==3?null:t,t!==null?(e.stateNode=t,De=e,Ie=null,!0):!1;case 13:return t=t.nodeType!==8?null:t,t!==null?(n=fn!==null?{id:pt,overflow:mt}:null,e.memoizedState={dehydrated:t,treeContext:n,retryLane:1073741824},n=Me(18,null,null,0),n.stateNode=t,n.return=e,e.child=n,De=e,Ie=null,!0):!1;default:return!1}}function Eo(e){return(e.mode&1)!==0&&(e.flags&128)===0}function Co(e){if(G){var t=Ie;if(t){var n=t;if(!Vc(e,t)){if(Eo(e))throw Error(N(418));t=Lt(n.nextSibling);var r=De;t&&Vc(e,t)?dh(r,n):(e.flags=e.flags&-4097|2,G=!1,De=e)}}else{if(Eo(e))throw Error(N(418));e.flags=e.flags&-4097|2,G=!1,De=e}}}function qc(e){for(e=e.return;e!==null&&e.tag!==5&&e.tag!==3&&e.tag!==13;)e=e.return;De=e}function Ds(e){if(e!==De)return!1;if(!G)return qc(e),G=!0,!1;var t;if((t=e.tag!==3)&&!(t=e.tag!==5)&&(t=e.type,t=t!=="head"&&t!=="body"&&!ko(e.type,e.memoizedProps)),t&&(t=Ie)){if(Eo(e))throw hh(),Error(N(418));for(;t;)dh(e,t),t=Lt(t.nextSibling)}if(qc(e),e.tag===13){if(e=e.memoizedState,e=e!==null?e.dehydrated:null,!e)throw Error(N(317));e:{for(e=e.nextSibling,t=0;e;){if(e.nodeType===8){var n=e.data;if(n==="/$"){if(t===0){Ie=Lt(e.nextSibling);break e}t--}else n!=="$"&&n!=="$!"&&n!=="$?"||t++}e=e.nextSibling}Ie=null}}else Ie=De?Lt(e.stateNode.nextSibling):null;return!0}function hh(){for(var e=Ie;e;)e=Lt(e.nextSibling)}function er(){Ie=De=null,G=!1}function Cl(e){Xe===null?Xe=[e]:Xe.push(e)}var Qm=kt.ReactCurrentBatchConfig;function vr(e,t,n){if(e=n.ref,e!==null&&typeof e!="function"&&typeof e!="object"){if(n._owner){if(n=n._owner,n){if(n.tag!==1)throw Error(N(309));var r=n.stateNode}if(!r)throw Error(N(147,e));var s=r,i=""+e;return t!==null&&t.ref!==null&&typeof t.ref=="function"&&t.ref._stringRef===i?t.ref:(t=function(o){var l=s.refs;o===null?delete l[i]:l[i]=o},t._stringRef=i,t)}if(typeof e!="string")throw Error(N(284));if(!n._owner)throw Error(N(290,e))}return e}function Fs(e,t){throw e=Object.prototype.toString.call(t),Error(N(31,e==="[object Object]"?"object with keys {"+Object.keys(t).join(", ")+"}":e))}function Gc(e){var t=e._init;return t(e._payload)}function fh(e){function t(y,p){if(e){var g=y.deletions;g===null?(y.deletions=[p],y.flags|=16):g.push(p)}}function n(y,p){if(!e)return null;for(;p!==null;)t(y,p),p=p.sibling;return null}function r(y,p){for(y=new Map;p!==null;)p.key!==null?y.set(p.key,p):y.set(p.index,p),p=p.sibling;return y}function s(y,p){return y=Mt(y,p),y.index=0,y.sibling=null,y}function i(y,p,g){return y.index=g,e?(g=y.alternate,g!==null?(g=g.index,g<p?(y.flags|=2,p):g):(y.flags|=2,p)):(y.flags|=1048576,p)}function o(y){return e&&y.alternate===null&&(y.flags|=2),y}function l(y,p,g,_){return p===null||p.tag!==6?(p=Fa(g,y.mode,_),p.return=y,p):(p=s(p,g),p.return=y,p)}function c(y,p,g,_){var j=g.type;return j===On?d(y,p,g.props.children,_,g.key):p!==null&&(p.elementType===j||typeof j=="object"&&j!==null&&j.$$typeof===Nt&&Gc(j)===p.type)?(_=s(p,g.props),_.ref=vr(y,p,g),_.return=y,_):(_=ai(g.type,g.key,g.props,null,y.mode,_),_.ref=vr(y,p,g),_.return=y,_)}function u(y,p,g,_){return p===null||p.tag!==4||p.stateNode.containerInfo!==g.containerInfo||p.stateNode.implementation!==g.implementation?(p=La(g,y.mode,_),p.return=y,p):(p=s(p,g.children||[]),p.return=y,p)}function d(y,p,g,_,j){return p===null||p.tag!==7?(p=dn(g,y.mode,_,j),p.return=y,p):(p=s(p,g),p.return=y,p)}function f(y,p,g){if(typeof p=="string"&&p!==""||typeof p=="number")return p=Fa(""+p,y.mode,g),p.return=y,p;if(typeof p=="object"&&p!==null){switch(p.$$typeof){case Ss:return g=ai(p.type,p.key,p.props,null,y.mode,g),g.ref=vr(y,null,p),g.return=y,g;case Rn:return p=La(p,y.mode,g),p.return=y,p;case Nt:var _=p._init;return f(y,_(p._payload),g)}if(jr(p)||fr(p))return p=dn(p,y.mode,g,null),p.return=y,p;Fs(y,p)}return null}function h(y,p,g,_){var j=p!==null?p.key:null;if(typeof g=="string"&&g!==""||typeof g=="number")return j!==null?null:l(y,p,""+g,_);if(typeof g=="object"&&g!==null){switch(g.$$typeof){case Ss:return g.key===j?c(y,p,g,_):null;case Rn:return g.key===j?u(y,p,g,_):null;case Nt:return j=g._init,h(y,p,j(g._payload),_)}if(jr(g)||fr(g))return j!==null?null:d(y,p,g,_,null);Fs(y,g)}return null}function m(y,p,g,_,j){if(typeof _=="string"&&_!==""||typeof _=="number")return y=y.get(g)||null,l(p,y,""+_,j);if(typeof _=="object"&&_!==null){switch(_.$$typeof){case Ss:return y=y.get(_.key===null?g:_.key)||null,c(p,y,_,j);case Rn:return y=y.get(_.key===null?g:_.key)||null,u(p,y,_,j);case Nt:var S=_._init;return m(y,p,g,S(_._payload),j)}if(jr(_)||fr(_))return y=y.get(g)||null,d(p,y,_,j,null);Fs(p,_)}return null}function v(y,p,g,_){for(var j=null,S=null,E=p,C=p=0,k=null;E!==null&&C<g.length;C++){E.index>C?(k=E,E=null):k=E.sibling;var A=h(y,E,g[C],_);if(A===null){E===null&&(E=k);break}e&&E&&A.alternate===null&&t(y,E),p=i(A,p,C),S===null?j=A:S.sibling=A,S=A,E=k}if(C===g.length)return n(y,E),G&&en(y,C),j;if(E===null){for(;C<g.length;C++)E=f(y,g[C],_),E!==null&&(p=i(E,p,C),S===null?j=E:S.sibling=E,S=E);return G&&en(y,C),j}for(E=r(y,E);C<g.length;C++)k=m(E,y,C,g[C],_),k!==null&&(e&&k.alternate!==null&&E.delete(k.key===null?C:k.key),p=i(k,p,C),S===null?j=k:S.sibling=k,S=k);return e&&E.forEach(function(M){return t(y,M)}),G&&en(y,C),j}function w(y,p,g,_){var j=fr(g);if(typeof j!="function")throw Error(N(150));if(g=j.call(g),g==null)throw Error(N(151));for(var S=j=null,E=p,C=p=0,k=null,A=g.next();E!==null&&!A.done;C++,A=g.next()){E.index>C?(k=E,E=null):k=E.sibling;var M=h(y,E,A.value,_);if(M===null){E===null&&(E=k);break}e&&E&&M.alternate===null&&t(y,E),p=i(M,p,C),S===null?j=M:S.sibling=M,S=M,E=k}if(A.done)return n(y,E),G&&en(y,C),j;if(E===null){for(;!A.done;C++,A=g.next())A=f(y,A.value,_),A!==null&&(p=i(A,p,C),S===null?j=A:S.sibling=A,S=A);return G&&en(y,C),j}for(E=r(y,E);!A.done;C++,A=g.next())A=m(E,y,C,A.value,_),A!==null&&(e&&A.alternate!==null&&E.delete(A.key===null?C:A.key),p=i(A,p,C),S===null?j=A:S.sibling=A,S=A);return e&&E.forEach(function(xe){return t(y,xe)}),G&&en(y,C),j}function b(y,p,g,_){if(typeof g=="object"&&g!==null&&g.type===On&&g.key===null&&(g=g.props.children),typeof g=="object"&&g!==null){switch(g.$$typeof){case Ss:e:{for(var j=g.key,S=p;S!==null;){if(S.key===j){if(j=g.type,j===On){if(S.tag===7){n(y,S.sibling),p=s(S,g.props.children),p.return=y,y=p;break e}}else if(S.elementType===j||typeof j=="object"&&j!==null&&j.$$typeof===Nt&&Gc(j)===S.type){n(y,S.sibling),p=s(S,g.props),p.ref=vr(y,S,g),p.return=y,y=p;break e}n(y,S);break}else t(y,S);S=S.sibling}g.type===On?(p=dn(g.props.children,y.mode,_,g.key),p.return=y,y=p):(_=ai(g.type,g.key,g.props,null,y.mode,_),_.ref=vr(y,p,g),_.return=y,y=_)}return o(y);case Rn:e:{for(S=g.key;p!==null;){if(p.key===S)if(p.tag===4&&p.stateNode.containerInfo===g.containerInfo&&p.stateNode.implementation===g.implementation){n(y,p.sibling),p=s(p,g.children||[]),p.return=y,y=p;break e}else{n(y,p);break}else t(y,p);p=p.sibling}p=La(g,y.mode,_),p.return=y,y=p}return o(y);case Nt:return S=g._init,b(y,p,S(g._payload),_)}if(jr(g))return v(y,p,g,_);if(fr(g))return w(y,p,g,_);Fs(y,g)}return typeof g=="string"&&g!==""||typeof g=="number"?(g=""+g,p!==null&&p.tag===6?(n(y,p.sibling),p=s(p,g),p.return=y,y=p):(n(y,p),p=Fa(g,y.mode,_),p.return=y,y=p),o(y)):n(y,p)}return b}var tr=fh(!0),ph=fh(!1),_i=Vt(null),ki=null,Mn=null,Tl=null;function Al(){Tl=Mn=ki=null}function Pl(e){var t=_i.current;V(_i),e._currentValue=t}function To(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 Yn(e,t){ki=e,Tl=Mn=null,e=e.dependencies,e!==null&&e.firstContext!==null&&(e.lanes&t&&(Ee=!0),e.firstContext=null)}function We(e){var t=e._currentValue;if(Tl!==e)if(e={context:e,memoizedValue:t,next:null},Mn===null){if(ki===null)throw Error(N(308));Mn=e,ki.dependencies={lanes:0,firstContext:e}}else Mn=Mn.next=e;return t}var on=null;function Rl(e){on===null?on=[e]:on.push(e)}function mh(e,t,n,r){var s=t.interleaved;return s===null?(n.next=n,Rl(t)):(n.next=s.next,s.next=n),t.interleaved=n,xt(e,r)}function xt(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 Et=!1;function Ol(e){e.updateQueue={baseState:e.memoizedState,firstBaseUpdate:null,lastBaseUpdate:null,shared:{pending:null,interleaved:null,lanes:0},effects:null}}function gh(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 gt(e,t){return{eventTime:e,lane:t,tag:0,payload:null,callback:null,next:null}}function $t(e,t,n){var r=e.updateQueue;if(r===null)return null;if(r=r.shared,U&2){var s=r.pending;return s===null?t.next=t:(t.next=s.next,s.next=t),r.pending=t,xt(e,n)}return s=r.interleaved,s===null?(t.next=t,Rl(r)):(t.next=s.next,s.next=t),r.interleaved=t,xt(e,n)}function ei(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,vl(e,n)}}function Kc(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 ji(e,t,n,r){var s=e.updateQueue;Et=!1;var i=s.firstBaseUpdate,o=s.lastBaseUpdate,l=s.shared.pending;if(l!==null){s.shared.pending=null;var c=l,u=c.next;c.next=null,o===null?i=u:o.next=u,o=c;var d=e.alternate;d!==null&&(d=d.updateQueue,l=d.lastBaseUpdate,l!==o&&(l===null?d.firstBaseUpdate=u:l.next=u,d.lastBaseUpdate=c))}if(i!==null){var f=s.baseState;o=0,d=u=c=null,l=i;do{var h=l.lane,m=l.eventTime;if((r&h)===h){d!==null&&(d=d.next={eventTime:m,lane:0,tag:l.tag,payload:l.payload,callback:l.callback,next:null});e:{var v=e,w=l;switch(h=t,m=n,w.tag){case 1:if(v=w.payload,typeof v=="function"){f=v.call(m,f,h);break e}f=v;break e;case 3:v.flags=v.flags&-65537|128;case 0:if(v=w.payload,h=typeof v=="function"?v.call(m,f,h):v,h==null)break e;f=X({},f,h);break e;case 2:Et=!0}}l.callback!==null&&l.lane!==0&&(e.flags|=64,h=s.effects,h===null?s.effects=[l]:h.push(l))}else m={eventTime:m,lane:h,tag:l.tag,payload:l.payload,callback:l.callback,next:null},d===null?(u=d=m,c=f):d=d.next=m,o|=h;if(l=l.next,l===null){if(l=s.shared.pending,l===null)break;h=l,l=h.next,h.next=null,s.lastBaseUpdate=h,s.shared.pending=null}}while(!0);if(d===null&&(c=f),s.baseState=c,s.firstBaseUpdate=u,s.lastBaseUpdate=d,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);mn|=o,e.lanes=o,e.memoizedState=f}}function Yc(e,t,n){if(e=t.effects,t.effects=null,e!==null)for(t=0;t<e.length;t++){var r=e[t],s=r.callback;if(s!==null){if(r.callback=null,r=n,typeof s!="function")throw Error(N(191,s));s.call(r)}}}var ys={},lt=Vt(ys),Qr=Vt(ys),Xr=Vt(ys);function ln(e){if(e===ys)throw Error(N(174));return e}function Il(e,t){switch(W(Xr,t),W(Qr,e),W(lt,ys),e=t.nodeType,e){case 9:case 11:t=(t=t.documentElement)?t.namespaceURI:lo(null,"");break;default:e=e===8?t.parentNode:t,t=e.namespaceURI||null,e=e.tagName,t=lo(t,e)}V(lt),W(lt,t)}function nr(){V(lt),V(Qr),V(Xr)}function yh(e){ln(Xr.current);var t=ln(lt.current),n=lo(t,e.type);t!==n&&(W(Qr,e),W(lt,n))}function Dl(e){Qr.current===e&&(V(lt),V(Qr))}var Y=Vt(0);function Si(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 Aa=[];function Fl(){for(var e=0;e<Aa.length;e++)Aa[e]._workInProgressVersionPrimary=null;Aa.length=0}var ti=kt.ReactCurrentDispatcher,Pa=kt.ReactCurrentBatchConfig,pn=0,J=null,ae=null,ce=null,Ni=!1,Or=!1,Zr=0,Xm=0;function ge(){throw Error(N(321))}function Ll(e,t){if(t===null)return!1;for(var n=0;n<t.length&&n<e.length;n++)if(!tt(e[n],t[n]))return!1;return!0}function $l(e,t,n,r,s,i){if(pn=i,J=t,t.memoizedState=null,t.updateQueue=null,t.lanes=0,ti.current=e===null||e.memoizedState===null?ng:rg,e=n(r,s),Or){i=0;do{if(Or=!1,Zr=0,25<=i)throw Error(N(301));i+=1,ce=ae=null,t.updateQueue=null,ti.current=sg,e=n(r,s)}while(Or)}if(ti.current=Ei,t=ae!==null&&ae.next!==null,pn=0,ce=ae=J=null,Ni=!1,t)throw Error(N(300));return e}function Ul(){var e=Zr!==0;return Zr=0,e}function it(){var e={memoizedState:null,baseState:null,baseQueue:null,queue:null,next:null};return ce===null?J.memoizedState=ce=e:ce=ce.next=e,ce}function He(){if(ae===null){var e=J.alternate;e=e!==null?e.memoizedState:null}else e=ae.next;
vendor: 6,079 bytes, line 38
38var t=ce===null?J.memoizedState:ce.next;if(t!==null)ce=t,ae=e;else{if(e===null)throw Error(N(310));ae=e,e={memoizedState:ae.memoizedState,baseState:ae.baseState,baseQueue:ae.baseQueue,queue:ae.queue,next:null},ce===null?J.memoizedState=ce=e:ce=ce.next=e}return ce}function es(e,t){return typeof t=="function"?t(e):t}function Ra(e){var t=He(),n=t.queue;if(n===null)throw Error(N(311));n.lastRenderedReducer=e;var r=ae,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 l=o=null,c=null,u=i;do{var d=u.lane;if((pn&d)===d)c!==null&&(c=c.next={lane:0,action:u.action,hasEagerState:u.hasEagerState,eagerState:u.eagerState,next:null}),r=u.hasEagerState?u.eagerState:e(r,u.action);else{var f={lane:d,action:u.action,hasEagerState:u.hasEagerState,eagerState:u.eagerState,next:null};c===null?(l=c=f,o=r):c=c.next=f,J.lanes|=d,mn|=d}u=u.next}while(u!==null&&u!==i);c===null?o=r:c.next=l,tt(r,t.memoizedState)||(Ee=!0),t.memoizedState=r,t.baseState=o,t.baseQueue=c,n.lastRenderedState=r}if(e=n.interleaved,e!==null){s=e;do i=s.lane,J.lanes|=i,mn|=i,s=s.next;while(s!==e)}else s===null&&(n.lanes=0);return[t.memoizedState,n.dispatch]}function Oa(e){var t=He(),n=t.queue;if(n===null)throw Error(N(311));n.lastRenderedReducer=e;var r=n.dispatch,s=n.pending,i=t.memoizedState;if(s!==null){n.pending=null;var o=s=s.next;do i=e(i,o.action),o=o.next;while(o!==s);tt(i,t.memoizedState)||(Ee=!0),t.memoizedState=i,t.baseQueue===null&&(t.baseState=i),n.lastRenderedState=i}return[i,r]}function vh(){}function wh(e,t){var n=J,r=He(),s=t(),i=!tt(r.memoizedState,s);if(i&&(r.memoizedState=s,Ee=!0),r=r.queue,zl(_h.bind(null,n,r,e),[e]),r.getSnapshot!==t||i||ce!==null&&ce.memoizedState.tag&1){if(n.flags|=2048,ts(9,bh.bind(null,n,r,s,t),void 0,null),ue===null)throw Error(N(349));pn&30||xh(n,t,s)}return s}function xh(e,t,n){e.flags|=16384,e={getSnapshot:t,value:n},t=J.updateQueue,t===null?(t={lastEffect:null,stores:null},J.updateQueue=t,t.stores=[e]):(n=t.stores,n===null?t.stores=[e]:n.push(e))}function bh(e,t,n,r){t.value=n,t.getSnapshot=r,kh(t)&&jh(e)}function _h(e,t,n){return n(function(){kh(t)&&jh(e)})}function kh(e){var t=e.getSnapshot;e=e.value;try{var n=t();return!tt(e,n)}catch{return!0}}function jh(e){var t=xt(e,1);t!==null&&et(t,e,1,-1)}function Jc(e){var t=it();return typeof e=="function"&&(e=e()),t.memoizedState=t.baseState=e,e={pending:null,interleaved:null,lanes:0,dispatch:null,lastRenderedReducer:es,lastRenderedState:e},t.queue=e,e=e.dispatch=tg.bind(null,J,e),[t.memoizedState,e]}function ts(e,t,n,r){return e={tag:e,create:t,destroy:n,deps:r,next:null},t=J.updateQueue,t===null?(t={lastEffect:null,stores:null},J.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 Sh(){return He().memoizedState}function ni(e,t,n,r){var s=it();J.flags|=e,s.memoizedState=ts(1|t,n,void 0,r===void 0?null:r)}function qi(e,t,n,r){var s=He();r=r===void 0?null:r;var i=void 0;if(ae!==null){var o=ae.memoizedState;if(i=o.destroy,r!==null&&Ll(r,o.deps)){s.memoizedState=ts(t,n,i,r);return}}J.flags|=e,s.memoizedState=ts(1|t,n,i,r)}function Qc(e,t){return ni(8390656,8,e,t)}function zl(e,t){return qi(2048,8,e,t)}function Nh(e,t){return qi(4,2,e,t)}function Eh(e,t){return qi(4,4,e,t)}function Ch(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 Th(e,t,n){return n=n!=null?n.concat([e]):null,qi(4,4,Ch.bind(null,t,e),n)}function Ml(){}function Ah(e,t){var n=He();t=t===void 0?null:t;var r=n.memoizedState;return r!==null&&t!==null&&Ll(t,r[1])?r[0]:(n.memoizedState=[e,t],e)}function Ph(e,t){var n=He();t=t===void 0?null:t;var r=n.memoizedState;return r!==null&&t!==null&&Ll(t,r[1])?r[0]:(e=e(),n.memoizedState=[e,t],e)}function Rh(e,t,n){return pn&21?(tt(n,t)||(n=Ld(),J.lanes|=n,mn|=n,e.baseState=!0),t):(e.baseState&&(e.baseState=!1,Ee=!0),e.memoizedState=n)}function Zm(e,t){var n=z;z=n!==0&&4>n?n:4,e(!0);var r=Pa.transition;Pa.transition={};try{e(!1),t()}finally{z=n,Pa.transition=r}}function Oh(){return He().memoizedState}function eg(e,t,n){var r=zt(e);if(n={lane:r,action:n,hasEagerState:!1,eagerState:null,next:null},Ih(e))Dh(t,n);else if(n=mh(e,t,n,r),n!==null){var s=ke();et(n,e,r,s),Fh(n,t,r)}}function tg(e,t,n){var r=zt(e),s={lane:r,action:n,hasEagerState:!1,eagerState:null,next:null};if(Ih(e))Dh(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,l=i(o,n);if(s.hasEagerState=!0,s.eagerState=l,tt(l,o)){var c=t.interleaved;c===null?(s.next=s,Rl(t)):(s.next=c.next,c.next=s),t.interleaved=s;return}}catch{}finally{}n=mh(e,t,s,r),n!==null&&(s=ke(),et(n,e,r,s),Fh(n,t,r))}}function Ih(e){var t=e.alternate;return e===J||t!==null&&t===J}function Dh(e,t){Or=Ni=!0;var n=e.pending;n===null?t.next=t:(t.next=n.next,n.next=t),e.pending=t}function Fh(e,t,n){if(n&4194240){var r=t.lanes;r&=e.pendingLanes,n|=r,t.lanes=n,vl(e,n)}}var Ei={readContext:We,useCallback:ge,useContext:ge,useEffect:ge,useImperativeHandle:ge,useInsertionEffect:ge,useLayoutEffect:ge,useMemo:ge,useReducer:ge,useRef:ge,useState:ge,useDebugValue:ge,useDeferredValue:ge,useTransition:ge,useMutableSource:ge,useSyncExternalStore:ge,useId:ge,unstable_isNewReconciler:!1},ng={readContext:We,useCallback:function(e,t){return it().memoizedState=[e,t===void 0?null:t],e},useContext:We,useEffect:Qc,useImperativeHandle:function(e,t,n){return n=n!=null?n.concat([e]):null,ni(4194308,4,Ch.bind(null,t,e),n)},useLayoutEffect:function(e,t){return ni(4194308,4,e,t)},useInsertionEffect:function(e,t){return ni(4,2,e,t)},useMemo:function(e,t){var n=it();return t=t===void 0?null:t,e=e(),n.memoizedState=[e,t],e},useReducer:function(e,t,n){var r=it();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=eg.bind(null,J,e),[r.memoizedState,e]}
vendor: 4,419 bytes, lines 38-40
38,useRef:function(e){var t=it();return e={current:e},t.memoizedState=e},useState:Jc,useDebugValue:Ml,useDeferredValue:function(e){return it().memoizedState=e},useTransition:function(){var e=Jc(!1),t=e[0];return e=Zm.bind(null,e[1]),it().memoizedState=e,[t,e]},useMutableSource:function(){},useSyncExternalStore:function(e,t,n){var r=J,s=it();if(G){if(n===void 0)throw Error(N(407));n=n()}else{if(n=t(),ue===null)throw Error(N(349));pn&30||xh(r,t,n)}s.memoizedState=n;var i={value:n,getSnapshot:t};return s.queue=i,Qc(_h.bind(null,r,i,e),[e]),r.flags|=2048,ts(9,bh.bind(null,r,i,n,t),void 0,null),n},useId:function(){var e=it(),t=ue.identifierPrefix;if(G){var n=mt,r=pt;n=(r&~(1<<32-Ze(r)-1)).toString(32)+n,t=":"+t+"R"+n,n=Zr++,0<n&&(t+="H"+n.toString(32)),t+=":"}else n=Xm++,t=":"+t+"r"+n.toString(32)+":";return e.memoizedState=t},unstable_isNewReconciler:!1},rg={readContext:We,useCallback:Ah,useContext:We,useEffect:zl,useImperativeHandle:Th,useInsertionEffect:Nh,useLayoutEffect:Eh,useMemo:Ph,useReducer:Ra,useRef:Sh,useState:function(){return Ra(es)},useDebugValue:Ml,useDeferredValue:function(e){var t=He();return Rh(t,ae.memoizedState,e)},useTransition:function(){var e=Ra(es)[0],t=He().memoizedState;return[e,t]},useMutableSource:vh,useSyncExternalStore:wh,useId:Oh,unstable_isNewReconciler:!1},sg={readContext:We,useCallback:Ah,useContext:We,useEffect:zl,useImperativeHandle:Th,useInsertionEffect:Nh,useLayoutEffect:Eh,useMemo:Ph,useReducer:Oa,useRef:Sh,useState:function(){return Oa(es)},useDebugValue:Ml,useDeferredValue:function(e){var t=He();return ae===null?t.memoizedState=e:Rh(t,ae.memoizedState,e)},useTransition:function(){var e=Oa(es)[0],t=He().memoizedState;return[e,t]},useMutableSource:vh,useSyncExternalStore:wh,useId:Oh,unstable_isNewReconciler:!1};function Ke(e,t){if(e&&e.defaultProps){t=X({},t),e=e.defaultProps;for(var n in e)t[n]===void 0&&(t[n]=e[n]);return t}return t}function Ao(e,t,n,r){t=e.memoizedState,n=n(r,t),n=n==null?t:X({},t,n),e.memoizedState=n,e.lanes===0&&(e.updateQueue.baseState=n)}var Gi={isMounted:function(e){return(e=e._reactInternals)?vn(e)===e:!1},enqueueSetState:function(e,t,n){e=e._reactInternals;var r=ke(),s=zt(e),i=gt(r,s);i.payload=t,n!=null&&(i.callback=n),t=$t(e,i,s),t!==null&&(et(t,e,s,r),ei(t,e,s))},enqueueReplaceState:function(e,t,n){e=e._reactInternals;var r=ke(),s=zt(e),i=gt(r,s);i.tag=1,i.payload=t,n!=null&&(i.callback=n),t=$t(e,i,s),t!==null&&(et(t,e,s,r),ei(t,e,s))},enqueueForceUpdate:function(e,t){e=e._reactInternals;var n=ke(),r=zt(e),s=gt(n,r);s.tag=2,t!=null&&(s.callback=t),t=$t(e,s,r),t!==null&&(et(t,e,r,n),ei(t,e,r))}};function Xc(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?!Gr(n,r)||!Gr(s,i):!0}function Lh(e,t,n){var r=!1,s=Wt,i=t.contextType;return typeof i=="object"&&i!==null?i=We(i):(s=Te(t)?hn:we.current,r=t.contextTypes,i=(r=r!=null)?Zn(e,s):Wt),t=new t(n,i),e.memoizedState=t.state!==null&&t.state!==void 0?t.state:null,t.updater=Gi,e.stateNode=t,t._reactInternals=e,r&&(e=e.stateNode,e.__reactInternalMemoizedUnmaskedChildContext=s,e.__reactInternalMemoizedMaskedChildContext=i),t}function Zc(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&&Gi.enqueueReplaceState(t,t.state,null)}function Po(e,t,n,r){var s=e.stateNode;s.props=n,s.state=e.memoizedState,s.refs={},Ol(e);var i=t.contextType;typeof i=="object"&&i!==null?s.context=We(i):(i=Te(t)?hn:we.current,s.context=Zn(e,i)),s.state=e.memoizedState,i=t.getDerivedStateFromProps,typeof i=="function"&&(Ao(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&&Gi.enqueueReplaceState(s,s.state,null),ji(e,n,s,r),s.state=e.memoizedState),typeof s.componentDidMount=="function"&&(e.flags|=4194308)}function rr(e,t){try{var n="",r=t;do n+=Rp(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}}
vendor: 11,172 bytes, line 40
40function Ia(e,t,n){return{value:e,source:null,stack:n??null,digest:t??null}}function Ro(e,t){try{console.error(t.value)}catch(n){setTimeout(function(){throw n})}}var ig=typeof WeakMap=="function"?WeakMap:Map;function $h(e,t,n){n=gt(-1,n),n.tag=3,n.payload={element:null};var r=t.value;return n.callback=function(){Ti||(Ti=!0,Bo=r),Ro(e,t)},n}function Uh(e,t,n){n=gt(-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(){Ro(e,t)}}var i=e.stateNode;return i!==null&&typeof i.componentDidCatch=="function"&&(n.callback=function(){Ro(e,t),typeof r!="function"&&(Ut===null?Ut=new Set([this]):Ut.add(this));var o=t.stack;this.componentDidCatch(t.value,{componentStack:o!==null?o:""})}),n}function eu(e,t,n){var r=e.pingCache;if(r===null){r=e.pingCache=new ig;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=wg.bind(null,e,t,n),t.then(e,e))}function tu(e){do{var t;if((t=e.tag===13)&&(t=e.memoizedState,t=t!==null?t.dehydrated!==null:!0),t)return e;e=e.return}while(e!==null);return null}function nu(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=gt(-1,1),t.tag=2,$t(n,t,1))),n.lanes|=1),e)}var ag=kt.ReactCurrentOwner,Ee=!1;function be(e,t,n,r){t.child=e===null?ph(t,null,n,r):tr(t,e.child,n,r)}function ru(e,t,n,r,s){n=n.render;var i=t.ref;return Yn(t,s),r=$l(e,t,n,r,i,s),n=Ul(),e!==null&&!Ee?(t.updateQueue=e.updateQueue,t.flags&=-2053,e.lanes&=~s,bt(e,t,s)):(G&&n&&Nl(t),t.flags|=1,be(e,t,r,s),t.child)}function su(e,t,n,r,s){if(e===null){var i=n.type;return typeof i=="function"&&!Yl(i)&&i.defaultProps===void 0&&n.compare===null&&n.defaultProps===void 0?(t.tag=15,t.type=i,zh(e,t,i,r,s)):(e=ai(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:Gr,n(o,r)&&e.ref===t.ref)return bt(e,t,s)}return t.flags|=1,e=Mt(i,r),e.ref=t.ref,e.return=t,t.child=e}function zh(e,t,n,r,s){if(e!==null){var i=e.memoizedProps;if(Gr(i,r)&&e.ref===t.ref)if(Ee=!1,t.pendingProps=r=i,(e.lanes&s)!==0)e.flags&131072&&(Ee=!0);else return t.lanes=e.lanes,bt(e,t,s)}return Oo(e,t,n,r,s)}function Mh(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},W(Wn,Re),Re|=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,W(Wn,Re),Re|=e,null;t.memoizedState={baseLanes:0,cachePool:null,transitions:null},r=i!==null?i.baseLanes:n,W(Wn,Re),Re|=r}else i!==null?(r=i.baseLanes|n,t.memoizedState=null):r=n,W(Wn,Re),Re|=r;return be(e,t,s,n),t.child}function Bh(e,t){var n=t.ref;(e===null&&n!==null||e!==null&&e.ref!==n)&&(t.flags|=512,t.flags|=2097152)}function Oo(e,t,n,r,s){var i=Te(n)?hn:we.current;return i=Zn(t,i),Yn(t,s),n=$l(e,t,n,r,i,s),r=Ul(),e!==null&&!Ee?(t.updateQueue=e.updateQueue,t.flags&=-2053,e.lanes&=~s,bt(e,t,s)):(G&&r&&Nl(t),t.flags|=1,be(e,t,n,s),t.child)}function iu(e,t,n,r,s){if(Te(n)){var i=!0;wi(t)}else i=!1;if(Yn(t,s),t.stateNode===null)ri(e,t),Lh(t,n,r),Po(t,n,r,s),r=!0;else if(e===null){var o=t.stateNode,l=t.memoizedProps;o.props=l;var c=o.context,u=n.contextType;typeof u=="object"&&u!==null?u=We(u):(u=Te(n)?hn:we.current,u=Zn(t,u));var d=n.getDerivedStateFromProps,f=typeof d=="function"||typeof o.getSnapshotBeforeUpdate=="function";f||typeof o.UNSAFE_componentWillReceiveProps!="function"&&typeof o.componentWillReceiveProps!="function"||(l!==r||c!==u)&&Zc(t,o,r,u),Et=!1;var h=t.memoizedState;o.state=h,ji(t,r,o,s),c=t.memoizedState,l!==r||h!==c||Ce.current||Et?(typeof d=="function"&&(Ao(t,n,d,r),c=t.memoizedState),(l=Et||Xc(t,n,l,r,h,c,u))?(f||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=c),o.props=r,o.state=c,o.context=u,r=l):(typeof o.componentDidMount=="function"&&(t.flags|=4194308),r=!1)}else{o=t.stateNode,gh(e,t),l=t.memoizedProps,u=t.type===t.elementType?l:Ke(t.type,l),o.props=u,f=t.pendingProps,h=o.context,c=n.contextType,typeof c=="object"&&c!==null?c=We(c):(c=Te(n)?hn:we.current,c=Zn(t,c));var m=n.getDerivedStateFromProps;(d=typeof m=="function"||typeof o.getSnapshotBeforeUpdate=="function")||typeof o.UNSAFE_componentWillReceiveProps!="function"&&typeof o.componentWillReceiveProps!="function"||(l!==f||h!==c)&&Zc(t,o,r,c),Et=!1,h=t.memoizedState,o.state=h,ji(t,r,o,s);var v=t.memoizedState;l!==f||h!==v||Ce.current||Et?(typeof m=="function"&&(Ao(t,n,m,r),v=t.memoizedState),(u=Et||Xc(t,n,u,r,h,v,c)||!1)?(d||typeof o.UNSAFE_componentWillUpdate!="function"&&typeof o.componentWillUpdate!="function"||(typeof o.componentWillUpdate=="function"&&o.componentWillUpdate(r,v,c),typeof o.UNSAFE_componentWillUpdate=="function"&&o.UNSAFE_componentWillUpdate(r,v,c)),typeof o.componentDidUpdate=="function"&&(t.flags|=4),typeof o.getSnapshotBeforeUpdate=="function"&&(t.flags|=1024)):(typeof o.componentDidUpdate!="function"||l===e.memoizedProps&&h===e.memoizedState||(t.flags|=4),typeof o.getSnapshotBeforeUpdate!="function"||l===e.memoizedProps&&h===e.memoizedState||(t.flags|=1024),t.memoizedProps=r,t.memoizedState=v),o.props=r,o.state=v,o.context=c,r=u):(typeof o.componentDidUpdate!="function"||l===e.memoizedProps&&h===e.memoizedState||(t.flags|=4),typeof o.getSnapshotBeforeUpdate!="function"||l===e.memoizedProps&&h===e.memoizedState||(t.flags|=1024),r=!1)}return Io(e,t,n,r,i,s)}function Io(e,t,n,r,s,i){Bh(e,t);var o=(t.flags&128)!==0;if(!r&&!o)return s&&Hc(t,n,!1),bt(e,t,i);r=t.stateNode,ag.current=t;var l=o&&typeof n.getDerivedStateFromError!="function"?null:r.render();return t.flags|=1,e!==null&&o?(t.child=tr(t,e.child,null,i),t.child=tr(t,null,l,i)):be(e,t,l,i),t.memoizedState=r.state,s&&Hc(t,n,!0),t.child}function Wh(e){var t=e.stateNode;t.pendingContext?Wc(e,t.pendingContext,t.pendingContext!==t.context):t.context&&Wc(e,t.context,!1),Il(e,t.containerInfo)}function au(e,t,n,r,s){return er(),Cl(s),t.flags|=256,be(e,t,n,r),t.child}var Do={dehydrated:null,treeContext:null,retryLane:0};function Fo(e){return{baseLanes:e,cachePool:null,transitions:null}}function Hh(e,t,n){var r=t.pendingProps,s=Y.current,i=!1,o=(t.flags&128)!==0,l;if((l=o)||(l=e!==null&&e.memoizedState===null?!1:(s&2)!==0),l?(i=!0,t.flags&=-129):(e===null||e.memoizedState!==null)&&(s|=1),W(Y,s&1),e===null)return Co(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=Ji(o,r,0,null),e=dn(e,r,n,null),i.return=t,e.return=t,i.sibling=e,t.child=i,t.child.memoizedState=Fo(n),t.memoizedState=Do,e):Bl(t,o));if(s=e.memoizedState,s!==null&&(l=s.dehydrated,l!==null))return og(e,t,o,r,l,s,n);if(i){i=r.fallback,o=t.mode,s=e.child,l=s.sibling;var c={mode:"hidden",children:r.children};return!(o&1)&&t.child!==s?(r=t.child,r.childLanes=0,r.pendingProps=c,t.deletions=null):(r=Mt(s,c),r.subtreeFlags=s.subtreeFlags&14680064),l!==null?i=Mt(l,i):(i=dn(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?Fo(n):{baseLanes:o.baseLanes|n,cachePool:null,transitions:o.transitions},i.memoizedState=o,i.childLanes=e.childLanes&~n,t.memoizedState=Do,r}return i=e.child,e=i.sibling,r=Mt(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 Bl(e,t){return t=Ji({mode:"visible",children:t},e.mode,0,null),t.return=e,e.child=t}function Ls(e,t,n,r){return r!==null&&Cl(r),tr(t,e.child,null,n),e=Bl(t,t.pendingProps.children),e.flags|=2,t.memoizedState=null,e}function og(e,t,n,r,s,i,o){if(n)return t.flags&256?(t.flags&=-257,r=Ia(Error(N(422))),Ls(e,t,o,r)):t.memoizedState!==null?(t.child=e.child,t.flags|=128,null):(i=r.fallback,s=t.mode,r=Ji({mode:"visible",children:r.children},s,0,null),i=dn(i,s,o,null),i.flags|=2,r.return=t,i.return=t,r.sibling=i,t.child=r,t.mode&1&&tr(t,e.child,null,o),t.child.memoizedState=Fo(o),t.memoizedState=Do,i);if(!(t.mode&1))return Ls(e,t,o,null);if(s.data==="$!"){if(r=s.nextSibling&&s.nextSibling.dataset,r)var l=r.dgst;return r=l,i=Error(N(419)),r=Ia(i,r,void 0),Ls(e,t,o,r)}if(l=(o&e.childLanes)!==0,Ee||l){if(r=ue,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,xt(e,s),et(r,e,s,-1))}return Kl(),r=Ia(Error(N(421))),Ls(e,t,o,r)}return s.data==="$?"?(t.flags|=128,t.child=e.child,t=xg.bind(null,e),s._reactRetry=t,null):(e=i.treeContext,Ie=Lt(s.nextSibling),De=t,G=!0,Xe=null,e!==null&&(Ue[ze++]=pt,Ue[ze++]=mt,Ue[ze++]=fn,pt=e.id,mt=e.overflow,fn=t),t=Bl(t,r.children),t.flags|=4096,t)}function ou(e,t,n){e.lanes|=t;var r=e.alternate;r!==null&&(r.lanes|=t),To(e.return,t,n)}function Da(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 Vh(e,t,n){var r=t.pendingProps,s=r.revealOrder,i=r.tail;if(be(e,t,r.children,n),r=Y.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&&ou(e,n,t);else if(e.tag===19)ou(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(W(Y,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&&Si(e)===null&&(s=n),n=n.sibling;n=s,n===null?(s=t.child,t.child=null):(s=n.sibling,n.sibling=null),Da(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&&Si(e)===null){t.child=s;break}e=s.sibling,s.sibling=n,n=s,s=e}Da(t,!0,n,null,i);break;case"together":Da(t,!1,null,null,void 0);break;default:t.memoizedState=null}return t.child}function ri(e,t){!(t.mode&1)&&e!==null&&(e.alternate=null,t.alternate=null,t.flags|=2)}function bt(e,t,n){if(e!==null&&(t.dependencies=e.dependencies),mn|=t.lanes,!(n&t.childLanes))return null;if(e!==null&&t.child!==e.child)throw Error(N(153));
vendor: 5,420 bytes, line 40
40if(t.child!==null){for(e=t.child,n=Mt(e,e.pendingProps),t.child=n,n.return=t;e.sibling!==null;)e=e.sibling,n=n.sibling=Mt(e,e.pendingProps),n.return=t;n.sibling=null}return t.child}function lg(e,t,n){switch(t.tag){case 3:Wh(t),er();break;case 5:yh(t);break;case 1:Te(t.type)&&wi(t);break;case 4:Il(t,t.stateNode.containerInfo);break;case 10:var r=t.type._context,s=t.memoizedProps.value;W(_i,r._currentValue),r._currentValue=s;break;case 13:if(r=t.memoizedState,r!==null)return r.dehydrated!==null?(W(Y,Y.current&1),t.flags|=128,null):n&t.child.childLanes?Hh(e,t,n):(W(Y,Y.current&1),e=bt(e,t,n),e!==null?e.sibling:null);W(Y,Y.current&1);break;case 19:if(r=(n&t.childLanes)!==0,e.flags&128){if(r)return Vh(e,t,n);t.flags|=128}if(s=t.memoizedState,s!==null&&(s.rendering=null,s.tail=null,s.lastEffect=null),W(Y,Y.current),r)break;return null;case 22:case 23:return t.lanes=0,Mh(e,t,n)}return bt(e,t,n)}var qh,Lo,Gh,Kh;qh=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}};Lo=function(){};Gh=function(e,t,n,r){var s=e.memoizedProps;if(s!==r){e=t.stateNode,ln(lt.current);var i=null;switch(n){case"input":s=so(e,s),r=so(e,r),i=[];break;case"select":s=X({},s,{value:void 0}),r=X({},r,{value:void 0}),i=[];break;case"textarea":s=oo(e,s),r=oo(e,r),i=[];break;default:typeof s.onClick!="function"&&typeof r.onClick=="function"&&(e.onclick=yi)}co(n,r);var o;n=null;for(u in s)if(!r.hasOwnProperty(u)&&s.hasOwnProperty(u)&&s[u]!=null)if(u==="style"){var l=s[u];for(o in l)l.hasOwnProperty(o)&&(n||(n={}),n[o]="")}else u!=="dangerouslySetInnerHTML"&&u!=="children"&&u!=="suppressContentEditableWarning"&&u!=="suppressHydrationWarning"&&u!=="autoFocus"&&(zr.hasOwnProperty(u)?i||(i=[]):(i=i||[]).push(u,null));for(u in r){var c=r[u];if(l=s!=null?s[u]:void 0,r.hasOwnProperty(u)&&c!==l&&(c!=null||l!=null))if(u==="style")if(l){for(o in l)!l.hasOwnProperty(o)||c&&c.hasOwnProperty(o)||(n||(n={}),n[o]="");for(o in c)c.hasOwnProperty(o)&&l[o]!==c[o]&&(n||(n={}),n[o]=c[o])}else n||(i||(i=[]),i.push(u,n)),n=c;else u==="dangerouslySetInnerHTML"?(c=c?c.__html:void 0,l=l?l.__html:void 0,c!=null&&l!==c&&(i=i||[]).push(u,c)):u==="children"?typeof c!="string"&&typeof c!="number"||(i=i||[]).push(u,""+c):u!=="suppressContentEditableWarning"&&u!=="suppressHydrationWarning"&&(zr.hasOwnProperty(u)?(c!=null&&u==="onScroll"&&H("scroll",e),i||l===c||(i=[])):(i=i||[]).push(u,c))}n&&(i=i||[]).push("style",n);var u=i;(t.updateQueue=u)&&(t.flags|=4)}};Kh=function(e,t,n,r){n!==r&&(t.flags|=4)};function wr(e,t){if(!G)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 ye(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 cg(e,t,n){var r=t.pendingProps;switch(El(t),t.tag){case 2:case 16:case 15:case 0:case 11:case 7:case 8:case 12:case 9:case 14:return ye(t),null;case 1:return Te(t.type)&&vi(),ye(t),null;case 3:return r=t.stateNode,nr(),V(Ce),V(we),Fl(),r.pendingContext&&(r.context=r.pendingContext,r.pendingContext=null),(e===null||e.child===null)&&(Ds(t)?t.flags|=4:e===null||e.memoizedState.isDehydrated&&!(t.flags&256)||(t.flags|=1024,Xe!==null&&(Vo(Xe),Xe=null))),Lo(e,t),ye(t),null;case 5:Dl(t);var s=ln(Xr.current);if(n=t.type,e!==null&&t.stateNode!=null)Gh(e,t,n,r,s),e.ref!==t.ref&&(t.flags|=512,t.flags|=2097152);else{if(!r){if(t.stateNode===null)throw Error(N(166));return ye(t),null}if(e=ln(lt.current),Ds(t)){r=t.stateNode,n=t.type;var i=t.memoizedProps;switch(r[at]=t,r[Jr]=i,e=(t.mode&1)!==0,n){case"dialog":H("cancel",r),H("close",r);break;case"iframe":case"object":case"embed":H("load",r);break;case"video":case"audio":for(s=0;s<Nr.length;s++)H(Nr[s],r);break;case"source":H("error",r);break;case"img":case"image":case"link":H("error",r),H("load",r);break;case"details":H("toggle",r);break;case"input":gc(r,i),H("invalid",r);break;case"select":r._wrapperState={wasMultiple:!!i.multiple},H("invalid",r);break;case"textarea":vc(r,i),H("invalid",r)}co(n,i),s=null;for(var o in i)if(i.hasOwnProperty(o)){var l=i[o];o==="children"?typeof l=="string"?r.textContent!==l&&(i.suppressHydrationWarning!==!0&&Is(r.textContent,l,e),s=["children",l]):typeof l=="number"&&r.textContent!==""+l&&(i.suppressHydrationWarning!==!0&&Is(r.textContent,l,e),s=["children",""+l]):zr.hasOwnProperty(o)&&l!=null&&o==="onScroll"&&H("scroll",r)}switch(n){case"input":Ns(r),yc(r,i,!0);break;case"textarea":Ns(r),wc(r);break;case"select":case"option":break;default:typeof i.onClick=="function"&&(r.onclick=yi)}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=_d(n)),e==="http://www.w3.org/1999/xhtml"?n==="script"?(e=o.createElement("div"),e.innerHTML="<script><\/script>
40",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[at]=t,e[Jr]=r,qh(e,t,!1,!1),t.stateNode=e;e:{switch(o=uo(n,r),n){case"dialog":H("cancel",e),H("close",e),s=r;break;case"iframe":case"object":case"embed":H("load",e),s=r;break;case"video":case"audio":for(s=0;s<Nr.length;s++)H(Nr[s],e);s=r;break;case"source":H("error",e),s=r;break;case"img":case"image":case"link":H("error",e),H("load",e),s=r;break;case"details":H("toggle",e),s=r;break;case"input":gc(e,r),s=so(e,r),H("invalid",e);break;case"option":s=r;break;case"select":e._wrapperState={wasMultiple:!!r.multiple},s=X({},r,{value:void 0}),H("invalid",e);break;case"textarea":vc(e,r),s=oo(e,r),H("invalid",e);break;default:s=r}co(n,s),l=s;for(i in l)if(l.hasOwnProperty(i)){var c=l[i];i==="style"?Sd(e,c):i==="dangerouslySetInnerHTML"?(c=c?c.__html:void 0,c!=null&&kd(e,c)):i==="children"?typeof c=="string"?(n!=="textarea"||c!=="")&&Mr(e,c):typeof c=="number"&&Mr(e,""+c):i!=="suppressContentEditableWarning"&&i!=="suppressHydrationWarning"&&i!=="autoFocus"&&(zr.hasOwnProperty(i)?c!=null&&i==="onScroll"&&H("scroll",e):c!=null&&hl(e,i,c,o))}switch(n){case"input":Ns(e),yc(e,r,!1);break;case"textarea":Ns(e),wc(e);break;case"option":r.value!=null&&e.setAttribute("value",""+Bt(r.value));break;case"select":e.multiple=!!r.multiple,i=r.value,i!=null?Vn(e,!!r.multiple,i,!1):r.defaultValue!=null&&Vn(e,!!r.multiple,r.defaultValue,!0);break;default:typeof s.onClick=="function"&&(e.onclick=yi)}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 ye(t),null;case 6:if(e&&t.stateNode!=null)Kh(e,t,e.memoizedProps,r);else{if(typeof r!="string"&&t.stateNode===null)throw Error(N(166));if(n=ln(Xr.current),ln(lt.current),Ds(t)){if(r=t.stateNode,n=t.memoizedProps,r[at]=t,(i=r.nodeValue!==n)&&(e=De,e!==null))switch(e.tag){case 3:Is(r.nodeValue,n,(e.mode&1)!==0);break;case 5:e.memoizedProps.suppressHydrationWarning!==!0&&Is(r.nodeValue,n,(e.mode&1)!==0)}i&&(t.flags|=4)}else r=(n.nodeType===9?n:n.ownerDocument).createTextNode(r),r[at]=t,t.stateNode=r}return ye(t),null;case 13:if(V(Y),r=t.memoizedState,e===null||e.memoizedState!==null&&e.memoizedState.dehydrated!==null){if(G&&Ie!==null&&t.mode&1&&!(t.flags&128))hh(),er(),t.flags|=98560,i=!1;else if(i=Ds(t),r!==null&&r.dehydrated!==null){if(e===null){if(!i)throw Error(N(318));if(i=t.memoizedState,i=i!==null?i.dehydrated:null,!i)throw Error(N(317));i[at]=t}else er(),!(t.flags&128)&&(t.memoizedState=null),t.flags|=4;ye(t),i=!1}else Xe!==null&&(Vo(Xe),Xe=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||Y.current&1?oe===0&&(oe=3):Kl())),t.updateQueue!==null&&(t.flags|=4),ye(t),null);case 4:return nr(),Lo(e,t),e===null&&Kr(t.stateNode.containerInfo),ye(t),null;case 10:return Pl(t.type._context),ye(t),null;case 17:return Te(t.type)&&vi(),ye(t),null;case 19:if(V(Y),i=t.memoizedState,i===null)return ye(t),null;if(r=(t.flags&128)!==0,o=i.rendering,o===null)if(r)wr(i,!1);else{if(oe!==0||e!==null&&e.flags&128)for(e=t.child;e!==null;){if(o=Si(e),o!==null){for(t.flags|=128,wr(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 W(Y,Y.current&1|2),t.child}e=e.sibling}i.tail!==null&&ne()>sr&&(t.flags|=128,r=!0,wr(i,!1),t.lanes=4194304)}else{if(!r)if(e=Si(o),e!==null){if(t.flags|=128,r=!0,n=e.updateQueue,n!==null&&(t.updateQueue=n,t.flags|=4),wr(i,!0),i.tail===null&&i.tailMode==="hidden"&&!o.alternate&&!G)return ye(t),null}else 2*ne()-i.renderingStartTime>sr&&n!==1073741824&&(t.flags|=128,r=!0,wr(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=ne(),t.sibling=null,n=Y.current,W(Y,r?n&1|2:n&1),t):(ye(t),null);
vendor: 13,968 bytes, line 40
40case 22:case 23:return Gl(),r=t.memoizedState!==null,e!==null&&e.memoizedState!==null!==r&&(t.flags|=8192),r&&t.mode&1?Re&1073741824&&(ye(t),t.subtreeFlags&6&&(t.flags|=8192)):ye(t),null;case 24:return null;case 25:return null}throw Error(N(156,t.tag))}function ug(e,t){switch(El(t),t.tag){case 1:return Te(t.type)&&vi(),e=t.flags,e&65536?(t.flags=e&-65537|128,t):null;case 3:return nr(),V(Ce),V(we),Fl(),e=t.flags,e&65536&&!(e&128)?(t.flags=e&-65537|128,t):null;case 5:return Dl(t),null;case 13:if(V(Y),e=t.memoizedState,e!==null&&e.dehydrated!==null){if(t.alternate===null)throw Error(N(340));er()}return e=t.flags,e&65536?(t.flags=e&-65537|128,t):null;case 19:return V(Y),null;case 4:return nr(),null;case 10:return Pl(t.type._context),null;case 22:case 23:return Gl(),null;case 24:return null;default:return null}}var $s=!1,ve=!1,dg=typeof WeakSet=="function"?WeakSet:Set,T=null;function Bn(e,t){var n=e.ref;if(n!==null)if(typeof n=="function")try{n(null)}catch(r){ee(e,t,r)}else n.current=null}function $o(e,t,n){try{n()}catch(r){ee(e,t,r)}}var lu=!1;function hg(e,t){if(bo=pi,e=Zd(),Sl(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,l=-1,c=-1,u=0,d=0,f=e,h=null;t:for(;;){for(var m;f!==n||s!==0&&f.nodeType!==3||(l=o+s),f!==i||r!==0&&f.nodeType!==3||(c=o+r),f.nodeType===3&&(o+=f.nodeValue.length),(m=f.firstChild)!==null;)h=f,f=m;for(;;){if(f===e)break t;if(h===n&&++u===s&&(l=o),h===i&&++d===r&&(c=o),(m=f.nextSibling)!==null)break;f=h,h=f.parentNode}f=m}n=l===-1||c===-1?null:{start:l,end:c}}else n=null}n=n||{start:0,end:0}}else n=null;for(_o={focusedElem:e,selectionRange:n},pi=!1,T=t;T!==null;)if(t=T,e=t.child,(t.subtreeFlags&1028)!==0&&e!==null)e.return=t,T=e;else for(;T!==null;){t=T;try{var v=t.alternate;if(t.flags&1024)switch(t.tag){case 0:case 11:case 15:break;case 1:if(v!==null){var w=v.memoizedProps,b=v.memoizedState,y=t.stateNode,p=y.getSnapshotBeforeUpdate(t.elementType===t.type?w:Ke(t.type,w),b);y.__reactInternalSnapshotBeforeUpdate=p}break;case 3:var g=t.stateNode.containerInfo;g.nodeType===1?g.textContent="":g.nodeType===9&&g.documentElement&&g.removeChild(g.documentElement);break;case 5:case 6:case 4:case 17:break;default:throw Error(N(163))}}catch(_){ee(t,t.return,_)}if(e=t.sibling,e!==null){e.return=t.return,T=e;break}T=t.return}return v=lu,lu=!1,v}function Ir(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&&$o(t,n,i)}s=s.next}while(s!==r)}}function Ki(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 Uo(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 Yh(e){var t=e.alternate;t!==null&&(e.alternate=null,Yh(t)),e.child=null,e.deletions=null,e.sibling=null,e.tag===5&&(t=e.stateNode,t!==null&&(delete t[at],delete t[Jr],delete t[So],delete t[Km],delete t[Ym])),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 Jh(e){return e.tag===5||e.tag===3||e.tag===4}function cu(e){e:for(;;){for(;e.sibling===null;){if(e.return===null||Jh(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 zo(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=yi));else if(r!==4&&(e=e.child,e!==null))for(zo(e,t,n),e=e.sibling;e!==null;)zo(e,t,n),e=e.sibling}function Mo(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(Mo(e,t,n),e=e.sibling;e!==null;)Mo(e,t,n),e=e.sibling}var fe=null,Je=!1;function St(e,t,n){for(n=n.child;n!==null;)Qh(e,t,n),n=n.sibling}function Qh(e,t,n){if(ot&&typeof ot.onCommitFiberUnmount=="function")try{ot.onCommitFiberUnmount(zi,n)}catch{}switch(n.tag){case 5:ve||Bn(n,t);case 6:var r=fe,s=Je;fe=null,St(e,t,n),fe=r,Je=s,fe!==null&&(Je?(e=fe,n=n.stateNode,e.nodeType===8?e.parentNode.removeChild(n):e.removeChild(n)):fe.removeChild(n.stateNode));break;case 18:fe!==null&&(Je?(e=fe,n=n.stateNode,e.nodeType===8?Ca(e.parentNode,n):e.nodeType===1&&Ca(e,n),Vr(e)):Ca(fe,n.stateNode));break;case 4:r=fe,s=Je,fe=n.stateNode.containerInfo,Je=!0,St(e,t,n),fe=r,Je=s;break;case 0:case 11:case 14:case 15:if(!ve&&(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)&&$o(n,t,o),s=s.next}while(s!==r)}St(e,t,n);break;case 1:if(!ve&&(Bn(n,t),r=n.stateNode,typeof r.componentWillUnmount=="function"))try{r.props=n.memoizedProps,r.state=n.memoizedState,r.componentWillUnmount()}catch(l){ee(n,t,l)}St(e,t,n);break;case 21:St(e,t,n);break;case 22:n.mode&1?(ve=(r=ve)||n.memoizedState!==null,St(e,t,n),ve=r):St(e,t,n);break;default:St(e,t,n)}}function uu(e){var t=e.updateQueue;if(t!==null){e.updateQueue=null;var n=e.stateNode;n===null&&(n=e.stateNode=new dg),t.forEach(function(r){var s=bg.bind(null,e,r);n.has(r)||(n.add(r),r.then(s,s))})}}function qe(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,l=o;e:for(;l!==null;){switch(l.tag){case 5:fe=l.stateNode,Je=!1;break e;case 3:fe=l.stateNode.containerInfo,Je=!0;break e;case 4:fe=l.stateNode.containerInfo,Je=!0;break e}l=l.return}if(fe===null)throw Error(N(160));Qh(i,o,s),fe=null,Je=!1;var c=s.alternate;c!==null&&(c.return=null),s.return=null}catch(u){ee(s,t,u)}}if(t.subtreeFlags&12854)for(t=t.child;t!==null;)Xh(t,e),t=t.sibling}function Xh(e,t){var n=e.alternate,r=e.flags;switch(e.tag){case 0:case 11:case 14:case 15:if(qe(t,e),st(e),r&4){try{Ir(3,e,e.return),Ki(3,e)}catch(w){ee(e,e.return,w)}try{Ir(5,e,e.return)}catch(w){ee(e,e.return,w)}}break;case 1:qe(t,e),st(e),r&512&&n!==null&&Bn(n,n.return);break;case 5:if(qe(t,e),st(e),r&512&&n!==null&&Bn(n,n.return),e.flags&32){var s=e.stateNode;try{Mr(s,"")}catch(w){ee(e,e.return,w)}}if(r&4&&(s=e.stateNode,s!=null)){var i=e.memoizedProps,o=n!==null?n.memoizedProps:i,l=e.type,c=e.updateQueue;if(e.updateQueue=null,c!==null)try{l==="input"&&i.type==="radio"&&i.name!=null&&xd(s,i),uo(l,o);var u=uo(l,i);for(o=0;o<c.length;o+=2){var d=c[o],f=c[o+1];d==="style"?Sd(s,f):d==="dangerouslySetInnerHTML"?kd(s,f):d==="children"?Mr(s,f):hl(s,d,f,u)}switch(l){case"input":io(s,i);break;case"textarea":bd(s,i);break;case"select":var h=s._wrapperState.wasMultiple;s._wrapperState.wasMultiple=!!i.multiple;var m=i.value;m!=null?Vn(s,!!i.multiple,m,!1):h!==!!i.multiple&&(i.defaultValue!=null?Vn(s,!!i.multiple,i.defaultValue,!0):Vn(s,!!i.multiple,i.multiple?[]:"",!1))}s[Jr]=i}catch(w){ee(e,e.return,w)}}break;case 6:if(qe(t,e),st(e),r&4){if(e.stateNode===null)throw Error(N(162));s=e.stateNode,i=e.memoizedProps;try{s.nodeValue=i}catch(w){ee(e,e.return,w)}}break;case 3:if(qe(t,e),st(e),r&4&&n!==null&&n.memoizedState.isDehydrated)try{Vr(t.containerInfo)}catch(w){ee(e,e.return,w)}break;case 4:qe(t,e),st(e);break;case 13:qe(t,e),st(e),s=e.child,s.flags&8192&&(i=s.memoizedState!==null,s.stateNode.isHidden=i,!i||s.alternate!==null&&s.alternate.memoizedState!==null||(Vl=ne())),r&4&&uu(e);break;case 22:if(d=n!==null&&n.memoizedState!==null,e.mode&1?(ve=(u=ve)||d,qe(t,e),ve=u):qe(t,e),st(e),r&8192){if(u=e.memoizedState!==null,(e.stateNode.isHidden=u)&&!d&&e.mode&1)for(T=e,d=e.child;d!==null;){for(f=T=d;T!==null;){switch(h=T,m=h.child,h.tag){case 0:case 11:case 14:case 15:Ir(4,h,h.return);break;case 1:Bn(h,h.return);var v=h.stateNode;if(typeof v.componentWillUnmount=="function"){r=h,n=h.return;try{t=r,v.props=t.memoizedProps,v.state=t.memoizedState,v.componentWillUnmount()}catch(w){ee(r,n,w)}}break;case 5:Bn(h,h.return);break;case 22:if(h.memoizedState!==null){hu(f);continue}}m!==null?(m.return=h,T=m):hu(f)}d=d.sibling}e:for(d=null,f=e;;){if(f.tag===5){if(d===null){d=f;try{s=f.stateNode,u?(i=s.style,typeof i.setProperty=="function"?i.setProperty("display","none","important"):i.display="none"):(l=f.stateNode,c=f.memoizedProps.style,o=c!=null&&c.hasOwnProperty("display")?c.display:null,l.style.display=jd("display",o))}catch(w){ee(e,e.return,w)}}}else if(f.tag===6){if(d===null)try{f.stateNode.nodeValue=u?"":f.memoizedProps}catch(w){ee(e,e.return,w)}}else if((f.tag!==22&&f.tag!==23||f.memoizedState===null||f===e)&&f.child!==null){f.child.return=f,f=f.child;continue}if(f===e)break e;for(;f.sibling===null;){if(f.return===null||f.return===e)break e;d===f&&(d=null),f=f.return}d===f&&(d=null),f.sibling.return=f.return,f=f.sibling}}break;case 19:qe(t,e),st(e),r&4&&uu(e);break;case 21:break;default:qe(t,e),st(e)}}function st(e){var t=e.flags;if(t&2){try{e:{for(var n=e.return;n!==null;){if(Jh(n)){var r=n;break e}n=n.return}throw Error(N(160))}switch(r.tag){case 5:var s=r.stateNode;r.flags&32&&(Mr(s,""),r.flags&=-33);var i=cu(e);Mo(e,i,s);break;case 3:case 4:var o=r.stateNode.containerInfo,l=cu(e);zo(e,l,o);break;default:throw Error(N(161))}}catch(c){ee(e,e.return,c)}e.flags&=-3}t&4096&&(e.flags&=-4097)}function fg(e,t,n){T=e,Zh(e)}function Zh(e,t,n){for(var r=(e.mode&1)!==0;T!==null;){var s=T,i=s.child;if(s.tag===22&&r){var o=s.memoizedState!==null||$s;if(!o){var l=s.alternate,c=l!==null&&l.memoizedState!==null||ve;l=$s;var u=ve;if($s=o,(ve=c)&&!u)for(T=s;T!==null;)o=T,c=o.child,o.tag===22&&o.memoizedState!==null?fu(s):c!==null?(c.return=o,T=c):fu(s);for(;i!==null;)T=i,Zh(i),i=i.sibling;T=s,$s=l,ve=u}du(e)}else s.subtreeFlags&8772&&i!==null?(i.return=s,T=i):du(e)}}function du(e){for(;T!==null;){var t=T;if(t.flags&8772){var n=t.alternate;try{if(t.flags&8772)switch(t.tag){case 0:case 11:case 15:ve||Ki(5,t);break;case 1:var r=t.stateNode;if(t.flags&4&&!ve)if(n===null)r.componentDidMount();else{var s=t.elementType===t.type?n.memoizedProps:Ke(t.type,n.memoizedProps);r.componentDidUpdate(s,n.memoizedState,r.__reactInternalSnapshotBeforeUpdate)}var i=t.updateQueue;i!==null&&Yc(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}Yc(t,o,n)}break;case 5:var l=t.stateNode;if(n===null&&t.flags&4){n=l;var c=t.memoizedProps;switch(t.type){case"button":case"input":case"select":case"textarea":c.autoFocus&&n.focus();break;case"img":c.src&&(n.src=c.src)}}break;case 6:break;case 4:break;case 12:break;case 13:if(t.memoizedState===null){var u=t.alternate;if(u!==null){var d=u.memoizedState;if(d!==null){var f=d.dehydrated;f!==null&&Vr(f)}}}break;case 19:case 17:case 21:case 22:case 23:case 25:break;default:throw Error(N(163))}ve||t.flags&512&&Uo(t)}catch(h){ee(t,t.return,h)}}if(t===e){T=null;break}if(n=t.sibling,n!==null){n.return=t.return,T=n;break}T=t.return}}function hu(e){for(;T!==null;){var t=T;if(t===e){T=null;break}var n=t.sibling;if(n!==null){n.return=t.return,T=n;break}T=t.return}}function fu(e){for(;T!==null;){var t=T;try{switch(t.tag){case 0:case 11:case 15:var n=t.return;try{Ki(4,t)}catch(c){ee(t,n,c)}break;case 1:var r=t.stateNode;if(typeof r.componentDidMount=="function"){var s=t.return;try{r.componentDidMount()}catch(c){ee(t,s,c)}}var i=t.return;try{Uo(t)}catch(c){ee(t,i,c)}break;case 5:var o=t.return;try{Uo(t)}catch(c){ee(t,o,c)}}}catch(c){ee(t,t.return,c)}if(t===e){T=null;break}var l=t.sibling;if(l!==null){l.return=t.return,T=l;break}T=t.return}}var pg=Math.ceil,Ci=kt.ReactCurrentDispatcher,Wl=kt.ReactCurrentOwner,Be=kt.ReactCurrentBatchConfig,U=0,ue=null,se=null,pe=0,Re=0,Wn=Vt(0),oe=0,ns=null,mn=0,Yi=0,Hl=0,Dr=null,Ne=null,Vl=0,sr=1/0,dt=null,Ti=!1,Bo=null,Ut=null,Us=!1,Ot=null,Ai=0,Fr=0,Wo=null,si=-1,ii=0;function ke(){return U&6?ne():si!==-1?si:si=ne()}function zt(e){return e.mode&1?U&2&&pe!==0?pe&-pe:Qm.transition!==null?(ii===0&&(ii=Ld()),ii):(e=z,e!==0||(e=window.event,e=e===void 0?16:Hd(e.type)),e):1}function et(e,t,n,r){if(50<Fr)throw Fr=0,Wo=null,Error(N(185));ps(e,n,r),(!(U&2)||e!==ue)&&(e===ue&&(!(U&2)&&(Yi|=n),oe===4&&At(e,pe)),Ae(e,r),n===1&&U===0&&!(t.mode&1)&&(sr=ne()+500,Vi&&qt()))}function Ae(e,t){var n=e.callbackNode;Qp(e,t);var r=fi(e,e===ue?pe:0);if(r===0)n!==null&&_c(n),e.callbackNode=null,e.callbackPriority=0;else if(t=r&-r,e.callbackPriority!==t){if(n!=null&&_c(n),t===1)e.tag===0?Jm(pu.bind(null,e)):ch(pu.bind(null,e)),qm(function(){!(U&6)&&qt()}),n=null;else{switch($d(r)){case 1:n=yl;break;case 4:n=Dd;break;case 16:n=hi;break;case 536870912:n=Fd;break;default:n=hi}n=lf(n,ef.bind(null,e))}e.callbackPriority=t,e.callbackNode=n}}function ef(e,t){if(si=-1,ii=0,U&6)throw Error(N(327));var n=e.callbackNode;if(Jn()&&e.callbackNode!==n)return null;var r=fi(e,e===ue?pe:0);if(r===0)return null;if(r&30||r&e.expiredLanes||t)t=Pi(e,r);else{t=r;var s=U;U|=2;var i=nf();(ue!==e||pe!==t)&&(dt=null,sr=ne()+500,un(e,t));do try{yg();break}catch(l){tf(e,l)}while(!0);Al(),Ci.current=i,U=s,se!==null?t=0:(ue=null,pe=0,t=oe)}if(t!==0){if(t===2&&(s=go(e),s!==0&&(r=s,t=Ho(e,s))),t===1)throw n=ns,un(e,0),At(e,r),Ae(e,ne()),n;if(t===6)At(e,r);else{if(s=e.current.alternate,!(r&30)&&!mg(s)&&(t=Pi(e,r),t===2&&(i=go(e),i!==0&&(r=i,t=Ho(e,i))),t===1))throw n=ns,un(e,0),At(e,r),Ae(e,ne()),n;switch(e.finishedWork=s,e.finishedLanes=r,t){case 0:case 1:throw Error(N(345));case 2:tn(e,Ne,dt);break;case 3:if(At(e,r),(r&130023424)===r&&(t=Vl+500-ne(),10<t)){if(fi(e,0)!==0)break;if(s=e.suspendedLanes,(s&r)!==r){ke(),e.pingedLanes|=e.suspendedLanes&s;break}e.timeoutHandle=jo(tn.bind(null,e,Ne,dt),t);break}
vendor: 2,622 bytes, line 40
40tn(e,Ne,dt);break;case 4:if(At(e,r),(r&4194240)===r)break;for(t=e.eventTimes,s=-1;0<r;){var o=31-Ze(r);i=1<<o,o=t[o],o>s&&(s=o),r&=~i}if(r=s,r=ne()-r,r=(120>r?120:480>r?480:1080>r?1080:1920>r?1920:3e3>r?3e3:4320>r?4320:1960*pg(r/1960))-r,10<r){e.timeoutHandle=jo(tn.bind(null,e,Ne,dt),r);break}tn(e,Ne,dt);break;case 5:tn(e,Ne,dt);break;default:throw Error(N(329))}}}return Ae(e,ne()),e.callbackNode===n?ef.bind(null,e):null}function Ho(e,t){var n=Dr;return e.current.memoizedState.isDehydrated&&(un(e,t).flags|=256),e=Pi(e,t),e!==2&&(t=Ne,Ne=n,t!==null&&Vo(t)),e}function Vo(e){Ne===null?Ne=e:Ne.push.apply(Ne,e)}function mg(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(!tt(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 At(e,t){for(t&=~Hl,t&=~Yi,e.suspendedLanes|=t,e.pingedLanes&=~t,e=e.expirationTimes;0<t;){var n=31-Ze(t),r=1<<n;e[n]=-1,t&=~r}}function pu(e){if(U&6)throw Error(N(327));Jn();var t=fi(e,0);if(!(t&1))return Ae(e,ne()),null;var n=Pi(e,t);if(e.tag!==0&&n===2){var r=go(e);r!==0&&(t=r,n=Ho(e,r))}if(n===1)throw n=ns,un(e,0),At(e,t),Ae(e,ne()),n;if(n===6)throw Error(N(345));return e.finishedWork=e.current.alternate,e.finishedLanes=t,tn(e,Ne,dt),Ae(e,ne()),null}function ql(e,t){var n=U;U|=1;try{return e(t)}finally{U=n,U===0&&(sr=ne()+500,Vi&&qt())}}function gn(e){Ot!==null&&Ot.tag===0&&!(U&6)&&Jn();var t=U;U|=1;var n=Be.transition,r=z;try{if(Be.transition=null,z=1,e)return e()}finally{z=r,Be.transition=n,U=t,!(U&6)&&qt()}}function Gl(){Re=Wn.current,V(Wn)}function un(e,t){e.finishedWork=null,e.finishedLanes=0;var n=e.timeoutHandle;if(n!==-1&&(e.timeoutHandle=-1,Vm(n)),se!==null)for(n=se.return;n!==null;){var r=n;switch(El(r),r.tag){case 1:r=r.type.childContextTypes,r!=null&&vi();break;case 3:nr(),V(Ce),V(we),Fl();break;case 5:Dl(r);break;case 4:nr();break;case 13:V(Y);break;case 19:V(Y);break;case 10:Pl(r.type._context);break;case 22:case 23:Gl()}n=n.return}if(ue=e,se=e=Mt(e.current,null),pe=Re=t,oe=0,ns=null,Hl=Yi=mn=0,Ne=Dr=null,on!==null){for(t=0;t<on.length;t++)if(n=on[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}on=null}return e}function tf(e,t){do{var n=se;try{if(Al(),ti.current=Ei,Ni){for(var r=J.memoizedState;r!==null;){var s=r.queue;s!==null&&(s.pending=null),r=r.next}Ni=!1}
vendor: 10,398 bytes, line 40
40if(pn=0,ce=ae=J=null,Or=!1,Zr=0,Wl.current=null,n===null||n.return===null){oe=1,ns=t,se=null;break}e:{var i=e,o=n.return,l=n,c=t;if(t=pe,l.flags|=32768,c!==null&&typeof c=="object"&&typeof c.then=="function"){var u=c,d=l,f=d.tag;if(!(d.mode&1)&&(f===0||f===11||f===15)){var h=d.alternate;h?(d.updateQueue=h.updateQueue,d.memoizedState=h.memoizedState,d.lanes=h.lanes):(d.updateQueue=null,d.memoizedState=null)}var m=tu(o);if(m!==null){m.flags&=-257,nu(m,o,l,i,t),m.mode&1&&eu(i,u,t),t=m,c=u;var v=t.updateQueue;if(v===null){var w=new Set;w.add(c),t.updateQueue=w}else v.add(c);break e}else{if(!(t&1)){eu(i,u,t),Kl();break e}c=Error(N(426))}}else if(G&&l.mode&1){var b=tu(o);if(b!==null){!(b.flags&65536)&&(b.flags|=256),nu(b,o,l,i,t),Cl(rr(c,l));break e}}i=c=rr(c,l),oe!==4&&(oe=2),Dr===null?Dr=[i]:Dr.push(i),i=o;do{switch(i.tag){case 3:i.flags|=65536,t&=-t,i.lanes|=t;var y=$h(i,c,t);Kc(i,y);break e;case 1:l=c;var p=i.type,g=i.stateNode;if(!(i.flags&128)&&(typeof p.getDerivedStateFromError=="function"||g!==null&&typeof g.componentDidCatch=="function"&&(Ut===null||!Ut.has(g)))){i.flags|=65536,t&=-t,i.lanes|=t;var _=Uh(i,l,t);Kc(i,_);break e}}i=i.return}while(i!==null)}sf(n)}catch(j){t=j,se===n&&n!==null&&(se=n=n.return);continue}break}while(!0)}function nf(){var e=Ci.current;return Ci.current=Ei,e===null?Ei:e}function Kl(){(oe===0||oe===3||oe===2)&&(oe=4),ue===null||!(mn&268435455)&&!(Yi&268435455)||At(ue,pe)}function Pi(e,t){var n=U;U|=2;var r=nf();(ue!==e||pe!==t)&&(dt=null,un(e,t));do try{gg();break}catch(s){tf(e,s)}while(!0);if(Al(),U=n,Ci.current=r,se!==null)throw Error(N(261));return ue=null,pe=0,oe}function gg(){for(;se!==null;)rf(se)}function yg(){for(;se!==null&&!Bp();)rf(se)}function rf(e){var t=of(e.alternate,e,Re);e.memoizedProps=e.pendingProps,t===null?sf(e):se=t,Wl.current=null}function sf(e){var t=e;do{var n=t.alternate;if(e=t.return,t.flags&32768){if(n=ug(n,t),n!==null){n.flags&=32767,se=n;return}if(e!==null)e.flags|=32768,e.subtreeFlags=0,e.deletions=null;else{oe=6,se=null;return}}else if(n=cg(n,t,Re),n!==null){se=n;return}if(t=t.sibling,t!==null){se=t;return}se=t=e}while(t!==null);oe===0&&(oe=5)}function tn(e,t,n){var r=z,s=Be.transition;try{Be.transition=null,z=1,vg(e,t,n,r)}finally{Be.transition=s,z=r}return null}function vg(e,t,n,r){do Jn();while(Ot!==null);if(U&6)throw Error(N(327));n=e.finishedWork;var s=e.finishedLanes;if(n===null)return null;if(e.finishedWork=null,e.finishedLanes=0,n===e.current)throw Error(N(177));e.callbackNode=null,e.callbackPriority=0;var i=n.lanes|n.childLanes;if(Xp(e,i),e===ue&&(se=ue=null,pe=0),!(n.subtreeFlags&2064)&&!(n.flags&2064)||Us||(Us=!0,lf(hi,function(){return Jn(),null})),i=(n.flags&15990)!==0,n.subtreeFlags&15990||i){i=Be.transition,Be.transition=null;var o=z;z=1;var l=U;U|=4,Wl.current=null,hg(e,n),Xh(n,e),$m(_o),pi=!!bo,_o=bo=null,e.current=n,fg(n),Wp(),U=l,z=o,Be.transition=i}else e.current=n;if(Us&&(Us=!1,Ot=e,Ai=s),i=e.pendingLanes,i===0&&(Ut=null),qp(n.stateNode),Ae(e,ne()),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(Ti)throw Ti=!1,e=Bo,Bo=null,e;return Ai&1&&e.tag!==0&&Jn(),i=e.pendingLanes,i&1?e===Wo?Fr++:(Fr=0,Wo=e):Fr=0,qt(),null}function Jn(){if(Ot!==null){var e=$d(Ai),t=Be.transition,n=z;try{if(Be.transition=null,z=16>e?16:e,Ot===null)var r=!1;else{if(e=Ot,Ot=null,Ai=0,U&6)throw Error(N(331));var s=U;for(U|=4,T=e.current;T!==null;){var i=T,o=i.child;if(T.flags&16){var l=i.deletions;if(l!==null){for(var c=0;c<l.length;c++){var u=l[c];for(T=u;T!==null;){var d=T;switch(d.tag){case 0:case 11:case 15:Ir(8,d,i)}var f=d.child;if(f!==null)f.return=d,T=f;else for(;T!==null;){d=T;var h=d.sibling,m=d.return;if(Yh(d),d===u){T=null;break}if(h!==null){h.return=m,T=h;break}T=m}}}var v=i.alternate;if(v!==null){var w=v.child;if(w!==null){v.child=null;do{var b=w.sibling;w.sibling=null,w=b}while(w!==null)}}T=i}}if(i.subtreeFlags&2064&&o!==null)o.return=i,T=o;else e:for(;T!==null;){if(i=T,i.flags&2048)switch(i.tag){case 0:case 11:case 15:Ir(9,i,i.return)}var y=i.sibling;if(y!==null){y.return=i.return,T=y;break e}T=i.return}}var p=e.current;for(T=p;T!==null;){o=T;var g=o.child;if(o.subtreeFlags&2064&&g!==null)g.return=o,T=g;else e:for(o=p;T!==null;){if(l=T,l.flags&2048)try{switch(l.tag){case 0:case 11:case 15:Ki(9,l)}}catch(j){ee(l,l.return,j)}if(l===o){T=null;break e}var _=l.sibling;if(_!==null){_.return=l.return,T=_;break e}T=l.return}}if(U=s,qt(),ot&&typeof ot.onPostCommitFiberRoot=="function")try{ot.onPostCommitFiberRoot(zi,e)}catch{}r=!0}return r}finally{z=n,Be.transition=t}}return!1}function mu(e,t,n){t=rr(n,t),t=$h(e,t,1),e=$t(e,t,1),t=ke(),e!==null&&(ps(e,1,t),Ae(e,t))}function ee(e,t,n){if(e.tag===3)mu(e,e,n);else for(;t!==null;){if(t.tag===3){mu(t,e,n);break}else if(t.tag===1){var r=t.stateNode;if(typeof t.type.getDerivedStateFromError=="function"||typeof r.componentDidCatch=="function"&&(Ut===null||!Ut.has(r))){e=rr(n,e),e=Uh(t,e,1),t=$t(t,e,1),e=ke(),t!==null&&(ps(t,1,e),Ae(t,e));break}}t=t.return}}function wg(e,t,n){var r=e.pingCache;r!==null&&r.delete(t),t=ke(),e.pingedLanes|=e.suspendedLanes&n,ue===e&&(pe&n)===n&&(oe===4||oe===3&&(pe&130023424)===pe&&500>ne()-Vl?un(e,0):Hl|=n),Ae(e,t)}function af(e,t){t===0&&(e.mode&1?(t=Ts,Ts<<=1,!(Ts&130023424)&&(Ts=4194304)):t=1);var n=ke();e=xt(e,t),e!==null&&(ps(e,t,n),Ae(e,n))}function xg(e){var t=e.memoizedState,n=0;t!==null&&(n=t.retryLane),af(e,n)}function bg(e,t){var n=0;switch(e.tag){case 13:var r=e.stateNode,s=e.memoizedState;s!==null&&(n=s.retryLane);break;case 19:r=e.stateNode;break;default:throw Error(N(314))}r!==null&&r.delete(t),af(e,n)}var of;of=function(e,t,n){if(e!==null)if(e.memoizedProps!==t.pendingProps||Ce.current)Ee=!0;else{if(!(e.lanes&n)&&!(t.flags&128))return Ee=!1,lg(e,t,n);Ee=!!(e.flags&131072)}else Ee=!1,G&&t.flags&1048576&&uh(t,bi,t.index);switch(t.lanes=0,t.tag){case 2:var r=t.type;ri(e,t),e=t.pendingProps;var s=Zn(t,we.current);Yn(t,n),s=$l(null,t,r,e,s,n);var i=Ul();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,Te(r)?(i=!0,wi(t)):i=!1,t.memoizedState=s.state!==null&&s.state!==void 0?s.state:null,Ol(t),s.updater=Gi,t.stateNode=s,s._reactInternals=t,Po(t,r,e,n),t=Io(null,t,r,!0,i,n)):(t.tag=0,G&&i&&Nl(t),be(null,t,s,n),t=t.child),t;case 16:r=t.elementType;e:{switch(ri(e,t),e=t.pendingProps,s=r._init,r=s(r._payload),t.type=r,s=t.tag=kg(r),e=Ke(r,e),s){case 0:t=Oo(null,t,r,e,n);break e;case 1:t=iu(null,t,r,e,n);break e;case 11:t=ru(null,t,r,e,n);break e;case 14:t=su(null,t,r,Ke(r.type,e),n);break e}throw Error(N(306,r,""))}return t;case 0:return r=t.type,s=t.pendingProps,s=t.elementType===r?s:Ke(r,s),Oo(e,t,r,s,n);case 1:return r=t.type,s=t.pendingProps,s=t.elementType===r?s:Ke(r,s),iu(e,t,r,s,n);case 3:e:{if(Wh(t),e===null)throw Error(N(387));r=t.pendingProps,i=t.memoizedState,s=i.element,gh(e,t),ji(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=rr(Error(N(423)),t),t=au(e,t,r,n,s);break e}else if(r!==s){s=rr(Error(N(424)),t),t=au(e,t,r,n,s);break e}else for(Ie=Lt(t.stateNode.containerInfo.firstChild),De=t,G=!0,Xe=null,n=ph(t,null,r,n),t.child=n;n;)n.flags=n.flags&-3|4096,n=n.sibling;else{if(er(),r===s){t=bt(e,t,n);break e}be(e,t,r,n)}t=t.child}return t;case 5:return yh(t),e===null&&Co(t),r=t.type,s=t.pendingProps,i=e!==null?e.memoizedProps:null,o=s.children,ko(r,s)?o=null:i!==null&&ko(r,i)&&(t.flags|=32),Bh(e,t),be(e,t,o,n),t.child;case 6:return e===null&&Co(t),null;case 13:return Hh(e,t,n);case 4:return Il(t,t.stateNode.containerInfo),r=t.pendingProps,e===null?t.child=tr(t,null,r,n):be(e,t,r,n),t.child;case 11:return r=t.type,s=t.pendingProps,s=t.elementType===r?s:Ke(r,s),ru(e,t,r,s,n);case 7:return be(e,t,t.pendingProps,n),t.child;case 8:return be(e,t,t.pendingProps.children,n),t.child;case 12:return be(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,W(_i,r._currentValue),r._currentValue=o,i!==null)if(tt(i.value,o)){if(i.children===s.children&&!Ce.current){t=bt(e,t,n);break e}}else for(i=t.child,i!==null&&(i.return=t);i!==null;){var l=i.dependencies;if(l!==null){o=i.child;for(var c=l.firstContext;c!==null;){if(c.context===r){if(i.tag===1){c=gt(-1,n&-n),c.tag=2;var u=i.updateQueue;if(u!==null){u=u.shared;var d=u.pending;d===null?c.next=c:(c.next=d.next,d.next=c),u.pending=c}}i.lanes|=n,c=i.alternate,c!==null&&(c.lanes|=n),To(i.return,n,t),l.lanes|=n;break}c=c.next}}else if(i.tag===10)o=i.type===t.type?null:i.child;else if(i.tag===18){if(o=i.return,o===null)throw Error(N(341));o.lanes|=n,l=o.alternate,l!==null&&(l.lanes|=n),To(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}be(e,t,s.children,n),t=t.child}return t;case 9:return s=t.type,r=t.pendingProps.children,Yn(t,n),s=We(s),r=r(s),t.flags|=1,be(e,t,r,n),t.child;case 14:return r=t.type,s=Ke(r,t.pendingProps),s=Ke(r.type,s),su(e,t,r,s,n);case 15:return zh(e,t,t.type,t.pendingProps,n);case 17:return r=t.type,s=t.pendingProps,s=t.elementType===r?s:Ke(r,s),ri(e,t),t.tag=1,Te(r)?(e=!0,wi(t)):e=!1,Yn(t,n),Lh(t,r,s),Po(t,r,s,n),Io(null,t,r,!0,e,n);case 19:return Vh(e,t,n);case 22:return Mh(e,t,n)}throw Error(N(156,t.tag))};function lf(e,t){return Id(e,t)}function _g(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 Me(e,t,n,r){return new _g(e,t,n,r)}function Yl(e){return e=e.prototype,!(!e||!e.isReactComponent)}function kg(e){if(typeof e=="function")return Yl(e)?1:0;if(e!=null){if(e=e.$$typeof,e===pl)return 11;if(e===ml)return 14}return 2}function Mt(e,t){var n=e.alternate;return n===null?(n=Me(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.deleti
vendor: 8,421 bytes, line 40
40ons=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 ai(e,t,n,r,s,i){var o=2;if(r=e,typeof e=="function")Yl(e)&&(o=1);else if(typeof e=="string")o=5;else e:switch(e){case On:return dn(n.children,s,i,t);case fl:o=8,s|=8;break;case eo:return e=Me(12,n,t,s|2),e.elementType=eo,e.lanes=i,e;case to:return e=Me(13,n,t,s),e.elementType=to,e.lanes=i,e;case no:return e=Me(19,n,t,s),e.elementType=no,e.lanes=i,e;case yd:return Ji(n,s,i,t);default:if(typeof e=="object"&&e!==null)switch(e.$$typeof){case md:o=10;break e;case gd:o=9;break e;case pl:o=11;break e;case ml:o=14;break e;case Nt:o=16,r=null;break e}throw Error(N(130,e==null?e:typeof e,""))}return t=Me(o,n,t,s),t.elementType=e,t.type=r,t.lanes=i,t}function dn(e,t,n,r){return e=Me(7,e,r,t),e.lanes=n,e}function Ji(e,t,n,r){return e=Me(22,e,r,t),e.elementType=yd,e.lanes=n,e.stateNode={isHidden:!1},e}function Fa(e,t,n){return e=Me(6,e,null,t),e.lanes=n,e}function La(e,t,n){return t=Me(4,e.children!==null?e.children:[],e.key,t),t.lanes=n,t.stateNode={containerInfo:e.containerInfo,pendingChildren:null,implementation:e.implementation},t}function jg(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=ya(0),this.expirationTimes=ya(-1),this.entangledLanes=this.finishedLanes=this.mutableReadLanes=this.expiredLanes=this.pingedLanes=this.suspendedLanes=this.pendingLanes=0,this.entanglements=ya(0),this.identifierPrefix=r,this.onRecoverableError=s,this.mutableSourceEagerHydrationData=null}function Jl(e,t,n,r,s,i,o,l,c){return e=new jg(e,t,n,l,c),t===1?(t=1,i===!0&&(t|=8)):t=0,i=Me(3,null,null,t),e.current=i,i.stateNode=e,i.memoizedState={element:r,isDehydrated:n,cache:null,transitions:null,pendingSuspenseBoundaries:null},Ol(i),e}function Sg(e,t,n){var r=3<arguments.length&&arguments[3]!==void 0?arguments[3]:null;return{$$typeof:Rn,key:r==null?null:""+r,children:e,containerInfo:t,implementation:n}}function cf(e){if(!e)return Wt;e=e._reactInternals;e:{if(vn(e)!==e||e.tag!==1)throw Error(N(170));var t=e;do{switch(t.tag){case 3:t=t.stateNode.context;break e;case 1:if(Te(t.type)){t=t.stateNode.__reactInternalMemoizedMergedChildContext;break e}}t=t.return}while(t!==null);throw Error(N(171))}if(e.tag===1){var n=e.type;if(Te(n))return lh(e,n,t)}return t}function uf(e,t,n,r,s,i,o,l,c){return e=Jl(n,r,!0,e,s,i,o,l,c),e.context=cf(null),n=e.current,r=ke(),s=zt(n),i=gt(r,s),i.callback=t??null,$t(n,i,s),e.current.lanes=s,ps(e,s,r),Ae(e,r),e}function Qi(e,t,n,r){var s=t.current,i=ke(),o=zt(s);return n=cf(n),t.context===null?t.context=n:t.pendingContext=n,t=gt(i,o),t.payload={element:e},r=r===void 0?null:r,r!==null&&(t.callback=r),e=$t(s,t,o),e!==null&&(et(e,s,o,i),ei(e,s,o)),o}function Ri(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 gu(e,t){if(e=e.memoizedState,e!==null&&e.dehydrated!==null){var n=e.retryLane;e.retryLane=n!==0&&n<t?n:t}}function Ql(e,t){gu(e,t),(e=e.alternate)&&gu(e,t)}function Ng(){return null}var df=typeof reportError=="function"?reportError:function(e){console.error(e)};function Xl(e){this._internalRoot=e}Xi.prototype.render=Xl.prototype.render=function(e){var t=this._internalRoot;if(t===null)throw Error(N(409));Qi(e,t,null,null)};Xi.prototype.unmount=Xl.prototype.unmount=function(){var e=this._internalRoot;if(e!==null){this._internalRoot=null;var t=e.containerInfo;gn(function(){Qi(null,e,null,null)}),t[wt]=null}};function Xi(e){this._internalRoot=e}Xi.prototype.unstable_scheduleHydration=function(e){if(e){var t=Md();e={blockedOn:null,target:e,priority:t};for(var n=0;n<Tt.length&&t!==0&&t<Tt[n].priority;n++);Tt.splice(n,0,e),n===0&&Wd(e)}};function Zl(e){return!(!e||e.nodeType!==1&&e.nodeType!==9&&e.nodeType!==11)}function Zi(e){return!(!e||e.nodeType!==1&&e.nodeType!==9&&e.nodeType!==11&&(e.nodeType!==8||e.nodeValue!==" react-mount-point-unstable "))}function yu(){}function Eg(e,t,n,r,s){if(s){if(typeof r=="function"){var i=r;r=function(){var u=Ri(o);i.call(u)}}var o=uf(t,r,e,0,null,!1,!1,"",yu);return e._reactRootContainer=o,e[wt]=o.current,Kr(e.nodeType===8?e.parentNode:e),gn(),o}for(;s=e.lastChild;)e.removeChild(s);if(typeof r=="function"){var l=r;r=function(){var u=Ri(c);l.call(u)}}var c=Jl(e,0,!1,null,null,!1,!1,"",yu);return e._reactRootContainer=c,e[wt]=c.current,Kr(e.nodeType===8?e.parentNode:e),gn(function(){Qi(t,c,n,r)}),c}function ea(e,t,n,r,s){var i=n._reactRootContainer;if(i){var o=i;if(typeof s=="function"){var l=s;s=function(){var c=Ri(o);l.call(c)}}Qi(t,o,e,s)}else o=Eg(n,t,e,s,r);return Ri(o)}Ud=function(e){switch(e.tag){case 3:var t=e.stateNode;if(t.current.memoizedState.isDehydrated){var n=Sr(t.pendingLanes);n!==0&&(vl(t,n|1),Ae(t,ne()),!(U&6)&&(sr=ne()+500,qt()))}break;case 13:gn(function(){var r=xt(e,1);if(r!==null){var s=ke();et(r,e,1,s)}}),Ql(e,1)}};wl=function(e){if(e.tag===13){var t=xt(e,134217728);if(t!==null){var n=ke();et(t,e,134217728,n)}Ql(e,134217728)}};zd=function(e){if(e.tag===13){var t=zt(e),n=xt(e,t);if(n!==null){var r=ke();et(n,e,t,r)}Ql(e,t)}};Md=function(){return z};Bd=function(e,t){var n=z;try{return z=e,t()}finally{z=n}};fo=function(e,t,n){switch(t){case"input":if(io(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=Hi(r);if(!s)throw Error(N(90));wd(r),io(r,s)}}}break;case"textarea":bd(e,n);break;case"select":t=n.value,t!=null&&Vn(e,!!n.multiple,t,!1)}};Cd=ql;Td=gn;var Cg={usingClientEntryPoint:!1,Events:[gs,Ln,Hi,Nd,Ed,ql]},xr={findFiberByHostInstance:an,bundleType:0,version:"18.3.1",rendererPackageName:"react-dom"},Tg={bundleType:xr.bundleType,version:xr.version,rendererPackageName:xr.rendererPackageName,rendererConfig:xr.rendererConfig,overrideHookState:null,overrideHookStateDeletePath:null,overrideHookStateRenamePath:null,overrideProps:null,overridePropsDeletePath:null,overridePropsRenamePath:null,setErrorHandler:null,setSuspenseHandler:null,scheduleUpdate:null,currentDispatcherRef:kt.ReactCurrentDispatcher,findHostInstanceByFiber:function(e){return e=Rd(e),e===null?null:e.stateNode},findFiberByHostInstance:xr.findFiberByHostInstance||Ng,findHostInstancesForRefresh:null,scheduleRefresh:null,scheduleRoot:null,setRefreshHandler:null,getCurrentFiber:null,reconcilerVersion:"18.3.1-next-f1338f8080-20240426"};if(typeof __REACT_DEVTOOLS_GLOBAL_HOOK__<"u"){var zs=__REACT_DEVTOOLS_GLOBAL_HOOK__;if(!zs.isDisabled&&zs.supportsFiber)try{zi=zs.inject(Tg),ot=zs}catch{}}Le.__SECRET_INTERNALS_DO_NOT_USE_OR_YOU_WILL_BE_FIRED=Cg;Le.createPortal=function(e,t){var n=2<arguments.length&&arguments[2]!==void 0?arguments[2]:null;if(!Zl(t))throw Error(N(200));return Sg(e,t,null,n)};Le.createRoot=function(e,t){if(!Zl(e))throw Error(N(299));var n=!1,r="",s=df;return t!=null&&(t.unstable_strictMode===!0&&(n=!0),t.identifierPrefix!==void 0&&(r=t.identifierPrefix),t.onRecoverableError!==void 0&&(s=t.onRecoverableError)),t=Jl(e,1,!1,null,null,n,!1,r,s),e[wt]=t.current,Kr(e.nodeType===8?e.parentNode:e),new Xl(t)};Le.findDOMNode=function(e){if(e==null)return null;if(e.nodeType===1)return e;var t=e._reactInternals;if(t===void 0)throw typeof e.render=="function"?Error(N(188)):(e=Object.keys(e).join(","),Error(N(268,e)));return e=Rd(t),e=e===null?null:e.stateNode,e};Le.flushSync=function(e){return gn(e)};Le.hydrate=function(e,t,n){if(!Zi(t))throw Error(N(200));return ea(null,e,t,!0,n)};Le.hydrateRoot=function(e,t,n){if(!Zl(e))throw Error(N(405));var r=n!=null&&n.hydratedSources||null,s=!1,i="",o=df;if(n!=null&&(n.unstable_strictMode===!0&&(s=!0),n.identifierPrefix!==void 0&&(i=n.identifierPrefix),n.onRecoverableError!==void 0&&(o=n.onRecoverableError)),t=uf(t,null,e,1,n??null,s,!1,i,o),e[wt]=t.current,Kr(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 Xi(t)};
40Le.render=function(e,t,n){if(!Zi(t))throw Error(N(200));return ea(null,e,t,!1,n)};Le.unmountComponentAtNode=function(e){if(!Zi(e))throw Error(N(40));return e._reactRootContainer?(gn(function(){ea(null,null,e,!1,function(){e._reactRootContainer=null,e[wt]=null})}),!0):!1};Le.unstable_batchedUpdates=ql;Le.unstable_renderSubtreeIntoContainer=function(e,t,n,r){if(!Zi(n))throw Error(N(200));if(e==null||e._reactInternals===void 0)throw Error(N(38));return ea(e,t,n,!1,r)};Le.version="18.3.1-next-f1338f8080-20240426";function hf(){if(!(typeof __REACT_DEVTOOLS_GLOBAL_HOOK__>"u"||typeof __REACT_DEVTOOLS_GLOBAL_HOOK__.checkDCE!="function"))try{__REACT_DEVTOOLS_GLOBAL_HOOK__.checkDCE(hf)}catch(e){console.error(e)}}hf(),dd.exports=Le;var ff=dd.exports,pf,vu=ff;pf=vu.createRoot,vu.hydrateRoot;/**
41 * react-router v7.13.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 */var wu="popstate";function Ag(e={}){function t(r,s){let{pathname:i,search:o,hash:l}=r.location;return qo("",{pathname:i,search:o,hash:l},s.state&&s.state.usr||null,s.state&&s.state.key||"default")}function n(r,s){return typeof s=="string"?s:rs(s)}return Rg(t,n,null,e)}function Q(e,t){if(e===!1||e===null||typeof e>"u")throw new Error(t)}function nt(e,t){if(!e){typeof console<"u"&&console.warn(t);try{throw new Error(t)}catch{}}}function Pg(){return Math.random().toString(36).substring(2,10)}function xu(e,t){return{usr:e.state,key:e.key,idx:t}}function qo(e,t,n=null,r){return{pathname:typeof e=="string"?e:e.pathname,search:"",hash:"",...typeof t=="string"?cr(t):t,state:n,key:t&&t.key||r||Pg()}}function rs({pathname:e="/",search:t="",hash:n=""}){return t&&t!=="?"&&(e+=t.charAt(0)==="?"?t:"?"+t),n&&n!=="#"&&(e+=n.charAt(0)==="#"?n:"#"+n),e}function cr(e){let t={};if(e){let n=e.indexOf("#");n>=0&&(t.hash=e.substring(n),e=e.substring(0,n));let r=e.indexOf("?");r>=0&&(t.search=e.substring(r),e=e.substring(0,r)),e&&(t.pathname=e)}return t}function Rg(e,t,n,r={}){let{window:s=document.defaultView,v5Compat:i=!1}=r,o=s.history,l="POP",c=null,u=d();u==null&&(u=0,o.replaceState({...o.state,idx:u},""));function d(){return(o.state||{idx:null}).idx}function f(){l="POP";let b=d(),y=b==null?null:b-u;u=b,c&&c({action:l,location:w.location,delta:y})}function h(b,y){l="PUSH";let p=qo(w.location,b,y);u=d()+1;let g=xu(p,u),_=w.createHref(p);try{o.pushState(g,"",_)}catch(j){if(j instanceof DOMException&&j.name==="DataCloneError")throw j;s.location.assign(_)}i&&c&&c({action:l,location:w.location,delta:1})}function m(b,y){l="REPLACE";let p=qo(w.location,b,y);u=d();let g=xu(p,u),_=w.createHref(p);o.replaceState(g,"",_),i&&c&&c({action:l,location:w.location,delta:0})}function v(b){return Og(b)}let w={get action(){return l},get location(){return e(s,o)},listen(b){if(c)throw new Error("A history only accepts one active listener");return s.addEventListener(wu,f),c=b,()=>{s.removeEventListener(wu,f),c=null}},createHref(b){return t(s,b)},createURL:v,encodeLocation(b){let y=v(b);return{pathname:y.pathname,search:y.search,hash:y.hash}},push:h,replace:m,go(b){return o.go(b)}};return w}function Og(e,t=!1){let n="http://localhost";
49typeof window<"u"&&(n=window.location.origin!=="null"?window.location.origin:window.location.href),Q(n,"No window.location.(origin|href) available to create URL");let r=typeof e=="string"?e:rs(e);return r=r.replace(/ $/,"%20"),!t&&r.startsWith("//")&&(r=n+r),new URL(r,n)}function mf(e,t,n="/"){return Ig(e,t,n,!1)}function Ig(e,t,n,r){let s=typeof t=="string"?cr(t):t,i=_t(s.pathname||"/",n);if(i==null)return null;let o=gf(e);Dg(o);let l=null;for(let c=0;l==null&&c<o.length;++c){let u=qg(i);l=Hg(o[c],u,r)}return l}function gf(e,t=[],n=[],r="",s=!1){let i=(o,l,c=s,u)=>{let d={relativePath:u===void 0?o.path||"":u,caseSensitive:o.caseSensitive===!0,childrenIndex:l,route:o};if(d.relativePath.startsWith("/")){if(!d.relativePath.startsWith(r)&&c)return;Q(d.relativePath.startsWith(r),`Absolute route path "${d.relativePath}" nested under path "${r}" is not valid. An absolute child route path must start with the combined path of all its parent routes.`),d.relativePath=d.relativePath.slice(r.length)}let f=yt([r,d.relativePath]),h=n.concat(d);o.children&&o.children.length>0&&(Q(o.index!==!0,`Index routes must not have child routes. Please remove all child routes from route path "${f}".`),gf(o.children,t,h,f,c)),!(o.path==null&&!o.index)&&t.push({path:f,score:Bg(f,o.index),routesMeta:h})};return e.forEach((o,l)=>{var c;if(o.path===""||!((c=o.path)!=null&&c.includes("?")))i(o,l);else for(let u of yf(o.path))i(o,l,!0,u)}),t}function yf(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=yf(r.join("/")),l=[];return l.push(...o.map(c=>c===""?i:[i,c].join("/"))),s&&l.push(...o),l.map(c=>e.startsWith("/")&&c===""?"/":c)}function Dg(e){e.sort((t,n)=>t.score!==n.score?n.score-t.score:Wg(t.routesMeta.map(r=>r.childrenIndex),n.routesMeta.map(r=>r.childrenIndex)))}var Fg=/^:[\w-]+$/,Lg=3,$g=2,Ug=1,zg=10,Mg=-2,bu=e=>e==="*";function Bg(e,t){let n=e.split("/"),r=n.length;return n.some(bu)&&(r+=Mg),t&&(r+=$g),n.filter(s=>!bu(s)).reduce((s,i)=>s+(Fg.test(i)?Lg:i===""?Ug:zg),r)}function Wg(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 Hg(e,t,n=!1){let{routesMeta:r}=e,s={},i="/",o=[];for(let l=0;l<r.length;++l){let c=r[l],u=l===r.length-1,d=i==="/"?t:t.slice(i.length)||"/",f=Oi({path:c.relativePath,caseSensitive:c.caseSensitive,end:u},d),h=c.route;if(!f&&u&&n&&!r[r.length-1].route.index&&(f=Oi({path:c.relativePath,caseSensitive:c.caseSensitive,end:!1},d)),!f)return null;
49Object.assign(s,f.params),o.push({params:s,pathname:yt([i,f.pathname]),pathnameBase:Jg(yt([i,f.pathnameBase])),route:h}),f.pathnameBase!=="/"&&(i=yt([i,f.pathnameBase]))}return o}function Oi(e,t){typeof e=="string"&&(e={path:e,caseSensitive:!1,end:!0});let[n,r]=Vg(e.path,e.caseSensitive,e.end),s=t.match(n);if(!s)return null;let i=s[0],o=i.replace(/(.)\/+$/,"$1"),l=s.slice(1);return{params:r.reduce((u,{paramName:d,isOptional:f},h)=>{if(d==="*"){let v=l[h]||"";o=i.slice(0,i.length-v.length).replace(/(.)\/+$/,"$1")}const m=l[h];return f&&!m?u[d]=void 0:u[d]=(m||"").replace(/%2F/g,"/"),u},{}),pathname:i,pathnameBase:o,pattern:e}}function Vg(e,t=!1,n=!0){nt(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,l,c)=>(r.push({paramName:l,isOptional:c!=null}),c?"/?([^\\/]+)?":"/([^\\/]+)")).replace(/\/([\w-]+)\?(\/|$)/g,"(/$1)?$2");return e.endsWith("*")?(r.push({paramName:"*"}),s+=e==="*"||e==="/*"?"(.*)$":"(?:\\/(.+)|\\/*)$"):n?s+="\\/*$":e!==""&&e!=="/"&&(s+="(?:(?=\\/|$))"),[new RegExp(s,t?void 0:"i"),r]}function qg(e){try{return e.split("/").map(t=>decodeURIComponent(t).replace(/\//g,"%2F")).join("/")}catch(t){return nt(!1,`The URL path "${e}" could not be decoded because it is a malformed URL segment. This is probably due to a bad percent encoding (${t}).`),e}}function _t(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)||"/"}var Gg=/^(?:[a-z][a-z0-9+.-]*:|\/\/)/i;function Kg(e,t="/"){let{pathname:n,search:r="",hash:s=""}=typeof e=="string"?cr(e):e,i;return n?(n=n.replace(/\/\/+/g,"/"),n.startsWith("/")?i=_u(n.substring(1),"/"):i=_u(n,t)):i=t,{pathname:i,search:Qg(r),hash:Xg(s)}}function _u(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 $a(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 Yg(e){return e.filter((t,n)=>n===0||t.route.path&&t.route.path.length>0)}function vf(e){let t=Yg(e);return t.map((n,r)=>r===t.length-1?n.pathname:n.pathnameBase)}function wf(e,t,n,r=!1){let s;typeof e=="string"?s=cr(e):(s={...e},Q(!s.pathname||!s.pathname.includes("?"),$a("?","pathname","search",s)),Q(!s.pathname||!s.pathname.includes("#"),$a("#","pathname","hash",s)),Q(!s.search||!s.search.includes("#"),$a("#","search","hash",s)));let i=e===""||s.pathname==="",o=i?"/":s.pathname,l;if(o==null)l=n;else{let f=t.length-1;if(!r&&o.startsWith("..")){let h=o.split("/");for(;h[0]==="..";)h.shift(),f-=1;s.pathname=h.join("/")}l=f>=0?t[f]:"/"}let c=Kg(s,l),u=o&&o!=="/"&&o.endsWith("/"),d=(i||o===".")&&n.endsWith("/");return!c.pathname.endsWith("/")&&(u||d)&&(c.pathname+="/"),c}var yt=e=>e.join("/").replace(/\/\/+/g,"/"),Jg=e=>e.replace(/\/+$/,"").replace(/^\/*/,"/"),Qg=e=>!e||e==="?"?"":e.startsWith("?")?e:"?"+e,Xg=e=>!e||e==="#"?"":e.startsWith("#")?e:"#"+e,Zg=class{constructor(e,t,n,r=!1){this.status=e,this.statusText=t||"",this.internal=r,n instanceof Error?(this.data=n.toString(),this.error=n):this.data=n}};function e0(e){return e!=null&&typeof e.status=="number"&&typeof e.statusText=="string"&&typeof e.internal=="boolean"&&"data"in e}function t0(e){return e.map(t=>t.route.path).filter(Boolean).join("/").replace(/\/\/*/g,"/")||"/"}var xf=typeof window<"u"&&typeof window.document<"u"&&typeof window.document.createElement<"u";function bf(e,t){let n=e;if(typeof n!="string"||!Gg.test(n))return{absoluteURL:void 0,isExternal:!1,to:n};let r=n,s=!1;if(xf)try{let i=new URL(window.location.href),o=n.startsWith("//")?new URL(i.protocol+n):new URL(n),l=_t(o.pathname,t);o.origin===i.origin&&l!=null?n=l+o.search+o.hash:s=!0}catch{nt(!1,`<Link to="${n}">
49 contains an invalid URL which will probably break when clicked - please update to a valid URL path.`)}return{absoluteURL:r,isExternal:s,to:n}}Object.getOwnPropertyNames(Object.prototype).sort().join("\0");var _f=["POST","PUT","PATCH","DELETE"];new Set(_f);var n0=["GET",..._f];new Set(n0);var ur=x.createContext(null);ur.displayName="DataRouter";var ta=x.createContext(null);ta.displayName="DataRouterState";var r0=x.createContext(!1),kf=x.createContext({isTransitioning:!1});kf.displayName="ViewTransition";var s0=x.createContext(new Map);s0.displayName="Fetchers";var i0=x.createContext(null);i0.displayName="Await";var Ve=x.createContext(null);Ve.displayName="Navigation";var vs=x.createContext(null);vs.displayName="Location";var ct=x.createContext({outlet:null,matches:[],isDataRoute:!1});ct.displayName="Route";var ec=x.createContext(null);ec.displayName="RouteError";var jf="REACT_ROUTER_ERROR",a0="REDIRECT",o0="ROUTE_ERROR_RESPONSE";function l0(e){if(e.startsWith(`${jf}:${a0}:{`))try{let t=JSON.parse(e.slice(28));if(typeof t=="object"&&t&&typeof t.status=="number"&&typeof t.statusText=="string"&&typeof t.location=="string"&&typeof t.reloadDocument=="boolean"&&typeof t.replace=="boolean")return t}catch{}}function c0(e){if(e.startsWith(`${jf}:${o0}:{`))try{let t=JSON.parse(e.slice(40));if(typeof t=="object"&&t&&typeof t.status=="number"&&typeof t.statusText=="string")return new Zg(t.status,t.statusText,t.data)}catch{}}function u0(e,{relative:t}={}){Q(ws(),"useHref() may be used only in the context of a <Router> component.");let{basename:n,navigator:r}=x.useContext(Ve),{hash:s,pathname:i,search:o}=xs(e,{relative:t}),l=i;return n!=="/"&&(l=i==="/"?n:yt([n,i])),r.createHref({pathname:l,search:o,hash:s})}function ws(){return x.useContext(vs)!=null}function Gt(){return Q(ws(),"useLocation() may be used only in the context of a <Router> component."),x.useContext(vs).location}var Sf="You should call navigate() in a React.useEffect(), not when your component is first rendered.";function Nf(e){x.useContext(Ve).static||x.useLayoutEffect(e)}function Kt(){let{isDataRoute:e}=x.useContext(ct);return e?j0():d0()}function d0(){Q(ws(),"useNavigate() may be used only in the context of a <Router> component.");let e=x.useContext(ur),{basename:t,navigator:n}=x.useContext(Ve),{matches:r}=x.useContext(ct),{pathname:s}=Gt(),i=JSON.stringify(vf(r)),o=x.useRef(!1);return Nf(()=>{o.current=!0}),x.useCallback((c,u={})=>{if(nt(o.current,Sf),!o.current)return;if(typeof c=="number"){n.go(c);return}let d=wf(c,JSON.parse(i),s,u.relative==="path");e==null&&t!=="/"&&(d.pathname=d.pathname==="/"?t:yt([t,d.pathname])),(u.replace?n.replace:n.push)(d,u.state,u)},[t,n,i,s,e])}x.createContext(null);function h0(){let{matches:e}=x.useContext(ct),t=e[e.length-1];return t?t.params:{}}function xs(e,{relative:t}={}){let{matches:n}=x.useContext(ct),{pathname:r}=Gt(),s=JSON.stringify(vf(n));return x.useMemo(()=>wf(e,JSON.parse(s),r,t==="path"),[e,s,r,t])}function f0(e,t){return Ef(e,t)}function Ef(e,t,n,r,s){var p;Q(ws(),"useRoutes() may be used only in the context of a <Router> component.");let{navigator:i}=x.useContext(Ve),{matches:o}=x.useContext(ct),l=o[o.length-1],c=l?l.params:{},u=l?l.pathname:"/",d=l?l.pathnameBase:"/",f=l&&l.route;{let g=f&&f.path||"";Tf(u,!f||g.endsWith("*")||g.endsWith("*?"),`You rendered descendant <Routes> (or called \`useRoutes()\`) at "${u}" (under <Route path="${g}">) but the parent route path has no trailing "*". This means if you navigate deeper, the parent won't match anymore and therefore the child routes will never render.
50
51Please change the parent <Route path="${g}"> to <Route path="${g==="/"?"*":`${g}/*`}">.`)}let h=Gt(),m;if(t){let g=typeof t=="string"?cr(t):t;Q(d==="/"||((p=g.pathname)==null?void 0:p.startsWith(d)),`When overriding the location using \`<Routes location>\` or \`useRoutes(routes, location)\`, the location pathname must begin with the portion of the URL pathname that was matched by all parent routes. The current pathname base is "${d}" but pathname "${g.pathname}" was given in the \`location\` prop.`),m=g}else m=h;let v=m.pathname||"/",w=v;if(d!=="/"){let g=d.replace(/^\//,"").split("/");w="/"+v.replace(/^\//,"").split("/").slice(g.length).join("/")}let b=mf(e,{pathname:w});nt(f||b!=null,`No routes matched location "${m.pathname}${m.search}${m.hash}" `),nt(b==null||b[b.length-1].route.element!==void 0||b[b.length-1].route.Component!==void 0||b[b.length-1].route.lazy!==void 0,`Matched leaf route at location "${m.pathname}${m.search}${m.hash}" does not have an element or Component. This means it will render an <Outlet /> with a null value by default resulting in an "empty" page.`);let y=v0(b&&b.map(g=>Object.assign({},g,{params:Object.assign({},c,g.params),pathname:yt([d,i.encodeLocation?i.encodeLocation(g.pathname.replace(/\?/g,"%3F").replace(/#/g,"%23")).pathname:g.pathname]),pathnameBase:g.pathnameBase==="/"?d:yt([d,i.encodeLocation?i.encodeLocation(g.pathnameBase.replace(/\?/g,"%3F").replace(/#/g,"%23")).pathname:g.pathnameBase])})),o,n,r,s);return t&&y?x.createElement(vs.Provider,{value:{location:{pathname:"/",search:"",hash:"",state:null,key:"default",...m},navigationType:"POP"}},y):y}function p0(){let e=k0(),t=e0(e)?`${e.status} ${e.statusText}`:e instanceof Error?e.message:JSON.stringify(e),n=e instanceof Error?e.stack:null,r="rgba(200,200,200, 0.5)",s={padding:"0.5rem",backgroundColor:r},i={padding:"2px 4px",backgroundColor:r},o=null;return console.error("Error handled by React Router default ErrorBoundary:",e),o=x.createElement(x.Fragment,null,x.createElement("p",null,"💿 Hey developer 👋"),x.createElement("p",null,"You can provide a way better UX than this when your app throws errors by providing your own ",x.createElement("code",{style:i},"ErrorBoundary")," or"," ",x.createElement("code",{style:i},"errorElement")," prop on your route.")),x.createElement(x.Fragment,null,x.createElement("h2",null,"Unexpected Application 
51Error!"),x.createElement("h3",{style:{fontStyle:"italic"}},t),n?x.createElement("pre",{style:s},n):null,o)}var m0=x.createElement(p0,null),Cf=class extends x.Component{constructor(e){super(e),this.state={location:e.location,revalidation:e.revalidation,error:e.error}}static getDerivedStateFromError(e){return{error:e}}static getDerivedStateFromProps(e,t){return t.location!==e.location||t.revalidation!=="idle"&&e.revalidation==="idle"?{error:e.error,location:e.location,revalidation:e.revalidation}:{error:e.error!==void 0?e.error:t.error,location:t.location,revalidation:e.revalidation||t.revalidation}}componentDidCatch(e,t){this.props.onError?this.props.onError(e,t):console.error("React Router caught the following error during render",e)}render(){let e=this.state.error;if(this.context&&typeof e=="object"&&e&&"digest"in e&&typeof e.digest=="string"){const n=c0(e.digest);n&&(e=n)}let t=e!==void 0?x.createElement(ct.Provider,{value:this.props.routeContext},x.createElement(ec.Provider,{value:e,children:this.props.component})):this.props.children;return this.context?x.createElement(g0,{error:e},t):t}};Cf.contextType=r0;var Ua=new WeakMap;function g0({children:e,error:t}){let{basename:n}=x.useContext(Ve);if(typeof t=="object"&&t&&"digest"in t&&typeof t.digest=="string"){let r=l0(t.digest);if(r){let s=Ua.get(t);if(s)throw s;let i=bf(r.location,n);if(xf&&!Ua.get(t))if(i.isExternal||r.reloadDocument)window.location.href=i.absoluteURL||i.to;else{const o=Promise.resolve().then(()=>window.__reactRouterDataRouter.navigate(i.to,{replace:r.replace}));throw Ua.set(t,o),o}return x.createElement("meta",{httpEquiv:"refresh",content:`0;url=${i.absoluteURL||i.to}`})}}return e}function y0({routeContext:e,match:t,children:n}){let r=x.useContext(ur);return r&&r.static&&r.staticContext&&(t.route.errorElement||t.route.ErrorBoundary)&&(r.staticContext._deepestRenderedBoundaryId=t.route.id),x.createElement(ct.Provider,{value:e},n)}function v0(e,t=[],n=null,r=null,s=null){if(e==null){if(!n)return null;if(n.errors)e=n.matches;else if(t.length===0&&!n.initialized&&n.matches.length>0)e=n.matches;else return null}let i=e,o=n==null?void 0:n.errors;if(o!=null){let d=i.findIndex(f=>f.route.id&&(o==null?void 0:o[f.route.id])!==void 0);Q(d>=0,`Could not find a matching route for errors on route IDs: ${Object.keys(o).join(",")}`),i=i.slice(0,Math.min(i.length,d+1))}let l=!1,c=-1;if(n)for(let d=0;d<i.length;d++){let f=i[d];if((f.route.HydrateFallback||f.route.hydrateFallbackElement)&&(c=d),f.route.id){let{loaderData:h,errors:m}=n,v=f.route.loader&&!h.hasOwnProperty(f.route.id)&&(!m||m[f.route.id]===void 0);if(f.route.lazy||v){l=!0,c>=0?i=i.slice(0,c+1):i=[i[0]];break}}}let u=n&&r?(d,f)=>{var h,m;r(d,{location:n.location,params:((m=(h=n.matches)==null?void 0:h[0])==null?void 0:m.params)??{},unstable_pattern:t0(n.matches),errorInfo:f})}:void 0;return i.reduceRight((d,f,h)=>{let m,v=!1,w=null,b=null;n&&(m=o&&f.route.id?o[f.route.id]:void 0,w=f.route.errorElement||m0,l&&(c<0&&h===0?(Tf("route-fallback",!1,"No `HydrateFallback` element provided to render during initial hydration"),v=!0,b=null):c===h&&(v=!0,b=f.route.hydrateFallbackElement||null)));let y=t.concat(i.slice(0,h+1)),p=()=>{let g;return m?g=w:v?g=b:f.route.Component?g=x.createElement(f.route.Component,null):f.route.element?g=f.route.element:g=d,x.createElement(y0,{match:f,routeContext:{outlet:d,matches:y,isDataRoute:n!=null},children:g})};return n&&(f.route.ErrorBoundary||f.route.errorElement||h===0)?x.createElement(Cf,{location:n.location,revalidation:n.revalidation,component:w,error:m,children:p(),routeContext:{outlet:null,matches:y,isDataRoute:!0},onError:u}):p()},null)}function tc(e){return`${e} must be used within a data router.  See https://reactrouter.com/en/main/routers/picking-a-router.`}function w0(e){let t=x.useContext(ur);return Q(t,tc(e)),t}function x0(e){let t=x.useContext(ta);return Q(t,tc(e)),t}function b0(e){let t=x.useContext(ct);return Q(t,tc(e)),t}function nc(e){let t=b0(e),n=t.matches[t.matches.length-1];return Q(n.route.id,`${e} can only be used on routes that contain a unique "id"`),n.route.id}function _0(){return nc("useRouteId")}function k0(){var r;let e=x.useContext(ec),t=x0("useRouteError"),n=nc("useRouteError");return e!==void 0?e:(r=t.errors)==null?void 0:r[n]}function j0(){let{router:e}=w0("useNavigate"),t=nc("useNavigate"),n=x.useRef(!1);return Nf(()=>{n.current=!0}),x.useCallback(async(s,i={})=>{nt(n.current,Sf),n.current&&(typeof s=="number"?await e.navigate(s):await e.navigate(s,{fromRouteId:t,...i}))},[e,t])}var ku={};function Tf(e,t,n){!t&&!ku[e]&&(ku[e]=!0,nt(!1,n))}
51x.memo(S0);function S0({routes:e,future:t,state:n,onError:r}){return Ef(e,void 0,n,r,t)}function ut(e){Q(!1,"A <Route> is only ever to be used as the child of <Routes> element, never rendered directly. Please wrap your <Route> in a <Routes>.")}function N0({basename:e="/",children:t=null,location:n,navigationType:r="POP",navigator:s,static:i=!1,unstable_useTransitions:o}){Q(!ws(),"You cannot render a <Router> inside another <Router>. You should never have more than one in your app.");let l=e.replace(/^\/*/,"/"),c=x.useMemo(()=>({basename:l,navigator:s,static:i,unstable_useTransitions:o,future:{}}),[l,s,i,o]);typeof n=="string"&&(n=cr(n));let{pathname:u="/",search:d="",hash:f="",state:h=null,key:m="default"}=n,v=x.useMemo(()=>{let w=_t(u,l);return w==null?null:{location:{pathname:w,search:d,hash:f,state:h,key:m},navigationType:r}},[l,u,d,f,h,m,r]);return nt(v!=null,`<Router basename="${l}"> is not able to match the URL "${u}${d}${f}" because it does not start with the basename, so the <Router> won't render anything.`),v==null?null:x.createElement(Ve.Provider,{value:c},x.createElement(vs.Provider,{children:t,value:v}))}function E0({children:e,location:t}){return f0(Go(e),t)}function Go(e,t=[]){let n=[];return x.Children.forEach(e,(r,s)=>{if(!x.isValidElement(r))return;let i=[...t,s];if(r.type===x.Fragment){n.push.apply(n,Go(r.props.children,i));return}Q(r.type===ut,`[${typeof r.type=="string"?r.type:r.type.name}] is not a <Route> component. All component children of <Routes> must be a <Route> or <React.Fragment>`),Q(!r.props.index||!r.props.children,"An index route cannot have child routes.");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,middleware:r.props.middleware,loader:r.props.loader,action:r.props.action,hydrateFallbackElement:r.props.hydrateFallbackElement,HydrateFallback:r.props.HydrateFallback,errorElement:r.props.errorElement,ErrorBoundary:r.props.ErrorBoundary,hasErrorBoundary:r.props.hasErrorBoundary===!0||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=Go(r.props.children,i)),n.push(o)}),n}var oi="get",li="application/x-www-form-urlencoded";function na(e){return typeof HTMLElement<"u"&&e instanceof HTMLElement}function C0(e){return na(e)&&e.tagName.toLowerCase()==="button"}function T0(e){return na(e)&&e.tagName.toLowerCase()==="form"}function A0(e){return na(e)&&e.tagName.toLowerCase()==="input"}function P0(e){return!!(e.metaKey||e.altKey||e.ctrlKey||e.shiftKey)}function R0(e,t){return e.button===0&&(!t||t==="_self")&&!P0(e)}function Ko(e=""){return new URLSearchParams(typeof e=="string"||Array.isArray(e)||e instanceof URLSearchParams?e:Object.keys(e).reduce((t,n)=>{let r=e[n];return t.concat(Array.isArray(r)?r.map(s=>[n,s]):[[n,r]])},[]))}function O0(e,t){let n=Ko(e);return t&&t.forEach((r,s)=>{n.has(s)||t.getAll(s).forEach(i=>{n.append(s,i)})}),n}var Ms=null;function I0(){if(Ms===null)try{new FormData(document.createElement("form"),0),Ms=!1}catch{Ms=!0}return Ms}var D0=new Set(["application/x-www-form-urlencoded","multipart/form-data","text/plain"]);function za(e){return e!=null&&!D0.has(e)?(nt(!1,`"${e}" is not a valid \`encType\` for \`<Form>\`/\`<fetcher.Form>\` and will default to "${li}"`),null):e}function F0(e,t){let n,r,s,i,o;if(T0(e)){let l=e.getAttribute("action");r=l?_t(l,t):null,n=e.getAttribute("method")||oi,s=za(e.getAttribute("enctype"))||li,i=new FormData(e)}else if(C0(e)||A0(e)&&(e.type==="submit"||e.type==="image")){let l=e.form;if(l==null)throw new Error('Cannot submit a <button> or <input type="submit"> without a <form>');let c=e.getAttribute("formaction")||l.getAttribute("action");if(r=c?_t(c,t):null,n=e.getAttribute("formmethod")||l.getAttribute("method")||oi,s=za(e.getAttribute("formenctype"))||za(l.getAttribute("enctype"))||li,i=new FormData(l,e),!I0()){let{name:u,type:d,value:f}=e;if(d==="image"){let h=u?`${u}.`:"";i.append(`${h}x`,"0"),i.append(`${h}y`,"0")}else u&&i.append(u,f)}}else{if(na(e))throw new Error('Cannot submit element that is not <form>, <button>, or <input type="submit|image">');n=oi,r=null,s=li,o=e}return i&&s==="text/plain"&&(o=i,i=void 0),{action:r,method:n.toLowerCase(),encType:s,formData:i,body:o}}Object.getOwnPropertyNames(Object.prototype).sort().join("\0");function rc(e,t){if(e===!1||e===null||typeof e>"u")throw new Error(t)}function L0(e,t,n,r){let s=typeof e=="string"?new URL(e,typeof window>"u"?"server://singlefetch/":window.location.origin):e;return n?s.pathname.endsWith("/")?s.pathname=`${s.pathname}_.${r}`:s.pathname=`${s.pathname}.${r}`:s.pathname==="/"?s.pathname=`_root.${r}`:t&&_t(s.pathname,t)==="/"?s.pathname=`${t.replace(/\/$/,"")}/_root.${r}`:s.pathname=`${s.pathname.replace(/\/$/,"")}.${r}`,s}async function $0(e,t){if(e.id in t)return t[e.id];try{let n=await import(e.module);return t[e.id]=n,n}catch(n){return console.error(`Error loading route module \`${e.module}\`, reloading page...`),console.error(n),window.__reactRouterContext&&window.__reactRouterContext.
51isSpaMode,window.location.reload(),new Promise(()=>{})}}function U0(e){return e==null?!1:e.href==null?e.rel==="preload"&&typeof e.imageSrcSet=="string"&&typeof e.imageSizes=="string":typeof e.rel=="string"&&typeof e.href=="string"}async function z0(e,t,n){let r=await Promise.all(e.map(async s=>{let i=t.routes[s.route.id];if(i){let o=await $0(i,n);return o.links?o.links():[]}return[]}));return H0(r.flat(1).filter(U0).filter(s=>s.rel==="stylesheet"||s.rel==="preload").map(s=>s.rel==="stylesheet"?{...s,rel:"prefetch",as:"style"}:{...s,rel:"prefetch"}))}function ju(e,t,n,r,s,i){let o=(c,u)=>n[u]?c.route.id!==n[u].route.id:!0,l=(c,u)=>{var d;return n[u].pathname!==c.pathname||((d=n[u].route.path)==null?void 0:d.endsWith("*"))&&n[u].params["*"]!==c.params["*"]};return i==="assets"?t.filter((c,u)=>o(c,u)||l(c,u)):i==="data"?t.filter((c,u)=>{var f;let d=r.routes[c.route.id];if(!d||!d.hasLoader)return!1;if(o(c,u)||l(c,u))return!0;if(c.route.shouldRevalidate){let h=c.route.shouldRevalidate({currentUrl:new URL(s.pathname+s.search+s.hash,window.origin),currentParams:((f=n[0])==null?void 0:f.params)||{},nextUrl:new URL(e,window.origin),nextParams:c.params,defaultShouldRevalidate:!0});if(typeof h=="boolean")return h}return!0}):[]}function M0(e,t,{includeHydrateFallback:n}={}){return B0(e.map(r=>{let s=t.routes[r.route.id];if(!s)return[];let i=[s.module];return s.clientActionModule&&(i=i.concat(s.clientActionModule)),s.clientLoaderModule&&(i=i.concat(s.clientLoaderModule)),n&&s.hydrateFallbackModule&&(i=i.concat(s.hydrateFallbackModule)),s.imports&&(i=i.concat(s.imports)),i}).flat(1))}function B0(e){return[...new Set(e)]}function W0(e){let t={},n=Object.keys(e).sort();for(let r of n)t[r]=e[r];return t}function H0(e,t){let n=new Set;return new Set(t),e.reduce((r,s)=>{let i=JSON.stringify(W0(s));return n.has(i)||(n.add(i),r.push({key:i,link:s})),r},[])}function Af(){let e=x.useContext(ur);return rc(e,"You must render this element inside a <DataRouterContext.Provider> element"),e}function V0(){let e=x.useContext(ta);return rc(e,"You must render this element inside a <DataRouterStateContext.Provider> element"),e}var sc=x.createContext(void 0);sc.displayName="FrameworkContext";function Pf(){let e=x.useContext(sc);return rc(e,"You must render this element inside a <HydratedRouter> element"),e}function q0(e,t){let n=x.useContext(sc),[r,s]=x.useState(!1),[i,o]=x.useState(!1),{onFocus:l,onBlur:c,onMouseEnter:u,onMouseLeave:d,onTouchStart:f}=t,h=x.useRef(null);x.useEffect(()=>{if(e==="render"&&o(!0),e==="viewport"){let w=y=>{y.forEach(p=>{o(p.isIntersecting)})},b=new IntersectionObserver(w,{threshold:.5});return h.current&&b.observe(h.current),()=>{b.disconnect()}}},[e]),x.useEffect(()=>{if(r){let w=setTimeout(()=>{o(!0)},100);return()=>{clearTimeout(w)}}},[r]);let m=()=>{s(!0)},v=()=>{s(!1),o(!1)};return n?e!=="intent"?[i,h,{}]:[i,h,{onFocus:br(l,m),onBlur:br(c,v),onMouseEnter:br(u,m),onMouseLeave:br(d,v),onTouchStart:br(f,m)}]:[!1,h,{}]}function br(e,t){return n=>{e&&e(n),n.defaultPrevented||t(n)}}function G0({page:e,...t}){let{router:n}=Af(),r=x.useMemo(()=>mf(n.routes,e,n.basename),[n.routes,e,n.basename]);return r?x.createElement(Y0,{page:e,matches:r,...t}):null}function K0(e){let{manifest:t,routeModules:n}=Pf(),[r,s]=x.useState([]);return x.useEffect(()=>{let i=!1;return z0(e,t,n).then(o=>{i||s(o)}),()=>{i=!0}},[e,t,n]),r}function Y0({page:e,matches:t,...n}){let r=Gt(),{future:s,manifest:i,routeModules:o}=Pf(),{basename:l}=Af(),{loaderData:c,matches:u}=V0(),d=x.useMemo(()=>ju(e,t,u,i,r,"data"),[e,t,u,i,r]),f=x.useMemo(()=>ju(e,t,u,i,r,"assets"),[e,t,u,i,r]),h=x.useMemo(()=>{if(e===r.pathname+r.search+r.hash)return[];let w=new Set,b=!1;if(t.forEach(p=>{var _;let g=i.routes[p.route.id];!g||!g.hasLoader||(!d.some(j=>j.route.id===p.route.id)&&p.route.id in c&&((_=o[p.route.id])!=null&&_.shouldRevalidate)||g.hasClientLoader?b=!0:w.add(p.route.id))}),w.size===0)return[];let y=L0(e,l,s.unstable_trailingSlashAwareDataRequests,"data");return b&&w.size>0&&y.searchParams.set("_routes",t.filter(p=>w.has(p.route.id)).map(p=>p.route.id).join(",")),[y.pathname+y.search]},[l,s.unstable_trailingSlashAwareDataRequests,c,r,i,d,t,e,o]),m=x.useMemo(()=>M0(f,i),[f,i]),v=K0(f);return x.createElement(x.Fragment,null,h.map(w=>x.createElement("link",{key:w,rel:"prefetch",as:"fetch",href:w,...n})),m.map(w=>x.createElement("link",{key:w,rel:"modulepreload",href:w,...n})),v.map(({key:w,link:b})=>x.createElement("link",{key:w,nonce:n.nonce,...b,crossOrigin:b.crossOrigin??n.crossOrigin})))}function J0(...e){return t=>{e.forEach(n=>{typeof n=="function"?n(t):n!=null&&(n.current=t)})}}var Q0=typeof window<"u"&&typeof window.document<"u"&&typeof window.document.createElement<"u";try{Q0&&(window.__reactRouterVersion="7.13.0")}catch{}function X0({basename:e,children:t,unstable_useTransitions:n,window:r}){let s=x.useRef();s.current==null&&(s.current=Ag({window:r,v5Compat:!0}));let i=s.current,[o,l]=x.useState({action:i.action,location:i.location}),c=x.useCallback(u=>{n===!1?l(u):x.startTransition(()=>l(u))},[n]);return x.useLayoutEffect(()=>
51i.listen(c),[i,c]),x.createElement(N0,{basename:e,children:t,location:o.location,navigationType:o.action,navigator:i,unstable_useTransitions:n})}var Rf=/^(?:[a-z][a-z0-9+.-]*:|\/\/)/i,_e=x.forwardRef(function({onClick:t,discover:n="render",prefetch:r="none",relative:s,reloadDocument:i,replace:o,state:l,target:c,to:u,preventScrollReset:d,viewTransition:f,unstable_defaultShouldRevalidate:h,...m},v){let{basename:w,unstable_useTransitions:b}=x.useContext(Ve),y=typeof u=="string"&&Rf.test(u),p=bf(u,w);u=p.to;let g=u0(u,{relative:s}),[_,j,S]=q0(r,m),E=ny(u,{replace:o,state:l,target:c,preventScrollReset:d,relative:s,viewTransition:f,unstable_defaultShouldRevalidate:h,unstable_useTransitions:b});function C(A){t&&t(A),A.defaultPrevented||E(A)}let k=x.createElement("a",{...m,...S,href:p.absoluteURL||g,onClick:p.isExternal||i?t:C,ref:J0(v,j),target:c,"data-discover":!y&&n==="render"?"true":void 0});return _&&!y?x.createElement(x.Fragment,null,k,x.createElement(G0,{page:g})):k});_e.displayName="Link";var Z0=x.forwardRef(function({"aria-current":t="page",caseSensitive:n=!1,className:r="",end:s=!1,style:i,to:o,viewTransition:l,children:c,...u},d){let f=xs(o,{relative:u.relative}),h=Gt(),m=x.useContext(ta),{navigator:v,basename:w}=x.useContext(Ve),b=m!=null&&ly(f)&&l===!0,y=v.encodeLocation?v.encodeLocation(f).pathname:f.pathname,p=h.pathname,g=m&&m.navigation&&m.navigation.location?m.navigation.location.pathname:null;n||(p=p.toLowerCase(),g=g?g.toLowerCase():null,y=y.toLowerCase()),g&&w&&(g=_t(g,w)||g);const _=y!=="/"&&y.endsWith("/")?y.length-1:y.length;let j=p===y||!s&&p.startsWith(y)&&p.charAt(_)==="/",S=g!=null&&(g===y||!s&&g.startsWith(y)&&g.charAt(y.length)==="/"),E={isActive:j,isPending:S,isTransitioning:b},C=j?t:void 0,k;typeof r=="function"?k=r(E):k=[r,j?"active":null,S?"pending":null,b?"transitioning":null].filter(Boolean).join(" ");let A=typeof i=="function"?i(E):i;return x.createElement(_e,{...u,"aria-current":C,className:k,ref:d,style:A,to:o,viewTransition:l},typeof c=="function"?c(E):c)});Z0.displayName="NavLink";var ey=x.forwardRef(({discover:e="render",fetcherKey:t,navigate:n,reloadDocument:r,replace:s,state:i,method:o=oi,action:l,onSubmit:c,relative:u,preventScrollReset:d,viewTransition:f,unstable_defaultShouldRevalidate:h,...m},v)=>{let{unstable_useTransitions:w}=x.useContext(Ve),b=ay(),y=oy(l,{relative:u}),p=o.toLowerCase()==="get"?"get":"post",g=typeof l=="string"&&Rf.test(l),_=j=>{if(c&&c(j),j.defaultPrevented)return;j.preventDefault();let S=j.nativeEvent.submitter,E=(S==null?void 0:S.getAttribute("formmethod"))||o,C=()=>b(S||j.currentTarget,{fetcherKey:t,method:E,navigate:n,replace:s,state:i,relative:u,preventScrollReset:d,viewTransition:f,unstable_defaultShouldRevalidate:h});w&&n!==!1?x.startTransition(()=>C()):C()};return x.createElement("form",{ref:v,method:p,action:y,onSubmit:r?c:_,...m,"data-discover":!g&&e==="render"?"true":void 0})});ey.displayName="Form";function ty(e){return`${e} must be used within a data router.  See https://reactrouter.com/en/main/routers/picking-a-router.`}function Of(e){let t=x.useContext(ur);return Q(t,ty(e)),t}function ny(e,{target:t,replace:n,state:r,preventScrollReset:s,relative:i,viewTransition:o,unstable_defaultShouldRevalidate:l,unstable_useTransitions:c}={}){let u=Kt(),d=Gt(),f=xs(e,{relative:i});return x.useCallback(h=>{if(R0(h,t)){h.preventDefault();let m=n!==void 0?n:rs(d)===rs(f),v=()=>u(e,{replace:m,state:r,preventScrollReset:s,relative:i,viewTransition:o,unstable_defaultShouldRevalidate:l});c?x.startTransition(()=>v()):v()}},[d,u,f,n,r,t,e,s,i,o,l,c])}function ry(e){nt(typeof URLSearchParams<"u","You cannot use the `useSearchParams` hook in a browser that does not support the URLSearchParams API. If you need to support Internet Explorer 11, we recommend you load a polyfill such as https://github.com/ungap/url-search-params.");let t=x.useRef(Ko(e)),n=x.useRef(!1),r=Gt(),s=x.useMemo(()=>O0(r.search,n.current?null:t.current),[r.search]),i=Kt(),o=x.useCallback((l,c)=>{const u=Ko(typeof l=="function"?l(new URLSearchParams(s)):l);n.current=!0,i("?"+u,c)},[i,s]);return[s,o]}var sy=0,iy=()=>`__${String(++sy)}__`;function ay(){let{router:e}=Of("useSubmit"),{basename:t}=x.useContext(Ve),n=_0(),r=e.fetch,s=e.navigate;return x.useCallback(async(i,o={})=>{let{action:l,method:c,encType:u,formData:d,body:f}=F0(i,t);if(o.navigate===!1){let h=o.fetcherKey||iy();await r(h,n,o.action||l,{unstable_defaultShouldRevalidate:o.unstable_defaultShouldRevalidate,preventScrollReset:o.preventScrollReset,formData:d,body:f,formMethod:o.method||c,formEncType:o.encType||u,flushSync:o.flushSync})}else await s(o.action||l,{unstable_defaultShouldRevalidate:o.unstable_defaultShouldRevalidate,preventScrollReset:o.preventScrollReset,formData:d,body:f,formMethod:o.method||c,formEncType:o.encType||u,replace:o.replace,state:o.state,fromRouteId:n,flushSync:o.flushSync,viewTransition:o.viewTransition})},[r,s,t,n])}function oy(e,{relative:t}={}){let{basename:n}=x.useContext(Ve),r=x.useContext(ct);Q(r,"useFormAction must be used inside a RouteContext");let[s]=r.matches.slice(-1),i={...xs(e||".",{relative:t})},o=Gt();if(e==null){i.search=o.search;let l=new URLSearchParams(i.search),c=l.getAll("index");if(c.some(d=>d==="")){l.delete("index"),c.filter(f=>f).forEach(f=>l.append("index",f));let d=l.toString();i.search=d?`?${d}`:""}}return(!e||e===".")&&s.route.index&&(i.search=i.search?i.search.replace(/^\?/,"?index&"):"?index"),n!=="/"&&(i.pathname=i.pathname==="/"?n:yt([n,i.pathname])),rs(i)}function ly(e,{relative:t}={}){let n=x.useContext(kf);Q(n!=null,"`useViewTransitionState` must be used within `react-router-dom`'s `RouterProvider`.  Did you accidentally import `RouterProvider` from `react-router`?");let{basename:r}=Of("useViewTransitionState"),s=xs(e,{relative:t});if(!n.isTransitioning)return!1;let i=_t(n.currentLocation.pathname,r)||n.currentLocation.pathname,o=_t(n.nextLocation.pathname,r)||n.nextLocation.pathname;return Oi(s.pathname,o)!=null||Oi(s.pathname,i)!=null}function ra(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 cy(e,t,n,r){function s(i){return i instanceof n?i:new n(function(o){o(i)})}
51return new(n||(n=Promise))(function(i,o){function l(d){try{u(r.next(d))}catch(f){o(f)}}function c(d){try{u(r.throw(d))}catch(f){o(f)}}function u(d){d.done?i(d.value):s(d.value).then(l,c)}u((r=r.apply(e,t||[])).next())})}const uy=e=>e?(...t)=>e(...t):(...t)=>fetch(...t);class ic extends Error{constructor(t,n="FunctionsError",r){super(t),this.name=n,this.context=r}}class dy extends ic{constructor(t){super("Failed to send a request to the Edge Function","FunctionsFetchError",t)}}class Su extends ic{constructor(t){super("Relay Error invoking the Edge Function","FunctionsRelayError",t)}}class Nu extends ic{constructor(t){super("Edge Function returned a non-2xx status code","FunctionsHttpError",t)}}var Yo;(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"})(Yo||(Yo={}));class hy{constructor(t,{headers:n={},customFetch:r,region:s=Yo.Any}={}){this.url=t,this.headers=n,this.region=s,this.fetch=uy(r)}setAuth(t){this.headers.Authorization=`Bearer ${t}`}invoke(t){return cy(this,arguments,void 0,function*(n,r={}){var s;let i,o;try{const{headers:l,method:c,body:u,signal:d,timeout:f}=r;let h={},{region:m}=r;m||(m=this.region);const v=new URL(`${this.url}/${n}`);m&&m!=="any"&&(h["x-region"]=m,v.searchParams.set("forceFunctionRegion",m));let w;u&&(l&&!Object.prototype.hasOwnProperty.call(l,"Content-Type")||!l)?typeof Blob<"u"&&u instanceof Blob||u instanceof ArrayBuffer?(h["Content-Type"]="application/octet-stream",w=u):typeof u=="string"?(h["Content-Type"]="text/plain",w=u):typeof FormData<"u"&&u instanceof FormData?w=u:(h["Content-Type"]="application/json",w=JSON.stringify(u)):u&&typeof u!="string"&&!(typeof Blob<"u"&&u instanceof Blob)&&!(u instanceof ArrayBuffer)&&!(typeof FormData<"u"&&u instanceof FormData)?w=JSON.stringify(u):w=u;let b=d;f&&(o=new AbortController,i=setTimeout(()=>o.abort(),f),d?(b=o.signal,d.addEventListener("abort",()=>o.abort())):b=o.signal);const y=yield this.fetch(v.toString(),{method:c||"POST",headers:Object.assign(Object.assign(Object.assign({},h),this.headers),l),body:w,signal:b}).catch(j=>{throw new dy(j)}),p=y.headers.get("x-relay-error");if(p&&p==="true")throw new Su(y);if(!y.ok)throw new Nu(y);let g=((s=y.headers.get("Content-Type"))!==null&&s!==void 0?s:"text/plain").split(";")[0].trim(),_;return g==="application/json"?_=yield y.json():g==="application/octet-stream"||g==="application/pdf"?_=yield y.blob():g==="text/event-stream"?_=y:g==="multipart/form-data"?_=yield y.formData():_=yield y.text(),{data:_,error:null,response:y}}catch(l){return{data:null,error:l,response:l instanceof Nu||l instanceof Su?l.context:void 0}}finally{i&&clearTimeout(i)}})}}var fy=class extends Error{constructor(e){super(e.message),this.name="PostgrestError",this.details=e.details,this.hint=e.hint,this.co
51de=e.code}},py=class{constructor(e){var t,n,r;this.shouldThrowOnError=!1,this.method=e.method,this.url=e.url,this.headers=new Headers(e.headers),this.schema=e.schema,this.body=e.body,this.shouldThrowOnError=(t=e.shouldThrowOnError)!==null&&t!==void 0?t:!1,this.signal=e.signal,this.isMaybeSingle=(n=e.isMaybeSingle)!==null&&n!==void 0?n:!1,this.urlLengthLimit=(r=e.urlLengthLimit)!==null&&r!==void 0?r:8e3,e.fetch?this.fetch=e.fetch:this.fetch=fetch}throwOnError(){return this.shouldThrowOnError=!0,this}setHeader(e,t){return this.headers=new Headers(this.headers),this.headers.set(e,t),this}then(e,t){var n=this;this.schema===void 0||(["GET","HEAD"].includes(this.method)?this.headers.set("Accept-Profile",this.schema):this.headers.set("Content-Profile",this.schema)),this.method!=="GET"&&this.method!=="HEAD"&&this.headers.set("Content-Type","application/json");const r=this.fetch;let s=r(this.url.toString(),{method:this.method,headers:this.headers,body:JSON.stringify(this.body),signal:this.signal}).then(async i=>{let o=null,l=null,c=null,u=i.status,d=i.statusText;if(i.ok){var f,h;if(n.method!=="HEAD"){var m;const y=await i.text();y===""||(n.headers.get("Accept")==="text/csv"||n.headers.get("Accept")&&(!((m=n.headers.get("Accept"))===null||m===void 0)&&m.includes("application/vnd.pgrst.plan+text"))?l=y:l=JSON.parse(y))}const w=(f=n.headers.get("Prefer"))===null||f===void 0?void 0:f.match(/count=(exact|planned|estimated)/),b=(h=i.headers.get("content-range"))===null||h===void 0?void 0:h.split("/");w&&b&&b.length>1&&(c=parseInt(b[1])),n.isMaybeSingle&&n.method==="GET"&&Array.isArray(l)&&(l.length>1?(o={code:"PGRST116",details:`Results contain ${l.length} rows, application/vnd.pgrst.object+json requires 1 row`,hint:null,message:"JSON object requested, multiple (or no) rows returned"},l=null,c=null,u=406,d="Not Acceptable"):l.length===1?l=l[0]:l=null)}else{var v;const w=await i.text();try{o=JSON.parse(w),Array.isArray(o)&&i.status===404&&(l=[],o=null,u=200,d="OK")}catch{i.status===404&&w===""?(u=204,d="No Content"):o={message:w}}if(o&&n.isMaybeSingle&&(!(o==null||(v=o.details)===null||v===void 0)&&v.includes("0 rows"))&&(o=null,u=200,d="OK"),o&&n.shouldThrowOnError)throw new fy(o)}return{error:o,data:l,count:c,status:u,statusText:d}});return this.shouldThrowOnError||(s=s.catch(i=>{var o;let l="",c="",u="";const d=i==null?void 0:i.cause;if(d){var f,h,m,v;const y=(f=d==null?void 0:d.message)!==null&&f!==void 0?f:"",p=(h=d==null?void 0:d.code)!==null&&h!==void 0?h:"";l=`${(m=i==null?void 0:i.name)!==null&&m!==void 0?m:"FetchError"}: ${i==null?void 0:i.message}`,l+=`
52
53Caused by: ${(v=d==null?void 0:d.name)!==null&&v!==void 0?v:"Error"}: ${y}`,p&&(l+=` (${p})`),d!=null&&d.stack&&(l+=`
54${d.stack}`)}else{var w;l=(w=i==null?void 0:i.stack)!==null&&w!==void 0?w:""}const b=this.url.toString().length;return(i==null?void 0:i.name)==="AbortError"||(i==null?void 0:i.code)==="ABORT_ERR"?(u="",c="Request was aborted (timeout or manual cancellation)",b>this.urlLengthLimit&&(c+=`. Note: Your request URL is ${b} characters, which may exceed server limits. If selecting many fields, consider using views. If filtering with large arrays (e.g., .in('id', [many IDs])), consider using an RPC function to pass values server-side.`)):((d==null?void 0:d.name)==="HeadersOverflowError"||(d==null?void 0:d.code)==="UND_ERR_HEADERS_OVERFLOW")&&(u="",c="HTTP headers exceeded server limits (typically 16KB)",b>this.urlLengthLimit&&(c+=`. Your request URL is ${b} characters. If selecting many fields, consider using views. If filtering with large arrays (e.g., .in('id', [200+ IDs])), consider using an RPC function instead.`)),{error:{message:`${(o=i==null?void 0:i.name)!==null&&o!==void 0?o:"FetchError"}: ${i==null?void 0:i.message}`,details:l,hint:c,code:u},data:null,count:null,status:0,statusText:""}})),s.then(e,t)}returns(){return this}overrideTypes(){return this}},my=class extends py{select(e){let t=!1;const n=(e??"*").split("").map(r=>/\s/.test(r)&&!t?"":(r==='"'&&(t=!t),r)).join("");return this.url.searchParams.set("select",n),this.headers.append("Prefer","return=representation"),this}order(e,{ascending:t=!0,nullsFirst:n,foreignTable:r,referencedTable:s=r}={}){const i=s?`${s}.order`:"order",o=this.url.searchParams.get(i);return this.url.searchParams.set(i,`${o?`${o},`:""}${e}.${t?"asc":"desc"}${n===void 0?"":n?".nullsfirst":".nullslast"}`),this}limit(e,{foreignTable:t,referencedTable:n=t}={}){const r=typeof n>"u"?"limit":`${n}.limit`;return this.url.searchParams.set(r,`${e}`),this}range(e,t,{foreignTable:n,referencedTable:r=n}={}){const s=typeof r>"u"?"offset":`${r}.offset`,i=typeof r>"u"?"limit":`${r}.limit`;return this.url.searchParams.set(s,`${e}`),this.url.searchParams.set(i,`${t-e+1}`),this}abortSignal(e){return this.signal=e,this}single(){return this.headers.set("Accept","application/vnd.pgrst.object+json"),this}maybeSingle(){return this.method==="GET"?this.headers.set("Accept","application/json"):this.headers.set("Accept","application/vnd.pgrst.object+json"),this.isMaybeSingle=!0,this}csv(){return this.headers.set("Accept","text/csv"),this}geojson(){return this.headers.set("Accept","application/geo+json"),this}
54explain({analyze:e=!1,verbose:t=!1,settings:n=!1,buffers:r=!1,wal:s=!1,format:i="text"}={}){var o;const l=[e?"analyze":null,t?"verbose":null,n?"settings":null,r?"buffers":null,s?"wal":null].filter(Boolean).join("|"),c=(o=this.headers.get("Accept"))!==null&&o!==void 0?o:"application/json";return this.headers.set("Accept",`application/vnd.pgrst.plan+${i}; for="${c}"; options=${l};`),i==="json"?this:this}rollback(){return this.headers.append("Prefer","tx=rollback"),this}returns(){return this}maxAffected(e){return this.headers.append("Prefer","handling=strict"),this.headers.append("Prefer",`max-affected=${e}`),this}};const Eu=new RegExp("[,()]");var Nn=class extends my{eq(e,t){return this.url.searchParams.append(e,`eq.${t}`),this}neq(e,t){return this.url.searchParams.append(e,`neq.${t}`),this}gt(e,t){return this.url.searchParams.append(e,`gt.${t}`),this}gte(e,t){return this.url.searchParams.append(e,`gte.${t}`),this}lt(e,t){return this.url.searchParams.append(e,`lt.${t}`),this}lte(e,t){return this.url.searchParams.append(e,`lte.${t}`),this}like(e,t){return this.url.searchParams.append(e,`like.${t}`),this}likeAllOf(e,t){return this.url.searchParams.append(e,`like(all).{${t.join(",")}}`),this}likeAnyOf(e,t){return this.url.searchParams.append(e,`like(any).{${t.join(",")}}`),this}ilike(e,t){return this.url.searchParams.append(e,`ilike.${t}`),this}ilikeAllOf(e,t){return this.url.searchParams.append(e,`ilike(all).{${t.join(",")}}`),this}ilikeAnyOf(e,t){return this.url.searchParams.append(e,`ilike(any).{${t.join(",")}}`),this}regexMatch(e,t){return this.url.searchParams.append(e,`match.${t}`),this}regexIMatch(e,t){return this.url.searchParams.append(e,`imatch.${t}`),this}is(e,t){return this.url.searchParams.append(e,`is.${t}`),this}isDistinct(e,t){return this.url.searchParams.append(e,`isdistinct.${t}`),this}in(e,t){const n=Array.from(new Set(t)).map(r=>typeof r=="string"&&Eu.test(r)?`"${r}"`:`${r}`).join(",");return this.url.searchParams.append(e,`in.(${n})`),this}notIn(e,t){const n=Array.from(new Set(t)).map(r=>typeof r=="string"&&Eu.test(r)?`"${r}"`:`${r}`).join(",");return this.url.searchParams.append(e,`not.in.(${n})`),this}contains(e,t){return typeof t=="string"?this.url.searchParams.append(e,`cs.${t}`):Array.isArray(t)?this.url.searchParams.append(e,`cs.{${t.join(",")}}`):this.url.searchParams.append(e,`cs.${JSON.stringify(t)}`),this}containedBy(e,t){return typeof t=="string"?this.url.searchParams.append(e,`cd.${t}`):Array.isArray(t)?this.url.searchParams.append(e,`cd.{${t.join(",")}}`):this.url.searchParams.append(e,`cd.${JSON.stringify(t)}`),this}rangeGt(e,t){return this.url.searchParams.append(e,`sr.${t}`),this}rangeGte(e,t){return this.url.searchParams.append(e,`nxl.${t}`),this}rangeLt(e,t){return this.url.searchParams.append(e,`sl.${t}`),this}rangeLte(e,t){return this.url.searchParams.append(e,`nxr.${t}`),this}rangeAdjacent(e,t){return this.url.searchParams.append(e,`adj.${t}`),this}overlaps(e,t){return typeof t=="string"?this.url.searchParams.append(e,`ov.${t}`):this.url.searchParams.append(e,`ov.{${t.join(",")}}`),this}textSearch(e,t,{config:n,type:r}={}){let s="";r==="plain"?s="pl":r==="phrase"?s="ph":r==="websearch"&&(s="w");const i=n===void 0?"":`(${n})`;return this.url.searchParams.append(e,`${s}fts${i}.${t}`),this}match(e){return Object.entries(e).forEach(([t,n])=>{this.url.searchParams.append(t,`eq.${n}`)}),this}not(e,t,n){return this.url.searchParams.append(e,`not.${t}.${n}`),this}or(e,{foreignTable:t,referencedTable:n=t}={}){const r=n?`${n}.or`:"or";return this.url.searchParams.append(r,`(${e})`),this}filter(e,t,n){return this.url.searchParams.append(e,`${t}.${n}`),this}},gy=class{constructor(e,{headers:t={},schema:n,fetch:r,urlLengthLimit:s=8e3}){this.url=e,this.headers=new Headers(t),this.schema=n,this.fetch=r,this.urlLengthLimit=s}cloneRequestState(){return{url:new URL(this.url.toString()),headers:new Headers(this.headers)}}select(e,t){const{head:n=!1,count:r}=t??{},s=n?"HEAD":"GET";let i=!1;const o=(e??"*").split("").map(u=>/\s/.test(u)&&!i?"":(u==='"'&&(i=!i),u)).join(""),{url:l,headers:c}=this.cloneRequestState();return l.searchParams.set("select",o),r&&c.append("Prefer",`count=${r}`),new Nn({method:s,url:l,headers:c,schema:this.schema,fetch:this.fetch,urlLengthLimit:this.urlLengthLimit})}insert(e,{count:t,defaultToNull:n=!0}={}){var r;const s="POST",{url:i,headers:o}=this.cloneRequestState();if(t&&o.append("Prefer",`count=${t}`),n||o.append("Prefer","missing=default"),Array.isArray(e)){const l=e.reduce((c,u)=>c.concat(Object.keys(u)),[]);if(l.length>0){const c=[...new Set(l)].map(u=>`"${u}"`);i.searchParams.set("columns",c.join(","))}}return new Nn({method:s,url:i,headers:o,schema:this.schema,body:e,fetch:(r=this.fetch)!==null&&r!==void 0?r:fetch,urlLengthLimit:this.urlLengthLimit})}upsert(e,{onConflict:t,ignoreDuplicates:n=!1,count:r,defaultToNull:s=!0}={}){var i;const o="POST",{url:l,headers:c}=this.cloneRequestState();if(c.append("Prefer",`resolution=${n?"ignore":"merge"}-duplicates`),t!==void 0&&l.searchParams.set("on_conflict",t),r&&c.append("Prefer",`count=${r}`),s||c.append("Prefer","missing=default"),Array.isArray(e)){const u=e.reduce((d,f)=>d.concat(Object.keys(f)),[]);if(u.length>0){const d=[...new Set(u)].map(f=>`"${f}"`);l.searchParams.set("columns",d.join(","))}}return new Nn({method:o,url:l,headers:c,schema:this.schema,body:e,fetch:(i=this.fetch)!==null&&i!==void 0?i:fetch,urlLengthLimit:this.urlLengthLimit})}update(e,{count:t}={}){var n;const r="PATCH",{url:s,headers:i}=this.cloneRequestState();return t&&i.append("Prefer",`count=${t}`),new Nn({method:r,url:s,headers:i,schema:this.schema,body:e,fetch:(n=this.fetch)!==null&&n!==void 0?n:fetch,urlLengthLimit:this.urlLengthLimit})}delete({count:e}={}){var t;const n="DELETE",{url:r,headers:s}=this.cloneRequestState();return e&&s.append("Prefer",`count=${e}`),new Nn({method:n,url:r,headers:s,schema:this.schema,fetch:(t=this.fetch)!==null&&t!==void 0?t:fetch,urlLengthLimit:this.urlLengthLimit})}};function ss(e){"@babel/helpers - typeof";return ss=typeof Symbol=="function"&&typeof Symbol.iterator=="symbol"?function(t){return typeof t}:function(t){return t&&typeof Symbol=="function"&&t.constructor===Symbol&&t!==Symbol.prototype?"symbol":typeof t},ss(e)}function yy(e,t){if(ss(e)!="object"||!e)return e;var n=e[Symbol.toPrimitive];if(n!==void 0){var r=n.call(e,t||"default");if(ss(r)!="object")return r;throw new TypeError("@@toPrimitive must return a primitive value.")}return(t==="string"?String:Number)(e)}function vy(e){var t=yy(e,"string");return ss(t)=="symbol"?t:t+""}function wy(e,t,n){return(t=vy(t))in e?Object.defineProperty(e,t,{value:n,enumerable:!0,configurable:!0,writable:!0}):e[t]=n,e}function Cu(e,t){var n=Object.keys(e);if(Object.getOwnPropertySymbols){var r=Object.getOwnPropertySymbols(e);t&&(r=r.filter(function(s){return Object.getOwnPropertyDescriptor(e,s).enumerable})),n.push.apply(n,r)}return n}function Bs(e){for(var t=1;t<arguments.length;t++){var n=arguments[t]!=null?arguments[t]:{};
54t%2?Cu(Object(n),!0).forEach(function(r){wy(e,r,n[r])}):Object.getOwnPropertyDescriptors?Object.defineProperties(e,Object.getOwnPropertyDescriptors(n)):Cu(Object(n)).forEach(function(r){Object.defineProperty(e,r,Object.getOwnPropertyDescriptor(n,r))})}return e}var xy=class If{constructor(t,{headers:n={},schema:r,fetch:s,timeout:i,urlLengthLimit:o=8e3}={}){this.url=t,this.headers=new Headers(n),this.schemaName=r,this.urlLengthLimit=o;const l=s??globalThis.fetch;i!==void 0&&i>0?this.fetch=(c,u)=>{const d=new AbortController,f=setTimeout(()=>d.abort(),i),h=u==null?void 0:u.signal;if(h){if(h.aborted)return clearTimeout(f),l(c,u);const m=()=>{clearTimeout(f),d.abort()};return h.addEventListener("abort",m,{once:!0}),l(c,Bs(Bs({},u),{},{signal:d.signal})).finally(()=>{clearTimeout(f),h.removeEventListener("abort",m)})}return l(c,Bs(Bs({},u),{},{signal:d.signal})).finally(()=>clearTimeout(f))}:this.fetch=l}from(t){if(!t||typeof t!="string"||t.trim()==="")throw new Error("Invalid relation name: relation must be a non-empty string.");return new gy(new URL(`${this.url}/${t}`),{headers:new Headers(this.headers),schema:this.schemaName,fetch:this.fetch,urlLengthLimit:this.urlLengthLimit})}schema(t){return new If(this.url,{headers:this.headers,schema:t,fetch:this.fetch,urlLengthLimit:this.urlLengthLimit})}rpc(t,n={},{head:r=!1,get:s=!1,count:i}={}){var o;let l;const c=new URL(`${this.url}/rpc/${t}`);let u;const d=m=>m!==null&&typeof m=="object"&&(!Array.isArray(m)||m.some(d)),f=r&&Object.values(n).some(d);f?(l="POST",u=n):r||s?(l=r?"HEAD":"GET",Object.entries(n).filter(([m,v])=>v!==void 0).map(([m,v])=>[m,Array.isArray(v)?`{${v.join(",")}}`:`${v}`]).forEach(([m,v])=>{c.searchParams.append(m,v)})):(l="POST",u=n);const h=new Headers(this.headers);return f?h.set("Prefer",i?`count=${i},return=minimal`:"return=minimal"):i&&h.set("Prefer",`count=${i}`),new Nn({method:l,url:c,headers:h,schema:this.schemaName,body:u,fetch:(o=this.fetch)!==null&&o!==void 0?o:fetch,urlLengthLimit:this.urlLengthLimit})}};class by{constructor(){}static detectEnvironment(){var t;if(typeof WebSocket<"u")return{type:"native",constructor:WebSocket};if(typeof globalThis<"u"&&typeof globalThis.WebSocket<"u")return{type:"native",constructor:globalThis.WebSocket};if(typeof global<"u"&&typeof global.WebSocket<"u")return{type:"native",constructor:global.WebSocket};if(typeof globalThis<"u"&&typeof globalThis.WebSocketPair<"u"&&typeof globalThis.WebSocket>"u")return{type:"cloudflare",error:"Cloudflare Workers detected. WebSocket clients are not supported in Cloudflare Workers.",workaround:"Use Cloudflare Workers WebSocket API for server-side WebSocket handling, or deploy to a different runtime."};if(typeof globalThis<"u"&&globalThis.EdgeRuntime||typeof navigator<"u"&&(!((t=navigator.userAgent)===null||t===void 0)&&t.includes("Vercel-Edge")))return{type:"unsupported",error:"Edge runtime detected (Vercel Edge/Netlify Edge). WebSockets are not supported in edge functions.",workaround:"Use serverless functions or a different deployment target for WebSocket functionality."};const n=globalThis.process;if(n){const r=n.versions;if(r&&r.node){const s=r.node,i=parseInt(s.replace(/^v/,"").split(".")[0]);return i>=22?typeof globalThis.WebSocket<"u"?{type:"native",constructor:globalThis.WebSocket}:{type:"unsupported",error:`Node.js ${i} detected but native WebSocket not found.`,workaround:"Provide a WebSocket implementation via the transport option."}:{type:"unsupported",error:`Node.js ${i} detected without native WebSocket support.`,workaround:`For Node.js < 22, install "ws" package and provide it via the transport option:
55import ws from "ws"
56new 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+=`
57
58Suggested 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 _y="2.97.0",ky=`realtime-js/${_y}`,jy="1.0.0",Df="2.0.0",Tu=Df,Jo=1e4,Sy=1e3,Ny=100;var Ct;(function(e){e[e.connecting=0]="connecting",e[e.open=1]="open",e[e.closing=2]="closing",e[e.closed=3]="closed"})(Ct||(Ct={}));var ie;(function(e){e.closed="closed",e.errored="errored",e.joined="joined",e.joining="joining",e.leaving="leaving"})(ie||(ie={}));var Qe;(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"})(Qe||(Qe={}));var Qo;(function(e){e.websocket="websocket"})(Qo||(Qo={}));
58var rn;(function(e){e.Connecting="connecting",e.Open="open",e.Closing="closing",e.Closed="closed"})(rn||(rn={}));class Ey{constructor(t){this.HEADER_LENGTH=1,this.USER_BROADCAST_PUSH_META_LENGTH=6,this.KINDS={userBroadcastPush:3,userBroadcast:4},this.BINARY_ENCODING=0,this.JSON_ENCODING=1,this.BROADCAST_EVENT="broadcast",this.allowedMetadataKeys=[],this.allowedMetadataKeys=t??[]}encode(t,n){if(t.event===this.BROADCAST_EVENT&&!(t.payload instanceof ArrayBuffer)&&typeof t.payload.event=="string")return n(this._binaryEncodeUserBroadcastPush(t));let r=[t.join_ref,t.ref,t.topic,t.event,t.payload];return n(JSON.stringify(r))}_binaryEncodeUserBroadcastPush(t){var n;return this._isArrayBuffer((n=t.payload)===null||n===void 0?void 0:n.payload)?this._encodeBinaryUserBroadcastPush(t):this._encodeJsonUserBroadcastPush(t)}_encodeBinaryUserBroadcastPush(t){var n,r;const s=(r=(n=t.payload)===null||n===void 0?void 0:n.payload)!==null&&r!==void 0?r:new ArrayBuffer(0);return this._encodeUserBroadcastPush(t,this.BINARY_ENCODING,s)}_encodeJsonUserBroadcastPush(t){var n,r;const s=(r=(n=t.payload)===null||n===void 0?void 0:n.payload)!==null&&r!==void 0?r:{},o=new TextEncoder().encode(JSON.stringify(s)).buffer;return this._encodeUserBroadcastPush(t,this.JSON_ENCODING,o)}_encodeUserBroadcastPush(t,n,r){var s,i;const o=t.topic,l=(s=t.ref)!==null&&s!==void 0?s:"",c=(i=t.join_ref)!==null&&i!==void 0?i:"",u=t.payload.event,d=this.allowedMetadataKeys?this._pick(t.payload,this.allowedMetadataKeys):{},f=Object.keys(d).length===0?"":JSON.stringify(d);if(c.length>255)throw new Error(`joinRef length ${c.length} exceeds maximum of 255`);if(l.length>255)throw new Error(`ref length ${l.length} exceeds maximum of 255`);if(o.length>255)throw new Error(`topic length ${o.length} exceeds maximum of 255`);if(u.length>255)throw new Error(`userEvent length ${u.length} exceeds maximum of 255`);if(f.length>255)throw new Error(`metadata length ${f.length} exceeds maximum of 255`);const h=this.USER_BROADCAST_PUSH_META_LENGTH+c.length+l.length+o.length+u.length+f.length,m=new ArrayBuffer(this.HEADER_LENGTH+h);let v=new DataView(m),w=0;v.setUint8(w++,this.KINDS.userBroadcastPush),v.setUint8(w++,c.length),v.setUint8(w++,l.length),v.setUint8(w++,o.length),v.setUint8(w++,u.length),v.setUint8(w++,f.length),v.setUint8(w++,n),Array.from(c,y=>v.setUint8(w++,y.charCodeAt(0))),Array.from(l,y=>v.setUint8(w++,y.charCodeAt(0))),Array.from(o,y=>v.setUint8(w++,y.charCodeAt(0))),Array.from(u,y=>v.setUint8(w++,y.charCodeAt(0))),Array.from(f,y=>v.setUint8(w++,y.charCodeAt(0)));var b=new Uint8Array(m.byteLength+r.byteLength);return b.set(new Uint8Array(m),0),b.set(new Uint8Array(r),m.byteLength),b.buffer}decode(t,n){if(this._isArrayBuffer(t)){let r=this._binaryDecode(t);return n(r)}if(typeof t=="string"){const r=JSON.parse(t),[s,i,o,l,c]=r;return n({join_ref:s,ref:i,topic:o,event:l,payload:c})}return n({})}_binaryDecode(t){const n=new DataView(t),r=n.getUint8(0),s=new TextDecoder;switch(r){case this.KINDS.userBroadcast:return this._decodeUserBroadcast(t,n,s)}}_decodeUserBroadcast(t,n,r){const s=n.getUint8(1),i=n.getUint8(2),o=n.getUint8(3),l=n.getUint8(4);let c=this.HEADER_LENGTH+4;const u=r.decode(t.slice(c,c+s));c=c+s;const d=r.decode(t.slice(c,c+i));c=c+i;const f=r.decode(t.slice(c,c+o));c=c+o;const h=t.slice(c,t.byteLength),m=l===this.JSON_ENCODING?JSON.parse(r.decode(h)):h,v={type:this.BROADCAST_EVENT,event:d,payload:m};return o>0&&(v.meta=JSON.parse(f)),{join_ref:null,ref:null,topic:u,event:this.BROADCAST_EVENT,payload:v}}_isArrayBuffer(t){var n;return t instanceof ArrayBuffer||((n=t==null?void 0:t.constructor)===null||n===void 0?void 0:n.name)==="ArrayBuffer"}_pick(t,n){return!t||typeof t!="object"?{}:Object.fromEntries(Object.entries(t).filter(([r])=>n.includes(r)))}}class Ff{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 B;(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"})(B||(B={}));const Au=(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]=Cy(o,e,t,s),i),{}):{}},Cy=(e,t,n,r)=>{const s=t.find(l=>
58l.name===e),i=s==null?void 0:s.type,o=n[e];return i&&!r.includes(i)?Lf(i,o):Xo(o)},Lf=(e,t)=>{if(e.charAt(0)==="_"){const n=e.slice(1,e.length);return Ry(t,n)}switch(e){case B.bool:return Ty(t);case B.float4:case B.float8:case B.int2:case B.int4:case B.int8:case B.numeric:case B.oid:return Ay(t);case B.json:case B.jsonb:return Py(t);case B.timestamp:return Oy(t);case B.abstime:case B.date:case B.daterange:case B.int4range:case B.int8range:case B.money:case B.reltime:case B.text:case B.time:case B.timestamptz:case B.timetz:case B.tsrange:case B.tstzrange:return Xo(t);default:return Xo(t)}},Xo=e=>e,Ty=e=>{switch(e){case"t":return!0;case"f":return!1;default:return e}},Ay=e=>{if(typeof e=="string"){const t=parseFloat(e);if(!Number.isNaN(t))return t}return e},Py=e=>{if(typeof e=="string")try{return JSON.parse(e)}catch{return e}return e},Ry=(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(l=>Lf(t,l))}return e},Oy=e=>typeof e=="string"?e.replace(" ","T"):e,$f=e=>{const t=new URL(e);return t.protocol=t.protocol.replace(/^ws/i,"http"),t.pathname=t.pathname.replace(/\/+$/,"").replace(/\/socket\/websocket$/i,"").replace(/\/socket$/i,"").replace(/\/websocket$/i,""),t.pathname===""||t.pathname==="/"?t.pathname="/api/broadcast":t.pathname=t.pathname+"/api/broadcast",t.href};class Ma{constructor(t,n,r={},s=Jo){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 Pu;(function(e){e.SYNC="sync",e.JOIN="join",e.LEAVE="leave"})(Pu||(Pu={}));class Lr{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:l}=this.caller;this.joinRef=this.channel._joinRef(),this.state=Lr.syncState(this.state,s,i,o),this.pendingDiffs.forEach(c=>{this.state=Lr.syncDiff(this.state,c,i,o)}),this.pendingDiffs=[],l()}),this.channel._on(r.diff,{},s=>{const{onJoin:i,onLeave:o,onSync:l}=this.caller;this.inPendingSyncState()?this.pendingDiffs.push(s):(this.state=Lr.syncDiff(this.state,s,i,o),l())}),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),l={},c={};return this.map(i,(u,d)=>{o[u]||(c[u]=d)}),this.map(o,(u,d)=>{const f=i[u];if(f){const h=d.map(b=>b.presence_ref),m=f.map(b=>b.presence_ref),v=d.filter(b=>m.indexOf(b.presence_ref)<0),w=f.filter(b=>h.indexOf(b.presence_ref)<0);v.length>0&&(l[u]=v),w.length>0&&(c[u]=w)}else l[u]=d}),this.syncDiff(i,{joins:l,leaves:c},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,(l,c)=>{var u;
58const d=(u=t[l])!==null&&u!==void 0?u:[];if(t[l]=this.cloneDeep(c),d.length>0){const f=t[l].map(m=>m.presence_ref),h=d.filter(m=>f.indexOf(m.presence_ref)<0);t[l].unshift(...h)}r(l,d,c)}),this.map(o,(l,c)=>{let u=t[l];if(!u)return;const d=c.map(f=>f.presence_ref);u=u.filter(f=>d.indexOf(f.presence_ref)<0),t[l]=u,s(l,u,c),u.length===0&&delete t[l]}),t}static map(t,n){return Object.getOwnPropertyNames(t).map(r=>n(r,t[r]))}static transformState(t){return t=this.cloneDeep(t),Object.getOwnPropertyNames(t).reduce((n,r)=>{const 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 Ru;(function(e){e.ALL="*",e.INSERT="INSERT",e.UPDATE="UPDATE",e.DELETE="DELETE"})(Ru||(Ru={}));var $r;(function(e){e.BROADCAST="broadcast",e.PRESENCE="presence",e.POSTGRES_CHANGES="postgres_changes",e.SYSTEM="system"})($r||($r={}));var ht;(function(e){e.SUBSCRIBED="SUBSCRIBED",e.TIMED_OUT="TIMED_OUT",e.CLOSED="CLOSED",e.CHANNEL_ERROR="CHANNEL_ERROR"})(ht||(ht={}));class Hn{constructor(t,n={config:{}},r){var s,i;if(this.topic=t,this.params=n,this.socket=r,this.bindings={},this.state=ie.closed,this.joinedOnce=!1,this.pushBuffer=[],this.subTopic=t.replace(/^realtime:/i,""),this.params.config=Object.assign({broadcast:{ack:!1,self:!1},presence:{key:"",enabled:!1},private:!1},n.config),this.timeout=this.socket.timeout,this.joinPush=new Ma(this,Qe.join,this.params,this.timeout),this.rejoinTimer=new Ff(()=>this._rejoinUntilConnected(),this.socket.reconnectAfterMs),this.joinPush.receive("ok",()=>{this.state=ie.joined,this.rejoinTimer.reset(),this.pushBuffer.forEach(o=>o.send()),this.pushBuffer=[]}),this._onClose(()=>{this.rejoinTimer.reset(),this.socket.log("channel",`close ${this.topic} ${this._joinRef()}`),this.state=ie.closed,this.socket._remove(this)}),this._onError(o=>{this._isLeaving()||this._isClosed()||(this.socket.log("channel",`error ${this.topic}`,o),this.state=ie.errored,this.rejoinTimer.scheduleTimeout())}),this.joinPush.receive("timeout",()=>{this._isJoining()&&(this.socket.log("channel",`timeout ${this.topic}`,this.joinPush.timeout),this.state=ie.errored,this.rejoinTimer.scheduleTimeout())}),this.joinPush.receive("error",o=>{this._isLeaving()||this._isClosed()||(this.socket.log("channel",`error ${this.topic}`,o),this.state=ie.errored,this.rejoinTimer.scheduleTimeout())}),this._on(Qe.reply,{},(o,l)=>{this._trigger(this._replyEventName(l),o)}),this.presence=new Lr(this),this.broadcastEndpointURL=$f(this.socket.endPoint),this.private=this.params.config.private||!1,!this.private&&(!((i=(s=this.params.config)===null||s===void 0?void 0:s.broadcast)===null||i===void 0)&&i.replay))throw`tried to use replay on public channel '${this.topic}'. It must be a private channel.`}subscribe(t,n=this.timeout){var r,s,i;if(this.socket.isConnected()||this.socket.connect(),this.state==ie.closed){const{config:{broadcast:o,presence:l,private:c}}=this.params,u=(s=(r=this.bindings.postgres_changes)===null||r===void 0?void 0:r.map(m=>m.filter))!==null&&s!==void 0?s:[],d=!!this.bindings[$r.PRESENCE]&&this.bindings[$r.PRESENCE].length>0||((i=this.params.config.presence)===null||i===void 0?void 0:i.enabled)===!0,f={},h={broadcast:o,presence:Object.assign(Object.assign({},l),{enabled:d}),postgres_changes:u,private:c};this.socket.accessTokenValue&&(f.access_token=this.socket.accessTokenValue),this._onError(m=>t==null?void 0:t(ht.CHANNEL_ERROR,m)),this._onClose(()=>t==null?void 0:t(ht.CLOSED)),this.updateJoinPayload(Object.assign({config:h},f)),this.joinedOnce=!0,this._rejoin(n),this.joinPush.receive("ok",async({postgres_changes:m})=>{var v;if(this.socket._isManualToken()||this.socket.setAuth(),m===void 0){t==null||t(ht.SUBSCRIBED);return}else{const w=this.bindings.postgres_changes,b=(v=w==null?void 0:w.length)!==null&&v!==void 0?v:0,y=[];for(let p=0;p<b;p++){const g=w[p],{filter:{event:_,schema:j,table:S,filter:E}}=g,C=m&&m[p];if(C&&C.event===_&&Hn.isFilterValueEqual(C.schema,j)&&Hn.isFilterValueEqual(C.table,S)&&Hn.isFilterValueEqual(C.filter,E))y.push(Object.assign(Object.assign({},g),{id:C.id}));else{this.unsubscribe(),this.state=ie.errored,t==null||t(ht.CHANNEL_ERROR,new Error("mismatch between server and client bindings for postgres changes"));return}}this.bindings.postgres_changes=y,t&&t(ht.SUBSCRIBED);return}}).receive("error",m=>{this.state=ie.errored,t==null||t(ht.CHANNEL_ERROR,new Error(JSON.stringify(Object.values(m).join(", ")||"error")))}).receive("timeout",()=>{t==null||t(ht.TIMED_OUT)})}return this}presenceState(){return this.presence.state}async track(t,n={}){return await this.send({type:"presence",event:"track",payload:t},n.timeout||this.timeout)}async untrack(t={}){return await this.send({type:"presence",event:"untrack"},t)}on(t,n,r){return this.state===ie.joined&&t===$r.PRESENCE&&(this.socket.log("channel",`resubscribe to ${this.topic} due to change in presence callbacks on joined channel`),this.unsubscribe().then(async()=>await this.subscribe())),this._on(t,n,r)}async httpSend(t,n,r={}){var s;if(n==null)return Promise.reject("Payload is required for httpSend()");const i={apikey:this.socket.apiKey?this.socket.apiKey:"","Content-Type":"application/json"};this.socket.accessTokenValue&&(i.Authorization=`Bearer ${this.socket.accessTokenValue}`);const o={method:"POST",headers:i,body:JSON.stringify({messages:[{topic:this.subTopic,event:t,payload:n,private:this.private}]})},l=await this._fetchWithTimeout(this.broadcastEndpointURL,o,(s=r.timeout)!==null&&s!==void 0?s:this.timeout);if(l.status===202)return{success:!0};let c=l.statusText;
58try{const u=await l.json();c=u.error||u.message||c}catch{}return Promise.reject(new Error(c))}async send(t,n={}){var r,s;if(!this._canPush()&&t.type==="broadcast"){console.warn("Realtime send() is automatically falling back to REST API. This behavior will be deprecated in the future. Please use httpSend() explicitly for REST delivery.");const{event:i,payload:o}=t,l={apikey:this.socket.apiKey?this.socket.apiKey:"","Content-Type":"application/json"};this.socket.accessTokenValue&&(l.Authorization=`Bearer ${this.socket.accessTokenValue}`);const c={method:"POST",headers:l,body:JSON.stringify({messages:[{topic:this.subTopic,event:i,payload:o,private:this.private}]})};try{const u=await this._fetchWithTimeout(this.broadcastEndpointURL,c,(r=n.timeout)!==null&&r!==void 0?r:this.timeout);return await((s=u.body)===null||s===void 0?void 0:s.cancel()),u.ok?"ok":"error"}catch(u){return u.name==="AbortError"?"timed out":"error"}}else return new Promise(i=>{var o,l,c;const u=this._push(t.type,t,n.timeout||this.timeout);t.type==="broadcast"&&!(!((c=(l=(o=this.params)===null||o===void 0?void 0:o.config)===null||l===void 0?void 0:l.broadcast)===null||c===void 0)&&c.ack)&&i("ok"),u.receive("ok",()=>i("ok")),u.receive("error",()=>i("error")),u.receive("timeout",()=>i("timed out"))})}updateJoinPayload(t){this.joinPush.updatePayload(t)}unsubscribe(t=this.timeout){this.state=ie.leaving;const n=()=>{this.socket.log("channel",`leave ${this.topic}`),this._trigger(Qe.close,"leave",this._joinRef())};this.joinPush.destroy();let r=null;return new Promise(s=>{r=new Ma(this,Qe.leave,{},t),r.receive("ok",()=>{n(),s("ok")}).receive("timeout",()=>{n(),s("timed out")}).receive("error",()=>{s("error")}),r.send(),this._canPush()||r.trigger("ok",{})}).finally(()=>{r==null||r.destroy()})}teardown(){this.pushBuffer.forEach(t=>t.destroy()),this.pushBuffer=[],this.rejoinTimer.reset(),this.joinPush.destroy(),this.state=ie.closed,this.bindings={}}async _fetchWithTimeout(t,n,r){const s=new AbortController,i=setTimeout(()=>s.abort(),r),o=await this.socket.fetch(t,Object.assign(Object.assign({},n),{signal:s.signal}));return clearTimeout(i),o}_push(t,n,r=this.timeout){if(!this.joinedOnce)throw`tried to push '${t}' to '${this.topic}' before joining. Use channel.subscribe() before pushing events`;let s=new Ma(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>Ny){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:l,error:c,leave:u,join:d}=Qe;if(r&&[l,c,u,d].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(m=>{var v,w,b;return((v=m.filter)===null||v===void 0?void 0:v.event)==="*"||((b=(w=m.filter)===null||w===void 0?void 0:w.event)===null||b===void 0?void 0:b.toLocaleLowerCase())===o}).map(m=>m.callback(h,r)):(i=this.bindings[o])===null||i===void 0||i.filter(m=>{var v,w,b,y,p,g;if(["broadcast","presence","postgres_changes"].includes(o))if("id"in m){const _=m.id,j=(v=m.filter)===null||v===void 0?void 0:v.event;return _&&((w=n.ids)===null||w===void 0?void 0:w.includes(_))&&(j==="*"||(j==null?void 0:j.toLocaleLowerCase())===((b=n.data)===null||b===void 0?void 0:b.type.toLocaleLowerCase()))}else{const _=(p=(y=m==null?void 0:m.filter)===null||y===void 0?void 0:y.event)===null||p===void 0?void 0:p.toLocaleLowerCase();return _==="*"||_===((g=n==null?void 0:n.event)===null||g===void 0?void 0:g.toLocaleLowerCase())}else return m.type.toLocaleLowerCase()===o}).map(m=>{if(typeof h=="object"&&"ids"in h){const v=h.data,{schema:w,table:b,commit_timestamp:y,type:p,errors:g}=v;h=Object.assign(Object.assign({},{schema:w,table:b,commit_timestamp:y,eventType:p,new:{},old:{},errors:g}),this._getPayloadRecords(v))}m.callback(h,r)})}_isClosed(){return this.state===ie.closed}_isJoined(){return this.state===ie.joined}_isJoining(){return this.state===ie.joining}_isLeaving(){return this.state===ie.leaving}_replyEventName(t){return`chan_reply_${t}`}_on(t,n,r){const s=t.toLocaleLowerCase(),i={type:s,filter:n,callback:r};return this.bindings[s]?this.bindings[s].push(i):this.bindings[s]=[i],this}_off(t,n){const r=t.toLocaleLowerCase();return this.bindings[r]&&(this.bindings[r]=this.bindings[r].filter(s=>{var i;return!(((i=s.type)===null||i===void 0?void 0:i.toLocaleLowerCase())===r&&Hn.isEqual(s.filter,n))})),this}static isEqual(t,n){if(Object.keys(t).length!==Object.keys(n).length)return!1;for(const r in t)if(t[r]!==n[r])return!1;return!0}static isFilterValueEqual(t,n){return(t??void 0)===(n??void 0)}_rejoinUntilConnected(){this.rejoinTimer.scheduleTimeout(),this.socket.isConnected()&&this._rejoin()}_onClose(t){this._on(Qe.close,{},t)}_onError(t){this._on(Qe.error,{},n=>t(n))}_canPush(){return this.socket.isConnected()&&this._isJoined()}_rejoin(t=this.timeout){this._isLeaving()||(this.socket._leaveOpenTopic(this.topic),this.state=ie.joining,this.joinPush.resend(t))}_getPayloadRecords(t){const n={new:{},old:{}};return(t.type==="INSERT"||t.type==="UPDATE")&&(n.new=Au(t.columns,t.record)),(t.type==="UPDATE"||t.type==="DELETE")&&(n.old=Au(t.columns,t.old_record)),n}}const Ba=()=>{},Ws={HEARTBEAT_INTERVAL:25e3,RECONNECT_DELAY:10,HEARTBEAT_TIMEOUT_FALLBACK:100},Iy=[1e3,2e3,5e3,1e4],Dy=1e4,Fy=`
59  addEventListener("message", (e) => {
60    if (e.data.event === "start") {
61      setInterval(() => postMessage({ event: "keepAlive" }), e.data.interval);
62    }
63  });`;class Ly{constructor(t,n){var r;if(this.accessTokenValue=null,this.apiKey=null,this._manuallySetToken=!1,this.channels=new Array,this.endPoint="",this.httpEndpoint="",this.headers={},this.params={},this.timeout=Jo,this.transport=null,this.heartbeatIntervalMs=Ws.HEARTBEAT_INTERVAL,this.heartbeatTimer=void 0,this.pendingHeartbeatRef=null,this.heartbeatCallback=Ba,this.ref=0,this.reconnectTimer=null,this.vsn=Tu,this.logger=Ba,this.conn=null,this.sendBuffer=[],this.serializer
63=new Ey,this.stateChangeCallbacks={open:[],close:[],error:[],message:[]},this.accessToken=null,this._connectionState="disconnected",this._wasManualDisconnect=!1,this._authPromise=null,this._heartbeatSentAt=null,this._resolveFetch=s=>s?(...i)=>s(...i):(...i)=>fetch(...i),!(!((r=n==null?void 0:n.params)===null||r===void 0)&&r.apikey))throw new Error("API key is required to connect to Realtime");this.apiKey=n.params.apikey,this.endPoint=`${t}/${Qo.websocket}`,this.httpEndpoint=$f(t),this._initializeOptions(n),this._setupReconnectionTimer(),this.fetch=this._resolveFetch(n==null?void 0:n.fetch)}connect(){if(!(this.isConnecting()||this.isDisconnecting()||this.conn!==null&&this.isConnected())){if(this._setConnectionState("connecting"),this.accessToken&&!this._authPromise&&this._setAuthSafely("connect"),this.transport)this.conn=new this.transport(this.endpointURL());else try{this.conn=by.createWebSocket(this.endpointURL())}catch(t){this._setConnectionState("disconnected");const n=t.message;throw n.includes("Node.js")?new Error(`${n}
64
65To use Realtime in Node.js, you need to provide a WebSocket implementation:
66
67Option 1: Use Node.js 22+ which has native WebSocket support
68Option 2: Install and provide the "ws" package:
69
70  npm install ws
71
72  import ws from "ws"
73  const client = new RealtimeClient(url, {
74    ...options,
75    transport: ws
76  })`):new Error(`WebSocket not available: ${n}`)}this._setupConnectionHandlers()}}endpointURL(){return this._appendParams(this.endPoint,Object.assign({},this.params,{vsn:this.vsn}))}disconnect(t,n){if(!this.isDisconnecting())if(this._setConnectionState("disconnecting",!0),this.conn){const r=setTimeout(()=>{this._setConnectionState("disconnected")},100);this.conn.onclose=()=>{clearTimeout(r),this._setConnectionState("disconnected")},typeof this.conn.close=="function"&&(t?this.conn.close(t,n??""):this.conn.close()),this._teardownConnection()}else this._setConnectionState("disconnected")}getChannels(){return this.channels}async removeChannel(t){const n=await t.unsubscribe();return this.channels.length===0&&this.disconnect(),n}async removeAllChannels(){const t=await Promise.all(this.channels.map(n=>n.unsubscribe()));return this.channels=[],this.disconnect(),t}log(t,n,r){this.logger(t,n,r)}connectionState(){switch(this.conn&&this.conn.readyState){case Ct.connecting:return rn.Connecting;case Ct.open:return rn.Open;case Ct.closing:return rn.Closing;default:return rn.Closed}}isConnected(){return this.connectionState()===rn.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 Hn(`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,l=>{var c;(c=this.conn)===null||c===void 0||c.send(l)})};this.log("push",`${n} ${r} (${i})`,s),this.isConnected()?o():this.sendBuffer.push(o)}async setAuth(t=null){this._authPromise=this._performAuth(t);try{await this._authPromise}finally{this._authPromise=null}}_isManualToken(){return this._manuallySetToken}async sendHeartbeat(){var t;if(!this.isConnected()){try{this.heartbeatCallback("disconnected")}catch(n){this.log("error","error in heartbeat callback",n)}return}if(this.pendingHeartbeatRef){this.pendingHeartbeatRef=null,this._heartbeatSentAt=null,this.log("transport","heartbeat timeout. Attempting to re-establish connection");try{this.heartbeatCallback("timeout")}catch(n){this.log("error","error in heartbeat callback",n)}this._wasManualDisconnect=!1,(t=this.conn)===null||t===void 0||t.close(Sy,"heartbeat timeout"),setTimeout(()=>{var n;this.isConnected()||(n=this.reconnectTimer)===null||n===void 0||n.scheduleTimeout()},Ws.HEARTBEAT_TIMEOUT_FALLBACK);return}this._heartbeatSentAt=Date.now(),this.pendingHeartbeatRef=this._makeRef(),this.push({topic:"phoenix",event:"heartbeat",payload:{},ref:this.pendingHeartbeatRef});try{this.heartbeatCallback("sent")}catch(n){this.log("error","error in heartbeat callback",n)}this._setAuthSafely("heartbeat")}onHeartbeat(t){this.heartbeatCallback=t}flushSendBuffer(){this.isConnected()&&this.sendBuffer.length>0&&(this.sendBuffer.forEach(t=>t()),this.sendBuffer=[])}_makeRef(){let t=this.ref+1;return t===this.ref?this.ref=0:this.ref=t,this.ref.toString()}_leaveOpenTopic(t){let n=this.channels.find(r=>r.topic===t&&(r._isJoined()||r._isJoining()));n&&(this.log("transport",`leaving duplicate topic "${t}"`),n.unsubscribe())}_remove(t){this.channels=this.channels.filter(n=>n.topic!==t.topic)}_onConnMessage(t){this.decode(t.data,n=>
76{if(n.topic==="phoenix"&&n.event==="phx_reply"&&n.ref&&n.ref===this.pendingHeartbeatRef){const u=this._heartbeatSentAt?Date.now()-this._heartbeatSentAt:void 0;try{this.heartbeatCallback(n.payload.status==="ok"?"ok":"error",u)}catch(d){this.log("error","error in heartbeat callback",d)}this._heartbeatSentAt=null,this.pendingHeartbeatRef=null}const{topic:r,event:s,payload:i,ref:o}=n,l=o?`(${o})`:"",c=i.status||"";this.log("receive",`${c} ${r} ${s} ${l}`.trim(),i),this.channels.filter(u=>u._isMember(r)).forEach(u=>u._trigger(s,i,o)),this._triggerStateCallbacks("message",n)})}_clearTimer(t){var n;t==="heartbeat"&&this.heartbeatTimer?(clearInterval(this.heartbeatTimer),this.heartbeatTimer=void 0):t==="reconnect"&&((n=this.reconnectTimer)===null||n===void 0||n.reset())}_clearAllTimers(){this._clearTimer("heartbeat"),this._clearTimer("reconnect")}_setupConnectionHandlers(){this.conn&&("binaryType"in this.conn&&(this.conn.binaryType="arraybuffer"),this.conn.onopen=()=>this._onConnOpen(),this.conn.onerror=t=>this._onConnError(t),this.conn.onmessage=t=>this._onConnMessage(t),this.conn.onclose=t=>this._onConnClose(t),this.conn.readyState===Ct.open&&this._onConnOpen())}_teardownConnection(){if(this.conn){if(this.conn.readyState===Ct.open||this.conn.readyState===Ct.connecting)try{this.conn.close()}catch(t){this.log("error","Error closing connection",t)}this.conn.onopen=null,this.conn.onerror=null,this.conn.onmessage=null,this.conn.onclose=null,this.conn=null}this._clearAllTimers(),this._terminateWorker(),this.channels.forEach(t=>t.teardown())}_onConnOpen(){this._setConnectionState("connected"),this.log("transport",`connected to ${this.endpointURL()}`),(this._authPromise||(this.accessToken&&!this.accessTokenValue?this.setAuth():Promise.resolve())).then(()=>{this.flushSendBuffer()}).catch(n=>{this.log("error","error waiting for auth on connect",n),this.flushSendBuffer()}),this._clearTimer("reconnect"),this.worker?this.workerRef||this._startWorkerHeartbeat():this._startHeartbeat(),this._triggerStateCallbacks("open")}_startHeartbeat(){this.heartbeatTimer&&clearInterval(this.heartbeatTimer),this.heartbeatTimer=setInterval(()=>this.sendHeartbeat(),this.heartbeatIntervalMs)}_startWorkerHeartbeat(){this.workerUrl?this.log("worker",`starting worker for from ${this.workerUrl}`):this.log("worker","starting default worker");const t=this._workerObjectUrl(this.workerUrl);this.workerRef=new Worker(t),this.workerRef.onerror=n=>{this.log("worker","worker error",n.message),this._terminateWorker()},this.workerRef.onmessage=n=>{n.data.event==="keepAlive"&&this.sendHeartbeat()},this.workerRef.postMessage({event:"start",interval:this.heartbeatIntervalMs})}_terminateWorker(){this.workerRef&&(this.log("worker","terminating worker"),this.workerRef.terminate(),this.workerRef=void 0)}_onConnClose(t){var n;this._setConnectionState("disconnected"),this.log("transport","close",t),this._triggerChanError(),this._clearTimer("heartbeat"),this._wasManualDisconnect||(n=this.reconnectTimer)===null||n===void 0||n.scheduleTimeout(),this._triggerStateCallbacks("close",t)}_onConnError(t){this._setConnectionState("disconnected"),this.log("transport",`${t}`),this._triggerChanError(),this._triggerStateCallbacks("error",t);try{this.heartbeatCallback("error")}catch(n){this.log("error","error in heartbeat callback",n)}}_triggerChanError(){this.channels.forEach(t=>t._trigger(Qe.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([Fy],{type:"application/javascript"});n=URL.createObjectURL(r)}return n}_setConnectionState(t,n=!1){this._connectionState=t,t==="connecting"?this._wasManualDisconnect=!1:t==="disconnecting"&&(this._wasManualDisconnect=n)}async _performAuth(t=null){let n,r=!1;if(t)n=t,r=!0;else if(this.accessToken)try{n=await this.accessToken()}catch(s){this.log("error","Error fetching access token from callback",s),n=this.accessTokenValue}else n=this.accessTokenValue;r?this._manuallySetToken=!0:this.accessToken&&(this._manuallySetToken=!1),this.accessTokenValue!=n&&(this.accessTokenValue=n,this.channels.forEac
76h(s=>{const i={access_token:n,version:ky};n&&s.updateJoinPayload(i),s.joinedOnce&&s._isJoined()&&s._push(Qe.access_token,{access_token:n})}))}async _waitForAuthIfNeeded(){this._authPromise&&await this._authPromise}_setAuthSafely(t="general"){this._isManualToken()||this.setAuth().catch(n=>{this.log("error",`Error setting auth in ${t}`,n)})}_triggerStateCallbacks(t,n){try{this.stateChangeCallbacks[t].forEach(r=>{try{r(n)}catch(s){this.log("error",`error in ${t} callback`,s)}})}catch(r){this.log("error",`error triggering ${t} callbacks`,r)}}_setupReconnectionTimer(){this.reconnectTimer=new Ff(async()=>{setTimeout(async()=>{await this._waitForAuthIfNeeded(),this.isConnected()||this.connect()},Ws.RECONNECT_DELAY)},this.reconnectAfterMs)}_initializeOptions(t){var n,r,s,i,o,l,c,u,d,f,h,m;switch(this.transport=(n=t==null?void 0:t.transport)!==null&&n!==void 0?n:null,this.timeout=(r=t==null?void 0:t.timeout)!==null&&r!==void 0?r:Jo,this.heartbeatIntervalMs=(s=t==null?void 0:t.heartbeatIntervalMs)!==null&&s!==void 0?s:Ws.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=(l=t==null?void 0:t.heartbeatCallback)!==null&&l!==void 0?l:Ba,this.vsn=(c=t==null?void 0:t.vsn)!==null&&c!==void 0?c:Tu,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=(u=t==null?void 0:t.reconnectAfterMs)!==null&&u!==void 0?u:v=>Iy[v-1]||Dy,this.vsn){case jy:this.encode=(d=t==null?void 0:t.encode)!==null&&d!==void 0?d:(v,w)=>w(JSON.stringify(v)),this.decode=(f=t==null?void 0:t.decode)!==null&&f!==void 0?f:(v,w)=>w(JSON.parse(v));break;case Df:this.encode=(h=t==null?void 0:t.encode)!==null&&h!==void 0?h:this.serializer.encode.bind(this.serializer),this.decode=(m=t==null?void 0:t.decode)!==null&&m!==void 0?m:this.serializer.decode.bind(this.serializer);break;default:throw new Error(`Unsupported serializer version: ${this.vsn}`)}if(this.worker){if(typeof window<"u"&&!window.Worker)throw new Error("Web Worker is not supported");this.workerUrl=t==null?void 0:t.workerUrl}}}var is=class extends Error{constructor(e,t){var n;super(e),this.name="IcebergError",this.status=t.status,this.icebergType=t.icebergType,this.icebergCode=t.icebergCode,this.details=t.details,this.isCommitStateUnknown=t.icebergType==="CommitStateUnknownException"||[500,502,504].includes(t.status)&&((n=t.icebergType)==null?void 0:n.includes("CommitState"))===!0}isNotFound(){return this.status===404}isConflict(){return this.status===409}isAuthenticationTimeout(){return this.status===419}};function $y(e,t,n){const r=new URL(t,e);if(n)for(const[s,i]of Object.entries(n))i!==void 0&&r.searchParams.set(s,i);return r.toString()}async function Uy(e){return!e||e.type==="none"?{}:e.type==="bearer"?{Authorization:`Bearer ${e.token}`}:e.type==="header"?{[e.name]:e.value}:e.type==="custom"?await e.getHeaders():{}}function zy(e){const t=e.fetchImpl??globalThis.fetch;return{async request({method:n,path:r,query:s,body:i,headers:o}){const l=$y(e.baseUrl,r,s),c=await Uy(e.auth),u=await t(l,{method:n,headers:{...i?{"Content-Type":"application/json"}:{},...c,...o},body:i?JSON.stringify(i):void 0}),d=await u.text(),f=(u.headers.get("content-type")||"").includes("application/json"),h=f&&d?JSON.parse(d):d;if(!u.ok){const m=f?h:void 0,v=m==null?void 0:m.error;throw new is((v==null?void 0:v.message)??`Request failed with status ${u.status}`,{status:u.status,icebergType:v==null?void 0:v.type,icebergCode:v==null?void 0:v.code,details:m})}return{status:u.status,headers:u.headers,data:h}}}}function Hs(e){return e.join("�")}var My=class{constructor(e,t=""){this.client=e,this.prefix=t}async listNamespaces(e){const t=e?{parent:Hs(e.namespace)}:void 0;return(await this.client.request({method:"GET",path:`${this.prefix}/namespaces`,query:t})).data.namespaces.map(r=>({namespace:r}))}async createNamespace(e,t){const n={namespace:e.namespace,properties:t==null?void 0:t.properties};return(await this.client.request({method:"POST",path:`${this.prefix}/namespaces`,body:n})).data}async dropNamespace(e){await this.client.request({method:"DELETE",path:`${this.prefix}/namespaces/${Hs(e.namespace)}`})}async loadNamespaceMetadata(e){return{properties:(await this.client.request({method:"GET",path:`${this.prefix}/namespaces/${Hs(e.namespace)}`})).data.properties}}async namespaceExists(e){try{return await this.client.request({method:"HEAD",path:`${this.prefix}/namespaces/${Hs(e.namespace)}`}),!0}catch(t){if(t instanceof is&&t.status===404)return!1;throw t}}async createNamespaceIfNotExists(e,t){try{return await this.createNamespace(e,t)}catch(n){if(n instanceof is&&n.status===409)return;throw n}}};function xn(e){return e.join("�")}var By=class{constructor(e,t="",n){this.client=e,this.prefix=t,this.accessDelegation=n}async listTables(e){return(await this.client.request({method:"GET",path:`${this.prefix}/namespaces/${xn(e.namespace)}/tables`})).data.identifiers}async createTable(e,t){const n={};return this.accessDelegation&&(n["X-Iceberg-Access-Delegation"]=this.accessDelegation),(await this.client.request({method:"POST",path:`${this.prefix}/namespaces/${xn(e.namespace)}/tables`,body:t,headers:n})).data.metadata}async updateTable(e,t){const n=await this.client.request({method:"POST",path:`${this.prefix}/namespaces/${xn(e.namespace)}/tables/${e.name}`,body:t});return{"metadata-location":n.data["metadata-location"],metadata:n.data.metadata}}async dropTable(e,t){await this.client.request({method:"DELETE",path:`${this.prefix}/namespaces/${xn(e.namespace)}/tables/${e.name}`,query:{purgeRequested:String((t==null?void 0:t.purge)??!1)}})}async loadTable(e){const t={};return this.accessDelegation&&(t["X-Iceberg-Access-Delegation"]=this.accessDelegation),(await this.client.request({method:"GET",path:`${this.prefix}/namespaces/${xn(e.namespace)}/tables/${e.name}`,headers:t})).data.metadata}async tableExists(e){const t={};this.accessDelegation&&(t["X-Iceberg-Access-Delegation"]=this.accessDelegation);try{return await this.client.request({method:"HEAD",path:`${this.prefix}/namespaces/${xn(e.namespace)}/tables/${e.name}`,headers:t}),!0}catch(n){if(n instanceof is&&n.status===404)return!1;throw n}}async createTableIfNotExists(e,t){try{return await this.createTable(e,t)}catch(n){if(n instanceof is&&n.status===409)return await this.loadTable({namespace:e.namespace,name:t.name});throw n}}},Wy=class{constructor(e){var r;let t="v1";e.catalogName&&(t+=`/${e.catalogName}`);const n=e.baseUrl.endsWith("/")?e.baseUrl:`${e.baseUrl}/`;this.client=zy({baseUrl:n,auth:e.auth,fetchImpl:e.fetch}),this.accessDelegation=(r=e.accessDelegation)==null?void 0:r.join(","),this.namespaceOps=new My(this.client,t),this.tableOps=new By(this.client,t,this.accessDelegation)}async listNamespaces(e){return this.namespaceOps.listNamespaces(e)}async createNamespace(e,t){return this.namespaceOps.createNamespace(e,t)}async dropNamespace(e){await this.namespaceOps.dropNamespace(e)}async loadNamespaceMetadata(e){return this.namespaceOps.loadNamespaceMetadata(e)}async listTables(e){return this.tableOps.listTables(e)}
76async createTable(e,t){return this.tableOps.createTable(e,t)}async updateTable(e,t){return this.tableOps.updateTable(e,t)}async dropTable(e,t){await this.tableOps.dropTable(e,t)}async loadTable(e){return this.tableOps.loadTable(e)}async namespaceExists(e){return this.namespaceOps.namespaceExists(e)}async tableExists(e){return this.tableOps.tableExists(e)}async createNamespaceIfNotExists(e,t){return this.namespaceOps.createNamespaceIfNotExists(e,t)}async createTableIfNotExists(e,t){return this.tableOps.createTableIfNotExists(e,t)}},sa=class extends Error{constructor(e,t="storage",n,r){super(e),this.__isStorageError=!0,this.namespace=t,this.name=t==="vectors"?"StorageVectorsError":"StorageError",this.status=n,this.statusCode=r}};function ia(e){return typeof e=="object"&&e!==null&&"__isStorageError"in e}var Vs=class extends sa{constructor(e,t,n,r="storage"){super(e,r,t,n),this.name=r==="vectors"?"StorageVectorsApiError":"StorageApiError",this.status=t,this.statusCode=n}toJSON(){return{name:this.name,message:this.message,status:this.status,statusCode:this.statusCode}}},Uf=class extends sa{constructor(e,t,n="storage"){super(e,n),this.name=n==="vectors"?"StorageVectorsUnknownError":"StorageUnknownError",this.originalError=t}};const Hy=e=>e?(...t)=>e(...t):(...t)=>fetch(...t),Vy=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)},Zo=e=>{if(Array.isArray(e))return e.map(n=>Zo(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]=Zo(r)}),t},qy=e=>!e||typeof e!="string"||e.length===0||e.length>100||e.trim()!==e||e.includes("/")||e.includes("\\")?!1:/^[\w!.\*'() &$@=;:+,?-]+$/.test(e);function as(e){"@babel/helpers - typeof";return as=typeof Symbol=="function"&&typeof Symbol.iterator=="symbol"?function(t){return typeof t}:function(t){return t&&typeof Symbol=="function"&&t.constructor===Symbol&&t!==Symbol.prototype?"symbol":typeof t},as(e)}function Gy(e,t){if(as(e)!="object"||!e)return e;var n=e[Symbol.toPrimitive];if(n!==void 0){var r=n.call(e,t||"default");if(as(r)!="object")return r;throw new TypeError("@@toPrimitive must return a primitive value.")}return(t==="string"?String:Number)(e)}function Ky(e){var t=Gy(e,"string");return as(t)=="symbol"?t:t+""}function Yy(e,t,n){return(t=Ky(t))in e?Object.defineProperty(e,t,{value:n,enumerable:!0,configurable:!0,writable:!0}):e[t]=n,e}function Ou(e,t){var n=Object.keys(e);if(Object.getOwnPropertySymbols){var r=Object.getOwnPropertySymbols(e);t&&(r=r.filter(function(s){return Object.getOwnPropertyDescriptor(e,s).enumerable})),n.push.apply(n,r)}return n}function O(e){for(var t=1;t<arguments.length;t++){var n=arguments[t]!=null?arguments[t]:{};t%2?Ou(Object(n),!0).forEach(function(r){Yy(e,r,n[r])}):Object.getOwnPropertyDescriptors?Object.defineProperties(e,Object.getOwnPropertyDescriptors(n)):Ou(Object(n)).forEach(function(r){Object.defineProperty(e,r,Object.getOwnPropertyDescriptor(n,r))})}return e}const Iu=e=>{var t;return e.msg||e.message||e.error_description||(typeof e.error=="string"?e.error:(t=e.error)===null||t===void 0?void 0:t.message)||JSON.stringify(e)},Jy=async(e,t,n,r)=>{if(e&&typeof e=="object"&&"status"in e&&"ok"in e&&typeof e.status=="number"&&!(n!=null&&n.noResolveJson)){const s=e,i=s.status||500;if(typeof s.json=="function")s.json().then(o=>{const l=(o==null?void 0:o.statusCode)||(o==null?void 0:o.code)||i+"";t(new Vs(Iu(o),i,l,r))}).catch(()=>{if(r==="vectors"){const o=i+"";t(new Vs(s.statusText||`HTTP ${i} error`,i,o,r))}else{const o=i+"";t(new Vs(s.statusText||`HTTP ${i} error`,i,o,r))}});else{const o=i+"";t(new Vs(s.statusText||`HTTP ${i} error`,i,o,r))}}else t(new Uf(Iu(e),e,r))},Qy=(e,t,n,r)=>{const s={method:e,headers:(t==null?void 0:t.headers)||{}};return e==="GET"||e==="HEAD"||!r?O(O({},s),n):(Vy(r)?(s.headers=O({"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),O(O({},s),n))};async function _r(e,t,n,r,s,i,o){return new Promise((l,c)=>{e(n,Qy(t,r,s,i)).then(u=>{if(!u.ok)throw u;if(r!=null&&r.noResolveJson)return u;if(o==="vectors"){const d=u.headers.get("content-type");if(u.headers.get("content-length")==="0"||u.status===204)return{};if(!d||!d.includes("application/json"))return{}}return u.json()}).then(u=>l(u)).catch(u=>Jy(u,c,r,o))})}function zf(e="storage"){return{get:async(t,n,r,s)=>_r(t,"GET",n,r,s,void 0,e),post:async(t,n,r,s,i)=>_r(t,"POST",n,s,i,r,e),put:async(t,n,r,s,i)=>_r(t,"PUT",n,s,i,r,e),head:async(t,n,r,s)=>_r(t,"HEAD",n,O(O({},r),{},{noResolveJson:!0}),s,void 0,e),remove:async(t,n,r,s,i)=>_r(t,"DELETE",n,s,i,r,e)}}const Xy=zf("storage"),{get:os,post:Ye,put:el,head:Zy,remove:ac}=Xy,Oe=zf("vectors");var dr=class{constructor(e,t={},n,r="storage"){this.shouldThrowOnError=!1,this.url=e,this.headers=t,this.fetch=Hy(n),this.namespace=r}throwOnError(){return this.shouldThrowOnError=!0,this}setHeader(e,t){return this.headers=O(O({},this.headers),{},{[e]:t}),this}async handleOperation(e){var t=this;try{return{data:await e(),error:null}}catch(n){if(t.shouldThrowOnError)throw n;if(ia(n))return{data:null,error:n};throw n}}},ev=class{constructor(e,t){this.downloadFn=e,this.shouldThrowOnError=t}then(e,t){return this.execute().then(e,t)}async execute(){var e=this;try{return{data:(await e.downloadFn()).body,error:null}}catch(t){if(e.shouldThrowOnError)throw t;if(ia(t))return{data:null,error:t};throw t}}};let Mf;Mf=Symbol.toStringTag;var tv=class{constructor(e,t){this.downloadFn=e,this.shouldThrowOnError=t,this[Mf]="BlobDownloadBuilder",this.promise=null}asStream(){return new ev(this.downloadFn,this.shouldThrowOnError)}then(e,t){return this.getPromise().then(e,t)}catch(e){return this.getPromise().catch(e)}finally(e){return this.getPromise().finally(e)}getPromise(){return this.promise||(this.promise=this.execute()),this.promise}async execute(){var e=this;try{return{data:await(await e.downloadFn()).blob(),error:null}}catch(t){if(e.shouldThrowOnError)throw t;if(ia(t))return{data:null,error:t};throw t}}};const nv={limit:100,offset:0,sortBy:{column:"name",order:"asc"}},Du={cacheControl:"3600",contentType:"text/plain;charset=UTF-8",upsert:!1};var rv=class extends dr{constructor(e,t={},n,r){super(e,t,r,"storage"),this.bucketId=n}async uploadOrUpdate(e,t,n,r){var s=this;return s.handleOperation(async()=>{let i;const o=O(O({},Du),r);let l=O(O({},s.headers),e==="POST"&&{"x-upsert":String(o.upsert)});const c=o.metadata;typeof Blob<"u"&&n instanceof Blob?(i=new FormData,i.append("cacheControl",o.cacheControl),c&&i.append("metadata",s.encodeMetadata(c)),i.append("",n)):typeof FormData<"u"&&n instanceof FormData?(i=n,i.has("cacheControl")||i.append("cacheControl",o.cacheControl),c&&!i.has("metadata")&&i.append("metadata",s.encodeMetadata(c))):(i=n,l["cache-control"]=`max-age=${o.cacheControl}`,l["content-type"]=o.contentType,c&&(l["x-metadata"]=s.toBase64(s.encodeMetadata(c))),(typeof ReadableStream<"u"&&i instanceof ReadableStream||i&&typeof i=="object"&&"pipe"in i&&typeof i.pipe=="function")&&!o.duplex&&(o.duplex="half")),r!=null&&r.headers&&(l=O(O({},l),r.headers));const u=s._removeEmptyFolders(t),d=s._getFinalPath(u),f=await(e=="PUT"?el:Ye)(s.fetch,`${s.url}/object/${d}`,i,O({headers:l},o!=null&&o.duplex?{duplex:o.duplex}:{}));return{path:u,id:f.Id,fullPath:f.Key}})}async upload(e,t,n){return this.uploadOrUpdate("POST",e,t,n)}async uploadToSignedUrl(e,t,n,r){var s=this;const i=s._removeEmptyFolders(e),o=s._getFinalPath(i),l=new URL(s.url+`/object/upload/sign/${o}`);return l.searchParams.set("token",t),s.handleOperation(async()=>{let c;const u=O({upsert:Du.upsert},r),d=O(O({},s.headers),{"x-upsert":String(u.upsert)});return typeof Blob<"u"&&n instanceof Blob?(c=new FormData,c.append("cacheControl",u.cacheControl),c.append("",n)):typeof FormData<"u"&&n instanceof FormData?(c=n,c.append("cacheControl",u.cacheControl)):(c=n,d["cache-control"]=`max-age=${u.cacheControl}`,d["content-type"]=u.contentType),{path:i,fullPath:(await el(s.fetch,l.toString(),c,{headers:d})).Key}})}async createSignedUploadUrl(e,t){var n=this;return n.handleOperation(async()=>{let r=n._getFinalPath(e);const s=O({},n.headers);t!=null&&t.upsert&&(s["x-upsert"]="true");const i=await Ye(n.fetch,`${n.url}/object/upload/sign/${r}`,{},{headers:s}),o=new URL(n.url+i.url),l=o.searchParams.get("token");if(!l)throw new sa("No token returned by API");return{signedUrl:o.toString(),path:e,token:l}})}async update(e,t,n){return this.uploadOrUpdate("PUT",e,t,n)}async move(e,t,n){var r=this;return r.handleOperation(async()=>await Ye(r.fetch,`${r.url}/object/move`,{bucketId:r.bucketId,sourceKey:e,destinationKey:t,de
76stinationBucket:n==null?void 0:n.destinationBucket},{headers:r.headers}))}async copy(e,t,n){var r=this;return r.handleOperation(async()=>({path:(await Ye(r.fetch,`${r.url}/object/copy`,{bucketId:r.bucketId,sourceKey:e,destinationKey:t,destinationBucket:n==null?void 0:n.destinationBucket},{headers:r.headers})).Key}))}async createSignedUrl(e,t,n){var r=this;return r.handleOperation(async()=>{let s=r._getFinalPath(e),i=await Ye(r.fetch,`${r.url}/object/sign/${s}`,O({expiresIn:t},n!=null&&n.transform?{transform:n.transform}:{}),{headers:r.headers});const o=n!=null&&n.download?`&download=${n.download===!0?"":n.download}`:"";return{signedUrl:encodeURI(`${r.url}${i.signedURL}${o}`)}})}async createSignedUrls(e,t,n){var r=this;return r.handleOperation(async()=>{const s=await Ye(r.fetch,`${r.url}/object/sign/${r.bucketId}`,{expiresIn:t,paths:e},{headers:r.headers}),i=n!=null&&n.download?`&download=${n.download===!0?"":n.download}`:"";return s.map(o=>O(O({},o),{},{signedUrl:o.signedURL?encodeURI(`${r.url}${o.signedURL}${i}`):null}))})}download(e,t,n){const r=typeof(t==null?void 0:t.transform)<"u"?"render/image/authenticated":"object",s=this.transformOptsToQueryString((t==null?void 0:t.transform)||{}),i=s?`?${s}`:"",o=this._getFinalPath(e),l=()=>os(this.fetch,`${this.url}/${r}/${o}${i}`,{headers:this.headers,noResolveJson:!0},n);return new tv(l,this.shouldThrowOnError)}async info(e){var t=this;const n=t._getFinalPath(e);return t.handleOperation(async()=>Zo(await os(t.fetch,`${t.url}/object/info/${n}`,{headers:t.headers})))}async exists(e){var t=this;const n=t._getFinalPath(e);try{return await Zy(t.fetch,`${t.url}/object/${n}`,{headers:t.headers}),{data:!0,error:null}}catch(r){if(t.shouldThrowOnError)throw r;if(ia(r)&&r instanceof Uf){const s=r.originalError;if([400,404].includes(s==null?void 0:s.status))return{data:!1,error:r}}throw r}}getPublicUrl(e,t){const n=this._getFinalPath(e),r=[],s=t!=null&&t.download?`download=${t.download===!0?"":t.download}`:"";s!==""&&r.push(s);const i=typeof(t==null?void 0:t.transform)<"u"?"render/image":"object",o=this.transformOptsToQueryString((t==null?void 0:t.transform)||{});o!==""&&r.push(o);let l=r.join("&");return l!==""&&(l=`?${l}`),{data:{publicUrl:encodeURI(`${this.url}/${i}/public/${n}${l}`)}}}async remove(e){var t=this;return t.handleOperation(async()=>await ac(t.fetch,`${t.url}/object/${t.bucketId}`,{prefixes:e},{headers:t.headers}))}async list(e,t,n){var r=this;return r.handleOperation(async()=>{const s=O(O(O({},nv),t),{},{prefix:e||""});return await Ye(r.fetch,`${r.url}/object/list/${r.bucketId}`,s,{headers:r.headers},n)})}async listV2(e,t){var n=this;return n.handleOperation(async()=>{const r=O({},e);return await Ye(n.fetch,`${n.url}/object/list-v2/${n.bucketId}`,r,{headers:n.headers},t)})}encodeMetadata(e){return JSON.stringify(e)}toBase64(e){return typeof Buffer<"u"?Buffer.from(e).toString("base64"):btoa(e)}_getFinalPath(e){return`${this.bucketId}/${e.replace(/^\/+/,"")}`}_removeEmptyFolders(e){return e.replace(/^\/|\/$/g,"").replace(/\/+/g,"/")}transformOptsToQueryString(e){const t=[];return e.width&&t.push(`width=${e.width}`),e.height&&t.push(`height=${e.height}`),e.resize&&t.push(`resize=${e.resize}`),e.format&&t.push(`format=${e.format}`),e.quality&&t.push(`quality=${e.quality}`),t.join("&")}};const sv="2.97.0",bs={"X-Client-Info":`storage-js/${sv}`};var iv=class extends dr{constructor(e,t={},n,r){const s=new URL(e);r!=null&&r.useNewHostname&&/supabase\.(co|in|red)$/.test(s.hostname)&&!s.hostname.includes("storage.supabase.")&&(s.hostname=s.hostname.replace("supabase.","storage.supabase."));const i=s.href.replace(/\/$/,""),o=O(O({},bs),t);super(i,o,n,"storage")}async listBuckets(e){var t=this;return t.handleOperation(async()=>{const n=t.listBucketOptionsToQueryString(e);return await os(t.fetch,`${t.url}/bucket${n}`,{headers:t.headers})})}async getBucket(e){var t=this;return t.handleOperation(async()=>await os(t.fetch,`${t.url}/bucket/${e}`,{headers:t.headers}))}async createBucket(e,t={public:!1}){var n=this;return n.handleOperation(async()=>await Ye(n.fetch,`${n.url}/bucket`,{id:e,name:e,type:t.type,public:t.public,file_size_limit:t.fileSizeLimit,allowed_mime_types:t.allowedMimeTypes},{headers:n.headers}))}async updateBucket(e,t){var n=this;return n.handleOperation(async()=>await el(n.fetch,`${n.url}/bucket/${e}`,{id:e,name:e,public:t.public,file_size_limit:t.fileSizeLimit,allowed_mime_types:t.allowedMimeTypes},{headers:n.headers}))}async emptyBucket(e){var t=this;return t.handleOperation(async()=>await Ye(t.fetch,`${t.url}/bucket/${e}/empty`,{},{headers:t.headers}))}async deleteBucket(e){var t=this;return t.handleOperation(async()=>await ac(t.fetch,`${t.url}/bucket/${e}`,{},{headers:t.headers}))}listBucketOptionsToQueryString(e){const t={};return e&&("limit"in e&&(t.limit=String(e.limit)),"offset"in e&&(t.offset=String(e.offset)),e.search&&(t.search=e.search),e.sortColumn&&(t.sortColumn=e.sortColumn),e.sortOrder&&(t.sortOrder=e.sortOrder)),Object.keys(t).length>0?"?"+new URLSearchParams(t).toString():""}},av=class extends dr{constructor(e,t={},n){const r=e.replace(/\/$/,""),s=O(O({},bs),t);super(r,s,n,"storage")}async createBucket(e){var t=this;return t.handleOperation(async()=>await Ye(t.fetch,`${t.url}/bucket`,{name:e},{headers:t.headers}))}async listBuckets(e){var t=this;return t.handleOperation(async()=>{const n=new URLSearchParams;(e==null?void 0:e.limit)!==void 0&&n.set("limit",e.limit.toString()),(e==null?void 0:e.offset)!==void 0&&n.set("offset",e.offset.toString()),e!=null&&e.sortColumn&&n.set("sortColumn",e.sortColumn),e!=null&&e.sortOrder&&n.set("sortOrder",e.sortOrder),e!=null&&e.search&&n.set("search",e.search);const r=n.toString(),s=r?`${t.url}/bucket?${r}`:`${t.url}/bucket`;return await os(t.fetch,s,{headers:t.headers})})}async deleteBucket(e){var t=this;return t.handleOperation(async()=>await ac(t.fetch,`${t.url}/bucket/${e}`,{},{headers:t.headers}))}from(e){var t=this;if(!qy(e))throw new sa("Invalid bucket name: File, folder, and bucket names must follow AWS object key naming guidelines and should avoid the use of any other characters.");const n=new Wy({baseUrl:this.url,catalogName:e,auth:{type:"custom",getHeaders:async()=>t.headers},fetch:this.fetch}
76),r=this.shouldThrowOnError;return new Proxy(n,{get(s,i){const o=s[i];return typeof o!="function"?o:async(...l)=>{try{return{data:await o.apply(s,l),error:null}}catch(c){if(r)throw c;return{data:null,error:c}}}}})}},ov=class extends dr{constructor(e,t={},n){const r=e.replace(/\/$/,""),s=O(O({},bs),{},{"Content-Type":"application/json"},t);super(r,s,n,"vectors")}async createIndex(e){var t=this;return t.handleOperation(async()=>await Oe.post(t.fetch,`${t.url}/CreateIndex`,e,{headers:t.headers})||{})}async getIndex(e,t){var n=this;return n.handleOperation(async()=>await Oe.post(n.fetch,`${n.url}/GetIndex`,{vectorBucketName:e,indexName:t},{headers:n.headers}))}async listIndexes(e){var t=this;return t.handleOperation(async()=>await Oe.post(t.fetch,`${t.url}/ListIndexes`,e,{headers:t.headers}))}async deleteIndex(e,t){var n=this;return n.handleOperation(async()=>await Oe.post(n.fetch,`${n.url}/DeleteIndex`,{vectorBucketName:e,indexName:t},{headers:n.headers})||{})}},lv=class extends dr{constructor(e,t={},n){const r=e.replace(/\/$/,""),s=O(O({},bs),{},{"Content-Type":"application/json"},t);super(r,s,n,"vectors")}async putVectors(e){var t=this;if(e.vectors.length<1||e.vectors.length>500)throw new Error("Vector batch size must be between 1 and 500 items");return t.handleOperation(async()=>await Oe.post(t.fetch,`${t.url}/PutVectors`,e,{headers:t.headers})||{})}async getVectors(e){var t=this;return t.handleOperation(async()=>await Oe.post(t.fetch,`${t.url}/GetVectors`,e,{headers:t.headers}))}async listVectors(e){var t=this;if(e.segmentCount!==void 0){if(e.segmentCount<1||e.segmentCount>16)throw new Error("segmentCount must be between 1 and 16");if(e.segmentIndex!==void 0&&(e.segmentIndex<0||e.segmentIndex>=e.segmentCount))throw new Error(`segmentIndex must be between 0 and ${e.segmentCount-1}`)}return t.handleOperation(async()=>await Oe.post(t.fetch,`${t.url}/ListVectors`,e,{headers:t.headers}))}async queryVectors(e){var t=this;return t.handleOperation(async()=>await Oe.post(t.fetch,`${t.url}/QueryVectors`,e,{headers:t.headers}))}async deleteVectors(e){var t=this;if(e.keys.length<1||e.keys.length>500)throw new Error("Keys batch size must be between 1 and 500 items");return t.handleOperation(async()=>await Oe.post(t.fetch,`${t.url}/DeleteVectors`,e,{headers:t.headers})||{})}},cv=class extends dr{constructor(e,t={},n){const r=e.replace(/\/$/,""),s=O(O({},bs),{},{"Content-Type":"application/json"},t);super(r,s,n,"vectors")}async createBucket(e){var t=this;return t.handleOperation(async()=>await Oe.post(t.fetch,`${t.url}/CreateVectorBucket`,{vectorBucketName:e},{headers:t.headers})||{})}async getBucket(e){var t=this;return t.handleOperation(async()=>await Oe.post(t.fetch,`${t.url}/GetVectorBucket`,{vectorBucketName:e},{headers:t.headers}))}async listBuckets(e={}){var t=this;return t.handleOperation(async()=>await Oe.post(t.fetch,`${t.url}/ListVectorBuckets`,e,{headers:t.headers}))}async deleteBucket(e){var t=this;return t.handleOperation(async()=>await Oe.post(t.fetch,`${t.url}/DeleteVectorBucket`,{vectorBucketName:e},{headers:t.headers})||{})}},uv=class extends cv{constructor(e,t={}){super(e,t.headers||{},t.fetch)}from(e){return new dv(this.url,this.headers,e,this.fetch)}async createBucket(e){var t=()=>super.createBucket,n=this;return t().call(n,e)}async getBucket(e){var t=()=>super.getBucket,n=this;return t().call(n,e)}async listBuckets(e={}){var t=()=>super.listBuckets,n=this;return t().call(n,e)}async deleteBucket(e){var t=()=>super.deleteBucket,n=this;return t().call(n,e)}},dv=class extends ov{constructor(e,t,n,r){super(e,t,r),this.vectorBucketName=n}async createIndex(e){var t=()=>super.createIndex,n=this;return t().call(n,O(O({},e),{},{vectorBucketName:n.vectorBucketName}))}async listIndexes(e={}){var t=()=>super.listIndexes,n=this;return t().call(n,O(O({},e),{},{vectorBucketName:n.vectorBucketName}))}async getIndex(e){var t=()=>super.getIndex,n=this;return t().call(n,n.vectorBucketName,e)}async deleteIndex(e){var t=()=>super.deleteIndex,n=this;return t().call(n,n.vectorBucketName,e)}index(e){return new hv(this.url,this.headers,this.vectorBucketName,e,this.fetch)}}
76,hv=class extends lv{constructor(e,t,n,r,s){super(e,t,s),this.vectorBucketName=n,this.indexName=r}async putVectors(e){var t=()=>super.putVectors,n=this;return t().call(n,O(O({},e),{},{vectorBucketName:n.vectorBucketName,indexName:n.indexName}))}async getVectors(e){var t=()=>super.getVectors,n=this;return t().call(n,O(O({},e),{},{vectorBucketName:n.vectorBucketName,indexName:n.indexName}))}async listVectors(e={}){var t=()=>super.listVectors,n=this;return t().call(n,O(O({},e),{},{vectorBucketName:n.vectorBucketName,indexName:n.indexName}))}async queryVectors(e){var t=()=>super.queryVectors,n=this;return t().call(n,O(O({},e),{},{vectorBucketName:n.vectorBucketName,indexName:n.indexName}))}async deleteVectors(e){var t=()=>super.deleteVectors,n=this;return t().call(n,O(O({},e),{},{vectorBucketName:n.vectorBucketName,indexName:n.indexName}))}},fv=class extends iv{constructor(e,t={},n,r){super(e,t,n,r)}from(e){return new rv(this.url,this.headers,e,this.fetch)}get vectors(){return new uv(this.url+"/vector",{headers:this.headers,fetch:this.fetch})}get analytics(){return new av(this.url+"/iceberg",this.headers,this.fetch)}};const Bf="2.97.0",En=30*1e3,tl=3,Wa=tl*En,pv="http://localhost:9999",mv="supabase.auth.token",gv={"X-Client-Info":`gotrue-js/${Bf}`},nl="X-Supabase-Api-Version",Wf={"2024-01-01":{timestamp:Date.parse("2024-01-01T00:00:00.0Z"),name:"2024-01-01"}},yv=/^([a-z0-9_-]{4})*($|[a-z0-9_-]{3}$|[a-z0-9_-]{2}$)$/i,vv=10*60*1e3;class ls extends Error{constructor(t,n,r){super(t),this.__isAuthError=!0,this.name="AuthError",this.status=n,this.code=r}}function R(e){return typeof e=="object"&&e!==null&&"__isAuthError"in e}class wv extends ls{constructor(t,n,r){super(t,n,r),this.name="AuthApiError",this.status=n,this.code=r}}function xv(e){return R(e)&&e.name==="AuthApiError"}class sn extends ls{constructor(t,n){super(t),this.name="AuthUnknownError",this.originalError=n}}class jt extends ls{constructor(t,n,r,s){super(t,r,s),this.name=n,this.status=r}}class Pe extends jt{constructor(){super("Auth session missing!","AuthSessionMissingError",400,void 0)}}function Ha(e){return R(e)&&e.name==="AuthSessionMissingError"}class bn extends jt{constructor(){super("Auth session or user missing","AuthInvalidToken
76ResponseError",500,void 0)}}class qs extends jt{constructor(t){super(t,"AuthInvalidCredentialsError",400,void 0)}}class Gs extends jt{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 bv(e){return R(e)&&e.name==="AuthImplicitGrantRedirectError"}class Fu extends jt{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 _v extends jt{constructor(){super("PKCE code verifier not found in storage. This can happen if the auth flow was initiated in a different browser or device, or if the storage was cleared. For SSR frameworks (Next.js, SvelteKit, etc.), use @supabase/ssr on both the server and client to store the code verifier in cookies.","AuthPKCECodeVerifierMissingError",400,"pkce_code_verifier_not_found")}}class rl extends jt{constructor(t,n){super(t,"AuthRetryableFetchError",n,void 0)}}function Va(e){return R(e)&&e.name==="AuthRetryableFetchError"}class Lu extends jt{constructor(t,n,r){super(t,"AuthWeakPasswordError",n,"weak_password"),this.reasons=r}}class sl extends jt{constructor(t){super(t,"AuthInvalidJwtError",400,"invalid_jwt")}}const Ii="ABCDEFGHIJKLMNOPQRSTUVWXYZabcdefghijklmnopqrstuvwxyz0123456789-_".split(""),$u=` 	
77\r=`.split(""),kv=(()=>{const e=new Array(128);for(let t=0;t<e.length;t+=1)e[t]=-1;for(let t=0;t<$u.length;t+=1)e[$u[t].charCodeAt(0)]=-2;for(let t=0;t<Ii.length;t+=1)e[Ii[t].charCodeAt(0)]=t;return e})();function Uu(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(Ii[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(Ii[r]),t.queuedBits-=6}}function Hf(e,t,n){const r=kv[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 zu(e){const t=[],n=o=>{t.push(String.fromCodePoint(o))},r={utf8seq:0,codepoint:0},s={queue:0,queuedBits:0},i=o=>{Nv(o,r,n)};for(let o=0;o<e.length;o+=1)Hf(e.charCodeAt(o),s,i);return t.join("")}function jv(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 Sv(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}jv(r,t)}}function Nv(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 Qn(e){const t=[],n={queue:0,queuedBits:0},r=s=>{t.push(s)};for(let s=0;s<e.length;s+=1)Hf(e.charCodeAt(s),n,r);return new Uint8Array(t)}function Ev(e){const t=[];return Sv(e,n=>t.push(n)),new Uint8Array(t)}function cn(e){const t=[],n={queue:0,queuedBits:0},r=s=>{t.push(s)};return e.forEach(s=>Uu(s,n,r)),Uu(null,n,r),t.join("")}function Cv(e){return Math.round(Date.now()/1e3)+e}function Tv(){return Symbol("auth-callback")}const he=()=>typeof window<"u"&&typeof document<"u",Qt={tested:!1,writable:!1},Vf=()=>{if(!he())return!1;try{if(typeof globalThis.localStorage!="object")return!1}catch{return!1}if(Qt.tested)return Qt.writable;const e=`lswt-${Math.random()}${Math.random()}`;try{globalThis.localStorage.setItem(e,e),globalThis.localStorage.removeItem(e),Qt.tested=!0,Qt.writable=!0}catch{Qt.tested=!0,Qt.writable=!1}return Qt.writable};function Av(e){const t={},n=new URL(e);if(n.hash&&n.hash[0]==="#")try{new URLSearchParams(n.hash.substring(1)).forEac
77h((s,i)=>{t[i]=s})}catch{}return n.searchParams.forEach((r,s)=>{t[s]=r}),t}const qf=e=>e?(...t)=>e(...t):(...t)=>fetch(...t),Pv=e=>typeof e=="object"&&e!==null&&"status"in e&&"ok"in e&&"json"in e&&typeof e.json=="function",Cn=async(e,t,n)=>{await e.setItem(t,JSON.stringify(n))},Xt=async(e,t)=>{const n=await e.getItem(t);if(!n)return null;try{return JSON.parse(n)}catch{return n}},de=async(e,t)=>{await e.removeItem(t)};class aa{constructor(){this.promise=new aa.promiseConstructor((t,n)=>{this.resolve=t,this.reject=n})}}aa.promiseConstructor=Promise;function Ks(e){const t=e.split(".");if(t.length!==3)throw new sl("Invalid JWT structure");for(let r=0;r<t.length;r++)if(!yv.test(t[r]))throw new sl("JWT not in base64url format");return{header:JSON.parse(zu(t[0])),payload:JSON.parse(zu(t[1])),signature:Qn(t[2]),raw:{header:t[0],payload:t[1]}}}async function Rv(e){return await new Promise(t=>{setTimeout(()=>t(null),e)})}function Ov(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 Iv(e){return("0"+e.toString(16)).substr(-2)}function Dv(){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,Iv).join("")}async function Fv(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 Lv(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 Fv(e);return btoa(n).replace(/\+/g,"-").replace(/\//g,"_").replace(/=+$/,"")}async function _n(e,t,n=!1){const r=Dv();let s=r;n&&(s+="/PASSWORD_RECOVERY"),await Cn(e,`${t}-code-verifier`,s);const i=await Lv(r);return[i,r===i?"plain":"s256"]}const $v=/^2[0-9]{3}-(0[1-9]|1[0-2])-(0[1-9]|1[0-9]|2[0-9]|3[0-1])$/i;function Uv(e){const t=e.headers.get(nl);if(!t||!t.match($v))return null;try{return new Date(`${t}T00:00:00.0Z`)}catch{return null}}function zv(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 Mv(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 Bv=/^[0-9a-f]{8}-[0-9a-f]{4}-[0-9a-f]{4}-[0-9a-f]{4}-[0-9a-f]{12}$/;function kn(e){if(!Bv.test(e))throw new Error("@supabase/auth-js: Expected parameter to be UUID but is not")}function qa(){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 Wv(e,t){return new Proxy(e,{get:(n,r,s)=>{if(r==="__isInsecureUserWarningProxy")return!0;if(typeof r=="symbol"){const i=r.toString();if(i==="Symbol(Symbol.toPrimitive)"||i==="Symbol(Symbol.toStringTag)"||i==="Symbol(util.inspect.custom)"||i==="Symbol(nodejs.util.inspect.custom)")return Reflect.get(n,r,s)}return!t.value&&typeof r=="string"&&(console.warn("Using the user object as returned from supabase.auth.getSession() or from some supabase.auth.onAuthStateChange() events could be insecure! This value comes directly from the storage medium (usually cookies on the server) and may not be authentic. Use supabase.auth.getUser() instead which authenticates the data by contacting the Supabase Auth server."),t.value=!0),Reflect.get(n,r,s)}})}function Mu(e){return JSON.parse(JSON.stringify(e))}const nn=e=>e.msg||e.message||e.error_description||e.error||JSON.stringify(e),Hv=[502,503,504];async function Bu(e){var t;if(!Pv(e))throw new rl(nn(e),0);if(Hv.includes(e.status))throw new rl(nn(e),e.status);let n;try{n=await e.json()}catch(i){throw new sn(nn(i),i)}let r;const s=Uv(e);if(s&&s.getTime()>=Wf["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 Lu(nn(n),e.status,((t=n.weak_password)===null||t===void 0?void 0:t.reasons)||[]);if(r==="session_not_found")throw new Pe}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)=>
77i&&typeof o=="string",!0))throw new Lu(nn(n),e.status,n.weak_password.reasons);throw new wv(nn(n),e.status||500,r)}const Vv=(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 I(e,t,n,r){var s;const i=Object.assign({},r==null?void 0:r.headers);i[nl]||(i[nl]=Wf["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 l=Object.keys(o).length?"?"+new URLSearchParams(o).toString():"",c=await qv(e,t,n+l,{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(c):{data:Object.assign({},c),error:null}}async function qv(e,t,n,r,s,i){const o=Vv(t,r,s,i);let l;try{l=await e(n,Object.assign({},o))}catch(c){throw console.error(c),new rl(nn(c),0)}if(l.ok||await Bu(l),r!=null&&r.noResolveJson)return l;try{return await l.json()}catch(c){await Bu(c)}}function Ge(e){var t;let n=null;Yv(e)&&(n=Object.assign({},e),e.expires_at||(n.expires_at=Cv(e.expires_in)));const r=(t=e.user)!==null&&t!==void 0?t:e;return{data:{session:n,user:r},error:null}}function Wu(e){const t=Ge(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 Pt(e){var t;return{data:{user:(t=e.user)!==null&&t!==void 0?t:e},error:null}}function Gv(e){return{data:e,error:null}}function Kv(e){const{action_link:t,email_otp:n,hashed_token:r,redirect_to:s,verification_type:i}=e,o=ra(e,["action_link","email_otp","hashed_token","redirect_to","verification_type"]),l={action_link:t,email_otp:n,hashed_token:r,redirect_to:s,verification_type:i},c=Object.assign({},o);return{data:{properties:l,user:c},error:null}}function Hu(e){return e}function Yv(e){return e.access_token&&e.refresh_token&&e.expires_in}const Ga=["global","local","others"];class Jv{constructor({url:t="",headers:n={},fetch:r}){this.url=t,this.headers=n,this.fetch=qf(r),this.mfa={listFactors:this._listFactors.bind(this),deleteFactor:this._deleteFactor.bind(this)},this.oauth={listClients:this._listOAuthClients.bind(this),createClient:this._createOAuthClient.bind(this),getClient:this._getOAuthClient.bind(this),updateClient:this._updateOAuthClient.bind(this),deleteClient:this._deleteOAuthClient.bind(this),regenerateClientSecret:this._regenerateOAuthClientSecret.bind(this)}}async signOut(t,n=Ga[0]){if(Ga.indexOf(n)<0)throw new Error(`@supabase/auth-js: Parameter scope must be one of ${Ga.join(", ")}`);try{return await I(this.fetch,"POST",`${this.url}/logout?scope=${n}`,{headers:this.headers,jwt:t,noResolveJson:!0}),{data:null,error:null}}catch(r){if(R(r))return{data:null,error:r};throw r}}async inviteUserByEmail(t,n={}){try{return await I(this.fetch,"POST",`${this.url}/invite`,{body:{email:t,data:n.data},headers:this.headers,redirectTo:n.redirectTo,xform:Pt})}catch(r){if(R(r))return{data:{user:null},error:r};throw r}}async generateLink(t){try{const{options:n}=t,r=ra(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 I(this.fetch,"POST",`${this.url}/admin/generate_link`,{body:s,headers:this.headers,xform:Kv,redirectTo:n==null?void 0:n.redirectTo})}catch(n){if(R(n))return{data:{properties:null,user:null},error:n};throw n}}async createUser(t){try{return await I(this.fetch,"POST",`${this.url}/admin/users`,{body:t,headers:this.headers,xform:Pt})}catch(n){if(R(n))return{data:{user:null},error:n};throw n}}async listUsers(t){var n,r,s,i,o,l,c;try{const u={nextPage:null,lastPage:0,total:0},d=await I(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:Hu});if(d.error)throw d.error;const f=await d.json(),h=(o=d.headers.get("x-total-count"))!==null&&o!==void 0?o:0,m=(c=(l=d.headers.get("link"))===null||l===void 0?void 0:l.split(","))!==null&&c!==void 0?c:[];return m.length>0&&(m.forEach(v=>{const w=parseInt(v.split(";")[0].split("=")[1].substring(0,1)),b=JSON.parse(v.split(";")[1].split("=")[1]);u[`${b}Page`]=w}),u.total=parseInt(h)),{data:Object.assign(Object.assign({},f),u),error:null}}catch(u){if(R(u))return{data:{users:[]},error:u};throw u}}async getUserById(t){kn(t);try{return await I(this.fetch,"GET",`${this.url}/admin/users/${t}`,{headers:this.headers,xform:Pt})}catch(n){if(R(n))return{data:{user:null},error:n};throw n}}async updateUserById(t,n){kn(t);try{return await I(this.fetch,"PUT",`${this.url}/admin/users/${t}`,{body:n,headers:this.headers,xform:Pt})}catch(r){if(R(r))return{data:{user:null},error:r};throw r}}async deleteUser(t,n=!1){kn(t);
77try{return await I(this.fetch,"DELETE",`${this.url}/admin/users/${t}`,{headers:this.headers,body:{should_soft_delete:n},xform:Pt})}catch(r){if(R(r))return{data:{user:null},error:r};throw r}}async _listFactors(t){kn(t.userId);try{const{data:n,error:r}=await I(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(R(n))return{data:null,error:n};throw n}}async _deleteFactor(t){kn(t.userId),kn(t.id);try{return{data:await I(this.fetch,"DELETE",`${this.url}/admin/users/${t.userId}/factors/${t.id}`,{headers:this.headers}),error:null}}catch(n){if(R(n))return{data:null,error:n};throw n}}async _listOAuthClients(t){var n,r,s,i,o,l,c;try{const u={nextPage:null,lastPage:0,total:0},d=await I(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:Hu});if(d.error)throw d.error;const f=await d.json(),h=(o=d.headers.get("x-total-count"))!==null&&o!==void 0?o:0,m=(c=(l=d.headers.get("link"))===null||l===void 0?void 0:l.split(","))!==null&&c!==void 0?c:[];return m.length>0&&(m.forEach(v=>{const w=parseInt(v.split(";")[0].split("=")[1].substring(0,1)),b=JSON.parse(v.split(";")[1].split("=")[1]);u[`${b}Page`]=w}),u.total=parseInt(h)),{data:Object.assign(Object.assign({},f),u),error:null}}catch(u){if(R(u))return{data:{clients:[]},error:u};throw u}}async _createOAuthClient(t){try{return await I(this.fetch,"POST",`${this.url}/admin/oauth/clients`,{body:t,headers:this.headers,xform:n=>({data:n,error:null})})}catch(n){if(R(n))return{data:null,error:n};throw n}}async _getOAuthClient(t){try{return await I(this.fetch,"GET",`${this.url}/admin/oauth/clients/${t}`,{headers:this.headers,xform:n=>({data:n,error:null})})}catch(n){if(R(n))return{data:null,error:n};throw n}}async _updateOAuthClient(t,n){try{return await I(this.fetch,"PUT",`${this.url}/admin/oauth/clients/${t}`,{body:n,headers:this.headers,xform:r=>({data:r,error:null})})}catch(r){if(R(r))return{data:null,error:r};throw r}}async _deleteOAuthClient(t){try{return await I(this.fetch,"DELETE",`${this.url}/admin/oauth/clients/${t}`,{headers:this.headers,noResolveJson:!0}),{data:null,error:null}}catch(n){if(R(n))return{data:null,error:n};throw n}}async _regenerateOAuthClientSecret(t){try{return await I(this.fetch,"POST",`${this.url}/admin/oauth/clients/${t}/regenerate_secret`,{headers:this.headers,xform:n=>({data:n,error:null})})}catch(n){if(R(n))return{data:null,error:n};throw n}}}function Vu(e={}){return{getItem:t=>e[t]||null,setItem:(t,n)=>{e[t]=n},removeItem:t=>{delete e[t]}}}const jn={debug:!!(globalThis&&Vf()&&globalThis.localStorage&&globalThis.localStorage.getItem("supabase.gotrue-js.locks.debug")==="true")};class Gf extends Error{constructor(t){super(t),this.isAcquireTimeout=!0}}class qu extends Gf{}async function Qv(e,t,n){jn.debug&&console.log("@supabase/gotrue-js: navigatorLock: acquire lock",e,t);const r=new globalThis.AbortController;t>0&&setTimeout(()=>{r.abort(),jn.debug&&console.log("@supabase/gotrue-js: navigatorLock acquire timed out",e)},t),await Promise.resolve();try{return await globalThis.navigator.locks.request(e,t===0?{mode:"exclusive",ifAvailable:!0}:{mode:"exclusive",signal:r.signal},async s=>{if(s){jn.debug&&console.log("@supabase/gotrue-js: navigatorLock: acquired",e,s.name);try{return await n()}finally{jn.debug&&console.log("@supabase/gotrue-js: navigatorLock: released",e,s.name)}}else{if(t===0)throw jn.debug&&console.log("@supabase/gotrue-js: navigatorLock: not immediately available",e),new qu(`Acquiring an exclusive Navigator LockManager lock "${e}" immediately failed`);if(jn.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()}})}catch(s){throw(s==null?void 0:s.name)==="AbortError"?new qu(`Acquiring an exclusive Navigator LockManager lock "${e}" timed out waiting ${t}ms`):s}}
77function Xv(){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 Kf(e){if(!/^0x[a-fA-F0-9]{40}$/.test(e))throw new Error(`@supabase/auth-js: Address "${e}" is invalid.`);return e.toLowerCase()}function Zv(e){return parseInt(e,16)}function ew(e){const t=new TextEncoder().encode(e);return"0x"+Array.from(t,r=>r.toString(16).padStart(2,"0")).join("")}function tw(e){var t;const{chainId:n,domain:r,expirationTime:s,issuedAt:i=new Date,nonce:o,notBefore:l,requestId:c,resources:u,scheme:d,uri:f,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(!f)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(`
78`))throw new Error(`@supabase/auth-js: Invalid SIWE message field "statement". Statement must not include '\\n'. Provided value: ${e.statement}`)}const m=Kf(e.address),v=d?`${d}://${r}`:r,w=e.statement?`${e.statement}
79`:"",b=`${v} wants you to sign in with your Ethereum account:
80${m}
81
82${w}`;let y=`URI: ${f}
83Version: ${h}
84Chain ID: ${n}${o?`
85Nonce: ${o}`:""}
86Issued At: ${i.toISOString()}`;if(s&&(y+=`
87Expiration Time: ${s.toISOString()}`),l&&(y+=`
88Not Before: ${l.toISOString()}`),c&&(y+=`
89Request ID: ${c}`),u){let p=`
90Resources:`;for(const g of u){if(!g||typeof g!="string")throw new Error(`@supabase/auth-js: Invalid SIWE message field "resources". Every resource must be a valid string. Provided value: ${g}`);p+=`
91- ${g}`}y+=p}return`${b}
92${y}`}class re extends Error{constructor({message:t,code:n,cause:r,name:s}){var i;super(t,{cause:r}),this.__isWebAuthnError=!0,this.name=(i=s??(r instanceof Error?r.name:void 0))!==null&&i!==void 0?i:"Unknown Error",this.code=n}}class Di extends re{constructor(t,n){super({code:"ERROR_PASSTHROUGH_SEE_CAUSE_PROPERTY",cause:n,message:t}),this.name="WebAuthnUnknownError",this.originalError=n}}function nw({error:e,options:t}){var n,r,s;const{publicKey:i}=t;if(!i)throw Error("options was missing required publicKey property");if(e.name==="AbortError"){if(t.signal instanceof AbortSignal)return new re({message:"Registration ceremony was sent an abort signal",code:"ERROR_CEREMONY_ABORTED",cause:e})}else if(e.name==="ConstraintError"){if(((n=i.authenticatorSelection)===null||n===void 0?void 0:n.requireResidentKey)===!0)return new re({message:"Discoverable credentials were required but no available authenticator supported it",code:"ERROR_AUTHENTICATOR_MISSING_DISCOVERABLE_CREDENTIAL_SUPPORT",cause:e});if(t.mediation==="conditional"&&((r=i.authenticatorSelection)===null||r===void 0?void 0:r.userVerification)==="required")return new re({message:"User verification was required during automatic registration but it could not be performed",code:"ERROR_AUTO_REGISTER_USER_VERIFICATION_FAILURE",cause:e});if(((s=i.authenticatorSelection)===null||s===void 0?void 0:s.userVerification)==="required")return new re({message:"User verification was required but no available authenticator supported it",code:"ERROR_AUTHENTICATOR_MISSING_USER_VERIFICATION_SUPPORT",cause:e})}else{if(e.name==="InvalidStateError")return new re({message:"The authenticator was previously registered",code:"ERROR_AUTHENTICATOR_PREVIOUSLY_REGISTERED",cause:e});if(e.name==="NotAllowedError")return new re({message:e.message,code:"ERROR_PASSTHROUGH_SEE_CAUSE_PROPERTY",cause:e});if(e.name==="NotSupportedError")return i.pubKeyCredParams.filter(l=>l.type==="public-key").length===0?new re({message:'No entry in pubKeyCredParams was of type "public-key"',code:"ERROR_MALFORMED_PUBKEYCREDPARAMS",cause:e}):new re({message:"No available authenticator supported any of the specified pubKeyCredParams algorithms",code:"ERROR_AUTHENTICATOR_NO_SUPPORTED_PUBKEYCREDPARAMS_ALG",cause:e});if(e.name==="SecurityError"){const o=window.location.hostname;if(Yf(o)){if(i.rp.id!==o)return new re({message:`The RP ID "${i.rp.id}
92" is invalid for this domain`,code:"ERROR_INVALID_RP_ID",cause:e})}else return new re({message:`${window.location.hostname} is an invalid domain`,code:"ERROR_INVALID_DOMAIN",cause:e})}else if(e.name==="TypeError"){if(i.user.id.byteLength<1||i.user.id.byteLength>64)return new re({message:"User ID was not between 1 and 64 characters",code:"ERROR_INVALID_USER_ID_LENGTH",cause:e})}else if(e.name==="UnknownError")return new re({message:"The authenticator was unable to process the specified options, or could not create a new credential",code:"ERROR_AUTHENTICATOR_GENERAL_ERROR",cause:e})}return new re({message:"a Non-Webauthn related error has occurred",code:"ERROR_PASSTHROUGH_SEE_CAUSE_PROPERTY",cause:e})}function rw({error:e,options:t}){const{publicKey:n}=t;if(!n)throw Error("options was missing required publicKey property");if(e.name==="AbortError"){if(t.signal instanceof AbortSignal)return new re({message:"Authentication ceremony was sent an abort signal",code:"ERROR_CEREMONY_ABORTED",cause:e})}else{if(e.name==="NotAllowedError")return new re({message:e.message,code:"ERROR_PASSTHROUGH_SEE_CAUSE_PROPERTY",cause:e});if(e.name==="SecurityError"){const r=window.location.hostname;if(Yf(r)){if(n.rpId!==r)return new re({message:`The RP ID "${n.rpId}" is invalid for this domain`,code:"ERROR_INVALID_RP_ID",cause:e})}else return new re({message:`${window.location.hostname} is an invalid domain`,code:"ERROR_INVALID_DOMAIN",cause:e})}else if(e.name==="UnknownError")return new re({message:"The authenticator was unable to process the specified options, or could not create a new assertion signature",code:"ERROR_AUTHENTICATOR_GENERAL_ERROR",cause:e})}return new re({message:"a Non-Webauthn related error has occurred",code:"ERROR_PASSTHROUGH_SEE_CAUSE_PROPERTY",cause:e})}class sw{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 iw=new sw;function aw(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=ra(e,["challenge","user","excludeCredentials"]),i=Qn(t).buffer,o=Object.assign(Object.assign({},n),{id:Qn(n.id).buffer}),l=Object.assign(Object.assign({},s),{challenge:i,user:o});if(r&&r.length>0){l.excludeCredentials=new Array(r.length);for(let c=0;c<r.length;c++){const u=r[c];l.excludeCredentials[c]=Object.assign(Object.assign({},u),{id:Qn(u.id).buffer,type:u.type||"public-key",transports:u.transports})}}return l}function ow(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=ra(e,["challenge","allowCredentials"]),s=Qn(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 l=n[o];i.allowCredentials[o]=Object.assign(Object.assign({},l),{id:Qn(l.id).buffer,type:l.type||"public-key",transports:l.transports})}}return i}function lw(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:cn(new Uint8Array(e.response.attestationObject)),clientDataJSON:cn(new Uint8Array(e.response.clientDataJSON))},type:"public-key",clientExtensionResults:e.getClientExtensionResults(),authenticatorAttachment:(t=n.authenticatorAttachment)!==null&&t!==void 0?t:void 0}}function cw(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:cn(new Uint8Array(s.authenticatorData)),clientDataJSON:cn(new Uint8Array(s.clientDataJSON)),signature:cn(new Uint8Array(s.signature)),userHandle:s.userHandle?cn(new Uint8Array(s.userHandle)):void 0},type:"public-key",clientExtensionResults:r,authenticatorAttachment:(t=n.authenticatorAttachment)!==null&&t!==void 0?t:void 0}}function Yf(e){return e==="localhost"||/^([a-z0-9]+(-[a-z0-9]+)*\.)+[a-z]{2,}$/i.test(e)}function Gu(){var e,t;return!!(he()&&"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 uw(e){try{const t=await navigator.credentials.create(e);return t?t instanceof PublicKeyCredential?{data:t,error:null}:{data:null,error:new Di("Browser returned unexpected credential type",t)}:{data:null,error:new Di("Empty credential response",t)}}
92catch(t){return{data:null,error:nw({error:t,options:e})}}}async function dw(e){try{const t=await navigator.credentials.get(e);return t?t instanceof PublicKeyCredential?{data:t,error:null}:{data:null,error:new Di("Browser returned unexpected credential type",t)}:{data:null,error:new Di("Empty credential response",t)}}catch(t){return{data:null,error:rw({error:t,options:e})}}}const hw={hints:["security-key"],authenticatorSelection:{authenticatorAttachment:"cross-platform",requireResidentKey:!1,userVerification:"preferred",residentKey:"discouraged"},attestation:"direct"},fw={userVerification:"preferred",hints:["security-key"],attestation:"direct"};function Fi(...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 l=r[i];t(l)?r[i]=Fi(l,o):r[i]=Fi(o)}else r[i]=o}return r}function pw(e,t){return Fi(hw,e,t||{})}function mw(e,t){return Fi(fw,e,t||{})}class gw{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){var o;try{const{data:l,error:c}=await this.client.mfa.challenge({factorId:t,webauthn:n});if(!l)return{data:null,error:c};const u=s??iw.createNewAbortSignal();if(l.webauthn.type==="create"){const{user:d}=l.webauthn.credential_options.publicKey;if(!d.name){const f=r;if(f)d.name=`${d.id}:${f}`;else{const m=(await this.client.getUser()).data.user,v=((o=m==null?void 0:m.user_metadata)===null||o===void 0?void 0:o.name)||(m==null?void 0:m.email)||(m==null?void 0:m.id)||"User";d.name=`${d.id}:${v}`}}d.displayName||(d.displayName=d.name)}switch(l.webauthn.type){case"create":{const d=pw(l.webauthn.credential_options.publicKey,i==null?void 0:i.create),{data:f,error:h}=await uw({publicKey:d,signal:u});return f?{data:{factorId:t,challengeId:l.id,webauthn:{type:l.webauthn.type,credential_response:f}},error:null}:{data:null,error:h}}case"request":{const d=mw(l.webauthn.credential_options.publicKey,i==null?void 0:i.request),{data:f,error:h}=await dw(Object.assign(Object.assign({},l.webauthn.credential_options),{publicKey:d,signal:u}));return f?{data:{factorId:t,challengeId:l.id,webauthn:{type:l.webauthn.type,credential_response:f}},error:null}:{data:null,error:h}}}}catch(l){return R(l)?{data:null,error:l}:{data:null,error:new sn("Unexpected error in challenge",l)}}}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 ls("rpId is required for WebAuthn authentication")};try{if(!Gu())return{data:null,error:new sn("Browser does not support WebAuthn",null)};const{data:o,error:l}=await this.challenge({factorId:t,webauthn:{rpId:n,rpOrigins:r},signal:s},{request:i});if(!o)return{data:null,error:l};const{webauthn:c}=o;return this._verify({factorId:t,challengeId:o.challengeId,webauthn:{type:c.type,rpId:n,rpOrigins:r,credential_response:c.credential_response}})}catch(o){return R(o)?{data:null,error:o}:{data:null,error:new sn("Unexpected error in authenticate",o)}}}async _register({friendlyName:t,webauthn:{rpId:n=typeof window<"u"?window.location.hostname:void 0,rpOrigins:r=typeof window<"u"?[window.location.origin]:void 0,signal:s}={}},i){if(!n)return{data:null,error:new ls("rpId is required for WebAuthn registration")};try{if(!Gu())return{data:null,error:new sn("Browser does not support WebAuthn",null)};const{data:o,error:l}=await this._enroll({friendlyName:t});if(!o)return await this.client.mfa.listFactors().then(d=>{var f;return(f=d.data)===null||f===void 0?void 0:f.all.find(h=>h.factor_type==="webauthn"&&h.friendly_name===t&&h.status!=="unverified")}).then(d=>d?this.client.mfa.unenroll({factorId:d==null?void 0:d.id}):void 0),{data:null,error:l};const{data:c,error:u}=await this._challenge({factorId:o.id,friendlyName:o.friendly_name,webauthn:{rpId:n,rpOrigins:r},signal:s},{create:i});return c?this._verify({factorId:o.id,challengeId:c.challengeId,webauthn:{rpId:n,rpOrigins:r,type:c.webauthn.type,credential_response:c.webauthn.credential_response}}):{data:null,error:u}}catch(o){return R(o)?{data:null,error:o}:{data:null,error:new sn("Unexpected error in register",o)}}}}Xv();const yw={url:pv,storageKey:mv,autoRefreshToken:!0,persistSession:!0,detectSessionInUrl:!0,headers:gv,flowType:"implicit",debug:!1,hasCustomAuthorizationHeader:!1,throwOnError:!1,lockAcquireTimeout:1e4,skipAutoInitialize:!1};async function Ku(e,t,n){return await n()}const Sn={};class cs{get jwks(){var t,n;return(n=(t=Sn[this.storageKey])===null||t===void 0?void 0:t.jwks)!==null&&n!==void 0?n:{keys:[]}}set jwks(t){Sn[this.storageKey]=Object.assign(Object.assign({},Sn[this.storageKey]),{jwks:t})}get jwks_cached_at(){var t,n;return(n=(t=Sn[this.storageKey])===null||t===void 0?void 0:t.cachedAt)!==null&&n!==void 0?n:Number.MIN_SAFE_INTEGER}set jwks_cached_at(t){Sn[this.storageKey]=Object.assign(Object.assign({},Sn[this.storageKey]),{cachedAt:t})}constructor(t){var n,r,s;this.userStorage=null,this.memoryStorage=null,this.stateChangeEmitters=new Map,this.autoRefreshTicker=null,this.autoRefreshTickTimeout=null,this.visibilityChangedCallback=null,this.refreshingDeferred=null,this.initializePromise=null,this.detectSessionInUrl=!0,this.hasCustomAuthorizationHeader=!1,this.suppressGetSessionWarning=!1,this.lockAcquired=!1,this.pendingInLock=[],this.broadcastChannel=null,this.logger=console.log;const i=Object.assign(Object.assign({},yw),t);
92if(this.storageKey=i.storageKey,this.instanceID=(n=cs.nextInstanceID[this.storageKey])!==null&&n!==void 0?n:0,cs.nextInstanceID[this.storageKey]=this.instanceID+1,this.logDebugMessages=!!i.debug,typeof i.debug=="function"&&(this.logger=i.debug),this.instanceID>0&&he()){const o=`${this._logPrefix()} Multiple GoTrueClient instances detected in the same browser context. It is not an error, but this should be avoided as it may produce undefined behavior when used concurrently under the same storage key.`;console.warn(o),this.logDebugMessages&&console.trace(o)}if(this.persistSession=i.persistSession,this.autoRefreshToken=i.autoRefreshToken,this.admin=new Jv({url:i.url,headers:i.headers,fetch:i.fetch}),this.url=i.url,this.headers=i.headers,this.fetch=qf(i.fetch),this.lock=i.lock||Ku,this.detectSessionInUrl=i.detectSessionInUrl,this.flowType=i.flowType,this.hasCustomAuthorizationHeader=i.hasCustomAuthorizationHeader,this.throwOnError=i.throwOnError,this.lockAcquireTimeout=i.lockAcquireTimeout,i.lock?this.lock=i.lock:this.persistSession&&he()&&(!((r=globalThis==null?void 0:globalThis.navigator)===null||r===void 0)&&r.locks)?this.lock=Qv:this.lock=Ku,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 gw(this)},this.oauth={getAuthorizationDetails:this._getAuthorizationDetails.bind(this),approveAuthorization:this._approveAuthorization.bind(this),denyAuthorization:this._denyAuthorization.bind(this),listGrants:this._listOAuthGrants.bind(this),revokeGrant:this._revokeOAuthGrant.bind(this)},this.persistSession?(i.storage?this.storage=i.storage:Vf()?this.storage=globalThis.localStorage:(this.memoryStorage={},this.storage=Vu(this.memoryStorage)),i.userStorage&&(this.userStorage=i.userStorage)):(this.memoryStorage={},this.storage=Vu(this.memoryStorage)),he()&&globalThis.BroadcastChannel&&this.persistSession&&this.storageKey){try{this.broadcastChannel=new globalThis.BroadcastChannel(this.storageKey)}catch(o){console.error("Failed to create a new BroadcastChannel, multi-tab state changes will not be available",o)}(s=this.broadcastChannel)===null||s===void 0||s.addEventListener("message",async o=>{this._debug("received broadcast notification from other tab or client",o);try{await this._notifyAllSubscribers(o.data.event,o.data.session,!1)}catch(l){this._debug("#broadcastChannel","error",l)}})}i.skipAutoInitialize||this.initialize().catch(o=>{this._debug("#initialize()","error",o)})}isThrowOnErrorEnabled(){return this.throwOnError}_returnResult(t){if(this.throwOnError&&t&&t.error)throw t.error;return t}_logPrefix(){return`GoTrueClient@${this.storageKey}:${this.instanceID} (${Bf}) ${new Date().toISOString()}`}_debug(...t){return this.logDebugMessages&&this.logger(this._logPrefix(),...t),this}async initialize(){return this.initializePromise?await this.initializePromise:(this.initializePromise=(async()=>await this._acquireLock(this.lockAcquireTimeout,async()=>await this._initialize()))(),await this.initializePromise)}async _initialize(){var t;try{let n={},r="none";if(he()&&(n=Av(window.location.href),this._isImplicitGrantCallback(n)?r="implicit":await this._isPKCECallback(n)&&(r="pkce")),he()&&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),bv(i)){const c=(t=i.details)===null||t===void 0?void 0:t.code;if(c==="identity_already_exists"||c==="identity_not_found"||c==="single_identity_not_deletable")return{error:i}}return{error:i}}const{session:o,redirectType:l}=s;return this._debug("#_initialize()","detected session in URL",o,"redirect type",l),await this._saveSession(o),setTimeout(async()=>{l==="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 R(n)?this._returnResult({error:n}):this._returnResult({error:new sn("Unexpected error during initialization",n)})}finally{await this._handleVisibilityChange(),this._debug("#_initialize()","end")}}async signInAnonymously(t){var n,r,s;try{const i=await I(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:Ge}),{data:o,error:l}=i;if(l||!o)return this._returnResult({data:{user:null,session:null},error:l});const c=o.session,u=o.user;return o.session&&(await this._saveSession(o.session),await this._notifyAllSubscribers("SIGNED_IN",c)),this._returnResult({data:{user:u,session:c},error:null})}catch(i){if(R(i))return this._returnResult({data:{user:null,session:null},error:i});throw i}}async signUp(t){var n,r,s;try{let i;if("email"in t){const{email:d,password:f,options:h}=t;let m=null,v=null;this.flowType==="pkce"&&([m,v]=await _n(this.storage,this.storageKey)),i=await I(this.fetch,"POST",`${this.url}/signup`,{headers:this.headers,redirectTo:h==null?void 0:h.emailRedirectTo,body:{email:d,password:f,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:m,code_challenge_method:v},xform:Ge})}else if("phone"in t){const{phone:d,password:f,options:h}=t;i=await I(this.fetch,"POST",`${this.url}/signup`,{headers:this.headers,body:{phone:d,password:f,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:Ge})}else throw new qs("You must provide either an email or phone number and a password");const{data:o,error:l}=i;if(l||!o)return await de(this.storage,`${this.storageKey}-code-verifier`),this._returnResult({data:{user:null,session:null},error:l});const c=o.session,u=o.user;return o.session&&(await this._saveSession(o.session),await this._notifyAllSubscribers("SIGNED_IN",c)),this._returnResult({data:{user:u,session:c},error:null})}catch(i){if(await de(this.storage,`${this.storageKey}-code-verifier`),R(i))return this._returnResult({data:{user:null,session:null},error:i});throw i}}async signInWithPassword(t){try{let n;if("email"in t){const{email:i,password:o,options:l}=t;n=await I(this.fetch,"POST",`${this.url}/token?grant_type=password`,{headers:this.headers,body:{email:i,password:o,gotrue_meta_security:{captcha_token:l==null?void 0:l.captchaToken}},xform:Wu})}else if("phone"in t){const{phone:i,password:o,options:l}=t;n=await I(this.fetch,"POST",`${this.url}/token?grant_type=password`,{headers:this.headers,body:{phone:i,password:o,gotrue_meta_security:{captcha_token:l==null?void 0:l.captchaToken}},xform:Wu})}else throw new qs("You must provide either an email or phone number and a password");const{data:r,error:s}=n;if(s)return this._returnResult({data:{user:null,session:null},error:s});if(!r||!r.session||!r.user){const i=new bn;return this._returnResult({data:{user:null,session:null},error:i})}return r.session&&(await this._saveSession(r.session),await this._notifyAllSubscribers("SIGNED_IN",r.session)),this._returnResult({data:Object.assign({user:r.user,session:r.session},r.weak_password?{weakPassword:r.weak_password}:null),error:s})}catch(n){if(R(n))return this._returnResult({data:{user:null,session:null},error:n});throw n}}async signInWithOAuth(t){var n,r,s,i;return await this._handleProviderSignIn(t.provider,{redirectTo:(n=t.options)===null||n===void 0?void 0:n.redirectTo,scopes:(r=t.options)===null||r===void 0?void 0:r.scopes,queryParams:(s=t.options)===null||s===void 0?void 0:s.queryParams,skipBrowserRedirect:(i=t.options)===null||i===void 0?void 0:i.skipBrowserRedirect})}async exchangeCodeForSession(t){return await this.initializePromise,this._acquireLock(this.lockAcquireTimeout,async()=>this._exchangeCodeForSession(t))}async signInWithWeb3(t){const{chain:n}=t;switch(n){case"ethereum":return await this.signInWithEthereum(t);case"solana":return await this.signInWithSolana(t);default:throw new Error(`@supabase/auth-js: Unsupported chain "${n}"`)}}async signInWithEthereum(t){var n,r,s,i,o,l,c,u,d,f,h;let m,v;if("message"in t)m=t.message,v=t.signature;else{const{chain:w,wallet:b,statement:y,options:p}=t;let g;if(he())if(typeof b=="object")g=b;
92else{const k=window;if("ethereum"in k&&typeof k.ethereum=="object"&&"request"in k.ethereum&&typeof k.ethereum.request=="function")g=k.ethereum;else throw new Error("@supabase/auth-js: No compatible Ethereum wallet interface on the window object (window.ethereum) detected. Make sure the user already has a wallet installed and connected for this app. Prefer passing the wallet interface object directly to signInWithWeb3({ chain: 'ethereum', wallet: resolvedUserWallet }) instead.")}else{if(typeof b!="object"||!(p!=null&&p.url))throw new Error("@supabase/auth-js: Both wallet and url must be specified in non-browser environments.");g=b}const _=new URL((n=p==null?void 0:p.url)!==null&&n!==void 0?n:window.location.href),j=await g.request({method:"eth_requestAccounts"}).then(k=>k).catch(()=>{throw new Error("@supabase/auth-js: Wallet method eth_requestAccounts is missing or invalid")});if(!j||j.length===0)throw new Error("@supabase/auth-js: No accounts available. Please ensure the wallet is connected.");const S=Kf(j[0]);let E=(r=p==null?void 0:p.signInWithEthereum)===null||r===void 0?void 0:r.chainId;if(!E){const k=await g.request({method:"eth_chainId"});E=Zv(k)}const C={domain:_.host,address:S,statement:y,uri:_.href,version:"1",chainId:E,nonce:(s=p==null?void 0:p.signInWithEthereum)===null||s===void 0?void 0:s.nonce,issuedAt:(o=(i=p==null?void 0:p.signInWithEthereum)===null||i===void 0?void 0:i.issuedAt)!==null&&o!==void 0?o:new Date,expirationTime:(l=p==null?void 0:p.signInWithEthereum)===null||l===void 0?void 0:l.expirationTime,notBefore:(c=p==null?void 0:p.signInWithEthereum)===null||c===void 0?void 0:c.notBefore,requestId:(u=p==null?void 0:p.signInWithEthereum)===null||u===void 0?void 0:u.requestId,resources:(d=p==null?void 0:p.signInWithEthereum)===null||d===void 0?void 0:d.resources};m=tw(C),v=await g.request({method:"personal_sign",params:[ew(m),S]})}try{const{data:w,error:b}=await I(this.fetch,"POST",`${this.url}/token?grant_type=web3`,{headers:this.headers,body:Object.assign({chain:"ethereum",message:m,signature:v},!((f=t.options)===null||f===void 0)&&f.captchaToken?{gotrue_meta_security:{captcha_token:(h=t.options)===null||h===void 0?void 0:h.captchaToken}}:null),xform:Ge});if(b)throw b;if(!w||!w.session||!w.user){const y=new bn;return this._returnResult({data:{user:null,session:null},error:y})}return w.session&&(await this._saveSession(w.session),await this._notifyAllSubscribers("SIGNED_IN",w.session)),this._returnResult({data:Object.assign({},w),error:b})}catch(w){if(R(w))return this._returnResult({data:{user:null,session:null},error:w});throw w}}async signInWithSolana(t){var n,r,s,i,o,l,c,u,d,f,h,m;let v,w;if("message"in t)v=t.message,w=t.signature;else{const{chain:b,wallet:y,statement:p,options:g}=t;let _;if(he())if(typeof y=="object")_=y;else{const S=window;if("solana"in S&&typeof S.solana=="object"&&("signIn"in S.solana&&typeof S.solana.signIn=="function"||"signMessage"in S.solana&&typeof S.solana.signMessage=="function"))_=S.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"||!(g!=null&&g.url))throw new Error("@supabase/auth-js: Both wallet and url must be specified in non-browser environments.");_=y}const j=new URL((n=g==null?void 0:g.url)!==null&&n!==void 0?n:window.location.href);if("signIn"in _&&_.signIn){const S=await _.signIn(Object.assign(Object.assign(Object.assign({issuedAt:new Date().toISOString()},g==null?void 0:g.signInWithSolana),{version:"1",domain:j.host,uri:j.href}),p?{statement:p}:null));let E;if(Array.isArray(S)&&S[0]&&typeof S[0]=="object")E=S[0];else if(S&&typeof S=="object"&&"signedMessage"in S&&"signature"in S)E=S;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)v=typeof E.signedMessage=="string"?E.signedMessage:new TextDecoder().decode(E.signedMessage),w=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");v=[`${j.host} wants you to sign in with your Solana account:`,_.publicKey.toBase58(),...p?["",p,""]:[""],"Version: 1",`URI: ${j.href}`,`Issued At: ${(s=(r=g==null?void 0:g.signInWithSolana)===null||r===void 0?void 0:r.issuedAt)!==null&&s!==void 0?s:new Date().toISOString()}`,...!((i=g==null?void 0:g.signInWithSolana)===null||i===void 0)&&i.notBefore?[`Not Before: ${g.signInWithSolana.notBefore}`]:[],...!((o=g==null?void 0:g.signInWithSolana)===null||o===void 0)&&o.expirationTime?[`Expiration Time: ${g.signInWithSolana.expirationTime}`]:[],...!((l=g==null?void 0:g.signInWithSolana)===null||l===void 0)&&l.chainId?[`Chain ID: ${g.signInWithSolana.chainId}`]:[],...!((c=g==null?void 0:g.signInWithSolana)===null||c===void 0)&&c.nonce?[`Nonce: ${g.signInWithSolana.nonce}`]:[],...!((u=g==null?void 0:g.signInWithSolana)===null||u===void 0)&&u.requestId?[`Request ID: ${g.signInWithSolana.requestId}`]:[],...!((f=(d=g==null?void 0:g.signInWithSolana)===null||d===void 0?void 0:d.resources)===null||f===void 0)&&f.length?["Resources",...g.signInWithSolana.resources.map(E=>`- ${E}`)]:[]].join(`
93`);const S=await _.signMessage(new TextEncoder().encode(v),"utf8");if(!S||!(S instanceof Uint8Array))throw new Error("@supabase/auth-js: Wallet signMessage() API returned an recognized value");w=S}}try{const{data:b,error:y}=await I(this.fetch,"POST",`${this.url}/token?grant_type=web3`,{headers:this.headers,body:Object.assign({chain:"solana",message:v,signature:cn(w)}
93,!((h=t.options)===null||h===void 0)&&h.captchaToken?{gotrue_meta_security:{captcha_token:(m=t.options)===null||m===void 0?void 0:m.captchaToken}}:null),xform:Ge});if(y)throw y;if(!b||!b.session||!b.user){const p=new bn;return this._returnResult({data:{user:null,session:null},error:p})}return b.session&&(await this._saveSession(b.session),await this._notifyAllSubscribers("SIGNED_IN",b.session)),this._returnResult({data:Object.assign({},b),error:y})}catch(b){if(R(b))return this._returnResult({data:{user:null,session:null},error:b});throw b}}async _exchangeCodeForSession(t){const n=await Xt(this.storage,`${this.storageKey}-code-verifier`),[r,s]=(n??"").split("/");try{if(!r&&this.flowType==="pkce")throw new _v;const{data:i,error:o}=await I(this.fetch,"POST",`${this.url}/token?grant_type=pkce`,{headers:this.headers,body:{auth_code:t,code_verifier:r},xform:Ge});if(await de(this.storage,`${this.storageKey}-code-verifier`),o)throw o;if(!i||!i.session||!i.user){const l=new bn;return this._returnResult({data:{user:null,session:null,redirectType:null},error:l})}return i.session&&(await this._saveSession(i.session),await this._notifyAllSubscribers("SIGNED_IN",i.session)),this._returnResult({data:Object.assign(Object.assign({},i),{redirectType:s??null}),error:o})}catch(i){if(await de(this.storage,`${this.storageKey}-code-verifier`),R(i))return this._returnResult({data:{user:null,session:null,redirectType:null},error:i});throw i}}async signInWithIdToken(t){try{const{options:n,provider:r,token:s,access_token:i,nonce:o}=t,l=await I(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:Ge}),{data:c,error:u}=l;if(u)return this._returnResult({data:{user:null,session:null},error:u});if(!c||!c.session||!c.user){const d=new bn;return this._returnResult({data:{user:null,session:null},error:d})}return c.session&&(await this._saveSession(c.session),await this._notifyAllSubscribers("SIGNED_IN",c.session)),this._returnResult({data:c,error:u})}catch(n){if(R(n))return this._returnResult({data:{user:null,session:null},error:n});throw n}}async signInWithOtp(t){var n,r,s,i,o;try{if("email"in t){const{email:l,options:c}=t;let u=null,d=null;this.flowType==="pkce"&&([u,d]=await _n(this.storage,this.storageKey));const{error:f}=await I(this.fetch,"POST",`${this.url}/otp`,{headers:this.headers,body:{email:l,data:(n=c==null?void 0:c.data)!==null&&n!==void 0?n:{},create_user:(r=c==null?void 0:c.shouldCreateUser)!==null&&r!==void 0?r:!0,gotrue_meta_security:{captcha_token:c==null?void 0:c.captchaToken},code_challenge:u,code_challenge_method:d},redirectTo:c==null?void 0:c.emailRedirectTo});return this._returnResult({data:{user:null,session:null},error:f})}if("phone"in t){const{phone:l,options:c}=t,{data:u,error:d}=await I(this.fetch,"POST",`${this.url}/otp`,{headers:this.headers,body:{phone:l,data:(s=c==null?void 0:c.data)!==null&&s!==void 0?s:{},create_user:(i=c==null?void 0:c.shouldCreateUser)!==null&&i!==void 0?i:!0,gotrue_meta_security:{captcha_token:c==null?void 0:c.captchaToken},channel:(o=c==null?void 0:c.channel)!==null&&o!==void 0?o:"sms"}});return this._returnResult({data:{user:null,session:null,messageId:u==null?void 0:u.message_id},error:d})}throw new qs("You must provide either an email or phone number.")}catch(l){if(await de(this.storage,`${this.storageKey}-code-verifier`),R(l))return this._returnResult({data:{user:null,session:null},error:l});throw l}}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:l}=await I(this.fetch,"POST",`${this.url}/verify`,{headers:this.headers,body:Object.assign(Object.assign({},t),{gotrue_meta_security:{captcha_token:i}}),redirectTo:s,xform:Ge});if(l)throw l;if(!o)throw new Error("An error occurred on token verification.");const c=o.session,u=o.user;return c!=null&&c.access_token&&(await this._saveSession(c),await this._notifyAllSubscribers(t.type=="recovery"?"PASSWORD_RECOVERY":"SIGNED_IN",c)),this._returnResult({data:{user:u,session:c},error:null})}catch(s){if(R(s))return this._returnResult({data:{user:null,session:null},error:s});throw s}}async signInWithSSO(t){var n,r,s,i,o;try{let l=null,c=null;this.flowType==="pkce"&&([l,c]=await _n(this.storage,this.storageKey));const u=await I(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:l,code_challenge_method:c}),headers:this.headers,xform:Gv});return!((i=u.data)===null||i===void 0)&&i.url&&he()&&!(!((o=t.options)===null||o===void 0)&&o.skipBrowserRedirect)&&window.location.assign(u.data.url),this._returnResult(u)}catch(l){if(await de(this.storage,`${this.storageKey}-code-verifier`),R(l))return this._returnResult({data:null,error:l});throw l}}async reauthenticate(){return await this.initializePromise,await this._acquireLock(this.lockAcquireTimeout,async()=>await this._reauthenticate())}async _reauthenticate(){try{return await this._useSession(async t=>{const{data:{session:n},error:r}=t;if(r)throw r;if(!n)throw new Pe;const{error:s}=await I(this.fetch,"GET",`${this.url}/reauthenticate`,{headers:this.headers,jwt:n.access_token});return this._returnResult({data:{user:null,session:null},error:s})})}catch(t){if(R(t))return this._returnResult({data:{user:null,session:null},error:t});throw t}}async resend(t){try{const n=`${this.url}/resend`;if("email"in t){const{email:r,type:s,options:i}=t,{error:o}=await I(this.fetch,"POST",n,{headers:this.headers,body:{email:r,type:s,gotrue_meta_security:{captcha_token:i==null?void 0:i.captchaToken}},redirectTo:i==null?void 0:i.emailRedirectTo});return this._returnResult({data:{user:null,session:null},error:o})}else if("phone"in t){const{phone:r,type:s,options:i}=t,{data:o,error:l}=await I(this.fetch,"POST",n,{headers:this.headers,body:{phone:r,type:s,gotrue_meta_security:{captcha_token:i==null?void 0:i.captchaToken}}});return this._returnResult({data:{user:null,session:null,messageId:o==null?void 0:o.message_id},error:l})}throw new qs("You must provide either an email or phone number and a type")}catch(n){if(R(n))return this._returnResult({data:{user:null,session:null},error:n});throw n}}async getSession(){return await this.initializePromise,await this._acquireLock(this.lockAcquireTimeout,async()=>this._useSession(async n=>n))}async _acquireLock(t,n){this._debug("#_acquireLock","begin",t);try{if(this.lockAcquired){const r=this.pendingInLock.length?this.pendingInLock[this.pendingInLock.length-1]:Promise.resolve(),s=(async()=>(await r,await n()))();return this.pendingInLock.push((async()=>{try{await s}catch{}})()),s}return await this.lock(`lock:${this.storageKey}`,t,async()=>{this._debug("#_acquireLock","lock acquired for storage key",this.storageKey);try{this.lockAcquired=!0;const r=n();for(this.pendingInLock.push((async()=>{try{await r}catch{}})()),await r;this.pendingInLock.length;){const s=[...this.pendingInLock];await Promise.all(s),this.pendingInLock.splice(0,s.length)}return await r}finally{this._debug("#_acquireLock","lock released for storage key",this.storageKey),this.lockAcquired=!1}})}finally{this._debug("#_acquireLock","end")}}async _useSession(t){this._debug("#_useSession","begin");try{const n=await this.__loadSession();return await t(n)}finally{this._debug("#_useSession","end")}}async __loadSession(){this._debug("#__loadSession()","begin"),this.lockAcquired||this._debug("#__loadSession()","used outside of an acquired lock!",new Error().stack);try{let t=null;const n=await Xt(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
93id"),await this._removeSession())),!t)return{data:{session:null},error:null};const r=t.expires_at?t.expires_at*1e3-Date.now()<Wa:!1;if(this._debug("#__loadSession()",`session has${r?"":" not"} expired`,"expires_at",t.expires_at),!r){if(this.userStorage){const o=await Xt(this.userStorage,this.storageKey+"-user");o!=null&&o.user?t.user=o.user:t.user=qa()}if(this.storage.isServer&&t.user&&!t.user.__isUserNotAvailableProxy){const o={value:this.suppressGetSessionWarning};t.user=Wv(t.user,o),o.value&&(this.suppressGetSessionWarning=!0)}return{data:{session:t},error:null}}const{data:s,error:i}=await this._callRefreshToken(t.refresh_token);return i?this._returnResult({data:{session:null},error:i}):this._returnResult({data:{session:s},error:null})}finally{this._debug("#__loadSession()","end")}}async getUser(t){if(t)return await this._getUser(t);await this.initializePromise;const n=await this._acquireLock(this.lockAcquireTimeout,async()=>await this._getUser());return n.data.user&&(this.suppressGetSessionWarning=!0),n}async _getUser(t){try{return t?await I(this.fetch,"GET",`${this.url}/user`,{headers:this.headers,jwt:t,xform:Pt}):await this._useSession(async n=>{var r,s,i;const{data:o,error:l}=n;if(l)throw l;return!(!((r=o.session)===null||r===void 0)&&r.access_token)&&!this.hasCustomAuthorizationHeader?{data:{user:null},error:new Pe}:await I(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:Pt})})}catch(n){if(R(n))return Ha(n)&&(await this._removeSession(),await de(this.storage,`${this.storageKey}-code-verifier`)),this._returnResult({data:{user:null},error:n});throw n}}async updateUser(t,n={}){return await this.initializePromise,await this._acquireLock(this.lockAcquireTimeout,async()=>await this._updateUser(t,n))}async _updateUser(t,n={}){try{return await this._useSession(async r=>{const{data:s,error:i}=r;if(i)throw i;if(!s.session)throw new Pe;const o=s.session;let l=null,c=null;this.flowType==="pkce"&&t.email!=null&&([l,c]=await _n(this.storage,this.storageKey));const{data:u,error:d}=await I(this.fetch,"PUT",`${this.url}/user`,{headers:this.headers,redirectTo:n==null?void 0:n.emailRedirectTo,body:Object.assign(Object.assign({},t),{code_challenge:l,code_challenge_method:c}),jwt:o.access_token,xform:Pt});if(d)throw d;return o.user=u.user,await this._saveSession(o),await this._notifyAllSubscribers("USER_UPDATED",o),this._returnResult({data:{user:o.user},error:null})})}catch(r){if(await de(this.storage,`${this.storageKey}-code-verifier`),R(r))return this._returnResult({data:{user:null},error:r});throw r}}async setSession(t){return await this.initializePromise,await this._acquireLock(this.lockAcquireTimeout,async()=>await this._setSession(t))}async _setSession(t){try{if(!t.access_token||!t.refresh_token)throw new Pe;const n=Date.now()/1e3;let r=n,s=!0,i=null;const{payload:o}=Ks(t.access_token);if(o.exp&&(r=o.exp,s=r<=n),s){const{data:l,error:c}=await this._callRefreshToken(t.refresh_token);if(c)return this._returnResult({data:{user:null,session:null},error:c});if(!l)return{data:{user:null,session:null},error:null};i=l}else{const{data:l,error:c}=await this._getUser(t.access_token);if(c)return this._returnResult({data:{user:null,session:null},error:c});i={access_token:t.access_token,refresh_token:t.refresh_token,user:l.user,token_type:"bearer",expires_in:r-n,expires_at:r},await this._saveSession(i),await this._notifyAllSubscribers("SIGNED_IN",i)}return this._returnResult({data:{user:i.user,session:i},error:null})}catch(n){if(R(n))return this._returnResult({data:{session:null,user:null},error:n});throw n}}async refreshSession(t){return await this.initializePromise,await this._acquireLock(this.lockAcquireTimeout,async()=>await this._refreshSession(t))}async _refreshSession(t){try{return await this._useSession(async n=>{var r;if(!t){const{data:o,error:l}=n;if(l)throw l;t=(r=o.session)!==null&&r!==void 0?r:void 0}if(!(t!=null&&t.refresh_token))throw new Pe;const{data:s,error:i}=await this._callRefreshToken(t.refresh_token);return i?this._returnResult({data:{user:null,session:null},error:i}):s?this._returnResult({data:{user:s.user,session:s},error:null}):this._returnResult({data:{user:null,session:null},error:null})})}catch(n){if(R(n))return this._returnResult({data:{user:null,session:null},error:n});throw n}}async _getSessionFromURL(t,n){try{if(!he())throw new Gs("No browser detected.");
93if(t.error||t.error_description||t.error_code)throw new Gs(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 Fu("Not a valid PKCE flow url.");break;case"pkce":if(this.flowType==="implicit")throw new Gs("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 Fu("No code detected.");const{data:p,error:g}=await this._exchangeCodeForSession(t.code);if(g)throw g;const _=new URL(window.location.href);return _.searchParams.delete("code"),window.history.replaceState(window.history.state,"",_.toString()),{data:{session:p.session,redirectType:null},error:null}}const{provider_token:r,provider_refresh_token:s,access_token:i,refresh_token:o,expires_in:l,expires_at:c,token_type:u}=t;if(!i||!l||!o||!u)throw new Gs("No session defined in URL");const d=Math.round(Date.now()/1e3),f=parseInt(l);let h=d+f;c&&(h=parseInt(c));const m=h-d;m*1e3<=En&&console.warn(`@supabase/gotrue-js: Session as retrieved from URL expires in ${m}s, should have been closer to ${f}s`);const v=h-f;d-v>=120?console.warn("@supabase/gotrue-js: Session as retrieved from URL was issued over 120s ago, URL could be stale",v,h,d):d-v<0&&console.warn("@supabase/gotrue-js: Session as retrieved from URL was issued in the future? Check the device clock for skew",v,h,d);const{data:w,error:b}=await this._getUser(i);if(b)throw b;const y={provider_token:r,provider_refresh_token:s,access_token:i,expires_in:f,expires_at:h,refresh_token:o,token_type:u,user:w.user};return window.location.hash="",this._debug("#_getSessionFromURL()","clearing window.location.hash"),this._returnResult({data:{session:y,redirectType:t.type},error:null})}catch(r){if(R(r))return this._returnResult({data:{session:null,redirectType:null},error:r});throw r}}_isImplicitGrantCallback(t){return typeof this.detectSessionInUrl=="function"?this.detectSessionInUrl(new URL(window.location.href),t):!!(t.access_token||t.error_description)}async _isPKCECallback(t){const n=await Xt(this.storage,`${this.storageKey}-code-verifier`);return!!(t.code&&n)}async signOut(t={scope:"global"}){return await this.initializePromise,await this._acquireLock(this.lockAcquireTimeout,async()=>await this._signOut(t))}async _signOut({scope:t}={scope:"global"}){return await this._useSession(async n=>{var r;const{data:s,error:i}=n;if(i&&!Ha(i))return this._returnResult({error:i});const o=(r=s.session)===null||r===void 0?void 0:r.access_token;if(o){const{error:l}=await this.admin.signOut(o,t);if(l&&!(xv(l)&&(l.status===404||l.status===401||l.status===403)||Ha(l)))return this._returnResult({error:l})}return t!=="others"&&(await this._removeSession(),await de(this.storage,`${this.storageKey}-code-verifier`)),this._returnResult({error:null})})}onAuthStateChange(t){const n=Tv(),r={id:n,callback:t,unsubscribe:()=>{this._debug("#unsubscribe()","state change callback with id removed",n),this.stateChangeEmitters.delete(n)}};return this._debug("#onAuthStateChange()","registered callback with id",n),this.stateChangeEmitters.set(n,r),(async()=>(await this.initializePromise,await this._acquireLock(this.lockAcquireTimeout,async()=>{this._emitInitialSession(n)})))(),{data:{subscription:r}}}async _emitInitialSession(t){return await this._useSession(async n=>{var r,s;try{const{data:{session:i},error:o}=n;if(o)throw o;await((r=this.stateChangeEmitters.get(t))===null||r===void 0?void 0:r.callback("INITIAL_SESSION",i)),this._debug("INITIAL_SESSION","callback id",t,"session",i)}catch(i){await((s=this.stateChangeEmitters.get(t))===null||s===void 0?void 0:s.callback("INITIAL_SESSION",null)),this._debug("INITIAL_SESSION","callback id",t,"error",i),console.error(i)}})}async resetPasswordForEmail(t,n={}){let r=null,s=null;this.flowType==="pkce"&&([r,s]=await _n(this.storage,this.storageKey,!0));try{return await I(this.fetch,"POST",`${this.url}/recover`,{body:{email:t,code_challenge:r,code_challenge_method:s,gotrue_meta_security:{captcha_token:n.captchaToken}},headers:this.headers,redirectTo:n.redirectTo})}catch(i){if(await de(this.storage,`${this.storageKey}-code-verifier`),R(i))return this._returnResult({data:null,error:i});throw i}}async getUserIdentities(){var t;try{const{data:n,error:r}=await this.getUser();if(r)throw r;return this._returnResult({data:{identities:(t=n.user.identities)!==null&&t!==void 0?t:[]},error:null})}catch(n){if(R(n))return this._returnResult({data:null,error:n});throw n}}async linkIdentity(t){return"token"in t?this.linkIdentityIdToken(t):this.linkIdentityOAuth(t)}async linkIdentityOAuth(t){var n;try{const{data:r,error:s}=await this._useSession(async i=>{var o,l,c,u,d;const{data:f,error:h}=i;if(h)throw h;const m=await this._getUrlForProvider(`${this.url}/user/identities/authorize`,t.provider,{redirectTo:(o=t.options)===null||o===void 0?void 0:o.redirectTo,scopes:(l=t.options)===null||l===void 0?void 0:l.scopes,queryParams:(c=t.options)===null||c===void 0?void 0:c.queryParams,skipBrowserRedirect:!0});return await I(this.fetch,"GET",m,{headers:this.headers,jwt:(d=(u=f.session)===null||u===void 0?void 0:u.access_token)!==null&&d!==void 0?d:void 0})});if(s)throw s;return he()&&!(!((n=t.options)===null||n===void 0)&&n.skipBrowserRedirect)&&window.location.assign(r==null?void 0:r.url),this._returnResult({data:{provider:t.provider,url:r==null?void 0:r.url},error:null})}catch(r){if(R(r))return this._returnResult({data:{provider:t.provider,url:null},error:r});throw r}}async linkIdentityIdToken(t){return await this._useSession(async n=>{var r;try{const{error:s,data:{session:i}}=n;
93if(s)throw s;const{options:o,provider:l,token:c,access_token:u,nonce:d}=t,f=await I(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:l,id_token:c,access_token:u,nonce:d,link_identity:!0,gotrue_meta_security:{captcha_token:o==null?void 0:o.captchaToken}},xform:Ge}),{data:h,error:m}=f;return m?this._returnResult({data:{user:null,session:null},error:m}):!h||!h.session||!h.user?this._returnResult({data:{user:null,session:null},error:new bn}):(h.session&&(await this._saveSession(h.session),await this._notifyAllSubscribers("USER_UPDATED",h.session)),this._returnResult({data:h,error:m}))}catch(s){if(await de(this.storage,`${this.storageKey}-code-verifier`),R(s))return this._returnResult({data:{user:null,session:null},error:s});throw s}})}async unlinkIdentity(t){try{return await this._useSession(async n=>{var r,s;const{data:i,error:o}=n;if(o)throw o;return await I(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(R(n))return this._returnResult({data:null,error:n});throw n}}async _refreshAccessToken(t){const n=`#_refreshAccessToken(${t.substring(0,5)}...)`;this._debug(n,"begin");try{const r=Date.now();return await Ov(async s=>(s>0&&await Rv(200*Math.pow(2,s-1)),this._debug(n,"refreshing attempt",s),await I(this.fetch,"POST",`${this.url}/token?grant_type=refresh_token`,{body:{refresh_token:t},headers:this.headers,xform:Ge})),(s,i)=>{const o=200*Math.pow(2,s);return i&&Va(i)&&Date.now()+o-r<En})}catch(r){if(this._debug(n,"error",r),R(r))return this._returnResult({data:{session:null,user:null},error:r});throw r}finally{this._debug(n,"end")}}_isValidSession(t){return typeof t=="object"&&t!==null&&"access_token"in t&&"refresh_token"in t&&"expires_at"in t}async _handleProviderSignIn(t,n){const r=await this._getUrlForProvider(`${this.url}/authorize`,t,{redirectTo:n.redirectTo,scopes:n.scopes,queryParams:n.queryParams});return this._debug("#_handleProviderSignIn()","provider",t,"options",n,"url",r),he()&&!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 Xt(this.storage,this.storageKey);if(s&&this.userStorage){let o=await Xt(this.userStorage,this.storageKey+"-user");!this.storage.isServer&&Object.is(this.storage,this.userStorage)&&!o&&(o={user:s.user},await Cn(this.userStorage,this.storageKey+"-user",o)),s.user=(t=o==null?void 0:o.user)!==null&&t!==void 0?t:qa()}else if(s&&!s.user&&!s.user){const o=await Xt(this.storage,this.storageKey+"-user");o&&(o!=null&&o.user)?(s.user=o.user,await de(this.storage,this.storageKey+"-user"),await Cn(this.storage,this.storageKey,s)):s.user=qa()}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()<Wa;if(this._debug(r,`session has${i?"":" not"} expired with margin of ${Wa}
93s`),i){if(this.autoRefreshToken&&s.refresh_token){const{error:o}=await this._callRefreshToken(s.refresh_token);o&&(console.error(o),Va(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:l}=await this._getUser(s.access_token);!l&&(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 Pe;if(this.refreshingDeferred)return this.refreshingDeferred.promise;const s=`#_callRefreshToken(${t.substring(0,5)}...)`;this._debug(s,"begin");try{this.refreshingDeferred=new aa;const{data:i,error:o}=await this._refreshAccessToken(t);if(o)throw o;if(!i.session)throw new Pe;await this._saveSession(i.session),await this._notifyAllSubscribers("TOKEN_REFRESHED",i.session);const l={data:i.session,error:null};return this.refreshingDeferred.resolve(l),l}catch(i){if(this._debug(s,"error",i),R(i)){const o={data:null,error:i};return Va(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 l=>{try{await l.callback(t,n)}catch(c){i.push(c)}});if(await Promise.all(o),i.length>0){for(let l=0;l<i.length;l+=1)console.error(i[l]);throw i[0]}}finally{this._debug(s,"end")}}async _saveSession(t){this._debug("#_saveSession()",t),this.suppressGetSessionWarning=!0,await de(this.storage,`${this.storageKey}-code-verifier`);const n=Object.assign({},t),r=n.user&&n.user.__isUserNotAvailableProxy===!0;if(this.userStorage){!r&&n.user&&await Cn(this.userStorage,this.storageKey+"-user",{user:n.user});const s=Object.assign({},n);delete s.user;const i=Mu(s);await Cn(this.storage,this.storageKey,i)}else{const s=Mu(n);await Cn(this.storage,this.storageKey,s)}}async _removeSession(){this._debug("#_removeSession()"),this.suppressGetSessionWarning=!1,await de(this.storage,this.storageKey),await de(this.storage,this.storageKey+"-code-verifier"),await de(this.storage,this.storageKey+"-user"),this.userStorage&&await de(this.userStorage,this.storageKey+"-user"),await this._notifyAllSubscribers("SIGNED_OUT",null)}_removeVisibilityChangedCallback(){this._debug("#_removeVisibilityChangedCallback()");const t=this.visibilityChangedCallback;this.visibilityChangedCallback=null;try{t&&he()&&(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(),En);this.autoRefreshTicker=t,t&&typeof t=="object"&&typeof t.unref=="function"?t.unref():typeof Deno<"u"&&typeof Deno.unrefTimer=="function"&&Deno.unrefTimer(t);const n=setTimeout(async()=>{await this.initializePromise,await this._autoRefreshTokenTick()},0);this.autoRefreshTickTimeout=n,n&&typeof n=="object"&&typeof n.unref=="function"?n.unref():typeof Deno<"u"&&typeof Deno.unrefTimer=="function"&&Deno.unrefTimer(n)}async _stopAutoRefresh(){this._debug("#_stopAutoRefresh()");const t=this.autoRefreshTicker;this.autoRefreshTicker=null,t&&clearInterval(t);const n=this.autoRefreshTickTimeout;this.autoRefreshTickTimeout=null,n&&clearTimeout(n)}async startAutoRefresh(){this._removeVisibilityChangedCallback(),await this._startAutoRefresh()}async stopAutoRefresh(){this._removeVisibilityChangedCallback(),await this._stopAutoRefresh()}async _autoRefreshTokenTick(){this._debug("#_autoRefreshTokenTick()","begin");try{await this._acquireLock(0,async()=>{try{const t=Date.now();try{return await this._useSession(async n=>{const{data:{session:r}}=n;if(!r||!r.refresh_token||!r.expires_at){this._debug("#_autoRefreshTokenTick()","no session");return}const s=Math.floor((r.expires_at*1e3-t)/En);this._debug("#_autoRefreshTokenTick()",`access token expires in ${s} ticks, a tick lasts ${En}ms, refresh threshold is ${tl} ticks`),s<=tl&&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 Gf)this._debug("auto refresh token tick lock not available");else throw t}}async _handleVisibilityChange(){if(this._debug("#_handleVisibilityChange()"),!he()||!(window!=null&&window.addEventListener))return this.autoRefreshToken&&this.startAutoRefresh(),!1;try{this.visibilityChangedCallback=async()=>{try{await this._onVisibilityChanged(!1)}catch(t){this._debug("#visibilityChangedCallback","error",t)}},window==null||window.addEventListener("visibilitychange",this.visibilityChangedCallback),await this._onVisibilityChanged(!0)}catch(t){console.error("_handleVisibilityChange",t)}}async _onVisibilityChanged(t){const n=`#_onVisibilityChanged(${t})`;this._debug(n,"visibilityState",document.visibilityState),document.visibilityState==="visible"?(this.autoRefreshToken&&this._startAutoRefresh(),t||(await this.initializePromise,await this._acquireLock(this.lockAcquireTimeout,async()=>
93{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 _n(this.storage,this.storageKey),l=new URLSearchParams({code_challenge:`${encodeURIComponent(i)}`,code_challenge_method:`${encodeURIComponent(o)}`});s.push(l.toString())}if(r!=null&&r.queryParams){const i=new URLSearchParams(r.queryParams);s.push(i.toString())}return r!=null&&r.skipBrowserRedirect&&s.push(`skip_http_redirect=${r.skipBrowserRedirect}`),`${t}?${s.join("&")}`}async _unenroll(t){try{return await this._useSession(async n=>{var r;const{data:s,error:i}=n;return i?this._returnResult({data:null,error:i}):await I(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(R(n))return this._returnResult({data:null,error:n});throw n}}async _enroll(t){try{return await this._useSession(async n=>{var r,s;const{data:i,error:o}=n;if(o)return this._returnResult({data:null,error:o});const l=Object.assign({friendly_name:t.friendlyName,factor_type:t.factorType},t.factorType==="phone"?{phone:t.phone}:t.factorType==="totp"?{issuer:t.issuer}:{}),{data:c,error:u}=await I(this.fetch,"POST",`${this.url}/factors`,{body:l,headers:this.headers,jwt:(r=i==null?void 0:i.session)===null||r===void 0?void 0:r.access_token});return u?this._returnResult({data:null,error:u}):(t.factorType==="totp"&&c.type==="totp"&&(!((s=c==null?void 0:c.totp)===null||s===void 0)&&s.qr_code)&&(c.totp.qr_code=`data:image/svg+xml;utf-8,${c.totp.qr_code}`),this._returnResult({data:c,error:null}))})}catch(n){if(R(n))return this._returnResult({data:null,error:n});throw n}}async _verify(t){return this._acquireLock(this.lockAcquireTimeout,async()=>{try{return await this._useSession(async n=>{var r;const{data:s,error:i}=n;if(i)return this._returnResult({data:null,error:i});const o=Object.assign({challenge_id:t.challengeId},"webauthn"in t?{webauthn:Object.assign(Object.assign({},t.webauthn),{credential_response:t.webauthn.type==="create"?lw(t.webauthn.credential_response):cw(t.webauthn.credential_response)})}:{code:t.code}),{data:l,error:c}=await I(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 c?this._returnResult({data:null,error:c}):(await this._saveSession(Object.assign({expires_at:Math.round(Date.now()/1e3)+l.expires_in},l)),await this._notifyAllSubscribers("MFA_CHALLENGE_VERIFIED",l),this._returnResult({data:l,error:c}))})}catch(n){if(R(n))return this._returnResult({data:null,error:n});throw n}})}async _challenge(t){return this._acquireLock(this.lockAcquireTimeout,async()=>{try{return await this._useSession(async n=>{var r;const{data:s,error:i}=n;if(i)return this._returnResult({data:null,error:i});const o=await I(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:l}=o;if(l.type!=="webauthn")return{data:l,error:null};switch(l.webauthn.type){case"create":return{data:Object.assign(Object.assign({},l),{webauthn:Object.assign(Object.assign({},l.webauthn),{credential_options:Object.assign(Object.assign({},l.webauthn.credential_options),{publicKey:aw(l.webauthn.credential_options.publicKey)})})}),error:null};case"request":return{data:Object.assign(Object.assign({},l),{webauthn:Object.assign(Object.assign({},l.webauthn),{credential_options:Object.assign(Object.assign({},l.webauthn.credential_options),{publicKey:ow(l.webauthn.credential_options.publicKey)})})}),error:null}}})}catch(n){if(R(n))return this._returnResult({data:null,error:n});throw n}})}async _challengeAndVerify(t){const{data:n,error:r}=await this._challenge({factorId:t.factorId});return r?this._returnResult({data:null,error:r}):await this._verify({factorId:t.factorId,challengeId:n.id,code:t.code})}async _listFactors(){var t;const{data:{user:n},error:r}=await this.getUser();if(r)return{data:null,error:r};const s={all:[],phone:[],totp:[],webauthn:[]};for(const i of(t=n==null?void 0:n.factors)!==null&&t!==void 0?t:[])s.all.push(i),i.status==="verified"&&s[i.factor_type].push(i);return{data:s,error:null}}async _getAuthenticatorAssuranceLevel(t){var n,r,s,i;if(t)try{const{payload:m}=Ks(t);let v=null;m.aal&&(v=m.aal);let w=v;const{data:{user:b},error:y}=await this.getUser(t);if(y)return this._returnResult({data:null,error:y});((r=(n=b==null?void 0:b.factors)===null||n===void 0?void 0:n.filter(_=>_.status==="verified"))!==null&&r!==void 0?r:[]).length>0&&(w="aal2");const g=m.amr||[];return{data:{currentLevel:v,nextLevel:w,currentAuthenticationMethods:g},error:null}}catch(m){if(R(m))return this._returnResult({data:null,error:m});throw m}const{data:{session:o},error:l}
93=await this.getSession();if(l)return this._returnResult({data:null,error:l});if(!o)return{data:{currentLevel:null,nextLevel:null,currentAuthenticationMethods:[]},error:null};const{payload:c}=Ks(o.access_token);let u=null;c.aal&&(u=c.aal);let d=u;((i=(s=o.user.factors)===null||s===void 0?void 0:s.filter(m=>m.status==="verified"))!==null&&i!==void 0?i:[]).length>0&&(d="aal2");const h=c.amr||[];return{data:{currentLevel:u,nextLevel:d,currentAuthenticationMethods:h},error:null}}async _getAuthorizationDetails(t){try{return await this._useSession(async n=>{const{data:{session:r},error:s}=n;return s?this._returnResult({data:null,error:s}):r?await I(this.fetch,"GET",`${this.url}/oauth/authorizations/${t}`,{headers:this.headers,jwt:r.access_token,xform:i=>({data:i,error:null})}):this._returnResult({data:null,error:new Pe})})}catch(n){if(R(n))return this._returnResult({data:null,error:n});throw n}}async _approveAuthorization(t,n){try{return await this._useSession(async r=>{const{data:{session:s},error:i}=r;if(i)return this._returnResult({data:null,error:i});if(!s)return this._returnResult({data:null,error:new Pe});const o=await I(this.fetch,"POST",`${this.url}/oauth/authorizations/${t}/consent`,{headers:this.headers,jwt:s.access_token,body:{action:"approve"},xform:l=>({data:l,error:null})});return o.data&&o.data.redirect_url&&he()&&!(n!=null&&n.skipBrowserRedirect)&&window.location.assign(o.data.redirect_url),o})}catch(r){if(R(r))return this._returnResult({data:null,error:r});throw r}}async _denyAuthorization(t,n){try{return await this._useSession(async r=>{const{data:{session:s},error:i}=r;if(i)return this._returnResult({data:null,error:i});if(!s)return this._returnResult({data:null,error:new Pe});const o=await I(this.fetch,"POST",`${this.url}/oauth/authorizations/${t}/consent`,{headers:this.headers,jwt:s.access_token,body:{action:"deny"},xform:l=>({data:l,error:null})});return o.data&&o.data.redirect_url&&he()&&!(n!=null&&n.skipBrowserRedirect)&&window.location.assign(o.data.redirect_url),o})}catch(r){if(R(r))return this._returnResult({data:null,error:r});throw r}}async _listOAuthGrants(){try{return await this._useSession(async t=>{const{data:{session:n},error:r}=t;return r?this._returnResult({data:null,error:r}):n?await I(this.fetch,"GET",`${this.url}/user/oauth/grants`,{headers:this.headers,jwt:n.access_token,xform:s=>({data:s,error:null})}):this._returnResult({data:null,error:new Pe})})}catch(t){if(R(t))return this._returnResult({data:null,error:t});throw t}}async _revokeOAuthGrant(t){try{return await this._useSession(async n=>{const{data:{session:r},error:s}=n;return s?this._returnResult({data:null,error:s}):r?(await I(this.fetch,"DELETE",`${this.url}/user/oauth/grants`,{headers:this.headers,jwt:r.access_token,query:{client_id:t.clientId},noResolveJson:!0}),{data:{},error:null}):this._returnResult({data:null,error:new Pe})})}catch(n){if(R(n))return this._returnResult({data:null,error:n});throw n}}async fetchJwk(t,n={keys:[]}){let r=n.keys.find(l=>l.kid===t);if(r)return r;const s=Date.now();if(r=this.jwks.keys.find(l=>l.kid===t),r&&this.jwks_cached_at+vv>s)return r;const{data:i,error:o}=await I(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(l=>l.kid===t),!r)?null:r}async getClaims(t,n={}){try{let r=t;if(!r){const{data:m,error:v}
93=await this.getSession();if(v||!m.session)return this._returnResult({data:null,error:v});r=m.session.access_token}const{header:s,payload:i,signature:o,raw:{header:l,payload:c}}=Ks(r);n!=null&&n.allowExpired||zv(i.exp);const u=!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(!u){const{error:m}=await this.getUser(r);if(m)throw m;return{data:{claims:i,header:s,signature:o},error:null}}const d=Mv(s.alg),f=await crypto.subtle.importKey("jwk",u,d,!0,["verify"]);if(!await crypto.subtle.verify(d,f,o,Ev(`${l}.${c}`)))throw new sl("Invalid JWT signature");return{data:{claims:i,header:s,signature:o},error:null}}catch(r){if(R(r))return this._returnResult({data:null,error:r});throw r}}}cs.nextInstanceID={};const vw=cs,ww="2.97.0";let Er="";typeof Deno<"u"?Er="deno":typeof document<"u"?Er="web":typeof navigator<"u"&&navigator.product==="ReactNative"?Er="react-native":Er="node";const xw={"X-Client-Info":`supabase-js-${Er}/${ww}`},bw={headers:xw},_w={schema:"public"},kw={autoRefreshToken:!0,persistSession:!0,detectSessionInUrl:!0,flowType:"implicit"},jw={};function us(e){"@babel/helpers - typeof";return us=typeof Symbol=="function"&&typeof Symbol.iterator=="symbol"?function(t){return typeof t}:function(t){return t&&typeof Symbol=="function"&&t.constructor===Symbol&&t!==Symbol.prototype?"symbol":typeof t},us(e)}function Sw(e,t){if(us(e)!="object"||!e)return e;var n=e[Symbol.toPrimitive];if(n!==void 0){var r=n.call(e,t||"default");if(us(r)!="object")return r;throw new TypeError("@@toPrimitive must return a primitive value.")}return(t==="string"?String:Number)(e)}function Nw(e){var t=Sw(e,"string");return us(t)=="symbol"?t:t+""}function Ew(e,t,n){return(t=Nw(t))in e?Object.defineProperty(e,t,{value:n,enumerable:!0,configurable:!0,writable:!0}):e[t]=n,e}function Yu(e,t){var n=Object.keys(e);if(Object.getOwnPropertySymbols){var r=Object.getOwnPropertySymbols(e);t&&(r=r.filter(function(s){return Object.getOwnPropertyDescriptor(e,s).enumerable})),n.push.apply(n,r)}return n}function Z(e){for(var t=1;t<arguments.length;t++){var n=arguments[t]!=null?arguments[t]:{};t%2?Yu(Object(n),!0).forEach(function(r){Ew(e,r,n[r])}):Object.getOwnPropertyDescriptors?Object.defineProperties(e,Object.getOwnPropertyDescriptors(n)):Yu(Object(n)).forEach(function(r){Object.defineProperty(e,r,Object.getOwnPropertyDescriptor(n,r))})}return e}const Cw=e=>e?(...t)=>e(...t):(...t)=>fetch(...t),Tw=()=>Headers,Aw=(e,t,n)=>{const r=Cw(n),s=Tw();return async(i,o)=>{var l;const c=(l=await t())!==null&&l!==void 0?l:e;let u=new s(o==null?void 0:o.headers);return u.has("apikey")||u.set("apikey",e),u.has("Authorization")||u.set("Authorization",`Bearer ${c}`),r(i,Z(Z({},o),{},{headers:u}))}};function Pw(e){return e.endsWith("/")?e:e+"/"}function Rw(e,t){var n,r;const{db:s,auth:i,realtime:o,global:l}=e,{db:c,auth:u,realtime:d,global:f}=t,h={db:Z(Z({},c),s),auth:Z(Z({},u),i),realtime:Z(Z({},d),o),storage:{},global:Z(Z(Z({},f),l),{},{headers:Z(Z({},(n=f==null?void 0:f.headers)!==null&&n!==void 0?n:{}),(r=l==null?void 0:l.headers)!==null&&r!==void 0?r:{})}),accessToken:async()=>""};return e.accessToken?h.accessToken=e.accessToken:delete h.accessToken,h}function Ow(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(Pw(t))}catch{throw Error("Invalid supabaseUrl: Provided URL is malformed.")}}var Iw=class extends vw{constructor(e){super(e)}},Dw=class{constructor(e,t,n){var r,s;this.supabaseUrl=e,this.supabaseKey=t;const i=Ow(e);if(!t)throw new Error("supabaseKey is required.");this.realtimeUrl=new URL("realtime/v1",i),this.realtimeUrl.protocol=this.realtimeUrl.protocol.replace("http","ws"),this.authUrl=new URL("auth/v1",i),this.storageUrl=new URL("storage/v1",i),this.functionsUrl=new URL("functions/v1",i);const o=`sb-${i.hostname.split(".")[0]}-auth-token`,l={db:_w,realtime:jw,auth:Z(Z({},kw),{},{storageKey:o}),global:bw},c=Rw(n??{},l);if(this.storageKey=(r=c.auth.storageKey)!==null&&r!==void 0?r:"",this.headers=(s=c.global.headers)!==null&&s!==void 0?s:{},c.accessToken)this.accessToken=c.accessToken,this.auth=new Proxy({},{get:(d,f)=>{throw new Error(`@supabase/supabase-js: Supabase Client is configured with the accessToken option, accessing supabase.auth.${String(f)} is not possible`)}});else{var u;this.auth=this._initSupabaseAuthClient((u=c.auth)!==null&&u!==void 0?u:{},this.headers,c.global.fetch)}this.fetch=Aw(t,this._getAccessToken.bind(this),c.global.fetch),this.realtime=this._initRealtimeClient(Z({headers:this.headers,accessToken:this._getAccessToken.bind(this)},c.realtime)),this.accessToken&&Promise.resolve(this.accessToken()).then(d=>this.realtime.setAuth(d)).catch(d=>console.warn("Failed to set initial Realtime auth token:",d)),this.rest=new xy(new URL("rest/v1",i).href,{headers:this.headers,schema:c.db.schema,fetch:this.fetch,timeout:c.db.timeout,urlLengthLimit:c.db.urlLengthLimit}),this.storage=new fv(this.storageUrl.href,this.headers,this.fetch,n==null?void 0:n.storage),c.accessToken||this._listenForAuthEvents()}get functions(){return new hy(this.functionsUrl.href,{headers:this.headers,customFetch:this.fetch})}from(e){return this.rest.from(e)}schema(e){return this.rest.schema(e)}rpc(e,t={},n={head:!1,get:!1,count:void 0}){return this.rest.rpc(e,t,n)}
93channel(e,t={config:{}}){return this.realtime.channel(e,t)}getChannels(){return this.realtime.getChannels()}removeChannel(e){return this.realtime.removeChannel(e)}removeAllChannels(){return this.realtime.removeAllChannels()}async _getAccessToken(){var e=this,t,n;if(e.accessToken)return await e.accessToken();const{data:r}=await e.auth.getSession();return(t=(n=r.session)===null||n===void 0?void 0:n.access_token)!==null&&t!==void 0?t:e.supabaseKey}_initSupabaseAuthClient({autoRefreshToken:e,persistSession:t,detectSessionInUrl:n,storage:r,userStorage:s,storageKey:i,flowType:o,lock:l,debug:c,throwOnError:u},d,f){const h={Authorization:`Bearer ${this.supabaseKey}`,apikey:`${this.supabaseKey}`};return new Iw({url:this.authUrl.href,headers:Z(Z({},h),d),storageKey:i,autoRefreshToken:e,persistSession:t,detectSessionInUrl:n,storage:r,userStorage:s,flowType:o,lock:l,debug:c,throwOnError:u,fetch:f,hasCustomAuthorizationHeader:Object.keys(this.headers).some(m=>m.toLowerCase()==="authorization")})}_initRealtimeClient(e){return new Ly(this.realtimeUrl.href,Z(Z({},e),{},{params:Z(Z({},{apikey:this.supabaseKey}),e==null?void 0:e.params)}))}_listenForAuthEvents(){return this.auth.onAuthStateChange((e,t)=>{this._handleTokenChanged(e,"CLIENT",t==null?void 0:t.access_token)})}_handleTokenChanged(e,t,n){(e==="TOKEN_REFRESHED"||e==="SIGNED_IN")&&this.changedAccessToken!==n?(this.changedAccessToken=n,this.realtime.setAuth(n)):e==="SIGNED_OUT"&&(this.realtime.setAuth(),t=="STORAGE"&&this.auth.signOut(),this.changedAccessToken=void 0)}};const Fw=(e,t,n)=>new Dw(e,t,n);function Lw(){if(typeof window<"u")return!1;const e=globalThis.process;if(!e)return!1;const t=e.version;if(t==null)return!1;const n=t.match(/^v(\d+)\./);return n?parseInt(n[1],10)<=18:!1}Lw()&&console.warn("⚠️  Node.js 18 and below are deprecated and will no longer be supported in future versions of @supabase/supabase-js. Please upgrade to Node.js 20 or later. For more information, visit: https://github.com/orgs/supabase/discussions/37217");const $w="https://keowxarexirpioejclpt.supabase.co",Uw="eyJhbGciOiJIUzI1NiIsInR5cCI6IkpXVCJ9.eyJpc3MiOiJzdXBhYmFzZSIsInJlZiI6Imtlb3d4YXJleGlycGlvZWpjbHB0Iiwicm9sZSI6ImFub24iLCJpYXQiOjE3NzE0MjU4OTksImV4cCI6MjA4NzAwMTg5OX0.9sqVFHcF90HRp29POH-vWDRnSwaOLws_xGd4d4Y-U0c",Tn=Fw($w,Uw),Jf=x.createContext(void 0);function zw({children:e}){const[t,n]=x.useState(null),[r,s]=x.useState(null),[i,o]=x.useState(!0);x.useEffect(()=>{Tn.auth.getSession().then(({data:{session:h}})=>{s(h),n((h==null?void 0:h.user)??null),o(!1)});const{data:{subscription:f}}=Tn.auth.onAuthStateChange((h,m)=>{s(m),n((m==null?void 0:m.user)??null),o(!1)});return()=>f.unsubscribe()},[]);const d={user:t,session:r,loading:i,signUp:async(f,h)=>{const{error:m}=await Tn.auth.signUp({email:f,password:h,options:{emailRedirectTo:void 0}});return{error:m}},signIn:async(f,h)=>{const{error:m}=await Tn.auth.signInWithPassword({email:f,password:h});return{error:m}},signOut:async()=>{await Tn.auth.signOut()}};return a.jsx(Jf.Provider,{value:d,children:e})}function oa(){const e=x.useContext(Jf);if(e===void 0)throw new Error("useAuth must be used within an AuthProvider");return e}/**
94 * @license lucide-react v0.344.0 - ISC
95 *
96 * This source code is licensed under the ISC license.
97 * See the LICENSE file in the root directory of this source tree.
98 */var Mw={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"};/**
99 * @license lucide-react v0.344.0 - ISC
100 *
101 * This source code is licensed under the ISC license.
102 * See the LICENSE file in the root directory of this source tree.
103 */const Bw=e=>e.replace(/([a-z0-9])([A-Z])/g,"$1-$2").toLowerCase().trim(),$=(e,t)=>{const n=x.forwardRef(({color:r="currentColor",size:s=24,strokeWidth:i=2,absoluteStrokeWidth:o,className:l="",children:c,...u},d)=>x.createElement("svg",{ref:d,...Mw,width:s,height:s,stroke:r,strokeWidth:o?Number(i)*24/Number(s):i,className:["lucide",`lucide-${Bw(e)}`,l].join(" "),...u},[...t.map(([f,h])=>
103x.createElement(f,h)),...Array.isArray(c)?c:[c]]));return n.displayName=`${e}`,n};/**
104 * @license lucide-react v0.344.0 - ISC
105 *
106 * This source code is licensed under the ISC license.
107 * See the LICENSE file in the root directory of this source tree.
108 */const Ww=$("AlertCircle",[["circle",{cx:"12",cy:"12",r:"10",key:"1mglay"}],["line",{x1:"12",x2:"12",y1:"8",y2:"12",key:"1pkeuh"}],["line",{x1:"12",x2:"12.01",y1:"16",y2:"16",key:"4dfq90"}]]);/**
109 * @license lucide-react v0.344.0 - ISC
110 *
111 * This source code is licensed under the ISC license.
112 * See the LICENSE file in the root directory of this source tree.
113 */const Li=$("ArrowLeft",[["path",{d:"m12 19-7-7 7-7",key:"1l729n"}],["path",{d:"M19 12H5",key:"x3x0zl"}]]);/**
114 * @license lucide-react v0.344.0 - ISC
115 *
116 * This source code is licensed under the ISC license.
117 * See the LICENSE file in the root directory of this source tree.
118 */const ir=$("ArrowRight",[["path",{d:"M5 12h14",key:"1ays0h"}],["path",{d:"m12 5 7 7-7 7",key:"xquz4c"}]]);/**
119 * @license lucide-react v0.344.0 - ISC
120 *
121 * This source code is licensed under the ISC license.
122 * See the LICENSE file in the root directory of this source tree.
123 */const la=$("Award",[["circle",{cx:"12",cy:"8",r:"6",key:"1vp47v"}],["path",{d:"M15.477 12.89 17 22l-5-3-5 3 1.523-9.11",key:"em7aur"}]]);/**
124 * @license lucide-react v0.344.0 - ISC
125 *
126 * This source code is licensed under the ISC license.
127 * See the LICENSE file in the root directory of this source tree.
128 */const Hw=$("BookOpen",[["path",{d:"M2 3h6a4 4 0 0 1 4 4v14a3 3 0 0 0-3-3H2z",key:"vv98re"}],["path",{d:"M22 3h-6a4 4 0 0 0-4 4v14a3 3 0 0 1 3-3h7z",key:"1cyq3y"}]]);/**
129 * @license lucide-react v0.344.0 - ISC
130 *
131 * This source code is licensed under the ISC license.
132 * See the LICENSE file in the root directory of this source tree.
133 */const Vw=$("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"}]]);/**
134 * @license lucide-react v0.344.0 - ISC
135 *
136 * This source code is licensed under the ISC license.
137 * See the LICENSE file in the root directory of this source tree.
138 */const il=$("CheckCircle",[["path",{d:"M22 11.08V12a10 10 0 1 1-5.93-9.14",key:"g774vq"}],["path",{d:"m9 11 3 3L22 4",key:"1pflzl"}]]);/**
139 * @license lucide-react v0.344.0 - ISC
140 *
141 * This source code is licensed under the ISC license.
142 * See the LICENSE file in the root directory of this source tree.
143 */const Zt=$("Check",[["path",{d:"M20 6 9 17l-5-5",key:"1gmf2c"}]]);/**
144 * @license lucide-react v0.344.0 - ISC
145 *
146 * This source code is licensed under the ISC license.
147 * See the LICENSE file in the root directory of this source tree.
148 */const qw=$("ChevronLeft",[["path",{d:"m15 18-6-6 6-6",key:"1wnfg3"}]]);/**
149 * @license lucide-react v0.344.0 - ISC
150 *
151 * This source code is licensed under the ISC license.
152 * See the LICENSE file in the root directory of this source tree.
153 */const Gw=$("ChevronRight",[["path",{d:"m9 18 6-6-6-6",key:"mthhwq"}]]);/**
154 * @license lucide-react v0.344.0 - ISC
155 *
156 * This source code is licensed under the ISC license.
157 * See the LICENSE file in the root directory of this source tree.
158 */const Qf=$("CreditCard",[["rect",{width:"20",height:"14",x:"2",y:"5",rx:"2",key:"ynyp8z"}],["line",{x1:"2",x2:"22",y1:"10",y2:"10",key:"1b3vmo"}]]);/**
159 * @license lucide-react v0.344.0 - ISC
160 *
161 * This source code is licensed under the ISC license.
162 * See the LICENSE file in the root directory of this source tree.
163 */const Kw=$("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"}]]);/**
164 * @license lucide-react v0.344.0 - ISC
165 *
166 * This source code is licensed under the ISC license.
167 * See the LICENSE file in the root directory of this source tree.
168 */const Yw=$("Home",[["path",{d:"m3 9 9-7 9 7v11a2 2 0 0 1-2 2H5a2 2 0 0 1-2-2z",key:"y5dka4"}],["polyline",{points:"9 22 9 12 15 12 15 22",key:"e2us08"}]]);/**
169 * @license lucide-react v0.344.0 - ISC
170 *
171 * This source code is licensed under the ISC license.
172 * See the LICENSE file in the root directory of this source tree.
173 */const Ka=$("Instagram",[["rect",{width:"20",height:"20",x:"2",y:"2",rx:"5",ry:"5",key:"2e1cvw"}],["path",{d:"M16 11.37A4 4 0 1 1 12.63 8 4 4 0 0 1 16 11.37z",key:"9exkf1"}],["line",{x1:"17.5",x2:"17.51",y1:"6.5",y2:"6.5",key:"r4j83e"}]]);/**
174 * @license lucide-react v0.344.0 - ISC
175 *
176 * This source code is licensed under the ISC license.
177 * See the LICENSE file in the root directory of this source tree.
178 */const Ya=$("Linkedin",[["path",{d:"M16 8a6 6 0 0 1 6 6v7h-4v-7a2 2 0 0 0-2-2 2 2 0 0 0-2 2v7h-4v-7a6 6 0 0 1 6-6z",key:"c2jq9f"}],["rect",{width:"4",height:"12",x:"2",y:"9",key:"mk3on5"}],["circle",{cx:"4",cy:"4",r:"2",key:"bt5ra8"}]]);/**
179 * @license lucide-react v0.344.0 - ISC
180 *
181 * This source code is licensed under the ISC license.
182 * See the LICENSE file in the root directory of this source tree.
183 */const Xf=$("Mail",[["rect",{width:"20",height:"16",x:"2",y:"4",rx:"2",key:"18n3k1"}],["path",{d:"m22 7-8.97 5.7a1.94 1.94 0 0 1-2.06 0L2 7",key:"1ocrg3"}]]);/**
184 * @license lucide-react v0.344.0 - ISC
185 *
186 * This source code is licensed under the ISC license.
187 * See the LICENSE file in the root directory of this source tree.
188 */const Jw=$("MapPin",[["path",{d:"M20 10c0 6-8 12-8 12s-8-6-8-12a8 8 0 0 1 16 0Z",key:"2oe9fu"}],["circle",{cx:"12",cy:"10",r:"3",key:"ilqhr7"}]]);/**
189 * @license lucide-react v0.344.0 - ISC
190 *
191 * This source code is licensed under the ISC license.
192 * See the LICENSE file in the root directory of this source tree.
193 */const Qw=$("Menu",[["line",{x1:"4",x2:"20",y1:"12",y2:"12",key:"1e0a9i"}],["line",{x1:"4",x2:"20",y1:"6",y2:"6",key:"1owob3"}],["line",{x1:"4",x2:"20",y1:"18",y2:"18",key:"yk5zj1"}]]);/**
194 * @license lucide-react v0.344.0 - ISC
195 *
196 * This source code is licensed under the ISC license.
197 * See the LICENSE file in the root directory of this source tree.
198 */const Ja=$("MessageCircle",[["path",{d:"M7.9 20A9 9 0 1 0 4 16.1L2 22Z",key:"vv11sd"}]]);/**
199 * @license lucide-react v0.344.0 - ISC
200 *
201 * This source code is licensed under the ISC license.
202 * See the LICENSE file in the root directory of this source tree.
203 */const Zf=$("Minus",[["path",{d:"M5 12h14",key:"1ays0h"}]]);/**
204 * @license lucide-react v0.344.0 - ISC
205 *
206 * This source code is licensed under the ISC license.
207 * See the LICENSE file in the root directory of this source tree.
208 */const ds=$("Package",[["path",{d:"m7.5 4.27 9 5.15",key:"1c824w"}],["path",{d:"M21 8a2 2 0 0 0-1-1.73l-7-4a2 2 0 0 0-2 0l-7 4A2 2 0 0 0 3 8v8a2 2 0 0 0 1 1.73l7 4a2 2 0 0 0 2 0l7-4A2 2 0 0 0 21 16Z",key:"hh9hay"}],["path",{d:"m3.3 7 8.7 5 8.7-5",key:"g66t2b"}],["path",{d:"M12 22V12",key:"d0xqtd"}]]);/**
209 * @license lucide-react v0.344.0 - ISC
210 *
211 * This source code is licensed under the ISC license.
212 * See the LICENSE file in the root directory of this source tree.
213 */const Xw=$("Phone",[["path",{d:"M22 16.92v3a2 2 0 0 1-2.18 2 19.79 19.79 0 0 1-8.63-3.07 19.5 19.5 0 0 1-6-6 19.79 19.79 0 0 1-3.07-8.67A2 2 0 0 1 4.11 2h3a2 2 0 0 1 2 1.72 12.84 12.84 0 0 0 .7 2.81 2 2 0 0 1-.45 2.11L8.09 9.91a16 16 0 0 0 6 6l1.27-1.27a2 2 0 0 1 2.11-.45 12.84 12.84 0 0 0 2.81.7A2 2 0 0 1 22 16.92z",key:"foiqr5"}]]);/**
214 * @license lucide-react v0.344.0 - ISC
215 *
216 * This source code is licensed under the ISC license.
217 * See the LICENSE file in the root directory of this source tree.
218 */const oc=$("Play",[["polygon",{points:"5 3 19 12 5 21 5 3",key:"191637"}]]);/**
219 * @license lucide-react v0.344.0 - ISC
220 *
221 * This source code is licensed under the ISC license.
222 * See the LICENSE file in the root directory of this source tree.
223 */const ep=$("Plus",[["path",{d:"M5 12h14",key:"1ays0h"}],["path",{d:"M12 5v14",key:"s699le"}]]);/**
224 * @license lucide-react v0.344.0 - ISC
225 *
226 * This source code is licensed under the ISC license.
227 * See the LICENSE file in the root directory of this source tree.
228 */const Zw=$("ShieldCheck",[["path",{d:"M20 13c0 5-3.5 7.5-7.66 8.95a1 1 0 0 1-.67-.01C7.5 20.5 4 18 4 13V6a1 1 0 0 1 1-1c2 0 4.5-1.2 6.24-2.72a1.17 1.17 0 0 1 1.52 0C14.51 3.81 17 5 19 5a1 1 0 0 1 1 1z",ke
228y:"oel41y"}],["path",{d:"m9 12 2 2 4-4",key:"dzmm74"}]]);/**
229 * @license lucide-react v0.344.0 - ISC
230 *
231 * This source code is licensed under the ISC license.
232 * See the LICENSE file in the root directory of this source tree.
233 */const ex=$("Shield",[["path",{d:"M20 13c0 5-3.5 7.5-7.66 8.95a1 1 0 0 1-.67-.01C7.5 20.5 4 18 4 13V6a1 1 0 0 1 1-1c2 0 4.5-1.2 6.24-2.72a1.17 1.17 0 0 1 1.52 0C14.51 3.81 17 5 19 5a1 1 0 0 1 1 1z",key:"oel41y"}]]);/**
234 * @license lucide-react v0.344.0 - ISC
235 *
236 * This source code is licensed under the ISC license.
237 * See the LICENSE file in the root directory of this source tree.
238 */const hs=$("ShoppingBag",[["path",{d:"M6 2 3 6v14a2 2 0 0 0 2 2h14a2 2 0 0 0 2-2V6l-3-4Z",key:"hou9p0"}],["path",{d:"M3 6h18",key:"d0wm0j"}],["path",{d:"M16 10a4 4 0 0 1-8 0",key:"1ltviw"}]]);/**
239 * @license lucide-react v0.344.0 - ISC
240 *
241 * This source code is licensed under the ISC license.
242 * See the LICENSE file in the root directory of this source tree.
243 */const Ju=$("ShoppingCart",[["circle",{cx:"8",cy:"21",r:"1",key:"jimo8o"}],["circle",{cx:"19",cy:"21",r:"1",key:"13723u"}],["path",{d:"M2.05 2.05h2l2.66 12.42a2 2 0 0 0 2 1.58h9.78a2 2 0 0 0 1.95-1.57l1.65-7.43H5.12",key:"9zh506"}]]);/**
244 * @license lucide-react v0.344.0 - ISC
245 *
246 * This source code is licensed under the ISC license.
247 * See the LICENSE file in the root directory of this source tree.
248 */const Ur=$("Star",[["polygon",{points:"12 2 15.09 8.26 22 9.27 17 14.14 18.18 21.02 12 17.77 5.82 21.02 7 14.14 2 9.27 8.91 8.26 12 2",key:"8f66p6"}]]);/**
249 * @license lucide-react v0.344.0 - ISC
250 *
251 * This source code is licensed under the ISC license.
252 * See the LICENSE file in the root directory of this source tree.
253 */const tx=$("Target",[["circle",{cx:"12",cy:"12",r:"10",key:"1mglay"}],["circle",{cx:"12",cy:"12",r:"6",key:"1vlfrh"}],["circle",{cx:"12",cy:"12",r:"2",key:"1c9p78"}]]);/**
254 * @license lucide-react v0.344.0 - ISC
255 *
256 * This source code is licensed under the ISC license.
257 * See the LICENSE file in the root directory of this source tree.
258 */const tp=$("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"}]]);/**
259 * @license lucide-react v0.344.0 - ISC
260 *
261 * This source code is licensed under the ISC license.
262 * See the LICENSE file in the root directory of this source tree.
263 */const lc=$("TrendingUp",[["polyline",{points:"22 7 13.5 15.5 8.5 10.5 2 17",key:"126l90"}],["polyline",{points:"16 7 22 7 22 13",key:"kwv8wd"}]]);/**
264 * @license lucide-react v0.344.0 - ISC
265 *
266 * This source code is licensed under the ISC license.
267 * See the LICENSE file in the root directory of this source tree.
268 */const Qa=$("Twitter",[["path",{d:"M22 4s-.7 2.1-2 3.4c1.6 10-9.4 17.3-18 11.6 2.2.1 4.4-.6 6-2C3 15.5.5 9.6 3 5c2.2 2.6 5.6 4.1 9 4-.9-4.2 4-6.6 7-3.8 1.1 0 3-1.2 3-1.2z",key:"pff0z6"}]]);/**
269 * @license lucide-react v0.344.0 - ISC
270 *
271 * This source code is licensed under the ISC license.
272 * See the LICENSE file in the root directory of this source tree.
273 */const np=$("Users",[["path",{d:"M16 21v-2a4 4 0 0 0-4-4H6a4 4 0 0 0-4 4v2",key:"1yyitq"}],["circle",{cx:"9",cy:"7",r:"4",key:"nufk8"}],["path",{d:"M22 21v-2a4 4 0 0 0-3-3.87",key:"kshegd"}],["path",{d:"M16 3.13a4 4 0 0 1 0 7.75",key:"1da9ce"}]]);/**
274 * @license lucide-react v0.344.0 - ISC
275 *
276 * This source code is licensed under the ISC license.
277 * See the LICENSE file in the root directory of this source tree.
278 */const $i=$("X",[["path",{d:"M18 6 6 18",key:"1bl5f8"}],["path",{d:"m6 6 12 12",key:"d8bk6v"}]]);/**
279 * @license lucide-react v0.344.0 - ISC
280 *
281 * This source code is licensed under the ISC license.
282 * See the LICENSE file in the root directory of this source tree.
283 */const An=$("Youtube",[["path",{d:"M2.5 17a24.12 24.12 0 0 1 0-10 2 2 0 0 1 1.4-1.4 49.56 49.56 0 0 1 16.2 0A2 2 0 0 1 21.5 7a24.12 24.12 0 0 1 0 10 2 2 0 0 1-1.4 1.4 49.55 49.55 0 0 1-16.2 0A2 2 0 0 1 2.5 17",key:"1q2vi4"}],["path",{d:"m10 15 5-3-5-3z",key:"1jp15x"}]]);/**
284 * @license lucide-react v0.344.0 - ISC
285 *
286 * This source code is licensed under the ISC license.
287 * See the LICENSE file in the root directory of this source tree.
288 */const nx=$("Zap",[["polygon",{points:"13 2 3 14 12 14 11 22 21 10 12 10 13 2",key:"45s27k"}]]),q=({children:e,variant:t="primary",size:n="md",onClick:r,href:s,className:i="",icon:o,type:l="button"})=>{const c="inline-flex items-center justify-center gap-2 rounded-full font-semibold transition-all duration-300 hover:scale-105 active:scale-95",u={primary:"bg-[#FF6600] text-white shadow-lg hover:bg-[#FF7722] hover:shadow-xl",secondary:"bg-transparent border-2 border-[#FF6600] text-[#FF6600] hover:bg-[#FF6600]/10",ghost:"bg-white/10 backdrop-blur-md text-white border border-white/20 hover:bg-white/20"},d={sm:"px-4 py-2 text-sm",md:"px-6 py-3 text-base",lg:"px-8 py-4 text-lg"},f=`${c} ${u[t]} ${d[n]} ${i}`;return s?a.jsxs("a",{href:s,className:f,children:[o&&a.jsx("span",{children:o}),e]}):a.jsxs("button",{type:l,onClick:r,className:f,children:[o&&a.jsx("span",{children:o}),e]})},K=({children:e,className:t="",hover:n=!1})=>{const r=n?"hover:scale-[1.02] hover:shadow-[0_20px_60px_rgba(0,102,255,0.3)] hover:-translate-y-1":"";return a.jsx("div",{className:`
289        bg-white/5 backdrop-blur-xl rounded-2xl p-6
290        border border-white/10 shadow-[0_8px_32px_rgba(0,0,0,0.3)]
291        transition-all duration-300
292        ${r}
293        ${t}
294      `,children:e})},Qu=({children:e,autoPlay:t=!1,interval:n=5e3,showDots:r=!0,className:s=""})=>{const[i,o]=x.useState(0),[l,c]=x.useState(!1);x.useEffect(()=>{if(t&&!l){const h=setInterval(()=>{o(m=>(m+1)%e.length)},n);return()=>clearInterval(h)}},[t,l,e.length,n]);const u=h=>{o(h)},d=()=>{o(h=>(h-1+e.length)%e.length)},f=()=>{o(h=>(h+1)%e.length)};return a.jsxs("div",{className:`relative ${s}`,onMouseEnter:()=>c(!0),onMouseLeave:()=>c(!1),children:[a.jsxs("div",{className:"flex items-center gap-3",children:[a.jsx("button",{onClick:d,className:"flex-shrink-0 w-10 h-10 rounded-full bg-black/60 backdrop-blur-sm text-white flex items-center justify-center hover:bg-[#FF6600]/80 hover:scale-110 transition-all duration-300 border border-white/20","aria-label":"Previous slide",children:a.jsx(qw,{className:"w-5 h-5"})}),a.jsx("div",{className:"overflow-hidden flex-1",children:a.jsx("div",{className:"flex transition-transform duration-500 ease-out",style:{transform:`translateX(-${i*100}%)`},children:e.map((h,m)=>a.jsx("div",{className:"min-w-full",children:h},m))})}),a.jsx("button",{onClick:f,className:"flex-shrink-0 w-10 h-10 rounded-full bg-black/60 backdrop-blur-sm text-white flex items-center justify-center hover:bg-[#FF6600]/80 hover:scale-110 transition-all duration-300 border border-white/20","aria-label":"Next slide",children:a.jsx(Gw,{className:"w-5 h-5"})})]}),r&&a.jsx("div",{className:"flex justify-center gap-2 mt-6",children:e.map((h,m)=>a.jsx("button",{onClick:()=>u(m),className:`w-2 h-2 rounded-full transition-all duration-300 ${m===i?"bg-gradient-to-r from-[#0066FF] to-[#00D9FF] w-8":"bg-white/30 hover:bg-white/50"}`,"aria-label":`Go to slide ${m+1}`},m))})]})},rx=({vimeoId:e,videoUrl:t,title:n,onClose:r})=>{x.useEffect(()=>{document.body.style.overflow="hidden";const i=o=>{o.key==="Escape"&&r()};return window.addEventListener("keydown",i),()=>{document.body.style.overflow="",window.removeEventListener("keydown",i)}},[r]);const s=t&&t.includes("youtube.com")?t+(t.includes("?")?"&autoplay=1":"?autoplay=1"):t;return ff.createPortal(a.jsx("div",{className:"fixed inset-0 flex items-center justify-center bg-black/90 backdrop-blur-sm",style:{zIndex:99999},onClick:r,children:a.jsxs("div",{className:"relative w-full mx-4",style:{maxWidth:"1100px"},onClick:i=>i.stopPropagation(),children:[a.jsx("button",{onClick:r,className:"absolute -top-12 right-0 w-10 h-10 rounded-full bg-white/10 hover:bg-white/20 flex items-center justify-center text-white transition-colors duration-200 border border-white/20","aria-label":"Close video",children:a.jsx($i,{className:"w-5 h-5"})}),a.jsx("div",{className:"relative rounded-xl overflow-hidden shadow-2xl bg-black",style:{paddingTop:"56.25%"},children:e?a.jsx("iframe",{src:`https://player.vimeo.com/video/${e}?badge=0&autopause=0&autoplay=1&byline=0&portrait=0&title=0&player_id=0&app_id=58479`,frameBorder:"0",allow:"autoplay; fullscreen; picture-in-picture; clipboard-write; encrypted-media;
294 web-share",referrerPolicy:"strict-origin-when-cross-origin",style:{position:"absolute",top:0,left:0,width:"100%",height:"100%"},title:n||"Vimeo Video"}):a.jsx("iframe",{src:s,frameBorder:"0",allow:"autoplay; fullscreen; picture-in-picture; clipboard-write; encrypted-media; web-share",referrerPolicy:"strict-origin-when-cross-origin",style:{position:"absolute",top:0,left:0,width:"100%",height:"100%"},title:n||"Video"})})]})}),document.body)},Xa=({imageSrc:e,videoUrl:t,vimeoId:n,title:r,className:s="",onClick:i,fullscreen:o=!1})=>{const[l,c]=x.useState(!1),[u,d]=x.useState(!1),f=()=>{o&&(n||t)?d(!0):(n||t)&&c(!0),i&&i()},h=()=>{d(!1)};if((t||n)&&l&&!o){const m=t&&t.includes("youtube.com")?t+(t.includes("?")?"&autoplay=1":"?autoplay=1"):t;return a.jsx("div",{className:`relative aspect-video bg-black rounded-xl overflow-hidden ${s}`,children:n?a.jsx("div",{style:{padding:"56.25% 0 0 0",position:"relative"},children:a.jsx("iframe",{src:`https://player.vimeo.com/video/${n}?badge=0&autopause=0&autoplay=1&byline=0&portrait=0&title=0&player_id=0&app_id=58479`,frameBorder:"0",allow:"autoplay; fullscreen; picture-in-picture; clipboard-write; encrypted-media; web-share",referrerPolicy:"strict-origin-when-cross-origin",style:{position:"absolute",top:0,left:0,width:"100%",height:"100%"},title:r||"Vimeo Video"})}):a.jsx("iframe",{src:m,className:"absolute top-0 left-0 w-full h-full",frameBorder:"0",allow:"autoplay; fullscreen; picture-in-picture; clipboard-write; encrypted-media; web-share",referrerPolicy:"strict-origin-when-cross-origin",title:r||"Video"})})}return a.jsxs(a.Fragment,{children:[a.jsxs("div",{className:`relative aspect-video bg-black rounded-xl overflow-hidden group cursor-pointer ${s}`,onClick:f,children:[a.jsx("img",{src:e,alt:r||"Video thumbnail",className:"w-full h-full object-cover"}),a.jsx("div",{className:"absolute inset-0 bg-gradient-to-t from-black/60 via-trans
294parent to-transparent"}),a.jsx("div",{className:"absolute bottom-8 left-1/2 -translate-x-1/2",children:a.jsx("div",{className:"w-20 h-20 rounded-full bg-[#FF6600]/90 backdrop-blur-md flex items-center justify-center border-2 border-white/50 group-hover:scale-110 group-hover:bg-[#FF6600] transition-all duration-300 shadow-[0_0_30px_rgba(255,102,0,0.5)]",children:a.jsx(oc,{className:"w-10 h-10 text-white fill-white ml-1"})})}),r&&a.jsx("div",{className:"absolute bottom-0 left-0 right-0 p-4",children:a.jsx("h3",{className:"text-white font-semibold text-lg drop-shadow-lg",children:r})})]}),u&&a.jsx(rx,{vimeoId:n,videoUrl:t,title:r,onClose:h})]})},Xu=({videoId:e,title:t,className:n=""})=>{const[r,s]=x.useState(!1),i=`https://img.youtube.com/vi/${e}/maxresdefault.jpg`,o=()=>{s(!0)};return r?a.jsx("div",{className:`aspect-[9/16] max-w-sm mx-auto ${n}`,children:a.jsx("iframe",{src:`https://www.youtube.com/embed/${e}?autoplay=1`,className:"w-full h-full rounded-lg",frameBorder:"0",allow:"accelerometer; autoplay; clipboard-write; encrypted-media; gyroscope; picture-in-picture",allowFullScreen:!0,title:t||`YouTube Short ${e}`})}):a.jsxs("div",{className:`aspect-[9/16] max-w-sm mx-auto relative group cursor-pointer rounded-lg overflow-hidden ${n}`,onClick:o,children:[a.jsx("img",{src:i,alt:t||"YouTube Short thumbnail",className:"w-full h-full object-cover"}),a.jsx("div",{className:"absolute inset-0 bg-gradient-to-t from-black/60 via-trans
294parent to-transparent"}),a.jsx("div",{className:"absolute top-1/2 left-1/2 -translate-x-1/2 -translate-y-1/2",children:a.jsx("div",{className:"w-20 h-20 rounded-full bg-[#FF6600]/90 backdrop-blur-md flex items-center justify-center border-2 border-white/50 group-hover:scale-110 group-hover:bg-[#FF6600] transition-all duration-300 shadow-[0_0_30px_rgba(255,102,0,0.5)]",children:a.jsx(oc,{className:"w-10 h-10 text-white fill-white ml-1"})})}),t&&a.jsx("div",{className:"absolute bottom-0 left-0 right-0 p-4",children:a.jsx("h3",{className:"text-white font-semibold text-sm drop-shadow-lg text-center",children:t})})]})},sx=({text:e,aspectRatio:t="video",className:n="",gradient:r="from-[#0F1F3C] via-[#0066FF]/20 to-black"})=>{const s={square:"aspect-square",video:"aspect-video",portrait:"aspect-[3/4]",wide:"aspect-[21/9]"};return a.jsxs("div",{className:`relative ${s[t]} bg-gradient-to-br ${r} rounded-xl overflow-hidden group ${n}`,children:[a.jsx("div",{className:"absolute inset-0 flex items-center justify-center",children:a.jsx("div",{className:"text-center px-6",children:a.jsx("div",{className:"text-white/40 font-medium text-sm uppercase tracking-wider",children:e})})}),a.jsx("div",{className:"absolute inset-0 bg-black/20 group-hover:bg-black/10 transition-all duration-300"})]})},ix=({quotes:e,speed:t=30})=>{const n=x.useRef(null);x.useEffect(()=>{const s=n.current;if(!s)return;let i,o=0;const l=()=>{o-=.5;const c=s.scrollWidth/2;Math.abs(o)>=c&&(o=0),s.style.transform=`translateX(${o}px)`,i=requestAnimationFrame(l)};return i=requestAnimationFrame(l),()=>{i&&cancelAnimationFrame(i)}},[t]);const r=[...e,...e];return a.jsxs("div",{className:"overflow-hidden relative",children:[a.jsx("div",{className:"absolute left-0 top-0 bottom-0 w-32 bg-gradient-to-r from-black to-transparent z-10"}),a.jsx("div",{className:"absolute right-0 top-0 bottom-0 w-32 bg-gradient-to-l from-black to-transparent z-10"}),a.jsx("div",{ref:n,className:"flex gap-4 py-4",style:{willChange:"transform"},children:r.map((s,i)=>a.jsx("div",{className:"flex-shrink-0 w-80",children:a.jsxs(K,{className:"p-4 h-full",children:[a.jsxs("p",{className:"text-xs text-white/70 italic leading-relaxed",children:['"',s,'"']}),a.jsx("p",{className:"text-xs text-[#FF6600] mt-2",children:"- Attendee"})]})},i))})]})},Zu=({logos:e,speed:t=30,theme:n="light"})=>{const r=x.useRef(null);x.useEffect(()=>{const l=r.current;if(!l)return;let c,u=0;const d=()=>{u-=.5;const f=l.scrollWidth/2;Math.abs(u)>=f&&(u=0),l.style.transform=`translateX(${u}px)`,c=requestAnimationFrame(d)};return c=requestAnimationFrame(d),()=>{c&&cancelAnimationFrame(c)}},[t]);const s=[...e,...e],i=n==="dark"?"from-black":"from-white",o="to-transparent";return a.jsxs("div",{className:"overflow-hidden relative",children:[a.jsx("div",{className:`absolute left-0 top-0 bottom-0 w-32 bg-gradient-to-r ${i} ${o} z-10`}),a.jsx("div",{className:`absolute right-0 top-0 bottom-0 w-32 bg-gradient-to-l ${i} ${o} z-10`}),a.jsx("div",{ref:r,className:"flex gap-12 py-8 items-center",style:{willChange:"transform"},children:s.map((l,c)=>a.jsx("div",{className:"flex-shrink-0 flex items-center justify-center h-24 w-48",children:a.jsx("img",{src:l,alt:`Client ${c+1}`,className:"max-h-full max-w-full object-contain transition-all duration-300 opacity-100 hover:scale-110"})},c))})]})},ax=[{videoId:"9zpLJOHYWoU",title:"Speaker Reel",subtitle:"High-energy keynote highlights"},{videoId:"SbDcLNELip0",title:"Speaker Reel",subtitle:"Leadership & championship moments"}];function ox({reel:e,index:t}){const[n,r]=x.useState(!1),s=`https://img.youtube.com/vi/${e.videoId}/maxresdefault.jpg`;return a.jsxs("div",{className:"relative group flex flex-col",style:{animationDelay:`${t*.15}s`},children:[a.jsxs("div",{className:"relative rounded-2xl overflow-hidden border-2 border-[#FF6600]/40 shadow-[0_0_40px_rgba(255,102,0,0.2)] group-hover:border-[#FF6600]/80 group-hover:shadow-[0_0_60px_rgba(255,102,0,0.4)] transition-all duration-500",children:[a.jsx("div",{className:"absolute inset-0 rounded-2xl bg-gradient-to-br from-[#FF6600]/10 via-trans
294parent to-transparent pointer-events-none z-10"}),a.jsx("div",{className:"absolute -inset-[1px] rounded-2xl bg-gradient-to-br from-[#FF6600]/60 via-transparent to-[#FF6600]/20 opacity-0 group-hover:opacity-100 transition-opacity duration-500 pointer-events-none",style:{zIndex:-1}}),n?a.jsx("div",{className:"aspect-video w-full",children:a.jsx("iframe",{src:`https://www.youtube.com/embed/${e.videoId}?autoplay=1`,className:"w-full h-full",frameBorder:"0",allow:"accelerometer; autoplay; clipboard-write; encrypted-media; gyroscope; picture-in-picture",allowFullScreen:!0,title:e.title})}):a.jsxs("div",{className:"aspect-video w-full relative cursor-pointer",onClick:()=>r(!0),children:[a.jsx("img",{src:s,alt:e.title,className:"w-full h-full object-cover transition-transform duration-700 group-hover:scale-105"}),a.jsx("div",{className:"absolute inset-0 bg-gradient-to-t from-black/80 via-black/20 to-transparent"}),a.jsx("div",{className:"absolute inset-0 flex items-center justify-center",children:a.jsx("div",{className:"w-20 h-20 rounded-full bg-[#FF6600] flex items-center justify-center shadow-[0_0_40px_rgba(255,102,0,0.7)] group-hover:scale-110 transition-transform duration-300 border-2 border-white/30",children:a.jsx(oc,{className:"w-9 h-9 text-white fill-white ml-1"})})}),a.jsx("div",{className:"absolute top-4 left-4",children:a.jsxs("span",{className:"inline-flex items-center gap-1.5 bg-[#FF6600] text-white text-xs font-bold px-3 py-1 rounded-full uppercase tracking-wider shadow-lg",children:[a.jsx("span",{className:"w-1.5 h-1.5 rounded-full bg-white animate-pulse"}),"Speaker Reel"]})})]})]}),a.jsxs("div",{className:"mt-5 px-1",children:[a.jsx("h3",{className:"text-xl font-bold text-white",children:e.title}),a.jsx("p",{className:"text-sm text-white/60 mt-1",children:e.subt
294itle})]})]})}function lx(){return a.jsxs("section",{id:"speaker-reels",className:"py-32 bg-gradient-to-b from-[#0a0a0a] to-black relative overflow-hidden",children:[a.jsxs("div",{className:"absolute inset-0 pointer-events-none",children:[a.jsx("div",{className:"absolute top-1/3 left-1/4 w-96 h-96 rounded-full bg-[#FF6600]/5 blur-[120px]"}),a.jsx("div",{className:"absolute bottom-1/3 right-1/4 w-96 h-96 rounded-full bg-[#FF6600]/5 blur-[120px]"})]}),a.jsx("div",{className:"container mx-auto px-6 relative z-10",children:a.jsxs("div",{className:"max-w-6xl mx-auto",children:[a.jsxs("div",{className:"text-center mb-16 animate-fade-up",children:[a.jsx("span",{className:"inline-block text-[#FF6600] text-sm font-bold uppercase tracking-[0.2em] mb-4",children:"Watch Dave in Action"}),a.jsxs("h2",{className:"text-5xl md:text-6xl font-black mb-6 text-white",children:["Speaker ",a.jsx("span",{className:"text-gradient",children:"Reels"})]}),a.jsx("p",{className:"text-xl text-white/70 max-w-2xl mx-auto",children:"See the energy, authenticity, and impact Dave brings to every stage"})]}),a.jsx("div",{className:"grid md:grid-cols-2 gap-10 max-w-5xl mx-auto animate-fade-up",style:{animationDelay:"0.2s"},children:ax.map((e,t)=>a.jsx(ox,{reel:e,index:t},e.videoId))}),a.jsx("div",{className:"text-center mt-14 animate-fade-up",style:{animationDelay:"0.4s"},children:a.jsxs("div",{className:"inline-flex flex-col sm:flex-row items-center gap-4",children:[a.jsxs("a",{href:"https://www.youtube.com/@davechristensen1215",target:"_blank",rel:"noopener noreferrer",className:"inline-flex items-center gap-3 bg-[#FF6600] hover:bg-[#e55c00] text-white font-bold px-8 py-4 rounded-xl transition-all duration-300 shadow-[0_0_30px_rgba(255,102,0,0.4)] hover:shadow-[0_0_50px_rgba(255,102,0,0.6)] hover:scale-105 text-base",children:[a.jsx(An,{className:"w-5 h-5"}),"Watch More on YouTube",a.jsx(Kw,{className:"w-4 h-4 opacity-70"})]}),a.jsx("a",{href:"#contact",className:"inline-flex items-center gap-3 bg-white/5 hover:bg-white/10 border border-white/20 hover:border-[#FF6600]/50 text-white font-bold px-8 py-4 rounded-xl transition-all duration-300 text-base",children:"Book Dave to Speak"})]})})]})})]})}const rp=x.createContext(void 0);function cx({children:e}){const[t,n]=x.useState([]),r=u=>{n(d=>d.find(h=>h.id===u.id)?d.map(h=>h.id===u.id?{...h,quantity:h.quantity+1}:h):[...d,{...u,quantity:1}])},s=u=>{n(d=>d.filter(f=>f.id!==u))},i=(u,d)=>{if(d<=0){s(u);return}n(f=>f.map(h=>h.id===u?{...h,quantity:d}:h))},o=()=>{n([])},l=t.reduce((u,d)=>u+d.price*d.quantity,0),c=t.reduce((u,d)=>u+d.quantity,0);return a.jsx(rp.Provider,{value:{items:t,addItem:r,removeItem:s,updateQuantity:i,clearCart:o,total:l,itemCount:c},children:e})}function cc(){const e=x.useContext(rp);if(e===void 0)throw new Error("useCart must be used within a CartProvider");return e}const ux=5;function dx({isOpen:e,onClose:t}){const{items:n,removeItem:r,updateQuantity:s,total:i,itemCount:o}=cc(),l=Kt();if(!e)return null;const c=n.reduce((h,m)=>h+m.quantity,0),u=c*ux,d=i+u,f=()=>{t(),l("/checkout")};return a.jsxs(a.Fragment,{children:[a.jsx("div",{className:"fixed inset-0 bg-black/60 backdrop-blur-sm z-50 transition-opacity",onClick:t}),a.jsxs("div",{className:"fixed right-0 top-0 h-full w-full max-w-md bg-black border-l border-white/10 z-50 shadow-2xl flex flex-col",children:[a.jsxs("div",{className:"flex items-center justify-between p-6 border-b border-white/10",children:[a.jsxs("div",{className:"flex items-center gap-3",children:[a.jsx(hs,{className:"w-6 h-6 text-[#FF6600]"}),a.jsxs("h2",{className:"text-2xl font-bold text-white",children:["Cart ",o>0&&a.jsxs("span",{className:"text-[#FF6600]",children:["(",o,")"]})]})]}),a.jsx("button",{onClick:t,className:"text-white/60 hover:text-white transition-colors",children:a.jsx($i,{className:"w-6 h-6"})})]}),a.jsx("div",{className:"flex-1 overflow-y-auto p-6",children:n.length===0?a.jsxs("div",{className:"flex flex-col items-center justify-center h-full text-center px-4",children:[a.jsx("div",{className:"w-20 h-20 rounded-full bg-white/5 border border-white/10 flex items-center justify-center mb-5",children:a.jsx(hs,{className:"w-9 h-9 text-white/20"})}),a.jsx("h3",{className:"text-white font-bold text-xl mb-2",children:"Your cart is empty"}),a.jsxs("p",{className:"text-white/50 text-sm mb-8 leading-relaxed",children:["Get your personally signed copy of",a.jsx("br",{}),a.jsx("span",{className:"text-white font-semibold",children:"YOUR 4th Down"})," by Coach Christensen."]}),a.jsxs("a",{href:"/#books",onClick:t,className:"flex items-center gap-2.5 bg-[#FF6600] hover:bg-[#e55c00] text-white font-bold px-6 py-3 rounded-xl transition-colors w-full justify-center mb-3",children:[a.jsx(Hw,{className:"w-5 h-5"}),"Shop the Book",a.jsx(ir,{className:"w-4 h-4"})]}),a.jsx("button",{onClick:t,className:"text-white/40 hover:text-white text-sm transition-colors",children:"Continue browsing"})]}):a.jsx("div",{className:"space-y-4",children:n.map(h=>a.jsxs("div",{className:"bg-white/5 backdrop-blur-md border border-white/10 rounded-xl p-4",children:[a.jsxs("div",{className:"flex justify-between items-start mb-3",children:[a.jsxs("div",{className:"flex-1",children:[a.jsx("h3",{className:"text-white font-bold mb-0.5",children:h.name}),a.jsx("p",{className:"text-[#FF6600] text-sm font-semibold",children:h.format}),a.jsx("p",{className:"text-white/40 text-xs mt-1",children:"Personally signed by Coach Christensen"})]}),a.jsx("button",{onClick:()=>r(h.id),className:"text-white/40 hover:text-red-500 transition-colors ml-2",title:"Remove item",children:a.jsx(tp,{className:"w-4 h-4"})})]}),a.jsxs("div",{className:"flex items-center justify-between",children:[a.jsxs("div",{className:"flex items-center gap-3",children:[a.jsx("button",{onClick:()=>s(h.id,h.quantity-1),className:"w-8 h-8 rounded-lg bg-white/10 hover:bg-white/20 flex items-center justify-center transition-colors",disabled:h.quantity<=1,children:a.jsx(Zf,{className:"w-4 h-4 text-white"})}),a.jsx("span",{className:"text-white font-semibold min-w-[2rem] text-center",children:h.quantity}),a.jsx("button",{onClick:()=>s(h.id,h.quantity+1),className:"w-8 h-8 rounded-lg bg-white/10 hover:bg-white/20 flex items-center justify-center transition-colors",children:a.jsx(ep,{className:"w-4 h-4 text-white"})})]}),a.jsxs("div",{className:"text-right",children:[a.jsxs("p",{className:"text-white font-bold text-lg",children:["$",(h.price*h.quantity).toFixed(2)]}),h.quantity>1&&a.jsxs("p",{className:"text-white/50 text-xs",children:["$",h.price.toFixed(2)," each"]})]})]})]}
294,h.id))})}),n.length>0&&a.jsxs("div",{className:"border-t border-white/10 p-6 bg-black/50",children:[a.jsxs("div",{className:"space-y-2 mb-4",children:[a.jsxs("div",{className:"flex items-center justify-between text-white/70",children:[a.jsxs("span",{children:["Subtotal (",c," ",c===1?"book":"books",")"]}),a.jsxs("span",{children:["$",i.toFixed(2)]})]}),a.jsxs("div",{className:"flex items-center justify-between text-white/70",children:[a.jsxs("div",{className:"flex items-center gap-1.5",children:[a.jsx(ds,{className:"w-3.5 h-3.5"}),a.jsx("span",{children:"Shipping & Handling"}),a.jsxs("span",{className:"text-white/40 text-xs",children:["($5.00 × ",c,")"]})]}),a.jsxs("span",{children:["$",u.toFixed(2)]})]}),a.jsxs("div",{className:"flex items-center justify-between pt-2 border-t border-white/10",children:[a.jsx("span",{className:"text-white font-bold text-lg",children:"Total"}),a.jsxs("span",{className:"text-[#FF6600] font-black text-2xl",children:["$",d.toFixed(2)]})]})]}),a.jsx(q,{onClick:f,className:"w-full",size:"lg",icon:a.jsx(Qf,{className:"w-5 h-5"}),children:"Proceed to Checkout"}),a.jsx("button",{onClick:t,className:"w-full mt-3 text-white/60 hover:text-white text-sm transition-colors",children:"Continue Shopping"})]})]})]})}function hx(){const[e,t]=x.useState(""),[n,r]=x.useState(""),[s,i]=x.useState(!1),[o,l]=x.useState(""),{signIn:c}=oa(),u=Kt(),d=async f=>{f.preventDefault(),i(!0),l("");const{error:h}=await c(e,n);h?l(h.message):u("/"),i(!1)};return a.jsx("div",{className:"min-h-screen bg-black flex items-center justify-center px-6",children:a.jsx("div",{className:"max-w-md w-full",children:a.jsxs(K,{children:[a.jsxs("div",{className:"text-center mb-8",children:[a.jsx("h1",{className:"text-3xl font-bold text-white mb-2",children:"Sign In"}),a.jsx("p",{className:"text-white/70",children:"Welcome back to your account"})]}),o&&a.jsx("div",{className:"mb-6 p-4 bg-red-500/20 border border-red-500/50 rounded-lg",children:a.jsx("p",{className:"text-red-200 text-sm",children:o})}),a.jsxs("form",{onSubmit:d,className:"space-y-6",children:[a.jsxs("div",{children:[a.jsx("label",{htmlFor:"email",className:"block text-sm font-medium text-white mb-2",children:"Email"}),a.jsx("input",{id:"email",type:"email",value:e,onChange:f=>t(f.target.value),required:!0,className:"w-full px-4 py-3 bg-white/5 border border-white/10 rounded-lg focus:outline-none focus:ring-2 focus:ring-[#FF6600] text-white",placeholder:"Enter your email"})]}),a.jsxs("div",{children:[a.jsx("label",{htmlFor:"password",className:"block text-sm font-medium text-white mb-2",children:"Password"}),a.jsx("input",{id:"password",type:"password",value:n,onChange:f=>r(f.target.value),required:!0,className:"w-full px-4 py-3 bg-white/5 border border-white/10 rounded-lg focus:outline-none focus:ring-2 focus:ring-[#FF6600] text-white",placeholder:"Enter your password"})]}),a.jsx(q,{type:"submit",disabled:s,className:"w-full",children:s?"Signing in...":"Sign In"})]}),a.jsx("div",{className:"mt-6 text-center",children:a.jsxs("p",{className:"text-white/70",children:["Don't have an account?"," ",a.jsx(_e,{to:"/signup",className:"text-[#FF6600] hover:text-[#FF8533] font-medium",children:"Sign up"})]})})]})})})}function fx(){const[e,t]=x.useState(""),[n,r]=x.useState(""),[s,i]=x.useState(""),[o,l]=x.useState(!1),[c,u]=x.useState(""),[d,f]=x.useState(""),{signUp:h}=oa(),m=Kt(),v=async w=>{if(w.preventDefault(),l(!0),u(""),f(""),n!==s){u("Passwords do not match"),l(!1);return}if(n.length<6){u("Password must be at least 6 characters long"),l(!1);return}const{error:b}=await h(e,n);b?u(b.message):(f("Account created successfully! You can now sign in."),setTimeout(()=>{m("/login")},2e3)),l(!1)};return a.jsx("div",{className:"min-h-screen bg-black flex items-center justify-center px-6",children:a.jsx("div",{className:"max-w-md w-full",children:a.jsxs(K,{children:[a.jsxs("div",{className:"text-center mb-8",children:[a.jsx("h1",{className:"text-3xl font-bold text-white mb-2",children:"Create Account"}),a.jsx("p",{className:"text-white/70",children:"Join us to access exclusive content"})]}),c&&a.jsx("div",{className:"mb-6 p-4 bg-red-500/20 border border-red-500/50 rounded-lg",children:a.jsx("p",{className:"text-red-200 text-sm",children:c})}),d&&a.jsx("div",{className:"mb-6 p-4 bg-green-500/20 border border-green-500/50 rounded-lg",children:a.jsx("p",{className:"text-green-200 text-sm",children:d})}),a.jsxs("form",{onSubmit:v,className:"space-y-6",children:[a.jsxs("div",{children:[a.jsx("label",{htmlFor:"email",className:"block text-sm font-medium text-white mb-2",children:"Email"}
294),a.jsx("input",{id:"email",type:"email",value:e,onChange:w=>t(w.target.value),required:!0,className:"w-full px-4 py-3 bg-white/5 border border-white/10 rounded-lg focus:outline-none focus:ring-2 focus:ring-[#FF6600] text-white",placeholder:"Enter your email"})]}),a.jsxs("div",{children:[a.jsx("label",{htmlFor:"password",className:"block text-sm font-medium text-white mb-2",children:"Password"}),a.jsx("input",{id:"password",type:"password",value:n,onChange:w=>r(w.target.value),required:!0,className:"w-full px-4 py-3 bg-white/5 border border-white/10 rounded-lg focus:outline-none focus:ring-2 focus:ring-[#FF6600] text-white",placeholder:"Enter your password"})]}),a.jsxs("div",{children:[a.jsx("label",{htmlFor:"confirmPassword",className:"block text-sm font-medium text-white mb-2",children:"Confirm Password"}),a.jsx("input",{id:"confirmPassword",type:"password",value:s,onChange:w=>i(w.target.value),required:!0,className:"w-full px-4 py-3 bg-white/5 border border-white/10 rounded-lg focus:outline-none focus:ring-2 focus:ring-[#FF6600] text-white",placeholder:"Confirm your password"})]}),a.jsx(q,{type:"submit",disabled:o,className:"w-full",children:o?"Creating account...":"Create Account"})]}),a.jsx("div",{className:"mt-6 text-center",children:a.jsxs("p",{className:"text-white/70",children:["Already have an account?"," ",a.jsx(_e,{to:"/login",className:"text-[#FF6600] hover:text-[#FF8533] font-medium",children:"Sign in"})]})})]})})})}const px="price_1T2D2SBMFHtTmXUwnNJirFxz",mx=5;function gx(){const e=Kt(),{items:t,total:n,removeItem:r,updateQuantity:s,clearCart:i}=cc(),[o,l]=x.useState(!1),[c,u]=x.useState(""),d=t.reduce((v,w)=>v+w.quantity,0),f=d*mx,h=n+f,m=async()=>{if(t.length!==0){l(!0),u("");try{const v=[];for(const g of t)v.push({price_id:g.priceId,quantity:g.quantity});v.push({price_id:px,quantity:d});const w="https://keowxarexirpioejclpt.supabase.co",b="eyJhbGciOiJIUzI1NiIsInR5cCI6IkpXVCJ9.eyJpc3MiOiJzdXBhYmFzZSIsInJlZiI6Imtlb3d4YXJleGlycGlvZWpjbHB0Iiwicm9sZSI6ImFub24iLCJpYXQiOjE3NzE0MjU4OTksImV4cCI6MjA4NzAwMTg5OX0.9sqVFHcF90HRp29POH-vWDRnSwaOLws_xGd4d4Y-U0c";let y;try{y=await fetch(`${w}/functions/v1/stripe-checkout`,{method:"POST",headers:{"Content-Type":"application/json",Authorization:`Bearer ${b}`,apikey:b},body:JSON.stringify({line_items:v,mode:"payment",success_url:`${window.location.origin}/success?session_id={CHECKOUT_SESSION_ID}`,cancel_url:`${window.location.origin}/checkout`})})}catch{throw new Error("Unable to reach payment server. Please check your connection and try again.")}const p=await y.json();if(!y.ok)throw new Error(p.error||"Failed to create checkout session");p.url&&(i(),window.location.href=p.url)}catch(v){u(v.message||"Something went wrong. Please try again.")}finally{l(!1)}}};return t.length===0?a.jsx("div",{className:"min-h-screen bg-black flex items-center justify-center py-32 px-6",children:a.jsxs("div",{className:"max-w-md mx-auto text-center",children:[a.jsx(hs,{className:"w-16 h-16 text-white/20 mx-auto mb-4"}),a.jsx("h2",{className:"text-3xl font-bold text-white mb-4",children:"Your cart is empty"}),a.jsx("p",{className:"text-white/60 mb-6",children:"Add some items to get started"}),a.jsx(q,{onClick:()=>e("/"),children:"Return to Home"})]})}):a.jsx("div",{className:"min-h-screen bg-black py-16 px-6",children:a.jsxs("div",{className:"max-w-5xl mx-auto",children:[a.jsxs("button",{onClick:()=>e("/"),className:"flex items-center gap-2 text-white/60 hover:text-white mb-8 transition-colors",children:[a.jsx(Li,{className:"w-5 h-5"}),"Back to Home"]}),a.jsx("h1",{className:"text-4xl font-black text-white mb-8",children:"Checkout"}),c&&a.jsx("div",{className:"mb-6 p-4 bg-red-500/20 border border-red-500/50 rounded-lg",children:a.jsx("p",{className:"text-red-200 text-sm",children:c})}),a.jsxs("div",{className:"grid lg:grid-cols-5 gap-8",children:[a.jsx("div",{className:"lg:col-span-3",children:a.jsxs(K,{children:[a.jsx("h2",{className:"text-xl font-bold text-white mb-5",children:"Order Items"}),a.jsx("div",{className:"space-y-4",children:t.map(v=>a.jsxs("div",{className:"bg-white/5 border border-white/10 rounded-xl p-4",children:[a.jsxs("div",{className:"flex justify-between items-start mb-3",children:[a.jsxs("div",{children:[a.jsx("h3",{className:"text-white font-bold",children:v.name}),a.jsx("p",{className:"text-[#FF6600] text-sm font-semibold",children:v.format}),a.jsx("p",{className:"text-white/40 text-xs mt-0.5",children:"Personally signed by Coach Christensen"})]}),a.jsx("button",{onClick:()=>r(v.id),className:"text-white/40 hover:text-red-500 transition-colors",title:"Remove",children:a.jsx(tp,{className:"w-4 h-4"})})]}),a.jsxs("div",{className:"flex items-center justify-between",children:[a.jsxs("div",{className:"flex items-center gap-3",children:[a.jsx("button",{onClick:()=>s(v.id,v.quantity-1),className:"w-8 h-8 rounded-lg bg-white/10 hover:bg-white/20 flex items-center justify-center transition-colors",disabled:v.quantity<=1,children:a.jsx(Zf,{className:"w-4 h-4 text-white"})}),a.jsx("span",{className:"text-white font-semibold min-w-[2rem] text-center",children:v.quantity}),a.jsx("button",{onClick:()=>s(v.id,v.quantity+1),className:"w-8 h-8 rounded-lg bg-white/10 hover:bg-white/20 flex items-center justify-center transition-colors",children:a.jsx(ep,{className:"w-4 h-4 text-white"})})]}),a.jsxs("div",{className:"text-right",children:[a.jsxs("p",{className:"text-white font-bold text-lg",children:["$",(v.price*v.quantity).toFixed(2)]}),v.quantity>1&&a.jsxs("p",{className:"text-white/40 text-xs",children:["$",v.price.toFixed(2)," each"]})]})]})]},v.id))}),a.jsx("div",{className:"mt-5 pt-5 border-t border-white/10 bg-white/5 rounded-xl p-4",children:a.jsxs("div",{className:"flex items-center gap-3",children:[a.jsx(ds,{className:"w-5 h-5 text-white/50 flex-shrink-0"}),a.jsxs("div",{children:[a.jsx("p",{className:"text-white/80 font-semibold text-sm",children:"Postage & Handling"}),a.jsx("p",{className:"text-white/40 text-xs",children:"$5.00 per book — direct order shipping"})]}),a.jsxs("span",{className:"ml-auto text-white/80 font-bold",children:["$",f.toFixed(2)]})]})})]})}),a.jsx("div",{className:"lg:col-span-2",children:a.jsx("div",{className:"sticky top-8",children:a.jsxs(K,{children:[a.jsx("h2",{className:"text-xl font-bold text-white mb-5",children:"Order Summary"}),a.jsxs("div",{className:"space-y-3 mb-5",children:[t.map(v=>a.jsxs("div",{className:"flex justify-between text-sm",children:[a.jsxs("span",{className:"text-white/70",children:[v.name," ",a.jsxs("span",{className:"text-[#FF6600]",children:["(",v.format,")"]})," × ",v.quantity]}),a.jsxs("span",{className:"text-white font-semibold",children:["$",(v.price*v.quantity).toFixed(2)]})]},v.id)),a.jsxs("div",{className:"flex justify-between text-sm text-white/70",children:[a.jsxs("span",{className:"flex items-center gap-1",children:[a.jsx(ds,{className:"w-3.5 h-3.5"}),"Shipping (",d," × $5.00)"]}),a.jsxs("span",{className:"text-white font-semibold",children:["$",f.toFixed(2)]})]})]}),a.jsxs("div",{className:"flex justify-between items-center py-4 border-t border-white/10 mb-5",children:[a.jsx("span",{className:"text-white font-bold text-lg",children:"Total"}),a.jsxs("span",{className:"text-[#FF6600] font-black text-3xl",children:["$",h.toFixed(2)]})]}),a.jsx(q,{onClick:m,disabled:o,className:"w-full mb-3",size:"lg",icon:a.jsx(Qf,{className:"w-5 h-5"}),children:o?"Redirecting...":"Pay Now"}),a.jsxs("div",{className:"flex items-center justify-center gap-2 text-white/40",children:[a.jsx(Zw,{className:"w-4 h-4 text-green-500/70"}),a.jsx("p",{className:"text-xs",children:"Secure checkout via Stripe. No account required."})]})]})})})]})]})})}function yx(){const[e]=ry(),t=Kt(),{user:n}=oa(),[r,s]=x.useState(!0),i=e.get("session_id");return x.useEffect(()=>{if(!n){t("/login");return}if(!i){t("/");return}const o=setTimeout(()=>{s(!1)},1500);return()=>clearTimeout(o)},[n,i,t]),r?a.jsx("div",{className:"min-h-screen bg-black flex items-center justify-center px-6",children:a.jsx("div",{className:"max-w-md w-full",children:a.jsx(K,{children:a.jsxs("div",{className:"text-center py-8",children:[a.jsx("div",{className:"animate-spin rounded-full h-12 w-12 border-b-2 border-[#FF6600] mx-auto mb-4"}),a.jsx("p",{className:"text-white/70",children:"Processing your order..."})]})})})}):a.jsx("div",{className:"min-h-screen bg-black flex items-center justify-center px-6",children:a.jsx("div",{className:"max-w-md w-full",children:a.jsx(K,{children:a.jsxs("div",{className:"text-center py-8",children:[a.jsxs("div",{className:"mb-6",children:[a.jsx(il,{className:"w-16 h-16 text-green-500 mx-auto mb-4"}),a.jsx("h1",{className:"text-3xl font-bold text-white mb-2",children:"Payment Successful!"}
294),a.jsx("p",{className:"text-white/70",children:"Thank you for your purchase. Your order has been confirmed."})]}),a.jsxs("div",{className:"bg-white/5 border border-white/10 rounded-lg p-4 mb-6",children:[a.jsx("p",{className:"text-sm text-white/70 mb-2",children:"Order ID:"}),a.jsx("p",{className:"text-white font-mono text-sm break-all",children:i})]}),a.jsxs("div",{className:"space-y-3",children:[a.jsx(q,{onClick:()=>t("/"),className:"w-full",icon:a.jsx(Yw,{className:"w-5 h-5"}),children:"Return to Home"}),a.jsx(q,{onClick:()=>t("/orders"),variant:"secondary",className:"w-full",icon:a.jsx(hs,{className:"w-5 h-5"}),children:"View Order History"})]}),a.jsx("div",{className:"mt-6 text-center",children:a.jsx("p",{className:"text-xs text-white/50",children:"You will receive a confirmation email shortly."})})]})})})})}function vx(){const e=Kt(),{user:t}=oa(),[n,r]=x.useState([]),[s,i]=x.useState(!0),[o,l]=x.useState("");x.useEffect(()=>{if(!t){e("/login");return}c()},[t,e]);const c=async()=>{try{const{data:h,error:m}=await Tn.from("stripe_user_orders").select("*").order("order_date",{ascending:!1});if(m)throw m;r(h||[])}catch(h){l(h.message||"Failed to fetch orders")}finally{i(!1)}},u=(h,m)=>new Intl.NumberFormat("en-US",{style:"currency",currency:m.toUpperCase()}).format(h/100),d=h=>new Date(h).toLocaleDateString("en-US",{year:"numeric",month:"long",day:"numeric",hour:"2-digit",minute:"2-digit"}),f=h=>{switch(h.toLowerCase()){case"completed":return"text-green-400";
294case"pending":return"text-yellow-400";case"canceled":return"text-red-400";default:return"text-white/70"}};return s?a.jsx("div",{className:"min-h-screen bg-black flex items-center justify-center px-6",children:a.jsx("div",{className:"animate-spin rounded-full h-12 w-12 border-b-2 border-[#FF6600]"})}):a.jsx("div",{className:"min-h-screen bg-black py-12 px-6",children:a.jsxs("div",{className:"max-w-4xl mx-auto",children:[a.jsxs("div",{className:"mb-8",children:[a.jsxs("button",{onClick:()=>e("/"),className:"flex items-center gap-2 text-white/70 hover:text-white transition-colors mb-4",children:[a.jsx(Li,{className:"w-4 h-4"}),"Back to Home"]}),a.jsx("h1",{className:"text-4xl font-bold text-white mb-2",children:"Order History"}),a.jsx("p",{className:"text-white/70",children:"View all your past purchases"})]}),o&&a.jsx("div",{className:"mb-6 p-4 bg-red-500/20 border border-red-500/50 rounded-lg",children:a.jsx("p",{className:"text-red-200 text-sm",children:o})}),n.length===0?a.jsx(K,{children:a.jsxs("div",{className:"text-center py-12",children:[a.jsx(ds,{className:"w-16 h-16 text-white/30 mx-auto mb-4"}),a.jsx("h3",{className:"text-xl font-semibold text-white mb-2",children:"No Orders Yet"}),a.jsx("p",{className:"text-white/70 mb-6",children:"You haven't made any purchases yet. Browse our products to get started."}),a.jsx(q,{onClick:()=>e("/"),children:"Browse Products"})]})}):a.jsx("div",{className:"space-y-4",children:n.map(h=>a.jsx(K,{children:a.jsxs("div",{className:"flex flex-col md:flex-row md:items-center justify-between gap-4",children:[a.jsxs("div",{className:"flex-1",children:[a.jsxs("div",{className:"flex items-center gap-3 mb-2",children:[a.jsx(ds,{className:"w-5 h-5 text-[#FF6600]"}),a.jsxs("h3",{className:"text-lg font-semibold text-white",children:["Order #",h.order_id]}),a.jsx("span",{className:`text-sm font-medium ${f(h.order_status)}`,children:h.order_status.charAt(0).toUpperCase()+h.order_status.slice(1)})]}),a.jsxs("div",{className:"flex items-center gap-2 text-white/70 text-sm mb-2",children:[a.jsx(Vw,{className:"w-4 h-4"}),d(h.order_date)]}),a.jsxs("p",{className:"text-xs text-white/50 font-mono",children:["Session: ",h.checkout_session_id]})]}),a.jsxs("div",{className:"text-right",children:[a.jsx("div",{className:"text-2xl font-bold text-[#FF6600] mb-1",children:u(h.amount_total,h.currency)}),a.jsxs("div",{className:"text-sm text-white/70",children:["Payment: ",h.payment_status]})]})]})},h.order_id))})]})})}const Pn=[{slug:"leadership-lessons-from-football",title:"Leadership Lessons from Football: What 40 Years of Coaching Taught Me",excerpt:"After four decades on the sidelines of Division I football, leadership keynote speaker Dave Christensen shares the most powerful lessons about leading people under pressure — and why they apply everywhere.",date:"January 2026",readTime:"6 min read",category:"Leadership",image:"/TROON_2025_1119_090809_0392_Tavits.jpg"},{slug:"how-leaders-perform-under-pressure",title:"How Leaders Perform Under Pressure: The 4th Down Mindset",excerpt:'Every leader faces their own "4th Down" — a high-stakes moment where hesitation means failure. Corporate motivational speaker Dave Christensen breaks down how championship leaders make the right call when it matters most.',date:"February 2026",readTime:"5 min read",category:"Performance",image:"/WhatsApp_Image_2026-02-11_at_02.01.15.jpeg"},{slug:"building-championship-culture",title:"Building a Championship Culture in Your Organization",excerpt:"Championship culture isn't about winning games — it's about the habits, standards, and accountability your team builds every single day. Leadership speaker Dave Christensen shares how to build it.",date:"February 2026",readTime:"7 min read",category:"Culture",image:"/DA66E9F7-14FC-405B-9BAC-F541EE56B50C_1_201_a.jpg"},{slug:"why-preparation-wins-high-stakes-moments",title:"Why Preparation Wins High-Stakes Moments",excerpt:"The leaders who perform best under pressure aren't the most talented — they're the most prepared. Motivational speaker Dave Christensen explains why attention to detail in preparation is the ultimate competitive advantage.",date:"March 2026",readTime:"5 min read",category:"High Performance",image:"/WhatsApp_Image_2026-02-19_at_04.23.38.jpeg"},{slug:"make-the-right-call-when-it-matters-most",title:"Make the Right Call When It Matters Most",excerpt:"Decision-making under pressure separates good leaders from great ones. Leadership keynote speaker Dave Christensen reveals the A.D.A.P.T. framework for making bold decisions with clarity and confidence.",date:"March 2026",readTime:"6 min read",category:"Decision Making",image:"/WhatsApp_Image_2026-02-19_at_04.23.21.jpeg"}];function wx(){return a.jsx("section",{id:"insights",className:"py-32 bg-white relative",children:a.jsx("div",{className:"container mx-auto px-6",children:a.jsxs("div",{className:"max-w-6xl mx-auto",children:[a.jsxs("div",{className:"text-center mb-16 animate-fade-up",children:[a.jsx("span",{className:"inline-block text-sm font-semibold tracking-widest text-[#FF6600] uppercase mb-4 border border-[#FF6600]/30 rounded-full px-4 py-1.5 bg-[#FF6600]/5",children:"Leadership Insights"}),a.jsxs("h2",{className:"text-5xl md:text-6xl font-black mb-6 text-gray-900",children:["Leadership ",a.jsx("span",{className:"bg-gradient-to-r from-[#FF6600] to-[#FF8533] bg-clip-text text-transparent",children:"Articles"})]}),a.jsx("p",{className:"text-xl text-gray-600 max-w-3xl mx-auto",children:"Practical leadership insights from corporate keynote speaker Dave Christensen — drawn from 40 years of coaching high-performance teams and leaders under pressure."})]}),a.jsx("div",{className:"grid md:grid-cols-2 lg:grid-cols-3 gap-8 animate-fade-up",style:{animationDelay:"0.2s"},children:Pn.map((e,t)=>a.jsxs(_e,{to:`/insights/${e.slug}`,className:"group bg-white rounded-2xl overflow-hidden border border-gray-100 shadow-md hover:shadow-xl hover:border-[#FF6600]/20 transition-all duration-300",children:[a.jsxs("div",{className:"relative h-48 overflow-hidden",children:[a.jsx("img",{src:e.image,alt:`Dave Christensen leadership keynote speaker - ${e.title}`,className:"w-full h-full object-cover transition-transform duration-500 group-hover:scale-105"}),a.jsx("div",{className:"absolute inset-0 bg-gradient-to-t from-black/60 to-transparent"}),a.jsx("span",{className:"absolute top-3 left-3 px-3 py-1 bg-[#FF6600] text-white text-xs font-bold rounded-full",children:e.category})]}),a.jsxs("div",{className:"p-6",children:[a.jsxs("div",{className:"flex items-center gap-3 text-xs text-gray-400 mb-3",children:[a.jsx("span",{children:e.date}),a.jsx("span",{children:"·"}),a.jsx("span",{children:e.readTime})]}),a.jsx("h3",{className:"font-black text-gray-900 mb-3 leading-tight group-hover:text-[#FF6600] transition-colors",children:e.title}),a.jsx("p",{className:"text-sm text-gray-600 leading-relaxed mb-4 line-clamp-3",children:e.excerpt}),a.jsxs("div",{className:"flex items-center gap-2 text-[#FF6600] text-sm font-semibold",children:[a.jsx("span",{children:"Read Article"}),a.jsx(ir,{className:"w-4 h-4 group-hover:translate-x-1 transition-transform"})]})]})]},e.slug))})]})})})}const xx={"leadership-lessons-from-football":{body:a.jsxs(a.Fragment,{children:[a.jsxs("p",{children:["I spent more than 40 years on the sidelines of college and professional football. From Division I programs to the NFL, I had the privilege of coaching hundreds of young men — and along the way, I learned the most important lessons weren't about schemes or plays. They were about ",a.jsx("strong",{children:"leadership"}),"."]}),a.jsxs("p",{children:["Those same lessons are what I now share as a ",a.jsx("strong",{children:"leadership keynote speaker"})," at corporate conferences, leadership summits, and team building events across the country. Here are the most powerful ones."]}),a.jsx("h2",{children:"1. Leadership Is a Daily Choice, Not a Title"}),a.jsx("p",{children:"The biggest misconception about leadership is that it comes with a title. A head coaching title doesn't make you a great leader — your daily choices do. Every day on the practice field, I saw players who were natural leaders and others who had captains' patches but weren't leading anyone."}),a.jsxs("p",{children:["In business, the same is true. A VP title doesn't automatically make someone a ",a.jsx("strong",{children:"corporate leader"}),". Leadership is built through daily habits — showing up prepared, communicating clearly, holding standards, and serving your team."]}),a.jsx("h2",{children:"2. Championship Culture Is Built in the Offseason"}),a.jsxs("p",{children:["The championships you win in November are built in January. The disciplined practices in the winter, the extra film sessions, the small details that nobody notices — that's what builds ",a.jsx("strong",{children:"championship culture"}),"."]}),a.jsx("p",{children:'For organizations, the "offseason" is the work you do when things are going well. Building accountability systems, developing your people, refining your processes — this is what creates high-performance teams that perform when the pressure is on.'}),a.jsx("h2",{children:"3. Adversity Reveals Character — and Creates It"}),a.jsxs("p",{children:["One of my coaching mentors told me early in my career: you don't build character through success, you reveal it. I believe that's partly right — but I also believe adversity actively ",a.jsx("em",{children:"creates"})," character when you choose to face it head-on."]}),a.jsxs("p",{children:["In football, the teams that develop ",a.jsx("strong",{children:"resilience"})," are the teams that face their losses honestly, study what went wrong, and come back better. The same is true in leadership. Failure isn't the enemy of great leadership — avoidance of failure is."]}),a.jsx("h2",{children:"4. The Best Leaders Make People Around Them Better"}),a.jsx("p",{children:"I've seen talented players who made great individual plays. But the best players I ever coached had a different gift — they made their teammates better. They raised the standard of everyone around them."}),a.jsxs("p",{children:["As a ",a.jsx("strong",{children:"motivational speaker"}),", this is the leadership trait I talk about most in corporate settings: y
294our value as a leader isn't measured by your personal performance, it's measured by the performance of your team."]}),a.jsx("h2",{children:"5. Attitude Is Always a Choice"}),a.jsx("p",{children:"You cannot control the weather, the referees, the injuries, or the competition. But you can control your attitude — every single day. In 40 years of coaching, the players who consistently chose a positive, competitive attitude outperformed more talented players who didn't."}),a.jsx("p",{children:'The "A" in my A.D.A.P.T. Game Plan stands for Attitude because it is the foundation of every other leadership trait. Choose it deliberately, every morning, before anything else happens.'}),a.jsx("p",{className:"border-l-4 border-[#FF6600] pl-4 italic text-lg font-medium",children:"Football gave me a laboratory for leadership. The plays are different, but the people — and the principles — are the same everywhere I've been."})]})},"how-leaders-perform-under-pressure":{body:a.jsxs(a.Fragment,{children:[a.jsxs("p",{children:["Every organization has its version of ",a.jsx("strong",{children:"4th and goal"}),". A deal on the line. A crisis to navigate. A leadership decision that will define the year. How leaders respond in those moments is what separates good organizations from great ones."]}),a.jsxs("p",{children:["As a ",a.jsx("strong",{children:"corporate keynote speaker"})," on leadership and performance under pressure, I've studied this my entire career — first on the football field, and now in boardrooms and conference rooms across the country."]}),a.jsx("h2",{children:'What Is a "4th Down" Moment?'}),a.jsx("p",{children:"In football, a 4th down is a decision point. You can play it safe — punt the ball away and hope for the best. Or you can go for it — accept the risk, execute your best play, and fight for the outcome you want."}),a.jsxs("p",{children:["In leadership and business, ",a.jsx("strong",{children:"4th Down moments"})," show up constantly:"]}),a.jsxs("ul",{children:[a.jsx("li",{children:"A key account is at risk and you need to decide whether to fight for it or let it go"}),a.jsx("li",{children:"Your team is underperforming and you need to have a difficult conversation"}),a.jsx("li",{children:"A competitor is making moves and you need to respond boldly or carefully"}),a.jsx("li",{children:"You have a major opportunity but the risk feels high"})]}),a.jsx("p",{children:"Most leaders, in these moments, default to the punt. They delay the decision, soften the message, or choose the safe path. But the leaders who build great organizations — they go for it."}),a.jsx("h2",{children:"The Psychology of Performing Under Pressure"}),a.jsx("p",{children:"What separates leaders who perform under pressure from those who crumble? In my experience, it comes down to three things:"}),a.jsx("h3",{children:"1. They Have a Framework"}),a.jsxs("p",{children:["High-performing leaders don't wing it under pressure — they have a ",a.jsx("strong",{children:"decision-making framework"})," they've practiced. My A.D.A.P.T. Game Plan is exactly that: a repeatable process for assessing a situation, committing to a course of action, and executing with confidence."]}),a.jsx("h3",{children:"2. They've Practiced Adversity"}),a.jsx("p",{children:"The best coaches I worked with didn't just prepare their teams for good conditions — they deliberately created adversity in practice. The leaders who perform best under pressure have been there before, at least mentally."}),a.jsx("h3",{children:"3. They Trust Their Team"}),a.jsx("p",{children:"No leader performs well under pressure alone. The leaders who shine in high-stakes moments have done the work in advance to build a team they trust — and to make sure their team trusts them."}),a.jsx("h2",{children:"Go For It"}),a.jsx("p",{children:"When your 4th Down comes — and it will — the question isn't whether you have enough talent or information. The question is: do you have the courage to go for it?"}),a.jsx("p",{className:"border-l-4 border-[#FF6600] pl-4 italic text-lg font-medium",children:"Performance under pressure is not about being fearless. It's about having a plan that gives you the confidence to act despite the fear."})]})},"building-championship-culture":{body:a.jsxs(a.Fragment,{children:[a.jsx("p",{children:"Culture is not a poster on the wall. It's not a set of values in a PowerPoint slide. Culture is what your people do when nobody is watching — the habits, standards, and behaviors that define how your organization operates every single day."}),a.jsxs("p",{children:["As a ",a.jsx("strong",{children:"leadership keynote speaker"})," who spent 40 years building winning programs, I've learned that ",a.jsx("strong",{children:"championship culture"})," is both harder and simpler than most organizations think."]}),a.jsx("h2",{children:"What Championship Culture Actually Is"}),a.jsx("p",{children:"In every great program I was part of, championship culture shared the same DNA:"}),a.jsxs("ul",{children:[a.jsxs("li",{children:[a.jsx("strong",{children:"High standards with 
294no exceptions."}),' The best teams held everyone — including stars — to the same standard. There were no "protected" players exempt from accountability.']}),a.jsxs("li",{children:[a.jsx("strong",{children:"Clarity of purpose."})," Everyone on the team understood the mission and how their role contributed to it."]}),a.jsxs("li",{children:[a.jsx("strong",{children:"Psychological safety within competitive intensity."})," Players could make mistakes in practice without fear of humiliation — but there was zero tolerance for lack of effort or preparation."]}),a.jsxs("li",{children:[a.jsx("strong",{children:"Leadership from every seat."})," Championship teams don't wait for the coaches to lead. The senior players lead. The quiet veterans lead. Leadership is distributed."]})]}),a.jsx("h2",{children:"How Organizations Build It"}),a.jsxs("p",{children:["For corporate teams, building ",a.jsx("strong",{children:"high-performance culture"})," requires the same ingredients — just applied to a different environment."]}),a.jsx("h3",{children:"1. Define Your Non-Negotiables"}),a.jsx("p",{children:"Every championship team has behaviors that are simply not up for debate. Being on time. Being prepared. Being honest. Define yours and enforce them consistently."}),a.jsx("h3",{children:"2. Celebrate the Right Things"}),a.jsx("p",{children:"What you celebrate in your organization signals what you value. If you only celebrate results, you're building a results-at-any-cost culture. Celebrate effort, accountability, and improvement to build a championship culture."}),a.jsx("h3",{children:"3. Make Every Person Feel Essential"}),a.jsx("p",{children:"On a championship team, the backup players matter as much as the starters — because they push the starters every day in practice. In your organization, every person on the team should understand that their role is essential to the mission."}),a.jsx("h2",{children:"Your Culture Is Built One Choice at a Time"}),a.jsx("p",{children:"Culture isn't built in an offsite retreat or an annual all-hands meeting. It's built in the thousands of small moments every day — the choice to have a hard conversation, the decision to hold someone accountable, the moment you choose to recognize someone publicly for doing the right thing."}),a.jsx("p",{className:"border-l-4 border-[#FF6600] pl-4 italic text-lg font-medium",children:"You're building your organizational culture right now — with every meeting, every decision, every standard you hold or let slide. Make it a championship one."})]})},"why-preparation-wins-high-stakes-moments":{body:a.jsxs(a.Fragment,{children:[a.jsx("p",{children:`Bobby Knight, one of the greatest coaches in the history of college basketball, once said: "The will to succeed is important, but what's more important is the will to prepare." In 40 years of coaching, I've found this to be profoundly true.`}),a.jsxs("p",{children:["As a ",a.jsx("strong",{children:"motivational speaker"})," for corporate organizations, I return to this principle constantly — because preparation is the most underrated competitive advantage in both sports and business."]}),a.jsx("h2",{children:"Why Preparation Matters More Than Talent"}),a.jsx("p",{children:"Early in my coaching career, I thought the teams with the best athletes would always win. Over time, I learned something different: the teams that prepared the most consistently outperformed more talented teams that didn't."}),a.jsx("p",{children:"Preparation does several things that raw talent cannot:"}),a.jsxs("ul",{children:[a.jsxs("li",{children:[a.jsx("strong",{children:"It reduces anxiety."})," When you've practiced a situation dozens of times, it doesn't feel new when it shows up in a high-stakes moment. Your body and mind know what to do."]}),a.jsxs("li",{children:[a.jsx("strong",{children:"It builds confidence."})," Confidence isn't swagger — it's the earned knowledge that you've done the work. You've prepared. You're ready."]}),a.jsxs("li",{children:[a.jsx("strong",{children:"It closes talent gaps."})," A less talented but better-prepared team can beat a more talented, less-prepared one. I've seen it happen."]})]}),a.jsx("h2",{children:'The "Attention to Detail" Principle'}),a.jsxs("p",{children:['The "A.D." in my ',a.jsx("strong",{children:"A.D.A.P.T. Game Plan"})," stands for Attention to Detail in Preparation. It's the third principle because it builds on Attitude and Discipline — and it's the one that separates good performers from great ones."]}),a.jsx("p",{children:"Attention to detail means:"}),a.jsxs("ul",{children:[a.jsx("li",{children:"Studying your customer or client the way a coach studies the opponent"}),a.jsx("li",{children:"Preparing for meetings with the same rigor you'd prepare for a championship game"}),a.jsx("li",{children:"Anticipating scenarios in advance so you're never caught flat-footed"}),a.jsx("li",{children:"Sweating the small things, because small things compound into big things"})]}),a.jsx("h2",{children:"How to Build a Preparation Culture"}),a.jsxs("p",{children:["For leaders, building a ",a.jsx("strong",{children:"high-performance preparation culture"})," starts with modeling it yourself. When your team sees you come to every meeting fully prepared — with answers thought through, data reviewed, scenarios anticipated — they raise the
294ir own standard."]}),a.jsx("p",{children:"Then you systematize it. Create preparation checklists. Do pre-mortems before important initiatives. Build rehearsal into your culture. Practice the hard conversations before you have them."}),a.jsx("p",{className:"border-l-4 border-[#FF6600] pl-4 italic text-lg font-medium",children:"Luck favors the prepared. The leaders and teams that win high-stakes moments are rarely the luckiest — they're the most prepared."})]})},"make-the-right-call-when-it-matters-most":{body:a.jsxs(a.Fragment,{children:[a.jsx("p",{children:"A football game comes down to dozens of decisions — from game-plan choices made in the coaches' office to split-second reads made at the line of scrimmage. The teams that win aren't always the most talented. They're the ones who make the right call when it matters most."}),a.jsxs("p",{children:["As a ",a.jsx("strong",{children:"corporate leadership keynote speaker"}),", I talk about decision-making under pressure more than almost any other topic — because it's the one that event planners and executives tell me their organizations struggle with most."]}),a.jsx("h2",{children:"Why Leaders Make Poor Decisions Under Pressure"}),a.jsx("p",{children:"The science of decision-making under stress is clear: when pressure is high, the brain defaults to fear-based, short-term thinking. You choose the safe option. You delay the decision. You second-guess yourself."}),a.jsx("p",{children:"In football, I watched talented players freeze in critical moments — not because they didn't know what to do, but because the pressure overwhelmed their preparation. The same thing happens to leaders in organizations every day."}),a.jsx("h2",{children:"The A.D.A.P.T. Framework for Decision-Making"}),a.jsx("p",{children:"My A.D.A.P.T. Game Plan isn't just a motivational framework — it's a practical tool for making better decisions under pressure:"}),a.jsxs("ul",{children:[a.jsxs("li",{children:[a.jsx("strong",{children:"Attitude:"})," Begin every high-stakes decision from a position of confidence, not fear. Your attitude in the moment shapes the quality of your judgment."]}),a.jsxs("li",{children:[a.jsx("strong",{children:"Discipline:"})," Stick to your process. Don't abandon your decision-making framework just because the situation feels urgent."]}),a.jsxs("li",{children:[a.jsx("strong",{children:"Attention to Detail in Preparation:"})," The best decisions in high-stakes moments were actually made weeks earlier, in the preparation phase — when you studied, anticipated, and planned."]}),a.jsxs("li",{children:[a.jsx("strong",{children:"Perseverance:"})," Accept that some decisions won't work out. Commit to learning from failures rather than avoiding future bold decisions."]}),a.jsxs("li",{children:[a.jsx("strong",{children:"Touchdown:"})," Celebrate good decision-making processes, not just good outcomes. This builds the muscle memory for the next high-stakes moment."]})]}),a.jsx("h2",{children:"The Courage to Go For It"}),a.jsx("p",{children:"The hardest part of decision-making under pressure isn't the intellectual work — it's the courage. Choosing to go for it on 4th down when a punt feels safer. Having the hard conversation you've been avoiding. Making the bold move when incremental action feels like less risk."}),a.jsx("p",{children:"The leaders I admire most aren't the ones who never doubted — they're the ones who acted despite doubt. They had a process, they trusted their preparation, and they had the courage to make the call."}),a.jsx("p",{className:"border-l-4 border-[#FF6600] pl-4 italic text-lg font-medium",children:"Great leaders don't wait for certainty. They build the preparation and the process that give them the confidence to act in the absence of certainty."})]})}};function bx(){const{slug:e}=h0(),t=Pn.find(o=>o.slug===e),n=e?xx[e]:null;if(!t||!n)return a.jsx("div",{className:"min-h-screen bg-white text-gray-900 flex items-center justify-center",children:a.jsxs("div",{className:"text-center",children:[a.jsx("h1",{className:"text-3xl font-black text-gray-900 mb-4",children:"Article Not Found"}),a.jsx(_e,{to:"/",className:"text-[#FF6600] hover:underline",children:"Return to Homepage"})]})});const r=Pn.findIndex(o=>o.slug===e),s=r>0?Pn[r-1]:null,i=r<Pn.length-1?Pn[r+1]:null;return a.jsxs("div",{className:"min-h-screen bg-white text-gray-900",children:[a.jsx("header",{className:"bg-[#f5f5f5]/95 backdrop-blur-xl border-b border-gray-200 shadow-md py-0 px-6",children:a.jsx("div",{className:"container mx-auto",children:a.jsxs("div",{className:"flex items-center justify-between h-24 md:h-28",children:[a.jsx(_e,{to:"/",className:"flex items-center",children:a.jsx("img",{src:"/header-2048x527_(1).png",alt:"Coach Dave Christensen - Leadership Keynote Speaker",className:"h-20 md:h-24 w-auto"})}),a.jsx(q,{href:"mailto:[email protected]?subject=Speaking Engagement Inquiry&body=Hi Dave,%0D%0A%0D%0AI'm interested in booking you for a speaking engagement.%0D%0A%0D%0AEvent Details:%0D%0AOrganization:%0D%0AEvent Date:%0D%0ALocation:%0D%0AExpected Audience Size:%0D%0A%0D%0APlease let me know your availability.%0D%0A%0D%0AThank you!",size:"md",children:"Book Dave"})]})})}),a.jsxs("div",{className:"relative h-72 md:h-96 overflow-hidden",children:[a.jsx("img",{src:t.image,alt:`Dave Christensen leadership keynote speaker - ${t.title}`,className:"w-full h-full object-cover"}),a.jsx("div",{className:"absolute inset-0 bg-gradient-to-t from-black via-black/60 to-black/20"}),a.jsxs("div",{className:"absolute bottom-0 left-0 right-0 p-8 container mx-auto max-w-3xl",children:[a.jsx("span",{className:"inline-block px-3 py-1 bg-[#FF6600] text-white text-xs font-bold rounded-full mb-3",children:t.category}),a.jsx("h1",{className:"text-3xl md:text-4xl lg:text-5xl font-black text-white leading-tight",children:t.title})]})]}),a.jsxs("div",{className:"container mx-auto max-w-3xl px-6 py-12",children:[a.jsxs("div",{className:"flex items-center gap-4 text-sm text-gray-400 mb-8 pb-8 border-b border-gray-100",children:[a.jsxs(_e,{to:"/#insights",className:"flex items-center gap-2 text-[#FF6600] hover:underline font-semibold",children:[a.jsx(Li,{className:"w-4 h-4"}),"All Insights"]}),a.jsx("span",{children:"·"}),a.jsx("span",{children:t.date}),a.jsx("span",{children:"·"}),a.jsx("span",{children:t.readTime}),a.jsx("span",{children:"·"}),a.jsx("span",{children:"By Dave Christensen"})]}),a.jsx("div",{className:"prose prose-lg max-w-none prose-headings:font-black prose-headings:text-gray-900 prose-p:text-gray-800 prose-p:leading-relaxed prose-li:text-gray-800 prose-strong:text-gray-900 prose-h2:text-2xl prose-h2:mt-10 prose-h2:mb-4 prose-h3:text-xl prose-h3:mt-8 prose-h3:mb-3 space-y-6",children:n.body}),a.jsxs("div",{className:"mt-16 p-8 bg-gradient-to-br from-black to-[#1a0800] rounded-2xl text-center",children:[a.jsx("h3",{className:"text-2xl font-black text-white mb-3",children:"Book Dave for Your Next Leadership Event"}),a.jsx("p",{className:"text-white/70 mb-6 max-w-xl mx-auto",children:"Bring these leadership insights to your corporate conference, leadership summit, or team event. Dave Christensen is available as a keynote speaker and leadership workshop facilitator."}),a.jsx(q,{href:"mailto:[email protected]?subject=Speaking Engagement Inquiry&body=Hi Dave,%0D%0A%0D%0AI'm interested in booking you for a speaking engagement.%0D%0A%0D%0AEvent Details:%0D%0AOrganization:%0D%0AEvent Date:%0D%0ALocation:%0D%0AExpected Audience Size:%0D%0A%0D%0APlease let me know your availability.%0D%0A%0D%0AThank you!",icon:a.jsx(Xf,{className:"w-5 h-5"}),children:"Request Availability"})]}),a.jsxs("div",{className:"mt-12 grid md:grid-cols-2 gap-6",children:[s&&a.jsxs(_e,{to:`/insights/${s.slug}`,className:"flex items-start gap-4 p-5 rounded-xl border border-gray-100 hover:border-[#FF6600]/30 hover:shadow-md transition-all group",children:[a.jsx(Li,{className:"w-5 h-5 text-gray-300 group-hover:text-[#FF6600] transition-colors flex-shrink-0 mt-1"}),a.jsxs("div",{children:[a.jsx("p",{className:"text-xs text-gray-400 mb-1 uppercase tracking-wide",children:"Previous"}),a.jsx("p",{className:"font-bold text-gray-900 text-sm leading-snug group-hover:text-[#FF6600] transition-colors",children:s.title})]})]}),i&&a.jsxs(_e,{to:`/insights/${i.slug}`,className:"flex items-start gap-4 p-5 rounded-xl border border-gray-100 hover:border-[#FF6600]/30 hover:shadow-md transition-all group md:text-right md:flex-row-reverse",children:[a.jsx(ir,{className:"w-5 h-5 text-gray-300 group-hover:text-[#FF6600] transition-colors flex-shrink-0 mt-1"}),a.jsxs("div",{children:[a.jsx("p",{className:"text-xs text-gray-400 mb-1 uppercase tracking-wide",children:"Next"}),a.jsx("p",{className:"font-bold text-gray-900 text-sm leading-snug group-hover:text-[#FF6600] transition-colors",children:i.title})]})]})]})]})]})}const _x=[{icon:np,value:"500+",label:"Events Delivered"},{icon:lc,value:"99%",label:"Find Valuable"},{icon:la,value:"40+",label:"Years Coaching"},{icon:Ur,value:"97%",label:"Would See Again"}],kx=[{icon:tx,title:"Corporate Leadership Keynote Speaker",description:"Dave delivers high-impact keynotes to Fortune 500 companies, mid-size organizations, and fast-growing teams. His message translates 40 years of high-stakes coaching into immediately actionable leadership frameworks for today's corporate environment."},{icon:nx,title:"Motivational Leadership Speaker",description:"Energy, authenticity, and relevance define every Dave Christensen keynote. He motivates audiences by connecting football's most pressure-packed moments to the real decisions leaders face daily in business and life."},{icon:ex,title:"Leadership Under Pressure",description:"When everything is on the line — a big deal, a tough quarter, a team in crisis — great leaders don't flinch. Dave teaches the mindset and systems that allow leaders to perform at their best when the stakes are highe
294st."},{icon:lc,title:"High-Performance Leadership",description:"High-performance teams are built on intentional culture, relentless preparation, and daily discipline. Dave's keynotes equip leaders to create environments where every person performs at their ceiling, every day."},{icon:la,title:"Leadership Lessons from Sports",description:"Over four decades on the sidelines of Division I college football and the NFL, Dave collected battle-tested leadership lessons that translate directly to the boardroom, the classroom, and every leadership challenge in between."}],jx=["Build belief in bold decision-making when stakes are high","Learn the A.D.A.P.T. Game Plan — a proven leadership framework","Develop championship culture within your team or organization","Strengthen personal accountability and daily discipline","Inspire audiences to stop playing it safe and start going for it","Create lasting motivation that outlives the event itself"],Sx=["Corporate Leadership Teams","Executive Conferences & Summits","Sales Kickoffs & Team Retreats","Universities & Athletic Departments","K-12 Schools & Staff Development","Non-Profit & Association Events"];function Nx(){return a.jsxs("div",{className:"min-h-screen bg-white text-gray-900",children:[a.jsx("header",{className:"bg-[#f5f5f5]/95 backdrop-blur-xl border-b border-gray-200 shadow-md py-0 px-6",children:a.jsx("div",{className:"container mx-auto",children:a.jsxs("div",{className:"flex items-center justify-between h-24 md:h-28",children:[a.jsx(_e,{to:"/",className:"flex items-center",children:a.jsx("img",{src:"/header-2048x527_(1).png",alt:"Coach Dave Christensen - Leadership Keynote Speaker",className:"h-20 md:h-24 w-auto"})}),a.jsxs("div",{className:"flex items-center gap-4",children:[a.jsx(_e,{to:"/#insights",className:"hidden md:block text-sm font-medium text-gray-600 hover:text-gray-900 transition-colors",children:"Insights"}),a.jsx(q,{href:"mailto:[email protected]?subject=Speaking Engagement Inquiry&body=Hi Dave,%0D%0A%0D%0AI'm interested in booking you for a speaking engagement.%0D%0A%0D%0AEvent Details:%0D%0AOrganization:%0D%0AEvent Date:%0D%0ALocation:%0D%0AExpected Audience Size:%0D%0A%0D%0APlease let me know your availability.%0D%0A%0D%0AThank you!",size:"md",children:"Book Dave"})]})]})})}),a.jsxs("section",{className:"relative bg-black text-white",children:[a.jsx("div",{className:"absolute inset-0 bg-cover bg-center opacity-20",style:{backgroundImage:"url('/WhatsApp_Image_2026-02-11_at_02.01.15.jpeg')"}}),a.jsx("div",{className:"absolute inset-0 bg-gradient-to-r from-black/90 via-black/70 to-black/30"}),a.jsx("div",{className:"relative container mx-auto px-6 pt-32 pb-20 md:pt-44 md:pb-36",children:a.jsxs("div",{className:"grid md:grid-cols-2 gap-10 items-center max-w-6xl mx-auto",children:[a.jsxs("div",{children:[a.jsxs("div",{className:"inline-flex flex-wrap items-center gap-2 bg-[#FF6600]/15 border border-[#FF6600]/30 text-[#FF6600] text-sm font-semibold px-4 py-2 rounded-full mb-8",children:[a.jsx(la,{className:"w-4 h-4"}),"Former Division I & NFL Coach"]}),a.jsx("h1",{className:"text-2xl sm:text-3xl md:text-5xl font-black leading-tight mb-8",children:"Leadership Keynote Speaker"}),a.jsx("p",{className:"text-lg md:text-xl text-white/80 leading-relaxed mb-5",children:"Dave Christensen — Corporate Motivational Speaker & Leadership Expert"}),a.jsx("p",{className:"text-base text-white/60 leading-relaxed mb-12",children:"40 years coaching college and professional football. One keynote that changes how your team shows up."}),a.jsxs("div",{className:"flex flex-col sm:flex-row items-start gap-4",children:[a.jsx(q,{href:"mailto:[email protected]?subject=Speaking Engagement Inquiry&body=Hi Dave,%0D%0A%0D%0AI'm interested in booking you for a speaking engagement.%0D%0A%0D%0AEvent Details:%0D%0AOrganization:%0D%0AEvent Date:%0D%0ALocation:%0D%0AExpected Audience Size:%0D%0A%0D%0APlease let me know your availability.%0D%0A%0D%0AThank you!",size:"lg",children:"Book Dave Now"}),a.jsxs(_e,{to:"/#speaking",className:"inline-flex items-center gap-2 text-white/80 hover:text-white font-medium transition-colors group mt-1 py-3",children:["View All Topics ",a.jsx(ir,{className:"w-4 h-4 group-hover:translate-x-1 transition-transform"})]})]})]}),a.jsx("div",{className:"relative flex justify-center md:justify-end",children:a.jsxs("div",{className:"relative w-full md:w-[560px]",children:[a.jsx("div",{className:"absolute -inset-1 bg-gradient-to-br from-[#FF6600]/40 to-transparent roun
294ded-2xl blur-xl"}),a.jsx("img",{src:"/WhatsApp_Image_2026-02-11_at_02.01.15.jpeg",alt:"Dave Christensen - Leadership Keynote Speaker",className:"relative rounded-2xl w-full object-contain shadow-2xl border border-white/10"})]})})]})})]}),a.jsx("section",{className:"bg-[#f5f5f5] border-y border-gray-200 py-12",children:a.jsx("div",{className:"container mx-auto px-6",children:a.jsx("div",{className:"grid grid-cols-2 md:grid-cols-4 gap-8",children:_x.map(e=>a.jsxs("div",{className:"text-center",children:[a.jsx(e.icon,{className:"w-7 h-7 text-[#FF6600] mx-auto mb-2"}),a.jsx("div",{className:"text-3xl font-black text-gray-900",children:e.value}),a.jsx("div",{className:"text-sm text-gray-500 font-medium",children:e.label})]},e.label))})})}),a.jsxs("section",{className:"py-20 container mx-auto px-6 max-w-5xl",children:[a.jsxs("div",{className:"text-center mb-14",children:[a.jsx("span",{className:"text-[#FF6600] text-sm font-bold uppercase tracking-widest",children:"Featured Keynote"}),a.jsx("h2",{className:"text-3xl md:text-5xl font-black text-gray-900 mt-3 mb-5",children:"YOUR 4th Down: Why You Need to Go For It"}),a.jsx("p",{className:"text-gray-600 text-lg leading-relaxed max-w-2xl mx-auto",children:"The signature keynote that meeting planners, event organizers, and HR leaders book Dave for again and again."})]}),a.jsxs("div",{className:"grid md:grid-cols-2 gap-10 items-center",children:[a.jsx("div",{children:a.jsx("img",{src:"/WhatsApp_Image_2026-02-11_at_02.01.15.jpeg",alt:"Dave Christensen delivering leadership keynote - YOUR 4th Down",className:"rounded-2xl w-full object-cover h-80 md:h-96 shadow-lg"})}),a.jsxs("div",{children:[a.jsx("p",{className:"text-gray-700 leading-relaxed mb-6",children:'YOUR 4th Down: Why You Need to Go For It is a high-energy keynote about making bold decisions when the stakes are high. Dave Christensen takes audiences inside pressure moments where one choice changes everything — then shows how to win your own "4th Down" moments in business and in life.'}),a.jsxs("p",{className:"text-gray-700 leading-relaxed mb-8",children:["Using the ",a.jsx("strong",{className:"text-gray-900",children:"A.D.A.P.T. Game Plan"})," (Attitude, Discipline, Attention to Detail, Perseverance, Touchdown), Dave delivers a fun, inspiring, practical message that builds belief, raises standards, and strengthens team connection."]}),a.jsxs("div",{className:"bg-gray-50 rounded-xl p-5 border border-gray-200",children:[a.jsx("div",{className:"text-xs font-bold uppercase tracking-widest text-gray-400 mb-3",children:"A.D.A.P.T. Game Plan"}),["Attitude — A choice we make daily that brings positive energy","Discipline — Doing what must be done, to the best of your ability","Attention to Detail — Always having a plan, sweating the small things","Perseverance — Learning to fail forward and turn setbacks into comebacks","Touchdown — Earning victory moments through the other four principles"].map(e=>a.jsxs("div",{className:"flex items-start gap-3 mb-2 last:mb-0",children:[a.jsx(il,{className:"w-4 h-4 text-[#FF6600] mt-0.5 flex-shrink-0"}),a.jsx("span",{className:"text-sm text-gray-700",children:e})]},e))]})]})]})]}),a.jsx("section",{className:"bg-gray-950 text-white py-20",children:a.jsxs("div",{className:"container mx-auto px-6 max-w-5xl",children:[a.jsxs("div",{className:"text-center mb-14",children:[a.jsx("span",{className:"text-[#FF6600] text-sm font-bold uppercase tracking-widest",children:"What Dave Speaks On"}),a.jsx("h2",{className:"text-3xl md:text-5xl font-black mt-3 mb-4",children:"Leadership Topics for Every Audience"}),a.jsx("p",{className:"text-white/60 text-lg max-w-xl mx-auto",children:"Every topic is customized to your event, your audience, and the outcomes you want to create."})]}),a.jsx("div",{className:"grid md:grid-cols-2 lg:grid-cols-3 gap-6",children:kx.map(e=>a.jsxs("div",{className:"bg-white/5 border border-white/10 rounded-2xl p-6 hover:border-[#FF6600]/40 hover:bg-white/8 transition-all duration-300",children:[a.jsx(e.icon,{className:"w-8 h-8 text-[#FF6600] mb-4"}),a.jsx("h3",{className:"text-lg font-bold text-white mb-3",children:e.title}),a.jsx("p",{className:"text-white/60 text-sm leading-relaxed",children:e.description})]},e.title))})]})}),a.jsx("section",{className:"py-20 container mx-auto px-6 max-w-5xl",children:a.jsxs("div",{className:"grid md:grid-cols-2 gap-16 items-start",children:[a.jsxs("div",{children:[a.jsx("span",{className:"text-[#FF6600] text-sm font-bold uppercase tracking-widest",children:"Audience Outcomes"}),a.jsx("h2",{className:"text-3xl md:text-4xl font-black text-gray-900 mt-3 mb-8",children:"What Your Audience Will Walk Away With"}),a.jsx("div",{className:"space-y-4",children:jx.map(e=>a.jsxs("div",{className:"flex items-start gap-3",children:[a.jsx(il,{className:"w-5 h-5 text-[#FF6600] mt-0.5 flex-shrink-0"}),a.jsx("span",{className:"text-gray-700 leading-relaxed",children:e})]},e))})]}),a.jsxs("div",{children:[a.jsx("span",{className:"text-[#FF6600] text-sm font-bold uppercase tracking-widest",children:"Who Dave Speaks For"}),a.jsx("h2",{className:"text-3xl md:text-4xl font-black text-gray-900 mt-3 mb-8",children:"Perfect For Your Event"}),a.jsx("div",{className:"grid grid-cols-1 gap-3",children:Sx.map(e=>a.jsxs("div",{className:"flex items-center gap-3 bg-[#f5f5f5] rounded-xl px-5 py-4 border border-gray-200",children:[a.jsx("div",{className:"w-2 h-2 bg-[#FF6600] rounded-full flex-shrink-0"}),a.jsx("span",{className:"font-medium text-gray-800",children:e})]},e))})]})]})}),a.jsx("section",{className:"bg-[#f5f5f5] border-y border-gray-200 py-20",children:a.jsxs("div",{className:"container mx-auto px-6 max-w-4xl",children:[a.jsxs("div",{className:"text-center mb-12",children:[a.jsx("span",{className:"text-[#FF6600] text-sm font-bold uppercase tracking-widest",children:"Social Proof"}),a.jsx("h2",{className:"text-3xl md:text-4xl font-black text-gray-900 mt-3",children:"What Meeting Planners & Audiences Say"})]}),a.jsx("div",{className:"grid md:grid-cols-2 gap-6",children:[{quote:"Dave's message hit home for every single person in the room. We have senior leaders quoting the A.D.A.P.T. framework weeks later.",name:"Fortune 500 HR Director",context:"Leadership Summit"},{quote:"We've had many keynote speakers, but Dave was the one our team kept talking about. He made leadership feel real, not theoretical.",name:"VP of Operations",context:"Sales Kickoff Event"},{quote:"Exactly what our students needed — practical, powerful, and delivered by someone who has lived every word of it.",n
294ame:"Athletic Director",context:"University Leadership Program"},{quote:"The energy Dave brings is unmatched. His keynote is the kind that changes how your team shows up — and keeps showing up.",name:"Conference Chair",context:"National Leadership Conference"}].map(e=>a.jsxs("div",{className:"bg-white rounded-2xl p-7 border border-gray-200 shadow-sm",children:[a.jsx("div",{className:"flex gap-1 mb-4",children:[...Array(5)].map((t,n)=>a.jsx(Ur,{className:"w-4 h-4 text-[#FF6600] fill-[#FF6600]"},n))}),a.jsxs("p",{className:"text-gray-700 italic leading-relaxed mb-5",children:['"',e.quote,'"']}),a.jsxs("div",{children:[a.jsx("div",{className:"font-bold text-gray-900 text-sm",children:e.name}),a.jsx("div",{className:"text-gray-500 text-xs",children:e.context})]})]},e.name))})]})}),a.jsxs("section",{className:"py-24 container mx-auto px-6 text-center max-w-3xl",children:[a.jsx("h2",{className:"text-3xl md:text-5xl font-black text-gray-900 mb-5",children:"Ready to Book a Leadership Keynote Speaker?"}),a.jsx("p",{className:"text-gray-600 text-lg leading-relaxed mb-10",children:"Dave Christensen is available for corporate events, leadership conferences, sales kickoffs, educational institutions, and more. Contact us today to check availability and receive a customized proposal."}),a.jsxs("div",{className:"flex flex-col sm:flex-row items-center justify-center gap-4",children:[a.jsx(q,{href:"mailto:[email protected]?subject=Speaking Engagement Inquiry&body=Hi Dave,%0D%0A%0D%0AI'm interested in booking you for a speaking engagement.%0D%0A%0D%0AEvent Details:%0D%0AOrganization:%0D%0AEvent Date:%0D%0ALocation:%0D%0AExpected Audience Size:%0D%0A%0D%0APlease let me know your availability.%0D%0A%0D%0AThank you!",size:"lg",children:"Book Dave for Your Event"}),a.jsxs(_e,{to:"/",className:"inline-flex items-center gap-2 text-gray-600 hover:text-gray-900 font-medium transition-colors group",children:["Learn More About Dave ",a.jsx(ir,{className:"w-4 h-4 group-hover:translate-x-1 transition-transform"})]})]})]}),a.jsx("footer",{className:"bg-gray-950 text-white/50 py-8 text-center text-sm border-t border-white/10",children:a.jsxs("p",{children:["© ",new Date().getFullYear()," Dave Christensen. Leadership Keynote Speaker."," ",a.jsx(_e,{to:"/",className:"hover:text-white transition-colors",children:"CoachChristensen.com"})]})})]})}const Ex=[{id:"prod_U0DTDKfF7IjTj4",priceId:"price_1T2D2SBMFHtTmXUwnNJirFxz",name:"Postage & Handling",price:5,currency:"usd",mode:"payment"},{id:"prod_Tuw1XS3cnPnUPp",priceId:"price_1Sx693BMFHtTmXUwr9suAXqf",name:"YOUR 4th Down: Why you need to Go For It (Paperback)",description:"Order Now! for your personal signed copy",price:19.95,currency:"usd",mode:"payment"},{id:"prod_TuvylrSegNkM1J",priceId:"price_1Sx66VBMFHtTmXUwQWSaq3KQ",name:"YOUR 4th Down: Why you need to Go For It (Hardcover)",description:"Order Now! for your personal signed copy",price:26.95,currency:"usd",mode:"payment"}];function Cx(){const[e,t]=x.useState(!1),[n,r]=x.useState(!1),[s,i]=x.useState(!1),[o,l]=x.useState(!0),[c,u]=x.useState({name:"",email:"",organization:"",message:""}),[d,f]=x.useState("idle"),{addItem:h,itemCount:m}=cc();x.useEffect(()=>{const k=()=>{t(window.scrollY>50)};return window.addEventListener("scroll",k),()=>window.removeEventListener("scroll",k)},[]);const v=k=>{k.preventDefault();const A=`Speaking Inquiry from ${c.name} - ${c.organization}`,M=`Name: ${c.name}
295Email: ${c.email}
296Organization: ${c.organization}
297
298Message:
299${c.message}`;window.location.href=`mailto:[email protected]?subject=${encodeURIComponent(A)}&body=${encodeURIComponent(M)}`,f("success"),u({name:"",email:"",organization:"",message:""})},w=[{label:"Home",href:"#home"},{label:"About",href:"#about"},{label:"Speaking",href:"#speaking"},{label:"Testimonials",href:"#testimonials"},{label:"Gallery",href:"#gallery"},{label:"Books",href:"#books"},{label:"Podcasts",href:"#podcasts"},{label:"Insights",href:"#insights"},{label:"Contact",href:"#contact"}],b=[{icon:lc,value:"99%",label:"Find Valuable"},{icon:np,value:"97%",label:"Would See Again"},{icon:la,value:"96%",label:"Actionable"}],y=[{title:"YOUR 4th Down: Why You Need to Go For It",duration:"30-60 minutes",audience:"Corporate Teams, Organizations & Leaders",description:'YOUR 4th Down: Why You Need to Go For It is a high-energy keynote about making bold decisions when the stakes are high. Former Division I co
299ach Dave Christensen takes audiences inside pressure moments where one choice changes everything—then shows how to win your own "4th Down" moments in business and life. Using the A.D.A.P.T. Game Plan (Attitude, Discipline, Attention to Detail, Perseverance, Touchdown), Dave delivers a fun, inspiring, practical message that builds belief, raises standards, and strengthens team connection. Audiences leave motivated—and equipped—to stop playing it safe and start going for it when it matters most.',outcomes:["Build belief in making bold decisions when stakes are high","Learn the A.D.A.P.T. Game Plan for winning pressure moments","Strengthen team connection and raise standards"],image:"/WhatsApp_Image_2026-02-11_at_02.01.15.jpeg",imagePosition:"70% center"},{title:"The A.D.A.P.T. Game Plan: A Playbook for Life and Leadership",duration:"45-60 minutes",audience:"Leaders, Teams & Organizations",description:"When faced with 4th downs in my life, I needed a plan to attack those situations. That's why I developed the A.D.A.P.T. Game Plan — a playbook for life and leadership. It's the framework that guided me through 40 years of coaching — and more importantly, throughout life. And I believe it can help you increase production, build consistency, and succeed — both personally and professionally. The A.D.A.P.T. Game Plan stands for: Attitude - A choice we make daily that brings positive energy; Discipline - Doing what must be done, when it must be done, to the best of your ability; Attention to Detail in Preparation - Always having a plan and focusing on the small things; Perseverance - Learning to fail forward and turn setbacks into comebacks; Touchdown - Earning victory moments through the application of the other principles. This framework helps you prepare for life's 4th down moments—when everything is on the line—giving you the confidence to make the choice to GO For It!",outcomes:["Learn how to choose a positive attitude that energizes yourself and those around you","Develop discipline as a superpower to create winning habits","Understand how attention to detail in preparation leads to success","Build resilience by learning to persevere through failures","Create a framework to face challenging decisions with confidence"],image:"/DA66E9F7-14FC-405B-9BAC-F541EE56B50C_1_201_a.jpg",imagePosition:"center center"},{title:"The Mindset of Championship Leaders",duration:"30-60 minutes",audience:"Schools, Teams & Organizations",description:`This presentation shares the core lessons Dave Christensen learned over 40 years of coaching college and professional football about what it takes to be a championship leader. The focus isn't on schemes or highlight reels—it's on mindset, habits, and character. A championship leader makes people around them better and raises the standard every day. The message applies to classrooms, businesses, and families: leadership is a choice, and your choices are building your future. Championship leaders are present and available, choose a great attitude daily, have a no-excuses mindset, practice self-discipline, sweat the details, understand they are the sum of their choices, serve as ambassadors of culture, and recognize what great teammates do. The presentation includes powerful stories like "The Carpenter" and reminds us that we are building our own "house" every day with our attitudes, habits, and choices. Championship leaders decide to build well—on purpose, with discipline, no excuses, and a relentless commitment to their team and their character.`,outcomes:["Stronger personal ownership of leadership. Attendees will recognize that leadership is a daily choice, not just a title, and leave committed to taking responsibility for their attitudes, habits, and performance.","Improved discipline and consistency. Attendees will learn simple, repeatable habits (showing up prepared, on time, focused) that require zero talent but dramatically raise their consistency and reliability.","Elevated team culture and accountability. Attendees will better understand how their actions affect the whole team and leave with practical ways to support teammates, eliminate excuses, and hold themselves to championship standards.",'Clearer goals and a "build your house well" mindset. Attendees will be equipped to set meaningful goals and make daily choices that build the kind of "house" (life, career, team) they actually want to live in.'],image:"/WhatsApp_Image_2026-02-19_at_04.23.38.jpeg",imagePosition:"center top"},{title:"Leading with Courage and Perseverance",duration:"45-60 minutes",audience:"K-12 Education & Staff Development",description:'This keynote shares lessons Dave Christensen learned over 40 years of coaching college and professional football and how they apply to leaders in education. Dave connects athletics and education, emphasizing that success depends on every person doing their job well and creating cohesion around a common purpose. The heart of the talk is leading with courage and perseverance—the mental and moral strength to do the right thing daily and moving forward despite difficulty. Dave shares inspiring stories of Abraham Lincoln and his own 
299journey to illustrate that courage and perseverance can change the trajectory of a life. He defines leadership as the ability to influence others for their benefit and introduces eight traits all great leaders share: Positive Attitude, Self-Discipline, Loyalty, Making Good Choices, Communication, Self-Motivation, Ambassadors of Culture, and Great Teammates. Dave closes with powerful images including the "lion and gazelle" story and "The Carpenter," reminding attendees that every day we are building the "house" we will live in with our attitudes and choices. His final challenge is to build wisely, lead with courage and perseverance, and use your influence to positively shape the lives of the students and colleagues you serve.',outcomes:["Own your influence as a leader. Attendees will understand that leadership is influence built on trust and empathy—and leave seeing themselves as leaders who can positively impact students, staff, and colleagues every day.","Apply courage and perseverance to real challenges. Attendees will learn how to respond to setbacks with resilience, using practical examples to keep moving forward when work and life get hard.","Integrate 8 core leadership traits into daily behavior. Attendees will walk away with a clear, simple framework—Positive Attitude, Self-Discipline, Loyalty, Good Choices, Communication, Self-Motivation, Culture Ambassador, and Great Teammate.","Strengthen team culture and cohesion. Attendees will recognize the vital role every classified staff member plays in student success and learn how to build a more unified culture across their school or district.","Adopt practical, zero-talent habits that raise performance. Attendees will leave with everyday habits—being on time, prepared, energetic, and accountable—that require no special talent but dramatically improve reliability, trust, and results."],image:"/WhatsApp_Image_2026-02-19_at_04.23.21.jpeg",imagePosition:"right center"}],p=[{text:"Having Dave Christensen as a keynote speaker at our Global Leadership Conference was one of the most impactful decisions we made for this year's program. Dave brings a rare blend of real-world leadership experience, storytelling prowess, and actionable strategy that resonated deeply with our audience. Drawing from decades of coaching at the highest levels, he challenged our leaders to embrace the vital '4th Down' moments in business, those defining times when the choice to go for it can unlock breakthrough performance and unity. Feedback from attendees was overwhelmingly positive: leaders walked away inspired, motivated, and ready to apply Dave's insights to both everyday challenges and high-stakes decisions. Dave's ability to connect athletic leadership principles with the realities of today's business landscape made his session both memorable and highly actionable. I'm confident his message will continue to inspire our organization long after the conference.",author:"Mike Ryan",role:"Chief Operating Officer",organization:"Troon",featured:!0},{text:"Hire Dave as a speaker for your upcoming events your audience will be so glad you did! Our corporate enjoyed listening to his remarkable journey as a football coach and motivational leader. Dave's storytelling about challenges and opportunities in his coaching career kept our team laughing and engaged throughout our time together. It was inspiring to hear how Dave led some of the most under dog teams to impressive successes. He has a natural gift for authenticity and a knack for making complex ideas accessible and exciting. I whole heartedly recommend Dave as a speaker who will showcase stories of leadership and invoke motivational prowess in your teams.",author:"Kara Mahoney",role:"Vice President, Account Management-Americas",organization:"Expeditors International"},{text:"Dave delivered more than motivation; he provided actionable A.D.A.P.T. strategies that our employees could implement right away. Our team left feeling more unified, energized, and motivated. Within days, our team took the comeback mentality to heart and landed an incredible deal!",author:"Jenny Bortman",role:"President/CEO",organization:"Universal Insurance Programs"},{text:"Dave was absolutely motivating and inspiring. He kept everyone on the edge of their seats with his topic. He hit so many great key points that were very easy to implement. I would have him speak for my company again!",author:"Oleg Bortman",role:"Co-Founder",organization:"The Brokery"},{text:"As the police chief I was looking for leadership training for my entire supervisory, middle management and executive team. Dave provided an exceptional presentation that was extremely well received by my staff. Using his experience as a coach he was able to bring together insightful examples of real life leadership situations that my staff was immediately able to put to use making them more effective leaders within our organization and community.",author:"Chief Art Miller (Retired)",role:"Police Chief",organization:"Peoria AZ Police Department"},{text:"Coach Christensen was outstanding when he presented his leadership presentation to our staff and team. He was knowledgeable, experienced, and motivating. I would highly recommend Dave to come speak to your school, team, or organization.",author:"Donnie Yantis",role:"Head Football Coach",organization:"Prestonwood Academy"},{text:"It was incredibly inspiring to listen to Dave at our conference - Lean TWI Summit. You are a truly inspiring figure and a practitioner in the field of leadership. I fully recommend you!",author:"Bartosz Misurek",role:"Promotor of Lean Management",organization:"P10 & Blockchain Technology Enthusiast"}],g=["Dave shared personal experiences that impacted his life, not a perfect person but never gave up. Dave shared that our attitude and choices we make will lead us to what it is that we want in life. We have to be thankful and blessed for being healthy and having a wonderful job regarding of our little. Being on time and responsible should take not much effort. Being passionate for your job will take you far on your journey.","Dave is an inspirational speaker. Amazing feedback. It made me reflect on how to be a better person and do a better job at what I do. Don't get me wrong, I love my job, but I could continually improve. Thank y
299ou, Dave, for your keynote today.","He speaks very well, has the skins on the wall, and has passion for what he does! The subject matter was very specific, nothing bad to say, he's done amazing things, I'd be more specific about those amazing accomplishments!","Has great reminders and in sight on leadership and what it is and attitude and how it costs nothing to have some of these skills to make you a better person and teammate to your family and colleagues. Very motivating","Definitely inspiring, the only thing I wished was interaction from the speaker with the audience. If that's not possible having everyone talk to a neighbor after key points.","Great speaker learned a lot about having a positive attitude and that it's up to me weather I make good choices and how those choices will affect me.","I will have to get his book as the hour we were fortunate to have with him left me wanting more knowledge to pursue a better team and self.","He delivers a clear message with great anecdotes. The combination with sports makes his presentation very relatable and relevant.","Great visuals and energy. It's nice to have a speaker that feels like they'd genuinely interact with you if you reached out."],_=["An inspiring summary of the life so far and career of a guy who got it done the hard way and the right way.","He was inspiring and his ADAPT presentation is something that would be great to introduce to our team.","I thoroughly enjoyed Dave's presentation— it was engaging, inspiring, funny and incredibly informative.","On point and what I needed to hear at this time!! Rejuvenated me to take back to my business and team!","Fundamentally accurate and inspiring. Focusing on the details sets everything else up for success.","Very relatable since I'm a college football fan and enjoyed the parallels and tie ins to business.","Great life reminders and a personal challenge to regroup in certain areas related to my career.","This session have great actionable ideas for improving property leadership and youth coaching.","Encouraging plans and discipline are the basics for success and this seminar instills that.","Dave is inspirational with his experience to success that applies to all aspects of life.","Very inspiring and engaging. It gave me a better perspective on my outlook for my future.","Great information and very informative! I needed the motivation today!!! Thanks Dave!!!","Relatable content and easily applicable to anyone regardless of position in life.","Very interesting inside info on what happens within the football coaching world.","Love his Leadership traits and the 10 Things that take no talent. Inspiring!","I already sent a pic of Dave's 'How to Gain an Edge' list to my five kids!!","Great energy very involved with the young audience. Real and to the point.","Informative, speaks about skills that we all have we just need to do it.","Very detailed- Great message- Great concept-Great Story- Well done.","Connected a lot of good thoughts across multiple different examples.","Great things for everyone to live by if they want to be their best.","How being adaptive can change everything. What my fourth down is.","Lots of great nuggets. Love the emphasis ATD and perseverance.","Simple, straightforward and engaging and thought provoking.","Dave communicated effectively and has an inspiring message.","Values i believe in. Your attitude and work is everything.","Motivating speaker and could run through a wall for Dave.","Very easy to understand and implement. Very motivating.","How to have Impactful leadership and motivate your team.","Enjoyed the stories and the formula for success.","Thank you for some great advice and inspiration.","Great speaker with a great message and attitude.","Very valuable life lesson and show up on time.","Prepare to overcome whatever comes your way.","It was very inspiring for sports and life.","Incredibly well done Actionable key note.","Awesome/inspiring and easily executable.","Very inspiring & positive information!!","Funny and encouraging. Very engaging.","It was very inspiring and encouraging!","Inspiring and use the adapt gameplay.","I too live my life by ADAPT game plan.","Great purpose, energy and motivating.","You missed a very Educational event.","Very inspirational and to the point.","Encouraged me to reflect on myself.","10 things that require zero talent.","Very positive, uplifting speaker!","Very informational and inspiring.","Very inspiring, I learned a lot.","Great speaker. Great messages.","On point and very inspiring.","Relevant to most industries.","Understandable and relatable.","Encouraging and descriptive.","Inspiring and motivating.","Relevant, honest, real.","Be positive. Inspire.","Extremely impactful!","good, inspirational.","Watch your thoughts.","Very inspirational.","Real and important.","10 positive things.","Very motivational.","Very inspiring.","Thank you coach!","Very instructive.","Super inspiring.","Very inspiring!","Brutally honest.","Very well done.","Inspirational.","Great speaker.","Inspirational.","Inspirational.","Motivational.","Motivational.","Informative.","Go for it!","Intresting.","Motivation.","Thank you.","Inspiring.","AWESOME!","Relevant.","Love it.","It's fun.","Inspired.","real."],j=[{title:"YOUR 4th Down",subtitle:"Why You Need to Go For It",description:"A thrilling blend of football strategy and life lessons that reframes risk, momentum, and decision-making. Drawing from nearly four decades of coaching experience, Dave shows you how stressful decisions can shape lives.",features:["How to recognize your true 4th down moments","How to reduce hesitation and fear-driven decisions","How to apply A.D.A.P.T to career, leadership, and personal crossroads"],image:"/Your_4th_down.png",amazonLink:"https://www.amazon.com/YOUR-4th-Down-Offensive-Strategy-ebook/dp/B0F7GNB7T7/ref=cm_cr_arp_d_product_top?ie=UTF8&language=en_US&currency=USD",formats:[{type:"Hardcover",price:"$26.95",link:"https://coachchristensen.com/hardcover"},{type:"Paperback",price:"$19.95",link:"https://coachchristensen.com/paperback"}]}],S=[{text:"Your 4th Down is one of those rare books that makes you stop, reflect, and rethink how you approach decisions when the pressure is real. Dave Christensen writes with authenticity and heart, sharing lessons that clearly come from lived experience, not theory. The stories are compelling, the insights are practical, and the message about accountability, courage, and commitment is incredibly timely.",author:"Amazon Customer",role:"Hardcover",date:"January 25, 2026",rating:5,title:"A powerful, honest book that stays with you"},{text:"I absolutely love this book! Tremendous insight into how a young man develops into a successful coach. A must read for anyone but especially for those entering into the coaching profession!",author:"Amazon Customer",role:"Paperback",date:"January 25, 2026",rating:5,title:"True success is about elevating those around you!"},{text:"This book carries powerful lessons beyond the gridiron. Christensen's personal tales and the ADAPT framework assisted me in dealing with a significant career decision with clarity and confidence. His method of turning hindrances into retaliations is transformative.",author:"John",role:"Paperback",date:"July 3, 2025",rating:5,title:"Highly recommend!"},{text:"This book is an outstanding reflection of Coach's experience, leadership, and commitment to excellence. Each chapter is intentional, clear, and rooted in principles that build strong teams, resilient individuals, and winning cultures. Whether you are a coach, athlete, or leader in any profession, the lessons are actionable and easy to implement.",author:"Amazon Customer",role:"Paperback",date:"January 25, 2026",rating:5,title:"YOUR 4th down"},{text:"Your fourth down book by Dave Christensen was tremendous! I highly recommend it to any person in a leadership role who wants to continue to strive to be excellent in all things. His leadership skills in this book are off the chart. Excellent!",author:"Donnie",role:"Hardcover",date:"January 25, 2026",rating:5,title:"Homerun Leadership Book!"},{text:`While this book is great for coaches, athletes and anyone in leadership, it cannot be overlooked as a guide for anyone who is able and willing to look at life's obstacles as opportunities. Learning about Christensen's method of "adapting" is worth the read.`,author:"Sandy P.",role:"Paperback",date:"February 2, 2026",rating:5,title:"Book for more than just sports fans"},{text:"A great story of perseverence and achievement and providing a blueprint for success in the face of adversity. Highly recommend!",author:"MB",role:"Paperback",date:"January 31, 2026",rating:5,title:"Playbook for Achievement"},{text:"As a long time friend, I've witnessed Dave as a winner at MIZZOU and every challenge afterwards. This book is a great blueprint for anyone serious about facing life's obstacles whether just starting a profession or taking success to the next level. A must read!",author:"Neil Riley",role:"Paperback",date:"January 28, 2026",rating:5,title:"Facing challenges"},{text:"Dave Christensen was a great coach and person to work alongside for a number of years at the Div. 1 level. Glad he is able to bring his experience and knowledge of leadership and coaching to anyone interested after his coaching c
299areer.",author:"Amazon Customer",role:"Paperback",date:"January 26, 2026",rating:4,title:"Excellent Coach!"},{text:'After Dave came to our office as a motivational keynote speaker, our team purchased his book—and it truly made an impact. The message was powerful and arrived at exactly the right time. We faced some real challenges in 2025, but by the end of the year we had our best year ever. This book helped fuel our comeback—we became the "comeback kids."',author:"Randyt",role:"Kindle",date:"January 25, 2026",rating:5,title:"Powerful Book for My Company"},{text:"This book gives great insight into how to achieve your goals in life. It helps to plan ahead, be prepared but most of all have a positive attitude and lastly make no excuses. This is a great book for all!!",author:"shelton",role:"Paperback",date:"January 26, 2026",rating:5,title:"Very Empowering!!"},{text:"This book provides great lessons for personal growth and self-improvement, as well as clear strategies to help you make decisions when building/improving successful teams.",author:"DM",role:"Paperback",date:"January 27, 2026",rating:5,title:"Great Blueprint for Personal and Team Successes"},{text:"What a book! The author shares an actual WORKING strategy to approach life and its challenges in an easy to read and digest format. Great insight for leaders in all walks of life on which you can build strong teams and establish a culture of success.",author:"Kent Loomer",role:"Paperback",date:"January 25, 2026",rating:5,title:"Leader or going to be? Read this book !!"},{text:"YOUR 4th down is a must! It is more than a book. It is a reference manual for the big decisions in your life, as well as, on the field. The ability to storytell and have it relate to daily situations is fantastic!",author:"Jim Harding",role:"Paperback",date:"January 25, 2026",rating:5,title:"Must Have"},{text:"I purchased this book and couldn't put it down. It's a great read and translates in life and in athletics. I own a business and coach 12u baseball and got a ton of great nuggets from this book!",author:"Amazon Customer",role:"Paperback",date:"January 25, 2026",rating:5,title:"Fantastic book"},{text:"As a long time friend and fellow teammate at the University of Washington, I absolutely love the insights and values Dave shares in his book. Thanks Dave!",author:"Robert",role:"Paperback",date:"January 25, 2026",rating:5,title:"Inspirational from a man of great leadership experience."},{text:"Practical, inspiring, and straight to the point. A great mindset book for coaches, athletes, and leaders who value preparation and accountability.",author:"R Hill",role:"Paperback",date:"January 26, 2026",rating:5,title:"Great Read for Coaches and Leaders"},{text:"Great read! Love the stories from specific games, and how Coach Christensen impacted their lives.",author:"Amazon Customer",role:"Paperback",date:"January 26, 2026",rating:5,title:"Great Read!"},{text:"Perfect read for the sports enthusiasts looking for great lessons to utilize in both their personal and professional life!",author:"amy buckley",role:"Paperback",date:"January 25, 2026",rating:5,title:"Highly recommend!!"},{text:"Love the book. A straight forward common sense approach to success in life. A great read for any business organization!",author:"Amazon Customer",role:"Paperback",date:"January 25, 2026",rating:5,title:"Great read"},{text:"Unbelievable book. Every parent needs to read this.",author:"Rodney Williams",role:"Paperback",date:"January 25, 2026",rating:5,title:"Fascinating book"},{text:"As a leader of a national sales organization I like to hire Athletes because they know the value of teamwork. The ADAPT framework that Dave Christensen outlines is perfect for success in many fields not just athletics. I learned new principles and enjoyed how Dave outlines his path to success. I highly recommend this read!",author:"AR",role:"Hardcover",date:"June 18, 2025",rating:5,title:"Excellent connect for all types of leaders."},{text:"This is an amazing book. Great insight to what coaches deal with in their personal and coaching careers. Everyone should read this book. It's also about life.",author:"Sue Nelson",role:"Hardcover",date:"June 15, 2025",rating:5,title:"Read this book"}
299],E=["/clients/1st-lean_(1).png","/clients/download_edited__1_-removebg-preview.png","/clients/Expeditors_(1).png","/clients/GettyImages-1823979425_b__1_-removebg-preview.png","/clients/omsd__1_-removebg-preview.png","/clients/PPD_(1).png","/clients/The-brokery_(1).png","/clients/ChatGPT_Image_Feb_24__2026__03_28_34_PM-removebg-preview.png","/clients/ChatGPT_Image_Feb_24__2026__03_28_39_PM-removebg-preview.png","/clients/ChatGPT_Image_Feb_24__2026__03_28_43_PM-removebg-preview.png","/clients/ChatGPT_Image_Feb_24__2026__03_28_48_PM-removebg-preview.png","/clients/ChatGPT_Image_Feb_24__2026__03_28_52_PM-removebg-preview.png","/clients/ChatGPT_Image_Feb_24__2026__03_30_42_PM-removebg-preview.png","/clients/ChatGPT_Image_Feb_24__2026__03_30_47_PM-removebg-preview.png","/clients/ChatGPT_Image_Feb_24__2026__03_30_51_PM-removebg-preview.png"],C=[{title:"Podcast Episode 1",platform:"Featured Interview",description:"Dave discusses leadership insights and championship strategies.",videoUrl:"https://www.youtube.com/embed/VOiVL4SrWYI?si=3S44OzsBv99R2UIb&controls=1&modestbranding=1&rel=0",thumbnailUrl:"https://img.youtube.com/vi/VOiVL4SrWYI/maxresdefault.jpg"},{title:"Podcast Episode 2",platform:"Featured Interview",description:"Sharing valuable coaching principles and life lessons.",videoUrl:"https://www.youtube.com/embed/dCIFDfUTXUo?si=h5ty5hkOMmLbGbb2&controls=1&modestbranding=1&rel=0",thumbnailUrl:"https://img.youtube.com/vi/dCIFDfUTXUo/maxresdefault.jpg"},{title:"Podcast Episode 3",platform:"Featured Interview",description:"Exploring championship mindset and leadership excellence.",videoUrl:"https://www.youtube.com/embed/0cZAadbwoo4?si=WtlmJaRXnSE6o3XX&controls=1&modestbranding=1&rel=0",thumbnailUrl:"https://img.youtube.com/vi/0cZAadbwoo4/maxresdefault.jpg"}];return a.jsxs("div",{className:"min-h-screen bg-white text-gray-900",children:[o&&a.jsx("div",{className:"fixed top-0 left-0 right-0 z-[60] bg-[#1a1a1a] text-white py-2 overflow-hidden",style:{height:"36px"},children:a.jsxs("div",{className:"flex items-center h-full",children:[a.jsx("div",{className:"flex-1 overflow-hidden relative",children:a.jsx("div",{className:"announcement-ticker flex items-center whitespace-nowrap",children:[0,1].map(k=>a.jsxs("span",{className:"inline-flex items-center gap-2 text-sm font-medium pr-16",children:[a.jsx(Ww,{className:"w-3.5 h-3.5 text-[#FF6600] flex-shrink-0 inline"}),a.jsx("span",{className:"text-white/90",children:"Signed copies shipped in the US only. For international orders, go to"}),a.jsx("a",{href:"https://www.amazon.com/YOUR-4th-Down-Offensive-Strategy-ebook/dp/B0F7GNB7T7/ref=cm_cr_arp_d_product_top?ie=UTF8&language=en_US&currency=USD",target:"_blank",rel:"noopener noreferrer",className:"underline underline-offset-2 text-[#FF6600] hover:text-white transition-colors font-semibold",onClick:A=>A.stopPropagation(),children:"Amazon.com"})]},k))})}),a.jsx("button",{onClick:()=>l(!1),className:"text-white/40 hover:text-white transition-colors flex-shrink-0 px-3","aria-label":"Dismiss",children:a.jsx($i,{className:"w-3.5 h-3.5"})})]})}),a.jsxs("header",{className:`fixed left-0 right-0 z-50 transition-all duration-300 bg-[#f5f5f5]/95 backdrop-blur-xl border-b border-gray-200 shadow-md ${o?"top-[36px]":"top-0"}`,children:[a.jsx("div",{className:"container mx-auto px-6",children:a.jsxs("div",{className:"flex items-center justify-between h-24 md:h-28",children:[a.jsx("a",{href:"#home",className:"flex items-center group",children:a.jsx("img",{src:"/header-2048x527_(1).png",alt:"Coach Dave Christensen - Leadership Keynote Speaker",className:"h-20 md:h-24 w-auto transition-all duration-300"})}),a.jsx("nav",{className:"hidden lg:flex items-center gap-8",children:w.map(k=>a.jsxs("a",{href:k.href,className:"text-sm font-medium text-gray-700 hover:text-black transition-colors relative group",children:[k.label,a.jsx("span",{className:"absolute -bottom-1 left-0 w-0 h-0.5 bg-gradient-to-r from-[#FF6600] to-[#FF8533] group-hover:w-full transition-all duration-300"})]},k.href))}),a.jsxs("div",{className:"hidden lg:flex items-center gap-4",children:[a.jsxs("button",{onClick:()=>i(!0),className:"relative text-gray-600 hover:text-black transition-colors",children:[a.jsx(Ju,{className:"w-5 h-5"}),m>0&&a.jsx("span",{className:"absolute -top-2 -right-2 bg-[#FF6600] text-white text-xs font-bold rounded-full w-5 h-5 flex items-center justify-center",children:m})]}),a.jsx("a",{href:"https://www.linkedin.com/in/dave-christensen-a0b78130",target:"_blank",rel:"noopener noreferrer",className:"text-gray-600 hover:text-black transition-colors",children:a.jsx(Ya,{className:"w-5 h-5"})}),a.jsx("a",{href:"https://www.instagram.com/koachc",target:"_blank",rel:"noopener noreferrer",className:"text-gray-600 hover:text-black transition-colors",children:a.jsx(Ka,{className:"w-5 h-5"})}),a.jsx("a",{href:"https://www.x.com/Koach_C",target:"_blank",rel:"noopener noreferrer",className:"text-gray-600 hover:text-black transition-colors",children:a.jsx(Qa,{className:"w-5 h-5"})}),a.jsx("a",{href:"https://www.talkadot.com/s/davechristensen",target:"_blank",rel:"noopener noreferrer",className:"text-gray-600 hover:text-black transition-colors",children:a.jsx(Ja,{className:"w-5 h-5"})}),a.jsx("a",{href:"https://www.youtube.com/@davechristensen1215",target:"_blank",rel:"noopener noreferrer",className:"text-gray-600 hover:text-black transition-colors",children:a.jsx(An,{className:"w-5 h-5"})}),a.jsx(q,{href:"mailto:[email protected]?subject=Speaking Engagement Inquiry&body=Hi Dave,%0D%0A%0D%0AI'm interested in booking you for a speaking engagement.%0D%0A%0D%0AEvent Details:%0D%0AOrganization:%0D%0AEvent Date:%0D%0ALocation:%0D%0AExpected Audience Size:%0D%0A%0D%0APlease let me know your availability.%0D%0A%0D%0AThank you!",size:"md",children:"Book Dave"})]}),a.jsx("button",{onClick:()=>r(!n),className:"lg:hidden text-gray-700",children:n?a.jsx($i,{className:"w-6 h-6"}):a.jsx(Qw,{className:"w-6 h-6"})})]})}),n&&a.jsx("div",{className:"lg:hidden bg-[#f5f5f5]/98 backdrop-blur-xl border-t border-gray-300",children:a.jsxs("nav",{className:"container mx-auto px-6 py-6 flex flex-col gap-4",children:[w.map(k=>a.jsx("a",{href:k.href,onClick:()=>r(!1),className:"text-lg font-medium text-gray-700 hover:text-black transition-colors",children:k.label},k.href)),a.jsxs("div",{className:"flex flex-col gap-4 mt-6 pt-6 border-t border-gray-200",children:[a.jsxs(q,{onClick:()=>{i(!0),r(!1)},variant:"secondary",className:"w-full relative",icon:a.jsx(Ju,{className:"w-5 h-5"}),children:["Shopping Cart ",m>0&&`(${m})`]}),a.jsx(q,{href:"mailto:[email protected]?subject=Speaking Engagement Inquiry&body=Hi Dave,%0D%0A%0D%0AI'm interested in booking you for a speaking engagement.%0D%0A%0D%0AEvent Details:%0D%0AOrganization:%0D%0AEvent Date:%0D%0ALocation:%0D%0AExpected Audience Size:%0D%0A%0D%0APlease let me know your availability.%0D%0A%0D%0AThank you!",size:"md",className:"w-full",children:"Book Dave"})]})]})})]}),a.jsxs("main",{className:o?"pt-[132px] md:pt-[148px]":"pt-24 md:pt-28",children:[a.jsxs("section",{id:"home",className:"relative hero-gradient overflow-hidden",children:[a.jsx("div",{className:"absolute inset-0 bg-[url('data:image/svg+xml;base64,PHN2ZyB3aWR0aD0iNjAiIGhlaWdodD0iNjAiIHZpZXdCb3g9IjAgMCA2MCA2MCIgeG1sbnM9Imh0dHA6Ly93d3cudzMub3JnLzIwMDAvc3ZnIj48ZyBmaWxsPSJub25lIiBmaWxsLXJ1bGU9ImV2ZW5vZGQiPjxwYXRoIGQ9Ik0zNiAxOGMzLjMxNCAwIDYgMi42ODYgNiA2cy0yLjY4
299NiA2LTYgNi02LTIuNjg2LTYtNiAyLjY4Ni02IDYtNnoiIHN0cm9rZT0icmdiYSgyNTUsMTAyLDAsMC4wNSkiLz48L2c+PC9zdmc+')] opacity-30"}),a.jsx("div",{className:"container mx-auto px-6 relative z-10 pt-8 md:pt-12 pb-8 min-h-[85vh] flex items-center",children:a.jsx("div",{className:"max-w-7xl mx-auto w-full",children:a.jsxs("div",{className:"grid lg:grid-cols-2 gap-12 lg:gap-16 items-center",children:[a.jsxs("div",{className:"text-center lg:text-left space-y-5 animate-fade-up",children:[a.jsx("h1",{className:"text-4xl md:text-5xl lg:text-6xl xl:text-7xl font-black leading-tight text-white",children:"Leadership Keynote Speaker Dave Christensen"}),a.jsx("p",{className:"text-lg md:text-xl lg:text-2xl text-[#FF6600] font-bold",children:"Corporate Keynote Speaker | Motivational Speaker | Former D1 & Pro Football Coach"}),a.jsx("p",{className:"text-xl md:text-2xl lg:text-3xl text-white font-bold leading-tight max-w-2xl mx-auto lg:mx-0",children:"Helping Leaders and Teams Perform When the Stakes Are Highest"}),a.jsx("p",{className:"text-base md:text-lg lg:text-xl text-white/90 leading-relaxed max-w-2xl mx-auto lg:mx-0",children:"Dave Christensen is a leadership keynote speaker and former Division I football coach who helps organizations, teams, and leaders perform at their best when the stakes are highest. Drawing on more than 40 years of coaching experience, Dave shares practical leadership lessons through his YOUR 4th Down message and A.D.A.P.T. Game Plan."}),a.jsxs("div",{className:"flex flex-col sm:flex-row gap-4 justify-center lg:justify-start pt-2",children:[a.jsx(q,{href:"mailto:[email protected]?subject=Speaking Engagement Inquiry&body=Hi Dave,%0D%0A%0D%0AI'm interested in booking you for a speaking engagement.%0D%0A%0D%0AEvent Details:%0D%0AOrganization:%0D%0AEvent Date:%0D%0ALocation:%0D%0AExpected Audience Size:%0D%0A%0D%0APlease let me know your availability.%0D%0A%0D%0AThank you!",size:"lg",children:"Book Dave to Speak"}),a.jsx(q,{href:"#speaking",variant:"secondary",size:"lg",children:"View Speaking Topics"})]})]}),a.jsx("div",{className:"animate-fade-up",style:{animationDelay:"0.2s"},children:a.jsx(K,{className:"p-0 overflow-hidden",children:a.jsx(Xa,{imageSrc:"/ChatGPT_Image_Feb_11,_2026,_01_43_36_AM.png",vimeoId:"1165481201",title:"Watch Dave's Speaker Reel",fullscreen:!0})})})]})})})]}),a.jsx("section",{className:"bg-white py-12",children:a.jsxs("div",{className:"container mx-auto px-6",children:[a.jsx("p",{className:"text-center text-sm text-gray-600 mb-8 uppercase tracking-wider font-semibold",children:"Trusted by Leading Organizations"}),a.jsx(Zu,{logos:E,theme:"light"})]})}),a.jsx("section",{className:"py-8 bg-black relative",children:a.jsx("div",{className:"container mx-auto px-6",children:a.jsx("div",{className:"max-w-4xl mx-auto",children:a.jsx("div",{className:"bg-gradient-to-r from-[#FF6600] to-[#FF8533] rounded-2xl p-8 shadow-[0_0_40px_rgba(255,102,0,0.4)] border-2 border-[#FF6600]/50",children:a.jsx("div",{className:"grid md:grid-cols-3 gap-6",children:b.map((k,A)=>{const M=k.icon;return a.jsxs("div",{className:"text-center",children:[a.jsx(M,{className:"w-8 h-8 mx-auto mb-2 text-white"}),a.jsx("div",{className:"text-3xl font-black text-white mb-1",children:k.value}),a.jsx("div",{className:"text-sm text-white/95 font-semibold",children:k.label})]},A)})})})})})}),a.jsx("section",{id:"about",className:"py-32 bg-black relative ambient-gradient",children:a.jsx("div",{className:"container mx-auto px-6",children:a.jsx("div",{className:"max-w-6xl mx-auto space-y-16",children:a.jsxs("div",{className:"grid lg:grid-cols-2 gap-16 items-start",children:[a.jsxs("div",{className:"animate-fade-up relative group",children:[a.jsx("div",{className:"absolute -inset-1 bg-gradient-to-r from-[#FF6600] to-[#FF8533] rounded-2xl blur opacity-75 group-hover:opacity-100 transition duration-300"}),a.jsx("div",{className:"relative",children:a.jsx("img",{src:"/ChatGPT_Image_Feb_11,_2026,_02_38_50_AM.png",alt:"Dave Christensen leadership keynote speaker presenting at corporate conference",className:"rounded-xl w-full h-auto shadow-2xl border-4 border-[#FF6600]/30"})})]}),a.jsxs("div",{className:"animate-fade-up space-y-6",style:{animationDelay:"0.2s"},children:[a.jsxs("h2",{className:"text-4xl md:text-5xl font-black text-white",children:["Championship Leadership",a.jsx("br",{}),a.jsx("span",{className:"text-gradient",children:"From the Field to Your Organization"})]}),a.jsx("p",{className:"text-xl text-white/80 leading-relaxed",children:"Dave Christensen is a motivational speaker and former Division I head football coach who spent more than 40 years developing leaders, building high-performance cultures, and winning under pressure. As a corporate keynote speaker, Dave helps organizations and leadership teams perform when the stakes are highe
299st."}),a.jsx("p",{className:"text-lg text-white/70 leading-relaxed",children:'Today he brings that same championship standard to businesses, schools, and teams as a leadership speaker, consultant, and author of "YOUR 4th Down: Why You Need to Go For It." His talks on performance under pressure, building championship culture, and leadership decision-making resonate with audiences across every industry.'}),a.jsxs("div",{className:"bg-white/10 backdrop-blur-md border border-white/20 rounded-2xl p-6 space-y-4",children:[a.jsx("h3",{className:"text-2xl font-bold text-[#FF6600]",children:"The A.D.A.P.T. Game Plan"}),a.jsxs("div",{className:"space-y-3",children:[a.jsxs("div",{className:"flex items-start gap-3",children:[a.jsx(Zt,{className:"w-6 h-6 text-[#FF6600] flex-shrink-0 mt-1"}),a.jsxs("div",{children:[a.jsx("p",{className:"font-bold text-white",children:"Attitude"}),a.jsx("p",{className:"text-white/80 text-sm",children:"Cultivate a winning mindset"})]})]}),a.jsxs("div",{className:"flex items-start gap-3",children:[a.jsx(Zt,{className:"w-6 h-6 text-[#FF6600] flex-shrink-0 mt-1"}),a.jsxs("div",{children:[a.jsx("p",{className:"font-bold text-white",children:"Discipline"}),a.jsx("p",{className:"text-white/80 text-sm",children:"Develop consistent habits and routines"})]})]}),a.jsxs("div",{className:"flex items-start gap-3",children:[a.jsx(Zt,{className:"w-6 h-6 text-[#FF6600] flex-shrink-0 mt-1"}),a.jsxs("div",{children:[a.jsx("p",{className:"font-bold text-white",children:"Attention to Detail in Preparation"}),a.jsx("p",{className:"text-white/80 text-sm",children:"Elevate performance through meticulous planning"})]})]}),a.jsxs("div",{className:"flex items-start gap-3",children:[a.jsx(Zt,{className:"w-6 h-6 text-[#FF6600] flex-shrink-0 mt-1"}),a.jsxs("div",{children:[a.jsx("p",{className:"font-bold text-white",children:"Perseverance"}),a.jsx("p",{className:"text-white/80 text-sm",children:"Overcome adversity with determination"})]})]}),a.jsxs("div",{className:"flex items-start gap-3",children:[a.jsx(Zt,{className:"w-6 h-6 text-[#FF6600] flex-shrink-0 mt-1"}),a.jsxs("div",{children:[a.jsx("p",{className:"font-bold text-white",children:"Touchdown"}),a.jsx("p",{className:"text-white/80 text-sm",children:"Celebrate victories and achieve greater success"})]})]})]})]}),a.jsx(q,{href:"mailto:[email protected]?subject=Speaking Engagement Inquiry&body=Hi Dave,%0D%0A%0D%0AI'm interested in booking you for a speaking engagement.%0D%0A%0D%0AEvent Details:%0D%0AOrganization:%0D%0AEvent Date:%0D%0ALocation:%0D%0AExpected Audience Size:%0D%0A%0D%0APlease let me know your availability.%0D%0A%0D%0AThank you!",variant:"primary",icon:a.jsx(ir,{className:"w-5 h-5"}),children:"Book Dave to Speak"})]})]})})})}),a.jsx("div",{className:"section-divider"}),a.jsx("section",{id:"speaking",className:"py-32 bg-gradient-to-b from-black to-[#0a0a0a] relative ambient-gradient",children:a.jsx("div",{className:"container mx-auto px-6",children:a.jsxs("div",{className:"max-w-6xl mx-auto",children:[a.jsxs("div",{className:"text-center mb-16 animate-fade-up",children:[a.jsxs("h2",{className:"text-5xl md:text-6xl font-black mb-6 text-white",children:["Leadership Keynote ",a.jsx("span",{className:"text-gradient",children:"Topics"})]}),a.jsx("p",{className:"text-xl text-white/80 max-w-3xl mx-auto",children:"Tailored leadership keynotes and workshops for corporate teams, conferences, and organizations. Each presentation on high-performance leadership, championship culture, and decision-making under pressure is customized to meet your specific needs and goals."})]}),a.jsx("div",{className:"grid gap-10 animate-fade-up",style:{animationDelay:"0.2s"},children:y.map((k,A)=>a.jsxs("div",{className:"group rounded-3xl overflow-hidden border border-white/10 bg-white/[0.03] shadow-[0_8px_40px_rgba(0,0,0,0.5)] hover:border-[#FF6600]/40 hover:shadow-[0_16px_60px_rgba(255,102,0,0.15)] transition-all duration-500",children:[a.jsxs("div",{className:"relative w-full overflow-hidden",style:{height:"420px"},children:[a.jsx("img",{src:k.image,alt:`Dave Christensen motivational speaker - ${k.title}`,className:"w-full h-full object-cover transition-transform duration-700 group-hover:scale-105",style:{objectPosition:k.imagePosition||"center center"}}),a.jsx("div",{className:"absolute inset-0 bg-gradient-to-t from-black via-black/50 to-transparent"}),a.jsx("div",{className:"absolute inset-0 bg-gradient-to-r from-black/40 to-transparent"}),a.jsx("div",{className:"absolute top-6 left-6",children:a.jsx("span",{className:"text-[120px] font-black leading-none text-white/[0.06] select-none",style:{fontFamily:"Space Grotesk, Inter, sans-serif"},children:String(A+1).padStart(2,"0")})}),a.jsxs("div",{className:"absolute bottom-0 left-0 right-0 p-8",children:[a.jsxs("div",{className:"flex flex-wrap items-center gap-3 mb-3",children:[a.jsx("span",{className:"px-3 py-1 bg-[#FF6600] rounded-full text-xs font-bold text-white tracking-wide uppercase",children:k.duration}),a.jsx("span",{className:"px-3 py-1 bg-white/10 backdrop-blur-sm border border-white/20 rounded-full text-xs text-white/80",children:k.audience})]}),a.jsx("h3",{className:"text-3xl md:text-4xl font-black text-white leading-tight",style:{fontFamily:"Space Grotesk, Inter, sans-serif"},children:k.title})]})]}
299),a.jsxs("div",{className:"p-8 md:p-10 grid md:grid-cols-5 gap-8",children:[a.jsx("div",{className:"md:col-span-3",children:a.jsx("p",{className:"text-white/70 leading-relaxed text-[15px]",children:k.description})}),a.jsxs("div",{className:"md:col-span-2",children:[a.jsx("p",{className:"text-xs font-bold text-[#FF6600] mb-4 uppercase tracking-widest",children:"Key Outcomes"}),a.jsx("div",{className:"space-y-3",children:k.outcomes.map((M,xe)=>a.jsxs("div",{className:"flex items-start gap-3",children:[a.jsx("div",{className:"w-5 h-5 rounded-full bg-[#FF6600]/20 border border-[#FF6600]/50 flex items-center justify-center flex-shrink-0 mt-0.5",children:a.jsx(Zt,{className:"w-3 h-3 text-[#FF6600]"})}),a.jsx("p",{className:"text-sm text-white/70 leading-relaxed",children:M})]},xe))})]})]})]},A))}),a.jsx("div",{className:"mt-16 text-center animate-fade-up",style:{animationDelay:"0.4s"},children:a.jsx(K,{className:"max-w-2xl mx-auto",children:a.jsxs("div",{className:"text-center",children:[a.jsx("h3",{className:"text-2xl font-bold mb-4 text-white",children:"Investment"}),a.jsx("p",{className:"text-4xl font-black text-[#FF6600] mb-4",children:"Starting at $5,000"}),a.jsx("p",{className:"text-white/70 mb-6",children:"Fee varies based on date, location, and engagement type. Custom workshops and multi-session engagements available."}),a.jsx(q,{href:"mailto:[email protected]?subject=Speaking Engagement Inquiry - Availability & Quote Request&body=Hi Dave,%0D%0A%0D%0AI'd like to request your availability and speaking fee quote.%0D%0A%0D%0AEvent Details:%0D%0AOrganization:%0D%0AEvent Date:%0D%0ALocation:%0D%0AExpected Audience Size:%0D%0AEngagement Type:%0D%0A%0D%0APlease share your availability and fee information.%0D%0A%0D%0AThank you!",size:"lg",children:"Request Availability & Quote"})]})})})]})})}),a.jsx("div",{className:"section-divider"}),a.jsx("section",{id:"testimonials",className:"py-32 bg-black relative ambient-gradient",children:a.jsx("div",{className:"container mx-auto px-6",children:a.jsxs("div",{className:"max-w-6xl mx-auto",children:[a.jsxs("div",{className:"text-center mb-16 animate-fade-up",children:[a.jsxs("h2",{className:"text-5xl md:text-6xl font-black mb-6 text-white",children:["What Clients ",a.jsx("span",{className:"text-gradient",children:"Say"})]}),a.jsx("p",{className:"text-xl text-white/80 max-w-3xl mx-auto",children:"Hear from event planners, executives, and leaders who've booked Dave Christensen as a leadership keynote speaker for their corporate conferences and leadership events."})]}),a.jsx("div",{className:"animate-fade-up mb-20",style:{animationDelay:"0.1s"},children:a.jsxs("div",{className:"relative",children:[a.jsx("div",{className:"absolute -inset-1 bg-gradient-to-r from-[#FF6600] via-[#FF8533] to-[#FF6600] rounded-3xl blur-2xl opacity-30 animate-pulse"}),a.jsxs("div",{className:"relative bg-gradient-to-br from-black via-[#1a0a00] to-black border-2 border-[#FF6600] rounded-3xl p-8 md:p-12 shadow-[0_0_60px_rgba(255,102,0,0.4)]",children:[a.jsx("div",{className:"flex items-center justify-center mb-6",children:a.jsx("span",{className:"px-6 py-2 bg-gradient-to-r from-[#FF6600] to-[#FF8533] text-white text-sm font-bold rounded-full shadow-lg",children:"⭐ FEATURED TESTIMONIAL"})}),a.jsx("div",{className:"flex justify-center mb-6",children:[...Array(5)].map((k,A)=>a.jsx(Ur,{className:"w-7 h-7 fill-[#FF6600] text-[#FF6600] mx-1"},A))}),a.jsxs("p",{className:"text-xl md:text-2xl text-white leading-relaxed mb-8 text-center italic font-light",children:['"',p[0].text,'"']}),a.jsxs("div",{className:"border-t-2 border-[#FF6600]/30 pt-6 text-center",children:[a.jsx("p",{className:"font-bold text-2xl mb-2 text-white",children:p[0].author}),a.jsx("p",{className:"text-lg text-[#FF6600] font-semibold mb-1",children:p[0].role}),a.jsx("p",{className:"text-lg text-white/80",children:p[0].organization})]})]})]})}),a.jsxs("div",{className:"animate-fade-up mb-16",style:{animationDelay:"0.3s"},children:[a.jsxs("h3",{className:"text-3xl font-bold text-center mb-8 text-white",children:["More Client ",a.jsx("span",{className:"text-gradient",children:"Testimonials"})]}),a.jsx(Qu,{autoPlay:!0,interval:5e3,children:p.slice(1).map((k,A)=>a.jsxs(K,{children:[a.jsx("div",{className:"flex mb-4",children:[...Array(5)].map((M,xe)=>a.jsx(Ur,{className:"w-5 h-5 fill-[#FF6600] text-[#FF6600]"},xe))}),a.jsxs("p",{className:"text-lg text-white/80 mb-6 leading-relaxed italic",children:['"',k.text,'"']}),a.jsxs("div",{className:"border-t border-white/10 pt-4",children:[a.jsx("p",{className:"font-bold text-white",children:k.author}),a.jsx("p",{className:"text-sm text-white/60",children:k.role}),a.jsx("p",{className:"text-sm text-[#FF6600]",children:k.organization})]})]},A))})]}),a.jsxs("div",{className:"animate-fade-up mb-12",style:{animationDelay:"0.4s"},children:[a.jsxs("h3",{className:"text-3xl font-bold text-center mb-8 text-white",children:["Featured ",a.jsx("span",{className:"text-gradient",children:"Attendee"})," Reviews"]}),a.jsx("div",{className:"grid md:grid-cols-2 lg:grid-cols-3 gap-4",children:g.map((k,A)=>a.jsxs(K,{className:"p-4",children:[a.jsxs("p",{className:"text-sm text-white/70 italic leading-relaxed mb-3",children:['"',k,'"']}),a.jsx("p",{className:"text-xs text-[#FF6600]",children:"- Event Attendee"})]},A))})]}),a.jsxs("div",{className:"animate-fade-up",style:{animationDelay:"0.5s"},children:[a.jsxs("h3",{className:"text-3xl font-bold text-center mb-8 text-white",children:["What ",a.jsx("span",{className:"text-gradient",children:"Attendees"})," Say"]}),a.jsx(ix,{quotes:_})]})]})})}),a.jsx("div",{className:"section-divider"}),a.jsx("section",{id:"gallery",className:"py-32 bg-gradient-to-b from-black to-[#0a0a0a] relative ambient-gradient",children:a.jsxs("div",{className:"w-full max-w-5xl mx-auto px-6",children:[a.jsxs("div",{className:"text-center mb-16 animate-fade-up",children:[a.jsx("span",{className:"inline-block text-sm font-semibold tracking-widest text-[#0066FF] uppercase mb-4 border border-[#0066FF]/30 rounded-full px-4 py-1.5 bg-[#0066FF]/10",children:"Behind The Scenes"}),a.jsxs("h2",{className:"text-5xl md:text-6xl font-black mb-6 text-white",children:["Event ",a.jsx("span",{className:"text-gradient",children:"Gallery"})]}),a.jsx("p",{className:"text-lg text-white/60 max-w-xl mx-auto",children:"See Dave in action at keynotes, workshops, and leadership conferences"})]}),a.jsx("div",{className:"animate-fade-up",style:{animationDelay:"0.2s"},children:a.jsx("div",{className:"relative rounded-2xl overflow-hidden shadow-2xl shadow-black/60 border border-white/10 bg-[#0a0a0a]",children:a.jsx(Qu,{autoPlay:!0,interval:4e3,children:["/TROON_2025_1119_090809_0392_Tavits.jpg","/TROON_2025_1119_090814_0397_Tavits.jpg","/TROON_2025_1119_090922_0417_Tavits.jpg","/TROON_2025_1119_091046_0473_Tavits.jpg","/TROON_2025_1119_091340_20117_Tavits.jpg","/TROON_2025_1119_091440_0527_Tavits.jpg","/TROON_2025_1119_093359_0572_Tavits.jpg","/TROON_2025_1119_094958_0594_Tavits.jpg","/TROON_2025_1119_095020_0604_Tavits.jpg","/TROON_2025_1119_095040_0620_Tavits.jpg","/TROON_2025_1119_100042_20276_Tavits.jpg","/TROON_2025_1119_100135_20289_Tavits.jpg","/TROON_2025_1119_100205_20294_Tavits.jpg","/6EBCD1A6-19FF-4DF2-96AD-2193923D07EB_1_201_a.jpg","/2D5E8914-44AE-40B2-9AFC-D2BF99F41A46_1_201_a.jpg","/3EC6C4C7-7D01-47A9-AE7D-B35C9B02F4F4_1_201_a.jpg","/817BF45C-E925-4DC7-96E6-D148F2CE903A_1_201_a.jpg","/IMG_4991_1.jpg","/IMG_4915_1_(1).jpg","/Screenshot_2024-11-27_182739_(1).png","/WhatsApp_Image_2026-02-19_at_04.22.42.jpeg","/WhatsApp_Image_2026-02-19_at_04.22.52.jpeg","/WhatsApp_Image_2026-02-19_at_04.23.21.jpeg","/WhatsApp_Image_2026-02-19_at_04.23.38.jpeg","/WhatsApp_Image_2026-02-19_at_04.27.58.jpeg","/WhatsApp_Image_2026-02-19_at_04.27.59.jpeg"].map((k,A)=>a.jsx("div",{className:"flex items-center justify-center bg-[#0a0a0a]",style:{height:"560px"},children:a.jsx("img",{src:k,alt:`Dave Christensen leadership keynote speaker at corporate conference event ${A+1}`,className:"max-w-full max-h-full object-contain",style:{display:"block",margin:"0 auto"}})},A))})})})]})}),a.jsx("div",{className:"section-divider"}),a.jsx("section",{id:"books",className:"py-32 bg-black relative ambient-gradient",children:a.jsx("div",{className:"container mx-auto px-6",children:a.jsxs("div",{className:"max-w-6xl mx-auto",children:[a.jsxs("div",{className:"text-center mb-16 animate-fade-up",children:[a.jsxs("h2",{className:"text-5xl md:text-6xl font-black mb-6 text-white",children:["Featured ",a.jsx("span",{className:"text-gradient",children:"Book"})]}),a.jsx("p",{className:"text-xl text-white/80 max-w-3xl mx-auto",children:"Leadership strategies and decisive action from 40 years of championship experience"})]}),a.jsx("div",{className:"animate-fade-up mb-16",style:{animationDelay:"0.2s"},children:j.map((k,A)=>
299a.jsxs("div",{className:"max-w-6xl mx-auto space-y-8",children:[a.jsxs("div",{className:"relative",children:[a.jsx("div",{className:"absolute -inset-1 bg-gradient-to-r from-[#FF6600] via-[#FF8533] to-[#FF6600] rounded-3xl blur-xl opacity-20"}),a.jsx(K,{className:"relative",children:a.jsxs("div",{className:"grid md:grid-cols-2 gap-8 lg:gap-12",children:[a.jsx("div",{className:"flex items-center justify-center",children:k.image?a.jsx("img",{src:k.image,alt:k.title,className:"w-full max-w-sm h-auto object-contain rounded-lg shadow-2xl"}):a.jsx(sx,{title:k.title,className:"h-96"})}),a.jsxs("div",{className:"flex flex-col justify-center",children:[a.jsxs("div",{className:"mb-6",children:[a.jsx("h3",{className:"text-4xl md:text-5xl font-black mb-3 text-white",children:k.title}),k.subtitle&&a.jsx("p",{className:"text-xl md:text-2xl text-[#FF6600] font-bold",children:k.subtitle})]}),a.jsx("p",{className:"text-lg text-white/80 mb-6 leading-relaxed",children:k.description}),a.jsxs("div",{className:"mb-6",children:[a.jsx("p",{className:"text-sm font-bold text-[#FF6600] mb-3 uppercase tracking-wider",children:"Key Insights:"}),a.jsx("div",{className:"space-y-3",children:k.features.map((M,xe)=>a.jsxs("div",{className:"flex items-start gap-3",children:[a.jsx(Zt,{className:"w-5 h-5 text-[#FF6600] flex-shrink-0 mt-0.5"}),a.jsx("p",{className:"text-white/80",children:M})]},xe))})]}),a.jsxs("div",{className:"space-y-4",children:[a.jsxs("div",{children:[a.jsx("p",{className:"text-sm font-semibold mb-3 text-white uppercase tracking-wider",children:"For your personal signed copy"}),a.jsx("p",{className:"text-base font-bold mb-3 text-[#FF6600]",children:"Order Direct From Coach Christensen!"}),a.jsx("div",{className:"grid grid-cols-2 gap-3",children:k.formats.map((M,xe)=>{const rt=Ex.find(hr=>hr.name.toLowerCase().includes(M.type.toLowerCase())&&hr.name.toLowerCase().includes("4th down"));return a.jsx("div",{className:"space-y-2",children:a.jsxs(q,{onClick:()=>{rt&&(h({id:rt.id,name:"YOUR 4th Down",price:rt.price,format:M.type,priceId:rt.priceId}),i(!0))},size:"sm",className:"flex-col h-auto py-3 w-full",children:[a.jsx(hs,{className:"w-4 h-4 mb-1"}),a.jsx("span",{className:"text-xs font-semibold",children:M.type}),a.jsx("span",{className:"text-white font-black text-xl",children:M.price}),a.jsx("span",{className:"text-white/60 text-xs",children:"+ $5.00 shipping/book"})]})},xe)})})]}),a.jsxs("div",{className:"pt-4 border-t border-white/10",children:[a.jsx("p",{className:"text-sm font-semibold mb-3 text-white/80 uppercase tracking-wider",children:"Also Available On Amazon:"}),a.jsx("div",{className:"space-y-3",children:a.jsx("a",{href:k.amazonLink,target:"_blank",rel:"noopener noreferrer",className:"inline-block",children:a.jsx("img",{src:"/amazon_logo.svg.png",alt:"Order on Amazon",className:"h-12 w-auto hover:opacity-80 transition-opacity duration-300"})})})]})]})]})]})})]}),a.jsx("div",{className:"relative",children:a.jsxs(K,{children:[a.jsxs("div",{className:"text-center mb-6",children:[a.jsx("h3",{className:"text-2xl md:text-3xl font-bold text-white mb-2",children:"Watch the Book Trailer"}),a.jsx("p",{className:"text-white/70",children:"See why leaders are calling this a game-changing read"})]}),a.jsx("div",{className:"max-w-3xl mx-auto",children:a.jsx(Xa,{imageSrc:"/WhatsApp_Image_2026-01-22_at_21.05.55_(1).jpeg",vimeoId:"1163774087",title:"Book Trailer",className:"aspect-video"})})]})})]},A))}),a.jsxs("div",{className:"animate-fade-up",style:{animationDelay:"0.4s"},children:[a.jsxs("h3",{className:"text-3xl font-bold text-center mb-8 text-white",children:["Amazon ",a.jsx("span",{className:"text-gradient",children:"Reviews"})]}),a.jsx("div",{className:"grid md:grid-cols-2 lg:grid-cols-3 gap-6",children:S.map((k,A)=>a.jsxs(K,{children:[a.jsx("div",{className:"flex mb-3",children:[...Array(k.rating)].map((M,xe)=>a.jsx(Ur,{className:"w-4 h-4 fill-[#FF6600] text-[#FF6600]"},xe))}),a.jsx("h4",{className:"font-bold text-sm mb-2 text-white",children:k.title}),a.jsxs("p",{className:"text-white/70 mb-3 italic leading-relaxed text-sm",children:['"',k.text,'"']}),a.jsxs("div",{className:"border-t border-white/10 pt-3",children:[a.jsx("p",{className:"font-bold text-xs text-[#FF6600]",children:k.author}),a.jsxs("p",{className:"text-xs text-white/60",children:[k.role," - ",k.date]})]})]},A))})]})]})})}),a.jsx("div",{className:"section-divider"}),a.jsx("section",{id:"podcasts",className:"py-32 bg-gradient-to-b from-black to-[#0a0a0a] relative ambient-gradient",children:a.jsx("div",{className:"container mx-auto px-6",children:a.jsxs("div",{className:"max-w-6xl mx-auto",children:[a.jsxs("div",{className:"text-center mb-16 animate-fade-up",children:[a.jsxs("h2",{className:"text-5xl md:text-6xl font-black mb-6 text-white",children:["Podcast ",a.jsx("span",{className:"text-gradient",children:"Appearances"})]}),a.jsx("p",{className:"text-xl text-white/80 max-w-3xl mx-auto",children:"Listen to Dave share leadership insights and championship strategies on leading podcasts"})]}),a.jsx("div",{className:"grid md:grid-cols-2 gap-8 max-w-5xl mx-auto animate-fade-up",style:{animationDelay:"0.2s"},children:C.map((k,A)=>a.jsxs(K,{hover:!0,children:[a.jsx(Xa,{imageSrc:k.thumbnailUrl,videoUrl:k.videoUrl,title:k.title,className:"aspect-video"}),a.jsxs("div",{className:"mt-4 space-y-2",children:[a.jsx("h3",{className:"text-xl font-bold text-white",children:k.title}),a.jsx("p",{className:"text-sm text-[#FF6600] font-semibold",children:k.platform}),a.jsx("p",{className:"text-sm text-white/70",children:k.description})]})]},A))})]})})}),a.jsx("div",{className:"section-divider"}),a.jsx(lx,{}),a.jsx("div",{className:"section-divider"}),a.jsx("section",{className:"py-32 bg-black relative ambient-gradient",children:a.jsx("div",{className:"container mx-auto px-6",children:a.jsxs("div",{className:"max-w-6xl mx-auto",children:[a.jsxs("div",{className:"text-center mb-16 animate-fade-up",children:[a.jsxs("h2",{className:"text-5xl md:text-6xl font-black mb-6 text-white",children:["YouTube ",a.jsx("span",{className:"text-gradient",children:"Shorts"})]}),a.jsx("p",{className:"text-xl text-white/80 max-w-3xl mx-auto",children:"Qu
299ick leadership insights and motivational moments"})]}),a.jsxs("div",{className:"grid md:grid-cols-2 gap-8 max-w-5xl mx-auto animate-fade-up mb-12",style:{animationDelay:"0.2s"},children:[a.jsx(K,{hover:!0,children:a.jsx(Xu,{videoId:"8myzRrKL57k",title:"Leadership Insight"})}),a.jsx(K,{hover:!0,children:a.jsx(Xu,{videoId:"-V6KkMu68wA",title:"Motivational Moment"})})]}),a.jsx("div",{className:"text-center animate-fade-up",style:{animationDelay:"0.4s"},children:a.jsx(K,{className:"max-w-2xl mx-auto",children:a.jsxs("div",{className:"flex flex-col items-center gap-6",children:[a.jsx(An,{className:"w-16 h-16 text-[#FF6600]"}),a.jsx("h3",{className:"text-3xl font-black text-white",children:"Want More Leadership Content?"}),a.jsx("p",{className:"text-lg text-white/80",children:"Subscribe to Dave's YouTube channel for regular leadership insights, motivational messages, and practical strategies you can implement right away."}),a.jsx(q,{href:"https://www.youtube.com/@davechristensen1215?sub_confirmation=1",size:"lg",icon:a.jsx(An,{className:"w-5 h-5"}),className:"shadow-[0_0_30px_rgba(255,102,0,0.3)]",children:"Subscribe on YouTube"})]})})})]})})}),a.jsx("div",{className:"section-divider"}),a.jsx("section",{className:"py-16 bg-white relative",children:a.jsx("div",{className:"container mx-auto px-6",children:a.jsxs("div",{className:"max-w-6xl mx-auto",children:[a.jsxs("h2",{className:"text-4xl md:text-5xl font-black text-center mb-4 text-black",children:["Trusted by ",a.jsx("span",{className:"bg-gradient-to-r from-[#FF6600] to-[#FF8533] bg-clip-text text-transparent",children:"Leading Organizations"})]}),a.jsx("p",{className:"text-center text-gray-600 mb-12 text-lg",children:"Companies and institutions that have experienced championship leadership strategies"}),a.jsx(Zu,{logos:E})]})})}),a.jsx("div",{className:"section-divider"}),a.jsxs("section",{className:"py-12 bg-gradient-to-r from-[#FF6600] to-[#FF8533] relative overflow-hidden",children:[a.jsx("div",{className:"absolute inset-0 bg-[url('data:image/svg+xml;base64,PHN2ZyB3aWR0aD0iNjAiIGhlaWdodD0iNjAiIHZpZXdCb3g9IjAgMCA2MCA2MCIgeG1sbnM9Imh0dHA6Ly93d3cudzMub3JnLzIwMDAvc3ZnIj48ZyBmaWxsPSJub25lIiBmaWxsLXJ1bGU9ImV2ZW5vZGQiPjxwYXRoIGQ9Ik0zNiAxOGMzLjMxNCAwIDYgMi42ODYgNiA2cy0yLjY4NiA2LTYgNi02LTIuNjg2LTYtNiAyLjY4Ni02IDYtNnoiIHN0cm9rZT0icmdiYSgyNTUsMjU1LDI1NSwwLjEpIi8+PC9nPjwvc3ZnPg==')] opacity-30"}),a.jsx("div",{className:"container mx-auto px-6 relative z-10",children:a.jsxs("div",{className:"max-w-4xl mx-auto text-center",children:[a.jsx("h2",{className:"text-3xl md:text-4xl font-black mb-4 text-white",children:"Ready to Go For It?"}),a.jsx("p",{className:"text-lg text-white/90 mb-6 leading-relaxed",children:"Book Dave for your next event and give your team the championship leadership strategies they need to win when it matters most."}),a.jsx("div",{className:"inline-block",children:a.jsx(q,{href:"mailto:[email protected]?subject=Speaking Engagement Inquiry&body=Hi Dave,%0D%0A%0D%0AI'm interested in booking you for a speaking engagement.%0D%0A%0D%0AEvent Details:%0D%0AOrganization:%0D%0AEvent Date:%0D%0ALocation:%0D%0AExpected Audience Size:%0D%0A%0D%0APlease let me know your availability.%0D%0A%0D%0AThank you!",size:"lg",variant:"secondary",className:"shadow-[0_0_30px_rgba(0,0,0,0.5)] hover:shadow-[0_0_40px_rgba(0,0,0,0.7)] transform hover:scale-105 transition-all text-white",children:"Request Availability"})})]})})]}),a.jsx("div",{className:"section-divider"}),a.jsx(wx,{}),a.jsx("div",{className:"section-divider"}),a.jsx("section",{id:"contact",className:"py-32 bg-black relative ambient-gradient",children:a.jsx("div",{className:"container mx-auto px-6",children:a.jsxs("div",{className:"max-w-6xl mx-auto",children:[a.jsxs("div",{className:"text-center mb-16 animate-fade-up",children:[a.jsxs("h2",{className:"text-5xl md:text-6xl font-black mb-6 text-white",children:["Let's ",a.jsx("span",{className:"text-gradient",children:"Connect"})]}),a.jsx("p",{className:"text-xl text-white/80 max-w-3xl mx-auto",children:"Ready to bring championship leadership to your organization? Get in touch to discu
299ss your event and receive a detailed quote."})]}),a.jsxs("div",{className:"grid lg:grid-cols-2 gap-12 animate-fade-up",style:{animationDelay:"0.2s"},children:[a.jsx(K,{children:a.jsxs("form",{className:"space-y-6",onSubmit:v,children:[a.jsxs("div",{children:[a.jsx("label",{htmlFor:"name",className:"block text-sm font-semibold mb-2 text-white",children:"Name*"}),a.jsx("input",{type:"text",id:"name",value:c.name,onChange:k=>u({...c,name:k.target.value}),required:!0,className:"w-full px-4 py-3 bg-white/5 border border-white/10 rounded-lg focus:outline-none focus:ring-2 focus:ring-[#FF6600] text-white"})]}),a.jsxs("div",{children:[a.jsx("label",{htmlFor:"email",className:"block text-sm font-semibold mb-2 text-white",children:"Email*"}),a.jsx("input",{type:"email",id:"email",value:c.email,onChange:k=>u({...c,email:k.target.value}),required:!0,className:"w-full px-4 py-3 bg-white/5 border border-white/10 rounded-lg focus:outline-none focus:ring-2 focus:ring-[#FF6600] text-white"})]}),a.jsxs("div",{children:[a.jsx("label",{htmlFor:"organization",className:"block text-sm font-semibold mb-2 text-white",children:"Organization*"}),a.jsx("input",{type:"text",id:"organization",value:c.organization,onChange:k=>u({...c,organization:k.target.value}),required:!0,className:"w-full px-4 py-3 bg-white/5 border border-white/10 rounded-lg focus:outline-none focus:ring-2 focus:ring-[#FF6600] text-white"})]}),a.jsxs("div",{children:[a.jsx("label",{htmlFor:"message",className:"block text-sm font-semibold mb-2 text-white",children:"Message*"}),a.jsx("textarea",{id:"message",value:c.message,onChange:k=>u({...c,message:k.target.value}),required:!0,rows:5,className:"w-full px-4 py-3 bg-white/5 border border-white/10 rounded-lg focus:outline-none focus:ring-2 focus:ring-[#FF6600] resize-none text-white",placeholder:"Tell us about your event, date, audience size, and what you're looking to achieve..."})]}),a.jsx(q,{type:"submit",className:"w-full",disabled:d==="sending",children:d==="sending"?"Sending...":"Send Message"}),d==="success"&&a.jsx("p",{className:"text-green-400 text-sm text-center font-medium",children:"Message sent! We'll be in touch soon."}),d==="error"&&a.jsx("p",{className:"text-red-400 text-sm text-center font-medium",children:"Something went wrong. Please try again or email us directly."})]})}),a.jsxs("div",{className:"space-y-8",children:[a.jsxs(K,{children:[a.jsx("h3",{className:"text-2xl font-bold mb-6 text-white",children:"Contact Information"}),a.jsxs("div",{className:"space-y-6",children:[a.jsxs("div",{className:"flex items-start gap-4",children:[a.jsx("div",{className:"w-12 h-12 rounded-full bg-[#FF6600] flex items-center justify-center flex-shrink-0",children:a.jsx(Xf,{className:"w-6 h-6"})}),a.jsxs("div",{children:[a.jsx("p",{className:"font-semibold mb-1 text-white",children:"Email"}),a.jsx("a",{href:"mailto:[email protected]?subject=Speaking Engagement Inquiry&body=Hi Dave,%0D%0A%0D%0AI'm interested in booking you for a speaking engagement.%0D%0A%0D%0AEvent Details:%0D%0AOrganization:%0D%0AEvent Date:%0D%0ALocation:%0D%0AExpected Audience Size:%0D%0A%0D%0APlease let me know your availability.%0D%0A%0D%0AThank you!",className:"text-[#FF6600] hover:underline",children:"[email protected]"})]})]}),a.jsxs("div",{className:"flex items-start gap-4",children:[a.jsx("div",{className:"w-12 h-12 rounded-full bg-[#FF6600] flex items-center justify-center flex-shrink-0",children:a.jsx(Xw,{className:"w-6 h-6"})}),a.jsxs("div",{children:[a.jsx("p",{className:"font-semibold mb-1 text-white",children:"Phone"}),a.jsx("a",{href:"tel:979.446.7413",className:"text-white/70 hover:text-white",children:"979.446.7413"})]})]}),a.jsxs("div",{className:"flex items-start gap-4",children:[a.jsx("div",{className:"w-12 h-12 rounded-full bg-[#FF6600] flex items-center justify-center flex-shrink-0",children:a.jsx(Jw,{className:"w-6 h-6"})}),a.jsxs("div",{children:[a.jsx("p",{className:"font-semibold mb-1 text-white",children:"Location"}),a.jsx("p",{className:"text-white/70",children:"Travels from Phoenix, AZ"}),a.jsx("p",{className:"text-sm text-white/60 mt-1",children:"Available for speaking engagements nationwide"})]})]})]})]}),a.jsxs(K,{children:[a.jsx("h3",{className:"text-xl font-bold mb-6 text-white",children:"Connect on Social Media"}),a.jsxs("div",{className:"flex flex-col gap-3",children:[a.jsxs("a",{href:"https://www.linkedin.com/in/dave-christensen-a0b78130",target:"_blank",rel:"noopener noreferrer",className:"flex items-center gap-4 px-4 py-3 rounded-xl bg-white/5 hover:bg-[#0A66C2]/20 border border-white/10 hover:border-[#0A66C2]/50 transition-all duration-300 group",children:[a.jsx("div",{className:"w-10 h-10 rounded-lg bg-[#0A66C2] flex items-center justify-center flex-shrink-0",children:a.jsx(Ya,{className:"w-5 h-5 text-white"})}),a.jsxs("div",{children:[a.jsx("p",{className:"text-white font-semibold text-sm",children:"LinkedIn"}),a.jsx("p",{className:"text-white/50 text-xs",children:"Dave Christensen"})]}),a.jsx("div",{className:"ml-auto text-white/30 group-hover:text-white/70 transition-colors",children:"→"})]}),a.jsxs("a",{href:"https://www.instagram.com/koachc",target:"_blank",rel:"noopener noreferrer",className:"flex items-center gap-4 px-4 py-3 rounded-xl bg-white/5 hover:bg-pink-600/20 border border-white/10 hover:border-pink-500/50 transition-all duration-300 group",children:[a.jsx("div",{className:"w-10 h-10 rounded-lg bg-gradient-to-br from-[#F58529] via-[#DD2A7B] to-[#8134AF] flex items-center justify-center flex-shrink-0",children:a.jsx(Ka,{className:"w-5 h-5 text-white"})}),a.jsxs("div",{children:[a.jsx("p",{className:"text-white font-semibold text-sm",children:"Instagram"}),a.jsx("p",{className:"text-white/50 text-xs",children:"@koachc"})]}),a.jsx("div",{className:"ml-auto text-white/30 group-hover:text-white/70 transition-colors",children:"→"})]}),a.jsxs("a",{href:"https://www.x.com/Koach_C",target:"_blank",rel:"noopener noreferrer",className:"flex items-center gap-4 px-4 py-3 rounded-xl bg-white/5 hover:bg-white/10 border border-white/10 hover:border-white/30 transition-all duration-300 group",children:[a.jsx("div",{className:"w-10 h-10 rounded-lg bg-black border border-white/20 flex items-center justify-center flex-shrink-0",children:a.jsx(Qa,{className:"w-5 h-5 text-white"})}),a.jsxs("div",{children:[a.jsx("p",{className:"text-white font-semibold text-sm",children:"X (Twitter)"}),a.jsx("p",{className:"text-white/50 text-xs",children:"@Koach_C"})]}),a.jsx("div",{className:"ml-auto text-white/30 group-hover:text-white/70 transition-colors",children:"→"})]}),a.jsxs("a",{href:"https://www.youtube.com/@davechristensen1215",target:"_blank",rel:"noopener noreferrer",className:"flex items-center gap-4 px-4 py-3 rounded-xl bg-white/5 hover:bg-red-600/20 border border-white/10 hover:border-red-500/50 transition-all duration-300 group",children:[a.jsx("div",{className:"w-10 h-10 rounded-lg bg-[#FF0000] flex items-center justify-center flex-shrink-0",children:a.jsx(An,{className:"w-5 h-5 text-white"})}),a.jsxs("div",{children:[a.jsx("p",{className:"text-white font-semibold text-sm",children:"YouTube"}),a.jsx("p",{className:"text-white/50 text-xs",children:"@davechristensen1215"})]}),a.jsx("div",{className:"ml-auto text-white/30 group-hover:text-white/70 transition-colors",children:"→"})]}),a.jsxs("a",{href:"https://www.talkadot.com/s/davechristensen",target:"_blank",rel:"noopener noreferrer",className:"flex items-center gap-4 px-4 py-3 rounded-xl bg-white/5 hover:bg-[#FF6600]/20 border border-white/10 hover:border-[#FF6600]/50 transition-all duration-300 group",children:[a.jsx("div",{className:"w-10 h-10 rounded-lg bg-[#FF6600] flex items-center justify-center flex-shrink-0",children:a.jsx(Ja,{className:"w-5 h-5 text-white"})}),a.jsxs("div",{children:[a.jsx("p",{className:"text-white font-semibold text-sm",children:"Talkadot"}),a.jsx("p",{className:"text-white/50 text-xs",children:"Speaker Feedback"})]}),a.jsx("div",{className:"ml-auto text-white/30 group-hover:text-white/70 transition-colors",children:"→"})]})]})]})]})]})]})})})]}),a.jsx("footer",{className:"bg-[#f5f5f5]/95 backdrop-blur-xl border-t border-gray-200 py-12",children:a.jsx("div",{className:"container mx-auto px-6",children:a.jsxs("div",{className:"max-w-6xl mx-auto",children:[a.jsxs("div",{className:"grid md:grid-cols-3 gap-8 mb-8",children:[a.jsxs("div",{children:[a.jsx("img",{src:"/header-2048x527_(1).png",alt:"Christensen Leadership",className:"h-20 w-auto mb-4"}),a.jsx("p",{className:"text-gray-600 text-sm",children:"Championship leadership strategies for organizations, schools, and team
299s."})]}),a.jsxs("div",{children:[a.jsx("h4",{className:"font-bold mb-4 text-gray-900",children:"Quick Links"}),a.jsx("div",{className:"space-y-2",children:w.map(k=>a.jsx("a",{href:k.href,className:"block text-gray-600 hover:text-gray-900 text-sm transition-colors",children:k.label},k.href))})]}),a.jsxs("div",{children:[a.jsx("h4",{className:"font-bold mb-4 text-gray-900",children:"Contact"}),a.jsxs("div",{className:"space-y-2 text-sm text-gray-600",children:[a.jsx("p",{children:"[email protected]"}),a.jsx("p",{children:"979.446.7413"}),a.jsx("p",{children:"Phoenix, AZ"})]}),a.jsxs("div",{className:"mt-6",children:[a.jsx("h4",{className:"font-bold mb-3 text-gray-900",children:"Follow Dave"}),a.jsxs("div",{className:"flex gap-3",children:[a.jsx("a",{href:"https://www.linkedin.com/in/dave-christensen-a0b78130",target:"_blank",rel:"noopener noreferrer",className:"w-10 h-10 rounded-full bg-gray-200 hover:bg-[#FF6600] flex items-center justify-center transition-colors text-gray-700 hover:text-white",children:a.jsx(Ya,{className:"w-5 h-5"})}),a.jsx("a",{href:"https://www.instagram.com/koachc",target:"_blank",rel:"noopener noreferrer",className:"w-10 h-10 rounded-full bg-gray-200 hover:bg-[#FF6600] flex items-center justify-center transition-colors text-gray-700 hover:text-white",children:a.jsx(Ka,{className:"w-5 h-5"})}),a.jsx("a",{href:"https://www.x.com/Koach_C",target:"_blank",rel:"noopener noreferrer",className:"w-10 h-10 rounded-full bg-gray-200 hover:bg-[#FF6600] flex items-center justify-center transition-colors text-gray-700 hover:text-white",children:a.jsx(Qa,{className:"w-5 h-5"})}),a.jsx("a",{href:"https://www.talkadot.com/s/davechristensen",target:"_blank",rel:"noopener noreferrer",className:"w-10 h-10 rounded-full bg-gray-200 hover:bg-[#FF6600] flex items-center justify-center transition-colors text-gray-700 hover:text-white",children:a.jsx(Ja,{className:"w-5 h-5"})}),a.jsx("a",{href:"https://www.youtube.com/@davechristensen1215",target:"_blank",rel:"noopener noreferrer",className:"w-10 h-10 rounded-full bg-gray-200 hover:bg-[#FF6600] flex items-center justify-center transition-colors text-gray-700 hover:text-white",children:a.jsx(An,{className:"w-5 h-5"})})]})]})]})]}),a.jsx("div",{className:"border-t border-gray-200 pt-8 text-center text-sm text-gray-500",children:a.jsxs("p",{children:["© ",new Date().getFullYear()," Coach Christensen Consulting, LLC. All rights reserved."]})})]})})}),a.jsx(dx,{isOpen:s,onClose:()=>i(!1)})]})}function Tx(){return a.jsx(X0,{children:a.jsx(zw,{children:a.jsx(cx,{children:a.jsxs(E0,{children:[a.jsx(ut,{path:"/",element:a.jsx(Cx,{})}),a.jsx(ut,{path:"/login",element:a.jsx(hx,{})}),a.jsx(ut,{path:"/signup",element:a.jsx(fx,{})}),a.jsx(ut,{path:"/checkout",element:a.jsx(gx,{})}),a.jsx(ut,{path:"/success",element:a.jsx(yx,{})}),a.jsx(ut,{path:"/orders",element:a.jsx(vx,{})}),a.jsx(ut,{path:"/insights/:slug",element:a.jsx(bx,{})}),a.jsx(ut,{path:"/leadership-keynote-speaker",element:a.jsx(Nx,{})})]})})})})}pf(document.getElementById("root")).render(a.jsx(x.StrictMode,{children:a.jsx(Tx,{})}));

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.