vendor: 4,966 bytes, lines 1-10
1const __vite__mapDeps=(i,m=__vite__mapDeps,d=(m.f||(m.f=["assets/AdminDashboard-wdoVHJcn.js","assets/use-mobile-Bv6qHDZS.js","assets/plus-B6G5Uwc9.js","assets/arrow-left-q3JHNQXJ.js","assets/search-5mTtkvxE.js","assets/external-link-BLgL_y7E.js","assets/loader-circle-FPuliJKw.js","assets/CaseDetail-AzgP5wPd.js","assets/MemberAuth-CA7IRgxz.js","assets/circle-alert-DQlVEDfr.js","assets/MemberDashboard-BgUc8TeM.js","assets/DashboardSidebar-C8juAWEM.js","assets/ClientDashboard-oRgLFysq.js","assets/DiagnosisPage-CJ4Wd1mD.js"])))=>i.map(i=>d[i]); 2var nT=Object.defineProperty;var Iv=e=>{throw TypeError(e)};var rT=(e,t,n)=>t in e?nT(e,t,{enumerable:!0,configurable:!0,writable:!0,value:n}):e[t]=n;var Cr=(e,t,n)=>rT(e,typeof t!="symbol"?t+"":t,n),df=(e,t,n)=>t.has(e)||Iv("Cannot "+n);var j=(e,t,n)=>(df(e,t,"read from private field"),n?n.call(e):t.get(e)),Te=(e,t,n)=>t.has(e)?Iv("Cannot add the same private member more than once"):t instanceof WeakSet?t.add(e):t.set(e,n),pe=(e,t,n,r)=>(df(e,t,"write to private field"),r?r.call(e,n):t.set(e,n),n),wt=(e,t,n)=>(df(e,t,"access private method"),n);var lc=(e,t,n,r)=>({set _(s){pe(e,t,s,n)},get _(){return j(e,t,r)}});function sT(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 i of o.addedNodes)i.tagName==="LINK"&&i.rel==="modulepreload"&&r(i)}).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)}})();var bz=typeof globalThis<"u"?globalThis:typeof window<"u"?window:typeof global<"u"?global:typeof self<"u"?self:{};function Hl(e){return e&&e.__esModule&&Object.prototype.hasOwnProperty.call(e,"default")?e.default:e}var db={exports:{}},cd={},fb={exports:{}},be={};/** 3 * @license React 4 * react.production.min.js 5 * 6 * Copyright (c) Facebook, Inc. and its affiliates. 7 * 8 * This source code is licensed under the MIT license found in the 9 * LICENSE file in the root directory of this source tree. 10 */var Vl=Symbol.for("react.element"),oT=Symbol.for("react.portal"),iT=Symbol.for("react.fragment"),aT=Symbol.for("react.strict_mode"),lT=Symbol.for("react.profiler"),cT=Symbol.for("react.provider"),uT=Symbol.for("react.context"),dT=Symbol.for("react.forward_ref"),fT=Symbol.for("react.suspense"),hT=Symbol.for("react.memo"),pT=Symbol.for("react.lazy"),Dv=Symbol.iterator;function mT(e){return e===null||typeof e!="object"?null:(e=Dv&&e[Dv]||e["@@iterator"],typeof e=="function"?e:null)}var hb={isMounted:function(){return!1},enqueueForceUpdate:function(){},enqueueReplaceState:function(){},enqueueSetState:function(){}},pb=Object.assign,mb={};function Qi(e,t,n){this.props=e,this.context=t,this.refs=mb,this.updater=n||hb}Qi.prototype.isReactComponent={};Qi.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")};Qi.prototype.forceUpdate=function(e){this.updater.enqueueForceUpdate(this,e,"forceUpdate")};function gb(){}gb.prototype=Qi.prototype;function km(e,t,n){this.props=e,this.context=t,this.refs=mb,this.updater=n||hb}var Cm=km.prototype=new gb;Cm.constructor=km;pb(Cm,Qi.prototype);Cm.isPureReactComponent=!0;var Mv=Array.isArray,vb=Object.prototype.hasOwnProperty,Tm={current:null},yb={key:!0,ref:!0,__self:!0,__source:!0};function wb(e,t,n){var r,s={},o=null,i=null;if(t!=null)for(r in t.ref!==void 0&&(i=t.ref),t.key!==void 0&&(o=""+t.key),t)vb.call(t,r)&&!yb.hasOwnProperty(r)&&(s[r]=t[r]);var a=arguments.length-2;if(a===1)s.children=n;else if(1<a){for(var l=Array(a),c=0;c<a;c++)l[c]=arguments[c+2];s.children=l}if(e&&e.defaultProps)for(r in a=e.defaultProps,a)s[r]===void 0&&(s[r]=a[r]);return{$$typeof:Vl,type:e,key:o,ref:i,props:s,_owner:Tm.current}}function gT(e,t){return{$$typeof:Vl,type:e.type,key:t,ref:e.ref,props:e.props,_owner:e._owner}}function Rm(e){return typeof e=="object"&&e!==null&&e.$$typeof===Vl}function vT(e){var t={"=":"=0",":":"=2"};return"$"+e.replace(/[=:]/g,function(n){return t[n]})}var Lv=/\/+/g;function ff(e,t){return typeof e=="object"&&e!==null&&e.key!=null?vT(""+e.key):t.toString(36)}
vendor: 4,786 bytes, lines 10-18
10function Vc(e,t,n,r,s){var o=typeof e;(o==="undefined"||o==="boolean")&&(e=null);var i=!1;if(e===null)i=!0;else switch(o){case"string":case"number":i=!0;break;case"object":switch(e.$$typeof){case Vl:case oT:i=!0}}if(i)return i=e,s=s(i),e=r===""?"."+ff(i,0):r,Mv(s)?(n="",e!=null&&(n=e.replace(Lv,"$&/")+"/"),Vc(s,t,n,"",function(c){return c})):s!=null&&(Rm(s)&&(s=gT(s,n+(!s.key||i&&i.key===s.key?"":(""+s.key).replace(Lv,"$&/")+"/")+e)),t.push(s)),1;if(i=0,r=r===""?".":r+":",Mv(e))for(var a=0;a<e.length;a++){o=e[a];var l=r+ff(o,a);i+=Vc(o,t,n,l,s)}else if(l=mT(e),typeof l=="function")for(e=l.call(e),a=0;!(o=e.next()).done;)o=o.value,l=r+ff(o,a++),i+=Vc(o,t,n,l,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 i}function cc(e,t,n){if(e==null)return e;var r=[],s=0;return Vc(e,r,"","",function(o){return t.call(n,o,s++)}),r}function yT(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 It={current:null},qc={transition:null},wT={ReactCurrentDispatcher:It,ReactCurrentBatchConfig:qc,ReactCurrentOwner:Tm};function bb(){throw Error("act(...) is not supported in production builds of React.")}be.Children={map:cc,forEach:function(e,t,n){cc(e,function(){t.apply(this,arguments)},n)},count:function(e){var t=0;return cc(e,function(){t++}),t},toArray:function(e){return cc(e,function(t){return t})||[]},only:function(e){if(!Rm(e))throw Error("React.Children.only expected to receive a single React element child.");return e}};be.Component=Qi;be.Fragment=iT;be.Profiler=lT;be.PureComponent=km;be.StrictMode=aT;be.Suspense=fT;be.__SECRET_INTERNALS_DO_NOT_USE_OR_YOU_WILL_BE_FIRED=wT;be.act=bb;be.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=pb({},e.props),s=e.key,o=e.ref,i=e._owner;if(t!=null){if(t.ref!==void 0&&(o=t.ref,i=Tm.current),t.key!==void 0&&(s=""+t.key),e.type&&e.type.defaultProps)var a=e.type.defaultProps;for(l in t)vb.call(t,l)&&!yb.hasOwnProperty(l)&&(r[l]=t[l]===void 0&&a!==void 0?a[l]:t[l])}var l=arguments.length-2;if(l===1)r.children=n;else if(1<l){a=Array(l);for(var c=0;c<l;c++)a[c]=arguments[c+2];r.children=a}return{$$typeof:Vl,type:e.type,key:s,ref:o,props:r,_owner:i}};be.createContext=function(e){return e={$$typeof:uT,_currentValue:e,_currentValue2:e,_threadCount:0,Provider:null,Consumer:null,_defaultValue:null,_globalName:null},e.Provider={$$typeof:cT,_context:e},e.Consumer=e};be.createElement=wb;be.createFactory=function(e){var t=wb.bind(null,e);return t.type=e,t};be.createRef=function(){return{current:null}};be.forwardRef=function(e){return{$$typeof:dT,render:e}};be.isValidElement=Rm;be.lazy=function(e){return{$$typeof:pT,_payload:{_status:-1,_result:e},_init:yT}};be.memo=function(e,t){return{$$typeof:hT,type:e,compare:t===void 0?null:t}};be.startTransition=function(e){var t=qc.transition;qc.transition={};try{e()}finally{qc.transition=t}};be.unstable_act=bb;be.useCallback=function(e,t){return It.current.useCallback(e,t)};be.useContext=function(e){return It.current.useContext(e)};be.useDebugValue=function(){};be.useDeferredValue=function(e){return It.current.useDeferredValue(e)};be.useEffect=function(e,t){return It.current.useEffect(e,t)};be.useId=function(){return It.current.useId()};be.useImperativeHandle=function(e,t,n){return It.current.useImperativeHandle(e,t,n)};be.useInsertionEffect=function(e,t){return It.current.useInsertionEffect(e,t)};be.useLayoutEffect=function(e,t){return It.current.useLayoutEffect(e,t)};be.useMemo=function(e,t){return It.current.useMemo(e,t)};be.useReducer=function(e,t,n){return It.current.useReducer(e,t,n)};be.useRef=function(e){return It.current.useRef(e)};be.useState=function(e){return It.current.useState(e)};be.useSyncExternalStore=function(e,t,n){return It.current.useSyncExternalStore(e,t,n)};be.useTransition=function(){return It.current.useTransition()};be.version="18.3.1";fb.exports=be;var m=fb.exports;const O=Hl(m),Pm=sT({__proto__:null,default:O},[m]);/** 11 * @license React 12 * react-jsx-runtime.production.min.js 13 * 14 * Copyright (c) Facebook, Inc. and its affiliates. 15 * 16 * This source code is licensed under the MIT license found in the 17 * LICENSE file in the root directory of this source tree. 18 */var bT=m,xT=Symbol.for("react.element"),_T=Symbol.for("react.fragment"),ST=Object.prototype.hasOwnProperty,ET=bT.__SECRET_INT
vendor: 11,413 bytes, lines 18-35
18ERNALS_DO_NOT_USE_OR_YOU_WILL_BE_FIRED.ReactCurrentOwner,kT={key:!0,ref:!0,__self:!0,__source:!0};function xb(e,t,n){var r,s={},o=null,i=null;n!==void 0&&(o=""+n),t.key!==void 0&&(o=""+t.key),t.ref!==void 0&&(i=t.ref);for(r in t)ST.call(t,r)&&!kT.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:xT,type:e,key:o,ref:i,props:s,_owner:ET.current}}cd.Fragment=_T;cd.jsx=xb;cd.jsxs=xb;db.exports=cd;var f=db.exports,_b={exports:{}},cn={},Sb={exports:{}},Eb={};/** 19 * @license React 20 * scheduler.production.min.js 21 * 22 * Copyright (c) Facebook, Inc. and its affiliates. 23 * 24 * This source code is licensed under the MIT license found in the 25 * LICENSE file in the root directory of this source tree. 26 */(function(e){function t(T,N){var z=T.length;T.push(N);e:for(;0<z;){var V=z-1>>>1,X=T[V];if(0<s(X,N))T[V]=N,T[z]=X,z=V;else break e}}function n(T){return T.length===0?null:T[0]}function r(T){if(T.length===0)return null;var N=T[0],z=T.pop();if(z!==N){T[0]=z;e:for(var V=0,X=T.length,ee=X>>>1;V<ee;){var ce=2*(V+1)-1,le=T[ce],Oe=ce+1,W=T[Oe];if(0>s(le,z))Oe<X&&0>s(W,le)?(T[V]=W,T[Oe]=z,V=Oe):(T[V]=le,T[ce]=z,V=ce);else if(Oe<X&&0>s(W,z))T[V]=W,T[Oe]=z,V=Oe;else break e}}return N}function s(T,N){var z=T.sortIndex-N.sortIndex;return z!==0?z:T.id-N.id}if(typeof performance=="object"&&typeof performance.now=="function"){var o=performance;e.unstable_now=function(){return o.now()}}else{var i=Date,a=i.now();e.unstable_now=function(){return i.now()-a}}var l=[],c=[],u=1,d=null,p=3,h=!1,x=!1,v=!1,b=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 y(T){for(var N=n(c);N!==null;){if(N.callback===null)r(c);else if(N.startTime<=T)r(c),N.sortIndex=N.expirationTime,t(l,N);else break;N=n(c)}}function _(T){if(v=!1,y(T),!x)if(n(l)!==null)x=!0,B(S);else{var N=n(c);N!==null&&I(_,N.startTime-T)}}function S(T,N){x=!1,v&&(v=!1,w(R),R=-1),h=!0;var z=p;try{for(y(N),d=n(l);d!==null&&(!(d.expirationTime>N)||T&&!D());){var V=d.callback;if(typeof V=="function"){d.callback=null,p=d.priorityLevel;var X=V(d.expirationTime<=N);N=e.unstable_now(),typeof X=="function"?d.callback=X:d===n(l)&&r(l),y(N)}else r(l);d=n(l)}if(d!==null)var ee=!0;else{var ce=n(c);ce!==null&&I(_,ce.startTime-N),ee=!1}return ee}finally{d=null,p=z,h=!1}}var k=!1,E=null,R=-1,P=5,A=-1;function D(){return!(e.unstable_now()-A<P)}function M(){if(E!==null){var T=e.unstable_now();A=T;var N=!0;try{N=E(!0,T)}finally{N?H():(k=!1,E=null)}}else k=!1}var H;if(typeof g=="function")H=function(){g(M)};else if(typeof MessageChannel<"u"){var L=new MessageChannel,Z=L.port2;L.port1.onmessage=M,H=function(){Z.postMessage(null)}}else H=function(){b(M,0)};function B(T){E=T,k||(k=!0,H())}function I(T,N){R=b(function(){T(e.unstable_now())},N)}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(){x||h||(x=!0,B(S))},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"):P=0<T?Math.floor(1e3/T):5},e.unstable_getCurrentPriorityLevel=function(){return p},e.unstable_getFirstCallbackNode=function(){return n(l)},e.unstable_next=function(T){switch(p){case 1:case 2:case 3:var N=3;break;default:N=p}var z=p;p=N;try{return T()}finally{p=z}},e.unstable_pauseExecution=function(){},e.unstable_requestPaint=function(){},e.unstable_runWithPriority=function(T,N){switch(T){case 1:case 2:case 3:case 4:case 5:break;default:T=3}var z=p;p=T;try{return N()}finally{p=z}},e.unstable_scheduleCallback=function(T,N,z){var V=e.unstable_now();switch(typeof z=="object"&&z!==null?(z=z.delay,z=typeof z=="number"&&0<z?V+z:V):z=V,T){case 1:var X=-1;break;case 2:X=250;break;case 5:X=1073741823;break;case 4:X=1e4;break;default:X=5e3}return X=z+X,T={id:u++,callback:N,priorityLevel:T,startTime:z,expirationTime:X,sortIndex:-1},z>V?(T.sortIndex=z,t(c,T),n(l)===null&&T===n(c)&&(v?(w(R),R=-1):v=!0,I(_,z-V))):(T.sortIndex=X,t(l,T),x||h||(x=!0,B(S))),T},e.unstable_shouldYield=D,e.unstable_wrapCallback=function(T){var N=p;return function(){var z=p;p=N;try{return T.apply(this,arguments)}finally{p=z}}}})(Eb);Sb.exports=Eb;var CT=Sb.exports;/** 27 * @license React 28 * react-dom.production.min.js 29 * 30 * Copyright (c) Facebook, Inc. and its affiliates. 31 * 32 * This source code is licensed under the MIT license found in the 33 * LICENSE file in the root directory of this source tree. 34 */var TT=m,on=CT;function $(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 kb=new Set,al={};function Oo(e,t){Di(e,t),Di(e+"Capture",t)}function Di(e,t){for(al[e]=t,e=0;e<t.length;e++)kb.add(t[e])}var Br=!(typeof window>"u"||typeof window.document>"u"||typeof window.document.createElement>"u"),Ph=Object.prototype.hasOwnProperty,RT=/^[: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]*$/,$v={},Fv={};function PT(e){return Ph.call(Fv,e)?!0:Ph.call($v,e)?!1:RT.test(e)?Fv[e]=!0:($v[e]=!0,!1)}function NT(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 AT(e,t,n,r){if(t===null||typeof t>"u"||NT(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 Dt(e,t,n,r,s,o,i){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=i}var vt={};"children dangerouslySetInnerHTML defaultValue defaultChecked innerHTML suppressContentEditableWarning suppressHydrationWarning style".split(" ").forEach(function(e){vt[e]=new Dt(e,0,!1,e,null,!1,!1)});[["acceptCharset","accept-charset"],["className","class"],["htmlFor","for"],["httpEquiv","http-equiv"]].forEach(function(e){var t=e[0];vt[t]=new Dt(t,1,!1,e[1],null,!1,!1)});["contentEditable","draggable","spellCheck","value"].forEach(function(e){vt[e]=new Dt(e,2,!1,e.toLowerCase(),null,!1,!1)});["autoReverse","externalResourcesRequired","focusable","preserveAlpha"].forEach(function(e){vt[e]=new Dt(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){vt[e]=new Dt(e,3,!1,e.toLowerCase(),null,!1,!1)});["checked","multiple","muted","selected"].forEach(function(e){vt[e]=new Dt(e,3,!0,e,null,!1,!1)});["capture","download"].forEach(function(e){vt[e]=new Dt(e,4,!1,e,null,!1,!1)});["cols","rows","size","span"].forEach(function(e){vt[e]=new Dt(e,6,!1,e,null,!1,!1)});["rowSpan","start"].forEach(function(e){vt[e]=new Dt(e,5,!1,e.toLowerCase(),null,!1,!1)});var Nm=/[\-:]([a-z])/g;function Am(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(Nm,Am);vt[t]=new Dt(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(Nm,Am);vt[t]=new Dt(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(Nm,Am);vt[t]=new Dt(t,1,!1,e,"http://www.w3.org/XML/1998/namespace",!1,!1)});["tabIndex","crossOrigin"].forEach(function(e){vt[e]=new Dt(e,1,!1,e.toLowerCase(),null,!1,!1)});vt.xlinkHref=new Dt("xlinkHref",1,!1,"xlink:href","http://www.w3.org/1999/xlink",!0,!1);["src","href","action","formAction"].forEach(function(e){vt[e]=new Dt(e,1,!1,e.toLowerCase(),null,!0,!0)});function Om(e,t,n,r){var s=vt.hasOwnProperty(t)?vt[t]:null;(s!==null?s.type!==0:r||!(2<t.length)||t[0]!=="o"&&t[0]!=="O"||t[1]!=="n"&&t[1]!=="N")&&(AT(t,n,s,r)&&(n=null),r||s===null?PT(t)&&(n===null?e.removeAttribute(t):e.setAttribute(t,""+n)):s.mustUseProperty?e[s.propertyName]=n===null?s.type===3?!1:"":n:(t=s.attributeName,r=s.attributeNamespace,n===null?e.removeAttribute(t):(s=s.type,n=s===3||s===4&&n===!0?"":""+n,r?e.setAttributeNS(r,t,n):e.setAttribute(t,n))))}var Gr=TT.__SECRET_INTERNALS_DO_NOT_USE_OR_YOU_WILL_BE_FIRED,uc=Symbol.for("react.element"),ni=Symbol.for("react.portal"),ri=Symbol.for("react.fragment"),jm=Symbol.for("react.strict_mode"),Nh=Symbol.for("react.profiler"),Cb=Symbol.for("react.provider"),Tb=Symbol.for("react.context"),Im=Symbol.for("react.forward_ref"),Ah=Symbol.for("react.suspense"),Oh=Symbol.for("react.suspense_list"),Dm=Symbol.for("react.memo"),os=Symbol.for("react.lazy"),Rb=Symbol.for("react.offscreen"),Uv=Symbol.iterator;function ya(e){return e===null||typeof e!="object"?null:(e=Uv&&e[Uv]||e["@@iterator"],typeof e=="function"?e:null)}var Ve=Object.assign,hf;function Ba(e){if(hf===void 0)try{throw Error()}catch(n){var t=n.stack.trim().match(/\n( *(at )?)/);hf=t&&t[1]||""}return` 35`+hf+e}var pf=!1;function mf(e,t){if(!e||pf)return"";pf=!0;var n=Error.prepareStackTrace;Error.prepareStackTrace=void 0;try{if(t)if(t=function(){throw Error()},Object.defineProperty(t.prototype,"props",{set:function(){throw Error()}}),typeof Reflect=="object"&&Reflect.construct){try{Reflect.construct(t,[])}catch(c){var r=c}Reflect.construct(e,[],t)}else{try{t.call()}catch(c){r=c}e.call(t.prototype)}else{try{throw Error()}catch(c){r=c}e()}}
vendor: 15,674 bytes, lines 35-38
35catch(c){if(c&&r&&typeof c.stack=="string"){for(var s=c.stack.split(` 36`),o=r.stack.split(` 37`),i=s.length-1,a=o.length-1;1<=i&&0<=a&&s[i]!==o[a];)a--;for(;1<=i&&0<=a;i--,a--)if(s[i]!==o[a]){if(i!==1||a!==1)do if(i--,a--,0>a||s[i]!==o[a]){var l=` 38`+s[i].replace(" at new "," at ");return e.displayName&&l.includes("<anonymous>")&&(l=l.replace("<anonymous>",e.displayName)),l}while(1<=i&&0<=a);break}}}finally{pf=!1,Error.prepareStackTrace=n}return(e=e?e.displayName||e.name:"")?Ba(e):""}function OT(e){switch(e.tag){case 5:return Ba(e.type);case 16:return Ba("Lazy");case 13:return Ba("Suspense");case 19:return Ba("SuspenseList");case 0:case 2:case 15:return e=mf(e.type,!1),e;case 11:return e=mf(e.type.render,!1),e;case 1:return e=mf(e.type,!0),e;default:return""}}function jh(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 ri:return"Fragment";case ni:return"Portal";case Nh:return"Profiler";case jm:return"StrictMode";case Ah:return"Suspense";case Oh:return"SuspenseList"}if(typeof e=="object")switch(e.$$typeof){case Tb:return(e.displayName||"Context")+".Consumer";case Cb:return(e._context.displayName||"Context")+".Provider";case Im:var t=e.render;return e=e.displayName,e||(e=t.displayName||t.name||"",e=e!==""?"ForwardRef("+e+")":"ForwardRef"),e;case Dm:return t=e.displayName||null,t!==null?t:jh(e.type)||"Memo";case os:t=e._payload,e=e._init;try{return jh(e(t))}catch{}}return null}function jT(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 jh(t);case 8:return t===jm?"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 Os(e){switch(typeof e){case"boolean":case"number":case"string":case"undefined":return e;case"object":return e;default:return""}}function Pb(e){var t=e.type;return(e=e.nodeName)&&e.toLowerCase()==="input"&&(t==="checkbox"||t==="radio")}function IT(e){var t=Pb(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(i){r=""+i,o.call(this,i)}}),Object.defineProperty(e,t,{enumerable:n.enumerable}),{getValue:function(){return r},setValue:function(i){r=""+i},stopTracking:function(){e._valueTracker=null,delete e[t]}}}}function dc(e){e._valueTracker||(e._valueTracker=IT(e))}function Nb(e){if(!e)return!1;var t=e._valueTracker;if(!t)return!0;var n=t.getValue(),r="";return e&&(r=Pb(e)?e.checked?"true":"false":e.value),e=r,e!==n?(t.setValue(e),!0):!1}function pu(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 Ih(e,t){var n=t.checked;return Ve({},t,{defaultChecked:void 0,defaultValue:void 0,value:void 0,checked:n??e._wrapperState.initialChecked})}function Bv(e,t){var n=t.defaultValue==null?"":t.defaultValue,r=t.checked!=null?t.checked:t.defaultChecked;n=Os(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 Ab(e,t){t=t.checked,t!=null&&Om(e,"checked",t,!1)}function Dh(e,t){Ab(e,t);var n=Os(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")?Mh(e,t.type,n):t.hasOwnProperty("defaultValue")&&Mh(e,t.type,Os(t.defaultValue)),t.checked==null&&t.defaultChecked!=null&&(e.defaultChecked=!!t.defaultChecked)}function zv(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 Mh(e,t,n){(t!=="number"||pu(e.ownerDocument)!==e)&&(n==null?e.defaultValue=""+e._wrapperState.initialValue:e.defaultValue!==""+n&&(e.defaultValue=""+n))}var za=Array.isArray;function mi(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=""+Os(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 Lh(e,t){if(t.dangerouslySetInnerHTML!=null)throw Error($(91));return Ve({},t,{value:void 0,defaultValue:void 0,children:""+e._wrapperState.initialValue})}function Wv(e,t){var n=t.value;if(n==null){if(n=t.children,t=t.defaultValue,n!=null){if(t!=null)throw Error($(92));if(za(n)){if(1<n.length)throw Error($(93));n=n[0]}t=n}t==null&&(t=""),n=t}e._wrapperState={initialValue:Os(n)}}function Ob(e,t){var n=Os(t.value),r=Os(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 Hv(e){var t=e.textContent;t===e._wrapperState.initialValue&&t!==""&&t!==null&&(e.value=t)}function jb(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 $h(e,t){return e==null||e==="http://www.w3.org/1999/xhtml"?jb(t):e==="http://www.w3.org/2000/svg"&&t==="foreignObject"?"http://www.w3.org/1999/xhtml":e}var fc,Ib=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(fc=fc||document.createElement("div"),fc.innerHTML="<svg>"+t.valueOf().toString()+"</svg>",t=fc.firstChild;e.firstChild;)e.removeChild(e.firstChild);for(;t.firstChild;)e.appendChild(t.firstChild)}});function ll(e,t){if(t){var n=e.firstChild;if(n&&n===e.lastChild&&n.nodeType===3){n.nodeValue=t;return}}e.textContent=t}var Ya={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},DT=["Webkit","ms","Moz","O"];Object.keys(Ya).forEach(function(e){DT.forEach(function(t){t=t+e.charAt(0).toUpperCase()+e.substring(1),Ya[t]=Ya[e]})});function Db(e,t,n){return t==null||typeof t=="boolean"||t===""?"":n||typeof t!="number"||t===0||Ya.hasOwnProperty(e)&&Ya[e]?(""+t).trim():t+"px"}function Mb(e,t){e=e.style;for(var n in t)if(t.hasOwnProperty(n)){var r=n.indexOf("--")===0,s=Db(n,t[n],r);n==="float"&&(n="cssFloat"),r?e.setProperty(n,s):e[n]=s}}var MT=Ve({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 Fh(e,t){if(t){if(MT[e]&&(t.children!=null||t.dangerouslySetInnerHTML!=null))throw Error($(137,e));if(t.dangerouslySetInnerHTML!=null){if(t.children!=null)throw Error($(60));if(typeof t.dangerouslySetInnerHTML!="object"||!("__html"in t.dangerouslySetInnerHTML))throw Error($(61))}if(t.style!=null&&typeof t.style!="object")throw Error($(62))}}function Uh(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 Bh=null;function Mm(e){return e=e.target||e.srcElement||window,e.correspondingUseElement&&(e=e.correspondingUseElement),e.nodeType===3?e.parentNode:e}var zh=null,gi=null,vi=null;function Vv(e){if(e=Gl(e)){if(typeof zh!="function")throw Error($(280));var t=e.stateNode;t&&(t=pd(t),zh(e.stateNode,e.type,t))}}function Lb(e){gi?vi?vi.push(e):vi=[e]:gi=e}function $b(){if(gi){var e=gi,t=vi;if(vi=gi=null,Vv(e),t)for(e=0;e<t.length;e++)Vv(t[e])}}function Fb(e,t){return e(t)}function Ub(){}var gf=!1;function Bb(e,t,n){if(gf)return e(t,n);gf=!0;try{return Fb(e,t,n)}finally{gf=!1,(gi!==null||vi!==null)&&(Ub(),$b())}}function cl(e,t){var n=e.stateNode;if(n===null)return null;var r=pd(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($(231,t,typeof n));return n}var Wh=!1;if(Br)try{var wa={};Object.defineProperty(wa,"passive",{get:function(){Wh=!0}}),window.addEventListener("test",wa,wa),window.removeEventListener("test",wa,wa)}catch{Wh=!1}function LT(e,t,n,r,s,o,i,a,l){var c=Array.prototype.slice.call(arguments,3);try{t.apply(n,c)}catch(u){this.onError(u)}}var Za=!1,mu=null,gu=!1,Hh=null,$T={onError:function(e){Za=!0,mu=e}};function FT(e,t,n,r,s,o,i,a,l){Za=!1,mu=null,LT.apply($T,arguments)}function UT(e,t,n,r,s,o,i,a,l){if(FT.apply(this,arguments),Za){if(Za){var c=mu;Za=!1,mu=null}else throw Error($(198));gu||(gu=!0,Hh=c)}}function jo(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 zb(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 qv(e){if(jo(e)!==e)throw Error($(188))}function BT(e){var t=e.alternate;if(!t){if(t=jo(e),t===null)throw Error($(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 qv(s),e;if(o===r)return qv(s),t;o=o.sibling}throw Error($(188))}if(n.return!==r.return)n=s,r=o;else{for(var i=!1,a=s.child;a;){if(a===n){i=!0,n=s,r=o;break}if(a===r){i=!0,r=s,n=o;break}a=a.sibling}if(!i){for(a=o.child;a;){if(a===n){i=!0,n=o,r=s;break}if(a===r){i=!0,r=o,n=s;break}a=a.sibling}if(!i)throw Error($(189))}}if(n.alternate!==r)throw Error($(190))}if(n.tag!==3)throw Error($(188));return n.stateNode.current===n?e:t}function Wb(e){return e=BT(e),e!==null?Hb(e):null}function Hb(e){if(e.tag===5||e.tag===6)return e;for(e=e.child;e!==null;){var t=Hb(e);if(t!==null)return t;e=e.sibling}return null}var Vb=on.unstable_scheduleCallback,Kv=on.unstable_cancelCallback,zT=on.unstable_shouldYield,WT=on.unstable_requestPaint,Ze=on.unstable_now,HT=on.unstable_getCurrentPriorityLevel,Lm=on.unstable_ImmediatePriority,qb=on.unstable_UserBlockingPriority,vu=on.unstable_NormalPriority,VT=on.unstable_LowPriority,Kb=on.unstable_IdlePriority,ud=null,mr=null;function qT(e){if(mr&&typeof mr.onCommitFiberRoot=="function")try{mr.onCommitFiberRoot(ud,e,void 0,(e.current.flags&128)===128)}catch{}}var Vn=Math.clz32?Math.clz32:YT,KT=Math.log,GT=Math.LN2;function YT(e){return e>>>=0,e===0?32:31-(KT(e)/GT|0)|0}var hc=64,pc=4194304;function Wa(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 yu(e,t){var n=e.pendingLanes;if(n===0)return 0;var r=0,s=e.suspendedLanes,o=e.pingedLanes,i=n&268435455;if(i!==0){var a=i&~s;a!==0?r=Wa(a):(o&=i,o!==0&&(r=Wa(o)))}else i=n&~s,i!==0?r=Wa(i):o!==0&&(r=Wa(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-Vn(t),s=1<<n,r|=e[n],t&=~s;return r}function ZT(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 QT(e,t){for(var n=e.suspendedLanes,r=e.pingedLanes,s=e.expirationTimes,o=e.pendingLanes;0<o;){var i=31-Vn(o),a=1<<i,l=s[i];l===-1?(!(a&n)||a&r)&&(s[i]=ZT(a,t)):l<=t&&(e.expiredLanes|=a),o&=~a}}function Vh(e){return e=e.pendingLanes&-1073741825,e!==0?e:e&1073741824?1073741824:0}function Gb(){var e=hc;return hc<<=1,!(hc&4194240)&&(hc=64),e}function vf(e){for(var t=[],n=0;31>n;n++)t.push(e);return t}function ql(e,t,n){e.pendingLanes|=t,t!==536870912&&(e.suspendedLanes=0,e.pingedLanes=0),e=e.eventTimes,t=31-Vn(t),e[t]=n}function JT(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-Vn(n),o=1<<s;t[s]=0,r[s]=-1,e[s]=-1,n&=~o}}function $m(e,t){var n=e.entangledLanes|=t;for(e=e.entanglements;n;){var r=31-Vn(n),s=1<<r;s&t|e[r]&t&&(e[r]|=t),n&=~s}}var Ae=0;function Yb(e){return e&=-e,1<e?4<e?e&268435455?16:536870912:4:1}var Zb,Fm,Qb,Jb,Xb,qh=!1,mc=[],xs=null,_s=null,Ss=null,ul=new Map,dl=new Map,cs=[],XT="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 Gv(e,t){switch(e){case"focusin":case"focusout":xs=null;break;case"dragenter":case"dragleave":_s=null;break;case"mouseover":case"mouseout":Ss=null;break;case"pointerover":case"pointerout":ul.delete(t.pointerId);break;case"gotpointercapture":case"lostpointercapture":dl.delete(t.pointerId)}}function ba(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=Gl(t),t!==null&&Fm(t)),e):(e.eventSystemFlags|=r,t=e.targetContainers,s!==null&&t.indexOf(s)===-1&&t.push(s),e)}function eR(e,t,n,r,s){switch(t){case"focusin":return xs=ba(xs,e,t,n,r,s),!0;
vendor: 10,354 bytes, line 38
38case"dragenter":return _s=ba(_s,e,t,n,r,s),!0;case"mouseover":return Ss=ba(Ss,e,t,n,r,s),!0;case"pointerover":var o=s.pointerId;return ul.set(o,ba(ul.get(o)||null,e,t,n,r,s)),!0;case"gotpointercapture":return o=s.pointerId,dl.set(o,ba(dl.get(o)||null,e,t,n,r,s)),!0}return!1}function ex(e){var t=ao(e.target);if(t!==null){var n=jo(t);if(n!==null){if(t=n.tag,t===13){if(t=zb(n),t!==null){e.blockedOn=t,Xb(e.priority,function(){Qb(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 Kc(e){if(e.blockedOn!==null)return!1;for(var t=e.targetContainers;0<t.length;){var n=Kh(e.domEventName,e.eventSystemFlags,t[0],e.nativeEvent);if(n===null){n=e.nativeEvent;var r=new n.constructor(n.type,n);Bh=r,n.target.dispatchEvent(r),Bh=null}else return t=Gl(n),t!==null&&Fm(t),e.blockedOn=n,!1;t.shift()}return!0}function Yv(e,t,n){Kc(e)&&n.delete(t)}function tR(){qh=!1,xs!==null&&Kc(xs)&&(xs=null),_s!==null&&Kc(_s)&&(_s=null),Ss!==null&&Kc(Ss)&&(Ss=null),ul.forEach(Yv),dl.forEach(Yv)}function xa(e,t){e.blockedOn===t&&(e.blockedOn=null,qh||(qh=!0,on.unstable_scheduleCallback(on.unstable_NormalPriority,tR)))}function fl(e){function t(s){return xa(s,e)}if(0<mc.length){xa(mc[0],e);for(var n=1;n<mc.length;n++){var r=mc[n];r.blockedOn===e&&(r.blockedOn=null)}}for(xs!==null&&xa(xs,e),_s!==null&&xa(_s,e),Ss!==null&&xa(Ss,e),ul.forEach(t),dl.forEach(t),n=0;n<cs.length;n++)r=cs[n],r.blockedOn===e&&(r.blockedOn=null);for(;0<cs.length&&(n=cs[0],n.blockedOn===null);)ex(n),n.blockedOn===null&&cs.shift()}var yi=Gr.ReactCurrentBatchConfig,wu=!0;function nR(e,t,n,r){var s=Ae,o=yi.transition;yi.transition=null;try{Ae=1,Um(e,t,n,r)}finally{Ae=s,yi.transition=o}}function rR(e,t,n,r){var s=Ae,o=yi.transition;yi.transition=null;try{Ae=4,Um(e,t,n,r)}finally{Ae=s,yi.transition=o}}function Um(e,t,n,r){if(wu){var s=Kh(e,t,n,r);if(s===null)Tf(e,t,r,bu,n),Gv(e,r);else if(eR(s,e,t,n,r))r.stopPropagation();else if(Gv(e,r),t&4&&-1<XT.indexOf(e)){for(;s!==null;){var o=Gl(s);if(o!==null&&Zb(o),o=Kh(e,t,n,r),o===null&&Tf(e,t,r,bu,n),o===s)break;s=o}s!==null&&r.stopPropagation()}else Tf(e,t,r,null,n)}}var bu=null;function Kh(e,t,n,r){if(bu=null,e=Mm(r),e=ao(e),e!==null)if(t=jo(e),t===null)e=null;else if(n=t.tag,n===13){if(e=zb(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 bu=e,null}function tx(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(HT()){case Lm:return 1;case qb:return 4;case vu:case VT:return 16;case Kb:return 536870912;default:return 16}default:return 16}}var vs=null,Bm=null,Gc=null;function nx(){if(Gc)return Gc;var e,t=Bm,n=t.length,r,s="value"in vs?vs.value:vs.textContent,o=s.length;for(e=0;e<n&&t[e]===s[e];e++);var i=n-e;for(r=1;r<=i&&t[n-r]===s[o-r];r++);return Gc=s.slice(e,1<r?1-r:void 0)}function Yc(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 gc(){return!0}function Zv(){return!1}function un(e){function t(n,r,s,o,i){this._reactName=n,this._targetInst=s,this.type=r,this.nativeEvent=o,this.target=i,this.currentTarget=null;for(var a in e)e.hasOwnProperty(a)&&(n=e[a],this[a]=n?n(o):o[a]);return this.isDefaultPrevented=(o.defaultPrevented!=null?o.defaultPrevented:o.returnValue===!1)?gc:Zv,this.isPropagationStopped=Zv,this}return Ve(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=gc)},stopPropagation:function(){var n=this.nativeEvent;n&&(n.stopPropagation?n.stopPropagation():typeof n.cancelBubble!="unknown"&&(n.cancelBubble=!0),this.isPropagationStopped=gc)},persist:function(){},isPersistent:gc}),t}var Ji={eventPhase:0,bubbles:0,cancelable:0,timeStamp:function(e){return e.timeStamp||Date.now()},defaultPrevented:0,isTrusted:0},zm=un(Ji),Kl=Ve({},Ji,{view:0,detail:0}),sR=un(Kl),yf,wf,_a,dd=Ve({},Kl,{screenX:0,screenY:0,clientX:0,clientY:0,pageX:0,pageY:0,ctrlKey:0,shiftKey:0,altKey:0,metaKey:0,getModifierState:Wm,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!==_a&&(_a&&e.type==="mousemove"?(yf=e.screenX-_a.screenX,wf=e.screenY-_a.screenY):wf=yf=0,_a=e),yf)},movementY:function(e){return"movementY"in e?e.movementY:wf}}),Qv=un(dd),oR=Ve({},dd,{dataTransfer:0}),iR=un(oR),aR=Ve({},Kl,{relatedTarget:0}),bf=un(aR),lR=Ve({},Ji,{animationName:0,elapsedTime:0,pseudoElement:0}),cR=un(lR),uR=Ve({},Ji,{clipboardData:function(e){return"clipboardData"in e?e.clipboardData:window.clipboardData}}),dR=un(uR),fR=Ve({},Ji,{data:0}),Jv=un(fR),hR={Esc:"Escape",Spacebar:" ",Left:"ArrowLeft",Up:"ArrowUp",Right:"ArrowRight",Down:"ArrowDown",Del:"Delete",Win:"OS",Menu:"ContextMenu",Apps:"ContextMenu",Scroll:"ScrollLock",MozPrintableKey:"Unidentified"},pR={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"},mR={Alt:"altKey",Control:"ctrlKey",Meta:"metaKey",Shift:"shiftKey"};function gR(e){var t=this.nativeEvent;return t.getModifierState?t.getModifierState(e):(e=mR[e])?!!t[e]:!1}function Wm(){return gR}var vR=Ve({},Kl,{key:function(e){if(e.key){var t=hR[e.key]||e.key;if(t!=="Unidentified")return t}return e.type==="keypress"?(e=Yc(e),e===13?"Enter":String.fromCharCode(e)):e.type==="keydown"||e.type==="keyup"?pR[e.keyCode]||"Unidentified":""},code:0,location:0,ctrlKey:0,shiftKey:0,altKey:0,metaKey:0,repeat:0,locale:0,getModifierState:Wm,charCode:function(e){return e.type==="keypress"?Yc(e):0},keyCode:function(e){return e.type==="keydown"||e.type==="keyup"?e.keyCode:0},which:function(e){return e.type==="keypress"?Yc(e):e.type==="keydown"||e.type==="keyup"?e.keyCode:0}}),yR=un(vR),wR=Ve({},dd,{pointerId:0,width:0,height:0,pressure:0,tangentialPressure:0,tiltX:0,tiltY:0,twist:0,pointerType:0,isPrimary:0}),Xv=un(wR),bR=Ve({},Kl,{touches:0,targetTouches:0,changedTouches:0,altKey:0,metaKey:0,ctrlKey:0,shiftKey:0,getModifierState:Wm}),xR=un(bR),_R=Ve({},Ji,{propertyName:0,elapsedTime:0,pseudoElement:0}),SR=un(_R),ER=Ve({},dd,{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}),kR=un(ER),CR=[9,13,27,32],Hm=Br&&"CompositionEvent"in window,Qa=null;Br&&"documentMode"in document&&(Qa=document.documentMode);var TR=Br&&"TextEvent"in window&&!Qa,rx=Br&&(!Hm||Qa&&8<Qa&&11>=Qa),ey=" ",ty=!1;function sx(e,t){switch(e){case"keyup":return CR.indexOf(t.keyCode)!==-1;case"keydown":return t.keyCode!==229;case"keypress":case"mousedown":case"focusout":return!0;default:return!1}}function ox(e){return e=e.detail,typeof e=="object"&&"data"in e?e.data:null}var si=!1;function RR(e,t){switch(e){case"compositionend":return ox(t);case"keypress":return t.which!==32?null:(ty=!0,ey);case"textInput":return e=t.data,e===ey&&ty?null:e;default:return null}}function PR(e,t){if(si)return e==="compositionend"||!Hm&&sx(e,t)?(e=nx(),Gc=Bm=vs=null,si=!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 rx&&t.locale!=="ko"?null:t.data;default:return null}}var NR={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 ny(e){var t=e&&e.nodeName&&e.nodeName.toLowerCase();return t==="input"?!!NR[e.type]:t==="textarea"}function ix(e,t,n,r){Lb(r),t=xu(t,"onChange"),0<t.length&&(n=new zm("onChange","change",null,n,r),e.push({event:n,listeners:t}))}var Ja=null,hl=null;function AR(e){vx(e,0)}function fd(e){var t=ai(e);if(Nb(t))return e}function OR(e,t){if(e==="change")return t}var ax=!1;if(Br){var xf;if(Br){var _f="oninput"in document;if(!_f){var ry=document.createElement("div");ry.setAttribute("oninput","return;"),_f=typeof ry.oninput=="function"}xf=_f}else xf=!1;ax=xf&&(!document.documentMode||9<document.documentMode)}function sy(){Ja&&(Ja.detachEvent("onpropertychange",lx),hl=Ja=null)}function lx(e){if(e.propertyName==="value"&&fd(hl)){var t=[];ix(t,hl,e,Mm(e)),Bb(AR,t)}}function jR(e,t,n){e==="focusin"?(sy(),Ja=t,hl=n,Ja.attachEvent("onpropertychange",lx)):e==="focusout"&&sy()}function IR(e){if(e==="selectionchange"||e==="keyup"||e==="keydown")return fd(hl)}function DR(e,t){if(e==="click")return fd(t)}function MR(e,t){if(e==="input"||e==="change")return fd(t)}function LR(e,t){return e===t&&(e!==0||1/e===1/t)||e!==e&&t!==t}var Kn=typeof Object.is=="function"?Object.is:LR;function pl(e,t){if(Kn(e,t))return!0;
vendor: 4,808 bytes, line 38
38if(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(!Ph.call(t,s)||!Kn(e[s],t[s]))return!1}return!0}function oy(e){for(;e&&e.firstChild;)e=e.firstChild;return e}function iy(e,t){var n=oy(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=oy(n)}}function cx(e,t){return e&&t?e===t?!0:e&&e.nodeType===3?!1:t&&t.nodeType===3?cx(e,t.parentNode):"contains"in e?e.contains(t):e.compareDocumentPosition?!!(e.compareDocumentPosition(t)&16):!1:!1}function ux(){for(var e=window,t=pu();t instanceof e.HTMLIFrameElement;){try{var n=typeof t.contentWindow.location.href=="string"}catch{n=!1}if(n)e=t.contentWindow;else break;t=pu(e.document)}return t}function Vm(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 $R(e){var t=ux(),n=e.focusedElem,r=e.selectionRange;if(t!==n&&n&&n.ownerDocument&&cx(n.ownerDocument.documentElement,n)){if(r!==null&&Vm(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=iy(n,o);var i=iy(n,r);s&&i&&(e.rangeCount!==1||e.anchorNode!==s.node||e.anchorOffset!==s.offset||e.focusNode!==i.node||e.focusOffset!==i.offset)&&(t=t.createRange(),t.setStart(s.node,s.offset),e.removeAllRanges(),o>r?(e.addRange(t),e.extend(i.node,i.offset)):(t.setEnd(i.node,i.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 FR=Br&&"documentMode"in document&&11>=document.documentMode,oi=null,Gh=null,Xa=null,Yh=!1;function ay(e,t,n){var r=n.window===n?n.document:n.nodeType===9?n:n.ownerDocument;Yh||oi==null||oi!==pu(r)||(r=oi,"selectionStart"in r&&Vm(r)?r={start:r.selectionStart,end:r.selectionEnd}:(r=(r.ownerDocument&&r.ownerDocument.defaultView||window).getSelection(),r={anchorNode:r.anchorNode,anchorOffset:r.anchorOffset,focusNode:r.focusNode,focusOffset:r.focusOffset}),Xa&&pl(Xa,r)||(Xa=r,r=xu(Gh,"onSelect"),0<r.length&&(t=new zm("onSelect","select",null,t,n),e.push({event:t,listeners:r}),t.target=oi)))}function vc(e,t){var n={};return n[e.toLowerCase()]=t.toLowerCase(),n["Webkit"+e]="webkit"+t,n["Moz"+e]="moz"+t,n}var ii={animationend:vc("Animation","AnimationEnd"),animationiteration:vc("Animation","AnimationIteration"),animationstart:vc("Animation","AnimationStart"),transitionend:vc("Transition","TransitionEnd")},Sf={},dx={};Br&&(dx=document.createElement("div").style,"AnimationEvent"in window||(delete ii.animationend.animation,delete ii.animationiteration.animation,delete ii.animationstart.animation),"TransitionEvent"in window||delete ii.transitionend.transition);function hd(e){if(Sf[e])return Sf[e];if(!ii[e])return e;var t=ii[e],n;for(n in t)if(t.hasOwnProperty(n)&&n in dx)return Sf[e]=t[n];return e}var fx=hd("animationend"),hx=hd("animationiteration"),px=hd("animationstart"),mx=hd("transitionend"),gx=new Map,ly="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 Fs(e,t){gx.set(e,t),Oo(t,[e])}for(var Ef=0;Ef<ly.length;Ef++){var kf=ly[Ef],UR=kf.toLowerCase(),BR=kf[0].toUpperCase()+kf.slice(1);Fs(UR,"on"+BR)}Fs(fx,"onAnimationEnd");Fs(hx,"onAnimationIteration");Fs(px,"onAnimationStart");Fs("dblclick","onDoubleClick");Fs("focusin","onFocus");Fs("focusout","onBlur");Fs(mx,"onTransitionEnd");Di("onMouseEnter",["mouseout","mouseover"]);Di("onMouseLeave",["mouseout","mouseover"]);Di("onPointerEnter",["pointerout","pointerover"]);Di("onPointerLeave",["pointerout","pointerover"]);Oo("onChange","change click focusin focusout input keydown keyup selectionchange".split(" "));
vendor: 4,770 bytes, line 38
38Oo("onSelect","focusout contextmenu dragend focusin keydown keyup mousedown mouseup selectionchange".split(" "));Oo("onBeforeInput",["compositionend","keypress","textInput","paste"]);Oo("onCompositionEnd","compositionend focusout keydown keypress keyup mousedown".split(" "));Oo("onCompositionStart","compositionstart focusout keydown keypress keyup mousedown".split(" "));Oo("onCompositionUpdate","compositionupdate focusout keydown keypress keyup mousedown".split(" "));var Ha="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(" "),zR=new Set("cancel close invalid load scroll toggle".split(" ").concat(Ha));function cy(e,t,n){var r=e.type||"unknown-event";e.currentTarget=n,UT(r,t,void 0,e),e.currentTarget=null}function vx(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 i=r.length-1;0<=i;i--){var a=r[i],l=a.instance,c=a.currentTarget;if(a=a.listener,l!==o&&s.isPropagationStopped())break e;cy(s,a,c),o=l}else for(i=0;i<r.length;i++){if(a=r[i],l=a.instance,c=a.currentTarget,a=a.listener,l!==o&&s.isPropagationStopped())break e;cy(s,a,c),o=l}}}if(gu)throw e=Hh,gu=!1,Hh=null,e}function $e(e,t){var n=t[ep];n===void 0&&(n=t[ep]=new Set);var r=e+"__bubble";n.has(r)||(yx(t,e,2,!1),n.add(r))}function Cf(e,t,n){var r=0;t&&(r|=4),yx(n,e,r,t)}var yc="_reactListening"+Math.random().toString(36).slice(2);function ml(e){if(!e[yc]){e[yc]=!0,kb.forEach(function(n){n!=="selectionchange"&&(zR.has(n)||Cf(n,!1,e),Cf(n,!0,e))});var t=e.nodeType===9?e:e.ownerDocument;t===null||t[yc]||(t[yc]=!0,Cf("selectionchange",!1,t))}}function yx(e,t,n,r){switch(tx(t)){case 1:var s=nR;break;case 4:s=rR;break;default:s=Um}n=s.bind(null,t,n,e),s=void 0,!Wh||t!=="touchstart"&&t!=="touchmove"&&t!=="wheel"||(s=!0),r?s!==void 0?e.addEventListener(t,n,{capture:!0,passive:s}):e.addEventListener(t,n,!0):s!==void 0?e.addEventListener(t,n,{passive:s}):e.addEventListener(t,n,!1)}function Tf(e,t,n,r,s){var o=r;if(!(t&1)&&!(t&2)&&r!==null)e:for(;;){if(r===null)return;var i=r.tag;if(i===3||i===4){var a=r.stateNode.containerInfo;if(a===s||a.nodeType===8&&a.parentNode===s)break;if(i===4)for(i=r.return;i!==null;){var l=i.tag;if((l===3||l===4)&&(l=i.stateNode.containerInfo,l===s||l.nodeType===8&&l.parentNode===s))return;i=i.return}for(;a!==null;){if(i=ao(a),i===null)return;if(l=i.tag,l===5||l===6){r=o=i;continue e}a=a.parentNode}}r=r.return}Bb(function(){var c=o,u=Mm(n),d=[];e:{var p=gx.get(e);if(p!==void 0){var h=zm,x=e;switch(e){case"keypress":if(Yc(n)===0)break e;case"keydown":case"keyup":h=yR;break;case"focusin":x="focus",h=bf;break;case"focusout":x="blur",h=bf;break;case"beforeblur":case"afterblur":h=bf;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":h=Qv;break;case"drag":case"dragend":case"dragenter":case"dragexit":case"dragleave":case"dragover":case"dragstart":case"drop":h=iR;break;case"touchcancel":case"touchend":case"touchmove":case"touchstart":h=xR;break;case fx:case hx:case px:h=cR;break;case mx:h=SR;break;case"scroll":h=sR;break;case"wheel":h=kR;break;case"copy":case"cut":case"paste":h=dR;break;case"gotpointercapture":case"lostpointercapture":case"pointercancel":case"pointerdown":case"pointermove":case"pointerout":case"pointerover":case"pointerup":h=Xv}var v=(t&4)!==0,b=!v&&e==="scroll",w=v?p!==null?p+"Capture":null:p;v=[];for(var g=c,y;g!==null;){y=g;var _=y.stateNode;if(y.tag===5&&_!==null&&(y=_,w!==null&&(_=cl(g,w),_!=null&&v.push(gl(g,_,y)))),b)break;g=g.return}0<v.length&&(p=new h(p,x,null,n,u),d.push({event:p,listeners:v}))}}if(!(t&7)){e:{if(p=e==="mouseover"||e==="pointerover",h=e==="mouseout"||e==="pointerout",p&&n!==Bh&&(x=n.relatedTarget||n.fromElement)&&(ao(x)||x[zr]))break e;if((h||p)&&(p=u.window===u?u:(p=u.ownerDocument)?p.defaultView||p.parentWindow:window,h?(x=n.relatedTarget||n.toElement,h=c,x=x?ao(x):null,x!==null&&(b=jo(x),x!==b||x.tag!==5&&x.tag!==6)&&(x=null)):(h=null,x=c),h!==x)){if(v=Qv,_="onMouseLeave",w="onMouseEnter",g="mouse",(e==="pointerout"||e==="pointerover")&&(v=Xv,_="onPointerLeave",w="onPointerEnter",g="pointer"),b=h==null?p:ai(h),y=x==null?p:ai(x),p=new v(_,g+"leave",h,n,u),p.target=b,p.relatedTarget=y,_=null,ao(u)===c&&(v=new v(w,g+"enter",x,n,u),v.target=y,v.relatedTarget=b,_=v),b=_,h&&x)t:{for(v=h,w=x,g=0,y=v;y;y=Fo(y))g++;for(y=0,_=w;_;_=Fo(_))y++;for(;0<g-y;)v=Fo(v),g--;for(;0<y-g;)w=Fo(w),y--;for(;g--;){if(v===w||w!==null&&v===w.alternate)break t;v=Fo(v),w=Fo(w)}v=null}else v=null;h!==null&&uy(d,p,h,v,!1),x!==null&&b!==null&&uy(d,b,x,v,!0)}}
vendor: 4,435 bytes, lines 38-39
38e:{if(p=c?ai(c):window,h=p.nodeName&&p.nodeName.toLowerCase(),h==="select"||h==="input"&&p.type==="file")var S=OR;else if(ny(p))if(ax)S=MR;else{S=IR;var k=jR}else(h=p.nodeName)&&h.toLowerCase()==="input"&&(p.type==="checkbox"||p.type==="radio")&&(S=DR);if(S&&(S=S(e,c))){ix(d,S,n,u);break e}k&&k(e,p,c),e==="focusout"&&(k=p._wrapperState)&&k.controlled&&p.type==="number"&&Mh(p,"number",p.value)}switch(k=c?ai(c):window,e){case"focusin":(ny(k)||k.contentEditable==="true")&&(oi=k,Gh=c,Xa=null);break;case"focusout":Xa=Gh=oi=null;break;case"mousedown":Yh=!0;break;case"contextmenu":case"mouseup":case"dragend":Yh=!1,ay(d,n,u);break;case"selectionchange":if(FR)break;case"keydown":case"keyup":ay(d,n,u)}var E;if(Hm)e:{switch(e){case"compositionstart":var R="onCompositionStart";break e;case"compositionend":R="onCompositionEnd";break e;case"compositionupdate":R="onCompositionUpdate";break e}R=void 0}else si?sx(e,n)&&(R="onCompositionEnd"):e==="keydown"&&n.keyCode===229&&(R="onCompositionStart");R&&(rx&&n.locale!=="ko"&&(si||R!=="onCompositionStart"?R==="onCompositionEnd"&&si&&(E=nx()):(vs=u,Bm="value"in vs?vs.value:vs.textContent,si=!0)),k=xu(c,R),0<k.length&&(R=new Jv(R,e,null,n,u),d.push({event:R,listeners:k}),E?R.data=E:(E=ox(n),E!==null&&(R.data=E)))),(E=TR?RR(e,n):PR(e,n))&&(c=xu(c,"onBeforeInput"),0<c.length&&(u=new Jv("onBeforeInput","beforeinput",null,n,u),d.push({event:u,listeners:c}),u.data=E))}vx(d,t)})}function gl(e,t,n){return{instance:e,listener:t,currentTarget:n}}function xu(e,t){for(var n=t+"Capture",r=[];e!==null;){var s=e,o=s.stateNode;s.tag===5&&o!==null&&(s=o,o=cl(e,n),o!=null&&r.unshift(gl(e,o,s)),o=cl(e,t),o!=null&&r.push(gl(e,o,s))),e=e.return}return r}function Fo(e){if(e===null)return null;do e=e.return;while(e&&e.tag!==5);return e||null}function uy(e,t,n,r,s){for(var o=t._reactName,i=[];n!==null&&n!==r;){var a=n,l=a.alternate,c=a.stateNode;if(l!==null&&l===r)break;a.tag===5&&c!==null&&(a=c,s?(l=cl(n,o),l!=null&&i.unshift(gl(n,l,a))):s||(l=cl(n,o),l!=null&&i.push(gl(n,l,a)))),n=n.return}i.length!==0&&e.push({event:t,listeners:i})}var WR=/\r\n?/g,HR=/\u0000|\uFFFD/g;function dy(e){return(typeof e=="string"?e:""+e).replace(WR,` 39`).replace(HR,"")}function wc(e,t,n){if(t=dy(t),dy(e)!==t&&n)throw Error($(425))}function _u(){}var Zh=null,Qh=null;function Jh(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 Xh=typeof setTimeout=="function"?setTimeout:void 0,VR=typeof clearTimeout=="function"?clearTimeout:void 0,fy=typeof Promise=="function"?Promise:void 0,qR=typeof queueMicrotask=="function"?queueMicrotask:typeof fy<"u"?function(e){return fy.resolve(null).then(e).catch(KR)}:Xh;function KR(e){setTimeout(function(){throw e})}function Rf(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),fl(t);return}r--}else n!=="$"&&n!=="$?"&&n!=="$!"||r++;n=s}while(n);fl(t)}function Es(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 hy(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 Xi=Math.random().toString(36).slice(2),ur="__reactFiber$"+Xi,vl="__reactProps$"+Xi,zr="__reactContainer$"+Xi,ep="__reactEvents$"+Xi,GR="__reactListeners$"+Xi,YR="__reactHandles$"+Xi;function ao(e){var t=e[ur];if(t)return t;for(var n=e.parentNode;n;){if(t=n[zr]||n[ur]){if(n=t.alternate,t.child!==null||n!==null&&n.child!==null)for(e=hy(e);e!==null;){if(n=e[ur])return n;e=hy(e)}return t}e=n,n=e.parentNode}return null}function Gl(e){return e=e[ur]||e[zr],!e||e.tag!==5&&e.tag!==6&&e.tag!==13&&e.tag!==3?null:e}function ai(e){if(e.tag===5||e.tag===6)return e.stateNode;throw Error($(33))}function pd(e){return e[vl]||null}var tp=[],li=-1;function Us(e){return{current:e}}function Fe(e){0>li||(e.current=tp[li],tp[li]=null,li--)}function Ie(e,t){li++,tp[li]=e.current,e.current=t}var js={},Et=Us(js),Ht=Us(!1),xo=js;function Mi(e,t){var n=e.type.contextTypes;if(!n)return js;var r=e.stateNode;if(r&&r.__reactInternalMemoizedUnmaskedChildContext===t)return r.__reactInternalMemoizedMaskedChildContext;var s={},o;
vendor: 14,751 bytes, line 39
39for(o in n)s[o]=t[o];return r&&(e=e.stateNode,e.__reactInternalMemoizedUnmaskedChildContext=t,e.__reactInternalMemoizedMaskedChildContext=s),s}function Vt(e){return e=e.childContextTypes,e!=null}function Su(){Fe(Ht),Fe(Et)}function py(e,t,n){if(Et.current!==js)throw Error($(168));Ie(Et,t),Ie(Ht,n)}function wx(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($(108,jT(e)||"Unknown",s));return Ve({},n,r)}function Eu(e){return e=(e=e.stateNode)&&e.__reactInternalMemoizedMergedChildContext||js,xo=Et.current,Ie(Et,e),Ie(Ht,Ht.current),!0}function my(e,t,n){var r=e.stateNode;if(!r)throw Error($(169));n?(e=wx(e,t,xo),r.__reactInternalMemoizedMergedChildContext=e,Fe(Ht),Fe(Et),Ie(Et,e)):Fe(Ht),Ie(Ht,n)}var Dr=null,md=!1,Pf=!1;function bx(e){Dr===null?Dr=[e]:Dr.push(e)}function ZR(e){md=!0,bx(e)}function Bs(){if(!Pf&&Dr!==null){Pf=!0;var e=0,t=Ae;try{var n=Dr;for(Ae=1;e<n.length;e++){var r=n[e];do r=r(!0);while(r!==null)}Dr=null,md=!1}catch(s){throw Dr!==null&&(Dr=Dr.slice(e+1)),Vb(Lm,Bs),s}finally{Ae=t,Pf=!1}}return null}var ci=[],ui=0,ku=null,Cu=0,wn=[],bn=0,_o=null,Lr=1,$r="";function to(e,t){ci[ui++]=Cu,ci[ui++]=ku,ku=e,Cu=t}function xx(e,t,n){wn[bn++]=Lr,wn[bn++]=$r,wn[bn++]=_o,_o=e;var r=Lr;e=$r;var s=32-Vn(r)-1;r&=~(1<<s),n+=1;var o=32-Vn(t)+s;if(30<o){var i=s-s%5;o=(r&(1<<i)-1).toString(32),r>>=i,s-=i,Lr=1<<32-Vn(t)+s|n<<s|r,$r=o+e}else Lr=1<<o|n<<s|r,$r=e}function qm(e){e.return!==null&&(to(e,1),xx(e,1,0))}function Km(e){for(;e===ku;)ku=ci[--ui],ci[ui]=null,Cu=ci[--ui],ci[ui]=null;for(;e===_o;)_o=wn[--bn],wn[bn]=null,$r=wn[--bn],wn[bn]=null,Lr=wn[--bn],wn[bn]=null}var rn=null,nn=null,Be=!1,Wn=null;function _x(e,t){var n=xn(5,null,null,0);n.elementType="DELETED",n.stateNode=t,n.return=e,t=e.deletions,t===null?(e.deletions=[n],e.flags|=16):t.push(n)}function gy(e,t){switch(e.tag){case 5:var n=e.type;return t=t.nodeType!==1||n.toLowerCase()!==t.nodeName.toLowerCase()?null:t,t!==null?(e.stateNode=t,rn=e,nn=Es(t.firstChild),!0):!1;case 6:return t=e.pendingProps===""||t.nodeType!==3?null:t,t!==null?(e.stateNode=t,rn=e,nn=null,!0):!1;case 13:return t=t.nodeType!==8?null:t,t!==null?(n=_o!==null?{id:Lr,overflow:$r}:null,e.memoizedState={dehydrated:t,treeContext:n,retryLane:1073741824},n=xn(18,null,null,0),n.stateNode=t,n.return=e,e.child=n,rn=e,nn=null,!0):!1;default:return!1}}function np(e){return(e.mode&1)!==0&&(e.flags&128)===0}function rp(e){if(Be){var t=nn;if(t){var n=t;if(!gy(e,t)){if(np(e))throw Error($(418));t=Es(n.nextSibling);var r=rn;t&&gy(e,t)?_x(r,n):(e.flags=e.flags&-4097|2,Be=!1,rn=e)}}else{if(np(e))throw Error($(418));e.flags=e.flags&-4097|2,Be=!1,rn=e}}}function vy(e){for(e=e.return;e!==null&&e.tag!==5&&e.tag!==3&&e.tag!==13;)e=e.return;rn=e}function bc(e){if(e!==rn)return!1;if(!Be)return vy(e),Be=!0,!1;var t;if((t=e.tag!==3)&&!(t=e.tag!==5)&&(t=e.type,t=t!=="head"&&t!=="body"&&!Jh(e.type,e.memoizedProps)),t&&(t=nn)){if(np(e))throw Sx(),Error($(418));for(;t;)_x(e,t),t=Es(t.nextSibling)}if(vy(e),e.tag===13){if(e=e.memoizedState,e=e!==null?e.dehydrated:null,!e)throw Error($(317));e:{for(e=e.nextSibling,t=0;e;){if(e.nodeType===8){var n=e.data;if(n==="/$"){if(t===0){nn=Es(e.nextSibling);break e}t--}else n!=="$"&&n!=="$!"&&n!=="$?"||t++}e=e.nextSibling}nn=null}}else nn=rn?Es(e.stateNode.nextSibling):null;return!0}function Sx(){for(var e=nn;e;)e=Es(e.nextSibling)}function Li(){nn=rn=null,Be=!1}function Gm(e){Wn===null?Wn=[e]:Wn.push(e)}var QR=Gr.ReactCurrentBatchConfig;function Sa(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($(309));var r=n.stateNode}if(!r)throw Error($(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(i){var a=s.refs;i===null?delete a[o]:a[o]=i},t._stringRef=o,t)}if(typeof e!="string")throw Error($(284));if(!n._owner)throw Error($(290,e))}return e}function xc(e,t){throw e=Object.prototype.toString.call(t),Error($(31,e==="[object Object]"?"object with keys {"+Object.keys(t).join(", ")+"}":e))}function yy(e){var t=e._init;return t(e._payload)}function Ex(e){function t(w,g){if(e){var y=w.deletions;y===null?(w.deletions=[g],w.flags|=16):y.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=Rs(w,g),w.index=0,w.sibling=null,w}function o(w,g,y){return w.index=y,e?(y=w.alternate,y!==null?(y=y.index,y<g?(w.flags|=2,g):y):(w.flags|=2,g)):(w.flags|=1048576,g)}function i(w){return e&&w.alternate===null&&(w.flags|=2),w}function a(w,g,y,_){return g===null||g.tag!==6?(g=Mf(y,w.mode,_),g.return=w,g):(g=s(g,y),g.return=w,g)}function l(w,g,y,_){var S=y.type;return S===ri?u(w,g,y.props.children,_,y.key):g!==null&&(g.elementType===S||typeof S=="object"&&S!==null&&S.$$typeof===os&&yy(S)===g.type)?(_=s(g,y.props),_.ref=Sa(w,g,y),_.return=w,_):(_=nu(y.type,y.key,y.props,null,w.mode,_),_.ref=Sa(w,g,y),_.return=w,_)}function c(w,g,y,_){return g===null||g.tag!==4||g.stateNode.containerInfo!==y.containerInfo||g.stateNode.implementation!==y.implementation?(g=Lf(y,w.mode,_),g.return=w,g):(g=s(g,y.children||[]),g.return=w,g)}function u(w,g,y,_,S){return g===null||g.tag!==7?(g=bo(y,w.mode,_,S),g.return=w,g):(g=s(g,y),g.return=w,g)}function d(w,g,y){if(typeof g=="string"&&g!==""||typeof g=="number")return g=Mf(""+g,w.mode,y),g.return=w,g;if(typeof g=="object"&&g!==null){switch(g.$$typeof){case uc:return y=nu(g.type,g.key,g.props,null,w.mode,y),y.ref=Sa(w,null,g),y.return=w,y;case ni:return g=Lf(g,w.mode,y),g.return=w,g;case os:var _=g._init;return d(w,_(g._payload),y)}if(za(g)||ya(g))return g=bo(g,w.mode,y,null),g.return=w,g;xc(w,g)}return null}function p(w,g,y,_){var S=g!==null?g.key:null;if(typeof y=="string"&&y!==""||typeof y=="number")return S!==null?null:a(w,g,""+y,_);if(typeof y=="object"&&y!==null){switch(y.$$typeof){case uc:return y.key===S?l(w,g,y,_):null;case ni:return y.key===S?c(w,g,y,_):null;case os:return S=y._init,p(w,g,S(y._payload),_)}if(za(y)||ya(y))return S!==null?null:u(w,g,y,_,null);xc(w,y)}return null}function h(w,g,y,_,S){if(typeof _=="string"&&_!==""||typeof _=="number")return w=w.get(y)||null,a(g,w,""+_,S);if(typeof _=="object"&&_!==null){switch(_.$$typeof){case uc:return w=w.get(_.key===null?y:_.key)||null,l(g,w,_,S);case ni:return w=w.get(_.key===null?y:_.key)||null,c(g,w,_,S);case os:var k=_._init;return h(w,g,y,k(_._payload),S)}if(za(_)||ya(_))return w=w.get(y)||null,u(g,w,_,S,null);xc(g,_)}return null}function x(w,g,y,_){for(var S=null,k=null,E=g,R=g=0,P=null;E!==null&&R<y.length;R++){E.index>R?(P=E,E=null):P=E.sibling;var A=p(w,E,y[R],_);if(A===null){E===null&&(E=P);break}e&&E&&A.alternate===null&&t(w,E),g=o(A,g,R),k===null?S=A:k.sibling=A,k=A,E=P}if(R===y.length)return n(w,E),Be&&to(w,R),S;if(E===null){for(;R<y.length;R++)E=d(w,y[R],_),E!==null&&(g=o(E,g,R),k===null?S=E:k.sibling=E,k=E);return Be&&to(w,R),S}for(E=r(w,E);R<y.length;R++)P=h(E,w,R,y[R],_),P!==null&&(e&&P.alternate!==null&&E.delete(P.key===null?R:P.key),g=o(P,g,R),k===null?S=P:k.sibling=P,k=P);return e&&E.forEach(function(D){return t(w,D)}),Be&&to(w,R),S}function v(w,g,y,_){var S=ya(y);if(typeof S!="function")throw Error($(150));if(y=S.call(y),y==null)throw Error($(151));for(var k=S=null,E=g,R=g=0,P=null,A=y.next();E!==null&&!A.done;R++,A=y.next()){E.index>R?(P=E,E=null):P=E.sibling;var D=p(w,E,A.value,_);if(D===null){E===null&&(E=P);break}e&&E&&D.alternate===null&&t(w,E),g=o(D,g,R),k===null?S=D:k.sibling=D,k=D,E=P}if(A.done)return n(w,E),Be&&to(w,R),S;if(E===null){for(;!A.done;R++,A=y.next())A=d(w,A.value,_),A!==null&&(g=o(A,g,R),k===null?S=A:k.sibling=A,k=A);return Be&&to(w,R),S}for(E=r(w,E);!A.done;R++,A=y.next())A=h(E,w,R,A.value,_),A!==null&&(e&&A.alternate!==null&&E.delete(A.key===null?R:A.key),g=o(A,g,R),k===null?S=A:k.sibling=A,k=A);return e&&E.forEach(function(M){return t(w,M)}),Be&&to(w,R),S}function b(w,g,y,_){if(typeof y=="object"&&y!==null&&y.type===ri&&y.key===null&&(y=y.props.children),typeof y=="object"&&y!==null){switch(y.$$typeof){case uc:e:{for(var S=y.key,k=g;k!==null;){if(k.key===S){if(S=y.type,S===ri){if(k.tag===7){n(w,k.sibling),g=s(k,y.props.children),g.return=w,w=g;break e}}else if(k.elementType===S||typeof S=="object"&&S!==null&&S.$$typeof===os&&yy(S)===k.type){n(w,k.sibling),g=s(k,y.props),g.ref=Sa(w,k,y),g.return=w,w=g;break e}n(w,k);break}else t(w,k);k=k.sibling}y.type===ri?(g=bo(y.props.children,w.mode,_,y.key),g.return=w,w=g):(_=nu(y.type,y.key,y.props,null,w.mode,_),_.ref=Sa(w,g,y),_.return=w,w=_)}return i(w);case ni:e:{for(k=y.key;g!==null;){if(g.key===k)if(g.tag===4&&g.stateNode.containerInfo===y.containerInfo&&g.stateNode.implementation===y.implementation){n(w,g.sibling),g=s(g,y.children||[]),g.return=w,w=g;break e}else{n(w,g);break}else t(w,g);g=g.sibling}g=Lf(y,w.mode,_),g.return=w,w=g}return i(w);case os:return k=y._init,b(w,g,k(y._payload),_)}if(za(y))return x(w,g,y,_);if(ya(y))return v(w,g,y,_);xc(w,y)}return typeof y=="string"&&y!==""||typeof y=="number"?(y=""+y,g!==null&&g.tag===6?(n(w,g.sibling),g=s(g,y),g.return=w,w=g):(n(w,g),g=Mf(y,w.mode,_),g.return=w,w=g),i(w)):n(w,g)}return b}var $i=Ex(!0),kx=Ex(!1),Tu=Us(null),Ru=null,di=null,Ym=null;function Zm(){Ym=di=Ru=null}function Qm(e){var t=Tu.current;Fe(Tu),e._currentValue=t}function sp(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 wi(e,t){Ru=e,Ym=di=null,e=e.dependencies,e!==null&&e.firstContext!==null&&(e.lanes&t&&(zt=!0),e.firstContext=null)}function Sn(e){var t=e._currentValue;if(Ym!==e)if(e={context:e,memoizedValue:t,next:null},di===null){if(Ru===null)throw Error($(308));di=e,Ru.dependencies={lanes:0,firstContext:e}}else di=di.next=e;return t}var lo=null;function Jm(e){lo===null?lo=[e]:lo.push(e)}function Cx(e,t,n,r){var s=t.interleaved;return s===null?(n.next=n,Jm(t)):(n.next=s.next,s.next=n),t.interleaved=n,Wr(e,r)}function Wr(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 is=!1;function Xm(e){e.updateQueue={baseState:e.memoizedState,firstBaseUpdate:null,lastBaseUpdate:null,shared:{pending:null,interleaved:null,lanes:0},effects:null}}function Tx(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 Fr(e,t){return{eventTime:e,lane:t,tag:0,payload:null,callback:null,next:null}}function ks(e,t,n){var r=e.updateQueue;if(r===null)return null;if(r=r.shared,Ee&2){var s=r.pending;return s===null?t.next=t:(t.next=s.next,s.next=t),r.pending=t,Wr(e,n)}return s=r.interleaved,s===null?(t.next=t,Jm(r)):(t.next=s.next,s.next=t),r.interleaved=t,Wr(e,n)}function Zc(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,$m(e,n)}}function wy(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 i={eventTime:n.eventTime,lane:n.lane,tag:n.tag,payload:n.payload,callback:n.callback,next:null};o===null?s=o=i:o=o.next=i,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 Pu(e,t,n,r){var s=e.updateQueue;is=!1;var o=s.firstBaseUpdate,i=s.lastBaseUpdate,a=s.shared.pending;if(a!==null){s.shared.pending=null;var l=a,c=l.next;l.next=null,i===null?o=c:i.next=c,i=l;var u=e.alternate;u!==null&&(u=u.updateQueue,a=u.lastBaseUpdate,a!==i&&(a===null?u.firstBaseUpdate=c:a.next=c,u.lastBaseUpdate=l))}if(o!==null){var d=s.baseState;i=0,u=c=l=null,a=o;do{var p=a.lane,h=a.eventTime;if((r&p)===p){u!==null&&(u=u.next={eventTime:h,lane:0,tag:a.tag,payload:a.payload,callback:a.callback,next:null});e:{var x=e,v=a;switch(p=t,h=n,v.tag){case 1:if(x=v.payload,typeof x=="function"){d=x.call(h,d,p);break e}d=x;break e;case 3:x.flags=x.flags&-65537|128;case 0:if(x=v.payload,p=typeof x=="function"?x.call(h,d,p):x,p==null)break e;d=Ve({},d,p);break e;case 2:is=!0}}a.callback!==null&&a.lane!==0&&(e.flags|=64,p=s.effects,p===null?s.effects=[a]:p.push(a))}else h={eventTime:h,lane:p,tag:a.tag,payload:a.payload,callback:a.callback,next:null},u===null?(c=u=h,l=d):u=u.next=h,i|=p;if(a=a.next,a===null){if(a=s.shared.pending,a===null)break;p=a,a=p.next,p.next=null,s.lastBaseUpdate=p,s.shared.pending=null}}while(!0);if(u===null&&(l=d),s.baseState=l,s.firstBaseUpdate=c,s.lastBaseUpdate=u,t=s.shared.interleaved,t!==null){s=t;do i|=s.lane,s=s.next;while(s!==t)}else o===null&&(s.shared.lanes=0);Eo|=i,e.lanes=i,e.memoizedState=d}}function by(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($(191,s));s.call(r)}}}var Yl={},gr=Us(Yl),yl=Us(Yl),wl=Us(Yl);function co(e){if(e===Yl)throw Error($(174));return e}function eg(e,t){switch(Ie(wl,t),Ie(yl,e),Ie(gr,Yl),e=t.nodeType,e){case 9:case 11:t=(t=t.documentElement)?t.namespaceURI:$h(null,"");break;default:e=e===8?t.parentNode:t,t=e.namespaceURI||null,e=e.tagName,t=$h(t,e)}Fe(gr),Ie(gr,t)}function Fi(){Fe(gr),Fe(yl),Fe(wl)}function Rx(e){co(wl.current);var t=co(gr.current),n=$h(t,e.type);t!==n&&(Ie(yl,e),Ie(gr,n))}function tg(e){yl.current===e&&(Fe(gr),Fe(yl))}var We=Us(0);function Nu(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 Nf=[];function ng(){for(var e=0;e<Nf.length;e++)Nf[e]._workInProgressVersionPrimary=null;Nf.length=0}var Qc=Gr.ReactCurrentDispatcher,Af=Gr.ReactCurrentBatchConfig,So=0,He=null,rt=null,lt=null,Au=!1,el=!1,bl=0,JR=0;function bt(){throw Error($(321))}function rg(e,t){if(t===null)return!1;for(var n=0;n<t.length&&n<e.length;n++)if(!Kn(e[n],t[n]))return!1;return!0}function sg(e,t,n,r,s,o){if(So=o,He=t,t.memoizedState=null,t.updateQueue=null,t.lanes=0,Qc.current=e===null||e.memoizedState===null?nP:rP,e=n(r,s),el){o=0;
vendor: 6,245 bytes, line 39
39do{if(el=!1,bl=0,25<=o)throw Error($(301));o+=1,lt=rt=null,t.updateQueue=null,Qc.current=sP,e=n(r,s)}while(el)}if(Qc.current=Ou,t=rt!==null&&rt.next!==null,So=0,lt=rt=He=null,Au=!1,t)throw Error($(300));return e}function og(){var e=bl!==0;return bl=0,e}function ir(){var e={memoizedState:null,baseState:null,baseQueue:null,queue:null,next:null};return lt===null?He.memoizedState=lt=e:lt=lt.next=e,lt}function En(){if(rt===null){var e=He.alternate;e=e!==null?e.memoizedState:null}else e=rt.next;var t=lt===null?He.memoizedState:lt.next;if(t!==null)lt=t,rt=e;else{if(e===null)throw Error($(310));rt=e,e={memoizedState:rt.memoizedState,baseState:rt.baseState,baseQueue:rt.baseQueue,queue:rt.queue,next:null},lt===null?He.memoizedState=lt=e:lt=lt.next=e}return lt}function xl(e,t){return typeof t=="function"?t(e):t}function Of(e){var t=En(),n=t.queue;if(n===null)throw Error($(311));n.lastRenderedReducer=e;var r=rt,s=r.baseQueue,o=n.pending;if(o!==null){if(s!==null){var i=s.next;s.next=o.next,o.next=i}r.baseQueue=s=o,n.pending=null}if(s!==null){o=s.next,r=r.baseState;var a=i=null,l=null,c=o;do{var u=c.lane;if((So&u)===u)l!==null&&(l=l.next={lane:0,action:c.action,hasEagerState:c.hasEagerState,eagerState:c.eagerState,next:null}),r=c.hasEagerState?c.eagerState:e(r,c.action);else{var d={lane:u,action:c.action,hasEagerState:c.hasEagerState,eagerState:c.eagerState,next:null};l===null?(a=l=d,i=r):l=l.next=d,He.lanes|=u,Eo|=u}c=c.next}while(c!==null&&c!==o);l===null?i=r:l.next=a,Kn(r,t.memoizedState)||(zt=!0),t.memoizedState=r,t.baseState=i,t.baseQueue=l,n.lastRenderedState=r}if(e=n.interleaved,e!==null){s=e;do o=s.lane,He.lanes|=o,Eo|=o,s=s.next;while(s!==e)}else s===null&&(n.lanes=0);return[t.memoizedState,n.dispatch]}function jf(e){var t=En(),n=t.queue;if(n===null)throw Error($(311));n.lastRenderedReducer=e;var r=n.dispatch,s=n.pending,o=t.memoizedState;if(s!==null){n.pending=null;var i=s=s.next;do o=e(o,i.action),i=i.next;while(i!==s);Kn(o,t.memoizedState)||(zt=!0),t.memoizedState=o,t.baseQueue===null&&(t.baseState=o),n.lastRenderedState=o}return[o,r]}function Px(){}function Nx(e,t){var n=He,r=En(),s=t(),o=!Kn(r.memoizedState,s);if(o&&(r.memoizedState=s,zt=!0),r=r.queue,ig(jx.bind(null,n,r,e),[e]),r.getSnapshot!==t||o||lt!==null&<.memoizedState.tag&1){if(n.flags|=2048,_l(9,Ox.bind(null,n,r,s,t),void 0,null),ct===null)throw Error($(349));So&30||Ax(n,t,s)}return s}function Ax(e,t,n){e.flags|=16384,e={getSnapshot:t,value:n},t=He.updateQueue,t===null?(t={lastEffect:null,stores:null},He.updateQueue=t,t.stores=[e]):(n=t.stores,n===null?t.stores=[e]:n.push(e))}function Ox(e,t,n,r){t.value=n,t.getSnapshot=r,Ix(t)&&Dx(e)}function jx(e,t,n){return n(function(){Ix(t)&&Dx(e)})}function Ix(e){var t=e.getSnapshot;e=e.value;try{var n=t();return!Kn(e,n)}catch{return!0}}function Dx(e){var t=Wr(e,1);t!==null&&qn(t,e,1,-1)}function xy(e){var t=ir();return typeof e=="function"&&(e=e()),t.memoizedState=t.baseState=e,e={pending:null,interleaved:null,lanes:0,dispatch:null,lastRenderedReducer:xl,lastRenderedState:e},t.queue=e,e=e.dispatch=tP.bind(null,He,e),[t.memoizedState,e]}function _l(e,t,n,r){return e={tag:e,create:t,destroy:n,deps:r,next:null},t=He.updateQueue,t===null?(t={lastEffect:null,stores:null},He.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 Mx(){return En().memoizedState}function Jc(e,t,n,r){var s=ir();He.flags|=e,s.memoizedState=_l(1|t,n,void 0,r===void 0?null:r)}function gd(e,t,n,r){var s=En();r=r===void 0?null:r;var o=void 0;if(rt!==null){var i=rt.memoizedState;if(o=i.destroy,r!==null&&rg(r,i.deps)){s.memoizedState=_l(t,n,o,r);return}}He.flags|=e,s.memoizedState=_l(1|t,n,o,r)}function _y(e,t){return Jc(8390656,8,e,t)}function ig(e,t){return gd(2048,8,e,t)}function Lx(e,t){return gd(4,2,e,t)}function $x(e,t){return gd(4,4,e,t)}function Fx(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 Ux(e,t,n){return n=n!=null?n.concat([e]):null,gd(4,4,Fx.bind(null,t,e),n)}function ag(){}function Bx(e,t){var n=En();t=t===void 0?null:t;var r=n.memoizedState;return r!==null&&t!==null&&rg(t,r[1])?r[0]:(n.memoizedState=[e,t],e)}function zx(e,t){var n=En();t=t===void 0?null:t;var r=n.memoizedState;return r!==null&&t!==null&&rg(t,r[1])?r[0]:(e=e(),n.memoizedState=[e,t],e)}function Wx(e,t,n){return So&21?(Kn(n,t)||(n=Gb(),He.lanes|=n,Eo|=n,e.baseState=!0),t):(e.baseState&&(e.baseState=!1,zt=!0),e.memoizedState=n)}function XR(e,t){var n=Ae;Ae=n!==0&&4>n?n:4,e(!0);var r=Af.transition;Af.transition={};try{e(!1),t()}finally{Ae=n,Af.transition=r}}function Hx(){return En().memoizedState}function eP(e,t,n){var r=Ts(e);if(n={lane:r,action:n,hasEagerState:!1,eagerState:null,next:null},Vx(e))qx(t,n);else if(n=Cx(e,t,n,r),n!==null){var s=At();qn(n,e,r,s),Kx(n,t,r)}}function tP(e,t,n){var r=Ts(e),s={lane:r,action:n,hasEagerState:!1,eagerState:null,next:null};if(Vx(e))qx(t,s);else{var o=e.alternate;if(e.lanes===0&&(o===null||o.lanes===0)&&(o=t.lastRenderedReducer,o!==null))try{var i=t.lastRenderedState,a=o(i,n);if(s.hasEagerState=!0,s.eagerState=a,Kn(a,i)){var l=t.interleaved;l===null?(s.next=s,Jm(t)):(s.next=l.next,l.next=s),t.interleaved=s;return}}catch{}finally{}n=Cx(e,t,s,r),n!==null&&(s=At(),qn(n,e,r,s),Kx(n,t,r))}}function Vx(e){var t=e.alternate;return e===He||t!==null&&t===He}function qx(e,t){el=Au=!0;var n=e.pending;n===null?t.next=t:(t.next=n.next,n.next=t),e.pending=t}function Kx(e,t,n){if(n&4194240){var r=t.lanes;r&=e.pendingLanes,n|=r,t.lanes=n,$m(e,n)}}var Ou={readContext:Sn,useCallback:bt,useContext:bt,useEffect:bt,useImperativeHandle:bt,useInsertionEffect:bt,useLayoutEffect:bt,useMemo:bt,useReducer:bt,useRef:bt,useState:bt,useDebugValue:bt,useDeferredValue:bt,useTransition:bt,useMutableSource:bt,useSyncExternalStore:bt,useId:bt,unstable_isNewReconciler:!1},nP={readContext:Sn,useCallback:function(e,t){return ir().memoizedState=[e,t===void 0?null:t],e},useContext:Sn,useEffect:_y,useImperativeHandle:function(e,t,n){return n=n!=null?n.concat([e]):null,Jc(4194308,4,Fx.bind(null,t,e),n)},useLayoutEffect:function(e,t){return Jc(4194308,4,e,t)},useInsertionEffect:function(e,t){return Jc(4,2,e,t)}
vendor: 5,113 bytes, lines 39-41
39,useMemo:function(e,t){var n=ir();return t=t===void 0?null:t,e=e(),n.memoizedState=[e,t],e},useReducer:function(e,t,n){var r=ir();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=eP.bind(null,He,e),[r.memoizedState,e]},useRef:function(e){var t=ir();return e={current:e},t.memoizedState=e},useState:xy,useDebugValue:ag,useDeferredValue:function(e){return ir().memoizedState=e},useTransition:function(){var e=xy(!1),t=e[0];return e=XR.bind(null,e[1]),ir().memoizedState=e,[t,e]},useMutableSource:function(){},useSyncExternalStore:function(e,t,n){var r=He,s=ir();if(Be){if(n===void 0)throw Error($(407));n=n()}else{if(n=t(),ct===null)throw Error($(349));So&30||Ax(r,t,n)}s.memoizedState=n;var o={value:n,getSnapshot:t};return s.queue=o,_y(jx.bind(null,r,o,e),[e]),r.flags|=2048,_l(9,Ox.bind(null,r,o,n,t),void 0,null),n},useId:function(){var e=ir(),t=ct.identifierPrefix;if(Be){var n=$r,r=Lr;n=(r&~(1<<32-Vn(r)-1)).toString(32)+n,t=":"+t+"R"+n,n=bl++,0<n&&(t+="H"+n.toString(32)),t+=":"}else n=JR++,t=":"+t+"r"+n.toString(32)+":";return e.memoizedState=t},unstable_isNewReconciler:!1},rP={readContext:Sn,useCallback:Bx,useContext:Sn,useEffect:ig,useImperativeHandle:Ux,useInsertionEffect:Lx,useLayoutEffect:$x,useMemo:zx,useReducer:Of,useRef:Mx,useState:function(){return Of(xl)},useDebugValue:ag,useDeferredValue:function(e){var t=En();return Wx(t,rt.memoizedState,e)},useTransition:function(){var e=Of(xl)[0],t=En().memoizedState;return[e,t]},useMutableSource:Px,useSyncExternalStore:Nx,useId:Hx,unstable_isNewReconciler:!1},sP={readContext:Sn,useCallback:Bx,useContext:Sn,useEffect:ig,useImperativeHandle:Ux,useInsertionEffect:Lx,useLayoutEffect:$x,useMemo:zx,useReducer:jf,useRef:Mx,useState:function(){return jf(xl)},useDebugValue:ag,useDeferredValue:function(e){var t=En();return rt===null?t.memoizedState=e:Wx(t,rt.memoizedState,e)},useTransition:function(){var e=jf(xl)[0],t=En().memoizedState;return[e,t]},useMutableSource:Px,useSyncExternalStore:Nx,useId:Hx,unstable_isNewReconciler:!1};function Mn(e,t){if(e&&e.defaultProps){t=Ve({},t),e=e.defaultProps;for(var n in e)t[n]===void 0&&(t[n]=e[n]);return t}return t}function op(e,t,n,r){t=e.memoizedState,n=n(r,t),n=n==null?t:Ve({},t,n),e.memoizedState=n,e.lanes===0&&(e.updateQueue.baseState=n)}var vd={isMounted:function(e){return(e=e._reactInternals)?jo(e)===e:!1},enqueueSetState:function(e,t,n){e=e._reactInternals;var r=At(),s=Ts(e),o=Fr(r,s);o.payload=t,n!=null&&(o.callback=n),t=ks(e,o,s),t!==null&&(qn(t,e,s,r),Zc(t,e,s))},enqueueReplaceState:function(e,t,n){e=e._reactInternals;var r=At(),s=Ts(e),o=Fr(r,s);o.tag=1,o.payload=t,n!=null&&(o.callback=n),t=ks(e,o,s),t!==null&&(qn(t,e,s,r),Zc(t,e,s))},enqueueForceUpdate:function(e,t){e=e._reactInternals;var n=At(),r=Ts(e),s=Fr(n,r);s.tag=2,t!=null&&(s.callback=t),t=ks(e,s,r),t!==null&&(qn(t,e,r,n),Zc(t,e,r))}};function Sy(e,t,n,r,s,o,i){return e=e.stateNode,typeof e.shouldComponentUpdate=="function"?e.shouldComponentUpdate(r,o,i):t.prototype&&t.prototype.isPureReactComponent?!pl(n,r)||!pl(s,o):!0}function Gx(e,t,n){var r=!1,s=js,o=t.contextType;return typeof o=="object"&&o!==null?o=Sn(o):(s=Vt(t)?xo:Et.current,r=t.contextTypes,o=(r=r!=null)?Mi(e,s):js),t=new t(n,o),e.memoizedState=t.state!==null&&t.state!==void 0?t.state:null,t.updater=vd,e.stateNode=t,t._reactInternals=e,r&&(e=e.stateNode,e.__reactInternalMemoizedUnmaskedChildContext=s,e.__reactInternalMemoizedMaskedChildContext=o),t}function Ey(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&&vd.enqueueReplaceState(t,t.state,null)}function ip(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=Sn(o):(o=Vt(t)?xo:Et.current,s.context=Mi(e,o)),s.state=e.memoizedState,o=t.getDerivedStateFromProps,typeof o=="function"&&(op(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&&vd.enqueueReplaceState(s,s.state,null),Pu(e,n,s,r),s.state=e.memoizedState),typeof s.componentDidMount=="function"&&(e.flags|=4194308)}function Ui(e,t){try{var n="",r=t;do n+=OT(r),r=r.return;while(r);var s=n}catch(o){s=` 40Error generating stack: `+o.message+` 41`+o.stack}return{value:e,source:t,stack:s,digest:null}}function If(e,t,n){return{value:e,source:null,stack:n??null,digest:t??null}}function ap(e,t){try{console.error(t.value)}catch(n){setTimeout(function(){throw n})}}var oP=typeof WeakMap=="function"?WeakMap:Map;function Yx(e,t,n){n=Fr(-1,n),n.tag=3,n.payload={element:null};var r=t.value;return n.callback=function(){Iu||(Iu=!0,vp=r),ap(e,t)},n}
vendor: 6,088 bytes, line 41
41function Zx(e,t,n){n=Fr(-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(){ap(e,t)}}var o=e.stateNode;return o!==null&&typeof o.componentDidCatch=="function"&&(n.callback=function(){ap(e,t),typeof r!="function"&&(Cs===null?Cs=new Set([this]):Cs.add(this));var i=t.stack;this.componentDidCatch(t.value,{componentStack:i!==null?i:""})}),n}function ky(e,t,n){var r=e.pingCache;if(r===null){r=e.pingCache=new oP;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=wP.bind(null,e,t,n),t.then(e,e))}function Cy(e){do{var t;if((t=e.tag===13)&&(t=e.memoizedState,t=t!==null?t.dehydrated!==null:!0),t)return e;e=e.return}while(e!==null);return null}function Ty(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=Fr(-1,1),t.tag=2,ks(n,t,1))),n.lanes|=1),e)}var iP=Gr.ReactCurrentOwner,zt=!1;function Rt(e,t,n,r){t.child=e===null?kx(t,null,n,r):$i(t,e.child,n,r)}function Ry(e,t,n,r,s){n=n.render;var o=t.ref;return wi(t,s),r=sg(e,t,n,r,o,s),n=og(),e!==null&&!zt?(t.updateQueue=e.updateQueue,t.flags&=-2053,e.lanes&=~s,Hr(e,t,s)):(Be&&n&&qm(t),t.flags|=1,Rt(e,t,r,s),t.child)}function Py(e,t,n,r,s){if(e===null){var o=n.type;return typeof o=="function"&&!mg(o)&&o.defaultProps===void 0&&n.compare===null&&n.defaultProps===void 0?(t.tag=15,t.type=o,Qx(e,t,o,r,s)):(e=nu(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 i=o.memoizedProps;if(n=n.compare,n=n!==null?n:pl,n(i,r)&&e.ref===t.ref)return Hr(e,t,s)}return t.flags|=1,e=Rs(o,r),e.ref=t.ref,e.return=t,t.child=e}function Qx(e,t,n,r,s){if(e!==null){var o=e.memoizedProps;if(pl(o,r)&&e.ref===t.ref)if(zt=!1,t.pendingProps=r=o,(e.lanes&s)!==0)e.flags&131072&&(zt=!0);else return t.lanes=e.lanes,Hr(e,t,s)}return lp(e,t,n,r,s)}function Jx(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},Ie(hi,Xt),Xt|=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,Ie(hi,Xt),Xt|=e,null;t.memoizedState={baseLanes:0,cachePool:null,transitions:null},r=o!==null?o.baseLanes:n,Ie(hi,Xt),Xt|=r}else o!==null?(r=o.baseLanes|n,t.memoizedState=null):r=n,Ie(hi,Xt),Xt|=r;return Rt(e,t,s,n),t.child}function Xx(e,t){var n=t.ref;(e===null&&n!==null||e!==null&&e.ref!==n)&&(t.flags|=512,t.flags|=2097152)}function lp(e,t,n,r,s){var o=Vt(n)?xo:Et.current;return o=Mi(t,o),wi(t,s),n=sg(e,t,n,r,o,s),r=og(),e!==null&&!zt?(t.updateQueue=e.updateQueue,t.flags&=-2053,e.lanes&=~s,Hr(e,t,s)):(Be&&r&&qm(t),t.flags|=1,Rt(e,t,n,s),t.child)}function Ny(e,t,n,r,s){if(Vt(n)){var o=!0;Eu(t)}else o=!1;if(wi(t,s),t.stateNode===null)Xc(e,t),Gx(t,n,r),ip(t,n,r,s),r=!0;else if(e===null){var i=t.stateNode,a=t.memoizedProps;i.props=a;var l=i.context,c=n.contextType;typeof c=="object"&&c!==null?c=Sn(c):(c=Vt(n)?xo:Et.current,c=Mi(t,c));var u=n.getDerivedStateFromProps,d=typeof u=="function"||typeof i.getSnapshotBeforeUpdate=="function";d||typeof i.UNSAFE_componentWillReceiveProps!="function"&&typeof i.componentWillReceiveProps!="function"||(a!==r||l!==c)&&Ey(t,i,r,c),is=!1;var p=t.memoizedState;i.state=p,Pu(t,r,i,s),l=t.memoizedState,a!==r||p!==l||Ht.current||is?(typeof u=="function"&&(op(t,n,u,r),l=t.memoizedState),(a=is||Sy(t,n,a,r,p,l,c))?(d||typeof i.UNSAFE_componentWillMount!="function"&&typeof i.componentWillMount!="function"||(typeof i.componentWillMount=="function"&&i.componentWillMount(),typeof i.UNSAFE_componentWillMount=="function"&&i.UNSAFE_componentWillMount()),typeof i.componentDidMount=="function"&&(t.flags|=4194308)):(typeof i.componentDidMount=="function"&&(t.flags|=4194308),t.memoizedProps=r,t.memoizedState=l),i.props=r,i.state=l,i.context=c,r=a):(typeof i.componentDidMount=="function"&&(t.flags|=4194308),r=!1)}else{i=t.stateNode,Tx(e,t),a=t.memoizedProps,c=t.type===t.elementType?a:Mn(t.type,a),i.props=c,d=t.pendingProps,p=i.context,l=n.contextType,typeof l=="object"&&l!==null?l=Sn(l):(l=Vt(n)?xo:Et.current,l=Mi(t,l));var h=n.getDerivedStateFromProps;(u=typeof h=="function"||typeof i.getSnapshotBeforeUpdate=="function")||typeof i.UNSAFE_componentWillReceiveProps!="function"&&typeof i.componentWillReceiveProps!="function"||(a!==d||p!==l)&&Ey(t,i,r,l),is=!1,p=t.memoizedState,i.state=p,Pu(t,r,i,s);var x=t.memoizedState;a!==d||p!==x||Ht.current||is?(typeof h=="function"&&(op(t,n,h,r),x=t.memoizedState),(c=is||Sy(t,n,c,r,p,x,l)||!1)?(u||typeof i.UNSAFE_componentWillUpdate!="function"&&typeof i.componentWillUpdate!="function"||(typeof i.componentWillUpdate=="function"&&i.componentWillUpdate(r,x,l),typeof i.UNSAFE_componentWillUpdate=="function"&&i.UNSAFE_componentWillUpdate(r,x,l)),typeof i.componentDidUpdate=="function"&&(t.flags|=4),typeof i.getSnapshotBeforeUpdate=="function"&&(t.flags|=1024)):(typeof i.componentDidUpdate!="function"||a===e.memoizedProps&&p===e.memoizedState||(t.flags|=4),typeof i.getSnapshotBeforeUpdate!="function"||a===e.memoizedProps&&p===e.memoizedState||(t.flags|=1024),t.memoizedProps=r,t.memoizedState=x),i.props=r,i.state=x,i.context=l,r=c):(typeof i.componentDidUpdate!="function"||a===e.memoizedProps&&p===e.memoizedState||(t.flags|=4),typeof i.getSnapshotBeforeUpdate!="function"||a===e.memoizedProps&&p===e.memoizedState||(t.flags|=1024),r=!1)}return cp(e,t,n,r,o,s)}function cp(e,t,n,r,s,o){Xx(e,t);var i=(t.flags&128)!==0;if(!r&&!i)return s&&my(t,n,!1),Hr(e,t,o);r=t.stateNode,iP.current=t;var a=i&&typeof n.getDerivedStateFromError!="function"?null:r.render();return t.flags|=1,e!==null&&i?(t.child=$i(t,e.child,null,o),t.child=$i(t,null,a,o)):Rt(e,t,a,o),t.memoizedState=r.state,s&&my(t,n,!0),t.child}function e_(e){var t=e.stateNode;t.pendingContext?py(e,t.pendingContext,t.pendingContext!==t.context):t.context&&py(e,t.context,!1),eg(e,t.containerInfo)}
vendor: 8,684 bytes, line 41
41function Ay(e,t,n,r,s){return Li(),Gm(s),t.flags|=256,Rt(e,t,n,r),t.child}var up={dehydrated:null,treeContext:null,retryLane:0};function dp(e){return{baseLanes:e,cachePool:null,transitions:null}}function t_(e,t,n){var r=t.pendingProps,s=We.current,o=!1,i=(t.flags&128)!==0,a;if((a=i)||(a=e!==null&&e.memoizedState===null?!1:(s&2)!==0),a?(o=!0,t.flags&=-129):(e===null||e.memoizedState!==null)&&(s|=1),Ie(We,s&1),e===null)return rp(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):(i=r.children,e=r.fallback,o?(r=t.mode,o=t.child,i={mode:"hidden",children:i},!(r&1)&&o!==null?(o.childLanes=0,o.pendingProps=i):o=bd(i,r,0,null),e=bo(e,r,n,null),o.return=t,e.return=t,o.sibling=e,t.child=o,t.child.memoizedState=dp(n),t.memoizedState=up,e):lg(t,i));if(s=e.memoizedState,s!==null&&(a=s.dehydrated,a!==null))return aP(e,t,i,r,a,s,n);if(o){o=r.fallback,i=t.mode,s=e.child,a=s.sibling;var l={mode:"hidden",children:r.children};return!(i&1)&&t.child!==s?(r=t.child,r.childLanes=0,r.pendingProps=l,t.deletions=null):(r=Rs(s,l),r.subtreeFlags=s.subtreeFlags&14680064),a!==null?o=Rs(a,o):(o=bo(o,i,n,null),o.flags|=2),o.return=t,r.return=t,r.sibling=o,t.child=r,r=o,o=t.child,i=e.child.memoizedState,i=i===null?dp(n):{baseLanes:i.baseLanes|n,cachePool:null,transitions:i.transitions},o.memoizedState=i,o.childLanes=e.childLanes&~n,t.memoizedState=up,r}return o=e.child,e=o.sibling,r=Rs(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 lg(e,t){return t=bd({mode:"visible",children:t},e.mode,0,null),t.return=e,e.child=t}function _c(e,t,n,r){return r!==null&&Gm(r),$i(t,e.child,null,n),e=lg(t,t.pendingProps.children),e.flags|=2,t.memoizedState=null,e}function aP(e,t,n,r,s,o,i){if(n)return t.flags&256?(t.flags&=-257,r=If(Error($(422))),_c(e,t,i,r)):t.memoizedState!==null?(t.child=e.child,t.flags|=128,null):(o=r.fallback,s=t.mode,r=bd({mode:"visible",children:r.children},s,0,null),o=bo(o,s,i,null),o.flags|=2,r.return=t,o.return=t,r.sibling=o,t.child=r,t.mode&1&&$i(t,e.child,null,i),t.child.memoizedState=dp(i),t.memoizedState=up,o);if(!(t.mode&1))return _c(e,t,i,null);if(s.data==="$!"){if(r=s.nextSibling&&s.nextSibling.dataset,r)var a=r.dgst;return r=a,o=Error($(419)),r=If(o,r,void 0),_c(e,t,i,r)}if(a=(i&e.childLanes)!==0,zt||a){if(r=ct,r!==null){switch(i&-i){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|i)?0:s,s!==0&&s!==o.retryLane&&(o.retryLane=s,Wr(e,s),qn(r,e,s,-1))}return pg(),r=If(Error($(421))),_c(e,t,i,r)}return s.data==="$?"?(t.flags|=128,t.child=e.child,t=bP.bind(null,e),s._reactRetry=t,null):(e=o.treeContext,nn=Es(s.nextSibling),rn=t,Be=!0,Wn=null,e!==null&&(wn[bn++]=Lr,wn[bn++]=$r,wn[bn++]=_o,Lr=e.id,$r=e.overflow,_o=t),t=lg(t,r.children),t.flags|=4096,t)}function Oy(e,t,n){e.lanes|=t;var r=e.alternate;r!==null&&(r.lanes|=t),sp(e.return,t,n)}function Df(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 n_(e,t,n){var r=t.pendingProps,s=r.revealOrder,o=r.tail;if(Rt(e,t,r.children,n),r=We.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&&Oy(e,n,t);else if(e.tag===19)Oy(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(Ie(We,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&&Nu(e)===null&&(s=n),n=n.sibling;n=s,n===null?(s=t.child,t.child=null):(s=n.sibling,n.sibling=null),Df(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&&Nu(e)===null){t.child=s;break}e=s.sibling,s.sibling=n,n=s,s=e}Df(t,!0,n,null,o);break;case"together":Df(t,!1,null,null,void 0);break;default:t.memoizedState=null}return t.child}function Xc(e,t){!(t.mode&1)&&e!==null&&(e.alternate=null,t.alternate=null,t.flags|=2)}function Hr(e,t,n){if(e!==null&&(t.dependencies=e.dependencies),Eo|=t.lanes,!(n&t.childLanes))return null;if(e!==null&&t.child!==e.child)throw Error($(153));if(t.child!==null){for(e=t.child,n=Rs(e,e.pendingProps),t.child=n,n.return=t;e.sibling!==null;)e=e.sibling,n=n.sibling=Rs(e,e.pendingProps),n.return=t;n.sibling=null}return t.child}function lP(e,t,n){switch(t.tag){case 3:e_(t),Li();break;case 5:Rx(t);break;case 1:Vt(t.type)&&Eu(t);break;case 4:eg(t,t.stateNode.containerInfo);break;case 10:var r=t.type._context,s=t.memoizedProps.value;Ie(Tu,r._currentValue),r._currentValue=s;break;case 13:if(r=t.memoizedState,r!==null)return r.dehydrated!==null?(Ie(We,We.current&1),t.flags|=128,null):n&t.child.childLanes?t_(e,t,n):(Ie(We,We.current&1),e=Hr(e,t,n),e!==null?e.sibling:null);Ie(We,We.current&1);break;case 19:if(r=(n&t.childLanes)!==0,e.flags&128){if(r)return n_(e,t,n);t.flags|=128}if(s=t.memoizedState,s!==null&&(s.rendering=null,s.tail=null,s.lastEffect=null),Ie(We,We.current),r)break;return null;case 22:case 23:return t.lanes=0,Jx(e,t,n)}return Hr(e,t,n)}var r_,fp,s_,o_;r_=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}};fp=function(){};s_=function(e,t,n,r){var s=e.memoizedProps;if(s!==r){e=t.stateNode,co(gr.current);var o=null;switch(n){case"input":s=Ih(e,s),r=Ih(e,r),o=[];break;case"select":s=Ve({},s,{value:void 0}),r=Ve({},r,{value:void 0}),o=[];break;case"textarea":s=Lh(e,s),r=Lh(e,r),o=[];break;default:typeof s.onClick!="function"&&typeof r.onClick=="function"&&(e.onclick=_u)}Fh(n,r);var i;n=null;for(c in s)if(!r.hasOwnProperty(c)&&s.hasOwnProperty(c)&&s[c]!=null)if(c==="style"){var a=s[c];for(i in a)a.hasOwnProperty(i)&&(n||(n={}),n[i]="")}else c!=="dangerouslySetInnerHTML"&&c!=="children"&&c!=="suppressContentEditableWarning"&&c!=="suppressHydrationWarning"&&c!=="autoFocus"&&(al.hasOwnProperty(c)?o||(o=[]):(o=o||[]).push(c,null));for(c in r){var l=r[c];if(a=s!=null?s[c]:void 0,r.hasOwnProperty(c)&&l!==a&&(l!=null||a!=null))if(c==="style")if(a){for(i in a)!a.hasOwnProperty(i)||l&&l.hasOwnProperty(i)||(n||(n={}),n[i]="");for(i in l)l.hasOwnProperty(i)&&a[i]!==l[i]&&(n||(n={}),n[i]=l[i])}else n||(o||(o=[]),o.push(c,n)),n=l;else c==="dangerouslySetInnerHTML"?(l=l?l.__html:void 0,a=a?a.__html:void 0,l!=null&&a!==l&&(o=o||[]).push(c,l)):c==="children"?typeof l!="string"&&typeof l!="number"||(o=o||[]).push(c,""+l):c!=="suppressContentEditableWarning"&&c!=="suppressHydrationWarning"&&(al.hasOwnProperty(c)?(l!=null&&c==="onScroll"&&$e("scroll",e),o||a===l||(o=[])):(o=o||[]).push(c,l))}n&&(o=o||[]).push("style",n);var c=o;(t.updateQueue=c)&&(t.flags|=4)}};o_=function(e,t,n,r){n!==r&&(t.flags|=4)};function Ea(e,t){if(!Be)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 xt(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 cP(e,t,n){var r=t.pendingProps;switch(Km(t),t.tag){case 2:case 16:case 15:case 0:case 11:case 7:case 8:case 12:case 9:case 14:return xt(t),null;case 1:return Vt(t.type)&&Su(),xt(t),null;case 3:return r=t.stateNode,Fi(),Fe(Ht),Fe(Et),ng(),r.pendingContext&&(r.context=r.pendingContext,r.pendingContext=null),(e===null||e.child===null)&&(bc(t)?t.flags|=4:e===null||e.memoizedState.isDehydrated&&!(t.flags&256)||(t.flags|=1024,Wn!==null&&(bp(Wn),Wn=null))),fp(e,t),xt(t),null;case 5:tg(t);var s=co(wl.current);
vendor: 29,713 bytes, line 41
41if(n=t.type,e!==null&&t.stateNode!=null)s_(e,t,n,r,s),e.ref!==t.ref&&(t.flags|=512,t.flags|=2097152);else{if(!r){if(t.stateNode===null)throw Error($(166));return xt(t),null}if(e=co(gr.current),bc(t)){r=t.stateNode,n=t.type;var o=t.memoizedProps;switch(r[ur]=t,r[vl]=o,e=(t.mode&1)!==0,n){case"dialog":$e("cancel",r),$e("close",r);break;case"iframe":case"object":case"embed":$e("load",r);break;case"video":case"audio":for(s=0;s<Ha.length;s++)$e(Ha[s],r);break;case"source":$e("error",r);break;case"img":case"image":case"link":$e("error",r),$e("load",r);break;case"details":$e("toggle",r);break;case"input":Bv(r,o),$e("invalid",r);break;case"select":r._wrapperState={wasMultiple:!!o.multiple},$e("invalid",r);break;case"textarea":Wv(r,o),$e("invalid",r)}Fh(n,o),s=null;for(var i in o)if(o.hasOwnProperty(i)){var a=o[i];i==="children"?typeof a=="string"?r.textContent!==a&&(o.suppressHydrationWarning!==!0&&wc(r.textContent,a,e),s=["children",a]):typeof a=="number"&&r.textContent!==""+a&&(o.suppressHydrationWarning!==!0&&wc(r.textContent,a,e),s=["children",""+a]):al.hasOwnProperty(i)&&a!=null&&i==="onScroll"&&$e("scroll",r)}switch(n){case"input":dc(r),zv(r,o,!0);break;case"textarea":dc(r),Hv(r);break;case"select":case"option":break;default:typeof o.onClick=="function"&&(r.onclick=_u)}r=s,t.updateQueue=r,r!==null&&(t.flags|=4)}else{i=s.nodeType===9?s:s.ownerDocument,e==="http://www.w3.org/1999/xhtml"&&(e=jb(n)),e==="http://www.w3.org/1999/xhtml"?n==="script"?(e=i.createElement("div"),e.innerHTML="<script><\/script>",e=e.removeChild(e.firstChild)):typeof r.is=="string"?e=i.createElement(n,{is:r.is}):(e=i.createElement(n),n==="select"&&(i=e,r.multiple?i.multiple=!0:r.size&&(i.size=r.size))):e=i.createElementNS(e,n),e[ur]=t,e[vl]=r,r_(e,t,!1,!1),t.stateNode=e;e:{switch(i=Uh(n,r),n){case"dialog":$e("cancel",e),$e("close",e),s=r;break;case"iframe":case"object":case"embed":$e("load",e),s=r;break;case"video":case"audio":for(s=0;s<Ha.length;s++)$e(Ha[s],e);s=r;break;case"source":$e("error",e),s=r;break;case"img":case"image":case"link":$e("error",e),$e("load",e),s=r;break;case"details":$e("toggle",e),s=r;break;case"input":Bv(e,r),s=Ih(e,r),$e("invalid",e);break;case"option":s=r;break;case"select":e._wrapperState={wasMultiple:!!r.multiple},s=Ve({},r,{value:void 0}),$e("invalid",e);break;case"textarea":Wv(e,r),s=Lh(e,r),$e("invalid",e);break;default:s=r}Fh(n,s),a=s;for(o in a)if(a.hasOwnProperty(o)){var l=a[o];o==="style"?Mb(e,l):o==="dangerouslySetInnerHTML"?(l=l?l.__html:void 0,l!=null&&Ib(e,l)):o==="children"?typeof l=="string"?(n!=="textarea"||l!=="")&&ll(e,l):typeof l=="number"&&ll(e,""+l):o!=="suppressContentEditableWarning"&&o!=="suppressHydrationWarning"&&o!=="autoFocus"&&(al.hasOwnProperty(o)?l!=null&&o==="onScroll"&&$e("scroll",e):l!=null&&Om(e,o,l,i))}switch(n){case"input":dc(e),zv(e,r,!1);break;case"textarea":dc(e),Hv(e);break;case"option":r.value!=null&&e.setAttribute("value",""+Os(r.value));break;case"select":e.multiple=!!r.multiple,o=r.value,o!=null?mi(e,!!r.multiple,o,!1):r.defaultValue!=null&&mi(e,!!r.multiple,r.defaultValue,!0);break;default:typeof s.onClick=="function"&&(e.onclick=_u)}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 xt(t),null;case 6:if(e&&t.stateNode!=null)o_(e,t,e.memoizedProps,r);else{if(typeof r!="string"&&t.stateNode===null)throw Error($(166));if(n=co(wl.current),co(gr.current),bc(t)){if(r=t.stateNode,n=t.memoizedProps,r[ur]=t,(o=r.nodeValue!==n)&&(e=rn,e!==null))switch(e.tag){case 3:wc(r.nodeValue,n,(e.mode&1)!==0);break;case 5:e.memoizedProps.suppressHydrationWarning!==!0&&wc(r.nodeValue,n,(e.mode&1)!==0)}o&&(t.flags|=4)}else r=(n.nodeType===9?n:n.ownerDocument).createTextNode(r),r[ur]=t,t.stateNode=r}return xt(t),null;case 13:if(Fe(We),r=t.memoizedState,e===null||e.memoizedState!==null&&e.memoizedState.dehydrated!==null){if(Be&&nn!==null&&t.mode&1&&!(t.flags&128))Sx(),Li(),t.flags|=98560,o=!1;else if(o=bc(t),r!==null&&r.dehydrated!==null){if(e===null){if(!o)throw Error($(318));if(o=t.memoizedState,o=o!==null?o.dehydrated:null,!o)throw Error($(317));o[ur]=t}else Li(),!(t.flags&128)&&(t.memoizedState=null),t.flags|=4;xt(t),o=!1}else Wn!==null&&(bp(Wn),Wn=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||We.current&1?ot===0&&(ot=3):pg())),t.updateQueue!==null&&(t.flags|=4),xt(t),null);case 4:return Fi(),fp(e,t),e===null&&ml(t.stateNode.containerInfo),xt(t),null;case 10:return Qm(t.type._context),xt(t),null;case 17:return Vt(t.type)&&Su(),xt(t),null;case 19:if(Fe(We),o=t.memoizedState,o===null)return xt(t),null;if(r=(t.flags&128)!==0,i=o.rendering,i===null)if(r)Ea(o,!1);else{if(ot!==0||e!==null&&e.flags&128)for(e=t.child;e!==null;){if(i=Nu(e),i!==null){for(t.flags|=128,Ea(o,!1),r=i.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,i=o.alternate,i===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=i.childLanes,o.lanes=i.lanes,o.child=i.child,o.subtreeFlags=0,o.deletions=null,o.memoizedProps=i.memoizedProps,o.memoizedState=i.memoizedState,o.updateQueue=i.updateQueue,o.type=i.type,e=i.dependencies,o.dependencies=e===null?null:{lanes:e.lanes,firstContext:e.firstContext}),n=n.sibling;return Ie(We,We.current&1|2),t.child}e=e.sibling}o.tail!==null&&Ze()>Bi&&(t.flags|=128,r=!0,Ea(o,!1),t.lanes=4194304)}else{if(!r)if(e=Nu(i),e!==null){if(t.flags|=128,r=!0,n=e.updateQueue,n!==null&&(t.updateQueue=n,t.flags|=4),Ea(o,!0),o.tail===null&&o.tailMode==="hidden"&&!i.alternate&&!Be)return xt(t),null}else 2*Ze()-o.renderingStartTime>Bi&&n!==1073741824&&(t.flags|=128,r=!0,Ea(o,!1),t.lanes=4194304);o.isBackwards?(i.sibling=t.child,t.child=i):(n=o.last,n!==null?n.sibling=i:t.child=i,o.last=i)}return o.tail!==null?(t=o.tail,o.rendering=t,o.tail=t.sibling,o.renderingStartTime=Ze(),t.sibling=null,n=We.current,Ie(We,r?n&1|2:n&1),t):(xt(t),null);case 22:case 23:return hg(),r=t.memoizedState!==null,e!==null&&e.memoizedState!==null!==r&&(t.flags|=8192),r&&t.mode&1?Xt&1073741824&&(xt(t),t.subtreeFlags&6&&(t.flags|=8192)):xt(t),null;case 24:return null;case 25:return null}throw Error($(156,t.tag))}function uP(e,t){switch(Km(t),t.tag){case 1:return Vt(t.type)&&Su(),e=t.flags,e&65536?(t.flags=e&-65537|128,t):null;case 3:return Fi(),Fe(Ht),Fe(Et),ng(),e=t.flags,e&65536&&!(e&128)?(t.flags=e&-65537|128,t):null;case 5:return tg(t),null;case 13:if(Fe(We),e=t.memoizedState,e!==null&&e.dehydrated!==null){if(t.alternate===null)throw Error($(340));Li()}return e=t.flags,e&65536?(t.flags=e&-65537|128,t):null;case 19:return Fe(We),null;case 4:return Fi(),null;case 10:return Qm(t.type._context),null;case 22:case 23:return hg(),null;case 24:return null;default:return null}}var Sc=!1,St=!1,dP=typeof WeakSet=="function"?WeakSet:Set,G=null;function fi(e,t){var n=e.ref;if(n!==null)if(typeof n=="function")try{n(null)}catch(r){Ye(e,t,r)}else n.current=null}function hp(e,t,n){try{n()}catch(r){Ye(e,t,r)}}var jy=!1;function fP(e,t){if(Zh=wu,e=ux(),Vm(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 i=0,a=-1,l=-1,c=0,u=0,d=e,p=null;t:for(;;){for(var h;d!==n||s!==0&&d.nodeType!==3||(a=i+s),d!==o||r!==0&&d.nodeType!==3||(l=i+r),d.nodeType===3&&(i+=d.nodeValue.length),(h=d.firstChild)!==null;)p=d,d=h;for(;;){if(d===e)break t;if(p===n&&++c===s&&(a=i),p===o&&++u===r&&(l=i),(h=d.nextSibling)!==null)break;d=p,p=d.parentNode}d=h}n=a===-1||l===-1?null:{start:a,end:l}}else n=null}n=n||{start:0,end:0}}else n=null;for(Qh={focusedElem:e,selectionRange:n},wu=!1,G=t;G!==null;)if(t=G,e=t.child,(t.subtreeFlags&1028)!==0&&e!==null)e.return=t,G=e;else for(;G!==null;){t=G;try{var x=t.alternate;if(t.flags&1024)switch(t.tag){case 0:case 11:case 15:break;case 1:if(x!==null){var v=x.memoizedProps,b=x.memoizedState,w=t.stateNode,g=w.getSnapshotBeforeUpdate(t.elementType===t.type?v:Mn(t.type,v),b);w.__reactInternalSnapshotBeforeUpdate=g}break;case 3:var y=t.stateNode.containerInfo;y.nodeType===1?y.textContent="":y.nodeType===9&&y.documentElement&&y.removeChild(y.documentElement);break;case 5:case 6:case 4:case 17:break;default:throw Error($(163))}}catch(_){Ye(t,t.return,_)}if(e=t.sibling,e!==null){e.return=t.return,G=e;break}G=t.return}return x=jy,jy=!1,x}function tl(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&&hp(t,n,o)}s=s.next}while(s!==r)}}function yd(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 pp(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 i_(e){var t=e.alternate;t!==null&&(e.alternate=null,i_(t)),e.child=null,e.deletions=null,e.sibling=null,e.tag===5&&(t=e.stateNode,t!==null&&(delete t[ur],delete t[vl],delete t[ep],delete t[GR],delete t[YR])),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 a_(e){return e.tag===5||e.tag===3||e.tag===4}function Iy(e){e:for(;;){for(;e.sibling===null;){if(e.return===null||a_(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 mp(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=_u));else if(r!==4&&(e=e.child,e!==null))for(mp(e,t,n),e=e.sibling;e!==null;)mp(e,t,n),e=e.sibling}function gp(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(gp(e,t,n),e=e.sibling;e!==null;)gp(e,t,n),e=e.sibling}var mt=null,Bn=!1;function Xr(e,t,n){for(n=n.child;n!==null;)l_(e,t,n),n=n.sibling}function l_(e,t,n){if(mr&&typeof mr.onCommitFiberUnmount=="function")try{mr.onCommitFiberUnmount(ud,n)}catch{}switch(n.tag){case 5:St||fi(n,t);case 6:var r=mt,s=Bn;mt=null,Xr(e,t,n),mt=r,Bn=s,mt!==null&&(Bn?(e=mt,n=n.stateNode,e.nodeType===8?e.parentNode.removeChild(n):e.removeChild(n)):mt.removeChild(n.stateNode));break;case 18:mt!==null&&(Bn?(e=mt,n=n.stateNode,e.nodeType===8?Rf(e.parentNode,n):e.nodeType===1&&Rf(e,n),fl(e)):Rf(mt,n.stateNode));break;case 4:r=mt,s=Bn,mt=n.stateNode.containerInfo,Bn=!0,Xr(e,t,n),mt=r,Bn=s;break;case 0:case 11:case 14:case 15:if(!St&&(r=n.updateQueue,r!==null&&(r=r.lastEffect,r!==null))){s=r=r.next;do{var o=s,i=o.destroy;o=o.tag,i!==void 0&&(o&2||o&4)&&hp(n,t,i),s=s.next}while(s!==r)}Xr(e,t,n);break;case 1:if(!St&&(fi(n,t),r=n.stateNode,typeof r.componentWillUnmount=="function"))try{r.props=n.memoizedProps,r.state=n.memoizedState,r.componentWillUnmount()}catch(a){Ye(n,t,a)}Xr(e,t,n);break;case 21:Xr(e,t,n);break;case 22:n.mode&1?(St=(r=St)||n.memoizedState!==null,Xr(e,t,n),St=r):Xr(e,t,n);break;default:Xr(e,t,n)}}function Dy(e){var t=e.updateQueue;if(t!==null){e.updateQueue=null;var n=e.stateNode;n===null&&(n=e.stateNode=new dP),t.forEach(function(r){var s=xP.bind(null,e,r);n.has(r)||(n.add(r),r.then(s,s))})}}function An(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,i=t,a=i;e:for(;a!==null;){switch(a.tag){case 5:mt=a.stateNode,Bn=!1;break e;case 3:mt=a.stateNode.containerInfo,Bn=!0;break e;case 4:mt=a.stateNode.containerInfo,Bn=!0;break e}a=a.return}if(mt===null)throw Error($(160));l_(o,i,s),mt=null,Bn=!1;var l=s.alternate;l!==null&&(l.return=null),s.return=null}catch(c){Ye(s,t,c)}}if(t.subtreeFlags&12854)for(t=t.child;t!==null;)c_(t,e),t=t.sibling}function c_(e,t){var n=e.alternate,r=e.flags;switch(e.tag){case 0:case 11:case 14:case 15:if(An(t,e),sr(e),r&4){try{tl(3,e,e.return),yd(3,e)}catch(v){Ye(e,e.return,v)}try{tl(5,e,e.return)}catch(v){Ye(e,e.return,v)}}break;case 1:An(t,e),sr(e),r&512&&n!==null&&fi(n,n.return);break;case 5:if(An(t,e),sr(e),r&512&&n!==null&&fi(n,n.return),e.flags&32){var s=e.stateNode;try{ll(s,"")}catch(v){Ye(e,e.return,v)}}if(r&4&&(s=e.stateNode,s!=null)){var o=e.memoizedProps,i=n!==null?n.memoizedProps:o,a=e.type,l=e.updateQueue;if(e.updateQueue=null,l!==null)try{a==="input"&&o.type==="radio"&&o.name!=null&&Ab(s,o),Uh(a,i);var c=Uh(a,o);for(i=0;i<l.length;i+=2){var u=l[i],d=l[i+1];u==="style"?Mb(s,d):u==="dangerouslySetInnerHTML"?Ib(s,d):u==="children"?ll(s,d):Om(s,u,d,c)}switch(a){case"input":Dh(s,o);break;case"textarea":Ob(s,o);break;case"select":var p=s._wrapperState.wasMultiple;s._wrapperState.wasMultiple=!!o.multiple;var h=o.value;h!=null?mi(s,!!o.multiple,h,!1):p!==!!o.multiple&&(o.defaultValue!=null?mi(s,!!o.multiple,o.defaultValue,!0):mi(s,!!o.multiple,o.multiple?[]:"",!1))}s[vl]=o}catch(v){Ye(e,e.return,v)}}break;case 6:if(An(t,e),sr(e),r&4){if(e.stateNode===null)throw Error($(162));s=e.stateNode,o=e.memoizedProps;try{s.nodeValue=o}catch(v){Ye(e,e.return,v)}}break;case 3:if(An(t,e),sr(e),r&4&&n!==null&&n.memoizedState.isDehydrated)try{fl(t.containerInfo)}catch(v){Ye(e,e.return,v)}break;case 4:An(t,e),sr(e);break;case 13:An(t,e),sr(e),s=e.child,s.flags&8192&&(o=s.memoizedState!==null,s.stateNode.isHidden=o,!o||s.alternate!==null&&s.alternate.memoizedState!==null||(dg=Ze())),r&4&&Dy(e);break;case 22:if(u=n!==null&&n.memoizedState!==null,e.mode&1?(St=(c=St)||u,An(t,e),St=c):An(t,e),sr(e),r&8192){if(c=e.memoizedState!==null,(e.stateNode.isHidden=c)&&!u&&e.mode&1)for(G=e,u=e.child;u!==null;){for(d=G=u;G!==null;){switch(p=G,h=p.child,p.tag){case 0:case 11:case 14:case 15:tl(4,p,p.return);break;case 1:fi(p,p.return);var x=p.stateNode;if(typeof x.componentWillUnmount=="function"){r=p,n=p.return;try{t=r,x.props=t.memoizedProps,x.state=t.memoizedState,x.componentWillUnmount()}catch(v){Ye(r,n,v)}}break;case 5:fi(p,p.return);break;case 22:if(p.memoizedState!==null){Ly(d);continue}}h!==null?(h.return=p,G=h):Ly(d)}u=u.sibling}e:for(u=null,d=e;;){if(d.tag===5){if(u===null){u=d;try{s=d.stateNode,c?(o=s.style,typeof o.setProperty=="function"?o.setProperty("display","none","important"):o.display="none"):(a=d.stateNode,l=d.memoizedProps.style,i=l!=null&&l.hasOwnProperty("display")?l.display:null,a.style.display=Db("display",i))}catch(v){Ye(e,e.return,v)}}}else if(d.tag===6){if(u===null)try{d.stateNode.nodeValue=c?"":d.memoizedProps}catch(v){Ye(e,e.return,v)}}else if((d.tag!==22&&d.tag!==23||d.memoizedState===null||d===e)&&d.child!==null){d.child.return=d,d=d.child;continue}if(d===e)break e;for(;d.sibling===null;){if(d.return===null||d.return===e)break e;u===d&&(u=null),d=d.return}u===d&&(u=null),d.sibling.return=d.return,d=d.sibling}}break;case 19:An(t,e),sr(e),r&4&&Dy(e);break;case 21:break;default:An(t,e),sr(e)}}function sr(e){var t=e.flags;if(t&2){try{e:{for(var n=e.return;n!==null;){if(a_(n)){var r=n;break e}n=n.return}throw Error($(160))}switch(r.tag){case 5:var s=r.stateNode;r.flags&32&&(ll(s,""),r.flags&=-33);var o=Iy(e);gp(e,o,s);break;case 3:case 4:var i=r.stateNode.containerInfo,a=Iy(e);mp(e,a,i);break;default:throw Error($(161))}}catch(l){Ye(e,e.return,l)}e.flags&=-3}t&4096&&(e.flags&=-4097)}function hP(e,t,n){G=e,u_(e)}function u_(e,t,n){for(var r=(e.mode&1)!==0;G!==null;){var s=G,o=s.child;if(s.tag===22&&r){var i=s.memoizedState!==null||Sc;if(!i){var a=s.alternate,l=a!==null&&a.memoizedState!==null||St;a=Sc;var c=St;if(Sc=i,(St=l)&&!c)for(G=s;G!==null;)i=G,l=i.child,i.tag===22&&i.memoizedState!==null?$y(s):l!==null?(l.return=i,G=l):$y(s);for(;o!==null;)G=o,u_(o),o=o.sibling;G=s,Sc=a,St=c}My(e)}else s.subtreeFlags&8772&&o!==null?(o.return=s,G=o):My(e)}}function My(e){for(;G!==null;){var t=G;if(t.flags&8772){var n=t.alternate;try{if(t.flags&8772)switch(t.tag){case 0:case 11:case 15:St||yd(5,t);break;case 1:var r=t.stateNode;if(t.flags&4&&!St)if(n===null)r.componentDidMount();else{var s=t.elementType===t.type?n.memoizedProps:Mn(t.type,n.memoizedProps);r.componentDidUpdate(s,n.memoizedState,r.__reactInternalSnapshotBeforeUpdate)}var o=t.updateQueue;o!==null&&by(t,o,r);break;case 3:var i=t.updateQueue;if(i!==null){if(n=null,t.child!==null)switch(t.child.tag){case 5:n=t.child.stateNode;break;case 1:n=t.child.stateNode}by(t,i,n)}break;case 5:var a=t.stateNode;if(n===null&&t.flags&4){n=a;var l=t.memoizedProps;switch(t.type){case"button":case"input":case"select":case"textarea":l.autoFocus&&n.focus();break;case"img":l.src&&(n.src=l.src)}}break;case 6:break;case 4:break;case 12:break;case 13:if(t.memoizedState===null){var c=t.alternate;if(c!==null){var u=c.memoizedState;if(u!==null){var d=u.dehydrated;d!==null&&fl(d)}}}break;case 19:case 17:case 21:case 22:case 23:case 25:break;default:throw Error($(163))}St||t.flags&512&&pp(t)}catch(p){Ye(t,t.return,p)}}if(t===e){G=null;break}if(n=t.sibling,n!==null){n.return=t.return,G=n;break}G=t.return}}function Ly(e){for(;G!==null;){var t=G;if(t===e){G=null;break}var n=t.sibling;if(n!==null){n.return=t.return,G=n;break}G=t.return}}function $y(e){for(;G!==null;){var t=G;try{switch(t.tag){case 0:case 11:case 15:var n=t.return;try{yd(4,t)}catch(l){Ye(t,n,l)}break;case 1:var r=t.stateNode;if(typeof r.componentDidMount=="function"){var s=t.return;try{r.componentDidMount()}catch(l){Ye(t,s,l)}}var o=t.return;try{pp(t)}catch(l){Ye(t,o,l)}break;case 5:var i=t.return;try{pp(t)}catch(l){Ye(t,i,l)}}}catch(l){Ye(t,t.return,l)}if(t===e){G=null;break}var a=t.sibling;if(a!==null){a.return=t.return,G=a;break}G=t.return}}var pP=Math.ceil,ju=Gr.ReactCurrentDispatcher,cg=Gr.ReactCurrentOwner,_n=Gr.ReactCurrentBatchConfig,Ee=0,ct=null,et=null,gt=0,Xt=0,hi=Us(0),ot=0,Sl=null,Eo=0,wd=0,ug=0,nl=null,Bt=null,dg=0,Bi=1/0,jr=null,Iu=!1,vp=null,Cs=null,Ec=!1,ys=null,Du=0,rl=0,yp=null,eu=-1,tu=0;function At(){return Ee&6?Ze():eu!==-1?eu:eu=Ze()}function Ts(e){return e.mode&1?Ee&2&>!==0?gt&-gt:QR.transition!==null?(tu===0&&(tu=Gb()),tu):(e=Ae,e!==0||(e=window.event,e=e===void 0?16:tx(e.type)),e):1}function qn(e,t,n,r){if(50<rl)throw rl=0,yp=null,Error($(185));ql(e,n,r),(!(Ee&2)||e!==ct)&&(e===ct&&(!(Ee&2)&&(wd|=n),ot===4&&us(e,gt)),qt(e,r),n===1&&Ee===0&&!(t.mode&1)&&(Bi=Ze()+500,md&&Bs()))}function qt(e,t){var n=e.callbackNode;QT(e,t);var r=yu(e,e===ct?gt:0);if(r===0)n!==null&&Kv(n),e.callbackNode=null,e.callbackPriority=0;else if(t=r&-r,e.callbackPriority!==t){if(n!=null&&Kv(n),t===1)e.tag===0?ZR(Fy.bind(null,e)):bx(Fy.bind(null,e)),qR(function(){!(Ee&6)&&Bs()}),n=null;else{switch(Yb(r)){case 1:n=Lm;break;case 4:n=qb;break;case 16:n=vu;break;case 536870912:n=Kb;break;default:n=vu}n=y_(n,d_.bind(null,e))}e.callbackPriority=t,e.callbackNode=n}}function d_(e,t){if(eu=-1,tu=0,Ee&6)throw Error($(327));var n=e.callbackNode;if(bi()&&e.callbackNode!==n)return null;var r=yu(e,e===ct?gt:0);if(r===0)return null;if(r&30||r&e.expiredLanes||t)t=Mu(e,r);else{t=r;var s=Ee;Ee|=2;var o=h_();(ct!==e||gt!==t)&&(jr=null,Bi=Ze()+500,wo(e,t));do try{vP();break}catch(a){f_(e,a)}while(!0);Zm(),ju.current=o,Ee=s,et!==null?t=0:(ct=null,gt=0,t=ot)}if(t!==0){if(t===2&&(s=Vh(e),s!==0&&(r=s,t=wp(e,s))),t===1)throw n=Sl,wo(e,0),us(e,r),qt(e,Ze()),n;if(t===6)us(e,r);else{if(s=e.current.alternate,!(r&30)&&!mP(s)&&(t=Mu(e,r),t===2&&(o=Vh(e),o!==0&&(r=o,t=wp(e,o))),t===1))throw n=Sl,wo(e,0),us(e,r),qt(e,Ze()),n;switch(e.finishedWork=s,e.finishedLanes=r,t){case 0:case 1:throw Error($(345));case 2:no(e,Bt,jr);break;case 3:if(us(e,r),(r&130023424)===r&&(t=dg+500-Ze(),10<t)){if(yu(e,0)!==0)break;if(s=e.suspendedLanes,(s&r)!==r){At(),e.pingedLanes|=e.suspendedLanes&s;break}e.timeoutHandle=Xh(no.bind(null,e,Bt,jr),t);break}no(e,Bt,jr);break;case 4:if(us(e,r),(r&4194240)===r)break;for(t=e.eventTimes,s=-1;0<r;){var i=31-Vn(r);o=1<<i,i=t[i],i>s&&(s=i),r&=~o}if(r=s,r=Ze()-r,r=(120>r?120:480>r?480:1080>r?1080:1920>r?1920:3e3>r?3e3:4320>r?4320:1960*pP(r/1960))-r,10<r){e.timeoutHandle=Xh(no.bind(null,e,Bt,jr),r);break}no(e,Bt,jr);break;case 5:no(e,Bt,jr);break;default:throw Error($(329))}}}return qt(e,Ze()),e.callbackNode===n?d_.bind(null,e):null}function wp(e,t){var n=nl;return e.current.memoizedState.isDehydrated&&(wo(e,t).flags|=256),e=Mu(e,t),e!==2&&(t=Bt,Bt=n,t!==null&&bp(t)),e}function bp(e){Bt===null?Bt=e:Bt.push.apply(Bt,e)}function mP(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(!Kn(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 us(e,t){for(t&=~ug,t&=~wd,e.suspendedLanes|=t,e.pingedLanes&=~t,e=e.expirationTimes;0<t;){var n=31-Vn(t),r=1<<n;e[n]=-1,t&=~r}}function Fy(e){if(Ee&6)throw Error($(327));bi();var t=yu(e,0);if(!(t&1))return qt(e,Ze()),null;var n=Mu(e,t);if(e.tag!==0&&n===2){var r=Vh(e);r!==0&&(t=r,n=wp(e,r))}if(n===1)throw n=Sl,wo(e,0),us(e,t),qt(e,Ze()),n;if(n===6)throw Error($(345));return e.finishedWork=e.current.alternate,e.finishedLanes=t,no(e,Bt,jr),qt(e,Ze()),null}function fg(e,t){var n=Ee;Ee|=1;try{return e(t)}finally{Ee=n,Ee===0&&(Bi=Ze()+500,md&&Bs())}}function ko(e){ys!==null&&ys.tag===0&&!(Ee&6)&&bi();var t=Ee;Ee|=1;var n=_n.transition,r=Ae;try{if(_n.transition=null,Ae=1,e)return e()}finally{Ae=r,_n.transition=n,Ee=t,!(Ee&6)&&Bs()}}function hg(){Xt=hi.current,Fe(hi)}function wo(e,t){e.finishedWork=null,e.finishedLanes=0;var n=e.timeoutHandle;if(n!==-1&&(e.timeoutHandle=-1,VR(n)),et!==null)for(n=et.return;n!==null;){var r=n;switch(Km(r),r.tag){case 1:r=r.type.childContextTypes,r!=null&&Su();break;case 3:Fi(),Fe(Ht),Fe(Et),ng();break;case 5:tg(r);break;case 4:Fi();break;case 13:Fe(We);break;case 19:Fe(We);break;case 10:Qm(r.type._context);break;case 22:case 23:hg()}n=n.return}if(ct=e,et=e=Rs(e.current,null),gt=Xt=t,ot=0,Sl=null,ug=wd=Eo=0,Bt=nl=null,lo!==null){for(t=0;t<lo.length;t++)if(n=lo[t],r=n.interleaved,r!==null){n.interleaved=null;var s=r.next,o=n.pending;if(o!==null){var i=o.next;o.next=s,r.next=i}n.pending=r}lo=null}return e}function f_(e,t){do{var n=et;try{if(Zm(),Qc.current=Ou,Au){for(var r=He.memoizedState;r!==null;){var s=r.queue;s!==null&&(s.pending=null),r=r.next}Au=!1}if(So=0,lt=rt=He=null,el=!1,bl=0,cg.current=null,n===null||n.return===null){ot=1,Sl=t,et=null;break}e:{var o=e,i=n.return,a=n,l=t;if(t=gt,a.flags|=32768,l!==null&&typeof l=="object"&&typeof l.then=="function"){var c=l,u=a,d=u.tag;if(!(u.mode&1)&&(d===0||d===11||d===15)){var p=u.alternate;p?(u.updateQueue=p.updateQueue,u.memoizedState=p.memoizedState,u.lanes=p.lanes):(u.updateQueue=null,u.memoizedState=null)}var h=Cy(i);if(h!==null){h.flags&=-257,Ty(h,i,a,o,t),h.mode&1&&ky(o,c,t),t=h,l=c;var x=t.updateQueue;if(x===null){var v=new Set;v.add(l),t.updateQueue=v}else x.add(l);break e}else{if(!(t&1)){ky(o,c,t),pg();break e}l=Error($(426))}}else if(Be&&a.mode&1){var b=Cy(i);if(b!==null){!(b.flags&65536)&&(b.flags|=256),Ty(b,i,a,o,t),Gm(Ui(l,a));break e}}o=l=Ui(l,a),ot!==4&&(ot=2),nl===null?nl=[o]:nl.push(o),o=i;do{switch(o.tag){case 3:o.flags|=65536,t&=-t,o.lanes|=t;var w=Yx(o,l,t);wy(o,w);break e;case 1:a=l;var g=o.type,y=o.stateNode;if(!(o.flags&128)&&(typeof g.getDerivedStateFromError=="function"||y!==null&&typeof y.componentDidCatch=="function"&&(Cs===null||!Cs.has(y)))){o.flags|=65536,t&=-t,o.lanes|=t;var _=Zx(o,a,t);wy(o,_);break e}}o=o.return}while(o!==null)}m_(n)}catch(S){t=S,et===n&&n!==null&&(et=n=n.return);continue}break}while(!0)}function h_(){var e=ju.current;return ju.current=Ou,e===null?Ou:e}function pg(){(ot===0||ot===3||ot===2)&&(ot=4),ct===null||!(Eo&268435455)&&!(wd&268435455)||us(ct,gt)}function Mu(e,t){var n=Ee;Ee|=2;var r=h_();(ct!==e||gt!==t)&&(jr=null,wo(e,t));do try{gP();break}catch(s){f_(e,s)}while(!0);if(Zm(),Ee=n,ju.current=r,et!==null)throw Error($(261));return ct=null,gt=0,ot}function gP(){for(;et!==null;)p_(et)}function vP(){for(;et!==null&&!zT();)p_(et)}function p_(e){var t=v_(e.alternate,e,Xt);e.memoizedProps=e.pendingProps,t===null?m_(e):et=t,cg.current=null}function m_(e){var t=e;do{var n=t.alternate;if(e=t.return,t.flags&32768){if(n=uP(n,t),n!==null){n.flags&=32767,et=n;return}if(e!==null)e.flags|=32768,e.subtreeFlags=0,e.deletions=null;else{ot=6,et=null;return}}else if(n=cP(n,t,Xt),n!==null){et=n;return}if(t=t.sibling,t!==null){et=t;return}et=t=e}while(t!==null);ot===0&&(ot=5)}function no(e,t,n){var r=Ae,s=_n.transition;try{_n.transition=null,Ae=1,yP(e,t,n,r)}finally{_n.transition=s,Ae=r}return null}function yP(e,t,n,r){do bi();while(ys!==null);if(Ee&6)throw Error($(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($(177));e.callbackNode=null,e.callbackPriority=0;var o=n.lanes|n.childLanes;if(JT(e,o),e===ct&&(et=ct=null,gt=0),!(n.subtreeFlags&2064)&&!(n.flags&2064)||Ec||(Ec=!0,y_(vu,function(){return bi(),null})),o=(n.flags&15990)!==0,n.subtreeFlags&15990||o){o=_n.transition,_n.transition=null;var i=Ae;Ae=1;var a=Ee;Ee|=4,cg.current=null,fP(e,n),c_(n,e),$R(Qh),wu=!!Zh,Qh=Zh=null,e.current=n,hP(n),WT(),Ee=a,Ae=i,_n.transition=o}else e.current=n;if(Ec&&(Ec=!1,ys=e,Du=s),o=e.pendingLanes,o===0&&(Cs=null),qT(n.stateNode),qt(e,Ze()),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(Iu)throw Iu=!1,e=vp,vp=null,e;return Du&1&&e.tag!==0&&bi(),o=e.pendingLanes,o&1?e===yp?rl++:(rl=0,yp=e):rl=0,Bs(),null}function bi(){if(ys!==null){var e=Yb(Du),t=_n.transition,n=Ae;try{if(_n.transition=null,Ae=16>e?16:e,ys===null)var r=!1;else{if(e=ys,ys=null,Du=0,Ee&6)throw Error($(331));var s=Ee;for(Ee|=4,G=e.current;G!==null;){var o=G,i=o.child;if(G.flags&16){var a=o.deletions;if(a!==null){for(var l=0;l<a.length;l++){var c=a[l];for(G=c;G!==null;){var u=G;switch(u.tag){case 0:case 11:case 15:tl(8,u,o)}var d=u.child;if(d!==null)d.return=u,G=d;else for(;G!==null;){u=G;var p=u.sibling,h=u.return;if(i_(u),u===c){G=null;break}if(p!==null){p.return=h,G=p;break}G=h}}}var x=o.alternate;if(x!==null){var v=x.child;if(v!==null){x.child=null;do{var b=v.sibling;v.sibling=null,v=b}while(v!==null)}}G=o}}if(o.subtreeFlags&2064&&i!==null)i.return=o,G=i;else e:for(;G!==null;){if(o=G,o.flags&2048)switch(o.tag){case 0:case 11:case 15:tl(9,o,o.return)}var w=o.sibling;if(w!==null){w.return=o.return,G=w;break e}G=o.return}}var g=e.current;for(G=g;G!==null;){i=G;var y=i.child;if(i.subtreeFlags&2064&&y!==null)y.return=i,G=y;else e:for(i=g;G!==null;){if(a=G,a.flags&2048)try{switch(a.tag){case 0:case 11:case 15:yd(9,a)}}catch(S){Ye(a,a.return,S)}if(a===i){G=null;break e}var _=a.sibling;if(_!==null){_.return=a.return,G=_;break e}G=a.return}}if(Ee=s,Bs(),mr&&typeof mr.onPostCommitFiberRoot=="function")try{mr.onPostCommitFiberRoot(ud,e)}catch{}r=!0}return r}finally{Ae=n,_n.transition=t}}return!1}function Uy(e,t,n){t=Ui(n,t),t=Yx(e,t,1),e=ks(e,t,1),t=At(),e!==null&&(ql(e,1,t),qt(e,t))}function Ye(e,t,n){if(e.tag===3)Uy(e,e,n);else for(;t!==null;){if(t.tag===3){Uy(t,e,n);break}else if(t.tag===1){var r=t.stateNode;if(typeof t.type.getDerivedStateFromError=="function"||typeof r.componentDidCatch=="function"&&(Cs===null||!Cs.has(r))){e=Ui(n,e),e=Zx(t,e,1),t=ks(t,e,1),e=At(),t!==null&&(ql(t,1,e),qt(t,e));break}}t=t.return}}function wP(e,t,n){var r=e.pingCache;r!==null&&r.delete(t),t=At(),e.pingedLanes|=e.suspendedLanes&n,ct===e&&(gt&n)===n&&(ot===4||ot===3&&(gt&130023424)===gt&&500>Ze()-dg?wo(e,0):ug|=n),qt(e,t)}function g_(e,t){t===0&&(e.mode&1?(t=pc,pc<<=1,!(pc&130023424)&&(pc=4194304)):t=1);var n=At();e=Wr(e,t),e!==null&&(ql(e,t,n),qt(e,n))}function bP(e){var t=e.memoizedState,n=0;t!==null&&(n=t.retryLane),g_(e,n)}function xP(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($(314))}r!==null&&r.delete(t),g_(e,n)}var v_;v_=function(e,t,n){if(e!==null)if(e.memoizedProps!==t.pendingProps||Ht.current)zt=!0;else{if(!(e.lanes&n)&&!(t.flags&128))return zt=!1,lP(e,t,n);zt=!!(e.flags&131072)}else zt=!1,Be&&t.flags&1048576&&xx(t,Cu,t.index);switch(t.lanes=0,t.tag){case 2:var r=t.type;Xc(e,t),e=t.pendingProps;var s=Mi(t,Et.current);wi(t,n),s=sg(null,t,r,e,s,n);var o=og();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,Vt(r)?(o=!0,Eu(t)):o=!1,t.memoizedState=s.state!==null&&s.state!==void 0?s.state:null,Xm(t),s.updater=vd,t.stateNode=s,s._reactInternals=t,ip(t,r,e,n),t=cp(null,t,r,!0,o,n)):(t.tag=0,Be&&o&&qm(t),Rt(null,t,s,n),t=t.child),t;case 16:r=t.elementType;e:{switch(Xc(e,t),e=t.pendingProps,s=r._init,r=s(r._payload),t.type=r,s=t.tag=SP(r),e=Mn(r,e),s){case 0:t=lp(null,t,r,e,n);break e;case 1:t=Ny(null,t,r,e,n);break e;case 11:t=Ry(null,t,r,e,n);break e;case 14:t=Py(null,t,r,Mn(r.type,e),n);break e}throw Error($(306,r,""))}return t;case 0:return r=t.type,s=t.pendingProps,s=t.elementType===r?s:Mn(r,s),lp(e,t,r,s,n);case 1:return r=t.type,s=t.pendingProps,s=t.elementType===r?s:Mn(r,s),Ny(e,t,r,s,n);case 3:e:{if(e_(t),e===null)throw Error($(387));
vendor: 4,912 bytes, line 41
41r=t.pendingProps,o=t.memoizedState,s=o.element,Tx(e,t),Pu(t,r,null,n);var i=t.memoizedState;if(r=i.element,o.isDehydrated)if(o={element:r,isDehydrated:!1,cache:i.cache,pendingSuspenseBoundaries:i.pendingSuspenseBoundaries,transitions:i.transitions},t.updateQueue.baseState=o,t.memoizedState=o,t.flags&256){s=Ui(Error($(423)),t),t=Ay(e,t,r,n,s);break e}else if(r!==s){s=Ui(Error($(424)),t),t=Ay(e,t,r,n,s);break e}else for(nn=Es(t.stateNode.containerInfo.firstChild),rn=t,Be=!0,Wn=null,n=kx(t,null,r,n),t.child=n;n;)n.flags=n.flags&-3|4096,n=n.sibling;else{if(Li(),r===s){t=Hr(e,t,n);break e}Rt(e,t,r,n)}t=t.child}return t;case 5:return Rx(t),e===null&&rp(t),r=t.type,s=t.pendingProps,o=e!==null?e.memoizedProps:null,i=s.children,Jh(r,s)?i=null:o!==null&&Jh(r,o)&&(t.flags|=32),Xx(e,t),Rt(e,t,i,n),t.child;case 6:return e===null&&rp(t),null;case 13:return t_(e,t,n);case 4:return eg(t,t.stateNode.containerInfo),r=t.pendingProps,e===null?t.child=$i(t,null,r,n):Rt(e,t,r,n),t.child;case 11:return r=t.type,s=t.pendingProps,s=t.elementType===r?s:Mn(r,s),Ry(e,t,r,s,n);case 7:return Rt(e,t,t.pendingProps,n),t.child;case 8:return Rt(e,t,t.pendingProps.children,n),t.child;case 12:return Rt(e,t,t.pendingProps.children,n),t.child;case 10:e:{if(r=t.type._context,s=t.pendingProps,o=t.memoizedProps,i=s.value,Ie(Tu,r._currentValue),r._currentValue=i,o!==null)if(Kn(o.value,i)){if(o.children===s.children&&!Ht.current){t=Hr(e,t,n);break e}}else for(o=t.child,o!==null&&(o.return=t);o!==null;){var a=o.dependencies;if(a!==null){i=o.child;for(var l=a.firstContext;l!==null;){if(l.context===r){if(o.tag===1){l=Fr(-1,n&-n),l.tag=2;var c=o.updateQueue;if(c!==null){c=c.shared;var u=c.pending;u===null?l.next=l:(l.next=u.next,u.next=l),c.pending=l}}o.lanes|=n,l=o.alternate,l!==null&&(l.lanes|=n),sp(o.return,n,t),a.lanes|=n;break}l=l.next}}else if(o.tag===10)i=o.type===t.type?null:o.child;else if(o.tag===18){if(i=o.return,i===null)throw Error($(341));i.lanes|=n,a=i.alternate,a!==null&&(a.lanes|=n),sp(i,n,t),i=o.sibling}else i=o.child;if(i!==null)i.return=o;else for(i=o;i!==null;){if(i===t){i=null;break}if(o=i.sibling,o!==null){o.return=i.return,i=o;break}i=i.return}o=i}Rt(e,t,s.children,n),t=t.child}return t;case 9:return s=t.type,r=t.pendingProps.children,wi(t,n),s=Sn(s),r=r(s),t.flags|=1,Rt(e,t,r,n),t.child;case 14:return r=t.type,s=Mn(r,t.pendingProps),s=Mn(r.type,s),Py(e,t,r,s,n);case 15:return Qx(e,t,t.type,t.pendingProps,n);case 17:return r=t.type,s=t.pendingProps,s=t.elementType===r?s:Mn(r,s),Xc(e,t),t.tag=1,Vt(r)?(e=!0,Eu(t)):e=!1,wi(t,n),Gx(t,r,s),ip(t,r,s,n),cp(null,t,r,!0,e,n);case 19:return n_(e,t,n);case 22:return Jx(e,t,n)}throw Error($(156,t.tag))};function y_(e,t){return Vb(e,t)}function _P(e,t,n,r){this.tag=e,this.key=n,this.sibling=this.child=this.return=this.stateNode=this.type=this.elementType=null,this.index=0,this.ref=null,this.pendingProps=t,this.dependencies=this.memoizedState=this.updateQueue=this.memoizedProps=null,this.mode=r,this.subtreeFlags=this.flags=0,this.deletions=null,this.childLanes=this.lanes=0,this.alternate=null}function xn(e,t,n,r){return new _P(e,t,n,r)}function mg(e){return e=e.prototype,!(!e||!e.isReactComponent)}function SP(e){if(typeof e=="function")return mg(e)?1:0;if(e!=null){if(e=e.$$typeof,e===Im)return 11;if(e===Dm)return 14}return 2}function Rs(e,t){var n=e.alternate;return n===null?(n=xn(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 nu(e,t,n,r,s,o){var i=2;if(r=e,typeof e=="function")mg(e)&&(i=1);else if(typeof e=="string")i=5;else e:switch(e){case ri:return bo(n.children,s,o,t);case jm:i=8,s|=8;break;case Nh:return e=xn(12,n,t,s|2),e.elementType=Nh,e.lanes=o,e;case Ah:return e=xn(13,n,t,s),e.elementType=Ah,e.lanes=o,e;case Oh:return e=xn(19,n,t,s),e.elementType=Oh,e.lanes=o,e;case Rb:return bd(n,s,o,t);default:if(typeof e=="object"&&e!==null)switch(e.$$typeof){case Cb:i=10;break e;case Tb:i=9;break e;case Im:i=11;break e;case Dm:i=14;break e;case os:i=16,r=null;break e}throw Error($(130,e==null?e:typeof e,""))}return t=xn(i,n,t,s),t.elementType=e,t.type=r,t.lanes=o,t}function bo(e,t,n,r){return e=xn(7,e,r,t),e.lanes=n,e}function bd(e,t,n,r){return e=xn(22,e,r,t),e.elementType=Rb,e.lanes=n,e.stateNode={isHidden:!1},e}function Mf(e,t,n){return e=xn(6,e,null,t),e.lanes=n,e}function Lf(e,t,n){return t=xn(4,e.children!==null?e.children:[],e.key,t),t.lanes=n,t.stateNode={containerInfo:e.containerInfo,pendingChildren:null,implementation:e.implementation},t}
vendor: 5,453 bytes, line 41
41function EP(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=vf(0),this.expirationTimes=vf(-1),this.entangledLanes=this.finishedLanes=this.mutableReadLanes=this.expiredLanes=this.pingedLanes=this.suspendedLanes=this.pendingLanes=0,this.entanglements=vf(0),this.identifierPrefix=r,this.onRecoverableError=s,this.mutableSourceEagerHydrationData=null}function gg(e,t,n,r,s,o,i,a,l){return e=new EP(e,t,n,a,l),t===1?(t=1,o===!0&&(t|=8)):t=0,o=xn(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 kP(e,t,n){var r=3<arguments.length&&arguments[3]!==void 0?arguments[3]:null;return{$$typeof:ni,key:r==null?null:""+r,children:e,containerInfo:t,implementation:n}}function w_(e){if(!e)return js;e=e._reactInternals;e:{if(jo(e)!==e||e.tag!==1)throw Error($(170));var t=e;do{switch(t.tag){case 3:t=t.stateNode.context;break e;case 1:if(Vt(t.type)){t=t.stateNode.__reactInternalMemoizedMergedChildContext;break e}}t=t.return}while(t!==null);throw Error($(171))}if(e.tag===1){var n=e.type;if(Vt(n))return wx(e,n,t)}return t}function b_(e,t,n,r,s,o,i,a,l){return e=gg(n,r,!0,e,s,o,i,a,l),e.context=w_(null),n=e.current,r=At(),s=Ts(n),o=Fr(r,s),o.callback=t??null,ks(n,o,s),e.current.lanes=s,ql(e,s,r),qt(e,r),e}function xd(e,t,n,r){var s=t.current,o=At(),i=Ts(s);return n=w_(n),t.context===null?t.context=n:t.pendingContext=n,t=Fr(o,i),t.payload={element:e},r=r===void 0?null:r,r!==null&&(t.callback=r),e=ks(s,t,i),e!==null&&(qn(e,s,i,o),Zc(e,s,i)),i}function Lu(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 By(e,t){if(e=e.memoizedState,e!==null&&e.dehydrated!==null){var n=e.retryLane;e.retryLane=n!==0&&n<t?n:t}}function vg(e,t){By(e,t),(e=e.alternate)&&By(e,t)}function CP(){return null}var x_=typeof reportError=="function"?reportError:function(e){console.error(e)};function yg(e){this._internalRoot=e}_d.prototype.render=yg.prototype.render=function(e){var t=this._internalRoot;if(t===null)throw Error($(409));xd(e,t,null,null)};_d.prototype.unmount=yg.prototype.unmount=function(){var e=this._internalRoot;if(e!==null){this._internalRoot=null;var t=e.containerInfo;ko(function(){xd(null,e,null,null)}),t[zr]=null}};function _d(e){this._internalRoot=e}_d.prototype.unstable_scheduleHydration=function(e){if(e){var t=Jb();e={blockedOn:null,target:e,priority:t};for(var n=0;n<cs.length&&t!==0&&t<cs[n].priority;n++);cs.splice(n,0,e),n===0&&ex(e)}};function wg(e){return!(!e||e.nodeType!==1&&e.nodeType!==9&&e.nodeType!==11)}function Sd(e){return!(!e||e.nodeType!==1&&e.nodeType!==9&&e.nodeType!==11&&(e.nodeType!==8||e.nodeValue!==" react-mount-point-unstable "))}function zy(){}function TP(e,t,n,r,s){if(s){if(typeof r=="function"){var o=r;r=function(){var c=Lu(i);o.call(c)}}var i=b_(t,r,e,0,null,!1,!1,"",zy);return e._reactRootContainer=i,e[zr]=i.current,ml(e.nodeType===8?e.parentNode:e),ko(),i}for(;s=e.lastChild;)e.removeChild(s);if(typeof r=="function"){var a=r;r=function(){var c=Lu(l);a.call(c)}}var l=gg(e,0,!1,null,null,!1,!1,"",zy);return e._reactRootContainer=l,e[zr]=l.current,ml(e.nodeType===8?e.parentNode:e),ko(function(){xd(t,l,n,r)}),l}function Ed(e,t,n,r,s){var o=n._reactRootContainer;if(o){var i=o;if(typeof s=="function"){var a=s;s=function(){var l=Lu(i);a.call(l)}}xd(t,i,e,s)}else i=TP(n,t,e,s,r);return Lu(i)}Zb=function(e){switch(e.tag){case 3:var t=e.stateNode;if(t.current.memoizedState.isDehydrated){var n=Wa(t.pendingLanes);n!==0&&($m(t,n|1),qt(t,Ze()),!(Ee&6)&&(Bi=Ze()+500,Bs()))}break;case 13:ko(function(){var r=Wr(e,1);if(r!==null){var s=At();qn(r,e,1,s)}}),vg(e,1)}};Fm=function(e){if(e.tag===13){var t=Wr(e,134217728);if(t!==null){var n=At();qn(t,e,134217728,n)}vg(e,134217728)}};Qb=function(e){if(e.tag===13){var t=Ts(e),n=Wr(e,t);if(n!==null){var r=At();qn(n,e,t,r)}vg(e,t)}};Jb=function(){return Ae};Xb=function(e,t){var n=Ae;try{return Ae=e,t()}finally{Ae=n}};zh=function(e,t,n){switch(t){case"input":if(Dh(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=pd(r);if(!s)throw Error($(90));Nb(r),Dh(r,s)}}}break;case"textarea":Ob(e,n);break;case"select":t=n.value,t!=null&&mi(e,!!n.multiple,t,!1)}};Fb=fg;Ub=ko;var RP={usingClientEntryPoint:!1,Events:[Gl,ai,pd,Lb,$b,fg]},ka={findFiberByHostInstance:ao,bundleType:0,version:"18.3.1",rendererPackageName:"react-dom"},PP={bundleType:ka.bundleType,version:ka.version,rendererPackageName:ka.rendererPackageName,rendererConfig:ka.rendererConfig,overrideHookState:null,overrideHookStateDeletePath:null,overrideHookStateRenamePath:null,overrideProps:null,overridePropsDeletePath:null,overridePropsRenamePath:null,setErrorHandler:null,setSuspenseHandler:null,scheduleUpdate:null,currentDispatcherRef:Gr.ReactCurrentDispatcher,findHostInstanceByFiber:function(e){return e=Wb(e),e===null?null:e.stateNode},findFiberByHostInstance:ka.findFiberByHostInstance||CP,findHostInstancesForRefresh:null,scheduleRefresh:null,scheduleRoot:null,setRefreshHandler:null,getCurrentFiber:null,reconcilerVersion:"18.3.1-next-f1338f8080-20240426"};
41if(typeof __REACT_DEVTOOLS_GLOBAL_HOOK__<"u"){var kc=__REACT_DEVTOOLS_GLOBAL_HOOK__;if(!kc.isDisabled&&kc.supportsFiber)try{ud=kc.inject(PP),mr=kc}catch{}}cn.__SECRET_INTERNALS_DO_NOT_USE_OR_YOU_WILL_BE_FIRED=RP;cn.createPortal=function(e,t){var n=2<arguments.length&&arguments[2]!==void 0?arguments[2]:null;if(!wg(t))throw Error($(200));return kP(e,t,null,n)};cn.createRoot=function(e,t){if(!wg(e))throw Error($(299));var n=!1,r="",s=x_;return t!=null&&(t.unstable_strictMode===!0&&(n=!0),t.identifierPrefix!==void 0&&(r=t.identifierPrefix),t.onRecoverableError!==void 0&&(s=t.onRecoverableError)),t=gg(e,1,!1,null,null,n,!1,r,s),e[zr]=t.current,ml(e.nodeType===8?e.parentNode:e),new yg(t)};cn.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($(188)):(e=Object.keys(e).join(","),Error($(268,e)));return e=Wb(t),e=e===null?null:e.stateNode,e};cn.flushSync=function(e){return ko(e)};cn.hydrate=function(e,t,n){if(!Sd(t))throw Error($(200));return Ed(null,e,t,!0,n)};cn.hydrateRoot=function(e,t,n){if(!wg(e))throw Error($(405));var r=n!=null&&n.hydratedSources||null,s=!1,o="",i=x_;if(n!=null&&(n.unstable_strictMode===!0&&(s=!0),n.identifierPrefix!==void 0&&(o=n.identifierPrefix),n.onRecoverableError!==void 0&&(i=n.onRecoverableError)),t=b_(t,null,e,1,n??null,s,!1,o,i),e[zr]=t.current,ml(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 _d(t)};cn.render=function(e,t,n){if(!Sd(t))throw Error($(200));return Ed(null,e,t,!1,n)};cn.unmountComponentAtNode=function(e){if(!Sd(e))throw Error($(40));return e._reactRootContainer?(ko(function(){Ed(null,null,e,!1,function(){e._reactRootContainer=null,e[zr]=null})}),!0):!1};cn.unstable_batchedUpdates=fg;cn.unstable_renderSubtreeIntoContainer=function(e,t,n,r){if(!Sd(n))throw Error($(200));if(e==null||e._reactInternals===void 0)throw Error($(38));return Ed(e,t,n,!1,r)};cn.version="18.3.1-next-f1338f8080-20240426";function __(){if(!(typeof __REACT_DEVTOOLS_GLOBAL_HOOK__>"u"||typeof __REACT_DEVTOOLS_GLOBAL_HOOK__.checkDCE!="function"))try{__REACT_DEVTOOLS_GLOBAL_HOOK__.checkDCE(__)}catch(e){console.error(e)}}__(),_b.exports=cn;var Io=_b.exports;const S_=Hl(Io);var E_,Wy=Io;E_=Wy.createRoot,Wy.hydrateRoot;var NP=typeof Element<"u",AP=typeof Map=="function",OP=typeof Set=="function",jP=typeof ArrayBuffer=="function"&&!!ArrayBuffer.isView;function ru(e,t){if(e===t)return!0;if(e&&t&&typeof e=="object"&&typeof t=="object"){if(e.constructor!==t.constructor)return!1;var n,r,s;if(Array.isArray(e)){if(n=e.length,n!=t.length)return!1;for(r=n;r--!==0;)if(!ru(e[r],t[r]))return!1;return!0}var o;if(AP&&e instanceof Map&&t instanceof Map){if(e.size!==t.size)return!1;for(o=e.entries();!(r=o.next()).done;)if(!t.has(r.value[0]))return!1;for(o=e.entries();!(r=o.next()).done;)if(!ru(r.value[1],t.get(r.value[0])))return!1;return!0}if(OP&&e instanceof Set&&t instanceof Set){if(e.size!==t.size)return!1;for(o=e.entries();!(r=o.next()).done;)if(!t.has(r.value[0]))return!1;return!0}if(jP&&ArrayBuffer.isView(e)&&ArrayBuffer.isView(t)){if(n=e.length,n!=t.length)return!1;for(r=n;r--!==0;)if(e[r]!==t[r])return!1;return!0}if(e.constructor===RegExp)return e.source===t.source&&e.flags===t.flags;if(e.valueOf!==Object.prototype.valueOf&&typeof e.valueOf=="function"&&typeof t.valueOf=="function")return e.valueOf()===t.valueOf();if(e.toString!==Object.prototype.toString&&typeof e.toString=="function"&&typeof t.toString=="function")return e.toString()===t.toString();if(s=Object.keys(e),n=s.length,n!==Object.keys(t).length)return!1;for(r=n;r--!==0;)if(!Object.prototype.hasOwnProperty.call(t,s[r]))return!1;if(NP&&e instanceof Element)return!1;for(r=n;r--!==0;)if(!((s[r]==="_owner"||s[r]==="__v"||s[r]==="__o")&&e.$$typeof)&&!ru(e[s[r]],t[s[r]]))return!1;return!0}return e!==e&&t!==t}var IP=function(t,n){try{return ru(t,n)}catch(r){if((r.message||"").match(/stack|recursion/i))return console.warn("react-fast-compare cannot handle circular refs"),!1;throw r}};const DP=Hl(IP);var MP=function(e,t,n,r,s,o,i,a){if(!e){var l;if(t===void 0)l=new Error("Minified exception occurred; use the non-minified dev environment for the full error message and additional helpful warnings.");else{var c=[n,r,s,o,i,a],u=0;l=new Error(t.replace(/%s/g,function(){return c[u++]})),l.name="Invariant Violation"}throw l.framesToPop=1,l}},LP=MP;const Hy=Hl(LP);var $P=function(t,n,r,s){var o=r?r.call(s,t,n):void 0;if(o!==void 0)return!!o;if(t===n)return!0;
41if(typeof t!="object"||!t||typeof n!="object"||!n)return!1;var i=Object.keys(t),a=Object.keys(n);if(i.length!==a.length)return!1;for(var l=Object.prototype.hasOwnProperty.bind(n),c=0;c<i.length;c++){var u=i[c];if(!l(u))return!1;var d=t[u],p=n[u];if(o=r?r.call(s,d,p,u):void 0,o===!1||o===void 0&&d!==p)return!1}return!0};const FP=Hl($P);var k_=(e=>(e.BASE="base",e.BODY="body",e.HEAD="head",e.HTML="html",e.LINK="link",e.META="meta",e.NOSCRIPT="noscript",e.SCRIPT="script",e.STYLE="style",e.TITLE="title",e.FRAGMENT="Symbol(react.fragment)",e))(k_||{}),$f={link:{rel:["amphtml","canonical","alternate"]},script:{type:["application/ld+json"]},meta:{charset:"",name:["generator","robots","description"],property:["og:type","og:title","og:url","og:image","og:image:alt","og:description","twitter:url","twitter:title","twitter:description","twitter:image","twitter:image:alt","twitter:card","twitter:site"]}},Vy=Object.values(k_),kd={accesskey:"accessKey",charset:"charSet",class:"className",contenteditable:"contentEditable",contextmenu:"contextMenu","http-equiv":"httpEquiv",itemprop:"itemProp",tabindex:"tabIndex"},C_=Object.entries(kd).reduce((e,[t,n])=>(e[n]=t,e),{}),Hn="data-rh",xi={DEFAULT_TITLE:"defaultTitle",DEFER:"defer",ENCODE_SPECIAL_CHARACTERS:"encodeSpecialCharacters",ON_CHANGE_CLIENT_STATE:"onChangeClientState",TITLE_TEMPLATE:"titleTemplate",PRIORITIZE_SEO_TAGS:"prioritizeSeoTags"},_i=(e,t)=>{for(let n=e.length-1;n>=0;n-=1){const r=e[n];if(Object.prototype.hasOwnProperty.call(r,t))return r[t]}return null},UP=e=>{let t=_i(e,"title");const n=_i(e,xi.TITLE_TEMPLATE);if(Array.isArray(t)&&(t=t.join("")),n&&t)return n.replace(/%s/g,()=>t);const r=_i(e,xi.DEFAULT_TITLE);return t||r||void 0},BP=e=>_i(e,xi.ON_CHANGE_CLIENT_STATE)||(()=>{}),Ff=(e,t)=>
41t.filter(n=>typeof n[e]<"u").map(n=>n[e]).reduce((n,r)=>({...n,...r}),{}),zP=(e,t)=>t.filter(n=>typeof n.base<"u").map(n=>n.base).reverse().reduce((n,r)=>{if(!n.length){const s=Object.keys(r);for(let o=0;o<s.length;o+=1){const a=s[o].toLowerCase();if(e.indexOf(a)!==-1&&r[a])return n.concat(r)}}return n},[]),WP=e=>console&&typeof console.warn=="function"&&console.warn(e),Ca=(e,t,n)=>{const r={};return n.filter(s=>Array.isArray(s[e])?!0:(typeof s[e]<"u"&&WP(`Helmet: ${e} should be of type "Array". Instead found type "${typeof s[e]}"`),!1)).map(s=>s[e]).reverse().reduce((s,o)=>{const i={};o.filter(l=>{let c;const u=Object.keys(l);for(let p=0;p<u.length;p+=1){const h=u[p],x=h.toLowerCase();t.indexOf(x)!==-1&&!(c==="rel"&&l[c].toLowerCase()==="canonical")&&!(x==="rel"&&l[x].toLowerCase()==="stylesheet")&&(c=x),t.indexOf(h)!==-1&&(h==="innerHTML"||h==="cssText"||h==="itemprop")&&(c=h)}if(!c||!l[c])return!1;const d=l[c].toLowerCase();return r[c]||(r[c]={}),i[c]||(i[c]={}),r[c][d]?!1:(i[c][d]=!0,!0)}).reverse().forEach(l=>s.push(l));const a=Object.keys(i);for(let l=0;l<a.length;l+=1){const c=a[l],u={...r[c],...i[c]};r[c]=u}return s},[]).reverse()},HP=(e,t)=>{if(Array.isArray(e)&&e.length){for(let n=0;n<e.length;n+=1)if(e[n][t])return!0}return!1},VP=e=>({baseTag:zP(["href"],e),bodyAttributes:Ff("bodyAttributes",e),defer:_i(e,xi.DEFER),encode:_i(e,xi.ENCODE_SPECIAL_CHARACTERS),htmlAttributes:Ff("htmlAttributes",e),linkTags:Ca("link",["rel","href"],e),metaTags:Ca("meta",["name","charset","http-equiv","property","itemprop"],e),noscriptTags:Ca("noscript",["innerHTML"],e),onChangeClientState:BP(e),scriptTags:Ca("script",["src","innerHTML"],e),styleTags:Ca("style",["cssText"],e),title:UP(e),titleAttributes:Ff("titleAttributes",e),prioritizeSeoTags:HP(e,xi.PRIORITIZE_SEO_TAGS)}),T_=e=>Array.isArray(e)?e.join(""):e,qP=(e,t)=>{const n=Object.keys(e);for(let r=0;r<n.length;r+=1)if(t[n[r]]&&t[n[r]].includes(e[n[r]]))return!0;return!1},Uf=(e,t)=>Array.isArray(e)?e.reduce((n,r)=>(qP(r,t)?n.priority.push(r):n.default.push(r),n),{priority:[],default:[]}):{default:e,priority:[]},qy=(e,t)=>({...e,[t]:void 0}),KP=["noscript","script","style"],xp=(e,t=!0)=>t===!1?String(e):String(e).replace(/&/g,"&").replace(/</g,"<").replace(/>/g,">").replace(/"/g,""").replace(/'/g,"'"),R_=e=>Object.keys(e).reduce((t,n)=>{const r=typeof e[n]<"u"?`${n}="${e[n]}"`:`${n}`;return t?`${t} ${r}`:r},""),GP=(e,t,n,r)=>{const s=R_(n),o=T_(t);return s?`<${e} ${Hn}="true" ${s}>${xp(o,r)}</${e}>`:`<${e} ${Hn}="true">${xp(o,r)}</${e}>`},YP=(e,t,n=!0)=>t.reduce((r,s)=>{const o=s,i=Object.keys(o).filter(c=>!(c==="innerHTML"||c==="cssText")).reduce((c,u)=>{const d=typeof o[u]>"u"?u:`${u}="${xp(o[u],n)}"`;return c?`${c} ${d}`:d},""),a=o.innerHTML||o.cssText||"",l=KP.indexOf(e)===-1;return`${r}<${e} ${Hn}="true" ${i}${l?"/>":`>${a}</${e}>`}`},""),P_=(e,t={})=>Object.keys(e).reduce((n,r)=>{const s=kd[r];return n[s||r]=e[r],n},t),ZP=(e,t,n)=>{const r={key:t,[Hn]:!0},s=P_(n,r);return[O.createElement("title",s,t)]},su=(e,t)=>t.map((n,r)=>{const s={key:r,[Hn]:!0};return Object.keys(n).forEach(o=>{const a=kd[o]||o;if(a==="innerHTML"||a==="cssText"){const l=n.innerHTML||n.cssText;s.dangerouslySetInnerHTML={__html:l}}else s[a]=n[o]}),O.createElement(e,s)}),vn=(e,t,n=!0)=>{switch(e){case"title":return{toComponent:()=>ZP(e,t.title,t.titleAttributes),toString:()=>GP(e,t.title,t.titleAttributes,n)};case"bodyAttributes":case"htmlAttributes":return{toComponent:()=>P_(t),toString:()=>R_(t)};default:return{toComponent:()=>su(e,t),toString:()=>YP(e,t,n)}}},QP=({metaTags:e,linkTags:t,scriptTags:n,encode:r})=>{const s=Uf(e,$f.meta),o=Uf(t,$f.link),i=Uf(n,$f.script);return{priorityMethods:{toComponent:()=>[...su("meta",s.priority),...su("link",o.priority),...su("script",i.priority)],toString:()=>`${vn("meta",s.priority,r)} ${vn("link",o.priority,r)} ${vn("script",i.priority,r)}`},metaTags:s.default,linkTags:o.default,scriptTags:i.default}},JP=e=>{const{baseTag:t,bodyAttributes:n,encode:r=!0,htmlAttributes:s,noscriptTags:o,styleTags:i,title:a="",titleAttributes:l,prioritizeSeoTags:c}=e;let{linkTags:u,metaTags:d,scriptTags:p}=e,h={toComponent:()=>[],toString:()=>""};return c&&({priorityMethods:h,linkTags:u,metaTags:d,scriptTags:p}=QP(e)),{priority:h,base:vn("base",t,r),bodyAttributes:vn("bodyAttributes",n,r),htmlAttributes:vn("htmlAttributes",s,r),link:vn("link",u,r),meta:vn("meta",d,r),noscript:vn("noscript",o,r),script:vn("script",p,r),style:vn("style",i,r),title:vn("title",{title:a,titleAttributes:l},r)}},_p=JP,Cc=[],bg=!!(typeof window<"u"&&window.document&&window.document.createElement),Sp=class{constructor(e,t){Cr(this,"instances",[]);Cr(this,"canUseDOM",bg);Cr(this,"context");Cr(this,"value",{setHelmet:e=>{this.context.helmet=e},helmetInstances:{get:()=>this.canUseDOM?Cc:this.instances,add:e=>{(this.canUseDOM?Cc:this.instances).push(e)},remove:e=>{const t=(this.canUseDOM?Cc:this.instances).indexOf(e);(this.canUseDOM?Cc:this.instances).splice(t,1)}}});this.context=e,this.canUseDOM=t||!1,t||(e.helmet=_p({baseTag:[],bodyAttributes:{},encodeSpecialCharacters:!0,htmlAttributes:{},linkTags:[],metaTags:[],noscriptTags:[],scriptTags:[],styleTags:[],title:"",titleAttributes:{}}))}},XP=parseInt(O.version.split(".")[0],10),Ep=XP>=19,eN={},N_=O.createContext(eN),fo,A_=(fo=class extends m.Component{constructor(n){super(n);Cr(this,"helmetData");Ep?this.helmetData=null:this.helmetData=new Sp(this.props.context||{},fo.canUseDOM)}render(){return Ep?O.createElement(O.Fragment,null,this.props.children):O.createElement(N_.Provider,{value:this.helmetData.value},this.props.children)}},Cr(fo,"canUseDOM",bg),fo),Uo=(e,t)=>{const n=document.head||document.querySelector("head"),r=n.querySelectorAll(`${e}[${Hn}]`),s=[].slice.call(r),o=[];let i;return t&&t.length&&t.forEach(a=>{const l=document.createElement(e);for(const c in a)if(Object.prototype.hasOwnProperty.call(a,c))if(c==="innerHTML")l.innerHTML=a.innerHTML;else if(c==="cssText"){const u=a.cssText;l.appendChild(document.createTextNode(u))}else{const u=c,d=typeof a[u]>
41"u"?"":a[u];l.setAttribute(c,d)}l.setAttribute(Hn,"true"),s.some((c,u)=>(i=u,l.isEqualNode(c)))?s.splice(i,1):o.push(l)}),s.forEach(a=>{var l;return(l=a.parentNode)==null?void 0:l.removeChild(a)}),o.forEach(a=>n.appendChild(a)),{oldTags:s,newTags:o}},kp=(e,t)=>{const n=document.getElementsByTagName(e)[0];if(!n)return;const r=n.getAttribute(Hn),s=r?r.split(","):[],o=[...s],i=Object.keys(t);for(const a of i){const l=t[a]||"";n.getAttribute(a)!==l&&n.setAttribute(a,l),s.indexOf(a)===-1&&s.push(a);const c=o.indexOf(a);c!==-1&&o.splice(c,1)}for(let a=o.length-1;a>=0;a-=1)n.removeAttribute(o[a]);s.length===o.length?n.removeAttribute(Hn):n.getAttribute(Hn)!==i.join(",")&&n.setAttribute(Hn,i.join(","))},tN=(e,t)=>{typeof e<"u"&&document.title!==e&&(document.title=T_(e)),kp("title",t)},Ky=(e,t)=>{const{baseTag:n,bodyAttributes:r,htmlAttributes:s,linkTags:o,metaTags:i,noscriptTags:a,onChangeClientState:l,scriptTags:c,styleTags:u,title:d,titleAttributes:p}=e;kp("body",r),kp("html",s),tN(d,p);const h={baseTag:Uo("base",n),linkTags:Uo("link",o),metaTags:Uo("meta",i),noscriptTags:Uo("noscript",a),scriptTags:Uo("script",c),styleTags:Uo("style",u)},x={},v={};Object.keys(h).forEach(b=>{const{newTags:w,oldTags:g}=h[b];w.length&&(x[b]=w),g.length&&(v[b]=h[b].oldTags)}),t&&t(),l(e,x,v)},Ta=null,nN=e=>{Ta&&cancelAnimationFrame(Ta),e.defer?Ta=requestAnimationFrame(()=>{Ky(e,()=>{Ta=null})}):(Ky(e),Ta=null)},rN=nN,Gy=class extends m.Component{constructor(){super(...arguments);Cr(this,"rendered",!1)}shouldComponentUpdate(t){return!FP(t,this.props)}componentDidUpdate(){this.emitChange()}componentWillUnmount(){const{helmetInstances:t}=this.props.context;t.remove(this),this.emitChange()}emitChange(){const{helmetInstances:t,setHelmet:n}=this.props.context;let r=null;const s=VP(t.get().map(o=>{const{context:i,...a}=o.props;return a}));A_.canUseDOM?rN(s):_p&&(r=_p(s)),n(r)}init(){if(this.rendered)return;this.rendered=!0;const{helmetInstances:t}=this.props.context;t.add(this),this.emitChange()}render(){return this.init(),null}},ou=[],Yy=e=>{const t={};for(const n of Object.keys(e))t[C_[n]||n]=e[n];return t},Js=e=>{const t={};for(const n of Object.keys(e)){const r=kd[n];t[r||n]=e[n]}return t},Zy=(e,t)=>{if(!bg)return;const n=document.getElementsByTagName(e)[0];if(!n)return;const r="data-rh-managed",s=n.getAttribute(r),o=s?s.split(","):[],i=Object.keys(t);for(const a of o)i.includes(a)||n.removeAttribute(a);for(const a of i){const l=t[a];l==null||l===!1?n.removeAttribute(a):l===!0?n.setAttribute(a,""):n.setAttribute(a,String(l))}i.length>0?n.setAttribute(r,i.join(",")):n.removeAttribute(r)},Bf=()=>{const e={},t={};for(const n of ou){const{htmlAttributes:r,bodyAttributes:s}=n.props;r&&Object.assign(e,Yy(r)),s&&Object.assign(t,Yy(s))}Zy("html",e),Zy("body",t)},sN=class extends m.Component{componentDidMount(){ou.push(this),Bf()}componentDidUpdate(){Bf()}componentWillUnmount(){const e=ou.indexOf(this);e!==-1&&ou.splice(e,1),Bf()}resolveTitle(){const{title:e,titleTemplate:t,defaultTitle:n}=this.props;return e&&t?t.replace(/%s/g,()=>Array.isArray(e)?e.join(""):e):e||n||void 0}renderTitle(){const e=this.resolveTitle();if(e===void 0)return null;const t=this.props.titleAttributes||{};return O.createElement("title",Js(t),e)}renderBase(){const{base:e}=this.props;return e?O.createElement("base",Js(e)):null}renderMeta(){const{meta:e}=this.props;return!e||!Array.isArray(e)?null:e.map((t,n)=>O.createElement("meta",{key:n,...Js(t)}))}renderLink(){const{link:e}=this.props;return!e||!Array.isArray(e)?null:e.map((t,n)=>O.createElement("link",{key:n,...Js(t)}))}renderScript(){const{script:e}=this.props;return!e||!Array.isArray(e)?null:e.map((t,n)=>{const{innerHTML:r,...s}=t,o=Js(s);return r&&(o.dangerouslySetInnerHTML={__html:r}),O.createElement("script",{key:n,...o})})}renderStyle(){const{style:e}=this.props;return!e||!Array.isArray(e)?null:e.map((t,n)=>{const{cssText:r,...s}=t,o=Js(s);return r&&(o.dangerouslySetInnerHTML={__html:r}),O.createElement("style",{key:n,...o})})}renderNoscript(){const{noscript:e}=this.props;return!e||!Array.isArray(e)?null:e.map((t,n)=>{const{innerHTML:r,...s}=t,o=Js(s);return r&&(o.dangerouslySetInnerHTML={__html:r}),O.createElement("noscript",{key:n,...o})})}render(){return O.createElement(O.Fragment,null,this.renderTitle(),this.renderBase(),this.renderMeta(),this.renderLink(),this.renderScript(),this.renderStyle(),this.renderNoscript())}},Rh,oN=(Rh=class extends m.Component{shouldComponentUpdate(e){return!DP(qy(this.props,"helmetData"),qy(e,"helmetData"))}mapNestedChildrenToProps(e,t){if(!t)return null;switch(e.type){case"script":case"noscript":return{innerHTML:t};case"style":return{cssText:t};default:throw new Error(`<${e.type} /> elements are self-closing and can not contain children. Refer to our API for more information.`)}}flattenArrayTypeChildren(e,t,n,r){return{...t,[e.type]:[...t[e.type]||[],{...n,...this.mapNestedChildrenToProps(e,r)}]}}mapObjectTypeChildren(e,t,n,r){switch(e.type){case"title":return{...t,[e.type]:r,titleAttributes:{...n}};case"body":return{...t,bodyAttributes:{...n}};case"html":return{...t,htmlAttributes:{...n}};default:return{...t,[e.type]:{...n}}}}mapArrayTypeChildrenToProps(e,t){let n={...t};return Object.keys(e).forEach(r=>{n={...n,[r]:e[r]}}),n}
41warnOnInvalidChildren(e,t){return Hy(Vy.some(n=>e.type===n),typeof e.type=="function"?"You may be attempting to nest <Helmet> components within each other, which is not allowed. Refer to our API for more information.":`Only elements types ${Vy.join(", ")} are allowed. Helmet does not support rendering <${e.type}> elements. Refer to our API for more information.`),Hy(!t||typeof t=="string"||Array.isArray(t)&&!t.some(n=>typeof n!="string"),`Helmet expects a string as a child of <${e.type}>. Did you forget to wrap your children in braces? ( <${e.type}>{\`\`}</${e.type}> ) Refer to our API for more information.`),!0}mapChildrenToProps(e,t){let n={};return O.Children.forEach(e,r=>{if(!r||!r.props)return;const{children:s,...o}=r.props,i=Object.keys(o).reduce((l,c)=>(l[C_[c]||c]=o[c],l),{});let{type:a}=r;switch(typeof a=="symbol"?a=a.toString():this.warnOnInvalidChildren(r,s),a){case"Symbol(react.fragment)":t=this.mapChildrenToProps(s,t);break;case"link":case"meta":case"noscript":case"script":case"style":n=this.flattenArrayTypeChildren(r,n,i,s);break;default:t=this.mapObjectTypeChildren(r,t,i,s);break}}),this.mapArrayTypeChildrenToProps(n,t)}render(){const{children:e,...t}=this.props;let n={...t},{helmetData:r}=t;if(e&&(n=this.mapChildrenToProps(e,n)),r&&!(r instanceof Sp)){const s=r;r=new Sp(s.context,!0),delete n.helmetData}return Ep?O.createElement(sN,{...n}):r?O.createElement(Gy,{...n,context:r.value}):O.createElement(N_.Consumer,null,s=>O.createElement(Gy,{...n,context:s}))}},Cr(Rh,"defaultProps",{defer:!0,encodeSpecialCharacters:!0,prioritizeSeoTags:!1}),Rh);const iN="modulepreload",aN=function(e){return"/"+e},Qy={},zs=function(t,n,r){let s=Promise.resolve();if(n&&n.length>0){document.getElementsByTagName("link");const i=document.querySelector("meta[property=csp-nonce]"),a=(i==null?void 0:i.nonce)||(i==null?void 0:i.getAttribute("nonce"));s=Promise.allSettled(n.map(l=>{if(l=aN(l),l in Qy)return;Qy[l]=!0;const c=l.endsWith(".css"),u=c?'[rel="stylesheet"]':"";if(document.querySelector(`link[href="${l}"]${u}`))return;const d=document.createElement("link");if(d.rel=c?"stylesheet":iN,c||(d.as="script"),d.crossOrigin="",d.href=l,a&&d.setAttribute("nonce",a),document.head.appendChild(d),c)return new Promise((p,h)=>{d.addEventListener("load",p),d.addEventListener("error",()=>h(new Error(`Unable to preload CSS for ${l}`)))})}))}function o(i){const a=new Event("vite:preloadError",{cancelable:!0});if(a.payload=i,window.dispatchEvent(a),!a.defaultPrevented)throw i}return s.then(i=>{for(const a of i||[])a.status==="rejected"&&o(a.reason);return t().catch(o)})},lN=1,cN=1e6;let zf=0;function uN(){return zf=(zf+1)%Number.MAX_SAFE_INTEGER,zf.toString()}const Wf=new Map,Jy=e=>{if(Wf.has(e))return;const t=setTimeout(()=>{Wf.delete(e),sl({type:"REMOVE_TOAST",toastId:e})},cN);Wf.set(e,t)},dN=(e,t)=>{switch(t.type){case"ADD_TOAST":return{...e,toasts:[t.toast,...e.toasts].slice(0,lN)};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?Jy(n):e.toasts.forEach(r=>{Jy(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)}}},iu=[];let au={toasts:[]};function sl(e){au=dN(au,e),iu.forEach(t=>{t(au)})}function fN({...e}){const t=uN(),n=s=>sl({type:"UPDATE_TOAST",toast:{...s,id:t}}),r=()=>sl({type:"DISMISS_TOAST",toastId:t});return sl({type:"ADD_TOAST",toast:{...e,id:t,open:!0,onOpenChange:s=>{s||r()}}}),{id:t,dismiss:r,update:n}}function hN(){const[e,t]=m.useState(au);return m.useEffect(()=>(iu.push(t),()=>{const n=iu.indexOf(t);n>-1&&iu.splice(n,1)}),[e]),{...e,toast:fN,dismiss:n=>sl({type:"DISMISS_TOAST",toastId:n})}}function K(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 Xy(e,t){if(typeof e=="function")return e(t);e!=null&&(e.current=t)}function O_(...e){return t=>{let n=!1;const r=e.map(s=>{const o=Xy(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():Xy(e[s],null)}}}}function de(...e){return m.useCallback(O_(...e),e)}function pN(e,t){const n=m.createContext(t),r=o=>{const{children:i,...a}=o,l=m.useMemo(()=>a,Object.values(a));return f.jsx(n.Provider,{value:l,children:i})};r.displayName=e+"Provider";function s(o){const i=m.useContext(n);if(i)return i;if(t!==void 0)return t;throw new Error(`\`${o}\` must be used within \`${e}\``)}return[r,s]}function Gt(e,t=[]){let n=[];function r(o,i){const a=m.createContext(i),l=n.length;n=[...n,i];const c=d=>{var w;const{scope:p,children:h,...x}=d,v=((w=p==null?void 0:p[e])==null?void 0:w[l])||a,b=m.useMemo(()=>x,Object.values(x));return f.jsx(v.Provider,{value:b,children:h})};c.displayName=o+"Provider";function u(d,p){var v;const h=((v=p==null?void 0:p[e])==null?void 0:v[l])||a,x=m.useContext(h);if(x)return x;if(i!==void 0)return i;throw new Error(`\`${d}\` must be used within \`${o}\``)}return[c,u]}const s=()=>{const o=n.map(i=>m.createContext(i));return function(a){const l=(a==null?void 0:a[e])||o;return m.useMemo(()=>({[`__scope${e}`]:{...a,[e]:l}}),[a,l])}};return s.scopeName=e,[r,mN(s,...t)]}function mN(...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 i=r.reduce((a,{useScope:l,scopeName:c}
vendor: 10,632 bytes, line 41
41)=>{const d=l(o)[`__scope${c}`];return{...a,...d}},{});return m.useMemo(()=>({[`__scope${t.scopeName}`]:i}),[i])}};return n.scopeName=t.scopeName,n}function zi(e){const t=vN(e),n=m.forwardRef((r,s)=>{const{children:o,...i}=r,a=m.Children.toArray(o),l=a.find(wN);if(l){const c=l.props.children,u=a.map(d=>d===l?m.Children.count(c)>1?m.Children.only(null):m.isValidElement(c)?c.props.children:null:d);return f.jsx(t,{...i,ref:s,children:m.isValidElement(c)?m.cloneElement(c,void 0,u):null})}return f.jsx(t,{...i,ref:s,children:o})});return n.displayName=`${e}.Slot`,n}var gN=zi("Slot");function vN(e){const t=m.forwardRef((n,r)=>{const{children:s,...o}=n;if(m.isValidElement(s)){const i=xN(s),a=bN(o,s.props);return s.type!==m.Fragment&&(a.ref=r?O_(r,i):i),m.cloneElement(s,a)}return m.Children.count(s)>1?m.Children.only(null):null});return t.displayName=`${e}.SlotClone`,t}var j_=Symbol("radix.slottable");function yN(e){const t=({children:n})=>f.jsx(f.Fragment,{children:n});return t.displayName=`${e}.Slottable`,t.__radixId=j_,t}function wN(e){return m.isValidElement(e)&&typeof e.type=="function"&&"__radixId"in e.type&&e.type.__radixId===j_}function bN(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]=(...a)=>{const l=o(...a);return s(...a),l}:s&&(n[r]=s):r==="style"?n[r]={...s,...o}:r==="className"&&(n[r]=[s,o].filter(Boolean).join(" "))}return{...e,...n}}function xN(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 Zl(e){const t=e+"CollectionProvider",[n,r]=Gt(t),[s,o]=n(t,{collectionRef:{current:null},itemMap:new Map}),i=v=>{const{scope:b,children:w}=v,g=O.useRef(null),y=O.useRef(new Map).current;return f.jsx(s,{scope:b,itemMap:y,collectionRef:g,children:w})};i.displayName=t;const a=e+"CollectionSlot",l=zi(a),c=O.forwardRef((v,b)=>{const{scope:w,children:g}=v,y=o(a,w),_=de(b,y.collectionRef);return f.jsx(l,{ref:_,children:g})});c.displayName=a;const u=e+"CollectionItemSlot",d="data-radix-collection-item",p=zi(u),h=O.forwardRef((v,b)=>{const{scope:w,children:g,...y}=v,_=O.useRef(null),S=de(b,_),k=o(u,w);return O.useEffect(()=>(k.itemMap.set(_,{ref:_,...y}),()=>void k.itemMap.delete(_))),f.jsx(p,{[d]:"",ref:S,children:g})});h.displayName=u;function x(v){const b=o(e+"CollectionConsumer",v);return O.useCallback(()=>{const g=b.collectionRef.current;if(!g)return[];const y=Array.from(g.querySelectorAll(`[${d}]`));return Array.from(b.itemMap.values()).sort((k,E)=>y.indexOf(k.ref.current)-y.indexOf(E.ref.current))},[b.collectionRef,b.itemMap])}return[{Provider:i,Slot:c,ItemSlot:h},x,r]}var _N=["a","button","div","form","h2","h3","img","input","label","li","nav","ol","p","select","span","svg","ul"],ne=_N.reduce((e,t)=>{const n=zi(`Primitive.${t}`),r=m.forwardRef((s,o)=>{const{asChild:i,...a}=s,l=i?n:t;return typeof window<"u"&&(window[Symbol.for("radix-ui")]=!0),f.jsx(l,{...a,ref:o})});return r.displayName=`Primitive.${t}`,{...e,[t]:r}},{});function I_(e,t){e&&Io.flushSync(()=>e.dispatchEvent(t))}function st(e){const t=m.useRef(e);return m.useEffect(()=>{t.current=e}),m.useMemo(()=>(...n)=>{var r;return(r=t.current)==null?void 0:r.call(t,...n)},[])}function SN(e,t=globalThis==null?void 0:globalThis.document){const n=st(e);m.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 EN="DismissableLayer",Cp="dismissableLayer.update",kN="dismissableLayer.pointerDownOutside",CN="dismissableLayer.focusOutside",ew,D_=m.createContext({layers:new Set,layersWithOutsidePointerEventsDisabled:new Set,branches:new Set}),Ql=m.forwardRef((e,t)=>{const{disableOutsidePointerEvents:n=!1,onEscapeKeyDown:r,onPointerDownOutside:s,onFocusOutside:o,onInteractOutside:i,onDismiss:a,...l}=e,c=m.useContext(D_),[u,d]=m.useState(null),p=(u==null?void 0:u.ownerDocument)??(globalThis==null?void 0:globalThis.document),[,h]=m.useState({}),x=de(t,E=>d(E)),v=Array.from(c.layers),[b]=[...c.layersWithOutsidePointerEventsDisabled].slice(-1),w=v.indexOf(b),g=u?v.indexOf(u):-1,y=c.layersWithOutsidePointerEventsDisabled.size>0,_=g>=w,S=RN(E=>{const R=E.target,P=[...c.branches].some(A=>A.contains(R));!_||P||(s==null||s(E),i==null||i(E),E.defaultPrevented||a==null||a())},p),k=PN(E=>{const R=E.target;[...c.branches].some(A=>A.contains(R))||(o==null||o(E),i==null||i(E),E.defaultPrevented||a==null||a())},p);return SN(E=>{g===c.layers.size-1&&(r==null||r(E),!E.defaultPrevented&&a&&(E.preventDefault(),a()))},p),m.useEffect(()=>{if(u)return n&&(c.layersWithOutsidePointerEventsDisabled.size===0&&(ew=p.body.style.pointerEvents,p.body.style.pointerEvents="none"),c.layersWithOutsidePointerEventsDisabled.add(u)),c.layers.add(u),tw(),()=>{n&&c.layersWithOutsidePointerEventsDisabled.size===1&&(p.body.style.pointerEvents=ew)}},[u,p,n,c]),m.useEffect(()=>()=>{u&&(c.layers.delete(u),c.layersWithOutsidePointerEventsDisabled.delete(u),tw())},[u,c]),m.useEffect(()=>{const E=()=>h({});return document.addEventListener(Cp,E),()=>document.removeEventListener(Cp,E)},[]),f.jsx(ne.div,{...l,ref:x,style:{pointerEvents:y?_?"auto":"none":void 0,...e.style},onFocusCapture:K(e.onFocusCapture,k.onFocusCapture),onBlurCapture:K(e.onBlurCapture,k.onBlurCapture),onPointerDownCapture:K(e.onPointerDownCapture,S.onPointerDownCapture)})});Ql.displayName=EN;var TN="DismissableLayerBranch",M_=m.forwardRef((e,t)=>{const n=m.useContext(D_),r=m.useRef(null),s=de(t,r);return m.useEffect(()=>{const o=r.current;if(o)return n.branches.add(o),()=>{n.branches.delete(o)}},[n.branches]),f.jsx(ne.div,{...e,ref:s})});M_.displayName=TN;function RN(e,t=globalThis==null?void 0:globalThis.document){const n=st(e),r=m.useRef(!1),s=m.useRef(()=>{});return m.useEffect(()=>{const o=a=>{if(a.target&&!r.current){let l=function(){L_(kN,n,c,{discrete:!0})};const c={originalEvent:a};a.pointerType==="touch"?(t.removeEventListener("click",s.current),s.current=l,t.addEventListener("click",s.current,{once:!0})):l()}else t.removeEventListener("click",s.current);r.current=!1},i=window.setTimeout(()=>{t.addEventListener("pointerdown",o)},0);return()=>{window.clearTimeout(i),t.removeEventListener("pointerdown",o),t.removeEventListener("click",s.current)}},[t,n]),{onPointerDownCapture:()=>r.current=!0}}function PN(e,t=globalThis==null?void 0:globalThis.document){const n=st(e),r=m.useRef(!1);return m.useEffect(()=>{const s=o=>{o.target&&!r.current&&L_(CN,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 tw(){const e=new CustomEvent(Cp);document.dispatchEvent(e)}function L_(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?I_(s,o):s.dispatchEvent(o)}var NN=Ql,AN=M_,it=globalThis!=null&&globalThis.document?m.useLayoutEffect:()=>{},ON="Portal",Cd=m.forwardRef((e,t)=>{var a;const{container:n,...r}=e,[s,o]=m.useState(!1);it(()=>o(!0),[]);const i=n||s&&((a=globalThis==null?void 0:globalThis.document)==null?void 0:a.body);return i?S_.createPortal(f.jsx(ne.div,{...r,ref:t}),i):null});Cd.displayName=ON;function jN(e,t){return m.useReducer((n,r)=>t[n][r]??n,e)}var dn=e=>{const{present:t,children:n}=e,r=IN(t),s=typeof n=="function"?n({present:r.isPresent}):m.Children.only(n),o=de(r.ref,DN(s));return typeof n=="function"||r.isPresent?m.cloneElement(s,{ref:o}):null};dn.displayName="Presence";function IN(e){const[t,n]=m.useState(),r=m.useRef(null),s=m.useRef(e),o=m.useRef("none"),i=e?"mounted":"unmounted",[a,l]=jN(i,{mounted:{UNMOUNT:"unmounted",ANIMATION_OUT:"unmountSuspended"},unmountSuspended:{MOUNT:"mounted",ANIMATION_END:"unmounted"},unmounted:{MOUNT:"mounted"}});return m.useEffect(()=>{const c=Tc(r.current);o.current=a==="mounted"?c:"none"},[a]),it(()=>{const c=r.current,u=s.current;if(u!==e){const p=o.current,h=Tc(c);e?l("MOUNT"):h==="none"||(c==null?void 0:c.display)==="none"?l("UNMOUNT"):l(u&&p!==h?"ANIMATION_OUT":"UNMOUNT"),s.current=e}},[e,l]),it(()=>{if(t){let c;const u=t.ownerDocument.defaultView??window,d=h=>{const v=Tc(r.current).includes(h.animationName);if(h.target===t&&v&&(l("ANIMATION_END"),!s.current)){const b=t.style.animationFillMode;t.style.animationFillMode="forwards",c=u.setTimeout(()=>{t.style.animationFillMode==="forwards"&&(t.style.animationFillMode=b)})}},p=h=>{h.target===t&&(o.current=Tc(r.current))};return t.addEventListener("animationstart",p),t.addEventListener("animationcancel",d),t.addEventListener("animationend",d),()=>{u.clearTimeout(c),t.removeEventListener("animationstart",p),t.removeEventListener("animationcancel",d),t.removeEventListener("animationend",d)}}else l("ANIMATION_END")},[t,l]),{isPresent:["mounted","unmountSuspended"].includes(a),ref:m.useCallback(c=>{r.current=c?getComputedStyle(c):null,n(c)},[])}}function Tc(e){return(e==null?void 0:e.animationName)||"none"}function DN(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 MN=Pm[" useInsertionEffect ".trim().toString()]||it;function Gn({prop:e,defaultProp:t,onChange:n=()=>{},caller:r}){const[s,o,i]=LN({defaultProp:t,onChange:n}),a=e!==void 0,l=a?e:s;{const u=m.useRef(e!==void 0);m.useEffect(()=>{const d=u.current;d!==a&&console.warn(`${r} is changing from ${d?"controlled":"uncontrolled"} to ${a?"controlled":"uncontrolled"}. Components should not switch from controlled to uncontrolled (or vice versa). Decide between using a controlled or uncontrolled value for the lifetime of the component.`),u.current=a},[a,r])}const c=m.useCallback(u=>{var d;if(a){const p=$N(u)?u(e):u;p!==e&&((d=i.current)==null||d.call(i,p))}else o(u)},[a,e,o,i]);return[l,c]}function LN({defaultProp:e,onChange:t}){const[n,r]=m.useState(e),s=m.useRef(n),o=m.useRef(t);return MN(()=>{o.current=t},[t]),m.useEffect(()=>{var i;s.current!==n&&((i=o.current)==null||i.call(o,n),s.current=n)},[n,s]),[n,r,o]}function $N(e){return typeof e=="function"}var $_=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"}),FN="VisuallyHidden",Td=m.forwardRef((e,t)=>
41f.jsx(ne.span,{...e,ref:t,style:{...$_,...e.style}}));Td.displayName=FN;var UN=Td,xg="ToastProvider",[_g,BN,zN]=Zl("Toast"),[F_,xz]=Gt("Toast",[zN]),[WN,Rd]=F_(xg),U_=e=>{const{__scopeToast:t,label:n="Notification",duration:r=5e3,swipeDirection:s="right",swipeThreshold:o=50,children:i}=e,[a,l]=m.useState(null),[c,u]=m.useState(0),d=m.useRef(!1),p=m.useRef(!1);return n.trim()||console.error(`Invalid prop \`label\` supplied to \`${xg}\`. Expected non-empty \`string\`.`),f.jsx(_g.Provider,{scope:t,children:f.jsx(WN,{scope:t,label:n,duration:r,swipeDirection:s,swipeThreshold:o,toastCount:c,viewport:a,onViewportChange:l,onToastAdd:m.useCallback(()=>u(h=>h+1),[]),onToastRemove:m.useCallback(()=>u(h=>h-1),[]),isFocusedToastEscapeKeyDownRef:d,isClosePausedRef:p,children:i})})};U_.displayName=xg;var B_="ToastViewport",HN=["F8"],Tp="toast.viewportPause",Rp="toast.viewportResume",z_=m.forwardRef((e,t)=>{const{__scopeToast:n,hotkey:r=HN,label:s="Notifications ({hotkey})",...o}=e,i=Rd(B_,n),a=BN(n),l=m.useRef(null),c=m.useRef(null),u=m.useRef(null),d=m.useRef(null),p=de(t,d,i.onViewportChange),h=r.join("+").replace(/Key/g,"").replace(/Digit/g,""),x=i.toastCount>0;m.useEffect(()=>{const b=w=>{var y;r.length!==0&&r.every(_=>w[_]||w.code===_)&&((y=d.current)==null||y.focus())};return document.addEventListener("keydown",b),()=>document.removeEventListener("keydown",b)},[r]),m.useEffect(()=>{const b=l.current,w=d.current;if(x&&b&&w){const g=()=>{if(!i.isClosePausedRef.current){const k=new CustomEvent(Tp);w.dispatchEvent(k),i.isClosePausedRef.current=!0}},y=()=>{if(i.isClosePausedRef.current){const k=new CustomEvent(Rp);w.dispatchEvent(k),i.isClosePausedRef.current=!1}},_=k=>{!b.contains(k.relatedTarget)&&y()},S=()=>{b.contains(document.activeElement)||y()};return b.addEventListener("focusin",g),b.addEventListener("focusout",_),b.addEventListener("pointermove",g),b.addEventListener("pointerleave",S),window.addEventListener("blur",g),window.addEventListener("focus",y),()=>{b.removeEventListener("focusin",g),b.removeEventListener("focusout",_),b.removeEventListener("pointermove",g),b.removeEventListener("pointerleave",S),window.removeEventListener("blur",g),window.removeEventListener("focus",y)}}},[x,i.isClosePausedRef]);const v=m.useCallback(({tabbingDirection:b})=>{const g=a().map(y=>{const _=y.ref.current,S=[_,...rA(_)];return b==="forwards"?S:S.reverse()});return(b==="forwards"?g.reverse():g).flat()},[a]);return m.useEffect(()=>{const b=d.current;if(b){const w=g=>{var S,k,E;const y=g.altKey||g.ctrlKey||g.metaKey;if(g.key==="Tab"&&!y){const R=document.activeElement,P=g.shiftKey;if(g.target===b&&P){(S=c.current)==null||S.focus();return}const M=v({tabbingDirection:P?"backwards":"forwards"}),H=M.findIndex(L=>L===R);Hf(M.slice(H+1))?g.preventDefault():P?(k=c.current)==null||k.focus():(E=u.current)==null||E.focus()}};return b.addEventListener("keydown",w),()=>b.removeEventListener("keydown",w)}},[a,v]),f.jsxs(AN,{ref:l,role:"region","aria-label":s.replace("{hotkey}",h),tabIndex:-1,style:{pointerEvents:x?void 0:"none"},children:[x&&f.jsx(Pp,{ref:c,onFocusFromOutsideViewport:()=>{const b=v({tabbingDirection:"forwards"});Hf(b)}}),f.jsx(_g.Slot,{scope:n,children:f.jsx(ne.ol,{tabIndex:-1,...o,ref:p})}),x&&f.jsx(Pp,{ref:u,onFocusFromOutsideViewport:()=>{const b=v({tabbingDirection:"backwards"});Hf(b)}})]})});z_.displayName=B_;var W_="ToastFocusProxy",Pp=m.forwardRef((e,t)=>{const{__scopeToast:n,onFocusFromOutsideViewport:r,...s}=e,o=Rd(W_,n);return f.jsx(Td,{"aria-hidden":!0,tabIndex:0,...s,ref:t,style:{position:"fixed"},onFocus:i=>{var c;const a=i.relatedTarget;!((c=o.viewport)!=null&&c.contains(a))&&r()}})});Pp.displayName=W_;var Jl="Toast",VN="toast.swipeStart",qN="toast.swipeMove",KN="toast.swipeCancel",GN="toast.swipeEnd",H_=m.forwardRef((e,t)=>{const{forceMount:n,open:r,defaultOpen:s,onOpenChange:o,...i}=e,[a,l]=Gn({prop:r,defaultProp:s??!0,onChange:o,caller:Jl});return f.jsx(dn,{present:n||a,children:f.jsx(QN,{open:a,...i,ref:t,onClose:()=>l(!1),onPause:st(e.onPause),onResume:st(e.onResume),onSwipeStart:K(e.onSwipeStart,c=>{c.currentTarget.setAttribute("data-swipe","start")}),onSwipeMove:K(e.onSwipeMove,c=>{const{x:u,y:d}=c.detail.delta;c.currentTarget.setAttribute("data-swipe","move"),c.currentTarget.style.setProperty("--radix-toast-swipe-move-x",`${u}px`),c.currentTarget.style.setProperty("--radix-toast-swipe-move-y",`${d}px`)}),onSwipeCancel:K(e.onSwipeCancel,c=>{c.currentTarget.setAttribute("data-swipe","cancel"),c.currentTarget.style.removeProperty("--radix-toast-swipe-move-x"),c.currentTarget.style.removeProperty("--radix-toast-swipe-move-y"),c.currentTarget.style.removeProperty("--radix-toast-swipe-end-x"),c.currentTarget.style.removeProperty("--radix-toast-swipe-end-y")}),onSwipeEnd:K(e.onSwipeEnd,c=>{const{x:u,y:d}=c.detail.delta;c.currentTarget.setAttribute("data-swipe","end"),c.currentTarget.style.removeProperty("--radix-toast-swipe-move-x"),c.currentTarget.style.removeProperty("--radix-toast-swipe-move-y"),c.currentTarget.style.setProperty("--radix-toast-swipe-end-x",`${u}px`),c.currentTarget.style.setProperty("--radix-toast-swipe-end-y",`${d}px`),l(!1)})})})});H_.displayName=Jl;var[YN,ZN]=F_(Jl,{onClose(){}}),QN=m.forwardRef((e,t)=>
41{const{__scopeToast:n,type:r="foreground",duration:s,open:o,onClose:i,onEscapeKeyDown:a,onPause:l,onResume:c,onSwipeStart:u,onSwipeMove:d,onSwipeCancel:p,onSwipeEnd:h,...x}=e,v=Rd(Jl,n),[b,w]=m.useState(null),g=de(t,L=>w(L)),y=m.useRef(null),_=m.useRef(null),S=s||v.duration,k=m.useRef(0),E=m.useRef(S),R=m.useRef(0),{onToastAdd:P,onToastRemove:A}=v,D=st(()=>{var Z;(b==null?void 0:b.contains(document.activeElement))&&((Z=v.viewport)==null||Z.focus()),i()}),M=m.useCallback(L=>{!L||L===1/0||(window.clearTimeout(R.current),k.current=new Date().getTime(),R.current=window.setTimeout(D,L))},[D]);m.useEffect(()=>{const L=v.viewport;if(L){const Z=()=>{M(E.current),c==null||c()},B=()=>{const I=new Date().getTime()-k.current;E.current=E.current-I,window.clearTimeout(R.current),l==null||l()};return L.addEventListener(Tp,B),L.addEventListener(Rp,Z),()=>{L.removeEventListener(Tp,B),L.removeEventListener(Rp,Z)}}},[v.viewport,S,l,c,M]),m.useEffect(()=>{o&&!v.isClosePausedRef.current&&M(S)},[o,S,v.isClosePausedRef,M]),m.useEffect(()=>(P(),()=>A()),[P,A]);const H=m.useMemo(()=>b?Q_(b):null,[b]);return v.viewport?f.jsxs(f.Fragment,{children:[H&&f.jsx(JN,{__scopeToast:n,role:"status","aria-live":r==="foreground"?"assertive":"polite","aria-atomic":!0,children:H}),f.jsx(YN,{scope:n,onClose:D,children:Io.createPortal(f.jsx(_g.ItemSlot,{scope:n,children:f.jsx(NN,{asChild:!0,onEscapeKeyDown:K(a,()=>{v.isFocusedToastEscapeKeyDownRef.current||D(),v.isFocusedToastEscapeKeyDownRef.current=!1}),children:f.jsx(ne.li,{role:"status","aria-live":"off","aria-atomic":!0,tabIndex:0,"data-state":o?"open":"closed","data-swipe-direction":v.swipeDirection,...x,ref:g,style:{userSelect:"none",touchAction:"none",...e.style},onKeyDown:K(e.onKeyDown,L=>{L.key==="Escape"&&(a==null||a(L.nativeEvent),L.nativeEvent.defaultPrevented||(v.isFocusedToastEscapeKeyDownRef.current=!0,D()))}),onPointerDown:K(e.onPointerDown,L=>{L.button===0&&(y.current={x:L.clientX,y:L.clientY})}),onPointerMove:K(e.onPointerMove,L=>{if(!y.current)return;const Z=L.clientX-y.current.x,B=L.clientY-y.current.y,I=!!_.current,T=["left","right"].includes(v.swipeDirection),N=["left","up"].includes(v.swipeDirection)?Math.min:Math.max,z=T?N(0,Z):0,V=T?0:N(0,B),X=L.pointerType==="touch"?10:2,ee={x:z,y:V},ce={originalEvent:L,delta:ee};I?(_.current=ee,Rc(qN,d,ce,{discrete:!1})):nw(ee,v.swipeDirection,X)?(_.current=ee,Rc(VN,u,ce,{discrete:!1}),L.target.setPointerCapture(L.pointerId)):(Math.abs(Z)>X||Math.abs(B)>X)&&(y.current=null)}),onPointerUp:K(e.onPointerUp,L=>{const Z=_.current,B=L.target;if(B.hasPointerCapture(L.pointerId)&&B.releasePointerCapture(L.pointerId),_.current=null,y.current=null,Z){const I=L.currentTarget,T={originalEvent:L,delta:Z};nw(Z,v.swipeDirection,v.swipeThreshold)?Rc(GN,h,T,{discrete:!0}):Rc(KN,p,T,{discrete:!0}),I.addEventListener("click",N=>N.preventDefault(),{once:!0})}})})})}),v.viewport)})]}):null}),JN=e=>{const{__scopeToast:t,children:n,...r}=e,s=Rd(Jl,t),[o,i]=m.useState(!1),[a,l]=m.useState(!1);return tA(()=>i(!0)),m.useEffect(()=>{const c=window.setTimeout(()=>l(!0),1e3);return()=>window.clearTimeout(c)},[]),a?null:f.jsx(Cd,{asChild:!0,children:f.jsx(Td,{...r,children:o&&f.jsxs(f.Fragment,{children:[s.label," ",n]})})})},XN="ToastTitle",V_=m.forwardRef((e,t)=>{const{__scopeToast:n,...r}=e;return f.jsx(ne.div,{...r,ref:t})});V_.displayName=XN;var eA="ToastDescription",q_=m.forwardRef((e,t)=>{const{__scopeToast:n,...r}=e;return f.jsx(ne.div,{...r,ref:t})});q_.displayName=eA;var K_="ToastAction",G_=m.forwardRef((e,t)=>{const{altText:n,...r}=e;return n.trim()?f.jsx(Z_,{altText:n,asChild:!0,children:f.jsx(Sg,{...r,ref:t})}):(console.error(`Invalid prop \`altText\` supplied to \`${K_}\`. Expected non-empty \`string\`.`),null)});G_.displayName=K_;var Y_="ToastClose",Sg=m.forwardRef((e,t)=>{const{__scopeToast:n,...r}=e,s=ZN(Y_,n);return f.jsx(Z_,{asChild:!0,children:f.jsx(ne.button,{type:"button",...r,ref:t,onClick:K(e.onClick,s.onClose)})})});Sg.displayName=Y_;var Z_=m.forwardRef((e,t)=>{const{__scopeToast:n,altText:r,...s}=e;return f.jsx(ne.div,{"data-radix-toast-announce-exclude":"","data-radix-toast-announce-alt":r||void 0,...s,ref:t})});function Q_(e){const t=[];
vendor: 4,454 bytes, lines 41-66
41return Array.from(e.childNodes).forEach(r=>{if(r.nodeType===r.TEXT_NODE&&r.textContent&&t.push(r.textContent),nA(r)){const s=r.ariaHidden||r.hidden||r.style.display==="none",o=r.dataset.radixToastAnnounceExclude==="";if(!s)if(o){const i=r.dataset.radixToastAnnounceAlt;i&&t.push(i)}else t.push(...Q_(r))}}),t}function Rc(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?I_(s,o):s.dispatchEvent(o)}var nw=(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 tA(e=()=>{}){const t=st(e);it(()=>{let n=0,r=0;return n=window.requestAnimationFrame(()=>r=window.requestAnimationFrame(t)),()=>{window.cancelAnimationFrame(n),window.cancelAnimationFrame(r)}},[t])}function nA(e){return e.nodeType===e.ELEMENT_NODE}function rA(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 Hf(e){const t=document.activeElement;return e.some(n=>n===t?!0:(n.focus(),document.activeElement!==t))}var sA=U_,J_=z_,X_=H_,eS=V_,tS=q_,nS=G_,rS=Sg;function sS(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=sS(e[t]))&&(r&&(r+=" "),r+=n)}else for(n in e)e[n]&&(r&&(r+=" "),r+=n);return r}function oS(){for(var e,t,n=0,r="",s=arguments.length;n<s;n++)(e=arguments[n])&&(t=sS(e))&&(r&&(r+=" "),r+=t);return r}const rw=e=>typeof e=="boolean"?`${e}`:e===0?"0":e,sw=oS,Eg=(e,t)=>n=>{var r;if((t==null?void 0:t.variants)==null)return sw(e,n==null?void 0:n.class,n==null?void 0:n.className);const{variants:s,defaultVariants:o}=t,i=Object.keys(s).map(c=>{const u=n==null?void 0:n[c],d=o==null?void 0:o[c];if(u===null)return null;const p=rw(u)||rw(d);return s[c][p]}),a=n&&Object.entries(n).reduce((c,u)=>{let[d,p]=u;return p===void 0||(c[d]=p),c},{}),l=t==null||(r=t.compoundVariants)===null||r===void 0?void 0:r.reduce((c,u)=>{let{class:d,className:p,...h}=u;return Object.entries(h).every(x=>{let[v,b]=x;return Array.isArray(b)?b.includes({...o,...a}[v]):{...o,...a}[v]===b})?[...c,d,p]:c},[]);return sw(e,i,l,n==null?void 0:n.class,n==null?void 0:n.className)};/** 42 * @license lucide-react v0.462.0 - ISC 43 * 44 * This source code is licensed under the ISC license. 45 * See the LICENSE file in the root directory of this source tree. 46 */const oA=e=>e.replace(/([a-z0-9])([A-Z])/g,"$1-$2").toLowerCase(),iS=(...e)=>e.filter((t,n,r)=>!!t&&t.trim()!==""&&r.indexOf(t)===n).join(" ").trim();/** 47 * @license lucide-react v0.462.0 - ISC 48 * 49 * This source code is licensed under the ISC license. 50 * See the LICENSE file in the root directory of this source tree. 51 */var iA={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"};/** 52 * @license lucide-react v0.462.0 - ISC 53 * 54 * This source code is licensed under the ISC license. 55 * See the LICENSE file in the root directory of this source tree. 56 */const aA=m.forwardRef(({color:e="currentColor",size:t=24,strokeWidth:n=2,absoluteStrokeWidth:r,className:s="",children:o,iconNode:i,...a},l)=>m.createElement("svg",{ref:l,...iA,width:t,height:t,stroke:e,strokeWidth:r?Number(n)*24/Number(t):n,className:iS("lucide",s),...a},[...i.map(([c,u])=>m.createElement(c,u)),...Array.isArray(o)?o:[o]]));/** 57 * @license lucide-react v0.462.0 - ISC 58 * 59 * This source code is licensed under the ISC license. 60 * See the LICENSE file in the root directory of this source tree. 61 */const at=(e,t)=>{const n=m.forwardRef(({className:r,...s},o)=>m.createElement(aA,{ref:o,iconNode:t,className:iS(`lucide-${oA(e)}`,r),...s}));return n.displayName=`${e}`,n};/** 62 * @license lucide-react v0.462.0 - ISC 63 * 64 * This source code is licensed under the ISC license. 65 * See the LICENSE file in the root directory of this source tree. 66 */const ow=at("Building2",[["path",{d:"M6 22V4a2 2 0 0 1 2-2h8a2 2 0 0 1 2 2v18Z",key:"1b4qmf"}],["path",{d:"M6 12H4a2 2 0 0 0-2 2v6a2 2 0 0 0 2 2h2",key:"i71pzd"}],["path",{d:"M18 9h2a2 2 0 0 1 2 2v9a2 2 0 0 1-2 2h-2",key:"10jefs"}],["path",{d:"M10 6h4",key:"1itunk"}],["path",{d:"M10 10h4",key:"tcdvrf"}
66],["path",{d:"M10 14h4",key:"kelpxr"}],["path",{d:"M10 18h4",key:"1ulq68"}]]);/** 67 * @license lucide-react v0.462.0 - ISC 68 * 69 * This source code is licensed under the ISC license. 70 * See the LICENSE file in the root directory of this source tree. 71 */const lA=at("Calculator",[["rect",{width:"16",height:"20",x:"4",y:"2",rx:"2",key:"1nb95v"}],["line",{x1:"8",x2:"16",y1:"6",y2:"6",key:"x4nwl0"}],["line",{x1:"16",x2:"16",y1:"14",y2:"18",key:"wjye3r"}],["path",{d:"M16 10h.01",key:"1m94wz"}],["path",{d:"M12 10h.01",key:"1nrarc"}],["path",{d:"M8 10h.01",key:"19clt8"}],["path",{d:"M12 14h.01",key:"1etili"}],["path",{d:"M8 14h.01",key:"6423bh"}],["path",{d:"M12 18h.01",key:"mhygvu"}],["path",{d:"M8 18h.01",key:"lrp35t"}]]);/** 72 * @license lucide-react v0.462.0 - ISC 73 * 74 * This source code is licensed under the ISC license. 75 * See the LICENSE file in the root directory of this source tree. 76 */const aS=at("Check",[["path",{d:"M20 6 9 17l-5-5",key:"1gmf2c"}]]);/** 77 * @license lucide-react v0.462.0 - ISC 78 * 79 * This source code is licensed under the ISC license. 80 * See the LICENSE file in the root directory of this source tree. 81 */const Pd=at("ChevronDown",[["path",{d:"m6 9 6 6 6-6",key:"qrunsl"}]]);/** 82 * @license lucide-react v0.462.0 - ISC 83 * 84 * This source code is licensed under the ISC license. 85 * See the LICENSE file in the root directory of this source tree. 86 */const Nd=at("ChevronLeft",[["path",{d:"m15 18-6-6 6-6",key:"1wnfg3"}]]);/** 87 * @license lucide-react v0.462.0 - ISC 88 * 89 * This source code is licensed under the ISC license. 90 * See the LICENSE file in the root directory of this source tree. 91 */const Ad=at("ChevronRight",[["path",{d:"m9 18 6-6-6-6",key:"mthhwq"}]]);/** 92 * @license lucide-react v0.462.0 - ISC 93 * 94 * This source code is licensed under the ISC license. 95 * See the LICENSE file in the root directory of this source tree. 96 */const cA=at("ChevronUp",[["path",{d:"m18 15-6-6-6 6",key:"153udz"}]]);/** 97 * @license lucide-react v0.462.0 - ISC 98 * 99 * This source code is licensed under the ISC license. 100 * See the LICENSE file in the root directory of this source tree. 101 */const uA=at("Circle",[["circle",{cx:"12",cy:"12",r:"10",key:"1mglay"}]]);/** 102 * @license lucide-react v0.462.0 - ISC 103 * 104 * This source code is licensed under the ISC license. 105 * See the LICENSE file in the root directory of this source tree. 106 */const dA=at("Clock",[["circle",{cx:"12",cy:"12",r:"10",key:"1mglay"}],["polyline",{points:"12 6 12 12 16 14",key:"68esgv"}]]);/** 107 * @license lucide-react v0.462.0 - ISC 108 * 109 * This source code is licensed under the ISC license. 110 * See the LICENSE file in the root directory of this source tree. 111 */const fA=at("FileCheck",[["path",{d:"M15 2H6a2 2 0 0 0-2 2v16a2 2 0 0 0 2 2h12a2 2 0 0 0 2-2V7Z",key:"1rqfz7"}],["path",{d:"M14 2v4a2 2 0 0 0 2 2h4",key:"tnqrlb"}],["path",{d:"m9 15 2 2 4-4",key:"1grp1n"}]]);/** 112 * @license lucide-react v0.462.0 - ISC 113 * 114 * This source code is licensed under the ISC license. 115 * See the LICENSE file in the root directory of this source tree. 116 */const hA=at("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"}]]);/** 117 * @license lucide-react v0.462.0 - ISC 118 * 119 * This source code is licensed under the ISC license. 120 * See the LICENSE file in the root directory of this source tree. 121 */const pA=at("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"}]]);/** 122 * @license lucide-react v0.462.0 - ISC 123 * 124 * This source code is licensed under the ISC license. 125 * See the LICENSE file in the root directory of this source tree. 126 */const mA=at("Menu",[["line",{x1:"4",x2:"20",y1:"12",y2:"12",key:"1e0a9i"}],["line",{x1:"4",x2:"20",y1:"6",y2:"6",key:"1owob3"}],["line",{x1:"4",x2:"20",y1:"18",y2:"18",key:"yk5zj1"}]]);/** 127 * @license lucide-react v0.462.0 - ISC 128 * 129 * This source code is licensed under the ISC license. 130 * See the LICENSE file in the root directory of this source tree. 131 */const gA=at("MessageCircle",[["path",{d:"M7.9 20A9 9 0 1 0 4 16.1L2 22Z",key:"vv11sd"}]]);/** 132 * @license lucide-react v0.462.0 - ISC 133 * 134 * This source code is licensed under the ISC license. 135 * See the LICENSE file in the root directory of this source tree. 136 */const Np=at("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"}]]);/** 137 * @license lucide-react v0.462.0 - ISC 138 * 139 * This source code is licensed under the ISC license. 140 * See the LICENSE file in the root directory of this source tree. 141 */const vA=at("Scale",[["path",{d:"m16 16 3-8 3 8c-.87.65-1.92 1-3 1s-2.13-.35-3-1Z",key:"7g6ntu"}],["path",{d:"m2 16 3-8 3 8c-.87.65-1.92 1-3 1s-2.13-.35-3-1Z",key:"ijws7r"}],["path",{d:"M7 21h10",key:"1b0cd5"}],["path",{d:"M12 3v18",key:"108xh3"}
vendor: 8,525 bytes, lines 141-156
141],["path",{d:"M3 7h2c2 0 5-1 7-2 2 1 5 2 7 2h2",key:"3gwbw2"}]]);/** 142 * @license lucide-react v0.462.0 - ISC 143 * 144 * This source code is licensed under the ISC license. 145 * See the LICENSE file in the root directory of this source tree. 146 */const yA=at("ShieldCheck",[["path",{d:"M20 13c0 5-3.5 7.5-7.66 8.95a1 1 0 0 1-.67-.01C7.5 20.5 4 18 4 13V6a1 1 0 0 1 1-1c2 0 4.5-1.2 6.24-2.72a1.17 1.17 0 0 1 1.52 0C14.51 3.81 17 5 19 5a1 1 0 0 1 1 1z",key:"oel41y"}],["path",{d:"m9 12 2 2 4-4",key:"dzmm74"}]]);/** 147 * @license lucide-react v0.462.0 - ISC 148 * 149 * This source code is licensed under the ISC license. 150 * See the LICENSE file in the root directory of this source tree. 151 */const $u=at("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"}]]);/** 152 * @license lucide-react v0.462.0 - ISC 153 * 154 * This source code is licensed under the ISC license. 155 * See the LICENSE file in the root directory of this source tree. 156 */const Od=at("X",[["path",{d:"M18 6 6 18",key:"1bl5f8"}],["path",{d:"m6 6 12 12",key:"d8bk6v"}]]),kg="-",wA=e=>{const t=xA(e),{conflictingClassGroups:n,conflictingClassGroupModifiers:r}=e;return{getClassGroupId:i=>{const a=i.split(kg);return a[0]===""&&a.length!==1&&a.shift(),lS(a,t)||bA(i)},getConflictingClassGroupIds:(i,a)=>{const l=n[i]||[];return a&&r[i]?[...l,...r[i]]:l}}},lS=(e,t)=>{var i;if(e.length===0)return t.classGroupId;const n=e[0],r=t.nextPart.get(n),s=r?lS(e.slice(1),r):void 0;if(s)return s;if(t.validators.length===0)return;const o=e.join(kg);return(i=t.validators.find(({validator:a})=>a(o)))==null?void 0:i.classGroupId},iw=/^\[(.+)\]$/,bA=e=>{if(iw.test(e)){const t=iw.exec(e)[1],n=t==null?void 0:t.substring(0,t.indexOf(":"));if(n)return"arbitrary.."+n}},xA=e=>{const{theme:t,prefix:n}=e,r={nextPart:new Map,validators:[]};return SA(Object.entries(e.classGroups),n).forEach(([o,i])=>{Ap(i,r,o,t)}),r},Ap=(e,t,n,r)=>{e.forEach(s=>{if(typeof s=="string"){const o=s===""?t:aw(t,s);o.classGroupId=n;return}if(typeof s=="function"){if(_A(s)){Ap(s(r),t,n,r);return}t.validators.push({validator:s,classGroupId:n});return}Object.entries(s).forEach(([o,i])=>{Ap(i,aw(t,o),n,r)})})},aw=(e,t)=>{let n=e;return t.split(kg).forEach(r=>{n.nextPart.has(r)||n.nextPart.set(r,{nextPart:new Map,validators:[]}),n=n.nextPart.get(r)}),n},_A=e=>e.isThemeGetter,SA=(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(([i,a])=>[t+i,a])):o);return[n,s]}):e,EA=e=>{if(e<1)return{get:()=>{},set:()=>{}};let t=0,n=new Map,r=new Map;const s=(o,i)=>{n.set(o,i),t++,t>e&&(t=0,r=n,n=new Map)};return{get(o){let i=n.get(o);if(i!==void 0)return i;if((i=r.get(o))!==void 0)return s(o,i),i},set(o,i){n.has(o)?n.set(o,i):s(o,i)}}},cS="!",kA=e=>{const{separator:t,experimentalParseClassName:n}=e,r=t.length===1,s=t[0],o=t.length,i=a=>{const l=[];let c=0,u=0,d;for(let b=0;b<a.length;b++){let w=a[b];if(c===0){if(w===s&&(r||a.slice(b,b+o)===t)){l.push(a.slice(u,b)),u=b+o;continue}if(w==="/"){d=b;continue}}w==="["?c++:w==="]"&&c--}const p=l.length===0?a:a.substring(u),h=p.startsWith(cS),x=h?p.substring(1):p,v=d&&d>u?d-u:void 0;return{modifiers:l,hasImportantModifier:h,baseClassName:x,maybePostfixModifierPosition:v}};return n?a=>n({className:a,parseClassName:i}):i},CA=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},TA=e=>({cache:EA(e.cacheSize),parseClassName:kA(e),...wA(e)}),RA=/\s+/,PA=(e,t)=>{const{parseClassName:n,getClassGroupId:r,getConflictingClassGroupIds:s}=t,o=[],i=e.trim().split(RA);let a="";for(let l=i.length-1;l>=0;l-=1){const c=i[l],{modifiers:u,hasImportantModifier:d,baseClassName:p,maybePostfixModifierPosition:h}=n(c);let x=!!h,v=r(x?p.substring(0,h):p);if(!v){if(!x){a=c+(a.length>0?" "+a:a);continue}if(v=r(p),!v){a=c+(a.length>0?" "+a:a);continue}x=!1}const b=CA(u).join(":"),w=d?b+cS:b,g=w+v;if(o.includes(g))continue;o.push(g);const y=s(v,x);for(let _=0;_<y.length;++_){const S=y[_];o.push(w+S)}a=c+(a.length>0?" "+a:a)}return a};function NA(){let e=0,t,n,r="";for(;e<arguments.length;)(t=arguments[e++])&&(n=uS(t))&&(r&&(r+=" "),r+=n);return r}const uS=e=>{if(typeof e=="string")return e;let t,n="";for(let r=0;r<e.length;r++)e[r]&&(t=uS(e[r]))&&(n&&(n+=" "),n+=t);return n};function AA(e,...t){let n,r,s,o=i;function i(l){const c=t.reduce((u,d)=>d(u),e());return n=TA(c),r=n.cache.get,s=n.cache.set,o=a,a(l)}function a(l){const c=r(l);if(c)return c;const u=PA(l,n);return s(l,u),u}return function(){return o(NA.apply(null,arguments))}}const Le=e=>{const t=n=>n[e]||[];return t.isThemeGetter=!0,t},dS=/^\[(?:([a-z-]+):)?(.+)\]$/i,OA=/^\d+\/\d+$/,jA=new Set(["px","full","screen"]),IA=/^(\d+(\.\d+)?)?(xs|sm|md|lg|xl)$/,DA=/\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$/,MA=/^(rgba?|hsla?|hwb|(ok)?(lab|lch))\(.+\)$/,LA=/^(inset_)?-?((\d+)?\.?(\d+)[a-z]+|0)_-?((\d+)?\.?(\d+)[a-z]+|0)/,$A=/^(url|image|image-set|cross-fade|element|(repeating-)?(linear|radial|conic)-gradient)\(.+\)$/,Tr=e=>Si(e)||jA.has(e)||OA.test(e),es=e=>ea(e,"length",qA),Si=e=>!!e&&!Number.isNaN(Number(e)),Vf=e=>ea(e,"number",Si),Ra=e=>!!e&&Number.isInteger(Number(e)),FA=e=>e.endsWith("%")&&Si(e.slice(0,-1)),ge=e=>dS.test(e),ts=e=>IA.test(e),UA=new Set(["length","size","percentage"]),BA=e=>ea(e,UA,fS),zA=e=>ea(e,"position",fS),WA=new Set(["image","url"]),HA=e=>ea(e,WA,GA),VA=e=>ea(e,"",KA),Pa=()=>!0,ea=(e,t,n)=>{const r=dS.exec(e);return r?r[1]?typeof t=="string"?r[1]===t:t.has(r[1]):n(r[2]):!1},qA=e=>DA.test(e)&&!MA.test(e),fS=()=>!1,KA=e=>LA.test(e),GA=e=>$A.test(e),YA=()=>{const e=Le("colors"),t=Le("spacing"),n=Le("blur"),r=Le("brightness"),s=Le("borderColor"),o=Le("borderRadius"),i=Le("borderSpacing"),a=Le("borderWidth"),l=Le("contrast"),c=Le("grayscale"),u=Le("hueRotate"),d=Le("invert"),p=Le("gap"),h=Le("gradientColorStops"),x=Le("gradientColorStopPositions"),v=Le("inset"),b=Le("margin"),w=Le("opacity"),g=Le("padding"),y=Le("saturate"),_=Le("scale"),S=Le("sepia"),k=Le("skew"),E=Le("space"),R=Le("translate"),P=()=>["auto","contain","none"],A=()=>["auto","hidden","clip","visible","scroll"],D=()=>["auto",ge,t],M=()=>[ge,t],H=()=>["",Tr,es],L=()=>["auto",Si,ge],Z=()=>["bottom","center","left","left-bottom","left-top","right","right-bottom","right-top","top"],B=()=>["solid","dashed","dotted","double","none"],I=()=>["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"],N=()=>["","0",ge],z=()=>["auto","avoid","all","avoid-page","page","left","right","column"],V=()=>[Si,ge];return{cacheSize:500,separator:":",theme:{colors:[Pa],spacing:[Tr,es],blur:["none","",ts,ge],brightness:V(),borderColor:[e],borderRadius:["none","","full",ts,ge],borderSpacing:M(),borderWidth:H(),contrast:V(),grayscale:N(),hueRotate:V(),invert:N(),gap:M(),gradientColorStops:[e],gradientColorStopPositions:[FA,es],inset:D(),margin:D(),opacity:V(),padding:M(),saturate:V(),scale:V(),sepia:N(),skew:V(),space:M(),translate:M()},classGroups:{aspect:[{aspect:["auto","square","video",ge]}],container:["container"],columns:[{columns:[ts]}],"break-after":[{"break-after":z()}],"break-before":[{"break-before":z()}],"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:[...Z(),ge]}],overflow:[{overflow:A()}],"overflow-x":[{"overflow-x":A()}],"overflow-y":[{"overflow-y":A()}],overscroll:[{overscroll:P()}],"overscroll-x":[{"overscroll-x":P()}],"overscroll-y":[{"overscroll-y":P()}],position:["static","fixed","absolute","relative","sticky"],inset:[{inset:[v]}],"inset-x":[{"inset-x":[v]}],"inset-y":[{"inset-y":[v]}],start:[{start:[v]}],end:[{end:[v]}],top:[{top:[v]}
vendor: 9,947 bytes, line 156
156],right:[{right:[v]}],bottom:[{bottom:[v]}],left:[{left:[v]}],visibility:["visible","invisible","collapse"],z:[{z:["auto",Ra,ge]}],basis:[{basis:D()}],"flex-direction":[{flex:["row","row-reverse","col","col-reverse"]}],"flex-wrap":[{flex:["wrap","wrap-reverse","nowrap"]}],flex:[{flex:["1","auto","initial","none",ge]}],grow:[{grow:N()}],shrink:[{shrink:N()}],order:[{order:["first","last","none",Ra,ge]}],"grid-cols":[{"grid-cols":[Pa]}],"col-start-end":[{col:["auto",{span:["full",Ra,ge]},ge]}],"col-start":[{"col-start":L()}],"col-end":[{"col-end":L()}],"grid-rows":[{"grid-rows":[Pa]}],"row-start-end":[{row:["auto",{span:[Ra,ge]},ge]}],"row-start":[{"row-start":L()}],"row-end":[{"row-end":L()}],"grid-flow":[{"grid-flow":["row","col","dense","row-dense","col-dense"]}],"auto-cols":[{"auto-cols":["auto","min","max","fr",ge]}],"auto-rows":[{"auto-rows":["auto","min","max","fr",ge]}],gap:[{gap:[p]}],"gap-x":[{"gap-x":[p]}],"gap-y":[{"gap-y":[p]}],"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:[b]}],mx:[{mx:[b]}],my:[{my:[b]}],ms:[{ms:[b]}],me:[{me:[b]}],mt:[{mt:[b]}],mr:[{mr:[b]}],mb:[{mb:[b]}],ml:[{ml:[b]}],"space-x":[{"space-x":[E]}],"space-x-reverse":["space-x-reverse"],"space-y":[{"space-y":[E]}],"space-y-reverse":["space-y-reverse"],w:[{w:["auto","min","max","fit","svw","lvw","dvw",ge,t]}],"min-w":[{"min-w":[ge,t,"min","max","fit"]}],"max-w":[{"max-w":[ge,t,"none","full","min","max","fit","prose",{screen:[ts]},ts]}],h:[{h:[ge,t,"auto","min","max","fit","svh","lvh","dvh"]}],"min-h":[{"min-h":[ge,t,"min","max","fit","svh","lvh","dvh"]}],"max-h":[{"max-h":[ge,t,"min","max","fit","svh","lvh","dvh"]}],size:[{size:[ge,t,"auto","min","max","fit"]}],"font-size":[{text:["base",ts,es]}],"font-smoothing":["antialiased","subpixel-antialiased"],"font-style":["italic","not-italic"],"font-weight":[{font:["thin","extralight","light","normal","medium","semibold","bold","extrabold","black",Vf]}],"font-family":[{font:[Pa]}],"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",ge]}],"line-clamp":[{"line-clamp":["none",Si,Vf]}],leading:[{leading:["none","tight","snug","normal","relaxed","loose",Tr,ge]}],"list-image":[{"list-image":["none",ge]}],"list-style-type":[{list:["none","disc","decimal",ge]}],"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",Tr,es]}],"underline-offset":[{"underline-offset":["auto",Tr,ge]}],"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",ge]}],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",ge]}],"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:[...Z(),zA]}],"bg-repeat":[{bg:["no-repeat",{repeat:["","x","y","round","space"]}]}],"bg-size":[{bg:["auto","cover","contain",BA]}],"bg-image":[{bg:["none",{"gradient-to":["t","tr","r","br","b","bl","l","tl"]},HA]}],"bg-color":[{bg:[e]}],"gradient-from-pos":[{from:[x]}],"gradient-via-pos":[{via:[x]}],"gradient-to-pos":[{to:[x]}],"gradient-from":[{from:[h]}],"gradient-via":[{via:[h]}],"gradient-to":[{to:[h]}],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:[a]}],"border-w-x":[{"border-x":[a]}],"border-w-y":[{"border-y":[a]}],"border-w-s":[{"border-s":[a]}],"border-w-e":[{"border-e":[a]}],"border-w-t":[{"border-t":[a]}],"border-w-r":[{"border-r":[a]}],"border-w-b":[{"border-b":[a]}],"border-w-l":[{"border-l":[a]}],"border-opacity":[{"border-opacity":[w]}],"border-style":[{border:[...B(),"hidden"]}],"divide-x":[{"divide-x":[a]}],"divide-x-reverse":["divide-x-reverse"],"divide-y":[{"divide-y":[a]}],"divide-y-reverse":["divide-y-reverse"],"divide-opacity":[{"divide-opacity":[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":[Tr,ge]}],"outline-w":[{outline:[Tr,es]}],"outline-color":[{outline:[e]}],"ring-w":[{ring:H()}],"ring-w-inset":["ring-inset"],"ring-color":[{ring:[e]}],"ring-opacity":[{"ring-opacity":[w]}],"ring-offset-w":[{"ring-offset":[Tr,es]}],"ring-offset-color":[{"ring-offset":[e]}],shadow:[{shadow:["","inner","none",ts,VA]}],"shadow-color":[{shadow:[Pa]}],opacity:[{opacity:[w]}],"mix-blend":[{"mix-blend":[...I(),"plus-lighter","plus-darker"]}],"bg-blend":[{"bg-blend":I()}],filter:[{filter:["","none"]}],blur:[{blur:[n]}],brightness:[{brightness:[r]}],contrast:[{contrast:[l]}],"drop-shadow":[{"drop-shadow":["","none",ts,ge]}],grayscale:[{grayscale:[c]}],"hue-rotate":[{"hue-rotate":[u]}],invert:[{invert:[d]}],saturate:[{saturate:[y]}],sepia:[{sepia:[S]}],"backdrop-filter":[{"backdrop-filter":["","none"]}],"backdrop-blur":[{"backdrop-blur":[n]}],"backdrop-brightness":[{"backdrop-brightness":[r]}],"backdrop-contrast":[{"backdrop-contrast":[l]}],"backdrop-grayscale":[{"backdrop-grayscale":[c]}],"backdrop-hue-rotate":[{"backdrop-hue-rotate":[u]}],"backdrop-invert":[{"backdrop-invert":[d]}],"backdrop-opacity":[{"backdrop-opacity":[w]}],"backdrop-saturate":[{"backdrop-saturate":[y]}],"backdrop-sepia":[{"backdrop-sepia":[S]}],"border-collapse":[{border:["collapse","separate"]}],"border-spacing":[{"border-spacing":[i]}],"border-spacing-x":[{"border-spacing-x":[i]}],"border-spacing-y":[{"border-spacing-y":[i]}],"table-layout":[{table:["auto","fixed"]}],caption:[{caption:["top","bottom"]}],transition:[{transition:["none","all","","colors","opacity","shadow","transform",ge]}],duration:[{duration:V()}],ease:[{ease:["linear","in","out","in-out",ge]}],delay:[{delay:V()}],animate:[{animate:["none","spin","ping","pulse","bounce",ge]}],transform:[{transform:["","gpu","none"]}],scale:[{scale:[_]}],"scale-x":[{"scale-x":[_]}],"scale-y":[{"scale-y":[_]}],rotate:[{rotate:[Ra,ge]}],"translate-x":[{"translate-x":[R]}],"translate-y":[{"translate-y":[R]}],"skew-x":[{"skew-x":[k]}],"skew-y":[{"skew-y":[k]}],"transform-origin":[{origin:["center","top","top-right","right","bottom-right","bottom","bottom-left","left","top-left",ge]}],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",ge]}],"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,488 bytes, line 156
156],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",ge]}],fill:[{fill:[e,"none"]}],"stroke-w":[{stroke:[Tr,es,Vf]}],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"]}}},ZA=AA(YA);function me(...e){return ZA(oS(e))}const QA=sA,hS=m.forwardRef(({className:e,...t},n)=>f.jsx(J_,{ref:n,className:me("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}));hS.displayName=J_.displayName;const JA=Eg("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"}}),pS=m.forwardRef(({className:e,variant:t,...n},r)=>f.jsx(X_,{ref:r,className:me(JA({variant:t}),e),...n}));pS.displayName=X_.displayName;const XA=m.forwardRef(({className:e,...t},n)=>f.jsx(nS,{ref:n,className:me("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}));
156XA.displayName=nS.displayName;const mS=m.forwardRef(({className:e,...t},n)=>f.jsx(rS,{ref:n,className:me("absolute right-2 top-2 rounded-md p-1 text-foreground/50 opacity-0 transition-opacity group-hover:opacity-100 group-[.destructive]:text-red-300 hover:text-foreground group-[.destructive]:hover:text-red-50 focus:opacity-100 focus:outline-none focus:ring-2 group-[.destructive]:focus:ring-red-400 group-[.destructive]:focus:ring-offset-red-600",e),"toast-close":"",...t,children:f.jsx(Od,{className:"h-4 w-4"})}));mS.displayName=rS.displayName;const gS=m.forwardRef(({className:e,...t},n)=>f.jsx(eS,{ref:n,className:me("text-sm font-semibold",e),...t}));gS.displayName=eS.displayName;const vS=m.forwardRef(({className:e,...t},n)=>f.jsx(tS,{ref:n,className:me("text-sm opacity-90",e),...t}));vS.displayName=tS.displayName;function eO(){const{toasts:e}=hN();return f.jsxs(QA,{children:[e.map(function({id:t,title:n,description:r,action:s,...o}){return f.jsxs(pS,{...o,children:[f.jsxs("div",{className:"grid gap-1",children:[n&&f.jsx(gS,{children:n}),r&&f.jsx(vS,{children:r})]}),s,f.jsx(mS,{})]},t)}),f.jsx(hS,{})]})}var lw=["light","dark"],tO="(prefers-color-scheme: dark)",nO=m.createContext(void 0),rO={setTheme:e=>{},themes:[]},sO=()=>{var e;return(e=m.useContext(nO))!=null?e:rO};m.memo(({forcedTheme:e,storageKey:t,attribute:n,enableSystem:r,enableColorScheme:s,defaultTheme:o,value:i,attrs:a,nonce:l})=>{let c=o==="system",u=n==="class"?`var d=document.documentElement,c=d.classList;${`c.remove(${a.map(x=>`'${x}'`).join(",")})`};`:`var d=document.documentElement,n='${n}',s='setAttribute';`,d=s?lw.includes(o)&&o?`if(e==='light'||e==='dark'||!e)d.style.colorScheme=e||'${o}'`:"if(e==='light'||e==='dark')d.style.colorScheme=e":"",p=(x,v=!1,b=!0)=>{let w=i?i[x]:x,g=v?x+"|| ''":`'${w}'`,y="";return s&&b&&!v&&lw.includes(x)&&(y+=`d.style.colorScheme = '${x}';
156`),n==="class"?v||w?y+=`c.add(${g})`:y+="null":w&&(y+=`d[s](n,${g})`),y},h=e?`!function(){${u}${p(e)}}()`:r?`!function(){try{${u}var e=localStorage.getItem('${t}');if('system'===e||(!e&&${c})){var t='${tO}',m=window.matchMedia(t);if(m.media!==t||m.matches){${p("dark")}}else{${p("light")}}}else if(e){${i?`var x=${JSON.stringify(i)};`:""}${p(i?"x[e]":"e",!0)}}${c?"":"else{"+p(o,!1,!1)+"}"}${d}}catch(e){}}()`:`!function(){try{${u}var e=localStorage.getItem('${t}');if(e){${i?`var x=${JSON.stringify(i)};`:""}${p(i?"x[e]":"e",!0)}}else{${p(o,!1,!1)};}${d}}catch(t){}}();`;return m.createElement("script",{nonce:l,dangerouslySetInnerHTML:{__html:h}})});var oO=e=>{switch(e){case"success":return lO;case"info":return uO;case"warning":return cO;case"error":return dO;default:return null}},iO=Array(12).fill(0),aO=({visible:e,className:t})=>O.createElement("div",{className:["sonner-loading-wrapper",t].filter(Boolean).join(" "),"data-visible":e},O.createElement("div",{className:"sonner-spinner"},iO.map((n,r)=>O.createElement("div",{className:"sonner-loading-bar",key:`spinner-bar-${r}`})))),lO=O.createElement("svg",{xmlns:"http://www.w3.org/2000/svg",viewBox:"0 0 20 20",fill:"currentColor",height:"20",width:"20"},O.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"})),cO=O.createElement("svg",{xmlns:"http://www.w3.org/2000/svg",viewBox:"0 0 24 24",fill:"currentColor",height:"20",width:"20"},O.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"})),uO=O.createElement("svg",{xmlns:"http://www.w3.org/2000/svg",viewBox:"0 0 20 20",fill:"currentColor",height:"20",width:"20"},O.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"})),dO=O.createElement("svg",{xmlns:"http://www.w3.org/2000/svg",viewBox:"0 0 20 20",fill:"currentColor",height:"20",width:"20"},O.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"})),fO=O.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"},O.createElement("line",{x1:"18",y1:"6",x2:"6",y2:"18"}),O.createElement("line",{x1:"6",y1:"6",x2:"18",y2:"18"})),hO=()=>{let[e,t]=O.useState(document.hidden);return O.useEffect(()=>{let n=()=>{t(document.hidden)};return document.addEventListener("visibilitychange",n),()=>window.removeEventListener("visibilitychange",n)},[]),e},Op=1,pO=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:Op++,o=this.toasts.find(a=>a.id===s),i=e.dismissible===void 0?!0:e.dismissible;return this.dismissedToasts.has(s)&&this.dismissedToasts.delete(s),o?this.toasts=this.toasts.map(a=>a.id===s?(this.publish({...a,...e,id:s,title:n}),{...a,...e,id:s,dismissible:i,title:n}):a):this.addToast({title:n,...r,dismissible:i,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)=>
156this.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)=>this.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,i=r.then(async l=>{if(o=["resolve",l],O.isValidElement(l))s=!1,this.create({id:n,type:"default",message:l});else if(gO(l)&&!l.ok){s=!1;let c=typeof t.error=="function"?await t.error(`HTTP error! status: ${l.status}`):t.error,u=typeof t.description=="function"?await t.description(`HTTP error! status: ${l.status}`):t.description;this.create({id:n,type:"error",message:c,description:u})}else if(t.success!==void 0){s=!1;let c=typeof t.success=="function"?await t.success(l):t.success,u=typeof t.description=="function"?await t.description(l):t.description;this.create({id:n,type:"success",message:c,description:u})}}).catch(async l=>{if(o=["reject",l],t.error!==void 0){s=!1;let c=typeof t.error=="function"?await t.error(l):t.error,u=typeof t.description=="function"?await t.description(l):t.description;this.create({id:n,type:"error",message:c,description:u})}}).finally(()=>{var l;s&&(this.dismiss(n),n=void 0),(l=t.finally)==null||l.call(t)}),a=()=>new Promise((l,c)=>i.then(()=>o[0]==="reject"?c(o[1]):l(o[1])).catch(c));return typeof n!="string"&&typeof n!="number"?{unwrap:a}:Object.assign(n,{unwrap:a})},this.custom=(e,t)=>{let n=(t==null?void 0:t.id)||Op++;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}},Ut=new pO,mO=(e,t)=>{let n=(t==null?void 0:t.id)||Op++;return Ut.addToast({title:e,...t,id:n}),n},gO=e=>e&&typeof e=="object"&&"ok"in e&&typeof e.ok=="boolean"&&"status"in e&&typeof e.status=="number",vO=mO,yO=()=>Ut.toasts,wO=()=>Ut.getActiveToasts(),Rr=Object.assign(vO,{success:Ut.success,info:Ut.info,warning:Ut.warning,error:Ut.error,custom:Ut.custom,message:Ut.message,promise:Ut.promise,dismiss:Ut.dismiss,loading:Ut.loading},{getHistory:yO,getToasts:wO});function bO(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))}bO(`: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;
156left: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}
156: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%);
156--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%)} 157`);function Pc(e){return e.label!==void 0}var xO=3,_O="32px",SO="16px",cw=4e3,EO=356,kO=14,CO=20,TO=200;function On(...e){return e.filter(Boolean).join(" ")}function RO(e){let[t,n]=e.split("-"),r=[];return t&&r.push(t),n&&r.push(n),r}var PO=e=>{var t,n,r,s,o,i,a,l,c,u,d;let{invert:p,toast:h,unstyled:x,interacting:v,setHeights:b,visibleToasts:w,heights:g,index:y,toasts:_,expanded:S,removeToast:k,defaultRichColors:E,closeButton:R,style:P,cancelButtonStyle:A,actionButtonStyle:D,className:M="",descriptionClassName:H="",duration:L,position:Z,gap:B,loadingIcon:I,expandByDefault:T,classNames:N,icons:z,closeButtonAriaLabel:V="Close toast",pauseWhenPageIsHidden:X}=e,[ee,ce]=O.useState(null),[le,Oe]=O.useState(null),[W,xe]=O.useState(!1),[Me,_e]=O.useState(!1),[we,Se]=O.useState(!1),[ze,ut]=O.useState(!1),[kt,fn]=O.useState(!1),[Rn,hn]=O.useState(0),[Pn,Ks]=O.useState(0),Qr=O.useRef(h.duration||L||cw),ua=O.useRef(null),Sr=O.useRef(null),da=y===0,Gs=y+1<=w,tt=h.type,dt=h.dismissible!==!1,fa=h.className||"",ic=h.descriptionClassName||"",Ys=O.useMemo(()=>g.findIndex(ue=>ue.toastId===h.id)||0,[g,h.id]),ha=O.useMemo(()=>{var ue;return(ue=h.closeButton)!=null?ue:R},[h.closeButton,R]),pa=O.useMemo(()=>h.duration||L||cw,[h.duration,L]),Jr=O.useRef(0),Nn=O.useRef(0),pn=O.useRef(0),Yt=O.useRef(null),[ma,ga]=Z.split("-"),ac=O.useMemo(()=>g.reduce((ue,ie,Pe)=>Pe>=Ys?ue:ue+ie.height,0),[g,Ys]),Zs=hO(),Lo=h.invert||p,va=tt==="loading";Nn.current=O.useMemo(()=>Ys*B+ac,[Ys,ac]),O.useEffect(()=>{Qr.current=pa},[pa]),O.useEffect(()=>{xe(!0)},[]),O.useEffect(()=>{let ue=Sr.current;if(ue){let ie=ue.getBoundingClientRect().height;return Ks(ie),b(Pe=>[{toastId:h.id,height:ie,position:h.position},...Pe]),()=>b(Pe=>Pe.filter(Zt=>Zt.toastId!==h.id))}},[b,h.id]),O.useLayoutEffect(()=>{if(!W)return;let ue=Sr.current,ie=ue.style.height;ue.style.height="auto";let Pe=ue.getBoundingClientRect().height;ue.style.height=ie,Ks(Pe),b(Zt=>Zt.find(Lt=>Lt.toastId===h.id)?Zt.map(Lt=>Lt.toastId===h.id?{...Lt,height:Pe}:Lt):[{toastId:h.id,height:Pe,position:h.position},...Zt])},[W,h.title,h.description,b,h.id]);let Mt=O.useCallback(()=>{_e(!0),hn(Nn.current),b(ue=>ue.filter(ie=>ie.toastId!==h.id)),setTimeout(()=>{k(h)},TO)},[h,k,b,Nn]);O.useEffect(()=>{if(h.promise&&tt==="loading"||h.duration===1/0||h.type==="loading")return;let ue;return S||v||X&&Zs?(()=>{if(pn.current<Jr.current){let ie=new Date().getTime()-Jr.current;Qr.current=Qr.current-ie}
157pn.current=new Date().getTime()})():Qr.current!==1/0&&(Jr.current=new Date().getTime(),ue=setTimeout(()=>{var ie;(ie=h.onAutoClose)==null||ie.call(h,h),Mt()},Qr.current)),()=>clearTimeout(ue)},[S,v,h,tt,X,Zs,Mt]),O.useEffect(()=>{h.delete&&Mt()},[Mt,h.delete]);function lf(){var ue,ie,Pe;return z!=null&&z.loading?O.createElement("div",{className:On(N==null?void 0:N.loader,(ue=h==null?void 0:h.classNames)==null?void 0:ue.loader,"sonner-loader"),"data-visible":tt==="loading"},z.loading):I?O.createElement("div",{className:On(N==null?void 0:N.loader,(ie=h==null?void 0:h.classNames)==null?void 0:ie.loader,"sonner-loader"),"data-visible":tt==="loading"},I):O.createElement(aO,{className:On(N==null?void 0:N.loader,(Pe=h==null?void 0:h.classNames)==null?void 0:Pe.loader),visible:tt==="loading"})}return O.createElement("li",{tabIndex:0,ref:Sr,className:On(M,fa,N==null?void 0:N.toast,(t=h==null?void 0:h.classNames)==null?void 0:t.toast,N==null?void 0:N.default,N==null?void 0:N[tt],(n=h==null?void 0:h.classNames)==null?void 0:n[tt]),"data-sonner-toast":"","data-rich-colors":(r=h.richColors)!=null?r:E,"data-styled":!(h.jsx||h.unstyled||x),"data-mounted":W,"data-promise":!!h.promise,"data-swiped":kt,"data-removed":Me,"data-visible":Gs,"data-y-position":ma,"data-x-position":ga,"data-index":y,"data-front":da,"data-swiping":we,"data-dismissible":dt,"data-type":tt,"data-invert":Lo,"data-swipe-out":ze,"data-swipe-direction":le,"data-expanded":!!(S||T&&W),style:{"--index":y,"--toasts-before":y,"--z-index":_.length-y,"--offset":`${Me?Rn:Nn.current}px`,"--initial-height":T?"auto":`${Pn}px`,...P,...h.style},onDragEnd:()=>{Se(!1),ce(null),Yt.current=null},onPointerDown:ue=>{va||!dt||(ua.current=new Date,hn(Nn.current),ue.target.setPointerCapture(ue.pointerId),ue.target.tagName!=="BUTTON"&&(Se(!0),Yt.current={x:ue.clientX,y:ue.clientY}))},onPointerUp:()=>{var ue,ie,Pe,Zt;if(ze||!dt)return;Yt.current=null;let Lt=Number(((ue=Sr.current)==null?void 0:ue.style.getPropertyValue("--swipe-amount-x").replace("px",""))||0),mn=Number(((ie=Sr.current)==null?void 0:ie.style.getPropertyValue("--swipe-amount-y").replace("px",""))||0),tr=new Date().getTime()-((Pe=ua.current)==null?void 0:Pe.getTime()),$t=ee==="x"?Lt:mn,nr=Math.abs($t)/tr;if(Math.abs($t)>=CO||nr>.11){hn(Nn.current),(Zt=h.onDismiss)==null||Zt.call(h,h),Oe(ee==="x"?Lt>0?"right":"left":mn>0?"down":"up"),Mt(),ut(!0),fn(!1);return}Se(!1),ce(null)},onPointerMove:ue=>{var ie,Pe,Zt,Lt;if(!Yt.current||!dt||((ie=window.getSelection())==null?void 0:ie.toString().length)>0)return;let mn=ue.clientY-Yt.current.y,tr=ue.clientX-Yt.current.x,$t=(Pe=e.swipeDirections)!=null?Pe:RO(Z);!ee&&(Math.abs(tr)>1||Math.abs(mn)>1)&&ce(Math.abs(tr)>Math.abs(mn)?"x":"y");let nr={x:0,y:0};ee==="y"?($t.includes("top")||$t.includes("bottom"))&&($t.includes("top")&&mn<0||$t.includes("bottom")&&mn>0)&&(nr.y=mn):ee==="x"&&($t.includes("left")||$t.includes("right"))&&($t.includes("left")&&tr<0||$t.includes("right")&&tr>0)&&(nr.x=tr),(Math.abs(nr.x)>0||Math.abs(nr.y)>0)&&fn(!0),(Zt=Sr.current)==null||Zt.style.setProperty("--swipe-amount-x",`${nr.x}px`),(Lt=Sr.current)==null||Lt.style.setProperty("--swipe-amount-y",`${nr.y}px`)}},ha&&!h.jsx?O.createElement("button",{"aria-label":V,"data-disabled":va,"data-close-button":!0,onClick:va||!dt?()=>{}:()=>{var ue;Mt(),(ue=h.onDismiss)==null||ue.call(h,h)},className:On(N==null?void 0:N.closeButton,(s=h==null?void 0:h.classNames)==null?void 0:s.closeButton)},(o=z==null?void 0:z.close)!=null?o:fO):null,h.jsx||m.isValidElement(h.title)?h.jsx?h.jsx:typeof h.title=="function"?h.title():h.title:O.createElement(O.Fragment,null,tt||h.icon||h.promise?O.createElement("div",{"data-icon":"",className:On(N==null?void 0:N.icon,(i=h==null?void 0:h.classNames)==null?void 0:i.icon)},h.promise||h.type==="loading"&&!h.icon?h.icon||lf():null,h.type!=="loading"?h.icon||(z==null?void 0:z[tt])||oO(tt):null):null,O.createElement("div",{"data-content":"",className:On(N==null?void 0:N.content,(a=h==null?void 0:h.classNames)==null?void 0:a.content)},O.createElement("div",{"data-title":"",className:On(N==null?void 0:N.title,(l=h==null?void 0:h.classNames)==null?void 0:l.title)},typeof h.title=="function"?h.title():h.title),h.description?O.createElement("div",{"data-description":"",className:On(H,ic,N==null?void 0:N.description,(c=h==null?void 0:h.classNames)==null?void 0:c.description)},typeof h.description=="function"?h.description():h.description):null),m.isValidElement(h.cancel)?h.cancel:h.cancel&&Pc(h.c
157ancel)?O.createElement("button",{"data-button":!0,"data-cancel":!0,style:h.cancelButtonStyle||A,onClick:ue=>{var ie,Pe;Pc(h.cancel)&&dt&&((Pe=(ie=h.cancel).onClick)==null||Pe.call(ie,ue),Mt())},className:On(N==null?void 0:N.cancelButton,(u=h==null?void 0:h.classNames)==null?void 0:u.cancelButton)},h.cancel.label):null,m.isValidElement(h.action)?h.action:h.action&&Pc(h.action)?O.createElement("button",{"data-button":!0,"data-action":!0,style:h.actionButtonStyle||D,onClick:ue=>{var ie,Pe;Pc(h.action)&&((Pe=(ie=h.action).onClick)==null||Pe.call(ie,ue),!ue.defaultPrevented&&Mt())},className:On(N==null?void 0:N.actionButton,(d=h==null?void 0:h.classNames)==null?void 0:d.actionButton)},h.action.label):null))};function uw(){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 NO(e,t){let n={};return[e,t].forEach((r,s)=>{let o=s===1,i=o?"--mobile-offset":"--offset",a=o?SO:_O;function l(c){["top","right","bottom","left"].forEach(u=>{n[`${i}-${u}`]=typeof c=="number"?`${c}px`:c})}typeof r=="number"||typeof r=="string"?l(r):typeof r=="object"?["top","right","bottom","left"].forEach(c=>{r[c]===void 0?n[`${i}-${c}`]=a:n[`${i}-${c}`]=typeof r[c]=="number"?`${r[c]}px`:r[c]}):l(a)}),n}var AO=m.forwardRef(function(e,t){let{invert:n,position:r="bottom-right",hotkey:s=["altKey","KeyT"],expand:o,closeButton:i,className:a,offset:l,mobileOffset:c,theme:u="light",richColors:d,duration:p,style:h,visibleToasts:x=xO,toastOptions:v,dir:b=uw(),gap:w=kO,loadingIcon:g,icons:y,containerAriaLabel:_="Notifications",pauseWhenPageIsHidden:S}=e,[k,E]=O.useState([]),R=O.useMemo(()=>Array.from(new Set([r].concat(k.filter(X=>X.position).map(X=>X.position)))),[k,r]),[P,A]=O.useState([]),[D,M]=O.useState(!1),[H,L]=O.useState(!1),[Z,B]=O.useState(u!=="system"?u:typeof window<"u"&&window.matchMedia&&window.matchMedia("(prefers-color-scheme: dark)").matches?"dark":"light"),I=O.useRef(null),T=s.join("+").replace(/Key/g,"").replace(/Digit/g,""),N=O.useRef(null),z=O.useRef(!1),V=O.useCallback(X=>{E(ee=>{var ce;return(ce=ee.find(le=>le.id===X.id))!=null&&ce.delete||Ut.dismiss(X.id),ee.filter(({id:le})=>le!==X.id)})},[]);return O.useEffect(()=>Ut.subscribe(X=>{if(X.dismiss){E(ee=>ee.map(ce=>ce.id===X.id?{...ce,delete:!0}:ce));return}setTimeout(()=>{S_.flushSync(()=>{E(ee=>{let ce=ee.findIndex(le=>le.id===X.id);return ce!==-1?[...ee.slice(0,ce),{...ee[ce],...X},...ee.slice(ce+1)]:[X,...ee]})})})}),[]),O.useEffect(()=>{if(u!=="system"){B(u);return}if(u==="system"&&(window.matchMedia&&window.matchMedia("(prefers-color-scheme: dark)").matches?B("dark"):B("light")),typeof window>"u")return;let X=window.matchMedia("(prefers-color-scheme: dark)");try{X.addEventListener("change",({matches:ee})=>{B(ee?"dark":"light")})}catch{X.addListener(({matches:ce})=>{try{B(ce?"dark":"light")}catch(le){console.error(le)}})}},[u]),O.useEffect(()=>{k.length<=1&&M(!1)},[k]),O.useEffect(()=>{let X=ee=>{var ce,le;s.every(Oe=>ee[Oe]||ee.code===Oe)&&(M(!0),(ce=I.current)==null||ce.focus()),ee.code==="Escape"&&(document.activeElement===I.current||(le=I.current)!=null&&le.contains(document.activeElement))&&M(!1)};return document.addEventListener("keydown",X),()=>document.removeEventListener("keydown",X)},[s]),O.useEffect(()=>{if(I.current)return()=>{N.current&&(N.current.focus({preventScroll:!0}),N.current=null,z.current=!1)}},[I.current]),O.createElement("section",{ref:t,"aria-label":`${_} ${T}`,tabIndex:-1,"aria-live":"polite","aria-relevant":"additions text","aria-atomic":"false",suppressHydrationWarning:!0},R.map((X,ee)=>{var ce;let[le,Oe]=X.split("-");return k.length?O.createElement("ol",{key:X,dir:b==="auto"?uw():b,tabIndex:-1,ref:I,className:a,"data-sonner-toaster":!0,"data-theme":Z,"data-y-position":le,"data-lifted":D&&k.length>1&&!o,"data-x-position":Oe,style:{"--front-toast-height":`${((ce=P[0])==null?void 0:ce.height)||0}px`,"--width":`${EO}px`,"--gap":`${w}px`,...h,...NO(l,c)},onBlur:W=>{z.current&&!W.currentTarget.contains(W.relatedTarget)&&(z.current=!1,N.current&&(N.current.focus({preventScroll:!0}),N.current=null))},onFocus:W=>{W.target instanceof HTMLElement&&W.target.dataset.dismissible==="false"||z.current||(z.current=!0,N.current=W.relatedTarget)},onMouseEnter:()=>M(!0),onMouseMove:()=>M(!0),onMouseLeave:()=>{H||M(!1)},onDragEnd:()=>M(!1),onPointerDown:W=>{W.target instanceof HTMLElement&&W.target.dataset.dismissible==="false"||L(!0)},onPointerUp:()=>L(!1)},k.filter(W=>!W.position&&ee===0||W.position===X).map((W,xe)=>{var Me,_e;return O.createElement(PO,{key:W.id,icons:y,index:xe,toast:W,defaultRichColors:d,duration:(Me=v==null?void 0:v.duration)!=null?Me:p,className:v==null?void 0:v.className,descriptionClassName:v==null?void 0:v.descriptionClassName,invert:n,visibleToasts:x,closeButton:(_e=v==null?void 0:v.closeButton)!=null?_e:i,interacting:H,position:X,style:v==null?void 0:v.style,unstyled:v==null?void 0:v.unstyled,classNames:v==null?void 0:v.classNames,cancelButtonStyle:v==null?void 0:v.cancelButtonStyle,actionButtonStyle:v==null?void 0:v.actionButtonStyle,removeToast:V,toasts:k.filter(we=>we.position==W.position),heights:P.filter(we=>we.position==W.position),setHeights:A,expandByDefault:o,gap:w,loadingIcon:g,expanded:D,pauseWhenPageIsHidden:S,swipeDirections:e.swipeDirections})})):null}))});const OO=({...e})=>{const{theme:t="system"}=sO();return f.jsx(AO,{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 jO=Pm[" useId ".trim().toString()]||(()=>{}),IO=0;function Ur(e){const[t,n]=m.useState(jO());return it(()=>{n(r=>r??String(IO++))},[e]),t?`radix-${t}`:""}const DO=["top","right","bottom","left"],Is=Math.min,en=Math.max,Fu=Math.round,Nc=Math.floor,vr=e=>({x:e,y:e}
vendor: 12,402 bytes, line 157
157),MO={left:"right",right:"left",bottom:"top",top:"bottom"},LO={start:"end",end:"start"};function jp(e,t,n){return en(e,Is(t,n))}function Vr(e,t){return typeof e=="function"?e(t):e}function qr(e){return e.split("-")[0]}function ta(e){return e.split("-")[1]}function Cg(e){return e==="x"?"y":"x"}function Tg(e){return e==="y"?"height":"width"}const $O=new Set(["top","bottom"]);function hr(e){return $O.has(qr(e))?"y":"x"}function Rg(e){return Cg(hr(e))}function FO(e,t,n){n===void 0&&(n=!1);const r=ta(e),s=Rg(e),o=Tg(s);let i=s==="x"?r===(n?"end":"start")?"right":"left":r==="start"?"bottom":"top";return t.reference[o]>t.floating[o]&&(i=Uu(i)),[i,Uu(i)]}function UO(e){const t=Uu(e);return[Ip(e),t,Ip(t)]}function Ip(e){return e.replace(/start|end/g,t=>LO[t])}const dw=["left","right"],fw=["right","left"],BO=["top","bottom"],zO=["bottom","top"];function WO(e,t,n){switch(e){case"top":case"bottom":return n?t?fw:dw:t?dw:fw;case"left":case"right":return t?BO:zO;default:return[]}}function HO(e,t,n,r){const s=ta(e);let o=WO(qr(e),n==="start",r);return s&&(o=o.map(i=>i+"-"+s),t&&(o=o.concat(o.map(Ip)))),o}function Uu(e){return e.replace(/left|right|bottom|top/g,t=>MO[t])}function VO(e){return{top:0,right:0,bottom:0,left:0,...e}}function yS(e){return typeof e!="number"?VO(e):{top:e,right:e,bottom:e,left:e}}function Bu(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 hw(e,t,n){let{reference:r,floating:s}=e;const o=hr(t),i=Rg(t),a=Tg(i),l=qr(t),c=o==="y",u=r.x+r.width/2-s.width/2,d=r.y+r.height/2-s.height/2,p=r[a]/2-s[a]/2;let h;switch(l){case"top":h={x:u,y:r.y-s.height};break;case"bottom":h={x:u,y:r.y+r.height};break;case"right":h={x:r.x+r.width,y:d};break;case"left":h={x:r.x-s.width,y:d};break;default:h={x:r.x,y:r.y}}switch(ta(t)){case"start":h[i]-=p*(n&&c?-1:1);break;case"end":h[i]+=p*(n&&c?-1:1);break}return h}const qO=async(e,t,n)=>{const{placement:r="bottom",strategy:s="absolute",middleware:o=[],platform:i}=n,a=o.filter(Boolean),l=await(i.isRTL==null?void 0:i.isRTL(t));let c=await i.getElementRects({reference:e,floating:t,strategy:s}),{x:u,y:d}=hw(c,r,l),p=r,h={},x=0;for(let v=0;v<a.length;v++){const{name:b,fn:w}=a[v],{x:g,y,data:_,reset:S}=await w({x:u,y:d,initialPlacement:r,placement:p,strategy:s,middlewareData:h,rects:c,platform:i,elements:{reference:e,floating:t}});u=g??u,d=y??d,h={...h,[b]:{...h[b],..._}},S&&x<=50&&(x++,typeof S=="object"&&(S.placement&&(p=S.placement),S.rects&&(c=S.rects===!0?await i.getElementRects({reference:e,floating:t,strategy:s}):S.rects),{x:u,y:d}=hw(c,p,l)),v=-1)}return{x:u,y:d,placement:p,strategy:s,middlewareData:h}};async function El(e,t){var n;t===void 0&&(t={});const{x:r,y:s,platform:o,rects:i,elements:a,strategy:l}=e,{boundary:c="clippingAncestors",rootBoundary:u="viewport",elementContext:d="floating",altBoundary:p=!1,padding:h=0}=Vr(t,e),x=yS(h),b=a[p?d==="floating"?"reference":"floating":d],w=Bu(await o.getClippingRect({element:(n=await(o.isElement==null?void 0:o.isElement(b)))==null||n?b:b.contextElement||await(o.getDocumentElement==null?void 0:o.getDocumentElement(a.floating)),boundary:c,rootBoundary:u,strategy:l})),g=d==="floating"?{x:r,y:s,width:i.floating.width,height:i.floating.height}:i.reference,y=await(o.getOffsetParent==null?void 0:o.getOffsetParent(a.floating)),_=await(o.isElement==null?void 0:o.isElement(y))?await(o.getScale==null?void 0:o.getScale(y))||{x:1,y:1}:{x:1,y:1},S=Bu(o.convertOffsetParentRelativeRectToViewportRelativeRect?await o.convertOffsetParentRelativeRectToViewportRelativeRect({elements:a,rect:g,offsetParent:y,strategy:l}):g);return{top:(w.top-S.top+x.top)/_.y,bottom:(S.bottom-w.bottom+x.bottom)/_.y,left:(w.left-S.left+x.left)/_.x,right:(S.right-w.right+x.right)/_.x}}const KO=e=>({name:"arrow",options:e,async fn(t){const{x:n,y:r,placement:s,rects:o,platform:i,elements:a,middlewareData:l}=t,{element:c,padding:u=0}=Vr(e,t)||{};if(c==null)return{};const d=yS(u),p={x:n,y:r},h=Rg(s),x=Tg(h),v=await i.getDimensions(c),b=h==="y",w=b?"top":"left",g=b?"bottom":"right",y=b?"clientHeight":"clientWidth",_=o.reference[x]+o.reference[h]-p[h]-o.floating[x],S=p[h]-o.reference[h],k=await(i.getOffsetParent==null?void 0:i.getOffsetParent(c));let E=k?k[y]:0;(!E||!await(i.isElement==null?void 0:i.isElement(k)))&&(E=a.floating[y]||o.floating[x]);const R=_/2-S/2,P=E/2-v[x]/2-1,A=Is(d[w],P),D=Is(d[g],P),M=A,H=E-v[x]-D,L=E/2-v[x]/2+R,Z=jp(M,L,H),B=!l.arrow&&ta(s)!=null&&L!==Z&&o.reference[x]/2-(L<M?A:D)-v[x]/2<0,I=B?L<M?L-M:L-H:0;return{[h]:p[h]+I,data:{[h]:Z,centerOffset:L-Z-I,...B&&{alignmentOffset:I}},reset:B}}}),GO=function(e){return e===void 0&&(e={}),{name:"flip",options:e,async fn(t){var n,r;const{placement:s,middlewareData:o,rects:i,initialPlacement:a,platform:l,elements:c}=t,{mainAxis:u=!0,crossAxis:d=!0,fallbackPlacements:p,fallbackStrategy:h="bestFit",fallbackAxisSideDirection:x="none",flipAlignment:v=!0,...b}=Vr(e,t);if((n=o.arrow)!=null&&n.alignmentOffset)return{};const w=qr(s),g=hr(a),y=qr(a)===a,_=await(l.isRTL==null?void 0:l.isRTL(c.floating)),S=p||(y||!v?[Uu(a)]:UO(a)),k=x!=="none";!p&&k&&S.push(...HO(a,v,x,_));const E=[a,...S],R=await El(t,b),P=[];let A=((r=o.flip)==null?void 0:r.overflows)||[];if(u&&P.push(R[w]),d){const L=FO(s,i,_);P.push(R[L[0]],R[L[1]])}if(A=[...A,{placement:s,overflows:P}],!P.every(L=>L<=0)){var D,M;const L=(((D=o.flip)==null?void 0:D.index)||0)+1,Z=E[L];if(Z&&(!(d==="alignment"?g!==hr(Z):!1)||A.every(T=>T.overflows[0]>0&&hr(T.placement)===g)))return{data:{index:L,overflows:A},reset:{placement:Z}};let B=(M=A.filter(I=>I.overflows[0]<=0).sort((I,T)=>I.overflows[1]-T.overflows[1])[0])==null?void 0:M.placement;if(!B)switch(h){case"bestFit":{var H;const I=(H=A.filter(T=>{if(k){const N=hr(T.placement);return N===g||N==="y"}return!0}).map(T=>[T.placement,T.overflows.filter(N=>N>0).reduce((N,z)=>N+z,0)]).sort((T,N)=>T[1]-N[1])[0])==null?void 0:H[0];I&&(B=I);break}case"initialPlacement":B=a;break}if(s!==B)return{reset:{placement:B}}}return{}}}};function pw(e,t){return{top:e.top-t.height,right:e.right-t.width,bottom:e.bottom-t.height,left:e.left-t.width}}function mw(e){return DO.some(t=>e[t]>=0)}const YO=function(e){return e===void 0&&(e={}),{name:"hide",options:e,async fn(t){const{rects:n}=t,{strategy:r="referenceHidden",...s}=Vr(e,t);switch(r){case"referenceHidden":{const o=await El(t,{...s,elementContext:"reference"}),i=pw(o,n.reference);return{data:{referenceHiddenOffsets:i,referenceHidden:mw(i)}}}case"escaped":{const o=await El(t,{...s,altBoundary:!0}),i=pw(o,n.floating);return{data:{escapedOffsets:i,escaped:mw(i)}}}default:return{}}}}},wS=new Set(["left","top"]);async function ZO(e,t){const{placement:n,platform:r,elements:s}=e,o=await(r.isRTL==null?void 0:r.isRTL(s.floating)),i=qr(n),a=ta(n),l=hr(n)==="y",c=wS.has(i)?-1:1,u=o&&l?-1:1,d=Vr(t,e);let{mainAxis:p,crossAxis:h,alignmentAxis:x}=typeof d=="number"?{mainAxis:d,crossAxis:0,alignmentAxis:null}:{mainAxis:d.mainAxis||0,crossAxis:d.crossAxis||0,alignmentAxis:d.alignmentAxis};return a&&typeof x=="number"&&(h=a==="end"?x*-1:x),l?{x:h*u,y:p*c}:{x:p*c,y:h*u}}const QO=function(e){return e===void 0&&(e=0),{name:"offset",options:e,async fn(t){var n,r;const{x:s,y:o,placement:i,middlewareData:a}=t,l=await ZO(t,e);return i===((n=a.offset)==null?void 0:n.placement)&&(r=a.arrow)!=null&&r.alignmentOffset?{}:{x:s+l.x,y:o+l.y,data:{...l,placement:i}}}}},JO=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:i=!1,limiter:a={fn:b=>{let{x:w,y:g}=b;return{x:w,y:g}}},...l}=Vr(e,t),c={x:n,y:r},u=await El(t,l),d=hr(qr(s)),p=Cg(d);let h=c[p],x=c[d];if(o){const b=p==="y"?"top":"left",w=p==="y"?"bottom":"right",g=h+u[b],y=h-u[w];h=jp(g,h,y)}if(i){const b=d==="y"?"top":"left",w=d==="y"?"bottom":"right",g=x+u[b],y=x-u[w];x=jp(g,x,y)}const v=a.fn({...t,[p]:h,[d]:x});return{...v,data:{x:v.x-n,y:v.y-r,enabled:{[p]:o,[d]:i}}}}}},XO=function(e){return e===void 0&&(e={}),{options:e,fn(t){const{x:n,y:r,placement:s,rects:o,middlewareData:i}=t,{offset:a=0,mainAxis:l=!0,crossAxis:c=!0}=Vr(e,t),u={x:n,y:r},d=hr(s),p=Cg(d);let h=u[p],x=u[d];const v=Vr(a,t),b=typeof v=="number"?{mainAxis:v,crossAxis:0}:{mainAxis:0,crossAxis:0,...v};if(l){const y=p==="y"?"height":"width",_=o.reference[p]-o.floating[y]+b.mainAxis,S=o.reference[p]+o.reference[y]-b.mainAxis;h<_?h=_:h>S&&(h=S)}if(c){var w,g;const y=p==="y"?"width":"height",_=wS.has(qr(s)),S=o.reference[d]-o.floating[y]+(_&&((w=i.offset)==null?void 0:w[d])||0)+(_?0:b.crossAxis),k=o.reference[d]+o.reference[y]+(_?0:((g=i.offset)==null?void 0:g[d])||0)-(_?b.crossAxis:0);x<S?x=S:x>k&&(x=k)}return{[p]:h,[d]:x}}}},ej=function(e){return e===void 0&&(e={}),{name:"size",options:e,async fn(t){var n,r;const{placement:s,rects:o,platform:i,elements:a}=t,{apply:l=()=>{},...c}=Vr(e,t),u=await El(t,c),d=qr(s),p=ta(s),h=hr(s)==="y",{width:x,height:v}=o.floating;let b,w;d==="top"||d==="bottom"?(b=d,w=p===(await(i.isRTL==null?void 0:i.isRTL(a.floating))?"start":"end")?"left":"right"):(w=d,b=p==="end"?"top":"bottom");const g=v-u.top-u.bottom,y=x-u.left-u.right,_=Is(v-u[b],g),S=Is(x-u[w],y),k=!t.middlewareData.shift;let E=_,R=S;if((n=t.middlewareData.shift)!=null&&n.enabled.x&&(R=y),(r=t.middlewareData.shift)!=null&&r.enabled.y&&(E=g),k&&!p){const A=en(u.left,0),D=en(u.right,0),M=en(u.top,0),H=en(u.bottom,0);h?R=x-2*(A!==0||D!==0?A+D:en(u.left,u.right)):E=v-2*(M!==0||H!==0?M+H:en(u.top,u.bottom))}await l({...t,availableWidth:R,availableHeight:E});const P=await i.getDimensions(a.floating);return x!==P.width||v!==P.height?{reset:{rects:!0}}:{}}}};function jd(){return typeof window<"u"}function na(e){return bS(e)?(e.nodeName||"").toLowerCase():"#document"}function sn(e){var t;return(e==null||(t=e.ownerDocument)==null?void 0:t.defaultView)||window}function xr(e){var t;return(t=(bS(e)?e.ownerDocument:e.document)||window.document)==null?void 0:t.documentElement}function bS(e){return jd()?e instanceof Node||e instanceof sn(e).Node:!1}function Yn(e){return jd()?e instanceof Element||e instanceof sn(e).Element:!1}function wr(e){return jd()?e instanceof HTMLElement||e instanceof sn(e).HTMLElement:!1}function gw(e){return!jd()||typeof ShadowRoot>"u"?!1:e instanceof ShadowRoot||e instanceof sn(e).ShadowRoot}const tj=new Set(["inline","contents"]);function Xl(e){const{overflow:t,overflowX:n,overflowY:r,display:s}=Zn(e);return/auto|scroll|overlay|hidden|clip/.test(t+r+n)&&!tj.has(s)}const nj=new Set(["table","td","th"]);function rj(e){return nj.has(na(e))}const sj=[":popover-open",":modal"];function Id(e){return sj.some(t=>{try{return e.matches(t)}catch{return!1}})}const oj=["transform","translate","scale","rotate","perspective"],ij=["transform","translate","scale","rotate","perspective","filter"],aj=["paint","layout","strict","content"];function Pg(e){const t=Ng(),n=Yn(e)?Zn(e):e;return oj.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)||ij.some(r=>(n.willChange||"").includes(r))||aj.some(r=>(n.contain||"").includes(r))}function lj(e){let t=Ds(e);for(;wr(t)&&!Wi(t);){if(Pg(t))return t;if(Id(t))return null;t=Ds(t)}return null}function Ng(){return typeof CSS>"u"||!CSS.supports?!1:CSS.supports("-webkit-backdrop-filter","none")}const cj=new Set(["html","body","#document"]);function Wi(e){return cj.has(na(e))}function Zn(e){return sn(e).getComputedStyle(e)}function Dd(e){return Yn(e)?{scrollLeft:e.scrollLeft,scrollTop:e.scrollTop}:{scrollLeft:e.scrollX,scrollTop:e.scrollY}}function Ds(e){if(na(e)==="html")return e;const t=e.assignedSlot||e.parentNode||gw(e)&&e.host||xr(e);return gw(t)?t.host:t}function xS(e){const t=Ds(e);return Wi(t)?e.ownerDocument?e.ownerDocument.body:e.body:wr(t)&&Xl(t)?t:xS(t)}function kl(e,t,n){var r;t===void 0&&(t=[]),n===void 0&&(n=!0);const s=xS(e),o=s===((r=e.ownerDocument)==null?void 0:r.body),i=sn(s);if(o){const a=Dp(i);return t.concat(i,i.visualViewport||[],Xl(s)?s:[],a&&n?kl(a):[])}return t.concat(s,kl(s,[],n))}function Dp(e){return e.parent&&Object.getPrototypeOf(e.parent)?e.frameElement:null}function _S(e){const t=Zn(e);let n=parseFloat(t.width)||0,r=parseFloat(t.height)||0;const s=wr(e),o=s?e.offsetWidth:n,i=s?e.offsetHeight:r,a=Fu(n)!==o||Fu(r)!==i;return a&&(n=o,r=i),{width:n,height:r,$:a}}function Ag(e){return Yn(e)?e:e.contextElement}function Ei(e){const t=Ag(e);if(!wr(t))return vr(1);
vendor: 5,309 bytes, line 157
157const n=t.getBoundingClientRect(),{width:r,height:s,$:o}=_S(t);let i=(o?Fu(n.width):n.width)/r,a=(o?Fu(n.height):n.height)/s;return(!i||!Number.isFinite(i))&&(i=1),(!a||!Number.isFinite(a))&&(a=1),{x:i,y:a}}const uj=vr(0);function SS(e){const t=sn(e);return!Ng()||!t.visualViewport?uj:{x:t.visualViewport.offsetLeft,y:t.visualViewport.offsetTop}}function dj(e,t,n){return t===void 0&&(t=!1),!n||t&&n!==sn(e)?!1:t}function Co(e,t,n,r){t===void 0&&(t=!1),n===void 0&&(n=!1);const s=e.getBoundingClientRect(),o=Ag(e);let i=vr(1);t&&(r?Yn(r)&&(i=Ei(r)):i=Ei(e));const a=dj(o,n,r)?SS(o):vr(0);let l=(s.left+a.x)/i.x,c=(s.top+a.y)/i.y,u=s.width/i.x,d=s.height/i.y;if(o){const p=sn(o),h=r&&Yn(r)?sn(r):r;let x=p,v=Dp(x);for(;v&&r&&h!==x;){const b=Ei(v),w=v.getBoundingClientRect(),g=Zn(v),y=w.left+(v.clientLeft+parseFloat(g.paddingLeft))*b.x,_=w.top+(v.clientTop+parseFloat(g.paddingTop))*b.y;l*=b.x,c*=b.y,u*=b.x,d*=b.y,l+=y,c+=_,x=sn(v),v=Dp(x)}}return Bu({width:u,height:d,x:l,y:c})}function Og(e,t){const n=Dd(e).scrollLeft;return t?t.left+n:Co(xr(e)).left+n}function ES(e,t,n){n===void 0&&(n=!1);const r=e.getBoundingClientRect(),s=r.left+t.scrollLeft-(n?0:Og(e,r)),o=r.top+t.scrollTop;return{x:s,y:o}}function fj(e){let{elements:t,rect:n,offsetParent:r,strategy:s}=e;const o=s==="fixed",i=xr(r),a=t?Id(t.floating):!1;if(r===i||a&&o)return n;let l={scrollLeft:0,scrollTop:0},c=vr(1);const u=vr(0),d=wr(r);if((d||!d&&!o)&&((na(r)!=="body"||Xl(i))&&(l=Dd(r)),wr(r))){const h=Co(r);c=Ei(r),u.x=h.x+r.clientLeft,u.y=h.y+r.clientTop}const p=i&&!d&&!o?ES(i,l,!0):vr(0);return{width:n.width*c.x,height:n.height*c.y,x:n.x*c.x-l.scrollLeft*c.x+u.x+p.x,y:n.y*c.y-l.scrollTop*c.y+u.y+p.y}}function hj(e){return Array.from(e.getClientRects())}function pj(e){const t=xr(e),n=Dd(e),r=e.ownerDocument.body,s=en(t.scrollWidth,t.clientWidth,r.scrollWidth,r.clientWidth),o=en(t.scrollHeight,t.clientHeight,r.scrollHeight,r.clientHeight);let i=-n.scrollLeft+Og(e);const a=-n.scrollTop;return Zn(r).direction==="rtl"&&(i+=en(t.clientWidth,r.clientWidth)-s),{width:s,height:o,x:i,y:a}}function mj(e,t){const n=sn(e),r=xr(e),s=n.visualViewport;let o=r.clientWidth,i=r.clientHeight,a=0,l=0;if(s){o=s.width,i=s.height;const c=Ng();(!c||c&&t==="fixed")&&(a=s.offsetLeft,l=s.offsetTop)}return{width:o,height:i,x:a,y:l}}const gj=new Set(["absolute","fixed"]);function vj(e,t){const n=Co(e,!0,t==="fixed"),r=n.top+e.clientTop,s=n.left+e.clientLeft,o=wr(e)?Ei(e):vr(1),i=e.clientWidth*o.x,a=e.clientHeight*o.y,l=s*o.x,c=r*o.y;return{width:i,height:a,x:l,y:c}}function vw(e,t,n){let r;if(t==="viewport")r=mj(e,n);else if(t==="document")r=pj(xr(e));else if(Yn(t))r=vj(t,n);else{const s=SS(e);r={x:t.x-s.x,y:t.y-s.y,width:t.width,height:t.height}}return Bu(r)}function kS(e,t){const n=Ds(e);return n===t||!Yn(n)||Wi(n)?!1:Zn(n).position==="fixed"||kS(n,t)}function yj(e,t){const n=t.get(e);if(n)return n;let r=kl(e,[],!1).filter(a=>Yn(a)&&na(a)!=="body"),s=null;const o=Zn(e).position==="fixed";let i=o?Ds(e):e;for(;Yn(i)&&!Wi(i);){const a=Zn(i),l=Pg(i);!l&&a.position==="fixed"&&(s=null),(o?!l&&!s:!l&&a.position==="static"&&!!s&&gj.has(s.position)||Xl(i)&&!l&&kS(e,i))?r=r.filter(u=>u!==i):s=a,i=Ds(i)}return t.set(e,r),r}function wj(e){let{element:t,boundary:n,rootBoundary:r,strategy:s}=e;const i=[...n==="clippingAncestors"?Id(t)?[]:yj(t,this._c):[].concat(n),r],a=i[0],l=i.reduce((c,u)=>{const d=vw(t,u,s);return c.top=en(d.top,c.top),c.right=Is(d.right,c.right),c.bottom=Is(d.bottom,c.bottom),c.left=en(d.left,c.left),c},vw(t,a,s));return{width:l.right-l.left,height:l.bottom-l.top,x:l.left,y:l.top}}function bj(e){const{width:t,height:n}=_S(e);return{width:t,height:n}}function xj(e,t,n){const r=wr(t),s=xr(t),o=n==="fixed",i=Co(e,!0,o,t);let a={scrollLeft:0,scrollTop:0};const l=vr(0);function c(){l.x=Og(s)}if(r||!r&&!o)if((na(t)!=="body"||Xl(s))&&(a=Dd(t)),r){const h=Co(t,!0,o,t);l.x=h.x+t.clientLeft,l.y=h.y+t.clientTop}else s&&c();o&&!r&&s&&c();const u=s&&!r&&!o?ES(s,a):vr(0),d=i.left+a.scrollLeft-l.x-u.x,p=i.top+a.scrollTop-l.y-u.y;return{x:d,y:p,width:i.width,height:i.height}}function qf(e){return Zn(e).position==="static"}function yw(e,t){if(!wr(e)||Zn(e).position==="fixed")return null;if(t)return t(e);let n=e.offsetParent;return xr(e)===n&&(n=n.ownerDocument.body),n}function CS(e,t){const n=sn(e);if(Id(e))return n;if(!wr(e)){let s=Ds(e);for(;s&&!Wi(s);){if(Yn(s)&&!qf(s))return s;s=Ds(s)}return n}let r=yw(e,t);for(;r&&rj(r)&&qf(r);)r=yw(r,t);return r&&Wi(r)&&qf(r)&&!Pg(r)?n:r||lj(e)||n}const _j=async function(e){const t=this.getOffsetParent||CS,n=this.getDimensions,r=await n(e.floating);return{reference:xj(e.reference,await t(e.floating),e.strategy),floating:{x:0,y:0,width:r.width,height:r.height}}};function Sj(e){return Zn(e).direction==="rtl"}const Ej={convertOffsetParentRelativeRectToViewportRelativeRect:fj,getDocumentElement:xr,getClippingRect:wj,getOffsetParent:CS,getElementRects:_j,getClientRects:hj,getDimensions:bj,getScale:Ei,isElement:Yn,isRTL:Sj};function TS(e,t){return e.x===t.x&&e.y===t.y&&e.width===t.width&&e.height===t.height}function kj(e,t){let n=null,r;const s=xr(e);function o(){var a;clearTimeout(r),(a=n)==null||a.disconnect(),n=null}function i(a,l){a===void 0&&(a=!1),l===void 0&&(l=1),o();const c=e.getBoundingClientRect(),{left:u,top:d,width:p,height:h}=c;if(a||t(),!p||!h)return;
vendor: 10,199 bytes, line 157
157const x=Nc(d),v=Nc(s.clientWidth-(u+p)),b=Nc(s.clientHeight-(d+h)),w=Nc(u),y={rootMargin:-x+"px "+-v+"px "+-b+"px "+-w+"px",threshold:en(0,Is(1,l))||1};let _=!0;function S(k){const E=k[0].intersectionRatio;if(E!==l){if(!_)return i();E?i(!1,E):r=setTimeout(()=>{i(!1,1e-7)},1e3)}E===1&&!TS(c,e.getBoundingClientRect())&&i(),_=!1}try{n=new IntersectionObserver(S,{...y,root:s.ownerDocument})}catch{n=new IntersectionObserver(S,y)}n.observe(e)}return i(!0),o}function Cj(e,t,n,r){r===void 0&&(r={});const{ancestorScroll:s=!0,ancestorResize:o=!0,elementResize:i=typeof ResizeObserver=="function",layoutShift:a=typeof IntersectionObserver=="function",animationFrame:l=!1}=r,c=Ag(e),u=s||o?[...c?kl(c):[],...kl(t)]:[];u.forEach(w=>{s&&w.addEventListener("scroll",n,{passive:!0}),o&&w.addEventListener("resize",n)});const d=c&&a?kj(c,n):null;let p=-1,h=null;i&&(h=new ResizeObserver(w=>{let[g]=w;g&&g.target===c&&h&&(h.unobserve(t),cancelAnimationFrame(p),p=requestAnimationFrame(()=>{var y;(y=h)==null||y.observe(t)})),n()}),c&&!l&&h.observe(c),h.observe(t));let x,v=l?Co(e):null;l&&b();function b(){const w=Co(e);v&&!TS(v,w)&&n(),v=w,x=requestAnimationFrame(b)}return n(),()=>{var w;u.forEach(g=>{s&&g.removeEventListener("scroll",n),o&&g.removeEventListener("resize",n)}),d==null||d(),(w=h)==null||w.disconnect(),h=null,l&&cancelAnimationFrame(x)}}const Tj=QO,Rj=JO,Pj=GO,Nj=ej,Aj=YO,ww=KO,Oj=XO,jj=(e,t,n)=>{const r=new Map,s={platform:Ej,...n},o={...s.platform,_c:r};return qO(e,t,{...s,platform:o})};var Ij=typeof document<"u",Dj=function(){},lu=Ij?m.useLayoutEffect:Dj;function zu(e,t){if(e===t)return!0;if(typeof e!=typeof t)return!1;if(typeof e=="function"&&e.toString()===t.toString())return!0;let n,r,s;if(e&&t&&typeof e=="object"){if(Array.isArray(e)){if(n=e.length,n!==t.length)return!1;for(r=n;r--!==0;)if(!zu(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)&&!zu(e[o],t[o]))return!1}return!0}return e!==e&&t!==t}function RS(e){return typeof window>"u"?1:(e.ownerDocument.defaultView||window).devicePixelRatio||1}function bw(e,t){const n=RS(e);return Math.round(t*n)/n}function Kf(e){const t=m.useRef(e);return lu(()=>{t.current=e}),t}function Mj(e){e===void 0&&(e={});const{placement:t="bottom",strategy:n="absolute",middleware:r=[],platform:s,elements:{reference:o,floating:i}={},transform:a=!0,whileElementsMounted:l,open:c}=e,[u,d]=m.useState({x:0,y:0,strategy:n,placement:t,middlewareData:{},isPositioned:!1}),[p,h]=m.useState(r);zu(p,r)||h(r);const[x,v]=m.useState(null),[b,w]=m.useState(null),g=m.useCallback(T=>{T!==k.current&&(k.current=T,v(T))},[]),y=m.useCallback(T=>{T!==E.current&&(E.current=T,w(T))},[]),_=o||x,S=i||b,k=m.useRef(null),E=m.useRef(null),R=m.useRef(u),P=l!=null,A=Kf(l),D=Kf(s),M=Kf(c),H=m.useCallback(()=>{if(!k.current||!E.current)return;const T={placement:t,strategy:n,middleware:p};D.current&&(T.platform=D.current),jj(k.current,E.current,T).then(N=>{const z={...N,isPositioned:M.current!==!1};L.current&&!zu(R.current,z)&&(R.current=z,Io.flushSync(()=>{d(z)}))})},[p,t,n,D,M]);lu(()=>{c===!1&&R.current.isPositioned&&(R.current.isPositioned=!1,d(T=>({...T,isPositioned:!1})))},[c]);const L=m.useRef(!1);lu(()=>(L.current=!0,()=>{L.current=!1}),[]),lu(()=>{if(_&&(k.current=_),S&&(E.current=S),_&&S){if(A.current)return A.current(_,S,H);H()}},[_,S,H,A,P]);const Z=m.useMemo(()=>({reference:k,floating:E,setReference:g,setFloating:y}),[g,y]),B=m.useMemo(()=>({reference:_,floating:S}),[_,S]),I=m.useMemo(()=>{const T={position:n,left:0,top:0};if(!B.floating)return T;const N=bw(B.floating,u.x),z=bw(B.floating,u.y);return a?{...T,transform:"translate("+N+"px, "+z+"px)",...RS(B.floating)>=1.5&&{willChange:"transform"}}:{position:n,left:N,top:z}},[n,a,B.floating,u.x,u.y]);return m.useMemo(()=>({...u,update:H,refs:Z,elements:B,floatingStyles:I}),[u,H,Z,B,I])}const Lj=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?ww({element:r.current,padding:s}).fn(n):{}:r?ww({element:r,padding:s}).fn(n):{}}}},$j=(e,t)=>({...Tj(e),options:[e,t]}),Fj=(e,t)=>({...Rj(e),options:[e,t]}),Uj=(e,t)=>({...Oj(e),options:[e,t]}),Bj=(e,t)=>({...Pj(e),options:[e,t]}),zj=(e,t)=>({...Nj(e),options:[e,t]}),Wj=(e,t)=>({...Aj(e),options:[e,t]}),Hj=(e,t)=>({...Lj(e),options:[e,t]});var Vj="Arrow",PS=m.forwardRef((e,t)=>{const{children:n,width:r=10,height:s=5,...o}=e;return f.jsx(ne.svg,{...o,ref:t,width:r,height:s,viewBox:"0 0 30 10",preserveAspectRatio:"none",children:e.asChild?n:f.jsx("polygon",{points:"0,0 30,0 15,10"})})});PS.displayName=Vj;var qj=PS;function Md(e){const[t,n]=m.useState(void 0);return it(()=>{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 i,a;if("borderBoxSize"in o){const l=o.borderBoxSize,c=Array.isArray(l)?l[0]:l;i=c.inlineSize,a=c.blockSize}else i=e.offsetWidth,a=e.offsetHeight;n({width:i,height:a})});return r.observe(e,{box:"border-box"}),()=>r.unobserve(e)}else n(void 0)},[e]),t}var jg="Popper",[NS,Ld]=Gt(jg),[Kj,AS]=NS(jg),OS=e=>{const{__scopePopper:t,children:n}=e,[r,s]=m.useState(null);return f.jsx(Kj,{scope:t,anchor:r,onAnchorChange:s,children:n})};OS.displayName=jg;var jS="PopperAnchor",IS=m.forwardRef((e,t)=>{const{__scopePopper:n,virtualRef:r,...s}=e,o=AS(jS,n),i=m.useRef(null),a=de(t,i);return m.useEffect(()=>{o.onAnchorChange((r==null?void 0:r.current)||i.current)}),r?null:f.jsx(ne.div,{...s,ref:a})});IS.displayName=jS;var Ig="PopperContent",[Gj,Yj]=NS(Ig),DS=m.forwardRef((e,t)=>{var W,xe,Me,_e,we,Se;const{__scopePopper:n,side:r="bottom",sideOffset:s=0,align:o="center",alignOffset:i=0,arrowPadding:a=0,avoidCollisions:l=!0,collisionBoundary:c=[],collisionPadding:u=0,sticky:d="partial",hideWhenDetached:p=!1,updatePositionStrategy:h="optimized",onPlaced:x,...v}=e,b=AS(Ig,n),[w,g]=m.useState(null),y=de(t,ze=>g(ze)),[_,S]=m.useState(null),k=Md(_),E=(k==null?void 0:k.width)??0,R=(k==null?void 0:k.height)??0,P=r+(o!=="center"?"-"+o:""),A=typeof u=="number"?u:{top:0,right:0,bottom:0,left:0,...u},D=Array.isArray(c)?c:[c],M=D.length>0,H={padding:A,boundary:D.filter(Qj),altBoundary:M},{refs:L,floatingStyles:Z,placement:B,isPositioned:I,middlewareData:T}=Mj({strategy:"fixed",placement:P,whileElementsMounted:(...ze)=>Cj(...ze,{animationFrame:h==="always"}),elements:{reference:b.anchor},middleware:[$j({mainAxis:s+R,alignmentAxis:i}),l&&Fj({mainAxis:!0,crossAxis:!1,limiter:d==="partial"?Uj():void 0,...H}),l&&Bj({...H}),zj({...H,apply:({elements:ze,rects:ut,availableWidth:kt,availableHeight:fn})=>{const{width:Rn,height:hn}=ut.reference,Pn=ze.floating.style;Pn.setProperty("--radix-popper-available-width",`${kt}px`),Pn.setProperty("--radix-popper-available-height",`${fn}px`),Pn.setProperty("--radix-popper-anchor-width",`${Rn}px`),Pn.setProperty("--radix-popper-anchor-height",`${hn}px`)}}),_&&Hj({element:_,padding:a}),Jj({arrowWidth:E,arrowHeight:R}),p&&Wj({strategy:"referenceHidden",...H})]}),[N,z]=$S(B),V=st(x);it(()=>{I&&(V==null||V())},[I,V]);const X=(W=T.arrow)==null?void 0:W.x,ee=(xe=T.arrow)==null?void 0:xe.y,ce=((Me=T.arrow)==null?void 0:Me.centerOffset)!==0,[le,Oe]=m.useState();return it(()=>{w&&Oe(window.getComputedStyle(w).zIndex)},[w]),f.jsx("div",{ref:L.setFloating,"data-radix-popper-content-wrapper":"",style:{...Z,transform:I?Z.transform:"translate(0, -200%)",minWidth:"max-content",zIndex:le,"--radix-popper-transform-origin":[(_e=T.transformOrigin)==null?void 0:_e.x,(we=T.transformOrigin)==null?void 0:we.y].join(" "),...((Se=T.hide)==null?void 0:Se.referenceHidden)&&{visibility:"hidden",pointerEvents:"none"}},dir:e.dir,children:f.jsx(Gj,{scope:n,placedSide:N,onArrowChange:S,arrowX:X,arrowY:ee,shouldHideArrow:ce,children:f.jsx(ne.div,{"data-side":N,"data-align":z,...v,ref:y,style:{...v.style,animation:I?void 0:"none"}})})})});DS.displayName=Ig;var MS="PopperArrow",Zj={top:"bottom",right:"left",bottom:"top",left:"right"},LS=m.forwardRef(function(t,n){const{__scopePopper:r,...s}=t,o=Yj(MS,r),i=Zj[o.placedSide];return f.jsx("span",{ref:o.onArrowChange,style:{position:"absolute",left:o.arrowX,top:o.arrowY,[i]: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:f.jsx(qj,{...s,ref:n,style:{...s.style,display:"block"}})})});LS.displayName=MS;function Qj(e){return e!==null}var Jj=e=>({name:"transformOrigin",options:e,fn(t){var b,w,g;const{placement:n,rects:r,middlewareData:s}=t,i=((b=s.arrow)==null?void 0:b.centerOffset)!==0,a=i?0:e.arrowWidth,l=i?0:e.arrowHeight,[c,u]=$S(n),d={start:"0%",center:"50%",end:"100%"}[u],p=(((w=s.arrow)==null?void 0:w.x)??0)+a/2,h=(((g=s.arrow)==null?void 0:g.y)??0)+l/2;let x="",v="";return c==="bottom"?(x=i?d:`${p}px`,v=`${-l}px`):c==="top"?(x=i?d:`${p}px`,v=`${r.floating.height+l}px`):c==="right"?(x=`${-l}px`,v=i?d:`${h}px`):c==="left"&&(x=`${r.floating.width+l}px`,v=i?d:`${h}px`),{data:{x,y:v}}}});function $S(e){const[t,n="center"]=e.split("-");return[t,n]}var Xj=OS,FS=IS,US=DS,BS=LS,[$d,_z]=Gt("Tooltip",[Ld]),Dg=Ld(),zS="TooltipProvider",eI=700,xw="tooltip.open",[tI,WS]=$d(zS),HS=e=>{const{__scopeTooltip:t,delayDuration:n=eI,skipDelayDuration:r=300,disableHoverableContent:s=!1,children:o}=e,i=m.useRef(!0),a=m.useRef(!1),l=m.useRef(0);return m.useEffect(()=>{const c=l.current;return()=>window.clearTimeout(c)},[]),f.jsx(tI,{scope:t,isOpenDelayedRef:i,delayDuration:n,onOpen:m.useCallback(()=>{window.clearTimeout(l.current),i.current=!1},[]),onClose:m.useCallback(()=>{window.clearTimeout(l.current),l.current=window.setTimeout(()=>i.current=!0,r)},[r]),isPointerInTransitRef:a,onPointerInTransitChange:m.useCallback(c=>{a.current=c},[]),disableHoverableContent:s,children:o})};HS.displayName=zS;var VS="Tooltip",[Sz,Fd]=$d(VS),Mp="TooltipTrigger",nI=m.forwardRef((e,t)=>
vendor: 1,889 bytes, line 157
157{const{__scopeTooltip:n,...r}=e,s=Fd(Mp,n),o=WS(Mp,n),i=Dg(n),a=m.useRef(null),l=de(t,a,s.onTriggerChange),c=m.useRef(!1),u=m.useRef(!1),d=m.useCallback(()=>c.current=!1,[]);return m.useEffect(()=>()=>document.removeEventListener("pointerup",d),[d]),f.jsx(FS,{asChild:!0,...i,children:f.jsx(ne.button,{"aria-describedby":s.open?s.contentId:void 0,"data-state":s.stateAttribute,...r,ref:l,onPointerMove:K(e.onPointerMove,p=>{p.pointerType!=="touch"&&!u.current&&!o.isPointerInTransitRef.current&&(s.onTriggerEnter(),u.current=!0)}),onPointerLeave:K(e.onPointerLeave,()=>{s.onTriggerLeave(),u.current=!1}),onPointerDown:K(e.onPointerDown,()=>{s.open&&s.onClose(),c.current=!0,document.addEventListener("pointerup",d,{once:!0})}),onFocus:K(e.onFocus,()=>{c.current||s.onOpen()}),onBlur:K(e.onBlur,s.onClose),onClick:K(e.onClick,s.onClose)})})});nI.displayName=Mp;var rI="TooltipPortal",[Ez,sI]=$d(rI,{forceMount:void 0}),Hi="TooltipContent",qS=m.forwardRef((e,t)=>{const n=sI(Hi,e.__scopeTooltip),{forceMount:r=n.forceMount,side:s="top",...o}=e,i=Fd(Hi,e.__scopeTooltip);return f.jsx(dn,{present:r||i.open,children:i.disableHoverableContent?f.jsx(KS,{side:s,...o,ref:t}):f.jsx(oI,{side:s,...o,ref:t})})}),oI=m.forwardRef((e,t)=>{const n=Fd(Hi,e.__scopeTooltip),r=WS(Hi,e.__scopeTooltip),s=m.useRef(null),o=de(t,s),[i,a]=m.useState(null),{trigger:l,onClose:c}=n,u=s.current,{onPointerInTransitChange:d}=r,p=m.useCallback(()=>{a(null),d(!1)},[d]),h=m.useCallback((x,v)=>{const b=x.currentTarget,w={x:x.clientX,y:x.clientY},g=uI(w,b.getBoundingClientRect()),y=dI(w,g),_=fI(v.getBoundingClientRect()),S=pI([...y,..._]);a(S),d(!0)},[d]);return m.useEffect(()=>()=>p(),[p]),m.useEffect(()=>{if(l&&u){const x=b=>h(b,u),v=b=>h(b,l);return l.addEventListener("pointerleave",x),u.addEventListener("pointerleave",v),()=>{l.removeEventListener("pointerleave",x),u.removeEventListener("pointerleave",v)}}}
vendor: 5,863 bytes, line 157
157,[l,u,h,p]),m.useEffect(()=>{if(i){const x=v=>{const b=v.target,w={x:v.clientX,y:v.clientY},g=(l==null?void 0:l.contains(b))||(u==null?void 0:u.contains(b)),y=!hI(w,i);g?p():y&&(p(),c())};return document.addEventListener("pointermove",x),()=>document.removeEventListener("pointermove",x)}},[l,u,i,c,p]),f.jsx(KS,{...e,ref:o})}),[iI,aI]=$d(VS,{isInside:!1}),lI=yN("TooltipContent"),KS=m.forwardRef((e,t)=>{const{__scopeTooltip:n,children:r,"aria-label":s,onEscapeKeyDown:o,onPointerDownOutside:i,...a}=e,l=Fd(Hi,n),c=Dg(n),{onClose:u}=l;return m.useEffect(()=>(document.addEventListener(xw,u),()=>document.removeEventListener(xw,u)),[u]),m.useEffect(()=>{if(l.trigger){const d=p=>{const h=p.target;h!=null&&h.contains(l.trigger)&&u()};return window.addEventListener("scroll",d,{capture:!0}),()=>window.removeEventListener("scroll",d,{capture:!0})}},[l.trigger,u]),f.jsx(Ql,{asChild:!0,disableOutsidePointerEvents:!1,onEscapeKeyDown:o,onPointerDownOutside:i,onFocusOutside:d=>d.preventDefault(),onDismiss:u,children:f.jsxs(US,{"data-state":l.stateAttribute,...c,...a,ref:t,style:{...a.style,"--radix-tooltip-content-transform-origin":"var(--radix-popper-transform-origin)","--radix-tooltip-content-available-width":"var(--radix-popper-available-width)","--radix-tooltip-content-available-height":"var(--radix-popper-available-height)","--radix-tooltip-trigger-width":"var(--radix-popper-anchor-width)","--radix-tooltip-trigger-height":"var(--radix-popper-anchor-height)"},children:[f.jsx(lI,{children:r}),f.jsx(iI,{scope:n,isInside:!0,children:f.jsx(UN,{id:l.contentId,role:"tooltip",children:s||r})})]})})});qS.displayName=Hi;var GS="TooltipArrow",cI=m.forwardRef((e,t)=>{const{__scopeTooltip:n,...r}=e,s=Dg(n);return aI(GS,n).isInside?null:f.jsx(BS,{...s,...r,ref:t})});cI.displayName=GS;function uI(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 dI(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 fI(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 hI(e,t){const{x:n,y:r}=e;let s=!1;for(let o=0,i=t.length-1;o<t.length;i=o++){const a=t[o],l=t[i],c=a.x,u=a.y,d=l.x,p=l.y;u>r!=p>r&&n<(d-c)*(r-u)/(p-u)+c&&(s=!s)}return s}function pI(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),mI(t)}function mI(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],i=t[t.length-2];if((o.x-i.x)*(s.y-i.y)>=(o.y-i.y)*(s.x-i.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],i=n[n.length-2];if((o.x-i.x)*(s.y-i.y)>=(o.y-i.y)*(s.x-i.x))n.pop();else break}n.push(s)}return n.pop(),t.length===1&&n.length===1&&t[0].x===n[0].x&&t[0].y===n[0].y?t:t.concat(n)}var gI=HS,YS=qS;const vI=gI,yI=m.forwardRef(({className:e,sideOffset:t=4,...n},r)=>f.jsx(YS,{ref:r,sideOffset:t,className:me("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}));yI.displayName=YS.displayName;var Ud=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(){}},Bd=typeof window>"u"||"Deno"in globalThis;function Ln(){}function wI(e,t){return typeof e=="function"?e(t):e}function bI(e){return typeof e=="number"&&e>=0&&e!==1/0}function xI(e,t){return Math.max(e+(t||0)-Date.now(),0)}function Lp(e,t){return typeof e=="function"?e(t):e}function _I(e,t){return typeof e=="function"?e(t):e}function _w(e,t){const{type:n="all",exact:r,fetchStatus:s,predicate:o,queryKey:i,stale:a}=e;if(i){if(r){if(t.queryHash!==Mg(i,t.options))return!1}else if(!Tl(t.queryKey,i))return!1}if(n!=="all"){const l=t.isActive();if(n==="active"&&!l||n==="inactive"&&l)return!1}return!(typeof a=="boolean"&&t.isStale()!==a||s&&s!==t.state.fetchStatus||o&&!o(t))}function Sw(e,t){const{exact:n,status:r,predicate:s,mutationKey:o}=e;if(o){if(!t.options.mutationKey)return!1;if(n){if(Cl(t.options.mutationKey)!==Cl(o))return!1}else if(!Tl(t.options.mutationKey,o))return!1}return!(r&&t.state.status!==r||s&&!s(t))}function Mg(e,t){return((t==null?void 0:t.queryKeyHashFn)||Cl)(e)}function Cl(e){return JSON.stringify(e,(t,n)=>$p(n)?Object.keys(n).sort().reduce((r,s)=>(r[s]=n[s],r),{}):n)}function Tl(e,t){return e===t?!0:typeof e!=typeof t?!1:e&&t&&typeof e=="object"&&typeof t=="object"?Object.keys(t).every(n=>Tl(e[n],t[n])):!1}function ZS(e,t){if(e===t)return e;const n=Ew(e)&&Ew(t);if(n||$p(e)&&$p(t)){const r=n?e:Object.keys(e),s=r.length,o=n?t:Object.keys(t),i=o.length,a=n?[]:{},l=new Set(r);let c=0;for(let u=0;u<i;u++){const d=n?u:o[u];(!n&&l.has(d)||n)&&e[d]===void 0&&t[d]===void 0?(a[d]=void 0,c++):(a[d]=ZS(e[d],t[d]),a[d]===e[d]&&e[d]!==void 0&&c++)}return s===i&&c===s?e:a}return t}function Ew(e){return Array.isArray(e)&&e.length===Object.keys(e).length}function $p(e){if(!kw(e))return!1;const t=e.constructor;if(t===void 0)return!0;const n=t.prototype;
vendor: 6,136 bytes, line 157
157return!(!kw(n)||!n.hasOwnProperty("isPrototypeOf")||Object.getPrototypeOf(e)!==Object.prototype)}function kw(e){return Object.prototype.toString.call(e)==="[object Object]"}function SI(e){return new Promise(t=>{setTimeout(t,e)})}function EI(e,t,n){return typeof n.structuralSharing=="function"?n.structuralSharing(e,t):n.structuralSharing!==!1?ZS(e,t):t}function kI(e,t,n=0){const r=[...e,t];return n&&r.length>n?r.slice(1):r}function CI(e,t,n=0){const r=[t,...e];return n&&r.length>n?r.slice(0,-1):r}var Lg=Symbol();function QS(e,t){return!e.queryFn&&(t!=null&&t.initialPromise)?()=>t.initialPromise:!e.queryFn||e.queryFn===Lg?()=>Promise.reject(new Error(`Missing queryFn: '${e.queryHash}'`)):e.queryFn}var ho,fs,Ti,rb,TI=(rb=class extends Ud{constructor(){super();Te(this,ho);Te(this,fs);Te(this,Ti);pe(this,Ti,t=>{if(!Bd&&window.addEventListener){const n=()=>t();return window.addEventListener("visibilitychange",n,!1),()=>{window.removeEventListener("visibilitychange",n)}}})}onSubscribe(){j(this,fs)||this.setEventListener(j(this,Ti))}onUnsubscribe(){var t;this.hasListeners()||((t=j(this,fs))==null||t.call(this),pe(this,fs,void 0))}setEventListener(t){var n;pe(this,Ti,t),(n=j(this,fs))==null||n.call(this),pe(this,fs,t(r=>{typeof r=="boolean"?this.setFocused(r):this.onFocus()}))}setFocused(t){j(this,ho)!==t&&(pe(this,ho,t),this.onFocus())}onFocus(){const t=this.isFocused();this.listeners.forEach(n=>{n(t)})}isFocused(){var t;return typeof j(this,ho)=="boolean"?j(this,ho):((t=globalThis.document)==null?void 0:t.visibilityState)!=="hidden"}},ho=new WeakMap,fs=new WeakMap,Ti=new WeakMap,rb),JS=new TI,Ri,hs,Pi,sb,RI=(sb=class extends Ud{constructor(){super();Te(this,Ri,!0);Te(this,hs);Te(this,Pi);pe(this,Pi,t=>{if(!Bd&&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(){j(this,hs)||this.setEventListener(j(this,Pi))}onUnsubscribe(){var t;this.hasListeners()||((t=j(this,hs))==null||t.call(this),pe(this,hs,void 0))}setEventListener(t){var n;pe(this,Pi,t),(n=j(this,hs))==null||n.call(this),pe(this,hs,t(this.setOnline.bind(this)))}setOnline(t){j(this,Ri)!==t&&(pe(this,Ri,t),this.listeners.forEach(r=>{r(t)}))}isOnline(){return j(this,Ri)}},Ri=new WeakMap,hs=new WeakMap,Pi=new WeakMap,sb),Wu=new RI;function PI(){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 NI(e){return Math.min(1e3*2**e,3e4)}function XS(e){return(e??"online")==="online"?Wu.isOnline():!0}var e1=class extends Error{constructor(e){super("CancelledError"),this.revert=e==null?void 0:e.revert,this.silent=e==null?void 0:e.silent}};function Gf(e){return e instanceof e1}function t1(e){let t=!1,n=0,r=!1,s;const o=PI(),i=v=>{var b;r||(p(new e1(v)),(b=e.abort)==null||b.call(e))},a=()=>{t=!0},l=()=>{t=!1},c=()=>JS.isFocused()&&(e.networkMode==="always"||Wu.isOnline())&&e.canRun(),u=()=>XS(e.networkMode)&&e.canRun(),d=v=>{var b;r||(r=!0,(b=e.onSuccess)==null||b.call(e,v),s==null||s(),o.resolve(v))},p=v=>{var b;r||(r=!0,(b=e.onError)==null||b.call(e,v),s==null||s(),o.reject(v))},h=()=>new Promise(v=>{var b;s=w=>{(r||c())&&v(w)},(b=e.onPause)==null||b.call(e)}).then(()=>{var v;s=void 0,r||(v=e.onContinue)==null||v.call(e)}),x=()=>{if(r)return;let v;const b=n===0?e.initialPromise:void 0;try{v=b??e.fn()}catch(w){v=Promise.reject(w)}Promise.resolve(v).then(d).catch(w=>{var k;if(r)return;const g=e.retry??(Bd?0:3),y=e.retryDelay??NI,_=typeof y=="function"?y(n,w):y,S=g===!0||typeof g=="number"&&n<g||typeof g=="function"&&g(n,w);if(t||!S){p(w);return}n++,(k=e.onFail)==null||k.call(e,n,w),SI(_).then(()=>c()?void 0:h()).then(()=>{t?p(w):x()})})};return{promise:o,cancel:i,continue:()=>(s==null||s(),o),cancelRetry:a,continueRetry:l,canStart:u,start:()=>(u()?x():h().then(x),o)}}var AI=e=>setTimeout(e,0);function OI(){let e=[],t=0,n=a=>{a()},r=a=>{a()},s=AI;const o=a=>{t?e.push(a):s(()=>{n(a)})},i=()=>{const a=e;e=[],a.length&&s(()=>{r(()=>{a.forEach(l=>{n(l)})})})};return{batch:a=>{let l;t++;try{l=a()}finally{t--,t||i()}return l},batchCalls:a=>(...l)=>{o(()=>{a(...l)})},schedule:o,setNotifyFunction:a=>{n=a},setBatchNotifyFunction:a=>{r=a},setScheduler:a=>{s=a}}}var Nt=OI(),po,ob,n1=(ob=class{constructor(){Te(this,po)}destroy(){this.clearGcTimeout()}scheduleGc(){this.clearGcTimeout(),bI(this.gcTime)&&pe(this,po,setTimeout(()=>{this.optionalRemove()},this.gcTime))}updateGcTime(e){this.gcTime=Math.max(this.gcTime||0,e??(Bd?1/0:5*60*1e3))}clearGcTimeout(){j(this,po)&&(clearTimeout(j(this,po)),pe(this,po,void 0))}},po=new WeakMap,ob),Ni,mo,yn,go,_t,zl,vo,Fn,Nr,ib,jI=(ib=class extends n1{constructor(t){super();Te(this,Fn);Te(this,Ni);Te(this,mo);Te(this,yn);Te(this,go);Te(this,_t);Te(this,zl);Te(this,vo);pe(this,vo,!1),pe(this,zl,t.defaultOptions),this.setOptions(t.options),this.observers=[],pe(this,go,t.client),pe(this,yn,j(this,go).getQueryCache()),this.queryKey=t.queryKey,this.queryHash=t.queryHash,pe(this,Ni,DI(this.options)),this.state=t.state??j(this,Ni),this.scheduleGc()}get meta(){return this.options.meta}get promise(){var t;return(t=j(this,_t))==null?void 0:t.promise}setOptions(t){this.options={...j(this,zl),...t},this.updateGcTime(this.options.gcTime)}optionalRemove(){!this.observers.length&&this.state.fetchStatus==="idle"&&j(this,yn).remove(this)}setData(t,n){const r=EI(this.state.data,t,this.options);return wt(this,Fn,Nr).call(this,{data:r,type:"success",dataUpdatedAt:n==null?void 0:n.updatedAt,manual:n==null?void 0:n.manual}),r}setState(t,n){wt(this,Fn,Nr).call(this,{type:"setState",state:t,setStateOptions:n})}cancel(t){var r,s;const n=(r=j(this,_t))==null?void 0:r.promise;return(s=j(this,_t))==null||s.cancel(t),n?n.then(Ln).catch(Ln):Promise.resolve()}destroy(){super.destroy(),this.cancel({silent:!0})}reset(){this.destroy(),this.setState(j(this,Ni))}isActive(){return this.observers.some(t=>
vendor: 1,447 bytes, line 157
157_I(t.options.enabled,this)!==!1)}isDisabled(){return this.getObserversCount()>0?!this.isActive():this.options.queryFn===Lg||this.state.dataUpdateCount+this.state.errorUpdateCount===0}isStatic(){return this.getObserversCount()>0?this.observers.some(t=>Lp(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:!xI(this.state.dataUpdatedAt,t)}onFocus(){var n;const t=this.observers.find(r=>r.shouldFetchOnWindowFocus());t==null||t.refetch({cancelRefetch:!1}),(n=j(this,_t))==null||n.continue()}onOnline(){var n;const t=this.observers.find(r=>r.shouldFetchOnReconnect());t==null||t.refetch({cancelRefetch:!1}),(n=j(this,_t))==null||n.continue()}addObserver(t){this.observers.includes(t)||(this.observers.push(t),this.clearGcTimeout(),j(this,yn).notify({type:"observerAdded",query:this,observer:t}))}removeObserver(t){this.observers.includes(t)&&(this.observers=this.observers.filter(n=>n!==t),this.observers.length||(j(this,_t)&&(j(this,vo)?j(this,_t).cancel({revert:!0}):j(this,_t).cancelRetry()),this.scheduleGc()),j(this,yn).notify({type:"observerRemoved",query:this,observer:t}))}getObserversCount(){return this.observers.length}invalidate(){this.state.isInvalidated||wt(this,Fn,Nr).call(this,{type:"invalidate"})}
vendor: 6,533 bytes, line 157
157fetch(t,n){var c,u,d;if(this.state.fetchStatus!=="idle"){if(this.state.data!==void 0&&(n!=null&&n.cancelRefetch))this.cancel({silent:!0});else if(j(this,_t))return j(this,_t).continueRetry(),j(this,_t).promise}if(t&&this.setOptions(t),!this.options.queryFn){const p=this.observers.find(h=>h.options.queryFn);p&&this.setOptions(p.options)}const r=new AbortController,s=p=>{Object.defineProperty(p,"signal",{enumerable:!0,get:()=>(pe(this,vo,!0),r.signal)})},o=()=>{const p=QS(this.options,n),x=(()=>{const v={client:j(this,go),queryKey:this.queryKey,meta:this.meta};return s(v),v})();return pe(this,vo,!1),this.options.persister?this.options.persister(p,x,this):p(x)},a=(()=>{const p={fetchOptions:n,options:this.options,queryKey:this.queryKey,client:j(this,go),state:this.state,fetchFn:o};return s(p),p})();(c=this.options.behavior)==null||c.onFetch(a,this),pe(this,mo,this.state),(this.state.fetchStatus==="idle"||this.state.fetchMeta!==((u=a.fetchOptions)==null?void 0:u.meta))&&wt(this,Fn,Nr).call(this,{type:"fetch",meta:(d=a.fetchOptions)==null?void 0:d.meta});const l=p=>{var h,x,v,b;Gf(p)&&p.silent||wt(this,Fn,Nr).call(this,{type:"error",error:p}),Gf(p)||((x=(h=j(this,yn).config).onError)==null||x.call(h,p,this),(b=(v=j(this,yn).config).onSettled)==null||b.call(v,this.state.data,p,this)),this.scheduleGc()};return pe(this,_t,t1({initialPromise:n==null?void 0:n.initialPromise,fn:a.fetchFn,abort:r.abort.bind(r),onSuccess:p=>{var h,x,v,b;if(p===void 0){l(new Error(`${this.queryHash} data is undefined`));return}try{this.setData(p)}catch(w){l(w);return}(x=(h=j(this,yn).config).onSuccess)==null||x.call(h,p,this),(b=(v=j(this,yn).config).onSettled)==null||b.call(v,p,this.state.error,this),this.scheduleGc()},onError:l,onFail:(p,h)=>{wt(this,Fn,Nr).call(this,{type:"failed",failureCount:p,error:h})},onPause:()=>{wt(this,Fn,Nr).call(this,{type:"pause"})},onContinue:()=>{wt(this,Fn,Nr).call(this,{type:"continue"})},retry:a.options.retry,retryDelay:a.options.retryDelay,networkMode:a.options.networkMode,canRun:()=>!0})),j(this,_t).start()}},Ni=new WeakMap,mo=new WeakMap,yn=new WeakMap,go=new WeakMap,_t=new WeakMap,zl=new WeakMap,vo=new WeakMap,Fn=new WeakSet,Nr=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,...II(r.data,this.options),fetchMeta:t.meta??null};case"success":return pe(this,mo,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 Gf(s)&&s.revert&&j(this,mo)?{...j(this,mo),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),Nt.batch(()=>{this.observers.forEach(r=>{r.onQueryUpdate()}),j(this,yn).notify({query:this,type:"updated",action:t})})},ib);function II(e,t){return{fetchFailureCount:0,fetchFailureReason:null,fetchStatus:XS(t.networkMode)?"fetching":"paused",...e===void 0&&{error:null,status:"pending"}}}function DI(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 ar,ab,MI=(ab=class extends Ud{constructor(t={}){super();Te(this,ar);this.config=t,pe(this,ar,new Map)}build(t,n,r){const s=n.queryKey,o=n.queryHash??Mg(s,n);let i=this.get(o);return i||(i=new jI({client:t,queryKey:s,queryHash:o,options:t.defaultQueryOptions(n),state:r,defaultOptions:t.getQueryDefaults(s)}),this.add(i)),i}add(t){j(this,ar).has(t.queryHash)||(j(this,ar).set(t.queryHash,t),this.notify({type:"added",query:t}))}remove(t){const n=j(this,ar).get(t.queryHash);n&&(t.destroy(),n===t&&j(this,ar).delete(t.queryHash),this.notify({type:"removed",query:t}))}clear(){Nt.batch(()=>{this.getAll().forEach(t=>{this.remove(t)})})}get(t){return j(this,ar).get(t)}getAll(){return[...j(this,ar).values()]}find(t){const n={exact:!0,...t};return this.getAll().find(r=>_w(n,r))}findAll(t={}){const n=this.getAll();return Object.keys(t).length>0?n.filter(r=>_w(t,r)):n}notify(t){Nt.batch(()=>{this.listeners.forEach(n=>{n(t)})})}onFocus(){Nt.batch(()=>{this.getAll().forEach(t=>{t.onFocus()})})}onOnline(){Nt.batch(()=>{this.getAll().forEach(t=>{t.onOnline()})})}},ar=new WeakMap,ab),lr,Tt,yo,cr,rs,lb,LI=(lb=class extends n1{constructor(t){super();Te(this,cr);Te(this,lr);Te(this,Tt);Te(this,yo);this.mutationId=t.mutationId,pe(this,Tt,t.mutationCache),pe(this,lr,[]),this.state=t.state||$I(),this.setOptions(t.options),this.scheduleGc()}setOptions(t){this.options=t,this.updateGcTime(this.options.gcTime)}get meta(){return this.options.meta}addObserver(t){j(this,lr).includes(t)||(j(this,lr).push(t),this.clearGcTimeout(),j(this,Tt).notify({type:"observerAdded",mutation:this,observer:t}))}removeObserver(t){pe(this,lr,j(this,lr).filter(n=>n!==t)),this.scheduleGc(),j(this,Tt).notify({type:"observerRemoved",mutation:this,observer:t})}optionalRemove(){j(this,lr).length||(this.state.status==="pending"?this.scheduleGc():j(this,Tt).remove(this))}continue(){var t;return((t=j(this,yo))==null?void 0:t.continue())??this.execute(this.state.variables)}async execute(t){var o,i,a,l,c,u,d,p,h,x,v,b,w,g,y,_,S,k,E,R;const n=()=>{wt(this,cr,rs).call(this,{type:"continue"})};pe(this,yo,t1({fn:()=>this.options.mutationFn?this.options.mutationFn(t):Promise.reject(new Error("No mutationFn found")),onFail:(P,A)=>{wt(this,cr,rs).call(this,{type:"failed",failureCount:P,error:A})},onPause:()=>{wt(this,cr,rs).call(this,{type:"pause"})},onContinue:n,retry:this.options.retry??0,retryDelay:this.options.retryDelay,networkMode:this.options.networkMode,canRun:()=>j(this,Tt).canRun(this)}));const r=this.state.status==="pending",s=!j(this,yo).canStart();try{if(r)n();else{wt(this,cr,rs).call(this,{type:"pending",variables:t,isPaused:s}),await((i=(o=j(this,Tt).config).onMutate)==null?void 0:i.call(o,t,this));
157const A=await((l=(a=this.options).onMutate)==null?void 0:l.call(a,t));A!==this.state.context&&wt(this,cr,rs).call(this,{type:"pending",context:A,variables:t,isPaused:s})}const P=await j(this,yo).start();return await((u=(c=j(this,Tt).config).onSuccess)==null?void 0:u.call(c,P,t,this.state.context,this)),await((p=(d=this.options).onSuccess)==null?void 0:p.call(d,P,t,this.state.context)),await((x=(h=j(this,Tt).config).onSettled)==null?void 0:x.call(h,P,null,this.state.variables,this.state.context,this)),await((b=(v=this.options).onSettled)==null?void 0:b.call(v,P,null,t,this.state.context)),wt(this,cr,rs).call(this,{type:"success",data:P}),P}catch(P){try{throw await((g=(w=j(this,Tt).config).onError)==null?void 0:g.call(w,P,t,this.state.context,this)),await((_=(y=this.options).onError)==null?void 0:_.call(y,P,t,this.state.context)),await((k=(S=j(this,Tt).config).onSettled)==null?void 0:k.call(S,void 0,P,this.state.variables,this.state.context,this)),await((R=(E=this.options).onSettled)==null?void 0:R.call(E,void 0,P,t,this.state.context)),P}finally{wt(this,cr,rs).call(this,{type:"error",error:P})}}finally{j(this,Tt).runNext(this)}}},lr=new WeakMap,Tt=new WeakMap,yo=new WeakMap,cr=new WeakSet,rs=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),Nt.batch(()=>{j(this,lr).forEach(r=>{r.onMutationUpdate(t)}),j(this,Tt).notify({mutation:this,type:"updated",action:t})})},lb);function $I(){return{context:void 0,data:void 0,error:null,failureCount:0,failureReason:null,isPaused:!1,status:"idle",variables:void 0,submittedAt:0}}var Mr,Un,Wl,cb,FI=(cb=class extends Ud{constructor(t={}){super();Te(this,Mr);Te(this,Un);Te(this,Wl);this.config=t,pe(this,Mr,new Set),pe(this,Un,new Map),pe(this,Wl,0)}build(t,n,r){const s=new LI({mutationCache:this,mutationId:++lc(this,Wl)._,options:t.defaultMutationOptions(n),state:r});return this.add(s),s}add(t){j(this,Mr).add(t);const n=Ac(t);if(typeof n=="string"){const r=j(this,Un).get(n);r?r.push(t):j(this,Un).set(n,[t])}this.notify({type:"added",mutation:t})}remove(t){if(j(this,Mr).delete(t)){const n=Ac(t);if(typeof n=="string"){const r=j(this,Un).get(n);if(r)if(r.length>1){const s=r.indexOf(t);s!==-1&&r.splice(s,1)}else r[0]===t&&j(this,Un).delete(n)}}this.notify({type:"removed",mutation:t})}canRun(t){const n=Ac(t);if(typeof n=="string"){const r=j(this,Un).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=Ac(t);if(typeof n=="string"){const s=(r=j(this,Un).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(){Nt.batch(()=>{j(this,Mr).forEach(t=>{this.notify({type:"removed",mutation:t})}),j(this,Mr).clear(),j(this,Un).clear()})}getAll(){return Array.from(j(this,Mr))}find(t){const n={exact:!0,...t};return this.getAll().find(r=>Sw(n,r))}findAll(t={}){return this.getAll().filter(n=>Sw(t,n))}notify(t){Nt.batch(()=>{this.listeners.forEach(n=>{n(t)})})}resumePausedMutations(){const t=this.getAll().filter(n=>n.state.isPaused);return Nt.batch(()=>Promise.all(t.map(n=>n.continue().catch(Ln))))}},Mr=new WeakMap,Un=new WeakMap,Wl=new WeakMap,cb);function Ac(e){var t;return(t=e.options.scope)==null?void 0:t.id}function Cw(e){return{onFetch:(t,n)=>{var u,d,p,h,x;const r=t.options,s=(p=(d=(u=t.fetchOptions)==null?void 0:u.meta)==null?void 0:d.fetchMore)==null?void 0:p.direction,o=((h=t.state.data)==null?void 0:h.pages)||[],i=((x=t.state.data)==null?void 0:x.pageParams)||[];let a={pages:[],pageParams:[]},l=0;const c=async()=>{let v=!1;const b=y=>{Object.defineProperty(y,"signal",{enumerable:!0,get:()=>(t.signal.aborted?v=!0:t.signal.addEventListener("abort",()=>{v=!0}),t.signal)}
vendor: 8,340 bytes, lines 157-166
157)},w=QS(t.options,t.fetchOptions),g=async(y,_,S)=>{if(v)return Promise.reject();if(_==null&&y.pages.length)return Promise.resolve(y);const E=(()=>{const D={client:t.client,queryKey:t.queryKey,pageParam:_,direction:S?"backward":"forward",meta:t.options.meta};return b(D),D})(),R=await w(E),{maxPages:P}=t.options,A=S?CI:kI;return{pages:A(y.pages,R,P),pageParams:A(y.pageParams,_,P)}};if(s&&o.length){const y=s==="backward",_=y?UI:Tw,S={pages:o,pageParams:i},k=_(r,S);a=await g(S,k,y)}else{const y=e??o.length;do{const _=l===0?i[0]??r.initialPageParam:Tw(r,a);if(l>0&&_==null)break;a=await g(a,_),l++}while(l<y)}return a};t.options.persister?t.fetchFn=()=>{var v,b;return(b=(v=t.options).persister)==null?void 0:b.call(v,c,{client:t.client,queryKey:t.queryKey,meta:t.options.meta,signal:t.signal},n)}:t.fetchFn=c}}}function Tw(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 UI(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 qe,ps,ms,Ai,Oi,gs,ji,Ii,ub,BI=(ub=class{constructor(e={}){Te(this,qe);Te(this,ps);Te(this,ms);Te(this,Ai);Te(this,Oi);Te(this,gs);Te(this,ji);Te(this,Ii);pe(this,qe,e.queryCache||new MI),pe(this,ps,e.mutationCache||new FI),pe(this,ms,e.defaultOptions||{}),pe(this,Ai,new Map),pe(this,Oi,new Map),pe(this,gs,0)}mount(){lc(this,gs)._++,j(this,gs)===1&&(pe(this,ji,JS.subscribe(async e=>{e&&(await this.resumePausedMutations(),j(this,qe).onFocus())})),pe(this,Ii,Wu.subscribe(async e=>{e&&(await this.resumePausedMutations(),j(this,qe).onOnline())})))}unmount(){var e,t;lc(this,gs)._--,j(this,gs)===0&&((e=j(this,ji))==null||e.call(this),pe(this,ji,void 0),(t=j(this,Ii))==null||t.call(this),pe(this,Ii,void 0))}isFetching(e){return j(this,qe).findAll({...e,fetchStatus:"fetching"}).length}isMutating(e){return j(this,ps).findAll({...e,status:"pending"}).length}getQueryData(e){var n;const t=this.defaultQueryOptions({queryKey:e});return(n=j(this,qe).get(t.queryHash))==null?void 0:n.state.data}ensureQueryData(e){const t=this.defaultQueryOptions(e),n=j(this,qe).build(this,t),r=n.state.data;return r===void 0?this.fetchQuery(e):(e.revalidateIfStale&&n.isStaleByTime(Lp(t.staleTime,n))&&this.prefetchQuery(t),Promise.resolve(r))}getQueriesData(e){return j(this,qe).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=j(this,qe).get(r.queryHash),o=s==null?void 0:s.state.data,i=wI(t,o);if(i!==void 0)return j(this,qe).build(this,r).setData(i,{...n,manual:!0})}setQueriesData(e,t,n){return Nt.batch(()=>j(this,qe).findAll(e).map(({queryKey:r})=>[r,this.setQueryData(r,t,n)]))}getQueryState(e){var n;const t=this.defaultQueryOptions({queryKey:e});return(n=j(this,qe).get(t.queryHash))==null?void 0:n.state}removeQueries(e){const t=j(this,qe);Nt.batch(()=>{t.findAll(e).forEach(n=>{t.remove(n)})})}resetQueries(e,t){const n=j(this,qe);return Nt.batch(()=>(n.findAll(e).forEach(r=>{r.reset()}),this.refetchQueries({type:"active",...e},t)))}cancelQueries(e,t={}){const n={revert:!0,...t},r=Nt.batch(()=>j(this,qe).findAll(e).map(s=>s.cancel(n)));return Promise.all(r).then(Ln).catch(Ln)}invalidateQueries(e,t={}){return Nt.batch(()=>(j(this,qe).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=Nt.batch(()=>j(this,qe).findAll(e).filter(s=>!s.isDisabled()&&!s.isStatic()).map(s=>{let o=s.fetch(void 0,n);return n.throwOnError||(o=o.catch(Ln)),s.state.fetchStatus==="paused"?Promise.resolve():o}));return Promise.all(r).then(Ln)}fetchQuery(e){const t=this.defaultQueryOptions(e);t.retry===void 0&&(t.retry=!1);const n=j(this,qe).build(this,t);return n.isStaleByTime(Lp(t.staleTime,n))?n.fetch(t):Promise.resolve(n.state.data)}prefetchQuery(e){return this.fetchQuery(e).then(Ln).catch(Ln)}fetchInfiniteQuery(e){return e.behavior=Cw(e.pages),this.fetchQuery(e)}prefetchInfiniteQuery(e){return this.fetchInfiniteQuery(e).then(Ln).catch(Ln)}ensureInfiniteQueryData(e){return e.behavior=Cw(e.pages),this.ensureQueryData(e)}resumePausedMutations(){return Wu.isOnline()?j(this,ps).resumePausedMutations():Promise.resolve()}getQueryCache(){return j(this,qe)}getMutationCache(){return j(this,ps)}getDefaultOptions(){return j(this,ms)}setDefaultOptions(e){pe(this,ms,e)}setQueryDefaults(e,t){j(this,Ai).set(Cl(e),{queryKey:e,defaultOptions:t})}getQueryDefaults(e){const t=[...j(this,Ai).values()],n={};return t.forEach(r=>{Tl(e,r.queryKey)&&Object.assign(n,r.defaultOptions)}),n}setMutationDefaults(e,t){j(this,Oi).set(Cl(e),{mutationKey:e,defaultOptions:t})}getMutationDefaults(e){const t=[...j(this,Oi).values()],n={};return t.forEach(r=>{Tl(e,r.mutationKey)&&Object.assign(n,r.defaultOptions)}),n}defaultQueryOptions(e){if(e._defaulted)return e;const t={...j(this,ms).queries,...this.getQueryDefaults(e.queryKey),...e,_defaulted:!0};return t.queryHash||(t.queryHash=Mg(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===Lg&&(t.enabled=!1),t}defaultMutationOptions(e){return e!=null&&e._defaulted?e:{...j(this,ms).mutations,...(e==null?void 0:e.mutationKey)&&this.getMutationDefaults(e.mutationKey),...e,_defaulted:!0}}clear(){j(this,qe).clear(),j(this,ps).clear()}},qe=new WeakMap,ps=new WeakMap,ms=new WeakMap,Ai=new WeakMap,Oi=new WeakMap,gs=new WeakMap,ji=new WeakMap,Ii=new WeakMap,ub),zI=m.createContext(void 0),WI=({client:e,children:t})=>(m.useEffect(()=>(e.mount(),()=>{e.unmount()}),[e]),f.jsx(zI.Provider,{value:e,children:t}));/** 158 * @remix-run/router v1.23.0 159 * 160 * Copyright (c) Remix Software Inc. 161 * 162 * This source code is licensed under the MIT license found in the 163 * LICENSE.md file in the root directory of this source tree. 164 * 165 * @license MIT 166 */function Rl(){return Rl=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},Rl.apply(this,arguments)}var ws;(function(e){e.Pop="POP",e.Push="PUSH",e.Replace="REPLACE"})(ws||(ws={}));const Rw="popstate";function HI(e){e===void 0&&(e={});function t(r,s){let{pathname:o,search:i,hash:a}=r.location;return Fp("",{pathname:o,search:i,hash:a},s.state&&s.state.usr||null,s.state&&s.state.key||"default")}function n(r,s){return typeof s=="string"?s:Hu(s)}return qI(t,n,null,e)}function Qe(e,t){if(e===!1||e===null||typeof e>"u")throw new Error(t)}function r1(e,t){if(!e){typeof console<"u"&&console.warn(t);try{throw new Error(t)}catch{}}}function VI(){return Math.random().toString(36).substr(2,8)}function Pw(e,t){return{usr:e.state,key:e.key,idx:t}}function Fp(e,t,n,r){return n===void 0&&(n=null),Rl({pathname:typeof e=="string"?e:e.pathname,search:"",hash:""},typeof t=="string"?ra(t):t,{state:n,key:t&&t.key||r||VI()})}function Hu(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 ra(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 qI(e,t,n,r){r===void 0&&(r={});let{window:s=document.defaultView,v5Compat:o=!1}=r,i=s.history,a=ws.Pop,l=null,c=u();c==null&&(c=0,i.replaceState(Rl({},i.state,{idx:c}),""));function u(){return(i.state||{idx:null}).idx}function d(){a=ws.Pop;let b=u(),w=b==null?null:b-c;c=b,l&&l({action:a,location:v.location,delta:w})}function p(b,w){a=ws.Push;let g=Fp(v.location,b,w);c=u()+1;let y=Pw(g,c),_=v.createHref(g);try{i.pushState(y,"",_)}catch(S){if(S instanceof DOMException&&S.name==="DataCloneError")throw S;s.location.assign(_)}o&&l&&l({action:a,location:v.location,delta:1})}function h(b,w){a=ws.Replace;let g=Fp(v.location,b,w);c=u();let y=Pw(g,c),_=v.createHref(g);i.replaceState(y,"",_),o&&l&&l({action:a,location:v.location,delta:0})}function x(b){let w=s.location.origin!=="null"?s.location.origin:s.location.href,g=typeof b=="string"?b:Hu(b);
vendor: 2,909 bytes, line 166
166return g=g.replace(/ $/,"%20"),Qe(w,"No window.location.(origin|href) available to create URL for href: "+g),new URL(g,w)}let v={get action(){return a},get location(){return e(s,i)},listen(b){if(l)throw new Error("A history only accepts one active listener");return s.addEventListener(Rw,d),l=b,()=>{s.removeEventListener(Rw,d),l=null}},createHref(b){return t(s,b)},createURL:x,encodeLocation(b){let w=x(b);return{pathname:w.pathname,search:w.search,hash:w.hash}},push:p,replace:h,go(b){return i.go(b)}};return v}var Nw;(function(e){e.data="data",e.deferred="deferred",e.redirect="redirect",e.error="error"})(Nw||(Nw={}));function KI(e,t,n){return n===void 0&&(n="/"),GI(e,t,n,!1)}function GI(e,t,n,r){let s=typeof t=="string"?ra(t):t,o=$g(s.pathname||"/",n);if(o==null)return null;let i=s1(e);YI(i);let a=null;for(let l=0;a==null&&l<i.length;++l){let c=iD(o);a=sD(i[l],c,r)}return a}function s1(e,t,n,r){t===void 0&&(t=[]),n===void 0&&(n=[]),r===void 0&&(r="");let s=(o,i,a)=>{let l={relativePath:a===void 0?o.path||"":a,caseSensitive:o.caseSensitive===!0,childrenIndex:i,route:o};l.relativePath.startsWith("/")&&(Qe(l.relativePath.startsWith(r),'Absolute route path "'+l.relativePath+'" nested under path '+('"'+r+'" is not valid. An absolute child route path ')+"must start with the combined path of all its parent routes."),l.relativePath=l.relativePath.slice(r.length));let c=Ps([r,l.relativePath]),u=n.concat(l);o.children&&o.children.length>0&&(Qe(o.index!==!0,"Index routes must not have child routes. Please remove "+('all child routes from route path "'+c+'".')),s1(o.children,t,u,c)),!(o.path==null&&!o.index)&&t.push({path:c,score:nD(c,o.index),routesMeta:u})};return e.forEach((o,i)=>{var a;if(o.path===""||!((a=o.path)!=null&&a.includes("?")))s(o,i);else for(let l of o1(o.path))s(o,i,l)}),t}function o1(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 i=o1(r.join("/")),a=[];return a.push(...i.map(l=>l===""?o:[o,l].join("/"))),s&&a.push(...i),a.map(l=>e.startsWith("/")&&l===""?"/":l)}function YI(e){e.sort((t,n)=>t.score!==n.score?n.score-t.score:rD(t.routesMeta.map(r=>r.childrenIndex),n.routesMeta.map(r=>r.childrenIndex)))}const ZI=/^:[\w-]+$/,QI=3,JI=2,XI=1,eD=10,tD=-2,Aw=e=>e==="*";function nD(e,t){let n=e.split("/"),r=n.length;return n.some(Aw)&&(r+=tD),t&&(r+=JI),n.filter(s=>!Aw(s)).reduce((s,o)=>s+(ZI.test(o)?QI:o===""?XI:eD),r)}function rD(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 sD(e,t,n){let{routesMeta:r}=e,s={},o="/",i=[];for(let a=0;a<r.length;++a){let l=r[a],c=a===r.length-1,u=o==="/"?t:t.slice(o.length)||"/",d=Ow({path:l.relativePath,caseSensitive:l.caseSensitive,end:c},u),p=l.route;if(!d&&c&&n&&!r[r.length-1].route.index&&(d=Ow({path:l.relativePath,caseSensitive:l.caseSensitive,end:!1},u)),!d)return null;
vendor: 9,263 bytes, lines 166-175
166Object.assign(s,d.params),i.push({params:s,pathname:Ps([o,d.pathname]),pathnameBase:uD(Ps([o,d.pathnameBase])),route:p}),d.pathnameBase!=="/"&&(o=Ps([o,d.pathnameBase]))}return i}function Ow(e,t){typeof e=="string"&&(e={path:e,caseSensitive:!1,end:!0});let[n,r]=oD(e.path,e.caseSensitive,e.end),s=t.match(n);if(!s)return null;let o=s[0],i=o.replace(/(.)\/+$/,"$1"),a=s.slice(1);return{params:r.reduce((c,u,d)=>{let{paramName:p,isOptional:h}=u;if(p==="*"){let v=a[d]||"";i=o.slice(0,o.length-v.length).replace(/(.)\/+$/,"$1")}const x=a[d];return h&&!x?c[p]=void 0:c[p]=(x||"").replace(/%2F/g,"/"),c},{}),pathname:o,pathnameBase:i,pattern:e}}function oD(e,t,n){t===void 0&&(t=!1),n===void 0&&(n=!0),r1(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,(i,a,l)=>(r.push({paramName:a,isOptional:l!=null}),l?"/?([^\\/]+)?":"/([^\\/]+)"));return e.endsWith("*")?(r.push({paramName:"*"}),s+=e==="*"||e==="/*"?"(.*)$":"(?:\\/(.+)|\\/*)$"):n?s+="\\/*$":e!==""&&e!=="/"&&(s+="(?:(?=\\/|$))"),[new RegExp(s,t?void 0:"i"),r]}function iD(e){try{return e.split("/").map(t=>decodeURIComponent(t).replace(/\//g,"%2F")).join("/")}catch(t){return r1(!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 $g(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 aD(e,t){t===void 0&&(t="/");let{pathname:n,search:r="",hash:s=""}=typeof e=="string"?ra(e):e;return{pathname:n?n.startsWith("/")?n:lD(n,t):t,search:dD(r),hash:fD(s)}}function lD(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 Yf(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 cD(e){return e.filter((t,n)=>n===0||t.route.path&&t.route.path.length>0)}function Fg(e,t){let n=cD(e);return t?n.map((r,s)=>s===n.length-1?r.pathname:r.pathnameBase):n.map(r=>r.pathnameBase)}function Ug(e,t,n,r){r===void 0&&(r=!1);let s;typeof e=="string"?s=ra(e):(s=Rl({},e),Qe(!s.pathname||!s.pathname.includes("?"),Yf("?","pathname","search",s)),Qe(!s.pathname||!s.pathname.includes("#"),Yf("#","pathname","hash",s)),Qe(!s.search||!s.search.includes("#"),Yf("#","search","hash",s)));let o=e===""||s.pathname==="",i=o?"/":s.pathname,a;if(i==null)a=n;else{let d=t.length-1;if(!r&&i.startsWith("..")){let p=i.split("/");for(;p[0]==="..";)p.shift(),d-=1;s.pathname=p.join("/")}a=d>=0?t[d]:"/"}let l=aD(s,a),c=i&&i!=="/"&&i.endsWith("/"),u=(o||i===".")&&n.endsWith("/");return!l.pathname.endsWith("/")&&(c||u)&&(l.pathname+="/"),l}const Ps=e=>e.join("/").replace(/\/\/+/g,"/"),uD=e=>e.replace(/\/+$/,"").replace(/^\/*/,"/"),dD=e=>!e||e==="?"?"":e.startsWith("?")?e:"?"+e,fD=e=>!e||e==="#"?"":e.startsWith("#")?e:"#"+e;function hD(e){return e!=null&&typeof e.status=="number"&&typeof e.statusText=="string"&&typeof e.internal=="boolean"&&"data"in e}const i1=["post","put","patch","delete"];new Set(i1);const pD=["get",...i1];new Set(pD);/** 167 * React Router v6.30.1 168 * 169 * Copyright (c) Remix Software Inc. 170 * 171 * This source code is licensed under the MIT license found in the 172 * LICENSE.md file in the root directory of this source tree. 173 * 174 * @license MIT 175 */function Pl(){return Pl=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},Pl.apply(this,arguments)}const Bg=m.createContext(null),mD=m.createContext(null),Ws=m.createContext(null),zd=m.createContext(null),Yr=m.createContext({outlet:null,matches:[],isDataRoute:!1}),a1=m.createContext(null);function gD(e,t){let{relative:n}=t===void 0?{}:t;sa()||Qe(!1);let{basename:r,navigator:s}=m.useContext(Ws),{hash:o,pathname:i,search:a}=c1(e,{relative:n}),l=i;return r!=="/"&&(l=i==="/"?r:Ps([r,i])),s.createHref({pathname:l,search:a,hash:o})}function sa(){return m.useContext(zd)!=null}function Hs(){return sa()||Qe(!1),m.useContext(zd).location}function l1(e){m.useContext(Ws).static||m.useLayoutEffect(e)}function Do(){let{isDataRoute:e}=m.useContext(Yr);return e?PD():vD()}function vD(){sa()||Qe(!1);let e=m.useContext(Bg),{basename:t,future:n,navigator:r}=m.useContext(Ws),{matches:s}=m.useContext(Yr),{pathname:o}=Hs(),i=JSON.stringify(Fg(s,n.v7_relativeSplatPath)),a=m.useRef(!1);return l1(()=>{a.current=!0}),m.useCallback(function(c,u){if(u===void 0&&(u={}),!a.current)return;if(typeof c=="number"){r.go(c);return}let d=Ug(c,JSON.parse(i),o,u.relative==="path");e==null&&t!=="/"&&(d.pathname=d.pathname==="/"?t:Ps([t,d.pathname])),(u.replace?r.replace:r.push)(d,u.state,u)},[t,r,i,o,e])}function kz(){let{matches:e}=m.useContext(Yr),t=e[e.length-1];return t?t.params:{}}function c1(e,t){let{relative:n}=t===void 0?{}:t,{future:r}=m.useContext(Ws),{matches:s}=m.useContext(Yr),{pathname:o}=Hs(),i=JSON.stringify(Fg(s,r.v7_relativeSplatPath));return m.useMemo(()=>Ug(e,JSON.parse(i),o,n==="path"),[e,i,o,n])}function yD(e,t){return wD(e,t)}function wD(e,t,n,r){sa()||Qe(!1);let{navigator:s}=m.useContext(Ws),{matches:o}=m.useContext(Yr),i=o[o.length-1],a=i?i.params:{};i&&i.pathname;let l=i?i.pathnameBase:"/";i&&i.route;let c=Hs(),u;if(t){var d;let b=typeof t=="string"?ra(t):t;l==="/"||(d=b.pathname)!=null&&d.startsWith(l)||Qe(!1),u=b}else u=c;let p=u.pathname||"/",h=p;if(l!=="/"){let b=l.replace(/^\//,"").split("/");h="/"+p.replace(/^\//,"").split("/").slice(b.length).join("/")}let x=KI(e,{pathname:h}),v=ED(x&&x.map(b=>Object.assign({},b,{params:Object.assign({},a,b.params),pathname:Ps([l,s.encodeLocation?s.encodeLocation(b.pathname).pathname:b.pathname]),pathnameBase:b.pathnameBase==="/"?l:Ps([l,s.encodeLocation?s.encodeLocation(b.pathnameBase).pathname:b.pathnameBase])})),o,n,r);return t&&v?m.createElement(zd.Provider,{value:{location:Pl({pathname:"/",search:"",hash:"",state:null,key:"default"},u),navigationType:ws.Pop}},v):v}function bD(){let e=RD(),t=hD(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 m.createElement(m.Fragment,null,m.createElement("h2",null,"Unexpected Application Error!"),m.createElement("h3",{style:{fontStyle:"italic"}},t),n?m.createElement("pre",{style:s},n):null,null)}const xD=m.createElement(bD,null);class _D extends m.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?m.createElement(Yr.Provider,{value:this.props.routeContext},m.createElement(a1.Provider,{value:this.state.error,children:this.props.component})):this.props.children}}function SD(e){let{routeContext:t,match:n,children:r}=e,s=m.useContext(Bg);return s&&s.static&&s.staticContext&&(n.route.errorElement||n.route.ErrorBoundary)&&(s.staticContext._deepestRenderedBoundaryId=n.route.id),m.createElement(Yr.Provider,{value:t},r)}function ED(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 i=e,a=(s=n)==null?void 0:s.errors;if(a!=null){let u=i.findIndex(d=>d.route.id&&(a==null?void 0:a[d.route.id])!==void 0);u>=0||Qe(!1),i=i.slice(0,Math.min(i.length,u+1))}let l=!1,c=-1;if(n&&r&&r.v7_partialHydration)for(let u=0;u<i.length;u++){let d=i[u];if((d.route.HydrateFallback||d.route.hydrateFallbackElement)&&(c=u),d.route.id){let{loaderData:p,errors:h}=n,x=d.route.loader&&p[d.route.id]===void 0&&(!h||h[d.route.id]===void 0);if(d.route.lazy||x){l=!0,c>=0?i=i.slice(0,c+1):i=[i[0]];break}}}return i.reduceRight((u,d,p)=>{let h,x=!1,v=null,b=null;n&&(h=a&&d.route.id?a[d.route.id]:void 0,v=d.route.errorElement||xD,l&&(c<0&&p===0?(x=!0,b=null):c===p&&(x=!0,b=d.route.hydrateFallbackElement||null)));let w=t.concat(i.slice(0,p+1)),g=()=>{let y;return h?y=v:x?y=b:d.route.Component?y=m.createElement(d.route.Component,null):d.route.element?y=d.route.element:y=u,m.createElement(SD,{match:d,routeC
175ontext:{outlet:u,matches:w,isDataRoute:n!=null},children:y})};return n&&(d.route.ErrorBoundary||d.route.errorElement||p===0)?m.createElement(_D,{location:n.location,revalidation:n.revalidation,component:v,error:h,children:g(),routeContext:{outlet:null,matches:w,isDataRoute:!0}}):g()},null)}var u1=function(e){return e.UseBlocker="useBlocker",e.UseRevalidator="useRevalidator",e.UseNavigateStable="useNavigate",e}(u1||{}),Vu=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}(Vu||{});function kD(e){let t=m.useContext(Bg);return t||Qe(!1),t}function CD(e){let t=m.useContext(mD);return t||Qe(!1),t}function TD(e){let t=m.useContext(Yr);return t||Qe(!1),t}function d1(e){let t=TD(),n=t.matches[t.matches.length-1];return n.route.id||Qe(!1),n.route.id}function RD(){var e;let t=m.useContext(a1),n=CD(Vu.UseRouteError),r=d1(Vu.UseRouteError);return t!==void 0?t:(e=n.errors)==null?void 0:e[r]}function PD(){let{router:e}=kD(u1.UseNavigateStable),t=d1(Vu.UseNavigateStable),n=m.useRef(!1);return l1(()=>{n.current=!0}),m.useCallback(function(s,o){o===void 0&&(o={}),n.current&&(typeof s=="number"?e.navigate(s):e.navigate(s,Pl({fromRouteId:t},o)))},[e,t])}function ND(e,t){e==null||e.v7_startTransition,e==null||e.v7_relativeSplatPath}function AD(e){let{to:t,replace:n,state:r,relative:s}=e;sa()||Qe(!1);let{future:o,static:i}=m.useContext(Ws),{matches:a}=m.useContext(Yr),{pathname:l}=Hs(),c=Do(),u=Ug(t,Fg(a,o.v7_relativeSplatPath),l,s==="path"),d=JSON.stringify(u);return m.useEffect(()=>c(JSON.parse(d),{replace:n,state:r,relative:s}),[c,d,s,n,r]),null}function Qt(e){Qe(!1)}function OD(e){let{basename:t="/",children:n=null,location:r,navigationType:s=ws.Pop,navigator:o,static:i=!1,future:a}=e;sa()&&Qe(!1);let l=t.replace(/^\/*/,"/"),c=m.useMemo(()=>({basename:l,navigator:o,static:i,future:Pl({v7_relativeSplatPath:!1},a)}),[l,a,o,i]);typeof r=="string"&&(r=ra(r));let{pathname:u="/",search:d="",hash:p="",state:h=null,key:x="default"}=r,v=m.useMemo(()=>{let b=$g(u,l);return b==null?null:{location:{pathname:b,search:d,hash:p,state:h,key:x},navigationType:s}},[l,u,d,p,h,x,s]);return v==null?null:m.createElement(Ws.Provider,{value:c},m.createElement(zd.Provider,{children:n,value:v}))}function jD(e){let{children:t,location:n}=e;return yD(Up(t),n)}new Promise(()=>{});function Up(e,t){t===void 0&&(t=[]);let n=[];return m.Children.forEach(e,(r,s)=>{if(!m.isValidElement(r))return;let o=[...t,s];if(r.type===m.Fragment){n.push.apply(n,Up(r.props.children,o));return}r.type!==Qt&&Qe(!1),!r.props.index||!r.props.children||Qe(!1);let i={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&&(i.children=Up(r.props.children,o)),n.push(i)}),n}/** 176 * React Router DOM v6.30.1 177 * 178 * Copyright (c) Remix Software Inc. 179 * 180 * This source code is licensed under the MIT license found in the 181 * LICENSE.md file in the root directory of this source tree. 182 * 183 * @license MIT 184 */function Bp(){return Bp=Object.assign?Object.assign.bind():function(e){for(var t=1;t<arguments.length;t++){var n=arguments[t];for(var r in n)Object.prototype.hasOwnProperty.call(n,r)&&(e[r]=n[r])}return e},Bp.apply(this,arguments)}function ID(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 DD(e){return!!(e.metaKey||e.altKey||e.ctrlKey||e.shiftKey)}function MD(e,t){return e.button===0&&(!t||t==="_self")&&!DD(e)}function zp(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 LD(e,t){let n=zp(e);return t&&t.forEach((r,s)=>
184{n.has(s)||t.getAll(s).forEach(o=>{n.append(s,o)})}),n}const $D=["onClick","relative","reloadDocument","replace","state","target","to","preventScrollReset","viewTransition"],FD="6";try{window.__reactRouterVersion=FD}catch{}const UD="startTransition",jw=Pm[UD];function BD(e){let{basename:t,children:n,future:r,window:s}=e,o=m.useRef();o.current==null&&(o.current=HI({window:s,v5Compat:!0}));let i=o.current,[a,l]=m.useState({action:i.action,location:i.location}),{v7_startTransition:c}=r||{},u=m.useCallback(d=>{c&&jw?jw(()=>l(d)):l(d)},[l,c]);return m.useLayoutEffect(()=>i.listen(u),[i,u]),m.useEffect(()=>ND(r),[r]),m.createElement(OD,{basename:t,children:n,location:a.location,navigationType:a.action,navigator:i,future:r})}const zD=typeof window<"u"&&typeof window.document<"u"&&typeof window.document.createElement<"u",WD=/^(?:[a-z][a-z0-9+.-]*:|\/\/)/i,Cz=m.forwardRef(function(t,n){let{onClick:r,relative:s,reloadDocument:o,replace:i,state:a,target:l,to:c,preventScrollReset:u,viewTransition:d}=t,p=ID(t,$D),{basename:h}=m.useContext(Ws),x,v=!1;if(typeof c=="string"&&WD.test(c)&&(x=c,zD))try{let y=new URL(window.location.href),_=c.startsWith("//")?new URL(y.protocol+c):new URL(c),S=$g(_.pathname,h);_.origin===y.origin&&S!=null?c=S+_.search+_.hash:v=!0}catch{}let b=gD(c,{relative:s}),w=HD(c,{replace:i,state:a,target:l,preventScrollReset:u,relative:s,viewTransition:d});function g(y){r&&r(y),y.defaultPrevented||w(y)}return m.createElement("a",Bp({},p,{href:x||b,onClick:v||o?r:g,ref:n,target:l}))});var Iw;(function(e){e.UseScrollRestoration="useScrollRestoration",e.UseSubmit="useSubmit",e.UseSubmitFetcher="useSubmitFetcher",e.UseFetcher="useFetcher",e.useViewTransitionState="useViewTransitionState"})(Iw||(Iw={}));var Dw;(function(e){e.UseFetcher="useFetcher",e.UseFetchers="useFetchers",e.UseScrollRestoration="useScrollRestoration"})(Dw||(Dw={}));function HD(e,t){let{target:n,replace:r,state:s,preventScrollReset:o,relative:i,viewTransition:a}=t===void 0?{}:t,l=Do(),c=Hs(),u=c1(e,{relative:i});return m.useCallback(d=>{if(MD(d,n)){d.preventDefault();let p=r!==void 0?r:Hu(c)===Hu(u);l(e,{replace:p,state:s,preventScrollReset:o,relative:i,viewTransition:a})}},[c,l,u,r,s,n,e,o,i,a])}function Tz(e){let t=m.useRef(zp(e)),n=m.useRef(!1),r=Hs(),s=m.useMemo(()=>LD(r.search,n.current?null:t.current),[r.search]),o=Do(),i=m.useCallback((a,l)=>{const c=zp(typeof a=="function"?a(s):a);n.current=!0,o("?"+c,l)},[o,s]);return[s,i]}function Nl(e,[t,n]){return Math.min(n,Math.max(t,e))}var VD=m.createContext(void 0);function oa(e){const t=m.useContext(VD);return e||t||"ltr"}function Wd(e){const t=m.useRef({value:e,previous:e});return m.useMemo(()=>(t.current.value!==e&&(t.current.previous=t.current.value,t.current.value=e),t.current.previous),[e])}var f1=["PageUp","PageDown"],h1=["ArrowUp","ArrowDown","ArrowLeft","ArrowRight"],p1={"from-left":["Home","PageDown","ArrowDown","ArrowLeft"],"from-right":["Home","PageDown","ArrowDown","ArrowRight"],"from-bottom":["Home","PageDown","ArrowDown","ArrowLeft"],"from-top":["Home","PageDown","ArrowUp","ArrowLeft"]},ia="Slider",[Wp,qD,KD]=Zl(ia),[m1,Rz]=Gt(ia,[KD]),[GD,Hd]=m1(ia),g1=m.forwardRef((e,t)=>{const{name:n,min:r=0,max:s=100,step:o=1,orientation:i="horizontal",disabled:a=!1,minStepsBetweenThumbs:l=0,defaultValue:c=[r],value:u,onValueChange:d=()=>{},onValueCommit:p=()=>{},inverted:h=!1,form:x,...v}=e,b=m.useRef(new Set),w=m.useRef(0),y=i==="horizontal"?YD:ZD,[_=[],S]=Gn({prop:u,defaultProp:c,onChange:D=>{var H;(H=[...b.current][w.current])==null||H.focus(),d(D)}}),k=m.useRef(_);function E(D){const M=t2(_,D);A(D,M)}function R(D){A(D,w.current)}function P(){const D=k.current[w.current];_[w.current]!==D&&p(_)}function A(D,M,{commit:H}={commit:!1}){const L=o2(o),Z=i2(Math.round((D-r)/o)*o+r,L),B=Nl(Z,[r,s]);S((I=[])=>{const T=XD(I,B,M);if(s2(T,l*o)){w.current=T.indexOf(B);const N=String(T)!==String(I);return N&&H&&p(T),N?T:I}else return I})}return f.jsx(GD,{scope:e.__scopeSlider,name:n,disabled:a,min:r,max:s,valueIndexToChangeRef:w,thumbs:b.current,values:_,orientation:i,form:x,children:f.jsx(Wp.Provider,{scope:e.__scopeSlider,children:f.jsx(Wp.Slot,{scope:e.__scopeSlider,children:f.jsx(y,{"aria-disabled":a,"data-disabled":a?"":void 0,...v,ref:t,onPointerDown:K(v.onPointerDown,()=>{a||(k.current=_)}),min:r,max:s,inverted:h,onSlideStart:a?void 0:E,onSlideMove:a?void 0:R,onSlideEnd:a?void 0:P,onHomeKeyDown:()=>!a&&A(r,0,{commit:!0}),onEndKeyDown:()=>!a&&A(s,_.length-1,{commit:!0}),onStepKeyDown:({event:D,direction:M})=>{if(!a){const Z=f1.includes(D.key)||D.shiftKey&&h1.includes(D.key)?10:1,B=w.current,I=_[B],T=o*Z*M;A(I+T,B,{commit:!0})}}})})})})});g1.displayName=ia;var[v1,y1]=m1(ia,{startEdge:"left",endEdge:"right",size:"width",direction:1}),YD=m.forwardRef((e,t)=>
184{const{min:n,max:r,dir:s,inverted:o,onSlideStart:i,onSlideMove:a,onSlideEnd:l,onStepKeyDown:c,...u}=e,[d,p]=m.useState(null),h=de(t,y=>p(y)),x=m.useRef(void 0),v=oa(s),b=v==="ltr",w=b&&!o||!b&&o;function g(y){const _=x.current||d.getBoundingClientRect(),S=[0,_.width],E=zg(S,w?[n,r]:[r,n]);return x.current=_,E(y-_.left)}return f.jsx(v1,{scope:e.__scopeSlider,startEdge:w?"left":"right",endEdge:w?"right":"left",direction:w?1:-1,size:"width",children:f.jsx(w1,{dir:v,"data-orientation":"horizontal",...u,ref:h,style:{...u.style,"--radix-slider-thumb-transform":"translateX(-50%)"},onSlideStart:y=>{const _=g(y.clientX);i==null||i(_)},onSlideMove:y=>{const _=g(y.clientX);a==null||a(_)},onSlideEnd:()=>{x.current=void 0,l==null||l()},onStepKeyDown:y=>{const S=p1[w?"from-left":"from-right"].includes(y.key);c==null||c({event:y,direction:S?-1:1})}})})}),ZD=m.forwardRef((e,t)=>{const{min:n,max:r,inverted:s,onSlideStart:o,onSlideMove:i,onSlideEnd:a,onStepKeyDown:l,...c}=e,u=m.useRef(null),d=de(t,u),p=m.useRef(void 0),h=!s;function x(v){const b=p.current||u.current.getBoundingClientRect(),w=[0,b.height],y=zg(w,h?[r,n]:[n,r]);return p.current=b,y(v-b.top)}return f.jsx(v1,{scope:e.__scopeSlider,startEdge:h?"bottom":"top",endEdge:h?"top":"bottom",size:"height",direction:h?1:-1,children:f.jsx(w1,{"data-orientation":"vertical",...c,ref:d,style:{...c.style,"--radix-slider-thumb-transform":"translateY(50%)"},onSlideStart:v=>{const b=x(v.clientY);o==null||o(b)},onSlideMove:v=>{const b=x(v.clientY);i==null||i(b)},onSlideEnd:()=>{p.current=void 0,a==null||a()},onStepKeyDown:v=>{const w=p1[h?"from-bottom":"from-top"].includes(v.key);l==null||l({event:v,direction:w?-1:1})}})})}),w1=m.forwardRef((e,t)=>{const{__scopeSlider:n,onSlideStart:r,onSlideMove:s,onSlideEnd:o,onHomeKeyDown:i,onEndKeyDown:a,onStepKeyDown:l,...c}=e,u=Hd(ia,n);return f.jsx(ne.span,{...c,ref:t,onKeyDown:K(e.onKeyDown,d=>{d.key==="Home"?(i(d),d.preventDefault()):d.key==="End"?(a(d),d.preventDefault()):f1.concat(h1).includes(d.key)&&(l(d),d.preventDefault())}),onPointerDown:K(e.onPointerDown,d=>{const p=d.target;p.setPointerCapture(d.pointerId),d.preventDefault(),u.thumbs.has(p)?p.focus():r(d)}),onPointerMove:K(e.onPointerMove,d=>{d.target.hasPointerCapture(d.pointerId)&&s(d)}),onPointerUp:K(e.onPointerUp,d=>{const p=d.target;p.hasPointerCapture(d.pointerId)&&(p.releasePointerCapture(d.pointerId),o(d))})})}),b1="SliderTrack",x1=m.forwardRef((e,t)=>{const{__scopeSlider:n,...r}=e,s=Hd(b1,n);return f.jsx(ne.span,{"data-disabled":s.disabled?"":void 0,"data-orientation":s.orientation,...r,ref:t})});x1.displayName=b1;var Hp="SliderRange",_1=m.forwardRef((e,t)=>{const{__scopeSlider:n,...r}=e,s=Hd(Hp,n),o=y1(Hp,n),i=m.useRef(null),a=de(t,i),l=s.values.length,c=s.values.map(p=>k1(p,s.min,s.max)),u=l>1?Math.min(...c):0,d=100-Math.max(...c);return f.jsx(ne.span,{"data-orientation":s.orientation,"data-disabled":s.disabled?"":void 0,...r,ref:a,style:{...e.style,[o.startEdge]:u+"%",[o.endEdge]:d+"%"}})});_1.displayName=Hp;var Vp="SliderThumb",S1=m.forwardRef((e,t)=>{const n=qD(e.__scopeSlider),[r,s]=m.useState(null),o=de(t,a=>s(a)),i=m.useMemo(()=>r?n().findIndex(a=>a.ref.current===r):-1,[n,r]);return f.jsx(QD,{...e,ref:o,index:i})}),QD=m.forwardRef((e,t)=>{const{__scopeSlider:n,index:r,name:s,...o}=e,i=Hd(Vp,n),a=y1(Vp,n),[l,c]=m.useState(null),u=de(t,g=>c(g)),d=l?i.form||!!l.closest("form"):!0,p=Md(l),h=i.values[r],x=h===void 0?0:k1(h,i.min,i.max),v=e2(r,i.values.length),b=p==null?void 0:p[a.size],w=b?n2(b,x,a.direction):0;return m.useEffect(()=>{if(l)return i.thumbs.add(l),()=>{i.thumbs.delete(l)}},[l,i.thumbs]),f.jsxs("span",{style:{transform:"var(--radix-slider-thumb-transform)",position:"absolute",[a.startEdge]:`calc(${x}% + ${w}px)`},children:[f.jsx(Wp.ItemSlot,{scope:e.__scopeSlider,children:f.jsx(ne.span,{role:"slider","aria-label":e["aria-label"]||v,"aria-valuemin":i.min,"aria-valuenow":h,"aria-valuemax":i.max,"aria-orientation":i.orientation,"data-orientation":i.orientation,"data-disabled":i.disabled?"":void 0,tabIndex:i.disabled?void 0:0,...o,ref:u,style:h===void 0?{display:"none"}:e.style,onFocus:K(e.onFocus,()=>{i.valueIndexToChangeRef.current=r})})}),d&&f.jsx(E1,{name:s??(i.name?i.name+(i.values.length>1?"[]":""):void 0),form:i.form,value:h},r)]})});S1.displayName=Vp;var JD="RadioBubbleInput",E1=m.forwardRef(({__scopeSlider:e,value:t,...n},r)=>{const s=m.useRef(null),o=de(s,r),i=Wd(t);return m.useEffect(()=>{const a=s.current;if(!a)return;const l=window.HTMLInputElement.prototype,u=Object.getOwnPropertyDescriptor(l,"value").set;if(i!==t&&u){const d=new Event("input",{bubbles:!0});u.call(a,t),a.dispatchEvent(d)}},[i,t]),f.jsx(ne.input,{style:{display:"none"},...n,ref:o,defaultValue:t})});E1.displayName=JD;function XD(e=[],t,n){const r=[...e];return r[n]=t,r.sort((s,o)=>s-o)}function k1(e,t,n){const o=100/(n-t)*(e-t);return Nl(o,[0,100])}function e2(e,t){return t>2?`Value ${e+1} of ${t}`:t===2?["Minimum","Maximum"][e]:void 0}function t2(e,t){if(e.length===1)return 0;const n=e.map(s=>
184Math.abs(s-t)),r=Math.min(...n);return n.indexOf(r)}function n2(e,t,n){const r=e/2,o=zg([0,50],[0,r]);return(r-o(t)*n)*n}function r2(e){return e.slice(0,-1).map((t,n)=>e[n+1]-t)}function s2(e,t){if(t>0){const n=r2(e);return Math.min(...n)>=t}return!0}function zg(e,t){return n=>{if(e[0]===e[1]||t[0]===t[1])return t[0];const r=(t[1]-t[0])/(e[1]-e[0]);return t[0]+r*(n-e[0])}}function o2(e){return(String(e).split(".")[1]||"").length}function i2(e,t){const n=Math.pow(10,t);return Math.round(e*n)/n}var C1=g1,a2=x1,l2=_1,c2=S1;const T1=m.forwardRef(({className:e,...t},n)=>f.jsxs(C1,{ref:n,className:me("relative flex w-full touch-none select-none items-center",e),...t,children:[f.jsx(a2,{className:"relative h-2 w-full grow overflow-hidden rounded-full bg-secondary",children:f.jsx(l2,{className:"absolute h-full bg-primary"})}),f.jsx(c2,{className:"block h-5 w-5 rounded-full border-2 border-primary bg-background ring-offset-background transition-colors focus-visible:outline-none focus-visible:ring-2 focus-visible:ring-ring focus-visible:ring-offset-2 disabled:pointer-events-none disabled:opacity-50"})]}));T1.displayName=C1.displayName;var Vd="Checkbox",[u2,Pz]=Gt(Vd),[d2,Wg]=u2(Vd);function f2(e){const{__scopeCheckbox:t,checked:n,children:r,defaultChecked:s,disabled:o,form:i,name:a,onCheckedChange:l,required:c,value:u="on",internal_do_not_use_render:d}=e,[p,h]=Gn({prop:n,defaultProp:s??!1,onChange:l,caller:Vd}),[x,v]=m.useState(null),[b,w]=m.useState(null),g=m.useRef(!1),y=x?!!i||!!x.closest("form"):!0,_={checked:p,disabled:o,setChecked:h,control:x,setControl:v,name:a,form:i,value:u,hasConsumerStoppedPropagationRef:g,required:c,defaultChecked:Ns(s)?!1:s,isFormControl:y,bubbleInput:b,setBubbleInput:w};return f.jsx(d2,{scope:t,..._,children:h2(d)?d(_):r})}var R1="CheckboxTrigger",P1=m.forwardRef(({__scopeCheckbox:e,onKeyDown:t,onClick:n,...r},s)=>{const{control:o,value:i,disabled:a,checked:l,required:c,setControl:u,setChecked:d,hasConsumerStoppedPropagationRef:p,isFormControl:h,bubbleInput:x}=Wg(R1,e),v=de(s,u),b=m.useRef(l);return m.useEffect(()=>{const w=o==null?void 0:o.form;if(w){const g=()=>d(b.current);return w.addEventListener("reset",g),()=>w.removeEventListener("reset",g)}},[o,d]),f.jsx(ne.button,{type:"button",role:"checkbox","aria-checked":Ns(l)?"mixed":l,"aria-required":c,"data-state":I1(l),"data-disabled":a?"":void 0,disabled:a,value:i,...r,ref:v,onKeyDown:K(t,w=>{w.key==="Enter"&&w.preventDefault()}),onClick:K(n,w=>{d(g=>Ns(g)?!0:!g),x&&h&&(p.current=w.isPropagationStopped(),p.current||w.stopPropagation())})})});P1.displayName=R1;var Hg=m.forwardRef((e,t)=>{const{__scopeCheckbox:n,name:r,checked:s,defaultChecked:o,required:i,disabled:a,value:l,onCheckedChange:c,form:u,...d}=e;return f.jsx(f2,{__scopeCheckbox:n,checked:s,defaultChecked:o,disabled:a,required:i,onCheckedChange:c,name:r,form:u,value:l,internal_do_not_use_render:({isFormControl:p})=>f.jsxs(f.Fragment,{children:[f.jsx(P1,{...d,ref:t,__scopeCheckbox:n}),p&&f.jsx(j1,{__scopeCheckbox:n})]})})});Hg.displayName=Vd;var N1="CheckboxIndicator",A1=m.forwardRef((e,t)=>{const{__scopeCheckbox:n,forceMount:r,...s}=e,o=Wg(N1,n);return f.jsx(dn,{present:r||Ns(o.checked)||o.checked===!0,children:f.jsx(ne.span,{"data-state":I1(o.checked),"data-disabled":o.disabled?"":void 0,...s,ref:t,style:{pointerEvents:"none",...e.style}})})});A1.displayName=N1;var O1="CheckboxBubbleInput",j1=m.forwardRef(({__scopeCheckbox:e,...t},n)=>{const{control:r,hasConsumerStoppedPropagationRef:s,checked:o,defaultChecked:i,required:a,disabled:l,name:c,value:u,form:d,bubbleInput:p,setBubbleInput:h}=Wg(O1,e),x=de(n,h),v=Wd(o),b=Md(r);m.useEffect(()=>{const g=p;if(!g)return;const y=window.HTMLInputElement.prototype,S=Object.getOwnPropertyDescriptor(y,"checked").set,k=!s.current;if(v!==o&&S){const E=new Event("click",{bubbles:k});g.indeterminate=Ns(o),S.call(g,Ns(o)?!1:o),g.dispatchEvent(E)}},[p,v,o,s]);const w=m.useRef(Ns(o)?!1:o);return f.jsx(ne.input,{type:"checkbox","aria-hidden":!0,defaultChecked:i??w.current,required:a,disabled:l,name:c,value:u,form:d,...t,tabIndex:-1,ref:x,style:{...t.style,...b,position:"absolute",pointerEvents:"none",opacity:0,margin:0,transform:"translateX(-100%)"}})});j1.displayName=O1;function h2(e){return typeof e=="function"}function Ns(e){return e==="indeterminate"}function I1(e){return Ns(e)?"indeterminate":e?"checked":"unchecked"}const Va=m.forwardRef(({className:e,...t},n)=>f.jsx(Hg,{ref:n,className:me("peer h-4 w-4 shrink-0 rounded-sm border border-primary ring-offset-background data-[state=checked]:bg-primary data-[state=checked]:text-primary-foreground focus-visible:outline-none focus-visible:ring-2 focus-visible:ring-ring focus-visible:ring-offset-2 disabled:cursor-not-allowed disabled:opacity-50",e),...t,children:f.jsx(A1,{className:me("flex items-center justify-center text-current"),children:f.jsx(aS,{className:"h-4 w-4"})})}));Va.displayName=Hg.displayName;var Zf="focusScope.autoFocusOnMount",Qf="focusScope.autoFocusOnUnmount",Mw={bubbles:!1,cancelable:!0},p2="FocusScope",Vg=m.forwardRef((e,t)=>
vendor: 4,236 bytes, line 184
184{const{loop:n=!1,trapped:r=!1,onMountAutoFocus:s,onUnmountAutoFocus:o,...i}=e,[a,l]=m.useState(null),c=st(s),u=st(o),d=m.useRef(null),p=de(t,v=>l(v)),h=m.useRef({paused:!1,pause(){this.paused=!0},resume(){this.paused=!1}}).current;m.useEffect(()=>{if(r){let v=function(y){if(h.paused||!a)return;const _=y.target;a.contains(_)?d.current=_:ss(d.current,{select:!0})},b=function(y){if(h.paused||!a)return;const _=y.relatedTarget;_!==null&&(a.contains(_)||ss(d.current,{select:!0}))},w=function(y){if(document.activeElement===document.body)for(const S of y)S.removedNodes.length>0&&ss(a)};document.addEventListener("focusin",v),document.addEventListener("focusout",b);const g=new MutationObserver(w);return a&&g.observe(a,{childList:!0,subtree:!0}),()=>{document.removeEventListener("focusin",v),document.removeEventListener("focusout",b),g.disconnect()}}},[r,a,h.paused]),m.useEffect(()=>{if(a){$w.add(h);const v=document.activeElement;if(!a.contains(v)){const w=new CustomEvent(Zf,Mw);a.addEventListener(Zf,c),a.dispatchEvent(w),w.defaultPrevented||(m2(b2(D1(a)),{select:!0}),document.activeElement===v&&ss(a))}return()=>{a.removeEventListener(Zf,c),setTimeout(()=>{const w=new CustomEvent(Qf,Mw);a.addEventListener(Qf,u),a.dispatchEvent(w),w.defaultPrevented||ss(v??document.body,{select:!0}),a.removeEventListener(Qf,u),$w.remove(h)},0)}}},[a,c,u,h]);const x=m.useCallback(v=>{if(!n&&!r||h.paused)return;const b=v.key==="Tab"&&!v.altKey&&!v.ctrlKey&&!v.metaKey,w=document.activeElement;if(b&&w){const g=v.currentTarget,[y,_]=g2(g);y&&_?!v.shiftKey&&w===_?(v.preventDefault(),n&&ss(y,{select:!0})):v.shiftKey&&w===y&&(v.preventDefault(),n&&ss(_,{select:!0})):w===g&&v.preventDefault()}},[n,r,h.paused]);return f.jsx(ne.div,{tabIndex:-1,...i,ref:p,onKeyDown:x})});Vg.displayName=p2;function m2(e,{select:t=!1}={}){const n=document.activeElement;for(const r of e)if(ss(r,{select:t}),document.activeElement!==n)return}function g2(e){const t=D1(e),n=Lw(t,e),r=Lw(t.reverse(),e);return[n,r]}function D1(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 Lw(e,t){for(const n of e)if(!v2(n,{upTo:t}))return n}function v2(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 y2(e){return e instanceof HTMLInputElement&&"select"in e}function ss(e,{select:t=!1}={}){if(e&&e.focus){const n=document.activeElement;e.focus({preventScroll:!0}),e!==n&&y2(e)&&t&&e.select()}}var $w=w2();function w2(){let e=[];return{add(t){const n=e[0];t!==n&&(n==null||n.pause()),e=Fw(e,t),e.unshift(t)},remove(t){var n;e=Fw(e,t),(n=e[0])==null||n.resume()}}}function Fw(e,t){const n=[...e],r=n.indexOf(t);return r!==-1&&n.splice(r,1),n}function b2(e){return e.filter(t=>t.tagName!=="A")}var Jf=0;function M1(){m.useEffect(()=>{const e=document.querySelectorAll("[data-radix-focus-guard]");return document.body.insertAdjacentElement("afterbegin",e[0]??Uw()),document.body.insertAdjacentElement("beforeend",e[1]??Uw()),Jf++,()=>{Jf===1&&document.querySelectorAll("[data-radix-focus-guard]").forEach(t=>t.remove()),Jf--}},[])}function Uw(){const e=document.createElement("span");return e.setAttribute("data-radix-focus-guard",""),e.tabIndex=0,e.style.outline="none",e.style.opacity="0",e.style.position="fixed",e.style.pointerEvents="none",e}var dr=function(){return dr=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},dr.apply(this,arguments)};function aa(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 x2(e,t,n,r){function s(o){return o instanceof n?o:new n(function(i){i(o)})}
vendor: 5,268 bytes, lines 184-199
184return new(n||(n=Promise))(function(o,i){function a(u){try{c(r.next(u))}catch(d){i(d)}}function l(u){try{c(r.throw(u))}catch(d){i(d)}}function c(u){u.done?o(u.value):s(u.value).then(a,l)}c((r=r.apply(e,t||[])).next())})}function _2(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 cu="right-scroll-bar-position",uu="width-before-scroll-bar",S2="with-scroll-bars-hidden",E2="--removed-body-scroll-bar-size";function Xf(e,t){return typeof e=="function"?e(t):e&&(e.current=t),e}function k2(e,t){var n=m.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 C2=typeof window<"u"?m.useLayoutEffect:m.useEffect,Bw=new WeakMap;function T2(e,t){var n=k2(null,function(r){return e.forEach(function(s){return Xf(s,r)})});return C2(function(){var r=Bw.get(n);if(r){var s=new Set(r),o=new Set(e),i=n.current;s.forEach(function(a){o.has(a)||Xf(a,null)}),o.forEach(function(a){s.has(a)||Xf(a,i)})}Bw.set(n,e)},[e]),n}function R2(e){return e}function P2(e,t){t===void 0&&(t=R2);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 i=t(o,r);return n.push(i),function(){n=n.filter(function(a){return a!==i})}},assignSyncMedium:function(o){for(r=!0;n.length;){var i=n;n=[],i.forEach(o)}n={push:function(a){return o(a)},filter:function(){return n}}},assignMedium:function(o){r=!0;var i=[];if(n.length){var a=n;n=[],a.forEach(o),i=n}var l=function(){var u=i;i=[],u.forEach(o)},c=function(){return Promise.resolve().then(l)};c(),n={push:function(u){i.push(u),c()},filter:function(u){return i=i.filter(u),n}}}};return s}function N2(e){e===void 0&&(e={});var t=P2(null);return t.options=dr({async:!0,ssr:!1},e),t}var L1=function(e){var t=e.sideCar,n=aa(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 m.createElement(r,dr({},n))};L1.isSideCarExport=!0;function A2(e,t){return e.useMedium(t),L1}var $1=N2(),eh=function(){},qd=m.forwardRef(function(e,t){var n=m.useRef(null),r=m.useState({onScrollCapture:eh,onWheelCapture:eh,onTouchMoveCapture:eh}),s=r[0],o=r[1],i=e.forwardProps,a=e.children,l=e.className,c=e.removeScrollBar,u=e.enabled,d=e.shards,p=e.sideCar,h=e.noRelative,x=e.noIsolation,v=e.inert,b=e.allowPinchZoom,w=e.as,g=w===void 0?"div":w,y=e.gapMode,_=aa(e,["forwardProps","children","className","removeScrollBar","enabled","shards","sideCar","noRelative","noIsolation","inert","allowPinchZoom","as","gapMode"]),S=p,k=T2([n,t]),E=dr(dr({},_),s);return m.createElement(m.Fragment,null,u&&m.createElement(S,{sideCar:$1,removeScrollBar:c,shards:d,noRelative:h,noIsolation:x,inert:v,setCallbacks:o,allowPinchZoom:!!b,lockRef:n,gapMode:y}),i?m.cloneElement(m.Children.only(a),dr(dr({},E),{ref:k})):m.createElement(g,dr({},E,{className:l,ref:k}),a))});qd.defaultProps={enabled:!0,removeScrollBar:!0,inert:!1};qd.classNames={fullWidth:uu,zeroRight:cu};var O2=function(){if(typeof __webpack_nonce__<"u")return __webpack_nonce__};function j2(){if(!document)return null;var e=document.createElement("style");e.type="text/css";var t=O2();return t&&e.setAttribute("nonce",t),e}function I2(e,t){e.styleSheet?e.styleSheet.cssText=t:e.appendChild(document.createTextNode(t))}function D2(e){var t=document.head||document.getElementsByTagName("head")[0];t.appendChild(e)}var M2=function(){var e=0,t=null;return{add:function(n){e==0&&(t=j2())&&(I2(t,n),D2(t)),e++},remove:function(){e--,!e&&t&&(t.parentNode&&t.parentNode.removeChild(t),t=null)}}},L2=function(){var e=M2();return function(t,n){m.useEffect(function(){return e.add(t),function(){e.remove()}},[t&&n])}},F1=function(){var e=L2(),t=function(n){var r=n.styles,s=n.dynamic;return e(r,s),null};return t},$2={left:0,top:0,right:0,gap:0},th=function(e){return parseInt(e||"",10)||0},F2=function(e){var t=window.getComputedStyle(document.body),n=t[e==="padding"?"paddingLeft":"marginLeft"],r=t[e==="padding"?"paddingTop":"marginTop"],s=t[e==="padding"?"paddingRight":"marginRight"];return[th(n),th(r),th(s)]},U2=function(e){if(e===void 0&&(e="margin"),typeof window>"u")return $2;var t=F2(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])}},B2=F1(),ki="data-scroll-locked",z2=function(e,t,n,r){var s=e.left,o=e.top,i=e.right,a=e.gap;return n===void 0&&(n="margin"),` 185 .`.concat(S2,` { 186 overflow: hidden `).concat(r,`; 187 padding-right: `).concat(a,"px ").concat(r,`; 188 } 189 body[`).concat(ki,`] { 190 overflow: hidden `).concat(r,`; 191 overscroll-behavior: contain; 192 `).concat([t&&"position: relative ".concat(r,";"),n==="margin"&&` 193 padding-left: `.concat(s,`px; 194 padding-top: `).concat(o,`px; 195 padding-right: `).concat(i,`px; 196 margin-left:0; 197 margin-top:0; 198 margin-right: `).concat(a,"px ").concat(r,`; 199 `),n==="padding"&&"padding-right: ".concat(a,"px ").concat(r,";
199")].filter(Boolean).join(""),` 200 } 201 202 .`).concat(cu,` { 203 right: `).concat(a,"px ").concat(r,`; 204 } 205 206 .`).concat(uu,` { 207 margin-right: `).concat(a,"px ").concat(r,`; 208 } 209 210 .`).concat(cu," .").concat(cu,` { 211 right: 0 `).concat(r,`; 212 } 213 214 .`).concat(uu," .").concat(uu,` { 215 margin-right: 0 `).concat(r,`; 216 } 217 218 body[`).concat(ki,`] { 219 `).concat(E2,": ").concat(a,`px; 220 } 221`)},zw=function(){var e=parseInt(document.body.getAttribute(ki)||"0",10);return isFinite(e)?e:0},W2=function(){m.useEffect(function(){return document.body.setAttribute(ki,(zw()+1).toString()),function(){var e=zw()-1;e<=0?document.body.removeAttribute(ki):document.body.setAttribute(ki,e.toString())}},[])},H2=function(e){var t=e.noRelative,n=e.noImportant,r=e.gapMode,s=r===void 0?"margin":r;W2();var o=m.useMemo(function(){return U2(s)},[s]);return m.createElement(B2,{styles:z2(o,!t,s,n?"":"!important")})},qp=!1;if(typeof window<"u")try{var Oc=Object.defineProperty({},"passive",{get:function(){return qp=!0,!0}});window.addEventListener("test",Oc,Oc),window.removeEventListener("test",Oc,Oc)}catch{qp=!1}var Bo=qp?{passive:!1}:!1,V2=function(e){return e.tagName==="TEXTAREA"},U1=function(e,t){if(!(e instanceof Element))return!1;var n=window.getComputedStyle(e);return n[t]!=="hidden"&&!(n.overflowY===n.overflowX&&!V2(e)&&n[t]==="visible")},q2=function(e){return U1(e,"overflowY")},K2=function(e){return U1(e,"overflowX")},Ww=function(e,t){var n=t.ownerDocument,r=t;do{typeof ShadowRoot<"u"&&r instanceof ShadowRoot&&(r=r.host);var s=B1(e,r);if(s){var o=z1(e,r),i=o[1],a=o[2];if(i>a)return!0}r=r.parentNode}while(r&&r!==n.body);return!1},G2=function(e){var t=e.scrollTop,n=e.scrollHeight,r=e.clientHeight;return[t,n,r]},Y2=function(e){var t=e.scrollLeft,n=e.scrollWidth,r=e.clientWidth;return[t,n,r]},B1=function(e,t){return e==="v"?q2(t):K2(t)},z1=function(e,t){return e==="v"?G2(t):Y2(t)},Z2=function(e,t){return e==="h"&&t==="rtl"?-1:1},Q2=function(e,t,n,r,s){var o=Z2(e,window.getComputedStyle(t).direction),i=o*r,a=n.target,l=t.contains(a),c=!1,u=i>0,d=0,p=0;do{if(!a)break;var h=z1(e,a),x=h[0],v=h[1],b=h[2],w=v-b-o*x;(x||w)&&B1(e,a)&&(d+=w,p+=x);var g=a.parentNode;a=g&&g.nodeType===Node.DOCUMENT_FRAGMENT_NODE?g.host:g}while(!l&&a!==document.body||l&&(t.contains(a)||t===a));return(u&&(Math.abs(d)<1||!s)||!u&&(Math.abs(p)<1||!s))&&(c=!0),c},jc=function(e){return"changedTouches"in e?[e.changedTouches[0].clientX,e.changedTouches[0].clientY]:[0,0]},Hw=function(e){return[e.deltaX,e.deltaY]},Vw=function(e){return e&&"current"in e?e.current:e},J2=function(e,t){return e[0]===t[0]&&e[1]===t[1]},X2=function(e){return` 222 .block-interactivity-`.concat(e,` {pointer-events: none;} 223 .allow-interactivity-`).concat(e,` {pointer-events: all;} 224`)},eM=0,zo=[];function tM(e){var t=m.useRef([]),n=m.useRef([0,0]),r=m.useRef(),s=m.useState(eM++)[0],o=m.useState(F1)[0],i=m.useRef(e);m.useEffect(function(){i.current=e},[e]),m.useEffect(function(){if(e.inert){document.body.classList.add("block-interactivity-".concat(s));var v=_2([e.lockRef.current],(e.shards||[]).map(Vw),!0).filter(Boolean);return v.forEach(function(b){return b.classList.add("allow-interactivity-".concat(s))}),function(){document.body.classList.remove("block-interactivity-".concat(s)),v.forEach(function(b){return b.classList.remove("allow-interactivity-".concat(s))})}}},[e.inert,e.lockRef.current,e.shards]);var a=m.useCallback(function(v,b){if("touches"in v&&v.touches.length===2||v.type==="wheel"&&v.ctrlKey)return!i.current.allowPinchZoom;var w=jc(v),g=n.current,y="deltaX"in v?v.deltaX:g[0]-w[0],_="deltaY"in v?v.deltaY:g[1]-w[1],S,k=v.target,E=Math.abs(y)>Math.abs(_)?"h":"v";if("touches"in v&&E==="h"&&k.type==="range")return!1;var R=Ww(E,k);if(!R)return!0;if(R?S=E:(S=E==="v"?"h":"v",R=Ww(E,k)),!R)return!1;if(!r.current&&"changedTouches"in v&&(y||_)&&(r.current=S),!S)return!0;var P=r.current||S;return Q2(P,b,v,P==="h"?y:_,!0)},[]),l=m.useCallback(function(v){var b=v;if(!(!zo.length||zo[zo.length-1]!==o)){var w="deltaY"in b?Hw(b):jc(b),g=t.current.filter(function(S){return S.name===b.type&&(S.target===b.target||b.target===S.shadowParent)&&J2(S.delta,w)})[0];if(g&&g.should){b.cancelable&&b.preventDefault();return}
vendor: 2,655 bytes, line 224
224if(!g){var y=(i.current.shards||[]).map(Vw).filter(Boolean).filter(function(S){return S.contains(b.target)}),_=y.length>0?a(b,y[0]):!i.current.noIsolation;_&&b.cancelable&&b.preventDefault()}}},[]),c=m.useCallback(function(v,b,w,g){var y={name:v,delta:b,target:w,should:g,shadowParent:nM(w)};t.current.push(y),setTimeout(function(){t.current=t.current.filter(function(_){return _!==y})},1)},[]),u=m.useCallback(function(v){n.current=jc(v),r.current=void 0},[]),d=m.useCallback(function(v){c(v.type,Hw(v),v.target,a(v,e.lockRef.current))},[]),p=m.useCallback(function(v){c(v.type,jc(v),v.target,a(v,e.lockRef.current))},[]);m.useEffect(function(){return zo.push(o),e.setCallbacks({onScrollCapture:d,onWheelCapture:d,onTouchMoveCapture:p}),document.addEventListener("wheel",l,Bo),document.addEventListener("touchmove",l,Bo),document.addEventListener("touchstart",u,Bo),function(){zo=zo.filter(function(v){return v!==o}),document.removeEventListener("wheel",l,Bo),document.removeEventListener("touchmove",l,Bo),document.removeEventListener("touchstart",u,Bo)}},[]);var h=e.removeScrollBar,x=e.inert;return m.createElement(m.Fragment,null,x?m.createElement(o,{styles:X2(s)}):null,h?m.createElement(H2,{noRelative:e.noRelative,gapMode:e.gapMode}):null)}function nM(e){for(var t=null;e!==null;)e instanceof ShadowRoot&&(t=e.host,e=e.host),e=e.parentNode;return t}const rM=A2($1,tM);var qg=m.forwardRef(function(e,t){return m.createElement(qd,dr({},e,{ref:t,sideCar:rM}))});qg.classNames=qd.classNames;var sM=function(e){if(typeof document>"u")return null;var t=Array.isArray(e)?e[0]:e;return t.ownerDocument.body},Wo=new WeakMap,Ic=new WeakMap,Dc={},nh=0,W1=function(e){return e&&(e.host||W1(e.parentNode))},oM=function(e,t){return t.map(function(n){if(e.contains(n))return n;var r=W1(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})},iM=function(e,t,n,r){var s=oM(t,Array.isArray(e)?e:[e]);Dc[n]||(Dc[n]=new WeakMap);var o=Dc[n],i=[],a=new Set,l=new Set(s),c=function(d){!d||a.has(d)||(a.add(d),c(d.parentNode))};s.forEach(c);var u=function(d){!d||l.has(d)||Array.prototype.forEach.call(d.children,function(p){if(a.has(p))u(p);else try{var h=p.getAttribute(r),x=h!==null&&h!=="false",v=(Wo.get(p)||0)+1,b=(o.get(p)||0)+1;Wo.set(p,v),o.set(p,b),i.push(p),v===1&&x&&Ic.set(p,!0),b===1&&p.setAttribute(n,"true"),x||p.setAttribute(r,"true")}catch(w){console.error("aria-hidden: cannot operate on ",p,w)}})};return u(t),a.clear(),nh++,function(){i.forEach(function(d){var p=Wo.get(d)-1,h=o.get(d)-1;Wo.set(d,p),o.set(d,h),p||(Ic.has(d)||d.removeAttribute(r),Ic.delete(
vendor: 6,391 bytes, lines 224-228
224d)),h||d.removeAttribute(n)}),nh--,nh||(Wo=new WeakMap,Wo=new WeakMap,Ic=new WeakMap,Dc={})}},H1=function(e,t,n){n===void 0&&(n="data-aria-hidden");var r=Array.from(Array.isArray(e)?e:[e]),s=sM(e);return s?(r.push.apply(r,Array.from(s.querySelectorAll("[aria-live]"))),iM(r,s,n,"aria-hidden")):function(){return null}},Kd="Dialog",[V1,Nz]=Gt(Kd),[aM,Xn]=V1(Kd),q1=e=>{const{__scopeDialog:t,children:n,open:r,defaultOpen:s,onOpenChange:o,modal:i=!0}=e,a=m.useRef(null),l=m.useRef(null),[c,u]=Gn({prop:r,defaultProp:s??!1,onChange:o,caller:Kd});return f.jsx(aM,{scope:t,triggerRef:a,contentRef:l,contentId:Ur(),titleId:Ur(),descriptionId:Ur(),open:c,onOpenChange:u,onOpenToggle:m.useCallback(()=>u(d=>!d),[u]),modal:i,children:n})};q1.displayName=Kd;var K1="DialogTrigger",G1=m.forwardRef((e,t)=>{const{__scopeDialog:n,...r}=e,s=Xn(K1,n),o=de(t,s.triggerRef);return f.jsx(ne.button,{type:"button","aria-haspopup":"dialog","aria-expanded":s.open,"aria-controls":s.contentId,"data-state":Yg(s.open),...r,ref:o,onClick:K(e.onClick,s.onOpenToggle)})});G1.displayName=K1;var Kg="DialogPortal",[lM,Y1]=V1(Kg,{forceMount:void 0}),Z1=e=>{const{__scopeDialog:t,forceMount:n,children:r,container:s}=e,o=Xn(Kg,t);return f.jsx(lM,{scope:t,forceMount:n,children:m.Children.map(r,i=>f.jsx(dn,{present:n||o.open,children:f.jsx(Cd,{asChild:!0,container:s,children:i})}))})};Z1.displayName=Kg;var qu="DialogOverlay",Q1=m.forwardRef((e,t)=>{const n=Y1(qu,e.__scopeDialog),{forceMount:r=n.forceMount,...s}=e,o=Xn(qu,e.__scopeDialog);return o.modal?f.jsx(dn,{present:r||o.open,children:f.jsx(uM,{...s,ref:t})}):null});Q1.displayName=qu;var cM=zi("DialogOverlay.RemoveScroll"),uM=m.forwardRef((e,t)=>{const{__scopeDialog:n,...r}=e,s=Xn(qu,n);return f.jsx(qg,{as:cM,allowPinchZoom:!0,shards:[s.contentRef],children:f.jsx(ne.div,{"data-state":Yg(s.open),...r,ref:t,style:{pointerEvents:"auto",...r.style}})})}),To="DialogContent",J1=m.forwardRef((e,t)=>{const n=Y1(To,e.__scopeDialog),{forceMount:r=n.forceMount,...s}=e,o=Xn(To,e.__scopeDialog);return f.jsx(dn,{present:r||o.open,children:o.modal?f.jsx(dM,{...s,ref:t}):f.jsx(fM,{...s,ref:t})})});J1.displayName=To;var dM=m.forwardRef((e,t)=>{const n=Xn(To,e.__scopeDialog),r=m.useRef(null),s=de(t,n.contentRef,r);return m.useEffect(()=>{const o=r.current;if(o)return H1(o)},[]),f.jsx(X1,{...e,ref:s,trapFocus:n.open,disableOutsidePointerEvents:!0,onCloseAutoFocus:K(e.onCloseAutoFocus,o=>{var i;o.preventDefault(),(i=n.triggerRef.current)==null||i.focus()}),onPointerDownOutside:K(e.onPointerDownOutside,o=>{const i=o.detail.originalEvent,a=i.button===0&&i.ctrlKey===!0;(i.button===2||a)&&o.preventDefault()}),onFocusOutside:K(e.onFocusOutside,o=>o.preventDefault())})}),fM=m.forwardRef((e,t)=>{const n=Xn(To,e.__scopeDialog),r=m.useRef(!1),s=m.useRef(!1);return f.jsx(X1,{...e,ref:t,trapFocus:!1,disableOutsidePointerEvents:!1,onCloseAutoFocus:o=>{var i,a;(i=e.onCloseAutoFocus)==null||i.call(e,o),o.defaultPrevented||(r.current||(a=n.triggerRef.current)==null||a.focus(),o.preventDefault()),r.current=!1,s.current=!1},onInteractOutside:o=>{var l,c;(l=e.onInteractOutside)==null||l.call(e,o),o.defaultPrevented||(r.current=!0,o.detail.originalEvent.type==="pointerdown"&&(s.current=!0));const i=o.target;((c=n.triggerRef.current)==null?void 0:c.contains(i))&&o.preventDefault(),o.detail.originalEvent.type==="focusin"&&s.current&&o.preventDefault()}})}),X1=m.forwardRef((e,t)=>{const{__scopeDialog:n,trapFocus:r,onOpenAutoFocus:s,onCloseAutoFocus:o,...i}=e,a=Xn(To,n),l=m.useRef(null),c=de(t,l);return M1(),f.jsxs(f.Fragment,{children:[f.jsx(Vg,{asChild:!0,loop:!0,trapped:r,onMountAutoFocus:s,onUnmountAutoFocus:o,children:f.jsx(Ql,{role:"dialog",id:a.contentId,"aria-describedby":a.descriptionId,"aria-labelledby":a.titleId,"data-state":Yg(a.open),...i,ref:c,onDismiss:()=>a.onOpenChange(!1)})}),f.jsxs(f.Fragment,{children:[f.jsx(hM,{titleId:a.titleId}),f.jsx(mM,{contentRef:l,descriptionId:a.descriptionId})]})]})}),Gg="DialogTitle",eE=m.forwardRef((e,t)=>{const{__scopeDialog:n,...r}=e,s=Xn(Gg,n);return f.jsx(ne.h2,{id:s.titleId,...r,ref:t})});eE.displayName=Gg;var tE="DialogDescription",nE=m.forwardRef((e,t)=>{const{__scopeDialog:n,...r}=e,s=Xn(tE,n);return f.jsx(ne.p,{id:s.descriptionId,...r,ref:t})});nE.displayName=tE;var rE="DialogClose",sE=m.forwardRef((e,t)=>{const{__scopeDialog:n,...r}=e,s=Xn(rE,n);return f.jsx(ne.button,{type:"button",...r,ref:t,onClick:K(e.onClick,()=>s.onOpenChange(!1))})});sE.displayName=rE;function Yg(e){return e?"open":"closed"}var oE="DialogTitleWarning",[Az,iE]=pN(oE,{contentName:To,titleName:Gg,docsSlug:"dialog"}),hM=({titleId:e})=>{const t=iE(oE),n=`\`${t.contentName}\` requires a \`${t.titleName}\` for the component to be accessible for screen reader users. 225 226If you want to hide the \`${t.titleName}\`, you can wrap it with our VisuallyHidden component. 227 228For more information, see https://radix-ui.com/primitives/docs/components/${t.docsSlug}`;return m.useEffect(()=>{e&&(document.getElementById(e)||console.error(n))},[n,e]),null},pM="DialogDescriptionWarning",mM=({contentRef:e,descriptionId:t})=>{const r=`Warning: Missing \`Description\` or \`aria-describedby={undefined}\` for {${iE(pM).contentName}}.`;return m.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},gM=q1,vM=G1,yM=Z1,aE=Q1,lE=J1,cE=eE,uE=nE,wM=sE;const bM=gM,xM=vM,_M=yM,dE=m.forwardRef(({className:e,...t},n)=>f.jsx(aE,{ref:n,className:me("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}));dE.displayName=aE.displayName;const fE=m.forwardRef(({className:e,children:t,...n},r)=>f.jsxs(_M,{children:[f.jsx(dE,{}),f.jsxs(lE,{ref:r,className:me("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,f.jsxs(wM,{className:"absolute right-4 top-4 roun
228ded-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:[f.jsx(Od,{className:"h-4 w-4"}),f.jsx("span",{className:"sr-only",children:"Close"})]})]})]}));fE.displayName=lE.displayName;const hE=({className:e,...t})=>f.jsx("div",{className:me("flex flex-col space-y-1.5 text-center sm:text-left",e),...t});hE.displayName="DialogHeader";const pE=m.forwardRef(({className:e,...t},n)=>f.jsx(cE,{ref:n,className:me("text-lg font-semibold leading-none tracking-tight",e),...t}));pE.displayName=cE.displayName;const SM=m.forwardRef(({className:e,...t},n)=>f.jsx(uE,{ref:n,className:me("text-sm text-muted-foreground",e),...t}));SM.displayName=uE.displayName;function EM(e,t){return m.useReducer((n,r)=>t[n][r]??n,e)}var Zg="ScrollArea",[mE,Oz]=Gt(Zg),[kM,Cn]=mE(Zg),gE=m.forwardRef((e,t)=>{const{__scopeScrollArea:n,type:r="hover",dir:s,scrollHideDelay:o=600,...i}=e,[a,l]=m.useState(null),[c,u]=m.useState(null),[d,p]=m.useState(null),[h,x]=m.useState(null),[v,b]=m.useState(null),[w,g]=m.useState(0),[y,_]=m.useState(0),[S,k]=m.useState(!1),[E,R]=m.useState(!1),P=de(t,D=>l(D)),A=oa(s);return f.jsx(kM,{scope:n,type:r,dir:A,scrollHideDelay:o,scrollArea:a,viewport:c,onViewportChange:u,content:d,onContentChange:p,scrollbarX:h,onScrollbarXChange:x,scrollbarXEnabled:S,onScrollbarXEnabledChange:k,scrollbarY:v,onScrollbarYChange:b,scrollbarYEnabled:E,onScrollbarYEnabledChange:R,onCornerWidthChange:g,onCornerHeightChange:_,children:f.jsx(ne.div,{dir:A,...i,ref:P,style:{position:"relative","--radix-scroll-area-corner-width":w+"px","--radix-scroll-area-corner-height":y+"px",...e.style}})})});gE.displayName=Zg;var vE="ScrollAreaViewport",yE=m.forwardRef((e,t)=>{const{__scopeScrollArea:n,children:r,nonce:s,...o}=e,i=Cn(vE,n),a=m.useRef(null),l=de(t,a,i.onViewportChange);return f.jsxs(f.Fragment,{children:[f.jsx("style",{dangerouslySetInnerHTML:{__html:"[data-radix-scroll-area-viewport]{scrollbar-width:none;-ms-overflow-style:none;-webkit-overflow-scrolling:touch;}[data-radix-scroll-area-viewport]::-webkit-scrollbar{display:none}"},nonce:s}),f.jsx(ne.div,{"data-radix-scroll-area-viewport":"",...o,ref:l,style:{overflowX:i.scrollbarXEnabled?"scroll":"hidden",overflowY:i.scrollbarYEnabled?"scroll":"hidden",...e.style},children:f.jsx("div",{ref:i.onContentChange,style:{minWidth:"100%",display:"table"},children:r})})]})});yE.displayName=vE;var _r="ScrollAreaScrollbar",Qg=m.forwardRef((e,t)=>{const{forceMount:n,...r}=e,s=Cn(_r,e.__scopeScrollArea),{onScrollbarXEnabledChange:o,onScrollbarYEnabledChange:i}=s,a=e.orientation==="horizontal";return m.useEffect(()=>(a?o(!0):i(!0),()=>{a?o(!1):i(!1)}),[a,o,i]),s.type==="hover"?f.jsx(CM,{...r,ref:t,forceMount:n}):s.type==="scroll"?f.jsx(TM,{...r,ref:t,forceMount:n}):s.type==="auto"?f.jsx(wE,{...r,ref:t,forceMount:n}):s.type==="always"?f.jsx(Jg,{...r,ref:t}):null});Qg.displayName=_r;var CM=m.forwardRef((e,t)=>{const{forceMount:n,...r}=e,s=Cn(_r,e.__scopeScrollArea),[o,i]=m.useState(!1);return m.useEffect(()=>{const a=s.scrollArea;let l=0;if(a){const c=()=>{window.clearTimeout(l),i(!0)},u=()=>{l=window.setTimeout(()=>i(!1),s.scrollHideDelay)};return a.addEventListener("pointerenter",c),a.addEventListener("pointerleave",u),()=>{window.clearTimeout(l),a.removeEventListener("pointerenter",c),a.removeEventListener("pointerleave",u)}}},[s.scrollArea,s.scrollHideDelay]),f.jsx(dn,{present:n||o,children:f.jsx(wE,{"data-state":o?"visible":"hidden",...r,ref:t})})}),TM=m.forwardRef((e,t)=>{const{forceMount:n,...r}=e,s=Cn(_r,e.__scopeScrollArea),o=e.orientation==="horizontal",i=Yd(()=>l("SCROLL_END"),100),[a,l]=EM("hidden",{hidden:{SCROLL:"scrolling"},scrolling:{SCROLL_END:"idle",POINTER_ENTER:"interacting"},interacting:{SCROLL:"interacting",POINTER_LEAVE:"idle"},idle:{HIDE:"hidden",SCROLL:"scrolling",POINTER_ENTER:"interacting"}});return m.useEffect(()=>{if(a==="idle"){const c=window.setTimeout(()=>l("HIDE"),s.scrollHideDelay);return()=>window.clearTimeout(c)}},[a,s.scrollHideDelay,l]),m.useEffect(()=>{const c=s.viewport,u=o?"scrollLeft":"scrollTop";if(c){let d=c[u];const p=()=>{const h=c[u];d!==h&&(l("SCROLL"),i()),d=h};return c.addEventListener("scroll",p),()=>c.removeEventListener("scroll",p)}},[s.viewport,o,l,i]),f.jsx(dn,{present:n||a!=="hidden",children:f.jsx(Jg,{"data-state":a==="hidden"?"hidden":"visible",...r,ref:t,onPointerEnter:K(e.onPointerEnter,()=>l("POINTER_ENTER")),onPointerLeave:K(e.onPointerLeave,()=>l("POINTER_LEAVE"))})})}),wE=m.forwardRef((e,t)=>
vendor: 4,771 bytes, line 228
228{const n=Cn(_r,e.__scopeScrollArea),{forceMount:r,...s}=e,[o,i]=m.useState(!1),a=e.orientation==="horizontal",l=Yd(()=>{if(n.viewport){const c=n.viewport.offsetWidth<n.viewport.scrollWidth,u=n.viewport.offsetHeight<n.viewport.scrollHeight;i(a?c:u)}},10);return Vi(n.viewport,l),Vi(n.content,l),f.jsx(dn,{present:r||o,children:f.jsx(Jg,{"data-state":o?"visible":"hidden",...s,ref:t})})}),Jg=m.forwardRef((e,t)=>{const{orientation:n="vertical",...r}=e,s=Cn(_r,e.__scopeScrollArea),o=m.useRef(null),i=m.useRef(0),[a,l]=m.useState({content:0,viewport:0,scrollbar:{size:0,paddingStart:0,paddingEnd:0}}),c=EE(a.viewport,a.content),u={...r,sizes:a,onSizesChange:l,hasThumb:c>0&&c<1,onThumbChange:p=>o.current=p,onThumbPointerUp:()=>i.current=0,onThumbPointerDown:p=>i.current=p};function d(p,h){return jM(p,i.current,a,h)}return n==="horizontal"?f.jsx(RM,{...u,ref:t,onThumbPositionChange:()=>{if(s.viewport&&o.current){const p=s.viewport.scrollLeft,h=qw(p,a,s.dir);o.current.style.transform=`translate3d(${h}px, 0, 0)`}},onWheelScroll:p=>{s.viewport&&(s.viewport.scrollLeft=p)},onDragScroll:p=>{s.viewport&&(s.viewport.scrollLeft=d(p,s.dir))}}):n==="vertical"?f.jsx(PM,{...u,ref:t,onThumbPositionChange:()=>{if(s.viewport&&o.current){const p=s.viewport.scrollTop,h=qw(p,a);o.current.style.transform=`translate3d(0, ${h}px, 0)`}},onWheelScroll:p=>{s.viewport&&(s.viewport.scrollTop=p)},onDragScroll:p=>{s.viewport&&(s.viewport.scrollTop=d(p))}}):null}),RM=m.forwardRef((e,t)=>{const{sizes:n,onSizesChange:r,...s}=e,o=Cn(_r,e.__scopeScrollArea),[i,a]=m.useState(),l=m.useRef(null),c=de(t,l,o.onScrollbarXChange);return m.useEffect(()=>{l.current&&a(getComputedStyle(l.current))},[l]),f.jsx(xE,{"data-orientation":"horizontal",...s,ref:c,sizes:n,style:{bottom:0,left:o.dir==="rtl"?"var(--radix-scroll-area-corner-width)":0,right:o.dir==="ltr"?"var(--radix-scroll-area-corner-width)":0,"--radix-scroll-area-thumb-width":Gd(n)+"px",...e.style},onThumbPointerDown:u=>e.onThumbPointerDown(u.x),onDragScroll:u=>e.onDragScroll(u.x),onWheelScroll:(u,d)=>{if(o.viewport){const p=o.viewport.scrollLeft+u.deltaX;e.onWheelScroll(p),CE(p,d)&&u.preventDefault()}},onResize:()=>{l.current&&o.viewport&&i&&r({content:o.viewport.scrollWidth,viewport:o.viewport.offsetWidth,scrollbar:{size:l.current.clientWidth,paddingStart:Gu(i.paddingLeft),paddingEnd:Gu(i.paddingRight)}})}})}),PM=m.forwardRef((e,t)=>{const{sizes:n,onSizesChange:r,...s}=e,o=Cn(_r,e.__scopeScrollArea),[i,a]=m.useState(),l=m.useRef(null),c=de(t,l,o.onScrollbarYChange);return m.useEffect(()=>{l.current&&a(getComputedStyle(l.current))},[l]),f.jsx(xE,{"data-orientation":"vertical",...s,ref:c,sizes:n,style:{top:0,right:o.dir==="ltr"?0:void 0,left:o.dir==="rtl"?0:void 0,bottom:"var(--radix-scroll-area-corner-height)","--radix-scroll-area-thumb-height":Gd(n)+"px",...e.style},onThumbPointerDown:u=>e.onThumbPointerDown(u.y),onDragScroll:u=>e.onDragScroll(u.y),onWheelScroll:(u,d)=>{if(o.viewport){const p=o.viewport.scrollTop+u.deltaY;e.onWheelScroll(p),CE(p,d)&&u.preventDefault()}},onResize:()=>{l.current&&o.viewport&&i&&r({content:o.viewport.scrollHeight,viewport:o.viewport.offsetHeight,scrollbar:{size:l.current.clientHeight,paddingStart:Gu(i.paddingTop),paddingEnd:Gu(i.paddingBottom)}})}})}),[NM,bE]=mE(_r),xE=m.forwardRef((e,t)=>{const{__scopeScrollArea:n,sizes:r,hasThumb:s,onThumbChange:o,onThumbPointerUp:i,onThumbPointerDown:a,onThumbPositionChange:l,onDragScroll:c,onWheelScroll:u,onResize:d,...p}=e,h=Cn(_r,n),[x,v]=m.useState(null),b=de(t,P=>v(P)),w=m.useRef(null),g=m.useRef(""),y=h.viewport,_=r.content-r.viewport,S=st(u),k=st(l),E=Yd(d,10);function R(P){if(w.current){const A=P.clientX-w.current.left,D=P.clientY-w.current.top;c({x:A,y:D})}}return m.useEffect(()=>{const P=A=>{const D=A.target;(x==null?void 0:x.contains(D))&&S(A,_)};return document.addEventListener("wheel",P,{passive:!1}),()=>document.removeEventListener("wheel",P,{passive:!1})},[y,x,_,S]),m.useEffect(k,[r,k]),Vi(x,E),Vi(h.content,E),f.jsx(NM,{scope:n,scrollbar:x,hasThumb:s,onThumbChange:st(o),onThumbPointerUp:st(i),onThumbPositionChange:k,onThumbPointerDown:st(a),children:f.jsx(ne.div,{...p,ref:b,style:{position:"absolute",...p.style},onPointerDown:K(e.onPointerDown,P=>{P.button===0&&(P.target.setPointerCapture(P.pointerId),w.current=x.getBoundingClientRect(),g.current=document.body.style.webkitUserSelect,document.body.style.webkitUserSelect="none",h.viewport&&(h.viewport.style.scrollBehavior="auto"),R(P))}),onPointerMove:K(e.onPointerMove,R),onPointerUp:K(e.onPointerUp,P=>{const A=P.target;A.hasPointerCapture(P.pointerId)&&A.releasePointerCapture(P.pointerId),document.body.style.webkitUserSelect=g.current,h.viewport&&(h.viewport.style.scrollBehavior=""),w.current=null})})})}),Ku="ScrollAreaThumb",_E=m.forwardRef((e,t)=>
228{const{forceMount:n,...r}=e,s=bE(Ku,e.__scopeScrollArea);return f.jsx(dn,{present:n||s.hasThumb,children:f.jsx(AM,{ref:t,...r})})}),AM=m.forwardRef((e,t)=>{const{__scopeScrollArea:n,style:r,...s}=e,o=Cn(Ku,n),i=bE(Ku,n),{onThumbPositionChange:a}=i,l=de(t,d=>i.onThumbChange(d)),c=m.useRef(void 0),u=Yd(()=>{c.current&&(c.current(),c.current=void 0)},100);return m.useEffect(()=>{const d=o.viewport;if(d){const p=()=>{if(u(),!c.current){const h=IM(d,a);c.current=h,a()}};return a(),d.addEventListener("scroll",p),()=>d.removeEventListener("scroll",p)}},[o.viewport,u,a]),f.jsx(ne.div,{"data-state":i.hasThumb?"visible":"hidden",...s,ref:l,style:{width:"var(--radix-scroll-area-thumb-width)",height:"var(--radix-scroll-area-thumb-height)",...r},onPointerDownCapture:K(e.onPointerDownCapture,d=>{const h=d.target.getBoundingClientRect(),x=d.clientX-h.left,v=d.clientY-h.top;i.onThumbPointerDown({x,y:v})}),onPointerUp:K(e.onPointerUp,i.onThumbPointerUp)})});_E.displayName=Ku;var Xg="ScrollAreaCorner",SE=m.forwardRef((e,t)=>{const n=Cn(Xg,e.__scopeScrollArea),r=!!(n.scrollbarX&&n.scrollbarY);return n.type!=="scroll"&&r?f.jsx(OM,{...e,ref:t}):null});SE.displayName=Xg;var OM=m.forwardRef((e,t)=>{const{__scopeScrollArea:n,...r}=e,s=Cn(Xg,n),[o,i]=m.useState(0),[a,l]=m.useState(0),c=!!(o&&a);return Vi(s.scrollbarX,()=>{var d;const u=((d=s.scrollbarX)==null?void 0:d.offsetHeight)||0;s.onCornerHeightChange(u),l(u)}),Vi(s.scrollbarY,()=>{var d;const u=((d=s.scrollbarY)==null?void 0:d.offsetWidth)||0;s.onCornerWidthChange(u),i(u)}),c?f.jsx(ne.div,{...r,ref:t,style:{width:o,height:a,position:"absolute",right:s.dir==="ltr"?0:void 0,left:s.dir==="rtl"?0:void 0,bottom:0,...e.style}}):null});function Gu(e){return e?parseInt(e,10):0}function EE(e,t){const n=e/t;return isNaN(n)?0:n}function Gd(e){const t=EE(e.viewport,e.content),n=e.scrollbar.paddingStart+e.scrollbar.paddingEnd,r=(e.scrollbar.size-n)*t;return Math.max(r,18)}function jM(e,t,n,r="ltr"){const s=Gd(n),o=s/2,i=t||o,a=s-i,l=n.scrollbar.paddingStart+i,c=n.scrollbar.size-n.scrollbar.paddingEnd-a,u=n.content-n.viewport,d=r==="ltr"?[0,u]:[u*-1,0];return kE([l,c],d)(e)}function qw(e,t,n="ltr"){const r=Gd(t),s=t.scrollbar.paddingStart+t.scrollbar.paddingEnd,o=t.scrollbar.size-s,i=t.content-t.viewport,a=o-r,l=n==="ltr"?[0,i]:[i*-1,0],c=Nl(e,l);return kE([0,i],[0,a])(c)}function kE(e,t){return n=>{if(e[0]===e[1]||t[0]===t[1])return t[0];const r=(t[1]-t[0])/(e[1]-e[0]);return t[0]+r*(n-e[0])}}function CE(e,t){return e>0&&e<t}var IM=(e,t=()=>{})=>{let n={left:e.scrollLeft,top:e.scrollTop},r=0;return function s(){const o={left:e.scrollLeft,top:e.scrollTop},i=n.left!==o.left,a=n.top!==o.top;(i||a)&&t(),n=o,r=window.requestAnimationFrame(s)}(),()=>window.cancelAnimationFrame(r)};function Yd(e,t){const n=st(e),r=m.useRef(0);return m.useEffect(()=>()=>window.clearTimeout(r.current),[]),m.useCallback(()=>{window.clearTimeout(r.current),r.current=window.setTimeout(n,t)},[n,t])}function Vi(e,t){const n=st(t);it(()=>{let r=0;if(e){const s=new ResizeObserver(()=>{cancelAnimationFrame(r),r=window.requestAnimationFrame(n)});return s.observe(e),()=>{window.cancelAnimationFrame(r),s.unobserve(e)}}},[e,n])}var TE=gE,DM=yE,MM=SE;const RE=m.forwardRef(({className:e,children:t,...n},r)=>f.jsxs(TE,{ref:r,className:me("relative overflow-hidden",e),...n,children:[f.jsx(DM,{className:"h-full w-full rounded-[inherit]",children:t}),f.jsx(PE,{}),f.jsx(MM,{})]}));RE.displayName=TE.displayName;const PE=m.forwardRef(({className:e,orientation:t="vertical",...n},r)=>f.jsx(Qg,{ref:r,orientation:t,className:me("flex touch-none select-none transition-colors",t==="vertical"&&"h-full w-2.5 border-l border-l-transparent p-[1px]",t==="horizontal"&&"h-2.5 flex-col border-t border-t-transparent p-[1px]",e),...n,children:f.jsx(_E,{className:"relative flex-1 rounded-full bg-border"})}));PE.displayName=Qg.displayName;const Kw=[{value:"manufacturing",label:"ì ì¡°ì
",hard:!1},{value:"service",label:"ìë¹ì¤ì
",hard:!1},{value:"medical",label:"ìë£ì
",hard:!0},{value:"retail",label:"ëì매ì
",hard:!1},{value:"restaurant",label:"ììì ì
(ì¹´í í¬í¨)",hard:!0}],LM=["ì§ì ì
í´ì¬ ë° ê·¼í ë³ëì´ ì¦ì ê²½ì°","ììì ì¼ë¡ ì¼ì©ì§ì ì¬ì©íë ê²½ì°","근무ííê° ë¹ì ííë ê²½ì°","ê·¼ë¡ìê° ì íì´ ë¤ìí ê²½ì°","ììì ì¼ë¡ ìê°ì¸ê·¼ë¡ê° ë°ìíë ê²½ì°"],$M=e=>Math.floor(e/1e4)*1e4;function FM(e){return e<=10?1e5:e<=19?15e4:e<=29?2e5:e<=39?25e4:3e5}function UM(e,t,n,r){if(e>=50)return null;if(t&&n){const s=Math.max(13e4,Math.min(6e5,e*11e3));return $M(r?s*1.15:s)}return t?FM(e):0}const Kp=({trigger:e,open:t,onOpenChange:n})=>{var S;const[r,s]=m.useState(10),[o,i]=m.useState(!0),[a,l]=m.useState(!1),[c,u]=m.useState(null),[d,p]=m.useState([]),h=k=>{u(E=>E===k?null:k)},x=k=>{p(E=>E.includes(k)?E.filter(R=>R!==k):[...E,k])},v=k=>{l(k),k&&i(!0)},b=k=>{k||l(!1),i(k)},w=c?((S=Kw.find(k=>k.value===c))==null?void 0:S.hard)??!1:!1,g=a,y=a&&(w||d.length>0),_=UM(r,o,a,y);return f.jsxs(bM,{open:t,onOpenChange:n,children:[e&&f.jsx(xM,{asChild:!0,children:e}),f.jsxs(fE,{className:"sm:max-w-lg max-h-[90vh] p-0",children:[f.jsx(hE,{className:"px-6 pt-6 pb-2",children:f.jsx(pE,{className:"text-2xl font-bold text-primary-foreground text-center",children:"ìì ìë¬¸ë£ ê²¬ì ìì보기"})}),f.jsx(RE,{className:"max-h-[calc(90vh-100px)] px-6 pb-6",children:f.jsxs("div",{className:"space-y-6",children:[f.jsxs("div",{children:[f.jsx("label",{className:"text-sm font-semibold text-foreground mb-3 block",children:"구ë¶"}),f.jsxs("div",{className:"space-y-3",children:[f.jsxs("label",{className:"flex items-center gap-3 cursor-pointer",children:[f.jsx(Va,{checked:o,onCheckedChange:k=>b(!!k)}),f.jsx("span",{className:"text-sm text-foreground",children:"ì¸ì¬ë
¸ë¬´ê´ë¦¬ ì문"})]}),f.jsxs("label",{className:"flex items-center gap-3 cursor-pointer",children:[f.jsx(Va,{checked:a,onCheckedChange:k=>v(!!k)}),f.jsx("span",{className:"text-sm text-foreground",children:"ê¸ì¬ê´ë¦¬ ë° 4ë ë³´í ì¬ë¬´ëí"})]})]})]}),f.jsxs("div",{children:[f.jsx("label",{className:"text-sm font-semibold text-foreground mb-3 block",children:"ì
ì¢
ì í"}),f.jsx("div",{className:"grid grid-cols-2 gap-3",children:Kw.map(k=>f.jsxs("label",{className:"flex items-center gap-2 cursor-pointer",children:[f.jsx(Va,{checked:c===k.value,onCheckedChange:()=>h(k.value)}),f.jsx("span",{className:"text-sm text-foreground",children:k.label})]},k.value))})]}),f.jsxs("div",{children:[f.jsxs("div",{className:"flex justify-between items-center mb-4",children:[f.jsx("label",{className:"text-sm font-semibold text-foreground",children:"ìì ê·¼ë¡ì ì"}),f.jsxs("span",{className:"text-2xl font-bold text-accent",children:[r,"ëª
"]})]}),f.jsx(T1,{value:[r],onValueChange:k=>s(k[0]),min:1,max:50,step:1,className:"[&_[role=slider]]:bg-accent [&_[role=slider]]:border-accent [&_span:first-child_span]:bg-accent"}),f.jsxs("div",{className:"flex justify-between text-xs text-muted-foreground mt-2",children:[f.jsx("span",{children:"1ëª
"}),f.jsx("span",{children:"50ëª
"})]})]}),f.jsxs("div",{className:g?"":"opacity-50",children:[f.jsx("label",{className:"text-sm font-semibold text-foreground mb-3 block",children:"ì´ì íí"}),f.jsx("div",{className:"space-y-3",children:LM.map(k=>f.jsxs("label",{className:`flex items-start gap-2 ${g?"cursor-pointer":"cursor-not-allowed"}`,children:[f.jsx(Va,{checked:d.includes(k),onCheckedChange:()=>x(k),className:"mt-0.5",disabled:!g}),f.jsx("span",{className:"text-sm text-foreground",children:k})]},k))})]}),f.jsxs("div",{className:"text-center bg-primary/5 rounded-xl p-6",children:[f.jsx("p",{className:"text-sm text-muted-foreground mb-2",children:"ìì ì ì문ë£"}),r>=50?f.jsxs("div",{children:[f.jsx("p",{className:"text-3xl font-bold text-primary",children:"ë³ë 문ì"}),f.jsx("p",{className:"text-sm text-muted-foreground mt-2",children:"50ì¸ ì´ìì ì í ìë´ì´ íìí©ëë¤"})]}):o?f.jsxs("p",{className:"text-4xl font-bold text-accent",children:[(_??0).toLocaleStr
228ing(),f.jsx("span",{className:"text-lg font-normal text-muted-foreground ml-1",children:"ì/ì"})]}):f.jsx("p",{className:"text-lg text-muted-foreground",children:"ìë¹ì¤ë¥¼ ì íí´ì£¼ì¸ì"})]}),f.jsx("p",{className:"text-xs text-muted-foreground text-center",children:"â» ì ê¸ì¡ì ìì 견ì ì´ë©°, ìë´ í ìµì¢ ê²°ì ë©ëë¤."})]})})]})]})},Gw=[{label:"구ì±ì ìê°",href:"#team"},{label:"주ì ìë¹ì¤",href:"#services"},{label:"ì 무ì¬ë¡",href:"#cases"},{label:"FAQ",href:"#faq"},{label:"ìë´ìì½",href:"#booking"}],BM=()=>{const[e,t]=m.useState(!1),[n,r]=m.useState(!1),s=Do(),o=Hs();m.useEffect(()=>{const l=()=>t(window.scrollY>50);return window.addEventListener("scroll",l),()=>window.removeEventListener("scroll",l)},[]);const i=()=>{o.pathname!=="/"?s("/"):window.scrollTo({top:0,behavior:"smooth"})},a=l=>{var c;r(!1),o.pathname!=="/"?s("/"+l):(c=document.querySelector(l))==null||c.scrollIntoView({behavior:"smooth"})};return f.jsxs("header",{className:`fixed top-0 left-0 right-0 z-50 transition-all duration-500 ease-in-out ${e?"bg-background/95 backdrop-blur-md shadow-lg":"bg-transparent"}`,children:[f.jsxs("div",{className:"container mx-auto flex items-center justify-between h-20 px-4 pl-8",children:[f.jsx("a",{href:"#",onClick:l=>{l.preventDefault(),i()},className:"cursor-pointer",children:f.jsx("img",{src:"/logo.png",alt:"êµë³´ ì¸ì¬ë ¸ë¬´ì»¨ì¤í ë¡ê³ ",className:"h-10 md:h-14"})}),f.jsxs("nav",{className:"hidden md:flex items-center gap-8 pr-8",children:[Gw.map(l=>f.jsx("button",{onClick:()=>a(l.href),className:`text-base font-medium transition-colors duration-500 relative after:content-[''] after:absolute after:left-0 after:bottom-[-4px] after:w-full after:h-[2px] after:bg-[hsl(200,60%,60%)] after:scale-x-0 after:origin-center after:transition-transform after:duration-300 hover:after:scale-x-100 ${e?"text-foreground":"text-white"}`,children:l.label},l.href)),f.jsx(Kp,{trigger:f.jsx("button",{className:`text-base font-medium transition-colors duration-500 relative after:content-[''] after:absolute after:left-0 after:bottom-[-4px] after:w-full after:h-[2px] after:bg-[hsl(200,60%,60%)] after:scale-x-0 after:origin-center after:transition-transform after:duration-300 hover:after:scale-x-100 ${e?"text-foreground":"text-white"}`,children:"ìë¬¸ë£ ê²¬ì "})})]}),f.jsx("button",{className:"md:hidden min-h-11 min-w-11 flex items-center justify-center",onClick:()=>r(!n),"aria-label":n?"ë©ë´ ë«ê¸°":"ë©ë´ ì´ê¸°","aria-expanded":n,children:n?f.jsx(Od,{className:`transition-colors duration-500 ${e?"text-foreground":"text-white"}`}):f.jsx(mA,{className:`transition-colors duration-500 ${e?"text-foreground":"text-white"}`})})]}),f.jsx("div",{className:`md:hidden overflow-hidden transition-all duration-500 ease-in-out ${n?"max-h-96 opacity-100":"max-h-0 opacity-0"}`,children:f.jsx("div",{className:"bg-background border-t shadow-lg",children:f.jsxs("nav",{className:"flex flex-col p-4 gap-3",children:[Gw.map(l=>f.jsx("button",{onClick:()=>a(l.href),className:"text-sm font-medium text-foreground py-2 text-left hover:text-accent",children:l.label},l.href)),f.jsx(Kp,{trigger:f.jsx("button",{className:"text-sm font-medium text-foreground py-2 text-left hover:text-accent",children:"ìë¬¸ë£ ê²¬ì "})})]})})})]})},Gp=Eg("inline-flex items-center justify-center gap-2 whitespace-nowrap rounded-md text-sm font-medium ring-offset-background transition-colors focus-visible:outline-none focus-visible:ring-2 focus-visible:ring-ring focus-visible:ring-offset-2 disabled:pointer-events-none disabled:opacity-50 [&_svg]:pointer-events-none [&_svg]:size-4 [&_svg]:shrink-0",{variants:{variant:{default:"bg-primary text-primary-foreground hover:bg-primary/90",destructive:"bg-destructive text-destructive-foreground hover:bg-destructive/90",outline:"border border-input bg-background hover:bg-accent hover:text-accent-foreground",secondary:"bg-secondary text-secondary-foreground hover:bg-secondary/80",ghost:"hover:bg-accent hover:text-accent-foreground",link:"text-primary underline-offset-4 hover:underline"},size:{default:"h-10 px-4 py-2",sm:"h-9 rounded-md px-3",lg:"h-11 rounded-md px-8",icon:"h-10 w-10"}},defaultVariants:{variant:"default",size:"default"}}),Yu=m.forwardRef(({className:e,variant:t,size:n,asChild:r=!1,...s},o)=>{const i=r?gN:"button";return f.jsx(i,{className:me(Gp({variant:t,size:n,className:e})),ref:o,...s})});Yu.displayName="Button";const zM="/assets/slide-1-ml28xOgf.jpg",WM="/assets/slide-2-BLehcY2c.jpg",HM="/assets/slide-3-Y2Or9D92.jpg",gn=[{image:zM,title:f.jsxs(f.Fragment,{children:["ë¹ì ì ë ë í",f.jsx("br",{}),"ì¸ì¬ë ¸ë¬´ê´ë¦¬ íí¸ë"]}),subtitle:`ë기ì ì¸ì¬í ì¶ì 229ê³µì¸ë ¸ë¬´ì¬ê° ì ê³µíë ì¸ì¬ ì¤ë¬´ ì문`,cta:{label:"ìë¬¸ë£ ê°í¸ 견ì ",target:"#calculator",modal:!0}},{image:WM,title:f.jsxs(f.Fragment,{children:["ê¸ì¬ê´ë¦¬ë¥¼",f.jsx("br",{}),"ì¡°ê¸ ë í¨ì¨ì ì¼ë¡!"]}),subtitle:`ê¸ì¬ ì°ì ë¶í° 4ëë³´í ì ê³ ê¹ì§,
230ì 문ê°ìê² ë§¡ê¸°ì¸ì!`,cta:{label:"ìë¹ì¤ ìì¸í 보기",target:"#services"}},{image:HM,title:f.jsxs(f.Fragment,{children:["ë¶ë¹í´ê³ ì¬ê±´ì",f.jsx("br",{}),"ì 문ê°ìê² ë§¡ê¸°ì¸ì"]}),subtitle:`íë¶í ë ¸ëììí ê²½íì¼ë¡ 231ìµì ì 결과를 ì´ëì´ë ëë¤`,cta:{label:"ì±ê³µì¬ë¡ íì¸",target:"#cases",tab:"ë¶ë¹í´ê³ "},cta2:{label:"ë¶ë¹í´ê³ ì§ë¨",route:"/diagnosis"}}],VM=()=>{const[e,t]=m.useState(0),[n,r]=m.useState(!1),[s,o]=m.useState(!1),i=Do(),a=m.useCallback(p=>{n||(r(!0),t(p),setTimeout(()=>r(!1),700))},[n]),l=m.useCallback(()=>a((e+1)%gn.length),[e,a]),c=m.useCallback(()=>a((e-1+gn.length)%gn.length),[e,a]);m.useEffect(()=>{const p=setInterval(l,6e3);return()=>clearInterval(p)},[l]);const u=p=>{var h;(h=document.querySelector(p))==null||h.scrollIntoView({behavior:"smooth"})},d=p=>{p.cta.modal?o(!0):(p.cta.tab&&window.dispatchEvent(new CustomEvent("set-cases-tab",{detail:p.cta.tab})),u(p.cta.target))};return f.jsxs("section",{"aria-label":"ë©ì¸ ë°°ë",className:"relative min-h-[85vh] flex items-center justify-center overflow-hidden",children:[gn.map((p,h)=>f.jsx("div",{className:"absolute inset-0 transition-opacity duration-700 ease-in-out",style:{opacity:h===e?1:0},children:f.jsx("img",{src:p.image,alt:"",className:"w-full h-full object-cover",loading:h===0?"eager":"lazy",...h===0?{fetchPriority:"high",decoding:"sync"}:{decoding:"async"}})},h)),f.jsx("div",{className:"absolute inset-0 bg-gradient-to-b from-black/80 via-black/50 to-transparent"}),f.jsx("div",{className:"relative z-10 w-full mx-auto px-4 text-center max-w-4xl",children:f.jsxs("div",{className:"min-h-[200px] flex flex-col items-center justify-center",children:[f.jsx("h1",{className:"w-full text-3xl md:text-5xl lg:text-6xl font-bold text-primary-foreground leading-snug md:leading-snug lg:leading-snug mb-6 animate-fade-in text-center",children:gn[e].title},e),f.jsx("p",{className:"w-full text-base md:text-xl text-primary-foreground/70 mb-10 max-w-2xl mx-auto animate-fade-in whitespace-pre-line text-center",children:gn[e].subtitle},`sub-${e}`),f.jsxs("div",{className:"flex flex-col sm:flex-row gap-4 justify-center animate-fade-in",children:[gn[e].cta2&&f.jsx(Yu,{size:"lg",variant:"outline",onClick:()=>i(gn[e].cta2.route),className:"bg-[hsl(175,30%,25%)] text-white hover:bg-[hsl(175,30%,30%)] border-none rounded-full px-8 text-base h-12",children:gn[e].cta2.label}),f.jsx(Yu,{size:"lg",onClick:()=>d(gn[e]),className:"bg-accent text-accent-foreground hover:bg-accent/90 rounded-full px-8 text-base h-12",children:gn[e].cta.label})]})]})}),f.jsx("button",{onClick:c,className:"absolute left-4 top-1/2 -translate-y-1/2 z-20 p-2 rounded-full bg-black/30 hover:bg-black/50 text-white transition-colors","aria-label":"ì´ì ì¬ë¼ì´ë",children:f.jsx(Nd,{className:"w-6 h-6"})}),f.jsx("button",{onClick:l,className:"absolute right-4 top-1/2 -translate-y-1/2 z-20 p-2 rounded-full bg-black/30 hover:bg-black/50 text-white transition-colors","aria-label":"ë¤ì ì¬ë¼ì´ë",children:f.jsx(Ad,{className:"w-6 h-6"})}),f.jsx("div",{className:"absolute bottom-8 left-1/2 -translate-x-1/2 z-20 flex gap-3",children:gn.map((p,h)=>f.jsx("button",{onClick:()=>a(h),className:`w-3 h-3 rounded-full transition-all duration-300 ${h===e?"bg-white scale-125":"bg-white/40 hover:bg-white/60"}`,"aria-label":`ì¬ë¼ì´ë ${h+1}`},h))}),f.jsx(Kp,{open:s,onOpenChange:o})]})},Ms=({threshold:e=.15,delay:t=0}={})=>{const n=m.useRef(null),[r,s]=m.useState(!1),o=m.useRef(null);m.useEffect(()=>{var u;(u=o.current)==null||u.disconnect();const a=n.current;if(!a||r)return;const l=a.getBoundingClientRect();if(l.top<window.innerHeight&&l.bottom>0){setTimeout(()=>s(!0),t);return}const c=new IntersectionObserver(([d])=>{d.isIntersecting&&(setTimeout(()=>s(!0),t),c.disconnect())},{threshold:Math.min(e,.05),rootMargin:"50px"});return c.observe(a),o.current=c,()=>c.disconnect()});const i={opacity:r?1:0,transform:r?"translateY(0)":"translateY(30px)",transition:`opacity 0.7s ease-out ${t}ms, transform 0.7s ease-out ${t}ms`};return{ref:n,style:i}};async function ev(e){const t="https://genfddadfnmdhnlyyctm.supabase.co",n="eyJhbGciOiJIUzI1NiIsInR5cCI6IkpXVCJ9.eyJpc3MiOiJzdXBhYmFzZSIsInJlZiI6ImdlbmZkZGFkZm5tZGhubHl5Y3RtIiwicm9sZSI6ImFub24iLCJpYXQiOjE3NzAzMzg3NDgsImV4cCI6MjA4NTk
231xNDc0OH0.Z9pf9T0Rn_LeRpEQlycwEFLe1G8PXwx39P_iN5hzYbA",r=await fetch(`${t}/rest/v1/${e}`,{method:"GET",headers:{apikey:n,authorization:`Bearer ${n}`,"accept-profile":"public",accept:"application/json"}});if(!r.ok){const o=await r.text().catch(()=>"");throw new Error(`HTTP ${r.status}: ${o}`)}const s=await r.json();return Array.isArray(s)?s:[]}const qM=()=>{const e=Ms(),t=Ms({delay:200}),[n,r]=m.useState(0),[s,o]=m.useState([]);m.useEffect(()=>{let u=!1;return(async()=>{try{const p=await ev("admin_profiles?member_type=eq.ê´ë¦¬ì&order=created_at.asc&select=id,name,member_type,bio,avatar_url");!u&&p.length>0&&o(p.map(h=>({id:h.id,name:h.name,member_type:h.member_type||"íì",bio:h.bio||null,avatar_url:h.avatar_url||null})))}catch(p){console.error("[TeamSection] fetch error:",p)}})(),()=>{u=!0}},[]);const i=[];for(let u=0;u<s.length;u+=2)i.push(s.slice(u,u+2));const a=i.length,l=m.useCallback(()=>{r(u=>(u+1)%a)},[a]),c=m.useCallback(()=>{r(u=>(u-1+a)%a)},[a]);return m.useEffect(()=>{if(a<=1)return;const u=setInterval(l,5e3);return()=>clearInterval(u)},[l,a]),s.length===0?null:f.jsx("section",{id:"team",className:"py-20 md:py-28 bg-background",children:f.jsxs("div",{className:"container mx-auto px-4",children:[f.jsx("div",{ref:e.ref,style:e.style,className:"text-center mb-14",children:f.jsx("h2",{className:"text-3xl md:text-4xl font-bold text-white mb-4",children:"구ì±ì ìê°"})}),f.jsxs("div",{ref:t.ref,style:t.style,className:"max-w-4xl mx-auto relative",children:[f.jsx("div",{className:"relative overflow-hidden",children:f.jsx("div",{className:"flex transition-transform duration-500 ease-in-out",style:{transform:`translateX(-${n*100}%)`},children:i.map((u,d)=>f.jsx("div",{className:"w-full flex-shrink-0 px-4",children:f.jsx("div",{className:"grid grid-cols-1 md:grid-cols-2 gap-6",children:u.map(p=>f.jsxs("div",{className:"bg-secondary rounded-2xl p-8 text-left",children:[f.jsx("div",{className:"w-24 h-24 rounded-full bg-muted flex items-center justify-center mb-5 overflow-hidden ml-auto",children:p.avatar_url?f.jsx("img",{src:p.avatar_url,alt:p.name,className:"w-full h-full object-cover"}):f.jsx($u,{className:"w-10 h-10 text-muted-foreground"})}),f.jsx("h3",{className:"text-xl font-bold text-foreground mb-1",children:p.name}),p.bio&&f.jsx("p",{className:"text-sm text-muted-foreground leading-relaxed whitespace-pre-line",children:p.bio})]},p.id))})},d))})}),a>1&&f.jsxs(f.Fragment,{children:[f.jsx("button",{onClick:c,"aria-label":"ì´ì 구ì±ì 보기",className:"absolute left-2 md:-left-14 top-1/2 -translate-y-1/2 w-10 h-10 rounded-full bg-secondary/80 hover:bg-secondary flex items-center justify-center text-foreground transition-colors z-10",children:f.jsx(Nd,{className:"w-5 h-5"})}),f.jsx("button",{onClick:l,"aria-label":"ë¤ì 구ì±ì 보기",className:"absolute right-2 md:-right-14 top-1/2 -translate-y-1/2 w-10 h-10 rounded-full bg-secondary/80 hover:bg-secondary flex items-center justify-center text-foreground transition-colors z-10",children:f.jsx(Ad,{className:"w-5 h-5"})}),f.jsx("div",{className:"flex justify-center gap-2 mt-6",children:i.map((u,d)=>f.jsx("button",{onClick:()=>r(d),"aria-label":`구ì±ì ì¬ë¼ì´ë ${d+1}ë¡ ì´ë`,className:`w-2.5 h-2.5 rounded-full transition-colors ${d===n?"bg-accent":"bg-muted-foreground/30"}`},d))})]})]})]})})},NE=m.forwardRef(({className:e,...t},n)=>f.jsx("div",{ref:n,className:me("rounded-lg border bg-card text-card-foreground shadow-sm",e),...t}));NE.displayName="Card";const KM=m.forwardRef(({className:e,...t},n)=>f.jsx("div",{ref:n,className:me("flex flex-col space-y-1.5 p-6",e),...t}));KM.displayName="CardHeader";const GM=m.forwardRef(({className:e,...t},n)=>f.jsx("h3",{ref:n,className:me("text-2xl font-semibold leading-none tracking-tight",e),...t}));GM.displayName="CardTitle";const YM=m.forwardRef(({className:e,...t},n)=>f.jsx("p",{ref:n,className:me("text-sm text-muted-foreground",e),...t}));YM.displayName="CardDescription";const AE=m.forwardRef(({className:e,...t},n)=>f.jsx("div",{ref:n,className:me("p-6 pt-0",e),...t}));AE.displayName="CardContent";const ZM=m.forwardRef(({className:e,...t},n)=>f.jsx("div",{ref:n,className:me("flex items-center p-6 pt-0",e),...t}));
231ZM.displayName="CardFooter";const QM=[{icon:vA,title:"ì¸ì¬ë ¸ë¬´ê´ë¦¬ ì문",description:`ãê·¼ë¡ê³ì½, ìê¸, ê·¼ë¡ìê°, í´ì¼ãí´ê°, ì§ê³ ë± ë²ë¥ ì문 232ãê·¼ë¡ê³ì½ì, ì·¨ì ê·ì¹ ë± ì¬ë´ ê·ì ê²í 233ãìµì ì¸ì¬ë ¸ë¬´ ì´ì ë° ì¬ë¡ ìë´`},{icon:lA,title:"ê¸ì¬ê´ë¦¬ ë° 4ë ë³´í ì¬ë¬´ëí",description:`ãê¸ì¬ ê³ì°, ê¸ì¬ëì¥ãê¸ì¬ëª ì¸ì ë°í 234ã4ë ë³´í ì¬ì ì¥ ì±ë¦½ ë° ì·¨ëãìì¤ ì ê³ 235ã4ë ë³´í ë³´ìì´ì¡ ì ê³ ë° ì ì°`},{icon:yA,title:"ë ¸ë ì¬ê±´ ëì",description:`ãë¶ë¹í´ê³ ë± êµ¬ì ì ì² (ê·¼ë¡ì/ì¬ì©ì) 236ãì§ì¥ ë´ ê´´ë¡í ì¡°ì¬ ë° ì¡°ì¬ê²°ê³¼ ë³´ê³ 237ãë ¸ëê´ê³ë²ë ¹ ìë° ë± ì§ì ì¬ê±´`},{icon:fA,title:"ë ¸ë¬´ì ê³µì ë³´íì¬ë¬´ ëí",description:`ãê·¼ë¡ë³µì§ê³µë¨ ê³ ì© ë° ì°ì¬ë³´í ê°ì¢ ì ê³ 238ãë ¸ë¬´ì ê³µì ì ë³´ìì¡ ì ê³ ëí 239ãê³ ì©Â·ì°ì¬ ë³´íë£ ë¶ê³¼ ë´ì íì¸ ë° ì ì `}],JM=()=>{const e=Ms(),t=Ms({delay:200});return f.jsx("section",{id:"services",className:"py-20 md:py-28 bg-background",children:f.jsxs("div",{className:"container mx-auto px-4",children:[f.jsx("div",{ref:e.ref,style:e.style,className:"text-center mb-14",children:f.jsx("h2",{className:"text-3xl md:text-4xl font-bold text-white mb-4",children:"주ì ìë¹ì¤"})}),f.jsx("div",{ref:t.ref,style:t.style,className:"grid grid-cols-1 md:grid-cols-2 gap-8 max-w-4xl mx-auto",children:QM.map(n=>f.jsx(NE,{className:"group border-0 shadow-lg hover:shadow-xl transition-all duration-300 hover:-translate-y-1",children:f.jsxs(AE,{className:"p-8 text-center",children:[f.jsx("div",{className:"w-16 h-16 rounded-2xl bg-accent/10 flex items-center justify-center mx-auto mb-6 group-hover:bg-accent/20 transition-colors",children:f.jsx(n.icon,{className:"w-8 h-8 text-accent"})}),f.jsx("h3",{className:"text-xl font-bold text-foreground mb-3",children:n.title}),f.jsx("div",{className:"text-muted-foreground text-sm text-left",style:{lineHeight:"1.8"},children:n.description.split(` 240`).map((r,s)=>f.jsx("p",{className:"pl-4",style:{textIndent:"-1em"},children:r},s))})]})},n.title))})]})})},jz={ë¶ë¹í´ê³ :["ì¸ì©","기ê°","íí´","ì´ì¬ì·¨ì","ì´ì¬ì ì§"],ë ¸ë리뷰:["ê·¼ë¡ê³ì½","ê·¼ë¡ìê°","ì°ì°¨í´ê°","ìê¸","ì§ê³","í´ì§","í´ê³ ","í´ì¼","ì 무ìë£","기í"],ìë´ì¬ë¡:["ê·¼ë¡ê³ì½","ê·¼ë¡ìê°","ì°ì°¨í´ê°","ìê¸","ì§ê³","í´ì§","í´ê³ ","í´ì¼","ì 무ìë£","기í"],ë ¸ëë´ì¤:["ê·¼ë¡ê³ì½","ê·¼ë¡ìê°","ì°ì°¨í´ê°","ìê¸","ì§ê³","í´ì§","í´ê³ ","í´ì¼","ì 무ìë£","기í"]},Na=["ì ì²´","ë ¸ë리뷰","ë¶ë¹í´ê³ ","ìë´ì¬ë¡","ë ¸ëë´ì¤"],XM={ë ¸ë리뷰:"bg-sky-500/15 text-sky-400",ë¶ë¹í´ê³ :"bg-orange-500/15 text-orange-400",ìë´ì¬ë¡:"bg-blue-500/15 text-blue-400",ë ¸ëë´ì¤:"bg-emerald-500/15 text-emerald-400"},eL={ì¸ì©:"bg-blue-500/15 text-blue-400",기ê°:"bg-red-500/15 text-red-400",íí´:"bg-green-500/15 text-green-400",ì´ì¬ì·¨ì:"bg-purple-500/15 text-purple-400",ì´ì¬ì ì§:"bg-yellow-500/15 text-yellow-400",ê·¼ë¡ê³ì½:"bg-indigo-500/15 text-indigo-400",ê·¼ë¡ìê°:"bg-cyan-500/15 text-cyan-400",ì°ì°¨í´ê°:"bg-lime-500/15 text-lime-400",ìê¸:"bg-yellow-500/15 text-yellow-400",ì§ê³:"bg-red-500/15 text-red-400",í´ì§:"bg-purple-500/15 text-purple-400",í´ê³ :"bg-pink-500/15 text-pink-400",í´ì¼:"bg-green-500/15 text-green-400",ì 무ìë£:"bg-blue-500/15 text-blue-400",기í:"bg-gray-500/15 text-gray-400"},tL=e=>XM[e]||"bg-primary text-primary-foreground",nL=e=>eL[e]||"bg-muted text-muted-foreground",rh=5,rL=7e3,sL=e=>{if(!e)return"";try{return(new DOMParser().parseFromString(e,"text/html").body.textContent||"").replace(/\s+/g," ").trim()}catch{return e.replace(/<[^>]*>/g," ").replace(/ /g," ").replace(/&/g,"&").replace(/</g,"<").replace(/>/g,">").replace(/\s+/g," ").trim()}},oL=()=>{const e=Ms(),[t,n]=m.useState([]),[r,s]=m.useState(!0),[o,i]=m.useState(null),a=Do(),[l,c]=m.useState("ì ì²´"),[u,d]=m.useState(1),[p,h]=m.useState(!1),x=m.useRef(null),v=m.useCallback(()=>{x.current&&clearInterval(x.current),x.current=setInterval(()=>{c(E=>{const R=Na.indexOf(E);return Na[(R+1)%Na.length]}),d(1)},rL)},[]);m.useEffect(()=>(p||v(),()=>{x.current&&clearInterval(x.current)}),[p,v]);const b=()=>{h(!0),x.current&&(clearInterval(x.current),x.current=null)},w=E=>{b(),c(E),d(1)},g=E=>{b(),a(`/blog/${E.post_number}`)};m.useEffect(()=>{const E=R=>{const P=R.detail;Na.includes(P)&&(b(),c(P),d(1))};return window.addEventListener("set-cases-tab",E),()=>window.removeEventListener("set-cases-tab",E)},[]);const y=m.useCallback(async()=>{s(!0),i(null);const E="https://genfddadfnmdhnlyyctm.supabase.co",R="eyJhbGciOiJIUzI1NiIsInR5cCI6IkpXVCJ9.eyJpc3MiOiJzdXBhYmFzZSIsInJlZiI6ImdlbmZkZGFkZm5tZGhubHl5Y3RtIiwicm9sZSI6ImFub24iLCJpYXQiOjE3NzAzMzg3NDgsImV4cCI6MjA4NTk
240xNDc0OH0.Z9pf9T0Rn_LeRpEQlycwEFLe1G8PXwx39P_iN5hzYbA",P=encodeURIComponent("id,post_number,author,author_avatar_url,category,subcategory,title,description"),A=`${E}/rest/v1/cases?select=${P}&order=created_at.desc&limit=30`,D=async M=>{const H=new AbortController,L=setTimeout(()=>H.abort(),M);try{const Z=await fetch(A,{method:"GET",headers:{apikey:R,authorization:`Bearer ${R}`,"accept-profile":"public",accept:"application/json"},signal:H.signal});if(!Z.ok){const B=await Z.text().catch(()=>"");throw new Error(`HTTP ${Z.status}: ${B}`)}return await Z.json()}finally{clearTimeout(L)}};try{const M=await D(6e3).catch(()=>D(1e4));n(Array.isArray(M)?M:[])}catch(M){const H=M instanceof Error?M.message:"unknown error";console.error("[CasesSection] Fetch error:",H),n([]),i(H)}finally{s(!1)}},[]);m.useEffect(()=>{y();const E=window.setInterval(y,15e3);return()=>window.clearInterval(E)},[y]);const _=l==="ì ì²´"?t:t.filter(E=>E.category===l),S=Math.ceil(_.length/rh),k=_.slice((u-1)*rh,u*rh);return f.jsx("section",{id:"cases",className:"py-20 md:py-28 bg-background",children:f.jsxs("div",{ref:e.ref,style:e.style,className:"container mx-auto px-4",children:[f.jsx("div",{className:"text-center mb-14",children:f.jsx("h2",{className:"text-3xl md:text-4xl font-bold text-white mb-4",children:"ì
무 ì¬ë¡"})}),f.jsx("div",{className:"flex flex-wrap justify-center gap-2 mb-8",children:Na.map(E=>f.jsx("button",{onClick:()=>w(E),className:`px-5 py-2 rounded-full text-sm font-semibold transition-all duration-200 ${l===E?"bg-accent text-accent-foreground shadow-md":"bg-secondary text-muted-foreground hover:bg-muted"}`,children:E},E))}),f.jsx("div",{className:"max-w-4xl mx-auto flex flex-col divide-y divide-border rounded-2xl bg-secondary overflow-hidden shadow-sm",style:{minHeight:630},children:r?f.jsx("div",{className:"p-12 text-center text-muted-foreground flex-1 flex items-center justify-center",children:"ê²ìê¸ì ë¶ë¬ì¤ë ì¤ì
ëë¤..."}):o?f.jsx("div",{className:"p-12 text-center text-muted-foreground",children:"ê²ìê¸ì ë¶ë¬ì¤ì§ 못íìµëë¤."}):k.length===0?f.jsx("div",{className:"p-12 text-center text-muted-foreground",children:"í´ë¹ ì¹´í
ê³ ë¦¬ì ê²ìê¸ì´ ììµëë¤."}):k.map(E=>f.jsxs("div",{onClick:()=>g(E),className:"flex gap-5 p-6 md:p-8 hover:bg-muted/50 transition-colors cursor-pointer",children:[f.jsxs("div",{className:"flex-shrink-0 w-20 flex flex-col items-center gap-2",children:[f.jsx("div",{className:"w-14 h-14 rounded-full bg-muted flex items-center justify-center overflow-hidden",children:E.author_avatar_url?f.jsx("img",{src:E.author_avatar_url,alt:E.author,className:"w-full h-full object-cover"}):f.jsx($u,{className:"w-7 h-7 text-muted-foreground"})}),f.jsx("span",{className:"text-xs text-muted-foreground font-medium whitespace-nowrap",children:E.author})]}),f.jsxs("div",{className:"flex-1 min-w-0",children:[f.jsxs("div",{className:"flex flex-wrap gap-1.5 mb-2",children:[f.jsx("span",{className:`inline-block text-xs font-semibold rounded-full px-3 py-1 ${tL(E.category)}`,children:E.category}),E.subcategory&&f.jsx("span",{className:`inline-block text-xs font-semibold rounded-full px-3 py-1 ${nL(E.subcategory)}`,children:E.subcategory})]}),f.jsx("h3",{className:"text-base md:text-lg font-bold text-foreground mb-1 line-clamp-2",children:E.title}),f.jsx("p",{className:"text-sm text-muted-foreground line-clamp-2 leading-relaxed",children:sL(E.description)})]})]},E.id))}),S>1&&f.jsxs("div",{className:"flex items-center justify-center gap-1 mt-6",children:[f.jsx("button",{onClick:()=>{b(),d(E=>Math.max(1,E-1))},disabled:u===1,className:"w-10 h-10 rounded-lg bg-secondary flex items-center justify-center text-muted-foreground hover:bg-muted disabled:opacity-30 transition-colors",children:f.jsx(Nd,{className:"w-4 h-4"})}),Array.from({length:S},(E,R)=>R+1).map(E=>f.jsx("button",{onClick:()=>{b(),d(E)},className:`w-10 h-10 rounded-lg text-sm font-bold transition-colors ${u===E?"bg-accent text-accent-foreground":"bg-secondary text-muted-foreground hover:bg-muted"}`,children:E},E)),f.jsx("button",{onClick:()=>{b(),d(E=>Math.min(S,E+1))},disabled:u===S,className:"w-10 h-10 rounded-lg bg-secondary flex items-center justify-center text-muted-foreground hover:bg-muted disabled:opacity-30 transition-colors",children:f.jsx(Ad,{className:"w-4 h-4"})})]})]})})},Yw=({partners:e,reverse:t=!1})=>{const n=[...e,...e,...e],r=t?"marquee-reverse":"marquee";return f.jsx("div",{className:"relative overflow-hidden",children:f.jsx("div",{className:"flex w-max",style:{animation:`${r} 45s linear infinite`},onMouseEnter:s=>s.currentTarget.style.animationPlayState="paused",onMouseLeave:s=>s.currentTarget.style.animationPlayState="running",children:n.map((s,o)=>f.jsx("div",{className:"flex items-center justify-center mx-4 md:mx-8 w-[140px] md:w-[200px] shrink-0 h-14 md:h-20 rounded-md overflow-hidden",children:s.logo_url?f.jsx("img",{src:s.logo_url,alt:s.name,className:"w-full h-full object-cover",loading:"lazy"}):f.jsx("span",{className:"text-muted-foreground font-semibold text-sm",children:s.name})},`${s.id}-${o}`))})})},iL=()=>{const e=Ms(),[t,n]=m.useState([]),[r,s]=m.useState(!0),[o,i]=m.useState(null);m.useEffect(()=>{let u=!1;const d=async()=>{s(!0),i(null);try{const h=await ev("partners?select=id,name,logo_url,display_order&order=display_order.asc");u||n(h)}catch(h){const x=h instanceof Error?h.message:"unknown error";console.error("[PartnersSection] Fetch error:",x),u||i(x)}finally{u||s(!1)}};d();const p=window.setTimeout(()=>{!u&&t.length===0&&d()},3e3);return()=>{u=!0,window.clearTimeout(p)}},[]);const a=Math.ceil(t.length/2),l=t.slice(0,a),c=t.slice(a);return f.jsx("section",{className:"py-12 bg-secondary border-y border-border",children:f.jsxs("div",{ref:e.ref,style:e.style,children:[f.jsx("div",{className:"container mx-auto px-4 mb-8",children:f.jsx("p",{className:"text-center text-xs font-semibold tracking-[0.3em] text-muted-foreground uppercase",children:"주ì íìì¬"})}),r?f.jsx("div",{className:"container mx-auto px-4 text-center text-muted-foreground text-sm",children:"íìì¬ ë°°ë를 ë¶ë¬ì¤ë ì¤ì
ëë¤..."}):o?f.jsx("div",{className:"container mx-auto px-4 text-center text-muted-foreground text-sm",children:"íìì¬ ë°°ë를 ë¶ë¬ì¤ì§ 못íìµëë¤."}):t.length===0?f.jsx("div",{className:"container mx-auto px-4 text-center text-muted-foreground text-sm",children:"ë±ë¡ë íìì¬ê° ììµëë¤."}):f.jsxs("div",{className:"space-y-8",children:[f.jsx(Yw,{partners:l}),f.jsx(Yw,{partners:c,reverse:!0})]})]})})};/*! @license DOMPurify 3.3.1 | (c) Cure53 and other contributors | Released under the Apache license 2.0 and Mozilla Public License 2.0 | github.com/cure53/DOMPurify/blob/3.3.1/LICENSE */const{entries:OE,setPrototypeOf:Zw,isFrozen:aL,getPrototypeOf:lL,getOwnPropertyDescriptor:cL}=Object;let{freeze:Ot,seal:kn,create:Yp}=Object,{apply:Zp,construct:Qp}=typeof Reflect<"u"&&Reflect;Ot||(Ot=function(t){return t});kn||(kn=function(t){return t});Zp||(Zp=function(t,n){for(var r=arguments.length,s=new Array(r>2?r-2:0),o=2;o<r;o++)s[o-2]=arguments[o];return t.apply(n,s)});Qp||(Qp=function(t){for(var n=arguments.length,r=new Array(n>1?n-1:0),s=1;s<n;s++)r[s-1]=arguments[s];return new t(...r)});const Mc=jt(Array.prototype.forEach),uL=jt(Array.prototype.lastIndexOf),Qw=jt(Array.prototype.pop),Aa=jt(Array.prototype.push),dL=jt(Array.prototype.splice),du=jt(String.prototype.toLowerCase),sh=jt(String.prototype.toString),oh=jt(String.prototype.match),Oa=jt(String.prototype.replace),fL=jt(String.prototype.indexOf),hL=jt(String.prototype.trim),In=jt(Object.prototype.hasOwnProperty),Ct=jt(Reg
vendor: 4,370 bytes, line 240
240Exp.prototype.test),ja=pL(TypeError);function jt(e){return function(t){t instanceof RegExp&&(t.lastIndex=0);for(var n=arguments.length,r=new Array(n>1?n-1:0),s=1;s<n;s++)r[s-1]=arguments[s];return Zp(e,t,r)}}function pL(e){return function(){for(var t=arguments.length,n=new Array(t),r=0;r<t;r++)n[r]=arguments[r];return Qp(e,n)}}function ve(e,t){let n=arguments.length>2&&arguments[2]!==void 0?arguments[2]:du;Zw&&Zw(e,null);let r=t.length;for(;r--;){let s=t[r];if(typeof s=="string"){const o=n(s);o!==s&&(aL(t)||(t[r]=o),s=o)}e[s]=!0}return e}function mL(e){for(let t=0;t<e.length;t++)In(e,t)||(e[t]=null);return e}function or(e){const t=Yp(null);for(const[n,r]of OE(e))In(e,n)&&(Array.isArray(r)?t[n]=mL(r):r&&typeof r=="object"&&r.constructor===Object?t[n]=or(r):t[n]=r);return t}function Ia(e,t){for(;e!==null;){const r=cL(e,t);if(r){if(r.get)return jt(r.get);if(typeof r.value=="function")return jt(r.value)}e=lL(e)}function n(){return null}return n}const Jw=Ot(["a","abbr","acronym","address","area","article","aside","audio","b","bdi","bdo","big","blink","blockquote","body","br","button","canvas","caption","center","cite","code","col","colgroup","content","data","datalist","dd","decorator","del","details","dfn","dialog","dir","div","dl","dt","element","em","fieldset","figcaption","figure","font","footer","form","h1","h2","h3","h4","h5","h6","head","header","hgroup","hr","html","i","img","input","ins","kbd","label","legend","li","main","map","mark","marquee","menu","menuitem","meter","nav","nobr","ol","optgroup","option","output","p","picture","pre","progress","q","rp","rt","ruby","s","samp","search","section","select","shadow","slot","small","source","spacer","span","strike","strong","style","sub","summary","sup","table","tbody","td","template","textarea","tfoot","th","thead","time","tr","track","tt","u","ul","var","video","wbr"]),ih=Ot(["svg","a","altglyph","altglyphdef","altglyphitem","animatecolor","animatemotion","animatetransform","circle","clippath","defs","desc","ellipse","enterkeyhint","exportparts","filter","font","g","glyph","glyphref","hkern","image","inputmode","line","lineargradient","marker","mask","metadata","mpath","part","path","pattern","polygon","polyline","radialgradient","rect","stop","style","switch","symbol","text","textpath","title","tref","tspan","view","vkern"]),ah=Ot(["feBlend","feColorMatrix","feComponentTransfer","feComposite","feConvolveMatrix","feDiffuseLighting","feDisplacementMap","feDistantLight","feDropShadow","feFlood","feFuncA","feFuncB","feFuncG","feFuncR","feGaussianBlur","feImage","feMerge","feMergeNode","feMorphology","feOffset","fePointLight","feSpecularLighting","feSpotLight","feTile","feTurbulence"]),gL=Ot(["animate","color-profile","cursor","discard","font-face","font-face-format","font-face-name","font-face-src","font-face-uri","foreignobject","hatch","hatchpath","mesh","meshgradient","meshpatch","meshrow","missing-glyph","script","set","solidcolor","unknown","use"]),lh=Ot(["math","menclose","merror","mfenced","mfrac","mglyph","mi","mlabeledtr","mmultiscripts","mn","mo","mover","mpadded","mphantom","mroot","mrow","ms","mspace","msqrt","mstyle","msub","msup","msubsup","mtable","mtd","mtext","mtr","munder","munderover","mprescripts"]),vL=Ot(["maction","maligngroup","malignmark","mlongdiv","mscarries","mscarry","msgroup","mstack","msline","msrow","semantics","annotation","annotation-xml","mprescripts","none"]),Xw=Ot(["#text"]),e0=Ot(["accept","action","align","alt","autocapitalize","autocomplete","autopictureinpicture","autoplay","background","bgcolor","border","capture","cellpadding","cellspacing","checked","cite","class","clear","color","cols","colspan","controls","controlslist","coords","crossorigin","datetime","decoding","default","dir","disabled","disablepictureinpicture","disableremoteplayback","download","draggable","enctype","enterkeyhint","exportparts","face","for","headers","height","hidden","high","href","hreflang","id","inert","inputmode","integrity","ismap","kind","label","lang","list","loading","loop","low","max","maxlength","media","method","min","minlength","multiple","muted","name","nonce","noshade","novalidate","nowrap","open","optimum","part","pattern","placeholder","playsinline","popover","popovertarget","popovertargetaction","poster","preload","pubdate","radiogroup","readonly","rel","required","rev","reversed","role","rows","rowspan","
240spellcheck","scope","selected","shape","size","sizes","slot","span","srclang","start","src","srcset","step","style","summary","tabindex","title","translate","type","usemap","valign","value","width","wrap","xmlns","slot"]),ch=Ot(["accent-height","accumulate","additive","alignment-baseline","amplitude","ascent","attributename","attributetype","azimuth","basefrequency","baseline-shift","begin","bias","by","class","clip","clippathunits","clip-path","clip-rule","color","color-interpolation","color-interpolation-filters","color-profile","color-rendering","cx","cy","d","dx","dy","diffuseconstant","direction","display","divisor","dur","edgemode","elevation","end","exponent","fill","fill-opacity","fill-rule","filter","filterunits","flood-color","flood-opacity","font-family","font-size","font-size-adjust","font-stretch","font-style","font-variant","font-weight","fx","fy","g1","g2","glyph-name","glyphref","gradientunits","gradienttransform","height","href","id","image-rendering","in","in2","intercept","k","k1","k2","k3","k4","kerning","keypoints","keysplines","keytimes","lang","lengthadjust","letter-spacing","kernelmatrix","kernelunitlength","lighting-color","local","marker-end","marker-mid","marker-start","markerheight","markerunits","markerwidth","maskcontentunits","maskunits","max","mask","mask-type","media","method","mode","min","name","numoctaves","offset","operator","opacity","order","orient","orientation","origin","overflow","paint-order","path","pathlength","patterncontentunits","patterntransform","patternunits","points","preservealpha","preserveaspectratio","primitiveunits","r","rx","ry","radius","refx","refy","repeatcount","repeatdur","restart","result","rotate","scale","seed","shape-rendering","slope","specularconstant","specularexponent","spreadmethod","startoffset","stddeviation","stitchtiles","stop-color","stop-opacity","stroke-dasharray","stroke-dashoffset","stroke-linecap","stroke-linejoin","stroke-miterlimit","stroke-opacity","stroke","stroke-width","style","surfacescale","systemlanguage","tabindex","tablevalues","targetx","targety","transform","transform-origin","text-anchor","text-decoration","text-rendering","textlength","type","u1","u2","unicode","values","viewbox","visibility","version","vert-adv-y","vert-origin-x","vert-origin-y","width","word-spacing","wrap","writing-mode","xchannelselector","ychannelselector","x","x1","x2","xmlns","y","y1","y2","z","zoomandpan"]),t0=Ot(["accent","accentunder","align","bevelled","close","columnsalign","columnlines","columnspan","denomalign","depth","dir","display","displaystyle","encoding","fence","frame","height","href","id","largeop","length","linethickness","lspace","lquote","mathbackground","mathcolor","mathsize","mathvariant","maxsize","minsize","movablelimits","notation","numalign","open","rowalign","rowlines","rowspacing","rowspan","rspace","rquote","scriptlevel","scriptminsize","scriptsizemultiplier","selection","separator","separators","stretchy","subscriptshift","supscriptshift","symmetric","voffset","width","xmlns"]),Lc=Ot(["xlink:href","xml:id","xlink:title","xml:space","xmlns:xlink"]),yL=kn(/\{\{[\w\W]*|[\w\W]*\}\}/gm),wL=kn(/<%[\w\W]*|[\w\W]*%>/gm),bL=kn(/\$\{[\w\W]*/gm),xL=kn(/^data-[\-\w.\u00B7-\uFFFF]+$/),_L=kn(/^aria-[\-\w]+$/),jE=kn(/^(?:(?:(?:f|ht)tps?|mailto|tel|callto|sms|cid|xmpp|matrix):|[^a-z]|[a-z+.\-]+(?:[^a-z+.\-:]|$))/i),SL=kn(/^(?:\w+script|data):/i),EL=kn(/[\u0000-\u0020\u00A0\u1680\u180E\u2000-\u2029\u205F\u3000]/g),IE=kn(/^html$/i),kL=kn(/^[a-z][.\w]*(-[.\w]+)+$/i);var n0=Object.freeze({__proto__:null,ARIA_ATTR:_L,ATTR_WHITESPACE:EL,CUSTOM_ELEMENT:kL,DATA_ATTR:xL,DOCTYPE_NAME:IE,ERB_EXPR:wL,IS_ALLOWED_URI:jE,IS_SCRIPT_OR_DATA:SL,MUSTACHE_EXPR:yL,TMPLIT_EXPR:bL});const Da={element:1,attribute:2,text:3,cdataSection:4,entityReference:5,entityNode:6,progressingInstruction:7,comment:8,document:9,documentType:10,documentFragment:11,notation:12},CL=function(){return typeof window>"u"?null:window},TL=function(t,n){if(typeof t!="object"||typeof t.createPolicy!="function")return null;let r=null;
vendor: 5,505 bytes, line 240
240const s="data-tt-policy-suffix";n&&n.hasAttribute(s)&&(r=n.getAttribute(s));const o="dompurify"+(r?"#"+r:"");try{return t.createPolicy(o,{createHTML(i){return i},createScriptURL(i){return i}})}catch{return console.warn("TrustedTypes policy "+o+" could not be created."),null}},r0=function(){return{afterSanitizeAttributes:[],afterSanitizeElements:[],afterSanitizeShadowDOM:[],beforeSanitizeAttributes:[],beforeSanitizeElements:[],beforeSanitizeShadowDOM:[],uponSanitizeAttribute:[],uponSanitizeElement:[],uponSanitizeShadowNode:[]}};function DE(){let e=arguments.length>0&&arguments[0]!==void 0?arguments[0]:CL();const t=re=>DE(re);if(t.version="3.3.1",t.removed=[],!e||!e.document||e.document.nodeType!==Da.document||!e.Element)return t.isSupported=!1,t;let{document:n}=e;const r=n,s=r.currentScript,{DocumentFragment:o,HTMLTemplateElement:i,Node:a,Element:l,NodeFilter:c,NamedNodeMap:u=e.NamedNodeMap||e.MozNamedAttrMap,HTMLFormElement:d,DOMParser:p,trustedTypes:h}=e,x=l.prototype,v=Ia(x,"cloneNode"),b=Ia(x,"remove"),w=Ia(x,"nextSibling"),g=Ia(x,"childNodes"),y=Ia(x,"parentNode");if(typeof i=="function"){const re=n.createElement("template");re.content&&re.content.ownerDocument&&(n=re.content.ownerDocument)}let _,S="";const{implementation:k,createNodeIterator:E,createDocumentFragment:R,getElementsByTagName:P}=n,{importNode:A}=r;let D=r0();t.isSupported=typeof OE=="function"&&typeof y=="function"&&k&&k.createHTMLDocument!==void 0;const{MUSTACHE_EXPR:M,ERB_EXPR:H,TMPLIT_EXPR:L,DATA_ATTR:Z,ARIA_ATTR:B,IS_SCRIPT_OR_DATA:I,ATTR_WHITESPACE:T,CUSTOM_ELEMENT:N}=n0;let{IS_ALLOWED_URI:z}=n0,V=null;const X=ve({},[...Jw,...ih,...ah,...lh,...Xw]);let ee=null;const ce=ve({},[...e0,...ch,...t0,...Lc]);let le=Object.seal(Yp(null,{tagNameCheck:{writable:!0,configurable:!1,enumerable:!0,value:null},attributeNameCheck:{writable:!0,configurable:!1,enumerable:!0,value:null},allowCustomizedBuiltInElements:{writable:!0,configurable:!1,enumerable:!0,value:!1}})),Oe=null,W=null;const xe=Object.seal(Yp(null,{tagCheck:{writable:!0,configurable:!1,enumerable:!0,value:null},attributeCheck:{writable:!0,configurable:!1,enumerable:!0,value:null}}));let Me=!0,_e=!0,we=!1,Se=!0,ze=!1,ut=!0,kt=!1,fn=!1,Rn=!1,hn=!1,Pn=!1,Ks=!1,Qr=!0,ua=!1;const Sr="user-content-";let da=!0,Gs=!1,tt={},dt=null;const fa=ve({},["annotation-xml","audio","colgroup","desc","foreignobject","head","iframe","math","mi","mn","mo","ms","mtext","noembed","noframes","noscript","plaintext","script","style","svg","template","thead","title","video","xmp"]);let ic=null;const Ys=ve({},["audio","video","img","source","image","track"]);let ha=null;const pa=ve({},["alt","class","for","id","label","name","pattern","placeholder","role","summary","title","value","style","xmlns"]),Jr="http://www.w3.org/1998/Math/MathML",Nn="http://www.w3.org/2000/svg",pn="http://www.w3.org/1999/xhtml";let Yt=pn,ma=!1,ga=null;const ac=ve({},[Jr,Nn,pn],sh);let Zs=ve({},["mi","mo","mn","ms","mtext"]),Lo=ve({},["annotation-xml"]);const va=ve({},["title","style","font","a","script"]);let Mt=null;const lf=["application/xhtml+xml","text/html"],ue="text/html";let ie=null,Pe=null;const Zt=n.createElement("form"),Lt=function(C){return C instanceof RegExp||C instanceof Function},mn=function(){let C=arguments.length>0&&arguments[0]!==void 0?arguments[0]:{};if(!(Pe&&Pe===C)){if((!C||typeof C!="object")&&(C={}),C=or(C),Mt=lf.indexOf(C.PARSER_MEDIA_TYPE)===-1?ue:C.PARSER_MEDIA_TYPE,ie=Mt==="application/xhtml+xml"?sh:du,V=In(C,"ALLOWED_TAGS")?ve({},C.ALLOWED_TAGS,ie):X,ee=In(C,"ALLOWED_ATTR")?ve({},C.ALLOWED_ATTR,ie):ce,ga=In(C,"ALLOWED_NAMESPACES")?ve({},C.ALLOWED_NAMESPACES,sh):ac,ha=In(C,"ADD_URI_SAFE_ATTR")?ve(or(pa),C.ADD_URI_SAFE_ATTR,ie):pa,ic=In(C,"ADD_DATA_URI_TAGS")?ve(or(Ys),C.ADD_DATA_URI_TAGS,ie):Ys,dt=In(C,"FORBID_CONTENTS")?ve({},C.FORBID_CONTENTS,ie):fa,Oe=In(C,"FORBID_TAGS")?ve({},C.FORBID_TAGS,ie):or({}),W=In(C,"FORBID_ATTR")?ve({},C.FORBID_ATTR,ie):or({}),tt=In(C,"USE_PROFILES")?C.USE_PROFILES:!1,Me=C.ALLOW_ARIA_ATTR!==!1,_e=C.ALLOW_DATA_ATTR!==!1,we=C.ALLOW_UNKNOWN_PROTOCOLS||!1,Se=C.ALLOW_SELF_CLOSE_IN_ATTR!==!1,ze=C.SAFE_FOR_TEMPLATES||!1,ut=C.SAFE_FOR_XML!==!1,kt=C.WHOLE_DOCUMENT||!1,hn=C.RETURN_DOM||!1,Pn=C.RETURN_DOM_FRAGMENT||!1,Ks=C.RETURN_TRUSTED_TYPE||!1,Rn=C.FORCE_BODY||!1,Qr=C.SANITIZE_DOM!==!1,ua=C.SANITIZE_NAMED_PROPS||!1,da=C.KEEP_CONTENT!==!1,Gs=C.IN_PLACE||!1,z=C.ALLOWED_URI_REGEXP||jE,Yt=C.NAMESPACE||pn,Zs=C.MATHML_TEXT_INTEGRATION_POINTS||Zs,Lo=C.HTML_INTEGRATION_POINTS||Lo,le=C.CUSTOM_ELEMENT_HANDLING||{},C.CUSTOM_ELEMENT_HANDLING&&Lt(C.CUSTOM_ELEMENT_HANDLING.tagNameCheck)&&(le.tagNameCheck=C.CUSTOM_ELEMENT_HANDLING.tagNameCheck),C.CUSTOM_ELEMENT_HANDLING&&Lt(C.CUSTOM_ELEMENT_HANDLING.attributeNameCheck)&&(le.attributeNameCheck=C.CUSTOM_ELEMENT_HANDLING.attributeNameCheck),C.CUSTOM_ELEMENT_HANDLING&&typeof C.CUSTOM_ELEMENT_HANDLING.allowCustomizedBuiltInElements=="boolean"&&(le.allowCustomizedBuiltInElements=C.CUSTOM_ELEMENT_HANDLING.allowCustomizedBuiltInElements),ze&&(_e=!1),Pn&&(hn=!0),tt&&(V=ve({},Xw),ee=[],tt.html===!0&&(ve(V,Jw),ve(ee,e0)),tt.svg===!0&&(ve(V,ih),ve(ee,ch),ve(ee,Lc)),tt.svgFilters===!0&&(ve(V,ah),ve(ee,ch),ve(ee,Lc)),tt.mathMl===!0&&(ve(V,lh),ve(ee,t0),ve(ee,Lc))),C.ADD_TAGS&&(typeof C.ADD_TAGS=="function"?xe.tagCheck=C.ADD_TAGS:(V===X&&(V=or(V)),ve(V,C.ADD_TAGS,ie))),C.ADD_ATTR&&(typeof C.ADD_ATTR=="function"?xe.attributeCheck=C.ADD_ATTR:(ee===ce&&(ee=or(ee)),ve(ee,C.ADD_ATTR,ie))),C.ADD_URI_SAFE_ATTR&&ve(ha,C.ADD_URI_SAFE_ATTR,ie),C.FORBID_CONTENTS&&(dt===fa&&(
vendor: 3,925 bytes, line 240
240dt=or(dt)),ve(dt,C.FORBID_CONTENTS,ie)),C.ADD_FORBID_CONTENTS&&(dt===fa&&(dt=or(dt)),ve(dt,C.ADD_FORBID_CONTENTS,ie)),da&&(V["#text"]=!0),kt&&ve(V,["html","head","body"]),V.table&&(ve(V,["tbody"]),delete Oe.tbody),C.TRUSTED_TYPES_POLICY){if(typeof C.TRUSTED_TYPES_POLICY.createHTML!="function")throw ja('TRUSTED_TYPES_POLICY configuration option must provide a "createHTML" hook.');if(typeof C.TRUSTED_TYPES_POLICY.createScriptURL!="function")throw ja('TRUSTED_TYPES_POLICY configuration option must provide a "createScriptURL" hook.');_=C.TRUSTED_TYPES_POLICY,S=_.createHTML("")}else _===void 0&&(_=TL(h,s)),_!==null&&typeof S=="string"&&(S=_.createHTML(""));Ot&&Ot(C),Pe=C}},tr=ve({},[...ih,...ah,...gL]),$t=ve({},[...lh,...vL]),nr=function(C){let F=y(C);(!F||!F.tagName)&&(F={namespaceURI:Yt,tagName:"template"});const Q=du(C.tagName),Ue=du(F.tagName);return ga[C.namespaceURI]?C.namespaceURI===Nn?F.namespaceURI===pn?Q==="svg":F.namespaceURI===Jr?Q==="svg"&&(Ue==="annotation-xml"||Zs[Ue]):!!tr[Q]:C.namespaceURI===Jr?F.namespaceURI===pn?Q==="math":F.namespaceURI===Nn?Q==="math"&&Lo[Ue]:!!$t[Q]:C.namespaceURI===pn?F.namespaceURI===Nn&&!Lo[Ue]||F.namespaceURI===Jr&&!Zs[Ue]?!1:!$t[Q]&&(va[Q]||!tr[Q]):!!(Mt==="application/xhtml+xml"&&ga[C.namespaceURI]):!1},rr=function(C){Aa(t.removed,{element:C});try{y(C).removeChild(C)}catch{b(C)}},Qs=function(C,F){try{Aa(t.removed,{attribute:F.getAttributeNode(C),from:F})}catch{Aa(t.removed,{attribute:null,from:F})}if(F.removeAttribute(C),C==="is")if(hn||Pn)try{rr(F)}catch{}else try{F.setAttribute(C,"")}catch{}},kv=function(C){let F=null,Q=null;if(Rn)C="<remove></remove>"+C;else{const Je=oh(C,/^[\r\n\t ]+/);Q=Je&&Je[0]}Mt==="application/xhtml+xml"&&Yt===pn&&(C='<html xmlns="http://www.w3.org/1999/xhtml"><head></head><body>'+C+"</body></html>");const Ue=_?_.createHTML(C):C;if(Yt===pn)try{F=new p().parseFromString(Ue,Mt)}catch{}if(!F||!F.documentElement){F=k.createDocument(Yt,"template",null);try{F.documentElement.innerHTML=ma?S:Ue}catch{}}const yt=F.body||F.documentElement;return C&&Q&&yt.insertBefore(n.createTextNode(Q),yt.childNodes[0]||null),Yt===pn?P.call(F,kt?"html":"body")[0]:kt?F.documentElement:yt},Cv=function(C){return E.call(C.ownerDocument||C,C,c.SHOW_ELEMENT|c.SHOW_COMMENT|c.SHOW_TEXT|c.SHOW_PROCESSING_INSTRUCTION|c.SHOW_CDATA_SECTION,null)},cf=function(C){return C instanceof d&&(typeof C.nodeName!="string"||typeof C.textContent!="string"||typeof C.removeChild!="function"||!(C.attributes instanceof u)||typeof C.removeAttribute!="function"||typeof C.setAttribute!="function"||typeof C.namespaceURI!="string"||typeof C.insertBefore!="function"||typeof C.hasChildNodes!="function")},Tv=function(C){return typeof a=="function"&&C instanceof a};function Er(re,C,F){Mc(re,Q=>{Q.call(t,C,F,Pe)})}const Rv=function(C){let F=null;if(Er(D.beforeSanitizeElements,C,null),cf(C))return rr(C),!0;const Q=ie(C.nodeName);if(Er(D.uponSanitizeElement,C,{tagName:Q,allowedTags:V}),ut&&C.hasChildNodes()&&!Tv(C.firstElementChild)&&Ct(/<[/\w!]/g,C.innerHTML)&&Ct(/<[/\w!]/g,C.textContent)||C.nodeType===Da.progressingInstruction||ut&&C.nodeType===Da.comment&&Ct(/<[/\w]/g,C.data))return rr(C),!0;if(!(xe.tagCheck instanceof Function&&xe.tagCheck(Q))&&(!V[Q]||Oe[Q])){if(!Oe[Q]&&Nv(Q)&&(le.tagNameCheck instanceof RegExp&&Ct(le.tagNameCheck,Q)||le.tagNameCheck instanceof Function&&le.tagNameCheck(Q)))return!1;if(da&&!dt[Q]){const Ue=y(C)||C.parentNode,yt=g(C)||C.childNodes;if(yt&&Ue){const Je=yt.length;for(let Ft=Je-1;Ft>=0;--Ft){const kr=v(yt[Ft],!0);kr.__removalCount=(C.__removalCount||0)+1,Ue.insertBefore(kr,w(C))}}}return rr(C),!0}return C instanceof l&&!nr(C)||(Q==="noscript"||Q==="noembed"||Q==="noframes")&&Ct(/<\/no(script|embed|frames)/i,C.innerHTML)?(rr(C),!0):(ze&&C.nodeType===Da.text&&(F=C.textContent,Mc([M,H,L],Ue=>{F=Oa(F,Ue," ")}),C.textContent!==F&&(Aa(t.removed,{element:C.cloneNode()}),C.textContent=F)),Er(D.afterSanitizeElements,C,null),!1)}
vendor: 4,269 bytes, lines 240-241
240,Pv=function(C,F,Q){if(Qr&&(F==="id"||F==="name")&&(Q in n||Q in Zt))return!1;if(!(_e&&!W[F]&&Ct(Z,F))){if(!(Me&&Ct(B,F))){if(!(xe.attributeCheck instanceof Function&&xe.attributeCheck(F,C))){if(!ee[F]||W[F]){if(!(Nv(C)&&(le.tagNameCheck instanceof RegExp&&Ct(le.tagNameCheck,C)||le.tagNameCheck instanceof Function&&le.tagNameCheck(C))&&(le.attributeNameCheck instanceof RegExp&&Ct(le.attributeNameCheck,F)||le.attributeNameCheck instanceof Function&&le.attributeNameCheck(F,C))||F==="is"&&le.allowCustomizedBuiltInElements&&(le.tagNameCheck instanceof RegExp&&Ct(le.tagNameCheck,Q)||le.tagNameCheck instanceof Function&&le.tagNameCheck(Q))))return!1}else if(!ha[F]){if(!Ct(z,Oa(Q,T,""))){if(!((F==="src"||F==="xlink:href"||F==="href")&&C!=="script"&&fL(Q,"data:")===0&&ic[C])){if(!(we&&!Ct(I,Oa(Q,T,"")))){if(Q)return!1}}}}}}}return!0},Nv=function(C){return C!=="annotation-xml"&&oh(C,N)},Av=function(C){Er(D.beforeSanitizeAttributes,C,null);const{attributes:F}=C;if(!F||cf(C))return;const Q={attrName:"",attrValue:"",keepAttr:!0,allowedAttributes:ee,forceKeepAttr:void 0};let Ue=F.length;for(;Ue--;){const yt=F[Ue],{name:Je,namespaceURI:Ft,value:kr}=yt,$o=ie(Je),uf=kr;let ft=Je==="value"?uf:hL(uf);if(Q.attrName=$o,Q.attrValue=ft,Q.keepAttr=!0,Q.forceKeepAttr=void 0,Er(D.uponSanitizeAttribute,C,Q),ft=Q.attrValue,ua&&($o==="id"||$o==="name")&&(Qs(Je,C),ft=Sr+ft),ut&&Ct(/((--!?|])>)|<\/(style|title|textarea)/i,ft)){Qs(Je,C);continue}if($o==="attributename"&&oh(ft,"href")){Qs(Je,C);continue}if(Q.forceKeepAttr)continue;if(!Q.keepAttr){Qs(Je,C);continue}if(!Se&&Ct(/\/>/i,ft)){Qs(Je,C);continue}ze&&Mc([M,H,L],jv=>{ft=Oa(ft,jv," ")});const Ov=ie(C.nodeName);if(!Pv(Ov,$o,ft)){Qs(Je,C);continue}if(_&&typeof h=="object"&&typeof h.getAttributeType=="function"&&!Ft)switch(h.getAttributeType(Ov,$o)){case"TrustedHTML":{ft=_.createHTML(ft);break}case"TrustedScriptURL":{ft=_.createScriptURL(ft);break}}if(ft!==uf)try{Ft?C.setAttributeNS(Ft,Je,ft):C.setAttribute(Je,ft),cf(C)?rr(C):Qw(t.removed)}catch{Qs(Je,C)}}Er(D.afterSanitizeAttributes,C,null)},tT=function re(C){let F=null;const Q=Cv(C);for(Er(D.beforeSanitizeShadowDOM,C,null);F=Q.nextNode();)Er(D.uponSanitizeShadowNode,F,null),Rv(F),Av(F),F.content instanceof o&&re(F.content);Er(D.afterSanitizeShadowDOM,C,null)};return t.sanitize=function(re){let C=arguments.length>1&&arguments[1]!==void 0?arguments[1]:{},F=null,Q=null,Ue=null,yt=null;if(ma=!re,ma&&(re="<!-->"),typeof re!="string"&&!Tv(re))if(typeof re.toString=="function"){if(re=re.toString(),typeof re!="string")throw ja("dirty is not a string, aborting")}else throw ja("toString is not a function");if(!t.isSupported)return re;if(fn||mn(C),t.removed=[],typeof re=="string"&&(Gs=!1),Gs){if(re.nodeName){const kr=ie(re.nodeName);if(!V[kr]||Oe[kr])throw ja("root node is forbidden and cannot be sanitized in-place")}}else if(re instanceof a)F=kv("<!---->"),Q=F.ownerDocument.importNode(re,!0),Q.nodeType===Da.element&&Q.nodeName==="BODY"||Q.nodeName==="HTML"?F=Q:F.appendChild(Q);else{if(!hn&&!ze&&!kt&&re.indexOf("<")===-1)return _&&Ks?_.createHTML(re):re;if(F=kv(re),!F)return hn?null:Ks?S:""}F&&Rn&&rr(F.firstChild);const Je=Cv(Gs?re:F);for(;Ue=Je.nextNode();)Rv(Ue),Av(Ue),Ue.content instanceof o&&tT(Ue.content);if(Gs)return re;if(hn){if(Pn)for(yt=R.call(F.ownerDocument);F.firstChild;)yt.appendChild(F.firstChild);else yt=F;return(ee.shadowroot||ee.shadowrootmode)&&(yt=A.call(r,yt,!0)),yt}let Ft=kt?F.outerHTML:F.innerHTML;return kt&&V["!doctype"]&&F.ownerDocument&&F.ownerDocument.doctype&&F.ownerDocument.doctype.name&&Ct(IE,F.ownerDocument.doctype.name)&&(Ft="<!DOCTYPE "+F.ownerDocument.doctype.name+`> 241`+Ft),ze&&Mc([M,H,L],kr=>{Ft=Oa(Ft,kr," ")}),_&&Ks?_.createHTML(Ft):Ft},t.setConfig=function(){let re=arguments.length>0&&arguments[0]!==void 0?arguments[0]:{};mn(re),fn=!0},t.clearConfig=function(){Pe=null,fn=!1},t.isValidAttribute=function(re,C,F){Pe||mn({});const Q=ie(re),Ue=ie(C);return Pv(Q,Ue,F)},t.addHook=function(re,C){typeof C=="function"&&Aa(D[re],C)},t.removeHook=function(re,C){if(C!==void 0){const F=uL(D[re],C);return F===-1?void 0:dL(D[re],F,1)[0]}return Qw(D[re])},t.removeHooks=function(re){D[re]=[]},t.removeAllHooks=function(){D=r0()},t}var RL=DE(),Zd="Collapsible",[PL,ME]=Gt(Zd),[NL,tv]=PL(Zd),LE=m.forwardRef((e,t)=>
vendor: 4,099 bytes, line 241
241{const{__scopeCollapsible:n,open:r,defaultOpen:s,disabled:o,onOpenChange:i,...a}=e,[l,c]=Gn({prop:r,defaultProp:s??!1,onChange:i,caller:Zd});return f.jsx(NL,{scope:n,disabled:o,contentId:Ur(),open:l,onOpenToggle:m.useCallback(()=>c(u=>!u),[c]),children:f.jsx(ne.div,{"data-state":rv(l),"data-disabled":o?"":void 0,...a,ref:t})})});LE.displayName=Zd;var $E="CollapsibleTrigger",FE=m.forwardRef((e,t)=>{const{__scopeCollapsible:n,...r}=e,s=tv($E,n);return f.jsx(ne.button,{type:"button","aria-controls":s.contentId,"aria-expanded":s.open||!1,"data-state":rv(s.open),"data-disabled":s.disabled?"":void 0,disabled:s.disabled,...r,ref:t,onClick:K(e.onClick,s.onOpenToggle)})});FE.displayName=$E;var nv="CollapsibleContent",UE=m.forwardRef((e,t)=>{const{forceMount:n,...r}=e,s=tv(nv,e.__scopeCollapsible);return f.jsx(dn,{present:n||s.open,children:({present:o})=>f.jsx(AL,{...r,ref:t,present:o})})});UE.displayName=nv;var AL=m.forwardRef((e,t)=>{const{__scopeCollapsible:n,present:r,children:s,...o}=e,i=tv(nv,n),[a,l]=m.useState(r),c=m.useRef(null),u=de(t,c),d=m.useRef(0),p=d.current,h=m.useRef(0),x=h.current,v=i.open||a,b=m.useRef(v),w=m.useRef(void 0);return m.useEffect(()=>{const g=requestAnimationFrame(()=>b.current=!1);return()=>cancelAnimationFrame(g)},[]),it(()=>{const g=c.current;if(g){w.current=w.current||{transitionDuration:g.style.transitionDuration,animationName:g.style.animationName},g.style.transitionDuration="0s",g.style.animationName="none";const y=g.getBoundingClientRect();d.current=y.height,h.current=y.width,b.current||(g.style.transitionDuration=w.current.transitionDuration,g.style.animationName=w.current.animationName),l(r)}},[i.open,r]),f.jsx(ne.div,{"data-state":rv(i.open),"data-disabled":i.disabled?"":void 0,id:i.contentId,hidden:!v,...o,ref:u,style:{"--radix-collapsible-content-height":p?`${p}px`:void 0,"--radix-collapsible-content-width":x?`${x}px`:void 0,...e.style},children:v&&s})});function rv(e){return e?"open":"closed"}var OL=LE,jL=FE,IL=UE,er="Accordion",DL=["Home","End","ArrowDown","ArrowUp","ArrowLeft","ArrowRight"],[sv,ML,LL]=Zl(er),[Qd,Iz]=Gt(er,[LL,ME]),ov=ME(),BE=O.forwardRef((e,t)=>{const{type:n,...r}=e,s=r,o=r;return f.jsx(sv.Provider,{scope:e.__scopeAccordion,children:n==="multiple"?f.jsx(BL,{...o,ref:t}):f.jsx(UL,{...s,ref:t})})});BE.displayName=er;var[zE,$L]=Qd(er),[WE,FL]=Qd(er,{collapsible:!1}),UL=O.forwardRef((e,t)=>{const{value:n,defaultValue:r,onValueChange:s=()=>{},collapsible:o=!1,...i}=e,[a,l]=Gn({prop:n,defaultProp:r??"",onChange:s,caller:er});return f.jsx(zE,{scope:e.__scopeAccordion,value:O.useMemo(()=>a?[a]:[],[a]),onItemOpen:l,onItemClose:O.useCallback(()=>o&&l(""),[o,l]),children:f.jsx(WE,{scope:e.__scopeAccordion,collapsible:o,children:f.jsx(HE,{...i,ref:t})})})}),BL=O.forwardRef((e,t)=>{const{value:n,defaultValue:r,onValueChange:s=()=>{},...o}=e,[i,a]=Gn({prop:n,defaultProp:r??[],onChange:s,caller:er}),l=O.useCallback(u=>a((d=[])=>[...d,u]),[a]),c=O.useCallback(u=>a((d=[])=>d.filter(p=>p!==u)),[a]);return f.jsx(zE,{scope:e.__scopeAccordion,value:i,onItemOpen:l,onItemClose:c,children:f.jsx(WE,{scope:e.__scopeAccordion,collapsible:!0,children:f.jsx(HE,{...o,ref:t})})})}),[zL,Jd]=Qd(er),HE=O.forwardRef((e,t)=>{const{__scopeAccordion:n,disabled:r,dir:s,orientation:o="vertical",...i}=e,a=O.useRef(null),l=de(a,t),c=ML(n),d=oa(s)==="ltr",p=K(e.onKeyDown,h=>{var R;if(!DL.includes(h.key))return;const x=h.target,v=c().filter(P=>{var A;return!((A=P.ref.current)!=null&&A.disabled)}),b=v.findIndex(P=>P.ref.current===x),w=v.length;if(b===-1)return;h.preventDefault();let g=b;const y=0,_=w-1,S=()=>{g=b+1,g>_&&(g=y)},k=()=>{g=b-1,g<y&&(g=_)};switch(h.key){case"Home":g=y;break;case"End":g=_;break;case"ArrowRight":o==="horizontal"&&(d?S():k());break;case"ArrowDown":o==="vertical"&&S();break;case"ArrowLeft":o==="horizontal"&&(d?k():S());break;case"ArrowUp":o==="vertical"&&k();break}const E=g%w;(R=v[E].ref.current)==null||R.focus()});return f.jsx(zL,{scope:n,disabled:r,direction:s,orientation:o,children:f.jsx(sv.Slot,{scope:n,children:f.jsx(ne.div,{...i,"data-orientation":o,ref:l,onKeyDown:r?void 0:p})})})}
241),Zu="AccordionItem",[WL,iv]=Qd(Zu),VE=O.forwardRef((e,t)=>{const{__scopeAccordion:n,value:r,...s}=e,o=Jd(Zu,n),i=$L(Zu,n),a=ov(n),l=Ur(),c=r&&i.value.includes(r)||!1,u=o.disabled||e.disabled;return f.jsx(WL,{scope:n,open:c,disabled:u,triggerId:l,children:f.jsx(OL,{"data-orientation":o.orientation,"data-state":QE(c),...a,...s,ref:t,disabled:u,open:c,onOpenChange:d=>{d?i.onItemOpen(r):i.onItemClose(r)}})})});VE.displayName=Zu;var qE="AccordionHeader",KE=O.forwardRef((e,t)=>{const{__scopeAccordion:n,...r}=e,s=Jd(er,n),o=iv(qE,n);return f.jsx(ne.h3,{"data-orientation":s.orientation,"data-state":QE(o.open),"data-disabled":o.disabled?"":void 0,...r,ref:t})});KE.displayName=qE;var Jp="AccordionTrigger",GE=O.forwardRef((e,t)=>{const{__scopeAccordion:n,...r}=e,s=Jd(er,n),o=iv(Jp,n),i=FL(Jp,n),a=ov(n);return f.jsx(sv.ItemSlot,{scope:n,children:f.jsx(jL,{"aria-disabled":o.open&&!i.collapsible||void 0,"data-orientation":s.orientation,id:o.triggerId,...a,...r,ref:t})})});GE.displayName=Jp;var YE="AccordionContent",ZE=O.forwardRef((e,t)=>{const{__scopeAccordion:n,...r}=e,s=Jd(er,n),o=iv(YE,n),i=ov(n);return f.jsx(IL,{role:"region","aria-labelledby":o.triggerId,"data-orientation":s.orientation,...i,...r,ref:t,style:{"--radix-accordion-content-height":"var(--radix-collapsible-content-height)","--radix-accordion-content-width":"var(--radix-collapsible-content-width)",...e.style}})});ZE.displayName=YE;function QE(e){return e?"open":"closed"}var HL=BE,VL=VE,qL=KE,JE=GE,XE=ZE;const KL=HL,ek=m.forwardRef(({className:e,...t},n)=>f.jsx(VL,{ref:n,className:me("border-b",e),...t}));ek.displayName="AccordionItem";const tk=m.forwardRef(({className:e,children:t,...n},r)=>f.jsx(qL,{className:"flex",children:f.jsxs(JE,{ref:r,className:me("flex flex-1 items-center justify-between py-4 font-medium transition-all hover:underline [&[data-state=open]>svg]:rotate-180",e),...n,children:[t,f.jsx(Pd,{className:"h-4 w-4 shrink-0 transition-transform duration-200"})]})}));tk.displayName=JE.displayName;const nk=m.forwardRef(({className:e,children:t,...n},r)=>f.jsx(XE,{ref:r,className:"overflow-hidden text-sm transition-all data-[state=closed]:animate-accordion-up data-[state=open]:animate-accordion-down",...n,children:f.jsx("div",{className:me("pb-4 pt-0",e),children:t})}));nk.displayName=XE.displayName;const uh=7,GL=()=>{const e=Ms(),[t,n]=m.useState([]),[r,s]=m.useState(1),[o,i]=m.useState(!0),[a,l]=m.useState(null);m.useEffect(()=>{let d=!1;const p=async()=>{i(!0),l(null);try{const x=await ev("faqs?select=id,question,answer,display_order&is_published=eq.true&order=display_order.asc");d||(n(x),s(1))}catch(x){const v=x instanceof Error?x.message:"unknown error";console.error("[FaqSection] Fetch error:",v),d||l(v)}finally{d||i(!1)}};p();const h=window.setTimeout(()=>{!d&&t.length===0&&p()},3e3);return()=>{d=!0,window.clearTimeout(h)}},[]);const c=Math.ceil(t.length/uh),u=t.slice((r-1)*uh,r*uh);return f.jsx("section",{id:"faq",className:"py-20 md:py-28 bg-secondary",children:f.jsxs("div",{ref:e.ref,style:e.style,className:"container mx-auto px-4",children:[f.jsx("div",{className:"text-center mb-14",children:f.jsx("h2",{className:"text-3xl md:text-4xl font-bold text-white mb-4",children:"ì주 묻ë ì§ë¬¸"})}),f.jsx("div",{className:"max-w-3xl mx-auto",children:o?f.jsx("div",{className:"text-center text-muted-foreground py-12",children:"FAQ를 ë¶ë¬ì¤ë ì¤ì
ëë¤..."}):a?f.jsx("div",{className:"text-center text-muted-foreground py-12",children:"FAQ를 ë¶ë¬ì¤ì§ 못íìµëë¤."}):t.length===0?f.jsx("div",{className:"text-center text-muted-foreground py-12",children:"ë±ë¡ë FAQê° ììµëë¤."}):f.jsxs(f.Fragment,{children:[f.jsx(KL,{type:"single",collapsible:!0,className:"space-y-3",children:u.map(d=>f.jsxs(ek,{value:d.id,className:"border border-border/50 rounded-lg bg-card px-6 data-[state=open]:bg-card",children:[f.jsx(tk,{className:"text-left text-foreground font-normal hover:no-underline py-5 pl-[1.5em]",style:{textIndent:"-1.5em"},children:d.question}),f.jsx(nk,{className:"text-muted-foreground leading-relaxed pb-5 prose prose-invert prose-sm max-w-none",children:f.jsx("div",{dangerouslySetInnerHTML:{__html:RL.sanitize(d.answer)}})})]},d.id))}),c>1&&f.jsx("div",{className:"flex justify-center items-center gap-2 mt-8",children:Array.from({length:c},(d,p)=>p+1).map(d=>f.jsx("button",{onClick:()=>s(d),className:`w-9 h-9 rounded-full text-sm font-medium transition-colors ${d===r?"bg-primary text-primary-foreground":"text-muted-foreground hover:bg-muted/50"}`,children:d},d))})]})})]})})};function ke(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 an(e,t){return e instanceof Date?new e.constructor(t):new Date(t)}function Pt(e,t){const n=ke(e);return isNaN(t)?an(e,NaN):(t&&n.setDate(n.getDate()+t),n)}function Qn(e,t){const n=ke(e);if(isNaN(t))return an(e,NaN);if(!t)return n;const r=n.getDate(),s=an(e,n.getTime());s.setMonth(n.getMonth()+t+1,0);const o=s.getDate();return r>=o?s:(n.setFullYear(s.getFullYear(),s.getMonth(),r),n)}const av=6048e5,YL=864e5;let ZL={};function ec(){return ZL}function br(e,t){var a,l,c,u;const n=ec(),r=(t==null?void 0:t.weekStartsOn)??((l=(a=t==null?void 0:t.locale)==null?void 0:a.options)==null?void 0:l.weekStartsOn)??n.weekStartsOn??((u=(c=n.locale)==null?void 0:c.options)==null?void 0:u.weekStartsOn)??0,s=ke(e),o=s.getDay(),i=(o<r?7:0)+o-r;return s.setDate(s.getDate()-i),s.setHours(0,0,0,0),s}function Ro(e){return br(e,{weekStartsOn:1}
241)}function rk(e){const t=ke(e),n=t.getFullYear(),r=an(e,0);r.setFullYear(n+1,0,4),r.setHours(0,0,0,0);const s=Ro(r),o=an(e,0);o.setFullYear(n,0,4),o.setHours(0,0,0,0);const i=Ro(o);return t.getTime()>=s.getTime()?n+1:t.getTime()>=i.getTime()?n:n-1}function qi(e){const t=ke(e);return t.setHours(0,0,0,0),t}function Qu(e){const t=ke(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 pr(e,t){const n=qi(e),r=qi(t),s=+n-Qu(n),o=+r-Qu(r);return Math.round((s-o)/YL)}function QL(e){const t=rk(e),n=an(e,0);return n.setFullYear(t,0,4),n.setHours(0,0,0,0),Ro(n)}function Xp(e,t){const n=t*7;return Pt(e,n)}function JL(e,t){return Qn(e,t*12)}function XL(e){let t;return e.forEach(function(n){const r=ke(n);(t===void 0||t<r||isNaN(Number(r)))&&(t=r)}),t||new Date(NaN)}function e$(e){let t;return e.forEach(n=>{const r=ke(n);(!t||t>r||isNaN(+r))&&(t=r)}),t||new Date(NaN)}function Wt(e,t){const n=qi(e),r=qi(t);return+n==+r}function lv(e){return e instanceof Date||typeof e=="object"&&Object.prototype.toString.call(e)==="[object Date]"}function t$(e){if(!lv(e)&&typeof e!="number")return!1;const t=ke(e);return!isNaN(Number(t))}function Al(e,t){const n=ke(e),r=ke(t),s=n.getFullYear()-r.getFullYear(),o=n.getMonth()-r.getMonth();return s*12+o}function n$(e,t,n){const r=br(e,n),s=br(t,n),o=+r-Qu(r),i=+s-Qu(s);return Math.round((o-i)/av)}function cv(e){const t=ke(e),n=t.getMonth();return t.setFullYear(t.getFullYear(),n+1,0),t.setHours(23,59,59,999),t}function Kt(e){const t=ke(e);return t.setDate(1),t.setHours(0,0,0,0),t}function sk(e){const t=ke(e),n=an(e,0);return n.setFullYear(t.getFullYear(),0,1),n.setHours(0,0,0,0),n}function uv(e,t){var a,l,c,u;const n=ec(),r=(t==null?void 0:t.weekStartsOn)??((l=(a=t==null?void 0:t.locale)==null?void 0:a.options)==null?void 0:l.weekStartsOn)??n.weekStartsOn??((u=(c=n.locale)==null?void 0:c.options)==null?void 0:u.weekStartsOn)??0,s=ke(e),o=s.getDay(),i=(o<r?-7:0)+6-(o-r);return s.setDate(s.getDate()+i),s.setHours(23,59,59,999),s}function ok(e){return uv(e,{weekStartsOn:1})}const r$={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"}},s$=(e,t,n)=>{let r;const s=r$[e];return typeof s=="string"?r=s:t===1?r=s.one:r=s.other.replace("{{count}}",t.toString()),n!=null&&n.addSuffix?n.comparison&&n.comparison>0?"in "+r:r+" ago":r};function dh(e){return(t={})=>{const n=t.width?String(t.width):e.defaultWidth;return e.formats[n]||e.formats[e.defaultWidth]}}const o$={full:"EEEE, MMMM do, y",long:"MMMM do, y",medium:"MMM d, y",short:"MM/dd/yyyy"},i$={full:"h:mm:ss a zzzz",long:"h:mm:ss a z",medium:"h:mm:ss a",short:"h:mm a"},a$={full:"{{date}} 'at' {{time}}",long:"{{date}} 'at' {{time}}",medium:"{{date}}, {{time}}",short:"{{date}}, {{time}}"},l$={date:dh({formats:o$,defaultWidth:"full"}),time:dh({formats:i$,defaultWidth:"full"}),dateTime:dh({formats:a$,defaultWidth:"full"})},c$={lastWeek:"'last' eeee 'at' p",yesterday:"'yesterday at' p",today:"'today at' p",tomorrow:"'tomorrow at' p",nextWeek:"eeee 'at' p",other:"P"},u$=(e,t,n,r)=>c$[e];function Ma(e){return(t,n)=>{const r=n!=null&&n.context?String(n.context):"standalone";let s;if(r==="formatting"&&e.formattingValues){const i=e.defaultFormattingWidth||e.defaultWidth,a=n!=null&&n.width?String(n.width):i;s=e.formattingValues[a]||e.formattingValues[i]}else{const i=e.defaultWidth,a=n!=null&&n.width?String(n.width):e.defaultWidth;s=e.values[a]||e.values[i]}const o=e.argumentCallback?e.argumentCallback(t):t;return s[o]}}const d$={narrow:["B","A"],abbreviated:["BC","AD"],wide:["Before Christ","Anno Domini"]}
vendor: 11,376 bytes, line 241
241,f$={narrow:["1","2","3","4"],abbreviated:["Q1","Q2","Q3","Q4"],wide:["1st quarter","2nd quarter","3rd quarter","4th quarter"]},h$={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"]},p$={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"]},m$={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"}},g$={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"}},v$=(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"},y$={ordinalNumber:v$,era:Ma({values:d$,defaultWidth:"wide"}),quarter:Ma({values:f$,defaultWidth:"wide",argumentCallback:e=>e-1}),month:Ma({values:h$,defaultWidth:"wide"}),day:Ma({values:p$,defaultWidth:"wide"}),dayPeriod:Ma({values:m$,defaultWidth:"wide",formattingValues:g$,defaultFormattingWidth:"wide"})};function La(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 i=o[0],a=r&&e.parsePatterns[r]||e.parsePatterns[e.defaultParseWidth],l=Array.isArray(a)?b$(a,d=>d.test(i)):w$(a,d=>d.test(i));let c;c=e.valueCallback?e.valueCallback(l):l,c=n.valueCallback?n.valueCallback(c):c;const u=t.slice(i.length);return{value:c,rest:u}}}function w$(e,t){for(const n in e)if(Object.prototype.hasOwnProperty.call(e,n)&&t(e[n]))return n}function b$(e,t){for(let n=0;n<e.length;n++)if(t(e[n]))return n}function x$(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 i=e.valueCallback?e.valueCallback(o[0]):o[0];i=n.valueCallback?n.valueCallback(i):i;const a=t.slice(s.length);return{value:i,rest:a}}}const _$=/^(\d+)(th|st|nd|rd)?/i,S$=/\d+/i,E$={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},k$={any:[/^b/i,/^(a|c)/i]},C$={narrow:/^[1234]/i,abbreviated:/^q[1234]/i,wide:/^[1234](th|st|nd|rd)? quarter/i},T$={any:[/1/i,/2/i,/3/i,/4/i]},R$={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},P$={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]},N$={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},A$={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]},O$={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},j$={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}},I$={ordinalNumber:x$({matchPattern:_$,parsePattern:S$,valueCallback:e=>parseInt(e,10)}),era:La({matchPatterns:E$,defaultMatchWidth:"wide",parsePatterns:k$,defaultParseWidth:"any"}),quarter:La({matchPatterns:C$,defaultMatchWidth:"wide",parsePatterns:T$,defaultParseWidth:"any",valueCallback:e=>e+1}),month:La({matchPatterns:R$,defaultMatchWidth:"wide",parsePatterns:P$,defaultParseWidth:"any"}),day:La({matchPatterns:N$,defaultMatchWidth:"wide",parsePatterns:A$,defaultParseWidth:"any"}),dayPeriod:La({matchPatterns:O$,defaultMatchWidth:"any",parsePatterns:j$,defaultParseWidth:"any"})},ik={code:"en-US",formatDistance:s$,formatLong:l$,formatRelative:u$,localize:y$,match:I$,options:{weekStartsOn:0,firstWeekContainsDate:1}};function D$(e){const t=ke(e);return pr(t,sk(t))+1}function ak(e){const t=ke(e),n=+Ro(t)-+QL(t);return Math.round(n/av)+1}function lk(e,t){var u,d,p,h;const n=ke(e),r=n.getFullYear(),s=ec(),o=(t==null?void 0:t.firstWeekContainsDate)??((d=(u=t==null?void 0:t.locale)==null?void 0:u.options)==null?void 0:d.firstWeekContainsDate)??s.firstWeekContainsDate??((h=(p=s.locale)==null?void 0:p.options)==null?void 0:h.firstWeekContainsDate)??1,i=an(e,0);i.setFullYear(r+1,0,o),i.setHours(0,0,0,0);const a=br(i,t),l=an(e,0);l.setFullYear(r,0,o),l.setHours(0,0,0,0);const c=br(l,t);return n.getTime()>=a.getTime()?r+1:n.getTime()>=c.getTime()?r:r-1}function M$(e,t){var a,l,c,u;const n=ec(),r=(t==null?void 0:t.firstWeekContainsDate)??((l=(a=t==null?void 0:t.locale)==null?void 0:a.options)==null?void 0:l.firstWeekContainsDate)??n.firstWeekContainsDate??((u=(c=n.locale)==null?void 0:c.options)==null?void 0:u.firstWeekContainsDate)??1,s=lk(e,t),o=an(e,0);return o.setFullYear(s,0,r),o.setHours(0,0,0,0),br(o,t)}function ck(e,t){const n=ke(e),r=+br(n,t)-+M$(n,t);return Math.round(r/av)+1}function Ne(e,t){const n=e<0?"-":"",r=Math.abs(e).toString().padStart(t,"0");return n+r}const ns={y(e,t){const n=e.getFullYear(),r=n>0?n:1-n;return Ne(t==="yy"?r%100:r,t.length)},M(e,t){const n=e.getMonth();return t==="M"?String(n+1):Ne(n+1,2)},d(e,t){return Ne(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 Ne(e.getHours()%12||12,t.length)},H(e,t){return Ne(e.getHours(),t.length)},m(e,t){return Ne(e.getMinutes(),t.length)},s(e,t){return Ne(e.getSeconds(),t.length)},S(e,t){const n=t.length,r=e.getMilliseconds(),s=Math.trunc(r*Math.pow(10,n-3));return Ne(s,t.length)}},Ho={am:"am",pm:"pm",midnight:"midnight",noon:"noon",morning:"morning",afternoon:"afternoon",evening:"evening",night:"night"},s0={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 ns.y(e,t)},Y:function(e,t,n,r){const s=lk(e,r),o=s>0?s:1-s;if(t==="YY"){const i=o%100;return Ne(i,2)}return t==="Yo"?n.ordinalNumber(o,{unit:"year"}):Ne(o,t.length)},R:function(e,t){const n=rk(e);return Ne(n,t.length)},u:function(e,t){const n=e.getFullYear();return Ne(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 Ne(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 Ne(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 ns.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 Ne(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=ck(e,r);return t==="wo"?n.ordinalNumber(s,{unit:"week"}):Ne(s,t.length)},I:function(e,t,n){const r=ak(e);return t==="Io"?n.ordinalNumber(r,{unit:"week"}):Ne(r,t.length)},d:function(e,t,n){return t==="do"?n.ordinalNumber(e.getDate(),{unit:"date"}):ns.d(e,t)},D:function(e,t,n){const r=D$(e);return t==="Do"?n.ordinalNumber(r,{unit:"dayOfYear"}):Ne(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 Ne(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 Ne(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 Ne(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=Ho.noon:r===0?s=Ho.midnight:s=r/12>
vendor: 4,693 bytes, line 241
241=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=Ho.evening:r>=12?s=Ho.afternoon:r>=4?s=Ho.morning:s=Ho.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 ns.h(e,t)},H:function(e,t,n){return t==="Ho"?n.ordinalNumber(e.getHours(),{unit:"hour"}):ns.H(e,t)},K:function(e,t,n){const r=e.getHours()%12;return t==="Ko"?n.ordinalNumber(r,{unit:"hour"}):Ne(r,t.length)},k:function(e,t,n){let r=e.getHours();return r===0&&(r=24),t==="ko"?n.ordinalNumber(r,{unit:"hour"}):Ne(r,t.length)},m:function(e,t,n){return t==="mo"?n.ordinalNumber(e.getMinutes(),{unit:"minute"}):ns.m(e,t)},s:function(e,t,n){return t==="so"?n.ordinalNumber(e.getSeconds(),{unit:"second"}):ns.s(e,t)},S:function(e,t){return ns.S(e,t)},X:function(e,t,n){const r=e.getTimezoneOffset();if(r===0)return"Z";switch(t){case"X":return i0(r);case"XXXX":case"XX":return ro(r);case"XXXXX":case"XXX":default:return ro(r,":")}},x:function(e,t,n){const r=e.getTimezoneOffset();switch(t){case"x":return i0(r);case"xxxx":case"xx":return ro(r);case"xxxxx":case"xxx":default:return ro(r,":")}},O:function(e,t,n){const r=e.getTimezoneOffset();switch(t){case"O":case"OO":case"OOO":return"GMT"+o0(r,":");case"OOOO":default:return"GMT"+ro(r,":")}},z:function(e,t,n){const r=e.getTimezoneOffset();switch(t){case"z":case"zz":case"zzz":return"GMT"+o0(r,":");case"zzzz":default:return"GMT"+ro(r,":")}},t:function(e,t,n){const r=Math.trunc(e.getTime()/1e3);return Ne(r,t.length)},T:function(e,t,n){const r=e.getTime();return Ne(r,t.length)}};function o0(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+Ne(o,2)}function i0(e,t){return e%60===0?(e>0?"-":"+")+Ne(Math.abs(e)/60,2):ro(e,t)}function ro(e,t=""){const n=e>0?"-":"+",r=Math.abs(e),s=Ne(Math.trunc(r/60),2),o=Ne(r%60,2);return n+s+t+o}const a0=(e,t)=>{switch(e){case"P":return t.date({width:"short"});case"PP":return t.date({width:"medium"});case"PPP":return t.date({width:"long"});case"PPPP":default:return t.date({width:"full"})}},uk=(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"})}},L$=(e,t)=>{const n=e.match(/(P+)(p+)?/)||[],r=n[1],s=n[2];if(!s)return a0(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}}",a0(r,t)).replace("{{time}}",uk(s,t))},$$={p:uk,P:L$},F$=/^D+$/,U$=/^Y+$/,B$=["D","DD","YY","YYYY"];function z$(e){return F$.test(e)}function W$(e){return U$.test(e)}function H$(e,t,n){const r=V$(e,t,n);if(console.warn(r),B$.includes(e))throw new RangeError(r)}function V$(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 q$=/[yYQqMLwIdDecihHKkms]o|(\w)\1*|''|'(''|[^'])+('|$)|./g,K$=/P+p+|P+|p+|''|'(''|[^'])+('|$)|./g,G$=/^'([^]*?)'?$/,Y$=/''/g,Z$=/[a-zA-Z]/;function Mo(e,t,n){var u,d,p,h,x,v,b,w;const r=ec(),s=(n==null?void 0:n.locale)??r.locale??ik,o=(n==null?void 0:n.firstWeekContainsDate)??((d=(u=n==null?void 0:n.locale)==null?void 0:u.options)==null?void 0:d.firstWeekContainsDate)??r.firstWeekContainsDate??((h=(p=r.locale)==null?void 0:p.options)==null?void 0:h.firstWeekContainsDate)??1,i=(n==null?void 0:n.weekStartsOn)??((v=(x=n==null?void 0:n.locale)==null?void 0:x.options)==null?void 0:v.weekStartsOn)??r.weekStartsOn??((w=(b=r.locale)==null?void 0:b.options)==null?void 0:w.weekStartsOn)??0,a=ke(e);if(!t$(a))throw new RangeError("Invalid time value");let l=t.match(K$).map(g=>{const y=g[0];if(y==="p"||y==="P"){const _=$$[y];return _(g,s.formatLong)}return g}).join("").match(q$).map(g=>{if(g==="''")return{isToken:!1,value:"'"};const y=g[0];if(y==="'")return{isToken:!1,value:Q$(g)};if(s0[y])return{isToken:!0,value:g};
241if(y.match(Z$))throw new RangeError("Format string contains an unescaped latin alphabet character `"+y+"`");return{isToken:!1,value:g}});s.localize.preprocessor&&(l=s.localize.preprocessor(a,l));const c={firstWeekContainsDate:o,weekStartsOn:i,locale:s};return l.map(g=>{if(!g.isToken)return g.value;const y=g.value;(!(n!=null&&n.useAdditionalWeekYearTokens)&&W$(y)||!(n!=null&&n.useAdditionalDayOfYearTokens)&&z$(y))&&H$(y,t,String(e));const _=s0[y[0]];return _(a,y,s.localize,c)}).join("")}function Q$(e){const t=e.match(G$);return t?t[1].replace(Y$,"'"):e}function J$(e){const t=ke(e),n=t.getFullYear(),r=t.getMonth(),s=an(e,0);return s.setFullYear(n,r+1,0),s.setHours(0,0,0,0),s.getDate()}function X$(e){return Math.trunc(+ke(e)/1e3)}function e4(e){const t=ke(e),n=t.getMonth();return t.setFullYear(t.getFullYear(),n+1,0),t.setHours(0,0,0,0),t}function t4(e,t){return n$(e4(e),Kt(e),t)+1}function em(e,t){const n=ke(e),r=ke(t);return n.getTime()>r.getTime()}function dk(e,t){const n=ke(e),r=ke(t);return+n<+r}function dv(e,t){const n=ke(e),r=ke(t);return n.getFullYear()===r.getFullYear()&&n.getMonth()===r.getMonth()}function n4(e,t){const n=ke(e),r=ke(t);return n.getFullYear()===r.getFullYear()}function fh(e,t){return Pt(e,-t)}function hh(e,t){const n=ke(e),r=n.getFullYear(),s=n.getDate(),o=an(e,0);o.setFullYear(r,t,15),o.setHours(0,0,0,0);const i=J$(o);return n.setMonth(t,Math.min(s,i)),n}function l0(e,t){const n=ke(e);return isNaN(+n)?an(e,NaN):(n.setFullYear(t),n)}var ae=function(){return ae=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},ae.apply(this,arguments)};function r4(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 fk(e,t,n){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))}function tc(e){return e.mode==="multiple"}function nc(e){return e.mode==="range"}function Xd(e){return e.mode==="single"}var s4={root:"rdp",multiple_months:"rdp-multiple_months",with_weeknumber:"rdp-with_weeknumber",vhidden:"rdp-vhidden",button_reset:"rdp-button_reset",button:"rdp-button",caption:"rdp-caption",caption_start:"rdp-caption_start",caption_end:"rdp-caption_end",caption_between:"rdp-caption_between",caption_label:"rdp-caption_label",caption_dropdowns:"rdp-caption_dropdowns",dropdown:"rdp-dropdown",dropdown_month:"rdp-dropdown_month",dropdown_year:"rdp-dropdown_year",dropdown_icon:"rdp-dropdown_icon",months:"rdp-months",month:"rdp-month",table:"rdp-table",tbody:"rdp-tbody",tfoot:"rdp-tfoot",head:"rdp-head",head_row:"rdp-head_row",head_cell:"rdp-head_cell",nav:"rdp-nav",nav_button:"rdp-nav_button",nav_button_previous:"rdp-nav_button_previous",nav_button_next:"rdp-nav_button_next",nav_icon:"rdp-nav_icon",row:"rdp-row",weeknumber:"rdp-weeknumber",cell:"rdp-cell",day:"rdp-day",day_today:"rdp-day_today",day_outside:"rdp-day_outside",day_selected:"rdp-day_selected",day_disabled:"rdp-day_disabled",day_hidden:"rdp-day_hidden",day_range_start:"rdp-day_range_start",day_range_end:"rdp-day_range_end",day_range_middle:"rdp-day_range_middle"};function o4(e,t){return Mo(e,"LLLL y",t)}function i4(e,t){return Mo(e,"d",t)}function a4(e,t){return Mo(e,"LLLL",t)}function l4(e){return"".concat(e)}function c4(e,t){return Mo(e,"cccccc",t)}function u4(e,t){return Mo(e,"yyyy",t)}var d4=Object.freeze({__proto__:null,formatCaption:o4,formatDay:i4,formatMonthCaption:a4,formatWeekNumber:l4,formatWeekdayName:c4,formatYearCaption:u4}),f4=function(e,t,n){return Mo(e,"do MMMM (EEEE)",n)},h4=function(){return"Month: "},p4=function(){return"Go to next month"},m4=function(){return"Go to previous month"},g4=function(e,t){return Mo(e,"cccc",t)},v4=function(e){return"Week n. ".concat(e)},y4=function(){return"Year: "},w4=Object.freeze({__proto__:null,labelDay:f4,labelMonthDropdown:h4,labelNext:p4,labelPrevious:m4,labelWeekNumber:v4,labelWeekday:g4,labelYearDropdown:y4});function b4(){var e="buttons",t=s4,n=ik,r={},s={},o=1,i={},a=new Date;return{captionLayout:e,classNames:t,formatters:d4,labels:w4,locale:n,modifiersClassNames:r,modifiers:s,numberOfMonths:o,styles:i,today:a,mode:"default"}}function x4(e){var t=e.fromYear,n=e.toYear,r=e.fromMonth,s=e.toMonth,o=e.fromDate,i=e.toDate;return r?o=Kt(r):t&&(o=new Date(t,0,1)),s?i=cv(s):n&&(i=new Date(n,11,31)),{fromDate:o?qi(o):void 0,toDate:i?qi(i):void 0}}var hk=m.createContext(void 0);function _4(e){var t,n=e.initialProps,r=b4(),s=x4(n),o=s.fromDate,i=s.toDate,a=(t=n.captionLayout)!==null&&t!==void 0?t:r.captionLayout;a!=="buttons"&&(!o||!i)&&(a="buttons");var l;(Xd(n)||tc(n)||nc(n))&&(l=n.onSelect);var c=ae(ae(ae({},r),n),{captionLayout:a,classNames:ae(ae({},r.classNames),n.classNames),components:ae({}
241,n.components),formatters:ae(ae({},r.formatters),n.formatters),fromDate:o,labels:ae(ae({},r.labels),n.labels),mode:n.mode||r.mode,modifiers:ae(ae({},r.modifiers),n.modifiers),modifiersClassNames:ae(ae({},r.modifiersClassNames),n.modifiersClassNames),onSelect:l,styles:ae(ae({},r.styles),n.styles),toDate:i});return f.jsx(hk.Provider,{value:c,children:e.children})}function De(){var e=m.useContext(hk);if(!e)throw new Error("useDayPicker must be used within a DayPickerProvider.");return e}function pk(e){var t=De(),n=t.locale,r=t.classNames,s=t.styles,o=t.formatters.formatCaption;return f.jsx("div",{className:r.caption_label,style:s.caption_label,"aria-live":"polite",role:"presentation",id:e.id,children:o(e.displayMonth,{locale:n})})}function S4(e){return f.jsx("svg",ae({width:"8px",height:"8px",viewBox:"0 0 120 120","data-testid":"iconDropdown"},e,{children:f.jsx("path",{d:"M4.22182541,48.2218254 C8.44222828,44.0014225 15.2388494,43.9273804 19.5496459,47.9996989 L19.7781746,48.2218254 L60,88.443 L100.221825,48.2218254 C104.442228,44.0014225 111.238849,43.9273804 115.549646,47.9996989 L115.778175,48.2218254 C119.998577,52.4422283 120.07262,59.2388494 116.000301,63.5496459 L115.778175,63.7781746 L67.7781746,111.778175 C63.5577717,115.998577 56.7611506,116.07262 52.4503541,112.000301 L52.2218254,111.778175 L4.22182541,63.7781746 C-0.0739418023,59.4824074 -0.0739418023,52.5175926 4.22182541,48.2218254 Z",fill:"currentColor",fillRule:"nonzero"})}))}function mk(e){var t,n,r=e.onChange,s=e.value,o=e.children,i=e.caption,a=e.className,l=e.style,c=De(),u=(n=(t=c.components)===null||t===void 0?void 0:t.IconDropdown)!==null&&n!==void 0?n:S4;return f.jsxs("div",{className:a,style:l,children:[f.jsx("span",{className:c.classNames.vhidden,children:e["aria-label"]}),f.jsx("select",{name:e.name,"aria-label":e["aria-label"],className:c.classNames.dropdown,style:c.styles.dropdown,value:s,onChange:r,children:o}),f.jsxs("div",{className:c.classNames.caption_label,style:c.styles.caption_label,"aria-hidden":"true",children:[i,f.jsx(u,{className:c.classNames.dropdown_icon,style:c.styles.dropdown_icon})]})]})}function E4(e){var t,n=De(),r=n.fromDate,s=n.toDate,o=n.styles,i=n.locale,a=n.formatters.formatMonthCaption,l=n.classNames,c=n.components,u=n.labels.labelMonthDropdown;if(!r)return f.jsx(f.Fragment,{});if(!s)return f.jsx(f.Fragment,{});var d=[];if(n4(r,s))for(var p=Kt(r),h=r.getMonth();h<=s.getMonth();h++)d.push(hh(p,h));else for(var p=Kt(new Date),h=0;h<=11;h++)d.push(hh(p,h));var x=function(b){var w=Number(b.target.value),g=hh(Kt(e.displayMonth),w);e.onChange(g)},v=(t=c==null?void 0:c.Dropdown)!==null&&t!==void 0?t:mk;return f.jsx(v,{name:"months","aria-label":u(),className:l.dropdown_month,style:o.dropdown_month,onChange:x,value:e.displayMonth.getMonth(),caption:a(e.displayMonth,{locale:i}),children:d.map(function(b){return f.jsx("option",{value:b.getMonth(),children:a(b,{locale:i})},b.getMonth())})})}function k4(e){var t,n=e.displayMonth,r=De(),s=r.fromDate,o=r.toDate,i=r.locale,a=r.styles,l=r.classNames,c=r.components,u=r.formatters.formatYearCaption,d=r.labels.labelYearDropdown,p=[];if(!s)return f.jsx(f.Fragment,{});if(!o)return f.jsx(f.Fragment,{});for(var h=s.getFullYear(),x=o.getFullYear(),v=h;v<=x;v++)p.push(l0(sk(new Date),v));var b=function(g){var y=l0(Kt(n),Number(g.target.value));e.onChange(y)},w=(t=c==null?void 0:c.Dropdown)!==null&&t!==void 0?t:mk;return f.jsx(w,{name:"years","aria-label":d(),className:l.dropdown_year,style:a.dropdown_year,onChange:b,value:n.getFullYear(),caption:u(n,{locale:i}),children:p.map(function(g){return f.jsx("option",{value:g.getFullYear(),children:u(g,{locale:i})},g.getFullYear())})})}function C4(e,t){var n=m.useState(e),r=n[0],s=n[1],o=t===void 0?r:t;return[o,s]}function T4(e){var t=e.month,n=e.defaultMonth,r=e.today,s=t||n||r||new Date,o=e.toDate,i=e.fromDate,a=e.numberOfMonths,l=a===void 0?1:a;if(o&&Al(o,s)<0){var c=-1*(l-1);s=Qn(o,c)}return i&&Al(s,i)<0&&(s=i),Kt(s)}function R4(){var e=De(),t=T4(e),n=C4(t,e.month),r=n[0],s=n[1],o=function(i){var a;if(!e.disableNavigation){var l=Kt(i);s(l),(a=e.onMonthChange)===null||a===void 0||a.call(e,l)}};return[r,o]}function P4(e,t){for(var n=t.reverseMonths,r=t.numberOfMonths,s=Kt(e),o=Kt(Qn(s,r)),i=Al(o,s),a=[],l=0;l<i;l++){var c=Qn(s,l);a.push(c)}return n&&(a=a.reverse()),a}function N4(e,t){if(!t.disableNavigation){var n=t.toDate,r=t.pagedNavigation,s=t.numberOfMonths,o=s===void 0?1:s,i=r?o:1,a=Kt(e);if(!n)return Qn(a,i);var l=Al(n,e);if(!(l<o))return Qn(a,i)}}function A4(e,t){if(!t.disableNavigation){var n=t.fromDate,r=t.pagedNavigation,s=t.numberOfMonths,o=s===void 0?1:s,i=r?o:1,a=Kt(e);if(!n)return Qn(a,-i);var l=Al(a,n);if(!(l<=0))return Qn(a,-i)}}var gk=m.createContext(void 0);function O4(e){var t=De(),n=R4(),r=n[0],s=n[1],o=P4(r,t),i=N4(r,t),a=A4(r,t),l=function(d){return o.some(function(p){return dv(d,p)})},c=function(d,p){l(d)||(p&&dk(d,p)?s(Qn(d,1+t.numberOfMonths*-1)):s(d))},u={currentMonth:r,displayMonths:o,goToMonth:s,goToDate:c,previousMonth:a,nextMonth:i,isDateDisplayed:l};return f.jsx(gk.Provider,{value:u,children:e.children})}function rc(){var e=m.useContext(gk);if(!e)throw new Error("useNavigation must be used within a NavigationProvider");return e}function c0(e){var t,n=De(),r=n.classNames,s=n.styles,o=n.components,i=rc().goToMonth,a=function(u){i(Qn(u,e.displayIndex?-e.dis
241playIndex:0))},l=(t=o==null?void 0:o.CaptionLabel)!==null&&t!==void 0?t:pk,c=f.jsx(l,{id:e.id,displayMonth:e.displayMonth});return f.jsxs("div",{className:r.caption_dropdowns,style:s.caption_dropdowns,children:[f.jsx("div",{className:r.vhidden,children:c}),f.jsx(E4,{onChange:a,displayMonth:e.displayMonth}),f.jsx(k4,{onChange:a,displayMonth:e.displayMonth})]})}function j4(e){return f.jsx("svg",ae({width:"16px",height:"16px",viewBox:"0 0 120 120"},e,{children:f.jsx("path",{d:"M69.490332,3.34314575 C72.6145263,0.218951416 77.6798462,0.218951416 80.8040405,3.34314575 C83.8617626,6.40086786 83.9268205,11.3179931 80.9992143,14.4548388 L80.8040405,14.6568542 L35.461,60 L80.8040405,105.343146 C83.8617626,108.400868 83.9268205,113.317993 80.9992143,116.454839 L80.8040405,116.656854 C77.7463184,119.714576 72.8291931,119.779634 69.6923475,116.852028 L69.490332,116.656854 L18.490332,65.6568542 C15.4326099,62.5991321 15.367552,57.6820069 18.2951583,54.5451612 L18.490332,54.3431458 L69.490332,3.34314575 Z",fill:"currentColor",fillRule:"nonzero"})}))}function I4(e){return f.jsx("svg",ae({width:"16px",height:"16px",viewBox:"0 0 120 120"},e,{children:f.jsx("path",{d:"M49.8040405,3.34314575 C46.6798462,0.218951416 41.6145263,0.218951416 38.490332,3.34314575 C35.4326099,6.40086786 35.367552,11.3179931 38.2951583,14.4548388 L38.490332,14.6568542 L83.8333725,60 L38.490332,105.343146 C35.4326099,108.400868 35.367552,113.317993 38.2951583,116.454839 L38.490332,116.656854 C41.5480541,119.714576 46.4651794,119.779634 49.602025,116.852028 L49.8040405,116.656854 L100.804041,65.6568542 C103.861763,62.5991321 103.926821,57.6820069 100.999214,54.5451612 L100.804041,54.3431458 L49.8040405,3.34314575 Z",fill:"currentColor"})}))}var Ju=m.forwardRef(function(e,t){var n=De(),r=n.classNames,s=n.styles,o=[r.button_reset,r.button];e.className&&o.push(e.className);var i=o.join(" "),a=ae(ae({},s.button_reset),s.button);return e.style&&Object.assign(a,e.style),f.jsx("button",ae({},e,{ref:t,type:"button",className:i,style:a}))});function D4(e){var t,n,r=De(),s=r.dir,o=r.locale,i=r.classNames,a=r.styles,l=r.labels,c=l.labelPrevious,u=l.labelNext,d=r.components;if(!e.nextMonth&&!e.previousMonth)return f.jsx(f.Fragment,{});var p=c(e.previousMonth,{locale:o}),h=[i.nav_button,i.nav_button_previous].join(" "),x=u(e.nextMonth,{locale:o}),v=[i.nav_button,i.nav_button_next].join(" "),b=(t=d==null?void 0:d.IconRight)!==null&&t!==void 0?t:I4,w=(n=d==null?void 0:d.IconLeft)!==null&&n!==void 0?n:j4;return f.jsxs("div",{className:i.nav,style:a.nav,children:[!e.hidePrevious&&f.jsx(Ju,{name:"previous-month","aria-label":p,className:h,style:a.nav_button_previous,disabled:!e.previousMonth,onClick:e.onPreviousClick,children:s==="rtl"?f.jsx(b,{className:i.nav_icon,style:a.nav_icon}):f.jsx(w,{className:i.nav_icon,style:a.nav_icon})}),!e.hideNext&&f.jsx(Ju,{name:"next-month","aria-label":x,className:v,style:a.nav_button_next,disabled:!e.nextMonth,onClick:e.onNextClick,children:s==="rtl"?f.jsx(w,{className:i.nav_icon,style:a.nav_icon}):f.jsx(b,{className:i.nav_icon,style:a.nav_icon})})]})}function u0(e){var t=De().numberOfMonths,n=rc(),r=n.previousMonth,s=n.nextMonth,o=n.goToMonth,i=n.displayMonths,a=i.findIndex(function(x){return dv(e.displayMonth,x)}),l=a===0,c=a===i.length-1,u=t>1&&(l||!c),d=t>1&&(c||!l),p=function(){r&&o(r)},h=function(){s&&o(s)};return f.jsx(D4,{displayMonth:e.displayMonth,hideNext:u,hidePrevious:d,nextMonth:s,previousMonth:r,onPreviousClick:p,onNextClick:h})}function M4(e){var t,n=De(),r=n.classNames,s=n.disableNavigation,o=n.styles,i=n.captionLayout,a=n.components,l=(t=a==null?void 0:a.CaptionLabel)!==null&&t!==void 0?t:pk,c;return s?c=f.jsx(l,{id:e.id,displayMonth:e.displayMonth}):i==="dropdown"?c=f.jsx(c0,{displayMonth:e.displayMonth,id:e.id}):i==="dropdown-buttons"?c=f.jsxs(f.Fragment,{children:[f.jsx(c0,{displayMonth:e.displayMonth,displayIndex:e.displayIndex,id:e.id}),f.jsx(u0,{displayMonth:e.displayMonth,displayIndex:e.displayIndex,id:e.id})]}):c=f.jsxs(f.Fragment,{children:[f.jsx(l,{id:e.id,displayMonth:e.displayMonth,displayIndex:e.displayIndex}),f.jsx(u0,{displayMonth:e.displayMonth,id:e.id})]}),f.jsx("div",{className:r.caption,style:o.caption,children:c})}function L4(e){var t=De(),n=t.footer,r=t.styles,s=t.classNames.tfoot;return n?f.jsx("tfoot",{className:s,style:r.tfoot,children:f.jsx("tr",{children:f.jsx("td",{colSpan:8,children:n})})}):f.jsx(f.Fragment,{})}function $4(e,t,n){for(var r=n?Ro(new Date):br(new Date,{locale:e,weekStartsOn:t}),s=[],o=0;o<7;o++){var i=Pt(r,o);s.push(i)}return s}
241function F4(){var e=De(),t=e.classNames,n=e.styles,r=e.showWeekNumber,s=e.locale,o=e.weekStartsOn,i=e.ISOWeek,a=e.formatters.formatWeekdayName,l=e.labels.labelWeekday,c=$4(s,o,i);return f.jsxs("tr",{style:n.head_row,className:t.head_row,children:[r&&f.jsx("td",{style:n.head_cell,className:t.head_cell}),c.map(function(u,d){return f.jsx("th",{scope:"col",className:t.head_cell,style:n.head_cell,"aria-label":l(u,{locale:s}),children:a(u,{locale:s})},d)})]})}function U4(){var e,t=De(),n=t.classNames,r=t.styles,s=t.components,o=(e=s==null?void 0:s.HeadRow)!==null&&e!==void 0?e:F4;return f.jsx("thead",{style:r.head,className:n.head,children:f.jsx(o,{})})}function B4(e){var t=De(),n=t.locale,r=t.formatters.formatDay;return f.jsx(f.Fragment,{children:r(e.date,{locale:n})})}var fv=m.createContext(void 0);function z4(e){if(!tc(e.initialProps)){var t={selected:void 0,modifiers:{disabled:[]}};return f.jsx(fv.Provider,{value:t,children:e.children})}return f.jsx(W4,{initialProps:e.initialProps,children:e.children})}function W4(e){var t=e.initialProps,n=e.children,r=t.selected,s=t.min,o=t.max,i=function(c,u,d){var p,h;(p=t.onDayClick)===null||p===void 0||p.call(t,c,u,d);var x=!!(u.selected&&s&&(r==null?void 0:r.length)===s);if(!x){var v=!!(!u.selected&&o&&(r==null?void 0:r.length)===o);if(!v){var b=r?fk([],r):[];if(u.selected){var w=b.findIndex(function(g){return Wt(c,g)});b.splice(w,1)}else b.push(c);(h=t.onSelect)===null||h===void 0||h.call(t,b,c,u,d)}}},a={disabled:[]};r&&a.disabled.push(function(c){var u=o&&r.length>o-1,d=r.some(function(p){return Wt(p,c)});return!!(u&&!d)});var l={selected:r,onDayClick:i,modifiers:a};return f.jsx(fv.Provider,{value:l,children:n})}function hv(){var e=m.useContext(fv);if(!e)throw new Error("useSelectMultiple must be used within a SelectMultipleProvider");return e}function H4(e,t){var n=t||{},r=n.from,s=n.to;return r&&s?Wt(s,e)&&Wt(r,e)?void 0:Wt(s,e)?{from:s,to:void 0}:Wt(r,e)?void 0:em(r,e)?{from:e,to:s}:{from:r,to:e}:s?em(e,s)?{from:s,to:e}:{from:e,to:s}:r?dk(e,r)?{from:e,to:r}:{from:r,to:e}:{from:e,to:void 0}}var pv=m.createContext(void 0);function V4(e){if(!nc(e.initialProps)){var t={selected:void 0,modifiers:{range_start:[],range_end:[],range_middle:[],disabled:[]}};return f.jsx(pv.Provider,{value:t,children:e.children})}return f.jsx(q4,{initialProps:e.initialProps,children:e.children})}function q4(e){var t=e.initialProps,n=e.children,r=t.selected,s=r||{},o=s.from,i=s.to,a=t.min,l=t.max,c=function(h,x,v){var b,w;(b=t.onDayClick)===null||b===void 0||b.call(t,h,x,v);var g=H4(h,r);(w=t.onSelect)===null||w===void 0||w.call(t,g,h,x,v)},u={range_start:[],range_end:[],range_middle:[],disabled:[]};if(o?(u.range_start=[o],i?(u.range_end=[i],Wt(o,i)||(u.range_middle=[{after:o,before:i}])):u.range_end=[o]):i&&(u.range_start=[i],u.range_end=[i]),a&&(o&&!i&&u.disabled.push({after:fh(o,a-1),before:Pt(o,a-1)}),o&&i&&u.disabled.push({after:o,before:Pt(o,a-1)}),!o&&i&&u.disabled.push({after:fh(i,a-1),before:Pt(i,a-1)})),l){if(o&&!i&&(u.disabled.push({before:Pt(o,-l+1)}),u.disabled.push({after:Pt(o,l-1)})),o&&i){var d=pr(i,o)+1,p=l-d;u.disabled.push({before:fh(o,p)}),u.disabled.push({after:Pt(i,p)})}!o&&i&&(u.disabled.push({before:Pt(i,-l+1)}),u.disabled.push({after:Pt(i,l-1)}))}return f.jsx(pv.Provider,{value:{selected:r,onDayClick:c,modifiers:u},children:n})}function mv(){var e=m.useContext(pv);if(!e)throw new Error("useSelectRange must be used within a SelectRangeProvider");return e}function fu(e){return Array.isArray(e)?fk([],e):e!==void 0?[e]:[]}function K4(e){var t={};return Object.entries(e).forEach(function(n){var r=n[0],s=n[1];t[r]=fu(s)}),t}var Jn;(function(e){e.Outside="outside",e.Disabled="disabled",e.Selected="selected",e.Hidden="hidden",e.Today="today",e.RangeStart="range_start",e.RangeEnd="range_end",e.RangeMiddle="range_middle"})(Jn||(Jn={}));var G4=Jn.Selected,Pr=Jn.Disabled,Y4=Jn.Hidden,Z4=Jn.Today,ph=Jn.RangeEnd,mh=Jn.RangeMiddle,gh=Jn.RangeStart,Q4=Jn.Outside;function J4(e,t,n){var r,s=(r={},r[G4]=fu(e.selected),r[Pr]=fu(e.disabled),r[Y4]=fu(e.hidden),r[Z4]=[e.today],r[ph]=[],r[mh]=[],r[gh]=[],r[Q4]=[],r);return e.fromDate&&s[Pr].push({before:e.fromDate}),e.toDate&&s[Pr].push({after:e.toDate}),tc(e)?s[Pr]=s[Pr].concat(t.modifiers[Pr]):nc(e)&&(s[Pr]=s[Pr].concat(n.modifiers[Pr]),s[gh]=n.modifiers[gh],s[mh]=n.modifiers[mh],s[ph]=n.modifiers[ph]),s}var vk=m.createContext(void 0);function X4(e){var t=De(),n=hv(),r=mv(),s=J4(t,n,r),o=K4(t.modifiers),i=ae(ae({},s),o);return f.jsx(vk.Provider,{value:i,children:e.children})}function yk(){var e=m.useContext(vk);if(!e)throw new Error("useModifiers must be used within a ModifiersProvider");return e}function eF(e){return!!(e&&typeof e=="object"&&"before"in e&&"after"in e)}function tF(e){return!!(e&&typeof e=="object"&&"from"in e)}function nF(e){return!!(e&&typeof e=="object"&&"after"in e)}function rF(e){return!!(e&&typeof e=="object"&&"before"in e)}function sF(e){return!!(e&&typeof e=="object"&&"dayOfWeek"in e)}function oF(e,t){var n,r=t.from,s=t.to;if(r&&s){var o=pr(s,r)<0;o&&(n=[s,r],r=n[0],s=n[1]);var i=pr(e,r)>=0&&pr(s,e)>=0;return i}return s?Wt(s,e):r?Wt(r,e):!1}function iF(e){return lv(e)}function aF(e){return Array.isArray(e)&&e.every(lv)}function lF(e,t){return t.some(function(n){if(typeof n=="boolean")return n;if(iF(n))return Wt(e,n);if(aF(n))return n.includes(e);if(tF(n))return oF(e,n);if(sF(n))return n.dayOfWeek.includes(e.getDay());if(eF(n)){var r=pr(n.before,e),s=pr(n.after,e),o=r>0,i=s<0,a=em(n.before,n.after);return a?i&&o:o||i}return nF(n)?pr(e,n.after)>0:rF(n)?pr(n.before,e)>0:typeof n=="function"?n(e):!1})}
241function gv(e,t,n){var r=Object.keys(t).reduce(function(o,i){var a=t[i];return lF(e,a)&&o.push(i),o},[]),s={};return r.forEach(function(o){return s[o]=!0}),n&&!dv(e,n)&&(s.outside=!0),s}function cF(e,t){for(var n=Kt(e[0]),r=cv(e[e.length-1]),s,o,i=n;i<=r;){var a=gv(i,t),l=!a.disabled&&!a.hidden;if(!l){i=Pt(i,1);continue}if(a.selected)return i;a.today&&!o&&(o=i),s||(s=i),i=Pt(i,1)}return o||s}var uF=365;function wk(e,t){var n=t.moveBy,r=t.direction,s=t.context,o=t.modifiers,i=t.retry,a=i===void 0?{count:0,lastFocused:e}:i,l=s.weekStartsOn,c=s.fromDate,u=s.toDate,d=s.locale,p={day:Pt,week:Xp,month:Qn,year:JL,startOfWeek:function(b){return s.ISOWeek?Ro(b):br(b,{locale:d,weekStartsOn:l})},endOfWeek:function(b){return s.ISOWeek?ok(b):uv(b,{locale:d,weekStartsOn:l})}},h=p[n](e,r==="after"?1:-1);r==="before"&&c?h=XL([c,h]):r==="after"&&u&&(h=e$([u,h]));var x=!0;if(o){var v=gv(h,o);x=!v.disabled&&!v.hidden}return x?h:a.count>uF?a.lastFocused:wk(h,{moveBy:n,direction:r,context:s,modifiers:o,retry:ae(ae({},a),{count:a.count+1})})}var bk=m.createContext(void 0);function dF(e){var t=rc(),n=yk(),r=m.useState(),s=r[0],o=r[1],i=m.useState(),a=i[0],l=i[1],c=cF(t.displayMonths,n),u=s??(a&&t.isDateDisplayed(a))?a:c,d=function(){l(s),o(void 0)},p=function(b){o(b)},h=De(),x=function(b,w){if(s){var g=wk(s,{moveBy:b,direction:w,context:h,modifiers:n});Wt(s,g)||(t.goToDate(g,s),p(g))}},v={focusedDay:s,focusTarget:u,blur:d,focus:p,focusDayAfter:function(){return x("day","after")},focusDayBefore:function(){return x("day","before")},focusWeekAfter:function(){return x("week","after")},focusWeekBefore:function(){return x("week","before")},focusMonthBefore:function(){return x("month","before")},focusMonthAfter:function(){return x("month","after")},focusYearBefore:function(){return x("year","before")},focusYearAfter:function(){return x("year","after")},focusStartOfWeek:function(){return x("startOfWeek","before")},focusEndOfWeek:function(){return x("endOfWeek","after")}};return f.jsx(bk.Provider,{value:v,children:e.children})}function vv(){var e=m.useContext(bk);if(!e)throw new Error("useFocusContext must be used within a FocusProvider");return e}function fF(e,t){var n=yk(),r=gv(e,n,t);return r}var yv=m.createContext(void 0);function hF(e){if(!Xd(e.initialProps)){var t={selected:void 0};return f.jsx(yv.Provider,{value:t,children:e.children})}return f.jsx(pF,{initialProps:e.initialProps,children:e.children})}function pF(e){var t=e.initialProps,n=e.children,r=function(o,i,a){var l,c,u;if((l=t.onDayClick)===null||l===void 0||l.call(t,o,i,a),i.selected&&!t.required){(c=t.onSelect)===null||c===void 0||c.call(t,void 0,o,i,a);return}(u=t.onSelect)===null||u===void 0||u.call(t,o,o,i,a)},s={selected:t.selected,onDayClick:r};return f.jsx(yv.Provider,{value:s,children:n})}function xk(){var e=m.useContext(yv);if(!e)throw new Error("useSelectSingle must be used within a SelectSingleProvider");return e}function mF(e,t){var n=De(),r=xk(),s=hv(),o=mv(),i=vv(),a=i.focusDayAfter,l=i.focusDayBefore,c=i.focusWeekAfter,u=i.focusWeekBefore,d=i.blur,p=i.focus,h=i.focusMonthBefore,x=i.focusMonthAfter,v=i.focusYearBefore,b=i.focusYearAfter,w=i.focusStartOfWeek,g=i.focusEndOfWeek,y=function(I){var T,N,z,V;Xd(n)?(T=r.onDayClick)===null||T===void 0||T.call(r,e,t,I):tc(n)?(N=s.onDayClick)===null||N===void 0||N.call(s,e,t,I):nc(n)?(z=o.onDayClick)===null||z===void 0||z.call(o,e,t,I):(V=n.onDayClick)===null||V===void 0||V.call(n,e,t,I)},_=function(I){var T;p(e),(T=n.onDayFocus)===null||T===void 0||T.call(n,e,t,I)},S=function(I){var T;d(),(T=n.onDayBlur)===null||T===void 0||T.call(n,e,t,I)},k=function(I){var T;(T=n.onDayMouseEnter)===null||T===void 0||T.call(n,e,t,I)},E=function(I){var T;(T=n.onDayMouseLeave)===null||T===void 0||T.call(n,e,t,I)},R=function(I){var T;(T=n.onDayPointerEnter)===null||T===void 0||T.call(n,e,t,I)},P=function(I){var T;(T=n.onDayPointerLeave)===null||T===void 0||T.call(n,e,t,I)},A=function(I){var T;(T=n.onDayTouchCancel)===null||T===void 0||T.call(n,e,t,I)},D=function(I){var T;(T=n.onDayTouchEnd)===null||T===void 0||T.call(n,e,t,I)},M=function(I){var T;(T=n.onDayTouchMove)===null||T===void 0||T.call(n,e,t,I)},H=function(I){var T;(T=n.onDayTouchStart)===null||T===void 0||T.call(n,e,t,I)},L=function(I){var T;(T=n.onDayKeyUp)===null||T===void 0||T.call(n,e,t,I)},Z=function(I){var T;switch(I.key){case"ArrowLeft":I.preventDefault(),I.stopPropagation(),n.dir==="rtl"?a():l();break;case"ArrowRight":I.preventDefault(),I.stopPropagation(),n.dir==="rtl"?l(
241):a();break;case"ArrowDown":I.preventDefault(),I.stopPropagation(),c();break;case"ArrowUp":I.preventDefault(),I.stopPropagation(),u();break;case"PageUp":I.preventDefault(),I.stopPropagation(),I.shiftKey?v():h();break;case"PageDown":I.preventDefault(),I.stopPropagation(),I.shiftKey?b():x();break;case"Home":I.preventDefault(),I.stopPropagation(),w();break;case"End":I.preventDefault(),I.stopPropagation(),g();break}(T=n.onDayKeyDown)===null||T===void 0||T.call(n,e,t,I)},B={onClick:y,onFocus:_,onBlur:S,onKeyDown:Z,onKeyUp:L,onMouseEnter:k,onMouseLeave:E,onPointerEnter:R,onPointerLeave:P,onTouchCancel:A,onTouchEnd:D,onTouchMove:M,onTouchStart:H};return B}function gF(){var e=De(),t=xk(),n=hv(),r=mv(),s=Xd(e)?t.selected:tc(e)?n.selected:nc(e)?r.selected:void 0;return s}function vF(e){return Object.values(Jn).includes(e)}function yF(e,t){var n=[e.classNames.day];return Object.keys(t).forEach(function(r){var s=e.modifiersClassNames[r];if(s)n.push(s);else if(vF(r)){var o=e.classNames["day_".concat(r)];o&&n.push(o)}}),n}function wF(e,t){var n=ae({},e.styles.day);return Object.keys(t).forEach(function(r){var s;n=ae(ae({},n),(s=e.modifiersStyles)===null||s===void 0?void 0:s[r])}),n}function bF(e,t,n){var r,s,o,i=De(),a=vv(),l=fF(e,t),c=mF(e,l),u=gF(),d=!!(i.onDayClick||i.mode!=="default");m.useEffect(function(){var k;l.outside||a.focusedDay&&d&&Wt(a.focusedDay,e)&&((k=n.current)===null||k===void 0||k.focus())},[a.focusedDay,e,n,d,l.outside]);var p=yF(i,l).join(" "),h=wF(i,l),x=!!(l.outside&&!i.showOutsideDays||l.hidden),v=(o=(s=i.components)===null||s===void 0?void 0:s.DayContent)!==null&&o!==void 0?o:B4,b=f.jsx(v,{date:e,displayMonth:t,activeModifiers:l}),w={style:h,className:p,children:b,role:"gridcell"},g=a.focusTarget&&Wt(a.focusTarget,e)&&!l.outside,y=a.focusedDay&&Wt(a.focusedDay,e),_=ae(ae(ae({},w),(r={disabled:l.disabled,role:"gridcell"},r["aria-selected"]=l.selected,r.tabIndex=y||g?0:-1,r)),c),S={isButton:d,isHidden:x,activeModifiers:l,selectedDays:u,buttonProps:_,divProps:w};return S}function xF(e){var t=m.useRef(null),n=bF(e.date,e.displayMonth,t);return n.isHidden?f.jsx("div",{role:"gridcell"}):n.isButton?f.jsx(Ju,ae({name:"day",ref:t},n.buttonProps)):f.jsx("div",ae({},n.divProps))}function _F(e){var t=e.number,n=e.dates,r=De(),s=r.onWeekNumberClick,o=r.styles,i=r.classNames,a=r.locale,l=r.labels.labelWeekNumber,c=r.formatters.formatWeekNumber,u=c(Number(t),{locale:a});if(!s)return f.jsx("span",{className:i.weeknumber,style:o.weeknumber,children:u});var d=l(Number(t),{locale:a}),p=function(h){s(t,n,h)};return f.jsx(Ju,{name:"week-number","aria-label":d,className:i.weeknumber,style:o.weeknumber,onClick:p,children:u})}function SF(e){var t,n,r=De(),s=r.styles,o=r.classNames,i=r.showWeekNumber,a=r.components,l=(t=a==null?void 0:a.Day)!==null&&t!==void 0?t:xF,c=(n=a==null?void 0:a.WeekNumber)!==null&&n!==void 0?n:_F,u;return i&&(u=f.jsx("td",{className:o.cell,style:s.cell,children:f.jsx(c,{number:e.weekNumber,dates:e.dates})})),f.jsxs("tr",{className:o.row,style:s.row,children:[u,e.dates.map(function(d){return f.jsx("td",{className:o.cell,style:s.cell,role:"presentation",children:f.jsx(l,{displayMonth:e.displayMonth,date:d})},X$(d))})]})}function d0(e,t,n){for(var r=n!=null&&n.ISOWeek?ok(t):uv(t,n),s=n!=null&&n.ISOWeek?Ro(e):br(e,n),o=pr(r,s),i=[],a=0;a<=o;a++)i.push(Pt(s,a));var l=i.reduce(function(c,u){var d=n!=null&&n.ISOWeek?ak(u):ck(u,n),p=c.find(function(h){return h.weekNumber===d});return p?(p.dates.push(u),c):(c.push({weekNumber:d,dates:[u]}),c)},[]);return l}function EF(e,t){var n=d0(Kt(e),cv(e),t);if(t!=null&&t.useFixedWeeks){var r=t4(e,t);if(r<6){var s=n[n.length-1],o=s.dates[s.dates.length-1],i=Xp(o,6-r),a=d0(Xp(o,1),i,t);n.push.apply(n,a)}}return n}function kF(e){var t,n,r,s=De(),o=s.locale,i=s.classNames,a=s.styles,l=s.hideHead,c=s.fixedWeeks,u=s.components,d=s.weekStartsOn,p=s.firstWeekContainsDate,h=s.ISOWeek,x=EF(e.displayMonth,{useFixedWeeks:!!c,ISOWeek:h,locale:o,weekStartsOn:d,firstWeekContainsDate:p}),v=(t=u==null?void 0:u.Head)!==null&&t!==void 0?t:U4,b=(n=u==null?void 0:u.Row)!==null&&n!==void 0?n:SF,w=(r=u==null?void 0:u.Footer)!==null&&r!==void 0?r:L4;return f.jsxs("table",{id:e.id,className:i.table,style:a.table,role:"grid","aria-labelledby":e["aria-labelledby"],children:[!l&&f.jsx(v,{}),f.jsx("tbody",{className:i.tbody,style:a.tbody,children:x.map(function(g){return f.jsx(b,{displayMonth:e.displayMonth,dates:g.dates,weekNumber:g.weekNumber},g.weekNumber)})}),f.jsx(w,{displayMonth:e.displayMonth})]})}function CF(){return!!(typeof window<"u"&&window.document&&window.document.createElement)}var TF=CF()?m.useLayoutEffect:m.useEffect,vh=!1,RF=0;function f0(){return"react-day-picker-".concat(++RF)}function PF(e){var t,n=e??(vh?f0():null),r=m.useState(n),s=r[0],o=r[1];return TF(function(){s===null&&o(f0())},[]),m.useEffect(function(){vh===!1&&(vh=!0)},[]),(t=e??s)!==null&&t!==void 0?t:void 0}function NF(e){var t,n,r=De(),s=r.dir,o=r.classNames,i=r.styles,a=r.components,l=rc().displayMonths,c=PF(r.id?"".concat(r.id,"-").concat(e.displayIndex):void 0),u=r.
vendor: 4,398 bytes, line 241
241id?"".concat(r.id,"-grid-").concat(e.displayIndex):void 0,d=[o.month],p=i.month,h=e.displayIndex===0,x=e.displayIndex===l.length-1,v=!h&&!x;s==="rtl"&&(t=[h,x],x=t[0],h=t[1]),h&&(d.push(o.caption_start),p=ae(ae({},p),i.caption_start)),x&&(d.push(o.caption_end),p=ae(ae({},p),i.caption_end)),v&&(d.push(o.caption_between),p=ae(ae({},p),i.caption_between));var b=(n=a==null?void 0:a.Caption)!==null&&n!==void 0?n:M4;return f.jsxs("div",{className:d.join(" "),style:p,children:[f.jsx(b,{id:c,displayMonth:e.displayMonth,displayIndex:e.displayIndex}),f.jsx(kF,{id:u,"aria-labelledby":c,displayMonth:e.displayMonth})]},e.displayIndex)}function AF(e){var t=De(),n=t.classNames,r=t.styles;return f.jsx("div",{className:n.months,style:r.months,children:e.children})}function OF(e){var t,n,r=e.initialProps,s=De(),o=vv(),i=rc(),a=m.useState(!1),l=a[0],c=a[1];m.useEffect(function(){s.initialFocus&&o.focusTarget&&(l||(o.focus(o.focusTarget),c(!0)))},[s.initialFocus,l,o.focus,o.focusTarget,o]);var u=[s.classNames.root,s.className];s.numberOfMonths>1&&u.push(s.classNames.multiple_months),s.showWeekNumber&&u.push(s.classNames.with_weeknumber);var d=ae(ae({},s.styles.root),s.style),p=Object.keys(r).filter(function(x){return x.startsWith("data-")}).reduce(function(x,v){var b;return ae(ae({},x),(b={},b[v]=r[v],b))},{}),h=(n=(t=r.components)===null||t===void 0?void 0:t.Months)!==null&&n!==void 0?n:AF;return f.jsx("div",ae({className:u.join(" "),style:d,dir:s.dir,id:s.id,nonce:r.nonce,title:r.title,lang:r.lang},p,{children:f.jsx(h,{children:i.displayMonths.map(function(x,v){return f.jsx(NF,{displayIndex:v,displayMonth:x},v)})})}))}function jF(e){var t=e.children,n=r4(e,["children"]);return f.jsx(_4,{initialProps:n,children:f.jsx(O4,{children:f.jsx(hF,{initialProps:n,children:f.jsx(z4,{initialProps:n,children:f.jsx(V4,{initialProps:n,children:f.jsx(X4,{children:f.jsx(dF,{children:t})})})})})})})}function IF(e){return f.jsx(jF,ae({},e,{children:f.jsx(OF,{initialProps:e})}))}function _k({className:e,classNames:t,showOutsideDays:n=!0,...r}){return f.jsx(IF,{showOutsideDays:n,className:me("p-3",e),classNames:{months:"flex flex-col sm:flex-row space-y-4 sm:space-x-4 sm:space-y-0",month:"space-y-4",caption:"flex justify-center pt-1 relative items-center",caption_label:"text-sm font-medium",nav:"space-x-1 flex items-center",nav_button:me(Gp({variant:"outline"}),"h-7 w-7 bg-transparent p-0 opacity-50 hover:opacity-100"),nav_button_previous:"absolute left-1",nav_button_next:"absolute right-1",table:"w-full border-collapse space-y-1",head_row:"flex",head_cell:"text-muted-foreground rounded-md w-9 font-normal text-[0.8rem]",row:"flex w-full mt-2",cell:"h-9 w-9 text-center text-sm p-0 relative [&:has([aria-selected].day-range-end)]:rounded-r-md [&:has([aria-selected].day-outside)]:bg-accent/50 [&:has([aria-selected])]:bg-accent first:[&:has([aria-selected])]:rounded-l-md last:[&:has([aria-selected])]:rounded-r-md focus-within:relative focus-within:z-20",day:me(Gp({variant:"ghost"}),"h-9 w-9 p-0 font-normal aria-selected:opacity-100"),day_range_end:"day-range-end",day_selected:"bg-primary text-primary-foreground hover:bg-primary hover:text-primary-foreground focus:bg-primary focus:text-primary-foreground",day_today:"bg-accent text-accent-foreground",day_outside:"day-outside text-muted-foreground opacity-50 aria-selected:bg-accent/50 aria-selected:text-muted-foreground aria-selected:opacity-30",day_disabled:"text-muted-foreground opacity-50",day_range_middle:"aria-selected:bg-accent aria-selected:text-accent-foreground",day_hidden:"invisible",...t},components:{IconLeft:({...s})=>f.jsx(Nd,{className:"h-4 w-4"}),IconRight:({...s})=>f.jsx(Ad,{className:"h-4 w-4"})},...r})}_k.displayName="Calendar";const tm=m.forwardRef(({className:e,type:t,...n},r)=>f.jsx("input",{type:t,className:me("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}));tm.displayName="Input";const Sk=m.forwardRef(({className:e,...t},n)=>f.jsx("textarea",{className:me("flex min-h-[80px] w-full rounded-md border border-input bg-background px-3 py-2 text-sm r
241ing-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}));Sk.displayName="Textarea";var DF=[" ","Enter","ArrowUp","ArrowDown"],MF=[" ","Enter"],Po="Select",[ef,tf,LF]=Zl(Po),[la,Dz]=Gt(Po,[LF,Ld]),nf=Ld(),[$F,Vs]=la(Po),[FF,UF]=la(Po),Ek=e=>{const{__scopeSelect:t,children:n,open:r,defaultOpen:s,onOpenChange:o,value:i,defaultValue:a,onValueChange:l,dir:c,name:u,autoComplete:d,disabled:p,required:h,form:x}=e,v=nf(t),[b,w]=m.useState(null),[g,y]=m.useState(null),[_,S]=m.useState(!1),k=oa(c),[E,R]=Gn({prop:r,defaultProp:s??!1,onChange:o,caller:Po}),[P,A]=Gn({prop:i,defaultProp:a,onChange:l,caller:Po}),D=m.useRef(null),M=b?x||!!b.closest("form"):!0,[H,L]=m.useState(new Set),Z=Array.from(H).map(B=>B.props.value).join(";");return f.jsx(Xj,{...v,children:f.jsxs($F,{required:h,scope:t,trigger:b,onTriggerChange:w,valueNode:g,onValueNodeChange:y,valueNodeHasChildren:_,onValueNodeHasChildrenChange:S,contentId:Ur(),value:P,onValueChange:A,open:E,onOpenChange:R,dir:k,triggerPointerDownPosRef:D,disabled:p,children:[f.jsx(ef.Provider,{scope:t,children:f.jsx(FF,{scope:e.__scopeSelect,onNativeOptionAdd:m.useCallback(B=>{L(I=>new Set(I).add(B))},[]),onNativeOptionRemove:m.useCallback(B=>{L(I=>{const T=new Set(I);return T.delete(B),T})},[]),children:n})}),M?f.jsxs(Gk,{"aria-hidden":!0,required:h,tabIndex:-1,name:u,autoComplete:d,value:P,onChange:B=>A(B.target.value),disabled:p,form:x,children:[P===void 0?f.jsx("option",{value:""}):null,Array.from(H)]},Z):null]})})};Ek.displayName=Po;var kk="SelectTrigger",Ck=m.forwardRef((e,t)=>{const{__scopeSelect:n,disabled:r=!1,...s}=e,o=nf(n),i=Vs(kk,n),a=i.disabled||r,l=de(t,i.onTriggerChange),c=tf(n),u=m.useRef("touch"),[d,p,h]=Zk(v=>{const b=c().filter(y=>!y.disabled),w=b.find(y=>y.value===i.value),g=Qk(b,v,w);g!==void 0&&i.onValueChange(g.value)}),x=v=>{a||(i.onOpenChange(!0),h()),v&&(i.triggerPointerDownPosRef.current={x:Math.round(v.pageX),y:Math.round(v.pageY)})};return f.jsx(FS,{asChild:!0,...o,children:f.jsx(ne.button,{type:"button",role:"combobox","aria-controls":i.contentId,"aria-expanded":i.open,"aria-required":i.required,"aria-autocomplete":"none",dir:i.dir,"data-state":i.open?"open":"closed",disabled:a,"data-disabled":a?"":void 0,"data-placeholder":Yk(i.value)?"":void 0,...s,ref:l,onClick:K(s.onClick,v=>{v.currentTarget.focus(),u.current!=="mouse"&&x(v)}),onPointerDown:K(s.onPointerDown,v=>{u.current=v.pointerType;const b=v.target;b.hasPointerCapture(v.pointerId)&&b.releasePointerCapture(v.pointerId),v.button===0&&v.ctrlKey===!1&&v.pointerType==="mouse"&&(x(v),v.preventDefault())}),onKeyDown:K(s.onKeyDown,v=>{const b=d.current!=="";!(v.ctrlKey||v.altKey||v.metaKey)&&v.key.length===1&&p(v.key),!(b&&v.key===" ")&&DF.includes(v.key)&&(x(),v.preventDefault())})})})});Ck.displayName=kk;var Tk="SelectValue",Rk=m.forwardRef((e,t)=>{const{__scopeSelect:n,className:r,style:s,children:o,placeholder:i="",...a}=e,l=Vs(Tk,n),{onValueNodeHasChildrenChange:c}=l,u=o!==void 0,d=de(t,l.onValueNodeChange);return it(()=>{c(u)},[c,u]),f.jsx(ne.span,{...a,ref:d,style:{pointerEvents:"none"},children:Yk(l.value)?f.jsx(f.Fragment,{children:i}):o})});Rk.displayName=Tk;var BF="SelectIcon",Pk=m.forwardRef((e,t)=>{const{__scopeSelect:n,children:r,...s}=e;return f.jsx(ne.span,{"aria-hidden":!0,...s,ref:t,children:r||"â¼"})});Pk.displayName=BF;var zF="SelectPortal",Nk=e=>f.jsx(Cd,{asChild:!0,...e});Nk.displayName=zF;var No="SelectContent",Ak=m.forwardRef((e,t)=>{const n=Vs(No,e.__scopeSelect),[r,s]=m.useState();if(it(()=>{s(new DocumentFragment)},[]),!n.open){const o=r;return o?Io.createPortal(f.jsx(Ok,{scope:e.__scopeSelect,children:f.jsx(ef.Slot,{scope:e.__scopeSelect,children:f.jsx("div",{children:e.children})})}),o):null}return f.jsx(jk,{...e,ref:t})});Ak.displayName=No;var Dn=10,[Ok,qs]=la(No),WF="SelectContentImpl",HF=zi("SelectContent.RemoveScroll"),jk=m.forwardRef((e,t)=>{const{__scopeSelect:n,position:r="item-aligned",onCloseAutoFocus:s,onEscapeKeyDown:o,onPointerDownOutside:i,side:a,sideOffset:l,align:c,alignOffset:u,arrowPadding:d,collisionBoundary:p,collisionPadding:h,sticky:x,hideWhenDetached:v,avoidCollisions:b,...w}=e,g=Vs(No,n),[y,_]=m.useState(null),[S,k]=m.useState(null),E=de(t,W=>_(W)),[R,P]=m.useState(null),[A,D]=m.useState(null),M=tf(n),[H,L]=m.useState(!1),Z=m.useRef(!1);m.useEffect(()=>{if(y)return H1(y)},[y]),M1();const B=m.useCallback(W=>{const[xe,...Me]=M().map(Se=>Se.ref.current),[_e]=Me.slice(-1),we=document.activeElement;for(const Se of W)if(Se===we||(Se==null||Se.scrollIntoView({block:"nearest"}),Se===xe&&S&&(S.scrollTop=0),Se===_e&&S&&(S.scrollTop=S.scrollHeight),Se==null||Se.focu
vendor: 13,742 bytes, line 241
241s(),document.activeElement!==we))return},[M,S]),I=m.useCallback(()=>B([R,y]),[B,R,y]);m.useEffect(()=>{H&&I()},[H,I]);const{onOpenChange:T,triggerPointerDownPosRef:N}=g;m.useEffect(()=>{if(y){let W={x:0,y:0};const xe=_e=>{var we,Se;W={x:Math.abs(Math.round(_e.pageX)-(((we=N.current)==null?void 0:we.x)??0)),y:Math.abs(Math.round(_e.pageY)-(((Se=N.current)==null?void 0:Se.y)??0))}},Me=_e=>{W.x<=10&&W.y<=10?_e.preventDefault():y.contains(_e.target)||T(!1),document.removeEventListener("pointermove",xe),N.current=null};return N.current!==null&&(document.addEventListener("pointermove",xe),document.addEventListener("pointerup",Me,{capture:!0,once:!0})),()=>{document.removeEventListener("pointermove",xe),document.removeEventListener("pointerup",Me,{capture:!0})}}},[y,T,N]),m.useEffect(()=>{const W=()=>T(!1);return window.addEventListener("blur",W),window.addEventListener("resize",W),()=>{window.removeEventListener("blur",W),window.removeEventListener("resize",W)}},[T]);const[z,V]=Zk(W=>{const xe=M().filter(we=>!we.disabled),Me=xe.find(we=>we.ref.current===document.activeElement),_e=Qk(xe,W,Me);_e&&setTimeout(()=>_e.ref.current.focus())}),X=m.useCallback((W,xe,Me)=>{const _e=!Z.current&&!Me;(g.value!==void 0&&g.value===xe||_e)&&(P(W),_e&&(Z.current=!0))},[g.value]),ee=m.useCallback(()=>y==null?void 0:y.focus(),[y]),ce=m.useCallback((W,xe,Me)=>{const _e=!Z.current&&!Me;(g.value!==void 0&&g.value===xe||_e)&&D(W)},[g.value]),le=r==="popper"?nm:Ik,Oe=le===nm?{side:a,sideOffset:l,align:c,alignOffset:u,arrowPadding:d,collisionBoundary:p,collisionPadding:h,sticky:x,hideWhenDetached:v,avoidCollisions:b}:{};return f.jsx(Ok,{scope:n,content:y,viewport:S,onViewportChange:k,itemRefCallback:X,selectedItem:R,onItemLeave:ee,itemTextRefCallback:ce,focusSelectedItem:I,selectedItemText:A,position:r,isPositioned:H,searchRef:z,children:f.jsx(qg,{as:HF,allowPinchZoom:!0,children:f.jsx(Vg,{asChild:!0,trapped:g.open,onMountAutoFocus:W=>{W.preventDefault()},onUnmountAutoFocus:K(s,W=>{var xe;(xe=g.trigger)==null||xe.focus({preventScroll:!0}),W.preventDefault()}),children:f.jsx(Ql,{asChild:!0,disableOutsidePointerEvents:!0,onEscapeKeyDown:o,onPointerDownOutside:i,onFocusOutside:W=>W.preventDefault(),onDismiss:()=>g.onOpenChange(!1),children:f.jsx(le,{role:"listbox",id:g.contentId,"data-state":g.open?"open":"closed",dir:g.dir,onContextMenu:W=>W.preventDefault(),...w,...Oe,onPlaced:()=>L(!0),ref:E,style:{display:"flex",flexDirection:"column",outline:"none",...w.style},onKeyDown:K(w.onKeyDown,W=>{const xe=W.ctrlKey||W.altKey||W.metaKey;if(W.key==="Tab"&&W.preventDefault(),!xe&&W.key.length===1&&V(W.key),["ArrowUp","ArrowDown","Home","End"].includes(W.key)){let _e=M().filter(we=>!we.disabled).map(we=>we.ref.current);if(["ArrowUp","End"].includes(W.key)&&(_e=_e.slice().reverse()),["ArrowUp","ArrowDown"].includes(W.key)){const we=W.target,Se=_e.indexOf(we);_e=_e.slice(Se+1)}setTimeout(()=>B(_e)),W.preventDefault()}})})})})})})});jk.displayName=WF;var VF="SelectItemAlignedPosition",Ik=m.forwardRef((e,t)=>{const{__scopeSelect:n,onPlaced:r,...s}=e,o=Vs(No,n),i=qs(No,n),[a,l]=m.useState(null),[c,u]=m.useState(null),d=de(t,E=>u(E)),p=tf(n),h=m.useRef(!1),x=m.useRef(!0),{viewport:v,selectedItem:b,selectedItemText:w,focusSelectedItem:g}=i,y=m.useCallback(()=>{if(o.trigger&&o.valueNode&&a&&c&&v&&b&&w){const E=o.trigger.getBoundingClientRect(),R=c.getBoundingClientRect(),P=o.valueNode.getBoundingClientRect(),A=w.getBoundingClientRect();if(o.dir!=="rtl"){const we=A.left-R.left,Se=P.left-we,ze=E.left-Se,ut=E.width+ze,kt=Math.max(ut,R.width),fn=window.innerWidth-Dn,Rn=Nl(Se,[Dn,Math.max(Dn,fn-kt)]);a.style.minWidth=ut+"px",a.style.left=Rn+"px"}else{const we=R.right-A.right,Se=window.innerWidth-P.right-we,ze=window.innerWidth-E.right-Se,ut=E.width+ze,kt=Math.max(ut,R.width),fn=window.innerWidth-Dn,Rn=Nl(Se,[Dn,Math.max(Dn,fn-kt)]);a.style.minWidth=ut+"px",a.style.right=Rn+"px"}const D=p(),M=window.innerHeight-Dn*2,H=v.scrollHeight,L=window.getComputedStyle(c),Z=parseInt(L.borderTopWidth,10),B=parseInt(L.paddingTop,10),I=parseInt(L.borderBottomWidth,10),T=parseInt(L.paddingBottom,10),N=Z+B+H+T+I,z=Math.min(b.offsetHeight*5,N),V=window.getComputedStyle(v),X=parseInt(V.paddingTop,10),ee=parseInt(V.paddingBottom,10),ce=E.top+E.height/2-Dn,le=M-ce,Oe=b.offsetHeight/2,W=b.offsetTop+Oe,xe=Z+B+W,Me=N-xe;if(xe<=ce){const we=D.length>0&&b===D[D.length-1].ref.current;a.style.bottom="0px";const Se=c.clientHeight-v.offsetTop-v.offsetHeight,ze=Math.max(le,Oe+(we?ee:0)+Se+I),ut=xe+ze;a.style.height=ut+"px"}else{const we=D.length>0&&b===D[0].ref.current;a.style.top="0px";const ze=Math.max(ce,Z+v.offsetTop+(we?X:0)+Oe)+Me;a.style.height=ze+"px",v.scrollTop=xe-ce+v.offsetTop}a.style.margin=`${Dn}px 0`,a.style.minHeight=z+"px",a.style.maxHeight=M+"px",r==null||r(),requestAnimationFrame(()=>h.current=!0)}},[p,o.trigger,o.valueNode,a,c,v,b,w,o.dir,r]);it(()=>y(),[y]);const[_,S]=m.useState();it(()=>{c&&S(window.getComputedStyle(c).zIndex)},[c]);const k=m.useCallback(E=>{E&&x.current===!0&&(y(),g==null||g(),x.current=!1)},[y,g]);return f.jsx(KF,{scope:n,contentWrapper:a,shouldExpandOnScrollRef:h,onScrollButtonChange:k,children:f.jsx("div",{ref:l,style:{display:"flex",flexDirection:"column",position:"fixed",zIndex:_},children:f.jsx(ne.div,{...s,ref:d,style:{boxSizing:"border-box",maxHeight:"100%",...s.style}})})})});Ik.displayName=VF;var qF="SelectPopperPosition",nm=m.forwardRef((e,t)=>{const{__scopeSelect:n,align:r="start",collisionPadding:s=Dn,...o}=e,i=nf(n);return f.jsx(US,{...i,...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)"}})});nm.displayName=qF;var[KF,wv]=la(No,{}),rm="SelectViewport",Dk=m.forwardRef((e,t)=>{const{__scopeSelect:n,nonce:r,...s}=e,o=qs(rm,n),i=wv(rm,n),a=de(t,o.onViewportChange),l=m.useRef(0);return f.jsxs(f.Fragment,{children:[f.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}),f.jsx(ef.Slot,{scope:n,children:f.jsx(ne.div,{"data-radix-select-viewport":"",role:"presentation",...s,ref:a,style:{position:"relative",flex:1,overflow:"hidden auto",...s.style},onScroll:K(s.onScroll,c=>{const u=c.currentTarget,{contentWrapper:d,shouldExpandOnScrollRef:p}=i;if(p!=null&&p.current&&d){const h=Math.abs(l.current-u.scrollTop);if(h>0){const x=window.innerHeight-Dn*2,v=parseFloat(d.style.minHeight),b=parseFloat(d.style.height),w=Math.max(v,b);if(w<x){const g=w+h,y=Math.min(x,g),_=g-y;d.style.height=y+"px",d.style.bottom==="0px"&&(u.scrollTop=_>0?_:0,d.style.justifyContent="flex-end")}}}l.current=u.scrollTop})})})]})});Dk.displayName=rm;var Mk="SelectGroup",[GF,YF]=la(Mk),ZF=m.forwardRef((e,t)=>{const{__scopeSelect:n,...r}=e,s=Ur();return f.jsx(GF,{scope:n,id:s,children:f.jsx(ne.div,{role:"group","aria-labelledby":s,...r,ref:t})})});ZF.displayName=Mk;var Lk="SelectLabel",$k=m.forwardRef((e,t)=>{const{__scopeSelect:n,...r}=e,s=YF(Lk,n);return f.jsx(ne.div,{id:s.id,...r,ref:t})});$k.displayName=Lk;var Xu="SelectItem",[QF,Fk]=la(Xu),Uk=m.forwardRef((e,t)=>{const{__scopeSelect:n,value:r,disabled:s=!1,textValue:o,...i}=e,a=Vs(Xu,n),l=qs(Xu,n),c=a.value===r,[u,d]=m.useState(o??""),[p,h]=m.useState(!1),x=de(t,g=>{var y;return(y=l.itemRefCallback)==null?void 0:y.call(l,g,r,s)}),v=Ur(),b=m.useRef("touch"),w=()=>{s||(a.onValueChange(r),a.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 f.jsx(QF,{scope:n,value:r,disabled:s,textId:v,isSelected:c,onItemTextChange:m.useCallback(g=>{d(y=>y||((g==null?void 0:g.textContent)??"").trim())},[]),children:f.jsx(ef.ItemSlot,{scope:n,value:r,disabled:s,textValue:u,children:f.jsx(ne.div,{role:"option","aria-labelledby":v,"data-highlighted":p?"":void 0,"aria-selected":c&&p,"data-state":c?"checked":"unchecked","aria-disabled":s||void 0,"data-disabled":s?"":void 0,tabIndex:s?void 0:-1,...i,ref:x,onFocus:K(i.onFocus,()=>h(!0)),onBlur:K(i.onBlur,()=>h(!1)),onClick:K(i.onClick,()=>{b.current!=="mouse"&&w()}),onPointerUp:K(i.onPointerUp,()=>{b.current==="mouse"&&w()}),onPointerDown:K(i.onPointerDown,g=>{b.current=g.pointerType}),onPointerMove:K(i.onPointerMove,g=>{var y;b.current=g.pointerType,s?(y=l.onItemLeave)==null||y.call(l):b.current==="mouse"&&g.currentTarget.focus({preventScroll:!0})}),onPointerLeave:K(i.onPointerLeave,g=>{var y;g.currentTarget===document.activeElement&&((y=l.onItemLeave)==null||y.call(l))}),onKeyDown:K(i.onKeyDown,g=>{var _;((_=l.searchRef)==null?void 0:_.current)!==""&&g.key===" "||(MF.includes(g.key)&&w(),g.key===" "&&g.preventDefault())})})})})});Uk.displayName=Xu;var qa="SelectItemText",Bk=m.forwardRef((e,t)=>{const{__scopeSelect:n,className:r,style:s,...o}=e,i=Vs(qa,n),a=qs(qa,n),l=Fk(qa,n),c=UF(qa,n),[u,d]=m.useState(null),p=de(t,w=>d(w),l.onItemTextChange,w=>{var g;return(g=a.itemTextRefCallback)==null?void 0:g.call(a,w,l.value,l.disabled)}),h=u==null?void 0:u.textContent,x=m.useMemo(()=>f.jsx("option",{value:l.value,disabled:l.disabled,children:h},l.value),[l.disabled,l.value,h]),{onNativeOptionAdd:v,onNativeOptionRemove:b}=c;return it(()=>(v(x),()=>b(x)),[v,b,x]),f.jsxs(f.Fragment,{children:[f.jsx(ne.span,{id:l.textId,...o,ref:p}),l.isSelected&&i.valueNode&&!i.valueNodeHasChildren?Io.createPortal(o.children,i.valueNode):null]})});Bk.displayName=qa;var zk="SelectItemIndicator",Wk=m.forwardRef((e,t)=>{const{__scopeSelect:n,...r}=e;return Fk(zk,n).isSelected?f.jsx(ne.span,{"aria-hidden":!0,...r,ref:t}):null});Wk.displayName=zk;var sm="SelectScrollUpButton",Hk=m.forwardRef((e,t)=>{const n=qs(sm,e.__scopeSelect),r=wv(sm,e.__scopeSelect),[s,o]=m.useState(!1),i=de(t,r.onScrollButtonChange);return it(()=>{if(n.viewport&&n.isPositioned){let a=function(){const c=l.scrollTop>0;o(c)};const l=n.viewport;return a(),l.addEventListener("scroll",a),()=>l.removeEventListener("scroll",a)}},[n.viewport,n.isPositioned]),s?f.jsx(qk,{...e,ref:i,onAutoScroll:()=>{const{viewport:a,selectedItem:l}=n;a&&l&&(a.scrollTop=a.scrollTop-l.offsetHeight)}}):null});Hk.displayName=sm;var om="SelectScrollDownButton",Vk=m.forwardRef((e,t)=>{const n=qs(om,e.__scopeSelect),r=wv(om,e.__scopeSelect),[s,o]=m.useState(!1),i=de(t,r.onScrollButtonChange);return it(()=>{if(n.viewport&&n.isPositioned){let a=function(){const c=l.scrollHeight-l.clientHeight,u=Math.ceil(l.scrollTop)<c;o(u)};const l=n.viewport;return a(),l.addEventListener("scroll",a),()=>l.removeEventListener("scroll",a)}},[n.viewport,n.isPositioned]),s?f.jsx(qk,{...e,ref:i,onAutoScroll:()=>{const{viewport:a,selectedItem:l}=n;a&&l&&(a.scrollTop=a.scrollTop+l.offsetHeight)}}):null});Vk.displayName=om;var qk=m.forwardRef((e,t)=>{const{__scopeSelect:n,onAutoScroll:r,...s}=e,o=qs("SelectScrollButton",n),i=m.useRef(null),a=tf(n),l=m.useCallback(()=>{i.current!==null&&(window.clearInterval(i.current),i.current=null)},[]);return m.useEffect(()=>()=>l(),[l]),it(()=>{var u;const c=a().find(d=>d.ref.current===document.activeElement);(u=c==null?void 0:c.ref.current)==null||u.scrollIntoView({block:"nearest"})},[a]),f.jsx(ne.div,{"aria-hidden":!0,...s,ref:t,style:{flexShrink:0,...s.style},onPointerDown:K(s.onPointerDown,()=>{i.current===null&&(i.current=window.setInterval(r,50))}),onPointerMove:K(s.onPointerMove,()=>{var c;(c=o.onItemLeave)==null||c.call(o),i.current===null&&(i.current=window.setInterval(r,50))}),onPointerLeave:K(s.onPointerLeave,()=>{l()})})}),JF="SelectSeparator",Kk=m.forwardRef((e,t)=>{const{__scopeSelect:n,...r}=e;return f.jsx(ne.div,{"aria-hidden":!0,...r,ref:t})});Kk.displayName=JF;var im="SelectArrow",XF=m.forwardRef((e,t)=>{const{__scopeSelect:n,...r}=e,s=nf(n),o=Vs(im,n),i=qs(im,n);return o.open&&i.position==="popper"?f.jsx(BS,{...s,...r,ref:t}):null});XF.displayName=im;var e3="SelectBubbleInput",Gk=m.forwardRef(({__scopeSelect:e,value:t,...n},r)=>{const s=m.useRef(null),o=de(r,s),i=Wd(t);return m.useEffect(()=>{const a=s.current;if(!a)return;const l=window.HTMLSelectElement.prototype,u=Object.getOwnPropertyDescriptor(l,"value").set;if(i!==t&&u){const d=new Event("change",{bubbles:!0});u.call(a,t),a.dispatchEvent(d)}},[i,t]),f.jsx(ne.select,{...n,style:{...$_,...n.style},ref:o,defaultValue:t})});Gk.displayName=e3;function Yk(e){return e===""||e===void 0}function Zk(e){const t=st(e),n=m.useRef(""),r=m.useRef(0),s=m.useCallback(i=>{const a=n.current+i;t(a),function l(c){n.current=c,window.clearTimeout(r.current),c!==""&&(r.current=window.setTimeout(()=>l(""),1e3))}(a)},[t]),o=m.useCallback(()=>{n.current="",window.clearTimeout(r.current)},[]);return m.useEffect(()=>()=>window.clearTimeout(r.current),[]),[n,s,o]}function Qk(e,t,n){const s=t.length>1&&Array.from(t).every(c=>c===t[0])?t[0]:t,o=n?e.indexOf(n):-1;let i=t3(e,Math.max(o,0));s.length===1&&(i=i.filter(c=>c!==n));const l=i.find(c=>c.textValue.toLowerCase().startsWith(s.toLowerCase()));return l!==n?l:void 0}function t3(e,t){return e.map((n,r)=>e[(t+r)%e.length])}var n3=Ek,Jk=Ck,r3=Rk,s3=Pk,o3=Nk,Xk=Ak,i3=Dk,eC=$k,tC=Uk,a3=Bk,l3=Wk,nC=Hk,rC=Vk,sC=Kk;const c3=n3,u3=r3,oC=m.forwardRef(({className:e,children:t,...n},r)=>f.jsxs(Jk,{ref:r,className:me("flex h-10 w-full items-center justify-between rounded-md border border-input bg-background px-3 py-2 text-sm r
241ing-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,f.jsx(s3,{asChild:!0,children:f.jsx(Pd,{className:"h-4 w-4 opacity-50"})})]}));oC.displayName=Jk.displayName;const iC=m.forwardRef(({className:e,...t},n)=>f.jsx(nC,{ref:n,className:me("flex cursor-default items-center justify-center py-1",e),...t,children:f.jsx(cA,{className:"h-4 w-4"})}));iC.displayName=nC.displayName;const aC=m.forwardRef(({className:e,...t},n)=>f.jsx(rC,{ref:n,className:me("flex cursor-default items-center justify-center py-1",e),...t,children:f.jsx(Pd,{className:"h-4 w-4"})}));aC.displayName=rC.displayName;const lC=m.forwardRef(({className:e,children:t,position:n="popper",...r},s)=>f.jsx(o3,{children:f.jsxs(Xk,{ref:s,className:me("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:[f.jsx(iC,{}),f.jsx(i3,{className:me("p-1",n==="popper"&&"h-[var(--radix-select-trigger-height)] w-full min-w-[var(--radix-select-trigger-width)]"),children:t}),f.jsx(aC,{})]})}));lC.displayName=Xk.displayName;const d3=m.forwardRef(({className:e,...t},n)=>f.jsx(eC,{ref:n,className:me("py-1.5 pl-8 pr-2 text-sm font-semibold",e),...t}));d3.displayName=eC.displayName;const cC=m.forwardRef(({className:e,children:t,...n},r)=>f.jsxs(tC,{ref:r,className:me("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:[f.jsx("span",{className:"absolute left-2 flex h-3.5 w-3.5 items-center justify-center",children:f.jsx(l3,{children:f.jsx(aS,{className:"h-4 w-4"})})}),f.jsx(a3,{children:t})]}));cC.displayName=tC.displayName;const f3=m.forwardRef(({className:e,...t},n)=>f.jsx(sC,{ref:n,className:me("-mx-1 my-1 h-px bg-muted",e),...t}));f3.displayName=sC.displayName;var yh="rovingFocusGroup.onEntryFocus",h3={bubbles:!1,cancelable:!0},sc="RovingFocusGroup",[am,uC,p3]=Zl(sc),[m3,dC]=Gt(sc,[p3]),[g3,v3]=m3(sc),fC=m.forwardRef((e,t)=>f.jsx(am.Provider,{scope:e.__scopeRovingFocusGroup,children:f.jsx(am.Slot,{scope:e.__scopeRovingFocusGroup,children:f.jsx(y3,{...e,ref:t})})}));fC.displayName=sc;var y3=m.forwardRef((e,t)=>{const{__scopeRovingFocusGroup:n,orientation:r,loop:s=!1,dir:o,currentTabStopId:i,defaultCurrentTabStopId:a,onCurrentTabStopIdChange:l,onEntryFocus:c,preventScrollOnEntryFocus:u=!1,...d}=e,p=m.useRef(null),h=de(t,p),x=oa(o),[v,b]=Gn({prop:i,defaultProp:a??null,onChange:l,caller:sc}),[w,g]=m.useState(!1),y=st(c),_=uC(n),S=m.useRef(!1),[k,E]=m.useState(0);return m.useEffect(()=>{const R=p.current;if(R)return R.addEventListener(yh,y),()=>R.removeEventListener(yh,y)},[y]),f.jsx(g3,{scope:n,orientation:r,dir:x,loop:s,currentTabStopId:v,onItemFocus:m.useCallback(R=>b(R),[b]),onItemShiftTab:m.useCallback(()=>g(!0),[]),onFocusableItemAdd:m.useCallback(()=>E(R=>R+1),[]),onFocusableItemRemove:m.useCallback(()=>E(R=>R-1),[]),children:f.jsx(ne.div,{tabIndex:w||k===0?-1:0,"data-orientation":r,...d,ref:h,style:{outline:"none",...e.style},onMouseDown:K(e.onMouseDown,()=>{S.current=!0}),onFocus:K(e.onFocus,R=>{const P=!S.current;if(R.target===R.currentTarget&&P&&!w){const A=new CustomEvent(yh,h3);if(R.currentTarget.dispatchEvent(A),!A.defaultPrevented){const D=_().filter(B=>B.focusable),M=D.find(B=>B.active),H=D.find(B=>B.id===v),Z=[M,H,...D].filter(Boolean).map(B=>B.ref.current);mC(Z,u)}}S.current=!1}),onBlur:K(e.onBlur,()=>g(!1))})})}),hC="RovingFocusGroupItem",pC=m.forwardRef((e,t)=>
vendor: 4,208 bytes, line 241
241{const{__scopeRovingFocusGroup:n,focusable:r=!0,active:s=!1,tabStopId:o,children:i,...a}=e,l=Ur(),c=o||l,u=v3(hC,n),d=u.currentTabStopId===c,p=uC(n),{onFocusableItemAdd:h,onFocusableItemRemove:x,currentTabStopId:v}=u;return m.useEffect(()=>{if(r)return h(),()=>x()},[r,h,x]),f.jsx(am.ItemSlot,{scope:n,id:c,focusable:r,active:s,children:f.jsx(ne.span,{tabIndex:d?0:-1,"data-orientation":u.orientation,...a,ref:t,onMouseDown:K(e.onMouseDown,b=>{r?u.onItemFocus(c):b.preventDefault()}),onFocus:K(e.onFocus,()=>u.onItemFocus(c)),onKeyDown:K(e.onKeyDown,b=>{if(b.key==="Tab"&&b.shiftKey){u.onItemShiftTab();return}if(b.target!==b.currentTarget)return;const w=x3(b,u.orientation,u.dir);if(w!==void 0){if(b.metaKey||b.ctrlKey||b.altKey||b.shiftKey)return;b.preventDefault();let y=p().filter(_=>_.focusable).map(_=>_.ref.current);if(w==="last")y.reverse();else if(w==="prev"||w==="next"){w==="prev"&&y.reverse();const _=y.indexOf(b.currentTarget);y=u.loop?_3(y,_+1):y.slice(_+1)}setTimeout(()=>mC(y))}}),children:typeof i=="function"?i({isCurrentTabStop:d,hasTabStop:v!=null}):i})})});pC.displayName=hC;var w3={ArrowLeft:"prev",ArrowUp:"prev",ArrowRight:"next",ArrowDown:"next",PageUp:"first",Home:"first",PageDown:"last",End:"last"};function b3(e,t){return t!=="rtl"?e:e==="ArrowLeft"?"ArrowRight":e==="ArrowRight"?"ArrowLeft":e}function x3(e,t,n){const r=b3(e.key,n);if(!(t==="vertical"&&["ArrowLeft","ArrowRight"].includes(r))&&!(t==="horizontal"&&["ArrowUp","ArrowDown"].includes(r)))return w3[r]}function mC(e,t=!1){const n=document.activeElement;for(const r of e)if(r===n||(r.focus({preventScroll:t}),document.activeElement!==n))return}function _3(e,t){return e.map((n,r)=>e[(t+r)%e.length])}var S3=fC,E3=pC,bv="Radio",[k3,gC]=Gt(bv),[C3,T3]=k3(bv),vC=m.forwardRef((e,t)=>{const{__scopeRadio:n,name:r,checked:s=!1,required:o,disabled:i,value:a="on",onCheck:l,form:c,...u}=e,[d,p]=m.useState(null),h=de(t,b=>p(b)),x=m.useRef(!1),v=d?c||!!d.closest("form"):!0;return f.jsxs(C3,{scope:n,checked:s,disabled:i,children:[f.jsx(ne.button,{type:"button",role:"radio","aria-checked":s,"data-state":xC(s),"data-disabled":i?"":void 0,disabled:i,value:a,...u,ref:h,onClick:K(e.onClick,b=>{s||l==null||l(),v&&(x.current=b.isPropagationStopped(),x.current||b.stopPropagation())})}),v&&f.jsx(bC,{control:d,bubbles:!x.current,name:r,value:a,checked:s,required:o,disabled:i,form:c,style:{transform:"translateX(-100%)"}})]})});vC.displayName=bv;var yC="RadioIndicator",wC=m.forwardRef((e,t)=>{const{__scopeRadio:n,forceMount:r,...s}=e,o=T3(yC,n);return f.jsx(dn,{present:r||o.checked,children:f.jsx(ne.span,{"data-state":xC(o.checked),"data-disabled":o.disabled?"":void 0,...s,ref:t})})});wC.displayName=yC;var R3="RadioBubbleInput",bC=m.forwardRef(({__scopeRadio:e,control:t,checked:n,bubbles:r=!0,...s},o)=>{const i=m.useRef(null),a=de(i,o),l=Wd(n),c=Md(t);return m.useEffect(()=>{const u=i.current;if(!u)return;const d=window.HTMLInputElement.prototype,h=Object.getOwnPropertyDescriptor(d,"checked").set;if(l!==n&&h){const x=new Event("click",{bubbles:r});h.call(u,n),u.dispatchEvent(x)}},[l,n,r]),f.jsx(ne.input,{type:"radio","aria-hidden":!0,defaultChecked:n,...s,tabIndex:-1,ref:a,style:{...s.style,...c,position:"absolute",pointerEvents:"none",opacity:0,margin:0}})});bC.displayName=R3;function xC(e){return e?"checked":"unchecked"}var P3=["ArrowUp","ArrowDown","ArrowLeft","ArrowRight"],rf="RadioGroup",[N3,Mz]=Gt(rf,[dC,gC]),_C=dC(),SC=gC(),[A3,O3]=N3(rf),EC=m.forwardRef((e,t)=>{const{__scopeRadioGroup:n,name:r,defaultValue:s,value:o,required:i=!1,disabled:a=!1,orientation:l,dir:c,loop:u=!0,onValueChange:d,...p}=e,h=_C(n),x=oa(c),[v,b]=Gn({prop:o,defaultProp:s??null,onChange:d,caller:rf});return f.jsx(A3,{scope:n,name:r,required:i,disabled:a,value:v,onValueChange:b,children:f.jsx(S3,{asChild:!0,...h,orientation:l,dir:x,loop:u,children:f.jsx(ne.div,{role:"radiogroup","aria-required":i,"aria-orientation":l,"data-disabled":a?"":void 0,dir:x,...p,ref:t})})})});EC.displayName=rf;var kC="RadioGroupItem",CC=m.forwardRef((e,t)=>{const{__scopeRadioGroup:n,disabled:r,...s}=e,o=O3(kC,n),i=o.disabled||r,a=_C(n),l=SC(n),c=m.useRef(null),u=de(t,c),d=o.value===s.value,p=m.useRef(!1);return m.useEffect(()=>{const h=v=>
241{P3.includes(v.key)&&(p.current=!0)},x=()=>p.current=!1;return document.addEventListener("keydown",h),document.addEventListener("keyup",x),()=>{document.removeEventListener("keydown",h),document.removeEventListener("keyup",x)}},[]),f.jsx(E3,{asChild:!0,...a,focusable:!i,active:d,children:f.jsx(vC,{disabled:i,required:o.required,checked:d,...l,...s,name:o.name,ref:u,onCheck:()=>o.onValueChange(s.value),onKeyDown:K(h=>{h.key==="Enter"&&h.preventDefault()}),onFocus:K(s.onFocus,()=>{var h;p.current&&((h=c.current)==null||h.click())})})})});CC.displayName=kC;var j3="RadioGroupIndicator",TC=m.forwardRef((e,t)=>{const{__scopeRadioGroup:n,...r}=e,s=SC(n);return f.jsx(wC,{...s,...r,ref:t})});TC.displayName=j3;var RC=EC,PC=CC,I3=TC;const hu=m.forwardRef(({className:e,...t},n)=>f.jsx(RC,{className:me("grid gap-2",e),...t,ref:n}));hu.displayName=RC.displayName;const Ar=m.forwardRef(({className:e,...t},n)=>f.jsx(PC,{ref:n,className:me("aspect-square h-4 w-4 rounded-full border border-primary text-primary ring-offset-background focus:outline-none focus-visible:ring-2 focus-visible:ring-ring focus-visible:ring-offset-2 disabled:cursor-not-allowed disabled:opacity-50",e),...t,children:f.jsx(I3,{className:"flex items-center justify-center",children:f.jsx(uA,{className:"h-2.5 w-2.5 fill-current text-current"})})}));Ar.displayName=PC.displayName;var D3="Label",NC=m.forwardRef((e,t)=>f.jsx(ne.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())}}));NC.displayName=D3;var AC=NC;const M3=Eg("text-sm font-medium leading-none peer-disabled:cursor-not-allowed peer-disabled:opacity-70"),Or=m.forwardRef(({className:e,...t},n)=>f.jsx(AC,{ref:n,className:me(M3(),e),...t}));Or.displayName=AC.displayName;const L3=e=>e?(...t)=>e(...t):(...t)=>fetch(...t);class xv extends Error{constructor(t,n="FunctionsError",r){super(t),this.name=n,this.context=r}}class $3 extends xv{constructor(t){super("Failed to send a request to the Edge Function","FunctionsFetchError",t)}}class h0 extends xv{constructor(t){super("Relay Error invoking the Edge Function","FunctionsRelayError",t)}}class p0 extends xv{constructor(t){super("Edge Function returned a non-2xx status code","FunctionsHttpError",t)}}var lm;(function(e){e.Any="any",e.ApNortheast1="ap-northeast-1",e.ApNortheast2="ap-northeast-2",e.ApSouth1="ap-south-1",e.ApSoutheast1="ap-southeast-1",e.ApSoutheast2="ap-southeast-2",e.CaCentral1="ca-central-1",e.EuCentral1="eu-central-1",e.EuWest1="eu-west-1",e.EuWest2="eu-west-2",e.EuWest3="eu-west-3",e.SaEast1="sa-east-1",e.UsEast1="us-east-1",e.UsWest1="us-west-1",e.UsWest2="us-west-2"})(lm||(lm={}));class F3{constructor(t,{headers:n={},customFetch:r,region:s=lm.Any}={}){this.url=t,this.headers=n,this.region=s,this.fetch=L3(r)}setAuth(t){this.headers.Authorization=`Bearer ${t}`}invoke(t){return x2(this,arguments,void 0,function*(n,r={}){var s;let o,i;try{const{headers:a,method:l,body:c,signal:u,timeout:d}=r;let p={},{region:h}=r;h||(h=this.region);const x=new URL(`${this.url}/${n}`);h&&h!=="any"&&(p["x-region"]=h,x.searchParams.set("forceFunctionRegion",h));let v;c&&(a&&!Object.prototype.hasOwnProperty.call(a,"Content-Type")||!a)?typeof Blob<"u"&&c instanceof Blob||c instanceof ArrayBuffer?(p["Content-Type"]="application/octet-stream",v=c):typeof c=="string"?(p["Content-Type"]="text/plain",v=c):typeof FormData<"u"&&c instanceof FormData?v=c:(p["Content-Type"]="application/json",v=JSON.stringify(c)):c&&typeof c!="string"&&!(typeof Blob<"u"&&c instanceof Blob)&&!(c instanceof ArrayBuffer)&&!(typeof FormData<"u"&&c instanceof FormData)?v=JSON.stringify(c):v=c;let b=u;d&&(i=new AbortController,o=setTimeout(()=>i.abort(),d),u?(b=i.signal,u.addEventListener("abort",()=>i.abort())):b=i.signal);const w=yield this.fetch(x.toString(),{method:l||"POST",headers:Object.assign(Object.assign(Object.assign({},p),this.headers),a),body:v,signal:b}).catch(S=>{throw new $3(S)}),g=w.headers.get("x-relay-error");if(g&&g==="true")throw new h0(w);if(!w.ok)throw new p0(w);let y=((s=w.headers.get("Content-Type"))!==null&&s!==void 0?s:"text/plain").split(";")[0].trim(),_;return y==="application/json"?_=yield w.json():y==="application/octet-stream"||y==="application/pdf"?_=yield w.blob():y==="text/event-stream"?_=w:y==="multipart/form-data"?_=yield w.formData():_=yield w.text(),{data:_,error:null,response:w}}catch(a){return{data:null,error:a,response:a instanceof p0||a instanceof h0?a.context:void 0}}finally{o&&clearTimeout(o)}})}}
241var U3=class extends Error{constructor(e){super(e.message),this.name="PostgrestError",this.details=e.details,this.hint=e.hint,this.code=e.code}},B3=class{constructor(e){var t,n,r;this.shouldThrowOnError=!1,this.method=e.method,this.url=e.url,this.headers=new Headers(e.headers),this.schema=e.schema,this.body=e.body,this.shouldThrowOnError=(t=e.shouldThrowOnError)!==null&&t!==void 0?t:!1,this.signal=e.signal,this.isMaybeSingle=(n=e.isMaybeSingle)!==null&&n!==void 0?n:!1,this.urlLengthLimit=(r=e.urlLengthLimit)!==null&&r!==void 0?r:8e3,e.fetch?this.fetch=e.fetch:this.fetch=fetch}throwOnError(){return this.shouldThrowOnError=!0,this}setHeader(e,t){return this.headers=new Headers(this.headers),this.headers.set(e,t),this}then(e,t){var n=this;this.schema===void 0||(["GET","HEAD"].includes(this.method)?this.headers.set("Accept-Profile",this.schema):this.headers.set("Content-Profile",this.schema)),this.method!=="GET"&&this.method!=="HEAD"&&this.headers.set("Content-Type","application/json");const r=this.fetch;let s=r(this.url.toString(),{method:this.method,headers:this.headers,body:JSON.stringify(this.body),signal:this.signal}).then(async o=>{let i=null,a=null,l=null,c=o.status,u=o.statusText;if(o.ok){var d,p;if(n.method!=="HEAD"){var h;const w=await o.text();w===""||(n.headers.get("Accept")==="text/csv"||n.headers.get("Accept")&&(!((h=n.headers.get("Accept"))===null||h===void 0)&&h.includes("application/vnd.pgrst.plan+text"))?a=w:a=JSON.parse(w))}const v=(d=n.headers.get("Prefer"))===null||d===void 0?void 0:d.match(/count=(exact|planned|estimated)/),b=(p=o.headers.get("content-range"))===null||p===void 0?void 0:p.split("/");v&&b&&b.length>1&&(l=parseInt(b[1])),n.isMaybeSingle&&n.method==="GET"&&Array.isArray(a)&&(a.length>1?(i={code:"PGRST116",details:`Results contain ${a.length} rows, application/vnd.pgrst.object+json requires 1 row`,hint:null,message:"JSON object requested, multiple (or no) rows returned"},a=null,l=null,c=406,u="Not Acceptable"):a.length===1?a=a[0]:a=null)}else{var x;const v=await o.text();try{i=JSON.parse(v),Array.isArray(i)&&o.status===404&&(a=[],i=null,c=200,u="OK")}catch{o.status===404&&v===""?(c=204,u="No Content"):i={message:v}}if(i&&n.isMaybeSingle&&(!(i==null||(x=i.details)===null||x===void 0)&&x.includes("0 rows"))&&(i=null,c=200,u="OK"),i&&n.shouldThrowOnError)throw new U3(i)}return{error:i,data:a,count:l,status:c,statusText:u}});return this.shouldThrowOnError||(s=s.catch(o=>{var i;let a="",l="",c="";const u=o==null?void 0:o.cause;if(u){var d,p,h,x;const w=(d=u==null?void 0:u.message)!==null&&d!==void 0?d:"",g=(p=u==null?void 0:u.code)!==null&&p!==void 0?p:"";a=`${(h=o==null?void 0:o.name)!==null&&h!==void 0?h:"FetchError"}: ${o==null?void 0:o.message}`,a+=` 242 243Caused by: ${(x=u==null?void 0:u.name)!==null&&x!==void 0?x:"Error"}: ${w}`,g&&(a+=` (${g})`),u!=null&&u.stack&&(a+=` 244${u.stack}`)}else{var v;a=(v=o==null?void 0:o.stack)!==null&&v!==void 0?v:""}const b=this.url.toString().length;return(o==null?void 0:o.name)==="AbortError"||(o==null?void 0:o.code)==="ABORT_ERR"?(c="",l="Request was aborted (timeout or manual cancellation)",b>this.urlLengthLimit&&(l+=`. Note: Your request URL is ${b} characters, which may exceed server limits. If selecting many fields, consider using views. If filtering with large arrays (e.g., .in('id', [many IDs])), consider using an RPC function to pass values server-side.`)):((u==null?void 0:u.name)==="HeadersOverflowError"||(u==null?void 0:u.code)==="UND_ERR_HEADERS_OVERFLOW")&&(c="",l="HTTP headers exceeded server limits (typically 16KB)",b>this.urlLengthLimit&&(l+=`. Your request URL is ${b} characters. If selecting many fields, consider using views. If filtering with large arrays (e.g., .in('id', [200+ IDs])), consider using an RPC function instead.`)),{error:{message:`${(i=o==null?void 0:o.name)!==null&&i!==void 0?i:"FetchError"}: ${o==null?void 0:o.message}`,details:a,hint:l,code:c},data:null,count:null,status:0,statusText:""}})),s.then(e,t)}returns(){return this}overrideTypes(){return this}},z3=class extends B3{select(e){let t=!1;const n=(e??"*").split("").map(r=>/\s/.test(r)&&!t?"":(r==='"'&&(t=!t),r)).join("");return this.url.searchParams.set("select",n),this.headers.append("Prefer","return=representation"),this}order(e,{ascending:t=!0,nullsFirst:n,foreignTable:r,referencedTable:s=r}={}){const o=s?`${s}.order`:"order",i=this.url.searchParams.get(o);return this.url.searchParams.set(o,`${i?`${i},`:""}${e}.${t?"asc":"desc"}${n===void 0?"":n?".nullsfirst":".nullslast"}`),this}limit(e,{foreignTable:t,referencedTable:n=t}={}){const r=typeof n>"u"?"limit":`${n}.limit`;return this.url.searchParams.set(r,`${e}`),this}range(e,t,{foreignTable:n,referencedTable:r=n}={}){const s=typeof r>"u"?"offset":`${r}.offset`,o=typeof r>"u"?"limit":`${r}.limit`;return this.url.searchParams.set(s,`${e}`),this.url.searchParams.set(o,`${t-e+1}`),this}abortSignal(e){return this.signal=e,this}single(){return this.headers.set("Accept","application/vnd.pgrst.object+json"),this}maybeSingle(){return this.method==="GET"?this.headers.set("Accept","application/json"):this.headers.set("Accept","application/vnd.pgrst.object+json"),this.isMaybeSingle=!0,this}csv(){return this.headers.set("Accept","text/csv"),this}geojson(){return this.headers.set("Accept","application/geo+json"),this}
244explain({analyze:e=!1,verbose:t=!1,settings:n=!1,buffers:r=!1,wal:s=!1,format:o="text"}={}){var i;const a=[e?"analyze":null,t?"verbose":null,n?"settings":null,r?"buffers":null,s?"wal":null].filter(Boolean).join("|"),l=(i=this.headers.get("Accept"))!==null&&i!==void 0?i:"application/json";return this.headers.set("Accept",`application/vnd.pgrst.plan+${o}; for="${l}"; options=${a};`),o==="json"?this:this}rollback(){return this.headers.append("Prefer","tx=rollback"),this}returns(){return this}maxAffected(e){return this.headers.append("Prefer","handling=strict"),this.headers.append("Prefer",`max-affected=${e}`),this}};const m0=new RegExp("[,()]");var Jo=class extends z3{eq(e,t){return this.url.searchParams.append(e,`eq.${t}`),this}neq(e,t){return this.url.searchParams.append(e,`neq.${t}`),this}gt(e,t){return this.url.searchParams.append(e,`gt.${t}`),this}gte(e,t){return this.url.searchParams.append(e,`gte.${t}`),this}lt(e,t){return this.url.searchParams.append(e,`lt.${t}`),this}lte(e,t){return this.url.searchParams.append(e,`lte.${t}`),this}like(e,t){return this.url.searchParams.append(e,`like.${t}`),this}likeAllOf(e,t){return this.url.searchParams.append(e,`like(all).{${t.join(",")}}`),this}likeAnyOf(e,t){return this.url.searchParams.append(e,`like(any).{${t.join(",")}}`),this}ilike(e,t){return this.url.searchParams.append(e,`ilike.${t}`),this}ilikeAllOf(e,t){return this.url.searchParams.append(e,`ilike(all).{${t.join(",")}}`),this}ilikeAnyOf(e,t){return this.url.searchParams.append(e,`ilike(any).{${t.join(",")}}`),this}regexMatch(e,t){return this.url.searchParams.append(e,`match.${t}`),this}regexIMatch(e,t){return this.url.searchParams.append(e,`imatch.${t}`),this}is(e,t){return this.url.searchParams.append(e,`is.${t}`),this}isDistinct(e,t){return this.url.searchParams.append(e,`isdistinct.${t}`),this}in(e,t){const n=Array.from(new Set(t)).map(r=>typeof r=="string"&&m0.test(r)?`"${r}"`:`${r}`).join(",");return this.url.searchParams.append(e,`in.(${n})`),this}notIn(e,t){const n=Array.from(new Set(t)).map(r=>typeof r=="string"&&m0.test(r)?`"${r}"`:`${r}`).join(",");return this.url.searchParams.append(e,`not.in.(${n})`),this}contains(e,t){return typeof t=="string"?this.url.searchParams.append(e,`cs.${t}`):Array.isArray(t)?this.url.searchParams.append(e,`cs.{${t.join(",")}}`):this.url.searchParams.append(e,`cs.${JSON.stringify(t)}`),this}containedBy(e,t){return typeof t=="string"?this.url.searchParams.append(e,`cd.${t}`):Array.isArray(t)?this.url.searchParams.append(e,`cd.{${t.join(",")}}`):this.url.searchParams.append(e,`cd.${JSON.stringify(t)}`),this}rangeGt(e,t){return this.url.searchParams.append(e,`sr.${t}`),this}rangeGte(e,t){return this.url.searchParams.append(e,`nxl.${t}`),this}rangeLt(e,t){return this.url.searchParams.append(e,`sl.${t}`),this}rangeLte(e,t){return this.url.searchParams.append(e,`nxr.${t}`),this}rangeAdjacent(e,t){return this.url.searchParams.append(e,`adj.${t}`),this}overlaps(e,t){return typeof t=="string"?this.url.searchParams.append(e,`ov.${t}`):this.url.searchParams.append(e,`ov.{${t.join(",")}}`),this}textSearch(e,t,{config:n,type:r}={}){let s="";r==="plain"?s="pl":r==="phrase"?s="ph":r==="websearch"&&(s="w");const o=n===void 0?"":`(${n})`;return this.url.searchParams.append(e,`${s}fts${o}.${t}`),this}match(e){return Object.entries(e).forEach(([t,n])=>{this.url.searchParams.append(t,`eq.${n}`)}),this}not(e,t,n){return this.url.searchParams.append(e,`not.${t}.${n}`),this}or(e,{foreignTable:t,referencedTable:n=t}={}){const r=n?`${n}.or`:"or";return this.url.searchParams.append(r,`(${e})`),this}filter(e,t,n){return this.url.searchParams.append(e,`${t}.${n}`),this}},W3=class{constructor(e,{headers:t={},schema:n,fetch:r,urlLengthLimit:s=8e3}){this.url=e,this.headers=new Headers(t),this.schema=n,this.fetch=r,this.urlLengthLimit=s}cloneRequestState(){return{url:new URL(this.url.toString()),headers:new Headers(this.headers)}}select(e,t){const{head:n=!1,count:r}=t??{},s=n?"HEAD":"GET";let o=!1;const i=(e??"*").split("").map(c=>/\s/.test(c)&&!o?"":(c==='"'&&(o=!o),c)).join(""),{url:a,headers:l}=this.cloneRequestState();return a.searchParams.set("select",i),r&&l.append("Prefer",`count=${r}`),new Jo({method:s,url:a,headers:l,schema:this.schema,fetch:this.fetch,urlLengthLimit:this.urlLengthLimit})}insert(e,{count:t,defaultToNull:n=!0}={}){var r;const s="POST",{url:o,headers:i}=this.cloneRequestState();if(t&&i.append("Prefer",`count=${t}`),n||i.append("Prefer","missing=default"),Array.isArray(e)){const a=e.reduce((l,c)=>l.concat(Object.keys(c)),[]);if(a.length>
2440){const l=[...new Set(a)].map(c=>`"${c}"`);o.searchParams.set("columns",l.join(","))}}return new Jo({method:s,url:o,headers:i,schema:this.schema,body:e,fetch:(r=this.fetch)!==null&&r!==void 0?r:fetch,urlLengthLimit:this.urlLengthLimit})}upsert(e,{onConflict:t,ignoreDuplicates:n=!1,count:r,defaultToNull:s=!0}={}){var o;const i="POST",{url:a,headers:l}=this.cloneRequestState();if(l.append("Prefer",`resolution=${n?"ignore":"merge"}-duplicates`),t!==void 0&&a.searchParams.set("on_conflict",t),r&&l.append("Prefer",`count=${r}`),s||l.append("Prefer","missing=default"),Array.isArray(e)){const c=e.reduce((u,d)=>u.concat(Object.keys(d)),[]);if(c.length>0){const u=[...new Set(c)].map(d=>`"${d}"`);a.searchParams.set("columns",u.join(","))}}return new Jo({method:i,url:a,headers:l,schema:this.schema,body:e,fetch:(o=this.fetch)!==null&&o!==void 0?o:fetch,urlLengthLimit:this.urlLengthLimit})}update(e,{count:t}={}){var n;const r="PATCH",{url:s,headers:o}=this.cloneRequestState();return t&&o.append("Prefer",`count=${t}`),new Jo({method:r,url:s,headers:o,schema:this.schema,body:e,fetch:(n=this.fetch)!==null&&n!==void 0?n:fetch,urlLengthLimit:this.urlLengthLimit})}delete({count:e}={}){var t;const n="DELETE",{url:r,headers:s}=this.cloneRequestState();return e&&s.append("Prefer",`count=${e}`),new Jo({method:n,url:r,headers:s,schema:this.schema,fetch:(t=this.fetch)!==null&&t!==void 0?t:fetch,urlLengthLimit:this.urlLengthLimit})}};function Ol(e){"@babel/helpers - typeof";return Ol=typeof Symbol=="function"&&typeof Symbol.iterator=="symbol"?function(t){return typeof t}:function(t){return t&&typeof Symbol=="function"&&t.constructor===Symbol&&t!==Symbol.prototype?"symbol":typeof t},Ol(e)}function H3(e,t){if(Ol(e)!="object"||!e)return e;var n=e[Symbol.toPrimitive];if(n!==void 0){var r=n.call(e,t||"default");if(Ol(r)!="object")return r;throw new TypeError("@@toPrimitive must return a primitive value.")}return(t==="string"?String:Number)(e)}function V3(e){var t=H3(e,"string");return Ol(t)=="symbol"?t:t+""}function q3(e,t,n){return(t=V3(t))in e?Object.defineProperty(e,t,{value:n,enumerable:!0,configurable:!0,writable:!0}):e[t]=n,e}function g0(e,t){var n=Object.keys(e);if(Object.getOwnPropertySymbols){var r=Object.getOwnPropertySymbols(e);t&&(r=r.filter(function(s){return Object.getOwnPropertyDescriptor(e,s).enumerable})),n.push.apply(n,r)}return n}function $c(e){for(var t=1;t<arguments.length;t++){var n=arguments[t]!=null?arguments[t]:{};t%2?g0(Object(n),!0).forEach(function(r){q3(e,r,n[r])}):Object.getOwnPropertyDescriptors?Object.defineProperties(e,Object.getOwnPropertyDescriptors(n)):g0(Object(n)).forEach(function(r){Object.defineProperty(e,r,Object.getOwnPropertyDescriptor(n,r))})}return e}var K3=class OC{constructor(t,{headers:n={},schema:r,fetch:s,timeout:o,urlLengthLimit:i=8e3}={}){this.url=t,this.headers=new Headers(n),this.schemaName=r,this.urlLengthLimit=i;const a=s??globalThis.fetch;o!==void 0&&o>0?this.fetch=(l,c)=>{const u=new AbortController,d=setTimeout(()=>u.abort(),o),p=c==null?void 0:c.signal;if(p){if(p.aborted)return clearTimeout(d),a(l,c);const h=()=>{clearTimeout(d),u.abort()};return p.addEventListener("abort",h,{once:!0}),a(l,$c($c({},c),{},{signal:u.signal})).finally(()=>{clearTimeout(d),p.removeEventListener("abort",h)})}return a(l,$c($c({},c),{},{signal:u.signal})).finally(()=>clearTimeout(d))}:this.fetch=a}from(t){if(!t||typeof t!="string"||t.trim()==="")throw new Error("Invalid relation name: relation must be a non-empty string.");return new W3(new URL(`${this.url}/${t}`),{headers:new Headers(this.headers),schema:this.schemaName,fetch:this.fetch,urlLengthLimit:this.urlLengthLimit})}schema(t){return new OC(this.url,{headers:this.headers,schema:t,fetch:this.fetch,urlLengthLimit:this.urlLengthLimit})}rpc(t,n={},{head:r=!1,get:s=!1,count:o}={}){var i;let a;const l=new URL(`${this.url}/rpc/${t}`);let c;const u=h=>h!==null&&typeof h=="object"&&(!Array.isArray(h)||h.some(u)),d=r&&Object.values(n).some(u);d?(a="POST",c=n):r||s?(a=r?"HEAD":"GET",Object.entries(n).filter(([h,x])=>x!==void 0).map(([h,x])=>[h,Array.isArray(x)?`{${x.join(",")}}`:`${x}
244`]).forEach(([h,x])=>{l.searchParams.append(h,x)})):(a="POST",c=n);const p=new Headers(this.headers);return d?p.set("Prefer",o?`count=${o},return=minimal`:"return=minimal"):o&&p.set("Prefer",`count=${o}`),new Jo({method:a,url:l,headers:p,schema:this.schemaName,body:c,fetch:(i=this.fetch)!==null&&i!==void 0?i:fetch,urlLengthLimit:this.urlLengthLimit})}};class G3{constructor(){}static detectEnvironment(){var t;if(typeof WebSocket<"u")return{type:"native",constructor:WebSocket};if(typeof globalThis<"u"&&typeof globalThis.WebSocket<"u")return{type:"native",constructor:globalThis.WebSocket};if(typeof global<"u"&&typeof global.WebSocket<"u")return{type:"native",constructor:global.WebSocket};if(typeof globalThis<"u"&&typeof globalThis.WebSocketPair<"u"&&typeof globalThis.WebSocket>"u")return{type:"cloudflare",error:"Cloudflare Workers detected. WebSocket clients are not supported in Cloudflare Workers.",workaround:"Use Cloudflare Workers WebSocket API for server-side WebSocket handling, or deploy to a different runtime."};if(typeof globalThis<"u"&&globalThis.EdgeRuntime||typeof navigator<"u"&&(!((t=navigator.userAgent)===null||t===void 0)&&t.includes("Vercel-Edge")))return{type:"unsupported",error:"Edge runtime detected (Vercel Edge/Netlify Edge). WebSockets are not supported in edge functions.",workaround:"Use serverless functions or a different deployment target for WebSocket functionality."};const n=globalThis.process;if(n){const r=n.versions;if(r&&r.node){const s=r.node,o=parseInt(s.replace(/^v/,"").split(".")[0]);return o>=22?typeof globalThis.WebSocket<"u"?{type:"native",constructor:globalThis.WebSocket}:{type:"unsupported",error:`Node.js ${o} detected but native WebSocket not found.`,workaround:"Provide a WebSocket implementation via the transport option."}:{type:"unsupported",error:`Node.js ${o} detected without native WebSocket support.`,workaround:`For Node.js < 22, install "ws" package and provide it via the transport option: 245import ws from "ws" 246new RealtimeClient(url, { transport: ws })`}}}return{type:"unsupported",error:"Unknown JavaScript runtime without WebSocket support.",workaround:"Ensure you're running in a supported environment (browser, Node.js, Deno) or provide a custom WebSocket implementation."}}static getWebSocketConstructor(){const t=this.detectEnvironment();if(t.constructor)return t.constructor;let n=t.error||"WebSocket not supported in this environment.";throw t.workaround&&(n+=` 247 248Suggested solution: ${t.workaround}`),new Error(n)}static createWebSocket(t,n){const r=this.getWebSocketConstructor();return new r(t,n)}static isWebSocketSupported(){try{const t=this.detectEnvironment();return t.type==="native"||t.type==="ws"}catch{return!1}}}const Y3="2.95.2",Z3=`realtime-js/${Y3}`,Q3="1.0.0",jC="2.0.0",v0=jC,cm=1e4,J3=1e3,X3=100;var as;(function(e){e[e.connecting=0]="connecting",e[e.open=1]="open",e[e.closing=2]="closing",e[e.closed=3]="closed"})(as||(as={}));var nt;(function(e){e.closed="closed",e.errored="errored",e.joined="joined",e.joining="joining",e.leaving="leaving"})(nt||(nt={}));var zn;(function(e){e.close="phx_close",e.error="phx_error",e.join="phx_join",e.reply="phx_reply",e.leave="phx_leave",e.access_token="access_token"})(zn||(zn={}));var um;(function(e){e.websocket="websocket"})(um||(um={}));var oo;(function(e){e.Connecting="connecting",e.Open="open",e.Closing="closing",e.Closed="closed"})(oo||(oo={}));class e5{constructor(t){this.HEADER_LENGTH=1,this.USER_BROADCAST_PUSH_META_LENGTH=6,this.KINDS={userBroadcastPush:3,userBroadcast:4},this.BINARY_ENCODING=0,this.JSON_ENCODING=1,this.BROADCAST_EVENT="broadcast",this.allowedMetadataKeys=[],this.allowedMetadataKeys=t??[]}encode(t,n){if(t.event===this.BROADCAST_EVENT&&!(t.payload instanceof ArrayBuffer)&&typeof t.payload.event=="string")return n(this._binaryEncodeUserBroadcastPush(t));let r=[t.join_ref,t.ref,t.topic,t.event,t.payload];return n(JSON.stringify(r))}_binaryEncodeUserBroadcastPush(t){var n;return this._isArrayBuffer((n=t.payload)===null||n===void 0?void 0:n.payload)?this._encodeBinaryUserBroadcastPush(t):this._encodeJsonUserBroadcastPush(t)}_encodeBinaryUserBroadcastPush(t){var n,r;const s=(r=(n=t.payload)===null||n===void 0?void 0:n.payload)!==null&&r!==void 0?r:new ArrayBuffer(0);return this._encodeUserBroadcastPush(t,this.BINARY_ENCODING,s)}_encodeJsonUserBroadcastPush(t){var n,r;const s=(r=(n=t.payload)===null||n===void 0?void 0:n.payload)!==null&&r!==void 0?r:{},i=new TextEncoder().encode(JSON.stringify(s)).buffer;return this._encodeUserBroadcastPush(t,this.JSON_ENCODING,i)}_encodeUserBroadcastPush(t,n,r){var s,o;const i=t.topic,a=(s=t.ref)!==null&&s!==void 0?s:"",l=(o=t.join_ref)!==null&&o!==void 0?o:"",c=t.payload.event,u=this.allowedMetadataKeys?this._pick(t.payload,this.allowedMetadataKeys):{},d=Object.keys(u).length===0?"":JSON.stringify(u);if(l.length>255)throw new Error(`joinRef length ${l.length} exceeds maximum of 255`);if(a.length>255)throw new Error(`ref length ${a.length} exceeds maximum of 255`);if(i.length>255)throw new Error(`topic length ${i.length} exceeds maximum of 255`);if(c.length>255)throw new Error(`userEvent length ${c.length} exceeds maximum of 255`);if(d.length>255)throw new Error(`metadata length ${d.length} exceeds maximum of 255`);const p=this.USER_BROADCAST_PUSH_META_LENGTH+l.length+a.length+i.length+c.length+d.length,h=new ArrayBuffer(this.HEADER_LENGTH+p);
248let x=new DataView(h),v=0;x.setUint8(v++,this.KINDS.userBroadcastPush),x.setUint8(v++,l.length),x.setUint8(v++,a.length),x.setUint8(v++,i.length),x.setUint8(v++,c.length),x.setUint8(v++,d.length),x.setUint8(v++,n),Array.from(l,w=>x.setUint8(v++,w.charCodeAt(0))),Array.from(a,w=>x.setUint8(v++,w.charCodeAt(0))),Array.from(i,w=>x.setUint8(v++,w.charCodeAt(0))),Array.from(c,w=>x.setUint8(v++,w.charCodeAt(0))),Array.from(d,w=>x.setUint8(v++,w.charCodeAt(0)));var b=new Uint8Array(h.byteLength+r.byteLength);return b.set(new Uint8Array(h),0),b.set(new Uint8Array(r),h.byteLength),b.buffer}decode(t,n){if(this._isArrayBuffer(t)){let r=this._binaryDecode(t);return n(r)}if(typeof t=="string"){const r=JSON.parse(t),[s,o,i,a,l]=r;return n({join_ref:s,ref:o,topic:i,event:a,payload:l})}return n({})}_binaryDecode(t){const n=new DataView(t),r=n.getUint8(0),s=new TextDecoder;switch(r){case this.KINDS.userBroadcast:return this._decodeUserBroadcast(t,n,s)}}_decodeUserBroadcast(t,n,r){const s=n.getUint8(1),o=n.getUint8(2),i=n.getUint8(3),a=n.getUint8(4);let l=this.HEADER_LENGTH+4;const c=r.decode(t.slice(l,l+s));l=l+s;const u=r.decode(t.slice(l,l+o));l=l+o;const d=r.decode(t.slice(l,l+i));l=l+i;const p=t.slice(l,t.byteLength),h=a===this.JSON_ENCODING?JSON.parse(r.decode(p)):p,x={type:this.BROADCAST_EVENT,event:u,payload:h};return i>0&&(x.meta=JSON.parse(d)),{join_ref:null,ref:null,topic:c,event:this.BROADCAST_EVENT,payload:x}}_isArrayBuffer(t){var n;return t instanceof ArrayBuffer||((n=t==null?void 0:t.constructor)===null||n===void 0?void 0:n.name)==="ArrayBuffer"}_pick(t,n){return!t||typeof t!="object"?{}:Object.fromEntries(Object.entries(t).filter(([r])=>n.includes(r)))}}class IC{constructor(t,n){this.callback=t,this.timerCalc=n,this.timer=void 0,this.tries=0,this.callback=t,this.timerCalc=n}reset(){this.tries=0,clearTimeout(this.timer),this.timer=void 0}scheduleTimeout(){clearTimeout(this.timer),this.timer=setTimeout(()=>{this.tries=this.tries+1,this.callback()},this.timerCalc(this.tries+1))}}var je;(function(e){e.abstime="abstime",e.bool="bool",e.date="date",e.daterange="daterange",e.float4="float4",e.float8="float8",e.int2="int2",e.int4="int4",e.int4range="int4range",e.int8="int8",e.int8range="int8range",e.json="json",e.jsonb="jsonb",e.money="money",e.numeric="numeric",e.oid="oid",e.reltime="reltime",e.text="text",e.time="time",e.timestamp="timestamp",e.timestamptz="timestamptz",e.timetz="timetz",e.tsrange="tsrange",e.tstzrange="tstzrange"})(je||(je={}));const y0=(e,t,n={})=>{var r;const s=(r=n.skipTypes)!==null&&r!==void 0?r:[];return t?Object.keys(t).reduce((o,i)=>(o[i]=t5(i,e,t,s),o),{}):{}},t5=(e,t,n,r)=>{const s=t.find(a=>a.name===e),o=s==null?void 0:s.type,i=n[e];return o&&!r.includes(o)?DC(o,i):dm(i)},DC=(e,t)=>{if(e.charAt(0)==="_"){const n=e.slice(1,e.length);return o5(t,n)}switch(e){case je.bool:return n5(t);case je.float4:case je.float8:case je.int2:case je.int4:case je.int8:case je.numeric:case je.oid:return r5(t);case je.json:case je.jsonb:return s5(t);case je.timestamp:return i5(t);case je.abstime:case je.date:case je.daterange:case je.int4range:case je.int8range:case je.money:case je.reltime:case je.text:case je.time:case je.timestamptz:case je.timetz:case je.tsrange:case je.tstzrange:return dm(t);default:return dm(t)}},dm=e=>e,n5=e=>{switch(e){case"t":return!0;case"f":return!1;default:return e}},r5=e=>{if(typeof e=="string"){const t=parseFloat(e);if(!Number.isNaN(t))return t}return e},s5=e=>{if(typeof e=="string")try{return JSON.parse(e)}catch{return e}return e},o5=(e,t)=>{if(typeof e!="string")return e;const n=e.length-1,r=e[n];if(e[0]==="{"&&r==="}"){let o;const i=e.slice(1,n);try{o=JSON.parse("["+i+"]")}catch{o=i?i.split(","):[]}return o.map(a=>DC(t,a))}return e},i5=e=>typeof e=="string"?e.replace(" ","T"):e,MC=e=>{const t=new URL(e);return t.protocol=t.protocol.replace(/^ws/i,"http"),t.pathname=t.pathname.replace(/\/+$/,"").replace(/\/socket\/websocket$/i,"").replace(/\/socket$/i,"").replace(/\/websocket$/i,""),t.pathname===""||t.pathname==="/"?t.pathname="/api/broadcast":t.pathname=t.pathname+"/api/broadcast",t.href};class wh{constructor(t,n,r={},s=cm){this.channel=t,this.event=n,this.payload=r,this.timeout=s,this.sent=!1,this.timeoutTimer=void 0,this.ref="",this.receivedResp=null,this.recHo
vendor: 4,925 bytes, line 248
248oks=[],this.refEvent=null}resend(t){this.timeout=t,this._cancelRefEvent(),this.ref="",this.refEvent=null,this.receivedResp=null,this.sent=!1,this.send()}send(){this._hasReceived("timeout")||(this.startTimeout(),this.sent=!0,this.channel.socket.push({topic:this.channel.topic,event:this.event,payload:this.payload,ref:this.ref,join_ref:this.channel._joinRef()}))}updatePayload(t){this.payload=Object.assign(Object.assign({},this.payload),t)}receive(t,n){var r;return this._hasReceived(t)&&n((r=this.receivedResp)===null||r===void 0?void 0:r.response),this.recHooks.push({status:t,callback:n}),this}startTimeout(){if(this.timeoutTimer)return;this.ref=this.channel.socket._makeRef(),this.refEvent=this.channel._replyEventName(this.ref);const t=n=>{this._cancelRefEvent(),this._cancelTimeout(),this.receivedResp=n,this._matchReceive(n)};this.channel._on(this.refEvent,{},t),this.timeoutTimer=setTimeout(()=>{this.trigger("timeout",{})},this.timeout)}trigger(t,n){this.refEvent&&this.channel._trigger(this.refEvent,{status:t,response:n})}destroy(){this._cancelRefEvent(),this._cancelTimeout()}_cancelRefEvent(){this.refEvent&&this.channel._off(this.refEvent,{})}_cancelTimeout(){clearTimeout(this.timeoutTimer),this.timeoutTimer=void 0}_matchReceive({status:t,response:n}){this.recHooks.filter(r=>r.status===t).forEach(r=>r.callback(n))}_hasReceived(t){return this.receivedResp&&this.receivedResp.status===t}}var w0;(function(e){e.SYNC="sync",e.JOIN="join",e.LEAVE="leave"})(w0||(w0={}));class ol{constructor(t,n){this.channel=t,this.state={},this.pendingDiffs=[],this.joinRef=null,this.enabled=!1,this.caller={onJoin:()=>{},onLeave:()=>{},onSync:()=>{}};const r=(n==null?void 0:n.events)||{state:"presence_state",diff:"presence_diff"};this.channel._on(r.state,{},s=>{const{onJoin:o,onLeave:i,onSync:a}=this.caller;this.joinRef=this.channel._joinRef(),this.state=ol.syncState(this.state,s,o,i),this.pendingDiffs.forEach(l=>{this.state=ol.syncDiff(this.state,l,o,i)}),this.pendingDiffs=[],a()}),this.channel._on(r.diff,{},s=>{const{onJoin:o,onLeave:i,onSync:a}=this.caller;this.inPendingSyncState()?this.pendingDiffs.push(s):(this.state=ol.syncDiff(this.state,s,o,i),a())}),this.onJoin((s,o,i)=>{this.channel._trigger("presence",{event:"join",key:s,currentPresences:o,newPresences:i})}),this.onLeave((s,o,i)=>{this.channel._trigger("presence",{event:"leave",key:s,currentPresences:o,leftPresences:i})}),this.onSync(()=>{this.channel._trigger("presence",{event:"sync"})})}static syncState(t,n,r,s){const o=this.cloneDeep(t),i=this.transformState(n),a={},l={};return this.map(o,(c,u)=>{i[c]||(l[c]=u)}),this.map(i,(c,u)=>{const d=o[c];if(d){const p=u.map(b=>b.presence_ref),h=d.map(b=>b.presence_ref),x=u.filter(b=>h.indexOf(b.presence_ref)<0),v=d.filter(b=>p.indexOf(b.presence_ref)<0);x.length>0&&(a[c]=x),v.length>0&&(l[c]=v)}else a[c]=u}),this.syncDiff(o,{joins:a,leaves:l},r,s)}static syncDiff(t,n,r,s){const{joins:o,leaves:i}={joins:this.transformState(n.joins),leaves:this.transformState(n.leaves)};return r||(r=()=>{}),s||(s=()=>{}),this.map(o,(a,l)=>{var c;const u=(c=t[a])!==null&&c!==void 0?c:[];if(t[a]=this.cloneDeep(l),u.length>0){const d=t[a].map(h=>h.presence_ref),p=u.filter(h=>d.indexOf(h.presence_ref)<0);t[a].unshift(...p)}r(a,u,l)}),this.map(i,(a,l)=>{let c=t[a];if(!c)return;const u=l.map(d=>d.presence_ref);c=c.filter(d=>u.indexOf(d.presence_ref)<0),t[a]=c,s(a,c,l),c.length===0&&delete t[a]}),t}static map(t,n){return Object.getOwnPropertyNames(t).map(r=>n(r,t[r]))}static transformState(t){return t=this.cloneDeep(t),Object.getOwnPropertyNames(t).reduce((n,r)=>{const s=t[r];return"metas"in s?n[r]=s.metas.map(o=>(o.presence_ref=o.phx_ref,delete o.phx_ref,delete o.phx_ref_prev,o)):n[r]=s,n},{})}static cloneDeep(t){return JSON.parse(JSON.stringify(t))}onJoin(t){this.caller.onJoin=t}onLeave(t){this.caller.onLeave=t}onSync(t){this.caller.onSync=t}inPendingSyncState(){return!this.joinRef||this.joinRef!==this.channel._joinRef()}}var b0;(function(e){e.ALL="*",e.INSERT="INSERT",e.UPDATE="UPDATE",e.DELETE="DELETE"})(b0||(b0={}));var il;(function(e){e.BROADCAST="broadcast",e.PRESENCE="presence",e.POSTGRES_CHANGES="postgres_changes",e.SYSTEM="system"})(il||(il={}));var Ir;(function(e){e.SUBSCRIBED="SUBSCRIBED",e.TIMED_OUT="TIMED_OUT",e.CLOSED="CLOSED",e.CHANNEL_ERROR="CHANNEL_ERROR"})(Ir||(Ir={}));class pi{constructor(t,n={config:{}},r){var s,o;if(this.topic=t,this.params=n,this.socket=r,this.bindings={},this.state=nt.closed,this.joinedOnce=!1,this.pushBuffer=[],this.subTopic=t.replace(/^realtime:/i,""),this.params.config=Object.assign({broadcast:{ack:!1,self:!1},presence:{key:"",enabled:!1},private:!1},n.config),this.timeout=this.socket.timeout,this.joinPush=new wh(this,zn.join,this.params,this.timeout),this.rejoinTimer=new IC(()=>this._rejoinUntilConnected(),this.socket.reconnectAfterMs),this.joinPush.receive("ok",()=>{this.state=nt.joined,this.rejoinTimer.reset(),this.pushBuffer.forEach(i=>
248i.send()),this.pushBuffer=[]}),this._onClose(()=>{this.rejoinTimer.reset(),this.socket.log("channel",`close ${this.topic} ${this._joinRef()}`),this.state=nt.closed,this.socket._remove(this)}),this._onError(i=>{this._isLeaving()||this._isClosed()||(this.socket.log("channel",`error ${this.topic}`,i),this.state=nt.errored,this.rejoinTimer.scheduleTimeout())}),this.joinPush.receive("timeout",()=>{this._isJoining()&&(this.socket.log("channel",`timeout ${this.topic}`,this.joinPush.timeout),this.state=nt.errored,this.rejoinTimer.scheduleTimeout())}),this.joinPush.receive("error",i=>{this._isLeaving()||this._isClosed()||(this.socket.log("channel",`error ${this.topic}`,i),this.state=nt.errored,this.rejoinTimer.scheduleTimeout())}),this._on(zn.reply,{},(i,a)=>{this._trigger(this._replyEventName(a),i)}),this.presence=new ol(this),this.broadcastEndpointURL=MC(this.socket.endPoint),this.private=this.params.config.private||!1,!this.private&&(!((o=(s=this.params.config)===null||s===void 0?void 0:s.broadcast)===null||o===void 0)&&o.replay))throw`tried to use replay on public channel '${this.topic}'. It must be a private channel.`}subscribe(t,n=this.timeout){var r,s,o;if(this.socket.isConnected()||this.socket.connect(),this.state==nt.closed){const{config:{broadcast:i,presence:a,private:l}}=this.params,c=(s=(r=this.bindings.postgres_changes)===null||r===void 0?void 0:r.map(h=>h.filter))!==null&&s!==void 0?s:[],u=!!this.bindings[il.PRESENCE]&&this.bindings[il.PRESENCE].length>0||((o=this.params.config.presence)===null||o===void 0?void 0:o.enabled)===!0,d={},p={broadcast:i,presence:Object.assign(Object.assign({},a),{enabled:u}),postgres_changes:c,private:l};this.socket.accessTokenValue&&(d.access_token=this.socket.accessTokenValue),this._onError(h=>t==null?void 0:t(Ir.CHANNEL_ERROR,h)),this._onClose(()=>t==null?void 0:t(Ir.CLOSED)),this.updateJoinPayload(Object.assign({config:p},d)),this.joinedOnce=!0,this._rejoin(n),this.joinPush.receive("ok",async({postgres_changes:h})=>{var x;if(this.socket._isManualToken()||this.socket.setAuth(),h===void 0){t==null||t(Ir.SUBSCRIBED);return}else{const v=this.bindings.postgres_changes,b=(x=v==null?void 0:v.length)!==null&&x!==void 0?x:0,w=[];for(let g=0;g<b;g++){const y=v[g],{filter:{event:_,schema:S,table:k,filter:E}}=y,R=h&&h[g];if(R&&R.event===_&&pi.isFilterValueEqual(R.schema,S)&&pi.isFilterValueEqual(R.table,k)&&pi.isFilterValueEqual(R.filter,E))w.push(Object.assign(Object.assign({},y),{id:R.id}));else{this.unsubscribe(),this.state=nt.errored,t==null||t(Ir.CHANNEL_ERROR,new Error("mismatch between server and client bindings for postgres changes"));return}}this.bindings.postgres_changes=w,t&&t(Ir.SUBSCRIBED);return}}).receive("error",h=>{this.state=nt.errored,t==null||t(Ir.CHANNEL_ERROR,new Error(JSON.stringify(Object.values(h).join(", ")||"error")))}).receive("timeout",()=>{t==null||t(Ir.TIMED_OUT)})}return this}presenceState(){return this.presence.state}async track(t,n={}){return await this.send({type:"presence",event:"track",payload:t},n.timeout||this.timeout)}async untrack(t={}){return await this.send({type:"presence",event:"untrack"},t)}on(t,n,r){return this.state===nt.joined&&t===il.PRESENCE&&(this.socket.log("channel",`resubscribe to ${this.topic} due to change in presence callbacks on joined channel`),this.unsubscribe().then(async()=>await this.subscribe())),this._on(t,n,r)}async httpSend(t,n,r={}){var s;if(n==null)return Promise.reject("Payload is required for httpSend()");const o={apikey:this.socket.apiKey?this.socket.apiKey:"","Content-Type":"application/json"};this.socket.accessTokenValue&&(o.Authorization=`Bearer ${this.socket.accessTokenValue}`);const i={method:"POST",headers:o,body:JSON.stringify({messages:[{topic:this.subTopic,event:t,payload:n,private:this.private}]})},a=await this._fetchWithTimeout(this.broadcastEndpointURL,i,(s=r.timeout)!==null&&s!==void 0?s:this.timeout);if(a.status===202)return{success:!0};let l=a.statusText;try{const c=await a.json();l=c.error||c.message||l}catch{}return Promise.reject(new Error(l))}async send(t,n={}){var r,s;if(!this._canPush()&&t.type==="broadcast"){console.warn("Realtime send() is automatically falling back to REST API. This behavior will be deprecated
248in the future. Please use httpSend() explicitly for REST delivery.");const{event:o,payload:i}=t,a={apikey:this.socket.apiKey?this.socket.apiKey:"","Content-Type":"application/json"};this.socket.accessTokenValue&&(a.Authorization=`Bearer ${this.socket.accessTokenValue}`);const l={method:"POST",headers:a,body:JSON.stringify({messages:[{topic:this.subTopic,event:o,payload:i,private:this.private}]})};try{const c=await this._fetchWithTimeout(this.broadcastEndpointURL,l,(r=n.timeout)!==null&&r!==void 0?r:this.timeout);return await((s=c.body)===null||s===void 0?void 0:s.cancel()),c.ok?"ok":"error"}catch(c){return c.name==="AbortError"?"timed out":"error"}}else return new Promise(o=>{var i,a,l;const c=this._push(t.type,t,n.timeout||this.timeout);t.type==="broadcast"&&!(!((l=(a=(i=this.params)===null||i===void 0?void 0:i.config)===null||a===void 0?void 0:a.broadcast)===null||l===void 0)&&l.ack)&&o("ok"),c.receive("ok",()=>o("ok")),c.receive("error",()=>o("error")),c.receive("timeout",()=>o("timed out"))})}updateJoinPayload(t){this.joinPush.updatePayload(t)}unsubscribe(t=this.timeout){this.state=nt.leaving;const n=()=>{this.socket.log("channel",`leave ${this.topic}`),this._trigger(zn.close,"leave",this._joinRef())};this.joinPush.destroy();let r=null;return new Promise(s=>{r=new wh(this,zn.leave,{},t),r.receive("ok",()=>{n(),s("ok")}).receive("timeout",()=>{n(),s("timed out")}).receive("error",()=>{s("error")}),r.send(),this._canPush()||r.trigger("ok",{})}).finally(()=>{r==null||r.destroy()})}teardown(){this.pushBuffer.forEach(t=>t.destroy()),this.pushBuffer=[],this.rejoinTimer.reset(),this.joinPush.destroy(),this.state=nt.closed,this.bindings={}}async _fetchWithTimeout(t,n,r){const s=new AbortController,o=setTimeout(()=>s.abort(),r),i=await this.socket.fetch(t,Object.assign(Object.assign({},n),{signal:s.signal}));return clearTimeout(o),i}_push(t,n,r=this.timeout){if(!this.joinedOnce)throw`tried to push '${t}' to '${this.topic}' before joining. Use channel.subscribe() before pushing events`;let s=new wh(this,t,n,r);return this._canPush()?s.send():this._addToPushBuffer(s),s}_addToPushBuffer(t){if(t.startTimeout(),this.pushBuffer.push(t),this.pushBuffer.length>X3){const n=this.pushBuffer.shift();n&&(n.destroy(),this.socket.log("channel",`discarded push due to buffer overflow: ${n.event}`,n.payload))}}_onMessage(t,n,r){return n}_isMember(t){return this.topic===t}_joinRef(){return this.joinPush.ref}_trigger(t,n,r){var s,o;const i=t.toLocaleLowerCase(),{close:a,error:l,leave:c,join:u}=zn;if(r&&[a,l,c,u].indexOf(i)>=0&&r!==this._joinRef())return;let p=this._onMessage(i,n,r);if(n&&!p)throw"channel onMessage callbacks must return the payload, modified or unmodified";["insert","update","delete"].includes(i)?(s=this.bindings.postgres_changes)===null||s===void 0||s.filter(h=>{var x,v,b;return((x=h.filter)===null||x===void 0?void 0:x.event)==="*"||((b=(v=h.filter)===null||v===void 0?void 0:v.event)===null||b===void 0?void 0:b.toLocaleLowerCase())===i}).map(h=>h.callback(p,r)):(o=this.bindings[i])===null||o===void 0||o.filter(h=>{var x,v,b,w,g,y;if(["broadcast","presence","postgres_changes"].includes(i))if("id"in h){const _=h.id,S=(x=h.filter)===null||x===void 0?void 0:x.event;return _&&((v=n.ids)===null||v===void 0?void 0:v.includes(_))&&(S==="*"||(S==null?void 0:S.toLocaleLowerCase())===((b=n.data)===null||b===void 0?void 0:b.type.toLocaleLowerCase()))}else{const _=(g=(w=h==null?void 0:h.filter)===null||w===void 0?void 0:w.event)===null||g===void 0?void 0:g.toLocaleLowerCase();return _==="*"||_===((y=n==null?void 0:n.event)===null||y===void 0?void 0:y.toLocaleLowerCase())}else return h.type.toLocaleLowerCase()===i}).map(h=>{if(typeof p=="object"&&"ids"in p){const x=p.data,{schema:v,table:b,commit_timestamp:w,type:g,errors:y}=x;p=Object.assign(Object.assign({},{schema:v,table:b,commit_timestamp:w,eventType:g,new:{},old:{},errors:y}),this._getPayloadRecords(x))}h.callback(p,r)})}_isClosed(){return this.state===nt.closed}_isJoined(){return this.state===nt.joined}_isJoining(){return this.state===nt.joining}_isLeaving(){return this.state===nt.leaving}_replyEventName(t){return`chan_reply_${t}`}_on(t,n,r){const s=t.toLocaleLowerCase(),o={type:s,filter:n,callback:r};return this.bindings[s]?this.bindings[s].push(o):this.bindings[s]=[o],this}_off(t,n){const r=t.toLocaleLowerCase();return this.bindings[r]&&(this.bindings[r]=this.bindings[r].filter(s=>{var o;return!(((o=s.type)===null||o===void 0?void 0:o.toLocaleLowerCase())===r&&pi.isEqual(s.filter,n))})),this}static isEqual(t,n){if(Object.keys(t).length!==Object.keys(n).length)return!1;for(const r in t)if(t[r]!==n[r])return!1;return!0}static isFilterValueEqual(t,n){return(t??void 0)===(n??void 0)}_rejoinUntilConnected(){this.rejoinTimer.scheduleTimeout(),this.socket.isConnected()&&this._rejoin()}_onClose(t){this._on(zn.close,{},t)}_onError(t){this._on(zn.error,{},n=>t(n))}_canPush(){return this.socket.isConnected()&&this._isJoined()}_rejoin(t=this.timeout){this._isLeaving()||(this.socket._leaveOpenTopic(this.topic),this.state=nt.joining,this.joinPush.resend(t))}_getPayloadRecords(t){const n={new:{},old:{}};return(t.type==="INSERT"||t.type==="UPDATE")&&(n.new=y0(t.columns,t.record)),(t.type==="UPDATE"||t.type==="DELETE")&&(n.old=y0(t.columns,t.old_record)),n}}const bh=()=>{},Fc={HEARTBEAT_INTERVAL:25e3,RECONNECT_DELAY:10,HEARTBEAT_TIMEOUT_FALLBACK:100},a5=[1e3,2e3,5e3,1e4],l5=1e4,c5=` 249 addEventListener("message", (e) => { 250 if (e.data.event === "start") { 251 setInterval(() => postMessage({ event: "keepAlive" }), e.data.interval); 252 } 253 });`;class u5{constructor(t,n){var r;if(this.accessTokenValue=null,this.apiKey=null,this._manuallySetToken=!1,this.channels=new Array,this.endPoint="",this.httpEndpoint="",this.headers={},this.params={},this.timeout=cm,this.transport=null,this.heartbeatIntervalMs=Fc.HEARTBEAT_INTERVAL,this.heartbeatTimer=void 0,this.pendingHeartbeatRef=null,this.heartbeatCallback=bh,this.ref=0,this.reconnectTimer=null,this.vsn=v0,this.logger=bh,this.conn=null,this.sendBuffer=[],this.serializer
253=new e5,this.stateChangeCallbacks={open:[],close:[],error:[],message:[]},this.accessToken=null,this._connectionState="disconnected",this._wasManualDisconnect=!1,this._authPromise=null,this._heartbeatSentAt=null,this._resolveFetch=s=>s?(...o)=>s(...o):(...o)=>fetch(...o),!(!((r=n==null?void 0:n.params)===null||r===void 0)&&r.apikey))throw new Error("API key is required to connect to Realtime");this.apiKey=n.params.apikey,this.endPoint=`${t}/${um.websocket}`,this.httpEndpoint=MC(t),this._initializeOptions(n),this._setupReconnectionTimer(),this.fetch=this._resolveFetch(n==null?void 0:n.fetch)}connect(){if(!(this.isConnecting()||this.isDisconnecting()||this.conn!==null&&this.isConnected())){if(this._setConnectionState("connecting"),this.accessToken&&!this._authPromise&&this._setAuthSafely("connect"),this.transport)this.conn=new this.transport(this.endpointURL());else try{this.conn=G3.createWebSocket(this.endpointURL())}catch(t){this._setConnectionState("disconnected");const n=t.message;throw n.includes("Node.js")?new Error(`${n} 254 255To use Realtime in Node.js, you need to provide a WebSocket implementation: 256 257Option 1: Use Node.js 22+ which has native WebSocket support 258Option 2: Install and provide the "ws" package: 259 260 npm install ws 261 262 import ws from "ws" 263 const client = new RealtimeClient(url, { 264 ...options, 265 transport: ws 266 })`):new Error(`WebSocket not available: ${n}`)}this._setupConnectionHandlers()}}endpointURL(){return this._appendParams(this.endPoint,Object.assign({},this.params,{vsn:this.vsn}))}disconnect(t,n){if(!this.isDisconnecting())if(this._setConnectionState("disconnecting",!0),this.conn){const r=setTimeout(()=>{this._setConnectionState("disconnected")},100);this.conn.onclose=()=>{clearTimeout(r),this._setConnectionState("disconnected")},typeof this.conn.close=="function"&&(t?this.conn.close(t,n??""):this.conn.close()),this._teardownConnection()}else this._setConnectionState("disconnected")}getChannels(){return this.channels}async removeChannel(t){const n=await t.unsubscribe();return this.channels.length===0&&this.disconnect(),n}async removeAllChannels(){const t=await Promise.all(this.channels.map(n=>n.unsubscribe()));return this.channels=[],this.disconnect(),t}log(t,n,r){this.logger(t,n,r)}connectionState(){switch(this.conn&&this.conn.readyState){case as.connecting:return oo.Connecting;case as.open:return oo.Open;case as.closing:return oo.Closing;default:return oo.Closed}}isConnected(){return this.connectionState()===oo.Open}isConnecting(){return this._connectionState==="connecting"}isDisconnecting(){return this._connectionState==="disconnecting"}channel(t,n={config:{}}){const r=`realtime:${t}`,s=this.getChannels().find(o=>o.topic===r);if(s)return s;{const o=new pi(`realtime:${t}`,n,this);return this.channels.push(o),o}}push(t){const{topic:n,event:r,payload:s,ref:o}=t,i=()=>{this.encode(t,a=>{var l;(l=this.conn)===null||l===void 0||l.send(a)})};this.log("push",`${n} ${r} (${o})`,s),this.isConnected()?i():this.sendBuffer.push(i)}async setAuth(t=null){this._authPromise=this._performAuth(t);try{await this._authPromise}finally{this._authPromise=null}}_isManualToken(){return this._manuallySetToken}async sendHeartbeat(){var t;if(!this.isConnected()){try{this.heartbeatCallback("disconnected")}catch(n){this.log("error","error in heartbeat callback",n)}return}if(this.pendingHeartbeatRef){this.pendingHeartbeatRef=null,this._heartbeatSentAt=null,this.log("transport","heartbeat timeout. Attempting to re-establish connection");try{this.heartbeatCallback("timeout")}catch(n){this.log("error","error in heartbeat callback",n)}this._wasManualDisconnect=!1,(t=this.conn)===null||t===void 0||t.close(J3,"heartbeat timeout"),setTimeout(()=>{var n;this.isConnected()||(n=this.reconnectTimer)===null||n===void 0||n.scheduleTimeout()},Fc.HEARTBEAT_TIMEOUT_FALLBACK);return}this._heartbeatSentAt=Date.now(),this.pendingHeartbeatRef=this._makeRef(),this.push({topic:"phoenix",event:"heartbeat",payload:{},ref:this.pendingHeartbeatRef});try{this.heartbeatCallback("sent")}catch(n){this.log("error","error in heartbeat callback",n)}this._setAuthSafely("heartbeat")}onHeartbeat(t){this.heartbeatCallback=t}flushSendBuffer(){this.isConnected()&&this.sendBuffer.length>0&&(this.sendBuffer.forEach(t=>t()),this.sendBuffer=[])}_makeRef(){let t=this.ref+1;return t===this.ref?this.ref=0:this.ref=t,this.ref.toString()}_leaveOpenTopic(t){let n=this.channels.find(r=>r.topic===t&&(r._isJoined()||r._isJoining()));n&&(this.log("transport",`leaving duplicate topic "${t}"`),n.unsubscribe())}_remove(t){this.channels=this.channels.filter(n=>n.topic!==t.topic)}_onConnMessage(t){this.decode(t.data,n=>
266{if(n.topic==="phoenix"&&n.event==="phx_reply"&&n.ref&&n.ref===this.pendingHeartbeatRef){const c=this._heartbeatSentAt?Date.now()-this._heartbeatSentAt:void 0;try{this.heartbeatCallback(n.payload.status==="ok"?"ok":"error",c)}catch(u){this.log("error","error in heartbeat callback",u)}this._heartbeatSentAt=null,this.pendingHeartbeatRef=null}const{topic:r,event:s,payload:o,ref:i}=n,a=i?`(${i})`:"",l=o.status||"";this.log("receive",`${l} ${r} ${s} ${a}`.trim(),o),this.channels.filter(c=>c._isMember(r)).forEach(c=>c._trigger(s,o,i)),this._triggerStateCallbacks("message",n)})}_clearTimer(t){var n;t==="heartbeat"&&this.heartbeatTimer?(clearInterval(this.heartbeatTimer),this.heartbeatTimer=void 0):t==="reconnect"&&((n=this.reconnectTimer)===null||n===void 0||n.reset())}_clearAllTimers(){this._clearTimer("heartbeat"),this._clearTimer("reconnect")}_setupConnectionHandlers(){this.conn&&("binaryType"in this.conn&&(this.conn.binaryType="arraybuffer"),this.conn.onopen=()=>this._onConnOpen(),this.conn.onerror=t=>this._onConnError(t),this.conn.onmessage=t=>this._onConnMessage(t),this.conn.onclose=t=>this._onConnClose(t),this.conn.readyState===as.open&&this._onConnOpen())}_teardownConnection(){if(this.conn){if(this.conn.readyState===as.open||this.conn.readyState===as.connecting)try{this.conn.close()}catch(t){this.log("error","Error closing connection",t)}this.conn.onopen=null,this.conn.onerror=null,this.conn.onmessage=null,this.conn.onclose=null,this.conn=null}this._clearAllTimers(),this._terminateWorker(),this.channels.forEach(t=>t.teardown())}_onConnOpen(){this._setConnectionState("connected"),this.log("transport",`connected to ${this.endpointURL()}`),(this._authPromise||(this.accessToken&&!this.accessTokenValue?this.setAuth():Promise.resolve())).then(()=>{this.flushSendBuffer()}).catch(n=>{this.log("error","error waiting for auth on connect",n),this.flushSendBuffer()}),this._clearTimer("reconnect"),this.worker?this.workerRef||this._startWorkerHeartbeat():this._startHeartbeat(),this._triggerStateCallbacks("open")}_startHeartbeat(){this.heartbeatTimer&&clearInterval(this.heartbeatTimer),this.heartbeatTimer=setInterval(()=>this.sendHeartbeat(),this.heartbeatIntervalMs)}_startWorkerHeartbeat(){this.workerUrl?this.log("worker",`starting worker for from ${this.workerUrl}`):this.log("worker","starting default worker");const t=this._workerObjectUrl(this.workerUrl);this.workerRef=new Worker(t),this.workerRef.onerror=n=>{this.log("worker","worker error",n.message),this._terminateWorker()},this.workerRef.onmessage=n=>{n.data.event==="keepAlive"&&this.sendHeartbeat()},this.workerRef.postMessage({event:"start",interval:this.heartbeatIntervalMs})}_terminateWorker(){this.workerRef&&(this.log("worker","terminating worker"),this.workerRef.terminate(),this.workerRef=void 0)}_onConnClose(t){var n;this._setConnectionState("disconnected"),this.log("transport","close",t),this._triggerChanError(),this._clearTimer("heartbeat"),this._wasManualDisconnect||(n=this.reconnectTimer)===null||n===void 0||n.scheduleTimeout(),this._triggerStateCallbacks("close",t)}_onConnError(t){this._setConnectionState("disconnected"),this.log("transport",`${t}`),this._triggerChanError(),this._triggerStateCallbacks("error",t);try{this.heartbeatCallback("error")}catch(n){this.log("error","error in heartbeat callback",n)}}_triggerChanError(){this.channels.forEach(t=>t._trigger(zn.error))}_appendParams(t,n){if(Object.keys(n).length===0)return t;const r=t.match(/\?/)?"&":"?",s=new URLSearchParams(n);return`${t}${r}${s}`}_workerObjectUrl(t){let n;if(t)n=t;else{const r=new Blob([c5],{type:"application/javascript"});n=URL.createObjectURL(r)}return n}_setConnectionState(t,n=!1){this._connectionState=t,t==="connecting"?this._wasManualDisconnect=!1:t==="disconnecting"&&(this._wasManualDisconnect=n)}async _performAuth(t=null){let n,r=!1;if(t)n=t,r=!0;else if(this.accessToken)try{n=await this.accessToken()}catch(s){this.log("error","Error fetching access token from callback",s),n=this.accessTokenValue}else n=this.accessTokenValue;r?this._manuallySetToken=!0:this.accessToken&&(this._manuallySetToken=!1),this.accessTokenValue!=n&&(this.accessTokenValue=n,this.channels.forEac
266h(s=>{const o={access_token:n,version:Z3};n&&s.updateJoinPayload(o),s.joinedOnce&&s._isJoined()&&s._push(zn.access_token,{access_token:n})}))}async _waitForAuthIfNeeded(){this._authPromise&&await this._authPromise}_setAuthSafely(t="general"){this._isManualToken()||this.setAuth().catch(n=>{this.log("error",`Error setting auth in ${t}`,n)})}_triggerStateCallbacks(t,n){try{this.stateChangeCallbacks[t].forEach(r=>{try{r(n)}catch(s){this.log("error",`error in ${t} callback`,s)}})}catch(r){this.log("error",`error triggering ${t} callbacks`,r)}}_setupReconnectionTimer(){this.reconnectTimer=new IC(async()=>{setTimeout(async()=>{await this._waitForAuthIfNeeded(),this.isConnected()||this.connect()},Fc.RECONNECT_DELAY)},this.reconnectAfterMs)}_initializeOptions(t){var n,r,s,o,i,a,l,c,u,d,p,h;switch(this.transport=(n=t==null?void 0:t.transport)!==null&&n!==void 0?n:null,this.timeout=(r=t==null?void 0:t.timeout)!==null&&r!==void 0?r:cm,this.heartbeatIntervalMs=(s=t==null?void 0:t.heartbeatIntervalMs)!==null&&s!==void 0?s:Fc.HEARTBEAT_INTERVAL,this.worker=(o=t==null?void 0:t.worker)!==null&&o!==void 0?o:!1,this.accessToken=(i=t==null?void 0:t.accessToken)!==null&&i!==void 0?i:null,this.heartbeatCallback=(a=t==null?void 0:t.heartbeatCallback)!==null&&a!==void 0?a:bh,this.vsn=(l=t==null?void 0:t.vsn)!==null&&l!==void 0?l:v0,t!=null&&t.params&&(this.params=t.params),t!=null&&t.logger&&(this.logger=t.logger),(t!=null&&t.logLevel||t!=null&&t.log_level)&&(this.logLevel=t.logLevel||t.log_level,this.params=Object.assign(Object.assign({},this.params),{log_level:this.logLevel})),this.reconnectAfterMs=(c=t==null?void 0:t.reconnectAfterMs)!==null&&c!==void 0?c:x=>a5[x-1]||l5,this.vsn){case Q3:this.encode=(u=t==null?void 0:t.encode)!==null&&u!==void 0?u:(x,v)=>v(JSON.stringify(x)),this.decode=(d=t==null?void 0:t.decode)!==null&&d!==void 0?d:(x,v)=>v(JSON.parse(x));break;case jC:this.encode=(p=t==null?void 0:t.encode)!==null&&p!==void 0?p:this.serializer.encode.bind(this.serializer),this.decode=(h=t==null?void 0:t.decode)!==null&&h!==void 0?h:this.serializer.decode.bind(this.serializer);break;default:throw new Error(`Unsupported serializer version: ${this.vsn}`)}if(this.worker){if(typeof window<"u"&&!window.Worker)throw new Error("Web Worker is not supported");this.workerUrl=t==null?void 0:t.workerUrl}}}var jl=class extends Error{constructor(e,t){var n;super(e),this.name="IcebergError",this.status=t.status,this.icebergType=t.icebergType,this.icebergCode=t.icebergCode,this.details=t.details,this.isCommitStateUnknown=t.icebergType==="CommitStateUnknownException"||[500,502,504].includes(t.status)&&((n=t.icebergType)==null?void 0:n.includes("CommitState"))===!0}isNotFound(){return this.status===404}isConflict(){return this.status===409}isAuthenticationTimeout(){return this.status===419}};function d5(e,t,n){const r=new URL(t,e);if(n)for(const[s,o]of Object.entries(n))o!==void 0&&r.searchParams.set(s,o);return r.toString()}async function f5(e){return!e||e.type==="none"?{}:e.type==="bearer"?{Authorization:`Bearer ${e.token}`}:e.type==="header"?{[e.name]:e.value}:e.type==="custom"?await e.getHeaders():{}}function h5(e){const t=e.fetchImpl??globalThis.fetch;return{async request({method:n,path:r,query:s,body:o,headers:i}){const a=d5(e.baseUrl,r,s),l=await f5(e.auth),c=await t(a,{method:n,headers:{...o?{"Content-Type":"application/json"}:{},...l,...i},body:o?JSON.stringify(o):void 0}),u=await c.text(),d=(c.headers.get("content-type")||"").includes("application/json"),p=d&&u?JSON.parse(u):u;if(!c.ok){const h=d?p:void 0,x=h==null?void 0:h.error;throw new jl((x==null?void 0:x.message)??`Request failed with status ${c.status}`,{status:c.status,icebergType:x==null?void 0:x.type,icebergCode:x==null?void 0:x.code,details:h})}return{status:c.status,headers:c.headers,data:p}}}}function Uc(e){return e.join("�")}var p5=class{constructor(e,t=""){this.client=e,this.prefix=t}async listNamespaces(e){const t=e?{parent:Uc(e.namespace)}:void 0;return(await this.client.request({method:"GET",path:`${this.prefix}/namespaces`,query:t})).data.namespaces.map(r=>({namespace:r}))}async createNamespace(e,t){const n={namespace:e.namespace,properties:t==null?void 0:t.properties};return(await this.client.request({method:"POST",path:`${this.prefix}/namespaces`,body:n})).data}async dropNamespace(e){await this.client.request({method:"DELETE",path:`${this.prefix}/namespaces/${Uc(e.namespace)}`})}async loadNamespaceMetadata(e){return{properties:(await this.client.request({method:"GET",path:`${this.prefix}/namespaces/${Uc(e.namespace)}`})).data.properties}}async namespaceExists(e){try{return await this.client.request({method:"HEAD",path:`${this.prefix}/namespaces/${Uc(e.namespace)}`}),!0}catch(t){if(t instanceof jl&&t.status===404)return!1;throw t}}async createNamespaceIfNotExists(e,t){try{return await this.createNamespace(e,t)}catch(n){if(n instanceof jl&&n.status===409)return;throw n}}};function Vo(e){return e.join("�")}var m5=class{constructor(e,t="",n){this.client=e,this.prefix=t,this.accessDelegation=n}async listTables(e){return(await this.client.request({method:"GET",path:`${this.prefix}/namespaces/${Vo(e.namespace)}/tables`})).data.identifiers}async createTable(e,t){const n={};return this.accessDelegation&&(n["X-Iceberg-Access-Delegation"]=this.accessDelegation),(await this.client.request({method:"POST",path:`${this.prefix}/namespaces/${Vo(e.namespace)}/tables`,body:t,headers:n})).data.metadata}async updateTable(e,t){const n=await this.client.request({method:"POST",path:`${this.prefix}/namespaces/${Vo(e.namespace)}/tables/${e.name}`,body:t});return{"metadata-location":n.data["metadata-location"],metadata:n.data.metadata}}async dropTable(e,t){await this.client.request({method:"DELETE",path:`${this.prefix}/namespaces/${Vo(e.namespace)}/tables/${e.name}`,query:{purgeRequested:String((t==null?void 0:t.purge)??!1)}})}async loadTable(e){const t={};return this.accessDelegation&&(t["X-Iceberg-Access-Delegation"]=this.accessDelegation),(await this.client.request({method:"GET",path:`${this.prefix}/namespaces/${Vo(e.namespace)}/tables/${e.name}`,headers:t})).data.metadata}async tableExists(e){const t={};this.accessDelegation&&(t["X-Iceberg-Access-Delegation"]=this.accessDelegation);try{return await this.client.request({method:"HEAD",path:`${this.prefix}/namespaces/${Vo(e.namespace)}/tables/${e.name}`,headers:t}),!0}catch(n){if(n instanceof jl&&n.status===404)return!1;throw n}}async createTableIfNotExists(e,t){try{return await this.createTable(e,t)}catch(n){if(n instanceof jl&&n.status===409)return await this.loadTable({namespace:e.namespace,name:t.name});throw n}}},g5=class{constructor(e){var r;let t="v1";e.catalogName&&(t+=`/${e.catalogName}`);const n=e.baseUrl.endsWith("/")?e.baseUrl:`${e.baseUrl}/`;this.client=h5({baseUrl:n,auth:e.auth,fetchImpl:e.fetch}),this.accessDelegation=(r=e.accessDelegation)==null?void 0:r.join(","),this.namespaceOps=new p5(this.client,t),this.tableOps=new m5(this.client,t,this.accessDelegation)}async listNamespaces(e){return this.namespaceOps.listNamespaces(e)}async createNamespace(e,t){return this.namespaceOps.createNamespace(e,t)}async dropNamespace(e){await this.namespaceOps.dropNamespace(e)}async loadNamespaceMetadata(e){return this.namespaceOps.loadNamespaceMetadata(e)}async listTables(e){return this.tableOps.listTables(e)}
266async createTable(e,t){return this.tableOps.createTable(e,t)}async updateTable(e,t){return this.tableOps.updateTable(e,t)}async dropTable(e,t){await this.tableOps.dropTable(e,t)}async loadTable(e){return this.tableOps.loadTable(e)}async namespaceExists(e){return this.namespaceOps.namespaceExists(e)}async tableExists(e){return this.tableOps.tableExists(e)}async createNamespaceIfNotExists(e,t){return this.namespaceOps.createNamespaceIfNotExists(e,t)}async createTableIfNotExists(e,t){return this.tableOps.createTableIfNotExists(e,t)}},sf=class extends Error{constructor(e,t="storage",n,r){super(e),this.__isStorageError=!0,this.namespace=t,this.name=t==="vectors"?"StorageVectorsError":"StorageError",this.status=n,this.statusCode=r}};function of(e){return typeof e=="object"&&e!==null&&"__isStorageError"in e}var Bc=class extends sf{constructor(e,t,n,r="storage"){super(e,r,t,n),this.name=r==="vectors"?"StorageVectorsApiError":"StorageApiError",this.status=t,this.statusCode=n}toJSON(){return{name:this.name,message:this.message,status:this.status,statusCode:this.statusCode}}},LC=class extends sf{constructor(e,t,n="storage"){super(e,n),this.name=n==="vectors"?"StorageVectorsUnknownError":"StorageUnknownError",this.originalError=t}};const v5=e=>e?(...t)=>e(...t):(...t)=>fetch(...t),y5=e=>{if(typeof e!="object"||e===null)return!1;const t=Object.getPrototypeOf(e);return(t===null||t===Object.prototype||Object.getPrototypeOf(t)===null)&&!(Symbol.toStringTag in e)&&!(Symbol.iterator in e)},fm=e=>{if(Array.isArray(e))return e.map(n=>fm(n));if(typeof e=="function"||e!==Object(e))return e;const t={};return Object.entries(e).forEach(([n,r])=>{const s=n.replace(/([-_][a-z])/gi,o=>o.toUpperCase().replace(/[-_]/g,""));t[s]=fm(r)}),t},w5=e=>!e||typeof e!="string"||e.length===0||e.length>100||e.trim()!==e||e.includes("/")||e.includes("\\")?!1:/^[\w!.\*'() &$@=;:+,?-]+$/.test(e);function Il(e){"@babel/helpers - typeof";return Il=typeof Symbol=="function"&&typeof Symbol.iterator=="symbol"?function(t){return typeof t}:function(t){return t&&typeof Symbol=="function"&&t.constructor===Symbol&&t!==Symbol.prototype?"symbol":typeof t},Il(e)}function b5(e,t){if(Il(e)!="object"||!e)return e;var n=e[Symbol.toPrimitive];if(n!==void 0){var r=n.call(e,t||"default");if(Il(r)!="object")return r;throw new TypeError("@@toPrimitive must return a primitive value.")}return(t==="string"?String:Number)(e)}function x5(e){var t=b5(e,"string");return Il(t)=="symbol"?t:t+""}function _5(e,t,n){return(t=x5(t))in e?Object.defineProperty(e,t,{value:n,enumerable:!0,configurable:!0,writable:!0}):e[t]=n,e}function x0(e,t){var n=Object.keys(e);if(Object.getOwnPropertySymbols){var r=Object.getOwnPropertySymbols(e);t&&(r=r.filter(function(s){return Object.getOwnPropertyDescriptor(e,s).enumerable})),n.push.apply(n,r)}return n}function oe(e){for(var t=1;t<arguments.length;t++){var n=arguments[t]!=null?arguments[t]:{};t%2?x0(Object(n),!0).forEach(function(r){_5(e,r,n[r])}):Object.getOwnPropertyDescriptors?Object.defineProperties(e,Object.getOwnPropertyDescriptors(n)):x0(Object(n)).forEach(function(r){Object.defineProperty(e,r,Object.getOwnPropertyDescriptor(n,r))})}return e}const _0=e=>{var t;return e.msg||e.message||e.error_description||(typeof e.error=="string"?e.error:(t=e.error)===null||t===void 0?void 0:t.message)||JSON.stringify(e)},S5=async(e,t,n,r)=>{if(e&&typeof e=="object"&&"status"in e&&"ok"in e&&typeof e.status=="number"&&!(n!=null&&n.noResolveJson)){const s=e,o=s.status||500;if(typeof s.json=="function")s.json().then(i=>{const a=(i==null?void 0:i.statusCode)||(i==null?void 0:i.code)||o+"";t(new Bc(_0(i),o,a,r))}).catch(()=>{if(r==="vectors"){const i=o+"";t(new Bc(s.statusText||`HTTP ${o} error`,o,i,r))}else{const i=o+"";t(new Bc(s.statusText||`HTTP ${o} error`,o,i,r))}});else{const i=o+"";t(new Bc(s.statusText||`HTTP ${o} error`,o,i,r))}}else t(new LC(_0(e),e,r))},E5=(e,t,n,r)=>{const s={method:e,headers:(t==null?void 0:t.headers)||{}};return e==="GET"||e==="HEAD"||!r?oe(oe({},s),n):(y5(r)?(s.headers=oe({"Content-Type":"application/json"},t==null?void 0:t.headers),s.body=JSON.stringify(r)):s.body=r,t!=null&&t.duplex&&(s.duplex=t.duplex),oe(oe({},s),n))};async function $a(e,t,n,r,s,o,i){return new Promise((a,l)=>{e(n,E5(t,r,s,o)).then(c=>{if(!c.ok)throw c;if(r!=null&&r.noResolveJson)return c;if(i==="vectors"){const u=c.headers.get("content-type");if(c.headers.get("content-length")==="0"||c.status===204)return{};if(!u||!u.includes("application/json"))return{}}return c.json()}).then(c=>a(c)).catch(c=>S5(c,l,r,i))})}function $C(e="storage"){return{get:async(t,n,r,s)=>$a(t,"GET",n,r,s,void 0,e),post:async(t,n,r,s,o)=>$a(t,"POST",n,s,o,r,e),put:async(t,n,r,s,o)=>$a(t,"PUT",n,s,o,r,e),head:async(t,n,r,s)=>$a(t,"HEAD",n,oe(oe({},r),{},{noResolveJson:!0}),s,void 0,e),remove:async(t,n,r,s,o)=>$a(t,"DELETE",n,s,o,r,e)}}const k5=$C("storage"),{get:Dl,post:$n,put:hm,head:C5,remove:_v}=k5,tn=$C("vectors");var ca=class{constructor(e,t={},n,r="storage"){this.shouldThrowOnError=!1,this.url=e,this.headers=t,this.fetch=v5(n),this.namespace=r}throwOnError(){return this.shouldThrowOnError=!0,this}async handleOperation(e){var t=this;try{return{data:await e(),error:null}}catch(n){if(t.shouldThrowOnError)throw n;if(of(n))return{data:null,error:n};throw n}}},T5=class{constructor(e,t){this.downloadFn=e,this.shouldThrowOnError=t}then(e,t){return this.execute().then(e,t)}async execute(){var e=this;try{return{data:(await e.downloadFn()).body,error:null}}catch(t){if(e.shouldThrowOnError)throw t;
266if(of(t))return{data:null,error:t};throw t}}};let FC;FC=Symbol.toStringTag;var R5=class{constructor(e,t){this.downloadFn=e,this.shouldThrowOnError=t,this[FC]="BlobDownloadBuilder",this.promise=null}asStream(){return new T5(this.downloadFn,this.shouldThrowOnError)}then(e,t){return this.getPromise().then(e,t)}catch(e){return this.getPromise().catch(e)}finally(e){return this.getPromise().finally(e)}getPromise(){return this.promise||(this.promise=this.execute()),this.promise}async execute(){var e=this;try{return{data:await(await e.downloadFn()).blob(),error:null}}catch(t){if(e.shouldThrowOnError)throw t;if(of(t))return{data:null,error:t};throw t}}};const P5={limit:100,offset:0,sortBy:{column:"name",order:"asc"}},S0={cacheControl:"3600",contentType:"text/plain;charset=UTF-8",upsert:!1};var N5=class extends ca{constructor(e,t={},n,r){super(e,t,r,"storage"),this.bucketId=n}async uploadOrUpdate(e,t,n,r){var s=this;return s.handleOperation(async()=>{let o;const i=oe(oe({},S0),r);let a=oe(oe({},s.headers),e==="POST"&&{"x-upsert":String(i.upsert)});const l=i.metadata;typeof Blob<"u"&&n instanceof Blob?(o=new FormData,o.append("cacheControl",i.cacheControl),l&&o.append("metadata",s.encodeMetadata(l)),o.append("",n)):typeof FormData<"u"&&n instanceof FormData?(o=n,o.has("cacheControl")||o.append("cacheControl",i.cacheControl),l&&!o.has("metadata")&&o.append("metadata",s.encodeMetadata(l))):(o=n,a["cache-control"]=`max-age=${i.cacheControl}`,a["content-type"]=i.contentType,l&&(a["x-metadata"]=s.toBase64(s.encodeMetadata(l))),(typeof ReadableStream<"u"&&o instanceof ReadableStream||o&&typeof o=="object"&&"pipe"in o&&typeof o.pipe=="function")&&!i.duplex&&(i.duplex="half")),r!=null&&r.headers&&(a=oe(oe({},a),r.headers));const c=s._removeEmptyFolders(t),u=s._getFinalPath(c),d=await(e=="PUT"?hm:$n)(s.fetch,`${s.url}/object/${u}`,o,oe({headers:a},i!=null&&i.duplex?{duplex:i.duplex}:{}));return{path:c,id:d.Id,fullPath:d.Key}})}async upload(e,t,n){return this.uploadOrUpdate("POST",e,t,n)}async uploadToSignedUrl(e,t,n,r){var s=this;const o=s._removeEmptyFolders(e),i=s._getFinalPath(o),a=new URL(s.url+`/object/upload/sign/${i}`);return a.searchParams.set("token",t),s.handleOperation(async()=>{let l;const c=oe({upsert:S0.upsert},r),u=oe(oe({},s.headers),{"x-upsert":String(c.upsert)});return typeof Blob<"u"&&n instanceof Blob?(l=new FormData,l.append("cacheControl",c.cacheControl),l.append("",n)):typeof FormData<"u"&&n instanceof FormData?(l=n,l.append("cacheControl",c.cacheControl)):(l=n,u["cache-control"]=`max-age=${c.cacheControl}`,u["content-type"]=c.contentType),{path:o,fullPath:(await hm(s.fetch,a.toString(),l,{headers:u})).Key}})}async createSignedUploadUrl(e,t){var n=this;return n.handleOperation(async()=>{let r=n._getFinalPath(e);const s=oe({},n.headers);t!=null&&t.upsert&&(s["x-upsert"]="true");const o=await $n(n.fetch,`${n.url}/object/upload/sign/${r}`,{},{headers:s}),i=new URL(n.url+o.url),a=i.searchParams.get("token");if(!a)throw new sf("No token returned by API");return{signedUrl:i.toString(),path:e,token:a}})}async update(e,t,n){return this.uploadOrUpdate("PUT",e,t,n)}async move(e,t,n){var r=this;return r.handleOperation(async()=>await $n(r.fetch,`${r.url}/object/move`,{bucketId:r.bucketId,sourceKey:e,destinationKey:t,de
266stinationBucket:n==null?void 0:n.destinationBucket},{headers:r.headers}))}async copy(e,t,n){var r=this;return r.handleOperation(async()=>({path:(await $n(r.fetch,`${r.url}/object/copy`,{bucketId:r.bucketId,sourceKey:e,destinationKey:t,destinationBucket:n==null?void 0:n.destinationBucket},{headers:r.headers})).Key}))}async createSignedUrl(e,t,n){var r=this;return r.handleOperation(async()=>{let s=r._getFinalPath(e),o=await $n(r.fetch,`${r.url}/object/sign/${s}`,oe({expiresIn:t},n!=null&&n.transform?{transform:n.transform}:{}),{headers:r.headers});const i=n!=null&&n.download?`&download=${n.download===!0?"":n.download}`:"";return{signedUrl:encodeURI(`${r.url}${o.signedURL}${i}`)}})}async createSignedUrls(e,t,n){var r=this;return r.handleOperation(async()=>{const s=await $n(r.fetch,`${r.url}/object/sign/${r.bucketId}`,{expiresIn:t,paths:e},{headers:r.headers}),o=n!=null&&n.download?`&download=${n.download===!0?"":n.download}`:"";return s.map(i=>oe(oe({},i),{},{signedUrl:i.signedURL?encodeURI(`${r.url}${i.signedURL}${o}`):null}))})}download(e,t){const n=typeof(t==null?void 0:t.transform)<"u"?"render/image/authenticated":"object",r=this.transformOptsToQueryString((t==null?void 0:t.transform)||{}),s=r?`?${r}`:"",o=this._getFinalPath(e),i=()=>Dl(this.fetch,`${this.url}/${n}/${o}${s}`,{headers:this.headers,noResolveJson:!0});return new R5(i,this.shouldThrowOnError)}async info(e){var t=this;const n=t._getFinalPath(e);return t.handleOperation(async()=>fm(await Dl(t.fetch,`${t.url}/object/info/${n}`,{headers:t.headers})))}async exists(e){var t=this;const n=t._getFinalPath(e);try{return await C5(t.fetch,`${t.url}/object/${n}`,{headers:t.headers}),{data:!0,error:null}}catch(r){if(t.shouldThrowOnError)throw r;if(of(r)&&r instanceof LC){const s=r.originalError;if([400,404].includes(s==null?void 0:s.status))return{data:!1,error:r}}throw r}}getPublicUrl(e,t){const n=this._getFinalPath(e),r=[],s=t!=null&&t.download?`download=${t.download===!0?"":t.download}`:"";s!==""&&r.push(s);const o=typeof(t==null?void 0:t.transform)<"u"?"render/image":"object",i=this.transformOptsToQueryString((t==null?void 0:t.transform)||{});i!==""&&r.push(i);let a=r.join("&");return a!==""&&(a=`?${a}`),{data:{publicUrl:encodeURI(`${this.url}/${o}/public/${n}${a}`)}}}async remove(e){var t=this;return t.handleOperation(async()=>await _v(t.fetch,`${t.url}/object/${t.bucketId}`,{prefixes:e},{headers:t.headers}))}async list(e,t,n){var r=this;return r.handleOperation(async()=>{const s=oe(oe(oe({},P5),t),{},{prefix:e||""});return await $n(r.fetch,`${r.url}/object/list/${r.bucketId}`,s,{headers:r.headers},n)})}async listV2(e,t){var n=this;return n.handleOperation(async()=>{const r=oe({},e);return await $n(n.fetch,`${n.url}/object/list-v2/${n.bucketId}`,r,{headers:n.headers},t)})}encodeMetadata(e){return JSON.stringify(e)}toBase64(e){return typeof Buffer<"u"?Buffer.from(e).toString("base64"):btoa(e)}_getFinalPath(e){return`${this.bucketId}/${e.replace(/^\/+/,"")}`}_removeEmptyFolders(e){return e.replace(/^\/|\/$/g,"").replace(/\/+/g,"/")}transformOptsToQueryString(e){const t=[];return e.width&&t.push(`width=${e.width}`),e.height&&t.push(`height=${e.height}`),e.resize&&t.push(`resize=${e.resize}`),e.format&&t.push(`format=${e.format}`),e.quality&&t.push(`quality=${e.quality}`),t.join("&")}};const A5="2.95.2",oc={"X-Client-Info":`storage-js/${A5}`};var O5=class extends ca{constructor(e,t={},n,r){const s=new URL(e);r!=null&&r.useNewHostname&&/supabase\.(co|in|red)$/.test(s.hostname)&&!s.hostname.includes("storage.supabase.")&&(s.hostname=s.hostname.replace("supabase.","storage.supabase."));const o=s.href.replace(/\/$/,""),i=oe(oe({},oc),t);super(o,i,n,"storage")}async listBuckets(e){var t=this;return t.handleOperation(async()=>{const n=t.listBucketOptionsToQueryString(e);return await Dl(t.fetch,`${t.url}/bucket${n}`,{headers:t.headers})})}async getBucket(e){var t=this;return t.handleOperation(async()=>await Dl(t.fetch,`${t.url}/bucket/${e}`,{headers:t.headers}))}async createBucket(e,t={public:!1}){var n=this;return n.handleOperation(async()=>await $n(n.fetch,`${n.url}/bucket`,{id:e,name:e,type:t.type,public:t.public,file_size_limit:t.fileSizeLimit,allowed_mime_types:t.allowedMimeTypes},{headers:n.headers}))}async updateBucket(e,t){var n=this;return n.handleOperation(async()=>await hm(n.fetch,`${n.url}/bucket/${e}`,{id:e,name:e,public:t.public,file_size_limit:t.fileSizeLimit,allowed_mime_types:t.allowedMimeTypes},{headers:n.headers}))}async emptyBucket(e){var t=this;return t.handleOperation(async()=>await $n(t.fetch,`${t.url}/bucket/${e}/empty`,{},{headers:t.headers}))}async deleteBucket(e){var t=this;return t.handleOperation(async()=>await _v(t.fetch,`${t.url}/bucket/${e}`,{},{headers:t.headers}))}listBucketOptionsToQueryString(e){const t={};return e&&("limit"in e&&(t.limit=String(e.limit)),"offset"in e&&(t.offset=String(e.offset)),e.search&&(t.search=e.search),e.sortColumn&&(t.sortColumn=e.sortColumn),e.sortOrder&&(t.sortOrder=e.sortOrder)),Object.keys(t).length>0?"?"+new URLSearchParams(t).toString():""}},j5=class extends ca{constructor(e,t={},n){const r=e.replace(/\/$/,""),s=oe(oe({},oc),t);super(r,s,n,"storage")}async createBucket(e){var t=this;return t.handleOperation(async()=>await $n(t.fetch,`${t.url}/bucket`,{name:e},{headers:t.headers}))}async listBuckets(e){var t=this;return t.handleOperation(async()=>{const n=new URLSearchParams;(e==null?void 0:e.limit)!==void 0&&n.set("limit",e.limit.toString()),(e==null?void 0:e.offset)!==void 0&&n.set("offset",e.offset.toString()),e!=null&&e.sortColumn&&n.set("sortColumn",e.sortColumn),e!=null&&e.sortOrder&&n.set("sortOrder",e.sortOrder),e!=null&&e.search&&n.set("search",e.search);const r=n.toString(),s=r?`${t.url}/bucket?${r}`:`${t.url}/bucket`;return await Dl(t.fetch,s,{headers:t.headers})})}async deleteBucket(e){var t=this;return t.handleOperation(async()=>await _v(t.fetch,`${t.url}/bucket/${e}`,{},{headers:t.headers}))}from(e){var t=this;if(!w5(e))throw new sf("Invalid bucket name: File, folder, and bucket names must follow AWS object key naming guidelines and should avoid the use of any other characters.");const n=new g5({baseUrl:this.url,catalogName:e,auth:{type:"custom",getHeaders:async()=>t.headers},fetch:this.fetch}
266),r=this.shouldThrowOnError;return new Proxy(n,{get(s,o){const i=s[o];return typeof i!="function"?i:async(...a)=>{try{return{data:await i.apply(s,a),error:null}}catch(l){if(r)throw l;return{data:null,error:l}}}}})}},I5=class extends ca{constructor(e,t={},n){const r=e.replace(/\/$/,""),s=oe(oe({},oc),{},{"Content-Type":"application/json"},t);super(r,s,n,"vectors")}async createIndex(e){var t=this;return t.handleOperation(async()=>await tn.post(t.fetch,`${t.url}/CreateIndex`,e,{headers:t.headers})||{})}async getIndex(e,t){var n=this;return n.handleOperation(async()=>await tn.post(n.fetch,`${n.url}/GetIndex`,{vectorBucketName:e,indexName:t},{headers:n.headers}))}async listIndexes(e){var t=this;return t.handleOperation(async()=>await tn.post(t.fetch,`${t.url}/ListIndexes`,e,{headers:t.headers}))}async deleteIndex(e,t){var n=this;return n.handleOperation(async()=>await tn.post(n.fetch,`${n.url}/DeleteIndex`,{vectorBucketName:e,indexName:t},{headers:n.headers})||{})}},D5=class extends ca{constructor(e,t={},n){const r=e.replace(/\/$/,""),s=oe(oe({},oc),{},{"Content-Type":"application/json"},t);super(r,s,n,"vectors")}async putVectors(e){var t=this;if(e.vectors.length<1||e.vectors.length>500)throw new Error("Vector batch size must be between 1 and 500 items");return t.handleOperation(async()=>await tn.post(t.fetch,`${t.url}/PutVectors`,e,{headers:t.headers})||{})}async getVectors(e){var t=this;return t.handleOperation(async()=>await tn.post(t.fetch,`${t.url}/GetVectors`,e,{headers:t.headers}))}async listVectors(e){var t=this;if(e.segmentCount!==void 0){if(e.segmentCount<1||e.segmentCount>16)throw new Error("segmentCount must be between 1 and 16");if(e.segmentIndex!==void 0&&(e.segmentIndex<0||e.segmentIndex>=e.segmentCount))throw new Error(`segmentIndex must be between 0 and ${e.segmentCount-1}`)}return t.handleOperation(async()=>await tn.post(t.fetch,`${t.url}/ListVectors`,e,{headers:t.headers}))}async queryVectors(e){var t=this;return t.handleOperation(async()=>await tn.post(t.fetch,`${t.url}/QueryVectors`,e,{headers:t.headers}))}async deleteVectors(e){var t=this;if(e.keys.length<1||e.keys.length>500)throw new Error("Keys batch size must be between 1 and 500 items");return t.handleOperation(async()=>await tn.post(t.fetch,`${t.url}/DeleteVectors`,e,{headers:t.headers})||{})}},M5=class extends ca{constructor(e,t={},n){const r=e.replace(/\/$/,""),s=oe(oe({},oc),{},{"Content-Type":"application/json"},t);super(r,s,n,"vectors")}async createBucket(e){var t=this;return t.handleOperation(async()=>await tn.post(t.fetch,`${t.url}/CreateVectorBucket`,{vectorBucketName:e},{headers:t.headers})||{})}async getBucket(e){var t=this;return t.handleOperation(async()=>await tn.post(t.fetch,`${t.url}/GetVectorBucket`,{vectorBucketName:e},{headers:t.headers}))}async listBuckets(e={}){var t=this;return t.handleOperation(async()=>await tn.post(t.fetch,`${t.url}/ListVectorBuckets`,e,{headers:t.headers}))}async deleteBucket(e){var t=this;return t.handleOperation(async()=>await tn.post(t.fetch,`${t.url}/DeleteVectorBucket`,{vectorBucketName:e},{headers:t.headers})||{})}},L5=class extends M5{constructor(e,t={}){super(e,t.headers||{},t.fetch)}from(e){return new $5(this.url,this.headers,e,this.fetch)}async createBucket(e){var t=()=>super.createBucket,n=this;return t().call(n,e)}async getBucket(e){var t=()=>super.getBucket,n=this;return t().call(n,e)}async listBuckets(e={}){var t=()=>super.listBuckets,n=this;return t().call(n,e)}async deleteBucket(e){var t=()=>super.deleteBucket,n=this;return t().call(n,e)}},$5=class extends I5{constructor(e,t,n,r){super(e,t,r),this.vectorBucketName=n}async createIndex(e){var t=()=>super.createIndex,n=this;return t().call(n,oe(oe({},e),{},{vectorBucketName:n.vectorBucketName}))}async listIndexes(e={}){var t=()=>super.listIndexes,n=this;return t().call(n,oe(oe({},e),{},{vectorBucketName:n.vectorBucketName}))}async getIndex(e){var t=()=>super.getIndex,n=this;return t().call(n,n.vectorBucketName,e)}async deleteIndex(e){var t=()=>super.deleteIndex,n=this;return t().call(n,n.vectorBucketName,e)}index(e){return new F5(this.url,this.headers,this.vectorBucketName,e,this.fetch)}}
266,F5=class extends D5{constructor(e,t,n,r,s){super(e,t,s),this.vectorBucketName=n,this.indexName=r}async putVectors(e){var t=()=>super.putVectors,n=this;return t().call(n,oe(oe({},e),{},{vectorBucketName:n.vectorBucketName,indexName:n.indexName}))}async getVectors(e){var t=()=>super.getVectors,n=this;return t().call(n,oe(oe({},e),{},{vectorBucketName:n.vectorBucketName,indexName:n.indexName}))}async listVectors(e={}){var t=()=>super.listVectors,n=this;return t().call(n,oe(oe({},e),{},{vectorBucketName:n.vectorBucketName,indexName:n.indexName}))}async queryVectors(e){var t=()=>super.queryVectors,n=this;return t().call(n,oe(oe({},e),{},{vectorBucketName:n.vectorBucketName,indexName:n.indexName}))}async deleteVectors(e){var t=()=>super.deleteVectors,n=this;return t().call(n,oe(oe({},e),{},{vectorBucketName:n.vectorBucketName,indexName:n.indexName}))}},U5=class extends O5{constructor(e,t={},n,r){super(e,t,n,r)}from(e){return new N5(this.url,this.headers,e,this.fetch)}get vectors(){return new L5(this.url+"/vector",{headers:this.headers,fetch:this.fetch})}get analytics(){return new j5(this.url+"/iceberg",this.headers,this.fetch)}};const UC="2.95.2",Xo=30*1e3,pm=3,xh=pm*Xo,B5="http://localhost:9999",z5="supabase.auth.token",W5={"X-Client-Info":`gotrue-js/${UC}`},mm="X-Supabase-Api-Version",BC={"2024-01-01":{timestamp:Date.parse("2024-01-01T00:00:00.0Z"),name:"2024-01-01"}},H5=/^([a-z0-9_-]{4})*($|[a-z0-9_-]{3}$|[a-z0-9_-]{2}$)$/i,V5=10*60*1e3;class Ml extends Error{constructor(t,n,r){super(t),this.__isAuthError=!0,this.name="AuthError",this.status=n,this.code=r}}function te(e){return typeof e=="object"&&e!==null&&"__isAuthError"in e}class q5 extends Ml{constructor(t,n,r){super(t,n,r),this.name="AuthApiError",this.status=n,this.code=r}}function K5(e){return te(e)&&e.name==="AuthApiError"}class io extends Ml{constructor(t,n){super(t),this.name="AuthUnknownError",this.originalError=n}}class Zr extends Ml{constructor(t,n,r,s){super(t,r,s),this.name=n,this.status=r}}class Jt extends Zr{constructor(){super("Auth session missing!","AuthSessionMissingError",400,void 0)}}function _h(e){return te(e)&&e.name==="AuthSessionMissingError"}class qo extends Zr{constructor(){super("Auth session or user missing","AuthInvalidToken
266ResponseError",500,void 0)}}class zc extends Zr{constructor(t){super(t,"AuthInvalidCredentialsError",400,void 0)}}class Wc extends Zr{constructor(t,n=null){super(t,"AuthImplicitGrantRedirectError",500,void 0),this.details=null,this.details=n}toJSON(){return{name:this.name,message:this.message,status:this.status,details:this.details}}}function G5(e){return te(e)&&e.name==="AuthImplicitGrantRedirectError"}class E0 extends Zr{constructor(t,n=null){super(t,"AuthPKCEGrantCodeExchangeError",500,void 0),this.details=null,this.details=n}toJSON(){return{name:this.name,message:this.message,status:this.status,details:this.details}}}class Y5 extends Zr{constructor(){super("PKCE code verifier not found in storage. This can happen if the auth flow was initiated in a different browser or device, or if the storage was cleared. For SSR frameworks (Next.js, SvelteKit, etc.), use @supabase/ssr on both the server and client to store the code verifier in cookies.","AuthPKCECodeVerifierMissingError",400,"pkce_code_verifier_not_found")}}class gm extends Zr{constructor(t,n){super(t,"AuthRetryableFetchError",n,void 0)}}function Sh(e){return te(e)&&e.name==="AuthRetryableFetchError"}class k0 extends Zr{constructor(t,n,r){super(t,"AuthWeakPasswordError",n,"weak_password"),this.reasons=r}}class vm extends Zr{constructor(t){super(t,"AuthInvalidJwtError",400,"invalid_jwt")}}const ed="ABCDEFGHIJKLMNOPQRSTUVWXYZabcdefghijklmnopqrstuvwxyz0123456789-_".split(""),C0=` 267\r=`.split(""),Z5=(()=>{const e=new Array(128);for(let t=0;t<e.length;t+=1)e[t]=-1;for(let t=0;t<C0.length;t+=1)e[C0[t].charCodeAt(0)]=-2;for(let t=0;t<ed.length;t+=1)e[ed[t].charCodeAt(0)]=t;return e})();function T0(e,t,n){if(e!==null)for(t.queue=t.queue<<8|e,t.queuedBits+=8;t.queuedBits>=6;){const r=t.queue>>t.queuedBits-6&63;n(ed[r]),t.queuedBits-=6}else if(t.queuedBits>0)for(t.queue=t.queue<<6-t.queuedBits,t.queuedBits=6;t.queuedBits>=6;){const r=t.queue>>t.queuedBits-6&63;n(ed[r]),t.queuedBits-=6}}function zC(e,t,n){const r=Z5[e];if(r>-1)for(t.queue=t.queue<<6|r,t.queuedBits+=6;t.queuedBits>=8;)n(t.queue>>t.queuedBits-8&255),t.queuedBits-=8;else{if(r===-2)return;throw new Error(`Invalid Base64-URL character "${String.fromCharCode(e)}"`)}}function R0(e){const t=[],n=i=>{t.push(String.fromCodePoint(i))},r={utf8seq:0,codepoint:0},s={queue:0,queuedBits:0},o=i=>{X5(i,r,n)};for(let i=0;i<e.length;i+=1)zC(e.charCodeAt(i),s,o);return t.join("")}function Q5(e,t){if(e<=127){t(e);return}else if(e<=2047){t(192|e>>6),t(128|e&63);return}else if(e<=65535){t(224|e>>12),t(128|e>>6&63),t(128|e&63);return}else if(e<=1114111){t(240|e>>18),t(128|e>>12&63),t(128|e>>6&63),t(128|e&63);return}throw new Error(`Unrecognized Unicode codepoint: ${e.toString(16)}`)}function J5(e,t){for(let n=0;n<e.length;n+=1){let r=e.charCodeAt(n);if(r>55295&&r<=56319){const s=(r-55296)*1024&65535;r=(e.charCodeAt(n+1)-56320&65535|s)+65536,n+=1}Q5(r,t)}}function X5(e,t,n){if(t.utf8seq===0){if(e<=127){n(e);return}for(let r=1;r<6;r+=1)if(!(e>>7-r&1)){t.utf8seq=r;break}if(t.utf8seq===2)t.codepoint=e&31;else if(t.utf8seq===3)t.codepoint=e&15;else if(t.utf8seq===4)t.codepoint=e&7;else throw new Error("Invalid UTF-8 sequence");t.utf8seq-=1}else if(t.utf8seq>0){if(e<=127)throw new Error("Invalid UTF-8 sequence");t.codepoint=t.codepoint<<6|e&63,t.utf8seq-=1,t.utf8seq===0&&n(t.codepoint)}}function Ci(e){const t=[],n={queue:0,queuedBits:0},r=s=>{t.push(s)};for(let s=0;s<e.length;s+=1)zC(e.charCodeAt(s),n,r);return new Uint8Array(t)}function eU(e){const t=[];return J5(e,n=>t.push(n)),new Uint8Array(t)}function uo(e){const t=[],n={queue:0,queuedBits:0},r=s=>{t.push(s)};return e.forEach(s=>T0(s,n,r)),T0(null,n,r),t.join("")}function tU(e){return Math.round(Date.now()/1e3)+e}function nU(){return Symbol("auth-callback")}const pt=()=>typeof window<"u"&&typeof document<"u",Xs={tested:!1,writable:!1},WC=()=>{if(!pt())return!1;try{if(typeof globalThis.localStorage!="object")return!1}catch{return!1}if(Xs.tested)return Xs.writable;const e=`lswt-${Math.random()}${Math.random()}`;try{globalThis.localStorage.setItem(e,e),globalThis.localStorage.removeItem(e),Xs.tested=!0,Xs.writable=!0}catch{Xs.tested=!0,Xs.writable=!1}return Xs.writable};function rU(e){const t={},n=new URL(e);if(n.hash&&n.hash[0]==="#")try{new URLSearchParams(n.hash.substring(1)).forEac
267h((s,o)=>{t[o]=s})}catch{}return n.searchParams.forEach((r,s)=>{t[s]=r}),t}const HC=e=>e?(...t)=>e(...t):(...t)=>fetch(...t),sU=e=>typeof e=="object"&&e!==null&&"status"in e&&"ok"in e&&"json"in e&&typeof e.json=="function",ei=async(e,t,n)=>{await e.setItem(t,JSON.stringify(n))},eo=async(e,t)=>{const n=await e.getItem(t);if(!n)return null;try{return JSON.parse(n)}catch{return n}},ht=async(e,t)=>{await e.removeItem(t)};class af{constructor(){this.promise=new af.promiseConstructor((t,n)=>{this.resolve=t,this.reject=n})}}af.promiseConstructor=Promise;function Hc(e){const t=e.split(".");if(t.length!==3)throw new vm("Invalid JWT structure");for(let r=0;r<t.length;r++)if(!H5.test(t[r]))throw new vm("JWT not in base64url format");return{header:JSON.parse(R0(t[0])),payload:JSON.parse(R0(t[1])),signature:Ci(t[2]),raw:{header:t[0],payload:t[1]}}}async function oU(e){return await new Promise(t=>{setTimeout(()=>t(null),e)})}function iU(e,t){return new Promise((r,s)=>{(async()=>{for(let o=0;o<1/0;o++)try{const i=await e(o);if(!t(o,null,i)){r(i);return}}catch(i){if(!t(o,i)){s(i);return}}})()})}function aU(e){return("0"+e.toString(16)).substr(-2)}function lU(){const t=new Uint32Array(56);if(typeof crypto>"u"){const n="ABCDEFGHIJKLMNOPQRSTUVWXYZabcdefghijklmnopqrstuvwxyz0123456789-._~",r=n.length;let s="";for(let o=0;o<56;o++)s+=n.charAt(Math.floor(Math.random()*r));return s}return crypto.getRandomValues(t),Array.from(t,aU).join("")}async function cU(e){const n=new TextEncoder().encode(e),r=await crypto.subtle.digest("SHA-256",n),s=new Uint8Array(r);return Array.from(s).map(o=>String.fromCharCode(o)).join("")}async function uU(e){if(!(typeof crypto<"u"&&typeof crypto.subtle<"u"&&typeof TextEncoder<"u"))return console.warn("WebCrypto API is not supported. Code challenge method will default to use plain instead of sha256."),e;const n=await cU(e);return btoa(n).replace(/\+/g,"-").replace(/\//g,"_").replace(/=+$/,"")}async function Ko(e,t,n=!1){const r=lU();let s=r;n&&(s+="/PASSWORD_RECOVERY"),await ei(e,`${t}-code-verifier`,s);const o=await uU(r);return[o,r===o?"plain":"s256"]}const dU=/^2[0-9]{3}-(0[1-9]|1[0-2])-(0[1-9]|1[0-9]|2[0-9]|3[0-1])$/i;function fU(e){const t=e.headers.get(mm);if(!t||!t.match(dU))return null;try{return new Date(`${t}T00:00:00.0Z`)}catch{return null}}function hU(e){if(!e)throw new Error("Missing exp claim");const t=Math.floor(Date.now()/1e3);if(e<=t)throw new Error("JWT has expired")}function pU(e){switch(e){case"RS256":return{name:"RSASSA-PKCS1-v1_5",hash:{name:"SHA-256"}};case"ES256":return{name:"ECDSA",namedCurve:"P-256",hash:{name:"SHA-256"}};default:throw new Error("Invalid alg claim")}}const mU=/^[0-9a-f]{8}-[0-9a-f]{4}-[0-9a-f]{4}-[0-9a-f]{4}-[0-9a-f]{12}$/;function Go(e){if(!mU.test(e))throw new Error("@supabase/auth-js: Expected parameter to be UUID but is not")}function Eh(){const e={};return new Proxy(e,{get:(t,n)=>{if(n==="__isUserNotAvailableProxy")return!0;if(typeof n=="symbol"){const r=n.toString();if(r==="Symbol(Symbol.toPrimitive)"||r==="Symbol(Symbol.toStringTag)"||r==="Symbol(util.inspect.custom)")return}throw new Error(`@supabase/auth-js: client was created with userStorage option and there was no user stored in the user storage. Accessing the "${n}" property of the session object is not supported. Please use getUser() instead.`)},set:(t,n)=>{throw new Error(`@supabase/auth-js: client was created with userStorage option and there was no user stored in the user storage. Setting the "${n}" property of the session object is not supported. Please use getUser() to fetch a user object you can manipulate.`)},deleteProperty:(t,n)=>{throw new Error(`@supabase/auth-js: client was created with userStorage option and there was no user stored in the user storage. Deleting the "${n}" property of the session object is not supported. Please use getUser() to fetch a user object you can manipulate.`)}})}function gU(e,t){return new Proxy(e,{get:(n,r,s)=>{if(r==="__isInsecureUserWarningProxy")return!0;if(typeof r=="symbol"){const o=r.toString();if(o==="Symbol(Symbol.toPrimitive)"||o==="Symbol(Symbol.toStringTag)"||o==="Symbol(util.inspect.custom)"||o==="Symbol(nodejs.util.inspect.custom)")return Reflect.get(n,r,s)}return!t.value&&typeof r=="string"&&(console.warn("Using the user object as returned from supabase.auth.getSession() or from some supabase.auth.onAuthStateChange() events could be insecure! This value comes directly from the storage medium (usually cookies on the server) and may not be authentic. Use supabase.auth.getUser() instead which authenticates the data by contacting the Supabase Auth server."),t.value=!0),Reflect.get(n,r,s)}})}function P0(e){return JSON.parse(JSON.stringify(e))}const so=e=>e.msg||e.message||e.error_description||e.error||JSON.stringify(e),vU=[502,503,504];async function N0(e){var t;if(!sU(e))throw new gm(so(e),0);if(vU.includes(e.status))throw new gm(so(e),e.status);let n;try{n=await e.json()}
267catch(o){throw new io(so(o),o)}let r;const s=fU(e);if(s&&s.getTime()>=BC["2024-01-01"].timestamp&&typeof n=="object"&&n&&typeof n.code=="string"?r=n.code:typeof n=="object"&&n&&typeof n.error_code=="string"&&(r=n.error_code),r){if(r==="weak_password")throw new k0(so(n),e.status,((t=n.weak_password)===null||t===void 0?void 0:t.reasons)||[]);if(r==="session_not_found")throw new Jt}else if(typeof n=="object"&&n&&typeof n.weak_password=="object"&&n.weak_password&&Array.isArray(n.weak_password.reasons)&&n.weak_password.reasons.length&&n.weak_password.reasons.reduce((o,i)=>o&&typeof i=="string",!0))throw new k0(so(n),e.status,n.weak_password.reasons);throw new q5(so(n),e.status||500,r)}const yU=(e,t,n,r)=>{const s={method:e,headers:(t==null?void 0:t.headers)||{}};return e==="GET"?s:(s.headers=Object.assign({"Content-Type":"application/json;charset=UTF-8"},t==null?void 0:t.headers),s.body=JSON.stringify(r),Object.assign(Object.assign({},s),n))};async function se(e,t,n,r){var s;const o=Object.assign({},r==null?void 0:r.headers);o[mm]||(o[mm]=BC["2024-01-01"].name),r!=null&&r.jwt&&(o.Authorization=`Bearer ${r.jwt}`);const i=(s=r==null?void 0:r.query)!==null&&s!==void 0?s:{};r!=null&&r.redirectTo&&(i.redirect_to=r.redirectTo);const a=Object.keys(i).length?"?"+new URLSearchParams(i).toString():"",l=await wU(e,t,n+a,{headers:o,noResolveJson:r==null?void 0:r.noResolveJson},{},r==null?void 0:r.body);return r!=null&&r.xform?r==null?void 0:r.xform(l):{data:Object.assign({},l),error:null}}async function wU(e,t,n,r,s,o){const i=yU(t,r,s,o);let a;try{a=await e(n,Object.assign({},i))}catch(l){throw console.error(l),new gm(so(l),0)}if(a.ok||await N0(a),r!=null&&r.noResolveJson)return a;try{return await a.json()}catch(l){await N0(l)}}function jn(e){var t;let n=null;_U(e)&&(n=Object.assign({},e),e.expires_at||(n.expires_at=tU(e.expires_in)));const r=(t=e.user)!==null&&t!==void 0?t:e;return{data:{session:n,user:r},error:null}}function A0(e){const t=jn(e);return!t.error&&e.weak_password&&typeof e.weak_password=="object"&&Array.isArray(e.weak_password.reasons)&&e.weak_password.reasons.length&&e.weak_password.message&&typeof e.weak_password.message=="string"&&e.weak_password.reasons.reduce((n,r)=>n&&typeof r=="string",!0)&&(t.data.weak_password=e.weak_password),t}function ds(e){var t;return{data:{user:(t=e.user)!==null&&t!==void 0?t:e},error:null}}function bU(e){return{data:e,error:null}}function xU(e){const{action_link:t,email_otp:n,hashed_token:r,redirect_to:s,verification_type:o}=e,i=aa(e,["action_link","email_otp","hashed_token","redirect_to","verification_type"]),a={action_link:t,email_otp:n,hashed_token:r,redirect_to:s,verification_type:o},l=Object.assign({},i);return{data:{properties:a,user:l},error:null}}function O0(e){return e}function _U(e){return e.access_token&&e.refresh_token&&e.expires_in}const kh=["global","local","others"];class SU{constructor({url:t="",headers:n={},fetch:r}){this.url=t,this.headers=n,this.fetch=HC(r),this.mfa={listFactors:this._listFactors.bind(this),deleteFactor:this._deleteFactor.bind(this)},this.oauth={listClients:this._listOAuthClients.bind(this),createClient:this._createOAuthClient.bind(this),getClient:this._getOAuthClient.bind(this),updateClient:this._updateOAuthClient.bind(this),deleteClient:this._deleteOAuthClient.bind(this),regenerateClientSecret:this._regenerateOAuthClientSecret.bind(this)}}async signOut(t,n=kh[0]){if(kh.indexOf(n)<0)throw new Error(`@supabase/auth-js: Parameter scope must be one of ${kh.join(", ")}`);try{return await se(this.fetch,"POST",`${this.url}/logout?scope=${n}`,{headers:this.headers,jwt:t,noResolveJson:!0}),{data:null,error:null}}catch(r){if(te(r))return{data:null,error:r};throw r}}async inviteUserByEmail(t,n={}){try{return await se(this.fetch,"POST",`${this.url}/invite`,{body:{email:t,data:n.data},headers:this.headers,redirectTo:n.redirectTo,xform:ds})}catch(r){if(te(r))return{data:{user:null},error:r};throw r}}async generateLink(t){try{const{options:n}=t,r=aa(t,["options"]),s=Object.assign(Object.assign({},r),n);return"newEmail"in r&&(s.new_email=r==null?void 0:r.newEmail,delete s.newEmail),await se(this.fetch,"POST",`${this.url}/admin/generate_link`,{body:s,headers:this.headers,xform:xU,redirectTo:n==null?void 0:n.redirectTo})}catch(n){if(te(n))return{data:{properties:null,user:null},error:n};throw n}}async createUser(t){try{return await se(this.fetch,"POST",`${this.url}/admin/users`,{body:t,headers:this.headers,xform:ds})}catch(n){if(te(n))return{data:{user:null},error:n};throw n}}async listUsers(t){var n,r,s,o,i,a,l;try{const c={nextPage:null,lastPage:0,total:0},u=await se(this.fetch,"GET",`${this.url}/admin/users`,{headers:this.headers,noResolveJson:!0,query:{page:(r=(n=t==null?void 0:t.page)===null||n===void 0?void 0:n.toString())!==null&&r!==void 0?r:"",per_page:(o=(s=t==null?void 0:t.perPage)===null||s===void 0?void 0:s.toString())!==null&&o!==void 0?o:""},xform:O0});if(u.error)throw u.error;const d=await u.json(),p=(i=u.headers.get("x-total-count"))!==null&&i!==void 0?i:0,h=(l=(a=u.headers.get("link"))===null||a===void 0?void 0:a.split(","))!==null&&l!==void 0?l:[];return h.length>
2670&&(h.forEach(x=>{const v=parseInt(x.split(";")[0].split("=")[1].substring(0,1)),b=JSON.parse(x.split(";")[1].split("=")[1]);c[`${b}Page`]=v}),c.total=parseInt(p)),{data:Object.assign(Object.assign({},d),c),error:null}}catch(c){if(te(c))return{data:{users:[]},error:c};throw c}}async getUserById(t){Go(t);try{return await se(this.fetch,"GET",`${this.url}/admin/users/${t}`,{headers:this.headers,xform:ds})}catch(n){if(te(n))return{data:{user:null},error:n};throw n}}async updateUserById(t,n){Go(t);try{return await se(this.fetch,"PUT",`${this.url}/admin/users/${t}`,{body:n,headers:this.headers,xform:ds})}catch(r){if(te(r))return{data:{user:null},error:r};throw r}}async deleteUser(t,n=!1){Go(t);try{return await se(this.fetch,"DELETE",`${this.url}/admin/users/${t}`,{headers:this.headers,body:{should_soft_delete:n},xform:ds})}catch(r){if(te(r))return{data:{user:null},error:r};throw r}}async _listFactors(t){Go(t.userId);try{const{data:n,error:r}=await se(this.fetch,"GET",`${this.url}/admin/users/${t.userId}/factors`,{headers:this.headers,xform:s=>({data:{factors:s},error:null})});return{data:n,error:r}}catch(n){if(te(n))return{data:null,error:n};throw n}}async _deleteFactor(t){Go(t.userId),Go(t.id);try{return{data:await se(this.fetch,"DELETE",`${this.url}/admin/users/${t.userId}/factors/${t.id}`,{headers:this.headers}),error:null}}catch(n){if(te(n))return{data:null,error:n};throw n}}async _listOAuthClients(t){var n,r,s,o,i,a,l;try{const c={nextPage:null,lastPage:0,total:0},u=await se(this.fetch,"GET",`${this.url}/admin/oauth/clients`,{headers:this.headers,noResolveJson:!0,query:{page:(r=(n=t==null?void 0:t.page)===null||n===void 0?void 0:n.toString())!==null&&r!==void 0?r:"",per_page:(o=(s=t==null?void 0:t.perPage)===null||s===void 0?void 0:s.toString())!==null&&o!==void 0?o:""},xform:O0});if(u.error)throw u.error;const d=await u.json(),p=(i=u.headers.get("x-total-count"))!==null&&i!==void 0?i:0,h=(l=(a=u.headers.get("link"))===null||a===void 0?void 0:a.split(","))!==null&&l!==void 0?l:[];return h.length>0&&(h.forEach(x=>{const v=parseInt(x.split(";")[0].split("=")[1].substring(0,1)),b=JSON.parse(x.split(";")[1].split("=")[1]);c[`${b}Page`]=v}),c.total=parseInt(p)),{data:Object.assign(Object.assign({},d),c),error:null}}catch(c){if(te(c))return{data:{clients:[]},error:c};throw c}}async _createOAuthClient(t){try{return await se(this.fetch,"POST",`${this.url}/admin/oauth/clients`,{body:t,headers:this.headers,xform:n=>({data:n,error:null})})}catch(n){if(te(n))return{data:null,error:n};throw n}}async _getOAuthClient(t){try{return await se(this.fetch,"GET",`${this.url}/admin/oauth/clients/${t}`,{headers:this.headers,xform:n=>({data:n,error:null})})}catch(n){if(te(n))return{data:null,error:n};throw n}}async _updateOAuthClient(t,n){try{return await se(this.fetch,"PUT",`${this.url}/admin/oauth/clients/${t}`,{body:n,headers:this.headers,xform:r=>({data:r,error:null})})}catch(r){if(te(r))return{data:null,error:r};throw r}}async _deleteOAuthClient(t){try{return await se(this.fetch,"DELETE",`${this.url}/admin/oauth/clients/${t}`,{headers:this.headers,noResolveJson:!0}),{data:null,error:null}}catch(n){if(te(n))return{data:null,error:n};throw n}}async _regenerateOAuthClientSecret(t){try{return await se(this.fetch,"POST",`${this.url}/admin/oauth/clients/${t}/regenerate_secret`,{headers:this.headers,xform:n=>({data:n,error:null})})}catch(n){if(te(n))return{data:null,error:n};throw n}}}function j0(e={}){return{getItem:t=>e[t]||null,setItem:(t,n)=>{e[t]=n},removeItem:t=>{delete e[t]}}}const Yo={debug:!!(globalThis&&WC()&&globalThis.localStorage&&globalThis.localStorage.getItem("supabase.gotrue-js.locks.debug")==="true")};class VC extends Error{constructor(t){super(t),this.isAcquireTimeout=!0}}class EU extends VC{}async function kU(e,t,n){Yo.debug&&console.log("@supabase/gotrue-js: navigatorLock: acquire lock",e,t);const r=new globalThis.AbortController;return t>0&&setTimeout(()=>{r.abort(),Yo.debug&&console.log("@supabase/gotrue-js: navigatorLock acquire timed out",e)},t),await Promise.resolve().then(()=>globalThis.navigator.locks.request(e,t===0?{mode:"exclusive",ifAvailable:!0}:{mode:"exclusive",signal:r.signal},async s=>{if(s){Yo.debug&&console.log("@supabase/gotrue-js: navigatorLock: acquired",e,s.name);try{return await n()}finally{Yo.debug&&console.log("@supabase/gotrue-js: navigatorLock: released",e,s.name)}}else{if(t===0)throw Yo.debug&&console.log("@supabase/gotrue-js: navigatorLock: not immediately available",e),new EU(`Acquiring an exclusive Navigator LockManager lock "${e}" immediately failed`);if(Yo.debug)try{const o=await globalThis.navigator.locks.query();console.log("@supabase/gotrue-js: Navigator LockManager state",JSON.stringify(o,null," "))}catch(o){console.warn("@supabase/gotrue-js: Error when querying Navigator LockManager state",o)}return console.warn("@supabase/gotrue-js: Navigator LockManager returned a null lock when using #request without ifAvailable set to true, it appears this browser is not following the LockManager spec https://developer.mozilla.org/en-US/docs/Web/API/LockManager/request"),await n()}}))}function CU(){if(typeof globalThis!="object")try{Object.defineProperty(Object.prototype,"__magic__",{get:function(){return this},configurable:!0}),__magic__.globalThis=__magic__,delete Object.prototype.__magic__}catch{typeof self<"u"&&(self.globalThis=self)}}function qC(e){if(!/^0x[a-fA-F0-9]{40}$/.test(e))throw new Error(`@supabase/auth-js: Address "${e}
267" is invalid.`);return e.toLowerCase()}function TU(e){return parseInt(e,16)}function RU(e){const t=new TextEncoder().encode(e);return"0x"+Array.from(t,r=>r.toString(16).padStart(2,"0")).join("")}function PU(e){var t;const{chainId:n,domain:r,expirationTime:s,issuedAt:o=new Date,nonce:i,notBefore:a,requestId:l,resources:c,scheme:u,uri:d,version:p}=e;{if(!Number.isInteger(n))throw new Error(`@supabase/auth-js: Invalid SIWE message field "chainId". Chain ID must be a EIP-155 chain ID. Provided value: ${n}`);if(!r)throw new Error('@supabase/auth-js: Invalid SIWE message field "domain". Domain must be provided.');if(i&&i.length<8)throw new Error(`@supabase/auth-js: Invalid SIWE message field "nonce". Nonce must be at least 8 characters. Provided value: ${i}`);if(!d)throw new Error('@supabase/auth-js: Invalid SIWE message field "uri". URI must be provided.');if(p!=="1")throw new Error(`@supabase/auth-js: Invalid SIWE message field "version". Version must be '1'. Provided value: ${p}`);if(!((t=e.statement)===null||t===void 0)&&t.includes(` 268`))throw new Error(`@supabase/auth-js: Invalid SIWE message field "statement". Statement must not include '\\n'. Provided value: ${e.statement}`)}const h=qC(e.address),x=u?`${u}://${r}`:r,v=e.statement?`${e.statement} 269`:"",b=`${x} wants you to sign in with your Ethereum account: 270${h} 271 272${v}`;let w=`URI: ${d} 273Version: ${p} 274Chain ID: ${n}${i?` 275Nonce: ${i}`:""} 276Issued At: ${o.toISOString()}`;if(s&&(w+=` 277Expiration Time: ${s.toISOString()}`),a&&(w+=` 278Not Before: ${a.toISOString()}`),l&&(w+=` 279Request ID: ${l}`),c){let g=` 280Resources:`;for(const y of c){if(!y||typeof y!="string")throw new Error(`@supabase/auth-js: Invalid SIWE message field "resources". Every resource must be a valid string. Provided value: ${y}`);g+=` 281- ${y}`}w+=g}return`${b} 282${w}`}class Xe extends Error{constructor({message:t,code:n,cause:r,name:s}){var o;super(t,{cause:r}),this.__isWebAuthnError=!0,this.name=(o=s??(r instanceof Error?r.name:void 0))!==null&&o!==void 0?o:"Unknown Error",this.code=n}}class td extends Xe{constructor(t,n){super({code:"ERROR_PASSTHROUGH_SEE_CAUSE_PROPERTY",cause:n,message:t}),this.name="WebAuthnUnknownError",this.originalError=n}}function NU({error:e,options:t}){var n,r,s;const{publicKey:o}=t;if(!o)throw Error("options was missing required publicKey property");if(e.name==="AbortError"){if(t.signal instanceof AbortSignal)return new Xe({message:"Registration ceremony was sent an abort signal",code:"ERROR_CEREMONY_ABORTED",cause:e})}else if(e.name==="ConstraintError"){if(((n=o.authenticatorSelection)===null||n===void 0?void 0:n.requireResidentKey)===!0)return new Xe({message:"Discoverable credentials were required but no available authenticator supported it",code:"ERROR_AUTHENTICATOR_MISSING_DISCOVERABLE_CREDENTIAL_SUPPORT",cause:e});if(t.mediation==="conditional"&&((r=o.authenticatorSelection)===null||r===void 0?void 0:r.userVerification)==="required")return new Xe({message:"User verification was required during automatic registration but it could not be performed",code:"ERROR_AUTO_REGISTER_USER_VERIFICATION_FAILURE",cause:e});if(((s=o.authenticatorSelection)===null||s===void 0?void 0:s.userVerification)==="required")return new Xe({message:"User verification was required but no available authenticator supported it",code:"ERROR_AUTHENTICATOR_MISSING_USER_VERIFICATION_SUPPORT",cause:e})}else{if(e.name==="InvalidStateError")return new Xe({message:"The authenticator was previously registered",code:"ERROR_AUTHENTICATOR_PREVIOUSLY_REGISTERED",cause:e});if(e.name==="NotAllowedError")return new Xe({message:e.message,code:"ERROR_PASSTHROUGH_SEE_CAUSE_PROPERTY",cause:e});if(e.name==="NotSupportedError")return o.pubKeyCredParams.filter(a=>a.type==="public-key").length===0?new Xe({message:'No entry in pubKeyCredParams was of type "public-key"',code:"ERROR_MALFORMED_PUBKEYCREDPARAMS",cause:e}):new Xe({message:"No available authenticator supported any of the specified pubKeyCredParams algorithms",code:"ERROR_AUTHENTICATOR_NO_SUPPORTED_PUBKEYCREDPARAMS_ALG",cause:e});if(e.name==="SecurityError"){const i=window.location.hostname;if(KC(i)){if(o.rp.id!==i)return new Xe({message:`The RP ID "${o.rp.id}
282" is invalid for this domain`,code:"ERROR_INVALID_RP_ID",cause:e})}else return new Xe({message:`${window.location.hostname} is an invalid domain`,code:"ERROR_INVALID_DOMAIN",cause:e})}else if(e.name==="TypeError"){if(o.user.id.byteLength<1||o.user.id.byteLength>64)return new Xe({message:"User ID was not between 1 and 64 characters",code:"ERROR_INVALID_USER_ID_LENGTH",cause:e})}else if(e.name==="UnknownError")return new Xe({message:"The authenticator was unable to process the specified options, or could not create a new credential",code:"ERROR_AUTHENTICATOR_GENERAL_ERROR",cause:e})}return new Xe({message:"a Non-Webauthn related error has occurred",code:"ERROR_PASSTHROUGH_SEE_CAUSE_PROPERTY",cause:e})}function AU({error:e,options:t}){const{publicKey:n}=t;if(!n)throw Error("options was missing required publicKey property");if(e.name==="AbortError"){if(t.signal instanceof AbortSignal)return new Xe({message:"Authentication ceremony was sent an abort signal",code:"ERROR_CEREMONY_ABORTED",cause:e})}else{if(e.name==="NotAllowedError")return new Xe({message:e.message,code:"ERROR_PASSTHROUGH_SEE_CAUSE_PROPERTY",cause:e});if(e.name==="SecurityError"){const r=window.location.hostname;if(KC(r)){if(n.rpId!==r)return new Xe({message:`The RP ID "${n.rpId}" is invalid for this domain`,code:"ERROR_INVALID_RP_ID",cause:e})}else return new Xe({message:`${window.location.hostname} is an invalid domain`,code:"ERROR_INVALID_DOMAIN",cause:e})}else if(e.name==="UnknownError")return new Xe({message:"The authenticator was unable to process the specified options, or could not create a new assertion signature",code:"ERROR_AUTHENTICATOR_GENERAL_ERROR",cause:e})}return new Xe({message:"a Non-Webauthn related error has occurred",code:"ERROR_PASSTHROUGH_SEE_CAUSE_PROPERTY",cause:e})}class OU{createNewAbortSignal(){if(this.controller){const n=new Error("Cancelling existing WebAuthn API call for new one");n.name="AbortError",this.controller.abort(n)}const t=new AbortController;return this.controller=t,t.signal}cancelCeremony(){if(this.controller){const t=new Error("Manually cancelling existing WebAuthn API call");t.name="AbortError",this.controller.abort(t),this.controller=void 0}}}const jU=new OU;function IU(e){if(!e)throw new Error("Credential creation options are required");if(typeof PublicKeyCredential<"u"&&"parseCreationOptionsFromJSON"in PublicKeyCredential&&typeof PublicKeyCredential.parseCreationOptionsFromJSON=="function")return PublicKeyCredential.parseCreationOptionsFromJSON(e);const{challenge:t,user:n,excludeCredentials:r}=e,s=aa(e,["challenge","user","excludeCredentials"]),o=Ci(t).buffer,i=Object.assign(Object.assign({},n),{id:Ci(n.id).buffer}),a=Object.assign(Object.assign({},s),{challenge:o,user:i});if(r&&r.length>0){a.excludeCredentials=new Array(r.length);for(let l=0;l<r.length;l++){const c=r[l];a.excludeCredentials[l]=Object.assign(Object.assign({},c),{id:Ci(c.id).buffer,type:c.type||"public-key",transports:c.transports})}}return a}function DU(e){if(!e)throw new Error("Credential request options are required");if(typeof PublicKeyCredential<"u"&&"parseRequestOptionsFromJSON"in PublicKeyCredential&&typeof PublicKeyCredential.parseRequestOptionsFromJSON=="function")return PublicKeyCredential.parseRequestOptionsFromJSON(e);const{challenge:t,allowCredentials:n}=e,r=aa(e,["challenge","allowCredentials"]),s=Ci(t).buffer,o=Object.assign(Object.assign({},r),{challenge:s});if(n&&n.length>0){o.allowCredentials=new Array(n.length);for(let i=0;i<n.length;i++){const a=n[i];o.allowCredentials[i]=Object.assign(Object.assign({},a),{id:Ci(a.id).buffer,type:a.type||"public-key",transports:a.transports})}}return o}function MU(e){var t;if("toJSON"in e&&typeof e.toJSON=="function")return e.toJSON();const n=e;return{id:e.id,rawId:e.id,response:{attestationObject:uo(new Uint8Array(e.response.attestationObject)),clientDataJSON:uo(new Uint8Array(e.response.clientDataJSON))},type:"public-key",clientExtensionResults:e.getClientExtensionResults(),authenticatorAttachment:(t=n.authenticatorAttachment)!==null&&t!==void 0?t:void 0}}function LU(e){var t;if("toJSON"in e&&typeof e.toJSON=="function")return e.toJSON();const n=e,r=e.getClientExtensionResults(),s=e.response;return{id:e.id,rawId:e.id,response:{authenticatorData:uo(new Uint8Array(s.authenticatorData)),clientDataJSON:uo(new Uint8Array(s.clientDataJSON)),signature:uo(new Uint8Array(s.signature)),userHandle:s.userHandle?uo(new Uint8Array(s.userHandle)):void 0},type:"public-key",clientExtensionResults:r,authenticatorAttachment:(t=n.authenticatorAttachment)!==null&&t!==void 0?t:void 0}}function KC(e){return e==="localhost"||/^([a-z0-9]+(-[a-z0-9]+)*\.)+[a-z]{2,}$/i.test(e)}function I0(){var e,t;return!!(pt()&&"PublicKeyCredential"in window&&window.PublicKeyCredential&&"credentials"in navigator&&typeof((e=navigator==null?void 0:navigator.credentials)===null||e===void 0?void 0:e.create)=="function"&&typeof((t=navigator==null?void 0:navigator.credentials)===null||t===void 0?void 0:t.get)=="function")}async function $U(e){try{const t=await navigator.credentials.create(e);return t?t instanceof PublicKeyCredential?{data:t,error:null}:{data:null,error:new td("Browser returned unexpected credential type",t)}:{data:null,error:new td("Empty credential response",t)}}
282catch(t){return{data:null,error:NU({error:t,options:e})}}}async function FU(e){try{const t=await navigator.credentials.get(e);return t?t instanceof PublicKeyCredential?{data:t,error:null}:{data:null,error:new td("Browser returned unexpected credential type",t)}:{data:null,error:new td("Empty credential response",t)}}catch(t){return{data:null,error:AU({error:t,options:e})}}}const UU={hints:["security-key"],authenticatorSelection:{authenticatorAttachment:"cross-platform",requireResidentKey:!1,userVerification:"preferred",residentKey:"discouraged"},attestation:"direct"},BU={userVerification:"preferred",hints:["security-key"],attestation:"direct"};function nd(...e){const t=s=>s!==null&&typeof s=="object"&&!Array.isArray(s),n=s=>s instanceof ArrayBuffer||ArrayBuffer.isView(s),r={};for(const s of e)if(s)for(const o in s){const i=s[o];if(i!==void 0)if(Array.isArray(i))r[o]=i;else if(n(i))r[o]=i;else if(t(i)){const a=r[o];t(a)?r[o]=nd(a,i):r[o]=nd(i)}else r[o]=i}return r}function zU(e,t){return nd(UU,e,t||{})}function WU(e,t){return nd(BU,e,t||{})}class HU{constructor(t){this.client=t,this.enroll=this._enroll.bind(this),this.challenge=this._challenge.bind(this),this.verify=this._verify.bind(this),this.authenticate=this._authenticate.bind(this),this.register=this._register.bind(this)}async _enroll(t){return this.client.mfa.enroll(Object.assign(Object.assign({},t),{factorType:"webauthn"}))}async _challenge({factorId:t,webauthn:n,friendlyName:r,signal:s},o){var i;try{const{data:a,error:l}=await this.client.mfa.challenge({factorId:t,webauthn:n});if(!a)return{data:null,error:l};const c=s??jU.createNewAbortSignal();if(a.webauthn.type==="create"){const{user:u}=a.webauthn.credential_options.publicKey;if(!u.name){const d=r;if(d)u.name=`${u.id}:${d}`;else{const h=(await this.client.getUser()).data.user,x=((i=h==null?void 0:h.user_metadata)===null||i===void 0?void 0:i.name)||(h==null?void 0:h.email)||(h==null?void 0:h.id)||"User";u.name=`${u.id}:${x}`}}u.displayName||(u.displayName=u.name)}switch(a.webauthn.type){case"create":{const u=zU(a.webauthn.credential_options.publicKey,o==null?void 0:o.create),{data:d,error:p}=await $U({publicKey:u,signal:c});return d?{data:{factorId:t,challengeId:a.id,webauthn:{type:a.webauthn.type,credential_response:d}},error:null}:{data:null,error:p}}case"request":{const u=WU(a.webauthn.credential_options.publicKey,o==null?void 0:o.request),{data:d,error:p}=await FU(Object.assign(Object.assign({},a.webauthn.credential_options),{publicKey:u,signal:c}));return d?{data:{factorId:t,challengeId:a.id,webauthn:{type:a.webauthn.type,credential_response:d}},error:null}:{data:null,error:p}}}}catch(a){return te(a)?{data:null,error:a}:{data:null,error:new io("Unexpected error in challenge",a)}}}async _verify({challengeId:t,factorId:n,webauthn:r}){return this.client.mfa.verify({factorId:n,challengeId:t,webauthn:r})}async _authenticate({factorId:t,webauthn:{rpId:n=typeof window<"u"?window.location.hostname:void 0,rpOrigins:r=typeof window<"u"?[window.location.origin]:void 0,signal:s}={}},o){if(!n)return{data:null,error:new Ml("rpId is required for WebAuthn authentication")};try{if(!I0())return{data:null,error:new io("Browser does not support WebAuthn",null)};const{data:i,error:a}=await this.challenge({factorId:t,webauthn:{rpId:n,rpOrigins:r},signal:s},{request:o});if(!i)return{data:null,error:a};const{webauthn:l}=i;return this._verify({factorId:t,challengeId:i.challengeId,webauthn:{type:l.type,rpId:n,rpOrigins:r,credential_response:l.credential_response}})}catch(i){return te(i)?{data:null,error:i}:{data:null,error:new io("Unexpected error in authenticate",i)}}}async _register({friendlyName:t,webauthn:{rpId:n=typeof window<"u"?window.location.hostname:void 0,rpOrigins:r=typeof window<"u"?[window.location.origin]:void 0,signal:s}={}},o){if(!n)return{data:null,error:new Ml("rpId is required for WebAuthn registration")};try{if(!I0())return{data:null,error:new io("Browser does not support WebAuthn",null)};const{data:i,error:a}=await this._enroll({friendlyName:t});if(!i)return await this.client.mfa.listFactors().then(u=>{var d;return(d=u.data)===null||d===void 0?void 0:d.all.find(p=>p.factor_type==="webauthn"&&p.friendly_name===t&&p.status!=="unverified")}).then(u=>u?this.client.mfa.unenroll({factorId:u==null?void 0:u.id}):void 0),{data:null,error:a};const{data:l,error:c}=await this._challenge({factorId:i.id,friendlyName:i.friendly_name,webauthn:{rpId:n,rpOrigins:r},signal:s},{create:o});return l?this._verify({factorId:i.id,challengeId:l.challengeId,webauthn:{rpId:n,rpOrigins:r,type:l.webauthn.type,credential_response:l.webauthn.credential_response}}):{data:null,error:c}}catch(i){return te(i)?{data:null,error:i}:{data:null,error:new io("Unexpected error in register",i)}}}}CU();const VU={url:B5,storageKey:z5,autoRefreshToken:!0,persistSession:!0,detectSessionInUrl:!0,headers:W5,flowType:"implicit",debug:!1,hasCustomAuthorizationHeader:!1,throwOnError:!1,lockAcquireTimeout:1e4};async function D0(e,t,n){return await n()}const Zo={};class Ll{get jwks(){var t,n;return(n=(t=Zo[this.storageKey])===null||t===void 0?void 0:t.jwks)!==null&&n!==void 0?n:{keys:[]}}set jwks(t){Zo[this.storageKey]=Object.assign(Object.assign({},Zo[this.storageKey]),{jwks:t})}get jwks_cached_at(){var t,n;return(n=(t=Zo[this.storageKey])===null||t===void 0?void 0:t.cachedAt)!==null&&n!==void 0?n:Number.MIN_SAFE_INTEGER}set jwks_cached_at(t){Zo[this.storageKey]=Object.assign(Object.assign({},Zo[this.storageKey]),{cachedAt:t})}constructor(t){var n,r,s;this.userStorage=null,this.memoryStorage=null,this.stateChangeEmitters=new Map,this.autoRefreshTicker=null,this.autoRefreshTickTimeout=null,this.visibilityChangedCallback=null,this.refreshingDeferred=null,this.initializePromise=null,this.detectSessionInUrl=!0,this.hasCustomAuthorizationHeader=!1,this.suppressGetSessionWarning=!1,this.lockAcquired=!1,this.pendingInLock=[],this.broadcastChannel=null,this.logger=console.log;const o=Object.assign(Object.assign({},VU),t);
282if(this.storageKey=o.storageKey,this.instanceID=(n=Ll.nextInstanceID[this.storageKey])!==null&&n!==void 0?n:0,Ll.nextInstanceID[this.storageKey]=this.instanceID+1,this.logDebugMessages=!!o.debug,typeof o.debug=="function"&&(this.logger=o.debug),this.instanceID>0&&pt()){const i=`${this._logPrefix()} Multiple GoTrueClient instances detected in the same browser context. It is not an error, but this should be avoided as it may produce undefined behavior when used concurrently under the same storage key.`;console.warn(i),this.logDebugMessages&&console.trace(i)}if(this.persistSession=o.persistSession,this.autoRefreshToken=o.autoRefreshToken,this.admin=new SU({url:o.url,headers:o.headers,fetch:o.fetch}),this.url=o.url,this.headers=o.headers,this.fetch=HC(o.fetch),this.lock=o.lock||D0,this.detectSessionInUrl=o.detectSessionInUrl,this.flowType=o.flowType,this.hasCustomAuthorizationHeader=o.hasCustomAuthorizationHeader,this.throwOnError=o.throwOnError,this.lockAcquireTimeout=o.lockAcquireTimeout,o.lock?this.lock=o.lock:this.persistSession&&pt()&&(!((r=globalThis==null?void 0:globalThis.navigator)===null||r===void 0)&&r.locks)?this.lock=kU:this.lock=D0,this.jwks||(this.jwks={keys:[]},this.jwks_cached_at=Number.MIN_SAFE_INTEGER),this.mfa={verify:this._verify.bind(this),enroll:this._enroll.bind(this),unenroll:this._unenroll.bind(this),challenge:this._challenge.bind(this),listFactors:this._listFactors.bind(this),challengeAndVerify:this._challengeAndVerify.bind(this),getAuthenticatorAssuranceLevel:this._getAuthenticatorAssuranceLevel.bind(this),webauthn:new HU(this)},this.oauth={getAuthorizationDetails:this._getAuthorizationDetails.bind(this),approveAuthorization:this._approveAuthorization.bind(this),denyAuthorization:this._denyAuthorization.bind(this),listGrants:this._listOAuthGrants.bind(this),revokeGrant:this._revokeOAuthGrant.bind(this)},this.persistSession?(o.storage?this.storage=o.storage:WC()?this.storage=globalThis.localStorage:(this.memoryStorage={},this.storage=j0(this.memoryStorage)),o.userStorage&&(this.userStorage=o.userStorage)):(this.memoryStorage={},this.storage=j0(this.memoryStorage)),pt()&&globalThis.BroadcastChannel&&this.persistSession&&this.storageKey){try{this.broadcastChannel=new globalThis.BroadcastChannel(this.storageKey)}catch(i){console.error("Failed to create a new BroadcastChannel, multi-tab state changes will not be available",i)}(s=this.broadcastChannel)===null||s===void 0||s.addEventListener("message",async i=>{this._debug("received broadcast notification from other tab or client",i);try{await this._notifyAllSubscribers(i.data.event,i.data.session,!1)}catch(a){this._debug("#broadcastChannel","error",a)}})}this.initialize().catch(i=>{this._debug("#initialize()","error",i)})}isThrowOnErrorEnabled(){return this.throwOnError}_returnResult(t){if(this.throwOnError&&t&&t.error)throw t.error;return t}_logPrefix(){return`GoTrueClient@${this.storageKey}:${this.instanceID} (${UC}) ${new Date().toISOString()}`}_debug(...t){return this.logDebugMessages&&this.logger(this._logPrefix(),...t),this}async initialize(){return this.initializePromise?await this.initializePromise:(this.initializePromise=(async()=>await this._acquireLock(this.lockAcquireTimeout,async()=>await this._initialize()))(),await this.initializePromise)}async _initialize(){var t;try{let n={},r="none";if(pt()&&(n=rU(window.location.href),this._isImplicitGrantCallback(n)?r="implicit":await this._isPKCECallback(n)&&(r="pkce")),pt()&&this.detectSessionInUrl&&r!=="none"){const{data:s,error:o}=await this._getSessionFromURL(n,r);if(o){if(this._debug("#_initialize()","error detecting session from URL",o),G5(o)){const l=(t=o.details)===null||t===void 0?void 0:t.code;if(l==="identity_already_exists"||l==="identity_not_found"||l==="single_identity_not_deletable")return{error:o}}return{error:o}}const{session:i,redirectType:a}=s;return this._debug("#_initialize()","detected session in URL",i,"redirect type",a),await this._saveSession(i),setTimeout(async()=>{a==="recovery"?await this._notifyAllSubscribers("PASSWORD_RECOVERY",i):await this._notifyAllSubscribers("SIGNED_IN",i)},0),{error:null}}return await this._recoverAndRefresh(),{error:null}}catch(n){return te(n)?this._returnResult({error:n}):this._returnResult({error:new io("Unexpected error during initialization",n)})}finally{await this._handleVisibilityChange(),this._debug("#_initialize()","end")}}async signInAnonymously(t){var n,r,s;try{const o=await se(this.fetch,"POST",`${this.url}/signup`,{headers:this.headers,body:{data:(r=(n=t==null?void 0:t.options)===null||n===void 0?void 0:n.data)!==null&&r!==void 0?r:{},gotrue_meta_security:{captcha_token:(s=t==null?void 0:t.options)===null||s===void 0?void 0:s.captchaToken}},xform:jn}),{data:i,error:a}=o;if(a||!i)return this._returnResult({data:{user:null,session:null},error:a});const l=i.session,c=i.user;return i.session&&(await this._saveSession(i.session),await this._notifyAllSubscribers("SIGNED_IN",l)),this._returnResult({data:{user:c,session:l},error:null})}catch(o){if(te(o))return this._returnResult({data:{user:null,session:null},error:o});throw o}}async signUp(t){var n,r,s;try{let o;if("email"in t){const{email:u,password:d,options:p}=t;let h=null,x=null;this.flowType==="pkce"&&([h,x]=await Ko(this.storage,this.storageKey)),o=await se(this.fetch,"POST",`${this.url}/signup`,{headers:this.headers,redirectTo:p==null?void 0:p.emailRedirectTo,body:{email:u,password:d,data:(n=p==null?void 0:p.data)!==null&&n!==void 0?n:{},gotrue_meta_security:{captcha_token:p==null?void 0:p.captchaToken},code_challenge:h,code_challenge_method:x},xform:jn})}else if("phone"in t){const{phone:u,password:d,options:p}=t;o=await se(this.fetch,"POST",`${this.url}/signup`,{headers:this.headers,body:{phone:u,password:d,data:(r=p==null?void 0:p.data)!==null&&r!==void 0?r:{},channel:(s=p==null?void 0:p.channel)!==null&&s!==void 0?s:"sms",gotrue_meta_security:{captcha_token:p==null?void 0:p.captchaToken}},xform:jn})}else throw new zc("You must provide either an email or phone number and a password");const{data:i,error:a}=o;if(a||!i)return await ht(this.storage,`${this.storageKey}-code-verifier`),this._returnResult({data:{user:null,session:null},error:a});const l=i.session,c=i.user;return i.session&&(await this._saveSession(i.session),await this._notifyAllSubscribers("SIGNED_IN",l)),this._returnResult({data:{user:c,session:l},error:null})}catch(o){if(await ht(this.storage,`${this.storageKey}-code-verifier`),te(o))return this._returnResult({data:{user:null,session:null},error:o});throw o}}async signInWithPassword(t){try{let n;if("email"in t){const{email:o,password:i,options:a}=t;n=await se(this.fetch,"POST",`${this.url}/token?grant_type=password`,{headers:this.headers,body:{email:o,password:i,gotrue_meta_security:{captcha_token:a==null?void 0:a.captchaToken}},xform:A0})}else if("phone"in t){const{phone:o,password:i,options:a}=t;n=await se(this.fetch,"POST",`${this.url}/token?grant_type=password`,{headers:this.headers,body:{phone:o,password:i,gotrue_meta_security:{captcha_token:a==null?void 0:a.captchaToken}},xform:A0})}else throw new zc("You must provide either an email or phone number and a password");const{data:r,error:s}=n;if(s)return this._returnResult({data:{user:null,session:null},error:s});if(!r||!r.session||!r.user){const o=new qo;return this._returnResult({data:{user:null,session:null},error:o})}return r.session&&(await this._saveSession(r.session),await this._notifyAllSubscribers("SIGNED_IN",r.session)),this._returnResult({data:Object.assign({user:r.user,session:r.session},r.weak_password?{weakPassword:r.weak_password}:null),error:s})}catch(n){if(te(n))return this._returnResult({data:{user:null,session:null},error:n});throw n}}async signInWithOAuth(t){var n,r,s,o;return await this._handleProviderSignIn(t.provider,{redirectTo:(n=t.options)===null||n===void 0?void 0:n.redirectTo,scopes:(r=t.options)===null||r===void 0?void 0:r.scopes,queryParams:(s=t.options)===null||s===void 0?void 0:s.queryParams,skipBrowserRedirect:(o=t.o
282ptions)===null||o===void 0?void 0:o.skipBrowserRedirect})}async exchangeCodeForSession(t){return await this.initializePromise,this._acquireLock(this.lockAcquireTimeout,async()=>this._exchangeCodeForSession(t))}async signInWithWeb3(t){const{chain:n}=t;switch(n){case"ethereum":return await this.signInWithEthereum(t);case"solana":return await this.signInWithSolana(t);default:throw new Error(`@supabase/auth-js: Unsupported chain "${n}"`)}}async signInWithEthereum(t){var n,r,s,o,i,a,l,c,u,d,p;let h,x;if("message"in t)h=t.message,x=t.signature;else{const{chain:v,wallet:b,statement:w,options:g}=t;let y;if(pt())if(typeof b=="object")y=b;else{const P=window;if("ethereum"in P&&typeof P.ethereum=="object"&&"request"in P.ethereum&&typeof P.ethereum.request=="function")y=P.ethereum;else throw new Error("@supabase/auth-js: No compatible Ethereum wallet interface on the window object (window.ethereum) detected. Make sure the user already has a wallet installed and connected for this app. Prefer passing the wallet interface object directly to signInWithWeb3({ chain: 'ethereum', wallet: resolvedUserWallet }) instead.")}else{if(typeof b!="object"||!(g!=null&&g.url))throw new Error("@supabase/auth-js: Both wallet and url must be specified in non-browser environments.");y=b}const _=new URL((n=g==null?void 0:g.url)!==null&&n!==void 0?n:window.location.href),S=await y.request({method:"eth_requestAccounts"}).then(P=>P).catch(()=>{throw new Error("@supabase/auth-js: Wallet method eth_requestAccounts is missing or invalid")});if(!S||S.length===0)throw new Error("@supabase/auth-js: No accounts available. Please ensure the wallet is connected.");const k=qC(S[0]);let E=(r=g==null?void 0:g.signInWithEthereum)===null||r===void 0?void 0:r.chainId;if(!E){const P=await y.request({method:"eth_chainId"});E=TU(P)}const R={domain:_.host,address:k,statement:w,uri:_.href,version:"1",chainId:E,nonce:(s=g==null?void 0:g.signInWithEthereum)===null||s===void 0?void 0:s.nonce,issuedAt:(i=(o=g==null?void 0:g.signInWithEthereum)===null||o===void 0?void 0:o.issuedAt)!==null&&i!==void 0?i:new Date,expirationTime:(a=g==null?void 0:g.signInWithEthereum)===null||a===void 0?void 0:a.expirationTime,notBefore:(l=g==null?void 0:g.signInWithEthereum)===null||l===void 0?void 0:l.notBefore,requestId:(c=g==null?void 0:g.signInWithEthereum)===null||c===void 0?void 0:c.requestId,resources:(u=g==null?void 0:g.signInWithEthereum)===null||u===void 0?void 0:u.resources};h=PU(R),x=await y.request({method:"personal_sign",params:[RU(h),k]})}try{const{data:v,error:b}=await se(this.fetch,"POST",`${this.url}/token?grant_type=web3`,{headers:this.headers,body:Object.assign({chain:"ethereum",message:h,signature:x},!((d=t.options)===null||d===void 0)&&d.captchaToken?{gotrue_meta_security:{captcha_token:(p=t.options)===null||p===void 0?void 0:p.captchaToken}}:null),xform:jn});if(b)throw b;if(!v||!v.session||!v.user){const w=new qo;return this._returnResult({data:{user:null,session:null},error:w})}return v.session&&(await this._saveSession(v.session),await this._notifyAllSubscribers("SIGNED_IN",v.session)),this._returnResult({data:Object.assign({},v),error:b})}catch(v){if(te(v))return this._returnResult({data:{user:null,session:null},error:v});throw v}}async signInWithSolana(t){var n,r,s,o,i,a,l,c,u,d,p,h;let x,v;if("message"in t)x=t.message,v=t.signature;else{const{chain:b,wallet:w,statement:g,options:y}=t;let _;if(pt())if(typeof w=="object")_=w;
282else{const k=window;if("solana"in k&&typeof k.solana=="object"&&("signIn"in k.solana&&typeof k.solana.signIn=="function"||"signMessage"in k.solana&&typeof k.solana.signMessage=="function"))_=k.solana;else throw new Error("@supabase/auth-js: No compatible Solana wallet interface on the window object (window.solana) detected. Make sure the user already has a wallet installed and connected for this app. Prefer passing the wallet interface object directly to signInWithWeb3({ chain: 'solana', wallet: resolvedUserWallet }) instead.")}else{if(typeof w!="object"||!(y!=null&&y.url))throw new Error("@supabase/auth-js: Both wallet and url must be specified in non-browser environments.");_=w}const S=new URL((n=y==null?void 0:y.url)!==null&&n!==void 0?n:window.location.href);if("signIn"in _&&_.signIn){const k=await _.signIn(Object.assign(Object.assign(Object.assign({issuedAt:new Date().toISOString()},y==null?void 0:y.signInWithSolana),{version:"1",domain:S.host,uri:S.href}),g?{statement:g}:null));let E;if(Array.isArray(k)&&k[0]&&typeof k[0]=="object")E=k[0];else if(k&&typeof k=="object"&&"signedMessage"in k&&"signature"in k)E=k;else throw new Error("@supabase/auth-js: Wallet method signIn() returned unrecognized value");if("signedMessage"in E&&"signature"in E&&(typeof E.signedMessage=="string"||E.signedMessage instanceof Uint8Array)&&E.signature instanceof Uint8Array)x=typeof E.signedMessage=="string"?E.signedMessage:new TextDecoder().decode(E.signedMessage),v=E.signature;else throw new Error("@supabase/auth-js: Wallet method signIn() API returned object without signedMessage and signature fields")}else{if(!("signMessage"in _)||typeof _.signMessage!="function"||!("publicKey"in _)||typeof _!="object"||!_.publicKey||!("toBase58"in _.publicKey)||typeof _.publicKey.toBase58!="function")throw new Error("@supabase/auth-js: Wallet does not have a compatible signMessage() and publicKey.toBase58() API");x=[`${S.host} wants you to sign in with your Solana account:`,_.publicKey.toBase58(),...g?["",g,""]:[""],"Version: 1",`URI: ${S.href}`,`Issued At: ${(s=(r=y==null?void 0:y.signInWithSolana)===null||r===void 0?void 0:r.issuedAt)!==null&&s!==void 0?s:new Date().toISOString()}`,...!((o=y==null?void 0:y.signInWithSolana)===null||o===void 0)&&o.notBefore?[`Not Before: ${y.signInWithSolana.notBefore}`]:[],...!((i=y==null?void 0:y.signInWithSolana)===null||i===void 0)&&i.expirationTime?[`Expiration Time: ${y.signInWithSolana.expirationTime}`]:[],...!((a=y==null?void 0:y.signInWithSolana)===null||a===void 0)&&a.chainId?[`Chain ID: ${y.signInWithSolana.chainId}`]:[],...!((l=y==null?void 0:y.signInWithSolana)===null||l===void 0)&&l.nonce?[`Nonce: ${y.signInWithSolana.nonce}`]:[],...!((c=y==null?void 0:y.signInWithSolana)===null||c===void 0)&&c.requestId?[`Request ID: ${y.signInWithSolana.requestId}`]:[],...!((d=(u=y==null?void 0:y.signInWithSolana)===null||u===void 0?void 0:u.resources)===null||d===void 0)&&d.length?["Resources",...y.signInWithSolana.resources.map(E=>`- ${E}`)]:[]].join(` 283`);const k=await _.signMessage(new TextEncoder().encode(x),"utf8");if(!k||!(k instanceof Uint8Array))throw new Error("@supabase/auth-js: Wallet signMessage() API returned an recognized value");v=k}}try{const{data:b,error:w}=await se(this.fetch,"POST",`${this.url}/token?grant_type=web3`,{headers:this.headers,body:Object.assign({chain:"solana",message:x,signature:uo(v)},!((p=t.options)===null||p===void 0)&&p.captchaToken?{gotrue_meta_security:{captcha_token:(h=t.options)===null||h===void 0?void 0:h.captchaToken}}:null),xform:jn});if(w)throw w;if(!b||!b.session||!b.user){const g=new qo;return this._returnResult({data:{user:null,session:null},error:g})}return b.session&&(await this._saveSession(b.session),await this._notifyAllSubscribers("SIGNED_IN",b.session)),this._returnResult({data:Object.assign({},b),error:w})}catch(b){if(te(b))return this._returnResult({data:{user:null,session:null},error:b});throw b}}async _exchangeCodeForSession(t){const n=await eo(this.storage,`${this.storageKey}-code-verifier`),[r,s]=(n??"").split("/");try{if(!r&&this.flowType==="pkce")throw new Y5;const{data:o,error:i}=await se(this.fetch,"POST",`${this.url}/token?grant_type=pkce`,{headers:this.headers,body:{auth_code:t,code_verifier:r},xform:jn});if(await ht(this.storage,`${this.storageKey}-code-verifier`),i)throw i;if(!o||!o.session||!o.user){const a=new qo;return this._returnResult({data:{user:null,session:null,redirectType:null},error:a})}return o.session&&(await this._saveSession(o.session),await this._notifyAllSubscribers("SIGNED_IN",o.session)),this._returnResult({data:Object.assign(Object.assign({},o),{redirectType:s??null}),error:i})}catch(o){if(await ht(this.storage,`${this.storageKey}-code-verifier`),te(o))return this._returnResult({data:{user:null,session:null,redirectType:null},error:o});throw o}}async signInWithIdToken(t){try{const{options:n,provider:r,token:s,access_token:o,nonce:i}=t,a=await se(this.fetch,"POST",`${this.url}/token?grant_type=id_token`,{headers:this.headers,body:{provider:r,id_token:s,access_token:o,nonce:i,gotrue_meta_security:{captcha_token:n==null?void 0:n.captchaToken}},xform:jn}),{data:l,error:c}=a;if(c)return this._returnResult({data:{user:null,session:null},error:c});if(!l||!l.session||!l.user){const u=new qo;return this._returnResult({data:{user:null,session:null},error:u})}return l.session&&(await this._saveSession(l.session),await this._notifyAllSubscribers("SIGNED_IN",l.session)),this._returnResult({data:l,error:c})}catch(n){if(te(n))return this._returnResult({data:{user:null,session:null},error:n});throw n}}async signInWithOtp(t){var n,r,s,o,i;try{if("email"in t){const{email:a,options:l}=t;
283let c=null,u=null;this.flowType==="pkce"&&([c,u]=await Ko(this.storage,this.storageKey));const{error:d}=await se(this.fetch,"POST",`${this.url}/otp`,{headers:this.headers,body:{email:a,data:(n=l==null?void 0:l.data)!==null&&n!==void 0?n:{},create_user:(r=l==null?void 0:l.shouldCreateUser)!==null&&r!==void 0?r:!0,gotrue_meta_security:{captcha_token:l==null?void 0:l.captchaToken},code_challenge:c,code_challenge_method:u},redirectTo:l==null?void 0:l.emailRedirectTo});return this._returnResult({data:{user:null,session:null},error:d})}if("phone"in t){const{phone:a,options:l}=t,{data:c,error:u}=await se(this.fetch,"POST",`${this.url}/otp`,{headers:this.headers,body:{phone:a,data:(s=l==null?void 0:l.data)!==null&&s!==void 0?s:{},create_user:(o=l==null?void 0:l.shouldCreateUser)!==null&&o!==void 0?o:!0,gotrue_meta_security:{captcha_token:l==null?void 0:l.captchaToken},channel:(i=l==null?void 0:l.channel)!==null&&i!==void 0?i:"sms"}});return this._returnResult({data:{user:null,session:null,messageId:c==null?void 0:c.message_id},error:u})}throw new zc("You must provide either an email or phone number.")}catch(a){if(await ht(this.storage,`${this.storageKey}-code-verifier`),te(a))return this._returnResult({data:{user:null,session:null},error:a});throw a}}async verifyOtp(t){var n,r;try{let s,o;"options"in t&&(s=(n=t.options)===null||n===void 0?void 0:n.redirectTo,o=(r=t.options)===null||r===void 0?void 0:r.captchaToken);const{data:i,error:a}=await se(this.fetch,"POST",`${this.url}/verify`,{headers:this.headers,body:Object.assign(Object.assign({},t),{gotrue_meta_security:{captcha_token:o}}),redirectTo:s,xform:jn});if(a)throw a;if(!i)throw new Error("An error occurred on token verification.");const l=i.session,c=i.user;return l!=null&&l.access_token&&(await this._saveSession(l),await this._notifyAllSubscribers(t.type=="recovery"?"PASSWORD_RECOVERY":"SIGNED_IN",l)),this._returnResult({data:{user:c,session:l},error:null})}catch(s){if(te(s))return this._returnResult({data:{user:null,session:null},error:s});throw s}}async signInWithSSO(t){var n,r,s,o,i;try{let a=null,l=null;this.flowType==="pkce"&&([a,l]=await Ko(this.storage,this.storageKey));const c=await se(this.fetch,"POST",`${this.url}/sso`,{body:Object.assign(Object.assign(Object.assign(Object.assign(Object.assign({},"providerId"in t?{provider_id:t.providerId}:null),"domain"in t?{domain:t.domain}:null),{redirect_to:(r=(n=t.options)===null||n===void 0?void 0:n.redirectTo)!==null&&r!==void 0?r:void 0}),!((s=t==null?void 0:t.options)===null||s===void 0)&&s.captchaToken?{gotrue_meta_security:{captcha_token:t.options.captchaToken}}:null),{skip_http_redirect:!0,code_challenge:a,code_challenge_method:l}),headers:this.headers,xform:bU});return!((o=c.data)===null||o===void 0)&&o.url&&pt()&&!(!((i=t.options)===null||i===void 0)&&i.skipBrowserRedirect)&&window.location.assign(c.data.url),this._returnResult(c)}catch(a){if(await ht(this.storage,`${this.storageKey}-code-verifier`),te(a))return this._returnResult({data:null,error:a});throw a}}async reauthenticate(){return await this.initializePromise,await this._acquireLock(this.lockAcquireTimeout,async()=>await this._reauthenticate())}async _reauthenticate(){try{return await this._useSession(async t=>{const{data:{session:n},error:r}=t;if(r)throw r;if(!n)throw new Jt;const{error:s}=await se(this.fetch,"GET",`${this.url}/reauthenticate`,{headers:this.headers,jwt:n.access_token});return this._returnResult({data:{user:null,session:null},error:s})})}catch(t){if(te(t))return this._returnResult({data:{user:null,session:null},error:t});throw t}}async resend(t){try{const n=`${this.url}/resend`;if("email"in t){const{email:r,type:s,options:o}=t,{error:i}=await se(this.fetch,"POST",n,{headers:this.headers,body:{email:r,type:s,gotrue_meta_security:{captcha_token:o==null?void 0:o.captchaToken}},redirectTo:o==null?void 0:o.emailRedirectTo});return this._returnResult({data:{user:null,session:null},error:i})}else if("phone"in t){const{phone:r,type:s,options:o}=t,{data:i,error:a}=await se(this.fetch,"POST",n,{headers:this.headers,body:{phone:r,type:s,gotrue_meta_security:{captcha_token:o==null?void 0:o.captchaToken}}});return this._returnResult({data:{user:null,session:null,messageId:i==null?void 0:i.message_id},error:a})}throw new zc("You must provide either an email or phone number and a type")}catch(n){if(te(n))return this._returnResult({data:{user:null,session:null},error:n});throw n}}async getSession(){return await this.initializePromise,await this._acquireLock(this.lockAcquireTimeout,async()=>this._useSession(async n=>n))}async _acquireLock(t,n){this._debug("#_acquireLock","begin",t);try{if(this.lockAcquired){const r=this.pendingInLock.length?this.pendingInLock[this.pendingInLock.length-1]:Promise.resolve(),s=(async()=>(await r,await n()))();return this.pendingInLock.push((async()=>{try{await s}catch{}})()),s}return await this.lock(`lock:${this.storageKey}`,t,async()=>{this._debug("#_acquireLock","lock acquired for storage key",this.storageKey);try{this.lockAcquired=!0;const r=n();for(this.pendingInLock.push((async()=>{try{await r}catch{}})()),await r;this.pendingInLock.length;){const s=[...this.pendingInLock];await Promise.all(s),this.pendingInLock.splice(0,s.length)}return await r}finally{this._debug("#_acquireLock","lock released for storage key",this.storageKey),this.lockAcquired=!1}})}finally{this._debug("#_acquireLock","end")}}async _useSession(t){this._debug("#_useSession","begin");try{const n=await this.__loadSession();return await t(n)}finally{this._debug("#_useSession","end")}}async __loadSession(){this._debug("#__loadSession()","begin"),this.lockAcquired||this._debug("#__loadSession()","used outside of an acquired lock!",new Error().stack);try{let t=null;const n=await eo(this.storage,this.storageKey);if(this._debug("#getSession()","session from storage",n),n!==null&&(this._isValidSession(n)?t=n:(this._debug("#getSession()","session from storage is not val
283id"),await this._removeSession())),!t)return{data:{session:null},error:null};const r=t.expires_at?t.expires_at*1e3-Date.now()<xh:!1;if(this._debug("#__loadSession()",`session has${r?"":" not"} expired`,"expires_at",t.expires_at),!r){if(this.userStorage){const i=await eo(this.userStorage,this.storageKey+"-user");i!=null&&i.user?t.user=i.user:t.user=Eh()}if(this.storage.isServer&&t.user&&!t.user.__isUserNotAvailableProxy){const i={value:this.suppressGetSessionWarning};t.user=gU(t.user,i),i.value&&(this.suppressGetSessionWarning=!0)}return{data:{session:t},error:null}}const{data:s,error:o}=await this._callRefreshToken(t.refresh_token);return o?this._returnResult({data:{session:null},error:o}):this._returnResult({data:{session:s},error:null})}finally{this._debug("#__loadSession()","end")}}async getUser(t){if(t)return await this._getUser(t);await this.initializePromise;const n=await this._acquireLock(this.lockAcquireTimeout,async()=>await this._getUser());return n.data.user&&(this.suppressGetSessionWarning=!0),n}async _getUser(t){try{return t?await se(this.fetch,"GET",`${this.url}/user`,{headers:this.headers,jwt:t,xform:ds}):await this._useSession(async n=>{var r,s,o;const{data:i,error:a}=n;if(a)throw a;return!(!((r=i.session)===null||r===void 0)&&r.access_token)&&!this.hasCustomAuthorizationHeader?{data:{user:null},error:new Jt}:await se(this.fetch,"GET",`${this.url}/user`,{headers:this.headers,jwt:(o=(s=i.session)===null||s===void 0?void 0:s.access_token)!==null&&o!==void 0?o:void 0,xform:ds})})}catch(n){if(te(n))return _h(n)&&(await this._removeSession(),await ht(this.storage,`${this.storageKey}-code-verifier`)),this._returnResult({data:{user:null},error:n});throw n}}async updateUser(t,n={}){return await this.initializePromise,await this._acquireLock(this.lockAcquireTimeout,async()=>await this._updateUser(t,n))}async _updateUser(t,n={}){try{return await this._useSession(async r=>{const{data:s,error:o}=r;if(o)throw o;if(!s.session)throw new Jt;const i=s.session;let a=null,l=null;this.flowType==="pkce"&&t.email!=null&&([a,l]=await Ko(this.storage,this.storageKey));const{data:c,error:u}=await se(this.fetch,"PUT",`${this.url}/user`,{headers:this.headers,redirectTo:n==null?void 0:n.emailRedirectTo,body:Object.assign(Object.assign({},t),{code_challenge:a,code_challenge_method:l}),jwt:i.access_token,xform:ds});if(u)throw u;return i.user=c.user,await this._saveSession(i),await this._notifyAllSubscribers("USER_UPDATED",i),this._returnResult({data:{user:i.user},error:null})})}catch(r){if(await ht(this.storage,`${this.storageKey}-code-verifier`),te(r))return this._returnResult({data:{user:null},error:r});throw r}}async setSession(t){return await this.initializePromise,await this._acquireLock(this.lockAcquireTimeout,async()=>await this._setSession(t))}async _setSession(t){try{if(!t.access_token||!t.refresh_token)throw new Jt;const n=Date.now()/1e3;let r=n,s=!0,o=null;const{payload:i}=Hc(t.access_token);if(i.exp&&(r=i.exp,s=r<=n),s){const{data:a,error:l}=await this._callRefreshToken(t.refresh_token);if(l)return this._returnResult({data:{user:null,session:null},error:l});if(!a)return{data:{user:null,session:null},error:null};o=a}else{const{data:a,error:l}=await this._getUser(t.access_token);if(l)return this._returnResult({data:{user:null,session:null},error:l});o={access_token:t.access_token,refresh_token:t.refresh_token,user:a.user,token_type:"bearer",expires_in:r-n,expires_at:r},await this._saveSession(o),await this._notifyAllSubscribers("SIGNED_IN",o)}return this._returnResult({data:{user:o.user,session:o},error:null})}catch(n){if(te(n))return this._returnResult({data:{session:null,user:null},error:n});throw n}}async refreshSession(t){return await this.initializePromise,await this._acquireLock(this.lockAcquireTimeout,async()=>await this._refreshSession(t))}async _refreshSession(t){try{return await this._useSession(async n=>{var r;if(!t){const{data:i,error:a}=n;if(a)throw a;t=(r=i.session)!==null&&r!==void 0?r:void 0}if(!(t!=null&&t.refresh_token))throw new Jt;const{data:s,error:o}=await this._callRefreshToken(t.refresh_token);return o?this._returnResult({data:{user:null,session:null},error:o}):s?this._returnResult({data:{user:s.user,session:s},error:null}):this._returnResult({data:{user:null,session:null},error:null})})}catch(n){if(te(n))return this._returnResult({data:{user:null,session:null},error:n});throw n}}async _getSessionFromURL(t,n){try{if(!pt())throw new Wc("No browser detected.");
283if(t.error||t.error_description||t.error_code)throw new Wc(t.error_description||"Error in URL with unspecified error_description",{error:t.error||"unspecified_error",code:t.error_code||"unspecified_code"});switch(n){case"implicit":if(this.flowType==="pkce")throw new E0("Not a valid PKCE flow url.");break;case"pkce":if(this.flowType==="implicit")throw new Wc("Not a valid implicit grant flow url.");break;default:}if(n==="pkce"){if(this._debug("#_initialize()","begin","is PKCE flow",!0),!t.code)throw new E0("No code detected.");const{data:g,error:y}=await this._exchangeCodeForSession(t.code);if(y)throw y;const _=new URL(window.location.href);return _.searchParams.delete("code"),window.history.replaceState(window.history.state,"",_.toString()),{data:{session:g.session,redirectType:null},error:null}}const{provider_token:r,provider_refresh_token:s,access_token:o,refresh_token:i,expires_in:a,expires_at:l,token_type:c}=t;if(!o||!a||!i||!c)throw new Wc("No session defined in URL");const u=Math.round(Date.now()/1e3),d=parseInt(a);let p=u+d;l&&(p=parseInt(l));const h=p-u;h*1e3<=Xo&&console.warn(`@supabase/gotrue-js: Session as retrieved from URL expires in ${h}s, should have been closer to ${d}s`);const x=p-d;u-x>=120?console.warn("@supabase/gotrue-js: Session as retrieved from URL was issued over 120s ago, URL could be stale",x,p,u):u-x<0&&console.warn("@supabase/gotrue-js: Session as retrieved from URL was issued in the future? Check the device clock for skew",x,p,u);const{data:v,error:b}=await this._getUser(o);if(b)throw b;const w={provider_token:r,provider_refresh_token:s,access_token:o,expires_in:d,expires_at:p,refresh_token:i,token_type:c,user:v.user};return window.location.hash="",this._debug("#_getSessionFromURL()","clearing window.location.hash"),this._returnResult({data:{session:w,redirectType:t.type},error:null})}catch(r){if(te(r))return this._returnResult({data:{session:null,redirectType:null},error:r});throw r}}_isImplicitGrantCallback(t){return typeof this.detectSessionInUrl=="function"?this.detectSessionInUrl(new URL(window.location.href),t):!!(t.access_token||t.error_description)}async _isPKCECallback(t){const n=await eo(this.storage,`${this.storageKey}-code-verifier`);return!!(t.code&&n)}async signOut(t={scope:"global"}){return await this.initializePromise,await this._acquireLock(this.lockAcquireTimeout,async()=>await this._signOut(t))}async _signOut({scope:t}={scope:"global"}){return await this._useSession(async n=>{var r;const{data:s,error:o}=n;if(o&&!_h(o))return this._returnResult({error:o});const i=(r=s.session)===null||r===void 0?void 0:r.access_token;if(i){const{error:a}=await this.admin.signOut(i,t);if(a&&!(K5(a)&&(a.status===404||a.status===401||a.status===403)||_h(a)))return this._returnResult({error:a})}return t!=="others"&&(await this._removeSession(),await ht(this.storage,`${this.storageKey}-code-verifier`)),this._returnResult({error:null})})}
283onAuthStateChange(t){const n=nU(),r={id:n,callback:t,unsubscribe:()=>{this._debug("#unsubscribe()","state change callback with id removed",n),this.stateChangeEmitters.delete(n)}};return this._debug("#onAuthStateChange()","registered callback with id",n),this.stateChangeEmitters.set(n,r),(async()=>(await this.initializePromise,await this._acquireLock(this.lockAcquireTimeout,async()=>{this._emitInitialSession(n)})))(),{data:{subscription:r}}}async _emitInitialSession(t){return await this._useSession(async n=>{var r,s;try{const{data:{session:o},error:i}=n;if(i)throw i;await((r=this.stateChangeEmitters.get(t))===null||r===void 0?void 0:r.callback("INITIAL_SESSION",o)),this._debug("INITIAL_SESSION","callback id",t,"session",o)}catch(o){await((s=this.stateChangeEmitters.get(t))===null||s===void 0?void 0:s.callback("INITIAL_SESSION",null)),this._debug("INITIAL_SESSION","callback id",t,"error",o),console.error(o)}})}async resetPasswordForEmail(t,n={}){let r=null,s=null;this.flowType==="pkce"&&([r,s]=await Ko(this.storage,this.storageKey,!0));try{return await se(this.fetch,"POST",`${this.url}/recover`,{body:{email:t,code_challenge:r,code_challenge_method:s,gotrue_meta_security:{captcha_token:n.captchaToken}},headers:this.headers,redirectTo:n.redirectTo})}catch(o){if(await ht(this.storage,`${this.storageKey}-code-verifier`),te(o))return this._returnResult({data:null,error:o});throw o}}async getUserIdentities(){var t;try{const{data:n,error:r}=await this.getUser();if(r)throw r;return this._returnResult({data:{identities:(t=n.user.identities)!==null&&t!==void 0?t:[]},error:null})}catch(n){if(te(n))return this._returnResult({data:null,error:n});throw n}}async linkIdentity(t){return"token"in t?this.linkIdentityIdToken(t):this.linkIdentityOAuth(t)}async linkIdentityOAuth(t){var n;try{const{data:r,error:s}=await this._useSession(async o=>{var i,a,l,c,u;const{data:d,error:p}=o;if(p)throw p;const h=await this._getUrlForProvider(`${this.url}/user/identities/authorize`,t.provider,{redirectTo:(i=t.options)===null||i===void 0?void 0:i.redirectTo,scopes:(a=t.options)===null||a===void 0?void 0:a.scopes,queryParams:(l=t.options)===null||l===void 0?void 0:l.queryParams,skipBrowserRedirect:!0});return await se(this.fetch,"GET",h,{headers:this.headers,jwt:(u=(c=d.session)===null||c===void 0?void 0:c.access_token)!==null&&u!==void 0?u:void 0})});if(s)throw s;return pt()&&!(!((n=t.options)===null||n===void 0)&&n.skipBrowserRedirect)&&window.location.assign(r==null?void 0:r.url),this._returnResult({data:{provider:t.provider,url:r==null?void 0:r.url},error:null})}catch(r){if(te(r))return this._returnResult({data:{provider:t.provider,url:null},error:r});throw r}}async linkIdentityIdToken(t){return await this._useSession(async n=>{var r;try{const{error:s,data:{session:o}}=n;if(s)throw s;const{options:i,provider:a,token:l,access_token:c,nonce:u}=t,d=await se(this.fetch,"POST",`${this.url}/token?grant_type=id_token`,{headers:this.headers,jwt:(r=o==null?void 0:o.access_token)!==null&&r!==void 0?r:void 0,body:{provider:a,id_token:l,access_token:c,nonce:u,link_identity:!0,gotrue_meta_security:{captcha_token:i==null?void 0:i.captchaToken}},xform:jn}),{data:p,error:h}=d;return h?this._returnResult({data:{user:null,session:null},error:h}):!p||!p.session||!p.user?this._returnResult({data:{user:null,session:null},error:new qo}):(p.session&&(await this._saveSession(p.session),await this._notifyAllSubscribers("USER_UPDATED",p.session)),this._returnResult({data:p,error:h}))}catch(s){if(await ht(this.storage,`${this.storageKey}-code-verifier`),te(s))return this._returnResult({data:{user:null,session:null},error:s});throw s}})}async unlinkIdentity(t){try{return await this._useSession(async n=>{var r,s;const{data:o,error:i}=n;if(i)throw i;return await se(this.fetch,"DELETE",`${this.url}/user/identities/${t.identity_id}`,{headers:this.headers,jwt:(s=(r=o.session)===null||r===void 0?void 0:r.access_token)!==null&&s!==void 0?s:void 0})})}catch(n){if(te(n))return this._returnResult({data:null,error:n});throw n}}async _refreshAccessToken(t){const n=`#_refreshAccessToken(${t.substring(0,5)}...)`;this._debug(n,"begin");try{const r=Date.now();return await iU(async s=>(s>
2830&&await oU(200*Math.pow(2,s-1)),this._debug(n,"refreshing attempt",s),await se(this.fetch,"POST",`${this.url}/token?grant_type=refresh_token`,{body:{refresh_token:t},headers:this.headers,xform:jn})),(s,o)=>{const i=200*Math.pow(2,s);return o&&Sh(o)&&Date.now()+i-r<Xo})}catch(r){if(this._debug(n,"error",r),te(r))return this._returnResult({data:{session:null,user:null},error:r});throw r}finally{this._debug(n,"end")}}_isValidSession(t){return typeof t=="object"&&t!==null&&"access_token"in t&&"refresh_token"in t&&"expires_at"in t}async _handleProviderSignIn(t,n){const r=await this._getUrlForProvider(`${this.url}/authorize`,t,{redirectTo:n.redirectTo,scopes:n.scopes,queryParams:n.queryParams});return this._debug("#_handleProviderSignIn()","provider",t,"options",n,"url",r),pt()&&!n.skipBrowserRedirect&&window.location.assign(r),{data:{provider:t,url:r},error:null}}async _recoverAndRefresh(){var t,n;const r="#_recoverAndRefresh()";this._debug(r,"begin");try{const s=await eo(this.storage,this.storageKey);if(s&&this.userStorage){let i=await eo(this.userStorage,this.storageKey+"-user");!this.storage.isServer&&Object.is(this.storage,this.userStorage)&&!i&&(i={user:s.user},await ei(this.userStorage,this.storageKey+"-user",i)),s.user=(t=i==null?void 0:i.user)!==null&&t!==void 0?t:Eh()}else if(s&&!s.user&&!s.user){const i=await eo(this.storage,this.storageKey+"-user");i&&(i!=null&&i.user)?(s.user=i.user,await ht(this.storage,this.storageKey+"-user"),await ei(this.storage,this.storageKey,s)):s.user=Eh()}if(this._debug(r,"session from storage",s),!this._isValidSession(s)){this._debug(r,"session is not valid"),s!==null&&await this._removeSession();return}const o=((n=s.expires_at)!==null&&n!==void 0?n:1/0)*1e3-Date.now()<xh;if(this._debug(r,`session has${o?"":" not"} expired with margin of ${xh}s`),o){if(this.autoRefreshToken&&s.refresh_token){const{error:i}=await this._callRefreshToken(s.refresh_token);i&&(console.error(i),Sh(i)||(this._debug(r,"refresh failed with a non-retryable error, removing the session",i),await this._removeSession()))}}else if(s.user&&s.user.__isUserNotAvailableProxy===!0)try{const{data:i,error:a}=await this._getUser(s.access_token);!a&&(i!=null&&i.user)?(s.user=i.user,await this._saveSession(s),await this._notifyAllSubscribers("SIGNED_IN",s)):this._debug(r,"could not get user data, skipping SIGNED_IN notification")}catch(i){console.error("Error getting user data:",i),this._debug(r,"error getting user data, skipping SIGNED_IN notification",i)}else await this._notifyAllSubscribers("SIGNED_IN",s)}catch(s){this._debug(r,"error",s),console.error(s);return}finally{this._debug(r,"end")}}async _callRefreshToken(t){var n,r;if(!t)throw new Jt;if(this.refreshingDeferred)return this.refreshingDeferred.promise;const s=`#_callRefreshToken(${t.substring(0,5)}...)`;this._debug(s,"begin");try{this.refreshingDeferred=new af;const{data:o,error:i}=await this._refreshAccessToken(t);if(i)throw i;if(!o.session)throw new Jt;await this._saveSession(o.session),await this._notifyAllSubscribers("TOKEN_REFRESHED",o.session);const a={data:o.session,error:null};return this.refreshingDeferred.resolve(a),a}catch(o){if(this._debug(s,"error",o),te(o)){const i={data:null,error:o};return Sh(o)||await this._removeSession(),(n=this.refreshingDeferred)===null||n===void 0||n.resolve(i),i}throw(r=this.refreshingDeferred)===null||r===void 0||r.reject(o),o}finally{this.refreshingDeferred=null,this._debug(s,"end")}}async _notifyAllSubscribers(t,n,r=!0){const s=`#_notifyAllSubscribers(${t})`;this._debug(s,"begin",n,`broadcast = ${r}`);try{this.broadcastChannel&&r&&this.broadcastChannel.postMessage({event:t,session:n});const o=[],i=Array.from(this.stateChangeEmitters.values()).map(async a=>{try{await a.callback(t,n)}catch(l){o.push(l)}});if(await Promise.all(i),o.length>0){for(let a=0;a<o.length;a+=1)console.error(o[a]);throw o[0]}}finally{this._debug(s,"end")}}async _saveSession(t){this._debug("#_saveSession()",t),this.suppressGetSessionWarning=!0,await ht(this.storage,`${this.storageKey}-code-verifier`);const n=Object.assign({},t),r=n.user&&n.user.__isUserNotAvailableProxy===!0;if(this.userStorage){!r&&n.user&&await ei(this.userStorage,this.storageKey+"-user",{user:n.user});const s=Object.assign({},n);delete s.user;const o=P0(s);await ei(this.storage,this.storageKey,o)}else{const s=P0(n);await ei(this.storage,this.storageKey,s)}}async _removeSession(){this._debug("#_removeSession()"),this.suppressGetSessionWarning=!1,await ht(this.storage,this.storageKey),await ht(this.storage,this.storageKey+"-code-verifier"),await ht(this.storage,this.storageKey+"-user"),this.userStorage&&await ht(this.userStorage,this.storageKey+"-user"),await this._notifyAllSubscribers("SIGNED_OUT",null)}_removeVisibilityChangedCallback(){this._debug("#_removeVisibilityChangedCallback()");const t=this.visibilityChangedCallback;this.visibilityChangedCallback=null;try{t&&pt()&&(window!=null&&window.removeEventListener)&&window.removeEventListener("visibilitychange",t)}
283catch(n){console.error("removing visibilitychange callback failed",n)}}async _startAutoRefresh(){await this._stopAutoRefresh(),this._debug("#_startAutoRefresh()");const t=setInterval(()=>this._autoRefreshTokenTick(),Xo);this.autoRefreshTicker=t,t&&typeof t=="object"&&typeof t.unref=="function"?t.unref():typeof Deno<"u"&&typeof Deno.unrefTimer=="function"&&Deno.unrefTimer(t);const n=setTimeout(async()=>{await this.initializePromise,await this._autoRefreshTokenTick()},0);this.autoRefreshTickTimeout=n,n&&typeof n=="object"&&typeof n.unref=="function"?n.unref():typeof Deno<"u"&&typeof Deno.unrefTimer=="function"&&Deno.unrefTimer(n)}async _stopAutoRefresh(){this._debug("#_stopAutoRefresh()");const t=this.autoRefreshTicker;this.autoRefreshTicker=null,t&&clearInterval(t);const n=this.autoRefreshTickTimeout;this.autoRefreshTickTimeout=null,n&&clearTimeout(n)}async startAutoRefresh(){this._removeVisibilityChangedCallback(),await this._startAutoRefresh()}async stopAutoRefresh(){this._removeVisibilityChangedCallback(),await this._stopAutoRefresh()}async _autoRefreshTokenTick(){this._debug("#_autoRefreshTokenTick()","begin");try{await this._acquireLock(0,async()=>{try{const t=Date.now();try{return await this._useSession(async n=>{const{data:{session:r}}=n;if(!r||!r.refresh_token||!r.expires_at){this._debug("#_autoRefreshTokenTick()","no session");return}const s=Math.floor((r.expires_at*1e3-t)/Xo);this._debug("#_autoRefreshTokenTick()",`access token expires in ${s} ticks, a tick lasts ${Xo}ms, refresh threshold is ${pm} ticks`),s<=pm&&await this._callRefreshToken(r.refresh_token)})}catch(n){console.error("Auto refresh tick failed with error. This is likely a transient error.",n)}}finally{this._debug("#_autoRefreshTokenTick()","end")}})}catch(t){if(t.isAcquireTimeout||t instanceof VC)this._debug("auto refresh token tick lock not available");else throw t}}async _handleVisibilityChange(){if(this._debug("#_handleVisibilityChange()"),!pt()||!(window!=null&&window.addEventListener))return this.autoRefreshToken&&this.startAutoRefresh(),!1;try{this.visibilityChangedCallback=async()=>{try{await this._onVisibilityChanged(!1)}catch(t){this._debug("#visibilityChangedCallback","error",t)}},window==null||window.addEventListener("visibilitychange",this.visibilityChangedCallback),await this._onVisibilityChanged(!0)}catch(t){console.error("_handleVisibilityChange",t)}}async _onVisibilityChanged(t){const n=`#_onVisibilityChanged(${t})`;this._debug(n,"visibilityState",document.visibilityState),document.visibilityState==="visible"?(this.autoRefreshToken&&this._startAutoRefresh(),t||(await this.initializePromise,await this._acquireLock(this.lockAcquireTimeout,async()=>{if(document.visibilityState!=="visible"){this._debug(n,"acquired the lock to recover the session, but the browser visibilityState is no longer visible, aborting");return}await this._recoverAndRefresh()}))):document.visibilityState==="hidden"&&this.autoRefreshToken&&this._stopAutoRefresh()}async _getUrlForProvider(t,n,r){const s=[`provider=${encodeURIComponent(n)}`];if(r!=null&&r.redirectTo&&s.push(`redirect_to=${encodeURIComponent(r.redirectTo)}`),r!=null&&r.scopes&&s.push(`scopes=${encodeURIComponent(r.scopes)}`),this.flowType==="pkce"){const[o,i]=await Ko(this.storage,this.storageKey),a=new URLSearchParams({code_challenge:`${encodeURIComponent(o)}`,code_challenge_method:`${encodeURIComponent(i)}`});s.push(a.toString())}if(r!=null&&r.queryParams){const o=new URLSearchParams(r.queryParams);s.push(o.toString())}return r!=null&&r.skipBrowserRedirect&&s.push(`skip_http_redirect=${r.skipBrowserRedirect}`),`${t}?${s.join("&")}`}async _unenroll(t){try{return await this._useSession(async n=>{var r;const{data:s,error:o}=n;return o?this._returnResult({data:null,error:o}):await se(this.fetch,"DELETE",`${this.url}/factors/${t.factorId}`,{headers:this.headers,jwt:(r=s==null?void 0:s.session)===null||r===void 0?void 0:r.access_token})})}catch(n){if(te(n))return this._returnResult({data:null,error:n});throw n}}async _enroll(t){try{return await this._useSession(async n=>{var r,s;const{data:o,error:i}=n;if(i)return this._returnResult({data:null,error:i});const a=Object.assign({friendly_name:t.friendlyName,factor_type:t.factorType},t.factorType==="phone"?{phone:t.phone}:t.factorType==="totp"?{issuer:t.issuer}:{}),{data:l,error:c}=await se(this.fetch,"POST",`${this.url}/factors`,{body:a,headers:this.headers,jwt:(r=o==null?void 0:o.session)===null||r===void 0?void 0:r.access_token});return c?this._returnResult({data:null,error:c}):(t.factorType==="totp"&&l.type==="totp"&&(!((s=l==null?void 0:l.totp)===null||s===void 0)&&s.qr_code)&&(l.totp.qr_code=`data:image/svg+xml;utf-8,${l.totp.qr_code}`),this._returnResult({data:l,error:null}))})}catch(n){if(te(n))return this._returnResult({data:null,error:n});throw n}}async _verify(t){return this._acquireLock(this.lockAcquireTimeout,async()=>{try{return await this._useSession(async n=>{var r;const{data:s,error:o}=n;
283if(o)return this._returnResult({data:null,error:o});const i=Object.assign({challenge_id:t.challengeId},"webauthn"in t?{webauthn:Object.assign(Object.assign({},t.webauthn),{credential_response:t.webauthn.type==="create"?MU(t.webauthn.credential_response):LU(t.webauthn.credential_response)})}:{code:t.code}),{data:a,error:l}=await se(this.fetch,"POST",`${this.url}/factors/${t.factorId}/verify`,{body:i,headers:this.headers,jwt:(r=s==null?void 0:s.session)===null||r===void 0?void 0:r.access_token});return l?this._returnResult({data:null,error:l}):(await this._saveSession(Object.assign({expires_at:Math.round(Date.now()/1e3)+a.expires_in},a)),await this._notifyAllSubscribers("MFA_CHALLENGE_VERIFIED",a),this._returnResult({data:a,error:l}))})}catch(n){if(te(n))return this._returnResult({data:null,error:n});throw n}})}async _challenge(t){return this._acquireLock(this.lockAcquireTimeout,async()=>{try{return await this._useSession(async n=>{var r;const{data:s,error:o}=n;if(o)return this._returnResult({data:null,error:o});const i=await se(this.fetch,"POST",`${this.url}/factors/${t.factorId}/challenge`,{body:t,headers:this.headers,jwt:(r=s==null?void 0:s.session)===null||r===void 0?void 0:r.access_token});if(i.error)return i;const{data:a}=i;if(a.type!=="webauthn")return{data:a,error:null};switch(a.webauthn.type){case"create":return{data:Object.assign(Object.assign({},a),{webauthn:Object.assign(Object.assign({},a.webauthn),{credential_options:Object.assign(Object.assign({},a.webauthn.credential_options),{publicKey:IU(a.webauthn.credential_options.publicKey)})})}),error:null};case"request":return{data:Object.assign(Object.assign({},a),{webauthn:Object.assign(Object.assign({},a.webauthn),{credential_options:Object.assign(Object.assign({},a.webauthn.credential_options),{publicKey:DU(a.webauthn.credential_options.publicKey)})})}),error:null}}})}catch(n){if(te(n))return this._returnResult({data:null,error:n});throw n}})}async _challengeAndVerify(t){const{data:n,error:r}=await this._challenge({factorId:t.factorId});return r?this._returnResult({data:null,error:r}):await this._verify({factorId:t.factorId,challengeId:n.id,code:t.code})}async _listFactors(){var t;const{data:{user:n},error:r}=await this.getUser();if(r)return{data:null,error:r};const s={all:[],phone:[],totp:[],webauthn:[]};for(const o of(t=n==null?void 0:n.factors)!==null&&t!==void 0?t:[])s.all.push(o),o.status==="verified"&&s[o.factor_type].push(o);return{data:s,error:null}}async _getAuthenticatorAssuranceLevel(t){var n,r,s,o;if(t)try{const{payload:h}=Hc(t);let x=null;h.aal&&(x=h.aal);let v=x;const{data:{user:b},error:w}=await this.getUser(t);if(w)return this._returnResult({data:null,error:w});((r=(n=b==null?void 0:b.factors)===null||n===void 0?void 0:n.filter(_=>_.status==="verified"))!==null&&r!==void 0?r:[]).length>0&&(v="aal2");const y=h.amr||[];return{data:{currentLevel:x,nextLevel:v,currentAuthenticationMethods:y},error:null}}catch(h){if(te(h))return this._returnResult({data:null,error:h});throw h}const{data:{session:i},error:a}
283=await this.getSession();if(a)return this._returnResult({data:null,error:a});if(!i)return{data:{currentLevel:null,nextLevel:null,currentAuthenticationMethods:[]},error:null};const{payload:l}=Hc(i.access_token);let c=null;l.aal&&(c=l.aal);let u=c;((o=(s=i.user.factors)===null||s===void 0?void 0:s.filter(h=>h.status==="verified"))!==null&&o!==void 0?o:[]).length>0&&(u="aal2");const p=l.amr||[];return{data:{currentLevel:c,nextLevel:u,currentAuthenticationMethods:p},error:null}}async _getAuthorizationDetails(t){try{return await this._useSession(async n=>{const{data:{session:r},error:s}=n;return s?this._returnResult({data:null,error:s}):r?await se(this.fetch,"GET",`${this.url}/oauth/authorizations/${t}`,{headers:this.headers,jwt:r.access_token,xform:o=>({data:o,error:null})}):this._returnResult({data:null,error:new Jt})})}catch(n){if(te(n))return this._returnResult({data:null,error:n});throw n}}async _approveAuthorization(t,n){try{return await this._useSession(async r=>{const{data:{session:s},error:o}=r;if(o)return this._returnResult({data:null,error:o});if(!s)return this._returnResult({data:null,error:new Jt});const i=await se(this.fetch,"POST",`${this.url}/oauth/authorizations/${t}/consent`,{headers:this.headers,jwt:s.access_token,body:{action:"approve"},xform:a=>({data:a,error:null})});return i.data&&i.data.redirect_url&&pt()&&!(n!=null&&n.skipBrowserRedirect)&&window.location.assign(i.data.redirect_url),i})}catch(r){if(te(r))return this._returnResult({data:null,error:r});throw r}}async _denyAuthorization(t,n){try{return await this._useSession(async r=>{const{data:{session:s},error:o}=r;if(o)return this._returnResult({data:null,error:o});if(!s)return this._returnResult({data:null,error:new Jt});const i=await se(this.fetch,"POST",`${this.url}/oauth/authorizations/${t}/consent`,{headers:this.headers,jwt:s.access_token,body:{action:"deny"},xform:a=>({data:a,error:null})});return i.data&&i.data.redirect_url&&pt()&&!(n!=null&&n.skipBrowserRedirect)&&window.location.assign(i.data.redirect_url),i})}catch(r){if(te(r))return this._returnResult({data:null,error:r});throw r}}async _listOAuthGrants(){try{return await this._useSession(async t=>{const{data:{session:n},error:r}=t;return r?this._returnResult({data:null,error:r}):n?await se(this.fetch,"GET",`${this.url}/user/oauth/grants`,{headers:this.headers,jwt:n.access_token,xform:s=>({data:s,error:null})}):this._returnResult({data:null,error:new Jt})})}catch(t){if(te(t))return this._returnResult({data:null,error:t});throw t}}async _revokeOAuthGrant(t){try{return await this._useSession(async n=>{const{data:{session:r},error:s}=n;return s?this._returnResult({data:null,error:s}):r?(await se(this.fetch,"DELETE",`${this.url}/user/oauth/grants`,{headers:this.headers,jwt:r.access_token,query:{client_id:t.clientId},noResolveJson:!0}),{data:{},error:null}):this._returnResult({data:null,error:new Jt})})}catch(n){if(te(n))return this._returnResult({data:null,error:n});throw n}}async fetchJwk(t,n={keys:[]}){let r=n.keys.find(a=>a.kid===t);if(r)return r;const s=Date.now();if(r=this.jwks.keys.find(a=>a.kid===t),r&&this.jwks_cached_at+V5>s)return r;const{data:o,error:i}=await se(this.fetch,"GET",`${this.url}/.well-known/jwks.json`,{headers:this.headers});if(i)throw i;return!o.keys||o.keys.length===0||(this.jwks=o,this.jwks_cached_at=s,r=o.keys.find(a=>a.kid===t),!r)?null:r}async getClaims(t,n={}){try{let r=t;if(!r){const{data:h,error:x}
283=await this.getSession();if(x||!h.session)return this._returnResult({data:null,error:x});r=h.session.access_token}const{header:s,payload:o,signature:i,raw:{header:a,payload:l}}=Hc(r);n!=null&&n.allowExpired||hU(o.exp);const c=!s.alg||s.alg.startsWith("HS")||!s.kid||!("crypto"in globalThis&&"subtle"in globalThis.crypto)?null:await this.fetchJwk(s.kid,n!=null&&n.keys?{keys:n.keys}:n==null?void 0:n.jwks);if(!c){const{error:h}=await this.getUser(r);if(h)throw h;return{data:{claims:o,header:s,signature:i},error:null}}const u=pU(s.alg),d=await crypto.subtle.importKey("jwk",c,u,!0,["verify"]);if(!await crypto.subtle.verify(u,d,i,eU(`${a}.${l}`)))throw new vm("Invalid JWT signature");return{data:{claims:o,header:s,signature:i},error:null}}catch(r){if(te(r))return this._returnResult({data:null,error:r});throw r}}}Ll.nextInstanceID={};const qU=Ll,KU="2.95.2";let Ka="";typeof Deno<"u"?Ka="deno":typeof document<"u"?Ka="web":typeof navigator<"u"&&navigator.product==="ReactNative"?Ka="react-native":Ka="node";const GU={"X-Client-Info":`supabase-js-${Ka}/${KU}`},YU={headers:GU},ZU={schema:"public"},QU={autoRefreshToken:!0,persistSession:!0,detectSessionInUrl:!0,flowType:"implicit"},JU={};function $l(e){"@babel/helpers - typeof";return $l=typeof Symbol=="function"&&typeof Symbol.iterator=="symbol"?function(t){return typeof t}:function(t){return t&&typeof Symbol=="function"&&t.constructor===Symbol&&t!==Symbol.prototype?"symbol":typeof t},$l(e)}function XU(e,t){if($l(e)!="object"||!e)return e;var n=e[Symbol.toPrimitive];if(n!==void 0){var r=n.call(e,t||"default");if($l(r)!="object")return r;throw new TypeError("@@toPrimitive must return a primitive value.")}return(t==="string"?String:Number)(e)}function eB(e){var t=XU(e,"string");return $l(t)=="symbol"?t:t+""}function tB(e,t,n){return(t=eB(t))in e?Object.defineProperty(e,t,{value:n,enumerable:!0,configurable:!0,writable:!0}):e[t]=n,e}function M0(e,t){var n=Object.keys(e);if(Object.getOwnPropertySymbols){var r=Object.getOwnPropertySymbols(e);t&&(r=r.filter(function(s){return Object.getOwnPropertyDescriptor(e,s).enumerable})),n.push.apply(n,r)}return n}function Ke(e){for(var t=1;t<arguments.length;t++){var n=arguments[t]!=null?arguments[t]:{};t%2?M0(Object(n),!0).forEach(function(r){tB(e,r,n[r])}):Object.getOwnPropertyDescriptors?Object.defineProperties(e,Object.getOwnPropertyDescriptors(n)):M0(Object(n)).forEach(function(r){Object.defineProperty(e,r,Object.getOwnPropertyDescriptor(n,r))})}return e}const nB=e=>e?(...t)=>e(...t):(...t)=>fetch(...t),rB=()=>Headers,sB=(e,t,n)=>{const r=nB(n),s=rB();return async(o,i)=>{var a;const l=(a=await t())!==null&&a!==void 0?a:e;let c=new s(i==null?void 0:i.headers);return c.has("apikey")||c.set("apikey",e),c.has("Authorization")||c.set("Authorization",`Bearer ${l}`),r(o,Ke(Ke({},i),{},{headers:c}))}};function oB(e){return e.endsWith("/")?e:e+"/"}function iB(e,t){var n,r;const{db:s,auth:o,realtime:i,global:a}=e,{db:l,auth:c,realtime:u,global:d}=t,p={db:Ke(Ke({},l),s),auth:Ke(Ke({},c),o),realtime:Ke(Ke({},u),i),storage:{},global:Ke(Ke(Ke({},d),a),{},{headers:Ke(Ke({},(n=d==null?void 0:d.headers)!==null&&n!==void 0?n:{}),(r=a==null?void 0:a.headers)!==null&&r!==void 0?r:{})}),accessToken:async()=>""};return e.accessToken?p.accessToken=e.accessToken:delete p.accessToken,p}function aB(e){const t=e==null?void 0:e.trim();if(!t)throw new Error("supabaseUrl is required.");if(!t.match(/^https?:\/\//i))throw new Error("Invalid supabaseUrl: Must be a valid HTTP or HTTPS URL.");try{return new URL(oB(t))}catch{throw Error("Invalid supabaseUrl: Provided URL is malformed.")}}var lB=class extends qU{constructor(e){super(e)}},cB=class{constructor(e,t,n){var r,s;this.supabaseUrl=e,this.supabaseKey=t;const o=aB(e);if(!t)throw new Error("supabaseKey is required.");this.realtimeUrl=new URL("realtime/v1",o),this.realtimeUrl.protocol=this.realtimeUrl.protocol.replace("http","ws"),this.authUrl=new URL("auth/v1",o),this.storageUrl=new URL("storage/v1",o),this.functionsUrl=new URL("functions/v1",o);const i=`sb-${o.hostname.split(".")[0]}-auth-token`,a={db:ZU,realtime:JU,auth:Ke(Ke({},QU),{},{storageKey:i}),global:YU},l=iB(n??{},a);if(this.storageKey=(r=l.auth.storageKey)!==null&&r!==void 0?r:"",this.headers=(s=l.global.headers)!==null&&s!==void 0?s:{},l.accessToken)this.accessToken=l.accessToken,this.auth=new Proxy({},{get:(u,d)=>{throw new Error(`@supabase/supabase-js: Supabase Client is configured with the accessToken option, accessing supabase.auth.${String(d)} is not possible`)}});else{var c;this.auth=this._initSupabaseAuthClient((c=l.auth)!==null&&c!==void 0?c:{},this.headers,l.global.fetch)}this.fetch=sB(t,this._getAccessToken.bind(this),l.global.fetch),this.realtime=this._initRealtimeClient(Ke({headers:this.headers,accessToken:this._getAccessToken.bind(this)},l.realtime)),this.accessToken&&Promise.resolve(this.accessToken()).then(u=>this.realtime.setAuth(u)).catch(u=>console.warn("Failed to set initial Realtime auth token:",u)),this.rest=new K3(new URL("rest/v1",o).href,{headers:this.headers,schema:l.db.schema,fetch:this.fetch,timeout:l.db.timeout,urlLengthLimit:l.db.urlLengthLimit}),this.storage=new U5(this.storageUrl.href,this.headers,this.fetch,n==null?void 0:n.storage),l.accessToken||this._listenForAuthEvents()}get functions(){return new F3(this.functionsUrl.href,{headers:this.headers,customFetch:this.fetch})}from(e){return this.rest.from(e)}schema(e){return this.rest.schema(e)}rpc(e,t={},n={head:!1,get:!1,count:void 0}){return this.rest.rpc(e,t,n)}
283channel(e,t={config:{}}){return this.realtime.channel(e,t)}getChannels(){return this.realtime.getChannels()}removeChannel(e){return this.realtime.removeChannel(e)}removeAllChannels(){return this.realtime.removeAllChannels()}async _getAccessToken(){var e=this,t,n;if(e.accessToken)return await e.accessToken();const{data:r}=await e.auth.getSession();return(t=(n=r.session)===null||n===void 0?void 0:n.access_token)!==null&&t!==void 0?t:e.supabaseKey}_initSupabaseAuthClient({autoRefreshToken:e,persistSession:t,detectSessionInUrl:n,storage:r,userStorage:s,storageKey:o,flowType:i,lock:a,debug:l,throwOnError:c},u,d){const p={Authorization:`Bearer ${this.supabaseKey}`,apikey:`${this.supabaseKey}`};return new lB({url:this.authUrl.href,headers:Ke(Ke({},p),u),storageKey:o,autoRefreshToken:e,persistSession:t,detectSessionInUrl:n,storage:r,userStorage:s,flowType:i,lock:a,debug:l,throwOnError:c,fetch:d,hasCustomAuthorizationHeader:Object.keys(this.headers).some(h=>h.toLowerCase()==="authorization")})}_initRealtimeClient(e){return new u5(this.realtimeUrl.href,Ke(Ke({},e),{},{params:Ke(Ke({},{apikey:this.supabaseKey}),e==null?void 0:e.params)}))}_listenForAuthEvents(){return this.auth.onAuthStateChange((e,t)=>{this._handleTokenChanged(e,"CLIENT",t==null?void 0:t.access_token)})}_handleTokenChanged(e,t,n){(e==="TOKEN_REFRESHED"||e==="SIGNED_IN")&&this.changedAccessToken!==n?(this.changedAccessToken=n,this.realtime.setAuth(n)):e==="SIGNED_OUT"&&(this.realtime.setAuth(),t=="STORAGE"&&this.auth.signOut(),this.changedAccessToken=void 0)}};const uB=(e,t,n)=>new cB(e,t,n);function dB(){if(typeof window<"u")return!1;const e=globalThis.process;if(!e)return!1;const t=e.version;if(t==null)return!1;const n=t.match(/^v(\d+)\./);return n?parseInt(n[1],10)<=18:!1}dB()&&console.warn("â ï¸ Node.js 18 and below are deprecated and will no longer be supported in future versions of @supabase/supabase-js. Please upgrade to Node.js 20 or later. For more information, visit: https://github.com/orgs/supabase/discussions/37217");function fB(){var b,w;if(typeof window>"u")return;const e=location.hostname,n=["lovableproject.com","lovableproject-dev.com","lovable.app","gpt-eng.com","gptengineer.run"].some(g=>e===g||e.endsWith("."+g)),r="[0-9a-f]{8}-[0-9a-f]{4}-4[0-9a-f]{3}-[89ab][0-9a-f]{3}-[0-9a-f]{12}",s=n?((b=e.match(new RegExp("^(?:id-preview(?:-[a-z0-9]+)?|project)--("+r+")(?:-dev)?(?=\\.|$)","i")))==null?void 0:b[1])??((w=e.match(new RegExp("^("+r+")(?=[.-])","i")))==null?void 0:w[1]):void 0,o=window.parent&&window.parent!==window;if(!s||!o)return localStorage;const i=e.endsWith(".lovableproject-dev.com")||e.endsWith(".gpt-eng.com"),a=i?/^https:\/\/([a-z0-9-]+\.)*(lovable\.dev|gptengineer\.app)$|^http:\/\/localhost:3000$/:/^https:\/\/([a-z0-9-]+\.)*(lovable\.dev|gptengineer\.app)$/,l=location.ancestorOrigins&&location.ancestorOrigins[0]||(document.referrer?new URL(document.referrer).origin:""),c=l&&a.test(l)?[l]:i?["https://lovable.dev","http://localhost:3000"]:["https://lovable.dev"],u="lovable-preview-auth:result",d=2e3,p=()=>Math.random().toString(36).slice(2)+Date.now().toString(36),h=(g,y,_)=>new Promise(S=>{const k=p();let E=!1,R;const P=M=>{E||(E=!0,clearTimeout(R),window.removeEventListener("message",A),S(M))},A=M=>{if(c.indexOf(M.origin)<0)return;const H=M.data;H&&H.type===u&&H.requestId===k&&P(H)};window.addEventListener("message",A);const D={type:g,requestId:k,projectId:s,key:y};_!==void 0&&(D.value=_);for(const M of c)window.parent.postMessage(D,M);R=setTimeout(()=>P(null),d)});let x=!0;const v=250;return{getItem:async g=>{let y=await h("lovable-preview-auth:get",g);return!y&&x&&(await new Promise(_=>setTimeout(_,v)),y=await h("lovable-preview-auth:get",g)),x=!1,y&&y.ok&&typeof y.value=="string"?y.value===""?(localStorage.removeItem(g),null):y.value:localStorage.getItem(g)},setItem:(g,y)=>(localStorage.setItem(g,y),h("lovable-preview-auth:set",g,y).then(_=>{_&&_.ok&&typeof _.value=="string"&&localStorage.getItem(g)===y&&(_.value===""?localStorage.removeItem(g):localStorage.setItem(g,_.value))})),removeItem:g=>(localStorage.removeItem(g),h("lovable-preview-auth:remove",g).then(()=>{}))}}const hB="https://genfddadfnmdhnlyyctm.supabase.co",pB="eyJhbGciOiJIUzI1NiIsInR5cCI6IkpXVCJ9.eyJpc3MiOiJzdXBhYmFzZSIsInJlZiI6ImdlbmZkZGFkZm5tZGhubHl5Y3RtIiwicm9sZSI6ImFub24iLCJpYXQiOjE3NzAzMzg3NDgsImV4cCI6MjA4NTk
283xNDc0OH0.Z9pf9T0Rn_LeRpEQlycwEFLe1G8PXwx39P_iN5hzYbA",fr=uB(hB,pB,{auth:{storage:fB(),persistSession:!0,autoRefreshToken:!0}}),Sv="sl_sid",mB=30,GC=e=>{const t=document.cookie.match(new RegExp("(?:^|; )"+e+"=([^;]*)"));return t?decodeURIComponent(t[1]):null},gB=()=>{const e=new Date,t=new Date(e.getTime()+mB*60*1e3),n=new Date(e.getTime()+9*60*60*1e3),r=Date.UTC(n.getUTCFullYear(),n.getUTCMonth(),n.getUTCDate()+1),s=new Date(r-9*60*60*1e3);return t<s?t:s},L0=e=>{document.cookie=`${Sv}=${encodeURIComponent(e)}; path=/; expires=${gB().toUTCString()}; SameSite=Lax`},vB=["utm_source","utm_medium","utm_campaign","utm_term","utm_content"],yB=()=>{const e=new URLSearchParams(window.location.search),t={};return vB.forEach(n=>{const r=e.get(n);t[n]=r&&r.trim()?r.trim():null}),t},ym=async e=>{try{await fr.functions.invoke("track-visit",{body:e})}catch{}};let wm=null;const wB=e=>!e.startsWith("/admin")&&!e.startsWith("/member")&&!e.startsWith("/client"),bB=async e=>{var s,o;if(!wB(e))return;const t=GC(Sv);if(t){wm=t,L0(t),await ym({action:"pageview",session_id:t,page_path:e});return}const n=crypto.randomUUID();wm=n,L0(n);let r=null;try{const{data:i}=await fr.auth.getSession();r=((o=(s=i.session)==null?void 0:s.user)==null?void 0:o.id)??null}catch{r=null}await ym({action:"start",session_id:n,referrer:document.referrer||null,utm:yB(),page_path:e,user_id:r})},rd=async(e,t)=>{const n=wm||GC(Sv);n&&await ym({action:"conversion",session_id:n,event_type:e,reference_id:null,page_path:window.location.pathname})};var Re;(function(e){e.assertEqual=s=>{};function t(s){}e.assertIs=t;function n(s){throw new Error}e.assertNever=n,e.arrayToEnum=s=>{const o={};for(const i of s)o[i]=i;return o},e.getValidEnumValues=s=>{const o=e.objectKeys(s).filter(a=>typeof s[s[a]]!="number"),i={};for(const a of o)i[a]=s[a];return e.objectValues(i)},e.objectValues=s=>e.objectKeys(s).map(function(o){return s[o]}),e.objectKeys=typeof Object.keys=="function"?s=>Object.keys(s):s=>{const o=[];for(const i in s)Object.prototype.hasOwnProperty.call(s,i)&&o.push(i);return o},e.find=(s,o)=>{for(const i of s)if(o(i))return i},e.isInteger=typeof Number.isInteger=="function"?s=>Number.isInteger(s):s=>typeof s=="number"&&Number.isFinite(s)&&Math.floor(s)===s;function r(s,o=" | "){return s.map(i=>typeof i=="string"?`'${i}'`:i).join(o)}e.joinValues=r,e.jsonStringifyReplacer=(s,o)=>typeof o=="bigint"?o.toString():o})(Re||(Re={}));var $0;(function(e){e.mergeShapes=(t,n)=>({...t,...n})})($0||($0={}));const Y=Re.arrayToEnum(["string","nan","number","integer","float","boolean","date","bigint","symbol","function","undefined","null","array","object","unknown","promise","void","never","map","set"]),ls=e=>{switch(typeof e){case"undefined":return Y.undefined;case"string":return Y.string;case"number":return Number.isNaN(e)?Y.nan:Y.number;case"boolean":return Y.boolean;case"function":return Y.function;case"bigint":return Y.bigint;case"symbol":return Y.symbol;case"object":return Array.isArray(e)?Y.array:e===null?Y.null:e.then&&typeof e.then=="function"&&e.catch&&typeof e.catch=="function"?Y.promise:typeof Map<"u"&&e instanceof Map?Y.map:typeof Set<"u"&&e instanceof Set?Y.set:typeof Date<"u"&&e instanceof Date?Y.date:Y.object;default:return Y.unknown}}
vendor: 4,685 bytes, line 283
283,U=Re.arrayToEnum(["invalid_type","invalid_literal","custom","invalid_union","invalid_union_discriminator","invalid_enum_value","unrecognized_keys","invalid_arguments","invalid_return_type","invalid_date","invalid_string","too_small","too_big","invalid_intersection_types","not_multiple_of","not_finite"]);class Kr extends Error{get errors(){return this.issues}constructor(t){super(),this.issues=[],this.addIssue=r=>{this.issues=[...this.issues,r]},this.addIssues=(r=[])=>{this.issues=[...this.issues,...r]};const n=new.target.prototype;Object.setPrototypeOf?Object.setPrototypeOf(this,n):this.__proto__=n,this.name="ZodError",this.issues=t}format(t){const n=t||function(o){return o.message},r={_errors:[]},s=o=>{for(const i of o.issues)if(i.code==="invalid_union")i.unionErrors.map(s);else if(i.code==="invalid_return_type")s(i.returnTypeError);else if(i.code==="invalid_arguments")s(i.argumentsError);else if(i.path.length===0)r._errors.push(n(i));else{let a=r,l=0;for(;l<i.path.length;){const c=i.path[l];l===i.path.length-1?(a[c]=a[c]||{_errors:[]},a[c]._errors.push(n(i))):a[c]=a[c]||{_errors:[]},a=a[c],l++}}};return s(this),r}static assert(t){if(!(t instanceof Kr))throw new Error(`Not a ZodError: ${t}`)}toString(){return this.message}get message(){return JSON.stringify(this.issues,Re.jsonStringifyReplacer,2)}get isEmpty(){return this.issues.length===0}flatten(t=n=>n.message){const n={},r=[];for(const s of this.issues)if(s.path.length>0){const o=s.path[0];n[o]=n[o]||[],n[o].push(t(s))}else r.push(t(s));return{formErrors:r,fieldErrors:n}}get formErrors(){return this.flatten()}}Kr.create=e=>new Kr(e);const bm=(e,t)=>{let n;switch(e.code){case U.invalid_type:e.received===Y.undefined?n="Required":n=`Expected ${e.expected}, received ${e.received}`;break;case U.invalid_literal:n=`Invalid literal value, expected ${JSON.stringify(e.expected,Re.jsonStringifyReplacer)}`;break;case U.unrecognized_keys:n=`Unrecognized key(s) in object: ${Re.joinValues(e.keys,", ")}`;break;case U.invalid_union:n="Invalid input";break;case U.invalid_union_discriminator:n=`Invalid discriminator value. Expected ${Re.joinValues(e.options)}`;break;case U.invalid_enum_value:n=`Invalid enum value. Expected ${Re.joinValues(e.options)}, received '${e.received}'`;break;case U.invalid_arguments:n="Invalid function arguments";break;case U.invalid_return_type:n="Invalid function return type";break;case U.invalid_date:n="Invalid date";break;case U.invalid_string:typeof e.validation=="object"?"includes"in e.validation?(n=`Invalid input: must include "${e.validation.includes}"`,typeof e.validation.position=="number"&&(n=`${n} at one or more positions greater than or equal to ${e.validation.position}`)):"startsWith"in e.validation?n=`Invalid input: must start with "${e.validation.startsWith}"`:"endsWith"in e.validation?n=`Invalid input: must end with "${e.validation.endsWith}"`:Re.assertNever(e.validation):e.validation!=="regex"?n=`Invalid ${e.validation}`:n="Invalid";break;case U.too_small:e.type==="array"?n=`Array must contain ${e.exact?"exactly":e.inclusive?"at least":"more than"} ${e.minimum} element(s)`:e.type==="string"?n=`String must contain ${e.exact?"exactly":e.inclusive?"at least":"over"} ${e.minimum} character(s)`:e.type==="number"?n=`Number must be ${e.exact?"exactly equal to ":e.inclusive?"greater than or equal to ":"greater than "}${e.minimum}`:e.type==="bigint"?n=`Number must be ${e.exact?"exactly equal to ":e.inclusive?"greater than or equal to ":"greater than "}${e.minimum}`:e.type==="date"?n=`Date must be ${e.exact?"exactly equal to ":e.inclusive?"greater than or equal to ":"greater than "}${new Date(Number(e.minimum))}`:n="Invalid input";break;case U.too_big:e.type==="array"?n=`Array must contain ${e.exact?"exactly":e.inclusive?"at most":"less than"} ${e.maximum} element(s)`:e.type==="string"?n=`String must contain ${e.exact?"exactly":e.inclusive?"at most":"under"} ${e.maximum} character(s)`:e.type==="number"?n=`Number must be ${e.exact?"exactly":e.inclusive?"less than or equal to":"less than"} ${e.maximum}`:e.type==="bigint"?n=`BigInt must be ${e.exact?"exactly":e.inclusive?"less than or equal to":"less than"} ${e.maximum}`:e.type==="date"?n=`Date must be ${e.exact?"exactly":e.inclusive?"smaller than or equal to":"smaller than"} ${new Date(Number(e.maximum))}`:n="Invalid input";break;case U.custom:n="Invalid input";break;case U.invalid_intersection_types:n="Intersection results could not be merged";break;case U.not_multiple_of:n=`Number must be a multiple of ${e.multipleOf}`;break;case U.not_finite:n="Number must be finite";break;default:n=t.defaultError,Re.assertNever(e)}return{message:n}};let xB=bm;function _B(){return xB}const SB=e=>
vendor: 7,205 bytes, line 283
283{const{data:t,path:n,errorMaps:r,issueData:s}=e,o=[...n,...s.path||[]],i={...s,path:o};if(s.message!==void 0)return{...s,path:o,message:s.message};let a="";const l=r.filter(c=>!!c).slice().reverse();for(const c of l)a=c(i,{data:t,defaultError:a}).message;return{...s,path:o,message:a}};function q(e,t){const n=_B(),r=SB({issueData:t,data:e.data,path:e.path,errorMaps:[e.common.contextualErrorMap,e.schemaErrorMap,n,n===bm?void 0:bm].filter(s=>!!s)});e.common.issues.push(r)}class ln{constructor(){this.value="valid"}dirty(){this.value==="valid"&&(this.value="dirty")}abort(){this.value!=="aborted"&&(this.value="aborted")}static mergeArray(t,n){const r=[];for(const s of n){if(s.status==="aborted")return fe;s.status==="dirty"&&t.dirty(),r.push(s.value)}return{status:t.value,value:r}}static async mergeObjectAsync(t,n){const r=[];for(const s of n){const o=await s.key,i=await s.value;r.push({key:o,value:i})}return ln.mergeObjectSync(t,r)}static mergeObjectSync(t,n){const r={};for(const s of n){const{key:o,value:i}=s;if(o.status==="aborted"||i.status==="aborted")return fe;o.status==="dirty"&&t.dirty(),i.status==="dirty"&&t.dirty(),o.value!=="__proto__"&&(typeof i.value<"u"||s.alwaysSet)&&(r[o.value]=i.value)}return{status:t.value,value:r}}}const fe=Object.freeze({status:"aborted"}),Ga=e=>({status:"dirty",value:e}),Tn=e=>({status:"valid",value:e}),F0=e=>e.status==="aborted",U0=e=>e.status==="dirty",Ki=e=>e.status==="valid",sd=e=>typeof Promise<"u"&&e instanceof Promise;var J;(function(e){e.errToObj=t=>typeof t=="string"?{message:t}:t||{},e.toString=t=>typeof t=="string"?t:t==null?void 0:t.message})(J||(J={}));class Ls{constructor(t,n,r,s){this._cachedPath=[],this.parent=t,this.data=n,this._path=r,this._key=s}get path(){return this._cachedPath.length||(Array.isArray(this._key)?this._cachedPath.push(...this._path,...this._key):this._cachedPath.push(...this._path,this._key)),this._cachedPath}}const B0=(e,t)=>{if(Ki(t))return{success:!0,data:t.value};if(!e.common.issues.length)throw new Error("Validation failed but no issues detected.");return{success:!1,get error(){if(this._error)return this._error;const n=new Kr(e.common.issues);return this._error=n,this._error}}};function ye(e){if(!e)return{};const{errorMap:t,invalid_type_error:n,required_error:r,description:s}=e;if(t&&(n||r))throw new Error(`Can't use "invalid_type_error" or "required_error" in conjunction with custom error map.`);return t?{errorMap:t,description:s}:{errorMap:(i,a)=>{const{message:l}=e;return i.code==="invalid_enum_value"?{message:l??a.defaultError}:typeof a.data>"u"?{message:l??r??a.defaultError}:i.code!=="invalid_type"?{message:a.defaultError}:{message:l??n??a.defaultError}},description:s}}class Ce{get description(){return this._def.description}_getType(t){return ls(t.data)}_getOrReturnCtx(t,n){return n||{common:t.parent.common,data:t.data,parsedType:ls(t.data),schemaErrorMap:this._def.errorMap,path:t.path,parent:t.parent}}_processInputParams(t){return{status:new ln,ctx:{common:t.parent.common,data:t.data,parsedType:ls(t.data),schemaErrorMap:this._def.errorMap,path:t.path,parent:t.parent}}}_parseSync(t){const n=this._parse(t);if(sd(n))throw new Error("Synchronous parse encountered promise.");return n}_parseAsync(t){const n=this._parse(t);return Promise.resolve(n)}parse(t,n){const r=this.safeParse(t,n);if(r.success)return r.data;throw r.error}safeParse(t,n){const r={common:{issues:[],async:(n==null?void 0:n.async)??!1,contextualErrorMap:n==null?void 0:n.errorMap},path:(n==null?void 0:n.path)||[],schemaErrorMap:this._def.errorMap,parent:null,data:t,parsedType:ls(t)},s=this._parseSync({data:t,path:r.path,parent:r});return B0(r,s)}"~validate"(t){var r,s;const n={common:{issues:[],async:!!this["~standard"].async},path:[],schemaErrorMap:this._def.errorMap,parent:null,data:t,parsedType:ls(t)};if(!this["~standard"].async)try{const o=this._parseSync({data:t,path:[],parent:n});return Ki(o)?{value:o.value}:{issues:n.common.issues}}catch(o){(s=(r=o==null?void 0:o.message)==null?void 0:r.toLowerCase())!=null&&s.includes("encountered")&&(this["~standard"].async=!0),n.common={issues:[],async:!0}}return this._parseAsync({data:t,path:[],parent:n}).then(o=>Ki(o)?{value:o.value}:{issues:n.common.issues})}async parseAsync(t,n){const r=await this.safeParseAsync(t,n);if(r.success)return r.data;throw r.error}async safeParseAsync(t,n){const r={common:{issues:[],contextualErrorMap:n==null?void 0:n.errorMap,async:!0},path:(n==null?void 0:n.path)||[],schemaErrorMap:this._def.errorMap,parent:null,data:t,parsedType:ls(t)},s=this._parse({data:t,path:r.path,parent:r}),o=await(sd(s)?s:Promise.resolve(s));return B0(r,o)}refine(t,n){const r=s=>typeof n=="string"||typeof n>"u"?{message:n}:typeof n=="function"?n(s):n;return this._refinement((s,o)=>{const i=t(s),a=()=>o.addIssue({code:U.custom,...r(s)});return typeof Promise<"u"&&i instanceof Promise?i.then(l=>l?!0:(a(),!1)):i?!0:(a(),!1)})}refinement(t,n){return this._refinement((r,s)=>t(r)?!0:(s.addIssue(typeof n=="function"?n(r,s):n),!1))}_refinement(t){return new Yi({schema:this,typeName:he.ZodEffects,effect:{type:"refinement",refinement:t}})}superRefine(t){return this._refinement(t)}constructor(t){this.spa=this.safeParseAsync,this._def=t,this.parse=this.parse.bind(this),this.safeParse=this.safeParse.bind(this),this.parseAsync=this.parseAsync.bind(this),this.safeParseAsync=this.safeParseAsync.bind(this),this.spa=this.spa.bind(this),this.refine=this.refine.bind(this),this.refinement=this.refinement.bind(this),this.superRefine=this.superRefine.bind(this),this.optional=this.optional.bind(this),this.nullable=this.nullable.bind(this),this.nullish=this.nullish.bind(this),this.array=this.array.bind(this),this.promise=this.promise.bind(this),this.or=this.or.bind(this),this.and=this.and.bind(this),this.transform=this.transform.bind(this),this.brand=this.brand.bind(this),this.default=this.default.bind(this),this.catch=this.catch.bind(this),this.describe=this.describe.bind(this),this.pipe=this.pipe.bind(this),this.readonly=this.readonly.bind(this),this.isNullable=this.isNullable.bind(this),this.isOptional=this.isOptional.bind(this),this["~standard"]={version:1,vendor:"zod",validate:n=>this["~validate"](n)}}optional(){return As.create(this,this._def)}nullable(){return Zi.create(this,this._def)}nullish(){return this.nullable().optional()}array(){return yr.create(this)}promise(){return ld.create(this,this._def)}or(t){return id.create([this,t],this._def)}and(t){return ad.create(this,t,this._def)}transform(t){return new Yi({...ye(this._def),schema:this,typeName:he.ZodEffects,effect:{type:"transform",transform:t}})}default(t){const n=typeof t=="function"?t:()=>t;return new _m({...ye(this._def),innerType:this,defaultValue:n,typeName:he.ZodDefault})}brand(){return new qB({typeName:he.ZodBranded,type:this,...ye(this._def)})}catch(t){const n=typeof t=="function"?t:()=>t;return new Sm({...ye(this._def),innerType:this,catchValue:n,typeName:he.ZodCatch})}describe(t){const n=this.constructor;return new n({...this._def,description:t})}pipe(t){return Ev.create(this,t)}readonly(){return Em.create(this)}isOptional(){return this.safeParse(void 0).success}isNullable(){return this.safeParse(null).success}}const EB=/^c[^\s-]{8,}
vendor: 4,644 bytes, line 283
283$/i,kB=/^[0-9a-z]+$/,CB=/^[0-9A-HJKMNP-TV-Z]{26}$/i,TB=/^[0-9a-fA-F]{8}\b-[0-9a-fA-F]{4}\b-[0-9a-fA-F]{4}\b-[0-9a-fA-F]{4}\b-[0-9a-fA-F]{12}$/i,RB=/^[a-z0-9_-]{21}$/i,PB=/^[A-Za-z0-9-_]+\.[A-Za-z0-9-_]+\.[A-Za-z0-9-_]*$/,NB=/^[-+]?P(?!$)(?:(?:[-+]?\d+Y)|(?:[-+]?\d+[.,]\d+Y$))?(?:(?:[-+]?\d+M)|(?:[-+]?\d+[.,]\d+M$))?(?:(?:[-+]?\d+W)|(?:[-+]?\d+[.,]\d+W$))?(?:(?:[-+]?\d+D)|(?:[-+]?\d+[.,]\d+D$))?(?:T(?=[\d+-])(?:(?:[-+]?\d+H)|(?:[-+]?\d+[.,]\d+H$))?(?:(?:[-+]?\d+M)|(?:[-+]?\d+[.,]\d+M$))?(?:[-+]?\d+(?:[.,]\d+)?S)?)??$/,AB=/^(?!\.)(?!.*\.\.)([A-Z0-9_'+\-\.]*)[A-Z0-9_+-]@([A-Z0-9][A-Z0-9\-]*\.)+[A-Z]{2,}$/i,OB="^(\\p{Extended_Pictographic}|\\p{Emoji_Component})+$";let Ch;const jB=/^(?:(?:25[0-5]|2[0-4][0-9]|1[0-9][0-9]|[1-9][0-9]|[0-9])\.){3}(?:25[0-5]|2[0-4][0-9]|1[0-9][0-9]|[1-9][0-9]|[0-9])$/,IB=/^(?:(?:25[0-5]|2[0-4][0-9]|1[0-9][0-9]|[1-9][0-9]|[0-9])\.){3}(?:25[0-5]|2[0-4][0-9]|1[0-9][0-9]|[1-9][0-9]|[0-9])\/(3[0-2]|[12]?[0-9])$/,DB=/^(([0-9a-fA-F]{1,4}:){7,7}[0-9a-fA-F]{1,4}|([0-9a-fA-F]{1,4}:){1,7}:|([0-9a-fA-F]{1,4}:){1,6}:[0-9a-fA-F]{1,4}|([0-9a-fA-F]{1,4}:){1,5}(:[0-9a-fA-F]{1,4}){1,2}|([0-9a-fA-F]{1,4}:){1,4}(:[0-9a-fA-F]{1,4}){1,3}|([0-9a-fA-F]{1,4}:){1,3}(:[0-9a-fA-F]{1,4}){1,4}|([0-9a-fA-F]{1,4}:){1,2}(:[0-9a-fA-F]{1,4}){1,5}|[0-9a-fA-F]{1,4}:((:[0-9a-fA-F]{1,4}){1,6})|:((:[0-9a-fA-F]{1,4}){1,7}|:)|fe80:(:[0-9a-fA-F]{0,4}){0,4}%[0-9a-zA-Z]{1,}|::(ffff(:0{1,4}){0,1}:){0,1}((25[0-5]|(2[0-4]|1{0,1}[0-9]){0,1}[0-9])\.){3,3}(25[0-5]|(2[0-4]|1{0,1}[0-9]){0,1}[0-9])|([0-9a-fA-F]{1,4}:){1,4}:((25[0-5]|(2[0-4]|1{0,1}[0-9]){0,1}[0-9])\.){3,3}(25[0-5]|(2[0-4]|1{0,1}[0-9]){0,1}[0-9]))$/,MB=/^(([0-9a-fA-F]{1,4}:){7,7}[0-9a-fA-F]{1,4}|([0-9a-fA-F]{1,4}:){1,7}:|([0-9a-fA-F]{1,4}:){1,6}:[0-9a-fA-F]{1,4}|([0-9a-fA-F]{1,4}:){1,5}(:[0-9a-fA-F]{1,4}){1,2}|([0-9a-fA-F]{1,4}:){1,4}(:[0-9a-fA-F]{1,4}){1,3}|([0-9a-fA-F]{1,4}:){1,3}(:[0-9a-fA-F]{1,4}){1,4}|([0-9a-fA-F]{1,4}:){1,2}(:[0-9a-fA-F]{1,4}){1,5}|[0-9a-fA-F]{1,4}:((:[0-9a-fA-F]{1,4}){1,6})|:((:[0-9a-fA-F]{1,4}){1,7}|:)|fe80:(:[0-9a-fA-F]{0,4}){0,4}%[0-9a-zA-Z]{1,}|::(ffff(:0{1,4}){0,1}:){0,1}((25[0-5]|(2[0-4]|1{0,1}[0-9]){0,1}[0-9])\.){3,3}(25[0-5]|(2[0-4]|1{0,1}[0-9]){0,1}[0-9])|([0-9a-fA-F]{1,4}:){1,4}:((25[0-5]|(2[0-4]|1{0,1}[0-9]){0,1}[0-9])\.){3,3}(25[0-5]|(2[0-4]|1{0,1}[0-9]){0,1}[0-9]))\/(12[0-8]|1[01][0-9]|[1-9]?[0-9])$/,LB=/^([0-9a-zA-Z+/]{4})*(([0-9a-zA-Z+/]{2}==)|([0-9a-zA-Z+/]{3}=))?$/,$B=/^([0-9a-zA-Z-_]{4})*(([0-9a-zA-Z-_]{2}(==)?)|([0-9a-zA-Z-_]{3}(=)?))?$/,YC="((\\d\\d[2468][048]|\\d\\d[13579][26]|\\d\\d0[48]|[02468][048]00|[13579][26]00)-02-29|\\d{4}-((0[13578]|1[02])-(0[1-9]|[12]\\d|3[01])|(0[469]|11)-(0[1-9]|[12]\\d|30)|(02)-(0[1-9]|1\\d|2[0-8])))",FB=new RegExp(`^${YC}$`);function ZC(e){let t="[0-5]\\d";e.precision?t=`${t}\\.\\d{${e.precision}}`:e.precision==null&&(t=`${t}(\\.\\d+)?`);const n=e.precision?"+":"?";return`([01]\\d|2[0-3]):[0-5]\\d(:${t})${n}`}function UB(e){return new RegExp(`^${ZC(e)}$`)}function BB(e){let t=`${YC}T${ZC(e)}`;const n=[];return n.push(e.local?"Z?":"Z"),e.offset&&n.push("([+-]\\d{2}:?\\d{2})"),t=`${t}(${n.join("|")})`,new RegExp(`^${t}$`)}function zB(e,t){return!!((t==="v4"||!t)&&jB.test(e)||(t==="v6"||!t)&&DB.test(e))}function WB(e,t){if(!PB.test(e))return!1;try{const[n]=e.split(".");if(!n)return!1;const r=n.replace(/-/g,"+").replace(/_/g,"/").padEnd(n.length+(4-n.length%4)%4,"="),s=JSON.parse(atob(r));return!(typeof s!="object"||s===null||"typ"in s&&(s==null?void 0:s.typ)!=="JWT"||!s.alg||t&&s.alg!==t)}catch{return!1}}function HB(e,t){return!!((t==="v4"||!t)&&IB.test(e)||(t==="v6"||!t)&&MB.test(e))}class bs extends Ce{_parse(t){if(this._def.coerce&&(t.data=String(t.data)),this._getType(t)!==Y.string){const o=this._getOrReturnCtx(t);return q(o,{code:U.invalid_type,expected:Y.string,received:o.parsedType}),fe}const r=new ln;let s;for(const o of this._def.checks)if(o.kind==="min")t.data.length<o.value&&(s=this._getOrReturnCtx(t,s),q(s,{code:U.too_small,minimum:o.value,type:"string",inclusive:!0,exact:!1,message:o.message}),r.dirty());else if(o.kind==="max")t.data.length>o.value&&(s=this._getOrReturnCtx(t,s),q(s,{code:U.too_big,maximum:o.value,type:"string",inclusive:!0,exact:!1,message:o.message}),r.dirty());else if(o.kind==="length"){const i=t.data.length>o.value,a=t.data.length<o.value;(i||a)&&(s=this._getOrReturnCtx(t,s),i?q(s,{code:U.too_big,maximum:o.value,type:"string",inclusive:!0,exact:!0,message:o.message}):a&&q(s,{code:U.too_small,minimum:o.value,type:"string",inclusive:!0,exact:!0,message:o.message}),r.dirty())}else if(o.kind==="email")AB.test(t.data)||(s=this._getOrReturnCtx(t,s),q(s,{validation:"email",code:U.invalid_string,message:o.message}),r.dirty());
vendor: 5,922 bytes, line 283
283else if(o.kind==="emoji")Ch||(Ch=new RegExp(OB,"u")),Ch.test(t.data)||(s=this._getOrReturnCtx(t,s),q(s,{validation:"emoji",code:U.invalid_string,message:o.message}),r.dirty());else if(o.kind==="uuid")TB.test(t.data)||(s=this._getOrReturnCtx(t,s),q(s,{validation:"uuid",code:U.invalid_string,message:o.message}),r.dirty());else if(o.kind==="nanoid")RB.test(t.data)||(s=this._getOrReturnCtx(t,s),q(s,{validation:"nanoid",code:U.invalid_string,message:o.message}),r.dirty());else if(o.kind==="cuid")EB.test(t.data)||(s=this._getOrReturnCtx(t,s),q(s,{validation:"cuid",code:U.invalid_string,message:o.message}),r.dirty());else if(o.kind==="cuid2")kB.test(t.data)||(s=this._getOrReturnCtx(t,s),q(s,{validation:"cuid2",code:U.invalid_string,message:o.message}),r.dirty());else if(o.kind==="ulid")CB.test(t.data)||(s=this._getOrReturnCtx(t,s),q(s,{validation:"ulid",code:U.invalid_string,message:o.message}),r.dirty());else if(o.kind==="url")try{new URL(t.data)}catch{s=this._getOrReturnCtx(t,s),q(s,{validation:"url",code:U.invalid_string,message:o.message}),r.dirty()}else o.kind==="regex"?(o.regex.lastIndex=0,o.regex.test(t.data)||(s=this._getOrReturnCtx(t,s),q(s,{validation:"regex",code:U.invalid_string,message:o.message}),r.dirty())):o.kind==="trim"?t.data=t.data.trim():o.kind==="includes"?t.data.includes(o.value,o.position)||(s=this._getOrReturnCtx(t,s),q(s,{code:U.invalid_string,validation:{includes:o.value,position:o.position},message:o.message}),r.dirty()):o.kind==="toLowerCase"?t.data=t.data.toLowerCase():o.kind==="toUpperCase"?t.data=t.data.toUpperCase():o.kind==="startsWith"?t.data.startsWith(o.value)||(s=this._getOrReturnCtx(t,s),q(s,{code:U.invalid_string,validation:{startsWith:o.value},message:o.message}),r.dirty()):o.kind==="endsWith"?t.data.endsWith(o.value)||(s=this._getOrReturnCtx(t,s),q(s,{code:U.invalid_string,validation:{endsWith:o.value},message:o.message}),r.dirty()):o.kind==="datetime"?BB(o).test(t.data)||(s=this._getOrReturnCtx(t,s),q(s,{code:U.invalid_string,validation:"datetime",message:o.message}),r.dirty()):o.kind==="date"?FB.test(t.data)||(s=this._getOrReturnCtx(t,s),q(s,{code:U.invalid_string,validation:"date",message:o.message}),r.dirty()):o.kind==="time"?UB(o).test(t.data)||(s=this._getOrReturnCtx(t,s),q(s,{code:U.invalid_string,validation:"time",message:o.message}),r.dirty()):o.kind==="duration"?NB.test(t.data)||(s=this._getOrReturnCtx(t,s),q(s,{validation:"duration",code:U.invalid_string,message:o.message}),r.dirty()):o.kind==="ip"?zB(t.data,o.version)||(s=this._getOrReturnCtx(t,s),q(s,{validation:"ip",code:U.invalid_string,message:o.message}),r.dirty()):o.kind==="jwt"?WB(t.data,o.alg)||(s=this._getOrReturnCtx(t,s),q(s,{validation:"jwt",code:U.invalid_string,message:o.message}),r.dirty()):o.kind==="cidr"?HB(t.data,o.version)||(s=this._getOrReturnCtx(t,s),q(s,{validation:"cidr",code:U.invalid_string,message:o.message}),r.dirty()):o.kind==="base64"?LB.test(t.data)||(s=this._getOrReturnCtx(t,s),q(s,{validation:"base64",code:U.invalid_string,message:o.message}),r.dirty()):o.kind==="base64url"?$B.test(t.data)||(s=this._getOrReturnCtx(t,s),q(s,{validation:"base64url",code:U.invalid_string,message:o.message}),r.dirty()):Re.assertNever(o);return{status:r.value,value:t.data}}_regex(t,n,r){return this.refinement(s=>t.test(s),{validation:n,code:U.invalid_string,...J.errToObj(r)})}_addCheck(t){return new bs({...this._def,checks:[...this._def.checks,t]})}email(t){return this._addCheck({kind:"email",...J.errToObj(t)})}url(t){return this._addCheck({kind:"url",...J.errToObj(t)})}emoji(t){return this._addCheck({kind:"emoji",...J.errToObj(t)})}uuid(t){return this._addCheck({kind:"uuid",...J.errToObj(t)})}nanoid(t){return this._addCheck({kind:"nanoid",...J.errToObj(t)})}cuid(t){return this._addCheck({kind:"cuid",...J.errToObj(t)})}cuid2(t){return this._addCheck({kind:"cuid2",...J.errToObj(t)})}ulid(t){return this._addCheck({kind:"ulid",...J.errToObj(t)})}base64(t){return this._addCheck({kind:"base64",...J.errToObj(t)})}base64url(t){return this._addCheck({kind:"base64url",...J.errToObj(t)})}jwt(t){return this._addCheck({kind:"jwt",...J.errToObj(t)})}ip(t){return this._addCheck({kind:"ip",...J.errToObj(t)})}cidr(t){return this._addCheck({kind:"cidr",...J.errToObj(t)})}datetime(t){return typeof t=="string"?this._addCheck({kind:"datetime",precision:null,offset:!1,local:!1,message:t}):this._addCheck({kind:"datetime",precision:typeof(t==null?void 0:t.precision)>"u"?null:t==null?void 0:t.precision,offset:(t==null?void 0:t.offset)??!1,local:(t==null?void 0:t.local)??!1,...J.errToObj(t==null?void 0:t.message)})}date(t){return this._addCheck({kind:"date",message:t})}time(t){return typeof t=="string"?this._addCheck({kind:"time",precision:null,message:t}):this._addCheck({kind:"time",precision:typeof(t==null?void 0:t.precision)>"u"?null:t==null?void 0:t.precision,...J.errToObj(t==null?void 0:t.message)})}duration(t){return this._addCheck({kind:"duration",...J.errToObj(t)})}regex(t,n){return this._addCheck({kind:"regex",regex:t,...J.errToObj(n)})}includes(t,n){return this._addCheck({kind:"includes",value:t,position:n==null?void 0:n.position,...J.errToObj(n==null?void 0:n.message)})}startsWith(t,n){return this._addCheck({kind:"startsWith",value:t,...J.errToObj(n)})}endsWith(t,n){return this._addCheck({kind:"endsWith",value:t,...J.errToObj(n)})}min(t,n){return this._addCheck({kind:"min",value:t,...J.errToObj(n)})}max(t,n){return this._addCheck({kind:"max",value:t,...J.errToObj(n)})}length(t,n){return this._addCheck({kind:"length",value:t,...J.errToObj(n)})}nonempty(t){return this.min(1,J.errToObj(t))}trim(){return new bs({...this._def,checks:[...this._def.checks,{kind:"trim"}]})}toLowerCase(){return new bs({...this._def,checks:[...this._def.checks,{kind:"toLowerCase"}]})}toUpperCase(){return new bs({...this._def,checks:[...this._def.checks,{kind:"toUpperCase"}]})}get isDatetime(){return!!this._def.checks.find(t=>t.kind==="datetime")}
vendor: 4,642 bytes, line 283
283get isDate(){return!!this._def.checks.find(t=>t.kind==="date")}get isTime(){return!!this._def.checks.find(t=>t.kind==="time")}get isDuration(){return!!this._def.checks.find(t=>t.kind==="duration")}get isEmail(){return!!this._def.checks.find(t=>t.kind==="email")}get isURL(){return!!this._def.checks.find(t=>t.kind==="url")}get isEmoji(){return!!this._def.checks.find(t=>t.kind==="emoji")}get isUUID(){return!!this._def.checks.find(t=>t.kind==="uuid")}get isNANOID(){return!!this._def.checks.find(t=>t.kind==="nanoid")}get isCUID(){return!!this._def.checks.find(t=>t.kind==="cuid")}get isCUID2(){return!!this._def.checks.find(t=>t.kind==="cuid2")}get isULID(){return!!this._def.checks.find(t=>t.kind==="ulid")}get isIP(){return!!this._def.checks.find(t=>t.kind==="ip")}get isCIDR(){return!!this._def.checks.find(t=>t.kind==="cidr")}get isBase64(){return!!this._def.checks.find(t=>t.kind==="base64")}get isBase64url(){return!!this._def.checks.find(t=>t.kind==="base64url")}get minLength(){let t=null;for(const n of this._def.checks)n.kind==="min"&&(t===null||n.value>t)&&(t=n.value);return t}get maxLength(){let t=null;for(const n of this._def.checks)n.kind==="max"&&(t===null||n.value<t)&&(t=n.value);return t}}bs.create=e=>new bs({checks:[],typeName:he.ZodString,coerce:(e==null?void 0:e.coerce)??!1,...ye(e)});function VB(e,t){const n=(e.toString().split(".")[1]||"").length,r=(t.toString().split(".")[1]||"").length,s=n>r?n:r,o=Number.parseInt(e.toFixed(s).replace(".","")),i=Number.parseInt(t.toFixed(s).replace(".",""));return o%i/10**s}class Fl extends Ce{constructor(){super(...arguments),this.min=this.gte,this.max=this.lte,this.step=this.multipleOf}_parse(t){if(this._def.coerce&&(t.data=Number(t.data)),this._getType(t)!==Y.number){const o=this._getOrReturnCtx(t);return q(o,{code:U.invalid_type,expected:Y.number,received:o.parsedType}),fe}let r;const s=new ln;for(const o of this._def.checks)o.kind==="int"?Re.isInteger(t.data)||(r=this._getOrReturnCtx(t,r),q(r,{code:U.invalid_type,expected:"integer",received:"float",message:o.message}),s.dirty()):o.kind==="min"?(o.inclusive?t.data<o.value:t.data<=o.value)&&(r=this._getOrReturnCtx(t,r),q(r,{code:U.too_small,minimum:o.value,type:"number",inclusive:o.inclusive,exact:!1,message:o.message}),s.dirty()):o.kind==="max"?(o.inclusive?t.data>o.value:t.data>=o.value)&&(r=this._getOrReturnCtx(t,r),q(r,{code:U.too_big,maximum:o.value,type:"number",inclusive:o.inclusive,exact:!1,message:o.message}),s.dirty()):o.kind==="multipleOf"?VB(t.data,o.value)!==0&&(r=this._getOrReturnCtx(t,r),q(r,{code:U.not_multiple_of,multipleOf:o.value,message:o.message}),s.dirty()):o.kind==="finite"?Number.isFinite(t.data)||(r=this._getOrReturnCtx(t,r),q(r,{code:U.not_finite,message:o.message}),s.dirty()):Re.assertNever(o);return{status:s.value,value:t.data}}gte(t,n){return this.setLimit("min",t,!0,J.toString(n))}gt(t,n){return this.setLimit("min",t,!1,J.toString(n))}lte(t,n){return this.setLimit("max",t,!0,J.toString(n))}lt(t,n){return this.setLimit("max",t,!1,J.toString(n))}setLimit(t,n,r,s){return new Fl({...this._def,checks:[...this._def.checks,{kind:t,value:n,inclusive:r,message:J.toString(s)}]})}_addCheck(t){return new Fl({...this._def,checks:[...this._def.checks,t]})}int(t){return this._addCheck({kind:"int",message:J.toString(t)})}positive(t){return this._addCheck({kind:"min",value:0,inclusive:!1,message:J.toString(t)})}negative(t){return this._addCheck({kind:"max",value:0,inclusive:!1,message:J.toString(t)})}nonpositive(t){return this._addCheck({kind:"max",value:0,inclusive:!0,message:J.toString(t)})}nonnegative(t){return this._addCheck({kind:"min",value:0,inclusive:!0,message:J.toString(t)})}multipleOf(t,n){return this._addCheck({kind:"multipleOf",value:t,message:J.toString(n)})}finite(t){return this._addCheck({kind:"finite",message:J.toString(t)})}safe(t){return this._addCheck({kind:"min",inclusive:!0,value:Number.MIN_SAFE_INTEGER,message:J.toString(t)})._addCheck({kind:"max",inclusive:!0,value:Number.MAX_SAFE_INTEGER,message:J.toString(t)})}get minValue(){let t=null;for(const n of this._def.checks)n.kind==="min"&&(t===null||n.value>t)&&(t=n.value);return t}get maxValue(){let t=null;for(const n of this._def.checks)n.kind==="max"&&(t===null||n.value<t)&&(t=n.value);return t}get isInt(){return!!this._def.checks.find(t=>t.kind==="int"||t.kind==="multipleOf"&&Re.isInteger(t.value))}get isFinite(){let t=null,n=null;for(const r of this._def.checks){if(r.kind==="finite"||r.kind==="int"||r.kind==="multipleOf")return!0;r.kind==="min"?(n===null||r.value>n)&&(n=r.value):r.kind==="max"&&(t===null||r.value<t)&&(t=r.value)}return Number.isFinite(n)&&Number.isFinite(t)}
vendor: 6,660 bytes, line 283
283}Fl.create=e=>new Fl({checks:[],typeName:he.ZodNumber,coerce:(e==null?void 0:e.coerce)||!1,...ye(e)});class Ul extends Ce{constructor(){super(...arguments),this.min=this.gte,this.max=this.lte}_parse(t){if(this._def.coerce)try{t.data=BigInt(t.data)}catch{return this._getInvalidInput(t)}if(this._getType(t)!==Y.bigint)return this._getInvalidInput(t);let r;const s=new ln;for(const o of this._def.checks)o.kind==="min"?(o.inclusive?t.data<o.value:t.data<=o.value)&&(r=this._getOrReturnCtx(t,r),q(r,{code:U.too_small,type:"bigint",minimum:o.value,inclusive:o.inclusive,message:o.message}),s.dirty()):o.kind==="max"?(o.inclusive?t.data>o.value:t.data>=o.value)&&(r=this._getOrReturnCtx(t,r),q(r,{code:U.too_big,type:"bigint",maximum:o.value,inclusive:o.inclusive,message:o.message}),s.dirty()):o.kind==="multipleOf"?t.data%o.value!==BigInt(0)&&(r=this._getOrReturnCtx(t,r),q(r,{code:U.not_multiple_of,multipleOf:o.value,message:o.message}),s.dirty()):Re.assertNever(o);return{status:s.value,value:t.data}}_getInvalidInput(t){const n=this._getOrReturnCtx(t);return q(n,{code:U.invalid_type,expected:Y.bigint,received:n.parsedType}),fe}gte(t,n){return this.setLimit("min",t,!0,J.toString(n))}gt(t,n){return this.setLimit("min",t,!1,J.toString(n))}lte(t,n){return this.setLimit("max",t,!0,J.toString(n))}lt(t,n){return this.setLimit("max",t,!1,J.toString(n))}setLimit(t,n,r,s){return new Ul({...this._def,checks:[...this._def.checks,{kind:t,value:n,inclusive:r,message:J.toString(s)}]})}_addCheck(t){return new Ul({...this._def,checks:[...this._def.checks,t]})}positive(t){return this._addCheck({kind:"min",value:BigInt(0),inclusive:!1,message:J.toString(t)})}negative(t){return this._addCheck({kind:"max",value:BigInt(0),inclusive:!1,message:J.toString(t)})}nonpositive(t){return this._addCheck({kind:"max",value:BigInt(0),inclusive:!0,message:J.toString(t)})}nonnegative(t){return this._addCheck({kind:"min",value:BigInt(0),inclusive:!0,message:J.toString(t)})}multipleOf(t,n){return this._addCheck({kind:"multipleOf",value:t,message:J.toString(n)})}get minValue(){let t=null;for(const n of this._def.checks)n.kind==="min"&&(t===null||n.value>t)&&(t=n.value);return t}get maxValue(){let t=null;for(const n of this._def.checks)n.kind==="max"&&(t===null||n.value<t)&&(t=n.value);return t}}Ul.create=e=>new Ul({checks:[],typeName:he.ZodBigInt,coerce:(e==null?void 0:e.coerce)??!1,...ye(e)});class z0 extends Ce{_parse(t){if(this._def.coerce&&(t.data=!!t.data),this._getType(t)!==Y.boolean){const r=this._getOrReturnCtx(t);return q(r,{code:U.invalid_type,expected:Y.boolean,received:r.parsedType}),fe}return Tn(t.data)}}z0.create=e=>new z0({typeName:he.ZodBoolean,coerce:(e==null?void 0:e.coerce)||!1,...ye(e)});class od extends Ce{_parse(t){if(this._def.coerce&&(t.data=new Date(t.data)),this._getType(t)!==Y.date){const o=this._getOrReturnCtx(t);return q(o,{code:U.invalid_type,expected:Y.date,received:o.parsedType}),fe}if(Number.isNaN(t.data.getTime())){const o=this._getOrReturnCtx(t);return q(o,{code:U.invalid_date}),fe}const r=new ln;let s;for(const o of this._def.checks)o.kind==="min"?t.data.getTime()<o.value&&(s=this._getOrReturnCtx(t,s),q(s,{code:U.too_small,message:o.message,inclusive:!0,exact:!1,minimum:o.value,type:"date"}),r.dirty()):o.kind==="max"?t.data.getTime()>o.value&&(s=this._getOrReturnCtx(t,s),q(s,{code:U.too_big,message:o.message,inclusive:!0,exact:!1,maximum:o.value,type:"date"}),r.dirty()):Re.assertNever(o);return{status:r.value,value:new Date(t.data.getTime())}}_addCheck(t){return new od({...this._def,checks:[...this._def.checks,t]})}min(t,n){return this._addCheck({kind:"min",value:t.getTime(),message:J.toString(n)})}max(t,n){return this._addCheck({kind:"max",value:t.getTime(),message:J.toString(n)})}get minDate(){let t=null;for(const n of this._def.checks)n.kind==="min"&&(t===null||n.value>t)&&(t=n.value);return t!=null?new Date(t):null}get maxDate(){let t=null;for(const n of this._def.checks)n.kind==="max"&&(t===null||n.value<t)&&(t=n.value);return t!=null?new Date(t):null}}od.create=e=>new od({checks:[],coerce:(e==null?void 0:e.coerce)||!1,typeName:he.ZodDate,...ye(e)});class W0 extends Ce{_parse(t){if(this._getType(t)!==Y.symbol){const r=this._getOrReturnCtx(t);return q(r,{code:U.invalid_type,expected:Y.symbol,received:r.parsedType}),fe}return Tn(t.data)}}W0.create=e=>new W0({typeName:he.ZodSymbol,...ye(e)});class H0 extends Ce{_parse(t){if(this._getType(t)!==Y.undefined){const r=this._getOrReturnCtx(t);return q(r,{code:U.invalid_type,expected:Y.undefined,received:r.parsedType}),fe}return Tn(t.data)}}H0.create=e=>new H0({typeName:he.ZodUndefined,...ye(e)});class V0 extends Ce{_parse(t){if(this._getType(t)!==Y.null){const r=this._getOrReturnCtx(t);return q(r,{code:U.invalid_type,expected:Y.null,received:r.parsedType}),fe}return Tn(t.data)}}V0.create=e=>new V0({typeName:he.ZodNull,...ye(e)});class q0 extends Ce{constructor(){super(...arguments),this._any=!0}_parse(t){return Tn(t.data)}}q0.create=e=>new q0({typeName:he.ZodAny,...ye(e)});class K0 extends Ce{constructor(){super(...arguments),this._unknown=!0}_parse(t){return Tn(t.data)}}K0.create=e=>new K0({typeName:he.ZodUnknown,...ye(e)});class $s extends Ce{_parse(t){const n=this._getOrReturnCtx(t);return q(n,{code:U.invalid_type,expected:Y.never,received:n.parsedType}),fe}}$s.create=e=>new $s({typeName:he.ZodNever,...ye(e)});class G0 extends Ce{_parse(t){if(this._getType(t)!==Y.undefined){const r=this._getOrReturnCtx(t);return q(r,{code:U.invalid_type,expected:Y.void,received:r.parsedType}),fe}return Tn(t.data)}}G0.create=e=>new G0({typeName:he.ZodVoid,...ye(e)});class yr extends Ce{_parse(t){const{ctx:n,status:r}=this._processInputParams(t),s=this._def;if(n.parsedType!==Y.array)return q(n,{code:U.invalid_type,expected:Y.array,received:n.parsedType}),fe;if(s.exactLength!==null){const i=n.data.length>s.exactLength.value,a=n.data.length<s.exactLength.value;(i||a)&&(q(n,{code:i?U.too_big:U.too_small,minimum:a?s.exactLength.value:void 0,maximum:i?s.exactLength.value:void 0,type:"array",inclusive:!0,exact:!0,message:s.exactLength.message}),r.dirty())}if(s.minLength!==null&&n.data.length<s.minLength.value&&(q(n,{code:U.too_small,minimum:s.minLength.value,type:"array",inclusive:!0,exact:!1,message:s.minLength.message}),r.dirty()),s.maxLength!==null&&n.data.length>s.maxLength.value&&(q(n,{code:U.too_big,maximum:s.maxLength.value,type:"array",inclusive:!0,exact:!1,message:s.maxLength.message}),r.dirty()),n.common.async)return Promise.all([...n.data].map((i,a)=>s.type._parseAsync(new Ls(n,i,n.path,a)))).then(i=>ln.mergeArray(r,i));const o=[...n.data].map((i,a)=>s.type._parseSync(new Ls(n,i,n.path,a)));return ln.mergeArray(r,o)}
vendor: 5,213 bytes, line 283
283get element(){return this._def.type}min(t,n){return new yr({...this._def,minLength:{value:t,message:J.toString(n)}})}max(t,n){return new yr({...this._def,maxLength:{value:t,message:J.toString(n)}})}length(t,n){return new yr({...this._def,exactLength:{value:t,message:J.toString(n)}})}nonempty(t){return this.min(1,t)}}yr.create=(e,t)=>new yr({type:e,minLength:null,maxLength:null,exactLength:null,typeName:he.ZodArray,...ye(t)});function ti(e){if(e instanceof Ge){const t={};for(const n in e.shape){const r=e.shape[n];t[n]=As.create(ti(r))}return new Ge({...e._def,shape:()=>t})}else return e instanceof yr?new yr({...e._def,type:ti(e.element)}):e instanceof As?As.create(ti(e.unwrap())):e instanceof Zi?Zi.create(ti(e.unwrap())):e instanceof Ao?Ao.create(e.items.map(t=>ti(t))):e}class Ge extends Ce{constructor(){super(...arguments),this._cached=null,this.nonstrict=this.passthrough,this.augment=this.extend}_getCached(){if(this._cached!==null)return this._cached;const t=this._def.shape(),n=Re.objectKeys(t);return this._cached={shape:t,keys:n},this._cached}_parse(t){if(this._getType(t)!==Y.object){const c=this._getOrReturnCtx(t);return q(c,{code:U.invalid_type,expected:Y.object,received:c.parsedType}),fe}const{status:r,ctx:s}=this._processInputParams(t),{shape:o,keys:i}=this._getCached(),a=[];if(!(this._def.catchall instanceof $s&&this._def.unknownKeys==="strip"))for(const c in s.data)i.includes(c)||a.push(c);const l=[];for(const c of i){const u=o[c],d=s.data[c];l.push({key:{status:"valid",value:c},value:u._parse(new Ls(s,d,s.path,c)),alwaysSet:c in s.data})}if(this._def.catchall instanceof $s){const c=this._def.unknownKeys;if(c==="passthrough")for(const u of a)l.push({key:{status:"valid",value:u},value:{status:"valid",value:s.data[u]}});else if(c==="strict")a.length>0&&(q(s,{code:U.unrecognized_keys,keys:a}),r.dirty());else if(c!=="strip")throw new Error("Internal ZodObject error: invalid unknownKeys value.")}else{const c=this._def.catchall;for(const u of a){const d=s.data[u];l.push({key:{status:"valid",value:u},value:c._parse(new Ls(s,d,s.path,u)),alwaysSet:u in s.data})}}return s.common.async?Promise.resolve().then(async()=>{const c=[];for(const u of l){const d=await u.key,p=await u.value;c.push({key:d,value:p,alwaysSet:u.alwaysSet})}return c}).then(c=>ln.mergeObjectSync(r,c)):ln.mergeObjectSync(r,l)}get shape(){return this._def.shape()}strict(t){return J.errToObj,new Ge({...this._def,unknownKeys:"strict",...t!==void 0?{errorMap:(n,r)=>{var o,i;const s=((i=(o=this._def).errorMap)==null?void 0:i.call(o,n,r).message)??r.defaultError;return n.code==="unrecognized_keys"?{message:J.errToObj(t).message??s}:{message:s}}}:{}})}strip(){return new Ge({...this._def,unknownKeys:"strip"})}passthrough(){return new Ge({...this._def,unknownKeys:"passthrough"})}extend(t){return new Ge({...this._def,shape:()=>({...this._def.shape(),...t})})}merge(t){return new Ge({unknownKeys:t._def.unknownKeys,catchall:t._def.catchall,shape:()=>({...this._def.shape(),...t._def.shape()}),typeName:he.ZodObject})}setKey(t,n){return this.augment({[t]:n})}catchall(t){return new Ge({...this._def,catchall:t})}pick(t){const n={};for(const r of Re.objectKeys(t))t[r]&&this.shape[r]&&(n[r]=this.shape[r]);return new Ge({...this._def,shape:()=>n})}omit(t){const n={};for(const r of Re.objectKeys(this.shape))t[r]||(n[r]=this.shape[r]);return new Ge({...this._def,shape:()=>n})}deepPartial(){return ti(this)}partial(t){const n={};for(const r of Re.objectKeys(this.shape)){const s=this.shape[r];t&&!t[r]?n[r]=s:n[r]=s.optional()}return new Ge({...this._def,shape:()=>n})}required(t){const n={};for(const r of Re.objectKeys(this.shape))if(t&&!t[r])n[r]=this.shape[r];else{let o=this.shape[r];for(;o instanceof As;)o=o._def.innerType;n[r]=o}return new Ge({...this._def,shape:()=>n})}keyof(){return QC(Re.objectKeys(this.shape))}}Ge.create=(e,t)=>new Ge({shape:()=>e,unknownKeys:"strip",catchall:$s.create(),typeName:he.ZodObject,...ye(t)});Ge.strictCreate=(e,t)=>new Ge({shape:()=>e,unknownKeys:"strict",catchall:$s.create(),typeName:he.ZodObject,...ye(t)});Ge.lazycreate=(e,t)=>new Ge({shape:e,unknownKeys:"strip",catchall:$s.create(),typeName:he.ZodObject,...ye(t)});class id extends Ce{_parse(t){const{ctx:n}=this._processInputParams(t),r=this._def.options;function s(o){for(const a of o)if(a.result.status==="valid")return a.result;for(const a of o)if(a.result.status==="dirty")return n.common.issues.push(...a.ctx.common.issues),a.result;const i=o.map(a=>new Kr(a.ctx.common.issues));return q(n,{code:U.invalid_union,unionErrors:i}),fe}if(n.common.async)return Promise.all(r.map(async o=>{const i={...n,common:{...n.common,issues:[]},parent:null};return{result:await o._parseAsync({data:n.data,path:n.path,parent:i}),ctx:i}})).then(s);{let o;const i=[];for(const l of r){const c={...n,common:{...n.common,issues:[]},parent:null},u=l._parseSync({data:n.data,path:n.path,parent:c});if(u.status==="valid")return u;u.status==="dirty"&&!o&&(o={result:u,ctx:c}),c.common.issues.length&&i.push(c.common.issues)}if(o)return n.common.issues.push(...o.ctx.common.issues),o.result;const a=i.map(l=>new Kr(l));return q(n,{code:U.invalid_union,unionErrors:a}),fe}}get options(){return this._def.options}}id.create=(e,t)=>
vendor: 4,379 bytes, line 283
283new id({options:e,typeName:he.ZodUnion,...ye(t)});function xm(e,t){const n=ls(e),r=ls(t);if(e===t)return{valid:!0,data:e};if(n===Y.object&&r===Y.object){const s=Re.objectKeys(t),o=Re.objectKeys(e).filter(a=>s.indexOf(a)!==-1),i={...e,...t};for(const a of o){const l=xm(e[a],t[a]);if(!l.valid)return{valid:!1};i[a]=l.data}return{valid:!0,data:i}}else if(n===Y.array&&r===Y.array){if(e.length!==t.length)return{valid:!1};const s=[];for(let o=0;o<e.length;o++){const i=e[o],a=t[o],l=xm(i,a);if(!l.valid)return{valid:!1};s.push(l.data)}return{valid:!0,data:s}}else return n===Y.date&&r===Y.date&&+e==+t?{valid:!0,data:e}:{valid:!1}}class ad extends Ce{_parse(t){const{status:n,ctx:r}=this._processInputParams(t),s=(o,i)=>{if(F0(o)||F0(i))return fe;const a=xm(o.value,i.value);return a.valid?((U0(o)||U0(i))&&n.dirty(),{status:n.value,value:a.data}):(q(r,{code:U.invalid_intersection_types}),fe)};return r.common.async?Promise.all([this._def.left._parseAsync({data:r.data,path:r.path,parent:r}),this._def.right._parseAsync({data:r.data,path:r.path,parent:r})]).then(([o,i])=>s(o,i)):s(this._def.left._parseSync({data:r.data,path:r.path,parent:r}),this._def.right._parseSync({data:r.data,path:r.path,parent:r}))}}ad.create=(e,t,n)=>new ad({left:e,right:t,typeName:he.ZodIntersection,...ye(n)});class Ao extends Ce{_parse(t){const{status:n,ctx:r}=this._processInputParams(t);if(r.parsedType!==Y.array)return q(r,{code:U.invalid_type,expected:Y.array,received:r.parsedType}),fe;if(r.data.length<this._def.items.length)return q(r,{code:U.too_small,minimum:this._def.items.length,inclusive:!0,exact:!1,type:"array"}),fe;!this._def.rest&&r.data.length>this._def.items.length&&(q(r,{code:U.too_big,maximum:this._def.items.length,inclusive:!0,exact:!1,type:"array"}),n.dirty());const o=[...r.data].map((i,a)=>{const l=this._def.items[a]||this._def.rest;return l?l._parse(new Ls(r,i,r.path,a)):null}).filter(i=>!!i);return r.common.async?Promise.all(o).then(i=>ln.mergeArray(n,i)):ln.mergeArray(n,o)}get items(){return this._def.items}rest(t){return new Ao({...this._def,rest:t})}}Ao.create=(e,t)=>{if(!Array.isArray(e))throw new Error("You must pass an array of schemas to z.tuple([ ... ])");return new Ao({items:e,typeName:he.ZodTuple,rest:null,...ye(t)})};class Y0 extends Ce{get keySchema(){return this._def.keyType}get valueSchema(){return this._def.valueType}_parse(t){const{status:n,ctx:r}=this._processInputParams(t);if(r.parsedType!==Y.map)return q(r,{code:U.invalid_type,expected:Y.map,received:r.parsedType}),fe;const s=this._def.keyType,o=this._def.valueType,i=[...r.data.entries()].map(([a,l],c)=>({key:s._parse(new Ls(r,a,r.path,[c,"key"])),value:o._parse(new Ls(r,l,r.path,[c,"value"]))}));if(r.common.async){const a=new Map;return Promise.resolve().then(async()=>{for(const l of i){const c=await l.key,u=await l.value;if(c.status==="aborted"||u.status==="aborted")return fe;(c.status==="dirty"||u.status==="dirty")&&n.dirty(),a.set(c.value,u.value)}return{status:n.value,value:a}})}else{const a=new Map;for(const l of i){const c=l.key,u=l.value;if(c.status==="aborted"||u.status==="aborted")return fe;(c.status==="dirty"||u.status==="dirty")&&n.dirty(),a.set(c.value,u.value)}return{status:n.value,value:a}}}}Y0.create=(e,t,n)=>new Y0({valueType:t,keyType:e,typeName:he.ZodMap,...ye(n)});class Bl extends Ce{_parse(t){const{status:n,ctx:r}=this._processInputParams(t);if(r.parsedType!==Y.set)return q(r,{code:U.invalid_type,expected:Y.set,received:r.parsedType}),fe;const s=this._def;s.minSize!==null&&r.data.size<s.minSize.value&&(q(r,{code:U.too_small,minimum:s.minSize.value,type:"set",inclusive:!0,exact:!1,message:s.minSize.message}),n.dirty()),s.maxSize!==null&&r.data.size>s.maxSize.value&&(q(r,{code:U.too_big,maximum:s.maxSize.value,type:"set",inclusive:!0,exact:!1,message:s.maxSize.message}),n.dirty());const o=this._def.valueType;function i(l){const c=new Set;for(const u of l){if(u.status==="aborted")return fe;u.status==="dirty"&&n.dirty(),c.add(u.value)}return{status:n.value,value:c}}const a=[...r.data.values()].map((l,c)=>o._parse(new Ls(r,l,r.path,c)));return r.common.async?Promise.all(a).then(l=>i(l)):i(a)}min(t,n){return new Bl({...this._def,minSize:{value:t,message:J.toString(n)}})}max(t,n){return new Bl({...this._def,maxSize:{value:t,message:J.toString(n)}})}size(t,n){return this.min(t,n).max(t,n)}nonempty(t){return this.min(1,t)}}Bl.create=(e,t)=>
vendor: 4,637 bytes, line 283
283new Bl({valueType:e,minSize:null,maxSize:null,typeName:he.ZodSet,...ye(t)});class Z0 extends Ce{get schema(){return this._def.getter()}_parse(t){const{ctx:n}=this._processInputParams(t);return this._def.getter()._parse({data:n.data,path:n.path,parent:n})}}Z0.create=(e,t)=>new Z0({getter:e,typeName:he.ZodLazy,...ye(t)});class Q0 extends Ce{_parse(t){if(t.data!==this._def.value){const n=this._getOrReturnCtx(t);return q(n,{received:n.data,code:U.invalid_literal,expected:this._def.value}),fe}return{status:"valid",value:t.data}}get value(){return this._def.value}}Q0.create=(e,t)=>new Q0({value:e,typeName:he.ZodLiteral,...ye(t)});function QC(e,t){return new Gi({values:e,typeName:he.ZodEnum,...ye(t)})}class Gi extends Ce{_parse(t){if(typeof t.data!="string"){const n=this._getOrReturnCtx(t),r=this._def.values;return q(n,{expected:Re.joinValues(r),received:n.parsedType,code:U.invalid_type}),fe}if(this._cache||(this._cache=new Set(this._def.values)),!this._cache.has(t.data)){const n=this._getOrReturnCtx(t),r=this._def.values;return q(n,{received:n.data,code:U.invalid_enum_value,options:r}),fe}return Tn(t.data)}get options(){return this._def.values}get enum(){const t={};for(const n of this._def.values)t[n]=n;return t}get Values(){const t={};for(const n of this._def.values)t[n]=n;return t}get Enum(){const t={};for(const n of this._def.values)t[n]=n;return t}extract(t,n=this._def){return Gi.create(t,{...this._def,...n})}exclude(t,n=this._def){return Gi.create(this.options.filter(r=>!t.includes(r)),{...this._def,...n})}}Gi.create=QC;class J0 extends Ce{_parse(t){const n=Re.getValidEnumValues(this._def.values),r=this._getOrReturnCtx(t);if(r.parsedType!==Y.string&&r.parsedType!==Y.number){const s=Re.objectValues(n);return q(r,{expected:Re.joinValues(s),received:r.parsedType,code:U.invalid_type}),fe}if(this._cache||(this._cache=new Set(Re.getValidEnumValues(this._def.values))),!this._cache.has(t.data)){const s=Re.objectValues(n);return q(r,{received:r.data,code:U.invalid_enum_value,options:s}),fe}return Tn(t.data)}get enum(){return this._def.values}}J0.create=(e,t)=>new J0({values:e,typeName:he.ZodNativeEnum,...ye(t)});class ld extends Ce{unwrap(){return this._def.type}_parse(t){const{ctx:n}=this._processInputParams(t);if(n.parsedType!==Y.promise&&n.common.async===!1)return q(n,{code:U.invalid_type,expected:Y.promise,received:n.parsedType}),fe;const r=n.parsedType===Y.promise?n.data:Promise.resolve(n.data);return Tn(r.then(s=>this._def.type.parseAsync(s,{path:n.path,errorMap:n.common.contextualErrorMap})))}}ld.create=(e,t)=>new ld({type:e,typeName:he.ZodPromise,...ye(t)});class Yi extends Ce{innerType(){return this._def.schema}sourceType(){return this._def.schema._def.typeName===he.ZodEffects?this._def.schema.sourceType():this._def.schema}_parse(t){const{status:n,ctx:r}=this._processInputParams(t),s=this._def.effect||null,o={addIssue:i=>{q(r,i),i.fatal?n.abort():n.dirty()},get path(){return r.path}};if(o.addIssue=o.addIssue.bind(o),s.type==="preprocess"){const i=s.transform(r.data,o);if(r.common.async)return Promise.resolve(i).then(async a=>{if(n.value==="aborted")return fe;const l=await this._def.schema._parseAsync({data:a,path:r.path,parent:r});return l.status==="aborted"?fe:l.status==="dirty"||n.value==="dirty"?Ga(l.value):l});{if(n.value==="aborted")return fe;const a=this._def.schema._parseSync({data:i,path:r.path,parent:r});return a.status==="aborted"?fe:a.status==="dirty"||n.value==="dirty"?Ga(a.value):a}}if(s.type==="refinement"){const i=a=>{const l=s.refinement(a,o);if(r.common.async)return Promise.resolve(l);if(l instanceof Promise)throw new Error("Async refinement encountered during synchronous parse operation. Use .parseAsync instead.");return a};if(r.common.async===!1){const a=this._def.schema._parseSync({data:r.data,path:r.path,parent:r});return a.status==="aborted"?fe:(a.status==="dirty"&&n.dirty(),i(a.value),{status:n.value,value:a.value})}else return this._def.schema._parseAsync({data:r.data,path:r.path,parent:r}).then(a=>a.status==="aborted"?fe:(a.status==="dirty"&&n.dirty(),i(a.value).then(()=>({status:n.value,value:a.value}))))}if(s.type==="transform")if(r.common.async===!1){const i=this._def.schema._parseSync({data:r.data,path:r.path,parent:r});if(!Ki(i))return fe;const a=s.transform(i.value,o);if(a instanceof Promise)throw new Error("Asynchronous transform encountered during synchronous parse operation. Use .parseAsync instead.");return{status:n.value,value:a}}else return this._def.schema._parseAsync({data:r.data,path:r.path,parent:r}).then(i=>Ki(i)?Promise.resolve(s.transform(i.value,o)).then(a=>({status:n.value,value:a})):fe);Re.assertNever(s)}}
283Yi.create=(e,t,n)=>new Yi({schema:e,typeName:he.ZodEffects,effect:t,...ye(n)});Yi.createWithPreprocess=(e,t,n)=>new Yi({schema:t,effect:{type:"preprocess",transform:e},typeName:he.ZodEffects,...ye(n)});class As extends Ce{_parse(t){return this._getType(t)===Y.undefined?Tn(void 0):this._def.innerType._parse(t)}unwrap(){return this._def.innerType}}As.create=(e,t)=>new As({innerType:e,typeName:he.ZodOptional,...ye(t)});class Zi extends Ce{_parse(t){return this._getType(t)===Y.null?Tn(null):this._def.innerType._parse(t)}unwrap(){return this._def.innerType}}Zi.create=(e,t)=>new Zi({innerType:e,typeName:he.ZodNullable,...ye(t)});class _m extends Ce{_parse(t){const{ctx:n}=this._processInputParams(t);let r=n.data;return n.parsedType===Y.undefined&&(r=this._def.defaultValue()),this._def.innerType._parse({data:r,path:n.path,parent:n})}removeDefault(){return this._def.innerType}}_m.create=(e,t)=>new _m({innerType:e,typeName:he.ZodDefault,defaultValue:typeof t.default=="function"?t.default:()=>t.default,...ye(t)});class Sm extends Ce{_parse(t){const{ctx:n}=this._processInputParams(t),r={...n,common:{...n.common,issues:[]}},s=this._def.innerType._parse({data:r.data,path:r.path,parent:{...r}});return sd(s)?s.then(o=>({status:"valid",value:o.status==="valid"?o.value:this._def.catchValue({get error(){return new Kr(r.common.issues)},input:r.data})})):{status:"valid",value:s.status==="valid"?s.value:this._def.catchValue({get error(){return new Kr(r.common.issues)},input:r.data})}}removeCatch(){return this._def.innerType}}Sm.create=(e,t)=>new Sm({innerType:e,typeName:he.ZodCatch,catchValue:typeof t.catch=="function"?t.catch:()=>t.catch,...ye(t)});class X0 extends Ce{_parse(t){if(this._getType(t)!==Y.nan){const r=this._getOrReturnCtx(t);return q(r,{code:U.invalid_type,expected:Y.nan,received:r.parsedType}),fe}return{status:"valid",value:t.data}}}X0.create=e=>new X0({typeName:he.ZodNaN,...ye(e)});class qB extends Ce{_parse(t){const{ctx:n}=this._processInputParams(t),r=n.data;return this._def.type._parse({data:r,path:n.path,parent:n})}unwrap(){return this._def.type}}class Ev extends Ce{_parse(t){const{status:n,ctx:r}=this._processInputParams(t);if(r.common.async)return(async()=>{const o=await this._def.in._parseAsync({data:r.data,path:r.path,parent:r});return o.status==="aborted"?fe:o.status==="dirty"?(n.dirty(),Ga(o.value)):this._def.out._parseAsync({data:o.value,path:r.path,parent:r})})();{const s=this._def.in._parseSync({data:r.data,path:r.path,parent:r});return s.status==="aborted"?fe:s.status==="dirty"?(n.dirty(),{status:"dirty",value:s.value}):this._def.out._parseSync({data:s.value,path:r.path,parent:r})}}static create(t,n){return new Ev({in:t,out:n,typeName:he.ZodPipeline})}}class Em extends Ce{_parse(t){const n=this._def.innerType._parse(t),r=s=>(Ki(s)&&(s.value=Object.freeze(s.value)),s);return sd(n)?n.then(s=>r(s)):r(n)}unwrap(){return this._def.innerType}}Em.create=(e,t)=>new Em({innerType:e,typeName:he.ZodReadonly,...ye(t)});Ge.lazycreate;var he;(function(e){e.ZodString="ZodString",e.ZodNumber="ZodNumber",e.ZodNaN="ZodNaN",e.ZodBigInt="ZodBigInt",e.ZodBoolean="ZodBoolean",e.ZodDate="ZodDate",e.ZodSymbol="ZodSymbol",e.ZodUndefined="ZodUndefined",e.ZodNull="ZodNull",e.ZodAny="ZodAny",e.ZodUnknown="ZodUnknown",e.ZodNever="ZodNever",e.ZodVoid="ZodVoid",e.ZodArray="ZodArray",e.ZodObject="ZodObject",e.ZodUnion="ZodUnion",e.ZodDiscriminatedUnion="ZodDiscriminatedUnion",e.ZodIntersection="ZodIntersection",e.ZodTuple="ZodTuple",e.ZodRecord="ZodRecord",e.ZodMap="ZodMap",e.ZodSet="ZodSet",e.ZodFunction="ZodFunction",e.ZodLazy="ZodLazy",e.ZodLiteral="ZodLiteral",e.ZodEnum="ZodEnum",e.ZodEffects="ZodEffects",e.ZodNativeEnum="ZodNativeEnum",e.ZodOptional="ZodOptional",e.ZodNullable="ZodNullable",e.ZodDefault="ZodDefault",e.ZodCatch="ZodCatch",e.ZodPromise="ZodPromise",e.ZodBranded="ZodBranded",e.ZodPipeline="ZodPipeline",e.ZodReadonly="ZodReadonly"})(he||(he={}));const Qo=bs.create;$s.create;yr.create;const KB=Ge.create;Ge.strictCreate;id.create;ad.create;Ao.create;Gi.create;ld.create;As.create;Zi.create;const GB=e=>{const t=[new Date(e,0,1),new Date(e,2,1),new Date(e,4,5),new Date(e,5,6),new Date(e,7,15),new Date(e,9,3),new Date(e,9,9),new Date(e,11,25)],n={2025:[new Date(2025,0,28),new Date(2025,0,29),new Date(2025,0,30),new Date(2025,0,27),new Date(2025,2,3),new Date(2025,4,5),new Date(2025,4,6),new Date(2025,9,5),new Date(2025,9,6),new Date(2025,9,7),new Date(2025,9,8)],2026:[new Date(2026,1,16),new Date(2026,1,17),new Date(2026,1,18),new Date(2026,4,24),new Date(2026,8,24),new Date(2026,8,25),new Date(2026,8,26)],2027:[new Date(2027,1,5),new Date(2027,1,6),new Date(2027,1,7),new Date(2027,1,8),new Date(2027,4,13),new Date(2027,9,14),new Date(2027,9,15),new Date(2027,9,16)],2028:[new Date(2028,0,25),new Date(2028,0,26),new Date(2028,0,27),new Date(2028,0,28),new Date(2028,4,2),new Date(2028,9,2),new Date(2028,9,3),new Date(2028,9,4)],2029:[new Date(2029,1,12),new Date(2029,1,13),new Date(2029,1,14),new Date(2029,4,20),new Date(2029,8,21),new Date(2029,8,22),new Date(2029,8,23),new Date(2029,8,24)],2030:[new Date(2030,1,2),new Date(2030,1,3),new Date(2030,1,4),new Date(2030,4,9),new Date(2030,8,11),new Date(2030,8,12),new Date(2030,8,13)],2031:[new Date(2031,0,22),new Date(2031,0,23),new Date(2031,0,24),new Date(2031,3,28),new Date(2031,9,1),new Date(2031,9,2),new Date(2031,9,3)],2032:[new Date(2032,1,10),new Date(2032,1,11),new Date(2032,1,12),new Date(2032,1,13),new Date(2032,4,16),new Date(2032,8,19),new Date(2032,8,20),new Date(2032,8,21)],2033:[new Date(2033,0,30),new Date(2033,0,31),new Date(2033,1,1),new Date(2033,4,6),new Date(2033,9,8),new Date(2033,9,9),new Date(2033,9,10),new Date(2033,9,11)],2034:[new Date(2034,1,18),new Date(2034,1,19),new Date(2034,1,20),new Date(2034,1,21),new Date(2034,4,25),new Date(2034,8,26),new Date(2034,8,27),new Date(2034,8,28)],2035:[new Date(2035,1,7),new Date(2035,1,8),new Date(2035,1,9),new Date(2035,4,15),new Date(2035,9,15),new Date(2035,9,16),new Date(2035,9,17)]};return n[e]&&t.push(...n[e]),t},eb=e=>GB(e.getFullYear()).some(n=>n.getFullYear()===e.getFullYear()&&n.getMonth()===e.getMonth()&&n.getDate()===e.getDate()),tb=(e,t)=>{const n=`${e.getFullYear()}
283-${String(e.getMonth()+1).padStart(2,"0")}-${String(e.getDate()).padStart(2,"0")}`;return t.includes(n)},YB=Array.from({length:15},(e,t)=>{const n=10+Math.floor(t/2),r=t%2===0?"00":"30";return`${n}:${r}`}).filter(e=>e<="17:00"),ZB=KB({name:Qo().trim().min(1,"ì±ëª
ì ì
ë ¥í´ì£¼ì¸ì").max(50),phone:Qo().trim().min(1,"ì°ë½ì²ë¥¼ ì
ë ¥í´ì£¼ì¸ì").max(20),client_type:Qo().min(1,"ìë´ì 구ë¶ì ì íí´ì£¼ì¸ì"),consultation_type:Qo().min(1,"ìë´ ì íì ì íí´ì£¼ì¸ì"),consultation_method:Qo().min(1,"ìë´ ë°©ìì ì íí´ì£¼ì¸ì"),message:Qo().max(1e3).default("")}),QB=()=>{const[e,t]=m.useState(),[n,r]=m.useState(""),[s,o]=m.useState({name:"",phone:"",client_type:"",consultation_type:"",consultation_method:"",message:""}),[i,a]=m.useState(!1),[l,c]=m.useState([]),[u,d]=m.useState([]);m.useEffect(()=>{fr.from("custom_holidays").select("holiday_date").then(({data:g})=>{d((g||[]).map(y=>y.holiday_date))})},[]);const p=async g=>{const y=g.toISOString().split("T")[0],{data:_}=await fr.from("bookings").select("booking_time").eq("booking_date",y);c((_||[]).map(S=>S.booking_time).filter(Boolean))},h=g=>{const y=new Date;return g.getFullYear()===y.getFullYear()&&g.getMonth()===y.getMonth()&&g.getDate()===y.getDate()},x=g=>{if(g&&h(g)){Rr.error("ë¹ì¼ ìë´ìì½ì ì´ë ¤ì°ë ë¤ë¥¸ ë ì§ë¥¼ ì íí´ì£¼ì¸ì.");return}if(g&&(eb(g)||tb(g,u))){Rr.error("ê³µí´ì¼ìë ìë´ ìì½ì´ ë¶ê°í©ëë¤. ë¤ë¥¸ ë ì§ë¥¼ ì íí´ì£¼ì¸ì.");return}t(g),r(""),g?p(g):c([])},v=YB.filter(g=>!l.includes(g)),b=async g=>{if(g.preventDefault(),!e){Rr.error("ìë´ í¬ë§ ë ì§ë¥¼ ì íí´ì£¼ì¸ì.");return}if(h(e)){Rr.error("ë¹ì¼ ìë´ìì½ì ì´ë ¤ì°ë ë¤ë¥¸ ë ì§ë¥¼ ì íí´ì£¼ì¸ì.");return}if(!n){Rr.error("ìë´ í¬ë§ ìê°ì ì íí´ì£¼ì¸ì.");return}const y=ZB.safeParse(s);if(!y.success){Rr.error(y.error.errors[0].message);return}a(!0);try{const _={company:"",name:y.data.name,phone:y.data.phone,message:y.data.message,booking_date:e.toISOString().split("T")[0],booking_time:n,client_type:y.data.client_type,consultation_type:y.data.consultation_type,consultation_method:y.data.consultation_method},{data:S}=await fr.from("bookings").select("id").eq("booking_date",_.booking_date).eq("booking_time",_.booking_time);if(S&&S.length>0){Rr.error("í´ë¹ ìê°ì ì´ë¯¸ ìì½ì´ ììµëë¤. ë¤ë¥¸ ìê°ì ì íí´ì£¼ì¸ì."),a(!1),e&&p(e);return}const{error:k}=await fr.from("bookings").insert(_);if(k){Rr.error("ìì½ ì ìì ì¤í¨íìµëë¤. ë¤ì ìëí´ì£¼ì¸ì.");return}fr.functions.invoke("send-booking-email",{body:{booking_date:_.booking_date,booking_time:_.booking_time,name:_.name,phone:_.phone,client_type:_.client_type,consultation_type:_.consultation_type,consultation_method:_.consultation_method,message:_.message}}).catch(E=>console.error("Email notification failed:",E)),rd("form_submit"),Rr.success("ìë´ ìì½ì´ ì ìëììµëë¤. ë¹ ë¥¸ ìì¼ ë´ì ì°ë½ëë¦¬ê² ìµëë¤."),o({name:"",phone:"",client_type:"",consultation_type:"",consultation_method:"",message:""}),t(void 0),r("")}finally{a(!1)}},w=Ms();return f.jsx("section",{id:"booking",className:"py-20 md:py-28 bg-secondary",children:f.jsxs("div",{ref:w.ref,style:w.style,className:"container mx-auto px-4",children:[f.jsx("div",{className:"text-center mb-14",children:f.jsx("h2",{className:"text-3xl md:text-4xl font-bold text-white mb-4",children:"ìë´ ìì½"})}),f.jsxs("form",{onSubmit:b,className:"max-w-4xl mx-auto bg-background rounded-2xl shadow-lg p-8 md:p-10 grid md:grid-cols-2 gap-8",children:[f.jsxs("div",{className:"flex flex-col items-center gap-4",children:[f.jsx(_k,{mode:"single",selected:e,onSelect:x,disabled:g=>{const y=new Date;return y.setHours(0,0,0,0),g<=y||g.getDay()===0||g.getDay()===6||eb(g)||tb(g,u)},className:"rounded-xl border [&_thead_tr_th:first-child]:text-red-500 [&_thead_tr_th:last-child]:text-blue-500",locale:{localize:{day:g=>["ì¼","ì","í","ì","목","ê¸","í "][g],month:g=>`${g+1}ì`,ordinalNumber:g=>`${g}`,era:()=>"",quarter:()=>"",dayPeriod:()=>""},formatLong:{date:()=>"yyyy-MM-dd",time:()=>"HH:mm",dateTime:()=>"yyyy-MM-dd HH:mm"},options:{weekStartsOn:0,firstWeekContainsDate:1},code:"ko",match:void 0,formatDistance:void 0,formatRelative:void 0},formatters:{formatCaption:g=>`${g.getFullYear()}ë
${g.getMonth()+1}ì`}}),f.jsxs("div",{className:"w-full max-w-[280px]",children:[f.jsx("label",{className:"text-sm font-medium text-foreground mb-2 block",children:"ìë´ ë°©ì"}),f.jsxs(hu,{value:s.consultation_method,onValueChange:g=>o({...s,consultation_method:g}),className:"grid grid-cols-2 gap-x-4 gap-y-3",children:[f.jsxs("div",{className:"flex items-center gap-2.5",children:[f.jsx(Ar,{value:"방문 ìë´",id:"method-visit"}),f.jsx(Or,{htmlFor:"method-visit",className:"cursor-pointer",children:"방문 ìë´"})]}),f.jsxs("div",{className:"flex items-center gap-2.5",children:[f.jsx(Ar,{value:"ì í ìë´",id:"method-phone"}),f.jsx(Or,{htmlFor:"method-phone",className:"cursor-pointer",children:"ì í ìë´"})]})]})]}),f.jsxs("div",{className:"w-full max-w-[280px]",children:[f.jsx("label",{className:"text-sm font-medium text-foreground mb-1 block",children:"ìë´ í¬ë§ ìê°"}),f.jsxs(c3,{value:n,onValueChange:r,children:[f.jsx(oC,{className:"w-full",children:f.jsx(u3,{placeholder:e?v.length===0?"ìì½ ê°ë¥í ìê° ìì":"ìê°ì ì ííì¸ì":"ë ì§ë¥¼ 먼ì ì ííì¸ì"})}),f.jsxs(lC,{children:[v.map(g=>f.jsx(cC,{value:g,children:g},g)),e&&v.length===0&&f.jsx("div",{className:"px-3 py-2 text-sm text-muted-foreground",children:"ìì½ ê°ë¥í ìê°ì´ ììµëë¤"})]})]})]})]}),f.jsxs("div",{className:"flex flex-col gap-4",children:[f.jsxs("div",{children:[f.jsx("label",{className:"text-sm font-medium text-foreground mb-1 block",children:"ì±ëª
"}),f.jsx(tm,{placeholder:"í길ë",value:s.name,onChange:g=>o({...s,name:g.target.value}),required:!0})]}),f.jsxs("div",{children:[f.jsx("label",{className:"text-sm font-medium text-foreground mb-1 block",children:"ì°ë½ì²"}),f.jsx(tm,{placeholder:"010-0000-0000",value:s.phone,onChange:g=>o({...s,phone:g.target.value}),required:!0})]}),f.jsxs("div",{children:[f.jsx("label",{className:"text-sm font-medium text-foreground mb-2 block",children:"ìë´ì 구ë¶"}),f.jsxs(hu,{value:s.client_type,onValueChange:g=>o({...s,client_type:g}),className:"grid grid-cols-2 gap-x-4 gap-y-3",children:[f.jsxs("div",{className:"flex items-center gap-2.5",children:[f.jsx(Ar,{value:"ì¬ì
주",id:"client-employer"}),f.jsx(Or,{htmlFor:"client-employer",className:"cursor-pointer",children:"ì¬ì
주"})]}),f.jsxs("div",{className:"flex items-center gap-2.5",children:[f.jsx(Ar,{value:"ê·¼ë¡ì",id:"client-worker"}),f.jsx(Or,{htmlFor:"client-worker",className:"cursor-pointer",children:"ê·¼ë¡ì"})]})]})]}),f.jsxs("div",{children:[f.jsx("label",{className:"text-sm font-medium text-foreground mb-2 block",children:"ìë´ ì í"}),f.jsxs(hu,{value:s.consultation_type,onValueChange:g=>o({...s,consultation_type:g}),className:"grid grid-cols-2 gap-x-4 gap-y-3",children:[f.jsxs("div",{className:"flex items-center gap-2.5",children:[f.jsx(Ar,{value:"ë
¸ëë² ì¼ë°",id:"type-general"}),f.jsx(Or,{htmlFor:"type-general",className:"cursor-pointer",children:"ë
¸ëë² ì¼ë°"})]}),f.jsxs("div",{className:"flex items-center gap-2.5",children:[f.jsx(Ar,{value:"ì문/ê¸ì¬",id:"type-advisory"}),f.jsx(Or,{htmlFor:"type-advisory",className:"cursor-pointer",children:"ì문/ê¸ì¬"})]}),f.jsxs("div",{className:"flex items-center gap-2.5",children:[f.jsx(Ar,{value:"ë
¸ë ì¬ê±´",id:"type-labor"}),f.jsx(Or,{htmlFor:"type-labor",className:"cursor-pointer",children:"ë
¸ë ì¬ê±´"})]}),f.jsxs("div",{className:"flex items-center gap-2.5",children:[f.jsx(Ar,{value:"기í",id:"type-other"}),f.jsx(Or,{htmlFor:"type-other",className:"cursor-pointer",children:"기í"})]})]})]}),f.jsxs("div",{children:[f.jsx("label",{className:"text-sm font-medium text-foreground mb-1 block",children:"문ì ë´ì©"}),f.jsx(Sk,{placeholder:"ìë´ ë°ê³ ì¶ì ë´ì©ì ê°ë¨í ì ì´ì£¼ì¸ì",value:s.message,onChange:g=>o({...s,message:g.target.value}),rows:3})]}),f.jsx(Yu,{type:"submit",disabled:i,className:"bg-accent text-accent-foreground hover:bg-accent/90 rounded-full h-12 text-base mt-2",children:i?"ì ì ì¤...":"ìë´ ìì½ ì ì²"})]})]})]})})},JB="60779906-5379-47fe-9474-376b0c08d8be";let Fa=null,Ua=null;function XB(){if(window.ChannelIO)return;const e=function(...t){e.c(t)};e.q=[],e.c=function(t){e.q.push(t)},window.ChannelIO=e}function JC(){return typeof window>"u"?Promise.resolve():Fa||(Fa=new Promise((e,t)=>
283{var o;if(XB(),document.querySelector('script[src="https://cdn.channel.io/plugin/ch-plugin-web.js"]')){e();return}const r=document.createElement("script");r.async=!0,r.src="https://cdn.channel.io/plugin/ch-plugin-web.js",r.onload=()=>e(),r.onerror=()=>{Fa=null,t(new Error("failed to load channel talk script"))};const s=document.getElementsByTagName("script")[0];(o=s==null?void 0:s.parentNode)==null||o.insertBefore(r,s)}),Fa)}function ez(e){const t={pluginKey:JB,hideChannelButtonOnBoot:!0};return e!=null&&e.userId&&(t.memberId=e.userId,t.profile={name:e.name||void 0,email:e.email||void 0}),t}function XC(e){return!window.ChannelIO||window.__channelTalkBooted?Promise.resolve():Ua||(Ua=new Promise((t,n)=>{window.ChannelIO("boot",ez(e),r=>{Ua=null,r?(window.__channelTalkBooted=!1,n(r)):(window.__channelTalkBooted=!0,t())})}),Ua)}async function eT(){const{data:{session:e}}=await fr.auth.getSession();if(!(e!=null&&e.user))return;const{data:t}=await fr.from("admin_profiles").select("name").eq("user_id",e.user.id).maybeSingle();return{userId:e.user.id,email:e.user.email,name:(t==null?void 0:t.name)||e.user.email}}async function nb(){var e;try{await JC(),window.__channelTalkBooted&&((e=window.ChannelIO)==null||e.call(window,"shutdown"),window.__channelTalkBooted=!1);const t=await eT();await XC(t)}catch(t){console.error("[ChannelTalk] init failed:",t)}}async function tz(){var e;try{if(await JC(),!window.__channelTalkBooted){const t=await eT();await XC(t)}(e=window.ChannelIO)==null||e.call(window,"showMessenger")}catch(t){console.error("[ChannelTalk] open failed:",t)}}function nz(){m.useEffect(()=>{let e=!0;(async()=>{e&&await nb()})();const{data:{subscription:n}}=fr.auth.onAuthStateChange(()=>{nb()});return()=>{e=!1,n.unsubscribe()}},[])}const rz=()=>{const[e,t]=m.useState(!1),n=async()=>{rd("channeltalk"),await tz(),t(!1)};return f.jsxs("div",{className:"fixed bottom-6 right-6 z-50 flex flex-col items-end gap-3",children:[e&&f.jsxs("div",{className:"flex flex-col gap-3 animate-fade-in",children:[f.jsxs("a",{href:"tel:051-715-9591",className:"flex items-center gap-3 bg-background shadow-lg rounded-full pl-4 pr-5 py-3 hover:shadow-xl transition-shadow",children:[f.jsx(Np,{className:"w-5 h-5 text-accent"}),f.jsx("span",{className:"text-sm font-medium text-foreground",children:"ì í ìë´"})]}),f.jsxs("button",{onClick:n,"aria-label":"ì±ëí¡ ìë´ ì´ê¸°",className:"flex items-center gap-3 bg-background shadow-lg rounded-full pl-4 pr-5 py-3 hover:shadow-xl transition-shadow",children:[f.jsx(gA,{className:"w-5 h-5 text-accent"}),f.jsx("span",{className:"text-sm font-medium text-foreground",children:"ì±ëí¡ ìë´"})]})]}),f.jsx("button",{onClick:()=>t(!e),"aria-label":e?"ìë´ ë©ë´ ë«ê¸°":"ìë´ ë©ë´ ì´ê¸°","aria-expanded":e,className:"w-14 h-14 rounded-full bg-accent text-accent-foreground shadow-lg hover:shadow-xl hover:scale-105 transition-all flex items-center justify-center",children:e?f.jsx(Od,{className:"w-6 h-6"}):f.jsx(Np,{className:"w-6 h-6"})})]})},sz=()=>{const[e,t]=m.useState(!0),n=Do();return f.jsx("footer",{className:"bg-secondary border-t border-border text-foreground py-12",children:f.jsx("div",{className:"container mx-auto px-4",children:f.jsxs("div",{className:"flex flex-col items-center gap-6",children:[f.jsxs("div",{className:"flex items-center gap-3 mb-2",children:[f.jsxs("button",{onClick:()=>n("/portal?type=member"),className:"inline-flex items-center gap-2 px-5 py-2.5 rounded-full bg-black text-white text-sm font-semibold hover:bg-black/80 transition-colors",children:[f.jsx(ow,{className:"w-4 h-4"}),"íìì¬ ì ì©"]}),f.jsxs("button",{onClick:()=>n("/portal?type=client"),className:"inline-flex items-center gap-2 px-5 py-2.5 rounded-full bg-black text-white text-sm font-semibold hover:bg-black/80 transition-colors",children:[f.jsx($u,{className:"w-4 h-4"}),"ìë¢°ì¸ ì ì©"]})]}),f.jsxs("div",{className:"text-sm flex flex-col items-center",children:[f.jsxs("button",{onClick:()=>t(!e),"aria-expanded":e,className:"flex items-center gap-1 text-foreground font-semibold hover:text-accent transition-colors",children:["êµë³´ ì¸ì¬ë
¸ë¬´ì»¨ì¤í
283
ì¬ì
ì ì ë³´",f.jsx(Pd,{className:`w-4 h-4 transition-transform duration-300 ${e?"rotate-180":""}`})]}),f.jsx("div",{className:`overflow-hidden transition-all duration-300 ${e?"max-h-60 opacity-100":"max-h-0 opacity-0"}`,children:f.jsxs("div",{className:"space-y-2 pt-3 text-muted-foreground",children:[f.jsxs("p",{className:"flex items-center gap-2",children:[f.jsx(ow,{className:"w-4 h-4 flex-shrink-0"}),"êµë³´ ì¸ì¬ë
¸ë¬´ì»¨ì¤í
"]}),f.jsxs("p",{className:"flex items-center gap-2",children:[f.jsx($u,{className:"w-4 h-4 flex-shrink-0"}),"ê³µì¸ë
¸ë¬´ì¬ ì¬êµë³´"]}),f.jsxs("p",{className:"flex items-center gap-2",children:[f.jsx(Np,{className:"w-4 h-4 flex-shrink-0"}),"051-715-9591"]}),f.jsxs("p",{className:"flex items-center gap-2",children:[f.jsx(hA,{className:"w-4 h-4 flex-shrink-0"}),"[email protected]"]}),f.jsxs("p",{className:"flex items-start gap-2",children:[f.jsx(pA,{className:"w-4 h-4 flex-shrink-0 mt-0.5"}),f.jsxs("span",{children:["ë¶ì°ê´ìì ê°ì구 ëª
ì§êµì 11ë¡ 66",f.jsx("br",{}),"ìëìì¤ë¹ë© 301í¸"]})]}),f.jsxs("p",{className:"flex items-center gap-2",children:[f.jsx(dA,{className:"w-4 h-4 flex-shrink-0"}),"íì¼ 09:00 - 18:00"]})]})})]}),f.jsx("p",{className:"text-xs text-muted-foreground border-t border-border pt-4 w-full text-center",children:"© 2018 êµë³´ ì¸ì¬ë
¸ë¬´ì»¨ì¤í
. All rights reserved."})]})})})},oz="https://www.siimlab.com",iz=({title:e,description:t,path:n,type:r="website",jsonLd:s})=>{const o=`${oz}${n}`;return f.jsxs(oN,{children:[f.jsx("title",{children:e}),f.jsx("meta",{name:"description",content:t}),f.jsx("link",{rel:"canonical",href:o}),f.jsx("meta",{property:"og:title",content:e}),f.jsx("meta",{property:"og:description",content:t}),f.jsx("meta",{property:"og:type",content:r}),f.jsx("meta",{property:"og:url",content:o}),f.jsx("meta",{name:"twitter:title",content:e}),f.jsx("meta",{name:"twitter:description",content:t}),s&&f.jsx("script",{type:"application/ld+json",children:JSON.stringify(s)})]})},az=()=>(nz(),f.jsxs("main",{className:"min-h-screen",children:[f.jsx(iz,{title:"êµë³´ ì¸ì¬ë
¸ë¬´ì»¨ì¤í
â ë¶ì° ê³µì¸ë
¸ë¬´ì¬ ì¸ì¬ë
¸ë¬´ ì문",description:"ë¶ì° ê°ì구 ëª
ì§ êµë³´ ì¸ì¬ë
¸ë¬´ì»¨ì¤í
. 16ë
ê²½ë ¥ ê³µì¸ë
¸ë¬´ì¬ê° ì¸ì¬ë
¸ë¬´ ì문, ê¸ì¬Â·4ëë³´í ê´ë¦¬, ë¶ë¹í´ê³ 구ì ì ì²ê¹ì§ 기ì
ê³¼ ê·¼ë¡ì를 ì§ìí©ëë¤.",path:"/"}),f.jsx(BM,{}),f.jsx(VM,{}),f.jsx(qM,{}),f.jsx(JM,{}),f.jsx(oL,{}),f.jsx(iL,{}),f.jsx(GL,{}),f.jsx(QB,{}),f.jsx(sz,{}),f.jsx(rz,{})]})),lz=()=>f.jsx("div",{className:"flex items-center justify-center min-h-screen bg-background",children:f.jsx("div",{className:"spinner",children:Array.from({length:8}).map((e,t)=>f.jsx("div",{className:"spinner-dot"},t))})}),cz=()=>{const e=Hs();return m.useEffect(()=>{bB(e.pathname)},[e.pathname]),m.useEffect(()=>{const t=n=>{var i;const r=n.target,s=(i=r==null?void 0:r.closest)==null?void 0:i.call(r,"a[href]"),o=(s==null?void 0:s.getAttribute("href"))||"";o.startsWith("tel:")?rd("tel_click"):o.startsWith("mailto:")&&rd("email_click")};return document.addEventListener("click",t,!0),()=>document.removeEventListener("click",t,!0)},[]),null},uz=m.lazy(()=>zs(()=>import("./NotFound-CPx1L6Bx.js"),[])),dz=m.lazy(()=>zs(()=>import("./AdminAuth-C-TIsKpF.js"),[])),fz=m.lazy(()=>zs(()=>import("./AdminDashboard-wdoVHJcn.js"),__vite__mapDeps([0,1,2,3,4,5,6]))),Th=m.lazy(()=>zs(()=>import("./CaseDetail-AzgP5wPd.js"),__vite__mapDeps([7,3,6,4]))),hz=m.lazy(()=>zs(()=>import("./MemberAuth-CA7IRgxz.js"),__vite__mapDeps([8,9,3]))),pz=m.lazy(()=>zs(()=>import("./MemberDashboard-BgUc8TeM.js"),__vite__mapDeps([10,11,1,3,2,9]))),mz=m.lazy(()=>zs(()=>import("./ClientDashboard-oRgLFysq.js"),__vite__mapDeps([12,11,1,3,9,5]))),gz=m.lazy(()=>zs(()=>import("./DiagnosisPage-CJ4Wd1mD.js"),__vite__mapDeps([13,3,6]))),vz=new BI,yz=()=>f.jsx(WI,{client:vz,children:f.jsxs(vI,{children:[f.jsx(eO,{}),f.jsx(OO,{}),f.jsxs(BD,{children:[f.jsx(cz,{}),f.jsx(m.Suspense,{fallback:f.jsx(lz,{}),children:f.jsxs(jD,{children:[f.jsx(Qt,{path:"/",element:f.jsx(az,{})}),f.jsx(Qt,{path:"/blog",element:f.jsx(Th,{})}),f.jsx(Qt,{path:"/blog/:postNumber",element:f.jsx(Th,{})}),f.jsx(Qt,{path:"/cases",element:f.jsx(AD,{to:"/blog",replace:!0})}),f.jsx(Qt,{path:"/cases/:id",element:f.jsx(Th,{})}),f.jsx(Qt,{path:"/admin/login",element:f.jsx(dz,{})}),f.jsx(Qt,{path:"/admin",element:f.jsx(fz,{})}),f.jsx(Qt,{path:"/portal",element:f.jsx(hz,{})}),f.jsx(Qt,{path:"/member/dashboard",element:f.jsx(pz,{})}),f.jsx(Qt,{path:"/client/dashboard",element:f.jsx(mz,{})}),f.jsx(Qt,{path:"/diagnosis",element:f.jsx(gz,{})}),f.jsx(Qt,{path:"*",element:f.jsx(uz,{})})]})})]})]})});E_(document.getElementById("root")).render(f.jsx(A_,{children:f.jsx(yz,{})}));export{ne as $,aS as A,Yu as B,_k as C,Gt as D,Nz as E,de as F,lE as G,oN as H,tm as I,K as J,cE as K,uE as L,wM as M,yN as N,aE as O,yM as P,gM as Q,O as R,c3 as S,vM as T,me as U,Gp as V,Az as W,cA as X,Pd as Y,Ld as Z,FS as _,Do as a,dn as a0,H1 as a1,qg as a2,M1 as a3,Vg as a4,Ql as a5,US as a6,BS as a7,Cd as a8,zi as a9,Ma as aA,x$ as aB,La as aC,Eg as aD,bM as aE,fE as aF,hE as aG,pE as aH,Va as aI,dC as aJ,oa as aK,S3 as aL,E3 as aM,Gn as aa,Xj as ab,Ur as ac,$u as ad,Od as ae,Sk as af,Or as ag,Wd as ah,Md as ai,ow as aj,mA as ak,Cz as al,kz as am,BM as an,iz as ao,Na as ap,RL as aq,sz as ar,rz as as,Tz as at,hu as au,Ar as av,dA as aw,Np as ax,hA as ay,dh as az,Rr as b,fr as c,at as d,bz as e,oS as f,Hl as g,qi as h,Mo as i,f as j,fh as k,Nd as l,Ad as m,S_ as n,KB as o,Io as p,jz as q,m as r,Qo as s,oC as t,Hs as u,u3 as v,lC as w,cC as x,tL as y,nL as z};
Line numbers count LF bytes from the start of the resource, as the search results do. Vendor segments are library code the classifier recognised; they are stored but not indexed. Bytes are shown as Latin1 characters, one per byte.