PageSourceSearch

https://scoops.ng/assets/index-BlctY-r1.js

js scoops.ng collected 2026-10-06 13:57:37 UTC 693,394 bytes, 380 lines download raw bytes

vendor: 4,305 bytes, lines 1-9
1var IC=Object.defineProperty;var Zp=e=>{throw TypeError(e)};var DC=(e,t,n)=>t in e?IC(e,t,{enumerable:!0,configurable:!0,writable:!0,value:n}):e[t]=n;var eg=(e,t,n)=>DC(e,typeof t!="symbol"?t+"":t,n),zu=(e,t,n)=>t.has(e)||Zp("Cannot "+n);var D=(e,t,n)=>(zu(e,t,"read from private field"),n?n.call(e):t.get(e)),ge=(e,t,n)=>t.has(e)?Zp("Cannot add the same private member more than once"):t instanceof WeakSet?t.add(e):t.set(e,n),se=(e,t,n,r)=>(zu(e,t,"write to private field"),r?r.call(e,n):t.set(e,n),n),st=(e,t,n)=>(zu(e,t,"access private method"),n);var Qa=(e,t,n,r)=>({set _(s){se(e,t,s,n)},get _(){return D(e,t,r)}});function LC(e,t){for(var n=0;n<t.length;n++){const r=t[n];if(typeof r!="string"&&!Array.isArray(r)){for(const s in r)if(s!=="default"&&!(s in e)){const o=Object.getOwnPropertyDescriptor(r,s);o&&Object.defineProperty(e,s,o.get?o:{enumerable:!0,get:()=>r[s]})}}}return Object.freeze(Object.defineProperty(e,Symbol.toStringTag,{value:"Module"}))}(function(){const t=document.createElement("link").relList;if(t&&t.supports&&t.supports("modulepreload"))return;for(const s of document.querySelectorAll('link[rel="modulepreload"]'))r(s);new MutationObserver(s=>{for(const o of s)if(o.type==="childList")for(const a of o.addedNodes)a.tagName==="LINK"&&a.rel==="modulepreload"&&r(a)}).observe(document,{childList:!0,subtree:!0});function n(s){const o={};return s.integrity&&(o.integrity=s.integrity),s.referrerPolicy&&(o.referrerPolicy=s.referrerPolicy),s.crossOrigin==="use-credentials"?o.credentials="include":s.crossOrigin==="anonymous"?o.credentials="omit":o.credentials="same-origin",o}function r(s){if(s.ep)return;s.ep=!0;const o=n(s);fetch(s.href,o)}})();function Kv(e){return e&&e.__esModule&&Object.prototype.hasOwnProperty.call(e,"default")?e.default:e}var Yv={exports:{}},Wc={},Gv={exports:{}},de={};/**
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 _a=Symbol.for("react.element"),_C=Symbol.for("react.portal"),FC=Symbol.for("react.fragment"),VC=Symbol.for("react.strict_mode"),$C=Symbol.for("react.profiler"),BC=Symbol.for("react.provider"),zC=Symbol.for("react.context"),UC=Symbol.for("react.forward_ref"),WC=Symbol.for("react.suspense"),HC=Symbol.for("react.memo"),KC=Symbol.for("react.lazy"),tg=Symbol.iterator;function YC(e){return e===null||typeof e!="object"?null:(e=tg&&e[tg]||e["@@iterator"],typeof e=="function"?e:null)}var qv={isMounted:function(){return!1},enqueueForceUpdate:function(){},enqueueReplaceState:function(){},enqueueSetState:function(){}},Qv=Object.assign,Xv={};function si(e,t,n){this.props=e,this.context=t,this.refs=Xv,this.updater=n||qv}si.prototype.isReactComponent={};si.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")};si.prototype.forceUpdate=function(e){this.updater.enqueueForceUpdate(this,e,"forceUpdate")};function Jv(){}Jv.prototype=si.prototype;function Uh(e,t,n){this.props=e,this.context=t,this.refs=Xv,this.updater=n||qv}var Wh=Uh.prototype=new Jv;Wh.constructor=Uh;Qv(Wh,si.prototype);Wh.isPureReactComponent=!0;var ng=Array.isArray,Zv=Object.prototype.hasOwnProperty,Hh={current:null},e0={key:!0,ref:!0,__self:!0,__source:!0};function t0(e,t,n){var r,s={},o=null,a=null;if(t!=null)for(r in t.ref!==void 0&&(a=t.ref),t.key!==void 0&&(o=""+t.key),t)Zv.call(t,r)&&!e0.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:_a,type:e,key:o,ref:a,props:s,_owner:Hh.current}}function GC(e,t){return{$$typeof:_a,type:e.type,key:t,ref:e.ref,props:e.props,_owner:e._owner}}function Kh(e){return typeof e=="object"&&e!==null&&e.$$typeof===_a}function qC(e){var t={"=":"=0",":":"=2"};return"$"+e.replace(/[=:]/g,function(n){return t[n]})}var rg=/\/+/g;function Uu(e,t){return typeof e=="object"&&e!==null&&e.key!=null?qC(""+e.key):t.toString(36)}
vendor: 4,786 bytes, lines 9-17
9function Al(e,t,n,r,s){var o=typeof e;(o==="undefined"||o==="boolean")&&(e=null);var a=!1;if(e===null)a=!0;else switch(o){case"string":case"number":a=!0;break;case"object":switch(e.$$typeof){case _a:case _C:a=!0}}if(a)return a=e,s=s(a),e=r===""?"."+Uu(a,0):r,ng(s)?(n="",e!=null&&(n=e.replace(rg,"$&/")+"/"),Al(s,t,n,"",function(u){return u})):s!=null&&(Kh(s)&&(s=GC(s,n+(!s.key||a&&a.key===s.key?"":(""+s.key).replace(rg,"$&/")+"/")+e)),t.push(s)),1;if(a=0,r=r===""?".":r+":",ng(e))for(var l=0;l<e.length;l++){o=e[l];var c=r+Uu(o,l);a+=Al(o,t,n,c,s)}else if(c=YC(e),typeof c=="function")for(e=c.call(e),l=0;!(o=e.next()).done;)o=o.value,c=r+Uu(o,l++),a+=Al(o,t,n,c,s);else if(o==="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 a}function Xa(e,t,n){if(e==null)return e;var r=[],s=0;return Al(e,r,"","",function(o){return t.call(n,o,s++)}),r}function QC(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 wt={current:null},Ml={transition:null},XC={ReactCurrentDispatcher:wt,ReactCurrentBatchConfig:Ml,ReactCurrentOwner:Hh};function n0(){throw Error("act(...) is not supported in production builds of React.")}de.Children={map:Xa,forEach:function(e,t,n){Xa(e,function(){t.apply(this,arguments)},n)},count:function(e){var t=0;return Xa(e,function(){t++}),t},toArray:function(e){return Xa(e,function(t){return t})||[]},only:function(e){if(!Kh(e))throw Error("React.Children.only expected to receive a single React element child.");return e}};de.Component=si;de.Fragment=FC;de.Profiler=$C;de.PureComponent=Uh;de.StrictMode=VC;de.Suspense=WC;de.__SECRET_INTERNALS_DO_NOT_USE_OR_YOU_WILL_BE_FIRED=XC;de.act=n0;de.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=Qv({},e.props),s=e.key,o=e.ref,a=e._owner;if(t!=null){if(t.ref!==void 0&&(o=t.ref,a=Hh.current),t.key!==void 0&&(s=""+t.key),e.type&&e.type.defaultProps)var l=e.type.defaultProps;for(c in t)Zv.call(t,c)&&!e0.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:_a,type:e.type,key:s,ref:o,props:r,_owner:a}};de.createContext=function(e){return e={$$typeof:zC,_currentValue:e,_currentValue2:e,_threadCount:0,Provider:null,Consumer:null,_defaultValue:null,_globalName:null},e.Provider={$$typeof:BC,_context:e},e.Consumer=e};de.createElement=t0;de.createFactory=function(e){var t=t0.bind(null,e);return t.type=e,t};de.createRef=function(){return{current:null}};de.forwardRef=function(e){return{$$typeof:UC,render:e}};de.isValidElement=Kh;de.lazy=function(e){return{$$typeof:KC,_payload:{_status:-1,_result:e},_init:QC}};de.memo=function(e,t){return{$$typeof:HC,type:e,compare:t===void 0?null:t}};de.startTransition=function(e){var t=Ml.transition;Ml.transition={};try{e()}finally{Ml.transition=t}};de.unstable_act=n0;de.useCallback=function(e,t){return wt.current.useCallback(e,t)};de.useContext=function(e){return wt.current.useContext(e)};de.useDebugValue=function(){};de.useDeferredValue=function(e){return wt.current.useDeferredValue(e)};de.useEffect=function(e,t){return wt.current.useEffect(e,t)};de.useId=function(){return wt.current.useId()};de.useImperativeHandle=function(e,t,n){return wt.current.useImperativeHandle(e,t,n)};de.useInsertionEffect=function(e,t){return wt.current.useInsertionEffect(e,t)};de.useLayoutEffect=function(e,t){return wt.current.useLayoutEffect(e,t)};de.useMemo=function(e,t){return wt.current.useMemo(e,t)};de.useReducer=function(e,t,n){return wt.current.useReducer(e,t,n)};de.useRef=function(e){return wt.current.useRef(e)};de.useState=function(e){return wt.current.useState(e)};de.useSyncExternalStore=function(e,t,n){return wt.current.useSyncExternalStore(e,t,n)};de.useTransition=function(){return wt.current.useTransition()};de.version="18.3.1";Gv.exports=de;var h=Gv.exports;const W=Kv(h),Yh=LC({__proto__:null,default:W},[h]);/**
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 JC=h,ZC=Symbol.for("react.element"),ek=Symbol.for("react.fragment"),tk=Object.prototype.hasOwnProperty,nk=JC.__SECRET_INT
vendor: 10,203 bytes, lines 17-33
17ERNALS_DO_NOT_USE_OR_YOU_WILL_BE_FIRED.ReactCurrentOwner,rk={key:!0,ref:!0,__self:!0,__source:!0};function r0(e,t,n){var r,s={},o=null,a=null;n!==void 0&&(o=""+n),t.key!==void 0&&(o=""+t.key),t.ref!==void 0&&(a=t.ref);for(r in t)tk.call(t,r)&&!rk.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:ZC,type:e,key:o,ref:a,props:s,_owner:nk.current}}Wc.Fragment=ek;Wc.jsx=r0;Wc.jsxs=r0;Yv.exports=Wc;var i=Yv.exports,s0={exports:{}},Ft={},o0={exports:{}},i0={};/**
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(T,A){var L=T.length;T.push(A);e:for(;0<L;){var _=L-1>>>1,$=T[_];if(0<s($,A))T[_]=A,T[L]=$,L=_;else break e}}function n(T){return T.length===0?null:T[0]}function r(T){if(T.length===0)return null;var A=T[0],L=T.pop();if(L!==A){T[0]=L;e:for(var _=0,$=T.length,J=$>>>1;_<J;){var ee=2*(_+1)-1,Q=T[ee],ne=ee+1,F=T[ne];if(0>s(Q,L))ne<$&&0>s(F,Q)?(T[_]=F,T[ne]=L,_=ne):(T[_]=Q,T[ee]=L,_=ee);else if(ne<$&&0>s(F,L))T[_]=F,T[ne]=L,_=ne;else break e}}return A}function s(T,A){var L=T.sortIndex-A.sortIndex;return L!==0?L:T.id-A.id}if(typeof performance=="object"&&typeof performance.now=="function"){var o=performance;e.unstable_now=function(){return o.now()}}else{var a=Date,l=a.now();e.unstable_now=function(){return a.now()-l}}var c=[],u=[],d=1,f=null,m=3,p=!1,b=!1,x=!1,y=typeof setTimeout=="function"?setTimeout:null,w=typeof clearTimeout=="function"?clearTimeout:null,g=typeof setImmediate<"u"?setImmediate:null;typeof navigator<"u"&&navigator.scheduling!==void 0&&navigator.scheduling.isInputPending!==void 0&&navigator.scheduling.isInputPending.bind(navigator.scheduling);function v(T){for(var A=n(u);A!==null;){if(A.callback===null)r(u);else if(A.startTime<=T)r(u),A.sortIndex=A.expirationTime,t(c,A);else break;A=n(u)}}function S(T){if(x=!1,v(T),!b)if(n(c)!==null)b=!0,B(j);else{var A=n(u);A!==null&&U(S,A.startTime-T)}}function j(T,A){b=!1,x&&(x=!1,w(N),N=-1),p=!0;var L=m;try{for(v(A),f=n(c);f!==null&&(!(f.expirationTime>A)||T&&!R());){var _=f.callback;if(typeof _=="function"){f.callback=null,m=f.priorityLevel;var $=_(f.expirationTime<=A);A=e.unstable_now(),typeof $=="function"?f.callback=$:f===n(c)&&r(c),v(A)}else r(c);f=n(c)}if(f!==null)var J=!0;else{var ee=n(u);ee!==null&&U(S,ee.startTime-A),J=!1}return J}finally{f=null,m=L,p=!1}}var C=!1,P=null,N=-1,E=5,k=-1;function R(){return!(e.unstable_now()-k<E)}function M(){if(P!==null){var T=e.unstable_now();k=T;var A=!0;try{A=P(!0,T)}finally{A?I():(C=!1,P=null)}}else C=!1}var I;if(typeof g=="function")I=function(){g(M)};else if(typeof MessageChannel<"u"){var O=new MessageChannel,H=O.port2;O.port1.onmessage=M,I=function(){H.postMessage(null)}}else I=function(){y(M,0)};function B(T){P=T,C||(C=!0,I())}function U(T,A){N=y(function(){T(e.unstable_now())},A)}e.unstable_IdlePriority=5,e.unstable_ImmediatePriority=1,e.unstable_LowPriority=4,e.unstable_NormalPriority=3,e.unstable_Profiling=null,e.unstable_UserBlockingPriority=2,e.unstable_cancelCallback=function(T){T.callback=null},e.unstable_continueExecution=function(){b||p||(b=!0,B(j))},e.unstable_forceFrameRate=function(T){0>T||125<T?console.error("forceFrameRate takes a positive int between 0 and 125, forcing frame rates higher than 125 fps is not supported"):E=0<T?Math.floor(1e3/T):5},e.unstable_getCurrentPriorityLevel=function(){return m},e.unstable_getFirstCallbackNode=function(){return n(c)},e.unstable_next=function(T){switch(m){case 1:case 2:case 3:var A=3;break;default:A=m}var L=m;m=A;try{return T()}finally{m=L}},e.unstable_pauseExecution=function(){},e.unstable_requestPaint=function(){},e.unstable_runWithPriority=function(T,A){switch(T){case 1:case 2:case 3:case 4:case 5:break;default:T=3}var L=m;m=T;try{return A()}finally{m=L}},e.unstable_scheduleCallback=function(T,A,L){var _=e.unstable_now();switch(typeof L=="object"&&L!==null?(L=L.delay,L=typeof L=="number"&&0<L?_+L:_):L=_,T){case 1:var $=-1;break;case 2:$=250;break;case 5:$=1073741823;break;case 4:$=1e4;break;default:$=5e3}return $=L+$,T={id:d++,callback:A,priorityLevel:T,startTime:L,expirationTime:$,sortIndex:-1},L>_?(T.sortIndex=L,t(u,T),n(c)===null&&T===n(u)&&(x?(w(N),N=-1):x=!0,U(S,L-_))):(T.sortIndex=$,t(c,T),b||p||(b=!0,B(j))),T},e.unstable_shouldYield=R,e.unstable_wrapCallback=function(T){var A=m;return function(){var L=m;m=A;try{return T.apply(this,arguments)}finally{m=L}}}})(i0);o0.exports=i0;var sk=o0.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 ok=h,_t=sk;function V(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 a0=new Set,sa={};function Ks(e,t){Uo(e,t),Uo(e+"Capture",t)}function Uo(e,t){for(sa[e]=t,e=0;e<t.length;e++)a0.add(t[e])}var rr=!(typeof window>"u"||typeof window.document>"u"||typeof window.document.createElement>"u"),tf=Object.prototype.hasOwnProperty,ik=/^[: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]*$/,sg={},og={};function ak(e){return tf.call(og,e)?!0:tf.call(sg,e)?!1:ik.test(e)?og[e]=!0:(sg[e]=!0,!1)}function lk(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 ck(e,t,n,r){if(t===null||typeof t>"u"||lk(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 bt(e,t,n,r,s,o,a){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=o,this.removeEmptyString=a}var nt={};"children dangerouslySetInnerHTML defaultValue defaultChecked innerHTML suppressContentEditableWarning suppressHydrationWarning style".split(" ").forEach(function(e){nt[e]=new bt(e,0,!1,e,null,!1,!1)});[["acceptCharset","accept-charset"],["className","class"],["htmlFor","for"],["httpEquiv","http-equiv"]].forEach(function(e){var t=e[0];nt[t]=new bt(t,1,!1,e[1],null,!1,!1)});["contentEditable","draggable","spellCheck","value"].forEach(function(e){nt[e]=new bt(e,2,!1,e.toLowerCase(),null,!1,!1)});["autoReverse","externalResourcesRequired","focusable","preserveAlpha"].forEach(function(e){nt[e]=new bt(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){nt[e]=new bt(e,3,!1,e.toLowerCase(),null,!1,!1)});["checked","multiple","muted","selected"].forEach(function(e){nt[e]=new bt(e,3,!0,e,null,!1,!1)});["capture","download"].forEach(function(e){nt[e]=new bt(e,4,!1,e,null,!1,!1)});["cols","rows","size","span"].forEach(function(e){nt[e]=new bt(e,6,!1,e,null,!1,!1)});["rowSpan","start"].forEach(function(e){nt[e]=new bt(e,5,!1,e.toLowerCase(),null,!1,!1)});var Gh=/[\-:]([a-z])/g;function qh(e){return e[1].toUpperCase()}"accent-height alignment-baseline arabic-form baseline-shift cap-height clip-path clip-rule color-interpolation color-interpolation-filters color-profile color-rendering dominant-baseline enable-background fill-opacity fill-rule flood-color flood-opacity font-family font-size font-size-adjust font-stretch font-style font-variant font-weight glyph-name glyph-orientation-horizontal glyph-orientation-vertical horiz-adv-x horiz-origin-x image-rendering letter-spacing lighting-color marker-end marker-mid marker-start overline-position overline-thickness paint-order panose-1 pointer-events rendering-intent shape-rendering stop-color stop-opacity strikethrough-position strikethrough-thickness stroke-dasharray stroke-dashoffset stroke-linecap stroke-linejoin stroke-miterlimit stroke-opacity stroke-width text-anchor text-decoration text-rendering underline-position underline-thickness unicode-bidi unicode-range units-per-em v-alphabetic v-hanging v-ideographic v-mathematical vector-effect vert-adv-y vert-origin-x vert-origin-y word-spacing writing-mode xmlns:xlink x-height".split(" ").forEach(function(e){var t=e.replace(Gh,qh);nt[t]=new bt(t,1,!1,e,null,!1,!1)});"xlink:actuate xlink:arcrole xlink:role xlink:show xlink:title xlink:type".split(" ").forEach(function(e){var t=e.replace(Gh,qh);nt[t]=new bt(t,1,!1,e,"http://www.w3.org/1999/xlink",!1,!1)});["xml:base","xml:lang","xml:space"].forEach(function(e){var t=e.replace(Gh,qh);nt[t]=new bt(t,1,!1,e,"http://www.w3.org/XML/1998/namespace",!1,!1)});["tabIndex","crossOrigin"].forEach(function(e){nt[e]=new bt(e,1,!1,e.toLowerCase(),null,!1,!1)});nt.xlinkHref=new bt("xlinkHref",1,!1,"xlink:href","http://www.w3.org/1999/xlink",!0,!1);["src","href","action","formAction"].forEach(function(e){nt[e]=new bt(e,1,!1,e.toLowerCase(),null,!0,!0)});function Qh(e,t,n,r){var s=nt.hasOwnProperty(t)?nt[t]:null;(s!==null?s.type!==0:r||!(2<t.length)||t[0]!=="o"&&t[0]!=="O"||t[1]!=="n"&&t[1]!=="N")&&(ck(t,n,s,r)&&(n=null),r||s===null?ak(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: 17,938 bytes, lines 33-37
33var fr=ok.__SECRET_INTERNALS_DO_NOT_USE_OR_YOU_WILL_BE_FIRED,Ja=Symbol.for("react.element"),so=Symbol.for("react.portal"),oo=Symbol.for("react.fragment"),Xh=Symbol.for("react.strict_mode"),nf=Symbol.for("react.profiler"),l0=Symbol.for("react.provider"),c0=Symbol.for("react.context"),Jh=Symbol.for("react.forward_ref"),rf=Symbol.for("react.suspense"),sf=Symbol.for("react.suspense_list"),Zh=Symbol.for("react.memo"),Mr=Symbol.for("react.lazy"),u0=Symbol.for("react.offscreen"),ig=Symbol.iterator;function wi(e){return e===null||typeof e!="object"?null:(e=ig&&e[ig]||e["@@iterator"],typeof e=="function"?e:null)}var Ie=Object.assign,Wu;function Di(e){if(Wu===void 0)try{throw Error()}catch(n){var t=n.stack.trim().match(/\n( *(at )?)/);Wu=t&&t[1]||""}return`
34`+Wu+e}var Hu=!1;function Ku(e,t){if(!e||Hu)return"";Hu=!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`),o=r.stack.split(`
36`),a=s.length-1,l=o.length-1;1<=a&&0<=l&&s[a]!==o[l];)l--;for(;1<=a&&0<=l;a--,l--)if(s[a]!==o[l]){if(a!==1||l!==1)do if(a--,l--,0>l||s[a]!==o[l]){var c=`
37`+s[a].replace(" at new "," at ");return e.displayName&&c.includes("<anonymous>")&&(c=c.replace("<anonymous>",e.displayName)),c}while(1<=a&&0<=l);break}}}finally{Hu=!1,Error.prepareStackTrace=n}return(e=e?e.displayName||e.name:"")?Di(e):""}function uk(e){switch(e.tag){case 5:return Di(e.type);case 16:return Di("Lazy");case 13:return Di("Suspense");case 19:return Di("SuspenseList");case 0:case 2:case 15:return e=Ku(e.type,!1),e;case 11:return e=Ku(e.type.render,!1),e;case 1:return e=Ku(e.type,!0),e;default:return""}}function of(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 oo:return"Fragment";case so:return"Portal";case nf:return"Profiler";case Xh:return"StrictMode";case rf:return"Suspense";case sf:return"SuspenseList"}if(typeof e=="object")switch(e.$$typeof){case c0:return(e.displayName||"Context")+".Consumer";case l0:return(e._context.displayName||"Context")+".Provider";case Jh:var t=e.render;return e=e.displayName,e||(e=t.displayName||t.name||"",e=e!==""?"ForwardRef("+e+")":"ForwardRef"),e;case Zh:return t=e.displayName||null,t!==null?t:of(e.type)||"Memo";case Mr:t=e._payload,e=e._init;try{return of(e(t))}catch{}}return null}function dk(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 of(t);case 8:return t===Xh?"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 ts(e){switch(typeof e){case"boolean":case"number":case"string":case"undefined":return e;case"object":return e;default:return""}}function d0(e){var t=e.type;return(e=e.nodeName)&&e.toLowerCase()==="input"&&(t==="checkbox"||t==="radio")}function fk(e){var t=d0(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,o=n.set;return Object.defineProperty(e,t,{configurable:!0,get:function(){return s.call(this)},set:function(a){r=""+a,o.call(this,a)}}),Object.defineProperty(e,t,{enumerable:n.enumerable}),{getValue:function(){return r},setValue:function(a){r=""+a},stopTracking:function(){e._valueTracker=null,delete e[t]}}}}function Za(e){e._valueTracker||(e._valueTracker=fk(e))}function f0(e){if(!e)return!1;var t=e._valueTracker;if(!t)return!0;var n=t.getValue(),r="";return e&&(r=d0(e)?e.checked?"true":"false":e.value),e=r,e!==n?(t.setValue(e),!0):!1}function ec(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 af(e,t){var n=t.checked;return Ie({},t,{defaultChecked:void 0,defaultValue:void 0,value:void 0,checked:n??e._wrapperState.initialChecked})}function ag(e,t){var n=t.defaultValue==null?"":t.defaultValue,r=t.checked!=null?t.checked:t.defaultChecked;n=ts(t.value!=null?t.value:n),e._wrapperState={initialChecked:r,initialValue:n,controlled:t.type==="checkbox"||t.type==="radio"?t.checked!=null:t.value!=null}}function h0(e,t){t=t.checked,t!=null&&Qh(e,"checked",t,!1)}function lf(e,t){h0(e,t);var n=ts(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")?cf(e,t.type,n):t.hasOwnProperty("defaultValue")&&cf(e,t.type,ts(t.defaultValue)),t.checked==null&&t.defaultChecked!=null&&(e.defaultChecked=!!t.defaultChecked)}function lg(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 cf(e,t,n){(t!=="number"||ec(e.ownerDocument)!==e)&&(n==null?e.defaultValue=""+e._wrapperState.initialValue:e.defaultValue!==""+n&&(e.defaultValue=""+n))}var Li=Array.isArray;function So(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=""+ts(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 uf(e,t){if(t.dangerouslySetInnerHTML!=null)throw Error(V(91));return Ie({},t,{value:void 0,defaultValue:void 0,children:""+e._wrapperState.initialValue})}function cg(e,t){var n=t.value;if(n==null){if(n=t.children,t=t.defaultValue,n!=null){if(t!=null)throw Error(V(92));if(Li(n)){if(1<n.length)throw Error(V(93));n=n[0]}t=n}t==null&&(t=""),n=t}e._wrapperState={initialValue:ts(n)}}function m0(e,t){var n=ts(t.value),r=ts(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 ug(e){var t=e.textContent;t===e._wrapperState.initialValue&&t!==""&&t!==null&&(e.value=t)}function p0(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 df(e,t){return e==null||e==="http://www.w3.org/1999/xhtml"?p0(t):e==="http://www.w3.org/2000/svg"&&t==="foreignObject"?"http://www.w3.org/1999/xhtml":e}var el,g0=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(el=el||document.createElement("div"),el.innerHTML="<svg>"+t.valueOf().toString()+"</svg>",t=el.firstChild;e.firstChild;)e.removeChild(e.firstChild);for(;t.firstChild;)e.appendChild(t.firstChild)}});function oa(e,t){if(t){var n=e.firstChild;if(n&&n===e.lastChild&&n.nodeType===3){n.nodeValue=t;return}}e.textContent=t}var Ui={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},hk=["Webkit","ms","Moz","O"];Object.keys(Ui).forEach(function(e){hk.forEach(function(t){t=t+e.charAt(0).toUpperCase()+e.substring(1),Ui[t]=Ui[e]})});function x0(e,t,n){return t==null||typeof t=="boolean"||t===""?"":n||typeof t!="number"||t===0||Ui.hasOwnProperty(e)&&Ui[e]?(""+t).trim():t+"px"}function y0(e,t){e=e.style;for(var n in t)if(t.hasOwnProperty(n)){var r=n.indexOf("--")===0,s=x0(n,t[n],r);n==="float"&&(n="cssFloat"),r?e.setProperty(n,s):e[n]=s}}var mk=Ie({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 ff(e,t){if(t){if(mk[e]&&(t.children!=null||t.dangerouslySetInnerHTML!=null))throw Error(V(137,e));if(t.dangerouslySetInnerHTML!=null){if(t.children!=null)throw Error(V(60));if(typeof t.dangerouslySetInnerHTML!="object"||!("__html"in t.dangerouslySetInnerHTML))throw Error(V(61))}if(t.style!=null&&typeof t.style!="object")throw Error(V(62))}}function hf(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 mf=null;function em(e){return e=e.target||e.srcElement||window,e.correspondingUseElement&&(e=e.correspondingUseElement),e.nodeType===3?e.parentNode:e}var pf=null,jo=null,No=null;function dg(e){if(e=$a(e)){if(typeof pf!="function")throw Error(V(280));var t=e.stateNode;t&&(t=qc(t),pf(e.stateNode,e.type,t))}}function v0(e){jo?No?No.push(e):No=[e]:jo=e}function w0(){if(jo){var e=jo,t=No;if(No=jo=null,dg(e),t)for(e=0;e<t.length;e++)dg(t[e])}}function b0(e,t){return e(t)}function S0(){}var Yu=!1;function j0(e,t,n){if(Yu)return e(t,n);Yu=!0;try{return b0(e,t,n)}finally{Yu=!1,(jo!==null||No!==null)&&(S0(),w0())}}function ia(e,t){var n=e.stateNode;if(n===null)return null;var r=qc(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(V(231,t,typeof n));return n}var gf=!1;if(rr)try{var bi={};Object.defineProperty(bi,"passive",{get:function(){gf=!0}}),window.addEventListener("test",bi,bi),window.removeEventListener("test",bi,bi)}catch{gf=!1}function pk(e,t,n,r,s,o,a,l,c){var u=Array.prototype.slice.call(arguments,3);try{t.apply(n,u)}catch(d){this.onError(d)}}var Wi=!1,tc=null,nc=!1,xf=null,gk={onError:function(e){Wi=!0,tc=e}};function xk(e,t,n,r,s,o,a,l,c){Wi=!1,tc=null,pk.apply(gk,arguments)}function yk(e,t,n,r,s,o,a,l,c){if(xk.apply(this,arguments),Wi){if(Wi){var u=tc;Wi=!1,tc=null}else throw Error(V(198));nc||(nc=!0,xf=u)}}function Ys(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 N0(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 fg(e){if(Ys(e)!==e)throw Error(V(188))}function vk(e){var t=e.alternate;if(!t){if(t=Ys(e),t===null)throw Error(V(188));return t!==e?null:e}for(var n=e,r=t;;){var s=n.return;if(s===null)break;var o=s.alternate;if(o===null){if(r=s.return,r!==null){n=r;continue}break}if(s.child===o.child){for(o=s.child;o;){if(o===n)return fg(s),e;if(o===r)return fg(s),t;o=o.sibling}throw Error(V(188))}if(n.return!==r.return)n=s,r=o;else{for(var a=!1,l=s.child;l;){if(l===n){a=!0,n=s,r=o;break}if(l===r){a=!0,r=s,n=o;break}l=l.sibling}if(!a){for(l=o.child;l;){if(l===n){a=!0,n=o,r=s;break}if(l===r){a=!0,r=o,n=s;break}l=l.sibling}if(!a)throw Error(V(189))}}if(n.alternate!==r)throw Error(V(190))}if(n.tag!==3)throw Error(V(188));return n.stateNode.current===n?e:t}function C0(e){return e=vk(e),e!==null?k0(e):null}function k0(e){if(e.tag===5||e.tag===6)return e;for(e=e.child;e!==null;){var t=k0(e);if(t!==null)return t;e=e.sibling}return null}var P0=_t.unstable_scheduleCallback,hg=_t.unstable_cancelCallback,wk=_t.unstable_shouldYield,bk=_t.unstable_requestPaint,Ve=_t.unstable_now,Sk=_t.unstable_getCurrentPriorityLevel,tm=_t.unstable_ImmediatePriority,E0=_t.unstable_UserBlockingPriority,rc=_t.unstable_NormalPriority,jk=_t.unstable_LowPriority,T0=_t.unstable_IdlePriority,Hc=null,Ln=null;function Nk(e){if(Ln&&typeof Ln.onCommitFiberRoot=="function")try{Ln.onCommitFiberRoot(Hc,e,void 0,(e.current.flags&128)===128)}catch{}}var yn=Math.clz32?Math.clz32:Pk,Ck=Math.log,kk=Math.LN2;function Pk(e){return e>>>=0,e===0?32:31-(Ck(e)/kk|0)|0}var tl=64,nl=4194304;function _i(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 sc(e,t){var n=e.pendingLanes;if(n===0)return 0;var r=0,s=e.suspendedLanes,o=e.pingedLanes,a=n&268435455;if(a!==0){var l=a&~s;l!==0?r=_i(l):(o&=a,o!==0&&(r=_i(o)))}else a=n&~s,a!==0?r=_i(a):o!==0&&(r=_i(o));if(r===0)return 0;if(t!==0&&t!==r&&!(t&s)&&(s=r&-r,o=t&-t,s>=o||s===16&&(o&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-yn(t),s=1<<n,r|=e[n],t&=~s;return r}function Ek(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 Tk(e,t){for(var n=e.suspendedLanes,r=e.pingedLanes,s=e.expirationTimes,o=e.pendingLanes;0<o;){var a=31-yn(o),l=1<<a,c=s[a];c===-1?(!(l&n)||l&r)&&(s[a]=Ek(l,t)):c<=t&&(e.expiredLanes|=l),o&=~l}}function yf(e){return e=e.pendingLanes&-1073741825,e!==0?e:e&1073741824?1073741824:0}function R0(){var e=tl;return tl<<=1,!(tl&4194240)&&(tl=64),e}function Gu(e){for(var t=[],n=0;31>n;n++)t.push(e);return t}function Fa(e,t,n){e.pendingLanes|=t,t!==536870912&&(e.suspendedLanes=0,e.pingedLanes=0),e=e.eventTimes,t=31-yn(t),e[t]=n}function Rk(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-yn(n),o=1<<s;t[s]=0,r[s]=-1,e[s]=-1,n&=~o}}function nm(e,t){var n=e.entangledLanes|=t;for(e=e.entanglements;n;){var r=31-yn(n),s=1<<r;s&t|e[r]&t&&(e[r]|=t),n&=~s}}var ve=0;function A0(e){return e&=-e,1<e?4<e?e&268435455?16:536870912:4:1}var M0,rm,O0,I0,D0,vf=!1,rl=[],Kr=null,Yr=null,Gr=null,aa=new Map,la=new Map,Dr=[],Ak="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 mg(e,t){switch(e){case"focusin":case"focusout":Kr=null;break;case"dragenter":case"dragleave":Yr=null;break;case"mouseover":case"mouseout":Gr=null;break;case"pointerover":case"pointerout":aa.delete(t.pointerId);break;case"gotpointercapture":case"lostpointercapture":la.delete(t.pointerId)}}function Si(e,t,n,r,s,o){return e===null||e.nativeEvent!==o?(e={blockedOn:t,domEventName:n,eventSystemFlags:r,nativeEvent:o,targetContainers:[s]},t!==null&&(t=$a(t),t!==null&&rm(t)),e):(e.eventSystemFlags|=r,t=e.targetContainers,s!==null&&t.indexOf(s)===-1&&t.push(s),e)}function Mk(e,t,n,r,s){switch(t){case"focusin":return Kr=Si(Kr,e,t,n,r,s),!0;case"dragenter":return Yr=Si(Yr,e,t,n,r,s),!0;case"mouseover":return Gr=Si(Gr,e,t,n,r,s),!0;case"pointerover":var o=s.pointerId;return aa.set(o,Si(aa.get(o)||null,e,t,n,r,s)),!0;case"gotpointercapture":return o=s.pointerId,la.set(o,Si(la.get(o)||null,e,t,n,r,s)),!0}return!1}function L0(e){var t=ws(e.target);if(t!==null){var n=Ys(t);if(n!==null){if(t=n.tag,t===13){if(t=N0(n),t!==null){e.blockedOn=t,D0(e.priority,function(){O0(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 Ol(e){if(e.blockedOn!==null)return!1;for(var t=e.targetContainers;0<t.length;){var n=wf(e.domEventName,e.eventSystemFlags,t[0],e.nativeEvent);if(n===null){n=e.nativeEvent;var r=new n.constructor(n.type,n);mf=r,n.target.dispatchEvent(r),mf=null}else return t=$a(n),t!==null&&rm(t),e.blockedOn=n,!1;t.shift()}return!0}function pg(e,t,n){Ol(e)&&n.delete(t)}function Ok(){vf=!1,Kr!==null&&Ol(Kr)&&(Kr=null),Yr!==null&&Ol(Yr)&&(Yr=null),Gr!==null&&Ol(Gr)&&(Gr=null),aa.forEac
vendor: 11,841 bytes, line 37
37h(pg),la.forEach(pg)}function ji(e,t){e.blockedOn===t&&(e.blockedOn=null,vf||(vf=!0,_t.unstable_scheduleCallback(_t.unstable_NormalPriority,Ok)))}function ca(e){function t(s){return ji(s,e)}if(0<rl.length){ji(rl[0],e);for(var n=1;n<rl.length;n++){var r=rl[n];r.blockedOn===e&&(r.blockedOn=null)}}for(Kr!==null&&ji(Kr,e),Yr!==null&&ji(Yr,e),Gr!==null&&ji(Gr,e),aa.forEach(t),la.forEach(t),n=0;n<Dr.length;n++)r=Dr[n],r.blockedOn===e&&(r.blockedOn=null);for(;0<Dr.length&&(n=Dr[0],n.blockedOn===null);)L0(n),n.blockedOn===null&&Dr.shift()}var Co=fr.ReactCurrentBatchConfig,oc=!0;function Ik(e,t,n,r){var s=ve,o=Co.transition;Co.transition=null;try{ve=1,sm(e,t,n,r)}finally{ve=s,Co.transition=o}}function Dk(e,t,n,r){var s=ve,o=Co.transition;Co.transition=null;try{ve=4,sm(e,t,n,r)}finally{ve=s,Co.transition=o}}function sm(e,t,n,r){if(oc){var s=wf(e,t,n,r);if(s===null)sd(e,t,r,ic,n),mg(e,r);else if(Mk(s,e,t,n,r))r.stopPropagation();else if(mg(e,r),t&4&&-1<Ak.indexOf(e)){for(;s!==null;){var o=$a(s);if(o!==null&&M0(o),o=wf(e,t,n,r),o===null&&sd(e,t,r,ic,n),o===s)break;s=o}s!==null&&r.stopPropagation()}else sd(e,t,r,null,n)}}var ic=null;function wf(e,t,n,r){if(ic=null,e=em(r),e=ws(e),e!==null)if(t=Ys(e),t===null)e=null;else if(n=t.tag,n===13){if(e=N0(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 ic=e,null}function _0(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(Sk()){case tm:return 1;case E0:return 4;case rc:case jk:return 16;case T0:return 536870912;default:return 16}default:return 16}}var zr=null,om=null,Il=null;function F0(){if(Il)return Il;var e,t=om,n=t.length,r,s="value"in zr?zr.value:zr.textContent,o=s.length;for(e=0;e<n&&t[e]===s[e];e++);var a=n-e;for(r=1;r<=a&&t[n-r]===s[o-r];r++);return Il=s.slice(e,1<r?1-r:void 0)}function Dl(e){var t=e.keyCode;return"charCode"in e?(e=e.charCode,e===0&&t===13&&(e=13)):e=t,e===10&&(e=13),32<=e||e===13?e:0}function sl(){return!0}function gg(){return!1}function Vt(e){function t(n,r,s,o,a){this._reactName=n,this._targetInst=s,this.type=r,this.nativeEvent=o,this.target=a,this.currentTarget=null;for(var l in e)e.hasOwnProperty(l)&&(n=e[l],this[l]=n?n(o):o[l]);return this.isDefaultPrevented=(o.defaultPrevented!=null?o.defaultPrevented:o.returnValue===!1)?sl:gg,this.isPropagationStopped=gg,this}return Ie(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=sl)},stopPropagation:function(){var n=this.nativeEvent;n&&(n.stopPropagation?n.stopPropagation():typeof n.cancelBubble!="unknown"&&(n.cancelBubble=!0),this.isPropagationStopped=sl)},persist:function(){},isPersistent:sl}),t}var oi={eventPhase:0,bubbles:0,cancelable:0,timeStamp:function(e){return e.timeStamp||Date.now()},defaultPrevented:0,isTrusted:0},im=Vt(oi),Va=Ie({},oi,{view:0,detail:0}),Lk=Vt(Va),qu,Qu,Ni,Kc=Ie({},Va,{screenX:0,screenY:0,clientX:0,clientY:0,pageX:0,pageY:0,ctrlKey:0,shiftKey:0,altKey:0,metaKey:0,getModifierState:am,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!==Ni&&(Ni&&e.type==="mousemove"?(qu=e.screenX-Ni.screenX,Qu=e.screenY-Ni.screenY):Qu=qu=0,Ni=e),qu)},movementY:function(e){return"movementY"in e?e.movementY:Qu}}),xg=Vt(Kc),_k=Ie({},Kc,{dataTransfer:0}),Fk=Vt(_k),Vk=Ie({},Va,{relatedTarget:0}),Xu=Vt(Vk),$k=Ie({},oi,{animationName:0,elapsedTime:0,pseudoElement:0}),Bk=Vt($k),zk=Ie({},oi,{clipboardData:function(e){return"clipboardData"in e?e.clipboardData:window.clipboardData}}),Uk=Vt(zk),Wk=Ie({},oi,{data:0}),yg=Vt(Wk),Hk={Esc:"Escape",Spacebar:" ",Left:"ArrowLeft",Up:"ArrowUp",Right:"ArrowRight",Down:"ArrowDown",Del:"Delete",Win:"OS",Menu:"ContextMenu",Apps:"ContextMenu",Scroll:"ScrollLock",MozPrintableKey:"Unidentified"},Kk={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"},Yk={Alt:"altKey",Control:"ctrlKey",Meta:"metaKey",Shift:"shiftKey"};function Gk(e){var t=this.nativeEvent;return t.getModifierState?t.getModifierState(e):(e=Yk[e])?!!t[e]:!1}function am(){return Gk}var qk=Ie({},Va,{key:function(e){if(e.key){var t=Hk[e.key]||e.key;if(t!=="Unidentified")return t}return e.type==="keypress"?(e=Dl(e),e===13?"Enter":String.fromCharCode(e)):e.type==="keydown"||e.type==="keyup"?Kk[e.keyCode]||"Unidentified":""},code:0,location:0,ctrlKey:0,shiftKey:0,altKey:0,metaKey:0,repeat:0,locale:0,getModifierState:am,charCode:function(e){return e.type==="keypress"?Dl(e):0},keyCode:function(e){return e.type==="keydown"||e.type==="keyup"?e.keyCode:0},which:function(e){return e.type==="keypress"?Dl(e):e.type==="keydown"||e.type==="keyup"?e.keyCode:0}}),Qk=Vt(qk),Xk=Ie({},Kc,{pointerId:0,width:0,height:0,pressure:0,tangentialPressure:0,tiltX:0,tiltY:0,twist:0,pointerType:0,isPrimary:0}),vg=Vt(Xk),Jk=Ie({},Va,{touches:0,targetTouches:0,changedTouches:0,altKey:0,metaKey:0,ctrlKey:0,shiftKey:0,getModifierState:am}),Zk=Vt(Jk),e2=Ie({},oi,{propertyName:0,elapsedTime:0,pseudoElement:0}),t2=Vt(e2),n2=Ie({},Kc,{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}),r2=Vt(n2),s2=[9,13,27,32],lm=rr&&"CompositionEvent"in window,Hi=null;rr&&"documentMode"in document&&(Hi=document.documentMode);var o2=rr&&"TextEvent"in window&&!Hi,V0=rr&&(!lm||Hi&&8<Hi&&11>=Hi),wg=" ",bg=!1;function $0(e,t){switch(e){case"keyup":return s2.indexOf(t.keyCode)!==-1;case"keydown":return t.keyCode!==229;case"keypress":case"mousedown":case"focusout":return!0;default:return!1}}function B0(e){return e=e.detail,typeof e=="object"&&"data"in e?e.data:null}var io=!1;function i2(e,t){switch(e){case"compositionend":return B0(t);case"keypress":return t.which!==32?null:(bg=!0,wg);case"textInput":return e=t.data,e===wg&&bg?null:e;default:return null}}function a2(e,t){if(io)return e==="compositionend"||!lm&&$0(e,t)?(e=F0(),Il=om=zr=null,io=!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 V0&&t.locale!=="ko"?null:t.data;default:return null}}var l2={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 Sg(e){var t=e&&e.nodeName&&e.nodeName.toLowerCase();return t==="input"?!!l2[e.type]:t==="textarea"}function z0(e,t,n,r){v0(r),t=ac(t,"onChange"),0<t.length&&(n=new im("onChange","change",null,n,r),e.push({event:n,listeners:t}))}var Ki=null,ua=null;function c2(e){Z0(e,0)}function Yc(e){var t=co(e);if(f0(t))return e}function u2(e,t){if(e==="change")return t}var U0=!1;if(rr){var Ju;if(rr){var Zu="oninput"in document;if(!Zu){var jg=document.createElement("div");jg.setAttribute("oninput","return;"),Zu=typeof jg.oninput=="function"}Ju=Zu}else Ju=!1;U0=Ju&&(!document.documentMode||9<document.documentMode)}function Ng(){Ki&&(Ki.detachEvent("onpropertychange",W0),ua=Ki=null)}function W0(e){if(e.propertyName==="value"&&Yc(ua)){var t=[];z0(t,ua,e,em(e)),j0(c2,t)}}function d2(e,t,n){e==="focusin"?(Ng(),Ki=t,ua=n,Ki.attachEvent("onpropertychange",W0)):e==="focusout"&&Ng()}function f2(e){if(e==="selectionchange"||e==="keyup"||e==="keydown")return Yc(ua)}function h2(e,t){if(e==="click")return Yc(t)}function m2(e,t){if(e==="input"||e==="change")return Yc(t)}function p2(e,t){return e===t&&(e!==0||1/e===1/t)||e!==e&&t!==t}var wn=typeof Object.is=="function"?Object.is:p2;function da(e,t){if(wn(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(!tf.call(t,s)||!wn(e[s],t[s]))return!1}return!0}function Cg(e){for(;e&&e.firstChild;)e=e.firstChild;return e}function kg(e,t){var n=Cg(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=Cg(n)}}function H0(e,t){return e&&t?e===t?!0:e&&e.nodeType===3?!1:t&&t.nodeType===3?H0(e,t.parentNode):"contains"in e?e.contains(t):e.compareDocumentPosition?!!(e.compareDocumentPosition(t)&16):!1:!1}function K0(){for(var e=window,t=ec();t instanceof e.HTMLIFrameElement;){try{var n=typeof t.contentWindow.location.href=="string"}catch{n=!1}if(n)e=t.contentWindow;else break;t=ec(e.document)}return t}function cm(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 g2(e){var t=K0(),n=e.focusedElem,r=e.selectionRange;if(t!==n&&n&&n.ownerDocument&&H0(n.ownerDocument.documentElement,n)){if(r!==null&&cm(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,o=Math.min(r.start,s);r=r.end===void 0?o:Math.min(r.end,s),!e.extend&&o>r&&(s=r,r=o,o=s),s=kg(n,o);var a=kg(n,r);s&&a&&(e.rangeCount!==1||e.anchorNode!==s.node||e.anchorOffset!==s.offset||e.focusNode!==a.node||e.focusOffset!==a.offset)&&(t=t.createRange(),t.setStart(s.node,s.offset),e.removeAllRanges(),o>r?(e.addRange(t),e.extend(a.node,a.offset)):(t.setEnd(a.node,a.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 x2=rr&&"documentMode"in document&&11>=document.documentMode,ao=null,bf=null,Yi=null,Sf=!1;function Pg(e,t,n){var r=n.window===n?n.document:n.nodeType===9?n:n.ownerDocument;Sf||ao==null||ao!==ec(r)||(r=ao,"selectionStart"in r&&cm(r)?r={start:r.selectionStart,end:r.selectionEnd}:(r=(r.ownerDocument&&r.ownerDocument.defaultView||window).getSelection(),r={anchorNode:r.anchorNode,anchorOffset:r.anchorOffset,focu
vendor: 4,352 bytes, line 37
37sNode:r.focusNode,focusOffset:r.focusOffset}),Yi&&da(Yi,r)||(Yi=r,r=ac(bf,"onSelect"),0<r.length&&(t=new im("onSelect","select",null,t,n),e.push({event:t,listeners:r}),t.target=ao)))}function ol(e,t){var n={};return n[e.toLowerCase()]=t.toLowerCase(),n["Webkit"+e]="webkit"+t,n["Moz"+e]="moz"+t,n}var lo={animationend:ol("Animation","AnimationEnd"),animationiteration:ol("Animation","AnimationIteration"),animationstart:ol("Animation","AnimationStart"),transitionend:ol("Transition","TransitionEnd")},ed={},Y0={};rr&&(Y0=document.createElement("div").style,"AnimationEvent"in window||(delete lo.animationend.animation,delete lo.animationiteration.animation,delete lo.animationstart.animation),"TransitionEvent"in window||delete lo.transitionend.transition);function Gc(e){if(ed[e])return ed[e];if(!lo[e])return e;var t=lo[e],n;for(n in t)if(t.hasOwnProperty(n)&&n in Y0)return ed[e]=t[n];return e}var G0=Gc("animationend"),q0=Gc("animationiteration"),Q0=Gc("animationstart"),X0=Gc("transitionend"),J0=new Map,Eg="abort auxClick cancel canPlay canPlayThrough click close contextMenu copy cut drag dragEnd dragEnter dragExit dragLeave dragOver dragStart drop durationChange emptied encrypted ended error gotPointerCapture input invalid keyDown keyPress keyUp load loadedData loadedMetadata loadStart lostPointerCapture mouseDown mouseMove mouseOut mouseOver mouseUp paste pause play playing pointerCancel pointerDown pointerMove pointerOut pointerOver pointerUp progress rateChange reset resize seeked seeking stalled submit suspend timeUpdate touchCancel touchEnd touchStart volumeChange scroll toggle touchMove waiting wheel".split(" ");function as(e,t){J0.set(e,t),Ks(t,[e])}for(var td=0;td<Eg.length;td++){var nd=Eg[td],y2=nd.toLowerCase(),v2=nd[0].toUpperCase()+nd.slice(1);as(y2,"on"+v2)}as(G0,"onAnimationEnd");as(q0,"onAnimationIteration");as(Q0,"onAnimationStart");as("dblclick","onDoubleClick");as("focusin","onFocus");as("focusout","onBlur");as(X0,"onTransitionEnd");Uo("onMouseEnter",["mouseout","mouseover"]);Uo("onMouseLeave",["mouseout","mouseover"]);Uo("onPointerEnter",["pointerout","pointerover"]);Uo("onPointerLeave",["pointerout","pointerover"]);Ks("onChange","change click focusin focusout input keydown keyup selectionchange".split(" "));Ks("onSelect","focusout contextmenu dragend focusin keydown keyup mousedown mouseup selectionchange".split(" "));Ks("onBeforeInput",["compositionend","keypress","textInput","paste"]);Ks("onCompositionEnd","compositionend focusout keydown keypress keyup mousedown".split(" "));Ks("onCompositionStart","compositionstart focusout keydown keypress keyup mousedown".split(" "));Ks("onCompositionUpdate","compositionupdate focusout keydown keypress keyup mousedown".split(" "));var Fi="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(" "),w2=new Set("cancel close invalid load scroll toggle".split(" ").concat(Fi));function Tg(e,t,n){var r=e.type||"unknown-event";e.currentTarget=n,yk(r,t,void 0,e),e.currentTarget=null}function Z0(e,t){t=(t&4)!==0;for(var n=0;n<e.length;n++){var r=e[n],s=r.event;r=r.listeners;e:{var o=void 0;if(t)for(var a=r.length-1;0<=a;a--){var l=r[a],c=l.instance,u=l.currentTarget;if(l=l.listener,c!==o&&s.isPropagationStopped())break e;Tg(s,l,u),o=c}else for(a=0;a<r.length;a++){if(l=r[a],c=l.instance,u=l.currentTarget,l=l.listener,c!==o&&s.isPropagationStopped())break e;Tg(s,l,u),o=c}}}if(nc)throw e=xf,nc=!1,xf=null,e}function Ce(e,t){var n=t[Pf];n===void 0&&(n=t[Pf]=new Set);var r=e+"__bubble";n.has(r)||(ew(t,e,2,!1),n.add(r))}function rd(e,t,n){var r=0;t&&(r|=4),ew(n,e,r,t)}var il="_reactListening"+Math.random().toString(36).slice(2);function fa(e){if(!e[il]){e[il]=!0,a0.forEach(function(n){n!=="selectionchange"&&(w2.has(n)||rd(n,!1,e),rd(n,!0,e))});var t=e.nodeType===9?e:e.ownerDocument;t===null||t[il]||(t[il]=!0,rd("selectionchange",!1,t))}}function ew(e,t,n,r){switch(_0(t)){case 1:var s=Ik;break;case 4:s=Dk;break;default:s=sm}n=s.bind(null,t,n,e),s=void 0,!gf||t!=="touchstart"&&t!=="touchmove"&&t!=="wheel"||(s=!0),r?s!==void 0?e.addEventListener(t,n,{capture:!0,passive:s}):e.addEventListener(t,n,!0):s!==void 0?e.addEventListener(t,n,{passive:s}):e.addEventListener(t,n,!1)}
vendor: 4,100 bytes, line 37
37function sd(e,t,n,r,s){var o=r;if(!(t&1)&&!(t&2)&&r!==null)e:for(;;){if(r===null)return;var a=r.tag;if(a===3||a===4){var l=r.stateNode.containerInfo;if(l===s||l.nodeType===8&&l.parentNode===s)break;if(a===4)for(a=r.return;a!==null;){var c=a.tag;if((c===3||c===4)&&(c=a.stateNode.containerInfo,c===s||c.nodeType===8&&c.parentNode===s))return;a=a.return}for(;l!==null;){if(a=ws(l),a===null)return;if(c=a.tag,c===5||c===6){r=o=a;continue e}l=l.parentNode}}r=r.return}j0(function(){var u=o,d=em(n),f=[];e:{var m=J0.get(e);if(m!==void 0){var p=im,b=e;switch(e){case"keypress":if(Dl(n)===0)break e;case"keydown":case"keyup":p=Qk;break;case"focusin":b="focus",p=Xu;break;case"focusout":b="blur",p=Xu;break;case"beforeblur":case"afterblur":p=Xu;break;case"click":if(n.button===2)break e;case"auxclick":case"dblclick":case"mousedown":case"mousemove":case"mouseup":case"mouseout":case"mouseover":case"contextmenu":p=xg;break;case"drag":case"dragend":case"dragenter":case"dragexit":case"dragleave":case"dragover":case"dragstart":case"drop":p=Fk;break;case"touchcancel":case"touchend":case"touchmove":case"touchstart":p=Zk;break;case G0:case q0:case Q0:p=Bk;break;case X0:p=t2;break;case"scroll":p=Lk;break;case"wheel":p=r2;break;case"copy":case"cut":case"paste":p=Uk;break;case"gotpointercapture":case"lostpointercapture":case"pointercancel":case"pointerdown":case"pointermove":case"pointerout":case"pointerover":case"pointerup":p=vg}var x=(t&4)!==0,y=!x&&e==="scroll",w=x?m!==null?m+"Capture":null:m;x=[];for(var g=u,v;g!==null;){v=g;var S=v.stateNode;if(v.tag===5&&S!==null&&(v=S,w!==null&&(S=ia(g,w),S!=null&&x.push(ha(g,S,v)))),y)break;g=g.return}0<x.length&&(m=new p(m,b,null,n,d),f.push({event:m,listeners:x}))}}if(!(t&7)){e:{if(m=e==="mouseover"||e==="pointerover",p=e==="mouseout"||e==="pointerout",m&&n!==mf&&(b=n.relatedTarget||n.fromElement)&&(ws(b)||b[sr]))break e;if((p||m)&&(m=d.window===d?d:(m=d.ownerDocument)?m.defaultView||m.parentWindow:window,p?(b=n.relatedTarget||n.toElement,p=u,b=b?ws(b):null,b!==null&&(y=Ys(b),b!==y||b.tag!==5&&b.tag!==6)&&(b=null)):(p=null,b=u),p!==b)){if(x=xg,S="onMouseLeave",w="onMouseEnter",g="mouse",(e==="pointerout"||e==="pointerover")&&(x=vg,S="onPointerLeave",w="onPointerEnter",g="pointer"),y=p==null?m:co(p),v=b==null?m:co(b),m=new x(S,g+"leave",p,n,d),m.target=y,m.relatedTarget=v,S=null,ws(d)===u&&(x=new x(w,g+"enter",b,n,d),x.target=v,x.relatedTarget=y,S=x),y=S,p&&b)t:{for(x=p,w=b,g=0,v=x;v;v=Xs(v))g++;for(v=0,S=w;S;S=Xs(S))v++;for(;0<g-v;)x=Xs(x),g--;for(;0<v-g;)w=Xs(w),v--;for(;g--;){if(x===w||w!==null&&x===w.alternate)break t;x=Xs(x),w=Xs(w)}x=null}else x=null;p!==null&&Rg(f,m,p,x,!1),b!==null&&y!==null&&Rg(f,y,b,x,!0)}}e:{if(m=u?co(u):window,p=m.nodeName&&m.nodeName.toLowerCase(),p==="select"||p==="input"&&m.type==="file")var j=u2;else if(Sg(m))if(U0)j=m2;else{j=f2;var C=d2}else(p=m.nodeName)&&p.toLowerCase()==="input"&&(m.type==="checkbox"||m.type==="radio")&&(j=h2);if(j&&(j=j(e,u))){z0(f,j,n,d);break e}C&&C(e,m,u),e==="focusout"&&(C=m._wrapperState)&&C.controlled&&m.type==="number"&&cf(m,"number",m.value)}switch(C=u?co(u):window,e){case"focusin":(Sg(C)||C.contentEditable==="true")&&(ao=C,bf=u,Yi=null);break;case"focusout":Yi=bf=ao=null;break;case"mousedown":Sf=!0;break;case"contextmenu":case"mouseup":case"dragend":Sf=!1,Pg(f,n,d);break;case"selectionchange":if(x2)break;case"keydown":case"keyup":Pg(f,n,d)}var P;if(lm)e:{switch(e){case"compositionstart":var N="onCompositionStart";break e;case"compositionend":N="onCompositionEnd";break e;case"compositionupdate":N="onCompositionUpdate";break e}N=void 0}else io?$0(e,n)&&(N="onCompositionEnd"):e==="keydown"&&n.keyCode===229&&(N="onCompositionStart");N&&(V0&&n.locale!=="ko"&&(io||N!=="onCompositionStart"?N==="onCompositionEnd"&&io&&(P=F0()):(zr=d,om="value"in zr?zr.value:zr.textContent,io=!0)),C=ac(u,N),0<C.length&&(N=new yg(N,e,null,n,d),f.push({event:N,listeners:C}),P?N.data=P:(P=B0(n),P!==null&&(N.data=P)))),(P=o2?i2(e,n):a2(e,n))&&(u=ac(u,"onBeforeInput"),0<u.length&&(d=new yg("onBeforeInput","beforeinput",null,n,d),f.push({event:d,listeners:u}),d.data=P))}Z0(f,t)})}
vendor: 4,381 bytes, lines 37-38
37function ha(e,t,n){return{instance:e,listener:t,currentTarget:n}}function ac(e,t){for(var n=t+"Capture",r=[];e!==null;){var s=e,o=s.stateNode;s.tag===5&&o!==null&&(s=o,o=ia(e,n),o!=null&&r.unshift(ha(e,o,s)),o=ia(e,t),o!=null&&r.push(ha(e,o,s))),e=e.return}return r}function Xs(e){if(e===null)return null;do e=e.return;while(e&&e.tag!==5);return e||null}function Rg(e,t,n,r,s){for(var o=t._reactName,a=[];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=ia(n,o),c!=null&&a.unshift(ha(n,c,l))):s||(c=ia(n,o),c!=null&&a.push(ha(n,c,l)))),n=n.return}a.length!==0&&e.push({event:t,listeners:a})}var b2=/\r\n?/g,S2=/\u0000|\uFFFD/g;function Ag(e){return(typeof e=="string"?e:""+e).replace(b2,`
38`).replace(S2,"")}function al(e,t,n){if(t=Ag(t),Ag(e)!==t&&n)throw Error(V(425))}function lc(){}var jf=null,Nf=null;function Cf(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 kf=typeof setTimeout=="function"?setTimeout:void 0,j2=typeof clearTimeout=="function"?clearTimeout:void 0,Mg=typeof Promise=="function"?Promise:void 0,N2=typeof queueMicrotask=="function"?queueMicrotask:typeof Mg<"u"?function(e){return Mg.resolve(null).then(e).catch(C2)}:kf;function C2(e){setTimeout(function(){throw e})}function od(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),ca(t);return}r--}else n!=="$"&&n!=="$?"&&n!=="$!"||r++;n=s}while(n);ca(t)}function qr(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 Og(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 ii=Math.random().toString(36).slice(2),An="__reactFiber$"+ii,ma="__reactProps$"+ii,sr="__reactContainer$"+ii,Pf="__reactEvents$"+ii,k2="__reactListeners$"+ii,P2="__reactHandles$"+ii;function ws(e){var t=e[An];if(t)return t;for(var n=e.parentNode;n;){if(t=n[sr]||n[An]){if(n=t.alternate,t.child!==null||n!==null&&n.child!==null)for(e=Og(e);e!==null;){if(n=e[An])return n;e=Og(e)}return t}e=n,n=e.parentNode}return null}function $a(e){return e=e[An]||e[sr],!e||e.tag!==5&&e.tag!==6&&e.tag!==13&&e.tag!==3?null:e}function co(e){if(e.tag===5||e.tag===6)return e.stateNode;throw Error(V(33))}function qc(e){return e[ma]||null}var Ef=[],uo=-1;function ls(e){return{current:e}}function ke(e){0>uo||(e.current=Ef[uo],Ef[uo]=null,uo--)}function je(e,t){uo++,Ef[uo]=e.current,e.current=t}var ns={},ut=ls(ns),kt=ls(!1),Ds=ns;function Wo(e,t){var n=e.type.contextTypes;if(!n)return ns;var r=e.stateNode;if(r&&r.__reactInternalMemoizedUnmaskedChildContext===t)return r.__reactInternalMemoizedMaskedChildContext;var s={},o;for(o in n)s[o]=t[o];return r&&(e=e.stateNode,e.__reactInternalMemoizedUnmaskedChildContext=t,e.__reactInternalMemoizedMaskedChildContext=s),s}function Pt(e){return e=e.childContextTypes,e!=null}function cc(){ke(kt),ke(ut)}function Ig(e,t,n){if(ut.current!==ns)throw Error(V(168));je(ut,t),je(kt,n)}function tw(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(V(108,dk(e)||"Unknown",s));return Ie({},n,r)}function uc(e){return e=(e=e.stateNode)&&e.__reactInternalMemoizedMergedChildContext||ns,Ds=ut.current,je(ut,e),je(kt,kt.current),!0}function Dg(e,t,n){var r=e.stateNode;if(!r)throw Error(V(169));n?(e=tw(e,t,Ds),r.__reactInternalMemoizedMergedChildContext=e,ke(kt),ke(ut),je(ut,e)):ke(kt),je(kt,n)}var Qn=null,Qc=!1,id=!1;function nw(e){Qn===null?Qn=[e]:Qn.push(e)}function E2(e){Qc=!0,nw(e)}function cs(){if(!id&&Qn!==null){id=!0;var e=0,t=ve;try{var n=Qn;for(ve=1;e<n.length;e++){var r=n[e];do r=r(!0);while(r!==null)}Qn=null,Qc=!1}catch(s){throw Qn!==null&&(Qn=Qn.slice(e+1)),P0(tm,cs),s}finally{ve=t,id=!1}}return null}var fo=[],ho=0,dc=null,fc=0,Ut=[],Wt=0,Ls=null,Jn=1,Zn="";function gs(e,t){fo[ho++]=fc,fo[ho++]=dc,dc=e,fc=t}function rw(e,t,n){Ut[Wt++]=Jn,Ut[Wt++]=Zn,Ut[Wt++]=Ls,Ls=e;var r=Jn;e=Zn;var s=32-yn(r)-1;r&=~(1<<s),n+=1;var o=32-yn(t)+s;
vendor: 14,489 bytes, line 38
38if(30<o){var a=s-s%5;o=(r&(1<<a)-1).toString(32),r>>=a,s-=a,Jn=1<<32-yn(t)+s|n<<s|r,Zn=o+e}else Jn=1<<o|n<<s|r,Zn=e}function um(e){e.return!==null&&(gs(e,1),rw(e,1,0))}function dm(e){for(;e===dc;)dc=fo[--ho],fo[ho]=null,fc=fo[--ho],fo[ho]=null;for(;e===Ls;)Ls=Ut[--Wt],Ut[Wt]=null,Zn=Ut[--Wt],Ut[Wt]=null,Jn=Ut[--Wt],Ut[Wt]=null}var Dt=null,It=null,Te=!1,pn=null;function sw(e,t){var n=Ht(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 Lg(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,Dt=e,It=qr(t.firstChild),!0):!1;case 6:return t=e.pendingProps===""||t.nodeType!==3?null:t,t!==null?(e.stateNode=t,Dt=e,It=null,!0):!1;case 13:return t=t.nodeType!==8?null:t,t!==null?(n=Ls!==null?{id:Jn,overflow:Zn}:null,e.memoizedState={dehydrated:t,treeContext:n,retryLane:1073741824},n=Ht(18,null,null,0),n.stateNode=t,n.return=e,e.child=n,Dt=e,It=null,!0):!1;default:return!1}}function Tf(e){return(e.mode&1)!==0&&(e.flags&128)===0}function Rf(e){if(Te){var t=It;if(t){var n=t;if(!Lg(e,t)){if(Tf(e))throw Error(V(418));t=qr(n.nextSibling);var r=Dt;t&&Lg(e,t)?sw(r,n):(e.flags=e.flags&-4097|2,Te=!1,Dt=e)}}else{if(Tf(e))throw Error(V(418));e.flags=e.flags&-4097|2,Te=!1,Dt=e}}}function _g(e){for(e=e.return;e!==null&&e.tag!==5&&e.tag!==3&&e.tag!==13;)e=e.return;Dt=e}function ll(e){if(e!==Dt)return!1;if(!Te)return _g(e),Te=!0,!1;var t;if((t=e.tag!==3)&&!(t=e.tag!==5)&&(t=e.type,t=t!=="head"&&t!=="body"&&!Cf(e.type,e.memoizedProps)),t&&(t=It)){if(Tf(e))throw ow(),Error(V(418));for(;t;)sw(e,t),t=qr(t.nextSibling)}if(_g(e),e.tag===13){if(e=e.memoizedState,e=e!==null?e.dehydrated:null,!e)throw Error(V(317));e:{for(e=e.nextSibling,t=0;e;){if(e.nodeType===8){var n=e.data;if(n==="/$"){if(t===0){It=qr(e.nextSibling);break e}t--}else n!=="$"&&n!=="$!"&&n!=="$?"||t++}e=e.nextSibling}It=null}}else It=Dt?qr(e.stateNode.nextSibling):null;return!0}function ow(){for(var e=It;e;)e=qr(e.nextSibling)}function Ho(){It=Dt=null,Te=!1}function fm(e){pn===null?pn=[e]:pn.push(e)}var T2=fr.ReactCurrentBatchConfig;function Ci(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(V(309));var r=n.stateNode}if(!r)throw Error(V(147,e));var s=r,o=""+e;return t!==null&&t.ref!==null&&typeof t.ref=="function"&&t.ref._stringRef===o?t.ref:(t=function(a){var l=s.refs;a===null?delete l[o]:l[o]=a},t._stringRef=o,t)}if(typeof e!="string")throw Error(V(284));if(!n._owner)throw Error(V(290,e))}return e}function cl(e,t){throw e=Object.prototype.toString.call(t),Error(V(31,e==="[object Object]"?"object with keys {"+Object.keys(t).join(", ")+"}":e))}function Fg(e){var t=e._init;return t(e._payload)}function iw(e){function t(w,g){if(e){var v=w.deletions;v===null?(w.deletions=[g],w.flags|=16):v.push(g)}}function n(w,g){if(!e)return null;for(;g!==null;)t(w,g),g=g.sibling;return null}function r(w,g){for(w=new Map;g!==null;)g.key!==null?w.set(g.key,g):w.set(g.index,g),g=g.sibling;return w}function s(w,g){return w=Zr(w,g),w.index=0,w.sibling=null,w}function o(w,g,v){return w.index=v,e?(v=w.alternate,v!==null?(v=v.index,v<g?(w.flags|=2,g):v):(w.flags|=2,g)):(w.flags|=1048576,g)}function a(w){return e&&w.alternate===null&&(w.flags|=2),w}function l(w,g,v,S){return g===null||g.tag!==6?(g=hd(v,w.mode,S),g.return=w,g):(g=s(g,v),g.return=w,g)}function c(w,g,v,S){var j=v.type;return j===oo?d(w,g,v.props.children,S,v.key):g!==null&&(g.elementType===j||typeof j=="object"&&j!==null&&j.$$typeof===Mr&&Fg(j)===g.type)?(S=s(g,v.props),S.ref=Ci(w,g,v),S.return=w,S):(S=zl(v.type,v.key,v.props,null,w.mode,S),S.ref=Ci(w,g,v),S.return=w,S)}function u(w,g,v,S){return g===null||g.tag!==4||g.stateNode.containerInfo!==v.containerInfo||g.stateNode.implementation!==v.implementation?(g=md(v,w.mode,S),g.return=w,g):(g=s(g,v.children||[]),g.return=w,g)}function d(w,g,v,S,j){return g===null||g.tag!==7?(g=Os(v,w.mode,S,j),g.return=w,g):(g=s(g,v),g.return=w,g)}function f(w,g,v){if(typeof g=="string"&&g!==""||typeof g=="number")return g=hd(""+g,w.mode,v),g.return=w,g;if(typeof g=="object"&&g!==null){switch(g.$$typeof){case Ja:return v=zl(g.type,g.key,g.props,null,w.mode,v),v.ref=Ci(w,null,g),v.return=w,v;case so:return g=md(g,w.mode,v),g.return=w,g;case Mr:var S=g._init;return f(w,S(g._payload),v)}if(Li(g)||wi(g))return g=Os(g,w.mode,v,null),g.return=w,g;cl(w,g)}return null}function m(w,g,v,S){var j=g!==null?g.key:null;if(typeof v=="string"&&v!==""||typeof v=="number")return j!==null?null:l(w,g,""+v,S);if(typeof v=="object"&&v!==null){switch(v.$$typeof){case Ja:return v.key===j?c(w,g,v,S):null;case so:return v.key===j?u(w,g,v,S):null;case Mr:return j=v._init,m(w,g,j(v._payload),S)}if(Li(v)||wi(v))return j!==null?null:d(w,g,v,S,null);cl(w,v)}return null}function p(w,g,v,S,j){if(typeof S=="string"&&S!==""||typeof S=="number")return w=w.get(v)||null,l(g,w,""+S,j);if(typeof S=="object"&&S!==null){switch(S.$$typeof){case Ja:return w=w.get(S.key===null?v:S.key)||null,c(g,w,S,j);case so:return w=w.get(S.key===null?v:S.key)||null,u(g,w,S,j);case Mr:var C=S._init;return p(w,g,v,C(S._payload),j)}if(Li(S)||wi(S))return w=w.get(v)||null,d(g,w,S,j,null);cl(g,S)}return null}function b(w,g,v,S){for(var j=null,C=null,P=g,N=g=0,E=null;P!==null&&N<v.length;N++){P.index>N?(E=P,P=null):E=P.sibling;var k=m(w,P,v[N],S);if(k===null){P===null&&(P=E);break}e&&P&&k.alternate===null&&t(w,P),g=o(k,g,N),C===null?j=k:C.sibling=k,C=k,P=E}if(N===v.length)return n(w,P),Te&&gs(w,N),j;if(P===null){for(;N<v.length;N++)P=f(w,v[N],S),P!==null&&(g=o(P,g,N),C===null?j=P:C.sibling=P,C=P);return Te&&gs(w,N),j}for(P=r(w,P);N<v.length;N++)E=p(P,w,N,v[N],S),E!==null&&(e&&E.alternate!==null&&P.delete(E.key===null?N:E.key),g=o(E,g,N),C===null?j=E:C.sibling=E,C=E);return e&&P.forEach(function(R){return t(w,R)}),Te&&gs(w,N),j}function x(w,g,v,S){var j=wi(v);if(typeof j!="function")throw Error(V(150));if(v=j.call(v),v==null)throw Error(V(151));for(var C=j=null,P=g,N=g=0,E=null,k=v.next();P!==null&&!k.done;N++,k=v.next()){P.index>N?(E=P,P=null):E=P.sibling;var R=m(w,P,k.value,S);if(R===null){P===null&&(P=E);break}e&&P&&R.alternate===null&&t(w,P),g=o(R,g,N),C===null?j=R:C.sibling=R,C=R,P=E}if(k.done)return n(w,P),Te&&gs(w,N),j;if(P===null){for(;!k.done;N++,k=v.next())k=f(w,k.value,S),k!==null&&(g=o(k,g,N),C===null?j=k:C.sibling=k,C=k);return Te&&gs(w,N),j}for(P=r(w,P);!k.done;N++,k=v.next())k=p(P,w,N,k.value,S),k!==null&&(e&&k.alternate!==null&&P.delete(k.key===null?N:k.key),g=o(k,g,N),C===null?j=k:C.sibling=k,C=k);return e&&P.forEach(function(M){return t(w,M)}),Te&&gs(w,N),j}function y(w,g,v,S){if(typeof v=="object"&&v!==null&&v.type===oo&&v.key===null&&(v=v.props.children),typeof v=="object"&&v!==null){switch(v.$$typeof){case Ja:e:{for(var j=v.key,C=g;C!==null;){if(C.key===j){if(j=v.type,j===oo){if(C.tag===7){n(w,C.sibling),g=s(C,v.props.children),g.return=w,w=g;break e}}else if(C.elementType===j||typeof j=="object"&&j!==null&&j.$$typeof===Mr&&Fg(j)===C.type){n(w,C.sibling),g=s(C,v.props),g.ref=Ci(w,C,v),g.return=w,w=g;break e}n(w,C);break}else t(w,C);C=C.sibling}v.type===oo?(g=Os(v.props.children,w.mode,S,v.key),g.return=w,w=g):(S=zl(v.type,v.key,v.props,null,w.mode,S),S.ref=Ci(w,g,v),S.return=w,w=S)}return a(w);case so:e:{for(C=v.key;g!==null;){if(g.key===C)if(g.tag===4&&g.stateNode.containerInfo===v.containerInfo&&g.stateNode.implementation===v.implementation){n(w,g.sibling),g=s(g,v.children||[]),g.return=w,w=g;break e}else{n(w,g);break}else t(w,g);g=g.sibling}g=md(v,w.mode,S),g.return=w,w=g}return a(w);case Mr:return C=v._init,y(w,g,C(v._payload),S)}if(Li(v))return b(w,g,v,S);if(wi(v))return x(w,g,v,S);cl(w,v)}return typeof v=="string"&&v!==""||typeof v=="number"?(v=""+v,g!==null&&g.tag===6?(n(w,g.sibling),g=s(g,v),g.return=w,w=g):(n(w,g),g=hd(v,w.mode,S),g.return=w,w=g),a(w)):n(w,g)}return y}var Ko=iw(!0),aw=iw(!1),hc=ls(null),mc=null,mo=null,hm=null;function mm(){hm=mo=mc=null}function pm(e){var t=hc.current;ke(hc),e._currentValue=t}function Af(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 ko(e,t){mc=e,hm=mo=null,e=e.dependencies,e!==null&&e.firstContext!==null&&(e.lanes&t&&(Ct=!0),e.firstContext=null)}function qt(e){var t=e._currentValue;if(hm!==e)if(e={context:e,memoizedValue:t,next:null},mo===null){if(mc===null)throw Error(V(308));mo=e,mc.dependencies={lanes:0,firstContext:e}}else mo=mo.next=e;return t}var bs=null;function gm(e){bs===null?bs=[e]:bs.push(e)}function lw(e,t,n,r){var s=t.interleaved;return s===null?(n.next=n,gm(t)):(n.next=s.next,s.next=n),t.interleaved=n,or(e,r)}function or(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 Or=!1;function xm(e){e.updateQueue={baseState:e.memoizedState,firstBaseUpdate:null,lastBaseUpdate:null,shared:{pending:null,interleaved:null,lanes:0},effects:null}}function cw(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 tr(e,t){return{eventTime:e,lane:t,tag:0,payload:null,callback:null,next:null}}function Qr(e,t,n){var r=e.updateQueue;if(r===null)return null;if(r=r.shared,me&2){var s=r.pending;return s===null?t.next=t:(t.next=s.next,s.next=t),r.pending=t,or(e,n)}return s=r.interleaved,s===null?(t.next=t,gm(r)):(t.next=s.next,s.next=t),r.interleaved=t,or(e,n)}function Ll(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,nm(e,n)}}function Vg(e,t){var n=e.updateQueue,r=e.alternate;if(r!==null&&(r=r.updateQueue,n===r)){var s=null,o=null;if(n=n.firstBaseUpdate,n!==null){do{var a={eventTime:n.eventTime,lane:n.lane,tag:n.tag,payload:n.payload,callback:n.callback,next:null};o===null?s=o=a:o=o.next=a,n=n.next}while(n!==null);o===null?s=o=t:o=o.next=t}else s=o=t;n={baseState:r.baseState,firstBaseUpdate:s,lastBaseUpdate:o,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 pc(e,t,n,r){var s=e.updateQueue;Or=!1;var o=s.firstBaseUpdate,a=s.lastBaseUpdate,l=s.shared.pending;if(l!==null){s.shared.pending=null;var c=l,u=c.next;c.next=null,a===null?o=u:a.next=u,a=c;var d=e.alternate;d!==null&&(d=d.updateQueue,l=d.lastBaseUpdate,l!==a&&(l===null?d.firstBaseUpdate=u:l.next=u,d.lastBaseUpdate=c))}if(o!==null){var f=s.baseState;a=0,d=u=c=null,l=o;do{var m=l.lane,p=l.eventTime;if((r&m)===m){d!==null&&(d=d.next={eventTime:p,lane:0,tag:l.tag,payload:l.payload,callback:l.callback,next:null});e:{var b=e,x=l;switch(m=t,p=n,x.tag){case 1:if(b=x.payload,typeof b=="function"){f=b.call(p,f,m);break e}f=b;break e;case 3:b.flags=b.flags&-65537|128;case 0:if(b=x.payload,m=typeof b=="function"?b.call(p,f,m):b,m==null)break e;f=Ie({},f,m);break e;case 2:Or=!0}}l.callback!==null&&l.lane!==0&&(e.flags|=64,m=s.effects,m===null?s.effects=[l]:m.push(l))}else p={eventTime:p,lane:m,tag:l.tag,payload:l.payload,callback:l.callback,next:null},d===null?(u=d=p,c=f):d=d.next=p,a|=m;if(l=l.next,l===null){if(l=s.shared.pending,l===null)break;m=l,l=m.next,m.next=null,s.lastBaseUpdate=m,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 a|=s.lane,s=s.next;while(s!==t)}else o===null&&(s.shared.lanes=0);Fs|=a,e.lanes=a,e.memoizedState=f}}function $g(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(V(191,s));s.call(r)}}}var Ba={},_n=ls(Ba),pa=ls(Ba),ga=ls(Ba);function Ss(e){if(e===Ba)throw Error(V(174));return e}function ym(e,t){switch(je(ga,t),je(pa,e),je(_n,Ba),e=t.nodeType,e){case 9:case 11:t=(t=t.documentElement)?t.namespaceURI:df(null,"");break;default:e=e===8?t.parentNode:t,t=e.namespaceURI||null,e=e.tagName,t=df(t,e)}ke(_n),je(_n,t)}function Yo(){ke(_n),ke(pa),ke(ga)}function uw(e){Ss(ga.current);var t=Ss(_n.current),n=df(t,e.type);t!==n&&(je(pa,e),je(_n,n))}function vm(e){pa.current===e&&(ke(_n),ke(pa))}var Ae=ls(0);function gc(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 ad=[];function wm(){for(var e=0;e<ad.length;e++)ad[e]._workInProgressVersionPrimary=null;ad.length=0}var _l=fr.ReactCurrentDispatcher,ld=fr.ReactCurrentBatchConfig,_s=0,Oe=null,He=null,qe=null,xc=!1,Gi=!1,xa=0,R2=0;function ot(){throw Error(V(321))}function bm(e,t){if(t===null)return!1;for(var n=0;n<t.length&&n<e.length;n++)if(!wn(e[n],t[n]))return!1;return!0}function Sm(e,t,n,r,s,o){if(_s=o,Oe=t,t.memoizedState=null,t.updateQueue=null,t.lanes=0,_l.current=e===null||e.memoizedState===null?I2:D2,e=n(r,s),Gi){o=0;do{if(Gi=!1,xa=0,25<=o)throw Error(V(301));o+=1,qe=He=null,t.updateQueue=null,_l.current=L2,e=n(r,s)}while(Gi)}if(_l.current=yc,t=He!==null&&He.next!==null,_s=0,qe=He=Oe=null,xc=!1,t)throw Error(V(300));return e}function jm(){var e=xa!==0;return xa=0,e}function Pn(){var e={memoizedState:null,baseState:null,baseQueue:null,queue:null,next:null};return qe===null?Oe.memoizedState=qe=e:qe=qe.next=e,qe}function Qt(){if(He===null){var e=Oe.alternate;e=e!==null?e.memoizedState:null}else e=He.next;var t=qe===null?Oe.memoizedState:qe.next;if(t!==null)qe=t,He=e;else{if(e===null)throw Error(V(310));He=e,e={memoizedState:He.memoizedState,baseState:He.baseState,baseQueue:He.baseQueue,queue:He.queue,next:null},qe===null?Oe.memoizedState=qe=e:qe=qe.next=e}return qe}function ya(e,t){return typeof t=="function"?t(e):t}function cd(e){var t=Qt(),n=t.queue;if(n===null)throw Error(V(311));n.lastRenderedReducer=e;var r=He,s=r.baseQueue,o=n.pending;if(o!==null){if(s!==null){var a=s.next;s.next=o.next,o.next=a}r.baseQueue=s=o,n.pending=null}if(s!==null){o=s.next,r=r.baseState;var l=a=null,c=null,u=o;do{var d=u.lane;
vendor: 6,504 bytes, line 38
38if((_s&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,a=r):c=c.next=f,Oe.lanes|=d,Fs|=d}u=u.next}while(u!==null&&u!==o);c===null?a=r:c.next=l,wn(r,t.memoizedState)||(Ct=!0),t.memoizedState=r,t.baseState=a,t.baseQueue=c,n.lastRenderedState=r}if(e=n.interleaved,e!==null){s=e;do o=s.lane,Oe.lanes|=o,Fs|=o,s=s.next;while(s!==e)}else s===null&&(n.lanes=0);return[t.memoizedState,n.dispatch]}function ud(e){var t=Qt(),n=t.queue;if(n===null)throw Error(V(311));n.lastRenderedReducer=e;var r=n.dispatch,s=n.pending,o=t.memoizedState;if(s!==null){n.pending=null;var a=s=s.next;do o=e(o,a.action),a=a.next;while(a!==s);wn(o,t.memoizedState)||(Ct=!0),t.memoizedState=o,t.baseQueue===null&&(t.baseState=o),n.lastRenderedState=o}return[o,r]}function dw(){}function fw(e,t){var n=Oe,r=Qt(),s=t(),o=!wn(r.memoizedState,s);if(o&&(r.memoizedState=s,Ct=!0),r=r.queue,Nm(pw.bind(null,n,r,e),[e]),r.getSnapshot!==t||o||qe!==null&&qe.memoizedState.tag&1){if(n.flags|=2048,va(9,mw.bind(null,n,r,s,t),void 0,null),Qe===null)throw Error(V(349));_s&30||hw(n,t,s)}return s}function hw(e,t,n){e.flags|=16384,e={getSnapshot:t,value:n},t=Oe.updateQueue,t===null?(t={lastEffect:null,stores:null},Oe.updateQueue=t,t.stores=[e]):(n=t.stores,n===null?t.stores=[e]:n.push(e))}function mw(e,t,n,r){t.value=n,t.getSnapshot=r,gw(t)&&xw(e)}function pw(e,t,n){return n(function(){gw(t)&&xw(e)})}function gw(e){var t=e.getSnapshot;e=e.value;try{var n=t();return!wn(e,n)}catch{return!0}}function xw(e){var t=or(e,1);t!==null&&vn(t,e,1,-1)}function Bg(e){var t=Pn();return typeof e=="function"&&(e=e()),t.memoizedState=t.baseState=e,e={pending:null,interleaved:null,lanes:0,dispatch:null,lastRenderedReducer:ya,lastRenderedState:e},t.queue=e,e=e.dispatch=O2.bind(null,Oe,e),[t.memoizedState,e]}function va(e,t,n,r){return e={tag:e,create:t,destroy:n,deps:r,next:null},t=Oe.updateQueue,t===null?(t={lastEffect:null,stores:null},Oe.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 yw(){return Qt().memoizedState}function Fl(e,t,n,r){var s=Pn();Oe.flags|=e,s.memoizedState=va(1|t,n,void 0,r===void 0?null:r)}function Xc(e,t,n,r){var s=Qt();r=r===void 0?null:r;var o=void 0;if(He!==null){var a=He.memoizedState;if(o=a.destroy,r!==null&&bm(r,a.deps)){s.memoizedState=va(t,n,o,r);return}}Oe.flags|=e,s.memoizedState=va(1|t,n,o,r)}function zg(e,t){return Fl(8390656,8,e,t)}function Nm(e,t){return Xc(2048,8,e,t)}function vw(e,t){return Xc(4,2,e,t)}function ww(e,t){return Xc(4,4,e,t)}function bw(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 Sw(e,t,n){return n=n!=null?n.concat([e]):null,Xc(4,4,bw.bind(null,t,e),n)}function Cm(){}function jw(e,t){var n=Qt();t=t===void 0?null:t;var r=n.memoizedState;return r!==null&&t!==null&&bm(t,r[1])?r[0]:(n.memoizedState=[e,t],e)}function Nw(e,t){var n=Qt();t=t===void 0?null:t;var r=n.memoizedState;return r!==null&&t!==null&&bm(t,r[1])?r[0]:(e=e(),n.memoizedState=[e,t],e)}function Cw(e,t,n){return _s&21?(wn(n,t)||(n=R0(),Oe.lanes|=n,Fs|=n,e.baseState=!0),t):(e.baseState&&(e.baseState=!1,Ct=!0),e.memoizedState=n)}function A2(e,t){var n=ve;ve=n!==0&&4>n?n:4,e(!0);var r=ld.transition;ld.transition={};try{e(!1),t()}finally{ve=n,ld.transition=r}}function kw(){return Qt().memoizedState}function M2(e,t,n){var r=Jr(e);if(n={lane:r,action:n,hasEagerState:!1,eagerState:null,next:null},Pw(e))Ew(t,n);else if(n=lw(e,t,n,r),n!==null){var s=yt();vn(n,e,r,s),Tw(n,t,r)}}function O2(e,t,n){var r=Jr(e),s={lane:r,action:n,hasEagerState:!1,eagerState:null,next:null};if(Pw(e))Ew(t,s);else{var o=e.alternate;if(e.lanes===0&&(o===null||o.lanes===0)&&(o=t.lastRenderedReducer,o!==null))try{var a=t.lastRenderedState,l=o(a,n);if(s.hasEagerState=!0,s.eagerState=l,wn(l,a)){var c=t.interleaved;c===null?(s.next=s,gm(t)):(s.next=c.next,c.next=s),t.interleaved=s;return}}catch{}finally{}n=lw(e,t,s,r),n!==null&&(s=yt(),vn(n,e,r,s),Tw(n,t,r))}}function Pw(e){var t=e.alternate;return e===Oe||t!==null&&t===Oe}function Ew(e,t){Gi=xc=!0;var n=e.pending;n===null?t.next=t:(t.next=n.next,n.next=t),e.pending=t}function Tw(e,t,n){if(n&4194240){var r=t.lanes;r&=e.pendingLanes,n|=r,t.lanes=n,nm(e,n)}}var yc={readContext:qt,useCallback:ot,useContext:ot,useEffect:ot,useImperativeHandle:ot,useInsertionEffect:ot,useLayoutEffect:ot,useMemo:ot,useReducer:ot,useRef:ot,useState:ot,useDebugValue:ot,useDeferredValue:ot,useTransition:ot,useMutableSource:ot,useSyncExternalStore:ot,useId:ot,unstable_isNewReconciler:!1},I2={readContext:qt,useCallback:function(e,t){return Pn().memoizedState=[e,t===void 0?null:t],e},useContext:qt,useEffect:zg,useImperativeHandle:function(e,t,n){return n=n!=null?n.concat([e]):null,Fl(4194308,4,bw.bind(null,t,e),n)},useLayoutEffect:function(e,t){return Fl(4194308,4,e,t)},useInsertionEffect:function(e,t){return Fl(4,2,e,t)},useMemo:function(e,t){var n=Pn();return t=t===void 0?null:t,e=e(),n.memoizedState=[e,t],e},useReducer:function(e,t,n){var r=Pn();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=M2.bind(null,Oe,e),[r.memoizedState,e]},useRef:function(e){var t=Pn();return e={current:e},t.memoizedState=e},useState:Bg,useDebugValue:Cm,useDeferredValue:function(e){return Pn().memoizedState=e},useTransition:function(){var e=Bg(!1),t=e[0];return e=A2.bind(null,e[1]),Pn().memoizedState=e,[t,e]},useMutableSource:function(){},useSyncExternalStore:function(e,t,n){var r=Oe,s=Pn();if(Te){if(n===void 0)throw Error(V(407));n=n()}else{if(n=t(),Qe===null)throw Error(V(349));_s&30||hw(r,t,n)}s.memoizedState=n;var o={value:n,getSnapshot:t};return s.queue=o,zg(pw.bind(null,r,o,e),[e]),r.flags|=2048,va(9,mw.bind(null,r,o,n,t),void 0,null),n},useId:function(){var e=Pn(),t=Qe.identifierPrefix;if(Te){var n=Zn,r=Jn;n=(r&~(1<<32-yn(r)-1)).toString(32)+n,t=":"+t+"R"+n,n=xa++,0<n&&(t+="H"+n.toString(32)),t+=":"}else n=R2++,t=":"+t+"r"+n.toString(32)+":";return e.memoizedState=t},unstable_isNewReconciler:!1},D2={readContext:qt,useCallback:jw,useContext:qt,useEffect:Nm,useImperativeHandle:Sw,useInsertionEffect:vw,useLayoutEffect:ww,useMemo:Nw,useReducer:cd,useRef
vendor: 4,528 bytes, lines 38-40
38:yw,useState:function(){return cd(ya)},useDebugValue:Cm,useDeferredValue:function(e){var t=Qt();return Cw(t,He.memoizedState,e)},useTransition:function(){var e=cd(ya)[0],t=Qt().memoizedState;return[e,t]},useMutableSource:dw,useSyncExternalStore:fw,useId:kw,unstable_isNewReconciler:!1},L2={readContext:qt,useCallback:jw,useContext:qt,useEffect:Nm,useImperativeHandle:Sw,useInsertionEffect:vw,useLayoutEffect:ww,useMemo:Nw,useReducer:ud,useRef:yw,useState:function(){return ud(ya)},useDebugValue:Cm,useDeferredValue:function(e){var t=Qt();return He===null?t.memoizedState=e:Cw(t,He.memoizedState,e)},useTransition:function(){var e=ud(ya)[0],t=Qt().memoizedState;return[e,t]},useMutableSource:dw,useSyncExternalStore:fw,useId:kw,unstable_isNewReconciler:!1};function un(e,t){if(e&&e.defaultProps){t=Ie({},t),e=e.defaultProps;for(var n in e)t[n]===void 0&&(t[n]=e[n]);return t}return t}function Mf(e,t,n,r){t=e.memoizedState,n=n(r,t),n=n==null?t:Ie({},t,n),e.memoizedState=n,e.lanes===0&&(e.updateQueue.baseState=n)}var Jc={isMounted:function(e){return(e=e._reactInternals)?Ys(e)===e:!1},enqueueSetState:function(e,t,n){e=e._reactInternals;var r=yt(),s=Jr(e),o=tr(r,s);o.payload=t,n!=null&&(o.callback=n),t=Qr(e,o,s),t!==null&&(vn(t,e,s,r),Ll(t,e,s))},enqueueReplaceState:function(e,t,n){e=e._reactInternals;var r=yt(),s=Jr(e),o=tr(r,s);o.tag=1,o.payload=t,n!=null&&(o.callback=n),t=Qr(e,o,s),t!==null&&(vn(t,e,s,r),Ll(t,e,s))},enqueueForceUpdate:function(e,t){e=e._reactInternals;var n=yt(),r=Jr(e),s=tr(n,r);s.tag=2,t!=null&&(s.callback=t),t=Qr(e,s,r),t!==null&&(vn(t,e,r,n),Ll(t,e,r))}};function Ug(e,t,n,r,s,o,a){return e=e.stateNode,typeof e.shouldComponentUpdate=="function"?e.shouldComponentUpdate(r,o,a):t.prototype&&t.prototype.isPureReactComponent?!da(n,r)||!da(s,o):!0}function Rw(e,t,n){var r=!1,s=ns,o=t.contextType;return typeof o=="object"&&o!==null?o=qt(o):(s=Pt(t)?Ds:ut.current,r=t.contextTypes,o=(r=r!=null)?Wo(e,s):ns),t=new t(n,o),e.memoizedState=t.state!==null&&t.state!==void 0?t.state:null,t.updater=Jc,e.stateNode=t,t._reactInternals=e,r&&(e=e.stateNode,e.__reactInternalMemoizedUnmaskedChildContext=s,e.__reactInternalMemoizedMaskedChildContext=o),t}function Wg(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&&Jc.enqueueReplaceState(t,t.state,null)}function Of(e,t,n,r){var s=e.stateNode;s.props=n,s.state=e.memoizedState,s.refs={},xm(e);var o=t.contextType;typeof o=="object"&&o!==null?s.context=qt(o):(o=Pt(t)?Ds:ut.current,s.context=Wo(e,o)),s.state=e.memoizedState,o=t.getDerivedStateFromProps,typeof o=="function"&&(Mf(e,t,o,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&&Jc.enqueueReplaceState(s,s.state,null),pc(e,n,s,r),s.state=e.memoizedState),typeof s.componentDidMount=="function"&&(e.flags|=4194308)}function Go(e,t){try{var n="",r=t;do n+=uk(r),r=r.return;while(r);var s=n}catch(o){s=`
39Error generating stack: `+o.message+`
40`+o.stack}return{value:e,source:t,stack:s,digest:null}}function dd(e,t,n){return{value:e,source:null,stack:n??null,digest:t??null}}function If(e,t){try{console.error(t.value)}catch(n){setTimeout(function(){throw n})}}var _2=typeof WeakMap=="function"?WeakMap:Map;function Aw(e,t,n){n=tr(-1,n),n.tag=3,n.payload={element:null};var r=t.value;return n.callback=function(){wc||(wc=!0,Wf=r),If(e,t)},n}function Mw(e,t,n){n=tr(-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(){If(e,t)}}var o=e.stateNode;return o!==null&&typeof o.componentDidCatch=="function"&&(n.callback=function(){If(e,t),typeof r!="function"&&(Xr===null?Xr=new Set([this]):Xr.add(this));var a=t.stack;this.componentDidCatch(t.value,{componentStack:a!==null?a:""})}),n}function Hg(e,t,n){var r=e.pingCache;if(r===null){r=e.pingCache=new _2;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=X2.bind(null,e,t,n),t.then(e,e))}function Kg(e){do{var t;if((t=e.tag===13)&&(t=e.memoizedState,t=t!==null?t.dehydrated!==null:!0),t)return e;e=e.return}while(e!==null);return null}
vendor: 10,061 bytes, line 40
40function Yg(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=tr(-1,1),t.tag=2,Qr(n,t,1))),n.lanes|=1),e)}var F2=fr.ReactCurrentOwner,Ct=!1;function ht(e,t,n,r){t.child=e===null?aw(t,null,n,r):Ko(t,e.child,n,r)}function Gg(e,t,n,r,s){n=n.render;var o=t.ref;return ko(t,s),r=Sm(e,t,n,r,o,s),n=jm(),e!==null&&!Ct?(t.updateQueue=e.updateQueue,t.flags&=-2053,e.lanes&=~s,ir(e,t,s)):(Te&&n&&um(t),t.flags|=1,ht(e,t,r,s),t.child)}function qg(e,t,n,r,s){if(e===null){var o=n.type;return typeof o=="function"&&!Om(o)&&o.defaultProps===void 0&&n.compare===null&&n.defaultProps===void 0?(t.tag=15,t.type=o,Ow(e,t,o,r,s)):(e=zl(n.type,null,r,t,t.mode,s),e.ref=t.ref,e.return=t,t.child=e)}if(o=e.child,!(e.lanes&s)){var a=o.memoizedProps;if(n=n.compare,n=n!==null?n:da,n(a,r)&&e.ref===t.ref)return ir(e,t,s)}return t.flags|=1,e=Zr(o,r),e.ref=t.ref,e.return=t,t.child=e}function Ow(e,t,n,r,s){if(e!==null){var o=e.memoizedProps;if(da(o,r)&&e.ref===t.ref)if(Ct=!1,t.pendingProps=r=o,(e.lanes&s)!==0)e.flags&131072&&(Ct=!0);else return t.lanes=e.lanes,ir(e,t,s)}return Df(e,t,n,r,s)}function Iw(e,t,n){var r=t.pendingProps,s=r.children,o=e!==null?e.memoizedState:null;if(r.mode==="hidden")if(!(t.mode&1))t.memoizedState={baseLanes:0,cachePool:null,transitions:null},je(go,Mt),Mt|=n;else{if(!(n&1073741824))return e=o!==null?o.baseLanes|n:n,t.lanes=t.childLanes=1073741824,t.memoizedState={baseLanes:e,cachePool:null,transitions:null},t.updateQueue=null,je(go,Mt),Mt|=e,null;t.memoizedState={baseLanes:0,cachePool:null,transitions:null},r=o!==null?o.baseLanes:n,je(go,Mt),Mt|=r}else o!==null?(r=o.baseLanes|n,t.memoizedState=null):r=n,je(go,Mt),Mt|=r;return ht(e,t,s,n),t.child}function Dw(e,t){var n=t.ref;(e===null&&n!==null||e!==null&&e.ref!==n)&&(t.flags|=512,t.flags|=2097152)}function Df(e,t,n,r,s){var o=Pt(n)?Ds:ut.current;return o=Wo(t,o),ko(t,s),n=Sm(e,t,n,r,o,s),r=jm(),e!==null&&!Ct?(t.updateQueue=e.updateQueue,t.flags&=-2053,e.lanes&=~s,ir(e,t,s)):(Te&&r&&um(t),t.flags|=1,ht(e,t,n,s),t.child)}function Qg(e,t,n,r,s){if(Pt(n)){var o=!0;uc(t)}else o=!1;if(ko(t,s),t.stateNode===null)Vl(e,t),Rw(t,n,r),Of(t,n,r,s),r=!0;else if(e===null){var a=t.stateNode,l=t.memoizedProps;a.props=l;var c=a.context,u=n.contextType;typeof u=="object"&&u!==null?u=qt(u):(u=Pt(n)?Ds:ut.current,u=Wo(t,u));var d=n.getDerivedStateFromProps,f=typeof d=="function"||typeof a.getSnapshotBeforeUpdate=="function";f||typeof a.UNSAFE_componentWillReceiveProps!="function"&&typeof a.componentWillReceiveProps!="function"||(l!==r||c!==u)&&Wg(t,a,r,u),Or=!1;var m=t.memoizedState;a.state=m,pc(t,r,a,s),c=t.memoizedState,l!==r||m!==c||kt.current||Or?(typeof d=="function"&&(Mf(t,n,d,r),c=t.memoizedState),(l=Or||Ug(t,n,l,r,m,c,u))?(f||typeof a.UNSAFE_componentWillMount!="function"&&typeof a.componentWillMount!="function"||(typeof a.componentWillMount=="function"&&a.componentWillMount(),typeof a.UNSAFE_componentWillMount=="function"&&a.UNSAFE_componentWillMount()),typeof a.componentDidMount=="function"&&(t.flags|=4194308)):(typeof a.componentDidMount=="function"&&(t.flags|=4194308),t.memoizedProps=r,t.memoizedState=c),a.props=r,a.state=c,a.context=u,r=l):(typeof a.componentDidMount=="function"&&(t.flags|=4194308),r=!1)}else{a=t.stateNode,cw(e,t),l=t.memoizedProps,u=t.type===t.elementType?l:un(t.type,l),a.props=u,f=t.pendingProps,m=a.context,c=n.contextType,typeof c=="object"&&c!==null?c=qt(c):(c=Pt(n)?Ds:ut.current,c=Wo(t,c));var p=n.getDerivedStateFromProps;(d=typeof p=="function"||typeof a.getSnapshotBeforeUpdate=="function")||typeof a.UNSAFE_componentWillReceiveProps!="function"&&typeof a.componentWillReceiveProps!="function"||(l!==f||m!==c)&&Wg(t,a,r,c),Or=!1,m=t.memoizedState,a.state=m,pc(t,r,a,s);var b=t.memoizedState;l!==f||m!==b||kt.current||Or?(typeof p=="function"&&(Mf(t,n,p,r),b=t.memoizedState),(u=Or||Ug(t,n,u,r,m,b,c)||!1)?(d||typeof a.UNSAFE_componentWillUpdate!="function"&&typeof a.componentWillUpdate!="function"||(typeof a.componentWillUpdate=="function"&&a.componentWillUpdate(r,b,c),typeof a.UNSAFE_componentWillUpdate=="function"&&a.UNSAFE_componentWillUpdate(r,b,c)),typeof a.componentDidUpdate=="function"&&(t.flags|=4),typeof a.getSnapshotBeforeUpdate=="function"&&(t.flags|=1024)):(typeof a.componentDidUpdate!="function"||l===e.memoizedProps&&m===e.memoizedState||(t.flags|=4),typeof a.getSnapshotBeforeUpdate!="function"||l===e.memoizedProps&&m===e.memoizedState||(t.flags|=1024),t.memoizedProps=r,t.memoizedState=b),a.props=r,a.state=b,a.context=c,r=u):(typeof a.componentDidUpdate!="function"||l===e.memoizedProps&&m===e.memoizedState||(t.flags|=4),typeof a.getSnapshotBeforeUpdate!="function"||l===e.memoizedProps&&m===e.memoizedState||(t.flags|=1024),r=!1)}return Lf(e,t,n,r,o,s)}function Lf(e,t,n,r,s,o){Dw(e,t);var a=(t.flags&128)!==0;if(!r&&!a)return s&&Dg(t,n,!1),ir(e,t,o);r=t.stateNode,F2.current=t;var l=a&&typeof n.getDerivedStateFromError!="function"?null:r.render();return t.flags|=1,e!==null&&a?(t.child=Ko(t,e.child,null,o),t.child=Ko(t,null,l,o)):ht(e,t,l,o),t.memoizedState=r.state,s&&Dg(t,n,!0),t.child}function Lw(e){var t=e.stateNode;t.pendingContext?Ig(e,t.pendingContext,t.pendingContext!==t.context):t.context&&Ig(e,t.context,!1),ym(e,t.containerInfo)}function Xg(e,t,n,r,s){return Ho(),fm(s),t.flags|=256,ht(e,t,n,r),t.child}var _f={dehydrated:null,treeContext:null,retryLane:0};function Ff(e){return{baseLanes:e,cachePool:null,transitions:null}}function _w(e,t,n){var r=t.pendingProps,s=Ae.current,o=!1,a=(t.flags&128)!==0,l;if((l=a)||(l=e!==null&&e.memoizedState===null?!1:(s&2)!==0),l?(o=!0,t.flags&=-129):(e===null||e.memoizedState!==null)&&(s|=1),je(Ae,s&1),e===null)return Rf(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):(a=r.children,e=r.fallback,o?(r=t.mode,o=t.child,a={mode:"hidden",children:a},!(r&1)&&o!==null?(o.childLanes=0,o.pendingProps=a):o=tu(a,r,0,null),e=Os(e,r,n,null),o.return=t,e.return=t,o.sibling=e,t.child=o,t.child.memoizedState=Ff(n),t.memoizedState=_f,e):km(t,a));if(s=e.memoizedState,s!==null&&(l=s.dehydrated,l!==null))return V2(e,t,a,r,l,s,n);if(o){o=r.fallback,a=t.mode,s=e.child,l=s.sibling;var c={mode:"hidden",children:r.children};return!(a&1)&&t.child!==s?(r=t.child,r.childLanes=0,r.pendingProps=c,t.deletions=null):(r=Zr(s,c),r.subtreeFlags=s.subtreeFlags&14680064),l!==null?o=Zr(l,o):(o=Os(o,a,n,null),o.flags|=2),o.return=t,r.return=t,r.sibling=o,t.child=r,r=o,o=t.child,a=e.child.memoizedState,a=a===null?Ff(n):{baseLanes:a.baseLanes|n,cachePool:null,transitions:a.transitions},o.memoizedState=a,o.childLanes=e.childLanes&~n,t.memoizedState=_f,r}return o=e.child,e=o.sibling,r=Zr(o,{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 km(e,t){return t=tu({mode:"visible",children:t},e.mode,0,null),t.return=e,e.child=t}function ul(e,t,n,r){return r!==null&&fm(r),Ko(t,e.child,null,n),e=km(t,t.pendingProps.children),e.flags|=2,t.memoizedState=null,e}function V2(e,t,n,r,s,o,a){if(n)return t.flags&256?(t.flags&=-257,r=dd(Error(V(422))),ul(e,t,a,r)):t.memoizedState!==null?(t.child=e.child,t.flags|=128,null):(o=r.fallback,s=t.mode,r=tu({mode:"visible",children:r.children},s,0,null),o=Os(o,s,a,null),o.flags|=2,r.return=t,o.return=t,r.sibling=o,t.child=r,t.mode&1&&Ko(t,e.child,null,a),t.child.memoizedState=Ff(a),t.memoizedState=_f,o);if(!(t.mode&1))return ul(e,t,a,null);if(s.data==="$!"){if(r=s.nextSibling&&s.nextSibling.dataset,r)var l=r.dgst;return r=l,o=Error(V(419)),r=dd(o,r,void 0),ul(e,t,a,r)}if(l=(a&e.childLanes)!==0,Ct||l){if(r=Qe,r!==null){switch(a&-a){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|a)?0:s,s!==0&&s!==o.retryLane&&(o.retryLane=s,or(e,s),vn(r,e,s,-1))}return Mm(),r=dd(Error(V(421))),ul(e,t,a,r)}return s.data==="$?"?(t.flags|=128,t.child=e.child,t=J2.bind(null,e),s._reactRetry=t,null):(e=o.treeContext,It=qr(s.nextSibling),Dt=t,Te=!0,pn=null,e!==null&&(Ut[Wt++]=Jn,Ut[Wt++]=Zn,Ut[Wt++]=Ls,Jn=e.id,Zn=e.overflow,Ls=t),t=km(t,r.children),t.flags|=4096,t)}function Jg(e,t,n){e.lanes|=t;var r=e.alternate;r!==null&&(r.lanes|=t),Af(e.return,t,n)}function fd(e,t,n,r,s){var o=e.memoizedState;o===null?e.memoizedState={isBackwards:t,rendering:null,renderingStartTime:0,last:r,tail:n,tailMode:s}:(o.isBackwards=t,o.rendering=null,o.renderingStartTime=0,o.last=r,o.tail=n,o.tailMode=s)}function Fw(e,t,n){var r=t.pendingProps,s=r.revealOrder,o=r.tail;if(ht(e,t,r.children,n),r=Ae.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&&Jg(e,n,t);else if(e.tag===19)Jg(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(je(Ae,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&&gc(e)===null&&(s=n),n=n.sibling;n=s,n===null?(s=t.child,t.child=null):(s=n.sibling,n.sibling=null),fd(t,!1,s,n,o);break;case"backwards":for(n=null,s=t.child,t.child=null;s!==null;){if(e=s.alternate,e!==null&&gc(e)===null){t.child=s;break}e=s.sibling,s.sibling=n,n=s,s=e}fd(t,!0,n,null,o);break;case"together":fd(t,!1,null,null,void 0);break;default:t.memoizedState=null}return t.child}function Vl(e,t){!(t.mode&1)&&e!==null&&(e.alternate=null,t.alternate=null,t.flags|=2)}function ir(e,t,n){if(e!==null&&(t.dependencies=e.dependencies),Fs|=t.lanes,!(n&t.childLanes))return null;if(e!==null&&t.child!==e.child)throw Error(V(153));
vendor: 5,451 bytes, line 40
40if(t.child!==null){for(e=t.child,n=Zr(e,e.pendingProps),t.child=n,n.return=t;e.sibling!==null;)e=e.sibling,n=n.sibling=Zr(e,e.pendingProps),n.return=t;n.sibling=null}return t.child}function $2(e,t,n){switch(t.tag){case 3:Lw(t),Ho();break;case 5:uw(t);break;case 1:Pt(t.type)&&uc(t);break;case 4:ym(t,t.stateNode.containerInfo);break;case 10:var r=t.type._context,s=t.memoizedProps.value;je(hc,r._currentValue),r._currentValue=s;break;case 13:if(r=t.memoizedState,r!==null)return r.dehydrated!==null?(je(Ae,Ae.current&1),t.flags|=128,null):n&t.child.childLanes?_w(e,t,n):(je(Ae,Ae.current&1),e=ir(e,t,n),e!==null?e.sibling:null);je(Ae,Ae.current&1);break;case 19:if(r=(n&t.childLanes)!==0,e.flags&128){if(r)return Fw(e,t,n);t.flags|=128}if(s=t.memoizedState,s!==null&&(s.rendering=null,s.tail=null,s.lastEffect=null),je(Ae,Ae.current),r)break;return null;case 22:case 23:return t.lanes=0,Iw(e,t,n)}return ir(e,t,n)}var Vw,Vf,$w,Bw;Vw=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}};Vf=function(){};$w=function(e,t,n,r){var s=e.memoizedProps;if(s!==r){e=t.stateNode,Ss(_n.current);var o=null;switch(n){case"input":s=af(e,s),r=af(e,r),o=[];break;case"select":s=Ie({},s,{value:void 0}),r=Ie({},r,{value:void 0}),o=[];break;case"textarea":s=uf(e,s),r=uf(e,r),o=[];break;default:typeof s.onClick!="function"&&typeof r.onClick=="function"&&(e.onclick=lc)}ff(n,r);var a;n=null;for(u in s)if(!r.hasOwnProperty(u)&&s.hasOwnProperty(u)&&s[u]!=null)if(u==="style"){var l=s[u];for(a in l)l.hasOwnProperty(a)&&(n||(n={}),n[a]="")}else u!=="dangerouslySetInnerHTML"&&u!=="children"&&u!=="suppressContentEditableWarning"&&u!=="suppressHydrationWarning"&&u!=="autoFocus"&&(sa.hasOwnProperty(u)?o||(o=[]):(o=o||[]).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(a in l)!l.hasOwnProperty(a)||c&&c.hasOwnProperty(a)||(n||(n={}),n[a]="");for(a in c)c.hasOwnProperty(a)&&l[a]!==c[a]&&(n||(n={}),n[a]=c[a])}else n||(o||(o=[]),o.push(u,n)),n=c;else u==="dangerouslySetInnerHTML"?(c=c?c.__html:void 0,l=l?l.__html:void 0,c!=null&&l!==c&&(o=o||[]).push(u,c)):u==="children"?typeof c!="string"&&typeof c!="number"||(o=o||[]).push(u,""+c):u!=="suppressContentEditableWarning"&&u!=="suppressHydrationWarning"&&(sa.hasOwnProperty(u)?(c!=null&&u==="onScroll"&&Ce("scroll",e),o||l===c||(o=[])):(o=o||[]).push(u,c))}n&&(o=o||[]).push("style",n);var u=o;(t.updateQueue=u)&&(t.flags|=4)}};Bw=function(e,t,n,r){n!==r&&(t.flags|=4)};function ki(e,t){if(!Te)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 it(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 B2(e,t,n){var r=t.pendingProps;switch(dm(t),t.tag){case 2:case 16:case 15:case 0:case 11:case 7:case 8:case 12:case 9:case 14:return it(t),null;case 1:return Pt(t.type)&&cc(),it(t),null;case 3:return r=t.stateNode,Yo(),ke(kt),ke(ut),wm(),r.pendingContext&&(r.context=r.pendingContext,r.pendingContext=null),(e===null||e.child===null)&&(ll(t)?t.flags|=4:e===null||e.memoizedState.isDehydrated&&!(t.flags&256)||(t.flags|=1024,pn!==null&&(Yf(pn),pn=null))),Vf(e,t),it(t),null;case 5:vm(t);var s=Ss(ga.current);if(n=t.type,e!==null&&t.stateNode!=null)$w(e,t,n,r,s),e.ref!==t.ref&&(t.flags|=512,t.flags|=2097152);else{if(!r){if(t.stateNode===null)throw Error(V(166));return it(t),null}if(e=Ss(_n.current),ll(t)){r=t.stateNode,n=t.type;var o=t.memoizedProps;switch(r[An]=t,r[ma]=o,e=(t.mode&1)!==0,n){case"dialog":Ce("cancel",r),Ce("close",r);break;case"iframe":case"object":case"embed":Ce("load",r);break;case"video":case"audio":for(s=0;s<Fi.length;s++)Ce(Fi[s],r);break;case"source":Ce("error",r);break;case"img":case"image":case"link":Ce("error",r),Ce("load",r);break;case"details":Ce("toggle",r);break;case"input":ag(r,o),Ce("invalid",r);break;case"select":r._wrapperState={wasMultiple:!!o.multiple},Ce("invalid",r);break;case"textarea":cg(r,o),Ce("invalid",r)}ff(n,o),s=null;for(var a in o)if(o.hasOwnProperty(a)){var l=o[a];a==="children"?typeof l=="string"?r.textContent!==l&&(o.suppressHydrationWarning!==!0&&al(r.textContent,l,e),s=["children",l]):typeof l=="number"&&r.textContent!==""+l&&(o.suppressHydrationWarning!==!0&&al(r.textContent,l,e),s=["children",""+l]):sa.hasOwnProperty(a)&&l!=null&&a==="onScroll"&&Ce("scroll",r)}switch(n){case"input":Za(r),lg(r,o,!0);break;case"textarea":Za(r),ug(r);break;case"select":case"option":break;default:typeof o.onClick=="function"&&(r.onclick=lc)}r=s,t.updateQueue=r,r!==null&&(t.flags|=4)}else{a=s.nodeType===9?s:s.ownerDocument,e==="http://www.w3.org/1999/xhtml"&&(e=p0(n)),e==="http://www.w3.org/1999/xhtml"?n==="script"?(e=a.createElement("div"),e.innerHTML="<script><\/script>
40",e=e.removeChild(e.firstChild)):typeof r.is=="string"?e=a.createElement(n,{is:r.is}):(e=a.createElement(n),n==="select"&&(a=e,r.multiple?a.multiple=!0:r.size&&(a.size=r.size))):e=a.createElementNS(e,n),e[An]=t,e[ma]=r,Vw(e,t,!1,!1),t.stateNode=e;e:{switch(a=hf(n,r),n){case"dialog":Ce("cancel",e),Ce("close",e),s=r;break;case"iframe":case"object":case"embed":Ce("load",e),s=r;break;case"video":case"audio":for(s=0;s<Fi.length;s++)Ce(Fi[s],e);s=r;break;case"source":Ce("error",e),s=r;break;case"img":case"image":case"link":Ce("error",e),Ce("load",e),s=r;break;case"details":Ce("toggle",e),s=r;break;case"input":ag(e,r),s=af(e,r),Ce("invalid",e);break;case"option":s=r;break;case"select":e._wrapperState={wasMultiple:!!r.multiple},s=Ie({},r,{value:void 0}),Ce("invalid",e);break;case"textarea":cg(e,r),s=uf(e,r),Ce("invalid",e);break;default:s=r}ff(n,s),l=s;for(o in l)if(l.hasOwnProperty(o)){var c=l[o];o==="style"?y0(e,c):o==="dangerouslySetInnerHTML"?(c=c?c.__html:void 0,c!=null&&g0(e,c)):o==="children"?typeof c=="string"?(n!=="textarea"||c!=="")&&oa(e,c):typeof c=="number"&&oa(e,""+c):o!=="suppressContentEditableWarning"&&o!=="suppressHydrationWarning"&&o!=="autoFocus"&&(sa.hasOwnProperty(o)?c!=null&&o==="onScroll"&&Ce("scroll",e):c!=null&&Qh(e,o,c,a))}switch(n){case"input":Za(e),lg(e,r,!1);break;case"textarea":Za(e),ug(e);break;case"option":r.value!=null&&e.setAttribute("value",""+ts(r.value));break;case"select":e.multiple=!!r.multiple,o=r.value,o!=null?So(e,!!r.multiple,o,!1):r.defaultValue!=null&&So(e,!!r.multiple,r.defaultValue,!0);break;default:typeof s.onClick=="function"&&(e.onclick=lc)}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 it(t),null;case 6:if(e&&t.stateNode!=null)Bw(e,t,e.memoizedProps,r);else{if(typeof r!="string"&&t.stateNode===null)throw Error(V(166));if(n=Ss(ga.current),Ss(_n.current),ll(t)){if(r=t.stateNode,n=t.memoizedProps,r[An]=t,(o=r.nodeValue!==n)&&(e=Dt,e!==null))switch(e.tag){case 3:al(r.nodeValue,n,(e.mode&1)!==0);break;case 5:e.memoizedProps.suppressHydrationWarning!==!0&&al(r.nodeValue,n,(e.mode&1)!==0)}o&&(t.flags|=4)}else r=(n.nodeType===9?n:n.ownerDocument).createTextNode(r),r[An]=t,t.stateNode=r}return it(t),null;case 13:if(ke(Ae),r=t.memoizedState,e===null||e.memoizedState!==null&&e.memoizedState.dehydrated!==null){if(Te&&It!==null&&t.mode&1&&!(t.flags&128))ow(),Ho(),t.flags|=98560,o=!1;else if(o=ll(t),r!==null&&r.dehydrated!==null){if(e===null){if(!o)throw Error(V(318));if(o=t.memoizedState,o=o!==null?o.dehydrated:null,!o)throw Error(V(317));o[An]=t}else Ho(),!(t.flags&128)&&(t.memoizedState=null),t.flags|=4;it(t),o=!1}else pn!==null&&(Yf(pn),pn=null),o=!0;if(!o)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||Ae.current&1?Ye===0&&(Ye=3):Mm())),t.updateQueue!==null&&(t.flags|=4),it(t),null);case 4:return Yo(),Vf(e,t),e===null&&fa(t.stateNode.containerInfo),it(t),null;case 10:return pm(t.type._context),it(t),null;case 17:return Pt(t.type)&&cc(),it(t),null;case 19:if(ke(Ae),o=t.memoizedState,o===null)return it(t),null;if(r=(t.flags&128)!==0,a=o.rendering,a===null)if(r)ki(o,!1);else{if(Ye!==0||e!==null&&e.flags&128)for(e=t.child;e!==null;){if(a=gc(e),a!==null){for(t.flags|=128,ki(o,!1),r=a.updateQueue,r!==null&&(t.updateQueue=r,t.flags|=4),t.subtreeFlags=0,r=n,n=t.child;n!==null;)o=n,e=r,o.flags&=14680066,a=o.alternate,a===null?(o.childLanes=0,o.lanes=e,o.child=null,o.subtreeFlags=0,o.memoizedProps=null,o.memoizedState=null,o.updateQueue=null,o.dependencies=null,o.stateNode=null):(o.childLanes=a.childLanes,o.lanes=a.lanes,o.child=a.child,o.subtreeFlags=0,o.deletions=null,o.memoizedProps=a.memoizedProps,o.memoizedState=a.memoizedState,o.updateQueue=a.updateQueue,o.type=a.type,e=a.dependencies,o.dependencies=e===null?null:{lanes:e.lanes,firstContext:e.firstContext}),n=n.sibling;return je(Ae,Ae.current&1|2),t.child}e=e.sibling}o.tail!==null&&Ve()>qo&&(t.flags|=128,r=!0,ki(o,!1),t.lanes=4194304)}else{if(!r)if(e=gc(a),e!==null){if(t.flags|=128,r=!0,n=e.updateQueue,n!==null&&(t.updateQueue=n,t.flags|=4),ki(o,!0),o.tail===null&&o.tailMode==="hidden"&&!a.alternate&&!Te)return it(t),null}else 2*Ve()-o.renderingStartTime>qo&&n!==1073741824&&(t.flags|=128,r=!0,ki(o,!1),t.lanes=4194304);o.isBackwards?(a.sibling=t.child,t.child=a):(n=o.last,n!==null?n.sibling=a:t.child=a,o.last=a)}return o.tail!==null?(t=o.tail,o.rendering=t,o.tail=t.sibling,o.renderingStartTime=Ve(),t.sibling=null,n=Ae.current,je(Ae,r?n&1|2:n&1),t):(it(t),null);case 22:case 23:return Am(),r=t.memoizedState!==null,e!==null&&e.memoizedState!==null!==r&&(t.flags|=8192),r&&t.mode&1?Mt&1073741824&&(it(t),t.subtreeFlags&6&&(t.flags|=8192)):it(t),null;case 24:return null;case 25:return null}throw Error(V(156,t.tag))}function z2(e,t){switch(dm(t),t.tag){case 1:return Pt(t.type)&&cc(),e=t.flags,e&65536?(t.flags=e&-65537|128,t):null;
vendor: 25,943 bytes, line 40
40case 3:return Yo(),ke(kt),ke(ut),wm(),e=t.flags,e&65536&&!(e&128)?(t.flags=e&-65537|128,t):null;case 5:return vm(t),null;case 13:if(ke(Ae),e=t.memoizedState,e!==null&&e.dehydrated!==null){if(t.alternate===null)throw Error(V(340));Ho()}return e=t.flags,e&65536?(t.flags=e&-65537|128,t):null;case 19:return ke(Ae),null;case 4:return Yo(),null;case 10:return pm(t.type._context),null;case 22:case 23:return Am(),null;case 24:return null;default:return null}}var dl=!1,lt=!1,U2=typeof WeakSet=="function"?WeakSet:Set,q=null;function po(e,t){var n=e.ref;if(n!==null)if(typeof n=="function")try{n(null)}catch(r){Fe(e,t,r)}else n.current=null}function $f(e,t,n){try{n()}catch(r){Fe(e,t,r)}}var Zg=!1;function W2(e,t){if(jf=oc,e=K0(),cm(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,o=r.focusNode;r=r.focusOffset;try{n.nodeType,o.nodeType}catch{n=null;break e}var a=0,l=-1,c=-1,u=0,d=0,f=e,m=null;t:for(;;){for(var p;f!==n||s!==0&&f.nodeType!==3||(l=a+s),f!==o||r!==0&&f.nodeType!==3||(c=a+r),f.nodeType===3&&(a+=f.nodeValue.length),(p=f.firstChild)!==null;)m=f,f=p;for(;;){if(f===e)break t;if(m===n&&++u===s&&(l=a),m===o&&++d===r&&(c=a),(p=f.nextSibling)!==null)break;f=m,m=f.parentNode}f=p}n=l===-1||c===-1?null:{start:l,end:c}}else n=null}n=n||{start:0,end:0}}else n=null;for(Nf={focusedElem:e,selectionRange:n},oc=!1,q=t;q!==null;)if(t=q,e=t.child,(t.subtreeFlags&1028)!==0&&e!==null)e.return=t,q=e;else for(;q!==null;){t=q;try{var b=t.alternate;if(t.flags&1024)switch(t.tag){case 0:case 11:case 15:break;case 1:if(b!==null){var x=b.memoizedProps,y=b.memoizedState,w=t.stateNode,g=w.getSnapshotBeforeUpdate(t.elementType===t.type?x:un(t.type,x),y);w.__reactInternalSnapshotBeforeUpdate=g}break;case 3:var v=t.stateNode.containerInfo;v.nodeType===1?v.textContent="":v.nodeType===9&&v.documentElement&&v.removeChild(v.documentElement);break;case 5:case 6:case 4:case 17:break;default:throw Error(V(163))}}catch(S){Fe(t,t.return,S)}if(e=t.sibling,e!==null){e.return=t.return,q=e;break}q=t.return}return b=Zg,Zg=!1,b}function qi(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 o=s.destroy;s.destroy=void 0,o!==void 0&&$f(t,n,o)}s=s.next}while(s!==r)}}function Zc(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 Bf(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 zw(e){var t=e.alternate;t!==null&&(e.alternate=null,zw(t)),e.child=null,e.deletions=null,e.sibling=null,e.tag===5&&(t=e.stateNode,t!==null&&(delete t[An],delete t[ma],delete t[Pf],delete t[k2],delete t[P2])),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 Uw(e){return e.tag===5||e.tag===3||e.tag===4}function ex(e){e:for(;;){for(;e.sibling===null;){if(e.return===null||Uw(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 zf(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=lc));else if(r!==4&&(e=e.child,e!==null))for(zf(e,t,n),e=e.sibling;e!==null;)zf(e,t,n),e=e.sibling}function Uf(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(Uf(e,t,n),e=e.sibling;e!==null;)Uf(e,t,n),e=e.sibling}var Ze=null,mn=!1;function Nr(e,t,n){for(n=n.child;n!==null;)Ww(e,t,n),n=n.sibling}function Ww(e,t,n){if(Ln&&typeof Ln.onCommitFiberUnmount=="function")try{Ln.onCommitFiberUnmount(Hc,n)}catch{}switch(n.tag){case 5:lt||po(n,t);case 6:var r=Ze,s=mn;Ze=null,Nr(e,t,n),Ze=r,mn=s,Ze!==null&&(mn?(e=Ze,n=n.stateNode,e.nodeType===8?e.parentNode.removeChild(n):e.removeChild(n)):Ze.removeChild(n.stateNode));break;case 18:Ze!==null&&(mn?(e=Ze,n=n.stateNode,e.nodeType===8?od(e.parentNode,n):e.nodeType===1&&od(e,n),ca(e)):od(Ze,n.stateNode));break;case 4:r=Ze,s=mn,Ze=n.stateNode.containerInfo,mn=!0,Nr(e,t,n),Ze=r,mn=s;break;case 0:case 11:case 14:case 15:if(!lt&&(r=n.updateQueue,r!==null&&(r=r.lastEffect,r!==null))){s=r=r.next;do{var o=s,a=o.destroy;o=o.tag,a!==void 0&&(o&2||o&4)&&$f(n,t,a),s=s.next}while(s!==r)}Nr(e,t,n);break;case 1:if(!lt&&(po(n,t),r=n.stateNode,typeof r.componentWillUnmount=="function"))try{r.props=n.memoizedProps,r.state=n.memoizedState,r.componentWillUnmount()}catch(l){Fe(n,t,l)}Nr(e,t,n);break;case 21:Nr(e,t,n);break;case 22:n.mode&1?(lt=(r=lt)||n.memoizedState!==null,Nr(e,t,n),lt=r):Nr(e,t,n);break;default:Nr(e,t,n)}}function tx(e){var t=e.updateQueue;if(t!==null){e.updateQueue=null;var n=e.stateNode;n===null&&(n=e.stateNode=new U2),t.forEach(function(r){var s=Z2.bind(null,e,r);n.has(r)||(n.add(r),r.then(s,s))})}}function sn(e,t){var n=t.deletions;if(n!==null)for(var r=0;r<n.length;r++){var s=n[r];try{var o=e,a=t,l=a;e:for(;l!==null;){switch(l.tag){case 5:Ze=l.stateNode,mn=!1;break e;case 3:Ze=l.stateNode.containerInfo,mn=!0;break e;case 4:Ze=l.stateNode.containerInfo,mn=!0;break e}l=l.return}if(Ze===null)throw Error(V(160));Ww(o,a,s),Ze=null,mn=!1;var c=s.alternate;c!==null&&(c.return=null),s.return=null}catch(u){Fe(s,t,u)}}if(t.subtreeFlags&12854)for(t=t.child;t!==null;)Hw(t,e),t=t.sibling}function Hw(e,t){var n=e.alternate,r=e.flags;switch(e.tag){case 0:case 11:case 14:case 15:if(sn(t,e),kn(e),r&4){try{qi(3,e,e.return),Zc(3,e)}catch(x){Fe(e,e.return,x)}try{qi(5,e,e.return)}catch(x){Fe(e,e.return,x)}}break;case 1:sn(t,e),kn(e),r&512&&n!==null&&po(n,n.return);break;case 5:if(sn(t,e),kn(e),r&512&&n!==null&&po(n,n.return),e.flags&32){var s=e.stateNode;try{oa(s,"")}catch(x){Fe(e,e.return,x)}}if(r&4&&(s=e.stateNode,s!=null)){var o=e.memoizedProps,a=n!==null?n.memoizedProps:o,l=e.type,c=e.updateQueue;if(e.updateQueue=null,c!==null)try{l==="input"&&o.type==="radio"&&o.name!=null&&h0(s,o),hf(l,a);var u=hf(l,o);for(a=0;a<c.length;a+=2){var d=c[a],f=c[a+1];d==="style"?y0(s,f):d==="dangerouslySetInnerHTML"?g0(s,f):d==="children"?oa(s,f):Qh(s,d,f,u)}switch(l){case"input":lf(s,o);break;case"textarea":m0(s,o);break;case"select":var m=s._wrapperState.wasMultiple;s._wrapperState.wasMultiple=!!o.multiple;var p=o.value;p!=null?So(s,!!o.multiple,p,!1):m!==!!o.multiple&&(o.defaultValue!=null?So(s,!!o.multiple,o.defaultValue,!0):So(s,!!o.multiple,o.multiple?[]:"",!1))}s[ma]=o}catch(x){Fe(e,e.return,x)}}break;case 6:if(sn(t,e),kn(e),r&4){if(e.stateNode===null)throw Error(V(162));s=e.stateNode,o=e.memoizedProps;try{s.nodeValue=o}catch(x){Fe(e,e.return,x)}}break;case 3:if(sn(t,e),kn(e),r&4&&n!==null&&n.memoizedState.isDehydrated)try{ca(t.containerInfo)}catch(x){Fe(e,e.return,x)}break;case 4:sn(t,e),kn(e);break;case 13:sn(t,e),kn(e),s=e.child,s.flags&8192&&(o=s.memoizedState!==null,s.stateNode.isHidden=o,!o||s.alternate!==null&&s.alternate.memoizedState!==null||(Tm=Ve())),r&4&&tx(e);break;case 22:if(d=n!==null&&n.memoizedState!==null,e.mode&1?(lt=(u=lt)||d,sn(t,e),lt=u):sn(t,e),kn(e),r&8192){if(u=e.memoizedState!==null,(e.stateNode.isHidden=u)&&!d&&e.mode&1)for(q=e,d=e.child;d!==null;){for(f=q=d;q!==null;){switch(m=q,p=m.child,m.tag){case 0:case 11:case 14:case 15:qi(4,m,m.return);break;case 1:po(m,m.return);var b=m.stateNode;if(typeof b.componentWillUnmount=="function"){r=m,n=m.return;try{t=r,b.props=t.memoizedProps,b.state=t.memoizedState,b.componentWillUnmount()}catch(x){Fe(r,n,x)}}break;case 5:po(m,m.return);break;case 22:if(m.memoizedState!==null){rx(f);continue}}p!==null?(p.return=m,q=p):rx(f)}d=d.sibling}e:for(d=null,f=e;;){if(f.tag===5){if(d===null){d=f;try{s=f.stateNode,u?(o=s.style,typeof o.setProperty=="function"?o.setProperty("display","none","important"):o.display="none"):(l=f.stateNode,c=f.memoizedProps.style,a=c!=null&&c.hasOwnProperty("display")?c.display:null,l.style.display=x0("display",a))}catch(x){Fe(e,e.return,x)}}}else if(f.tag===6){if(d===null)try{f.stateNode.nodeValue=u?"":f.memoizedProps}catch(x){Fe(e,e.return,x)}}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:sn(t,e),kn(e),r&4&&tx(e);break;case 21:break;default:sn(t,e),kn(e)}}function kn(e){var t=e.flags;if(t&2){try{e:{for(var n=e.return;n!==null;){if(Uw(n)){var r=n;break e}n=n.return}throw Error(V(160))}switch(r.tag){case 5:var s=r.stateNode;r.flags&32&&(oa(s,""),r.flags&=-33);var o=ex(e);Uf(e,o,s);break;case 3:case 4:var a=r.stateNode.containerInfo,l=ex(e);zf(e,l,a);break;default:throw Error(V(161))}}catch(c){Fe(e,e.return,c)}e.flags&=-3}t&4096&&(e.flags&=-4097)}function H2(e,t,n){q=e,Kw(e)}function Kw(e,t,n){for(var r=(e.mode&1)!==0;q!==null;){var s=q,o=s.child;if(s.tag===22&&r){var a=s.memoizedState!==null||dl;if(!a){var l=s.alternate,c=l!==null&&l.memoizedState!==null||lt;l=dl;var u=lt;if(dl=a,(lt=c)&&!u)for(q=s;q!==null;)a=q,c=a.child,a.tag===22&&a.memoizedState!==null?sx(s):c!==null?(c.return=a,q=c):sx(s);for(;o!==null;)q=o,Kw(o),o=o.sibling;q=s,dl=l,lt=u}nx(e)}else s.subtreeFlags&8772&&o!==null?(o.return=s,q=o):nx(e)}}function nx(e){for(;q!==null;){var t=q;if(t.flags&8772){var n=t.alternate;try{if(t.flags&8772)switch(t.tag){case 0:case 11:case 15:lt||Zc(5,t);break;case 1:var r=t.stateNode;if(t.flags&4&&!lt)if(n===null)r.componentDidMount();else{var s=t.elementType===t.type?n.memoizedProps:un(t.type,n.memoizedProps);r.componentDidUpdate(s,n.memoizedState,r.__reactInternalSnapshotBeforeUpdate)}var o=t.updateQueue;o!==null&&$g(t,o,r);break;case 3:var a=t.updateQueue;if(a!==null){if(n=null,t.child!==null)switch(t.child.tag){case 5:n=t.child.stateNode;break;case 1:n=t.child.stateNode}$g(t,a,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&&ca(f)}}}break;case 19:case 17:case 21:case 22:case 23:case 25:break;default:throw Error(V(163))}lt||t.flags&512&&Bf(t)}catch(m){Fe(t,t.return,m)}}if(t===e){q=null;break}if(n=t.sibling,n!==null){n.return=t.return,q=n;break}q=t.return}}function rx(e){for(;q!==null;){var t=q;if(t===e){q=null;break}var n=t.sibling;if(n!==null){n.return=t.return,q=n;break}q=t.return}}function sx(e){for(;q!==null;){var t=q;try{switch(t.tag){case 0:case 11:case 15:var n=t.return;try{Zc(4,t)}catch(c){Fe(t,n,c)}break;case 1:var r=t.stateNode;if(typeof r.componentDidMount=="function"){var s=t.return;try{r.componentDidMount()}catch(c){Fe(t,s,c)}}var o=t.return;try{Bf(t)}catch(c){Fe(t,o,c)}break;case 5:var a=t.return;try{Bf(t)}catch(c){Fe(t,a,c)}}}catch(c){Fe(t,t.return,c)}if(t===e){q=null;break}var l=t.sibling;if(l!==null){l.return=t.return,q=l;break}q=t.return}}var K2=Math.ceil,vc=fr.ReactCurrentDispatcher,Pm=fr.ReactCurrentOwner,Yt=fr.ReactCurrentBatchConfig,me=0,Qe=null,Ue=null,tt=0,Mt=0,go=ls(0),Ye=0,wa=null,Fs=0,eu=0,Em=0,Qi=null,Nt=null,Tm=0,qo=1/0,qn=null,wc=!1,Wf=null,Xr=null,fl=!1,Ur=null,bc=0,Xi=0,Hf=null,$l=-1,Bl=0;function yt(){return me&6?Ve():$l!==-1?$l:$l=Ve()}function Jr(e){return e.mode&1?me&2&&tt!==0?tt&-tt:T2.transition!==null?(Bl===0&&(Bl=R0()),Bl):(e=ve,e!==0||(e=window.event,e=e===void 0?16:_0(e.type)),e):1}function vn(e,t,n,r){if(50<Xi)throw Xi=0,Hf=null,Error(V(185));Fa(e,n,r),(!(me&2)||e!==Qe)&&(e===Qe&&(!(me&2)&&(eu|=n),Ye===4&&Lr(e,tt)),Et(e,r),n===1&&me===0&&!(t.mode&1)&&(qo=Ve()+500,Qc&&cs()))}function Et(e,t){var n=e.callbackNode;Tk(e,t);var r=sc(e,e===Qe?tt:0);if(r===0)n!==null&&hg(n),e.callbackNode=null,e.callbackPriority=0;else if(t=r&-r,e.callbackPriority!==t){if(n!=null&&hg(n),t===1)e.tag===0?E2(ox.bind(null,e)):nw(ox.bind(null,e)),N2(function(){!(me&6)&&cs()}),n=null;else{switch(A0(r)){case 1:n=tm;break;case 4:n=E0;break;case 16:n=rc;break;case 536870912:n=T0;break;default:n=rc}n=eb(n,Yw.bind(null,e))}e.callbackPriority=t,e.callbackNode=n}}function Yw(e,t){if($l=-1,Bl=0,me&6)throw Error(V(327));var n=e.callbackNode;if(Po()&&e.callbackNode!==n)return null;var r=sc(e,e===Qe?tt:0);if(r===0)return null;if(r&30||r&e.expiredLanes||t)t=Sc(e,r);else{t=r;var s=me;me|=2;var o=qw();(Qe!==e||tt!==t)&&(qn=null,qo=Ve()+500,Ms(e,t));do try{q2();break}catch(l){Gw(e,l)}while(!0);mm(),vc.current=o,me=s,Ue!==null?t=0:(Qe=null,tt=0,t=Ye)}if(t!==0){if(t===2&&(s=yf(e),s!==0&&(r=s,t=Kf(e,s))),t===1)throw n=wa,Ms(e,0),Lr(e,r),Et(e,Ve()),n;if(t===6)Lr(e,r);else{if(s=e.current.alternate,!(r&30)&&!Y2(s)&&(t=Sc(e,r),t===2&&(o=yf(e),o!==0&&(r=o,t=Kf(e,o))),t===1))throw n=wa,Ms(e,0),Lr(e,r),Et(e,Ve()),n;switch(e.finishedWork=s,e.finishedLanes=r,t){case 0:case 1:throw Error(V(345));case 2:xs(e,Nt,qn);break;case 3:if(Lr(e,r),(r&130023424)===r&&(t=Tm+500-Ve(),10<t)){if(sc(e,0)!==0)break;if(s=e.suspendedLanes,(s&r)!==r){yt(),e.pingedLanes|=e.suspendedLanes&s;break}e.timeoutHandle=kf(xs.bind(null,e,Nt,qn),t);break}xs(e,Nt,qn);break;case 4:if(Lr(e,r),(r&4194240)===r)break;for(t=e.eventTimes,s=-1;0<r;){var a=31-yn(r);o=1<<a,a=t[a],a>s&&(s=a),r&=~o}if(r=s,r=Ve()-r,r=(120>r?120:480>r?480:1080>r?1080:1920>r?1920:3e3>r?3e3:4320>r?4320:1960*K2(r/1960))-r,10<r){e.timeoutHandle=kf(xs.bind(null,e,Nt,qn),r);break}xs(e,Nt,qn);break;case 5:xs(e,Nt,qn);break;default:throw Error(V(329))}}}return Et(e,Ve()),e.callbackNode===n?Yw.bind(null,e):null}function Kf(e,t){var n=Qi;return e.current.memoizedState.isDehydrated&&(Ms(e,t).flags|=256),e=Sc(e,t),e!==2&&(t=Nt,Nt=n,t!==null&&Yf(t)),e}function Yf(e){Nt===null?Nt=e:Nt.push.apply(Nt,e)}function Y2(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],o=s.getSnapshot;s=s.value;try{if(!wn(o(),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 Lr(e,t){for(t&=~Em,t&=~eu,e.suspendedLanes|=t,e.pingedLanes&=~t,e=e.expirationTimes;0<t;){var n=31-yn(t),r=1<<n;e[n]=-1,t&=~r}}function ox(e){if(me&6)throw Error(V(327));Po();var t=sc(e,0);if(!(t&1))return Et(e,Ve()),null;var n=Sc(e,t);if(e.tag!==0&&n===2){var r=yf(e);r!==0&&(t=r,n=Kf(e,r))}if(n===1)throw n=wa,Ms(e,0),Lr(e,t),Et(e,Ve()),n;if(n===6)throw Error(V(345));return e.finishedWork=e.current.alternate,e.finishedLanes=t,xs(e,Nt,qn),Et(e,Ve()),null}function Rm(e,t){var n=me;me|=1;try{return e(t)}finally{me=n,me===0&&(qo=Ve()+500,Qc&&cs())}}function Vs(e){Ur!==null&&Ur.tag===0&&!(me&6)&&Po();var t=me;me|=1;var n=Yt.transition,r=ve;try{if(Yt.transition=null,ve=1,e)return e()}finally{ve=r,Yt.transition=n,me=t,!(me&6)&&cs()}}function Am(){Mt=go.current,ke(go)}function Ms(e,t){e.finishedWork=null,e.finishedLanes=0;var n=e.timeoutHandle;if(n!==-1&&(e.timeoutHandle=-1,j2(n)),Ue!==null)for(n=Ue.return;n!==null;){var r=n;switch(dm(r),r.tag){case 1:r=r.type.childContextTypes,r!=null&&cc();break;case 3:Yo(),ke(kt),ke(ut),wm();break;case 5:vm(r);break;case 4:Yo();break;case 13:ke(Ae);break;case 19:ke(Ae);break;case 10:pm(r.type._context);break;case 22:case 23:Am()}n=n.return}if(Qe=e,Ue=e=Zr(e.current,null),tt=Mt=t,Ye=0,wa=null,Em=eu=Fs=0,Nt=Qi=null,bs!==null){for(t=0;t<bs.length;t++)if(n=bs[t],r=n.interleaved,r!==null){n.interleaved=null;var s=r.next,o=n.pending;if(o!==null){var a=o.next;o.next=s,r.next=a}n.pending=r}bs=null}return e}function Gw(e,t){do{var n=Ue;try{if(mm(),_l.current=yc,xc){for(var r=Oe.memoizedState;r!==null;){var s=r.queue;s!==null&&(s.pending=null),r=r.next}xc=!1}if(_s=0,qe=He=Oe=null,Gi=!1,xa=0,Pm.current=null,n===null||n.return===null){Ye=1,wa=t,Ue=null;break}e:{var o=e,a=n.return,l=n,c=t;if(t=tt,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 m=d.alternate;m?(d.updateQueue=m.updateQueue,d.memoizedState=m.memoizedState,d.lanes=m.lanes):(d.updateQueue=null,d.memoizedState=null)}var p=Kg(a);if(p!==null){p.flags&=-257,Yg(p,a,l,o,t),p.mode&1&&Hg(o,u,t),t=p,c=u;var b=t.updateQueue;if(b===null){var x=new Set;x.add(c),t.updateQueue=x}else b.add(c);break e}else{if(!(t&1)){Hg(o,u,t),Mm();break e}c=Error(V(426))}}else if(Te&&l.mode&1){var y=Kg(a);if(y!==null){!(y.flags&65536)&&(y.flags|=256),Yg(y,a,l,o,t),fm(Go(c,l));break e}}o=c=Go(c,l),Ye!==4&&(Ye=2),Qi===null?Qi=[o]:Qi.push(o),o=a;do{switch(o.tag){case 3:o.flags|=65536,t&=-t,o.lanes|=t;var w=Aw(o,c,t);Vg(o,w);break e;case 1:l=c;var g=o.type,v=o.stateNode;if(!(o.flags&128)&&(typeof g.getDerivedStateFromError=="function"||v!==null&&typeof v.componentDidCatch=="function"&&(Xr===null||!Xr.has(v)))){o.flags|=65536,t&=-t,o.lanes|=t;var S=Mw(o,l,t);Vg(o,S);break e}}o=o.return}while(o!==null)}Xw(n)}catch(j){t=j,Ue===n&&n!==null&&(Ue=n=n.return);continue}break}while(!0)}function qw(){var e=vc.current;return vc.current=yc,e===null?yc:e}function Mm(){(Ye===0||Ye===3||Ye===2)&&(Ye=4),Qe===null||!(Fs&268435455)&&!(eu&268435455)||Lr(Qe,tt)}function Sc(e,t){var n=me;me|=2;var r=qw();(Qe!==e||tt!==t)&&(qn=null,Ms(e,t));do try{G2();break}catch(s){Gw(e,s)}while(!0);if(mm(),me=n,vc.current=r,Ue!==null)throw Error(V(261));return Qe=null,tt=0,Ye}function G2(){for(;Ue!==null;)Qw(Ue)}function q2(){for(;Ue!==null&&!wk();)Qw(Ue)}function Qw(e){var t=Zw(e.alternate,e,Mt);e.memoizedProps=e.pendingProps,t===null?Xw(e):Ue=t,Pm.current=null}function Xw(e){var t=e;do{var n=t.alternate;if(e=t.return,t.flags&32768){if(n=z2(n,t),n!==null){n.flags&=32767,Ue=n;return}if(e!==null)e.flags|=32768,e.subtreeFlags=0,e.deletions=null;else{Ye=6,Ue=null;return}}else if(n=B2(n,t,Mt),n!==null){Ue=n;return}if(t=t.sibling,t!==null){Ue=t;return}Ue=t=e}while(t!==null);Ye===0&&(Ye=5)}function xs(e,t,n){var r=ve,s=Yt.transition;try{Yt.transition=null,ve=1,Q2(e,t,n,r)}finally{Yt.transition=s,ve=r}return null}function Q2(e,t,n,r){do Po();while(Ur!==null);if(me&6)throw Error(V(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(V(177));e.callbackNode=null,e.callbackPriority=0;var o=n.lanes|n.childLanes;if(Rk(e,o),e===Qe&&(Ue=Qe=null,tt=0),!(n.subtreeFlags&2064)&&!(n.flags&2064)||fl||(fl=!0,eb(rc,function(){return Po(),null})),o=(n.flags&15990)!==0,n.subtreeFlags&15990||o){o=Yt.transition,Yt.transition=null;var a=ve;ve=1;var l=me;me|=4,Pm.current=null,W2(e,n),Hw(n,e),g2(Nf),oc=!!jf,Nf=jf=null,e.current=n,H2(n),bk(),me=l,ve=a,Yt.transition=o}else e.current=n;if(fl&&(fl=!1,Ur=e,bc=s),o=e.pendingLanes,o===0&&(Xr=null),Nk(n.stateNode),Et(e,Ve()),t!==null)for(r=e.onRecoverableError,n=0;n<t.length;n++)s=t[n],r(s.value,{componentStack:s.stack,digest:s.digest});if(wc)throw wc=!1,e=Wf,Wf=null,e;return bc&1&&e.tag!==0&&Po(),o=e.pendingLanes,o&1?e===Hf?Xi++:(Xi=0,Hf=e):Xi=0,cs(),null}function Po(){if(Ur!==null){var e=A0(bc),t=Yt.transition,n=ve;try{if(Yt.transition=null,ve=16>e?16:e,Ur===null)var r=!1;else{if(e=Ur,Ur=null,bc=0,me&6)throw Error(V(331));var s=me;for(me|=4,q=e.current;q!==null;){var o=q,a=o.child;if(q.flags&16){var l=o.deletions;if(l!==null){for(var c=0;c<l.length;c++){var u=l[c];for(q=u;q!==null;){var d=q;switch(d.tag){case 0:case 11:case 15:qi(8,d,o)}var f=d.child;if(f!==null)f.return=d,q=f;else for(;q!==null;){d=q;var m=d.sibling,p=d.return;if(zw(d),d===u){q=null;break}if(m!==null){m.return=p,q=m;break}q=p}}}var b=o.alternate;if(b!==null){var x=b.child;if(x!==null){b.child=null;do{var y=x.sibling;x.sibling=null,x=y}while(x!==null)}}q=o}}if(o.subtreeFlags&2064&&a!==null)a.return=o,q=a;else e:for(;q!==null;){if(o=q,o.flags&2048)switch(o.tag){case 0:case 11:case 15:qi(9,o,o.return)}var w=o.sibling;if(w!==null){w.return=o.return,q=w;break e}q=o.return}}var g=e.current;for(q=g;q!==null;){a=q;var v=a.child;if(a.subtreeFlags&2064&&v!==null)v.return=a,q=v;else e:for(a=g;q!==null;){if(l=q,l.flags&2048)try{switch(l.tag){case 0:case 11:case 15:Zc(9,l)}}catch(j){Fe(l,l.return,j)}if(l===a){q=null;break e}var S=l.sibling;if(S!==null){S.return=l.return,q=S;break e}q=l.return}}if(me=s,cs(),Ln&&typeof Ln.onPostCommitFiberRoot=="function")try{Ln.onPostCommitFiberRoot(Hc,e)}catch{}r=!0}return r}finally{ve=n,Yt.transition=t}}return!1}function ix(e,t,n){t=Go(n,t),t=Aw(e,t,1),e=Qr(e,t,1),t=yt(),e!==null&&(Fa(e,1,t),Et(e,t))}function Fe(e,t,n){if(e.tag===3)ix(e,e,n);else for(;t!==null;){if(t.tag===3){ix(t,e,n);break}else if(t.tag===1){var r=t.stateNode;if(typeof t.type.getDerivedStateFromError=="function"||typeof r.componentDidCatch=="function"&&(Xr===null||!Xr.has(r))){e=Go(n,e),e=Mw(t,e,1),t=Qr(t,e,1),e=yt(),t!==null&&(Fa(t,1,e),Et(t,e));break}}t=t.return}}function X2(e,t,n){var r=e.pingCache;r!==null&&r.delete(t),t=yt(),e.pingedLanes|=e.suspendedLanes&n,Qe===e&&(tt&n)===n&&(Ye===4||Ye===3&&(tt&130023424)===tt&&500>Ve()-Tm?Ms(e,0):Em|=n),Et(e,t)}function Jw(e,t){t===0&&(e.mode&1?(t=nl,nl<<=1,!(nl&130023424)&&(nl=4194304)):t=1);var n=yt();e=or(e,t),e!==null&&(Fa(e,t,n),Et(e,n))}function J2(e){var t=e.memoizedState,n=0;t!==null&&(n=t.retryLane),Jw(e,n)}function Z2(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(V(314))}r!==null&&r.delete(t),Jw(e,n)}var Zw;Zw=function(e,t,n){if(e!==null)if(e.memoizedProps!==t.pendingProps||kt.current)Ct=!0;else{if(!(e.lanes&n)&&!(t.flags&128))return Ct=!1,$2(e,t,n);Ct=!!(e.flags&131072)}else Ct=!1,Te&&t.flags&1048576&&rw(t,fc,t.index);switch(t.lanes=0,t.tag){case 2:var r=t.type;Vl(e,t),e=t.pendingProps;var s=Wo(t,ut.current);ko(t,n),s=Sm(null,t,r,e,s,n);var o=jm();return t.flags|=1,typeof s=="object"&&s!==null&&typeof s.render=="function"&&s.$$typeof===void 0?(t.tag=1,t.memoizedState=null,t.updateQueue=null,Pt(r)?(o=!0,uc(t)):o=!1,t.memoizedState=s.state!==null&&s.state!==void 0?s.state:null,xm(t),s.updater=Jc,t.stateNode=s,s._reactInternals=t,Of(t,r,e,n),t=Lf(null,t,r,!0,o,n)):(t.tag=0,Te&&o&&um(t),ht(null,t,s,n),t=t.child),t;case 16:r=t.elementType;e:{switch(Vl(e,t),e=t.pendingProps,s=r._init,r=s(r._payload),t.type=r,s=t.tag=tP(r),e=un(r,e),s){case 0:t=Df(null,t,r,e,n);break e;case 1:t=Qg(null,t,r,e,n);break e;case 11:t=Gg(null,t,r,e,n);break e;case 14:t=qg(null,t,r,un(r.type,e),n);break e}throw Error(V(306,r,""))}return t;case 0:return r=t.type,s=t.pendingProps,s=t.elementType===r?s:un(r,s),Df(e,t,r,s,n);case 1:return r=t.type,s=t.pendingProps,s=t.elementType===r?s:un(r,s),Qg(e,t,r,s,n);case 3:e:{if(Lw(t),e===null)throw Error(V(387));r=t.pendingProps,o=t.memoizedState,s=o.element,cw(e,t),pc(t,r,null,n);var a=t.memoizedState;if(r=a.element,o.isDehydrated)if(o={element:r,isDehydrated:!1,cache:a.cache,pendingSuspenseBoundaries:a.pendingSuspenseBoundaries,transitions:a.transitions},t.updateQueue.baseState=o,t.memoizedState=o,t.flags&256){s=Go(Error(V(423)),t),t=Xg(e,t,r,n,s);break e}else if(r!==s){s=Go(Error(V(424)),t),t=Xg(e,t,r,n,s);break e}else for(It=qr(t.stateNode.containerInfo.firstChild),Dt=t,Te=!0,pn=null,n=aw(t,null,r,n),t.child=n;n;)n.flags=n.flags&-3|4096,n=n.sibling;else{if(Ho(),r===s){t=ir(e,t,n);break e}ht(e,t,r,n)}t=t.child}return t;case 5:return uw(t),e===null&&Rf(t),r=t.type,s=t.pendingProps,o=e!==null?e.memoizedProps:null,a=s.children,Cf(r,s)?a=null:o!==null&&Cf(r,o)&&(t.flags|=32),Dw(e,t),ht(e,t,a,n),t.child;case 6:return e===null&&Rf(t),null;case 13:return _w(e,t,n);case 4:return ym(t,t.stateNode.containerInfo),r=t.pendingProps,e===null?t.child=Ko(t,null,r,n):ht(e,t,r,n),t.child;case 11:return r=t.type,s=t.pendingProps,s=t.elementType===r?s:un(r,s),Gg(e,t,r,s,n);case 7:return ht(e,t,t.pendingProps,n),t.child;case 8:return ht(e,t,t.pendingProps.children,n),t.child;case 12:return ht(e,t,t.pendingProps.children,n),t.child;case 10:e:{if(r=t.type._context,s=t.pendingProps,o=t.memoizedProps,a=s.value,je(hc,r._currentValue),r._currentValue=a,o!==null)if(wn(o.value,a)){if(o.children===s.children&&!kt.current){t=ir(e,t,n);break e}}else for(o=t.child,o!==null&&(o.return=t);o!==null;){var l=o.dependencies;if(l!==null){a=o.child;for(var c=l.firstContext;c!==null;){if(c.context===r){if(o.tag===1){c=tr(-1,n&-n),c.tag=2;var u=o.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}}o.lanes|=n,c=o.alternate,c!==null&&(c.lanes|=n),Af(o.return,n,t),l.lanes|=n;break}c=c.next}}else if(o.tag===10)a=o.type===t.type?null:o.child;else if(o.tag===18){if(a=o.return,a===null)throw Error(V(341));a.lanes|=n,l=a.alternate,l!==null&&(l.lanes|=n),Af(a,n,t),a=o.sibling}else a=o.child;if(a!==null)a.return=o;else for(a=o;a!==null;){if(a===t){a=null;break}if(o=a.sibling,o!==null){o.return=a.return,a=o;break}a=a.return}o=a}ht(e,t,s.children,n),t=t.child}return t;case 9:return s=t.type,r=t.pendingProps.children,ko(t,n),s=qt(s),r=r(s),t.flags|=1,ht(e,t,r,n),t.child;case 14:return r=t.type,s=un(r,t.pendingProps),s=un(r.type,s),qg(e,t,r,s,n);case 15:return Ow(e,t,t.type,t.pendingProps,n);case 17:return r=t.type,s=t.pendingProps,s=t.elementType===r?s:un(r,s),Vl(e,t),t.tag=1,Pt(r)?(e=!0,uc(t)):e=!1,ko(t,n),Rw(t,r,s),Of(t,r,s,n),Lf(null,t,r,!0,e,n);case 19:return Fw(e,t,n);case 22:return Iw(e,t,n)}throw Error(V(156,t.tag))};function eb(e,t){return P0(e,t)}function eP(e,t,n,r){this.tag=e,this.key=n,this.sibling=this.child=this.return=this.stateNode=this.t
vendor: 9,682 bytes, line 40
40ype=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 Ht(e,t,n,r){return new eP(e,t,n,r)}function Om(e){return e=e.prototype,!(!e||!e.isReactComponent)}function tP(e){if(typeof e=="function")return Om(e)?1:0;if(e!=null){if(e=e.$$typeof,e===Jh)return 11;if(e===Zh)return 14}return 2}function Zr(e,t){var n=e.alternate;return n===null?(n=Ht(e.tag,t,e.key,e.mode),n.elementType=e.elementType,n.type=e.type,n.stateNode=e.stateNode,n.alternate=e,e.alternate=n):(n.pendingProps=t,n.type=e.type,n.flags=0,n.subtreeFlags=0,n.deletions=null),n.flags=e.flags&14680064,n.childLanes=e.childLanes,n.lanes=e.lanes,n.child=e.child,n.memoizedProps=e.memoizedProps,n.memoizedState=e.memoizedState,n.updateQueue=e.updateQueue,t=e.dependencies,n.dependencies=t===null?null:{lanes:t.lanes,firstContext:t.firstContext},n.sibling=e.sibling,n.index=e.index,n.ref=e.ref,n}function zl(e,t,n,r,s,o){var a=2;if(r=e,typeof e=="function")Om(e)&&(a=1);else if(typeof e=="string")a=5;else e:switch(e){case oo:return Os(n.children,s,o,t);case Xh:a=8,s|=8;break;case nf:return e=Ht(12,n,t,s|2),e.elementType=nf,e.lanes=o,e;case rf:return e=Ht(13,n,t,s),e.elementType=rf,e.lanes=o,e;case sf:return e=Ht(19,n,t,s),e.elementType=sf,e.lanes=o,e;case u0:return tu(n,s,o,t);default:if(typeof e=="object"&&e!==null)switch(e.$$typeof){case l0:a=10;break e;case c0:a=9;break e;case Jh:a=11;break e;case Zh:a=14;break e;case Mr:a=16,r=null;break e}throw Error(V(130,e==null?e:typeof e,""))}return t=Ht(a,n,t,s),t.elementType=e,t.type=r,t.lanes=o,t}function Os(e,t,n,r){return e=Ht(7,e,r,t),e.lanes=n,e}function tu(e,t,n,r){return e=Ht(22,e,r,t),e.elementType=u0,e.lanes=n,e.stateNode={isHidden:!1},e}function hd(e,t,n){return e=Ht(6,e,null,t),e.lanes=n,e}function md(e,t,n){return t=Ht(4,e.children!==null?e.children:[],e.key,t),t.lanes=n,t.stateNode={containerInfo:e.containerInfo,pendingChildren:null,implementation:e.implementation},t}function nP(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=Gu(0),this.expirationTimes=Gu(-1),this.entangledLanes=this.finishedLanes=this.mutableReadLanes=this.expiredLanes=this.pingedLanes=this.suspendedLanes=this.pendingLanes=0,this.entanglements=Gu(0),this.identifierPrefix=r,this.onRecoverableError=s,this.mutableSourceEagerHydrationData=null}function Im(e,t,n,r,s,o,a,l,c){return e=new nP(e,t,n,l,c),t===1?(t=1,o===!0&&(t|=8)):t=0,o=Ht(3,null,null,t),e.current=o,o.stateNode=e,o.memoizedState={element:r,isDehydrated:n,cache:null,transitions:null,pendingSuspenseBoundaries:null},xm(o),e}function rP(e,t,n){var r=3<arguments.length&&arguments[3]!==void 0?arguments[3]:null;return{$$typeof:so,key:r==null?null:""+r,children:e,containerInfo:t,implementation:n}}function tb(e){if(!e)return ns;e=e._reactInternals;e:{if(Ys(e)!==e||e.tag!==1)throw Error(V(170));var t=e;do{switch(t.tag){case 3:t=t.stateNode.context;break e;case 1:if(Pt(t.type)){t=t.stateNode.__reactInternalMemoizedMergedChildContext;break e}}t=t.return}while(t!==null);throw Error(V(171))}if(e.tag===1){var n=e.type;if(Pt(n))return tw(e,n,t)}return t}function nb(e,t,n,r,s,o,a,l,c){return e=Im(n,r,!0,e,s,o,a,l,c),e.context=tb(null),n=e.current,r=yt(),s=Jr(n),o=tr(r,s),o.callback=t??null,Qr(n,o,s),e.current.lanes=s,Fa(e,s,r),Et(e,r),e}function nu(e,t,n,r){var s=t.current,o=yt(),a=Jr(s);return n=tb(n),t.context===null?t.context=n:t.pendingContext=n,t=tr(o,a),t.payload={element:e},r=r===void 0?null:r,r!==null&&(t.callback=r),e=Qr(s,t,a),e!==null&&(vn(e,s,a,o),Ll(e,s,a)),a}function jc(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 ax(e,t){if(e=e.memoizedState,e!==null&&e.dehydrated!==null){var n=e.retryLane;e.retryLane=n!==0&&n<t?n:t}}function Dm(e,t){ax(e,t),(e=e.alternate)&&ax(e,t)}function sP(){return null}var rb=typeof reportError=="function"?reportError:function(e){console.error(e)};function Lm(e){this._internalRoot=e}ru.prototype.render=Lm.prototype.render=function(e){var t=this._internalRoot;if(t===null)throw Error(V(409));nu(e,t,null,null)};ru.prototype.unmount=Lm.prototype.unmount=function(){var e=this._internalRoot;if(e!==null){this._internalRoot=null;var t=e.containerInfo;Vs(function(){nu(null,e,null,null)}),t[sr]=null}};function ru(e){this._internalRoot=e}ru.prototype.unstable_scheduleHydration=function(e){if(e){var t=I0();e={blockedOn:null,target:e,priority:t};for(var n=0;n<Dr.length&&t!==0&&t<Dr[n].priority;n++);Dr.splice(n,0,e),n===0&&L0(e)}};function _m(e){return!(!e||e.nodeType!==1&&e.nodeType!==9&&e.nodeType!==11)}function su(e){return!(!e||e.nodeType!==1&&e.nodeType!==9&&e.nodeType!==11&&(e.nodeType!==8||e.nodeValue!==" react-mount-point-unstable "))}function lx(){}function oP(e,t,n,r,s){if(s){if(typeof r=="function"){var o=r;r=function(){var u=jc(a);o.call(u)}}var a=nb(t,r,e,0,null,!1,!1,"",lx);return e._reactRootContainer=a,e[sr]=a.current,fa(e.nodeType===8?e.parentNode:e),Vs(),a}for(;s=e.lastChild;)e.removeChild(s);if(typeof r=="function"){var l=r;r=function(){var u=jc(c);l.call(u)}}var c=Im(e,0,!1,null,null,!1,!1,"",lx);return e._reactRootContainer=c,e[sr]=c.current,fa(e.nodeType===8?e.parentNode:e),Vs(function(){nu(t,c,n,r)}),c}function ou(e,t,n,r,s){var o=n._reactRootContainer;if(o){var a=o;if(typeof s=="function"){var l=s;s=function(){var c=jc(a);l.call(c)}}nu(t,a,e,s)}else a=oP(n,t,e,s,r);return jc(a)}M0=function(e){switch(e.tag){case 3:var t=e.stateNode;if(t.current.memoizedState.isDehydrated){var n=_i(t.pendingLanes);n!==0&&(nm(t,n|1),Et(t,Ve()),!(me&6)&&(qo=Ve()+500,cs()))}break;case 13:Vs(function(){var r=or(e,1);if(r!==null){var s=yt();vn(r,e,1,s)}}),Dm(e,1)}};rm=function(e){if(e.tag===13){var t=or(e,134217728);if(t!==null){var n=yt();vn(t,e,134217728,n)}Dm(e,134217728)}};O0=function(e){if(e.tag===13){var t=Jr(e),n=or(e,t);if(n!==null){var r=yt();vn(n,e,t,r)}Dm(e,t)}};I0=function(){return ve};D0=function(e,t){var n=ve;try{return ve=e,t()}finally{ve=n}};pf=function(e,t,n){switch(t){case"input":if(lf(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=qc(r);if(!s)throw Error(V(90));f0(r),lf(r,s)}}}break;case"textarea":m0(e,n);break;case"select":t=n.value,t!=null&&So(e,!!n.multiple,t,!1)}};b0=Rm;S0=Vs;var iP={usingClientEntryPoint:!1,Events:[$a,co,qc,v0,w0,Rm]},Pi={findFiberByHostInstance:ws,bundleType:0,version:"18.3.1",rendererPackageName:"react-dom"},aP={bundleType:Pi.bundleType,version:Pi.version,rendererPackageName:Pi.rendererPackageName,rendererConfig:Pi.rendererConfig,overrideHookState:null,overrideHookStateDeletePath:null,overrideHookStateRenamePath:null,overrideProps:null,overridePropsDeletePath:null,overridePropsRenamePath:null,setErrorHandler:null,setSuspenseHandler:null,scheduleUpdate:null,currentDispatcherRef:fr.ReactCurrentDispatcher,findHostInstanceByFiber:function(e){return e=C0(e),e===null?null:e.stateNode},findFiberByHostInstance:Pi.findFiberByHostInstance||sP,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 hl=__REACT_DEVTOOLS_GLOBAL_HOOK__;if(!hl.isDisabled&&hl.supportsFiber)try{Hc=hl.inject(aP),Ln=hl}catch{}}Ft.__SECRET_INTERNALS_DO_NOT_USE_OR_YOU_WILL_BE_FIRED=iP;Ft.createPortal=function(e,t){var n=2<arguments.length&&arguments[2]!==void 0?arguments[2]:null;if(!_m(t))throw Error(V(200));return rP(e,t,null,n)};Ft.createRoot=function(e,t){if(!_m(e))throw Error(V(299));var n=!1,r="",s=rb;return t!=null&&(t.unstable_strictMode===!0&&(n=!0),t.identifierPrefix!==void 0&&(r=t.identifierPrefix),t.onRecoverableError!==void 0&&(s=t.onRecoverableError)),t=Im(e,1,!1,null,null,n,!1,r,s),e[sr]=t.current,fa(e.nodeType===8?e.parentNode:e),new Lm(t)};Ft.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(V(188)):(e=Object.keys(e).join(","),Error(V(268,e)));return e=C0(t),e=e===null?null:e.stateNode,e};Ft.flushSync=function(e){return Vs(e)};Ft.hydrate=function(e,t,n){if(!su(t))throw Error(V(200));return ou(null,e,t,!0,n)};Ft.hydrateRoot=function(e,t,n){if(!_m(e))throw Error(V(405));var r=n!=null&&n.hydratedSources||null,s=!1,o="",a=rb;if(n!=null&&(n.unstable_strictMode===!0&&(s=!0),n.identifierPrefix!==void 0&&(o=n.identifierPrefix),n.onRecoverableError!==void 0&&(a=n.onRecoverableError)),t=nb(t,null,e,1,n??null,s,!1,o,a),e[sr]=t.current,fa(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 ru(t)};Ft.render=function(e,t,n){if(!su(t))throw Error(V(200));return ou(null,e,t,!1,n)};Ft.unmountComponentAtNode=function(e){if(!su(e))throw Error(V(40));return e._reactRootContainer?(Vs(function(){ou(null,null,e,!1,function(){e._reactRootContainer=null,e[sr]=null})}),!0):!1};Ft.unstable_batchedUpdates=Rm;Ft.unstable_renderSubtreeIntoContainer=function(e,t,n,r){if(!su(n))throw Error(V(200));if(e==null||e._reactInternals===void 0)throw Error(V(38));return ou(e,t,n,!1,r)};Ft.version="18.3.1-next-f1338f8080-20240426";
40function sb(){if(!(typeof __REACT_DEVTOOLS_GLOBAL_HOOK__>"u"||typeof __REACT_DEVTOOLS_GLOBAL_HOOK__.checkDCE!="function"))try{__REACT_DEVTOOLS_GLOBAL_HOOK__.checkDCE(sb)}catch(e){console.error(e)}}sb(),s0.exports=Ft;var Gs=s0.exports;const ob=Kv(Gs);var ib,cx=Gs;ib=cx.createRoot,cx.hydrateRoot;const lP=1,cP=1e6;let pd=0;function uP(){return pd=(pd+1)%Number.MAX_SAFE_INTEGER,pd.toString()}const gd=new Map,ux=e=>{if(gd.has(e))return;const t=setTimeout(()=>{gd.delete(e),Ji({type:"REMOVE_TOAST",toastId:e})},cP);gd.set(e,t)},dP=(e,t)=>{switch(t.type){case"ADD_TOAST":return{...e,toasts:[t.toast,...e.toasts].slice(0,lP)};case"UPDATE_TOAST":return{...e,toasts:e.toasts.map(n=>n.id===t.toast.id?{...n,...t.toast}:n)};case"DISMISS_TOAST":{const{toastId:n}=t;return n?ux(n):e.toasts.forEach(r=>{ux(r.id)}),{...e,toasts:e.toasts.map(r=>r.id===n||n===void 0?{...r,open:!1}:r)}}case"REMOVE_TOAST":return t.toastId===void 0?{...e,toasts:[]}:{...e,toasts:e.toasts.filter(n=>n.id!==t.toastId)}}},Ul=[];let Wl={toasts:[]};function Ji(e){Wl=dP(Wl,e),Ul.forEach(t=>{t(Wl)})}function fP({...e}){const t=uP(),n=s=>Ji({type:"UPDATE_TOAST",toast:{...s,id:t}}),r=()=>Ji({type:"DISMISS_TOAST",toastId:t});return Ji({type:"ADD_TOAST",toast:{...e,id:t,open:!0,onOpenChange:s=>{s||r()}}}),{id:t,dismiss:r,update:n}}function hP(){const[e,t]=h.useState(Wl);return h.useEffect(()=>(Ul.push(t),()=>{const n=Ul.indexOf(t);n>-1&&Ul.splice(n,1)}),[e]),{...e,toast:fP,dismiss:n=>Ji({type:"DISMISS_TOAST",toastId:n})}}function oe(e,t,{checkForDefaultPrevented:n=!0}={}){return function(s){if(e==null||e(s),n===!1||!s.defaultPrevented)return t==null?void 0:t(s)}}function dx(e,t){if(typeof e=="function")return e(t);e!=null&&(e.current=t)}function ab(...e){return t=>{let n=!1;const r=e.map(s=>{const o=dx(s,t);return!n&&typeof o=="function"&&(n=!0),o});if(n)return()=>{for(let s=0;s<r.length;s++){const o=r[s];typeof o=="function"?o():dx(e[s],null)}}}}function Se(...e){return h.useCallback(ab(...e),e)}function mP(e,t){const n=h.createContext(t),r=o=>{const{children:a,...l}=o,c=h.useMemo(()=>l,Object.values(l));return i.jsx(n.Provider,{value:c,children:a})};r.displayName=e+"Provider";function s(o){const a=h.useContext(n);if(a)return a;if(t!==void 0)return t;throw new Error(`\`${o}\` must be used within \`${e}\``)}return[r,s]}function qs(e,t=[]){let n=[];function r(o,a){const l=h.createContext(a),c=n.length;n=[...n,a];const u=f=>{var w;const{scope:m,children:p,...b}=f,x=((w=m==null?void 0:m[e])==null?void 0:w[c])||l,y=h.useMemo(()=>b,Object.values(b));return i.jsx(x.Provider,{value:y,children:p})};u.displayName=o+"Provider";function d(f,m){var x;const p=((x=m==null?void 0:m[e])==null?void 0:x[c])||l,b=h.useContext(p);if(b)return b;if(a!==void 0)return a;throw new Error(`\`${f}\` must be used within \`${o}\``)}return[u,d]}const s=()=>{const o=n.map(a=>h.createContext(a));return function(l){const c=(l==null?void 0:l[e])||o;return h.useMemo(()=>({[`__scope${e}`]:{...l,[e]:c}}),[l,c])}};return s.scopeName=e,[r,pP(s,...t)]}function pP(...e){const t=e[0];if(e.length===1)return t;const n=()=>{const r=e.map(s=>({useScope:s(),scopeName:s.scopeName}));return function(o){const a=r.reduce((l,{useScope:c,scopeName:u})=>{const f=c(o)[`__scope${u}`];return{...l,...f}},{});return h.useMemo(()=>({[`__scope${t.scopeName}`]:a}),[a])}};return n.scopeName=t.scopeName,n}function Qo(e){const t=xP(e),n=h.forwardRef((r,s)=>{const{children:o,...a}=r,l=h.Children.toArray(o),c=l.find(vP);if(c){const u=c.props.children,d=l.map(f=>f===c?h.Children.count(u)>1?h.Children.only(null):h.isValidElement(u)?u.props.children:null:f);return i.jsx(t,{...a,ref:s,children:h.isValidElement(u)?h.cloneElement(u,void 0,d):null})}return i.jsx(t,{...a,ref:s,children:o})});return n.displayName=`${e}.Slot`,n}var gP=Qo("Slot");function xP(e){const t=h.forwardRef((n,r)=>{const{children:s,...o}=n;if(h.isValidElement(s)){const a=bP(s),l=wP(o,s.props);return s.type!==h.Fragment&&(l.ref=r?ab(r,a):a),h.cloneElement(s,l)}return h.Children.count(s)>1?h.Children.only(null):null});return t.displayName=`${e}.SlotClone`,t}var lb=Symbol("radix.slottable");function yP(e){const t=({children:n})=>i.jsx(i.Fragment,{children:n});return t.displayName=`${e}.Slottable`,t.__radixId=lb,t}function vP(e){return h.isValidElement(e)&&typeof e.type=="function"&&"__radixId"in e.type&&e.type.__radixId===lb}function wP(e,t){const n={...t};for(const r in t){const s=e[r],o=t[r];/^on[A-Z]/.test(r)?s&&o?n[r]=(...l)=>{const c=o(...l);return s(...l),c}:s&&(n[r]=s):r==="style"?n[r]={...s,...o}
vendor: 8,722 bytes, line 40
40:r==="className"&&(n[r]=[s,o].filter(Boolean).join(" "))}return{...e,...n}}function bP(e){var r,s;let t=(r=Object.getOwnPropertyDescriptor(e.props,"ref"))==null?void 0:r.get,n=t&&"isReactWarning"in t&&t.isReactWarning;return n?e.ref:(t=(s=Object.getOwnPropertyDescriptor(e,"ref"))==null?void 0:s.get,n=t&&"isReactWarning"in t&&t.isReactWarning,n?e.props.ref:e.props.ref||e.ref)}function cb(e){const t=e+"CollectionProvider",[n,r]=qs(t),[s,o]=n(t,{collectionRef:{current:null},itemMap:new Map}),a=x=>{const{scope:y,children:w}=x,g=W.useRef(null),v=W.useRef(new Map).current;return i.jsx(s,{scope:y,itemMap:v,collectionRef:g,children:w})};a.displayName=t;const l=e+"CollectionSlot",c=Qo(l),u=W.forwardRef((x,y)=>{const{scope:w,children:g}=x,v=o(l,w),S=Se(y,v.collectionRef);return i.jsx(c,{ref:S,children:g})});u.displayName=l;const d=e+"CollectionItemSlot",f="data-radix-collection-item",m=Qo(d),p=W.forwardRef((x,y)=>{const{scope:w,children:g,...v}=x,S=W.useRef(null),j=Se(y,S),C=o(d,w);return W.useEffect(()=>(C.itemMap.set(S,{ref:S,...v}),()=>void C.itemMap.delete(S))),i.jsx(m,{[f]:"",ref:j,children:g})});p.displayName=d;function b(x){const y=o(e+"CollectionConsumer",x);return W.useCallback(()=>{const g=y.collectionRef.current;if(!g)return[];const v=Array.from(g.querySelectorAll(`[${f}]`));return Array.from(y.itemMap.values()).sort((C,P)=>v.indexOf(C.ref.current)-v.indexOf(P.ref.current))},[y.collectionRef,y.itemMap])}return[{Provider:a,Slot:u,ItemSlot:p},b,r]}var SP=["a","button","div","form","h2","h3","img","input","label","li","nav","ol","p","select","span","svg","ul"],fe=SP.reduce((e,t)=>{const n=Qo(`Primitive.${t}`),r=h.forwardRef((s,o)=>{const{asChild:a,...l}=s,c=a?n:t;return typeof window<"u"&&(window[Symbol.for("radix-ui")]=!0),i.jsx(c,{...l,ref:o})});return r.displayName=`Primitive.${t}`,{...e,[t]:r}},{});function ub(e,t){e&&Gs.flushSync(()=>e.dispatchEvent(t))}function bn(e){const t=h.useRef(e);return h.useEffect(()=>{t.current=e}),h.useMemo(()=>(...n)=>{var r;return(r=t.current)==null?void 0:r.call(t,...n)},[])}function jP(e,t=globalThis==null?void 0:globalThis.document){const n=bn(e);h.useEffect(()=>{const r=s=>{s.key==="Escape"&&n(s)};return t.addEventListener("keydown",r,{capture:!0}),()=>t.removeEventListener("keydown",r,{capture:!0})},[n,t])}var NP="DismissableLayer",Gf="dismissableLayer.update",CP="dismissableLayer.pointerDownOutside",kP="dismissableLayer.focusOutside",fx,db=h.createContext({layers:new Set,layersWithOutsidePointerEventsDisabled:new Set,branches:new Set}),za=h.forwardRef((e,t)=>{const{disableOutsidePointerEvents:n=!1,onEscapeKeyDown:r,onPointerDownOutside:s,onFocusOutside:o,onInteractOutside:a,onDismiss:l,...c}=e,u=h.useContext(db),[d,f]=h.useState(null),m=(d==null?void 0:d.ownerDocument)??(globalThis==null?void 0:globalThis.document),[,p]=h.useState({}),b=Se(t,P=>f(P)),x=Array.from(u.layers),[y]=[...u.layersWithOutsidePointerEventsDisabled].slice(-1),w=x.indexOf(y),g=d?x.indexOf(d):-1,v=u.layersWithOutsidePointerEventsDisabled.size>0,S=g>=w,j=EP(P=>{const N=P.target,E=[...u.branches].some(k=>k.contains(N));!S||E||(s==null||s(P),a==null||a(P),P.defaultPrevented||l==null||l())},m),C=TP(P=>{const N=P.target;[...u.branches].some(k=>k.contains(N))||(o==null||o(P),a==null||a(P),P.defaultPrevented||l==null||l())},m);return jP(P=>{g===u.layers.size-1&&(r==null||r(P),!P.defaultPrevented&&l&&(P.preventDefault(),l()))},m),h.useEffect(()=>{if(d)return n&&(u.layersWithOutsidePointerEventsDisabled.size===0&&(fx=m.body.style.pointerEvents,m.body.style.pointerEvents="none"),u.layersWithOutsidePointerEventsDisabled.add(d)),u.layers.add(d),hx(),()=>{n&&u.layersWithOutsidePointerEventsDisabled.size===1&&(m.body.style.pointerEvents=fx)}},[d,m,n,u]),h.useEffect(()=>()=>{d&&(u.layers.delete(d),u.layersWithOutsidePointerEventsDisabled.delete(d),hx())},[d,u]),h.useEffect(()=>{const P=()=>p({});return document.addEventListener(Gf,P),()=>document.removeEventListener(Gf,P)},[]),i.jsx(fe.div,{...c,ref:b,style:{pointerEvents:v?S?"auto":"none":void 0,...e.style},onFocusCapture:oe(e.onFocusCapture,C.onFocusCapture),onBlurCapture:oe(e.onBlurCapture,C.onBlurCapture),onPointerDownCapture:oe(e.onPointerDownCapture,j.onPointerDownCapture)})});za.displayName=NP;var PP="DismissableLayerBranch",fb=h.forwardRef((e,t)=>{const n=h.useContext(db),r=h.useRef(null),s=Se(t,r);return h.useEffect(()=>{const o=r.current;if(o)return n.branches.add(o),()=>{n.branches.delete(o)}},[n.branches]),i.jsx(fe.div,{...e,ref:s})});fb.displayName=PP;function EP(e,t=globalThis==null?void 0:globalThis.document){const n=bn(e),r=h.useRef(!1),s=h.useRef(()=>{});return h.useEffect(()=>{const o=l=>{if(l.target&&!r.current){let c=function(){hb(CP,n,u,{discrete:!0})};const u={originalEvent:l};l.pointerType==="touch"?(t.removeEventListener("click",s.current),s.current=c,t.addEventListener("click",s.current,{once:!0})):c()}else t.removeEventListener("click",s.current);r.current=!1},a=window.setTimeout(()=>{t.addEventListener("pointerdown",o)},0);return()=>{window.clearTimeout(a),t.removeEventListener("pointerdown",o),t.removeEventListener("click",s.current)}},[t,n]),{onPointerDownCapture:()=>r.current=!0}}function TP(e,t=globalThis==null?void 0:globalThis.document){const n=bn(e),r=h.useRef(!1);return h.useEffect(()=>{const s=o=>{o.target&&!r.current&&hb(kP,n,{originalEvent:o},{discrete:!1})};return t.addEventListener("focusin",s),()=>t.removeEventListener("focusin",s)},[t,n]),{onFocusCapture:()=>r.current=!0,onBlurCapture:()=>r.current=!1}}function hx(){const e=new CustomEvent(Gf);document.dispatchEvent(e)}function hb(e,t,n,{discrete:r}){const s=n.originalEvent.target,o=new CustomEvent(e,{bubbles:!1,cancelable:!0,detail:n});t&&s.addEventListener(e,t,{once:!0}),r?ub(s,o):s.dispatchEvent(o)}var RP=za,AP=fb,rt=globalThis!=null&&globalThis.document?h.useLayoutEffect:()=>{},MP="Portal",iu=h.forwardRef((e,t)=>{var l;const{container:n,...r}=e,[s,o]=h.useState(!1);rt(()=>o(!0),[]);const a=n||s&&((l=globalThis==null?void 0:globalThis.document)==null?void 0:l.body);return a?ob.createPortal(i.jsx(fe.div,{...r,ref:t}),a):null});iu.displayName=MP;function OP(e,t){return h.useReducer((n,r)=>t[n][r]??n,e)}var ai=e=>{const{present:t,children:n}=e,r=IP(t),s=typeof n=="function"?n({present:r.isPresent}):h.Children.only(n),o=Se(r.ref,DP(s));return typeof n=="function"||r.isPresent?h.cloneElement(s,{ref:o}):null};ai.displayName="Presence";function IP(e){const[t,n]=h.useState(),r=h.useRef(null),s=h.useRef(e),o=h.useRef("none"),a=e?"mounted":"unmounted",[l,c]=OP(a,{mounted:{UNMOUNT:"unmounted",ANIMATION_OUT:"unmountSuspended"},unmountSuspended:{MOUNT:"mounted",ANIMATION_END:"unmounted"},unmounted:{MOUNT:"mounted"}});return h.useEffect(()=>{const u=ml(r.current);o.current=l==="mounted"?u:"none"},[l]),rt(()=>{const u=r.current,d=s.current;if(d!==e){const m=o.current,p=ml(u);e?c("MOUNT"):p==="none"||(u==null?void 0:u.display)==="none"?c("UNMOUNT"):c(d&&m!==p?"ANIMATION_OUT":"UNMOUNT"),s.current=e}},[e,c]),rt(()=>{if(t){let u;const d=t.ownerDocument.defaultView??window,f=p=>{const x=ml(r.current).includes(p.animationName);if(p.target===t&&x&&(c("ANIMATION_END"),!s.current)){const y=t.style.animationFillMode;t.style.animationFillMode="forwards",u=d.setTimeout(()=>{t.style.animationFillMode==="forwards"&&(t.style.animationFillMode=y)})}},m=p=>{p.target===t&&(o.current=ml(r.current))};return t.addEventListener("animationstart",m),t.addEventListener("animationcancel",f),t.addEventListener("animationend",f),()=>{d.clearTimeout(u),t.removeEventListener("animationstart",m),t.removeEventListener("animationcancel",f),t.removeEventListener("animationend",f)}}else c("ANIMATION_END")},[t,c]),{isPresent:["mounted","unmountSuspended"].includes(l),ref:h.useCallback(u=>{r.current=u?getComputedStyle(u):null,n(u)},[])}}function ml(e){return(e==null?void 0:e.animationName)||"none"}function DP(e){var r,s;let t=(r=Object.getOwnPropertyDescriptor(e.props,"ref"))==null?void 0:r.get,n=t&&"isReactWarning"in t&&t.isReactWarning;return n?e.ref:(t=(s=Object.getOwnPropertyDescriptor(e,"ref"))==null?void 0:s.get,n=t&&"isReactWarning"in t&&t.isReactWarning,n?e.props.ref:e.props.ref||e.ref)}var LP=Yh[" useInsertionEffect ".trim().toString()]||rt;function ba({prop:e,defaultProp:t,onChange:n=()=>{},caller:r}){const[s,o,a]=_P({defaultProp:t,onChange:n}),l=e!==void 0,c=l?e:s;{const d=h.useRef(e!==void 0);h.useEffect(()=>{const f=d.current;f!==l&&console.warn(`${r} is changing from ${f?"controlled":"uncontrolled"} to ${l?"controlled":"uncontrolled"}. Components should not switch from controlled to uncontrolled (or vice versa). Decide between using a controlled or uncontrolled value for the lifetime of the component.`),d.current=l},[l,r])}const u=h.useCallback(d=>{var f;
40if(l){const m=FP(d)?d(e):d;m!==e&&((f=a.current)==null||f.call(a,m))}else o(d)},[l,e,o,a]);return[c,u]}function _P({defaultProp:e,onChange:t}){const[n,r]=h.useState(e),s=h.useRef(n),o=h.useRef(t);return LP(()=>{o.current=t},[t]),h.useEffect(()=>{var a;s.current!==n&&((a=o.current)==null||a.call(o,n),s.current=n)},[n,s]),[n,r,o]}function FP(e){return typeof e=="function"}var mb=Object.freeze({position:"absolute",border:0,width:1,height:1,padding:0,margin:-1,overflow:"hidden",clip:"rect(0, 0, 0, 0)",whiteSpace:"nowrap",wordWrap:"normal"}),VP="VisuallyHidden",au=h.forwardRef((e,t)=>i.jsx(fe.span,{...e,ref:t,style:{...mb,...e.style}}));au.displayName=VP;var $P=au,Fm="ToastProvider",[Vm,BP,zP]=cb("Toast"),[pb]=qs("Toast",[zP]),[UP,lu]=pb(Fm),gb=e=>{const{__scopeToast:t,label:n="Notification",duration:r=5e3,swipeDirection:s="right",swipeThreshold:o=50,children:a}=e,[l,c]=h.useState(null),[u,d]=h.useState(0),f=h.useRef(!1),m=h.useRef(!1);return n.trim()||console.error(`Invalid prop \`label\` supplied to \`${Fm}\`. Expected non-empty \`string\`.`),i.jsx(Vm.Provider,{scope:t,children:i.jsx(UP,{scope:t,label:n,duration:r,swipeDirection:s,swipeThreshold:o,toastCount:u,viewport:l,onViewportChange:c,onToastAdd:h.useCallback(()=>d(p=>p+1),[]),onToastRemove:h.useCallback(()=>d(p=>p-1),[]),isFocusedToastEscapeKeyDownRef:f,isClosePausedRef:m,children:a})})};gb.displayName=Fm;var xb="ToastViewport",WP=["F8"],qf="toast.viewportPause",Qf="toast.viewportResume",yb=h.forwardRef((e,t)=>{const{__scopeToast:n,hotkey:r=WP,label:s="Notifications ({hotkey})",...o}=e,a=lu(xb,n),l=BP(n),c=h.useRef(null),u=h.useRef(null),d=h.useRef(null),f=h.useRef(null),m=Se(t,f,a.onViewportChange),p=r.join("+").replace(/Key/g,"").replace(/Digit/g,""),b=a.toastCount>0;h.useEffect(()=>{const y=w=>{var v;r.length!==0&&r.every(S=>w[S]||w.code===S)&&((v=f.current)==null||v.focus())};return document.addEventListener("keydown",y),()=>document.removeEventListener("keydown",y)},[r]),h.useEffect(()=>{const y=c.current,w=f.current;if(b&&y&&w){const g=()=>{if(!a.isClosePausedRef.current){const C=new CustomEvent(qf);w.dispatchEvent(C),a.isClosePausedRef.current=!0}},v=()=>{if(a.isClosePausedRef.current){const C=new CustomEvent(Qf);w.dispatchEvent(C),a.isClosePausedRef.current=!1}},S=C=>{!y.contains(C.relatedTarget)&&v()},j=()=>{y.contains(document.activeElement)||v()};return y.addEventListener("focusin",g),y.addEventListener("focusout",S),y.addEventListener("pointermove",g),y.addEventListener("pointerleave",j),window.addEventListener("blur",g),window.addEventListener("focus",v),()=>{y.removeEventListener("focusin",g),y.removeEventListener("focusout",S),y.removeEventListener("pointermove",g),y.removeEventListener("pointerleave",j),window.removeEventListener("blur",g),window.removeEventListener("focus",v)}}},[b,a.isClosePausedRef]);const x=h.useCallback(({tabbingDirection:y})=>{const g=l().map(v=>{const S=v.ref.current,j=[S,...rE(S)];return y==="forwards"?j:j.reverse()});return(y==="forwards"?g.reverse():g).flat()},[l]);return h.useEffect(()=>{const y=f.current;if(y){const w=g=>{var j,C,P;const v=g.altKey||g.ctrlKey||g.metaKey;if(g.key==="Tab"&&!v){const N=document.activeElement,E=g.shiftKey;if(g.target===y&&E){(j=u.current)==null||j.focus();return}const M=x({tabbingDirection:E?"backwards":"forwards"}),I=M.findIndex(O=>O===N);xd(M.slice(I+1))?g.preventDefault():E?(C=u.current)==null||C.focus():(P=d.current)==null||P.focus()}};return y.addEventListener("keydown",w),()=>y.removeEventListener("keydown",w)}},[l,x]),i.jsxs(AP,{ref:c,role:"region","aria-label":s.replace("{hotkey}",p),tabIndex:-1,style:{pointerEvents:b?void 0:"none"},children:[b&&i.jsx(Xf,{ref:u,onFocusFromOutsideViewport:()=>{const y=x({tabbingDirection:"forwards"});xd(y)}}),i.jsx(Vm.Slot,{scope:n,children:i.jsx(fe.ol,{tabIndex:-1,...o,ref:m})}),b&&i.jsx(Xf,{ref:d,onFocusFromOutsideViewport:()=>{const y=x({tabbingDirection:"backwards"});xd(y)}})]})});yb.displayName=xb;var vb="ToastFocusProxy",Xf=h.forwardRef((e,t)=>{const{__scopeToast:n,onFocusFromOutsideViewport:r,...s}=e,o=lu(vb,n);return i.jsx(au,{"aria-hidden":!0,tabIndex:0,...s,ref:t,style:{position:"fixed"},onFocus:a=>{var u;const l=a.relatedTarget;!((u=o.viewport)!=null&&u.contains(l))&&r()}})});Xf.displayName=vb;var Ua="Toast",HP="toast.swipeStart",KP="toast.swipeMove",YP="toast.swipeCancel",GP="toast.swipeEnd",wb=h.forwardRef((e,t)=>
40{const{forceMount:n,open:r,defaultOpen:s,onOpenChange:o,...a}=e,[l,c]=ba({prop:r,defaultProp:s??!0,onChange:o,caller:Ua});return i.jsx(ai,{present:n||l,children:i.jsx(XP,{open:l,...a,ref:t,onClose:()=>c(!1),onPause:bn(e.onPause),onResume:bn(e.onResume),onSwipeStart:oe(e.onSwipeStart,u=>{u.currentTarget.setAttribute("data-swipe","start")}),onSwipeMove:oe(e.onSwipeMove,u=>{const{x:d,y:f}=u.detail.delta;u.currentTarget.setAttribute("data-swipe","move"),u.currentTarget.style.setProperty("--radix-toast-swipe-move-x",`${d}px`),u.currentTarget.style.setProperty("--radix-toast-swipe-move-y",`${f}px`)}),onSwipeCancel:oe(e.onSwipeCancel,u=>{u.currentTarget.setAttribute("data-swipe","cancel"),u.currentTarget.style.removeProperty("--radix-toast-swipe-move-x"),u.currentTarget.style.removeProperty("--radix-toast-swipe-move-y"),u.currentTarget.style.removeProperty("--radix-toast-swipe-end-x"),u.currentTarget.style.removeProperty("--radix-toast-swipe-end-y")}),onSwipeEnd:oe(e.onSwipeEnd,u=>{const{x:d,y:f}=u.detail.delta;u.currentTarget.setAttribute("data-swipe","end"),u.currentTarget.style.removeProperty("--radix-toast-swipe-move-x"),u.currentTarget.style.removeProperty("--radix-toast-swipe-move-y"),u.currentTarget.style.setProperty("--radix-toast-swipe-end-x",`${d}px`),u.currentTarget.style.setProperty("--radix-toast-swipe-end-y",`${f}px`),c(!1)})})})});wb.displayName=Ua;var[qP,QP]=pb(Ua,{onClose(){}}),XP=h.forwardRef((e,t)=>{const{__scopeToast:n,type:r="foreground",duration:s,open:o,onClose:a,onEscapeKeyDown:l,onPause:c,onResume:u,onSwipeStart:d,onSwipeMove:f,onSwipeCancel:m,onSwipeEnd:p,...b}=e,x=lu(Ua,n),[y,w]=h.useState(null),g=Se(t,O=>w(O)),v=h.useRef(null),S=h.useRef(null),j=s||x.duration,C=h.useRef(0),P=h.useRef(j),N=h.useRef(0),{onToastAdd:E,onToastRemove:k}=x,R=bn(()=>{var H;(y==null?void 0:y.contains(document.activeElement))&&((H=x.viewport)==null||H.focus()),a()}),M=h.useCallback(O=>{!O||O===1/0||(window.clearTimeout(N.current),C.current=new Date().getTime(),N.current=window.setTimeout(R,O))},[R]);h.useEffect(()=>{const O=x.viewport;if(O){const H=()=>{M(P.current),u==null||u()},B=()=>{const U=new Date().getTime()-C.current;P.current=P.current-U,window.clearTimeout(N.current),c==null||c()};return O.addEventListener(qf,B),O.addEventListener(Qf,H),()=>{O.removeEventListener(qf,B),O.removeEventListener(Qf,H)}}},[x.viewport,j,c,u,M]),h.useEffect(()=>{o&&!x.isClosePausedRef.current&&M(j)},[o,j,x.isClosePausedRef,M]),h.useEffect(()=>(E(),()=>k()),[E,k]);const I=h.useMemo(()=>y?Pb(y):null,[y]);return x.viewport?i.jsxs(i.Fragment,{children:[I&&i.jsx(JP,{__scopeToast:n,role:"status","aria-live":r==="foreground"?"assertive":"polite","aria-atomic":!0,children:I}),i.jsx(qP,{scope:n,onClose:R,children:Gs.createPortal(i.jsx(Vm.ItemSlot,{scope:n,children:i.jsx(RP,{asChild:!0,onEscapeKeyDown:oe(l,()=>{x.isFocusedToastEscapeKeyDownRef.current||R(),x.isFocusedToastEscapeKeyDownRef.current=!1}),children:i.jsx(fe.li,{role:"status","aria-live":"off","aria-atomic":!0,tabIndex:0,"data-state":o?"open":"closed","data-swipe-direction":x.swipeDirection,...b,ref:g,style:{userSelect:"none",touchAction:"none",...e.style},onKeyDown:oe(e.onKeyDown,O=>{O.key==="Escape"&&(l==null||l(O.nativeEvent),O.nativeEvent.defaultPrevented||(x.isFocusedToastEscapeKeyDownRef.current=!0,R()))}),onPointerDown:oe(e.onPointerDown,O=>{O.button===0&&(v.current={x:O.clientX,y:O.clientY})}),onPointerMove:oe(e.onPointerMove,O=>{if(!v.current)return;const H=O.clientX-v.current.x,B=O.clientY-v.current.y,U=!!S.current,T=["left","right"].includes(x.swipeDirection),A=["left","up"].includes(x.swipeDirection)?Math.min:Math.max,L=T?A(0,H):0,_=T?0:A(0,B),$=O.pointerType==="touch"?10:2,J={x:L,y:_},ee={originalEvent:O,delta:J};U?(S.current=J,pl(KP,f,ee,{discrete:!1})):mx(J,x.swipeDirection,$)?(S.current=J,pl(HP,d,ee,{discrete:!1}),O.target.setPointerCapture(O.pointerId)):(Math.abs(H)>$||Math.abs(B)>$)&&(v.current=null)}),onPointerUp:oe(e.onPointerUp,O=>{const H=S.current,B=O.target;if(B.hasPointerCapture(O.pointerId)&&B.releasePointerCapture(O.pointerId),S.current=null,v.current=null,H){const U=O.currentTarget,T={originalEvent:O,delta:H};mx(H,x.swipeDirection,x.swipeThreshold)?pl(GP,p,T,{discrete:!0}):pl(YP,m,T,{discrete:!0}),U.addEventListener("click",A=>A.preventDefault(),{once:!0})}})})})}),x.viewport)})]}):null}),JP=e=>{const{__scopeToast:t,children:n,...r}=e,s=lu(Ua,t),[o,a]=h.useState(!1),[l,c]=h.useState(!1);return tE(()=>a(!0)),h.useEffect(()=>{const u=window.setTimeout(()=>c(!0),1e3);return()=>window.clearTimeout(u)},[]),l?null:i.jsx(iu,{asChild:!0,children:i.jsx(au,{...r,children:o&&i.jsxs(i.Fragment,{children:[s.label," ",n]})})})},ZP="ToastTitle",bb=h.forwardRef((e,t)=>
vendor: 4,742 bytes, lines 40-60
40{const{__scopeToast:n,...r}=e;return i.jsx(fe.div,{...r,ref:t})});bb.displayName=ZP;var eE="ToastDescription",Sb=h.forwardRef((e,t)=>{const{__scopeToast:n,...r}=e;return i.jsx(fe.div,{...r,ref:t})});Sb.displayName=eE;var jb="ToastAction",Nb=h.forwardRef((e,t)=>{const{altText:n,...r}=e;return n.trim()?i.jsx(kb,{altText:n,asChild:!0,children:i.jsx($m,{...r,ref:t})}):(console.error(`Invalid prop \`altText\` supplied to \`${jb}\`. Expected non-empty \`string\`.`),null)});Nb.displayName=jb;var Cb="ToastClose",$m=h.forwardRef((e,t)=>{const{__scopeToast:n,...r}=e,s=QP(Cb,n);return i.jsx(kb,{asChild:!0,children:i.jsx(fe.button,{type:"button",...r,ref:t,onClick:oe(e.onClick,s.onClose)})})});$m.displayName=Cb;var kb=h.forwardRef((e,t)=>{const{__scopeToast:n,altText:r,...s}=e;return i.jsx(fe.div,{"data-radix-toast-announce-exclude":"","data-radix-toast-announce-alt":r||void 0,...s,ref:t})});function Pb(e){const t=[];return Array.from(e.childNodes).forEach(r=>{if(r.nodeType===r.TEXT_NODE&&r.textContent&&t.push(r.textContent),nE(r)){const s=r.ariaHidden||r.hidden||r.style.display==="none",o=r.dataset.radixToastAnnounceExclude==="";if(!s)if(o){const a=r.dataset.radixToastAnnounceAlt;a&&t.push(a)}else t.push(...Pb(r))}}),t}function pl(e,t,n,{discrete:r}){const s=n.originalEvent.currentTarget,o=new CustomEvent(e,{bubbles:!0,cancelable:!0,detail:n});t&&s.addEventListener(e,t,{once:!0}),r?ub(s,o):s.dispatchEvent(o)}var mx=(e,t,n=0)=>{const r=Math.abs(e.x),s=Math.abs(e.y),o=r>s;return t==="left"||t==="right"?o&&r>n:!o&&s>n};function tE(e=()=>{}){const t=bn(e);rt(()=>{let n=0,r=0;return n=window.requestAnimationFrame(()=>r=window.requestAnimationFrame(t)),()=>{window.cancelAnimationFrame(n),window.cancelAnimationFrame(r)}},[t])}function nE(e){return e.nodeType===e.ELEMENT_NODE}function rE(e){const t=[],n=document.createTreeWalker(e,NodeFilter.SHOW_ELEMENT,{acceptNode:r=>{const s=r.tagName==="INPUT"&&r.type==="hidden";return r.disabled||r.hidden||s?NodeFilter.FILTER_SKIP:r.tabIndex>=0?NodeFilter.FILTER_ACCEPT:NodeFilter.FILTER_SKIP}});for(;n.nextNode();)t.push(n.currentNode);return t}function xd(e){const t=document.activeElement;return e.some(n=>n===t?!0:(n.focus(),document.activeElement!==t))}var sE=gb,Eb=yb,Tb=wb,Rb=bb,Ab=Sb,Mb=Nb,Ob=$m;function Ib(e){var t,n,r="";if(typeof e=="string"||typeof e=="number")r+=e;else if(typeof e=="object")if(Array.isArray(e)){var s=e.length;for(t=0;t<s;t++)e[t]&&(n=Ib(e[t]))&&(r&&(r+=" "),r+=n)}else for(n in e)e[n]&&(r&&(r+=" "),r+=n);return r}function Db(){for(var e,t,n=0,r="",s=arguments.length;n<s;n++)(e=arguments[n])&&(t=Ib(e))&&(r&&(r+=" "),r+=t);return r}const px=e=>typeof e=="boolean"?`${e}`:e===0?"0":e,gx=Db,cu=(e,t)=>n=>{var r;if((t==null?void 0:t.variants)==null)return gx(e,n==null?void 0:n.class,n==null?void 0:n.className);const{variants:s,defaultVariants:o}=t,a=Object.keys(s).map(u=>{const d=n==null?void 0:n[u],f=o==null?void 0:o[u];if(d===null)return null;const m=px(d)||px(f);return s[u][m]}),l=n&&Object.entries(n).reduce((u,d)=>{let[f,m]=d;return m===void 0||(u[f]=m),u},{}),c=t==null||(r=t.compoundVariants)===null||r===void 0?void 0:r.reduce((u,d)=>{let{class:f,className:m,...p}=d;return Object.entries(p).every(b=>{let[x,y]=b;return Array.isArray(y)?y.includes({...o,...l}[x]):{...o,...l}[x]===y})?[...u,f,m]:u},[]);return gx(e,a,c,n==null?void 0:n.class,n==null?void 0:n.className)};/**
41 * @license lucide-react v0.462.0 - ISC
42 *
43 * This source code is licensed under the ISC license.
44 * See the LICENSE file in the root directory of this source tree.
45 */const oE=e=>e.replace(/([a-z0-9])([A-Z])/g,"$1-$2").toLowerCase(),Lb=(...e)=>e.filter((t,n,r)=>!!t&&t.trim()!==""&&r.indexOf(t)===n).join(" ").trim();/**
46 * @license lucide-react v0.462.0 - ISC
47 *
48 * This source code is licensed under the ISC license.
49 * See the LICENSE file in the root directory of this source tree.
50 */var iE={xmlns:"http://www.w3.org/2000/svg",width:24,height:24,viewBox:"0 0 24 24",fill:"none",stroke:"currentColor",strokeWidth:2,strokeLinecap:"round",strokeLinejoin:"round"};/**
51 * @license lucide-react v0.462.0 - ISC
52 *
53 * This source code is licensed under the ISC license.
54 * See the LICENSE file in the root directory of this source tree.
55 */const aE=h.forwardRef(({color:e="currentColor",size:t=24,strokeWidth:n=2,absoluteStrokeWidth:r,className:s="",children:o,iconNode:a,...l},c)=>h.createElement("svg",{ref:c,...iE,width:t,height:t,stroke:e,strokeWidth:r?Number(n)*24/Number(t):n,className:Lb("lucide",s),...l},[...a.map(([u,d])=>h.createElement(u,d)),...Array.isArray(o)?o:[o]]));/**
56 * @license lucide-react v0.462.0 - ISC
57 *
58 * This source code is licensed under the ISC license.
59 * See the LICENSE file in the root directory of this source tree.
60 */const te=(e,t)=>
60{const n=h.forwardRef(({className:r,...s},o)=>h.createElement(aE,{ref:o,iconNode:t,className:Lb(`lucide-${oE(e)}`,r),...s}));return n.displayName=`${e}`,n};/**
61 * @license lucide-react v0.462.0 - ISC
62 *
63 * This source code is licensed under the ISC license.
64 * See the LICENSE file in the root directory of this source tree.
65 */const Fn=te("ArrowLeft",[["path",{d:"m12 19-7-7 7-7",key:"1l729n"}],["path",{d:"M19 12H5",key:"x3x0zl"}]]);/**
66 * @license lucide-react v0.462.0 - ISC
67 *
68 * This source code is licensed under the ISC license.
69 * See the LICENSE file in the root directory of this source tree.
70 */const lE=te("Bell",[["path",{d:"M6 8a6 6 0 0 1 12 0c0 7 3 9 3 9H3s3-2 3-9",key:"1qo2s2"}],["path",{d:"M10.3 21a1.94 1.94 0 0 0 3.4 0",key:"qgo35s"}]]);/**
71 * @license lucide-react v0.462.0 - ISC
72 *
73 * This source code is licensed under the ISC license.
74 * See the LICENSE file in the root directory of this source tree.
75 */const cE=te("Bike",[["circle",{cx:"18.5",cy:"17.5",r:"3.5",key:"15x4ox"}],["circle",{cx:"5.5",cy:"17.5",r:"3.5",key:"1noe27"}],["circle",{cx:"15",cy:"5",r:"1",key:"19l28e"}],["path",{d:"M12 17.5V14l-3-3 4-3 2 3h2",key:"1npguv"}]]);/**
76 * @license lucide-react v0.462.0 - ISC
77 *
78 * This source code is licensed under the ISC license.
79 * See the LICENSE file in the root directory of this source tree.
80 */const Mn=te("Check",[["path",{d:"M20 6 9 17l-5-5",key:"1gmf2c"}]]);/**
81 * @license lucide-react v0.462.0 - ISC
82 *
83 * This source code is licensed under the ISC license.
84 * See the LICENSE file in the root directory of this source tree.
85 */const uE=te("ChefHat",[["path",{d:"M17 21a1 1 0 0 0 1-1v-5.35c0-.457.316-.844.727-1.041a4 4 0 0 0-2.134-7.589 5 5 0 0 0-9.186 0 4 4 0 0 0-2.134 7.588c.411.198.727.585.727 1.041V20a1 1 0 0 0 1 1Z",key:"1qvrer"}],["path",{d:"M6 17h12",key:"1jwigz"}]]);/**
86 * @license lucide-react v0.462.0 - ISC
87 *
88 * This source code is licensed under the ISC license.
89 * See the LICENSE file in the root directory of this source tree.
90 */const Nc=te("ChevronDown",[["path",{d:"m6 9 6 6 6-6",key:"qrunsl"}]]);/**
91 * @license lucide-react v0.462.0 - ISC
92 *
93 * This source code is licensed under the ISC license.
94 * See the LICENSE file in the root directory of this source tree.
95 */const $s=te("ChevronRight",[["path",{d:"m9 18 6-6-6-6",key:"mthhwq"}]]);/**
96 * @license lucide-react v0.462.0 - ISC
97 *
98 * This source code is licensed under the ISC license.
99 * See the LICENSE file in the root directory of this source tree.
100 */const dE=te("ChevronUp",[["path",{d:"m18 15-6-6-6 6",key:"153udz"}]]);/**
101 * @license lucide-react v0.462.0 - ISC
102 *
103 * This source code is licensed under the ISC license.
104 * See the LICENSE file in the root directory of this source tree.
105 */const fE=te("CircleCheckBig",[["path",{d:"M21.801 10A10 10 0 1 1 17 3.335",key:"yps3ct"}],["path",{d:"m9 11 3 3L22 4",key:"1pflzl"}]]);/**
106 * @license lucide-react v0.462.0 - ISC
107 *
108 * This source code is licensed under the ISC license.
109 * See the LICENSE file in the root directory of this source tree.
110 */const _b=te("CircleCheck",[["circle",{cx:"12",cy:"12",r:"10",key:"1mglay"}],["path",{d:"m9 12 2 2 4-4",key:"dzmm74"}]]);/**
111 * @license lucide-react v0.462.0 - ISC
112 *
113 * This source code is licensed under the ISC license.
114 * See the LICENSE file in the root directory of this source tree.
115 */const hE=te("CircleX",[["circle",{cx:"12",cy:"12",r:"10",key:"1mglay"}],["path",{d:"m15 9-6 6",key:"1uzhvr"}],["path",{d:"m9 9 6 6",key:"z0biqf"}]]);/**
116 * @license lucide-react v0.462.0 - ISC
117 *
118 * This source code is licensed under the ISC license.
119 * See the LICENSE file in the root directory of this source tree.
120 */const mE=te("ClipboardList",[["rect",{width:"8",height:"4",x:"8",y:"2",rx:"1",ry:"1",key:"tgr4d6"}],["path",{d:"M16 4h2a2 2 0 0 1 2 2v14a2 2 0 0 1-2 2H6a2 2 0 0 1-2-2V6a2 2 0 0 1 2-2h2",key:"116196"}],["path",{d:"M12 11h4",key:"1jrz19"}],["path",{d:"M12 16h4",key:"n85exb"}],["path",{d:"M8 11h.01",key:"1dfujw"}],["path",{d:"M8 16h.01",key:"18s6g9"}]]);/**
121 * @license lucide-react v0.462.0 - ISC
122 *
123 * This source code is licensed under the ISC license.
124 * See the LICENSE file in the root directory of this source tree.
125 */const Xo=te("Clock",[["circle",{cx:"12",cy:"12",r:"10",key:"1mglay"}],["polyline",{points:"12 6 12 12 16 14",key:"68esgv"}]]);/**
126 * @license lucide-react v0.462.0 - ISC
127 *
128 * This source code is licensed under the ISC license.
129 * See the LICENSE file in the root directory of this source tree.
130 */const Bm=te("Copy",[["rect",{width:"14",height:"14",x:"8",y:"8",rx:"2",ry:"2",key:"17jyea"}],["path",{d:"M4 16c-1.1 0-2-.9-2-2V4c0-1.1.9-2 2-2h10c1.1 0 2 .9 2 2",key:"zix9uf"}]]);/**
131 * @license lucide-react v0.462.0 - ISC
132 *
133 * This source code is licensed under the ISC license.
134 * See the LICENSE file in the root directory of this source tree.
135 */const Zi=te("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"}]]);/**
136 * @license lucide-react v0.462.0 - ISC
137 *
138 * This source code is licensed under the ISC license.
139 * See the LICENSE file in the root directory of this source tree.
140 */const pE=te("Eye",[["path",{d:"M2.062 12.348a1 1 0 0 1 0-.696 10.75 10.75 0 0 1 19.876 0 1 1 0 0 1 0 .696 10.75 10.75 0 0 1-19.876 0",key:"1nclc0"}],["circle",{cx:"12",cy:"12",r:"3",key:"1v7zrd"}]]);/**
141 * @license lucide-react v0.462.0 - ISC
142 *
143 * This source code is licensed under the ISC license.
144 * See the LICENSE file in the root directory of this source tree.
145 */const Jf=te("Gift",[["rect",{x:"3",y:"8",width:"18",height:"4",rx:"1",key:"bkv52"}],["path",{d:"M12 8v13",key:"1c76mn"}],["path",{d:"M19 12v7a2 2 0 0 1-2 2H7a2 2 0 0 1-2-2v-7",key:"6wjy6b"}],["path",{d:"M7.5 8a2.5 2.5 0 0 1 0-5A4.8 8 0 0 1 12 8a4.8 8 0 0 1 4.5-5 2.5 2.5 0 0 1 0 5",key:"1ihvrl"}]]);/**
146 * @license lucide-react v0.462.0 - ISC
147 *
148 * This source code is licensed under the ISC license.
149 * See the LICENSE file in the root directory of this source tree.
150 */const gE=te("History",[["path",{d:"M3 12a9 9 0 1 0 9-9 9.75 9.75 0 0 0-6.74 2.74L3 8",key:"1357e3"}],["path",{d:"M3 3v5h5",key:"1xhq8a"}],["path",{d:"M12 7v5l4 2",key:"1fdv2h"}]]);/**
151 * @license lucide-react v0.462.0 - ISC
152 *
153 * This source code is licensed under the ISC license.
154 * See the LICENSE file in the root directory of this source tree.
155 */const xE=te("House",[["path",{d:"M15 21v-8a1 1 0 0 0-1-1h-4a1 1 0 0 0-1 1v8",key:"5wwlr5"}],["path",{d:"M3 10a2 2 0 0 1 .709-1.528l7-5.999a2 2 0 0 1 2.582 0l7 5.999A2 2 0 0 1 21 10v9a2 2 0 0 1-2 2H5a2 2 0 0 1-2-2z",key:"1d0kgt"}]]);/**
156 * @license lucide-react v0.462.0 - ISC
157 *
158 * This source code is licensed under the ISC license.
159 * See the LICENSE file in the root directory of this source tree.
160 */const yE=te("ImagePlus",[["path",{d:"M16 5h6",key:"1vod17"}],["path",{d:"M19 2v6",key:"4bpg5p"}],["path",{d:"M21 11.5V19a2 2 0 0 1-2 2H5a2 2 0 0 1-2-2V5a2 2 0 0 1 2-2h7.5",key:"1ue2ih"}],["path",{d:"m21 15-3.086-3.086a2 2 0 0 0-2.828 0L6 21",key:"1xmnt7"}],["circle",{cx:"9",cy:"9",r:"2",key:"af1f0g"}]]);/**
161 * @license lucide-react v0.462.0 - ISC
162 *
163 * This source code is licensed under the ISC license.
164 * See the LICENSE file in the root directory of this source tree.
165 */const vE=te("LoaderCircle",[["path",{d:"M21 12a9 9 0 1 1-6.219-8.56",key:"13zald"}]]);/**
166 * @license lucide-react v0.462.0 - ISC
167 *
168 * This source code is licensed under the ISC license.
169 * See the LICENSE file in the root directory of this source tree.
170 */const wE=te("LogOut",[["path",{d:"M9 21H5a2 2 0 0 1-2-2V5a2 2 0 0 1 2-2h4",key:"1uf3rs"}],["polyline",{points:"16 17 21 12 16 7",key:"1gabdz"}],["line",{x1:"21",x2:"9",y1:"12",y2:"12",key:"1uyos4"}]]);/**
171 * @license lucide-react v0.462.0 - ISC
172 *
173 * This source code is licensed under the ISC license.
174 * See the LICENSE file in the root directory of this source tree.
175 */const bE=te("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"}]]);/**
176 * @license lucide-react v0.462.0 - ISC
177 *
178 * This source code is licensed under the ISC license.
179 * See the LICENSE file in the root directory of this source tree.
180 */const er=te("MapPin",[["path",{d:"M20 10c0 4.993-5.539 10.193-7.399 11.799a1 1 0 0 1-1.202 0C9.539 20.193 4 14.993 4 10a8 8 0 0 1 16 0",key:"1r0f0z"}],["circle",{cx:"12",cy:"10",r:"3",key:"ilqhr7"}]]);/**
181 * @license lucide-react v0.462.0 - ISC
182 *
183 * This source code is licensed under the ISC license.
184 * See the LICENSE file in the root directory of this source tree.
185 */const Cc=te("Minus",[["path",{d:"M5 12h14",key:"1ays0h"}]]);/**
186 * @license lucide-react v0.462.0 - ISC
187 *
188 * This source code is licensed under the ISC license.
189 * See the LICENSE file in the root directory of this source tree.
190 */const SE=te("Moon",[["path",{d:"M12 3a6 6 0 0 0 9 9 9 9 0 1 1-9-9Z",key:"a7tn18"}]]);/**
191 * @license lucide-react v0.462.0 - ISC
192 *
193 * This source code is licensed under the ISC license.
194 * See the LICENSE file in the root directory of this source tree.
195 */const zm=te("Package",[["path",{d:"M11 21.73a2 2 0 0 0 2 0l7-4A2 2 0 0 0 21 16V8a2 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.73z",key:"1a0edw"}],["path",{d:"M12 22V12",key:"d0xqtd"}],["path",{d:"m3.3 7 7.703 4.734a2 2 0 0 0 1.994 0L20.7 7",key:"yx3hmr"}],["path",{d:"m7.5 4.27 9 5.15",key:"1c824w"}]]);/**
196 * @license lucide-react v0.462.0 - ISC
197 *
198 * This source code is licensed under the ISC license.
199 * See the LICENSE file in the root directory of this source tree.
200 */const xx=te("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"}]]);/**
201 * @license lucide-react v0.462.0 - ISC
202 *
203 * This source code is licensed under the ISC license.
204 * See the LICENSE file in the root directory of this source tree.
205 */const xn=te("Plus",[["path",{d:"M5 12h14",key:"1ays0h"}],["path",{d:"M12 5v14",key:"s699le"}]]);/**
206 * @license lucide-react v0.462.0 - ISC
207 *
208 * This source code is licensed under the ISC license.
209 * See the LICENSE file in the root directory of this source tree.
210 */const jE=te("RotateCcw",[["path",{d:"M3 12a9 9 0 1 0 9-9 9.75 9.75 0 0 0-6.74 2.74L3 8",key:"1357e3"}],["path",{d:"M3 3v5h5",key:"1xhq8a"}]]);/**
211 * @license lucide-react v0.462.0 - ISC
212 *
213 * This source code is licensed under the ISC license.
214 * See the LICENSE file in the root directory of this source tree.
215 */const yx=te("Search",[["circle",{cx:"11",cy:"11",r:"8",key:"4ej97u"}],["path",{d:"m21 21-4.3-4.3",key:"1qie3q"}]]);/**
216 * @license lucide-react v0.462.0 - ISC
217 *
218 * This source code is licensed under the ISC license.
219 * See the LICENSE file in the root directory of this source tree.
220 */const NE=te("Send",[["path",{d:"M14.536 21.686a.5.5 0 0 0 .937-.024l6.5-19a.496.496 0 0 0-.635-.635l-19 6.5a.5.5 0 0 0-.024.937l7.93 3.18a2 2 0 0 1 1.112 1.11z",key:"1ffxy3"}],["path",{d:"m21.854 2.147-10.94 10.939",key:"12cjpa"}]]);/**
221 * @license lucide-react v0.462.0 - ISC
222 *
223 * This source code is licensed under the ISC license.
224 * See the LICENSE file in the root directory of this source tree.
225 */const CE=te("Settings",[["path",{d:"M12.22 2h-.44a2 2 0 0 0-2 2v.18a2 2 0 0 1-1 1.73l-.43.25a2 2 0 0 1-2 0l-.15-.08a2 2 0 0 0-2.73.73l-.22.38a2 2 0 0 0 .73 2.73l.15.1a2 2 0 0 1 1 1.72v.51a2 2 0 0 1-1 1.74l-.15.09a2 2 0 0 0-.73 2.73l.22.38a2 2 0 0 0 2.73.73l.15-.08a2 2 0 0 1 2 0l.43.25a2 2 0 0 1 1 1.73V20a2 2 0 0 0 2 2h.44a2 2 0 0 0 2-2v-.18a2 2 0 0 1 1-1.73l.43-.25a2 2 0 0 1 2 0l.15.08a2 2 0 0 0 2.73-.73l.22-.39a2 2 0 0 0-.73-2.73l-.15-.08a2 2 0 0 1-1-1.74v-.5a2 2 0 0 1 1-1.74l.15-.09a2 2 0 0 0 .73-2.73l-.22-.38a2 2 0 0 0-2.73-.73l-.15.08a2 2 0 0 1-2 0l-.43-.25a2 2 0 0 1-1-1.73V4a2 2 0 0 0-2-2z",key:"1qme2f"}],["circle",{cx:"12",cy:"12",r:"3",key:"1v7zrd"}]]);/**
226 * @license lucide-react v0.462.0 - ISC
227 *
228 * This source code is licensed under the ISC license.
229 * See the LICENSE file in the root directory of this source tree.
230 */const Fb=te("Share2",[["circle",{cx:"18",cy:"5",r:"3",key:"gq8acd"}],["circle",{cx:"6",cy:"12",r:"3",key:"w7nqdw"}],["circle",{cx:"18",cy:"19",r:"3",key:"1xt0gg"}],["line",{x1:"8.59",x2:"15.42",y1:"13.51",y2:"17.49",key:"47mynk"}],["line",{x1:"15.41",x2:"8.59",y1:"6.51",y2:"10.49",key:"1n3mei"}]]);/**
231 * @license lucide-react v0.462.0 - ISC
232 *
233 * This source code is licensed under the ISC license.
234 * See the LICENSE file in the root directory of this source tree.
235 */const Um=te("ShoppingCart",[["circle",{cx:"8",cy:"21",r:"1",key:"jimo8o"}
235],["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"}]]);/**
236 * @license lucide-react v0.462.0 - ISC
237 *
238 * This source code is licensed under the ISC license.
239 * See the LICENSE file in the root directory of this source tree.
240 */const kE=te("Smartphone",[["rect",{width:"14",height:"20",x:"5",y:"2",rx:"2",ry:"2",key:"1yt0o3"}],["path",{d:"M12 18h.01",key:"mhygvu"}]]);/**
241 * @license lucide-react v0.462.0 - ISC
242 *
243 * This source code is licensed under the ISC license.
244 * See the LICENSE file in the root directory of this source tree.
245 */const PE=te("Sparkles",[["path",{d:"M9.937 15.5A2 2 0 0 0 8.5 14.063l-6.135-1.582a.5.5 0 0 1 0-.962L8.5 9.936A2 2 0 0 0 9.937 8.5l1.582-6.135a.5.5 0 0 1 .963 0L14.063 8.5A2 2 0 0 0 15.5 9.937l6.135 1.581a.5.5 0 0 1 0 .964L15.5 14.063a2 2 0 0 0-1.437 1.437l-1.582 6.135a.5.5 0 0 1-.963 0z",key:"4pj2yx"}],["path",{d:"M20 3v4",key:"1olli1"}],["path",{d:"M22 5h-4",key:"1gvqau"}],["path",{d:"M4 17v2",key:"vumght"}],["path",{d:"M5 18H3",key:"zchphs"}]]);/**
246 * @license lucide-react v0.462.0 - ISC
247 *
248 * This source code is licensed under the ISC license.
249 * See the LICENSE file in the root directory of this source tree.
250 */const ar=te("Star",[["path",{d:"M11.525 2.295a.53.53 0 0 1 .95 0l2.31 4.679a2.123 2.123 0 0 0 1.595 1.16l5.166.756a.53.53 0 0 1 .294.904l-3.736 3.638a2.123 2.123 0 0 0-.611 1.878l.882 5.14a.53.53 0 0 1-.771.56l-4.618-2.428a2.122 2.122 0 0 0-1.973 0L6.396 21.01a.53.53 0 0 1-.77-.56l.881-5.139a2.122 2.122 0 0 0-.611-1.879L2.16 9.795a.53.53 0 0 1 .294-.906l5.165-.755a2.122 2.122 0 0 0 1.597-1.16z",key:"r04s7s"}]]);/**
251 * @license lucide-react v0.462.0 - ISC
252 *
253 * This source code is licensed under the ISC license.
254 * See the LICENSE file in the root directory of this source tree.
255 */const Vb=te("Tag",[["path",{d:"M12.586 2.586A2 2 0 0 0 11.172 2H4a2 2 0 0 0-2 2v7.172a2 2 0 0 0 .586 1.414l8.704 8.704a2.426 2.426 0 0 0 3.42 0l6.58-6.58a2.426 2.426 0 0 0 0-3.42z",key:"vktsd0"}],["circle",{cx:"7.5",cy:"7.5",r:".5",fill:"currentColor",key:"kqv944"}]]);/**
256 * @license lucide-react v0.462.0 - ISC
257 *
258 * This source code is licensed under the ISC license.
259 * See the LICENSE file in the root directory of this source tree.
260 */const vx=te("Ticket",[["path",{d:"M2 9a3 3 0 0 1 0 6v2a2 2 0 0 0 2 2h16a2 2 0 0 0 2-2v-2a3 3 0 0 1 0-6V7a2 2 0 0 0-2-2H4a2 2 0 0 0-2 2Z",key:"qn84l0"}],["path",{d:"M13 5v2",key:"dyzc3o"}],["path",{d:"M13 17v2",key:"1ont0d"}],["path",{d:"M13 11v2",key:"1wjjxi"}]]);/**
261 * @license lucide-react v0.462.0 - ISC
262 *
263 * This source code is licensed under the ISC license.
264 * See the LICENSE file in the root directory of this source tree.
265 */const EE=te("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"}]]);/**
266 * @license lucide-react v0.462.0 - ISC
267 *
268 * This source code is licensed under the ISC license.
269 * See the LICENSE file in the root directory of this source tree.
270 */const TE=te("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"}]]);/**
271 * @license lucide-react v0.462.0 - ISC
272 *
273 * This source code is licensed under the ISC license.
274 * See the LICENSE file in the root directory of this source tree.
275 */const Zf=te("User",[["path",{d:"M19 21v-2a4 4 0 0 0-4-4H9a4 4 0 0 0-4 4v2",key:"975kel"}],["circle",{cx:"12",cy:"7",r:"4",key:"17ys0d"}]]);/**
276 * @license lucide-react v0.462.0 - ISC
277 *
278 * This source code is licensed under the ISC license.
279 * See the LICENSE file in the root directory of this source tree.
280 */const RE=te("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"}]]);/**
281 * @license lucide-react v0.462.0 - ISC
282 *
283 * This source code is licensed under the ISC license.
284 * See the LICENSE file in the root directory of this source tree.
285 */const AE=te("Vibrate",[["path",{d:"m2 8 2 2-2 2 2 2-2 2",key:"sv1b1"}],["path",{d:"m22 8-2 2 2 2-2 2 2 2",key:"101i4y"}
vendor: 8,689 bytes, lines 285-300
285],["rect",{width:"8",height:"14",x:"8",y:"5",rx:"1",key:"1oyrl4"}]]);/**
286 * @license lucide-react v0.462.0 - ISC
287 *
288 * This source code is licensed under the ISC license.
289 * See the LICENSE file in the root directory of this source tree.
290 */const ME=te("Volume2",[["path",{d:"M11 4.702a.705.705 0 0 0-1.203-.498L6.413 7.587A1.4 1.4 0 0 1 5.416 8H3a1 1 0 0 0-1 1v6a1 1 0 0 0 1 1h2.416a1.4 1.4 0 0 1 .997.413l3.383 3.384A.705.705 0 0 0 11 19.298z",key:"uqj9uw"}],["path",{d:"M16 9a5 5 0 0 1 0 6",key:"1q6k2b"}],["path",{d:"M19.364 18.364a9 9 0 0 0 0-12.728",key:"ijwkga"}]]);/**
291 * @license lucide-react v0.462.0 - ISC
292 *
293 * This source code is licensed under the ISC license.
294 * See the LICENSE file in the root directory of this source tree.
295 */const kc=te("Wallet",[["path",{d:"M19 7V4a1 1 0 0 0-1-1H5a2 2 0 0 0 0 4h15a1 1 0 0 1 1 1v4h-3a2 2 0 0 0 0 4h3a1 1 0 0 0 1-1v-2a1 1 0 0 0-1-1",key:"18etb6"}],["path",{d:"M3 5v14a2 2 0 0 0 2 2h15a1 1 0 0 0 1-1v-4",key:"xoc0q4"}]]);/**
296 * @license lucide-react v0.462.0 - ISC
297 *
298 * This source code is licensed under the ISC license.
299 * See the LICENSE file in the root directory of this source tree.
300 */const vt=te("X",[["path",{d:"M18 6 6 18",key:"1bl5f8"}],["path",{d:"m6 6 12 12",key:"d8bk6v"}]]),Wm="-",OE=e=>{const t=DE(e),{conflictingClassGroups:n,conflictingClassGroupModifiers:r}=e;return{getClassGroupId:a=>{const l=a.split(Wm);return l[0]===""&&l.length!==1&&l.shift(),$b(l,t)||IE(a)},getConflictingClassGroupIds:(a,l)=>{const c=n[a]||[];return l&&r[a]?[...c,...r[a]]:c}}},$b=(e,t)=>{var a;if(e.length===0)return t.classGroupId;const n=e[0],r=t.nextPart.get(n),s=r?$b(e.slice(1),r):void 0;if(s)return s;if(t.validators.length===0)return;const o=e.join(Wm);return(a=t.validators.find(({validator:l})=>l(o)))==null?void 0:a.classGroupId},wx=/^\[(.+)\]$/,IE=e=>{if(wx.test(e)){const t=wx.exec(e)[1],n=t==null?void 0:t.substring(0,t.indexOf(":"));if(n)return"arbitrary.."+n}},DE=e=>{const{theme:t,prefix:n}=e,r={nextPart:new Map,validators:[]};return _E(Object.entries(e.classGroups),n).forEach(([o,a])=>{eh(a,r,o,t)}),r},eh=(e,t,n,r)=>{e.forEach(s=>{if(typeof s=="string"){const o=s===""?t:bx(t,s);o.classGroupId=n;return}if(typeof s=="function"){if(LE(s)){eh(s(r),t,n,r);return}t.validators.push({validator:s,classGroupId:n});return}Object.entries(s).forEach(([o,a])=>{eh(a,bx(t,o),n,r)})})},bx=(e,t)=>{let n=e;return t.split(Wm).forEach(r=>{n.nextPart.has(r)||n.nextPart.set(r,{nextPart:new Map,validators:[]}),n=n.nextPart.get(r)}),n},LE=e=>e.isThemeGetter,_E=(e,t)=>t?e.map(([n,r])=>{const s=r.map(o=>typeof o=="string"?t+o:typeof o=="object"?Object.fromEntries(Object.entries(o).map(([a,l])=>[t+a,l])):o);return[n,s]}):e,FE=e=>{if(e<1)return{get:()=>{},set:()=>{}};let t=0,n=new Map,r=new Map;const s=(o,a)=>{n.set(o,a),t++,t>e&&(t=0,r=n,n=new Map)};return{get(o){let a=n.get(o);if(a!==void 0)return a;if((a=r.get(o))!==void 0)return s(o,a),a},set(o,a){n.has(o)?n.set(o,a):s(o,a)}}},Bb="!",VE=e=>{const{separator:t,experimentalParseClassName:n}=e,r=t.length===1,s=t[0],o=t.length,a=l=>{const c=[];let u=0,d=0,f;for(let y=0;y<l.length;y++){let w=l[y];if(u===0){if(w===s&&(r||l.slice(y,y+o)===t)){c.push(l.slice(d,y)),d=y+o;continue}if(w==="/"){f=y;continue}}w==="["?u++:w==="]"&&u--}const m=c.length===0?l:l.substring(d),p=m.startsWith(Bb),b=p?m.substring(1):m,x=f&&f>d?f-d:void 0;return{modifiers:c,hasImportantModifier:p,baseClassName:b,maybePostfixModifierPosition:x}};return n?l=>n({className:l,parseClassName:a}):a},$E=e=>{if(e.length<=1)return e;const t=[];let n=[];return e.forEach(r=>{r[0]==="["?(t.push(...n.sort(),r),n=[]):n.push(r)}),t.push(...n.sort()),t},BE=e=>({cache:FE(e.cacheSize),parseClassName:VE(e),...OE(e)}),zE=/\s+/,UE=(e,t)=>{const{parseClassName:n,getClassGroupId:r,getConflictingClassGroupIds:s}=t,o=[],a=e.trim().split(zE);let l="";for(let c=a.length-1;c>=0;c-=1){const u=a[c],{modifiers:d,hasImportantModifier:f,baseClassName:m,maybePostfixModifierPosition:p}=n(u);let b=!!p,x=r(b?m.substring(0,p):m);if(!x){if(!b){l=u+(l.length>0?" "+l:l);continue}if(x=r(m),!x){l=u+(l.length>0?" "+l:l);continue}b=!1}const y=$E(d).join(":"),w=f?y+Bb:y,g=w+x;if(o.includes(g))continue;o.push(g);const v=s(x,b);for(let S=0;S<v.length;++S){const j=v[S];o.push(w+j)}l=u+(l.length>0?" "+l:l)}return l};function WE(){let e=0,t,n,r="";for(;e<arguments.length;)(t=arguments[e++])&&(n=zb(t))&&(r&&(r+=" "),r+=n);return r}const zb=e=>{if(typeof e=="string")return e;let t,n="";for(let r=0;r<e.length;r++)e[r]&&(t=zb(e[r]))&&(n&&(n+=" "),n+=t);return n};function HE(e,...t){let n,r,s,o=a;function a(c){const u=t.reduce((d,f)=>f(d),e());return n=BE(u),r=n.cache.get,s=n.cache.set,o=l,l(c)}function l(c){const u=r(c);if(u)return u;const d=UE(c,n);return s(c,d),d}return function(){return o(WE.apply(null,arguments))}}const Ne=e=>{const t=n=>n[e]||[];return t.isThemeGetter=!0,t},Ub=/^\[(?:([a-z-]+):)?(.+)\]$/i,KE=/^\d+\/\d+$/,YE=new Set(["px","full","screen"]),GE=/^(\d+(\.\d+)?)?(xs|sm|md|lg|xl)$/,qE=/\d+(%|px|r?em|[sdl]?v([hwib]|min|max)|pt|pc|in|cm|mm|cap|ch|ex|r?lh|cq(w|h|i|b|min|max))|\b(calc|min|max|clamp)\(.+\)|^0$/,QE=/^(rgba?|hsla?|hwb|(ok)?(lab|lch))\(.+\)$/,XE=/^(inset_)?-?((\d+)?\.?(\d+)[a-z]+|0)_-?((\d+)?\.?(\d+)[a-z]+|0)/,JE=/^(url|image|image-set|cross-fade|element|(repeating-)?(linear|radial|conic)-gradient)\(.+\)$/,Yn=e=>Eo(e)||YE.has(e)||KE.test(e),Cr=e=>li(e,"length",iT),Eo=e=>!!e&&!Number.isNaN(Number(e)),yd=e=>li(e,"number",Eo),Ei=e=>!!e&&Number.isInteger(Number(e)),ZE=e=>e.endsWith("%")&&Eo(e.slice(0,-1)),ie=e=>Ub.test(e),kr=e=>GE.test(e),eT=new Set(["length","size","percentage"]),tT=e=>li(e,eT,Wb),nT=e=>li(e,"position",Wb),rT=new Set(["image","url"]),sT=e=>li(e,rT,lT),oT=e=>li(e,"",aT),Ti=()=>!0,li=(e,t,n)=>{const r=Ub.exec(e);return r?r[1]?typeof t=="string"?r[1]===t:t.has(r[1]):n(r[2]):!1},iT=e=>qE.test(e)&&!QE.test(e),Wb=()=>!1,aT=e=>XE.test(e),lT=e=>JE.test(e),cT=()=>{const e=Ne("colors"),t=Ne("spacing"),n=Ne("blur"),r=Ne("brightness"),s=Ne("borderColor"),o=Ne("borderRadius"),a=Ne("borderSpacing"),l=Ne("borderWidth"),c=Ne("contrast"),u=Ne("grayscale"),d=Ne("hueRotate"),f=Ne("invert"),m=Ne("gap"),p=Ne("gradientColorStops"),b=Ne("gradientColorStopPositions"),x=Ne("inset"),y=Ne("margin"),w=Ne("opacity"),g=Ne("padding"),v=Ne("saturate"),S=Ne("scale"),j=Ne("sepia"),C=Ne("skew"),P=Ne("space"),N=Ne("translate"),E=()=>["auto","contain","none"],k=()=>["auto","hidden","clip","visible","scroll"],R=()=>["auto",ie,t],M=()=>[ie,t],I=()=>["",Yn,Cr],O=()=>["auto",Eo,ie],H=()=>["bottom","center","left","left-bottom","left-top","right","right-bottom","right-top","top"],B=()=>["solid","dashed","dotted","double","none"],U=()=>["normal","multiply","screen","overlay","darken","lighten","color-dodge","color-burn","hard-light","soft-light","difference","exclusion","hue","saturation","color","luminosity"],T=()=>["start","end","center","between","around","evenly","stretch"],A=()=>["","0",ie],L=()=>["auto","avoid","all","avoid-page","page","left","right","column"],_=()=>[Eo,ie];return{cacheSize:500,separator:":",theme:{colors:[Ti],spacing:[Yn,Cr],blur:["none","",kr,ie],brightness:_(),borderColor:[e],borderRadius:["none","","full",kr,ie],borderSpacing:M(),borderWidth:I(),contrast:_(),grayscale:A(),hueRotate:_(),invert:A(),gap:M(),gradientColorStops:[e],gradientColorStopPositions:[ZE,Cr],inset:R(),margin:R(),opacity:_(),padding:M(),saturate:_(),scale:_(),sepia:A(),skew:_(),space:M(),translate:M()},classGroups:{aspect:[{aspect:["auto","square","video",ie]}],container:["container"],columns:[{columns:[kr]}],"break-after":[{"break-after":L()}],"break-before":[{"break-before":L()}],"break-inside":[{"break-inside":["auto","avoid","avoid-page","avoid-column"]}],"box-decoration":[{"box-decoration":["slice","clone"]}],box:[{box:["border","content"]}],display:["block","inline-block","inline","flex","inline-flex","table","inline-table","table-caption","table-cell","table-column","table-column-group","table-footer-group","table-header-group","table-row-group","table-row","flow-root","grid","inline-grid","contents","list-item","hidden"],float:[{float:["right","left","none","start","end"]}],clear:[{clear:["left","right","both","none","start","end"]}],isolation:["isolate","isolation-auto"],"object-fit":[{object:["contain","cover","fill","none","scale-down"]}],"object-position":[{object:[...H(),ie]}],overflow:[{overflow:k()}],"overflow-x":[{"overflow-x":k()}],"overflow-y":[{"overflow-y":k()}],overscroll:[{overscroll:E()}],"overscroll-x":[{"overscroll-x":E()}],"overscroll-y":[{"overscroll-y":E()}],position:["static","fixed","absolute","relative","sticky"],inset:[{inset:[x]}],"inset-x":[{"inset-x":[x]}],"inset-y":[{"inset-y":[x]}],start:[{start:[x]}],end:[{end:[x]}],top:[{top:[x]}
vendor: 9,947 bytes, line 300
300],right:[{right:[x]}],bottom:[{bottom:[x]}],left:[{left:[x]}],visibility:["visible","invisible","collapse"],z:[{z:["auto",Ei,ie]}],basis:[{basis:R()}],"flex-direction":[{flex:["row","row-reverse","col","col-reverse"]}],"flex-wrap":[{flex:["wrap","wrap-reverse","nowrap"]}],flex:[{flex:["1","auto","initial","none",ie]}],grow:[{grow:A()}],shrink:[{shrink:A()}],order:[{order:["first","last","none",Ei,ie]}],"grid-cols":[{"grid-cols":[Ti]}],"col-start-end":[{col:["auto",{span:["full",Ei,ie]},ie]}],"col-start":[{"col-start":O()}],"col-end":[{"col-end":O()}],"grid-rows":[{"grid-rows":[Ti]}],"row-start-end":[{row:["auto",{span:[Ei,ie]},ie]}],"row-start":[{"row-start":O()}],"row-end":[{"row-end":O()}],"grid-flow":[{"grid-flow":["row","col","dense","row-dense","col-dense"]}],"auto-cols":[{"auto-cols":["auto","min","max","fr",ie]}],"auto-rows":[{"auto-rows":["auto","min","max","fr",ie]}],gap:[{gap:[m]}],"gap-x":[{"gap-x":[m]}],"gap-y":[{"gap-y":[m]}],"justify-content":[{justify:["normal",...T()]}],"justify-items":[{"justify-items":["start","end","center","stretch"]}],"justify-self":[{"justify-self":["auto","start","end","center","stretch"]}],"align-content":[{content:["normal",...T(),"baseline"]}],"align-items":[{items:["start","end","center","baseline","stretch"]}],"align-self":[{self:["auto","start","end","center","stretch","baseline"]}],"place-content":[{"place-content":[...T(),"baseline"]}],"place-items":[{"place-items":["start","end","center","baseline","stretch"]}],"place-self":[{"place-self":["auto","start","end","center","stretch"]}],p:[{p:[g]}],px:[{px:[g]}],py:[{py:[g]}],ps:[{ps:[g]}],pe:[{pe:[g]}],pt:[{pt:[g]}],pr:[{pr:[g]}],pb:[{pb:[g]}],pl:[{pl:[g]}],m:[{m:[y]}],mx:[{mx:[y]}],my:[{my:[y]}],ms:[{ms:[y]}],me:[{me:[y]}],mt:[{mt:[y]}],mr:[{mr:[y]}],mb:[{mb:[y]}],ml:[{ml:[y]}],"space-x":[{"space-x":[P]}],"space-x-reverse":["space-x-reverse"],"space-y":[{"space-y":[P]}],"space-y-reverse":["space-y-reverse"],w:[{w:["auto","min","max","fit","svw","lvw","dvw",ie,t]}],"min-w":[{"min-w":[ie,t,"min","max","fit"]}],"max-w":[{"max-w":[ie,t,"none","full","min","max","fit","prose",{screen:[kr]},kr]}],h:[{h:[ie,t,"auto","min","max","fit","svh","lvh","dvh"]}],"min-h":[{"min-h":[ie,t,"min","max","fit","svh","lvh","dvh"]}],"max-h":[{"max-h":[ie,t,"min","max","fit","svh","lvh","dvh"]}],size:[{size:[ie,t,"auto","min","max","fit"]}],"font-size":[{text:["base",kr,Cr]}],"font-smoothing":["antialiased","subpixel-antialiased"],"font-style":["italic","not-italic"],"font-weight":[{font:["thin","extralight","light","normal","medium","semibold","bold","extrabold","black",yd]}],"font-family":[{font:[Ti]}],"fvn-normal":["normal-nums"],"fvn-ordinal":["ordinal"],"fvn-slashed-zero":["slashed-zero"],"fvn-figure":["lining-nums","oldstyle-nums"],"fvn-spacing":["proportional-nums","tabular-nums"],"fvn-fraction":["diagonal-fractions","stacked-fractions"],tracking:[{tracking:["tighter","tight","normal","wide","wider","widest",ie]}],"line-clamp":[{"line-clamp":["none",Eo,yd]}],leading:[{leading:["none","tight","snug","normal","relaxed","loose",Yn,ie]}],"list-image":[{"list-image":["none",ie]}],"list-style-type":[{list:["none","disc","decimal",ie]}],"list-style-position":[{list:["inside","outside"]}],"placeholder-color":[{placeholder:[e]}],"placeholder-opacity":[{"placeholder-opacity":[w]}],"text-alignment":[{text:["left","center","right","justify","start","end"]}],"text-color":[{text:[e]}],"text-opacity":[{"text-opacity":[w]}],"text-decoration":["underline","overline","line-through","no-underline"],"text-decoration-style":[{decoration:[...B(),"wavy"]}],"text-decoration-thickness":[{decoration:["auto","from-font",Yn,Cr]}],"underline-offset":[{"underline-offset":["auto",Yn,ie]}],"text-decoration-color":[{decoration:[e]}],"text-transform":["uppercase","lowercase","capitalize","normal-case"],"text-overflow":["truncate","text-ellipsis","text-clip"],"text-wrap":[{text:["wrap","nowrap","balance","pretty"]}],indent:[{indent:M()}],"vertical-align":[{align:["baseline","top","middle","bottom","text-top","text-bottom","sub","super",ie]}],whitespace:[{whitespace:["normal","nowrap","pre","pre-line","pre-wrap","break-spaces"]}],break:[{break:["normal","words","all","keep"]}],hyphens:[{hyphens:["none","manual","auto"]}],content:[{content:["none",ie]}],"bg-attachment":[{bg:["fixed","local","scroll"]}],"bg-clip":[{"bg-clip":["border","padding","content","text"]}],"bg-opacity":[{"bg-opacity":[w]}],"bg-origin":[{"bg-origin":["border","padding","content"]}],"bg-position":[{bg:[...H(),nT]}],"bg-repeat":[{bg:["no-repeat",{repeat:["","x","y","round","space"]}]}],"bg-size":[{bg:["auto","cover","contain",tT]}],"bg-image":[{bg:["none",{"gradient-to":["t","tr","r","br","b","bl","l","tl"]},sT]}],"bg-color":[{bg:[e]}],"gradient-from-pos":[{from:[b]}],"gradient-via-pos":[{via:[b]}],"gradient-to-pos":[{to:[b]}],"gradient-from":[{from:[p]}],"gradient-via":[{via:[p]}],"gradient-to":[{to:[p]}],rounded:[{rounded:[o]}],"rounded-s":[{"rounded-s":[o]}],"rounded-e":[{"rounded-e":[o]}],"rounded-t":[{"rounded-t":[o]}],"rounded-r":[{"rounded-r":[o]}],"rounded-b":[{"rounded-b":[o]}],"rounded-l":[{"rounded-l":[o]}],"rounded-ss":[{"rounded-ss":[o]}],"rounded-se":[{"rounded-se":[o]}],"rounded-ee":[{"rounded-ee":[o]}],"rounded-es":[{"rounded-es":[o]}],"rounded-tl":[{"rounded-tl":[o]}],"rounded-tr":[{"rounded-tr":[o]}],"rounded-br":[{"rounded-br":[o]}],"rounded-bl":[{"rounded-bl":[o]}],"border-w":[{border:[l]}],"border-w-x":[{"border-x":[l]}],"border-w-y":[{"border-y":[l]}],"border-w-s":[{"border-s":[l]}],"border-w-e":[{"border-e":[l]}],"border-w-t":[{"border-t":[l]}],"border-w-r":[{"border-r":[l]}],"border-w-b":[{"border-b":[l]}],"border-w-l":[{"border-l":[l]}],"border-opacity":[{"border-opacity":[w]}],"border-style":[{border:[...B(),"hidden"]}],"divide-x":[{"divide-x":[l]}],"divide-x-reverse":["divide-x-reverse"],"divide-y":[{"divide-y":[l]}],"divide-y-reverse":["divide-y-reverse"],"divide-opacity":[{"divide-opacity":[w]}],"divide-style":[{divide:B()}],"border-color":[{border:[s]}],"border-color-x":[{"border-x":[s]}],"border-color-y":[{"border-y":[s]}],"border-color-s":[{"border-s":[s]}],"border-color-e":[{"border-e":[s]}],"border-color-t":[{"border-t":[s]}],"border-color-r":[{"border-r":[s]}],"border-color-b":[{"border-b":[s]}],"border-color-l":[{"border-l":[s]}],"divide-color":[{divide:[s]}],"outline-style":[{outline:["",...B()]}],"outline-offset":[{"outline-offset":[Yn,ie]}],"outline-w":[{outline:[Yn,Cr]}],"outline-color":[{outline:[e]}],"ring-w":[{ring:I()}],"ring-w-inset":["ring-inset"],"ring-color":[{ring:[e]}],"ring-opacity":[{"ring-opacity":[w]}],"ring-offset-w":[{"ring-offset":[Yn,Cr]}],"ring-offset-color":[{"ring-offset":[e]}],shadow:[{shadow:["","inner","none",kr,oT]}],"shadow-color":[{shadow:[Ti]}],opacity:[{opacity:[w]}],"mix-blend":[{"mix-blend":[...U(),"plus-lighter","plus-darker"]}],"bg-blend":[{"bg-blend":U()}],filter:[{filter:["","none"]}],blur:[{blur:[n]}],brightness:[{brightness:[r]}],contrast:[{contrast:[c]}],"drop-shadow":[{"drop-shadow":["","none",kr,ie]}],grayscale:[{grayscale:[u]}],"hue-rotate":[{"hue-rotate":[d]}],invert:[{invert:[f]}],saturate:[{saturate:[v]}],sepia:[{sepia:[j]}],"backdrop-filter":[{"backdrop-filter":["","none"]}],"backdrop-blur":[{"backdrop-blur":[n]}],"backdrop-brightness":[{"backdrop-brightness":[r]}],"backdrop-contrast":[{"backdrop-contrast":[c]}],"backdrop-grayscale":[{"backdrop-grayscale":[u]}],"backdrop-hue-rotate":[{"backdrop-hue-rotate":[d]}],"backdrop-invert":[{"backdrop-invert":[f]}],"backdrop-opacity":[{"backdrop-opacity":[w]}],"backdrop-saturate":[{"backdrop-saturate":[v]}],"backdrop-sepia":[{"backdrop-sepia":[j]}],"border-collapse":[{border:["collapse","separate"]}],"border-spacing":[{"border-spacing":[a]}],"border-spacing-x":[{"border-spacing-x":[a]}],"border-spacing-y":[{"border-spacing-y":[a]}],"table-layout":[{table:["auto","fixed"]}],caption:[{caption:["top","bottom"]}],transition:[{transition:["none","all","","colors","opacity","shadow","transform",ie]}],duration:[{duration:_()}],ease:[{ease:["linear","in","out","in-out",ie]}],delay:[{delay:_()}],animate:[{animate:["none","spin","ping","pulse","bounce",ie]}],transform:[{transform:["","gpu","none"]}],scale:[{scale:[S]}],"scale-x":[{"scale-x":[S]}],"scale-y":[{"scale-y":[S]}],rotate:[{rotate:[Ei,ie]}],"translate-x":[{"translate-x":[N]}],"translate-y":[{"translate-y":[N]}],"skew-x":[{"skew-x":[C]}],"skew-y":[{"skew-y":[C]}],"transform-origin":[{origin:["center","top","top-right","right","bottom-right","bottom","bottom-left","left","top-left",ie]}],accent:[{accent:["auto",e]}],appearance:[{appearance:["none","auto"]}],cursor:[{cursor:["auto","default","pointer","wait","text","move","help","not-allowed","none","context-menu","progress","cell","crosshair","vertical-text","alias","copy","no-drop","grab","grabbing","all-scroll","col-resize","row-resize","n-resize","e-resize","s-resize","w-resize","ne-resize","nw-resize","se-resize","sw-resize","ew-resize","ns-resize","nesw-resize","nwse-resize","zoom-in","zoom-out",ie]}],"caret-color":[{caret:[e]}],"pointer-events":[{"pointer-events":["none","auto"]}],resize:[{resize:["none","y","x",""]}],"scroll-behavior":[{scroll:["auto","smooth"]}],"scroll-m":[{"scroll-m":M()}],"scroll-mx":[{"scroll-mx":M()}],"scroll-my":[{"scroll-my":M()}],"scroll-ms":[{"scroll-ms":M()}],"scroll-me":[{"scroll-me":M()}],"scroll-mt":[{"scroll-mt":M()}],"scroll-mr":[{"scroll-mr":M()}],"scroll-mb":[{"scroll-mb":M()}],"scroll-ml":[{"scroll-ml":M()}],"scroll-p":[{"scroll-p":M()}],"scroll-px":[{"scroll-px":M()}],"scroll-py":[{"scroll-py":M()}],"scroll-ps":[{"scroll-ps":M()}],"scroll-pe":[{"scroll-pe":M()}],"scroll-pt":[{"scroll-pt":M()}],"scroll-pr":[{"scroll-pr":M()}],"scroll-pb":[{"scroll-pb":M()}],"scroll-pl":[{"scroll-pl":M()}],"snap-align":[{snap:["start","end","center","align-none"]}],"snap-stop":[{snap:["normal","always"]}],"snap-type":[{snap:["none","x","y","both"]}],"snap-strictness":[{snap:["mandatory","proximity"]}
vendor: 4,642 bytes, line 300
300],touch:[{touch:["auto","none","manipulation"]}],"touch-x":[{"touch-pan":["x","left","right"]}],"touch-y":[{"touch-pan":["y","up","down"]}],"touch-pz":["touch-pinch-zoom"],select:[{select:["none","text","all","auto"]}],"will-change":[{"will-change":["auto","scroll","contents","transform",ie]}],fill:[{fill:[e,"none"]}],"stroke-w":[{stroke:[Yn,Cr,yd]}],stroke:[{stroke:[e,"none"]}],sr:["sr-only","not-sr-only"],"forced-color-adjust":[{"forced-color-adjust":["auto","none"]}]},conflictingClassGroups:{overflow:["overflow-x","overflow-y"],overscroll:["overscroll-x","overscroll-y"],inset:["inset-x","inset-y","start","end","top","right","bottom","left"],"inset-x":["right","left"],"inset-y":["top","bottom"],flex:["basis","grow","shrink"],gap:["gap-x","gap-y"],p:["px","py","ps","pe","pt","pr","pb","pl"],px:["pr","pl"],py:["pt","pb"],m:["mx","my","ms","me","mt","mr","mb","ml"],mx:["mr","ml"],my:["mt","mb"],size:["w","h"],"font-size":["leading"],"fvn-normal":["fvn-ordinal","fvn-slashed-zero","fvn-figure","fvn-spacing","fvn-fraction"],"fvn-ordinal":["fvn-normal"],"fvn-slashed-zero":["fvn-normal"],"fvn-figure":["fvn-normal"],"fvn-spacing":["fvn-normal"],"fvn-fraction":["fvn-normal"],"line-clamp":["display","overflow"],rounded:["rounded-s","rounded-e","rounded-t","rounded-r","rounded-b","rounded-l","rounded-ss","rounded-se","rounded-ee","rounded-es","rounded-tl","rounded-tr","rounded-br","rounded-bl"],"rounded-s":["rounded-ss","rounded-es"],"rounded-e":["rounded-se","rounded-ee"],"rounded-t":["rounded-tl","rounded-tr"],"rounded-r":["rounded-tr","rounded-br"],"rounded-b":["rounded-br","rounded-bl"],"rounded-l":["rounded-tl","rounded-bl"],"border-spacing":["border-spacing-x","border-spacing-y"],"border-w":["border-w-s","border-w-e","border-w-t","border-w-r","border-w-b","border-w-l"],"border-w-x":["border-w-r","border-w-l"],"border-w-y":["border-w-t","border-w-b"],"border-color":["border-color-s","border-color-e","border-color-t","border-color-r","border-color-b","border-color-l"],"border-color-x":["border-color-r","border-color-l"],"border-color-y":["border-color-t","border-color-b"],"scroll-m":["scroll-mx","scroll-my","scroll-ms","scroll-me","scroll-mt","scroll-mr","scroll-mb","scroll-ml"],"scroll-mx":["scroll-mr","scroll-ml"],"scroll-my":["scroll-mt","scroll-mb"],"scroll-p":["scroll-px","scroll-py","scroll-ps","scroll-pe","scroll-pt","scroll-pr","scroll-pb","scroll-pl"],"scroll-px":["scroll-pr","scroll-pl"],"scroll-py":["scroll-pt","scroll-pb"],touch:["touch-x","touch-y","touch-pz"],"touch-x":["touch"],"touch-y":["touch"],"touch-pz":["touch"]},conflictingClassGroupModifiers:{"font-size":["leading"]}}},uT=HE(cT);function Y(...e){return uT(Db(e))}const dT=sE,Hb=h.forwardRef(({className:e,...t},n)=>i.jsx(Eb,{ref:n,className:Y("fixed top-0 z-[100] flex max-h-screen w-full flex-col-reverse p-4 sm:bottom-0 sm:right-0 sm:top-auto sm:flex-col md:max-w-[420px]",e),...t}));Hb.displayName=Eb.displayName;const fT=cu("group pointer-events-auto relative flex w-full items-center justify-between space-x-4 overflow-hidden rounded-md border p-6 pr-8 shadow-lg transition-all data-[swipe=cancel]:translate-x-0 data-[swipe=end]:translate-x-[var(--radix-toast-swipe-end-x)] data-[swipe=move]:translate-x-[var(--radix-toast-swipe-move-x)] data-[swipe=move]:transition-none data-[state=open]:animate-in data-[state=closed]:animate-out data-[swipe=end]:animate-out data-[state=closed]:fade-out-80 data-[state=closed]:slide-out-to-right-full data-[state=open]:slide-in-from-top-full data-[state=open]:sm:slide-in-from-bottom-full",{variants:{variant:{default:"border bg-background text-foreground",destructive:"destructive group border-destructive bg-destructive text-destructive-foreground"}},defaultVariants:{variant:"default"}}),Kb=h.forwardRef(({className:e,variant:t,...n},r)=>i.jsx(Tb,{ref:r,className:Y(fT({variant:t}),e),...n}));Kb.displayName=Tb.displayName;const hT=h.forwardRef(({className:e,...t},n)=>i.jsx(Mb,{ref:n,className:Y("inline-flex h-8 shrink-0 items-center justify-center rounded-md border bg-transparent px-3 text-sm font-medium ring-offset-background transition-colors group-[.destructive]:border-muted/40 hover:bg-secondary group-[.destructive]:hover:border-destructive/30 group-[.destructive]:hover:bg-destructive group-[.destructive]:hover:text-destructive-foreground focus:outline-none focus:ring-2 focus:ring-ring focus:ring-offset-2 group-[.destructive]:focus:ring-destructive disabled:pointer-events-none disabled:opacity-50",e),...t}));hT.displayName=Mb.displayName;const Yb=h.forwardRef(({className:e,...t},n)=>i.jsx(Ob,{ref:n,className:Y("absolute right-2 top-2 rounded-md p-1 text-foreground
300/50 opacity-0 transition-opacity group-hover:opacity-100 group-[.destructive]:text-red-300 hover:text-foreground group-[.destructive]:hover:text-red-50 focus:opacity-100 focus:outline-none focus:ring-2 group-[.destructive]:focus:ring-red-400 group-[.destructive]:focus:ring-offset-red-600",e),"toast-close":"",...t,children:i.jsx(vt,{className:"h-4 w-4"})}));Yb.displayName=Ob.displayName;const Gb=h.forwardRef(({className:e,...t},n)=>i.jsx(Rb,{ref:n,className:Y("text-sm font-semibold",e),...t}));Gb.displayName=Rb.displayName;const qb=h.forwardRef(({className:e,...t},n)=>i.jsx(Ab,{ref:n,className:Y("text-sm opacity-90",e),...t}));qb.displayName=Ab.displayName;function mT(){const{toasts:e}=hP();return i.jsxs(dT,{children:[e.map(function({id:t,title:n,description:r,action:s,...o}){return i.jsxs(Kb,{...o,children:[i.jsxs("div",{className:"grid gap-1",children:[n&&i.jsx(Gb,{children:n}),r&&i.jsx(qb,{children:r})]}),s,i.jsx(Yb,{})]},t)}),i.jsx(Hb,{})]})}var Sx=["light","dark"],pT="(prefers-color-scheme: dark)",gT=h.createContext(void 0),xT={setTheme:e=>{},themes:[]},yT=()=>{var e;return(e=h.useContext(gT))!=null?e:xT};h.memo(({forcedTheme:e,storageKey:t,attribute:n,enableSystem:r,enableColorScheme:s,defaultTheme:o,value:a,attrs:l,nonce:c})=>{let u=o==="system",d=n==="class"?`var d=document.documentElement,c=d.classList;${`c.remove(${l.map(b=>`'${b}'`).join(",")})`};`:`var d=document.documentElement,n='${n}',s='setAttribute';`,f=s?Sx.includes(o)&&o?`if(e==='light'||e==='dark'||!e)d.style.colorScheme=e||'${o}'`:"if(e==='light'||e==='dark')d.style.colorScheme=e":"",m=(b,x=!1,y=!0)=>{let w=a?a[b]:b,g=x?b+"|| ''":`'${w}'`,v="";return s&&y&&!x&&Sx.includes(b)&&(v+=`d.style.colorScheme = '${b}';`),n==="class"?x||w?v+=`c.add(${g})`:v+="null":w&&(v+=`d[s](n,${g})`),v},p=e?`!function(){${d}${m(e)}}()`:r?`!function(){try{${d}var e=localStorage.getItem('${t}');if('system'===e||(!e&&${u})){var t='${pT}',m=window.matchMedia(t);if(m.media!==t||m.matches){${m("dark")}}else{${m("light")}}}else if(e){${a?`var x=${JSON.stringify(a)};`:""}${m(a?"x[e]":"e",!0)}}${u?"":"else{"+m(o,!1,!1)+"}"}${f}}catch(e){}}()`:`!function(){try{${d}var e=localStorage.getItem('${t}');if(e){${a?`var x=${JSON.stringify(a)};`:""}${m(a?"x[e]":"e",!0)}}else{${m(o,!1,!1)};}${f}}catch(t){}}();`;return h.createElement("script",{nonce:c,dangerouslySetInnerHTML:{__html:p}})});var vT=e=>{switch(e){case"success":return ST;case"info":return NT;case"warning":return jT;case"error":return CT;default:return null}},wT=Array(12).fill(0),bT=({visible:e,className:t})=>W.createElement("div",{className:["sonner-loading-wrapper",t].filter(Boolean).join(" "),"data-visible":e},W.createElement("div",{className:"sonner-spinner"},wT.map((n,r)=>W.createElement("div",{className:"sonner-loading-bar",key:`spinner-bar-${r}`})))),ST=W.createElement("svg",{xmlns:"http://www.w3.org/2000/svg",viewBox:"0 0 20 20",fill:"currentColor",height:"20",width:"20"},W.createElement("path",{fillRule:"evenodd",d:"M10 18a8 8 0 100-16 8 8 0 000 16zm3.857-9.809a.75.75 0 00-1.214-.882l-3.483 4.79-1.88-1.88a.75.75 0 10-1.06 1.061l2.5 2.5a.75.75 0 001.137-.089l4-5.5z",clipRule:"evenodd"})),jT=W.createElement("svg",{xmlns:"http://www.w3.org/2000/svg",viewBox:"0 0 24 24",fill:"currentColor",height:"20",width:"20"},W.createElement("path",{fillRule:"evenodd",d:"M9.401 3.003c1.155-2 4.043-2 5.197 0l7.355 12.748c1.154 2-.29 4.5-2.599 4.5H4.645c-2.309 0-3.752-2.5-2.598-4.5L9.4 3.003zM12 8.25a.75.75 0 01.75.75v3.75a.75.75 0 01-1.5 0V9a.75.75 0 01.75-.75zm0 8.25a.75.75 0 100-1.5.75.75 0 000 1.5z",clipRule:"evenodd"})),NT=W.createElement("svg",{xmlns:"http://www.w3.org/2000/svg",viewBox:"0 0 20 20",fill:"currentColor",height:"20",width:"20"},W.createElement("path",{fillRule:"evenodd",d:"M18 10a8 8 0 11-16 0 8 8 0 0116 0zm-7-4a1 1 0 11-2 0 1 1 0 012 0zM9 9a.75.75 0 000 1.5h.253a.25.25 0 01.244.304l-.459 2.066A1.75 1.75 0 0010.747 15H11a.75.75 0 000-1.5h-.253a.25.25 0 01-.244-.304l.459-2.066A1.75 1.75 0 009.253 9H9z",clipRule:"evenodd"})),CT=W.createElement("svg",{xmlns:"http://www.w3.org/2000/svg",viewBox:"0 0 20 20",fill:"currentColor",height:"20",width:"20"},W.createElement("path",{fillRule:"evenodd",d:"M18 10a8 8 0 11-16 0 8 8 0 0116 0zm-8-5a.75.75 0 01.75.75v4.5a.75.75 0 01-1.5 0v-4.5A.75.75 0 0110 5zm0 10a1 1 0 100-2 1 1 0 000 2z",clipRule:"evenodd"})),kT=W.createElement("svg",{xmlns:"http://www.w3.org/2000/svg",width:"12",height:"12",viewBox:"0 0 24 24",fill:"none",stroke:"currentColor",strokeWidth:"1.5",strokeLinecap:"round",strokeLinejoin:"round"},W.createElement("line",{x1:"18",y1:"6",x2:"6",y2:"18"}),W.createElement("line",{x1:"6",y1:"6",x2:"18",y2:"18"})),PT=()=>{let[e,t]=W.useState(document.hidden);return W.useEffect(()=>{let n=()=>{t(document.hidden)};
300return document.addEventListener("visibilitychange",n),()=>window.removeEventListener("visibilitychange",n)},[]),e},th=1,ET=class{constructor(){this.subscribe=e=>(this.subscribers.push(e),()=>{let t=this.subscribers.indexOf(e);this.subscribers.splice(t,1)}),this.publish=e=>{this.subscribers.forEach(t=>t(e))},this.addToast=e=>{this.publish(e),this.toasts=[...this.toasts,e]},this.create=e=>{var t;let{message:n,...r}=e,s=typeof(e==null?void 0:e.id)=="number"||((t=e.id)==null?void 0:t.length)>0?e.id:th++,o=this.toasts.find(l=>l.id===s),a=e.dismissible===void 0?!0:e.dismissible;return this.dismissedToasts.has(s)&&this.dismissedToasts.delete(s),o?this.toasts=this.toasts.map(l=>l.id===s?(this.publish({...l,...e,id:s,title:n}),{...l,...e,id:s,dismissible:a,title:n}):l):this.addToast({title:n,...r,dismissible:a,id:s}),s},this.dismiss=e=>(this.dismissedToasts.add(e),e||this.toasts.forEach(t=>{this.subscribers.forEach(n=>n({id:t.id,dismiss:!0}))}),this.subscribers.forEach(t=>t({id:e,dismiss:!0})),e),this.message=(e,t)=>this.create({...t,message:e}),this.error=(e,t)=>this.create({...t,message:e,type:"error"}),this.success=(e,t)=>this.create({...t,type:"success",message:e}),this.info=(e,t)=>this.create({...t,type:"info",message:e}),this.warning=(e,t)=>this.create({...t,type:"warning",message:e}),this.loading=(e,t)=>
300this.create({...t,type:"loading",message:e}),this.promise=(e,t)=>{if(!t)return;let n;t.loading!==void 0&&(n=this.create({...t,promise:e,type:"loading",message:t.loading,description:typeof t.description!="function"?t.description:void 0}));let r=e instanceof Promise?e:e(),s=n!==void 0,o,a=r.then(async c=>{if(o=["resolve",c],W.isValidElement(c))s=!1,this.create({id:n,type:"default",message:c});else if(RT(c)&&!c.ok){s=!1;let u=typeof t.error=="function"?await t.error(`HTTP error! status: ${c.status}`):t.error,d=typeof t.description=="function"?await t.description(`HTTP error! status: ${c.status}`):t.description;this.create({id:n,type:"error",message:u,description:d})}else if(t.success!==void 0){s=!1;let u=typeof t.success=="function"?await t.success(c):t.success,d=typeof t.description=="function"?await t.description(c):t.description;this.create({id:n,type:"success",message:u,description:d})}}).catch(async c=>{if(o=["reject",c],t.error!==void 0){s=!1;let u=typeof t.error=="function"?await t.error(c):t.error,d=typeof t.description=="function"?await t.description(c):t.description;this.create({id:n,type:"error",message:u,description:d})}}).finally(()=>{var c;s&&(this.dismiss(n),n=void 0),(c=t.finally)==null||c.call(t)}),l=()=>new Promise((c,u)=>a.then(()=>o[0]==="reject"?u(o[1]):c(o[1])).catch(u));return typeof n!="string"&&typeof n!="number"?{unwrap:l}:Object.assign(n,{unwrap:l})},this.custom=(e,t)=>{let n=(t==null?void 0:t.id)||th++;return this.create({jsx:e(n),id:n,...t}),n},this.getActiveToasts=()=>this.toasts.filter(e=>!this.dismissedToasts.has(e.id)),this.subscribers=[],this.toasts=[],this.dismissedToasts=new Set}},jt=new ET,TT=(e,t)=>{let n=(t==null?void 0:t.id)||th++;return jt.addToast({title:e,...t,id:n}),n},RT=e=>e&&typeof e=="object"&&"ok"in e&&typeof e.ok=="boolean"&&"status"in e&&typeof e.status=="number",AT=TT,MT=()=>jt.toasts,OT=()=>jt.getActiveToasts(),K=Object.assign(AT,{success:jt.success,info:jt.info,warning:jt.warning,error:jt.error,custom:jt.custom,message:jt.message,promise:jt.promise,dismiss:jt.dismiss,loading:jt.loading},{getHistory:MT,getToasts:OT});function IT(e,{insertAt:t}={}){if(typeof document>"u")return;let n=document.head||document.getElementsByTagName("head")[0],r=document.createElement("style");r.type="text/css",t==="top"&&n.firstChild?n.insertBefore(r,n.firstChild):n.appendChild(r),r.styleSheet?r.styleSheet.cssText=e:r.appendChild(document.createTextNode(e))}IT(`:where(html[dir="ltr"]),:where([data-sonner-toaster][dir="ltr"]){--toast-icon-margin-start: -3px;--toast-icon-margin-end: 4px;--toast-svg-margin-start: -1px;--toast-svg-margin-end: 0px;--toast-button-margin-start: auto;--toast-button-margin-end: 0;--toast-close-button-start: 0;--toast-close-button-end: unset;--toast-close-button-transform: translate(-35%, -35%)}:where(html[dir="rtl"]),:where([data-sonner-toaster][dir="rtl"]){--toast-icon-margin-start: 4px;--toast-icon-margin-end: -3px;--toast-svg-margin-start: 0px;--toast-svg-margin-end: -1px;--toast-button-margin-start: 0;--toast-button-margin-end: auto;--toast-close-button-start: unset;--toast-close-button-end: 0;--toast-close-button-transform: translate(35%, -35%)}:where([data-sonner-toaster]){position:fixed;width:var(--width);font-family:ui-sans-serif,system-ui,-apple-system,BlinkMacSystemFont,Segoe UI,Roboto,Helvetica Neue,Arial,Noto Sans,sans-serif,Apple Color Emoji,Segoe UI Emoji,Segoe UI Symbol,Noto Color Emoji;--gray1: hsl(0, 0%, 99%);--gray2: hsl(0, 0%, 97.3%);--gray3: hsl(0, 0%, 95.1%);--gray4: hsl(0, 0%, 93%);--gray5: hsl(0, 0%, 90.9%);--gray6: hsl(0, 0%, 88.7%);--gray7: hsl(0, 0%, 85.8%);--gray8: hsl(0, 0%, 78%);--gray9: hsl(0, 0%, 56.1%);--gray10: hsl(0, 0%, 52.3%);--gray11: hsl(0, 0%, 43.5%);--gray12: hsl(0, 0%, 9%);--border-radius: 8px;box-sizing:border-box;padding:0;margin:0;list-style:none;outline:none;z-index:999999999;transition:transform .4s ease}:where([data-sonner-toaster][data-lifted="true"]){transform:translateY(-10px)}@media (hover: none) and (pointer: coarse){:where([data-sonner-toaster][data-lifted="true"]){transform:none}}:where([data-sonner-toaster][data-x-position="right"]){right:var(--offset-right)}:where([data-sonner-toaster][data-x-position="left"]){left:var(--offset-left)}:where([data-sonner-toaster][data-x-position="center"]){left:50%;transform:translate(-50%)}:where([data-sonner-toaster][data-y-position="top"]){top:var(--offset-top)}:where([data-sonner-toaster][data-y-position="bottom"]){bottom:var(--offset-bottom)}:where([data-sonner-toast]){--y: translateY(100%);--lift-amount: calc(var(--lift) * var(--gap));z-index:var(--z-index);position:absolute;opacity:0;transform:var(--y);filter:blur(0);touch-action:none;transition:transform .4s,opacity .4s,height .4s,box-shadow .2s;box-sizing:border-box;outline:none;overflow-wrap:anywhere}:where([data-sonner-toast][data-styled="true"]){padding:16px;background:var(--normal-bg);border:1px solid var(--normal-border);color:var(--normal-text);border-radius:var(--border-radius);box-shadow:0 4px 12px #0000001a;width:var(--width);font-size:13px;display:flex;align-items:center;gap:6px}:where([data-sonner-toast]:focus-visible){box-shadow:0 4px 12px #0000001a,0 0 0 2px #0003}:where([data-sonner-toast][data-y-position="top"]){top:0;--y: translateY(-100%);--lift: 1;--lift-amount: calc(1 * var(--gap))}:where([data-sonner-toast][data-y-position="bottom"]){bottom:0;--y: translateY(100%);--lift: -1;--lift-amount: calc(var(--lift) * var(--gap))}:where([data-sonner-toast]) :where([data-description]){font-weight:400;line-height:1.4;color:inherit}:where([data-sonner-toast]) :where([data-title]){font-weight:500;line-height:1.5;color:inherit}:where([data-sonner-toast]) :where([data-icon]){display:flex;height:16px;width:16px;position:relative;justify-content:flex-start;align-items:center;flex-shrink:0;margin-left:var(--toast-icon-margin-start);margin-right:var(--toast-icon-margin-end)}:where([data-sonner-toast][data-promise="true"]) :where([data-icon])>svg{opacity:0;transform:scale(.8);transform-origin:center;animation:sonner-fade-in .3s ease forwards}:where([data-sonner-toast]) :where([data-icon])>*{flex-shrink:0}:where([data-sonner-toast]) :where([data-icon]) svg{margin-left:var(--toast-svg-margin-start);margin-right:var(--toast-svg-margin-end)}:where([data-sonner-toast]) :where([data-content]){display:flex;flex-direction:column;gap:2px}[data-sonner-toast][data-styled=true] [data-button]{border-radius:4px;padding-left:8px;padding-right:8px;height:24px;font-size:12px;color:var(--normal-bg);background:var(--normal-text);margin-left:var(--toast-button-margin-start);margin-right:var(--toast-button-margin-end);border:none;cursor:pointer;outline:none;display:flex;align-items:center;flex-shrink:0;transition:opacity .4s,box-shadow .2s}:where([data-sonner-toast]) :where([data-button]):focus-visible{box-shadow:0 0 0 2px #0006}:where([data-sonner-toast]) :where([data-button]):first-of-type{margin-left:var(--toast-button-margin-start);margin-right:var(--toast-button-margin-end)}:where([data-sonner-toast]) :where([data-cancel]){color:var(--normal-text);background:rgba(0,0,0,.08)}:where([data-sonner-toast][data-theme="dark"]) :where([data-cancel]){background:rgba(255,255,255,.3)}:where([data-sonner-toast]) :where([data-close-button]){position:absolute;
300left:var(--toast-close-button-start);right:var(--toast-close-button-end);top:0;height:20px;width:20px;display:flex;justify-content:center;align-items:center;padding:0;color:var(--gray12);border:1px solid var(--gray4);transform:var(--toast-close-button-transform);border-radius:50%;cursor:pointer;z-index:1;transition:opacity .1s,background .2s,border-color .2s}[data-sonner-toast] [data-close-button]{background:var(--gray1)}:where([data-sonner-toast]) :where([data-close-button]):focus-visible{box-shadow:0 4px 12px #0000001a,0 0 0 2px #0003}:where([data-sonner-toast]) :where([data-disabled="true"]){cursor:not-allowed}:where([data-sonner-toast]):hover :where([data-close-button]):hover{background:var(--gray2);border-color:var(--gray5)}:where([data-sonner-toast][data-swiping="true"]):before{content:"";position:absolute;left:-50%;right:-50%;height:100%;z-index:-1}:where([data-sonner-toast][data-y-position="top"][data-swiping="true"]):before{bottom:50%;transform:scaleY(3) translateY(50%)}:where([data-sonner-toast][data-y-position="bottom"][data-swiping="true"]):before{top:50%;transform:scaleY(3) translateY(-50%)}:where([data-sonner-toast][data-swiping="false"][data-removed="true"]):before{content:"";position:absolute;inset:0;transform:scaleY(2)}:where([data-sonner-toast]):after{content:"";position:absolute;left:0;height:calc(var(--gap) + 1px);bottom:100%;width:100%}:where([data-sonner-toast][data-mounted="true"]){--y: translateY(0);opacity:1}:where([data-sonner-toast][data-expanded="false"][data-front="false"]){--scale: var(--toasts-before) * .05 + 1;--y: translateY(calc(var(--lift-amount) * var(--toasts-before))) scale(calc(-1 * var(--scale)));height:var(--front-toast-height)}:where([data-sonner-toast])>*{transition:opacity .4s}:where([data-sonner-toast][data-expanded="false"][data-front="false"][data-styled="true"])>*{opacity:0}
300:where([data-sonner-toast][data-visible="false"]){opacity:0;pointer-events:none}:where([data-sonner-toast][data-mounted="true"][data-expanded="true"]){--y: translateY(calc(var(--lift) * var(--offset)));height:var(--initial-height)}:where([data-sonner-toast][data-removed="true"][data-front="true"][data-swipe-out="false"]){--y: translateY(calc(var(--lift) * -100%));opacity:0}:where([data-sonner-toast][data-removed="true"][data-front="false"][data-swipe-out="false"][data-expanded="true"]){--y: translateY(calc(var(--lift) * var(--offset) + var(--lift) * -100%));opacity:0}:where([data-sonner-toast][data-removed="true"][data-front="false"][data-swipe-out="false"][data-expanded="false"]){--y: translateY(40%);opacity:0;transition:transform .5s,opacity .2s}:where([data-sonner-toast][data-removed="true"][data-front="false"]):before{height:calc(var(--initial-height) + 20%)}[data-sonner-toast][data-swiping=true]{transform:var(--y) translateY(var(--swipe-amount-y, 0px)) translate(var(--swipe-amount-x, 0px));transition:none}[data-sonner-toast][data-swiped=true]{user-select:none}[data-sonner-toast][data-swipe-out=true][data-y-position=bottom],[data-sonner-toast][data-swipe-out=true][data-y-position=top]{animation-duration:.2s;animation-timing-function:ease-out;animation-fill-mode:forwards}[data-sonner-toast][data-swipe-out=true][data-swipe-direction=left]{animation-name:swipe-out-left}[data-sonner-toast][data-swipe-out=true][data-swipe-direction=right]{animation-name:swipe-out-right}[data-sonner-toast][data-swipe-out=true][data-swipe-direction=up]{animation-name:swipe-out-up}[data-sonner-toast][data-swipe-out=true][data-swipe-direction=down]{animation-name:swipe-out-down}@keyframes swipe-out-left{0%{transform:var(--y) translate(var(--swipe-amount-x));opacity:1}to{transform:var(--y) translate(calc(var(--swipe-amount-x) - 100%));opacity:0}}@keyframes swipe-out-right{0%{transform:var(--y) translate(var(--swipe-amount-x));opacity:1}to{transform:var(--y) translate(calc(var(--swipe-amount-x) + 100%));opacity:0}}@keyframes swipe-out-up{0%{transform:var(--y) translateY(var(--swipe-amount-y));opacity:1}to{transform:var(--y) translateY(calc(var(--swipe-amount-y) - 100%));opacity:0}}@keyframes swipe-out-down{0%{transform:var(--y) translateY(var(--swipe-amount-y));opacity:1}to{transform:var(--y) translateY(calc(var(--swipe-amount-y) + 100%));opacity:0}}@media (max-width: 600px){[data-sonner-toaster]{position:fixed;right:var(--mobile-offset-right);left:var(--mobile-offset-left);width:100%}[data-sonner-toaster][dir=rtl]{left:calc(var(--mobile-offset-left) * -1)}[data-sonner-toaster] [data-sonner-toast]{left:0;right:0;width:calc(100% - var(--mobile-offset-left) * 2)}[data-sonner-toaster][data-x-position=left]{left:var(--mobile-offset-left)}[data-sonner-toaster][data-y-position=bottom]{bottom:var(--mobile-offset-bottom)}[data-sonner-toaster][data-y-position=top]{top:var(--mobile-offset-top)}[data-sonner-toaster][data-x-position=center]{left:var(--mobile-offset-left);right:var(--mobile-offset-right);transform:none}}[data-sonner-toaster][data-theme=light]{--normal-bg: #fff;--normal-border: var(--gray4);--normal-text: var(--gray12);--success-bg: hsl(143, 85%, 96%);--success-border: hsl(145, 92%, 91%);--success-text: hsl(140, 100%, 27%);--info-bg: hsl(208, 100%, 97%);--info-border: hsl(221, 91%, 91%);--info-text: hsl(210, 92%, 45%);--warning-bg: hsl(49, 100%, 97%);--warning-border: hsl(49, 91%, 91%);--warning-text: hsl(31, 92%, 45%);--error-bg: hsl(359, 100%, 97%);--error-border: hsl(359, 100%, 94%);--error-text: hsl(360, 100%, 45%)}[data-sonner-toaster][data-theme=light] [data-sonner-toast][data-invert=true]{--normal-bg: #000;--normal-border: hsl(0, 0%, 20%);--normal-text: var(--gray1)}[data-sonner-toaster][data-theme=dark] [data-sonner-toast][data-invert=true]{--normal-bg: #fff;--normal-border: var(--gray3);--normal-text: var(--gray12)}[data-sonner-toaster][data-theme=dark]{--normal-bg: #000;--normal-bg-hover: hsl(0, 0%, 12%);--normal-border: hsl(0, 0%, 20%);--normal-border-hover: hsl(0, 0%, 25%);--normal-text: var(--gray1);--success-bg: hsl(150, 100%, 6%);--success-border: hsl(147, 100%, 12%);--success-text: hsl(150, 86%, 65%);--info-bg: hsl(215, 100%, 6%);--info-border: hsl(223, 100%, 12%);--info-text: hsl(216, 87%, 65%);--warning-bg: hsl(64, 100%, 6%);--warning-border: hsl(60, 100%, 12%);--warning-text: hsl(46, 87%, 65%);--error-bg: hsl(358, 76%, 10%);--error-border: hsl(357, 89%, 16%);
300--error-text: hsl(358, 100%, 81%)}[data-sonner-toaster][data-theme=dark] [data-sonner-toast] [data-close-button]{background:var(--normal-bg);border-color:var(--normal-border);color:var(--normal-text)}[data-sonner-toaster][data-theme=dark] [data-sonner-toast] [data-close-button]:hover{background:var(--normal-bg-hover);border-color:var(--normal-border-hover)}[data-rich-colors=true][data-sonner-toast][data-type=success],[data-rich-colors=true][data-sonner-toast][data-type=success] [data-close-button]{background:var(--success-bg);border-color:var(--success-border);color:var(--success-text)}[data-rich-colors=true][data-sonner-toast][data-type=info],[data-rich-colors=true][data-sonner-toast][data-type=info] [data-close-button]{background:var(--info-bg);border-color:var(--info-border);color:var(--info-text)}[data-rich-colors=true][data-sonner-toast][data-type=warning],[data-rich-colors=true][data-sonner-toast][data-type=warning] [data-close-button]{background:var(--warning-bg);border-color:var(--warning-border);color:var(--warning-text)}[data-rich-colors=true][data-sonner-toast][data-type=error],[data-rich-colors=true][data-sonner-toast][data-type=error] [data-close-button]{background:var(--error-bg);border-color:var(--error-border);color:var(--error-text)}.sonner-loading-wrapper{--size: 16px;height:var(--size);width:var(--size);position:absolute;inset:0;z-index:10}.sonner-loading-wrapper[data-visible=false]{transform-origin:center;animation:sonner-fade-out .2s ease forwards}.sonner-spinner{position:relative;top:50%;left:50%;height:var(--size);width:var(--size)}.sonner-loading-bar{animation:sonner-spin 1.2s linear infinite;background:var(--gray11);border-radius:6px;height:8%;left:-10%;position:absolute;top:-3.9%;width:24%}.sonner-loading-bar:nth-child(1){animation-delay:-1.2s;transform:rotate(.0001deg) translate(146%)}.sonner-loading-bar:nth-child(2){animation-delay:-1.1s;transform:rotate(30deg) translate(146%)}.sonner-loading-bar:nth-child(3){animation-delay:-1s;transform:rotate(60deg) translate(146%)}.sonner-loading-bar:nth-child(4){animation-delay:-.9s;transform:rotate(90deg) translate(146%)}.sonner-loading-bar:nth-child(5){animation-delay:-.8s;transform:rotate(120deg) translate(146%)}.sonner-loading-bar:nth-child(6){animation-delay:-.7s;transform:rotate(150deg) translate(146%)}.sonner-loading-bar:nth-child(7){animation-delay:-.6s;transform:rotate(180deg) translate(146%)}.sonner-loading-bar:nth-child(8){animation-delay:-.5s;transform:rotate(210deg) translate(146%)}.sonner-loading-bar:nth-child(9){animation-delay:-.4s;transform:rotate(240deg) translate(146%)}.sonner-loading-bar:nth-child(10){animation-delay:-.3s;transform:rotate(270deg) translate(146%)}.sonner-loading-bar:nth-child(11){animation-delay:-.2s;transform:rotate(300deg) translate(146%)}.sonner-loading-bar:nth-child(12){animation-delay:-.1s;transform:rotate(330deg) translate(146%)}@keyframes sonner-fade-in{0%{opacity:0;transform:scale(.8)}to{opacity:1;transform:scale(1)}}@keyframes sonner-fade-out{0%{opacity:1;transform:scale(1)}to{opacity:0;transform:scale(.8)}}@keyframes sonner-spin{0%{opacity:1}to{opacity:.15}}@media (prefers-reduced-motion){[data-sonner-toast],[data-sonner-toast]>*,.sonner-loading-bar{transition:none!important;animation:none!important}}.sonner-loader{position:absolute;top:50%;left:50%;transform:translate(-50%,-50%);transform-origin:center;transition:opacity .2s,transform .2s}.sonner-loader[data-visible=false]{opacity:0;transform:scale(.8) translate(-50%,-50%)}
301`);function gl(e){return e.label!==void 0}var DT=3,LT="32px",_T="16px",jx=4e3,FT=356,VT=14,$T=20,BT=200;function on(...e){return e.filter(Boolean).join(" ")}function zT(e){let[t,n]=e.split("-"),r=[];return t&&r.push(t),n&&r.push(n),r}var UT=e=>{var t,n,r,s,o,a,l,c,u,d,f;let{invert:m,toast:p,unstyled:b,interacting:x,setHeights:y,visibleToasts:w,heights:g,index:v,toasts:S,expanded:j,removeToast:C,defaultRichColors:P,closeButton:N,style:E,cancelButtonStyle:k,actionButtonStyle:R,className:M="",descriptionClassName:I="",duration:O,position:H,gap:B,loadingIcon:U,expandByDefault:T,classNames:A,icons:L,closeButtonAriaLabel:_="Close toast",pauseWhenPageIsHidden:$}=e,[J,ee]=W.useState(null),[Q,ne]=W.useState(null),[F,Z]=W.useState(!1),[we,ae]=W.useState(!1),[le,ce]=W.useState(!1),[Be,St]=W.useState(!1),[Rt,At]=W.useState(!1),[Jt,Zt]=W.useState(0),[$t,pr]=W.useState(0),gr=W.useRef(p.duration||O||jx),qa=W.useRef(null),en=W.useRef(null),Qs=v===0,xr=v+1<=w,Ge=p.type,yr=p.dismissible!==!1,Lu=p.className||"",_u=p.descriptionClassName||"",vr=W.useMemo(()=>g.findIndex(re=>re.toastId===p.id)||0,[g,p.id]),Fu=W.useMemo(()=>{var re;return(re=p.closeButton)!=null?re:N},[p.closeButton,N]),X=W.useMemo(()=>p.duration||O||jx,[p.duration,O]),pe=W.useRef(0),De=W.useRef(0),Re=W.useRef(0),wr=W.useRef(null),[Vu,$u]=H.split("-"),Xp=W.useMemo(()=>g.reduce((re,be,Ee)=>Ee>=vr?re:re+be.height,0),[g,vr]),Jp=PT(),MC=p.invert||m,Bu=Ge==="loading";De.current=W.useMemo(()=>vr*B+Xp,[vr,Xp]),W.useEffect(()=>{gr.current=X},[X]),W.useEffect(()=>{Z(!0)},[]),W.useEffect(()=>{let re=en.current;if(re){let be=re.getBoundingClientRect().height;return pr(be),y(Ee=>[{toastId:p.id,height:be,position:p.position},...Ee]),()=>y(Ee=>Ee.filter(tn=>tn.toastId!==p.id))}},[y,p.id]),W.useLayoutEffect(()=>{if(!F)return;let re=en.current,be=re.style.height;re.style.height="auto";let Ee=re.getBoundingClientRect().height;re.style.height=be,pr(Ee),y(tn=>tn.find(nn=>nn.toastId===p.id)?tn.map(nn=>nn.toastId===p.id?{...nn,height:Ee}:nn):[{toastId:p.id,height:Ee,position:p.position},...tn])},[F,p.title,p.description,y,p.id]);let br=W.useCallback(()=>{ae(!0),Zt(De.current),y(re=>re.filter(be=>be.toastId!==p.id)),setTimeout(()=>{C(p)},BT)},[p,C,y,De]);W.useEffect(()=>{if(p.promise&&Ge==="loading"||p.duration===1/0||p.type==="loading")return;let re;return j||x||$&&Jp?(()=>{if(Re.current<pe.current){let be=new Date().getTime()-pe.current;gr.current=gr.current-be}
301Re.current=new Date().getTime()})():gr.current!==1/0&&(pe.current=new Date().getTime(),re=setTimeout(()=>{var be;(be=p.onAutoClose)==null||be.call(p,p),br()},gr.current)),()=>clearTimeout(re)},[j,x,p,Ge,$,Jp,br]),W.useEffect(()=>{p.delete&&br()},[br,p.delete]);function OC(){var re,be,Ee;return L!=null&&L.loading?W.createElement("div",{className:on(A==null?void 0:A.loader,(re=p==null?void 0:p.classNames)==null?void 0:re.loader,"sonner-loader"),"data-visible":Ge==="loading"},L.loading):U?W.createElement("div",{className:on(A==null?void 0:A.loader,(be=p==null?void 0:p.classNames)==null?void 0:be.loader,"sonner-loader"),"data-visible":Ge==="loading"},U):W.createElement(bT,{className:on(A==null?void 0:A.loader,(Ee=p==null?void 0:p.classNames)==null?void 0:Ee.loader),visible:Ge==="loading"})}return W.createElement("li",{tabIndex:0,ref:en,className:on(M,Lu,A==null?void 0:A.toast,(t=p==null?void 0:p.classNames)==null?void 0:t.toast,A==null?void 0:A.default,A==null?void 0:A[Ge],(n=p==null?void 0:p.classNames)==null?void 0:n[Ge]),"data-sonner-toast":"","data-rich-colors":(r=p.richColors)!=null?r:P,"data-styled":!(p.jsx||p.unstyled||b),"data-mounted":F,"data-promise":!!p.promise,"data-swiped":Rt,"data-removed":we,"data-visible":xr,"data-y-position":Vu,"data-x-position":$u,"data-index":v,"data-front":Qs,"data-swiping":le,"data-dismissible":yr,"data-type":Ge,"data-invert":MC,"data-swipe-out":Be,"data-swipe-direction":Q,"data-expanded":!!(j||T&&F),style:{"--index":v,"--toasts-before":v,"--z-index":S.length-v,"--offset":`${we?Jt:De.current}px`,"--initial-height":T?"auto":`${$t}px`,...E,...p.style},onDragEnd:()=>{ce(!1),ee(null),wr.current=null},onPointerDown:re=>{Bu||!yr||(qa.current=new Date,Zt(De.current),re.target.setPointerCapture(re.pointerId),re.target.tagName!=="BUTTON"&&(ce(!0),wr.current={x:re.clientX,y:re.clientY}))},onPointerUp:()=>{var re,be,Ee,tn;if(Be||!yr)return;wr.current=null;let nn=Number(((re=en.current)==null?void 0:re.style.getPropertyValue("--swipe-amount-x").replace("px",""))||0),Sr=Number(((be=en.current)==null?void 0:be.style.getPropertyValue("--swipe-amount-y").replace("px",""))||0),ms=new Date().getTime()-((Ee=qa.current)==null?void 0:Ee.getTime()),rn=J==="x"?nn:Sr,jr=Math.abs(rn)/ms;if(Math.abs(rn)>=$T||jr>.11){Zt(De.current),(tn=p.onDismiss)==null||tn.call(p,p),ne(J==="x"?nn>0?"right":"left":Sr>0?"down":"up"),br(),St(!0),At(!1);return}ce(!1),ee(null)},onPointerMove:re=>{var be,Ee,tn,nn;if(!wr.current||!yr||((be=window.getSelection())==null?void 0:be.toString().length)>0)return;let Sr=re.clientY-wr.current.y,ms=re.clientX-wr.current.x,rn=(Ee=e.swipeDirections)!=null?Ee:zT(H);!J&&(Math.abs(ms)>1||Math.abs(Sr)>1)&&ee(Math.abs(ms)>Math.abs(Sr)?"x":"y");let jr={x:0,y:0};J==="y"?(rn.includes("top")||rn.includes("bottom"))&&(rn.includes("top")&&Sr<0||rn.includes("bottom")&&Sr>0)&&(jr.y=Sr):J==="x"&&(rn.includes("left")||rn.includes("right"))&&(rn.includes("left")&&ms<0||rn.includes("right")&&ms>0)&&(jr.x=ms),(Math.abs(jr.x)>0||Math.abs(jr.y)>0)&&At(!0),(tn=en.current)==null||tn.style.setProperty("--swipe-amount-x",`${jr.x}px`),(nn=en.current)==null||nn.style.setProperty("--swipe-amount-y",`${jr.y}px`)}},Fu&&!p.jsx?W.createElement("button",{"aria-label":_,"data-disabled":Bu,"data-close-button":!0,onClick:Bu||!yr?()=>{}:()=>{var re;br(),(re=p.onDismiss)==null||re.call(p,p)},className:on(A==null?void 0:A.closeButton,(s=p==null?void 0:p.classNames)==null?void 0:s.closeButton)},(o=L==null?void 0:L.close)!=null?o:kT):null,p.jsx||h.isValidElement(p.title)?p.jsx?p.jsx:typeof p.title=="function"?p.title():p.title:W.createElement(W.Fragment,null,Ge||p.icon||p.promise?W.createElement("div",{"data-icon":"",className:on(A==null?void 0:A.icon,(a=p==null?void 0:p.classNames)==null?void 0:a.icon)},p.promise||p.type==="loading"&&!p.icon?p.icon||OC():null,p.type!=="loading"?p.icon||(L==null?void 0:L[Ge])||vT(Ge):null):null,W.createElement("div",{"data-content":"",className:on(A==null?void 0:A.content,(l=p==null?void 0:p.classNames)==null?void 0:l.content)},W.createElement("div",{"data-title":"",className:on(A==null?void 0:A.title,(c=p==null?void 0:p.classNames)==null?void 0:c.title)},typeof p.title=="function"?p.title():p.title),p.description?W.createElement("div",{"data-description":"",className:on(I,_u,A==null?void 0:A.description,(u=p==null?void 0:p.classNames)==null?void 0:u.description)},typeof p.description=="function"?p.description():p.description):null),h.isValidElement(p.cancel)?p.cancel:p.cancel&&gl(p.cancel)?W.createElement("button",{"data-button":!0,"data-cancel":!0,style:p.cancelButtonStyle||k,onClick:re=>{var be,Ee;gl(p.cancel)&&yr&&((Ee=(be=p.cancel).onClick)==null||Ee.call(be,re),br())},className:on(A==null?void 0:A.cancelButton,(d=p==null?void 0:p.classNames)==null?void 0:d.cancelButton)},p.cancel.label):null,h.isValidElement(p.action)?p.action:p.action&&gl(p.action)?W.createElement("button",{"data-button":!0,"data-action":!0,style:p.actionButtonStyle||R,onClick:re=>{var be,Ee;gl(p.action)&&((Ee=(be=p.action).onClick)==null||Ee.call(be,re),!re.defaultPrevented&&br())},className:on(A==null?void 0:A.actionButton,(f=p==null?void 0:p.classNames)==null?void 0:f.actionButton)},p.action.label):null))};function Nx(){if(typeof window>"u"||typeof document>"u")return"ltr";let e=document.documentElement.getAttribute("dir");return e==="auto"||!e?window.getComputedStyle(document.documentElement).direction:e}function WT(e,t){let n={};return[e,t].forEach((r,s)=>{let o=s===1,a=o?"--mobile-offset":"--offset",l=o?_T:LT;function c(u){["top","right","bottom","left"].forEach(d=>{n[`${a}-${d}`]=typeof u=="number"?`${u}px`:u})}typeof r=="number"||typeof r=="string"?c(r):typeof r=="object"?["top","right","bottom","left"].forEach(u=>{r[u]===void 0?n[`${a}-${u}`]=l:n[`${a}-${u}`]=typeof r[u]=="number"?`${r[u]}px`:r[u]}):c(l)}),n}var HT=h.forwardRef(function(e,t){let{invert:n,position:r="bottom-right",hotkey:s=["altKey","KeyT"],expand:o,closeButton:a,className:l,offset:c,mobileOffset:u,theme:d="light",richColors:f,duration:m,style:p,visibleToasts:b=DT,toastOptions:x,dir:y=Nx(),gap:w=VT,loadingIcon:g,icons:v,containerAriaLabel:S="Notifications",pauseWhenPageIsHidden:j}=e,[C,P]=W.useState([]),N=W.useMemo(()=>Array.from(new Set([r].concat(C.filter($=>$.position).map($=>$.position)))),[C,r]),[E,k]=W.useState([]),[R,M]=W.useState(!1),[I,O]=W.useState(!1),[H,B]=W.useState(d!=="system"?d:typeof window<"u"&&window.matchMedia&&window.matchMedia("(prefers-color-scheme: dark)").matches?"dar
301k":"light"),U=W.useRef(null),T=s.join("+").replace(/Key/g,"").replace(/Digit/g,""),A=W.useRef(null),L=W.useRef(!1),_=W.useCallback($=>{P(J=>{var ee;return(ee=J.find(Q=>Q.id===$.id))!=null&&ee.delete||jt.dismiss($.id),J.filter(({id:Q})=>Q!==$.id)})},[]);return W.useEffect(()=>jt.subscribe($=>{if($.dismiss){P(J=>J.map(ee=>ee.id===$.id?{...ee,delete:!0}:ee));return}setTimeout(()=>{ob.flushSync(()=>{P(J=>{let ee=J.findIndex(Q=>Q.id===$.id);return ee!==-1?[...J.slice(0,ee),{...J[ee],...$},...J.slice(ee+1)]:[$,...J]})})})}),[]),W.useEffect(()=>{if(d!=="system"){B(d);return}if(d==="system"&&(window.matchMedia&&window.matchMedia("(prefers-color-scheme: dark)").matches?B("dark"):B("light")),typeof window>"u")return;let $=window.matchMedia("(prefers-color-scheme: dark)");try{$.addEventListener("change",({matches:J})=>{B(J?"dark":"light")})}catch{$.addListener(({matches:ee})=>{try{B(ee?"dark":"light")}catch(Q){console.error(Q)}})}},[d]),W.useEffect(()=>{C.length<=1&&M(!1)},[C]),W.useEffect(()=>{let $=J=>{var ee,Q;s.every(ne=>J[ne]||J.code===ne)&&(M(!0),(ee=U.current)==null||ee.focus()),J.code==="Escape"&&(document.activeElement===U.current||(Q=U.current)!=null&&Q.contains(document.activeElement))&&M(!1)};return document.addEventListener("keydown",$),()=>document.removeEventListener("keydown",$)},[s]),W.useEffect(()=>{if(U.current)return()=>{A.current&&(A.current.focus({preventScroll:!0}),A.current=null,L.current=!1)}},[U.current]),W.createElement("section",{ref:t,"aria-label":`${S} ${T}`,tabIndex:-1,"aria-live":"polite","aria-relevant":"additions text","aria-atomic":"false",suppressHydrationWarning:!0},N.map(($,J)=>{var ee;let[Q,ne]=$.split("-");return C.length?W.createElement("ol",{key:$,dir:y==="auto"?Nx():y,tabIndex:-1,ref:U,className:l,"data-sonner-toaster":!0,"data-theme":H,"data-y-position":Q,"data-lifted":R&&C.length>1&&!o,"data-x-position":ne,style:{"--front-toast-height":`${((ee=E[0])==null?void 0:ee.height)||0}px`,"--width":`${FT}px`,"--gap":`${w}px`,...p,...WT(c,u)},onBlur:F=>{L.current&&!F.currentTarget.contains(F.relatedTarget)&&(L.current=!1,A.current&&(A.current.focus({preventScroll:!0}),A.current=null))},onFocus:F=>{F.target instanceof HTMLElement&&F.target.dataset.dismissible==="false"||L.current||(L.current=!0,A.current=F.relatedTarget)},onMouseEnter:()=>M(!0),onMouseMove:()=>M(!0),onMouseLeave:()=>{I||M(!1)},onDragEnd:()=>M(!1),onPointerDown:F=>{F.target instanceof HTMLElement&&F.target.dataset.dismissible==="false"||O(!0)},onPointerUp:()=>O(!1)},C.filter(F=>!F.position&&J===0||F.position===$).map((F,Z)=>{var we,ae;return W.createElement(UT,{key:F.id,icons:v,index:Z,toast:F,defaultRichColors:f,duration:(we=x==null?void 0:x.duration)!=null?we:m,className:x==null?void 0:x.className,descriptionClassName:x==null?void 0:x.descriptionClassName,invert:n,visibleToasts:b,closeButton:(ae=x==null?void 0:x.closeButton)!=null?ae:a,interacting:I,position:$,style:x==null?void 0:x.style,unstyled:x==null?void 0:x.unstyled,classNames:x==null?void 0:x.classNames,cancelButtonStyle:x==null?void 0:x.cancelButtonStyle,actionButtonStyle:x==null?void 0:x.actionButtonStyle,removeToast:_,toasts:C.filter(le=>le.position==F.position),heights:E.filter(le=>le.position==F.position),setHeights:k,expandByDefault:o,gap:w,loadingIcon:g,expanded:R,pauseWhenPageIsHidden:j,swipeDirections:e.swipeDirections})})):null}))});const KT=({...e})=>{const{theme:t="system"}=yT();return i.jsx(HT,{theme:t,className:"toaster group",toastOptions:{classNames:{toast:"group toast group-[.toaster]:bg-background group-[.toaster]:text-foreground group-[.toaster]:border-border group-[.toaster]:shadow-lg",description:"group-[.toast]:text-muted-foreground",actionButton:"group-[.toast]:bg-primary group-[.toast]:text-primary-foreground",cancelButton:"group-[.toast]:bg-muted group-[.toast]:text-muted-foreground"}},...e})};var YT=Yh[" useId ".trim().toString()]||(()=>{}),GT=0;function To(e){const[t,n]=h.useState(YT());return rt(()=>{n(r=>r??String(GT++))},[e]),t?`radix-${t}`:""}const qT=["top","right","bottom","left"],rs=Math.min,Ot=Math.max,Pc=Math.round,xl=Math.floor,Vn=e=>({x:e,y:e}
vendor: 19,317 bytes, line 301
301),QT={left:"right",right:"left",bottom:"top",top:"bottom"},XT={start:"end",end:"start"};function nh(e,t,n){return Ot(e,rs(t,n))}function lr(e,t){return typeof e=="function"?e(t):e}function cr(e){return e.split("-")[0]}function ci(e){return e.split("-")[1]}function Hm(e){return e==="x"?"y":"x"}function Km(e){return e==="y"?"height":"width"}const JT=new Set(["top","bottom"]);function Dn(e){return JT.has(cr(e))?"y":"x"}function Ym(e){return Hm(Dn(e))}function ZT(e,t,n){n===void 0&&(n=!1);const r=ci(e),s=Ym(e),o=Km(s);let a=s==="x"?r===(n?"end":"start")?"right":"left":r==="start"?"bottom":"top";return t.reference[o]>t.floating[o]&&(a=Ec(a)),[a,Ec(a)]}function eR(e){const t=Ec(e);return[rh(e),t,rh(t)]}function rh(e){return e.replace(/start|end/g,t=>XT[t])}const Cx=["left","right"],kx=["right","left"],tR=["top","bottom"],nR=["bottom","top"];function rR(e,t,n){switch(e){case"top":case"bottom":return n?t?kx:Cx:t?Cx:kx;case"left":case"right":return t?tR:nR;default:return[]}}function sR(e,t,n,r){const s=ci(e);let o=rR(cr(e),n==="start",r);return s&&(o=o.map(a=>a+"-"+s),t&&(o=o.concat(o.map(rh)))),o}function Ec(e){return e.replace(/left|right|bottom|top/g,t=>QT[t])}function oR(e){return{top:0,right:0,bottom:0,left:0,...e}}function Qb(e){return typeof e!="number"?oR(e):{top:e,right:e,bottom:e,left:e}}function Tc(e){const{x:t,y:n,width:r,height:s}=e;return{width:r,height:s,top:n,left:t,right:t+r,bottom:n+s,x:t,y:n}}function Px(e,t,n){let{reference:r,floating:s}=e;const o=Dn(t),a=Ym(t),l=Km(a),c=cr(t),u=o==="y",d=r.x+r.width/2-s.width/2,f=r.y+r.height/2-s.height/2,m=r[l]/2-s[l]/2;let p;switch(c){case"top":p={x:d,y:r.y-s.height};break;case"bottom":p={x:d,y:r.y+r.height};break;case"right":p={x:r.x+r.width,y:f};break;case"left":p={x:r.x-s.width,y:f};break;default:p={x:r.x,y:r.y}}switch(ci(t)){case"start":p[a]-=m*(n&&u?-1:1);break;case"end":p[a]+=m*(n&&u?-1:1);break}return p}const iR=async(e,t,n)=>{const{placement:r="bottom",strategy:s="absolute",middleware:o=[],platform:a}=n,l=o.filter(Boolean),c=await(a.isRTL==null?void 0:a.isRTL(t));let u=await a.getElementRects({reference:e,floating:t,strategy:s}),{x:d,y:f}=Px(u,r,c),m=r,p={},b=0;for(let x=0;x<l.length;x++){const{name:y,fn:w}=l[x],{x:g,y:v,data:S,reset:j}=await w({x:d,y:f,initialPlacement:r,placement:m,strategy:s,middlewareData:p,rects:u,platform:a,elements:{reference:e,floating:t}});d=g??d,f=v??f,p={...p,[y]:{...p[y],...S}},j&&b<=50&&(b++,typeof j=="object"&&(j.placement&&(m=j.placement),j.rects&&(u=j.rects===!0?await a.getElementRects({reference:e,floating:t,strategy:s}):j.rects),{x:d,y:f}=Px(u,m,c)),x=-1)}return{x:d,y:f,placement:m,strategy:s,middlewareData:p}};async function Sa(e,t){var n;t===void 0&&(t={});const{x:r,y:s,platform:o,rects:a,elements:l,strategy:c}=e,{boundary:u="clippingAncestors",rootBoundary:d="viewport",elementContext:f="floating",altBoundary:m=!1,padding:p=0}=lr(t,e),b=Qb(p),y=l[m?f==="floating"?"reference":"floating":f],w=Tc(await o.getClippingRect({element:(n=await(o.isElement==null?void 0:o.isElement(y)))==null||n?y:y.contextElement||await(o.getDocumentElement==null?void 0:o.getDocumentElement(l.floating)),boundary:u,rootBoundary:d,strategy:c})),g=f==="floating"?{x:r,y:s,width:a.floating.width,height:a.floating.height}:a.reference,v=await(o.getOffsetParent==null?void 0:o.getOffsetParent(l.floating)),S=await(o.isElement==null?void 0:o.isElement(v))?await(o.getScale==null?void 0:o.getScale(v))||{x:1,y:1}:{x:1,y:1},j=Tc(o.convertOffsetParentRelativeRectToViewportRelativeRect?await o.convertOffsetParentRelativeRectToViewportRelativeRect({elements:l,rect:g,offsetParent:v,strategy:c}):g);return{top:(w.top-j.top+b.top)/S.y,bottom:(j.bottom-w.bottom+b.bottom)/S.y,left:(w.left-j.left+b.left)/S.x,right:(j.right-w.right+b.right)/S.x}}const aR=e=>({name:"arrow",options:e,async fn(t){const{x:n,y:r,placement:s,rects:o,platform:a,elements:l,middlewareData:c}=t,{element:u,padding:d=0}=lr(e,t)||{};if(u==null)return{};const f=Qb(d),m={x:n,y:r},p=Ym(s),b=Km(p),x=await a.getDimensions(u),y=p==="y",w=y?"top":"left",g=y?"bottom":"right",v=y?"clientHeight":"clientWidth",S=o.reference[b]+o.reference[p]-m[p]-o.floating[b],j=m[p]-o.reference[p],C=await(a.getOffsetParent==null?void 0:a.getOffsetParent(u));let P=C?C[v]:0;(!P||!await(a.isElement==null?void 0:a.isElement(C)))&&(P=l.floating[v]||o.floating[b]);const N=S/2-j/2,E=P/2-x[b]/2-1,k=rs(f[w],E),R=rs(f[g],E),M=k,I=P-x[b]-R,O=P/2-x[b]/2+N,H=nh(M,O,I),B=!c.arrow&&ci(s)!=null&&O!==H&&o.reference[b]/2-(O<M?k:R)-x[b]/2<0,U=B?O<M?O-M:O-I:0;return{[p]:m[p]+U,data:{[p]:H,centerOffset:O-H-U,...B&&{alignmentOffset:U}},reset:B}}}),lR=function(e){return e===void 0&&(e={}),{name:"flip",options:e,async fn(t){var n,r;const{placement:s,middlewareData:o,rects:a,initialPlacement:l,platform:c,elements:u}=t,{mainAxis:d=!0,crossAxis:f=!0,fallbackPlacements:m,fallbackStrategy:p="bestFit",fallbackAxisSideDirection:b="none",flipAlignment:x=!0,...y}=lr(e,t);if((n=o.arrow)!=null&&n.alignmentOffset)return{};const w=cr(s),g=Dn(l),v=cr(l)===l,S=await(c.isRTL==null?void 0:c.isRTL(u.floating)),j=m||(v||!x?[Ec(l)]:eR(l)),C=b!=="none";!m&&C&&j.push(...sR(l,x,b,S));const P=[l,...j],N=await Sa(t,y),E=[];let k=((r=o.flip)==null?void 0:r.overflows)||[];if(d&&E.push(N[w]),f){const O=ZT(s,a,S);E.push(N[O[0]],N[O[1]])}if(k=[...k,{placement:s,overflows:E}],!E.every(O=>O<=0)){var R,M;const O=(((R=o.flip)==null?void 0:R.index)||0)+1,H=P[O];if(H&&(!(f==="alignment"?g!==Dn(H):!1)||k.every(T=>T.overflows[0]>0&&Dn(T.placement)===g)))return{data:{index:O,overflows:k},reset:{placement:H}};let B=(M=k.filter(U=>U.overflows[0]<=0).sort((U,T)=>U.overflows[1]-T.overflows[1])[0])==null?void 0:M.placement;if(!B)switch(p){case"bestFit":{var I;const U=(I=k.filter(T=>{if(C){const A=Dn(T.placement);return A===g||A==="y"}return!0}).map(T=>[T.placement,T.overflows.filter(A=>A>0).reduce((A,L)=>A+L,0)]).sort((T,A)=>T[1]-A[1])[0])==null?void 0:I[0];U&&(B=U);break}case"initialPlacement":B=l;break}if(s!==B)return{reset:{placement:B}}}return{}}}};function Ex(e,t){return{top:e.top-t.height,right:e.right-t.width,bottom:e.bottom-t.height,left:e.left-t.width}}function Tx(e){return qT.some(t=>e[t]>=0)}const cR=function(e){return e===void 0&&(e={}),{name:"hide",options:e,async fn(t){const{rects:n}=t,{strategy:r="referenceHidden",...s}=lr(e,t);switch(r){case"referenceHidden":{const o=await Sa(t,{...s,elementContext:"reference"}),a=Ex(o,n.reference);return{data:{referenceHiddenOffsets:a,referenceHidden:Tx(a)}}}case"escaped":{const o=await Sa(t,{...s,altBoundary:!0}),a=Ex(o,n.floating);return{data:{escapedOffsets:a,escaped:Tx(a)}}}default:return{}}}}},Xb=new Set(["left","top"]);async function uR(e,t){const{placement:n,platform:r,elements:s}=e,o=await(r.isRTL==null?void 0:r.isRTL(s.floating)),a=cr(n),l=ci(n),c=Dn(n)==="y",u=Xb.has(a)?-1:1,d=o&&c?-1:1,f=lr(t,e);let{mainAxis:m,crossAxis:p,alignmentAxis:b}=typeof f=="number"?{mainAxis:f,crossAxis:0,alignmentAxis:null}:{mainAxis:f.mainAxis||0,crossAxis:f.crossAxis||0,alignmentAxis:f.alignmentAxis};return l&&typeof b=="number"&&(p=l==="end"?b*-1:b),c?{x:p*d,y:m*u}:{x:m*u,y:p*d}}const dR=function(e){return e===void 0&&(e=0),{name:"offset",options:e,async fn(t){var n,r;const{x:s,y:o,placement:a,middlewareData:l}=t,c=await uR(t,e);return a===((n=l.offset)==null?void 0:n.placement)&&(r=l.arrow)!=null&&r.alignmentOffset?{}:{x:s+c.x,y:o+c.y,data:{...c,placement:a}}}}},fR=function(e){return e===void 0&&(e={}),{name:"shift",options:e,async fn(t){const{x:n,y:r,placement:s}=t,{mainAxis:o=!0,crossAxis:a=!1,limiter:l={fn:y=>{let{x:w,y:g}=y;return{x:w,y:g}}},...c}=lr(e,t),u={x:n,y:r},d=await Sa(t,c),f=Dn(cr(s)),m=Hm(f);let p=u[m],b=u[f];if(o){const y=m==="y"?"top":"left",w=m==="y"?"bottom":"right",g=p+d[y],v=p-d[w];p=nh(g,p,v)}if(a){const y=f==="y"?"top":"left",w=f==="y"?"bottom":"right",g=b+d[y],v=b-d[w];b=nh(g,b,v)}const x=l.fn({...t,[m]:p,[f]:b});return{...x,data:{x:x.x-n,y:x.y-r,enabled:{[m]:o,[f]:a}}}}}},hR=function(e){return e===void 0&&(e={}),{options:e,fn(t){const{x:n,y:r,placement:s,rects:o,middlewareData:a}=t,{offset:l=0,mainAxis:c=!0,crossAxis:u=!0}=lr(e,t),d={x:n,y:r},f=Dn(s),m=Hm(f);let p=d[m],b=d[f];const x=lr(l,t),y=typeof x=="number"?{mainAxis:x,crossAxis:0}:{mainAxis:0,crossAxis:0,...x};if(c){const v=m==="y"?"height":"width",S=o.reference[m]-o.floating[v]+y.mainAxis,j=o.reference[m]+o.reference[v]-y.mainAxis;p<S?p=S:p>j&&(p=j)}if(u){var w,g;const v=m==="y"?"width":"height",S=Xb.has(cr(s)),j=o.reference[f]-o.floating[v]+(S&&((w=a.offset)==null?void 0:w[f])||0)+(S?0:y.crossAxis),C=o.reference[f]+o.reference[v]+(S?0:((g=a.offset)==null?void 0:g[f])||0)-(S?y.crossAxis:0);b<j?b=j:b>C&&(b=C)}return{[m]:p,[f]:b}}}},mR=function(e){return e===void 0&&(e={}),{name:"size",options:e,async fn(t){var n,r;const{placement:s,rects:o,platform:a,elements:l}=t,{apply:c=()=>{},...u}=lr(e,t),d=await Sa(t,u),f=cr(s),m=ci(s),p=Dn(s)==="y",{width:b,height:x}=o.floating;let y,w;f==="top"||f==="bottom"?(y=f,w=m===(await(a.isRTL==null?void 0:a.isRTL(l.floating))?"start":"end")?"left":"right"):(w=f,y=m==="end"?"top":"bottom");const g=x-d.top-d.bottom,v=b-d.left-d.right,S=rs(x-d[y],g),j=rs(b-d[w],v),C=!t.middlewareData.shift;let P=S,N=j;if((n=t.middlewareData.shift)!=null&&n.enabled.x&&(N=v),(r=t.middlewareData.shift)!=null&&r.enabled.y&&(P=g),C&&!m){const k=Ot(d.left,0),R=Ot(d.right,0),M=Ot(d.top,0),I=Ot(d.bottom,0);p?N=b-2*(k!==0||R!==0?k+R:Ot(d.left,d.right)):P=x-2*(M!==0||I!==0?M+I:Ot(d.top,d.bottom))}await c({...t,availableWidth:N,availableHeight:P});const E=await a.getDimensions(l.floating);return b!==E.width||x!==E.height?{reset:{rects:!0}}:{}}}};function uu(){return typeof window<"u"}function ui(e){return Jb(e)?(e.nodeName||"").toLowerCase():"#document"}function Lt(e){var t;return(e==null||(t=e.ownerDocument)==null?void 0:t.defaultView)||window}function Un(e){var t;return(t=(Jb(e)?e.ownerDocument:e.document)||window.document)==null?void 0:t.documentElement}function Jb(e){return uu()?e instanceof Node||e instanceof Lt(e).Node:!1}function Sn(e){return uu()?e instanceof Element||e instanceof Lt(e).Element:!1}function Bn(e){return uu()?e instanceof HTMLElement||e instanceof Lt(e).HTMLElement:!1}function Rx(e){return!uu()||typeof ShadowRoot>"u"?!1:e instanceof ShadowRoot||e instanceof Lt(e).ShadowRoot}const pR=new Set(["inline","contents"]);function Wa(e){const{overflow:t,overflowX:n,overflowY:r,display:s}=jn(e);return/auto|scroll|overlay|hidden|clip/.test(t+r+n)&&!pR.has(s)}const gR=new Set(["table","td","th"]);function xR(e){return gR.has(ui(e))}const yR=[":popover-open",":modal"];function du(e){return yR.some(t=>{try{return e.matches(t)}catch{return!1}})}const vR=["transform","translate","scale","rotate","perspective"],wR=["transform","translate","scale","rotate","perspective","filter"],bR=["paint","layout","strict","content"];function Gm(e){const t=qm(),n=Sn(e)?jn(e):e;return vR.some(r=>n[r]?n[r]!=="none":!1)||(n.containerType?n.containerType!=="normal":!1)||!t&&(n.backdropFilter?n.backdropFilter!=="none":!1)||!t&&(n.filter?n.filter!=="none":!1)||wR.some(r=>(n.willChange||"").includes(r))||bR.some(r=>(n.contain||"").includes(r))}function SR(e){let t=ss(e);for(;Bn(t)&&!Jo(t);){if(Gm(t))return t;if(du(t))return null;t=ss(t)}return null}function qm(){return typeof CSS>"u"||!CSS.supports?!1:CSS.supports("-webkit-backdrop-filter","none")}const jR=new Set(["html","body","#document"]);function Jo(e){return jR.has(ui(e))}function jn(e){return Lt(e).getComputedStyle(e)}function fu(e){return Sn(e)?{scrollLeft:e.scrollLeft,scrollTop:e.scrollTop}:{scrollLeft:e.scrollX,scrollTop:e.scrollY}}function ss(e){if(ui(e)==="html")return e;const t=e.assignedSlot||e.parentNode||Rx(e)&&e.host||Un(e);return Rx(t)?t.host:t}function Zb(e){const t=ss(e);return Jo(t)?e.ownerDocument?e.ownerDocument.body:e.body:Bn(t)&&Wa(t)?t:Zb(t)}function ja(e,t,n){var r;t===void 0&&(t=[]),n===void 0&&(n=!0);const s=Zb(e),o=s===((r=e.ownerDocument)==null?void 0:r.body),a=Lt(s);if(o){const l=sh(a);return t.concat(a,a.visualViewport||[],Wa(s)?s:[],l&&n?ja(l):[])}return t.concat(s,ja(s,[],n))}function sh(e){return e.parent&&Object.getPrototypeOf(e.parent)?e.frameElement:null}function e1(e){const t=jn(e);let n=parseFloat(t.width)||0,r=parseFloat(t.height)||0;const s=Bn(e),o=s?e.offsetWidth:n,a=s?e.offsetHeight:r,l=Pc(n)!==o||Pc(r)!==a;return l&&(n=o,r=a),{width:n,height:r,$:l}}function Qm(e){return Sn(e)?e:e.contextElement}function Ro(e){const t=Qm(e);if(!Bn(t))return Vn(1);const n=t.getBoundingClientRect(),{width:r,height:s,$:o}=e1(t);let a=(o?Pc(n.width):n.width)/r,l=(o?Pc(n.height):n.height)/s;return(!a||!Number.isFinite(a))&&(a=1),(!l||!Number.isFinite(l))&&(l=1),{x:a,y:l}}const NR=Vn(0);function t1(e){const t=Lt(e);return!qm()||!t.visualViewport?NR:{x:t.visualViewport.offsetLeft,y:t.visualViewport.offsetTop}}function CR(e,t,n){return t===void 0&&(t=!1),!n||t&&n!==Lt(e)?!1:t}function Bs(e,t,n,r){t===void 0&&(t=!1),n===void 0&&(n=!1);const s=e.getBoundingClientRect(),o=Qm(e);let a=Vn(1);t&&(r?Sn(r)&&(a=Ro(r)):a=Ro(e));const l=CR(o,n,r)?t1(o):Vn(0);let c=(s.left+l.x)/a.x,u=(s.top+l.y)/a.y,d=s.width/a.x,f=s.height/a.y;if(o){const m=Lt(o),p=r&&Sn(r)?Lt(r):r;let b=m,x=sh(b);for(;x&&r&&p!==b;){const y=Ro(x),w=x.getBoundingClientRect(),g=jn(x),v=w.left+(x.clientLeft+parseFloat(g.paddingLeft))*y.x,S=w.top+(x.clientTop+parseFloat(g.paddingTop))*y.y;c*=y.x,u*=y.y,d*=y.x,f*=y.y,c+=v,u+=S,b=Lt(x),x=sh(b)}}return Tc({width:d,height:f,x:c,y:u})}function Xm(e,t){const n=fu(e).scrollLeft;return t?t.left+n:Bs(Un(e)).left+n}function n1(e,t,n){n===void 0&&(n=!1);const r=e.getBoundingClientRect(),s=r.left+t.scrollLeft-(n?0:Xm(e,r)),o=r.top+t.scrollTop;return{x:s,y:o}}function kR(e){let{elements:t,rect:n,offsetParent:r,strategy:s}=e;const o=s==="fixed",a=Un(r),l=t?du(t.floating):!1;if(r===a||l&&o)return n;let c={scrollLeft:0,scrollTop:0},u=Vn(1);const d=Vn(0),f=Bn(r);if((f||!f&&!o)&&((ui(r)!=="body"||Wa(a))&&(c=fu(r)),Bn(r))){const p=Bs(r);u=Ro(r),d.x=p.x+r.clientLeft,d.y=p.y+r.clientTop}const m=a&&!f&&!o?n1(a,c,!0):Vn(0);return{width:n.width*u.x,height:n.height*u.y,x:n.x*u.x-c.scrollLeft*u.x+d.x+m.x,y:n.y*u.y-c.scrollTop*u.y+d.y+m.y}}function PR(e){return Array.from(e.getClientRects())}function ER(e){const t=Un(e),n=fu(e),r=e.ownerDocument.body,s=Ot(t.scrollWidth,t.clientWidth,r.scrollWidth,r.clientWidth),o=Ot(t.scrollHeight,t.clientHeight,r.scrollHeight,r.clientHeight);let a=-n.scrollLeft+Xm(e);const l=-n.scrollTop;return jn(r).direction==="rtl"&&(a+=Ot(t.clientWidth,r.clientWidth)-s),{width:s,height:o,x:a,y:l}}function TR(e,t){const n=Lt(e),r=Un(e),s=n.visualViewport;let o=r.clientWidth,a=r.clientHeight,l=0,c=0;if(s){o=s.width,a=s.height;const u=qm();(!u||u&&t==="fixed")&&(l=s.offsetLeft,c=s.offsetTop)}return{width:o,height:a,x:l,y:c}}const RR=new Set(["absolute","fixed"]);function AR(e,t){const n=Bs(e,!0,t==="fixed"),r=n.top+e.clientTop,s=n.left+e.clientLeft,o=Bn(e)?Ro(e):Vn(1),a=e.clientWidth*o.x,l=e.clientHeight*o.y,c=s*o.x,u=r*o.y;return{width:a,height:l,x:c,y:u}}function Ax(e,t,n){let r;if(t==="viewport")r=TR(e,n);else if(t==="document")r=ER(Un(e));else if(Sn(t))r=AR(t,n);else{const s=t1(e);r={x:t.x-s.x,y:t.y-s.y,width:t.width,height:t.height}}return Tc(r)}function r1(e,t){const n=ss(e);return n===t||!Sn(n)||Jo(n)?!1:jn(n).position==="fixed"||r1(n,t)}function MR(e,t){const n=t.get(e);if(n)return n;let r=ja(e,[],!1).filter(l=>Sn(l)&&ui(l)!=="body"),s=null;const o=jn(e).position==="fixed";let a=o?ss(e):e;for(;Sn(a)&&!Jo(a);){const l=jn(a),c=Gm(a);!c&&l.position==="fixed"&&(s=null),(o?!c&&!s:!c&&l.position==="static"&&!!s&&RR.has(s.position)||Wa(a)&&!c&&r1(e,a))?r=r.filter(d=>d!==a):s=l,a=ss(a)}return t.set(e,r),r}function OR(e){let{element:t,boundary:n,rootBoundary:r,strategy:s}=e;const a=[...n==="clippingAncestors"?du(t)?[]:MR(t,this._c):[].concat(n),r],l=a[0],c=a.reduce((u,d)=>{const f=Ax(t,d,s);return u.top=Ot(f.top,u.top),u.right=rs(f.right,u.right),u.bottom=rs(f.bottom,u.bottom),u.left=Ot(f.left,u.left),u},Ax(t,l,s));return{width:c.right-c.left,height:c.bottom-c.top,x:c.left,y:c.top}}function IR(e){const{width:t,height:n}=e1(e);return{width:t,height:n}}function DR(e,t,n){const r=Bn(t),s=Un(t),o=n==="fixed",a=Bs(e,!0,o,t);let l={scrollLeft:0,scrollTop:0};const c=Vn(0);function u(){c.x=Xm(s)}if(r||!r&&!o)if((ui(t)!=="body"||Wa(s))&&(l=fu(t)),r){const p=Bs(t,!0,o,t);c.x=p.x+t.clientLeft,c.y=p.y+t.clientTop}else s&&u();o&&!r&&s&&u();const d=s&&!r&&!o?n1(s,l):Vn(0),f=a.left+l.scrollLeft-c.x-d.x,m=a.top+l.scrollTop-c.y-d.y;return{x:f,y:m,width:a.width,height:a.height}}function vd(e){return jn(e).position==="static"}function Mx(e,t){if(!Bn(e)||jn(e).position==="fixed")return null;if(t)return t(e);let n=e.offsetParent;return Un(e)===n&&(n=n.ownerDocument.body),n}function s1(e,t){const n=Lt(e);if(du(e))return n;if(!Bn(e)){let s=ss(e);for(;s&&!Jo(s);){if(Sn(s)&&!vd(s))return s;s=ss(s)}return n}let r=Mx(e,t);for(;r&&xR(r)&&vd(r);)r=Mx(r,t);return r&&Jo(r)&&vd(r)&&!Gm(r)?n:r||SR(e)||n}const LR=async function(e){const t=this.getOffsetParent||s1,n=this.getDimensions,r=await n(e.floating);return{reference:DR(e.reference,await t(e.floating),e.strategy),floating:{x:0,y:0,width:r.width,height:r.height}}};function _R(e){return jn(e).direction==="rtl"}const FR={convertOffsetParentRelativeRectToViewportRelativeRect:kR,getDocumentElement:Un,getClippingRect:OR,getOffsetParent:s1,getElementRects:LR,getClientRects:PR,getDimensions:IR,getScale:Ro,isElement:Sn,isRTL:_R};function o1(e,t){return e.x===t.x&&e.y===t.y&&e.width===t.width&&e.height===t.height}function VR(e,t){let n=null,r;const s=Un(e);function o(){var l;clearTimeout(r),(l=n)==null||l.disconnect(),n=null}function a(l,c){l===void 0&&(l=!1),c===void 0&&(c=1),o();const u=e.getBoundingClientRect(),{left:d,top:f,width:m,height:p}=u;if(l||t(),!m||!p)return;const b=xl(f),x=xl(s.clientWidth-(d+m)),y=xl(s.clientHeight-(f+p)),w=xl(d),v={rootMargin:-b+"px "+-x+"px "+-y+"px "+-w+"px",threshold:Ot(0,rs(1,c))||1};let S=!0;function j(C){const P=C[0].intersectionRatio;if(P!==c){if(!S)return a();P?a(!1,P):r=setTimeout(()=>{a(!1,1e-7)},1e3)}P===1&&!o1(u,e.getBoundingClientRect())&&a(),S=!1}try{n=new IntersectionObserver(j,{...v,root:s.ownerDocument})}catch{n=new IntersectionObserver(j,v)}n.observe(e)}return a(!0),o}function $R(e,t,n,r){r===void 0&&(r={});const{ancestorScroll:s=!0,ancestorResize:o=!0,elementResize:a=typeof ResizeObserver=="function",layoutShift:l=typeof IntersectionObserver=="function",animationFrame:c=!1}=r,u=Qm(e),d=s||o?[...u?ja(u):[],...ja(t)]:[];d.forEach(w=>{s&&w.addEventListener("scroll",n,{passive:!0}),o&&w.addEventListener("resize",n)});const f=u&&l?VR(u,n):null;let m=-1,p=null;a&&(p=new ResizeObserver(w=>{let[g]=w;g&&g.target===u&&p&&(p.unobserve(t),cancelAnimationFrame(m),m=requestAnimationFrame(()=>{var v;(v=p)==null||v.observe(t)})),n()}),u&&!c&&p.observe(u),p.observe(t));let b,x=c?Bs(e):null;c&&y();function y(){const w=Bs(e);x&&!o1(x,w)&&n(),x=w,b=requestAnimationFrame(y)}return n(),()=>{var w;d.forEach(g=>{s&&g.removeEventListener("scroll",n),o&&g.removeEventListener("resize",n)}),f==null||f(),(w=p)==null||w.disconnect(),p=null,c&&cancelAnimationFrame(b)}}const BR=dR,zR=fR,UR=lR,WR=mR,HR=cR,Ox=aR,KR=hR,YR=(e,t,n)=>{const r=new Map,s={platform:FR,...n},o={...s.platform,_c:r};return iR(e,t,{...s,platform:o})};var GR=typeof document<"u",qR=function(){},Hl=GR?h.useLayoutEffect:qR;function Rc(e,t){if(e===t)return!0;
vendor: 4,143 bytes, line 301
301if(typeof e!=typeof t)return!1;if(typeof e=="function"&&e.toString()===t.toString())return!0;let n,r,s;if(e&&t&&typeof e=="object"){if(Array.isArray(e)){if(n=e.length,n!==t.length)return!1;for(r=n;r--!==0;)if(!Rc(e[r],t[r]))return!1;return!0}if(s=Object.keys(e),n=s.length,n!==Object.keys(t).length)return!1;for(r=n;r--!==0;)if(!{}.hasOwnProperty.call(t,s[r]))return!1;for(r=n;r--!==0;){const o=s[r];if(!(o==="_owner"&&e.$$typeof)&&!Rc(e[o],t[o]))return!1}return!0}return e!==e&&t!==t}function i1(e){return typeof window>"u"?1:(e.ownerDocument.defaultView||window).devicePixelRatio||1}function Ix(e,t){const n=i1(e);return Math.round(t*n)/n}function wd(e){const t=h.useRef(e);return Hl(()=>{t.current=e}),t}function QR(e){e===void 0&&(e={});const{placement:t="bottom",strategy:n="absolute",middleware:r=[],platform:s,elements:{reference:o,floating:a}={},transform:l=!0,whileElementsMounted:c,open:u}=e,[d,f]=h.useState({x:0,y:0,strategy:n,placement:t,middlewareData:{},isPositioned:!1}),[m,p]=h.useState(r);Rc(m,r)||p(r);const[b,x]=h.useState(null),[y,w]=h.useState(null),g=h.useCallback(T=>{T!==C.current&&(C.current=T,x(T))},[]),v=h.useCallback(T=>{T!==P.current&&(P.current=T,w(T))},[]),S=o||b,j=a||y,C=h.useRef(null),P=h.useRef(null),N=h.useRef(d),E=c!=null,k=wd(c),R=wd(s),M=wd(u),I=h.useCallback(()=>{if(!C.current||!P.current)return;const T={placement:t,strategy:n,middleware:m};R.current&&(T.platform=R.current),YR(C.current,P.current,T).then(A=>{const L={...A,isPositioned:M.current!==!1};O.current&&!Rc(N.current,L)&&(N.current=L,Gs.flushSync(()=>{f(L)}))})},[m,t,n,R,M]);Hl(()=>{u===!1&&N.current.isPositioned&&(N.current.isPositioned=!1,f(T=>({...T,isPositioned:!1})))},[u]);const O=h.useRef(!1);Hl(()=>(O.current=!0,()=>{O.current=!1}),[]),Hl(()=>{if(S&&(C.current=S),j&&(P.current=j),S&&j){if(k.current)return k.current(S,j,I);I()}},[S,j,I,k,E]);const H=h.useMemo(()=>({reference:C,floating:P,setReference:g,setFloating:v}),[g,v]),B=h.useMemo(()=>({reference:S,floating:j}),[S,j]),U=h.useMemo(()=>{const T={position:n,left:0,top:0};if(!B.floating)return T;const A=Ix(B.floating,d.x),L=Ix(B.floating,d.y);return l?{...T,transform:"translate("+A+"px, "+L+"px)",...i1(B.floating)>=1.5&&{willChange:"transform"}}:{position:n,left:A,top:L}},[n,l,B.floating,d.x,d.y]);return h.useMemo(()=>({...d,update:I,refs:H,elements:B,floatingStyles:U}),[d,I,H,B,U])}const XR=e=>{function t(n){return{}.hasOwnProperty.call(n,"current")}return{name:"arrow",options:e,fn(n){const{element:r,padding:s}=typeof e=="function"?e(n):e;return r&&t(r)?r.current!=null?Ox({element:r.current,padding:s}).fn(n):{}:r?Ox({element:r,padding:s}).fn(n):{}}}},JR=(e,t)=>({...BR(e),options:[e,t]}),ZR=(e,t)=>({...zR(e),options:[e,t]}),eA=(e,t)=>({...KR(e),options:[e,t]}),tA=(e,t)=>({...UR(e),options:[e,t]}),nA=(e,t)=>({...WR(e),options:[e,t]}),rA=(e,t)=>({...HR(e),options:[e,t]}),sA=(e,t)=>({...XR(e),options:[e,t]});var oA="Arrow",a1=h.forwardRef((e,t)=>{const{children:n,width:r=10,height:s=5,...o}=e;return i.jsx(fe.svg,{...o,ref:t,width:r,height:s,viewBox:"0 0 30 10",preserveAspectRatio:"none",children:e.asChild?n:i.jsx("polygon",{points:"0,0 30,0 15,10"})})});a1.displayName=oA;var iA=a1;function l1(e){const[t,n]=h.useState(void 0);return rt(()=>{if(e){n({width:e.offsetWidth,height:e.offsetHeight});const r=new ResizeObserver(s=>{if(!Array.isArray(s)||!s.length)return;const o=s[0];let a,l;if("borderBoxSize"in o){const c=o.borderBoxSize,u=Array.isArray(c)?c[0]:c;a=u.inlineSize,l=u.blockSize}else a=e.offsetWidth,l=e.offsetHeight;n({width:a,height:l})});return r.observe(e,{box:"border-box"}),()=>r.unobserve(e)}else n(void 0)},[e]),t}var Jm="Popper",[c1,hu]=qs(Jm),[aA,u1]=c1(Jm),d1=e=>{const{__scopePopper:t,children:n}=e,[r,s]=h.useState(null);return i.jsx(aA,{scope:t,anchor:r,onAnchorChange:s,children:n})};d1.displayName=Jm;var f1="PopperAnchor",h1=h.forwardRef((e,t)=>{const{__scopePopper:n,virtualRef:r,...s}=e,o=u1(f1,n),a=h.useRef(null),l=Se(t,a);return h.useEffect(()=>{o.onAnchorChange((r==null?void 0:r.current)||a.current)}),r?null:i.jsx(fe.div,{...s,ref:l})});h1.displayName=f1;var Zm="PopperContent",[lA,cA]=c1(Zm),m1=h.forwardRef((e,t)=>
vendor: 4,444 bytes, line 301
301{var F,Z,we,ae,le,ce;const{__scopePopper:n,side:r="bottom",sideOffset:s=0,align:o="center",alignOffset:a=0,arrowPadding:l=0,avoidCollisions:c=!0,collisionBoundary:u=[],collisionPadding:d=0,sticky:f="partial",hideWhenDetached:m=!1,updatePositionStrategy:p="optimized",onPlaced:b,...x}=e,y=u1(Zm,n),[w,g]=h.useState(null),v=Se(t,Be=>g(Be)),[S,j]=h.useState(null),C=l1(S),P=(C==null?void 0:C.width)??0,N=(C==null?void 0:C.height)??0,E=r+(o!=="center"?"-"+o:""),k=typeof d=="number"?d:{top:0,right:0,bottom:0,left:0,...d},R=Array.isArray(u)?u:[u],M=R.length>0,I={padding:k,boundary:R.filter(dA),altBoundary:M},{refs:O,floatingStyles:H,placement:B,isPositioned:U,middlewareData:T}=QR({strategy:"fixed",placement:E,whileElementsMounted:(...Be)=>$R(...Be,{animationFrame:p==="always"}),elements:{reference:y.anchor},middleware:[JR({mainAxis:s+N,alignmentAxis:a}),c&&ZR({mainAxis:!0,crossAxis:!1,limiter:f==="partial"?eA():void 0,...I}),c&&tA({...I}),nA({...I,apply:({elements:Be,rects:St,availableWidth:Rt,availableHeight:At})=>{const{width:Jt,height:Zt}=St.reference,$t=Be.floating.style;$t.setProperty("--radix-popper-available-width",`${Rt}px`),$t.setProperty("--radix-popper-available-height",`${At}px`),$t.setProperty("--radix-popper-anchor-width",`${Jt}px`),$t.setProperty("--radix-popper-anchor-height",`${Zt}px`)}}),S&&sA({element:S,padding:l}),fA({arrowWidth:P,arrowHeight:N}),m&&rA({strategy:"referenceHidden",...I})]}),[A,L]=x1(B),_=bn(b);rt(()=>{U&&(_==null||_())},[U,_]);const $=(F=T.arrow)==null?void 0:F.x,J=(Z=T.arrow)==null?void 0:Z.y,ee=((we=T.arrow)==null?void 0:we.centerOffset)!==0,[Q,ne]=h.useState();return rt(()=>{w&&ne(window.getComputedStyle(w).zIndex)},[w]),i.jsx("div",{ref:O.setFloating,"data-radix-popper-content-wrapper":"",style:{...H,transform:U?H.transform:"translate(0, -200%)",minWidth:"max-content",zIndex:Q,"--radix-popper-transform-origin":[(ae=T.transformOrigin)==null?void 0:ae.x,(le=T.transformOrigin)==null?void 0:le.y].join(" "),...((ce=T.hide)==null?void 0:ce.referenceHidden)&&{visibility:"hidden",pointerEvents:"none"}},dir:e.dir,children:i.jsx(lA,{scope:n,placedSide:A,onArrowChange:j,arrowX:$,arrowY:J,shouldHideArrow:ee,children:i.jsx(fe.div,{"data-side":A,"data-align":L,...x,ref:v,style:{...x.style,animation:U?void 0:"none"}})})})});m1.displayName=Zm;var p1="PopperArrow",uA={top:"bottom",right:"left",bottom:"top",left:"right"},g1=h.forwardRef(function(t,n){const{__scopePopper:r,...s}=t,o=cA(p1,r),a=uA[o.placedSide];return i.jsx("span",{ref:o.onArrowChange,style:{position:"absolute",left:o.arrowX,top:o.arrowY,[a]:0,transformOrigin:{top:"",right:"0 0",bottom:"center 0",left:"100% 0"}[o.placedSide],transform:{top:"translateY(100%)",right:"translateY(50%) rotate(90deg) translateX(-50%)",bottom:"rotate(180deg)",left:"translateY(50%) rotate(-90deg) translateX(50%)"}[o.placedSide],visibility:o.shouldHideArrow?"hidden":void 0},children:i.jsx(iA,{...s,ref:n,style:{...s.style,display:"block"}})})});g1.displayName=p1;function dA(e){return e!==null}var fA=e=>({name:"transformOrigin",options:e,fn(t){var y,w,g;const{placement:n,rects:r,middlewareData:s}=t,a=((y=s.arrow)==null?void 0:y.centerOffset)!==0,l=a?0:e.arrowWidth,c=a?0:e.arrowHeight,[u,d]=x1(n),f={start:"0%",center:"50%",end:"100%"}[d],m=(((w=s.arrow)==null?void 0:w.x)??0)+l/2,p=(((g=s.arrow)==null?void 0:g.y)??0)+c/2;let b="",x="";return u==="bottom"?(b=a?f:`${m}px`,x=`${-c}px`):u==="top"?(b=a?f:`${m}px`,x=`${r.floating.height+c}px`):u==="right"?(b=`${-c}px`,x=a?f:`${p}px`):u==="left"&&(b=`${r.floating.width+c}px`,x=a?f:`${p}px`),{data:{x:b,y:x}}}});function x1(e){const[t,n="center"]=e.split("-");return[t,n]}var hA=d1,y1=h1,v1=m1,w1=g1,[mu]=qs("Tooltip",[hu]),ep=hu(),b1="TooltipProvider",mA=700,Dx="tooltip.open",[pA,S1]=mu(b1),j1=e=>{const{__scopeTooltip:t,delayDuration:n=mA,skipDelayDuration:r=300,disableHoverableContent:s=!1,children:o}=e,a=h.useRef(!0),l=h.useRef(!1),c=h.useRef(0);return h.useEffect(()=>{const u=c.current;return()=>window.clearTimeout(u)},[]),i.jsx(pA,{scope:t,isOpenDelayedRef:a,delayDuration:n,onOpen:h.useCallback(()=>{window.clearTimeout(c.current),a.current=!1},[]),onClose:h.useCallback(()=>{window.clearTimeout(c.current),c.current=window.setTimeout(()=>a.current=!0,r)},[r]),isPointerInTransitRef:l,onPointerInTransitChange:h.useCallback(u=>{l.current=u},[]),disableHoverableContent:s,children:o})};j1.displayName=b1;var N1="Tooltip",[OV,pu]=mu(N1),oh="TooltipTrigger",gA=h.forwardRef((e,t)=>
vendor: 5,143 bytes, line 301
301{const{__scopeTooltip:n,...r}=e,s=pu(oh,n),o=S1(oh,n),a=ep(n),l=h.useRef(null),c=Se(t,l,s.onTriggerChange),u=h.useRef(!1),d=h.useRef(!1),f=h.useCallback(()=>u.current=!1,[]);return h.useEffect(()=>()=>document.removeEventListener("pointerup",f),[f]),i.jsx(y1,{asChild:!0,...a,children:i.jsx(fe.button,{"aria-describedby":s.open?s.contentId:void 0,"data-state":s.stateAttribute,...r,ref:c,onPointerMove:oe(e.onPointerMove,m=>{m.pointerType!=="touch"&&!d.current&&!o.isPointerInTransitRef.current&&(s.onTriggerEnter(),d.current=!0)}),onPointerLeave:oe(e.onPointerLeave,()=>{s.onTriggerLeave(),d.current=!1}),onPointerDown:oe(e.onPointerDown,()=>{s.open&&s.onClose(),u.current=!0,document.addEventListener("pointerup",f,{once:!0})}),onFocus:oe(e.onFocus,()=>{u.current||s.onOpen()}),onBlur:oe(e.onBlur,s.onClose),onClick:oe(e.onClick,s.onClose)})})});gA.displayName=oh;var xA="TooltipPortal",[IV,yA]=mu(xA,{forceMount:void 0}),Zo="TooltipContent",C1=h.forwardRef((e,t)=>{const n=yA(Zo,e.__scopeTooltip),{forceMount:r=n.forceMount,side:s="top",...o}=e,a=pu(Zo,e.__scopeTooltip);return i.jsx(ai,{present:r||a.open,children:a.disableHoverableContent?i.jsx(k1,{side:s,...o,ref:t}):i.jsx(vA,{side:s,...o,ref:t})})}),vA=h.forwardRef((e,t)=>{const n=pu(Zo,e.__scopeTooltip),r=S1(Zo,e.__scopeTooltip),s=h.useRef(null),o=Se(t,s),[a,l]=h.useState(null),{trigger:c,onClose:u}=n,d=s.current,{onPointerInTransitChange:f}=r,m=h.useCallback(()=>{l(null),f(!1)},[f]),p=h.useCallback((b,x)=>{const y=b.currentTarget,w={x:b.clientX,y:b.clientY},g=NA(w,y.getBoundingClientRect()),v=CA(w,g),S=kA(x.getBoundingClientRect()),j=EA([...v,...S]);l(j),f(!0)},[f]);return h.useEffect(()=>()=>m(),[m]),h.useEffect(()=>{if(c&&d){const b=y=>p(y,d),x=y=>p(y,c);return c.addEventListener("pointerleave",b),d.addEventListener("pointerleave",x),()=>{c.removeEventListener("pointerleave",b),d.removeEventListener("pointerleave",x)}}},[c,d,p,m]),h.useEffect(()=>{if(a){const b=x=>{const y=x.target,w={x:x.clientX,y:x.clientY},g=(c==null?void 0:c.contains(y))||(d==null?void 0:d.contains(y)),v=!PA(w,a);g?m():v&&(m(),u())};return document.addEventListener("pointermove",b),()=>document.removeEventListener("pointermove",b)}},[c,d,a,u,m]),i.jsx(k1,{...e,ref:o})}),[wA,bA]=mu(N1,{isInside:!1}),SA=yP("TooltipContent"),k1=h.forwardRef((e,t)=>{const{__scopeTooltip:n,children:r,"aria-label":s,onEscapeKeyDown:o,onPointerDownOutside:a,...l}=e,c=pu(Zo,n),u=ep(n),{onClose:d}=c;return h.useEffect(()=>(document.addEventListener(Dx,d),()=>document.removeEventListener(Dx,d)),[d]),h.useEffect(()=>{if(c.trigger){const f=m=>{const p=m.target;p!=null&&p.contains(c.trigger)&&d()};return window.addEventListener("scroll",f,{capture:!0}),()=>window.removeEventListener("scroll",f,{capture:!0})}},[c.trigger,d]),i.jsx(za,{asChild:!0,disableOutsidePointerEvents:!1,onEscapeKeyDown:o,onPointerDownOutside:a,onFocusOutside:f=>f.preventDefault(),onDismiss:d,children:i.jsxs(v1,{"data-state":c.stateAttribute,...u,...l,ref:t,style:{...l.style,"--radix-tooltip-content-transform-origin":"var(--radix-popper-transform-origin)","--radix-tooltip-content-available-width":"var(--radix-popper-available-width)","--radix-tooltip-content-available-height":"var(--radix-popper-available-height)","--radix-tooltip-trigger-width":"var(--radix-popper-anchor-width)","--radix-tooltip-trigger-height":"var(--radix-popper-anchor-height)"},children:[i.jsx(SA,{children:r}),i.jsx(wA,{scope:n,isInside:!0,children:i.jsx($P,{id:c.contentId,role:"tooltip",children:s||r})})]})})});C1.displayName=Zo;var P1="TooltipArrow",jA=h.forwardRef((e,t)=>{const{__scopeTooltip:n,...r}=e,s=ep(n);return bA(P1,n).isInside?null:i.jsx(w1,{...s,...r,ref:t})});jA.displayName=P1;function NA(e,t){const n=Math.abs(t.top-e.y),r=Math.abs(t.bottom-e.y),s=Math.abs(t.right-e.x),o=Math.abs(t.left-e.x);switch(Math.min(n,r,s,o)){case o:return"left";case s:return"right";case n:return"top";case r:return"bottom";default:throw new Error("unreachable")}}function CA(e,t,n=5){const r=[];switch(t){case"top":r.push({x:e.x-n,y:e.y+n},{x:e.x+n,y:e.y+n});break;case"bottom":r.push({x:e.x-n,y:e.y-n},{x:e.x+n,y:e.y-n});break;case"left":r.push({x:e.x+n,y:e.y-n},{x:e.x+n,y:e.y+n});break;case"right":r.push({x:e.x-n,y:e.y-n},{x:e.x-n,y:e.y+n});break}return r}function kA(e){const{top:t,right:n,bottom:r,left:s}=e;return[{x:s,y:t},{x:n,y:t},{x:n,y:r},{x:s,y:r}]}function PA(e,t){const{x:n,y:r}=e;let s=!1;for(let o=0,a=t.length-1;o<t.length;a=o++){const l=t[o],c=t[a],u=l.x,d=l.y,f=c.x,m=c.y;d>r!=m>r&&n<(f-u)*(r-d)/(m-d)+u&&(s=!s)}return s}function EA(e){const t=e.slice();return t.sort((n,r)=>n.x<r.x?-1:n.x>r.x?1:n.y<r.y?-1:n.y>r.y?1:0),TA(t)}function TA(e){if(e.length<=1)return e.slice();const t=[];for(let r=0;r<e.length;r++){const s=e[r];for(;t.length>=2;){const o=t[t.length-1],a=t[t.length-2];if((o.x-a.x)*(s.y-a.y)>=(o.y-a.y)*(s.x-a.x))t.pop();else break}t.push(s)}t.pop();const n=[];for(let r=e.length-1;r>=0;r--){const s=e[r];for(;n.length>=2;){const o=n[n.length-1],a=n[n.length-2];if((o.x-a.x)*(s.y-a.y)>=(o.y-a.y)*(s.x-a.x))n.pop();else break}n.push(s)}return n.pop(),t.length===1&&n.length===1&&t[0].x===n[0].x&&t[0].y===n[0].y?t:t.concat(n)}
vendor: 8,923 bytes, line 301
301var RA=j1,E1=C1;const AA=RA,MA=h.forwardRef(({className:e,sideOffset:t=4,...n},r)=>i.jsx(E1,{ref:r,sideOffset:t,className:Y("z-50 overflow-hidden rounded-md border bg-popover px-3 py-1.5 text-sm text-popover-foreground shadow-md animate-in fade-in-0 zoom-in-95 data-[state=closed]:animate-out data-[state=closed]:fade-out-0 data-[state=closed]:zoom-out-95 data-[side=bottom]:slide-in-from-top-2 data-[side=left]:slide-in-from-right-2 data-[side=right]:slide-in-from-left-2 data-[side=top]:slide-in-from-bottom-2",e),...n}));MA.displayName=E1.displayName;var gu=class{constructor(){this.listeners=new Set,this.subscribe=this.subscribe.bind(this)}subscribe(e){return this.listeners.add(e),this.onSubscribe(),()=>{this.listeners.delete(e),this.onUnsubscribe()}}hasListeners(){return this.listeners.size>0}onSubscribe(){}onUnsubscribe(){}},xu=typeof window>"u"||"Deno"in globalThis;function dn(){}function OA(e,t){return typeof e=="function"?e(t):e}function IA(e){return typeof e=="number"&&e>=0&&e!==1/0}function DA(e,t){return Math.max(e+(t||0)-Date.now(),0)}function ih(e,t){return typeof e=="function"?e(t):e}function LA(e,t){return typeof e=="function"?e(t):e}function Lx(e,t){const{type:n="all",exact:r,fetchStatus:s,predicate:o,queryKey:a,stale:l}=e;if(a){if(r){if(t.queryHash!==tp(a,t.options))return!1}else if(!Ca(t.queryKey,a))return!1}if(n!=="all"){const c=t.isActive();if(n==="active"&&!c||n==="inactive"&&c)return!1}return!(typeof l=="boolean"&&t.isStale()!==l||s&&s!==t.state.fetchStatus||o&&!o(t))}function _x(e,t){const{exact:n,status:r,predicate:s,mutationKey:o}=e;if(o){if(!t.options.mutationKey)return!1;if(n){if(Na(t.options.mutationKey)!==Na(o))return!1}else if(!Ca(t.options.mutationKey,o))return!1}return!(r&&t.state.status!==r||s&&!s(t))}function tp(e,t){return((t==null?void 0:t.queryKeyHashFn)||Na)(e)}function Na(e){return JSON.stringify(e,(t,n)=>ah(n)?Object.keys(n).sort().reduce((r,s)=>(r[s]=n[s],r),{}):n)}function Ca(e,t){return e===t?!0:typeof e!=typeof t?!1:e&&t&&typeof e=="object"&&typeof t=="object"?Object.keys(t).every(n=>Ca(e[n],t[n])):!1}function T1(e,t){if(e===t)return e;const n=Fx(e)&&Fx(t);if(n||ah(e)&&ah(t)){const r=n?e:Object.keys(e),s=r.length,o=n?t:Object.keys(t),a=o.length,l=n?[]:{},c=new Set(r);let u=0;for(let d=0;d<a;d++){const f=n?d:o[d];(!n&&c.has(f)||n)&&e[f]===void 0&&t[f]===void 0?(l[f]=void 0,u++):(l[f]=T1(e[f],t[f]),l[f]===e[f]&&e[f]!==void 0&&u++)}return s===a&&u===s?e:l}return t}function Fx(e){return Array.isArray(e)&&e.length===Object.keys(e).length}function ah(e){if(!Vx(e))return!1;const t=e.constructor;if(t===void 0)return!0;const n=t.prototype;return!(!Vx(n)||!n.hasOwnProperty("isPrototypeOf")||Object.getPrototypeOf(e)!==Object.prototype)}function Vx(e){return Object.prototype.toString.call(e)==="[object Object]"}function _A(e){return new Promise(t=>{setTimeout(t,e)})}function FA(e,t,n){return typeof n.structuralSharing=="function"?n.structuralSharing(e,t):n.structuralSharing!==!1?T1(e,t):t}function VA(e,t,n=0){const r=[...e,t];return n&&r.length>n?r.slice(1):r}function $A(e,t,n=0){const r=[t,...e];return n&&r.length>n?r.slice(0,-1):r}var np=Symbol();function R1(e,t){return!e.queryFn&&(t!=null&&t.initialPromise)?()=>t.initialPromise:!e.queryFn||e.queryFn===np?()=>Promise.reject(new Error(`Missing queryFn: '${e.queryHash}'`)):e.queryFn}var ks,_r,Do,Fv,BA=(Fv=class extends gu{constructor(){super();ge(this,ks);ge(this,_r);ge(this,Do);se(this,Do,t=>{if(!xu&&window.addEventListener){const n=()=>t();return window.addEventListener("visibilitychange",n,!1),()=>{window.removeEventListener("visibilitychange",n)}}})}onSubscribe(){D(this,_r)||this.setEventListener(D(this,Do))}onUnsubscribe(){var t;this.hasListeners()||((t=D(this,_r))==null||t.call(this),se(this,_r,void 0))}setEventListener(t){var n;se(this,Do,t),(n=D(this,_r))==null||n.call(this),se(this,_r,t(r=>{typeof r=="boolean"?this.setFocused(r):this.onFocus()}))}setFocused(t){D(this,ks)!==t&&(se(this,ks,t),this.onFocus())}onFocus(){const t=this.isFocused();this.listeners.forEach(n=>{n(t)})}isFocused(){var t;return typeof D(this,ks)=="boolean"?D(this,ks):((t=globalThis.document)==null?void 0:t.visibilityState)!=="hidden"}},ks=new WeakMap,_r=new WeakMap,Do=new WeakMap,Fv),A1=new BA,Lo,Fr,_o,Vv,zA=(Vv=class extends gu{constructor(){super();ge(this,Lo,!0);ge(this,Fr);ge(this,_o);se(this,_o,t=>{if(!xu&&window.addEventListener){const n=()=>t(!0),r=()=>t(!1);return window.addEventListener("online",n,!1),window.addEventListener("offline",r,!1),()=>{window.removeEventListener("online",n),window.removeEventListener("offline",r)}}})}onSubscribe(){D(this,Fr)||this.setEventListener(D(this,_o))}onUnsubscribe(){var t;this.hasListeners()||((t=D(this,Fr))==null||t.call(this),se(this,Fr,void 0))}setEventListener(t){var n;se(this,_o,t),(n=D(this,Fr))==null||n.call(this),se(this,Fr,t(this.setOnline.bind(this)))}setOnline(t){D(this,Lo)!==t&&(se(this,Lo,t),this.listeners.forEach(r=>{r(t)}))}isOnline(){return D(this,Lo)}},Lo=new WeakMap,Fr=new WeakMap,_o=new WeakMap,Vv),Ac=new zA;function UA(){let e,t;const n=new Promise((s,o)=>{e=s,t=o});n.status="pending",n.catch(()=>{});function r(s){Object.assign(n,s),delete n.resolve,delete n.reject}return n.resolve=s=>{r({status:"fulfilled",value:s}),e(s)},n.reject=s=>{r({status:"rejected",reason:s}),t(s)},n}function WA(e){return Math.min(1e3*2**e,3e4)}function M1(e){return(e??"online")==="online"?Ac.isOnline():!0}var O1=class extends Error{constructor(e){super("CancelledError"),this.revert=e==null?void 0:e.revert,this.silent=e==null?void 0:e.silent}};function bd(e){return e instanceof O1}function I1(e){let t=!1,n=0,r=!1,s;const o=UA(),a=x=>{var y;r||(m(new O1(x)),(y=e.abort)==null||y.call(e))},l=()=>{t=!0},c=()=>{t=!1},u=()=>A1.isFocused()&&(e.networkMode==="always"||Ac.isOnline())&&e.canRun(),d=()=>M1(e.networkMode)&&e.canRun(),f=x=>{var y;r||(r=!0,(y=e.onSuccess)==null||y.call(e,x),s==null||s(),o.resolve(x))},m=x=>{var y;r||(r=!0,(y=e.onError)==null||y.call(e,x),s==null||s(),o.reject(x))},p=()=>new Promise(x=>{var y;s=w=>{(r||u())&&x(w)},(y=e.onPause)==null||y.call(e)}).then(()=>{var x;s=void 0,r||(x=e.onContinue)==null||x.call(e)}),b=()=>{if(r)return;let x;const y=n===0?e.initialPromise:void 0;try{x=y??e.fn()}catch(w){x=Promise.reject(w)}Promise.resolve(x).then(f).catch(w=>{var C;if(r)return;const g=e.retry??(xu?0:3),v=e.retryDelay??WA,S=typeof v=="function"?v(n,w):v,j=g===!0||typeof g=="number"&&n<g||typeof g=="function"&&g(n,w);if(t||!j){m(w);return}n++,(C=e.onFail)==null||C.call(e,n,w),_A(S).then(()=>u()?void 0:p()).then(()=>{t?m(w):b()})})};return{promise:o,cancel:a,continue:()=>(s==null||s(),o),cancelRetry:l,continueRetry:c,canStart:d,start:()=>(d()?b():p().then(b),o)}}var HA=e=>setTimeout(e,0);function KA(){let e=[],t=0,n=l=>{l()},r=l=>{l()},s=HA;const o=l=>{t?e.push(l):s(()=>{n(l)})},a=()=>{const l=e;e=[],l.length&&s(()=>{r(()=>{l.forEach(c=>{n(c)})})})};return{batch:l=>{let c;t++;try{c=l()}finally{t--,t||a()}return c},batchCalls:l=>(...c)=>{o(()=>{l(...c)})},schedule:o,setNotifyFunction:l=>{n=l},setBatchNotifyFunction:l=>{r=l},setScheduler:l=>{s=l}}}var mt=KA(),Ps,$v,D1=($v=class{constructor(){ge(this,Ps)}destroy(){this.clearGcTimeout()}scheduleGc(){this.clearGcTimeout(),IA(this.gcTime)&&se(this,Ps,setTimeout(()=>{this.optionalRemove()},this.gcTime))}updateGcTime(e){this.gcTime=Math.max(this.gcTime||0,e??(xu?1/0:5*60*1e3))}clearGcTimeout(){D(this,Ps)&&(clearTimeout(D(this,Ps)),se(this,Ps,void 0))}},Ps=new WeakMap,$v),Fo,Es,zt,Ts,at,Da,Rs,fn,Gn,Bv,YA=(Bv=class extends D1{constructor(t){super();ge(this,fn);ge(this,Fo);ge(this,Es);ge(this,zt);ge(this,Ts);ge(this,at);ge(this,Da);ge(this,Rs);se(this,Rs,!1),se(this,Da,t.defaultOptions),this.setOptions(t.options),this.observers=[],se(this,Ts,t.client),se(this,zt,D(this,Ts).getQueryCache()),this.queryKey=t.queryKey,this.queryHash=t.queryHash,se(this,Fo,qA(this.options)),this.state=t.state??D(this,Fo),this.scheduleGc()}get meta(){return this.options.meta}get promise(){var t;return(t=D(this,at))==null?void 0:t.promise}setOptions(t){this.options={...D(this,Da),...t},this.updateGcTime(this.options.gcTime)}optionalRemove(){!this.observers.length&&this.state.fetchStatus==="idle"&&D(this,zt).remove(this)}setData(t,n){const r=FA(this.state.data,t,this.options);return st(this,fn,Gn).call(this,{data:r,type:"success",dataUpdatedAt:n==null?void 0:n.updatedAt,manual:n==null?void 0:n.manual}),r}setState(t,n){st(this,fn,Gn).call(this,{type:"setState",state:t,setStateOptions:n})}cancel(t){var r,s;const n=(r=D(this,at))==null?void 0:r.promise;return(s=D(this,at))==null||s.cancel(t),n?n.then(dn).catch(dn):Promise.resolve()}destroy(){super.destroy(),this.cancel({silent:!0})}reset(){this.destroy(),this.setState(D(this,Fo))}isActive(){return this.observers.some(t=>LA(t.options.enabled,this)!==!1)}isDisabled(){return this.getObserversCount()>0?!this.isActive():this.options.queryFn===np||this.state.dataUpdateCount+this.state.errorUpdate
vendor: 1,274 bytes, line 301
301Count===0}isStatic(){return this.getObserversCount()>0?this.observers.some(t=>ih(t.options.staleTime,this)==="static"):!1}isStale(){return this.getObserversCount()>0?this.observers.some(t=>t.getCurrentResult().isStale):this.state.data===void 0||this.state.isInvalidated}isStaleByTime(t=0){return this.state.data===void 0?!0:t==="static"?!1:this.state.isInvalidated?!0:!DA(this.state.dataUpdatedAt,t)}onFocus(){var n;const t=this.observers.find(r=>r.shouldFetchOnWindowFocus());t==null||t.refetch({cancelRefetch:!1}),(n=D(this,at))==null||n.continue()}onOnline(){var n;const t=this.observers.find(r=>r.shouldFetchOnReconnect());t==null||t.refetch({cancelRefetch:!1}),(n=D(this,at))==null||n.continue()}addObserver(t){this.observers.includes(t)||(this.observers.push(t),this.clearGcTimeout(),D(this,zt).notify({type:"observerAdded",query:this,observer:t}))}removeObserver(t){this.observers.includes(t)&&(this.observers=this.observers.filter(n=>n!==t),this.observers.length||(D(this,at)&&(D(this,Rs)?D(this,at).cancel({revert:!0}):D(this,at).cancelRetry()),this.scheduleGc()),D(this,zt).notify({type:"observerRemoved",query:this,observer:t}))}getObserversCount(){return this.observers.length}invalidate(){this.state.isInvalidated||st(this,fn,Gn).call(this,{type:"invalidate"})}
vendor: 13,738 bytes, line 301
301fetch(t,n){var u,d,f;if(this.state.fetchStatus!=="idle"){if(this.state.data!==void 0&&(n!=null&&n.cancelRefetch))this.cancel({silent:!0});else if(D(this,at))return D(this,at).continueRetry(),D(this,at).promise}if(t&&this.setOptions(t),!this.options.queryFn){const m=this.observers.find(p=>p.options.queryFn);m&&this.setOptions(m.options)}const r=new AbortController,s=m=>{Object.defineProperty(m,"signal",{enumerable:!0,get:()=>(se(this,Rs,!0),r.signal)})},o=()=>{const m=R1(this.options,n),b=(()=>{const x={client:D(this,Ts),queryKey:this.queryKey,meta:this.meta};return s(x),x})();return se(this,Rs,!1),this.options.persister?this.options.persister(m,b,this):m(b)},l=(()=>{const m={fetchOptions:n,options:this.options,queryKey:this.queryKey,client:D(this,Ts),state:this.state,fetchFn:o};return s(m),m})();(u=this.options.behavior)==null||u.onFetch(l,this),se(this,Es,this.state),(this.state.fetchStatus==="idle"||this.state.fetchMeta!==((d=l.fetchOptions)==null?void 0:d.meta))&&st(this,fn,Gn).call(this,{type:"fetch",meta:(f=l.fetchOptions)==null?void 0:f.meta});const c=m=>{var p,b,x,y;bd(m)&&m.silent||st(this,fn,Gn).call(this,{type:"error",error:m}),bd(m)||((b=(p=D(this,zt).config).onError)==null||b.call(p,m,this),(y=(x=D(this,zt).config).onSettled)==null||y.call(x,this.state.data,m,this)),this.scheduleGc()};return se(this,at,I1({initialPromise:n==null?void 0:n.initialPromise,fn:l.fetchFn,abort:r.abort.bind(r),onSuccess:m=>{var p,b,x,y;if(m===void 0){c(new Error(`${this.queryHash} data is undefined`));return}try{this.setData(m)}catch(w){c(w);return}(b=(p=D(this,zt).config).onSuccess)==null||b.call(p,m,this),(y=(x=D(this,zt).config).onSettled)==null||y.call(x,m,this.state.error,this),this.scheduleGc()},onError:c,onFail:(m,p)=>{st(this,fn,Gn).call(this,{type:"failed",failureCount:m,error:p})},onPause:()=>{st(this,fn,Gn).call(this,{type:"pause"})},onContinue:()=>{st(this,fn,Gn).call(this,{type:"continue"})},retry:l.options.retry,retryDelay:l.options.retryDelay,networkMode:l.options.networkMode,canRun:()=>!0})),D(this,at).start()}},Fo=new WeakMap,Es=new WeakMap,zt=new WeakMap,Ts=new WeakMap,at=new WeakMap,Da=new WeakMap,Rs=new WeakMap,fn=new WeakSet,Gn=function(t){const n=r=>{switch(t.type){case"failed":return{...r,fetchFailureCount:t.failureCount,fetchFailureReason:t.error};case"pause":return{...r,fetchStatus:"paused"};case"continue":return{...r,fetchStatus:"fetching"};case"fetch":return{...r,...GA(r.data,this.options),fetchMeta:t.meta??null};case"success":return se(this,Es,void 0),{...r,data:t.data,dataUpdateCount:r.dataUpdateCount+1,dataUpdatedAt:t.dataUpdatedAt??Date.now(),error:null,isInvalidated:!1,status:"success",...!t.manual&&{fetchStatus:"idle",fetchFailureCount:0,fetchFailureReason:null}};case"error":const s=t.error;return bd(s)&&s.revert&&D(this,Es)?{...D(this,Es),fetchStatus:"idle"}:{...r,error:s,errorUpdateCount:r.errorUpdateCount+1,errorUpdatedAt:Date.now(),fetchFailureCount:r.fetchFailureCount+1,fetchFailureReason:s,fetchStatus:"idle",status:"error"};case"invalidate":return{...r,isInvalidated:!0};case"setState":return{...r,...t.state}}};this.state=n(this.state),mt.batch(()=>{this.observers.forEach(r=>{r.onQueryUpdate()}),D(this,zt).notify({query:this,type:"updated",action:t})})},Bv);function GA(e,t){return{fetchFailureCount:0,fetchFailureReason:null,fetchStatus:M1(t.networkMode)?"fetching":"paused",...e===void 0&&{error:null,status:"pending"}}}function qA(e){const t=typeof e.initialData=="function"?e.initialData():e.initialData,n=t!==void 0,r=n?typeof e.initialDataUpdatedAt=="function"?e.initialDataUpdatedAt():e.initialDataUpdatedAt:0;return{data:t,dataUpdateCount:0,dataUpdatedAt:n?r??Date.now():0,error:null,errorUpdateCount:0,errorUpdatedAt:0,fetchFailureCount:0,fetchFailureReason:null,fetchMeta:null,isInvalidated:!1,status:n?"success":"pending",fetchStatus:"idle"}}var En,zv,QA=(zv=class extends gu{constructor(t={}){super();ge(this,En);this.config=t,se(this,En,new Map)}build(t,n,r){const s=n.queryKey,o=n.queryHash??tp(s,n);let a=this.get(o);return a||(a=new YA({client:t,queryKey:s,queryHash:o,options:t.defaultQueryOptions(n),state:r,defaultOptions:t.getQueryDefaults(s)}),this.add(a)),a}add(t){D(this,En).has(t.queryHash)||(D(this,En).set(t.queryHash,t),this.notify({type:"added",query:t}))}remove(t){const n=D(this,En).get(t.queryHash);n&&(t.destroy(),n===t&&D(this,En).delete(t.queryHash),this.notify({type:"removed",query:t}))}clear(){mt.batch(()=>{this.getAll().forEach(t=>{this.remove(t)})})}get(t){return D(this,En).get(t)}getAll(){return[...D(this,En).values()]}find(t){const n={exact:!0,...t};return this.getAll().find(r=>Lx(n,r))}findAll(t={}){const n=this.getAll();return Object.keys(t).length>0?n.filter(r=>Lx(t,r)):n}notify(t){mt.batch(()=>{this.listeners.forEach(n=>{n(t)})})}onFocus(){mt.batch(()=>{this.getAll().forEach(t=>{t.onFocus()})})}onOnline(){mt.batch(()=>{this.getAll().forEach(t=>{t.onOnline()})})}},En=new WeakMap,zv),Tn,ft,As,Rn,Tr,Uv,XA=(Uv=class extends D1{constructor(t){super();ge(this,Rn);ge(this,Tn);ge(this,ft);ge(this,As);this.mutationId=t.mutationId,se(this,ft,t.mutationCache),se(this,Tn,[]),this.state=t.state||JA(),this.setOptions(t.options),this.scheduleGc()}setOptions(t){this.options=t,this.updateGcTime(this.options.gcTime)}get meta(){return this.options.meta}addObserver(t){D(this,Tn).includes(t)||(D(this,Tn).push(t),this.clearGcTimeout(),D(this,ft).notify({type:"observerAdded",mutation:this,observer:t}))}removeObserver(t){se(this,Tn,D(this,Tn).filter(n=>n!==t)),this.scheduleGc(),D(this,ft).notify({type:"observerRemoved",mutation:this,observer:t})}optionalRemove(){D(this,Tn).length||(this.state.status==="pending"?this.scheduleGc():D(this,ft).remove(this))}continue(){var t;return((t=D(this,As))==null?void 0:t.continue())??this.execute(this.state.variables)}async execute(t){var o,a,l,c,u,d,f,m,p,b,x,y,w,g,v,S,j,C,P,N;const n=()=>{st(this,Rn,Tr).call(this,{type:"continue"})};se(this,As,I1({fn:()=>this.options.mutationFn?this.options.mutationFn(t):Promise.reject(new Error("No mutationFn found")),onFail:(E,k)=>{st(this,Rn,Tr).call(this,{type:"failed",failureCount:E,error:k})},onPause:()=>{st(this,Rn,Tr).call(this,{type:"pause"})},onContinue:n,retry:this.options.retry??0,retryDelay:this.options.retryDelay,networkMode:this.options.networkMode,canRun:()=>D(this,ft).canRun(this)}));const r=this.state.status==="pending",s=!D(this,As).canStart();try{if(r)n();else{st(this,Rn,Tr).call(this,{type:"pending",variables:t,isPaused:s}),await((a=(o=D(this,ft).config).onMutate)==null?void 0:a.call(o,t,this));const k=await((c=(l=this.options).onMutate)==null?void 0:c.call(l,t));k!==this.state.context&&st(this,Rn,Tr).call(this,{type:"pending",context:k,variables:t,isPaused:s})}const E=await D(this,As).start();return await((d=(u=D(this,ft).config).onSuccess)==null?void 0:d.call(u,E,t,this.state.context,this)),await((m=(f=this.options).onSuccess)==null?void 0:m.call(f,E,t,this.state.context)),await((b=(p=D(this,ft).config).onSettled)==null?void 0:b.call(p,E,null,this.state.variables,this.state.context,this)),await((y=(x=this.options).onSettled)==null?void 0:y.call(x,E,null,t,this.state.context)),st(this,Rn,Tr).call(this,{type:"success",data:E}),E}catch(E){try{throw await((g=(w=D(this,ft).config).onError)==null?void 0:g.call(w,E,t,this.state.context,this)),await((S=(v=this.options).onError)==null?void 0:S.call(v,E,t,this.state.context)),await((C=(j=D(this,ft).config).onSettled)==null?void 0:C.call(j,void 0,E,this.state.variables,this.state.context,this)),await((N=(P=this.options).onSettled)==null?void 0:N.call(P,void 0,E,t,this.state.context)),E}finally{st(this,Rn,Tr).call(this,{type:"error",error:E})}}finally{D(this,ft).runNext(this)}}},Tn=new WeakMap,ft=new WeakMap,As=new WeakMap,Rn=new WeakSet,Tr=function(t){const n=r=>{switch(t.type){case"failed":return{...r,failureCount:t.failureCount,failureReason:t.error};case"pause":return{...r,isPaused:!0};case"continue":return{...r,isPaused:!1};case"pending":return{...r,context:t.context,data:void 0,failureCount:0,failureReason:null,error:null,isPaused:t.isPaused,status:"pending",variables:t.variables,submittedAt:Date.now()};case"success":return{...r,data:t.data,failureCount:0,failureReason:null,error:null,status:"success",isPaused:!1};case"error":return{...r,data:void 0,error:t.error,failureCount:r.failureCount+1,failureReason:t.error,isPaused:!1,status:"error"}}};this.state=n(this.state),mt.batch(()=>{D(this,Tn).forEach(r=>{r.onMutationUpdate(t)}),D(this,ft).notify({mutation:this,type:"updated",action:t})})},Uv);function JA(){return{context:void 0,data:void 0,error:null,failureCount:0,failureReason:null,isPaused:!1,status:"idle",variables:void 0,submittedAt:0}}var Xn,hn,La,Wv,ZA=(Wv=class extends gu{constructor(t={}){super();ge(this,Xn);ge(this,hn);ge(this,La);this.config=t,se(this,Xn,new Set),se(this,hn,new Map),se(this,La,0)}build(t,n,r){const s=new XA({mutationCache:this,mutationId:++Qa(this,La)._,options:t.defaultMutationOptions(n),state:r});return this.add(s),s}add(t){D(this,Xn).add(t);const n=yl(t);if(typeof n=="string"){const r=D(this,hn).get(n);r?r.push(t):D(this,hn).set(n,[t])}this.notify({type:"added",mutation:t})}remove(t){if(D(this,Xn).delete(t)){const n=yl(t);if(typeof n=="string"){const r=D(this,hn).get(n);if(r)if(r.length>1){const s=r.indexOf(t);s!==-1&&r.splice(s,1)}else r[0]===t&&D(this,hn).delete(n)}}this.notify({type:"removed",mutation:t})}canRun(t){const n=yl(t);if(typeof n=="string"){const r=D(this,hn).get(n),s=r==null?void 0:r.find(o=>o.state.status==="pending");return!s||s===t}else return!0}runNext(t){var r;const n=yl(t);if(typeof n=="string"){const s=(r=D(this,hn).get(n))==null?void 0:r.find(o=>o!==t&&o.state.isPaused);return(s==null?void 0:s.continue())??Promise.resolve()}else return Promise.resolve()}clear(){mt.batch(()=>{D(this,Xn).forEach(t=>{this.notify({type:"removed",mutation:t})}),D(this,Xn).clear(),D(this,hn).clear()})}getAll(){return Array.from(D(this,Xn))}find(t){const n={exact:!0,...t};return this.getAll().find(r=>_x(n,r))}findAll(t={}){return this.getAll().filter(n=>_x(t,n))}notify(t){mt.batch(()=>{this.listeners.forEach(n=>{n(t)})})}resumePausedMutations(){const t=this.getAll().filter(n=>n.state.isPaused);return mt.batch(()=>Promise.all(t.map(n=>n.continue().catch(dn))))}},Xn=new WeakMap,hn=new WeakMap,La=new WeakMap,Wv);function yl(e){var t;return(t=e.options.scope)==null?void 0:t.id}function $x(e){return{onFetch:(t,n)=>{var d,f,m,p,b;const r=t.options,s=(m=(f=(d=t.fetchOptions)==null?void 0:d.meta)==null?void 0:f.fetchMore)==null?void 0:m.direction,o=((p=t.state.data)==null?void 0:p.pages)||[],a=((b=t.state.data)==null?void 0:b.pageParams)||[];let l={pages:[],pageParams:[]},c=0;const u=async()=>{let x=!1;const y=v=>{Object.defineProperty(v,"signal",{enumerable:!0,get:()=>(t.signal.aborted?x=!0:t.signal.addEventListener("abort",()=>{x=!0}),t.signal)})},w=R1(t.options,t.fetchOptions),g=async(v,S,j)=>{if(x)return Promise.reject();if(S==null&&v.pages.length)return Promise.resolve(v);const P=(()=>{const R={client:t.client,queryKey:t.queryKey,pageParam:S,direction:j?"backward":"forward",meta:t.options.meta};return y(R),R})(),N=await w(P),{maxPages:E}=t.options,k=j?$A:VA;return{pages:k(v.pages,N,E),pageParams:k(v.pageParams,S,E)}};if(s&&o.length){const v=s==="backward",S=v?eM:Bx,j={pages:o,pageParams:a},C=S(r,j);l=await g(j,C,v)}else{const v=e??o.length;do{const S=c===0?a[0]??r.initialPageParam:Bx(r,l);if(c>0&&S==null)break;l=await g(l,S),c++}while(c<v)}return l};t.options.persister?t.fetchFn=()=>{var x,y;return(y=(x=t.options).persister)==null?void 0:y.call(x,u,{client:t.client,queryKey:t.queryKey,meta:t.options.meta,signal:t.signal},n)}:t.fetchFn=u}}}function Bx(e,{pages:t,pageParams:n}){const r=t.length-1;return t.length>0?e.getNextPageParam(t[r],t,n[r],n):void 0}function eM(e,{pages:t,pageParams:n}){var r;return t.length>0?(r=e.getPreviousPageParam)==null?void 0:r.call(e,t[0],t,n[0],n):void 0}var Le,Vr,$r,Vo,$o,Br,Bo,zo,Hv,tM=(Hv=class{constructor(e={}){ge(this,Le);ge(this,Vr);ge(this,$r);ge(this,Vo);ge(this,$o);ge(this,Br);ge(this,Bo);ge(this,zo);se(this,Le,e.queryCache||new QA),se(this,Vr,e.mutationCache||new ZA),se(this,$r,e.defaultOptions||{}),se(this,Vo,new Map),se(this,$o,new Map),se(this,Br,0)}mount(){Qa(this,Br)._++,D(this,Br)===1&&(se(this,Bo,A1.subscribe(async e=>{e&&(await this.resumePausedMutations(),D(this,Le).onFocus())})),se(this,zo,Ac.subscribe(async e=>{e&&(await this.resumePausedMutations(),D(this,Le).onOnline())})))}unmount(){var e,t;Qa(this,Br)._--,D(this,Br)===0&&((e=D(this,Bo))==null||e.call(this),se(this,Bo,void 0),(t=D(this,zo))==null||t.call(this),se(this,zo,void 0))}isFetching(e){return D(this,Le).findAll({...e,fetchStatus:"fetching"}).length}isMutating(e){return D(this,Vr).findAll({...e,status:"pending"}).length}getQueryData(e){var n;const t=this.defaultQueryOptions({queryKey:e});return(n=D(this,Le).get(t.queryHash))==null?void 0:n.state.data}ensureQueryData(e){const t=this.defaultQueryOptions(e),n=D(this,Le).build(this,t),r=n.state.data;return r===void 0?this.fetchQuery(e):(e.revalidateIfStale&&n.isStaleByTime(ih(t.staleTime,n))&&this.prefetchQuery(t),Promise.resolve(r))}getQueriesData(e){return D(this,Le).findAll(e).map(({queryKey:t,state:n})=>{const r=n.data;return[t,r]})}setQueryData(e,t,n){const r=this.defaultQueryOptions({queryKey:e}),s=D(this,Le).get(r.queryHash),o=s==null?void 0:s.state.data,a=OA(t,o);if(a!==void 0)return D(this,Le).build(this,r).setData(a,{...n,manual:!0})}setQueriesData(e,t,n){return mt.batch(()=>D(this,Le).findAll(e).map(({queryKey:r})=>[r,this.setQueryData(r,t,n)]))}getQueryState(e){var n;const t=this.defaultQueryOptions({queryKey:e});return(n=D(this,Le).get(t.queryHash))==null?void 0:n.state}removeQueries(e){const t=D(this,Le);mt.batch(()=>
301{t.findAll(e).forEach(n=>{t.remove(n)})})}resetQueries(e,t){const n=D(this,Le);return mt.batch(()=>(n.findAll(e).forEach(r=>{r.reset()}),this.refetchQueries({type:"active",...e},t)))}cancelQueries(e,t={}){const n={revert:!0,...t},r=mt.batch(()=>D(this,Le).findAll(e).map(s=>s.cancel(n)));return Promise.all(r).then(dn).catch(dn)}invalidateQueries(e,t={}){return mt.batch(()=>(D(this,Le).findAll(e).forEach(n=>{n.invalidate()}),(e==null?void 0:e.refetchType)==="none"?Promise.resolve():this.refetchQueries({...e,type:(e==null?void 0:e.refetchType)??(e==null?void 0:e.type)??"active"},t)))}refetchQueries(e,t={}){const n={...t,cancelRefetch:t.cancelRefetch??!0},r=mt.batch(()=>D(this,Le).findAll(e).filter(s=>!s.isDisabled()&&!s.isStatic()).map(s=>{let o=s.fetch(void 0,n);return n.throwOnError||(o=o.catch(dn)),s.state.fetchStatus==="paused"?Promise.resolve():o}));return Promise.all(r).then(dn)}fetchQuery(e){const t=this.defaultQueryOptions(e);t.retry===void 0&&(t.retry=!1);const n=D(this,Le).build(this,t);return n.isStaleByTime(ih(t.staleTime,n))?n.fetch(t):Promise.resolve(n.state.data)}prefetchQuery(e){return this.fetchQuery(e).then(dn).catch(dn)}fetchInfiniteQuery(e){return e.behavior=$x(e.pages),this.fetchQuery(e)}prefetchInfiniteQuery(e){return this.fetchInfiniteQuery(e).then(dn).catch(dn)}ensureInfiniteQueryData(e){return e.behavior=$x(e.pages),this.ensureQueryData(e)}resumePausedMutations(){return Ac.isOnline()?D(this,Vr).resumePausedMutations():Promise.resolve()}getQueryCache(){return D(this,Le)}getMutationCache(){return D(this,Vr)}getDefaultOptions(){return D(this,$r)}setDefaultOptions(e){se(this,$r,e)}setQueryDefaults(e,t){D(this,Vo).set(Na(e),{queryKey:e,defaultOptions:t})}getQueryDefaults(e){const t=[...D(this,Vo).values()],n={};return t.forEach(r=>{Ca(e,r.queryKey)&&Object.assign(n,r.defaultOptions)}),n}setMutationDefaults(e,t){D(this,$o).set(Na(e),{mutationKey:e,defaultOptions:t})}getMutationDefaults(e){const t=[...D(this,$o).values()],n={};return t.forEach(r=>{Ca(e,r.mutationKey)&&Object.assign(n,r.defaultOptions)}),n}defaultQueryOptions(e){if(e._defaulted)return e;const t={...D(this,$r).queries,...this.getQueryDefaults(e.queryKey),...e,_defaulted:!0};return t.queryHash||(t.queryHash=tp(t.queryKey,t)),t.refetchOnReconnect===void 0&&(t.refetchOnReconnect=t.networkMode!=="always"),t.throwOnError===void 0&&(t.throwOnError=!!t.suspense),!t.networkMode&&t.persister&&(t.networkMode="offlineFirst"),t.queryFn===np&&(t.enabled=!1),t}defaultMutationOptions(e){return e!=null&&e._defaulted?e:{...D(this,$r).mutations,...(e==null?void 0:e.mutationKey)&&this.getMutationDefaults(e.mutationKey),...e,_defaulted:!0}}clear(){D(this,Le).clear(),D(this,Vr).clear()}},Le=new WeakMap,Vr=new WeakMap,$r=new WeakMap,Vo=new WeakMap,$o=new WeakMap,Br=new WeakMap,Bo=new WeakMap,zo=new WeakMap,Hv),nM=h.createContext(void 0),rM=({client:e,children:t})=>(h.useEffect(()=>(e.mount(),()=>{e.unmount()}),[e]),i.jsx(nM.Provider,{value:e,children:t}));/**
302 * @remix-run/router v1.23.0
303 *
304 * Copyright (c) Remix Software Inc.
305 *
306 * This source code is licensed under the MIT license found in the
307 * LICENSE.md file in the root directory of this source tree.
308 *
309 * @license MIT
310 */function ka(){return ka=Object.assign?Object.assign.bind():function(e){for(var t=1;t<arguments.length;t++){var n=arguments[t];for(var r in n)Object.prototype.hasOwnProperty.call(n,r)&&(e[r]=n[r])}return e},ka.apply(this,arguments)}var Wr;(function(e){e.Pop="POP",e.Push="PUSH",e.Replace="REPLACE"})(Wr||(Wr={}));const zx="popstate";function sM(e){e===void 0&&(e={});function t(r,s){let{pathname:o,search:a,hash:l}=r.location;return lh("",{pathname:o,search:a,hash:l},s.state&&s.state.usr||null,s.state&&s.state.key||"default")}function n(r,s){return typeof s=="string"?s:Mc(s)}return iM(t,n,null,e)}function $e(e,t){if(e===!1||e===null||typeof e>"u")throw new Error(t)}function L1(e,t){if(!e){typeof console<"u"&&console.warn(t);try{throw new Error(t)}catch{}}}function oM(){return Math.random().toString(36).substr(2,8)}function Ux(e,t){return{usr:e.state,key:e.key,idx:t}}function lh(e,t,n,r){return n===void 0&&(n=null),ka({pathname:typeof e=="string"?e:e.pathname,search:"",hash:""},typeof t=="string"?di(t):t,{state:n,key:t&&t.key||r||oM()})}function Mc(e){let{pathname:t="/",search:n="",hash:r=""}=e;return n&&n!=="?"&&(t+=n.charAt(0)==="?"?n:"?"+n),r&&r!=="#"&&(t+=r.charAt(0)==="#"?r:"#"+r),t}function di(e){let t={};if(e){let n=e.indexOf("#");n>=0&&(t.hash=e.substr(n),e=e.substr(0,n));let r=e.indexOf("?");r>=0&&(t.search=e.substr(r),e=e.substr(0,r)),e&&(t.pathname=e)}return t}function iM(e,t,n,r){r===void 0&&(r={});let{window:s=document.defaultView,v5Compat:o=!1}=r,a=s.history,l=Wr.Pop,c=null,u=d();u==null&&(u=0,a.replaceState(ka({},a.state,{idx:u}),""));function d(){return(a.state||{idx:null}).idx}function f(){l=Wr.Pop;let y=d(),w=y==null?null:y-u;u=y,c&&c({action:l,location:x.location,delta:w})}function m(y,w){l=Wr.Push;let g=lh(x.location,y,w);u=d()+1;let v=Ux(g,u),S=x.createHref(g);try{a.pushState(v,"",S)}catch(j){if(j instanceof DOMException&&j.name==="DataCloneError")throw j;s.location.assign(S)}o&&c&&c({action:l,location:x.location,delta:1})}function p(y,w){l=Wr.Replace;let g=lh(x.location,y,w);u=d();let v=Ux(g,u),S=x.createHref(g);a.replaceState(v,"",S),o&&c&&c({action:l,location:x.location,delta:0})}function b(y){let w=s.location.origin!=="null"?s.location.origin:s.location.href,g=typeof y=="string"?y:Mc(y);return g=g.replace(/ $/,"%20"),$e(w,"No window.location.(origin|href) available to create URL for href: "+g),new URL(g,w)}let x={get action(){return l},get location(){return e(s,a)},listen(y){if(c)throw new Error("A history only accepts one active listener");return s.addEventListener(zx,f),c=y,()=>{s.removeEventListener(zx,f),c=null}},createHref(y){return t(s,y)},createURL:b,encodeLocation(y){let w=b(y);return{pathname:w.pathname,search:w.search,hash:w.hash}},push:m,replace:p,go(y){return a.go(y)}};return x}var Wx;(function(e){e.data="data",e.deferred="deferred",e.redirect="redirect",e.error="error"})(Wx||(Wx={}));
vendor: 9,219 bytes, lines 310-319
310function aM(e,t,n){return n===void 0&&(n="/"),lM(e,t,n)}function lM(e,t,n,r){let s=typeof t=="string"?di(t):t,o=rp(s.pathname||"/",n);if(o==null)return null;let a=_1(e);cM(a);let l=null;for(let c=0;l==null&&c<a.length;++c){let u=bM(o);l=yM(a[c],u)}return l}function _1(e,t,n,r){t===void 0&&(t=[]),n===void 0&&(n=[]),r===void 0&&(r="");let s=(o,a,l)=>{let c={relativePath:l===void 0?o.path||"":l,caseSensitive:o.caseSensitive===!0,childrenIndex:a,route:o};c.relativePath.startsWith("/")&&($e(c.relativePath.startsWith(r),'Absolute route path "'+c.relativePath+'" nested under path '+('"'+r+'" is not valid. An absolute child route path ')+"must start with the combined path of all its parent routes."),c.relativePath=c.relativePath.slice(r.length));let u=es([r,c.relativePath]),d=n.concat(c);o.children&&o.children.length>0&&($e(o.index!==!0,"Index routes must not have child routes. Please remove "+('all child routes from route path "'+u+'".')),_1(o.children,t,d,u)),!(o.path==null&&!o.index)&&t.push({path:u,score:gM(u,o.index),routesMeta:d})};return e.forEach((o,a)=>{var l;if(o.path===""||!((l=o.path)!=null&&l.includes("?")))s(o,a);else for(let c of F1(o.path))s(o,a,c)}),t}function F1(e){let t=e.split("/");if(t.length===0)return[];let[n,...r]=t,s=n.endsWith("?"),o=n.replace(/\?$/,"");if(r.length===0)return s?[o,""]:[o];let a=F1(r.join("/")),l=[];return l.push(...a.map(c=>c===""?o:[o,c].join("/"))),s&&l.push(...a),l.map(c=>e.startsWith("/")&&c===""?"/":c)}function cM(e){e.sort((t,n)=>t.score!==n.score?n.score-t.score:xM(t.routesMeta.map(r=>r.childrenIndex),n.routesMeta.map(r=>r.childrenIndex)))}const uM=/^:[\w-]+$/,dM=3,fM=2,hM=1,mM=10,pM=-2,Hx=e=>e==="*";function gM(e,t){let n=e.split("/"),r=n.length;return n.some(Hx)&&(r+=pM),t&&(r+=fM),n.filter(s=>!Hx(s)).reduce((s,o)=>s+(uM.test(o)?dM:o===""?hM:mM),r)}function xM(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 yM(e,t,n){let{routesMeta:r}=e,s={},o="/",a=[];for(let l=0;l<r.length;++l){let c=r[l],u=l===r.length-1,d=o==="/"?t:t.slice(o.length)||"/",f=vM({path:c.relativePath,caseSensitive:c.caseSensitive,end:u},d),m=c.route;if(!f)return null;Object.assign(s,f.params),a.push({params:s,pathname:es([o,f.pathname]),pathnameBase:CM(es([o,f.pathnameBase])),route:m}),f.pathnameBase!=="/"&&(o=es([o,f.pathnameBase]))}return a}function vM(e,t){typeof e=="string"&&(e={path:e,caseSensitive:!1,end:!0});let[n,r]=wM(e.path,e.caseSensitive,e.end),s=t.match(n);if(!s)return null;let o=s[0],a=o.replace(/(.)\/+$/,"$1"),l=s.slice(1);return{params:r.reduce((u,d,f)=>{let{paramName:m,isOptional:p}=d;if(m==="*"){let x=l[f]||"";a=o.slice(0,o.length-x.length).replace(/(.)\/+$/,"$1")}const b=l[f];return p&&!b?u[m]=void 0:u[m]=(b||"").replace(/%2F/g,"/"),u},{}),pathname:o,pathnameBase:a,pattern:e}}function wM(e,t,n){t===void 0&&(t=!1),n===void 0&&(n=!0),L1(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,(a,l,c)=>(r.push({paramName:l,isOptional:c!=null}),c?"/?([^\\/]+)?":"/([^\\/]+)"));return e.endsWith("*")?(r.push({paramName:"*"}),s+=e==="*"||e==="/*"?"(.*)$":"(?:\\/(.+)|\\/*)$"):n?s+="\\/*$":e!==""&&e!=="/"&&(s+="(?:(?=\\/|$))"),[new RegExp(s,t?void 0:"i"),r]}function bM(e){try{return e.split("/").map(t=>decodeURIComponent(t).replace(/\//g,"%2F")).join("/")}catch(t){return L1(!1,'The URL path "'+e+'" could not be decoded because it is is a malformed URL segment. This is probably due to a bad percent '+("encoding ("+t+").")),e}}function rp(e,t){if(t==="/")return e;if(!e.toLowerCase().startsWith(t.toLowerCase()))return null;let n=t.endsWith("/")?t.length-1:t.length,r=e.charAt(n);return r&&r!=="/"?null:e.slice(n)||"/"}function SM(e,t){t===void 0&&(t="/");let{pathname:n,search:r="",hash:s=""}=typeof e=="string"?di(e):e;return{pathname:n?n.startsWith("/")?n:jM(n,t):t,search:kM(r),hash:PM(s)}}function jM(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 Sd(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 NM(e){return e.filter((t,n)=>n===0||t.route.path&&t.route.path.length>0)}function sp(e,t){let n=NM(e);return t?n.map((r,s)=>s===n.length-1?r.pathname:r.pathnameBase):n.map(r=>r.pathnameBase)}function op(e,t,n,r){r===void 0&&(r=!1);let s;typeof e=="string"?s=di(e):(s=ka({},e),$e(!s.pathname||!s.pathname.includes("?"),Sd("?","pathname","search",s)),$e(!s.pathname||!s.pathname.includes("#"),Sd("#","pathname","hash",s)),$e(!s.search||!s.search.includes("#"),Sd("#","search","hash",s)));let o=e===""||s.pathname==="",a=o?"/":s.pathname,l;if(a==null)l=n;else{let f=t.length-1;if(!r&&a.startsWith("..")){let m=a.split("/");for(;m[0]==="..";)m.shift(),f-=1;s.pathname=m.join("/")}l=f>=0?t[f]:"/"}let c=SM(s,l),u=a&&a!=="/"&&a.endsWith("/"),d=(o||a===".")&&n.endsWith("/");return!c.pathname.endsWith("/")&&(u||d)&&(c.pathname+="/"),c}const es=e=>e.join("/").replace(/\/\/+/g,"/"),CM=e=>e.replace(/\/+$/,"").replace(/^\/*/,"/"),kM=e=>!e||e==="?"?"":e.startsWith("?")?e:"?"+e,PM=e=>!e||e==="#"?"":e.startsWith("#")?e:"#"+e;function EM(e){return e!=null&&typeof e.status=="number"&&typeof e.statusText=="string"&&typeof e.internal=="boolean"&&"data"in e}const V1=["post","put","patch","delete"];new Set(V1);const TM=["get",...V1];new Set(TM);/**
311 * React Router v6.30.1
312 *
313 * Copyright (c) Remix Software Inc.
314 *
315 * This source code is licensed under the MIT license found in the
316 * LICENSE.md file in the root directory of this source tree.
317 *
318 * @license MIT
319 */function Pa(){return Pa=Object.assign?Object.assign.bind():function(e){for(var t=1;t<arguments.length;t++){var n=arguments[t];for(var r in n)Object.prototype.hasOwnProperty.call(n,r)&&(e[r]=n[r])}return e},Pa.apply(this,arguments)}const ip=h.createContext(null),RM=h.createContext(null),us=h.createContext(null),yu=h.createContext(null),Wn=h.createContext({outlet:null,matches:[],isDataRoute:!1}),$1=h.createContext(null);function AM(e,t){let{relative:n}=t===void 0?{}:t;fi()||$e(!1);let{basename:r,navigator:s}=h.useContext(us),{hash:o,pathname:a,search:l}=U1(e,{relative:n}),c=a;return r!=="/"&&(c=a==="/"?r:es([r,a])),s.createHref({pathname:c,search:l,hash:o})}function fi(){return h.useContext(yu)!=null}function Hn(){return fi()||$e(!1),h.useContext(yu).location}function B1(e){h.useContext(us).static||h.useLayoutEffect(e)}function Je(){let{isDataRoute:e}=h.useContext(Wn);return e?KM():MM()}function MM(){fi()||$e(!1);let e=h.useContext(ip),{basename:t,future:n,navigator:r}=h.useContext(us),{matches:s}=h.useContext(Wn),{pathname:o}=Hn(),a=JSON.stringify(sp(s,n.v7_relativeSplatPath)),l=h.useRef(!1);return B1(()=>{l.current=!0}),h.useCallback(function(u,d){if(d===void 0&&(d={}),!l.current)return;if(typeof u=="number"){r.go(u);return}let f=op(u,JSON.parse(a),o,d.relative==="path");e==null&&t!=="/"&&(f.pathname=f.pathname==="/"?t:es([t,f.pathname])),(d.replace?r.replace:r.push)(f,d.state,d)},[t,r,a,o,e])}const OM=h.createContext(null);function IM(e){let t=h.useContext(Wn).outlet;return t&&h.createElement(OM.Provider,{value:e},t)}function z1(){let{matches:e}=h.useContext(Wn),t=e[e.length-1];return t?t.params:{}}function U1(e,t){let{relative:n}=t===void 0?{}:t,{future:r}=h.useContext(us),{matches:s}=h.useContext(Wn),{pathname:o}=Hn(),a=JSON.stringify(sp(s,r.v7_relativeSplatPath));return h.useMemo(()=>op(e,JSON.parse(a),o,n==="path"),[e,a,o,n])}function DM(e,t){return LM(e,t)}function LM(e,t,n,r){fi()||$e(!1);let{navigator:s}=h.useContext(us),{matches:o}=h.useContext(Wn),a=o[o.length-1],l=a?a.params:{};a&&a.pathname;let c=a?a.pathnameBase:"/";a&&a.route;let u=Hn(),d;if(t){var f;let y=typeof t=="string"?di(t):t;c==="/"||(f=y.pathname)!=null&&f.startsWith(c)||$e(!1),d=y}else d=u;let m=d.pathname||"/",p=m;if(c!=="/"){let y=c.replace(/^\//,"").split("/");p="/"+m.replace(/^\//,"").split("/").slice(y.length).join("/")}let b=aM(e,{pathname:p}),x=BM(b&&b.map(y=>Object.assign({},y,{params:Object.assign({},l,y.params),pathname:es([c,s.encodeLocation?s.encodeLocation(y.pathname).pathname:y.pathname]),pathnameBase:y.pathnameBase==="/"?c:es([c,s.encodeLocation?s.encodeLocation(y.pathnameBase).pathname:y.pathnameBase])})),o,n,r);return t&&x?h.createElement(yu.Provider,{value:{location:Pa({pathname:"/",search:"",hash:"",state:null,key:"default"},d),navigationType:Wr.Pop}},x):x}function _M(){let e=HM(),t=EM(e)?e.status+" "+e.statusText:e instanceof Error?e.message:JSON.stringify(e),n=e instanceof Error?e.stack:null,s={padding:"0.5rem",backgroundColor:"rgba(200,200,200, 0.5)"};return h.createElement(h.Fragment,null,h.createElement("h2",null,"Unexpected Application 
319Error!"),h.createElement("h3",{style:{fontStyle:"italic"}},t),n?h.createElement("pre",{style:s},n):null,null)}const FM=h.createElement(_M,null);class VM extends h.Component{constructor(t){super(t),this.state={location:t.location,revalidation:t.revalidation,error:t.error}}static getDerivedStateFromError(t){return{error:t}}static getDerivedStateFromProps(t,n){return n.location!==t.location||n.revalidation!=="idle"&&t.revalidation==="idle"?{error:t.error,location:t.location,revalidation:t.revalidation}:{error:t.error!==void 0?t.error:n.error,location:n.location,revalidation:t.revalidation||n.revalidation}}componentDidCatch(t,n){console.error("React Router caught the following error during render",t,n)}render(){return this.state.error!==void 0?h.createElement(Wn.Provider,{value:this.props.routeContext},h.createElement($1.Provider,{value:this.state.error,children:this.props.component})):this.props.children}}function $M(e){let{routeContext:t,match:n,children:r}=e,s=h.useContext(ip);return s&&s.static&&s.staticContext&&(n.route.errorElement||n.route.ErrorBoundary)&&(s.staticContext._deepestRenderedBoundaryId=n.route.id),h.createElement(Wn.Provider,{value:t},r)}function BM(e,t,n,r){var s;if(t===void 0&&(t=[]),n===void 0&&(n=null),r===void 0&&(r=null),e==null){var o;if(!n)return null;if(n.errors)e=n.matches;else if((o=r)!=null&&o.v7_partialHydration&&t.length===0&&!n.initialized&&n.matches.length>0)e=n.matches;else return null}let a=e,l=(s=n)==null?void 0:s.errors;if(l!=null){let d=a.findIndex(f=>f.route.id&&(l==null?void 0:l[f.route.id])!==void 0);d>=0||$e(!1),a=a.slice(0,Math.min(a.length,d+1))}let c=!1,u=-1;if(n&&r&&r.v7_partialHydration)for(let d=0;d<a.length;d++){let f=a[d];if((f.route.HydrateFallback||f.route.hydrateFallbackElement)&&(u=d),f.route.id){let{loaderData:m,errors:p}=n,b=f.route.loader&&m[f.route.id]===void 0&&(!p||p[f.route.id]===void 0);if(f.route.lazy||b){c=!0,u>=0?a=a.slice(0,u+1):a=[a[0]];break}}}return a.reduceRight((d,f,m)=>{let p,b=!1,x=null,y=null;n&&(p=l&&f.route.id?l[f.route.id]:void 0,x=f.route.errorElement||FM,c&&(u<0&&m===0?(YM("route-fallback"),b=!0,y=null):u===m&&(b=!0,y=f.route.hydrateFallbackElement||null)));let w=t.concat(a.slice(0,m+1)),g=()=>{let v;return p?v=x:b?v=y:f.route.Component?v=h.createElement(f.route.Component,null):f.route.element?v=f.route.element:v=d,h.createElement($M,{match:f,routeContext:{outlet:d,matches:w,isDataRoute:n!=null},children:v})};return n&&(f.route.ErrorBoundary||f.route.errorElement||m===0)?h.createElement(VM,{location:n.location,revalidation:n.revalidation,component:x,error:p,children:g(),routeContext:{outlet:null,matches:w,isDataRoute:!0}}):g()},null)}var W1=function(e){return e.UseBlocker="useBlocker",e.UseRevalidator="useRevalidator",e.UseNavigateStable="useNavigate",e}(W1||{}),H1=function(e){return e.UseBlocker="useBlocker",e.UseLoaderData="useLoaderData",e.UseActionData="useActionData",e.UseRouteError="useRouteError",e.UseNavigation="useNavigation",e.UseRouteLoaderData="useRouteLoaderData",e.UseMatches="useMatches",e.UseRevalidator="useRevalidator",e.UseNavigateStable="useNavigate",e.UseRouteId="useRouteId",e}(H1||{});function zM(e){let t=h.useContext(ip);return t||$e(!1),t}function UM(e){let t=h.useContext(RM);return t||$e(!1),t}function WM(e){let t=h.useContext(Wn);return t||$e(!1),t}function K1(e){let t=WM(),n=t.matches[t.matches.length-1];return n.route.id||$e(!1),n.route.id}function HM(){var e;let t=h.useContext($1),n=UM(),r=K1();return t!==void 0?t:(e=n.errors)==null?void 0:e[r]}function KM(){let{router:e}=zM(W1.UseNavigateStable),t=K1(H1.UseNavigateStable),n=h.useRef(!1);return B1(()=>{n.current=!0}),h.useCallback(function(s,o){o===void 0&&(o={}),n.current&&(typeof s=="number"?e.navigate(s):e.navigate(s,Pa({fromRouteId:t},o)))},[e,t])}const Kx={};function YM(e,t,n){Kx[e]||(Kx[e]=!0)}function GM(e,t){e==null||e.v7_startTransition,e==null||e.v7_relativeSplatPath}function qM(e){let{to:t,replace:n,state:r,relative:s}=e;fi()||$e(!1);let{future:o,static:a}=h.useContext(us),{matches:l}=h.useContext(Wn),{pathname:c}=Hn(),u=Je(),d=op(t,sp(l,o.v7_relativeSplatPath),c,s==="path"),f=JSON.stringify(d);return h.useEffect(()=>u(JSON.parse(f),{replace:n,state:r,relative:s}),[u,f,s,n,r]),null}function QM(e){return IM(e.context)}
319function dt(e){$e(!1)}function XM(e){let{basename:t="/",children:n=null,location:r,navigationType:s=Wr.Pop,navigator:o,static:a=!1,future:l}=e;fi()&&$e(!1);let c=t.replace(/^\/*/,"/"),u=h.useMemo(()=>({basename:c,navigator:o,static:a,future:Pa({v7_relativeSplatPath:!1},l)}),[c,l,o,a]);typeof r=="string"&&(r=di(r));let{pathname:d="/",search:f="",hash:m="",state:p=null,key:b="default"}=r,x=h.useMemo(()=>{let y=rp(d,c);return y==null?null:{location:{pathname:y,search:f,hash:m,state:p,key:b},navigationType:s}},[c,d,f,m,p,b,s]);return x==null?null:h.createElement(us.Provider,{value:u},h.createElement(yu.Provider,{children:n,value:x}))}function JM(e){let{children:t,location:n}=e;return DM(ch(t),n)}new Promise(()=>{});function ch(e,t){t===void 0&&(t=[]);let n=[];return h.Children.forEach(e,(r,s)=>{if(!h.isValidElement(r))return;let o=[...t,s];if(r.type===h.Fragment){n.push.apply(n,ch(r.props.children,o));return}r.type!==dt&&$e(!1),!r.props.index||!r.props.children||$e(!1);let a={id:r.props.id||o.join("-"),caseSensitive:r.props.caseSensitive,element:r.props.element,Component:r.props.Component,index:r.props.index,path:r.props.path,loader:r.props.loader,action:r.props.action,errorElement:r.props.errorElement,ErrorBoundary:r.props.ErrorBoundary,hasErrorBoundary:r.props.ErrorBoundary!=null||r.props.errorElement!=null,shouldRevalidate:r.props.shouldRevalidate,handle:r.props.handle,lazy:r.props.lazy};r.props.children&&(a.children=ch(r.props.children,o)),n.push(a)}),n}/**
320 * React Router DOM v6.30.1
321 *
322 * Copyright (c) Remix Software Inc.
323 *
324 * This source code is licensed under the MIT license found in the
325 * LICENSE.md file in the root directory of this source tree.
326 *
327 * @license MIT
328 */function uh(){return uh=Object.assign?Object.assign.bind():function(e){for(var t=1;t<arguments.length;t++){var n=arguments[t];for(var r in n)Object.prototype.hasOwnProperty.call(n,r)&&(e[r]=n[r])}return e},uh.apply(this,arguments)}function ZM(e,t){if(e==null)return{};var n={},r=Object.keys(e),s,o;for(o=0;o<r.length;o++)s=r[o],!(t.indexOf(s)>=0)&&(n[s]=e[s]);return n}function e4(e){return!!(e.metaKey||e.altKey||e.ctrlKey||e.shiftKey)}function t4(e,t){return e.button===0&&(!t||t==="_self")&&!e4(e)}function dh(e){return e===void 0&&(e=""),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 n4(e,t){let n=dh(e);return t&&t.forEach((r,s)=>{n.has(s)||t.getAll(s).forEach(o=>{n.append(s,o)})}),n}const r4=["onClick","relative","reloadDocument","replace","state","target","to","preventScrollReset","viewTransition"],s4="6";try{window.__reactRouterVersion=s4}catch{}const o4="startTransition",Yx=Yh[o4];function i4(e){let{basename:t,children:n,future:r,window:s}=e,o=h.useRef();o.current==null&&(o.current=sM({window:s,v5Compat:!0}));let a=o.current,[l,c]=h.useState({action:a.action,location:a.location}),{v7_startTransition:u}=r||{},d=h.useCallback(f=>{u&&Yx?Yx(()=>c(f)):c(f)},[c,u]);return h.useLayoutEffect(()=>a.listen(d),[a,d]),h.useEffect(()=>GM(r),[r]),h.createElement(XM,{basename:t,children:n,location:l.location,navigationType:l.action,navigator:a,future:r})}const a4=typeof window<"u"&&typeof window.document<"u"&&typeof window.document.createElement<"u",l4=/^(?:[a-z][a-z0-9+.-]*:|\/\/)/i,Oc=h.forwardRef(function(t,n){let{onClick:r,relative:s,reloadDocument:o,replace:a,state:l,target:c,to:u,preventScrollReset:d,viewTransition:f}=t,m=ZM(t,r4),{basename:p}=h.useContext(us),b,x=!1;if(typeof u=="string"&&l4.test(u)&&(b=u,a4))try{let v=new URL(window.location.href),S=u.startsWith("//")?new URL(v.protocol+u):new URL(u),j=rp(S.pathname,p);S.origin===v.origin&&j!=null?u=j+S.search+S.hash:x=!0}catch{}let y=AM(u,{relative:s}),w=c4(u,{replace:a,state:l,target:c,preventScrollReset:d,relative:s,viewTransition:f});function g(v){r&&r(v),v.defaultPrevented||w(v)}return h.createElement("a",uh({},m,{href:b||y,onClick:x||o?r:g,ref:n,target:c}))});var Gx;(function(e){e.UseScrollRestoration="useScrollRestoration",e.UseSubmit="useSubmit",e.UseSubmitFetcher="useSubmitFetcher",e.UseFetcher="useFetcher",e.useViewTransitionState="useViewTransitionState"})(Gx||(Gx={}));var qx;(function(e){e.UseFetcher="useFetcher",e.UseFetchers="useFetchers",e.UseScrollRestoration="useScrollRestoration"})(qx||(qx={}));function c4(e,t){let{target:n,replace:r,state:s,preventScrollReset:o,relative:a,viewTransition:l}=t===void 0?{}:t,c=Je(),u=Hn(),d=U1(e,{relative:a});return h.useCallback(f=>{if(t4(f,n)){f.preventDefault();let m=r!==void 0?r:Mc(u)===Mc(d);c(e,{replace:m,state:s,preventScrollReset:o,relative:a,viewTransition:l})}},[u,c,d,r,s,n,e,o,a,l])}function Y1(e){let t=h.useRef(dh(e)),n=h.useRef(!1),r=Hn(),s=h.useMemo(()=>n4(r.search,n.current?null:t.current),[r.search]),o=Je(),a=h.useCallback((l,c)=>{const u=dh(typeof l=="function"?l(s):l);n.current=!0,o("?"+u,c)},[o,s]);return[s,a]}const ap=h.createContext({});function lp(e){const t=h.useRef(null);return t.current===null&&(t.current=e()),t.current}const cp=typeof window<"u",G1=cp?h.useLayoutEffect:h.useEffect,vu=h.createContext(null);function up(e,t){e.indexOf(t)===-1&&e.push(t)}function dp(e,t){const n=e.indexOf(t);n>-1&&e.splice(n,1)}const zn=(e,t,n)=>n>t?t:n<e?e:n;let fp=()=>{};const ur={},q1=e=>/^-?(?:\d+(?:\.\d+)?|\.\d+)$/u.test(e);function Q1(e){return typeof e=="object"&&e!==null}
vendor: 19,267 bytes, line 328
328const X1=e=>/^0[^.\s]+$/u.test(e);function hp(e){let t;return()=>(t===void 0&&(t=e()),t)}const Gt=e=>e,u4=(e,t)=>n=>t(e(n)),Ha=(...e)=>e.reduce(u4),Ea=(e,t,n)=>{const r=t-e;return r===0?1:(n-e)/r};class mp{constructor(){this.subscriptions=[]}add(t){return up(this.subscriptions,t),()=>dp(this.subscriptions,t)}notify(t,n,r){const s=this.subscriptions.length;if(s)if(s===1)this.subscriptions[0](t,n,r);else for(let o=0;o<s;o++){const a=this.subscriptions[o];a&&a(t,n,r)}}getSize(){return this.subscriptions.length}clear(){this.subscriptions.length=0}}const nr=e=>e*1e3,Kt=e=>e/1e3;function J1(e,t){return t?e*(1e3/t):0}const Z1=(e,t,n)=>(((1-3*n+3*t)*e+(3*n-6*t))*e+3*t)*e,d4=1e-7,f4=12;function h4(e,t,n,r,s){let o,a,l=0;do a=t+(n-t)/2,o=Z1(a,r,s)-e,o>0?n=a:t=a;while(Math.abs(o)>d4&&++l<f4);return a}function Ka(e,t,n,r){if(e===t&&n===r)return Gt;const s=o=>h4(o,0,1,e,n);return o=>o===0||o===1?o:Z1(s(o),t,r)}const eS=e=>t=>t<=.5?e(2*t)/2:(2-e(2*(1-t)))/2,tS=e=>t=>1-e(1-t),nS=Ka(.33,1.53,.69,.99),pp=tS(nS),rS=eS(pp),sS=e=>(e*=2)<1?.5*pp(e):.5*(2-Math.pow(2,-10*(e-1))),gp=e=>1-Math.sin(Math.acos(e)),oS=tS(gp),iS=eS(gp),m4=Ka(.42,0,1,1),p4=Ka(0,0,.58,1),aS=Ka(.42,0,.58,1),g4=e=>Array.isArray(e)&&typeof e[0]!="number",lS=e=>Array.isArray(e)&&typeof e[0]=="number",x4={linear:Gt,easeIn:m4,easeInOut:aS,easeOut:p4,circIn:gp,circInOut:iS,circOut:oS,backIn:pp,backInOut:rS,backOut:nS,anticipate:sS},y4=e=>typeof e=="string",Qx=e=>{if(lS(e)){fp(e.length===4);const[t,n,r,s]=e;return Ka(t,n,r,s)}else if(y4(e))return x4[e];return e},vl=["setup","read","resolveKeyframes","preUpdate","update","preRender","render","postRender"];function v4(e,t){let n=new Set,r=new Set,s=!1,o=!1;const a=new WeakSet;let l={delta:0,timestamp:0,isProcessing:!1};function c(d){a.has(d)&&(u.schedule(d),e()),d(l)}const u={schedule:(d,f=!1,m=!1)=>{const b=m&&s?n:r;return f&&a.add(d),b.has(d)||b.add(d),d},cancel:d=>{r.delete(d),a.delete(d)},process:d=>{if(l=d,s){o=!0;return}s=!0,[n,r]=[r,n],n.forEach(c),n.clear(),s=!1,o&&(o=!1,u.process(d))}};return u}const w4=40;function cS(e,t){let n=!1,r=!0;const s={delta:0,timestamp:0,isProcessing:!1},o=()=>n=!0,a=vl.reduce((v,S)=>(v[S]=v4(o),v),{}),{setup:l,read:c,resolveKeyframes:u,preUpdate:d,update:f,preRender:m,render:p,postRender:b}=a,x=()=>{const v=ur.useManualTiming?s.timestamp:performance.now();n=!1,ur.useManualTiming||(s.delta=r?1e3/60:Math.max(Math.min(v-s.timestamp,w4),1)),s.timestamp=v,s.isProcessing=!0,l.process(s),c.process(s),u.process(s),d.process(s),f.process(s),m.process(s),p.process(s),b.process(s),s.isProcessing=!1,n&&t&&(r=!1,e(x))},y=()=>{n=!0,r=!0,s.isProcessing||e(x)};return{schedule:vl.reduce((v,S)=>{const j=a[S];return v[S]=(C,P=!1,N=!1)=>(n||y(),j.schedule(C,P,N)),v},{}),cancel:v=>{for(let S=0;S<vl.length;S++)a[vl[S]].cancel(v)},state:s,steps:a}}const{schedule:Pe,cancel:os,state:et,steps:jd}=cS(typeof requestAnimationFrame<"u"?requestAnimationFrame:Gt,!0);let Kl;function b4(){Kl=void 0}const gt={now:()=>(Kl===void 0&&gt.set(et.isProcessing||ur.useManualTiming?et.timestamp:performance.now()),Kl),set:e=>{Kl=e,queueMicrotask(b4)}},uS=e=>t=>typeof t=="string"&&t.startsWith(e),dS=uS("--"),S4=uS("var(--"),xp=e=>S4(e)?j4.test(e.split("/*")[0].trim()):!1,j4=/var\(--(?:[\w-]+\s*|[\w-]+\s*,(?:\s*[^)(\s]|\s*\((?:[^)(]|\([^)(]*\))*\))+\s*)\)$/iu;function Xx(e){return typeof e!="string"?!1:e.split("/*")[0].includes("var(--")}const hi={test:e=>typeof e=="number",parse:parseFloat,transform:e=>e},Ta={...hi,transform:e=>zn(0,1,e)},wl={...hi,default:1},ea=e=>Math.round(e*1e5)/1e5,yp=/-?(?:\d+(?:\.\d+)?|\.\d+)/gu;function N4(e){return e==null}const C4=/^(?:#[\da-f]{3,8}|(?:rgb|hsl)a?\((?:-?[\d.]+%?[,\s]+){2}-?[\d.]+%?\s*(?:[,/]\s*)?(?:\b\d+(?:\.\d+)?|\.\d+)?%?\))$/iu,vp=(e,t)=>n=>!!(typeof n=="string"&&C4.test(n)&&n.startsWith(e)||t&&!N4(n)&&Object.prototype.hasOwnProperty.call(n,t)),fS=(e,t,n)=>r=>{if(typeof r!="string")return r;const[s,o,a,l]=r.match(yp);return{[e]:parseFloat(s),[t]:parseFloat(o),[n]:parseFloat(a),alpha:l!==void 0?parseFloat(l):1}},k4=e=>zn(0,255,e),Nd={...hi,transform:e=>Math.round(k4(e))},js={test:vp("rgb","red"),parse:fS("red","green","blue"),transform:({red:e,green:t,blue:n,alpha:r=1})=>"rgba("+Nd.transform(e)+", "+Nd.transform(t)+", "+Nd.transform(n)+", "+ea(Ta.transform(r))+")"};function P4(e){let t="",n="",r="",s="";return e.length>5?(t=e.substring(1,3),n=e.substring(3,5),r=e.substring(5,7),s=e.substring(7,9)):(t=e.substring(1,2),n=e.substring(2,3),r=e.substring(3,4),s=e.substring(4,5),t+=t,n+=n,r+=r,s+=s),{red:parseInt(t,16),green:parseInt(n,16),blue:parseInt(r,16),alpha:s?parseInt(s,16)/255:1}}const fh={test:vp("#"),parse:P4,transform:js.transform},Ya=e=>({test:t=>typeof t=="string"&&t.endsWith(e)&&t.split(" ").length===1,parse:parseFloat,transform:t=>`${t}${e}`}),Rr=Ya("deg"),$n=Ya("%"),G=Ya("px"),E4=Ya("vh"),T4=Ya("vw"),Jx={...$n,parse:e=>$n.parse(e)/100,transform:e=>$n.transform(e*100)},xo={test:vp("hsl","hue"),parse:fS("hue","saturation","lightness"),transform:({hue:e,saturation:t,lightness:n,alpha:r=1})=>"hsla("+Math.round(e)+", "+$n.transform(ea(t))+", "+$n.transform(ea(n))+", "+ea(Ta.transform(r))+")"},ze={test:e=>js.test(e)||fh.test(e)||xo.test(e),parse:e=>js.test(e)?js.parse(e):xo.test(e)?xo.parse(e):fh.parse(e),transform:e=>typeof e=="string"?e:e.hasOwnProperty("red")?js.transform(e):xo.transform(e),getAnimatableNone:e=>{const t=ze.parse(e);return t.alpha=0,ze.transform(t)}},R4=/(?:#[\da-f]{3,8}|(?:rgb|hsl)a?\((?:-?[\d.]+%?[,\s]+){2}-?[\d.]+%?\s*(?:[,/]\s*)?(?:\b\d+(?:\.\d+)?|\.\d+)?%?\))/giu;function A4(e){var t,n;return isNaN(e)&&typeof e=="string"&&(((t=e.match(yp))==null?void 0:t.length)||0)+(((n=e.match(R4))==null?void 0:n.length)||0)>0}const hS="number",mS="color",M4="var",O4="var(",Zx="${}",I4=/var\s*\(\s*--(?:[\w-]+\s*|[\w-]+\s*,(?:\s*[^)(\s]|\s*\((?:[^)(]|\([^)(]*\))*\))+\s*)\)|#[\da-f]{3,8}|(?:rgb|hsl)a?\((?:-?[\d.]+%?[,\s]+){2}-?[\d.]+%?\s*(?:[,/]\s*)?(?:\b\d+(?:\.\d+)?|\.\d+)?%?\)|-?(?:\d+(?:\.\d+)?|\.\d+)/giu;function Ra(e){const t=e.toString(),n=[],r={color:[],number:[],var:[]},s=[];let o=0;const l=t.replace(I4,c=>(ze.test(c)?(r.color.push(o),s.push(mS),n.push(ze.parse(c))):c.startsWith(O4)?(r.var.push(o),s.push(M4),n.push(c)):(r.number.push(o),s.push(hS),n.push(parseFloat(c))),++o,Zx)).split(Zx);return{values:n,split:l,indexes:r,types:s}}function pS(e){return Ra(e).values}function gS(e){const{split:t,types:n}=Ra(e),r=t.length;return s=>{let o="";for(let a=0;a<r;a++)if(o+=t[a],s[a]!==void 0){const l=n[a];l===hS?o+=ea(s[a]):l===mS?o+=ze.transform(s[a]):o+=s[a]}return o}}const D4=e=>typeof e=="number"?0:ze.test(e)?ze.getAnimatableNone(e):e;function L4(e){const t=pS(e);return gS(e)(t.map(D4))}const is={test:A4,parse:pS,createTransformer:gS,getAnimatableNone:L4};function Cd(e,t,n){return n<0&&(n+=1),n>1&&(n-=1),n<1/6?e+(t-e)*6*n:n<1/2?t:n<2/3?e+(t-e)*(2/3-n)*6:e}function _4({hue:e,saturation:t,lightness:n,alpha:r}){e/=360,t/=100,n/=100;let s=0,o=0,a=0;if(!t)s=o=a=n;else{const l=n<.5?n*(1+t):n+t-n*t,c=2*n-l;s=Cd(c,l,e+1/3),o=Cd(c,l,e),a=Cd(c,l,e-1/3)}return{red:Math.round(s*255),green:Math.round(o*255),blue:Math.round(a*255),alpha:r}}function Ic(e,t){return n=>n>0?t:e}const Me=(e,t,n)=>e+(t-e)*n,kd=(e,t,n)=>{const r=e*e,s=n*(t*t-r)+r;return s<0?0:Math.sqrt(s)},F4=[fh,js,xo],V4=e=>F4.find(t=>t.test(e));function ey(e){const t=V4(e);if(!t)return!1;let n=t.parse(e);return t===xo&&(n=_4(n)),n}const ty=(e,t)=>{const n=ey(e),r=ey(t);if(!n||!r)return Ic(e,t);const s={...n};return o=>(s.red=kd(n.red,r.red,o),s.green=kd(n.green,r.green,o),s.blue=kd(n.blue,r.blue,o),s.alpha=Me(n.alpha,r.alpha,o),js.transform(s))},hh=new Set(["none","hidden"]);function $4(e,t){return hh.has(e)?n=>n<=0?e:t:n=>n>=1?t:e}function B4(e,t){return n=>Me(e,t,n)}function wp(e){return typeof e=="number"?B4:typeof e=="string"?xp(e)?Ic:ze.test(e)?ty:W4:Array.isArray(e)?xS:typeof e=="object"?ze.test(e)?ty:z4:Ic}function xS(e,t){const n=[...e],r=n.length,s=e.map((o,a)=>wp(o)(o,t[a]));return o=>{for(let a=0;a<r;a++)n[a]=s[a](o);return n}}function z4(e,t){const n={...e,...t},r={};for(const s in n)e[s]!==void 0&&t[s]!==void 0&&(r[s]=wp(e[s])(e[s],t[s]));return s=>{for(const o in r)n[o]=r[o](s);return n}}function U4(e,t){const n=[],r={color:0,var:0,number:0};for(let s=0;s<t.values.length;s++){const o=t.types[s],a=e.indexes[o][r[o]],l=e.values[a]??0;n[s]=l,r[o]++}return n}const W4=(e,t)=>{const n=is.createTransformer(t),r=Ra(e),s=Ra(t);return r.indexes.var.length===s.indexes.var.length&&r.indexes.color.length===s.indexes.color.length&&r.indexes.number.length>=s.indexes.number.length?hh.has(e)&&!s.values.length||hh.has(t)&&!r.values.length?$4(e,t):Ha(xS(U4(r,s),s.values),n):Ic(e,t)};function yS(e,t,n){return typeof e=="number"&&typeof t=="number"&&typeof n=="number"?Me(e,t,n):wp(e)(e,t)}const H4=e=>{const t=({timestamp:n})=>e(n);return{start:(n=!0)=>Pe.update(t,n),stop:()=>os(t),now:()=>et.isProcessing?et.timestamp:gt.now()}},vS=(e,t,n=10)=>{let r="";const s=Math.max(Math.round(t/n),2);for(let o=0;o<s;o++)r+=Math.round(e(o/(s-1))*1e4)/1e4+", ";return`linear(${r.substring(0,r.length-2)})`},Dc=2e4;function bp(e){let t=0;const n=50;let r=e.next(t);for(;!r.done&&t<Dc;)t+=n,r=e.next(t);return t>=Dc?1/0:t}function K4(e,t=100,n){const r=n({...e,keyframes:[0,t]}),s=Math.min(bp(r),Dc);return{type:"keyframes",ease:o=>r.next(s*o).value/t,duration:Kt(s)}}const Y4=5;function wS(e,t,n){const r=Math.max(t-Y4,0);return J1(n-e(r),t-r)}const _e={stiffness:100,damping:10,mass:1,velocity:0,duration:800,bounce:.3,visualDuration:.3,restSpeed:{granular:.01,default:2},restDelta:{granular:.005,default:.5},minDuration:.01,maxDuration:10,minDamping:.05,maxDamping:1},Pd=.001;function G4({duration:e=_e.duration,bounce:t=_e.bounce,velocity:n=_e.velocity,mass:r=_e.mass}){let s,o,a=1-t;a=zn(_e.minDamping,_e.maxDamping,a),e=zn(_e.minDuration,_e.maxDuration,Kt(e)),a<1?(s=u=>{const d=u*a,f=d*e,m=d-n,p=mh(u,a),b=Math.exp(-f);return Pd-m/p*b},o=u=>{const f=u*a*e,m=f*n+n,p=Math.pow(a,2)*Math.pow(u,2)*e,b=Math.exp(-f),x=mh(Math.pow(u,2),a);return(-s(u)+Pd>0?-1:1)*((m-p)*b)/x}):(s=u=>{const d=Math.exp(-u*e),f=(u-n)*e+1;return-Pd+d*f},o=u=>{const d=Math.exp(-u*e),f=(n-u)*(e*e);return d*f});const l=5/e,c=Q4(s,o,l);if(e=nr(e),isNaN(c))return{stiffness:_e.stiffness,damping:_e.damping,duration:e};{const u=Math.pow(c,2)*r;return{stiffness:u,damping:a*2*Math.sqrt(r*u),duration:e}}}const q4=12;function Q4(e,t,n){let r=n;for(let s=1;s<q4;s++)r=r-e(r)/t(r);return r}function mh(e,t){return e*Math.sqrt(1-t*t)}const X4=["duration","bounce"],J4=["stiffness","damping","mass"];function ny(e,t){return t.some(n=>e[n]!==void 0)}function Z4(e){let t={velocity:_e.velocity,stiffness:_e.stiffness,damping:_e.damping,mass:_e.mass,isResolvedFromDuration:!1,...e};if(!ny(e,J4)&&ny(e,X4))if(e.visualDuration){const n=e.visualDuration,r=2*Math.PI/(n*1.2),s=r*r,o=2*zn(.05,1,1-(e.bounce||0))*Math.sqrt(s);t={...t,mass:_e.mass,stiffness:s,damping:o}}else{const n=G4(e);t={...t,...n,mass:_e.mass},t.isResolvedFromDuration=!0}return t}function Lc(e=_e.visualDuration,t=_e.bounce){const n=typeof e!="object"?{visualDuration:e,keyframes:[0,1],bounce:t}:e;let{restSpeed:r,restDelta:s}=n;const o=n.keyframes[0],a=n.keyframes[n.keyframes.length-1],l={done:!1,value:o},{stiffness:c,damping:u,mass:d,duration:f,velocity:m,isResolvedFromDuration:p}=Z4({...n,velocity:-Kt(n.velocity||0)}),b=m||0,x=u/(2*Math.sqrt(c*d)),y=a-o,w=Kt(Math.sqrt(c/d)),g=Math.abs(y)<5;r||(r=g?_e.restSpeed.granular:_e.restSpeed.default),s||(s=g?_e.restDelta.granular:_e.restDelta.default);let v;if(x<1){const j=mh(w,x);v=C=>{const P=Math.exp(-x*w*C);return a-P*((b+x*w*y)/j*Math.sin(j*C)+y*Math.cos(j*C))}}else if(x===1)v=j=>a-Math.exp(-w*j)*(y+(b+w*y)*j);else{const j=w*Math.sqrt(x*x-1);v=C=>{const P=Math.exp(-x*w*C),N=Math.min(j*C,300);return a-P*((b+x*w*y)*Math.sinh(N)+j*y*Math.cosh(N))/j}}const S={calculatedDuration:p&&f||null,next:j=>{const C=v(j);if(p)l.done=j>=f;else{let P=j===0?b:0;x<1&&(P=j===0?nr(b):wS(v,j,C));const N=Math.abs(P)<=r,E=Math.abs(a-C)<=s;l.done=N&&E}return l.value=l.done?a:C,l},toString:()=>{const j=Math.min(bp(S),Dc),C=vS(P=>S.next(j*P).value,j,30);return j+"ms "+C},toTransition:()=>{}};return S}Lc.applyToOptions=e=>{const t=K4(e,100,Lc);return e.ease=t.ease,e.duration=nr(t.duration),e.type="keyframes",e};function ph({keyframes:e,velocity:t=0,power:n=.8,timeConstant:r=325,bounceDamping:s=10,bounceStiffness:o=500,modifyTarget:a,min:l,max:c,restDelta:u=.5,restSpeed:d}){const f=e[0],m={done:!1,value:f},p=N=>l!==void 0&&N<l||c!==void 0&&N>c,b=N=>l===void 0?c:c===void 0||Math.abs(l-N)<Math.abs(c-N)?l:c;let x=n*t;const y=f+x,w=a===void 0?y:a(y);w!==y&&(x=w-f);const g=N=>-x*Math.exp(-N/r),v=N=>w+g(N),S=N=>{const E=g(N),k=v(N);m.done=Math.abs(E)<=u,m.value=m.done?w:k};let j,C;const P=N=>{p(m.value)&&(j=N,C=Lc({keyframes:[m.value,b(m.value)],velocity:wS(v,N,m.value),damping:s,stiffness:o,restDelta:u,restSpeed:d}))};return P(0),{calculatedDuration:null,next:N=>{let E=!1;return!C&&j===void 0&&(E=!0,S(N),P(N)),j!==void 0&&N>=j?C.next(N-j):(!E&&S(N),m)}}}function eO(e,t,n){const r=[],s=n||ur.mix||yS,o=e.length-1;for(let a=0;a<o;a++){let l=s(e[a],e[a+1]);if(t){const c=Array.isArray(t)?t[a]||Gt:t;l=Ha(c,l)}r.push(l)}return r}function tO(e,t,{clamp:n=!0,ease:r,mixer:s}={}){const o=e.length;if(fp(o===t.length),o===1)return()=>t[0];if(o===2&&t[0]===t[1])return()=>t[1];const a=e[0]===e[1];e[0]>e[o-1]&&(e=[...e].reverse(),t=[...t].reverse());const l=eO(t,r,s),c=l.length,u=d=>{if(a&&d<e[0])return t[0];let f=0;if(c>1)for(;f<e.length-2&&!(d<e[f+1]);f++);const m=Ea(e[f],e[f+1],d);return l[f](m)};return n?d=>u(zn(e[0],e[o-1],d)):u}function nO(e,t){const n=e[e.length-1];for(let r=1;r<=t;r++){const s=Ea(0,t,r);e.push(Me(n,1,s))}}function rO(e){const t=[0];return nO(t,e.length-1),t}function sO(e,t){return e.map(n=>n*t)}function oO(e,t){return e.map(()=>t||aS).splice(0,e.length-1)}function ta({duration:e=300,keyframes:t,times:n,ease:r="easeInOut"}){const s=g4(r)?r.map(Qx):Qx(r),o={done:!1,value:t[0]},a=sO(n&&n.length===t.length?n:rO(t),e),l=tO(a,t,{ease:Array.isArray(s)?s:oO(t,s)});return{calculatedDuration:e,next:c=>(o.value=l(c),o.done=c>=e,o)}}const iO=e=>e!==null;function Sp(e,{repeat:t,repeatType:n="loop"},r,s=1){const o=e.filter(iO),l=s<0||t&&n!=="loop"&&t%2===1?0:o.length-1;return!l||r===void 0?o[l]:r}const aO={decay:ph,inertia:ph,tween:ta,keyframes:ta,spring:Lc};function bS(e){typeof e.type=="string"&&(e.type=aO[e.type])}class jp{constructor(){this.updateFinished()}get finished(){return this._finished}updateFinished(){this._finished=new Promise(t=>{this.resolve=t})}notifyFinished(){this.resolve()}then(t,n){return this.finished.then(t,n)}}const lO=e=>e/100;class Np extends jp{constructor(t){super(),this.state="idle",this.startTime=null,this.isStopped=!1,this.currentTime=0,this.holdTime=null,this.playbackSpeed=1,this.stop=()=>{var r,s;const{motionValue:n}=this.options;n&&n.updatedAt!==gt.now()&&this.tick(gt.now()),this.isStopped=!0,this.state!=="idle"&&(this.teardown(),(s=(r=this.options).onStop)==null||s.call(r))},this.options=t,this.initAnimation(),this.play(),t.autoplay===!1&&this.pause()}initAnimation(){const{options:t}=this;bS(t);const{type:n=ta,repeat:r=0,repeatDelay:s=0,repeatType:o,velocity:a=0}=t;let{keyframes:l}=t;const c=n||ta;c!==ta&&typeof l[0]!="number"&&(this.mixKeyframes=Ha(lO,yS(l[0],l[1])),l=[0,100]);const u=c({...t,keyframes:l});o==="mirror"&&(this.mirroredGenerator=c({...t,keyframes:[...l].reverse(),velocity:-a})),u.calculatedDuration===null&&(u.calculatedDuration=bp(u));const{calculatedDuration:d}=u;this.calculatedDuration=d,this.resolvedDuration=d+s,this.totalDuration=this.resolvedDuration*(r+1)-s,this.generator=u}updateTime(t){const n=Math.round(t-this.startTime)*this.playbackSpeed;this.holdTime!==null?this.currentTime=this.holdTime:this.currentTime=n}tick(t,n=!1){const{generator:r,totalDuration:s,mixKeyframes:o,mirroredGenerator:a,resolvedDuration:l,calculatedDuration:c}=this;if(this.startTime===null)return r.next(0);const{delay:u=0,keyframes:d,repeat:f,repeatType:m,repeatDelay:p,type:b,onUpdate:x,finalKeyframe:y}=this.options;this.speed>0?this.startTime=Math.min(this.startTime,t):this.speed<0&&(this.startTime=Math.min(t-s/this.speed,this.startTime)),n?this.currentTime=t:this.updateTime(t);const w=this.currentTime-u*(this.playbackSpeed>=0?1:-1),g=this.playbackSpeed>=0?w<0:w>s;this.currentTime=Math.max(w,0),this.state==="finished"&&this.holdTime===null&&(this.currentTime=s);let v=this.currentTime,S=r;if(f){const N=Math.min(this.currentTime,s)/l;let E=Math.floor(N),k=N%1;!k&&N>=1&&(k=1),k===1&&E--,E=Math.min(E,f+1),!!(E%2)&&(m==="reverse"?(k=1-k,p&&(k-=p/l)):m==="mirror"&&(S=a)),v=zn(0,1,k)*l}const j=g?{done:!1,value:d[0]}:S.next(v);o&&(j.value=o(j.value));let{done:C}=j;!g&&c!==null&&(C=this.playbackSpeed>=0?this.currentTime>=s:this.currentTime<=0);const P=this.holdTime===null&&(this.state==="finished"||this.state==="running"&&C);return P&&b!==ph&&(j.value=Sp(d,this.options,y,this.speed)),x&&x(j.value),P&&this.finish(),j}then(t,n){return this.finished.then(t,n)}get duration(){return Kt(this.calculatedDuration)}get iterationDuration(){const{delay:t=0}=this.options||{};return this.duration+Kt(t)}get time(){return Kt(this.currentTime)}set time(t){var n;t=nr(t),this.currentTime=t,this.startTime===null||this.holdTime!==null||this.playbackSpeed===0?this.holdTime=t:this.driver&&(this.startTime=this.driver.now()-t/this.playbackSpeed),(n=this.driver)==null||n.start(!1)}get speed(){return this.playbackSpeed}set speed(t){this.updateTime(gt.now());const n=this.playbackSpeed!==t;this.playbackSpeed=t,n&&(this.time=Kt(this.currentTime))}play(){var s,o;if(this.isStopped)return;const{driver:t=H4,startTime:n}=this.options;this.driver||(this.driver=t(a=>this.tick(a))),(o=(s=this.options).onPlay)==null||o.call(s);const r=this.driver.now();this.state==="finished"?(this.updateFinished(),this.startTime=r):this.holdTime!==null?this.startTime=r-this.holdTime:this.startTime||(this.startTime=n??r),this.state==="finished"&&this.speed<0&&(this.startTime+=this.calculatedDuration),this.holdTime=null,this.state="running",this.driver.start()}pause(){this.state="paused",this.updateTime(gt.now()),this.holdTime=this.currentTime}complete(){this.state!=="running"&&this.play(),this.state="finished",this.holdTime=null}finish(){var t,n;this.notifyFinished(),this.teardown(),this.state="finished",(n=(t=this.options).onComplete)==null||n.call(t)}cancel(){var t,n;this.holdTime=null,this.startTime=0,this.tick(0),this.teardown(),(n=(t=this.options).onCancel)==null||n.call(t)}teardown(){this.state="idle",this.stopDriver(),this.startTime=this.holdTime=null}stopDriver(){this.driver&&(this.driver.stop(),this.driver=void 0)}sample(t){return this.startTime=0,this.tick(t,!0)}attachTimeline(t){var n;return this.options.allowFlatten&&(this.options.type="keyframes",this.options.ease="linear",this.initAnimation()),(n=this.driver)==null||n.stop(),t.observe(this)}}function cO(e){for(let t=1;t<e.length;t++)e[t]??(e[t]=e[t-1])}const Ns=e=>e*180/Math.PI,gh=e=>{const t=Ns(Math.atan2(e[1],e[0]));return xh(t)},uO={x:4,y:5,translateX:4,translateY:5,scaleX:0,scaleY:3,scale:e=>(Math.abs(e[0])+Math.abs(e[3]))/2,rotate:gh,rotateZ:gh,skewX:e=>Ns(Math.atan(e[1])),skewY:e=>Ns(Math.atan(e[2])),skew:e=>(Math.abs(e[1])+Math.abs(e[2]))/2},xh=e=>(e=e%360,e<0&&(e+=360),e),ry=gh,sy=e=>
vendor: 2,019 bytes, line 328
328Math.sqrt(e[0]*e[0]+e[1]*e[1]),oy=e=>Math.sqrt(e[4]*e[4]+e[5]*e[5]),dO={x:12,y:13,z:14,translateX:12,translateY:13,translateZ:14,scaleX:sy,scaleY:oy,scale:e=>(sy(e)+oy(e))/2,rotateX:e=>xh(Ns(Math.atan2(e[6],e[5]))),rotateY:e=>xh(Ns(Math.atan2(-e[2],e[0]))),rotateZ:ry,rotate:ry,skewX:e=>Ns(Math.atan(e[4])),skewY:e=>Ns(Math.atan(e[1])),skew:e=>(Math.abs(e[1])+Math.abs(e[4]))/2};function yh(e){return e.includes("scale")?1:0}function vh(e,t){if(!e||e==="none")return yh(t);const n=e.match(/^matrix3d\(([-\d.e\s,]+)\)$/u);let r,s;if(n)r=dO,s=n;else{const l=e.match(/^matrix\(([-\d.e\s,]+)\)$/u);r=uO,s=l}if(!s)return yh(t);const o=r[t],a=s[1].split(",").map(hO);return typeof o=="function"?o(a):a[o]}const fO=(e,t)=>{const{transform:n="none"}=getComputedStyle(e);return vh(n,t)};function hO(e){return parseFloat(e.trim())}const mi=["transformPerspective","x","y","z","translateX","translateY","translateZ","scale","scaleX","scaleY","rotate","rotateX","rotateY","rotateZ","skew","skewX","skewY"],pi=new Set(mi),iy=e=>e===hi||e===G,mO=new Set(["x","y","z"]),pO=mi.filter(e=>!mO.has(e));function gO(e){const t=[];return pO.forEach(n=>{const r=e.getValue(n);r!==void 0&&(t.push([n,r.get()]),r.set(n.startsWith("scale")?1:0))}),t}const Hr={width:({x:e},{paddingLeft:t="0",paddingRight:n="0"})=>e.max-e.min-parseFloat(t)-parseFloat(n),height:({y:e},{paddingTop:t="0",paddingBottom:n="0"})=>e.max-e.min-parseFloat(t)-parseFloat(n),top:(e,{top:t})=>parseFloat(t),left:(e,{left:t})=>parseFloat(t),bottom:({y:e},{top:t})=>parseFloat(t)+(e.max-e.min),right:({x:e},{left:t})=>parseFloat(t)+(e.max-e.min),x:(e,{transform:t})=>vh(t,"x"),y:(e,{transform:t})=>vh(t,"y")};Hr.translateX=Hr.x;Hr.translateY=Hr.y;const Is=new Set;let wh=!1,bh=!1,Sh=!1;function SS(){if(bh){const e=Array.from(Is).filter(r=>r.needsMeasurement),t=new Set(e.map(r=>r.element)),n=new Map;t.forEach(r=>{const s=gO(r);s.length&&(n.set(r,s),r.render())}),e.forEach(r=>r.measureInitialState()),t.forEach(r=>{r.render();const s=n.get(r);s&&s.forEach(([o,a])=>{var l;
vendor: 24,114 bytes, lines 328-336
328(l=r.getValue(o))==null||l.set(a)})}),e.forEach(r=>r.measureEndState()),e.forEach(r=>{r.suspendedScrollY!==void 0&&window.scrollTo(0,r.suspendedScrollY)})}bh=!1,wh=!1,Is.forEach(e=>e.complete(Sh)),Is.clear()}function jS(){Is.forEach(e=>{e.readKeyframes(),e.needsMeasurement&&(bh=!0)})}function xO(){Sh=!0,jS(),SS(),Sh=!1}class Cp{constructor(t,n,r,s,o,a=!1){this.state="pending",this.isAsync=!1,this.needsMeasurement=!1,this.unresolvedKeyframes=[...t],this.onComplete=n,this.name=r,this.motionValue=s,this.element=o,this.isAsync=a}scheduleResolve(){this.state="scheduled",this.isAsync?(Is.add(this),wh||(wh=!0,Pe.read(jS),Pe.resolveKeyframes(SS))):(this.readKeyframes(),this.complete())}readKeyframes(){const{unresolvedKeyframes:t,name:n,element:r,motionValue:s}=this;if(t[0]===null){const o=s==null?void 0:s.get(),a=t[t.length-1];if(o!==void 0)t[0]=o;else if(r&&n){const l=r.readValue(n,a);l!=null&&(t[0]=l)}t[0]===void 0&&(t[0]=a),s&&o===void 0&&s.set(t[0])}cO(t)}setFinalKeyframe(){}measureInitialState(){}renderEndStyles(){}measureEndState(){}complete(t=!1){this.state="complete",this.onComplete(this.unresolvedKeyframes,this.finalKeyframe,t),Is.delete(this)}cancel(){this.state==="scheduled"&&(Is.delete(this),this.state="pending")}resume(){this.state==="pending"&&this.scheduleResolve()}}const yO=e=>e.startsWith("--");function vO(e,t,n){yO(t)?e.style.setProperty(t,n):e.style[t]=n}const wO=hp(()=>window.ScrollTimeline!==void 0),bO={};function SO(e,t){const n=hp(e);return()=>bO[t]??n()}const NS=SO(()=>{try{document.createElement("div").animate({opacity:0},{easing:"linear(0, 1)"})}catch{return!1}return!0},"linearEasing"),Vi=([e,t,n,r])=>`cubic-bezier(${e}, ${t}, ${n}, ${r})`,ay={linear:"linear",ease:"ease",easeIn:"ease-in",easeOut:"ease-out",easeInOut:"ease-in-out",circIn:Vi([0,.65,.55,1]),circOut:Vi([.55,0,1,.45]),backIn:Vi([.31,.01,.66,-.59]),backOut:Vi([.33,1.53,.69,.99])};function CS(e,t){if(e)return typeof e=="function"?NS()?vS(e,t):"ease-out":lS(e)?Vi(e):Array.isArray(e)?e.map(n=>CS(n,t)||ay.easeOut):ay[e]}function jO(e,t,n,{delay:r=0,duration:s=300,repeat:o=0,repeatType:a="loop",ease:l="easeOut",times:c}={},u=void 0){const d={[t]:n};c&&(d.offset=c);const f=CS(l,s);Array.isArray(f)&&(d.easing=f);const m={delay:r,duration:s,easing:Array.isArray(f)?"linear":f,fill:"both",iterations:o+1,direction:a==="reverse"?"alternate":"normal"};return u&&(m.pseudoElement=u),e.animate(d,m)}function kS(e){return typeof e=="function"&&"applyToOptions"in e}function NO({type:e,...t}){return kS(e)&&NS()?e.applyToOptions(t):(t.duration??(t.duration=300),t.ease??(t.ease="easeOut"),t)}class CO extends jp{constructor(t){if(super(),this.finishedTime=null,this.isStopped=!1,this.manualStartTime=null,!t)return;const{element:n,name:r,keyframes:s,pseudoElement:o,allowFlatten:a=!1,finalKeyframe:l,onComplete:c}=t;this.isPseudoElement=!!o,this.allowFlatten=a,this.options=t,fp(typeof t.type!="string");const u=NO(t);this.animation=jO(n,r,s,u,o),u.autoplay===!1&&this.animation.pause(),this.animation.onfinish=()=>{if(this.finishedTime=this.time,!o){const d=Sp(s,this.options,l,this.speed);this.updateMotionValue?this.updateMotionValue(d):vO(n,r,d),this.animation.cancel()}c==null||c(),this.notifyFinished()}}play(){this.isStopped||(this.manualStartTime=null,this.animation.play(),this.state==="finished"&&this.updateFinished())}pause(){this.animation.pause()}complete(){var t,n;(n=(t=this.animation).finish)==null||n.call(t)}cancel(){try{this.animation.cancel()}catch{}}stop(){if(this.isStopped)return;this.isStopped=!0;const{state:t}=this;t==="idle"||t==="finished"||(this.updateMotionValue?this.updateMotionValue():this.commitStyles(),this.isPseudoElement||this.cancel())}commitStyles(){var t,n;this.isPseudoElement||(n=(t=this.animation).commitStyles)==null||n.call(t)}get duration(){var n,r;const t=((r=(n=this.animation.effect)==null?void 0:n.getComputedTiming)==null?void 0:r.call(n).duration)||0;return Kt(Number(t))}get iterationDuration(){const{delay:t=0}=this.options||{};return this.duration+Kt(t)}get time(){return Kt(Number(this.animation.currentTime)||0)}set time(t){this.manualStartTime=null,this.finishedTime=null,this.animation.currentTime=nr(t)}get speed(){return this.animation.playbackRate}set speed(t){t<0&&(this.finishedTime=null),this.animation.playbackRate=t}get state(){return this.finishedTime!==null?"finished":this.animation.playState}get startTime(){return this.manualStartTime??Number(this.animation.startTime)}set startTime(t){this.manualStartTime=this.animation.startTime=t}attachTimeline({timeline:t,observe:n}){var r;return this.allowFlatten&&((r=this.animation.effect)==null||r.updateTiming({easing:"linear"})),this.animation.onfinish=null,t&&wO()?(this.animation.timeline=t,Gt):n(this)}}const PS={anticipate:sS,backInOut:rS,circInOut:iS};function kO(e){return e in PS}function PO(e){typeof e.ease=="string"&&kO(e.ease)&&(e.ease=PS[e.ease])}const Ed=10;class EO extends CO{constructor(t){PO(t),bS(t),super(t),t.startTime!==void 0&&(this.startTime=t.startTime),this.options=t}updateMotionValue(t){const{motionValue:n,onUpdate:r,onComplete:s,element:o,...a}=this.options;if(!n)return;if(t!==void 0){n.set(t);return}const l=new Np({...a,autoplay:!1}),c=Math.max(Ed,gt.now()-this.startTime),u=zn(0,Ed,c-Ed);n.setWithVelocity(l.sample(Math.max(0,c-u)).value,l.sample(c).value,u),l.stop()}}const ly=(e,t)=>t==="zIndex"?!1:!!(typeof e=="number"||Array.isArray(e)||typeof e=="string"&&(is.test(e)||e==="0")&&!e.startsWith("url("));function TO(e){const t=e[0];if(e.length===1)return!0;for(let n=0;n<e.length;n++)if(e[n]!==t)return!0}function RO(e,t,n,r){const s=e[0];if(s===null)return!1;if(t==="display"||t==="visibility")return!0;const o=e[e.length-1],a=ly(s,t),l=ly(o,t);return!a||!l?!1:TO(e)||(n==="spring"||kS(n))&&r}function jh(e){e.duration=0,e.type="keyframes"}const AO=new Set(["opacity","clipPath","filter","transform"]),MO=hp(()=>Object.hasOwnProperty.call(Element.prototype,"animate"));function OO(e){var d;const{motionValue:t,name:n,repeatDelay:r,repeatType:s,damping:o,type:a}=e;if(!(((d=t==null?void 0:t.owner)==null?void 0:d.current)instanceof HTMLElement))return!1;const{onUpdate:c,transformTemplate:u}=t.owner.getProps();return MO()&&n&&AO.has(n)&&(n!=="transform"||!u)&&!c&&!r&&s!=="mirror"&&o!==0&&a!=="inertia"}const IO=40;class DO extends jp{constructor({autoplay:t=!0,delay:n=0,type:r="keyframes",repeat:s=0,repeatDelay:o=0,repeatType:a="loop",keyframes:l,name:c,motionValue:u,element:d,...f}){var b;super(),this.stop=()=>{var x,y;this._animation&&(this._animation.stop(),(x=this.stopTimeline)==null||x.call(this)),(y=this.keyframeResolver)==null||y.cancel()},this.createdAt=gt.now();const m={autoplay:t,delay:n,type:r,repeat:s,repeatDelay:o,repeatType:a,name:c,motionValue:u,element:d,...f},p=(d==null?void 0:d.KeyframeResolver)||Cp;this.keyframeResolver=new p(l,(x,y,w)=>this.onKeyframesResolved(x,y,m,!w),c,u,d),(b=this.keyframeResolver)==null||b.scheduleResolve()}onKeyframesResolved(t,n,r,s){this.keyframeResolver=void 0;const{name:o,type:a,velocity:l,delay:c,isHandoff:u,onUpdate:d}=r;this.resolvedAt=gt.now(),RO(t,o,a,l)||((ur.instantAnimations||!c)&&(d==null||d(Sp(t,r,n))),t[0]=t[t.length-1],jh(r),r.repeat=0);const m={startTime:s?this.resolvedAt?this.resolvedAt-this.createdAt>IO?this.resolvedAt:this.createdAt:this.createdAt:void 0,finalKeyframe:n,...r,keyframes:t},p=!u&&OO(m)?new EO({...m,element:m.motionValue.owner.current}):new Np(m);p.finished.then(()=>this.notifyFinished()).catch(Gt),this.pendingTimeline&&(this.stopTimeline=p.attachTimeline(this.pendingTimeline),this.pendingTimeline=void 0),this._animation=p}get finished(){return this._animation?this.animation.finished:this._finished}then(t,n){return this.finished.finally(t).then(()=>{})}get animation(){var t;return this._animation||((t=this.keyframeResolver)==null||t.resume(),xO()),this._animation}get duration(){return this.animation.duration}get iterationDuration(){return this.animation.iterationDuration}get time(){return this.animation.time}set time(t){this.animation.time=t}get speed(){return this.animation.speed}get state(){return this.animation.state}set speed(t){this.animation.speed=t}get startTime(){return this.animation.startTime}attachTimeline(t){return this._animation?this.stopTimeline=this.animation.attachTimeline(t):this.pendingTimeline=t,()=>this.stop()}play(){this.animation.play()}pause(){this.animation.pause()}complete(){this.animation.complete()}cancel(){var t;this._animation&&this.animation.cancel(),(t=this.keyframeResolver)==null||t.cancel()}}const LO=/^var\(--(?:([\w-]+)|([\w-]+), ?([a-zA-Z\d ()%#.,-]+))\)/u;function _O(e){const t=LO.exec(e);if(!t)return[,];const[,n,r,s]=t;return[`--${n??r}`,s]}function ES(e,t,n=1){const[r,s]=_O(e);if(!r)return;const o=window.getComputedStyle(t).getPropertyValue(r);if(o){const a=o.trim();return q1(a)?parseFloat(a):a}return xp(s)?ES(s,t,n+1):s}function kp(e,t){return(e==null?void 0:e[t])??(e==null?void 0:e.default)??e}const TS=new Set(["width","height","top","left","right","bottom",...mi]),FO={test:e=>e==="auto",parse:e=>e},RS=e=>t=>t.test(e),AS=[hi,G,$n,Rr,T4,E4,FO],cy=e=>AS.find(RS(e));function VO(e){return typeof e=="number"?e===0:e!==null?e==="none"||e==="0"||X1(e):!0}const $O=new Set(["brightness","contrast","saturate","opacity"]);function BO(e){const[t,n]=e.slice(0,-1).split("(");if(t==="drop-shadow")return e;const[r]=n.match(yp)||[];if(!r)return e;const s=n.replace(r,"");let o=$O.has(t)?1:0;return r!==n&&(o*=100),t+"("+o+s+")"}const zO=/\b([a-z-]*)\(.*?\)/gu,Nh={...is,getAnimatableNone:e=>{const t=e.match(zO);return t?t.map(BO).join(" "):e}},uy={...hi,transform:Math.round},UO={rotate:Rr,rotateX:Rr,rotateY:Rr,rotateZ:Rr,scale:wl,scaleX:wl,scaleY:wl,scaleZ:wl,skew:Rr,skewX:Rr,skewY:Rr,distance:G,translateX:G,translateY:G,translateZ:G,x:G,y:G,z:G,perspective:G,transformPerspective:G,opacity:Ta,originX:Jx,originY:Jx,originZ:G},Pp={borderWidth:G,borderTopWidth:G,borderRightWidth:G,borderBottomWidth:G,borderLeftWidth:G,borderRadius:G,radius:G,borderTopLeftRadius:G,borderTopRightRadius:G,borderBottomRightRadius:G,borderBottomLeftRadius:G,width:G,maxWidth:G,height:G,maxHeight:G,top:G,right:G,bottom:G,left:G,inset:G,insetBlock:G,insetBlockStart:G,insetBlockEnd:G,insetInline:G,insetInlineStart:G,insetInlineEnd:G,padding:G,paddingTop:G,paddingRight:G,paddingBottom:G,paddingLeft:G,paddingBlock:G,paddingBlockStart:G,paddingBlockEnd:G,paddingInline:G,paddingInlineStart:G,paddingInlineEnd:G,margin:G,marginTop:G,marginRight:G,marginBottom:G,marginLeft:G,marginBlock:G,marginBlockStart:G,marginBlockEnd:G,marginInline:G,marginInlineStart:G,marginInlineEnd:G,backgroundPositionX:G,backgroundPositionY:G,...UO,zIndex:uy,fillOpacity:Ta,strokeOpacity:Ta,numOctaves:uy},WO={...Pp,color:ze,backgroundColor:ze,outlineColor:ze,fill:ze,stroke:ze,borderColor:ze,borderTopColor:ze,borderRightColor:ze,borderBottomColor:ze,borderLeftColor:ze,filter:Nh,WebkitFilter:Nh},MS=e=>WO[e];function OS(e,t){let n=MS(e);return n!==Nh&&(n=is),n.getAnimatableNone?n.getAnimatableNone(t):void 0}const HO=new Set(["auto","none","0"]);function KO(e,t,n){let r=0,s;for(;r<e.length&&!s;){const o=e[r];typeof o=="string"&&!HO.has(o)&&Ra(o).values.length&&(s=e[r]),r++}if(s&&n)for(const o of t)e[o]=OS(n,s)}class YO extends Cp{constructor(t,n,r,s,o){super(t,n,r,s,o,!0)}readKeyframes(){const{unresolvedKeyframes:t,element:n,name:r}=this;if(!n||!n.current)return;super.readKeyframes();for(let d=0;d<t.length;d++){let f=t[d];if(typeof f=="string"&&(f=f.trim(),xp(f))){const m=ES(f,n.current);m!==void 0&&(t[d]=m),d===t.length-1&&(this.finalKeyframe=f)}}if(this.resolveNoneKeyframes(),!TS.has(r)||t.length!==2)return;const[s,o]=t,a=cy(s),l=cy(o),c=Xx(s),u=Xx(o);if(c!==u&&Hr[r]){this.needsMeasurement=!0;return}if(a!==l)if(iy(a)&&iy(l))for(let d=0;d<t.length;d++){const f=t[d];typeof f=="string"&&(t[d]=parseFloat(f))}else Hr[r]&&(this.needsMeasurement=!0)}resolveNoneKeyframes(){const{unresolvedKeyframes:t,name:n}=this,r=[];for(let s=0;s<t.length;s++)(t[s]===null||VO(t[s]))&&r.push(s);r.length&&KO(t,r,n)}measureInitialState(){const{element:t,unresolvedKeyframes:n,name:r}=this;if(!t||!t.current)return;r==="height"&&(this.suspendedScrollY=window.pageYOffset),this.measuredOrigin=Hr[r](t.measureViewportBox(),window.getComputedStyle(t.current)),n[0]=this.measuredOrigin;const s=n[n.length-1];s!==void 0&&t.getValue(r,s).jump(s,!1)}measureEndState(){var l;const{element:t,name:n,unresolvedKeyframes:r}=this;if(!t||!t.current)return;const s=t.getValue(n);s&&s.jump(this.measuredOrigin,!1);const o=r.length-1,a=r[o];r[o]=Hr[n](t.measureViewportBox(),window.getComputedStyle(t.current)),a!==null&&this.finalKeyframe===void 0&&(this.finalKeyframe=a),(l=this.removedTransforms)!=null&&l.length&&this.removedTransforms.forEach(([c,u])=>{t.getValue(c).set(u)}),this.resolveNoneKeyframes()}}function GO(e,t,n){if(e instanceof EventTarget)return[e];if(typeof e=="string"){let r=document;const s=(n==null?void 0:n[e])??r.querySelectorAll(e);return s?Array.from(s):[]}return Array.from(e)}const IS=(e,t)=>t&&typeof e=="number"?t.transform(e):e;function DS(e){return Q1(e)&&"offsetHeight"in e}const dy=30,qO=e=>!isNaN(parseFloat(e));class QO{constructor(t,n={}){this.canTrackVelocity=null,this.events={},this.updateAndNotify=r=>{var o;const s=gt.now();if(this.updatedAt!==s&&this.setPrevFrameValue(),this.prev=this.current,this.setCurrent(r),this.current!==this.prev&&((o=this.events.change)==null||o.notify(this.current),this.dependents))for(const a of this.dependents)a.dirty()},this.hasAnimated=!1,this.setCurrent(t),this.owner=n.owner}setCurrent(t){this.current=t,this.updatedAt=gt.now(),this.canTrackVelocity===null&&t!==void 0&&(this.canTrackVelocity=qO(this.current))}setPrevFrameValue(t=this.current){this.prevFrameValue=t,this.prevUpdatedAt=this.updatedAt}onChange(t){return this.on("change",t)}on(t,n){this.events[t]||(this.events[t]=new mp);const r=this.events[t].add(n);return t==="change"?()=>{r(),Pe.read(()=>{this.events.change.getSize()||this.stop()})}:r}clearListeners(){for(const t in this.events)this.events[t].clear()}attach(t,n){this.passiveEffect=t,this.stopPassiveEffect=n}set(t){this.passiveEffect?this.passiveEffect(t,this.updateAndNotify):this.updateAndNotify(t)}setWithVelocity(t,n,r){this.set(n),this.prev=void 0,this.prevFrameValue=t,this.prevUpdatedAt=this.updatedAt-r}jump(t,n=!0){this.updateAndNotify(t),this.prev=t,this.prevUpdatedAt=this.prevFrameValue=void 0,n&&this.stop(),this.stopPassiveEffect&&this.stopPassiveEffect()}dirty(){var t;(t=this.events.change)==null||t.notify(this.current)}addDependent(t){this.dependents||(this.dependents=new Set),this.dependents.add(t)}removeDependent(t){this.dependents&&this.dependents.delete(t)}get(){return this.current}getPrevious(){return this.prev}getVelocity(){const t=gt.now();if(!this.canTrackVelocity||this.prevFrameValue===void 0||t-this.updatedAt>dy)return 0;const n=Math.min(this.updatedAt-this.prevUpdatedAt,dy);return J1(parseFloat(this.current)-parseFloat(this.prevFrameValue),n)}start(t){return this.stop(),new Promise(n=>{this.hasAnimated=!0,this.animation=t(n),this.events.animationStart&&this.events.animationStart.notify()}).then(()=>{this.events.animationComplete&&this.events.animationComplete.notify(),this.clearAnimation()})}stop(){this.animation&&(this.animation.stop(),this.events.animationCancel&&this.events.animationCancel.notify()),this.clearAnimation()}isAnimating(){return!!this.animation}clearAnimation(){delete this.animation}destroy(){var t,n;(t=this.dependents)==null||t.clear(),(n=this.events.destroy)==null||n.notify(),this.clearListeners(),this.stop(),this.stopPassiveEffect&&this.stopPassiveEffect()}}function ei(e,t){return new QO(e,t)}const{schedule:Ep}=cS(queueMicrotask,!1),ln={x:!1,y:!1};function LS(){return ln.x||ln.y}function XO(e){return e==="x"||e==="y"?ln[e]?null:(ln[e]=!0,()=>{ln[e]=!1}):ln.x||ln.y?null:(ln.x=ln.y=!0,()=>{ln.x=ln.y=!1})}function _S(e,t){const n=GO(e),r=new AbortController,s={passive:!0,...t,signal:r.signal};return[n,s,()=>r.abort()]}function fy(e){return!(e.pointerType==="touch"||LS())}function JO(e,t,n={}){const[r,s,o]=_S(e,n),a=l=>{if(!fy(l))return;const{target:c}=l,u=t(c,l);if(typeof u!="function"||!c)return;const d=f=>{fy(f)&&(u(f),c.removeEventListener("pointerleave",d))};c.addEventListener("pointerleave",d,s)};return r.forEach(l=>{l.addEventListener("pointerenter",a,s)}),o}const FS=(e,t)=>t?e===t?!0:FS(e,t.parentElement):!1,Tp=e=>e.pointerType==="mouse"?typeof e.button!="number"||e.button<=0:e.isPrimary!==!1,ZO=new Set(["BUTTON","INPUT","SELECT","TEXTAREA","A"]);function VS(e){return ZO.has(e.tagName)||e.isContentEditable===!0}const Yl=new WeakSet;function hy(e){return t=>{t.key==="Enter"&&e(t)}}function Td(e,t){e.dispatchEvent(new PointerEvent("pointer"+t,{isPrimary:!0,bubbles:!0}))}const eI=(e,t)=>{const n=e.currentTarget;if(!n)return;const r=hy(()=>{if(Yl.has(n))return;Td(n,"down");const s=hy(()=>{Td(n,"up")}),o=()=>Td(n,"cancel");n.addEventListener("keyup",s,t),n.addEventListener("blur",o,t)});n.addEventListener("keydown",r,t),n.addEventListener("blur",()=>n.removeEventListener("keydown",r),t)};function my(e){return Tp(e)&&!LS()}function tI(e,t,n={}){const[r,s,o]=_S(e,n),a=l=>{const c=l.currentTarget;if(!my(l))return;Yl.add(c);const u=t(c,l),d=(p,b)=>{window.removeEventListener("pointerup",f),window.removeEventListener("pointercancel",m),Yl.has(c)&&Yl.delete(c),my(p)&&typeof u=="function"&&u(p,{success:b})},f=p=>{d(p,c===window||c===document||n.useGlobalTarget||FS(c,p.target))},m=p=>{d(p,!1)};window.addEventListener("pointerup",f,s),window.addEventListener("pointercancel",m,s)};return r.forEach(l=>{(n.useGlobalTarget?window:l).addEventListener("pointerdown",a,s),DS(l)&&(l.addEventListener("focus",u=>eI(u,s)),!VS(l)&&!l.hasAttribute("tabindex")&&(l.tabIndex=0))}),o}function $S(e){return Q1(e)&&"ownerSVGElement"in e}function nI(e){return $S(e)&&e.tagName==="svg"}const ct=e=>!!(e&&e.getVelocity),rI=[...AS,ze,is],sI=e=>rI.find(RS(e)),Rp=h.createContext({transformPagePoint:e=>e,isStatic:!1,reducedMotion:"never"});function py(e,t){if(typeof e=="function")return e(t);e!=null&&(e.current=t)}function oI(...e){return t=>{let n=!1;const r=e.map(s=>{const o=py(s,t);return!n&&typeof o=="function"&&(n=!0),o});if(n)return()=>{for(let s=0;s<r.length;s++){const o=r[s];typeof o=="function"?o():py(e[s],null)}}}}function iI(...e){return h.useCallback(oI(...e),e)}class aI extends h.Component{getSnapshotBeforeUpdate(t){const n=this.props.childRef.current;if(n&&t.isPresent&&!this.props.isPresent){const r=n.offsetParent,s=DS(r)&&r.offsetWidth||0,o=this.props.sizeRef.current;o.height=n.offsetHeight||0,o.width=n.offsetWidth||0,o.top=n.offsetTop,o.left=n.offsetLeft,o.right=s-o.width-o.left}return null}componentDidUpdate(){}render(){return this.props.children}}function lI({children:e,isPresent:t,anchorX:n,root:r}){var d;const s=h.useId(),o=h.useRef(null),a=h.useRef({width:0,height:0,top:0,left:0,right:0}),{nonce:l}=h.useContext(Rp),c=((d=e.props)==null?void 0:d.ref)??(e==null?void 0:e.ref),u=iI(o,c);return h.useInsertionEffect(()=>{const{width:f,height:m,top:p,left:b,right:x}=a.current;if(t||!o.current||!f||!m)return;const y=n==="left"?`left: ${b}`:`right: ${x}`;o.current.dataset.motionPopId=s;const w=document.createElement("style");l&&(w.nonce=l);const g=r??document.head;return g.appendChild(w),w.sheet&&w.sheet.insertRule(`
329          [data-motion-pop-id="${s}"] {
330            position: absolute !important;
331            width: ${f}px !important;
332            height: ${m}px !important;
333            ${y}px !important;
334            top: ${p}px !important;
335          }
336        `),()=>{g.contains(w)&&g.removeChild(w)}},[t]),i.jsx(aI,{isPresent:t,childRef:o,sizeRef:a,children:h.cloneElement(e,{ref:u})})}const cI=({children:e,initial:t,isPresent:n,onExitComplete:r,custom:s,presenceAffectsLayout:o,mode:a,anchorX:l,root:c})=>{const u=lp(uI),d=h.useId();let f=!0,m=h.useMemo(()=>(f=!1,{id:d,initial:t,isPresent:n,custom:s,onExitComplete:p=>{u.set(p,!0);for(const b of u.values())if(!b)return;r&&r()},register:p=>(u.set(p,!1),()=>u.delete(p))}),[n,u,r]);return o&&f&&(m={...m}),h.useMemo(()=>{u.forEach((p,b)=>u.set(b,!1))},[n]),h.useEffect(()=>{!n&&!u.size&&r&&r()},[n]),a==="popLayout"&&(e=i.jsx(lI,{isPresent:n,anchorX:l,root:c,children:e})),i.jsx(vu.Provider,{value:m,children:e})};function uI(){return new Map}function BS(e=!0){const t=h.useContext(vu);if(t===null)return[!0,null];const{isPresent:n,onExitComplete:r,register:s}=t,o=h.useId();h.useEffect(()=>{if(e)return s(o)},[e]);const a=h.useCallback(()=>e&&r&&r(o),[o,r,e]);return!n&&r?[!1,a]:[!0]}const bl=e=>e.key||"";function gy(e){const t=[];return h.Children.forEach(e,n=>{h.isValidElement(n)&&t.push(n)}),t}const ti=({children:e,custom:t,initial:n=!0,onExitComplete:r,presenceAffectsLayout:s=!0,mode:o="sync",propagate:a=!1,anchorX:l="left",root:c})=>{const[u,d]=BS(a),f=h.useMemo(()=>gy(e),[e]),m=a&&!u?[]:f.map(bl),p=h.useRef(!0),b=h.useRef(f),x=lp(()=>new Map),y=h.useRef(new Set),[w,g]=h.useState(f),[v,S]=h.useState(f);G1(()=>{p.current=!1,b.current=f;for(let P=0;P<v.length;P++){const N=bl(v[P]);m.includes(N)?(x.delete(N),y.current.delete(N)):x.get(N)!==!0&&x.set(N,!1)}},[v,m.length,m.join("-")]);const j=[];if(f!==w){let P=[...f];for(let N=0;N<v.length;N++){const E=v[N],k=bl(E);m.includes(k)||(P.splice(N,0,E),j.push(E))}return o==="wait"&&j.length&&(P=j),S(gy(P)),g(f),null}const{forceRender:C}=h.useContext(ap);return i.jsx(i.Fragment,{children:v.map(P=>{const N=bl(P),E=a&&!u?!1:f===v||m.includes(N),k=()=>{if(y.current.has(N))return;if(y.current.add(N),x.has(N))x.set(N,!0);else return;let R=!0;x.forEach(M=>{M||(R=!1)}),R&&(C==null||C(),S(b.current),a&&(d==null||d()),r&&r())};return i.jsx(cI,{isPresent:E,initial:!p.current||n?void 0:!1,custom:t,presenceAffectsLayout:s,mode:o,root:c,onExitComplete:E?void 0:k,anchorX:l,children:P},N)})})},zS=h.createContext({strict:!1}),xy={animation:["animate","variants","whileHover","whileTap","exit","whileInView","whileFocus","whileDrag"],exit:["exit"],drag:["drag","dragControls"],focus:["whileFocus"],hover:["whileHover","onHoverStart","onHoverEnd"],tap:["whileTap","onTap","onTapStart","onTapCancel"],pan:["onPan","onPanStart","onPanSessionStart","onPanEnd"],inView:["whileInView","onViewportEnter","onViewportLeave"],layout:["layout","layoutId"]},ni={};for(const e in xy)ni[e]={isEnabled:t=>xy[e].some(n=>!!t[n])};function dI(e){for(const t in e)ni[t]={...ni[t],...e[t]}}const fI=new Set(["animate","exit","variants","initial","style","values","variants","transition","transformTemplate","custom","inherit","onBeforeLayoutMeasure","onAnimationStart","onAnimationComplete","onUpdate","onDragStart","onDrag","onDragEnd","onMeasureDragConstraints","onDirectionLock","onDragTransitionEnd","_dragX","_dragY","onHoverStart","onHoverEnd","onViewportEnter","onViewportLeave","globalTapTarget","ignoreStrict","viewport"]);function _c(e){return e.startsWith("while")||e.startsWith("drag")&&e!=="draggable"||e.startsWith("layout")||e.startsWith("onTap")||e.startsWith("onPan")||e.startsWith("onLayout")||fI.has(e)}let US=e=>!_c(e);function hI(e){typeof e=="function"&&(US=t=>t.startsWith("on")?!_c(t):e(t))}try{hI(require("@emotion/is-prop-valid").default)}catch{}function mI(e,t,n){const r={};for(const s in e)s==="values"&&typeof e.values=="object"||(US(s)||n===!0&&_c(s)||!t&&!_c(s)||e.draggable&&s.startsWith("onDrag"))&&(r[s]=e[s]);return r}const wu=h.createContext({});function bu(e){return e!==null&&typeof e=="object"&&typeof e.start=="function"}function Aa(e){return typeof e=="string"||Array.isArray(e)}const Ap=["animate","whileInView","whileFocus","whileHover","whileTap","whileDrag","exit"],Mp=["initial",...Ap];function Su(e){return bu(e.animate)||Mp.some(t=>Aa(e[t]))}function WS(e){return!!(Su(e)||e.variants)}function pI(e,t){if(Su(e)){const{initial:n,animate:r}=e;return{initial:n===!1||Aa(n)?n:void 0,animate:Aa(r)?r:void 0}}return e.inherit!==!1?t:{}}function gI(e){const{initial:t,animate:n}=pI(e,h.useContext(wu));return h.useMemo(()=>({initial:t,animate:n}),[yy(t),yy(n)])}function yy(e){return Array.isArray(e)?e.join(" "):e}function vy(e,t){return t.max===t.min?0:e/(t.max-t.min)*100}const Ri={correct:(e,t)=>
vendor: 4,189 bytes, line 336
336{if(!t.target)return e;if(typeof e=="string")if(G.test(e))e=parseFloat(e);else return e;const n=vy(e,t.target.x),r=vy(e,t.target.y);return`${n}% ${r}%`}},xI={correct:(e,{treeScale:t,projectionDelta:n})=>{const r=e,s=is.parse(e);if(s.length>5)return r;const o=is.createTransformer(e),a=typeof s[0]!="number"?1:0,l=n.x.scale*t.x,c=n.y.scale*t.y;s[0+a]/=l,s[1+a]/=c;const u=Me(l,c,.5);return typeof s[2+a]=="number"&&(s[2+a]/=u),typeof s[3+a]=="number"&&(s[3+a]/=u),o(s)}},Ch={borderRadius:{...Ri,applyTo:["borderTopLeftRadius","borderTopRightRadius","borderBottomLeftRadius","borderBottomRightRadius"]},borderTopLeftRadius:Ri,borderTopRightRadius:Ri,borderBottomLeftRadius:Ri,borderBottomRightRadius:Ri,boxShadow:xI};function HS(e,{layout:t,layoutId:n}){return pi.has(e)||e.startsWith("origin")||(t||n!==void 0)&&(!!Ch[e]||e==="opacity")}const yI={x:"translateX",y:"translateY",z:"translateZ",transformPerspective:"perspective"},vI=mi.length;function wI(e,t,n){let r="",s=!0;for(let o=0;o<vI;o++){const a=mi[o],l=e[a];if(l===void 0)continue;let c=!0;if(typeof l=="number"?c=l===(a.startsWith("scale")?1:0):c=parseFloat(l)===0,!c||n){const u=IS(l,Pp[a]);if(!c){s=!1;const d=yI[a]||a;r+=`${d}(${u}) `}n&&(t[a]=u)}}return r=r.trim(),n?r=n(t,s?"":r):s&&(r="none"),r}function Op(e,t,n){const{style:r,vars:s,transformOrigin:o}=e;let a=!1,l=!1;for(const c in t){const u=t[c];if(pi.has(c)){a=!0;continue}else if(dS(c)){s[c]=u;continue}else{const d=IS(u,Pp[c]);c.startsWith("origin")?(l=!0,o[c]=d):r[c]=d}}if(t.transform||(a||n?r.transform=wI(t,e.transform,n):r.transform&&(r.transform="none")),l){const{originX:c="50%",originY:u="50%",originZ:d=0}=o;r.transformOrigin=`${c} ${u} ${d}`}}const Ip=()=>({style:{},transform:{},transformOrigin:{},vars:{}});function KS(e,t,n){for(const r in t)!ct(t[r])&&!HS(r,n)&&(e[r]=t[r])}function bI({transformTemplate:e},t){return h.useMemo(()=>{const n=Ip();return Op(n,t,e),Object.assign({},n.vars,n.style)},[t])}function SI(e,t){const n=e.style||{},r={};return KS(r,n,e),Object.assign(r,bI(e,t)),r}function jI(e,t){const n={},r=SI(e,t);return e.drag&&e.dragListener!==!1&&(n.draggable=!1,r.userSelect=r.WebkitUserSelect=r.WebkitTouchCallout="none",r.touchAction=e.drag===!0?"none":`pan-${e.drag==="x"?"y":"x"}`),e.tabIndex===void 0&&(e.onTap||e.onTapStart||e.whileTap)&&(n.tabIndex=0),n.style=r,n}const NI={offset:"stroke-dashoffset",array:"stroke-dasharray"},CI={offset:"strokeDashoffset",array:"strokeDasharray"};function kI(e,t,n=1,r=0,s=!0){e.pathLength=1;const o=s?NI:CI;e[o.offset]=G.transform(-r);const a=G.transform(t),l=G.transform(n);e[o.array]=`${a} ${l}`}const PI=["offsetDistance","offsetPath","offsetRotate","offsetAnchor"];function YS(e,{attrX:t,attrY:n,attrScale:r,pathLength:s,pathSpacing:o=1,pathOffset:a=0,...l},c,u,d){if(Op(e,l,u),c){e.style.viewBox&&(e.attrs.viewBox=e.style.viewBox);return}e.attrs=e.style,e.style={};const{attrs:f,style:m}=e;f.transform&&(m.transform=f.transform,delete f.transform),(m.transform||f.transformOrigin)&&(m.transformOrigin=f.transformOrigin??"50% 50%",delete f.transformOrigin),m.transform&&(m.transformBox=(d==null?void 0:d.transformBox)??"fill-box",delete f.transformBox);for(const p of PI)f[p]!==void 0&&(m[p]=f[p],delete f[p]);t!==void 0&&(f.x=t),n!==void 0&&(f.y=n),r!==void 0&&(f.scale=r),s!==void 0&&kI(f,s,o,a,!1)}const GS=()=>({...Ip(),attrs:{}}),qS=e=>typeof e=="string"&&e.toLowerCase()==="svg";function EI(e,t,n,r){const s=h.useMemo(()=>{const o=GS();return YS(o,t,qS(r),e.transformTemplate,e.style),{...o.attrs,style:{...o.style}}},[t]);if(e.style){const o={};KS(o,e.style,e),s.style={...o,...s.style}}return s}const TI=["animate","circle","defs","desc","ellipse","g","image","line","filter","marker","mask","metadata","path","pattern","polygon","polyline","rect","stop","switch","symbol","svg","text","tspan","use","view"];function Dp(e){return typeof e!="string"||e.includes("-")?!1:!!(TI.indexOf(e)>-1||/[A-Z]/u.test(e))}function RI(e,t,n,{latestValues:r},s,o=!1,a){const c=(a??Dp(e)?EI:jI)(t,r,s,e),u=mI(t,typeof e=="string",o),d=e!==h.Fragment?{...u,...c,ref:n}:{},{children:f}=t,m=h.useMemo(()=>ct(f)?f.get():f,[f]);return h.createElement(e,{...d,children:m})}function wy(e){const t=[{},{}];
336return e==null||e.values.forEach((n,r)=>{t[0][r]=n.get(),t[1][r]=n.getVelocity()}),t}function Lp(e,t,n,r){if(typeof t=="function"){const[s,o]=wy(r);t=t(n!==void 0?n:e.custom,s,o)}if(typeof t=="string"&&(t=e.variants&&e.variants[t]),typeof t=="function"){const[s,o]=wy(r);t=t(n!==void 0?n:e.custom,s,o)}return t}function Gl(e){return ct(e)?e.get():e}function AI({scrapeMotionValuesFromProps:e,createRenderState:t},n,r,s){return{latestValues:MI(n,r,s,e),renderState:t()}}function MI(e,t,n,r){const s={},o=r(e,{});for(const m in o)s[m]=Gl(o[m]);let{initial:a,animate:l}=e;const c=Su(e),u=WS(e);t&&u&&!c&&e.inherit!==!1&&(a===void 0&&(a=t.initial),l===void 0&&(l=t.animate));let d=n?n.initial===!1:!1;d=d||a===!1;const f=d?l:a;if(f&&typeof f!="boolean"&&!bu(f)){const m=Array.isArray(f)?f:[f];for(let p=0;p<m.length;p++){const b=Lp(e,m[p]);if(b){const{transitionEnd:x,transition:y,...w}=b;for(const g in w){let v=w[g];if(Array.isArray(v)){const S=d?v.length-1:0;v=v[S]}v!==null&&(s[g]=v)}for(const g in x)s[g]=x[g]}}}return s}const QS=e=>(t,n)=>{const r=h.useContext(wu),s=h.useContext(vu),o=()=>AI(e,t,r,s);return n?o():lp(o)};function _p(e,t,n){var o;const{style:r}=e,s={};for(const a in r)(ct(r[a])||t.style&&ct(t.style[a])||HS(a,e)||((o=n==null?void 0:n.getValue(a))==null?void 0:o.liveStyle)!==void 0)&&(s[a]=r[a]);return s}const OI=QS({scrapeMotionValuesFromProps:_p,createRenderState:Ip});function XS(e,t,n){const r=_p(e,t,n);for(const s in e)if(ct(e[s])||ct(t[s])){const o=mi.indexOf(s)!==-1?"attr"+s.charAt(0).toUpperCase()+s.substring(1):s;r[o]=e[s]}return r}const II=QS({scrapeMotionValuesFromProps:XS,createRenderState:GS}),DI=Symbol.for("motionComponentSymbol");function LI(e,t,n){const r=h.useRef(n);h.useInsertionEffect(()=>{r.current=n});const s=h.useRef(null);return h.useCallback(o=>{var l;o&&((l=e.onMount)==null||l.call(e,o)),t&&(o?t.mount(o):t.unmount());const a=r.current;if(typeof a=="function")if(o){const c=a(o);typeof c=="function"&&(s.current=c)}else s.current?(s.current(),s.current=null):a(o);else a&&(a.current=o)},[t])}const Fp=e=>e.replace(/([a-z])([A-Z])/gu,"$1-$2").toLowerCase(),_I="framerAppearId",JS="data-"+Fp(_I),ZS=h.createContext({});function $i(e){return e&&typeof e=="object"&&Object.prototype.hasOwnProperty.call(e,"current")}function FI(e,t,n,r,s,o){var y,w;const{visualElement:a}=h.useContext(wu),l=h.useContext(zS),c=h.useContext(vu),u=h.useContext(Rp).reducedMotion,d=h.useRef(null);r=r||l.renderer,!d.current&&r&&(d.current=r(e,{visualState:t,parent:a,props:n,presenceContext:c,blockInitialAnimation:c?c.initial===!1:!1,reducedMotionConfig:u,isSVG:o}));const f=d.current,m=h.useContext(ZS);f&&!f.projection&&s&&(f.type==="html"||f.type==="svg")&&VI(d.current,n,s,m);const p=h.useRef(!1);h.useInsertionEffect(()=>{f&&p.current&&f.update(n,c)});const b=n[JS],x=h.useRef(!!b&&!((y=window.MotionHandoffIsComplete)!=null&&y.call(window,b))&&((w=window.MotionHasOptimisedAnimation)==null?void 0:w.call(window,b)));return G1(()=>{f&&(p.current=!0,window.MotionIsMounted=!0,f.updateFeatures(),f.scheduleRenderMicrotask(),x.current&&f.animationState&&f.animationState.animateChanges())}),h.useEffect(()=>{f&&(!x.current&&f.animationState&&f.animationState.animateChanges(),x.current&&(queueMicrotask(()=>{var g;(g=window.MotionHandoffMarkAsComplete)==null||g.call(window,b)}),x.current=!1),f.enteringChildren=void 0)}),f}function VI(e,t,n,r){const{layoutId:s,layout:o,drag:a,dragConstraints:l,layoutScroll:c,layoutRoot:u,layoutCrossfade:d}=t;e.projection=new n(e.latestValues,t["data-framer-portal-id"]?void 0:ej(e.parent)),e.projection.setOptions({layoutId:s,layout:o,alwaysMeasureLayout:!!a||l&&$i(l),visualElement:e,animationType:typeof o=="string"?o:"both",initialPromotionConfig:r,crossfade:d,layoutScroll:c,layoutRoot:u})}function ej(e){if(e)return e.options.allowProjection!==!1?e.projection:ej(e.parent)}function Rd(e,{forwardMotionProps:t=!1,type:n}={},r,s){r&&dI(r);const o=n?n==="svg":Dp(e),a=o?II:OI;function l(u,d){let f;const m={...h.useContext(Rp),...u,layoutId:$I(u)},{isStatic:p}=m,b=gI(u),x=a(u,p);if(!p&&cp){BI();const y=zI(m);f=y.MeasureLayout,b.visualElement=FI(e,x,m,s,y.ProjectionNode,o)}return i.jsxs(wu.Provider,{value:b,children:[f&&b.visualElement?i.jsx(f,{visualElement:b.visualElement,...m}):null,RI(e,u,LI(x,b.visualElement,d),x,p,t,o)]})}l.displayName=`motion.${typeof e=="string"?e:`create(${e.displayName??e.name??""})`}`;const c=h.forwardRef(l);return c[DI]=e,c}function $I({layoutId:e}){const t=h.useContext(ap).id;return t&&e!==void 0?t+"-"+e:e}function BI(e,t){h.useContext(zS).strict}function zI(e){const{drag:t,layout:n}=ni;if(!t&&!n)return{};const r={...t,...n};return{MeasureLayout:t!=null&&t.isEnabled(e)||n!=null&&n.isEnabled(e)?r.MeasureLayout:void 0,ProjectionNode:r.ProjectionNode}}
vendor: 35,413 bytes, line 336
336function UI(e,t){if(typeof Proxy>"u")return Rd;const n=new Map,r=(o,a)=>Rd(o,a,e,t),s=(o,a)=>r(o,a);return new Proxy(s,{get:(o,a)=>a==="create"?r:(n.has(a)||n.set(a,Rd(a,void 0,e,t)),n.get(a))})}function tj({top:e,left:t,right:n,bottom:r}){return{x:{min:t,max:n},y:{min:e,max:r}}}function WI({x:e,y:t}){return{top:t.min,right:e.max,bottom:t.max,left:e.min}}function HI(e,t){if(!t)return e;const n=t({x:e.left,y:e.top}),r=t({x:e.right,y:e.bottom});return{top:n.y,left:n.x,bottom:r.y,right:r.x}}function Ad(e){return e===void 0||e===1}function kh({scale:e,scaleX:t,scaleY:n}){return!Ad(e)||!Ad(t)||!Ad(n)}function ys(e){return kh(e)||nj(e)||e.z||e.rotate||e.rotateX||e.rotateY||e.skewX||e.skewY}function nj(e){return by(e.x)||by(e.y)}function by(e){return e&&e!=="0%"}function Fc(e,t,n){const r=e-n,s=t*r;return n+s}function Sy(e,t,n,r,s){return s!==void 0&&(e=Fc(e,s,r)),Fc(e,n,r)+t}function Ph(e,t=0,n=1,r,s){e.min=Sy(e.min,t,n,r,s),e.max=Sy(e.max,t,n,r,s)}function rj(e,{x:t,y:n}){Ph(e.x,t.translate,t.scale,t.originPoint),Ph(e.y,n.translate,n.scale,n.originPoint)}const jy=.999999999999,Ny=1.0000000000001;function KI(e,t,n,r=!1){const s=n.length;if(!s)return;t.x=t.y=1;let o,a;for(let l=0;l<s;l++){o=n[l],a=o.projectionDelta;const{visualElement:c}=o.options;c&&c.props.style&&c.props.style.display==="contents"||(r&&o.options.layoutScroll&&o.scroll&&o!==o.root&&vo(e,{x:-o.scroll.offset.x,y:-o.scroll.offset.y}),a&&(t.x*=a.x.scale,t.y*=a.y.scale,rj(e,a)),r&&ys(o.latestValues)&&vo(e,o.latestValues))}t.x<Ny&&t.x>jy&&(t.x=1),t.y<Ny&&t.y>jy&&(t.y=1)}function yo(e,t){e.min=e.min+t,e.max=e.max+t}function Cy(e,t,n,r,s=.5){const o=Me(e.min,e.max,s);Ph(e,t,n,o,r)}function vo(e,t){Cy(e.x,t.x,t.scaleX,t.scale,t.originX),Cy(e.y,t.y,t.scaleY,t.scale,t.originY)}function sj(e,t){return tj(HI(e.getBoundingClientRect(),t))}function YI(e,t,n){const r=sj(e,n),{scroll:s}=t;return s&&(yo(r.x,s.offset.x),yo(r.y,s.offset.y)),r}const ky=()=>({translate:0,scale:1,origin:0,originPoint:0}),wo=()=>({x:ky(),y:ky()}),Py=()=>({min:0,max:0}),We=()=>({x:Py(),y:Py()}),Eh={current:null},oj={current:!1};function GI(){if(oj.current=!0,!!cp)if(window.matchMedia){const e=window.matchMedia("(prefers-reduced-motion)"),t=()=>Eh.current=e.matches;e.addEventListener("change",t),t()}else Eh.current=!1}const qI=new WeakMap;function QI(e,t,n){for(const r in t){const s=t[r],o=n[r];if(ct(s))e.addValue(r,s);else if(ct(o))e.addValue(r,ei(s,{owner:e}));else if(o!==s)if(e.hasValue(r)){const a=e.getValue(r);a.liveStyle===!0?a.jump(s):a.hasAnimated||a.set(s)}else{const a=e.getStaticValue(r);e.addValue(r,ei(a!==void 0?a:s,{owner:e}))}}for(const r in n)t[r]===void 0&&e.removeValue(r);return t}const Ey=["AnimationStart","AnimationComplete","Update","BeforeLayoutMeasure","LayoutMeasure","LayoutAnimationStart","LayoutAnimationComplete"];class XI{scrapeMotionValuesFromProps(t,n,r){return{}}constructor({parent:t,props:n,presenceContext:r,reducedMotionConfig:s,blockInitialAnimation:o,visualState:a},l={}){this.current=null,this.children=new Set,this.isVariantNode=!1,this.isControllingVariants=!1,this.shouldReduceMotion=null,this.values=new Map,this.KeyframeResolver=Cp,this.features={},this.valueSubscriptions=new Map,this.prevMotionValues={},this.events={},this.propEventSubscriptions={},this.notifyUpdate=()=>this.notify("Update",this.latestValues),this.render=()=>{this.current&&(this.triggerBuild(),this.renderInstance(this.current,this.renderState,this.props.style,this.projection))},this.renderScheduledAt=0,this.scheduleRender=()=>{const m=gt.now();this.renderScheduledAt<m&&(this.renderScheduledAt=m,Pe.render(this.render,!1,!0))};const{latestValues:c,renderState:u}=a;this.latestValues=c,this.baseTarget={...c},this.initialValues=n.initial?{...c}:{},this.renderState=u,this.parent=t,this.props=n,this.presenceContext=r,this.depth=t?t.depth+1:0,this.reducedMotionConfig=s,this.options=l,this.blockInitialAnimation=!!o,this.isControllingVariants=Su(n),this.isVariantNode=WS(n),this.isVariantNode&&(this.variantChildren=new Set),this.manuallyAnimateOnMount=!!(t&&t.current);const{willChange:d,...f}=this.scrapeMotionValuesFromProps(n,{},this);for(const m in f){const p=f[m];c[m]!==void 0&&ct(p)&&p.set(c[m])}}mount(t){var n;this.current=t,qI.set(t,this),this.projection&&!this.projection.instance&&this.projection.mount(t),this.parent&&this.isVariantNode&&!this.isControllingVariants&&(this.removeFromVariantTree=this.parent.addVariantChild(this)),this.values.forEach((r,s)=>this.bindToMotionValue(s,r)),this.reducedMotionConfig==="never"?this.shouldReduceMotion=!1:this.reducedMotionConfig==="always"?this.shouldReduceMotion=!0:(oj.current||GI(),this.shouldReduceMotion=Eh.current),(n=this.parent)==null||n.addChild(this),this.update(this.props,this.presenceContext)}unmount(){var t;this.projection&&this.projection.unmount(),os(this.notifyUpdate),os(this.render),this.valueSubscriptions.forEach(n=>n()),this.valueSubscriptions.clear(),this.removeFromVariantTree&&this.removeFromVariantTree(),(t=this.parent)==null||t.removeChild(this);for(const n in this.events)this.events[n].clear();for(const n in this.features){const r=this.features[n];r&&(r.unmount(),r.isMounted=!1)}this.current=null}addChild(t){this.children.add(t),this.enteringChildren??(this.enteringChildren=new Set),this.enteringChildren.add(t)}removeChild(t){this.children.delete(t),this.enteringChildren&&this.enteringChildren.delete(t)}bindToMotionValue(t,n){this.valueSubscriptions.has(t)&&this.valueSubscriptions.get(t)();const r=pi.has(t);r&&this.onBindTransform&&this.onBindTransform();const s=n.on("change",a=>{this.latestValues[t]=a,this.props.onUpdate&&Pe.preRender(this.notifyUpdate),r&&this.projection&&(this.projection.isTransformDirty=!0),this.scheduleRender()});let o;window.MotionCheckAppearSync&&(o=window.MotionCheckAppearSync(this,t,n)),this.valueSubscriptions.set(t,()=>{s(),o&&o(),n.owner&&n.stop()})}sortNodePosition(t){return!this.current||!this.sortInstanceNodePosition||this.type!==t.type?0:this.sortInstanceNodePosition(this.current,t.current)}updateFeatures(){let t="animation";for(t in ni){const n=ni[t];if(!n)continue;const{isEnabled:r,Feature:s}=n;if(!this.features[t]&&s&&r(this.props)&&(this.features[t]=new s(this)),this.features[t]){const o=this.features[t];o.isMounted?o.update():(o.mount(),o.isMounted=!0)}}}triggerBuild(){this.build(this.renderState,this.latestValues,this.props)}measureViewportBox(){return this.current?this.measureInstanceViewportBox(this.current,this.props):We()}getStaticValue(t){return this.latestValues[t]}setStaticValue(t,n){this.latestValues[t]=n}update(t,n){(t.transformTemplate||this.props.transformTemplate)&&this.scheduleRender(),this.prevProps=this.props,this.props=t,this.prevPresenceContext=this.presenceContext,this.presenceContext=n;for(let r=0;r<Ey.length;r++){const s=Ey[r];this.propEventSubscriptions[s]&&(this.propEventSubscriptions[s](),delete this.propEventSubscriptions[s]);const o="on"+s,a=t[o];a&&(this.propEventSubscriptions[s]=this.on(s,a))}this.prevMotionValues=QI(this,this.scrapeMotionValuesFromProps(t,this.prevProps,this),this.prevMotionValues),this.handleChildMotionValue&&this.handleChildMotionValue()}getProps(){return this.props}getVariant(t){return this.props.variants?this.props.variants[t]:void 0}getDefaultTransition(){return this.props.transition}getTransformPagePoint(){return this.props.transformPagePoint}getClosestVariantNode(){return this.isVariantNode?this:this.parent?this.parent.getClosestVariantNode():void 0}addVariantChild(t){const n=this.getClosestVariantNode();if(n)return n.variantChildren&&n.variantChildren.add(t),()=>n.variantChildren.delete(t)}addValue(t,n){const r=this.values.get(t);n!==r&&(r&&this.removeValue(t),this.bindToMotionValue(t,n),this.values.set(t,n),this.latestValues[t]=n.get())}removeValue(t){this.values.delete(t);const n=this.valueSubscriptions.get(t);n&&(n(),this.valueSubscriptions.delete(t)),delete this.latestValues[t],this.removeValueFromRenderState(t,this.renderState)}hasValue(t){return this.values.has(t)}getValue(t,n){if(this.props.values&&this.props.values[t])return this.props.values[t];let r=this.values.get(t);return r===void 0&&n!==void 0&&(r=ei(n===null?void 0:n,{owner:this}),this.addValue(t,r)),r}readValue(t,n){let r=this.latestValues[t]!==void 0||!this.current?this.latestValues[t]:this.getBaseTargetFromProps(this.props,t)??this.readValueFromInstance(this.current,t,this.options);return r!=null&&(typeof r=="string"&&(q1(r)||X1(r))?r=parseFloat(r):!sI(r)&&is.test(n)&&(r=OS(t,n)),this.setBaseTarget(t,ct(r)?r.get():r)),ct(r)?r.get():r}setBaseTarget(t,n){this.baseTarget[t]=n}getBaseTarget(t){var o;const{initial:n}=this.props;let r;if(typeof n=="string"||typeof n=="object"){const a=Lp(this.props,n,(o=this.presenceContext)==null?void 0:o.custom);a&&(r=a[t])}if(n&&r!==void 0)return r;const s=this.getBaseTargetFromProps(this.props,t);return s!==void 0&&!ct(s)?s:this.initialValues[t]!==void 0&&r===void 0?void 0:this.baseTarget[t]}on(t,n){return this.events[t]||(this.events[t]=new mp),this.events[t].add(n)}notify(t,...n){this.events[t]&&this.events[t].notify(...n)}scheduleRenderMicrotask(){Ep.render(this.render)}}class ij extends XI{constructor(){super(...arguments),this.KeyframeResolver=YO}sortInstanceNodePosition(t,n){return t.compareDocumentPosition(n)&2?1:-1}getBaseTargetFromProps(t,n){return t.style?t.style[n]:void 0}removeValueFromRenderState(t,{vars:n,style:r}){delete n[t],delete r[t]}handleChildMotionValue(){this.childSubscription&&(this.childSubscription(),delete this.childSubscription);const{children:t}=this.props;ct(t)&&(this.childSubscription=t.on("change",n=>{this.current&&(this.current.textContent=`${n}`)}))}}function aj(e,{style:t,vars:n},r,s){const o=e.style;let a;for(a in t)o[a]=t[a];s==null||s.applyProjectionStyles(o,r);for(a in n)o.setProperty(a,n[a])}function JI(e){return window.getComputedStyle(e)}class ZI extends ij{constructor(){super(...arguments),this.type="html",this.renderInstance=aj}readValueFromInstance(t,n){var r;if(pi.has(n))return(r=this.projection)!=null&&r.isProjecting?yh(n):fO(t,n);{const s=JI(t),o=(dS(n)?s.getPropertyValue(n):s[n])||0;return typeof o=="string"?o.trim():o}}measureInstanceViewportBox(t,{transformPagePoint:n}){return sj(t,n)}build(t,n,r){Op(t,n,r.transformTemplate)}scrapeMotionValuesFromProps(t,n,r){return _p(t,n,r)}}const lj=new Set(["baseFrequency","diffuseConstant","kernelMatrix","kernelUnitLength","keySplines","keyTimes","limitingConeAngle","markerHeight","markerWidth","numOctaves","targetX","targetY","surfaceScale","specularConstant","specularExponent","stdDeviation","tableValues","viewBox","gradientTransform","pathLength","startOffset","textLength","lengthAdjust"]);function eD(e,t,n,r){aj(e,t,void 0,r);for(const s in t.attrs)e.setAttribute(lj.has(s)?s:Fp(s),t.attrs[s])}class tD extends ij{constructor(){super(...arguments),this.type="svg",this.isSVGTag=!1,this.measureInstanceViewportBox=We}getBaseTargetFromProps(t,n){return t[n]}readValueFromInstance(t,n){if(pi.has(n)){const r=MS(n);return r&&r.default||0}return n=lj.has(n)?n:Fp(n),t.getAttribute(n)}scrapeMotionValuesFromProps(t,n,r){return XS(t,n,r)}build(t,n,r){YS(t,n,this.isSVGTag,r.transformTemplate,r.style)}renderInstance(t,n,r,s){eD(t,n,r,s)}mount(t){this.isSVGTag=qS(t.tagName),super.mount(t)}}const nD=(e,t)=>t.isSVG??Dp(e)?new tD(t):new ZI(t,{allowProjection:e!==h.Fragment});function Ao(e,t,n){const r=e.getProps();return Lp(r,t,n!==void 0?n:r.custom,e)}const Th=e=>Array.isArray(e);function rD(e,t,n){e.hasValue(t)?e.getValue(t).set(n):e.addValue(t,ei(n))}function sD(e){return Th(e)?e[e.length-1]||0:e}function oD(e,t){const n=Ao(e,t);let{transitionEnd:r={},transition:s={},...o}=n||{};o={...o,...r};for(const a in o){const l=sD(o[a]);rD(e,a,l)}}function iD(e){return!!(ct(e)&&e.add)}function Rh(e,t){const n=e.getValue("willChange");if(iD(n))return n.add(t);if(!n&&ur.WillChange){const r=new ur.WillChange("auto");e.addValue("willChange",r),r.add(t)}}function cj(e){return e.props[JS]}const aD=e=>e!==null;function lD(e,{repeat:t,repeatType:n="loop"},r){const s=e.filter(aD),o=t&&n!=="loop"&&t%2===1?0:s.length-1;return s[o]}const cD={type:"spring",stiffness:500,damping:25,restSpeed:10},uD=e=>({type:"spring",stiffness:550,damping:e===0?2*Math.sqrt(550):30,restSpeed:10}),dD={type:"keyframes",duration:.8},fD={type:"keyframes",ease:[.25,.1,.35,1],duration:.3},hD=(e,{keyframes:t})=>t.length>2?dD:pi.has(e)?e.startsWith("scale")?uD(t[1]):cD:fD;function mD({when:e,delay:t,delayChildren:n,staggerChildren:r,staggerDirection:s,repeat:o,repeatType:a,repeatDelay:l,from:c,elapsed:u,...d}){return!!Object.keys(d).length}const Vp=(e,t,n,r={},s,o)=>a=>{const l=kp(r,e)||{},c=l.delay||r.delay||0;let{elapsed:u=0}=r;u=u-nr(c);const d={keyframes:Array.isArray(n)?n:[null,n],ease:"easeOut",velocity:t.getVelocity(),...l,delay:-u,onUpdate:m=>{t.set(m),l.onUpdate&&l.onUpdate(m)},onComplete:()=>{a(),l.onComplete&&l.onComplete()},name:e,motionValue:t,element:o?void 0:s};mD(l)||Object.assign(d,hD(e,d)),d.duration&&(d.duration=nr(d.duration)),d.repeatDelay&&(d.repeatDelay=nr(d.repeatDelay)),d.from!==void 0&&(d.keyframes[0]=d.from);let f=!1;if((d.type===!1||d.duration===0&&!d.repeatDelay)&&(jh(d),d.delay===0&&(f=!0)),(ur.instantAnimations||ur.skipAnimations)&&(f=!0,jh(d),d.delay=0),d.allowFlatten=!l.type&&!l.ease,f&&!o&&t.get()!==void 0){const m=lD(d.keyframes,l);if(m!==void 0){Pe.update(()=>{d.onUpdate(m),d.onComplete()});return}}return l.isSync?new Np(d):new DO(d)};function pD({protectedKeys:e,needsAnimating:t},n){const r=e.hasOwnProperty(n)&&t[n]!==!0;return t[n]=!1,r}function uj(e,t,{delay:n=0,transitionOverride:r,type:s}={}){let{transition:o=e.getDefaultTransition(),transitionEnd:a,...l}=t;r&&(o=r);const c=[],u=s&&e.animationState&&e.animationState.getState()[s];for(const d in l){const f=e.getValue(d,e.latestValues[d]??null),m=l[d];if(m===void 0||u&&pD(u,d))continue;const p={delay:n,...kp(o||{},d)},b=f.get();if(b!==void 0&&!f.isAnimating&&!Array.isArray(m)&&m===b&&!p.velocity)continue;let x=!1;if(window.MotionHandoffAnimation){const w=cj(e);if(w){const g=window.MotionHandoffAnimation(w,d,Pe);g!==null&&(p.startTime=g,x=!0)}}Rh(e,d),f.start(Vp(d,f,m,e.shouldReduceMotion&&TS.has(d)?{type:!1}:p,e,x));const y=f.animation;y&&c.push(y)}return a&&Promise.all(c).then(()=>{Pe.update(()=>{a&&oD(e,a)})}),c}function dj(e,t,n,r=0,s=1){const o=Array.from(e).sort((u,d)=>u.sortNodePosition(d)).indexOf(t),a=e.size,l=(a-1)*r;return typeof n=="function"?n(o,a):s===1?o*r:l-o*r}function Ah(e,t,n={}){var c;const r=Ao(e,t,n.type==="exit"?(c=e.presenceContext)==null?void 0:c.custom:void 0);let{transition:s=e.getDefaultTransition()||{}}=r||{};n.transitionOverride&&(s=n.transitionOverride);const o=r?()=>Promise.all(uj(e,r,n)):()=>Promise.resolve(),a=e.variantChildren&&e.variantChildren.size?(u=0)=>{const{delayChildren:d=0,staggerChildren:f,staggerDirection:m}=s;return gD(e,t,u,d,f,m,n)}:()=>Promise.resolve(),{when:l}=s;if(l){const[u,d]=l==="beforeChildren"?[o,a]:[a,o];return u().then(()=>d())}else return Promise.all([o(),a(n.delay)])}function gD(e,t,n=0,r=0,s=0,o=1,a){const l=[];for(const c of e.variantChildren)c.notify("AnimationStart",t),l.push(Ah(c,t,{...a,delay:n+(typeof r=="function"?0:r)+dj(e.variantChildren,c,r,s,o)}).then(()=>c.notify("AnimationComplete",t)));return Promise.all(l)}function xD(e,t,n={}){e.notify("AnimationStart",t);let r;if(Array.isArray(t)){const s=t.map(o=>Ah(e,o,n));r=Promise.all(s)}else if(typeof t=="string")r=Ah(e,t,n);else{const s=typeof t=="function"?Ao(e,t,n.custom):t;r=Promise.all(uj(e,s,n))}return r.then(()=>{e.notify("AnimationComplete",t)})}function fj(e,t){if(!Array.isArray(t))return!1;const n=t.length;if(n!==e.length)return!1;for(let r=0;r<n;r++)if(t[r]!==e[r])return!1;return!0}const yD=Mp.length;function hj(e){if(!e)return;if(!e.isControllingVariants){const n=e.parent?hj(e.parent)||{}:{};return e.props.initial!==void 0&&(n.initial=e.props.initial),n}const t={};for(let n=0;n<yD;n++){const r=Mp[n],s=e.props[r];(Aa(s)||s===!1)&&(t[r]=s)}return t}const vD=[...Ap].reverse(),wD=Ap.length;function bD(e){return t=>Promise.all(t.map(({animation:n,options:r})=>xD(e,n,r)))}function SD(e){let t=bD(e),n=Ty(),r=!0;const s=c=>(u,d)=>{var m;const f=Ao(e,d,c==="exit"?(m=e.presenceContext)==null?void 0:m.custom:void 0);if(f){const{transition:p,transitionEnd:b,...x}=f;u={...u,...x,...b}}return u};function o(c){t=c(e)}function a(c){const{props:u}=e,d=hj(e.parent)||{},f=[],m=new Set;let p={},b=1/0;for(let y=0;y<wD;y++){const w=vD[y],g=n[w],v=u[w]!==void 0?u[w]:d[w],S=Aa(v),j=w===c?g.isActive:null;j===!1&&(b=y);let C=v===d[w]&&v!==u[w]&&S;if(C&&r&&e.manuallyAnimateOnMount&&(C=!1),g.protectedKeys={...p},!g.isActive&&j===null||!v&&!g.prevProp||bu(v)||typeof v=="boolean")continue;const P=jD(g.prevProp,v);let N=P||w===c&&g.isActive&&!C&&S||y>b&&S,E=!1;const k=Array.isArray(v)?v:[v];let R=k.reduce(s(w),{});j===!1&&(R={});const{prevResolvedValues:M={}}=g,I={...M,...R},O=U=>{N=!0,m.has(U)&&(E=!0,m.delete(U)),g.needsAnimating[U]=!0;const T=e.getValue(U);T&&(T.liveStyle=!1)};for(const U in I){const T=R[U],A=M[U];if(p.hasOwnProperty(U))continue;let L=!1;Th(T)&&Th(A)?L=!fj(T,A):L=T!==A,L?T!=null?O(U):m.add(U):T!==void 0&&m.has(U)?O(U):g.protectedKeys[U]=!0}g.prevProp=v,g.prevResolvedValues=R,g.isActive&&(p={...p,...R}),r&&e.blockInitialAnimation&&(N=!1);const H=C&&P;N&&(!H||E)&&f.push(...k.map(U=>{const T={type:w};if(typeof U=="string"&&r&&!H&&e.manuallyAnimateOnMount&&e.parent){const{parent:A}=e,L=Ao(A,U);if(A.enteringChildren&&L){const{delayChildren:_}=L.transition||{};T.delay=dj(A.enteringChildren,e,_)}}return{animation:U,options:T}}))}if(m.size){const y={};if(typeof u.initial!="boolean"){const w=Ao(e,Array.isArray(u.initial)?u.initial[0]:u.initial);w&&w.transition&&(y.transition=w.transition)}m.forEach(w=>{const g=e.getBaseTarget(w),v=e.getValue(w);v&&(v.liveStyle=!0),y[w]=g??null}),f.push({animation:y})}let x=!!f.length;return r&&(u.initial===!1||u.initial===u.animate)&&!e.manuallyAnimateOnMount&&(x=!1),r=!1,x?t(f):Promise.resolve()}function l(c,u){var f;if(n[c].isActive===u)return Promise.resolve();(f=e.variantChildren)==null||f.forEach(m=>{var p;return(p=m.animationState)==null?void 0:p.setActive(c,u)}),n[c].isActive=u;const d=a(c);for(const m in n)n[m].protectedKeys={};return d}return{animateChanges:a,setActive:l,setAnimateFunction:o,getState:()=>n,reset:()=>{n=Ty()}}}function jD(e,t){return typeof t=="string"?t!==e:Array.isArray(t)?!fj(t,e):!1}function ps(e=!1){return{isActive:e,protectedKeys:{},needsAnimating:{},prevResolvedValues:{}}}function Ty(){return{animate:ps(!0),whileInView:ps(),whileHover:ps(),whileTap:ps(),whileDrag:ps(),whileFocus:ps(),exit:ps()}}class ds{constructor(t){this.isMounted=!1,this.node=t}update(){}}class ND extends ds{constructor(t){super(t),t.animationState||(t.animationState=SD(t))}updateAnimationControlsSubscription(){const{animate:t}=this.node.getProps();bu(t)&&(this.unmountControls=t.subscribe(this.node))}mount(){this.updateAnimationControlsSubscription()}update(){const{animate:t}=this.node.getProps(),{animate:n}=this.node.prevProps||{};t!==n&&this.updateAnimationControlsSubscription()}unmount(){var t;this.node.animationState.reset(),(t=this.unmountControls)==null||t.call(this)}}let CD=0;class kD extends ds{constructor(){super(...arguments),this.id=CD++}update(){if(!this.node.presenceContext)return;const{isPresent:t,onExitComplete:n}=this.node.presenceContext,{isPresent:r}=this.node.prevPresenceContext||{};if(!this.node.animationState||t===r)return;const s=this.node.animationState.setActive("exit",!t);n&&!t&&s.then(()=>{n(this.id)})}mount(){const{register:t,onExitComplete:n}=this.node.presenceContext||{};n&&n(this.id),t&&(this.unmount=t(this.id))}unmount(){}}const PD={animation:{Feature:ND},exit:{Feature:kD}};function Ma(e,t,n,r={passive:!0}){return e.addEventListener(t,n,r),()=>e.removeEventListener(t,n)}function Ga(e){return{point:{x:e.pageX,y:e.pageY}}}const ED=e=>t=>Tp(t)&&e(t,Ga(t));function na(e,t,n,r){return Ma(e,t,ED(n),r)}const mj=1e-4,TD=1-mj,RD=1+mj,pj=.01,AD=0-pj,MD=0+pj;function xt(e){return e.max-e.min}function OD(e,t,n){return Math.abs(e-t)<=n}function Ry(e,t,n,r=.5){e.origin=r,e.originPoint=Me(t.min,t.max,e.origin),e.scale=xt(n)/xt(t),e.translate=Me(n.min,n.max,e.origin)-e.originPoint,(e.scale>=TD&&e.scale<=RD||isNaN(e.scale))&&(e.scale=1),(e.translate>=AD&&e.translate<=MD||isNaN(e.translate))&&(e.translate=0)}function ra(e,t,n,r){Ry(e.x,t.x,n.x,r?r.originX:void 0),Ry(e.y,t.y,n.y,r?r.originY:void 0)}function Ay(e,t,n){e.min=n.min+t.min,e.max=e.min+xt(t)}function ID(e,t,n){Ay(e.x,t.x,n.x),Ay(e.y,t.y,n.y)}function My(e,t,n){e.min=t.min-n.min,e.max=e.min+xt(t)}function Vc(e,t,n){My(e.x,t.x,n.x),My(e.y,t.y,n.y)}function Bt(e){return[e("x"),e("y")]}const gj=({current:e})=>e?e.ownerDocument.defaultView:null,Oy=(e,t)=>Math.abs(e-t);function DD(e,t){const n=Oy(e.x,t.x),r=Oy(e.y,t.y);return Math.sqrt(n**2+r**2)}const Iy=new Set(["auto","scroll"]);class xj{constructor(t,n,{transformPagePoint:r,contextWindow:s=window,dragSnapToOrigin:o=!1,distanceThreshold:a=3,element:l}={}){if(this.startEvent=null,this.lastMoveEvent=null,this.lastMoveEventInfo=null,this.handlers={},this.contextWindow=window,this.scrollPositions=new Map,this.removeScrollListeners=null,this.onElementScroll=p=>{this.handleScroll(p.target)},this.onWindowScroll=()=>{this.handleScroll(window)},this.updatePoint=()=>{if(!(this.lastMoveEvent&&this.lastMoveEventInfo))return;const p=Od(this.lastMoveEventInfo,this.history),b=this.startEvent!==null,x=DD(p.offset,{x:0,y:0})>=this.distanceThreshold;if(!b&&!x)return;const{point:y}=p,{timestamp:w}=et;this.history.push({...y,timestamp:w});const{onStart:g,onMove:v}=this.handlers;b||(g&&g(this.lastMoveEvent,p),this.startEvent=this.lastMoveEvent),v&&v(this.lastMoveEvent,p)},this.handlePointerMove=(p,b)=>{this.lastMoveEvent=p,this.lastMoveEventInfo=Md(b,this.transformPagePoint),Pe.update(this.updatePoint,!0)},this.handlePointerUp=(p,b)=>{this.end();const{onEnd:x,onSessionEnd:y,resumeAnimation:w}=this.handlers;if((this.dragSnapToOrigin||!this.startEvent)&&w&&w(),!(this.lastMoveEvent&&this.lastMoveEventInfo))return;const g=Od(p.type==="pointercancel"?this.lastMoveEventInfo:Md(b,this.transformPagePoint),this.history);this.startEvent&&x&&x(p,g),y&&y(p,g)},!Tp(t))return;this.dragSnapToOrigin=o,this.handlers=n,this.transformPagePoint=r,this.distanceThreshold=a,this.contextWindow=s||window;const c=Ga(t),u=Md(c,this.transformPagePoint),{point:d}=u,{timestamp:f}=et;this.history=[{...d,timestamp:f}];const{onSessionStart:m}=n;m&&m(t,Od(u,this.history)),this.removeListeners=Ha(na(this.contextWindow,"pointermove",this.handlePointerMove),na(this.contextWindow,"pointerup",this.handlePointerUp),na(this.contextWindow,"pointercancel",this.handlePointerUp)),l&&this.startScrollTracking(l)}startScrollTracking(t){let n=t.parentElement;for(;n;){const r=getComputedStyle(n);(Iy.has(r.overflowX)||Iy.has(r.overflowY))&&this.scrollPositions.set(n,{x:n.scrollLeft,y:n.scrollTop}),n=n.parentElement}this.scrollPositions.set(window,{x:window.scrollX,y:window.scrollY}),window.addEventListener("scroll",this.onElementScroll,{capture:!0,passive:!0}),window.addEventListener("scroll",this.onWindowScroll,{passive:!0}),this.removeScrollListeners=()=>{window.removeEventListener("scroll",this.onElementScroll,{capture:!0}),window.removeEventListener("scroll",this.onWindowScroll)}}handleScroll(t){const n=this.scrollPositions.get(t);if(!n)return;const r=t===window,s=r?{x:window.scrollX,y:window.scrollY}:{x:t.scrollLeft,y:t.scrollTop},o={x:s.x-n.x,y:s.y-n.y};o.x===0&&o.y===0||(r?this.lastMoveEventInfo&&(this.lastMoveEventInfo.point.x+=o.x,this.lastMoveEventInfo.point.y+=o.y):this.history.length>0&&(this.history[0].x-=o.x,this.history[0].y-=o.y),this.scrollPositions.set(t,s),Pe.update(this.updatePoint,!0))}updateHandlers(t){this.handlers=t}end(){this.removeListeners&&this.removeListeners(),this.removeScrollListeners&&this.removeScrollListeners(),this.scrollPositions.clear(),os(this.updatePoint)}}function Md(e,t){return t?{point:t(e.point)}:e}function Dy(e,t){return{x:e.x-t.x,y:e.y-t.y}}function Od({point:e},t){return{point:e,delta:Dy(e,yj(t)),offset:Dy(e,LD(t)),velocity:_D(t,.1)}}function LD(e){return e[0]}function yj(e){return e[e.length-1]}function _D(e,t){if(e.length<2)return{x:0,y:0};let n=e.length-1,r=null;const s=yj(e);for(;n>=0&&(r=e[n],!(s.timestamp-r.timestamp>nr(t)));)n--;if(!r)return{x:0,y:0};const o=Kt(s.timestamp-r.timestamp);if(o===0)return{x:0,y:0};const a={x:(s.x-r.x)/o,y:(s.y-r.y)/o};return a.x===1/0&&(a.x=0),a.y===1/0&&(a.y=0),a}function FD(e,{min:t,max:n},r){return t!==void 0&&e<t?e=r?Me(t,e,r.min):Math.max(e,t):n!==void 0&&e>n&&(e=r?Me(n,e,r.max):Math.min(e,n)),e}function Ly(e,t,n){return{min:t!==void 0?e.min+t:void 0,max:n!==void 0?e.max+n-(e.max-e.min):void 0}}function VD(e,{top:t,left:n,bottom:r,right:s}){return{x:Ly(e.x,n,s),y:Ly(e.y,t,r)}}function _y(e,t){let n=t.min-e.min,r=t.max-e.max;return t.max-t.min<e.max-e.min&&([n,r]=[r,n]),{min:n,max:r}}function $D(e,t){return{x:_y(e.x,t.x),y:_y(e.y,t.y)}}function BD(e,t){let n=.5;const r=xt(e),s=xt(t);return s>r?n=Ea(t.min,t.max-r,e.min):r>s&&(n=Ea(e.min,e.max-s,t.min)),zn(0,1,n)}function zD(e,t){const n={};return t.min!==void 0&&(n.min=t.min-e.min),t.max!==void 0&&(n.max=t.max-e.min),n}const Mh=.35;function UD(e=Mh){return e===!1?e=0:e===!0&&(e=Mh),{x:Fy(e,"left","right"),y:Fy(e,"top","bottom")}}function Fy(e,t,n){return{min:Vy(e,t),max:Vy(e,n)}}function Vy(e,t){return typeof e=="number"?e:e[t]||0}const WD=new WeakMap;class HD{constructor(t){this.openDragLock=null,this.isDragging=!1,this.currentDirection=null,this.originPoint={x:0,y:0},this.constraints=!1,this.hasMutatedConstraints=!1,this.elastic=We(),this.latestPointerEvent=null,this.latestPanInfo=null,this.visualElement=t}start(t,{snapToCursor:n=!1,distanceThreshold:r}={}){const{presenceContext:s}=this.visualElement;if(s&&s.isPresent===!1)return;const o=f=>{n?(this.stopAnimation(),this.snapToCursor(Ga(f).point)):this.pauseAnimation()},a=(f,m)=>{this.stopAnimation();const{drag:p,dragPropagation:b,onDragStart:x}=this.getProps();if(p&&!b&&(this.openDragLock&&this.openDragLock(),this.openDragLock=XO(p),!this.openDragLock))return;this.latestPointerEvent=f,this.latestPanInfo=m,this.isDragging=!0,this.currentDirection=null,this.resolveConstraints(),this.visualElement.projection&&(this.visualElement.projection.isAnimationBlocked=!0,this.visualElement.projection.target=void 0),Bt(w=>{let g=this.getAxisMotionValue(w).get()||0;if($n.test(g)){const{projection:v}=this.visualElement;if(v&&v.layout){const S=v.layout.layoutBox[w];S&&(g=xt(S)*(parseFloat(g)/100))}}this.originPoint[w]=g}),x&&Pe.postRender(()=>x(f,m)),Rh(this.visualElement,"transform");const{animationState:y}=this.visualElement;y&&y.setActive("whileDrag",!0)},l=(f,m)=>{this.latestPointerEvent=f,this.latestPanInfo=m;const{dragPropagation:p,dragDirectionLock:b,onDirectionLock:x,onDrag:y}=this.getProps();if(!p&&!this.openDragLock)return;const{offset:w}=m;if(b&&this.currentDirection===null){this.currentDirection=KD(w),this.currentDirection!==null&&x&&x(this.currentDirection);return}this.updateAxis("x",m.point,w),this.updateAxis("y",m.point,w),this.visualElement.render(),y&&y(f,m)},c=(f,m)=>{this.latestPointerEvent=f,this.latestPanInfo=m,this.stop(f,m),this.latestPointerEvent=null,this.latestPanInfo=null},u=()=>Bt(f=>{var m;return this.getAnimationState(f)==="paused"&&((m=this.getAxisMotionValue(f).animation)==null?void 0:m.play())}),{dragSnapToOrigin:d}=this.getProps();this.panSession=new xj(t,{onSessionStart:o,onStart:a,onMove:l,onSessionEnd:c,resumeAnimation:u},{transformPagePoint:this.visualElement.getTransformPagePoint(),dragSnapToOrigin:d,distanceThreshold:r,contextWindow:gj(this.visualElement),element:this.visualElement.current})}stop(t,n){const r=t||this.latestPointerEvent,s=n||this.latestPanInfo,o=this.isDragging;if(this.cancel(),!o||!s||!r)return;const{velocity:a}=s;this.startAnimation(a);const{onDragEnd:l}=this.getProps();l&&Pe.postRender(()=>l(r,s))}cancel(){this.isDragging=!1;const{projection:t,animationState:n}=this.visualElement;t&&(t.isAnimationBlocked=!1),this.panSession&&this.panSession.end(),this.panSession=void 0;const{dragPropagation:r}=this.getProps();!r&&this.openDragLock&&(this.openDragLock(),this.openDragLock=null),n&&n.setActive("whileDrag",!1)}updateAxis(t,n,r){const{drag:s}=this.getProps();if(!r||!Sl(t,s,this.currentDirection))return;const o=this.getAxisMotionValue(t);let a=this.originPoint[t]+r[t];this.constraints&&this.constraints[t]&&(a=FD(a,this.constraints[t],this.elastic[t])),o.set(a)}resolveConstraints(){var o;const{dragConstraints:t,dragElastic:n}=this.getProps(),r=this.visualElement.projection&&!this.visualElement.projection.layout?this.visualElement.projection.measure(!1):(o=this.visualElement.projection)==null?void 0:o.layout,s=this.constraints;t&&$i(t)?this.constraints||(this.constraints=this.resolveRefConstraints()):t&&r?this.constraints=VD(r.layoutBox,t):this.constraints=!1,this.elastic=UD(n),s!==this.constraints&&r&&this.constraints&&!this.hasMutatedConstraints&&Bt(a=>{this.constraints!==!1&&this.getAxisMotionValue(a)&&(this.constraints[a]=zD(r.layoutBox[a],this.constraints[a]))})}resolveRefConstraints(){const{dragConstraints:t,onMeasureDragConstraints:n}=this.getProps();if(!t||!$i(t))return!1;const r=t.current,{projection:s}=this.visualElement;if(!s||!s.layout)return!1;const o=YI(r,s.root,this.visualElement.getTransformPagePoint());let a=$D(s.layout.layoutBox,o);if(n){const l=n(WI(a));this.hasMutatedConstraints=!!l,l&&(a=tj(l))}return a}startAnimation(t){const{drag:n,dragMomentum:r,dragElastic:s,dragTransition:o,dragSnapToOrigin:a,onDragTransitionEnd:l}=this.getProps(),c=this.constraints||{},u=Bt(d=>{if(!Sl(d,n,this.currentDirection))return;let f=c&&c[d]||{};a&&(f={min:0,max:0});const m=s?200:1e6,p=s?40:1e7,b={type:"inertia",velocity:r?t[d]:0,bounceStiffness:m,bounceDamping:p,timeConstant:750,restDelta:1,restSpeed:10,...o,...f};return this.startAxisValueAnimation(d,b)});return Promise.all(u).then(l)}startAxisValueAnimation(t,n){const r=this.getAxisMotionValue(t);return Rh(this.visualElement,t),r.start(Vp(t,r,0,n,this.visualElement,!1))}stopAnimation(){Bt(t=>this.getAxisMotionValue(t).stop())}pauseAnimation(){Bt(t=>{var n;return(n=this.getAxisMotionValue(t).animation)==null?void 0:n.pause()})}getAnimationState(t){var n;return(n=this.getAxisMotionValue(t).animation)==null?void 0:n.state}getAxisMotionValue(t){const n=`_drag${t.toUpperCase()}`,r=this.visualElement.getProps(),s=r[n];return s||this.visualElement.getValue(t,(r.initial?r.initial[t]:void 0)||0)}snapToCursor(t){Bt(n=>{const{drag:r}=this.getProps();if(!Sl(n,r,this.currentDirection))return;const{projection:s}=this.visualElement,o=this.getAxisMotionValue(n);if(s&&s.layout){const{min:a,max:l}=s.layout.layoutBox[n],c=o.get()||0;o.set(t[n]-Me(a,l,.5)+c)}})}scalePositionWithinConstraints(){if(!this.visualElement.current)return;const{drag:t,dragConstraints:n}=this.getProps(),{projection:r}=this.visualElement;if(!$i(n)||!r||!this.constraints)return;this.stopAnimation();const s={x:0,y:0};Bt(a=>{const l=this.getAxisMotionValue(a);if(l&&this.constraints!==!1){const c=l.get();s[a]=BD({min:c,max:c},this.constraints[a])}});const{transformTemplate:o}=this.visualElement.getProps();this.visualElement.current.style.transform=o?o({},""):"none",r.root&&r.root.updateScroll(),r.updateLayout(),this.resolveConstraints(),Bt(a=>{if(!Sl(a,t,null))return;const l=this.getAxisMotionValue(a),{min:c,max:u}=this.constraints[a];l.set(Me(c,u,s[a]))})}addListeners(){if(!this.visualElement.current)return;WD.set(this.visualElement,this);const t=this.visualElement.current,n=na(t,"pointerdown",c=>{const{drag:u,dragListener:d=!0}=this.getProps();u&&d&&!VS(c.target)&&this.start(c)}),r=()=>{const{dragConstraints:c}=this.getProps();$i(c)&&c.current&&(this.constraints=this.resolveRefConstraints())},{projection:s}=this.visualElement,o=s.addEventListener("measure",r);s&&!s.layout&&(s.root&&s.root.updateScroll(),s.updateLayout()),Pe.read(r);const a=Ma(window,"resize",()=>this.scalePositionWithinConstraints()),l=s.addEventListener("didUpdate",({delta:c,hasLayoutChanged:u})=>{this.isDragging&&u&&(Bt(d=>{const f=this.getAxisMotionValue(d);f&&(this.originPoint[d]+=c[d].translate,f.set(f.get()+c[d].translate))}),this.visualElement.render())});return()=>{a(),n(),o(),l&&l()}}getProps(){const t=this.visualElement.getProps(),{drag:n=!1,dragDirectionLock:r=!1,dragPropagation:s=!1,dragConstraints:o=!1,dragElastic:a=Mh,dragMomentum:l=!0}=t;return{...t,drag:n,dragDirectionLock:r,dragPropagation:s,dragConstraints:o,dragElastic:a,dragMomentum:l}}}function Sl(e,t,n){return(t===!0||t===e)&&(n===null||n===e)}function KD(e,t=10){let n=null;return Math.abs(e.y)>t?n="y":Math.abs(e.x)>t&&(n="x"),n}class YD extends ds{constructor(t){super(t),this.removeGroupControls=Gt,this.removeListeners=Gt,this.controls=new HD(t)}mount(){const{dragControls:t}=this.node.getProps();t&&(this.removeGroupControls=t.subscribe(this.controls)),this.removeListeners=this.controls.addListeners()||Gt}update(){const{dragControls:t}=this.node.getProps(),{dragControls:n}=this.node.prevProps||{};t!==n&&(this.removeGroupControls(),t&&(this.removeGroupControls=t.subscribe(this.controls)))}unmount(){this.removeGroupControls(),this.removeListeners()}}const $y=e=>(t,n)=>{e&&Pe.postRender(()=>e(t,n))};class GD extends ds{constructor(){super(...arguments),this.removePointerDownListener=Gt}onPointerDown(t){this.session=new xj(t,this.createPanHandlers(),{transformPagePoint:this.node.getTransformPagePoint(),contextWindow:gj(this.node)})}createPanHandlers(){const{onPanSessionStart:t,onPanStart:n,onPan:r,onPanEnd:s}=this.node.getProps();return{onSessionStart:$y(t),onStart:$y(n),onMove:r,onEnd:(o,a)=>{delete this.session,s&&Pe.postRender(()=>s(o,a))}}}mount(){this.removePointerDownListener=na(this.node.current,"pointerdown",t=>this.onPointerDown(t))}update(){this.session&&this.session.updateHandlers(this.createPanHandlers())}unmount(){this.removePointerDownListener(),this.session&&this.session.end()}}const ql={hasAnimatedSinceResize:!0,hasEverUpdated:!1};let Id=!1;class qD extends h.Component{componentDidMount(){const{visualElement:t,layoutGroup:n,switchLayoutGroup:r,layoutId:s}=this.props,{projection:o}=t;o&&(n.group&&n.group.add(o),r&&r.register&&s&&r.register(o),Id&&o.root.didUpdate(),o.addEventListener("animationComplete",()=>{this.safeToRemove()}),o.setOptions({...o.options,onExitComplete:()=>this.safeToRemove()})),ql.hasEverUpdated=!0}getSnapshotBeforeUpdate(t){const{layoutDependency:n,visualElement:r,drag:s,isPresent:o}=this.props,{projection:a}=r;return a&&(a.isPresent=o,Id=!0,s||t.layoutDependency!==n||n===void 0||t.isPresent!==o?a.willUpdate():this.safeToRemove(),t.isPresent!==o&&(o?a.promote():a.relegate()||Pe.postRender(()=>{const l=a.getStack();(!l||!l.members.length)&&this.safeToRemove()}))),null}componentDidUpdate(){const{projection:t}=this.props.visualElement;t&&(t.root.didUpdate(),Ep.postRender(()=>{!t.currentAnimation&&t.isLead()&&this.safeToRemove()}))}componentWillUnmount(){const{visualElement:t,layoutGroup:n,switchLayoutGroup:r}=this.props,{projection:s}=t;Id=!0,s&&(s.scheduleCheckAfterUnmount(),n&&n.group&&n.group.remove(s),r&&r.deregister&&r.deregister(s))}safeToRemove(){const{safeToRemove:t}=this.props;t&&t()}render(){return null}}function vj(e){const[t,n]=BS(),r=h.useContext(ap);return i.jsx(qD,{...e,layoutGroup:r,switchLayoutGroup:h.useContext(ZS),isPresent:t,safeToRemove:n})}
vendor: 3,564 bytes, line 336
336function QD(e,t,n){const r=ct(e)?e:ei(e);return r.start(Vp("",r,t,n)),r.animation}const XD=(e,t)=>e.depth-t.depth;class JD{constructor(){this.children=[],this.isDirty=!1}add(t){up(this.children,t),this.isDirty=!0}remove(t){dp(this.children,t),this.isDirty=!0}forEach(t){this.isDirty&&this.children.sort(XD),this.isDirty=!1,this.children.forEach(t)}}function ZD(e,t){const n=gt.now(),r=({timestamp:s})=>{const o=s-n;o>=t&&(os(r),e(o-t))};return Pe.setup(r,!0),()=>os(r)}const wj=["TopLeft","TopRight","BottomLeft","BottomRight"],eL=wj.length,By=e=>typeof e=="string"?parseFloat(e):e,zy=e=>typeof e=="number"||G.test(e);function tL(e,t,n,r,s,o){s?(e.opacity=Me(0,n.opacity??1,nL(r)),e.opacityExit=Me(t.opacity??1,0,rL(r))):o&&(e.opacity=Me(t.opacity??1,n.opacity??1,r));for(let a=0;a<eL;a++){const l=`border${wj[a]}Radius`;let c=Uy(t,l),u=Uy(n,l);if(c===void 0&&u===void 0)continue;c||(c=0),u||(u=0),c===0||u===0||zy(c)===zy(u)?(e[l]=Math.max(Me(By(c),By(u),r),0),($n.test(u)||$n.test(c))&&(e[l]+="%")):e[l]=u}(t.rotate||n.rotate)&&(e.rotate=Me(t.rotate||0,n.rotate||0,r))}function Uy(e,t){return e[t]!==void 0?e[t]:e.borderRadius}const nL=bj(0,.5,oS),rL=bj(.5,.95,Gt);function bj(e,t,n){return r=>r<e?0:r>t?1:n(Ea(e,t,r))}function Wy(e,t){e.min=t.min,e.max=t.max}function an(e,t){Wy(e.x,t.x),Wy(e.y,t.y)}function Hy(e,t){e.translate=t.translate,e.scale=t.scale,e.originPoint=t.originPoint,e.origin=t.origin}function Ky(e,t,n,r,s){return e-=t,e=Fc(e,1/n,r),s!==void 0&&(e=Fc(e,1/s,r)),e}function sL(e,t=0,n=1,r=.5,s,o=e,a=e){if($n.test(t)&&(t=parseFloat(t),t=Me(a.min,a.max,t/100)-a.min),typeof t!="number")return;let l=Me(o.min,o.max,r);e===o&&(l-=t),e.min=Ky(e.min,t,n,l,s),e.max=Ky(e.max,t,n,l,s)}function Yy(e,t,[n,r,s],o,a){sL(e,t[n],t[r],t[s],t.scale,o,a)}const oL=["x","scaleX","originX"],iL=["y","scaleY","originY"];function Gy(e,t,n,r){Yy(e.x,t,oL,n?n.x:void 0,r?r.x:void 0),Yy(e.y,t,iL,n?n.y:void 0,r?r.y:void 0)}function qy(e){return e.translate===0&&e.scale===1}function Sj(e){return qy(e.x)&&qy(e.y)}function Qy(e,t){return e.min===t.min&&e.max===t.max}function aL(e,t){return Qy(e.x,t.x)&&Qy(e.y,t.y)}function Xy(e,t){return Math.round(e.min)===Math.round(t.min)&&Math.round(e.max)===Math.round(t.max)}function jj(e,t){return Xy(e.x,t.x)&&Xy(e.y,t.y)}function Jy(e){return xt(e.x)/xt(e.y)}function Zy(e,t){return e.translate===t.translate&&e.scale===t.scale&&e.originPoint===t.originPoint}class lL{constructor(){this.members=[]}add(t){up(this.members,t),t.scheduleRender()}remove(t){if(dp(this.members,t),t===this.prevLead&&(this.prevLead=void 0),t===this.lead){const n=this.members[this.members.length-1];n&&this.promote(n)}}relegate(t){const n=this.members.findIndex(s=>t===s);if(n===0)return!1;let r;for(let s=n;s>=0;s--){const o=this.members[s];if(o.isPresent!==!1){r=o;break}}return r?(this.promote(r),!0):!1}promote(t,n){const r=this.lead;if(t!==r&&(this.prevLead=r,this.lead=t,t.show(),r)){r.instance&&r.scheduleRender(),t.scheduleRender(),t.resumeFrom=r,n&&(t.resumeFrom.preserveOpacity=!0),r.snapshot&&(t.snapshot=r.snapshot,t.snapshot.latestValues=r.animationValues||r.latestValues),t.root&&t.root.isUpdating&&(t.isLayoutDirty=!0);const{crossfade:s}=t.options;s===!1&&r.hide()}}exitAnimationComplete(){this.members.forEach(t=>{const{options:n,resumingFrom:r}=t;n.onExitComplete&&n.onExitComplete(),r&&r.options.onExitComplete&&r.options.onExitComplete()})}scheduleRender(){this.members.forEach(t=>{t.instance&&t.scheduleRender(!1)})}removeLeadSnapshot(){this.lead&&this.lead.snapshot&&(this.lead.snapshot=void 0)}}function cL(e,t,n){let r="";
vendor: 16,621 bytes, line 336
336const s=e.x.translate/t.x,o=e.y.translate/t.y,a=(n==null?void 0:n.z)||0;if((s||o||a)&&(r=`translate3d(${s}px, ${o}px, ${a}px) `),(t.x!==1||t.y!==1)&&(r+=`scale(${1/t.x}, ${1/t.y}) `),n){const{transformPerspective:u,rotate:d,rotateX:f,rotateY:m,skewX:p,skewY:b}=n;u&&(r=`perspective(${u}px) ${r}`),d&&(r+=`rotate(${d}deg) `),f&&(r+=`rotateX(${f}deg) `),m&&(r+=`rotateY(${m}deg) `),p&&(r+=`skewX(${p}deg) `),b&&(r+=`skewY(${b}deg) `)}const l=e.x.scale*t.x,c=e.y.scale*t.y;return(l!==1||c!==1)&&(r+=`scale(${l}, ${c})`),r||"none"}const Dd=["","X","Y","Z"],uL=1e3;let dL=0;function Ld(e,t,n,r){const{latestValues:s}=t;s[e]&&(n[e]=s[e],t.setStaticValue(e,0),r&&(r[e]=0))}function Nj(e){if(e.hasCheckedOptimisedAppear=!0,e.root===e)return;const{visualElement:t}=e.options;if(!t)return;const n=cj(t);if(window.MotionHasOptimisedAnimation(n,"transform")){const{layout:s,layoutId:o}=e.options;window.MotionCancelOptimisedAnimation(n,"transform",Pe,!(s||o))}const{parent:r}=e;r&&!r.hasCheckedOptimisedAppear&&Nj(r)}function Cj({attachResizeListener:e,defaultParent:t,measureScroll:n,checkIsScrollRoot:r,resetTransform:s}){return class{constructor(a={},l=t==null?void 0:t()){this.id=dL++,this.animationId=0,this.animationCommitId=0,this.children=new Set,this.options={},this.isTreeAnimating=!1,this.isAnimationBlocked=!1,this.isLayoutDirty=!1,this.isProjectionDirty=!1,this.isSharedProjectionDirty=!1,this.isTransformDirty=!1,this.updateManuallyBlocked=!1,this.updateBlockedByResize=!1,this.isUpdating=!1,this.isSVG=!1,this.needsReset=!1,this.shouldResetTransform=!1,this.hasCheckedOptimisedAppear=!1,this.treeScale={x:1,y:1},this.eventHandlers=new Map,this.hasTreeAnimated=!1,this.layoutVersion=0,this.updateScheduled=!1,this.scheduleUpdate=()=>this.update(),this.projectionUpdateScheduled=!1,this.checkUpdateFailed=()=>{this.isUpdating&&(this.isUpdating=!1,this.clearAllSnapshots())},this.updateProjection=()=>{this.projectionUpdateScheduled=!1,this.nodes.forEach(mL),this.nodes.forEach(yL),this.nodes.forEach(vL),this.nodes.forEach(pL)},this.resolvedRelativeTargetAt=0,this.linkedParentVersion=0,this.hasProjected=!1,this.isVisible=!0,this.animationProgress=0,this.sharedNodes=new Map,this.latestValues=a,this.root=l?l.root||l:this,this.path=l?[...l.path,l]:[],this.parent=l,this.depth=l?l.depth+1:0;for(let c=0;c<this.path.length;c++)this.path[c].shouldResetTransform=!0;this.root===this&&(this.nodes=new JD)}addEventListener(a,l){return this.eventHandlers.has(a)||this.eventHandlers.set(a,new mp),this.eventHandlers.get(a).add(l)}notifyListeners(a,...l){const c=this.eventHandlers.get(a);c&&c.notify(...l)}hasListeners(a){return this.eventHandlers.has(a)}mount(a){if(this.instance)return;this.isSVG=$S(a)&&!nI(a),this.instance=a;const{layoutId:l,layout:c,visualElement:u}=this.options;if(u&&!u.current&&u.mount(a),this.root.nodes.add(this),this.parent&&this.parent.children.add(this),this.root.hasTreeAnimated&&(c||l)&&(this.isLayoutDirty=!0),e){let d,f=0;const m=()=>this.root.updateBlockedByResize=!1;Pe.read(()=>{f=window.innerWidth}),e(a,()=>{const p=window.innerWidth;p!==f&&(f=p,this.root.updateBlockedByResize=!0,d&&d(),d=ZD(m,250),ql.hasAnimatedSinceResize&&(ql.hasAnimatedSinceResize=!1,this.nodes.forEach(nv)))})}l&&this.root.registerSharedNode(l,this),this.options.animate!==!1&&u&&(l||c)&&this.addEventListener("didUpdate",({delta:d,hasLayoutChanged:f,hasRelativeLayoutChanged:m,layout:p})=>{if(this.isTreeAnimationBlocked()){this.target=void 0,this.relativeTarget=void 0;return}const b=this.options.transition||u.getDefaultTransition()||NL,{onLayoutAnimationStart:x,onLayoutAnimationComplete:y}=u.getProps(),w=!this.targetLayout||!jj(this.targetLayout,p),g=!f&&m;if(this.options.layoutRoot||this.resumeFrom||g||f&&(w||!this.currentAnimation)){this.resumeFrom&&(this.resumingFrom=this.resumeFrom,this.resumingFrom.resumingFrom=void 0);const v={...kp(b,"layout"),onPlay:x,onComplete:y};(u.shouldReduceMotion||this.options.layoutRoot)&&(v.delay=0,v.type=!1),this.startAnimation(v),this.setAnimationOrigin(d,g)}else f||nv(this),this.isLead()&&this.options.onExitComplete&&this.options.onExitComplete();this.targetLayout=p})}unmount(){this.options.layoutId&&this.willUpdate(),this.root.nodes.remove(this);const a=this.getStack();a&&a.remove(this),this.parent&&this.parent.children.delete(this),this.instance=void 0,this.eventHandlers.clear(),os(this.updateProjection)}blockUpdate(){this.updateManuallyBlocked=!0}unblockUpdate(){this.updateManuallyBlocked=!1}isUpdateBlocked(){return this.updateManuallyBlocked||this.updateBlockedByResize}isTreeAnimationBlocked(){return this.isAnimationBlocked||this.parent&&this.parent.isTreeAnimationBlocked()||!1}startUpdate(){this.isUpdateBlocked()||(this.isUpdating=!0,this.nodes&&this.nodes.forEach(wL),this.animationId++)}getTransformTemplate(){const{visualElement:a}=this.options;return a&&a.getProps().transformTemplate}willUpdate(a=!0){if(this.root.hasTreeAnimated=!0,this.root.isUpdateBlocked()){this.options.onExitComplete&&this.options.onExitComplete();return}if(window.MotionCancelOptimisedAnimation&&!this.hasCheckedOptimisedAppear&&Nj(this),!this.root.isUpdating&&this.root.startUpdate(),this.isLayoutDirty)return;this.isLayoutDirty=!0;for(let d=0;d<this.path.length;d++){const f=this.path[d];f.shouldResetTransform=!0,f.updateScroll("snapshot"),f.options.layoutRoot&&f.willUpdate(!1)}const{layoutId:l,layout:c}=this.options;if(l===void 0&&!c)return;const u=this.getTransformTemplate();this.prevTransformTemplateValue=u?u(this.latestValues,""):void 0,this.updateSnapshot(),a&&this.notifyListeners("willUpdate")}update(){if(this.updateScheduled=!1,this.isUpdateBlocked()){this.unblockUpdate(),this.clearAllSnapshots(),this.nodes.forEach(ev);return}if(this.animationId<=this.animationCommitId){this.nodes.forEach(tv);return}this.animationCommitId=this.animationId,this.isUpdating?(this.isUpdating=!1,this.nodes.forEach(xL),this.nodes.forEach(fL),this.nodes.forEach(hL)):this.nodes.forEach(tv),this.clearAllSnapshots();const l=gt.now();et.delta=zn(0,1e3/60,l-et.timestamp),et.timestamp=l,et.isProcessing=!0,jd.update.process(et),jd.preRender.process(et),jd.render.process(et),et.isProcessing=!1}didUpdate(){this.updateScheduled||(this.updateScheduled=!0,Ep.read(this.scheduleUpdate))}clearAllSnapshots(){this.nodes.forEach(gL),this.sharedNodes.forEach(bL)}scheduleUpdateProjection(){this.projectionUpdateScheduled||(this.projectionUpdateScheduled=!0,Pe.preRender(this.updateProjection,!1,!0))}scheduleCheckAfterUnmount(){Pe.postRender(()=>{this.isLayoutDirty?this.root.didUpdate():this.root.checkUpdateFailed()})}updateSnapshot(){this.snapshot||!this.instance||(this.snapshot=this.measure(),this.snapshot&&!xt(this.snapshot.measuredBox.x)&&!xt(this.snapshot.measuredBox.y)&&(this.snapshot=void 0))}updateLayout(){if(!this.instance||(this.updateScroll(),!(this.options.alwaysMeasureLayout&&this.isLead())&&!this.isLayoutDirty))return;if(this.resumeFrom&&!this.resumeFrom.instance)for(let c=0;c<this.path.length;c++)this.path[c].updateScroll();const a=this.layout;this.layout=this.measure(!1),this.layoutVersion++,this.layoutCorrected=We(),this.isLayoutDirty=!1,this.projectionDelta=void 0,this.notifyListeners("measure",this.layout.layoutBox);const{visualElement:l}=this.options;l&&l.notify("LayoutMeasure",this.layout.layoutBox,a?a.layoutBox:void 0)}updateScroll(a="measure"){let l=!!(this.options.layoutScroll&&this.instance);if(this.scroll&&this.scroll.animationId===this.root.animationId&&this.scroll.phase===a&&(l=!1),l&&this.instance){const c=r(this.instance);this.scroll={animationId:this.root.animationId,phase:a,isRoot:c,offset:n(this.instance),wasRoot:this.scroll?this.scroll.isRoot:c}}}resetTransform(){if(!s)return;const a=this.isLayoutDirty||this.shouldResetTransform||this.options.alwaysMeasureLayout,l=this.projectionDelta&&!Sj(this.projectionDelta),c=this.getTransformTemplate(),u=c?c(this.latestValues,""):void 0,d=u!==this.prevTransformTemplateValue;a&&this.instance&&(l||ys(this.latestValues)||d)&&(s(this.instance,u),this.shouldResetTransform=!1,this.scheduleRender())}measure(a=!0){const l=this.measurePageBox();let c=this.removeElementScroll(l);return a&&(c=this.removeTransform(c)),CL(c),{animationId:this.root.animationId,measuredBox:l,layoutBox:c,latestValues:{},source:this.id}}measurePageBox(){var u;const{visualElement:a}=this.options;if(!a)return We();const l=a.measureViewportBox();if(!(((u=this.scroll)==null?void 0:u.wasRoot)||this.path.some(kL))){const{scroll:d}=this.root;d&&(yo(l.x,d.offset.x),yo(l.y,d.offset.y))}return l}removeElementScroll(a){var c;const l=We();if(an(l,a),(c=this.scroll)!=null&&c.wasRoot)return l;for(let u=0;u<this.path.length;u++){const d=this.path[u],{scroll:f,options:m}=d;d!==this.root&&f&&m.layoutScroll&&(f.wasRoot&&an(l,a),yo(l.x,f.offset.x),yo(l.y,f.offset.y))}return l}applyTransform(a,l=!1){const c=We();an(c,a);for(let u=0;u<this.path.length;u++){const d=this.path[u];!l&&d.options.layoutScroll&&d.scroll&&d!==d.root&&vo(c,{x:-d.scroll.offset.x,y:-d.scroll.offset.y}),ys(d.latestValues)&&vo(c,d.latestValues)}return ys(this.latestValues)&&vo(c,this.latestValues),c}removeTransform(a){const l=We();an(l,a);for(let c=0;c<this.path.length;c++){const u=this.path[c];if(!u.instance||!ys(u.latestValues))continue;kh(u.latestValues)&&u.updateSnapshot();const d=We(),f=u.measurePageBox();an(d,f),Gy(l,u.latestValues,u.snapshot?u.snapshot.layoutBox:void 0,d)}return ys(this.latestValues)&&Gy(l,this.latestValues),l}setTargetDelta(a){this.targetDelta=a,this.root.scheduleUpdateProjection(),this.isProjectionDirty=!0}setOptions(a){this.options={...this.options,...a,crossfade:a.crossfade!==void 0?a.crossfade:!0}}clearMeasurements(){this.scroll=void 0,this.layout=void 0,this.snapshot=void 0,this.prevTransformTemplateValue=void 0,this.targetDelta=void 0,this.target=void 0,this.isLayoutDirty=!1}forceRelativeParentToResolveTarget(){this.relativeParent&&this.relativeParent.resolvedRelativeTargetAt!==et.timestamp&&this.relativeParent.resolveTargetDelta(!0)}resolveTargetDelta(a=!1){var p;const l=this.getLead();this.isProjectionDirty||(this.isProjectionDirty=l.isProjectionDirty),this.isTransformDirty||(this.isTransformDirty=l.isTransformDirty),this.isSharedProjectionDirty||(this.isSharedProjectionDirty=l.isSharedProjectionDirty);const c=!!this.resumingFrom||this!==l;if(!(a||c&&this.isSharedProjectionDirty||this.isProjectionDirty||(p=this.parent)!=null&&p.isProjectionDirty||this.attemptToResolveRelativeTarget||this.root.updateBlockedByResize))return;const{layout:d,layoutId:f}=this.options;if(!this.layout||!(d||f))return;this.resolvedRelativeTargetAt=et.timestamp;const m=this.getClosestProjectingParent();m&&this.linkedParentVersion!==m.layoutVersion&&!m.options.layoutRoot&&this.removeRelativeTarget(),!this.targetDelta&&!this.relativeTarget&&(m&&m.layout?this.createRelativeTarget(m,this.layout.layoutBox,m.layout.layoutBox):this.removeRelativeTarget()),!(!this.relativeTarget&&!this.targetDelta)&&(this.target||(this.target=We(),this.targetWithTransforms=We()),this.relativeTarget&&this.relativeTargetOrigin&&this.relativeParent&&this.relativeParent.target?(this.forceRelativeParentToResolveTarget(),ID(this.target,this.relativeTarget,this.relativeParent.target)):this.targetDelta?(this.resumingFrom?this.target=this.applyTransform(this.layout.layoutBox):an(this.target,this.layout.layoutBox),rj(this.target,this.targetDelta)):an(this.target,this.layout.layoutBox),this.attemptToResolveRelativeTarget&&(this.attemptToResolveRelativeTarget=!1,m&&!!m.resumingFrom==!!this.resumingFrom&&!m.options.layoutScroll&&m.target&&this.animationProgress!==1?this.createRelativeTarget(m,this.target,m.target):this.relativeParent=this.relativeTarget=void 0))}getClosestProjectingParent(){if(!(!this.parent||kh(this.parent.latestValues)||nj(this.parent.latestValues)))return this.parent.isProjecting()?this.parent:this.parent.getClosestProjectingParent()}isProjecting(){return!!((this.relativeTarget||this.targetDelta||this.options.layoutRoot)&&this.layout)}createRelativeTarget(a,l,c){this.relativeParent=a,this.linkedParentVersion=a.layoutVersion,this.forceRelativeParentToResolveTarget(),this.relativeTarget=We(),this.relativeTargetOrigin=We(),Vc(this.relativeTargetOrigin,l,c),an(this.relativeTarget,this.relativeTargetOrigin)}removeRelativeTarget(){this.relativeParent=this.relativeTarget=void 0}calcProjection(){var b;const a=this.getLead(),l=!!this.resumingFrom||this!==a;let c=!0;if((this.isProjectionDirty||(b=this.parent)!=null&&b.isProjectionDirty)&&(c=!1),l&&(this.isSharedProjectionDirty||this.isTransformDirty)&&(c=!1),this.resolvedRelativeTargetAt===et.timestamp&&(c=!1),c)return;const{layout:u,layoutId:d}=this.options;if(this.isTreeAnimating=!!(this.parent&&this.parent.isTreeAnimating||this.currentAnimation||this.pendingAnimation),this.isTreeAnimating||(this.targetDelta=this.relativeTarget=void 0),!this.layout||!(u||d))return;an(this.layoutCorrected,this.layout.layoutBox);const f=this.treeScale.x,m=this.treeScale.y;KI(this.layoutCorrected,this.treeScale,this.path,l),a.layout&&!a.target&&(this.treeScale.x!==1||this.treeScale.y!==1)&&(a.target=a.layout.layoutBox,a.targetWithTransforms=We());const{target:p}=a;if(!p){this.prevProjectionDelta&&(this.createProjectionDeltas(),this.scheduleRender());return}!this.projectionDelta||!this.prevProjectionDelta?this.createProjectionDeltas():(Hy(this.prevProjectionDelta.x,this.projectionDelta.x),Hy(this.prevProjectionDelta.y,this.projectionDelta.y)),ra(this.projectionDelta,this.layoutCorrected,p,this.latestValues),(this.treeScale.x!==f||this.treeScale.y!==m||!Zy(this.projectionDelta.x,this.prevProjectionDelta.x)||!Zy(this.projectionDelta.y,this.prevProjectionDelta.y))&&(this.hasProjected=!0,this.scheduleRender(),this.notifyListeners("projectionUpdate",p))}hide(){this.isVisible=!1}show(){this.isVisible=!0}scheduleRender(a=!0){var l;if((l=this.options.visualElement)==null||l.scheduleRender(),a){const c=this.getStack();c&&c.scheduleRender()}this.resumingFrom&&!this.resumingFrom.instance&&(this.resumingFrom=void 0)}createProjectionDeltas(){this.prevProjectionDelta=wo(),this.projectionDelta=wo(),this.projectionDeltaWithTransform=wo()}setAnimationOrigin(a,l=!1){const c=this.snapshot,u=c?c.latestValues:{},d={...this.latestValues},f=wo();(!this.relativeParent||!this.relativeParent.options.layoutRoot)&&(this.relativeTarget=this.relativeTargetOrigin=void 0),this.attemptToResolveRelativeTarget=!l;const m=We(),p=c?c.source:void 0,b=this.layout?this.layout.source:void 0,x=p!==b,y=this.getStack(),w=!y||y.members.length<=1,g=!!(x&&!w&&this.options.crossfade===!0&&!this.path.some(jL));this.animationProgress=0;let v;this.mixTargetDelta=S=>{const j=S/1e3;rv(f.x,a.x,j),rv(f.y,a.y,j),this.setTargetDelta(f),this.relativeTarget&&this.relativeTargetOrigin&&this.layout&&this.relativeParent&&this.relativeParent.layout&&(Vc(m,this.layout.layoutBox,this.relativeParent.layout.layoutBox),SL(this.relativeTarget,this.relativeTargetOrigin,m,j),v&&aL(this.relativeTarget,v)&&(this.isProjectionDirty=!1),v||(v=We()),an(v,this.relativeTarget)),x&&(this.animationValues=d,tL(d,u,this.latestValues,j,g,w)),this.root.scheduleUpdateProjection(),this.scheduleRender(),this.animationProgress=j},this.mixTargetDelta(this.options.layoutRoot?1e3:0)}startAnimation(a){var l,c,u;this.notifyListeners("animationStart"),(l=this.currentAnimation)==null||l.stop(),(u=(c=this.resumingFrom)==null?void 0:c.currentAnimation)==null||u.stop(),this.pendingAnimation&&(os(this.pendingAnimation),this.pendingAnimation=void 0),this.pendingAnimation=Pe.update(()=>{ql.hasAnimatedSinceResize=!0,this.motionValue||(this.motionValue=ei(0)),this.currentAnimation=QD(this.motionValue,[0,1e3],{...a,velocity:0,isSync:!0,onUpdate:d=>{this.mixTargetDelta(d),a.onUpdate&&a.onUpdate(d)},onStop:()=>{},onComplete:()=>{a.onComplete&&a.onComplete(),this.completeAnimation()}}),this.resumingFrom&&(this.resumingFrom.currentAnimation=this.currentAnimation),this.pendingAnimation=void 0})}completeAnimation(){this.resumingFrom&&(this.resumingFrom.currentAnimation=void 0,this.resumingFrom.preserveOpacity=void 0);const a=this.getStack();a&&a.exitAnimationComplete(),this.resumingFrom=this.currentAnimation=this.animationValues=void 0,this.notifyListeners("animationComplete")}finishAnimation(){this.currentAnimation&&(this.mixTargetDelta&&this.mixTargetDelta(uL),this.currentAnimation.stop()),this.completeAnimation()}applyTransformsToTarget(){const a=this.getLead();let{targetWithTransforms:l,target:c,layout:u,latestValues:d}=a;if(!(!l||!c||!u)){if(this!==a&&this.layout&&u&&kj(this.options.animationType,this.layout.layoutBox,u.layoutBox)){c=this.target||We();const f=xt(this.layout.layoutBox.x);
vendor: 9,568 bytes, line 336
336c.x.min=a.target.x.min,c.x.max=c.x.min+f;const m=xt(this.layout.layoutBox.y);c.y.min=a.target.y.min,c.y.max=c.y.min+m}an(l,c),vo(l,d),ra(this.projectionDeltaWithTransform,this.layoutCorrected,l,d)}}registerSharedNode(a,l){this.sharedNodes.has(a)||this.sharedNodes.set(a,new lL),this.sharedNodes.get(a).add(l);const u=l.options.initialPromotionConfig;l.promote({transition:u?u.transition:void 0,preserveFollowOpacity:u&&u.shouldPreserveFollowOpacity?u.shouldPreserveFollowOpacity(l):void 0})}isLead(){const a=this.getStack();return a?a.lead===this:!0}getLead(){var l;const{layoutId:a}=this.options;return a?((l=this.getStack())==null?void 0:l.lead)||this:this}getPrevLead(){var l;const{layoutId:a}=this.options;return a?(l=this.getStack())==null?void 0:l.prevLead:void 0}getStack(){const{layoutId:a}=this.options;if(a)return this.root.sharedNodes.get(a)}promote({needsReset:a,transition:l,preserveFollowOpacity:c}={}){const u=this.getStack();u&&u.promote(this,c),a&&(this.projectionDelta=void 0,this.needsReset=!0),l&&this.setOptions({transition:l})}relegate(){const a=this.getStack();return a?a.relegate(this):!1}resetSkewAndRotation(){const{visualElement:a}=this.options;if(!a)return;let l=!1;const{latestValues:c}=a;if((c.z||c.rotate||c.rotateX||c.rotateY||c.rotateZ||c.skewX||c.skewY)&&(l=!0),!l)return;const u={};c.z&&Ld("z",a,u,this.animationValues);for(let d=0;d<Dd.length;d++)Ld(`rotate${Dd[d]}`,a,u,this.animationValues),Ld(`skew${Dd[d]}`,a,u,this.animationValues);a.render();for(const d in u)a.setStaticValue(d,u[d]),this.animationValues&&(this.animationValues[d]=u[d]);a.scheduleRender()}applyProjectionStyles(a,l){if(!this.instance||this.isSVG)return;if(!this.isVisible){a.visibility="hidden";return}const c=this.getTransformTemplate();if(this.needsReset){this.needsReset=!1,a.visibility="",a.opacity="",a.pointerEvents=Gl(l==null?void 0:l.pointerEvents)||"",a.transform=c?c(this.latestValues,""):"none";return}const u=this.getLead();if(!this.projectionDelta||!this.layout||!u.target){this.options.layoutId&&(a.opacity=this.latestValues.opacity!==void 0?this.latestValues.opacity:1,a.pointerEvents=Gl(l==null?void 0:l.pointerEvents)||""),this.hasProjected&&!ys(this.latestValues)&&(a.transform=c?c({},""):"none",this.hasProjected=!1);return}a.visibility="";const d=u.animationValues||u.latestValues;this.applyTransformsToTarget();let f=cL(this.projectionDeltaWithTransform,this.treeScale,d);c&&(f=c(d,f)),a.transform=f;const{x:m,y:p}=this.projectionDelta;a.transformOrigin=`${m.origin*100}% ${p.origin*100}% 0`,u.animationValues?a.opacity=u===this?d.opacity??this.latestValues.opacity??1:this.preserveOpacity?this.latestValues.opacity:d.opacityExit:a.opacity=u===this?d.opacity!==void 0?d.opacity:"":d.opacityExit!==void 0?d.opacityExit:0;for(const b in Ch){if(d[b]===void 0)continue;const{correct:x,applyTo:y,isCSSVariable:w}=Ch[b],g=f==="none"?d[b]:x(d[b],u);if(y){const v=y.length;for(let S=0;S<v;S++)a[y[S]]=g}else w?this.options.visualElement.renderState.vars[b]=g:a[b]=g}this.options.layoutId&&(a.pointerEvents=u===this?Gl(l==null?void 0:l.pointerEvents)||"":"none")}clearSnapshot(){this.resumeFrom=this.snapshot=void 0}resetTree(){this.root.nodes.forEach(a=>{var l;return(l=a.currentAnimation)==null?void 0:l.stop()}),this.root.nodes.forEach(ev),this.root.sharedNodes.clear()}}}function fL(e){e.updateLayout()}function hL(e){var n;const t=((n=e.resumeFrom)==null?void 0:n.snapshot)||e.snapshot;if(e.isLead()&&e.layout&&t&&e.hasListeners("didUpdate")){const{layoutBox:r,measuredBox:s}=e.layout,{animationType:o}=e.options,a=t.source!==e.layout.source;o==="size"?Bt(f=>{const m=a?t.measuredBox[f]:t.layoutBox[f],p=xt(m);m.min=r[f].min,m.max=m.min+p}):kj(o,t.layoutBox,r)&&Bt(f=>{const m=a?t.measuredBox[f]:t.layoutBox[f],p=xt(r[f]);m.max=m.min+p,e.relativeTarget&&!e.currentAnimation&&(e.isProjectionDirty=!0,e.relativeTarget[f].max=e.relativeTarget[f].min+p)});const l=wo();ra(l,r,t.layoutBox);const c=wo();a?ra(c,e.applyTransform(s,!0),t.measuredBox):ra(c,r,t.layoutBox);const u=!Sj(l);let d=!1;if(!e.resumeFrom){const f=e.getClosestProjectingParent();if(f&&!f.resumeFrom){const{snapshot:m,layout:p}=f;if(m&&p){const b=We();Vc(b,t.layoutBox,m.layoutBox);const x=We();Vc(x,r,p.layoutBox),jj(b,x)||(d=!0),f.options.layoutRoot&&(e.relativeTarget=x,e.relativeTargetOrigin=b,e.relativeParent=f)}}}e.notifyListeners("didUpdate",{layout:r,snapshot:t,delta:c,layoutDelta:l,hasLayoutChanged:u,hasRelativeLayoutChanged:d})}else if(e.isLead()){const{onExitComplete:r}=e.options;r&&r()}e.options.transition=void 0}function mL(e){e.parent&&(e.isProjecting()||(e.isProjectionDirty=e.parent.isProjectionDirty),e.isSharedProjectionDirty||(e.isSharedProjectionDirty=!!(e.isProjectionDirty||e.parent.isProjectionDirty||e.parent.isSharedProjectionDirty)),e.isTransformDirty||(e.isTransformDirty=e.parent.isTransformDirty))}function pL(e){e.isProjectionDirty=e.isSharedProjectionDirty=e.isTransformDirty=!1}function gL(e){e.clearSnapshot()}function ev(e){e.clearMeasurements()}function tv(e){e.isLayoutDirty=!1}function xL(e){const{visualElement:t}=e.options;t&&t.getProps().onBeforeLayoutMeasure&&t.notify("BeforeLayoutMeasure"),e.resetTransform()}function nv(e){e.finishAnimation(),e.targetDelta=e.relativeTarget=e.target=void 0,e.isProjectionDirty=!0}function yL(e){e.resolveTargetDelta()}function vL(e){e.calcProjection()}function wL(e){e.resetSkewAndRotation()}function bL(e){e.removeLeadSnapshot()}function rv(e,t,n){e.translate=Me(t.translate,0,n),e.scale=Me(t.scale,1,n),e.origin=t.origin,e.originPoint=t.originPoint}function sv(e,t,n,r){e.min=Me(t.min,n.min,r),e.max=Me(t.max,n.max,r)}function SL(e,t,n,r){sv(e.x,t.x,n.x,r),sv(e.y,t.y,n.y,r)}function jL(e){return e.animationValues&&e.animationValues.opacityExit!==void 0}const NL={duration:.45,ease:[.4,0,.1,1]},ov=e=>typeof navigator<"u"&&navigator.userAgent&&navigator.userAgent.toLowerCase().includes(e),iv=ov("applewebkit/")&&!ov("chrome/")?Math.round:Gt;function av(e){e.min=iv(e.min),e.max=iv(e.max)}function CL(e){av(e.x),av(e.y)}function kj(e,t,n){return e==="position"||e==="preserve-aspect"&&!OD(Jy(t),Jy(n),.2)}function kL(e){var t;return e!==e.root&&((t=e.scroll)==null?void 0:t.wasRoot)}const PL=Cj({attachResizeListener:(e,t)=>Ma(e,"resize",t),measureScroll:()=>({x:document.documentElement.scrollLeft||document.body.scrollLeft,y:document.documentElement.scrollTop||document.body.scrollTop}),checkIsScrollRoot:()=>!0}),_d={current:void 0},Pj=Cj({measureScroll:e=>({x:e.scrollLeft,y:e.scrollTop}),defaultParent:()=>{if(!_d.current){const e=new PL({});e.mount(window),e.setOptions({layoutScroll:!0}),_d.current=e}return _d.current},resetTransform:(e,t)=>{e.style.transform=t!==void 0?t:"none"},checkIsScrollRoot:e=>window.getComputedStyle(e).position==="fixed"}),EL={pan:{Feature:GD},drag:{Feature:YD,ProjectionNode:Pj,MeasureLayout:vj}};function lv(e,t,n){const{props:r}=e;e.animationState&&r.whileHover&&e.animationState.setActive("whileHover",n==="Start");const s="onHover"+n,o=r[s];o&&Pe.postRender(()=>o(t,Ga(t)))}class TL extends ds{mount(){const{current:t}=this.node;t&&(this.unmount=JO(t,(n,r)=>(lv(this.node,r,"Start"),s=>lv(this.node,s,"End"))))}unmount(){}}class RL extends ds{constructor(){super(...arguments),this.isActive=!1}onFocus(){let t=!1;try{t=this.node.current.matches(":focus-visible")}catch{t=!0}!t||!this.node.animationState||(this.node.animationState.setActive("whileFocus",!0),this.isActive=!0)}onBlur(){!this.isActive||!this.node.animationState||(this.node.animationState.setActive("whileFocus",!1),this.isActive=!1)}mount(){this.unmount=Ha(Ma(this.node.current,"focus",()=>this.onFocus()),Ma(this.node.current,"blur",()=>this.onBlur()))}unmount(){}}function cv(e,t,n){const{props:r}=e;if(e.current instanceof HTMLButtonElement&&e.current.disabled)return;e.animationState&&r.whileTap&&e.animationState.setActive("whileTap",n==="Start");const s="onTap"+(n==="End"?"":n),o=r[s];o&&Pe.postRender(()=>o(t,Ga(t)))}class AL extends ds{mount(){const{current:t}=this.node;t&&(this.unmount=tI(t,(n,r)=>(cv(this.node,r,"Start"),(s,{success:o})=>cv(this.node,s,o?"End":"Cancel")),{useGlobalTarget:this.node.props.globalTapTarget}))}unmount(){}}const Oh=new WeakMap,Fd=new WeakMap,ML=e=>{const t=Oh.get(e.target);t&&t(e)},OL=e=>{e.forEach(ML)};function IL({root:e,...t}){const n=e||document;Fd.has(n)||Fd.set(n,{});const r=Fd.get(n),s=JSON.stringify(t);return r[s]||(r[s]=new IntersectionObserver(OL,{root:e,...t})),r[s]}function DL(e,t,n){const r=IL(t);return Oh.set(e,n),r.observe(e),()=>{Oh.delete(e),r.unobserve(e)}}const LL={some:0,all:1};class _L extends ds{constructor(){super(...arguments),this.hasEnteredView=!1,this.isInView=!1}startObserver(){this.unmount();const{viewport:t={}}=this.node.getProps(),{root:n,margin:r,amount:s="some",once:o}=t,a={root:n?n.current:void 0,rootMargin:r,threshold:typeof s=="number"?s:LL[s]},l=c=>{const{isIntersecting:u}=c;if(this.isInView===u||(this.isInView=u,o&&!u&&this.hasEnteredView))return;u&&(this.hasEnteredView=!0),this.node.animationState&&this.node.animationState.setActive("whileInView",u);const{onViewportEnter:d,onViewportLeave:f}=this.node.getProps(),m=u?d:f;m&&m(c)};return DL(this.node.current,a,l)}mount(){this.startObserver()}update(){if(typeof IntersectionObserver>"u")return;const{props:t,prevProps:n}=this.node;["amount","margin","root"].some(FL(t,n))&&this.startObserver()}unmount(){}}function FL({viewport:e={}},{viewport:t={}}={}){return n=>e[n]!==t[n]}const VL={inView:{Feature:_L},tap:{Feature:AL},focus:{Feature:RL},hover:{Feature:TL}},$L={layout:{ProjectionNode:Pj,MeasureLayout:vj}},BL={...PD,...VL,...EL,...$L}
336,xe=UI(BL,nD),Ej="https://omega.staybolted.dev/api",Vd="omega_user_token",$d="omega_user_refresh_token",gn={getToken:()=>localStorage.getItem(Vd),setToken:e=>localStorage.setItem(Vd,e),getRefreshToken:()=>localStorage.getItem($d),setRefreshToken:e=>localStorage.setItem($d,e),clear:()=>{localStorage.removeItem(Vd),localStorage.removeItem($d)}},zL=1e4;class Tj extends Error{constructor(n,r){super(n);eg(this,"status");this.name="ApiError",this.status=r}}let jl=!1,Bd=[];function UL(){typeof window<"u"&&window.dispatchEvent(new Event("omega:auth-expired"))}async function WL(){const e=gn.getRefreshToken();if(!e)throw new Error("No refresh token");const t=new AbortController,n=setTimeout(()=>t.abort(),zL);let r;try{r=await fetch(`${Ej}/auth/storefront/refresh`,{method:"POST",headers:{"Content-Type":"application/json"},body:JSON.stringify({refreshToken:e}),signal:t.signal})}catch(l){throw l.name==="AbortError"?new Error("Refresh timed out"):l}finally{clearTimeout(n)}if(!r.ok)throw new Error("Session expired");const s=await r.json(),o=s.data??s,a=o.accessToken;if(!a)throw new Error("Refresh did not return an access token");return gn.setToken(a),typeof o.refreshToken=="string"&&gn.setRefreshToken(o.refreshToken),a}async function HL(e,t){try{return await fetch(e,t)}catch{throw new Error("Could not reach the server. It may be offline, or the request failed before a reply came back — check your connection and try again.")}}async function he(e,t={}){const n=gn.getToken(),r=async a=>{const l={"Content-Type":"application/json",...t.headers};return a&&(l.Authorization=`Bearer ${a}`),HL(`${Ej}${e}`,{...t,headers:l})};let s=await r(n);if(s.status===401&&n){let a=null;if(jl){if(a=await new Promise(l=>{Bd.push(l)}),!a)throw new Error("Session expired")}else{jl=!0;try{a=await WL(),Bd.splice(0).forEach(l=>l(a))}catch(l){throw jl=!1,Bd.splice(0).forEach(c=>c(null)),gn.clear(),UL(),l}jl=!1}s=await r(a)}if(!s.ok){const a=await s.json().catch(()=>({message:"Request failed"}));throw new Tj(a.message??`HTTP ${s.status}`,s.status)}if(s.status===204)return;const o=await s.json();return o&&typeof o=="object"&&"data"in o?o.data:o}const Js={register(e){return he("/auth/storefront/register",{method:"POST",body:JSON.stringify(e)})},login(e){return he("/auth/storefront/login",{method:"POST",body:JSON.stringify(e)})},google(e){return he("/auth/storefront/google",{method:"POST",body:JSON.stringify(e)})},logout(){return he("/auth/storefront/logout",{method:"POST"})},requestPhoneOtp(e){return he("/auth/storefront/phone/request-otp",{method:"POST",body:JSON.stringify(e)})},verifyPhoneOtp(e){return he("/auth/storefront/phone/verify",{method:"POST",body:JSON.stringify(e)})}},Cs={me(){return he("/storefront/me")},update(e){return he("/storefront/me",{method:"PATCH",body:JSON.stringify(e)})},myOrders(){return he("/storefront/me/orders?limit=50")},myWallet(){return he("/storefront/me/wallet-transactions")},startDeposit(e){return he("/storefront/me/wallet/deposit",{method:"POST",body:JSON.stringify({amount:e})})},verifyDeposit(e){return he("/storefront/me/wallet/deposit/verify",{method:"POST",body:JSON.stringify({reference:e})})},myPoints(){return he("/storefront/me/points-transactions")}},Rj=h.createContext(void 0);function KL({children:e}){const[t,n]=h.useState(null),[r,s]=h.useState(null),[o,a]=h.useState(!0),l=h.useCallback(async()=>{try{const y=await Cs.me();s(y)}catch{s(null)}},[]);h.useEffect(()=>{let y=!1;return(async()=>{if(!gn.getToken()){y||a(!1);return}try{const g=await Cs.me();y||(s(g),n({id:g.id,email:g.email??"",businessId:"",customerId:g.id}))}catch{y||(gn.clear(),n(null),s(null))}finally{y||a(!1)}})(),()=>{y=!0}},[]),h.useEffect(()=>{const y=()=>{n(null),s(null)};return window.addEventListener("omega:auth-expired",y),()=>window.removeEventListener("omega:auth-expired",y)},[]);const c=h.useCallback(async y=>{gn.setToken(y.accessToken),gn.setRefreshToken(y.refreshToken),n(y.user),await l()},[l]),u=h.useCallback(async y=>{const w=await Js.login(y);await c(w)},[c]),d=h.useCallback(async y=>{const w=await Js.register(y);await c(w)},[c]),f=h.useCallback(async y=>{const w=await Js.google(y);await c(w)},[c]),m=h.useCallback(async y=>{await Js.requestPhoneOtp(y)},[]),p=h.useCallback(async y=>{const w=await Js.verifyPhoneOtp(y);await c(w)},[c]),b=h.useCallback(async()=>{try{await Js.logout()}catch{}gn.clear(),n(null),s(null)},[]),x=h.useMemo(()=>({user:t,profile:r,isLoading:o,isAuthenticated:!!t,login:u,register:d,loginWithGoogle:f,logout:b,refreshProfile:l,requestPhoneOtp:m,loginWithPhoneOtp:p}),[t,r,o,u,d,f,b,l,m,p]);return i.jsx(Rj.Provider,{value:x,children:e})}function Tt(){const e=h.useContext(Rj);if(!e)throw new Error("useAuth must be used within AuthProvider");return e}const Aj="7539e0df-038b-4346-b742-b8f035315a3e";let Ih=Aj;function gi(){return Ih}async function YL(){return Ih=Aj,Ih}const GL="https://omega.staybolted.dev/api";async function Ai(e){const t=e.includes("?")?"&":"?",n=`${GL}${e}${t}businessId=${encodeURIComponent(gi())}`,r=await fetch(n);if(!r.ok){const o=await r.json().catch(()=>({message:"Request failed"}));throw new Error(o.message??`HTTP ${r.status}`)}if(r.status===204)return;const s=await r.json();return s.data??s}const xi={getConfig(){return Ai("/public/storefront/config")},getBanners(){return Ai("/public/storefront/banners")},getPages(){return Ai("/public/storefront/pages")},getPage(e){return Ai(`/public/storefront/pages/${encodeURIComponent(e)}`)},getPaymentMethods(){return Ai("/public/storefront/payment-methods")}},Mj=h.createContext(void 0);function qL({children:e}){const[t,n]=h.useState(null),[r,s]=h.useState(!0),[o,a]=h.useState(null),l=async()=>{s(!0);try{const u=await xi.getConfig();n(u),a(null)}catch(u){a(u.message??"Couldn't load storefront config"),n(null)}finally{s(!1)}};h.useEffect(()=>{l();const u=window.setInterval(()=>void l(),6e4);return()=>window.clearInterval(u)},[]),h.useEffect(()=>{if(!t)return;const u=document.documentElement;if(u.style.setProperty("--sf-primary",t.primaryColor),u.style.setProperty("--sf-secondary",t.secondaryColor),u.style.setProperty("--sf-accent",t.accentColor),u.style.setProperty("--sf-background",t.backgroundColor),u.style.setProperty("--sf-foreground",t.foregroundColor),u.style.setProperty("--sf-font-family",t.fontFamily),t.seoTitle?document.title=t.seoTitle:t.storeName&&(document.title=t.storeName),t.faviconUrl){let d=document.querySelector("link[rel='icon']");d||(d=document.createElement("link"),d.rel="icon",document.head.appendChild(d)),d.href=t.faviconUrl}},[t]);const c=h.useMemo(()=>({config:t,isLoading:r,error:o,refresh:l}),[t,r,o]);return i.jsx(Mj.Provider,{value:c,children:e})}function hr(){const e=h.useContext(Mj);if(!e)throw new Error("useStorefront must be used within a StorefrontProvider");return e}function zs(e,t){let n=e.price,r=0;
336if(t&&e.options)for(const s of e.options){const o=t[s.id];if(!o||o.length===0)continue;const a=s.isVariation||s.id==="variation";for(const l of o){const c=s.choices.find(u=>u.id===l);c!=null&&c.price&&(a?n=c.price:r+=c.price)}}return n+r}function QL(e,t){const n=[];let r;const s=[];if(t&&e.options)for(const o of e.options){const a=t[o.id];if(!a||a.length===0)continue;const l=o.isVariation||o.id==="variation";for(const c of a){const u=o.choices.find(d=>d.id===c);u&&(l?(n.push(u.name),r=r??u.id):s.push({id:u.id,name:u.name,price:u.price??0}))}}return{variation:n.length?{name:n.join(", ")}:void 0,addons:s.length?s:void 0,variationId:r}}const XL="https://omega.staybolted.dev/api",Oj={async forStore(e,t){const n=`${XL}/public/storefront/stores/${encodeURIComponent(e)}/availability?businessId=${encodeURIComponent(gi())}&date=${encodeURIComponent(t)}`,r=await fetch(n);if(!r.ok){const o=await r.json().catch(()=>({message:"Request failed"}));throw new Error(o.message??`HTTP ${r.status}`)}const s=await r.json();return s.data??s}},Ij="omega_cart_v2",Dj=h.createContext(void 0);function JL(){try{const e=localStorage.getItem(Ij);return e?JSON.parse(e):{}}catch{return{}}}const ZL=({children:e})=>{const{isAuthenticated:t}=Tt(),{config:n}=hr(),r=JL(),[s,o]=h.useState(r.items??[]),[a,l]=h.useState(r.orderType??"pickup"),[c,u]=h.useState(r.storeId??null),[d,f]=h.useState(r.selectedAddressId??null),[m,p]=h.useState(r.selectedPaymentMethodId??null),[b,x]=h.useState(r.selectedTime??"ASAP"),[y,w]=h.useState(r.selectedDeliveryRegionId??null);h.useEffect(()=>{if(!c||b!=="ASAP"&&b!=="")return;let I=!1;const O=new Date,H=`${O.getFullYear()}-${String(O.getMonth()+1).padStart(2,"0")}-${String(O.getDate()).padStart(2,"0")}`;return Oj.forStore(c,H).then(B=>{I||(!B.asapAvailable&&b==="ASAP"?x(""):B.asapAvailable&&b===""&&x("ASAP"))}).catch(()=>{}),()=>{I=!0}},[c,b]),h.useEffect(()=>{const I={items:s,orderType:a,storeId:c,selectedAddressId:d,selectedPaymentMethodId:m,selectedTime:b,selectedDeliveryRegionId:y};try{localStorage.setItem(Ij,JSON.stringify(I))}catch{}},[s,a,c,d,m,b,y]);const g=h.useCallback((I,O=1,H,B)=>{o(U=>{const T=U.findIndex(A=>A.menuItem.id===I.id&&JSON.stringify(A.selectedOptions)===JSON.stringify(H));if(T>=0){const A=[...U];return A[T].quantity+=O,A}return[...U,{id:`${I.id}-${Date.now()}`,menuItem:I,quantity:O,selectedOptions:H,specialRequest:B}]})},[]),v=h.useCallback(I=>{o(O=>O.filter(H=>H.id!==I))},[]),S=h.useCallback((I,O)=>{if(O<=0){v(I);return}o(H=>H.map(B=>B.id===I?{...B,quantity:O}:B))},[v]),j=h.useCallback(()=>{o([])},[]),C=s.reduce((I,O)=>I+zs(O.menuItem,O.selectedOptions)*O.quantity,0),P=Number((n==null?void 0:n.taxRate)??.075),N=Number((n==null?void 0:n.pointsPerNaira)??.1),E=Math.round(C*P),k=C+E,R=Math.floor(C*N),M=s.reduce((I,O)=>I+O.quantity,0);return i.jsx(Dj.Provider,{value:{items:s,orderType:a,storeId:c,selectedAddressId:d,selectedPaymentMethodId:m,selectedTime:b,selectedDeliveryRegionId:y,isLoggedIn:t,addItem:g,removeItem:v,updateQuantity:S,clearCart:j,setOrderType:l,setStoreId:u,setSelectedAddressId:f,setSelectedPaymentMethodId:p,setSelectedTime:x,setSelectedDeliveryRegionId:w,subtotal:C,tax:E,total:k,pointsToEarn:R,itemCount:M},children:e})},Nn=()=>{const e=h.useContext(Dj);if(!e)throw new Error("useCart must be used within a CartProvider");return e},Lj=h.createContext(void 0),e3=({children:e})=>{const[t,n]=h.useState(()=>localStorage.getItem("theme")||"light");h.useEffect(()=>{const s=document.documentElement;s.classList.remove("light","dark","theme-red","theme-blue","theme-green"),s.classList.add(t),localStorage.setItem("theme",t)},[t]);const r=()=>{n(s=>s==="light"?"dark":"light")};return i.jsx(Lj.Provider,{value:{theme:t,setTheme:n,toggleTheme:r},children:e})},t3=()=>{const e=h.useContext(Lj);if(e===void 0)throw new Error("useTheme must be used within a ThemeProvider");return e},n3="https://omega.staybolted.dev/api";async function Zs(e){const t=e.includes("?")?"&":"?",n=`${n3}${e}${t}businessId=${encodeURIComponent(gi())}`,r=await fetch(n);if(!r.ok){const o=await r.json().catch(()=>({message:"Request failed"}));throw new Error(o.message??`HTTP ${r.status}`)}if(r.status===204)return;const s=await r.json();return s.data??s}const bo={stores(){return Zs("/public/storefront/stores")},categories(e){return Zs(`/public/storefront/menu/categories?storeId=${encodeURIComponent(e)}`)},products(e,t){const n=new URLSearchParams({storeId:e});return t!=null&&t.categoryId&&n.set("categoryId",t.categoryId),t!=null&&t.search&&n.set("search",t.search),Zs(`/public/storefront/menu/products?${n.toString()}`)},product(e){return Zs(`/public/storefront/menu/products/${encodeURIComponent(e)}`)},combos(e){return Zs(`/public/storefront/menu/combos?storeId=${encodeURIComponent(e)}`)},recommendations(e,t){const n=new URLSearchParams({storeId:e});return t!=null&&t.productId&&n.set("productId",t.productId),t!=null&&t.limit&&n.set("limit",String(t.limit)),Zs(`/public/storefront/recommendations?${n.toString()}`)}},_j=h.createContext(void 0),r3=[{id:"popular",name:"Popular",emoji:"🔥"},{id:"new",name:"New",emoji:"✨"}];function s3(e,t){var r;const n=[];(e.variations??[]).length>0&&n.push({id:"variation",name:"Choose option",required:!0,maxSelections:1,isVariation:!0,choices:e.variations.map(s=>{var o;return{id:s.id,name:s.name,price:Number(((o=s.discount)==null?void 0:o.price)??s.sellingPrice)||(s.priceDelta!=null?Number(e.sellingPrice)+Number(s.priceDelta):void 0)}})});for(const s of e.addonGroups??[]){if(!s.addons||s.addons.length===0)continue;const o=s.minSelection??void 0,a=s.maxSelection??void 0;n.push({id:s.id,name:s.name,required:(o??0)>=1,maxSelections:a,minSelections:o,choices:s.addons.filter(l=>
336l.isAvailable!==!1).map(l=>({id:l.id,name:l.name,price:Number(l.price)||void 0}))})}return{id:e.id,name:e.name,description:e.description??"",price:Number(((r=e.discount)==null?void 0:r.price)??e.sellingPrice??e.price),discount:e.discount?{originalPrice:Number(e.discount.originalPrice),percentOff:e.discount.percentOff??null,label:e.discount.label??null}:null,image:e.imageUrl??"",category:t,options:n.length>0?n:void 0}}function o3(e){return{id:e.id,name:e.name,description:e.description??"",price:Number(e.price),image:e.imageUrl??"",category:"combos",isCombo:!0,comboItems:(e.items??[]).map(t=>{var n,r;return{itemId:t.productId,name:((n=t.product)==null?void 0:n.name)??"Item",originalPrice:Number(((r=t.product)==null?void 0:r.sellingPrice)??0)}})}}function i3({children:e}){const{storeId:t,setStoreId:n}=Nn(),[r,s]=h.useState([]),[o,a]=h.useState([]),[l,c]=h.useState([]),[u,d]=h.useState([]),[f,m]=h.useState(!0),[p,b]=h.useState(null);h.useEffect(()=>{let g=!1;return(async()=>{try{const v=await bo.stores();if(g)return;if(s(v),v.length>0){const S=t&&v.some(j=>j.id===t);(!t||!S)&&n(v[0].id)}else m(!1)}catch(v){g||(b(v.message??"Failed to load stores"),m(!1))}})(),()=>{g=!0}},[]);const x=async()=>{if(t){m(!0);try{const[g,v,S]=await Promise.all([bo.categories(t),bo.products(t),bo.combos(t)]);d(g),a(v),c(S),b(null)}catch(g){b(g.message??"Failed to load menu")}finally{m(!1)}}};h.useEffect(()=>{x()},[t]);const y=h.useMemo(()=>r.find(g=>g.id===t)??null,[r,t]),w=h.useMemo(()=>{const g=(u??[]).map(C=>({id:C.id,name:C.name,emoji:C.emoji||"🍽️"})),v=[{id:"combos",name:"Combos",emoji:"🎁"},...r3,...g],S=o.map(C=>s3(C,C.categoryId??"popular")),j=l.map(o3);return{isLoading:f,error:p,stores:r,store:y,categories:v,menuItems:S,comboItems:j,refresh:x}},[u,o,l,r,y,f,p]);return i.jsx(_j.Provider,{value:w,children:e})}function Kn(){const e=h.useContext(_j);if(!e)throw new Error("useMenu must be used within a MenuProvider");return e}const a3=()=>{const{pathname:e}=Hn();return h.useEffect(()=>{window.scrollTo(0,0)},[e]),null};function l3({children:e}){const{config:t,isLoading:n}=hr();return n?i.jsx(i.Fragment,{children:e}):t&&t.storeStatus!=="live"?i.jsx("div",{className:"min-h-screen flex items-center justify-center bg-background px-4",children:i.jsxs("div",{className:"max-w-md text-center space-y-3",children:[i.jsx("div",{className:"text-5xl",children:t.storeStatus==="maintenance"?"🛠️":"🔒"}),i.jsx("h1",{className:"text-2xl font-semibold",children:t.storeStatus==="maintenance"?"We'll be right back":"Currently offline"}),i.jsx("p",{className:"text-muted-foreground",children:t.maintenanceMessage??(t.storeStatus==="maintenance"?"We're making things better. Please check back soon.":`${t.storeName||"Our store"} is not accepting orders right now.`)})]})}):i.jsx(i.Fragment,{children:e})}const Fj="storefront_preferences",Nl={sound_effects:!0,haptic_feedback:!0,order_tracking:!0,data_saver:!1};function c3(){if(typeof window>"u")return{...Nl};try{const e=window.localStorage.getItem(Fj);if(!e)return{...Nl};const t=JSON.parse(e);return{...Nl,...t}}catch{return{...Nl}}}let ri=c3();const Dh=new Set;function u3(){try{typeof window<"u"&&window.localStorage.setItem(Fj,JSON.stringify(ri))}catch{}
336Dh.forEach(e=>e())}function $p(e){return ri[e]}function d3(e,t){ri={...ri,[e]:t},u3()}function Vj(e){const[t,n]=h.useState(ri[e]);return h.useEffect(()=>{const r=()=>n(ri[e]);return Dh.add(r),()=>{Dh.delete(r)}},[e]),[t,r=>d3(e,r)]}const mr=()=>{const e=h.useCallback((n="light")=>{if(!navigator.vibrate||!$p("haptic_feedback"))return;const r={light:10,medium:25,heavy:50,success:[10,50,30],error:[50,30,50],selection:5};try{navigator.vibrate(r[n])}catch{}},[]);return{triggerHaptic:h.useCallback((n="light")=>{e(n)},[e])}},f3=({onCartClick:e,onWalletClick:t,onSignInClick:n,isLoggedIn:r})=>{const s=Je(),{itemCount:o,subtotal:a}=Nn(),{profile:l}=Tt(),c=(l==null?void 0:l.points)??0,{triggerHaptic:u}=mr(),d=()=>{u("medium"),e()},f=m=>{u("selection"),m()};return i.jsx("div",{className:"fixed bottom-0 inset-x-0 z-40 px-4 pb-6 pt-3 pointer-events-none lg:px-6 safari-fix",children:i.jsx("div",{className:"max-w-lg mx-auto lg:max-w-xl",children:i.jsxs("div",{className:"flex items-center gap-2",children:[i.jsxs("div",{className:"flex items-center gap-1 bg-card rounded-full p-1 border border-border/60 shadow-none pointer-events-auto",children:[i.jsxs(xe.button,{onClick:()=>f(t),className:"relative w-11 h-11 rounded-full flex items-center justify-center hover:bg-secondary transition-colors",whileTap:{scale:.9},transition:{duration:.1},children:[i.jsx(ar,{className:"w-5 h-5"}),c>0&&i.jsx("span",{className:"absolute -top-0.5 -right-0.5 px-1.5 min-w-[18px] h-[18px] rounded-full bg-foreground text-background text-[10px] font-bold flex items-center justify-center",children:c>999?"1k":c})]}),i.jsx(xe.button,{onClick:()=>f(()=>s("/order-history")),className:"w-11 h-11 rounded-full flex items-center justify-center hover:bg-secondary transition-colors",whileTap:{scale:.9},transition:{duration:.1},children:i.jsx(mE,{className:"w-5 h-5"})}),i.jsx(xe.button,{onClick:()=>f(r?()=>s("/profile"):n),className:"w-11 h-11 rounded-full flex items-center justify-center hover:bg-secondary transition-colors",whileTap:{scale:.9},transition:{duration:.1},children:i.jsx(Zf,{className:"w-5 h-5"})})]}),i.jsxs(xe.button,{onClick:d,className:Y("flex-1 h-14 rounded-full font-bold text-base flex items-center justify-between px-6 transition-all shadow-none pointer-events-auto","bg-primary text-primary-foreground hover:bg-primary/90"),whileHover:{scale:1.02},whileTap:{scale:.98},transition:{duration:.1},children:[i.jsxs("div",{className:"flex items-center gap-2",children:[i.jsx(Um,{className:"w-5 h-5"}),i.jsx("span",{children:o>0?`View cart (${o})`:"Start order"})]}),o>0&&i.jsxs("span",{children:["₦",a.toLocaleString()]})]})]})})})};function Xt(e){const t=Object.prototype.toString.call(e);return e instanceof Date||typeof e=="object"&&t==="[object Date]"?new e.constructor(+e):typeof e=="number"||t==="[object Number]"||typeof e=="string"||t==="[object String]"?new Date(e):new Date(NaN)}function dr(e,t){return e instanceof Date?new e.constructor(t):new Date(t)}function $j(e,t){const n=Xt(e);return isNaN(t)?dr(e,NaN):(t&&n.setDate(n.getDate()+t),n)}const Bj=6048e5,h3=864e5;let m3={};function ju(){return m3}function Oa(e,t){var l,c,u,d;const n=ju(),r=(t==null?void 0:t.weekStartsOn)??((c=(l=t==null?void 0:t.locale)==null?void 0:l.options)==null?void 0:c.weekStartsOn)??n.weekStartsOn??((d=(u=n.locale)==null?void 0:u.options)==null?void 0:d.weekStartsOn)??0,s=Xt(e),o=s.getDay(),a=(o<r?7:0)+o-r;return s.setDate(s.getDate()-a),s.setHours(0,0,0,0),s}function $c(e){return Oa(e,{weekStartsOn:1})}function zj(e){const t=Xt(e),n=t.getFullYear(),r=dr(e,0);r.setFullYear(n+1,0,4),r.setHours(0,0,0,0);const s=$c(r),o=dr(e,0);o.setFullYear(n,0,4),o.setHours(0,0,0,0);const a=$c(o);return t.getTime()>=s.getTime()?n+1:t.getTime()>=a.getTime()?n:n-1}function Ia(e){const t=Xt(e);return t.setHours(0,0,0,0),t}function uv(e){const t=Xt(e),n=new Date(Date.UTC(t.getFullYear(),t.getMonth(),t.getDate(),t.getHours(),t.getMinutes(),t.getSeconds(),t.getMilliseconds()));return n.setUTCFullYear(t.getFullYear()),+e-+n}function p3(e,t){const n=Ia(e),r=Ia(t),s=+n-uv(n),o=+r-uv(r);return Math.round((s-o)/h3)}function g3(e){const t=zj(e),n=dr(e,0);return n.setFullYear(t,0,4),n.setHours(0,0,0,0),$c(n)}function Uj(e){return dr(e,Date.now())}function Bp(e,t){const n=Ia(e),r=Ia(t);return+n==+r}function x3(e){return e instanceof Date||typeof e=="object"&&Object.prototype.toString.call(e)==="[object Date]"}
vendor: 16,367 bytes, line 336
336function y3(e){if(!x3(e)&&typeof e!="number")return!1;const t=Xt(e);return!isNaN(Number(t))}function v3(e){const t=Xt(e),n=dr(e,0);return n.setFullYear(t.getFullYear(),0,1),n.setHours(0,0,0,0),n}const w3={lessThanXSeconds:{one:"less than a second",other:"less than {{count}} seconds"},xSeconds:{one:"1 second",other:"{{count}} seconds"},halfAMinute:"half a minute",lessThanXMinutes:{one:"less than a minute",other:"less than {{count}} minutes"},xMinutes:{one:"1 minute",other:"{{count}} minutes"},aboutXHours:{one:"about 1 hour",other:"about {{count}} hours"},xHours:{one:"1 hour",other:"{{count}} hours"},xDays:{one:"1 day",other:"{{count}} days"},aboutXWeeks:{one:"about 1 week",other:"about {{count}} weeks"},xWeeks:{one:"1 week",other:"{{count}} weeks"},aboutXMonths:{one:"about 1 month",other:"about {{count}} months"},xMonths:{one:"1 month",other:"{{count}} months"},aboutXYears:{one:"about 1 year",other:"about {{count}} years"},xYears:{one:"1 year",other:"{{count}} years"},overXYears:{one:"over 1 year",other:"over {{count}} years"},almostXYears:{one:"almost 1 year",other:"almost {{count}} years"}},b3=(e,t,n)=>{let r;const s=w3[e];return typeof s=="string"?r=s:t===1?r=s.one:r=s.other.replace("{{count}}",t.toString()),n!=null&&n.addSuffix?n.comparison&&n.comparison>0?"in "+r:r+" ago":r};function zd(e){return(t={})=>{const n=t.width?String(t.width):e.defaultWidth;return e.formats[n]||e.formats[e.defaultWidth]}}const S3={full:"EEEE, MMMM do, y",long:"MMMM do, y",medium:"MMM d, y",short:"MM/dd/yyyy"},j3={full:"h:mm:ss a zzzz",long:"h:mm:ss a z",medium:"h:mm:ss a",short:"h:mm a"},N3={full:"{{date}} 'at' {{time}}",long:"{{date}} 'at' {{time}}",medium:"{{date}}, {{time}}",short:"{{date}}, {{time}}"},C3={date:zd({formats:S3,defaultWidth:"full"}),time:zd({formats:j3,defaultWidth:"full"}),dateTime:zd({formats:N3,defaultWidth:"full"})},k3={lastWeek:"'last' eeee 'at' p",yesterday:"'yesterday at' p",today:"'today at' p",tomorrow:"'tomorrow at' p",nextWeek:"eeee 'at' p",other:"P"},P3=(e,t,n,r)=>k3[e];function Mi(e){return(t,n)=>{const r=n!=null&&n.context?String(n.context):"standalone";let s;if(r==="formatting"&&e.formattingValues){const a=e.defaultFormattingWidth||e.defaultWidth,l=n!=null&&n.width?String(n.width):a;s=e.formattingValues[l]||e.formattingValues[a]}else{const a=e.defaultWidth,l=n!=null&&n.width?String(n.width):e.defaultWidth;s=e.values[l]||e.values[a]}const o=e.argumentCallback?e.argumentCallback(t):t;return s[o]}}const E3={narrow:["B","A"],abbreviated:["BC","AD"],wide:["Before Christ","Anno Domini"]},T3={narrow:["1","2","3","4"],abbreviated:["Q1","Q2","Q3","Q4"],wide:["1st quarter","2nd quarter","3rd quarter","4th quarter"]},R3={narrow:["J","F","M","A","M","J","J","A","S","O","N","D"],abbreviated:["Jan","Feb","Mar","Apr","May","Jun","Jul","Aug","Sep","Oct","Nov","Dec"],wide:["January","February","March","April","May","June","July","August","September","October","November","December"]},A3={narrow:["S","M","T","W","T","F","S"],short:["Su","Mo","Tu","We","Th","Fr","Sa"],abbreviated:["Sun","Mon","Tue","Wed","Thu","Fri","Sat"],wide:["Sunday","Monday","Tuesday","Wednesday","Thursday","Friday","Saturday"]},M3={narrow:{am:"a",pm:"p",midnight:"mi",noon:"n",morning:"morning",afternoon:"afternoon",evening:"evening",night:"night"},abbreviated:{am:"AM",pm:"PM",midnight:"midnight",noon:"noon",morning:"morning",afternoon:"afternoon",evening:"evening",night:"night"},wide:{am:"a.m.",pm:"p.m.",midnight:"midnight",noon:"noon",morning:"morning",afternoon:"afternoon",evening:"evening",night:"night"}},O3={narrow:{am:"a",pm:"p",midnight:"mi",noon:"n",morning:"in the morning",afternoon:"in the afternoon",evening:"in the evening",night:"at night"},abbreviated:{am:"AM",pm:"PM",midnight:"midnight",noon:"noon",morning:"in the morning",afternoon:"in the afternoon",evening:"in the evening",night:"at night"},wide:{am:"a.m.",pm:"p.m.",midnight:"midnight",noon:"noon",morning:"in the morning",afternoon:"in the afternoon",evening:"in the evening",night:"at night"}},I3=(e,t)=>{const n=Number(e),r=n%100;if(r>20||r<10)switch(r%10){case 1:return n+"st";case 2:return n+"nd";case 3:return n+"rd"}return n+"th"},D3={ordinalNumber:I3,era:Mi({values:E3,defaultWidth:"wide"}),quarter:Mi({values:T3,defaultWidth:"wide",argumentCallback:e=>e-1}),month:Mi({values:R3,defaultWidth:"wide"}),day:Mi({values:A3,defaultWidth:"wide"}),dayPeriod:Mi({values:M3,defaultWidth:"wide",formattingValues:O3,defaultFormattingWidth:"wide"})};function Oi(e){return(t,n={})=>{const r=n.width,s=r&&e.matchPatterns[r]||e.matchPatterns[e.defaultMatchWidth],o=t.match(s);if(!o)return null;const a=o[0],l=r&&e.parsePatterns[r]||e.parsePatterns[e.defaultParseWidth],c=Array.isArray(l)?_3(l,f=>f.test(a)):L3(l,f=>f.test(a));let u;u=e.valueCallback?e.valueCallback(c):c,u=n.valueCallback?n.valueCallback(u):u;const d=t.slice(a.length);return{value:u,rest:d}}}function L3(e,t){for(const n in e)if(Object.prototype.hasOwnProperty.call(e,n)&&t(e[n]))return n}function _3(e,t){for(let n=0;n<e.length;n++)if(t(e[n]))return n}function F3(e){return(t,n={})=>{const r=t.match(e.matchPattern);if(!r)return null;const s=r[0],o=t.match(e.parsePattern);if(!o)return null;let a=e.valueCallback?e.valueCallback(o[0]):o[0];a=n.valueCallback?n.valueCallback(a):a;const l=t.slice(s.length);return{value:a,rest:l}}}const V3=/^(\d+)(th|st|nd|rd)?/i,$3=/\d+/i,B3={narrow:/^(b|a)/i,abbreviated:/^(b\.?\s?c\.?|b\.?\s?c\.?\s?e\.?|a\.?\s?d\.?|c\.?\s?e\.?)/i,wide:/^(before christ|before common era|anno domini|common era)/i},z3={any:[/^b/i,/^(a|c)/i]},U3={narrow:/^[1234]/i,abbreviated:/^q[1234]/i,wide:/^[1234](th|st|nd|rd)? quarter/i},W3={any:[/1/i,/2/i,/3/i,/4/i]},H3={narrow:/^[jfmasond]/i,abbreviated:/^(jan|feb|mar|apr|may|jun|jul|aug|sep|oct|nov|dec)/i,wide:/^(january|february|march|april|may|june|july|august|september|october|november|december)/i},K3={narrow:[/^j/i,/^f/i,/^m/i,/^a/i,/^m/i,/^j/i,/^j/i,/^a/i,/^s/i,/^o/i,/^n/i,/^d/i],any:[/^ja/i,/^f/i,/^mar/i,/^ap/i,/^may/i,/^jun/i,/^jul/i,/^au/i,/^s/i,/^o/i,/^n/i,/^d/i]},Y3={narrow:/^[smtwf]/i,short:/^(su|mo|tu|we|th|fr|sa)/i,abbreviated:/^(sun|mon|tue|wed|thu|fri|sat)/i,wide:/^(sunday|monday|tuesday|wednesday|thursday|friday|saturday)/i},G3={narrow:[/^s/i,/^m/i,/^t/i,/^w/i,/^t/i,/^f/i,/^s/i],any:[/^su/i,/^m/i,/^tu/i,/^w/i,/^th/i,/^f/i,/^sa/i]},q3={narrow:/^(a|p|mi|n|(in the|at) (morning|afternoon|evening|night))/i,any:/^([ap]\.?\s?m\.?|midnight|noon|(in the|at) (morning|afternoon|evening|night))/i},Q3={any:{am:/^a/i,pm:/^p/i,midnight:/^mi/i,noon:/^no/i,morning:/morning/i,afternoon:/afternoon/i,evening:/evening/i,night:/night/i}},X3={ordinalNumber:F3({matchPattern:V3,parsePattern:$3,valueCallback:e=>parseInt(e,10)}),era:Oi({matchPatterns:B3,defaultMatchWidth:"wide",parsePatterns:z3,defaultParseWidth:"any"}),quarter:Oi({matchPatterns:U3,defaultMatchWidth:"wide",parsePatterns:W3,defaultParseWidth:"any",valueCallback:e=>e+1}),month:Oi({matchPatterns:H3,defaultMatchWidth:"wide",parsePatterns:K3,defaultParseWidth:"any"}),day:Oi({matchPatterns:Y3,defaultMatchWidth:"wide",parsePatterns:G3,defaultParseWidth:"any"}),dayPeriod:Oi({matchPatterns:q3,defaultMatchWidth:"any",parsePatterns:Q3,defaultParseWidth:"any"})},J3={code:"en-US",formatDistance:b3,formatLong:C3,formatRelative:P3,localize:D3,match:X3,options:{weekStartsOn:0,firstWeekContainsDate:1}};function Z3(e){const t=Xt(e);return p3(t,v3(t))+1}function e5(e){const t=Xt(e),n=+$c(t)-+g3(t);return Math.round(n/Bj)+1}function Wj(e,t){var d,f,m,p;const n=Xt(e),r=n.getFullYear(),s=ju(),o=(t==null?void 0:t.firstWeekContainsDate)??((f=(d=t==null?void 0:t.locale)==null?void 0:d.options)==null?void 0:f.firstWeekContainsDate)??s.firstWeekContainsDate??((p=(m=s.locale)==null?void 0:m.options)==null?void 0:p.firstWeekContainsDate)??1,a=dr(e,0);a.setFullYear(r+1,0,o),a.setHours(0,0,0,0);const l=Oa(a,t),c=dr(e,0);c.setFullYear(r,0,o),c.setHours(0,0,0,0);const u=Oa(c,t);return n.getTime()>=l.getTime()?r+1:n.getTime()>=u.getTime()?r:r-1}function t5(e,t){var l,c,u,d;const n=ju(),r=(t==null?void 0:t.firstWeekContainsDate)??((c=(l=t==null?void 0:t.locale)==null?void 0:l.options)==null?void 0:c.firstWeekContainsDate)??n.firstWeekContainsDate??((d=(u=n.locale)==null?void 0:u.options)==null?void 0:d.firstWeekContainsDate)??1,s=Wj(e,t),o=dr(e,0);return o.setFullYear(s,0,r),o.setHours(0,0,0,0),Oa(o,t)}function n5(e,t){const n=Xt(e),r=+Oa(n,t)-+t5(n,t);return Math.round(r/Bj)+1}function ye(e,t){const n=e<0?"-":"",r=Math.abs(e).toString().padStart(t,"0");return n+r}const Pr={y(e,t){const n=e.getFullYear(),r=n>0?n:1-n;return ye(t==="yy"?r%100:r,t.length)},M(e,t){const n=e.getMonth();return t==="M"?String(n+1):ye(n+1,2)},d(e,t){return ye(e.getDate(),t.length)},a(e,t){const n=e.getHours()/12>=1?"pm":"am";switch(t){case"a":case"aa":return n.toUpperCase();case"aaa":return n;case"aaaaa":return n[0];case"aaaa":default:return n==="am"?"a.m.":"p.m."}},h(e,t){return ye(e.getHours()%12||12,t.length)},H(e,t){return ye(e.getHours(),t.length)},m(e,t){return ye(e.getMinutes(),t.length)},s(e,t){return ye(e.getSeconds(),t.length)},S(e,t){const n=t.length,r=e.getMilliseconds(),s=Math.trunc(r*Math.pow(10,n-3));return ye(s,t.length)}},eo={midnight:"midnight",noon:"noon",morning:"morning",afternoon:"afternoon",evening:"evening",night:"night"},dv={G:function(e,t,n){const r=e.getFullYear()>0?1:0;switch(t){case"G":case"GG":case"GGG":return n.era(r,{width:"abbreviated"});case"GGGGG":return n.era(r,{width:"narrow"});case"GGGG":default:return n.era(r,{width:"wide"})}},y:function(e,t,n){if(t==="yo"){const r=e.getFullYear(),s=r>0?r:1-r;return n.ordinalNumber(s,{unit:"year"})}return Pr.y(e,t)},Y:function(e,t,n,r){const s=Wj(e,r),o=s>0?s:1-s;if(t==="YY"){const a=o%100;return ye(a,2)}return t==="Yo"?n.ordinalNumber(o,{unit:"year"}):ye(o,t.length)},R:function(e,t){const n=zj(e);return ye(n,t.length)},u:function(e,t){const n=e.getFullYear();return ye(n,t.length)},Q:function(e,t,n){const r=Math.ceil((e.getMonth()+1)/3);switch(t){case"Q":return String(r);case"QQ":return ye(r,2);case"Qo":return n.ordinalNumber(r,{unit:"quarter"});case"QQQ":return n.quarter(r,{width:"abbreviated",context:"formatting"});case"QQQQQ":return n.quarter(r,{width:"narrow",context:"formatting"});case"QQQQ":default:return n.quarter(r,{width:"wide",context:"formatting"})}},q:function(e,t,n){const r=Math.ceil((e.getMonth()+1)/3);switch(t){case"q":return String(r);case"qq":return ye(r,2);case"qo":return n.ordinalNumber(r,{unit:"quarter"});case"qqq":return n.quarter(r,{width:"abbreviated",context:"standalone"});case"qqqqq":return n.quarter(r,{width:"narrow",context:"standalone"});case"qqqq":default:return n.quarter(r,{width:"wide",context:"standalone"})}},M:function(e,t,n){const r=e.getMonth();switch(t){case"M":case"MM":return Pr.M(e,t);case"Mo":return n.ordinalNumber(r+1,{unit:"month"});case"MMM":return n.month(r,{width:"abbreviated",context:"formatting"});case"MMMMM":return n.month(r,{width:"narrow",context:"formatting"});case"MMMM":default:return n.month(r,{width:"wide",context:"formatting"})}},L:function(e,t,n){const r=e.getMonth();switch(t){case"L":return String(r+1);case"LL":return ye(r+1,2);case"Lo":return n.ordinalNumber(r+1,{unit:"month"});case"LLL":return n.month(r,{width:"abbreviated",context:"standalone"});case"LLLLL":return n.month(r,{width:"narrow",context:"standalone"});case"LLLL":default:return n.month(r,{width:"wide",context:"standalone"})}},w:function(e,t,n,r){const s=n5(e,r);return t==="wo"?n.ordinalNumber(s,{unit:"week"}):ye(s,t.length)},I:function(e,t,n){const r=e5(e);return t==="Io"?n.ordinalNumber(r,{unit:"week"}):ye(r,t.length)},d:function(e,t,n){return t==="do"?n.ordinalNumber(e.getDate(),{unit:"date"}):Pr.d(e,t)},D:function(e,t,n){const r=Z3(e);return t==="Do"?n.ordinalNumber(r,{unit:"dayOfYear"}):ye(r,t.length)},E:function(e,t,n){const r=e.getDay();switch(t){case"E":case"EE":case"EEE":return n.day(r,{width:"abbreviated",context:"formatting"});case"EEEEE":return n.day(r,{width:"narrow",context:"formatting"});case"EEEEEE":return n.day(r,{width:"short",context:"formatting"});case"EEEE":default:return n.day(r,{width:"wide",context:"formatting"})}},e:function(e,t,n,r){const s=e.getDay(),o=(s-r.weekStartsOn+8)%7||7;switch(t){case"e":return String(o);case"ee":return ye(o,2);case"eo":return n.ordinalNumber(o,{unit:"day"});case"eee":return n.day(s,{width:"abbreviated",context:"formatting"});case"eeeee":return n.day(s,{width:"narrow",context:"formatting"});case"eeeeee":return n.day(s,{width:"short",context:"formatting"});case"eeee":default:return n.day(s,{width:"wide",context:"formatting"})}},c:function(e,t,n,r){const s=e.getDay(),o=(s-r.weekStartsOn+8)%7||7;switch(t){case"c":return String(o);case"cc":return ye(o,t.length);case"co":return n.ordinalNumber(o,{unit:"day"});case"ccc":return n.day(s,{width:"abbreviated",context:"standalone"});case"ccccc":return n.day(s,{width:"narrow",context:"standalone"});case"cccccc":return n.day(s,{width:"short",context:"standalone"});case"cccc":default:return n.day(s,{width:"wide",context:"standalone"})}},i:function(e,t,n){const r=e.getDay(),s=r===0?7:r;switch(t){case"i":return String(s);case"ii":return ye(s,t.length);case"io":return n.ordinalNumber(s,{unit:"day"});case"iii":return n.day(r,{width:"abbreviated",context:"formatting"});case"iiiii":return n.day(r,{width:"narrow",context:"formatting"});case"iiiiii":return n.day(r,{width:"short",context:"formatting"});case"iiii":default:return n.day(r,{width:"wide",context:"formatting"})}},a:function(e,t,n){const s=e.getHours()/12>=1?"pm":"am";switch(t){case"a":case"aa":return n.dayPeriod(s,{width:"abbreviated",context:"formatting"});case"aaa":return n.dayPeriod(s,{width:"abbreviated",context:"formatting"}).toLowerCase();case"aaaaa":return n.dayPeriod(s,{width:"narrow",context:"formatting"});case"aaaa":default:return n.dayPeriod(s,{width:"wide",context:"formatting"})}},b:function(e,t,n){const r=e.getHours();let s;switch(r===12?s=eo.noon:r===0?s=eo.midnight:s=r/12>=1?"pm":"am",t){case"b":case"bb":return n.dayPeriod(s,{width:"abbreviated",context:"formatting"});case"bbb":return n.dayPeriod(s,{width:"abbreviated",context:"formatting"}).toLowerCase();case"bbbbb":return n.dayPeriod(s,{width:"narrow",context:"formatting"});case"bbbb":default:return n.dayPeriod(s,{width:"wide",context:"formatting"})}},B:function(e,t,n){const r=e.getHours();let s;switch(r>=17?s=eo.evening:r>=12?s=eo.afternoon:r>=4?s=eo.morning:s=eo.night,t){case"B":case"BB":case"BBB":return n.dayPeriod(s,{width:"abbreviated",context:"formatting"});case"BBBBB":return n.dayPeriod(s,{width:"narrow",context:"formatting"});case"BBBB":default:return n.dayPeriod(s,{width:"wide",context:"formatting"})}},h:function(e,t,n){if(t==="ho"){let r=e.getHours()%12;return r===0&&(r=12),n.ordinalNumber(r,{unit:"hour"})}return Pr.h(e,t)},H:function(e,t,n){return t==="Ho"?n.ordinalNumber(e.getHours(),{unit:"hour"}):Pr.H(e,t)},K:function(e,t,n){const r=e.getHours()%12;return t==="Ko"?n.ordinalNumber(r,{unit:"hour"}):ye(r,t.length)},k:function(e,t,n){let r=e.getHours();return r===0&&(r=24),t==="ko"?n.ordinalNumber(r,{unit:"hour"}):ye(r,t.length)},m:function(e,t,n){return t==="mo"?n.ordinalNumber(e.getMinutes(),{unit:"minute"}):Pr.m(e,t)},s:function(e,t,n){return t==="so"?n.ordinalNumber(e.getSeconds(),{unit:"second"}):Pr.s(e,t)},S:function(e,t){return Pr.S(e,t)},X:function(e,t,n){const r=e.getTimezoneOffset();if(r===0)return"Z";switch(t){case"X":return hv(r);case"XXXX":case"XX":return vs(r);case"XXXXX":case"XXX":default:return vs(r,":")}},x:function(e,t,n){const r=e.getTimezoneOffset();switch(t){case"x":return hv(r);case"xxxx":case"xx":return vs(r);case"xxxxx":case"xxx":default:return vs(r,":")}},O:function(e,t,n){const r=e.getTimezoneOffset();switch(t){case"O":case"OO":case"OOO":return"GMT"+fv(r,":");case"OOOO":default:return"GMT"+vs(r,":")}},z:function(e,t,n){const r=e.getTimezoneOffset();switch(t){case"z":case"zz":case"zzz":return"GMT"+fv(r,":");case"zzzz":default:return"GMT"+vs(r,":")}},t:function(e,t,n){const r=Math.trunc(e.getTime()/1e3);return ye(r,t.length)},T:function(e,t,n){const r=e.getTime();return ye(r,t.length)}};function fv(e,t=""){const n=e>0?"-":"+",r=Math.abs(e),s=Math.trunc(r/60),o=r%60;return o===0?n+String(s):n+String(s)+t+ye(o,2)}function hv(e,t){return e%60===0?(e>0?"-":"+")+ye(Math.abs(e)/60,2):vs(e,t)}function vs(e,t=""){const n=e>0?"-":"+",r=Math.abs(e),s=ye(Math.trunc(r/60),2),o=ye(r%60,2);return n+s+t+o}const mv=(e,t)=>
336{switch(e){case"P":return t.date({width:"short"});case"PP":return t.date({width:"medium"});case"PPP":return t.date({width:"long"});case"PPPP":default:return t.date({width:"full"})}},Hj=(e,t)=>{switch(e){case"p":return t.time({width:"short"});case"pp":return t.time({width:"medium"});case"ppp":return t.time({width:"long"});case"pppp":default:return t.time({width:"full"})}},r5=(e,t)=>{const n=e.match(/(P+)(p+)?/)||[],r=n[1],s=n[2];if(!s)return mv(e,t);let o;switch(r){case"P":o=t.dateTime({width:"short"});break;case"PP":o=t.dateTime({width:"medium"});break;case"PPP":o=t.dateTime({width:"long"});break;case"PPPP":default:o=t.dateTime({width:"full"});break}return o.replace("{{date}}",mv(r,t)).replace("{{time}}",Hj(s,t))},s5={p:Hj,P:r5},o5=/^D+$/,i5=/^Y+$/,a5=["D","DD","YY","YYYY"];function l5(e){return o5.test(e)}function c5(e){return i5.test(e)}function u5(e,t,n){const r=d5(e,t,n);if(console.warn(r),a5.includes(e))throw new RangeError(r)}function d5(e,t,n){const r=e[0]==="Y"?"years":"days of the month";return`Use \`${e.toLowerCase()}\` instead of \`${e}\` (in \`${t}\`) for formatting ${r} to the input \`${n}\`; see: https://github.com/date-fns/date-fns/blob/master/docs/unicodeTokens.md`}const f5=/[yYQqMLwIdDecihHKkms]o|(\w)\1*|''|'(''|[^'])+('|$)|./g,h5=/P+p+|P+|p+|''|'(''|[^'])+('|$)|./g,m5=/^'([^]*?)'?$/,p5=/''/g,g5=/[a-zA-Z]/;function Ir(e,t,n){var d,f,m,p;const r=ju(),s=r.locale??J3,o=r.firstWeekContainsDate??((f=(d=r.locale)==null?void 0:d.options)==null?void 0:f.firstWeekContainsDate)??1,a=r.weekStartsOn??((p=(m=r.locale)==null?void 0:m.options)==null?void 0:p.weekStartsOn)??0,l=Xt(e);if(!y3(l))throw new RangeError("Invalid time value");let c=t.match(h5).map(b=>{const x=b[0];if(x==="p"||x==="P"){const y=s5[x];return y(b,s.formatLong)}return b}).join("").match(f5).map(b=>{if(b==="''")return{isToken:!1,value:"'"};const x=b[0];if(x==="'")return{isToken:!1,value:x5(b)};if(dv[x])return{isToken:!0,value:b};if(x.match(g5))throw new RangeError("Format string contains an unescaped latin alphabet character `"+x+"`");return{isToken:!1,value:b}});s.localize.preprocessor&&(c=s.localize.preprocessor(l,c));const u={firstWeekContainsDate:o,weekStartsOn:a,locale:s};return c.map(b=>{if(!b.isToken)return b.value;const x=b.value;(c5(x)||l5(x))&&u5(x,t,String(e));const y=dv[x[0]];return y(l,x,s.localize,u)}).join("")}function x5(e){const t=e.match(m5);return t?t[1].replace(p5,"'"):e}function y5(e){return Bp(e,Uj(e))}function v5(e){return Bp(e,$j(Uj(e),1))}function pv(){return Ia(Date.now())}function Kj(e){if(e==="ASAP")return"ASAP";if(!e)return"Schedule";const t=new Date(e);if(Number.isNaN(t.getTime()))return e;const n=Ir(t,"h:mm a");return y5(t)?`Today, ${n}`:v5(t)?`Tomorrow, ${n}`:`${Ir(t,"MMM d")}, ${n}`}const gv=["sunday","monday","tuesday","wednesday","thursday","friday","saturday"];function Ud(e){const[t,n]=e.split(":").map(o=>parseInt(o,10));if(Number.isNaN(t))return e;const r=t>=12?"pm":"am",s=t%12===0?12:t%12;return n?`${s}:${String(n).padStart(2,"0")}${r}`:`${s}${r}`}const xv=e=>{const[t,n]=e.split(":").map(r=>parseInt(r,10));return t*60+n};function zp(e){if(!e)return null;const t=new Date,n=t.getHours()*60+t.getMinutes(),r=e[gv[t.getDay()]];if(r&&!r.closed){const s=xv(r.open),o=xv(r.close);if(n>=s&&n<o)return{isOpen:!0,label:`Open · Closes ${Ud(r.close)}`};if(n<s)return{isOpen:!1,label:`Closed · Opens ${Ud(r.open)}`}}for(let s=1;s<=7;s++){const o=e[gv[(t.getDay()+s)%7]];if(o&&!o.closed)return{isOpen:!1,label:`Closed · Opens ${Ud(o.open)}`}}return{isOpen:!1,label:"Closed"}}const w5=({onLocationClick:e,onTimeClick:t})=>{const{orderType:n,setOrderType:r,storeId:s,selectedAddressId:o,selectedTime:a}=Nn(),{stores:l}=Kn(),c=l.find(d=>d.id===s)??null,u=n==="pickup"?(c==null?void 0:c.name)??"Choose a store...":o?"Saved address":"Enter address...";return i.jsxs("div",{className:"space-y-3",children:[i.jsxs("div",{className:"flex bg-secondary rounded-full p-1",children:[i.jsx("button",{onClick:()=>r("pickup"),className:Y("flex-1 py-2.5 px-4 rounded-full font-medium text-sm transition-all",n==="pickup"?"bg-foreground text-background":"text-muted-foreground hover:text-foreground"),children:"Pickup"}),i.jsx("button",{onClick:()=>
336r("delivery"),className:Y("flex-1 py-2.5 px-4 rounded-full font-medium text-sm transition-all",n==="delivery"?"bg-foreground text-background":"text-muted-foreground hover:text-foreground"),children:"Delivery"})]}),i.jsxs("div",{className:"flex gap-2",children:[i.jsxs("button",{onClick:e,className:"flex-1 flex items-center gap-2 px-3 py-2.5 bg-secondary rounded-full text-left hover:bg-secondary/80 transition-colors",children:[i.jsx(er,{className:"w-4 h-4 text-muted-foreground flex-shrink-0"}),i.jsx("span",{className:"text-sm font-medium truncate",children:u}),i.jsx(Nc,{className:"w-4 h-4 text-muted-foreground ml-auto flex-shrink-0"})]}),i.jsxs("button",{onClick:t,className:"flex items-center gap-2 px-3 py-2.5 bg-secondary rounded-full hover:bg-secondary/80 transition-colors",children:[i.jsx(Xo,{className:"w-4 h-4 text-muted-foreground"}),i.jsx("span",{className:"text-sm font-medium",children:Kj(a)}),i.jsx(Nc,{className:"w-4 h-4 text-muted-foreground"})]})]})]})},b5=({activeCategory:e,onCategoryChange:t,searchQuery:n,onSearchQueryChange:r})=>{const[s,o]=h.useState(!1),a=h.useRef(null),l=h.useRef(null),c=h.useRef(null),u=h.useRef(null),{categories:d}=Kn();h.useEffect(()=>{if(l.current&&a.current){const m=a.current,p=l.current,b=p.offsetLeft-m.offsetWidth/2+p.offsetWidth/2;m.scrollTo({left:b,behavior:"smooth"})}},[e]),h.useEffect(()=>{s&&c.current&&c.current.focus()},[s]),h.useEffect(()=>{const m=p=>{u.current&&!u.current.contains(p.target)&&o(!1)};return s&&document.addEventListener("mousedown",m),()=>{document.removeEventListener("mousedown",m)}},[s]);const f=()=>{o(!1),r("")};return i.jsx("div",{className:"sticky top-0 z-40 bg-background safari-fix",children:i.jsx("div",{className:"max-w-7xl mx-auto",children:i.jsxs("div",{ref:a,className:"flex items-center gap-2 overflow-x-auto scrollbar-hide px-4 py-3 lg:px-6",children:[i.jsx("div",{ref:u,className:"relative flex-shrink-0",children:s?i.jsxs("div",{className:"flex items-center gap-2",children:[i.jsxs("div",{className:"relative",children:[i.jsx(yx,{className:"absolute left-3 top-1/2 -translate-y-1/2 w-4 h-4 text-muted-foreground"}),i.jsx("input",{ref:c,type:"text",value:n,onChange:m=>r(m.target.value),placeholder:"Search menu...",className:"w-48 sm:w-64 h-9 pl-10 pr-4 rounded-lg bg-secondary text-sm focus:outline-none focus:ring-2 focus:ring-foreground/20"})]}),i.jsx("button",{onClick:f,className:"w-9 h-9 rounded-lg flex items-center justify-center hover:bg-secondary transition-colors","aria-label":"Close search",children:i.jsx(vt,{className:"w-4 h-4"})})]}):i.jsx("button",{onClick:()=>o(!0),className:"w-9 h-9 rounded-lg border border-border/60 bg-background flex items-center justify-center hover:bg-secondary transition-colors","aria-label":"Search",children:i.jsx(yx,{className:"w-4 h-4 text-muted-foreground"})})}),d.map(m=>i.jsxs("button",{ref:e===m.id?l:null,onClick:()=>t(m.id),className:Y("flex-shrink-0 px-4 py-2 rounded-full text-sm font-medium transition-all whitespace-nowrap",e===m.id?"bg-foreground text-background":"bg-background border border-border/60 text-foreground hover:bg-secondary"),children:[m.name," ",m.emoji]},m.id))]})})})},S5=({item:e,onClick:t,onQuickAdd:n})=>{const{triggerHaptic:r}=mr(),s=a=>{a.stopPropagation(),r("medium"),n()},o=()=>{r("light"),t()};return i.jsxs(xe.div,{className:"flex gap-4 py-4 border-b border-border last:border-0 cursor-pointer hover:bg-secondary/30 transition-colors -mx-4 px-4",onClick:o,whileTap:{scale:.98},transition:{duration:.1},children:[i.jsxs("div",{className:"flex-1 min-w-0 flex flex-col justify-center",children:[i.jsx("h3",{className:"font-semibold text-base text-foreground mb-1",children:e.name}),e.discount?i.jsxs("div",{className:"flex items-center gap-2 mb-1 flex-wrap",children:[i.jsxs("span",{className:"text-base font-semibold text-foreground",children:["₦",e.price.toLocaleString()]}),i.jsxs("span",{className:"text-sm text-muted-foreground line-through",children:["₦",e.discount.originalPrice.toLocaleString()]}),e.discount.percentOff!=null&&i.jsxs("span",{className:"text-xs font-semibold text-destructive bg-destructive/10 rounded px-1.5 py-0.5",children:["-",e.discount.percentOff,"%"]})]}):i.jsxs("p",{className:"text-base font-semibold text-foreground mb-1",children:["₦",e.price.toLocaleStr
336ing()]}),i.jsx("p",{className:"text-sm text-muted-foreground line-clamp-2 leading-relaxed",children:e.description})]}),i.jsxs("div",{className:"relative flex-shrink-0",children:[i.jsx("img",{src:e.image,alt:e.name,className:"w-24 h-24 object-cover rounded-lg"}),i.jsx(xe.button,{onClick:s,className:"absolute -bottom-2 -right-2 w-8 h-8 rounded-lg bg-card border border-border shadow-sm flex items-center justify-center hover:bg-secondary transition-colors",whileHover:{scale:1.1},whileTap:{scale:.9},transition:{duration:.1},children:i.jsx(xn,{className:"w-4 h-4"})})]})]})},j5=({categoryId:e,items:t,onItemClick:n,onQuickAdd:r})=>{const{categories:s}=Kn(),o=s.find(a=>a.id===e);return!o||t.length===0?null:i.jsxs("section",{className:"mb-8",children:[i.jsxs("h2",{className:"text-lg font-bold mb-3 px-4 lg:px-0",children:[o.name," ",o.emoji]}),i.jsx("div",{className:"px-4 lg:px-0",children:t.map(a=>i.jsx(S5,{item:a,onClick:()=>n(a),onQuickAdd:()=>r(a)},a.id))})]})},N5=cu("inline-flex items-center justify-center gap-2 whitespace-nowrap rounded-xl text-sm font-semibold ring-offset-background transition-all duration-150 focus-visible:outline-none focus-visible:ring-2 focus-visible:ring-ring focus-visible:ring-offset-2 disabled:pointer-events-none disabled:opacity-50 [&_svg]:pointer-events-none [&_svg]:size-4 [&_svg]:shrink-0 active:scale-[0.96] active:brightness-90",{variants:{variant:{default:"bg-primary text-primary-foreground hover:bg-primary/90 hover:shadow-lg shadow-sm",destructive:"bg-destructive text-destructive-foreground hover:bg-destructive/90",outline:"border border-border bg-card hover:bg-accent hover:text-accent-foreground hover:border-accent",secondary:"bg-secondary text-secondary-foreground hover:bg-secondary/80",ghost:"hover:bg-accent hover:text-accent-foreground",link:"text-primary underline-offset-4 hover:underline"},size:{default:"h-10 px-4 py-2",sm:"h-9 rounded-lg px-3",lg:"h-12 rounded-xl px-8",icon:"h-10 w-10"}},defaultVariants:{variant:"default",size:"default"}}),ue=h.forwardRef(({className:e,variant:t,size:n,asChild:r=!1,...s},o)=>{const a=r?gP:"button";return i.jsx(a,{className:Y(N5({variant:t,size:n,className:e})),ref:o,...s})});ue.displayName="Button";const Up=h.forwardRef(({className:e,...t},n)=>i.jsx("textarea",{className:Y("flex min-h-[80px] w-full rounded-md border border-input bg-background px-3 py-2 text-sm r
336ing-offset-background placeholder:text-muted-foreground focus-visible:outline-none focus-visible:ring-2 focus-visible:ring-ring focus-visible:ring-offset-2 disabled:cursor-not-allowed disabled:opacity-50",e),ref:n,...t}));Up.displayName="Textarea";const yi=e=>{const t=h.useRef(0),n=h.useRef(!1),r=s=>{const o=document.documentElement,a=o.style.scrollBehavior;o.style.scrollBehavior="auto",window.scrollTo(0,s),o.style.scrollBehavior=a};h.useLayoutEffect(()=>{if(e&&!n.current)t.current=window.scrollY,document.body.style.top=`-${t.current}px`,document.body.classList.add("modal-open"),n.current=!0;else if(!e&&n.current){const s=document.body.style.top,o=s?Math.abs(parseInt(s,10)):t.current;document.body.classList.remove("modal-open"),document.body.style.top="",n.current=!1,document.body.offsetHeight,r(o)}return()=>{if(n.current){const s=document.body.style.top,o=s?Math.abs(parseInt(s,10)):t.current;document.body.classList.remove("modal-open"),document.body.style.top="",n.current=!1,document.body.offsetHeight,r(o)}}},[e])};let Wd=null;function C5(){if(typeof window>"u")return null;try{const e=window.AudioContext??window.webkitAudioContext;return e?(Wd||(Wd=new e),Wd):null}catch{return null}}const k5={tap:{freq:660,duration:.06,type:"sine"},success:{freq:880,duration:.12,type:"triangle"},error:{freq:220,duration:.18,type:"sawtooth"}};function Yj(e="tap"){if(!$p("sound_effects"))return;const t=C5();if(t)try{t.state==="suspended"&&t.resume();const{freq:n,duration:r,type:s}=k5[e],o=t.createOscillator(),a=t.createGain();o.type=s,o.frequency.value=n,a.gain.setValueAtTime(1e-4,t.currentTime),a.gain.exponentialRampToValueAtTime(.15,t.currentTime+.01),a.gain.exponentialRampToValueAtTime(1e-4,t.currentTime+r),o.connect(a).connect(t.destination),o.start(),o.stop(t.currentTime+r)}catch{}}function Nu(e){var t;return((t=e.options)==null?void 0:t.some(n=>n.isVariation||n.required||(n.minSelections??0)>=1))??!1}function P5(e){var n;const t=e==null?void 0:e.maxSelections;return t!=null&&t>0?t:((n=e==null?void 0:e.choices)==null?void 0:n.length)??Number.MAX_SAFE_INTEGER}function E5(e){const t=e.minSelections??(e.required?1:0),n=e.maxSelections!=null&&e.maxSelections>0?e.maxSelections:null;return t>0&&n!=null?t===n?t===1?"Required":`Choose ${t}`:`Choose ${t}–${n}`:t>1?`Choose at least ${t}`:t===1?"Required":n!=null&&n>1?`Choose up to ${n}`:n===1?"Choose one":"Choose as many as you like"}const Hd=e=>e.replace(/^\s*(choose|select|pick)\s+/i,"").toLowerCase(),T5=({item:e,isOpen:t,onClose:n,onOpenItem:r})=>{var P;yi(t&&!!e);const{triggerHaptic:s}=mr();h.useEffect(()=>{t&&e&&s("medium")},[t,e,s]);const{addItem:o}=Nn(),[a,l]=h.useState(1),[c,u]=h.useState({}),[d,f]=h.useState(""),{menuItems:m,store:p}=Kn(),[b,x]=h.useState([]);h.useEffect(()=>{if(!e||e.isCombo){x([]);return}const N=m.filter(k=>k.id!==e.id&&k.category===e.category).slice(0,3);if(!(p!=null&&p.id)){x(N);return}let E=!1;return bo.recommendations(p.id,{productId:e.id,limit:6}).then(k=>{if(E)return;const R=k.map(M=>m.find(I=>I.id===M.id)).filter(M=>!!M&&M.id!==e.id).slice(0,3);x(R.length?R:N)}).catch(()=>{E||x(N)}),()=>{E=!0}},[e,m,p==null?void 0:p.id]);const y=h.useMemo(()=>{if(!(e!=null&&e.isCombo)||!e.comboItems)return null;const N=e.comboItems.reduce((R,M)=>R+M.originalPrice,0),E=N-e.price,k=Math.round(E/N*100);return{originalTotal:N,savings:E,savingsPercent:k}},[e]);if(h.useEffect(()=>{u({}),l(1),f("")},[e==null?void 0:e.id]),!e)return null;const w=(N,E)=>{var M;const k=(M=e.options)==null?void 0:M.find(I=>I.id===N),R=P5(k);if(R<=1){u(I=>({...I,[N]:[E]}));return}u(I=>{const O=I[N]??[];return O.includes(E)?{...I,[N]:O.filter(H=>H!==E)}:O.length>=R?(K.error(`You can pick at most ${R} for ${((k==null?void 0:k.name)??"").toLowerCase()}`),s("error"),I):{...I,[N]:[...O,E]}})},g=()=>zs(e,c)*a,v=()=>{const N=e.options??[];for(const E of N){const k=c[E.id]??[];if(E.required&&k.length===0){K.error(`Please choose ${Hd(E.name)}`),s("error");return}const R=E.minSelections??0;if(R>0&&k.length<R){K.error(R===1?`Please choose ${Hd(E.name)}`:`Please choose at least ${R} for ${Hd(E.name)}`),s("error");return}if(E.maxSelections&&k.length>E.maxSelections){K.error(`You can pick at most ${E.maxSelections} for ${E.name.toLowerCase()}`),s("error");return}}s("success"),Yj("success"),o(e,a,c,d),l(1),u({}),f(""),n()},S=N=>{if(s("light"),Nu(N)&&r){r(N);return}o(N),K.success(`${N.name} added`)},j=N=>
336`₦${N.toLocaleString()}`,C=()=>{s("light"),n()};return i.jsx(ti,{children:t&&i.jsxs(i.Fragment,{children:[i.jsx(xe.div,{initial:{opacity:0},animate:{opacity:1},exit:{opacity:0},transition:{duration:.2},className:"fixed inset-0 bg-foreground/50 z-50 safari-fix",onClick:C}),i.jsxs(xe.div,{initial:{y:"100%",opacity:.5},animate:{y:0,opacity:1},exit:{y:"100%",opacity:0},transition:{type:"spring",damping:25,stiffness:300},className:Y("fixed z-50 bg-card border border-border shadow-none overflow-hidden flex flex-col safari-fix","inset-x-0 bottom-0 rounded-t-3xl h-[85dvh] max-h-[85dvh]","lg:inset-y-4 lg:right-4 lg:left-auto lg:bottom-auto lg:rounded-2xl lg:w-[480px] lg:h-auto lg:max-h-[calc(100vh-2rem)]"),children:[i.jsxs("div",{className:"relative h-48 sm:h-56 flex-shrink-0",children:[i.jsx("img",{src:e.image,alt:e.name,className:"w-full h-full object-cover"}),i.jsx("div",{className:"absolute inset-0 bg-gradient-to-t from-black/40 to-transparent"}),e.isCombo&&y&&i.jsxs(xe.div,{initial:{scale:.8,opacity:0},animate:{scale:1,opacity:1},transition:{delay:.2},className:"absolute top-3 left-3 bg-success text-success-foreground px-3 py-1.5 rounded-full text-sm font-bold flex items-center gap-1.5",children:[i.jsx(Vb,{className:"w-4 h-4"}),"Save ",y.savingsPercent,"%"]}),i.jsx("button",{onClick:C,className:"absolute top-3 right-3 w-9 h-9 rounded-full bg-card flex items-center justify-center active:scale-95 transition-transform",children:i.jsx(vt,{className:"w-4 h-4"})})]}),i.jsx("div",{className:"flex-1 overflow-y-auto",children:i.jsxs("div",{className:"p-5",children:[i.jsxs("div",{className:"flex items-start justify-between gap-3 mb-1",children:[i.jsx("h2",{className:"text-xl font-bold",children:e.name}),i.jsxs("div",{className:"text-right flex-shrink-0",children:[i.jsx("span",{className:"font-bold text-lg",children:j(e.price)}),e.isCombo&&y&&i.jsx("p",{className:"text-xs text-muted-foreground line-through",children:j(y.originalTotal)}),e.discount&&i.jsxs("div",{className:"flex items-center justify-end gap-2",children:[i.jsx("span",{className:"text-xs text-muted-foreground line-through",children:j(e.discount.originalPrice)}),e.discount.percentOff!=null&&i.jsxs("span",{className:"text-[10px] font-semibold text-destructive bg-destructive/10 rounded px-1 py-0.5",children:["-",e.discount.percentOff,"%"]})]})]})]}),i.jsx("p",{className:"text-muted-foreground text-sm mb-5",children:e.description}),e.isCombo&&e.comboItems&&i.jsxs("div",{className:"mb-5 bg-secondary/50 rounded-xl p-4",children:[i.jsxs("div",{className:"flex items-center gap-2 mb-3",children:[i.jsx(zm,{className:"w-4 h-4 text-primary"}),i.jsx("h3",{className:"font-semibold text-sm",children:"What's Included"})]}),i.jsx("div",{className:"space-y-2",children:e.comboItems.map((N,E)=>i.jsxs("div",{className:"flex items-center justify-between py-2 border-b border-border/50 last:border-0",children:[i.jsxs("div",{className:"flex items-center gap-2",children:[i.jsx("div",{className:"w-6 h-6 rounded-full bg-primary/10 flex items-center justify-center",children:i.jsx(Mn,{className:"w-3.5 h-3.5 text-primary"})}),i.jsx("span",{className:"text-sm",children:N.name})]}),i.jsx("span",{className:"text-sm text-muted-foreground line-through",children:j(N.originalPrice)})]},E))}),y&&i.jsxs("div",{className:"mt-3 pt-3 border-t border-border flex items-center justify-between",children:[i.jsx("span",{className:"text-sm font-medium text-success",children:"Your Savings"}),i.jsx("span",{className:"font-bold text-success",children:j(y.savings)})]})]}),(P=e.options)==null?void 0:P.map(N=>i.jsxs("div",{className:"mb-5",children:[i.jsxs("div",{className:"flex items-center justify-between mb-3",children:[i.jsx("h3",{className:"font-semibold",children:N.name}),i.jsx("span",{className:"text-xs text-muted-foreground",children:E5(N)})]}),i.jsx("div",{className:"space-y-2",children:N.choices.map(E=>{var R;const k=((R=c[N.id])==null?void 0:R.includes(E.id))??!1;return i.jsxs("button",{onClick:()=>w(N.id,E.id),className:Y("w-full flex items-center gap-3 p-3 rounded-xl border transition-all",k?"border-primary bg-primary/10":"border-border hover:bg-secondary/50"),children:[E.image&&i.jsx("img",{src:E.image,alt:E.name,className:"w-10 h-10 rounded-lg object-cover flex-shrink-0"}),i.jsxs("div",{className:"flex-1 text-left",children:[i.jsx("p",{className:"font-medium text-sm",children:E.name}),E.price&&E.price>0&&i.jsxs("p",{className:"text-xs text-muted-foreground",children:[N.isVariation?"":"+","₦",E.price.toLocaleStr
336ing()]})]}),k&&i.jsx("div",{className:"w-5 h-5 rounded-full bg-primary flex items-center justify-center",children:i.jsx(Mn,{className:"w-3 h-3 text-primary-foreground"})})]},E.id)})})]},N.id)),i.jsxs("div",{className:"mb-5",children:[i.jsx("h3",{className:"font-semibold mb-2",children:"Special Requests"}),i.jsx(Up,{placeholder:"Any special instructions...",value:d,onChange:N=>f(N.target.value),className:"resize-none h-20 text-sm"})]}),b.length>0&&i.jsxs("div",{className:"mb-4",children:[i.jsx("h3",{className:"font-semibold mb-3",children:"Goes well with"}),i.jsx("div",{className:"space-y-2",children:b.map(N=>i.jsxs("div",{className:"flex items-center gap-3",children:[i.jsx("img",{src:N.image,alt:N.name,className:"w-12 h-12 object-cover rounded-lg flex-shrink-0"}),i.jsxs("div",{className:"flex-1 min-w-0",children:[i.jsx("p",{className:"font-medium text-sm truncate",children:N.name}),i.jsxs("p",{className:"text-xs text-muted-foreground",children:["₦",N.price.toLocaleString()]})]}),i.jsx("button",{onClick:()=>S(N),className:"w-8 h-8 rounded-full border border-border flex items-center justify-center hover:bg-secondary transition-colors",children:i.jsx(xn,{className:"w-4 h-4"})})]},N.id))})]})]})}),i.jsx("div",{className:"flex-shrink-0 p-4 border-t border-border bg-card safe-bottom-pad",children:i.jsxs("div",{className:"flex items-center gap-3",children:[i.jsxs("div",{className:"flex items-center bg-secondary rounded-full h-11",children:[i.jsx("button",{onClick:()=>l(N=>Math.max(1,N-1)),className:"w-11 h-11 rounded-l-full flex items-center justify-center hover:bg-muted transition-colors",children:i.jsx(Cc,{className:"w-4 h-4"})}),i.jsx("span",{className:"w-8 text-center font-bold",children:a}),i.jsx("button",{onClick:()=>l(N=>N+1),className:"w-11 h-11 rounded-r-full flex items-center justify-center hover:bg-muted transition-colors",children:i.jsx(xn,{className:"w-4 h-4"})})]}),i.jsxs(ue,{onClick:v,className:"flex-1 h-11 text-sm font-semibold rounded-full",size:"lg",children:["Add to cart · ₦",g().toLocaleString()]})]})})]})]})})},R5=({isOpen:e,onClose:t,onCheckout:n,onOpenItem:r})=>{yi(e);const{triggerHaptic:s}=mr();h.useEffect(()=>{e&&s("medium")},[e,s]);const{items:o,updateQuantity:a,addItem:l,subtotal:c,pointsToEarn:u,storeId:d}=Nn(),{menuItems:f}=Kn(),[m,p]=h.useState([]);h.useEffect(()=>{var S;if(!e||o.length===0){p([]);return}const y=new Set(o.map(j=>j.menuItem.id)),w=j=>j.map(C=>f.find(P=>P.id===C)).filter(C=>!!C&&!y.has(C.id)).slice(0,3),g=()=>f.filter(j=>!y.has(j.id)).sort(()=>Math.random()-.5).slice(0,3);let v=!1;if(!d){p(g());return}return bo.recommendations(d,{productId:(S=o[0])==null?void 0:S.menuItem.id,limit:6}).then(j=>{if(v)return;const C=w(j.map(P=>P.id));p(C.length?C:g())}).catch(()=>{v||p(g())}),()=>{v=!0}},[e,d,o.length,f]);const b=y=>{if(Nu(y)&&r){r(y);return}l(y),K.success(`${y.name} added`)},x=()=>{s("light"),t()};return i.jsx(ti,{children:e&&i.jsxs(i.Fragment,{children:[i.jsx(xe.div,{initial:{opacity:0}
336,animate:{opacity:1},exit:{opacity:0},transition:{duration:.2},className:"fixed inset-0 bg-foreground/50 z-50 safari-fix",onClick:x}),i.jsxs(xe.div,{initial:{y:"100%",opacity:.5},animate:{y:0,opacity:1},exit:{y:"100%",opacity:0},transition:{type:"spring",damping:25,stiffness:300},className:"fixed z-50 bg-card shadow-none border border-border flex flex-col safari-fix inset-x-0 bottom-0 rounded-t-3xl h-[85vh] max-h-[85vh] lg:hidden",onClick:y=>y.stopPropagation(),children:[i.jsxs("div",{className:"flex items-center justify-between p-5 pb-3 border-b border-border",children:[i.jsxs("h2",{className:"text-lg font-bold",children:["Cart (",o.length,")"]}),i.jsx("button",{onClick:x,className:"w-9 h-9 rounded-full bg-secondary flex items-center justify-center active:scale-95 transition-transform",children:i.jsx(vt,{className:"w-4 h-4"})})]}),i.jsxs("div",{className:"flex-1 overflow-y-auto",children:[o.length===0?i.jsxs("div",{className:"flex flex-col items-center justify-center py-12 text-center px-5",children:[i.jsx("div",{className:"w-14 h-14 rounded-full bg-secondary flex items-center justify-center mb-3",children:i.jsx("span",{className:"text-2xl",children:"🛒"})}),i.jsx("p",{className:"text-muted-foreground text-sm",children:"Your cart is empty"}),i.jsx("p",{className:"text-xs text-muted-foreground mt-1",children:"Add items to get started"})]}):i.jsx("div",{className:"px-5 py-3 space-y-3",children:o.map(y=>i.jsxs("div",{className:"flex gap-3",children:[i.jsx("img",{src:y.menuItem.image,alt:y.menuItem.name,className:"w-14 h-14 object-cover rounded-xl flex-shrink-0"}),i.jsxs("div",{className:"flex-1 min-w-0",children:[i.jsx("h3",{className:"font-semibold text-sm truncate",children:y.menuItem.name}),y.selectedOptions&&Object.keys(y.selectedOptions).length>0&&i.jsx("div",{className:"mt-1 space-y-0.5",children:Object.entries(y.selectedOptions).map(([w,g])=>{var S;const v=(S=y.menuItem.options)==null?void 0:S.find(j=>j.id===w);return g.map(j=>{const C=v==null?void 0:v.choices.find(P=>P.id===j);return C?i.jsxs("div",{className:"flex items-center justify-between text-xs text-muted-foreground",children:[i.jsxs("span",{className:"flex items-center gap-1",children:[i.jsx("span",{className:"w-1 h-1 rounded-full bg-muted-foreground"}),C.name]}),C.price&&C.price>0&&i.jsxs("span",{children:[v!=null&&v.isVariation?"":"+","₦",C.price.toLocaleString()]})]},`${w}-${j}`):null})})}),y.specialRequest&&i.jsxs("p",{className:"text-xs text-muted-foreground italic mt-1 truncate",children:['"',y.specialRequest,'"']}),i.jsxs("p",{className:"text-sm font-bold mt-1",children:["₦",(zs(y.menuItem,y.selectedOptions)*y.quantity).toLocaleString()]})]}),i.jsxs("div",{className:"flex items-center bg-secondary rounded-full h-8",children:[i.jsx("button",{onClick:()=>a(y.id,y.quantity-1),className:"w-8 h-8 flex items-center justify-center hover:bg-muted rounded-l-full transition-colors",children:i.jsx(Cc,{className:"w-3 h-3"})}),i.jsx("span",{className:"w-6 text-center font-semibold text-sm",children:y.quantity}),i.jsx("button",{onClick:()=>a(y.id,y.quantity+1),className:"w-8 h-8 flex items-center justify-center hover:bg-muted rounded-r-full transition-colors",children:i.jsx(xn,{className:"w-3 h-3"})})]})]},y.id))}),o.length>0&&m.length>0&&i.jsxs("div",{className:"px-5 py-4 border-t border-border",children:[i.jsx("h3",{className:"font-semibold text-sm mb-3",children:"You might also like"}),i.jsx("div",{className:"space-y-2",children:m.map(y=>i.jsxs("div",{className:"flex items-center gap-3",children:[i.jsx("img",{src:y.image,alt:y.name,className:"w-12 h-12 object-cover rounded-lg flex-shrink-0"}),i.jsxs("div",{className:"flex-1 min-w-0",children:[i.jsx("p",{className:"font-medium text-sm truncate",children:y.name}),i.jsxs("p",{className:"text-xs text-muted-foreground",children:["₦",y.price.toLocaleString()]})]}),i.jsx("button",{onClick:()=>b(y),className:"w-8 h-8 rounded-full border border-border flex items-center justify-center hover:bg-secondary transition-colors",children:i.jsx(xn,{className:"w-4 h-4"})})]},y.id))})]})]}),o.length>0&&i.jsxs("div",{className:"flex-shrink-0 p-5 pt-3 border-t border-border space-y-3 safe-bottom-pad",children:[i.jsxs("div",{className:"flex items-center gap-2 px-3 py-2.5 bg-secondary rounded-xl",children:[i.jsx(ar,{className:"w-4 h-4"}),i.jsxs("span",{className:"text-sm",children:["Earn ",i.jsxs("strong",{children:[u," points"]})," with this order"]})]}),i.jsxs("div",{className:"flex items-center justify-between",children:[i.jsx("span",{className:"font-medium",children:"Subtotal"}),i.jsxs("span",{className:"font-bold",children:["₦",c.toLocaleStr
336ing()]})]}),i.jsxs(ue,{onClick:n,className:"w-full h-12 text-base font-semibold rounded-full",size:"lg",children:["Go to checkout",i.jsx($s,{className:"w-5 h-5 ml-1"})]})]})]}),i.jsx("div",{className:"hidden lg:flex fixed inset-0 z-50 items-center justify-center pointer-events-none",children:i.jsxs(xe.div,{initial:{opacity:0,scale:.95},animate:{opacity:1,scale:1},exit:{opacity:0,scale:.95},transition:{duration:.2,ease:"easeOut"},className:"bg-card shadow-lg border border-border flex flex-col safari-fix rounded-2xl w-full max-w-md max-h-[80vh] pointer-events-auto",onClick:y=>y.stopPropagation(),children:[i.jsxs("div",{className:"flex items-center justify-between p-5 pb-3 border-b border-border",children:[i.jsxs("h2",{className:"text-lg font-bold",children:["Cart (",o.length,")"]}),i.jsx("button",{onClick:x,className:"w-9 h-9 rounded-full bg-secondary flex items-center justify-center active:scale-95 transition-transform",children:i.jsx(vt,{className:"w-4 h-4"})})]}),i.jsxs("div",{className:"flex-1 overflow-y-auto",children:[o.length===0?i.jsxs("div",{className:"flex flex-col items-center justify-center py-12 text-center px-5",children:[i.jsx("div",{className:"w-14 h-14 rounded-full bg-secondary flex items-center justify-center mb-3",children:i.jsx("span",{className:"text-2xl",children:"🛒"})}),i.jsx("p",{className:"text-muted-foreground text-sm",children:"Your cart is empty"}),i.jsx("p",{className:"text-xs text-muted-foreground mt-1",children:"Add items to get started"})]}):i.jsx("div",{className:"px-5 py-3 space-y-3",children:o.map(y=>i.jsxs("div",{className:"flex gap-3",children:[i.jsx("img",{src:y.menuItem.image,alt:y.menuItem.name,className:"w-14 h-14 object-cover rounded-xl flex-shrink-0"}),i.jsxs("div",{className:"flex-1 min-w-0",children:[i.jsx("h3",{className:"font-semibold text-sm truncate",children:y.menuItem.name}),y.selectedOptions&&Object.keys(y.selectedOptions).length>0&&i.jsx("div",{className:"mt-1 space-y-0.5",children:Object.entries(y.selectedOptions).map(([w,g])=>{var S;const v=(S=y.menuItem.options)==null?void 0:S.find(j=>j.id===w);return g.map(j=>{const C=v==null?void 0:v.choices.find(P=>P.id===j);return C?i.jsxs("div",{className:"flex items-center justify-between text-xs text-muted-foreground",children:[i.jsxs("span",{className:"flex items-center gap-1",children:[i.jsx("span",{className:"w-1 h-1 rounded-full bg-muted-foreground"}),C.name]}),C.price&&C.price>0&&i.jsxs("span",{children:[v!=null&&v.isVariation?"":"+","₦",C.price.toLocaleString()]})]},`${w}-${j}`):null})})}),y.specialRequest&&i.jsxs("p",{className:"text-xs text-muted-foreground italic mt-1 truncate",children:['"',y.specialRequest,'"']}),i.jsxs("p",{className:"text-sm font-bold mt-1",children:["₦",(zs(y.menuItem,y.selectedOptions)*y.quantity).toLocaleString()]})]}),i.jsxs("div",{className:"flex items-center bg-secondary rounded-full h-8",children:[i.jsx("button",{onClick:()=>a(y.id,y.quantity-1),className:"w-8 h-8 flex items-center justify-center hover:bg-muted rounded-l-full transition-colors",children:i.jsx(Cc,{className:"w-3 h-3"})}),i.jsx("span",{className:"w-6 text-center font-semibold text-sm",children:y.quantity}),i.jsx("button",{onClick:()=>a(y.id,y.quantity+1),className:"w-8 h-8 flex items-center justify-center hover:bg-muted rounded-r-full transition-colors",children:i.jsx(xn,{className:"w-3 h-3"})})]})]},y.id))}),o.length>0&&m.length>0&&i.jsxs("div",{className:"px-5 py-4 border-t border-border",children:[i.jsx("h3",{className:"font-semibold text-sm mb-3",children:"You might also like"}),i.jsx("div",{className:"space-y-2",children:m.map(y=>i.jsxs("div",{className:"flex items-center gap-3",children:[i.jsx("img",{src:y.image,alt:y.name,className:"w-12 h-12 object-cover rounded-lg flex-shrink-0"}),i.jsxs("div",{className:"flex-1 min-w-0",children:[i.jsx("p",{className:"font-medium text-sm truncate",children:y.name}),i.jsxs("p",{className:"text-xs text-muted-foreground",children:["₦",y.price.toLocaleString()]})]}),i.jsx("button",{onClick:()=>b(y),className:"w-8 h-8 rounded-full border border-border flex items-center justify-center hover:bg-secondary transition-colors",children:i.jsx(xn,{className:"w-4 h-4"})})]},y.id))})]})]}),o.length>0&&i.jsxs("div",{className:"flex-shrink-0 p-5 pt-3 border-t border-border space-y-3",children:[i.jsxs("div",{className:"flex items-center gap-2 px-3 py-2.5 bg-secondary rounded-xl",children:[i.jsx(ar,{className:"w-4 h-4"}),i.jsxs("span",{className:"text-sm",children:["Earn ",i.jsxs("strong",{children:[u," points"]})," with this order"]})]}),i.jsxs("div",{className:"flex items-center justify-between",children:[i.jsx("span",{className:"font-medium",children:"Subtotal"}),i.jsxs("span",{className:"font-bold",children:["₦",c.toLocaleStr
336ing()]})]}),i.jsxs(ue,{onClick:n,className:"w-full h-12 text-base font-semibold rounded-full",size:"lg",children:["Go to checkout",i.jsx($s,{className:"w-5 h-5 ml-1"})]})]})]})})]})})},Gj={mySummary(){return he("/storefront/me/referrals")}},Ke=h.forwardRef(({className:e,type:t,...n},r)=>i.jsx("input",{type:t,className:Y("flex h-10 w-full rounded-md border border-input bg-background px-3 py-2 text-base ring-offset-background file:border-0 file:bg-transparent file:text-sm file:font-medium file:text-foreground placeholder:text-muted-foreground focus-visible:outline-none focus-visible:ring-2 focus-visible:ring-ring focus-visible:ring-offset-2 disabled:cursor-not-allowed disabled:opacity-50 md:text-sm",e),ref:r,...n}));Ke.displayName="Input";const yv="https://js.paystack.co/v1/inline.js",A5=1e4;function M5(){return new Promise((e,t)=>{if(window.PaystackPop){e(window.PaystackPop);return}const n=document.querySelector(`script[src="${yv}"]`),r=setTimeout(()=>{t(new Error("Paystack didn't load in time. Please retry."))},A5),s=()=>{clearTimeout(r),window.PaystackPop?e(window.PaystackPop):t(new Error("Failed to load Paystack"))},o=()=>{clearTimeout(r),t(new Error("Failed to load Paystack"))};if(n){n.addEventListener("load",s,{once:!0}),n.addEventListener("error",o,{once:!0});return}const a=document.createElement("script");a.src=yv,a.async=!0,a.onload=s,a.onerror=o,document.body.appendChild(a)})}async function qj(e,t){const n=await M5();if(!e.publicKey||!e.reference)throw new Error("Payment could not be started. Please retry.");const r=o=>void t.onSuccess((o==null?void 0:o.reference)??e.reference);n.setup({key:e.publicKey,email:e.email,amount:Math.round(e.amountKobo),ref:e.reference,currency:"NGN",metadata:e.metadata,onSuccess:r,callback:r,onCancel:t.onCancel,onClose:t.onClose}).openIframe()}const O5={bronze:500,silver:1500,gold:3e3,platinum:1/0},vv=e=>new Date(e).toLocaleDateString("en-US",{month:"short",day:"numeric",year:"numeric"}),I5=({isOpen:e,onClose:t})=>{yi(e);const{profile:n,isAuthenticated:r,refreshProfile:s}=Tt(),[o,a]=h.useState(""),[l,c]=h.useState(!1),{config:u}=hr(),d=Number((u==null?void 0:u.nairaPerPoint)??.1),[f,m]=h.useState("main"),[p,b]=h.useState([]),[x,y]=h.useState([]),[w,g]=h.useState(!1),[v,S]=h.useState(null),[j,C]=h.useState(null);h.useEffect(()=>{if(!e)return;let L=!1;return xi.getPaymentMethods().then(_=>{if(L)return;const $=_.find(J=>{var ee;return J.type==="transfer"&&((ee=J.bank)==null?void 0:ee.accountNumber)});C(($==null?void 0:$.bank)??null)}).catch(()=>{}),()=>{L=!0}},[e]),h.useEffect(()=>{if(!e||!r)return;let L=!1;return Gj.mySummary().then(_=>{L||S(_)}).catch(()=>{}),()=>{L=!0}},[e,r]),h.useEffect(()=>{if(!e||f!=="history"||!r)return;let L=!1;return g(!0),Promise.all([Cs.myWallet(),Cs.myPoints()]).then(([_,$])=>{L||(b(_),y($))}).catch(_=>{L||K.error(_.message??"Couldn't load history")}).finally(()=>{L||g(!1)}),()=>{L=!0}},[e,f,r]);const P=()=>{m("main"),t()};if(!n)return i.jsxs(i.Fragment,{children:[i.jsx("div",{className:Y("fixed inset-0 bg-foreground
336/50 z-50 transition-opacity duration-300 safari-fix",e?"opacity-100":"opacity-0 pointer-events-none"),onClick:P}),i.jsx("div",{className:Y("fixed z-50 bg-card shadow-none border border-border transition-all duration-300 flex flex-col safari-fix","inset-x-0 bottom-0 rounded-t-3xl max-h-[40vh]",e?"translate-y-0":"translate-y-full","lg:inset-auto lg:top-1/2 lg:left-1/2 lg:-translate-x-1/2 lg:rounded-2xl lg:w-full lg:max-w-md lg:max-h-[40vh]",e?"lg:-translate-y-1/2 lg:opacity-100":"lg:-translate-y-1/2 lg:opacity-0 lg:pointer-events-none"),children:i.jsxs("div",{className:"flex flex-col items-center justify-center text-center p-8 gap-3 flex-1",children:[i.jsx(kc,{className:"w-10 h-10 text-muted-foreground"}),i.jsx("h3",{className:"text-lg font-bold",children:"Sign in to view wallet"}),i.jsx(ue,{onClick:P,className:"rounded-full",children:"Close"})]})})]});const N=n.loyaltyTier,E=n.points,k=n.walletBalance,R=N==="platinum"?null:N==="bronze"?"Silver":N==="silver"?"Gold":"Platinum",M=O5[N],I=M===1/0?0:M-E,O=M===1/0?100:Math.min(100,E/M*100),H=()=>i.jsxs(i.Fragment,{children:[i.jsxs("div",{className:"bg-primary rounded-2xl p-5 text-primary-foreground mb-4",children:[i.jsxs("div",{className:"flex items-start justify-between",children:[i.jsxs("div",{children:[i.jsxs("div",{className:"flex items-center gap-2 mb-3 opacity-80",children:[i.jsx(kc,{className:"w-4 h-4"}),i.jsx("span",{className:"text-sm font-medium",children:"Wallet Balance"})]}),i.jsxs("p",{className:"text-3xl font-bold mb-1",children:["₦",Number(k).toLocaleString()]}),i.jsx("p",{className:"text-xs opacity-70",children:"Use at checkout to pay for your order."})]}),i.jsx("button",{onClick:()=>m("deposit"),"aria-label":"Add money to wallet",className:"w-10 h-10 rounded-full bg-primary-foreground/20 flex items-center justify-center hover:bg-primary-foreground/30 transition-colors flex-shrink-0",children:i.jsx(xn,{className:"w-5 h-5"})})]}),v&&v.rewardType==="wallet_credit"&&v.totalRewardPending>0&&i.jsxs("div",{className:"mt-3 pt-3 border-t border-primary-foreground/20 flex items-center justify-between text-xs opacity-90",children:[i.jsx("span",{children:"Pending from referrals"}),i.jsxs("span",{className:"font-semibold",children:["₦",v.totalRewardPending.toLocaleString()]})]})]}),i.jsxs("div",{className:"bg-primary rounded-2xl p-5 text-primary-foreground mb-4",children:[i.jsxs("div",{className:"flex items-center justify-between mb-3",children:[i.jsxs("div",{className:"flex items-center gap-2 opacity-80",children:[i.jsx(ar,{className:"w-4 h-4"}),i.jsx("span",{className:"text-sm font-medium capitalize",children:N})]}),i.jsx("span",{className:"text-xs opacity-60",children:"Loyalty Points"})]}),i.jsx("p",{className:"text-3xl font-bold mb-1",children:Number(E).toLocaleString()}),i.jsxs("p",{className:"text-xs opacity-70 mb-3",children:["Worth ₦",Math.floor(E*d).toLocaleString()]}),R&&i.jsxs("div",{children:[i.jsxs("div",{className:"flex items-center justify-between text-xs mb-2 opacity-80",children:[i.jsxs("span",{children:[I.toLocaleString()," pts to ",R]}),i.jsxs("span",{children:[Math.round(O),"%"]})]}),i.jsx("div",{className:"h-1.5 bg-primary-foreground/20 rounded-full overflow-hidden",children:i.jsx("div",{className:"h-full bg-primary-foreground rounded-full transition-all duration-500",style:{width:`${O}%`}})})]})]}),i.jsxs("div",{className:"grid grid-cols-2 gap-3 mb-4",children:[i.jsxs("button",{onClick:()=>m("redeem"),className:"flex flex-col items-center gap-2 p-4 bg-secondary rounded-xl hover:bg-secondary/80 transition-colors",children:[i.jsx(Jf,{className:"w-5 h-5"}),i.jsx("span",{className:"font-medium text-sm",children:"Redeem Points"})]}),i.jsxs("button",{onClick:()=>m("history"),className:"flex flex-col items-center gap-2 p-4 bg-secondary rounded-xl hover:bg-secondary/80 transition-colors",children:[i.jsx(TE,{className:"w-5 h-5"}),i.jsx("span",{className:"font-medium text-sm",children:"View History"})]})]}),i.jsxs("div",{className:"bg-secondary rounded-xl p-4 mb-4",children:[i.jsx("h3",{className:"font-semibold text-sm mb-3",children:"How to Earn Points"}),i.jsxs("div",{className:"space-y-2.5 text-sm",children:[i.jsx("div",{className:"flex items-center gap-3",children:i.jsx("span",{className:"text-muted-foreground",children:"Earn points on every paid order — your tier determines the rate."})}),i.jsx("div",{className:"flex items-center gap-3",children:i.jsx("span",{className:"text-muted-foreground",children:"Apply points at checkout to discount your order."})}),i.jsx("div",{className:"flex items-center gap-3",children:i.jsx("span",{className:"text-muted-foreground",children:"Refer a friend — earn a bonus when they place their first paid order."})})]})]}),v&&v.rewardType==="points"&&v.totalRewardPending>0&&i.jsxs("div",{className:"bg-secondary rounded-xl p-4 flex items-center justify-between text-sm",children:[i.jsx("span",{className:"text-muted-foreground",children:"Pending points from referrals"}),i.jsxs("span",{className:"font-semibold",children:[v.totalRewardPending.toLocaleStr
336ing()," pts"]})]})]}),B=()=>{const L=[...p.map(_=>({id:`w-${_.id}`,label:_.description,sub:vv(_.createdAt),createdAt:_.createdAt,sign:_.type==="credit"?"+":"-",amount:`₦${Number(_.amount).toLocaleString()}`,tone:_.type==="credit"?"credit":"debit"})),...x.map(_=>({id:`p-${_.id}`,label:_.description,sub:vv(_.createdAt),createdAt:_.createdAt,sign:_.type==="earned"?"+":"-",amount:`${Number(_.points).toLocaleString()} pts`,tone:"neutral"}))].sort((_,$)=>new Date($.createdAt).getTime()-new Date(_.createdAt).getTime());return i.jsxs(i.Fragment,{children:[i.jsxs("button",{onClick:()=>m("main"),className:"flex items-center gap-1 text-sm text-muted-foreground mb-4",children:[i.jsx(Fn,{className:"w-4 h-4"}),"Back"]}),i.jsx("h3",{className:"text-lg font-bold mb-4",children:"Transaction History"}),w?i.jsx("p",{className:"text-sm text-muted-foreground text-center py-8",children:"Loading…"}):L.length===0?i.jsx("p",{className:"text-sm text-muted-foreground text-center py-8",children:"No activity yet."}):i.jsx("div",{className:"space-y-2",children:L.map(_=>i.jsxs("div",{className:"flex items-center justify-between p-3 bg-secondary rounded-xl",children:[i.jsxs("div",{children:[i.jsx("p",{className:"font-medium text-sm",children:_.label}),i.jsx("p",{className:"text-xs text-muted-foreground",children:_.sub})]}),i.jsxs("span",{className:Y("font-bold text-sm",_.tone==="debit"?"text-destructive":_.tone==="credit"?"text-success":"text-foreground"),children:[_.sign,_.amount]})]},_.id))})]})},U=()=>i.jsxs(i.Fragment,{children:[i.jsxs("button",{onClick:()=>m("main"),className:"flex items-center gap-1 text-sm text-muted-foreground mb-4",children:[i.jsx(Fn,{className:"w-4 h-4"}),"Back"]}),i.jsxs("div",{className:"text-center py-8",children:[i.jsx("div",{className:"w-16 h-16 rounded-full bg-secondary flex items-center justify-center mx-auto mb-4",children:i.jsx(Jf,{className:"w-8 h-8"})}),i.jsx("h3",{className:"text-lg font-bold mb-2",children:"Redeem Your Points"}),i.jsxs("p",{className:"text-muted-foreground text-sm mb-4",children:["You have ",i.jsxs("strong",{children:[Number(E).toLocaleString()," points"]})," ","(worth ₦",Math.floor(E*d).toLocaleString(),")"]}),i.jsxs("p",{className:"text-sm text-muted-foreground",children:["Add items to your cart and apply your points at checkout —"," ",d>0?`1 point = ₦${d.toLocaleString()}`:"points are not redeemable right now","."]}),i.jsx(ue,{onClick:P,className:"mt-6 rounded-full",children:"Start Ordering"})]})]}),T=async()=>{const L=Math.round(Number(o));if(!Number.isFinite(L)||L<=0){K.error("Enter a valid amount");return}c(!0);try{const _=await Cs.startDeposit(L);await qj({publicKey:_.publicKey,email:_.email,amountKobo:_.amountKobo,reference:_.reference,metadata:{kind:"wallet_deposit"}},{onSuccess:async $=>{try{const J=await Cs.verifyDeposit($);K.success(`Wallet topped up with ₦${Number(J.amount).toLocaleString()}`),a(""),await s(),m("main")}catch(J){K.error(J.message??"We couldn't confirm the payment. Contact the store if you were charged.")}finally{c(!1)}},onCancel:()=>{c(!1),K.info("Top-up cancelled")},onClose:()=>c(!1)})}catch(_){c(!1),K.error(_.message??"Couldn't start the top-up")}},A=()=>{const L=$=>{var J;$&&((J=navigator.clipboard)==null||J.writeText($).then(()=>K.success("Copied")).catch(()=>{}))},_=[{label:"Bank",value:j==null?void 0:j.bankName},{label:"Account number",value:j==null?void 0:j.accountNumber},{label:"Account name",value:j==null?void 0:j.accountName}];return i.jsxs(i.Fragment,{children:[i.jsxs("button",{onClick:()=>m("main"),className:"flex items-center gap-1 text-sm text-muted-foreground mb-4",children:[i.jsx(Fn,{className:"w-4 h-4"}),"Back"]}),i.jsx("h3",{className:"text-lg font-bold mb-2",children:"Add money to wallet"}),i.jsxs("div",{className:"bg-secondary rounded-xl p-4 space-y-3 mb-4",children:[i.jsx("p",{className:"text-xs text-muted-foreground",children:"Pay with card"}),i.jsx(Ke,{type:"number",inputMode:"numeric",min:1,placeholder:"Amount (₦)",value:o,onChange:$=>a($.target.value)}),i.jsx(ue,{className:"w-full",onClick:T,disabled:l||!o,children:l?"Processing…":"Top up"})]}),i.jsx("p",{className:"text-sm text-muted-foreground mb-4",children:"Or transfer to the account below. Your wallet is credited once the transfer is confirmed."}),j!=null&&j.accountNumber?i.jsx("div",{className:"bg-secondary rounded-xl p-4 space-y-3",children:_.map($=>$.value?i.jsxs("div",{className:"flex items-center justify-between gap-3",children:[i.jsxs("div",{className:"min-w-0",children:[i.jsx("p",{className:"text-xs text-muted-foreground",children:$.label}),i.jsx("p",{className:"font-medium text-sm truncate",children:$.value})]}),$.label==="Account number"&&i.jsxs("button",{onClick:()=>L($.value),className:"flex items-center gap-1 text-xs text-primary flex-shrink-0",children:[i.jsx(Bm,{className:"w-3.5 h-3.5"}),"Copy"]})]},$.label):null)}):i.jsx("div",{className:"bg-secondary rounded-xl p-4 text-sm text-muted-foreground text-center",children:"Bank deposit details aren't available yet. Please contact the store to top up your wallet."})]})};return i.jsxs(i.Fragment,{children:[i.jsx("div",{className:Y("fixed inset-0 bg-foreground
336/50 z-50 transition-opacity duration-300 safari-fix",e?"opacity-100":"opacity-0 pointer-events-none"),onClick:P}),i.jsxs("div",{className:Y("fixed z-50 bg-card shadow-none border border-border transition-all duration-300 flex flex-col safari-fix","inset-x-0 bottom-0 rounded-t-3xl h-[85vh] max-h-[85vh]",e?"translate-y-0":"translate-y-full","lg:inset-auto lg:top-1/2 lg:left-1/2 lg:-translate-x-1/2 lg:rounded-2xl lg:w-full lg:max-w-md lg:h-auto lg:max-h-[80vh]",e?"lg:-translate-y-1/2 lg:opacity-100":"lg:-translate-y-1/2 lg:opacity-0 lg:pointer-events-none"),onClick:L=>L.stopPropagation(),children:[i.jsxs("div",{className:"flex items-center justify-between p-5 pb-3",children:[i.jsx("h2",{className:"text-lg font-bold",children:"Wallet & Rewards"}),i.jsx("button",{onClick:P,className:"w-9 h-9 rounded-full bg-secondary flex items-center justify-center",children:i.jsx(vt,{className:"w-4 h-4"})})]}),i.jsxs("div",{className:"flex-1 overflow-y-auto px-5 safe-bottom-pad",children:[f==="main"&&H(),f==="history"&&B(),f==="redeem"&&U(),f==="deposit"&&A()]})]})]})};function D5(){return!1}function L5(){return Promise.reject(new Error("Maps API key not configured"))}const wv={lat:6.5244,lng:3.3792};function _5(e){const t={};for(const n of(e==null?void 0:e.address_components)??[]){const r=n.types??[];(r.includes("locality")||!t.city&&r.includes("administrative_area_level_2"))&&(t.city=n.long_name),r.includes("administrative_area_level_1")&&(t.state=n.long_name),r.includes("country")&&(t.country=n.long_name)}return t}function F5({onConfirm:e,onCancel:t}){const n=h.useRef(null),r=h.useRef(null),s=h.useRef(null),[o,a]=h.useState(!0),[l,c]=h.useState(null),[u,d]=h.useState(null);return h.useEffect(()=>{let f=!1;const m=(p,b)=>{var x;(x=s.current)==null||x.geocode({location:{lat:p,lng:b}},(y,w)=>{f||(w==="OK"&&(y!=null&&y[0])?d({line1:y[0].formatted_address,latitude:p,longitude:b,..._5(y[0])}):d({line1:`${p.toFixed(5)}, ${b.toFixed(5)}`,latitude:p,longitude:b}))})};return L5().then(p=>{if(f||!n.current)return;s.current=new p.Geocoder;const b=x=>{const y=new p.Map(n.current,{center:x,zoom:16,disableDefaultUI:!0,zoomControl:!0}),w=new p.Marker({position:x,map:y,draggable:!0});r.current=w,w.addListener("dragend",()=>{const g=w.getPosition();m(g.lat(),g.lng())}),y.addListener("click",g=>{w.setPosition(g.latLng),m(g.latLng.lat(),g.latLng.lng())}),m(x.lat,x.lng),a(!1)};navigator.geolocation?navigator.geolocation.getCurrentPosition(x=>b({lat:x.coords.latitude,lng:x.coords.longitude}),()=>b(wv),{timeout:5e3}):b(wv)}).catch(p=>{f||(c(p.message??"Couldn't load the map"),a(!1))}),()=>{f=!0}},[]),i.jsxs("div",{className:"space-y-3",children:[i.jsxs("div",{className:"relative h-64 rounded-xl overflow-hidden border border-border",children:[i.jsx("div",{ref:n,className:"absolute inset-0"}),o&&i.jsx("div",{className:"absolute inset-0 flex items-center justify-center bg-secondary/60",children:i.jsx(vE,{className:"w-6 h-6 animate-spin text-muted-foreground"})}),l&&i.jsx("div",{className:"absolute inset-0 flex items-center justify-center text-center text-sm text-destructive p-4",children:l})]}),u&&i.jsxs("div",{className:"flex items-start gap-2 text-sm",children:[i.jsx(er,{className:"w-4 h-4 mt-0.5 text-primary flex-shrink-0"}),i.jsx("span",{className:"text-muted-foreground",children:u.line1})]}),i.jsxs("div",{className:"flex gap-2",children:[i.jsx(ue,{variant:"outline",className:"flex-1",onClick:t,children:"Cancel"}),i.jsx(ue,{className:"flex-1",disabled:!u,onClick:()=>u&&e(u),children:"Use this address"})]})]})}const Ql={list(){return he("/storefront/me/addresses")},get(e){return he(`/storefront/me/addresses/${e}`)},create(e){return he("/storefront/me/addresses",{method:"POST",body:JSON.stringify(e)})},update(e,t){return he(`/storefront/me/addresses/${e}`,{method:"PATCH",body:JSON.stringify(t)})},remove(e){return he(`/storefront/me/addresses/${e}`,{method:"DELETE"})}},V5=({isOpen:e,onClose:t})=>{yi(e);const{triggerHaptic:n}=mr();h.useEffect(()=>{e&&n("medium")},[e,n]);const{orderType:r,setOrderType:s,storeId:o,setStoreId:a,selectedAddressId:l,setSelectedAddressId:c}=Nn(),{isAuthenticated:u}=Tt(),{stores:d}=Kn(),[f,m]=h.useState([]),[p,b]=h.useState(""),[x,y]=h.useState(""),[w,g]=h.useState(!1);h.useEffect(()=>{!e||!u||r!=="delivery"||Ql.list().then(m).catch(()=>m([]))},[e,u,r]);const v=d.filter(k=>{if(!x.trim())return!0;const R=x.toLowerCase();return k.name.toLowerCase().includes(R)||k.address.toLowerCase().includes(R)}),S=k=>{n("success"),a(k),t()},j=k=>{n("success"),c(k),t()},C=async()=>{const k=p.trim();if(k){if(!u){K.error("Please sign in to save your delivery address");return}try{const R=await Ql.create({label:"Delivery",line1:k,isDefault:f.length===0});m(M=>[R,...M]),c(R.id),b(""),K.success("Address saved"),t()}catch(R){K.error(R.message??"Couldn't save address")}}},P=async k=>
336{if(!u){K.error("Please sign in to save your delivery address");return}try{const R=await Ql.create({label:"Delivery",line1:k.line1,city:k.city,state:k.state,country:k.country,latitude:k.latitude,longitude:k.longitude,isDefault:f.length===0});m(M=>[R,...M]),c(R.id),g(!1),n("success"),K.success("Address saved"),t()}catch(R){K.error(R.message??"Couldn't save address")}},N=()=>{n("light"),g(!1),t()},E=i.jsxs(i.Fragment,{children:[i.jsxs("div",{className:"flex items-center justify-between p-6 pb-4",children:[i.jsx("h2",{className:"text-xl font-bold",children:"Order details"}),i.jsx("button",{onClick:N,className:"w-10 h-10 rounded-full bg-secondary flex items-center justify-center active:scale-95 transition-transform",children:i.jsx(vt,{className:"w-5 h-5"})})]}),i.jsxs("div",{className:"px-6 pb-4",children:[i.jsxs("div",{className:"flex bg-secondary rounded-xl p-1 mb-4",children:[i.jsx("button",{onClick:()=>s("pickup"),className:Y("flex-1 py-2.5 px-4 rounded-lg font-semibold text-sm transition-all",r==="pickup"?"bg-card text-foreground shadow-sm":"text-muted-foreground"),children:"Pickup"}),i.jsx("button",{onClick:()=>s("delivery"),className:Y("flex-1 py-2.5 px-4 rounded-lg font-semibold text-sm transition-all",r==="delivery"?"bg-card text-foreground shadow-sm":"text-muted-foreground"),children:"Delivery"})]}),i.jsxs("div",{className:"relative",children:[i.jsx(er,{className:"absolute left-4 top-1/2 -translate-y-1/2 w-5 h-5 text-muted-foreground"}),r==="pickup"?i.jsx(Ke,{placeholder:"Search locations...",value:x,onChange:k=>y(k.target.value),className:"pl-12 h-12 rounded-xl bg-secondary border-0"}):i.jsx(Ke,{placeholder:"Type your address & phone number",value:p,onChange:k=>b(k.target.value),onKeyDown:k=>{k.key==="Enter"&&C()},className:"pl-12 h-12 rounded-xl bg-secondary border-0"})]})]}),i.jsx("div",{className:"flex-1 overflow-y-auto px-6 safe-bottom-pad",children:r==="pickup"?i.jsx("div",{className:"space-y-3",children:v.length===0?i.jsxs("div",{className:"flex flex-col items-center justify-center py-12 text-center text-muted-foreground",children:[i.jsx(er,{className:"w-8 h-8 mb-2"}),i.jsx("p",{children:"No stores available"})]}):v.map(k=>{const R=o===k.id,M=zp(k.openingHours??null),I=M?M.isOpen:k.isActive;return i.jsxs("div",{className:Y("flex items-center justify-between p-4 rounded-2xl border-2 transition-colors cursor-pointer",R?"border-primary bg-primary/5":"border-border hover:border-muted-foreground/30"),onClick:()=>S(k.id),children:[i.jsxs("div",{children:[i.jsx("h3",{className:"font-bold",children:k.name}),i.jsx("div",{className:"flex items-center gap-2 mt-1",children:i.jsxs("span",{className:Y("flex items-center gap-1 text-sm",I?"text-success":"text-destructive"),children:[i.jsx(Xo,{className:"w-3 h-3"}),M?M.label:I?"Open now":"Closed"]})}),i.jsx("p",{className:"text-sm text-muted-foreground mt-1",children:k.address})]}),i.jsx(ue,{variant:R?"default":"outline",size:"sm",disabled:!k.isActive,children:R?"Selected":"Pick"})]},k.id)})}):u?w?i.jsx("div",{className:"pb-2",children:i.jsx(F5,{onConfirm:P,onCancel:()=>g(!1)})}):i.jsxs("div",{className:"space-y-3",children:[p.trim()&&i.jsxs(ue,{onClick:C,variant:"outline",className:"w-full",children:[i.jsx(xn,{className:"h-4 w-4 mr-2"}),'Save "',p.trim(),'"']}),D5(),f.length===0?i.jsxs("div",{className:"flex flex-col items-center justify-center py-12 text-center",children:[i.jsx(er,{className:"w-8 h-8 text-muted-foreground mb-2"}),i.jsx("p",{className:"text-muted-foreground",children:"No saved addresses yet"}),i.jsx("p",{className:"text-sm text-muted-foreground mt-1",children:"Type your address above to save it"})]}):f.map(k=>{const R=l===k.id;return i.jsxs("div",{className:Y("flex items-center justify-between p-4 rounded-2xl border-2 transition-colors cursor-pointer",R?"border-primary bg-primary/5":"border-border hover:border-muted-foreground/30"),onClick:()=>j(k.id),children:[i.jsxs("div",{children:[i.jsx("h3",{className:"font-bold",children:k.label}),i.jsxs("p",{className:"text-sm text-muted-foreground mt-1",children:[k.line1,k.city&&`, ${k.city}`]})]}),i.jsx(ue,{variant:R?"default":"outline",size:"sm",children:R?"Selected":"Select"})]},k.id)})]}):i.jsxs("div",{className:"flex flex-col items-center justify-center py-12 text-center",children:[i.jsx("div",{className:"w-16 h-16 rounded-full bg-secondary flex items-center justify-center mb-4",children:i.jsx(er,{className:"w-8 h-8 text-muted-foreground"})}),i.jsx("p",{className:"text-muted-foreground",children:"Sign in to add a delivery address"})]})})]});return i.jsx(ti,{children:e&&i.jsxs(i.Fragment,{children:[i.jsx(xe.div,{initial:{opacity:0}
336,animate:{opacity:1},exit:{opacity:0},transition:{duration:.2},className:"fixed inset-0 bg-foreground/50 z-50 safari-fix",onClick:N}),i.jsx(xe.div,{initial:{y:"100%",opacity:.5},animate:{y:0,opacity:1},exit:{y:"100%",opacity:0},transition:{type:"spring",damping:25,stiffness:300},className:"fixed z-50 bg-card shadow-none border border-border flex flex-col safari-fix inset-x-0 bottom-0 rounded-t-3xl max-h-[85vh] lg:hidden",onClick:k=>k.stopPropagation(),children:E}),i.jsx("div",{className:"hidden lg:flex fixed inset-0 z-50 items-center justify-center pointer-events-none",children:i.jsx(xe.div,{initial:{opacity:0,scale:.95},animate:{opacity:1,scale:1},exit:{opacity:0,scale:.95},transition:{duration:.2,ease:"easeOut"},className:"bg-card shadow-lg border border-border flex flex-col safari-fix rounded-2xl w-full max-w-lg max-h-[80vh] pointer-events-auto",onClick:k=>k.stopPropagation(),children:E})})]})})};function $5(e,t){const[n,r]=h.useState(null),[s,o]=h.useState(null),[a,l]=h.useState(!!e);return h.useEffect(()=>{if(!e){r(null),l(!1);return}let c=!1;return l(!0),o(null),Oj.forStore(e,t).then(u=>{c||r(u)}).catch(u=>{c||o(u)}).finally(()=>{c||l(!1)}),()=>{c=!0}},[e,t]),{data:n,isLoading:a,error:s}}const Er="asap",B5=({isOpen:e,onClose:t})=>{yi(e);const{selectedTime:n,setSelectedTime:r,storeId:s}=Nn(),[o,a]=h.useState(pv()),[l,c]=h.useState(n||Er),u=h.useMemo(()=>{const g=pv();return Array.from({length:7},(v,S)=>$j(g,S))},[]),d=Ir(o,"yyyy-MM-dd"),{data:f,isLoading:m,error:p}=$5(s,d),b=(f==null?void 0:f.slots)??[],x=(f==null?void 0:f.asapAvailable)??!1,y=!m&&!p&&b.length===0&&!x;h.useEffect(()=>{var v;!f||(l===Er?x:b.some(S=>S.startsAt===l))||c(x?Er:((v=b[0])==null?void 0:v.startsAt)??"")},[f]);const w=()=>{var v;let g=l;g===Er&&!x&&(g=""),g||(g=((v=b[0])==null?void 0:v.startsAt)??""),g&&(r(g===Er?"ASAP":g),t())};return i.jsxs(i.Fragment,{children:[i.jsx("div",{className:Y("fixed inset-0 bg-foreground
336/50 z-50 transition-opacity duration-300 safari-fix",e?"opacity-100":"opacity-0 pointer-events-none"),onClick:t}),i.jsxs("div",{className:Y("fixed z-50 bg-card shadow-none border border-border transition-all duration-300 flex flex-col safari-fix","inset-x-0 bottom-0 rounded-t-3xl max-h-[80vh]",e?"translate-y-0":"translate-y-full","lg:inset-auto lg:top-1/2 lg:left-1/2 lg:-translate-x-1/2 lg:rounded-2xl lg:w-full lg:max-w-md lg:max-h-[70vh]",e?"lg:-translate-y-1/2 lg:opacity-100":"lg:-translate-y-1/2 lg:opacity-0 lg:pointer-events-none"),onClick:g=>g.stopPropagation(),children:[i.jsxs("div",{className:"flex items-center justify-between p-5 pb-3 border-b border-border",children:[i.jsx("h2",{className:"text-lg font-bold",children:"Select Date & Time"}),i.jsx("button",{onClick:t,className:"w-9 h-9 rounded-full bg-secondary flex items-center justify-center",children:i.jsx(vt,{className:"w-4 h-4"})})]}),i.jsx("div",{className:"px-4 py-3 border-b border-border",children:i.jsx("div",{className:"flex items-center gap-2 overflow-x-auto scrollbar-hide pb-1",children:u.map((g,v)=>{const S=Bp(g,o),j=v===0;return i.jsxs("button",{onClick:()=>{a(g),c("")},className:Y("flex flex-col items-center min-w-[60px] py-2 px-3 rounded-xl transition-all",S?"bg-primary text-primary-foreground":"bg-secondary hover:bg-secondary/80"),children:[i.jsx("span",{className:"text-xs font-medium",children:j?"Today":Ir(g,"EEE")}),i.jsx("span",{className:"text-lg font-bold",children:Ir(g,"d")}),i.jsx("span",{className:"text-[10px] opacity-70",children:Ir(g,"MMM")})]},g.toISOString())})})}),i.jsx("div",{className:"flex-1 overflow-y-auto p-4",children:s?m?i.jsx("p",{className:"text-sm text-muted-foreground text-center py-6",children:"Loading availability…"}):p?i.jsx("p",{className:"text-sm text-destructive text-center py-6",children:"Couldn't load slots — please try again."}):y?i.jsx("p",{className:"text-sm text-muted-foreground text-center py-6",children:"Closed on this day. Try another date."}):i.jsxs("div",{className:"space-y-2",children:[x&&i.jsxs("button",{onClick:()=>c(Er),className:Y("w-full flex items-center justify-between p-4 rounded-xl border transition-all",l===Er?"border-primary bg-primary/10":"border-border hover:bg-secondary/50"),children:[i.jsxs("div",{className:"text-left",children:[i.jsx("p",{className:"font-medium",children:"ASAP"}),i.jsx("p",{className:"text-sm text-muted-foreground",children:"Start now — typical 15-25 min"})]}),l===Er&&i.jsx("div",{className:"w-6 h-6 rounded-full bg-primary flex items-center justify-center",children:i.jsx(Mn,{className:"w-4 h-4 text-primary-foreground"})})]}),b.map(g=>{const v=new Date(g.startsAt),S=Ir(v,"h:mm a"),j=Ir(v,"EEE, MMM d");return i.jsxs("button",{onClick:()=>c(g.startsAt),className:Y("w-full flex items-center justify-between p-4 rounded-xl border transition-all",l===g.startsAt?"border-primary bg-primary/10":"border-border hover:bg-secondary/50"),children:[i.jsxs("div",{className:"text-left",children:[i.jsx("p",{className:"font-medium",children:S}),i.jsx("p",{className:"text-sm text-muted-foreground",children:j})]}),l===g.startsAt&&i.jsx("div",{className:"w-6 h-6 rounded-full bg-primary flex items-center justify-center",children:i.jsx(Mn,{className:"w-4 h-4 text-primary-foreground"})})]},g.startsAt)})]}):i.jsx("p",{className:"text-sm text-muted-foreground text-center py-6",children:"Pick a store first to see available times."})}),i.jsx("div",{className:"p-4 border-t border-border safe-bottom-pad",children:i.jsx("button",{onClick:w,disabled:y||m||!!p||!s,className:"w-full h-12 bg-primary text-primary-foreground rounded-full font-semibold disabled:opacity-50",children:"Confirm"})})]})]})},z5="1077207931550-oqi7fdqujckh8ent9rkk9dl5ulv10p5v.apps.googleusercontent.com",U5="https://accounts.google.com/gsi/client";let Cl=null;function W5(){return Cl||(Cl=new Promise((e,t)=>{var r,s;if((s=(r=window.google)==null?void 0:r.accounts)!=null&&s.id)return e();const n=document.createElement("script");n.src=U5,n.async=!0,n.defer=!0,n.onload=()=>e(),n.onerror=()=>t(new Error("Failed to load Google")),document.head.appendChild(n)}),Cl)}function Wp({text:e="continue_with",onSuccess:t}){const{loginWithGoogle:n}=Tt(),r=h.useRef(null);return h.useEffect(()=>{let s=!1;return W5().then(()=>
vendor: 6,090 bytes, line 336
336{if(s||!r.current)return;const o=window.google;o.accounts.id.initialize({client_id:z5,callback:async a=>{try{await n({businessId:gi(),idToken:a.credential}),t==null||t()}catch(l){K.error(l.message??"Google sign-in failed")}}}),o.accounts.id.renderButton(r.current,{theme:"outline",size:"large",shape:"pill",text:e,width:Math.min(r.current.offsetWidth||320,400)})}).catch(()=>{}),()=>{s=!0}},[n,t,e]),i.jsx("div",{ref:r,className:"w-full flex justify-center"})}const H5=({isOpen:e,onClose:t})=>{yi(e);const n=Je(),r=s=>{t(),n(s)};return i.jsxs(i.Fragment,{children:[i.jsx("div",{className:Y("fixed inset-0 bg-foreground/50 z-50 transition-opacity duration-300 safari-fix",e?"opacity-100":"opacity-0 pointer-events-none","lg:flex lg:items-center lg:justify-center"),onClick:t}),i.jsxs("div",{className:Y("fixed z-50 bg-card shadow-none border border-border transition-all duration-300 safari-fix","inset-x-0 bottom-0 rounded-t-3xl",e?"translate-y-0":"translate-y-full pointer-events-none invisible","lg:inset-auto lg:top-1/2 lg:left-1/2 lg:-translate-x-1/2 lg:rounded-2xl lg:w-full lg:max-w-md",e?"lg:-translate-y-1/2 lg:opacity-100 lg:visible lg:pointer-events-auto":"lg:-translate-y-1/2 lg:opacity-0 lg:pointer-events-none lg:invisible"),onClick:s=>s.stopPropagation(),children:[i.jsxs("div",{className:"flex items-center justify-between p-5 pb-3",children:[i.jsx("h2",{className:"text-lg font-bold",children:"Sign in"}),i.jsx("button",{onClick:t,className:"w-9 h-9 rounded-full bg-secondary flex items-center justify-center","aria-label":"Close",children:i.jsx(vt,{className:"w-4 h-4"})})]}),i.jsxs("div",{className:"px-5 pb-6 safe-bottom-pad space-y-3",children:[i.jsx("p",{className:"text-muted-foreground text-sm mb-2",children:"Sign in to save your orders, earn points, and more."}),i.jsx(ue,{onClick:()=>r("/login"),className:"w-full h-12 rounded-full",children:"Sign in"}),i.jsx(ue,{onClick:()=>r("/register"),variant:"outline",className:"w-full h-12 rounded-full",children:"Create an account"}),i.jsxs("div",{className:"relative my-1",children:[i.jsx("div",{className:"absolute inset-0 flex items-center",children:i.jsx("span",{className:"w-full border-t border-border"})}),i.jsx("div",{className:"relative flex justify-center text-xs uppercase",children:i.jsx("span",{className:"bg-card px-2 text-muted-foreground",children:"or"})})]}),i.jsx(Wp,{text:"continue_with",onSuccess:t})]})]})]})};var Kd="focusScope.autoFocusOnMount",Yd="focusScope.autoFocusOnUnmount",bv={bubbles:!1,cancelable:!0},K5="FocusScope",Hp=h.forwardRef((e,t)=>{const{loop:n=!1,trapped:r=!1,onMountAutoFocus:s,onUnmountAutoFocus:o,...a}=e,[l,c]=h.useState(null),u=bn(s),d=bn(o),f=h.useRef(null),m=Se(t,x=>c(x)),p=h.useRef({paused:!1,pause(){this.paused=!0},resume(){this.paused=!1}}).current;h.useEffect(()=>{if(r){let x=function(v){if(p.paused||!l)return;const S=v.target;l.contains(S)?f.current=S:Ar(f.current,{select:!0})},y=function(v){if(p.paused||!l)return;const S=v.relatedTarget;S!==null&&(l.contains(S)||Ar(f.current,{select:!0}))},w=function(v){if(document.activeElement===document.body)for(const j of v)j.removedNodes.length>0&&Ar(l)};document.addEventListener("focusin",x),document.addEventListener("focusout",y);const g=new MutationObserver(w);return l&&g.observe(l,{childList:!0,subtree:!0}),()=>{document.removeEventListener("focusin",x),document.removeEventListener("focusout",y),g.disconnect()}}},[r,l,p.paused]),h.useEffect(()=>{if(l){jv.add(p);const x=document.activeElement;if(!l.contains(x)){const w=new CustomEvent(Kd,bv);l.addEventListener(Kd,u),l.dispatchEvent(w),w.defaultPrevented||(Y5(J5(Qj(l)),{select:!0}),document.activeElement===x&&Ar(l))}return()=>{l.removeEventListener(Kd,u),setTimeout(()=>{const w=new CustomEvent(Yd,bv);l.addEventListener(Yd,d),l.dispatchEvent(w),w.defaultPrevented||Ar(x??document.body,{select:!0}),l.removeEventListener(Yd,d),jv.remove(p)},0)}}},[l,u,d,p]);const b=h.useCallback(x=>{if(!n&&!r||p.paused)return;const y=x.key==="Tab"&&!x.altKey&&!x.ctrlKey&&!x.metaKey,w=document.activeElement;if(y&&w){const g=x.currentTarget,[v,S]=G5(g);v&&S?!x.shiftKey&&w===S?(x.preventDefault(),n&&Ar(v,{select:!0})):x.shiftKey&&w===v&&(x.preventDefault(),n&&Ar(S,{select:!0})):w===g&&x.preventDefault()}},[n,r,p.paused]);return i.jsx(fe.div,{tabIndex:-1,...a,ref:m,onKeyDown:b})});Hp.displayName=K5;function Y5(e,{select:t=!1}={}){const n=document.activeElement;for(const r of e)if(Ar(r,{select:t}),document.activeElement!==n)return}function G5(e){const t=Qj(e),n=Sv(t,e),r=Sv(t.reverse(),e);return[n,r]}function Qj(e){const t=[],n=document.createTreeWalker(e,NodeFilter.SHOW_ELEMENT,{acceptNode:r=>{const s=r.tagName==="INPUT"&&r.type==="hidden";return r.disabled||r.hidden||s?NodeFilter.FILTER_SKIP:r.tabIndex>=0?NodeFilter.FILTER_ACCEPT:NodeFilter.FILTER_SKIP}});for(;n.nextNode();)t.push(n.currentNode);return t}function Sv(e,t){for(const n of e)if(!q5(n,{upTo:t}))return n}function q5(e,{upTo:t}){if(getComputedStyle(e).visibility==="hidden")return!0;for(;e;){if(t!==void 0&&e===t)return!1;if(getComputedStyle(e).display==="none")return!0;e=e.parentElement}return!1}function Q5(e){return e instanceof HTMLInputElement&&"select"in e}function Ar(e,{select:t=!1}={}){if(e&&e.focus){const n=document.activeElement;e.focus({preventScroll:!0}),e!==n&&Q5(e)&&t&&e.select()}}var jv=X5();function X5(){let e=[];return{add(t){const n=e[0];t!==n&&(n==null||n.pause()),e=Nv(e,t),e.unshift(t)},remove(t){var n;e=Nv(e,t),(n=e[0])==null||n.resume()}}}function Nv(e,t){const n=[...e],r=n.indexOf(t);return r!==-1&&n.splice(r,1),n}function J5(e){return e.filter(t=>t.tagName!=="A")}var Gd=0;function Xj(){h.useEffect(()=>{const e=document.querySelectorAll("[data-radix-focus-guard]");return document.body.insertAdjacentElement("afterbegin",e[0]??Cv()),document.body.insertAdjacentElement("beforeend",e[1]??Cv()),Gd++,()=>{Gd===1&&document.querySelectorAll("[data-radix-focus-guard]").forEach(t=>t.remove()),Gd--}},[])}function Cv(){const e=document.createElement("span");return e.setAttribute("data-radix-focus-guard",""),e.tabIndex=0,e.style.outline="none",e.style.opacity="0",e.
vendor: 4,758 bytes, line 336
336style.position="fixed",e.style.pointerEvents="none",e}var On=function(){return On=Object.assign||function(t){for(var n,r=1,s=arguments.length;r<s;r++){n=arguments[r];for(var o in n)Object.prototype.hasOwnProperty.call(n,o)&&(t[o]=n[o])}return t},On.apply(this,arguments)};function Jj(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 Z5(e,t,n){if(n||arguments.length===2)for(var r=0,s=t.length,o;r<s;r++)(o||!(r in t))&&(o||(o=Array.prototype.slice.call(t,0,r)),o[r]=t[r]);return e.concat(o||Array.prototype.slice.call(t))}var Xl="right-scroll-bar-position",Jl="width-before-scroll-bar",e_="with-scroll-bars-hidden",t_="--removed-body-scroll-bar-size";function qd(e,t){return typeof e=="function"?e(t):e&&(e.current=t),e}function n_(e,t){var n=h.useState(function(){return{value:e,callback:t,facade:{get current(){return n.value},set current(r){var s=n.value;s!==r&&(n.value=r,n.callback(r,s))}}}})[0];return n.callback=t,n.facade}var r_=typeof window<"u"?h.useLayoutEffect:h.useEffect,kv=new WeakMap;function s_(e,t){var n=n_(null,function(r){return e.forEach(function(s){return qd(s,r)})});return r_(function(){var r=kv.get(n);if(r){var s=new Set(r),o=new Set(e),a=n.current;s.forEach(function(l){o.has(l)||qd(l,null)}),o.forEach(function(l){s.has(l)||qd(l,a)})}kv.set(n,e)},[e]),n}function o_(e){return e}function i_(e,t){t===void 0&&(t=o_);var n=[],r=!1,s={read:function(){if(r)throw new Error("Sidecar: could not `read` from an `assigned` medium. `read` could be used only with `useMedium`.");return n.length?n[n.length-1]:e},useMedium:function(o){var a=t(o,r);return n.push(a),function(){n=n.filter(function(l){return l!==a})}},assignSyncMedium:function(o){for(r=!0;n.length;){var a=n;n=[],a.forEach(o)}n={push:function(l){return o(l)},filter:function(){return n}}},assignMedium:function(o){r=!0;var a=[];if(n.length){var l=n;n=[],l.forEach(o),a=n}var c=function(){var d=a;a=[],d.forEach(o)},u=function(){return Promise.resolve().then(c)};u(),n={push:function(d){a.push(d),u()},filter:function(d){return a=a.filter(d),n}}}};return s}function a_(e){e===void 0&&(e={});var t=i_(null);return t.options=On({async:!0,ssr:!1},e),t}var Zj=function(e){var t=e.sideCar,n=Jj(e,["sideCar"]);if(!t)throw new Error("Sidecar: please provide `sideCar` property to import the right car");var r=t.read();if(!r)throw new Error("Sidecar medium not found");return h.createElement(r,On({},n))};Zj.isSideCarExport=!0;function l_(e,t){return e.useMedium(t),Zj}var eN=a_(),Qd=function(){},Cu=h.forwardRef(function(e,t){var n=h.useRef(null),r=h.useState({onScrollCapture:Qd,onWheelCapture:Qd,onTouchMoveCapture:Qd}),s=r[0],o=r[1],a=e.forwardProps,l=e.children,c=e.className,u=e.removeScrollBar,d=e.enabled,f=e.shards,m=e.sideCar,p=e.noRelative,b=e.noIsolation,x=e.inert,y=e.allowPinchZoom,w=e.as,g=w===void 0?"div":w,v=e.gapMode,S=Jj(e,["forwardProps","children","className","removeScrollBar","enabled","shards","sideCar","noRelative","noIsolation","inert","allowPinchZoom","as","gapMode"]),j=m,C=s_([n,t]),P=On(On({},S),s);return h.createElement(h.Fragment,null,d&&h.createElement(j,{sideCar:eN,removeScrollBar:u,shards:f,noRelative:p,noIsolation:b,inert:x,setCallbacks:o,allowPinchZoom:!!y,lockRef:n,gapMode:v}),a?h.cloneElement(h.Children.only(l),On(On({},P),{ref:C})):h.createElement(g,On({},P,{className:c,ref:C}),l))});Cu.defaultProps={enabled:!0,removeScrollBar:!0,inert:!1};Cu.classNames={fullWidth:Jl,zeroRight:Xl};var c_=function(){if(typeof __webpack_nonce__<"u")return __webpack_nonce__};function u_(){if(!document)return null;var e=document.createElement("style");e.type="text/css";var t=c_();return t&&e.setAttribute("nonce",t),e}function d_(e,t){e.styleSheet?e.styleSheet.cssText=t:e.appendChild(document.createTextNode(t))}function f_(e){var t=document.head||document.getElementsByTagName("head")[0];t.appendChild(e)}var h_=function(){var e=0,t=null;return{add:function(n){e==0&&(t=u_())&&(d_(t,n),f_(t)),e++},remove:function(){e--,!e&&t&&(t.parentNode&&t.parentNode.removeChild(t),t=null)}}},m_=function(){var e=h_();return function(t,n){h.useEffect(function(){return e.add(t),function(){e.remove()}},[t&&n])}},tN=function(){var e=m_(),t=function(n){var r=n.styles,s=n.dynamic;return e(r,s),null};return t},p_={left:0,top:0,right:0,gap:0},Xd=function(e){return parseInt(e||"",10)||0},g_=function(e){var t=window.getComputedStyle(document.body),n=t[e==="padding"?"paddingLeft":"marginLeft"],r=t[e==="padding"?"paddingTop":"marginTop"],s=t[e==="padding"?"paddingRight":"marginRight"];
vendor: 4,224 bytes, lines 336-376
336return[Xd(n),Xd(r),Xd(s)]},x_=function(e){if(e===void 0&&(e="margin"),typeof window>"u")return p_;var t=g_(e),n=document.documentElement.clientWidth,r=window.innerWidth;return{left:t[0],top:t[1],right:t[2],gap:Math.max(0,r-n+t[2]-t[0])}},y_=tN(),Mo="data-scroll-locked",v_=function(e,t,n,r){var s=e.left,o=e.top,a=e.right,l=e.gap;return n===void 0&&(n="margin"),`
337  .`.concat(e_,` {
338   overflow: hidden `).concat(r,`;
339   padding-right: `).concat(l,"px ").concat(r,`;
340  }
341  body[`).concat(Mo,`] {
342    overflow: hidden `).concat(r,`;
343    overscroll-behavior: contain;
344    `).concat([t&&"position: relative ".concat(r,";"),n==="margin"&&`
345    padding-left: `.concat(s,`px;
346    padding-top: `).concat(o,`px;
347    padding-right: `).concat(a,`px;
348    margin-left:0;
349    margin-top:0;
350    margin-right: `).concat(l,"px ").concat(r,`;
351    `),n==="padding"&&"padding-right: ".concat(l,"px ").concat(r,";")].filter(Boolean).join(""),`
352  }
353  
354  .`).concat(Xl,` {
355    right: `).concat(l,"px ").concat(r,`;
356  }
357  
358  .`).concat(Jl,` {
359    margin-right: `).concat(l,"px ").concat(r,`;
360  }
361  
362  .`).concat(Xl," .").concat(Xl,` {
363    right: 0 `).concat(r,`;
364  }
365  
366  .`).concat(Jl," .").concat(Jl,` {
367    margin-right: 0 `).concat(r,`;
368  }
369  
370  body[`).concat(Mo,`] {
371    `).concat(t_,": ").concat(l,`px;
372  }
373`)},Pv=function(){var e=parseInt(document.body.getAttribute(Mo)||"0",10);return isFinite(e)?e:0},w_=function(){h.useEffect(function(){return document.body.setAttribute(Mo,(Pv()+1).toString()),function(){var e=Pv()-1;e<=0?document.body.removeAttribute(Mo):document.body.setAttribute(Mo,e.toString())}},[])},b_=function(e){var t=e.noRelative,n=e.noImportant,r=e.gapMode,s=r===void 0?"margin":r;w_();var o=h.useMemo(function(){return x_(s)},[s]);return h.createElement(y_,{styles:v_(o,!t,s,n?"":"!important")})},Lh=!1;if(typeof window<"u")try{var kl=Object.defineProperty({},"passive",{get:function(){return Lh=!0,!0}});window.addEventListener("test",kl,kl),window.removeEventListener("test",kl,kl)}catch{Lh=!1}var to=Lh?{passive:!1}:!1,S_=function(e){return e.tagName==="TEXTAREA"},nN=function(e,t){if(!(e instanceof Element))return!1;var n=window.getComputedStyle(e);return n[t]!=="hidden"&&!(n.overflowY===n.overflowX&&!S_(e)&&n[t]==="visible")},j_=function(e){return nN(e,"overflowY")},N_=function(e){return nN(e,"overflowX")},Ev=function(e,t){var n=t.ownerDocument,r=t;do{typeof ShadowRoot<"u"&&r instanceof ShadowRoot&&(r=r.host);var s=rN(e,r);if(s){var o=sN(e,r),a=o[1],l=o[2];if(a>l)return!0}r=r.parentNode}while(r&&r!==n.body);return!1},C_=function(e){var t=e.scrollTop,n=e.scrollHeight,r=e.clientHeight;return[t,n,r]},k_=function(e){var t=e.scrollLeft,n=e.scrollWidth,r=e.clientWidth;return[t,n,r]},rN=function(e,t){return e==="v"?j_(t):N_(t)},sN=function(e,t){return e==="v"?C_(t):k_(t)},P_=function(e,t){return e==="h"&&t==="rtl"?-1:1},E_=function(e,t,n,r,s){var o=P_(e,window.getComputedStyle(t).direction),a=o*r,l=n.target,c=t.contains(l),u=!1,d=a>0,f=0,m=0;do{if(!l)break;var p=sN(e,l),b=p[0],x=p[1],y=p[2],w=x-y-o*b;(b||w)&&rN(e,l)&&(f+=w,m+=b);var g=l.parentNode;l=g&&g.nodeType===Node.DOCUMENT_FRAGMENT_NODE?g.host:g}while(!c&&l!==document.body||c&&(t.contains(l)||t===l));return(d&&Math.abs(f)<1||!d&&Math.abs(m)<1)&&(u=!0),u},Pl=function(e){return"changedTouches"in e?[e.changedTouches[0].clientX,e.changedTouches[0].clientY]:[0,0]},Tv=function(e){return[e.deltaX,e.deltaY]},Rv=function(e){return e&&"current"in e?e.current:e},T_=function(e,t){return e[0]===t[0]&&e[1]===t[1]},R_=function(e){return`
374  .block-interactivity-`.concat(e,` {pointer-events: none;}
375  .allow-interactivity-`).concat(e,` {pointer-events: all;}
376`)},A_=0,no=[];function M_(e){var t=h.useRef([]),n=h.useRef([0,0]),r=h.useRef(),s=h.useState(A_++)[0],o=h.useState(tN)[0],a=h.useRef(e);h.useEffect(function(){a.current=e},[e]),h.useEffect(function(){if(e.inert){document.body.classList.add("block-interactivity-".concat(s));var x=Z5([e.lockRef.current],(e.shards||[]).map(Rv),!0).filter(Boolean);return x.forEach(function(y){return y.classList.add("allow-interactivity-".concat(s))}),function(){document.body.classList.remove("block-interactivity-".concat(s)),x.forEach(function(y){return y.classList.remove("allow-interactivity-".concat(s))})}}}
vendor: 4,301 bytes, line 376
376,[e.inert,e.lockRef.current,e.shards]);var l=h.useCallback(function(x,y){if("touches"in x&&x.touches.length===2||x.type==="wheel"&&x.ctrlKey)return!a.current.allowPinchZoom;var w=Pl(x),g=n.current,v="deltaX"in x?x.deltaX:g[0]-w[0],S="deltaY"in x?x.deltaY:g[1]-w[1],j,C=x.target,P=Math.abs(v)>Math.abs(S)?"h":"v";if("touches"in x&&P==="h"&&C.type==="range")return!1;var N=Ev(P,C);if(!N)return!0;if(N?j=P:(j=P==="v"?"h":"v",N=Ev(P,C)),!N)return!1;if(!r.current&&"changedTouches"in x&&(v||S)&&(r.current=j),!j)return!0;var E=r.current||j;return E_(E,y,x,E==="h"?v:S)},[]),c=h.useCallback(function(x){var y=x;if(!(!no.length||no[no.length-1]!==o)){var w="deltaY"in y?Tv(y):Pl(y),g=t.current.filter(function(j){return j.name===y.type&&(j.target===y.target||y.target===j.shadowParent)&&T_(j.delta,w)})[0];if(g&&g.should){y.cancelable&&y.preventDefault();return}if(!g){var v=(a.current.shards||[]).map(Rv).filter(Boolean).filter(function(j){return j.contains(y.target)}),S=v.length>0?l(y,v[0]):!a.current.noIsolation;S&&y.cancelable&&y.preventDefault()}}},[]),u=h.useCallback(function(x,y,w,g){var v={name:x,delta:y,target:w,should:g,shadowParent:O_(w)};t.current.push(v),setTimeout(function(){t.current=t.current.filter(function(S){return S!==v})},1)},[]),d=h.useCallback(function(x){n.current=Pl(x),r.current=void 0},[]),f=h.useCallback(function(x){u(x.type,Tv(x),x.target,l(x,e.lockRef.current))},[]),m=h.useCallback(function(x){u(x.type,Pl(x),x.target,l(x,e.lockRef.current))},[]);h.useEffect(function(){return no.push(o),e.setCallbacks({onScrollCapture:f,onWheelCapture:f,onTouchMoveCapture:m}),document.addEventListener("wheel",c,to),document.addEventListener("touchmove",c,to),document.addEventListener("touchstart",d,to),function(){no=no.filter(function(x){return x!==o}),document.removeEventListener("wheel",c,to),document.removeEventListener("touchmove",c,to),document.removeEventListener("touchstart",d,to)}},[]);var p=e.removeScrollBar,b=e.inert;return h.createElement(h.Fragment,null,b?h.createElement(o,{styles:R_(s)}):null,p?h.createElement(b_,{noRelative:e.noRelative,gapMode:e.gapMode}):null)}function O_(e){for(var t=null;e!==null;)e instanceof ShadowRoot&&(t=e.host,e=e.host),e=e.parentNode;return t}const I_=l_(eN,M_);var Kp=h.forwardRef(function(e,t){return h.createElement(Cu,On({},e,{ref:t,sideCar:I_}))});Kp.classNames=Cu.classNames;var D_=function(e){if(typeof document>"u")return null;var t=Array.isArray(e)?e[0]:e;return t.ownerDocument.body},ro=new WeakMap,El=new WeakMap,Tl={},Jd=0,oN=function(e){return e&&(e.host||oN(e.parentNode))},L_=function(e,t){return t.map(function(n){if(e.contains(n))return n;var r=oN(n);return r&&e.contains(r)?r:(console.error("aria-hidden",n,"in not contained inside",e,". Doing nothing"),null)}).filter(function(n){return!!n})},__=function(e,t,n,r){var s=L_(t,Array.isArray(e)?e:[e]);Tl[n]||(Tl[n]=new WeakMap);var o=Tl[n],a=[],l=new Set,c=new Set(s),u=function(f){!f||l.has(f)||(l.add(f),u(f.parentNode))};s.forEach(u);var d=function(f){!f||c.has(f)||Array.prototype.forEach.call(f.children,function(m){if(l.has(m))d(m);else try{var p=m.getAttribute(r),b=p!==null&&p!=="false",x=(ro.get(m)||0)+1,y=(o.get(m)||0)+1;ro.set(m,x),o.set(m,y),a.push(m),x===1&&b&&El.set(m,!0),y===1&&m.setAttribute(n,"true"),b||m.setAttribute(r,"true")}catch(w){console.error("aria-hidden: cannot operate on ",m,w)}})};return d(t),l.clear(),Jd++,function(){a.forEach(function(f){var m=ro.get(f)-1,p=o.get(f)-1;ro.set(f,m),o.set(f,p),m||(El.has(f)||f.removeAttribute(r),El.delete(f)),p||f.removeAttribute(n)}),Jd--,Jd||(ro=new WeakMap,ro=new WeakMap,El=new WeakMap,Tl={})}},iN=function(e,t,n){n===void 0&&(n="data-aria-hidden");var r=Array.from(Array.isArray(e)?e:[e]),s=D_(e);return s?(r.push.apply(r,Array.from(s.querySelectorAll("[aria-live]"))),__(r,s,n,"aria-hidden")):function(){return null}},ku="Dialog",[aN]=qs(ku),[F_,Cn]=aN(ku),lN=e=>{const{__scopeDialog:t,children:n,open:r,defaultOpen:s,onOpenChange:o,modal:a=!0}=e,l=h.useRef(null),c=h.useRef(null),[u,d]=ba({prop:r,defaultProp:s??!1,onChange:o,caller:ku});return i.jsx(F_,{scope:t,triggerRef:l,contentRef:c,contentId:To(),titleId:To(),descriptionId:To(),open:u,onOpenChange:d,onOpenToggle:h.useCallback(()=>d(f=>!f),[d]),modal:a,children:n})};lN.displayName=ku;var cN="DialogTrigger",V_=h.forwardRef((e,t)=>
vendor: 5,850 bytes, lines 376-380
376{const{__scopeDialog:n,...r}=e,s=Cn(cN,n),o=Se(t,s.triggerRef);return i.jsx(fe.button,{type:"button","aria-haspopup":"dialog","aria-expanded":s.open,"aria-controls":s.contentId,"data-state":qp(s.open),...r,ref:o,onClick:oe(e.onClick,s.onOpenToggle)})});V_.displayName=cN;var Yp="DialogPortal",[$_,uN]=aN(Yp,{forceMount:void 0}),dN=e=>{const{__scopeDialog:t,forceMount:n,children:r,container:s}=e,o=Cn(Yp,t);return i.jsx($_,{scope:t,forceMount:n,children:h.Children.map(r,a=>i.jsx(ai,{present:n||o.open,children:i.jsx(iu,{asChild:!0,container:s,children:a})}))})};dN.displayName=Yp;var Bc="DialogOverlay",fN=h.forwardRef((e,t)=>{const n=uN(Bc,e.__scopeDialog),{forceMount:r=n.forceMount,...s}=e,o=Cn(Bc,e.__scopeDialog);return o.modal?i.jsx(ai,{present:r||o.open,children:i.jsx(z_,{...s,ref:t})}):null});fN.displayName=Bc;var B_=Qo("DialogOverlay.RemoveScroll"),z_=h.forwardRef((e,t)=>{const{__scopeDialog:n,...r}=e,s=Cn(Bc,n);return i.jsx(Kp,{as:B_,allowPinchZoom:!0,shards:[s.contentRef],children:i.jsx(fe.div,{"data-state":qp(s.open),...r,ref:t,style:{pointerEvents:"auto",...r.style}})})}),Us="DialogContent",hN=h.forwardRef((e,t)=>{const n=uN(Us,e.__scopeDialog),{forceMount:r=n.forceMount,...s}=e,o=Cn(Us,e.__scopeDialog);return i.jsx(ai,{present:r||o.open,children:o.modal?i.jsx(U_,{...s,ref:t}):i.jsx(W_,{...s,ref:t})})});hN.displayName=Us;var U_=h.forwardRef((e,t)=>{const n=Cn(Us,e.__scopeDialog),r=h.useRef(null),s=Se(t,n.contentRef,r);return h.useEffect(()=>{const o=r.current;if(o)return iN(o)},[]),i.jsx(mN,{...e,ref:s,trapFocus:n.open,disableOutsidePointerEvents:!0,onCloseAutoFocus:oe(e.onCloseAutoFocus,o=>{var a;o.preventDefault(),(a=n.triggerRef.current)==null||a.focus()}),onPointerDownOutside:oe(e.onPointerDownOutside,o=>{const a=o.detail.originalEvent,l=a.button===0&&a.ctrlKey===!0;(a.button===2||l)&&o.preventDefault()}),onFocusOutside:oe(e.onFocusOutside,o=>o.preventDefault())})}),W_=h.forwardRef((e,t)=>{const n=Cn(Us,e.__scopeDialog),r=h.useRef(!1),s=h.useRef(!1);return i.jsx(mN,{...e,ref:t,trapFocus:!1,disableOutsidePointerEvents:!1,onCloseAutoFocus:o=>{var a,l;(a=e.onCloseAutoFocus)==null||a.call(e,o),o.defaultPrevented||(r.current||(l=n.triggerRef.current)==null||l.focus(),o.preventDefault()),r.current=!1,s.current=!1},onInteractOutside:o=>{var c,u;(c=e.onInteractOutside)==null||c.call(e,o),o.defaultPrevented||(r.current=!0,o.detail.originalEvent.type==="pointerdown"&&(s.current=!0));const a=o.target;((u=n.triggerRef.current)==null?void 0:u.contains(a))&&o.preventDefault(),o.detail.originalEvent.type==="focusin"&&s.current&&o.preventDefault()}})}),mN=h.forwardRef((e,t)=>{const{__scopeDialog:n,trapFocus:r,onOpenAutoFocus:s,onCloseAutoFocus:o,...a}=e,l=Cn(Us,n),c=h.useRef(null),u=Se(t,c);return Xj(),i.jsxs(i.Fragment,{children:[i.jsx(Hp,{asChild:!0,loop:!0,trapped:r,onMountAutoFocus:s,onUnmountAutoFocus:o,children:i.jsx(za,{role:"dialog",id:l.contentId,"aria-describedby":l.descriptionId,"aria-labelledby":l.titleId,"data-state":qp(l.open),...a,ref:u,onDismiss:()=>l.onOpenChange(!1)})}),i.jsxs(i.Fragment,{children:[i.jsx(H_,{titleId:l.titleId}),i.jsx(Y_,{contentRef:c,descriptionId:l.descriptionId})]})]})}),Gp="DialogTitle",pN=h.forwardRef((e,t)=>{const{__scopeDialog:n,...r}=e,s=Cn(Gp,n);return i.jsx(fe.h2,{id:s.titleId,...r,ref:t})});pN.displayName=Gp;var gN="DialogDescription",xN=h.forwardRef((e,t)=>{const{__scopeDialog:n,...r}=e,s=Cn(gN,n);return i.jsx(fe.p,{id:s.descriptionId,...r,ref:t})});xN.displayName=gN;var yN="DialogClose",vN=h.forwardRef((e,t)=>{const{__scopeDialog:n,...r}=e,s=Cn(yN,n);return i.jsx(fe.button,{type:"button",...r,ref:t,onClick:oe(e.onClick,()=>s.onOpenChange(!1))})});vN.displayName=yN;function qp(e){return e?"open":"closed"}var wN="DialogTitleWarning",[LV,bN]=mP(wN,{contentName:Us,titleName:Gp,docsSlug:"dialog"}),H_=({titleId:e})=>{const t=bN(wN),n=`\`${t.contentName}\` requires a \`${t.titleName}\` for the component to be accessible for screen reader users.
377
378If you want to hide the \`${t.titleName}\`, you can wrap it with our VisuallyHidden component.
379
380For more information, see https://radix-ui.com/primitives/docs/components/${t.docsSlug}`;return h.useEffect(()=>{e&&(document.getElementById(e)||console.error(n))},[n,e]),null},K_="DialogDescriptionWarning",Y_=({contentRef:e,descriptionId:t})=>{const r=`Warning: Missing \`Description\` or \`aria-describedby={undefined}\` for {${bN(K_).contentName}}.`;return h.useEffect(()=>{var o;const s=(o=e.current)==null?void 0:o.getAttribute("aria-describedby");t&&s&&(document.getElementById(t)||console.warn(r))},[r,e,t]),null},SN=lN,jN=dN,Pu=fN,Eu=hN,Tu=pN,Ru=xN,NN=vN;const G_=SN,q_=jN,CN=h.forwardRef(({className:e,...t},n)=>i.jsx(Pu,{className:Y("fixed inset-0 z-50 bg-black/80 data-[state=open]:animate-in data-[state=closed]:animate-out data-[state=closed]:fade-out-0 data-[state=open]:fade-in-0",e),...t,ref:n}));CN.displayName=Pu.displayName;const Q_=cu("fixed z-50 gap-4 bg-background p-6 shadow-lg transition ease-in-out data-[state=open]:animate-in data-[state=closed]:animate-out data-[state=closed]:duration-300 data-[state=open]:duration-500",{variants:{side:{top:"inset-x-0 top-0 border-b data-[state=closed]:slide-out-to-top data-[state=open]:slide-in-from-top",bottom:"inset-x-0 bottom-0 border-t data-[state=closed]:slide-out-to-bottom data-[state=open]:slide-in-from-bottom",left:"inset-y-0 left-0 h-full w-3/4 border-r data-[state=closed]:slide-out-to-left data-[state=open]:slide-in-from-left sm:max-w-sm",right:"inset-y-0 right-0 h-full w-3/4  border-l data-[state=closed]:slide-out-to-right data-[state=open]:slide-in-from-right sm:max-w-sm"}},defaultVariants:{side:"right"}}),kN=h.forwardRef(({side:e="right",className:t,children:n,...r},s)=>i.jsxs(q_,{children:[i.jsx(CN,{}),i.jsxs(Eu,{ref:s,className:Y(Q_({side:e}),t),...r,children:[n,i.jsxs(NN,{className:"absolute right-4 top-4 roun
380ded-sm opacity-70 ring-offset-background transition-opacity data-[state=open]:bg-secondary hover:opacity-100 focus:outline-none focus:ring-2 focus:ring-ring focus:ring-offset-2 disabled:pointer-events-none",children:[i.jsx(vt,{className:"h-4 w-4"}),i.jsx("span",{className:"sr-only",children:"Close"})]})]})]}));kN.displayName=Eu.displayName;const PN=({className:e,...t})=>i.jsx("div",{className:Y("flex flex-col space-y-2 text-center sm:text-left",e),...t});PN.displayName="SheetHeader";const EN=h.forwardRef(({className:e,...t},n)=>i.jsx(Tu,{ref:n,className:Y("text-lg font-semibold text-foreground",e),...t}));EN.displayName=Tu.displayName;const X_=h.forwardRef(({className:e,...t},n)=>i.jsx(Ru,{ref:n,className:Y("text-sm text-muted-foreground",e),...t}));X_.displayName=Ru.displayName;const J_=SN,Z_=jN,TN=h.forwardRef(({className:e,...t},n)=>i.jsx(Pu,{ref:n,className:Y("fixed inset-0 z-50 bg-black/80 data-[state=open]:animate-in data-[state=closed]:animate-out data-[state=closed]:fade-out-0 data-[state=open]:fade-in-0",e),...t}));TN.displayName=Pu.displayName;const RN=h.forwardRef(({className:e,children:t,...n},r)=>i.jsxs(Z_,{children:[i.jsx(TN,{}),i.jsxs(Eu,{ref:r,className:Y("fixed left-[50%] top-[50%] z-50 grid w-full max-w-lg translate-x-[-50%] translate-y-[-50%] gap-4 border bg-background p-6 shadow-lg duration-200 data-[state=open]:animate-in data-[state=closed]:animate-out data-[state=closed]:fade-out-0 data-[state=open]:fade-in-0 data-[state=closed]:zoom-out-95 data-[state=open]:zoom-in-95 data-[state=closed]:slide-out-to-left-1/2 data-[state=closed]:slide-out-to-top-[48%] data-[state=open]:slide-in-from-left-1/2 data-[state=open]:slide-in-from-top-[48%] sm:rounded-lg",e),...n,children:[t,i.jsxs(NN,{className:"absolute right-4 top-4 roun
380ded-sm opacity-70 ring-offset-background transition-opacity data-[state=open]:bg-accent data-[state=open]:text-muted-foreground hover:opacity-100 focus:outline-none focus:ring-2 focus:ring-ring focus:ring-offset-2 disabled:pointer-events-none",children:[i.jsx(vt,{className:"h-4 w-4"}),i.jsx("span",{className:"sr-only",children:"Close"})]})]})]}));RN.displayName=Eu.displayName;const AN=({className:e,...t})=>i.jsx("div",{className:Y("flex flex-col space-y-1.5 text-center sm:text-left",e),...t});AN.displayName="DialogHeader";const MN=h.forwardRef(({className:e,...t},n)=>i.jsx(Tu,{ref:n,className:Y("text-lg font-semibold leading-none tracking-tight",e),...t}));MN.displayName=Tu.displayName;const eF=h.forwardRef(({className:e,...t},n)=>i.jsx(Ru,{ref:n,className:Y("text-sm text-muted-foreground",e),...t}));eF.displayName=Ru.displayName;const Zd=768;function tF(){const[e,t]=h.useState(void 0);return h.useEffect(()=>{const n=window.matchMedia(`(max-width: ${Zd-1}px)`),r=()=>{t(window.innerWidth<Zd)};return n.addEventListener("change",r),t(window.innerWidth<Zd),()=>n.removeEventListener("change",r)},[]),!!e}const nF=[{key:"monday",label:"Monday"},{key:"tuesday",label:"Tuesday"},{key:"wednesday",label:"Wednesday"},{key:"thursday",label:"Thursday"},{key:"friday",label:"Friday"},{key:"saturday",label:"Saturday"},{key:"sunday",label:"Sunday"}],Av=()=>{const{store:e}=Kn(),t=new Date().toLocaleDateString("en-US",{weekday:"long"}).toLowerCase(),n=zp((e==null?void 0:e.openingHours)??null);return i.jsxs("div",{className:"space-y-6",children:[n&&i.jsxs("div",{className:Y("flex items-center gap-2 text-sm font-medium rounded-lg px-3 py-2",n.isOpen?"bg-success/10 text-success":"bg-muted text-muted-foreground"),children:[i.jsx(Xo,{className:"w-4 h-4"}),i.jsx("span",{children:n.label})]}),i.jsxs("div",{children:[i.jsxs("div",{className:"flex items-center gap-2 mb-3",children:[i.jsx(Xo,{className:"w-5 h-5 text-primary"}),i.jsx("h3",{className:"font-semibold",children:"Operating Hours"})]}),i.jsx("div",{className:"space-y-2 pl-7",children:nF.map(({key:r,label:s})=>{var c;const o=(c=e==null?void 0:e.openingHours)==null?void 0:c[r],a=o?o.closed?"Closed":`${o.open} – ${o.close}`:"Hours not set",l=r===t;return i.jsxs("div",{className:`flex justify-between text-sm py-1.5 px-3 rounded-lg ${l?"bg-primary/10 font-medium":""}`,children:[i.jsxs("span",{className:l?"text-primary":"text-muted-foreground",children:[s,l&&i.jsx("span",{className:"ml-2 text-xs",children:"(Today)"})]}),i.jsx("span",{children:a})]},r)})})]}),e&&i.jsxs("div",{children:[i.jsxs("div",{className:"flex items-center gap-2 mb-3",children:[i.jsx(er,{className:"w-5 h-5 text-primary"}),i.jsx("h3",{className:"font-semibold",children:"Location"})]}),i.jsxs("div",{className:"pl-7 space-y-1",children:[i.jsx("p",{className:"text-sm",children:e.address}),(e.city||e.state)&&i.jsx("p",{className:"text-sm text-muted-foreground",children:[e.city,e.state].filter(Boolean).join(", ")})]})]}),e&&i.jsxs("div",{children:[i.jsxs("div",{className:"flex items-center gap-2 mb-3",children:[i.jsx(xx,{className:"w-5 h-5 text-primary"}),i.jsx("h3",{className:"font-semibold",children:"Contact"})]}),i.jsxs("div",{className:"pl-7 space-y-2",children:[e.phone&&i.jsxs("div",{className:"flex items-center gap-2 text-sm",children:[i.jsx(xx,{className:"w-4 h-4 text-muted-foreground"}),i.jsx("span",{children:e.phone})]}),e.email&&i.jsxs("div",{className:"flex items-center gap-2 text-sm",children:[i.jsx(bE,{className:"w-4 h-4 text-muted-foreground"}),i.jsx("span",{children:e.email})]})]})]}),i.jsx("div",{className:"pt-4 border-t border-border",children:i.jsx("p",{className:"text-xs text-muted-foreground text-center",children:"Holiday hours may vary. Please call ahead to confirm."})})]})},rF=({isOpen:e,onClose:t})=>tF()?i.jsx(G_,{open:e,onOpenChange:t,children:i.jsxs(kN,{side:"bottom",className:"rounded-t-3xl max-h-[85vh] overflow-y-auto",children:[i.jsx(PN,{className:"text-left pb-4",children:i.jsx(EN,{className:"text-xl",children:"Store Information"})}),i.jsx(Av,{})]})}):i.jsx(J_,{open:e,onOpenChange:t,children:i.jsxs(RN,{className:"sm:max-w-md",children:[i.jsx(AN,{children:i.jsx(MN,{className:"text-xl",children:"Store Information"})}),i.jsx(Av,{})]})}),sF=()=>{const e=Je(),[t,n]=h.useState([]),[r,s]=h.useState(!0),[o]=Vj("data_saver");if(h.useEffect(()=>
380{if(o){s(!1);return}let l=!1;return(async()=>{try{const c=await xi.getBanners();l||n(c)}catch{l||n([])}finally{l||s(!1)}})(),()=>{l=!0}},[o]),o||r||t.length===0)return null;const a=l=>{l.actionUrl&&(l.actionUrl.startsWith("http")?window.location.href=l.actionUrl:e(l.actionUrl))};return i.jsx("div",{className:"py-4 max-w-7xl mx-auto",children:i.jsx("div",{className:"flex gap-4 overflow-x-auto scrollbar-hide pb-2 px-4 lg:px-6 lg:grid lg:grid-cols-3 lg:overflow-visible",children:t.map(l=>{const c=l.theme==="dark",u=c?"bg-foreground":"bg-secondary";return i.jsx("div",{role:l.actionUrl?"button":void 0,onClick:()=>a(l),className:`${u} rounded-2xl overflow-hidden flex-shrink-0 w-[85vw] sm:w-[320px] lg:w-full cursor-pointer group`,children:i.jsxs("div",{className:"flex h-32 sm:h-36",children:[i.jsxs("div",{className:"flex-1 p-4 flex flex-col justify-between",children:[i.jsxs("div",{children:[i.jsx("h3",{className:`font-bold text-lg ${c?"text-background":"text-foreground"}`,children:l.title}),l.description&&i.jsx("p",{className:`text-sm ${c?"text-background/70":"text-muted-foreground"}`,children:l.description})]}),l.actionText&&i.jsxs("div",{className:`flex items-center gap-1 text-sm font-medium ${c?"text-background":"text-foreground"} group-hover:gap-2 transition-all`,children:[l.actionText,i.jsx($s,{className:"w-4 h-4"})]})]}),i.jsx("div",{className:"w-32 sm:w-36",children:i.jsx("img",{src:l.imageUrl,alt:l.title,className:"w-full h-full object-cover"})})]})},l.id)})})})},oF=({onCheckout:e})=>{const{items:t,updateQuantity:n,subtotal:r,pointsToEarn:s}=Nn();return i.jsx("div",{className:"hidden lg:block sticky top-20 h-fit will-change-transform",children:i.jsxs("div",{className:"bg-card rounded-2xl border border-border shadow-card overflow-hidden",children:[i.jsx("div",{className:"p-4 border-b border-border",children:i.jsxs("h2",{className:"text-lg font-bold flex items-center gap-2",children:[i.jsx(Um,{className:"w-5 h-5"}),"Your Order"]})}),i.jsx("div",{className:"max-h-[400px] overflow-y-auto",children:t.length===0?i.jsxs("div",{className:"flex flex-col items-center justify-center py-12 text-center px-5",children:[i.jsx("div",{className:"w-14 h-14 rounded-full bg-secondary flex items-center justify-center mb-3",children:i.jsx("span",{className:"text-2xl",children:"🛒"})}),i.jsx("p",{className:"text-muted-foreground text-sm",children:"Your cart is empty"}),i.jsx("p",{className:"text-xs text-muted-foreground mt-1",children:"Add items to get started"})]}):i.jsx("div",{className:"p-4 space-y-3",children:t.map(o=>i.jsxs("div",{className:"flex gap-3",children:[i.jsx("img",{src:o.menuItem.image,alt:o.menuItem.name,className:"w-12 h-12 object-cover rounded-xl flex-shrink-0"}),i.jsxs("div",{className:"flex-1 min-w-0",children:[i.jsx("h3",{className:"font-semibold text-sm truncate",children:o.menuItem.name}),i.jsxs("p",{className:"text-sm font-bold mt-0.5",children:["₦",(zs(o.menuItem,o.selectedOptions)*o.quantity).toLocaleString()]})]}),i.jsxs("div",{className:"flex items-center bg-secondary rounded-full h-8",children:[i.jsx("button",{onClick:()=>n(o.id,o.quantity-1),className:"w-7 h-7 flex items-center justify-center hover:bg-muted rounded-l-full transition-colors",children:i.jsx(Cc,{className:"w-3 h-3"})}),i.jsx("span",{className:"w-5 text-center font-semibold text-xs",children:o.quantity}),i.jsx("button",{onClick:()=>n(o.id,o.quantity+1),className:"w-7 h-7 flex items-center justify-center hover:bg-muted rounded-r-full transition-colors",children:i.jsx(xn,{className:"w-3 h-3"})})]})]},o.id))})}),t.length>0&&i.jsxs("div",{className:"p-4 border-t border-border space-y-3",children:[i.jsxs("div",{className:"flex items-center gap-2 px-3 py-2 bg-secondary rounded-xl",children:[i.jsx(ar,{className:"w-4 h-4"}),i.jsxs("span",{className:"text-sm",children:["Earn ",i.jsxs("strong",{children:[s," points"]})]})]}),i.jsxs("div",{className:"flex items-center justify-between",children:[i.jsx("span",{className:"font-medium",children:"Subtotal"}),i.jsxs("span",{className:"font-bold",children:["₦",r.toLocaleString()]})]}),i.jsxs(ue,{onClick:e,className:"w-full h-11 text-base font-semibold rounded-full",size:"lg",children:["Checkout",i.jsx($s,{className:"w-5 h-5 ml-1"})]})]})]})})},ON=()=>{const{config:e}=hr(),[t,n]=h.useState([]);h.useEffect(()=>{let a=!1;return xi.getPages().then(l=>{if(a)return;const c=(l??[]).filter(u=>u.status==="published").sort((u,d)=>u.position-d.position);n(c)}).catch(()=>{}),()=>{a=!0}},[]);const r=(e==null?void 0:e.storeName)??"",s=new Date().getFullYear(),o=r?`© ${s} ${r}. All rights reserved.`:`© ${s}. All rights reserved.`;return i.jsx("footer",{className:"border-t border-border bg-card mt-8 mb-20 lg:mb-0",children:i.jsxs("div",{className:"max-w-7xl mx-auto px-4 lg:px-6 py-6",children:[i.jsxs("div",{className:"lg:hidden space-y-4",children:[t.length>0&&i.jsx("div",{className:"flex flex-wrap items-center gap-4",children:t.map(a=>i.jsx(Oc,{to:`/p/${a.slug}`,className:"text-sm text-muted-foreground hover:text-foreground transition-colors",children:a.name},a.id))}),i.jsx("p",{className:"text-xs text-muted-foreground",children:o})]}),i.jsxs("div",{className:"hidden lg:flex items-center justify-between",children:[i.jsx("div",{className:"flex items-center gap-6",children:t.map(a=>i.jsx(Oc,{to:`/p/${a.slug}`,className:"text-sm text-muted-foreground hover:text-foreground transition-colors",children:a.name},a.id))}),i.jsx("p",{className:"text-sm text-muted-foreground",children:o})]})]})})},iF={initial:{opacity:0}
380,in:{opacity:1},out:{opacity:0}},aF={type:"tween",ease:[.25,.46,.45,.94],duration:.3},lF=h.createContext(0),Xe=({children:e})=>i.jsx(lF.Provider,{value:.1,children:i.jsx(xe.div,{initial:"initial",animate:"in",exit:"out",variants:iF,transition:aF,children:e})}),cF=({children:e,className:t,delay:n=0})=>i.jsx(xe.div,{className:t,initial:"hidden",animate:"visible",variants:{hidden:{opacity:0},visible:{opacity:1,transition:{staggerChildren:.06,delayChildren:n}}},children:e}),uF={hidden:{opacity:0,y:12,scale:.98},visible:{opacity:1,y:0,scale:1,transition:{type:"spring",stiffness:300,damping:24}}},dF=({children:e,className:t})=>i.jsx(xe.div,{className:t,variants:uF,children:e}),Bi=({children:e,className:t,delay:n=0,direction:r="up"})=>{const s={up:{y:16,x:0},down:{y:-16,x:0},left:{y:0,x:16},right:{y:0,x:-16},none:{y:0,x:0}};return i.jsx(xe.div,{className:t,initial:{opacity:0,...s[r]},animate:{opacity:1,y:0,x:0},transition:{type:"spring",stiffness:260,damping:20,delay:n},children:e})};function z({className:e,...t}){return i.jsx("div",{className:Y("animate-pulse rounded-md bg-muted",e),...t})}const fF=()=>i.jsxs("div",{className:"flex gap-3 p-3 bg-card rounded-xl border border-border",children:[i.jsx(z,{className:"w-20 h-20 rounded-lg flex-shrink-0"}),i.jsxs("div",{className:"flex-1 min-w-0 space-y-2",children:[i.jsx(z,{className:"h-4 w-3/4"}),i.jsx(z,{className:"h-3 w-full"}),i.jsxs("div",{className:"flex items-center justify-between pt-1",children:[i.jsx(z,{className:"h-4 w-16"}),i.jsx(z,{className:"h-8 w-8 rounded-full"})]})]})]}),Au=({children:e,className:t,delay:n=0})=>i.jsx(xe.div,{className:t,initial:"hidden",animate:"visible",variants:{hidden:{opacity:0},visible:{opacity:1,transition:{staggerChildren:.08,delayChildren:n}}},children:e}),hF={hidden:{opacity:0,y:10},visible:{opacity:1,y:0,transition:{type:"spring",stiffness:400,damping:25}}},Oo=({children:e,className:t})=>i.jsx(xe.div,{className:t,variants:hF,children:e}),In=({children:e,className:t,delay:n=0})=>i.jsx(xe.div,{className:t,initial:{opacity:0,y:8},animate:{opacity:1,y:0},transition:{type:"spring",stiffness:300,damping:24,delay:n},children:e}),Mv=()=>i.jsxs("div",{className:"px-4 lg:px-0 mb-6",children:[i.jsx(In,{children:i.jsx(z,{className:"h-6 w-32 mb-4"})}),i.jsx(Au,{className:"grid gap-3 sm:grid-cols-2",children:Array.from({length:4}).map((e,t)=>i.jsx(Oo,{children:i.jsx(fF,{})},t))})]}),mF=()=>i.jsxs("div",{className:"min-h-screen bg-background pb-28 lg:pb-8",children:[i.jsx("header",{className:"sticky top-0 z-40 bg-background border-b border-border",children:i.jsxs("div",{className:"flex items-center h-14 px-4 max-w-7xl mx-auto lg:px-6",children:[i.jsx(z,{className:"w-5 h-5"}),i.jsx(z,{className:"h-5 w-16 ml-4"})]})}),i.jsx("div",{className:"max-w-7xl mx-auto px-4 lg:px-6 py-6",children:i.jsxs("div",{className:"lg:grid lg:grid-cols-2 lg:gap-8",children:[i.jsxs("div",{children:[i.jsx(In,{delay:.1,children:i.jsxs("div",{className:"flex items-center gap-4 p-4 lg:p-6 bg-card rounded-2xl border border-border mb-6",children:[i.jsx(z,{className:"w-14 h-14 lg:w-20 lg:h-20 rounded-full"}),i.jsxs("div",{className:"flex-1 space-y-2",children:[i.jsx(z,{className:"h-5 w-32"}),i.jsx(z,{className:"h-4 w-48"}),i.jsx(z,{className:"h-3 w-36"})]}),i.jsx(z,{className:"h-8 w-12 rounded-full"})]})}),i.jsx(In,{delay:.2,children:i.jsxs("div",{className:"grid grid-cols-2 gap-3 mb-6",children:[i.jsxs("div",{className:"p-4 lg:p-6 bg-card rounded-2xl border border-border text-center",children:[i.jsx(z,{className:"h-8 w-20 mx-auto mb-1"}),i.jsx(z,{className:"h-3 w-12 mx-auto"})]}),i.jsxs("div",{className:"p-4 lg:p-6 bg-card rounded-2xl border border-border text-center",children:[i.jsx(z,{className:"h-8 w-24 mx-auto mb-1"}),i.jsx(z,{className:"h-3 w-12 mx-auto"})]})]})}),i.jsx(In,{delay:.3,children:i.jsxs("div",{className:"p-4 lg:p-6 bg-card rounded-2xl border border-border mb-6",children:[i.jsx(z,{className:"h-5 w-28 mb-2"}),i.jsx(z,{className:"h-4 w-full mb-1"}),i.jsx(z,{className:"h-4 w-3/4 mb-3"}),i.jsxs("div",{className:"flex items-center gap-2",children:[i.jsx(z,{className:"h-10 flex-1 rounded-lg"}),i.jsx(z,{className:"h-10 w-10 rounded-lg"}),i.jsx(z,{className:"h-10 w-10 rounded-lg"})]})]})})]}),i.jsx(In,{delay:.25,children:i.jsxs("div",{children:[i.jsx("div",{className:"bg-card rounded-2xl border border-border overflow-hidden",children:Array.from({length:4}).map((e,t)=>i.jsxs("div",{className:"flex items-center gap-3 p-4 border-b border-border last:border-0",children:[i.jsx(z,{className:"w-10 h-10 rounded-xl"}),i.jsx(z,{className:"h-4 flex-1"}),i.jsx(z,{className:"w-4 h-4"})]},t))}),i.jsx(z,{className:"h-12 w-full rounded-xl mt-6"})]})})]})})]}),pF=()=>i.jsx("div",{className:"px-4 py-4 max-w-7xl mx-auto lg:px-6",children:i.jsxs(Au,{className:"flex gap-3 overflow-hidden",children:[i.jsx(Oo,{children:i.jsx(z,{className:"min-w-[280px] sm:min-w-[320px] h-36 rounded-2xl"})}),i.jsx(Oo,{className:"hidden sm:block",children:i.jsx(z,{className:"min-w-[280px] sm:min-w-[320px] h-36 rounded-2xl"})}),i.jsx(Oo,{className:"hidden lg:block",children:i.jsx(z,{className:"min-w-[280px] sm:min-w-[320px] h-36 rounded-2xl"})})]})}),gF=()=>i.jsxs("div",{className:"min-h-screen bg-background pb-8",children:[i.jsx("header",{className:"sticky top-0 z-40 bg-background border-b border-border",children:i.jsxs("div",{className:"flex items-center h-14 px-4 max-w-7xl mx-auto lg:px-6",children:[i.jsx(z,{className:"w-5 h-5"}),i.jsx(z,{className:"h-5 w-28 ml-4"})]})}),i.jsx("div",{className:"max-w-7xl mx-auto px-4 lg:px-6 py-4",children:i.jsx(Au,{className:"lg:grid lg:grid-cols-2 xl:grid-cols-3 lg:gap-4 space-y-3 lg:space-y-0",children:Array.from({length:6}).map((e,t)=>i.jsx(Oo,{children:i.jsxs("div",{className:"p-4 bg-card rounded-lg border border-border",children:[i.jsxs("div",{className:"flex items-start justify-between mb-3",children:[i.jsxs("div",{children:[i.jsxs("div",{className:"flex items-center gap-2 mb-1",children:[i.jsx(z,{className:"h-5 w-20"}),i.jsx(z,{className:"h-5 w-16 rounded-full"})]}),i.jsx(z,{className:"h-3 w-40"})]}),i.jsx(z,{className:"h-5 w-16"})]}),i.jsxs("div",{className:"flex items-center gap-2 mb-3",children:[i.jsx(z,{className:"h-3 w-3"}),i.jsx(z,{className:"h-3 w-24"})]}),i.jsxs("div",{className:"space-y-2 mb-3 pb-3 border-b border-border",children:[i.jsxs("div",{className:"flex justify-between",children:[i.jsx(z,{className:"h-4 w-32"}),i.jsx(z,{className:"h-4 w-12"})]}),i.jsxs("div",{className:"flex justify-between",children:[i.jsx(z,{className:"h-4 w-28"}),i.jsx(z,{className:"h-4 w-12"})]})]}),i.jsxs("div",{className:"flex gap-2",children:[i.jsx(z,{className:"h-9 flex-1 rounded-md"}),i.jsx(z,{className:"h-9 flex-1 rounded-md"})]})]})},t))})})]}),xF=()=>i.jsxs("div",{className:"min-h-screen bg-background pb-28 lg:pb-8",children:[i.jsx("header",{className:"sticky top-0 z-40 bg-background border-b border-border",children:i.jsxs("div",{className:"flex items-center h-14 px-4 max-w-7xl mx-auto lg:px-6",children:[i.jsx(z,{className:"w-5 h-5"}),i.jsx(z,{className:"h-5 w-20 ml-4"})]})}),i.jsx("div",{className:"max-w-7xl mx-auto px-4 lg:px-6 py-5",children:i.jsxs("div",{className:"lg:grid lg:grid-cols-3 lg:gap-8",children:[i.jsxs("div",{className:"lg:col-span-2 space-y-5",children:[i.jsx(In,{delay:.1,children:i.jsxs("div",{className:"bg-card rounded-2xl border border-border overflow-hidden",children:[i.jsxs("div",{className:"p-4 space-y-3",children:[i.jsxs("div",{className:"flex items-center gap-3",children:[i.jsx(z,{className:"w-4 h-4"}),i.jsxs("div",{className:"flex-1",children:[i.jsx(z,{className:"h-4 w-24 mb-1"}),i.jsx(z,{className:"h-3 w-40"})]}),i.jsx(z,{className:"w-4 h-4"})]}),i.jsxs("div",{className:"flex items-center gap-3",children:[i.jsx(z,{className:"w-4 h-4"}),i.jsxs("div",{className:"flex-1",children:[i.jsx(z,{className:"h-4 w-28 mb-1"}),i.jsx(z,{className:"h-3 w-20"})]}),i.jsx(z,{className:"w-4 h-4"})]})]}),i.jsx("div",{className:"border-t border-border p-4",children:i.jsxs("div",{className:"flex items-center gap-3",children:[i.jsx(z,{className:"w-4 h-4"}),i.jsx(z,{className:"h-4 w-24"}),i.jsx(z,{className:"ml-auto w-4 h-4"})]})})]})}),i.jsx(In,{delay:.2,children:i.jsxs("div",{className:"bg-card rounded-2xl border border-border p-4",children:[i.jsx(z,{className:"h-5 w-20 mb-3"}),i.jsx("div",{className:"flex gap-2",children:Array.from({length:4}).map((e,t)=>i.jsx(z,{className:"h-10 flex-1 rounded-full"},t))})]})}),i.jsx(In,{delay:.3,children:i.jsxs("div",{className:"bg-card rounded-2xl border border-border p-4",children:[i.jsx(z,{className:"h-5 w-32 mb-4"}),i.jsxs("div",{className:"space-y-3",children:[i.jsxs("div",{children:[i.jsx(z,{className:"h-3 w-24 mb-1"}),i.jsx(z,{className:"h-11 w-full rounded-md"})]}),i.jsxs("div",{className:"grid grid-cols-2 gap-3",children:[i.jsxs("div",{children:[i.jsx(z,{className:"h-3 w-20 mb-1"}),i.jsx(z,{className:"h-11 w-full rounded-md"})]}),i.jsxs("div",{children:[i.jsx(z,{className:"h-3 w-20 mb-1"}),i.jsx(z,{className:"h-11 w-full rounded-md"})]})]}),i.jsxs("div",{children:[i.jsx(z,{className:"h-3 w-12 mb-1"}),i.jsx(z,{className:"h-11 w-full rounded-md"})]})]})]})}),i.jsx(In,{delay:.4,children:i.jsxs("div",{className:"bg-card rounded-2xl border border-border p-4",children:[i.jsx(z,{className:"h-5 w-32 mb-4"}),i.jsx(Au,{className:"space-y-2",children:Array.from({length:3}).map((e,t)=>i.jsx(Oo,{children:i.jsxs("div",{className:"flex items-center gap-3 p-3 rounded-xl border border-border",children:[i.jsx(z,{className:"w-10 h-10 rounded-lg"}),i.jsxs("div",{className:"flex-1",children:[i.jsx(z,{className:"h-4 w-16 mb-1"}),i.jsx(z,{className:"h-3 w-32"})]})]})},t))})]})})]}),i.jsx(In,{delay:.3,className:"hidden lg:block",children:i.jsxs("div",{className:"sticky top-20 p-6 bg-card rounded-2xl border border-border",children:[i.jsx(z,{className:"h-5 w-28 mb-6"}),i.jsxs("div",{className:"space-y-3",children:[i.jsxs("div",{className:"flex justify-between",children:[i.jsx(z,{className:"h-4 w-16"}),i.jsx(z,{className:"h-4 w-20"})]}),i.jsxs("div",{className:"flex justify-between",children:[i.jsx(z,{className:"h-4 w-12"}),i.jsx(z,{className:"h-4 w-16"})]}),i.jsxs("div",{className:"flex justify-between",children:[i.jsx(z,{className:"h-4 w-8"}),i.jsx(z,{className:"h-4 w-14"})]}),i.jsxs("div",{className:"flex justify-between pt-3 border-t border-border",children:[i.jsx(z,{className:"h-5 w-12"}),i.jsx(z,{className:"h-5 w-24"})]})]}),i.jsx(z,{className:"h-14 w-full rounded-full mt-6"}),i.jsx(z,{className:"h-4 w-48 mx-auto mt-3"})]})})]})})]}),IN=(e=1500)=>{const[t,n]=h.useState(!0);return h.useEffect(()=>{const r=setTimeout(()=>{n(!1)},e);return()=>clearTimeout(r)},[e]),t},yF=({item:e,onItemClick:t,onQuickAdd:n})=>{var f,m;const{triggerHaptic:r}=mr(),s=((f=e.comboItems)==null?void 0:f.reduce((p,b)=>p+b.originalPrice,0))||0,o=s-e.price,a=Math.round(o/s*100),l=p=>new Intl.NumberFormat("en-NG",{style:"currency",currency:"NGN",minimumFractionDigits:0}).format(p),c=p=>{p.stopPropagation(),r("medium"),n(e)},d=(((m=e.comboItems)==null?void 0:m.reduce((p,b)=>{const x=p.find(y=>y.name===b.name);return x?x.count++:p.push({name:b.name,count:1}),p},[]))||[]).map(p=>p.count>1?`${p.count}x ${p.name}`:p.name).join(" + ");return i.jsxs(xe.div,{initial:{opacity:0,y:10}
380,animate:{opacity:1,y:0},whileHover:{scale:1.01},transition:{duration:.15},className:"bg-card rounded-xl overflow-hidden shadow-card hover:shadow-card-hover transition-all cursor-pointer flex gap-3 p-3 border border-primary/10",onClick:()=>{r("light"),t(e)},children:[i.jsxs("div",{className:"relative w-24 h-24 flex-shrink-0 rounded-lg overflow-hidden",children:[i.jsx("img",{src:e.image,alt:e.name,className:"w-full h-full object-cover"}),i.jsxs("div",{className:"absolute top-1 left-1 bg-success text-success-foreground px-1.5 py-0.5 rounded text-[10px] font-bold flex items-center gap-0.5",children:[i.jsx(Vb,{className:"w-2.5 h-2.5"}),"-",a,"%"]})]}),i.jsxs("div",{className:"flex-1 min-w-0 flex flex-col justify-between py-0.5",children:[i.jsxs("div",{children:[i.jsx("h3",{className:"font-semibold text-sm mb-0.5 truncate",children:e.name}),i.jsx("p",{className:"text-xs text-muted-foreground line-clamp-2",children:d})]}),i.jsxs("div",{className:"flex items-center justify-between mt-1",children:[i.jsxs("div",{className:"flex items-center gap-2",children:[i.jsx("span",{className:"font-bold text-primary",children:l(e.price)}),i.jsx("span",{className:"text-xs text-muted-foreground line-through",children:l(s)})]}),i.jsx(xe.div,{whileTap:{scale:.9},children:i.jsx(ue,{size:"icon",onClick:c,className:"h-8 w-8 rounded-full",children:i.jsx(xn,{className:"w-4 h-4"})})})]})]})]})},DN="/assets/logo-iinwe-lI.png",vF=()=>{const e=Je(),{addItem:t,isLoggedIn:n}=Nn(),{config:r}=hr(),{menuItems:s,comboItems:o,categories:a,stores:l,store:c,error:u,isLoading:d}=Kn(),f=h.useMemo(()=>(r==null?void 0:r.storeStatus)==="maintenance"?{isOpen:!1,label:"Under maintenance"}:(r==null?void 0:r.storeStatus)==="offline"?{isOpen:!1,label:"Closed"}:zp((c==null?void 0:c.openingHours)??null)??{isOpen:(r==null?void 0:r.storeStatus)==="live",label:(r==null?void 0:r.storeStatus)==="live"?"Open":"Store info"},[r==null?void 0:r.storeStatus,c==null?void 0:c.openingHours]),p=IN(1500)||d,[b,x]=h.useState("combos"),[y,w]=h.useState(""),[g,v]=h.useState(null),[S,j]=h.useState(!1),[C,P]=h.useState(!1),[N,E]=h.useState(!1),[k,R]=h.useState(!1),[M,I]=h.useState(!1),[O,H]=h.useState(!1),[B,U]=h.useState(!1),T=h.useRef({}),A=h.useRef(null),L=h.useMemo(()=>{const Q=y.trim().toLowerCase(),ne=Z=>Q.length===0||Z.name.toLowerCase().includes(Q)||Z.description.toLowerCase().includes(Q),F={};return F.combos=o.filter(ne),F.popular=s.filter(Z=>Z.popular).filter(ne),F.new=s.filter(Z=>Z.newRelease).filter(ne),a.filter(Z=>Z.id!=="popular"&&Z.id!=="new"&&Z.id!=="combos").forEach(Z=>{F[Z.id]=s.filter(we=>we.category===Z.id).filter(ne)}),F},[y,s,o,a]);h.useEffect(()=>{const Q=new IntersectionObserver(ne=>{ne.forEach(F=>{if(F.isIntersecting){const Z=F.target.getAttribute("data-category");Z&&x(Z)}})},{rootMargin:"-100px 0px -70% 0px",threshold:0});return A.current=Q,Object.values(T.current).forEach(ne=>{ne&&Q.observe(ne)}),()=>{Q.disconnect(),A.current=null}},[]);const _=Q=>{x(Q);const ne=T.current[Q];if(ne){const we=ne.getBoundingClientRect().top+window.scrollY-120;window.scrollTo({top:we,behavior:"smooth"})}},$=Q=>{v(Q),j(!0)},J=Q=>{if(Nu(Q)){v(Q),j(!0);return}t(Q),Yj("success"),K.success(`${Q.name} added to cart`,{duration:1500})},ee=()=>{P(!1),e("/checkout")};return i.jsx(Xe,{children:i.jsxs("div",{className:"min-h-screen bg-background pb-28",children:[i.jsxs("div",{className:"px-4 pt-6 pb-4 max-w-7xl mx-auto lg:px-6",children:[i.jsxs("div",{className:"mb-4",children:[i.jsx("img",{src:(r==null?void 0:r.logoUrl)||DN,alt:(r==null?void 0:r.storeName)??"Storefront",className:"h-14 w-auto mb-2"}),i.jsxs("button",{onClick:()=>U(!0),className:`flex items-center gap-1 text-sm transition-colors ${f.isOpen?"text-success hover:text-success/80":"text-muted-foreground hover:text-foreground"}`,children:[i.jsx(Xo,{className:"w-3.5 h-3.5"}),i.jsx("span",{children:f.label})]})]}),i.jsx(w5,{onLocationClick:()=>R(!0),onTimeClick:()=>I(!0)})]}),p?i.jsx(pF,{}):i.jsx(sF,{}),i.jsx(b5,{activeCategory:b,onCategoryChange:_,searchQuery:y,onSearchQueryChange:w}),i.jsxs("div",{className:"max-w-7xl mx-auto lg:flex lg:gap-8 lg:px-6",children:[i.jsx("main",{className:"pt-4 pb-8 flex-1 lg:pt-6",children:p?i.jsxs(i.Fragment,{children:[i.jsx(Mv,{}),i.jsx(Mv,{})]}):u?i.jsxs("div",{className:"px-4 lg:px-0 py-10 text-center text-sm text-muted-foreground",children:[i.jsxs("p",{children:["We couldn't load the menu — ",u]}),i.jsx("button",{onClick:()=>window.location.reload(),className:"mt-3 px-4 py-2 bg-primary text-primary-foreground rounded-full text-sm font-medium",children:"Retry"})]}):l.length===0?i.jsx("div",{className:"px-4 lg:px-0 py-10 text-center text-sm text-muted-foreground",children:"No stores are open right now — please check back soon."}):s.length+o.length===0?i.jsx("div",{className:"px-4 lg:px-0 py-10 text-center text-sm text-muted-foreground",children:"The menu is empty. Please check back soon."}):a.map(Q=>{const ne=L[Q.id]||[];return ne.length===0?null:Q.id==="combos"?i.jsxs("section",{ref:F=>{const Z=T.current[Q.id];Z&&A.current&&A.current.unobserve(Z),T.current[Q.id]=F,F&&A.current&&A.current.observe(F)},"data-category":Q.id,className:"mb-6 px-4 lg:px-0",children:[i.jsxs("h2",{className:"text-xl font-bold mb-4 flex items-center gap-2",children:[i.jsx("span",{children:Q.emoji}),i.jsx("span",{children:Q.name})]}),i.jsx("div",{className:"grid grid-cols-1 md:grid-cols-2 gap-4",children:ne.map(F=>i.jsx(yF,{item:F,onItemClick:$,onQuickAdd:J},F.id))})]},Q.id):i.jsx("section",{ref:F=>{const Z=T.current[Q.id];Z&&A.current&&A.current.unobserve(Z),T.current[Q.id]=F,F&&A.current&&A.current.observe(F)},"data-category":Q.id,className:"mb-6",children:i.jsx(j5,{categoryId:Q.id,items:ne,onItemClick:$,onQuickAdd:J})},Q.id)})}),i.jsx("aside",{className:"hidden lg:block w-80 pt-6 flex-shrink-0",children:i.jsx(oF,{onCheckout:ee})})]}),i.jsx(f3,{onCartClick:()=>P(!0),onWalletClick:()=>E(!0),onSignInClick:()=>H(!0),isLoggedIn:n}),i.jsx(T5,{item:g,isOpen:S,onClose:()=>j(!1),onOpenItem:$}),i.jsx(R5,{isOpen:C,onClose:()=>P(!1),onCheckout:ee,onOpenItem:$}),i.jsx(I5,{isOpen:N,onClose:()=>E(!1)}),i.jsx(V5,{isOpen:k,onClose:()=>R(!1)}),i.jsx(B5,{isOpen:M,onClose:()=>I(!1)}),i.jsx(H5,{isOpen:O,onClose:()=>H(!1)}),i.jsx(rF,{isOpen:B,onClose:()=>U(!1)}),i.jsx(ON,{})]})})};var wF="Label",LN=h.forwardRef((e,t)=>
380i.jsx(fe.label,{...e,ref:t,onMouseDown:n=>{var s;n.target.closest("button, input, select, textarea")||((s=e.onMouseDown)==null||s.call(e,n),!n.defaultPrevented&&n.detail>1&&n.preventDefault())}}));LN.displayName=wF;var _N=LN;const bF=cu("text-sm font-medium leading-none peer-disabled:cursor-not-allowed peer-disabled:opacity-70"),pt=h.forwardRef(({className:e,...t},n)=>i.jsx(_N,{ref:n,className:Y(bF(),e),...t}));pt.displayName=_N.displayName;const Io={place(e){return he("/storefront/me/orders",{method:"POST",body:JSON.stringify(e)})},verifyPayment(e,t){return he(`/storefront/me/orders/${e}/verify-payment`,{method:"POST",body:JSON.stringify({reference:t})})},abandonPayment(e){return he(`/storefront/me/orders/${e}/abandon-payment`,{method:"POST"})},list(e){const t=new URLSearchParams;e!=null&&e.status&&t.set("status",e.status),e!=null&&e.page&&t.set("page",String(e.page)),e!=null&&e.limit&&t.set("limit",String(e.limit));const n=t.toString();return he(`/storefront/me/orders${n?`?${n}`:""}`)},get(e){return he(`/storefront/me/orders/${e}`)}},Ov={validate(e,t,n=[]){return he("/storefront/coupons/validate",{method:"POST",body:JSON.stringify({code:e,subtotal:t,items:n})})}},Zl={list(){return he("/storefront/me/payment-methods")},update(e,t){return he(`/storefront/me/payment-methods/${e}`,{method:"PATCH",body:JSON.stringify(t)})},remove(e){return he(`/storefront/me/payment-methods/${e}`,{method:"DELETE"})}};function Iv(e,[t,n]){return Math.min(n,Math.max(t,e))}var SF=h.createContext(void 0);function jF(e){const t=h.useContext(SF);return e||t||"ltr"}function FN(e){const t=h.useRef({value:e,previous:e});return h.useMemo(()=>(t.current.value!==e&&(t.current.previous=t.current.value,t.current.value=e),t.current.previous),[e])}var NF=[" ","Enter","ArrowUp","ArrowDown"],CF=[" ","Enter"],Ws="Select",[Mu,Ou,kF]=cb(Ws),[vi]=qs(Ws,[kF,hu]),Iu=hu(),[PF,fs]=vi(Ws),[EF,TF]=vi(Ws),VN=e=>{const{__scopeSelect:t,children:n,open:r,defaultOpen:s,onOpenChange:o,value:a,defaultValue:l,onValueChange:c,dir:u,name:d,autoComplete:f,disabled:m,required:p,form:b}=e,x=Iu(t),[y,w]=h.useState(null),[g,v]=h.useState(null),[S,j]=h.useState(!1),C=jF(u),[P,N]=ba({prop:r,defaultProp:s??!1,onChange:o,caller:Ws}),[E,k]=ba({prop:a,defaultProp:l,onChange:c,caller:Ws}),R=h.useRef(null),M=y?b||!!y.closest("form"):!0,[I,O]=h.useState(new Set),H=Array.from(I).map(B=>B.props.value).join(";");return i.jsx(hA,{...x,children:i.jsxs(PF,{required:p,scope:t,trigger:y,onTriggerChange:w,valueNode:g,onValueNodeChange:v,valueNodeHasChildren:S,onValueNodeHasChildrenChange:j,contentId:To(),value:E,onValueChange:k,open:P,onOpenChange:N,dir:C,triggerPointerDownPosRef:R,disabled:m,children:[i.jsx(Mu.Provider,{scope:t,children:i.jsx(EF,{scope:e.__scopeSelect,onNativeOptionAdd:h.useCallback(B=>{O(U=>new Set(U).add(B))},[]),onNativeOptionRemove:h.useCallback(B=>{O(U=>{const T=new Set(U);return T.delete(B),T})},[]),children:n})}),M?i.jsxs(cC,{"aria-hidden":!0,required:p,tabIndex:-1,name:d,autoComplete:f,value:E,onChange:B=>k(B.target.value),disabled:m,form:b,children:[E===void 0?i.jsx("option",{value:""}):null,Array.from(I)]},H):null]})})};VN.displayName=Ws;var $N="SelectTrigger",BN=h.forwardRef((e,t)=>{const{__scopeSelect:n,disabled:r=!1,...s}=e,o=Iu(n),a=fs($N,n),l=a.disabled||r,c=Se(t,a.onTriggerChange),u=Ou(n),d=h.useRef("touch"),[f,m,p]=dC(x=>{const y=u().filter(v=>!v.disabled),w=y.find(v=>v.value===a.value),g=fC(y,x,w);g!==void 0&&a.onValueChange(g.value)}),b=x=>{l||(a.onOpenChange(!0),p()),x&&(a.triggerPointerDownPosRef.current={x:Math.round(x.pageX),y:Math.round(x.pageY)})};return i.jsx(y1,{asChild:!0,...o,children:i.jsx(fe.button,{type:"button",role:"combobox","aria-controls":a.contentId,"aria-expanded":a.open,"aria-required":a.required,"aria-autocomplete":"none",dir:a.dir,"data-state":a.open?"open":"closed",disabled:l,"data-disabled":l?"":void 0,"data-placeholder":uC(a.value)?"":void 0,...s,ref:c,onClick:oe(s.onClick,x=>{x.currentTarget.focus(),d.current!=="mouse"&&b(x)}),onPointerDown:oe(s.onPointerDown,x=>{d.current=x.pointerType;const y=x.target;y.hasPointerCapture(x.pointerId)&&y.releasePointerCapture(x.pointerId),x.button===0&&x.ctrlKey===!1&&x.pointerType==="mouse"&&(b(x),x.preventDefault())}),onKeyDown:oe(s.onKeyDown,x=>{const y=f.current!=="";!(x.ctrlKey||x.altKey||x.metaKey)&&x.key.length===1&&m(x.key),!(y&&x.key===" ")&&NF.includes(x.key)&&(b(),x.preventDefault())})})})});BN.displayName=$N;var zN="SelectValue",UN=h.forwardRef((e,t)=>
vendor: 15,515 bytes, line 380
380{const{__scopeSelect:n,className:r,style:s,children:o,placeholder:a="",...l}=e,c=fs(zN,n),{onValueNodeHasChildrenChange:u}=c,d=o!==void 0,f=Se(t,c.onValueNodeChange);return rt(()=>{u(d)},[u,d]),i.jsx(fe.span,{...l,ref:f,style:{pointerEvents:"none"},children:uC(c.value)?i.jsx(i.Fragment,{children:a}):o})});UN.displayName=zN;var RF="SelectIcon",WN=h.forwardRef((e,t)=>{const{__scopeSelect:n,children:r,...s}=e;return i.jsx(fe.span,{"aria-hidden":!0,...s,ref:t,children:r||"▼"})});WN.displayName=RF;var AF="SelectPortal",HN=e=>i.jsx(iu,{asChild:!0,...e});HN.displayName=AF;var Hs="SelectContent",KN=h.forwardRef((e,t)=>{const n=fs(Hs,e.__scopeSelect),[r,s]=h.useState();if(rt(()=>{s(new DocumentFragment)},[]),!n.open){const o=r;return o?Gs.createPortal(i.jsx(YN,{scope:e.__scopeSelect,children:i.jsx(Mu.Slot,{scope:e.__scopeSelect,children:i.jsx("div",{children:e.children})})}),o):null}return i.jsx(GN,{...e,ref:t})});KN.displayName=Hs;var cn=10,[YN,hs]=vi(Hs),MF="SelectContentImpl",OF=Qo("SelectContent.RemoveScroll"),GN=h.forwardRef((e,t)=>{const{__scopeSelect:n,position:r="item-aligned",onCloseAutoFocus:s,onEscapeKeyDown:o,onPointerDownOutside:a,side:l,sideOffset:c,align:u,alignOffset:d,arrowPadding:f,collisionBoundary:m,collisionPadding:p,sticky:b,hideWhenDetached:x,avoidCollisions:y,...w}=e,g=fs(Hs,n),[v,S]=h.useState(null),[j,C]=h.useState(null),P=Se(t,F=>S(F)),[N,E]=h.useState(null),[k,R]=h.useState(null),M=Ou(n),[I,O]=h.useState(!1),H=h.useRef(!1);h.useEffect(()=>{if(v)return iN(v)},[v]),Xj();const B=h.useCallback(F=>{const[Z,...we]=M().map(ce=>ce.ref.current),[ae]=we.slice(-1),le=document.activeElement;for(const ce of F)if(ce===le||(ce==null||ce.scrollIntoView({block:"nearest"}),ce===Z&&j&&(j.scrollTop=0),ce===ae&&j&&(j.scrollTop=j.scrollHeight),ce==null||ce.focus(),document.activeElement!==le))return},[M,j]),U=h.useCallback(()=>B([N,v]),[B,N,v]);h.useEffect(()=>{I&&U()},[I,U]);const{onOpenChange:T,triggerPointerDownPosRef:A}=g;h.useEffect(()=>{if(v){let F={x:0,y:0};const Z=ae=>{var le,ce;F={x:Math.abs(Math.round(ae.pageX)-(((le=A.current)==null?void 0:le.x)??0)),y:Math.abs(Math.round(ae.pageY)-(((ce=A.current)==null?void 0:ce.y)??0))}},we=ae=>{F.x<=10&&F.y<=10?ae.preventDefault():v.contains(ae.target)||T(!1),document.removeEventListener("pointermove",Z),A.current=null};return A.current!==null&&(document.addEventListener("pointermove",Z),document.addEventListener("pointerup",we,{capture:!0,once:!0})),()=>{document.removeEventListener("pointermove",Z),document.removeEventListener("pointerup",we,{capture:!0})}}},[v,T,A]),h.useEffect(()=>{const F=()=>T(!1);return window.addEventListener("blur",F),window.addEventListener("resize",F),()=>{window.removeEventListener("blur",F),window.removeEventListener("resize",F)}},[T]);const[L,_]=dC(F=>{const Z=M().filter(le=>!le.disabled),we=Z.find(le=>le.ref.current===document.activeElement),ae=fC(Z,F,we);ae&&setTimeout(()=>ae.ref.current.focus())}),$=h.useCallback((F,Z,we)=>{const ae=!H.current&&!we;(g.value!==void 0&&g.value===Z||ae)&&(E(F),ae&&(H.current=!0))},[g.value]),J=h.useCallback(()=>v==null?void 0:v.focus(),[v]),ee=h.useCallback((F,Z,we)=>{const ae=!H.current&&!we;(g.value!==void 0&&g.value===Z||ae)&&R(F)},[g.value]),Q=r==="popper"?_h:qN,ne=Q===_h?{side:l,sideOffset:c,align:u,alignOffset:d,arrowPadding:f,collisionBoundary:m,collisionPadding:p,sticky:b,hideWhenDetached:x,avoidCollisions:y}:{};return i.jsx(YN,{scope:n,content:v,viewport:j,onViewportChange:C,itemRefCallback:$,selectedItem:N,onItemLeave:J,itemTextRefCallback:ee,focusSelectedItem:U,selectedItemText:k,position:r,isPositioned:I,searchRef:L,children:i.jsx(Kp,{as:OF,allowPinchZoom:!0,children:i.jsx(Hp,{asChild:!0,trapped:g.open,onMountAutoFocus:F=>{F.preventDefault()},onUnmountAutoFocus:oe(s,F=>{var Z;(Z=g.trigger)==null||Z.focus({preventScroll:!0}),F.preventDefault()}),children:i.jsx(za,{asChild:!0,disableOutsidePointerEvents:!0,onEscapeKeyDown:o,onPointerDownOutside:a,onFocusOutside:F=>F.preventDefault(),onDismiss:()=>g.onOpenChange(!1),children:i.jsx(Q,{role:"listbox",id:g.contentId,"data-state":g.open?"open":"closed",dir:g.dir,onContextMenu:F=>F.preventDefault(),...w,...ne,onPlaced:()=>O(!0),ref:P,style:{display:"flex",flexDirection:"column",outline:"none",...w.style},onKeyDown:oe(w.onKeyDown,F=>{const Z=F.ctrlKey||F.altKey||F.metaKey;if(F.key==="Tab"&&F.preventDefault(),!Z&&F.key.length===1&&_(F.key),["ArrowUp","ArrowDown","Home","End"].includes(F.key)){let ae=M().filter(le=>!le.disabled).map(le=>le.ref.current);if(["ArrowUp","End"].includes(F.key)&&(ae=ae.slice().reverse()),["ArrowUp","ArrowDown"].includes(F.key)){const le=F.target,ce=ae.indexOf(le);ae=ae.slice(ce+1)}setTimeout(()=>B(ae)),F.preventDefault()}})})})})})})});GN.displayName=MF;var IF="SelectItemAlignedPosition",qN=h.forwardRef((e,t)=>{const{__scopeSelect:n,onPlaced:r,...s}=e,o=fs(Hs,n),a=hs(Hs,n),[l,c]=h.useState(null),[u,d]=h.useState(null),f=Se(t,P=>d(P)),m=Ou(n),p=h.useRef(!1),b=h.useRef(!0),{viewport:x,selectedItem:y,selectedItemText:w,focusSelectedItem:g}=a,v=h.useCallback(()=>{if(o.trigger&&o.valueNode&&l&&u&&x&&y&&w){const P=o.trigger.getBoundingClientRect(),N=u.getBoundingClientRect(),E=o.valueNode.getBoundingClientRect(),k=w.getBoundingClientRect();if(o.dir!=="rtl"){const le=k.left-N.left,ce=E.left-le,Be=P.left-ce,St=P.width+Be,Rt=Math.max(St,N.width),At=window.innerWidth-cn,Jt=Iv(ce,[cn,Math.max(cn,At-Rt)]);l.style.minWidth=St+"px",l.style.left=Jt+"px"}else{const le=N.right-k.right,ce=window.innerWidth-E.right-le,Be=window.innerWidth-P.right-ce,St=P.width+Be,Rt=Math.max(St,N.width),At=window.innerWidth-cn,Jt=Iv(ce,[cn,Math.max(cn,At-Rt)]);l.style.minWidth=St+"px",l.style.right=Jt+"px"}const R=m(),M=window.innerHeight-cn*2,I=x.scrollHeight,O=window.getComputedStyle(u),H=parseInt(O.borderTopWidth,10),B=parseInt(O.paddingTop,10),U=parseInt(O.borderBottomWidth,10),T=parseInt(O.paddingBottom,10),A=H+B+I+T+U,L=Math.min(y.offsetHeight*5,A),_=window.getComputedStyle(x),$=parseInt(_.paddingTop,10),J=parseInt(_.paddingBottom,10),ee=P.top+P.height/2-cn,Q=M-ee,ne=y.offsetHeight/2,F=y.offsetTop+ne,Z=H+B+F,we=A-Z;if(Z<=ee){const le=R.length>0&&y===R[R.length-1].ref.current;l.style.bottom="0px";const ce=u.clientHeight-x.offsetTop-x.offsetHeight,Be=Math.max(Q,ne+(le?J:0)+ce+U),St=Z+Be;l.style.height=St+"px"}else{const le=R.length>0&&y===R[0].ref.current;l.style.top="0px";const Be=Math.max(ee,H+x.offsetTop+(le?$:0)+ne)+we;l.style.height=Be+"px",x.scrollTop=Z-ee+x.offsetTop}l.style.margin=`${cn}px 0`,l.style.minHeight=L+"px",l.style.maxHeight=M+"px",r==null||r(),requestAnimationFrame(()=>p.current=!0)}},[m,o.trigger,o.valueNode,l,u,x,y,w,o.dir,r]);rt(()=>v(),[v]);const[S,j]=h.useState();rt(()=>{u&&j(window.getComputedStyle(u).zIndex)},[u]);const C=h.useCallback(P=>{P&&b.current===!0&&(v(),g==null||g(),b.current=!1)},[v,g]);return i.jsx(LF,{scope:n,contentWrapper:l,shouldExpandOnScrollRef:p,onScrollButtonChange:C,children:i.jsx("div",{ref:c,style:{display:"flex",flexDirection:"column",position:"fixed",zIndex:S},children:i.jsx(fe.div,{...s,ref:f,style:{boxSizing:"border-box",maxHeight:"100%",...s.style}})})})});qN.displayName=IF;var DF="SelectPopperPosition",_h=h.forwardRef((e,t)=>{const{__scopeSelect:n,align:r="start",collisionPadding:s=cn,...o}=e,a=Iu(n);return i.jsx(v1,{...a,...o,ref:t,align:r,collisionPadding:s,style:{boxSizing:"border-box",...o.style,"--radix-select-content-transform-origin":"var(--radix-popper-transform-origin)","--radix-select-content-available-width":"var(--radix-popper-available-width)","--radix-select-content-available-height":"var(--radix-popper-available-height)","--radix-select-trigger-width":"var(--radix-popper-anchor-width)","--radix-select-trigger-height":"var(--radix-popper-anchor-height)"}})});_h.displayName=DF;var[LF,Qp]=vi(Hs,{}),Fh="SelectViewport",QN=h.forwardRef((e,t)=>{const{__scopeSelect:n,nonce:r,...s}=e,o=hs(Fh,n),a=Qp(Fh,n),l=Se(t,o.onViewportChange),c=h.useRef(0);return i.jsxs(i.Fragment,{children:[i.jsx("style",{dangerouslySetInnerHTML:{__html:"[data-radix-select-viewport]{scrollbar-width:none;-ms-overflow-style:none;-webkit-overflow-scrolling:touch;}[data-radix-select-viewport]::-webkit-scrollbar{display:none}"},nonce:r}),i.jsx(Mu.Slot,{scope:n,children:i.jsx(fe.div,{"data-radix-select-viewport":"",role:"presentation",...s,ref:l,style:{position:"relative",flex:1,overflow:"hidden auto",...s.style},onScroll:oe(s.onScroll,u=>{const d=u.currentTarget,{contentWrapper:f,shouldExpandOnScrollRef:m}=a;if(m!=null&&m.current&&f){const p=Math.abs(c.current-d.scrollTop);if(p>0){const b=window.innerHeight-cn*2,x=parseFloat(f.style.minHeight),y=parseFloat(f.style.height),w=Math.max(x,y);if(w<b){const g=w+p,v=Math.min(b,g),S=g-v;f.style.height=v+"px",f.style.bottom==="0px"&&(d.scrollTop=S>0?S:0,f.style.justifyContent="flex-end")}}}c.current=d.scrollTop})})})]})});QN.displayName=Fh;var XN="SelectGroup",[_F,FF]=vi(XN),VF=h.forwardRef((e,t)=>{const{__scopeSelect:n,...r}=e,s=To();return i.jsx(_F,{scope:n,id:s,children:i.jsx(fe.div,{role:"group","aria-labelledby":s,...r,ref:t})})});VF.displayName=XN;var JN="SelectLabel",ZN=h.forwardRef((e,t)=>{const{__scopeSelect:n,...r}=e,s=FF(JN,n);return i.jsx(fe.div,{id:s.id,...r,ref:t})});ZN.displayName=JN;var zc="SelectItem",[$F,eC]=vi(zc),tC=h.forwardRef((e,t)=>{const{__scopeSelect:n,value:r,disabled:s=!1,textValue:o,...a}=e,l=fs(zc,n),c=hs(zc,n),u=l.value===r,[d,f]=h.useState(o??""),[m,p]=h.useState(!1),b=Se(t,g=>{var v;return(v=c.itemRefCallback)==null?void 0:v.call(c,g,r,s)}),x=To(),y=h.useRef("touch"),w=()=>{s||(l.onValueChange(r),l.onOpenChange(!1))};if(r==="")throw new Error("A <Select.Item /> must have a value prop that is not an empty string. This is because the Select value can be set to an empty string to clear the selection and show the placeholder.");return i.jsx($F,{scope:n,value:r,disabled:s,textId:x,isSelected:u,onItemTextChange:h.useCallback(g=>{f(v=>v||((g==null?void 0:g.textContent)??"").trim())},[]),children:i.jsx(Mu.ItemSlot,{scope:n,value:r,disabled:s,textValue:d,children:i.jsx(fe.div,{role:"option","aria-labelledby":x,"data-highlighted":m?"":void 0,"aria-selected":u&&m,"data-state":u?"checked":"unchecked","aria-disabled":s||void 0,"data-disabled":s?"":void 0,tabIndex:s?void 0:-1,...a,ref:b,onFocus:oe(a.onFocus,()=>p(!0)),onBlur:oe(a.onBlur,()=>p(!1)),onClick:oe(a.onClick,()=>{y.current!=="mouse"&&w()}),onPointerUp:oe(a.onPointerUp,()=>{y.current==="mouse"&&w()}),onPointerDown:oe(a.onPointerDown,g=>{y.current=g.pointerType}),onPointerMove:oe(a.onPointerMove,g=>{var v;y.current=g.pointerType,s?(v=c.onItemLeave)==null||v.call(c):y.current==="mouse"&&g.currentTarget.focus({preventScroll:!0})}),onPointerLeave:oe(a.onPointerLeave,g=>{var v;g.currentTarget===document.activeElement&&((v=c.onItemLeave)==null||v.call(c))}),onKeyDown:oe(a.onKeyDown,g=>{var S;((S=c.searchRef)==null?void 0:S.current)!==""&&g.key===" "||(CF.includes(g.key)&&w(),g.key===" "&&g.preventDefault())})})})})});tC.displayName=zc;var zi="SelectItemText",nC=h.forwardRef((e,t)=>{const{__scopeSelect:n,className:r,style:s,...o}=e,a=fs(zi,n),l=hs(zi,n),c=eC(zi,n),u=TF(zi,n),[d,f]=h.useState(null),m=Se(t,w=>f(w),c.onItemTextChange,w=>{var g;return(g=l.itemTextRefCallback)==null?void 0:g.call(l,w,c.value,c.disabled)}),p=d==null?void 0:d.textContent,b=h.useMemo(()=>i.jsx("option",{value:c.value,disabled:c.disabled,children:p},c.value),[c.disabled,c.value,p]),{onNativeOptionAdd:x,onNativeOptionRemove:y}=u;return rt(()=>(x(b),()=>y(b)),[x,y,b]),i.jsxs(i.Fragment,{children:[i.jsx(fe.span,{id:c.textId,...o,ref:m}),c.isSelected&&a.valueNode&&!a.valueNodeHasChildren?Gs.createPortal(o.children,a.valueNode):null]})});nC.displayName=zi;var rC="SelectItemIndicator",sC=h.forwardRef((e,t)=>{const{__scopeSelect:n,...r}=e;return eC(rC,n).isSelected?i.jsx(fe.span,{"aria-hidden":!0,...r,ref:t}):null});sC.displayName=rC;var Vh="SelectScrollUpButton",oC=h.forwardRef((e,t)=>{const n=hs(Vh,e.__scopeSelect),r=Qp(Vh,e.__scopeSelect),[s,o]=h.useState(!1),a=Se(t,r.onScrollButtonChange);return rt(()=>{if(n.viewport&&n.isPositioned){let l=function(){const u=c.scrollTop>0;o(u)};const c=n.viewport;return l(),c.addEventListener("scroll",l),()=>c.removeEventListener("scroll",l)}},[n.viewport,n.isPositioned]),s?i.jsx(aC,{...e,ref:a,onAutoScroll:()=>{const{viewport:l,selectedItem:c}=n;l&&c&&(l.scrollTop=l.scrollTop-c.offsetHeight)}}):null});oC.displayName=Vh;var $h="SelectScrollDownButton",iC=h.forwardRef((e,t)=>{const n=hs($h,e.__scopeSelect),r=Qp($h,e.__scopeSelect),[s,o]=h.useState(!1),a=Se(t,r.onScrollButtonChange);return rt(()=>{if(n.viewport&&n.isPositioned){let l=function(){const u=c.scrollHeight-c.clientHeight,d=Math.ceil(c.scrollTop)<u;o(d)};const c=n.viewport;return l(),c.addEventListener("scroll",l),()=>c.removeEventListener("scroll",l)}},[n.viewport,n.isPositioned]),s?i.jsx(aC,{...e,ref:a,onAutoScroll:()=>{const{viewport:l,selectedItem:c}=n;l&&c&&(l.scrollTop=l.scrollTop+c.offsetHeight)}}):null});iC.displayName=$h;var aC=h.forwardRef((e,t)=>{const{__scopeSelect:n,onAutoScroll:r,...s}=e,o=hs("SelectScrollButton",n),a=h.useRef(null),l=Ou(n),c=h.useCallback(()=>{a.current!==null&&(window.clearInterval(a.current),a.current=null)},[]);return h.useEffect(()=>()=>c(),[c]),rt(()=>{var d;const u=l().find(f=>f.ref.current===document.activeElement);(d=u==null?void 0:u.ref.current)==null||d.scrollIntoView({block:"nearest"})},[l]),i.jsx(fe.div,{"aria-hidden":!0,...s,ref:t,style:{flexShrink:0,...s.style},onPointerDown:oe(s.onPointerDown,()=>{a.current===null&&(a.current=window.setInterval(r,50))}),onPointerMove:oe(s.onPointerMove,()=>{var u;(u=o.onItemLeave)==null||u.call(o),a.current===null&&(a.current=window.setInterval(r,50))}),onPointerLeave:oe(s.onPointerLeave,()=>{c()})})}),BF="SelectSeparator",lC=h.forwardRef((e,t)=>{const{__scopeSelect:n,...r}=e;return i.jsx(fe.div,{"aria-hidden":!0,...r,ref:t})});lC.displayName=BF;var Bh="SelectArrow",zF=h.forwardRef((e,t)=>{const{__scopeSelect:n,...r}=e,s=Iu(n),o=fs(Bh,n),a=hs(Bh,n);return o.open&&a.position==="popper"?i.jsx(w1,{...s,...r,ref:t}):null});zF.displayName=Bh;var UF="SelectBubbleInput",cC=h.forwardRef(({__scopeSelect:e,value:t,...n},r)=>{const s=h.useRef(null),o=Se(r,s),a=FN(t);return h.useEffect(()=>{const l=s.current;if(!l)return;const c=window.HTMLSelectElement.prototype,d=Object.getOwnPropertyDescriptor(c,"value").set;if(a!==t&&d){const f=new Event("change",{bubbles:!0});d.call(l,t),l.dispatchEvent(f)}},[a,t]),i.jsx(fe.select,{...n,style:{...mb,...n.style},ref:o,defaultValue:t})});cC.displayName=UF;function uC(e){return e===""||e===void 0}function dC(e){const t=bn(e),n=h.useRef(""),r=h.useRef(0),s=h.useCallback(a=>{const l=n.current+a;t(l),function c(u){n.current=u,window.clearTimeout(r.current),u!==""&&(r.current=window.setTimeout(()=>c(""),1e3))}(l)},[t]),o=h.useCallback(()=>{n.current="",window.clearTimeout(r.current)},[]);return h.useEffect(()=>()=>window.clearTimeout(r.current),[]),[n,s,o]}function fC(e,t,n){const s=t.length>1&&Array.from(t).every(u=>u===t[0])?t[0]:t,o=n?e.indexOf(n):-1;let a=WF(e,Math.max(o,0));s.length===1&&(a=a.filter(u=>u!==n));const c=a.find(u=>u.textValue.toLowerCase().startsWith(s.toLowerCase()));return c!==n?c:void 0}function WF(e,t){return e.map((n,r)=>e[(t+r)%e.length])}var HF=VN,hC=BN,KF=UN,YF=WN,GF=HN,mC=KN,qF=QN,pC=ZN,gC=tC,QF=nC,XF=sC,xC=oC,yC=iC,vC=lC;const JF=HF,ZF=KF,wC=h.forwardRef(({className:e,children:t,...n},r)=>i.jsxs(hC,{ref:r,className:Y("flex h-10 w-full items-center justify-between rounded-md border border-input bg-background px-3 py-2 text-sm r
380ing-offset-background placeholder:text-muted-foreground focus:outline-none focus:ring-2 focus:ring-ring focus:ring-offset-2 disabled:cursor-not-allowed disabled:opacity-50 [&>span]:line-clamp-1",e),...n,children:[t,i.jsx(YF,{asChild:!0,children:i.jsx(Nc,{className:"h-4 w-4 opacity-50"})})]}));wC.displayName=hC.displayName;const bC=h.forwardRef(({className:e,...t},n)=>i.jsx(xC,{ref:n,className:Y("flex cursor-default items-center justify-center py-1",e),...t,children:i.jsx(dE,{className:"h-4 w-4"})}));bC.displayName=xC.displayName;const SC=h.forwardRef(({className:e,...t},n)=>i.jsx(yC,{ref:n,className:Y("flex cursor-default items-center justify-center py-1",e),...t,children:i.jsx(Nc,{className:"h-4 w-4"})}));SC.displayName=yC.displayName;const jC=h.forwardRef(({className:e,children:t,position:n="popper",...r},s)=>i.jsx(GF,{children:i.jsxs(mC,{ref:s,className:Y("relative z-50 max-h-96 min-w-[8rem] overflow-hidden rounded-md border bg-popover text-popover-foreground shadow-md data-[state=open]:animate-in data-[state=closed]:animate-out data-[state=closed]:fade-out-0 data-[state=open]:fade-in-0 data-[state=closed]:zoom-out-95 data-[state=open]:zoom-in-95 data-[side=bottom]:slide-in-from-top-2 data-[side=left]:slide-in-from-right-2 data-[side=right]:slide-in-from-left-2 data-[side=top]:slide-in-from-bottom-2",n==="popper"&&"data-[side=bottom]:translate-y-1 data-[side=left]:-translate-x-1 data-[side=right]:translate-x-1 data-[side=top]:-translate-y-1",e),position:n,...r,children:[i.jsx(bC,{}),i.jsx(qF,{className:Y("p-1",n==="popper"&&"h-[var(--radix-select-trigger-height)] w-full min-w-[var(--radix-select-trigger-width)]"),children:t}),i.jsx(SC,{})]})}));jC.displayName=mC.displayName;const eV=h.forwardRef(({className:e,...t},n)=>i.jsx(pC,{ref:n,className:Y("py-1.5 pl-8 pr-2 text-sm font-semibold",e),...t}));eV.displayName=pC.displayName;const NC=h.forwardRef(({className:e,children:t,...n},r)=>i.jsxs(gC,{ref:r,className:Y("relative flex w-full cursor-default select-none items-center rounded-sm py-1.5 pl-8 pr-2 text-sm outline-none data-[disabled]:pointer-events-none data-[disabled]:opacity-50 focus:bg-accent focus:text-accent-foreground",e),...n,children:[i.jsx("span",{className:"absolute left-2 flex h-3.5 w-3.5 items-center justify-center",children:i.jsx(XF,{children:i.jsx(Mn,{className:"h-4 w-4"})})}),i.jsx(QF,{children:t})]}));NC.displayName=gC.displayName;const tV=h.forwardRef(({className:e,...t},n)=>i.jsx(vC,{ref:n,className:Y("-mx-1 my-1 h-px bg-muted",e),...t}));tV.displayName=vC.displayName;const nV="https://omega.staybolted.dev/api",rV={async forStore(e){const t=`${nV}/public/storefront/stores/${encodeURIComponent(e)}/delivery-regions`,n=await fetch(t);if(!n.ok){const s=await n.json().catch(()=>({message:"Request failed"}));throw new Error(s.message??`HTTP ${n.status}`)}const r=await n.json();return r.data??r}},sV=()=>{const e=Je(),t=IN(800),{items:n,orderType:r,storeId:s,selectedAddressId:o,setSelectedAddressId:a,selectedDeliveryRegionId:l,setSelectedDeliveryRegionId:c,selectedPaymentMethodId:u,setSelectedPaymentMethodId:d,selectedTime:f,subtotal:m,tax:p,total:b,pointsToEarn:x,clearCart:y}=Nn(),{profile:w,isAuthenticated:g}=Tt(),{config:v}=hr(),S=Number((v==null?void 0:v.nairaPerPoint)??.1),{store:j}=Kn(),[C,P]=h.useState(0),[N,E]=h.useState("percent"),[k,R]=h.useState(""),[M,I]=h.useState("paystack"),[O,H]=h.useState(null),[B,U]=h.useState(""),[T,A]=h.useState(null),[L,_]=h.useState(!1),[$,J]=h.useState(!1),[ee,Q]=h.useState(!1),[ne,F]=h.useState([]),[Z,we]=h.useState([]);h.useEffect(()=>{g&&(Ql.list().then(F).catch(()=>{}),Zl.list().then(we).catch(()=>{}))},[g]),h.useEffect(()=>{xi.getPaymentMethods().then(H).catch(()=>H(null))},[]),h.useEffect(()=>{if(r!=="delivery"||o)return;const X=ne.find(pe=>pe.isDefault)??ne[0];X&&a(X.id)},[ne,r,o,a]);const[ae,le]=h.useState([]);h.useEffect(()=>{if(!s)return;let X=!1;return rV.forStore(s).then(pe=>{X||le(pe)}).catch(()=>{X||le([])}),()=>{X=!0}},[s]);const ce=ae.find(X=>X.id===l)??null,Be=r==="delivery"?Number((ce==null?void 0:ce.fee)??0):0;h.useEffect(()=>{l&&ae.length!==0&&(ae.some(X=>X.id===l)||c(null))},[ae,l,c]);const St=Number((v==null?void 0:v.taxRate)??.075),Rt=N==="custom"?Math.max(0,Math.round(Number(k)||0)):Math.round(m*(C/100)),At=(T==null?void 0:T.discount)??0,Jt=new Set((O??[]).map(X=>X.type)),Zt=!O||Jt.has("card")||Jt.has("pos"),$t=!O||Jt.has("cash"),pr=(v==null?void 0:v.walletEnabled)!==!1&&!!w&&Number(w.walletBalance??0)>0;h.useEffect(()=>{M==="paystack"&&!Zt?I($t?"cash":pr?"wallet":"paystack"):M==="cash"&&!$t?I(Zt?"paystack":pr?"wallet":"cash"):M==="wallet"&&!pr&&I(Zt?"paystack":$t?"cash":"wallet")},[Zt,$t,pr]);const gr=(w==null?void 0:w.points)??0,qa=Math.floor(gr*S),en=$?Math.min(gr,S>0?Math.ceil(b/S):0):0,Qs=Math.floor(en*S),xr=h.useMemo(()=>Math.max(0,b+Be+Rt-At-Qs),[b,Be,Rt,At,Qs]),Ge=ne.find(X=>X.id===o),yr=async()=>
380{if(B.trim()){if(!g){K.error("Please sign in to use coupons");return}try{const X=n.map(De=>({productId:De.menuItem.isCombo?void 0:De.menuItem.id,categoryId:De.menuItem.category,lineTotal:De.menuItem.price*De.quantity})),pe=await Ov.validate(B.trim(),m,X);if(!pe.valid){K.error(pe.reason??"Invalid coupon code");return}A({code:pe.coupon.code,discount:pe.discountAmount??0}),U(""),_(!1),K.success(`Coupon applied! You save ₦${(pe.discountAmount??0).toLocaleString()}`)}catch(X){K.error(X.message??"Failed to apply coupon")}}},Lu=()=>{A(null),K.success("Coupon removed")},_u=async()=>{var X;if(n.length===0){K.error("Your cart is empty");return}if(!s){K.error("Pick a store first");return}if(!g||!w){K.error("Please sign in to place an order"),e("/login");return}if(r==="delivery"&&!o){K.error("Please select a delivery address");return}if(r==="delivery"&&ae.length>0&&!l){K.error("Please select a delivery region");return}if(m<=0){K.error("Add at least one item to your cart");return}if(!f){K.error("The store is closed — pick a scheduled time for your order");return}if(M==="wallet"&&xr>Number(w.walletBalance??0)){K.error(`Wallet balance ₦${Number(w.walletBalance??0).toLocaleString()} can't cover ₦${xr.toLocaleString()} — pick another payment method.`);return}if(M==="points"&&xr>0){K.error("Points alone can't cover this order — pick another payment method or redeem fewer points.");return}if(T)try{const pe=n.map(Re=>({productId:Re.menuItem.isCombo?void 0:Re.menuItem.id,categoryId:Re.menuItem.category,lineTotal:Re.menuItem.price*Re.quantity})),De=await Ov.validate(T.code,m,pe);if(!De.valid){A(null),K.error(`Coupon ${T.code} is no longer valid: ${De.reason??"removed"}`);return}}catch{}Q(!0);try{const pe=await Io.place({storeId:s,isDelivery:r==="delivery",deliveryAddressId:r==="delivery"?o??void 0:void 0,deliveryRegionId:r==="delivery"?l??void 0:void 0,scheduledFor:f&&f!=="ASAP"?f:void 0,items:n.map(Re=>{const{variation:wr,addons:Vu,variationId:$u}=QL(Re.menuItem,Re.selectedOptions);return{productId:Re.menuItem.isCombo?void 0:Re.menuItem.id,comboId:Re.menuItem.isCombo?Re.menuItem.id:void 0,name:Re.menuItem.name,quantity:Re.quantity,unitPrice:zs(Re.menuItem,Re.selectedOptions),variationId:Re.menuItem.isCombo?void 0:$u,variation:wr,addons:Vu,notes:Re.specialRequest??void 0}}),paymentChannel:M,savedPaymentMethodId:M==="paystack"&&u?u:void 0,couponCode:T==null?void 0:T.code,tipAmount:Rt,pointsToRedeem:en>0?en:void 0,notes:void 0}),De=pe.order.id;if((X=pe.payment)!=null&&X.requiresAction){await Fu(De,pe.payment);return}K.success("Order placed"),y(),Q(!1),e(`/order-tracking/${De}`)}catch(pe){Q(!1),K.error(pe.message??"Couldn't place order")}},vr=async(X,pe)=>{try{await Io.abandonPayment(X)}catch{}Q(!1),pe&&K.info(pe)},Fu=async(X,pe)=>{try{await qj({publicKey:pe.publicKey??"",email:(w==null?void 0:w.email)??`customer-${w==null?void 0:w.id}@no-email.local`,amountKobo:pe.amount??Math.round(xr*100),reference:pe.reference??"",metadata:{orderId:X,kind:"storefront_order"}},{onSuccess:async De=>{try{await Io.verifyPayment(X,De),K.success("Payment successful"),y()}catch(Re){K.error(Re.message??"Couldn't verify payment — your order is still recorded.")}finally{Q(!1),e(`/order-tracking/${X}`)}},onCancel:()=>{vr(X,"Payment cancelled — your order was not placed.")},onClose:()=>{vr(X,"Payment closed — your order was not placed.")}})}catch(De){K.error(De.message??"Failed to start payment. Please try again."),await vr(X)}};return t?i.jsx(Xe,{children:i.jsx(xF,{})}):n.length===0?i.jsx(Xe,{children:i.jsxs("div",{className:"min-h-screen bg-background flex flex-col items-center justify-center p-6",children:[i.jsx("div",{className:"w-14 h-14 rounded-full bg-secondary flex items-center justify-center mb-3",children:i.jsx(Um,{className:"w-6 h-6 text-muted-foreground"})}),i.jsx("h2",{className:"text-lg font-bold mb-1",children:"Your cart is empty"}),i.jsx("p",{className:"text-muted-foreground text-sm mb-4",children:"Add items to checkout"}),i.jsx(ue,{onClick:()=>e("/"),children:"Browse menu"})]})}):i.jsx(Xe,{children:i.jsxs("div",{className:"min-h-screen bg-background pb-32",children:[i.jsx("header",{className:"sticky top-0 z-40 bg-background border-b border-border",children:i.jsx("div",{className:"max-w-3xl mx-auto flex items-center h-14 px-4",children:i.jsxs("button",{onClick:()=>e(-1),className:"flex items-center gap-2 text-muted-foreground hover:text-foreground",children:[i.jsx(Fn,{className:"w-5 h-5"}),i.jsx("span",{children:"Checkout"})]})})}),i.jsxs("main",{className:"max-w-3xl mx-auto px-4 py-6 space-y-6",children:[i.jsxs("section",{className:"bg-card rounded-2xl p-4",children:[i.jsx("h3",{className:"font-semibold mb-3",children:r==="delivery"?"Delivering to":"Picking up at"}),i.jsxs("div",{className:"flex items-start gap-3",children:[i.jsx("div",{className:"w-10 h-10 rounded-full bg-secondary flex items-center justify-center shrink-0",children:i.jsx(er,{className:"w-5 h-5 text-muted-foreground"})}),i.jsx("div",{className:"flex-1 min-w-0",children:r==="delivery"?Ge?i.jsxs(i.Fragment,{children:[i.jsx("p",{className:"font-medium",children:Ge.label}),i.jsxs("p",{className:"text-muted-foreground text-xs",children:[Ge.line1,Ge.city&&`, ${Ge.city}`]})]}):i.jsx("p",{className:"text-muted-foreground text-sm",children:"Choose a delivery address"}):j?i.jsxs(i.Fragment,{children:[i.jsx("p",{className:"font-medium",children:j.name}),i.jsx("p",{className:"text-muted-foreground text-xs",children:j.address})]}):i.jsx("p",{className:"text-muted-foreground text-sm",children:"Choose a pickup location"})})]}),r==="delivery"&&ae.length>0&&i.jsxs("div",{className:"mt-3",children:[i.jsxs("div",{className:"mb-4 flex items-start gap-3 rounded-xl border border-yellow-300 bg-yellow-50 px-4 py-3 shadow-sm",children:[i.jsx("span",{className:"text-lg leading-5",children:"⚠️"}),i.jsx("p",{className:"text-sm leading-5 text-black",children:"Please select a delivery region that matches your delivery address."})]}),i.jsxs(JF,{value:l,onValueChange:c,children:[i.jsx(wC,{className:"w-full",children:l?i.jsx(ZF,{}):i.jsx("span",{className:"text-gray-500",children:"Select Delivery Region"})}),i.jsx(jC,{children:ae.map(X=>i.jsxs(NC,{value:X.id,children:[X.name," — ₦",Number(X.fee).toLocaleStr
380ing()]},X.id))})]})]}),i.jsxs("div",{className:"flex items-center gap-2 mt-3 text-sm text-muted-foreground",children:[i.jsx(Xo,{className:"w-4 h-4"}),i.jsx("span",{children:Kj(f)})]})]}),i.jsxs("section",{className:"bg-card rounded-2xl p-4",children:[i.jsx("h3",{className:"font-semibold mb-3",children:"Items"}),i.jsx("div",{className:"space-y-3",children:n.map(X=>i.jsxs("div",{className:"flex justify-between text-sm",children:[i.jsxs("span",{children:[X.quantity,"× ",X.menuItem.name]}),i.jsxs("span",{className:"font-medium",children:["₦",(zs(X.menuItem,X.selectedOptions)*X.quantity).toLocaleString()]})]},X.id))})]}),i.jsxs("section",{className:"bg-card rounded-2xl p-4",children:[i.jsx("h3",{className:"font-semibold mb-3",children:"Add tip"}),i.jsxs("div",{className:"grid grid-cols-5 gap-2",children:[[0,5,10,15].map(X=>i.jsx("button",{onClick:()=>{E("percent"),P(X)},className:Y("py-2 rounded-lg border text-sm font-medium",N==="percent"&&C===X?"border-primary bg-primary/5":"border-border"),children:X===0?"None":`${X}%`},X)),i.jsx("button",{onClick:()=>E("custom"),className:Y("py-2 rounded-lg border text-sm font-medium",N==="custom"?"border-primary bg-primary/5":"border-border"),children:"Custom"})]}),N==="custom"&&i.jsxs("div",{className:"mt-3 relative",children:[i.jsx("span",{className:"absolute left-3 top-1/2 -translate-y-1/2 text-muted-foreground",children:"₦"}),i.jsx(Ke,{type:"number",inputMode:"numeric",min:0,placeholder:"Enter tip amount",value:k,onChange:X=>R(X.target.value),className:"pl-7",autoFocus:!0})]})]}),i.jsx("section",{className:"bg-card rounded-2xl p-4",children:T?i.jsxs("div",{className:"flex items-center justify-between",children:[i.jsxs("div",{className:"flex items-center gap-2",children:[i.jsx(vx,{className:"w-4 h-4 text-primary"}),i.jsx("span",{className:"font-medium",children:T.code}),i.jsxs("span",{className:"text-sm text-muted-foreground",children:["−₦",T.discount.toLocaleString()]})]}),i.jsx("button",{onClick:Lu,className:"text-muted-foreground hover:text-foreground",children:i.jsx(vt,{className:"w-4 h-4"})})]}):L?i.jsxs("div",{className:"space-y-2",children:[i.jsx(pt,{children:"Coupon code"}),i.jsxs("div",{className:"flex gap-2",children:[i.jsx(Ke,{value:B,onChange:X=>U(X.target.value),placeholder:"ENTER CODE"}),i.jsx(ue,{onClick:yr,children:"Apply"})]})]}):i.jsxs("button",{onClick:()=>_(!0),className:"flex items-center justify-between w-full text-sm",children:[i.jsxs("span",{className:"flex items-center gap-2",children:[i.jsx(vx,{className:"w-4 h-4"}),"Have a promo code?"]}),i.jsx($s,{className:"w-4 h-4 text-muted-foreground"})]})}),w&&w.points>0&&i.jsx("section",{className:"bg-card rounded-2xl p-4",children:i.jsxs("button",{onClick:()=>J(!$),className:"flex items-center justify-between w-full",children:[i.jsxs("div",{className:"flex items-center gap-3",children:[i.jsx(ar,{className:"w-5 h-5"}),i.jsxs("div",{className:"text-left",children:[i.jsxs("p",{className:"font-medium",children:["Redeem ",w.points.toLocaleString()," points"]}),i.jsxs("p",{className:"text-xs text-muted-foreground",children:["Worth up to ₦",qa.toLocaleString()]})]})]}),i.jsx("div",{className:Y("w-6 h-6 rounded-md border flex items-center justify-center",$?"border-primary bg-primary text-primary-foreground":"border-border"),children:$&&i.jsx(Mn,{className:"w-3 h-3"})})]})}),i.jsxs("section",{className:"bg-card rounded-2xl p-4",children:[i.jsx("h3",{className:"font-semibold mb-3",children:"Payment"}),i.jsxs("div",{className:"space-y-2",children:[Zt&&i.jsxs("button",{onClick:()=>I("paystack"),className:Y("flex items-center justify-between w-full p-3 rounded-lg border",M==="paystack"?"border-primary bg-primary/5":"border-border"),children:[i.jsxs("div",{className:"flex items-center gap-3",children:[i.jsx(Zi,{className:"w-5 h-5"}),i.jsxs("div",{className:"text-left",children:[i.jsx("p",{className:"font-medium",children:"Card via Paystack"}),i.jsx("p",{className:"text-xs text-muted-foreground",children:"Visa, Mastercard, Verve, transfer"})]})]}),M==="paystack"&&i.jsx(Mn,{className:"w-4 h-4 text-primary"})]}),Z.length>0&&M==="paystack"&&i.jsxs("div",{className:"ml-8 space-y-1",children:[Z.map(X=>{const pe=u===X.id;return i.jsxs("button",{onClick:()=>d(pe?null:X.id),className:Y("flex items-center justify-between w-full p-2 rounded-lg text-sm border",pe?"border-primary bg-primary/5":"border-border"),children:[i.jsxs("span",{className:"capitalize",children:[X.brand," •••• ",X.last4]}),pe&&i.jsx(Mn,{className:"w-4 h-4 text-primary"})]},X.id)}),i.jsx("p",{className:"text-xs text-muted-foreground",children:"Skip selection to enter a new card"})]}),pr&&i.jsxs("button",{onClick:()=>I("wallet"),className:Y("flex items-center justify-between w-full p-3 rounded-lg border",M==="wallet"?"border-primary bg-primary/5":"border-border"),children:[i.jsxs("div",{className:"flex items-center gap-3",children:[i.jsx(kc,{className:"w-5 h-5"}),i.jsxs("div",{className:"text-left",children:[i.jsx("p",{className:"font-medium",children:"Wallet"}),i.jsxs("p",{className:"text-xs text-muted-foreground",children:["Balance: ₦",w.walletBalance.toLocaleStr
380ing()]})]})]}),M==="wallet"&&i.jsx(Mn,{className:"w-4 h-4 text-primary"})]}),$t&&i.jsxs("button",{onClick:()=>I("cash"),className:Y("flex items-center justify-between w-full p-3 rounded-lg border",M==="cash"?"border-primary bg-primary/5":"border-border"),children:[i.jsxs("div",{className:"flex items-center gap-3",children:[i.jsx(kc,{className:"w-5 h-5"}),i.jsxs("div",{className:"text-left",children:[i.jsxs("p",{className:"font-medium",children:["Cash on ",r==="delivery"?"delivery":"pickup"]}),i.jsx("p",{className:"text-xs text-muted-foreground",children:"Pay when your order arrives"})]})]}),M==="cash"&&i.jsx(Mn,{className:"w-4 h-4 text-primary"})]})]})]}),i.jsxs("section",{className:"bg-card rounded-2xl p-4 space-y-2",children:[i.jsxs("div",{className:"flex justify-between text-sm",children:[i.jsx("span",{className:"text-muted-foreground",children:"Subtotal"}),i.jsxs("span",{children:["₦",m.toLocaleString()]})]}),i.jsxs("div",{className:"flex justify-between text-sm",children:[i.jsxs("span",{className:"text-muted-foreground",children:["Tax (",+(St*100).toFixed(2),"%)"]}),i.jsxs("span",{children:["₦",p.toLocaleString()]})]}),r==="delivery"&&i.jsxs("div",{className:"flex justify-between text-sm",children:[i.jsx("span",{className:"text-muted-foreground",children:"Delivery fee"}),i.jsx("span",{children:ce?`₦${Be.toLocaleString()}`:"Select a region"})]}),Rt>0&&i.jsxs("div",{className:"flex justify-between text-sm",children:[i.jsx("span",{className:"text-muted-foreground",children:"Tip"}),i.jsxs("span",{children:["₦",Rt.toLocaleString()]})]}),At>0&&i.jsxs("div",{className:"flex justify-between text-sm text-green-600",children:[i.jsxs("span",{children:["Coupon (",T==null?void 0:T.code,")"]}),i.jsxs("span",{children:["−₦",At.toLocaleString()]})]}),Qs>0&&i.jsxs("div",{className:"flex justify-between text-sm text-green-600",children:[i.jsx("span",{children:"Points"}),i.jsxs("span",{children:["−₦",Qs.toLocaleString()]})]}),i.jsxs("div",{className:"flex justify-between font-semibold pt-2 border-t",children:[i.jsx("span",{children:"Total"}),i.jsxs("span",{children:["₦",xr.toLocaleString()]})]}),i.jsxs("p",{className:"text-xs text-muted-foreground pt-1",children:["You'll earn ",x.toLocaleString()," loyalty points"]})]})]}),i.jsx("div",{className:"fixed bottom-0 left-0 right-0 bg-card border-t border-border p-4 z-40",children:i.jsx("div",{className:"max-w-3xl mx-auto",children:i.jsx(ue,{className:"w-full h-12 text-base",onClick:_u,disabled:ee,children:ee?"Placing order...":`Place order · ₦${xr.toLocaleString()}`})})})]})})},CC=({isOpen:e,onClose:t,onSubmit:n,orderId:r,orderNumber:s})=>{const[o,a]=h.useState(0),[l,c]=h.useState(0),[u,d]=h.useState(""),[f,m]=h.useState([]),[p,b]=h.useState(!1),x=h.useRef(null),{triggerHaptic:y}=mr(),w=E=>new Promise((k,R)=>{const M=new FileReader;M.onerror=()=>R(new Error("Could not read that image")),M.onload=()=>{const I=new Image;I.onerror=()=>R(new Error("That file is not an image")),I.onload=()=>{const H=Math.min(1,1600/Math.max(I.width,I.height)),B=document.createElement("canvas");B.width=Math.round(I.width*H),B.height=Math.round(I.height*H);const U=B.getContext("2d");if(!U){k(M.result);return}U.drawImage(I,0,0,B.width,B.height),k(B.toDataURL("image/jpeg",.8))},I.src=M.result},M.readAsDataURL(E)}),g=async E=>{const k=E.target.files?Array.from(E.target.files):[];if(x.current&&(x.current.value=""),k.length===0)return;const R=4-f.length;if(R<=0)return;const M=k.slice(0,R),O=(await Promise.allSettled(M.map(w))).filter(H=>H.status==="fulfilled").map(H=>H.value);O.length>0&&(m(H=>[...H,...O].slice(0,4)),y("selection")),O.length<M.length&&K.error(M.length-O.length===1?"One photo couldn't be added":`${M.length-O.length} photos couldn't be added`)},v=E=>{m(k=>k.filter((R,M)=>M!==E)),y("selection")},S=E=>{a(E),y("selection")},j=E=>{c(E)},C=async()=>{o!==0&&(b(!0),y("success"),n(o,u,f.length>0?f:void 0),b(!1),a(0),d(""),m([]),t())},P=l||o,N={1:"Poor",2:"Fair",3:"Good",4:"Very Good",5:"Excellent"};return i.jsx(ti,{children:e&&i.jsxs(i.Fragment,{children:[i.jsx(xe.div,{initial:{opacity:0}
380,animate:{opacity:1},exit:{opacity:0},className:"fixed inset-0 bg-black/80 z-50",onClick:t}),i.jsx(xe.div,{initial:{y:"100%"},animate:{y:0},exit:{y:"100%"},transition:{type:"spring",damping:25,stiffness:300},className:"fixed bottom-0 inset-x-0 z-50 bg-card rounded-t-3xl shadow-modal safe-bottom-pad",children:i.jsxs("div",{className:"p-6",children:[i.jsx("div",{className:"w-12 h-1 bg-muted-foreground/30 rounded-full mx-auto mb-6"}),i.jsx("button",{onClick:t,className:"absolute top-6 right-6 w-8 h-8 rounded-full bg-secondary flex items-center justify-center hover:bg-accent transition-colors",children:i.jsx(vt,{className:"w-4 h-4"})}),i.jsxs("div",{className:"text-center mb-8",children:[i.jsx("div",{className:"w-16 h-16 rounded-full bg-success/20 flex items-center justify-center mx-auto mb-4",children:i.jsx("span",{className:"text-3xl",children:"🎉"})}),i.jsx("h2",{className:"text-xl font-bold mb-2",children:"Order Delivered!"}),i.jsx("p",{className:"text-muted-foreground",children:"How was your experience?"}),(s??r)&&i.jsxs("p",{className:"text-xs text-muted-foreground mt-1",children:["Order #",s??r]})]}),i.jsxs("div",{className:"flex flex-col items-center mb-6",children:[i.jsx("div",{className:"flex gap-2 mb-3",children:[1,2,3,4,5].map(E=>i.jsx(xe.button,{whileHover:{scale:1.15},whileTap:{scale:.95},onClick:()=>S(E),onMouseEnter:()=>j(E),onMouseLeave:()=>c(0),className:"p-1 transition-colors",children:i.jsx(ar,{className:Y("w-10 h-10 transition-all duration-150",E<=P?"fill-warning text-warning":"text-muted-foreground/40")})},E))}),i.jsx(ti,{mode:"wait",children:P>0&&i.jsx(xe.span,{initial:{opacity:0,y:-10},animate:{opacity:1,y:0},exit:{opacity:0,y:10},className:"text-sm font-medium text-warning",children:N[P]},P)})]}),i.jsxs("div",{className:"mb-4",children:[i.jsx(Up,{placeholder:"Share your thoughts about this order (optional)",value:u,onChange:E=>d(E.target.value),className:"min-h-[100px] bg-secondary border-border resize-none",maxLength:500}),i.jsxs("p",{className:"text-xs text-muted-foreground text-right mt-1",children:[u.length,"/500"]})]}),i.jsxs("div",{className:"mb-6",children:[i.jsx("input",{type:"file",ref:x,onChange:g,accept:"image/*",multiple:!0,className:"hidden"}),i.jsxs("div",{className:"flex items-center gap-2 flex-wrap",children:[f.map((E,k)=>i.jsxs(xe.div,{initial:{opacity:0,scale:.8},animate:{opacity:1,scale:1},exit:{opacity:0,scale:.8},className:"relative w-16 h-16 rounded-lg overflow-hidden border border-border",children:[i.jsx("img",{src:E,alt:`Attachment ${k+1}`,className:"w-full h-full object-cover"}),i.jsx("button",{onClick:()=>v(k),className:"absolute top-0.5 right-0.5 w-5 h-5 bg-foreground
380/80 rounded-full flex items-center justify-center",children:i.jsx(vt,{className:"w-3 h-3 text-background"})})]},k)),f.length<4&&i.jsxs(xe.button,{whileHover:{scale:1.05},whileTap:{scale:.95},onClick:()=>{var E;return(E=x.current)==null?void 0:E.click()},className:"w-16 h-16 rounded-lg border-2 border-dashed border-border flex flex-col items-center justify-center gap-1 text-muted-foreground hover:border-foreground hover:text-foreground transition-colors",children:[i.jsx(yE,{className:"w-5 h-5"}),i.jsx("span",{className:"text-[10px]",children:"Add"})]})]}),i.jsx("p",{className:"text-xs text-muted-foreground mt-2",children:"Add up to 4 photos (optional)"})]}),i.jsx(ue,{onClick:C,disabled:o===0||p,className:"w-full h-14 text-base font-bold gap-2",children:p?i.jsx(xe.div,{animate:{rotate:360},transition:{repeat:1/0,duration:1,ease:"linear"},className:"w-5 h-5 border-2 border-primary-foreground/30 border-t-primary-foreground rounded-full"}):i.jsxs(i.Fragment,{children:[i.jsx(NE,{className:"w-5 h-5"}),"Submit Review"]})}),i.jsx("button",{onClick:t,className:"w-full py-3 text-muted-foreground text-sm mt-2 hover:text-foreground transition-colors",children:"Maybe later"})]})})]})})},zh={forOrder(e){return he(`/storefront/me/orders/${e}/review`)},submit(e,t){return he(`/storefront/me/orders/${e}/review`,{method:"POST",body:JSON.stringify(t)})}},Ii=[{id:"pending",label:"Order Received",icon:_b,description:"We've got your order"},{id:"preparing",label:"Preparing",icon:uE,description:"Our chefs are at it"},{id:"ready",label:"Ready",icon:zm,description:"Order is ready"},{id:"served",label:"On the way / Picked up",icon:cE,description:"Heading your way"},{id:"completed",label:"Completed",icon:xE,description:"Enjoy your meal!"}],Dv=()=>{var y,w;const e=Je(),{id:t}=z1(),{triggerHaptic:n}=mr(),[r,s]=h.useState(null),[o,a]=h.useState(!0),[l,c]=h.useState(null),[u,d]=h.useState(null),[f,m]=h.useState(!1);h.useEffect(()=>{if(!t){a(!1);return}let g=!1,v=null,S=0,j=null;const C=async()=>{try{const E=await Io.get(t);if(g)return;v&&E.status!==v&&n("light"),v=E.status,S=0,s(E),c(null)}catch(E){g||(S+=1,c(E.message??"Couldn't load order"),S>=3&&j!=null&&(window.clearInterval(j),j=null))}finally{g||a(!1)}},P=$p("order_tracking");C(),P&&(j=window.setInterval(()=>{if(v==="completed"||v==="cancelled"){j!=null&&window.clearInterval(j),j=null;return}C()},8e3));const N=()=>{g||(S=0,P&&j==null&&v!=="completed"&&v!=="cancelled"&&(j=window.setInterval(()=>void C(),8e3)),C())};return window.addEventListener("focus",N),()=>{g=!0,j!=null&&window.clearInterval(j),window.removeEventListener("focus",N)}},[t,n]),h.useEffect(()=>{!r||u!==null||r.status!=="completed"&&r.status!=="served"||zh.forOrder(r.id).then(g=>{d(!!g),g||setTimeout(()=>m(!0),1200)}).catch(()=>d(!1))},[r,u]);const p=async(g,v,S)=>{if(r)try{const j=await zh.submit(r.id,{rating:g,comment:v||void 0,images:S});j!=null&&j.imagesFailed?K.warning(j.imagesFailed===1?"Review saved, but your photo couldn't be uploaded":`Review saved, but ${j.imagesFailed} photos couldn't be uploaded`):K.success(`Thanks for your ${g}-star review!`),d(!0)}catch(j){K.error(j.message??"Couldn't submit review")}},b=h.useMemo(()=>{if(!r)return 0;if(r.status==="cancelled")return-1;const g=r.status==="delivering"?"served":r.status==="initiated"?"pending":r.status,v=Ii.findIndex(S=>S.id===g);return v===-1?0:v},[r]);if(o)return i.jsx(Xe,{children:i.jsx("div",{className:"min-h-screen flex items-center justify-center",children:i.jsx("p",{className:"text-muted-foreground",children:"Loading order…"})})});if(!t||!r)return i.jsx(Xe,{children:i.jsxs("div",{className:"min-h-screen bg-background flex flex-col items-center justify-center p-6 text-center",children:[i.jsx(zm,{className:"w-12 h-12 text-muted-foreground mb-3"}),i.jsx("h1",{className:"text-lg font-bold mb-1",children:"No order to track"}),i.jsx("p",{className:"text-sm text-muted-foreground mb-4",children:l??"Place an order from the menu to start tracking."}),i.jsx(ue,{onClick:()=>e("/"),children:"Browse menu"})]})});const x=r.status==="cancelled";return i.jsxs(Xe,{children:[i.jsxs("div",{className:"min-h-screen bg-background pb-8",children:[i.jsx("header",{className:"sticky top-0 z-40 bg-background border-b border-border",children:i.jsx("div",{className:"max-w-7xl mx-auto flex items-center h-14 px-4 lg:px-6",children:i.jsxs("button",{onClick:()=>e("/"),className:"flex items-center gap-2 text-muted-foreground hover:text-foreground",children:[i.jsx(Fn,{className:"w-5 h-5"}),i.jsx("span",{children:"Back"})]})})}),i.jsx("div",{className:"max-w-7xl mx-auto px-4 lg:px-6 py-6",children:i.jsxs("div",{className:"lg:grid lg:grid-cols-3 lg:gap-8",children:[i.jsxs("div",{className:"lg:col-span-2 space-y-6",children:[i.jsxs("div",{className:"text-center py-8",children:[i.jsx("div",{className:"w-20 h-20 rounded-full bg-primary/10 flex items-center justify-center mx-auto mb-4 animate-pulse",children:x?i.jsx(hE,{className:"w-10 h-10 text-destructive"}):r.status==="completed"?i.jsx(_b,{className:"w-10 h-10 text-primary"}):i.jsxs("span",{className:"text-4xl",children:[r.status==="initiated"&&"✅",r.status==="pending"&&"✅",r.status==="preparing"&&"👨‍🍳",r.status==="ready"&&"📦",r.status==="delivering"&&"🛵",r.status==="served"&&(r.isDelivery?"🛵":"🤝")]})}),i.jsx("h1",{className:"text-2xl font-bold mb-2",children:x?"Order Cancelled":((y=Ii[b])==null?void 0:y.label)??"Pending"}),i.jsx("p",{className:"text-muted-foreground",children:x?"Your order was cancelled.":(w=Ii[b])==null?void 0:w.description}),i.jsxs("p",{className:"text-xs text-muted-foreground mt-2",children:["Order #",r.orderNumber]})]}),!x&&i.jsxs("div",{className:"bg-card rounded-2xl p-6 shadow-card",children:[i.jsx("h2",{className:"font-bold mb-6",children:"Order Progress"}),i.jsx("div",{className:"space-y-1",children:Ii.map((g,v)=>{const S=v<=b,j=v===b,C=g.icon;return i.jsxs("div",{className:"flex gap-4",children:[i.jsxs("div",{className:"flex flex-col items-center",children:[i.jsx("div",{className:Y("w-10 h-10 rounded-full flex items-center justify-center transition-all",S?"bg-primary text-primary-foreground":"bg-secondary text-muted-foreground",j&&"scale-110"),children:i.jsx(C,{className:"w-5 h-5"})}),v!==Ii.length-1&&i.jsx("div",{className:Y("w-0.5 h-12 transition-colors",S?"bg-primary":"bg-border")})]}),i.jsxs("div",{className:"pb-8 flex-1",children:[i.jsx("p",{className:Y("font-medium",S?"text-foreground":"text-muted-foreground"),children:g.label}),i.jsx("p",{className:"text-sm text-muted-foreground",children:g.description})]})]},g.id)})})]})]}),i.jsxs("div",{className:"lg:col-span-1 space-y-6 mt-6 lg:mt-0",children:[i.jsxs("div",{className:"bg-card rounded-2xl p-4",children:[i.jsx("h2",{className:"font-bold mb-3",children:"Summary"}),i.jsxs("div",{className:"space-y-2 text-sm",children:[r.items.map(g=>i.jsxs("div",{className:"flex justify-between",children:[i.jsxs("span",{children:[g.quantity,"× ",g.name]}
380),i.jsxs("span",{children:["₦",Number(g.subtotal).toLocaleString()]})]},g.id)),i.jsxs("div",{className:"flex justify-between border-t pt-2 mt-2",children:[i.jsx("span",{className:"text-muted-foreground",children:"Subtotal"}),i.jsxs("span",{children:["₦",Number(r.subtotal).toLocaleString()]})]}),r.deliveryFee>0&&i.jsxs("div",{className:"flex justify-between",children:[i.jsx("span",{className:"text-muted-foreground",children:"Delivery"}),i.jsxs("span",{children:["₦",Number(r.deliveryFee).toLocaleString()]})]}),i.jsxs("div",{className:"flex justify-between",children:[i.jsx("span",{className:"text-muted-foreground",children:"Tax"}),i.jsxs("span",{children:["₦",Number(r.taxAmount).toLocaleString()]})]}),r.tipAmount>0&&i.jsxs("div",{className:"flex justify-between",children:[i.jsx("span",{className:"text-muted-foreground",children:"Tip"}),i.jsxs("span",{children:["₦",Number(r.tipAmount).toLocaleString()]})]}),r.couponDiscount>0&&i.jsxs("div",{className:"flex justify-between text-green-600",children:[i.jsxs("span",{children:["Coupon (",r.couponCode,")"]}),i.jsxs("span",{children:["−₦",Number(r.couponDiscount).toLocaleString()]})]}),i.jsxs("div",{className:"flex justify-between font-semibold border-t pt-2 mt-2",children:[i.jsx("span",{children:"Total"}),i.jsxs("span",{children:["₦",Number(r.total).toLocaleString()]})]}),i.jsxs("div",{className:"flex justify-between text-xs",children:[i.jsx("span",{className:"text-muted-foreground",children:"Payment"}),i.jsxs("span",{className:"capitalize",children:[r.paymentChannel," · ",r.paymentStatus??"n/a"]})]})]})]}),r.isDelivery&&r.deliveryAddress&&i.jsxs("div",{className:"bg-card rounded-2xl p-4",children:[i.jsx("h2",{className:"font-bold mb-2",children:"Delivery to"}),i.jsx("p",{className:"text-sm",children:String(r.deliveryAddress.line1??"")}),i.jsx("p",{className:"text-xs text-muted-foreground",children:String(r.deliveryAddress.city??"")})]}),u===!1&&r.status==="completed"&&i.jsx(ue,{className:"w-full",variant:"outline",onClick:()=>m(!0),children:"Leave a review"})]})]})})]}),i.jsx(CC,{isOpen:f,onClose:()=>m(!1),onSubmit:p})]})},Lv=20,oV=()=>{const e=Je(),{triggerHaptic:t}=mr(),{menuItems:n}=Kn(),{addItem:r}=Nn(),[s,o]=h.useState([]),[a,l]=h.useState(1),[c,u]=h.useState(1),[d,f]=h.useState(!0),[m,p]=h.useState(!1),[b,x]=h.useState(null),[y,w]=h.useState(null),[g,v]=h.useState(()=>new Set);h.useEffect(()=>{let k=!1;return f(!0),Io.list({page:1,limit:Lv}).then(R=>{k||(o(R.data),u(R.totalPages),l(R.page),x(null))}).catch(R=>{k||x(R.message??"Couldn't load orders")}).finally(()=>{k||f(!1)}),()=>{k=!0}},[]);const S=async()=>{if(!(m||a>=c)){p(!0);try{const k=await Io.list({page:a+1,limit:Lv});o(R=>[...R,...k.data]),l(k.page),u(k.totalPages)}catch(k){K.error(k.message??"Couldn't load more orders")}finally{p(!1)}}},j=k=>new Date(k).toLocaleDateString("en-US",{month:"short",day:"numeric",year:"numeric"}),C=k=>new Date(k).toLocaleTimeString("en-US",{hour:"numeric",minute:"2-digit",hour12:!0}),P=k=>{const R={initiated:"bg-yellow-500/10 text-yellow-600",pending:"bg-yellow-500/10 text-yellow-600",preparing:"bg-blue-500/10 text-blue-600",ready:"bg-indigo-500/10 text-indigo-600",delivering:"bg-blue-500/10 text-blue-600",served:"bg-success/10 text-success",completed:"bg-success/10 text-success",cancelled:"bg-destructive/10 text-destructive"};return i.jsx("span",{className:`px-2 py-0.5 rounded-full text-xs font-medium capitalize ${R[k]}`,children:k})},N=k=>{t("light");let R=0,M=0,I=0;for(const O of k.items){if(!O.productId){M+=1;continue}const H=n.find(B=>B.id===O.productId);if(!H){M+=1;continue}if(Nu(H)){I+=1;continue}r(H,O.quantity),R+=1}if(R===0){K.error(I>0?"Those items need options chosen — please add them from the menu.":"None of those items are still on the menu.");return}I>0?K.success(`${R} item(s) added — ${I} need options chosen on the menu.`):M>0?K.success(`${R} item(s) added — ${M} no longer available.`):K.success(`${R} item${R===1?"":"s"} added to your cart`),e("/")},E=async(k,R,M)=>{if(y)try{const I=await zh.submit(y.id,{rating:k,comment:R||void 0,images:M});I!=null&&I.imagesFailed?K.warning(I.imagesFailed===1?"Review saved, but your photo couldn't be uploaded":`Review saved, but ${I.imagesFailed} photos couldn't be uploaded`):K.success(`Thanks for your ${k}-star review!`),v(O=>new Set(O).add(y.id)),w(null)}
380catch(I){if(I instanceof Tj&&I.status===409){K.info("You've already reviewed this order"),v(O=>new Set(O).add(y.id)),w(null);return}K.error(I.message??"Couldn't submit review")}};return d?i.jsx(Xe,{children:i.jsx(gF,{})}):i.jsxs(Xe,{children:[i.jsxs("div",{className:"min-h-screen bg-background pb-28 lg:pb-8",children:[i.jsx("header",{className:"sticky top-0 z-40 bg-background border-b border-border",children:i.jsxs("div",{className:"flex items-center h-14 px-4 max-w-7xl mx-auto lg:px-6",children:[i.jsx("button",{onClick:()=>e(-1),className:"flex items-center gap-2 text-muted-foreground hover:text-foreground",children:i.jsx(Fn,{className:"w-5 h-5"})}),i.jsx("h1",{className:"text-lg font-bold ml-4",children:"Order History"})]})}),i.jsxs("div",{className:"max-w-3xl mx-auto px-4 lg:px-6 py-6 space-y-4",children:[b&&i.jsx("p",{className:"text-sm text-destructive text-center",children:b}),s.length===0?i.jsx(Bi,{children:i.jsxs("div",{className:"text-center py-16",children:[i.jsx("p",{className:"text-muted-foreground mb-4",children:"No orders yet"}),i.jsx(ue,{onClick:()=>e("/"),children:"Browse menu"})]})}):i.jsx(cF,{className:"space-y-3",children:s.map(k=>i.jsx(dF,{children:i.jsxs("button",{onClick:()=>e(`/order-tracking/${k.id}`),className:"w-full bg-card rounded-2xl p-4 text-left hover:bg-secondary/50 transition-colors",children:[i.jsxs("div",{className:"flex items-start justify-between mb-2",children:[i.jsxs("div",{children:[i.jsxs("p",{className:"font-semibold",children:["#",k.orderNumber]}),i.jsxs("p",{className:"text-xs text-muted-foreground",children:[j(k.createdAt)," · ",C(k.createdAt)]})]}),P(k.status)]}),i.jsx("p",{className:"text-sm text-muted-foreground mb-3 line-clamp-1",children:k.items.map(R=>`${R.quantity}× ${R.name}`).join(", ")}),i.jsxs("div",{className:"flex items-center justify-between",children:[i.jsxs("div",{className:"flex items-center gap-1.5 text-xs text-muted-foreground",children:[i.jsx(er,{className:"w-3 h-3"}),i.jsx("span",{children:k.isDelivery?"Delivery":"Pickup"})]}),i.jsxs("div",{className:"flex items-center gap-3",children:[i.jsxs("span",{className:"font-semibold",children:["₦",Number(k.total).toLocaleString()]}),(k.status==="completed"||k.status==="served")&&!g.has(k.id)&&i.jsxs("button",{onClick:R=>{R.stopPropagation(),w(k)},className:"flex items-center gap-1 text-xs text-primary hover:underline",children:[i.jsx(ar,{className:"w-3 h-3"})," Review"]}),(k.status==="completed"||k.status==="served")&&i.jsxs("button",{onClick:R=>{R.stopPropagation(),N(k)},className:"flex items-center gap-1 text-xs text-primary hover:underline",children:[i.jsx(jE,{className:"w-3 h-3"})," Reorder"]}),i.jsx($s,{className:"w-4 h-4 text-muted-foreground"})]})]})]})},k.id))}),s.length>0&&a<c&&i.jsx("div",{className:"text-center pt-2",children:i.jsx(ue,{variant:"outline",onClick:S,disabled:m,children:m?"Loading…":"Load more"})})]})]}),i.jsx(CC,{isOpen:!!y,onClose:()=>w(null),onSubmit:E,orderId:y==null?void 0:y.id,orderNumber:y==null?void 0:y.orderNumber})]})},iV=({isOpen:e,onClose:t,onSaved:n})=>{const{profile:r}=Tt(),[s,o]=h.useState({firstName:"",lastName:"",email:"",phone:"",birthday:""}),[a,l]=h.useState(!1);h.useEffect(()=>{r&&o({firstName:r.firstName,lastName:r.lastName,email:r.email??"",phone:r.phone??"",birthday:r.birthday??""})},[r]);const c=async()=>{if(!s.firstName.trim()||!s.lastName.trim()){K.error("First and last name are required");return}l(!0);try{await Cs.update({firstName:s.firstName,lastName:s.lastName,email:s.email||null,phone:s.phone||null,birthday:s.birthday||null}),K.success("Profile updated"),n==null||n()}catch(u){K.error(u.message??"Couldn't update profile")}finally{l(!1)}};return i.jsxs(i.Fragment,{children:[i.jsx("div",{className:Y("fixed inset-0 bg-foreground
380/40 z-50 transition-opacity duration-300",e?"opacity-100":"opacity-0 pointer-events-none"),onClick:t}),i.jsxs("div",{className:Y("fixed z-50 bg-card shadow-modal transition-all duration-300 flex flex-col","inset-x-0 bottom-0 rounded-t-3xl max-h-[90vh]",e?"translate-y-0":"translate-y-full","lg:inset-auto lg:top-1/2 lg:left-1/2 lg:-translate-x-1/2 lg:rounded-2xl lg:w-full lg:max-w-md lg:max-h-[80vh]",e?"lg:-translate-y-1/2 lg:opacity-100":"lg:-translate-y-1/2 lg:opacity-0 lg:pointer-events-none"),onClick:u=>u.stopPropagation(),children:[i.jsxs("div",{className:"flex items-center justify-between p-5 pb-3 border-b border-border",children:[i.jsx("h2",{className:"text-lg font-bold",children:"Edit Profile"}),i.jsx("button",{onClick:t,className:"w-9 h-9 rounded-full bg-secondary flex items-center justify-center",children:i.jsx(vt,{className:"w-4 h-4"})})]}),i.jsxs("div",{className:"flex-1 overflow-y-auto p-5 space-y-4",children:[i.jsxs("div",{className:"grid grid-cols-2 gap-3",children:[i.jsxs("div",{className:"space-y-2",children:[i.jsx(pt,{htmlFor:"firstName",children:"First name"}),i.jsx(Ke,{id:"firstName",value:s.firstName,onChange:u=>o({...s,firstName:u.target.value})})]}),i.jsxs("div",{className:"space-y-2",children:[i.jsx(pt,{htmlFor:"lastName",children:"Last name"}),i.jsx(Ke,{id:"lastName",value:s.lastName,onChange:u=>o({...s,lastName:u.target.value})})]})]}),i.jsxs("div",{className:"space-y-2",children:[i.jsx(pt,{htmlFor:"email",children:"Email"}),i.jsx(Ke,{id:"email",type:"email",value:s.email,onChange:u=>o({...s,email:u.target.value})})]}),i.jsxs("div",{className:"space-y-2",children:[i.jsx(pt,{htmlFor:"phone",children:"Phone"}),i.jsx(Ke,{id:"phone",type:"tel",value:s.phone,onChange:u=>o({...s,phone:u.target.value})})]}),i.jsxs("div",{className:"space-y-2",children:[i.jsx(pt,{htmlFor:"birthday",children:"Birthday"}),i.jsx(Ke,{id:"birthday",type:"date",value:s.birthday,onChange:u=>o({...s,birthday:u.target.value})})]})]}),i.jsx("div",{className:"p-5 pt-3 border-t border-border safe-bottom-pad",children:i.jsx(ue,{onClick:c,className:"w-full h-12 rounded-full",disabled:a,children:a?"Saving…":"Save Changes"})})]})]})},aV=()=>{const e=Je(),{profile:t,isLoading:n,isAuthenticated:r,logout:s,refreshProfile:o}=Tt(),{config:a}=hr(),l=Number((a==null?void 0:a.nairaPerPoint)??.1),[c,u]=h.useState(!1);if(n)return i.jsx(Xe,{children:i.jsx(mF,{})});if(!r||!t)return i.jsx(Xe,{children:i.jsxs("div",{className:"min-h-screen flex flex-col items-center justify-center p-6 text-center",children:[i.jsx(Zf,{className:"w-12 h-12 text-muted-foreground mb-3"}),i.jsx("h1",{className:"text-lg font-bold mb-1",children:"Sign in to view profile"}),i.jsx(ue,{onClick:()=>e("/login"),className:"mt-2",children:"Sign in"})]})});const d=`${t.firstName} ${t.lastName}`.trim(),f=t.referralCode,p=`${typeof window<"u"?window.location.origin:"https://store"}/register?ref=${f}`,b=()=>{navigator.clipboard.writeText(p),K.success("Referral link copied!")},x=()=>{navigator.clipboard.writeText(f),K.success("Referral code copied!")},y=async()=>{if(navigator.share)try{await navigator.share({title:"Join us",text:`Use my referral code ${f} to claim a welcome bonus.`,url:p})}catch{b()}else b()},w=async()=>{await s(),K.success("Signed out"),e("/")},g=[{icon:gE,label:"Order History",onClick:()=>e("/order-history")},{icon:Zi,label:"Payment Methods",onClick:()=>e("/payment-methods")},{icon:ar,label:"Rewards & Points",onClick:()=>K.info(`You have ${t.points} points`)},{icon:CE,label:"Settings",onClick:()=>e("/settings")}];return i.jsxs(Xe,{children:[i.jsxs("div",{className:"min-h-screen bg-background pb-28 lg:pb-8",children:[i.jsx("header",{className:"sticky top-0 z-40 bg-background border-b border-border",children:i.jsxs("div",{className:"flex items-center h-14 px-4 max-w-7xl mx-auto lg:px-6",children:[i.jsx("button",{onClick:()=>e(-1),className:"flex items-center gap-2 text-muted-foreground hover:text-foreground",children:i.jsx(Fn,{className:"w-5 h-5"})}),i.jsx("h1",{className:"text-lg font-bold ml-4",children:"Profile"})]})}),i.jsx("div",{className:"max-w-7xl mx-auto px-4 lg:px-6 py-6",children:i.jsxs("div",{className:"lg:grid lg:grid-cols-2 lg:gap-8",children:[i.jsxs("div",{children:[i.jsx(Bi,{delay:.1,children:i.jsxs("div",{className:"flex items-center gap-4 p-4 lg:p-6 bg-card rounded-2xl border border-border mb-6",children:[i.jsx("div",{className:"w-14 h-14 lg:w-20 lg:h-20 rounded-full bg-primary/10 flex items-center justify-center",children:i.jsx(Zf,{className:"w-6 h-6 lg:w-8 lg:h-8 text-primary"})}),i.jsxs("div",{className:"flex-1",children:[i.jsx("h2",{className:"font-bold lg:text-xl",children:d}),i.jsx("p",{className:"text-sm text-muted-foreground",children:t.email??"No email"}),i.jsx("p",{className:"text-xs text-muted-foreground",children:t.phone??""})]}),i.jsx(ue,{variant:"outline",size:"sm",className:"rounded-full",onClick:()=>u(!0),children:"Edit"})]})}),i.jsx(Bi,{delay:.2,children:i.jsxs("div",{className:"grid grid-cols-2 gap-3 mb-6",children:[i.jsxs("div",{className:"p-4 lg:p-6 bg-card rounded-2xl border border-border text-center",children:[i.jsx("p",{className:"text-2xl lg:text-3xl font-bold text-primary",children:t.points.toLocaleStr
380ing()}),i.jsxs("p",{className:"text-xs text-muted-foreground",children:["≈ ₦",Math.floor(t.points*l).toLocaleString()]}),i.jsx("p",{className:"text-sm text-muted-foreground",children:"Points"})]}),i.jsxs("div",{className:"p-4 lg:p-6 bg-card rounded-2xl border border-border text-center",children:[i.jsxs("p",{className:"text-2xl lg:text-3xl font-bold",children:["₦",t.walletBalance.toLocaleString()]}),i.jsx("p",{className:"text-sm text-muted-foreground",children:"Wallet"})]})]})}),i.jsx(Bi,{delay:.3,children:i.jsxs("div",{className:"p-4 lg:p-6 bg-card rounded-2xl border border-border mb-6",children:[i.jsx("h3",{className:"font-bold mb-1",children:"Refer a Friend"}),i.jsx("p",{className:"text-sm text-muted-foreground mb-3",children:"Share your referral link. You both earn a reward when your friend places their first paid order."}),i.jsxs("button",{onClick:x,className:"w-full mb-3 px-3 py-3 bg-primary/10 rounded-lg text-center hover:bg-primary/15 transition-colors",children:[i.jsx("p",{className:"text-xs text-muted-foreground uppercase tracking-wide",children:"Your code"}),i.jsx("p",{className:"text-lg font-bold font-mono text-primary",children:f}),i.jsx("p",{className:"text-[10px] text-muted-foreground mt-1",children:"Tap to copy"})]}),i.jsxs("div",{className:"flex items-center gap-2",children:[i.jsx("div",{className:"flex-1 px-3 py-2 bg-secondary rounded-lg text-xs truncate text-muted-foreground",children:p}),i.jsx(ue,{variant:"outline",size:"icon",onClick:b,className:"rounded-lg flex-shrink-0",children:i.jsx(Bm,{className:"w-4 h-4"})}),i.jsx(ue,{size:"icon",onClick:y,className:"rounded-lg flex-shrink-0",children:i.jsx(Fb,{className:"w-4 h-4"})})]}),i.jsx("button",{onClick:()=>e("/referrals"),className:"text-xs text-primary hover:underline mt-3",children:"See referral history →"})]})})]}),i.jsx(Bi,{delay:.25,direction:"right",children:i.jsxs("div",{children:[i.jsx("div",{className:"bg-card rounded-2xl border border-border overflow-hidden",children:g.map((v,S)=>i.jsxs("button",{onClick:v.onClick,className:`w-full flex items-center gap-3 p-4 hover:bg-secondary/50 transition-colors ${S!==g.length-1?"border-b border-border":""}`,children:[i.jsx(v.icon,{className:"w-5 h-5 text-muted-foreground"}),i.jsx("span",{className:"flex-1 text-left font-medium",children:v.label}),i.jsx($s,{className:"w-4 h-4 text-muted-foreground"})]},v.label))}),i.jsxs("button",{onClick:w,className:"w-full flex items-center justify-center gap-2 p-4 mt-6 text-destructive hover:bg-destructive/10 rounded-xl transition-colors",children:[i.jsx(wE,{className:"w-5 h-5"}),i.jsx("span",{className:"font-medium",children:"Log out"})]})]})})]})})]}),i.jsx(iV,{isOpen:c,onClose:()=>u(!1),onSaved:()=>{o(),u(!1)}})]})},lV={pending:"Pending",signed_up:"Signed up",first_purchase:"First order placed",rewarded:"Rewarded",expired:"Expired"},cV={pending:"bg-yellow-100 text-yellow-700",signed_up:"bg-blue-100 text-blue-700",first_purchase:"bg-indigo-100 text-indigo-700",rewarded:"bg-green-100 text-green-700",expired:"bg-gray-100 text-gray-700"},uV=e=>new Date(e).toLocaleDateString("en-US",{month:"short",day:"numeric",year:"numeric"}),ef=(e,t)=>t==="wallet_credit"?`₦${e.toLocaleString()}`:`${e.toLocaleString()} pts`;function dV(){const e=Je(),{isAuthenticated:t}=Tt(),[n,r]=h.useState(null),[s,o]=h.useState(!0);h.useEffect(()=>{if(!t){o(!1);return}let m=!1;return Gj.mySummary().then(p=>{m||r(p)}).catch(p=>{m||K.error(p.message??"Couldn't load referral history")}).finally(()=>{m||o(!1)}),()=>{m=!0}},[t]);const a=(n==null?void 0:n.referralCode)??"",l=typeof window<"u"?window.location.origin:"https://store",c=a?`${l}/register?ref=${a}`:"",u=()=>{a&&(navigator.clipboard.writeText(a),K.success("Referral code copied"))},d=()=>{c&&(navigator.clipboard.writeText(c),K.success("Referral link copied"))},f=async()=>{if(c){if(navigator.share)try{await navigator.share({title:"Join me",text:`Use my referral code ${a} for a welcome bonus.`,url:c});return}catch{}d()}};return t?i.jsx(Xe,{children:i.jsxs("div",{className:"min-h-screen bg-background pb-28 lg:pb-8",children:[i.jsx("header",{className:"sticky top-0 z-40 bg-background border-b border-border",children:i.jsxs("div",{className:"flex items-center h-14 px-4 max-w-7xl mx-auto lg:px-6",children:[i.jsx("button",{onClick:()=>e(-1),className:"flex items-center gap-2 text-muted-foreground hover:text-foreground",children:i.jsx(Fn,{className:"w-5 h-5"})}),i.jsx("h1",{className:"text-lg font-bold ml-4",children:"Refer a Friend"})]})}),i.jsx("div",{className:"max-w-2xl mx-auto px-4 lg:px-6 py-6 space-y-4",children:s?i.jsx("p",{className:"text-sm text-muted-foreground text-center py-8",children:"Loading…"}):n?i.jsxs(i.Fragment,{children:[i.jsxs("div",{className:"bg-primary/5 border border-primary/20 rounded-2xl p-5 text-center",children:[i.jsx(PE,{className:"w-7 h-7 text-primary mx-auto mb-2"}),i.jsx("p",{className:"text-sm text-muted-foreground",children:"Your code"}),i.jsx("p",{className:"text-2xl font-bold font-mono mt-1 text-primary",children:a}),i.jsxs("div",{className:"flex items-center justify-center gap-2 mt-4",children:[i.jsxs(ue,{variant:"outline",size:"sm",onClick:u,className:"gap-2",children:[i.jsx(Bm,{className:"w-4 h-4"})," Copy code"]}),i.jsxs(ue,{size:"sm",onClick:f,className:"gap-2",children:[i.jsx(Fb,{className:"w-4 h-4"})," Share link"]})]}),i.jsx("p",{className:"text-xs text-muted-foreground mt-3",children:"Friends who sign up with your code get a wel
380come bonus — you'll earn yours once they place their first paid order."})]}),i.jsxs("div",{className:"grid grid-cols-3 gap-3",children:[i.jsxs("div",{className:"rounded-xl bg-card border border-border p-3 text-center",children:[i.jsx(RE,{className:"w-5 h-5 text-muted-foreground mx-auto mb-1"}),i.jsx("p",{className:"text-2xl font-bold",children:n.totalReferred}),i.jsx("p",{className:"text-xs text-muted-foreground",children:"Referred"})]}),i.jsxs("div",{className:"rounded-xl bg-card border border-border p-3 text-center",children:[i.jsx("p",{className:"text-2xl font-bold text-success",children:ef(n.totalRewardEarned,n.rewardType)}),i.jsx("p",{className:"text-xs text-muted-foreground",children:"Earned"})]}),i.jsxs("div",{className:"rounded-xl bg-card border border-border p-3 text-center",children:[i.jsx("p",{className:"text-2xl font-bold text-yellow-600",children:ef(n.totalRewardPending,n.rewardType)}),i.jsx("p",{className:"text-xs text-muted-foreground",children:"Pending"})]})]}),i.jsxs("div",{className:"bg-card rounded-2xl border border-border overflow-hidden",children:[i.jsx("div",{className:"px-4 py-3 border-b border-border",children:i.jsx("p",{className:"font-medium text-sm",children:"Referral history"})}),n.referrals.length===0?i.jsx("div",{className:"p-6 text-center text-sm text-muted-foreground",children:"No referrals yet — share your code to get started."}):i.jsx("div",{className:"divide-y divide-border",children:n.referrals.map(m=>i.jsxs("div",{className:"p-4 flex items-center justify-between gap-3",children:[i.jsxs("div",{className:"min-w-0",children:[i.jsx("p",{className:"text-sm font-medium truncate",children:m.referredName??m.referredEmail??m.referredPhone??"Anonymous"}),i.jsx("p",{className:"text-xs text-muted-foreground",children:uV(m.createdAt)})]}),i.jsxs("div",{className:"text-right",children:[i.jsx("span",{className:`inline-block text-xs font-medium px-2 py-1 rounded-full ${cV[m.status]}`,children:lV[m.status]}),i.jsx("p",{className:"text-xs text-muted-foreground mt-1",children:ef(Number(m.referrerReward),m.rewardType)})]})]},m.id))})]})]}):i.jsx("p",{className:"text-sm text-muted-foreground text-center py-8",children:"We couldn't load your referrals."})})]})}):i.jsx(Xe,{children:i.jsxs("div",{className:"min-h-screen flex flex-col items-center justify-center p-6 text-center",children:[i.jsx(Jf,{className:"w-12 h-12 text-muted-foreground mb-3"}),i.jsx("h1",{className:"text-lg font-bold mb-1",children:"Sign in to view referrals"}),i.jsx(ue,{onClick:()=>e("/login"),className:"mt-2",children:"Sign in"})]})})}const fV=()=>{const e=Je(),{isAuthenticated:t}=Tt(),[n,r]=h.useState([]),[s,o]=h.useState(!0);h.useEffect(()=>{if(!t){o(!1);return}let u=!1;return Zl.list().then(d=>{u||r(d)}).catch(d=>{u||K.error(d.message??"Couldn't load cards")}).finally(()=>{u||o(!1)}),()=>{u=!0}},[t]);const a=u=>{const d={visa:"text-blue-600",mastercard:"text-orange-500",verve:"text-green-600",amex:"text-indigo-500",discover:"text-amber-500",other:"text-muted-foreground"};return i.jsx(Zi,{className:`w-8 h-8 ${d[u]}`})},l=async u=>{try{const d=await Zl.update(u,{isDefault:!0});r(f=>f.map(m=>({...m,isDefault:m.id===d.id}))),K.success("Default payment method updated")}catch(d){K.error(d.message??"Couldn't update")}},c=async u=>{if(confirm("Remove this card?"))try{await Zl.remove(u),r(d=>d.filter(f=>f.id!==u)),K.success("Card removed")}catch(d){K.error(d.message??"Couldn't remove")}};return t?i.jsx(Xe,{children:i.jsxs("div",{className:"min-h-screen bg-background pb-24 lg:pb-8",children:[i.jsx("header",{className:"sticky top-0 z-40 bg-background border-b border-border",children:i.jsxs("div",{className:"flex items-center h-14 px-4 max-w-7xl mx-auto lg:px-6",children:[i.jsx("button",{onClick:()=>e(-1),className:"flex items-center gap-2 text-muted-foreground hover:text-foreground",children:i.jsx(Fn,{className:"w-5 h-5"})}),i.jsx("h1",{className:"text-lg font-bold ml-4",children:"Payment Methods"})]})}),i.jsxs("div",{className:"max-w-2xl mx-auto px-4 lg:px-6 py-6 space-y-4",children:[s?i.jsx("p",{className:"text-sm text-muted-foreground text-center py-8",children:"Loading…"}):n.length===0?i.jsxs("div",{className:"bg-card rounded-2xl border border-dashed p-6 text-center",children:[i.jsx(Zi,{className:"w-10 h-10 text-muted-foreground mx-auto mb-3"}),i.jsx("h2",{className:"font-semibold mb-1",children:"No saved cards yet"}),i.jsx("p",{className:"text-sm text-muted-foreground",children:"Cards are saved automatically when you pay with Paystack."})]}):n.map(u=>i.jsxs("div",{className:"bg-card rounded-2xl border border-border p-4 flex items-center gap-4",children:[i.jsx("div",{className:"w-12 h-12 rounded-xl bg-secondary flex items-center justify-center",children:a(u.brand)}),i.jsxs("div",{className:"flex-1",children:[i.jsxs("div",{className:"flex items-center gap-2",children:[i.jsxs("span",{className:"font-semibold capitalize",children:[u.brand," •••• ",u.last4]}),u.isDefault&&i.jsx("span",{className:"px-2 py-0.5 bg-primary/10 text-primary text-xs font-medium rounded-full",children:"Default"})]}),i.jsxs("p",{className:"text-sm text-muted-foreground",children:[u.bank?`${u.bank} · `:"","Expires ",u.expMonth,"/",u.expYear]})]}),i.jsxs("div",{className:"flex items-center gap-2",children:[!u.isDefault&&i.jsx(ue,{variant:"ghost",size:"icon",onClick:()=>l(u.id),className:"w-9 h-9",title:"Set as default",children:i.jsx(fE,{className:"w-4 h-4"})}),i.jsx(ue,{variant:"ghost",size:"icon",onClick:()=>c(u.id),className:"w-9 h-9 text-destructive hover:text-destructive",children:i.jsx(EE,{className:"w-4 h-4"})})]})]},u.id)),i.jsx("p",{className:"text-xs text-center text-muted-foreground px-4",children:"Your card details are tokenised by Paystack — we only ever store the last 4 digits."})]})]})}):i.jsx(Xe,{children:i.jsxs("div",{className:"min-h-screen flex flex-col items-center justify-center p-6 text-center",children:[i.jsx(Zi,{className:"w-12 h-12 text-muted-foreground mb-3"}),i.jsx("h1",{className:"text-lg font-bold mb-1",children:"Sign in to manage cards"}),i.jsx(ue,{onClick:()=>
380e("/login"),className:"mt-2",children:"Sign in"})]})})};var Du="Switch",[hV]=qs(Du),[mV,pV]=hV(Du),kC=h.forwardRef((e,t)=>{const{__scopeSwitch:n,name:r,checked:s,defaultChecked:o,required:a,disabled:l,value:c="on",onCheckedChange:u,form:d,...f}=e,[m,p]=h.useState(null),b=Se(t,v=>p(v)),x=h.useRef(!1),y=m?d||!!m.closest("form"):!0,[w,g]=ba({prop:s,defaultProp:o??!1,onChange:u,caller:Du});return i.jsxs(mV,{scope:n,checked:w,disabled:l,children:[i.jsx(fe.button,{type:"button",role:"switch","aria-checked":w,"aria-required":a,"data-state":RC(w),"data-disabled":l?"":void 0,disabled:l,value:c,...f,ref:b,onClick:oe(e.onClick,v=>{g(S=>!S),y&&(x.current=v.isPropagationStopped(),x.current||v.stopPropagation())})}),y&&i.jsx(TC,{control:m,bubbles:!x.current,name:r,value:c,checked:w,required:a,disabled:l,form:d,style:{transform:"translateX(-100%)"}})]})});kC.displayName=Du;var PC="SwitchThumb",EC=h.forwardRef((e,t)=>{const{__scopeSwitch:n,...r}=e,s=pV(PC,n);return i.jsx(fe.span,{"data-state":RC(s.checked),"data-disabled":s.disabled?"":void 0,...r,ref:t})});EC.displayName=PC;var gV="SwitchBubbleInput",TC=h.forwardRef(({__scopeSwitch:e,control:t,checked:n,bubbles:r=!0,...s},o)=>{const a=h.useRef(null),l=Se(a,o),c=FN(n),u=l1(t);return h.useEffect(()=>{const d=a.current;if(!d)return;const f=window.HTMLInputElement.prototype,p=Object.getOwnPropertyDescriptor(f,"checked").set;if(c!==n&&p){const b=new Event("click",{bubbles:r});p.call(d,n),d.dispatchEvent(b)}},[c,n,r]),i.jsx("input",{type:"checkbox","aria-hidden":!0,defaultChecked:n,...s,tabIndex:-1,ref:l,style:{...s.style,...u,position:"absolute",pointerEvents:"none",opacity:0,margin:0}})});TC.displayName=gV;function RC(e){return e?"checked":"unchecked"}var AC=kC,xV=EC;const Uc=h.forwardRef(({className:e,...t},n)=>i.jsx(AC,{className:Y("peer inline-flex h-6 w-11 shrink-0 cursor-pointer items-center rounded-full border-2 border-transparent transition-colors data-[state=checked]:bg-primary data-[state=unchecked]:bg-input focus-visible:outline-none focus-visible:ring-2 focus-visible:ring-ring focus-visible:ring-offset-2 focus-visible:ring-offset-background disabled:cursor-not-allowed disabled:opacity-50",e),...t,ref:n,children:i.jsx(xV,{className:Y("pointer-events-none block h-5 w-5 rounded-full bg-background shadow-lg ring-0 transition-transform data-[state=checked]:translate-x-5 data-[state=unchecked]:translate-x-0")})}));Uc.displayName=AC.displayName;const Rl={publicKey:()=>he("/notifications/web-push/public-key"),subscribe:e=>he("/storefront/me/push-subscriptions",{method:"POST",body:JSON.stringify(e)}),list:()=>he("/storefront/me/push-subscriptions"),unsubscribe:e=>he(`/storefront/me/push-subscriptions/${e}`,{method:"DELETE"})};function yV(e){const t="=".repeat((4-e.length%4)%4),n=(e+t).replace(/-/g,"+").replace(/_/g,"/"),r=atob(n),s=new Uint8Array(r.length);for(let o=0;o<r.length;o++)s[o]=r.charCodeAt(o);return s}function _v(e){if(!e)return"";const t=new Uint8Array(e);let n="";for(let r=0;r<t.byteLength;r++)n+=String.fromCharCode(t[r]);return btoa(n).replace(/\+/g,"-").replace(/\//g,"_").replace(/=+$/,"")}function vV(){const[e,t]=h.useState("loading"),[n,r]=h.useState(null),[s,o]=h.useState(!1),a=h.useCallback(async()=>{if(r(null),typeof window>"u"){t("unsupported");return}if(!("serviceWorker"in navigator)||!("PushManager"in window)||!("Notification"in window)){t("unsupported");return}if(!gn.getToken()){t("unsubscribed");return}try{await(await navigator.serviceWorker.ready).pushManager.getSubscription()?t("subscribed"):Notification.permission==="denied"?t("permission-denied"):t("unsubscribed")}catch(u){r(u.message),t("unsubscribed")}},[]);h.useEffect(()=>{a()},[a]);const l=h.useCallback(async()=>{r(null),o(!0);try{if(!("serviceWorker"in navigator)||!("PushManager"in window))throw new Error("Push is not supported in this browser.");if(await Notification.requestPermission()!=="granted"){t("permission-denied");return}const{publicKey:d}=await Rl.publicKey();if(!d){t("unconfigured"),r("Push notifications aren't enabled by the merchant yet.");return}const m=await(await navigator.serviceWorker.ready).pushManager.subscribe({userVisibleOnly:!0,applicationServerKey:yV(d)}),b=m.toJSON().keys;await Rl.subscribe({endpoint:m.endpoint,keys:{p256dh:(b==null?void 0:b.p256dh)??_v(m.getKey("p256dh")),auth:(b==null?void 0:b.auth)??_v(m.getKey("auth"))},userAgent:navigator.userAgent}),t("subscribed")}catch(u){r(u.message??"Couldn't enable push notifications.")}finally{o(!1)}},[]),c=h.useCallback(async()=>{r(null),o(!0);try{const d=await(await navigator.serviceWorker.ready).pushManager.getSubscription();if(d){const m=(await Rl.list().catch(()=>[])).find(p=>p.endpoint===d.endpoint);m&&await Rl.unsubscribe(m.id).catch(()=>{}),await d.unsubscribe()}t("unsubscribed")}catch(u){r(u.message??"Couldn't disable push notifications.")}finally{o(!1)}},[]);return{status:e,error:n,isBusy:s,enable:l,disable:c}}const wV=[{key:"sound_effects",icon:ME,label:"Sound Effects",description:"Play sounds for notifications and actions"},{key:"haptic_feedback",icon:AE,label:"Haptic Feedback",description:"Vibration feedback on interactions"},{key:"order_tracking",icon:pE,label:"Live Order Tracking",description:"Auto-refresh the order tracking screen"},{key:"data_saver",icon:kE,label:"Data Saver Mode",description:"Reduce data usage where possible"}],bV=({item:e})=>{const[t,n]=Vj(e.key),r=e.icon;return i.jsxs("div",{className:"flex items-center gap-4 p-4",children:[i.jsx("div",{className:"w-10 h-10 rounded-xl bg-secondary flex items-center justify-center flex-shrink-0",children:i.jsx(r,{className:"w-5 h-5 text-muted-foreground"})}),i.jsxs("div",{className:"flex-1 min-w-0",children:[i.jsx("p",{className:"font-medium",children:e.label}),i.jsx("p",{className:"text-sm text-muted-foreground truncate",children:e.description})]}),i.jsx(Uc,{checked:t,onCheckedChange:n})]})},SV=()=>{const e=Je(),{theme:t,toggleTheme:n}=t3(),{config:r}=hr(),{isAuthenticated:s}=Tt(),o=vV(),a=(r==null?void 0:r.storeName)??"",l=new Date().getFullYear(),c=p=>{p?o.enable():o.disable()},u=o.status==="subscribed",d=o.status==="permission-denied",f=o.status==="unsupported",m=o.status==="unconfigured";return i.jsx(Xe,{children:i.jsxs("div",{className:"min-h-screen bg-background pb-8",children:[i.jsx("header",{className:"sticky top-0 z-40 bg-background border-b border-border",children:i.jsxs("div",{className:"flex items-center h-14 px-4 max-w-7xl mx-auto lg:px-6",children:[i.jsx("button",{onClick:()=>e(-1),className:"flex items-center gap-2 text-muted-foreground hover:text-foreground transition-colors","aria-label":"Go back",children:i.jsx(Fn,{className:"w-5 h-5"})}),i.jsx("h1",{className:"text-lg font-bold ml-4",children:"Settings"})]})}),i.jsxs("div",{className:"max-w-2xl mx-auto px-4 lg:px-6 py-6",children:[i.jsxs("div",{className:"bg-card rounded-2xl border border-border overflow-hidden divide-y divide-border",children:[i.jsxs("div",{className:"flex items-center gap-4 p-4",children:[i.jsx("div",{className:"w-10 h-10 rounded-xl bg-secondary flex items-center justify-center flex-shrink-0",children:i.jsx(SE,{className:"w-5 h-5 text-muted-foreground"})}),i.jsxs("div",{className:"flex-1 min-w-0",children:[i.jsx("p",{className:"font-medium",children:"Dark Mode"}),i.jsx("p",{className:"text-sm text-muted-foreground truncate",children:"Use dark theme throughout the app"})]}),i.jsx(Uc,{checked:t==="dark",onCheckedChange:n})]}),wV.map(p=>i.jsx(bV,{item:p},p.key)),s&&!f&&i.jsxs("div",{className:"flex items-center gap-4 p-4",children:[i.jsx("div",{className:"w-10 h-10 rounded-xl bg-secondary flex items-center justify-center flex-shrink-0",children:i.jsx(lE,{className:"w-5 h-5 text-muted-foreground"})}),i.jsxs("div",{className:"flex-1 min-w-0",children:[i.jsx("p",{className:"font-medium",children:"Push Notifications"}),i.jsx("p",{className:"text-sm text-muted-foreground truncate",children:d?"Blocked in your browser — enable notifications in site settings to turn this on.":m?"Not available yet — the merchant hasn't enabled push.":o.error?o.error:"Order updates delivered to your device when the app isn't open."})]}),i.jsx(Uc,{checked:u,disabled:o.isBusy||d||m||o.status==="loading",onCheckedChange:c})]})]}),i.jsx("div",{className:"mt-8 text-center",children:i.jsx("p",{className:"text-xs text-muted-foreground",children:a?`© ${l} ${a}. All rights reserved.`:`© ${l}. All rights reserved.`})})]})]})})};function jV(){const e=Je(),[t]=Y1(),n=t.get("redirect")||"/",{login:r}=Tt(),[s,o]=h.useState(""),[a,l]=h.useState(""),[c,u]=h.useState(!1),d=async f=>{if(f.preventDefault(),!s||!a){K.error("Email and password are required");return}const m=gi();if(!m){K.error("Storefront is not linked to a business yet");return}u(!0);try{await r({businessId:m,email:s,password:a}),K.success("Welcome back!"),e(n,{replace:!0})}catch(p){K.error(p.message??"Couldn't sign in")}finally{u(!1)}};return i.jsx("div",{className:"min-h-screen flex items-center justify-center bg-background px-4",children:i.jsxs("div",{className:"w-full max-w-md 
380space-y-6 rounded-xl border bg-card p-6 shadow-sm",children:[i.jsxs("div",{className:"space-y-1 text-center",children:[i.jsx("h1",{className:"text-2xl font-semibold",children:"Welcome back"}),i.jsx("p",{className:"text-sm text-muted-foreground",children:"Sign in to track orders and manage your account"})]}),i.jsxs("form",{onSubmit:d,className:"space-y-4",children:[i.jsxs("div",{className:"space-y-2",children:[i.jsx(pt,{htmlFor:"email",children:"Email"}),i.jsx(Ke,{id:"email",type:"email",required:!0,value:s,onChange:f=>o(f.target.value)})]}),i.jsxs("div",{className:"space-y-2",children:[i.jsx(pt,{htmlFor:"password",children:"Password"}),i.jsx(Ke,{id:"password",type:"password",required:!0,value:a,onChange:f=>l(f.target.value)})]}),i.jsx(ue,{type:"submit",className:"w-full",disabled:c,children:c?"Signing in...":"Sign In"})]}),i.jsxs("div",{className:"flex items-center gap-3",children:[i.jsx("span",{className:"h-px flex-1 bg-border"}),i.jsx("span",{className:"text-xs text-muted-foreground",children:"or"}),i.jsx("span",{className:"h-px flex-1 bg-border"})]}),i.jsx(Wp,{text:"signin_with",onSuccess:()=>{K.success("Welcome back!"),e(n,{replace:!0})}}),i.jsxs("p",{className:"text-center text-sm",children:["Don't have an account?"," ",i.jsx(Oc,{to:"/register",className:"font-medium underline",children:"Create one"})]})]})})}function NV(){const e=Je(),[t]=Y1(),{register:n}=Tt(),[r,s]=h.useState(""),[o,a]=h.useState(""),[l,c]=h.useState(""),[u,d]=h.useState(""),[f,m]=h.useState(""),[p,b]=h.useState(""),[x,y]=h.useState(!1);h.useEffect(()=>{const g=t.get("ref");if(g){b(g.toUpperCase());return}try{const v=window.localStorage.getItem("omega_referred_by");v&&b(v.toUpperCase())}catch{}},[t]);const w=async g=>{if(g.preventDefault(),!r||!o||!l||!f){K.error("Please fill in all required fields");return}if(f.length<8){K.error("Password must be at least 8 characters");return}const v=gi();if(!v){K.error("Storefront is not linked to a business yet");return}y(!0);try{await n({businessId:v,firstName:r,lastName:o,email:l,password:f,phone:u||void 0,referredByCode:p.trim()||void 0});try{window.localStorage.removeItem("omega_referred_by")}catch{}K.success("Account created!"),e("/")}catch(S){K.error(S.message??"Couldn't create account")}finally{y(!1)}};return i.jsx("div",{className:"min-h-screen flex items-center justify-center bg-background px-4 py-10",children:i.jsxs("div",{className:"w-full max-w-md 
380space-y-6 rounded-xl border bg-card p-6 shadow-sm",children:[i.jsxs("div",{className:"space-y-1 text-center",children:[i.jsx("h1",{className:"text-2xl font-semibold",children:"Create account"}),i.jsx("p",{className:"text-sm text-muted-foreground",children:"Sign up to save your details and track orders"})]}),i.jsxs("form",{onSubmit:w,className:"space-y-4",children:[i.jsxs("div",{className:"grid grid-cols-2 gap-3",children:[i.jsxs("div",{className:"space-y-2",children:[i.jsx(pt,{htmlFor:"firstName",children:"First name"}),i.jsx(Ke,{id:"firstName",required:!0,value:r,onChange:g=>s(g.target.value)})]}),i.jsxs("div",{className:"space-y-2",children:[i.jsx(pt,{htmlFor:"lastName",children:"Last name"}),i.jsx(Ke,{id:"lastName",required:!0,value:o,onChange:g=>a(g.target.value)})]})]}),i.jsxs("div",{className:"space-y-2",children:[i.jsx(pt,{htmlFor:"email",children:"Email"}),i.jsx(Ke,{id:"email",type:"email",required:!0,value:l,onChange:g=>c(g.target.value)})]}),i.jsxs("div",{className:"space-y-2",children:[i.jsx(pt,{htmlFor:"phone",children:"Phone (optional)"}),i.jsx(Ke,{id:"phone",type:"tel",value:u,onChange:g=>d(g.target.value)})]}),i.jsxs("div",{className:"space-y-2",children:[i.jsx(pt,{htmlFor:"password",children:"Password"}),i.jsx(Ke,{id:"password",type:"password",required:!0,value:f,onChange:g=>m(g.target.value)}),i.jsx("p",{className:"text-xs text-muted-foreground",children:"At least 8 characters"})]}),i.jsxs("div",{className:"space-y-2",children:[i.jsx(pt,{htmlFor:"referralCode",children:"Referral code (optional)"}),i.jsx(Ke,{id:"referralCode",value:p,onChange:g=>b(g.target.value.toUpperCase()),placeholder:"e.g. REF-A8K3"}),i.jsx("p",{className:"text-xs text-muted-foreground",children:"Got invited? Enter the code to claim your welcome bonus."})]}),i.jsx(ue,{type:"submit",className:"w-full",disabled:x,children:x?"Creating...":"Create account"})]}),i.jsxs("div",{className:"flex items-center gap-3",children:[i.jsx("span",{className:"h-px flex-1 bg-border"}),i.jsx("span",{className:"text-xs text-muted-foreground",children:"or"}),i.jsx("span",{className:"h-px flex-1 bg-border"})]}),i.jsx(Wp,{text:"signup_with",onSuccess:()=>{try{window.localStorage.removeItem("omega_referred_by")}catch{}K.success("Account created!"),e("/")}}),i.jsxs("p",{className:"text-center text-sm",children:["Already have an account?"," ",i.jsx(Oc,{to:"/login",className:"font-medium underline",children:"Sign in"})]})]})})}const CV=()=>{const e=Je(),{config:t}=hr(),n=(t==null?void 0:t.storeName)||"Storefront",r=(t==null?void 0:t.logoUrl)||DN;return i.jsx("header",{className:"bg-background border-b border-border",children:i.jsx("div",{className:"container flex items-center justify-between h-14 px-4 max-w-7xl mx-auto",children:i.jsx("div",{className:"flex items-center gap-2 cursor-pointer",onClick:()=>e("/"),children:i.jsx("img",{src:r,alt:n,className:"h-10 w-auto"})})})})};function kV(){const{slug:e}=z1(),t=Je(),[n,r]=h.useState(null),[s,o]=h.useState(!0),[a,l]=h.useState(null);return h.useEffect(()=>{if(!e)return;let c=!1;return o(!0),(async()=>{try{const u=await xi.getPage(e);c||(r(u),l(null),u.metaTitle&&(document.title=u.metaTitle))}catch(u){c||(l(u.message??"Page not found"),r(null))}finally{c||o(!1)}})(),()=>{c=!0}},[e]),i.jsxs("div",{className:"min-h-screen bg-background",children:[i.jsx(CV,{}),i.jsx("main",{className:"max-w-3xl mx-auto px-4 py-10",children:s?i.jsxs("div",{className:"space-y-3",children:[i.jsx(z,{className:"h-10 w-2/3"}),i.jsx(z,{className:"h-6 w-full"}),i.jsx(z,{className:"h-6 w-full"}),i.jsx(z,{className:"h-6 w-3/4"})]}):a||!n?i.jsxs("div",{className:"text-center py-20",children:[i.jsx("h1",{className:"text-2xl font-semibold mb-2",children:"Page not found"}),i.jsx("p",{className:"text-muted-foreground mb-6",children:a??"We couldn't find the page you're looking for."}),i.jsx("button",{onClick:()=>t("/"),className:"text-primary underline",children:"Back home"})]}):i.jsxs("article",{children:[i.jsxs("header",{className:"mb-6",children:[i.jsx("h1",{className:"text-3xl font-bold tracking-tight",children:n.name}),n.metaDescription&&i.jsx("p",{className:"text-muted-foreground mt-2",children:n.metaDescription})]}),i.jsx("div",{className:"prose prose-neutral dark:prose-invert max-w-none whitespace-pre-wrap",children:n.content||""})]})}),i.jsx(ON,{})]})}const PV=()=>{const e=Hn();return h.useEffect(()=>{},[e.pathname]),i.jsx(Xe,{children:i.jsx("div",{className:"flex min-h-screen items-center justify-center bg-background px-4",children:i.jsx("div",{className:"max-w-md w-full",children:i.jsxs("div",{className:"bg-card rounded-2xl border border-border p-8 lg:p-12 text-center",children:[i.jsx("div",{className:"w-20 h-20 lg:w-24 lg:h-24 rounded-full bg-primary/10 flex items-center justify-center mx-auto mb-6",children:i.jsx("span",{className:"text-4xl lg:text-5xl",children:"🔍"})}),i.jsx("h1",{className:"mb-2 text-5xl lg:text-6xl font-bold",children:"404"}),i.jsx("p",{className:"mb-6 text-lg text-muted-foreground",children:"Oops! Page not found"}),i.jsx("a",{href:"/",className:"inline-flex items-center justify-center h-12 px-8 bg-primary text-primary-foreground rounded-full font-semibold hover:bg-primary/90 transition-colors",children:"Return to Home"})]})})})})};function EV(){const{isAuthenticated:e,isLoading:t}=Tt(),n=Hn();if(t)return i.jsx("div",{className:"min-h-screen flex items-center justify-center text-sm text-muted-foreground",children:"Loading…"});if(!e){const r=encodeURIComponent(`${n.pathname}${n.search}`);return i.jsx(qM,{to:`/login?redirect=${r}`,replace:!0})}return i.jsx(QM,{})}const TV=new tM,RV=()=>{const e=Hn();return i.jsx(ti,{mode:"wait",children:i.jsxs(JM,{location:e,children:[i.jsx(dt,{path:"/",element:i.jsx(vF,{})}),i.jsx(dt,{path:"/login",element:i.jsx(jV,{})}),i.jsx(dt,{path:"/register",element:i.jsx(NV,{})}),i.jsx(dt,{path:"/p/:slug",element:i.jsx(kV,{})}),i.jsxs(dt,{element:i.jsx(EV,{}),children:[i.jsx(dt,{path:"/checkout",element:i.jsx(sV,{})}),i.jsx(dt,{path:"/order-tracking",element:i.jsx(Dv,{})}),i.jsx(dt,{path:"/order-tracking/:id",element:i.jsx(Dv,{})}),i.jsx(dt,{path:"/order-history",element:i.jsx(oV,{})}),i.jsx(dt,{path:"/profile",element:i.jsx(aV,{})}),i.jsx(dt,{path:"/referrals",element:i.jsx(dV,{})}),i.jsx(dt,{path:"/payment-methods",element:i.jsx(fV,{})}),i.jsx(dt,{path:"/settings",element:i.jsx(SV,{})})]}),i.jsx(dt,{path:"*",element:i.jsx(PV,{})})]},e.pathname)})},AV=()=>i.jsx(rM,{client:TV,children:i.jsx(e3,{children:i.jsx(qL,{children:i.jsx(KL,{children:i.jsx(ZL,{children:i.jsx(i3,{children:i.jsxs(AA,{children:[i.jsx(mT,{}),i.jsx(KT,{position:"top-center"}),i.jsxs(i4,{children:[i.jsx(a3,{}),i.jsx(l3,{children:i.jsx(RV,{})})]})]})})})})})})});YL().finally(()=>{ib(document.getElementById("root")).render(i.jsx(AV,{}))});

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.