1const __vite__mapDeps=(i,m=__vite__mapDeps,d=(m.f||(m.f=["assets/progress.page-B40lKx4M.js","assets/index-DrpVUG_w.js","assets/metrics-C1oYPf8N.js","assets/progress_analytics_icon-Bpk1suwI.js","assets/marker_icon-C2eBNoGY.js","assets/clock_icon-DIppvskh.js","assets/module-progress-3imittHq.js","assets/utils-DgU0FEbZ.js","assets/progress-badge-BfDD-pA0.js","assets/check_icon-DcKto_lO.js","assets/tooltip-wrapper--2PwgTMl.js","assets/review_exam_icon-CBPhmZ15.js","assets/search_icon-CSlyrV_Y.js","assets/check_circle_gradient_icon-D4RNYn_F.js","assets/chevron_right_icon-DvCXrcJA.js","assets/star_icon-Cd6kJaBM.js","assets/flag_icon-CN-cjVKi.js","assets/chevron_down_icon-WuaaMogj.js","assets/bookmark_icon-B7uoWVtU.js","assets/practice.page-Bp3Jq6fZ.js","assets/accordion-modal-1FTcpKgX.js","assets/arrow_right-Bw3fXVy3.js","assets/highlighter_icon-B1RYi46l.js","assets/queries-Bb_Y_seP.js","assets/question-difficulty-badge-j5hq9ypo.js","assets/question-answer-gHDdcCpm.js","assets/instruction-html-Bc4py9-C.js","assets/format-timer-time-
1BD8VfAPb.js","assets/index-BJD95C6U.js","assets/question-skeleton-jNIZm9f5.js","assets/arrow_left-C0ADZkFO.js","assets/index.esm-Cni_MQLG.js","assets/vocabulary.page-Rpq0iNwJ.js","assets/switch-BGTI7QMD.js","assets/empty-state-CmLTeyeL.js","assets/back-button-kneAgyKO.js","assets/vocabulary-practice.page-DXBYs3RU.js","assets/review-exams.page-COy3qmgE.js","assets/square_minus_icon-nHXaoDwv.js","assets/poll-DLGsfAr9.js","assets/ChevronRightIcon-DJ8vLE8E.js","assets/account.page-Bpqks3ND.js","assets/footer-BX70FX0t.js","assets/logo_gray-BtbYDzIX.js","assets/plans.page-4M8B_kLb.js","assets/review-questions.page-BNGJD_vw.js","assets/loading_icon-DpoaPnF2.js","assets/exam-intro.page-B0XQVenI.js","assets/list_icon-D1WowWB2.js","assets/use-start-section-dRFhmWSn.js","assets/proctor-storage-KIziptYz.js","assets/use-exam-instructions-Iy5lyYX3.js","assets/intro-shell-DEGPVFzK.js","assets/exam.page-COv-aXKH.js","assets/exam-review-PJcWoxea.js","assets/spinner-BnOsT7Xf.js","assets/cursor-memory-B3E6c14Z.js","assets/signup.page-CWsnwJLU.js","assets/diagnosis.page-DPKv5Bly.js","assets/assignments.page-CiOhC0Si.js","assets/assignment.page-J6Mkkc7A.js","assets/mutations-CNPERWhe.js","assets/question-navigator-BEs0-vIC.js","assets/assignment-intro.page-CZagWb96.js","assets/review-assignment.page-zo8qfXau.js"])))=>i.map(i=>d[i]); 2(function(){try{var e=typeof window<"u"?window:typeof global<"u"?global:typeof globalThis<"u"?globalThis:typeof self<"u"?self:{};e.SENTRY_RELEASE={id:"3b04a436aaa09b871bbc9aaf912981fe6a3097f5"};var t=new e.Error().stack;t&&(e._sentryDebugIds=e._sentryDebugIds||{},e._sentryDebugIds[t]="c1ac681e-0a72-4ac6-98b7-c29211f0790f",e._sentryDebugIdIdentifier="sentry-dbid-c1ac681e-0a72-4ac6-98b7-c29211f0790f")}catch{}})();function YW(e,t){for(var n=0;n<t.length;n++){const r=t[n];if(typeof r!="string"&&!Array.isArray(r)){for(const i in r)if(i!=="default"&&!(i in e)){const s=Object.getOwnPropertyDescriptor(r,i);s&&Object.defineProperty(e,i,s.get?s:{enumerable:!0,get:()=>r[i]})}}}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 i of document.querySelectorAll('link[rel="modulepreload"]'))r(i);new MutationObserver(i=>{for(const s of i)if(s.type==="childList")for(const o of s.addedNodes)o.tagName==="LINK"&&o.rel==="modulepreload"&&r(o)}).observe(document,{childList:!0,subtree:!0});function n(i){const s={};return i.integrity&&(s.integrity=i.integrity),i.referrerPolicy&&(s.referrerPolicy=i.referrerPolicy),i.crossOrigin==="use-credentials"?s.credentials="include":i.crossOrigin==="anonymous"?s.credentials="omit":s.credentials="same-origin",s}function r(i){if(i.ep)return;i.ep=!0;const s=n(i);fetch(i.href,s)}})();var gy=typeof globalThis<"u"?globalThis:typeof window<"u"?window:typeof global<"u"?global:typeof self<"u"?self:{};function Pl(e){return e&&e.__esModule&&Object.prototype.hasOwnProperty.call(e,"default")?e.default:e}function JW(e){if(Object.prototype.hasOwnProperty.call(e,"__esModule"))return e;var t=e.default;if(typeof t=="function"){var n=function r(){var i=!1;try{i=this instanceof r}catch{}return i?Reflect.construct(t,arguments,this.constructor):t.apply(this,arguments)};n.prototype=t.prototype}else n={};return Object.defineProperty(n,"__esModule",{value:!0}),Object.keys(e).forEach(function(r){var i=Object.getOwnPropertyDescriptor(e,r);Object.defineProperty(n,r,i.get?i:{enumerable:!0,get:function(){return e[r]}})}),n}var cb={exports:{}},bh={},ub={exports:{}},Tt={};var wO;function ZW(){if(wO)return Tt;wO=1;var e=Symbol.for("react.element"),t=Symbol.for("react.portal"),n=Symbol.for("react.fragment"),r=Symbol.for("react.strict_mode"),i=Symbol.for("react.profiler"),s=Symbol.for("react.provider"),o=Symbol.for("react.context"),a=Symbol.for("react.forward_ref"),c=Symbol.for("react.suspense"),d=Symbol.for("react.memo"),f=Symbol.for("react.lazy"),p=Symbol.iterator;function m(O){return O===null||typeof O!="object"?null:(O=p&&O[p]||O["@@iterator"],typeof O=="function"?O:null)}var v={isMounted:function(){return!1},enqueueForceUpdate:function(){},enqueueReplaceState:function(){},enqueueSetState:function(){}},w=Object.assign,_={};function b(O,H,Z){this.props=O,this.context=H,this.refs=_,this.updater=Z||v}b.prototype.isReactComponent={},b.prototype.setState=function(O,H){if(typeof O!="object"&&typeof O!="function"&&O!=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,O,H,"setState")},b.prototype.forceUpdate=function(O){this.updater.enqueueForceUpdate(this,O,"forceUpdate")};function C(){}C.prototype=b.prototype;function P(O,H,Z){this.props=O,this.context=H,this.refs=_,this.updater=Z||v}var D=P.prototype=new C;D.constructor=P,w(D,b.prototype),D.isPureReactComponent=!0;var F=Array.isArray,R=Object.prototype.hasOwnProperty,I={current:null},k={key:!0,ref:!0,__self:!0,__source:!0};function L(O,H,Z){var X,te={},oe=null,le=null;if(H!=null)for(X in H.ref!==void 0&&(le=H.ref),H.key!==void 0&&(oe=""+H.key),H)R.call(H,X)&&!k.hasOwnProperty(X)&&(te[X]=H[X]);var ye=arguments.length-2;if(ye===1)te.children=Z;else if(1<ye){for(var xe=Array(ye),be=0;be<ye;be++)xe[be]=arguments[be+2];te.children=xe}if(O&&O.defaultProps)for(X in ye=O.defaultProps,ye)te[X]===void 0&&(te[X]=ye[X]);return{$$typeof:e,type:O,key:oe,ref:le,props:te,_owner:I.current}}function B(O,H){return{$$typeof:e,type:O.type,key:H,ref:O.ref,props:O.props,_owner:O._owner}}function A(O){return typeof O=="object"&&O!==null&&O.$$typeof===e}function V(O){var H={"=":"=0",":":"=2"};return"$"+O.replace(/[=:]/g,function(Z){return H[Z]})}var K=/\/+/g;function W(O,H){return typeof O=="object"&&O!==null&&O.key!=null?V(""+O.key):H.toString(36)}function U(O,H,Z,X,te){var oe=typeof O;(oe==="undefined"||oe==="boolean")&&(O=null);var le=!1;if(O===null)le=!0;else switch(oe){case"string":case"number":le=!0;break;case"object":switch(O.$$typeof){case e:case t:le=!0}}if(le)return le=O,te=te(le),O=X===""?"."+W(le,0):X,F(te)?(Z="",O!=null&&(Z=O.replace(K,"$&/")+"/"),U(te,H,Z,"",function(be){return be})):te!=null&&(A(te)&&(te=B(te,Z+(!te.key||le&&le.key===te.key?"":(""+te.key).replace(K,"$&/")+"/")+O)),H.push(te)),1;if(le=0,X=X===""?".":X+":",F(O))for(var ye=0;ye<O.length;ye++){oe=O[ye];var xe=X+W(oe,ye);le+=U(oe,H,Z,xe,te)}else if(xe=m(O),typeof xe=="function")for(O=xe.call(O),ye=0;!(oe=O.next()).done;)oe=oe.value,xe=X+W(oe,ye++),le+=U(oe,H,Z,xe,te);else if(oe==="object")throw H=String(O),Error("Objects are not valid as a React child (found: "+(H==="[object Object]"?"object with keys {"+Object.keys(O).join(", ")+"}":H)+"). If you meant to render a collection of children, use an array instead.");return le}function q(O,H,Z){if(O==null)return O;var X=[],te=0;return U(O,X,"","",function(oe){return H.call(Z,oe,te++)}),X}function z(O){if(O._status===-1){var H=O._result;H=H(),H.then(function(Z){(O._status===0||O._status===-1)&&(O._status=1,O._result=Z)},function(Z){(O._status===0||O._status===-1)&&(O._status=2,O._result=Z)}),O._status===-1&&(O._status=0,O._result=H)}if(O._status===1)return O._result.default;throw O._result}var x={current:null},N={transition:null},M={ReactCurrentDispatcher:x,ReactCurrentBatchConfig:N,ReactCurrentOwner:I};function E(){throw Error("act(...) is not supported in production builds of React.")}return Tt.Children={map:q,forEach:function(O,H,Z){q(O,function(){H.apply(this,arguments)},Z)},count:function(O){var H=0;return q(O,function(){H++}),H},toArray:function(O){return q(O,function(H){return H})||[]},only:function(O){if(!A(O))throw Error("React.Children.only expected to receive a single React element child.");return O}},Tt.Component=b,Tt.Fragment=n,Tt.Profiler=i,Tt.PureComponent=P,Tt.StrictMode=r,Tt.Suspense=c,Tt.__SECRET_INT
vendor: 4,496 bytes, line 2
2ERNALS_DO_NOT_USE_OR_YOU_WILL_BE_FIRED=M,Tt.act=E,Tt.cloneElement=function(O,H,Z){if(O==null)throw Error("React.cloneElement(...): The argument must be a React element, but you passed "+O+".");var X=w({},O.props),te=O.key,oe=O.ref,le=O._owner;if(H!=null){if(H.ref!==void 0&&(oe=H.ref,le=I.current),H.key!==void 0&&(te=""+H.key),O.type&&O.type.defaultProps)var ye=O.type.defaultProps;for(xe in H)R.call(H,xe)&&!k.hasOwnProperty(xe)&&(X[xe]=H[xe]===void 0&&ye!==void 0?ye[xe]:H[xe])}var xe=arguments.length-2;if(xe===1)X.children=Z;else if(1<xe){ye=Array(xe);for(var be=0;be<xe;be++)ye[be]=arguments[be+2];X.children=ye}return{$$typeof:e,type:O.type,key:te,ref:oe,props:X,_owner:le}},Tt.createContext=function(O){return O={$$typeof:o,_currentValue:O,_currentValue2:O,_threadCount:0,Provider:null,Consumer:null,_defaultValue:null,_globalName:null},O.Provider={$$typeof:s,_context:O},O.Consumer=O},Tt.createElement=L,Tt.createFactory=function(O){var H=L.bind(null,O);return H.type=O,H},Tt.createRef=function(){return{current:null}},Tt.forwardRef=function(O){return{$$typeof:a,render:O}},Tt.isValidElement=A,Tt.lazy=function(O){return{$$typeof:f,_payload:{_status:-1,_result:O},_init:z}},Tt.memo=function(O,H){return{$$typeof:d,type:O,compare:H===void 0?null:H}},Tt.startTransition=function(O){var H=N.transition;N.transition={};try{O()}finally{N.transition=H}},Tt.unstable_act=E,Tt.useCallback=function(O,H){return x.current.useCallback(O,H)},Tt.useContext=function(O){return x.current.useContext(O)},Tt.useDebugValue=function(){},Tt.useDeferredValue=function(O){return x.current.useDeferredValue(O)},Tt.useEffect=function(O,H){return x.current.useEffect(O,H)},Tt.useId=function(){return x.current.useId()},Tt.useImperativeHandle=function(O,H,Z){return x.current.useImperativeHandle(O,H,Z)},Tt.useInsertionEffect=function(O,H){return x.current.useInsertionEffect(O,H)},Tt.useLayoutEffect=function(O,H){return x.current.useLayoutEffect(O,H)},Tt.useMemo=function(O,H){return x.current.useMemo(O,H)},Tt.useReducer=function(O,H,Z){return x.current.useReducer(O,H,Z)},Tt.useRef=function(O){return x.current.useRef(O)},Tt.useState=function(O){return x.current.useState(O)},Tt.useSyncExternalStore=function(O,H,Z){return x.current.useSyncExternalStore(O,H,Z)},Tt.useTransition=function(){return x.current.useTransition()},Tt.version="18.3.1",Tt}var bO;function ao(){return bO||(bO=1,ub.exports=ZW()),ub.exports}var SO;function XW(){if(SO)return bh;SO=1;var e=ao(),t=Symbol.for("react.element"),n=Symbol.for("react.fragment"),r=Object.prototype.hasOwnProperty,i=e.__SECRET_INTERNALS_DO_NOT_USE_OR_YOU_WILL_BE_FIRED.ReactCurrentOwner,s={key:!0,ref:!0,__self:!0,__source:!0};function o(a,c,d){var f,p={},m=null,v=null;d!==void 0&&(m=""+d),c.key!==void 0&&(m=""+c.key),c.ref!==void 0&&(v=c.ref);for(f in c)r.call(c,f)&&!s.hasOwnProperty(f)&&(p[f]=c[f]);if(a&&a.defaultProps)for(f in c=a.defaultProps,c)p[f]===void 0&&(p[f]=c[f]);return{$$typeof:t,type:a,key:m,ref:v,props:p,_owner:i.current}}return bh.Fragment=n,bh.jsx=o,bh.jsxs=o,bh}var EO;function QW(){return EO||(EO=1,cb.exports=XW()),cb.exports}var j=QW(),g=ao();const bt=Pl(g),w_=YW({__proto__:null,default:bt},[g]);var yy={},db={exports:{}},ri={},fb={exports:{}},hb={};var xO;function eq(){return xO||(xO=1,(function(e){function t(N,M){var E=N.length;N.push(M);e:for(;0<E;){var O=E-1>>>1,H=N[O];if(0<i(H,M))N[O]=M,N[E]=H,E=O;else break e}}function n(N){return N.length===0?null:N[0]}function r(N){if(N.length===0)return null;var M=N[0],E=N.pop();if(E!==M){N[0]=E;e:for(var O=0,H=N.length,Z=H>>>1;O<Z;){var X=2*(O+1)-1,te=N[X],oe=X+1,le=N[oe];if(0>i(te,E))oe<H&&0>i(le,te)?(N[O]=le,N[oe]=E,O=oe):(N[O]=te,N[X]=E,O=X);else if(oe<H&&0>i(le,E))N[O]=le,N[oe]=E,O=oe;else break e}}return M}function i(N,M){var E=N.sortIndex-M.sortIndex;return E!==0?E:N.id-M.id}if(typeof performance=="object"&&typeof performance.now=="function"){var s=performance;e.unstable_now=function(){return s.now()}}else{var o=Date,a=o.now();e.unstable_now=function(){return o.now()-a}}var c=[],d=[],f=1,p=null,m=3,v=!1,w=!1,_=!1,b=typeof setTimeout=="function"?setTimeout:null,C=typeof clearTimeout=="function"?clearTimeout:null,P=typeof setImmediate<"u"?setImmediate:null;typeof navigator<"u"&&navigator.scheduling!==void 0&&navigator.scheduling.isInputPending!==void 0&&navigator.scheduling.isInputPending.bind(navigator.scheduling);function D(N){for(var M=n(d);M!==null;){if(M.callback===null)r(d);else if(M.startTime<=N)r(d),M.sortIndex=M.expirationTime,t(c,M);else break;M=n(d)}}
vendor: 49,940 bytes, lines 2-7
2function F(N){if(_=!1,D(N),!w)if(n(c)!==null)w=!0,z(R);else{var M=n(d);M!==null&&x(F,M.startTime-N)}}function R(N,M){w=!1,_&&(_=!1,C(L),L=-1),v=!0;var E=m;try{for(D(M),p=n(c);p!==null&&(!(p.expirationTime>M)||N&&!V());){var O=p.callback;if(typeof O=="function"){p.callback=null,m=p.priorityLevel;var H=O(p.expirationTime<=M);M=e.unstable_now(),typeof H=="function"?p.callback=H:p===n(c)&&r(c),D(M)}else r(c);p=n(c)}if(p!==null)var Z=!0;else{var X=n(d);X!==null&&x(F,X.startTime-M),Z=!1}return Z}finally{p=null,m=E,v=!1}}var I=!1,k=null,L=-1,B=5,A=-1;function V(){return!(e.unstable_now()-A<B)}function K(){if(k!==null){var N=e.unstable_now();A=N;var M=!0;try{M=k(!0,N)}finally{M?W():(I=!1,k=null)}}else I=!1}var W;if(typeof P=="function")W=function(){P(K)};else if(typeof MessageChannel<"u"){var U=new MessageChannel,q=U.port2;U.port1.onmessage=K,W=function(){q.postMessage(null)}}else W=function(){b(K,0)};function z(N){k=N,I||(I=!0,W())}function x(N,M){L=b(function(){N(e.unstable_now())},M)}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(N){N.callback=null},e.unstable_continueExecution=function(){w||v||(w=!0,z(R))},e.unstable_forceFrameRate=function(N){0>N||125<N?console.error("forceFrameRate takes a positive int between 0 and 125, forcing frame rates higher than 125 fps is not supported"):B=0<N?Math.floor(1e3/N):5},e.unstable_getCurrentPriorityLevel=function(){return m},e.unstable_getFirstCallbackNode=function(){return n(c)},e.unstable_next=function(N){switch(m){case 1:case 2:case 3:var M=3;break;default:M=m}var E=m;m=M;try{return N()}finally{m=E}},e.unstable_pauseExecution=function(){},e.unstable_requestPaint=function(){},e.unstable_runWithPriority=function(N,M){switch(N){case 1:case 2:case 3:case 4:case 5:break;default:N=3}var E=m;m=N;try{return M()}finally{m=E}},e.unstable_scheduleCallback=function(N,M,E){var O=e.unstable_now();switch(typeof E=="object"&&E!==null?(E=E.delay,E=typeof E=="number"&&0<E?O+E:O):E=O,N){case 1:var H=-1;break;case 2:H=250;break;case 5:H=1073741823;break;case 4:H=1e4;break;default:H=5e3}return H=E+H,N={id:f++,callback:M,priorityLevel:N,startTime:E,expirationTime:H,sortIndex:-1},E>O?(N.sortIndex=E,t(d,N),n(c)===null&&N===n(d)&&(_?(C(L),L=-1):_=!0,x(F,E-O))):(N.sortIndex=H,t(c,N),w||v||(w=!0,z(R))),N},e.unstable_shouldYield=V,e.unstable_wrapCallback=function(N){var M=m;return function(){var E=m;m=M;try{return N.apply(this,arguments)}finally{m=E}}}})(hb)),hb}var CO;function tq(){return CO||(CO=1,fb.exports=eq()),fb.exports}var kO;function nq(){if(kO)return ri;kO=1;var e=ao(),t=tq();function n(l){for(var u="https://reactjs.org/docs/error-decoder.html?invariant="+l,h=1;h<arguments.length;h++)u+="&args[]="+encodeURIComponent(arguments[h]);return"Minified React error #"+l+"; visit "+u+" for the full message or use the non-minified dev environment for full errors and additional helpful warnings."}var r=new Set,i={};function s(l,u){o(l,u),o(l+"Capture",u)}function o(l,u){for(i[l]=u,l=0;l<u.length;l++)r.add(u[l])}var a=!(typeof window>"u"||typeof window.document>"u"||typeof window.document.createElement>"u"),c=Object.prototype.hasOwnProperty,d=/^[: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]*$/,f={},p={};function m(l){return c.call(p,l)?!0:c.call(f,l)?!1:d.test(l)?p[l]=!0:(f[l]=!0,!1)}function v(l,u,h,y){if(h!==null&&h.type===0)return!1;switch(typeof u){case"function":case"symbol":return!0;case"boolean":return y?!1:h!==null?!h.acceptsBooleans:(l=l.toLowerCase().slice(0,5),l!=="data-"&&l!=="aria-");default:return!1}}function w(l,u,h,y){if(u===null||typeof u>"u"||v(l,u,h,y))return!0;if(y)return!1;if(h!==null)switch(h.type){case 3:return!u;case 4:return u===!1;case 5:return isNaN(u);case 6:return isNaN(u)||1>u}return!1}function _(l,u,h,y,S,T,$){this.acceptsBooleans=u===2||u===3||u===4,this.attributeName=y,this.attributeNamespace=S,this.mustUseProperty=h,this.propertyName=l,this.type=u,this.sanitizeURL=T,this.removeEmptyString=$}var b={};"children dangerouslySetInnerHTML defaultValue defaultChecked innerHTML suppressContentEditableWarning suppressHydrationWarning style".split(" ").forEach(function(l){b[l]=new _(l,0,!1,l,null,!1,!1)}),[["acceptCharset","accept-charset"],["className","class"],["htmlFor","for"],["httpEquiv","http-equiv"]].forEach(function(l){var u=l[0];b[u]=new _(u,1,!1,l[1],null,!1,!1)}),["contentEditable","draggable","spellCheck","value"].forEach(function(l){b[l]=new _(l,2,!1,l.toLowerCase(),null,!1,!1)}),["autoReverse","externalResourcesRequired","focusable","preserveAlpha"].forEach(function(l){b[l]=new _(l,2,!1,l,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(l){b[l]=new _(l,3,!1,l.toLowerCase(),null,!1,!1)}),["checked","multiple","muted","selected"].forEach(function(l){b[l]=new _(l,3,!0,l,null,!1,!1)}),["capture","download"].forEach(function(l){b[l]=new _(l,4,!1,l,null,!1,!1)}),["cols","rows","size","span"].forEach(function(l){b[l]=new _(l,6,!1,l,null,!1,!1)}),["rowSpan","start"].forEach(function(l){b[l]=new _(l,5,!1,l.toLowerCase(),null,!1,!1)});var C=/[\-:]([a-z])/g;function P(l){return l[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(l){var u=l.replace(C,P);b[u]=new _(u,1,!1,l,null,!1,!1)}),"xlink:actuate xlink:arcrole xlink:role xlink:show xlink:title xlink:type".split(" ").forEach(function(l){var u=l.replace(C,P);b[u]=new _(u,1,!1,l,"http://www.w3.org/1999/xlink",!1,!1)}),["xml:base","xml:lang","xml:space"].forEach(function(l){var u=l.replace(C,P);b[u]=new _(u,1,!1,l,"http://www.w3.org/XML/1998/namespace",!1,!1)}),["tabIndex","crossOrigin"].forEach(function(l){b[l]=new _(l,1,!1,l.toLowerCase(),null,!1,!1)}),b.xlinkHref=new _("xlinkHref",1,!1,"xlink:href","http://www.w3.org/1999/xlink",!0,!1),["src","href","action","formAction"].forEach(function(l){b[l]=new _(l,1,!1,l.toLowerCase(),null,!0,!0)});function D(l,u,h,y){var S=b.hasOwnProperty(u)?b[u]:null;(S!==null?S.type!==0:y||!(2<u.length)||u[0]!=="o"&&u[0]!=="O"||u[1]!=="n"&&u[1]!=="N")&&(w(u,h,S,y)&&(h=null),y||S===null?m(u)&&(h===null?l.removeAttribute(u):l.setAttribute(u,""+h)):S.mustUseProperty?l[S.propertyName]=h===null?S.type===3?!1:"":h:(u=S.attributeName,y=S.attributeNamespace,h===null?l.removeAttribute(u):(S=S.type,h=S===3||S===4&&h===!0?"":""+h,y?l.setAttributeNS(y,u,h):l.setAttribute(u,h))))}var F=e.__SECRET_INTERNALS_DO_NOT_USE_OR_YOU_WILL_BE_FIRED,R=Symbol.for("react.element"),I=Symbol.for("react.portal"),k=Symbol.for("react.fragment"),L=Symbol.for("react.strict_mode"),B=Symbol.for("react.profiler"),A=Symbol.for("react.provider"),V=Symbol.for("react.context"),K=Symbol.for("react.forward_ref"),W=Symbol.for("react.suspense"),U=Symbol.for("react.suspense_list"),q=Symbol.for("react.memo"),z=Symbol.for("react.lazy"),x=Symbol.for("react.offscreen"),N=Symbol.iterator;function M(l){return l===null||typeof l!="object"?null:(l=N&&l[N]||l["@@iterator"],typeof l=="function"?l:null)}var E=Object.assign,O;function H(l){if(O===void 0)try{throw Error()}catch(h){var u=h.stack.trim().match(/\n( *(at )?)/);O=u&&u[1]||""}return` 3`+O+l}var Z=!1;function X(l,u){if(!l||Z)return"";Z=!0;var h=Error.prepareStackTrace;Error.prepareStackTrace=void 0;try{if(u)if(u=function(){throw Error()},Object.defineProperty(u.prototype,"props",{set:function(){throw Error()}}),typeof Reflect=="object"&&Reflect.construct){try{Reflect.construct(u,[])}catch(ue){var y=ue}Reflect.construct(l,[],u)}else{try{u.call()}catch(ue){y=ue}l.call(u.prototype)}else{try{throw Error()}catch(ue){y=ue}l()}}catch(ue){if(ue&&y&&typeof ue.stack=="string"){for(var S=ue.stack.split(` 4`),T=y.stack.split(` 5`),$=S.length-1,G=T.length-1;1<=$&&0<=G&&S[$]!==T[G];)G--;for(;1<=$&&0<=G;$--,G--)if(S[$]!==T[G]){if($!==1||G!==1)do if($--,G--,0>G||S[$]!==T[G]){var Q=` 6`+S[$].replace(" at new "," at ");return l.displayName&&Q.includes("<anonymous>")&&(Q=Q.replace("<anonymous>",l.displayName)),Q}while(1<=$&&0<=G);break}}}finally{Z=!1,Error.prepareStackTrace=h}return(l=l?l.displayName||l.name:"")?H(l):""}function te(l){switch(l.tag){case 5:return H(l.type);case 16:return H("Lazy");case 13:return H("Suspense");case 19:return H("SuspenseList");case 0:case 2:case 15:return l=X(l.type,!1),l;case 11:return l=X(l.type.render,!1),l;case 1:return l=X(l.type,!0),l;default:return""}}function oe(l){if(l==null)return null;if(typeof l=="function")return l.displayName||l.name||null;if(typeof l=="string")return l;switch(l){case k:return"Fragment";case I:return"Portal";case B:return"Profiler";case L:return"StrictMode";case W:return"Suspense";case U:return"SuspenseList"}if(typeof l=="object")switch(l.$$typeof){case V:return(l.displayName||"Context")+".Consumer";case A:return(l._context.displayName||"Context")+".Provider";case K:var u=l.render;return l=l.displayName,l||(l=u.displayName||u.name||"",l=l!==""?"ForwardRef("+l+")":"ForwardRef"),l;case q:return u=l.displayName||null,u!==null?u:oe(l.type)||"Memo";case z:u=l._payload,l=l._init;try{return oe(l(u))}catch{}}return null}function le(l){var u=l.type;switch(l.tag){case 24:return"Cache";case 9:return(u.displayName||"Context")+".Consumer";case 10:return(u._context.displayName||"Context")+".Provider";case 18:return"DehydratedFragment";case 11:return l=u.render,l=l.displayName||l.name||"",u.displayName||(l!==""?"ForwardRef("+l+")":"ForwardRef");case 7:return"Fragment";case 5:return u;case 4:return"Portal";case 3:return"Root";case 6:return"Text";case 16:return oe(u);case 8:return u===L?"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 u=="function")return u.displayName||u.name||null;if(typeof u=="string")return u}return null}function ye(l){switch(typeof l){case"boolean":case"number":case"string":case"undefined":return l;case"object":return l;default:return""}}function xe(l){var u=l.type;return(l=l.nodeName)&&l.toLowerCase()==="input"&&(u==="checkbox"||u==="radio")}function be(l){var u=xe(l)?"checked":"value",h=Object.getOwnPropertyDescriptor(l.constructor.prototype,u),y=""+l[u];if(!l.hasOwnProperty(u)&&typeof h<"u"&&typeof h.get=="function"&&typeof h.set=="function"){var S=h.get,T=h.set;return Object.defineProperty(l,u,{configurable:!0,get:function(){return S.call(this)},set:function($){y=""+$,T.call(this,$)}}),Object.defineProperty(l,u,{enumerable:h.enumerable}),{getValue:function(){return y},setValue:function($){y=""+$},stopTracking:function(){l._valueTracker=null,delete l[u]}}}}function rt(l){l._valueTracker||(l._valueTracker=be(l))}function Ue(l){if(!l)return!1;var u=l._valueTracker;if(!u)return!0;var h=u.getValue(),y="";return l&&(y=xe(l)?l.checked?"true":"false":l.value),l=y,l!==h?(u.setValue(l),!0):!1}function Ve(l){if(l=l||(typeof document<"u"?document:void 0),typeof l>"u")return null;try{return l.activeElement||l.body}catch{return l.body}}function Qe(l,u){var h=u.checked;return E({},u,{defaultChecked:void 0,defaultValue:void 0,value:void 0,checked:h??l._wrapperState.initialChecked})}function ht(l,u){var h=u.defaultValue==null?"":u.defaultValue,y=u.checked!=null?u.checked:u.defaultChecked;h=ye(u.value!=null?u.value:h),l._wrapperState={initialChecked:y,initialValue:h,controlled:u.type==="checkbox"||u.type==="radio"?u.checked!=null:u.value!=null}}function Rt(l,u){u=u.checked,u!=null&&D(l,"checked",u,!1)}function it(l,u){Rt(l,u);var h=ye(u.value),y=u.type;if(h!=null)y==="number"?(h===0&&l.value===""||l.value!=h)&&(l.value=""+h):l.value!==""+h&&(l.value=""+h);else if(y==="submit"||y==="reset"){l.removeAttribute("value");return}u.hasOwnProperty("value")?Xt(l,u.type,h):u.hasOwnProperty("defaultValue")&&Xt(l,u.type,ye(u.defaultValue)),u.checked==null&&u.defaultChecked!=null&&(l.defaultChecked=!!u.defaultChecked)}function Yt(l,u,h){if(u.hasOwnProperty("value")||u.hasOwnProperty("defaultValue")){var y=u.type;if(!(y!=="submit"&&y!=="reset"||u.value!==void 0&&u.value!==null))return;u=""+l._wrapperState.initialValue,h||u===l.value||(l.value=u),l.defaultValue=u}h=l.name,h!==""&&(l.name=""),l.defaultChecked=!!l._wrapperState.initialChecked,h!==""&&(l.name=h)}function Xt(l,u,h){(u!=="number"||Ve(l.ownerDocument)!==l)&&(h==null?l.defaultValue=""+l._wrapperState.initialValue:l.defaultValue!==""+h&&(l.defaultValue=""+h))}var Je=Array.isArray;function jt(l,u,h,y){if(l=l.options,u){u={};for(var S=0;S<h.length;S++)u["$"+h[S]]=!0;for(h=0;h<l.length;h++)S=u.hasOwnProperty("$"+l[h].value),l[h].selected!==S&&(l[h].selected=S),S&&y&&(l[h].defaultSelected=!0)}else{for(h=""+ye(h),u=null,S=0;S<l.length;S++){if(l[S].value===h){l[S].selected=!0,y&&(l[S].defaultSelected=!0);return}u!==null||l[S].disabled||(u=l[S])}u!==null&&(u.selected=!0)}}function ot(l,u){if(u.dangerouslySetInnerHTML!=null)throw Error(n(91));return E({},u,{value:void 0,defaultValue:void 0,children:""+l._wrapperState.initialValue})}function on(l,u){var h=u.value;if(h==null){if(h=u.children,u=u.defaultValue,h!=null){if(u!=null)throw Error(n(92));if(Je(h)){if(1<h.length)throw Error(n(93));h=h[0]}u=h}u==null&&(u=""),h=u}l._wrapperState={initialValue:ye(h)}}function yt(l,u){var h=ye(u.value),y=ye(u.defaultValue);h!=null&&(h=""+h,h!==l.value&&(l.value=h),u.defaultValue==null&&l.defaultValue!==h&&(l.defaultValue=h)),y!=null&&(l.defaultValue=""+y)}function Un(l){var u=l.textContent;u===l._wrapperState.initialValue&&u!==""&&u!==null&&(l.value=u)}function zl(l){switch(l){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 kr(l,u){return l==null||l==="http://www.w3.org/1999/xhtml"?zl(u):l==="http://www.w3.org/2000/svg"&&u==="foreignObject"?"http://www.w3.org/1999/xhtml":l}var zn,Di=(function(l){return typeof MSApp<"u"&&MSApp.execUnsafeLocalFunction?function(u,h,y,S){MSApp.execUnsafeLocalFunction(function(){return l(u,h,y,S)})}:l})(function(l,u){if(l.namespaceURI!=="http://www.w3.org/2000/svg"||"innerHTML"in l)l.innerHTML=u;else{for(zn=zn||document.createElement("div"),zn.innerHTML="<svg>"+u.valueOf().toString()+"</svg>",u=zn.firstChild;l.firstChild;)l.removeChild(l.firstChild);for(;u.firstChild;)l.appendChild(u.firstChild)}});function fa(l,u){if(u){var h=l.firstChild;if(h&&h===l.lastChild&&h.nodeType===3){h.nodeValue=u;return}}l.textContent=u}var Bl={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},$f=["Webkit","ms","Moz","O"];Object.keys(Bl).forEach(function(l){$f.forEach(function(u){u=u+l.charAt(0).toUpperCase()+l.substring(1),Bl[u]=Bl[l]})});function dg(l,u,h){return u==null||typeof u=="boolean"||u===""?"":h||typeof u!="number"||u===0||Bl.hasOwnProperty(l)&&Bl[l]?(""+u).trim():u+"px"}function Li(l,u){l=l.style;for(var h in u)if(u.hasOwnProperty(h)){var y=h.indexOf("--")===0,S=dg(h,u[h],y);h==="float"&&(h="cssFloat"),y?l.setProperty(h,S):l[h]=S}}var fg=E({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 Su(l,u){if(u){if(fg[l]&&(u.children!=null||u.dangerouslySetInnerHTML!=null))throw Error(n(137,l));if(u.dangerouslySetInnerHTML!=null){if(u.children!=null)throw Error(n(60));if(typeof u.dangerouslySetInnerHTML!="object"||!("__html"in u.dangerouslySetInnerHTML))throw Error(n(61))}if(u.style!=null&&typeof u.style!="object")throw Error(n(62))}}function Eu(l,u){if(l.indexOf("-")===-1)return typeof u.is=="string";switch(l){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 jf=null;function xu(l){return l=l.target||l.srcElement||window,l.correspondingUseElement&&(l=l.correspondingUseElement),l.nodeType===3?l.parentNode:l}var ha=null,fo=null,Ls=null;function hg(l){if(l=oh(l)){if(typeof ha!="function")throw Error(n(280));var u=l.stateNode;u&&(u=Ag(u),ha(l.stateNode,l.type,u))}}function Ff(l){fo?Ls?Ls.push(l):Ls=[l]:fo=l}function pg(){if(fo){var l=fo,u=Ls;if(Ls=fo=null,hg(l),u)for(l=0;l<u.length;l++)hg(u[l])}}function Uf(l,u){return l(u)}function Hl(){}var pa=!1;function zf(l,u,h){if(pa)return l(u,h);pa=!0;try{return Uf(l,u,h)}finally{pa=!1,(fo!==null||Ls!==null)&&(Hl(),pg())}}function Vl(l,u){var h=l.stateNode;if(h===null)return null;var y=Ag(h);if(y===null)return null;h=y[u];e:switch(u){case"onClick":case"onClickCapture":case"onDoubleClick":case"onDoubleClickCapture":case"onMouseDown":case"onMouseDownCapture":case"onMouseMove":case"onMouseMoveCapture":case"onMouseUp":case"onMouseUpCapture":case"onMouseEnter":(y=!y.disabled)||(l=l.type,y=!(l==="button"||l==="input"||l==="select"||l==="textarea")),l=!y;break e;default:l=!1}if(l)return null;if(h&&typeof h!="function")throw Error(n(231,u,typeof h));return h}var Bf=!1;if(a)try{var Y={};Object.defineProperty(Y,"passive",{get:function(){Bf=!0}}),window.addEventListener("test",Y,Y),window.removeEventListener("test",Y,Y)}catch{Bf=!1}function ne(l,u,h,y,S,T,$,G,Q){var ue=Array.prototype.slice.call(arguments,3);try{u.apply(h,ue)}catch(pe){this.onError(pe)}}var ce=!1,me=null,we=!1,We=null,De={onError:function(l){ce=!0,me=l}};function Be(l,u,h,y,S,T,$,G,Q){ce=!1,me=null,ne.apply(De,arguments)}function Ge(l,u,h,y,S,T,$,G,Q){if(Be.apply(this,arguments),ce){if(ce){var ue=me;ce=!1,me=null}else throw Error(n(198));we||(we=!0,We=ue)}}function He(l){var u=l,h=l;if(l.alternate)for(;u.return;)u=u.return;else{l=u;do u=l,(u.flags&4098)!==0&&(h=u.return),l=u.return;while(l)}return u.tag===3?h:null}function st(l){if(l.tag===13){var u=l.memoizedState;if(u===null&&(l=l.alternate,l!==null&&(u=l.memoizedState)),u!==null)return u.dehydrated}return null}function Ye(l){if(He(l)!==l)throw Error(n(188))}function Ft(l){var u=l.alternate;if(!u){if(u=He(l),u===null)throw Error(n(188));return u!==l?null:l}for(var h=l,y=u;;){var S=h.return;if(S===null)break;var T=S.alternate;if(T===null){if(y=S.return,y!==null){h=y;continue}break}if(S.child===T.child){for(T=S.child;T;){if(T===h)return Ye(S),l;if(T===y)return Ye(S),u;T=T.sibling}throw Error(n(188))}if(h.return!==y.return)h=S,y=T;else{for(var $=!1,G=S.child;G;){if(G===h){$=!0,h=S,y=T;break}if(G===y){$=!0,y=S,h=T;break}G=G.sibling}if(!$){for(G=T.child;G;){if(G===h){$=!0,h=T,y=S;break}if(G===y){$=!0,y=T,h=S;break}G=G.sibling}if(!$)throw Error(n(189))}}if(h.alternate!==y)throw Error(n(190))}if(h.tag!==3)throw Error(n(188));return h.stateNode.current===h?l:u}function It(l){return l=Ft(l),l!==null?Bn(l):null}function Bn(l){if(l.tag===5||l.tag===6)return l;for(l=l.child;l!==null;){var u=Bn(l);if(u!==null)return u;l=l.sibling}return null}var Ln=t.unstable_scheduleCallback,ur=t.unstable_cancelCallback,Jt=t.unstable_shouldYield,Zr=t.unstable_requestPaint,Qt=t.unstable_now,Wl=t.unstable_getCurrentPriorityLevel,Ni=t.unstable_ImmediatePriority,mi=t.unstable_UserBlockingPriority,ma=t.unstable_NormalPriority,ql=t.unstable_LowPriority,Ns=t.unstable_IdlePriority,ho=null,Nr=null;function Mt(l){if(Nr&&typeof Nr.onCommitFiberRoot=="function")try{Nr.onCommitFiberRoot(ho,l,void 0,(l.current.flags&128)===128)}catch{}}var nn=Math.clz32?Math.clz32:vn,ga=Math.log,po=Math.LN2;function vn(l){return l>>>=0,l===0?32:31-(ga(l)/po|0)|0}var mo=64,Kl=4194304;function Gl(l){switch(l&-l){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 l&4194240;case 4194304:case 8388608:case 16777216:case 33554432:case 67108864:return l&130023424;case 134217728:return 134217728;case 268435456:return 268435456;case 536870912:return 536870912;case 1073741824:return 1073741824;default:return l}}function mg(l,u){var h=l.pendingLanes;if(h===0)return 0;var y=0,S=l.suspendedLanes,T=l.pingedLanes,$=h&268435455;if($!==0){var G=$&~S;G!==0?y=Gl(G):(T&=$,T!==0&&(y=Gl(T)))}else $=h&~S,$!==0?y=Gl($):T!==0&&(y=Gl(T));if(y===0)return 0;if(u!==0&&u!==y&&(u&S)===0&&(S=y&-y,T=u&-u,S>=T||S===16&&(T&4194240)!==0))return u;if((y&4)!==0&&(y|=h&16),u=l.entangledLanes,u!==0)for(l=l.entanglements,u&=y;0<u;)h=31-nn(u),S=1<<h,y|=l[h],u&=~S;return y}function pV(l,u){switch(l){case 1:case 2:case 4:return u+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 u+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 mV(l,u){for(var h=l.suspendedLanes,y=l.pingedLanes,S=l.expirationTimes,T=l.pendingLanes;0<T;){var $=31-nn(T),G=1<<$,Q=S[$];Q===-1?((G&h)===0||(G&y)!==0)&&(S[$]=pV(G,u)):Q<=u&&(l.expiredLanes|=G),T&=~G}}function O1(l){return l=l.pendingLanes&-1073741825,l!==0?l:l&1073741824?1073741824:0}function ZR(){var l=mo;return mo<<=1,(mo&4194240)===0&&(mo=64),l}function A1(l){for(var u=[],h=0;31>h;h++)u.push(l);return u}function Hf(l,u,h){l.pendingLanes|=u,u!==536870912&&(l.suspendedLanes=0,l.pingedLanes=0),l=l.eventTimes,u=31-nn(u),l[u]=h}function gV(l,u){var h=l.pendingLanes&~u;l.pendingLanes=u,l.suspendedLanes=0,l.pingedLanes=0,l.expiredLanes&=u,l.mutableReadLanes&=u,l.entangledLanes&=u,u=l.entanglements;var y=l.eventTimes;for(l=l.expirationTimes;0<h;){var S=31-nn(h),T=1<<S;u[S]=0,y[S]=-1,l[S]=-1,h&=~T}}function I1(l,u){var h=l.entangledLanes|=u;for(l=l.entanglements;h;){var y=31-nn(h),S=1<<y;S&u|l[y]&u&&(l[y]|=u),h&=~S}}var en=0;function XR(l){return l&=-l,1<l?4<l?(l&268435455)!==0?16:536870912:4:1}var QR,M1,eP,tP,nP,D1=!1,gg=[],ya=null,va=null,_a=null,Vf=new Map,Wf=new Map,wa=[],yV="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 rP(l,u){switch(l){case"focusin":case"focusout":ya=null;break;case"dragenter":case"dragleave":va=null;break;case"mouseover":case"mouseout":_a=null;break;case"pointerover":case"pointerout":Vf.delete(u.pointerId);break;case"gotpointercapture":case"lostpointercapture":Wf.delete(u.pointerId)}}function qf(l,u,h,y,S,T){return l===null||l.nativeEvent!==T?(l={blockedOn:u,domEventName:h,eventSystemFlags:y,nativeEvent:T,targetContainers:[S]},u!==null&&(u=oh(u),u!==null&&M1(u)),l):(l.eventSystemFlags|=y,u=l.targetContainers,S!==null&&u.indexOf(S)===-1&&u.push(S),l)}function vV(l,u,h,y,S){switch(u){case"focusin":return ya=qf(ya,l,u,h,y,S),!0;case"dragenter":return va=qf(va,l,u,h,y,S),!0;case"mouseover":return _a=qf(_a,l,u,h,y,S),!0;case"pointerover":var T=S.pointerId;return Vf.set(T,qf(Vf.get(T)||null,l,u,h,y,S)),!0;case"gotpointercapture":return T=S.pointerId,Wf.set(T,qf(Wf.get(T)||null,l,u,h,y,S)),!0}return!1}function iP(l){var u=Yl(l.target);if(u!==null){var h=He(u);if(h!==null){if(u=h.tag,u===13){if(u=st(h),u!==null){l.blockedOn=u,nP(l.priority,function(){eP(h)});return}}else if(u===3&&h.stateNode.current.memoizedState.isDehydrated){l.blockedOn=h.tag===3?h.stateNode.containerInfo:null;return}}}l.blockedOn=null}function yg(l){if(l.blockedOn!==null)return!1;for(var u=l.targetContainers;0<u.length;){var h=N1(l.domEventName,l.eventSystemFlags,u[0],l.nativeEvent);if(h===null){h=l.nativeEvent;var y=new h.constructor(h.type,h);jf=y,h.target.dispatchEvent(y),jf=null}else return u=oh(h),u!==null&&M1(u),l.blockedOn=h,!1;u.shift()}return!0}function sP(l,u,h){yg(l)&&h.delete(u)}function _V(){D1=!1,ya!==null&&yg(ya)&&(ya=null),va!==null&&yg(va)&&(va=null),_a!==null&&yg(_a)&&(_a=null),Vf.forEach(sP),Wf.forEach(sP)}function Kf(l,u){l.blockedOn===u&&(l.blockedOn=null,D1||(D1=!0,t.unstable_scheduleCallback(t.unstable_NormalPriority,_V)))}function Gf(l){function u(S){return Kf(S,l)}if(0<gg.length){Kf(gg[0],l);for(var h=1;h<gg.length;h++){var y=gg[h];y.blockedOn===l&&(y.blockedOn=null)}}for(ya!==null&&Kf(ya,l),va!==null&&Kf(va,l),_a!==null&&Kf(_a,l),Vf.forEach(u),Wf.forEach(u),h=0;h<wa.length;h++)y=wa[h],y.blockedOn===l&&(y.blockedOn=null);for(;0<wa.length&&(h=wa[0],h.blockedOn===null);)iP(h),h.blockedOn===null&&wa.shift()}var Cu=F.ReactCurrentBatchConfig,vg=!0;function wV(l,u,h,y){var S=en,T=Cu.transition;Cu.transition=null;try{en=1,L1(l,u,h,y)}finally{en=S,Cu.transition=T}}function bV(l,u,h,y){var S=en,T=Cu.transition;Cu.transition=null;try{en=4,L1(l,u,h,y)}finally{en=S,Cu.transition=T}}function L1(l,u,h,y){if(vg){var S=N1(l,u,h,y);if(S===null)Q1(l,u,y,_g,h),rP(l,y);else if(vV(S,l,u,h,y))y.stopPropagation();else if(rP(l,y),u&4&&-1<yV.indexOf(l)){for(;S!==null;){var T=oh(S);if(T!==null&&QR(T),T=N1(l,u,h,y),T===null&&Q1(l,u,y,_g,h),T===S)break;S=T}S!==null&&y.stopPropagation()}else Q1(l,u,y,null,h)}}var _g=null;function N1(l,u,h,y){if(_g=null,l=xu(y),l=Yl(l),l!==null)if(u=He(l),u===null)l=null;else if(h=u.tag,h===13){if(l=st(u),l!==null)return l;l=null}else if(h===3){if(u.stateNode.current.memoizedState.isDehydrated)return u.tag===3?u.stateNode.containerInfo:null;l=null}else u!==l&&(l=null);return _g=l,null}function oP(l){switch(l){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(Wl()){case Ni:return 1;case mi:return 4;case ma:case ql:return 16;case Ns:return 536870912;default:return 16}default:return 16}}var ba=null,$1=null,wg=null;function aP(){if(wg)return wg;var l,u=$1,h=u.length,y,S="value"in ba?ba.value:ba.textContent,T=S.length;for(l=0;l<h&&u[l]===S[l];l++);var $=h-l;for(y=1;y<=$&&u[h-y]===S[T-y];y++);return wg=S.slice(l,1<y?1-y:void 0)}function bg(l){var u=l.keyCode;return"charCode"in l?(l=l.charCode,l===0&&u===13&&(l=13)):l=u,l===10&&(l=13),32<=l||l===13?l:0}function Sg(){return!0}function lP(){return!1}function gi(l){function u(h,y,S,T,$){this._reactName=h,this._targetInst=S,this.type=y,this.nativeEvent=T,this.target=$,this.currentTarget=null;for(var G in l)l.hasOwnProperty(G)&&(h=l[G],this[G]=h?h(T):T[G]);return this.isDefaultPrevented=(T.defaultPrevented!=null?T.defaultPrevented:T.returnValue===!1)?Sg:lP,this.isPropagationStopped=lP,this}return E(u.prototype,{preventDefault:function(){this.defaultPrevented=!0;var h=this.nativeEvent;h&&(h.preventDefault?h.preventDefault():typeof h.returnValue!="unknown"&&(h.returnValue=!1),this.isDefaultPrevented=Sg)},stopPropagation:function(){var h=this.nativeEvent;h&&(h.stopPropagation?h.stopPropagation():typeof h.cancelBubble!="unknown"&&(h.cancelBubble=!0),this.isPropagationStopped=Sg)},persist:function(){},isPersistent:Sg}),u}var ku={eventPhase:0,bubbles:0,cancelable:0,timeStamp:function(l){return l.timeStamp||Date.now()},defaultPrevented:0,isTrusted:0},j1=gi(ku),Yf=E({},ku,{view:0,detail:0}),SV=gi(Yf),F1,U1,Jf,Eg=E({},Yf,{screenX:0,screenY:0,clientX:0,clientY:0,pageX:0,pageY:0,ctrlKey:0,shiftKey:0,altKey:0,metaKey:0,getModifierState:B1,button:0,buttons:0,relatedTarget:function(l){return l.relatedTarget===void 0?l.fromElement===l.srcElement?l.toElement:l.fromElement:l.relatedTarget},movementX:function(l){return"movementX"in l?l.movementX:(l!==Jf&&(Jf&&l.type==="mousemove"?(F1=l.screenX-Jf.screenX,U1=l.screenY-Jf.screenY):U1=F1=0,Jf=l),F1)},movementY:function(l){return"movementY"in l?l.movementY:U1}}),cP=gi(Eg),EV=E({},Eg,{dataTransfer:0}),xV=gi(EV),CV=E({},Yf,{relatedTarget:0}),z1=gi(CV),kV=E({},ku,{animationName:0,elapsedTime:0,pseudoElement:0}),TV=gi(kV),RV=E({},ku,{clipboardData:function(l){return"clipboardData"in l?l.clipboardData:window.clipboardData}}),PV=gi(RV),OV=E({},ku,{data:0}),uP=gi(OV),AV={Esc:"Escape",Spacebar:" ",Left:"ArrowLeft",Up:"ArrowUp",Right:"ArrowRight",Down:"ArrowDown",Del:"Delete",Win:"OS",Menu:"ContextMenu",Apps:"ContextMenu",Scroll:"ScrollLock",MozPrintableKey:"Unidentified"},IV={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"},MV={Alt:"altKey",Control:"ctrlKey",Meta:"metaKey",Shift:"shiftKey"};function DV(l){var u=this.nativeEvent;return u.getModifierState?u.getModifierState(l):(l=MV[l])?!!u[l]:!1}function B1(){return DV}var LV=E({},Yf,{key:function(l){if(l.key){var u=AV[l.key]||l.key;if(u!=="Unidentified")return u}return l.type==="keypress"?(l=bg(l),l===13?"Enter":String.fromCharCode(l)):l.type==="keydown"||l.type==="keyup"?IV[l.keyCode]||"Unidentified":""},code:0,location:0,ctrlKey:0,shiftKey:0,altKey:0,metaKey:0,repeat:0,locale:0,getModifierState:B1,charCode:function(l){return l.type==="keypress"?bg(l):0},keyCode:function(l){return l.type==="keydown"||l.type==="keyup"?l.keyCode:0},which:function(l){return l.type==="keypress"?bg(l):l.type==="keydown"||l.type==="keyup"?l.keyCode:0}}),NV=gi(LV),$V=E({},Eg,{pointerId:0,width:0,height:0,pressure:0,tangentialPressure:0,tiltX:0,tiltY:0,twist:0,pointerType:0,isPrimary:0}),dP=gi($V),jV=E({},Yf,{touches:0,targetTouches:0,changedTouches:0,altKey:0,metaKey:0,ctrlKey:0,shiftKey:0,getModifierState:B1}),FV=gi(jV),UV=E({},ku,{propertyName:0,elapsedTime:0,pseudoElement:0}),zV=gi(UV),BV=E({},Eg,{deltaX:function(l){return"deltaX"in l?l.deltaX:"wheelDeltaX"in l?-l.wheelDeltaX:0},deltaY:function(l){return"deltaY"in l?l.deltaY:"wheelDeltaY"in l?-l.wheelDeltaY:"wheelDelta"in l?-l.wheelDelta:0},deltaZ:0,deltaMode:0}),HV=gi(BV),VV=[9,13,27,32],H1=a&&"CompositionEvent"in window,Zf=null;a&&"documentMode"in document&&(Zf=document.documentMode);var WV=a&&"TextEvent"in window&&!Zf,fP=a&&(!H1||Zf&&8<Zf&&11>=Zf),hP=" ",pP=!1;function mP(l,u){switch(l){case"keyup":return VV.indexOf(u.keyCode)!==-1;case"keydown":return u.keyCode!==229;case"keypress":case"mousedown":case"focusout":return!0;default:return!1}}function gP(l){return l=l.detail,typeof l=="object"&&"data"in l?l.data:null}var Tu=!1;function qV(l,u){switch(l){case"compositionend":return gP(u);case"keypress":return u.which!==32?null:(pP=!0,hP);case"textInput":return l=u.data,l===hP&&pP?null:l;default:return null}}function KV(l,u){if(Tu)return l==="compositionend"||!H1&&mP(l,u)?(l=aP(),wg=$1=ba=null,Tu=!1,l):null;switch(l){case"paste":return null;case"keypress":if(!(u.ctrlKey||u.altKey||u.metaKey)||u.ctrlKey&&u.altKey){if(u.char&&1<u.char.length)return u.char;if(u.which)return String.fromCharCode(u.which)}return null;case"compositionend":return fP&&u.locale!=="ko"?null:u.data;default:return null}}var GV={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 yP(l){var u=l&&l.nodeName&&l.nodeName.toLowerCase();return u==="input"?!!GV[l.type]:u==="textarea"}function vP(l,u,h,y){Ff(y),u=Rg(u,"onChange"),0<u.length&&(h=new j1("onChange","change",null,h,y),l.push({event:h,listeners:u}))}var Xf=null,Qf=null;function YV(l){NP(l,0)}function xg(l){var u=Iu(l);if(Ue(u))return l}function JV(l,u){if(l==="change")return u}var _P=!1;if(a){var V1;if(a){var W1="oninput"in document;if(!W1){var wP=document.createElement("div");wP.setAttribute("oninput","return;"),W1=typeof wP.oninput=="function"}V1=W1}else V1=!1;_P=V1&&(!document.documentMode||9<document.documentMode)}function bP(){Xf&&(Xf.detachEvent("onpropertychange",SP),Qf=Xf=null)}function SP(l){if(l.propertyName==="value"&&xg(Qf)){var u=[];vP(u,Qf,l,xu(l)),zf(YV,u)}}function ZV(l,u,h){l==="focusin"?(bP(),Xf=u,Qf=h,Xf.attachEvent("onpropertychange",SP)):l==="focusout"&&bP()}function XV(l){if(l==="selectionchange"||l==="keyup"||l==="keydown")return xg(Qf)}function QV(l,u){if(l==="click")return xg(u)}function eW(l,u){if(l==="input"||l==="change")return xg(u)}function tW(l,u){return l===u&&(l!==0||1/l===1/u)||l!==l&&u!==u}var as=typeof Object.is=="function"?Object.is:tW;function eh(l,u){if(as(l,u))return!0;if(typeof l!="object"||l===null||typeof u!="object"||u===null)return!1;var h=Object.keys(l),y=Object.keys(u);if(h.length!==y.length)return!1;for(y=0;y<h.length;y++){var S=h[y];if(!c.call(u,S)||!as(l[S],u[S]))return!1}return!0}function EP(l){for(;l&&l.firstChild;)l=l.firstChild;return l}function xP(l,u){var h=EP(l);l=0;for(var y;h;){if(h.nodeType===3){if(y=l+h.textContent.length,l<=u&&y>=u)return{node:h,offset:u-l};l=y}e:{for(;h;){if(h.nextSibling){h=h.nextSibling;break e}h=h.parentNode}h=void 0}h=EP(h)}}function CP(l,u){return l&&u?l===u?!0:l&&l.nodeType===3?!1:u&&u.nodeType===3?CP(l,u.parentNode):"contains"in l?l.contains(u):l.compareDocumentPosition?!!(l.compareDocumentPosition(u)&16):!1:!1}function kP(){for(var l=window,u=Ve();u instanceof l.HTMLIFrameElement;){try{var h=typeof u.contentWindow.location.href=="string"}catch{h=!1}if(h)l=u.contentWindow;else break;u=Ve(l.document)}return u}function q1(l){var u=l&&l.nodeName&&l.nodeName.toLowerCase();return u&&(u==="input"&&(l.type==="text"||l.type==="search"||l.type==="tel"||l.type==="url"||l.type==="password")||u==="textarea"||l.contentEditable==="true")}function nW(l){var u=kP(),h=l.focusedElem,y=l.selectionRange;if(u!==h&&h&&h.ownerDocument&&CP(h.ownerDocument.documentElement,h)){if(y!==null&&q1(h)){if(u=y.start,l=y.end,l===void 0&&(l=u),"selectionStart"in h)h.selectionStart=u,h.selectionEnd=Math.min(l,h.value.length);else if(l=(u=h.ownerDocument||document)&&u.defaultView||window,l.getSelection){l=l.getSelection();var S=h.textContent.length,T=Math.min(y.start,S);y=y.end===void 0?T:Math.min(y.end,S),!l.extend&&T>y&&(S=y,y=T,T=S),S=xP(h,T);var $=xP(h,y);S&&$&&(l.rangeCount!==1||l.anchorNode!==S.node||l.anchorOffset!==S.offset||l.focusNode!==$.node||l.focusOffset!==$.offset)&&(u=u.createRange(),u.setStart(S.node,S.offset),l.removeAllRanges(),T>y?(l.addRange(u),l.extend($.node,$.offset)):(u.setEnd($.node,$.offset),l.addRange(u)))}}for(u=[],l=h;l=l.parentNode;)l.nodeType===1&&u.push({element:l,left:l.scrollLeft,top:l.scrollTop});for(typeof h.focus=="function"&&h.focus(),h=0;h<u.length;h++)l=u[h],l.element.scrollLeft=l.left,l.element.scrollTop=l.top}}var rW=a&&"documentMode"in document&&11>=document.documentMode,Ru=null,K1=null,th=null,G1=!1;function TP(l,u,h){var y=h.window===h?h.document:h.nodeType===9?h:h.ownerDocument;G1||Ru==null||Ru!==Ve(y)||(y=Ru,"selectionStart"in y&&q1(y)?y={start:y.selectionStart,end:y.selectionEnd}:(y=(y.ownerDocument&&y.ownerDocument.defaultView||window).getSelection(),y={anchorNode:y.anchorNode,anchorOffset:y.anchorOffset,focusNode:y.focusNode,focusOffset:y.focusOffset}),th&&eh(th,y)||(th=y,y=Rg(K1,"onSelect"),0<y.length&&(u=new j1("onSelect","select",null,u,h),l.push({event:u,listeners:y}),u.target=Ru)))}function Cg(l,u){var h={};return h[l.toLowerCase()]=u.toLowerCase(),h["Webkit"+l]="webkit"+u,h["Moz"+l]="moz"+u,h}var Pu={animationend:Cg("Animation","AnimationEnd"),animationiteration:Cg("Animation","AnimationIteration"),animationstart:Cg("Animation","AnimationStart"),transitionend:Cg("Transition","TransitionEnd")},Y1={},RP={};a&&(RP=document.createElement("div").style,"AnimationEvent"in window||(delete Pu.animationend.animation,delete Pu.animationiteration.animation,delete Pu.animationstart.animation),"TransitionEvent"in window||delete Pu.transitionend.transition);function kg(l){if(Y1[l])return Y1[l];if(!Pu[l])return l;var u=Pu[l],h;for(h in u)if(u.hasOwnProperty(h)&&h in RP)return Y1[l]=u[h];return l}var PP=kg("animationend"),OP=kg("animationiteration"),AP=kg("animationstart"),IP=kg("transitionend"),MP=new Map,DP="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 Sa(l,u){MP.set(l,u),s(u,[l])}for(var J1=0;J1<DP.length;J1++){var Z1=DP[J1],iW=Z1.toLowerCase(),sW=Z1[0].toUpperCase()+Z1.slice(1);Sa(iW,"on"+sW)}Sa(PP,"onAnimationEnd"),Sa(OP,"onAnimationIteration"),Sa(AP,"onAnimationStart"),Sa("dblclick","onDoubleClick"),Sa("focusin","onFocus"),Sa("focusout","onBlur"),Sa(IP,"onTransitionEnd"),o("onMouseEnter",["mouseout","mouseover"]),o("onMouseLeave",["mouseout","mouseover"]),o("onPointerEnter",["pointerout","pointerover"]),o("onPointerLeave",["pointerout","pointerover"]),s("onChange","change click focusin focusout input keydown keyup selectionchange".split(" ")),s("onSelect","focusout contextmenu dragend focusin keydown keyup mousedown mouseup selectionchange".split(" ")),s("onBeforeInput",["compositionend","keypress","textInput","paste"]),s("onCompositionEnd","compositionend focusout keydown keypress keyup mousedown".split(" ")),s("onCompositionStart","compositionstart focusout keydown keypress keyup mousedown".split(" ")),s("onCompositionUpdate","compositionupdate focusout keydown keypress keyup mousedown".split(" "));var nh="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(" "),oW=new Set("cancel close invalid load scroll toggle".split(" ").concat(nh));function LP(l,u,h){var y=l.type||"unknown-event";l.currentTarget=h,Ge(y,u,void 0,l),l.currentTarget=null}function NP(l,u){u=(u&4)!==0;for(var h=0;h<l.length;h++){var y=l[h],S=y.event;y=y.listeners;e:{var T=void 0;if(u)for(var $=y.length-1;0<=$;$--){var G=y[$],Q=G.instance,ue=G.currentTarget;if(G=G.listener,Q!==T&&S.isPropagationStopped())break e;LP(S,G,ue),T=Q}else for($=0;$<y.length;$++){if(G=y[$],Q=G.instance,ue=G.currentTarget,G=G.listener,Q!==T&&S.isPropagationStopped())break e;LP(S,G,ue),T=Q}}}if(we)throw l=We,we=!1,We=null,l}function fn(l,u){var h=u[sw];h===void 0&&(h=u[sw]=new Set);var y=l+"__bubble";h.has(y)||($P(u,l,2,!1),h.add(y))}function X1(l,u,h){var y=0;u&&(y|=4),$P(h,l,y,u)}var Tg="_reactListening"+Math.random().toString(36).slice(2);function rh(l){if(!l[Tg]){l[Tg]=!0,r.forEach(function(h){h!=="selectionchange"&&(oW.has(h)||X1(h,!1,l),X1(h,!0,l))});var u=l.nodeType===9?l:l.ownerDocument;u===null||u[Tg]||(u[Tg]=!0,X1("selectionchange",!1,u))}}function $P(l,u,h,y){switch(oP(u)){case 1:var S=wV;break;case 4:S=bV;break;default:S=L1}h=S.bind(null,u,h,l),S=void 0,!Bf||u!=="touchstart"&&u!=="touchmove"&&u!=="wheel"||(S=!0),y?S!==void 0?l.addEventListener(u,h,{capture:!0,passive:S}):l.addEventListener(u,h,!0):S!==void 0?l.addEventListener(u,h,{passive:S}):l.addEventListener(u,h,!1)}function Q1(l,u,h,y,S){var T=y;if((u&1)===0&&(u&2)===0&&y!==null)e:for(;;){if(y===null)return;var $=y.tag;if($===3||$===4){var G=y.stateNode.containerInfo;if(G===S||G.nodeType===8&&G.parentNode===S)break;if($===4)for($=y.return;$!==null;){var Q=$.tag;if((Q===3||Q===4)&&(Q=$.stateNode.containerInfo,Q===S||Q.nodeType===8&&Q.parentNode===S))return;$=$.return}for(;G!==null;){if($=Yl(G),$===null)return;if(Q=$.tag,Q===5||Q===6){y=T=$;continue e}G=G.parentNode}}y=y.return}zf(function(){var ue=T,pe=xu(h),ge=[];e:{var he=MP.get(l);if(he!==void 0){var Me=j1,Ne=l;switch(l){case"keypress":if(bg(h)===0)break e;case"keydown":case"keyup":Me=NV;break;case"focusin":Ne="focus",Me=z1;break;case"focusout":Ne="blur",Me=z1;break;case"beforeblur":case"afterblur":Me=z1;break;case"click":if(h.button===2)break e;case"auxclick":case"dblclick":case"mousedown":case"mousemove":case"mouseup":case"mouseout":case"mouseover":case"contextmenu":Me=cP;break;case"drag":case"dragend":case"dragenter":case"dragexit":case"dragleave":case"dragover":case"dragstart":case"drop":Me=xV;break;case"touchcancel":case"touchend":case"touchmove":case"touchstart":Me=FV;break;case PP:case OP:case AP:Me=TV;break;case IP:Me=zV;break;case"scroll":Me=SV;break;case"wheel":Me=HV;break;case"copy":case"cut":case"paste":Me=PV;break;case"gotpointercapture":case"lostpointercapture":case"pointercancel":case"pointerdown":case"pointermove":case"pointerout":case"pointerover":case"pointerup":Me=dP}var ze=(u&4)!==0,Nn=!ze&&l==="scroll",ie=ze?he!==null?he+"Capture":null:he;ze=[];for(var ee=ue,ae;ee!==null;){ae=ee;var _e=ae.stateNode;if(ae.tag===5&&_e!==null&&(ae=_e,ie!==null&&(_e=Vl(ee,ie),_e!=null&&ze.push(ih(ee,_e,ae)))),Nn)break;ee=ee.return}0<ze.length&&(he=new Me(he,Ne,null,h,pe),ge.push({event:he,listeners:ze}))}}if((u&7)===0){e:{if(he=l==="mouseover"||l==="pointerover",Me=l==="mouseout"||l==="pointerout",he&&h!==jf&&(Ne=h.relatedTarget||h.fromElement)&&(Yl(Ne)||Ne[go]))break e;if((Me||he)&&(he=pe.window===pe?pe:(he=pe.ownerDocument)?he.defaultView||he.parentWindow:window,Me?(Ne=h.relatedTarget||h.toElement,Me=ue,Ne=Ne?Yl(Ne):null,Ne!==null&&(Nn=He(Ne),Ne!==Nn||Ne.tag!==5&&Ne.tag!==6)&&(Ne=null)):(Me=null,Ne=ue),Me!==Ne)){if(ze=cP,_e="onMouseLeave",ie="onMouseEnter",ee="mouse",(l==="pointerout"||l==="pointerover")&&(ze=dP,_e="onPointerLeave",ie="onPointerEnter",ee="pointer"),Nn=Me==null?he:Iu(Me),ae=Ne==null?he:Iu(Ne),he=new ze(_e,ee+"leave",Me,h,pe),he.target=Nn,he.relatedTarget=ae,_e=null,Yl(pe)===ue&&(ze=new ze(ie,ee+"enter",Ne,h,pe),ze.target=ae,ze.relatedTarget=Nn,_e=ze),Nn=_e,Me&&Ne)t:{for(ze=Me,ie=Ne,ee=0,ae=ze;ae;ae=Ou(ae))ee++;for(ae=0,_e=ie;_e;_e=Ou(_e))ae++;for(;0<ee-ae;)ze=Ou(ze),ee--;for(;0<ae-ee;)ie=Ou(ie),ae--;for(;ee--;){if(ze===ie||ie!==null&&ze===ie.alternate)break t;ze=Ou(ze),ie=Ou(ie)}ze=null}else ze=null;Me!==null&&jP(ge,he,Me,ze,!1),Ne!==null&&Nn!==null&&jP(ge,Nn,Ne,ze,!0)}}e:{if(he=ue?Iu(ue):window,Me=he.nodeName&&he.nodeName.toLowerCase(),Me==="select"||Me==="input"&&he.type==="file")var qe=JV;else if(yP(he))if(_P)qe=eW;else{qe=XV;var tt=ZV}else(Me=he.nodeName)&&Me.toLowerCase()==="input"&&(he.type==="checkbox"||he.type==="radio")&&(qe=QV);if(qe&&(qe=qe(l,ue))){vP(ge,qe,h,pe);break e}tt&&tt(l,he,ue),l==="focusout"&&(tt=he._wrapperState)&&tt.controlled&&he.type==="number"&&Xt(he,"number",he.value)}switch(tt=ue?Iu(ue):window,l){case"focusin":(yP(tt)||tt.contentEditable==="true")&&(Ru=tt,K1=ue,th=null);break;case"focusout":th=K1=Ru=null;break;case"mousedown":G1=!0;break;case"contextmenu":case"mouseup":case"dragend":G1=!1,TP(ge,h,pe);break;case"selectionchange":if(rW)break;case"keydown":case"keyup":TP(ge,h,pe)}var nt;if(H1)e:{switch(l){case"compositionstart":var ut="onCompositionStart";break e;case"compositionend":ut="onCompositionEnd";break e;case"compositionupdate":ut="onCompositionUpdate";break e}ut=void 0}else Tu?mP(l,h)&&(ut="onCompositionEnd"):l==="keydown"&&h.keyCode===229&&(ut="onCompositionStart");ut&&(fP&&h.locale!=="ko"&&(Tu||ut!=="onCompositionStart"?ut==="onCompositionEnd"&&Tu&&(nt=aP()):(ba=pe,$1="value"in ba?ba.value:ba.textContent,Tu=!0)),tt=Rg(ue,ut),0<tt.length&&(ut=new uP(ut,l,null,h,pe),ge.push({event:ut,listeners:tt}),nt?ut.data=nt:(nt=gP(h),nt!==null&&(ut.data=nt)))),(nt=WV?qV(l,h):KV(l,h))&&(ue=Rg(ue,"onBeforeInput"),0<ue.length&&(pe=new uP("onBeforeInput","beforeinput",null,h,pe),ge.push({event:pe,listeners:ue}),pe.data=nt))}NP(ge,u)})}function ih(l,u,h){return{instance:l,listener:u,currentTarget:h}}function Rg(l,u){for(var h=u+"Capture",y=[];l!==null;){var S=l,T=S.stateNode;S.tag===5&&T!==null&&(S=T,T=Vl(l,h),T!=null&&y.unshift(ih(l,T,S)),T=Vl(l,u),T!=null&&y.push(ih(l,T,S))),l=l.return}return y}function Ou(l){if(l===null)return null;do l=l.return;while(l&&l.tag!==5);return l||null}function jP(l,u,h,y,S){for(var T=u._reactName,$=[];h!==null&&h!==y;){var G=h,Q=G.alternate,ue=G.stateNode;if(Q!==null&&Q===y)break;G.tag===5&&ue!==null&&(G=ue,S?(Q=Vl(h,T),Q!=null&&$.unshift(ih(h,Q,G))):S||(Q=Vl(h,T),Q!=null&&$.push(ih(h,Q,G)))),h=h.return}$.length!==0&&l.push({event:u,listeners:$})}var aW=/\r\n?/g,lW=/\u0000|\uFFFD/g;function FP(l){return(typeof l=="string"?l:""+l).replace(aW,` 7`).replace(lW,"")}function Pg(l,u,h){if(u=FP(u),FP(l)!==u&&h)throw Error(n(425))}function Og(){}var ew=null,tw=null;function nw(l,u){return l==="textarea"||l==="noscript"||typeof u.children=="string"||typeof u.children=="number"||typeof u.dangerouslySetInnerHTML=="object"&&u.dangerouslySetInnerHTML!==null&&u.dangerouslySetInnerHTML.__html!=null}var rw=typeof setTimeout=="function"?setTimeout:void 0,cW=typeof clearTimeout=="function"?clearTimeout:void 0,UP=typeof Promise=="function"?Promise:void 0,uW=typeof queueMicrotask=="function"?queueMicrotask:typeof UP<"u"?function(l){return UP.resolve(null).then(l).catch(dW)}:rw;function dW(l){setTimeout(function(){throw l})}function iw(l,u){var h=u,y=0;do{var S=h.nextSibling;if(l.removeChild(h),S&&S.nodeType===8)if(h=S.data,h==="/$"){if(y===0){l.removeChild(S),Gf(u);return}y--}else h!=="$"&&h!=="$?"&&h!=="$!"||y++;h=S}while(h);Gf(u)}function Ea(l){for(;l!=null;l=l.nextSibling){var u=l.nodeType;if(u===1||u===3)break;if(u===8){if(u=l.data,u==="$"||u==="$!"||u==="$?")break;if(u==="/$")return null}}return l}function zP(l){l=l.previousSibling;for(var u=0;l;){if(l.nodeType===8){var h=l.data;if(h==="$"||h==="$!"||h==="$?"){if(u===0)return l;u--}else h==="/$"&&u++}l=l.previousSibling}return null}var Au=Math.random().toString(36).slice(2),$s="__reactFiber$"+Au,sh="__reactProps$"+Au,go="__reactContainer$"+Au,sw="__reactEvents$"+Au,fW="__reactListeners$"+Au,hW="__reactHandles$"+Au;function Yl(l){var u=l[$s];if(u)return u;for(var h=l.parentNode;h;){if(u=h[go]||h[$s]){if(h=u.alternate,u.child!==null||h!==null&&h.child!==null)for(l=zP(l);l!==null;){if(h=l[$s])return h;l=zP(l)}return u}l=h,h=l.parentNode}return null}function oh(l){return l=l[$s]||l[go],!l||l.tag!==5&&l.tag!==6&&l.tag!==13&&l.tag!==3?null:l}function Iu(l){if(l.tag===5||l.tag===6)return l.stateNode;throw Error(n(33))}function Ag(l){return l[sh]||null}var ow=[],Mu=-1;function xa(l){return{current:l}}function hn(l){0>Mu||(l.current=ow[Mu],ow[Mu]=null,Mu--)}function ln(l,u){Mu++,ow[Mu]=l.current,l.current=u}var Ca={},Tr=xa(Ca),Xr=xa(!1),Jl=Ca;function Du(l,u){var h=l.type.contextTypes;if(!h)return Ca;var y=l.stateNode;if(y&&y.__reactInternalMemoizedUnmaskedChildContext===u)return y.__reactInternalMemoizedMaskedChildContext;var S={},T;for(T in h)S[T]=u[T];return y&&(l=l.stateNode,l.__reactInternalMemoizedUnmaskedChildContext=u,l.__reactInternalMemoizedMaskedChildContext=S),S}function Qr(l){return l=l.childContextTypes,l!=null}function Ig(){hn(Xr),hn(Tr)}function BP(l,u,h){if(Tr.current!==Ca)throw Error(n(168));ln(Tr,u),ln(Xr,h)}function HP(l,u,h){var y=l.stateNode;if(u=u.childContextTypes,typeof y.getChildContext!="function")return h;y=y.getChildContext();for(var S in y)if(!(S in u))throw Error(n(108,le(l)||"Unknown",S
vendor: 3,754 bytes, line 7
7));return E({},h,y)}function Mg(l){return l=(l=l.stateNode)&&l.__reactInternalMemoizedMergedChildContext||Ca,Jl=Tr.current,ln(Tr,l),ln(Xr,Xr.current),!0}function VP(l,u,h){var y=l.stateNode;if(!y)throw Error(n(169));h?(l=HP(l,u,Jl),y.__reactInternalMemoizedMergedChildContext=l,hn(Xr),hn(Tr),ln(Tr,l)):hn(Xr),ln(Xr,h)}var yo=null,Dg=!1,aw=!1;function WP(l){yo===null?yo=[l]:yo.push(l)}function pW(l){Dg=!0,WP(l)}function ka(){if(!aw&&yo!==null){aw=!0;var l=0,u=en;try{var h=yo;for(en=1;l<h.length;l++){var y=h[l];do y=y(!0);while(y!==null)}yo=null,Dg=!1}catch(S){throw yo!==null&&(yo=yo.slice(l+1)),Ln(Ni,ka),S}finally{en=u,aw=!1}}return null}var Lu=[],Nu=0,Lg=null,Ng=0,$i=[],ji=0,Zl=null,vo=1,_o="";function Xl(l,u){Lu[Nu++]=Ng,Lu[Nu++]=Lg,Lg=l,Ng=u}function qP(l,u,h){$i[ji++]=vo,$i[ji++]=_o,$i[ji++]=Zl,Zl=l;var y=vo;l=_o;var S=32-nn(y)-1;y&=~(1<<S),h+=1;var T=32-nn(u)+S;if(30<T){var $=S-S%5;T=(y&(1<<$)-1).toString(32),y>>=$,S-=$,vo=1<<32-nn(u)+S|h<<S|y,_o=T+l}else vo=1<<T|h<<S|y,_o=l}function lw(l){l.return!==null&&(Xl(l,1),qP(l,1,0))}function cw(l){for(;l===Lg;)Lg=Lu[--Nu],Lu[Nu]=null,Ng=Lu[--Nu],Lu[Nu]=null;for(;l===Zl;)Zl=$i[--ji],$i[ji]=null,_o=$i[--ji],$i[ji]=null,vo=$i[--ji],$i[ji]=null}var yi=null,vi=null,_n=!1,ls=null;function KP(l,u){var h=Bi(5,null,null,0);h.elementType="DELETED",h.stateNode=u,h.return=l,u=l.deletions,u===null?(l.deletions=[h],l.flags|=16):u.push(h)}function GP(l,u){switch(l.tag){case 5:var h=l.type;return u=u.nodeType!==1||h.toLowerCase()!==u.nodeName.toLowerCase()?null:u,u!==null?(l.stateNode=u,yi=l,vi=Ea(u.firstChild),!0):!1;case 6:return u=l.pendingProps===""||u.nodeType!==3?null:u,u!==null?(l.stateNode=u,yi=l,vi=null,!0):!1;case 13:return u=u.nodeType!==8?null:u,u!==null?(h=Zl!==null?{id:vo,overflow:_o}:null,l.memoizedState={dehydrated:u,treeContext:h,retryLane:1073741824},h=Bi(18,null,null,0),h.stateNode=u,h.return=l,l.child=h,yi=l,vi=null,!0):!1;default:return!1}}function uw(l){return(l.mode&1)!==0&&(l.flags&128)===0}function dw(l){if(_n){var u=vi;if(u){var h=u;if(!GP(l,u)){if(uw(l))throw Error(n(418));u=Ea(h.nextSibling);var y=yi;u&&GP(l,u)?KP(y,h):(l.flags=l.flags&-4097|2,_n=!1,yi=l)}}else{if(uw(l))throw Error(n(418));l.flags=l.flags&-4097|2,_n=!1,yi=l}}}function YP(l){for(l=l.return;l!==null&&l.tag!==5&&l.tag!==3&&l.tag!==13;)l=l.return;yi=l}function $g(l){if(l!==yi)return!1;if(!_n)return YP(l),_n=!0,!1;var u;if((u=l.tag!==3)&&!(u=l.tag!==5)&&(u=l.type,u=u!=="head"&&u!=="body"&&!nw(l.type,l.memoizedProps)),u&&(u=vi)){if(uw(l))throw JP(),Error(n(418));for(;u;)KP(l,u),u=Ea(u.nextSibling)}if(YP(l),l.tag===13){if(l=l.memoizedState,l=l!==null?l.dehydrated:null,!l)throw Error(n(317));e:{for(l=l.nextSibling,u=0;l;){if(l.nodeType===8){var h=l.data;if(h==="/$"){if(u===0){vi=Ea(l.nextSibling);break e}u--}else h!=="$"&&h!=="$!"&&h!=="$?"||u++}l=l.nextSibling}vi=null}}else vi=yi?Ea(l.stateNode.nextSibling):null;return!0}function JP(){for(var l=vi;l;)l=Ea(l.nextSibling)}function $u(){vi=yi=null,_n=!1}function fw(l){ls===null?ls=[l]:ls.push(l)}var mW=F.ReactCurrentBatchConfig;function ah(l,u,h){if(l=h.ref,l!==null&&typeof l!="function"&&typeof l!="object"){if(h._owner){if(h=h._owner,h){if(h.tag!==1)throw Error(n(309));var y=h.stateNode}if(!y)throw Error(n(147,l));var S=y,T=""+l;return u!==null&&u.ref!==null&&typeof u.ref=="function"&&u.ref._stringRef===T?u.ref:(u=function($){var G=S.refs;$===null?delete G[T]:G[T]=$},u._stringRef=T,u)}if(typeof l!="string")throw Error(n(284));if(!h._owner)throw Error(n(290,l))}return l}function jg(l,u){throw l=Object.prototype.toString.call(u),Error(n(31,l==="[object Object]"?"object with keys {"+Object.keys(u).join(", ")+"}":l))}function ZP(l){var u=l._init;return u(l._payload)}function XP(l){function u(ie,ee){if(l){var ae=ie.deletions;
vendor: 5,385 bytes, line 7
7ae===null?(ie.deletions=[ee],ie.flags|=16):ae.push(ee)}}function h(ie,ee){if(!l)return null;for(;ee!==null;)u(ie,ee),ee=ee.sibling;return null}function y(ie,ee){for(ie=new Map;ee!==null;)ee.key!==null?ie.set(ee.key,ee):ie.set(ee.index,ee),ee=ee.sibling;return ie}function S(ie,ee){return ie=Da(ie,ee),ie.index=0,ie.sibling=null,ie}function T(ie,ee,ae){return ie.index=ae,l?(ae=ie.alternate,ae!==null?(ae=ae.index,ae<ee?(ie.flags|=2,ee):ae):(ie.flags|=2,ee)):(ie.flags|=1048576,ee)}function $(ie){return l&&ie.alternate===null&&(ie.flags|=2),ie}function G(ie,ee,ae,_e){return ee===null||ee.tag!==6?(ee=rb(ae,ie.mode,_e),ee.return=ie,ee):(ee=S(ee,ae),ee.return=ie,ee)}function Q(ie,ee,ae,_e){var qe=ae.type;return qe===k?pe(ie,ee,ae.props.children,_e,ae.key):ee!==null&&(ee.elementType===qe||typeof qe=="object"&&qe!==null&&qe.$$typeof===z&&ZP(qe)===ee.type)?(_e=S(ee,ae.props),_e.ref=ah(ie,ee,ae),_e.return=ie,_e):(_e=ly(ae.type,ae.key,ae.props,null,ie.mode,_e),_e.ref=ah(ie,ee,ae),_e.return=ie,_e)}function ue(ie,ee,ae,_e){return ee===null||ee.tag!==4||ee.stateNode.containerInfo!==ae.containerInfo||ee.stateNode.implementation!==ae.implementation?(ee=ib(ae,ie.mode,_e),ee.return=ie,ee):(ee=S(ee,ae.children||[]),ee.return=ie,ee)}function pe(ie,ee,ae,_e,qe){return ee===null||ee.tag!==7?(ee=oc(ae,ie.mode,_e,qe),ee.return=ie,ee):(ee=S(ee,ae),ee.return=ie,ee)}function ge(ie,ee,ae){if(typeof ee=="string"&&ee!==""||typeof ee=="number")return ee=rb(""+ee,ie.mode,ae),ee.return=ie,ee;if(typeof ee=="object"&&ee!==null){switch(ee.$$typeof){case R:return ae=ly(ee.type,ee.key,ee.props,null,ie.mode,ae),ae.ref=ah(ie,null,ee),ae.return=ie,ae;case I:return ee=ib(ee,ie.mode,ae),ee.return=ie,ee;case z:var _e=ee._init;return ge(ie,_e(ee._payload),ae)}if(Je(ee)||M(ee))return ee=oc(ee,ie.mode,ae,null),ee.return=ie,ee;jg(ie,ee)}return null}function he(ie,ee,ae,_e){var qe=ee!==null?ee.key:null;if(typeof ae=="string"&&ae!==""||typeof ae=="number")return qe!==null?null:G(ie,ee,""+ae,_e);if(typeof ae=="object"&&ae!==null){switch(ae.$$typeof){case R:return ae.key===qe?Q(ie,ee,ae,_e):null;case I:return ae.key===qe?ue(ie,ee,ae,_e):null;case z:return qe=ae._init,he(ie,ee,qe(ae._payload),_e)}if(Je(ae)||M(ae))return qe!==null?null:pe(ie,ee,ae,_e,null);jg(ie,ae)}return null}function Me(ie,ee,ae,_e,qe){if(typeof _e=="string"&&_e!==""||typeof _e=="number")return ie=ie.get(ae)||null,G(ee,ie,""+_e,qe);if(typeof _e=="object"&&_e!==null){switch(_e.$$typeof){case R:return ie=ie.get(_e.key===null?ae:_e.key)||null,Q(ee,ie,_e,qe);case I:return ie=ie.get(_e.key===null?ae:_e.key)||null,ue(ee,ie,_e,qe);case z:var tt=_e._init;return Me(ie,ee,ae,tt(_e._payload),qe)}if(Je(_e)||M(_e))return ie=ie.get(ae)||null,pe(ee,ie,_e,qe,null);jg(ee,_e)}return null}function Ne(ie,ee,ae,_e){for(var qe=null,tt=null,nt=ee,ut=ee=0,hr=null;nt!==null&&ut<ae.length;ut++){nt.index>ut?(hr=nt,nt=null):hr=nt.sibling;var Kt=he(ie,nt,ae[ut],_e);if(Kt===null){nt===null&&(nt=hr);break}l&&nt&&Kt.alternate===null&&u(ie,nt),ee=T(Kt,ee,ut),tt===null?qe=Kt:tt.sibling=Kt,tt=Kt,nt=hr}if(ut===ae.length)return h(ie,nt),_n&&Xl(ie,ut),qe;if(nt===null){for(;ut<ae.length;ut++)nt=ge(ie,ae[ut],_e),nt!==null&&(ee=T(nt,ee,ut),tt===null?qe=nt:tt.sibling=nt,tt=nt);return _n&&Xl(ie,ut),qe}for(nt=y(ie,nt);ut<ae.length;ut++)hr=Me(nt,ie,ut,ae[ut],_e),hr!==null&&(l&&hr.alternate!==null&&nt.delete(hr.key===null?ut:hr.key),ee=T(hr,ee,ut),tt===null?qe=hr:tt.sibling=hr,tt=hr);return l&&nt.forEach(function(La){return u(ie,La)}),_n&&Xl(ie,ut),qe}function ze(ie,ee,ae,_e){var qe=M(ae);if(typeof qe!="function")throw Error(n(150));if(ae=qe.call(ae),ae==null)throw Error(n(151));for(var tt=qe=null,nt=ee,ut=ee=0,hr=null,Kt=ae.next();nt!==null&&!Kt.done;ut++,Kt=ae.next()){nt.index>ut?(hr=nt,nt=null):hr=nt.sibling;var La=he(ie,nt,Kt.value,_e);if(La===null){nt===null&&(nt=hr);break}l&&nt&&La.alternate===null&&u(ie,nt),ee=T(La,ee,ut),tt===null?qe=La:tt.sibling=La,tt=La,nt=hr}if(Kt.done)return h(ie,nt),_n&&Xl(ie,ut),qe;if(nt===null){for(;!Kt.done;ut++,Kt=ae.next())Kt=ge(ie,Kt.value,_e),Kt!==null&&(ee=T(Kt,ee,ut),tt===null?qe=Kt:tt.sibling=Kt,tt=Kt);return _n&&Xl(ie,ut),qe}for(nt=y(ie,nt);!Kt.done;ut++,Kt=ae.next())Kt=Me(nt,ie,ut,Kt.value,_e),Kt!==null&&(l&&Kt.alternate!==null&&nt.delete(Kt.key===null?ut:Kt.key),ee=T(Kt,ee,ut),tt===null?qe=Kt:tt.sibling=Kt,tt=Kt);return l&&nt.forEach(function(GW){return u(ie,GW)}),_n&&Xl(ie,ut),qe}function Nn(ie,ee,ae,_e){if(typeof ae=="object"&&ae!==null&&ae.type===k&&ae.key===null&&(ae=ae.props.children),typeof ae=="object"&&ae!==null){switch(ae.$$typeof){case R:e:{for(var qe=ae.key,tt=ee;tt!==null;){if(tt.key===qe){if(qe=ae.type,qe===k){if(tt.tag===7){h(ie,tt.sibling),ee=S(tt,ae.props.children),ee.return=ie,ie=ee;break e}}else if(tt.elementType===qe||typeof qe=="object"&&qe!==null&&qe.$$typeof===z&&ZP(qe)===tt.type){h(ie,tt.sibling),ee=S(tt,ae.props),ee.ref=ah(ie,tt,ae),ee.return=ie,ie=ee;break e}h(ie,tt);break}else u(ie,tt);tt=tt.sibling}ae.type===k?(ee=oc(ae.props.children,ie.mode,_e,ae.key),ee.return=ie,ie=ee):(_e=ly(ae.type,ae.key,ae.props,null,ie.mode,_e),_e.ref=ah(ie,ee,ae),_e.return=ie,ie=_e)}return $(ie);case I:e:{for(tt=ae.key;ee!==null;){if(ee.key===tt)if(ee.tag===4&&ee.stateNode.containerInfo===ae.containerInfo&&ee.stateNode.implementation===ae.implementation){h(ie,ee.sibling),ee=S(ee,ae.children||[]),ee.return=ie,ie=ee;break e}else{h(ie,ee);break}else u(ie,ee);ee=ee.sibling}
vendor: 9,403 bytes, line 7
7ee=ib(ae,ie.mode,_e),ee.return=ie,ie=ee}return $(ie);case z:return tt=ae._init,Nn(ie,ee,tt(ae._payload),_e)}if(Je(ae))return Ne(ie,ee,ae,_e);if(M(ae))return ze(ie,ee,ae,_e);jg(ie,ae)}return typeof ae=="string"&&ae!==""||typeof ae=="number"?(ae=""+ae,ee!==null&&ee.tag===6?(h(ie,ee.sibling),ee=S(ee,ae),ee.return=ie,ie=ee):(h(ie,ee),ee=rb(ae,ie.mode,_e),ee.return=ie,ie=ee),$(ie)):h(ie,ee)}return Nn}var ju=XP(!0),QP=XP(!1),Fg=xa(null),Ug=null,Fu=null,hw=null;function pw(){hw=Fu=Ug=null}function mw(l){var u=Fg.current;hn(Fg),l._currentValue=u}function gw(l,u,h){for(;l!==null;){var y=l.alternate;if((l.childLanes&u)!==u?(l.childLanes|=u,y!==null&&(y.childLanes|=u)):y!==null&&(y.childLanes&u)!==u&&(y.childLanes|=u),l===h)break;l=l.return}}function Uu(l,u){Ug=l,hw=Fu=null,l=l.dependencies,l!==null&&l.firstContext!==null&&((l.lanes&u)!==0&&(ei=!0),l.firstContext=null)}function Fi(l){var u=l._currentValue;if(hw!==l)if(l={context:l,memoizedValue:u,next:null},Fu===null){if(Ug===null)throw Error(n(308));Fu=l,Ug.dependencies={lanes:0,firstContext:l}}else Fu=Fu.next=l;return u}var Ql=null;function yw(l){Ql===null?Ql=[l]:Ql.push(l)}function e3(l,u,h,y){var S=u.interleaved;return S===null?(h.next=h,yw(u)):(h.next=S.next,S.next=h),u.interleaved=h,wo(l,y)}function wo(l,u){l.lanes|=u;var h=l.alternate;for(h!==null&&(h.lanes|=u),h=l,l=l.return;l!==null;)l.childLanes|=u,h=l.alternate,h!==null&&(h.childLanes|=u),h=l,l=l.return;return h.tag===3?h.stateNode:null}var Ta=!1;function vw(l){l.updateQueue={baseState:l.memoizedState,firstBaseUpdate:null,lastBaseUpdate:null,shared:{pending:null,interleaved:null,lanes:0},effects:null}}function t3(l,u){l=l.updateQueue,u.updateQueue===l&&(u.updateQueue={baseState:l.baseState,firstBaseUpdate:l.firstBaseUpdate,lastBaseUpdate:l.lastBaseUpdate,shared:l.shared,effects:l.effects})}function bo(l,u){return{eventTime:l,lane:u,tag:0,payload:null,callback:null,next:null}}function Ra(l,u,h){var y=l.updateQueue;if(y===null)return null;if(y=y.shared,(Ht&2)!==0){var S=y.pending;return S===null?u.next=u:(u.next=S.next,S.next=u),y.pending=u,wo(l,h)}return S=y.interleaved,S===null?(u.next=u,yw(y)):(u.next=S.next,S.next=u),y.interleaved=u,wo(l,h)}function zg(l,u,h){if(u=u.updateQueue,u!==null&&(u=u.shared,(h&4194240)!==0)){var y=u.lanes;y&=l.pendingLanes,h|=y,u.lanes=h,I1(l,h)}}function n3(l,u){var h=l.updateQueue,y=l.alternate;if(y!==null&&(y=y.updateQueue,h===y)){var S=null,T=null;if(h=h.firstBaseUpdate,h!==null){do{var $={eventTime:h.eventTime,lane:h.lane,tag:h.tag,payload:h.payload,callback:h.callback,next:null};T===null?S=T=$:T=T.next=$,h=h.next}while(h!==null);T===null?S=T=u:T=T.next=u}else S=T=u;h={baseState:y.baseState,firstBaseUpdate:S,lastBaseUpdate:T,shared:y.shared,effects:y.effects},l.updateQueue=h;return}l=h.lastBaseUpdate,l===null?h.firstBaseUpdate=u:l.next=u,h.lastBaseUpdate=u}function Bg(l,u,h,y){var S=l.updateQueue;Ta=!1;var T=S.firstBaseUpdate,$=S.lastBaseUpdate,G=S.shared.pending;if(G!==null){S.shared.pending=null;var Q=G,ue=Q.next;Q.next=null,$===null?T=ue:$.next=ue,$=Q;var pe=l.alternate;pe!==null&&(pe=pe.updateQueue,G=pe.lastBaseUpdate,G!==$&&(G===null?pe.firstBaseUpdate=ue:G.next=ue,pe.lastBaseUpdate=Q))}if(T!==null){var ge=S.baseState;$=0,pe=ue=Q=null,G=T;do{var he=G.lane,Me=G.eventTime;if((y&he)===he){pe!==null&&(pe=pe.next={eventTime:Me,lane:0,tag:G.tag,payload:G.payload,callback:G.callback,next:null});e:{var Ne=l,ze=G;switch(he=u,Me=h,ze.tag){case 1:if(Ne=ze.payload,typeof Ne=="function"){ge=Ne.call(Me,ge,he);break e}ge=Ne;break e;case 3:Ne.flags=Ne.flags&-65537|128;case 0:if(Ne=ze.payload,he=typeof Ne=="function"?Ne.call(Me,ge,he):Ne,he==null)break e;ge=E({},ge,he);break e;case 2:Ta=!0}}G.callback!==null&&G.lane!==0&&(l.flags|=64,he=S.effects,he===null?S.effects=[G]:he.push(G))}else Me={eventTime:Me,lane:he,tag:G.tag,payload:G.payload,callback:G.callback,next:null},pe===null?(ue=pe=Me,Q=ge):pe=pe.next=Me,$|=he;if(G=G.next,G===null){if(G=S.shared.pending,G===null)break;he=G,G=he.next,he.next=null,S.lastBaseUpdate=he,S.shared.pending=null}}while(!0);if(pe===null&&(Q=ge),S.baseState=Q,S.firstBaseUpdate=ue,S.lastBaseUpdate=pe,u=S.shared.interleaved,u!==null){S=u;do $|=S.lane,S=S.next;while(S!==u)}else T===null&&(S.shared.lanes=0);nc|=$,l.lanes=$,l.memoizedState=ge}}function r3(l,u,h){if(l=u.effects,u.effects=null,l!==null)for(u=0;u<l.length;u++){var y=l[u],S=y.callback;if(S!==null){if(y.callback=null,y=h,typeof S!="function")throw Error(n(191,S));S.call(y)}}}var lh={},js=xa(lh),ch=xa(lh),uh=xa(lh);function ec(l){if(l===lh)throw Error(n(174));return l}function _w(l,u){switch(ln(uh,u),ln(ch,l),ln(js,lh),l=u.nodeType,l){case 9:case 11:u=(u=u.documentElement)?u.namespaceURI:kr(null,"");break;default:l=l===8?u.parentNode:u,u=l.namespaceURI||null,l=l.tagName,u=kr(u,l)}hn(js),ln(js,u)}function zu(){hn(js),hn(ch),hn(uh)}function i3(l){ec(uh.current);var u=ec(js.current),h=kr(u,l.type);u!==h&&(ln(ch,l),ln(js,h))}function ww(l){ch.current===l&&(hn(js),hn(ch))}var Sn=xa(0);function Hg(l){for(var u=l;u!==null;){if(u.tag===13){var h=u.memoizedState;if(h!==null&&(h=h.dehydrated,h===null||h.data==="$?"||h.data==="$!"))return u}else if(u.tag===19&&u.memoizedProps.revealOrder!==void 0){if((u.flags&128)!==0)return u}else if(u.child!==null){u.child.return=u,u=u.child;continue}if(u===l)break;for(;u.sibling===null;){if(u.return===null||u.return===l)return null;u=u.return}u.sibling.return=u.return,u=u.sibling}return null}var bw=[];function Sw(){for(var l=0;l<bw.length;l++)bw[l]._workInProgressVersionPrimary=null;bw.length=0}var Vg=F.ReactCurrentDispatcher,Ew=F.ReactCurrentBatchConfig,tc=0,En=null,er=null,dr=null,Wg=!1,dh=!1,fh=0,gW=0;function Rr(){throw Error(n(321))}function xw(l,u){if(u===null)return!1;for(var h=0;h<u.length&&h<l.length;h++)if(!as(l[h],u[h]))return!1;return!0}function Cw(l,u,h,y,S,T){if(tc=T,En=u,u.memoizedState=null,u.updateQueue=null,u.lanes=0,Vg.current=l===null||l.memoizedState===null?wW:bW,l=h(y,S),dh){T=0;do{if(dh=!1,fh=0,25<=T)throw Error(n(301));T+=1,dr=er=null,u.updateQueue=null,Vg.current=SW,l=h(y,S)}while(dh)}if(Vg.current=Gg,u=er!==null&&er.next!==null,tc=0,dr=er=En=null,Wg=!1,u)throw Error(n(300));return l}function kw(){var l=fh!==0;return fh=0,l}function Fs(){var l={memoizedState:null,baseState:null,baseQueue:null,queue:null,next:null};return dr===null?En.memoizedState=dr=l:dr=dr.next=l,dr}function Ui(){if(er===null){var l=En.alternate;l=l!==null?l.memoizedState:null}else l=er.next;var u=dr===null?En.memoizedState:dr.next;if(u!==null)dr=u,er=l;else{if(l===null)throw Error(n(310));er=l,l={memoizedState:er.memoizedState,baseState:er.baseState,baseQueue:er.baseQueue,queue:er.queue,next:null},dr===null?En.memoizedState=dr=l:dr=dr.next=l}return dr}function hh(l,u){return typeof u=="function"?u(l):u}function Tw(l){var u=Ui(),h=u.queue;if(h===null)throw Error(n(311));h.lastRenderedReducer=l;var y=er,S=y.baseQueue,T=h.pending;if(T!==null){if(S!==null){var $=S.next;S.next=T.next,T.next=$}y.baseQueue=S=T,h.pending=null}if(S!==null){T=S.next,y=y.baseState;var G=$=null,Q=null,ue=T;do{var pe=ue.lane;if((tc&pe)===pe)Q!==null&&(Q=Q.next={lane:0,action:ue.action,hasEagerState:ue.hasEagerState,eagerState:ue.eagerState,next:null}),y=ue.hasEagerState?ue.eagerState:l(y,ue.action);else{var ge={lane:pe,action:ue.action,hasEagerState:ue.hasEagerState,eagerState:ue.eagerState,next:null};Q===null?(G=Q=ge,$=y):Q=Q.next=ge,En.lanes|=pe,nc|=pe}ue=ue.next}while(ue!==null&&ue!==T);Q===null?$=y:Q.next=G,as(y,u.memoizedState)||(ei=!0),u.memoizedState=y,u.baseState=$,u.baseQueue=Q,h.lastRenderedState=y}if(l=h.interleaved,l!==null){S=l;do T=S.lane,En.lanes|=T,nc|=T,S=S.next;while(S!==l)}else S===null&&(h.lanes=0);return[u.memoizedState,h.dispatch]}function Rw(l){var u=Ui(),h=u.queue;if(h===null)throw Error(n(311));h.lastRenderedReducer=l;var y=h.dispatch,S=h.pending,T=u.memoizedState;if(S!==null){h.pending=null;var $=S=S.next;do T=l(T,$.action),$=$.next;while($!==S);as(T,u.memoizedState)||(ei=!0),u.memoizedState=T,u.baseQueue===null&&(u.baseState=T),h.lastRenderedState=T}return[T,y]}function s3(){}function o3(l,u){var h=En,y=Ui(),S=u(),T=!as(y.memoizedState,S);if(T&&(y.memoizedState=S,ei=!0),y=y.queue,Pw(c3.bind(null,h,y,l),[l]),y.getSnapshot!==u||T||dr!==null&&dr.memoizedState.tag&1){if(h.flags|=2048,ph(9,l3.bind(null,h,y,S,u),void 0,null),fr===null)throw Error(n(349));(tc&30)!==0||a3(h,u,S)}return S}function a3(l,u,h){l.flags|=16384,l={getSnapshot:u,value:h},u=En.updateQueue,u===null?(u={lastEffect:null,stores:null},En.updateQueue=u,u.stores=[l]):(h=u.stores,h===null?u.stores=[l]:h.push(l))}function l3(l,u,h,y){u.value=h,u.getSnapshot=y,u3(u)&&d3(l)}function c3(l,u,h){return h(function(){u3(u)&&d3(l)})}function u3(l){var u=l.getSnapshot;l=l.value;try{var h=u();return!as(l,h)}catch{return!0}}function d3(l){var u=wo(l,1);u!==null&&fs(u,l,1,-1)}function f3(l){var u=Fs();return typeof l=="function"&&(l=l()),u.memoizedState=u.baseState=l,l={pending:null,interleaved:null,lanes:0,dispatch:null,lastRenderedReducer:hh,lastRenderedState:l},u.queue=l,l=l.dispatch=_W.bind(null,En,l),[u.memoizedState,l]}function ph(l,u,h,y){return l={tag:l,create:u,destroy:h,deps:y,next:null},u=En.updateQueue,u===null?(u={lastEffect:null,stores:null},En.updateQueue=u,u.lastEffect=l.next=l):(h=u.lastEffect,h===null?u.lastEffect=l.next=l:(y=h.next,h.next=l,l.next=y,u.lastEffect=l)),l}function h3(){return Ui().memoizedState}function qg(l,u,h,y){var S=Fs();
vendor: 4,197 bytes, line 7
7En.flags|=l,S.memoizedState=ph(1|u,h,void 0,y===void 0?null:y)}function Kg(l,u,h,y){var S=Ui();y=y===void 0?null:y;var T=void 0;if(er!==null){var $=er.memoizedState;if(T=$.destroy,y!==null&&xw(y,$.deps)){S.memoizedState=ph(u,h,T,y);return}}En.flags|=l,S.memoizedState=ph(1|u,h,T,y)}function p3(l,u){return qg(8390656,8,l,u)}function Pw(l,u){return Kg(2048,8,l,u)}function m3(l,u){return Kg(4,2,l,u)}function g3(l,u){return Kg(4,4,l,u)}function y3(l,u){if(typeof u=="function")return l=l(),u(l),function(){u(null)};if(u!=null)return l=l(),u.current=l,function(){u.current=null}}function v3(l,u,h){return h=h!=null?h.concat([l]):null,Kg(4,4,y3.bind(null,u,l),h)}function Ow(){}function _3(l,u){var h=Ui();u=u===void 0?null:u;var y=h.memoizedState;return y!==null&&u!==null&&xw(u,y[1])?y[0]:(h.memoizedState=[l,u],l)}function w3(l,u){var h=Ui();u=u===void 0?null:u;var y=h.memoizedState;return y!==null&&u!==null&&xw(u,y[1])?y[0]:(l=l(),h.memoizedState=[l,u],l)}function b3(l,u,h){return(tc&21)===0?(l.baseState&&(l.baseState=!1,ei=!0),l.memoizedState=h):(as(h,u)||(h=ZR(),En.lanes|=h,nc|=h,l.baseState=!0),u)}function yW(l,u){var h=en;en=h!==0&&4>h?h:4,l(!0);var y=Ew.transition;Ew.transition={};try{l(!1),u()}finally{en=h,Ew.transition=y}}function S3(){return Ui().memoizedState}function vW(l,u,h){var y=Ia(l);if(h={lane:y,action:h,hasEagerState:!1,eagerState:null,next:null},E3(l))x3(u,h);else if(h=e3(l,u,h,y),h!==null){var S=jr();fs(h,l,y,S),C3(h,u,y)}}function _W(l,u,h){var y=Ia(l),S={lane:y,action:h,hasEagerState:!1,eagerState:null,next:null};if(E3(l))x3(u,S);else{var T=l.alternate;if(l.lanes===0&&(T===null||T.lanes===0)&&(T=u.lastRenderedReducer,T!==null))try{var $=u.lastRenderedState,G=T($,h);if(S.hasEagerState=!0,S.eagerState=G,as(G,$)){var Q=u.interleaved;Q===null?(S.next=S,yw(u)):(S.next=Q.next,Q.next=S),u.interleaved=S;return}}catch{}finally{}h=e3(l,u,S,y),h!==null&&(S=jr(),fs(h,l,y,S),C3(h,u,y))}}function E3(l){var u=l.alternate;return l===En||u!==null&&u===En}function x3(l,u){dh=Wg=!0;var h=l.pending;h===null?u.next=u:(u.next=h.next,h.next=u),l.pending=u}function C3(l,u,h){if((h&4194240)!==0){var y=u.lanes;y&=l.pendingLanes,h|=y,u.lanes=h,I1(l,h)}}var Gg={readContext:Fi,useCallback:Rr,useContext:Rr,useEffect:Rr,useImperativeHandle:Rr,useInsertionEffect:Rr,useLayoutEffect:Rr,useMemo:Rr,useReducer:Rr,useRef:Rr,useState:Rr,useDebugValue:Rr,useDeferredValue:Rr,useTransition:Rr,useMutableSource:Rr,useSyncExternalStore:Rr,useId:Rr,unstable_isNewReconciler:!1},wW={readContext:Fi,useCallback:function(l,u){return Fs().memoizedState=[l,u===void 0?null:u],l},useContext:Fi,useEffect:p3,useImperativeHandle:function(l,u,h){return h=h!=null?h.concat([l]):null,qg(4194308,4,y3.bind(null,u,l),h)},useLayoutEffect:function(l,u){return qg(4194308,4,l,u)},useInsertionEffect:function(l,u){return qg(4,2,l,u)},useMemo:function(l,u){var h=Fs();return u=u===void 0?null:u,l=l(),h.memoizedState=[l,u],l},useReducer:function(l,u,h){var y=Fs();return u=h!==void 0?h(u):u,y.memoizedState=y.baseState=u,l={pending:null,interleaved:null,lanes:0,dispatch:null,lastRenderedReducer:l,lastRenderedState:u},y.queue=l,l=l.dispatch=vW.bind(null,En,l),[y.memoizedState,l]},useRef:function(l){var u=Fs();return l={current:l},u.memoizedState=l},useState:f3,useDebugValue:Ow,useDeferredValue:function(l){return Fs().memoizedState=l},useTransition:function(){var l=f3(!1),u=l[0];return l=yW.bind(null,l[1]),Fs().memoizedState=l,[u,l]},useMutableSource:function(){},useSyncExternalStore:function(l,u,h){var y=En,S=Fs();if(_n){if(h===void 0)throw Error(n(407));h=h()}else{if(h=u(),fr===null)throw Error(n(349));(tc&30)!==0||a3(y,u,h)}S.memoizedState=h;var T={value:h,getSnapshot:u};return S.queue=T,p3(c3.bind(null,y,T,l),[l]),y.flags|=2048,ph(9,l3.bind(null,y,T,h,u),void 0,null),h},useId:function(){var l=Fs(),u=fr.identifierPrefix;if(_n){var h=_o,y=vo;h=(y&~(1<<32-nn(y)-1)).toString(32)+h,u=":"+u+"R"+h,h=fh++,0<h&&(u+="H"+h.toString(32)),u+=":"}else h=gW++,u=":"+u+"r"+h.toString(32)+":";return l.memoizedState=u},unstable_isNewReconciler:!1},bW={readContext:Fi,useCallback:_3,useContext:Fi,useEffect:Pw,useImperativeHandle:v3,useInsertionEffect:m3,useLayoutEffect:g3,useMemo:w3,useReducer:Tw,useRef
vendor: 5,376 bytes, lines 7-9
7:h3,useState:function(){return Tw(hh)},useDebugValue:Ow,useDeferredValue:function(l){var u=Ui();return b3(u,er.memoizedState,l)},useTransition:function(){var l=Tw(hh)[0],u=Ui().memoizedState;return[l,u]},useMutableSource:s3,useSyncExternalStore:o3,useId:S3,unstable_isNewReconciler:!1},SW={readContext:Fi,useCallback:_3,useContext:Fi,useEffect:Pw,useImperativeHandle:v3,useInsertionEffect:m3,useLayoutEffect:g3,useMemo:w3,useReducer:Rw,useRef:h3,useState:function(){return Rw(hh)},useDebugValue:Ow,useDeferredValue:function(l){var u=Ui();return er===null?u.memoizedState=l:b3(u,er.memoizedState,l)},useTransition:function(){var l=Rw(hh)[0],u=Ui().memoizedState;return[l,u]},useMutableSource:s3,useSyncExternalStore:o3,useId:S3,unstable_isNewReconciler:!1};function cs(l,u){if(l&&l.defaultProps){u=E({},u),l=l.defaultProps;for(var h in l)u[h]===void 0&&(u[h]=l[h]);return u}return u}function Aw(l,u,h,y){u=l.memoizedState,h=h(y,u),h=h==null?u:E({},u,h),l.memoizedState=h,l.lanes===0&&(l.updateQueue.baseState=h)}var Yg={isMounted:function(l){return(l=l._reactInternals)?He(l)===l:!1},enqueueSetState:function(l,u,h){l=l._reactInternals;var y=jr(),S=Ia(l),T=bo(y,S);T.payload=u,h!=null&&(T.callback=h),u=Ra(l,T,S),u!==null&&(fs(u,l,S,y),zg(u,l,S))},enqueueReplaceState:function(l,u,h){l=l._reactInternals;var y=jr(),S=Ia(l),T=bo(y,S);T.tag=1,T.payload=u,h!=null&&(T.callback=h),u=Ra(l,T,S),u!==null&&(fs(u,l,S,y),zg(u,l,S))},enqueueForceUpdate:function(l,u){l=l._reactInternals;var h=jr(),y=Ia(l),S=bo(h,y);S.tag=2,u!=null&&(S.callback=u),u=Ra(l,S,y),u!==null&&(fs(u,l,y,h),zg(u,l,y))}};function k3(l,u,h,y,S,T,$){return l=l.stateNode,typeof l.shouldComponentUpdate=="function"?l.shouldComponentUpdate(y,T,$):u.prototype&&u.prototype.isPureReactComponent?!eh(h,y)||!eh(S,T):!0}function T3(l,u,h){var y=!1,S=Ca,T=u.contextType;return typeof T=="object"&&T!==null?T=Fi(T):(S=Qr(u)?Jl:Tr.current,y=u.contextTypes,T=(y=y!=null)?Du(l,S):Ca),u=new u(h,T),l.memoizedState=u.state!==null&&u.state!==void 0?u.state:null,u.updater=Yg,l.stateNode=u,u._reactInternals=l,y&&(l=l.stateNode,l.__reactInternalMemoizedUnmaskedChildContext=S,l.__reactInternalMemoizedMaskedChildContext=T),u}function R3(l,u,h,y){l=u.state,typeof u.componentWillReceiveProps=="function"&&u.componentWillReceiveProps(h,y),typeof u.UNSAFE_componentWillReceiveProps=="function"&&u.UNSAFE_componentWillReceiveProps(h,y),u.state!==l&&Yg.enqueueReplaceState(u,u.state,null)}function Iw(l,u,h,y){var S=l.stateNode;S.props=h,S.state=l.memoizedState,S.refs={},vw(l);var T=u.contextType;typeof T=="object"&&T!==null?S.context=Fi(T):(T=Qr(u)?Jl:Tr.current,S.context=Du(l,T)),S.state=l.memoizedState,T=u.getDerivedStateFromProps,typeof T=="function"&&(Aw(l,u,T,h),S.state=l.memoizedState),typeof u.getDerivedStateFromProps=="function"||typeof S.getSnapshotBeforeUpdate=="function"||typeof S.UNSAFE_componentWillMount!="function"&&typeof S.componentWillMount!="function"||(u=S.state,typeof S.componentWillMount=="function"&&S.componentWillMount(),typeof S.UNSAFE_componentWillMount=="function"&&S.UNSAFE_componentWillMount(),u!==S.state&&Yg.enqueueReplaceState(S,S.state,null),Bg(l,h,S,y),S.state=l.memoizedState),typeof S.componentDidMount=="function"&&(l.flags|=4194308)}function Bu(l,u){try{var h="",y=u;do h+=te(y),y=y.return;while(y);var S=h}catch(T){S=` 8Error generating stack: `+T.message+` 9`+T.stack}return{value:l,source:u,stack:S,digest:null}}function Mw(l,u,h){return{value:l,source:null,stack:h??null,digest:u??null}}function Dw(l,u){try{console.error(u.value)}catch(h){setTimeout(function(){throw h})}}var EW=typeof WeakMap=="function"?WeakMap:Map;function P3(l,u,h){h=bo(-1,h),h.tag=3,h.payload={element:null};var y=u.value;return h.callback=function(){ny||(ny=!0,Yw=y),Dw(l,u)},h}function O3(l,u,h){h=bo(-1,h),h.tag=3;var y=l.type.getDerivedStateFromError;if(typeof y=="function"){var S=u.value;h.payload=function(){return y(S)},h.callback=function(){Dw(l,u)}}var T=l.stateNode;return T!==null&&typeof T.componentDidCatch=="function"&&(h.callback=function(){Dw(l,u),typeof y!="function"&&(Oa===null?Oa=new Set([this]):Oa.add(this));var $=u.stack;this.componentDidCatch(u.value,{componentStack:$!==null?$:""})}),h}function A3(l,u,h){var y=l.pingCache;if(y===null){y=l.pingCache=new EW;var S=new Set;y.set(u,S)}else S=y.get(u),S===void 0&&(S=new Set,y.set(u,S));S.has(h)||(S.add(h),l=$W.bind(null,l,u,h),u.then(l,l))}function I3(l){do{var u;if((u=l.tag===13)&&(u=l.memoizedState,u=u!==null?u.dehydrated!==null:!0),u)return l;l=l.return}while(l!==null);return null}function M3(l,u,h,y,S){return(l.mode&1)===0?(l===u?l.flags|=65536:(l.flags|=128,h.flags|=131072,h.flags&=-52805,h.tag===1&&(h.alternate===null?h.tag=17:(u=bo(-1,1),u.tag=2,Ra(h,u,1))),h.lanes|=1),l):(l.flags|=65536,l.lanes=S,l)}var xW=F.ReactCurrentOwner,ei=!1;function $r(l,u,h,y){u.child=l===null?QP(u,null,h,y):ju(u,l.child,h,y)}function D3(l,u,h,y,S){h=h.render;var T=u.ref;return Uu(u,S),y=Cw(l,u,h,y,T,S),h=kw(),l!==null&&!ei?(u.updateQueue=l.updateQueue,u.flags&=-2053,l.lanes&=~S,So(l,u,S)):(_n&&h&&lw(u),u.flags|=1,$r(l,u,y,S),u.child)}function L3(l,u,h,y,S){if(l===null){var T=h.type;return typeof T=="function"&&!nb(T)&&T.defaultProps===void 0&&h.compare===null&&h.defaultProps===void 0?(u.tag=15,u.type=T,N3(l,u,T,y,S)):(l=ly(h.type,null,y,u,u.mode,S),l.ref=u.ref,l.return=u,u.child=l)}if(T=l.child,(l.lanes&S)===0){var $=T.memoizedProps;
vendor: 9,669 bytes, line 9
9if(h=h.compare,h=h!==null?h:eh,h($,y)&&l.ref===u.ref)return So(l,u,S)}return u.flags|=1,l=Da(T,y),l.ref=u.ref,l.return=u,u.child=l}function N3(l,u,h,y,S){if(l!==null){var T=l.memoizedProps;if(eh(T,y)&&l.ref===u.ref)if(ei=!1,u.pendingProps=y=T,(l.lanes&S)!==0)(l.flags&131072)!==0&&(ei=!0);else return u.lanes=l.lanes,So(l,u,S)}return Lw(l,u,h,y,S)}function $3(l,u,h){var y=u.pendingProps,S=y.children,T=l!==null?l.memoizedState:null;if(y.mode==="hidden")if((u.mode&1)===0)u.memoizedState={baseLanes:0,cachePool:null,transitions:null},ln(Vu,_i),_i|=h;else{if((h&1073741824)===0)return l=T!==null?T.baseLanes|h:h,u.lanes=u.childLanes=1073741824,u.memoizedState={baseLanes:l,cachePool:null,transitions:null},u.updateQueue=null,ln(Vu,_i),_i|=l,null;u.memoizedState={baseLanes:0,cachePool:null,transitions:null},y=T!==null?T.baseLanes:h,ln(Vu,_i),_i|=y}else T!==null?(y=T.baseLanes|h,u.memoizedState=null):y=h,ln(Vu,_i),_i|=y;return $r(l,u,S,h),u.child}function j3(l,u){var h=u.ref;(l===null&&h!==null||l!==null&&l.ref!==h)&&(u.flags|=512,u.flags|=2097152)}function Lw(l,u,h,y,S){var T=Qr(h)?Jl:Tr.current;return T=Du(u,T),Uu(u,S),h=Cw(l,u,h,y,T,S),y=kw(),l!==null&&!ei?(u.updateQueue=l.updateQueue,u.flags&=-2053,l.lanes&=~S,So(l,u,S)):(_n&&y&&lw(u),u.flags|=1,$r(l,u,h,S),u.child)}function F3(l,u,h,y,S){if(Qr(h)){var T=!0;Mg(u)}else T=!1;if(Uu(u,S),u.stateNode===null)Zg(l,u),T3(u,h,y),Iw(u,h,y,S),y=!0;else if(l===null){var $=u.stateNode,G=u.memoizedProps;$.props=G;var Q=$.context,ue=h.contextType;typeof ue=="object"&&ue!==null?ue=Fi(ue):(ue=Qr(h)?Jl:Tr.current,ue=Du(u,ue));var pe=h.getDerivedStateFromProps,ge=typeof pe=="function"||typeof $.getSnapshotBeforeUpdate=="function";ge||typeof $.UNSAFE_componentWillReceiveProps!="function"&&typeof $.componentWillReceiveProps!="function"||(G!==y||Q!==ue)&&R3(u,$,y,ue),Ta=!1;var he=u.memoizedState;$.state=he,Bg(u,y,$,S),Q=u.memoizedState,G!==y||he!==Q||Xr.current||Ta?(typeof pe=="function"&&(Aw(u,h,pe,y),Q=u.memoizedState),(G=Ta||k3(u,h,G,y,he,Q,ue))?(ge||typeof $.UNSAFE_componentWillMount!="function"&&typeof $.componentWillMount!="function"||(typeof $.componentWillMount=="function"&&$.componentWillMount(),typeof $.UNSAFE_componentWillMount=="function"&&$.UNSAFE_componentWillMount()),typeof $.componentDidMount=="function"&&(u.flags|=4194308)):(typeof $.componentDidMount=="function"&&(u.flags|=4194308),u.memoizedProps=y,u.memoizedState=Q),$.props=y,$.state=Q,$.context=ue,y=G):(typeof $.componentDidMount=="function"&&(u.flags|=4194308),y=!1)}else{$=u.stateNode,t3(l,u),G=u.memoizedProps,ue=u.type===u.elementType?G:cs(u.type,G),$.props=ue,ge=u.pendingProps,he=$.context,Q=h.contextType,typeof Q=="object"&&Q!==null?Q=Fi(Q):(Q=Qr(h)?Jl:Tr.current,Q=Du(u,Q));var Me=h.getDerivedStateFromProps;(pe=typeof Me=="function"||typeof $.getSnapshotBeforeUpdate=="function")||typeof $.UNSAFE_componentWillReceiveProps!="function"&&typeof $.componentWillReceiveProps!="function"||(G!==ge||he!==Q)&&R3(u,$,y,Q),Ta=!1,he=u.memoizedState,$.state=he,Bg(u,y,$,S);var Ne=u.memoizedState;G!==ge||he!==Ne||Xr.current||Ta?(typeof Me=="function"&&(Aw(u,h,Me,y),Ne=u.memoizedState),(ue=Ta||k3(u,h,ue,y,he,Ne,Q)||!1)?(pe||typeof $.UNSAFE_componentWillUpdate!="function"&&typeof $.componentWillUpdate!="function"||(typeof $.componentWillUpdate=="function"&&$.componentWillUpdate(y,Ne,Q),typeof $.UNSAFE_componentWillUpdate=="function"&&$.UNSAFE_componentWillUpdate(y,Ne,Q)),typeof $.componentDidUpdate=="function"&&(u.flags|=4),typeof $.getSnapshotBeforeUpdate=="function"&&(u.flags|=1024)):(typeof $.componentDidUpdate!="function"||G===l.memoizedProps&&he===l.memoizedState||(u.flags|=4),typeof $.getSnapshotBeforeUpdate!="function"||G===l.memoizedProps&&he===l.memoizedState||(u.flags|=1024),u.memoizedProps=y,u.memoizedState=Ne),$.props=y,$.state=Ne,$.context=Q,y=ue):(typeof $.componentDidUpdate!="function"||G===l.memoizedProps&&he===l.memoizedState||(u.flags|=4),typeof $.getSnapshotBeforeUpdate!="function"||G===l.memoizedProps&&he===l.memoizedState||(u.flags|=1024),y=!1)}return Nw(l,u,h,y,T,S)}function Nw(l,u,h,y,S,T){j3(l,u);var $=(u.flags&128)!==0;if(!y&&!$)return S&&VP(u,h,!1),So(l,u,T);y=u.stateNode,xW.current=u;var G=$&&typeof h.getDerivedStateFromError!="function"?null:y.render();return u.flags|=1,l!==null&&$?(u.child=ju(u,l.child,null,T),u.child=ju(u,null,G,T)):$r(l,u,G,T),u.memoizedState=y.state,S&&VP(u,h,!0),u.child}function U3(l){var u=l.stateNode;u.pendingContext?BP(l,u.pendingContext,u.pendingContext!==u.context):u.context&&BP(l,u.context,!1),_w(l,u.containerInfo)}function z3(l,u,h,y,S){return $u(),fw(S),u.flags|=256,$r(l,u,h,y),u.child}var $w={dehydrated:null,treeContext:null,retryLane:0};function jw(l){return{baseLanes:l,cachePool:null,transitions:null}}function B3(l,u,h){var y=u.pendingProps,S=Sn.current,T=!1,$=(u.flags&128)!==0,G;if((G=$)||(G=l!==null&&l.memoizedState===null?!1:(S&2)!==0),G?(T=!0,u.flags&=-129):(l===null||l.memoizedState!==null)&&(S|=1),ln(Sn,S&1),l===null)return dw(u),l=u.memoizedState,l!==null&&(l=l.dehydrated,l!==null)?((u.mode&1)===0?u.lanes=1:l.data==="$!"?u.lanes=8:u.lanes=1073741824,null):($=y.children,l=y.fallback,T?(y=u.mode,T=u.child,$={mode:"hidden",children:$},(y&1)===0&&T!==null?(T.childLanes=0,T.pendingProps=$):T=cy($,y,0,null),l=oc(l,y,h,null),T.return=u,l.return=u,T.sibling=l,u.child=T,u.child.memoizedState=jw(h),u.memoizedState=$w,l):Fw(u,$));if(S=l.memoizedState,S!==null&&(G=S.dehydrated,G!==null))return CW(l,u,$,y,G,S,h);if(T){T=y.fallback,$=u.mode,S=l.child,G=S.sibling;var Q={mode:"hidden",children:y.children};return($&1)===0&&u.child!==S?(y=u.child,y.childLanes=0,y.pendingProps=Q,u.deletions=null):(y=Da(S,Q),y.subtreeFlags=S.subtreeFlags&14680064),G!==null?T=Da(G,T):(T=oc(T,$,h,null),T.flags|=2),T.return=u,y.return=u,y.sibling=T,u.child=y,y=T,T=u.child,$=l.child.memoizedState,$=$===null?jw(h):{baseLanes:$.baseLanes|h,cachePool:null,transitions:$.transitions},T.memoizedState=$,T.childLanes=l.childLanes&~h,u.memoizedState=$w,y}return T=l.child,l=T.sibling,y=Da(T,{mode:"visible",children:y.children}),(u.mode&1)===0&&(y.lanes=h),y.return=u,y.sibling=null,l!==null&&(h=u.deletions,h===null?(u.deletions=[l],u.flags|=16):h.push(l)),u.child=y,u.memoizedState=null,y}function Fw(l,u){return u=cy({mode:"visible",children:u},l.mode,0,null),u.return=l,l.child=u}function Jg(l,u,h,y){return y!==null&&fw(y),ju(u,l.child,null,h),l=Fw(u,u.pendingProps.children),l.flags|=2,u.memoizedState=null,l}function CW(l,u,h,y,S,T,$){if(h)return u.flags&256?(u.flags&=-257,y=Mw(Error(n(422))),Jg(l,u,$,y)):u.memoizedState!==null?(u.child=l.child,u.flags|=128,null):(T=y.fallback,S=u.mode,y=cy({mode:"visible",children:y.children},S,0,null),T=oc(T,S,$,null),T.flags|=2,y.return=u,T.return=u,y.sibling=T,u.child=y,(u.mode&1)!==0&&ju(u,l.child,null,$),u.child.memoizedState=jw($),u.memoizedState=$w,T);if((u.mode&1)===0)return Jg(l,u,$,null);if(S.data==="$!"){if(y=S.nextSibling&&S.nextSibling.dataset,y)var G=y.dgst;return y=G,T=Error(n(419)),y=Mw(T,y,void 0),Jg(l,u,$,y)}if(G=($&l.childLanes)!==0,ei||G){if(y=fr,y!==null){switch($&-$){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&(y.suspendedLanes|$))!==0?0:S,S!==0&&S!==T.retryLane&&(T.retryLane=S,wo(l,S),fs(y,l,S,-1))}return tb(),y=Mw(Error(n(421))),Jg(l,u,$,y)}return S.data==="$?"?(u.flags|=128,u.child=l.child,u=jW.bind(null,l),S._reactRetry=u,null):(l=T.treeContext,vi=Ea(S.nextSibling),yi=u,_n=!0,ls=null,l!==null&&($i[ji++]=vo,$i[ji++]=_o,$i[ji++]=Zl,vo=l.id,_o=l.overflow,Zl=u),u=Fw(u,y.children),u.flags|=4096,u)}function H3(l,u,h){l.lanes|=u;var y=l.alternate;y!==null&&(y.lanes|=u),gw(l.return,u,h)}function Uw(l,u,h,y,S){var T=l.memoizedState;T===null?l.memoizedState={isBackwards:u,rendering:null,renderingStartTime:0,last:y,tail:h,tailMode:S}:(T.isBackwards=u,T.rendering=null,T.renderingStartTime=0,T.last=y,T.tail=h,T.tailMode=S)}function V3(l,u,h){var y=u.pendingProps,S=y.revealOrder,T=y.tail;if($r(l,u,y.children,h),y=Sn.current,(y&2)!==0)y=y&1|2,u.flags|=128;else{if(l!==null&&(l.flags&128)!==0)e:for(l=u.child;l!==null;){if(l.tag===13)l.memoizedState!==null&&H3(l,h,u);else if(l.tag===19)H3(l,h,u);else if(l.child!==null){l.child.return=l,l=l.child;continue}if(l===u)break e;for(;l.sibling===null;){if(l.return===null||l.return===u)break e;l=l.return}l.sibling.return=l.return,l=l.sibling}y&=1}if(ln(Sn,y),(u.mode&1)===0)u.memoizedState=null;else switch(S){case"forwards":for(h=u.child,S=null;h!==null;)l=h.alternate,l!==null&&Hg(l)===null&&(S=h),h=h.sibling;h=S,h===null?(S=u.child,u.child=null):(S=h.sibling,h.sibling=null),Uw(u,!1,S,h,T);break;case"backwards":for(h=null,S=u.child,u.child=null;S!==null;){if(l=S.alternate,l!==null&&Hg(l)===null){u.child=S;break}l=S.sibling,S.sibling=h,h=S,S=l}Uw(u,!0,h,null,T);break;case"together":Uw(u,!1,null,null,void 0);break;default:u.memoizedState=null}return u.child}function Zg(l,u){(u.mode&1)===0&&l!==null&&(l.alternate=null,u.alternate=null,u.flags|=2)}function So(l,u,h){if(l!==null&&(u.dependencies=l.dependencies),nc|=u.lanes,(h&u.childLanes)===0)return null;if(l!==null&&u.child!==l.child)throw Error(n(153));if(u.child!==null){for(l=u.child,h=Da(l,l.pendingProps),u.child=h,h.return=u;l.sibling!==null;)l=l.sibling,h=h.sibling=Da(l,l.pendingProps),h.return=u;h.sibling=null}return u.child}function kW(l,u,h){switch(u.tag){case 3:U3(u),$u();break;case 5:i3(u);break;case 1:Qr(u.type)&&Mg(u);break;case 4:_w(u,u.stateNode.containerInfo);break;
vendor: 5,145 bytes, line 9
9case 10:var y=u.type._context,S=u.memoizedProps.value;ln(Fg,y._currentValue),y._currentValue=S;break;case 13:if(y=u.memoizedState,y!==null)return y.dehydrated!==null?(ln(Sn,Sn.current&1),u.flags|=128,null):(h&u.child.childLanes)!==0?B3(l,u,h):(ln(Sn,Sn.current&1),l=So(l,u,h),l!==null?l.sibling:null);ln(Sn,Sn.current&1);break;case 19:if(y=(h&u.childLanes)!==0,(l.flags&128)!==0){if(y)return V3(l,u,h);u.flags|=128}if(S=u.memoizedState,S!==null&&(S.rendering=null,S.tail=null,S.lastEffect=null),ln(Sn,Sn.current),y)break;return null;case 22:case 23:return u.lanes=0,$3(l,u,h)}return So(l,u,h)}var W3,zw,q3,K3;W3=function(l,u){for(var h=u.child;h!==null;){if(h.tag===5||h.tag===6)l.appendChild(h.stateNode);else if(h.tag!==4&&h.child!==null){h.child.return=h,h=h.child;continue}if(h===u)break;for(;h.sibling===null;){if(h.return===null||h.return===u)return;h=h.return}h.sibling.return=h.return,h=h.sibling}},zw=function(){},q3=function(l,u,h,y){var S=l.memoizedProps;if(S!==y){l=u.stateNode,ec(js.current);var T=null;switch(h){case"input":S=Qe(l,S),y=Qe(l,y),T=[];break;case"select":S=E({},S,{value:void 0}),y=E({},y,{value:void 0}),T=[];break;case"textarea":S=ot(l,S),y=ot(l,y),T=[];break;default:typeof S.onClick!="function"&&typeof y.onClick=="function"&&(l.onclick=Og)}Su(h,y);var $;h=null;for(ue in S)if(!y.hasOwnProperty(ue)&&S.hasOwnProperty(ue)&&S[ue]!=null)if(ue==="style"){var G=S[ue];for($ in G)G.hasOwnProperty($)&&(h||(h={}),h[$]="")}else ue!=="dangerouslySetInnerHTML"&&ue!=="children"&&ue!=="suppressContentEditableWarning"&&ue!=="suppressHydrationWarning"&&ue!=="autoFocus"&&(i.hasOwnProperty(ue)?T||(T=[]):(T=T||[]).push(ue,null));for(ue in y){var Q=y[ue];if(G=S?.[ue],y.hasOwnProperty(ue)&&Q!==G&&(Q!=null||G!=null))if(ue==="style")if(G){for($ in G)!G.hasOwnProperty($)||Q&&Q.hasOwnProperty($)||(h||(h={}),h[$]="");for($ in Q)Q.hasOwnProperty($)&&G[$]!==Q[$]&&(h||(h={}),h[$]=Q[$])}else h||(T||(T=[]),T.push(ue,h)),h=Q;else ue==="dangerouslySetInnerHTML"?(Q=Q?Q.__html:void 0,G=G?G.__html:void 0,Q!=null&&G!==Q&&(T=T||[]).push(ue,Q)):ue==="children"?typeof Q!="string"&&typeof Q!="number"||(T=T||[]).push(ue,""+Q):ue!=="suppressContentEditableWarning"&&ue!=="suppressHydrationWarning"&&(i.hasOwnProperty(ue)?(Q!=null&&ue==="onScroll"&&fn("scroll",l),T||G===Q||(T=[])):(T=T||[]).push(ue,Q))}h&&(T=T||[]).push("style",h);var ue=T;(u.updateQueue=ue)&&(u.flags|=4)}},K3=function(l,u,h,y){h!==y&&(u.flags|=4)};function mh(l,u){if(!_n)switch(l.tailMode){case"hidden":u=l.tail;for(var h=null;u!==null;)u.alternate!==null&&(h=u),u=u.sibling;h===null?l.tail=null:h.sibling=null;break;case"collapsed":h=l.tail;for(var y=null;h!==null;)h.alternate!==null&&(y=h),h=h.sibling;y===null?u||l.tail===null?l.tail=null:l.tail.sibling=null:y.sibling=null}}function Pr(l){var u=l.alternate!==null&&l.alternate.child===l.child,h=0,y=0;if(u)for(var S=l.child;S!==null;)h|=S.lanes|S.childLanes,y|=S.subtreeFlags&14680064,y|=S.flags&14680064,S.return=l,S=S.sibling;else for(S=l.child;S!==null;)h|=S.lanes|S.childLanes,y|=S.subtreeFlags,y|=S.flags,S.return=l,S=S.sibling;return l.subtreeFlags|=y,l.childLanes=h,u}function TW(l,u,h){var y=u.pendingProps;switch(cw(u),u.tag){case 2:case 16:case 15:case 0:case 11:case 7:case 8:case 12:case 9:case 14:return Pr(u),null;case 1:return Qr(u.type)&&Ig(),Pr(u),null;case 3:return y=u.stateNode,zu(),hn(Xr),hn(Tr),Sw(),y.pendingContext&&(y.context=y.pendingContext,y.pendingContext=null),(l===null||l.child===null)&&($g(u)?u.flags|=4:l===null||l.memoizedState.isDehydrated&&(u.flags&256)===0||(u.flags|=1024,ls!==null&&(Xw(ls),ls=null))),zw(l,u),Pr(u),null;case 5:ww(u);var S=ec(uh.current);if(h=u.type,l!==null&&u.stateNode!=null)q3(l,u,h,y,S),l.ref!==u.ref&&(u.flags|=512,u.flags|=2097152);else{if(!y){if(u.stateNode===null)throw Error(n(166));return Pr(u),null}if(l=ec(js.current),$g(u)){y=u.stateNode,h=u.type;var T=u.memoizedProps;switch(y[$s]=u,y[sh]=T,l=(u.mode&1)!==0,h){case"dialog":fn("cancel",y),fn("close",y);break;case"iframe":case"object":case"embed":fn("load",y);break;case"video":case"audio":for(S=0;S<nh.length;S++)fn(nh[S],y);break;case"source":fn("error",y);break;case"img":case"image":case"link":fn("error",y),fn("load",y);break;case"details":fn("toggle",y);break;case"input":ht(y,T),fn("invalid",y);break;case"select":y._wrapperState={wasMultiple:!!T.multiple},fn("invalid",y);break;case"textarea":on(y,T),fn("invalid",y)}Su(h,T),S=null;for(var $ in T)if(T.hasOwnProperty($)){var G=T[$];$==="children"?typeof G=="string"?y.textContent!==G&&(T.suppressHydrationWarning!==!0&&Pg(y.textContent,G,l),S=["children",G]):typeof G=="number"&&y.textContent!==""+G&&(T.suppressHydrationWarning!==!0&&Pg(y.textContent,G,l),S=["children",""+G]):i.hasOwnProperty($)&&G!=null&&$==="onScroll"&&fn("scroll",y)}switch(h){case"input":rt(y),Yt(y,T,!0);break;case"textarea":rt(y),Un(y);break;case"select":case"option":break;default:typeof T.onClick=="function"&&(y.onclick=Og)}y=S,u.updateQueue=y,y!==null&&(u.flags|=4)}else{$=S.nodeType===9?S:S.ownerDocument,l==="http://www.w3.org/1999/xhtml"&&(l=zl(h)),l==="http://www.w3.org/1999/xhtml"?h==="script"?(l=$.createElement("div"),l.innerHTML="<script><\/script>
9",l=l.removeChild(l.firstChild)):typeof y.is=="string"?l=$.createElement(h,{is:y.is}):(l=$.createElement(h),h==="select"&&($=l,y.multiple?$.multiple=!0:y.size&&($.size=y.size))):l=$.createElementNS(l,h),l[$s]=u,l[sh]=y,W3(l,u,!1,!1),u.stateNode=l;e:{switch($=Eu(h,y),h){case"dialog":fn("cancel",l),fn("close",l),S=y;break;case"iframe":case"object":case"embed":fn("load",l),S=y;break;case"video":case"audio":for(S=0;S<nh.length;S++)fn(nh[S],l);S=y;break;case"source":fn("error",l),S=y;break;case"img":case"image":case"link":fn("error",l),fn("load",l),S=y;break;case"details":fn("toggle",l),S=y;break;case"input":ht(l,y),S=Qe(l,y),fn("invalid",l);break;case"option":S=y;break;case"select":l._wrapperState={wasMultiple:!!y.multiple},S=E({},y,{value:void 0}),fn("invalid",l);break;case"textarea":on(l,y),S=ot(l,y),fn("invalid",l);break;default:S=y}Su(h,S),G=S;for(T in G)if(G.hasOwnProperty(T)){var Q=G[T];T==="style"?Li(l,Q):T==="dangerouslySetInnerHTML"?(Q=Q?Q.__html:void 0,Q!=null&&Di(l,Q)):T==="children"?typeof Q=="string"?(h!=="textarea"||Q!=="")&&fa(l,Q):typeof Q=="number"&&fa(l,""+Q):T!=="suppressContentEditableWarning"&&T!=="suppressHydrationWarning"&&T!=="autoFocus"&&(i.hasOwnProperty(T)?Q!=null&&T==="onScroll"&&fn("scroll",l):Q!=null&&D(l,T,Q,$))}switch(h){case"input":rt(l),Yt(l,y,!1);break;case"textarea":rt(l),Un(l);break;case"option":y.value!=null&&l.setAttribute("value",""+ye(y.value));break;case"select":l.multiple=!!y.multiple,T=y.value,T!=null?jt(l,!!y.multiple,T,!1):y.defaultValue!=null&&jt(l,!!y.multiple,y.defaultValue,!0);break;default:typeof S.onClick=="function"&&(l.onclick=Og)}switch(h){case"button":case"input":case"select":case"textarea":y=!!y.autoFocus;break e;case"img":y=!0;break e;default:y=!1}}y&&(u.flags|=4)}u.ref!==null&&(u.flags|=512,u.flags|=2097152)}return Pr(u),null;case 6:if(l&&u.stateNode!=null)K3(l,u,l.memoizedProps,y);else{if(typeof y!="string"&&u.stateNode===null)throw Error(n(166));if(h=ec(uh.current),ec(js.current),$g(u)){if(y=u.stateNode,h=u.memoizedProps,y[$s]=u,(T=y.nodeValue!==h)&&(l=yi,l!==null))switch(l.tag){case 3:Pg(y.nodeValue,h,(l.mode&1)!==0);break;case 5:l.memoizedProps.suppressHydrationWarning!==!0&&Pg(y.nodeValue,h,(l.mode&1)!==0)}T&&(u.flags|=4)}else y=(h.nodeType===9?h:h.ownerDocument).createTextNode(y),y[$s]=u,u.stateNode=y}return Pr(u),null;case 13:if(hn(Sn),y=u.memoizedState,l===null||l.memoizedState!==null&&l.memoizedState.dehydrated!==null){if(_n&&vi!==null&&(u.mode&1)!==0&&(u.flags&128)===0)JP(),$u(),u.flags|=98560,T=!1;else if(T=$g(u),y!==null&&y.dehydrated!==null){if(l===null){if(!T)throw Error(n(318));if(T=u.memoizedState,T=T!==null?T.dehydrated:null,!T)throw Error(n(317));T[$s]=u}else $u(),(u.flags&128)===0&&(u.memoizedState=null),u.flags|=4;Pr(u),T=!1}else ls!==null&&(Xw(ls),ls=null),T=!0;if(!T)return u.flags&65536?u:null}return(u.flags&128)!==0?(u.lanes=h,u):(y=y!==null,y!==(l!==null&&l.memoizedState!==null)&&y&&(u.child.flags|=8192,(u.mode&1)!==0&&(l===null||(Sn.current&1)!==0?tr===0&&(tr=3):tb())),u.updateQueue!==null&&(u.flags|=4),Pr(u),null);case 4:return zu(),zw(l,u),l===null&&rh(u.stateNode.containerInfo),Pr(u),null;case 10:return mw(u.type._context),Pr(u),null;case 17:return Qr(u.type)&&Ig(),Pr(u),null;case 19:if(hn(Sn),T=u.memoizedState,T===null)return Pr(u),null;if(y=(u.flags&128)!==0,$=T.rendering,$===null)if(y)mh(T,!1);else{if(tr!==0||l!==null&&(l.flags&128)!==0)for(l=u.child;l!==null;){if($=Hg(l),$!==null){for(u.flags|=128,mh(T,!1),y=$.updateQueue,y!==null&&(u.updateQueue=y,u.flags|=4),u.subtreeFlags=0,y=h,h=u.child;h!==null;)T=h,l=y,T.flags&=14680066,$=T.alternate,$===null?(T.childLanes=0,T.lanes=l,T.child=null,T.subtreeFlags=0,T.memoizedProps=null,T.memoizedState=null,T.updateQueue=null,T.dependencies=null,T.stateNode=null):(T.childLanes=$.childLanes,T.lanes=$.lanes,T.child=$.child,T.subtreeFlags=0,T.deletions=null,T.memoizedProps=$.memoizedProps,T.memoizedState=$.memoizedState,T.updateQueue=$.updateQueue,T.type=$.type,l=$.dependencies,T.dependencies=l===null?null:{lanes:l.lanes,firstContext:l.firstContext}),h=h.sibling;return ln(Sn,Sn.current&1|2),u.child}l=l.sibling}T.tail!==null&&Qt()>Wu&&(u.flags|=128,y=!0,mh(T,!1),u.lanes=4194304)}else{if(!y)if(l=Hg($),l!==null){if(u.flags|=128,y=!0,h=l.updateQueue,h!==null&&(u.updateQueue=h,u.flags|=4),mh(T,!0),T.tail===null&&T.tailMode==="hidden"&&!$.alternate&&!_n
vendor: 20,056 bytes, line 9
9)return Pr(u),null}else 2*Qt()-T.renderingStartTime>Wu&&h!==1073741824&&(u.flags|=128,y=!0,mh(T,!1),u.lanes=4194304);T.isBackwards?($.sibling=u.child,u.child=$):(h=T.last,h!==null?h.sibling=$:u.child=$,T.last=$)}return T.tail!==null?(u=T.tail,T.rendering=u,T.tail=u.sibling,T.renderingStartTime=Qt(),u.sibling=null,h=Sn.current,ln(Sn,y?h&1|2:h&1),u):(Pr(u),null);case 22:case 23:return eb(),y=u.memoizedState!==null,l!==null&&l.memoizedState!==null!==y&&(u.flags|=8192),y&&(u.mode&1)!==0?(_i&1073741824)!==0&&(Pr(u),u.subtreeFlags&6&&(u.flags|=8192)):Pr(u),null;case 24:return null;case 25:return null}throw Error(n(156,u.tag))}function RW(l,u){switch(cw(u),u.tag){case 1:return Qr(u.type)&&Ig(),l=u.flags,l&65536?(u.flags=l&-65537|128,u):null;case 3:return zu(),hn(Xr),hn(Tr),Sw(),l=u.flags,(l&65536)!==0&&(l&128)===0?(u.flags=l&-65537|128,u):null;case 5:return ww(u),null;case 13:if(hn(Sn),l=u.memoizedState,l!==null&&l.dehydrated!==null){if(u.alternate===null)throw Error(n(340));$u()}return l=u.flags,l&65536?(u.flags=l&-65537|128,u):null;case 19:return hn(Sn),null;case 4:return zu(),null;case 10:return mw(u.type._context),null;case 22:case 23:return eb(),null;case 24:return null;default:return null}}var Xg=!1,Or=!1,PW=typeof WeakSet=="function"?WeakSet:Set,Le=null;function Hu(l,u){var h=l.ref;if(h!==null)if(typeof h=="function")try{h(null)}catch(y){Rn(l,u,y)}else h.current=null}function Bw(l,u,h){try{h()}catch(y){Rn(l,u,y)}}var G3=!1;function OW(l,u){if(ew=vg,l=kP(),q1(l)){if("selectionStart"in l)var h={start:l.selectionStart,end:l.selectionEnd};else e:{h=(h=l.ownerDocument)&&h.defaultView||window;var y=h.getSelection&&h.getSelection();if(y&&y.rangeCount!==0){h=y.anchorNode;var S=y.anchorOffset,T=y.focusNode;y=y.focusOffset;try{h.nodeType,T.nodeType}catch{h=null;break e}var $=0,G=-1,Q=-1,ue=0,pe=0,ge=l,he=null;t:for(;;){for(var Me;ge!==h||S!==0&&ge.nodeType!==3||(G=$+S),ge!==T||y!==0&&ge.nodeType!==3||(Q=$+y),ge.nodeType===3&&($+=ge.nodeValue.length),(Me=ge.firstChild)!==null;)he=ge,ge=Me;for(;;){if(ge===l)break t;if(he===h&&++ue===S&&(G=$),he===T&&++pe===y&&(Q=$),(Me=ge.nextSibling)!==null)break;ge=he,he=ge.parentNode}ge=Me}h=G===-1||Q===-1?null:{start:G,end:Q}}else h=null}h=h||{start:0,end:0}}else h=null;for(tw={focusedElem:l,selectionRange:h},vg=!1,Le=u;Le!==null;)if(u=Le,l=u.child,(u.subtreeFlags&1028)!==0&&l!==null)l.return=u,Le=l;else for(;Le!==null;){u=Le;try{var Ne=u.alternate;if((u.flags&1024)!==0)switch(u.tag){case 0:case 11:case 15:break;case 1:if(Ne!==null){var ze=Ne.memoizedProps,Nn=Ne.memoizedState,ie=u.stateNode,ee=ie.getSnapshotBeforeUpdate(u.elementType===u.type?ze:cs(u.type,ze),Nn);ie.__reactInternalSnapshotBeforeUpdate=ee}break;case 3:var ae=u.stateNode.containerInfo;ae.nodeType===1?ae.textContent="":ae.nodeType===9&&ae.documentElement&&ae.removeChild(ae.documentElement);break;case 5:case 6:case 4:case 17:break;default:throw Error(n(163))}}catch(_e){Rn(u,u.return,_e)}if(l=u.sibling,l!==null){l.return=u.return,Le=l;break}Le=u.return}return Ne=G3,G3=!1,Ne}function gh(l,u,h){var y=u.updateQueue;if(y=y!==null?y.lastEffect:null,y!==null){var S=y=y.next;do{if((S.tag&l)===l){var T=S.destroy;S.destroy=void 0,T!==void 0&&Bw(u,h,T)}S=S.next}while(S!==y)}}function Qg(l,u){if(u=u.updateQueue,u=u!==null?u.lastEffect:null,u!==null){var h=u=u.next;do{if((h.tag&l)===l){var y=h.create;h.destroy=y()}h=h.next}while(h!==u)}}function Hw(l){var u=l.ref;if(u!==null){var h=l.stateNode;switch(l.tag){case 5:l=h;break;default:l=h}typeof u=="function"?u(l):u.current=l}}function Y3(l){var u=l.alternate;u!==null&&(l.alternate=null,Y3(u)),l.child=null,l.deletions=null,l.sibling=null,l.tag===5&&(u=l.stateNode,u!==null&&(delete u[$s],delete u[sh],delete u[sw],delete u[fW],delete u[hW])),l.stateNode=null,l.return=null,l.dependencies=null,l.memoizedProps=null,l.memoizedState=null,l.pendingProps=null,l.stateNode=null,l.updateQueue=null}function J3(l){return l.tag===5||l.tag===3||l.tag===4}function Z3(l){e:for(;;){for(;l.sibling===null;){if(l.return===null||J3(l.return))return null;l=l.return}for(l.sibling.return=l.return,l=l.sibling;l.tag!==5&&l.tag!==6&&l.tag!==18;){if(l.flags&2||l.child===null||l.tag===4)continue e;l.child.return=l,l=l.child}if(!(l.flags&2))return l.stateNode}}function Vw(l,u,h){var y=l.tag;if(y===5||y===6)l=l.stateNode,u?h.nodeType===8?h.parentNode.insertBefore(l,u):h.insertBefore(l,u):(h.nodeType===8?(u=h.parentNode,u.insertBefore(l,h)):(u=h,u.appendChild(l)),h=h._reactRootContainer,h!=null||u.onclick!==null||(u.onclick=Og));else if(y!==4&&(l=l.child,l!==null))for(Vw(l,u,h),l=l.sibling;l!==null;)Vw(l,u,h),l=l.sibling}function Ww(l,u,h){var y=l.tag;if(y===5||y===6)l=l.stateNode,u?h.insertBefore(l,u):h.appendChild(l);else if(y!==4&&(l=l.child,l!==null))for(Ww(l,u,h),l=l.sibling;l!==null;)Ww(l,u,h),l=l.sibling}var vr=null,us=!1;function Pa(l,u,h){for(h=h.child;h!==null;)X3(l,u,h),h=h.sibling}function X3(l,u,h){if(Nr&&typeof Nr.onCommitFiberUnmount=="function")try{Nr.onCommitFiberUnmount(ho,h)}catch{}switch(h.tag){case 5:Or||Hu(h,u);case 6:var y=vr,S=us;vr=null,Pa(l,u,h),vr=y,us=S,vr!==null&&(us?(l=vr,h=h.stateNode,l.nodeType===8?l.parentNode.removeChild(h):l.removeChild(h)):vr.removeChild(h.stateNode));break;case 18:vr!==null&&(us?(l=vr,h=h.stateNode,l.nodeType===8?iw(l.parentNode,h):l.nodeType===1&&iw(l,h),Gf(l)):iw(vr,h.stateNode));break;case 4:y=vr,S=us,vr=h.stateNode.containerInfo,us=!0,Pa(l,u,h),vr=y,us=S;break;case 0:case 11:case 14:case 15:if(!Or&&(y=h.updateQueue,y!==null&&(y=y.lastEffect,y!==null))){S=y=y.next;do{var T=S,$=T.destroy;T=T.tag,$!==void 0&&((T&2)!==0||(T&4)!==0)&&Bw(h,u,$),S=S.next}while(S!==y)}Pa(l,u,h);break;case 1:if(!Or&&(Hu(h,u),y=h.stateNode,typeof y.componentWillUnmount=="function"))try{y.props=h.memoizedProps,y.state=h.memoizedState,y.componentWillUnmount()}catch(G){Rn(h,u,G)}Pa(l,u,h);break;case 21:Pa(l,u,h);break;case 22:h.mode&1?(Or=(y=Or)||h.memoizedState!==null,Pa(l,u,h),Or=y):Pa(l,u,h);break;default:Pa(l,u,h)}}function Q3(l){var u=l.updateQueue;if(u!==null){l.updateQueue=null;var h=l.stateNode;h===null&&(h=l.stateNode=new PW),u.forEach(function(y){var S=FW.bind(null,l,y);h.has(y)||(h.add(y),y.then(S,S))})}}function ds(l,u){var h=u.deletions;if(h!==null)for(var y=0;y<h.length;y++){var S=h[y];try{var T=l,$=u,G=$;e:for(;G!==null;){switch(G.tag){case 5:vr=G.stateNode,us=!1;break e;case 3:vr=G.stateNode.containerInfo,us=!0;break e;case 4:vr=G.stateNode.containerInfo,us=!0;break e}G=G.return}if(vr===null)throw Error(n(160));X3(T,$,S),vr=null,us=!1;var Q=S.alternate;Q!==null&&(Q.return=null),S.return=null}catch(ue){Rn(S,u,ue)}}if(u.subtreeFlags&12854)for(u=u.child;u!==null;)eO(u,l),u=u.sibling}function eO(l,u){var h=l.alternate,y=l.flags;switch(l.tag){case 0:case 11:case 14:case 15:if(ds(u,l),Us(l),y&4){try{gh(3,l,l.return),Qg(3,l)}catch(ze){Rn(l,l.return,ze)}try{gh(5,l,l.return)}catch(ze){Rn(l,l.return,ze)}}break;case 1:ds(u,l),Us(l),y&512&&h!==null&&Hu(h,h.return);break;case 5:if(ds(u,l),Us(l),y&512&&h!==null&&Hu(h,h.return),l.flags&32){var S=l.stateNode;try{fa(S,"")}catch(ze){Rn(l,l.return,ze)}}if(y&4&&(S=l.stateNode,S!=null)){var T=l.memoizedProps,$=h!==null?h.memoizedProps:T,G=l.type,Q=l.updateQueue;if(l.updateQueue=null,Q!==null)try{G==="input"&&T.type==="radio"&&T.name!=null&&Rt(S,T),Eu(G,$);var ue=Eu(G,T);for($=0;$<Q.length;$+=2){var pe=Q[$],ge=Q[$+1];pe==="style"?Li(S,ge):pe==="dangerouslySetInnerHTML"?Di(S,ge):pe==="children"?fa(S,ge):D(S,pe,ge,ue)}switch(G){case"input":it(S,T);break;case"textarea":yt(S,T);break;case"select":var he=S._wrapperState.wasMultiple;S._wrapperState.wasMultiple=!!T.multiple;var Me=T.value;Me!=null?jt(S,!!T.multiple,Me,!1):he!==!!T.multiple&&(T.defaultValue!=null?jt(S,!!T.multiple,T.defaultValue,!0):jt(S,!!T.multiple,T.multiple?[]:"",!1))}S[sh]=T}catch(ze){Rn(l,l.return,ze)}}break;case 6:if(ds(u,l),Us(l),y&4){if(l.stateNode===null)throw Error(n(162));S=l.stateNode,T=l.memoizedProps;try{S.nodeValue=T}catch(ze){Rn(l,l.return,ze)}}break;case 3:if(ds(u,l),Us(l),y&4&&h!==null&&h.memoizedState.isDehydrated)try{Gf(u.containerInfo)}catch(ze){Rn(l,l.return,ze)}break;case 4:ds(u,l),Us(l);break;case 13:ds(u,l),Us(l),S=l.child,S.flags&8192&&(T=S.memoizedState!==null,S.stateNode.isHidden=T,!T||S.alternate!==null&&S.alternate.memoizedState!==null||(Gw=Qt())),y&4&&Q3(l);break;case 22:if(pe=h!==null&&h.memoizedState!==null,l.mode&1?(Or=(ue=Or)||pe,ds(u,l),Or=ue):ds(u,l),Us(l),y&8192){if(ue=l.memoizedState!==null,(l.stateNode.isHidden=ue)&&!pe&&(l.mode&1)!==0)for(Le=l,pe=l.child;pe!==null;){for(ge=Le=pe;Le!==null;){switch(he=Le,Me=he.child,he.tag){case 0:case 11:case 14:case 15:gh(4,he,he.return);break;case 1:Hu(he,he.return);var Ne=he.stateNode;if(typeof Ne.componentWillUnmount=="function"){y=he,h=he.return;try{u=y,Ne.props=u.memoizedProps,Ne.state=u.memoizedState,Ne.componentWillUnmount()}catch(ze){Rn(y,h,ze)}}break;case 5:Hu(he,he.return);break;case 22:if(he.memoizedState!==null){rO(ge);continue}}Me!==null?(Me.return=he,Le=Me):rO(ge)}pe=pe.sibling}e:for(pe=null,ge=l;;){if(ge.tag===5){if(pe===null){pe=ge;try{S=ge.stateNode,ue?(T=S.style,typeof T.setProperty=="function"?T.setProperty("display","none","important"):T.display="none"):(G=ge.stateNode,Q=ge.memoizedProps.style,$=Q!=null&&Q.hasOwnProperty("display")?Q.display:null,G.style.display=dg("display",$))}catch(ze){Rn(l,l.return,ze)}}}else if(ge.tag===6){if(pe===null)try{ge.stateNode.nodeValue=ue?"":ge.memoizedProps}catch(ze){Rn(l,l.return,ze)}}else if((ge.tag!==22&&ge.tag!==23||ge.memoizedState===null||ge===l)&&ge.child!==null){ge.child.return=ge,ge=ge.child;continue}if(ge===l)break e;for(;ge.sibling===null;){if(ge.return===null||ge.return===l)break e;pe===ge&&(pe=null),ge=ge.return}pe===ge&&(pe=null),ge.sibling.return=ge.return,ge=ge.sibling}}break;case 19:ds(u,l),Us(l),y&4&&Q3(l);break;case 21:break;default:ds(u,l),Us(l)}}function Us(l){var u=l.flags;if(u&2){try{e:{for(var h=l.return;h!==null;){if(J3(h)){var y=h;break e}h=h.return}throw Error(n(160))}switch(y.tag){case 5:var S=y.stateNode;y.flags&32&&(fa(S,""),y.flags&=-33);var T=Z3(l);Ww(l,T,S);break;case 3:case 4:var $=y.stateNode.containerInfo,G=Z3(l);Vw(l,G,$);break;default:throw Error(n(161))}}catch(Q){Rn(l,l.return,Q)}l.flags&=-3}u&4096&&(l.flags&=-4097)}function AW(l,u,h){Le=l,tO(l)}function tO(l,u,h){for(var y=(l.mode&1)!==0;Le!==null;){var S=Le,T=S.child;if(S.tag===22&&y){var $=S.memoizedState!==null||Xg;if(!$){var G=S.alternate,Q=G!==null&&G.memoizedState!==null||Or;G=Xg;var ue=Or;if(Xg=$,(Or=Q)&&!ue)for(Le=S;Le!==null;)$=Le,Q=$.child,$.tag===22&&$.memoizedState!==null?iO(S):Q!==null?(Q.return=$,Le=Q):iO(S);for(;T!==null;)Le=T,tO(T),T=T.sibling;Le=S,Xg=G,Or=ue}nO(l)}else(S.subtreeFlags&8772)!==0&&T!==null?(T.return=S,Le=T):nO(l)}}function nO(l){for(;Le!==null;){var u=Le;if((u.flags&8772)!==0){var h=u.alternate;try{if((u.flags&8772)!==0)switch(u.tag){case 0:case 11:case 15:Or||Qg(5,u);break;case 1:var y=u.stateNode;if(u.flags&4&&!Or)if(h===null)y.componentDidMount();else{var S=u.elementType===u.type?h.memoizedProps:cs(u.type,h.memoizedProps);y.componentDidUpdate(S,h.memoizedState,y.__reactInternalSnapshotBeforeUpdate)}var T=u.updateQueue;T!==null&&r3(u,T,y);break;case 3:var $=u.updateQueue;if($!==null){if(h=null,u.child!==null)switch(u.child.tag){case 5:h=u.child.stateNode;break;case 1:h=u.child.stateNode}r3(u,$,h)}break;case 5:var G=u.stateNode;if(h===null&&u.flags&4){h=G;var Q=u.memoizedProps;switch(u.type){case"button":case"input":case"select":case"textarea":Q.autoFocus&&h.focus();break;case"img":Q.src&&(h.src=Q.src)}}break;case 6:break;case 4:break;case 12:break;case 13:if(u.memoizedState===null){var ue=u.alternate;if(ue!==null){var pe=ue.memoizedState;if(pe!==null){var ge=pe.dehydrated;ge!==null&&Gf(ge)}}}break;case 19:case 17:case 21:case 22:case 23:case 25:break;default:throw Error(n(163))}Or||u.flags&512&&Hw(u)}catch(he){Rn(u,u.return,he)}}if(u===l){Le=null;break}if(h=u.sibling,h!==null){h.return=u.return,Le=h;break}Le=u.return}}function rO(l){for(;Le!==null;){var u=Le;if(u===l){Le=null;break}var h=u.sibling;if(h!==null){h.return=u.return,Le=h;break}Le=u.return}}function iO(l){for(;Le!==null;){var u=Le;try{switch(u.tag){case 0:case 11:case 15:var h=u.return;try{Qg(4,u)}catch(Q){Rn(u,h,Q)}break;case 1:var y=u.stateNode;if(typeof y.componentDidMount=="function"){var S=u.return;try{y.componentDidMount()}catch(Q){Rn(u,S,Q)}}var T=u.return;try{Hw(u)}catch(Q){Rn(u,T,Q)}break;case 5:var $=u.return;try{Hw(u)}catch(Q){Rn(u,$,Q)}}}catch(Q){Rn(u,u.return,Q)}if(u===l){Le=null;break}var G=u.sibling;if(G!==null){G.return=u.return,Le=G;break}Le=u.return}}var IW=Math.ceil,ey=F.ReactCurrentDispatcher,qw=F.ReactCurrentOwner,zi=F.ReactCurrentBatchConfig,Ht=0,fr=null,Hn=null,_r=0,_i=0,Vu=xa(0),tr=0,yh=null,nc=0,ty=0,Kw=0,vh=null,ti=null,Gw=0,Wu=1/0,Eo=null,ny=!1,Yw=null,Oa=null,ry=!1,Aa=null,iy=0,_h=0,Jw=null,sy=-1,oy=0;function jr(){return(Ht&6)!==0?Qt():sy!==-1?sy:sy=Qt()}function Ia(l){return(l.mode&1)===0?1:(Ht&2)!==0&&_r!==0?_r&-_r:mW.transition!==null?(oy===0&&(oy=ZR()),oy):(l=en,l!==0||(l=window.event,l=l===void 0?16:oP(l.type)),l)}function fs(l,u,h,y){if(50<_h)throw _h=0,Jw=null,Error(n(185));Hf(l,h,y),((Ht&2)===0||l!==fr)&&(l===fr&&((Ht&2)===0&&(ty|=h),tr===4&&Ma(l,_r)),ni(l,y),h===1&&Ht===0&&(u.mode&1)===0&&(Wu=Qt()+500,Dg&&ka()))}function ni(l,u){var h=l.callbackNode;mV(l,u);var y=mg(l,l===fr?_r:0);if(y===0)h!==null&&ur(h),l.callbackNode=null,l.callbackPriority=0;else if(u=y&-y,l.callbackPriority!==u){if(h!=null&&ur(h),u===1)l.tag===0?pW(oO.bind(null,l)):WP(oO.bind(null,l)),uW(function(){(Ht&6)===0&&ka()}),h=null;else{switch(XR(y)){case 1:h=Ni;break;case 4:h=mi;break;case 16:h=ma;break;case 536870912:h=Ns;break;default:h=ma}h=pO(h,sO.bind(null,l))}l.callbackPriority=u,l.callbackNode=h}}function sO(l,u){if(sy=-1,oy=0,(Ht&6)!==0)throw Error(n(327));var h=l.callbackNode;if(qu()&&l.callbackNode!==h)return null;var y=mg(l,l===fr?_r:0);if(y===0)return null;if((y&30)!==0||(y&l.expiredLanes)!==0||u)u=ay(l,y);else{u=y;var S=Ht;Ht|=2;var T=lO();(fr!==l||_r!==u)&&(Eo=null,Wu=Qt()+500,ic(l,u));do try{LW();break}catch(G){aO(l,G)}while(!0);pw(),ey.current=T,Ht=S,Hn!==null?u=0:(fr=null,_r=0,u=tr)}if(u!==0){if(u===2&&(S=O1(l),S!==0&&(y=S,u=Zw(l,S))),u===1)throw h=yh,ic(l,0),Ma(l,y),ni(l,Qt()),h;if(u===6)Ma(l,y);else{if(S=l.current.alternate,(y&30)===0&&!MW(S)&&(u=ay(l,y),u===2&&(T=O1(l),T!==0&&(y=T,u=Zw(l,T))),u===1))throw h=yh,ic(l,0),Ma(l,y),ni(l,Qt()),h;switch(l.finishedWork=S,l.finishedLanes=y,u){case 0:case 1:throw Error(n(345));case 2:sc(l,ti,Eo);break;case 3:if(Ma(l,y),(y&130023424)===y&&(u=Gw+500-Qt(),10<u)){if(mg(l,0)!==0)break;if(S=l.suspendedLanes,(S&y)!==y){jr(),l.pingedLanes|=l.suspendedLanes&S;break}l.timeoutHandle=rw(sc.bind(null,l,ti,Eo),u);break}sc(l,ti,Eo);break;case 4:if(Ma(l,y),(y&4194240)===y)break;for(u=l.eventTimes,S=-1;0<y;){var $=31-nn(y);T=1<<$,$=u[$],$>S&&(S=$),y&=~T}if(y=S,y=Qt()-y,y=(120>y?120:480>y?480:1080>y?1080:1920>y?1920:3e3>y?3e3:4320>y?4320:1960*IW(y/1960))-y,10<y){l.timeoutHandle=rw(sc.bind(null,l,ti,Eo),y);break}sc(l,ti,Eo);break;case 5:sc(l,ti,Eo);break;default:throw Error(n(329))}}}return ni(l,Qt()),l.callbackNode===h?sO.bind(null,l):null}function Zw(l,u){var h=vh;return l.current.memoizedState.isDehydrated&&(ic(l,u).flags|=256),l=ay(l,u),l!==2&&(u=ti,ti=h,u!==null&&Xw(u)),l}function Xw(l){ti===null?ti=l:ti.push.apply(ti,l)}function MW(l){for(var u=l;;){if(u.flags&16384){var h=u.updateQueue;if(h!==null&&(h=h.stores,h!==null))for(var y=0;y<h.length;y++){var S=h[y],T=S.getSnapshot;S=S.value;try{if(!as(T(),S))return!1}catch{return!1}}}if(h=u.child,u.subtreeFlags&16384&&h!==null)h.return=u,u=h;else{if(u===l)break;for(;u.sibling===null;){if(u.return===null||u.return===l)return!0;u=u.return}u.sibling.return=u.return,u=u.sibling}}return!0}function Ma(l,u){for(u&=~Kw,u&=~ty,l.suspendedLanes|=u,l.pingedLanes&=~u,l=l.expirationTimes;0<u;){var h=31-nn(u),y=1<<h;l[h]=-1,u&=~y}}function oO(l){if((Ht&6)!==0)throw Error(n(327));qu();var u=mg(l,0);if((u&1)===0)return ni(l,Qt()),null;var h=ay(l,u);if(l.tag!==0&&h===2){var y=O1(l);y!==0&&(u=y,h=Zw(l,y))}if(h===1)throw h=yh,ic(l,0),Ma(l,u),ni(l,Qt()),h;if(h===6)throw Error(n(345));return l.finishedWork=l.current.alternate,l.finishedLanes=u,sc(l,ti,Eo),ni(l,Qt()),null}function Qw(l,u){var h=Ht;Ht|=1;try{return l(u)}finally{Ht=h,Ht===0&&(Wu=Qt()+500,Dg&&ka())}}function rc(l){Aa!==null&&Aa.tag===0&&(Ht&6)===0&&qu();var u=Ht;Ht|=1;var h=zi.transition,y=en;try{if(zi.transition=null,en=1,l)return l()}finally{en=y,zi.transition=h,Ht=u,(Ht&6)===0&&ka()}}function eb(){_i=Vu.current,hn(Vu)}function ic(l,u){l.finishedWork=null,l.finishedLanes=0;var h=l.timeoutHandle;if(h!==-1&&(l.timeoutHandle=-1,cW(h)),Hn!==null)for(h=Hn.return;h!==null;){var y=h;switch(cw(y),y.tag){case 1:y=y.type.childContextTypes,y!=null&&Ig();break;case 3:zu(),hn(Xr),hn(Tr),Sw();break;case 5:ww(y);break;case 4:zu();break;case 13:hn(Sn);break;case 19:hn(Sn);break;case 10:mw(y.type._context);break;case 22:case 23:eb()}h=h.return}if(fr=l,Hn=l=Da(l.current,null),_r=_i=u,tr=0,yh=null,Kw=ty=nc=0,ti=vh=null,Ql!==null){for(u=0;u<Ql.length;u++)if(h=Ql[u],y=h.interleaved,y!==null){h.interleaved=null;var S=y.next,T=h.pending;if(T!==null){var $=T.next;T.next=S,y.next=$}h.pending=y}Ql=null}return l}function aO(l,u){do{var h=Hn;try{if(pw(),Vg.current=Gg,Wg){for(var y=En.memoizedState;y!==null;){var S=y.queue;S!==null&&(S.pending=null),y=y.next}Wg=!1}if(tc=0,dr=er=En=null,dh=!1,fh=0,qw.current=null,h===null||h.return===null){tr=1,yh=u,Hn=null;break}e:{var T=l,$=h.return,G=h,Q=u;if(u=_r,G.flags|=32768,Q!==null&&typeof Q=="object"&&typeof Q.then=="function"){var ue=Q,pe=G,ge=pe.tag;if((pe.mode&1)===0&&(ge===0||ge===11||ge===15)){var he=pe.alternate;he?(pe.updateQueue=he.updateQueue,pe.memoizedState=he.memoizedState,pe.lanes=he.lanes):(pe.updateQueue=null,pe.memoizedState=null)}var Me=I3($);if(Me!==null){Me.flags&=-257,M3(Me,$,G,T,u),Me.mode&1&&A3(T,ue,u),u=Me,Q=ue;var Ne=u.updateQueue;if(Ne===null){var ze=new Set;ze.add(Q),u.updateQueue=ze}else Ne.add(Q);break e}else{if((u&1)===0){A3(T,ue,u),tb();break e}Q=Error(n(426))}}else if(_n&&G.mode&1){var Nn=I3($);if(Nn!==null){(Nn.flags&65536)===0&&(Nn.flags|=256),M3(Nn,$,G,T,u),fw(Bu(Q,G));break e}}T=Q=Bu(Q,G),tr!==4&&(tr=2),vh===null?vh=[T]:vh.push(T),T=$;do{switch(T.tag){case 3:T.flags|=65536,u&=-u,T.lanes|=u;var ie=P3(T,Q,u);n3(T,ie);break e;case 1:G=Q;var ee=T.type,ae=T.stateNode;if((T.flags&128)===0&&(typeof ee.getDerivedStateFromError=="function"||ae!==null&&typeof ae.componentDidCatch=="function"&&(Oa===null||!Oa.has(ae)))){T.flags|=65536,u&=-u,T.lanes|=u;var _e=O3(T,G,u);n3(T,_e);break e}}T=T.return}while(T!==null)}uO(h)}catch(qe){u=qe,Hn===h&&h!==null&&(Hn=h=h.return);continue}break}while(!0)}function lO(){var l=ey.current;return ey.current=Gg,l===null?Gg:l}function tb(){(tr===0||tr===3||tr===2)&&(tr=4),fr===null||(nc&268435455)===0&&(ty&268435455)===0||Ma(fr,_r)}function ay(l,u){var h=Ht;Ht|=2;var y=lO();(fr!==l||_r!==u)&&(Eo=null,ic(l,u));do try{DW();break}catch(S){aO(l,S)}while(!0);if(pw(),Ht=h,ey.current=y,Hn!==null)throw Error(n(261));return fr=null,_r=0,tr}function DW(){for(;Hn!==null;)cO(Hn)}function LW(){for(;Hn!==null&&!Jt();)cO(Hn)}function cO(l){var u=hO(l.alternate,l,_i);l.memoizedProps=l.pendingProps,u===null?uO(l):Hn=u,qw.current=null}function uO(l){var u=l;do{var h=u.alternate;if(l=u.return,(u.flags&32768)===0){if(h=TW(h,u,_i),h!==null){Hn=h;return}}else{if(h=RW(h,u),h!==null){h.flags&=32767,Hn=h;return}if(l!==null)l.flags|=32768,l.subtreeFlags=0,l.deletions=null;else{tr=6,Hn=null;return}}if(u=u.sibling,u!==null){Hn=u;return}Hn=u=l}while(u!==null);tr===0&&(tr=5)}function sc(l,u,h){var y=en,S=zi.transition;try{zi.transition=null,en=1,NW(l,u,h,y)}finally{zi.transition=S,en=y}return null}function NW(l,u,h,y){do qu();while(Aa!==null);if((Ht&6)!==0)throw Error(n(327));h=l.finishedWork;var S=l.finishedLanes;if(h===null)return null;if(l.finishedWork=null,l.finishedLanes=0,h===l.current)throw Error(n(177));l.callbackNode=null,l.callbackPriority=0;var T=h.lanes|h.childLanes;if(gV(l,T),l===fr&&(Hn=fr=null,_r=0),(h.subtreeFlags&2064)===0&&(h.flags&2064)===0||ry||
vendor: 5,475 bytes, line 9
9(ry=!0,pO(ma,function(){return qu(),null})),T=(h.flags&15990)!==0,(h.subtreeFlags&15990)!==0||T){T=zi.transition,zi.transition=null;var $=en;en=1;var G=Ht;Ht|=4,qw.current=null,OW(l,h),eO(h,l),nW(tw),vg=!!ew,tw=ew=null,l.current=h,AW(h),Zr(),Ht=G,en=$,zi.transition=T}else l.current=h;if(ry&&(ry=!1,Aa=l,iy=S),T=l.pendingLanes,T===0&&(Oa=null),Mt(h.stateNode),ni(l,Qt()),u!==null)for(y=l.onRecoverableError,h=0;h<u.length;h++)S=u[h],y(S.value,{componentStack:S.stack,digest:S.digest});if(ny)throw ny=!1,l=Yw,Yw=null,l;return(iy&1)!==0&&l.tag!==0&&qu(),T=l.pendingLanes,(T&1)!==0?l===Jw?_h++:(_h=0,Jw=l):_h=0,ka(),null}function qu(){if(Aa!==null){var l=XR(iy),u=zi.transition,h=en;try{if(zi.transition=null,en=16>l?16:l,Aa===null)var y=!1;else{if(l=Aa,Aa=null,iy=0,(Ht&6)!==0)throw Error(n(331));var S=Ht;for(Ht|=4,Le=l.current;Le!==null;){var T=Le,$=T.child;if((Le.flags&16)!==0){var G=T.deletions;if(G!==null){for(var Q=0;Q<G.length;Q++){var ue=G[Q];for(Le=ue;Le!==null;){var pe=Le;switch(pe.tag){case 0:case 11:case 15:gh(8,pe,T)}var ge=pe.child;if(ge!==null)ge.return=pe,Le=ge;else for(;Le!==null;){pe=Le;var he=pe.sibling,Me=pe.return;if(Y3(pe),pe===ue){Le=null;break}if(he!==null){he.return=Me,Le=he;break}Le=Me}}}var Ne=T.alternate;if(Ne!==null){var ze=Ne.child;if(ze!==null){Ne.child=null;do{var Nn=ze.sibling;ze.sibling=null,ze=Nn}while(ze!==null)}}Le=T}}if((T.subtreeFlags&2064)!==0&&$!==null)$.return=T,Le=$;else e:for(;Le!==null;){if(T=Le,(T.flags&2048)!==0)switch(T.tag){case 0:case 11:case 15:gh(9,T,T.return)}var ie=T.sibling;if(ie!==null){ie.return=T.return,Le=ie;break e}Le=T.return}}var ee=l.current;for(Le=ee;Le!==null;){$=Le;var ae=$.child;if(($.subtreeFlags&2064)!==0&&ae!==null)ae.return=$,Le=ae;else e:for($=ee;Le!==null;){if(G=Le,(G.flags&2048)!==0)try{switch(G.tag){case 0:case 11:case 15:Qg(9,G)}}catch(qe){Rn(G,G.return,qe)}if(G===$){Le=null;break e}var _e=G.sibling;if(_e!==null){_e.return=G.return,Le=_e;break e}Le=G.return}}if(Ht=S,ka(),Nr&&typeof Nr.onPostCommitFiberRoot=="function")try{Nr.onPostCommitFiberRoot(ho,l)}catch{}y=!0}return y}finally{en=h,zi.transition=u}}return!1}function dO(l,u,h){u=Bu(h,u),u=P3(l,u,1),l=Ra(l,u,1),u=jr(),l!==null&&(Hf(l,1,u),ni(l,u))}function Rn(l,u,h){if(l.tag===3)dO(l,l,h);else for(;u!==null;){if(u.tag===3){dO(u,l,h);break}else if(u.tag===1){var y=u.stateNode;if(typeof u.type.getDerivedStateFromError=="function"||typeof y.componentDidCatch=="function"&&(Oa===null||!Oa.has(y))){l=Bu(h,l),l=O3(u,l,1),u=Ra(u,l,1),l=jr(),u!==null&&(Hf(u,1,l),ni(u,l));break}}u=u.return}}function $W(l,u,h){var y=l.pingCache;y!==null&&y.delete(u),u=jr(),l.pingedLanes|=l.suspendedLanes&h,fr===l&&(_r&h)===h&&(tr===4||tr===3&&(_r&130023424)===_r&&500>Qt()-Gw?ic(l,0):Kw|=h),ni(l,u)}function fO(l,u){u===0&&((l.mode&1)===0?u=1:(u=Kl,Kl<<=1,(Kl&130023424)===0&&(Kl=4194304)));var h=jr();l=wo(l,u),l!==null&&(Hf(l,u,h),ni(l,h))}function jW(l){var u=l.memoizedState,h=0;u!==null&&(h=u.retryLane),fO(l,h)}function FW(l,u){var h=0;switch(l.tag){case 13:var y=l.stateNode,S=l.memoizedState;S!==null&&(h=S.retryLane);break;case 19:y=l.stateNode;break;default:throw Error(n(314))}y!==null&&y.delete(u),fO(l,h)}var hO;hO=function(l,u,h){if(l!==null)if(l.memoizedProps!==u.pendingProps||Xr.current)ei=!0;else{if((l.lanes&h)===0&&(u.flags&128)===0)return ei=!1,kW(l,u,h);ei=(l.flags&131072)!==0}else ei=!1,_n&&(u.flags&1048576)!==0&&qP(u,Ng,u.index);switch(u.lanes=0,u.tag){case 2:var y=u.type;Zg(l,u),l=u.pendingProps;var S=Du(u,Tr.current);Uu(u,h),S=Cw(null,u,y,l,S,h);var T=kw();return u.flags|=1,typeof S=="object"&&S!==null&&typeof S.render=="function"&&S.$$typeof===void 0?(u.tag=1,u.memoizedState=null,u.updateQueue=null,Qr(y)?(T=!0,Mg(u)):T=!1,u.memoizedState=S.state!==null&&S.state!==void 0?S.state:null,vw(u),S.updater=Yg,u.stateNode=S,S._reactInternals=u,Iw(u,y,l,h),u=Nw(null,u,y,!0,T,h)):(u.tag=0,_n&&T&&lw(u),$r(null,u,S,h),u=u.child),u;case 16:y=u.elementType;e:{switch(Zg(l,u),l=u.pendingProps,S=y._init,y=S(y._payload),u.type=y,S=u.tag=zW(y),l=cs(y,l),S){case 0:u=Lw(null,u,y,l,h);break e;case 1:u=F3(null,u,y,l,h);break e;case 11:u=D3(null,u,y,l,h);break e;case 14:u=L3(null,u,y,cs(y.type,l),h);break e}throw Error(n(306,y,""))}return u;case 0:return y=u.type,S=u.pendingProps,S=u.elementType===y?S:cs(y,S),Lw(l,u,y,S,h);case 1:return y=u.type,S=u.pendingProps,S=u.elementType===y?S:cs(y,S),F3(l,u,y,S,h);case 3:e:{if(U3(u),l===null)throw Error(n(387));y=u.pendingProps,T=u.memoizedState,S=T.element,t3(l,u),Bg(u,y,null,h);var $=u.memoizedState;if(y=$.element,T.isDehydrated)if(T={element:y,isDehydrated:!1,cache:$.cache,pendingSuspenseBoundaries:$.pendingSuspenseBoundaries,transitions:$.transitions},u.updateQueue.baseState=T,u.memoizedState=T,u.flags&256){S=Bu(Error(n(423)),u),u=z3(l,u,y,h,S);break e}else if(y!==S){S=Bu(Error(n(424)),u),u=z3(l,u,y,h,S);break e}else for(vi=Ea(u.stateNode.containerInfo.firstChild),yi=u,_n=!0,ls=null,h=QP(u,null,y,h),u.child=h;h;)h.flags=h.flags&-3|4096,h=h.sibling;else{if($u(),y===S){u=So(l,u,h);break e}$r(l,u,y,h)}u=u.child}return u;case 5:return i3(u),l===null&&dw(u),y=u.type,S=u.pendingProps,T=l!==null?l.memoizedProps:null,$=S.children,nw(y,S)?$=null:T!==null&&nw(y,T)&&(u.flags|=32),j3(l,u),$r(l,u,$,h),u.child;case 6:return l===null&&dw(u),null;case 13:return B3(l,u,h);case 4:return _w(u,u.stateNode.containerInfo),y=u.pendingProps,l===null?u.child=ju(u,null,y,h):$r(l,u,y,h),u.child;case 11:return y=u.type,S=u.pendingProps,S=u.elementType===y?S:cs(y,S),D3(l,u,y,S,h);
vendor: 9,298 bytes, line 9
9case 7:return $r(l,u,u.pendingProps,h),u.child;case 8:return $r(l,u,u.pendingProps.children,h),u.child;case 12:return $r(l,u,u.pendingProps.children,h),u.child;case 10:e:{if(y=u.type._context,S=u.pendingProps,T=u.memoizedProps,$=S.value,ln(Fg,y._currentValue),y._currentValue=$,T!==null)if(as(T.value,$)){if(T.children===S.children&&!Xr.current){u=So(l,u,h);break e}}else for(T=u.child,T!==null&&(T.return=u);T!==null;){var G=T.dependencies;if(G!==null){$=T.child;for(var Q=G.firstContext;Q!==null;){if(Q.context===y){if(T.tag===1){Q=bo(-1,h&-h),Q.tag=2;var ue=T.updateQueue;if(ue!==null){ue=ue.shared;var pe=ue.pending;pe===null?Q.next=Q:(Q.next=pe.next,pe.next=Q),ue.pending=Q}}T.lanes|=h,Q=T.alternate,Q!==null&&(Q.lanes|=h),gw(T.return,h,u),G.lanes|=h;break}Q=Q.next}}else if(T.tag===10)$=T.type===u.type?null:T.child;else if(T.tag===18){if($=T.return,$===null)throw Error(n(341));$.lanes|=h,G=$.alternate,G!==null&&(G.lanes|=h),gw($,h,u),$=T.sibling}else $=T.child;if($!==null)$.return=T;else for($=T;$!==null;){if($===u){$=null;break}if(T=$.sibling,T!==null){T.return=$.return,$=T;break}$=$.return}T=$}$r(l,u,S.children,h),u=u.child}return u;case 9:return S=u.type,y=u.pendingProps.children,Uu(u,h),S=Fi(S),y=y(S),u.flags|=1,$r(l,u,y,h),u.child;case 14:return y=u.type,S=cs(y,u.pendingProps),S=cs(y.type,S),L3(l,u,y,S,h);case 15:return N3(l,u,u.type,u.pendingProps,h);case 17:return y=u.type,S=u.pendingProps,S=u.elementType===y?S:cs(y,S),Zg(l,u),u.tag=1,Qr(y)?(l=!0,Mg(u)):l=!1,Uu(u,h),T3(u,y,S),Iw(u,y,S,h),Nw(null,u,y,!0,l,h);case 19:return V3(l,u,h);case 22:return $3(l,u,h)}throw Error(n(156,u.tag))};function pO(l,u){return Ln(l,u)}function UW(l,u,h,y){this.tag=l,this.key=h,this.sibling=this.child=this.return=this.stateNode=this.type=this.elementType=null,this.index=0,this.ref=null,this.pendingProps=u,this.dependencies=this.memoizedState=this.updateQueue=this.memoizedProps=null,this.mode=y,this.subtreeFlags=this.flags=0,this.deletions=null,this.childLanes=this.lanes=0,this.alternate=null}function Bi(l,u,h,y){return new UW(l,u,h,y)}function nb(l){return l=l.prototype,!(!l||!l.isReactComponent)}function zW(l){if(typeof l=="function")return nb(l)?1:0;if(l!=null){if(l=l.$$typeof,l===K)return 11;if(l===q)return 14}return 2}function Da(l,u){var h=l.alternate;return h===null?(h=Bi(l.tag,u,l.key,l.mode),h.elementType=l.elementType,h.type=l.type,h.stateNode=l.stateNode,h.alternate=l,l.alternate=h):(h.pendingProps=u,h.type=l.type,h.flags=0,h.subtreeFlags=0,h.deletions=null),h.flags=l.flags&14680064,h.childLanes=l.childLanes,h.lanes=l.lanes,h.child=l.child,h.memoizedProps=l.memoizedProps,h.memoizedState=l.memoizedState,h.updateQueue=l.updateQueue,u=l.dependencies,h.dependencies=u===null?null:{lanes:u.lanes,firstContext:u.firstContext},h.sibling=l.sibling,h.index=l.index,h.ref=l.ref,h}function ly(l,u,h,y,S,T){var $=2;if(y=l,typeof l=="function")nb(l)&&($=1);else if(typeof l=="string")$=5;else e:switch(l){case k:return oc(h.children,S,T,u);case L:$=8,S|=8;break;case B:return l=Bi(12,h,u,S|2),l.elementType=B,l.lanes=T,l;case W:return l=Bi(13,h,u,S),l.elementType=W,l.lanes=T,l;case U:return l=Bi(19,h,u,S),l.elementType=U,l.lanes=T,l;case x:return cy(h,S,T,u);default:if(typeof l=="object"&&l!==null)switch(l.$$typeof){case A:$=10;break e;case V:$=9;break e;case K:$=11;break e;case q:$=14;break e;case z:$=16,y=null;break e}throw Error(n(130,l==null?l:typeof l,""))}return u=Bi($,h,u,S),u.elementType=l,u.type=y,u.lanes=T,u}function oc(l,u,h,y){return l=Bi(7,l,y,u),l.lanes=h,l}function cy(l,u,h,y){return l=Bi(22,l,y,u),l.elementType=x,l.lanes=h,l.stateNode={isHidden:!1},l}function rb(l,u,h){return l=Bi(6,l,null,u),l.lanes=h,l}function ib(l,u,h){return u=Bi(4,l.children!==null?l.children:[],l.key,u),u.lanes=h,u.stateNode={containerInfo:l.containerInfo,pendingChildren:null,implementation:l.implementation},u}function BW(l,u,h,y,S){this.tag=u,this.containerInfo=l,this.finishedWork=this.pingCache=this.current=this.pendingChildren=null,this.timeoutHandle=-1,this.callbackNode=this.pendingContext=this.context=null,this.callbackPriority=0,this.eventTimes=A1(0),this.expirationTimes=A1(-1),this.entangledLanes=this.finishedLanes=this.mutableReadLanes=this.expiredLanes=this.pingedLanes=this.suspendedLanes=this.pendingLanes=0,this.entanglements=A1(0),this.identifierPrefix=y,this.onRecoverableError=S,this.mutableSourceEagerHydrationData=null}function sb(l,u,h,y,S,T,$,G,Q){return l=new BW(l,u,h,G,Q),u===1?(u=1,T===!0&&(u|=8)):u=0,T=Bi(3,null,null,u),l.current=T,T.stateNode=l,T.memoizedState={element:y,isDehydrated:h,cache:null,transitions:null,pendingSuspenseBoundaries:null},vw(T),l}function HW(l,u,h){var y=3<arguments.length&&arguments[3]!==void 0?arguments[3]:null;return{$$typeof:I,key:y==null?null:""+y,children:l,containerInfo:u,implementation:h}}function mO(l){if(!l)return Ca;l=l._reactInternals;e:{if(He(l)!==l||l.tag!==1)throw Error(n(170));var u=l;do{switch(u.tag){case 3:u=u.stateNode.context;break e;case 1:if(Qr(u.type)){u=u.stateNode.__reactInternalMemoizedMergedChildContext;break e}}u=u.return}while(u!==null);throw Error(n(171))}if(l.tag===1){var h=l.type;if(Qr(h))return HP(l,h,u)}return u}function gO(l,u,h,y,S,T,$,G,Q){return l=sb(h,y,!0,l,S,T,$,G,Q),l.context=mO(null),h=l.current,y=jr(),S=Ia(h),T=bo(y,S),T.callback=u??null,Ra(h,T,S),l.current.lanes=S,Hf(l,S,y),ni(l,y),l}function uy(l,u,h,y){var S=u.current,T=jr(),$=Ia(S);return h=mO(h),u.context===null?u.context=h:u.pendingContext=h,u=bo(T,$),u.payload={element:l},y=y===void 0?null:y,y!==null&&(u.callback=y),l=Ra(S,u,$),l!==null&&(fs(l,S,$,T),zg(l,S,$)),$}function dy(l){if(l=l.current,!l.child)return null;switch(l.child.tag){case 5:return l.child.stateNode;default:return l.child.stateNode}}function yO(l,u){if(l=l.memoizedState,l!==null&&l.dehydrated!==null){var h=l.retryLane;l.retryLane=h!==0&&h<u?h:u}}function ob(l,u){yO(l,u),(l=l.alternate)&&yO(l,u)}function VW(){return null}var vO=typeof reportError=="function"?reportError:function(l){console.error(l)};function ab(l){this._internalRoot=l}fy.prototype.render=ab.prototype.render=function(l){var u=this._internalRoot;if(u===null)throw Error(n(409));uy(l,u,null,null)},fy.prototype.unmount=ab.prototype.unmount=function(){var l=this._internalRoot;if(l!==null){this._internalRoot=null;var u=l.containerInfo;rc(function(){uy(null,l,null,null)}),u[go]=null}};function fy(l){this._internalRoot=l}fy.prototype.unstable_scheduleHydration=function(l){if(l){var u=tP();l={blockedOn:null,target:l,priority:u};for(var h=0;h<wa.length&&u!==0&&u<wa[h].priority;h++);wa.splice(h,0,l),h===0&&iP(l)}};function lb(l){return!(!l||l.nodeType!==1&&l.nodeType!==9&&l.nodeType!==11)}function hy(l){return!(!l||l.nodeType!==1&&l.nodeType!==9&&l.nodeType!==11&&(l.nodeType!==8||l.nodeValue!==" react-mount-point-unstable "))}function _O(){}function WW(l,u,h,y,S){if(S){if(typeof y=="function"){var T=y;y=function(){var ue=dy($);T.call(ue)}}var $=gO(u,y,l,0,null,!1,!1,"",_O);return l._reactRootContainer=$,l[go]=$.current,rh(l.nodeType===8?l.parentNode:l),rc(),$}for(;S=l.lastChild;)l.removeChild(S);if(typeof y=="function"){var G=y;y=function(){var ue=dy(Q);G.call(ue)}}var Q=sb(l,0,!1,null,null,!1,!1,"",_O);return l._reactRootContainer=Q,l[go]=Q.current,rh(l.nodeType===8?l.parentNode:l),rc(function(){uy(u,Q,h,y)}),Q}function py(l,u,h,y,S){var T=h._reactRootContainer;if(T){var $=T;if(typeof S=="function"){var G=S;S=function(){var Q=dy($);G.call(Q)}}uy(u,$,l,S)}else $=WW(h,u,l,S,y);return dy($)}QR=function(l){switch(l.tag){case 3:var u=l.stateNode;if(u.current.memoizedState.isDehydrated){var h=Gl(u.pendingLanes);h!==0&&(I1(u,h|1),ni(u,Qt()),(Ht&6)===0&&(Wu=Qt()+500,ka()))}break;case 13:rc(function(){var y=wo(l,1);if(y!==null){var S=jr();fs(y,l,1,S)}}),ob(l,1)}},M1=function(l){if(l.tag===13){var u=wo(l,134217728);if(u!==null){var h=jr();fs(u,l,134217728,h)}ob(l,134217728)}},eP=function(l){if(l.tag===13){var u=Ia(l),h=wo(l,u);if(h!==null){var y=jr();fs(h,l,u,y)}ob(l,u)}},tP=function(){return en},nP=function(l,u){var h=en;try{return en=l,u()}finally{en=h}},ha=function(l,u,h){switch(u){case"input":if(it(l,h),u=h.name,h.type==="radio"&&u!=null){for(h=l;h.parentNode;)h=h.parentNode;for(h=h.querySelectorAll("input[name="+JSON.stringify(""+u)+'][type="radio"]'),u=0;u<h.length;u++){var y=h[u];if(y!==l&&y.form===l.form){var S=Ag(y);if(!S)throw Error(n(90));Ue(y),it(y,S)}}}break;case"textarea":yt(l,h);break;case"select":u=h.value,u!=null&&jt(l,!!h.multiple,u,!1)}},Uf=Qw,Hl=rc;var qW={usingClientEntryPoint:!1,Events:[oh,Iu,Ag,Ff,pg,Qw]},wh={findFiberByHostInstance:Yl,bundleType:0,version:"18.3.1",rendererPackageName:"react-dom"},KW={bundleType:wh.bundleType,version:wh.version,rendererPackageName:wh.rendererPackageName,rendererConfig:wh.rendererConfig,overrideHookState:null,overrideHookStateDeletePath:null,overrideHookStateRenamePath:null,overrideProps:null,overridePropsDeletePath:null,overridePropsRenamePath:null,setErrorHandler:null,setSuspenseHandler:null,scheduleUpdate:null,currentDispatcherRef:F.ReactCurrentDispatcher,findHostInstanceByFiber:function(l){return l=It(l),l===null?null:l.stateNode},findFiberByHostInstance:wh.findFiberByHostInstance||VW,findHostInstancesForRefresh:null,scheduleRefresh:null,scheduleRoot:null,setRefreshHandler:null,getCurrentFiber:null,reconcilerVersion:"18.3.1-next-f1338f8080-20240426"};
vendor: 4,801 bytes, line 9
9if(typeof __REACT_DEVTOOLS_GLOBAL_HOOK__<"u"){var my=__REACT_DEVTOOLS_GLOBAL_HOOK__;if(!my.isDisabled&&my.supportsFiber)try{ho=my.inject(KW),Nr=my}catch{}}return ri.__SECRET_INTERNALS_DO_NOT_USE_OR_YOU_WILL_BE_FIRED=qW,ri.createPortal=function(l,u){var h=2<arguments.length&&arguments[2]!==void 0?arguments[2]:null;if(!lb(u))throw Error(n(200));return HW(l,u,null,h)},ri.createRoot=function(l,u){if(!lb(l))throw Error(n(299));var h=!1,y="",S=vO;return u!=null&&(u.unstable_strictMode===!0&&(h=!0),u.identifierPrefix!==void 0&&(y=u.identifierPrefix),u.onRecoverableError!==void 0&&(S=u.onRecoverableError)),u=sb(l,1,!1,null,null,h,!1,y,S),l[go]=u.current,rh(l.nodeType===8?l.parentNode:l),new ab(u)},ri.findDOMNode=function(l){if(l==null)return null;if(l.nodeType===1)return l;var u=l._reactInternals;if(u===void 0)throw typeof l.render=="function"?Error(n(188)):(l=Object.keys(l).join(","),Error(n(268,l)));return l=It(u),l=l===null?null:l.stateNode,l},ri.flushSync=function(l){return rc(l)},ri.hydrate=function(l,u,h){if(!hy(u))throw Error(n(200));return py(null,l,u,!0,h)},ri.hydrateRoot=function(l,u,h){if(!lb(l))throw Error(n(405));var y=h!=null&&h.hydratedSources||null,S=!1,T="",$=vO;if(h!=null&&(h.unstable_strictMode===!0&&(S=!0),h.identifierPrefix!==void 0&&(T=h.identifierPrefix),h.onRecoverableError!==void 0&&($=h.onRecoverableError)),u=gO(u,null,l,1,h??null,S,!1,T,$),l[go]=u.current,rh(l),y)for(l=0;l<y.length;l++)h=y[l],S=h._getVersion,S=S(h._source),u.mutableSourceEagerHydrationData==null?u.mutableSourceEagerHydrationData=[h,S]:u.mutableSourceEagerHydrationData.push(h,S);return new fy(u)},ri.render=function(l,u,h){if(!hy(u))throw Error(n(200));return py(null,l,u,!1,h)},ri.unmountComponentAtNode=function(l){if(!hy(l))throw Error(n(40));return l._reactRootContainer?(rc(function(){py(null,null,l,!1,function(){l._reactRootContainer=null,l[go]=null})}),!0):!1},ri.unstable_batchedUpdates=Qw,ri.unstable_renderSubtreeIntoContainer=function(l,u,h,y){if(!hy(h))throw Error(n(200));if(l==null||l._reactInternals===void 0)throw Error(n(38));return py(l,u,h,!1,y)},ri.version="18.3.1-next-f1338f8080-20240426",ri}var TO;function HD(){if(TO)return db.exports;TO=1;function e(){if(!(typeof __REACT_DEVTOOLS_GLOBAL_HOOK__>"u"||typeof __REACT_DEVTOOLS_GLOBAL_HOOK__.checkDCE!="function"))try{__REACT_DEVTOOLS_GLOBAL_HOOK__.checkDCE(e)}catch(t){console.error(t)}}return e(),db.exports=nq(),db.exports}var RO;function rq(){if(RO)return yy;RO=1;var e=HD();return yy.createRoot=e.createRoot,yy.hydrateRoot=e.hydrateRoot,yy}var iq=rq();function gt(e,t,{checkForDefaultPrevented:n=!0}={}){return function(i){if(e?.(i),n===!1||!i.defaultPrevented)return t?.(i)}}function PO(e,t){if(typeof e=="function")return e(t);e!=null&&(e.current=t)}function Ol(...e){return t=>{let n=!1;const r=e.map(i=>{const s=PO(i,t);return!n&&typeof s=="function"&&(n=!0),s});if(n)return()=>{for(let i=0;i<r.length;i++){const s=r[i];typeof s=="function"?s():PO(e[i],null)}}}}function lr(...e){return g.useCallback(Ol(...e),e)}function sq(e,t){const n=g.createContext(t),r=s=>{const{children:o,...a}=s,c=g.useMemo(()=>a,Object.values(a));return j.jsx(n.Provider,{value:c,children:o})};r.displayName=e+"Provider";function i(s){const o=g.useContext(n);if(o)return o;if(t!==void 0)return t;throw new Error(`\`${s}\` must be used within \`${e}\``)}return[r,i]}function Al(e,t=[]){let n=[];function r(s,o){const a=g.createContext(o),c=n.length;n=[...n,o];const d=p=>{const{scope:m,children:v,...w}=p,_=m?.[e]?.[c]||a,b=g.useMemo(()=>w,Object.values(w));return j.jsx(_.Provider,{value:b,children:v})};d.displayName=s+"Provider";function f(p,m){const v=m?.[e]?.[c]||a,w=g.useContext(v);if(w)return w;if(o!==void 0)return o;throw new Error(`\`${p}\` must be used within \`${s}\``)}return[d,f]}const i=()=>{const s=n.map(o=>g.createContext(o));return function(a){const c=a?.[e]||s;return g.useMemo(()=>({[`__scope${e}`]:{...a,[e]:c}}),[a,c])}};return i.scopeName=e,[r,oq(i,...t)]}function oq(...e){const t=e[0];if(e.length===1)return t;const n=()=>{const r=e.map(i=>({useScope:i(),scopeName:i.scopeName}));return function(s){const o=r.reduce((a,{useScope:c,scopeName:d})=>{const p=c(s)[`__scope${d}`];return{...a,...p}},{});return g.useMemo(()=>({[`__scope${t.scopeName}`]:o}),[o])}};return n.scopeName=t.scopeName,n}var b_=HD();const aq=Pl(b_);function lq(e){const t=cq(e),n=g.forwardRef((r,i)=>{const{children:s,...o}=r,a=g.Children.toArray(s),c=a.find(dq);if(c){const d=c.props.children,f=a.map(p=>p===c?g.Children.count(d)>1?g.Children.only(null):g.isValidElement(d)?d.props.children:null:p);return j.jsx(t,{...o,ref:i,children:g.isValidElement(d)?g.cloneElement(d,void 0,f):null})}return j.jsx(t,{...o,ref:i,children:s})});return n.displayName=`${e}.Slot`,n}function cq(e){const t=g.forwardRef((n,r)=>{const{children:i,...s}=n;
vendor: 5,276 bytes, line 9
9if(g.isValidElement(i)){const o=hq(i),a=fq(s,i.props);return i.type!==g.Fragment&&(a.ref=r?Ol(r,o):o),g.cloneElement(i,a)}return g.Children.count(i)>1?g.Children.only(null):null});return t.displayName=`${e}.SlotClone`,t}var uq=Symbol("radix.slottable");function dq(e){return g.isValidElement(e)&&typeof e.type=="function"&&"__radixId"in e.type&&e.type.__radixId===uq}function fq(e,t){const n={...t};for(const r in t){const i=e[r],s=t[r];/^on[A-Z]/.test(r)?i&&s?n[r]=(...a)=>{const c=s(...a);return i(...a),c}:i&&(n[r]=i):r==="style"?n[r]={...i,...s}:r==="className"&&(n[r]=[i,s].filter(Boolean).join(" "))}return{...e,...n}}function hq(e){let t=Object.getOwnPropertyDescriptor(e.props,"ref")?.get,n=t&&"isReactWarning"in t&&t.isReactWarning;return n?e.ref:(t=Object.getOwnPropertyDescriptor(e,"ref")?.get,n=t&&"isReactWarning"in t&&t.isReactWarning,n?e.props.ref:e.props.ref||e.ref)}var pq=["a","button","div","form","h2","h3","img","input","label","li","nav","ol","p","select","span","svg","ul"],yn=pq.reduce((e,t)=>{const n=lq(`Primitive.${t}`),r=g.forwardRef((i,s)=>{const{asChild:o,...a}=i,c=o?n:t;return typeof window<"u"&&(window[Symbol.for("radix-ui")]=!0),j.jsx(c,{...a,ref:s})});return r.displayName=`Primitive.${t}`,{...e,[t]:r}},{});function VD(e,t){e&&b_.flushSync(()=>e.dispatchEvent(t))}function Yo(e){const t=g.useRef(e);return g.useEffect(()=>{t.current=e}),g.useMemo(()=>(...n)=>t.current?.(...n),[])}function mq(e,t=globalThis?.document){const n=Yo(e);g.useEffect(()=>{const r=i=>{i.key==="Escape"&&n(i)};return t.addEventListener("keydown",r,{capture:!0}),()=>t.removeEventListener("keydown",r,{capture:!0})},[n,t])}var gq="DismissableLayer",ME="dismissableLayer.update",yq="dismissableLayer.pointerDownOutside",vq="dismissableLayer.focusOutside",OO,WD=g.createContext({layers:new Set,layersWithOutsidePointerEventsDisabled:new Set,branches:new Set}),S_=g.forwardRef((e,t)=>{const{disableOutsidePointerEvents:n=!1,onEscapeKeyDown:r,onPointerDownOutside:i,onFocusOutside:s,onInteractOutside:o,onDismiss:a,...c}=e,d=g.useContext(WD),[f,p]=g.useState(null),m=f?.ownerDocument??globalThis?.document,[,v]=g.useState({}),w=lr(t,k=>p(k)),_=Array.from(d.layers),[b]=[...d.layersWithOutsidePointerEventsDisabled].slice(-1),C=_.indexOf(b),P=f?_.indexOf(f):-1,D=d.layersWithOutsidePointerEventsDisabled.size>0,F=P>=C,R=bq(k=>{const L=k.target,B=[...d.branches].some(A=>A.contains(L));!F||B||(i?.(k),o?.(k),k.defaultPrevented||a?.())},m),I=Sq(k=>{const L=k.target;[...d.branches].some(A=>A.contains(L))||(s?.(k),o?.(k),k.defaultPrevented||a?.())},m);return mq(k=>{P===d.layers.size-1&&(r?.(k),!k.defaultPrevented&&a&&(k.preventDefault(),a()))},m),g.useEffect(()=>{if(f)return n&&(d.layersWithOutsidePointerEventsDisabled.size===0&&(OO=m.body.style.pointerEvents,m.body.style.pointerEvents="none"),d.layersWithOutsidePointerEventsDisabled.add(f)),d.layers.add(f),AO(),()=>{n&&d.layersWithOutsidePointerEventsDisabled.size===1&&(m.body.style.pointerEvents=OO)}},[f,m,n,d]),g.useEffect(()=>()=>{f&&(d.layers.delete(f),d.layersWithOutsidePointerEventsDisabled.delete(f),AO())},[f,d]),g.useEffect(()=>{const k=()=>v({});return document.addEventListener(ME,k),()=>document.removeEventListener(ME,k)},[]),j.jsx(yn.div,{...c,ref:w,style:{pointerEvents:D?F?"auto":"none":void 0,...e.style},onFocusCapture:gt(e.onFocusCapture,I.onFocusCapture),onBlurCapture:gt(e.onBlurCapture,I.onBlurCapture),onPointerDownCapture:gt(e.onPointerDownCapture,R.onPointerDownCapture)})});S_.displayName=gq;var _q="DismissableLayerBranch",wq=g.forwardRef((e,t)=>{const n=g.useContext(WD),r=g.useRef(null),i=lr(t,r);return g.useEffect(()=>{const s=r.current;if(s)return n.branches.add(s),()=>{n.branches.delete(s)}},[n.branches]),j.jsx(yn.div,{...e,ref:i})});wq.displayName=_q;function bq(e,t=globalThis?.document){const n=Yo(e),r=g.useRef(!1),i=g.useRef(()=>{});return g.useEffect(()=>{const s=a=>{if(a.target&&!r.current){let c=function(){qD(yq,n,d,{discrete:!0})};const d={originalEvent:a};a.pointerType==="touch"?(t.removeEventListener("click",i.current),i.current=c,t.addEventListener("click",i.current,{once:!0})):c()}else t.removeEventListener("click",i.current);r.current=!1},o=window.setTimeout(()=>{t.addEventListener("pointerdown",s)},0);return()=>{window.clearTimeout(o),t.removeEventListener("pointerdown",s),t.removeEventListener("click",i.current)}},[t,n]),{onPointerDownCapture:()=>r.current=!0}}function Sq(e,t=globalThis?.document){const n=Yo(e),r=g.useRef(!1);return g.useEffect(()=>{const i=s=>{s.target&&!r.current&&qD(vq,n,{originalEvent:s},{discrete:!1})};return t.addEventListener("focusin",i),()=>t.removeEventListener("focusin",i)},[t,n]),{onFocusCapture:()=>r.current=!0,onBlurCapture:()=>r.current=!1}}function AO(){const e=new CustomEvent(ME);document.dispatchEvent(e)}function qD(e,t,n,{discrete:r}){const i=n.originalEvent.target,s=new CustomEvent(e,{bubbles:!1,cancelable:!0,detail:n});t&&i.addEventListener(e,t,{once:!0}),r?VD(i,s):i.dispatchEvent(s)}var yl=globalThis?.document?g.useLayoutEffect:()=>{},Eq=w_[" useId ".trim().toString()]||(()=>{}),xq=0;function Lc(e){const[t,n]=g.useState(Eq());return yl(()=>{n(r=>r??String(xq++))},[e]),t?`radix-${t}`:""}const Cq=["top","right","bottom","left"],vl=Math.min,Ei=Math.max,Jv=Math.round,vy=Math.floor,Zs=e=>({x:e,y:e}
vendor: 16,099 bytes, line 9
9),kq={left:"right",right:"left",bottom:"top",top:"bottom"},Tq={start:"end",end:"start"};function DE(e,t,n){return Ei(e,vl(t,n))}function Jo(e,t){return typeof e=="function"?e(t):e}function Zo(e){return e.split("-")[0]}function hf(e){return e.split("-")[1]}function NC(e){return e==="x"?"y":"x"}function $C(e){return e==="y"?"height":"width"}const Rq=new Set(["top","bottom"]);function Ks(e){return Rq.has(Zo(e))?"y":"x"}function jC(e){return NC(Ks(e))}function Pq(e,t,n){n===void 0&&(n=!1);const r=hf(e),i=jC(e),s=$C(i);let o=i==="x"?r===(n?"end":"start")?"right":"left":r==="start"?"bottom":"top";return t.reference[s]>t.floating[s]&&(o=Zv(o)),[o,Zv(o)]}function Oq(e){const t=Zv(e);return[LE(e),t,LE(t)]}function LE(e){return e.replace(/start|end/g,t=>Tq[t])}const IO=["left","right"],MO=["right","left"],Aq=["top","bottom"],Iq=["bottom","top"];function Mq(e,t,n){switch(e){case"top":case"bottom":return n?t?MO:IO:t?IO:MO;case"left":case"right":return t?Aq:Iq;default:return[]}}function Dq(e,t,n,r){const i=hf(e);let s=Mq(Zo(e),n==="start",r);return i&&(s=s.map(o=>o+"-"+i),t&&(s=s.concat(s.map(LE)))),s}function Zv(e){return e.replace(/left|right|bottom|top/g,t=>kq[t])}function Lq(e){return{top:0,right:0,bottom:0,left:0,...e}}function KD(e){return typeof e!="number"?Lq(e):{top:e,right:e,bottom:e,left:e}}function Xv(e){const{x:t,y:n,width:r,height:i}=e;return{width:r,height:i,top:n,left:t,right:t+r,bottom:n+i,x:t,y:n}}function DO(e,t,n){let{reference:r,floating:i}=e;const s=Ks(t),o=jC(t),a=$C(o),c=Zo(t),d=s==="y",f=r.x+r.width/2-i.width/2,p=r.y+r.height/2-i.height/2,m=r[a]/2-i[a]/2;let v;switch(c){case"top":v={x:f,y:r.y-i.height};break;case"bottom":v={x:f,y:r.y+r.height};break;case"right":v={x:r.x+r.width,y:p};break;case"left":v={x:r.x-i.width,y:p};break;default:v={x:r.x,y:r.y}}switch(hf(t)){case"start":v[o]-=m*(n&&d?-1:1);break;case"end":v[o]+=m*(n&&d?-1:1);break}return v}const Nq=async(e,t,n)=>{const{placement:r="bottom",strategy:i="absolute",middleware:s=[],platform:o}=n,a=s.filter(Boolean),c=await(o.isRTL==null?void 0:o.isRTL(t));let d=await o.getElementRects({reference:e,floating:t,strategy:i}),{x:f,y:p}=DO(d,r,c),m=r,v={},w=0;for(let _=0;_<a.length;_++){const{name:b,fn:C}=a[_],{x:P,y:D,data:F,reset:R}=await C({x:f,y:p,initialPlacement:r,placement:m,strategy:i,middlewareData:v,rects:d,platform:o,elements:{reference:e,floating:t}});f=P??f,p=D??p,v={...v,[b]:{...v[b],...F}},R&&w<=50&&(w++,typeof R=="object"&&(R.placement&&(m=R.placement),R.rects&&(d=R.rects===!0?await o.getElementRects({reference:e,floating:t,strategy:i}):R.rects),{x:f,y:p}=DO(d,m,c)),_=-1)}return{x:f,y:p,placement:m,strategy:i,middlewareData:v}};async function Rp(e,t){var n;t===void 0&&(t={});const{x:r,y:i,platform:s,rects:o,elements:a,strategy:c}=e,{boundary:d="clippingAncestors",rootBoundary:f="viewport",elementContext:p="floating",altBoundary:m=!1,padding:v=0}=Jo(t,e),w=KD(v),b=a[m?p==="floating"?"reference":"floating":p],C=Xv(await s.getClippingRect({element:(n=await(s.isElement==null?void 0:s.isElement(b)))==null||n?b:b.contextElement||await(s.getDocumentElement==null?void 0:s.getDocumentElement(a.floating)),boundary:d,rootBoundary:f,strategy:c})),P=p==="floating"?{x:r,y:i,width:o.floating.width,height:o.floating.height}:o.reference,D=await(s.getOffsetParent==null?void 0:s.getOffsetParent(a.floating)),F=await(s.isElement==null?void 0:s.isElement(D))?await(s.getScale==null?void 0:s.getScale(D))||{x:1,y:1}:{x:1,y:1},R=Xv(s.convertOffsetParentRelativeRectToViewportRelativeRect?await s.convertOffsetParentRelativeRectToViewportRelativeRect({elements:a,rect:P,offsetParent:D,strategy:c}):P);return{top:(C.top-R.top+w.top)/F.y,bottom:(R.bottom-C.bottom+w.bottom)/F.y,left:(C.left-R.left+w.left)/F.x,right:(R.right-C.right+w.right)/F.x}}const $q=e=>({name:"arrow",options:e,async fn(t){const{x:n,y:r,placement:i,rects:s,platform:o,elements:a,middlewareData:c}=t,{element:d,padding:f=0}=Jo(e,t)||{};if(d==null)return{};const p=KD(f),m={x:n,y:r},v=jC(i),w=$C(v),_=await o.getDimensions(d),b=v==="y",C=b?"top":"left",P=b?"bottom":"right",D=b?"clientHeight":"clientWidth",F=s.reference[w]+s.reference[v]-m[v]-s.floating[w],R=m[v]-s.reference[v],I=await(o.getOffsetParent==null?void 0:o.getOffsetParent(d));let k=I?I[D]:0;(!k||!await(o.isElement==null?void 0:o.isElement(I)))&&(k=a.floating[D]||s.floating[w]);const L=F/2-R/2,B=k/2-_[w]/2-1,A=vl(p[C],B),V=vl(p[P],B),K=A,W=k-_[w]-V,U=k/2-_[w]/2+L,q=DE(K,U,W),z=!c.arrow&&hf(i)!=null&&U!==q&&s.reference[w]/2-(U<K?A:V)-_[w]/2<0,x=z?U<K?U-K:U-W:0;return{[v]:m[v]+x,data:{[v]:q,centerOffset:U-q-x,...z&&{alignmentOffset:x}},reset:z}}}),jq=function(e){return e===void 0&&(e={}),{name:"flip",options:e,async fn(t){var n,r;const{placement:i,middlewareData:s,rects:o,initialPlacement:a,platform:c,elements:d}=t,{mainAxis:f=!0,crossAxis:p=!0,fallbackPlacements:m,fallbackStrategy:v="bestFit",fallbackAxisSideDirection:w="none",flipAlignment:_=!0,...b}=Jo(e,t);if((n=s.arrow)!=null&&n.alignmentOffset)return{};const C=Zo(i),P=Ks(a),D=Zo(a)===a,F=await(c.isRTL==null?void 0:c.isRTL(d.floating)),R=m||(D||!_?[Zv(a)]:Oq(a)),I=w!=="none";!m&&I&&R.push(...Dq(a,_,w,F));const k=[a,...R],L=await Rp(t,b),B=[];let A=((r=s.flip)==null?void 0:r.overflows)||[];if(f&&B.push(L[C]),p){const U=Pq(i,o,F);B.push(L[U[0]],L[U[1]])}if(A=[...A,{placement:i,overflows:B}],!B.every(U=>U<=0)){var V,K;const U=(((V=s.flip)==null?void 0:V.index)||0)+1,q=k[U];if(q&&(!(p==="alignment"?P!==Ks(q):!1)||A.every(N=>Ks(N.placement)===P?N.overflows[0]>0:!0)))return{data:{index:U,overflows:A},reset:{placement:q}};let z=(K=A.filter(x=>x.overflows[0]<=0).sort((x,N)=>x.overflows[1]-N.overflows[1])[0])==null?void 0:K.placement;if(!z)switch(v){case"bestFit":{var W;const x=(W=A.filter(N=>{if(I){const M=Ks(N.placement);return M===P||M==="y"}return!0}).map(N=>[N.placement,N.overflows.filter(M=>M>0).reduce((M,E)=>M+E,0)]).sort((N,M)=>N[1]-M[1])[0])==null?void 0:W[0];x&&(z=x);break}case"initialPlacement":z=a;break}if(i!==z)return{reset:{placement:z}}}return{}}}};function LO(e,t){return{top:e.top-t.height,right:e.right-t.width,bottom:e.bottom-t.height,left:e.left-t.width}}function NO(e){return Cq.some(t=>e[t]>=0)}const Fq=function(e){return e===void 0&&(e={}),{name:"hide",options:e,async fn(t){const{rects:n}=t,{strategy:r="referenceHidden",...i}=Jo(e,t);switch(r){case"referenceHidden":{const s=await Rp(t,{...i,elementContext:"reference"}),o=LO(s,n.reference);return{data:{referenceHiddenOffsets:o,referenceHidden:NO(o)}}}case"escaped":{const s=await Rp(t,{...i,altBoundary:!0}),o=LO(s,n.floating);return{data:{escapedOffsets:o,escaped:NO(o)}}}default:return{}}}}},GD=new Set(["left","top"]);async function Uq(e,t){const{placement:n,platform:r,elements:i}=e,s=await(r.isRTL==null?void 0:r.isRTL(i.floating)),o=Zo(n),a=hf(n),c=Ks(n)==="y",d=GD.has(o)?-1:1,f=s&&c?-1:1,p=Jo(t,e);let{mainAxis:m,crossAxis:v,alignmentAxis:w}=typeof p=="number"?{mainAxis:p,crossAxis:0,alignmentAxis:null}:{mainAxis:p.mainAxis||0,crossAxis:p.crossAxis||0,alignmentAxis:p.alignmentAxis};return a&&typeof w=="number"&&(v=a==="end"?w*-1:w),c?{x:v*f,y:m*d}:{x:m*d,y:v*f}}const zq=function(e){return e===void 0&&(e=0),{name:"offset",options:e,async fn(t){var n,r;const{x:i,y:s,placement:o,middlewareData:a}=t,c=await Uq(t,e);return o===((n=a.offset)==null?void 0:n.placement)&&(r=a.arrow)!=null&&r.alignmentOffset?{}:{x:i+c.x,y:s+c.y,data:{...c,placement:o}}}}},Bq=function(e){return e===void 0&&(e={}),{name:"shift",options:e,async fn(t){const{x:n,y:r,placement:i}=t,{mainAxis:s=!0,crossAxis:o=!1,limiter:a={fn:b=>{let{x:C,y:P}=b;return{x:C,y:P}}},...c}=Jo(e,t),d={x:n,y:r},f=await Rp(t,c),p=Ks(Zo(i)),m=NC(p);let v=d[m],w=d[p];if(s){const b=m==="y"?"top":"left",C=m==="y"?"bottom":"right",P=v+f[b],D=v-f[C];v=DE(P,v,D)}if(o){const b=p==="y"?"top":"left",C=p==="y"?"bottom":"right",P=w+f[b],D=w-f[C];w=DE(P,w,D)}const _=a.fn({...t,[m]:v,[p]:w});return{..._,data:{x:_.x-n,y:_.y-r,enabled:{[m]:s,[p]:o}}}}}},Hq=function(e){return e===void 0&&(e={}),{options:e,fn(t){const{x:n,y:r,placement:i,rects:s,middlewareData:o}=t,{offset:a=0,mainAxis:c=!0,crossAxis:d=!0}=Jo(e,t),f={x:n,y:r},p=Ks(i),m=NC(p);let v=f[m],w=f[p];const _=Jo(a,t),b=typeof _=="number"?{mainAxis:_,crossAxis:0}:{mainAxis:0,crossAxis:0,..._};if(c){const D=m==="y"?"height":"width",F=s.reference[m]-s.floating[D]+b.mainAxis,R=s.reference[m]+s.reference[D]-b.mainAxis;v<F?v=F:v>R&&(v=R)}if(d){var C,P;const D=m==="y"?"width":"height",F=GD.has(Zo(i)),R=s.reference[p]-s.floating[D]+(F&&((C=o.offset)==null?void 0:C[p])||0)+(F?0:b.crossAxis),I=s.reference[p]+s.reference[D]+(F?0:((P=o.offset)==null?void 0:P[p])||0)-(F?b.crossAxis:0);w<R?w=R:w>I&&(w=I)}return{[m]:v,[p]:w}}}},Vq=function(e){return e===void 0&&(e={}),{name:"size",options:e,async fn(t){var n,r;const{placement:i,rects:s,platform:o,elements:a}=t,{apply:c=()=>{},...d}=Jo(e,t),f=await Rp(t,d),p=Zo(i),m=hf(i),v=Ks(i)==="y",{width:w,height:_}=s.floating;let b,C;p==="top"||p==="bottom"?(b=p,C=m===(await(o.isRTL==null?void 0:o.isRTL(a.floating))?"start":"end")?"left":"right"):(C=p,b=m==="end"?"top":"bottom");const P=_-f.top-f.bottom,D=w-f.left-f.right,F=vl(_-f[b],P),R=vl(w-f[C],D),I=!t.middlewareData.shift;let k=F,L=R;if((n=t.middlewareData.shift)!=null&&n.enabled.x&&(L=D),(r=t.middlewareData.shift)!=null&&r.enabled.y&&(k=P),I&&!m){const A=Ei(f.left,0),V=Ei(f.right,0),K=Ei(f.top,0),W=Ei(f.bottom,0);v?L=w-2*(A!==0||V!==0?A+V:Ei(f.left,f.right)):k=_-2*(K!==0||W!==0?K+W:Ei(f.top,f.bottom))}await c({...t,availableWidth:L,availableHeight:k});const B=await o.getDimensions(a.floating);return w!==B.width||_!==B.height?{reset:{rects:!0}}:{}}}};function E_(){return typeof window<"u"}function pf(e){return YD(e)?(e.nodeName||"").toLowerCase():"#document"}function Ti(e){var t;return(e==null||(t=e.ownerDocument)==null?void 0:t.defaultView)||window}function lo(e){var t;return(t=(YD(e)?e.ownerDocument:e.document)||window.document)==null?void 0:t.documentElement}function YD(e){return E_()?e instanceof Node||e instanceof Ti(e).Node:!1}function ks(e){return E_()?e instanceof Element||e instanceof Ti(e).Element:!1}function no(e){return E_()?e instanceof HTMLElement||e instanceof Ti(e).HTMLElement:!1}function $O(e){return!E_()||typeof ShadowRoot>"u"?!1:e instanceof ShadowRoot||e instanceof Ti(e).ShadowRoot}const Wq=new Set(["inline","contents"]);function gm(e){const{overflow:t,overflowX:n,overflowY:r,display:i}=Ts(e);return/auto|scroll|overlay|hidden|clip/.test(t+r+n)&&!Wq.has(i)}const qq=new Set(["table","td","th"]);function Kq(e){return qq.has(pf(e))}const Gq=[":popover-open",":modal"];function x_(e){return Gq.some(t=>{try{return e.matches(t)}catch{return!1}})}const Yq=["transform","translate","scale","rotate","perspective"],Jq=["transform","translate","scale","rotate","perspective","filter"],Zq=["paint","layout","strict","content"];function FC(e){const t=UC(),n=ks(e)?Ts(e):e;return Yq.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)||Jq.some(r=>(n.willChange||"").includes(r))||Zq.some(r=>(n.contain||"").includes(r))}function Xq(e){let t=_l(e);for(;no(t)&&!Hd(t);){if(FC(t))return t;if(x_(t))return null;t=_l(t)}return null}function UC(){return typeof CSS>"u"||!CSS.supports?!1:CSS.supports("-webkit-backdrop-filter","none")}const Qq=new Set(["html","body","#document"]);function Hd(e){return Qq.has(pf(e))}function Ts(e){return Ti(e).getComputedStyle(e)}function C_(e){return ks(e)?{scrollLeft:e.scrollLeft,scrollTop:e.scrollTop}:{scrollLeft:e.scrollX,scrollTop:e.scrollY}}function _l(e){if(pf(e)==="html")return e;const t=e.assignedSlot||e.parentNode||$O(e)&&e.host||lo(e);return $O(t)?t.host:t}function JD(e){const t=_l(e);return Hd(t)?e.ownerDocument?e.ownerDocument.body:e.body:no(t)&&gm(t)?t:JD(t)}function Pp(e,t,n){var r;t===void 0&&(t=[]),n===void 0&&(n=!0);const i=JD(e),s=i===((r=e.ownerDocument)==null?void 0:r.body),o=Ti(i);if(s){const a=NE(o);return t.concat(o,o.visualViewport||[],gm(i)?i:[],a&&n?Pp(a):[])}return t.concat(i,Pp(i,[],n))}function NE(e){return e.parent&&Object.getPrototypeOf(e.parent)?e.frameElement:null}function ZD(e){const t=Ts(e);let n=parseFloat(t.width)||0,r=parseFloat(t.height)||0;const i=no(e),s=i?e.offsetWidth:n,o=i?e.offsetHeight:r,a=Jv(n)!==s||Jv(r)!==o;return a&&(n=s,r=o),{width:n,height:r,$:a}}function zC(e){return ks(e)?e:e.contextElement}function Ad(e){const t=zC(e);if(!no(t))return Zs(1);const n=t.getBoundingClientRect(),{width:r,height:i,$:s}=ZD(t);let o=(s?Jv(n.width):n.width)/r,a=(s?Jv(n.height):n.height)/i;return(!o||!Number.isFinite(o))&&(o=1),(!a||!Number.isFinite(a))&&(a=1),{x:o,y:a}}const eK=Zs(0);function XD(e){const t=Ti(e);return!UC()||!t.visualViewport?eK:{x:t.visualViewport.offsetLeft,y:t.visualViewport.offsetTop}}function tK(e,t,n){return t===void 0&&(t=!1),!n||t&&n!==Ti(e)?!1:t}function Wc(e,t,n,r){t===void 0&&(t=!1),n===void 0&&(n=!1);const i=e.getBoundingClientRect(),s=zC(e);let o=Zs(1);t&&(r?ks(r)&&(o=Ad(r)):o=Ad(e));const a=tK(s,n,r)?XD(s):Zs(0);let c=(i.left+a.x)/o.x,d=(i.top+a.y)/o.y,f=i.width/o.x,p=i.height/o.y;if(s){const m=Ti(s),v=r&&ks(r)?Ti(r):r;let w=m,_=NE(w);for(;_&&r&&v!==w;){const b=Ad(_),C=_.getBoundingClientRect(),P=Ts(_),D=C.left+(_.clientLeft+parseFloat(P.paddingLeft))*b.x,F=C.top+(_.clientTop+parseFloat(P.paddingTop))*b.y;c*=b.x,d*=b.y,f*=b.x,p*=b.y,c+=D,d+=F,w=Ti(_),_=NE(w)}}return Xv({width:f,height:p,x:c,y:d})}function k_(e,t){const n=C_(e).scrollLeft;return t?t.left+n:Wc(lo(e)).left+n}function QD(e,t){const n=e.getBoundingClientRect(),r=n.left+t.scrollLeft-k_(e,n),i=n.top+t.scrollTop;return{x:r,y:i}}function nK(e){let{elements:t,rect:n,offsetParent:r,strategy:i}=e;const s=i==="fixed",o=lo(r),a=t?x_(t.floating):!1;if(r===o||a&&s)return n;let c={scrollLeft:0,scrollTop:0},d=Zs(1);const f=Zs(0),p=no(r);if((p||!p&&!s)&&((pf(r)!=="body"||gm(o))&&(c=C_(r)),no(r))){const v=Wc(r);d=Ad(r),f.x=v.x+r.clientLeft,f.y=v.y+r.clientTop}const m=o&&!p&&!s?QD(o,c):Zs(0);return{width:n.width*d.x,height:n.height*d.y,x:n.x*d.x-c.scrollLeft*d.x+f.x+m.x,y:n.y*d.y-c.scrollTop*d.y+f.y+m.y}}function rK(e){return Array.from(e.getClientRects())}function iK(e){const t=lo(e),n=C_(e),r=e.ownerDocument.body,i=Ei(t.scrollWidth,t.clientWidth,r.scrollWidth,r.clientWidth),s=Ei(t.scrollHeight,t.clientHeight,r.scrollHeight,r.clientHeight);let o=-n.scrollLeft+k_(e);const a=-n.scrollTop;return Ts(r).direction==="rtl"&&(o+=Ei(t.clientWidth,r.clientWidth)-i),{width:i,height:s,x:o,y:a}}const jO=25;function sK(e,t){const n=Ti(e),r=lo(e),i=n.visualViewport;let s=r.clientWidth,o=r.clientHeight,a=0,c=0;if(i){s=i.width,o=i.height;const f=UC();(!f||f&&t==="fixed")&&(a=i.offsetLeft,c=i.offsetTop)}const d=k_(r);if(d<=0){const f=r.ownerDocument,p=f.body,m=getComputedStyle(p),v=f.compatMode==="CSS1Compat"&&parseFloat(m.marginLeft)+parseFloat(m.marginRight)||0,w=Math.abs(r.clientWidth-p.clientWidth-v);w<=jO&&(s-=w)}else d<=jO&&(s+=d);return{width:s,height:o,x:a,y:c}}const oK=new Set(["absolute","fixed"]);function aK(e,t){const n=Wc(e,!0,t==="fixed"),r=n.top+e.clientTop,i=n.left+e.clientLeft,s=no(e)?Ad(e):Zs(1),o=e.clientWidth*s.x,a=e.clientHeight*s.y,c=i*s.x,d=r*s.y;return{width:o,height:a,x:c,y:d}}function FO(e,t,n){let r;if(t==="viewport")r=sK(e,n);else if(t==="document")r=iK(lo(e));else if(ks(t))r=aK(t,n);else{const i=XD(e);r={x:t.x-i.x,y:t.y-i.y,width:t.width,height:t.height}}return Xv(r)}function e6(e,t){const n=_l(e);return n===t||!ks(n)||Hd(n)?!1:Ts(n).position==="fixed"||e6(n,t)}function lK(e,t){const n=t.get(e);if(n)return n;let r=Pp(e,[],!1).filter(a=>ks(a)&&pf(a)!=="body"),i=null;const s=Ts(e).position==="fixed";let o=s?_l(e):e;for(;ks(o)&&!Hd(o);){const a=Ts(o),c=FC(o);!c&&a.position==="fixed"&&(i=null),(s?!c&&!i:!c&&a.position==="static"&&!!i&&oK.has(i.position)||gm(o)&&!c&&e6(e,o))?r=r.filter(f=>f!==o):i=a,o=_l(o)}return t.set(e,r),r}function cK(e){let{element:t,boundary:n,rootBoundary:r,strategy:i}=e;const o=[...n==="clippingAncestors"?x_(t)?[]:lK(t,this._c):[].concat(n),r],a=o[0],c=o.reduce((d,f)=>{const p=FO(t,f,i);return d.top=Ei(p.top,d.top),d.right=vl(p.right,d.right),d.bottom=vl(p.bottom,d.bottom),d.left
vendor: 9,817 bytes, line 9
9=Ei(p.left,d.left),d},FO(t,a,i));return{width:c.right-c.left,height:c.bottom-c.top,x:c.left,y:c.top}}function uK(e){const{width:t,height:n}=ZD(e);return{width:t,height:n}}function dK(e,t,n){const r=no(t),i=lo(t),s=n==="fixed",o=Wc(e,!0,s,t);let a={scrollLeft:0,scrollTop:0};const c=Zs(0);function d(){c.x=k_(i)}if(r||!r&&!s)if((pf(t)!=="body"||gm(i))&&(a=C_(t)),r){const v=Wc(t,!0,s,t);c.x=v.x+t.clientLeft,c.y=v.y+t.clientTop}else i&&d();s&&!r&&i&&d();const f=i&&!r&&!s?QD(i,a):Zs(0),p=o.left+a.scrollLeft-c.x-f.x,m=o.top+a.scrollTop-c.y-f.y;return{x:p,y:m,width:o.width,height:o.height}}function pb(e){return Ts(e).position==="static"}function UO(e,t){if(!no(e)||Ts(e).position==="fixed")return null;if(t)return t(e);let n=e.offsetParent;return lo(e)===n&&(n=n.ownerDocument.body),n}function t6(e,t){const n=Ti(e);if(x_(e))return n;if(!no(e)){let i=_l(e);for(;i&&!Hd(i);){if(ks(i)&&!pb(i))return i;i=_l(i)}return n}let r=UO(e,t);for(;r&&Kq(r)&&pb(r);)r=UO(r,t);return r&&Hd(r)&&pb(r)&&!FC(r)?n:r||Xq(e)||n}const fK=async function(e){const t=this.getOffsetParent||t6,n=this.getDimensions,r=await n(e.floating);return{reference:dK(e.reference,await t(e.floating),e.strategy),floating:{x:0,y:0,width:r.width,height:r.height}}};function hK(e){return Ts(e).direction==="rtl"}const pK={convertOffsetParentRelativeRectToViewportRelativeRect:nK,getDocumentElement:lo,getClippingRect:cK,getOffsetParent:t6,getElementRects:fK,getClientRects:rK,getDimensions:uK,getScale:Ad,isElement:ks,isRTL:hK};function n6(e,t){return e.x===t.x&&e.y===t.y&&e.width===t.width&&e.height===t.height}function mK(e,t){let n=null,r;const i=lo(e);function s(){var a;clearTimeout(r),(a=n)==null||a.disconnect(),n=null}function o(a,c){a===void 0&&(a=!1),c===void 0&&(c=1),s();const d=e.getBoundingClientRect(),{left:f,top:p,width:m,height:v}=d;if(a||t(),!m||!v)return;const w=vy(p),_=vy(i.clientWidth-(f+m)),b=vy(i.clientHeight-(p+v)),C=vy(f),D={rootMargin:-w+"px "+-_+"px "+-b+"px "+-C+"px",threshold:Ei(0,vl(1,c))||1};let F=!0;function R(I){const k=I[0].intersectionRatio;if(k!==c){if(!F)return o();k?o(!1,k):r=setTimeout(()=>{o(!1,1e-7)},1e3)}k===1&&!n6(d,e.getBoundingClientRect())&&o(),F=!1}try{n=new IntersectionObserver(R,{...D,root:i.ownerDocument})}catch{n=new IntersectionObserver(R,D)}n.observe(e)}return o(!0),s}function gK(e,t,n,r){r===void 0&&(r={});const{ancestorScroll:i=!0,ancestorResize:s=!0,elementResize:o=typeof ResizeObserver=="function",layoutShift:a=typeof IntersectionObserver=="function",animationFrame:c=!1}=r,d=zC(e),f=i||s?[...d?Pp(d):[],...Pp(t)]:[];f.forEach(C=>{i&&C.addEventListener("scroll",n,{passive:!0}),s&&C.addEventListener("resize",n)});const p=d&&a?mK(d,n):null;let m=-1,v=null;o&&(v=new ResizeObserver(C=>{let[P]=C;P&&P.target===d&&v&&(v.unobserve(t),cancelAnimationFrame(m),m=requestAnimationFrame(()=>{var D;(D=v)==null||D.observe(t)})),n()}),d&&!c&&v.observe(d),v.observe(t));let w,_=c?Wc(e):null;c&&b();function b(){const C=Wc(e);_&&!n6(_,C)&&n(),_=C,w=requestAnimationFrame(b)}return n(),()=>{var C;f.forEach(P=>{i&&P.removeEventListener("scroll",n),s&&P.removeEventListener("resize",n)}),p?.(),(C=v)==null||C.disconnect(),v=null,c&&cancelAnimationFrame(w)}}const yK=zq,vK=Bq,_K=jq,wK=Vq,bK=Fq,zO=$q,SK=Hq,EK=(e,t,n)=>{const r=new Map,i={platform:pK,...n},s={...i.platform,_c:r};return Nq(e,t,{...i,platform:s})};var xK=typeof document<"u",CK=function(){},mv=xK?g.useLayoutEffect:CK;function Qv(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,i;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(!Qv(e[r],t[r]))return!1;return!0}if(i=Object.keys(e),n=i.length,n!==Object.keys(t).length)return!1;for(r=n;r--!==0;)if(!{}.hasOwnProperty.call(t,i[r]))return!1;for(r=n;r--!==0;){const s=i[r];if(!(s==="_owner"&&e.$$typeof)&&!Qv(e[s],t[s]))return!1}return!0}return e!==e&&t!==t}function r6(e){return typeof window>"u"?1:(e.ownerDocument.defaultView||window).devicePixelRatio||1}function BO(e,t){const n=r6(e);return Math.round(t*n)/n}function mb(e){const t=g.useRef(e);return mv(()=>{t.current=e}),t}function kK(e){e===void 0&&(e={});const{placement:t="bottom",strategy:n="absolute",middleware:r=[],platform:i,elements:{reference:s,floating:o}={},transform:a=!0,whileElementsMounted:c,open:d}=e,[f,p]=g.useState({x:0,y:0,strategy:n,placement:t,middlewareData:{},isPositioned:!1}),[m,v]=g.useState(r);Qv(m,r)||v(r);const[w,_]=g.useState(null),[b,C]=g.useState(null),P=g.useCallback(N=>{N!==I.current&&(I.current=N,_(N))},[]),D=g.useCallback(N=>{N!==k.current&&(k.current=N,C(N))},[]),F=s||w,R=o||b,I=g.useRef(null),k=g.useRef(null),L=g.useRef(f),B=c!=null,A=mb(c),V=mb(i),K=mb(d),W=g.useCallback(()=>{if(!I.current||!k.current)return;const N={placement:t,strategy:n,middleware:m};V.current&&(N.platform=V.current),EK(I.current,k.current,N).then(M=>{const E={...M,isPositioned:K.current!==!1};U.current&&!Qv(L.current,E)&&(L.current=E,b_.flushSync(()=>{p(E)}))})},[m,t,n,V,K]);mv(()=>{d===!1&&L.current.isPositioned&&(L.current.isPositioned=!1,p(N=>({...N,isPositioned:!1})))},[d]);const U=g.useRef(!1);mv(()=>(U.current=!0,()=>{U.current=!1}),[]),mv(()=>{if(F&&(I.current=F),R&&(k.current=R),F&&R){if(A.current)return A.current(F,R,W);W()}},[F,R,W,A,B]);const q=g.useMemo(()=>({reference:I,floating:k,setReference:P,setFloating:D}),[P,D]),z=g.useMemo(()=>({reference:F,floating:R}),[F,R]),x=g.useMemo(()=>{const N={position:n,left:0,top:0};if(!z.floating)return N;const M=BO(z.floating,f.x),E=BO(z.floating,f.y);return a?{...N,transform:"translate("+M+"px, "+E+"px)",...r6(z.floating)>=1.5&&{willChange:"transform"}}:{position:n,left:M,top:E}},[n,a,z.floating,f.x,f.y]);return g.useMemo(()=>({...f,update:W,refs:q,elements:z,floatingStyles:x}),[f,W,q,z,x])}const TK=e=>{function t(n){return{}.hasOwnProperty.call(n,"current")}return{name:"arrow",options:e,fn(n){const{element:r,padding:i}=typeof e=="function"?e(n):e;return r&&t(r)?r.current!=null?zO({element:r.current,padding:i}).fn(n):{}:r?zO({element:r,padding:i}).fn(n):{}}}},RK=(e,t)=>({...yK(e),options:[e,t]}),PK=(e,t)=>({...vK(e),options:[e,t]}),OK=(e,t)=>({...SK(e),options:[e,t]}),AK=(e,t)=>({..._K(e),options:[e,t]}),IK=(e,t)=>({...wK(e),options:[e,t]}),MK=(e,t)=>({...bK(e),options:[e,t]}),DK=(e,t)=>({...TK(e),options:[e,t]});var LK="Arrow",i6=g.forwardRef((e,t)=>{const{children:n,width:r=10,height:i=5,...s}=e;return j.jsx(yn.svg,{...s,ref:t,width:r,height:i,viewBox:"0 0 30 10",preserveAspectRatio:"none",children:e.asChild?n:j.jsx("polygon",{points:"0,0 30,0 15,10"})})});i6.displayName=LK;var NK=i6;function $K(e){const[t,n]=g.useState(void 0);return yl(()=>{if(e){n({width:e.offsetWidth,height:e.offsetHeight});const r=new ResizeObserver(i=>{if(!Array.isArray(i)||!i.length)return;const s=i[0];let o,a;if("borderBoxSize"in s){const c=s.borderBoxSize,d=Array.isArray(c)?c[0]:c;o=d.inlineSize,a=d.blockSize}else o=e.offsetWidth,a=e.offsetHeight;n({width:o,height:a})});return r.observe(e,{box:"border-box"}),()=>r.unobserve(e)}else n(void 0)},[e]),t}var BC="Popper",[s6,T_]=Al(BC),[jK,o6]=s6(BC),a6=e=>{const{__scopePopper:t,children:n}=e,[r,i]=g.useState(null);return j.jsx(jK,{scope:t,anchor:r,onAnchorChange:i,children:n})};a6.displayName=BC;var l6="PopperAnchor",c6=g.forwardRef((e,t)=>{const{__scopePopper:n,virtualRef:r,...i}=e,s=o6(l6,n),o=g.useRef(null),a=lr(t,o),c=g.useRef(null);return g.useEffect(()=>{const d=c.current;c.current=r?.current||o.current,d!==c.current&&s.onAnchorChange(c.current)}),r?null:j.jsx(yn.div,{...i,ref:a})});c6.displayName=l6;var HC="PopperContent",[FK,UK]=s6(HC),u6=g.forwardRef((e,t)=>{const{__scopePopper:n,side:r="bottom",sideOffset:i=0,align:s="center",alignOffset:o=0,arrowPadding:a=0,avoidCollisions:c=!0,collisionBoundary:d=[],collisionPadding:f=0,sticky:p="partial",hideWhenDetached:m=!1,updatePositionStrategy:v="optimized",onPlaced:w,..._}=e,b=o6(HC,n),[C,P]=g.useState(null),D=lr(t,le=>P(le)),[F,R]=g.useState(null),I=$K(F),k=I?.width??0,L=I?.height??0,B=r+(s!=="center"?"-"+s:""),A=typeof f=="number"?f:{top:0,right:0,bottom:0,left:0,...f},V=Array.isArray(d)?d:[d],K=V.length>0,W={padding:A,boundary:V.filter(BK),altBoundary:K},{refs:U,floatingStyles:q,placement:z,isPositioned:x,middlewareData:N}=kK({strategy:"fixed",placement:B,whileElementsMounted:(...le)=>gK(...le,{animationFrame:v==="always"}),elements:{reference:b.anchor},middleware:[RK({mainAxis:i+L,alignmentAxis:o}),c&&PK({mainAxis:!0,crossAxis:!1,limiter:p==="partial"?OK():void 0,...W}),c&&AK({...W}),IK({...W,apply:({elements:le,rects:ye,availableWidth:xe,availableHeight:be})=>{const{width:rt,height:Ue}=ye.reference,Ve=le.floating.style;Ve.setProperty("--radix-popper-available-width",`${xe}px`),Ve.setProperty("--radix-popper-available-height",`${be}px`),Ve.setProperty("--radix-popper-anchor-width",`${rt}px`),Ve.setProperty("--radix-popper-anchor-height",`${Ue}px`)}}),F&&DK({element:F,padding:a}),HK({arrowWidth:k,arrowHeight:L}),m&&MK({strategy:"referenceHidden",...W})]}),[M,E]=h6(z),O=Yo(w);yl(()=>{x&&O?.()},[x,O]);const H=N.arrow?.x,Z=N.arrow?.y,X=N.arrow?.centerOffset!==0,[te,oe]=g.useState();return yl(()=>{C&&oe(window.getComputedStyle(C).zIndex)},[C]),j.jsx("div",{ref:U.setFloating,"data-radix-popper-content-wrapper":"",style:{...q,transform:x?q.transform:"translate(0, -200%)",minWidth:"max-content",zIndex:te,"--radix-popper-transform-origin":[N.transformOrigin?.x,N.transformOrigin?.y].join(" "),...N.hide?.referenceHidden&&{visibility:"hidden",pointerEvents:"none"}},dir:e.dir,children:j.jsx(FK,{scope:n,placedSide:M,onArrowChange:R,arrowX:H,arrowY:Z,shouldHideArrow:X,children:j.jsx(yn.div,{"data-side":M,"data-align":E,..._,ref:D,style:{..._.style,animation:x?void 0:"none"}})})})});u6.displayName=HC;var d6="PopperArrow",zK={top:"bottom",right:"left",bottom:"top",left:"r
9ight"},f6=g.forwardRef(function(t,n){const{__scopePopper:r,...i}=t,s=UK(d6,r),o=zK[s.placedSide];return j.jsx("span",{ref:s.onArrowChange,style:{position:"absolute",left:s.arrowX,top:s.arrowY,[o]:0,transformOrigin:{top:"",right:"0 0",bottom:"center 0",left:"100% 0"}[s.placedSide],transform:{top:"translateY(100%)",right:"translateY(50%) rotate(90deg) translateX(-50%)",bottom:"rotate(180deg)",left:"translateY(50%) rotate(-90deg) translateX(50%)"}[s.placedSide],visibility:s.shouldHideArrow?"hidden":void 0},children:j.jsx(NK,{...i,ref:n,style:{...i.style,display:"block"}})})});f6.displayName=d6;function BK(e){return e!==null}var HK=e=>({name:"transformOrigin",options:e,fn(t){const{placement:n,rects:r,middlewareData:i}=t,o=i.arrow?.centerOffset!==0,a=o?0:e.arrowWidth,c=o?0:e.arrowHeight,[d,f]=h6(n),p={start:"0%",center:"50%",end:"100%"}[f],m=(i.arrow?.x??0)+a/2,v=(i.arrow?.y??0)+c/2;let w="",_="";return d==="bottom"?(w=o?p:`${m}px`,_=`${-c}px`):d==="top"?(w=o?p:`${m}px`,_=`${r.floating.height+c}px`):d==="right"?(w=`${-c}px`,_=o?p:`${v}px`):d==="left"&&(w=`${r.floating.width+c}px`,_=o?p:`${v}px`),{data:{x:w,y:_}}}});function h6(e){const[t,n="center"]=e.split("-");return[t,n]}var p6=a6,m6=c6,g6=u6,y6=f6,VK="Portal",R_=g.forwardRef((e,t)=>{const{container:n,...r}=e,[i,s]=g.useState(!1);yl(()=>s(!0),[]);const o=n||i&&globalThis?.document?.body;return o?aq.createPortal(j.jsx(yn.div,{...r,ref:t}),o):null});R_.displayName=VK;function WK(e,t){return g.useReducer((n,r)=>t[n][r]??n,e)}var co=e=>{const{present:t,children:n}=e,r=qK(t),i=typeof n=="function"?n({present:r.isPresent}):g.Children.only(n),s=lr(r.ref,KK(i));return typeof n=="function"||r.isPresent?g.cloneElement(i,{ref:s}):null};co.displayName="Presence";function qK(e){const[t,n]=g.useState(),r=g.useRef(null),i=g.useRef(e),s=g.useRef("none"),o=e?"mounted":"unmounted",[a,c]=WK(o,{mounted:{UNMOUNT:"unmounted",ANIMATION_OUT:"unmountSuspended"},unmountSuspended:{MOUNT:"mounted",ANIMATION_END:"unmounted"},unmounted:{MOUNT:"mounted"}});return g.useEffect(()=>{const d=_y(r.current);s.current=a==="mounted"?d:"none"},[a]),yl(()=>{const d=r.current,f=i.current;if(f!==e){const m=s.current,v=_y(d);e?c("MOUNT"):v==="none"||d?.display==="none"?c("UNMOUNT"):c(f&&m!==v?"ANIMATION_OUT":"UNMOUNT"),i.current=e}},[e,c]),yl(()=>{if(t){let d;const f=t.ownerDocument.defaultView??window,p=v=>{const _=_y(r.current).includes(CSS.escape(v.animationName));if(v.target===t&&_&&(c("ANIMATION_END"),!i.current)){const b=t.style.animationFillMode;t.style.animationFillMode="forwards",d=f.setTimeout(()=>{t.style.animationFillMode==="forwards"&&(t.style.animationFillMode=b)})}},m=v=>{v.target===t&&(s.current=_y(r.current))};return t.addEventListener("animationstart",m),t.addEventListener("animationcancel",p),t.addEventListener("animationend",p),()=>{f.clearTimeout(d),t.removeEventListener("animationstart",m),t.removeEventListener("animationcancel",p),t.removeEventListener("animationend",p)}}else c("ANIMATION_END")},[t,c]),{isPresent:["mounted","unmountSuspended"].includes(a),ref:g.useCallback(d=>{r.current=d?getComputedStyle(d):null,n(d)},[])}}function _y(e){return e?.animationName||"none"}function KK(e){let t=Object.getOwnPropertyDescriptor(e.props,"ref")?.get,n=t&&"isReactWarning"in t&&t.isReactWarning;return n?e.ref:(t=Object.getOwnPropertyDescriptor(e,"ref")?.get,n=t&&"isReactWarning"in t&&t.isReactWarning,n?e.props.ref:e.props.ref||e.ref)}var GK=Symbol("radix.slottable");function YK(e){const t=({children:n})=>j.jsx(j.Fragment,{children:n});return t.displayName=`${e}.Slottable`,t.__radixId=GK,t}var JK=w_[" useInsertionEffect ".trim().toString()]||yl;function du({prop:e,defaultProp:t,onChange:n=()=>{},caller:r}){const[i,s,o]=ZK({defaultProp:t,onChange:n}),a=e!==void 0,c=a?e:i;{const f=g.useRef(e!==void 0);g.useEffect(()=>{const p=f.current;p!==a&&console.warn(`${r} is changing from ${p?"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.`),f.current=a},[a,r])}const d=g.useCallback(f=>{if(a){const p=XK(f)?f(e):f;p!==e&&o.current?.(p)}else s(f)},[a,e,s,o]);return[c,d]}function ZK({defaultProp:e,onChange:t}){const[n,r]=g.useState(e),i=g.useRef(n),s=g.useRef(t);return JK(()=>{s.current=t},[t]),g.useEffect(()=>{i.current!==n&&(s.current?.(n),i.current=n)},[n,i]),[n,r,s]}function XK(e){return typeof e=="function"}var QK=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"}
vendor: 4,285 bytes, line 9
9),eG="VisuallyHidden",v6=g.forwardRef((e,t)=>j.jsx(yn.span,{...e,ref:t,style:{...QK,...e.style}}));v6.displayName=eG;var tG=v6,[P_]=Al("Tooltip",[T_]),O_=T_(),_6="TooltipProvider",nG=700,$E="tooltip.open",[rG,VC]=P_(_6),w6=e=>{const{__scopeTooltip:t,delayDuration:n=nG,skipDelayDuration:r=300,disableHoverableContent:i=!1,children:s}=e,o=g.useRef(!0),a=g.useRef(!1),c=g.useRef(0);return g.useEffect(()=>{const d=c.current;return()=>window.clearTimeout(d)},[]),j.jsx(rG,{scope:t,isOpenDelayedRef:o,delayDuration:n,onOpen:g.useCallback(()=>{window.clearTimeout(c.current),o.current=!1},[]),onClose:g.useCallback(()=>{window.clearTimeout(c.current),c.current=window.setTimeout(()=>o.current=!0,r)},[r]),isPointerInTransitRef:a,onPointerInTransitChange:g.useCallback(d=>{a.current=d},[]),disableHoverableContent:i,children:s})};w6.displayName=_6;var Op="Tooltip",[iG,ym]=P_(Op),b6=e=>{const{__scopeTooltip:t,children:n,open:r,defaultOpen:i,onOpenChange:s,disableHoverableContent:o,delayDuration:a}=e,c=VC(Op,e.__scopeTooltip),d=O_(t),[f,p]=g.useState(null),m=Lc(),v=g.useRef(0),w=o??c.disableHoverableContent,_=a??c.delayDuration,b=g.useRef(!1),[C,P]=du({prop:r,defaultProp:i??!1,onChange:k=>{k?(c.onOpen(),document.dispatchEvent(new CustomEvent($E))):c.onClose(),s?.(k)},caller:Op}),D=g.useMemo(()=>C?b.current?"delayed-open":"instant-open":"closed",[C]),F=g.useCallback(()=>{window.clearTimeout(v.current),v.current=0,b.current=!1,P(!0)},[P]),R=g.useCallback(()=>{window.clearTimeout(v.current),v.current=0,P(!1)},[P]),I=g.useCallback(()=>{window.clearTimeout(v.current),v.current=window.setTimeout(()=>{b.current=!0,P(!0),v.current=0},_)},[_,P]);return g.useEffect(()=>()=>{v.current&&(window.clearTimeout(v.current),v.current=0)},[]),j.jsx(p6,{...d,children:j.jsx(iG,{scope:t,contentId:m,open:C,stateAttribute:D,trigger:f,onTriggerChange:p,onTriggerEnter:g.useCallback(()=>{c.isOpenDelayedRef.current?I():F()},[c.isOpenDelayedRef,I,F]),onTriggerLeave:g.useCallback(()=>{w?R():(window.clearTimeout(v.current),v.current=0)},[R,w]),onOpen:F,onClose:R,disableHoverableContent:w,children:n})})};b6.displayName=Op;var jE="TooltipTrigger",S6=g.forwardRef((e,t)=>{const{__scopeTooltip:n,...r}=e,i=ym(jE,n),s=VC(jE,n),o=O_(n),a=g.useRef(null),c=lr(t,a,i.onTriggerChange),d=g.useRef(!1),f=g.useRef(!1),p=g.useCallback(()=>d.current=!1,[]);return g.useEffect(()=>()=>document.removeEventListener("pointerup",p),[p]),j.jsx(m6,{asChild:!0,...o,children:j.jsx(yn.button,{"aria-describedby":i.open?i.contentId:void 0,"data-state":i.stateAttribute,...r,ref:c,onPointerMove:gt(e.onPointerMove,m=>{m.pointerType!=="touch"&&!f.current&&!s.isPointerInTransitRef.current&&(i.onTriggerEnter(),f.current=!0)}),onPointerLeave:gt(e.onPointerLeave,()=>{i.onTriggerLeave(),f.current=!1}),onPointerDown:gt(e.onPointerDown,()=>{i.open&&i.onClose(),d.current=!0,document.addEventListener("pointerup",p,{once:!0})}),onFocus:gt(e.onFocus,()=>{d.current||i.onOpen()}),onBlur:gt(e.onBlur,i.onClose),onClick:gt(e.onClick,i.onClose)})})});S6.displayName=jE;var WC="TooltipPortal",[sG,oG]=P_(WC,{forceMount:void 0}),E6=e=>{const{__scopeTooltip:t,forceMount:n,children:r,container:i}=e,s=ym(WC,t);return j.jsx(sG,{scope:t,forceMount:n,children:j.jsx(co,{present:n||s.open,children:j.jsx(R_,{asChild:!0,container:i,children:r})})})};E6.displayName=WC;var Vd="TooltipContent",x6=g.forwardRef((e,t)=>{const n=oG(Vd,e.__scopeTooltip),{forceMount:r=n.forceMount,side:i="top",...s}=e,o=ym(Vd,e.__scopeTooltip);return j.jsx(co,{present:r||o.open,children:o.disableHoverableContent?j.jsx(C6,{side:i,...s,ref:t}):j.jsx(aG,{side:i,...s,ref:t})})}),aG=g.forwardRef((e,t)=>{const n=ym(Vd,e.__scopeTooltip),r=VC(Vd,e.__scopeTooltip),i=g.useRef(null),s=lr(t,i),[o,a]=g.useState(null),{trigger:c,onClose:d}=n,f=i.current,{onPointerInTransitChange:p}=r,m=g.useCallback(()=>{a(null),p(!1)},[p]),v=g.useCallback((w,_)=>{const b=w.currentTarget,C={x:w.clientX,y:w.clientY},P=dG(C,b.getBoundingClientRect()),D=fG(C,P),F=hG(_.getBoundingClientRect()),R=mG([...D,...F]);a(R),p(!0)},[p]);return g.useEffect(()=>()=>m(),[m]),g.useEffect(()=>{if(c&&f){const w=b=>v(b,f),_=b=>v(b,c);return c.addEventListener("pointerleave",w),f.addEventListener("pointerleave",_),()=>{c.removeEventListener("pointerleave",w),f.removeEventListener("pointerleave",_)}
vendor: 4,321 bytes, line 9
9}},[c,f,v,m]),g.useEffect(()=>{if(o){const w=_=>{const b=_.target,C={x:_.clientX,y:_.clientY},P=c?.contains(b)||f?.contains(b),D=!pG(C,o);P?m():D&&(m(),d())};return document.addEventListener("pointermove",w),()=>document.removeEventListener("pointermove",w)}},[c,f,o,d,m]),j.jsx(C6,{...e,ref:s})}),[lG,cG]=P_(Op,{isInside:!1}),uG=YK("TooltipContent"),C6=g.forwardRef((e,t)=>{const{__scopeTooltip:n,children:r,"aria-label":i,onEscapeKeyDown:s,onPointerDownOutside:o,...a}=e,c=ym(Vd,n),d=O_(n),{onClose:f}=c;return g.useEffect(()=>(document.addEventListener($E,f),()=>document.removeEventListener($E,f)),[f]),g.useEffect(()=>{if(c.trigger){const p=m=>{m.target?.contains(c.trigger)&&f()};return window.addEventListener("scroll",p,{capture:!0}),()=>window.removeEventListener("scroll",p,{capture:!0})}},[c.trigger,f]),j.jsx(S_,{asChild:!0,disableOutsidePointerEvents:!1,onEscapeKeyDown:s,onPointerDownOutside:o,onFocusOutside:p=>p.preventDefault(),onDismiss:f,children:j.jsxs(g6,{"data-state":c.stateAttribute,...d,...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:[j.jsx(uG,{children:r}),j.jsx(lG,{scope:n,isInside:!0,children:j.jsx(tG,{id:c.contentId,role:"tooltip",children:i||r})})]})})});x6.displayName=Vd;var k6="TooltipArrow",T6=g.forwardRef((e,t)=>{const{__scopeTooltip:n,...r}=e,i=O_(n);return cG(k6,n).isInside?null:j.jsx(y6,{...i,...r,ref:t})});T6.displayName=k6;function dG(e,t){const n=Math.abs(t.top-e.y),r=Math.abs(t.bottom-e.y),i=Math.abs(t.right-e.x),s=Math.abs(t.left-e.x);switch(Math.min(n,r,i,s)){case s:return"left";case i:return"right";case n:return"top";case r:return"bottom";default:throw new Error("unreachable")}}function fG(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 hG(e){const{top:t,right:n,bottom:r,left:i}=e;return[{x:i,y:t},{x:n,y:t},{x:n,y:r},{x:i,y:r}]}function pG(e,t){const{x:n,y:r}=e;let i=!1;for(let s=0,o=t.length-1;s<t.length;o=s++){const a=t[s],c=t[o],d=a.x,f=a.y,p=c.x,m=c.y;f>r!=m>r&&n<(p-d)*(r-f)/(m-f)+d&&(i=!i)}return i}function mG(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),gG(t)}function gG(e){if(e.length<=1)return e.slice();const t=[];for(let r=0;r<e.length;r++){const i=e[r];for(;t.length>=2;){const s=t[t.length-1],o=t[t.length-2];if((s.x-o.x)*(i.y-o.y)>=(s.y-o.y)*(i.x-o.x))t.pop();else break}t.push(i)}t.pop();const n=[];for(let r=e.length-1;r>=0;r--){const i=e[r];for(;n.length>=2;){const s=n[n.length-1],o=n[n.length-2];if((s.x-o.x)*(i.y-o.y)>=(s.y-o.y)*(i.x-o.x))n.pop();else break}n.push(i)}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 yG=w6,HO=b6,R6=S6,vG=E6,P6=x6,_G=T6;function O6(e){var t,n,r="";if(typeof e=="string"||typeof e=="number")r+=e;else if(typeof e=="object")if(Array.isArray(e)){var i=e.length;for(t=0;t<i;t++)e[t]&&(n=O6(e[t]))&&(r&&(r+=" "),r+=n)}else for(n in e)e[n]&&(r&&(r+=" "),r+=n);return r}function wG(){for(var e,t,n=0,r="",i=arguments.length;n<i;n++)(e=arguments[n])&&(t=O6(e))&&(r&&(r+=" "),r+=t);return r}const qC="-",bG=e=>{const t=EG(e),{conflictingClassGroups:n,conflictingClassGroupModifiers:r}=e;return{getClassGroupId:o=>{const a=o.split(qC);return a[0]===""&&a.length!==1&&a.shift(),A6(a,t)||SG(o)},getConflictingClassGroupIds:(o,a)=>{const c=n[o]||[];return a&&r[o]?[...c,...r[o]]:c}}},A6=(e,t)=>{if(e.length===0)return t.classGroupId;const n=e[0],r=t.nextPart.get(n),i=r?A6(e.slice(1),r):void 0;if(i)return i;if(t.validators.length===0)return;const s=e.join(qC);return t.validators.find(({validator:o})=>o(s))?.classGroupId},VO=/^\[(.+)\]$/,SG=e=>{if(VO.test(e)){const t=VO.exec(e)[1],n=t?.substring(0,t.indexOf(":"));if(n)return"arbitrary.."+n}},EG=e=>{const{theme:t,prefix:n}=e,r={nextPart:new Map,validators:[]};
vendor: 11,463 bytes, line 9
9return CG(Object.entries(e.classGroups),n).forEach(([s,o])=>{FE(o,r,s,t)}),r},FE=(e,t,n,r)=>{e.forEach(i=>{if(typeof i=="string"){const s=i===""?t:WO(t,i);s.classGroupId=n;return}if(typeof i=="function"){if(xG(i)){FE(i(r),t,n,r);return}t.validators.push({validator:i,classGroupId:n});return}Object.entries(i).forEach(([s,o])=>{FE(o,WO(t,s),n,r)})})},WO=(e,t)=>{let n=e;return t.split(qC).forEach(r=>{n.nextPart.has(r)||n.nextPart.set(r,{nextPart:new Map,validators:[]}),n=n.nextPart.get(r)}),n},xG=e=>e.isThemeGetter,CG=(e,t)=>t?e.map(([n,r])=>{const i=r.map(s=>typeof s=="string"?t+s:typeof s=="object"?Object.fromEntries(Object.entries(s).map(([o,a])=>[t+o,a])):s);return[n,i]}):e,kG=e=>{if(e<1)return{get:()=>{},set:()=>{}};let t=0,n=new Map,r=new Map;const i=(s,o)=>{n.set(s,o),t++,t>e&&(t=0,r=n,n=new Map)};return{get(s){let o=n.get(s);if(o!==void 0)return o;if((o=r.get(s))!==void 0)return i(s,o),o},set(s,o){n.has(s)?n.set(s,o):i(s,o)}}},I6="!",TG=e=>{const{separator:t,experimentalParseClassName:n}=e,r=t.length===1,i=t[0],s=t.length,o=a=>{const c=[];let d=0,f=0,p;for(let b=0;b<a.length;b++){let C=a[b];if(d===0){if(C===i&&(r||a.slice(b,b+s)===t)){c.push(a.slice(f,b)),f=b+s;continue}if(C==="/"){p=b;continue}}C==="["?d++:C==="]"&&d--}const m=c.length===0?a:a.substring(f),v=m.startsWith(I6),w=v?m.substring(1):m,_=p&&p>f?p-f:void 0;return{modifiers:c,hasImportantModifier:v,baseClassName:w,maybePostfixModifierPosition:_}};return n?a=>n({className:a,parseClassName:o}):o},RG=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},PG=e=>({cache:kG(e.cacheSize),parseClassName:TG(e),...bG(e)}),OG=/\s+/,AG=(e,t)=>{const{parseClassName:n,getClassGroupId:r,getConflictingClassGroupIds:i}=t,s=[],o=e.trim().split(OG);let a="";for(let c=o.length-1;c>=0;c-=1){const d=o[c],{modifiers:f,hasImportantModifier:p,baseClassName:m,maybePostfixModifierPosition:v}=n(d);let w=!!v,_=r(w?m.substring(0,v):m);if(!_){if(!w){a=d+(a.length>0?" "+a:a);continue}if(_=r(m),!_){a=d+(a.length>0?" "+a:a);continue}w=!1}const b=RG(f).join(":"),C=p?b+I6:b,P=C+_;if(s.includes(P))continue;s.push(P);const D=i(_,w);for(let F=0;F<D.length;++F){const R=D[F];s.push(C+R)}a=d+(a.length>0?" "+a:a)}return a};function IG(){let e=0,t,n,r="";for(;e<arguments.length;)(t=arguments[e++])&&(n=M6(t))&&(r&&(r+=" "),r+=n);return r}const M6=e=>{if(typeof e=="string")return e;let t,n="";for(let r=0;r<e.length;r++)e[r]&&(t=M6(e[r]))&&(n&&(n+=" "),n+=t);return n};function MG(e,...t){let n,r,i,s=o;function o(c){const d=t.reduce((f,p)=>p(f),e());return n=PG(d),r=n.cache.get,i=n.cache.set,s=a,a(c)}function a(c){const d=r(c);if(d)return d;const f=AG(c,n);return i(c,f),f}return function(){return s(IG.apply(null,arguments))}}const pn=e=>{const t=n=>n[e]||[];return t.isThemeGetter=!0,t},D6=/^\[(?:([a-z-]+):)?(.+)\]$/i,DG=/^\d+\/\d+$/,LG=new Set(["px","full","screen"]),NG=/^(\d+(\.\d+)?)?(xs|sm|md|lg|xl)$/,$G=/\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$/,jG=/^(rgba?|hsla?|hwb|(ok)?(lab|lch))\(.+\)$/,FG=/^(inset_)?-?((\d+)?\.?(\d+)[a-z]+|0)_-?((\d+)?\.?(\d+)[a-z]+|0)/,UG=/^(url|image|image-set|cross-fade|element|(repeating-)?(linear|radial|conic)-gradient)\(.+\)$/,xo=e=>Id(e)||LG.has(e)||DG.test(e),Na=e=>mf(e,"length",GG),Id=e=>!!e&&!Number.isNaN(Number(e)),gb=e=>mf(e,"number",Id),Sh=e=>!!e&&Number.isInteger(Number(e)),zG=e=>e.endsWith("%")&&Id(e.slice(0,-1)),St=e=>D6.test(e),$a=e=>NG.test(e),BG=new Set(["length","size","percentage"]),HG=e=>mf(e,BG,L6),VG=e=>mf(e,"position",L6),WG=new Set(["image","url"]),qG=e=>mf(e,WG,JG),KG=e=>mf(e,"",YG),Eh=()=>!0,mf=(e,t,n)=>{const r=D6.exec(e);return r?r[1]?typeof t=="string"?r[1]===t:t.has(r[1]):n(r[2]):!1},GG=e=>$G.test(e)&&!jG.test(e),L6=()=>!1,YG=e=>FG.test(e),JG=e=>UG.test(e),ZG=()=>{const e=pn("colors"),t=pn("spacing"),n=pn("blur"),r=pn("brightness"),i=pn("borderColor"),s=pn("borderRadius"),o=pn("borderSpacing"),a=pn("borderWidth"),c=pn("contrast"),d=pn("grayscale"),f=pn("hueRotate"),p=pn("invert"),m=pn("gap"),v=pn("gradientColorStops"),w=pn("gradientColorStopPositions"),_=pn("inset"),b=pn("margin"),C=pn("opacity"),P=pn("padding"),D=pn("saturate"),F=pn("scale"),R=pn("sepia"),I=pn("skew"),k=pn("space"),L=pn("translate"),B=()=>["auto","contain","none"],A=()=>["auto","hidden","clip","visible","scroll"],V=()=>["auto",St,t],K=()=>[St,t],W=()=>["",xo,Na],U=()=>["auto",Id,St],q=()=>["bottom","center","left","left-bottom","left-top","right","right-bottom","right-top","top"],z=()=>["solid","dashed","dotted","double","none"],x=()=>["normal","multiply","screen","overlay","darken","lighten","color-dodge","color-burn","hard-light","soft-light","difference","exclusion","hue","saturation","color","luminosity"],N=()=>["start","end","center","between","around","evenly","stretch"],M=()=>["","0",St],E=()=>["auto","avoid","all","avoid-page","page","left","right","column"],O=()=>[Id,St];return{cacheSize:500,separator:":",theme:{colors:[Eh],spacing:[xo,Na],blur:["none","",$a,St],brightness:O(),borderColor:[e],borderRadius:["none","","full",$a,St],borderSpacing:K(),borderWidth:W(),contrast:O(),grayscale:M(),hueRotate:O(),invert:M(),gap:K(),gradientColorStops:[e],gradientColorStopPositions:[zG,Na],inset:V(),margin:V(),opacity:O(),padding:K(),saturate:O(),scale:O(),sepia:M(),skew:O(),space:K(),translate:K()},classGroups:{aspect:[{aspect:["auto","square","video",St]}],container:["container"],columns:[{columns:[$a]}],"break-after":[{"break-after":E()}],"break-before":[{"break-before":E()}],"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:[...q(),St]}],overflow:[{overflow:A()}],"overflow-x":[{"overflow-x":A()}],"overflow-y":[{"overflow-y":A()}],overscroll:[{overscroll:B()}],"overscroll-x":[{"overscroll-x":B()}],"overscroll-y":[{"overscroll-y":B()}],position:["static","fixed","absolute","relative","sticky"],inset:[{inset:[_]}],"inset-x":[{"inset-x":[_]}],"inset-y":[{"inset-y":[_]}],start:[{start:[_]}],end:[{end:[_]}],top:[{top:[_]}],right:[{right:[_]}],bottom:[{bottom:[_]}],left:[{left:[_]}],visibility:["visible","invisible","collapse"],z:[{z:["auto",Sh,St]}],basis:[{basis:V()}],"flex-direction":[{flex:["row","row-reverse","col","col-reverse"]}],"flex-wrap":[{flex:["wrap","wrap-reverse","nowrap"]}],flex:[{flex:["1","auto","initial","none",St]}],grow:[{grow:M()}],shrink:[{shrink:M()}],order:[{order:["first","last","none",Sh,St]}],"grid-cols":[{"grid-cols":[Eh]}],"col-start-end":[{col:["auto",{span:["full",Sh,St]},St]}],"col-start":[{"col-start":U()}],"col-end":[{"col-end":U()}],"grid-rows":[{"grid-rows":[Eh]}],"row-start-end":[{row:["auto",{span:[Sh,St]},St]}],"row-start":[{"row-start":U()}],"row-end":[{"row-end":U()}],"grid-flow":[{"grid-flow":["row","col","dense","row-dense","col-dense"]}],"auto-cols":[{"auto-cols":["auto","min","max","fr",St]}],"auto-rows":[{"auto-rows":["auto","min","max","fr",St]}],gap:[{gap:[m]}],"gap-x":[{"gap-x":[m]}],"gap-y":[{"gap-y":[m]}],"justify-content":[{justify:["normal",...N()]}],"justify-items":[{"justify-items":["start","end","center","stretch"]}],"justify-self":[{"justify-self":["auto","start","end","center","stretch"]}],"align-content":[{content:["normal",...N(),"baseline"]}],"align-items":[{items:["start","end","center","baseline","stretch"]}],"align-self":[{self:["auto","start","end","center","stretch","baseline"]}],"place-content":[{"place-content":[...N(),"baseline"]}],"place-items":[{"place-items":["start","end","center","baseline","stretch"]}],"place-self":[{"place-self":["auto","start","end","center","stretch"]}],p:[{p:[P]}],px:[{px:[P]}],py:[{py:[P]}],ps:[{ps:[P]}],pe:[{pe:[P]}],pt:[{pt:[P]}],pr:[{pr:[P]}],pb:[{pb:[P]}],pl:[{pl:[P]}],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":[k]}],"space-x-reverse":["space-x-reverse"],"space-y":[{"space-y":[k]}],"space-y-reverse":["space-y-reverse"],w:[{w:["auto","min","max","fit","svw","lvw","dvw",St,t]}],"min-w":[{"min-w":[St,t,"min","max","fit"]}],"max-w":[{"max-w":[St,t,"none","full","min","max","fit","prose",{screen:[$a]},$a]}],h:[{h:[St,t,"auto","min","max","fit","svh","lvh","dvh"]}],"min-h":[{"min-h":[St,t,"min","max","fit","svh","lvh","dvh"]}],"max-h":[{"max-h":[St,t,"min","max","fit","svh","lvh","dvh"]}],size:[{size:[St,t,"auto","min","max","fit"]}],"font-size":[{text:["base",$a,Na]}],"font-smoothing":["antialiased","subpixel-antialiased"],"font-style":["italic","not-italic"],"font-weight":[{font:["thin","extralight","light","normal","medium","semibold","bold","extrabold","black",gb]}],"font-family":[{font:[Eh]}],"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",St]}],"line-clamp":[{"line-clamp":["none",Id,gb]}],leading:[{leading:["none","tight","snug","normal","relaxed","loose",xo,St]}],"list-image":[{"list-image":["none",St]}],"list-style-type":[{list:["none","disc","decimal",St]}],"list-style-position":[{list:["inside","outside"]}],"placeholder-color":[{placeholder:[e]}],"placeholder-opacity":[{"placeholder-opacity":[C]}],"text-alignment":[{text:["left","center","right","justify","start","end"]}],"text-color":[{text:[e]}],"text-opacity":[{"text-opacity":[C]}],"text-decoration":["underline","overline","line-through","no-underline"],"text-decoration-style":[{decoration:[...z(),"wavy"]}],"text-decoration-thickness":[{decoration:["auto","from-font",xo,Na]}],"underline-offset":[{"underline-offset":["auto",xo,St]}],"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:K()}],"vertical-align":[{align:["baseline","top","middle","bottom","text-top","text-bottom","sub","super",St]}],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",St]}],"bg-attachment":[{bg:["fixed","local","scroll"]}],"bg-clip":[{"bg-clip":["border","padding","content","text"]}],"bg-opacity":[{"bg-opacity":[C]}],"bg-origin":[{"bg-origin":["border","padding","content"]}],"bg-position":[{bg:[...q(),VG]}],"bg-repeat":[{bg:["no-repeat",{repeat:["","x","y","round","space"]}]}],"bg-size":[{bg:["auto","cover","contain",HG]}],"bg-image":[{bg:["none",{"gradient-to":["t","tr","r","br","b","bl","l","tl"]},qG]}],"bg-color":[{bg:[e]}],"gradient-from-pos":[{from:[w]}
vendor: 5,180 bytes, line 9
9],"gradient-via-pos":[{via:[w]}],"gradient-to-pos":[{to:[w]}],"gradient-from":[{from:[v]}],"gradient-via":[{via:[v]}],"gradient-to":[{to:[v]}],rounded:[{rounded:[s]}],"rounded-s":[{"rounded-s":[s]}],"rounded-e":[{"rounded-e":[s]}],"rounded-t":[{"rounded-t":[s]}],"rounded-r":[{"rounded-r":[s]}],"rounded-b":[{"rounded-b":[s]}],"rounded-l":[{"rounded-l":[s]}],"rounded-ss":[{"rounded-ss":[s]}],"rounded-se":[{"rounded-se":[s]}],"rounded-ee":[{"rounded-ee":[s]}],"rounded-es":[{"rounded-es":[s]}],"rounded-tl":[{"rounded-tl":[s]}],"rounded-tr":[{"rounded-tr":[s]}],"rounded-br":[{"rounded-br":[s]}],"rounded-bl":[{"rounded-bl":[s]}],"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":[C]}],"border-style":[{border:[...z(),"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":[C]}],"divide-style":[{divide:z()}],"border-color":[{border:[i]}],"border-color-x":[{"border-x":[i]}],"border-color-y":[{"border-y":[i]}],"border-color-s":[{"border-s":[i]}],"border-color-e":[{"border-e":[i]}],"border-color-t":[{"border-t":[i]}],"border-color-r":[{"border-r":[i]}],"border-color-b":[{"border-b":[i]}],"border-color-l":[{"border-l":[i]}],"divide-color":[{divide:[i]}],"outline-style":[{outline:["",...z()]}],"outline-offset":[{"outline-offset":[xo,St]}],"outline-w":[{outline:[xo,Na]}],"outline-color":[{outline:[e]}],"ring-w":[{ring:W()}],"ring-w-inset":["ring-inset"],"ring-color":[{ring:[e]}],"ring-opacity":[{"ring-opacity":[C]}],"ring-offset-w":[{"ring-offset":[xo,Na]}],"ring-offset-color":[{"ring-offset":[e]}],shadow:[{shadow:["","inner","none",$a,KG]}],"shadow-color":[{shadow:[Eh]}],opacity:[{opacity:[C]}],"mix-blend":[{"mix-blend":[...x(),"plus-lighter","plus-darker"]}],"bg-blend":[{"bg-blend":x()}],filter:[{filter:["","none"]}],blur:[{blur:[n]}],brightness:[{brightness:[r]}],contrast:[{contrast:[c]}],"drop-shadow":[{"drop-shadow":["","none",$a,St]}],grayscale:[{grayscale:[d]}],"hue-rotate":[{"hue-rotate":[f]}],invert:[{invert:[p]}],saturate:[{saturate:[D]}],sepia:[{sepia:[R]}],"backdrop-filter":[{"backdrop-filter":["","none"]}],"backdrop-blur":[{"backdrop-blur":[n]}],"backdrop-brightness":[{"backdrop-brightness":[r]}],"backdrop-contrast":[{"backdrop-contrast":[c]}],"backdrop-grayscale":[{"backdrop-grayscale":[d]}],"backdrop-hue-rotate":[{"backdrop-hue-rotate":[f]}],"backdrop-invert":[{"backdrop-invert":[p]}],"backdrop-opacity":[{"backdrop-opacity":[C]}],"backdrop-saturate":[{"backdrop-saturate":[D]}],"backdrop-sepia":[{"backdrop-sepia":[R]}],"border-collapse":[{border:["collapse","separate"]}],"border-spacing":[{"border-spacing":[o]}],"border-spacing-x":[{"border-spacing-x":[o]}],"border-spacing-y":[{"border-spacing-y":[o]}],"table-layout":[{table:["auto","fixed"]}],caption:[{caption:["top","bottom"]}],transition:[{transition:["none","all","","colors","opacity","shadow","transform",St]}],duration:[{duration:O()}],ease:[{ease:["linear","in","out","in-out",St]}],delay:[{delay:O()}],animate:[{animate:["none","spin","ping","pulse","bounce",St]}],transform:[{transform:["","gpu","none"]}],scale:[{scale:[F]}],"scale-x":[{"scale-x":[F]}],"scale-y":[{"scale-y":[F]}],rotate:[{rotate:[Sh,St]}],"translate-x":[{"translate-x":[L]}],"translate-y":[{"translate-y":[L]}],"skew-x":[{"skew-x":[I]}],"skew-y":[{"skew-y":[I]}],"transform-origin":[{origin:["center","top","top-right","right","bottom-right","bottom","bottom-left","left","top-left",St]}],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",St]}],"caret-color":[{caret:[e]}],"pointer-events":[{"pointer-events":["none","auto"]}],resize:[{resize:["none","y","x",""]}],"scroll-behavior":[{scroll:["auto","smooth"]}],"scroll-m":[{"scroll-m":K()}],"scroll-mx":[{"scroll-mx":K()}],"scroll-my":[{"scroll-my":K()}],"scroll-ms":[{"scroll-ms":K()}],"scroll-me":[{"scroll-me":K()}],"scroll-mt":[{"scroll-mt":K()}],"scroll-mr":[{"scroll-mr":K()}],"scroll-mb":[{"scroll-mb":K()}],"scroll-ml":[{"scroll-ml":K()}],"scroll-p":[{"scroll-p":K()}],"scroll-px":[{"scroll-px":K()}],"scroll-py":[{"scroll-py":K()}],"scroll-ps":[{"scroll-ps":K()}],"scroll-pe":[{"scroll-pe":K()}],"scroll-pt":[{"scroll-pt":K()}],"scroll-pr":[{"scroll-pr":K()}],"scroll-pb":[{"scroll-pb":K()}],"scroll-pl":[{"scroll-pl":K()}],"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"]}
9],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",St]}],fill:[{fill:[e,"none"]}],"stroke-w":[{stroke:[xo,Na,gb]}],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"]}}},XG=MG(ZG);function sn(...e){return XG(wG(...e))}const ac={sm:640,md:768,lg:1024,xl:1280,"2xl":1536},N6=g.createContext({screen:"sm",screenWidth:0,isMobile:!1}),QG=({children:e})=>{const[t,n]=g.useState("sm"),[r,i]=g.useState(window.innerWidth),[s,o]=g.useState(window.innerWidth<ac.lg);return g.useEffect(()=>{const a=()=>{const c=window.innerWidth;i(c),c>=ac["2xl"]?n("2xl"):c>=ac.xl?n("xl"):c>=ac.lg?n("lg"):c>=ac.md?n("md"):(c>=ac.sm,n("sm")),o(c<ac.lg)};return a(),window.addEventListener("resize",a),()=>window.removeEventListener("resize",a)},[]),j.jsx(N6.Provider,{value:{screen:t,screenWidth:r,isMobile:s},children:e})},A_=()=>g.useContext(N6),eY=yG,b3e=_G,tY=g.forwardRef(({className:e,sideOffset:t=4,...n},r)=>j.jsx(vG,{children:j.jsx(P6,{ref:r,side:"top",sideOffset:t,className:sn("z-[9999] px-3 py-2 text-sm font-medium text-white bg-navy-blue rounded-[10px] pointer-events-none origin-[--radix-tooltip-content-transform-origin]","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})}));tY.displayName=P6.displayName;const nY=g.forwardRef(({children:e,...t})=>{const{isMobile:n}=A_(),[r,i]=g.useState(!1),s=g.useRef(null),o=a=>{s.current=a;const c=e?.ref;c&&(typeof c=="function"?c(a):c.current!==void 0&&(c.current=a))};return g.useEffect(()=>{if(!n)return;const a=d=>{if(!r)return;const f=d.target;f.closest("[data-radix-tooltip-trigger]")||f.closest("[data-radix-tooltip-content]")||i(!1)},c=setTimeout(()=>{document.addEventListener("click",a)},100);return()=>{clearTimeout(c),document.removeEventListener("click",a)}},[n,r]),n?j.jsx(HO,{open:r,onOpenChange:()=>{},delayDuration:0,disableHoverableContent:!0,...t,children:g.Children.map(e,a=>{if(g.isValidElement(a)&&a.type===$6){const c=a.props;return g.cloneElement(a,{ref:o,onClick:d=>{d.preventDefault(),d.stopPropagation(),i(f=>!f),c.onClick?.(d)},onPointerDown:d=>{d.preventDefault(),c.onPointerDown?.(d)}})}return a})}):j.jsx(HO,{...t,children:e})});nY.displayName="Tooltip";const $6=g.forwardRef(({onClick:e,...t},n)=>j.jsx(R6,{ref:n,onClick:e,"data-radix-tooltip-trigger":!0,...t}));$6.displayName=R6.displayName;
9var UE=function(e,t){return UE=Object.setPrototypeOf||{__proto__:[]}instanceof Array&&function(n,r){n.__proto__=r}||function(n,r){for(var i in r)Object.prototype.hasOwnProperty.call(r,i)&&(n[i]=r[i])},UE(e,t)};function rY(e,t){if(typeof t!="function"&&t!==null)throw new TypeError("Class extends value "+String(t)+" is not a constructor or null");UE(e,t);function n(){this.constructor=e}e.prototype=t===null?Object.create(t):(n.prototype=t.prototype,new n)}var gr=function(){return gr=Object.assign||function(t){for(var n,r=1,i=arguments.length;r<i;r++){n=arguments[r];for(var s in n)Object.prototype.hasOwnProperty.call(n,s)&&(t[s]=n[s])}return t},gr.apply(this,arguments)};function qO(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 i=0,r=Object.getOwnPropertySymbols(e);i<r.length;i++)t.indexOf(r[i])<0&&Object.prototype.propertyIsEnumerable.call(e,r[i])&&(n[r[i]]=e[r[i]]);return n}function ja(e,t,n,r){function i(s){return s instanceof n?s:new n(function(o){o(s)})}return new(n||(n=Promise))(function(s,o){function a(f){try{d(r.next(f))}catch(p){o(p)}}function c(f){try{d(r.throw(f))}catch(p){o(p)}}function d(f){f.done?s(f.value):i(f.value).then(a,c)}d((r=r.apply(e,t||[])).next())})}function Fa(e,t){var n={label:0,sent:function(){if(s[0]&1)throw s[1];return s[1]},trys:[],ops:[]},r,i,s,o=Object.create((typeof Iterator=="function"?Iterator:Object).prototype);return o.next=a(0),o.throw=a(1),o.return=a(2),typeof Symbol=="function"&&(o[Symbol.iterator]=function(){return this}),o;function a(d){return function(f){return c([d,f])}}function c(d){if(r)throw new TypeError("Generator is already executing.");for(;o&&(o=0,d[0]&&(n=0)),n;)try{if(r=1,i&&(s=d[0]&2?i.return:d[0]?i.throw||((s=i.return)&&s.call(i),0):i.next)&&!(s=s.call(i,d[1])).done)return s;switch(i=0,s&&(d=[d[0]&2,s.value]),d[0]){case 0:case 1:s=d;break;case 4:return n.label++,{value:d[1],done:!1};case 5:n.label++,i=d[1],d=[0];continue;case 7:d=n.ops.pop(),n.trys.pop();continue;default:if(s=n.trys,!(s=s.length>0&&s[s.length-1])&&(d[0]===6||d[0]===2)){n=0;continue}if(d[0]===3&&(!s||d[1]>s[0]&&d[1]<s[3])){n.label=d[1];break}if(d[0]===6&&n.label<s[1]){n.label=s[1],s=d;break}if(s&&n.label<s[2]){n.label=s[2],n.ops.push(d);break}s[2]&&n.ops.pop(),n.trys.pop();continue}d=t.call(e,n)}catch(f){d=[6,f],i=0}finally{r=s=0}if(d[0]&5)throw d[1];return{value:d[0]?d[1]:void 0,done:!0}}}function iY(e,t,n){for(var r=0,i=t.length,s;r<i;r++)(s||!(r in t))&&(s||(s=Array.prototype.slice.call(t,0,r)),s[r]=t[r]);return e.concat(s||Array.prototype.slice.call(t))}function ys(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"){var i=0;for(r=Object.getOwnPropertySymbols(e);i<r.length;i++)t.indexOf(r[i])<0&&Object.prototype.propertyIsEnumerable.call(e,r[i])&&(n[r[i]]=e[r[i]])}return n}const sY={timeoutInSeconds:60},j6={name:"auth0-spa-js",version:"2.16.0"},F6=()=>Date.now();let $n=class zE extends Error{constructor(t,n){super(n),this.error=t,this.error_description=n,Object.setPrototypeOf(this,zE.prototype)}static fromPayload(t){let{error:n,error_description:r}=t;return new zE(n,r)}},oY=class U6 extends $n{constructor(t,n,r){let i=arguments.length>3&&arguments[3]!==void 0?arguments[3]:null;super(t,n),this.state=r,this.appState=i,Object.setPrototypeOf(this,U6.prototype)}},aY=class z6 extends $n{constructor(t,n,r,i){let s=arguments.length>4&&arguments[4]!==void 0?arguments[4]:null;super(t,n),this.connection=r,this.state=i,this.appState=s,Object.setPrototypeOf(this,z6.prototype)}},I_=class B6 extends $n{constructor(){super("timeout","Timeout"),Object.setPrototypeOf(this,B6.prototype)}},lY=class H6 extends I_{constructor(t){super(),this.popup=t,Object.setPrototypeOf(this,H6.prototype)}},cY=class V6 extends $n{constructor(t){super("cancelled","Popup closed"),this.popup=t,Object.setPrototypeOf(this,V6.prototype)}},uY=class W6 extends $n{constructor(){super("popup_open","Unable to open a popup for loginWithPopup - window.open returned `null`"),Object.setPrototypeOf(this,W6.prototype)}},e0=class q6 extends $n{constructor(t,n,r,i){super(t,n),this.mfa_token=r,this.mfa_requirements=i,Object.setPrototypeOf(this,q6.prototype)}},K6=class G6 extends $n{constructor(t,n){super("missing_refresh_token","Missing Refresh Token (audience: '".concat(t0(t,["default"]),"', scope: '").concat(t0(n),"')")),this.audience=t,this.scope=n,Object.setPrototypeOf(this,G6.prototype)}},dY=class Y6 extends $n{constructor(t,n){super("missing_scopes","Missing requested scopes after refresh (audience: '".concat(t0(t,["default"]),"', missing scope: '").concat(t0(n),"')")),this.audience=t,this.scope=n,Object.setPrototypeOf(this,Y6.prototype)}},J6=class Z6 extends $n{constructor(t){super("use_dpop_nonce","Server rejected DPoP proof: wrong nonce"),this.newDpopNonce=t,Object.setPrototypeOf(this,Z6.prototype)}};function t0(e){let t=arguments.length>1&&arguments[1]!==void 0?arguments[1]:[];return e&&!t.includes(e)?e:""}const n0=()=>window.crypto,xh=()=>{const e="0123456789ABCDEFGHIJKLMNOPQRSTUVWXYZabcdefghijklmnopqrstuvwxyz-_~.";let t="";return Array.from(n0().getRandomValues(new Uint8Array(43))).forEac
9h((n=>t+=e[n%e.length])),t},yb=e=>btoa(e),fY=[{key:"name",type:["string"]},{key:"version",type:["string","number"]},{key:"env",type:["object"]}],X6=function(e){let t=arguments.length>1&&arguments[1]!==void 0&&arguments[1];return Object.keys(e).reduce(((n,r)=>{if(t&&r==="env")return n;const i=fY.find((s=>s.key===r));return i&&i.type.includes(typeof e[r])&&(n[r]=e[r]),n}),{})},BE=e=>{var{clientId:t}=e,n=ys(e,["clientId"]);return new URLSearchParams((r=>Object.keys(r).filter((i=>r[i]!==void 0)).reduce(((i,s)=>Object.assign(Object.assign({},i),{[s]:r[s]})),{}))(Object.assign({client_id:t},n))).toString()},KO=async e=>await n0().subtle.digest({name:"SHA-256"},new TextEncoder().encode(e)),GO=e=>(t=>decodeURIComponent(atob(t).split("").map((n=>"%"+("00"+n.charCodeAt(0).toString(16)).slice(-2))).join("")))(e.replace(/_/g,"/").replace(/-/g,"+")),YO=e=>{const t=new Uint8Array(e);return(n=>{const r={"+":"-","/":"_","=":""};return n.replace(/[+/=]/g,(i=>r[i]))})(window.btoa(String.fromCharCode(...Array.from(t))))};var qc=typeof globalThis<"u"?globalThis:typeof window<"u"?window:typeof global<"u"?global:typeof self<"u"?self:{},Q6={},KC={};Object.defineProperty(KC,"__esModule",{value:!0});var hY=(function(){function e(){var t=this;this.locked=new Map,this.addToLocked=function(n,r){var i=t.locked.get(n);i===void 0?r===void 0?t.locked.set(n,[]):t.locked.set(n,[r]):r!==void 0&&(i.unshift(r),t.locked.set(n,i))},this.isLocked=function(n){return t.locked.has(n)},this.lock=function(n){return new Promise((function(r,i){t.isLocked(n)?t.addToLocked(n,r):(t.addToLocked(n),r())}))},this.unlock=function(n){var r=t.locked.get(n);if(r!==void 0&&r.length!==0){var i=r.pop();t.locked.set(n,r),i!==void 0&&setTimeout(i,0)}else t.locked.delete(n)}}return e.getInstance=function(){return e.instance===void 0&&(e.instance=new e),e.instance},e})();KC.default=function(){return hY.getInstance()};var ws=qc&&qc.__awaiter||function(e,t,n,r){return new(n||(n=Promise))((function(i,s){function o(d){try{c(r.next(d))}catch(f){s(f)}}function a(d){try{c(r.throw(d))}catch(f){s(f)}}function c(d){d.done?i(d.value):new n((function(f){f(d.value)})).then(o,a)}c((r=r.apply(e,t||[])).next())}))},bs=qc&&qc.__generator||function(e,t){var n,r,i,s,o={label:0,sent:function(){if(1&i[0])throw i[1];return i[1]},trys:[],ops:[]};return s={next:a(0),throw:a(1),return:a(2)},typeof Symbol=="function"&&(s[Symbol.iterator]=function(){return this}),s;function a(c){return function(d){return(function(f){if(n)throw new TypeError("Generator is already executing.");for(;o;)try{if(n=1,r&&(i=2&f[0]?r.return:f[0]?r.throw||((i=r.return)&&i.call(r),0):r.next)&&!(i=i.call(r,f[1])).done)return i;switch(r=0,i&&(f=[2&f[0],i.value]),f[0]){case 0:case 1:i=f;break;case 4:return o.label++,{value:f[1],done:!1};case 5:o.label++,r=f[1],f=[0];continue;case 7:f=o.ops.pop(),o.trys.pop();continue;default:if(i=o.trys,!((i=i.length>0&&i[i.length-1])||f[0]!==6&&f[0]!==2)){o=0;continue}if(f[0]===3&&(!i||f[1]>i[0]&&f[1]<i[3])){o.label=f[1];break}if(f[0]===6&&o.label<i[1]){o.label=i[1],i=f;break}if(i&&o.label<i[2]){o.label=i[2],o.ops.push(f);break}i[2]&&o.ops.pop(),o.trys.pop();continue}f=t.call(e,o)}catch(p){f=[6,p],r=0}finally{n=i=0}if(5&f[0])throw f[1];return{value:f[0]?f[1]:void 0,done:!0}}
9)([c,d])}}},Ch=qc;Object.defineProperty(Q6,"__esModule",{value:!0});var Ku=KC,wy={key:function(e){return ws(Ch,void 0,void 0,(function(){return bs(this,(function(t){throw new Error("Unsupported")}))}))},getItem:function(e){return ws(Ch,void 0,void 0,(function(){return bs(this,(function(t){throw new Error("Unsupported")}))}))},clear:function(){return ws(Ch,void 0,void 0,(function(){return bs(this,(function(e){return[2,window.localStorage.clear()]}))}))},removeItem:function(e){return ws(Ch,void 0,void 0,(function(){return bs(this,(function(t){throw new Error("Unsupported")}))}))},setItem:function(e,t){return ws(Ch,void 0,void 0,(function(){return bs(this,(function(n){throw new Error("Unsupported")}))}))},keySync:function(e){return window.localStorage.key(e)},getItemSync:function(e){return window.localStorage.getItem(e)},clearSync:function(){return window.localStorage.clear()},removeItemSync:function(e){return window.localStorage.removeItem(e)},setItemSync:function(e,t){return window.localStorage.setItem(e,t)}};function vb(e){return new Promise((function(t){return setTimeout(t,e)}))}function _b(e){for(var t="0123456789ABCDEFGHIJKLMNOPQRSTUVWXTZabcdefghiklmnopqrstuvwxyz",n="",r=0;r<e;r++)n+=t[Math.floor(Math.random()*t.length)];return n}var pY=(function(){function e(t){this.acquiredIatSet=new Set,this.storageHandler=void 0,this.id=Date.now().toString()+_b(15),this.acquireLock=this.acquireLock.bind(this),this.releaseLock=this.releaseLock.bind(this),this.releaseLock__private__=this.releaseLock__private__.bind(this),this.waitForSomethingToChange=this.waitForSomethingToChange.bind(this),this.refreshLockWhileAcquired=this.refreshLockWhileAcquired.bind(this),this.storageHandler=t,e.waiters===void 0&&(e.waiters=[])}return e.prototype.acquireLock=function(t,n){return n===void 0&&(n=5e3),ws(this,void 0,void 0,(function(){var r,i,s,o,a,c,d;return bs(this,(function(f){switch(f.label){case 0:r=Date.now()+_b(4),i=Date.now()+n,s="browser-tabs-lock-key-"+t,o=this.storageHandler===void 0?wy:this.storageHandler,f.label=1;case 1:return Date.now()<i?[4,vb(30)]:[3,8];case 2:return f.sent(),o.getItemSync(s)!==null?[3,5]:(a=this.id+"-"+t+"-"+r,[4,vb(Math.floor(25*Math.random()))]);case 3:return f.sent(),o.setItemSync(s,JSON.stringify({id:this.id,iat:r,timeoutKey:a,timeAcquired:Date.now(),timeRefreshed:Date.now()})),[4,vb(30)];case 4:return f.sent(),(c=o.getItemSync(s))!==null&&(d=JSON.parse(c)).id===this.id&&d.iat===r?(this.acquiredIatSet.add(r),this.refreshLockWhileAcquired(s,r),[2,!0]):[3,7];case 5:return e.lockCorrector(this.storageHandler===void 0?wy:this.storageHandler),[4,this.waitForSomethingToChange(i)];case 6:f.sent(),f.label=7;case 7:return r=Date.now()+_b(4),[3,1];case 8:return[2,!1]}}))}))},e.prototype.refreshLockWhileAcquired=function(t,n){return ws(this,void 0,void 0,(function(){var r=this;return bs(this,(function(i){return setTimeout((function(){return ws(r,void 0,void 0,(function(){var s,o,a;return bs(this,(function(c){switch(c.label){case 0:return[4,Ku.default().lock(n)];case 1:return c.sent(),this.acquiredIatSet.has(n)?(s=this.storageHandler===void 0?wy:this.storageHandler,(o=s.getItemSync(t))===null?(Ku.default().unlock(n),[2]):((a=JSON.parse(o)).timeRefreshed=Date.now(),s.setItemSync(t,JSON.stringify(a)),Ku.default().unlock(n),this.refreshLockWhileAcquired(t,n),[2])):(Ku.default().unlock(n),[2])}}))}))}),1e3),[2]}))}))},e.prototype.waitForSomethingToChange=function(t){return ws(this,void 0,void 0,(function(){return bs(this,(function(n){switch(n.label){case 0:return[4,new Promise((function(r){var i=!1,s=Date.now(),o=!1;function a(){if(o||(window.removeEventListener("storage",a),e.removeFromWaiting(a),clearTimeout(c),o=!0),!i){i=!0;var d=50-(Date.now()-s);d>0?setTimeout(r,d):r(null)}}window.addEventListener("storage",a),e.addToWaiting(a);var c=setTimeout(a,Math.max(0,t-Date.now()))}))];case 1:return n.sent(),[2]}}))}))},e.addToWaiting=function(t){this.removeFromWaiting(t),e.waiters!==void 0&&e.waiters.push(t)},e.removeFromWaiting=function(t){e.waiters!==void 0&&(e.waiters=e.waiters.filter((function(n){return n!==t})))},e.notifyWaiters=function(){e.waiters!==void 0&&e.waiters.slice().forEac
9h((function(t){return t()}))},e.prototype.releaseLock=function(t){return ws(this,void 0,void 0,(function(){return bs(this,(function(n){switch(n.label){case 0:return[4,this.releaseLock__private__(t)];case 1:return[2,n.sent()]}}))}))},e.prototype.releaseLock__private__=function(t){return ws(this,void 0,void 0,(function(){var n,r,i,s;return bs(this,(function(o){switch(o.label){case 0:return n=this.storageHandler===void 0?wy:this.storageHandler,r="browser-tabs-lock-key-"+t,(i=n.getItemSync(r))===null?[2]:(s=JSON.parse(i)).id!==this.id?[3,2]:[4,Ku.default().lock(s.iat)];case 1:o.sent(),this.acquiredIatSet.delete(s.iat),n.removeItemSync(r),Ku.default().unlock(s.iat),e.notifyWaiters(),o.label=2;case 2:return[2]}}))}))},e.lockCorrector=function(t){for(var n=Date.now()-5e3,r=t,i=[],s=0;;){var o=r.keySync(s);if(o===null)break;i.push(o),s++}for(var a=!1,c=0;c<i.length;c++){var d=i[c];if(d.includes("browser-tabs-lock-key")){var f=r.getItemSync(d);if(f!==null){var p=JSON.parse(f);(p.timeRefreshed===void 0&&p.timeAcquired<n||p.timeRefreshed!==void 0&&p.timeRefreshed<n)&&(r.removeItemSync(d),a=!0)}}}a&&e.notifyWaiters()},e.waiters=void 0,e})(),mY=Q6.default=pY;let gY=class{async runWithLock(t,n,r){const i=new AbortController,s=setTimeout((()=>i.abort()),n);try{return await navigator.locks.request(t,{mode:"exclusive",signal:i.signal},(async o=>{if(clearTimeout(s),!o)throw new Error("Lock not available");return await r()}))}catch(o){throw clearTimeout(s),o?.name==="AbortError"?new I_:o}}},yY=class{constructor(){this.activeLocks=new Set,this.lock=new mY,this.pagehideHandler=()=>{this.activeLocks.forEach((t=>this.lock.releaseLock(t))),this.activeLocks.clear()}}async runWithLock(t,n,r){let i=!1;for(let s=0;s<10&&!i;s++)i=await this.lock.acquireLock(t,n);if(!i)throw new I_;this.activeLocks.add(t),this.activeLocks.size===1&&typeof window<"u"&&window.addEventListener("pagehide",this.pagehideHandler);try{return await r()}finally{this.activeLocks.delete(t),await this.lock.releaseLock(t),this.activeLocks.size===0&&typeof window<"u"&&window.removeEventListener("pagehide",this.pagehideHandler)}}};function vY(){return typeof navigator<"u"&&typeof((e=navigator.locks)===null||e===void 0?void 0:e.request)=="function"?new gY:new yY;var e}let wb=null;const _Y=new TextEncoder,wY=new TextDecoder;function fp(e){return typeof e=="string"?_Y.encode(e):wY.decode(e)}function JO(e){if(typeof e.modulusLength!="number"||e.modulusLength<2048)throw new SY(`${e.name} modulusLength must be at least 2048 bits`)}async function bY(e,t,n){if(n.usages.includes("sign")===!1)throw new TypeError('private CryptoKey instances used for signing assertions must include "sign" in their "usages"');const r=`${hp(fp(JSON.stringify(e)))}.${hp(fp(JSON.stringify(t)))}`;return`${r}.${hp(await crypto.subtle.sign((function(i){switch(i.algorithm.name){case"ECDSA":return{name:i.algorithm.name,hash:"SHA-256"};case"RSA-PSS":return JO(i.algorithm),{name:i.algorithm.name,saltLength:32};case"RSASSA-PKCS1-v1_5":return JO(i.algorithm),{name:i.algorithm.name};case"Ed25519":return{name:i.algorithm.name}}throw new Rc})(n),n,fp(r)))}`}let HE;Uint8Array.prototype.toBase64?HE=e=>(e instanceof ArrayBuffer&&(e=new Uint8Array(e)),e.toBase64({alphabet:"base64url",omitPadding:!0})):HE=t=>{t instanceof ArrayBuffer&&(t=new Uint8Array(t));const n=[];for(let r=0;r<t.byteLength;r+=32768)n.push(String.fromCharCode.apply(null,t.subarray(r,r+32768)));return btoa(n.join("")).replace(/=/g,"").replace(/\+/g,"-").replace(/\//g,"_")};function hp(e){return HE(e)}let Rc=class extends Error{constructor(t){var n;super(t??"operation not supported"),this.name=this.constructor.name,(n=Error.captureStackTrace)===null||n===void 0||n.call(Error,this,this.constructor)}},SY=class extends Error{constructor(t){var n;super(t),this.name=this.constructor.name,(n=Error.captureStackTrace)===null||n===void 0||n.call(Error,this,this.constructor)}};function EY(e){switch(e.algorithm.name){case"RSA-PSS":return(function(t){if(t.algorithm.hash.name==="SHA-256")return"PS256";throw new Rc("unsupported RsaHashedKeyAlgorithm hash name")})(e);case"RSASSA-PKCS1-v1_5":return(function(t){if(t.algorithm.hash.name==="SHA-256")return"RS256";throw new Rc("unsupported RsaHashedKeyAlgorithm hash name")})(e);case"ECDSA":return(function(t){if(t.algorithm.namedCurve==="P-256")return"ES256";throw new Rc("unsupported EcKeyAlgorithm namedCurve")})(e);case"Ed25519":return"Ed25519";default:throw new Rc("unsupported CryptoKey algorithm name")}}function eL(e){return e instanceof CryptoKey}function tL(e){return eL(e)&&e.type==="public"}async function xY(e,t,n,r,i,s){const o=e?.privateKey,a=e?.publicKey;if(!eL(c=o)||c.type!=="private")throw new TypeError('"keypair.privateKey" must be a private CryptoKey');var c;
9if(!tL(a))throw new TypeError('"keypair.publicKey" must be a public CryptoKey');if(a.extractable!==!0)throw new TypeError('"keypair.publicKey.extractable" must be true');if(typeof t!="string")throw new TypeError('"htu" must be a string');if(typeof n!="string")throw new TypeError('"htm" must be a string');if(r!==void 0&&typeof r!="string")throw new TypeError('"nonce" must be a string or undefined');if(i!==void 0&&typeof i!="string")throw new TypeError('"accessToken" must be a string or undefined');return bY({alg:EY(o),typ:"dpop+jwt",jwk:await nL(a)},Object.assign(Object.assign({},s),{iat:Math.floor(Date.now()/1e3),jti:crypto.randomUUID(),htm:n,nonce:r,htu:t,ath:i?hp(await crypto.subtle.digest("SHA-256",fp(i))):void 0}),o)}async function nL(e){const{kty:t,e:n,n:r,x:i,y:s,crv:o}=await crypto.subtle.exportKey("jwk",e);return{kty:t,crv:o,e:n,n:r,x:i,y:s}}const CY=["authorization_code","refresh_token","urn:ietf:params:oauth:grant-type:token-exchange","http://auth0.com/oauth/grant-type/mfa-oob","http://auth0.com/oauth/grant-type/mfa-otp","http://auth0.com/oauth/grant-type/mfa-rec
9overy-code"];function kY(){return(async function(e,t){var n;let r;if(e.length===0)throw new TypeError('"alg" must be a non-empty string');switch(e){case"PS256":r={name:"RSA-PSS",hash:"SHA-256",modulusLength:2048,publicExponent:new Uint8Array([1,0,1])};break;case"RS256":r={name:"RSASSA-PKCS1-v1_5",hash:"SHA-256",modulusLength:2048,publicExponent:new Uint8Array([1,0,1])};break;case"ES256":r={name:"ECDSA",namedCurve:"P-256"};break;case"Ed25519":r={name:"Ed25519"};break;default:throw new Rc}return crypto.subtle.generateKey(r,(n=t?.extractable)!==null&&n!==void 0&&n,["sign","verify"])})("ES256",{extractable:!1})}function TY(e){return(async function(t){if(!tL(t))throw new TypeError('"publicKey" must be a public CryptoKey');if(t.extractable!==!0)throw new TypeError('"publicKey.extractable" must be true');const n=await nL(t);let r;switch(n.kty){case"EC":r={crv:n.crv,kty:n.kty,x:n.x,y:n.y};break;case"OKP":r={crv:n.crv,kty:n.kty,x:n.x};break;case"RSA":r={e:n.e,kty:n.kty,n:n.n};break;default:throw new Rc("unsupported JWK kty")}return hp(await crypto.subtle.digest({name:"SHA-256"},fp(JSON.stringify(r))))})(e.publicKey)}function RY(e){let{keyPair:t,url:n,method:r,nonce:i,accessToken:s}=e;const o=(function(a){const c=new URL(a);return c.search="",c.hash="",c.href})(n);return xY(t,o,r,i,s)}const PY=async(e,t)=>{const n=await fetch(e,t);return{ok:n.ok,json:await n.json(),headers:(r=n.headers,[...r].reduce(((i,s)=>{let[o,a]=s;return i[o]=a,i}),{}))};var r},OY=async(e,t,n)=>{const r=new AbortController;let i;return t.signal=r.signal,Promise.race([PY(e,t),new Promise(((s,o)=>{i=setTimeout((()=>{r.abort(),o(new Error("Timeout when executing 'fetch'"))}),n)}))]).finally((()=>{clearTimeout(i)}))},AY=async(e,t,n,r,i,s,o,a)=>((c,d)=>new Promise((function(f,p){const m=new MessageChannel;m.port1.onmessage=function(v){v.data.error?p(new Error(v.data.error)):f(v.data),m.port1.close()},d.postMessage(c,[m.port2])})))({auth:{audience:t,scope:n},timeout:i,fetchUrl:e,fetchOptions:r,useFormData:o,useMrrt:a},s),IY=async function(e,t,n,r,i,s){let o=arguments.length>6&&arguments[6]!==void 0?arguments[6]:1e4,a=arguments.length>7?arguments[7]:void 0;return i?AY(e,t,n,r,o,i,s,a):OY(e,r,o)};async function rL(e,t,n,r,i,s,o,a,c,d){if(c){const D=await c.generateProof({url:e,method:i.method||"GET",nonce:await c.getNonce()});i.headers=Object.assign(Object.assign({},i.headers),{dpop:D})}let f,p=null;for(let D=0;D<3;D++)try{f=await IY(e,n,r,i,s,o,t,a),p=null;break}catch(F){p=F}if(p)throw p;const m=f.json,{error:v,error_description:w}=m,_=ys(m,["error","error_description"]),{headers:b,ok:C}=f;let P;if(c&&(P=b["dpop-nonce"],P&&await c.setNonce(P)),!C){const D=w||"HTTP error. Unable to fetch ".concat(e);if(v==="mfa_required")throw new e0(v,D,_.mfa_token,_.mfa_requirements);if(v==="missing_refresh_token")throw new K6(n,r);if(v==="use_dpop_nonce"){if(!c||!P||d)throw new J6(P);return rL(e,t,n,r,i,s,o,a,c,!0)}throw new $n(v||"request_error",D)}return _}async function MY(e,t){var{baseUrl:n,timeout:r,audience:i,scope:s,auth0Client:o,useFormData:a,useMrrt:c,dpop:d}=e,f=ys(e,["baseUrl","timeout","audience","scope","auth0Client","useFormData","useMrrt","dpop"]);const p=f.grant_type==="urn:ietf:params:oauth:grant-type:token-exchange",m=f.grant_type==="refresh_token"&&c,v=Object.assign(Object.assign(Object.assign(Object.assign({},f),p&&i&&{audience:i}),p&&s&&{scope:s}),m&&{audience:i,scope:s}),w=a?BE(v):JSON.stringify(v),_=(b=f.grant_type,CY.includes(b));var b;return await rL("".concat(n,"/oauth/token"),r,i||"default",s,{method:"POST",body:w,headers:{"Content-Type":a?"application/x-www-form-urlencoded":"application/json","Auth0-Client":btoa(JSON.stringify(X6(o||j6)))}},t,a,c,_?d:void 0)}const DY=e=>Array.from(new Set(e)),gv=function(){for(var e=arguments.length,t=new Array(e),n=0;n<e;n++)t[n]=arguments[n];return DY(t.filter(Boolean).join(" ").trim().split(/\s+/)).join(" ")},by=(e,t,n)=>{let r;return n&&(r=e[n]),r||(r=e.default),gv(r,t)};let No=class VE{constructor(t){let n=arguments.length>1&&arguments[1]!==void 0?arguments[1]:"@@auth0spajs@@",r=arguments.length>2?arguments[2]:void 0;this.prefix=n,this.suffix=r,this.clientId=t.clientId,this.scope=t.scope,this.audience=t.audie
9nce}toKey(){return[this.prefix,this.clientId,this.audience,this.scope,this.suffix].filter(Boolean).join("::")}static fromKey(t){const[n,r,i,s]=t.split("::");return new VE({clientId:r,scope:s,audience:i},n)}static fromCacheEntry(t){const{scope:n,audience:r,client_id:i}=t;return new VE({scope:n,audience:r,clientId:i})}},LY=class{set(t,n){localStorage.setItem(t,JSON.stringify(n))}get(t){const n=window.localStorage.getItem(t);if(n)try{return JSON.parse(n)}catch{return}}remove(t){localStorage.removeItem(t)}allKeys(){return Object.keys(window.localStorage).filter((t=>t.startsWith("@@auth0spajs@@")))}},iL=class{constructor(){this.enclosedCache=(function(){let t={};return{set(n,r){t[n]=r},get(n){const r=t[n];if(r)return r},remove(n){delete t[n]},allKeys:()=>Object.keys(t)}})()}},NY=class{constructor(t,n,r){this.cache=t,this.keyManifest=n,this.nowProvider=r||F6}async setIdToken(t,n,r){var i;const s=this.getIdTokenCacheKey(t);await this.cache.set(s,{id_token:n,decodedToken:r}),await((i=this.keyManifest)===null||i===void 0?void 0:i.add(s))}async getIdToken(t){const n=await this.cache.get(this.getIdTokenCacheKey(t.clientId));if(!n&&t.scope&&t.audience){const r=await this.get(t);return!r||!r.id_token||!r.decodedToken?void 0:{id_token:r.id_token,decodedToken:r.decodedToken}}if(n)return{id_token:n.id_token,decodedToken:n.decodedToken}}async get(t){let n=arguments.length>1&&arguments[1]!==void 0?arguments[1]:0,r=arguments.length>2&&arguments[2]!==void 0&&arguments[2],i=arguments.length>3?arguments[3]:void 0;var s;let o=await this.cache.get(t.toKey());if(!o){const d=await this.getCacheKeys();if(!d)return;const f=this.matchExistingCacheKey(t,d);if(f&&(o=await this.cache.get(f)),!o&&r&&i!=="cache-only")return this.getEntryWithRefreshToken(t,d)}if(!o)return;const a=await this.nowProvider(),c=Math.floor(a/1e3);return o.expiresAt-n<c?o.body.refresh_token?this.modifiedCachedEntry(o,t):(await this.cache.remove(t.toKey()),void await((s=this.keyManifest)===null||s===void 0?void 0:s.remove(t.toKey()))):o.body}async modifiedCachedEntry(t,n){return t.body={refresh_token:t.body.refresh_token,audience:t.body.audience,scope:t.body.scope},await this.cache.set(n.toKey(),t),{refresh_token:t.body.refresh_token,audience:t.body.audience,scope:t.body.scope}}async set(t){var n;const r=new No({clientId:t.client_id,scope:t.scope,audience:t.audience}),i=await this.wrapCacheEntry(t);await this.cache.set(r.toKey(),i),await((n=this.keyManifest)===null||n===void 0?void 0:n.add(r.toKey()))}async remove(t,n,r){const i=new No({clientId:t,scope:r,audience:n});await this.cache.remove(i.toKey())}async clear(t){var n;const r=await this.getCacheKeys();r&&(await r.filter((i=>!t||i.includes(t))).reduce((async(i,s)=>{await i,await this.cache.remove(s)}),Promise.resolve()),await((n=this.keyManifest)===null||n===void 0?void 0:n.clear()))}async wrapCacheEntry(t){const n=await this.nowProvider();return{body:t,expiresAt:Math.floor(n/1e3)+t.expires_in}}async getCacheKeys(){var t;return this.keyManifest?(t=await this.keyManifest.get())===null||t===void 0?void 0:t.keys:this.cache.allKeys?this.cache.allKeys():void 0}getIdTokenCacheKey(t){return new No({clientId:t},"@@auth0spajs@@","@@user@@").toKey()}matchExistingCacheKey(t,n){return n.filter((r=>{var i;const s=No.fromKey(r),o=new Set(s.scope&&s.scope.split(" ")),a=((i=t.scope)===null||i===void 0?void 0:i.split(" "))||[],c=s.scope&&a.reduce(((d,f)=>d&&o.has(f)),!0);return s.prefix==="@@auth0spajs@@"&&s.clientId===t.clientId&&s.audience===t.audience&&c}))[0]}async getEntryWithRefreshToken(t,n){var r;for(const i of n){const s=No.fromKey(i);if(s.prefix==="@@auth0spajs@@"&&s.clientId===t.clientId){const o=await this.cache.get(i);if(!((r=o?.body)===null||r===void 0)&&r.refresh_token)return this.modifiedCachedEntry(o,t)}}}async updateEntry(t,n){var r;const i=await this.getCacheKeys();if(i)for(const s of i){const o=await this.cache.get(s);((r=o?.body)===null||r===void 0?void 0:r.refresh_token)===t&&(o.body.refresh_token=n,await this.cache.set(s,o))}}},$Y=class{constructor(t,n,r){this.storage=t,this.clientId=n,this.cookieDomain=r,this.storageKey="".concat("a0.spajs.txs",".").concat(this.clientId)}create(t){this.storage.save(this.storageKey,t,{daysUntilExpire:1,cookieDomain:this.cookieDomain})}get(){return this.storage.get(this.storageKey)}remove(){this.storage.remove(this.storageKey,{cookieDomain:this.cookieDomain})}};const kh=e=>typeof e=="number",jY=["iss","aud","exp","nbf","iat","jti","azp","
9nonce","auth_time","at_hash","c_hash","acr","amr","sub_jwk","cnf","sip_from_tag","sip_date","sip_callid","sip_cseq_num","sip_via_branch","orig","dest","mky","events","toe","txn","rph","sid","vot","vtm"],FY=e=>{if(!e.id_token)throw new Error("ID token is required but missing");const t=(s=>{const o=s.split("."),[a,c,d]=o;if(o.length!==3||!a||!c||!d)throw new Error("ID token could not be decoded");const f=JSON.parse(GO(c)),p={__raw:s},m={};return Object.keys(f).forEach((v=>{p[v]=f[v],jY.includes(v)||(m[v]=f[v])})),{encoded:{header:a,payload:c,signature:d},header:JSON.parse(GO(a)),claims:p,user:m}})(e.id_token);if(!t.claims.iss)throw new Error("Issuer (iss) claim must be a string present in the ID token");if(t.claims.iss!==e.iss)throw new Error('Issuer (iss) claim mismatch in the ID token; expected "'.concat(e.iss,'", found "').concat(t.claims.iss,'"'));if(!t.user.sub)throw new Error("Subject (sub) claim must be a string present in the ID token");if(t.header.alg!=="RS256")throw new Error('Signature algorithm of "'.concat(t.header.alg,'" is not supported. Expected the ID token to be signed with "RS256".'));if(!t.claims.aud||typeof t.claims.aud!="string"&&!Array.isArray(t.claims.aud))throw new Error("Audience (aud) claim must be a string or array of strings present in the ID token");if(Array.isArray(t.claims.aud)){if(!t.claims.aud.includes(e.aud))throw new Error('Audience (aud) claim mismatch in the ID token; expected "'.concat(e.aud,'" but was not one of "').concat(t.claims.aud.join(", "),'"'));if(t.claims.aud.length>1){if(!t.claims.azp)throw new Error("Authorized Party (azp) claim must be a string present in the ID token when Audience (aud) claim has multiple values");if(t.claims.azp!==e.aud)throw new Error('Authorized Party (azp) claim mismatch in the ID token; expected "'.concat(e.aud,'", found "').concat(t.claims.azp,'"'))}}else if(t.claims.aud!==e.aud)throw new Error('Audience (aud) claim mismatch in the ID token; expected "'.concat(e.aud,'" but found "').concat(t.claims.aud,'"'));if(e.nonce){if(!t.claims.nonce)throw new Error("Nonce (nonce) claim must be a string present in the ID token");if(t.claims.nonce!==e.nonce)throw new Error('Nonce (nonce) claim mismatch in the ID token; expected "'.concat(e.nonce,'", found "').concat(t.claims.nonce,'"'))}if(e.max_age&&!kh(t.claims.auth_time))throw new Error("Authentication Time (auth_time) claim must be a number present in the ID token when Max Age (max_age) is specified");if(t.claims.exp==null||!kh(t.claims.exp))throw new Error("Expiration Time (exp) claim must be a number present in the ID token");if(!kh(t.claims.iat))throw new Error("Issued At (iat) claim must be a number present in the ID token");const n=e.leeway||60,r=new Date(e.now||Date.now()),i=new Date(0);if(i.setUTCSeconds(t.claims.exp+n),r>i)throw new Error("Expiration Time (exp) claim error in the ID token; current time (".concat(r,") is after expiration time (").concat(i,")"));if(t.claims.nbf!=null&&kh(t.claims.nbf)){const s=new Date(0);if(s.setUTCSeconds(t.claims.nbf-n),r<s)throw new Error("Not Before time (nbf) claim in the ID token indicates that this token can't be used just yet. Current time (".concat(r,") is before ").concat(s))}if(t.claims.auth_time!=null&&kh(t.claims.auth_time)){const s=new Date(0);if(s.setUTCSeconds(parseInt(t.claims.auth_time)+e.max_age+n),r>s)throw new Error("Authentication Time (auth_time) claim in the ID token indicates that too much time has passed since the last end-user authentication. Current time (".concat(r,") is after last auth at ").concat(s))}if(e.organization){const s=e.organization.trim();if(s.startsWith("org_")){const o=s;if(!t.claims.org_id)throw new Error("Organization ID (org_id) claim must be a string present in the ID token");if(o!==t.claims.org_id)throw new Error('Organization ID (org_id) claim mismatch in the ID token; expected "'.concat(o,'", found "').concat(t.claims.org_id,'"'))}else{const o=s.toLowerCase();if(!t.claims.org_name)throw new Error("Organization Name (org_name) claim must be a string present in the ID token");if(o!==t.claims.org_name)throw new Error('Organization Name (org_name) claim mismatch in the ID token; expected "'.concat(o,'", found "').concat(t.claims.org_name,'"'))}}return t};var Ap=qc&&qc.__assign||function(){return Ap=Object.assign||function(e){for(var t,n=1,r=arguments.length;n<r;n++)for(var i in t=arguments[n])Object.prototype.hasOwnProperty.call(t,i)&&(e[i]=t[i]);return e},Ap.apply(this,arguments)};function Th(e,t){if(!t)return"";var n="; "+e;return t===!0?n:n+"="+t}function UY(e,t,n){return encodeURIComponent(e).replace(/%(23|24|26|2B|5E|60|7C)/g,decode
9URIComponent).replace(/\(/g,"%28").replace(/\)/g,"%29")+"="+encodeURIComponent(t).replace(/%(23|24|26|2B|3A|3C|3E|3D|2F|3F|40|5B|5D|5E|60|7B|7D|7C)/g,decodeURIComponent)+(function(r){if(typeof r.expires=="number"){var i=new Date;i.setMilliseconds(i.getMilliseconds()+864e5*r.expires),r.expires=i}return Th("Expires",r.expires?r.expires.toUTCString():"")+Th("Domain",r.domain)+Th("Path",r.path)+Th("Secure",r.secure)+Th("SameSite",r.sameSite)})(n)}function zY(){return(function(e){for(var t={},n=e?e.split("; "):[],r=/(%[\dA-F]{2})+/gi,i=0;i<n.length;i++){var s=n[i].split("="),o=s.slice(1).join("=");o.charAt(0)==='"'&&(o=o.slice(1,-1));try{t[s[0].replace(r,decodeURIComponent)]=o.replace(r,decodeURIComponent)}catch{}}return t})(document.cookie)}var BY=function(e){return zY()[e]};function sL(e,t,n){document.cookie=UY(e,t,Ap({path:"/"},n))}var oL=sL,aL=function(e,t){sL(e,"",Ap(Ap({},t),{expires:-1}))};const ad={get(e){const t=BY(e);if(t!==void 0)return JSON.parse(t)},save(e,t,n){let r={};window.location.protocol==="https:"&&(r={secure:!0,sameSite:"none"}),n?.daysUntilExpire&&(r.expires=n.daysUntilExpire),n?.cookieDomain&&(r.domain=n.cookieDomain),oL(e,JSON.stringify(t),r)},remove(e,t){let n={};t?.cookieDomain&&(n.domain=t.cookieDomain),aL(e,n)}},HY={get(e){return ad.get(e)||ad.get("".concat("_legacy_").concat(e))},save(e,t,n){let r={};window.location.protocol==="https:"&&(r={secure:!0}),n?.daysUntilExpire&&(r.expires=n.daysUntilExpire),n?.cookieDomain&&(r.domain=n.cookieDomain),oL("".concat("_legacy_").concat(e),JSON.stringify(t),r),ad.save(e,t,n)},remove(e,t){let n={};t?.cookieDomain&&(n.domain=t.cookieDomain),aL(e,n),ad.remove(e,t),ad.remove("".concat("_legacy_").concat(e),t)}},VY={get(e){if(typeof sessionStorage>"u")return;const t=sessionStorage.getItem(e);return t!=null?JSON.parse(t):void 0},save(e,t){sessionStorage.setItem(e,JSON.stringify(t))},remove(e){sessionStorage.removeItem(e)}};var rl;(function(e){e.Code="code",e.ConnectCode="connect_code"})(rl||(rl={}));function WY(e,t,n){var r=t===void 0?null:t,i=(function(c,d){var f=atob(c);if(d){for(var p=new Uint8Array(f.length),m=0,v=f.length;m<v;++m)p[m]=f.charCodeAt(m);return String.fromCharCode.apply(null,new Uint16Array(p.buffer))}return f})(e,n!==void 0&&n),s=i.indexOf(` 10`,10)+1,o=i.substring(s)+(r?"//# sourceMappingURL="+r:""),a=new Blob([o],{type:"application/javascript"});return URL.createObjectURL(a)}var ZO,XO,QO,bb,qY=(ZO="Lyogcm9sbHVwLXBsdWdpbi13ZWItd29ya2VyLWxvYWRlciAqLwohZnVuY3Rpb24oKXsidXNlIHN0cmljdCI7Y2xhc3MgZSBleHRlbmRzIEVycm9ye2NvbnN0cnVjdG9yKHQscil7c3VwZXIociksdGhpcy5lcnJvcj10LHRoaXMuZXJyb3JfZGVzY3JpcHRpb249cixPYmplY3Quc2V0UHJvdG90eXBlT2YodGhpcyxlLnByb3RvdHlwZSl9c3RhdGljIGZyb21QYXlsb2FkKHQpe2xldHtlcnJvcjpyLGVycm9yX2Rlc2NyaXB0aW9uOnN9PXQ7cmV0dXJuIG5ldyBlKHIscyl9fWNsYXNzIHQgZXh0ZW5kcyBle2NvbnN0cnVjdG9yKGUscyl7c3VwZXIoIm1pc3NpbmdfcmVmcmVzaF90b2tlbiIsIk1pc3NpbmcgUmVmcmVzaCBUb2tlbiAoYXVkaWVuY2U6ICciLmNvbmNhdChyKGUsWyJkZWZhdWx0Il0pLCInLCBzY29wZTogJyIpLmNvbmNhdChyKHMpLCInKSIpKSx0aGlzLmF1ZGllbmNlPWUsdGhpcy5zY29wZT1zLE9iamVjdC5zZXRQcm90b3R5cGVPZih0aGlzLHQucHJvdG90eXBlKX19ZnVuY3Rpb24gcihlKXtsZXQgdD1hcmd1bWVudHMubGVuZ3RoPjEmJnZvaWQgMCE9PWFyZ3VtZW50c1sxXT9hcmd1bWVudHNbMV06W107cmV0dXJuIGUmJiF0LmluY2x1ZGVzKGUpP2U6IiJ9ImZ1bmN0aW9uIj09dHlwZW9mIFN1cHByZXNzZWRFcnJvciYmU3VwcHJlc3NlZEVycm9yO2NvbnN0IHM9ZT0+e3ZhcntjbGllbnRJZDp0fT1lLHI9ZnVuY3Rpb24oZSx0KXt2YXIgcj17fTtmb3IodmFyIHMgaW4gZSlPYmplY3QucHJvdG90eXBlLmhhc093blByb3BlcnR5LmNhbGwoZSxzKSYmdC5pbmRleE9mKHMpPDAmJihyW3NdPWVbc10pO2lmKG51bGwhPWUmJiJmdW5jdGlvbiI9PXR5cGVvZiBPYmplY3QuZ2V0T3duUHJvcGVydHlTeW1ib2xzKXt2YXIgbz0wO2ZvcihzPU9iamVjdC5nZXRPd25Qcm9wZXJ0eVN5bWJvbHMoZSk7bzxzLmxlbmd0aDtvKyspdC5pbmRleE9mKHNbb10pPDAmJk9iamVjdC5wcm90b3R5cGUucHJvcGVydHlJc0VudW1lcmFibGUuY2FsbChlLHNbb10pJiYocltzW29dXT1lW3Nbb11dKX1yZXR1cm4gcn0oZSxbImNsaWVudElkIl0pO3JldHVybiBuZXcgVVJMU2VhcmNoUGFyYW1zKChlPT5PYmplY3Qua2V5cyhlKS5maWx0ZXIoKHQ9PnZvaWQgMCE9PWVbdF0pKS5yZWR1Y2UoKCh0LHIpPT5PYmplY3QuYXNzaWduKE9iamVjdC5hc3NpZ24oe30sdCkse1tyXTplW3JdfSkpLHt9KSkoT2JqZWN0LmFzc2lnbih7Y2xpZW50X2lkOnR9LHIpKSkudG9TdHJpbmcoKX07bGV0IG89e307Y29uc3Qgbj0oZSx0KT0+IiIuY29uY2F0KGUsInwiKS5jb25jYXQodCk7YWRkRXZlbnRMaXN0ZW5lcigibWVz
10c2FnZSIsKGFzeW5jIGU9PntsZXQgcixjLHtkYXRhOnt0aW1lb3V0OmksYXV0aDphLGZldGNoVXJsOmYsZmV0Y2hPcHRpb25zOmwsdXNlRm9ybURhdGE6cCx1c2VNcnJ0Omh9LHBvcnRzOlt1XX09ZSxkPXt9O2NvbnN0e2F1ZGllbmNlOmcsc2NvcGU6eX09YXx8e307dHJ5e2NvbnN0IGU9cD8oZT0+e2NvbnN0IHQ9bmV3IFVSTFNlYXJjaFBhcmFtcyhlKSxyPXt9O3JldHVybiB0LmZvckVhY2goKChlLHQpPT57clt0XT1lfSkpLHJ9KShsLmJvZHkpOkpTT04ucGFyc2UobC5ib2R5KTtpZighZS5yZWZyZXNoX3Rva2VuJiYicmVmcmVzaF90b2tlbiI9PT1lLmdyYW50X3R5cGUpe2lmKGM9KChlLHQpPT5vW24oZSx0KV0pKGcseSksIWMmJmgpe2NvbnN0IGU9by5sYXRlc3RfcmVmcmVzaF90b2tlbix0PSgoZSx0KT0+e2NvbnN0IHI9T2JqZWN0LmtleXMobykuZmluZCgocj0+e2lmKCJsYXRlc3RfcmVmcmVzaF90b2tlbiIhPT1yKXtjb25zdCBzPSgoZSx0KT0+dC5zdGFydHNXaXRoKCIiLmNvbmNhdChlLCJ8IikpKSh0LHIpLG89ci5zcGxpdCgifCIpWzFdLnNwbGl0KCIgIiksbj1lLnNwbGl0KCIgIikuZXZlcnkoKGU9Pm8uaW5jbHVkZXMoZSkpKTtyZXR1cm4gcyYmbn19KSk7cmV0dXJuISFyfSkoeSxnKTtlJiYhdCYmKGM9ZSl9aWYoIWMpdGhyb3cgbmV3IHQoZyx5KTtsLmJvZHk9cD9zKE9iamVjdC5hc3NpZ24oT2JqZWN0LmFzc2lnbih7fSxlKSx7cmVmcmVzaF90b2tlbjpjfSkpOkpTT04uc3RyaW5naWZ5KE9iamVjdC5hc3NpZ24oT2JqZWN0LmFzc2lnbih7fSxlKSx7cmVmcmVzaF90b2tlbjpjfSkpfWxldCBhLGs7ImZ1bmN0aW9uIj09dHlwZW9mIEFib3J0Q29udHJvbGxlciYmKGE9bmV3IEFib3J0Q29udHJvbGxlcixsLnNpZ25hbD1hLnNpZ25hbCk7dHJ5e2s9YXdhaXQgUHJvbWlzZS5yYWNlKFsoaj1pLG5ldyBQcm9taXNlKChlPT5zZXRUaW1lb3V0KGUsaikpKSksZmV0Y2goZixPYmplY3QuYXNzaWduKHt9LGwpKV0pfWNhdGNoKGUpe3JldHVybiB2b2lkIHUucG9zdE1lc3NhZ2Uoe2Vycm9yOmUubWVzc2FnZX0pfWlmKCFrKXJldHVybiBhJiZhLmFib3J0KCksdm9pZCB1LnBvc3RNZXNzYWdlKHtlcnJvcjoiVGltZW91dCB3aGVuIGV4ZWN1dGluZyAnZmV0Y2gnIn0pO189ay5oZWFkZXJzLGQ9Wy4uLl9dLnJlZHVjZSgoKGUsdCk9PntsZXRbcixzXT10O3JldHVybiBlW3JdPXMsZX0pLHt9KSxyPWF3YWl0IGsuanNvbigpLHIucmVmcmVzaF90b2tlbj8oaCYmKG8ubGF0ZXN0X3JlZnJlc2hfdG9rZW49ci5yZWZyZXNoX3Rva2VuLE89YyxiPXIucmVmcmVzaF90b2tlbixPYmplY3QuZW50cmllcyhvKS5mb3JFYWNoKChlPT57bGV0W3Qscl09ZTtyPT09TyYmKG9bdF09Yil9KSkpLCgoZSx0LHIpPT57b1tuKHQscildPWV9KShyLnJlZnJlc2hfdG9rZW4sZyx5KSxkZWxldGUgci5yZWZyZXNoX3Rva2VuKTooKGUsdCk9PntkZWxldGUgb1tuKGUsdCldfSkoZyx5KSx1LnBvc3RNZXNzYWdlKHtvazprLm9rLGpzb246cixoZWFkZXJzOmR9KX1jYXRjaChlKXt1LnBvc3RNZXNzYWdlKHtvazohMSxqc29uOntlcnJvcjplLmVycm9yLGVycm9yX2Rlc2NyaXB0aW9uOmUubWVzc2FnZX0saGVhZGVyczpkfSl9dmFyIE8sYixfLGp9KSl9KCk7Cgo=",XO=null,QO=!1,function(e){return bb=bb||WY(ZO,XO,QO),new Worker(bb,e)});const Sb={};let KY=class{constructor(t,n){this.cache=t,this.clientId=n,this.manifestKey=this.createManifestKeyFrom(this.clientId)}async add(t){var n;const r=new Set(((n=await this.cache.get(this.manifestKey))===null||n===void 0?void 0:n.keys)||[]);r.add(t),await this.cache.set(this.manifestKey,{keys:[...r]})}async remove(t){const n=await this.cache.get(this.manifestKey);if(n){const r=new Set(n.keys);return r.delete(t),r.size>0?await this.cache.set(this.manifestKey,{keys:[...r]}):await this.cache.remove(this.manifestKey)}}get(){return this.cache.get(this.manifestKey)}clear(){return this.cache.remove(this.manifestKey)}createManifestKeyFrom(t){return"".concat("@@auth0spajs@@","::").concat(t)}};const GY={memory:()=>new iL().enclosedCache,localstorage:()=>new LY},eA=e=>GY[e],tA=e=>{const{openUrl:t,onRedirect:n}=e,r=ys(e,["openUrl","onRedirect"]);return Object.assign(Object.assign({},r),{openUrl:t===!1||t?t:n})},nA=(e,t)=>{const n=t?.split(" ")||[];return(e?.split(" ")||[]).every((r=>n.includes(r)))},lc={NONCE:"nonce",KEYPAIR:"keypair"};let YY=class{constructor(t){this.clientId=t}getVersion(){return 1}createDbHandle(){const t=window.indexedDB.open("auth0-spa-js",this.getVersion());return new Promise(((n,r)=>{t.onupgradeneeded=()=>Object.values(lc).forEach((i=>t.result.createObjectStore(i))),t.onerror=()=>r(t.error),t.onsuccess=()=>n(t.result)}))}async getDbHandle(){return this.dbHandle||(this.dbHandle=await this.createDbHandle()),this.dbHandle}async executeDbRequest(t,n,r){const i=r((await this.getDbHandle()).transaction(t,n).objectStore(t));return new Promise(((s,o)=>{i.onsuccess=()=>s(i.result),i.onerror=()=>o(i.error)}))}buildKey(t){const n=t?"_".concat(t):"auth0";return"".concat(this.clientId,"::").concat(n)}setNonce(t,n){return this.save(lc.NONCE,this.buildKey(n),t)}setKeyPair(t){return this.save(lc.KEYPAIR,this.buildKey(),t)}async save(t,n,r){await this.executeDbRequest(t,"readwrite",(i=>i.put(r,n)))}findNonce(t){return this.find(lc.NONCE,this.buildKey(t))}findKeyPair(){return this.find(lc.KEYPAIR,this.buildKey())}find(t,n){return this.executeDbRequest(t,"readonly",(r=>r.get(n)))}async deleteBy(t,n){const r=await this.executeDbRequest(t,"readonly",(i=>i.getAllKeys()));r?.filter(n).map((i=>this.executeDbRequest(t,"readwrite",(s=>s.delete(i)))))}deleteByClientId(t,n){return this.deleteBy(t,(r=>typeof r=="string"&&r.startsWith("".concat(n,"::"))))}clearNonces(){return this.deleteByClientId(lc.NONCE,this.clientId)}clearKeyPairs(){return this.deleteByClientId(lc.KEYPAIR,this.clientId)}},JY=class{constructor(t){this.storage=new YY(t)}getNonce(t){return this.storage.findNonce(t)}setNonce(t,n){return this.storage.setNonce(t,n)}async getOrGenerateKeyPair(){let t=await this.storage.findKeyPair();return t||(t=await kY(),await this.storage.setKeyPair(t)),t}async generateProof(t){const n=await this.getOrGenerateKeyPair();return RY(Object.assign({keyPair:n},t))}async calculateThumbprint(){return TY(await this.getOrGenerateKeyPair())}async clear(){await Promise.all([this.storage.clearNonces(),this.storage.clearKeyPairs()])}};var md;(function(e){e.Bearer="Bearer",e.DPoP="DPoP"})(md||(md={}));let ZY=class{constructor(t,n){this.hooks=n,this.config=Object.assign(Object.assign({},t),{fetch:t.fetch||(typeof window>"u"?fetch:window.fetch.bind(window))})}isAbsoluteUrl(t){return/^(https?:)?\/\//i.test(t)}buildUrl(t,n){if(n){if(this.isAbsoluteUrl(n))return n;if(t)return"".concat(t.replace(/\/?\/$/,""),"/").concat(n.replace(/^\/+/,""))}throw new TypeError("`url` must be absolute or `baseUrl` non-empty.")}getAccessToken(t){return this.config.getAccessToken?this.config.getAccessToken(t):this.hooks.getAccessToken(t)}extractUrl(t){return typeof t=="string"?t:t instanceof URL?t.href:t.url}
10buildBaseRequest(t,n){if(!this.config.baseUrl)return new Request(t,n);const r=this.buildUrl(this.config.baseUrl,this.extractUrl(t)),i=t instanceof Request?new Request(r,t):r;return new Request(i,n)}setAuthorizationHeader(t,n){let r=arguments.length>2&&arguments[2]!==void 0?arguments[2]:md.Bearer;t.headers.set("authorization","".concat(r," ").concat(n))}async setDpopProofHeader(t,n){if(!this.config.dpopNonceId)return;const r=await this.hooks.getDpopNonce(),i=await this.hooks.generateDpopProof({accessToken:n,method:t.method,nonce:r,url:t.url});t.headers.set("dpop",i)}async prepareRequest(t,n){const r=await this.getAccessToken(n);let i,s;typeof r=="string"?(i=this.config.dpopNonceId?md.DPoP:md.Bearer,s=r):(i=r.token_type,s=r.access_token),this.setAuthorizationHeader(t,s,i),i===md.DPoP&&await this.setDpopProofHeader(t,s)}getHeader(t,n){return Array.isArray(t)?new Headers(t).get(n)||"":typeof t.get=="function"?t.get(n)||"":t[n]||""}hasUseDpopNonceError(t){if(t.status!==401)return!1;const n=this.getHeader(t.headers,"www-authenticate");return n.includes("invalid_dpop_nonce")||n.includes("use_dpop_nonce")}async handleResponse(t,n){const r=this.getHeader(t.headers,"dpop-nonce");if(r&&await this.hooks.setDpopNonce(r),!this.hasUseDpopNonceError(t))return t;if(!r||!n.onUseDpopNonceError)throw new J6(r);return n.onUseDpopNonceError()}async internalFetchWithAuth(t,n,r,i){const s=this.buildBaseRequest(t,n);await this.prepareRequest(s,i);const o=await this.config.fetch(s);return this.handleResponse(o,r)}fetchWithAuth(t,n,r){const i={onUseDpopNonceError:()=>this.internalFetchWithAuth(t,n,Object.assign(Object.assign({},i),{onUseDpopNonceError:void 0}),r)};return this.internalFetchWithAuth(t,n,i,r)}},XY=class{constructor(t,n){this.myAccountFetcher=t,this.apiBase=n}async connectAccount(t){const n=await this.myAccountFetcher.fetchWithAuth("".concat(this.apiBase,"v1/connected-accounts/connect"),{method:"POST",headers:{"Content-Type":"application/json"},body:JSON.stringify(t)});return this._handleResponse(n)}async completeAccount(t){const n=await this.myAccountFetcher.fetchWithAuth("".concat(this.apiBase,"v1/connected-accounts/complete"),{method:"POST",headers:{"Content-Type":"application/json"},body:JSON.stringify(t)});return this._handleResponse(n)}async _handleResponse(t){let n;try{n=await t.text(),n=JSON.parse(n)}catch(r){throw new rA({type:"invalid_json",status:t.status,title:"Invalid JSON response",detail:n||String(r)})}if(t.ok)return n;throw new rA(n)}},rA=class lL extends Error{constructor(t){let{type:n,status:r,title:i,detail:s,validation_errors:o}=t;super(s),this.name="MyAccountApiError",this.type=n,this.status=r,this.title=i,this.detail=s,this.validation_errors=o,Object.setPrototypeOf(this,lL.prototype)}};const QY={otp:{authenticatorTypes:["otp"]},sms:{authenticatorTypes:["oob"],oobChannels:["sms"]},email:{authenticatorTypes:["oob"],oobChannels:["email"]},push:{authenticatorTypes:["oob"],oobChannels:["auth0"]},voice:{authenticatorTypes:["oob"],oobChannels:["voice"]}},eJ="http://auth0.com/oauth/grant-type/mfa-otp",tJ="http://auth0.com/oauth/grant-type/mfa-oob",nJ="http://auth0.com/oauth/grant-type/mfa-rec
10overy-code";function cL(e,t){this.v=e,this.k=t}function Wn(e,t,n){if(typeof e=="function"?e===t:e.has(t))return arguments.length<3?t:n;throw new TypeError("Private element is not present on this object")}function rJ(e){return new cL(e,0)}function uL(e,t){if(t.has(e))throw new TypeError("Cannot initialize the same private elements twice on an object")}function Ce(e,t){return e.get(Wn(e,t))}function ir(e,t,n){uL(e,t),t.set(e,n)}function xn(e,t,n){return e.set(Wn(e,t),n),n}function Oe(e,t,n){return(t=(function(r){var i=(function(s,o){if(typeof s!="object"||!s)return s;var a=s[Symbol.toPrimitive];if(a!==void 0){var c=a.call(s,o);if(typeof c!="object")return c;throw new TypeError("@@toPrimitive must return a primitive value.")}return(o==="string"?String:Number)(s)})(r,"string");return typeof i=="symbol"?i:i+""})(t))in e?Object.defineProperty(e,t,{value:n,enumerable:!0,configurable:!0,writable:!0}):e[t]=n,e}function iA(e,t){var n=Object.keys(e);if(Object.getOwnPropertySymbols){var r=Object.getOwnPropertySymbols(e);t&&(r=r.filter((function(i){return Object.getOwnPropertyDescriptor(e,i).enumerable}))),n.push.apply(n,r)}return n}function et(e){for(var t=1;t<arguments.length;t++){var n=arguments[t]!=null?arguments[t]:{};t%2?iA(Object(n),!0).forEach((function(r){Oe(e,r,n[r])})):Object.getOwnPropertyDescriptors?Object.defineProperties(e,Object.getOwnPropertyDescriptors(n)):iA(Object(n)).forEach((function(r){Object.defineProperty(e,r,Object.getOwnPropertyDescriptor(n,r))}))}return e}function sA(e,t){if(e==null)return{};var n,r,i=(function(o,a){if(o==null)return{};var c={};for(var d in o)if({}.hasOwnProperty.call(o,d)){if(a.indexOf(d)!==-1)continue;c[d]=o[d]}return c})(e,t);if(Object.getOwnPropertySymbols){var s=Object.getOwnPropertySymbols(e);for(r=0;r<s.length;r++)n=s[r],t.indexOf(n)===-1&&{}.propertyIsEnumerable.call(e,n)&&(i[n]=e[n])}return i}function iJ(e){return function(){return new Zh(e.apply(this,arguments))}}function Zh(e){var t,n;function r(s,o){try{var a=e[s](o),c=a.value,d=c instanceof cL;Promise.resolve(d?c.v:c).then((function(f){if(d){var p=s==="return"?"return":"next";if(!c.k||f.done)return r(p,f);f=e[p](f).value}i(a.done?"return":"normal",f)}),(function(f){r("throw",f)}))}catch(f){i("throw",f)}}function i(s,o){switch(s){case"return":t.resolve({value:o,done:!0});break;case"throw":t.reject(o);break;default:t.resolve({value:o,done:!1})}(t=t.next)?r(t.key,t.arg):n=null}this._invoke=function(s,o){return new Promise((function(a,c){var d={key:s,arg:o,resolve:a,reject:c,next:null};n?n=n.next=d:(t=n=d,r(s,o))}))},typeof e.return!="function"&&(this.return=void 0)}var Sy,Eb;let WE;Zh.prototype[typeof Symbol=="function"&&Symbol.asyncIterator||"@@asyncIterator"]=function(){return this},Zh.prototype.next=function(e){return this._invoke("next",e)},Zh.prototype.throw=function(e){return this._invoke("throw",e)},Zh.prototype.return=function(e){return this._invoke("return",e)},(typeof navigator>"u"||(Sy=navigator.userAgent)===null||Sy===void 0||(Eb=Sy.startsWith)===null||Eb===void 0||!Eb.call(Sy,"Mozilla/5.0 "))&&(WE="".concat("oauth4webapi","/").concat("v3.8.3"));function gf(e,t){if(e==null)return!1;try{return e instanceof t||Object.getPrototypeOf(e)[Symbol.toStringTag]===t.prototype[Symbol.toStringTag]}catch{return!1}}function Zt(e,t,n){const r=new TypeError(e,{cause:n});return Object.assign(r,{code:t}),r}const ns=Symbol(),qE=Symbol(),KE=Symbol(),Os=Symbol(),Xo=Symbol(),sJ=new TextEncoder,oJ=new TextDecoder;function Md(e){return typeof e=="string"?sJ.encode(e):oJ.decode(e)}let GE,dL;Uint8Array.prototype.toBase64?GE=e=>(e instanceof ArrayBuffer&&(e=new Uint8Array(e)),e.toBase64({alphabet:"base64url",omitPadding:!0})):GE=t=>{t instanceof ArrayBuffer&&(t=new Uint8Array(t));const n=[];for(let r=0;r<t.byteLength;r+=32768)n.push(String.fromCharCode.apply(null,t.subarray(r,r+32768)));return btoa(n.join("")).replace(/=/g,"").replace(/\+/g,"-").replace(/\//g,"_")};function Nc(e){return typeof e=="string"?dL(e):GE(e)}dL=Uint8Array.fromBase64?e=>{try{return Uint8Array.fromBase64(e,{alphabet:"base64url"})}catch(t){throw Zt("The input to be decoded is not correctly encoded.","ERR_INVALID_ARG_VALUE",t)}}:e=>{try{const t=atob(e.replace(/-/g,"+").replace(/_/g,"/").replace(/\s/g,"")),n=new Uint8Array(t.length);for(let r=0;r<t.length;r++)n[r]=t.charCodeAt(r);return n}catch(t){throw Zt("The input to be decoded is not correctly encoded.","ERR_INVALID_ARG_VALUE",t)}};
10let Ci=class extends Error{constructor(t,n){var r;super(t,n),Oe(this,"code",void 0),this.name=this.constructor.name,this.code=ZE,(r=Error.captureStackTrace)===null||r===void 0||r.call(Error,this,this.constructor)}},GC=class extends Error{constructor(t,n){var r;super(t,n),Oe(this,"code",void 0),this.name=this.constructor.name,n!=null&&n.code&&(this.code=n?.code),(r=Error.captureStackTrace)===null||r===void 0||r.call(Error,this,this.constructor)}};function pt(e,t,n){return new GC(e,{code:t,cause:n})}function aJ(e,t){if((function(n,r){if(!(n instanceof CryptoKey))throw Zt("".concat(r," must be a CryptoKey"),"ERR_INVALID_ARG_TYPE")})(e,t),e.type!=="private")throw Zt("".concat(t," must be a private CryptoKey"),"ERR_INVALID_ARG_VALUE")}function r0(e){return e!==null&&typeof e=="object"&&!Array.isArray(e)}function M_(e){gf(e,Headers)&&(e=Object.fromEntries(e.entries()));const t=new Headers(e??{});if(WE&&!t.has("user-agent")&&t.set("user-agent",WE),t.has("authorization"))throw Zt('"options.headers" must not include the "authorization" header name',"ERR_INVALID_ARG_VALUE");return t}function fL(e,t){if(t!==void 0){if(typeof t=="function"&&(t=t(e.href)),!(t instanceof AbortSignal))throw Zt('"options.signal" must return or be an instance of AbortSignal',"ERR_INVALID_ARG_TYPE");return t}}function oA(e){return e.includes("//")?e.replace("//","/"):e}async function lJ(e,t){return(async function(n,r,i,s){if(!(n instanceof URL))throw Zt('"'.concat(r,'" must be an instance of URL'),"ERR_INVALID_ARG_TYPE");YC(n,s?.[ns]!==!0);const o=i(new URL(n.href)),a=M_(s?.headers);return a.set("accept","application/json"),(s?.[Os]||fetch)(o.href,{body:void 0,headers:Object.fromEntries(a.entries()),method:"GET",redirect:"manual",signal:fL(o,s?.signal)})})(e,"issuerIdentifier",(n=>{switch(t?.algorithm){case void 0:case"oidc":(function(r,i){r.pathname=oA("".concat(r.pathname,"/").concat(i))})(n,".well-known/openid-configuration");break;case"oauth2":(function(r,i){let s=arguments.length>2&&arguments[2]!==void 0&&arguments[2];r.pathname==="/"?r.pathname=i:r.pathname=oA("".concat(i,"/").concat(s?r.pathname:r.pathname.replace(/(\/)$/,"")))})(n,".well-known/oauth-authorization-server");break;default:throw Zt('"options.algorithm" must be "oidc" (default), or "oauth2"',"ERR_INVALID_ARG_VALUE")}return n}),t)}function dl(e,t,n,r,i){try{if(typeof e!="number"||!Number.isFinite(e))throw Zt("".concat(n," must be a number"),"ERR_INVALID_ARG_TYPE",i);if(e>0)return;if(t){if(e!==0)throw Zt("".concat(n," must be a non-negative number"),"ERR_INVALID_ARG_VALUE",i);return}throw Zt("".concat(n," must be a positive number"),"ERR_INVALID_ARG_VALUE",i)}catch(s){throw r?pt(s.message,r,i):s}}function Qn(e,t,n,r){try{if(typeof e!="string")throw Zt("".concat(t," must be a string"),"ERR_INVALID_ARG_TYPE",r);if(e.length===0)throw Zt("".concat(t," must not be empty"),"ERR_INVALID_ARG_VALUE",r)}catch(i){throw n?pt(i.message,n,r):i}}function hL(e){(function(t,n){if(yL(t)!==n)throw(function(r){let i='"response" content-type must be ';for(var s=arguments.length,o=new Array(s>1?s-1:0),a=1;a<s;a++)o[a-1]=arguments[a];if(o.length>2){const c=o.pop();i+="".concat(o.join(", "),", or ").concat(c)}else o.length===2?i+="".concat(o[0]," or ").concat(o[1]):i+=o[0];return pt(i,_L,r)})(t,n)})(e,"application/json")}function pL(){return Nc(crypto.getRandomValues(new Uint8Array(32)))}function cJ(e){switch(e.algorithm.name){case"RSA-PSS":return(function(t){switch(t.algorithm.hash.name){case"SHA-256":return"PS256";case"SHA-384":return"PS384";case"SHA-512":return"PS512";default:throw new Ci("unsupported RsaHashedKeyAlgorithm hash name",{cause:t})}})(e);case"RSASSA-PKCS1-v1_5":return(function(t){switch(t.algorithm.hash.name){case"SHA-256":return"RS256";case"SHA-384":return"RS384";case"SHA-512":return"RS512";default:throw new Ci("unsupported RsaHashedKeyAlgorithm hash name",{cause:t})}})(e);case"ECDSA":return(function(t){switch(t.algorithm.namedCurve){case"P-256":return"ES256";case"P-384":return"ES384";case"P-521":return"ES512";default:throw new Ci("unsupported EcKeyAlgorithm namedCurve",{cause:t})}})(e);case"Ed25519":case"ML-DSA-44":case"ML-DSA-65":case"ML-DSA-87":return e.algorithm.name;case"EdDSA":return"Ed25519";default:throw new Ci("unsupported CryptoKey algorithm name",{cause:e})}}function i0(e){const t=e?.[qE];return typeof t=="number"&&Number.isFinite(t)?t:0}function YE(e){const t=e?.[KE];return typeof t=="number"&&Number.isFinite(t)&&Math.sign(t)!==-1?t:30}function s0(){return Math.floor(Date.now()/1e3)}function Rs(e){if(typeof e!="object"||e===null)throw Zt('"as" must be an object',"ERR_INVALID_ARG_TYPE");Qn(e.issuer,'"as.issuer"')}function Ps(e){if(typeof e!="object"||e===null)throw Zt('"client" must be an object',"ERR_INVALID_ARG_TYPE");Qn(e.client_id,'"client.client_id"')}function aA(e){return Qn(e,'"clientSecret"'),(t,n,r,i)=>{r.set("client_id",n.client_id),r.set("client_secret",e)}}function uJ(e,t){const{key:n,kid:r}=(i=e)instanceof CryptoKey?{key:i}:i?.key instanceof CryptoKey?(i.kid!==void 0&&Qn(i.kid,'"kid"'),{key:i.key,kid:i.kid}):{};var i;return aJ(n,'"clientPrivateKey.key"'),async(s,o,a,c)=>{const d={alg:cJ(n),kid:r},f=(function(p,m){const v=s0()+i0(m);return{jti:pL(),aud:p.issuer,exp:v+60,iat:v,nbf:v,iss:m.client_id,sub:m.client_id}})(s,o);a.set("client_id",o.client_id),a.set("client_assertion_type","urn:ietf:params:oauth:client-assertion-type:jwt-bearer"),a.set("client_assertion",await(async function(p,m,v){if(!v.usages.includes("sign"))throw Zt('CryptoKey instances used for signing assertions must include "sign" in their "usages"',"ERR_INVALID_ARG_VALUE");const w="".concat(Nc(Md(JSON.stringify(p))),".").concat(Nc(Md(JSON.stringify(m)))),_=Nc(await crypto.subtle.sign((function(b){switch(b.algorithm.name){case"ECDSA":return{name:b.algorithm.name,hash:RJ(b)};case"RSA-PSS":switch(uA(b),b.algorithm.hash.name){case"SHA-256":case"SHA-384":case"SHA-512":return{name:b.algorithm.name,saltLength:parseInt(b.algorithm.hash.name.slice(-3),10)>>3};default:throw new Ci("unsupported RSA-PSS hash name",{cause:b})}case"RSASSA-PKCS1-v1_5":return uA(b),b.algorithm.name;case"ML-DSA-44":case"ML-DSA-65":case"ML-DSA-87":case"Ed25519":return b.algorithm.name}throw new Ci("unsupported CryptoKey algorithm name",{cause:b})})(v),v,Md(w)));return"".concat(w,".").concat(_)})(d,f,n))}}const dJ=URL.parse?(e,t)=>URL.parse(e,t):(e,t)=>{try{return new URL(e,t)}catch{return null}};function YC(e,t){if(t&&e.protocol!=="https:")throw pt("only requests to HTTPS are allowed",wL,e);if(e.protocol!=="https:"&&e.protocol!=="http:")throw pt("only HTTP and HTTPS requests are allowed",bL,e)}function lA(e,t,n,r){let i;if(typeof e!="string"||!(i=dJ(e)))throw pt("authorization server metadata does not contain a valid ".concat(n?'"as.mtls_endpoint_aliases.'.concat(t,'"'):'"as.'.concat(t,'"')),e===void 0?kJ:TJ,{attribute:n?"mtls_endpoint_aliases.".concat(t):t});return YC(i,r),i}function vm(e,t,n,r){return n&&e.mtls_endpoint_aliases&&t in e.mtls_endpoint_aliases?lA(e.mtls_endpoint_aliases[t],t,n,r):lA(e[t],t,n,r)}
10let D_=class extends Error{constructor(t,n){var r;super(t,n),Oe(this,"cause",void 0),Oe(this,"code",void 0),Oe(this,"error",void 0),Oe(this,"status",void 0),Oe(this,"error_description",void 0),Oe(this,"response",void 0),this.name=this.constructor.name,this.code=xJ,this.cause=n.cause,this.error=n.cause.error,this.status=n.response.status,this.error_description=n.cause.error_description,Object.defineProperty(this,"response",{enumerable:!1,value:n.response}),(r=Error.captureStackTrace)===null||r===void 0||r.call(Error,this,this.constructor)}},mL=class extends Error{constructor(t,n){var r,i;super(t,n),Oe(this,"cause",void 0),Oe(this,"code",void 0),Oe(this,"error",void 0),Oe(this,"error_description",void 0),this.name=this.constructor.name,this.code=CJ,this.cause=n.cause,this.error=n.cause.get("error"),this.error_description=(r=n.cause.get("error_description"))!==null&&r!==void 0?r:void 0,(i=Error.captureStackTrace)===null||i===void 0||i.call(Error,this,this.constructor)}},JC=class extends Error{constructor(t,n){var r;super(t,n),Oe(this,"cause",void 0),Oe(this,"code",void 0),Oe(this,"response",void 0),Oe(this,"status",void 0),this.name=this.constructor.name,this.code=EJ,this.cause=n.cause,this.status=n.response.status,this.response=n.response,Object.defineProperty(this,"response",{enumerable:!1}),(r=Error.captureStackTrace)===null||r===void 0||r.call(Error,this,this.constructor)}};const fJ="[a-zA-Z0-9!#$%&\\'\\*\\+\\-\\.\\^_`\\|~]+",hJ=new RegExp("^[,\\s]*("+fJ+")"),pJ=new RegExp('^[,\\s]*([a-zA-Z0-9!#$%&\\\'\\*\\+\\-\\.\\^_`\\|~]+)\\s*=\\s*"((?:[^"\\\\]|\\\\[\\s\\S])*)"[,\\s]*(.*)'),mJ=new RegExp("^[,\\s]*([a-zA-Z0-9!#$%&\\'\\*\\+\\-\\.\\^_`\\|~]+)\\s*=\\s*([a-zA-Z0-9!#$%&\\'\\*\\+\\-\\.\\^_`\\|~]+)[,\\s]*(.*)"),gJ=new RegExp("^([a-zA-Z0-9\\-\\._\\~\\+\\/]+={0,2})(?:$|[,\\s])(.*)");async function ZC(e,t,n){if(e.status!==t){let i;var r;throw(function(s){let o;if(o=(function(a){if(!gf(a,Response))throw Zt('"response" must be an instance of Response',"ERR_INVALID_ARG_TYPE");const c=a.headers.get("www-authenticate");if(c===null)return;const d=[];let f=c;for(;f;){var p;let m=f.match(hJ);const v=(p=m)===null||p===void 0?void 0:p[1].toLowerCase();if(!v)return;const w=f.substring(m[0].length);if(w&&!w.match(/^[\s,]/))return;const _=w.match(/^\s+(.*)$/),b=!!_;f=_?_[1]:void 0;const C={};let P;if(b)for(;f;){let F,R;if(m=f.match(pJ)){if([,F,R,f]=m,R.includes("\\"))try{R=JSON.parse('"'.concat(R,'"'))}catch{}C[F.toLowerCase()]=R}else{if(!(m=f.match(mJ))){if(m=f.match(gJ)){if(Object.keys(C).length)break;[,P,f]=m;break}return}[,F,R,f]=m,C[F.toLowerCase()]=R}}else f=w||void 0;const D={scheme:v,parameters:C};P&&(D.token68=P),d.push(D)}return d.length?d:void 0})(s))throw new JC("server responded with a challenge in the WWW-Authenticate HTTP Header",{cause:o,response:s})})(e),(i=await(async function(s){if(s.status>399&&s.status<500){wm(s),hL(s);try{const o=await s.clone().json();if(r0(o)&&typeof o.error=="string"&&o.error.length)return o}catch{}}})(e))?(await((r=e.body)===null||r===void 0?void 0:r.cancel()),new D_("server responded with an error in the response body",{cause:i,response:e})):pt('"response" is not a conform '.concat(n," response (unexpected HTTP status code)"),ek,e)}}function gL(e){if(!QC.has(e))throw Zt('"options.DPoP" is not a valid DPoPHandle',"ERR_INVALID_ARG_VALUE")}function yL(e){var t;return(t=e.headers.get("content-type"))===null||t===void 0?void 0:t.split(";")[0]}async function XC(e,t,n,r,i,s,o){return await n(e,t,i,s),s.set("content-type","application/x-www-form-urlencoded;charset=UTF-8"),(o?.[Os]||fetch)(r.href,{body:i,headers:Object.fromEntries(s.entries()),method:"POST",redirect:"manual",signal:fL(r,o?.signal)})}async function _m(e,t,n,r,i,s){var o;const a=vm(e,"token_endpoint",t.use_mtls_endpoint_aliases,s?.[ns]!==!0);i.set("grant_type",r);const c=M_(s?.headers);c.set("accept","application/json"),s?.DPoP!==void 0&&(gL(s.DPoP),await s.DPoP.addProof(a,c,"POST"));const d=await XC(e,t,n,a,i,c,s);return s==null||(o=s.DPoP)===null||o===void 0||o.cacheNonce(d,a),d}const vL=new WeakMap,yJ=new WeakMap;function JE(e){if(!e.id_token)return;const t=vL.get(e);if(!t)throw Zt('"ref" was already garbage collected or did not resolve from the proper sources',"ERR_INVALID_ARG_VALUE");return t}async function Wd(e,t,n,r,i,s){if(Rs(e),Ps(t),!gf(n,Response))throw Zt('"response" must be an instance of Response',"ERR_INVALID_ARG_TYPE");await ZC(n,200,"Token Endpoint"),wm(n);const o=await L_(n);if(Qn(o.access_token,'"response" body "access_token" property',Dt,{body:o}),Qn(o.token_type,'"response" body "token_type" property',Dt,{body:o}),o.token_type=o.token_type.toLowerCase(),o.expires_in!==void 0){let a=typeof o.expires_in!="number"?parseFloat(o.expires_in):o.expires_in;dl(a,!0,'"response" body "expires_in" property',Dt,{body:o}),o.expires_in=a}if(o.refresh_token!==void 0&&Qn(o.refresh_token,'"response" body "refresh_token" property',Dt,{body:o}),o.scope!==void 0&&typeof o.scope!="string")throw pt('"response" body "scope" property must be a string',Dt,{body:o});if(o.id_token!==void 0){Qn(o.id_token,'"response" body "id_token" property',Dt,{body:o});const a=["aud","exp","iat","iss","sub"];t.require_auth_time===!0&&a.push("auth_time"),t.default_max_age!==void 0&&(dl(t.default_max_age,!0,'"client.default_max_age"'),a.push("auth_time")),r!=null&&r.length&&a.push(...r);const{claims:c,jwt:d}=await(async function(f,p,m,v,w){let _,b,{0:C,1:P,length:D}=f.split(".");if(D===5){if(w===void 0)throw new Ci("JWE decryption is not configured",{cause:f});f=await w(f),{0:C,1:P,length:D}=f.split(".")}if(D!==3)throw pt("Invalid JWT",Dt,f);try{_=JSON.parse(Md(Nc(C)))}catch(R){throw pt("failed to parse JWT Header body as base64url encoded JSON",o0,R)}if(!r0(_))throw pt("JWT Header must be a top level object",Dt,f);if(p(_),_.crit!==void 0)throw new Ci('no JWT "crit" header parameter extensions are supported',{cause:{header:_}});try{b=JSON.parse(Md(Nc(P)))}catch(R){throw pt("failed to parse JWT Payload body as base64url encoded JSON",o0,R)}if(!r0(b))throw pt("JWT Payload must be a top level object",Dt,f);const F=s0()+m;if(b.exp!==void 0){if(typeof b.exp!="number")throw pt('unexpected JWT "exp" (expiration time) claim type',Dt,{claims:b});if(b.exp<=F-v)throw pt('unexpected JWT "exp" (expiration time) claim value, expiration is past current timestamp',Ip,{claims:b,now:F,tolerance:v,claim:"exp"})}if(b.iat!==void 0&&typeof b.iat!="number")throw pt('unexpected JWT "iat" (issued at) claim type',Dt,{claims:b});if(b.iss!==void 0&&typeof b.iss!="string")throw pt('unexpected JWT "iss" (issuer) claim type',Dt,{claims:b});if(b.nbf!==void 0){if(typeof b.nbf!="number")throw pt('unexpected JWT "nbf" (not before) claim type',Dt,{claims:b});if(b.nbf>F+v)throw pt('unexpected JWT "nbf" (not before) claim value',Ip,{claims:b,now:F,tolerance:v,claim:"nbf"})}if(b.aud!==void 0&&typeof b.aud!="string"&&!Array.isArray(b.aud))throw pt('unexpected JWT "aud" (audience) claim type',Dt,{claims:b});return{header:_,claims:b,jwt:f}})(o.id_token,OJ.bind(void 0,t.id_token_signed_response_alg,e.id_token_signing_alg_values_supported,"RS256"),i0(t),YE(t),i).then(bJ.bind(void 0,a)).then(_J.bind(void 0,e)).then(vJ.bind(void 0,t.client_id));if(Array.isArray(c.aud)&&c.aud.length!==1){if(c.azp===void 0)throw pt('ID Token "aud" (audience) claim includes additional untrusted audiences',Bo,{claims:c,claim:"aud"});if(c.azp!==t.client_id)throw pt('unexpected ID Token "azp" (authorized party) claim value',Bo,{expected:t.client_id,claims:c,claim:"azp"})}c.auth_time!==void 0&&dl(c.auth_time,!0,'ID Token "auth_time" (authentication time)',Dt,{claims:c}),yJ.set(n,d),vL.set(o,c)}if(s?.[o.token_type]!==void 0)s[o.token_type](n,o);else if(o.token_type!=="dpop"&&o.token_type!=="bearer")throw new Ci("unsupported `token_type` value",{cause:{body:o}});return o}function vJ(e,t){if(Array.isArray(t.claims.aud)){if(!t.claims.aud.includes(e))throw pt('unexpected JWT "aud" (audience) claim value',Bo,{expected:e,claims:t.claims,claim:"aud"})}else if(t.claims.aud!==e)throw pt('unexpected JWT "aud" (audience) claim value',Bo,{expected:e,claims:t.claims,claim:"aud"});return t}function _J(e,t){var n,r;const i=(n=(r=e[SL])===null||r===void 0?void 0:r.call(e,t))!==null&&n!==void 0?n:e.issuer;if(t.claims.iss!==i)throw pt('unexpected JWT "iss" (issuer) claim value',Bo,{expected:i,claims:t.claims,claim:"iss"});return t}const QC=new WeakSet,cA=Symbol(),wJ={aud:"audience",c_hash:"code hash",client_id:"client id",exp:"expiration time",iat:"issued at",iss:"issuer",jti:"jwt id",nonce:"nonce",s_hash:"state hash",sub:"subject",ath:"access token hash",htm:"http method",htu:"http uri",cnf:"confirmation",auth_time:"authentication time"};function bJ(e,t){for(const n of e)if(t.claims[n]===void 0)throw pt('JWT "'.concat(n,'" (').concat(wJ[n],") claim missing"),Dt,{claims:t.claims});return t}const xb=Symbol(),Cb=Symbol();async function SJ(e,t,n,r){return typeof r?.expectedNonce=="string"||typeof r?.maxAge=="number"||r!=null&&r.requireIdToken?(async function(i,s,o,a,c,d,f){const p=[];switch(a){case void 0:a=xb;break;case xb:break;default:Qn(a,'"expectedNonce" argument'),p.push("nonce")}switch(c!=null||(c=s.default_max_age),c){case void 0:c=Cb;break;case Cb:break;default:dl(c,!0,'"maxAge" argument'),p.push("auth_time")}const m=await Wd(i,s,o,p,d,f);Qn(m.id_token,'"response" body "id_token" property',Dt,{body:m});const v=JE(m);if(c!==Cb){const w=s0()+i0(s),_=YE(s);if(v.auth_time+c<w-_)throw pt("too much time has elapsed since the last End-User authentication",Ip,{claims:v,now:w,tolerance:_,claim:"auth_time"})}if(a===xb){if(v.nonce!==void 0)throw pt('unexpected ID Token "nonce" claim value',Bo,{expected:void 0,claims:v,claim:"nonce"})}else if(v.nonce!==a)throw pt('unexpected ID Token "nonce" claim value',Bo,{expected:a,claims:v,claim:"nonce"});return m})(e,t,n,r.expectedNonce,r.maxAge,r[Xo],r.recognizedTokenTypes):(async function(i,s,o,a,c){const d=await Wd(i,s,o,void 0,a,c),f=JE(d);if(f){if(s.default_max_age!==void 0){dl(s.default_max_age,!0,'"client.default_max_age"');const p=s0()+i0(s),m=YE(s);if(f.auth_time+s.default_max_age<p-m)throw pt("too much time has elapsed since the last End-User authentication",Ip,{claims:f,now:p,tolerance:m,claim:"auth_time"})}if(f.nonce!==void 0)throw pt('unexpected ID Token "nonce" claim value',Bo,{expected:void 0,claims:f,claim:"nonce"})}return d})(e,t,n,r?.[Xo],r?.recognizedTokenTypes)}const EJ="OAUTH_WWW_AUTHENTICATE_CHALLENGE",xJ="OAUTH_RESPONSE_BODY_ERROR",ZE="OAUTH_UNSUPPORTED_OPERATION",CJ="OAUTH_AUTHORIZATION_RESPONSE_E
10RROR",o0="OAUTH_PARSE_ERROR",Dt="OAUTH_INVALID_RESPONSE",_L="OAUTH_RESPONSE_IS_NOT_JSON",ek="OAUTH_RESPONSE_IS_NOT_CONFORM",wL="OAUTH_HTTP_REQUEST_FORBIDDEN",bL="OAUTH_REQUEST_PROTOCOL_FORBIDDEN",Ip="OAUTH_JWT_TIMESTAMP_CHECK_FAILED",Bo="OAUTH_JWT_CLAIM_COMPARISON_FAILED",XE="OAUTH_JSON_ATTRIBUTE_COMPARISON_FAILED",kJ="OAUTH_MISSING_SERVER_METADATA",TJ="OAUTH_INVALID_SERVER_METADATA";function wm(e){if(e.bodyUsed)throw Zt('"response" body has been used already',"ERR_INVALID_ARG_VALUE")}function uA(e){const{algorithm:t}=e;if(typeof t.modulusLength!="number"||t.modulusLength<2048)throw new Ci("unsupported ".concat(t.name," modulusLength"),{cause:e})}function RJ(e){const{algorithm:t}=e;switch(t.namedCurve){case"P-256":return"SHA-256";case"P-384":return"SHA-384";case"P-521":return"SHA-512";default:throw new Ci("unsupported ECDSA namedCurve",{cause:e})}}async function PJ(e){if(e.method!=="POST")throw Zt("form_post responses are expected to use the POST method","ERR_INVALID_ARG_VALUE",{cause:e});if(yL(e)!=="application/x-www-form-urlencoded")throw Zt("form_post responses are expected to use the application/x-www-form-urlencoded content-type","ERR_INVALID_ARG_VALUE",{cause:e});return(async function(t){if(t.bodyUsed)throw Zt("form_post Request instances must contain a readable body","ERR_INVALID_ARG_VALUE",{cause:t});return t.text()})(e)}function OJ(e,t,n,r){if(e===void 0)if(Array.isArray(t)){if(!t.includes(r.alg))throw pt('unexpected JWT "alg" header parameter',Dt,{header:r,expected:t,reason:"authorization server metadata"})}else{if(n===void 0)throw pt('missing client or server configuration to verify used JWT "alg" header parameter',void 0,{client:e,issuer:t,fallback:n});if(typeof n=="string"?r.alg!==n:typeof n=="function"?!n(r.alg):!n.includes(r.alg))throw pt('unexpected JWT "alg" header parameter',Dt,{header:r,expected:n,reason:"default value"})}else if(typeof e=="string"?r.alg!==e:!e.includes(r.alg))throw pt('unexpected JWT "alg" header parameter',Dt,{header:r,expected:e,reason:"client configuration"})}function bc(e,t){const{0:n,length:r}=e.getAll(t);if(r>1)throw pt('"'.concat(t,'" parameter must be provided only once'),Dt);return n}const AJ=Symbol(),IJ=Symbol();function MJ(e,t,n,r){if(Rs(e),Ps(t),n instanceof URL&&(n=n.searchParams),!(n instanceof URLSearchParams))throw Zt('"parameters" must be an instance of URLSearchParams, or URL',"ERR_INVALID_ARG_TYPE");if(bc(n,"response"))throw pt('"parameters" contains a JARM response, use validateJwtAuthResponse() instead of validateAuthResponse()',Dt,{parameters:n});const i=bc(n,"iss"),s=bc(n,"state");if(!i&&e.authorization_response_iss_parameter_supported)throw pt('response parameter "iss" (issuer) missing',Dt,{parameters:n});if(i&&i!==e.issuer)throw pt('unexpected "iss" (issuer) response parameter value',Dt,{expected:e.issuer,parameters:n});switch(r){case void 0:case IJ:if(s!==void 0)throw pt('unexpected "state" response parameter encountered',Dt,{expected:void 0,parameters:n});break;case AJ:break;default:if(Qn(r,'"expectedState" argument'),s!==r)throw pt(s===void 0?'response parameter "state" missing':'unexpected "state" response parameter value',Dt,{expected:r,parameters:n})}if(bc(n,"error"))throw new mL("authorization response from the server is an error",{cause:n});const o=bc(n,"id_token"),a=bc(n,"token");if(o!==void 0||a!==void 0)throw new Ci("implicit and hybrid flows are not supported");return c=new URLSearchParams(n),QC.add(c),c;var c}async function L_(e){let t,n=arguments.length>1&&arguments[1]!==void 0?arguments[1]:hL;try{t=await e.json()}catch(r){throw n(e),pt('failed to parse "response" body as JSON',o0,r)}if(!r0(t))throw pt('"response" body must be a top level object',Dt,{body:t});return t}const kb=Symbol(),SL=Symbol(),dA=new TextEncoder,Mp=new TextDecoder;function Tb(e){const t=new Uint8Array(e.length);for(let n=0;n<e.length;n++){const r=e.charCodeAt(n);if(r>127)throw new TypeError("non-ASCII string encountered in encode()");t[n]=r}return t}function EL(e){if(Uint8Array.fromBase64)return Uint8Array.fromBase64(e);const t=atob(e),n=new Uint8Array(t.length);for(let r=0;r<t.length;r++)n[r]=t.charCodeAt(r);return n}function pp(e){if(Uint8Array.fromBase64)return Uint8Array.fromBase64(typeof e=="string"?e:Mp.decode(e),{alphabet:"base64url"});let t=e;t instanceof Uint8Array&&(t=Mp.decode(t)),t=t.replace(/-/g,"+").replace(/_/g,"/");try{return EL(t)}catch{throw new TypeError("The input to be decoded is not correctly encoded.")}}
10let Cr=class extends Error{constructor(t,n){var r;super(t,n),Oe(this,"code","ERR_JOSE_GENERIC"),this.name=this.constructor.name,(r=Error.captureStackTrace)===null||r===void 0||r.call(Error,this,this.constructor)}};Oe(Cr,"code","ERR_JOSE_GENERIC");let ps=class extends Cr{constructor(t,n){let r=arguments.length>2&&arguments[2]!==void 0?arguments[2]:"unspecified",i=arguments.length>3&&arguments[3]!==void 0?arguments[3]:"unspecified";super(t,{cause:{claim:r,reason:i,payload:n}}),Oe(this,"code","ERR_JWT_CLAIM_VALIDATION_FAILED"),Oe(this,"claim",void 0),Oe(this,"reason",void 0),Oe(this,"payload",void 0),this.claim=r,this.reason=i,this.payload=n}};Oe(ps,"code","ERR_JWT_CLAIM_VALIDATION_FAILED");let QE=class extends Cr{constructor(t,n){let r=arguments.length>2&&arguments[2]!==void 0?arguments[2]:"unspecified",i=arguments.length>3&&arguments[3]!==void 0?arguments[3]:"unspecified";super(t,{cause:{claim:r,reason:i,payload:n}}),Oe(this,"code","ERR_JWT_EXPIRED"),Oe(this,"claim",void 0),Oe(this,"reason",void 0),Oe(this,"payload",void 0),this.claim=r,this.reason=i,this.payload=n}};Oe(QE,"code","ERR_JWT_EXPIRED");let xL=class extends Cr{constructor(){super(...arguments),Oe(this,"code","ERR_JOSE_ALG_NOT_ALLOWED")}};Oe(xL,"code","ERR_JOSE_ALG_NOT_ALLOWED");let xi=class extends Cr{constructor(){super(...arguments),Oe(this,"code","ERR_JOSE_NOT_SUPPORTED")}};Oe(xi,"code","ERR_JOSE_NOT_SUPPORTED");Oe(class extends Cr{constructor(){super(arguments.length>0&&arguments[0]!==void 0?arguments[0]:"decryption operation failed",arguments.length>1?arguments[1]:void 0),Oe(this,"code","ERR_JWE_DECRYPTION_FAILED")}},"code","ERR_JWE_DECRYPTION_FAILED");Oe(class extends Cr{constructor(){super(...arguments),Oe(this,"code","ERR_JWE_INVALID")}},"code","ERR_JWE_INVALID");let mr=class extends Cr{constructor(){super(...arguments),Oe(this,"code","ERR_JWS_INVALID")}};
10Oe(mr,"code","ERR_JWS_INVALID");let ex=class extends Cr{constructor(){super(...arguments),Oe(this,"code","ERR_JWT_INVALID")}};Oe(ex,"code","ERR_JWT_INVALID");Oe(class extends Cr{constructor(){super(...arguments),Oe(this,"code","ERR_JWK_INVALID")}},"code","ERR_JWK_INVALID");let tk=class extends Cr{constructor(){super(...arguments),Oe(this,"code","ERR_JWKS_INVALID")}};Oe(tk,"code","ERR_JWKS_INVALID");let nk=class extends Cr{constructor(){super(arguments.length>0&&arguments[0]!==void 0?arguments[0]:"no applicable key found in the JSON Web Key Set",arguments.length>1?arguments[1]:void 0),Oe(this,"code","ERR_JWKS_NO_MATCHING_KEY")}};Oe(nk,"code","ERR_JWKS_NO_MATCHING_KEY");let CL=class extends Cr{constructor(){super(arguments.length>0&&arguments[0]!==void 0?arguments[0]:"multiple matching keys found in the JSON Web Key Set",arguments.length>1?arguments[1]:void 0),Oe(this,Symbol.asyncIterator,void 0),Oe(this,"code","ERR_JWKS_MULTIPLE_MATCHING_KEYS")}};Oe(CL,"code","ERR_JWKS_MULTIPLE_MATCHING_KEYS");let kL=class extends Cr{constructor(){super(arguments.length>0&&arguments[0]!==void 0?arguments[0]:"request timed out",arguments.length>1?arguments[1]:void 0),Oe(this,"code","ERR_JWKS_TIMEOUT")}};Oe(kL,"code","ERR_JWKS_TIMEOUT");let TL=class extends Cr{constructor(){super(arguments.length>0&&arguments[0]!==void 0?arguments[0]:"signature verification failed",arguments.length>1?arguments[1]:void 0),Oe(this,"code","ERR_JWS_SIGNATURE_VERIFICATION_FAILED")}};Oe(TL,"code","ERR_JWS_SIGNATURE_VERIFICATION_FAILED");const zs=function(e){let t=arguments.length>1&&arguments[1]!==void 0?arguments[1]:"algorithm.name";return new TypeError("CryptoKey does not support this operation, its ".concat(t," must be ").concat(e))},Gu=(e,t)=>e.name===t;function Rb(e){return parseInt(e.name.slice(4),10)}function DJ(e,t,n){switch(t){case"HS256":case"HS384":case"HS512":{if(!Gu(e.algorithm,"HMAC"))throw zs("HMAC");const r=parseInt(t.slice(2),10);
10if(Rb(e.algorithm.hash)!==r)throw zs("SHA-".concat(r),"algorithm.hash");break}case"RS256":case"RS384":case"RS512":{if(!Gu(e.algorithm,"RSASSA-PKCS1-v1_5"))throw zs("RSASSA-PKCS1-v1_5");const r=parseInt(t.slice(2),10);if(Rb(e.algorithm.hash)!==r)throw zs("SHA-".concat(r),"algorithm.hash");break}case"PS256":case"PS384":case"PS512":{if(!Gu(e.algorithm,"RSA-PSS"))throw zs("RSA-PSS");const r=parseInt(t.slice(2),10);if(Rb(e.algorithm.hash)!==r)throw zs("SHA-".concat(r),"algorithm.hash");break}case"Ed25519":case"EdDSA":if(!Gu(e.algorithm,"Ed25519"))throw zs("Ed25519");break;case"ML-DSA-44":case"ML-DSA-65":case"ML-DSA-87":if(!Gu(e.algorithm,t))throw zs(t);break;case"ES256":case"ES384":case"ES512":{if(!Gu(e.algorithm,"ECDSA"))throw zs("ECDSA");const r=(function(i){switch(i){case"ES256":return"P-256";case"ES384":return"P-384";case"ES512":return"P-521";default:throw new Error("unreachable")}})(t);if(e.algorithm.namedCurve!==r)throw zs(r,"algorithm.namedCurve");break}default:throw new TypeError("CryptoKey does not support this operation")}(function(r,i){if(!r.usages.includes(i))throw new TypeError("CryptoKey does not support this operation, its usages must include ".concat(i,"."))})(e,n)}function RL(e,t){for(var n=arguments.length,r=new Array(n>2?n-2:0),i=2;i<n;i++)r[i-2]=arguments[i];if((r=r.filter(Boolean)).length>2){const o=r.pop();e+="one of type ".concat(r.join(", "),", or ").concat(o,".")}else r.length===2?e+="one of type ".concat(r[0]," or ").concat(r[1],"."):e+="of type ".concat(r[0],".");if(t==null)e+=" Received ".concat(t);else if(typeof t=="function"&&t.name)e+=" Received function ".concat(t.name);else if(typeof t=="object"&&t!=null){var s;(s=t.constructor)!==null&&s!==void 0&&s.name&&(e+=" Received an instance of ".concat(t.constructor.name))}return e}const fA=function(e,t){for(var n=arguments.length,r=new Array(n>2?n-2:0),i=2;i<n;i++)r[i-2]=arguments[i];return RL("Key for the ".concat(e," algorithm must be "),t,...r)},PL=e=>{if(e?.[Symbol.toStringTag]==="CryptoKey")return!0;try{return e instanceof CryptoKey}catch{return!1}},OL=e=>e?.[Symbol.toStringTag]==="KeyObject",hA=e=>PL(e)||OL(e);function wl(e){if(typeof(t=e)!="object"||t===null||Object.prototype.toString.call(e)!=="[object Object]")return!1;var t;if(Object.getPrototypeOf(e)===null)return!0;let n=e;for(;Object.getPrototypeOf(n)!==null;)n=Object.getPrototypeOf(n);return Object.getPrototypeOf(e)===n}const Pb=(e,t)=>{if(e.byteLength!==t.length)return!1;for(let n=0;n<e.byteLength;n++)if(e[n]!==t[n])return!1;return!0},mp=e=>{const t=e.data[e.pos++];if(128&t){const n=127&t;let r=0;for(let i=0;i<n;i++)r=r<<8|e.data[e.pos++];return r}return t},gp=(e,t,n)=>{if(e.data[e.pos++]!==t)throw new Error(n)},pA=(e,t)=>{const n=e.data.subarray(e.pos,e.pos+t);return e.pos+=t,n},LJ=e=>{const t=(i=>{gp(i,6,"Expected algorithm OID");const s=mp(i);return pA(i,s)})(e);if(Pb(t,[43,101,110]))return"X25519";if(!Pb(t,[42,134,72,206,61,2,1]))throw new Error("Unsupported key algorithm");gp(e,6,"Expected curve OID");const n=mp(e),r=pA(e,n);for(const{name:i,oid:s}of[{name:"P-256",oid:[42,134,72,206,61,3,1,7]},{name:"P-384",oid:[43,129,4,0,34]},{name:"P-521",oid:[43,129,4,0,35]}])if(Pb(r,s))return i;throw new Error("Unsupported named curve")},NJ=async(e,t,n,r)=>{var i;let s,o;const a=()=>["sign"];switch(n){case"PS256":case"PS384":case"PS512":s={name:"RSA-PSS",hash:"SHA-".concat(n.slice(-3))},o=a();break;case"RS256":case"RS384":case"RS512":s={name:"RSASSA-PKCS1-v1_5",hash:"SHA-".concat(n.slice(-3))},o=a();break;case"RSA-OAEP":case"RSA-OAEP-256":case"RSA-OAEP-384":case"RSA-OAEP-512":s={name:"RSA-OAEP",hash:"SHA-".concat(parseInt(n.slice(-3),10)||1)},o=["decrypt","unwrapKey"];break;case"ES256":case"ES384":case"ES512":s={name:"ECDSA",namedCurve:{ES256:"P-256",ES384:"P-384",ES512:"P-521"}[n]},o=a();break;case"ECDH-ES":case"ECDH-ES+A128KW":case"ECDH-ES+A192KW":case"ECDH-ES+A256KW":try{const c=r.getNamedCurve(t);s=c==="X25519"?{name:"X25519"}:{name:"ECDH",namedCurve:c}}catch{throw new xi("Invalid or unsupported key format")}o=["deriveBits"];break;
10case"Ed25519":case"EdDSA":s={name:"Ed25519"},o=a();break;case"ML-DSA-44":case"ML-DSA-65":case"ML-DSA-87":s={name:n},o=a();break;default:throw new xi('Invalid or unsupported "alg" (Algorithm) value')}return crypto.subtle.importKey(e,t,s,(i=r?.extractable)!==null&&i!==void 0?i:!1,o)},$J=(e,t,n)=>{var r;const i=((o,a)=>EL(o.replace(a,"")))(e,/(?:-----(?:BEGIN|END) PRIVATE KEY-----|\s)/g);let s=n;return t!=null&&(r=t.startsWith)!==null&&r!==void 0&&r.call(t,"ECDH-ES")&&(s||(s={}),s.getNamedCurve=o=>{const a={data:o,pos:0};return(function(c){gp(c,48,"Invalid PKCS#8 structure"),mp(c),gp(c,2,"Expected version field");const d=mp(c);c.pos+=d,gp(c,48,"Expected algorithm identifier"),mp(c)})(a),LJ(a)}),NJ("pkcs8",i,t,s)};async function yv(e){var t,n;if(!e.alg)throw new TypeError('"alg" argument is required when "jwk.alg" is not present');const{algorithm:r,keyUsages:i}=(function(o){let a,c;switch(o.kty){case"AKP":switch(o.alg){case"ML-DSA-44":case"ML-DSA-65":case"ML-DSA-87":a={name:o.alg},c=o.priv?["sign"]:["verify"];break;default:throw new xi('Invalid or unsupported JWK "alg" (Algorithm) Parameter value')}break;case"RSA":switch(o.alg){case"PS256":case"PS384":case"PS512":a={name:"RSA-PSS",hash:"SHA-".concat(o.alg.slice(-3))},c=o.d?["sign"]:["verify"];break;case"RS256":case"RS384":case"RS512":a={name:"RSASSA-PKCS1-v1_5",hash:"SHA-".concat(o.alg.slice(-3))},c=o.d?["sign"]:["verify"];break;case"RSA-OAEP":case"RSA-OAEP-256":case"RSA-OAEP-384":case"RSA-OAEP-512":a={name:"RSA-OAEP",hash:"SHA-".concat(parseInt(o.alg.slice(-3),10)||1)},c=o.d?["decrypt","unwrapKey"]:["encrypt","wrapKey"];break;default:throw new xi('Invalid or unsupported JWK "alg" (Algorithm) Parameter value')}break;case"EC":switch(o.alg){case"ES256":a={name:"ECDSA",namedCurve:"P-256"},c=o.d?["sign"]:["verify"];break;case"ES384":a={name:"ECDSA",namedCurve:"P-384"},c=o.d?["sign"]:["verify"];break;case"ES512":a={name:"ECDSA",namedCurve:"P-521"},c=o.d?["sign"]:["verify"];break;case"ECDH-ES":case"ECDH-ES+A128KW":case"ECDH-ES+A192KW":case"ECDH-ES+A256KW":a={name:"ECDH",namedCurve:o.crv},c=o.d?["deriveBits"]:[];break;default:throw new xi('Invalid or unsupported JWK "alg" (Algorithm) Parameter value')}break;
10case"OKP":switch(o.alg){case"Ed25519":case"EdDSA":a={name:"Ed25519"},c=o.d?["sign"]:["verify"];break;case"ECDH-ES":case"ECDH-ES+A128KW":case"ECDH-ES+A192KW":case"ECDH-ES+A256KW":a={name:o.crv},c=o.d?["deriveBits"]:[];break;default:throw new xi('Invalid or unsupported JWK "alg" (Algorithm) Parameter value')}break;default:throw new xi('Invalid or unsupported JWK "kty" (Key Type) Parameter value')}return{algorithm:a,keyUsages:c}})(e),s=et({},e);return s.kty!=="AKP"&&delete s.alg,delete s.use,crypto.subtle.importKey("jwk",s,r,(t=e.ext)!==null&&t!==void 0?t:!e.d&&!e.priv,(n=e.key_ops)!==null&&n!==void 0?n:i)}const tx=e=>wl(e)&&typeof e.kty=="string";let al;const mA=async function(e,t,n){let r=arguments.length>3&&arguments[3]!==void 0&&arguments[3];al||(al=new WeakMap);let i=al.get(e);if(i!=null&&i[n])return i[n];const s=await yv(et(et({},t),{},{alg:n}));return r&&Object.freeze(e),i?i[n]=s:al.set(e,{[n]:s}),s};async function jJ(e,t){if(e instanceof Uint8Array||PL(e))return e;if(OL(e)){if(e.type==="secret")return e.export();if("toCryptoKey"in e&&typeof e.toCryptoKey=="function")try{return((r,i)=>{al||(al=new WeakMap);let s=al.get(r);if(s!=null&&s[i])return s[i];const o=r.type==="public",a=!!o;let c;if(r.asymmetricKeyType==="x25519"){switch(i){case"ECDH-ES":case"ECDH-ES+A128KW":case"ECDH-ES+A192KW":case"ECDH-ES+A256KW":break;default:throw new TypeError("given KeyObject instance cannot be used for this algorithm")}c=r.toCryptoKey(r.asymmetricKeyType,a,o?[]:["deriveBits"])}if(r.asymmetricKeyType==="ed25519"){if(i!=="EdDSA"&&i!=="Ed25519")throw new TypeError("given KeyObject instance cannot be used for this algorithm");c=r.toCryptoKey(r.asymmetricKeyType,a,[o?"verify":"sign"])}switch(r.asymmetricKeyType){case"ml-dsa-44":case"ml-dsa-65":case"ml-dsa-87":if(i!==r.asymmetricKeyType.toUpperCase())throw new TypeError("given KeyObject instance cannot be used for this algorithm");c=r.toCryptoKey(r.asymmetricKeyType,a,[o?"verify":"sign"])}if(r.asymmetricKeyType==="rsa"){let f;switch(i){case"RSA-OAEP":f="SHA-1";break;case"RS256":case"PS256":case"RSA-OAEP-256":f="SHA-256";break;case"RS384":case"PS384":case"RSA-OAEP-384":f="SHA-384";break;case"RS512":case"PS512":case"RSA-OAEP-512":f="SHA-512";break;default:throw new TypeError("given KeyObject instance cannot be used for this algorithm")}if(i.startsWith("RSA-OAEP"))return r.toCryptoKey({name:"RSA-OAEP",hash:f},a,o?["encrypt"]:["decrypt"]);c=r.toCryptoKey({name:i.startsWith("PS")?"RSA-PSS":"RSASSA-PKCS1-v1_5",hash:f},a,[o?"verify":"sign"])}if(r.asymmetricKeyType==="ec"){var d;const f=new Map([["prime256v1","P-256"],["secp384r1","P-384"],["secp521r1","P-521"]]).get((d=r.asymmetricKeyDetails)===null||d===void 0?void 0:d.namedCurve);if(!f)throw new TypeError("given KeyObject instance cannot be used for this algorithm");i==="ES256"&&f==="P-256"&&(c=r.toCryptoKey({name:"ECDSA",namedCurve:f},a,[o?"verify":"sign"])),i==="ES384"&&f==="P-384"&&(c=r.toCryptoKey({name:"ECDSA",namedCurve:f},a,[o?"verify":"sign"])),i==="ES512"&&f==="P-521"&&(c=r.toCryptoKey({name:"ECDSA",namedCurve:f},a,[o?"verify":"sign"])),i.startsWith("ECDH-ES")&&(c=r.toCryptoKey({name:"ECDH",namedCurve:f},a,o?[]:["deriveBits"]))}if(!c)throw new TypeError("given KeyObject instance cannot be used for this algorithm");return s?s[i]=c:al.set(r,{[i]:c}),c})(e,t)}catch(r){if(r instanceof TypeError)throw r}let n=e.export({format:"jwk"});return mA(e,n,t)}if(tx(e))return e.k?pp(e.k):mA(e,e,t,!0);throw new Error("unreachable")}const Yu=e=>e?.[Symbol.toStringTag],Ob=(e,t,n)=>{if(t.use!==void 0){let s;switch(n){case"sign":case"verify":s="sig";break;case"encrypt":case"decrypt":s="enc"}if(t.use!==s)throw new TypeError('Invalid key for this operation, its "use" must be "'.concat(s,'" when present'))}if(t.alg!==void 0&&t.alg!==e)throw new TypeError('Invalid key for this operation, its "alg" must be "'.concat(e,'" when present'));if(Array.isArray(t.key_ops)){var r,i;let s;switch(!0){case n==="verify":case e==="dir":case e.includes("CBC-HS"):s=n;break;case e.startsWith("PBES2"):s="deriveBits";break;case/^A\d{3}(?:GCM)?(?:KW)?$/.test(e):s=!e.includes("GCM")&&e.endsWith("KW")?"unwrapKey":n;break;case n==="encrypt":s="wrapKey";break;case n==="decrypt":s=e.startsWith("RSA")?"unwrapKey":"deriveBits"}if(s&&((r=t.key_ops)===null||r===void 0||(i=r.includes)===null||i===void 0?void 0:i.call(r,s))===!1)throw new TypeError('Invalid key for this operation, its "key_ops" must include "'.concat(s,'" when present'))}return!0};function FJ(e,t,n){switch(e.substring(0,2)){case"A1":case"A2":case"di":case"HS":case"PB":((r,i,s)=>{if(!(i instanceof Uint8Array)){if(tx(i)){if((o=>o.kty==="oct"&&typeof o.k=="string")(i)&&Ob(r,i,s))return;throw new TypeError('JSON Web Key for symmetric algorithms must have JWK "kty" (Key Type) equal to "oct" and the JWK "k" (Key Value) present')}if(!hA(i))throw new TypeError(fA(r,i,"CryptoKey","KeyObject","JSON Web Key","Uint8Array"));if(i.type!=="secret")throw new TypeError("".concat(Yu(i),' instances for symmetric algorithms must be of type "secret"'))}})(e,t,n);break;default:((r,i,s)=>{if(tx(i))switch(s){case"decrypt":case"sign":if((o=>o.kty!=="oct"&&(o.kty==="AKP"&&typeof o.priv=="string"||typeof o.d=="str
10ing"))(i)&&Ob(r,i,s))return;throw new TypeError("JSON Web Key for this operation must be a private JWK");case"encrypt":case"verify":if((o=>o.kty!=="oct"&&o.d===void 0&&o.priv===void 0)(i)&&Ob(r,i,s))return;throw new TypeError("JSON Web Key for this operation must be a public JWK")}if(!hA(i))throw new TypeError(fA(r,i,"CryptoKey","KeyObject","JSON Web Key"));if(i.type==="secret")throw new TypeError("".concat(Yu(i),' instances for asymmetric algorithms must not be of type "secret"'));if(i.type==="public")switch(s){case"sign":throw new TypeError("".concat(Yu(i),' instances for asymmetric algorithm signing must be of type "private"'));case"decrypt":throw new TypeError("".concat(Yu(i),' instances for asymmetric algorithm decryption must be of type "private"'))}if(i.type==="private")switch(s){case"verify":throw new TypeError("".concat(Yu(i),' instances for asymmetric algorithm verifying must be of type "public"'));case"encrypt":throw new TypeError("".concat(Yu(i),' instances for asymmetric algorithm encryption must be of type "public"'))}})(e,t,n)}}var Ey,Ab;let ro,gA;(typeof navigator>"u"||(Ey=navigator.userAgent)===null||Ey===void 0||(Ab=Ey.startsWith)===null||Ab===void 0||!Ab.call(Ey,"Mozilla/5.0 "))&&(gA="".concat("openid-client","/").concat("v6.8.1"),ro={"user-agent":gA});const Sr=e=>vv.get(e);let vv,xy;function AL(e){return e!==void 0?aA(e):(xy||(xy=new WeakMap),(t,n,r,i)=>{let s;return(s=xy.get(n))||((function(o,a){if(typeof o!="string")throw io("".concat(a," must be a string"),Sm);if(o.length===0)throw io("".concat(a," must not be empty"),bm)})(n.client_secret,'"metadata.client_secret"'),s=aA(n.client_secret),xy.set(n,s)),s(t,n,r,i)})}const ll=Os,bm="ERR_INVALID_ARG_VALUE",Sm="ERR_INVALID_ARG_TYPE";function io(e,t,n){const r=new TypeError(e,{cause:n});return Object.assign(r,{code:t}),r}function UJ(e){return(async function(t){return Qn(t,"codeVerifier"),Nc(await crypto.subtle.digest("SHA-256",Md(t)))})(e)}function zJ(){return pL()}let a0=class extends Error{constructor(t,n){var r;super(t,n),Oe(this,"code",void 0),this.name=this.constructor.name,this.code=n?.code,(r=Error.captureStackTrace)===null||r===void 0||r.call(Error,this,this.constructor)}};function Fr(e,t,n){return new a0(e,{cause:t,code:n})}function qr(e){if(e instanceof TypeError||e instanceof a0||e instanceof D_||e instanceof mL||e instanceof JC)throw e;if(e instanceof GC)switch(e.code){case wL:throw Fr("only requests to HTTPS are allowed",e,e.code);case bL:throw Fr("only requests to HTTP or HTTPS are allowed",e,e.code);case ek:throw Fr("unexpected HTTP response status code",e.cause,e.code);case _L:throw Fr("unexpected response content-type",e.cause,e.code);case o0:throw Fr("parsing error occured",e,e.code);case Dt:throw Fr("invalid response encountered",e,e.code);case Bo:throw Fr("unexpected JWT claim value encountered",e,e.code);case XE:throw Fr("unexpected JSON attribute value encountered",e,e.code);case Ip:throw Fr("JWT timestamp claim value failed validation",e,e.code);default:throw Fr(e.message,e,e.code)}if(e instanceof Ci)throw Fr("unsupported operation",e,e.code);if(e instanceof DOMException)switch(e.name){case"OperationError":throw Fr("runtime operation error",e,ZE);case"NotSupportedError":throw Fr("runtime unsupported operation",e,ZE);case"TimeoutError":throw Fr("operation timed out",e,"OAUTH_TIMEOUT");case"AbortError":throw Fr("operation aborted",e,"OAUTH_ABORT")}throw new a0("something went wrong",{cause:e})}async function BJ(e,t,n,r,i){const s=await(async function(c,d){var f,p;if(!(c instanceof URL))throw io('"server" must be an instance of URL',Sm);const m=!c.href.includes("/.well-known/"),v=(f=d?.timeout)!==null&&f!==void 0?f:30,w=AbortSignal.timeout(1e3*v),_=await(m?lJ(c,{algorithm:d?.algorithm,[Os]:d?.[ll],[ns]:d==null||(p=d.execute)===null||p===void 0?void 0:p.includes(_A),signal:w,headers:new Headers(ro)}):(d?.[ll]||fetch)((YC(c,d==null||(b=d.execute)===null||b===void 0||!b.includes(_A)),c.href),{headers:Object.fromEntries(new Headers(et({accept:"application/json"},ro)).entries()),body:void 0,method:"GET",redirect:"manual",signal:w})).then((C=>(async function(P,D){const F=P;if(!(F instanceof URL)&&F!==kb)throw Zt('"expectedIssuerIdentifier" must be an instance of URL',"ERR_INVALID_ARG_TYPE");if(!gf(D,Response))throw Zt('"response" must be an instance of Response',"ERR_INVALID_ARG_TYPE");if(D.status!==200)throw pt('"response" is not a conform Authorization Server Metadata response
10(unexpected HTTP status code)',ek,D);wm(D);const R=await L_(D);if(Qn(R.issuer,'"response" body "issuer" property',Dt,{body:R}),F!==kb&&new URL(R.issuer).href!==F.href)throw pt('"response" body "issuer" property does not match the expected value',XE,{expected:F.href,body:R,attribute:"issuer"});return R})(kb,C))).catch(qr);var b;return m&&new URL(_.issuer).href!==c.href&&((function(C,P,D){return!(C.origin!=="https://login.microsoftonline.com"||D!=null&&D.algorithm&&D.algorithm!=="oidc"||(P[IL]=!0,0))})(c,_,d)||(function(C,P){return!(!C.hostname.endsWith(".b2clogin.com")||P!=null&&P.algorithm&&P.algorithm!=="oidc")})(c,d)||(()=>{throw new a0("discovered metadata issuer does not match the expected issuer",{code:XE,cause:{expected:c.href,body:_,attribute:"issuer"}})})()),_})(e,i),o=new l0(s,t,n,r);let a=Sr(o);if(i!=null&&i[ll]&&(a.fetch=i[ll]),i!=null&&i.timeout&&(a.timeout=i.timeout),i!=null&&i.execute)for(const c of i.execute)c(o);return o}new TextDecoder;const IL=Symbol();let l0=class{constructor(t,n,r,i){var s,o,a,c,d;
10if(typeof n!="string"||!n.length)throw io('"clientId" must be a non-empty string',Sm);if(typeof r=="string"&&(r={client_secret:r}),((s=r)===null||s===void 0?void 0:s.client_id)!==void 0&&n!==r.client_id)throw io('"clientId" and "metadata.client_id" must be the same',bm);const f=et(et({},structuredClone(r)),{},{client_id:n});let p;f[qE]=(o=(a=r)===null||a===void 0?void 0:a[qE])!==null&&o!==void 0?o:0,f[KE]=(c=(d=r)===null||d===void 0?void 0:d[KE])!==null&&c!==void 0?c:30,p=i||(typeof f.client_secret=="string"&&f.client_secret.length?AL(f.client_secret):(_,b,C,P)=>{C.set("client_id",b.client_id)});let m=Object.freeze(f);const v=structuredClone(t);IL in t&&(v[SL]=_=>{let{claims:{tid:b}}=_;return t.issuer.replace("{tenantid}",b)});let w=Object.freeze(v);vv||(vv=new WeakMap),vv.set(this,{__proto__:null,as:w,c:m,auth:p,tlsOnly:!0,jwksCache:{}})}serverMetadata(){const t=structuredClone(Sr(this).as);return(function(n){Object.defineProperties(n,(function(r){return{supportsPKCE:{__proto__:null,value(){var i;let s=arguments.length>0&&arguments[0]!==void 0?arguments[0]:"S256";return((i=r.code_challenge_methods_supported)===null||i===void 0?void 0:i.includes(s))===!0}}}})(n))})(t),t}clientMetadata(){return structuredClone(Sr(this).c)}get timeout(){return Sr(this).timeout}set timeout(t){Sr(this).timeout=t}get[ll](){return Sr(this).fetch}set[ll](t){Sr(this).fetch=t}};function Em(e){Object.defineProperties(e,(function(t){let n;if(t.expires_in!==void 0){const r=new Date;r.setSeconds(r.getSeconds()+t.expires_in),n=r.getTime()}
10return{expiresIn:{__proto__:null,value(){if(n){const r=Date.now();return n>r?Math.floor((n-r)/1e3):0}}},claims:{__proto__:null,value(){try{return JE(this)}catch{return}}}}})(e))}async function yA(e,t,n){var r;let i=arguments.length>3&&arguments[3]!==void 0&&arguments[3];const s=(r=e.headers.get("retry-after"))===null||r===void 0?void 0:r.trim();if(s===void 0)return;let o;if(/^\d+$/.test(s))o=parseInt(s,10);else{const a=new Date(s);if(Number.isFinite(a.getTime())){const c=new Date,d=a.getTime()-c.getTime();d>0&&(o=Math.ceil(d/1e3))}}if(i&&!Number.isFinite(o))throw new GC("invalid Retry-After header value",{cause:e});o>t&&await ML(o-t,n)}function ML(e,t){return new Promise(((n,r)=>{const i=s=>{try{t.throwIfAborted()}catch(a){return void r(a)}if(s<=0)return void n();const o=Math.min(s,5);setTimeout((()=>i(s-o)),1e3*o)};i(e)}))}async function vA(e,t){ua(e);const{as:n,c:r,auth:i,fetch:s,tlsOnly:o,timeout:a}=Sr(e);return(async function(c,d,f,p,m){Rs(c),Ps(d);const v=vm(c,"backchannel_authentication_endpoint",d.use_mtls_endpoint_aliases,m?.[ns]!==!0),w=new URLSearchParams(p);w.set("client_id",d.client_id);const _=M_(m?.headers);return _.set("accept","application/json"),XC(c,d,f,v,w,_,m)})(n,r,i,t,{[Os]:s,[ns]:!o,headers:new Headers(ro),signal:fu(a)}).then((c=>(async function(d,f,p){if(Rs(d),Ps(f),!gf(p,Response))throw Zt('"response" must be an instance of Response',"ERR_INVALID_ARG_TYPE");await ZC(p,200,"Backchannel Authentication Endpoint"),wm(p);const m=await L_(p);Qn(m.auth_req_id,'"response" body "auth_req_id" property',Dt,{body:m});let v=typeof m.expires_in!="number"?parseFloat(m.expires_in):m.expires_in;return dl(v,!0,'"response" body "expires_in" property',Dt,{body:m}),m.expires_in=v,m.interval!==void 0&&dl(m.interval,!1,'"response" body "interval" property',Dt,{body:m}),m})(n,r,c))).catch(qr)}async function DL(e,t,n,r){var i,s;ua(e),n=new URLSearchParams(n);let o=(i=t.interval)!==null&&i!==void 0?i:5;const a=(s=r?.signal)!==null&&s!==void 0?s:AbortSignal.timeout(1e3*t.expires_in);try{await ML(o,a)}catch(R){qr(R)}const{as:c,c:d,auth:f,fetch:p,tlsOnly:m,nonRepudiation:v,timeout:w,decrypt:_}=Sr(e),b=(R,I)=>DL(e,et(et({},t),{},{interval:R}),n,et(et({},r),{},{signal:a,flag:I})),C=await(async function(R,I,k,L,B){Rs(R),Ps(I),Qn(L,'"authReqId"');const A=new URLSearchParams(B?.additionalParameters);return A.set("auth_req_id",L),_m(R,I,k,"urn:openid:params:grant-type:ciba",A,B)})(c,d,f,t.auth_req_id,{[Os]:p,[ns]:!m,additionalParameters:n,DPoP:r?.DPoP,headers:new Headers(ro),signal:a.aborted?a:fu(w)}).catch(qr);var P;if(C.status===503&&C.headers.has("retry-after"))return await yA(C,o,a,!0),await((P=C.body)===null||P===void 0?void 0:P.cancel()),b(o);const D=(async function(R,I,k,L){return Wd(R,I,k,void 0,L?.[Xo],L?.recognizedTokenTypes)})(c,d,C,{[Xo]:_});let F;try{F=await D}catch(R){if(xm(R,r))return b(o,fl);if(R instanceof D_)switch(R.error){case"slow_down":o+=5;case"authorization_pending":return await yA(R.response,o,a),b(o)}qr(R)}return F.id_token&&await v?.(C),Em(F),F}function _A(e){Sr(e).tlsOnly=!1}async function LL(e,t,n,r,i){if(ua(e),!(i?.flag===fl||t instanceof URL||(function(R,I){try{return Object.getPrototypeOf(R)[Symbol.toStringTag]===I}catch{return!1}})(t,"Request")))throw io('"currentUrl" must be an instance of URL, or Request',Sm);let s,o;const{as:a,c,auth:d,fetch:f,tlsOnly:p,jarm:m,hybrid:v,nonRepudiation:w,timeout:_,decrypt:b,implicit:C}=Sr(e);if(i?.flag===fl)s=i.authResponse,o=i.redirectUri;else{if(!(t instanceof URL)){const R=t;switch(t=new URL(t.url),R.method){case"GET":break;case"POST":const I=new URLSearchParams(await PJ(R));if(v)t.hash=I.toString();else for(const[k,L]of I.entries())t.searchParams.append(k,L);break;default:throw io("unexpected Request HTTP method",bm)}}switch(o=(function(R){return(R=new URL(R)).search="",R.hash="",R.href})(t),!0){case!!m:s=await m(t,n?.expectedState);break;case!!v:s=await v(t,n?.expectedNonce,n?.expectedState,n?.maxAge);break;case!!C:throw new TypeError("authorizationCodeGrant() cannot be used by response_type=id_token clients");default:try{s=MJ(a,c,t.searchParams,n?.expectedState)}catch(R){qr(R)}}}const P=await(async function(R,I,k,L,B,A,V){if(Rs(R),Ps(I),!QC.has(L))throw Zt('"callbackParameters" must be an instance of URLSearchParams obtained from "validateAuthResponse()", or "validateJwtAuthResponse()',"E
10RR_INVALID_ARG_VALUE");Qn(B,'"redirectUri"');const K=bc(L,"code");if(!K)throw pt('no authorization code in "callbackParameters"',Dt);const W=new URLSearchParams(V?.additionalParameters);return W.set("redirect_uri",B),W.set("code",K),A!==cA&&(Qn(A,'"codeVerifier"'),W.set("code_verifier",A)),_m(R,I,k,"authorization_code",W,V)})(a,c,d,s,o,n?.pkceCodeVerifier||cA,{additionalParameters:r,[Os]:f,[ns]:!p,DPoP:i?.DPoP,headers:new Headers(ro),signal:fu(_)}).catch(qr);typeof n?.expectedNonce!="string"&&typeof n?.maxAge!="number"||(n.idTokenExpected=!0);const D=SJ(a,c,P,{expectedNonce:n?.expectedNonce,maxAge:n?.maxAge,requireIdToken:n?.idTokenExpected,[Xo]:b});let F;try{F=await D}catch(R){if(xm(R,i))return LL(e,void 0,n,r,et(et({},i),{},{flag:fl,authResponse:s,redirectUri:o}));qr(R)}return F.id_token&&await w?.(P),Em(F),F}async function NL(e,t,n,r){ua(e),n=new URLSearchParams(n);const{as:i,c:s,auth:o,fetch:a,tlsOnly:c,nonRepudiation:d,timeout:f,decrypt:p}=Sr(e),m=await(async function(_,b,C,P,D){Rs(_),Ps(b),Qn(P,'"refreshToken"');const F=new URLSearchParams(D?.additionalParameters);return F.set("refresh_token",P),_m(_,b,C,"refresh_token",F,D)})(i,s,o,t,{[Os]:a,[ns]:!c,additionalParameters:n,DPoP:r?.DPoP,headers:new Headers(ro),signal:fu(f)}).catch(qr),v=(async function(_,b,C,P){return Wd(_,b,C,void 0,P?.[Xo],P?.recognizedTokenTypes)})(i,s,m,{[Xo]:p});let w;try{w=await v}catch(_){if(xm(_,r))return NL(e,t,n,et(et({},r),{},{flag:fl}));qr(_)}return w.id_token&&await d?.(m),Em(w),w}async function $L(e,t,n){ua(e),t=new URLSearchParams(t);const{as:r,c:i,auth:s,fetch:o,tlsOnly:a,timeout:c}=Sr(e),d=await(async function(m,v,w,_,b){return Rs(m),Ps(v),_m(m,v,w,"client_credentials",new URLSearchParams(_),b)})(r,i,s,t,{[Os]:o,[ns]:!a,DPoP:n?.DPoP,headers:new Headers(ro),signal:fu(c)}).catch(qr),f=(async function(m,v,w,_){return Wd(m,v,w,void 0,void 0,void 0)})(r,i,d);let p;try{p=await f}catch(m){if(xm(m,n))return $L(e,t,et(et({},n),{},{flag:fl}));qr(m)}return Em(p),p}function nx(e,t){ua(e);const{as:n,c:r,tlsOnly:i,hybrid:s,jarm:o,implicit:a}=Sr(e),c=vm(n,"authorization_endpoint",!1,i);if((t=new URLSearchParams(t)).has("client_id")||t.set("client_id",r.client_id),!t.has("request_uri")&&!t.has("request")){if(t.has("response_type")||t.set("response_type",s?"code id_token":a?"id_token":"code"),a&&!t.has("nonce"))throw io("response_type=id_token clients must provide a nonce parameter in their authorization request parameters",bm);o&&t.set("response_mode","jwt")}for(const[d,f]of t.entries())c.searchParams.append(d,f);return c}async function jL(e,t,n){ua(e);const r=nx(e,t),{as:i,c:s,auth:o,fetch:a,tlsOnly:c,timeout:d}=Sr(e),f=await(async function(v,w,_,b,C){var P;Rs(v),Ps(w);const D=vm(v,"pushed_authorization_request_endpoint",w.use_mtls_endpoint_aliases,C?.[ns]!==!0),F=new URLSearchParams(b);F.set("client_id",w.client_id);const R=M_(C?.headers);R.set("accept","application/json"),C?.DPoP!==void 0&&(gL(C.DPoP),await C.DPoP.addProof(D,R,"POST"));const I=await XC(v,w,_,D,F,R,C);return C==null||(P=C.DPoP)===null||P===void 0||P.cacheNonce(I,D),I})(i,s,o,r.searchParams,{[Os]:a,[ns]:!c,DPoP:n?.DPoP,headers:new Headers(ro),signal:fu(d)}).catch(qr),p=(async function(v,w,_){if(Rs(v),Ps(w),!gf(_,Response))throw Zt('"response" must be an instance of Response',"ERR_INVALID_ARG_TYPE");await ZC(_,201,"Pushed Authorization Request Endpoint"),wm(_);const b=await L_(_);Qn(b.request_uri,'"response" body "request_uri" property',Dt,{body:b});let C=typeof b.expires_in!="number"?parseFloat(b.expires_in):b.expires_in;return dl(C,!0,'"response" body "expires_in" property',Dt,{body:b}),b.expires_in=C,b})(i,s,f);let m;try{m=await p}catch(v){if(xm(v,n))return jL(e,t,et(et({},n),{},{flag:fl}));qr(v)}return nx(e,{request_uri:m.request_uri})}function ua(e){if(!(e instanceof l0))throw io('"config" must be an instance of Configuration',Sm);if(Object.getPrototypeOf(e)!==l0.prototype)throw io("subclassing Configuration is not allowed",bm)}function fu(e){return e?AbortSignal.timeout(1e3*e):void 0}function xm(e,t){return!(t==null||!t.DPoP||t.flag===fl)&&(function(n){if(n instanceof JC){const{0:r,length:i}=n.cause;return i===1&&r.scheme==="dpop"&&r.parameters.error==="use_dpop_nonce"}return n instanceof D_&&n.error==="use_dpop_nonce"})(e)}Object.freeze(l0.prototype);const fl=Symbol();async function rk(e,t,n,r){ua(e);const{as:i,c:s,auth:o,fetch:a,tlsOnly:c,timeout:d,decrypt:f}=Sr(e),p=await(async function(m,v,w,_,b,C){return Rs(m),Ps(v),Qn(_,'"grantType"'),_m(m,v,w,_,new URLSearchParams(b),C)})(i,s,o,t,new URLSearchParams(n),{[Os]:a,[ns]:!c,DPoP:void 0,headers:new Headers(ro),signal:fu(d)}).then((m=>{let v;return t==="urn:ietf:params:oauth:grant-type:token-exchange"&&(v={n_a:()=>{}}),(async function(w,_,b,C){return Wd(w,_,b,void 0,C?.[Xo],C?.recognizedTokenTypes)})(i,s,m,{[Xo]:f,recognizedTokenTypes:v})})).catch(qr);return Em(p),p}async function HJ(e,t,n){if(t instanceof Uint8Array){if(!e.startsWith("HS"))throw new TypeError((function(r){for(var i=arguments.length,s=new Array(i>1?i-1:0),o=1;o<i;o++)s[o-1]=arguments[o];return RL("Key must be ",r,...s)})(t,"CryptoKey","KeyObject","JSON Web Key"));return crypto.subtle.importKey("raw",t,{hash:"SHA-".concat(e.slice(-3)),name:"HMAC"},!1,[n])}return DJ(t,e,n),t}async function VJ(e,t,n,r){const i=await HJ(e,t,"verify");(function(o,a){if(o.startsWith("RS")||o.startsWith("PS")){const{modulusLength:c}=a.algorithm;if(typeof c!="number"||c<2048)throw new TypeError("".concat(o," requires ke
10y modulusLength to be 2048 bits or larger"))}})(e,i);const s=(function(o,a){const c="SHA-".concat(o.slice(-3));switch(o){case"HS256":case"HS384":case"HS512":return{hash:c,name:"HMAC"};case"PS256":case"PS384":case"PS512":return{hash:c,name:"RSA-PSS",saltLength:parseInt(o.slice(-3),10)>>3};case"RS256":case"RS384":case"RS512":return{hash:c,name:"RSASSA-PKCS1-v1_5"};case"ES256":case"ES384":case"ES512":return{hash:c,name:"ECDSA",namedCurve:a.namedCurve};case"Ed25519":case"EdDSA":return{name:"Ed25519"};case"ML-DSA-44":case"ML-DSA-65":case"ML-DSA-87":return{name:o};default:throw new xi("alg ".concat(o," is not supported either by JOSE or your javascript runtime"))}})(e,i.algorithm);try{return await crypto.subtle.verify(s,i,n,r)}catch{return!1}}async function WJ(e,t,n){if(!wl(e))throw new mr("Flattened JWS must be an object");if(e.protected===void 0&&e.header===void 0)throw new mr('Flattened JWS must have either of the "protected" or "header" members');if(e.protected!==void 0&&typeof e.protected!="string")throw new mr("JWS Protected Header incorrect type");if(e.payload===void 0)throw new mr("JWS Payload missing");if(typeof e.signature!="string")throw new mr("JWS Signature missing or incorrect type");if(e.header!==void 0&&!wl(e.header))throw new mr("JWS Unprotected Header incorrect type");let r={};if(e.protected)try{const _=pp(e.protected);r=JSON.parse(Mp.decode(_))}catch{throw new mr("JWS Protected Header is invalid")}if(!(function(){for(var _=arguments.length,b=new Array(_),C=0;C<_;C++)b[C]=arguments[C];const P=b.filter(Boolean);if(P.length===0||P.length===1)return!0;let D;for(const F of P){const R=Object.keys(F);if(D&&D.size!==0)for(const I of R){if(D.has(I))return!1;D.add(I)}else D=new Set(R)}return!0})(r,e.header))throw new mr("JWS Protected and JWS Unprotected Header Parameter names must be disjoint");const i=et(et({},r),e.header),s=(function(_,b,C,P,D){if(D.crit!==void 0&&P?.crit===void 0)throw new _('"crit" (Critical) Header Parameter MUST be integrity protected');if(!P||P.crit===void 0)return new Set;if(!Array.isArray(P.crit)||P.crit.length===0||P.crit.some((R=>typeof R!="string"||R.length===0)))throw new _('"crit" (Critical) Header Parameter MUST be an array of non-empty strings when present');let F;F=C!==void 0?new Map([...Object.entries(C),...b.entries()]):b;for(const R of P.crit){if(!F.has(R))throw new xi('Extension Header Parameter "'.concat(R,'" is not recognized'));if(D[R]===void 0)throw new _('Extension Header Parameter "'.concat(R,'" is missing'));if(F.get(R)&&P[R]===void 0)throw new _('Extension Header Parameter "'.concat(R,'" MUST be integrity protected'))}return new Set(P.crit)})(mr,new Map([["b64",!0]]),n?.crit,r,i);let o=!0;if(s.has("b64")&&(o=r.b64,typeof o!="boolean"))throw new mr('The "b64" (base64url-encode payload) Header Parameter must be a boolean');const{alg:a}=i;if(typeof a!="string"||!a)throw new mr('JWS "alg" (Algorithm) Header Parameter missing or invalid');const c=n&&(function(_,b){if(b!==void 0&&(!Array.isArray(b)||b.some((C=>typeof C!="string"))))throw new TypeError('"'.concat(_,'" option must be an array of strings'));if(b)return new Set(b)})("algorithms",n.algorithms);if(c&&!c.has(a))throw new xL('"alg" (Algorithm) Header Parameter value not allowed');if(o){if(typeof e.payload!="string")throw new mr("JWS Payload must be a string")}else if(typeof e.payload!="string"&&!(e.payload instanceof Uint8Array))throw new mr("JWS Payload must be a string or an Uint8Array instance");let d=!1;typeof t=="function"&&(t=await t(r,e),d=!0),FJ(a,t,"verify");const f=(function(){for(var _=arguments.length,b=new Array(_),C=0;C<_;C++)b[C]=arguments[C];const P=b.reduce(((R,I)=>{let{length:k}=I;return R+k}),0),D=new Uint8Array(P);let F=0;for(const R of b)D.set(R,F),F+=R.length;return D})(e.protected!==void 0?Tb(e.protected):new Uint8Array,Tb("."),typeof e.payload=="string"?o?Tb(e.payload):dA.encode(e.payload):e.payload);let p;try{p=pp(e.signature)}catch{throw new mr("Failed to base64url decode the signature")}const m=await jJ(t,a);if(!await VJ(a,m,p,f))throw new TL;let v;if(o)try{v=pp(e.payload)}catch{throw new mr("Failed to base64url decode the payload")}else v=typeof e.payload=="string"?dA.encode(e.payload):e.payload;const w={payload:v};return e.protected!==void 0&&(w.protectedHeader=r),e.header!==void 0&&(w.unprotectedHeader=e.header),d?et(et({},w),{},{key:m}):w}const qJ=e=>Math.floor(e.getTime()/1e3),KJ=/^(\+|\-)? ?(\d+|\d+\.\d+) ?(seconds?|secs?|s|minutes?|mins?|m|hours?|hrs?|h|days?|d|weeks?|w|years?|yrs?|y)(?: (ago|from now))?$/i;function wA(e){const t=KJ.exec(e);if(!t||t[4]&&t[1])throw new TypeError("Invalid time period format");const n=parseFloat(t[2]);let r;switch(t[3].toLowerCase()){case"sec":case"secs":case"second":case"seconds":case"s":r=Math.round(n);break;case"minute":case"minutes":case"min":case"mins":case"m":r=Math.round(60*n);break;case"hour":case"hours":case"hr":case"hrs":case"h":r=Math.round(3600*n);break;case"day":case"days":case"d":r=Math.round(86400*n);break;case"week":case"weeks":case"w":r=Math.round(604800*n);break;default:r=Math.round(31557600*n)}return t[1]==="-"||t[4]==="ago"?-r:r}const bA=e=>e.includes("/")?e.toLowerCase():"application/".concat(e.toLowerCase()),GJ=(e,t)=>
10typeof e=="string"?t.includes(e):!!Array.isArray(e)&&t.some(Set.prototype.has.bind(new Set(e)));async function YJ(e,t,n){var r;const i=await(async function(a,c,d){if(a instanceof Uint8Array&&(a=Mp.decode(a)),typeof a!="string")throw new mr("Compact JWS must be a string or Uint8Array");const{0:f,1:p,2:m,length:v}=a.split(".");if(v!==3)throw new mr("Invalid Compact JWS");const w=await WJ({payload:p,protected:f,signature:m},c,d),_={payload:w.payload,protectedHeader:w.protectedHeader};return typeof c=="function"?et(et({},_),{},{key:w.key}):_})(e,t,n);if((r=i.protectedHeader.crit)!==null&&r!==void 0&&r.includes("b64")&&i.protectedHeader.b64===!1)throw new ex("JWTs MUST NOT use unencoded payload");const s=(function(a,c){let d,f=arguments.length>2&&arguments[2]!==void 0?arguments[2]:{};try{d=JSON.parse(Mp.decode(c))}catch{}if(!wl(d))throw new ex("JWT Claims Set must be a top-level JSON object");const{typ:p}=f;if(p&&(typeof a.typ!="string"||bA(a.typ)!==bA(p)))throw new ps('unexpected "typ" JWT header value',d,"typ","check_failed");const{requiredClaims:m=[],issuer:v,subject:w,audience:_,maxTokenAge:b}=f,C=[...m];b!==void 0&&C.push("iat"),_!==void 0&&C.push("aud"),w!==void 0&&C.push("sub"),v!==void 0&&C.push("iss");for(const R of new Set(C.reverse()))if(!(R in d))throw new ps('missing required "'.concat(R,'" claim'),d,R,"missing");if(v&&!(Array.isArray(v)?v:[v]).includes(d.iss))throw new ps('unexpected "iss" claim value',d,"iss","check_failed");if(w&&d.sub!==w)throw new ps('unexpected "sub" claim value',d,"sub","check_failed");if(_&&!GJ(d.aud,typeof _=="string"?[_]:_))throw new ps('unexpected "aud" claim value',d,"aud","check_failed");let P;switch(typeof f.clockTolerance){case"string":P=wA(f.clockTolerance);break;case"number":P=f.clockTolerance;break;case"undefined":P=0;break;default:throw new TypeError("Invalid clockTolerance option type")}const{currentDate:D}=f,F=qJ(D||new Date);if((d.iat!==void 0||b)&&typeof d.iat!="number")throw new ps('"iat" claim must be a number',d,"iat","invalid");if(d.nbf!==void 0){if(typeof d.nbf!="number")throw new ps('"nbf" claim must be a number',d,"nbf","invalid");if(d.nbf>F+P)throw new ps('"nbf" claim timestamp check failed',d,"nbf","check_failed")}if(d.exp!==void 0){if(typeof d.exp!="number")throw new ps('"exp" claim must be a number',d,"exp","invalid");if(d.exp<=F-P)throw new QE('"exp" claim timestamp check failed',d,"exp","check_failed")}if(b){const R=F-d.iat;if(R-P>(typeof b=="number"?b:wA(b)))throw new QE('"iat" claim timestamp check failed (too far in the past)',d,"iat","check_failed");if(R<0-P)throw new ps('"iat" claim timestamp check failed (it should be in the past)',d,"iat","check_failed")}return d})(i.protectedHeader,i.payload,n),o={payload:s,protectedHeader:i.protectedHeader};return typeof t=="function"?et(et({},o),{},{key:i.key}):o}function JJ(e){return wl(e)}var Cy,Ib,ky=new WeakMap,Mb=new WeakMap;let ZJ=class{constructor(t){if(ir(this,ky,void 0),ir(this,Mb,new WeakMap),!(function(n){return n&&typeof n=="object"&&Array.isArray(n.keys)&&n.keys.every(JJ)})(t))throw new tk("JSON Web Key Set malformed");xn(ky,this,structuredClone(t))}jwks(){return Ce(ky,this)}async getKey(t,n){const{alg:r,kid:i}=et(et({},t),n?.header),s=(function(d){switch(typeof d=="string"&&d.slice(0,2)){case"RS":case"PS":return"RSA";case"ES":return"EC";case"Ed":return"OKP";case"ML":return"AKP";default:throw new xi('Unsupported "alg" value for a JSON Web Key Set')}})(r),o=Ce(ky,this).keys.filter((d=>{let f=s===d.kty;if(f&&typeof i=="string"&&(f=i===d.kid),!f||typeof d.alg!="string"&&s!=="AKP"||(f=r===d.alg),f&&typeof d.use=="string"&&(f=d.use==="sig"),f&&Array.isArray(d.key_ops)&&(f=d.key_ops.includes("verify")),f)switch(r){case"ES256":f=d.crv==="P-256";break;case"ES384":f=d.crv==="P-384";break;case"ES512":f=d.crv==="P-521";break;
10case"Ed25519":case"EdDSA":f=d.crv==="Ed25519"}return f})),{0:a,length:c}=o;if(c===0)throw new nk;if(c!==1){const d=new CL,f=Ce(Mb,this);throw d[Symbol.asyncIterator]=iJ((function*(){for(const p of o)try{yield yield rJ(SA(f,p,r))}catch{}})),d}return SA(Ce(Mb,this),a,r)}};async function SA(e,t,n){const r=e.get(t)||e.set(t,{}).get(t);if(r[n]===void 0){const i=await(async function(s,o,a){var c;if(!wl(s))throw new TypeError("JWK must be an object");let d;switch(o!=null||(o=s.alg),d!=null||(d=(c=void 0)!==null&&c!==void 0?c:s.ext),s.kty){case"oct":if(typeof s.k!="string"||!s.k)throw new TypeError('missing "k" (Key Value) Parameter value');return pp(s.k);case"RSA":if("oth"in s&&s.oth!==void 0)throw new xi('RSA JWK "oth" (Other Primes Info) Parameter value is not supported');return yv(et(et({},s),{},{alg:o,ext:d}));case"AKP":if(typeof s.alg!="string"||!s.alg)throw new TypeError('missing "alg" (Algorithm) Parameter value');if(o!==void 0&&o!==s.alg)throw new TypeError("JWK alg and alg option value mismatch");return yv(et(et({},s),{},{ext:d}));case"EC":case"OKP":return yv(et(et({},s),{},{alg:o,ext:d}));default:throw new xi('Unsupported "kty" (Key Type) Parameter value')}})(et(et({},t),{},{ext:!0}),n);if(i instanceof Uint8Array||i.type!=="public")throw new tk("JSON Web Key Set members must be public keys");r[n]=i}return r[n]}function EA(e){const t=new ZJ(e),n=async(r,i)=>t.getKey(r,i);return Object.defineProperties(n,{jwks:{value:()=>structuredClone(t.jwks()),enumerable:!1,configurable:!1,writable:!1}}),n}let rx;(typeof navigator>"u"||(Cy=navigator.userAgent)===null||Cy===void 0||(Ib=Cy.startsWith)===null||Ib===void 0||!Ib.call(Cy,"Mozilla/5.0 "))&&(rx="".concat("jose","/").concat("v6.1.3"));const FL=Symbol(),Db=Symbol();var Lb=new WeakMap,Nb=new WeakMap,$b=new WeakMap,Ty=new WeakMap,cc=new WeakMap,Co=new WeakMap,Ua=new WeakMap,jb=new WeakMap,uc=new WeakMap,dc=new WeakMap;let XJ=class{constructor(t,n){if(ir(this,Lb,void 0),ir(this,Nb,void 0),ir(this,$b,void 0),ir(this,Ty,void 0),ir(this,cc,void 0),ir(this,Co,void 0),ir(this,Ua,void 0),ir(this,jb,void 0),ir(this,uc,void 0),ir(this,dc,void 0),!(t instanceof URL))throw new TypeError("url must be an instance of URL");var r,i;xn(Lb,this,new URL(t.href)),xn(Nb,this,typeof n?.timeoutDuration=="number"?n?.timeoutDuration:5e3),xn($b,this,typeof n?.cooldownDuration=="number"?n?.cooldownDuration:3e4),xn(Ty,this,typeof n?.cacheMaxAge=="number"?n?.cacheMaxAge:6e5),xn(Ua,this,new Headers(n?.headers)),rx&&!Ce(Ua,this).has("User-Agent")&&Ce(Ua,this).set("User-Agent",rx),Ce(Ua,this).has("accept")||(Ce(Ua,this).set("accept","application/json"),Ce(Ua,this).append("accept","application/jwk-set+json")),xn(jb,this,n?.[FL]),n?.[Db]!==void 0&&(xn(dc,this,n?.[Db]),r=n?.[Db],i=Ce(Ty,this),typeof r=="object"&&r!==null&&"uat"in r&&typeof r.uat=="number"&&!(Date.now()-r.uat>=i)&&"jwks"in r&&wl(r.jwks)&&Array.isArray(r.jwks.keys)&&Array.prototype.every.call(r.jwks.keys,wl)&&(xn(cc,this,Ce(dc,this).uat),xn(uc,this,EA(Ce(dc,this).jwks))))}pendingFetch(){return!!Ce(Co,this)}coolingDown(){return typeof Ce(cc,this)=="number"&&Date.now()<Ce(cc,this)+Ce($b,this)}fresh(){return typeof Ce(cc,this)=="number"&&Date.now()<Ce(cc,this)+Ce(Ty,this)}jwks(){var t;return(t=Ce(uc,this))===null||t===void 0?void 0:t.jwks()}async getKey(t,n){Ce(uc,this)&&this.fresh()||await this.reload();try{return await Ce(uc,this).call(this,t,n)}catch(r){if(r instanceof nk&&this.coolingDown()===!1)return await this.reload(),Ce(uc,this).call(this,t,n);throw r}}async reload(){Ce(Co,this)&&(typeof WebSocketPair<"u"||typeof navigator<"u"&&navigator.userAgent==="Cloudflare-Workers"||typeof EdgeRuntime<"u"&&EdgeRuntime==="vercel")&&xn(Co,this,void 0),Ce(Co,this)||xn(Co,this,(async function(t,n,r){const s=await(arguments.length>3&&arguments[3]!==void 0?arguments[3]:fetch)(t,{method:"GET",signal:r,redirect:"manual",headers:n}).catch((o=>{throw o.name==="TimeoutError"?new kL:o}));if(s.status!==200)throw new Cr("Expected 200 OK from the JSON Web Key Set HTTP response");try{return await s.json()}catch{throw new Cr("Failed to parse the JSON Web Key Set HTTP response as JSON")}})(Ce(Lb,this).href,Ce(Ua,this),AbortSignal.timeout(Ce(Nb,this)),Ce(jb,this)).then((t=>{xn(uc,this,EA(t)),Ce(dc,this)&&(Ce(dc,this).uat=Date.now(),Ce(dc,this).jwks=t),xn(cc,this,Date.now()),xn(Co,this,void 0)})).catch((t=>{throw xn(Co,this,void 0),t}))),await Ce(Co,this)}};const QJ=["mfaToken"],eZ=["mfaToken"];
10var fc,Ry,hc,Qa,gd,rn,Rh,Vn,xA=class extends Error{constructor(t,n){super(n),Oe(this,"code",void 0),this.name="NotSupportedError",this.code=t}},da=class extends Error{constructor(t,n,r){super(n),Oe(this,"cause",void 0),Oe(this,"code",void 0),this.code=t,this.cause=r&&{error:r.error,error_description:r.error_description,message:r.message}}},tZ=class extends da{constructor(t,n){super("token_by_code_error",t,n),this.name="TokenByCodeError"}},nZ=class extends da{constructor(t,n){super("token_by_client_credentials_error",t,n),this.name="TokenByClientCredentialsError"}},rZ=class extends da{constructor(t,n){super("token_by_refresh_token_error",t,n),this.name="TokenByRefreshTokenError"}},Fb=class extends da{constructor(t,n){super("token_for_connection_error",t,n),this.name="TokenForConnectionErrorCode"}},Vs=class extends da{constructor(t,n){super("token_exchange_error",t,n),this.name="TokenExchangeError"}},za=class extends Error{constructor(t){super(t),Oe(this,"code","verify_logout_token_error"),this.name="VerifyLogoutTokenError"}},Ub=class extends da{constructor(t){super("backchannel_authentication_error","There was an error when trying to use Client-Initiated Backchannel Authentication.",t),Oe(this,"code","backchannel_authentication_error"),this.name="BackchannelAuthenticationError"}},iZ=class extends da{constructor(t){super("build_authorization_url_error","There was an error when trying to build the authorization URL.",t),this.name="BuildAuthorizationUrlError"}},sZ=class extends da{constructor(t){super("build_link_user_url_error","There was an error when trying to build the Link User URL.",t),this.name="BuildLinkUserUrlError"}},oZ=class extends da{constructor(t){super("build_unlink_user_url_error","There was an error when trying to build the Unlink User URL.",t),this.name="BuildUnlinkUserUrlError"}},aZ=class extends Error{constructor(){super("The client secret or client assertion signing key must be provided."),Oe(this,"code","missing_client_auth_error"),this.name="MissingClientAuthError"}};function ix(e){return Object.entries(e).filter((t=>{let[,n]=t;return n!==void 0})).reduce(((t,n)=>et(et({},t),{},{[n[0]]:n[1]})),{})}var N_=class extends Error{constructor(t,n,r){super(n),Oe(this,"cause",void 0),Oe(this,"code",void 0),this.code=t,this.cause=r&&{error:r.error,error_description:r.error_description,message:r.message}}},UL=class extends N_{constructor(t,n){super("mfa_list_authenticators_error",t,n),this.name="MfaListAuthenticatorsError"}},zL=class extends N_{constructor(t,n){super("mfa_enrollment_error",t,n),this.name="MfaEnrollmentError"}},lZ=class extends N_{constructor(t,n){super("mfa_delete_authenticator_error",t,n),this.name="MfaDeleteAuthenticatorError"}},BL=class extends N_{constructor(t,n){super("mfa_challenge_error",t,n),this.name="MfaChallengeError"}};function cZ(e){return{id:e.id,authenticatorType:e.authenticator_type,active:e.active,name:e.name,oobChannels:e.oob_channels,type:e.type}}var uZ=(fc=new WeakMap,Ry=new WeakMap,hc=new WeakMap,class{constructor(e){var t;ir(this,fc,void 0),ir(this,Ry,void 0),ir(this,hc,void 0),xn(fc,this,"https://".concat(e.domain)),xn(Ry,this,e.clientId),xn(hc,this,(t=e.customFetch)!==null&&t!==void 0?t:function(){return fetch(...arguments)})}async listAuthenticators(e){const t="".concat(Ce(fc,this),"/mfa/authenticators"),{mfaToken:n}=e,r=await Ce(hc,this).call(this,t,{method:"GET",headers:{Authorization:"Bearer ".concat(n),"Content-Type":"application/json"}});if(!r.ok){const i=await r.json();throw new UL(i.error_description||"Failed to list authenticators",i)}return(await r.json()).map(cZ)}async enrollAuthenticator(e){const t="".concat(Ce(fc,this),"/mfa/associate"),{mfaToken:n}=e,r=sA(e,QJ),i={authenticator_types:r.authenticatorTypes};"oobChannels"in r&&(i.oob_channels=r.oobChannels),"phoneNumber"in r&&r.phoneNumber&&(i.phone_number=r.phoneNumber),"email"in r&&r.email&&(i.email=r.email);const s=await Ce(hc,this).call(this,t,{method:"POST",headers:{Authorization:"Bearer ".concat(n),"Content-Type":"application/json"},body:JSON.stringify(i)});if(!s.ok){const o=await s.json();throw new zL(o.error_description||"Failed to enroll authenticator",o)}
10return(function(o){if(o.authenticator_type==="otp")return{authenticatorType:"otp",secret:o.secret,barcodeUri:o.barcode_uri,recoveryCodes:o.recovery_codes,id:o.id};if(o.authenticator_type==="oob")return{authenticatorType:"oob",oobChannel:o.oob_channel,oobCode:o.oob_code,bindingMethod:o.binding_method,id:o.id};throw new Error("Unexpected authenticator type: ".concat(o.authenticator_type))})(await s.json())}async deleteAuthenticator(e){const{authenticatorId:t,mfaToken:n}=e,r="".concat(Ce(fc,this),"/mfa/authenticators/").concat(encodeURIComponent(t)),i=await Ce(hc,this).call(this,r,{method:"DELETE",headers:{Authorization:"Bearer ".concat(n),"Content-Type":"application/json"}});if(!i.ok){const s=await i.json();throw new lZ(s.error_description||"Failed to delete authenticator",s)}}async challengeAuthenticator(e){const t="".concat(Ce(fc,this),"/mfa/challenge"),{mfaToken:n}=e,r=sA(e,eZ),i={mfa_token:n,client_id:Ce(Ry,this),challenge_type:r.challengeType};r.authenticatorId&&(i.authenticator_id=r.authenticatorId);const s=await Ce(hc,this).call(this,t,{method:"POST",headers:{"Content-Type":"application/json"},body:JSON.stringify(i)});if(!s.ok){const o=await s.json();throw new BL(o.error_description||"Failed to challenge authenticator",o)}return(function(o){const a={challengeType:o.challenge_type};return o.oob_code!==void 0&&(a.oobCode=o.oob_code),o.binding_method!==void 0&&(a.bindingMethod=o.binding_method),a})(await s.json())}}),Cc=class HL{constructor(t,n,r,i,s,o,a){Oe(this,"accessToken",void 0),Oe(this,"idToken",void 0),Oe(this,"refreshToken",void 0),Oe(this,"expiresAt",void 0),Oe(this,"scope",void 0),Oe(this,"claims",void 0),Oe(this,"authorizationDetails",void 0),Oe(this,"tokenType",void 0),Oe(this,"issuedTokenType",void 0),this.accessToken=t,this.idToken=r,this.refreshToken=i,this.expiresAt=n,this.scope=s,this.claims=o,this.authorizationDetails=a}static fromTokenEndpointResponse(t){const n=t.id_token?t.claims():void 0,r=new HL(t.access_token,Math.floor(Date.now()/1e3)+Number(t.expires_in),t.id_token,t.refresh_token,t.scope,n,t.authorization_details);return r.tokenType=t.token_type,r.issuedTokenType=t.issued_token_type,r}},sx="openid profile email offline_access",dZ=Object.freeze(new Set(["grant_type","client_id","client_secret","client_assertion","client_assertion_type","subject_token","subject_token_type","requested_token_type","actor_token","actor_token_type","audience","aud","resource","resources","resource_indicator","scope","connection","login_hint","organization","assertion"]));function VL(e){if(e==null)throw new Vs("subject_token is required");if(typeof e!="string")throw new Vs("subject_token must be a string");if(e.trim().length===0)throw new Vs("subject_token cannot be blank or whitespace");if(e!==e.trim())throw new Vs("subject_token must not include leading or trailing whitespace");if(/^bearer\s+/i.test(e))throw new Vs("subject_token must not include the 'Bearer ' prefix")}function WL(e,t){if(t){for(const[n,r]of Object.entries(t))if(!dZ.has(n))if(Array.isArray(r)){if(r.length>20)throw new Vs("Parameter '".concat(n,"' exceeds maximum array size of ").concat(20));r.forEach((i=>{e.append(n,i)}))}else e.append(n,r)}}var fZ=(Qa=new WeakMap,gd=new WeakMap,rn=new WeakMap,Rh=new WeakMap,Vn=new WeakSet,class{constructor(e){if((function(t,n){uL(t,n),n.add(t)})(this,Vn),ir(this,Qa,void 0),ir(this,gd,void 0),ir(this,rn,void 0),ir(this,Rh,void 0),Oe(this,"mfa",void 0),xn(rn,this,e),e.useMtls&&!e.customFetch)throw new xA("mtls_without_custom_fetch_not_supported","Using mTLS without a custom fetch implementation is not supported");this.mfa=new uZ({domain:Ce(rn,this).domain,clientId:Ce(rn,this).clientId,customFetch:Ce(rn,this).customFetch})}async buildAuthorizationUrl(e){const{serverMetadata:t}=await Wn(Vn,this,qi).call(this);if(e!=null&&e.pushedAuthorizationRequests&&!t.pushed_authorization_request_endpoint)throw new xA("par_not_supported_error","The Auth0 tenant does not have pushed authorization requests enabled. Learn how to enable it here: https://auth0.com/docs/get-started/applications/configure-par");try{return await Wn(Vn,this,zb).call(this,e)}catch(n){throw new iZ(n)}}async buildLinkUserUrl(e){try{const t=await Wn(Vn,this,zb).call(this,{authorizationParams:et(et({},e.authorizationParams),{},{requested_connection:e.connection,requested_connection_scope:e.connectionScope,scope:"openid link_account offline_access",id_token_hint:e.idToken})});return{linkUserUrl:t.authorizationUrl,codeVerifier:t.codeVerifier}}catch(t){throw new sZ(t)}}async buildUnlinkUserUrl(e){try{const t=await Wn(Vn,this,zb).call(this,{authorizationParams:et(et({},e.authorizationParams),{},{requested_connection:e.connection,scope:"openid unlink_account",id_token_hint:e.idToken})});return{unlinkUserUrl:t.authorizationUrl,codeVerifier:t.codeVerifier}}catch(t){throw new oZ(t)}}async backchannelAuthentication(e){const{configuration:t,serverMetadata:n}=await Wn(Vn,this,qi).call(this),r=ix(et(et({},Ce(rn,this).authorizationParams),e?.authorizationParams)),i=new URLSearchParams(et(et({scope:sx},r),{},{client_id:Ce(rn,this).clientId,binding_message:e.bindingMessage,login_hint:JSON.stringify({format:"iss_sub",iss:n.issuer,sub:e.loginHint.sub})}));e.requestedExpiry&&i.append("requested_expiry",e.requestedExpiry.toString()),e.authorizationDetail
10s&&i.append("authorization_details",JSON.stringify(e.authorizationDetails));try{const s=await vA(t,i),o=await DL(t,s);return Cc.fromTokenEndpointResponse(o)}catch(s){throw new Ub(s)}}async initiateBackchannelAuthentication(e){const{configuration:t,serverMetadata:n}=await Wn(Vn,this,qi).call(this),r=ix(et(et({},Ce(rn,this).authorizationParams),e?.authorizationParams)),i=new URLSearchParams(et(et({scope:sx},r),{},{client_id:Ce(rn,this).clientId,binding_message:e.bindingMessage,login_hint:JSON.stringify({format:"iss_sub",iss:n.issuer,sub:e.loginHint.sub})}));e.requestedExpiry&&i.append("requested_expiry",e.requestedExpiry.toString()),e.authorizationDetails&&i.append("authorization_details",JSON.stringify(e.authorizationDetails));try{const s=await vA(t,i);return{authReqId:s.auth_req_id,expiresIn:s.expires_in,interval:s.interval}}catch(s){throw new Ub(s)}}async backchannelAuthenticationGrant(e){let{authReqId:t}=e;const{configuration:n}=await Wn(Vn,this,qi).call(this),r=new URLSearchParams({auth_req_id:t});try{const i=await rk(n,"urn:openid:params:grant-type:ciba",r);return Cc.fromTokenEndpointResponse(i)}catch(i){throw new Ub(i)}}async getTokenForConnection(e){var t;if(e.refreshToken&&e.accessToken)throw new Fb("Either a refresh or access token should be specified, but not both.");const n=(t=e.accessToken)!==null&&t!==void 0?t:e.refreshToken;if(!n)throw new Fb("Either a refresh or access token must be specified.");try{return await this.exchangeToken({connection:e.connection,subjectToken:n,subjectTokenType:e.accessToken?"urn:ietf:params:oauth:token-type:access_token":"urn:ietf:params:oauth:token-type:refresh_token",loginHint:e.loginHint})}catch(r){throw r instanceof Vs?new Fb(r.message,r.cause):r}}async exchangeToken(e){return"connection"in e?Wn(Vn,this,hZ).call(this,e):Wn(Vn,this,pZ).call(this,e)}async getTokenByCode(e,t){const{configuration:n}=await Wn(Vn,this,qi).call(this);try{const r=await LL(n,e,{pkceCodeVerifier:t.codeVerifier});return Cc.fromTokenEndpointResponse(r)}catch(r){throw new tZ("There was an error while trying to request a token.",r)}}async getTokenByRefreshToken(e){const{configuration:t}=await Wn(Vn,this,qi).call(this);try{const n=await NL(t,e.refreshToken);return Cc.fromTokenEndpointResponse(n)}catch(n){throw new rZ("The access token has expired and there was an error while trying to refresh it.",n)}}async getTokenByClientCredentials(e){const{configuration:t}=await Wn(Vn,this,qi).call(this);try{const n=new URLSearchParams({audience:e.audience});e.organization&&n.append("organization",e.organization);const r=await $L(t,n);return Cc.fromTokenEndpointResponse(r)}catch(n){throw new nZ("There was an error while trying to request a token.",n)}}async buildLogoutUrl(e){const{configuration:t,serverMetadata:n}=await Wn(Vn,this,qi).call(this);if(!n.end_session_endpoint){const r=new URL("https://".concat(Ce(rn,this).domain,"/v2/logout"));return r.searchParams.set("returnTo",e.returnTo),r.searchParams.set("client_id",Ce(rn,this).clientId),r}return(function(r,i){ua(r);const{as:s,c:o,tlsOnly:a}=Sr(r),c=vm(s,"end_session_endpoint",!1,a);(i=new URLSearchParams(i)).has("client_id")||i.set("client_id",o.client_id);for(const[d,f]of i.entries())c.searchParams.append(d,f);return c})(t,{post_logout_redirect_uri:e.returnTo})}async verifyLogoutToken(e){const{serverMetadata:t}=await Wn(Vn,this,qi).call(this);Ce(Rh,this)||xn(Rh,this,(function(r,i){const s=new XJ(r,i),o=async(a,c)=>s.getKey(a,c);return Object.defineProperties(o,{coolingDown:{get:()=>s.coolingDown(),enumerable:!0,configurable:!1},fresh:{get:()=>s.fresh(),enumerable:!0,configurable:!1},reload:{value:()=>s.reload(),enumerable:!0,configurable:!1,writable:!1},reloading:{get:()=>s.pendingFetch(),enumerable:!0,configurable:!1},jwks:{value:()=>s.jwks(),enumerable:!0,configurable:!1,writable:!1}}),o})(new URL(t.jwks_uri),{[FL]:Ce(rn,this).customFetch}));const{payload:n}=await YJ(e.logoutToken,Ce(Rh,this),{issuer:t.issuer,audience:Ce(rn,this).clientId,algorithms:["RS256"],requiredClaims:["iat"]});if(!("sid"in n)&&!("sub"in n))throw new za('either "sid" or "sub" (or both) claims must be present');
10if("sid"in n&&typeof n.sid!="string")throw new za('"sid" claim must be a string');if("sub"in n&&typeof n.sub!="string")throw new za('"sub" claim must be a string');if("nonce"in n)throw new za('"nonce" claim is prohibited');if(!("events"in n))throw new za('"events" claim is missing');if(typeof n.events!="object"||n.events===null)throw new za('"events" claim must be an object');if(!("http://schemas.openid.net/event/backchannel-logout"in n.events))throw new za('"http://schemas.openid.net/event/backchannel-logout" member is missing in the "events" claim');if(typeof n.events["http://schemas.openid.net/event/backchannel-logout"]!="object")throw new za('"http://schemas.openid.net/event/backchannel-logout" member in the "events" claim must be an object');return{sid:n.sid,sub:n.sub}}});async function qi(){if(Ce(Qa,this)&&Ce(gd,this))return{configuration:Ce(Qa,this),serverMetadata:Ce(gd,this)};const e=await Wn(Vn,this,mZ).call(this);return xn(Qa,this,await BJ(new URL("https://".concat(Ce(rn,this).domain)),Ce(rn,this).clientId,{use_mtls_endpoint_aliases:Ce(rn,this).useMtls},e,{[ll]:Ce(rn,this).customFetch})),xn(gd,this,Ce(Qa,this).serverMetadata()),Ce(Qa,this)[ll]=Ce(rn,this).customFetch||fetch,{configuration:Ce(Qa,this),serverMetadata:Ce(gd,this)}}async function hZ(e){var t,n;const{configuration:r}=await Wn(Vn,this,qi).call(this);if("audience"in e||"resource"in e)throw new Vs("audience and resource parameters are not supported for Token Vault exchanges");VL(e.subjectToken);const i=new URLSearchParams({connection:e.connection,subject_token:e.subjectToken,subject_token_type:(t=e.subjectTokenType)!==null&&t!==void 0?t:"urn:ietf:params:oauth:token-type:access_token",requested_token_type:(n=e.requestedTokenType)!==null&&n!==void 0?n:"http://auth0.com/oauth/token-type/federated-connection-access-token"});e.loginHint&&i.append("login_hint",e.loginHint),e.scope&&i.append("scope",e.scope),WL(i,e.extra);try{const s=await rk(r,"urn:auth0:params:oauth:grant-type:token-exchange:federated-connection-access-token",i);return Cc.fromTokenEndpointResponse(s)}catch(s){throw new Vs("Failed to exchange token for connection '".concat(e.connection,"'."),s)}}async function pZ(e){const{configuration:t}=await Wn(Vn,this,qi).call(this);VL(e.subjectToken);const n=new URLSearchParams({subject_token_type:e.subjectTokenType,subject_token:e.subjectToken});e.audience&&n.append("audience",e.audience),e.scope&&n.append("scope",e.scope),e.requestedTokenType&&n.append("requested_token_type",e.requestedTokenType),e.organization&&n.append("organization",e.organization),WL(n,e.extra);try{const r=await rk(t,"urn:ietf:params:oauth:grant-type:token-exchange",n);return Cc.fromTokenEndpointResponse(r)}catch(r){throw new Vs("Failed to exchange token of type '".concat(e.subjectTokenType,"'").concat(e.audience?" for audience '".concat(e.audience,"'"):"","."),r)}}async function mZ(){if(!Ce(rn,this).clientSecret&&!Ce(rn,this).clientAssertionSigningKey&&!Ce(rn,this).useMtls)throw new aZ;if(Ce(rn,this).useMtls)return(t,n,r,i)=>{r.set("client_id",n.client_id)};let e=Ce(rn,this).clientAssertionSigningKey;return!e||e instanceof CryptoKey||(e=await(async function(t,n,r){if(typeof t!="string"||t.indexOf("-----BEGIN PRIVATE KEY-----")!==0)throw new TypeError('"pkcs8" must be PKCS#8 formatted string');return $J(t,n,r)})(e,Ce(rn,this).clientAssertionSigningAlg||"RS256")),e?(function(t,n){return uJ(t)})(e):AL(Ce(rn,this).clientSecret)}async function zb(e){const{configuration:t}=await Wn(Vn,this,qi).call(this),n=zJ(),r=await UJ(n),i=ix(et(et({},Ce(rn,this).authorizationParams),e?.authorizationParams)),s=new URLSearchParams(et(et({scope:sx},i),{},{client_id:Ce(rn,this).clientId,code_challenge:r,code_challenge_method:"S256"}));return{authorizationUrl:e!=null&&e.pushedAuthorizationRequests?await jL(t,s):await nx(t,s),codeVerifier:n}}let Cm=class ox extends $n{constructor(t,n){super(t,n),Object.setPrototypeOf(this,ox.prototype)}static fromPayload(t){let{error:n,error_description:r}=t;return new ox(n,r)}},CA=class qL extends Cm{constructor(t,n){super(t,n),Object.setPrototypeOf(this,qL.prototype)}},gZ=class KL extends Cm{constructor(t,n){super(t,n),Object.setPrototypeOf(this,KL.prototype)}},yZ=class GL extends Cm{constructor(t,n){super(t,n),Object.setPrototypeOf(this,GL.prototype)}};class yd extends Cm{constructor(t,n){super(t,n),Object.setPrototypeOf(this,yd.prototype)}}let vZ=class YL extends Cm{constructor(t,n){super(t,n),Object.setPrototypeOf(this,YL.prototype)}},_Z=class{constructor(){let t=arguments.length>0&&arguments[0]!==void 0?arguments[0]:6e5;this.contexts=new Map,this.ttlMs=t}set(t,n){this.cleanup(),this.contexts.set(t,Object.assign(Object.assign({}
10,n),{createdAt:Date.now()}))}get(t){const n=this.contexts.get(t);if(n){if(!(Date.now()-n.createdAt>this.ttlMs))return n;this.contexts.delete(t)}}remove(t){this.contexts.delete(t)}cleanup(){const t=Date.now();for(const[n,r]of this.contexts)t-r.createdAt>this.ttlMs&&this.contexts.delete(n)}get size(){return this.contexts.size}};class wZ{constructor(t,n){this.authJsMfaClient=t,this.auth0Client=n,this.contextManager=new _Z}setMFAAuthDetails(t,n,r,i){this.contextManager.set(t,{scope:n,audience:r,mfaRequirements:i})}async getAuthenticators(t){var n,r;const i=this.contextManager.get(t);if(!(!((n=i?.mfaRequirements)===null||n===void 0)&&n.challenge)||i.mfaRequirements.challenge.length===0)throw new CA("invalid_request","challengeType is required and must contain at least one challenge type, please check mfa_required error payload");const s=i.mfaRequirements.challenge.map((o=>o.type));try{return(await this.authJsMfaClient.listAuthenticators({mfaToken:t})).filter((o=>!!o.type&&s.includes(o.type)))}catch(o){throw o instanceof UL?new CA((r=o.cause)===null||r===void 0?void 0:r.error,o.message):o}}async enroll(t){var n;const r=(function(i){const s=QY[i.factorType];return Object.assign(Object.assign(Object.assign({mfaToken:i.mfaToken,authenticatorTypes:s.authenticatorTypes},s.oobChannels&&{oobChannels:s.oobChannels}),"phoneNumber"in i&&{phoneNumber:i.phoneNumber}),"email"in i&&{email:i.email})})(t);try{return await this.authJsMfaClient.enrollAuthenticator(r)}catch(i){throw i instanceof zL?new gZ((n=i.cause)===null||n===void 0?void 0:n.error,i.message):i}}async challenge(t){var n;try{const r={challengeType:t.challengeType,mfaToken:t.mfaToken};return t.authenticatorId&&(r.authenticatorId=t.authenticatorId),await this.authJsMfaClient.challengeAuthenticator(r)}catch(r){throw r instanceof BL?new yZ((n=r.cause)===null||n===void 0?void 0:n.error,r.message):r}}async getEnrollmentFactors(t){const n=this.contextManager.get(t);if(!n||!n.mfaRequirements)throw new vZ("mfa_context_not_found","MFA context not found for this MFA token. Please retry the original request to get a new MFA token.");return n.mfaRequirements.enroll&&n.mfaRequirements.enroll.length!==0?n.mfaRequirements.enroll:[]}async verify(t){const n=this.contextManager.get(t.mfaToken);if(!n)throw new yd("mfa_context_not_found","MFA context not found for this MFA token. Please retry the original request to get a new MFA token.");const r=(function(o){return"otp"in o&&o.otp?eJ:"oobCode"in o&&o.oobCode?tJ:"recoveryCode"in o&&o.recoveryCode?nJ:void 0})(t);if(!r)throw new yd("invalid_request","Unable to determine grant type. Provide one of: otp, oobCode, or recoveryCode.");const i=n.scope,s=n.audience;try{const o=await this.auth0Client._requestTokenForMfa({grant_type:r,mfaToken:t.mfaToken,scope:i,audience:s,otp:t.otp,oob_code:t.oobCode,binding_code:t.bindingCode,recovery_code:t.re
10coveryCode});return this.contextManager.remove(t.mfaToken),o}catch(o){if(o instanceof e0)this.setMFAAuthDetails(o.mfa_token,i,s,o.mfa_requirements);else if(o instanceof yd)throw new yd(o.error,o.error_description);throw o}}}class bZ{constructor(t){let n,r;if(this.userCache=new iL().enclosedCache,this.defaultOptions={authorizationParams:{scope:"openid profile email"},useRefreshTokensFallback:!1,useFormData:!0},this.options=Object.assign(Object.assign(Object.assign({},this.defaultOptions),t),{authorizationParams:Object.assign(Object.assign({},this.defaultOptions.authorizationParams),t.authorizationParams)}),typeof window<"u"&&(()=>{if(!n0())throw new Error("For security reasons, `window.crypto` is required to run `auth0-spa-js`.");if(n0().subtle===void 0)throw new Error(` 11 auth0-spa-js must run on a secure origin. See https://github.com/auth0/auth0-spa-js/blob/main/FAQ.md#why-do-i-get-auth0-spa-js-must-run-on-a-secure-origin for more information. 12 `)})(),this.lockManager=(wb||(wb=vY()),wb),t.cache&&t.cacheLocation&&console.warn("Both `cache` and `cacheLocation` options have been specified in the Auth0Client configuration; ignoring `cacheLocation` and using `cache`."),t.cache)r=t.cache;else{if(n=t.cacheLocation||"memory",!eA(n))throw new Error('Invalid cache location "'.concat(n,'"'));r=eA(n)()}var i;this.httpTimeoutMs=t.httpTimeoutInSeconds?1e3*t.httpTimeoutInSeconds:1e4,this.cookieStorage=t.legacySameSiteCookie===!1?ad:HY,this.orgHintCookieName=(i=this.options.clientId,"auth0.".concat(i,".organization_hint")),this.isAuthenticatedCookieName=(d=>"auth0.".concat(d,".is.authenticated"))(this.options.clientId),this.sessionCheckExpiryDays=t.sessionCheckExpiryDays||1;const s=t.useCookiesForTransactions?this.cookieStorage:VY;var o;this.scope=(function(d,f){for(var p=arguments.length,m=new Array(p>2?p-2:0),v=2;v<p;v++)m[v-2]=arguments[v];if(typeof d!="object")return{default:gv(f,d,...m)};let w={default:gv(f,...m)};return Object.keys(d).forEach((_=>{const b=d[_];w[_]=gv(f,b,...m)})),w})(this.options.authorizationParams.scope,"openid",this.options.useRefreshTokens?"offline_access":""),this.transactionManager=new $Y(s,this.options.clientId,this.options.cookieDomain),this.nowProvider=this.options.nowProvider||F6,this.cacheManager=new NY(r,r.allKeys?void 0:new KY(r,this.options.clientId),this.nowProvider),this.dpop=this.options.useDpop?new JY(this.options.clientId):void 0,this.domainUrl=(o=this.options.domain,/^https?:\/\//.test(o)?o:"https://".concat(o)),this.tokenIssuer=((d,f)=>d?d.startsWith("https://")?d:"https://".concat(d,"/"):"".concat(f,"/"))(this.options.issuer,this.domainUrl);const a="".concat(this.domainUrl,"/me/"),c=this.createFetcher(Object.assign(Object.assign({},this.options.useDpop&&{dpopNonceId:"__auth0_my_account_api__"}),{getAccessToken:()=>this.getTokenSilently({authorizationParams:{scope:"create:me:connected_accounts",audience:a},detailedResponse:!0})}));this.myAccountApi=new XY(c,a),this.authJsClient=new fZ({domain:this.options.domain,clientId:this.options.clientId}),this.mfa=new wZ(this.authJsClient.mfa,this),typeof window<"u"&&window.Worker&&this.options.useRefreshTokens&&n==="memory"&&(this.options.workerUrl?this.worker=new Worker(this.options.workerUrl):this.worker=new qY)}getConfiguration(){return Object.freeze({domain:this.options.domain,clientId:this.options.clientId})}_url(t){const n=this.options.auth0Client||j6,r=X6(n,!0),i=encodeURIComponent(btoa(JSON.stringify(r)));return"".concat(this.domainUrl).concat(t,"&auth0Client=").concat(i)}_authorizeUrl(t){return this._url("/authorize?".concat(BE(t)))}async _verifyIdToken(t,n,r){const i=await this.nowProvider();return FY({iss:this.tokenIssuer,aud:this.options.clientId,id_token:t,nonce:n,organization:r,leeway:this.options.leeway,max_age:(s=this.options.authorizationParams.max_age,typeof s!="string"?s:parseInt(s,10)||void 0),now:i});var s}_processOrgHint(t){t?this.cookieStorage.save(this.orgHintCookieName,t,{daysUntilExpire:this.sessionCheckExpiryDays,cookieDomain:this.options.cookieDomain}):this.cookieStorage.remove(this.orgHintCookieName,{cookieDomain:this.options.cookieDomain})}async _prepareAuthorizeUrl(t,n,r){var i;const s=yb(xh()),o=yb(xh()),a=xh(),c=await KO(a),d=YO(c),f=await((i=this.dpop)===null||i===void 0?void 0:i.calculateThumbprint()),p=((v,w,_,b,C,P,D,F,R)=>Object.assign(Object.assign(Object.assign({client_id:v.clientId}
12,v.authorizationParams),_),{scope:by(w,_.scope,_.audience),response_type:"code",response_mode:F||"query",state:b,nonce:C,redirect_uri:D||v.authorizationParams.redirect_uri,code_challenge:P,code_challenge_method:"S256",dpop_jkt:R}))(this.options,this.scope,t,s,o,d,t.redirect_uri||this.options.authorizationParams.redirect_uri||r,n?.response_mode,f),m=this._authorizeUrl(p);return{nonce:o,code_verifier:a,scope:p.scope,audience:p.audience||"default",redirect_uri:p.redirect_uri,state:s,url:m}}async loginWithPopup(t,n){var r;if(t=t||{},!(n=n||{}).popup&&(n.popup=(a=>{const c=window.screenX+(window.innerWidth-400)/2,d=window.screenY+(window.innerHeight-600)/2;return window.open(a,"auth0:authorize:popup","left=".concat(c,",top=").concat(d,",width=").concat(400,",height=").concat(600,",resizable,scrollbars=yes,status=1"))})(""),!n.popup))throw new uY;const i=await this._prepareAuthorizeUrl(t.authorizationParams||{},{response_mode:"web_message"},window.location.origin);n.popup.location.href=i.url;const s=await(a=>new Promise(((c,d)=>{let f;const p=setInterval((()=>{a.popup&&a.popup.closed&&(clearInterval(p),clearTimeout(m),window.removeEventListener("message",f,!1),d(new cY(a.popup)))}),1e3),m=setTimeout((()=>{clearInterval(p),d(new lY(a.popup)),window.removeEventListener("message",f,!1)}),1e3*(a.timeoutInSeconds||60));f=function(v){if(v.data&&v.data.type==="authorization_response"){if(clearTimeout(m),clearInterval(p),window.removeEventListener("message",f,!1),a.closePopup!==!1&&a.popup.close(),v.data.response.error)return d($n.fromPayload(v.data.response));c(v.data.response)}},window.addEventListener("message",f)})))(Object.assign(Object.assign({},n),{timeoutInSeconds:n.timeoutInSeconds||this.options.authorizeTimeoutInSeconds||60}));if(i.state!==s.state)throw new $n("state_mismatch","Invalid state");const o=((r=t.authorizationParams)===null||r===void 0?void 0:r.organization)||this.options.authorizationParams.organization;await this._requestToken({audience:i.audience,scope:i.scope,code_verifier:i.code_verifier,grant_type:"authorization_code",code:s.code,redirect_uri:i.redirect_uri},{nonceIn:i.nonce,organization:o})}async getUser(){var t;const n=await this._getIdTokenFromCache();return(t=n?.decodedToken)===null||t===void 0?void 0:t.user}async getIdTokenClaims(){var t;const n=await this._getIdTokenFromCache();return(t=n?.decodedToken)===null||t===void 0?void 0:t.claims}async loginWithRedirect(){var t;const n=tA(arguments.length>0&&arguments[0]!==void 0?arguments[0]:{}),{openUrl:r,fragment:i,appState:s}=n,o=ys(n,["openUrl","fragment","appState"]),a=((t=o.authorizationParams)===null||t===void 0?void 0:t.organization)||this.options.authorizationParams.organization,c=await this._prepareAuthorizeUrl(o.authorizationParams||{}),{url:d}=c,f=ys(c,["url"]);this.transactionManager.create(Object.assign(Object.assign(Object.assign({},f),{appState:s,response_type:rl.Code}),a&&{organization:a}));const p=i?"".concat(d,"#").concat(i):d;r?await r(p):window.location.assign(p)}async handleRedirectCallback(){const t=(arguments.length>0&&arguments[0]!==void 0?arguments[0]:window.location.href).split("?").slice(1);if(t.length===0)throw new Error("There are no query params available for parsing.");const n=this.transactionManager.get();if(!n)throw new $n("missing_transaction","Invalid state");this.transactionManager.remove();const r=(i=>{i.indexOf("#")>-1&&(i=i.substring(0,i.indexOf("#")));const s=new URLSearchParams(i);return{state:s.get("state"),code:s.get("code")||void 0,connect_code:s.get("connect_code")||void 0,error:s.get("error")||void 0,error_description:s.get("error_description")||void 0}})(t.join(""));return n.response_type===rl.ConnectCode?this._handleConnectAccountRedirectCallback(r,n):this._handleLoginRedirectCallback(r,n)}async _handleLoginRedirectCallback(t,n){const{code:r,state:i,error:s,error_description:o}=t;if(s)throw new oY(s,o||s,i,n.appState);if(!n.code_verifier||n.state&&n.state!==i)throw new $n("state_mismatch","Invalid state");const a=n.organization,c=n.nonce,d=n.redirect_uri;return await this._requestToken(Object.assign({audience:n.audience,scope:n.scope,code_verifier:n.code_verifier,grant_type:"authorization_code",code:r},d?{redirect_uri:d}:{}),{nonceIn:c,organization:a}),{appState:n.appState,response_type:rl.Code}}async _handleConnectAccountRedirectCallback(t,n){const{connect_code:r,state:i,error:s,error_description:o}=t;if(s)throw new aY(s,o||s,n.connection,i,n.appState);if(!r)throw new $n("missing_connect_code","Missing connect code");if(!(n.code_verifier&&n.state&&n.auth_session&&n.redirect_uri&&n.state===i))throw new $n("state_mismatch","Invalid state");const a=await this.myAccountApi.completeAccount({auth_session:n.auth_session,connect_code:r,redirect_uri:n.redirect_uri,code_verifier:n.code_verifier});return Object.assign(Object.assign({},a),{appState:n.appState,response_type:rl.ConnectCode})}async checkSession(t){if(!this.cookieStorage.get(this.isAuthenticatedCookieName)){if(!this.cookieStorage.get("auth0.is.authenticated"))return;this.cookieStorage.save(this.isAuthenticatedCookieName,!0,{daysUntilExpire:this.sessionCheckExpiryDays,cookieDomain:this.options.cookieDomain}),this.cookieStorage.remove("auth0.is.authenticated")}try{await this.getTokenSilently(t)}catch{}}async getTokenSilently(){let t=arguments.length>0&&arguments[0]!==void 0?arguments[0]:{};var n,r;const i=Object.assign(Object.assign({cacheMode:"on"},t),{authorizationParams:Object.assign(Object.assign(Object.assign({},this.options.authorizationParams),t.authorizationParams),{scope:by(this.scope,(n=t.authorizationParams)===null||n===void 0?void 0:n.scope,((r=t.authorizationParams)===null||r===void 0?void 0:r.audie
12nce)||this.options.authorizationParams.audience)})}),s=await((o,a)=>{let c=Sb[a];return c||(c=o().finally((()=>{delete Sb[a],c=null})),Sb[a]=c),c})((()=>this._getTokenSilently(i)),"".concat(this.options.clientId,"::").concat(i.authorizationParams.audience,"::").concat(i.authorizationParams.scope));return t.detailedResponse?s:s?.access_token}async _getTokenSilently(t){const{cacheMode:n}=t,r=ys(t,["cacheMode"]);if(n!=="off"){const a=await this._getEntryFromCache({scope:r.authorizationParams.scope,audience:r.authorizationParams.audience||"default",clientId:this.options.clientId,cacheMode:n});if(a)return a}if(n==="cache-only")return;const i=(s=this.options.clientId,o=r.authorizationParams.audience||"default","".concat("auth0.lock.getTokenSilently",".").concat(s,".").concat(o));var s,o;try{return await this.lockManager.runWithLock(i,5e3,(async()=>{if(n!=="off"){const v=await this._getEntryFromCache({scope:r.authorizationParams.scope,audience:r.authorizationParams.audience||"default",clientId:this.options.clientId});if(v)return v}const a=this.options.useRefreshTokens?await this._getTokenUsingRefreshToken(r):await this._getTokenFromIFrame(r),{id_token:c,token_type:d,access_token:f,oauthTokenScope:p,expires_in:m}=a;return Object.assign(Object.assign({id_token:c,token_type:d,access_token:f},p?{scope:p}:null),{expires_in:m})}))}catch(a){if(this._isInteractiveError(a)&&this.options.interactiveErrorHandler==="popup")return await this._handleInteractiveErrorWithPopup(r);throw a}}_isInteractiveError(t){return t instanceof e0}async _handleInteractiveErrorWithPopup(t){try{await this.loginWithPopup({authorizationParams:t.authorizationParams});const n=await this._getEntryFromCache({scope:t.authorizationParams.scope,audience:t.authorizationParams.audience||"default",clientId:this.options.clientId});if(!n)throw new $n("interactive_handler_cache_miss","Token not found in cache after interactive authentication");return n}catch(n){throw n}}async getTokenWithPopup(){let t=arguments.length>0&&arguments[0]!==void 0?arguments[0]:{},n=arguments.length>1&&arguments[1]!==void 0?arguments[1]:{};var r,i;const s=Object.assign(Object.assign({},t),{authorizationParams:Object.assign(Object.assign(Object.assign({},this.options.authorizationParams),t.authorizationParams),{scope:by(this.scope,(r=t.authorizationParams)===null||r===void 0?void 0:r.scope,((i=t.authorizationParams)===null||i===void 0?void 0:i.audience)||this.options.authorizationParams.audience)})});return n=Object.assign(Object.assign({},sY),n),await this.loginWithPopup(s,n),(await this.cacheManager.get(new No({scope:s.authorizationParams.scope,audience:s.authorizationParams.audience||"default",clientId:this.options.clientId}),void 0,this.options.useMrrt)).access_token}async isAuthenticated(){return!!await this.getUser()}_buildLogoutUrl(t){t.clientId!==null?t.clientId=t.clientId||this.options.clientId:delete t.clientId;const n=t.logoutParams||{},{federated:r}=n,i=ys(n,["federated"]),s=r?"&federated":"";return this._url("/v2/logout?".concat(BE(Object.assign({clientId:t.clientId},i))))+s}async logout(){let t=arguments.length>0&&arguments[0]!==void 0?arguments[0]:{};var n;const r=tA(t),{openUrl:i}=r,s=ys(r,["openUrl"]);t.clientId===null?await this.cacheManager.clear():await this.cacheManager.clear(t.clientId||this.options.clientId),this.cookieStorage.remove(this.orgHintCookieName,{cookieDomain:this.options.cookieDomain}),this.cookieStorage.remove(this.isAuthenticatedCookieName,{cookieDomain:this.options.cookieDomain}),this.userCache.remove("@@user@@"),await((n=this.dpop)===null||n===void 0?void 0:n.clear());const o=this._buildLogoutUrl(s);i?await i(o):i!==!1&&window.location.assign(o)}async _getTokenFromIFrame(t){const n=(r=this.options.clientId,"".concat("auth0.lock.getTokenFromIFrame",".").concat(r));var r;try{return await this.lockManager.runWithLock(n,5e3,(async()=>{const i=Object.assign(Object.assign({},t.authorizationParams),{prompt:"none"}),s=this.cookieStorage.get(this.orgHintCookieName);s&&!i.organization&&(i.organization=s);const{url:o,state:a,nonce:c,code_verifier:d,redirect_uri:f,scope:p,audience:m}=await this._prepareAuthorizeUrl(i,{response_mode:"web_message"},window.location.origin);if(window.crossOriginIsolated)throw new $n("login_required","The application is running in a Cross-Origin Isolated context, silently retrieving a token without refresh token is not possible.");const v=t.timeoutInSeconds||this.options.authorizeTimeoutInSeconds;let w;try{w=new URL(this.domainUrl).origin}catch{w=this.domainUrl}const _=await(function(C,P){let D=arguments.length>2&&arguments[2]!==void 0?arguments[2]:60;return new Promise(((F,R)=>{const I=window.document.createElement("iframe");I.setAttribute("width","0"),I.setAttribute("height","0"),I.style.display="none";const k=()=>{window.document.body.contains(I)&&(window.document.body.removeChild(I),window.removeEventListener("message",L,!1))};let L;const B=setTimeout((()=>{R(new I_),k()}),1e3*D);L=function(A){if(A.origin!=P||!A.data||A.data.type!=="authorization_response")return;const V=A.source;V&&V.close(),A.data.response.error?R($n.fromPayload(A.data.response)):F(A.data.response),clearTimeout(B),window.removeEventListener("message",L,!1),setTimeout(k,2e3)},window.addEventListener("message",L,!1),window.document.body.appendChild(I),I.setAttribute("src",C)}))})(o,w,v);if(a!==_.state)throw new $n("state_mismatch","Invalid state");const b=await this._requestToken(Object.assign(Object.assign({},t.authorizationParams),{code_verifier:d,code:_.code,grant_type:"authorization_code",redirect_uri:f,timeout:t.authorizationParams.timeout||this.httpTimeoutMs}),{nonceIn:c,organization:i.organization});return Object.assign(Object.assign({},b),{scope:p,oauthTokenScope:b.scope,audience:m})}))}catch(i){throw i.error==="login_required"&&this.logout({openUrl:!1}),i}}async _getTokenUsingRefreshToken(t){var n,r;const i=await this.cacheManager.get(new No({scope:t.authorizationParams.scope,audience:t.authorizationParams.audience||"default",clientId:this.options.clientId}),void 0,this.options.useMrrt);if(!(i&&i.refresh_token||this.worker)){if(this.options.useRefreshTokensFallback)return await this._getTokenFromIFrame(t);throw new K6(t.authorizationParams.audience||"default",t.authorizationParams.scope)}const s=t.authorizationParams.redirect_uri||this.options.authorizationParams.redirect_uri||window.location.origin,o=typeof t.timeoutInSeconds=="number"?1e3*t.timeoutInSeconds:null,a=((m,v,w,_)=>{var b;if(m&&w&&_){if(v.audience!==w)return v.scope;const C=_.split(" "),P=((b=v.scope)===null||b===void 0?void 0:b.split(" "))||[],D=P.every((F=>C.includes(F)));return C.length>=P.length&&D?_:v.scope}return v.scope})(this.options.useMrrt,t.authorizationParams,i?.audience,i?.scope);try{const m=await this._requestToken(Object.assign(Object.assign(Object.assign({},t.authorizationParams),{grant_type:"refresh_token",refresh_token:i&&i.refresh_token,redirect_uri:s}),o&&{timeout:o}),{scopesToRequest:a});if(m.refresh_token&&i?.refresh_token&&await this.cacheManager.updateEntry(i.refresh_token,m.refresh_token),this.options.useMrrt&&(c=i?.audience,d=i?.scope,f=t.authorizationParams.audience,p=t.authorizationParams.scope,(c!==f||!nA(p,d))&&!nA(a,m.scope))){if(this.options.useRefreshTokensFallback)return await this._getTokenFromIFrame(t);await this.cacheManager.remove(this.options.clientId,t.authorizationParams.audience,t.authorizationParams.scope);const v=((w,_)=>{const b=w?.split(" ")||[],C=_?.split(" ")||[];
12return b.filter((P=>C.indexOf(P)==-1)).join(",")})(a,m.scope);throw new dY(t.authorizationParams.audience||"default",v)}return Object.assign(Object.assign({},m),{scope:t.authorizationParams.scope,oauthTokenScope:m.scope,audience:t.authorizationParams.audience||"default"})}catch(m){if(m.message){if(m.message.includes("user is blocked"))throw await this.logout({openUrl:!1}),m;if((m.message.includes("Missing Refresh Token")||m.message.includes("invalid refresh token"))&&this.options.useRefreshTokensFallback)return await this._getTokenFromIFrame(t)}throw m instanceof e0&&this.mfa.setMFAAuthDetails(m.mfa_token,(n=t.authorizationParams)===null||n===void 0?void 0:n.scope,(r=t.authorizationParams)===null||r===void 0?void 0:r.audience,m.mfa_requirements),m}var c,d,f,p}async _saveEntryInCache(t){const{id_token:n,decodedToken:r}=t,i=ys(t,["id_token","decodedToken"]);this.userCache.set("@@user@@",{id_token:n,decodedToken:r}),await this.cacheManager.setIdToken(this.options.clientId,t.id_token,t.decodedToken),await this.cacheManager.set(i)}async _getIdTokenFromCache(){const t=this.options.authorizationParams.audience||"default",n=this.scope[t],r=await this.cacheManager.getIdToken(new No({clientId:this.options.clientId,audience:t,scope:n})),i=this.userCache.get("@@user@@");return r&&r.id_token===i?.id_token?i:(this.userCache.set("@@user@@",r),r)}async _getEntryFromCache(t){let{scope:n,audience:r,clientId:i,cacheMode:s}=t;const o=await this.cacheManager.get(new No({scope:n,audience:r,clientId:i}),60,this.options.useMrrt,s);if(o&&o.access_token){const{token_type:a,access_token:c,oauthTokenScope:d,expires_in:f}=o,p=await this._getIdTokenFromCache();return p&&Object.assign(Object.assign({id_token:p.id_token,token_type:a||"Bearer",access_token:c},d?{scope:d}:null),{expires_in:f})}}async _requestToken(t,n){var r,i;const{nonceIn:s,organization:o,scopesToRequest:a}=n||{},c=await MY(Object.assign(Object.assign({baseUrl:this.domainUrl,client_id:this.options.clientId,auth0Client:this.options.auth0Client,useFormData:this.options.useFormData,timeout:this.httpTimeoutMs,useMrrt:this.options.useMrrt,dpop:this.dpop},t),{scope:a||t.scope}),this.worker),d=await this._verifyIdToken(c.id_token,s,o);if(t.grant_type==="authorization_code"){const f=await this._getIdTokenFromCache();!((i=(r=f?.decodedToken)===null||r===void 0?void 0:r.claims)===null||i===void 0)&&i.sub&&f.decodedToken.claims.sub!==d.claims.sub&&(await this.cacheManager.clear(this.options.clientId),this.userCache.remove("@@user@@"))}return await this._saveEntryInCache(Object.assign(Object.assign(Object.assign(Object.assign({},c),{decodedToken:d,scope:t.scope,audience:t.audience||"default"}),c.scope?{oauthTokenScope:c.scope}:null),{client_id:this.options.clientId})),this.cookieStorage.save(this.isAuthenticatedCookieName,!0,{daysUntilExpire:this.sessionCheckExpiryDays,cookieDomain:this.options.cookieDomain}),this._processOrgHint(o||d.claims.org_id),Object.assign(Object.assign({},c),{decodedToken:d})}async loginWithCustomTokenExchange(t){return this._requestToken(Object.assign(Object.assign({},t),{grant_type:"urn:ietf:params:oauth:grant-type:token-exchange",subject_token:t.subject_token,subject_token_type:t.subject_token_type,scope:by(this.scope,t.scope,t.audience||this.options.authorizationParams.audience),audience:t.audience||this.options.authorizationParams.audience,organization:t.organization||this.options.authorizationParams.organization}))}async exchangeToken(t){return this.loginWithCustomTokenExchange(t)}
12_assertDpop(t){if(!t)throw new Error("`useDpop` option must be enabled before using DPoP.")}getDpopNonce(t){return this._assertDpop(this.dpop),this.dpop.getNonce(t)}setDpopNonce(t,n){return this._assertDpop(this.dpop),this.dpop.setNonce(t,n)}generateDpopProof(t){return this._assertDpop(this.dpop),this.dpop.generateProof(t)}createFetcher(){let t=arguments.length>0&&arguments[0]!==void 0?arguments[0]:{};return new ZY(t,{isDpopEnabled:()=>!!this.options.useDpop,getAccessToken:n=>{var r;return this.getTokenSilently({authorizationParams:{scope:(r=n?.scope)===null||r===void 0?void 0:r.join(" "),audience:n?.audience},detailedResponse:!0})},getDpopNonce:()=>this.getDpopNonce(t.dpopNonceId),setDpopNonce:n=>this.setDpopNonce(n,t.dpopNonceId),generateDpopProof:n=>this.generateDpopProof(n)})}async connectAccountWithRedirect(t){const{openUrl:n,appState:r,connection:i,scopes:s,authorization_params:o,redirectUri:a=this.options.authorizationParams.redirect_uri||window.location.origin}=t;if(!i)throw new Error("connection is required");const c=yb(xh()),d=xh(),f=await KO(d),p=YO(f),{connect_uri:m,connect_params:v,auth_session:w}=await this.myAccountApi.connectAccount({connection:i,scopes:s,redirect_uri:a,state:c,code_challenge:p,code_challenge_method:"S256",authorization_params:o});this.transactionManager.create({state:c,code_verifier:d,auth_session:w,redirect_uri:a,appState:r,connection:i,response_type:rl.ConnectCode});const _=new URL(m);_.searchParams.set("ticket",v.ticket),n?await n(_.toString()):window.location.assign(_)}async _requestTokenForMfa(t,n){const{mfaToken:r}=t,i=ys(t,["mfaToken"]);return this._requestToken(Object.assign(Object.assign({},i),{mfa_token:r}),n)}}var JL={isAuthenticated:!1,isLoading:!0,error:void 0,user:void 0},Pn=function(){throw new Error("You forgot to wrap your component in <Auth0Provider>.")},SZ=gr(gr({},JL),{buildAuthorizeUrl:Pn,buildLogoutUrl:Pn,getAccessTokenSilently:Pn,getAccessTokenWithPopup:Pn,getIdTokenClaims:Pn,loginWithCustomTokenExchange:Pn,exchangeToken:Pn,loginWithRedirect:Pn,loginWithPopup:Pn,connectAccountWithRedirect:Pn,logout:Pn,handleRedirectCallback:Pn,getDpopNonce:Pn,setDpopNonce:Pn,generateDpopProof:Pn,createFetcher:Pn,getConfiguration:Pn,mfa:{getAuthenticators:Pn,enroll:Pn,challenge:Pn,verify:Pn,getEnrollmentFactors:Pn}}),ZL=g.createContext(SZ),kA=(function(e){rY(t,e);function t(n,r){var i=e.call(this,r??n)||this;return i.error=n,i.error_description=r,Object.setPrototypeOf(i,t.prototype),i}return t})(Error),EZ=/[?&](?:connect_)?code=[^&]+/,xZ=/[?&]state=[^&]+/,CZ=/[?&]error=[^&]+/,kZ=function(e){return e===void 0&&(e=window.location.search),(EZ.test(e)||CZ.test(e))&&xZ.test(e)},XL=function(e){return function(t){if(t instanceof Error)return t;if(t!==null&&typeof t=="object"&&"error"in t&&typeof t.error=="string"){if("error_description"in t&&typeof t.error_description=="string"){var n=t;return new kA(n.error,n.error_description)}var r=t;return new kA(r.error)}return new Error(e)}},TA=XL("Login failed"),Py=XL("Get access token failed"),QL=function(e){var t,n;e?.redirectUri&&(console.warn("Using `redirectUri` has been deprecated, please use `authorizationParams.redirect_uri` instead as `redirectUri` will be no longer supported in a future version"),e.authorizationParams=(t=e.authorizationParams)!==null&&t!==void 0?t:{},e.authorizationParams.redirect_uri=e.redirectUri,delete e.redirectUri),!((n=e?.authorizationParams)===null||n===void 0)&&n.redirectUri&&(console.warn("Using `authorizationParams.redirectUri` has been deprecated, please use `authorizationParams.redirect_uri` instead as `authorizationParams.redirectUri` will be removed in a future version"),e.authorizationParams.redirect_uri=e.authorizationParams.redirectUri,delete e.authorizationParams.redirectUri)},TZ=function(e,t){switch(t.type){case"LOGIN_POPUP_STARTED":return gr(gr({},e),{isLoading:!0});case"LOGIN_POPUP_COMPLETE":case"INITIALISED":return gr(gr({},e),{isAuthenticated:!!t.user,user:t.user,isLoading:!1,error:void 0});case"HANDLE_REDIRECT_COMPLETE":case"GET_ACCESS_TOKEN_COMPLETE":return e.user===t.user?e:gr(gr({},e),{isAuthenticated:!!t.user,user:t.user});case"LOGOUT":return gr(gr({},e),{isAuthenticated:!1,user:void 0});case"ERROR":return gr(gr({},e),{isLoading:!1,error:t.error})}},RZ=function(e){return QL(e),gr(gr({},e),{auth0Client:{name:"auth0-react",version:"2.15.0"}})},PZ=function(e){var t;window.history.replaceState({},document.title,(t=e.returnTo)!==null&&t!==void 0?t:window.location.pathname)},OZ=function(e){var t=e.children,n=e.skipRedirectCallback,r=e.onRedirectCallback,i=r===void 0?PZ:r,s=e.context,o=s===void 0?ZL:s,a=qO(e,["children","skipRedirectCallback","onRedirectCallback","context"]),c=g.useState(function(){return new bZ(RZ(a)
12)})[0],d=g.useReducer(TZ,JL),f=d[0],p=d[1],m=g.useRef(!1),v=g.useCallback(function(q){return p({type:"ERROR",error:q}),q},[]);g.useEffect(function(){m.current||(m.current=!0,(function(){return ja(void 0,void 0,void 0,function(){var q,z,x,N,M,E,O;return Fa(this,function(H){switch(H.label){case 0:return H.trys.push([0,7,,8]),q=void 0,kZ()&&!n?[4,c.handleRedirectCallback()]:[3,3];case 1:return z=H.sent(),x=z.appState,N=x===void 0?{}:x,M=z.response_type,E=qO(z,["appState","response_type"]),[4,c.getUser()];case 2:return q=H.sent(),N.response_type=M,M===rl.ConnectCode&&(N.connectedAccount=E),i(N,q),[3,6];case 3:return[4,c.checkSession()];case 4:return H.sent(),[4,c.getUser()];case 5:q=H.sent(),H.label=6;case 6:return p({type:"INITIALISED",user:q}),[3,8];case 7:return O=H.sent(),v(TA(O)),[3,8];case 8:return[2]}})})})())},[c,i,n,v]);var w=g.useCallback(function(q){return QL(q),c.loginWithRedirect(q)},[c]),_=g.useCallback(function(q,z){return ja(void 0,void 0,void 0,function(){var x,N;return Fa(this,function(M){switch(M.label){case 0:p({type:"LOGIN_POPUP_STARTED"}),M.label=1;case 1:return M.trys.push([1,3,,4]),[4,c.loginWithPopup(q,z)];case 2:return M.sent(),[3,4];case 3:return x=M.sent(),v(TA(x)),[2];case 4:return[4,c.getUser()];case 5:return N=M.sent(),p({type:"LOGIN_POPUP_COMPLETE",user:N}),[2]}})})},[c,v]),b=g.useCallback(function(){for(var q=[],z=0;z<arguments.length;z++)q[z]=arguments[z];return ja(void 0,iY([],q),void 0,function(x){return x===void 0&&(x={}),Fa(this,function(N){switch(N.label){case 0:return[4,c.logout(x)];case 1:return N.sent(),(x.openUrl||x.openUrl===!1)&&p({type:"LOGOUT"}),[2]}})})},[c]),C=g.useCallback(function(q){return ja(void 0,void 0,void 0,function(){var z,x,N,M;return Fa(this,function(E){switch(E.label){case 0:return E.trys.push([0,2,3,5]),[4,c.getTokenSilently(q)];case 1:return z=E.sent(),[3,5];case 2:throw x=E.sent(),Py(x);case 3:return N=p,M={type:"GET_ACCESS_TOKEN_COMPLETE"},[4,c.getUser()];case 4:return N.apply(void 0,[(M.user=E.sent(),M)]),[7];case 5:return[2,z]}})})},[c]),P=g.useCallback(function(q,z){return ja(void 0,void 0,void 0,function(){var x,N,M,E;return Fa(this,function(O){switch(O.label){case 0:return O.trys.push([0,2,3,5]),[4,c.getTokenWithPopup(q,z)];case 1:return x=O.sent(),[3,5];case 2:throw N=O.sent(),Py(N);case 3:return M=p,E={type:"GET_ACCESS_TOKEN_COMPLETE"},[4,c.getUser()];case 4:return M.apply(void 0,[(E.user=O.sent(),E)]),[7];case 5:return[2,x]}})})},[c]),D=g.useCallback(function(q){return c.connectAccountWithRedirect(q)},[c]),F=g.useCallback(function(){return c.getIdTokenClaims()},[c]),R=g.useCallback(function(q){return ja(void 0,void 0,void 0,function(){var z,x,N,M;return Fa(this,function(E){switch(E.label){case 0:return E.trys.push([0,2,3,5]),[4,c.loginWithCustomTokenExchange(q)];case 1:return z=E.sent(),[3,5];case 2:throw x=E.sent(),Py(x);case 3:return N=p,M={type:"GET_ACCESS_TOKEN_COMPLETE"},[4,c.getUser()];case 4:return N.apply(void 0,[(M.user=E.sent(),M)]),[7];case 5:return[2,z]}})})},[c]),I=g.useCallback(function(q){return ja(void 0,void 0,void 0,function(){return Fa(this,function(z){return[2,R(q)]})})},[R]),k=g.useCallback(function(q){return ja(void 0,void 0,void 0,function(){var z,x,N;return Fa(this,function(M){switch(M.label){case 0:return M.trys.push([0,2,3,5]),[4,c.handleRedirectCallback(q)];case 1:return[2,M.sent()];case 2:throw z=M.sent(),Py(z);case 3:return x=p,N={type:"HANDLE_REDIRECT_COMPLETE"},[4,c.getUser()];case 4:return x.apply(void 0,[(N.user=M.sent(),N)]),[7];case 5:return[2]}})})},[c]),L=g.useCallback(function(q){return c.getDpopNonce(q)},[c]),B=g.useCallback(function(q,z){return c.setDpopNonce(q,z)},[c]),A=g.useCallback(function(q){return c.generateDpopProof(q)},[c]),V=g.useCallback(function(q){return c.createFetcher(q)},[c]),K=g.useCallback(function(){return c.getConfiguration()},[c]),W=g.useMemo(function(){return c.mfa},[c]),U=g.useMemo(function(){return gr(gr({},f),{getAccessTokenSilently:C,getAccessTokenWithPopup:P,getIdTokenClaims:F,loginWithCustomTokenExchange:R,exchangeToken:I,loginWithRedirect:w,loginWithPopup:_,connectAccountWithRedirect:D,logout:b,handleRedirectCallback:k,getDpopNonce:L,setDpopNonce:B,generateDpopProof:A,createFetcher:V,getConfiguration:K,mfa:W})},[f,C,P,F,R,I,w,_,D,b,k,L,B,A,V,K,W]);return bt.createElement(o.Provider,{value:U},t)},km=function(e){return e===void 0&&(e=ZL),g.useContext(e)},hu=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(){}},AZ={setTimeout:(e,t)=>setTimeout(e,t),clearTimeout:e=>clearTimeout(e),setInterval:(e,t)=>setInterval(e,t),clearInterval:e=>clearInterval(e)},IZ=class{#t=AZ;#e=!1;setTimeoutProvider(e){this.#t=e}setTimeout(e,t){return this.#t.setTimeout(e,t)}clearTimeout(e){this.#t.clearTimeout(e)}setInterval(e,t){return this.#t.setInterval(e,t)}clearInterval(e){this.#t.clearInterval(e)}},jo=new IZ;function MZ(e){setTimeout(e,0)}var Kc=typeof window>"u"||"Deno"in globalThis;function Yn(){}function DZ(e,t){return typeof e=="function"?e(t):e}function ax(e){return typeof e=="number"&&e>=0&&e!==1/0}function e7(e,t){return Math.max(e+(t||0)-Date.now(),0)}function hl(e,t){return typeof e=="function"?e(t):e}function Yi(e,t){return typeof e=="function"?e(t):e}function RA(e,t){const{type:n="all",exact:r,fetchStatus:i,predicate:s,queryKey:o,stale:a}=e;if(o){if(r){if(t.queryHash!==ik(o,t.options))return!1}else if(!Dp(t.queryKey,o))return!1}if(n!=="all"){const c=t.isActive();if(n==="active"&&!c||n==="inactive"&&c)return!1}return!(typeof a=="boolean"&&t.isStale()!==a||i&&i!==t.state.fetchStatus||s&&!s(t))}function PA(e,t){const{exact:n,status:r,predicate:i,mutationKey:s}=e;if(s){if(!t.options.mutationKey)return!1;if(n){if(Gc(t.options.mutationKey)!==Gc(s))return!1}else if(!Dp(t.options.mutationKey,s))return!1}return!(r&&t.state.status!==r||i&&!i(t))}function ik(e,t){return(t?.queryKeyHashFn||Gc)(e)}function Gc(e){return JSON.stringify(e,(t,n)=>lx(n)?Object.keys(n).sort().reduce((r,i)=>(r[i]=n[i],r),{}):n)}function Dp(e,t){return e===t?!0:typeof e!=typeof t?!1:e&&t&&typeof e=="object"&&typeof t=="object"?Object.keys(t).every(n=>Dp(e[n],t[n])):!1}var LZ=Object.prototype.hasOwnProperty;function sk(e,t){if(e===t)return e;const n=OA(e)&&OA(t);if(!n&&!(lx(e)&&lx(t)))return t;const i=(n?e:Object.keys(e)).length,s=n?t:Object.keys(t),o=s.length,a=n?
12new Array(o):{};let c=0;for(let d=0;d<o;d++){const f=n?d:s[d],p=e[f],m=t[f];if(p===m){a[f]=p,(n?d<i:LZ.call(e,f))&&c++;continue}if(p===null||m===null||typeof p!="object"||typeof m!="object"){a[f]=m;continue}const v=sk(p,m);a[f]=v,v===p&&c++}return i===o&&c===i?e:a}function Lp(e,t){if(!t||Object.keys(e).length!==Object.keys(t).length)return!1;for(const n in e)if(e[n]!==t[n])return!1;return!0}function OA(e){return Array.isArray(e)&&e.length===Object.keys(e).length}function lx(e){if(!AA(e))return!1;const t=e.constructor;if(t===void 0)return!0;const n=t.prototype;return!(!AA(n)||!n.hasOwnProperty("isPrototypeOf")||Object.getPrototypeOf(e)!==Object.prototype)}function AA(e){return Object.prototype.toString.call(e)==="[object Object]"}function NZ(e){return new Promise(t=>{jo.setTimeout(t,e)})}function cx(e,t,n){return typeof n.structuralSharing=="function"?n.structuralSharing(e,t):n.structuralSharing!==!1?sk(e,t):t}function $Z(e,t,n=0){const r=[...e,t];return n&&r.length>n?r.slice(1):r}function jZ(e,t,n=0){const r=[t,...e];return n&&r.length>n?r.slice(0,-1):r}var ok=Symbol();function t7(e,t){return!e.queryFn&&t?.initialPromise?()=>t.initialPromise:!e.queryFn||e.queryFn===ok?()=>Promise.reject(new Error(`Missing queryFn: '${e.queryHash}'`)):e.queryFn}function n7(e,t){return typeof e=="function"?e(...t):!!e}var FZ=class extends hu{#t;#e;#n;constructor(){super(),this.#n=e=>{if(!Kc&&window.addEventListener){const t=()=>e();return window.addEventListener("visibilitychange",t,!1),()=>{window.removeEventListener("visibilitychange",t)}}}}onSubscribe(){this.#e||this.setEventListener(this.#n)}onUnsubscribe(){this.hasListeners()||(this.#e?.(),this.#e=void 0)}setEventListener(e){this.#n=e,this.#e?.(),this.#e=e(t=>{typeof t=="boolean"?this.setFocused(t):this.onFocus()})}setFocused(e){this.#t!==e&&(this.#t=e,this.onFocus())}onFocus(){const e=this.isFocused();this.listeners.forEach(t=>{t(e)})}isFocused(){return typeof this.#t=="boolean"?this.#t:globalThis.document?.visibilityState!=="hidden"}},ak=new FZ;function ux(){let e,t;const n=new Promise((i,s)=>{e=i,t=s});n.status="pending",n.catch(()=>{});function r(i){Object.assign(n,i),delete n.resolve,delete n.reject}return n.resolve=i=>{r({status:"fulfilled",value:i}),e(i)},n.reject=i=>{r({status:"rejected",reason:i}),t(i)},n}function UZ(e){let t;if(e.then(n=>(t=n,n),Yn)?.catch(Yn),t!==void 0)return{data:t}}function r7(e){return e}function zZ(e){return{mutationKey:e.options.mutationKey,state:e.state,...e.options.scope&&{scope:e.options.scope},...e.meta&&{meta:e.meta}}}function BZ(e,t,n){const r=()=>{const i=e.promise?.then(t).catch(s=>n(s)?Promise.reject(new Error("redacted")):Promise.reject(s));return i?.catch(Yn),i};return{dehydratedAt:Date.now(),state:{...e.state,...e.state.data!==void 0&&{data:t(e.state.data)}},queryKey:e.queryKey,queryHash:e.queryHash,...e.state.status==="pending"&&{promise:r()},...e.meta&&{meta:e.meta}}}
12function HZ(e){return e.state.isPaused}function VZ(e){return e.state.status==="success"}function WZ(e){return!0}function qZ(e,t={}){const n=t.shouldDehydrateMutation??e.getDefaultOptions().dehydrate?.shouldDehydrateMutation??HZ,r=e.getMutationCache().getAll().flatMap(c=>n(c)?[zZ(c)]:[]),i=t.shouldDehydrateQuery??e.getDefaultOptions().dehydrate?.shouldDehydrateQuery??VZ,s=t.shouldRedactErrors??e.getDefaultOptions().dehydrate?.shouldRedactErrors??WZ,o=t.serializeData??e.getDefaultOptions().dehydrate?.serializeData??r7,a=e.getQueryCache().getAll().flatMap(c=>i(c)?[BZ(c,o,s)]:[]);return{mutations:r,queries:a}}function KZ(e,t,n){if(typeof t!="object"||t===null)return;const r=e.getMutationCache(),i=e.getQueryCache(),s=n?.defaultOptions?.deserializeData??e.getDefaultOptions().hydrate?.deserializeData??r7,o=t.mutations||[],a=t.queries||[];o.forEach(({state:c,...d})=>{r.build(e,{...e.getDefaultOptions().hydrate?.mutations,...n?.defaultOptions?.mutations,...d},c)}),a.forEach(({queryKey:c,state:d,queryHash:f,meta:p,promise:m,dehydratedAt:v})=>{const w=m?UZ(m):void 0,_=d.data===void 0?w?.data:d.data,b=_===void 0?_:s(_);let C=i.get(f);const P=C?.state.status==="pending",D=C?.state.fetchStatus==="fetching";if(C){const F=w&&v!==void 0&&v>C.state.dataUpdatedAt;if(d.dataUpdatedAt>C.state.dataUpdatedAt||F){const{fetchStatus:R,...I}=d;C.setState({...I,data:b})}}else C=i.build(e,{...e.getDefaultOptions().hydrate?.queries,...n?.defaultOptions?.queries,queryKey:c,queryHash:f,meta:p},{...d,data:b,fetchStatus:"idle",status:b!==void 0?"success":d.status});m&&!P&&!D&&(v===void 0||v>C.state.dataUpdatedAt)&&C.fetch(void 0,{initialPromise:Promise.resolve(m).then(s)}).catch(Yn)})}var GZ=MZ;function YZ(){let e=[],t=0,n=a=>{a()},r=a=>{a()},i=GZ;const s=a=>{t?e.push(a):i(()=>{n(a)})},o=()=>{const a=e;e=[],a.length&&i(()=>{r(()=>{a.forEach(c=>{n(c)})})})};return{batch:a=>{let c;t++;try{c=a()}finally{t--,t||o()}return c},batchCalls:a=>(...c)=>{s(()=>{a(...c)})},schedule:s,setNotifyFunction:a=>{n=a},setBatchNotifyFunction:a=>{r=a},setScheduler:a=>{i=a}}}var In=YZ(),JZ=class extends hu{#t=!0;#e;#n;constructor(){super(),this.#n=e=>{if(!Kc&&window.addEventListener){const t=()=>e(!0),n=()=>e(!1);return window.addEventListener("online",t,!1),window.addEventListener("offline",n,!1),()=>{window.removeEventListener("online",t),window.removeEventListener("offline",n)}}}}onSubscribe(){this.#e||this.setEventListener(this.#n)}onUnsubscribe(){this.hasListeners()||(this.#e?.(),this.#e=void 0)}setEventListener(e){this.#n=e,this.#e?.(),this.#e=e(this.setOnline.bind(this))}setOnline(e){this.#t!==e&&(this.#t=e,this.listeners.forEach(n=>{n(e)}))}isOnline(){return this.#t}},c0=new JZ;function ZZ(e){return Math.min(1e3*2**e,3e4)}function i7(e){return(e??"online")==="online"?c0.isOnline():!0}var dx=class extends Error{constructor(e){super("CancelledError"),this.revert=e?.revert,this.silent=e?.silent}};function s7(e){let t=!1,n=0,r;const i=ux(),s=()=>i.status!=="pending",o=_=>{if(!s()){const b=new dx(_);m(b),e.onCancel?.(b)}},a=()=>{t=!0},c=()=>{t=!1},d=()=>ak.isFocused()&&(e.networkMode==="always"||c0.isOnline())&&e.canRun(),f=()=>i7(e.networkMode)&&e.canRun(),p=_=>{s()||(r?.(),i.resolve(_))},m=_=>{s()||(r?.(),i.reject(_))},v=()=>new Promise(_=>{r=b=>{(s()||d())&&_(b)},e.onPause?.()}).then(()=>{r=void 0,s()||e.onContinue?.()}),w=()=>
vendor: 12,333 bytes, line 12
12{if(s())return;let _;const b=n===0?e.initialPromise:void 0;try{_=b??e.fn()}catch(C){_=Promise.reject(C)}Promise.resolve(_).then(p).catch(C=>{if(s())return;const P=e.retry??(Kc?0:3),D=e.retryDelay??ZZ,F=typeof D=="function"?D(n,C):D,R=P===!0||typeof P=="number"&&n<P||typeof P=="function"&&P(n,C);if(t||!R){m(C);return}n++,e.onFail?.(n,C),NZ(F).then(()=>d()?void 0:v()).then(()=>{t?m(C):w()})})};return{promise:i,status:()=>i.status,cancel:o,continue:()=>(r?.(),i),cancelRetry:a,continueRetry:c,canStart:f,start:()=>(f()?w():v().then(w),i)}}var o7=class{#t;destroy(){this.clearGcTimeout()}scheduleGc(){this.clearGcTimeout(),ax(this.gcTime)&&(this.#t=jo.setTimeout(()=>{this.optionalRemove()},this.gcTime))}updateGcTime(e){this.gcTime=Math.max(this.gcTime||0,e??(Kc?1/0:300*1e3))}clearGcTimeout(){this.#t&&(jo.clearTimeout(this.#t),this.#t=void 0)}},XZ=class extends o7{#t;#e;#n;#i;#r;#s;#a;constructor(e){super(),this.#a=!1,this.#s=e.defaultOptions,this.setOptions(e.options),this.observers=[],this.#i=e.client,this.#n=this.#i.getQueryCache(),this.queryKey=e.queryKey,this.queryHash=e.queryHash,this.#t=MA(this.options),this.state=e.state??this.#t,this.scheduleGc()}get meta(){return this.options.meta}get promise(){return this.#r?.promise}setOptions(e){if(this.options={...this.#s,...e},this.updateGcTime(this.options.gcTime),this.state&&this.state.data===void 0){const t=MA(this.options);t.data!==void 0&&(this.setState(IA(t.data,t.dataUpdatedAt)),this.#t=t)}}optionalRemove(){!this.observers.length&&this.state.fetchStatus==="idle"&&this.#n.remove(this)}setData(e,t){const n=cx(this.state.data,e,this.options);return this.#o({data:n,type:"success",dataUpdatedAt:t?.updatedAt,manual:t?.manual}),n}setState(e,t){this.#o({type:"setState",state:e,setStateOptions:t})}cancel(e){const t=this.#r?.promise;return this.#r?.cancel(e),t?t.then(Yn).catch(Yn):Promise.resolve()}destroy(){super.destroy(),this.cancel({silent:!0})}reset(){this.destroy(),this.setState(this.#t)}isActive(){return this.observers.some(e=>Yi(e.options.enabled,this)!==!1)}isDisabled(){return this.getObserversCount()>0?!this.isActive():this.options.queryFn===ok||this.state.dataUpdateCount+this.state.errorUpdateCount===0}isStatic(){return this.getObserversCount()>0?this.observers.some(e=>hl(e.options.staleTime,this)==="static"):!1}isStale(){return this.getObserversCount()>0?this.observers.some(e=>e.getCurrentResult().isStale):this.state.data===void 0||this.state.isInvalidated}isStaleByTime(e=0){return this.state.data===void 0?!0:e==="static"?!1:this.state.isInvalidated?!0:!e7(this.state.dataUpdatedAt,e)}onFocus(){this.observers.find(t=>t.shouldFetchOnWindowFocus())?.refetch({cancelRefetch:!1}),this.#r?.continue()}onOnline(){this.observers.find(t=>t.shouldFetchOnReconnect())?.refetch({cancelRefetch:!1}),this.#r?.continue()}addObserver(e){this.observers.includes(e)||(this.observers.push(e),this.clearGcTimeout(),this.#n.notify({type:"observerAdded",query:this,observer:e}))}removeObserver(e){this.observers.includes(e)&&(this.observers=this.observers.filter(t=>t!==e),this.observers.length||(this.#r&&(this.#a?this.#r.cancel({revert:!0}):this.#r.cancelRetry()),this.scheduleGc()),this.#n.notify({type:"observerRemoved",query:this,observer:e}))}getObserversCount(){return this.observers.length}invalidate(){this.state.isInvalidated||this.#o({type:"invalidate"})}async fetch(e,t){if(this.state.fetchStatus!=="idle"&&this.#r?.status()!=="rejected"){if(this.state.data!==void 0&&t?.cancelRefetch)this.cancel({silent:!0});else if(this.#r)return this.#r.continueRetry(),this.#r.promise}if(e&&this.setOptions(e),!this.options.queryFn){const a=this.observers.find(c=>c.options.queryFn);a&&this.setOptions(a.options)}const n=new AbortController,r=a=>{Object.defineProperty(a,"signal",{enumerable:!0,get:()=>(this.#a=!0,n.signal)})},i=()=>{const a=t7(this.options,t),d=(()=>{const f={client:this.#i,queryKey:this.queryKey,meta:this.meta};return r(f),f})();return this.#a=!1,this.options.persister?this.options.persister(a,d,this):a(d)},o=(()=>{const a={fetchOptions:t,options:this.options,queryKey:this.queryKey,client:this.#i,state:this.state,fetchFn:i};return r(a),a})();this.options.behavior?.onFetch(o,this),this.#e=this.state,(this.state.fetchStatus==="idle"||this.state.fetchMeta!==o.fetchOptions?.meta)&&this.#o({type:"fetch",meta:o.fetchOptions?.meta}),this.#r=s7({initialPromise:t?.initialPromise,fn:o.fetchFn,onCancel:a=>{a instanceof dx&&a.revert&&this.setState({...this.#e,fetchStatus:"idle"}),n.abort()},onFail:(a,c)=>{this.#o({type:"failed",failureCount:a,error:c})},onPause:()=>{this.#o({type:"pause"})},onContinue:()=>{this.#o({type:"continue"})},retry:o.options.retry,retryDelay:o.options.retryDelay,networkMode:o.options.networkMode,canRun:()=>!0});try{const a=await this.#r.start();if(a===void 0)throw new Error(`${this.queryHash} data is undefined`);return this.setData(a),this.#n.config.onSuccess?.(a,this),this.#n.config.onSettled?.(a,this.state.error,this),a}catch(a){if(a instanceof dx){if(a.silent)return this.#r.promise;if(a.revert){if(this.state.data===void 0)throw a;return this.state.data}}throw this.#o({type:"error",error:a}),this.#n.config.onError?.(a,this),this.#n.config.onSettled?.(this.state.data,a,this),a}finally{this.scheduleGc()}}#o(e){const t=n=>{switch(e.type){case"failed":return{...n,fetchFailureCount:e.failureCount,fetchFailureReason:e.error};case"pause":return{...n,fetchStatus:"paused"};case"continue":return{...n,fetchStatus:"fetching"};case"fetch":return{...n,...a7(n.data,this.options),fetchMeta:e.meta??null};case"success":const r={...n,...IA(e.data,e.dataUpdatedAt),dataUpdateCount:n.dataUpdateCount+1,...!e.manual&&{fetchStatus:"idle",fetchFailureCount:0,fetchFailureReason:null}};return this.#e=e.manual?r:void 0,r;case"error":const i=e.error;return{...n,error:i,errorUpdateCount:n.errorUpdateCount+1,errorUpdatedAt:Date.now(),fetchFailureCount:n.fetchFailureCount+1,fetchFailureReason:i,fetchStatus:"idle",status:"error"};case"invalidate":return{...n,isInvalidated:!0};case"setState":return{...n,...e.state}}};this.state=t(this.state),In.batch(()=>{this.observers.forEach(n=>{n.onQueryUpdate()}),this.#n.notify({query:this,type:"updated",action:e})})}};function a7(e,t){return{fetchFailureCount:0,fetchFailureReason:null,fetchStatus:i7(t.networkMode)?"fetching":"paused",...e===void 0&&{error:null,status:"pending"}}}function IA(e,t){return{data:e,dataUpdatedAt:t??Date.now(),error:null,isInvalidated:!1,status:"success"}}function MA(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 $_=class extends hu{constructor(e,t){super(),this.options=t,this.#t=e,this.#o=null,this.#a=ux(),this.bindMethods(),this.setOptions(t)}#t;#e=void 0;#n=void 0;#i=void 0;#r;#s;#a;#o;#h;#d;#f;#c;#u;#l;#m=new Set;bindMethods(){this.refetch=this.refetch.bind(this)}onSubscribe(){this.listeners.size===1&&(this.#e.addObserver(this),DA(this.#e,this.options)?this.#p():this.updateResult(),this.#_())}onUnsubscribe(){this.hasListeners()||this.destroy()}shouldFetchOnReconnect(){return fx(this.#e,this.options,this.options.refetchOnReconnect)}shouldFetchOnWindowFocus(){return fx(this.#e,this.options,this.options.refetchOnWindowFocus)}destroy(){this.listeners=new Set,this.#w(),this.#b(),this.#e.removeObserver(this)}setOptions(e){const t=this.options,n=this.#e;if(this.options=this.#t.defaultQueryOptions(e),this.options.enabled!==void 0&&typeof this.options.enabled!="boolean"&&typeof this.options.enabled!="function"&&typeof Yi(this.options.enabled,this.#e)!="boolean")throw new Error("Expected enabled to be a boolean or a callback that returns a boolean");this.#S(),this.#e.setOptions(this.options),t._defaulted&&!Lp(this.options,t)&&this.#t.getQueryCache().notify({type:"observerOptionsUpdated",query:this.#e,observer:this});const r=this.hasListeners();r&&LA(this.#e,n,this.options,t)&&this.#p(),this.updateResult(),r&&(this.#e!==n||Yi(this.options.enabled,this.#e)!==Yi(t.enabled,this.#e)||hl(this.options.staleTime,this.#e)!==hl(t.staleTime,this.#e))&&this.#g();const i=this.#y();r&&(this.#e!==n||Yi(this.options.enabled,this.#e)!==Yi(t.enabled,this.#e)||i!==this.#l)&&this.#v(i)}getOptimisticResult(e){const t=this.#t.getQueryCache().build(this.#t,e),n=this.createResult(t,e);return eX(this,n)&&(this.#i=n,this.#s=this.options,this.#r=this.#e.state),n}getCurrentResult(){return this.#i}trackResult(e,t){return new Proxy(e,{get:(n,r)=>(this.trackProp(r),t?.(r),r==="promise"&&(this.trackProp("data"),!this.options.experimental_prefetchInRender&&this.#a.status==="pending"&&this.#a.reject(new Error("experimental_prefetchInRender feature flag is not enabled"))),Reflect.get(n,r))})}trackProp(e){this.#m.add(e)}getCurrentQuery(){return this.#e}refetch({...e}={}){return this.fetch({...e})}fetchOptimistic(e){const t=this.#t.defaultQueryOptions(e),n=this.#t.getQueryCache().build(this.#t,t);return n.fetch().then(()=>this.createResult(n,t))}fetch(e){return this.#p({...e,cancelRefetch:e.cancelRefetch??!0}).then(()=>(this.updateResult(),this.#i))}#p(e){this.#S();let t=this.#e.fetch(this.options,e);return e?.throwOnError||(t=t.catch(Yn)),t}#g(){this.#w();const e=hl(this.options.staleTime,this.#e);if(Kc||this.#i.isStale||!ax(e))return;const n=e7(this.#i.dataUpdatedAt,e)+1;this.#c=jo.setTimeout(()=>{this.#i.isStale||this.updateResult()},n)}#y(){return(typeof this.options.refetchInterval=="function"?this.options.refetchInterval(this.#e):this.options.refetchInterval)??!1}#v(e){this.#b(),this.#l=e,!(Kc||Yi(this.options.enabled,this.#e)===!1||!ax(this.#l)||this.#l===0)&&(this.#u=jo.setInterval(()=>{(this.options.refetchIntervalInBackground||ak.isFocused())&&this.#p()},this.#l))}#_(){this.#g(),this.#v(this.#y())}#w(){this.#c&&(jo.clearTimeout(this.#c),this.#c=void 0)}#b(){this.#u&&(jo.clearInterval(this.#u),this.#u=void 0)}createResult(e,t){const n=this.#e,r=this.options,i=this.#i,s=this.#r,o=this.#s,c=e!==n?e.state:this.#n,{state:d}=e;let f={...d},p=!1,m;if(t._optimisticResults){const L=this.hasListeners(),B=!L&&DA(e,t),A=L&&LA(e,n,t,r);(B||A)&&(f={...f,...a7(d.data,e.options)}),t._optimisticResults==="isRestoring"&&(f.fetchStatus="idle")}let{error:v,errorUpdatedAt:w,status:_}=f;m=f.data;let b=!1;if(t.placeholderData!==void 0&&m===void 0&&_==="pending"){let L;i?.isPlaceholderData&&t.placeholderData===o?.placeholderData?(L=i.data,b=!0):L=typeof t.placeholderData=="function"?t.placeholderData(this.#f?.state.data,this.#f):t.placeholderData,L!==void 0&&(_="success",m=cx(i?.data,L,t),p=!0)}if(t.select&&m!==void 0&&!b)if(i&&m===s?.data&&t.select===this.#h)m=this.#d;else try{this.#h=t.select,m=t.select(m),m=cx(i?.data,m,t),this.#d=m,this.#o=null}catch(L){this.#o=L}this.#o&&(v=this.#o,m=this.#d,w=Date.now(),_="error");const C=f.fetchStatus==="fetching",P=_==="pending",D=_==="error",F=P&&C,R=m!==void 0,k={status:_,fetchStatus:f.fetchStatus,isPending:P,isSuccess:_==="success",isError:D,isInitialLoading:F,isLoading:F,data:m,dataUpdatedAt:f.dataUpdatedAt,error:v,errorUpdatedAt:w,failureCount:f.fetchFailureCount,failureReason:f.fetchFailureReason,errorUpdateCount:f.errorUpdateCount,isFetched:f.dataUpdateCount>0||f.errorUpdateCount>0,isFetchedAfterMount:f.dataUpdateCount>c.dataUpdateCount||f.errorUpdateCount>c.errorUpdateCount,isFetching:C,isRefetching:C&&!P,isLoadingError:D&&!R,isPaused:f.fetchStatus==="paused",isPlaceholderData:p,isRefetchError:D&&R,isStale:lk(e,t),refetch:this.refetch,promise:this.#a,isEnabled:Yi(t.enabled,e)!==!1};if(this.options.experimental_prefetchInRender){const L=V=>{k.status==="error"?V.reject(k.error):k.data!==void 0&&V.resolve(k.data)},B=()=>{const V=this.#a=k.promise=ux();L(V)},A=this.#a;switch(A.status){case"pending":e.queryHash===n.queryHash&&L(A);break;case"fulfilled":(k.status==="error"||k.data!==A.value)&&B();break;case"rejected":(k.status!=="error"||k.error!==A.reason)&&B();break}}return k}updateResult(){const e=this.#i,t=this.createResult(this.#e,this.options);if(this.#r=this.#e.state,this.#s=this.options,this.#r.data!==void 0&&(this.#f=this.#e),Lp(t,e))return;this.#i=t;const n=()=>
12{if(!e)return!0;const{notifyOnChangeProps:r}=this.options,i=typeof r=="function"?r():r;if(i==="all"||!i&&!this.#m.size)return!0;const s=new Set(i??this.#m);return this.options.throwOnError&&s.add("error"),Object.keys(this.#i).some(o=>{const a=o;return this.#i[a]!==e[a]&&s.has(a)})};this.#E({listeners:n()})}#S(){const e=this.#t.getQueryCache().build(this.#t,this.options);if(e===this.#e)return;const t=this.#e;this.#e=e,this.#n=e.state,this.hasListeners()&&(t?.removeObserver(this),e.addObserver(this))}onQueryUpdate(){this.updateResult(),this.hasListeners()&&this.#_()}#E(e){In.batch(()=>{e.listeners&&this.listeners.forEach(t=>{t(this.#i)}),this.#t.getQueryCache().notify({query:this.#e,type:"observerResultsUpdated"})})}};function QZ(e,t){return Yi(t.enabled,e)!==!1&&e.state.data===void 0&&!(e.state.status==="error"&&t.retryOnMount===!1)}function DA(e,t){return QZ(e,t)||e.state.data!==void 0&&fx(e,t,t.refetchOnMount)}function fx(e,t,n){if(Yi(t.enabled,e)!==!1&&hl(t.staleTime,e)!=="static"){const r=typeof n=="function"?n(e):n;return r==="always"||r!==!1&&lk(e,t)}return!1}function LA(e,t,n,r){return(e!==t||Yi(r.enabled,e)===!1)&&(!n.suspense||e.state.status!=="error")&&lk(e,n)}function lk(e,t){return Yi(t.enabled,e)!==!1&&e.isStaleByTime(hl(t.staleTime,e))}function eX(e,t){return!Lp(e.getCurrentResult(),t)}function u0(e){return{onFetch:(t,n)=>{const r=t.options,i=t.fetchOptions?.meta?.fetchMore?.direction,s=t.state.data?.pages||[],o=t.state.data?.pageParams||[];let a={pages:[],pageParams:[]},c=0;const d=async()=>{let f=!1;const p=w=>{Object.defineProperty(w,"signal",{enumerable:!0,get:()=>(t.signal.aborted?f=!0:t.signal.addEventListener("abort",()=>{f=!0}),t.signal)})},m=t7(t.options,t.fetchOptions),v=async(w,_,b)=>{if(f)return Promise.reject();if(_==null&&w.pages.length)return Promise.resolve(w);const P=(()=>{const I={client:t.client,queryKey:t.queryKey,pageParam:_,direction:b?"backward":"forward",meta:t.options.meta};return p(I),I})(),D=await m(P),{maxPages:F}=t.options,R=b?jZ:$Z;return{pages:R(w.pages,D,F),pageParams:R(w.pageParams,_,F)}};if(i&&s.length){const w=i==="backward",_=w?l7:hx,b={pages:s,pageParams:o},C=_(r,b);a=await v(b,C,w)}else{const w=e??s.length;do{const _=c===0?o[0]??r.initialPageParam:hx(r,a);if(c>0&&_==null)break;a=await v(a,_),c++}while(c<w)}return a};t.options.persister?t.fetchFn=()=>t.options.persister?.(d,{client:t.client,queryKey:t.queryKey,meta:t.options.meta,signal:t.signal},n):t.fetchFn=d}}}function hx(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 l7(e,{pages:t,pageParams:n}){return t.length>0?e.getPreviousPageParam?.(t[0],t,n[0],n):void 0}function tX(e,t){return t?hx(e,t)!=null:!1}function nX(e,t){return!t||!e.getPreviousPageParam?!1:l7(e,t)!=null}var rX=class extends $_{constructor(e,t){super(e,t)}bindMethods(){super.bindMethods(),this.fetchNextPage=this.fetchNextPage.bind(this),this.fetchPreviousPage=this.fetchPreviousPage.bind(this)}setOptions(e){super.setOptions({...e,behavior:u0()})}getOptimisticResult(e){return e.behavior=u0(),super.getOptimisticResult(e)}fetchNextPage(e){return this.fetch({...e,meta:{fetchMore:{direction:"forward"}}})}fetchPreviousPage(e){return this.fetch({...e,meta:{fetchMore:{direction:"backward"}}})}createResult(e,t){const{state:n}=e,r=super.createResult(e,t),{isFetching:i,isRefetching:s,isError:o,isRefetchError:a}=r,c=n.fetchMeta?.fetchMore?.direction,d=o&&c==="forward",f=i&&c==="forward",p=o&&c==="backward",m=i&&c==="backward";return{...r,fetchNextPage:this.fetchNextPage,fetchPreviousPage:this.fetchPreviousPage,hasNextPage:tX(t,n.data),hasPreviousPage:nX(t,n.data),isFetchNextPageError:d,isFetchingNextPage:f,isFetchPreviousPageError:p,isFetchingPreviousPage:m,isRefetchError:a&&!d&&!p,isRefetching:s&&!f&&!m}}},iX=class extends o7{#t;#e;#n;#i;constructor(e){super(),this.#t=e.client,this.mutationId=e.mutationId,this.#n=e.mutationCache,this.#e=[],this.state=e.state||c7(),this.setOptions(e.options),this.scheduleGc()}setOptions(e){this.options=e,this.updateGcTime(this.options.gcTime)}get meta(){return this.options.meta}addObserver(e){this.#e.includes(e)||(this.#e.push(e),this.clearGcTimeout(),this.#n.notify({type:"observerAdded",mutation:this,observer:e}))}removeObserver(e){this.#e=this.#e.filter(t=>t!==e),this.scheduleGc(),this.#n.notify({type:"observerRemoved",mutation:this,observer:e})}optionalRemove(){this.#e.length||(this.state.status==="pending"?this.scheduleGc():this.#n.remove(this))}continue(){return this.#i?.continue()??this.execute(this.state.variables)}async execute(e){const t=()=>{this.#r({type:"continue"})},n={client:this.#t,meta:this.options.meta,mutationKey:this.options.mutationKey};this.#i=s7({fn:()=>this.options.mutationFn?this.options.mutationFn(e,n):Promise.reject(new Error("No mutationFn found")),onFail:(s,o)=>{this.#r({type:"failed",failureCount:s,error:o})},onPause:()=>{this.#r({type:"pause"})},onContinue:t,retry:this.options.retry??0,retryDelay:this.options.retryDelay,networkMode:this.options.networkMode,canRun:()=>this.#n.canRun(this)});const r=this.state.status==="pending",i=!this.#i.canStart();try{if(r)t();else{this.#r({type:"pending",variables:e,isPaused:i}),await this.#n.config.onMutate?.(e,this,n);const o=await this.options.onMutate?.(e,n);o!==this.state.context&&this.#r({type:"pending",context:o,variables:e,isPaused:i})}const s=await this.#i.start();return await this.#n.config.onSuccess?.(s,e,this.state.context,this,n),await this.options.onSuccess?.(s,e,this.state.context,n),await this.#n.config.onSettled?.(s,null,this.state.variables,this.state.context,this,n),await this.options.onSettled?.(s,null,e,this.state.context,n),this.#r({type:"success",data:s}),s}catch(s){try{throw await this.#n.config.onError?.(s,e,this.state.context,this,n),await this.options.onError?.(s,e,this.state.context,n),await this.#n.config.onSettled?.(void 0,s,this.state.variables,this.state.context,this,n),await this.options.onSettled?.(void 0,s,e,this.state.context,n),s}finally{this.#r({type:"error",error:s})}}finally{this.#n.runNext(this)}}#r(e){const t=n=>{switch(e.type){case"failed":return{...n,failureCount:e.failureCount,failureReason:e.error};case"pause":return{...n,isPaused:!0};case"continue":return{...n,isPaused:!1};
vendor: 1,577 bytes, line 12
12case"pending":return{...n,context:e.context,data:void 0,failureCount:0,failureReason:null,error:null,isPaused:e.isPaused,status:"pending",variables:e.variables,submittedAt:Date.now()};case"success":return{...n,data:e.data,failureCount:0,failureReason:null,error:null,status:"success",isPaused:!1};case"error":return{...n,data:void 0,error:e.error,failureCount:n.failureCount+1,failureReason:e.error,isPaused:!1,status:"error"}}};this.state=t(this.state),In.batch(()=>{this.#e.forEach(n=>{n.onMutationUpdate(e)}),this.#n.notify({mutation:this,type:"updated",action:e})})}};function c7(){return{context:void 0,data:void 0,error:null,failureCount:0,failureReason:null,isPaused:!1,status:"idle",variables:void 0,submittedAt:0}}var u7=class extends hu{constructor(e={}){super(),this.config=e,this.#t=new Set,this.#e=new Map,this.#n=0}#t;#e;#n;build(e,t,n){const r=new iX({client:e,mutationCache:this,mutationId:++this.#n,options:e.defaultMutationOptions(t),state:n});return this.add(r),r}add(e){this.#t.add(e);const t=Oy(e);if(typeof t=="string"){const n=this.#e.get(t);n?n.push(e):this.#e.set(t,[e])}this.notify({type:"added",mutation:e})}remove(e){if(this.#t.delete(e)){const t=Oy(e);if(typeof t=="string"){const n=this.#e.get(t);if(n)if(n.length>1){const r=n.indexOf(e);r!==-1&&n.splice(r,1)}else n[0]===e&&this.#e.delete(t)}}this.notify({type:"removed",mutation:e})}canRun(e){const t=Oy(e);if(typeof t=="string"){const r=this.#e.get(t)?.find(i=>i.state.status==="pending");return!r||r===e}else return!0}runNext(e){const t=Oy(e);return typeof t=="string"?this.#e.get(t)?.find(r=>
12r!==e&&r.state.isPaused)?.continue()??Promise.resolve():Promise.resolve()}clear(){In.batch(()=>{this.#t.forEach(e=>{this.notify({type:"removed",mutation:e})}),this.#t.clear(),this.#e.clear()})}getAll(){return Array.from(this.#t)}find(e){const t={exact:!0,...e};return this.getAll().find(n=>PA(t,n))}findAll(e={}){return this.getAll().filter(t=>PA(e,t))}notify(e){In.batch(()=>{this.listeners.forEach(t=>{t(e)})})}resumePausedMutations(){const e=this.getAll().filter(t=>t.state.isPaused);return In.batch(()=>Promise.all(e.map(t=>t.continue().catch(Yn))))}};function Oy(e){return e.options.scope?.id}var sX=class extends hu{#t;#e=void 0;#n;#i;constructor(t,n){super(),this.#t=t,this.setOptions(n),this.bindMethods(),this.#r()}bindMethods(){this.mutate=this.mutate.bind(this),this.reset=this.reset.bind(this)}setOptions(t){const n=this.options;this.options=this.#t.defaultMutationOptions(t),Lp(this.options,n)||this.#t.getMutationCache().notify({type:"observerOptionsUpdated",mutation:this.#n,observer:this}),n?.mutationKey&&this.options.mutationKey&&Gc(n.mutationKey)!==Gc(this.options.mutationKey)?this.reset():this.#n?.state.status==="pending"&&this.#n.setOptions(this.options)}onUnsubscribe(){this.hasListeners()||this.#n?.removeObserver(this)}onMutationUpdate(t){this.#r(),this.#s(t)}getCurrentResult(){return this.#e}reset(){this.#n?.removeObserver(this),this.#n=void 0,this.#r(),this.#s()}mutate(t,n){return this.#i=n,this.#n?.removeObserver(this),this.#n=this.#t.getMutationCache().build(this.#t,this.options),this.#n.addObserver(this),this.#n.execute(t)}#r(){const t=this.#n?.state??c7();this.#e={...t,isPending:t.status==="pending",isSuccess:t.status==="success",isError:t.status==="error",isIdle:t.status==="idle",mutate:this.mutate,reset:this.reset}}#s(t){In.batch(()=>{if(this.#i&&this.hasListeners()){const n=this.#e.variables,r=this.#e.context,i={client:this.#t,meta:this.options.meta,mutationKey:this.options.mutationKey};t?.type==="success"?(this.#i.onSuccess?.(t.data,n,r,i),this.#i.onSettled?.(t.data,null,
12n,r,i)):t?.type==="error"&&(this.#i.onError?.(t.error,n,r,i),this.#i.onSettled?.(void 0,t.error,n,r,i))}this.listeners.forEach(n=>{n(this.#e)})})}};function NA(e,t){const n=new Set(t);return e.filter(r=>!n.has(r))}function oX(e,t,n){const r=e.slice(0);return r[t]=n,r}var aX=class extends hu{#t;#e;#n;#i;#r;#s;#a;#o;#h=[];constructor(e,t,n){super(),this.#t=e,this.#i=n,this.#n=[],this.#r=[],this.#e=[],this.setQueries(t)}onSubscribe(){this.listeners.size===1&&this.#r.forEach(e=>{e.subscribe(t=>{this.#u(e,t)})})}onUnsubscribe(){this.listeners.size||this.destroy()}destroy(){this.listeners=new Set,this.#r.forEach(e=>{e.destroy()})}setQueries(e,t){this.#n=e,this.#i=t,In.batch(()=>{const n=this.#r,r=this.#c(this.#n);this.#h=r,r.forEach(f=>f.observer.setOptions(f.defaultedQueryOptions));const i=r.map(f=>f.observer),s=i.map(f=>f.getCurrentResult()),o=n.length!==i.length,a=i.some((f,p)=>f!==n[p]),c=o||a,d=c?!0:s.some((f,p)=>{const m=this.#e[p];return!m||!Lp(f,m)});!c&&!d||(c&&(this.#r=i),this.#e=s,this.hasListeners()&&(c&&(NA(n,i).forEach(f=>{f.destroy()}),NA(i,n).forEach(f=>{f.subscribe(p=>{this.#u(f,p)})})),this.#l()))})}getCurrentResult(){return this.#e}getQueries(){return this.#r.map(e=>e.getCurrentQuery())}getObservers(){return this.#r}getOptimisticResult(e,t){const n=this.#c(e),r=n.map(i=>i.observer.getOptimisticResult(i.defaultedQueryOptions));return[r,i=>this.#f(i??r,t),()=>this.#d(r,n)]}#d(e,t){return t.map((n,r)=>{const i=e[r];return n.defaultedQueryOptions.notifyOnChangeProps?i:n.observer.trackResult(i,s=>{t.forEach(o=>{o.observer.trackProp(s)})})})}#f(e,t){return t?((!this.#s||this.#e!==this.#o||t!==this.#a)&&(this.#a=t,this.#o=this.#e,this.#s=sk(this.#s,t(e))),this.#s):e}#c(e){const t=new Map;this.#r.forEach(r=>{const i=r.options.queryHash;if(!i)return;const s=t.get(i);s?s.push(r):t.set(i,[r])});const n=[];return e.forEach(r=>{const i=this.#t.defaultQueryOptions(r),o=t.get(i.queryHash)?.shift()??new $_(this.#t,i);n.push({defaultedQueryOptions:i,observer:o})}),n}#u(e,t){const n=this.#r.indexOf(e);n!==-1&&(this.#e=oX(this.#e,n,t),this.#l())}#l(){if(this.hasListeners()){const e=this.#s,t=this.#d(this.#e,this.#h),n=this.#f(t,this.#i?.combine);e!==n&&In.batch(()=>{this.listeners.forEach(r=>{r(this.#e)})})}}},d7=class extends hu{constructor(e={}){super(),this.config=e,this.#t=new Map}#t;build(e,t,n){const r=t.queryKey,i=t.queryHash??ik(r,t);let s=this.get(i);return s||(s=new XZ({client:e,queryKey:r,queryHash:i,options:e.defaultQueryOptions(t),state:n,defaultOptions:e.getQueryDefaults(r)}),this.add(s)),s}add(e){this.#t.has(e.queryHash)||(this.#t.set(e.queryHash,e),this.notify({type:"added",query:e}))}remove(e){const t=this.#t.get(e.queryHash);t&&(e.destroy(),t===e&&this.#t.delete(e.queryHash),this.notify({type:"removed",query:e}))}clear(){In.batch(()=>{this.getAll().forEach(e=>{this.remove(e)})})}get(e){return this.#t.get(e)}getAll(){return[...this.#t.values()]}find(e){const t={exact:!0,...e};return this.getAll().find(n=>RA(t,n))}findAll(e={}){const t=this.getAll();return Object.keys(e).length>0?t.filter(n=>RA(e,n)):t}notify(e){In.batch(()=>{this.listeners.forEach(t=>{t(e)})})}onFocus(){In.batch(()=>{this.getAll().forEach(e=>{e.onFocus()})})}onOnline(){In.batch(()=>{this.getAll().forEach(e=>{e.onOnline()})})}},lX=class{#t;#e;#n;#i;#r;#s;#a;#o;constructor(e={}){this.#t=e.queryCache||new d7,this.#e=e.mutationCache||new u7,this.#n=e.defaultOptions||{},this.#i=new Map,this.#r=new Map,this.#s=0}mount(){this.#s++,this.#s===1&&(this.#a=ak.subscribe(async e=>{e&&(await this.resumePausedMutations(),this.#t.onFocus())}),this.#o=c0.subscribe(async e=>{e&&(await this.resumePausedMutations(),this.#t.onOnline())}))}unmount(){this.#s--,this.#s===0&&(this.#a?.(),this.#a=void 0,this.#o?.(),this.#o=void 0)}isFetching(e){return this.#t.findAll({...e,fetchStatus:"fetching"}).length}isMutating(e){return this.#e.findAll({...e,status:"pending"}).length}getQueryData(e){const t=this.defaultQueryOptions({queryKey:e});return this.#t.get(t.queryHash)?.state.data}ensureQueryData(e){const t=this.defaultQueryOptions(e),n=this.#t.build(this,t),r=n.state.data;return r===void 0?this.fetchQuery(e):(e.revalidateIfStale&&n.isStaleByTime(hl(t.
12staleTime,n))&&this.prefetchQuery(t),Promise.resolve(r))}getQueriesData(e){return this.#t.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=this.#t.get(r.queryHash)?.state.data,o=DZ(t,s);if(o!==void 0)return this.#t.build(this,r).setData(o,{...n,manual:!0})}setQueriesData(e,t,n){return In.batch(()=>this.#t.findAll(e).map(({queryKey:r})=>[r,this.setQueryData(r,t,n)]))}getQueryState(e){const t=this.defaultQueryOptions({queryKey:e});return this.#t.get(t.queryHash)?.state}removeQueries(e){const t=this.#t;In.batch(()=>{t.findAll(e).forEach(n=>{t.remove(n)})})}resetQueries(e,t){const n=this.#t;return In.batch(()=>(n.findAll(e).forEach(r=>{r.reset()}),this.refetchQueries({type:"active",...e},t)))}cancelQueries(e,t={}){const n={revert:!0,...t},r=In.batch(()=>this.#t.findAll(e).map(i=>i.cancel(n)));return Promise.all(r).then(Yn).catch(Yn)}invalidateQueries(e,t={}){return In.batch(()=>(this.#t.findAll(e).forEach(n=>{n.invalidate()}),e?.refetchType==="none"?Promise.resolve():this.refetchQueries({...e,type:e?.refetchType??e?.type??"active"},t)))}refetchQueries(e,t={}){const n={...t,cancelRefetch:t.cancelRefetch??!0},r=In.batch(()=>this.#t.findAll(e).filter(i=>!i.isDisabled()&&!i.isStatic()).map(i=>{let s=i.fetch(void 0,n);return n.throwOnError||(s=s.catch(Yn)),i.state.fetchStatus==="paused"?Promise.resolve():s}));return Promise.all(r).then(Yn)}fetchQuery(e){const t=this.defaultQueryOptions(e);t.retry===void 0&&(t.retry=!1);const n=this.#t.build(this,t);return n.isStaleByTime(hl(t.staleTime,n))?n.fetch(t):Promise.resolve(n.state.data)}prefetchQuery(e){return this.fetchQuery(e).then(Yn).catch(Yn)}fetchInfiniteQuery(e){return e.behavior=u0(e.pages),this.fetchQuery(e)}prefetchInfiniteQuery(e){return this.fetchInfiniteQuery(e).then(Yn).catch(Yn)}ensureInfiniteQueryData(e){return e.behavior=u0(e.pages),this.ensureQueryData(e)}resumePausedMutations(){return c0.isOnline()?this.#e.resumePausedMutations():Promise.resolve()}getQueryCache(){return this.#t}getMutationCache(){return this.#e}getDefaultOptions(){return this.#n}setDefaultOptions(e){this.#n=e}setQueryDefaults(e,t){this.#i.set(Gc(e),{queryKey:e,defaultOptions:t})}getQueryDefaults(e){const t=[...this.#i.values()],n={};return t.forEach(r=>{Dp(e,r.queryKey)&&Object.assign(n,r.defaultOptions)}),n}setMutationDefaults(e,t){this.#r.set(Gc(e),{mutationKey:e,defaultOptions:t})}getMutationDefaults(e){const t=[...this.#r.values()],n={};return t.forEach(r=>{Dp(e,r.mutationKey)&&Object.assign(n,r.defaultOptions)}),n}defaultQueryOptions(e){if(e._defaulted)return e;const t={...this.#n.queries,...this.getQueryDefaults(e.queryKey),...e,_defaulted:!0};return t.queryHash||(t.queryHash=ik(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===ok&&(t.enabled=!1),t}defaultMutationOptions(e){return e?._defaulted?e:{...this.#n.mutations,...e?.mutationKey&&this.getMutationDefaults(e.mutationKey),...e,_defaulted:!0}}clear(){this.#t.clear(),this.#e.clear()}},f7=g.createContext(void 0),Tm=e=>{const t=g.useContext(f7);if(!t)throw new Error("No QueryClient set, use QueryClientProvider to set one");return t},cX=({client:e,children:t})=>(g.useEffect(()=>(e.mount(),()=>{e.unmount()}),[e]),j.jsx(f7.Provider,{value:e,children:t})),h7=g.createContext(!1),p7=()=>g.useContext(h7);h7.Provider;function uX(){let e=!1;return{clearReset:()=>{e=!1},reset:()=>{e=!0},isReset:()=>e}}var dX=g.createContext(uX()),m7=()=>g.useContext(dX),g7=(e,t)=>{(e.suspense||e.throwOnError||e.experimental_prefetchInRender)&&(t.isReset()||(e.retryOnMount=!1))},y7=e=>{g.useEffect(()=>{e.clearReset()},[e])},v7=({result:e,errorResetBoundary:t,throwOnError:n,query:r,suspense:i})=>e.isError&&!t.isReset()&&!e.isFetching&&r&&(i&&e.data===void 0||n7(n,[e.error,r])),_7=e=>{if(e.suspense){const n=i=>i==="static"?i:Math.max(i??1e3,1e3),r=e.staleTime;e.staleTime=typeof r=="function"?(...i)=>n(r(...i)):n(r),typeof e.gcTime=="number"&&(e.gcTime=Math.max(e.gcTime,1e3))}},w7=(e,t)=>e.isLoading&&e.isFetching&&!t,px=(e,t)=>e?.suspense&&t.isPending,d0=(e,t,n)=>t.fetchOptimistic(e).catch(()=>{n.clearReset()});function fX({queries:e,...t},n){const r=Tm(),i=p7(),s=m7(),o=g.useMemo(()=>e.map(_=>{const b=r.defaultQueryOptions(_);return b._optimisticResults=i?"isRestoring":"optimistic",b}),[e,r,i]);o.forEach(_=>{_7(_),g7(_,s)}),y7(s);const[a]=g.useState(()=>new aX(r,o,t)),[c,d,f]=a.getOptimisticResult(o,t.combine),p=!i&&t.subscribed!==!1;g.useSyncExternalStore(g.useCallback(_=>p?a.subscribe(In.batchCalls(_)):Yn,[a,p]),()=>a.getCurrentResult(),()=>a.getCurrentResult()),g.useEffect(()=>{a.setQueries(o,t)},[o,t,a]);const v=c.some((_,b)=>px(o[b],_))?c.flatMap((_,b)=>{const C=o[b];if(C){const P=new $_(r,C);if(px(C,_))return d0(C,P,s);w7(_,i)&&d0(C,P,s)}return[]}):[];if(v.length>0)throw Promise.all(v);const w=c.find((_,b)=>{const C=o[b];return C&&v7({result:_,errorResetBoundary:s,throwOnError:C.throwOnError,query:r.getQueryCache().get(C.queryHash),suspense:C.suspense})});if(w?.error)throw w.error;return d(f())}function b7(e,t,n){const r=p7(),i=m7(),s=Tm(),o=s.defaultQueryOptions(e);s.getDefaultOptions().queries?._experimental_beforeQuery?.(o),o._optimisticResults=r?"isRestoring":"optimistic",_7(o),g7(o,i),y7(i);const a=!s.getQueryCache().get(o.queryHash),[c]=g.useState(()=>new t(s,o)),d=c.getOptimisticResult(o),f=!r&&e.subscribed!==!1;if(g.useSyncExternalStore(g.useCallback(p=>{const m=f?c.subscribe(In.batchCalls(p)):Yn;return c.updateResult(),m},[c,f]),()=>c.getCurrentResult(),()=>c.getCurrentResult()),g.useEffect(()=>{c.setOptions(o)},[o,c]),px(o,d))throw d0(o,c,i);if(v7({result:d,errorResetBoundary:i,throwOnError:o.throwOnError,query:s.getQueryCache().get(o.queryHash),suspense:o.suspense}))throw d.error;return s.getDefaultOptions().queries?._experimental_afterQuery?.(o,d),o.experimental_prefetchInRender&&!Kc&&w7(d,r)&&(a?d0(o,c,i):s.getQueryCache().get(o.queryHash)?.promise)?.catch(Yn).finally(()=>{c.updateResult()}),o.notifyOnChangeProps?d:c.trackResult(d)}function As(e,t){return b7(e,$_)}function hX(e,t){const n=Tm(),[r]=g.useState(()=>new sX(n,e));g.useEffect(()=>{r.setOptions(e)},[r,e]);const i=g.useSyncExternalStore(g.useCallback(o=>r.subscribe(In.batchCalls(o)),[r]),()=>r.getCurrentResult(),()=>r.getCurrentResult()),s=g.useCallback((o,a)=>{r.mutate(o,a).catch(Yn)},[r]);if(i.error&&n7(r.options.throwOnError,[i.error]))throw i.error;return{...i,mutate:s,mutateAsync:i.mutate}}function pX(e,t){return b7(e,rX)}const mX="modulepreload",gX=function(e){return"/"+e},$A={},bn=function(t,n,r){let i=Promise.resolve();if(n&&n.length>0){let c=function(d){return Promise.all(d.map(f=>Promise.resolve(f).then(p=>({status:"fulfilled",value:p}),p=>({status:"rejected",reason:p}))))};document.getElementsByTagName("link");const o=document.querySelector("meta[property=csp-nonce]"),a=o?.nonce||o?.getAttribute("nonce");i=c(n.map(d=>{if(d=gX(d),d in $A)return;$A[d]=!0;const f=d.endsWith(".css"),p=f?'[rel="stylesheet"]':"";if(document.querySelector(`link[href="${d}"]${p}`))return;
12const m=document.createElement("link");if(m.rel=f?"stylesheet":mX,f||(m.as="script"),m.crossOrigin="",m.href=d,a&&m.setAttribute("nonce",a),document.head.appendChild(m),f)return new Promise((v,w)=>{m.addEventListener("load",v),m.addEventListener("error",()=>w(new Error(`Unable to preload CSS for ${d}`)))})}))}function s(o){const a=new Event("vite:preloadError",{cancelable:!0});if(a.payload=o,window.dispatchEvent(a),!a.defaultPrevented)throw o}return i.then(o=>{for(const a of o||[])a.status==="rejected"&&s(a.reason);return t().catch(s)})};var yX=function(){return null},vX=Symbol.for("react.lazy"),f0=w_[" use ".trim().toString()];function _X(e){return typeof e=="object"&&e!==null&&"then"in e}function S7(e){return e!=null&&typeof e=="object"&&"$$typeof"in e&&e.$$typeof===vX&&"_payload"in e&&_X(e._payload)}function wX(e){const t=SX(e),n=g.forwardRef((r,i)=>{let{children:s,...o}=r;S7(s)&&typeof f0=="function"&&(s=f0(s._payload));const a=g.Children.toArray(s),c=a.find(xX);if(c){const d=c.props.children,f=a.map(p=>p===c?g.Children.count(d)>1?g.Children.only(null):g.isValidElement(d)?d.props.children:null:p);return j.jsx(t,{...o,ref:i,children:g.isValidElement(d)?g.cloneElement(d,void 0,f):null})}return j.jsx(t,{...o,ref:i,children:s})});return n.displayName=`${e}.Slot`,n}var bX=wX("Slot");function SX(e){const t=g.forwardRef((n,r)=>{let{children:i,...s}=n;if(S7(i)&&typeof f0=="function"&&(i=f0(i._payload)),g.isValidElement(i)){const o=kX(i),a=CX(s,i.props);return i.type!==g.Fragment&&(a.ref=r?Ol(r,o):o),g.cloneElement(i,a)}return g.Children.count(i)>1?g.Children.only(null):null});return t.displayName=`${e}.SlotClone`,t}var EX=Symbol("radix.slottable");function xX(e){return g.isValidElement(e)&&typeof e.type=="function"&&"__radixId"in e.type&&e.type.__radixId===EX}function CX(e,t){const n={...t};for(const r in t){const i=e[r],s=t[r];/^on[A-Z]/.test(r)?i&&s?n[r]=(...a)=>{const c=s(...a);return i(...a),c}:i&&(n[r]=i):r==="style"?n[r]={...i,...s}:r==="className"&&(n[r]=[i,s].filter(Boolean).join(" "))}return{...e,...n}}function kX(e){let t=Object.getOwnPropertyDescriptor(e.props,"ref")?.get,n=t&&"isReactWarning"in t&&t.isReactWarning;return n?e.ref:(t=Object.getOwnPropertyDescriptor(e,"ref")?.get,n=t&&"isReactWarning"in t&&t.isReactWarning,n?e.props.ref:e.props.ref||e.ref)}function TX({title:e,titleId:t,...n},r){return g.createElement("svg",Object.assign({xmlns:"http://www.w3.org/2000/svg",fill:"none",viewBox:"0 0 24 24",strokeWidth:1.5,stroke:"currentColor","aria-hidden":"true","data-slot":"icon",ref:r,"aria-labelledby":t},n),e?g.createElement("title",{id:t},e):null,g.createElement("path",{strokeLinecap:"round",strokeLinejoin:"round",d:"M16.023 9.348h4.992v-.001M2.985 19.644v-4.992m0 0h4.992m-4.993 0 3.181 3.183a8.25 8.25 0 0 0 13.803-3.7M4.031 9.865a8.25 8.25 0 0 1 13.803-3.7l3.181 3.182m0-4.991v4.99"}))}const E7=g.forwardRef(TX);function RX({title:e,titleId:t,...n},r){return g.createElement("svg",Object.assign({xmlns:"http://www.w3.org/2000/svg",fill:"none",viewBox:"0 0 24 24",strokeWidth:1.5,stroke:"currentColor","aria-hidden":"true","data-slot":"icon",ref:r,"aria-labelledby":t},n),e?g.createElement("title",{id:t},e):null,g.createElement("path",{strokeLinecap:"round",strokeLinejoin:"round",d:"M6 18 18 6M6 6l12 12"}))}const x7=g.forwardRef(RX);var jA=e=>typeof e=="boolean"?`${e}`:e===0?"0":e,ii=e=>!e||typeof e!="object"||Object.keys(e).length===0,PX=(e,t)=>JSON.stringify(e)===JSON.stringify(t);function C7(e,t){e.forEach(function(n){Array.isArray(n)?C7(n,t):t.push(n)})}function k7(e){let t=[];return C7(e,t),t}var T7=(...e)=>k7(e).filter(Boolean),R7=(e,t)=>{let n={},r=Object.keys(e),i=Object.keys(t);for(let s of r)if(i.includes(s)){let o=e[s],a=t[s];Array.isArray(o)||Array.isArray(a)?n[s]=T7(a,o):typeof o=="object"&&typeof a=="object"?n[s]=R7(o,a):n[s]=a+" "+o}else n[s]=e[s];for(let s of i)r.includes(s)||(n[s]=t[s]);return n},FA=e=>!e||typeof e!="string"?e:e.replace(/\s+/g," ").trim();const ck="-",OX=e=>{const t=IX(e),{conflictingClassGroups:n,conflictingClassGroupModifiers:r}=e;return{getClassGroupId:o=>{const a=o.split(ck);return a[0]===""&&a.length!==1&&a.shift(),P7(a,t)||AX(o)},getConflictingClassGroupIds:(o,a)=>{const c=n[o]||[];return a&&r[o]?[...c,...r[o]]:c}}},P7=(e,t)=>{if(e.length===0)return t.classGroupId;const n=e[0],r=t.nextPart.get(n),i=r?P7(e.slice(1),r):void 0;if(i)return i;if(t.validators.length===0)return;const s=e.join(ck);return t.validators.find(({validator:o})=>o(s))?.classGroupId},UA=/^\[(.+)\]$/,AX=e=>{if(UA.test(e)){const t=UA.exec(e)[1],n=t?.substring(0,t.indexOf(":"));if(n)return"arbitrary.."+n}},IX=e=>{const{theme:t,classGroups:n}=e,r={nextPart:new Map,validators:[]};for(const i in n)mx(n[i],r,i,t);return r},mx=(e,t,n,r)=>{e.forEach(i=>
vendor: 12,032 bytes, line 12
12{if(typeof i=="string"){const s=i===""?t:zA(t,i);s.classGroupId=n;return}if(typeof i=="function"){if(MX(i)){mx(i(r),t,n,r);return}t.validators.push({validator:i,classGroupId:n});return}Object.entries(i).forEach(([s,o])=>{mx(o,zA(t,s),n,r)})})},zA=(e,t)=>{let n=e;return t.split(ck).forEach(r=>{n.nextPart.has(r)||n.nextPart.set(r,{nextPart:new Map,validators:[]}),n=n.nextPart.get(r)}),n},MX=e=>e.isThemeGetter,DX=e=>{if(e<1)return{get:()=>{},set:()=>{}};let t=0,n=new Map,r=new Map;const i=(s,o)=>{n.set(s,o),t++,t>e&&(t=0,r=n,n=new Map)};return{get(s){let o=n.get(s);if(o!==void 0)return o;if((o=r.get(s))!==void 0)return i(s,o),o},set(s,o){n.has(s)?n.set(s,o):i(s,o)}}},gx="!",yx=":",LX=yx.length,NX=e=>{const{prefix:t,experimentalParseClassName:n}=e;let r=i=>{const s=[];let o=0,a=0,c=0,d;for(let w=0;w<i.length;w++){let _=i[w];if(o===0&&a===0){if(_===yx){s.push(i.slice(c,w)),c=w+LX;continue}if(_==="/"){d=w;continue}}_==="["?o++:_==="]"?o--:_==="("?a++:_===")"&&a--}const f=s.length===0?i:i.substring(c),p=$X(f),m=p!==f,v=d&&d>c?d-c:void 0;return{modifiers:s,hasImportantModifier:m,baseClassName:p,maybePostfixModifierPosition:v}};if(t){const i=t+yx,s=r;r=o=>o.startsWith(i)?s(o.substring(i.length)):{isExternal:!0,modifiers:[],hasImportantModifier:!1,baseClassName:o,maybePostfixModifierPosition:void 0}}if(n){const i=r;r=s=>n({className:s,parseClassName:i})}return r},$X=e=>e.endsWith(gx)?e.substring(0,e.length-1):e.startsWith(gx)?e.substring(1):e,jX=e=>{const t=Object.fromEntries(e.orderSensitiveModifiers.map(r=>[r,!0]));return r=>{if(r.length<=1)return r;const i=[];let s=[];return r.forEach(o=>{o[0]==="["||t[o]?(i.push(...s.sort(),o),s=[]):s.push(o)}),i.push(...s.sort()),i}},FX=e=>({cache:DX(e.cacheSize),parseClassName:NX(e),sortModifiers:jX(e),...OX(e)}),UX=/\s+/,zX=(e,t)=>{const{parseClassName:n,getClassGroupId:r,getConflictingClassGroupIds:i,sortModifiers:s}=t,o=[],a=e.trim().split(UX);let c="";for(let d=a.length-1;d>=0;d-=1){const f=a[d],{isExternal:p,modifiers:m,hasImportantModifier:v,baseClassName:w,maybePostfixModifierPosition:_}=n(f);if(p){c=f+(c.length>0?" "+c:c);continue}let b=!!_,C=r(b?w.substring(0,_):w);if(!C){if(!b){c=f+(c.length>0?" "+c:c);continue}if(C=r(w),!C){c=f+(c.length>0?" "+c:c);continue}b=!1}const P=s(m).join(":"),D=v?P+gx:P,F=D+C;if(o.includes(F))continue;o.push(F);const R=i(C,b);for(let I=0;I<R.length;++I){const k=R[I];o.push(D+k)}c=f+(c.length>0?" "+c:c)}return c};function BX(){let e=0,t,n,r="";for(;e<arguments.length;)(t=arguments[e++])&&(n=O7(t))&&(r&&(r+=" "),r+=n);return r}const O7=e=>{if(typeof e=="string")return e;let t,n="";for(let r=0;r<e.length;r++)e[r]&&(t=O7(e[r]))&&(n&&(n+=" "),n+=t);return n};function vx(e,...t){let n,r,i,s=o;function o(c){const d=t.reduce((f,p)=>p(f),e());return n=FX(d),r=n.cache.get,i=n.cache.set,s=a,a(c)}function a(c){const d=r(c);if(d)return d;const f=zX(c,n);return i(c,f),f}return function(){return s(BX.apply(null,arguments))}}const pr=e=>{const t=n=>n[e]||[];return t.isThemeGetter=!0,t},A7=/^\[(?:(\w[\w-]*):)?(.+)\]$/i,I7=/^\((?:(\w[\w-]*):)?(.+)\)$/i,HX=/^\d+\/\d+$/,VX=/^(\d+(\.\d+)?)?(xs|sm|md|lg|xl)$/,WX=/\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$/,qX=/^(rgba?|hsla?|hwb|(ok)?(lab|lch))\(.+\)$/,KX=/^(inset_)?-?((\d+)?\.?(\d+)[a-z]+|0)_-?((\d+)?\.?(\d+)[a-z]+|0)/,GX=/^(url|image|image-set|cross-fade|element|(repeating-)?(linear|radial|conic)-gradient)\(.+\)$/,Ju=e=>HX.test(e),Ot=e=>!!e&&!Number.isNaN(Number(e)),pc=e=>!!e&&Number.isInteger(Number(e)),BA=e=>e.endsWith("%")&&Ot(e.slice(0,-1)),Ba=e=>VX.test(e),YX=()=>!0,JX=e=>WX.test(e)&&!qX.test(e),uk=()=>!1,ZX=e=>KX.test(e),XX=e=>GX.test(e),QX=e=>!je(e)&&!Fe(e),eQ=e=>yf(e,L7,uk),je=e=>A7.test(e),mc=e=>yf(e,N7,JX),Bb=e=>yf(e,dQ,Ot),tQ=e=>yf(e,M7,uk),nQ=e=>yf(e,D7,XX),rQ=e=>yf(e,uk,ZX),Fe=e=>I7.test(e),Ay=e=>vf(e,N7),iQ=e=>vf(e,fQ),sQ=e=>vf(e,M7),oQ=e=>vf(e,L7),aQ=e=>vf(e,D7),lQ=e=>vf(e,hQ,!0),yf=(e,t,n)=>{const r=A7.exec(e);return r?r[1]?t(r[1]):n(r[2]):!1},vf=(e,t,n=!1)=>{const r=I7.exec(e);return r?r[1]?t(r[1]):n:!1},M7=e=>e==="position",cQ=new Set(["image","url"]),D7=e=>cQ.has(e),uQ=new Set(["length","size","percentage"]),L7=e=>uQ.has(e),N7=e=>e==="length",dQ=e=>e==="number",fQ=e=>e==="family-name",hQ=e=>e==="shadow",_x=()=>{const e=pr("color"),t=pr("font"),n=pr("text"),r=pr("font-weight"),i=pr("tracking"),s=pr("leading"),o=pr("breakpoint"),a=pr("container"),c=pr("spacing"),d=pr("radius"),f=pr("shadow"),p=pr("inset-shadow"),m=pr("drop-shadow"),v=pr("blur"),w=pr("perspective"),_=pr("aspect"),b=pr("ease"),C=pr("animate"),P=()=>["auto","avoid","all","avoid-page","page","left","right","column"],D=()=>["bottom","center","left","left-bottom","left-top","right","right-bottom","right-top","top"],F=()=>["auto","hidden","clip","visible","scroll"],R=()=>["auto","contain","none"],I=()=>[Fe,je,c],k=()=>[Ju,"full","auto",...I()],L=()=>[pc,"none","subgrid",Fe,je],B=()=>["auto",{span:["full",pc,Fe,je]},Fe,je],A=()=>[pc,"auto",Fe,je],V=()=>["auto","min","max","fr",Fe,je],K=()=>["start","end","center","between","around","evenly","stretch","baseline"],W=()=>["start","end","center","stretch"],U=()=>["auto",...I()],q=()=>[Ju,"auto","full","dvw","dvh","lvw","lvh","svw","svh","min","max","fit",...I()],z=()=>[e,Fe,je],x=()=>[BA,mc],N=()=>["","none","full",d,Fe,je],M=()=>["",Ot,Ay,mc],E=()=>["solid","dashed","dotted","double"],O=()=>["normal","multiply","screen","overlay","darken","lighten","color-dodge","color-burn","hard-light","soft-light","difference","exclusion","hue","saturation","color","luminosity"],H=()=>["","none",v,Fe,je],Z=()=>["center","top","top-right","right","bottom-right","bottom","bottom-left","left","top-left",Fe,je],X=()=>["none",Ot,Fe,je],te=()=>["none",Ot,Fe,je],oe=()=>[Ot,Fe,je],le=()=>[Ju,"full",...I()];return{cacheSize:500,theme:{animate:["spin","ping","pulse","bounce"],aspect:["video"],blur:[Ba],breakpoint:[Ba],color:[YX],container:[Ba],"drop-shadow":[Ba],ease:["in","out","in-out"],font:[QX],"font-weight":["thin","extralight","light","normal","medium","semibold","bold","extrabold","black"],"inset-shadow":[Ba],leading:["none","tight","snug","normal","relaxed","loose"],perspective:["dramatic","near","normal","midrange","distant","none"],radius:[Ba],shadow:[Ba],spacing:["px",Ot],text:[Ba],tracking:["tighter","tight","normal","wide","wider","widest"]},classGroups:{aspect:[{aspect:["auto","square",Ju,je,Fe,_]}],container:["container"],columns:[{columns:[Ot,je,Fe,a]}],"break-after":[{"break-after":P()}],"break-before":[{"break-before":P()}],"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"],sr:["sr-only","not-sr-only"],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:[...D(),je,Fe]}],overflow:[{overflow:F()}],"overflow-x":[{"overflow-x":F()}],"overflow-y":[{"overflow-y":F()}],overscroll:[{overscroll:R()}],"overscroll-x":[{"overscroll-x":R()}],"overscroll-y":[{"overscroll-y":R()}],position:["static","fixed","absolute","relative","sticky"],inset:[{inset:k()}],"inset-x":[{"inset-x":k()}],"inset-y":[{"inset-y":k()}],start:[{start:k()}],end:[{end:k()}],top:[{top:k()}],right:[{right:k()}],bottom:[{bottom:k()}],left:[{left:k()}],visibility:["visible","invisible","collapse"],z:[{z:[pc,"auto",Fe,je]}],basis:[{basis:[Ju,"full","auto",a,...I()]}],"flex-direction":[{flex:["row","row-reverse","col","col-reverse"]}],"flex-wrap":[{flex:["nowrap","wrap","wrap-reverse"]}],flex:[{flex:[Ot,Ju,"auto","initial","none",je]}],grow:[{grow:["",Ot,Fe,je]}],shrink:[{shrink:["",Ot,Fe,je]}],order:[{order:[pc,"first","last","none",Fe,je]}],"grid-cols":[{"grid-cols":L()}],"col-start-end":[{col:B()}],"col-start":[{"col-start":A()}],"col-end":[{"col-end":A()}],"grid-rows":[{"grid-rows":L()}],"row-start-end":[{row:B()}],"row-start":[{"row-start":A()}],"row-end":[{"row-end":A()}],"grid-flow":[{"grid-flow":["row","col","dense","row-dense","col-dense"]}],"auto-cols":[{"auto-cols":V()}],"auto-rows":[{"auto-rows":V()}],gap:[{gap:I()}],"gap-x":[{"gap-x":I()}],"gap-y":[{"gap-y":I()}],"justify-content":[{justify:[...K(),"normal"]}],"justify-items":[{"justify-items":[...W(),"normal"]}],"justify-self":[{"justify-self":["auto",...W()]}],"align-content":[{content:["normal",...K()]}],"align-items":[{items:[...W(),"baseline"]}],"align-self":[{self:["auto",...W(),"baseline"]}],"place-content":[{"place-content":K()}],"place-items":[{"place-items":[...W(),"baseline"]}],"place-self":[{"place-self":["auto",...W()]}],p:[{p:I()}],px:[{px:I()}],py:[{py:I()}],ps:[{ps:I()}],pe:[{pe:I()}],pt:[{pt:I()}],pr:[{pr:I()}],pb:[{pb:I()}],pl:[{pl:I()}],m:[{m:U()}],mx:[{mx:U()}],my:[{my:U()}],ms:[{ms:U()}],me:[{me:U()}],mt:[{mt:U()}],mr:[{mr:U()}],mb:[{mb:U()}],ml:[{ml:U()}],"space-x":[{"space-x":I()}],"space-x-reverse":["space-x-reverse"],"space-y":[{"space-y":I()}],"space-y-reverse":["space-y-reverse"],size:[{size:q()}],w:[{w:[a,"screen",...q()]}],"min-w":[{"min-w":[a,"screen","none",...q()]}],"max-w":[{"max-w":[a,"screen","none","prose",{screen:[o]},...q()]}],h:[{h:["screen",...q()]}],"min-h":[{"min-h":["screen","none",...q()]}],"max-h":[{"max-h":["screen",...q()]}],"font-size":[{text:["base",n,Ay,mc]}],"font-smoothing":["antialiased","subpixel-antialiased"],"font-style":["italic","not-italic"],"font-weight":[{font:[r,Fe,Bb]}],"font-stretch":[{"font-stretch":["ultra-condensed","extra-condensed","condensed","semi-condensed","normal","semi-expanded","expanded","extra-expanded","ultra-expanded",BA,je]}],"font-family":[{font:[iQ,je,t]}],"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:[i,Fe,je]}],"line-clamp":[{"line-clamp":[Ot,"none",Fe,Bb]}],leading:[{leading:[s,...I()]}],"list-image":[{"list-image":["none",Fe,je]}],"list-style-position":[{list:["inside","outside"]}],"list-style-type":[{list:["disc","decimal","none",Fe,je]}],"text-alignment":[{text:["left","center","right","justify","start","end"]}],"placeholder-color":[{placeholder:z()}],"text-color":[{text:z()}],"text-decoration":["underline","overline","line-through","no-underline"],"text-decoration-style":[{decoration:[...E(),"wavy"]}],"text-decoration-thickness":[{decoration:[Ot,"from-font","auto",Fe,mc]}],"text-decoration-color":[{decoration:z()}],"underline-offset":[{"underline-offset":[Ot,"auto",Fe,je]}],"text-transform":["uppercase","lowercase","capitalize","normal-case"],"text-overflow":["truncate","text-ellipsis","text-clip"],"text-wrap":[{text:["wrap","nowrap","balance","pretty"]}],indent:[{indent:I()}],"vertical-align":[{align:["baseline","top","middle","bottom","text-top","text-bottom","sub","super",Fe,je]}],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",Fe,je]}],"bg-attachment":[{bg:["fixed","local","scroll"]}],"bg-clip":[{"bg-clip":["border","padding","content","text"]}],"bg-origin":[{"bg-origin":["border","padding","content"]}],"bg-position":[{bg:[...D(),sQ,tQ]}],"bg-repeat":[{bg:["no-repeat",{repeat:["","x","y","space","round"]}]}],"bg-size":[{bg:["auto","cover","contain",oQ,eQ]}],"bg-image":[{bg:["none",{linear:[{to:["t","tr","r","br","b","bl","l","tl"]},pc,Fe,je],radial:["",Fe,je],conic:[pc,Fe,je]},aQ,nQ]}],"bg-color":[{bg:z()}],"gradient-from-pos":[{from:x()}
vendor: 4,511 bytes, line 12
12],"gradient-via-pos":[{via:x()}],"gradient-to-pos":[{to:x()}],"gradient-from":[{from:z()}],"gradient-via":[{via:z()}],"gradient-to":[{to:z()}],rounded:[{rounded:N()}],"rounded-s":[{"rounded-s":N()}],"rounded-e":[{"rounded-e":N()}],"rounded-t":[{"rounded-t":N()}],"rounded-r":[{"rounded-r":N()}],"rounded-b":[{"rounded-b":N()}],"rounded-l":[{"rounded-l":N()}],"rounded-ss":[{"rounded-ss":N()}],"rounded-se":[{"rounded-se":N()}],"rounded-ee":[{"rounded-ee":N()}],"rounded-es":[{"rounded-es":N()}],"rounded-tl":[{"rounded-tl":N()}],"rounded-tr":[{"rounded-tr":N()}],"rounded-br":[{"rounded-br":N()}],"rounded-bl":[{"rounded-bl":N()}],"border-w":[{border:M()}],"border-w-x":[{"border-x":M()}],"border-w-y":[{"border-y":M()}],"border-w-s":[{"border-s":M()}],"border-w-e":[{"border-e":M()}],"border-w-t":[{"border-t":M()}],"border-w-r":[{"border-r":M()}],"border-w-b":[{"border-b":M()}],"border-w-l":[{"border-l":M()}],"divide-x":[{"divide-x":M()}],"divide-x-reverse":["divide-x-reverse"],"divide-y":[{"divide-y":M()}],"divide-y-reverse":["divide-y-reverse"],"border-style":[{border:[...E(),"hidden","none"]}],"divide-style":[{divide:[...E(),"hidden","none"]}],"border-color":[{border:z()}],"border-color-x":[{"border-x":z()}],"border-color-y":[{"border-y":z()}],"border-color-s":[{"border-s":z()}],"border-color-e":[{"border-e":z()}],"border-color-t":[{"border-t":z()}],"border-color-r":[{"border-r":z()}],"border-color-b":[{"border-b":z()}],"border-color-l":[{"border-l":z()}],"divide-color":[{divide:z()}],"outline-style":[{outline:[...E(),"none","hidden"]}],"outline-offset":[{"outline-offset":[Ot,Fe,je]}],"outline-w":[{outline:["",Ot,Ay,mc]}],"outline-color":[{outline:[e]}],shadow:[{shadow:["","none",f,lQ,rQ]}],"shadow-color":[{shadow:z()}],"inset-shadow":[{"inset-shadow":["none",Fe,je,p]}],"inset-shadow-color":[{"inset-shadow":z()}],"ring-w":[{ring:M()}],"ring-w-inset":["ring-inset"],"ring-color":[{ring:z()}],"ring-offset-w":[{"ring-offset":[Ot,mc]}],"ring-offset-color":[{"ring-offset":z()}],"inset-ring-w":[{"inset-ring":M()}],"inset-ring-color":[{"inset-ring":z()}],opacity:[{opacity:[Ot,Fe,je]}],"mix-blend":[{"mix-blend":[...O(),"plus-darker","plus-lighter"]}],"bg-blend":[{"bg-blend":O()}],filter:[{filter:["","none",Fe,je]}],blur:[{blur:H()}],brightness:[{brightness:[Ot,Fe,je]}],contrast:[{contrast:[Ot,Fe,je]}],"drop-shadow":[{"drop-shadow":["","none",m,Fe,je]}],grayscale:[{grayscale:["",Ot,Fe,je]}],"hue-rotate":[{"hue-rotate":[Ot,Fe,je]}],invert:[{invert:["",Ot,Fe,je]}],saturate:[{saturate:[Ot,Fe,je]}],sepia:[{sepia:["",Ot,Fe,je]}],"backdrop-filter":[{"backdrop-filter":["","none",Fe,je]}],"backdrop-blur":[{"backdrop-blur":H()}],"backdrop-brightness":[{"backdrop-brightness":[Ot,Fe,je]}],"backdrop-contrast":[{"backdrop-contrast":[Ot,Fe,je]}],"backdrop-grayscale":[{"backdrop-grayscale":["",Ot,Fe,je]}],"backdrop-hue-rotate":[{"backdrop-hue-rotate":[Ot,Fe,je]}],"backdrop-invert":[{"backdrop-invert":["",Ot,Fe,je]}],"backdrop-opacity":[{"backdrop-opacity":[Ot,Fe,je]}],"backdrop-saturate":[{"backdrop-saturate":[Ot,Fe,je]}],"backdrop-sepia":[{"backdrop-sepia":["",Ot,Fe,je]}],"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:["","all","colors","opacity","shadow","transform","none",Fe,je]}],"transition-behavior":[{transition:["normal","discrete"]}],duration:[{duration:[Ot,"initial",Fe,je]}],ease:[{ease:["linear","initial",b,Fe,je]}],delay:[{delay:[Ot,Fe,je]}],animate:[{animate:["none",C,Fe,je]}],backface:[{backface:["hidden","visible"]}],perspective:[{perspective:[w,Fe,je]}],"perspective-origin":[{"perspective-origin":Z()}],rotate:[{rotate:X()}],"rotate-x":[{"rotate-x":X()}],"rotate-y":[{"rotate-y":X()}],"rotate-z":[{"rotate-z":X()}],scale:[{scale:te()}],"scale-x":[{"scale-x":te()}],"scale-y":[{"scale-y":te()}],"scale-z":[{"scale-z":te()}],"scale-3d":["scale-3d"],skew:[{skew:oe()}],"skew-x":[{"skew-x":oe()}],"skew-y":[{"skew-y":oe()}],transform:[{transform:[Fe,je,"","none","gpu","cpu"]}],"transform-origin":[{origin:Z()}],"transform-style":[{transform:["3d","flat"]}],translate:[{translate:le()}],"translate-x":[{"translate-x":le()}],"translate-y":[{"translate-y":le()}],"translate-z":[{"translate-z":le()}],"translate-none":["translate-none"],accent:[{accent:z()}],appearance:[{appearance:["none","auto"]}],"caret-color":[{caret:z()}
vendor: 5,000 bytes, line 12
12],"color-scheme":[{scheme:["normal","dark","light","light-dark","only-dark","only-light"]}],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",Fe,je]}],"field-sizing":[{"field-sizing":["fixed","content"]}],"pointer-events":[{"pointer-events":["auto","none"]}],resize:[{resize:["none","","y","x"]}],"scroll-behavior":[{scroll:["auto","smooth"]}],"scroll-m":[{"scroll-m":I()}],"scroll-mx":[{"scroll-mx":I()}],"scroll-my":[{"scroll-my":I()}],"scroll-ms":[{"scroll-ms":I()}],"scroll-me":[{"scroll-me":I()}],"scroll-mt":[{"scroll-mt":I()}],"scroll-mr":[{"scroll-mr":I()}],"scroll-mb":[{"scroll-mb":I()}],"scroll-ml":[{"scroll-ml":I()}],"scroll-p":[{"scroll-p":I()}],"scroll-px":[{"scroll-px":I()}],"scroll-py":[{"scroll-py":I()}],"scroll-ps":[{"scroll-ps":I()}],"scroll-pe":[{"scroll-pe":I()}],"scroll-pt":[{"scroll-pt":I()}],"scroll-pr":[{"scroll-pr":I()}],"scroll-pb":[{"scroll-pb":I()}],"scroll-pl":[{"scroll-pl":I()}],"snap-align":[{snap:["start","end","center","align-none"]}],"snap-stop":[{snap:["normal","always"]}],"snap-type":[{snap:["none","x","y","both"]}],"snap-strictness":[{snap:["mandatory","proximity"]}],touch:[{touch:["auto","none","manipulation"]}],"touch-x":[{"touch-pan":["x","left","right"]}],"touch-y":[{"touch-pan":["y","up","down"]}],"touch-pz":["touch-pinch-zoom"],select:[{select:["none","text","all","auto"]}],"will-change":[{"will-change":["auto","scroll","contents","transform",Fe,je]}],fill:[{fill:["none",...z()]}],"stroke-w":[{stroke:[Ot,Ay,mc,Bb]}],stroke:[{stroke:["none",...z()]}],"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"],translate:["translate-x","translate-y","translate-none"],"translate-none":["translate","translate-x","translate-y","translate-z"],"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"]},orderSensitiveModifiers:["before","after","placeholder","file","marker","selection","first-line","first-letter","backdrop","*","**"]}},pQ=(e,{cacheSize:t,prefix:n,experimentalParseClassName:r,extend:i={},override:s={}})=>(Xh(e,"cacheSize",t),Xh(e,"prefix",n),Xh(e,"experimentalParseClassName",r),Iy(e.theme,s.theme),Iy(e.classGroups,s.classGroups),Iy(e.conflictingClassGroups,s.conflictingClassGroups),Iy(e.conflictingClassGroupModifiers,s.conflictingClassGroupModifiers),Xh(e,"orderSensitiveModifiers",s.orderSensitiveModifiers),My(e.theme,i.theme),My(e.classGroups,i.classGroups),My(e.conflictingClassGroups,i.conflictingClassGroups),My(e.conflictingClassGroupModifiers,i.conflictingClassGroupModifiers),$7(e,i,"orderSensitiveModifiers"),e),Xh=(e,t,n)=>{n!==void 0&&(e[t]=n)},Iy=(e,t)=>
12{if(t)for(const n in t)Xh(e,n,t[n])},My=(e,t)=>{if(t)for(const n in t)$7(e,t,n)},$7=(e,t,n)=>{const r=t[n];r!==void 0&&(e[n]=e[n]?e[n].concat(r):r)},mQ=(e,...t)=>typeof e=="function"?vx(_x,e,...t):vx(()=>pQ(_x(),e),...t),gQ=vx(_x);var yQ={twMerge:!0,twMergeConfig:{},responsiveVariants:!1},j7=e=>e||void 0,Np=(...e)=>j7(k7(e).filter(Boolean).join(" ")),Hb=null,Io={},wx=!1,Ph=(...e)=>t=>t.twMerge?((!Hb||wx)&&(wx=!1,Hb=ii(Io)?gQ:mQ({...Io,extend:{theme:Io.theme,classGroups:Io.classGroups,conflictingClassGroupModifiers:Io.conflictingClassGroupModifiers,conflictingClassGroups:Io.conflictingClassGroups,...Io.extend}})),j7(Hb(Np(e)))):Np(e),HA=(e,t)=>{for(let n in t)e.hasOwnProperty(n)?e[n]=Np(e[n],t[n]):e[n]=t[n];return e},dk=(e,t)=>{let{extend:n=null,slots:r={},variants:i={},compoundVariants:s=[],compoundSlots:o=[],defaultVariants:a={}}=e,c={...yQ,...t},d=n!=null&&n.base?Np(n.base,e?.base):e?.base,f=n!=null&&n.variants&&!ii(n.variants)?R7(i,n.variants):i,p=n!=null&&n.defaultVariants&&!ii(n.defaultVariants)?{...n.defaultVariants,...a}:a;!ii(c.twMergeConfig)&&!PX(c.twMergeConfig,Io)&&(wx=!0,Io=c.twMergeConfig);let m=ii(n?.slots),v=ii(r)?{}:{base:Np(e?.base,m&&n?.base),...r},w=m?v:HA({...n?.slots},ii(v)?{base:e?.base}:v),_=ii(n?.compoundVariants)?s:T7(n?.compoundVariants,s),b=P=>{if(ii(f)&&ii(r)&&m)return Ph(d,P?.class,P?.className)(c);if(_&&!Array.isArray(_))throw new TypeError(`The "compoundVariants" prop must be an array. Received: ${typeof _}`);if(o&&!Array.isArray(o))throw new TypeError(`The "compoundSlots" prop must be an array. Received: ${typeof o}`);let D=(K,W,U=[],q)=>{let z=U;if(typeof W=="string")z=z.concat(FA(W).split(" ").map(x=>`${K}:${x}`));else if(Array.isArray(W))z=z.concat(W.reduce((x,N)=>x.concat(`${K}:${N}`),[]));else if(typeof W=="object"&&typeof q=="string"){for(let x in W)if(W.hasOwnProperty(x)&&x===q){let N=W[x];if(N&&typeof N=="string"){let M=FA(N);z[q]?z[q]=z[q].concat(M.split(" ").map(E=>`${K}:${E}`)):z[q]=M.split(" ").map(E=>`${K}:${E}`)}else Array.isArray(N)&&N.length>0&&(z[q]=N.reduce((M,E)=>M.concat(`${K}:${E}`),[]))}}return z},F=(K,W=f,U=null,q=null)=>{var z;let x=W[K];if(!x||ii(x))return null;let N=(z=q?.[K])!=null?z:P?.[K];if(N===null)return null;let M=jA(N),E=Array.isArray(c.responsiveVariants)&&c.responsiveVariants.length>0||c.responsiveVariants===!0,O=p?.[K],H=[];if(typeof M=="object"&&E)for(let[te,oe]of Object.entries(M)){let le=x[oe];if(te==="initial"){O=oe;continue}Array.isArray(c.responsiveVariants)&&!c.responsiveVariants.includes(te)||(H=D(te,le,H,U))}let Z=M!=null&&typeof M!="object"?M:jA(O),X=x[Z||"false"];return typeof H=="object"&&typeof U=="string"&&H[U]?HA(H,X):H.length>0?(H.push(X),U==="base"?H.join(" "):H):X},R=()=>f?Object.keys(f).map(K=>F(K,f)):null,I=(K,W)=>{if(!f||typeof f!="object")return null;let U=new Array;for(let q in f){let z=F(q,f,K,W),x=K==="base"&&typeof z=="string"?z:z&&z[K];x&&(U[U.length]=x)}return U},k={};for(let K in P)P[K]!==void 0&&(k[K]=P[K]);let L=(K,W)=>{var U;let q=typeof P?.[K]=="object"?{[K]:(U=P[K])==null?void 0:U.initial}:{};return{...p,...k,...q,...W}},B=(K=[],W)=>{let U=[];for(let{class:q,className:z,...x}of K){let N=!0;for(let[M,E]of Object.entries(x)){let O=L(M,W)[M];if(Array.isArray(E)){if(!E.includes(O)){N=!1;break}}else{let H=Z=>Z==null||Z===!1;if(H(E)&&H(O))continue;if(O!==E){N=!1;break}}}N&&(q&&U.push(q),z&&U.push(z))}return U},A=K=>{let W=B(_,K);if(!Array.isArray(W))return W;let U={};for(let q of W)if(typeof q=="string"&&(U.base=Ph(U.base,q)(c)),typeof q=="object")for(let[z,x]of Object.entries(q))U[z]=Ph(U[z],x)(c);return U},V=K=>{if(o.length<1)return null;let W={};for(let{slots:U=[],class:q,className:z,...x}of o){if(!ii(x)){let N=!0;for(let M of Object.keys(x)){let E=L(M,K)[M];if(E===void 0||(Array.isArray(x[M])?!x[M].includes(E):x[M]!==E)){N=!1;break}}if(!N)continue}for(let N of U)W[N]=W[N]||[],W[N].push([q,z])}return W};if(!ii(r)||!m){let K={};if(typeof w=="object"&&!ii(w))for(let W of Object.keys(w))K[W]=U=>{var q,z;return Ph(w[W],I(W,U),((q=A(U))!=null?q:[])[W],((z=V(U))!=null?z:[])[W],U?.class,U?.className)(c)};return K}return Ph(d,R(),B(_),P?.class,P?.className)(c)},C=()=>
12{if(!(!f||typeof f!="object"))return Object.keys(f)};return b.variantKeys=C(),b.extend=n,b.base=d,b.slots=w,b.variants=f,b.defaultVariants=p,b.compoundSlots=o,b.compoundVariants=_,b};const vQ=dk({base:["relative cursor-pointer inline-flex items-center justify-center whitespace-nowrap text-center transition-all duration-100 ease-in-out","disabled:pointer-events-none disabled:shadow-none"],variants:{variant:{solid:["text-base font-semibold","rounded-[56px]","disabled:bg-gray-100 disabled:text-navy-blue/50 disabled:cursor-not-allowed","h-[48px] px-[24px]"],subtle:["text-base font-semibold","rounded-[56px]","disabled:bg-soft-silver disabled:text-navy-blue/50 disabled:cursor-not-allowed","h-[40px] px-[22px]"],outline:["border","bg-white","text-secondary","hover:bg-gray-50","shadow-xs","text-sm font-medium","rounded-[8px]","h-[36px] px-3","disabled:bg-[#E5E7EF]","disabled:opacity-50","disabled:border-navy-blue/20","disabled:text-navy-blue/40","disabled:pointer-events-none","disabled:shadow-inner"],text:["text-[15px] font-semibold","rounded-[56px]","text-slate-blue","disabled:text-navy-blue/50"],ghost:["text-sm font-medium","rounded-[8px]","hover:bg-gray-50","h-[36px] px-3","disabled:opacity-50","disabled:pointer-events-none"]},color:{primary:"",secondary:"",math:"",english:"",subject:""}},compoundVariants:[{variant:"solid",color:"primary",className:"text-white bg-primary hover:opacity-90"},{variant:"solid",color:"secondary",className:"text-white bg-secondary hover:opacity-90"},{variant:"solid",color:"math",className:"text-white bg-math hover:opacity-90"},{variant:"solid",color:"english",className:"text-white bg-english hover:opacity-90"},{variant:"solid",color:"subject",className:"text-white subject-fill hover:opacity-90"},{variant:"subtle",color:"math",className:"text-math bg-math/10 hover:bg-math/20"},{variant:"subtle",color:"english",className:"text-english bg-english/10 hover:bg-english/20"},{variant:"subtle",color:"subject",className:"subject-text subject-wash hover:opacity-90"},{variant:"subtle",color:"primary",className:"text-primary bg-primary/10 hover:bg-primary/20"}],defaultVariants:{variant:"solid",color:"primary"}}),Kr=bt.forwardRef(({asChild:e,isLoading:t=!1,className:n,disabled:r,variant:i,children:s,color:o,...a},c)=>{const d=e?bX:"button";return j.jsxs(d,{ref:c,className:sn(vQ({variant:i,color:o}),n),disabled:r||t,...a,children:[s,t&&j.jsx(E7,{className:"size-4 animate-spin ml-2"})]})});Kr.displayName="Button";const Ze=typeof __SENTRY_DEBUG__>"u"||__SENTRY_DEBUG__,zt=globalThis,$c="10.29.0";function pu(){return j_(zt),zt}function j_(e){const t=e.__SENTRY__=e.__SENTRY__||{};return t.version=t.version||$c,t[$c]=t[$c]||{}}function _f(e,t,n=zt){const r=n.__SENTRY__=n.__SENTRY__||{},i=r[$c]=r[$c]||{};return i[e]||(i[e]=t())}const _Q=["debug","info","warn","error","log","assert","trace"],wQ="Sentry Logger ",h0={};function mu(e){if(!("console"in zt))return e();const t=zt.console,n={},r=Object.keys(h0);r.forEach(i=>{const s=h0[i];n[i]=t[i],t[i]=s});try{return e()}finally{r.forEach(i=>{t[i]=n[i]})}}function bQ(){hk().enabled=!0}function SQ(){hk().enabled=!1}function F7(){return hk().enabled}function EQ(...e){fk("log",...e)}function xQ(...e){fk("warn",...e)}function CQ(...e){fk("error",...e)}function fk(e,...t){Ze&&F7()&&mu(()=>{zt.console[e](`${wQ}[${e}]:`,...t)})}function hk(){return Ze?_f("loggerSettings",()=>({enabled:!1})):{enabled:!1}}const Se={enable:bQ,disable:SQ,isEnabled:F7,log:EQ,warn:xQ,error:CQ},U7=50,Yc="?",VA=/\(error: (.*)\)/,WA=/captureMessage|captureException/;function z7(...e){const t=e.sort((n,r)=>n[0]-r[0]).map(n=>n[1]);return(n,r=0,i=0)=>{const s=[],o=n.split(` 13`);for(let a=r;a<o.length;a++){let c=o[a];c.length>1024&&(c=c.slice(0,1024));const d=VA.test(c)?c.replace(VA,"$1"):c;if(!d.match(/\S*Error: /)){for(const f of t){const p=f(d);if(p){s.push(p);break}}if(s.length>=U7+i)break}}return TQ(s.slice(i))}}function kQ(e){return Array.isArray(e)?z7(...e):e}function TQ(e){if(!e.length)return[];const t=Array.from(e);return/sentryWrapped/.test(Dy(t).function||"")&&t.pop(),t.reverse(),WA.test(Dy(t).function||"")&&(t.pop(),WA.test(Dy(t).function||"")&&t.pop()),t.slice(0,U7).map(n=>({...n,filename:n.filename||Dy(t).filename,function:n.function||Yc}))}function Dy(e){return e[e.length-1]||{}}const Vb="<anonymous>";function Qo(e){try{return!e||typeof e!="function"?Vb:e.name||Vb}catch{return Vb}}function qA(e){const t=e.exception;if(t){const n=[];
13try{return t.values.forEach(r=>{r.stacktrace.frames&&n.push(...r.stacktrace.frames)}),n}catch{return}}}function B7(e){return"__v_isVNode"in e&&e.__v_isVNode?"[VueVNode]":"[VueViewModel]"}const _v={},KA={};function Il(e,t){_v[e]=_v[e]||[],_v[e].push(t)}function Ml(e,t){if(!KA[e]){KA[e]=!0;try{t()}catch(n){Ze&&Se.error(`Error while instrumenting ${e}`,n)}}}function Zi(e,t){const n=e&&_v[e];if(n)for(const r of n)try{r(t)}catch(i){Ze&&Se.error(`Error while triggering instrumentation handler. 14Type: ${e} 15Name: ${Qo(r)} 16Error:`,i)}}let Wb=null;function H7(e){const t="error";Il(t,e),Ml(t,RQ)}function RQ(){Wb=zt.onerror,zt.onerror=function(e,t,n,r,i){return Zi("error",{column:r,error:i,line:n,msg:e,url:t}),Wb?Wb.apply(this,arguments):!1},zt.onerror.__SENTRY_INSTRUMENTED__=!0}let qb=null;function V7(e){const t="unhandledrejection";Il(t,e),Ml(t,PQ)}function PQ(){qb=zt.onunhandledrejection,zt.onunhandledrejection=function(e){return Zi("unhandledrejection",e),qb?qb.apply(this,arguments):!0},zt.onunhandledrejection.__SENTRY_INSTRUMENTED__=!0}const W7=Object.prototype.toString;function pk(e){switch(W7.call(e)){case"[object Error]":case"[object Exception]":case"[object DOMException]":case"[object WebAssembly.Exception]":return!0;default:return ea(e,Error)}}function wf(e,t){return W7.call(e)===`[object ${t}]`}function q7(e){return wf(e,"ErrorEvent")}function GA(e){return wf(e,"DOMError")}function OQ(e){return wf(e,"DOMException")}function Ho(e){return wf(e,"String")}function mk(e){return typeof e=="object"&&e!==null&&"__sentry_template_string__"in e&&"__sentry_template_values__"in e}function qd(e){return e===null||mk(e)||typeof e!="object"&&typeof e!="function"}function $p(e){return wf(e,"Object")}function F_(e){return typeof Event<"u"&&ea(e,Event)}function AQ(e){return typeof Element<"u"&&ea(e,Element)}function IQ(e){return wf(e,"RegExp")}function bf(e){return!!(e?.then&&typeof e.then=="function")}function MQ(e){return $p(e)&&"nativeEvent"in e&&"preventDefault"in e&&"stopPropagation"in e}function ea(e,t){try{return e instanceof t}catch{return!1}}function K7(e){return!!(typeof e=="object"&&e!==null&&(e.__isVue||e._isVue||e.__v_isVNode))}function G7(e){return typeof Request<"u"&&ea(e,Request)}const gk=zt,DQ=80;function hi(e,t={}){if(!e)return"<unknown>";try{let n=e;const r=5,i=[];let s=0,o=0;const a=" > ",c=a.length;let d;const f=Array.isArray(t)?t:t.keyAttrs,p=!Array.isArray(t)&&t.maxStringLength||DQ;for(;n&&s++<r&&(d=LQ(n,f),!(d==="html"||s>1&&o+i.length*c+d.length>=p));)i.push(d),o+=d.length,n=n.parentNode;return i.reverse().join(a)}catch{return"<unknown>"}}function LQ(e,t){const n=e,r=[];if(!n?.tagName)return"";if(gk.HTMLElement&&n instanceof HTMLElement&&n.dataset){if(n.dataset.sentryComponent)return n.dataset.sentryComponent;if(n.dataset.sentryElement)return n.dataset.sentryElement}r.push(n.tagName.toLowerCase());const i=t?.length?t.filter(o=>n.getAttribute(o)).map(o=>[o,n.getAttribute(o)]):null;if(i?.length)i.forEach(o=>{r.push(`[${o[0]}="${o[1]}"]`)});else{n.id&&r.push(`#${n.id}`);const o=n.className;if(o&&Ho(o)){const a=o.split(/\s+/);for(const c of a)r.push(`.${c}`)}}const s=["aria-label","type","name","title","alt"];for(const o of s){const a=n.getAttribute(o);a&&r.push(`[${o}="${a}"]`)}return r.join("")}function Sf(){try{return gk.document.location.href}catch{return""}}function Y7(e){if(!gk.HTMLElement)return null;let t=e;const n=5;for(let r=0;r<n;r++){if(!t)return null;if(t instanceof HTMLElement){if(t.dataset.sentryComponent)return t.dataset.sentryComponent;if(t.dataset.sentryElement)return t.dataset.sentryElement}t=t.parentNode}return null}function li(e,t,n){if(!(t in e))return;const r=e[t];if(typeof r!="function")return;const i=n(r);typeof i=="function"&&J7(i,r);try{e[t]=i}catch{Ze&&Se.log(`Failed to replace method "${t}" in object`,e)}}function Pi(e,t,n){try{Object.defineProperty(e,t,{value:n,writable:!0,configurable:!0})}catch{Ze&&Se.log(`Failed to add non-enumerable property "${t}" to object`,e)}}function J7(e,t){try{const n=t.prototype||{};e.prototype=t.prototype=n,Pi(e,"__sentry_original__",t)}catch{}}function yk(e){return e.__sentry_original__}function Z7(e){if(pk(e))return{message:e.message,name:e.name,stack:e.stack,...JA(e)};if(F_(e)){const t={type:e.type,target:YA(e.target),currentTarget:YA(e.currentTarget),...JA(e)};return typeof CustomEvent<"u"&&ea(e,CustomEvent)&&(t.detail=e.detail),t}else return e}function YA(e){try{return AQ(e)?hi(e):Object.prototype.toString.call(e)}catch{return"<unknown>"}}function JA(e){if(typeof e=="object"&&e!==null){const t={};for(const n in e)Object.prototype.hasOwnProperty.call(e,n)&&(t[n]=e[n]);return t}else return{}}function NQ(e){const t=Object.keys(Z7(e));return t.sort(),t[0]?t.join(", "):"[object has no keys]"}function bx(e,t=0){return typeof e!="string"||t===0||e.length<=t?e:`${e.slice(0,t)}...`}function ZA(e,t){if(!Array.isArray(e))return"";const n=[];for(let r=0;r<e.length;r++){const i=e[r];try{K7(i)?n.push(B7(i)):n.push(String(i))}catch{n.push("[value cannot be serialized]")}}return n.join(t)}function wv(e,t,n=!1){return Ho(e)?IQ(t)?t.test(e):Ho(t)?n?e===t:e.includes(t):!1:!1}function Vo(e,t=[],n=!1){return t.some(r=>wv(e,r,n))}function $Q(){const e=zt;return e.crypto||e.msCrypto}let Kb;function jQ(){return Math.random()*16}function Ri(e=$Q()){try{if(e?.randomUUID)return e.randomUUID().replace(/-/g,"")}catch{}return Kb||(Kb="10000000100040008000"+1e11),Kb.replace(/[018]/g,t=>(t^(jQ()&15)>>t/4).toString(16))}function X7(e){return e.exception?.values?.[0]}function kc(e){const{message:t,event_id:n}=e;if(t)return t;const r=X7(e);return r?r.type&&r.value?`${r.type}: ${r.value}
16`:r.type||r.value||n||"<unknown>":n||"<unknown>"}function Sx(e,t,n){const r=e.exception=e.exception||{},i=r.values=r.values||[],s=i[0]=i[0]||{};s.value||(s.value=t||""),s.type||(s.type="Error")}function Kd(e,t){const n=X7(e);if(!n)return;const r={type:"generic",handled:!0},i=n.mechanism;if(n.mechanism={...r,...i,...t},t&&"data"in t){const s={...i?.data,...t.data};n.mechanism.data=s}}function XA(e){if(FQ(e))return!0;try{Pi(e,"__sentry_captured__",!0)}catch{}return!1}function FQ(e){try{return e.__sentry_captured__}catch{}}const Q7=1e3;function gu(){return Date.now()/Q7}function UQ(){const{performance:e}=zt;if(!e?.now||!e.timeOrigin)return gu;const t=e.timeOrigin;return()=>(t+e.now())/Q7}let QA;function yr(){return(QA??(QA=UQ()))()}let Gb;function zQ(){const{performance:e}=zt;if(!e?.now)return[void 0,"none"];const t=3600*1e3,n=e.now(),r=Date.now(),i=e.timeOrigin?Math.abs(e.timeOrigin+n-r):t,s=i<t,o=e.timing?.navigationStart,c=typeof o=="number"?Math.abs(o+n-r):t,d=c<t;return s||d?i<=c?[e.timeOrigin,"timeOrigin"]:[o,"navigationStart"]:[r,"dateNow"]}function pi(){return Gb||(Gb=zQ()),Gb[0]}function BQ(e){const t=yr(),n={sid:Ri(),init:!0,timestamp:t,started:t,duration:0,status:"ok",errors:0,ignoreDuration:!1,toJSON:()=>VQ(n)};return e&&Gd(n,e),n}function Gd(e,t={}){if(t.user&&(!e.ipAddress&&t.user.ip_address&&(e.ipAddress=t.user.ip_address),!e.did&&!t.did&&(e.did=t.user.id||t.user.email||t.user.username)),e.timestamp=t.timestamp||yr(),t.abnormal_mechanism&&(e.abnormal_mechanism=t.abnormal_mechanism),t.ignoreDuration&&(e.ignoreDuration=t.ignoreDuration),t.sid&&(e.sid=t.sid.length===32?t.sid:Ri()),t.init!==void 0&&(e.init=t.init),!e.did&&t.did&&(e.did=`${t.did}`),typeof t.started=="number"&&(e.started=t.started),e.ignoreDuration)e.duration=void 0;else if(typeof t.duration=="number")e.duration=t.duration;else{const n=e.timestamp-e.started;e.duration=n>=0?n:0}t.release&&(e.release=t.release),t.environment&&(e.environment=t.environment),!e.ipAddress&&t.ipAddress&&(e.ipAddress=t.ipAddress),!e.userAgent&&t.userAgent&&(e.userAgent=t.userAgent),typeof t.errors=="number"&&(e.errors=t.errors),t.status&&(e.status=t.status)}function HQ(e,t){let n={};e.status==="ok"&&(n={status:"exited"}),Gd(e,n)}function VQ(e){return{sid:`${e.sid}`,init:e.init,started:new Date(e.started*1e3).toISOString(),timestamp:new Date(e.timestamp*1e3).toISOString(),status:e.status,errors:e.errors,did:typeof e.did=="number"||typeof e.did=="string"?`${e.did}`:void 0,duration:e.duration,abnormal_mechanism:e.abnormal_mechanism,attrs:{release:e.release,environment:e.environment,ip_address:e.ipAddress,user_agent:e.userAgent}}}function Rm(e,t,n=2){if(!t||typeof t!="object"||n<=0)return t;if(e&&Object.keys(t).length===0)return e;const r={...e};for(const i in t)Object.prototype.hasOwnProperty.call(t,i)&&(r[i]=Rm(r[i],t[i],n-1));return r}function ta(){return Ri()}function Wo(){return Ri().substring(16)}const Ex="_sentrySpan";function Yd(e,t){t?Pi(e,Ex,t):delete e[Ex]}function p0(e){return e[Ex]}const WQ=100;class so{constructor(){this._notifyingListeners=!1,this._scopeListeners=[],this._eventProcessors=[],this._breadcrumbs=[],this._attachments=[],this._user={},this._tags={},this._attributes={},this._extra={},this._contexts={},this._sdkProcessingMetadata={},this._propagationContext={traceId:ta(),sampleRand:Math.random()}}clone(){const t=new so;return t._breadcrumbs=[...this._breadcrumbs],t._tags={...this._tags},t._attributes={...this._attributes},t._extra={...this._extra},t._contexts={...this._contexts},this._contexts.flags&&(t._contexts.flags={values:[...this._contexts.flags.values]}),t._user=this._user,t._level=this._level,t._session=this._session,t._transactionName=this._transactionName,t._fingerprint=this._fingerprint,t._eventProcessors=[...this._eventProcessors],t._attachments=[...this._attachments],t._sdkProcessingMetadata={...this._sdkProcessingMetadata},t._propagationContext={...this._propagationContext},t._client=this._client,t._lastEventId=this._lastEventId,Yd(t,p0(this)),t}setClient(t){this._client=t}setLastEventId(t){this._lastEventId=t}getClient(){return this._client}lastEventId(){return this._lastEventId}addScopeListener(t){this._scopeListeners.push(t)}addEventProcessor(t){return this._eventProcessors.push(t),this}setUser(t){return this._user=t||{email:void 0,id:void 0,ip_address:void 0,username:void 0},this._session&&Gd(this._session,{user:t}),this._notifyScopeListeners(),this}getUser(){return this._user}setTags(t){return this._tags={...this._tags,...t},this._notifyScopeListeners(),this}setTag(t,n){return this.setTags({[t]:n})}setAttributes(t){return this._attributes={...this._attributes,...t},this._notifyScopeListeners(),this}setAttribute(t,n){return this.setAttributes({[t]:n})}removeAttribute(t){return t in this._attributes&&(delete this._attributes[t],this._notifyScopeListeners()),this}setExtras(t){return this._extra={...this._extra,...t},this._notifyScopeListeners(),this}setExtra(t,n){return this._extra={...this._extra,[t]:n},this._notifyScopeListeners(),this}setFingerprint(t){return this._fingerprint=t,this._notifyScopeListeners(),this}setLevel(t){return this._level=t,this._notifyScopeListeners(),this}setTransactionName(t){return this._transactionName=t,this._notifyScopeListeners(),this}setContext(t,n){return n===null?delete this._contexts[t]:this._contexts[t]=n,this._notifyScopeListeners(),this}setSession(t){return t?this._session=t:delete this._session,this._notifyScopeListeners(),this}getSession(){return this._session}update(t){if(!t)return this;const n=typeof t=="function"?t(this):t,r=n instanceof so?n.getScopeData():$p(n)?t:void 0,{tags:i,attributes:s,extra:o,user:a,contexts:c,level:d,fingerprint:f=[],propagationContext:p}=r||{};return this._tags={...this._tags,...i},this._attributes={...this._attributes,...s},this._extra={...this._extra,...o},this._contexts={...this._contexts,...c},a&&Object.keys(a).length&&(this._user=a),d&&(this._level=d),f.length&&(this._fingerprint=f),p&&(this._propagationContext=p),this}clear(){return this._breadcrumbs=[],this._tags={},this._attributes={},this._extra={},this._user={},this._contexts={},this._level=void 0,this._transactionName=void 0,this._fingerprint=void 0,this._session=void 0,Yd(this,void 0),this._attachments=[],this.setPropagationContext({traceId:ta(),sampleRand:Math.random()}),this._notifyScopeListeners(),this}addBreadcrumb(t,n){const r=typeof n=="number"?n:WQ;if(r<=0)return this;const i={timestamp:gu(),...t,message:t.message?bx(t.message,2048):t.message};return this._breadcrumbs.push(i),this._breadcrumbs.length>r&&(this._breadcrumbs=this._breadcrumbs.slice(-r),this._client?.recordDroppedEvent("buffer_overflow","log_item")),this._notifyScopeListeners(),this}getLastBreadcrumb(){return this._breadcrumbs[this._breadcrumbs.length-1]}clearBreadcrumbs(){return this._breadcrumbs=[],this._notifyScopeListeners(),this}addAttachment(t){return this._attachments.push(t),this}clearAttachments(){return this._attachments=[],this}getScopeData(){return{breadcrumbs:this._breadcrumbs,attachments:this._attachments,contexts:this._contexts,tags:this._tags,attributes:this._attributes,extra:this._extra,user:this._user,level:this._level,fingerprint:this._fingerprint||[],eventProcessors:this._eventProcessors,propagationContext:this._propagationContext,sdkProcessingMetadata:this._sdkProcessingMetadata,transactionName:this._transactionName,span:p0(this)}}setSDKProcessingMetadata(t){return this._sdkProcessingMetadata=Rm(this._sdkProcessingMetadata,t,2),this}setPropagationContext(t){return this._propagationContext=t,this}getPropagationContext(){return this._propagationContext}captureException(t,n){const r=n?.event_id||Ri();if(!this._client)return Ze&&Se.warn("No client configured on scope - will not capture exception!"),r;const i=new Error("Sentry syntheticException");return this._client.captureException(t,{originalException:t,syntheticException:i,...n,event_id:r},this),r}captureMessage(t,n,r){const i=r?.event_id||Ri();if(!this._client)return Ze&&Se.warn("No client configured on scope - will not capture message!"),i;const s=r?.syntheticException??new Error(t);return this._client.captureMessage(t,n,{originalException:t,syntheticException:s,...r,event_id:i},this),i}captureEvent(t,n){const r=n?.event_id||Ri();return this._client?(this._client.captureEvent(t,{...n,event_id:r},this),r):(Ze&&Se.warn("No client configured on scope - will not capture event!"),r)}_notifyScopeListeners(){this._notifyingListeners||(this._notifyingListeners=!0,this._scopeListeners.forEac
16h(t=>{t(this)}),this._notifyingListeners=!1)}}function qQ(){return _f("defaultCurrentScope",()=>new so)}function KQ(){return _f("defaultIsolationScope",()=>new so)}class GQ{constructor(t,n){let r;t?r=t:r=new so;let i;n?i=n:i=new so,this._stack=[{scope:r}],this._isolationScope=i}withScope(t){const n=this._pushScope();let r;try{r=t(n)}catch(i){throw this._popScope(),i}return bf(r)?r.then(i=>(this._popScope(),i),i=>{throw this._popScope(),i}):(this._popScope(),r)}getClient(){return this.getStackTop().client}getScope(){return this.getStackTop().scope}getIsolationScope(){return this._isolationScope}getStackTop(){return this._stack[this._stack.length-1]}_pushScope(){const t=this.getScope().clone();return this._stack.push({client:this.getClient(),scope:t}),t}_popScope(){return this._stack.length<=1?!1:!!this._stack.pop()}}function Jd(){const e=pu(),t=j_(e);return t.stack=t.stack||new GQ(qQ(),KQ())}function YQ(e){return Jd().withScope(e)}function JQ(e,t){const n=Jd();return n.withScope(()=>(n.getStackTop().scope=e,t(e)))}function eI(e){return Jd().withScope(()=>e(Jd().getIsolationScope()))}function ZQ(){return{withIsolationScope:eI,withScope:YQ,withSetScope:JQ,withSetIsolationScope:(e,t)=>eI(t),getCurrentScope:()=>Jd().getScope(),getIsolationScope:()=>Jd().getIsolationScope()}}function Ef(e){const t=j_(e);return t.acs?t.acs:ZQ()}function tn(){const e=pu();return Ef(e).getCurrentScope()}function uo(){const e=pu();return Ef(e).getIsolationScope()}function XQ(){return _f("globalScope",()=>new so)}function U_(...e){const t=pu(),n=Ef(t);if(e.length===2){const[r,i]=e;return r?n.withSetScope(r,i):n.withScope(i)}return n.withScope(e[0])}function $t(){return tn().getClient()}function QQ(e){const t=e.getPropagationContext(),{traceId:n,parentSpanId:r,propagationSpanId:i}=t,s={trace_id:n,span_id:i||Wo()};return r&&(s.parent_span_id=r),s}const Es="sentry.source",vk="sentry.sample_rate",eN="sentry.previous_trace_sample_rate",na="sentry.op",cr="sentry.origin",jp="sentry.idle_span_finish_reason",Pm="sentry.measurement_unit",Om="sentry.measurement_value",tI="sentry.custom_span_name",_k="sentry.profile_id",xf="sentry.exclusive_time",eee="sentry.link.type",tee=0,wk=1,rr=2;function nee(e){if(e<400&&e>=100)return{code:wk};if(e>=400&&e<500)switch(e){case 401:return{code:rr,message:"unauthenticated"};case 403:return{code:rr,message:"permission_denied"};case 404:return{code:rr,message:"not_found"};case 409:return{code:rr,message:"already_exists"};case 413:return{code:rr,message:"failed_precondition"};case 429:return{code:rr,message:"resource_exhausted"};case 499:return{code:rr,message:"cancelled"};default:return{code:rr,message:"invalid_argument"}}if(e>=500&&e<600)switch(e){case 501:return{code:rr,message:"unimplemented"};case 503:return{code:rr,message:"unavailable"};case 504:return{code:rr,message:"deadline_exceeded"};default:return{code:rr,message:"internal_error"}}return{code:rr,message:"internal_error"}}function tN(e,t){e.setAttribute("http.response.status_code",t);const n=nee(t);n.message!=="unknown_error"&&e.setStatus(n)}const nN="_sentryScope",rN="_sentryIsolationScope";function ree(e){try{const t=zt.WeakRef;if(typeof t=="function")return new t(e)}catch{}return e}function iee(e){if(e){if(typeof e=="object"&&"deref"in e&&typeof e.deref=="function")try{return e.deref()}catch{return}return e}}function see(e,t,n){e&&(Pi(e,rN,ree(n)),Pi(e,nN,t))}function m0(e){const t=e;return{scope:t[nN],isolationScope:iee(t[rN])}}const bk="sentry-",oee=/^sentry-/,aee=8192;function iN(e){const t=cee(e);if(!t)return;const n=Object.entries(t).reduce((r,[i,s])=>{if(i.match(oee)){const o=i.slice(bk.length);r[o]=s}return r},{});if(Object.keys(n).length>0)return n}function lee(e){if(!e)return;const t=Object.entries(e).reduce((n,[r,i])=>(i&&(n[`${bk}${r}`]=i),n),{});return uee(t)}function cee(e){if(!(!e||!Ho(e)&&!Array.isArray(e)))return Array.isArray(e)?e.reduce((t,n)=>{const r=nI(n);return Object.entries(r).forEach(([i,s])=>{t[i]=s}),t},{}):nI(e)}function nI(e){return e.split(",").map(t=>{const n=t.indexOf("=");if(n===-1)return[];const r=t.slice(0,n),i=t.slice(n+1);return[r,i].map(s=>{try{return decodeURIComponent(s.trim())}catch{return}})}).reduce((t,[n,r])=>(n&&r&&(t[n]=r),t),{})}function uee(e){if(Object.keys(e).length!==0)return Object.entries(e).reduce((t,[n,r],i)=>{const s=`${encodeURIComponent(n)}=${encodeURIComponent(r)}`,o=i===0?s:`${t},${s}`;return o.length>aee?(Ze&&Se.warn(`Not adding key: ${n} with val: ${r} to baggage header due to exceeding baggage size limits.`),t):o},"")}const dee=/^o(\d+)\./,fee=/^(?:(\w+):)\/\/(?:(\w+)(?::(\w+)?)?@)([\w.-]+)(?::(\d+))?\/(.+)/;function hee(e){return e==="http"||e==="https"}function Cf(e,t=!1){const{host:n,path:r,pass:i,port:s,projectId:o,protocol:a,publicKey:c}=e;return`${a}://${c}${t&&i?`:${i}`:""}@${n}${s?`:${s}`:""}/${r&&`${r}/`}${o}`}function pee(e){const t=fee.exec(e);if(!t){mu(()=>{console.error(`Invalid Sentry Dsn: ${e}`)});return}const[n,r,i="",s="",o="",a=""]=t.slice(1);let c="",d=a;const f=d.split("/");if(f.length>1&&(c=f.slice(0,-1).join("/"),d=f.pop()),d){const p=d.match(/^\d+/);p&&(d=p[0])}return sN({host:s,pass:i,path:c,projectId:d,port:o,protocol:n,publicKey:r})}function sN(e){return{protocol:e.protocol,publicKey:e.publicKey||"",pass:e.pass||"",host:e.host,port:e.port||"",path:e.path||"",projectId:e.projectId}}function mee(e){if(!Ze)return!0;const{port:t,projectId:n,protocol:r}=e;return["protocol","publicKey","host","projectId"].find(o=>e[o]?!1:(Se.error(`Invalid Sentry Dsn: ${o} missing`),!0))?!1:n.match(/^\d+$/)?hee(r)?t&&isNaN(parseInt(t,10))?(Se.error(`Invalid Sentry Dsn: Invalid port ${t}`),!1):!0:(Se.error(`Invalid Sentry Dsn: Invalid protocol ${r}`),!1):(Se.error(`Invalid Sentry Dsn: Invalid projectId ${n}`),!1)}function gee(e){return e.match(dee)?.[1]}function yee(e){const t=e.getOptions(),{host:n}=e.getDsn()||{};let r;return t.orgId?r=String(t.orgId):n&&(r=gee(n)),r}function vee(e){const t=typeof e=="string"?pee(e):sN(e);if(!(!t||!mee(t)))return t}
16function Jc(e){if(typeof e=="boolean")return Number(e);const t=typeof e=="string"?parseFloat(e):e;if(!(typeof t!="number"||isNaN(t)||t<0||t>1))return t}const oN=new RegExp("^[ \\t]*([0-9a-f]{32})?-?([0-9a-f]{16})?-?([01])?[ \\t]*$");function _ee(e){if(!e)return;const t=e.match(oN);if(!t)return;let n;return t[3]==="1"?n=!0:t[3]==="0"&&(n=!1),{traceId:t[1],parentSampled:n,parentSpanId:t[2]}}function wee(e,t){const n=_ee(e),r=iN(t);if(!n?.traceId)return{traceId:ta(),sampleRand:Math.random()};const i=bee(n,r);r&&(r.sample_rand=i.toString());const{traceId:s,parentSpanId:o,parentSampled:a}=n;return{traceId:s,parentSpanId:o,sampled:a,dsc:r||{},sampleRand:i}}function aN(e=ta(),t=Wo(),n){let r="";return n!==void 0&&(r=n?"-1":"-0"),`${e}-${t}${r}`}function lN(e=ta(),t=Wo(),n){return`00-${e}-${t}-${n?"01":"00"}`}function bee(e,t){const n=Jc(t?.sample_rand);if(n!==void 0)return n;const r=Jc(t?.sample_rate);return r&&e?.parentSampled!==void 0?e.parentSampled?Math.random()*r:r+Math.random()*(1-r):Math.random()}const cN=0,Sk=1;let rI=!1;function See(e){const{spanId:t,traceId:n}=e.spanContext(),{data:r,op:i,parent_span_id:s,status:o,origin:a,links:c}=Wt(e);return{parent_span_id:s,span_id:t,trace_id:n,data:r,op:i,status:o,origin:a,links:c}}function Eee(e){const{spanId:t,traceId:n,isRemote:r}=e.spanContext(),i=r?t:Wt(e).parent_span_id,s=m0(e).scope,o=r?s?.getPropagationContext().propagationSpanId||Wo():t;return{parent_span_id:i,span_id:o,trace_id:n}}function xee(e){const{traceId:t,spanId:n}=e.spanContext(),r=Dl(e);return aN(t,n,r)}function Cee(e){const{traceId:t,spanId:n}=e.spanContext(),r=Dl(e);return lN(t,n,r)}function uN(e){if(e&&e.length>0)return e.map(({context:{spanId:t,traceId:n,traceFlags:r,...i},attributes:s})=>({span_id:t,trace_id:n,sampled:r===Sk,attributes:s,...i}))}function jc(e){return typeof e=="number"?iI(e):Array.isArray(e)?e[0]+e[1]/1e9:e instanceof Date?iI(e.getTime()):yr()}function iI(e){return e>9999999999?e/1e3:e}function Wt(e){if(Tee(e))return e.getSpanJSON();const{spanId:t,traceId:n}=e.spanContext();if(kee(e)){const{attributes:r,startTime:i,name:s,endTime:o,status:a,links:c}=e,d="parentSpanId"in e?e.parentSpanId:"parentSpanContext"in e?e.parentSpanContext?.spanId:void 0;return{span_id:t,trace_id:n,data:r,description:s,parent_span_id:d,start_timestamp:jc(i),timestamp:jc(o)||void 0,status:dN(a),op:r[na],origin:r[cr],links:uN(c)}}return{span_id:t,trace_id:n,start_timestamp:0,data:{}}}function kee(e){const t=e;return!!t.attributes&&!!t.startTime&&!!t.name&&!!t.endTime&&!!t.status}function Tee(e){return typeof e.getSpanJSON=="function"}function Dl(e){const{traceFlags:t}=e.spanContext();return t===Sk}function dN(e){if(!(!e||e.code===tee))return e.code===wk?"ok":e.message||"internal_error"}const Fc="_sentryChildSpans",xx="_sentryRootSpan";function fN(e,t){const n=e[xx]||e;Pi(t,xx,n),e[Fc]?e[Fc].add(t):Pi(e,Fc,new Set([t]))}function Ree(e,t){e[Fc]&&e[Fc].delete(t)}function bv(e){const t=new Set;function n(r){if(!t.has(r)&&Dl(r)){t.add(r);const i=r[Fc]?Array.from(r[Fc]):[];for(const s of i)n(s)}}return n(e),Array.from(t)}function Lr(e){return e[xx]||e}function Yr(){const e=pu(),t=Ef(e);return t.getActiveSpan?t.getActiveSpan():p0(tn())}function Cx(){rI||(mu(()=>{console.warn("[Sentry] Returning null from `beforeSendSpan` is disallowed. To drop certain spans, configure the respective integrations directly or use `ignoreSpans`.")}),rI=!0)}let sI=!1;function Pee(){if(sI)return;function e(){const t=Yr(),n=t&&Lr(t);if(n){const r="internal_error";Ze&&Se.log(`[Tracing] Root span: ${r} -> Global error occurred`),n.setStatus({code:rr,message:r})}}e.tag="sentry_tracingErrorCallback",sI=!0,H7(e),V7(e)}function Cs(e){if(typeof __SENTRY_TRACING__=="boolean"&&!__SENTRY_TRACING__)return!1;const t=e||$t()?.getOptions();return!!t&&(t.tracesSampleRate!=null||!!t.tracesSampler)}function oI(e){Se.log(`Ignoring span ${e.op} - ${e.description} because it matches \`ignoreSpans\`.`)}function g0(e,t){if(!t?.length||!e.description)return!1;for(const n of t){if(Aee(n)){if(wv(e.description,n))return Ze&&oI(e),!0;continue}if(!n.name&&!n.op)continue;const r=n.name?wv(e.description,n.name):!0,i=n.op?e.op&&wv(e.op,n.op):!0;if(r&&i)return Ze&&oI(e),!0}return!1}function Oee(e,t){const n=t.parent_span_id,r=t.span_id;if(n)for(const i of e)i.parent_span_id===r&&(i.parent_span_id=n)}function Aee(e){return typeof e=="string"||e instanceof RegExp}const Ek="production",hN="_frozenDsc";function Sv(e,t){Pi(e,hN,t)}function pN(e,t){const n=t.getOptions(),{publicKey:r}=t.getDsn()||{},i={environment:n.environment||Ek,release:n.release,public_key:r,trace_id:e,org_id:yee(t)};return t.emit("createDsc",i),i}function mN(e,t){const n=t.getPropagationContext();return n.dsc||pN(n.traceId,e)}function ra(e){const t=$t();if(!t)return{};const n=Lr(e),r=Wt(n),i=r.data,s=n.spanContext().traceState,o=s?.get("sentry.sample_rate")??i[vk]??i[eN];
16function a(w){return(typeof o=="number"||typeof o=="string")&&(w.sample_rate=`${o}`),w}const c=n[hN];if(c)return a(c);const d=s?.get("sentry.dsc"),f=d&&iN(d);if(f)return a(f);const p=pN(e.spanContext().traceId,t),m=i[Es],v=r.description;return m!=="url"&&v&&(p.transaction=v),Cs()&&(p.sampled=String(Dl(n)),p.sample_rand=s?.get("sentry.sample_rand")??m0(n).scope?.getPropagationContext().sampleRand.toString()),a(p),t.emit("createDsc",p,n),p}class bl{constructor(t={}){this._traceId=t.traceId||ta(),this._spanId=t.spanId||Wo()}spanContext(){return{spanId:this._spanId,traceId:this._traceId,traceFlags:cN}}end(t){}setAttribute(t,n){return this}setAttributes(t){return this}setStatus(t){return this}updateName(t){return this}isRecording(){return!1}addEvent(t,n,r){return this}addLink(t){return this}addLinks(t){return this}recordException(t,n){}}function vs(e,t=100,n=1/0){try{return kx("",e,t,n)}catch(r){return{ERROR:`**non-serializable** (${r})`}}}function gN(e,t=3,n=100*1024){const r=vs(e,t);return Lee(r)>n?gN(e,t-1,n):r}function kx(e,t,n=1/0,r=1/0,i=Nee()){const[s,o]=i;if(t==null||["boolean","string"].includes(typeof t)||typeof t=="number"&&Number.isFinite(t))return t;const a=Iee(e,t);if(!a.startsWith("[object "))return a;if(t.__sentry_skip_normalization__)return t;const c=typeof t.__sentry_override_normalization_depth__=="number"?t.__sentry_override_normalization_depth__:n;if(c===0)return a.replace("object ","");if(s(t))return"[Circular ~]";const d=t;if(d&&typeof d.toJSON=="function")try{const v=d.toJSON();return kx("",v,c-1,r,i)}catch{}const f=Array.isArray(t)?[]:{};let p=0;const m=Z7(t);for(const v in m){if(!Object.prototype.hasOwnProperty.call(m,v))continue;if(p>=r){f[v]="[MaxProperties ~]";break}const w=m[v];f[v]=kx(v,w,c-1,r,i),p++}return o(t),f}function Iee(e,t){try{if(e==="domain"&&t&&typeof t=="object"&&t._events)return"[Domain]";if(e==="domainEmitter")return"[DomainEmitter]";if(typeof global<"u"&&t===global)return"[Global]";if(typeof window<"u"&&t===window)return"[Window]";if(typeof document<"u"&&t===document)return"[Document]";if(K7(t))return B7(t);if(MQ(t))return"[SyntheticEvent]";if(typeof t=="number"&&!Number.isFinite(t))return`[${t}]`;if(typeof t=="function")return`[Function: ${Qo(t)}]`;if(typeof t=="symbol")return`[${String(t)}]`;if(typeof t=="bigint")return`[BigInt: ${String(t)}]`;const n=Mee(t);return/^HTML(\w*)Element$/.test(n)?`[HTMLElement: ${n}]`:`[object ${n}]`}catch(n){return`**non-serializable** (${n})`}}function Mee(e){const t=Object.getPrototypeOf(e);return t?.constructor?t.constructor.name:"null prototype"}function Dee(e){return~-encodeURI(e).split(/%..|./).length}function Lee(e){return Dee(JSON.stringify(e))}function Nee(){const e=new WeakSet;function t(r){return e.has(r)?!0:(e.add(r),!1)}function n(r){e.delete(r)}return[t,n]}function Ll(e,t=[]){return[e,t]}function $ee(e,t){const[n,r]=e;return[n,[...r,t]]}function aI(e,t){const n=e[1];for(const r of n){const i=r[0].type;if(t(r,i))return!0}return!1}function Tx(e){const t=j_(zt);return t.encodePolyfill?t.encodePolyfill(e):new TextEncoder().encode(e)}function jee(e){const[t,n]=e;let r=JSON.stringify(t);function i(s){typeof r=="string"?r=typeof s=="string"?r+s:[Tx(r),s]:r.push(typeof s=="string"?Tx(s):s)}for(const s of n){const[o,a]=s;if(i(` 17${JSON.stringify(o)} 18`),typeof a=="string"||a instanceof Uint8Array)i(a);else{let c;try{c=JSON.stringify(a)}catch{c=JSON.stringify(vs(a))}i(c)}}return typeof r=="string"?r:Fee(r)}function Fee(e){const t=e.reduce((i,s)=>i+s.length,0),n=new Uint8Array(t);let r=0;for(const i of e)n.set(i,r),r+=i.length;return n}function Uee(e){return[{type:"span"},e]}function zee(e){const t=typeof e.data=="string"?Tx(e.data):e.data;return[{type:"attachment",length:t.length,filename:e.filename,content_type:e.contentType,attachment_type:e.attachmentType},t]}const Bee={session:"session",sessions:"session",attachment:"attachment",transaction:"transaction",event:"error",client_report:"internal",user_report:"default",profile:"profile",profile_chunk:"profile",replay_event:"replay",replay_recording:"replay",check_in:"monitor",feedback:"feedback",span:"span",raw_security:"security",log:"log_item",metric:"metric",trace_metric:"metric"};function lI(e){return Bee[e]}function xk(e){if(!e?.sdk)return;
18const{name:t,version:n}=e.sdk;return{name:t,version:n}}function yN(e,t,n,r){const i=e.sdkProcessingMetadata?.dynamicSamplingContext;return{event_id:e.event_id,sent_at:new Date().toISOString(),...t&&{sdk:t},...!!n&&r&&{dsn:Cf(r)},...i&&{trace:i}}}function Hee(e,t){if(!t)return e;const n=e.sdk||{};return e.sdk={...n,name:n.name||t.name,version:n.version||t.version,integrations:[...e.sdk?.integrations||[],...t.integrations||[]],packages:[...e.sdk?.packages||[],...t.packages||[]],settings:e.sdk?.settings||t.settings?{...e.sdk?.settings,...t.settings}:void 0},e}function Vee(e,t,n,r){const i=xk(n),s={sent_at:new Date().toISOString(),...i&&{sdk:i},...!!r&&t&&{dsn:Cf(t)}},o="aggregates"in e?[{type:"sessions"},e]:[{type:"session"},e.toJSON()];return Ll(s,[o])}function Wee(e,t,n,r){const i=xk(n),s=e.type&&e.type!=="replay_event"?e.type:"event";Hee(e,n?.sdk);const o=yN(e,i,r,t);return delete e.sdkProcessingMetadata,Ll(o,[[{type:s},e]])}function qee(e,t){function n(v){return!!v.trace_id&&!!v.public_key}const r=ra(e[0]),i=t?.getDsn(),s=t?.getOptions().tunnel,o={sent_at:new Date().toISOString(),...n(r)&&{trace:r},...!!s&&i&&{dsn:Cf(i)}},{beforeSendSpan:a,ignoreSpans:c}=t?.getOptions()||{},d=c?.length?e.filter(v=>!g0(Wt(v),c)):e,f=e.length-d.length;f&&t?.recordDroppedEvent("before_send","span",f);const p=a?v=>{const w=Wt(v),_=a(w);return _||(Cx(),w)}:Wt,m=[];for(const v of d){const w=p(v);w&&m.push(Uee(w))}return Ll(o,m)}function Kee(e){if(!Ze)return;const{description:t="< unknown name >",op:n="< unknown op >",parent_span_id:r}=Wt(e),{spanId:i}=e.spanContext(),s=Dl(e),o=Lr(e),a=o===e,c=`[Tracing] Starting ${s?"sampled":"unsampled"} ${a?"root ":""}span`,d=[`op: ${n}`,`name: ${t}`,`ID: ${i}`];if(r&&d.push(`parent ID: ${r}`),!a){const{op:f,description:p}=Wt(o);d.push(`root ID: ${o.spanContext().spanId}`),f&&d.push(`root op: ${f}`),p&&d.push(`root description: ${p}`)}Se.log(`${c} 19 ${d.join(` 20 `)}`)}function Gee(e){if(!Ze)return;const{description:t="< unknown name >",op:n="< unknown op >"}=Wt(e),{spanId:r}=e.spanContext(),s=Lr(e)===e,o=`[Tracing] Finishing "${n}" ${s?"root ":""}span "${t}" with ID ${r}`;Se.log(o)}function Yee(e,t,n,r=Yr()){const i=r&&Lr(r);i&&(Ze&&Se.log(`[Measurement] Setting measurement on root span: ${e} = ${t} ${n}`),i.addEvent(e,{[Om]:t,[Pm]:n}))}function cI(e){if(!e||e.length===0)return;const t={};return e.forEach(n=>{const r=n.attributes||{},i=r[Pm],s=r[Om];typeof i=="string"&&typeof s=="number"&&(t[n.name]={value:s,unit:i})}),t}const uI=1e3;class z_{constructor(t={}){this._traceId=t.traceId||ta(),this._spanId=t.spanId||Wo(),this._startTime=t.startTimestamp||yr(),this._links=t.links,this._attributes={},this.setAttributes({[cr]:"manual",[na]:t.op,...t.attributes}),this._name=t.name,t.parentSpanId&&(this._parentSpanId=t.parentSpanId),"sampled"in t&&(this._sampled=t.sampled),t.endTimestamp&&(this._endTime=t.endTimestamp),this._events=[],this._isStandaloneSpan=t.isStandalone,this._endTime&&this._onSpanEnded()}addLink(t){return this._links?this._links.push(t):this._links=[t],this}addLinks(t){return this._links?this._links.push(...t):this._links=t,this}recordException(t,n){}spanContext(){const{_spanId:t,_traceId:n,_sampled:r}=this;return{spanId:t,traceId:n,traceFlags:r?Sk:cN}}setAttribute(t,n){return n===void 0?delete this._attributes[t]:this._attributes[t]=n,this}setAttributes(t){return Object.keys(t).forEach(n=>this.setAttribute(n,t[n])),this}updateStartTime(t){this._startTime=jc(t)}setStatus(t){return this._status=t,this}updateName(t){return this._name=t,this.setAttribute(Es,"custom"),this}end(t){this._endTime||(this._endTime=jc(t),Gee(this),this._onSpanEnded())}getSpanJSON(){return{data:this._attributes,description:this._name,op:this._attributes[na],parent_span_id:this._parentSpanId,span_id:this._spanId,start_timestamp:this._startTime,status:dN(this._status),timestamp:this._endTime,trace_id:this._traceId,origin:this._attributes[cr],profile_id:this._attributes[_k],exclusive_time:this._attributes[xf],measurements:cI(this._events),is_segment:this._isStandaloneSpan&&Lr(this)===this||void 0,segment_id:this._isStandaloneSpan?Lr(this).spanContext().spanId:void 0,links:uN(this._links)}}isRecording(){return!this._endTime&&!!this._sampled}addEvent(t,n,r){Ze&&Se.log("[Tracing] Adding an event to span:",t);const i=dI(n)?n:r||yr(),s=dI(n)?{}:n||{},o={name:t,time:jc(i),attributes:s};return this._events.push(o),this}isStandaloneSpan(){return!!this._isStandaloneSpan}_onSpanEnded(){const t=$t();if(t&&t.emit("spanEnd",this),!(this._isStandaloneSpan||this===Lr(this)))return;if(this._isStandaloneSpan){this._sampled?Zee(qee([this],t)):(Ze&&Se.log("[Tracing] Discarding standalone span because its trace was not chosen to be sampled."),t&&t.recordDroppedEvent("sample_rate","span"));return}const r=this._convertSpanToTransaction();r&&(m0(this).scope||tn()).captureEvent(r)}_convertSpanToTransaction(){if(!fI(Wt(this)))return;this._name||(Ze&&Se.warn("Transaction has no name, falling back to `<unlabeled transaction>`."),this._name="<unlabeled transaction>");const{scope:t,isolationScope:n}=m0(this),r=t?.getScopeData().sdkProcessingMetadata?.normalizedRequest;if(this._sampled!==!0)return;const s=bv(this).filter(f=>f!==this&&!Jee(f)).map(f=>Wt(f)).filter(fI),o=this._attributes[Es];
20delete this._attributes[tI],s.forEach(f=>{delete f.data[tI]});const a={contexts:{trace:See(this)},spans:s.length>uI?s.sort((f,p)=>f.start_timestamp-p.start_timestamp).slice(0,uI):s,start_timestamp:this._startTime,timestamp:this._endTime,transaction:this._name,type:"transaction",sdkProcessingMetadata:{capturedSpanScope:t,capturedSpanIsolationScope:n,dynamicSamplingContext:ra(this)},request:r,...o&&{transaction_info:{source:o}}},c=cI(this._events);return c&&Object.keys(c).length&&(Ze&&Se.log("[Measurements] Adding measurements to transaction event",JSON.stringify(c,void 0,2)),a.measurements=c),a}}function dI(e){return e&&typeof e=="number"||e instanceof Date||Array.isArray(e)}function fI(e){return!!e.start_timestamp&&!!e.timestamp&&!!e.span_id&&!!e.trace_id}function Jee(e){return e instanceof z_&&e.isStandaloneSpan()}function Zee(e){const t=$t();if(!t)return;const n=e[1];if(!n||n.length===0){t.recordDroppedEvent("before_send","span");return}t.sendEnvelope(e)}function Xee(e,t,n=()=>{},r=()=>{}){let i;try{i=e()}catch(s){throw t(s),n(),s}return Qee(i,t,n,r)}function Qee(e,t,n,r){return bf(e)?e.then(i=>(n(),r(i),i),i=>{throw t(i),n(),i}):(n(),r(e),e)}function ete(e,t,n){if(!Cs(e))return[!1];let r,i;typeof e.tracesSampler=="function"?(i=e.tracesSampler({...t,inheritOrSampleWith:a=>typeof t.parentSampleRate=="number"?t.parentSampleRate:typeof t.parentSampled=="boolean"?Number(t.parentSampled):a}),r=!0):t.parentSampled!==void 0?i=t.parentSampled:typeof e.tracesSampleRate<"u"&&(i=e.tracesSampleRate,r=!0);const s=Jc(i);if(s===void 0)return Ze&&Se.warn(`[Tracing] Discarding root span because of invalid sample rate. Sample rate must be a boolean or a number between 0 and 1. Got ${JSON.stringify(i)} of type ${JSON.stringify(typeof i)}.`),[!1];if(!s)return Ze&&Se.log(`[Tracing] Discarding transaction because ${typeof e.tracesSampler=="function"?"tracesSampler returned 0 or false":"a negative sampling decision was inherited or tracesSampleRate is set to 0"}`),[!1,s,r];const o=n<s;return o||Ze&&Se.log(`[Tracing] Discarding transaction because it's not included in the random sample (sampling rate = ${Number(i)})`),[o,s,r]}const vN="__SENTRY_SUPPRESS_TRACING__";function tte(e,t){const n=kk();if(n.startSpan)return n.startSpan(e,t);const r=wN(e),{forceTransaction:i,parentSpan:s,scope:o}=e,a=o?.clone();return U_(a,()=>rte(s)(()=>{const d=tn(),f=bN(d,s),m=e.onlyIfParent&&!f?new bl:_N({parentSpan:f,spanArguments:r,forceTransaction:i,scope:d});return Yd(d,m),Xee(()=>t(m),()=>{const{status:v}=Wt(m);m.isRecording()&&(!v||v==="ok")&&m.setStatus({code:rr,message:"internal_error"})},()=>{m.end()})}))}function kf(e){const t=kk();if(t.startInactiveSpan)return t.startInactiveSpan(e);const n=wN(e),{forceTransaction:r,parentSpan:i}=e;return(e.scope?o=>U_(e.scope,o):i!==void 0?o=>Ck(i,o):o=>o())(()=>{const o=tn(),a=bN(o,i);return e.onlyIfParent&&!a?new bl:_N({parentSpan:a,spanArguments:n,forceTransaction:r,scope:o})})}function Ck(e,t){const n=kk();return n.withActiveSpan?n.withActiveSpan(e,t):U_(r=>(Yd(r,e||void 0),t(r)))}function _N({parentSpan:e,spanArguments:t,forceTransaction:n,scope:r}){if(!Cs()){const o=new bl;if(n||!e){const a={sampled:"false",sample_rate:"0",transaction:t.name,...ra(o)};Sv(o,a)}return o}const i=uo();let s;if(e&&!n)s=nte(e,r,t),fN(e,s);else if(e){const o=ra(e),{traceId:a,spanId:c}=e.spanContext(),d=Dl(e);s=hI({traceId:a,parentSpanId:c,...t},r,d),Sv(s,o)}else{const{traceId:o,dsc:a,parentSpanId:c,sampled:d}={...i.getPropagationContext(),...r.getPropagationContext()};s=hI({traceId:o,parentSpanId:c,...t},r,d),a&&Sv(s,a)}return Kee(s),see(s,r,i),s}function wN(e){const n={isStandalone:(e.experimental||{}).standalone,...e};if(e.startTime){const r={...n};return r.startTimestamp=jc(e.startTime),delete r.startTime,r}return n}function kk(){const e=pu();return Ef(e)}function hI(e,t,n){const r=$t(),i=r?.getOptions()||{},{name:s=""}=e,o={spanAttributes:{...e.attributes},spanName:s,parentSampled:n};r?.emit("beforeSampling",o,{decision:!1});const a=o.parentSampled??n,c=o.spanAttributes,d=t.getPropagationContext(),[f,p,m]=t.getScopeData().sdkProcessingMetadata[vN]?[!1]:ete(i,{name:s,parentSampled:a,attributes:c,parentSampleRate:Jc(d.dsc?.sample_rate)},d.sampleRand),v=new z_({...e,attributes:{[Es]:"custom",[vk]:p!==void 0&&m?p:void 0,...c},sampled:f});return!f&&r&&(Ze&&Se.log("[Tracing] Discarding root span because its trace was not chosen to be sampled."),r.recordDroppedEvent("sample_rate","transaction")),r&&r.emit("spanStart",v),v}function nte(e,t,n){const{spanId:r,traceId:i}=e.spanContext(),s=t.getScopeData().sdkProcessingMetadata[vN]?!1:Dl(e),o=s?
20new z_({...n,parentSpanId:r,traceId:i,sampled:s}):new bl({traceId:i});fN(e,o);const a=$t();return a&&(a.emit("spanStart",o),n.endTimestamp&&a.emit("spanEnd",o)),o}function bN(e,t){if(t)return t;if(t===null)return;const n=p0(e);if(!n)return;const r=$t();return(r?r.getOptions():{}).parentSpanIsAlwaysRootSpan?Lr(n):n}function rte(e){return e!==void 0?t=>Ck(e,t):t=>t()}const Ev={idleTimeout:1e3,finalTimeout:3e4,childSpanTimeout:15e3},ite="heartbeatFailed",ste="idleTimeout",ote="finalTimeout",ate="externalFinish";function SN(e,t={}){const n=new Map;let r=!1,i,s=ate,o=!t.disableAutoFinish;const a=[],{idleTimeout:c=Ev.idleTimeout,finalTimeout:d=Ev.finalTimeout,childSpanTimeout:f=Ev.childSpanTimeout,beforeSpanEnd:p,trimIdleSpanEndTimestamp:m=!0}=t,v=$t();if(!v||!Cs()){const k=new bl,L={sample_rate:"0",sampled:"false",...ra(k)};return Sv(k,L),k}const w=tn(),_=Yr(),b=lte(e);b.end=new Proxy(b.end,{apply(k,L,B){if(p&&p(b),L instanceof bl)return;const[A,...V]=B,K=A||yr(),W=jc(K),U=bv(b).filter(E=>E!==b),q=Wt(b);if(!U.length||!m)return I(W),Reflect.apply(k,L,[W,...V]);const z=v.getOptions().ignoreSpans,x=U?.reduce((E,O)=>{const H=Wt(O);return!H.timestamp||z&&g0(H,z)?E:E?Math.max(E,H.timestamp):H.timestamp},void 0),N=q.start_timestamp,M=Math.min(N?N+d/1e3:1/0,Math.max(N||-1/0,Math.min(W,x||1/0)));return I(M),Reflect.apply(k,L,[M,...V])}});function C(){i&&(clearTimeout(i),i=void 0)}function P(k){C(),i=setTimeout(()=>{!r&&n.size===0&&o&&(s=ste,b.end(k))},c)}function D(k){i=setTimeout(()=>{!r&&o&&(s=ite,b.end(k))},f)}function F(k){C(),n.set(k,!0);const L=yr();D(L+f/1e3)}function R(k){if(n.has(k)&&n.delete(k),n.size===0){const L=yr();P(L+c/1e3)}}function I(k){r=!0,n.clear(),a.forEach(U=>U()),Yd(w,_);const L=Wt(b),{start_timestamp:B}=L;if(!B)return;L.data[jp]||b.setAttribute(jp,s);const V=L.status;(!V||V==="unknown")&&b.setStatus({code:wk}),Se.log(`[Tracing] Idle span "${L.op}" finished`);const K=bv(b).filter(U=>U!==b);let W=0;K.forEach(U=>{U.isRecording()&&(U.setStatus({code:rr,message:"cancelled"}),U.end(k),Ze&&Se.log("[Tracing] Cancelling span since span ended early",JSON.stringify(U,void 0,2)));const q=Wt(U),{timestamp:z=0,start_timestamp:x=0}=q,N=x<=k,M=(d+c)/1e3,E=z-x<=M;if(Ze){const O=JSON.stringify(U,void 0,2);N?E||Se.log("[Tracing] Discarding span since it finished after idle span final timeout",O):Se.log("[Tracing] Discarding span since it happened after idle span was finished",O)}(!E||!N)&&(Ree(b,U),W++)}),W>0&&b.setAttribute("sentry.idle_span_discarded_spans",W)}return a.push(v.on("spanStart",k=>{if(r||k===b||Wt(k).timestamp||k instanceof z_&&k.isStandaloneSpan())return;bv(b).includes(k)&&F(k.spanContext().spanId)})),a.push(v.on("spanEnd",k=>{r||R(k.spanContext().spanId)})),a.push(v.on("idleSpanEnableAutoFinish",k=>{k===b&&(o=!0,P(),n.size&&D())})),t.disableAutoFinish||P(),setTimeout(()=>{r||(b.setStatus({code:rr,message:"deadline_exceeded"}),s=ote,b.end())},d),b}function lte(e){const t=kf(e);return Yd(tn(),t),Ze&&Se.log("[Tracing] Started span is an idle span"),t}const Yb=0,pI=1,mI=2;function B_(e){return new Fp(t=>{t(e)})}function Tk(e){return new Fp((t,n)=>{n(e)})}class Fp{constructor(t){this._state=Yb,this._handlers=[],this._runExecutor(t)}then(t,n){return new Fp((r,i)=>{this._handlers.push([!1,s=>{if(!t)r(s);else try{r(t(s))}catch(o){i(o)}},s=>{if(!n)i(s);else try{r(n(s))}catch(o){i(o)}}]),this._executeHandlers()})}catch(t){return this.then(n=>n,t)}finally(t){return new Fp((n,r)=>{let i,s;return this.then(o=>{s=!1,i=o,t&&t()},o=>{s=!0,i=o,t&&t()}).then(()=>{if(s){r(i);return}n(i)})})}_executeHandlers(){if(this._state===Yb)return;const t=this._handlers.slice();this._handlers=[],t.forEach(n=>{n[0]||(this._state===pI&&n[1](this._value),this._state===mI&&n[2](this._value),n[0]=!0)})}_runExecutor(t){const n=(s,o)=>{if(this._state===Yb){if(bf(o)){o.then(r,i);return}this._state=s,this._value=o,this._executeHandlers()}},r=s=>{n(pI,s)},i=s=>{n(mI,s)};try{t(r,i)}catch(s){i(s)}}}function cte(e,t,n,r=0){try{const i=Rx(t,n,e,r);return bf(i)?i:B_(i)}catch(i){return Tk(i)}}function Rx(e,t,n,r){const i=n[r];if(!e||!i)return e;const s=i({...e},t);return Ze&&s===null&&Se.log(`Event processor "${i.id||"?"}" dropped event`),bf(s)?s.then(o=>Rx(o,t,n,r+1)):Rx(s,t,n,r+1)}function ute(e,t){const{fingerprint:n,span:r,breadcrumbs:i,sdkProcessingMetadata:s}=t;
20dte(e,t),r&&pte(e,r),mte(e,n),fte(e,i),hte(e,s)}function gI(e,t){const{extra:n,tags:r,user:i,contexts:s,level:o,sdkProcessingMetadata:a,breadcrumbs:c,fingerprint:d,eventProcessors:f,attachments:p,propagationContext:m,transactionName:v,span:w}=t;Ly(e,"extra",n),Ly(e,"tags",r),Ly(e,"user",i),Ly(e,"contexts",s),e.sdkProcessingMetadata=Rm(e.sdkProcessingMetadata,a,2),o&&(e.level=o),v&&(e.transactionName=v),w&&(e.span=w),c.length&&(e.breadcrumbs=[...e.breadcrumbs,...c]),d.length&&(e.fingerprint=[...e.fingerprint,...d]),f.length&&(e.eventProcessors=[...e.eventProcessors,...f]),p.length&&(e.attachments=[...e.attachments,...p]),e.propagationContext={...e.propagationContext,...m}}function Ly(e,t,n){e[t]=Rm(e[t],n,1)}function dte(e,t){const{extra:n,tags:r,user:i,contexts:s,level:o,transactionName:a}=t;Object.keys(n).length&&(e.extra={...n,...e.extra}),Object.keys(r).length&&(e.tags={...r,...e.tags}),Object.keys(i).length&&(e.user={...i,...e.user}),Object.keys(s).length&&(e.contexts={...s,...e.contexts}),o&&(e.level=o),a&&e.type!=="transaction"&&(e.transaction=a)}function fte(e,t){const n=[...e.breadcrumbs||[],...t];e.breadcrumbs=n.length?n:void 0}function hte(e,t){e.sdkProcessingMetadata={...e.sdkProcessingMetadata,...t}}function pte(e,t){e.contexts={trace:Eee(t),...e.contexts},e.sdkProcessingMetadata={dynamicSamplingContext:ra(t),...e.sdkProcessingMetadata};const n=Lr(t),r=Wt(n).description;r&&!e.transaction&&e.type==="transaction"&&(e.transaction=r)}function mte(e,t){e.fingerprint=e.fingerprint?Array.isArray(e.fingerprint)?e.fingerprint:[e.fingerprint]:[],t&&(e.fingerprint=e.fingerprint.concat(t)),e.fingerprint.length||delete e.fingerprint}let gc,yI,vI,Ha;function gte(e){const t=zt._sentryDebugIds,n=zt._debugIds;if(!t&&!n)return{};const r=t?Object.keys(t):[],i=n?Object.keys(n):[];if(Ha&&r.length===yI&&i.length===vI)return Ha;yI=r.length,vI=i.length,Ha={},gc||(gc={});const s=(o,a)=>{for(const c of o){const d=a[c],f=gc?.[c];if(f&&Ha&&d)Ha[f[0]]=d,gc&&(gc[c]=[f[0],d]);else if(d){const p=e(c);for(let m=p.length-1;m>=0;m--){const w=p[m]?.filename;if(w&&Ha&&gc){Ha[w]=d,gc[c]=[w,d];break}}}}};return t&&s(r,t),n&&s(i,n),Ha}function EN(e,t,n,r,i,s){const{normalizeDepth:o=3,normalizeMaxBreadth:a=1e3}=e,c={...t,event_id:t.event_id||n.event_id||Ri(),timestamp:t.timestamp||gu()},d=n.integrations||e.integrations.map(b=>b.name);yte(c,e),wte(c,d),i&&i.emit("applyFrameMetadata",t),t.type===void 0&&vte(c,e.stackParser);const f=Ste(r,n.captureContext);n.mechanism&&Kd(c,n.mechanism);const p=i?i.getEventProcessors():[],m=XQ().getScopeData();if(s){const b=s.getScopeData();gI(m,b)}if(f){const b=f.getScopeData();gI(m,b)}const v=[...n.attachments||[],...m.attachments];v.length&&(n.attachments=v),ute(c,m);const w=[...p,...m.eventProcessors];return cte(w,c,n).then(b=>(b&&_te(b),typeof o=="number"&&o>0?bte(b,o,a):b))}function yte(e,t){const{environment:n,release:r,dist:i,maxValueLength:s}=t;e.environment=e.environment||n||Ek,!e.release&&r&&(e.release=r),!e.dist&&i&&(e.dist=i);const o=e.request;o?.url&&s&&(o.url=bx(o.url,s)),s&&e.exception?.values?.forEach(a=>{a.value&&(a.value=bx(a.value,s))})}function vte(e,t){const n=gte(t);e.exception?.values?.forEach(r=>{r.stacktrace?.frames?.forEach(i=>{i.filename&&(i.debug_id=n[i.filename])})})}function _te(e){const t={};if(e.exception?.values?.forEach(r=>{r.stacktrace?.frames?.forEach(i=>{i.debug_id&&(i.abs_path?t[i.abs_path]=i.debug_id:i.filename&&(t[i.filename]=i.debug_id),delete i.debug_id)})}),Object.keys(t).length===0)return;e.debug_meta=e.debug_meta||{},e.debug_meta.images=e.debug_meta.images||[];const n=e.debug_meta.images;Object.entries(t).forEach(([r,i])=>{n.push({type:"sourcemap",code_file:r,debug_id:i})})}function wte(e,t){t.length>0&&(e.sdk=e.sdk||{},e.sdk.integrations=[...e.sdk.integrations||[],...t])}function bte(e,t,n){if(!e)return null;const r={...e,...e.breadcrumbs&&{breadcrumbs:e.breadcrumbs.map(i=>({...i,...i.data&&{data:vs(i.data,t,n)}}))},...e.user&&{user:vs(e.user,t,n)},...e.contexts&&{contexts:vs(e.contexts,t,n)},...e.extra&&{extra:vs(e.extra,t,n)}};return e.contexts?.trace&&r.contexts&&(r.contexts.trace=e.contexts.trace,e.contexts.trace.data&&(r.contexts.trace.data=vs(e.contexts.trace.data,t,n))),e.spans&&(r.spans=e.spans.map(i=>({...i,...i.data&&{data:vs(i.data,t,n)}}))),e.contexts?.flags&&r.contexts&&(r.contexts.flags=vs(e.contexts.flags,3,n)),r}function Ste(e,t){if(!t)return e;const n=e?e.clone():new so;return n.update(t),n}function Ete(e){if(e)return xte(e)?{captureContext:e}:kte(e)?{captureContext:e}:e}function xte(e){return e instanceof so||typeof e=="function"}const Cte=["user","level","extra","contexts","tags","fingerprint","propagationContext"];function kte(e){return Object.keys(e).some(t=>Cte.includes(t))}function Rk(e,t){return tn().captureException(e,Ete(t))}function xN(e,t){return tn().captureEvent(e,t)}function Pk(e,t){uo().setContext(e,t)}function Tte(){const e=$t();return e?.getOptions().enabled!==!1&&!!e?.getTransport()}function Rte(e){uo().addEventProcessor(e)}function _I(e){const t=uo(),n=tn(),{userAgent:r}=zt.navigator||{},i=BQ({user:n.getUser()||t.getUser(),...r&&{userAgent:r},...e}),s=t.getSession();return s?.status==="ok"&&Gd(s,{status:"exited"}),CN(),t.setSession(i),i}function CN(){const e=uo(),n=tn().getSession()||e.getSession();n&&HQ(n),kN(),e.setSession()}function kN(){const e=uo(),t=$t(),n=e.getSession();n&&t&&t.captureSession(n)}function wI(e=!1){if(e){CN();return}kN()}const Pte="7";function Ote(e){const t=e.protocol?`${e.protocol}:`:"",n=e.port?`:${e.port}`:"";return`${t}//${e.host}${n}${e.path?`/${e.path}`:""}/api/`}function Ate(e){return`${Ote(e)}${e.projectId}/envelope/`}function Ite(e,t){const n={sentry_version:Pte};return e.publicKey&&(n.sentry_key=e.publicKey),t&&(n.sentry_client=`${t.name}/${t.version}`),new URLSearchParams(n).toString()}function Mte(e,t,n){return t||`${Ate(e)}?${Ite(e,n)}`}const bI=[];function Dte(e){const t={};return e.forEach(n=>{const{name:r}=n,i=t[r];
20i&&!i.isDefaultInstance&&n.isDefaultInstance||(t[r]=n)}),Object.values(t)}function Lte(e){const t=e.defaultIntegrations||[],n=e.integrations;t.forEach(i=>{i.isDefaultInstance=!0});let r;if(Array.isArray(n))r=[...t,...n];else if(typeof n=="function"){const i=n(t);r=Array.isArray(i)?i:[i]}else r=t;return Dte(r)}function Nte(e,t){const n={};return t.forEach(r=>{r&&TN(e,r,n)}),n}function SI(e,t){for(const n of t)n?.afterAllSetup&&n.afterAllSetup(e)}function TN(e,t,n){if(n[t.name]){Ze&&Se.log(`Integration skipped because it was already installed: ${t.name}`);return}if(n[t.name]=t,!bI.includes(t.name)&&typeof t.setupOnce=="function"&&(t.setupOnce(),bI.push(t.name)),t.setup&&typeof t.setup=="function"&&t.setup(e),typeof t.preprocessEvent=="function"){const r=t.preprocessEvent.bind(t);e.on("preprocessEvent",(i,s)=>r(i,s,e))}if(typeof t.processEvent=="function"){const r=t.processEvent.bind(t),i=Object.assign((s,o)=>r(s,o,e),{id:t.name});e.addEventProcessor(i)}Ze&&Se.log(`Integration installed: ${t.name}`)}function $te(e){return[{type:"log",item_count:e.length,content_type:"application/vnd.sentry.items.log+json"},{items:e}]}function jte(e,t,n,r){const i={};return t?.sdk&&(i.sdk={name:t.sdk.name,version:t.sdk.version}),n&&r&&(i.dsn=Cf(r)),Ll(i,[$te(e)])}function RN(e,t){const n=t??Fte(e)??[];if(n.length===0)return;const r=e.getOptions(),i=jte(n,r._metadata,r.tunnel,e.getDsn());PN().set(e,[]),e.emit("flushLogs"),e.sendEnvelope(i)}function Fte(e){return PN().get(e)}function PN(){return _f("clientToLogBufferMap",()=>new WeakMap)}function Ute(e){return[{type:"trace_metric",item_count:e.length,content_type:"application/vnd.sentry.items.trace-metric+json"},{items:e}]}function zte(e,t,n,r){const i={};return t?.sdk&&(i.sdk={name:t.sdk.name,version:t.sdk.version}),n&&r&&(i.dsn=Cf(r)),Ll(i,[Ute(e)])}function ON(e,t){const n=t??Bte(e)??[];if(n.length===0)return;const r=e.getOptions(),i=zte(n,r._metadata,r.tunnel,e.getDsn());AN().set(e,[]),e.emit("flushMetrics"),e.sendEnvelope(i)}function Bte(e){return AN().get(e)}function AN(){return _f("clientToMetricBufferMap",()=>new WeakMap)}const Ok=Symbol.for("SentryBufferFullError");function Ak(e=100){const t=new Set;function n(){return t.size<e}function r(o){t.delete(o)}function i(o){if(!n())return Tk(Ok);const a=o();return t.add(a),a.then(()=>r(a),()=>r(a)),a}function s(o){if(!t.size)return B_(!0);const a=Promise.allSettled(Array.from(t)).then(()=>!0);if(!o)return a;const c=[a,new Promise(d=>setTimeout(()=>d(!1),o))];return Promise.race(c)}return{get $(){return Array.from(t)},add:i,drain:s}}const Hte=60*1e3;function Vte(e,t=Date.now()){const n=parseInt(`${e}`,10);if(!isNaN(n))return n*1e3;const r=Date.parse(`${e}`);return isNaN(r)?Hte:r-t}function Wte(e,t){return e[t]||e.all||0}function IN(e,t,n=Date.now()){return Wte(e,t)>n}function MN(e,{statusCode:t,headers:n},r=Date.now()){const i={...e},s=n?.["x-sentry-rate-limits"],o=n?.["retry-after"];if(s)for(const a of s.trim().split(",")){const[c,d,,,f]=a.split(":",5),p=parseInt(c,10),m=(isNaN(p)?60:p)*1e3;if(!d)i.all=r+m;else for(const v of d.split(";"))v==="metric_bucket"?(!f||f.split(";").includes("custom"))&&(i[v]=r+m):i[v]=r+m}else o?i.all=r+Vte(o,r):t===429&&(i.all=r+60*1e3);return i}const DN=64;function qte(e,t,n=Ak(e.bufferSize||DN)){let r={};const i=o=>n.drain(o);function s(o){const a=[];if(aI(o,(p,m)=>{const v=lI(m);IN(r,v)?e.recordDroppedEvent("ratelimit_backoff",v):a.push(p)}),a.length===0)return Promise.resolve({});const c=Ll(o[0],a),d=p=>{aI(c,(m,v)=>{e.recordDroppedEvent(p,lI(v))})},f=()=>t({body:jee(c)}).then(p=>(p.statusCode!==void 0&&(p.statusCode<200||p.statusCode>=300)&&Ze&&Se.warn(`Sentry responded with status code ${p.statusCode} to sent event.`),r=MN(r,p),p),p=>{throw d("network_error"),Ze&&Se.error("Encountered error running transport request:",p),p});return n.add(f).then(p=>p,p=>{if(p===Ok)return Ze&&Se.error("Skipped sending event because buffer is full."),d("queue_overflow"),Promise.resolve({});throw p})}return{send:s,flush:i}}function Kte(e,t,n){const r=[{type:"client_report"},{timestamp:gu(),discarded_events:e}];return Ll(t?{dsn:t}:{},[r])}function LN(e){const t=[];e.message&&t.push(e.message);try{const n=e.exception.values[e.exception.values.length-1];n?.value&&(t.push(n.value),n.type&&t.push(`${n.type}: ${n.value}`))}catch{}return t}function Gte(e){const{trace_id:t,parent_span_id:n,span_id:r,status:i,origin:s,data:o,op:a}=e.contexts?.trace??{};return{data:o??{},description:e.transaction,op:a,parent_span_id:n,span_id:r??"",start_timestamp:e.start_timestamp??0,status:i,timestamp:e.timestamp,trace_id:t??"",origin:s,profile_id:o?.[_k],exclusive_time:o?.[xf],measurements:e.measurements,is_segment:!0}}function Yte(e){return{type:"transaction",timestamp:e.timestamp,start_timestamp:e.start_timestamp,transaction:e.description,contexts:{trace:{trace_id:e.trace_id,span_id:e.span_id,parent_span_id:e.parent_span_id,op:e.op,status:e.status,origin:e.origin,data:{...e.data,...e.profile_id&&{[_k]:e.profile_id},...e.exclusive_time&&{[xf]:e.exclusive_time}}}},measurements:e.measurements}}const EI="Not capturing exception because it's already been captured.",xI="Discarded session because of missing or non-string release",NN=Symbol.for("SentryInternalError"),$N=Symbol.for("SentryDoNotSendEventError"),Jte=5e3;function xv(e){return{message:e,[NN]:!0}}function Jb(e){return{message:e,[$N]:!0}}function CI(e){return!!e&&typeof e=="object"&&NN in e}function kI(e){return!!e&&typeof e=="object"&&$N in e}function TI(e,t,n,r,i){let s=0,o,a=!1;e.on(n,()=>{s=0,clearTimeout(o),a=!1}),e.on(t,c=>{s+=r(c),s>=8e5?i(e):a||(a=!0,o=setTimeout(()=>{i(e)},Jte))}),e.on("flush",()=>{i(e)})}class Zte{constructor(t){if(this._options=t,this._integrations={},this._numProcessing=0,this._outcomes={},this._hooks={},this._eventProcessors=[],this._promiseBuffer=Ak(t.transportOptions?.bufferSize??DN),t.dsn?this._dsn=vee(t.dsn):Ze&&Se.warn("No DSN provided, client will not send events."),this._dsn){const r=Mte(this._dsn,t.tunnel,t._metadata?t._metadata.sdk:void 0);this._transport=t.transport({tunnel:this._options.tunnel,recordDroppedEvent:this.recordDroppedEvent.bind(this),...t.transportOptions,url:r})}this._options.enableLogs=this._options.enableLogs??this._options._experiments?.enableLogs,this._options.enableLogs&&TI(this,"afterCaptureLog","flushLogs",tne,RN),(this._options.enableMetrics??this._options._experiments?.enableMetrics??!0)&&TI(this,"afterCaptureMetric","flushMetrics",ene,ON)}captureException(t,n,r){const i=Ri();if(XA(t))return Ze&&Se.log(EI),i;const s={event_id:i,...n};return this._process(()=>this.eventFromException(t,s).then(o=>this._captureEvent(o,s,r)).then(o=>o),"error"),s.event_id}captureMessage(t,n,r,i){const s={event_id:Ri(),...r},o=mk(t)?t:String(t),a=qd(t),c=a?this.eventFromMessage(o,n,s):this.eventFromException(t,s);return this._process(()=>c.then(d=>this._captureEvent(d,s,i)),a?"unknown":"error"),s.event_id}captureEvent(t,n,r){const i=Ri();if(n?.originalException&&XA(n.originalException))return Ze&&Se.log(EI),i;const s={event_id:i,...n},o=t.sdkProcessingMetadata||{},a=o.capturedSpanScope,c=o.capturedSpanIsolationScope,d=RI(t.type);return this._process(()=>this._captureEvent(t,s,a||r,c),d),s.event_id}captureSession(t){this.sendSession(t),Gd(t,{init:!1})}getDsn(){return this._dsn}getOptions(){return this._options}getSdkMetadata(){return this._options._metadata}getTransport(){return this._transport}async flush(t){const n=this._transport;if(!n)return!0;
20this.emit("flush");const r=await this._isClientDoneProcessing(t),i=await n.flush(t);return r&&i}async close(t){const n=await this.flush(t);return this.getOptions().enabled=!1,this.emit("close"),n}getEventProcessors(){return this._eventProcessors}addEventProcessor(t){this._eventProcessors.push(t)}init(){(this._isEnabled()||this._options.integrations.some(({name:t})=>t.startsWith("Spotlight")))&&this._setupIntegrations()}getIntegrationByName(t){return this._integrations[t]}addIntegration(t){const n=this._integrations[t.name];TN(this,t,this._integrations),n||SI(this,[t])}sendEvent(t,n={}){this.emit("beforeSendEvent",t,n);let r=Wee(t,this._dsn,this._options._metadata,this._options.tunnel);for(const i of n.attachments||[])r=$ee(r,zee(i));this.sendEnvelope(r).then(i=>this.emit("afterSendEvent",t,i))}sendSession(t){const{release:n,environment:r=Ek}=this._options;if("aggregates"in t){const s=t.attrs||{};if(!s.release&&!n){Ze&&Se.warn(xI);return}s.release=s.release||n,s.environment=s.environment||r,t.attrs=s}else{if(!t.release&&!n){Ze&&Se.warn(xI);return}t.release=t.release||n,t.environment=t.environment||r}this.emit("beforeSendSession",t);const i=Vee(t,this._dsn,this._options._metadata,this._options.tunnel);this.sendEnvelope(i)}recordDroppedEvent(t,n,r=1){if(this._options.sendClientReports){const i=`${t}:${n}`;Ze&&Se.log(`Recording outcome: "${i}"${r>1?` (${r} times)`:""}`),this._outcomes[i]=(this._outcomes[i]||0)+r}}on(t,n){const r=this._hooks[t]=this._hooks[t]||new Set,i=(...s)=>n(...s);return r.add(i),()=>{r.delete(i)}}emit(t,...n){const r=this._hooks[t];r&&r.forEach(i=>i(...n))}async sendEnvelope(t){if(this.emit("beforeEnvelope",t),this._isEnabled()&&this._transport)try{return await this._transport.send(t)}catch(n){return Ze&&Se.error("Error while sending envelope:",n),{}}return Ze&&Se.error("Transport disabled"),{}}_setupIntegrations(){const{integrations:t}=this._options;this._integrations=Nte(this,t),SI(this,t)}_updateSessionFromEvent(t,n){let r=n.level==="fatal",i=!1;const s=n.exception?.values;if(s){i=!0,r=!1;for(const c of s)if(c.mechanism?.handled===!1){r=!0;break}}const o=t.status==="ok";(o&&t.errors===0||o&&r)&&(Gd(t,{...r&&{status:"crashed"},errors:t.errors||Number(i||r)}),this.captureSession(t))}async _isClientDoneProcessing(t){let n=0;for(;!t||n<t;){if(await new Promise(r=>setTimeout(r,1)),!this._numProcessing)return!0;n++}return!1}_isEnabled(){return this.getOptions().enabled!==!1&&this._transport!==void 0}_prepareEvent(t,n,r,i){const s=this.getOptions(),o=Object.keys(this._integrations);return!n.integrations&&o?.length&&(n.integrations=o),this.emit("preprocessEvent",t,n),t.type||i.setLastEventId(t.event_id||n.event_id),EN(s,t,n,r,this,i).then(a=>{if(a===null)return a;this.emit("postprocessEvent",a,n),a.contexts={trace:QQ(r),...a.contexts};const c=mN(this,r);return a.sdkProcessingMetadata={dynamicSamplingContext:c,...a.sdkProcessingMetadata},a})}_captureEvent(t,n={},r=tn(),i=uo()){return Ze&&Px(t)&&Se.log(`Captured error event \`${LN(t)[0]||"<unknown>"}\``),this._processEvent(t,n,r,i).then(s=>s.event_id,s=>{Ze&&(kI(s)?Se.log(s.message):CI(s)?Se.warn(s.message):Se.warn(s))})}_processEvent(t,n,r,i){const s=this.getOptions(),{sampleRate:o}=s,a=jN(t),c=Px(t),f=`before send for type \`${t.type||"error"}\``,p=typeof o>"u"?void 0:Jc(o);if(c&&typeof p=="number"&&Math.random()>p)return this.recordDroppedEvent("sample_rate","error"),Tk(Jb(`Discarding event because it's not included in the random sample (sampling rate = ${o})`));const m=RI(t.type);return this._prepareEvent(t,n,r,i).then(v=>{if(v===null)throw this.recordDroppedEvent("event_processor",m),Jb("An event processor returned `null`, will not send event.");if(n.data&&n.data.__sentry__===!0)return v;const _=Qte(this,s,v,n);return Xte(_,f)}).then(v=>{if(v===null){if(this.recordDroppedEvent("before_send",m),a){const C=1+(t.spans||[]).length;this.recordDroppedEvent("before_send","span",C)}throw Jb(`${f} returned \`null\`, will not send event.`)}const w=r.getSession()||i.getSession();if(c&&w&&this._updateSessionFromEvent(w,v),a){const b=v.sdkProcessingMetadata?.spanCountBeforeProcessing||0,C=v.spans?v.spans.length:0,P=b-C;P>0&&this.recordDroppedEvent("before_send","span",P)}const _=v.transaction_info;if(a&&_&&v.transaction!==t.transaction){const b="custom";v.transaction_info={..._,source:b}}return this.sendEvent(v,n),v}).then(null,v=>{throw kI(v)||CI(v)?v:(this.captureException(v,{mechanism:{handled:!1,type:"internal"},data:{__sentry__:!0},originalException:v}),xv(`Event processing pipeline threw an error, original event will not be sent. Details have been sent as a new event. 21Reason: ${v}`))})}_process(t,n){this._numProcessing++,this._promiseBuffer.add(t).then(r=>(this._numProcessing--,r),r=>(this._numProcessing--,r===Ok&&this.recordDroppedEvent("queue_overflow",n),r))}_clearOutcomes(){const t=this._outcomes;return this._outcomes={},Object.entries(t).map(([n,r])=>{const[i,s]=n.split(":");return{reason:i,category:s,quantity:r}})}_flushOutcomes(){Ze&&Se.log("Flushing outcomes...");const t=this._clearOutcomes();if(t.length===0){Ze&&Se.log("No outcomes to send");return}if(!this._dsn){Ze&&Se.log("No dsn provided, will not send outcomes");return}Ze&&Se.log("Sending outcomes:",t);const n=Kte(t,this._options.tunnel&&Cf(this._dsn));this.sendEnvelope(n)}}function RI(e){return e==="replay_event"?"replay":e||"error"}function Xte(e,t){const n=`${t} must return \`null\` or a valid event.`;if(bf(e))return e.then(r=>{if(!$p(r)&&r!==null)throw xv(n);return r},r=>{throw xv(`${t} rejected with ${r}`)});if(!$p(e)&&e!==null)throw xv(n);return e}function Qte(e,t,n,r){const{beforeSend:i,beforeSendTransaction:s,beforeSendSpan:o,ignoreSpans:a}=t;let c=n;if(Px(c)&&i)return i(c,r);
21if(jN(c)){if(o||a){const d=Gte(c);if(a?.length&&g0(d,a))return null;if(o){const f=o(d);f?c=Rm(n,Yte(f)):Cx()}if(c.spans){const f=[],p=c.spans;for(const v of p){if(a?.length&&g0(v,a)){Oee(p,v);continue}if(o){const w=o(v);w?f.push(w):(Cx(),f.push(v))}else f.push(v)}const m=c.spans.length-f.length;m&&e.recordDroppedEvent("before_send","span",m),c.spans=f}}if(s){if(c.spans){const d=c.spans.length;c.sdkProcessingMetadata={...n.sdkProcessingMetadata,spanCountBeforeProcessing:d}}return s(c,r)}}return c}function Px(e){return e.type===void 0}function jN(e){return e.type==="transaction"}function ene(e){let t=0;return e.name&&(t+=e.name.length*2),t+=8,t+FN(e.attributes)}function tne(e){let t=0;return e.message&&(t+=e.message.length*2),t+FN(e.attributes)}function FN(e){if(!e)return 0;let t=0;return Object.values(e).forEach(n=>{Array.isArray(n)?t+=n.length*PI(n[0]):qd(n)?t+=PI(n):t+=100}),t}function PI(e){return typeof e=="string"?e.length*2:typeof e=="number"?8:typeof e=="boolean"?4:0}function nne(e,t){t.debug===!0&&(Ze?Se.enable():mu(()=>{console.warn("[Sentry] Cannot initialize SDK with `debug` option using a non-debug bundle.")})),tn().update(t.initialScope);const r=new e(t);return rne(r),r.init(),r}function rne(e){tn().setClient(e)}const ine="thismessage:/";function Ik(e){return"isRelative"in e}function Mk(e,t){const n=e.indexOf("://")<=0&&e.indexOf("//")!==0,r=n?ine:void 0;try{if("canParse"in URL&&!URL.canParse(e,r))return;const i=new URL(e,r);return n?{isRelative:n,pathname:i.pathname,search:i.search,hash:i.hash}:i}catch{}}function sne(e){if(Ik(e))return e.pathname;const t=new URL(e);return t.search="",t.hash="",["80","443"].includes(t.port)&&(t.port=""),t.password&&(t.password="%filtered%"),t.username&&(t.username="%filtered%"),t.toString()}function Uc(e){if(!e)return{};const t=e.match(/^(([^:/?#]+):)?(\/\/([^/?#]*))?([^?#]*)(\?([^#]*))?(#(.*))?$/);if(!t)return{};const n=t[6]||"",r=t[8]||"";return{host:t[4],path:t[5],protocol:t[2],search:n,hash:r,relative:t[5]+n+r}}function one(e){return e.split(/[?#]/,1)[0]}function ane(e,t){const n=t?.getDsn(),r=t?.getOptions().tunnel;return cne(e,n)||lne(e,r)}function lne(e,t){return t?OI(e)===OI(t):!1}function cne(e,t){const n=Mk(e);return!n||Ik(n)?!1:t?n.host.includes(t.host)&&/(^|&|\?)sentry_key=/.test(n.search):!1}function OI(e){return e[e.length-1]==="/"?e.slice(0,-1):e}function une(e){"aggregates"in e?e.attrs?.ip_address===void 0&&(e.attrs={...e.attrs,ip_address:"{{auto}}"}):e.ipAddress===void 0&&(e.ipAddress="{{auto}}")}function UN(e,t,n=[t],r="npm"){const i=e._metadata||{};i.sdk||(i.sdk={name:`sentry.javascript.${t}`,packages:n.map(s=>({name:`${r}:@sentry/${s}`,version:$c})),version:$c}),e._metadata=i}function zN(e={}){const t=e.client||$t();if(!Tte()||!t)return{};const n=pu(),r=Ef(n);if(r.getTraceData)return r.getTraceData(e);const i=e.scope||tn(),s=e.span||Yr(),o=s?xee(s):dne(i),a=s?ra(s):mN(t,i),c=lee(a);if(!oN.test(o))return Se.warn("Invalid sentry-trace data. Cannot generate trace data"),{};const f={"sentry-trace":o,baggage:c};if(e.propagateTraceparent){const p=s?Cee(s):fne(i);p&&(f.traceparent=p)}return f}function dne(e){const{traceId:t,sampled:n,propagationSpanId:r}=e.getPropagationContext();return aN(t,r,n)}function fne(e){const{traceId:t,sampled:n,propagationSpanId:r}=e.getPropagationContext();return lN(t,r,n)}function hne(e,t,n){let r,i,s;const o=n?.maxWait?Math.max(n.maxWait,t):0,a=n?.setTimeoutImpl||setTimeout;function c(){return d(),r=e(),r}function d(){i!==void 0&&clearTimeout(i),s!==void 0&&clearTimeout(s),i=s=void 0}function f(){return i!==void 0||s!==void 0?c():r}function p(){return i&&clearTimeout(i),i=a(c,t),o&&s===void 0&&(s=a(c,o)),r}return p.cancel=d,p.flush=f,p}const pne=100;function Sl(e,t){const n=$t(),r=uo();if(!n)return;const{beforeBreadcrumb:i=null,maxBreadcrumbs:s=pne}=n.getOptions();if(s<=0)return;const a={timestamp:gu(),...e},c=i?mu(()=>i(a,t)):a;c!==null&&(n.emit&&n.emit("beforeAddBreadcrumb",c,t),r.addBreadcrumb(c,s))}let AI;const mne="FunctionToString",II=new WeakMap,gne=(()=>({name:mne,setupOnce(){AI=Function.prototype.toString;try{Function.prototype.toString=function(...e){const t=yk(this),n=II.has($t())&&t!==void 0?t:this;return AI.apply(n,e)}}catch{}},setup(e){II.set(e,!0)}})),yne=gne,vne=[/^Script error\.?$/,/^Javascript error: Script error\.? on line 0$/,/^ResizeObserver loop completed with undelivered notifications.$/,/^Cannot redefine property: googletag$/,/^Can't find variable: gmo$/,/^undefined is not an object \(evaluating 'a\.[A-Z]'\)$/,`can't redefine non-configurable property "solana"`,"vv().getRestrictions is not a function. (In 'vv().getRestrictions(1,a)', 'vv().getRestrictions' is undefined)","Can't find variable: _AutofillCallbackHandler",/^Non-Error promise rejection captured with value: Object Not Found Matching Id:\d+, MethodName:simulateEvent, ParamCount:\d+$/,/^Java exception was raised during method invocation$/],_ne="EventFilters",wne=(e={})=>{let t;return{name:_ne,setup(n){const r=n.getOptions();t=MI(e,r)},processEvent(n,r,i){if(!t){const s=i.getOptions();t=MI(e,s)}return Sne(n,t)?null:n}}},bne=((e={})=>({...wne(e),name:"InboundFilters"}));function MI(e={},t={}){return{allowUrls:[...e.allowUrls||[],...t.allowUrls||[]],denyUrls:[...e.denyUrls||[],...t.denyUrls||[]],ignoreErrors:[...e.ignoreErrors||[],...t.ignoreErrors||[],...e.disableErrorDefaults?[]:vne],ignoreTransactions:[...e.ignoreTransactions||[],...t.ignoreTransactions||[]]}}function Sne(e,t){if(e.type){if(e.type==="transaction"&&xne(e,t.ignoreTransactions))return Ze&&Se.warn(`Event dropped due to being matched by \`ignoreTransactions\` option. 22Event: ${kc(e)}`),!0}else{if(Ene(e,t.ignoreErrors))return Ze&&Se.warn(`Event dropped due to being matched by \`ignoreErrors\` option. 23Event: ${kc(e)}`),!0;if(Rne(e))return Ze&&Se.warn(`Event dropped due to not having an error message, error type or stacktrace. 24Event: ${kc(e)}`),!0;if(Cne(e,t.denyUrls))return Ze&&Se.warn(`Event dropped due to being matched by \`denyUrls\` option. 25Event: ${kc(e)}. 26Url: ${y0(e)}`),!0;if(!kne(e,t.allowUrls))return Ze&&Se.warn(`Event dropped due to not being matched by \`allowUrls\` option. 27Event: ${kc(e)}. 28Url: ${y0(e)}`),!0}return!1}function Ene(e,t){return t?.length?LN(e).some(n=>Vo(n,t)):!1}function xne(e,t){if(!t?.length)return!1;const n=e.transaction;return n?Vo(n,t):!1}function Cne(e,t){if(!t?.length)return!1;const n=y0(e);return n?Vo(n,t):!1}function kne(e,t){if(!t?.length)return!0;const n=y0(e);return n?Vo(n,t):!0}function Tne(e=[]){for(let t=e.length-1;t>=0;t--){const n=e[t];if(n&&n.filename!=="<anonymous>"&&n.filename!=="[native code]")return n.filename||null}return null}function y0(e){try{const n=[...e.exception?.values??[]].reverse().find(r=>r.mechanism?.parent_id===void 0&&r.stacktrace?.frames?.length)?.stacktrace?.frames;return n?Tne(n):null}catch{return Ze&&Se.error(`Cannot extract url for event ${kc(e)}`),null}}function Rne(e){return e.exception?.values?.length?!e.message&&!e.exception.values.some(t=>t.stacktrace||t.type&&t.type!=="Error"||t.value):!1}function Pne(e,t,n,r,i,s){if(!i.exception?.values||!s||!ea(s.originalException,Error))return;const o=i.exception.values.length>0?i.exception.values[i.exception.values.length-1]:void 0;o&&(i.exception.values=Ox(e,t,r,s.originalException,n,i.exception.values,o,0))}function Ox(e,t,n,r,i,s,o,a){if(s.length>=n+1)return s;let c=[...s];if(ea(r[i],Error)){DI(o,a);const d=e(t,r[i]),f=c.length;LI(d,i,f,a),c=Ox(e,t,n,r[i],i,[d,...c],d,f)}
28return Array.isArray(r.errors)&&r.errors.forEach((d,f)=>{if(ea(d,Error)){DI(o,a);const p=e(t,d),m=c.length;LI(p,`errors[${f}]`,m,a),c=Ox(e,t,n,d,i,[p,...c],p,m)}}),c}function DI(e,t){e.mechanism={handled:!0,type:"auto.core.linked_errors",...e.mechanism,...e.type==="AggregateError"&&{is_exception_group:!0},exception_id:t}}function LI(e,t,n,r){e.mechanism={handled:!0,...e.mechanism,type:"chained",source:t,exception_id:n,parent_id:r}}function One(e){const t="console";Il(t,e),Ml(t,Ane)}function Ane(){"console"in zt&&_Q.forEach(function(e){e in zt.console&&li(zt.console,e,function(t){return h0[e]=t,function(...n){Zi("console",{args:n,level:e}),h0[e]?.apply(zt.console,n)}})})}function BN(e){return e==="warn"?"warning":["fatal","error","warning","log","info","debug"].includes(e)?e:"log"}const Ine="Dedupe",Mne=(()=>{let e;return{name:Ine,processEvent(t){if(t.type)return t;try{if(Lne(t,e))return Ze&&Se.warn("Event dropped due to being a duplicate of previously captured event."),null}catch{}return e=t}}}),Dne=Mne;function Lne(e,t){return t?!!(Nne(e,t)||$ne(e,t)):!1}function Nne(e,t){const n=e.message,r=t.message;return!(!n&&!r||n&&!r||!n&&r||n!==r||!VN(e,t)||!HN(e,t))}function $ne(e,t){const n=NI(t),r=NI(e);return!(!n||!r||n.type!==r.type||n.value!==r.value||!VN(e,t)||!HN(e,t))}function HN(e,t){let n=qA(e),r=qA(t);if(!n&&!r)return!0;if(n&&!r||!n&&r||(n=n,r=r,r.length!==n.length))return!1;for(let i=0;i<r.length;i++){const s=r[i],o=n[i];if(s.filename!==o.filename||s.lineno!==o.lineno||s.colno!==o.colno||s.function!==o.function)return!1}return!0}function VN(e,t){let n=e.fingerprint,r=t.fingerprint;if(!n&&!r)return!0;if(n&&!r||!n&&r)return!1;n=n,r=r;try{return n.join("")===r.join("")}catch{return!1}}function NI(e){return e.exception?.values?.[0]}function jne(e,t,n,r,i){if(!e.fetchData)return;const{method:s,url:o}=e.fetchData,a=Cs()&&t(o);if(e.endTimestamp&&a){const v=e.fetchData.__span;if(!v)return;const w=r[v];w&&(zne(w,e),Fne(w,e,i),delete r[v]);return}const{spanOrigin:c="auto.http.browser",propagateTraceparent:d=!1}=typeof i=="object"?i:{spanOrigin:i},f=!!Yr(),p=a&&f?kf(Hne(o,s,c)):new bl;if(e.fetchData.__span=p.spanContext().spanId,r[p.spanContext().spanId]=p,n(e.fetchData.url)){const v=e.args[0],w=e.args[1]||{},_=Une(v,w,Cs()&&f?p:void 0,d);_&&(e.args[1]=w,w.headers=_)}const m=$t();if(m){const v={input:e.args,response:e.response,startTimestamp:e.startTimestamp,endTimestamp:e.endTimestamp};m.emit("beforeOutgoingRequestSpan",p,v)}return p}function Fne(e,t,n){(typeof n=="object"&&n!==null?n.onRequestSpanEnd:void 0)?.(e,{headers:t.response?.headers,error:t.error})}function Une(e,t,n,r){const i=zN({span:n,propagateTraceparent:r}),s=i["sentry-trace"],o=i.baggage,a=i.traceparent;if(!s)return;const c=t.headers||(G7(e)?e.headers:void 0);if(c)if(Bne(c)){const d=new Headers(c);if(d.get("sentry-trace")||d.set("sentry-trace",s),r&&a&&!d.get("traceparent")&&d.set("traceparent",a),o){const f=d.get("baggage");f?Ny(f)||d.set("baggage",`${f},${o}`):d.set("baggage",o)}return d}else if(Array.isArray(c)){const d=[...c];c.find(p=>p[0]==="sentry-trace")||d.push(["sentry-trace",s]),r&&a&&!c.find(p=>p[0]==="traceparent")&&d.push(["traceparent",a]);const f=c.find(p=>p[0]==="baggage"&&Ny(p[1]));return o&&!f&&d.push(["baggage",o]),d}else{const d="sentry-trace"in c?c["sentry-trace"]:void 0,f="traceparent"in c?c.traceparent:void 0,p="baggage"in c?c.baggage:void 0,m=p?Array.isArray(p)?[...p]:[p]:[],v=p&&(Array.isArray(p)?p.find(_=>Ny(_)):Ny(p));o&&!v&&m.push(o);const w={...c,"sentry-trace":d??s,baggage:m.length>0?m.join(","):void 0};return r&&a&&!f&&(w.traceparent=a),w}else return{...i}}function zne(e,t){if(t.response){tN(e,t.response.status);const n=t.response?.headers?.get("content-length");if(n){const r=parseInt(n);r>0&&e.setAttribute("http.response_content_length",r)}}else t.error&&e.setStatus({code:rr,message:"internal_error"});e.end()}function Ny(e){return e.split(",").some(t=>t.trim().startsWith(bk))}function Bne(e){return typeof Headers<"u"&&ea(e,Headers)}function Hne(e,t,n){const r=Mk(e);return{name:r?`${t} ${sne(r)}`:t,attributes:Vne(e,r,t,n)}}function Vne(e,t,n,r){const i={url:e,type:"fetch","http.method":n,[cr]:r,[na]:"http.client"};return t&&(Ik(t)||(i["http.url"]=t.href,i["server.address"]=t.host),t.search&&(i["http.query"]=t.search),t.hash&&(i["http.fragment"]=t.hash)),i}function WN(e){if(e!==void 0)return e>=400&&e<500?"warning":e>=500?"error":void 0}const Up=zt;function Wne(){return"history"in Up&&!!Up.history}
28function qne(){if(!("fetch"in Up))return!1;try{return new Headers,new Request("data:,"),new Response,!0}catch{return!1}}function Ax(e){return e&&/^function\s+\w+\(\)\s+\{\s+\[native code\]\s+\}$/.test(e.toString())}function Kne(){if(typeof EdgeRuntime=="string")return!0;if(!qne())return!1;if(Ax(Up.fetch))return!0;let e=!1;const t=Up.document;if(t&&typeof t.createElement=="function")try{const n=t.createElement("iframe");n.hidden=!0,t.head.appendChild(n),n.contentWindow?.fetch&&(e=Ax(n.contentWindow.fetch)),t.head.removeChild(n)}catch(n){Ze&&Se.warn("Could not create sandbox iframe for pure fetch check, bailing to window.fetch: ",n)}return e}function qN(e,t){const n="fetch";Il(n,e),Ml(n,()=>KN(void 0,t))}function Gne(e){const t="fetch-body-resolved";Il(t,e),Ml(t,()=>KN(Jne))}function KN(e,t=!1){t&&!Kne()||li(zt,"fetch",function(n){return function(...r){const i=new Error,{method:s,url:o}=Zne(r),a={args:r,fetchData:{method:s,url:o},startTimestamp:yr()*1e3,virtualError:i,headers:Xne(r)};return e||Zi("fetch",{...a}),n.apply(zt,r).then(async c=>(e?e(c):Zi("fetch",{...a,endTimestamp:yr()*1e3,response:c}),c),c=>{if(Zi("fetch",{...a,endTimestamp:yr()*1e3,error:c}),pk(c)&&c.stack===void 0&&(c.stack=i.stack,Pi(c,"framesToPop",1)),c instanceof TypeError&&(c.message==="Failed to fetch"||c.message==="Load failed"||c.message==="NetworkError when attempting to fetch resource."))try{const d=new URL(a.fetchData.url);c.message=`${c.message} (${d.host})`}catch{}throw c})}})}async function Yne(e,t){if(e?.body){const n=e.body,r=n.getReader(),i=setTimeout(()=>{n.cancel().then(null,()=>{})},90*1e3);let s=!0;for(;s;){let o;try{o=setTimeout(()=>{n.cancel().then(null,()=>{})},5e3);const{done:a}=await r.read();clearTimeout(o),a&&(t(),s=!1)}catch{s=!1}finally{clearTimeout(o)}}clearTimeout(i),r.releaseLock(),n.cancel().then(null,()=>{})}}function Jne(e){let t;try{t=e.clone()}catch{return}Yne(t,()=>{Zi("fetch-body-resolved",{endTimestamp:yr()*1e3,response:e})})}function Ix(e,t){return!!e&&typeof e=="object"&&!!e[t]}function $I(e){return typeof e=="string"?e:e?Ix(e,"url")?e.url:e.toString?e.toString():"":""}function Zne(e){if(e.length===0)return{method:"GET",url:""};if(e.length===2){const[n,r]=e;return{url:$I(n),method:Ix(r,"method")?String(r.method).toUpperCase():"GET"}}const t=e[0];return{url:$I(t),method:Ix(t,"method")?String(t.method).toUpperCase():"GET"}}function Xne(e){const[t,n]=e;try{if(typeof n=="object"&&n!==null&&"headers"in n&&n.headers)return new Headers(n.headers);if(G7(t))return new Headers(t.headers)}catch{}}function Qne(){return typeof __SENTRY_BROWSER_BUNDLE__<"u"&&!!__SENTRY_BROWSER_BUNDLE__}function ere(){return"npm"}function tre(){return!Qne()&&Object.prototype.toString.call(typeof process<"u"?process:0)==="[object process]"}function Mx(){return typeof window<"u"&&(!tre()||nre())}function nre(){return zt.process?.type==="renderer"}const qt=zt;let Dx=0;function GN(){return Dx>0}function rre(){Dx++,setTimeout(()=>{Dx--})}function Zd(e,t={}){function n(i){return typeof i=="function"}if(!n(e))return e;try{const i=e.__sentry_wrapped__;if(i)return typeof i=="function"?i:e;if(yk(e))return e}catch{return e}const r=function(...i){try{const s=i.map(o=>Zd(o,t));return e.apply(this,s)}catch(s){throw rre(),U_(o=>{o.addEventProcessor(a=>(t.mechanism&&(Sx(a,void 0),Kd(a,t.mechanism)),a.extra={...a.extra,arguments:i},a)),Rk(s)}),s}};try{for(const i in e)Object.prototype.hasOwnProperty.call(e,i)&&(r[i]=e[i])}catch{}J7(r,e),Pi(e,"__sentry_wrapped__",r);try{Object.getOwnPropertyDescriptor(r,"name").configurable&&Object.defineProperty(r,"name",{get(){return e.name}})}catch{}return r}function Dk(){const e=Sf(),{referrer:t}=qt.document||{},{userAgent:n}=qt.navigator||{},r={...t&&{Referer:t},...n&&{"User-Agent":n}};return{url:e,headers:r}}function Lk(e,t){const n=Nk(e,t),r={type:lre(t),value:cre(t)};return n.length&&(r.stacktrace={frames:n}),r.type===void 0&&r.value===""&&(r.value="Unrecoverable error caught"),r}function ire(e,t,n,r){const s=$t()?.getOptions().normalizeDepth,o=pre(t),a={__serialized__:gN(t,s)};if(o)return{exception:{values:[Lk(e,o)]},extra:a};const c={exception:{values:[{type:F_(t)?t.constructor.name:r?"UnhandledRejection":"Error",value:fre(t,{isUnhandledRejection:r})}]},extra:a};if(n){const d=Nk(e,n);d.length&&(c.exception.values[0].stacktrace={frames:d})}return c}function Zb(e,t){return{exception:{values:[Lk(e,t)]}}}function Nk(e,t){const n=t.stacktrace||t.stack||"",r=ore(t),i=are(t);try{return e(n,r,i)}catch{}return[]}const sre=/Minified React error #\d+;/i;function ore(e){return e&&sre.test(e.message)?1:0}function are(e){return typeof e.framesToPop=="number"?e.framesToPop:0}function YN(e){return typeof WebAssembly<"u"&&typeof WebAssembly.Exception<"u"?e instanceof WebAssembly.Exception:!1}function lre(e){const t=e?.name;return!t&&YN(e)?e.message&&Array.isArray(e.message)&&e.message.length==2?e.message[0]:"WebAssembly.Exception":t}function cre(e){const t=e?.message;return YN(e)?Array.isArray(e.message)&&e.message.length==2?e.message[1]:"wasm exception":t?t.error&&typeof t.error.message=="string"?t.error.message:t:"No error message"}function ure(e,t,n,r){const i=n?.syntheticException||void 0,s=$k(e,t,i,r);return Kd(s),s.level="error",n?.event_id&&(s.event_id=n.event_id),B_(s)}function dre(e,t,n="info",r,i){const s=r?.syntheticException||void 0,o=Lx(e,t,s,i);return o.level=n,r?.event_id&&(o.event_id=r.event_id),B_(o)}function $k(e,t,n,r,i){let s;if(q7(t)&&t.error)return Zb(e,t.error);if(GA(t)||OQ(t)){const o=t;if("stack"in t)s=Zb(e,t);
28else{const a=o.name||(GA(o)?"DOMError":"DOMException"),c=o.message?`${a}: ${o.message}`:a;s=Lx(e,c,n,r),Sx(s,c)}return"code"in o&&(s.tags={...s.tags,"DOMException.code":`${o.code}`}),s}return pk(t)?Zb(e,t):$p(t)||F_(t)?(s=ire(e,t,n,i),Kd(s,{synthetic:!0}),s):(s=Lx(e,t,n,r),Sx(s,`${t}`),Kd(s,{synthetic:!0}),s)}function Lx(e,t,n,r){const i={};if(r&&n){const s=Nk(e,n);s.length&&(i.exception={values:[{value:t,stacktrace:{frames:s}}]}),Kd(i,{synthetic:!0})}if(mk(t)){const{__sentry_template_string__:s,__sentry_template_values__:o}=t;return i.logentry={message:s,params:o},i}return i.message=t,i}function fre(e,{isUnhandledRejection:t}){const n=NQ(e),r=t?"promise rejection":"exception";return q7(e)?`Event \`ErrorEvent\` captured as ${r} with message \`${e.message}\``:F_(e)?`Event \`${hre(e)}\` (type=${e.type}) captured as ${r}`:`Object captured as ${r} with keys: ${n}`}function hre(e){try{const t=Object.getPrototypeOf(e);return t?t.constructor.name:void 0}catch{}}function pre(e){for(const t in e)if(Object.prototype.hasOwnProperty.call(e,t)){const n=e[t];if(n instanceof Error)return n}}class mre extends Zte{constructor(t){const n=gre(t),r=qt.SENTRY_SDK_SOURCE||ere();UN(n,"browser",["browser"],r),n._metadata?.sdk&&(n._metadata.sdk.settings={infer_ip:n.sendDefaultPii?"auto":"never",...n._metadata.sdk.settings}),super(n);const{sendDefaultPii:i,sendClientReports:s,enableLogs:o,_experiments:a,enableMetrics:c}=this._options,d=c??a?.enableMetrics??!0;qt.document&&(s||o||d)&&qt.document.addEventListener("visibilitychange",()=>{qt.document.visibilityState==="hidden"&&(s&&this._flushOutcomes(),o&&RN(this),d&&ON(this))}),i&&this.on("beforeSendSession",une)}eventFromException(t,n){return ure(this._options.stackParser,t,n,this._options.attachStacktrace)}eventFromMessage(t,n="info",r){return dre(this._options.stackParser,t,n,r,this._options.attachStacktrace)}_prepareEvent(t,n,r,i){return t.platform=t.platform||"javascript",super._prepareEvent(t,n,r,i)}}function gre(e){return{release:typeof __SENTRY_RELEASE__=="string"?__SENTRY_RELEASE__:qt.SENTRY_RELEASE?.id,sendClientReports:!0,parentSpanIsAlwaysRootSpan:!0,...e}}const Zc=typeof __SENTRY_DEBUG__>"u"||__SENTRY_DEBUG__,wt=zt,yre=(e,t)=>e>t[1]?"poor":e>t[0]?"needs-improvement":"good",Am=(e,t,n,r)=>{let i,s;return o=>{t.value>=0&&(o||r)&&(s=t.value-(i??0),(s||i===void 0)&&(i=t.value,t.delta=s,t.rating=yre(t.value,n),e(t)))}},Im=(e=!0)=>{const t=wt.performance?.getEntriesByType?.("navigation")[0];if(!e||t&&t.responseStart>0&&t.responseStart<performance.now())return t},Tf=()=>Im()?.activationStart??0;function zc(e,t,n){wt.document&&wt.addEventListener(e,t,n)}function jk(e,t,n){wt.document&&wt.removeEventListener(e,t,n)}let Dd=-1;const JN=new Set,vre=()=>wt.document?.visibilityState==="hidden"&&!wt.document?.prerendering?0:1/0,Cv=e=>{if(_re(e)&&Dd>-1){if(e.type==="visibilitychange"||e.type==="pagehide")for(const t of JN)t();isFinite(Dd)||(Dd=e.type==="visibilitychange"?e.timeStamp:0,jk("prerenderingchange",Cv,!0))}},Mm=()=>{if(wt.document&&Dd<0){const e=Tf();Dd=(wt.document.prerendering?void 0:globalThis.performance.getEntriesByType("visibility-state").filter(n=>n.name==="hidden"&&n.startTime>e)[0]?.startTime)??vre(),zc("visibilitychange",Cv,!0),zc("pagehide",Cv,!0),zc("prerenderingchange",Cv,!0)}return{get firstHiddenTime(){return Dd},onHidden(e){JN.add(e)}}};function _re(e){return e.type==="pagehide"||wt.document?.visibilityState==="hidden"}const wre=()=>`v5-${Date.now()}-${Math.floor(Math.random()*(9e12-1))+1e12}`,Dm=(e,t=-1)=>{const n=Im();let r="navigate";return n&&(wt.document?.prerendering||Tf()>0?r="prerender":wt.document?.wasDiscarded?r="restore":n.type&&(r=n.type.replace(/_/g,"-"))),{name:e,value:t,rating:"good",delta:0,entries:[],id:wre(),navigationType:r}},Xb=new WeakMap;function Fk(e,t){return Xb.get(e)||Xb.set(e,new t),Xb.get(e)}class v0{constructor(){v0.prototype.__init.call(this),v0.prototype.__init2.call(this)}__init(){this._sessionValue=0}__init2(){this._sessionEntries=[]}_processEntry(t){if(t.hadRecentInput)return;const n=this._sessionEntries[0],r=this._sessionEntries[this._sessionEntries.length-1];this._sessionValue&&n&&r&&t.startTime-r.startTime<1e3&&t.startTime-n.startTime<5e3?(this._sessionValue+=t.value,this._sessionEntries.push(t)):(this._sessionValue=t.value,this._sessionEntries=[t]),this._onAfterProcessingUnexpectedShift?.(t)}}const Rf=(e,t,n={})=>{try{if(PerformanceObserver.supportedEntryTypes.includes(e)){const r=new PerformanceObserver(i=>{Promise.resolve().then(()=>{t(i.getEntries())})});return r.observe({type:e,buffered:!0,...n}),r}}catch{}},Uk=e=>{let t=!1;return()=>{t||(e(),t=!0)}},H_=e=>{wt.document?.prerendering?addEventListener("prerenderingchange",()=>e(),!0):e()},bre=[1800,3e3],Sre=(e,t={})=>{H_(()=>{const n=Mm(),r=Dm("FCP");let i;const o=Rf("paint",a=>{for(const c of a)c.name==="first-contentful-paint"&&(o.disconnect(),c.startTime<n.firstHiddenTime&&(r.value=Math.max(c.startTime-Tf(),0),r.entries.push(c),i(!0)))});o&&(i=Am(e,r,bre,t.reportAllChanges))})},Ere=[.1,.25],xre=(e,t={})=>{Sre(Uk(()=>{const n=Dm("CLS",0);let r;const i=Mm(),s=Fk(t,v0),o=c=>{for(const d of c)s._processEntry(d);s._sessionValue>
28n.value&&(n.value=s._sessionValue,n.entries=s._sessionEntries,r())},a=Rf("layout-shift",o);a&&(r=Am(e,n,Ere,t.reportAllChanges),i.onHidden(()=>{o(a.takeRecords()),r(!0)}),wt?.setTimeout?.(r))}))};let ZN=0,Qb=1/0,$y=0;const Cre=e=>{e.forEach(t=>{t.interactionId&&(Qb=Math.min(Qb,t.interactionId),$y=Math.max($y,t.interactionId),ZN=$y?($y-Qb)/7+1:0)})};let Nx;const XN=()=>Nx?ZN:performance.interactionCount||0,kre=()=>{"interactionCount"in performance||Nx||(Nx=Rf("event",Cre,{type:"event",buffered:!0,durationThreshold:0}))},eS=10;let QN=0;const Tre=()=>XN()-QN;class _0{constructor(){_0.prototype.__init.call(this),_0.prototype.__init2.call(this)}__init(){this._longestInteractionList=[]}__init2(){this._longestInteractionMap=new Map}_resetInteractions(){QN=XN(),this._longestInteractionList.length=0,this._longestInteractionMap.clear()}_estimateP98LongestInteraction(){const t=Math.min(this._longestInteractionList.length-1,Math.floor(Tre()/50));return this._longestInteractionList[t]}_processEntry(t){if(this._onBeforeProcessingEntry?.(t),!(t.interactionId||t.entryType==="first-input"))return;const n=this._longestInteractionList.at(-1);let r=this._longestInteractionMap.get(t.interactionId);if(r||this._longestInteractionList.length<eS||t.duration>n._latency){if(r?t.duration>r._latency?(r.entries=[t],r._latency=t.duration):t.duration===r._latency&&t.startTime===r.entries[0].startTime&&r.entries.push(t):(r={id:t.interactionId,entries:[t],_latency:t.duration},this._longestInteractionMap.set(r.id,r),this._longestInteractionList.push(r)),this._longestInteractionList.sort((i,s)=>s._latency-i._latency),this._longestInteractionList.length>eS){const i=this._longestInteractionList.splice(eS);for(const s of i)this._longestInteractionMap.delete(s.id)}this._onAfterProcessingINPCandidate?.(r)}}}const e9=e=>{const t=n=>{(n.type==="pagehide"||wt.document?.visibilityState==="hidden")&&e(n)};zc("visibilitychange",t,!0),zc("pagehide",t,!0)},t9=e=>{const t=wt.requestIdleCallback||wt.setTimeout;wt.document?.visibilityState==="hidden"?e():(e=Uk(e),zc("visibilitychange",e,{once:!0,capture:!0}),t(()=>{e(),jk("visibilitychange",e,{capture:!0})}),e9(e))},Rre=[200,500],Pre=40,Ore=(e,t={})=>{if(!(globalThis.PerformanceEventTiming&&"interactionId"in PerformanceEventTiming.prototype))return;const n=Mm();H_(()=>{kre();const r=Dm("INP");let i;const s=Fk(t,_0),o=c=>{t9(()=>{for(const f of c)s._processEntry(f);const d=s._estimateP98LongestInteraction();d&&d._latency!==r.value&&(r.value=d._latency,r.entries=d.entries,i())})},a=Rf("event",o,{durationThreshold:t.durationThreshold??Pre});i=Am(e,r,Rre,t.reportAllChanges),a&&(a.observe({type:"first-input",buffered:!0}),n.onHidden(()=>{o(a.takeRecords()),i(!0)}))})};class Are{_processEntry(t){this._onBeforeProcessingEntry?.(t)}}const Ire=[2500,4e3],Mre=(e,t={})=>{H_(()=>{const n=Mm(),r=Dm("LCP");let i;const s=Fk(t,Are),o=c=>{t.reportAllChanges||(c=c.slice(-1));for(const d of c)s._processEntry(d),d.startTime<n.firstHiddenTime&&(r.value=Math.max(d.startTime-Tf(),0),r.entries=[d],i())},a=Rf("largest-contentful-paint",o);if(a){i=Am(e,r,Ire,t.reportAllChanges);const c=Uk(()=>{o(a.takeRecords()),a.disconnect(),i(!0)}),d=f=>{f.isTrusted&&(t9(c),jk(f.type,d,{capture:!0}))};for(const f of["keydown","click","visibilitychange"])zc(f,d,{capture:!0})}})},Dre=[800,1800],$x=e=>{wt.document?.prerendering?H_(()=>$x(e)):wt.document?.readyState!=="complete"?addEventListener("load",()=>$x(e),!0):setTimeout(e)},Lre=(e,t={})=>{const n=Dm("TTFB"),r=Am(e,n,Dre,t.reportAllChanges);$x(()=>{const i=Im();i&&(n.value=Math.max(i.responseStart-Tf(),0),n.entries=[i],r(!0))})},yp={},w0={};let n9,r9,i9,s9;function zk(e,t=!1){return V_("cls",e,$re,n9,t)}function Bk(e,t=!1){return V_("lcp",e,jre,r9,t)}function Nre(e){return V_("ttfb",e,Fre,i9)}function o9(e){return V_("inp",e,Ure,s9)}function Xc(e,t){return a9(e,t),w0[e]||(zre(e),w0[e]=!0),l9(e,t)}function Lm(e,t){const n=yp[e];if(n?.length)for(const r of n)try{r(t)}catch(i){Zc&&Se.error(`Error while triggering instrumentation handler. 29Type: ${e} 30Name: ${Qo(r)} 31Error:`,i)}}function $re(){return xre(e=>{Lm("cls",{metric:e}),n9=e},{reportAllChanges:!0})}function jre(){return Mre(e=>{Lm("lcp",{metric:e}),r9=e},{reportAllChanges:!0})}function Fre(){return Lre(e=>{Lm("ttfb",{metric:e}),i9=e})}function Ure(){return Ore(e=>{Lm("inp",{metric:e}),s9=e})}function V_(e,t,n,r,i=!1){a9(e,t);let s;return w0[e]||(s=n(),w0[e]=!0),r&&t({metric:r}),l9(e,t,i?s:void 0)}function zre(e){const t={};e==="event"&&(t.durationThreshold=0),Rf(e,n=>{Lm(e,{entries:n})},t)}function a9(e,t){yp[e]=yp[e]||[],yp[e].push(t)}function l9(e,t,n){return()=>{n&&n();const r=yp[e];if(!r)return;const i=r.indexOf(t);i!==-1&&r.splice(i,1)}}function Bre(e){return"duration"in e}function tS(e){return typeof e=="number"&&isFinite(e)}function El(e,t,n,{...r}){const i=Wt(e).start_timestamp;return i&&i>t&&typeof e.updateStartTime=="function"&&e.updateStartTime(t),Ck(e,()=>{const s=kf({startTime:t,...r});return s&&s.end(n),s})}function Hk(e){const t=$t();if(!t)return;const{name:n,transaction:r,attributes:i,startTime:s}=e,{release:o,environment:a,sendDefaultPii:c}=t.getOptions(),f=t.getIntegrationByName("Replay")?.getReplayId(),p=tn(),m=p.getUser(),v=m!==void 0?m.email||m.id||m.ip_address:void 0;let w;try{w=p.getScopeData().contexts.profile.profile_id}catch{}const _={release:o,environment:a,user:v||void 0,profile_id:w||void 0,replay_id:f||void 0,transaction:r,"user_agent.original":wt.navigator?.userAgent,"client.address":c?"{{auto}}":void 0,...i};return kf({name:n,attributes:_,startTime:s,experimental:{standalone:!0}})}function Nm(){return wt.addEventListener&&wt.performance}function Mn(e){return e/1e3}function Hre(e){let t="unknown",n="unknown",r="";for(const i of e){if(i==="/"){[t,n]=e.split("/");break}if(!isNaN(Number(i))){t=r==="h"?"http":r,n=e.split(r)[1];break}r+=i}
31return r===e&&(t=r),{name:t,version:n}}function c9(e){try{return PerformanceObserver.supportedEntryTypes.includes(e)}catch{return!1}}function u9(e,t){let n,r=!1;function i(a){!r&&n&&t(a,n),r=!0}e9(()=>{i("pagehide")});const s=e.on("beforeStartNavigationSpan",(a,c)=>{c?.isRedirect||(i("navigation"),s(),o())}),o=e.on("afterStartPageLoadSpan",a=>{n=a.spanContext().spanId,o()})}function Vre(e){let t=0,n;if(!c9("layout-shift"))return;const r=zk(({metric:i})=>{const s=i.entries[i.entries.length-1];s&&(t=i.value,n=s)},!0);u9(e,(i,s)=>{Wre(t,n,s,i),r()})}function Wre(e,t,n,r){Zc&&Se.log(`Sending CLS span (${e})`);const i=t?Mn((pi()||0)+t.startTime):yr(),s=tn().getScopeData().transactionName,o=t?hi(t.sources[0]?.node):"Layout shift",a={[cr]:"auto.http.browser.cls",[na]:"ui.webvital.cls",[xf]:0,"sentry.pageload.span_id":n,"sentry.report_event":r};t?.sources&&t.sources.forEach((d,f)=>{a[`cls.source.${f+1}`]=hi(d.node)});const c=Hk({name:o,transaction:s,attributes:a,startTime:i});c&&(c.addEvent("cls",{[Pm]:"",[Om]:e}),c.end(i))}function qre(e){let t=0,n;if(!c9("largest-contentful-paint"))return;const r=Bk(({metric:i})=>{const s=i.entries[i.entries.length-1];s&&(t=i.value,n=s)},!0);u9(e,(i,s)=>{Kre(t,n,s,i),r()})}function Kre(e,t,n,r){Zc&&Se.log(`Sending LCP span (${e})`);const i=Mn((pi()||0)+(t?.startTime||0)),s=tn().getScopeData().transactionName,o=t?hi(t.element):"Largest contentful paint",a={[cr]:"auto.http.browser.lcp",[na]:"ui.webvital.lcp",[xf]:0,"sentry.pageload.span_id":n,"sentry.report_event":r};t&&(t.element&&(a["lcp.element"]=hi(t.element)),t.id&&(a["lcp.id"]=t.id),t.url&&(a["lcp.url"]=t.url),t.loadTime!=null&&(a["lcp.loadTime"]=t.loadTime),t.renderTime!=null&&(a["lcp.renderTime"]=t.renderTime),t.size!=null&&(a["lcp.size"]=t.size));const c=Hk({name:o,transaction:s,attributes:a,startTime:i});c&&(c.addEvent("lcp",{[Pm]:"millisecond",[Om]:e}),c.end(i))}function Hi(e){return e&&((pi()||performance.timeOrigin)+e)/1e3}function d9(e){const t={};if(e.nextHopProtocol!=null){const{name:n,version:r}=Hre(e.nextHopProtocol);t["network.protocol.version"]=r,t["network.protocol.name"]=n}return pi()||Nm()?.timeOrigin?Gre({...t,"http.request.redirect_start":Hi(e.redirectStart),"http.request.redirect_end":Hi(e.redirectEnd),"http.request.worker_start":Hi(e.workerStart),"http.request.fetch_start":Hi(e.fetchStart),"http.request.domain_lookup_start":Hi(e.domainLookupStart),"http.request.domain_lookup_end":Hi(e.domainLookupEnd),"http.request.connect_start":Hi(e.connectStart),"http.request.secure_connection_start":Hi(e.secureConnectionStart),"http.request.connection_end":Hi(e.connectEnd),"http.request.request_start":Hi(e.requestStart),"http.request.response_start":Hi(e.responseStart),"http.request.response_end":Hi(e.responseEnd),"http.request.time_to_first_byte":e.responseStart!=null?e.responseStart/1e3:void 0}):t}function Gre(e){return Object.fromEntries(Object.entries(e).filter(([,t])=>t!=null))}const Yre=2147483647;let jI=0,_s={},si,b0;function Jre({recordClsStandaloneSpans:e,recordLcpStandaloneSpans:t,client:n}){const r=Nm();if(r&&pi()){r.mark&&wt.performance.mark("sentry-tracing-init");const i=t?qre(n):tie(),s=nie(),o=e?Vre(n):eie();return()=>{i?.(),s(),o?.()}}return()=>{}}function Zre(){Xc("longtask",({entries:e})=>{const t=Yr();if(!t)return;const{op:n,start_timestamp:r}=Wt(t);for(const i of e){const s=Mn(pi()+i.startTime),o=Mn(i.duration);n==="navigation"&&r&&s<r||El(t,s,s+o,{name:"Main UI thread blocked",op:"ui.long-task",attributes:{[cr]:"auto.ui.browser.metrics"}})}})}function Xre(){new PerformanceObserver(t=>{const n=Yr();if(n)for(const r of t.getEntries()){if(!r.scripts[0])continue;const i=Mn(pi()+r.startTime),{start_timestamp:s,op:o}=Wt(n);if(o==="navigation"&&s&&i<s)continue;const a=Mn(r.duration),c={[cr]:"auto.ui.browser.metrics"},d=r.scripts[0],{invoker:f,invokerType:p,sourceURL:m,sourceFunctionName:v,sourceCharPosition:w}=d;c["browser.script.invoker"]=f,c["browser.script.invoker_type"]=p,m&&(c["code.filepath"]=m),v&&(c["code.function"]=v),w!==-1&&(c["browser.script.source_char_position"]=w),El(n,i,i+a,{name:"Main UI thread blocked",op:"ui.long-animation-frame",attributes:c})}}).observe({type:"long-animation-frame",buffered:!0})}function Qre(){Xc("event",({entries:e})=>{const t=Yr();if(t){for(const n of e)if(n.name==="click"){const r=Mn(pi()+n.startTime),i=Mn(n.duration),s={name:hi(n.target),op:`ui.interaction.${n.name}`,startTime:r,attributes:{[cr]:"auto.ui.browser.metrics"}},o=Y7(n.target);o&&(s.attributes["ui.component_name"]=o),El(t,r,r+i,s)}}})}function eie(){return zk(({metric:e})=>{const t=e.entries[e.entries.length-1];t&&(_s.cls={value:e.value,unit:""},b0=t)},!0)}function tie(){return Bk(({metric:e})=>{const t=e.entries[e.entries.length-1];t&&(_s.lcp={value:e.value,unit:"millisecond"},si=t)},!0)}function nie(){return Nre(({metric:e})=>{e.entries[e.entries.length-1]&&(_s.ttfb={value:e.value,unit:"millisecond"})})}function rie(e,t){const n=Nm(),r=pi();if(!n?.getEntries||!r)return;const i=Mn(r),s=n.getEntries(),{op:o,start_timestamp:a}=Wt(e);
31s.slice(jI).forEach(c=>{const d=Mn(c.startTime),f=Mn(Math.max(0,c.duration));if(!(o==="navigation"&&a&&i+d<a))switch(c.entryType){case"navigation":{aie(e,c,i);break}case"mark":case"paint":case"measure":{sie(e,c,d,f,i,t.ignorePerformanceApiSpans);const p=Mm(),m=c.startTime<p.firstHiddenTime;c.name==="first-paint"&&m&&(_s.fp={value:c.startTime,unit:"millisecond"}),c.name==="first-contentful-paint"&&m&&(_s.fcp={value:c.startTime,unit:"millisecond"});break}case"resource":{uie(e,c,c.name,d,f,i,t.ignoreResourceSpans);break}}}),jI=Math.max(s.length-1,0),die(e),o==="pageload"&&(pie(_s),t.recordClsOnPageloadSpan||delete _s.cls,t.recordLcpOnPageloadSpan||delete _s.lcp,Object.entries(_s).forEach(([c,d])=>{Yee(c,d.value,d.unit)}),e.setAttribute("performance.timeOrigin",i),e.setAttribute("performance.activationStart",Tf()),fie(e,t)),si=void 0,b0=void 0,_s={}}function iie(e){if(e?.entryType==="measure")try{return e.detail.devtools.track==="Components ⚛"}catch{return}}function sie(e,t,n,r,i,s){if(iie(t)||["mark","measure"].includes(t.entryType)&&Vo(t.name,s))return;const o=Im(!1),a=Mn(o?o.requestStart:0),c=i+Math.max(n,a),d=i+n,f=d+r,p={[cr]:"auto.resource.browser.metrics"};c!==d&&(p["sentry.browser.measure_happened_before_request"]=!0,p["sentry.browser.measure_start_time"]=c),oie(p,t),c<=f&&El(e,c,f,{name:t.name,op:t.entryType,attributes:p})}function oie(e,t){try{const n=t.detail;if(!n)return;if(typeof n=="object"){for(const[r,i]of Object.entries(n))if(i&&qd(i))e[`sentry.browser.measure.detail.${r}`]=i;else if(i!==void 0)try{e[`sentry.browser.measure.detail.${r}`]=JSON.stringify(i)}catch{}return}if(qd(n)){e["sentry.browser.measure.detail"]=n;return}try{e["sentry.browser.measure.detail"]=JSON.stringify(n)}catch{}}catch{}}function aie(e,t,n){["unloadEvent","redirect","domContentLoadedEvent","loadEvent","connect"].forEach(r=>{jy(e,t,r,n)}),jy(e,t,"secureConnection",n,"TLS/SSL"),jy(e,t,"fetch",n,"cache"),jy(e,t,"domainLookup",n,"DNS"),cie(e,t,n)}function jy(e,t,n,r,i=n){const s=lie(n),o=t[s],a=t[`${n}Start`];!a||!o||El(e,r+Mn(a),r+Mn(o),{op:`browser.${i}`,name:t.name,attributes:{[cr]:"auto.ui.browser.metrics",...n==="redirect"&&t.redirectCount!=null?{"http.redirect_count":t.redirectCount}:{}}})}function lie(e){return e==="secureConnection"?"connectEnd":e==="fetch"?"domainLookupStart":`${e}End`}function cie(e,t,n){const r=n+Mn(t.requestStart),i=n+Mn(t.responseEnd),s=n+Mn(t.responseStart);t.responseEnd&&(El(e,r,i,{op:"browser.request",name:t.name,attributes:{[cr]:"auto.ui.browser.metrics"}}),El(e,s,i,{op:"browser.response",name:t.name,attributes:{[cr]:"auto.ui.browser.metrics"}}))}function uie(e,t,n,r,i,s,o){if(t.initiatorType==="xmlhttprequest"||t.initiatorType==="fetch")return;const a=t.initiatorType?`resource.${t.initiatorType}`:"resource.other";if(o?.includes(a))return;const c={[cr]:"auto.resource.browser.metrics"},d=Uc(n);d.protocol&&(c["url.scheme"]=d.protocol.split(":").pop()),d.host&&(c["server.address"]=d.host),c["url.same_origin"]=n.includes(wt.location.origin),hie(t,c,[["responseStatus","http.response.status_code"],["transferSize","http.response_transfer_size"],["encodedBodySize","http.response_content_length"],["decodedBodySize","http.decoded_response_content_length"],["renderBlockingStatus","resource.render_blocking_status"],["deliveryType","http.response_delivery_type"]]);const f={...c,...d9(t)},p=s+r,m=p+i;El(e,p,m,{name:n.replace(wt.location.origin,""),op:a,attributes:f})}function die(e){const t=wt.navigator;if(!t)return;const n=t.connection;n&&(n.effectiveType&&e.setAttribute("effectiveConnectionType",n.effectiveType),n.type&&e.setAttribute("connectionType",n.type),tS(n.rtt)&&(_s["connection.rtt"]={value:n.rtt,unit:"millisecond"})),tS(t.deviceMemory)&&e.setAttribute("deviceMemory",`${t.deviceMemory} GB`),tS(t.hardwareConcurrency)&&e.setAttribute("hardwareConcurrency",String(t.hardwareConcurrency))}function fie(e,t){si&&t.recordLcpOnPageloadSpan&&(si.element&&e.setAttribute("lcp.element",hi(si.element)),si.id&&e.setAttribute("lcp.id",si.id),si.url&&e.setAttribute("lcp.url",si.url.trim().slice(0,200)),si.loadTime!=null&&e.setAttribute("lcp.loadTime",si.loadTime),si.renderTime!=null&&e.setAttribute("lcp.renderTime",si.renderTime),e.setAttribute("lcp.size",si.size)),b0?.sources&&t.recordClsOnPageloadSpan&&b0.sources.forEac
31h((n,r)=>e.setAttribute(`cls.source.${r+1}`,hi(n.node)))}function hie(e,t,n){n.forEach(([r,i])=>{const s=e[r];s!=null&&(typeof s=="number"&&s<Yre||typeof s=="string")&&(t[i]=s)})}function pie(e){const t=Im(!1);if(!t)return;const{responseStart:n,requestStart:r}=t;r<=n&&(e["ttfb.requestTime"]={value:n-r,unit:"millisecond"})}function mie(){return Nm()&&pi()?Xc("element",gie):()=>{}}const gie=({entries:e})=>{const t=Yr(),n=t?Lr(t):void 0,r=n?Wt(n).description:tn().getScopeData().transactionName;e.forEach(i=>{const s=i;if(!s.identifier)return;const o=s.name,a=s.renderTime,c=s.loadTime,[d,f]=c?[Mn(c),"load-time"]:a?[Mn(a),"render-time"]:[yr(),"entry-emission"],p=o==="image-paint"?Mn(Math.max(0,(a??0)-(c??0))):0,m={[cr]:"auto.ui.browser.elementtiming",[na]:"ui.elementtiming",[Es]:"component","sentry.span_start_time_source":f,"sentry.transaction_name":r,"element.id":s.id,"element.type":s.element?.tagName?.toLowerCase()||"unknown","element.size":s.naturalWidth&&s.naturalHeight?`${s.naturalWidth}x${s.naturalHeight}`:void 0,"element.render_time":a,"element.load_time":c,"element.url":s.url||void 0,"element.identifier":s.identifier,"element.paint_type":o};tte({name:`element[${s.identifier}]`,attributes:m,startTime:d,onlyIfParent:!0},v=>{v.end(d+p)})})},yie=1e3;let FI,jx,Fx;function f9(e){Il("dom",e),Ml("dom",vie)}function vie(){if(!wt.document)return;const e=Zi.bind(null,"dom"),t=UI(e,!0);wt.document.addEventListener("click",t,!1),wt.document.addEventListener("keypress",t,!1),["EventTarget","Node"].forEach(n=>{const i=wt[n]?.prototype;i?.hasOwnProperty?.("addEventListener")&&(li(i,"addEventListener",function(s){return function(o,a,c){if(o==="click"||o=="keypress")try{const d=this.__sentry_instrumentation_handlers__=this.__sentry_instrumentation_handlers__||{},f=d[o]=d[o]||{refCount:0};if(!f.handler){const p=UI(e);f.handler=p,s.call(this,o,p,c)}f.refCount++}catch{}return s.call(this,o,a,c)}}),li(i,"removeEventListener",function(s){return function(o,a,c){if(o==="click"||o=="keypress")try{const d=this.__sentry_instrumentation_handlers__||{},f=d[o];f&&(f.refCount--,f.refCount<=0&&(s.call(this,o,f.handler,c),f.handler=void 0,delete d[o]),Object.keys(d).length===0&&delete this.__sentry_instrumentation_handlers__)}catch{}return s.call(this,o,a,c)}}))})}function _ie(e){if(e.type!==jx)return!1;try{if(!e.target||e.target._sentryId!==Fx)return!1}catch{}return!0}function wie(e,t){return e!=="keypress"?!1:t?.tagName?!(t.tagName==="INPUT"||t.tagName==="TEXTAREA"||t.isContentEditable):!0}function UI(e,t=!1){return n=>{if(!n||n._sentryCaptured)return;const r=bie(n);if(wie(n.type,r))return;Pi(n,"_sentryCaptured",!0),r&&!r._sentryId&&Pi(r,"_sentryId",Ri());
31const i=n.type==="keypress"?"input":n.type;_ie(n)||(e({event:n,name:i,global:t}),jx=n.type,Fx=r?r._sentryId:void 0),clearTimeout(FI),FI=wt.setTimeout(()=>{Fx=void 0,jx=void 0},yie)}}function bie(e){try{return e.target}catch{return null}}let Fy;function W_(e){const t="history";Il(t,e),Ml(t,Sie)}function Sie(){if(wt.addEventListener("popstate",()=>{const t=wt.location.href,n=Fy;if(Fy=t,n===t)return;Zi("history",{from:n,to:t})}),!Wne())return;function e(t){return function(...n){const r=n.length>2?n[2]:void 0;if(r){const i=Fy,s=Eie(String(r));if(Fy=s,i===s)return t.apply(this,n);Zi("history",{from:i,to:s})}return t.apply(this,n)}}li(wt.history,"pushState",e),li(wt.history,"replaceState",e)}function Eie(e){try{return new URL(e,wt.location.origin).toString()}catch{return e}}const kv={};function h9(e){const t=kv[e];if(t)return t;let n=wt[e];if(Ax(n))return kv[e]=n.bind(wt);const r=wt.document;if(r&&typeof r.createElement=="function")try{const i=r.createElement("iframe");i.hidden=!0,r.head.appendChild(i);const s=i.contentWindow;s?.[e]&&(n=s[e]),r.head.removeChild(i)}catch(i){Zc&&Se.warn(`Could not create sandbox iframe for ${e} check, bailing to window.${e}: `,i)}return n&&(kv[e]=n.bind(wt))}function xie(e){kv[e]=void 0}function $m(...e){return h9("setTimeout")(...e)}const Pc="__sentry_xhr_v3__";function p9(e){Il("xhr",e),Ml("xhr",Cie)}function Cie(){if(!wt.XMLHttpRequest)return;const e=XMLHttpRequest.prototype;e.open=new Proxy(e.open,{apply(t,n,r){const i=new Error,s=yr()*1e3,o=Ho(r[0])?r[0].toUpperCase():void 0,a=kie(r[1]);if(!o||!a)return t.apply(n,r);n[Pc]={method:o,url:a,request_headers:{}},o==="POST"&&a.match(/sentry_key/)&&(n.__sentry_own_request__=!0);const c=()=>{const d=n[Pc];if(d&&n.readyState===4){try{d.status_code=n.status}catch{}const f={endTimestamp:yr()*1e3,startTimestamp:s,xhr:n,virtualError:i};Zi("xhr",f)}};return"onreadystatechange"in n&&typeof n.onreadystatechange=="function"?n.onreadystatechange=new Proxy(n.onreadystatechange,{apply(d,f,p){return c(),d.apply(f,p)}}):n.addEventListener("readystatechange",c),n.setRequestHeader=new Proxy(n.setRequestHeader,{apply(d,f,p){const[m,v]=p,w=f[Pc];return w&&Ho(m)&&Ho(v)&&(w.request_headers[m.toLowerCase()]=v),d.apply(f,p)}}),t.apply(n,r)}}),e.send=new Proxy(e.send,{apply(t,n,r){const i=n[Pc];if(!i)return t.apply(n,r);r[0]!==void 0&&(i.body=r[0]);const s={startTimestamp:yr()*1e3,xhr:n};return Zi("xhr",s),t.apply(n,r)}})}function kie(e){if(Ho(e))return e;try{return e.toString()}catch{}}function m9(e){return new URLSearchParams(e).toString()}function g9(e,t=Se){try{if(typeof e=="string")return[e];if(e instanceof URLSearchParams)return[e.toString()];if(e instanceof FormData)return[m9(e)];if(!e)return[void 0]}catch(n){return Zc&&t.error(n,"Failed to serialize body",e),[void 0,"BODY_PARSE_ERROR"]}return Zc&&t.log("Skipping network body because of body type",e),[void 0,"UNPARSEABLE_BODY_TYPE"]}function y9(e=[]){if(!(e.length!==2||typeof e[1]!="object"))return e[1].body}function v9(e){let t;try{t=e.getAllResponseHeaders()}catch(n){return Zc&&Se.error(n,"Failed to get xhr response headers",e),{}}return t?t.split(`\r 32`).reduce((n,r)=>{const[i,s]=r.split(": ");return s&&(n[i.toLowerCase()]=s),n},{}):{}}const nS=[],Tv=new Map,Zu=new Map,Tie=60;function Rie(){if(Nm()&&pi()){const t=Pie();return()=>{t()}}return()=>{}}const Ux={click:"click",pointerdown:"click",pointerup:"click",mousedown:"click",mouseup:"click",touchstart:"click",touchend:"click",mouseover:"hover",mouseout:"hover",mouseenter:"hover",mouseleave:"hover",pointerover:"hover",pointerout:"hover",pointerenter:"hover",pointerleave:"hover",dragstart:"drag",dragend:"drag",drag:"drag",dragenter:"drag",dragleave:"drag",dragover:"drag",drop:"drag",keydown:"press",keyup:"press",keypress:"press",input:"press"};function Pie(){return o9(Oie)}const Oie=({metric:e})=>{if(e.value==null)return;const t=Mn(e.value);if(t>Tie)return;const n=e.entries.find(w=>w.duration===e.value&&Ux[w.name]);if(!n)return;const{interactionId:r}=n,i=Ux[n.name],s=Mn(pi()+n.startTime),o=Yr(),a=o?Lr(o):void 0,c=r!=null?Tv.get(r):void 0,d=c?.span||a,f=d?Wt(d).description:tn().getScopeData().transactionName,p=c?.elementName||hi(n.target),m={[cr]:"auto.http.browser.inp",[na]:`ui.interaction.${i}`,[xf]:n.duration},v=Hk({name:p,transaction:f,attributes:m,startTime:s});v&&(v.addEvent("inp",{[Pm]:"millisecond",[Om]:e.value}),v.end(s+t))};function Aie(){const e=Object.keys(Ux);Mx()&&e.forEach(i=>
32{wt.addEventListener(i,t,{capture:!0,passive:!0})});function t(i){const s=i.target;if(!s)return;const o=hi(s),a=Math.round(i.timeStamp);if(Zu.set(a,o),Zu.size>50){const c=Zu.keys().next().value;c!==void 0&&Zu.delete(c)}}function n(i){const s=Math.round(i.startTime);let o=Zu.get(s);if(!o)for(let a=-5;a<=5;a++){const c=Zu.get(s+a);if(c){o=c;break}}return o||"<unknown>"}const r=({entries:i})=>{const s=Yr(),o=s&&Lr(s);i.forEach(a=>{if(!Bre(a))return;const c=a.interactionId;if(c==null||Tv.has(c))return;const d=a.target?hi(a.target):n(a);if(nS.length>10){const f=nS.shift();Tv.delete(f)}nS.push(c),Tv.set(c,{span:o,elementName:d})})};Xc("event",r),Xc("first-input",r)}const Iie=40;function Mie(e,t=h9("fetch")){let n=0,r=0;async function i(s){const o=s.body.length;n+=o,r++;const a={body:s.body,method:"POST",referrerPolicy:"strict-origin",headers:e.headers,keepalive:n<=6e4&&r<15,...e.fetchOptions};try{const c=await t(e.url,a);return{statusCode:c.status,headers:{"x-sentry-rate-limits":c.headers.get("X-Sentry-Rate-Limits"),"retry-after":c.headers.get("Retry-After")}}}catch(c){throw xie("fetch"),c}finally{n-=o,r--}}return qte(e,i,Ak(e.bufferSize||Iie))}const rs=typeof __SENTRY_DEBUG__>"u"||__SENTRY_DEBUG__,Die=30,Lie=50;function zx(e,t,n,r){const i={filename:e,function:t==="<anonymous>"?Yc:t,in_app:!0};return n!==void 0&&(i.lineno=n),r!==void 0&&(i.colno=r),i}const Nie=/^\s*at (\S+?)(?::(\d+))(?::(\d+))\s*$/i,$ie=/^\s*at (?:(.+?\)(?: \[.+\])?|.*?) ?\((?:address at )?)?(?:async )?((?:<anonymous>|[-a-z]+:|.*bundle|\/)?.*?)(?::(\d+))?(?::(\d+))?\)?\s*$/i,jie=/\((\S*)(?::(\d+))(?::(\d+))\)/,Fie=/at (.+?) ?\(data:(.+?),/,Uie=e=>{const t=e.match(Fie);if(t)return{filename:`<data:${t[2]}>`,function:t[1]};const n=Nie.exec(e);if(n){const[,i,s,o]=n;return zx(i,Yc,+s,+o)}const r=$ie.exec(e);if(r){if(r[2]&&r[2].indexOf("eval")===0){const a=jie.exec(r[2]);a&&(r[2]=a[1],r[3]=a[2],r[4]=a[3])}const[s,o]=_9(r[1]||Yc,r[2]);return zx(o,s,r[3]?+r[3]:void 0,r[4]?+r[4]:void 0)}},zie=[Die,Uie],Bie=/^\s*(.*?)(?:\((.*?)\))?(?:^|@)?((?:[-a-z]+)?:\/.*?|\[native code\]|[^@]*(?:bundle|\d+\.js)|\/[\w\-. /=]+)(?::(\d+))?(?::(\d+))?\s*$/i,Hie=/(\S+) line (\d+)(?: > eval line \d+)* > eval/i,Vie=e=>{const t=Bie.exec(e);if(t){if(t[3]&&t[3].indexOf(" > eval")>-1){const s=Hie.exec(t[3]);s&&(t[1]=t[1]||"eval",t[3]=s[1],t[4]=s[2],t[5]="")}let r=t[3],i=t[1]||Yc;return[i,r]=_9(i,r),zx(r,i,t[4]?+t[4]:void 0,t[5]?+t[5]:void 0)}},Wie=[Lie,Vie],qie=[zie,Wie],Kie=z7(...qie),_9=(e,t)=>{const n=e.indexOf("safari-extension")!==-1,r=e.indexOf("safari-web-extension")!==-1;return n||r?[e.indexOf("@")!==-1?e.split("@")[0]:Yc,n?`safari-extension:${t}`:`safari-web-extension:${t}`]:[e,t]},Uy=1024,Gie="Breadcrumbs",Yie=((e={})=>{const t={console:!0,dom:!0,fetch:!0,history:!0,sentry:!0,xhr:!0,...e};return{name:Gie,setup(n){t.console&&One(Qie(n)),t.dom&&f9(Xie(n,t.dom)),t.xhr&&p9(ese(n)),t.fetch&&qN(tse(n)),t.history&&W_(nse(n)),t.sentry&&n.on("beforeSendEvent",Zie(n))}}}),Jie=Yie;function Zie(e){return function(n){$t()===e&&Sl({category:`sentry.${n.type==="transaction"?"transaction":"event"}`,event_id:n.event_id,level:n.level,message:kc(n)},{event:n})}}function Xie(e,t){return function(r){if($t()!==e)return;let i,s,o=typeof t=="object"?t.serializeAttribute:void 0,a=typeof t=="object"&&typeof t.maxStringLength=="number"?t.maxStringLength:void 0;a&&a>Uy&&(rs&&Se.warn(`\`dom.maxStringLength\` cannot exceed ${Uy}, but a value of ${a} was configured. Sentry will use ${Uy} instead.`),a=Uy),typeof o=="string"&&(o=[o]);try{const d=r.event,f=rse(d)?d.target:d;i=hi(f,{keyAttrs:o,maxStringLength:a}),s=Y7(f)}catch{i="<unknown>"}if(i.length===0)return;const c={category:`ui.${r.name}`,message:i};s&&(c.data={"ui.component_name":s}),Sl(c,{event:r.event,name:r.name,global:r.global})}}function Qie(e){return function(n){if($t()!==e)return;const r={category:"console",data:{arguments:n.args,logger:"console"},level:BN(n.level),message:ZA(n.args," ")};if(n.level==="assert")if(n.args[0]===!1)r.message=`Assertion failed: ${ZA(n.args.slice(1)," ")||"console.assert"}`,r.data.arguments=n.args.slice(1);else return;Sl(r,{input:n.args,level:n.level})}}function ese(e){return function(n){if($t()!==e)return;const{startTimestamp:r,endTimestamp:i}=n,s=n.xhr[Pc];if(!r||!i||!s)return;const{method:o,url:a,status_code:c,body:d}=s,f={method:o,url:a,status_code:c},p={xhr:n.xhr,input:d,startTimestamp:r,endTimestamp:i},m={category:"xhr",data:f,type:"http",level:WN(c)};e.emit("beforeOutgoingRequestBreadcrumb",m,p),Sl(m,p)}}function tse(e){return function(n){if($t()!==e)return;const{startTimestamp:r,endTimestamp:i}=n;
32if(i&&!(n.fetchData.url.match(/sentry_key/)&&n.fetchData.method==="POST"))if(n.fetchData.method,n.fetchData.url,n.error){const s=n.fetchData,o={data:n.error,input:n.args,startTimestamp:r,endTimestamp:i},a={category:"fetch",data:s,level:"error",type:"http"};e.emit("beforeOutgoingRequestBreadcrumb",a,o),Sl(a,o)}else{const s=n.response,o={...n.fetchData,status_code:s?.status};n.fetchData.request_body_size,n.fetchData.response_body_size,s?.status;const a={input:n.args,response:s,startTimestamp:r,endTimestamp:i},c={category:"fetch",data:o,type:"http",level:WN(o.status_code)};e.emit("beforeOutgoingRequestBreadcrumb",c,a),Sl(c,a)}}}function nse(e){return function(n){if($t()!==e)return;let r=n.from,i=n.to;const s=Uc(qt.location.href);let o=r?Uc(r):void 0;const a=Uc(i);o?.path||(o=s),s.protocol===a.protocol&&s.host===a.host&&(i=a.relative),s.protocol===o.protocol&&s.host===o.host&&(r=o.relative),Sl({category:"navigation",data:{from:r,to:i}})}}function rse(e){return!!e&&!!e.target}const ise=["EventTarget","Window","Node","ApplicationCache","AudioTrackList","BroadcastChannel","ChannelMergerNode","CryptoOperation","EventSource","FileReader","HTMLUnknownElement","IDBDatabase","IDBRequest","IDBTransaction","KeyOperation","MediaController","MessagePort","ModalWindow","Notification","SVGElementInstance","Screen","SharedWorker","TextTrack","TextTrackCue","TextTrackList","WebSocket","WebSocketWorker","Worker","XMLHttpRequest","XMLHttpRequestEventTarget","XMLHttpRequestUpload"],sse="BrowserApiErrors",ose=((e={})=>{const t={XMLHttpRequest:!0,eventTarget:!0,requestAnimationFrame:!0,setInterval:!0,setTimeout:!0,unregisterOriginalCallbacks:!1,...e};return{name:sse,setupOnce(){t.setTimeout&&li(qt,"setTimeout",zI),t.setInterval&&li(qt,"setInterval",zI),t.requestAnimationFrame&&li(qt,"requestAnimationFrame",lse),t.XMLHttpRequest&&"XMLHttpRequest"in qt&&li(XMLHttpRequest.prototype,"send",cse);const n=t.eventTarget;n&&(Array.isArray(n)?n:ise).forEach(i=>use(i,t))}}}),ase=ose;function zI(e){return function(...t){const n=t[0];return t[0]=Zd(n,{mechanism:{handled:!1,type:`auto.browser.browserapierrors.${Qo(e)}`}}),e.apply(this,t)}}function lse(e){return function(t){return e.apply(this,[Zd(t,{mechanism:{data:{handler:Qo(e)},handled:!1,type:"auto.browser.browserapierrors.requestAnimationFrame"}})])}}function cse(e){return function(...t){const n=this;return["onload","onerror","onprogress","onreadystatechange"].forEach(i=>{i in n&&typeof n[i]=="function"&&li(n,i,function(s){const o={mechanism:{data:{handler:Qo(s)},handled:!1,type:`auto.browser.browserapierrors.xhr.${i}`}},a=yk(s);return a&&(o.mechanism.data.handler=Qo(a)),Zd(s,o)})}),e.apply(this,t)}}function use(e,t){const r=qt[e]?.prototype;r?.hasOwnProperty?.("addEventListener")&&(li(r,"addEventListener",function(i){return function(s,o,a){try{dse(o)&&(o.handleEvent=Zd(o.handleEvent,{mechanism:{data:{handler:Qo(o),target:e},handled:!1,type:"auto.browser.browserapierrors.handleEvent"}}))}catch{}return t.unregisterOriginalCallbacks&&fse(this,s,o),i.apply(this,[s,Zd(o,{mechanism:{data:{handler:Qo(o),target:e},handled:!1,type:"auto.browser.browserapierrors.addEventListener"}}),a])}}),li(r,"removeEventListener",function(i){return function(s,o,a){try{const c=o.__sentry_wrapped__;c&&i.call(this,s,c,a)}catch{}return i.call(this,s,o,a)}}))}function dse(e){return typeof e.handleEvent=="function"}function fse(e,t,n){e&&typeof e=="object"&&"removeEventListener"in e&&typeof e.removeEventListener=="function"&&e.removeEventListener(t,n)}const hse=()=>({name:"BrowserSession",setupOnce(){if(typeof qt.document>"u"){rs&&Se.warn("Using the `browserSessionIntegration` in non-browser environments is not supported.");return}_I({ignoreDuration:!0}),wI(),W_(({from:e,to:t})=>{e!==void 0&&e!==t&&(_I({ignoreDuration:!0}),wI())})}}),pse="GlobalHandlers",mse=((e={})=>{const t={onerror:!0,onunhandledrejection:!0,...e};return{name:pse,setupOnce(){Error.stackTraceLimit=50},setup(n){t.onerror&&(yse(n),BI("onerror")),t.onunhandledrejection&&(vse(n),BI("onunhandledrejection"))}}}),gse=mse;function yse(e){H7(t=>{const{stackParser:n,attachStacktrace:r}=w9();if($t()!==e||GN())return;const{msg:i,url:s,line:o,column:a,error:c}=t,d=bse($k(n,c||i,void 0,r,!1),s,o,a);d.level="error",xN(d,{originalException:c,mechanism:{handled:!1,type:"auto.browser.global_handlers.onerror"}})})}function vse(e){V7(t=>{const{stackParser:n,attachStacktrace:r}=w9();if($t()!==e||GN())return;const i=_se(t),s=qd(i)?wse(i):$k(n,i,void 0,r,!0);s.level="error",xN(s,{originalException:i,mechanism:{handled:!1,type:"auto.browser.global_handlers.onunhandledrejection"}})})}function _se(e){if(qd(e))return e;try{if("reason"in e)return e.reason;if("detail"in e&&"reason"in e.detail)return e.detail.reason}catch{}return e}function wse(e){return{exception:{values:[{type:"UnhandledRejection",value:`Non-Error promise rejection captured with value: ${String(e)}`}]}}}function bse(e,t,n,r){const i=e.exception=e.exception||{},s=i.values=i.values||[],o=s[0]=s[0]||{},a=o.stacktrace=o.stacktrace||{},c=a.frames=a.frames||[],d=r,f=n,p=Sse(t)??Sf();
32return c.length===0&&c.push({colno:d,filename:p,function:Yc,in_app:!0,lineno:f}),e}function BI(e){rs&&Se.log(`Global Handler attached: ${e}`)}function w9(){return $t()?.getOptions()||{stackParser:()=>[],attachStacktrace:!1}}function Sse(e){if(!(!Ho(e)||e.length===0)){if(e.startsWith("data:")){const t=e.match(/^data:([^;]+)/),n=t?t[1]:"text/javascript",r=e.includes("base64,");return`<data:${n}${r?",base64":""}>`}return e}}const Ese=()=>({name:"HttpContext",preprocessEvent(e){if(!qt.navigator&&!qt.location&&!qt.document)return;const t=Dk(),n={...t.headers,...e.request?.headers};e.request={...t,...e.request,headers:n}}}),xse="cause",Cse=5,kse="LinkedErrors",Tse=((e={})=>{const t=e.limit||Cse,n=e.key||xse;return{name:kse,preprocessEvent(r,i,s){const o=s.getOptions();Pne(Lk,o.stackParser,n,t,r,i)}}}),Rse=Tse;function Pse(){return Ose()?(rs&&mu(()=>{console.error("[Sentry] You cannot use Sentry.init() in a browser extension, see: https://docs.sentry.io/platforms/javascript/best-practices/browser-extensions/")}),!0):!1}function Ose(){if(typeof qt.window>"u")return!1;const e=qt;if(e.nw||!(e.chrome||e.browser)?.runtime?.id)return!1;const n=Sf(),r=["chrome-extension","moz-extension","ms-browser-extension","safari-web-extension"];return!(qt===qt.top&&r.some(s=>n.startsWith(`${s}://`)))}function Ase(e){return[bne(),yne(),ase(),Jie(),gse(),Rse(),Dne(),Ese(),hse()]}function Ise(e={}){const t=!e.skipBrowserExtensionCheck&&Pse();let n=e.defaultIntegrations==null?Ase():e.defaultIntegrations;const r={...e,enabled:t?!1:e.enabled,stackParser:kQ(e.stackParser||Kie),integrations:Lte({integrations:e.integrations,defaultIntegrations:n}),transport:e.transport||Mie};return nne(mre,r)}const un=zt,Vk="sentryReplaySession",Mse="replay_event",Wk="Unable to send Replay",Dse=3e5,Lse=9e5,Nse=5e3,$se=5500,jse=6e4,Fse=5e3,Use=3,HI=15e4,zy=5e3,zse=3e3,Bse=300,qk=2e7,Hse=4999,Vse=5e4,VI=36e5;var Wse=Object.defineProperty,qse=(e,t,n)=>t in e?Wse(e,t,{enumerable:!0,configurable:!0,writable:!0,value:n}):e[t]=n,WI=(e,t,n)=>qse(e,typeof t!="symbol"?t+"":t,n),Gn=(e=>(e[e.Document=0]="Document",e[e.DocumentType=1]="DocumentType",e[e.Element=2]="Element",e[e.Text=3]="Text",e[e.CDATA=4]="CDATA",e[e.Comment=5]="Comment",e))(Gn||{});function Kse(e){return e.nodeType===e.ELEMENT_NODE}function vp(e){return e?.host?.shadowRoot===e}function _p(e){return Object.prototype.toString.call(e)==="[object ShadowRoot]"}function Gse(e){return e.includes(" background-clip: text;")&&!e.includes(" -webkit-background-clip: text;")&&(e=e.replace(/\sbackground-clip:\s*text;/g," -webkit-background-clip: text; background-clip: text;")),e}function Yse(e){const{cssText:t}=e;if(t.split('"').length<3)return t;const n=["@import",`url(${JSON.stringify(e.href)})`];return e.layerName===""?n.push("layer"):e.layerName&&n.push(`layer(${e.layerName})`),e.supportsText&&n.push(`supports(${e.supportsText})`),e.media.length&&n.push(e.media.mediaText),n.join(" ")+";"}function S0(e){try{const t=e.rules||e.cssRules;return t?Gse(Array.from(t,b9).join("")):null}catch{return null}}function Jse(e){let t="";for(let n=0;n<e.style.length;n++){const r=e.style,i=r[n],s=r.getPropertyPriority(i);t+=`${i}:${r.getPropertyValue(i)}${s?" !important":""};`}return`${e.selectorText} { ${t} }`}function b9(e){let t;if(Xse(e))try{t=S0(e.styleSheet)||Yse(e)}catch{}else if(Qse(e)){let n=e.cssText;const r=e.selectorText.includes(":"),i=typeof e.style.all=="string"&&e.style.all;if(i&&(n=Jse(e)),r&&(n=Zse(n)),r||i)return n}return t||e.cssText}function Zse(e){const t=/(\[(?:[\w-]+)[^\\])(:(?:[\w-]+)\])/gm;return e.replace(t,"$1\\$2")}function Xse(e){return"styleSheet"in e}function Qse(e){return"selectorText"in e}class S9{constructor(){WI(this,"idNodeMap",new Map),WI(this,"nodeMetaMap",new WeakMap)}getId(t){return t?this.getMeta(t)?.id??-1:-1}getNode(t){return this.idNodeMap.get(t)||null}getIds(){return Array.from(this.idNodeMap.keys())}getMeta(t){return this.nodeMetaMap.get(t)||null}removeNodeFromMap(t){const n=this.getId(t);this.idNodeMap.delete(n),t.childNodes&&t.childNodes.forEach(r=>this.removeNodeFromMap(r))}has(t){return this.idNodeMap.has(t)}hasNode(t){return this.nodeMetaMap.has(t)}add(t,n){const r=n.id;this.idNodeMap.set(r,t),this.nodeMetaMap.set(t,n)}replace(t,n){const r=this.getNode(t);if(r){const i=this.nodeMetaMap.get(r);i&&this.nodeMetaMap.set(n,i)}this.idNodeMap.set(t,n)}reset(){this.idNodeMap=new Map,this.nodeMetaMap=new WeakMap}}function eoe(){return new S9}function q_({maskInputOptions:e,tagName:t,type:n}
32){return t==="OPTION"&&(t="SELECT"),!!(e[t.toLowerCase()]||n&&e[n]||n==="password"||t==="INPUT"&&!n&&e.text)}function zp({isMasked:e,element:t,value:n,maskInputFn:r}){let i=n||"";return e?(r&&(i=r(i,t)),"*".repeat(i.length)):i}function Xd(e){return e.toLowerCase()}function Bx(e){return e.toUpperCase()}const qI="__rrweb_original__";function toe(e){const t=e.getContext("2d");if(!t)return!0;const n=50;for(let r=0;r<e.width;r+=n)for(let i=0;i<e.height;i+=n){const s=t.getImageData,o=qI in s?s[qI]:s;if(new Uint32Array(o.call(t,r,i,Math.min(n,e.width-r),Math.min(n,e.height-i)).data.buffer).some(c=>c!==0))return!1}return!0}function Kk(e){const t=e.type;return e.hasAttribute("data-rr-is-password")?"password":t?Xd(t):null}function E0(e,t,n){return t==="INPUT"&&(n==="radio"||n==="checkbox")?e.getAttribute("value")||"":e.value}function E9(e,t){let n;try{n=new URL(e,t??window.location.href)}catch{return null}const r=/\.([0-9a-z]+)(?:$)/i;return n.pathname.match(r)?.[1]??null}const KI={};function x9(e){const t=KI[e];if(t)return t;const n=window.document;let r=window[e];if(n&&typeof n.createElement=="function")try{const i=n.createElement("iframe");i.hidden=!0,n.head.appendChild(i);const s=i.contentWindow;s&&s[e]&&(r=s[e]),n.head.removeChild(i)}catch{}return KI[e]=r.bind(window)}function Hx(...e){return x9("setTimeout")(...e)}function C9(...e){return x9("clearTimeout")(...e)}function k9(e){try{return e.contentDocument}catch{}}let noe=1;const roe=new RegExp("[^a-z0-9-_:]"),Bp=-2;function Gk(){return noe++}function ioe(e){if(e instanceof HTMLFormElement)return"form";const t=Xd(e.tagName);return roe.test(t)?"div":t}function soe(e){let t="";return e.indexOf("//")>-1?t=e.split("/").slice(0,3).join("/"):t=e.split("/")[0],t=t.split("?")[0],t}let Xu,GI;const ooe=/url\((?:(')([^']*)'|(")(.*?)"|([^)]*))\)/gm,aoe=/^(?:[a-z+]+:)?\/\//i,loe=/^www\..*/i,coe=/^(data:)([^,]*),(.*)/i;function uoe(e,t){if(!e||t.size===0)return e;try{const n=e.split(";"),r=[];for(let i of n){if(i=i.trim(),!i)continue;const s=i.indexOf(":");if(s===-1){r.push(i);continue}const o=i.slice(0,s).trim();t.has(o)||r.push(i)}return r.join("; ")+(r.length>0&&e.endsWith(";")?";":"")}catch(n){return console.warn("Error filtering CSS properties:",n),e}}function x0(e,t){return(e||"").replace(ooe,(n,r,i,s,o,a)=>{const c=i||o||a,d=r||s||"";if(!c)return n;if(aoe.test(c)||loe.test(c))return`url(${d}${c}${d})`;if(coe.test(c))return`url(${d}${c}${d})`;if(c[0]==="/")return`url(${d}${soe(t)+c}${d})`;const f=t.split("/"),p=c.split("/");f.pop();for(const m of p)m!=="."&&(m===".."?f.pop():f.push(m));return`url(${d}${f.join("/")}${d})`})}const doe=/^[^ \t\n\r\u000c]+/,foe=/^[, \t\n\r\u000c]+/;function hoe(e,t){if(t.trim()==="")return t;let n=0;function r(s){let o;const a=s.exec(t.substring(n));return a?(o=a[0],n+=o.length,o):""}const i=[];for(;r(foe),!(n>=t.length);){let s=r(doe);if(s.slice(-1)===",")s=vd(e,s.substring(0,s.length-1)),i.push(s);else{let o="";s=vd(e,s);let a=!1;for(;;){const c=t.charAt(n);if(c===""){i.push((s+o).trim());break}else if(a)c===")"&&(a=!1);else if(c===","){n+=1,i.push((s+o).trim());break}else c==="("&&(a=!0);o+=c,n+=1}}}return i.join(", ")}const YI=new WeakMap;function vd(e,t){return!t||t.trim()===""?t:K_(e,t)}function poe(e){return!!(e.tagName==="svg"||e.ownerSVGElement)}function K_(e,t){let n=YI.get(e);if(n||(n=e.createElement("a"),YI.set(e,n)),!t)t="";else if(t.startsWith("blob:")||t.startsWith("data:"))return t;return n.setAttribute("href",t),n.href}function T9(e,t,n,r,i,s,o){if(!r)return r;if(n==="src"||n==="href"&&!(t==="use"&&r[0]==="#"))return vd(e,r);if(n==="xlink:href"&&r[0]!=="#")return vd(e,r);if(n==="background"&&(t==="table"||t==="td"||t==="th"))return vd(e,r);if(n==="srcset")return hoe(e,r);if(n==="style"){let a=x0(r,K_(e));return o&&o.size>0&&(a=uoe(a,o)),a}else if(t==="object"&&n==="data")return vd(e,r);return typeof s=="function"?s(n,r,i):r}function R9(e,t,n){return(e==="video"||e==="audio")&&t==="autoplay"}function moe(e,t,n,r){try{if(r&&e.matches(r))return!1;if(typeof t=="string"){if(e.classList.contains(t))return!0}else for(let i=e.classList.length;i--;){const s=e.classList[i];if(t.test(s))return!0}if(n)return e.matches(n)}catch{}return!1}function goe(e,t){for(let n=e.classList.length;n--;){const r=e.classList[n];if(t.test(r))return!0}return!1}function Oc(e,t,n=1/0,r=0){return!e||e.nodeType!==e.ELEMENT_NODE||r>n?-1:t(e)?r:Oc(e.parentNode,t,n,r+1)}function _d(e,t){return n=>{const r=n;if(r===null)return!1;try{if(e){if(typeof e=="string"){if(r.matches(`.${e}`))return!0}else if(goe(r,e))return!0}return!!(t&&r.matches(t))}catch{return!1}}}function Qd(e,t,n,r,i,s){try{const o=e.nodeType===e.ELEMENT_NODE?e:e.parentElement;if(o===null)return!1;if(o.tagName==="INPUT"){const d=o.getAttribute("autocomplete");if(["current-password","new-password","cc-number","cc-exp","cc-exp-month","cc-exp-year","cc-csc"].includes(d))return!0}let a=-1,c=-1;if(s){if(c=Oc(o,_d(r,i)),c<0)return!0;a=Oc(o,_d(t,n),c>=0?c:1/0)}else{if(a=Oc(o,_d(t,n)),a<0)return!1;c=Oc(o,_d(r,i),a>=0?a:1/0)}return a>=0?c>=0?a<=c:!0:c>=0?!1:!!s}catch{}return!!s}function yoe(e,t,n){const r=e.contentWindow;if(!r)return;let i=!1,s;try{s=r.document.readyState}catch{return}if(s!=="complete"){const a=Hx(()=>{i||(t(),i=!0)},n);e.addEventListener("load",()=>{C9(a),i=!0,t()});return}const o="about:blank";if(r.location.href!==o||e.src===o||e.src==="")return Hx(t,0),e.addEventListener("load",t);e.addEventListener("load",t)}function voe(e,t,n){let r=!1,i;try{i=e.sheet}catch{return}if(i)return;const s=Hx(()=>{r||(t(),r=!0)},n);e.addEventListener("load",()=>{C9(s),r=!0,t()})}function _oe(e,t){const{doc:n,mirror:r,blockClass:i,blockSelector:s,unblockSelector:o,maskAllText:a,maskAttributeFn:c,maskTextClass:d,unmaskTextClass:f,maskTextSelector:p,unmaskTextSelector:m,inlineStylesheet:v,maskInputOptions:w={},maskTextFn:_,maskInputFn:b,dataURLOptions:C={}
32,inlineImages:P,recordCanvas:D,keepIframeSrcFn:F,newlyAddedElement:R=!1,ignoreCSSAttributes:I}=t,k=woe(n,r);switch(e.nodeType){case e.DOCUMENT_NODE:return e.compatMode!=="CSS1Compat"?{type:Gn.Document,childNodes:[],compatMode:e.compatMode}:{type:Gn.Document,childNodes:[]};case e.DOCUMENT_TYPE_NODE:return{type:Gn.DocumentType,name:e.name,publicId:e.publicId,systemId:e.systemId,rootId:k};case e.ELEMENT_NODE:return Soe(e,{doc:n,blockClass:i,blockSelector:s,unblockSelector:o,inlineStylesheet:v,maskAttributeFn:c,maskInputOptions:w,maskInputFn:b,dataURLOptions:C,inlineImages:P,recordCanvas:D,keepIframeSrcFn:F,newlyAddedElement:R,rootId:k,maskTextClass:d,unmaskTextClass:f,maskTextSelector:p,unmaskTextSelector:m,ignoreCSSAttributes:I});case e.TEXT_NODE:return boe(e,{doc:n,maskAllText:a,maskTextClass:d,unmaskTextClass:f,maskTextSelector:p,unmaskTextSelector:m,maskTextFn:_,maskInputOptions:w,maskInputFn:b,rootId:k});case e.CDATA_SECTION_NODE:return{type:Gn.CDATA,textContent:"",rootId:k};case e.COMMENT_NODE:return{type:Gn.Comment,textContent:e.textContent||"",rootId:k};default:return!1}}function woe(e,t){if(!t.hasNode(e))return;const n=t.getId(e);return n===1?void 0:n}function boe(e,t){const{maskAllText:n,maskTextClass:r,unmaskTextClass:i,maskTextSelector:s,unmaskTextSelector:o,maskTextFn:a,maskInputOptions:c,maskInputFn:d,rootId:f}=t,p=e.parentNode&&e.parentNode.tagName;let m=e.textContent;const v=p==="STYLE"?!0:void 0,w=p==="SCRIPT"?!0:void 0,_=p==="TEXTAREA"?!0:void 0;if(v&&m){try{e.nextSibling||e.previousSibling||e.parentNode.sheet?.cssRules&&(m=S0(e.parentNode.sheet))}catch(C){console.warn(`Cannot get CSS styles from text's parentNode. Error: ${C}`,e)}m=x0(m,K_(t.doc))}w&&(m="SCRIPT_PLACEHOLDER");const b=Qd(e,r,s,i,o,n);if(!v&&!w&&!_&&m&&b&&(m=a?a(m,e.parentElement):m.replace(/[\S]/g,"*")),_&&m&&(c.textarea||b)&&(m=d?d(m,e.parentNode):m.replace(/[\S]/g,"*")),p==="OPTION"&&m){const C=q_({type:null,tagName:p,maskInputOptions:c});m=zp({isMasked:Qd(e,r,s,i,o,C),element:e,value:m,maskInputFn:d})}return{type:Gn.Text,textContent:m||"",isStyle:v,rootId:f}}function Soe(e,t){const{doc:n,blockClass:r,blockSelector:i,unblockSelector:s,inlineStylesheet:o,maskInputOptions:a={},maskAttributeFn:c,maskInputFn:d,dataURLOptions:f={},inlineImages:p,recordCanvas:m,keepIframeSrcFn:v,newlyAddedElement:w=!1,rootId:_,maskTextClass:b,unmaskTextClass:C,maskTextSelector:P,unmaskTextSelector:D,ignoreCSSAttributes:F}=t,R=moe(e,r,i,s),I=ioe(e);let k={};const L=e.attributes.length;for(let A=0;A<L;A++){const V=e.attributes[A];V.name&&!R9(I,V.name,V.value)&&(k[V.name]=T9(n,I,Xd(V.name),V.value,e,c,F))}if(I==="link"&&o){const A=Array.from(n.styleSheets).find(K=>K.href===e.href);let V=null;A&&(V=S0(A)),V&&(k.rel=null,k.href=null,k.crossorigin=null,k._cssText=x0(V,A.href))}if(I==="style"&&e.sheet&&!(e.innerText||e.textContent||"").trim().length){const A=S0(e.sheet);A&&(k._cssText=x0(A,K_(n)))}if(I==="input"||I==="textarea"||I==="select"||I==="option"){const A=e,V=Kk(A),K=E0(A,Bx(I),V),W=A.checked;if(V!=="submit"&&V!=="button"&&K){const U=Qd(A,b,P,C,D,q_({type:V,tagName:Bx(I),maskInputOptions:a}));k.value=zp({isMasked:U,element:A,value:K,maskInputFn:d})}W&&(k.checked=W)}if(I==="option"&&(e.selected&&!a.select?k.selected=!0:delete k.selected),I==="canvas"&&m){if(e.__context==="2d")toe(e)||(k.rr_dataURL=e.toDataURL(f.type,f.quality));else if(!("__context"in e)){const A=e.toDataURL(f.type,f.quality),V=n.createElement("canvas");V.width=e.width,V.height=e.height;const K=V.toDataURL(f.type,f.quality);A!==K&&(k.rr_dataURL=A)}}if(I==="img"&&p){Xu||(Xu=n.createElement("canvas"),GI=Xu.getContext("2d"));const A=e,V=A.currentSrc||A.getAttribute("src")||"<unknown-src>",K=A.crossOrigin,W=()=>{A.removeEventListener("load",W);try{Xu.width=A.naturalWidth,Xu.height=A.naturalHeight,GI.drawImage(A,0,0),k.rr_dataURL=Xu.toDataURL(f.type,f.quality)}catch(U){if(A.crossOrigin!=="anonymous"){A.crossOrigin="anonymous",A.complete&&A.naturalWidth!==0?W():A.addEventListener("load",W);return}else console.warn(`Cannot inline img src=${V}! Error: ${U}`)}A.crossOrigin==="anonymous"&&(K?k.crossOrigin=K:A.removeAttribute("crossorigin"))};
32A.complete&&A.naturalWidth!==0?W():A.addEventListener("load",W)}if((I==="audio"||I==="video")&&(k.rr_mediaState=e.paused?"paused":"played",k.rr_mediaCurrentTime=e.currentTime),w||(e.scrollLeft&&(k.rr_scrollLeft=e.scrollLeft),e.scrollTop&&(k.rr_scrollTop=e.scrollTop)),R){const{width:A,height:V}=e.getBoundingClientRect();k={class:k.class,rr_width:`${A}px`,rr_height:`${V}px`}}I==="iframe"&&!v(k.src)&&(!R&&!k9(e)&&(k.rr_src=k.src),delete k.src);let B;try{customElements.get(I)&&(B=!0)}catch{}return{type:Gn.Element,tagName:I,attributes:k,childNodes:[],isSVG:poe(e)||void 0,needBlock:R,rootId:_,isCustom:B}}function cn(e){return e==null?"":e.toLowerCase()}function Eoe(e,t){if(t.comment&&e.type===Gn.Comment)return!0;if(e.type===Gn.Element){if(t.script&&(e.tagName==="script"||e.tagName==="link"&&(e.attributes.rel==="preload"||e.attributes.rel==="modulepreload")||e.tagName==="link"&&e.attributes.rel==="prefetch"&&typeof e.attributes.href=="string"&&E9(e.attributes.href)==="js"))return!0;if(t.headFavicon&&(e.tagName==="link"&&e.attributes.rel==="shortcut icon"||e.tagName==="meta"&&(cn(e.attributes.name).match(/^msapplication-tile(image|color)$/)||cn(e.attributes.name)==="application-name"||cn(e.attributes.rel)==="icon"||cn(e.attributes.rel)==="apple-touch-icon"||cn(e.attributes.rel)==="shortcut icon")))return!0;if(e.tagName==="meta"){if(t.headMetaDescKeywords&&cn(e.attributes.name).match(/^description|keywords$/))return!0;if(t.headMetaSocial&&(cn(e.attributes.property).match(/^(og|twitter|fb):/)||cn(e.attributes.name).match(/^(og|twitter):/)||cn(e.attributes.name)==="pinterest"))return!0;if(t.headMetaRobots&&(cn(e.attributes.name)==="robots"||cn(e.attributes.name)==="googlebot"||cn(e.attributes.name)==="bingbot"))return!0;if(t.headMetaHttpEquiv&&e.attributes["http-equiv"]!==void 0)return!0;if(t.headMetaAuthorship&&(cn(e.attributes.name)==="author"||cn(e.attributes.name)==="generator"||cn(e.attributes.name)==="framework"||cn(e.attributes.name)==="publisher"||cn(e.attributes.name)==="progid"||cn(e.attributes.property).match(/^article:/)||cn(e.attributes.property).match(/^product:/)))return!0;if(t.headMetaVerification&&(cn(e.attributes.name)==="google-site-verification"||cn(e.attributes.name)==="yandex-verification"||cn(e.attributes.name)==="csrf-token"||cn(e.attributes.name)==="p:domain_verify"||cn(e.attributes.name)==="verify-v1"||cn(e.attributes.name)==="verification"||cn(e.attributes.name)==="shopify-checkout-api-token"))return!0}}return!1}function wd(e,t){const{doc:n,mirror:r,blockClass:i,blockSelector:s,unblockSelector:o,maskAllText:a,maskTextClass:c,unmaskTextClass:d,maskTextSelector:f,unmaskTextSelector:p,skipChild:m=!1,inlineStylesheet:v=!0,maskInputOptions:w={},maskAttributeFn:_,maskTextFn:b,maskInputFn:C,slimDOMOptions:P,dataURLOptions:D={},inlineImages:F=!1,recordCanvas:R=!1,onSerialize:I,onIframeLoad:k,iframeLoadTimeout:L=5e3,onBlockedImageLoad:B,onStylesheetLoad:A,stylesheetLoadTimeout:V=5e3,keepIframeSrcFn:K=()=>!1,newlyAddedElement:W=!1,ignoreCSSAttributes:U}=t;let{preserveWhiteSpace:q=!0}=t;const z=_oe(e,{doc:n,mirror:r,blockClass:i,blockSelector:s,maskAllText:a,unblockSelector:o,maskTextClass:c,unmaskTextClass:d,maskTextSelector:f,unmaskTextSelector:p,inlineStylesheet:v,maskInputOptions:w,maskAttributeFn:_,maskTextFn:b,maskInputFn:C,dataURLOptions:D,inlineImages:F,recordCanvas:R,keepIframeSrcFn:K,newlyAddedElement:W,ignoreCSSAttributes:U});if(!z)return console.warn(e,"not serialized"),null;let x;r.hasNode(e)?x=r.getId(e):Eoe(z,P)||!q&&z.type===Gn.Text&&!z.isStyle&&!z.textContent.replace(/^\s+|\s+$/gm,"").length?x=Bp:x=Gk();const N=Object.assign(z,{id:x});if(r.add(e,N),x===Bp)return null;I&&I(e);let M=!m;if(N.type===Gn.Element){M=M&&!N.needBlock;const E=e.shadowRoot;E&&_p(E)&&(N.isShadowHost=!0)}if((N.type===Gn.Document||N.type===Gn.Element)&&M){P.headWhitespace&&N.type===Gn.Element&&N.tagName==="head"&&(q=!1);const E={doc:n,mirror:r,blockClass:i,blockSelector:s,maskAllText:a,unblockSelector:o,maskTextClass:c,unmaskTextClass:d,maskTextSelector:f,unmaskTextSelector:p,skipChild:m,inlineStylesheet:v,maskInputOptions:w,maskAttributeFn:_,maskTextFn:b,maskInputFn:C,slimDOMOptions:P,dataURLOptions:D,inlineImages:F,recordCanvas:R,preserveWhiteSpace:q,onSerialize:I,onIframeLoad:k,iframeLoadTimeout:L,onBlockedImageLoad:B,onStylesheetLoad:A,stylesheetLoadTimeout:V,keepIframeSrcFn:K,ignoreCSSAttributes:U},O=e.childNodes?Array.from(e.childNodes):[];for(const H of O){const Z=wd(H,E);Z&&N.childNodes.push(Z)}if(Kse(e)&&e.shadowRoot)for(const H of Array.from(e.shadowRoot.childNodes)){const Z=wd(H,E);Z&&(_p(e.shadowRoot)&&(Z.isShadow=!0),N.childNodes.push(Z))}}if(e.parentNode&&vp(e.parentNode)&&_p(e.parentNode)&&(N.isShadow=!0),N.type===Gn.Element&&N.tagName==="iframe"&&!N.needBlock&&yoe(e,()=>{const E=k9(e);if(E&&k){const O=wd(E,{doc:E,mirror:r,blockClass:i,blockSelector:s,unblockSelector:o,maskAllText:a,maskTextClass:c,unmaskTextClass:d,maskTextSelector:f,unmaskTextSelector:p,skipChild:!1,inlineStylesheet:v,maskInputOptions:w,maskAttributeFn:_,maskTextFn:b,maskInputFn:C,slimDOMOptions:P,dataURLOptions:D,inlineImages:F,recordCanvas:R,preserveWhiteSpace:q,onSerialize:I,onIframeLoad:k,iframeLoadTimeout:L,onStylesheetLoad:A,stylesheetLoadTimeout:V,keepIframeSrcFn:K,ignoreCSSAttributes:U});O&&k(e,O)}},L),N.type===Gn.Element&&N.tagName==="img"&&!e.complete&&N.needBlock){const E=e,O=()=>{if(E.isConnected&&!E.complete&&B)try{const H=E.getBoundingClientRect();H.width>0&&H.height>0&&B(E,N,H)}catch{}E.removeEventListener("load",O)};E.isConnected&&E.addEventListener("load",O)}return N.type===Gn.Element&&N.tagName==="link"&&typeof N.attributes.rel=="string"&&(N.attributes.rel==="stylesheet"||N.attributes.rel==="preload"&&typeof N.attributes.href=="string"&&E9(N.attributes.href)==="css")&&voe(e,()=>{if(A){const E=wd(e,{doc:n,mirror:r,blockClass:i,blockSelector:s,unblockSelector:o,maskAllText:a,maskTextClass:c,unmaskTextClass:d,maskTextSelector:f,unmaskTextSelector:p,skipChild:!1,inlineStylesheet:v,maskInputOptions:w,maskAttributeFn:_,maskTextFn:b,maskInputFn:C,slimDOMOptions:P,dataURLOptions:D,inlineImages:F,recordCanvas:R,preserveWhiteSpace:q,onSerialize:I,onIframeLoad:k,iframeLoadTimeout:L,onStylesheetLoad:A,stylesheetLoadTimeout:V,keepIframeSrcFn:K,ignoreCSSAttributes:U});E&&A(e,E)}},V),N.type===Gn.Element&&delete N.needBlock,N}function xoe(e,t){const{mirror:n=new S9,blockClass:r="rr-block",blockSelector:i=null,unblockSelector:s=null,maskAllText:o=!1,maskTextClass:a="rr-mask",unmaskTextClass:c=null,maskTextSelector:d=null,unmaskTextSelector:f=null,inlineStylesheet:p=!0,inl
32ineImages:m=!1,recordCanvas:v=!1,maskAllInputs:w=!1,maskAttributeFn:_,maskTextFn:b,maskInputFn:C,slimDOM:P=!1,dataURLOptions:D,preserveWhiteSpace:F,onSerialize:R,onIframeLoad:I,iframeLoadTimeout:k,onBlockedImageLoad:L,onStylesheetLoad:B,stylesheetLoadTimeout:A,keepIframeSrcFn:V=()=>!1,ignoreCSSAttributes:K=new Set([])}=t||{};return wd(e,{doc:e,mirror:n,blockClass:r,blockSelector:i,unblockSelector:s,maskAllText:o,maskTextClass:a,unmaskTextClass:c,maskTextSelector:d,unmaskTextSelector:f,skipChild:!1,inlineStylesheet:p,maskInputOptions:w===!0?{color:!0,date:!0,"datetime-local":!0,email:!0,month:!0,number:!0,range:!0,search:!0,tel:!0,text:!0,time:!0,url:!0,week:!0,textarea:!0,select:!0}:w===!1?{}:w,maskAttributeFn:_,maskTextFn:b,maskInputFn:C,slimDOMOptions:P===!0||P==="all"?{script:!0,comment:!0,headFavicon:!0,headWhitespace:!0,headMetaDescKeywords:P==="all",headMetaSocial:!0,headMetaRobots:!0,headMetaHttpEquiv:!0,headMetaAuthorship:!0,headMetaVerification:!0}:P===!1?{}:P,dataURLOptions:D,inlineImages:m,recordCanvas:v,preserveWhiteSpace:F,onSerialize:R,onIframeLoad:I,iframeLoadTimeout:k,onBlockedImageLoad:L,onStylesheetLoad:B,stylesheetLoadTimeout:A,keepIframeSrcFn:V,newlyAddedElement:!1,ignoreCSSAttributes:K})}function Vr(e,t,n=document){const r={capture:!0,passive:!0};return n.addEventListener(e,t,r),()=>n.removeEventListener(e,t,r)}const ld=`Please stop import mirror directly. Instead of that,\r 33now you can use replayer.getMirror() to access the mirror instance of a replayer,\r 34or you can use record.mirror to access the mirror instance during recording.`;let JI={map:{},getId(){return console.error(ld),-1},getNode(){return console.error(ld),null},removeNodeFromMap(){console.error(ld)},has(){return console.error(ld),!1},reset(){console.error(ld)}};typeof window<"u"&&window.Proxy&&window.Reflect&&(JI=new Proxy(JI,{get(e,t,n){return t==="map"&&console.error(ld),Reflect.get(e,t,n)}}));function Hp(e,t,n={}){let r=null,i=0;return function(...s){const o=Date.now();!i&&n.leading===!1&&(i=o);const a=t-(o-i),c=this;a<=0||a>t?(r&&(Aoe(r),r=null),i=o,e.apply(c,s)):!r&&n.trailing!==!1&&(r=G_(()=>{i=n.leading===!1?0:Date.now(),r=null,e.apply(c,s)},a))}}function P9(e,t,n,r,i=window){const s=i.Object.getOwnPropertyDescriptor(e,t);return i.Object.defineProperty(e,t,r?n:{set(o){G_(()=>{n.set.call(this,o)},0),s&&s.set&&s.set.call(this,o)}}),()=>P9(e,t,s||{},!0)}function Yk(e,t,n){try{if(!(t in e))return()=>{};const r=e[t],i=n(r);return typeof i=="function"&&(i.prototype=i.prototype||{},Object.defineProperties(i,{__rrweb_original__:{enumerable:!1,value:r}})),e[t]=i,()=>{e[t]=r}}catch{return()=>{}}}let C0=Date.now;/[1-9][0-9]{12}/.test(Date.now().toString())||(C0=()=>new Date().getTime());function O9(e){const t=e.document;return{left:t.scrollingElement?t.scrollingElement.scrollLeft:e.pageXOffset!==void 0?e.pageXOffset:t?.documentElement.scrollLeft||t?.body?.parentElement?.scrollLeft||t?.body?.scrollLeft||0,top:t.scrollingElement?t.scrollingElement.scrollTop:e.pageYOffset!==void 0?e.pageYOffset:t?.documentElement.scrollTop||t?.body?.parentElement?.scrollTop||t?.body?.scrollTop||0}}function A9(){return window.innerHeight||document.documentElement&&document.documentElement.clientHeight||document.body&&document.body.clientHeight}function I9(){return window.innerWidth||document.documentElement&&document.documentElement.clientWidth||document.body&&document.body.clientWidth}function M9(e){if(!e)return null;try{return e.nodeType===e.ELEMENT_NODE?e:e.parentElement}catch{return null}}function bi(e,t,n,r,i){if(!e)return!1;const s=M9(e);if(!s)return!1;const o=_d(t,n);if(!i){const d=r&&s.matches(r);return o(s)&&!d}const a=Oc(s,o);let c=-1;return a<0?!1:(r&&(c=Oc(s,_d(null,r))),a>-1&&c<0?!0:a<c)}function Coe(e,t){return t.getId(e)!==-1}function rS(e,t){return t.getId(e)===Bp}function D9(e,t){if(vp(e))return!1;const n=t.getId(e);return t.has(n)?e.parentNode&&e.parentNode.nodeType===e.DOCUMENT_NODE?!1:e.parentNode?D9(e.parentNode,t):!0:!0}function Vx(e){return!!e.changedTouches}function koe(e=window){"NodeList"in e&&!e.NodeList.prototype.forEach&&(e.NodeList.prototype.forEach=Array.prototype.forEach),"DOMTokenList"in e&&!e.DOMTokenList.prototype.forEach&&(e.DOMTokenList.prototype.forEach=Array.prototype.forEach),Node.prototype.contains||(Node.prototype.contains=(...t)=>{let n=t[0];if(!(0 in t))throw new TypeError("1 argument is required");do if(this===n)return!0;while(n=n&&n.parentNode);return!1})}function L9(e,t){return!!(e.nodeName==="IFRAME"&&t.getMeta(e))}function N9(e,t){return!!(e.nodeName==="LINK"&&e.nodeType===e.ELEMENT_NODE&&e.getAttribute&&e.getAttribute("rel")==="stylesheet"&&t.getMeta(e))}
34function Wx(e){return!!e?.shadowRoot}class Toe{constructor(){this.id=1,this.styleIDMap=new WeakMap,this.idStyleMap=new Map}getId(t){return this.styleIDMap.get(t)??-1}has(t){return this.styleIDMap.has(t)}add(t,n){if(this.has(t))return this.getId(t);let r;return n===void 0?r=this.id++:r=n,this.styleIDMap.set(t,r),this.idStyleMap.set(r,t),r}getStyle(t){return this.idStyleMap.get(t)||null}reset(){this.styleIDMap=new WeakMap,this.idStyleMap=new Map,this.id=1}generateId(){return this.id++}}function $9(e){let t=null;return e.getRootNode?.()?.nodeType===Node.DOCUMENT_FRAGMENT_NODE&&e.getRootNode().host&&(t=e.getRootNode().host),t}function Roe(e){let t=e,n;for(;n=$9(t);)t=n;return t}function Poe(e){const t=e.ownerDocument;if(!t)return!1;const n=Roe(e);return t.contains(n)}function j9(e){const t=e.ownerDocument;return t?t.contains(e)||Poe(e):!1}const ZI={};function Jk(e){const t=ZI[e];if(t)return t;const n=window.document;let r=window[e];if(n&&typeof n.createElement=="function")try{const i=n.createElement("iframe");i.hidden=!0,n.head.appendChild(i);const s=i.contentWindow;s&&s[e]&&(r=s[e]),n.head.removeChild(i)}catch{}return ZI[e]=r.bind(window)}function Ooe(...e){return Jk("requestAnimationFrame")(...e)}function G_(...e){return Jk("setTimeout")(...e)}function Aoe(...e){return Jk("clearTimeout")(...e)}var xt=(e=>(e[e.DomContentLoaded=0]="DomContentLoaded",e[e.Load=1]="Load",e[e.FullSnapshot=2]="FullSnapshot",e[e.IncrementalSnapshot=3]="IncrementalSnapshot",e[e.Meta=4]="Meta",e[e.Custom=5]="Custom",e[e.Plugin=6]="Plugin",e))(xt||{}),vt=(e=>(e[e.Mutation=0]="Mutation",e[e.MouseMove=1]="MouseMove",e[e.MouseInteraction=2]="MouseInteraction",e[e.Scroll=3]="Scroll",e[e.ViewportResize=4]="ViewportResize",e[e.Input=5]="Input",e[e.TouchMove=6]="TouchMove",e[e.MediaInteraction=7]="MediaInteraction",e[e.StyleSheetRule=8]="StyleSheetRule",e[e.CanvasMutation=9]="CanvasMutation",e[e.Font=10]="Font",e[e.Log=11]="Log",e[e.Drag=12]="Drag",e[e.StyleDeclaration=13]="StyleDeclaration",e[e.Selection=14]="Selection",e[e.AdoptedStyleSheet=15]="AdoptedStyleSheet",e[e.CustomElement=16]="CustomElement",e))(vt||{}),zr=(e=>(e[e.MouseUp=0]="MouseUp",e[e.MouseDown=1]="MouseDown",e[e.Click=2]="Click",e[e.ContextMenu=3]="ContextMenu",e[e.DblClick=4]="DblClick",e[e.Focus=5]="Focus",e[e.Blur=6]="Blur",e[e.TouchStart=7]="TouchStart",e[e.TouchMove_Departed=8]="TouchMove_Departed",e[e.TouchEnd=9]="TouchEnd",e[e.TouchCancel=10]="TouchCancel",e))(zr||{}),Po=(e=>(e[e.Mouse=0]="Mouse",e[e.Pen=1]="Pen",e[e.Touch=2]="Touch",e))(Po||{}),cd=(e=>(e[e.Play=0]="Play",e[e.Pause=1]="Pause",e[e.Seeked=2]="Seeked",e[e.VolumeChange=3]="VolumeChange",e[e.RateChange=4]="RateChange",e))(cd||{});function Zk(e){try{return e.contentDocument}catch{}}function Ioe(e){try{return e.contentWindow}catch{}}function XI(e){return"__ln"in e}class Moe{constructor(){this.length=0,this.head=null,this.tail=null}get(t){if(t>=this.length)throw new Error("Position outside of list range");let n=this.head;for(let r=0;r<t;r++)n=n?.next||null;return n}addNode(t){const n={value:t,previous:null,next:null};if(t.__ln=n,t.previousSibling&&XI(t.previousSibling)){const r=t.previousSibling.__ln.next;n.next=r,n.previous=t.previousSibling.__ln,t.previousSibling.__ln.next=n,r&&(r.previous=n)}else if(t.nextSibling&&XI(t.nextSibling)&&t.nextSibling.__ln.previous){const r=t.nextSibling.__ln.previous;n.previous=r,n.next=t.nextSibling.__ln,t.nextSibling.__ln.previous=n,r&&(r.next=n)}else this.head&&(this.head.previous=n),n.next=this.head,this.head=n;n.next===null&&(this.tail=n),this.length++}removeNode(t){const n=t.__ln;this.head&&(n.previous?(n.previous.next=n.next,n.next?n.next.previous=n.previous:this.tail=n.previous):(this.head=n.next,this.head?this.head.previous=null:this.tail=null),t.__ln&&delete t.__ln,this.length--)}}const QI=(e,t)=>`${e}@${t}`;class Doe{constructor(){this.frozen=!1,this.locked=!1,this.texts=[],this.attributes=[],this.attributeMap=new WeakMap,this.removes=[],this.mapRemoves=[],this.movedMap={},this.addedSet=new Set,this.movedSet=new Set,this.droppedSet=new Set,this.processMutations=t=>
34{t.forEach(this.processMutation),this.emit()},this.emit=()=>{if(this.frozen||this.locked)return;const t=[],n=new Set,r=new Moe,i=c=>{let d=c,f=Bp;for(;f===Bp;)d=d&&d.nextSibling,f=d&&this.mirror.getId(d);return f},s=c=>{if(!c.parentNode||!j9(c))return;const d=vp(c.parentNode)?this.mirror.getId($9(c)):this.mirror.getId(c.parentNode),f=i(c);if(d===-1||f===-1)return r.addNode(c);const p=wd(c,{doc:this.doc,mirror:this.mirror,blockClass:this.blockClass,blockSelector:this.blockSelector,maskAllText:this.maskAllText,unblockSelector:this.unblockSelector,maskTextClass:this.maskTextClass,unmaskTextClass:this.unmaskTextClass,maskTextSelector:this.maskTextSelector,unmaskTextSelector:this.unmaskTextSelector,skipChild:!0,newlyAddedElement:!0,inlineStylesheet:this.inlineStylesheet,maskInputOptions:this.maskInputOptions,maskAttributeFn:this.maskAttributeFn,maskTextFn:this.maskTextFn,maskInputFn:this.maskInputFn,slimDOMOptions:this.slimDOMOptions,dataURLOptions:this.dataURLOptions,recordCanvas:this.recordCanvas,inlineImages:this.inlineImages,onSerialize:m=>{L9(m,this.mirror)&&!bi(m,this.blockClass,this.blockSelector,this.unblockSelector,!1)&&this.iframeManager.addIframe(m),N9(m,this.mirror)&&this.stylesheetManager.trackLinkElement(m),Wx(c)&&this.shadowDomManager.addShadowRoot(c.shadowRoot,this.doc)},onIframeLoad:(m,v)=>{bi(m,this.blockClass,this.blockSelector,this.unblockSelector,!1)||(this.iframeManager.attachIframe(m,v),m.contentWindow&&this.canvasManager.addWindow(m.contentWindow),this.shadowDomManager.observeAttachShadow(m))},onStylesheetLoad:(m,v)=>{this.stylesheetManager.attachLinkElement(m,v)},onBlockedImageLoad:(m,v,{width:w,height:_})=>{this.mutationCb({adds:[],removes:[],texts:[],attributes:[{id:v.id,attributes:{style:{width:`${w}px`,height:`${_}px`}}}]})},ignoreCSSAttributes:this.ignoreCSSAttributes});p&&(t.push({parentId:d,nextId:f,node:p}),n.add(p.id))};for(;this.mapRemoves.length;)this.mirror.removeNodeFromMap(this.mapRemoves.shift());for(const c of this.movedSet)e5(this.removes,c,this.mirror)&&!this.movedSet.has(c.parentNode)||s(c);for(const c of this.addedSet)!t5(this.droppedSet,c)&&!e5(this.removes,c,this.mirror)||t5(this.movedSet,c)?s(c):this.droppedSet.add(c);let o=null;for(;r.length;){let c=null;if(o){const d=this.mirror.getId(o.value.parentNode),f=i(o.value);d!==-1&&f!==-1&&(c=o)}if(!c){let d=r.tail;for(;d;){const f=d;if(d=d.previous,f){const p=this.mirror.getId(f.value.parentNode);if(i(f.value)===-1)continue;if(p!==-1){c=f;break}else{const v=f.value;if(v.parentNode&&v.parentNode.nodeType===Node.DOCUMENT_FRAGMENT_NODE){const w=v.parentNode.host;if(this.mirror.getId(w)!==-1){c=f;break}}}}}}if(!c){for(;r.head;)r.removeNode(r.head.value);break}o=c.previous,r.removeNode(c.value),s(c.value)}const a={texts:this.texts.map(c=>({id:this.mirror.getId(c.node),value:c.value})).filter(c=>!n.has(c.id)).filter(c=>this.mirror.has(c.id)),attributes:this.attributes.map(c=>{const{attributes:d}=c;if(typeof d.style=="string"){const f=JSON.stringify(c.styleDiff),p=JSON.stringify(c._unchangedStyles);f.length<d.style.length&&(f+p).split("var(").length===d.style.split("var(").length&&(d.style=c.styleDiff)}return{id:this.mirror.getId(c.node),attributes:d}}).filter(c=>!n.has(c.id)).filter(c=>this.mirror.has(c.id)),removes:this.removes,adds:t};!a.texts.length&&!a.attributes.length&&!a.removes.length&&!a.adds.length||(this.texts=[],this.attributes=[],this.attributeMap=new WeakMap,this.removes=[],this.addedSet=new Set,this.movedSet=new Set,this.droppedSet=new Set,this.movedMap={},this.mutationCb(a))},this.processMutation=t=>{if(!rS(t.target,this.mirror))switch(t.type){case"characterData":{const n=t.target.textContent;!bi(t.target,this.blockClass,this.blockSelector,this.unblockSelector,!1)&&n!==t.oldValue&&this.texts.push({value:Qd(t.target,this.maskTextClass,this.maskTextSelector,this.unmaskTextClass,this.unmaskTextSelector,this.maskAllText)&&n?this.maskTextFn?this.maskTextFn(n,M9(t.target)):n.replace(/[\S]/g,"*"):n,node:t.target});break}case"attributes":{const n=t.target;let r=t.attributeName,i=t.target.getAttribute(r);if(r==="value"){const o=Kk(n),a=n.tagName;i=E0(n,a,o);const c=q_({maskInputOptions:this.maskInputOptions,tagName:a,type:o}),d=Qd(t.target,this.maskTextClass,this.maskTextSelector,this.unmaskTextClass,this.unmaskTextSelector,c);i=zp({isMasked:d,element:n,value:i,maskInputFn:this.maskInputFn})}if(bi(t.target,this.blockClass,this.blockSelector,this.unblockSelector,!1)||i===t.oldValue)return;let s=this.attributeMap.get(t.target);if(n.tagName==="IFRAME"&&r==="src"&&!this.keepIframeSrcFn(i))if(!Zk(n))r="rr_src";else return;if(s||(s={node:t.target,attributes:{},styleDiff:{},_unchangedStyles:{}},this.attributes.push(s),this.attributeMap.set(t.target,s)),r==="type"&&n.tagName==="INPUT"&&(t.oldValue||"").toLowerCase()==="password"&&n.setAttribute("data-rr-is-password","true"),!R9(n.tagName,r)&&(s.attributes[r]=T9(this.doc,Xd(n.tagName),Xd(r),i,n,this.maskAttributeFn),r==="style")){if(!this.unattachedDoc)try{this.unattachedDoc=document.implementation.createHTMLDocument()}catch{this.unattachedDoc=this.doc}const o=this.unattachedDoc.createElement("span");t.oldValue&&o.setAttribute("style",t.oldValue);for(const a of Array.from(n.style)){const c=n.style.getPropertyValue(a),d=n.style.getPropertyPriority(a);c!==o.style.getPropertyValue(a)||d!==o.style.getPropertyPriority(a)?d===""?s.styleDiff[a]=c:s.styleDiff[a]=[c,d]:s._unchangedStyles[a]=[c,d]}for(const a of Array.from(o.style))n.style.getPropertyValue(a)===""&&(s.styleDiff[a]=!1)}break}
34case"childList":{if(bi(t.target,this.blockClass,this.blockSelector,this.unblockSelector,!0))return;t.addedNodes.forEach(n=>this.genAdds(n,t.target)),t.removedNodes.forEach(n=>{const r=this.mirror.getId(n),i=vp(t.target)?this.mirror.getId(t.target.host):this.mirror.getId(t.target);bi(t.target,this.blockClass,this.blockSelector,this.unblockSelector,!1)||rS(n,this.mirror)||!Coe(n,this.mirror)||(this.addedSet.has(n)?(qx(this.addedSet,n),this.droppedSet.add(n)):this.addedSet.has(t.target)&&r===-1||D9(t.target,this.mirror)||(this.movedSet.has(n)&&this.movedMap[QI(r,i)]?qx(this.movedSet,n):this.removes.push({parentId:i,id:r,isShadow:vp(t.target)&&_p(t.target)?!0:void 0})),this.mapRemoves.push(n))});break}}},this.genAdds=(t,n)=>{if(!this.processedNodeManager.inOtherBuffer(t,this)&&!(this.addedSet.has(t)||this.movedSet.has(t))){if(this.mirror.hasNode(t)){if(rS(t,this.mirror))return;this.movedSet.add(t);let r=null;n&&this.mirror.hasNode(n)&&(r=this.mirror.getId(n)),r&&r!==-1&&(this.movedMap[QI(this.mirror.getId(t),r)]=!0)}else this.addedSet.add(t),this.droppedSet.delete(t);bi(t,this.blockClass,this.blockSelector,this.unblockSelector,!1)||(t.childNodes&&t.childNodes.forEach(r=>this.genAdds(r)),Wx(t)&&t.shadowRoot.childNodes.forEach(r=>{this.processedNodeManager.add(r,this),this.genAdds(r,t)}))}}}init(t){["mutationCb","blockClass","blockSelector","unblockSelector","maskAllText","maskTextClass","unmaskTextClass","maskTextSelector","unmaskTextSelector","inlineStylesheet","maskInputOptions","maskAttributeFn","maskTextFn","maskInputFn","keepIframeSrcFn","recordCanvas","inlineImages","slimDOMOptions","dataURLOptions","doc","mirror","iframeManager","stylesheetManager","shadowDomManager","canvasManager","processedNodeManager","ignoreCSSAttributes"].forEach(n=>{this[n]=t[n]})}freeze(){this.frozen=!0,this.canvasManager.freeze()}unfreeze(){this.frozen=!1,this.canvasManager.unfreeze(),this.emit()}isFrozen(){return this.frozen}lock(){this.locked=!0,this.canvasManager.lock()}unlock(){this.locked=!1,this.canvasManager.unlock(),this.emit()}reset(){this.shadowDomManager.reset(),this.canvasManager.reset()}}function qx(e,t){e.delete(t),t.childNodes?.forEach(n=>qx(e,n))}function e5(e,t,n){return e.length===0?!1:Loe(e,t,n)}function Loe(e,t,n){let r=t.parentNode;for(;r;){const i=n.getId(r);if(e.some(s=>s.id===i))return!0;r=r.parentNode}return!1}function t5(e,t){return e.size===0?!1:F9(e,t)}function F9(e,t){const{parentNode:n}=t;return n?e.has(n)?!0:F9(e,n):!1}let wp;function Noe(e){wp=e}function $oe(){wp=void 0}const Ut=e=>wp?(...n)=>{try{return e(...n)}catch(r){if(wp&&wp(r)===!0)return()=>{};throw r}}:e,bd=[];function jm(e){try{if("composedPath"in e){const t=e.composedPath();if(t.length)return t[0]}else if("path"in e&&e.path.length)return e.path[0]}catch{}return e&&e.target}function U9(e,t){const n=new Doe;bd.push(n),n.init(e);let r=window.MutationObserver||window.__rrMutationObserver;const i=window?.Zone?.__symbol__?.("MutationObserver");i&&window[i]&&(r=window[i]);const s=new r(Ut(o=>{e.onMutation&&e.onMutation(o)===!1||n.processMutations.bind(n)(o)}));return s.observe(t,{attributes:!0,attributeOldValue:!0,characterData:!0,characterDataOldValue:!0,childList:!0,subtree:!0}),s}function joe({mousemoveCb:e,sampling:t,doc:n,mirror:r}){if(t.mousemove===!1)return()=>{};const i=typeof t.mousemove=="number"?t.mousemove:50,s=typeof t.mousemoveCallback=="number"?t.mousemoveCallback:500;let o=[],a;const c=Hp(Ut(p=>{const m=Date.now()-a;e(o.map(v=>(v.timeOffset-=m,v)),p),o=[],a=null}),s),d=Ut(Hp(Ut(p=>{const m=jm(p),{clientX:v,clientY:w}=Vx(p)?p.changedTouches[0]:p;a||(a=C0()),o.push({x:v,y:w,id:r.getId(m),timeOffset:C0()-a}),c(typeof DragEvent<"u"&&p instanceof DragEvent?vt.Drag:p instanceof MouseEvent?vt.MouseMove:vt.TouchMove)}),i,{trailing:!1})),f=[Vr("mousemove",d,n),Vr("touchmove",d,n),Vr("drag",d,n)];return Ut(()=>{f.forEach(p=>p())})}function Foe({mouseInteractionCb:e,doc:t,mirror:n,blockClass:r,blockSelector:i,unblockSelector:s,sampling:o}){if(o.mouseInteraction===!1)return()=>{};const a=o.mouseInteraction===!0||o.mouseInteraction===void 0?{}:o.mouseInteraction,c=[];let d=null;const f=p=>m=>{const v=jm(m);if(bi(v,r,i,s,!0))return;let w=null,_=p;if("pointerType"in m){switch(m.pointerType){case"mouse":w=Po.Mouse;break;case"touch":w=Po.Touch;break;case"pen":w=Po.Pen;break}w===Po.Touch?zr[p]===zr.MouseDown?_="TouchStart":zr[p]===zr.MouseUp&&(_="TouchEnd"):Po.Pen}else Vx(m)&&(w=Po.Touch);w!==null?(d=w,(_.startsWith("Touch")&&w===Po.Touch||_.startsWith("Mouse")&&w===Po.Mouse)&&(w=null)):zr[p]===zr.Click&&(w=d,d=null);const b=Vx(m)?m.changedTouches[0]:m;if(!b)return;const C=n.getId(v),{clientX:P,clientY:D}=b;Ut(e)({type:zr[_],id:C,x:P,y:D,...w!==null&&{pointerType:w}})};return Object.keys(zr).filter(p=>Number.isNaN(Number(p))&&!p.endsWith("_Departed")&&a[p]!==!1).forEac
34h(p=>{let m=Xd(p);const v=f(p);if(window.PointerEvent)switch(zr[p]){case zr.MouseDown:case zr.MouseUp:m=m.replace("mouse","pointer");break;case zr.TouchStart:case zr.TouchEnd:return}c.push(Vr(m,v,t))}),Ut(()=>{c.forEach(p=>p())})}function z9({scrollCb:e,doc:t,mirror:n,blockClass:r,blockSelector:i,unblockSelector:s,sampling:o}){const a=Ut(Hp(Ut(c=>{const d=jm(c);if(!d||bi(d,r,i,s,!0))return;const f=n.getId(d);if(d===t&&t.defaultView){const p=O9(t.defaultView);e({id:f,x:p.left,y:p.top})}else e({id:f,x:d.scrollLeft,y:d.scrollTop})}),o.scroll||100));return Vr("scroll",a,t)}function Uoe({viewportResizeCb:e},{win:t}){let n=-1,r=-1;const i=Ut(Hp(Ut(()=>{const s=A9(),o=I9();(n!==s||r!==o)&&(e({width:Number(o),height:Number(s)}),n=s,r=o)}),200));return Vr("resize",i,t)}const zoe=["INPUT","TEXTAREA","SELECT"],n5=new WeakMap;function Boe({inputCb:e,doc:t,mirror:n,blockClass:r,blockSelector:i,unblockSelector:s,ignoreClass:o,ignoreSelector:a,maskInputOptions:c,maskInputFn:d,sampling:f,userTriggeredOnInput:p,maskTextClass:m,unmaskTextClass:v,maskTextSelector:w,unmaskTextSelector:_}){function b(k){let L=jm(k);const B=k.isTrusted,A=L&&Bx(L.tagName);if(A==="OPTION"&&(L=L.parentElement),!L||!A||zoe.indexOf(A)<0||bi(L,r,i,s,!0))return;const V=L;if(V.classList.contains(o)||a&&V.matches(a))return;const K=Kk(L);let W=E0(V,A,K),U=!1;const q=q_({maskInputOptions:c,tagName:A,type:K}),z=Qd(L,m,w,v,_,q);(K==="radio"||K==="checkbox")&&(U=L.checked),W=zp({isMasked:z,element:L,value:W,maskInputFn:d}),C(L,p?{text:W,isChecked:U,userTriggered:B}:{text:W,isChecked:U});const x=L.name;K==="radio"&&x&&U&&t.querySelectorAll(`input[type="radio"][name="${x}"]`).forEach(N=>{if(N!==L){const M=zp({isMasked:z,element:N,value:E0(N,A,K),maskInputFn:d});C(N,p?{text:M,isChecked:!U,userTriggered:!1}:{text:M,isChecked:!U})}})}function C(k,L){const B=n5.get(k);if(!B||B.text!==L.text||B.isChecked!==L.isChecked){n5.set(k,L);const A=n.getId(k);Ut(e)({...L,id:A})}}const D=(f.input==="last"?["change"]:["input","change"]).map(k=>Vr(k,Ut(b),t)),F=t.defaultView;if(!F)return()=>{D.forEach(k=>k())};const R=F.Object.getOwnPropertyDescriptor(F.HTMLInputElement.prototype,"value"),I=[[F.HTMLInputElement.prototype,"value"],[F.HTMLInputElement.prototype,"checked"],[F.HTMLSelectElement.prototype,"value"],[F.HTMLTextAreaElement.prototype,"value"],[F.HTMLSelectElement.prototype,"selectedIndex"],[F.HTMLOptionElement.prototype,"selected"]];return R&&R.set&&D.push(...I.map(k=>P9(k[0],k[1],{set(){Ut(b)({target:this,isTrusted:!1})}},!1,F))),Ut(()=>{D.forEach(k=>k())})}function k0(e){const t=[];function n(r,i){if(By("CSSGroupingRule")&&r.parentRule instanceof CSSGroupingRule||By("CSSMediaRule")&&r.parentRule instanceof CSSMediaRule||By("CSSSupportsRule")&&r.parentRule instanceof CSSSupportsRule||By("CSSConditionRule")&&r.parentRule instanceof CSSConditionRule){const o=Array.from(r.parentRule.cssRules).indexOf(r);i.unshift(o)}else if(r.parentStyleSheet){const o=Array.from(r.parentStyleSheet.cssRules).indexOf(r);i.unshift(o)}return i}return n(e,t)}function el(e,t,n){let r,i;return e?(e.ownerNode?r=t.getId(e.ownerNode):i=n.getId(e),{styleId:i,id:r}):{}}function Hoe({styleSheetRuleCb:e,mirror:t,stylesheetManager:n},{win:r}){if(!r.CSSStyleSheet||!r.CSSStyleSheet.prototype)return()=>{};const i=r.CSSStyleSheet.prototype.insertRule;r.CSSStyleSheet.prototype.insertRule=new Proxy(i,{apply:Ut((f,p,m)=>{const[v,w]=m,{id:_,styleId:b}=el(p,t,n.styleMirror);return(_&&_!==-1||b&&b!==-1)&&e({id:_,styleId:b,adds:[{rule:v,index:w}]}),f.apply(p,m)})});const s=r.CSSStyleSheet.prototype.deleteRule;r.CSSStyleSheet.prototype.deleteRule=new Proxy(s,{apply:Ut((f,p,m)=>{const[v]=m,{id:w,styleId:_}=el(p,t,n.styleMirror);return(w&&w!==-1||_&&_!==-1)&&e({id:w,styleId:_,removes:[{index:v}]}),f.apply(p,m)})});let o;r.CSSStyleSheet.prototype.replace&&(o=r.CSSStyleSheet.prototype.replace,r.CSSStyleSheet.prototype.replace=new Proxy(o,{apply:Ut((f,p,m)=>{const[v]=m,{id:w,styleId:_}=el(p,t,n.styleMirror);return(w&&w!==-1||_&&_!==-1)&&e({id:w,styleId:_,replace:v}),f.apply(p,m)})}));let a;r.CSSStyleSheet.prototype.replaceSync&&(a=r.CSSStyleSheet.prototype.replaceSync,r.CSSStyleSheet.prototype.replaceSync=new Proxy(a,{apply:Ut((f,p,m)=>{const[v]=m,{id:w,styleId:_}=el(p,t,n.styleMirror);return(w&&w!==-1||_&&_!==-1)&&e({id:w,styleId:_,replaceSync:v}),f.apply(p,m)})}
34));const c={};Hy("CSSGroupingRule")?c.CSSGroupingRule=r.CSSGroupingRule:(Hy("CSSMediaRule")&&(c.CSSMediaRule=r.CSSMediaRule),Hy("CSSConditionRule")&&(c.CSSConditionRule=r.CSSConditionRule),Hy("CSSSupportsRule")&&(c.CSSSupportsRule=r.CSSSupportsRule));const d={};return Object.entries(c).forEach(([f,p])=>{d[f]={insertRule:p.prototype.insertRule,deleteRule:p.prototype.deleteRule},p.prototype.insertRule=new Proxy(d[f].insertRule,{apply:Ut((m,v,w)=>{const[_,b]=w,{id:C,styleId:P}=el(v.parentStyleSheet,t,n.styleMirror);return(C&&C!==-1||P&&P!==-1)&&e({id:C,styleId:P,adds:[{rule:_,index:[...k0(v),b||0]}]}),m.apply(v,w)})}),p.prototype.deleteRule=new Proxy(d[f].deleteRule,{apply:Ut((m,v,w)=>{const[_]=w,{id:b,styleId:C}=el(v.parentStyleSheet,t,n.styleMirror);return(b&&b!==-1||C&&C!==-1)&&e({id:b,styleId:C,removes:[{index:[...k0(v),_]}]}),m.apply(v,w)})})}),Ut(()=>{r.CSSStyleSheet.prototype.insertRule=i,r.CSSStyleSheet.prototype.deleteRule=s,o&&(r.CSSStyleSheet.prototype.replace=o),a&&(r.CSSStyleSheet.prototype.replaceSync=a),Object.entries(c).forEach(([f,p])=>{p.prototype.insertRule=d[f].insertRule,p.prototype.deleteRule=d[f].deleteRule})})}function B9({mirror:e,stylesheetManager:t},n){let r=null;n.nodeName==="#document"?r=e.getId(n):r=e.getId(n.host);const i=n.nodeName==="#document"?n.defaultView?.Document:n.ownerDocument?.defaultView?.ShadowRoot,s=i?.prototype?Object.getOwnPropertyDescriptor(i?.prototype,"adoptedStyleSheets"):void 0;return r===null||r===-1||!i||!s?()=>{}:(Object.defineProperty(n,"adoptedStyleSheets",{configurable:s.configurable,enumerable:s.enumerable,get(){return s.get?.call(this)},set(o){const a=s.set?.call(this,o);if(r!==null&&r!==-1)try{t.adoptStyleSheets(o,r)}catch{}return a}}),Ut(()=>{Object.defineProperty(n,"adoptedStyleSheets",{configurable:s.configurable,enumerable:s.enumerable,get:s.get,set:s.set})}))}function Voe({styleDeclarationCb:e,mirror:t,ignoreCSSAttributes:n,stylesheetManager:r},{win:i}){const s=i.CSSStyleDeclaration.prototype.setProperty;i.CSSStyleDeclaration.prototype.setProperty=new Proxy(s,{apply:Ut((a,c,d)=>{const[f,p,m]=d;if(n.has(f))return s.apply(c,[f,p,m]);const{id:v,styleId:w}=el(c.parentRule?.parentStyleSheet,t,r.styleMirror);return(v&&v!==-1||w&&w!==-1)&&e({id:v,styleId:w,set:{property:f,value:p,priority:m},index:k0(c.parentRule)}),a.apply(c,d)})});const o=i.CSSStyleDeclaration.prototype.removeProperty;return i.CSSStyleDeclaration.prototype.removeProperty=new Proxy(o,{apply:Ut((a,c,d)=>{const[f]=d;if(n.has(f))return o.apply(c,[f]);const{id:p,styleId:m}=el(c.parentRule?.parentStyleSheet,t,r.styleMirror);return(p&&p!==-1||m&&m!==-1)&&e({id:p,styleId:m,remove:{property:f},index:k0(c.parentRule)}),a.apply(c,d)})}),Ut(()=>{i.CSSStyleDeclaration.prototype.setProperty=s,i.CSSStyleDeclaration.prototype.removeProperty=o})}function Woe({mediaInteractionCb:e,blockClass:t,blockSelector:n,unblockSelector:r,mirror:i,sampling:s,doc:o}){const a=Ut(d=>Hp(Ut(f=>{const p=jm(f);if(!p||bi(p,t,n,r,!0))return;const{currentTime:m,volume:v,muted:w,playbackRate:_}=p;e({type:d,id:i.getId(p),currentTime:m,volume:v,muted:w,playbackRate:_})}),s.media||500)),c=[Vr("play",a(cd.Play),o),Vr("pause",a(cd.Pause),o),Vr("seeked",a(cd.Seeked),o),Vr("volumechange",a(cd.VolumeChange),o),Vr("ratechange",a(cd.RateChange),o)];return Ut(()=>{c.forEach(d=>d())})}function qoe({fontCb:e,doc:t}){const n=t.defaultView;if(!n)return()=>{};const r=[],i=new WeakMap,s=n.FontFace;n.FontFace=function(c,d,f){const p=new s(c,d,f);return i.set(p,{family:c,buffer:typeof d!="string",descriptors:f,fontSource:typeof d=="string"?d:JSON.stringify(Array.from(new Uint8Array(d)))}),p};const o=Yk(t.fonts,"add",function(a){return function(c){return G_(Ut(()=>{const d=i.get(c);d&&(e(d),i.delete(c))}),0),a.apply(this,[c])}});return r.push(()=>{n.FontFace=s}),r.push(o),Ut(()=>{r.forEach(a=>a())})}function Koe(e){const{doc:t,mirror:n,blockClass:r,blockSelector:i,unblockSelector:s,selectionCb:o}=e;let a=!0;const c=Ut(()=>{const d=t.getSelection();if(!d||a&&d?.isCollapsed)return;a=d.isCollapsed||!1;const f=[],p=d.rangeCount||0;for(let m=0;m<p;m++){const v=d.getRangeAt(m),{startContainer:w,startOffset:_,endContainer:b,endOffset:C}=v;bi(w,r,i,s,!0)||bi(b,r,i,s,!0)||f.push({start:n.getId(w),startOffset:_,end:n.getId(b),endOffset:C})}o({ranges:f})});return c(),Vr("selectionchange",c)}function Goe({doc:e,customElementCb:t}){const n=e.defaultView;return!n||!n.customElements?()=>{}:Yk(n.customElements,"define",function(i){return function(s,o,a){try{t({define:{name:s}})}catch{}return i.apply(this,[s,o,a])}})}function Yoe(e,t={}){const n=e.doc.defaultView;if(!n)return()=>{};let r;e.recordDOM&&(r=U9(e,e.doc));const i=joe(e),s=Foe(e),o=z9(e),a=Uoe(e,{win:n}),c=Boe(e),d=Woe(e);let f=()=>{},p=()=>{},m=()=>{},v=()=>{};e.recordDOM&&(f=Hoe(e,{win:n}),p=B9(e,e.doc),m=Voe(e,{win:n}),e.collectFonts&&(v=qoe(e)));const w=Koe(e),_=Goe(e),b=[];for(const C of e.plugins)b.push(C.observer(C.callback,n,C.options));return Ut(()=>{bd.forEach(C=>C.reset()),r?.disconnect(),i(),s(),o(),a(),c(),d(),f(),p(),m(),v(),w(),_(),b.forEach(C=>C())})}function By(e){return typeof window[e]<"u"}function Hy(e){return!!(typeof window[e]<"u"&&window[e].prototype&&"insertRule"in window[e].prototype&&"deleteRule"in window[e].prototype)}class Kx{constructor(t){this.generateIdFn=t,this.iframeIdToRemoteIdMap=new WeakMap,this.iframeRemoteIdToIdMap=new WeakMap}getId(t,n,r,i){const s=r||this.getIdToRemoteIdMap(t),o=i||this.getRemoteIdToIdMap(t);let a=s.get(n);return a||(a=this.generateIdFn(),s.set(n,a),o.set(a,n)),a}getIds(t,n){const r=this.getIdToRemoteIdMap(t),i=this.getRemoteIdToIdMap(t);return n.map(s=>this.getId(t,s,r,i))}getRemoteId(t,n,r){const i=r||this.getRemoteIdToIdMap(t);if(typeof n!="number")return n;const s=i.get(n);return s||-1}getRemoteIds(t,n){const r=this.getRemoteIdToIdMap(t);return n.map(i=>this.getRemoteId(t,i,r))}reset(t){if(!t){this.iframeIdToRemoteIdMap=new WeakMap,this.iframeRemoteIdToIdMap=new WeakMap;return}this.iframeIdToRemoteIdMap.delete(t),this.iframeRemoteIdToIdMap.delete(t)}getIdToRemoteIdMap(t){let n=this.iframeIdToRemoteIdMap.get(t);return n||(n=new Map,this.iframeIdToRemoteIdMap.set(t,n)),n}getRemoteIdToIdMap(t){let n=this.iframeRemoteIdToIdMap.get(t);return n||(n=new Map,this.iframeRemoteIdToIdMap.set(t,n)),n}}
34class Joe{constructor(){this.crossOriginIframeMirror=new Kx(Gk),this.crossOriginIframeRootIdMap=new WeakMap}addIframe(){}addLoadListener(){}attachIframe(){}}class Zoe{constructor(t){this.iframes=new WeakMap,this.crossOriginIframeMap=new WeakMap,this.crossOriginIframeMirror=new Kx(Gk),this.crossOriginIframeRootIdMap=new WeakMap,this.mutationCb=t.mutationCb,this.wrappedEmit=t.wrappedEmit,this.stylesheetManager=t.stylesheetManager,this.recordCrossOriginIframes=t.recordCrossOriginIframes,this.crossOriginIframeStyleMirror=new Kx(this.stylesheetManager.styleMirror.generateId.bind(this.stylesheetManager.styleMirror)),this.mirror=t.mirror,this.recordCrossOriginIframes&&window.addEventListener("message",this.handleMessage.bind(this))}addIframe(t){this.iframes.set(t,!0),t.contentWindow&&this.crossOriginIframeMap.set(t.contentWindow,t)}addLoadListener(t){this.loadListener=t}attachIframe(t,n){this.mutationCb({adds:[{parentId:this.mirror.getId(t),nextId:null,node:n}],removes:[],texts:[],attributes:[],isAttachIframe:!0}),this.recordCrossOriginIframes&&t.contentWindow?.addEventListener("message",this.handleMessage.bind(this)),this.loadListener?.(t);const r=Zk(t);r&&r.adoptedStyleSheets&&r.adoptedStyleSheets.length>0&&this.stylesheetManager.adoptStyleSheets(r.adoptedStyleSheets,this.mirror.getId(r))}handleMessage(t){const n=t;if(n.data.type!=="rrweb"||n.origin!==n.data.origin||!t.source)return;const i=this.crossOriginIframeMap.get(t.source);if(!i)return;const s=this.transformCrossOriginEvent(i,n.data.event);s&&this.wrappedEmit(s,n.data.isCheckout)}transformCrossOriginEvent(t,n){switch(n.type){case xt.FullSnapshot:{this.crossOriginIframeMirror.reset(t),this.crossOriginIframeStyleMirror.reset(t),this.replaceIdOnNode(n.data.node,t);const r=n.data.node.id;return this.crossOriginIframeRootIdMap.set(t,r),this.patchRootIdOnNode(n.data.node,r),{timestamp:n.timestamp,type:xt.IncrementalSnapshot,data:{source:vt.Mutation,adds:[{parentId:this.mirror.getId(t),nextId:null,node:n.data.node}],removes:[],texts:[],attributes:[],isAttachIframe:!0}}}case xt.Meta:case xt.Load:case xt.DomContentLoaded:return!1;case xt.Plugin:return n;case xt.Custom:return this.replaceIds(n.data.payload,t,["id","parentId","previousId","nextId"]),n;case xt.IncrementalSnapshot:switch(n.data.source){case vt.Mutation:return n.data.adds.forEach(r=>{this.replaceIds(r,t,["parentId","nextId","previousId"]),this.replaceIdOnNode(r.node,t);const i=this.crossOriginIframeRootIdMap.get(t);i&&this.patchRootIdOnNode(r.node,i)}),n.data.removes.forEach(r=>{this.replaceIds(r,t,["parentId","id"])}),n.data.attributes.forEach(r=>{this.replaceIds(r,t,["id"])}),n.data.texts.forEach(r=>{this.replaceIds(r,t,["id"])}),n;case vt.Drag:case vt.TouchMove:case vt.MouseMove:return n.data.positions.forEach(r=>{this.replaceIds(r,t,["id"])}),n;case vt.ViewportResize:return!1;case vt.MediaInteraction:case vt.MouseInteraction:case vt.Scroll:case vt.CanvasMutation:case vt.Input:return this.replaceIds(n.data,t,["id"]),n;case vt.StyleSheetRule:case vt.StyleDeclaration:return this.replaceIds(n.data,t,["id"]),this.replaceStyleIds(n.data,t,["styleId"]),n;case vt.Font:return n;case vt.Selection:return n.data.ranges.forEach(r=>{this.replaceIds(r,t,["start","end"])}),n;case vt.AdoptedStyleSheet:return this.replaceIds(n.data,t,["id"]),this.replaceStyleIds(n.data,t,["styleIds"]),n.data.styles?.forEach(r=>{this.replaceStyleIds(r,t,["styleId"])}),n}}return!1}replace(t,n,r,i){for(const s of i)!Array.isArray(n[s])&&typeof n[s]!="number"||(Array.isArray(n[s])?n[s]=t.getIds(r,n[s]):n[s]=t.getId(r,n[s]));return n}replaceIds(t,n,r){return this.replace(this.crossOriginIframeMirror,t,n,r)}replaceStyleIds(t,n,r){return this.replace(this.crossOriginIframeStyleMirror,t,n,r)}replaceIdOnNode(t,n){this.replaceIds(t,n,["id","rootId"]),"childNodes"in t&&t.childNodes.forEach(r=>{this.replaceIdOnNode(r,n)})}patchRootIdOnNode(t,n){t.type!==Gn.Document&&!t.rootId&&(t.rootId=n),"childNodes"in t&&t.childNodes.forEach(r=>{this.patchRootIdOnNode(r,n)})}}class Xoe{init(){}addShadowRoot(){}observeAttachShadow(){}reset(){}}class Qoe{constructor(t){this.shadowDoms=new WeakSet,this.restoreHandlers=[],this.mutationCb=t.mutationCb,this.scrollCb=t.scrollCb,this.bypassOptions=t.bypassOptions,this.mirror=t.mirror,this.init()}init(){this.reset(),this.patchAttachShadow(Element,document)}addShadowRoot(t,n){if(!_p(t)||this.shadowDoms.has(t))return;this.shadowDoms.add(t),this.bypassOptions.canvasManager.addShadowRoot(t);const r=U9({...this.bypassOptions,doc:n,mutationCb:this.mutationCb,mirror:this.mirror,shadowDomManager:this},t);this.restoreHandlers.push(()=>r.disconnect()),this.restoreHandlers.push(z9({...this.bypassOptions,scrollCb:this.scrollCb,doc:t,mirror:this.mirror})),G_(()=>{t.adoptedStyleSheets&&t.adoptedStyleSheets.length>0&&this.bypassOptions.stylesheetManager.adoptStyleSheets(t.adoptedStyleSheets,this.mirror.getId(t.host)),this.restoreHandlers.push(B9({mirror:this.mirror,stylesheetManager:this.bypassOptions.stylesheetManager},t))},0)}observeAttachShadow(t){const n=Zk(t),r=Ioe(t);!n||!r||this.patchAttachShadow(r.Element,n)}patchAttachShadow(t,n){const r=this;this.restoreHandlers.push(Yk(t.prototype,"attachShadow",function(i){return function(s){const o=i.call(this,s);return this.shadowRoot&&j9(this)&&r.addShadowRoot(this.shadowRoot,n),o}}))}
34reset(){this.restoreHandlers.forEach(t=>{try{t()}catch{}}),this.restoreHandlers=[],this.shadowDoms=new WeakSet,this.bypassOptions.canvasManager.resetShadowRoots()}}var r5="ABCDEFGHIJKLMNOPQRSTUVWXYZabcdefghijklmnopqrstuvwxyz0123456789+/",eae=typeof Uint8Array>"u"?[]:new Uint8Array(256);for(var Vy=0;Vy<r5.length;Vy++)eae[r5.charCodeAt(Vy)]=Vy;class i5{reset(){}freeze(){}unfreeze(){}lock(){}unlock(){}snapshot(){}addWindow(){}addShadowRoot(){}resetShadowRoots(){}}class tae{constructor(t){this.trackedLinkElements=new WeakSet,this.styleMirror=new Toe,this.mutationCb=t.mutationCb,this.adoptedStyleSheetCb=t.adoptedStyleSheetCb}attachLinkElement(t,n){"_cssText"in n.attributes&&this.mutationCb({adds:[],removes:[],texts:[],attributes:[{id:n.id,attributes:n.attributes}]}),this.trackLinkElement(t)}trackLinkElement(t){this.trackedLinkElements.has(t)||(this.trackedLinkElements.add(t),this.trackStylesheetInLinkElement(t))}adoptStyleSheets(t,n){if(t.length===0)return;const r={id:n,styleIds:[]},i=[];for(const s of t){let o;this.styleMirror.has(s)?o=this.styleMirror.getId(s):(o=this.styleMirror.add(s),i.push({styleId:o,rules:Array.from(s.rules||CSSRule,(a,c)=>({rule:b9(a),index:c}))})),r.styleIds.push(o)}i.length>0&&(r.styles=i),this.adoptedStyleSheetCb(r)}reset(){this.styleMirror.reset(),this.trackedLinkElements=new WeakSet}trackStylesheetInLinkElement(t){}}class nae{constructor(){this.nodeMap=new WeakMap,this.active=!1}inOtherBuffer(t,n){const r=this.nodeMap.get(t);return r&&Array.from(r).some(i=>i!==n)}add(t,n){this.active||(this.active=!0,Ooe(()=>{this.nodeMap=new WeakMap,this.active=!1})),this.nodeMap.set(t,(this.nodeMap.get(t)||new Set).add(n))}destroy(){}}let On,T0;try{if(Array.from([1],e=>e*2)[0]!==2){const e=document.createElement("iframe");document.body.appendChild(e),Array.from=e.contentWindow?.Array.from||Array.from,document.body.removeChild(e)}}catch(e){console.debug("Unable to override Array.from",e)}const ms=eoe();function qo(e={}){const{emit:t,checkoutEveryNms:n,checkoutEveryNth:r,blockClass:i="rr-block",blockSelector:s=null,unblockSelector:o=null,ignoreClass:a="rr-ignore",ignoreSelector:c=null,maskAllText:d=!1,maskTextClass:f="rr-mask",unmaskTextClass:p=null,maskTextSelector:m=null,unmaskTextSelector:v=null,inlineStylesheet:w=!0,maskAllInputs:_,maskInputOptions:b,slimDOMOptions:C,maskAttributeFn:P,maskInputFn:D,maskTextFn:F,maxCanvasSize:R=null,packFn:I,sampling:k={},dataURLOptions:L={},mousemoveWait:B,recordDOM:A=!0,recordCanvas:V=!1,recordCrossOriginIframes:K=!1,recordAfter:W=e.recordAfter==="DOMContentLoaded"?e.recordAfter:"load",userTriggeredOnInput:U=!1,collectFonts:q=!1,inlineImages:z=!1,plugins:x,keepIframeSrcFn:N=()=>!1,ignoreCSSAttributes:M=new Set([]),errorHandler:E,onMutation:O,getCanvasManager:H}=e;Noe(E);const Z=K?window.parent===window:!0;let X=!1;if(!Z)try{window.parent.document&&(X=!1)}catch{X=!0}if(Z&&!t)throw new Error("emit function is required");if(!Z&&!X)return()=>{};B!==void 0&&k.mousemove===void 0&&(k.mousemove=B),ms.reset();const te=_===!0?{color:!0,date:!0,"datetime-local":!0,email:!0,month:!0,number:!0,range:!0,search:!0,tel:!0,text:!0,time:!0,url:!0,week:!0,textarea:!0,select:!0,radio:!0,checkbox:!0}:b!==void 0?b:{},oe=C===!0||C==="all"?{script:!0,comment:!0,headFavicon:!0,headWhitespace:!0,headMetaSocial:!0,headMetaRobots:!0,headMetaHttpEquiv:!0,headMetaVerification:!0,headMetaAuthorship:C==="all",headMetaDescKeywords:C==="all"}:C||{};koe();let le,ye=0;const xe=Je=>{for(const jt of x||[])jt.eventProcessor&&(Je=jt.eventProcessor(Je));return I&&!X&&(Je=I(Je)),Je};On=(Je,jt)=>{const ot=Je;if(ot.timestamp=C0(),bd[0]?.isFrozen()&&ot.type!==xt.FullSnapshot&&!(ot.type===xt.IncrementalSnapshot&&ot.data.source===vt.Mutation)&&bd.forEach(on=>on.unfreeze()),Z)t?.(xe(ot),jt);else if(X){const on={type:"rrweb",event:xe(ot),origin:window.location.origin,isCheckout:jt};window.parent.postMessage(on,"*")}if(ot.type===xt.FullSnapshot)le=ot,ye=0;else if(ot.type===xt.IncrementalSnapshot){if(ot.data.source===vt.Mutation&&ot.data.isAttachIframe)return;ye++;const on=r&&ye>=r,yt=n&&le&&ot.timestamp-le.timestamp>n;(on||yt)&&Xt(!0)}};const be=Je=>{On({type:xt.IncrementalSnapshot,data:{source:vt.Mutation,...Je}})},rt=Je=>On({type:xt.IncrementalSnapshot,data:{source:vt.Scroll,...Je}}),Ue=Je=>On({type:xt.IncrementalSnapshot,data:{source:vt.CanvasMutation,...Je}}),Ve=Je=>On({type:xt.IncrementalSnapshot,data:{source:vt.AdoptedStyleSheet,...Je}}),Qe=new tae({mutationCb:be,adoptedStyleSheetCb:Ve}),ht=typeof __RRWEB_EXCLUDE_IFRAME__=="boolean"&&__RRWEB_EXCLUDE_IFRAME__?new Joe:new Zoe({mirror:ms,mutationCb:be,stylesheetManager:Qe,recordCrossOriginIframes:K,wrappedEmit:On});for(const Je of x||[])Je.getMirror&&Je.getMirror({nodeMirror:ms,crossOriginIframeMirror:ht.crossOriginIframeMirror,crossOriginIframeStyleMirror:ht.crossOriginIframeStyleMirror});const Rt=new nae,it=iae(H,{mirror:ms,win:window,mutationCb:Je=>On({type:xt.IncrementalSnapshot,data:{source:vt.CanvasMutation,...Je}}),recordCanvas:V,blockClass:i,blockSelector:s,unblockSelector:o,maxCanvasSize:R,sampling:k.canvas,dataURLOptions:L,errorHandler:E}),Yt=typeof __RRWEB_EXCLUDE_SHADOW_DOM__=="boolean"&&__RRWEB_EXCLUDE_SHADOW_DOM__?new Xoe:new Qoe({mutationCb:be,scrollCb:rt,bypassOptions:{onMutation:O,blockClass:i,blockSelector:s,unblockSelector:o,maskAllText:d,maskTextClass:f,unmaskTextClass:p,maskTextSelector:m,unmaskTextSelector:v,inlineStylesheet:w,maskInputOptions:te,dataURLOptions:L,maskAttributeFn:P,maskTextFn:F,maskInputFn:D,recordCanvas:V,inlineImages:z,sampling:k,slimDOMOptions:oe,iframeManager:ht,stylesheetManager:Qe,canvasManager:it,keepIframeSrcFn:N,processedNodeManager:Rt,ignoreCSSAttributes:M},mirror:ms}),Xt=(Je=!1)=>
34{if(!A)return;On({type:xt.Meta,data:{href:window.location.href,width:I9(),height:A9()}},Je),Qe.reset(),Yt.init(),bd.forEach(ot=>ot.lock());const jt=xoe(document,{mirror:ms,blockClass:i,blockSelector:s,unblockSelector:o,maskAllText:d,maskTextClass:f,unmaskTextClass:p,maskTextSelector:m,unmaskTextSelector:v,inlineStylesheet:w,maskAllInputs:te,maskAttributeFn:P,maskInputFn:D,maskTextFn:F,slimDOM:oe,dataURLOptions:L,recordCanvas:V,inlineImages:z,onSerialize:ot=>{L9(ot,ms)&&ht.addIframe(ot),N9(ot,ms)&&Qe.trackLinkElement(ot),Wx(ot)&&Yt.addShadowRoot(ot.shadowRoot,document)},onIframeLoad:(ot,on)=>{ht.attachIframe(ot,on),ot.contentWindow&&it.addWindow(ot.contentWindow),Yt.observeAttachShadow(ot)},onStylesheetLoad:(ot,on)=>{Qe.attachLinkElement(ot,on)},onBlockedImageLoad:(ot,on,{width:yt,height:Un})=>{be({adds:[],removes:[],texts:[],attributes:[{id:on.id,attributes:{style:{width:`${yt}px`,height:`${Un}px`}}}]})},keepIframeSrcFn:N,ignoreCSSAttributes:M});if(!jt)return console.warn("Failed to snapshot the document");On({type:xt.FullSnapshot,data:{node:jt,initialOffset:O9(window)}}),bd.forEach(ot=>ot.unlock()),document.adoptedStyleSheets&&document.adoptedStyleSheets.length>0&&Qe.adoptStyleSheets(document.adoptedStyleSheets,ms.getId(document))};T0=Xt;try{const Je=[],jt=on=>Ut(Yoe)({onMutation:O,mutationCb:be,mousemoveCb:(yt,Un)=>On({type:xt.IncrementalSnapshot,data:{source:Un,positions:yt}}),mouseInteractionCb:yt=>On({type:xt.IncrementalSnapshot,data:{source:vt.MouseInteraction,...yt}}),scrollCb:rt,viewportResizeCb:yt=>On({type:xt.IncrementalSnapshot,data:{source:vt.ViewportResize,...yt}}),inputCb:yt=>On({type:xt.IncrementalSnapshot,data:{source:vt.Input,...yt}}),mediaInteractionCb:yt=>On({type:xt.IncrementalSnapshot,data:{source:vt.MediaInteraction,...yt}}),styleSheetRuleCb:yt=>On({type:xt.IncrementalSnapshot,data:{source:vt.StyleSheetRule,...yt}}),styleDeclarationCb:yt=>On({type:xt.IncrementalSnapshot,data:{source:vt.StyleDeclaration,...yt}}),canvasMutationCb:Ue,fontCb:yt=>On({type:xt.IncrementalSnapshot,data:{source:vt.Font,...yt}}),selectionCb:yt=>{On({type:xt.IncrementalSnapshot,data:{source:vt.Selection,...yt}})},customElementCb:yt=>{On({type:xt.IncrementalSnapshot,data:{source:vt.CustomElement,...yt}})},blockClass:i,ignoreClass:a,ignoreSelector:c,maskAllText:d,maskTextClass:f,unmaskTextClass:p,maskTextSelector:m,unmaskTextSelector:v,maskInputOptions:te,inlineStylesheet:w,sampling:k,recordDOM:A,recordCanvas:V,inlineImages:z,userTriggeredOnInput:U,collectFonts:q,doc:on,maskAttributeFn:P,maskInputFn:D,maskTextFn:F,keepIframeSrcFn:N,blockSelector:s,unblockSelector:o,slimDOMOptions:oe,dataURLOptions:L,mirror:ms,iframeManager:ht,stylesheetManager:Qe,shadowDomManager:Yt,processedNodeManager:Rt,canvasManager:it,ignoreCSSAttributes:M,plugins:x?.filter(yt=>yt.observer)?.map(yt=>({observer:yt.observer,options:yt.options,callback:Un=>On({type:xt.Plugin,data:{plugin:yt.name,payload:Un}})}))||[]},{});ht.addLoadListener(on=>{try{Je.push(jt(on.contentDocument))}catch(yt){console.warn(yt)}});const ot=()=>{Xt(),Je.push(jt(document))};return document.readyState==="interactive"||document.readyState==="complete"?ot():(Je.push(Vr("DOMContentLoaded",()=>{On({type:xt.DomContentLoaded,data:{}}),W==="DOMContentLoaded"&&ot()})),Je.push(Vr("load",()=>{On({type:xt.Load,data:{}}),W==="load"&&ot()},window))),()=>{Je.forEach(on=>on()),Rt.destroy(),T0=void 0,$oe()}}catch(Je){console.warn(Je)}}function rae(e){if(!T0)throw new Error("please take full snapshot after start recording");T0(e)}qo.mirror=ms;qo.takeFullSnapshot=rae;function iae(e,t){try{return e?e(t):new i5}catch{return console.warn("Unable to initialize CanvasManager"),new i5}}var s5;(function(e){e[e.NotStarted=0]="NotStarted",e[e.Running=1]="Running",e[e.Stopped=2]="Stopped"})(s5||(s5={}));const sae=3,oae=5;function Xk(e){return e>9999999999?e:e*1e3}function iS(e){return e>9999999999?e/1e3:e}function Fm(e,t){t.category!=="sentry.transaction"&&(["ui.click","ui.input"].includes(t.category)?e.triggerUserActivity():e.checkAndHandleExpiredSession(),e.addUpdate(()=>
34(e.throttledAddEvent({type:xt.Custom,timestamp:(t.timestamp||0)*1e3,data:{tag:"breadcrumb",payload:vs(t,10,1e3)}}),t.category==="console")))}const aae="button,a";function H9(e){return e.closest(aae)||e}function V9(e){const t=W9(e);return!t||!(t instanceof Element)?t:H9(t)}function W9(e){return lae(e)?e.target:e}function lae(e){return typeof e=="object"&&!!e&&"target"in e}let tl;function cae(e){return tl||(tl=[],uae()),tl.push(e),()=>{const t=tl?tl.indexOf(e):-1;t>-1&&tl.splice(t,1)}}function uae(){li(un,"open",function(e){return function(...t){if(tl)try{tl.forEach(n=>n())}catch{}return e.apply(un,t)}})}const dae=new Set([vt.Mutation,vt.StyleSheetRule,vt.StyleDeclaration,vt.AdoptedStyleSheet,vt.CanvasMutation,vt.Selection,vt.MediaInteraction]);function fae(e,t,n){e.handleClick(t,n)}class hae{constructor(t,n,r=Fm){this._lastMutation=0,this._lastScroll=0,this._clicks=[],this._timeout=n.timeout/1e3,this._threshold=n.threshold/1e3,this._scrollTimeout=n.scrollTimeout/1e3,this._replay=t,this._ignoreSelector=n.ignoreSelector,this._addBreadcrumbEvent=r}addListeners(){const t=cae(()=>{this._lastMutation=o5()});this._teardown=()=>{t(),this._clicks=[],this._lastMutation=0,this._lastScroll=0}}removeListeners(){this._teardown&&this._teardown(),this._checkClickTimeout&&clearTimeout(this._checkClickTimeout)}handleClick(t,n){if(mae(n,this._ignoreSelector)||!gae(t))return;const r={timestamp:iS(t.timestamp),clickBreadcrumb:t,clickCount:0,node:n};this._clicks.some(i=>i.node===r.node&&Math.abs(i.timestamp-r.timestamp)<1)||(this._clicks.push(r),this._clicks.length===1&&this._scheduleCheckClicks())}registerMutation(t=Date.now()){this._lastMutation=iS(t)}registerScroll(t=Date.now()){this._lastScroll=iS(t)}registerClick(t){const n=H9(t);this._handleMultiClick(n)}_handleMultiClick(t){this._getClicks(t).forEach(n=>{n.clickCount++})}_getClicks(t){return this._clicks.filter(n=>n.node===t)}_checkClicks(){const t=[],n=o5();this._clicks.forEach(r=>{!r.mutationAfter&&this._lastMutation&&(r.mutationAfter=r.timestamp<=this._lastMutation?this._lastMutation-r.timestamp:void 0),!r.scrollAfter&&this._lastScroll&&(r.scrollAfter=r.timestamp<=this._lastScroll?this._lastScroll-r.timestamp:void 0),r.timestamp+this._timeout<=n&&t.push(r)});for(const r of t){const i=this._clicks.indexOf(r);i>-1&&(this._generateBreadcrumbs(r),this._clicks.splice(i,1))}this._clicks.length&&this._scheduleCheckClicks()}_generateBreadcrumbs(t){const n=this._replay,r=t.scrollAfter&&t.scrollAfter<=this._scrollTimeout,i=t.mutationAfter&&t.mutationAfter<=this._threshold,s=!r&&!i,{clickCount:o,clickBreadcrumb:a}=t;if(s){const c=Math.min(t.mutationAfter||this._timeout,this._timeout)*1e3,d=c<this._timeout*1e3?"mutation":"timeout",f={type:"default",message:a.message,timestamp:a.timestamp,category:"ui.slowClickDetected",data:{...a.data,url:un.location.href,route:n.getCurrentRoute(),timeAfterClickMs:c,endReason:d,clickCount:o||1}};this._addBreadcrumbEvent(n,f);return}if(o>1){const c={type:"default",message:a.message,timestamp:a.timestamp,category:"ui.multiClick",data:{...a.data,url:un.location.href,route:n.getCurrentRoute(),clickCount:o,metric:!0}};this._addBreadcrumbEvent(n,c)}}_scheduleCheckClicks(){this._checkClickTimeout&&clearTimeout(this._checkClickTimeout),this._checkClickTimeout=$m(()=>this._checkClicks(),1e3)}}const pae=["A","BUTTON","INPUT"];function mae(e,t){return!!(!pae.includes(e.tagName)||e.tagName==="INPUT"&&!["submit","button"].includes(e.getAttribute("type")||"")||e.tagName==="A"&&(e.hasAttribute("download")||e.hasAttribute("target")&&e.getAttribute("target")!=="_self")||t&&e.matches(t))}function gae(e){return!!(e.data&&typeof e.data.nodeId=="number"&&e.timestamp)}function o5(){return Date.now()/1e3}function yae(e,t){try{if(!vae(t))return;const{source:n}=t.data;if(dae.has(n)&&e.registerMutation(t.timestamp),n===vt.Scroll&&e.registerScroll(t.timestamp),_ae(t)){const{type:r,id:i}=t.data,s=qo.mirror.getNode(i);s instanceof HTMLElement&&r===zr.Click&&e.registerClick(s)}}catch{}}function vae(e){return e.type===sae}function _ae(e){return e.data.source===vt.MouseInteraction}function Gs(e){return{timestamp:Date.now()/1e3,type:"default",...e}}var Qk=(e=>(e[e.Document=0]="Document",e[e.DocumentType=1]="DocumentType",e[e.Element=2]="Element",e[e.Text=3]="Text",e[e.CDATA=4]="CDATA",e[e.Comment=5]="Comment",e))(Qk||{});const wae=new Set(["id","class","aria-label","role","name","alt","title","data-test-id","data-testid","disabled","aria-disabled","data-sentry-component"]);function bae(e){const t={};!e["data-sentry-component"]&&e["data-sentry-element"]&&(e["data-sentry-component"]=e["data-sentry-element"]);for(const n in e)if(wae.has(n)){let r=n;(n==="data-testid"||n==="data-test-id")&&(r="testId"),t[r]=e[n]}return t}const Sae=e=>t=>{if(!e.isEnabled())return;const n=Eae(t);if(!n)return;const r=t.name==="click",i=r?t.event:void 0;r&&e.clickDetector&&i?.target&&!i.altKey&&!i.metaKey&&!i.ctrlKey&&!i.shiftKey&&fae(e.clickDetector,n,V9(t.event)),Fm(e,n)};function q9(e,t){const n=qo.mirror.getId(e),r=n&&qo.mirror.getNode(n),i=r&&qo.mirror.getMeta(r),s=i&&Cae(i)?i:null;return{message:t,data:s?{nodeId:n,node:{id:n,tagName:s.tagName,textContent:Array.from(s.childNodes).map(o=>
34o.type===Qk.Text&&o.textContent).filter(Boolean).map(o=>o.trim()).join(""),attributes:bae(s.attributes)}}:{}}}function Eae(e){const{target:t,message:n}=xae(e);return Gs({category:`ui.${e.name}`,...q9(t,n)})}function xae(e){const t=e.name==="click";let n,r=null;try{r=t?V9(e.event):W9(e.event),n=hi(r,{maxStringLength:200})||"<unknown>"}catch{n="<unknown>"}return{target:r,message:n}}function Cae(e){return e.type===Qk.Element}function kae(e,t){if(!e.isEnabled())return;e.updateUserActivity();const n=Tae(t);n&&Fm(e,n)}function Tae(e){const{metaKey:t,shiftKey:n,ctrlKey:r,altKey:i,key:s,target:o}=e;if(!o||Rae(o)||!s)return null;const a=t||r||i,c=s.length===1;if(!a&&c)return null;const d=hi(o,{maxStringLength:200})||"<unknown>",f=q9(o,d);return Gs({category:"ui.keyDown",message:d,data:{...f.data,metaKey:t,shiftKey:n,ctrlKey:r,altKey:i,key:s}})}function Rae(e){return e.tagName==="INPUT"||e.tagName==="TEXTAREA"||e.isContentEditable}const Pae={resource:Dae,paint:Iae,navigation:Mae};function sS(e,t){return({metric:n})=>void t.replayPerformanceEntries.push(e(n))}function Oae(e){return e.map(Aae).filter(Boolean)}function Aae(e){const t=Pae[e.entryType];return t?t(e):null}function ef(e){return((pi()||un.performance.timeOrigin)+e)/1e3}function Iae(e){const{duration:t,entryType:n,name:r,startTime:i}=e,s=ef(i);return{type:n,name:r,start:s,end:s+t,data:void 0}}function Mae(e){const{entryType:t,name:n,decodedBodySize:r,duration:i,domComplete:s,encodedBodySize:o,domContentLoadedEventStart:a,domContentLoadedEventEnd:c,domInteractive:d,loadEventStart:f,loadEventEnd:p,redirectCount:m,startTime:v,transferSize:w,type:_}=e;return i===0?null:{type:`${t}.${_}`,start:ef(v),end:ef(s),name:n,data:{size:w,decodedBodySize:r,encodedBodySize:o,duration:i,domInteractive:d,domContentLoadedEventStart:a,domContentLoadedEventEnd:c,loadEventStart:f,loadEventEnd:p,domComplete:s,redirectCount:m}}}function Dae(e){const{entryType:t,initiatorType:n,name:r,responseEnd:i,startTime:s,decodedBodySize:o,encodedBodySize:a,responseStatus:c,transferSize:d}=e;return["fetch","xmlhttprequest"].includes(n)?null:{type:`${t}.${n}`,start:ef(s),end:ef(i),name:r,data:{size:d,statusCode:c,decodedBodySize:o,encodedBodySize:a}}}function Lae(e){const t=e.entries[e.entries.length-1],n=t?.element?[t.element]:void 0;return eT(e,"largest-contentful-paint",n)}function Nae(e){return e.sources!==void 0}function $ae(e){const t=[],n=[];for(const r of e.entries)if(Nae(r)){const i=[];for(const s of r.sources)if(s.node){n.push(s.node);const o=qo.mirror.getId(s.node);o&&i.push(o)}t.push({value:r.value,nodeIds:i.length?i:void 0})}return eT(e,"cumulative-layout-shift",n,t)}function jae(e){const t=e.entries[e.entries.length-1],n=t?.target?[t.target]:void 0;return eT(e,"interaction-to-next-paint",n)}function eT(e,t,n,r){const i=e.value,s=e.rating,o=ef(i);return{type:"web-vital",name:t,start:o,end:o,data:{value:i,size:i,rating:s,nodeIds:n?n.map(a=>qo.mirror.getId(a)):void 0,attributions:r}}}function Fae(e){function t(i){e.performanceEntries.includes(i)||e.performanceEntries.push(i)}function n({entries:i}){i.forEach(t)}const r=[];return["navigation","paint","resource"].forEach(i=>{r.push(Xc(i,n))}),r.push(Bk(sS(Lae,e)),zk(sS($ae,e)),o9(sS(jae,e))),()=>{r.forEach(i=>i())}}const dt=typeof __SENTRY_DEBUG__>"u"||__SENTRY_DEBUG__,Uae='
vendor: 10,329 bytes, line 34
34var t=Uint8Array,n=Uint16Array,r=Int32Array,e=new t([0,0,0,0,0,0,0,0,1,1,1,1,2,2,2,2,3,3,3,3,4,4,4,4,5,5,5,5,0,0,0,0]),i=new t([0,0,0,0,1,1,2,2,3,3,4,4,5,5,6,6,7,7,8,8,9,9,10,10,11,11,12,12,13,13,0,0]),s=new t([16,17,18,0,8,7,9,6,10,5,11,4,12,3,13,2,14,1,15]),a=function(t,e){for(var i=new n(31),s=0;s<31;++s)i[s]=e+=1<<t[s-1];var a=new r(i[30]);for(s=1;s<30;++s)for(var o=i[s];o<i[s+1];++o)a[o]=o-i[s]<<5|s;return{b:i,r:a}},o=a(e,2),h=o.b,f=o.r;h[28]=258,f[258]=28;for(var l=a(i,0).r,u=new n(32768),c=0;c<32768;++c){var v=(43690&c)>>1|(21845&c)<<1;v=(61680&(v=(52428&v)>>2|(13107&v)<<2))>>4|(3855&v)<<4,u[c]=((65280&v)>>8|(255&v)<<8)>>1}var d=function(t,r,e){for(var i=t.length,s=0,a=new n(r);s<i;++s)t[s]&&++a[t[s]-1];var o,h=new n(r);for(s=1;s<r;++s)h[s]=h[s-1]+a[s-1]<<1;if(e){o=new n(1<<r);var f=15-r;for(s=0;s<i;++s)if(t[s])for(var l=s<<4|t[s],c=r-t[s],v=h[t[s]-1]++<<c,d=v|(1<<c)-1;v<=d;++v)o[u[v]>>f]=l}else for(o=new n(i),s=0;s<i;++s)t[s]&&(o[s]=u[h[t[s]-1]++]>>15-t[s]);return o},p=new t(288);for(c=0;c<144;++c)p[c]=8;for(c=144;c<256;++c)p[c]=9;for(c=256;c<280;++c)p[c]=7;for(c=280;c<288;++c)p[c]=8;var g=new t(32);for(c=0;c<32;++c)g[c]=5;var w=d(p,9,0),y=d(g,5,0),m=function(t){return(t+7)/8|0},b=function(n,r,e){return(null==e||e>n.length)&&(e=n.length),new t(n.subarray(r,e))},M=["unexpected EOF","invalid block type","invalid length/literal","invalid distance","stream finished","no stream handler",,"no callback","invalid UTF-8 data","extra field too long","date not in range 1980-2099","filename too long","stream finishing","invalid zip data"],E=function(t,n,r){var e=new Error(n||M[t]);if(e.code=t,Error.captureStackTrace&&Error.captureStackTrace(e,E),!r)throw e;return e},z=function(t,n,r){r<<=7&n;var e=n/8|0;t[e]|=r,t[e+1]|=r>>8},_=function(t,n,r){r<<=7&n;var e=n/8|0;t[e]|=r,t[e+1]|=r>>8,t[e+2]|=r>>16},x=function(r,e){for(var i=[],s=0;s<r.length;++s)r[s]&&i.push({s:s,f:r[s]});var a=i.length,o=i.slice();if(!a)return{t:F,l:0};if(1==a){var h=new t(i[0].s+1);return h[i[0].s]=1,{t:h,l:1}}i.sort(function(t,n){return t.f-n.f}),i.push({s:-1,f:25001});var f=i[0],l=i[1],u=0,c=1,v=2;for(i[0]={s:-1,f:f.f+l.f,l:f,r:l};c!=a-1;)f=i[i[u].f<i[v].f?u++:v++],l=i[u!=c&&i[u].f<i[v].f?u++:v++],i[c++]={s:-1,f:f.f+l.f,l:f,r:l};var d=o[0].s;for(s=1;s<a;++s)o[s].s>d&&(d=o[s].s);var p=new n(d+1),g=A(i[c-1],p,0);if(g>e){s=0;var w=0,y=g-e,m=1<<y;for(o.sort(function(t,n){return p[n.s]-p[t.s]||t.f-n.f});s<a;++s){var b=o[s].s;if(!(p[b]>e))break;w+=m-(1<<g-p[b]),p[b]=e}for(w>>=y;w>0;){var M=o[s].s;p[M]<e?w-=1<<e-p[M]++-1:++s}for(;s>=0&&w;--s){var E=o[s].s;p[E]==e&&(--p[E],++w)}g=e}return{t:new t(p),l:g}},A=function(t,n,r){return-1==t.s?Math.max(A(t.l,n,r+1),A(t.r,n,r+1)):n[t.s]=r},D=function(t){for(var r=t.length;r&&!t[--r];);for(var e=new n(++r),i=0,s=t[0],a=1,o=function(t){e[i++]=t},h=1;h<=r;++h)if(t[h]==s&&h!=r)++a;else{if(!s&&a>2){for(;a>138;a-=138)o(32754);a>2&&(o(a>10?a-11<<5|28690:a-3<<5|12305),a=0)}else if(a>3){for(o(s),--a;a>6;a-=6)o(8304);a>2&&(o(a-3<<5|8208),a=0)}for(;a--;)o(s);a=1,s=t[h]}return{c:e.subarray(0,i),n:r}},T=function(t,n){for(var r=0,e=0;e<n.length;++e)r+=t[e]*n[e];return r},k=function(t,n,r){var e=r.length,i=m(n+2);t[i]=255&e,t[i+1]=e>>8,t[i+2]=255^t[i],t[i+3]=255^t[i+1];for(var s=0;s<e;++s)t[i+s+4]=r[s];return 8*(i+4+e)},U=function(t,r,a,o,h,f,l,u,c,v,m){z(r,m++,a),++h[256];for(var b=x(h,15),M=b.t,E=b.l,A=x(f,15),U=A.t,C=A.l,F=D(M),I=F.c,S=F.n,L=D(U),O=L.c,j=L.n,q=new n(19),B=0;B<I.length;++B)++q[31&I[B]];for(B=0;B<O.length;++B)++q[31&O[B]];for(var G=x(q,7),H=G.t,J=G.l,K=19;K>4&&!H[s[K-1]];--K);var N,P,Q,R,V=v+5<<3,W=T(h,p)+T(f,g)+l,X=T(h,M)+T(f,U)+l+14+3*K+T(q,H)+2*q[16]+3*q[17]+7*q[18];if(c>=0&&V<=W&&V<=X)return k(r,m,t.subarray(c,c+v));if(z(r,m,1+(X<W)),m+=2,X<W){N=d(M,E,0),P=M,Q=d(U,C,0),R=U;var Y=d(H,J,0);z(r,m,S-257),z(r,m+5,j-1),z(r,m+10,K-4),m+=14;for(B=0;B<K;++B)z(r,m+3*B,H[s[B]]);m+=3*K;for(var Z=[I,O],$=0;$<2;++$){var tt=Z[$];for(B=0;B<tt.length;++B){var nt=31&tt[B];z(r,m,Y[nt]),m+=H[nt],nt>15&&(z(r,m,tt[B]>>5&127),m+=tt[B]>>12)}}}else N=w,P=p,Q=y,R=g;for(B=0;B<u;++B){var rt=o[B];if(rt>255){_(r,m,N[(nt=rt>>18&31)+257]),m+=P[nt+257],nt>7&&(z(r,m,rt>>23&31),m+=e[nt]);var et=31&rt;_(r,m,Q[et]),m+=R[et],et>3&&(_(r,m,rt>>5&8191),m+=i[et])}else _(r,m,N[rt]),m+=P[rt]}return _(r,m,N[256]),m+P[256]},C=new r([65540,131080,131088,131104,262176,1048704,1048832,2114560,2117632]),F=new t(0),I=function(){for(var t=new Int32Array(256),n=0;n<256;++n){for(var r=n,e=9;--e;)r=(1&r&&-306674912)^r>>>1;t[n]=r}return t}(),S=function(){var t=1,n=0;return{p:function(r){for(var e=t,i=n,s=0|r.length,a=0;a!=s;){for(var o=Math.min(a+2655,s);a<o;++a)i+=e+=r[a];e=(65535&e)+15*(e>>16),i=(65535&i)+15*(i>>16)}t=e,n=i},d:function(){return(255&(t%=65521))<<24|(65280&t)<<8|(255&(n%=65521))<<8|n>>8}}},L=function(s,a,o,h,u){if(!u&&(u={l:1},a.dictionary)){var c=a.dictionary.subarray(-32768),v=new t(c.length+s.length);v.set(c),v.set(s,c.length),s=v,u.w=c.length}return function(s,a,o,h,u,c){var v=c.z||s.length,d=new t(h+v+5*(1+Math.ceil(v/7e3))+u),p=d.subarray(h,d.length-u),g=c.l,w=7&(c.r||0);if(a){w&&(p[0]=c.r>>3);for(var y=C[a-1],M=y>>13,E=8191&y,z=(1<<o)-1,_=c.p||new n(32768),x=c.h||new n(z+1),A=Math.ceil(o/3),D=2*A,T=function(t){return(s[t]^s[t+1]<<A^s[t+2]<<D)&z},F=new r(25e3),I=new n(288),S=new n(32),L=0,O=0,j=c.i||0,q=0,B=c.w||0,G=0;j+2<v;++j){var H=T(j),J=32767&j,K=x[H];if(_[J]=K,x[H]=J,B<=j){var N=v-j;if((L>7e3||q>24576)&&(N>423||!g)){w=U(s,p,0,F,I,S,O,q,G,j-G,w),q=L=O=0,G=j;for(var P=0;P<286;++P)I[P]=0;for(P=0;P<30;++P)S[P]=0}var Q=2,R=0,V=E,W=J-K&32767;if(N>2&&H==T(j-W))for(var X=Math.min(M,N)-1,Y=Math.min(32767,j),Z=Math.min(258,N);W<=Y&&--V&&J!=K;){if(s[j+Q]==s[j+Q-W]){for(var $=0;$<Z&&s[j+$]==s[j+$-W];++$);if($>Q){if(Q=$,R=W,$>X)break;var tt=Math.min(W,$-2),nt=0;for(P=0;P<tt;++P){var rt=j-W+P&32767,et=rt-_[rt]&32767;et>nt&&(nt=et,K=rt)}}}W+=(J=K)-(K=_[J])&32767}if(R){F[q++]=268435456|f[Q]<<18|l[R];var it=31&f[Q],st=31&l[R];O+=e[it]+i[st],++I[257+it],++S[st],B=j+Q,++L}else F[q++]=s[j],++I[s[j]]}}for(j=Math.max(j,B);j<v;++j)F[q++]=s[j],++I[s[j]];w=U(s,p,g,F,I,S,O,q,G,j-G,w),g||(c.r=7&w|p[w/8|0]<<3,w-=7,c.h=x,c.p=_,c.i=j,c.w=B)}else{for(j=c.w||0;j<v+g;j+=65535){var at=j+65535;at>=v&&(p[w/8|0]=g,at=v),w=k(p,w+1,s.subarray(j,at))}c.i=v}return b(d,0,h+m(w)+u)}(s,null==a.level?6:a.level,null==a.mem?u.l?Math.ceil(1.5*Math.max(8,Math.min(13,Math.log(s.length)))):20:12+a.mem,o,h,u)},O=function(t,n,r){for(;r;++n)t[n]=r,r>>>=8},j=function(){function n(n,r){if("function"==typeof n&&(r=n,n={}),this.ondata=r,this.o=n||{},this.s={l:0,i:32768,w:32768,z:32768},this.b=new t(98304),this.o.dictionary){var e=this.o.dictionary.subarray(-32768);this.b.set(e,32768-e.length),this.s.i=32768-e.length}}return n.prototype.p=function(t,n){this.ondata(L(t,this.o,0,0,this.s),n)},n.prototype.push=function(n,r){this.ondata||E(5),this.s.l&&E(4);var e=n.length+this.s.z;if(e>this.b.length){if(e>2*this.b.length-32768){var i=new t(-32768&e);i.set(this.b.subarray(0,this.s.z)),this.b=i}var s=this.b.length-this.s.z;this.b.set(n.subarray(0,s),this.s.z),this.s.z=this.b.length,this.p(this.b,!1),this.b.set(this.b.subarray(-32768)),this.b.set(n.subarray(s),32768),this.s.z=n.length-s+32768,this.s.i=32766,this.s.w=32768}else this.b.set(n,this.s.z),this.s.z+=n.length;this.s.l=1&r,(this.s.z>this.s.w+8191||r)&&(this.p(this.b,r||!1),this.s.w=this.s.i,this.s.i-=2)},n.prototype.flush=function(){this.ondata||E(5),this.s.l&&E(4),this.p(this.b,!1),this.s.w=this.s.i,this.s.i-=2},n}();function q(t,n){n||(n={});var r=function(){var t=-1;return{p:function(n){for(var r=t,e=0;e<n.length;++e)r=I[255&r^n[e]]^r>>>8;t=r},d:function(){return~t}}}(),e=t.length;r.p(t);var i,s=L(t,n,10+((i=n).filename?i.filename.length+1:0),8),a=s.length;return function(t,n){var r=n.filename;if(t[0]=31,t[1]=139,t[2]=8,t[8]=n.level<2?4:9==n.level?2:0,t[9]=3,0!=n.mtime&&O(t,4,Math.floor(new Date(n.mtime||Date.now())/1e3)),r){t[3]=8;for(var e=0;e<=r.length;++e)t[e+10]=r.charCodeAt(e)}}(s,n),O(s,a-8,r.d()),O(s,a-4,e),s}var B=function(){function t(t,n){this.c=S(),this.v=1,j.call(this,t,n)}return t.prototype.push=function(t,n){this.c.p(t),j.prototype.push.call(this,t,n)},t.prototype.p=function(t,n){var r=L(t,this.o,this.v&&(this.o.dictionary?6:2),n&&4,this.s);this.v&&(function(t,n){var r=n.level,e=0==r?0:r<6?1:9==r?3:2;if(t[0]=120,t[1]=e<<6|(n.dictionary&&32),t[1]|=31-(t[0]<<8|t[1])%31,n.dictionary){var i=S();i.p(n.dictionary),O(t,2,i.d())}}(r,this.o),this.v=0),n&&O(r,r.length-4,this.c.d()),this.ondata(r,n)},t.prototype.flush=function(){j.prototype.flush.call(this)},t}(),G="undefined"!=typeof TextEncoder&&new TextEncoder,H="undefined"!=typeof TextDecoder&&new TextDecoder;try{H.decode(F,{stream:!0})}catch(t){}var J=function(){function t(t){this.ondata=t}return t.prototype.push=function(t,n){this.ondata||E(5),this.d&&E(4),this.ondata(K(t),this.d=n||!1)},t}();function K(n,r){if(G)return G.encode(n);for(var e=n.length,i=new t(n.length+(n.length>>1)),s=0,a=function(t){i[s++]=t},o=0;o<e;++o){if(s+5>i.length){var h=new t(s+8+(e-o<<1));h.set(i),i=h}var f=n.charCodeAt(o);f<128||r?a(f):f<2048?(a(192|f>>6),a(128|63&f)):f>55295&&f<57344?(a(240|(f=65536+(1047552&f)|1023&n.charCodeAt(++o))>>18),a(128|f>>12&63),a(128|f>>6&63),a(128|63&f)):(a(224|f>>12),a(128|f>>6&63),a(128|63&f))}return b(i,0,s)}const N=new class{constructor(){this._init()}clear(){this._init()}addEvent(t){if(!t)throw new Error("Adding invalid event");const n=this._hasEvents?",":"";this.stream.push(n+t),this._hasEvents=!0}finish(){this.stream.push("]",!0);const t=function(t){let n=0;for(const r of t)n+=r.length;const r=new Uint8Array(n);for(let n=0,e=0,i=t.length;n<i;n++){const i=t[n];r.set(i,e),e+=i.length}return r}(this._deflatedData);return this._init(),t}_init(){this._hasEvents=!1,this._deflatedData=[],this.deflate=new B,this.deflate.ondata=(t,n)=>{this._deflatedData.push(t)},this.stream=new J((t,n)=>{this.deflate.push(t,n)}),this.stream.push("[")}},P={clear:()=>{N.clear()},addEvent:t=>N.addEvent(t),finish:()=>N.finish(),compress:t=>function(t){return q(K(t))}(t)};addEventListener("message",function(t){const n=t.data.method,r=t.data.id,e=t.data.arg;if(n in P&&"function"==typeof P[n])try{const t=P[n](e);postMessage({id:r,method:n,success:!0,response:t})}catch(t){postMessage({id:r,method:n,success:!1,response:t.message}),console.error(t)}}),postMessage({id:void 0,method:"init",success:!0,response:void 0});
34';function zae(){const e=new Blob([Uae]);return URL.createObjectURL(e)}const a5=["log","warn","error"],Rv="[Replay] ";function oS(e,t="info"){Sl({category:"console",data:{logger:"replay"},level:t,message:`${Rv}${e}`},{level:t})}function Bae(){let e=!1,t=!1;const n={exception:()=>{},infoTick:()=>{},setConfig:r=>{e=!!r.captureExceptions,t=!!r.traceInternals}};return dt?(a5.forEach(r=>{n[r]=(...i)=>{Se[r](Rv,...i),t&&oS(i.join(""),BN(r))}}),n.exception=(r,...i)=>{i.length&&n.error&&n.error(...i),Se.error(Rv,r),e?Rk(r,{mechanism:{handled:!0,type:"auto.function.replay.debug"}}):t&&oS(r,"error")},n.infoTick=(...r)=>{Se.log(Rv,...r),t&&setTimeout(()=>oS(r[0]),0)}):a5.forEach(r=>{n[r]=()=>{}}),n}const ft=Bae();class tT extends Error{constructor(){super(`Event buffer exceeded maximum size of ${qk}.`)}}class K9{constructor(){this.events=[],this._totalSize=0,this.hasCheckout=!1,this.waitForCheckout=!1}get hasEvents(){return this.events.length>0}get type(){return"sync"}destroy(){this.events=[]}async addEvent(t){const n=JSON.stringify(t).length;if(this._totalSize+=n,this._totalSize>qk)throw new tT;this.events.push(t)}finish(){return new Promise(t=>{const n=this.events;this.clear(),t(JSON.stringify(n))})}clear(){this.events=[],this._totalSize=0,this.hasCheckout=!1}getEarliestTimestamp(){const t=this.events.map(n=>n.timestamp).sort()[0];return t?Xk(t):null}}class Hae{constructor(t){this._worker=t,this._id=0}ensureReady(){return this._ensureReadyPromise?this._ensureReadyPromise:(this._ensureReadyPromise=new Promise((t,n)=>{this._worker.addEventListener("message",({data:r})=>{r.success?t():n()},{once:!0}),this._worker.addEventListener("error",r=>{n(r)},{once:!0})}),this._ensureReadyPromise)}destroy(){dt&&ft.log("Destroying compression worker"),this._worker.terminate()}postMessage(t,n){const r=this._getAndIncrementId();return new Promise((i,s)=>{const o=({data:a})=>{const c=a;if(c.method===t&&c.id===r){if(this._worker.removeEventListener("message",o),!c.success){dt&&ft.error("Error in compression worker: ",c.response),s(new Error("Error in compression worker"));return}i(c.response)}};this._worker.addEventListener("message",o),this._worker.postMessage({id:r,method:t,arg:n})})}_getAndIncrementId(){return this._id++}}class Vae{constructor(t){this._worker=new Hae(t),this._earliestTimestamp=null,this._totalSize=0,this.hasCheckout=!1,this.waitForCheckout=!1}get hasEvents(){return!!this._earliestTimestamp}get type(){return"worker"}ensureReady(){return this._worker.ensureReady()}destroy(){this._worker.destroy()}addEvent(t){const n=Xk(t.timestamp);(!this._earliestTimestamp||n<this._earliestTimestamp)&&(this._earliestTimestamp=n);const r=JSON.stringify(t);return this._totalSize+=r.length,this._totalSize>qk?Promise.reject(new tT):this._sendEventToWorker(r)}finish(){return this._finishRequest()}clear(){this._earliestTimestamp=null,this._totalSize=0,this.hasCheckout=!1,this._worker.postMessage("clear").then(null,t=>{dt&&ft.exception(t,'Sending "clear" message to worker failed',t)})}getEarliestTimestamp(){return this._earliestTimestamp}_sendEventToWorker(t){return this._worker.postMessage("addEvent",t)}async _finishRequest(){const t=await this._worker.postMessage("finish");return this._earliestTimestamp=null,this._totalSize=0,t}}class Wae{constructor(t){this._fallback=new K9,this._compression=new Vae(t),this._used=this._fallback,this._ensureWorkerIsLoadedPromise=this._ensureWorkerIsLoaded()}get waitForCheckout(){return this._used.waitForCheckout}get type(){return this._used.type}get hasEvents(){return this._used.hasEvents}get hasCheckout(){return this._used.hasCheckout}set hasCheckout(t){this._used.hasCheckout=t}set waitForCheckout(t){this._used.waitForCheckout=t}destroy(){this._fallback.destroy(),this._compression.destroy()}clear(){return this._used.clear()}getEarliestTimestamp(){return this._used.getEarliestTimestamp()}addEvent(t){return this._used.addEvent(t)}async finish(){return await this.ensureWorkerIsLoaded(),this._used.finish()}ensureWorkerIsLoaded(){return this._ensureWorkerIsLoadedPromise}async _ensureWorkerIsLoaded(){try{await this._compression.ensureReady()}catch(t){dt&&ft.exception(t,"Failed to load the compression worker, falling back to simple buffer");return}await this._switchToCompressionWorker()}async _switchToCompressionWorker(){const{events:t,hasCheckout:n,waitForCheckout:r}=this._fallback,i=[];for(const s of t)i.push(this._compression.addEvent(s));this._compression.hasCheckout=n,this._compression.waitForCheckout=r,this._used=this._compression;try{await Promise.all(i),this._fallback.clear()}catch(s){dt&&ft.exception(s,"Failed to add events when switching buffers.")}}}function qae({useCompression:e,workerUrl:t}){if(e&&window.Worker){const n=Kae(t);if(n)return n}return dt&&ft.log("Using simple buffer"),new K9}function Kae(e){try{const t=e||Gae();if(!t)return;dt&&ft.log(`Using compression worker${e?` from ${e}`:""}`);const n=new Worker(t);return new Wae(n)}catch(t){dt&&ft.exception(t,"Failed to create compression worker")}}function Gae(){return typeof __SENTRY_EXCLUDE_REPLAY_WORKER__>"u"||!__SENTRY_EXCLUDE_REPLAY_WORKER__?zae():""}function nT(){try{return"sessionStorage"in un&&!!un.sessionStorage}catch{return!1}}function Yae(e){Jae(),e.session=void 0}
34function Jae(){if(nT())try{un.sessionStorage.removeItem(Vk)}catch{}}function G9(e){return e===void 0?!1:Math.random()<e}function Y_(e){if(nT())try{un.sessionStorage.setItem(Vk,JSON.stringify(e))}catch{}}function Y9(e){const t=Date.now(),n=e.id||Ri(),r=e.started||t,i=e.lastActivity||t,s=e.segmentId||0,o=e.sampled,a=e.previousSessionId,c=e.dirty||!1;return{id:n,started:r,lastActivity:i,segmentId:s,sampled:o,previousSessionId:a,dirty:c}}function Zae(e,t){return G9(e)?"session":t?"buffer":!1}function l5({sessionSampleRate:e,allowBuffering:t,stickySession:n=!1},{previousSessionId:r}={}){const i=Zae(e,t),s=Y9({sampled:i,previousSessionId:r});return n&&Y_(s),s}function Xae(){if(!nT())return null;try{const e=un.sessionStorage.getItem(Vk);if(!e)return null;const t=JSON.parse(e);return dt&&ft.infoTick("Loading existing session"),Y9(t)}catch{return null}}function Gx(e,t,n=+new Date){return e===null||t===void 0||t<0?!0:t===0?!1:e+t<=n}function J9(e,{maxReplayDuration:t,sessionIdleExpire:n,targetTime:r=Date.now()}){return Gx(e.started,t,r)||Gx(e.lastActivity,n,r)}function Z9(e,{sessionIdleExpire:t,maxReplayDuration:n}){return!(!J9(e,{sessionIdleExpire:t,maxReplayDuration:n})||e.sampled==="buffer"&&e.segmentId===0)}function aS({sessionIdleExpire:e,maxReplayDuration:t,previousSessionId:n},r){const i=r.stickySession&&Xae();return i?Z9(i,{sessionIdleExpire:e,maxReplayDuration:t})?(dt&&ft.infoTick("Session in sessionStorage is expired, creating new one..."),l5(r,{previousSessionId:i.id})):i:(dt&&ft.infoTick("Creating new session"),l5(r,{previousSessionId:n}))}function Qae(e){return e.type===xt.Custom}function rT(e,t,n){return Q9(e,t)?(X9(e,t,n),!0):!1}function ele(e,t,n){return Q9(e,t)?X9(e,t,n):Promise.resolve(null)}async function X9(e,t,n){const{eventBuffer:r}=e;if(!r||r.waitForCheckout&&!n)return null;const i=e.recordingMode==="buffer";try{n&&i&&r.clear(),n&&(r.hasCheckout=!0,r.waitForCheckout=!1);const s=e.getOptions(),o=tle(t,s.beforeAddRecordingEvent);return o?await r.addEvent(o):void 0}catch(s){const o=s&&s instanceof tT,a=o?"addEventSizeExceeded":"addEvent",c=$t();if(c){const d=o?"buffer_overflow":"internal_sdk_error";c.recordDroppedEvent(d,"replay")}if(o&&i)return r.clear(),r.waitForCheckout=!0,null;e.handleException(s),await e.stop({reason:a})}}function Q9(e,t){if(!e.eventBuffer||e.isPaused()||!e.isEnabled())return!1;const n=Xk(t.timestamp);return n+e.timeouts.sessionIdlePause<Date.now()?!1:n>e.getContext().initialTimestamp+e.getOptions().maxReplayDuration?(dt&&ft.infoTick(`Skipping event with timestamp ${n} because it is after maxReplayDuration`),!1):!0}function tle(e,t){try{if(typeof t=="function"&&Qae(e))return t(e)}catch(n){return dt&&ft.exception(n,"An error occurred in the `beforeAddRecordingEvent` callback, skipping the event..."),null}return e}function iT(e){return!e.type}function Yx(e){return e.type==="transaction"}function nle(e){return e.type==="replay_event"}function c5(e){return e.type==="feedback"}function rle(e){return(t,n)=>{if(!e.isEnabled()||!iT(t)&&!Yx(t))return;const r=n.statusCode;if(!(!r||r<200||r>=300)){if(Yx(t)){ile(e,t);return}sle(e,t)}}}function ile(e,t){const n=e.getContext();t.contexts?.trace?.trace_id&&n.traceIds.size<100&&n.traceIds.add(t.contexts.trace.trace_id)}function sle(e,t){const n=e.getContext();if(t.event_id&&n.errorIds.size<100&&n.errorIds.add(t.event_id),e.recordingMode!=="buffer"||!t.tags||!t.tags.replayId)return;const{beforeErrorSampling:r}=e.getOptions();typeof r=="function"&&!r(t)||$m(async()=>{try{await e.sendBufferedReplayOrFlush()}catch(i){e.handleException(i)}})}function ole(e){return t=>{!e.isEnabled()||!iT(t)||ale(e,t)}}function ale(e,t){const n=t.exception?.values?.[0]?.value;if(typeof n=="string"&&(n.match(/(reactjs\.org\/docs\/error-decoder\.html\?invariant=|react\.dev\/errors\/)(418|419|422|423|425)/)||n.match(/(does not match server-rendered HTML|Hydration failed because)/i))){const r=Gs({category:"replay.hydrate-error",data:{url:Sf()}});Fm(e,r)}}function lle(e){const t=$t();t&&t.on("beforeAddBreadcrumb",n=>cle(e,n))}function cle(e,t){if(!e.isEnabled()||!e$(t))return;const n=ule(t);n&&Fm(e,n)}function ule(e){return!e$(e)||["fetch","xhr","sentry.event","sentry.transaction"].includes(e.category)||e.category.startsWith("ui.")?null:e.category==="console"?dle(e):Gs(e)}function dle(e){const t=e.data?.arguments;if(!Array.isArray(t)||t.length===0)return Gs(e);let n=!1;const r=t.map(i=>{if(!i)return i;if(typeof i=="string")return i.length>zy?(n=!0,`${i.slice(0,zy)}…`):i;if(typeof i=="object")try{const s=vs(i,7);return JSON.stringify(s).length>zy?(n=!0,`${JSON.stringify(s,null,2).slice(0,zy)}…`):s}catch{}return i});return Gs({...e,data:{...e.data,arguments:r,...n?{_meta:{warnings:["CONSOLE_ARG_TRUNCATED"]}}:{}}})}function e$(e){return!!e.category}function fle(e,t){return e.type||!e.exception?.values?.length?!1:!!t.originalException?.__rrweb__}function t$(){const e=tn().getPropagationContext().dsc;e&&delete e.replay_id;const t=Yr();if(t){const n=ra(t);delete n.replay_id}}function hle(e,t){e.triggerUserActivity(),e.addUpdate(()=>t.timestamp?(e.throttledAddEvent({type:xt.Custom,timestamp:t.timestamp*1e3,data:{tag:"breadcrumb",payload:{timestamp:t.timestamp,type:"default",category:"sentry.feedback",data:{feedbackId:t.event_id}}}}),!1):!0)}function ple(e,t){return e.recordingMode!=="buffer"||t.message===Wk||!t.exception||t.type?!1:G9(e.getOptions().errorSampleRate)}function mle(e){return Object.assign((t,n)=>
34{if(!e.isEnabled()||e.isPaused())return t;if(nle(t))return delete t.breadcrumbs,t;if(!iT(t)&&!Yx(t)&&!c5(t))return t;if(!e.checkAndHandleExpiredSession())return t$(),t;if(c5(t))return e.flush(),t.contexts.feedback.replay_id=e.getSessionId(),hle(e,t),t;if(fle(t,n)&&!e.getOptions()._experiments.captureExceptions)return dt&&ft.log("Ignoring error from rrweb internals",t),null;const i=ple(e,t);if((i||e.recordingMode==="session")&&(t.tags={...t.tags,replayId:e.getSessionId()}),i&&e.recordingMode==="buffer"&&e.session?.sampled==="buffer"){const o=e.session;o.dirty=!0,e.getOptions().stickySession&&Y_(o)}return t},{id:"Replay"})}function J_(e,t){return t.map(({type:n,start:r,end:i,name:s,data:o})=>{const a=e.throttledAddEvent({type:xt.Custom,timestamp:r,data:{tag:"performanceSpan",payload:{op:n,description:s,startTimestamp:r,endTimestamp:i,data:o}}});return typeof a=="string"?Promise.resolve(null):a})}function gle(e){const{from:t,to:n}=e,r=Date.now()/1e3;return{type:"navigation.push",start:r,end:r,name:n,data:{previous:t}}}function yle(e){return t=>{if(!e.isEnabled())return;const n=gle(t);n!==null&&(e.getContext().urls.push(n.name),e.triggerUserActivity(),e.addUpdate(()=>(J_(e,[n]),!1)))}}function vle(e,t){return dt&&e.getOptions()._experiments.traceInternals?!1:ane(t,$t())}function n$(e,t){e.isEnabled()&&t!==null&&(vle(e,t.name)||e.addUpdate(()=>(J_(e,[t]),!0)))}function Z_(e){if(!e)return;const t=new TextEncoder;try{if(typeof e=="string")return t.encode(e).length;if(e instanceof URLSearchParams)return t.encode(e.toString()).length;if(e instanceof FormData){const n=m9(e);return t.encode(n).length}if(e instanceof Blob)return e.size;if(e instanceof ArrayBuffer)return e.byteLength}catch{}}function r$(e){if(!e)return;const t=parseInt(e,10);return isNaN(t)?void 0:t}function R0(e,t){if(!e)return{headers:{},size:void 0,_meta:{warnings:[t]}};const n={...e._meta},r=n.warnings||[];return n.warnings=[...r,t],e._meta=n,e}function i$(e,t){if(!t)return null;const{startTimestamp:n,endTimestamp:r,url:i,method:s,statusCode:o,request:a,response:c}=t;return{type:e,start:n/1e3,end:r/1e3,name:i,data:{method:s,statusCode:o,request:a,response:c}}}function Vp(e){return{headers:{},size:e,_meta:{warnings:["URL_SKIPPED"]}}}function pl(e,t,n){if(!t&&Object.keys(e).length===0)return;if(!t)return{headers:e};if(!n)return{headers:e,size:t};const r={headers:e,size:t},{body:i,warnings:s}=_le(n);return r.body=i,s?.length&&(r._meta={warnings:s}),r}function Jx(e,t){return Object.entries(e).reduce((n,[r,i])=>{const s=r.toLowerCase();return t.includes(s)&&e[r]&&(n[s]=i),n},{})}function _le(e){if(!e||typeof e!="string")return{body:e};const t=e.length>HI,n=wle(e);if(t){const r=e.slice(0,HI);return n?{body:r,warnings:["MAYBE_JSON_TRUNCATED"]}:{body:`${r}…`,warnings:["TEXT_TRUNCATED"]}}if(n)try{return{body:JSON.parse(e)}}catch{}return{body:e}}function wle(e){const t=e[0],n=e[e.length-1];return t==="["&&n==="]"||t==="{"&&n==="}"}function P0(e,t){const n=ble(e);return Vo(n,t)}function ble(e,t=un.document.baseURI){if(e.startsWith("http://")||e.startsWith("https://")||e.startsWith(un.location.origin))return e;const n=new URL(e,t);if(n.origin!==new URL(t).origin)return e;const r=n.href;return!e.endsWith("/")&&r.endsWith("/")?r.slice(0,-1):r}async function Sle(e,t,n){try{const r=await xle(e,t,n),i=i$("resource.fetch",r);n$(n.replay,i)}catch(r){dt&&ft.exception(r,"Failed to capture fetch breadcrumb")}}function Ele(e,t){const{input:n,response:r}=t,i=n?y9(n):void 0,s=Z_(i),o=r?r$(r.headers.get("content-length")):void 0;s!==void 0&&(e.data.request_body_size=s),o!==void 0&&(e.data.response_body_size=o)}async function xle(e,t,n){const r=Date.now(),{startTimestamp:i=r,endTimestamp:s=r}=t,{url:o,method:a,status_code:c=0,request_body_size:d,response_body_size:f}=e.data,p=P0(o,n.networkDetailAllowUrls)&&!P0(o,n.networkDetailDenyUrls),m=p?Cle(n,t.input,d):Vp(d),v=await kle(p,n,t.response,f);return{startTimestamp:i,endTimestamp:s,url:o,method:a,statusCode:c,request:m,response:v}}function Cle({networkCaptureBodies:e,networkRequestHeaders:t},n,r){const i=n?Ple(n,t):{};if(!e)return pl(i,r,void 0);const s=y9(n),[o,a]=g9(s,ft),c=pl(i,r,o);return a?R0(c,a):c}async function kle(e,{networkCaptureBodies:t,networkResponseHeaders:n},r,i){if(!e&&i!==void 0)return Vp(i);const s=r?s$(r.headers,n):{};if(!r||!t&&i!==void 0)return pl(s,i,void 0);const[o,a]=await Rle(r),c=Tle(o,{networkCaptureBodies:t,responseBodySize:i,captureDetails:e,headers:s});return a?R0(c,a):c}function Tle(e,{networkCaptureBodies:t,responseBodySize:n,captureDetails:r,headers:i}){try{const s=e?.length&&n===void 0?Z_(e):n;return r?t?pl(i,s,e):pl(i,s,void 0):Vp(s)}catch(s){return dt&&ft.exception(s,"Failed to serialize response body"),pl(i,n,void 0)}}async function Rle(e){const t=Ole(e);if(!t)return[void 0,"BODY_PARSE_ERROR"];try{return[await Ale(t)]}catch(n){return n instanceof Error&&n.message.indexOf("Timeout")>-1?(dt&&ft.warn("Parsing text body from response timed out"),[void 0,"BODY_PARSE_TIMEOUT"]):(dt&&ft.exception(n,"Failed to get text body from response"),[void 0,"BODY_PARSE_ERROR"])}}function s$(e,t){const n={};return t.forEach(r=>{e.get(r)&&(n[r]=e.get(r))}),n}
34function Ple(e,t){return e.length===1&&typeof e[0]!="string"?u5(e[0],t):e.length===2?u5(e[1],t):{}}function u5(e,t){if(!e)return{};const n=e.headers;return n?n instanceof Headers?s$(n,t):Array.isArray(n)?{}:Jx(n,t):{}}function Ole(e){try{return e.clone()}catch(t){dt&&ft.exception(t,"Failed to clone response body")}}function Ale(e){return new Promise((t,n)=>{const r=$m(()=>n(new Error("Timeout while trying to read response body")),500);Ile(e).then(i=>t(i),i=>n(i)).finally(()=>clearTimeout(r))})}async function Ile(e){return await e.text()}async function Mle(e,t,n){try{const r=Lle(e,t,n),i=i$("resource.xhr",r);n$(n.replay,i)}catch(r){dt&&ft.exception(r,"Failed to capture xhr breadcrumb")}}function Dle(e,t){const{xhr:n,input:r}=t;if(!n)return;const i=Z_(r),s=n.getResponseHeader("content-length")?r$(n.getResponseHeader("content-length")):jle(n.response,n.responseType);i!==void 0&&(e.data.request_body_size=i),s!==void 0&&(e.data.response_body_size=s)}function Lle(e,t,n){const r=Date.now(),{startTimestamp:i=r,endTimestamp:s=r,input:o,xhr:a}=t,{url:c,method:d,status_code:f=0,request_body_size:p,response_body_size:m}=e.data;if(!c)return null;if(!a||!P0(c,n.networkDetailAllowUrls)||P0(c,n.networkDetailDenyUrls)){const I=Vp(p),k=Vp(m);return{startTimestamp:i,endTimestamp:s,url:c,method:d,statusCode:f,request:I,response:k}}const v=a[Pc],w=v?Jx(v.request_headers,n.networkRequestHeaders):{},_=Jx(v9(a),n.networkResponseHeaders),[b,C]=n.networkCaptureBodies?g9(o,ft):[void 0],[P,D]=n.networkCaptureBodies?Nle(a):[void 0],F=pl(w,p,b),R=pl(_,m,P);return{startTimestamp:i,endTimestamp:s,url:c,method:d,statusCode:f,request:C?R0(F,C):F,response:D?R0(R,D):R}}function Nle(e){const t=[];try{return[e.responseText]}catch(n){t.push(n)}try{return $le(e.response,e.responseType)}catch(n){t.push(n)}return dt&&ft.warn("Failed to get xhr response body",...t),[void 0]}function $le(e,t){try{if(typeof e=="string")return[e];if(e instanceof Document)return[e.body.outerHTML];if(t==="json"&&e&&typeof e=="object")return[JSON.stringify(e)];if(!e)return[void 0]}catch(n){return dt&&ft.exception(n,"Failed to serialize body",e),[void 0,"BODY_PARSE_ERROR"]}return dt&&ft.log("Skipping network body because of body type",e),[void 0,"UNPARSEABLE_BODY_TYPE"]}function jle(e,t){try{const n=t==="json"&&e&&typeof e=="object"?JSON.stringify(e):e;return Z_(n)}catch{return}}function Fle(e){const t=$t();try{const{networkDetailAllowUrls:n,networkDetailDenyUrls:r,networkCaptureBodies:i,networkRequestHeaders:s,networkResponseHeaders:o}=e.getOptions(),a={replay:e,networkDetailAllowUrls:n,networkDetailDenyUrls:r,networkCaptureBodies:i,networkRequestHeaders:s,networkResponseHeaders:o};t&&t.on("beforeAddBreadcrumb",(c,d)=>Ule(a,c,d))}catch{}}function Ule(e,t,n){if(t.data)try{zle(t)&&Hle(n)&&(Dle(t,n),Mle(t,n,e)),Ble(t)&&Vle(n)&&(Ele(t,n),Sle(t,n,e))}catch(r){dt&&ft.exception(r,"Error when enriching network breadcrumb")}}function zle(e){return e.category==="xhr"}function Ble(e){return e.category==="fetch"}function Hle(e){return e?.xhr}function Vle(e){return e?.response}function Wle(e){const t=$t();f9(Sae(e)),W_(yle(e)),lle(e),Fle(e);const n=mle(e);Rte(n),t&&(t.on("beforeSendEvent",ole(e)),t.on("afterSendEvent",rle(e)),t.on("createDsc",r=>{const i=e.getSessionId();i&&e.isEnabled()&&e.recordingMode==="session"&&e.checkAndHandleExpiredSession()&&(r.replay_id=i)}),t.on("spanStart",r=>{e.lastActiveSpan=r}),t.on("spanEnd",r=>{e.lastActiveSpan=r}),t.on("beforeSendFeedback",async(r,i)=>{const s=e.getSessionId();i?.includeReplay&&e.isEnabled()&&s&&r.contexts?.feedback&&(r.contexts.feedback.source==="api"&&await e.sendBufferedReplayOrFlush(),r.contexts.feedback.replay_id=s)}),t.on("openFeedbackWidget",async()=>{await e.sendBufferedReplayOrFlush()}))}async function qle(e){try{return Promise.all(J_(e,[Kle(un.performance.memory)]))}catch{return[]}}function Kle(e){const{jsHeapSizeLimit:t,totalJSHeapSize:n,usedJSHeapSize:r}=e,i=Date.now()/1e3;return{type:"memory",name:"memory",start:i,end:i,data:{memory:{jsHeapSizeLimit:t,totalJSHeapSize:n,usedJSHeapSize:r}}}}function Gle(e,t,n){return hne(e,t,{...n,setTimeoutImpl:$m})}const Wy=zt.navigator;function Yle(){return/iPhone|iPad|iPod/i.test(Wy?.userAgent??"")||/Macintosh/i.test(Wy?.userAgent??"")&&Wy?.maxTouchPoints&&Wy?.maxTouchPoints>1?{sampling:{mousemove:!1}}:{}}function Jle(e){let t=!1;return(n,r)=>{if(!e.checkAndHandleExpiredSession()){dt&&ft.warn("Received replay event after session expired.");return}const i=r||!t;t=!0,e.clickDetector&&yae(e.clickDetector,n),e.addUpdate(()=>{if(e.recordingMode==="buffer"&&i&&e.setInitialState(),!rT(e,n,i))return!0;
34if(!i)return!1;const s=e.session;if(Xle(e,i),e.recordingMode==="buffer"&&s&&e.eventBuffer&&!s.dirty){const o=e.eventBuffer.getEarliestTimestamp();o&&(dt&&ft.log(`Updating session start time to earliest event in buffer to ${new Date(o)}`),s.started=o,e.getOptions().stickySession&&Y_(s))}return s?.previousSessionId||e.recordingMode==="session"&&e.flush(),!0})}}function Zle(e){const t=e.getOptions();return{type:xt.Custom,timestamp:Date.now(),data:{tag:"options",payload:{shouldRecordCanvas:e.isRecordingCanvas(),sessionSampleRate:t.sessionSampleRate,errorSampleRate:t.errorSampleRate,useCompressionOption:t.useCompression,blockAllMedia:t.blockAllMedia,maskAllText:t.maskAllText,maskAllInputs:t.maskAllInputs,useCompression:e.eventBuffer?e.eventBuffer.type==="worker":!1,networkDetailHasUrls:t.networkDetailAllowUrls.length>0,networkCaptureBodies:t.networkCaptureBodies,networkRequestHasHeaders:t.networkRequestHeaders.length>0,networkResponseHasHeaders:t.networkResponseHeaders.length>0}}}}function Xle(e,t){!t||!e.session||e.session.segmentId!==0||rT(e,Zle(e),!1)}function Qle(e){if(!e)return null;try{return e.nodeType===e.ELEMENT_NODE?e:e.parentElement}catch{return null}}function ece(e,t,n,r){return Ll(yN(e,xk(e),r,n),[[{type:"replay_event"},e],[{type:"replay_recording",length:typeof t=="string"?new TextEncoder().encode(t).length:t.length},t]])}function tce({recordingData:e,headers:t}){let n;const r=`${JSON.stringify(t)} 35`;if(typeof e=="string")n=`${r}${e}`;else{const s=new TextEncoder().encode(r);n=new Uint8Array(s.length+e.length),n.set(s),n.set(e,s.length)}return n}async function nce({client:e,scope:t,replayId:n,event:r}){const i=typeof e._integrations=="object"&&e._integrations!==null&&!Array.isArray(e._integrations)?Object.keys(e._integrations):void 0,s={event_id:n,integrations:i};e.emit("preprocessEvent",r,s);const o=await EN(e.getOptions(),r,s,t,e,uo());if(!o)return null;e.emit("postprocessEvent",o,s),o.platform=o.platform||"javascript";const a=e.getSdkMetadata(),{name:c,version:d,settings:f}=a?.sdk||{};return o.sdk={...o.sdk,name:c||"sentry.javascript.unknown",version:d||"0.0.0",settings:f},o}async function rce({recordingData:e,replayId:t,segmentId:n,eventContext:r,timestamp:i,session:s}){const o=tce({recordingData:e,headers:{segment_id:n}}),{urls:a,errorIds:c,traceIds:d,initialTimestamp:f}=r,p=$t(),m=tn(),v=p?.getTransport(),w=p?.getDsn();if(!p||!v||!w||!s.sampled)return Promise.resolve({});const _={type:Mse,replay_start_timestamp:f/1e3,timestamp:i/1e3,error_ids:c,trace_ids:d,urls:a,replay_id:t,segment_id:n,replay_type:s.sampled},b=await nce({scope:m,client:p,replayId:t,event:_});if(!b)return p.recordDroppedEvent("event_processor","replay"),dt&&ft.log("An event processor returned `null`, will not send event."),Promise.resolve({});delete b.sdkProcessingMetadata;const C=ece(b,o,w,p.getOptions().tunnel);let P;try{P=await v.send(C)}catch(F){const R=new Error(Wk);try{R.cause=F}catch{}throw R}if(typeof P.statusCode=="number"&&(P.statusCode<200||P.statusCode>=300))throw new o$(P.statusCode);const D=MN({},P);if(IN(D,"replay"))throw new sT(D);return P}class o$ extends Error{constructor(t){super(`Transport returned status code ${t}`)}}class sT extends Error{constructor(t){super("Rate limit hit"),this.rateLimits=t}}async function a$(e,t={count:0,interval:Fse}){const{recordingData:n,onError:r}=e;if(n.length)try{return await rce(e),!0}catch(i){if(i instanceof o$||i instanceof sT)throw i;if(Pk("Replays",{_retryCount:t.count}),r&&r(i),t.count>=Use){const s=new Error(`${Wk} - max retries exceeded`);try{s.cause=i}catch{}throw s}return t.interval*=++t.count,new Promise((s,o)=>{$m(async()=>{try{await a$(e,t),s(!0)}catch(a){o(a)}},t.interval)})}}const l$="__THROTTLED",ice="__SKIPPED";function sce(e,t,n){const r=new Map,i=a=>{const c=a-n;r.forEach((d,f)=>{f<c&&r.delete(f)})},s=()=>[...r.values()].reduce((a,c)=>a+c,0);let o=!1;return(...a)=>{const c=Math.floor(Date.now()/1e3);if(i(c),s()>=t){const f=o;return o=!0,f?ice:l$}o=!1;const d=r.get(c)||0;return r.set(c,d+1),e(...a)}}class oce{constructor({options:t,recordingOptions:n}){this.eventBuffer=null,this.performanceEntries=[],this.replayPerformanceEntries=[],this.recordingMode="session",this.timeouts={sessionIdlePause:Dse,sessionIdleExpire:Lse},this._lastActivity=Date.now(),this._isEnabled=!1,this._isPaused=!1,this._requiresManualStart=!1,this._hasInitializedCoreListeners=!1,this._context={errorIds:new Set,traceIds:new Set,urls:[],initialTimestamp:Date.now(),initialUrl:""},this._recordingOptions=n,this._options=t,this._debouncedFlush=Gle(()=>this._flush(),this._options.flushMinDelay,{maxWait:this._options.flushMaxDelay}),this._throttledAddEvent=sce((o,a)=>ele(this,o,a),300,5);const{slowClickTimeout:r,slowClickIgnoreSelectors:i}=this.getOptions(),s=r?{threshold:Math.min(zse,r),timeout:r,scrollTimeout:Bse,ignoreSelector:i?i.join(","):""}:void 0;if(s&&(this.clickDetector=new hae(this,s)),dt){const o=t._experiments;ft.setConfig({captureExceptions:!!o.captureExceptions,traceInternals:!!o.traceInternals})}this._handleVisibilityChange=()=>{un.document.visibilityState==="visible"?this._doChangeToForegroundTasks():this._doChangeToBackgroun
35dTasks()},this._handleWindowBlur=()=>{const o=Gs({category:"ui.blur"});this._doChangeToBackgroundTasks(o)},this._handleWindowFocus=()=>{const o=Gs({category:"ui.focus"});this._doChangeToForegroundTasks(o)},this._handleKeyboardEvent=o=>{kae(this,o)}}getContext(){return this._context}isEnabled(){return this._isEnabled}isPaused(){return this._isPaused}isRecordingCanvas(){return!!this._canvas}getOptions(){return this._options}handleException(t){dt&&ft.exception(t),this._options.onError&&this._options.onError(t)}initializeSampling(t){const{errorSampleRate:n,sessionSampleRate:r}=this._options,i=n<=0&&r<=0;if(this._requiresManualStart=i,!i){if(this._initializeSessionForSampling(t),!this.session){dt&&ft.exception(new Error("Unable to initialize and create session"));return}this.session.sampled!==!1&&(this.recordingMode=this.session.sampled==="buffer"&&this.session.segmentId===0?"buffer":"session",dt&&ft.infoTick(`Starting replay in ${this.recordingMode} mode`),this._initializeRecording())}}start(){if(this._isEnabled&&this.recordingMode==="session"){dt&&ft.log("Recording is already in progress");return}if(this._isEnabled&&this.recordingMode==="buffer"){dt&&ft.log("Buffering is in progress, call `flush()` to save the replay");return}dt&&ft.infoTick("Starting replay in session mode"),this._updateUserActivity();const t=aS({maxReplayDuration:this._options.maxReplayDuration,sessionIdleExpire:this.timeouts.sessionIdleExpire},{stickySession:this._options.stickySession,sessionSampleRate:1,allowBuffering:!1});this.session=t,this.recordingMode="session",this._initializeRecording()}startBuffering(){if(this._isEnabled){dt&&ft.log("Buffering is in progress, call `flush()` to save the replay");return}dt&&ft.infoTick("Starting replay in buffer mode");const t=aS({sessionIdleExpire:this.timeouts.sessionIdleExpire,maxReplayDuration:this._options.maxReplayDuration},{stickySession:this._options.stickySession,sessionSampleRate:0,allowBuffering:!0});this.session=t,this.recordingMode="buffer",this._initializeRecording()}startRecording(){try{const t=this._canvas;this._stopRecording=qo({...this._recordingOptions,...this.recordingMode==="buffer"?{checkoutEveryNms:jse}:this._options._experiments.continuousCheckout&&{checkoutEveryNms:Math.max(36e4,this._options._experiments.continuousCheckout)},emit:Jle(this),...Yle(),onMutation:this._onMutationHandler.bind(this),...t?{recordCanvas:t.recordCanvas,getCanvasManager:t.getCanvasManager,sampling:t.sampling,dataURLOptions:t.dataURLOptions}:{}})}catch(t){this.handleException(t)}}stopRecording(){try{return this._stopRecording&&(this._stopRecording(),this._stopRecording=void 0),!0}catch(t){return this.handleException(t),!1}}async stop({forceFlush:t=!1,reason:n}={}){if(this._isEnabled){this._isEnabled=!1,this.recordingMode="buffer";try{dt&&ft.log(`Stopping Replay${n?` triggered by ${n}`:""}`),t$(),this._removeListeners(),this.stopRecording(),this._debouncedFlush.cancel(),t&&await this._flush({force:!0}),this.eventBuffer?.destroy(),this.eventBuffer=null,Yae(this)}catch(r){this.handleException(r)}}}pause(){this._isPaused||(this._isPaused=!0,this.stopRecording(),dt&&ft.log("Pausing replay"))}resume(){!this._isPaused||!this._checkSession()||(this._isPaused=!1,this.startRecording(),dt&&ft.log("Resuming replay"))}async sendBufferedReplayOrFlush({continueRecording:t=!0}={}){if(this.recordingMode==="session")return this.flushImmediate();const n=Date.now();dt&&ft.log("Converting buffer to session"),await this.flushImmediate();const r=this.stopRecording();!t||!r||this.recordingMode!=="session"&&(this.recordingMode="session",this.session&&(this.session.dirty=!1,this._updateUserActivity(n),this._updateSessionActivity(n),this._maybeSaveSession()),this.startRecording())}addUpdate(t){const n=t();this.recordingMode==="buffer"||!this._isEnabled||n!==!0&&this._debouncedFlush()}triggerUserActivity(){if(this._updateUserActivity(),!this._stopRecording){if(!this._checkSession())return;this.resume();return}this.checkAndHandleExpiredSession(),this._updateSessionActivity()}updateUserActivity(){this._updateUserActivity(),this._updateSessionActivity()}conditionalFlush(){return this.recordingMode==="buffer"?Promise.resolve():this.flushImmediate()}flush(){return this._debouncedFlush()}flushImmediate(){return this._debouncedFlush(),this._debouncedFlush.flush()}cancelFlush(){this._debouncedFlush.cancel()}getSessionId(t){if(!(t&&this.session?.sampled===!1))return this.session?.id}
35checkAndHandleExpiredSession(){if(this._lastActivity&&Gx(this._lastActivity,this.timeouts.sessionIdlePause)&&this.session&&this.session.sampled==="session"){this.pause();return}return!!this._checkSession()}setInitialState(){const t=`${un.location.pathname}${un.location.hash}${un.location.search}`,n=`${un.location.origin}${t}`;this.performanceEntries=[],this.replayPerformanceEntries=[],this._clearContext(),this._context.initialUrl=n,this._context.initialTimestamp=Date.now(),this._context.urls.push(n)}throttledAddEvent(t,n){const r=this._throttledAddEvent(t,n);if(r===l$){const i=Gs({category:"replay.throttled"});this.addUpdate(()=>!rT(this,{type:oae,timestamp:i.timestamp||0,data:{tag:"breadcrumb",payload:i,metric:!0}}))}return r}getCurrentRoute(){const t=this.lastActiveSpan||Yr(),n=t&&Lr(t),i=(n&&Wt(n).data||{})[Es];if(!(!n||!i||!["route","custom"].includes(i)))return Wt(n).description}_initializeRecording(){this.setInitialState(),this._updateSessionActivity(),this.eventBuffer=qae({useCompression:this._options.useCompression,workerUrl:this._options.workerUrl}),this._removeListeners(),this._addListeners(),this._isEnabled=!0,this._isPaused=!1,this.startRecording()}_initializeSessionForSampling(t){const n=this._options.errorSampleRate>0,r=aS({sessionIdleExpire:this.timeouts.sessionIdleExpire,maxReplayDuration:this._options.maxReplayDuration,previousSessionId:t},{stickySession:this._options.stickySession,sessionSampleRate:this._options.sessionSampleRate,allowBuffering:n});this.session=r}_checkSession(){if(!this.session)return!1;const t=this.session;return Z9(t,{sessionIdleExpire:this.timeouts.sessionIdleExpire,maxReplayDuration:this._options.maxReplayDuration})?(this._refreshSession(t),!1):!0}async _refreshSession(t){this._isEnabled&&(await this.stop({reason:"refresh session"}),this.initializeSampling(t.id))}_addListeners(){try{un.document.addEventListener("visibilitychange",this._handleVisibilityChange),un.addEventListener("blur",this._handleWindowBlur),un.addEventListener("focus",this._handleWindowFocus),un.addEventListener("keydown",this._handleKeyboardEvent),this.clickDetector&&this.clickDetector.addListeners(),this._hasInitializedCoreListeners||(Wle(this),this._hasInitializedCoreListeners=!0)}catch(t){this.handleException(t)}this._performanceCleanupCallback=Fae(this)}_removeListeners(){try{un.document.removeEventListener("visibilitychange",this._handleVisibilityChange),un.removeEventListener("blur",this._handleWindowBlur),un.removeEventListener("focus",this._handleWindowFocus),un.removeEventListener("keydown",this._handleKeyboardEvent),this.clickDetector&&this.clickDetector.removeListeners(),this._performanceCleanupCallback&&this._performanceCleanupCallback()}catch(t){this.handleException(t)}}_doChangeToBackgroundTasks(t){!this.session||J9(this.session,{maxReplayDuration:this._options.maxReplayDuration,sessionIdleExpire:this.timeouts.sessionIdleExpire})||(t&&this._createCustomBreadcrumb(t),this.conditionalFlush())}_doChangeToForegroundTasks(t){if(!this.session)return;if(!this.checkAndHandleExpiredSession()){dt&&ft.log("Document has become active, but session has expired");return}t&&this._createCustomBreadcrumb(t)}_updateUserActivity(t=Date.now()){this._lastActivity=t}_updateSessionActivity(t=Date.now()){this.session&&(this.session.lastActivity=t,this._maybeSaveSession())}_createCustomBreadcrumb(t){this.addUpdate(()=>{this.throttledAddEvent({type:xt.Custom,timestamp:t.timestamp||0,data:{tag:"breadcrumb",payload:t}})})}_addPerformanceEntries(){let t=Oae(this.performanceEntries).concat(this.replayPerformanceEntries);if(this.performanceEntries=[],this.replayPerformanceEntries=[],this._requiresManualStart){const n=this._context.initialTimestamp/1e3;t=t.filter(r=>r.start>=n)}return Promise.all(J_(this,t))}_clearContext(){this._context.errorIds.clear(),this._context.traceIds.clear(),this._context.urls=[]}_updateInitialTimestampFromEventBuffer(){const{session:t,eventBuffer:n}=this;if(!t||!n||this._requiresManualStart||t.segmentId)return;const r=n.getEarliestTimestamp();r&&r<this._context.initialTimestamp&&(this._context.initialTimestamp=r)}
35_popEventContext(){const t={initialTimestamp:this._context.initialTimestamp,initialUrl:this._context.initialUrl,errorIds:Array.from(this._context.errorIds),traceIds:Array.from(this._context.traceIds),urls:this._context.urls};return this._clearContext(),t}async _runFlush(){const t=this.getSessionId();if(!this.session||!this.eventBuffer||!t){dt&&ft.error("No session or eventBuffer found to flush.");return}if(await this._addPerformanceEntries(),!!this.eventBuffer?.hasEvents&&(await qle(this),!!this.eventBuffer&&t===this.getSessionId()))try{this._updateInitialTimestampFromEventBuffer();const n=Date.now();if(n-this._context.initialTimestamp>this._options.maxReplayDuration+3e4)throw new Error("Session is too long, not sending replay");const r=this._popEventContext(),i=this.session.segmentId++;this._maybeSaveSession();const s=await this.eventBuffer.finish();await a$({replayId:t,recordingData:s,segmentId:i,eventContext:r,session:this.session,timestamp:n,onError:o=>this.handleException(o)})}catch(n){this.handleException(n),this.stop({reason:"sendReplay"});const r=$t();if(r){const i=n instanceof sT?"ratelimit_backoff":"send_error";r.recordDroppedEvent(i,"replay")}}}async _flush({force:t=!1}={}){if(!this._isEnabled&&!t)return;if(!this.checkAndHandleExpiredSession()){dt&&ft.error("Attempting to finish replay event after session expired.");return}if(!this.session)return;const n=this.session.started,i=Date.now()-n;this._debouncedFlush.cancel();const s=i<this._options.minReplayDuration,o=i>this._options.maxReplayDuration+5e3;if(s||o){dt&&ft.log(`Session duration (${Math.floor(i/1e3)}s) is too ${s?"short":"long"}, not sending replay.`),s&&this._debouncedFlush();return}const a=this.eventBuffer;a&&this.session.segmentId===0&&!a.hasCheckout&&dt&&ft.log("Flushing initial segment without checkout.");const c=!!this._flushLock;this._flushLock||(this._flushLock=this._runFlush());try{await this._flushLock}catch(d){this.handleException(d)}finally{this._flushLock=void 0,c&&this._debouncedFlush()}}_maybeSaveSession(){this.session&&this._options.stickySession&&Y_(this.session)}_onMutationHandler(t){const{ignoreMutations:n}=this._options._experiments;if(n?.length&&t.some(a=>{const c=Qle(a.target),d=n.join(",");return c?.matches(d)}))return!1;const r=t.length,i=this._options.mutationLimit,s=this._options.mutationBreadcrumbLimit,o=i&&r>i;
35if(r>s||o){const a=Gs({category:"replay.mutations",data:{count:r,limit:o}});this._createCustomBreadcrumb(a)}return o?(this.stop({reason:"mutationLimit",forceFlush:this.recordingMode==="session"}),!1):!0}}function Oh(e,t){return[...e,...t].join(",")}function ace({mask:e,unmask:t,block:n,unblock:r,ignore:i}){const s=["base","iframe[srcdoc]:not([src])"],o=Oh(e,[".sentry-mask","[data-sentry-mask]"]),a=Oh(t,[]);return{maskTextSelector:o,unmaskTextSelector:a,blockSelector:Oh(n,[".sentry-block","[data-sentry-block]",...s]),unblockSelector:Oh(r,[]),ignoreSelector:Oh(i,[".sentry-ignore","[data-sentry-ignore]",'input[type="file"]'])}}function lce({el:e,key:t,maskAttributes:n,maskAllText:r,privacyOptions:i,value:s}){return!r||i.unmaskTextSelector&&e.matches(i.unmaskTextSelector)?s:n.includes(t)||t==="value"&&e.tagName==="INPUT"&&["submit","button"].includes(e.getAttribute("type")||"")?s.replace(/[\S]/g,"*"):s}const d5='img,image,svg,video,object,picture,embed,map,audio,link[rel="icon"],link[rel="apple-touch-icon"]',cce=["content-length","content-type","accept"];let f5=!1;const uce=(e=>new dce(e));class dce{constructor({flushMinDelay:t=Nse,flushMaxDelay:n=$se,minReplayDuration:r=Hse,maxReplayDuration:i=VI,stickySession:s=!0,useCompression:o=!0,workerUrl:a,_experiments:c={},maskAllText:d=!0,maskAllInputs:f=!0,blockAllMedia:p=!0,mutationBreadcrumbLimit:m=750,mutationLimit:v=1e4,slowClickTimeout:w=7e3,slowClickIgnoreSelectors:_=[],networkDetailAllowUrls:b=[],networkDetailDenyUrls:C=[],networkCaptureBodies:P=!0,networkRequestHeaders:D=[],networkResponseHeaders:F=[],mask:R=[],maskAttributes:I=["title","placeholder","aria-label"],unmask:k=[],block:L=[],unblock:B=[],ignore:A=[],maskFn:V,beforeAddRecordingEvent:K,beforeErrorSampling:W,onError:U}={}){this.name="Replay";const q=ace({mask:R,unmask:k,block:L,unblock:B,ignore:A});if(this._recordingOptions={maskAllInputs:f,maskAllText:d,maskInputOptions:{password:!0},maskTextFn:V,maskInputFn:V,maskAttributeFn:(z,x,N)=>lce({maskAttributes:I,maskAllText:d,privacyOptions:q,key:z,value:x,el:N}),...q,slimDOMOptions:"all",inlineStylesheet:!0,inlineImages:!1,collectFonts:!0,errorHandler:z=>{try{z.__rrweb__=!0}catch{}},recordCrossOriginIframes:!!c.recordCrossOriginIframes},this._initialOptions={flushMinDelay:t,flushMaxDelay:n,minReplayDuration:Math.min(r,Vse),maxReplayDuration:Math.min(i,VI),stickySession:s,useCompression:o,workerUrl:a,blockAllMedia:p,maskAllInputs:f,maskAllText:d,mutationBreadcrumbLimit:m,mutationLimit:v,slowClickTimeout:w,slowClickIgnoreSelectors:_,networkDetailAllowUrls:b,networkDetailDenyUrls:C,networkCaptureBodies:P,networkRequestHeaders:h5(D),networkResponseHeaders:h5(F),beforeAddRecordingEvent:K,beforeErrorSampling:W,onError:U,_experiments:c},this._initialOptions.blockAllMedia&&(this._recordingOptions.blockSelector=this._recordingOptions.blockSelector?`${this._recordingOptions.blockSelector},${d5}`:d5,this._recordingOptions.ignoreCSSAttributes=new Set(["background-image"])),this._isInitialized&&Mx())throw new Error("Multiple Sentry Session Replay instances are not supported");this._isInitialized=!0}get _isInitialized(){return f5}set _isInitialized(t){f5=t}afterAllSetup(t){!Mx()||this._replay||(this._setup(t),this._initialize(t))}start(){this._replay&&this._replay.start()}startBuffering(){this._replay&&this._replay.startBuffering()}stop(){return this._replay?this._replay.stop({forceFlush:this._replay.recordingMode==="session"}):Promise.resolve()}flush(t){return this._replay?this._replay.isEnabled()?this._replay.sendBufferedReplayOrFlush(t):(this._replay.start(),Promise.resolve()):Promise.resolve()}getReplayId(t){if(this._replay?.isEnabled())return this._replay.getSessionId(t)}getRecordingMode(){if(this._replay?.isEnabled())return this._replay.recordingMode}_initialize(t){this._replay&&(this._maybeLoadFromReplayCanvasIntegration(t),this._replay.initializeSampling())}_setup(t){const n=fce(this._initialOptions,t);this._replay=new oce({options:n,recordingOptions:this._recordingOptions})}_maybeLoadFromReplayCanvasIntegration(t){try{const n=t.getIntegrationByName("ReplayCanvas");if(!n)return;this._replay._canvas=n.getOptions()}catch{}}}function fce(e,t){const n=t.getOptions(),r={sessionSampleRate:0,errorSampleRate:0,...e},i=Jc(n.replaysSessionSampleRate),s=Jc(n.replaysOnErrorSampleRate);return i==null&&s==null&&mu(()=>{console.warn("Replay is disabled because neither `replaysSessionSampleRate` nor `replaysOnErrorSampleRate` are set.")}),i!=null&&(r.sessionSampleRate=i),s!=null&&(r.errorSampleRate=s),r}function h5(e){return[...cce,...e.map(t=>t.toLowerCase())]}function hce(e){return e.split(",").some(t=>t.trim().startsWith("sentry-"))}function c$(e){try{return new URL(e,qt.location.origin).href}catch{return}}function pce(e){return e.entryType==="resource"&&"initiatorType"in e&&typeof e.nextHopProtocol=="string"&&(e.initiatorType==="fetch"||e.
35initiatorType==="xmlhttprequest")}function u$(e){try{return new Headers(e)}catch{return}}const p5=new WeakMap,lS=new Map,d$={traceFetch:!0,traceXHR:!0,enableHTTPTimings:!0,trackFetchStreamPerformance:!1};function mce(e,t){const{traceFetch:n,traceXHR:r,trackFetchStreamPerformance:i,shouldCreateSpanForRequest:s,enableHTTPTimings:o,tracePropagationTargets:a,onRequestSpanStart:c,onRequestSpanEnd:d}={...d$,...t},f=typeof s=="function"?s:w=>!0,p=w=>gce(w,a),m={},v=e.getOptions().propagateTraceparent;n&&(e.addEventProcessor(w=>(w.type==="transaction"&&w.spans&&w.spans.forEach(_=>{if(_.op==="http.client"){const b=lS.get(_.span_id);b&&(_.timestamp=b/1e3,lS.delete(_.span_id))}}),w)),i&&Gne(w=>{if(w.response){const _=p5.get(w.response);_&&w.endTimestamp&&lS.set(_,w.endTimestamp)}}),qN(w=>{const _=jne(w,f,p,m,{propagateTraceparent:v,onRequestSpanEnd:d});if(w.response&&w.fetchData.__span&&p5.set(w.response,w.fetchData.__span),_){const b=c$(w.fetchData.url),C=b?Uc(b).host:void 0;_.setAttributes({"http.url":b,"server.address":C}),o&&m5(_),c?.(_,{headers:w.headers})}})),r&&p9(w=>{const _=yce(w,f,p,m,v,d);_&&(o&&m5(_),c?.(_,{headers:u$(w.xhr.__sentry_xhr_v3__?.request_headers)}))})}function m5(e){const{url:t}=Wt(e).data;if(!t||typeof t!="string")return;const n=Xc("resource",({entries:r})=>{r.forEach(i=>{pce(i)&&i.name.endsWith(t)&&(e.setAttributes(d9(i)),setTimeout(n))})})}function gce(e,t){const n=Sf();if(n){let r,i;try{r=new URL(e,n),i=new URL(n).origin}catch{return!1}const s=r.origin===i;return t?Vo(r.toString(),t)||s&&Vo(r.pathname,t):s}else{const r=!!e.match(/^\/(?!\/)/);return t?Vo(e,t):r}}function yce(e,t,n,r,i,s){const o=e.xhr,a=o?.[Pc];if(!o||o.__sentry_own_request__||!a)return;const{url:c,method:d}=a,f=Cs()&&t(c);if(e.endTimestamp&&f){const C=o.__sentry_xhr_span_id__;if(!C)return;const P=r[C];P&&a.status_code!==void 0&&(tN(P,a.status_code),P.end(),s?.(P,{headers:u$(v9(o)),error:e.error}),delete r[C]);return}const p=c$(c),m=Uc(p||c),v=one(c),w=!!Yr(),_=f&&w?kf({name:`${d} ${v}`,attributes:{url:c,type:"xhr","http.method":d,"http.url":p,"server.address":m?.host,[cr]:"auto.http.browser",[na]:"http.client",...m?.search&&{"http.query":m?.search},...m?.hash&&{"http.fragment":m?.hash}}}):new bl;o.__sentry_xhr_span_id__=_.spanContext().spanId,r[o.__sentry_xhr_span_id__]=_,n(c)&&vce(o,Cs()&&w?_:void 0,i);const b=$t();return b&&b.emit("beforeOutgoingRequestSpan",_,e),_}function vce(e,t,n){const{"sentry-trace":r,baggage:i,traceparent:s}=zN({span:t,propagateTraceparent:n});r&&_ce(e,r,i,s)}function _ce(e,t,n,r){const i=e.__sentry_xhr_v3__?.request_headers;if(!(i?.["sentry-trace"]||!e.setRequestHeader))try{if(e.setRequestHeader("sentry-trace",t),r&&!i?.traceparent&&e.setRequestHeader("traceparent",r),n){const s=i?.baggage;(!s||!hce(s))&&e.setRequestHeader("baggage",n)}}catch{}}function wce(){qt.document?qt.document.addEventListener("visibilitychange",()=>{const e=Yr();if(!e)return;const t=Lr(e);if(qt.document.hidden&&t){const n="cancelled",{op:r,status:i}=Wt(t);rs&&Se.log(`[Tracing] Transaction: ${n} -> since tab moved to the background, op: ${r}`),i||t.setStatus({code:rr,message:n}),t.setAttribute("sentry.cancellation_reason","document.hidden"),t.end()}}):rs&&Se.warn("[Tracing] Could not set up background tab detection due to lack of global document")}const bce=3600,f$="sentry_previous_trace",Sce="sentry.previous_trace";function Ece(e,{linkPreviousTrace:t,consistentTraceSampling:n}){const r=t==="session-storage";let i=r?kce():void 0;e.on("spanStart",o=>{if(Lr(o)!==o)return;const a=tn().getPropagationContext();i=xce(i,o,a),r&&Cce(i)});let s=!0;n&&e.on("beforeSampling",o=>{if(!i)return;const a=tn(),c=a.getPropagationContext();if(s&&c.parentSpanId){s=!1;return}a.setPropagationContext({...c,dsc:{...c.dsc,sample_rate:String(i.sampleRate),sampled:String(Zx(i.spanContext))},sampleRand:i.sampleRand}),o.parentSampled=Zx(i.spanContext),o.parentSampleRate=i.sampleRate,o.spanAttributes={...o.spanAttributes,[eN]:i.sampleRate}})}function xce(e,t,n){const r=Wt(t);function i(){try{return Number(n.dsc?.sample_rate)??Number(r.data?.[vk])}catch{return 0}}const s={spanContext:t.spanContext(),startTimestamp:r.start_timestamp,sampleRate:i(),sampleRand:n.sampleRand};if(!e)return s;const o=e.spanContext;return o.traceId===r.trace_id?e:(Date.now()/1e3-e.startTimestamp<=bce&&(rs&&Se.log(`Adding previous_trace ${o} link to span ${{op:r.op,...t.spanContext()}}`),t.addLink({context:o,attributes:{[eee]:"previous_trace"}}),t.setAttribute(Sce,`${o.traceId}-${o.spanId}-${Zx(o)?1:0}`)),s)}function Cce(e){try{qt.sessionStorage.setItem(f$,JSON.stringify(e))}catch(t){rs&&Se.warn("Could not store previous trace in sessionStorage",t)}}function kce(){try{const e=qt.sessionStorage?.getItem(f$);return JSON.parse(e)}catch{return}}function Zx(e){return e.traceFlags===1}const Tce="BrowserTracing",Rce={...Ev,instrumentNavigation:!0,instrumentPageLoad:!0,markBackgroun
35dSpan:!0,enableLongTask:!0,enableLongAnimationFrame:!0,enableInp:!0,enableElementTiming:!0,ignoreResourceSpans:[],ignorePerformanceApiSpans:[],detectRedirects:!0,linkPreviousTrace:"in-memory",consistentTraceSampling:!1,enableReportPageLoaded:!1,_experiments:{},...d$},Pce=((e={})=>{const t={name:void 0,source:void 0},n=qt.document,{enableInp:r,enableElementTiming:i,enableLongTask:s,enableLongAnimationFrame:o,_experiments:{enableInteractions:a,enableStandaloneClsSpans:c,enableStandaloneLcpSpans:d},beforeStartSpan:f,idleTimeout:p,finalTimeout:m,childSpanTimeout:v,markBackgroundSpan:w,traceFetch:_,traceXHR:b,trackFetchStreamPerformance:C,shouldCreateSpanForRequest:P,enableHTTPTimings:D,ignoreResourceSpans:F,ignorePerformanceApiSpans:R,instrumentPageLoad:I,instrumentNavigation:k,detectRedirects:L,linkPreviousTrace:B,consistentTraceSampling:A,enableReportPageLoaded:V,onRequestSpanStart:K,onRequestSpanEnd:W}={...Rce,...e};let U,q,z;function x(N,M,E=!0){const O=M.op==="pageload",H=M.name,Z=f?f(M):M,X=Z.attributes||{};if(H!==Z.name&&(X[Es]="custom",Z.attributes=X),!E){const le=gu();kf({...Z,startTime:le}).end(le);return}t.name=Z.name,t.source=X[Es];const te=SN(Z,{idleTimeout:p,finalTimeout:m,childSpanTimeout:v,disableAutoFinish:O,beforeSpanEnd:le=>{U?.(),rie(le,{recordClsOnPageloadSpan:!c,recordLcpOnPageloadSpan:!d,ignoreResourceSpans:F,ignorePerformanceApiSpans:R}),y5(N,void 0);const ye=tn(),xe=ye.getPropagationContext();ye.setPropagationContext({...xe,traceId:te.spanContext().traceId,sampled:Dl(te),dsc:ra(le)}),O&&(z=void 0)},trimIdleSpanEndTimestamp:!V});O&&V&&(z=te),y5(N,te);function oe(){n&&["interactive","complete"].includes(n.readyState)&&N.emit("idleSpanEnableAutoFinish",te)}O&&!V&&n&&(n.addEventListener("readystatechange",()=>{oe()}),oe())}return{name:Tce,setup(N){if(Pee(),U=Jre({recordClsStandaloneSpans:c||!1,recordLcpStandaloneSpans:d||!1,client:N}),r&&Rie(),i&&mie(),o&&zt.PerformanceObserver&&PerformanceObserver.supportedEntryTypes&&PerformanceObserver.supportedEntryTypes.includes("long-animation-frame")?Xre():s&&Zre(),a&&Qre(),L&&n){const E=()=>{q=yr()};addEventListener("click",E,{capture:!0}),addEventListener("keydown",E,{capture:!0,passive:!0})}function M(){const E=Wp(N);E&&!Wt(E).timestamp&&(rs&&Se.log(`[Tracing] Finishing current active span with op: ${Wt(E).op}`),E.setAttribute(jp,"cancelled"),E.end())}N.on("startNavigationSpan",(E,O)=>{if($t()!==N)return;if(O?.isRedirect){rs&&Se.warn("[Tracing] Detected redirect, navigation span will not be the root span, but a child span."),x(N,{op:"navigation.redirect",...E},!1);return}q=void 0,M(),uo().setPropagationContext({traceId:ta(),sampleRand:Math.random(),propagationSpanId:Cs()?void 0:Wo()});const H=tn();H.setPropagationContext({traceId:ta(),sampleRand:Math.random(),propagationSpanId:Cs()?void 0:Wo()}),H.setSDKProcessingMetadata({normalizedRequest:void 0}),x(N,{op:"navigation",...E,parentSpan:null,forceTransaction:!0})}),N.on("startPageLoadSpan",(E,O={})=>{if($t()!==N)return;M();const H=O.sentryTrace||g5("sentry-trace"),Z=O.baggage||g5("baggage"),X=wee(H,Z),te=tn();te.setPropagationContext(X),Cs()||(te.getPropagationContext().propagationSpanId=Wo()),te.setSDKProcessingMetadata({normalizedRequest:Dk()}),x(N,{op:"pageload",...E})}),N.on("endPageloadSpan",()=>{V&&z&&(z.setAttribute(jp,"reportPageLoaded"),z.end())})},afterAllSetup(N){let M=Sf();if(B!=="off"&&Ece(N,{linkPreviousTrace:B,consistentTraceSampling:A}),qt.location){if(I){const E=pi();Oce(N,{name:qt.location.pathname,startTime:E?E/1e3:void 0,attributes:{[Es]:"url",[cr]:"auto.pageload.browser"}})}k&&W_(({to:E,from:O})=>{if(O===void 0&&M?.indexOf(E)!==-1){M=void 0;return}M=void 0;const H=Mk(E),Z=Wp(N),X=Z&&L&&Mce(Z,q);Ace(N,{name:H?.pathname||qt.location.pathname,attributes:{[Es]:"url",[cr]:"auto.navigation.browser"}},{url:E,isRedirect:X})})}w&&wce(),a&&Ice(N,p,m,v,t),r&&Aie(),mce(N,{traceFetch:_,traceXHR:b,trackFetchStreamPerformance:C,tracePropagationTargets:N.getOptions().tracePropagationTargets,shouldCreateSpanForRequest:P,enableHTTPTimings:D,onRequestSpanStart:K,onRequestSpanEnd:W})}}});function Oce(e,t,n){e.emit("startPageLoadSpan",t,n),tn().setTransactionName(t.name);const r=Wp(e);return r&&e.emit("afterStartPageLoadSpan",r),r}function Ace(e,t,n){const{url:r,isRedirect:i}=n||{};e.emit("beforeStartNavigationSpan",t,{isRedirect:i}),e.emit("startNavigationSpan",t,{isRedirect:i});const s=tn();return s.setTransactionName(t.name),r&&!i&&s.setSDKProcessingMetadata({normalizedRequest:{...Dk(),url:r}}),Wp(e)}function g5(e){return qt.document?.querySelector(`meta[name=${e}]`)?.getAttribute("content")||void 0}function Ice(e,t,n,r,i){const s=qt.document;let o;const a=()=>{const c="ui.action.click",d=Wp(e);if(d){const f=Wt(d).op;
35if(["navigation","pageload"].includes(f)){rs&&Se.warn(`[Tracing] Did not create ${c} span because a pageload or navigation span is in progress.`);return}}if(o&&(o.setAttribute(jp,"interactionInterrupted"),o.end(),o=void 0),!i.name){rs&&Se.warn(`[Tracing] Did not create ${c} transaction because _latestRouteName is missing.`);return}o=SN({name:i.name,op:c,attributes:{[Es]:i.source||"url"}},{idleTimeout:t,finalTimeout:n,childSpanTimeout:r})};s&&addEventListener("click",a,{capture:!0})}const h$="_sentry_idleSpan";function Wp(e){return e[h$]}function y5(e,t){Pi(e,h$,t)}const v5=1.5;function Mce(e,t){const n=Wt(e),r=gu(),i=n.start_timestamp;return!(r-i>v5||t&&r-t<=v5)}function Dce(e){const t={...e};return UN(t,"react"),Pk("react",{version:g.version}),Ise(t)}const Lce="https://32fe489093c4e0d5b14bf8cc5e1b16a6@o4510744058920960.ingest.us.sentry.io/4510747705802752",_5="production",cS=!1,Nce={warn:(...e)=>cS,error:(...e)=>cS,info:(...e)=>cS},$ce=()=>{Dce({dsn:Lce,environment:_5,enabled:_5!=="development",integrations:[Pce(),uce()],tracesSampleRate:.1,replaysSessionSampleRate:.1,replaysOnErrorSampleRate:1})},ia=(e,t)=>{Nce.error(e,t),t&&Pk("additional",t),Rk(e)},jce=e=>g.createElement("svg",{width:481,height:488,viewBox:"0 0 481 488",fill:"none",xmlns:"http://www.w3.org/2000/svg",...e},g.createElement("mask",{id:"mask0_1708_12218",style:{maskType:"alpha"},maskUnits:"userSpaceOnUse",x:1,y:0,width:480,height:480},g.createElement("rect",{width:480,height:480,transform:"translate(1)",fill:"url(#paint0_radial_1708_12218)"})),g.createElement("g",{mask:"url(#mask0_1708_12218)"},g.createElement("circle",{cx:241,cy:240,r:47.5,stroke:"#E9EAEB"}),g.createElement("circle",{cx:241,cy:240,r:79.5,stroke:"#E9EAEB"}),g.createElement("circle",{cx:241,cy:240,r:111.5,stroke:"#E9EAEB"}),g.createElement("circle",{cx:241,cy:240,r:143.5,stroke:"#E9EAEB"}),g.createElement("circle",{cx:241,cy:240,r:143.5,stroke:"#E9EAEB"}),g.createElement("circle",{cx:241,cy:240,r:175.5,stroke:"#E9EAEB"}),g.createElement("circle",{cx:241,cy:240,r:207.5,stroke:"#E9EAEB"}),g.createElement("circle",{cx:241,cy:240,r:239.5,stroke:"#E9EAEB"}),g.createElement("g",{filter:"url(#filter0_dii_1708_12218)"},g.createElement("rect",{x:213,y:212,width:56,height:56,rx:28,fill:"white"}),g.createElement("rect",{x:213.5,y:212.5,width:55,height:55,rx:27.5,stroke:"#E9EAEB"}),g.createElement("path",{d:"M244.973 228.501C245.792 228.555 246.433 229.219 246.523 230.006L246.541 230.236C246.556 230.509 246.562 230.892 246.555 231.257C246.55 231.504 246.539 231.755 246.52 231.971C246.502 232.165 246.473 232.396 246.409 232.559C246.216 233.049 245.724 233.511 245.138 233.575L245.083 233.578L238.03 233.58L238.011 233.579C237.625 233.564 237.286 233.376 237.043 233.143C236.83 232.938 236.657 232.666 236.58 232.365L236.553 232.234C236.513 231.981 236.499 231.516 236.498 231.09C236.497 230.658 236.51 230.2 236.538 229.952C236.618 229.231 237.217 228.622 237.925 228.52L237.995 228.515L244.938 228.5L244.973 228.501Z",fill:"white",stroke:"#E1E3EA",strokeLinejoin:"bevel"}),g.createElement("g",{filter:"url(#filter1_i_1708_12218)"},g.createElement("path",{d:"M249.851 231.645C249.087 231.028 248.013 230.827 247.082 231.127C247.233 232.277 246.804 233.624 245.74 234.062C245.294 234.246 244.797 234.247 244.314 234.245C242.541 234.239 240.767 234.233 238.995 234.228C238.212 234.225 237.53 234.338 236.874 233.854C236.396 233.501 235.869 232.904 235.869 232.267V231.064H234.363C233.235 231.064 231.959 232.615 232.001 233.739V236.827C232.001 237.145 232.001 237.464 232.002 237.783V239.904C232.012 239.904 232.02 239.905 232.029 239.905C232.081 242.607 232.173 245.324 232.071 247.982C231.927 249.266 233.228 251 234.53 251H248.416C249.717 251 251.019 249.266 250.874 247.982C250.772 245.324 250.865 242.607 250.916 239.905C250.925 239.905 250.934 239.904 250.944 239.904V237.784C250.945 237.463 250.946 237.144 250.944 236.824C250.944 235.088 251.375 232.875 249.851 231.645ZM244.687 239.5L238.27 239.496C237.412 239.297 237.38 238.189 238.228 237.941L244.73 237.935C245.637 238.148 245.598 239.346 244.686 239.501L244.687 239.5Z",fill:"white"})),g.createElement("path",{d:"M238.313 238.44C238.154 238.506 238.107 238.626 238.109 238.723C238.112 238.822 238.168 238.941 238.338 238.996L244.636 238.999C244.734 238.976 244.791 238.935 244.825 238.896C244.865 238.848 244.888 238.788 244.89 238.725C244.892 238.661 244.873 238.599 244.835 238.549C244.804 238.508 244.751 238.464 244.658 238.435L238.313 238.44ZM251.415 239.931C251.363 242.639 251.273 245.329 251.374 247.963C251.451 248.767 251.093 249.634 250.579 250.283C250.061 250.938 249.281 251.5 248.416 251.5H234.529C233.664 251.5 232.885 250.938 232.366 250.283C231.852 249.634 231.494 248.767 231.571 247.963C231.673 245.329 231.582 242.639 231.53 239.931L231.502 239.903V237.784L231.501 23
356.827V233.619C231.523 232.925 231.895 232.198 232.364 231.653C232.861 231.077 233.588 230.564 234.363 230.564H235.868L236.368 231.064V232.268C236.368 232.448 236.445 232.657 236.602 232.88C236.756 233.1 236.966 233.3 237.171 233.451C237.658 233.811 238.107 233.724 238.995 233.728H238.996C240.769 233.733 242.543 233.739 244.316 233.745C244.816 233.747 245.211 233.739 245.55 233.6C245.929 233.443 246.22 233.116 246.404 232.671C246.589 232.223 246.651 231.688 246.586 231.192L246.929 230.651C248.021 230.3 249.27 230.534 250.165 231.256C251.076 231.992 251.378 233.01 251.467 234C251.511 234.494 251.504 234.998 251.487 235.474C251.47 235.96 251.443 236.402 251.443 236.824V239.903L251.415 239.931Z",stroke:"#E1E3EA",strokeLinejoin:"bevel"})),g.createElement("g",{opacity:.7},g.createElement("g",{filter:"url(#filter2_ddi_1708_12218)"},g.createElement("rect",{x:322,y:169,width:35,height:35,rx:17.5,fill:"white"}),g.createElement("rect",{x:322,y:169,width:35,height:35,rx:17.5,fill:"#25BD7B"}),g.createElement("rect",{x:322,y:169,width:35,height:35,rx:17.5,fill:"url(#paint1_linear_1708_12218)",fillOpacity:.2})),g.createElement("g",{filter:"url(#filter3_di_1708_12218)"},g.createElement("path",{d:"M334.943 185.301L337.859 188.16L344.057 182.084",stroke:"white",strokeWidth:3.03819,strokeLinecap:"round"}))),g.createElement("g",{opacity:.7},g.createElement("g",{filter:"url(#filter4_ddi_1708_12218)"},g.createElement("rect",{x:221,y:109,width:35,height:35,rx:17.5,fill:"white"}),g.createElement("rect",{x:221,y:109,width:35,height:35,rx:17.5,fill:"#213860"}),g.createElement("rect",{x:221,y:109,width:35,height:35,rx:17.5,fill:"url(#paint2_linear_1708_12218)",fillOpacity:.2})),g.createElement("g",{filter:"url(#filter5_di_1708_12218)"},g.createElement("path",{d:"M244.232 124.771C244.565 124.963 244.565 125.444 244.232 125.637L235.036 130.946C234.703 131.138 234.287 130.898 234.287 130.513L234.287 119.895C234.287 119.51 234.703 119.27 235.036 119.462L244.232 124.771Z",fill:"white"}))),g.createElement("g",{opacity:.7},g.createElement("g",{filter:"url(#filter6_ddi_1708_12218)"},g.createElement("rect",{x:128,y:167.271,width:34.2857,height:34.2857,rx:17.1429,fill:"white"}),g.createElement("rect",{x:128,y:167.271,width:34.2857,height:34.2857,rx:17.1429,fill:"#25BD7B"}),g.createElement("rect",{x:128,y:167.271,width:34.2857,height:34.2857,rx:17.1429,fill:"url(#paint3_linear_1708_12218)",fillOpacity:.2})),g.createElement("g",{filter:"url(#filter7_di_1708_12218)"},g.createElement("path",{d:"M140.679 183.237L143.536 186.038L149.607 180.086",stroke:"white",strokeWidth:2.97619,strokeLinecap:"round"})),g.createElement("g",{filter:"url(#filter8_d_1708_12218)"},g.createElement("rect",{x:152.127,y:166,width:15.873,height:15.873,rx:7.93651,fill:"white"}),g.createElement("rect",{x:152.127,y:166,width:15.873,height:15.873,rx:7.93651,fill:"#25BD7B"}),g.createElement("rect",{x:152.127,y:166,width:15.873,height:15.873,rx:7.93651,fill:"#213860"})),g.createElement("path",{d:"M161.084 173.537C161.36 173.732 161.36 174.141 161.084 174.336L158.137 176.416C157.812 176.645 157.365 176.413 157.365 176.016L157.365 171.856C157.365 171.46 157.812 171.228 158.137 171.457L161.084 173.537Z",fill:"white"}),g.createElement("path",{d:"M163.54 173.523C163.843 173.716 163.843 174.157 163.54 174.35L160.18 176.483C159.855 176.69 159.429 176.456 159.429 176.07L159.429 171.803C159.429 171.417 159.855 171.183 160.18 171.39L163.54 173.523Z",fill:"white"})),g.createElement("g",{opacity:.7},g.createElement("g",{filter:"url(#filter9_d_1708_12218)"},g.createElement("rect",{x:318,y:272,width:38,height:38,rx:10,fill:"white"}),g.createElement("rect",{x:318.5,y:272.5,width:37,height:37,rx:9.5,stroke:"#E9EAEF"})),g.createElement("g",{opacity:.2},g.createElement("rect",{x:322,y:276,width:30,height:30,rx:6,fill:"#0073B6"}),g.createElement("rect",{x:322,y:276,width:30,height:30,rx:6,fill:"url(#paint4_linear_1708_12218)",fillOpacity:.2})),g.createElement("path",{d:"M336.749 299.788C336.371 299.788 336.022 299.614 335.788 299.312C335.556 299.008 335.476 298.622 335.566 298.248L336.76 293.388H333.28C332.474 293.388 331.818 292.72 331.818 291.9C331.818 291.776 331.834 291.652 331.863 291.532L334.073 282.72C334.211 282.172 334.696 281.788 335.252 281.788H338.308C338.677 281.788 339.023 281.956 339.255 282.25C339.487 282.544 339.575 282.922 339.494 283.29L338.444 288.188H341.602C342.272 288.188 342.818 288.744 342.818 289.426C342.818 289.63 342.767 289.834 342.671 290.016L337.817 299.138C337.605 299.54 337.195 299.788 336.749 299.788L336.749 299.788Z",fill:"#0073B6"})),g.createElement("g",{opacity:.7}
35,g.createElement("g",{filter:"url(#filter10_d_1708_12218)"},g.createElement("rect",{x:225,y:328,width:38,height:38,rx:10,fill:"white"}),g.createElement("rect",{x:225.5,y:328.5,width:37,height:37,rx:9.5,stroke:"#E9EAEF"})),g.createElement("g",{opacity:.2},g.createElement("rect",{x:229,y:332,width:30,height:30,rx:6,fill:"#00A75F"}),g.createElement("rect",{x:229,y:332,width:30,height:30,rx:6,fill:"url(#paint5_linear_1708_12218)",fillOpacity:.2})),g.createElement("path",{d:"M242.931 356C242.553 356 242.204 355.826 241.97 355.524C241.738 355.22 241.658 354.834 241.748 354.46L242.942 349.6H239.462C238.656 349.6 238 348.932 238 348.112C238 347.988 238.015 347.864 238.045 347.744L240.255 338.932C240.392 338.384 240.878 338 241.434 338H244.49C244.859 338 245.205 338.168 245.437 338.462C245.668 338.755 245.757 339.134 245.676 339.502L244.626 344.4H247.784C248.454 344.4 249 344.956 249 345.638C249 345.842 248.949 346.046 248.853 346.228L243.999 355.35C243.787 355.752 243.376 356 242.931 356L242.931 356Z",fill:"#00A75F"})),g.createElement("g",{opacity:.7},g.createElement("g",{filter:"url(#filter11_d_1708_12218)"},g.createElement("rect",{x:128,y:276,width:38,height:38,rx:10,fill:"white"}),g.createElement("rect",{x:128.5,y:276.5,width:37,height:37,rx:9.5,stroke:"#E9EAEF"})),g.createElement("g",{opacity:.2},g.createElement("rect",{x:132,y:280,width:30,height:30,rx:6,fill:"#F48D27"}),g.createElement("rect",{x:132,y:280,width:30,height:30,rx:6,fill:"url(#paint6_linear_1708_12218)",fillOpacity:.2})),g.createElement("path",{d:"M145.931 304C145.553 304 145.204 303.826 144.97 303.524C144.738 303.22 144.658 302.834 144.748 302.46L145.942 297.6H142.462C141.656 297.6 141 296.932 141 296.112C141 295.988 141.015 295.864 141.045 295.744L143.255 286.932C143.392 286.384 143.878 286 144.434 286H147.49C147.859 286 148.205 286.168 148.437 286.462C148.668 286.755 148.757 287.134 148.676 287.502L147.626 292.4H150.784C151.454 292.4 152 292.956 152 293.638C152 293.842 151.949 294.046 151.853 294.228L146.999 303.35C146.787 303.752 146.376 304 145.931 304L145.931 304Z",fill:"#F48D27"}))),g.createElement("defs",null,g.createElement("filter",{id:"filter0_dii_1708_12218",x:211,y:211,width:60,height:60,filterUnits:"userSpaceOnUse",colorInterpolationFilters:"sRGB"},g.createElement("feFlood",{floodOpacity:0,result:"BackgroundImageFix"}),g.createElement("feColorMatrix",{in:"SourceAlpha",type:"matrix",values:"0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 127 0",result:"hardAlpha"}),g.createElement("feOffset",{dy:1}),g.createElement("feGaussianBlur",{stdDeviation:1}),g.createElement("feComposite",{in2:"hardAlpha",operator:"out"}),g.createElement("feColorMatrix",{type:"matrix",values:"0 0 0 0 0.0392157 0 0 0 0 0.0496732 0 0 0 0 0.0705882 0 0 0 0.05 0"}),g.createElement("feBlend",{mode:"normal",in2:"BackgroundImageFix",result:"effect1_dropShadow_1708_12218"}),g.createElement("feBlend",{mode:"normal",in:"SourceGraphic",in2:"effect1_dropShadow_1708_12218",result:"shape"}),g.createElement("feColorMatrix",{in:"SourceAlpha",type:"matrix",values:"0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 127 0",result:"hardAlpha"}),g.createElement("feOffset",{dy:-2}),g.createElement("feComposite",{in2:"hardAlpha",operator:"arithmetic",k2:-1,k3:1}),g.createElement("feColorMatrix",{type:"matrix",values:"0 0 0 0 0.0392157 0 0 0 0 0.0496732 0 0 0 0 0.0705882 0 0 0 0.05 0"}),g.createElement("feBlend",{mode:"normal",in2:"shape",result:"effect2_innerShadow_1708_12218"}),g.createElement("feColorMatrix",{in:"SourceAlpha",type:"matrix",values:"0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 127 0",result:"hardAlpha"}),g.createElement("feMorphology",{radius:1,operator:"erode",in:"SourceAlpha",result:"effect3_innerShadow_1708_12218"}),g.createElement("feOffset",null),g.createElement("feComposite",{in2:"hardAlpha",operator:"arithmetic",k2:-1,k3:1}),g.createElement("feColorMatrix",{type:"matrix",values:"0 0 0 0 0.0392157 0 0 0 0 0.0496732 0 0 0 0 0.0705882 0 0 0 0.18 0"}),g.createElement("feBlend",{mode:"normal",in2:"effect2_innerShadow_1708_12218",result:"effect3_innerShadow_1708_12218"})),g.createElement("filter",{id:"filter1_i_1708_12218",x:231,y:229.99,width:21,height:22.0098,filterUnits:"userSpaceOnUse",colorInterpolationFilters:"sRGB"}
35,g.createElement("feFlood",{floodOpacity:0,result:"BackgroundImageFix"}),g.createElement("feBlend",{mode:"normal",in:"SourceGraphic",in2:"BackgroundImageFix",result:"shape"}),g.createElement("feColorMatrix",{in:"SourceAlpha",type:"matrix",values:"0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 127 0",result:"hardAlpha"}),g.createElement("feOffset",null),g.createElement("feGaussianBlur",{stdDeviation:2}),g.createElement("feComposite",{in2:"hardAlpha",operator:"arithmetic",k2:-1,k3:1}),g.createElement("feColorMatrix",{type:"matrix",values:"0 0 0 0 0.898039 0 0 0 0 1 0 0 0 0 0.972549 0 0 0 0.25 0"}),g.createElement("feBlend",{mode:"normal",in2:"shape",result:"effect1_innerShadow_1708_12218"})),g.createElement("filter",{id:"filter2_ddi_1708_12218",x:319.407,y:166.407,width:40.1852,height:40.1852,filterUnits:"userSpaceOnUse",colorInterpolationFilters:"sRGB"},g.createElement("feFlood",{floodOpacity:0,result:"BackgroundImageFix"}),g.createElement("feColorMatrix",{in:"SourceAlpha",type:"matrix",values:"0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 127 0",result:"hardAlpha"}),g.createElement("feMorphology",{radius:2.59259,operator:"dilate",in:"SourceAlpha",result:"effect1_dropShadow_1708_12218"}),g.createElement("feOffset",null),g.createElement("feComposite",{in2:"hardAlpha",operator:"out"}),g.createElement("feColorMatrix",{type:"matrix",values:"0 0 0 0 0.884941 0 0 0 0 0.954476 0 0 0 0 0.927821 0 0 0 1 0"}),g.createElement("feBlend",{mode:"normal",in2:"BackgroundImageFix",result:"effect1_dropShadow_1708_12218"}),g.createElement("feColorMatrix",{in:"SourceAlpha",type:"matrix",values:"0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 127 0",result:"hardAlpha"}),g.createElement("feMorphology",{radius:1.01273,operator:"erode",in:"SourceAlpha",result:"effect2_dropShadow_1708_12218"}),g.createElement("feOffset",{dy:1.01273}),g.createElement("feGaussianBlur",{stdDeviation:1.01273}),g.createElement("feComposite",{in2:"hardAlpha",operator:"out"}),g.createElement("feColorMatrix",{type:"matrix",values:"0 0 0 0 0.188235 0 0 0 0 0.192157 0 0 0 0 0.239216 0 0 0 0.25 0"}),g.createElement("feBlend",{mode:"normal",in2:"effect1_dropShadow_1708_12218",result:"effect2_dropShadow_1708_12218"}),g.createElement("feBlend",{mode:"normal",in:"SourceGraphic",in2:"effect2_dropShadow_1708_12218",result:"shape"}),g.createElement("feColorMatrix",{in:"SourceAlpha",type:"matrix",values:"0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 127 0",result:"hardAlpha"}),g.createElement("feOffset",{dy:-2.53183}),g.createElement("feComposite",{in2:"hardAlpha",operator:"arithmetic",k2:-1,k3:1}),g.createElement("feColorMatrix",{type:"matrix",values:"0 0 0 0 0.0951048 0 0 0 0 0.628711 0 0 0 0 0.397014 0 0 0 1 0"}),g.createElement("feBlend",{mode:"normal",in2:"shape",result:"effect3_innerShadow_1708_12218"})),g.createElement("filter",{id:"filter3_di_1708_12218",x:331.398,y:179.552,width:16.2037,height:15.2937,filterUnits:"userSpaceOnUse",colorInterpolationFilters:"sRGB"},g.createElement("feFlood",{floodOpacity:0,result:"BackgroundImageFix"}),g.createElement("feColorMatrix",{in:"SourceAlpha",type:"matrix",values:"0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 127 0",result:"hardAlpha"}),g.createElement("feOffset",{dy:2.53183}),g.createElement("feGaussianBlur",{stdDeviation:1.01273}),g.createElement("feComposite",{in2:"hardAlpha",operator:"out"}),g.createElement("feColorMatrix",{type:"matrix",values:"0 0 0 0 0.0402673 0 0 0 0 0.553597 0 0 0 0 0.322599 0 0 0 0.45 0"}),g.createElement("feBlend",{mode:"normal",in2:"BackgroundImageFix",result:"effect1_dropShadow_1708_12218"}),g.createElement("feBlend",{mode:"normal",in:"SourceGraphic",in2:"effect1_dropShadow_1708_12218",result:"shape"}),g.createElement("feColorMatrix",{in:"SourceAlpha",type:"matrix",values:"0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 127 0",result:"hardAlpha"}),g.createElement("feOffset",{dy:-1.01273}),g.createElement("feGaussianBlur",{stdDeviation:.506366}),g.createElement("feComposite",{in2:"hardAlpha",operator:"arithmetic",k2:-1,k3:1}),g.createElement("feColorMatrix",{type:"matrix",values:"0 0 0 0 0.154656 0 0 0 0 0.893473 0 0 0 0 0.462497 0 0 0 0.3 0"}),g.createElement("feBlend",{mode:"normal",in2:"shape",result:"effect2_innerShadow_1708_12218"})),g.createElement("filter",{id:"filter4_ddi_1708_12218",x:218.407,y:106.407,width:40.1852,height:40.1852,filterUnits:"userSpaceOnUse",colorInterpolationFilters:"sRGB"}
35,g.createElement("feFlood",{floodOpacity:0,result:"BackgroundImageFix"}),g.createElement("feColorMatrix",{in:"SourceAlpha",type:"matrix",values:"0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 127 0",result:"hardAlpha"}),g.createElement("feMorphology",{radius:2.59259,operator:"dilate",in:"SourceAlpha",result:"effect1_dropShadow_1708_12218"}),g.createElement("feOffset",null),g.createElement("feComposite",{in2:"hardAlpha",operator:"out"}),g.createElement("feColorMatrix",{type:"matrix",values:"0 0 0 0 0.886275 0 0 0 0 0.952941 0 0 0 0 0.929412 0 0 0 1 0"}),g.createElement("feBlend",{mode:"normal",in2:"BackgroundImageFix",result:"effect1_dropShadow_1708_12218"}),g.createElement("feColorMatrix",{in:"SourceAlpha",type:"matrix",values:"0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 127 0",result:"hardAlpha"}),g.createElement("feMorphology",{radius:1.01273,operator:"erode",in:"SourceAlpha",result:"effect2_dropShadow_1708_12218"}),g.createElement("feOffset",{dy:1.01273}),g.createElement("feGaussianBlur",{stdDeviation:1.01273}),g.createElement("feComposite",{in2:"hardAlpha",operator:"out"}),g.createElement("feColorMatrix",{type:"matrix",values:"0 0 0 0 0.188235 0 0 0 0 0.192157 0 0 0 0 0.239216 0 0 0 0.25 0"}),g.createElement("feBlend",{mode:"normal",in2:"effect1_dropShadow_1708_12218",result:"effect2_dropShadow_1708_12218"}),g.createElement("feBlend",{mode:"normal",in:"SourceGraphic",in2:"effect2_dropShadow_1708_12218",result:"shape"}),g.createElement("feColorMatrix",{in:"SourceAlpha",type:"matrix",values:"0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 127 0",result:"hardAlpha"}),g.createElement("feOffset",{dy:-2.53183}),g.createElement("feComposite",{in2:"hardAlpha",operator:"arithmetic",k2:-1,k3:1}),g.createElement("feColorMatrix",{type:"matrix",values:"0 0 0 0 0.114162 0 0 0 0 0.133086 0 0 0 0 0.165771 0 0 0 1 0"}),g.createElement("feBlend",{mode:"normal",in2:"shape",result:"effect3_innerShadow_1708_12218"})),g.createElement("filter",{id:"filter5_di_1708_12218",x:232.289,y:118.395,width:14.1915,height:17.1146,filterUnits:"userSpaceOnUse",colorInterpolationFilters:"sRGB"},g.createElement("feFlood",{floodOpacity:0,result:"BackgroundImageFix"}),g.createElement("feColorMatrix",{in:"SourceAlpha",type:"matrix",values:"0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 127 0",result:"hardAlpha"}),g.createElement("feOffset",{dy:2.49791}),g.createElement("feGaussianBlur",{stdDeviation:.999165}),g.createElement("feComposite",{in2:"hardAlpha",operator:"out"}),g.createElement("feColorMatrix",{type:"matrix",values:"0 0 0 0 0.0901961 0 0 0 0 0.117647 0 0 0 0 0.141176 0 0 0 0.4 0"}),g.createElement("feBlend",{mode:"normal",in2:"BackgroundImageFix",result:"effect1_dropShadow_1708_12218"}),g.createElement("feBlend",{mode:"normal",in:"SourceGraphic",in2:"effect1_dropShadow_1708_12218",result:"shape"}),g.createElement("feColorMatrix",{in:"SourceAlpha",type:"matrix",values:"0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 127 0",result:"hardAlpha"}),g.createElement("feOffset",{dy:-.999165}),g.createElement("feGaussianBlur",{stdDeviation:.749374}),g.createElement("feComposite",{in2:"hardAlpha",operator:"arithmetic",k2:-1,k3:1}),g.createElement("feColorMatrix",{type:"matrix",values:"0 0 0 0 0.392157 0 0 0 0 0.541176 0 0 0 0 0.607843 0 0 0 0.3 0"}),g.createElement("feBlend",{mode:"normal",in2:"shape",result:"effect2_innerShadow_1708_12218"})),g.createElement("filter",{id:"filter6_ddi_1708_12218",x:125.46,y:164.731,width:39.3651,height:39.3655,filterUnits:"userSpaceOnUse",colorInterpolationFilters:"sRGB"},g.createElement("feFlood",{floodOpacity:0,result:"BackgroundImageFix"}),g.createElement("feColorMatrix",{in:"SourceAlpha",type:"matrix",values:"0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 127 0",result:"hardAlpha"}),g.createElement("feMorphology",{radius:2.53968,operator:"dilate",in:"SourceAlpha",result:"effect1_dropShadow_1708_12218"}),g.createElement("feOffset",null),g.createElement("feComposite",{in2:"hardAlpha",operator:"out"}),g.createElement("feColorMatrix",{type:"matrix",values:"0 0 0 0 0.884941 0 0 0 0 0.954476 0 0 0 0 0.927821 0 0 0 1 0"}),g.createElement("feBlend",{mode:"normal",in2:"BackgroundImageFix",result:"effect1_dropShadow_1708_12218"}),g.createElement("feColorMatrix",{in:"SourceAlpha",type:"matrix",values:"0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 127 0",result:"hardAlpha"}),g.createElement("feMorphology",{radius:.992064,operator:"erode",in:"SourceAlpha",result:"effect2_dropShadow_1708_12218"}),g.createElement("feOffset",{dy:.992064}),g.createElement("feGaussianBlur",{stdDeviation:.992064}),g.createElement("feComposite",{in2:"hardAlpha",operator:"out"}),g.createElement("feColorMatrix",{type:"matrix",values:"0 0 0 0 0.188235 0 0 0 0 0.192157 0 0 0 0 0.239216 0 0 0 0.25 0"}),g.createElement("feBlend",{mode:"normal",in2:"effect1_dropShadow_1708_12218",result:"effect2_dropShadow_1708_12218"}),g.createElement("feBlend",{mode:"normal",in:"SourceGraphic",in2:"effect2_dropShadow_1708_12218",result:"shape"}),g.createElement("feColorMatrix",{in:"SourceAlpha",type:"matrix",values:"0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 127 0",result:"hardAlpha"}),g.createElement("feOffset",{dy:-2.48016}),g.createElement("feComposite",{in2:"hardAlpha",operator:"arithmetic",k2:-1,k3:1}),g.createElement("feColorMatrix",{type:"matrix",values:"0 0 0 0 0.0951048 0 0 0 0 0.628711 0 0 0 0 0.397014 0 0 0 1 0"}),g.createElement("feBlend",{mode:"normal",in2:"shape",result:"effect3_innerShadow_1708_12218"})),g.createElement("filter",{id:"filter7_di_1708_12218",x:137.206,y:177.606,width:15.873,height:14.9808,filterUnits:"userSpaceOnUse",colorInterpolationFilters:"sRGB"}
35,g.createElement("feFlood",{floodOpacity:0,result:"BackgroundImageFix"}),g.createElement("feColorMatrix",{in:"SourceAlpha",type:"matrix",values:"0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 127 0",result:"hardAlpha"}),g.createElement("feOffset",{dy:2.48016}),g.createElement("feGaussianBlur",{stdDeviation:.992064}),g.createElement("feComposite",{in2:"hardAlpha",operator:"out"}),g.createElement("feColorMatrix",{type:"matrix",values:"0 0 0 0 0.0402673 0 0 0 0 0.553597 0 0 0 0 0.322599 0 0 0 0.45 0"}),g.createElement("feBlend",{mode:"normal",in2:"BackgroundImageFix",result:"effect1_dropShadow_1708_12218"}),g.createElement("feBlend",{mode:"normal",in:"SourceGraphic",in2:"effect1_dropShadow_1708_12218",result:"shape"}),g.createElement("feColorMatrix",{in:"SourceAlpha",type:"matrix",values:"0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 127 0",result:"hardAlpha"}),g.createElement("feOffset",{dy:-.992064}),g.createElement("feGaussianBlur",{stdDeviation:.496032}),g.createElement("feComposite",{in2:"hardAlpha",operator:"arithmetic",k2:-1,k3:1}),g.createElement("feColorMatrix",{type:"matrix",values:"0 0 0 0 0.154656 0 0 0 0 0.893473 0 0 0 0 0.462497 0 0 0 0.3 0"}),g.createElement("feBlend",{mode:"normal",in2:"shape",result:"effect2_innerShadow_1708_12218"})),g.createElement("filter",{id:"filter8_d_1708_12218",x:150.857,y:164.73,width:18.4127,height:18.4127,filterUnits:"userSpaceOnUse",colorInterpolationFilters:"sRGB"},g.createElement("feFlood",{floodOpacity:0,result:"BackgroundImageFix"}),g.createElement("feColorMatrix",{in:"SourceAlpha",type:"matrix",values:"0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 127 0",result:"hardAlpha"}),g.createElement("feMorphology",{radius:1.26984,operator:"dilate",in:"SourceAlpha",result:"effect1_dropShadow_1708_12218"}),g.createElement("feOffset",null),g.createElement("feComposite",{in2:"hardAlpha",operator:"out"}),g.createElement("feColorMatrix",{type:"matrix",values:"0 0 0 0 1 0 0 0 0 1 0 0 0 0 1 0 0 0 1 0"}),g.createElement("feBlend",{mode:"normal",in2:"BackgroundImageFix",result:"effect1_dropShadow_1708_12218"}),g.createElement("feBlend",{mode:"normal",in:"SourceGraphic",in2:"effect1_dropShadow_1708_12218",result:"shape"})),g.createElement("filter",{id:"filter9_d_1708_12218",x:315,y:271,width:44,height:44,filterUnits:"userSpaceOnUse",colorInterpolationFilters:"sRGB"},g.createElement("feFlood",{floodOpacity:0,result:"BackgroundImageFix"}),g.createElement("feColorMatrix",{in:"SourceAlpha",type:"matrix",values:"0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 127 0",result:"hardAlpha"}),g.createElement("feOffset",{dy:2}),g.createElement("feGaussianBlur",{stdDeviation:1.5}),g.createElement("feComposite",{in2:"hardAlpha",operator:"out"}),g.createElement("feColorMatrix",{type:"matrix",values:"0 0 0 0 0.188235 0 0 0 0 0.192157 0 0 0 0 0.239216 0 0 0 0.05 0"}),g.createElement("feBlend",{mode:"normal",in2:"BackgroundImageFix",result:"effect1_dropShadow_1708_12218"}),g.createElement("feBlend",{mode:"normal",in:"SourceGraphic",in2:"effect1_dropShadow_1708_12218",result:"shape"})),g.createElement("filter",{id:"filter10_d_1708_12218",x:222,y:327,width:44,height:44,filterUnits:"userSpaceOnUse",colorInterpolationFilters:"sRGB"},g.createElement("feFlood",{floodOpacity:0,result:"BackgroundImageFix"}),g.createElement("feColorMatrix",{in:"SourceAlpha",type:"matrix",values:"0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 127 0",result:"hardAlpha"}),g.createElement("feOffset",{dy:2}),g.createElement("feGaussianBlur",{stdDeviation:1.5}),g.createElement("feComposite",{in2:"hardAlpha",operator:"out"}),g.createElement("feColorMatrix",{type:"matrix",values:"0 0 0 0 0.188235 0 0 0 0 0.192157 0 0 0 0 0.239216 0 0 0 0.05 0"}),g.createElement("feBlend",{mode:"normal",in2:"BackgroundImageFix",result:"effect1_dropShadow_1708_12218"}),g.createElement("feBlend",{mode:"normal",in:"SourceGraphic",in2:"effect1_dropShadow_1708_12218",result:"shape"})),g.createElement("filter",{id:"filter11_d_1708_12218",x:125,y:275,width:44,height:44,filterUnits:"userSpaceOnUse",colorInterpolationFilters:"sRGB"},g.createElement("feFlood",{floodOpacity:0,result:"BackgroundImageFix"}),g.createElement("feColorMatrix",{in:"SourceAlpha",type:"matrix",values:"0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 127 0",result:"hardAlpha"}),g.createElement("feOffset",{dy:2}),g.createElement("feGaussianBlur",{stdDeviation:1.5}),g.createElement("feComposite",{in2:"hardAlpha",operator:"out"}),g.createElement("feColorMatrix",{type:"matrix",values:"0 0 0 0 0.188235 0 0 0 0 0.192157 0 0 0 0 0.239216 0 0 0 0.05 0"}
35),g.createElement("feBlend",{mode:"normal",in2:"BackgroundImageFix",result:"effect1_dropShadow_1708_12218"}),g.createElement("feBlend",{mode:"normal",in:"SourceGraphic",in2:"effect1_dropShadow_1708_12218",result:"shape"})),g.createElement("radialGradient",{id:"paint0_radial_1708_12218",cx:0,cy:0,r:1,gradientUnits:"userSpaceOnUse",gradientTransform:"translate(240 240) rotate(90) scale(255.5 255.5)"},g.createElement("stop",null),g.createElement("stop",{offset:1,stopOpacity:0})),g.createElement("linearGradient",{id:"paint1_linear_1708_12218",x1:329.383,y1:196.891,x2:357,y2:184.312,gradientUnits:"userSpaceOnUse"},g.createElement("stop",{stopColor:"white",stopOpacity:0}),g.createElement("stop",{offset:1,stopColor:"white"})),g.createElement("linearGradient",{id:"paint2_linear_1708_12218",x1:228.383,y1:136.891,x2:256,y2:124.312,gradientUnits:"userSpaceOnUse"},g.createElement("stop",{stopColor:"white",stopOpacity:0}),g.createElement("stop",{offset:1,stopColor:"white"})),g.createElement("linearGradient",{id:"paint3_linear_1708_12218",x1:135.232,y1:194.592,x2:162.286,y2:182.271,gradientUnits:"userSpaceOnUse"},g.createElement("stop",{stopColor:"white",stopOpacity:0}),g.createElement("stop",{offset:1,stopColor:"white"})),g.createElement("linearGradient",{id:"paint4_linear_1708_12218",x1:328.328,y1:299.906,x2:352,y2:289.125,gradientUnits:"userSpaceOnUse"},g.createElement("stop",{stopColor:"white",stopOpacity:0}),g.createElement("stop",{offset:1,stopColor:"white"})),g.createElement("linearGradient",{id:"paint5_linear_1708_12218",x1:235.328,y1:355.906,x2:259,y2:345.125,gradientUnits:"userSpaceOnUse"},g.createElement("stop",{stopColor:"white",stopOpacity:0}),g.createElement("stop",{offset:1,stopColor:"white"})),g.createElement("linearGradient",{id:"paint6_linear_1708_12218",x1:138.328,y1:303.906,x2:162,y2:293.125,gradientUnits:"userSpaceOnUse"},g.createElement("stop",{stopColor:"white",stopOpacity:0}),g.createElement("stop",{offset:1,stopColor:"white"})))),p$=({title:e,description:t,className:n,children:r})=>j.jsxs("div",{className:sn("flex flex-col items-center",n),children:[j.jsx(jce,{className:"w-full max-w-md"}),j.jsxs("div",{className:"-mt-28 text-center max-w-sm mx-auto mb-8",children:[j.jsx("h3",{className:"font-semibold text-xl mb-1",children:e}),j.jsx("p",{className:"text-[15px] leading-loose",children:t})]}),r]});class Fce extends g.Component{constructor(t){super(t),this.state={hasError:!1,error:null}}static getDerivedStateFromError(t){return{hasError:!0,error:t}}componentDidCatch(t,n){ia(t,{componentStack:n.componentStack})}handleReset=()=>{this.setState({hasError:!1,error:null}),this.props.onReset?.()};render(){return this.state.hasError?this.props.fallback?this.props.fallback:j.jsx(p$,{title:"Something went wrong",description:"We encountered an unexpected error. Please try again or refresh the page.",children:j.jsxs("div",{className:"flex items-center gap-4",children:[j.jsx(Kr,{variant:"outline",onClick:()=>window.location.reload(),children:"Refresh Page"}),j.jsx(Kr,{onClick:this.handleReset,children:"Try Again"})]})}):this.props.children}}var uS,w5;function Uce(){if(w5)return uS;w5=1;var e=typeof Element<"u",t=typeof Map=="function",n=typeof Set=="function",r=typeof ArrayBuffer=="function"&&!!ArrayBuffer.isView;function i(s,o){if(s===o)return!0;if(s&&o&&typeof s=="object"&&typeof o=="object"){if(s.constructor!==o.constructor)return!1;var a,c,d;if(Array.isArray(s)){if(a=s.length,a!=o.length)return!1;for(c=a;c--!==0;)if(!i(s[c],o[c]))return!1;return!0}var f;if(t&&s instanceof Map&&o instanceof Map){if(s.size!==o.size)return!1;for(f=s.entries();!(c=f.next()).done;)if(!o.has(c.value[0]))return!1;for(f=s.entries();!(c=f.next()).done;)if(!i(c.value[1],o.get(c.value[0])))return!1;return!0}if(n&&s instanceof Set&&o instanceof Set){if(s.size!==o.size)return!1;for(f=s.entries();!(c=f.next()).done;)if(!o.has(c.value[0]))return!1;return!0}if(r&&ArrayBuffer.isView(s)&&ArrayBuffer.isView(o)){if(a=s.length,a!=o.length)return!1;for(c=a;c--!==0;)if(s[c]!==o[c])return!1;return!0}if(s.constructor===RegExp)return s.source===o.source&&s.flags===o.flags;if(s.valueOf!==Object.prototype.valueOf&&typeof s.valueOf=="function"&&typeof o.valueOf=="function")return s.valueOf()===o.valueOf();if(s.toString!==Object.prototype.toString&&typeof s.toString=="function"&&typeof o.toString=="function")return s.toString()===o.toString();if(d=Object.keys(s),a=d.length,a!==Object.keys(o).length)return!1;for(c=a;c--!==0;)if(!Object.prototype.hasOwnProperty.call(o,d[c]))return!1;if(e&&s instanceof Element)return!1;for(c=a;c--!==0;)if(!((d[c]==="_owner"||d[c]==="__v"||d[c]==="__o")&&s.$$typeof)&&!i(s[d[c]],o[d[c]])
35)return!1;return!0}return s!==s&&o!==o}return uS=function(o,a){try{return i(o,a)}catch(c){if((c.message||"").match(/stack|recursion/i))return console.warn("react-fast-compare cannot handle circular refs"),!1;throw c}},uS}var zce=Uce();const Bce=Pl(zce);var dS,b5;function Hce(){if(b5)return dS;b5=1;var e=function(t,n,r,i,s,o,a,c){if(!t){var d;if(n===void 0)d=new Error("Minified exception occurred; use the non-minified dev environment for the full error message and additional helpful warnings.");else{var f=[r,i,s,o,a,c],p=0;d=new Error(n.replace(/%s/g,function(){return f[p++]})),d.name="Invariant Violation"}throw d.framesToPop=1,d}};return dS=e,dS}var Vce=Hce();const S5=Pl(Vce);var fS,E5;function Wce(){return E5||(E5=1,fS=function(t,n,r,i){var s=r?r.call(i,t,n):void 0;if(s!==void 0)return!!s;if(t===n)return!0;if(typeof t!="object"||!t||typeof n!="object"||!n)return!1;var o=Object.keys(t),a=Object.keys(n);if(o.length!==a.length)return!1;for(var c=Object.prototype.hasOwnProperty.bind(n),d=0;d<o.length;d++){var f=o[d];if(!c(f))return!1;var p=t[f],m=n[f];if(s=r?r.call(i,p,m,f):void 0,s===!1||s===void 0&&p!==m)return!1}return!0}),fS}var qce=Wce();const Kce=Pl(qce);var m$=(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))(m$||{}),hS={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"]}},x5=Object.values(m$),oT={accesskey:"accessKey",charset:"charSet",class:"className",contenteditable:"contentEditable",contextmenu:"contextMenu","http-equiv":"httpEquiv",itemprop:"itemProp",tabindex:"tabIndex"},Gce=Object.entries(oT).reduce((e,[t,n])=>(e[n]=t,e),{}),xs="data-rh",Ld={DEFAULT_TITLE:"defaultTitle",DEFER:"defer",ENCODE_SPECIAL_CHARACTERS:"encodeSpecialCharacters",ON_CHANGE_CLIENT_STATE:"onChangeClientState",TITLE_TEMPLATE:"titleTemplate",PRIORITIZE_SEO_TAGS:"prioritizeSeoTags"},Nd=(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},Yce=e=>{let t=Nd(e,"title");const n=Nd(e,Ld.TITLE_TEMPLATE);if(Array.isArray(t)&&(t=t.join("")),n&&t)return n.replace(/%s/g,()=>t);const r=Nd(e,Ld.DEFAULT_TITLE);return t||r||void 0},Jce=e=>Nd(e,Ld.ON_CHANGE_CLIENT_STATE)||(()=>{}),pS=(e,t)=>t.filter(n=>typeof n[e]<"u").map(n=>n[e]).reduce((n,r)=>({...n,...r}),{}),Zce=(e,t)=>t.filter(n=>typeof n.base<"u").map(n=>n.base).reverse().reduce((n,r)=>{if(!n.length){const i=Object.keys(r);for(let s=0;s<i.length;s+=1){const a=i[s].toLowerCase();if(e.indexOf(a)!==-1&&r[a])return n.concat(r)}}return n},[]),Xce=e=>console&&typeof console.warn=="function"&&console.warn(e),Ah=(e,t,n)=>{const r={};return n.filter(i=>Array.isArray(i[e])?!0:(typeof i[e]<"u"&&Xce(`Helmet: ${e} should be of type "Array". Instead found type "${typeof i[e]}"`),!1)).map(i=>i[e]).reverse().reduce((i,s)=>{const o={};s.filter(c=>{let d;const f=Object.keys(c);for(let m=0;m<f.length;m+=1){const v=f[m],w=v.toLowerCase();t.indexOf(w)!==-1&&!(d==="rel"&&c[d].toLowerCase()==="canonical")&&!(w==="rel"&&c[w].toLowerCase()==="stylesheet")&&(d=w),t.indexOf(v)!==-1&&(v==="innerHTML"||v==="cssText"||v==="itemprop")&&(d=v)}if(!d||!c[d])return!1;const p=c[d].toLowerCase();return r[d]||(r[d]={}),o[d]||(o[d]={}),r[d][p]?!1:(o[d][p]=!0,!0)}).reverse().forEach(c=>i.push(c));const a=Object.keys(o);for(let c=0;c<a.length;c+=1){const d=a[c],f={...r[d],...o[d]};r[d]=f}return i},[]).reverse()},Qce=(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},eue=e=>({baseTag:Zce(["href"],e),bodyAttributes:pS("bodyAttributes",e),defer:Nd(e,Ld.DEFER),encode:Nd(e,Ld.ENCODE_SPECIAL_CHARACTERS),htmlAttributes:pS("htmlAttributes",e),linkTags:Ah("link",["rel","href"],e),metaTags:Ah("meta",["name","charset","http-equiv","property","itemprop"],e),noscriptTags:Ah("noscript",["innerHTML"],e),onChangeClientState:Jce(e),scriptTags:Ah("script",["src","innerHTML"],e),styleTags:Ah("style",["cssText"],e),title:Yce(e),titleAttributes:pS("titleAttributes",e),prioritizeSeoTags:Qce(e,Ld.PRIORITIZE_SEO_TAGS)}),g$=e=>Array.isArray(e)?e.join(""):e,tue=(e,t)=>
35{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},mS=(e,t)=>Array.isArray(e)?e.reduce((n,r)=>(tue(r,t)?n.priority.push(r):n.default.push(r),n),{priority:[],default:[]}):{default:e,priority:[]},C5=(e,t)=>({...e,[t]:void 0}),nue=["noscript","script","style"],Xx=(e,t=!0)=>t===!1?String(e):String(e).replace(/&/g,"&").replace(/</g,"<").replace(/>/g,">").replace(/"/g,""").replace(/'/g,"'"),y$=e=>Object.keys(e).reduce((t,n)=>{const r=typeof e[n]<"u"?`${n}="${e[n]}"`:`${n}`;return t?`${t} ${r}`:r},""),rue=(e,t,n,r)=>{const i=y$(n),s=g$(t);return i?`<${e} ${xs}="true" ${i}>${Xx(s,r)}</${e}>`:`<${e} ${xs}="true">${Xx(s,r)}</${e}>`},iue=(e,t,n=!0)=>t.reduce((r,i)=>{const s=i,o=Object.keys(s).filter(d=>!(d==="innerHTML"||d==="cssText")).reduce((d,f)=>{const p=typeof s[f]>"u"?f:`${f}="${Xx(s[f],n)}"`;return d?`${d} ${p}`:p},""),a=s.innerHTML||s.cssText||"",c=nue.indexOf(e)===-1;return`${r}<${e} ${xs}="true" ${o}${c?"/>":`>${a}</${e}>`}`},""),v$=(e,t={})=>Object.keys(e).reduce((n,r)=>{const i=oT[r];return n[i||r]=e[r],n},t),sue=(e,t,n)=>{const r={key:t,[xs]:!0},i=v$(n,r);return[bt.createElement("title",i,t)]},Pv=(e,t)=>t.map((n,r)=>{const i={key:r,[xs]:!0};return Object.keys(n).forEach(s=>{const a=oT[s]||s;if(a==="innerHTML"||a==="cssText"){const c=n.innerHTML||n.cssText;i.dangerouslySetInnerHTML={__html:c}}else i[a]=n[s]}),bt.createElement(e,i)}),Ki=(e,t,n=!0)=>{switch(e){case"title":return{toComponent:()=>sue(e,t.title,t.titleAttributes),toString:()=>rue(e,t.title,t.titleAttributes,n)};case"bodyAttributes":case"htmlAttributes":return{toComponent:()=>v$(t),toString:()=>y$(t)};default:return{toComponent:()=>Pv(e,t),toString:()=>iue(e,t,n)}}},oue=({metaTags:e,linkTags:t,scriptTags:n,encode:r})=>{const i=mS(e,hS.meta),s=mS(t,hS.link),o=mS(n,hS.script);return{priorityMethods:{toComponent:()=>[...Pv("meta",i.priority),...Pv("link",s.priority),...Pv("script",o.priority)],toString:()=>`${Ki("meta",i.priority,r)} ${Ki("link",s.priority,r)} ${Ki("script",o.priority,r)}`},metaTags:i.default,linkTags:s.default,scriptTags:o.default}},aue=e=>{const{baseTag:t,bodyAttributes:n,encode:r=!0,htmlAttributes:i,noscriptTags:s,styleTags:o,title:a="",titleAttributes:c,prioritizeSeoTags:d}=e;let{linkTags:f,metaTags:p,scriptTags:m}=e,v={toComponent:()=>{},toString:()=>""};return d&&({priorityMethods:v,linkTags:f,metaTags:p,scriptTags:m}=oue(e)),{priority:v,base:Ki("base",t,r),bodyAttributes:Ki("bodyAttributes",n,r),htmlAttributes:Ki("htmlAttributes",i,r),link:Ki("link",f,r),meta:Ki("meta",p,r),noscript:Ki("noscript",s,r),script:Ki("script",m,r),style:Ki("style",o,r),title:Ki("title",{title:a,titleAttributes:c},r)}},Qx=aue,qy=[],_$=!!(typeof window<"u"&&window.document&&window.document.createElement),e2=class{instances=[];canUseDOM=_$;context;value={setHelmet:e=>{this.context.helmet=e},helmetInstances:{get:()=>this.canUseDOM?qy:this.instances,add:e=>{(this.canUseDOM?qy:this.instances).push(e)},remove:e=>{const t=(this.canUseDOM?qy:this.instances).indexOf(e);(this.canUseDOM?qy:this.instances).splice(t,1)}}};constructor(e,t){this.context=e,this.canUseDOM=t||!1,t||(e.helmet=Qx({baseTag:[],bodyAttributes:{},htmlAttributes:{},linkTags:[],metaTags:[],noscriptTags:[],scriptTags:[],styleTags:[],title:"",titleAttributes:{}}))}},lue={},w$=bt.createContext(lue),b$=class S$ extends g.Component{static canUseDOM=_$;helmetData;constructor(t){super(t),this.helmetData=new e2(this.props.context||{},S$.canUseDOM)}render(){return bt.createElement(w$.Provider,{value:this.helmetData.value},this.props.children)}},Qu=(e,t)=>{const n=document.head||document.querySelector("head"),r=n.querySelectorAll(`${e}[${xs}]`),i=[].slice.call(r),s=[];let o;return t&&t.length&&t.forEach(a=>{const c=document.createElement(e);for(const d in a)if(Object.prototype.hasOwnProperty.call(a,d))if(d==="innerHTML")c.innerHTML=a.innerHTML;else if(d==="cssText")c.styleSheet?c.styleSheet.cssText=a.cssText:c.appendChild(document.createTextNode(a.cssText));else{const f=d,p=typeof a[f]>"u"?"":a[f];c.setAttribute(d,p)}c.setAttribute(xs,"true"),i.some((d,f)=>(o=f,c.isEqualNode(d)))?i.splice(o,1):s.push(c)}
35),i.forEach(a=>a.parentNode?.removeChild(a)),s.forEach(a=>n.appendChild(a)),{oldTags:i,newTags:s}},t2=(e,t)=>{const n=document.getElementsByTagName(e)[0];if(!n)return;const r=n.getAttribute(xs),i=r?r.split(","):[],s=[...i],o=Object.keys(t);for(const a of o){const c=t[a]||"";n.getAttribute(a)!==c&&n.setAttribute(a,c),i.indexOf(a)===-1&&i.push(a);const d=s.indexOf(a);d!==-1&&s.splice(d,1)}for(let a=s.length-1;a>=0;a-=1)n.removeAttribute(s[a]);i.length===s.length?n.removeAttribute(xs):n.getAttribute(xs)!==o.join(",")&&n.setAttribute(xs,o.join(","))},cue=(e,t)=>{typeof e<"u"&&document.title!==e&&(document.title=g$(e)),t2("title",t)},k5=(e,t)=>{const{baseTag:n,bodyAttributes:r,htmlAttributes:i,linkTags:s,metaTags:o,noscriptTags:a,onChangeClientState:c,scriptTags:d,styleTags:f,title:p,titleAttributes:m}=e;t2("body",r),t2("html",i),cue(p,m);const v={baseTag:Qu("base",n),linkTags:Qu("link",s),metaTags:Qu("meta",o),noscriptTags:Qu("noscript",a),scriptTags:Qu("script",d),styleTags:Qu("style",f)},w={},_={};Object.keys(v).forEach(b=>{const{newTags:C,oldTags:P}=v[b];C.length&&(w[b]=C),P.length&&(_[b]=v[b].oldTags)}),t&&t(),c(e,w,_)},Ih=null,uue=e=>{Ih&&cancelAnimationFrame(Ih),e.defer?Ih=requestAnimationFrame(()=>{k5(e,()=>{Ih=null})}):(k5(e),Ih=null)},due=uue,T5=class extends g.Component{rendered=!1;shouldComponentUpdate(e){return!Kce(e,this.props)}componentDidUpdate(){this.emitChange()}componentWillUnmount(){const{helmetInstances:e}=this.props.context;e.remove(this),this.emitChange()}emitChange(){const{helmetInstances:e,setHelmet:t}=this.props.context;let n=null;const r=eue(e.get().map(i=>{const s={...i.props};return delete s.context,s}));b$.canUseDOM?due(r):Qx&&(n=Qx(r)),t(n)}init(){if(this.rendered)return;this.rendered=!0;const{helmetInstances:e}=this.props.context;e.add(this),this.emitChange()}render(){return this.init(),null}},SOe=class extends g.Component{static defaultProps={defer:!0,encodeSpecialCharacters:!0,prioritizeSeoTags:!1};shouldComponentUpdate(e){return!Bce(C5(this.props,"helmetData"),C5(e,"helmetData"))}mapNestedChildrenToProps(e,t){if(!t)return null;switch(e.type){case"script":case"noscript":return{innerHTML:t};case"style":return{cssText:t};default:throw new Error(`<${e.type} /> elements are self-closing and can not contain children. Refer to our API for more information.`)}}flattenArrayTypeChildren(e,t,n,r){return{...t,[e.type]:[...t[e.type]||[],{...n,...this.mapNestedChildrenToProps(e,r)}]}}mapObjectTypeChildren(e,t,n,r){switch(e.type){case"title":return{...t,[e.type]:r,titleAttributes:{...n}};case"body":return{...t,bodyAttributes:{...n}};case"html":return{...t,htmlAttributes:{...n}};default:return{...t,[e.type]:{...n}}}}mapArrayTypeChildrenToProps(e,t){let n={...t};return Object.keys(e).forEach(r=>{n={...n,[r]:e[r]}}),n}warnOnInvalidChildren(e,t){return S5(x5.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 ${x5.join(", ")} are allowed. Helmet does not support rendering <${e.type}> elements. Refer to our API for more information.`),S5(!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 bt.Children.forEach(e,r=>{if(!r||!r.props)return;const{children:i,...s}=r.props,o=Object.keys(s).reduce((c,d)=>(c[Gce[d]||d]=s[d],c),{});let{type:a}=r;
35switch(typeof a=="symbol"?a=a.toString():this.warnOnInvalidChildren(r,i),a){case"Symbol(react.fragment)":t=this.mapChildrenToProps(i,t);break;case"link":case"meta":case"noscript":case"script":case"style":n=this.flattenArrayTypeChildren(r,n,o,i);break;default:t=this.mapObjectTypeChildren(r,t,o,i);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 e2)){const i=r;r=new e2(i.context,!0),delete n.helmetData}return r?bt.createElement(T5,{...n,context:r.value}):bt.createElement(w$.Consumer,null,i=>bt.createElement(T5,{...n,context:i}))}};function n2(){}function fue(e,{interval:t=1e3,onError:n=n2}={}){if(typeof e!="function")throw new Error("argument is not function.");let r=0,i=null,s=!1,o=!1;return async(...a)=>{if(i=a,!o){for(o=!0;s;)await new Promise(c=>jo.setTimeout(c,t));for(;Date.now()<r;)await new Promise(c=>jo.setTimeout(c,r-Date.now()));o=!1,s=!0;try{await e(...i)}catch(c){try{n(c)}catch{}}r=Date.now()+t,s=!1}}}var hue=({storage:e,key:t="REACT_QUERY_OFFLINE_CACHE",throttleTime:n=1e3,serialize:r=JSON.stringify,deserialize:i=JSON.parse,retry:s})=>{if(e){const o=async a=>{try{const c=await r(a);await e.setItem(t,c);return}catch(c){return c}};return{persistClient:fue(async a=>{let c=a,d=await o(c),f=0;for(;d&&c;)f++,c=await s?.({persistedClient:c,error:d,errorCount:f}),c&&(d=await o(c))},{interval:n}),restoreClient:async()=>{const a=await e.getItem(t);if(a)return await i(a)},removeClient:()=>e.removeItem(t)}}return{persistClient:n2,restoreClient:()=>Promise.resolve(void 0),removeClient:n2}},pue=["added","removed","updated"];function R5(e){return pue.includes(e)}async function mue({queryClient:e,persister:t,maxAge:n=1e3*60*60*24,buster:r="",hydrateOptions:i}){try{const s=await t.restoreClient();if(s)if(s.timestamp){const o=Date.now()-s.timestamp>n,a=s.buster!==r;if(o||a)return t.removeClient();KZ(e,s.clientState,i)}else return t.removeClient()}catch(s){throw await t.removeClient(),s}}async function P5({queryClient:e,persister:t,buster:n="",dehydrateOptions:r}){const i={buster:n,timestamp:Date.now(),clientState:qZ(e,r)};await t.persistClient(i)}function gue(e){const t=e.queryClient.getQueryCache().subscribe(r=>{R5(r.type)&&P5(e)}),n=e.queryClient.getMutationCache().subscribe(r=>{R5(r.type)&&P5(e)});return()=>{t(),n()}}function yue(e){let t=!1,n;const r=()=>{t=!0,n?.()},i=mue(e).then(()=>{t||(n=gue(e))});return[r,i]}let vue={data:""},_ue=e=>{if(typeof window=="object"){let t=(e?e.querySelector("#_goober"):window._goober)||Object.assign(document.createElement("style"),{innerHTML:" ",id:"_goober"});return t.nonce=window.__nonce__,t.parentNode||(e||document.head).appendChild(t),t.firstChild}return e||vue},wue=/(?:([\u0080-\uFFFF\w-%@]+) *:? *([^{;]+?);|([^;}{]*?) *{)|(}\s*)/g,bue=/\/\*[^]*?\*\/| +/g,O5=/\n+/g,il=(e,t)=>{let n="",r="",i="";for(let s in e){let o=e[s];s[0]=="@"?s[1]=="i"?n=s+" "+o+";":r+=s[1]=="f"?il(o,s):s+"{"+il(o,s[1]=="k"?"":t)+"}":typeof o=="object"?r+=il(o,t?t.replace(/([^,])+/g,a=>s.replace(/([^,]*:\S+\([^)]*\))|([^,])+/g,c=>/&/.test(c)?c.replace(/&/g,a):a?a+" "+c:c)):s):o!=null&&(s=/^--/.test(s)?s:s.replace(/[A-Z]/g,"-$&").toLowerCase(),i+=il.p?il.p(s,o):s+":"+o+";")}return n+(t&&i?t+"{"+i+"}":i)+r},ko={},E$=e=>{if(typeof e=="object"){let t="";for(let n in e)t+=n+E$(e[n]);return t}return e},Sue=(e,t,n,r,i)=>{let s=E$(e),o=ko[s]||(ko[s]=(c=>{let d=0,f=11;for(;d<c.length;)f=101*f+c.charCodeAt(d++)>>>0;return"go"+f})(s));if(!ko[o]){let c=s!==e?e:(d=>{let f,p,m=[{}];for(;f=wue.exec(d.replace(bue,""));)f[4]?m.shift():f[3]?(p=f[3].replace(O5," ").trim(),m.unshift(m[0][p]=m[0][p]||{})):m[0][f[1]]=f[2].replace(O5," ").trim();return m[0]})(e);ko[o]=il(i?{["@keyframes "+o]:c}:c,n?"":"."+o)}let a=n&&ko.g?ko.g:null;return n&&(ko.g=ko[o]),((c,d,f,p)=>{p?d.data=d.data.replace(p,c):d.data.indexOf(c)===-1&&(d.data=f?c+d.data:d.data+c)})(ko[o],t,r,a),o},Eue=(e,t,n)=>e.reduce((r,i,s)=>{let o=t[s];if(o&&o.call){let a=o(n),c=a&&a.props&&a.props.className||/^go/.test(a)&&a;o=c?"."+c:a&&typeof a=="object"?a.props?"":il(a,""):a===!1?"":a}return r+i+(o??"")},"");function X_(e){let t=this||{},n=e.call?e(t.p):e;
35return Sue(n.unshift?n.raw?Eue(n,[].slice.call(arguments,1),t.p):n.reduce((r,i)=>Object.assign(r,i&&i.call?i(t.p):i),{}):n,_ue(t.target),t.g,t.o,t.k)}let x$,r2,i2;X_.bind({g:1});let sa=X_.bind({k:1});function xue(e,t,n,r){il.p=t,x$=e,r2=n,i2=r}function Nl(e,t){let n=this||{};return function(){let r=arguments;function i(s,o){let a=Object.assign({},s),c=a.className||i.className;n.p=Object.assign({theme:r2&&r2()},a),n.o=/ *go\d+/.test(c),a.className=X_.apply(n,r)+(c?" "+c:"");let d=e;return e[0]&&(d=a.as||e,delete a.as),i2&&d[0]&&i2(a),x$(d,a)}return i}}var Cue=e=>typeof e=="function",O0=(e,t)=>Cue(e)?e(t):e,kue=(()=>{let e=0;return()=>(++e).toString()})(),C$=(()=>{let e;return()=>{if(e===void 0&&typeof window<"u"){let t=matchMedia("(prefers-reduced-motion: reduce)");e=!t||t.matches}return e}})(),Tue=20,aT="default",k$=(e,t)=>{let{toastLimit:n}=e.settings;switch(t.type){case 0:return{...e,toasts:[t.toast,...e.toasts].slice(0,n)};case 1:return{...e,toasts:e.toasts.map(o=>o.id===t.toast.id?{...o,...t.toast}:o)};case 2:let{toast:r}=t;return k$(e,{type:e.toasts.find(o=>o.id===r.id)?1:0,toast:r});case 3:let{toastId:i}=t;return{...e,toasts:e.toasts.map(o=>o.id===i||i===void 0?{...o,dismissed:!0,visible:!1}:o)};case 4:return t.toastId===void 0?{...e,toasts:[]}:{...e,toasts:e.toasts.filter(o=>o.id!==t.toastId)};case 5:return{...e,pausedAt:t.time};case 6:let s=t.time-(e.pausedAt||0);return{...e,pausedAt:void 0,toasts:e.toasts.map(o=>({...o,pauseDuration:o.pauseDuration+s}))}}},Ov=[],T$={toasts:[],pausedAt:void 0,settings:{toastLimit:Tue}},Ys={},R$=(e,t=aT)=>{Ys[t]=k$(Ys[t]||T$,e),Ov.forEach(([n,r])=>{n===t&&r(Ys[t])})},P$=e=>Object.keys(Ys).forEach(t=>R$(e,t)),Rue=e=>Object.keys(Ys).find(t=>Ys[t].toasts.some(n=>n.id===e)),Q_=(e=aT)=>t=>{R$(t,e)},Pue={blank:4e3,error:4e3,success:2e3,loading:1/0,custom:4e3},Oue=(e={},t=aT)=>{let[n,r]=g.useState(Ys[t]||T$),i=g.useRef(Ys[t]);g.useEffect(()=>(i.current!==Ys[t]&&r(Ys[t]),Ov.push([t,r]),()=>{let o=Ov.findIndex(([a])=>a===t);o>-1&&Ov.splice(o,1)}),[t]);let s=n.toasts.map(o=>{var a,c,d;return{...e,...e[o.type],...o,removeDelay:o.removeDelay||((a=e[o.type])==null?void 0:a.removeDelay)||e?.removeDelay,duration:o.duration||((c=e[o.type])==null?void 0:c.duration)||e?.duration||Pue[o.type],style:{...e.style,...(d=e[o.type])==null?void 0:d.style,...o.style}}});return{...n,toasts:s}},Aue=(e,t="blank",n)=>({createdAt:Date.now(),visible:!0,dismissed:!1,type:t,ariaProps:{role:"status","aria-live":"polite"},message:e,pauseDuration:0,...n,id:n?.id||kue()}),Um=e=>(t,n)=>{let r=Aue(t,e,n);return Q_(r.toasterId||Rue(r.id))({type:2,toast:r}),r.id},or=(e,t)=>Um("blank")(e,t);or.error=Um("error");or.success=Um("success");or.loading=Um("loading");or.custom=Um("custom");or.dismiss=(e,t)=>{let n={type:3,toastId:e};t?Q_(t)(n):P$(n)};or.dismissAll=e=>or.dismiss(void 0,e);or.remove=(e,t)=>{let n={type:4,toastId:e};t?Q_(t)(n):P$(n)};or.removeAll=e=>or.remove(void 0,e);or.promise=(e,t,n)=>{let r=or.loading(t.loading,{...n,...n?.loading});return typeof e=="function"&&(e=e()),e.then(i=>{let s=t.success?O0(t.success,i):void 0;return s?or.success(s,{id:r,...n,...n?.success}):or.dismiss(r),i}).catch(i=>{let s=t.error?O0(t.error,i):void 0;s?or.error(s,{id:r,...n,...n?.error}):or.dismiss(r)}),e};var Iue=1e3,Mue=(e,t="default")=>{let{toasts:n,pausedAt:r}=Oue(e,t),i=g.useRef(new Map).current,s=g.useCallback((p,m=Iue)=>{if(i.has(p))return;let v=setTimeout(()=>{i.delete(p),o({type:4,toastId:p})},m);i.set(p,v)},[]);g.useEffect(()=>{if(r)return;let p=Date.now(),m=n.map(v=>{if(v.duration===1/0)return;let w=(v.duration||0)+v.pauseDuration-(p-v.createdAt);if(w<0){v.visible&&or.dismiss(v.id);return}return setTimeout(()=>or.dismiss(v.id,t),w)});return()=>{m.forEach(v=>v&&clearTimeout(v))}},[n,r,t]);let o=g.useCallback(Q_(t),[t]),a=g.useCallback(()=>{o({type:5,time:Date.now()})},[o]),c=g.useCallback((p,m)=>{o({type:1,toast:{id:p,height:m}})},[o]),d=g.useCallback(()=>{r&&o({type:6,time:Date.now()})},[r,o]),f=g.useCallback((p,m)=>{let{reverseOrder:v=!1,gutter:w=8,defaultPosition:_}=m||{},b=n.filter(D=>(D.position||_)===(p.position||_)&&D.height),C=b.findIndex(D=>D.id===p.id),P=b.filter((D,F)=>F<C&&D.visible).length;
35return b.filter(D=>D.visible).slice(...v?[P+1]:[0,P]).reduce((D,F)=>D+(F.height||0)+w,0)},[n]);return g.useEffect(()=>{n.forEach(p=>{if(p.dismissed)s(p.id,p.removeDelay);else{let m=i.get(p.id);m&&(clearTimeout(m),i.delete(p.id))}})},[n,s]),{toasts:n,handlers:{updateHeight:c,startPause:a,endPause:d,calculateOffset:f}}},Due=sa` 36from { 37 transform: scale(0) rotate(45deg); 38 opacity: 0; 39} 40to { 41 transform: scale(1) rotate(45deg); 42 opacity: 1; 43}`,Lue=sa` 44from { 45 transform: scale(0); 46 opacity: 0; 47} 48to { 49 transform: scale(1); 50 opacity: 1; 51}`,Nue=sa` 52from { 53 transform: scale(0) rotate(90deg); 54 opacity: 0; 55} 56to { 57 transform: scale(1) rotate(90deg); 58 opacity: 1; 59}`,$ue=Nl("div")` 60 width: 20px; 61 opacity: 0; 62 height: 20px; 63 border-radius: 10px; 64 background: ${e=>e.primary||"#ff4b4b"}; 65 position: relative; 66 transform: rotate(45deg); 67 68 animation: ${Due} 0.3s cubic-bezier(0.175, 0.885, 0.32, 1.275) 69 forwards; 70 animation-delay: 100ms; 71 72 &:after, 73 &:before { 74 content: ''; 75 animation: ${Lue} 0.15s ease-out forwards; 76 animation-delay: 150ms; 77 position: absolute; 78 border-radius: 3px; 79 opacity: 0; 80 background: ${e=>e.secondary||"#fff"}; 81 bottom: 9px; 82 left: 4px; 83 height: 2px; 84 width: 12px; 85 } 86 87 &:before { 88 animation: ${Nue} 0.15s ease-out forwards; 89 animation-delay: 180ms; 90 transform: rotate(90deg); 91 } 92`,jue=sa` 93 from { 94 transform: rotate(0deg); 95 } 96 to { 97 transform: rotate(360deg); 98 } 99`,Fue=Nl("div")` 100 width: 12px; 101 height: 12px; 102 box-sizing: border-box; 103 border: 2px solid; 104 border-radius: 100%; 105 border-color: ${e=>e.secondary||"#e0e0e0"}; 106 border-right-color: ${e=>e.primary||"#616161"}; 107 animation: ${jue} 1s linear infinite; 108`,Uue=sa` 109from { 110 transform: scale(0) rotate(45deg); 111 opacity: 0; 112} 113to { 114 transform: scale(1) rotate(45deg); 115 opacity: 1; 116}`,zue=sa` 1170% { 118 height: 0; 119 width: 0; 120 opacity: 0; 121} 12240% { 123 height: 0; 124 width: 6px; 125 opacity: 1; 126} 127100% { 128 opacity: 1; 129 height: 10px; 130}`,Bue=Nl("div")` 131 width: 20px; 132 opacity: 0; 133 height: 20px; 134 border-radius: 10px; 135 background: ${e=>e.primary||"#61d345"}; 136 position: relative; 137 transform: rotate(45deg); 138 139 animation: ${Uue} 0.3s cubic-bezier(0.175, 0.885, 0.32, 1.275) 140 forwards; 141 animation-delay: 100ms; 142 &:after { 143 content: ''; 144 box-sizing: border-box; 145 animation: ${zue} 0.2s ease-out forwards; 146 opacity: 0; 147 animation-delay: 200ms; 148 position: absolute; 149 border-right: 2px solid; 150 border-bottom: 2px solid; 151 border-color: ${e=>e.secondary||"#fff"}; 152 bottom: 6px; 153 left: 6px; 154 height: 10px; 155 width: 6px; 156 } 157`,Hue=Nl("div")` 158 position: absolute; 159`,Vue=Nl("div")` 160 position: relative; 161 display: flex; 162 justify-content: center; 163 align-items: center; 164 min-width: 20px; 165 min-height: 20px; 166`,Wue=sa` 167from { 168 transform: scale(0.6); 169 opacity: 0.4; 170} 171to { 172 transform: scale(1); 173 opacity: 1; 174}`,que=Nl("div")` 175 position: relative; 176 transform: scale(0.6); 177 opacity: 0.4; 178 min-width: 20px; 179 animation: ${Wue} 0.3s 0.12s cubic-bezier(0.175, 0.885, 0.32, 1.275) 180 forwards; 181`,Kue=({toast:e})=>{let{icon:t,type:n,iconTheme:r}=e;return t!==void 0?typeof t=="string"?g.createElement(que,null,t):t:n==="blank"?null:g.createElement(Vue,null,g.createElement(Fue,{...r}),n!=="loading"&&g.createElement(Hue,null,n==="error"?g.createElement($ue,{...r}):g.createElement(Bue,{...r})))},Gue=e=>` 1820% {transform: translate3d(0,${e*-200}%,0) scale(.6); opacity:.5;} 183100% {transform: translate3d(0,0,0) scale(1); opacity:1;} 184`,Yue=e=>` 1850% {transform: translate3d(0,0,-1px) scale(1); opacity:1;} 186100% {transform: translate3d(0,${e*-150}%,-1px) scale(.6); opacity:0;} 187`,Jue="0%{opacity:0;} 100%{opacity:1;}",Zue="0%{opacity:1;} 100%{opacity:0;}",Xue=Nl("div")` 188 display: flex; 189 align-items: center; 190 background: #fff; 191 color: #363636; 192 line-height: 1.3; 193 will-change: transform; 194 box-shadow: 0 3px 10px rgba(0, 0, 0, 0.1), 0 3px 3px rgba(0, 0, 0, 0.05); 195 max-width: 350px; 196 pointer-events: auto; 197 padding: 8px 10px; 198 border-radius: 8px; 199`,Que=Nl("div")` 200 display: flex; 201 justify-content: center; 202 margin: 4px 10px; 203 color: inherit; 204 flex: 1 1 auto; 205 white-space: pre-line; 206`,ede=(e,t)=>{let n=e.includes("top")?1:-1,[r,i]=C$()?[Jue,Zue]:[Gue(n),Yue(n)];return{animation:t?`${sa(r)} 0.35s cubic-bezier(.21,1.02,.73,1) forwards`:`${sa(i)} 0.4s forwards cubic-bezier(.06,.71,.55,1)`}},tde=g.memo(({toast:e,position:t,style:n,children:r})=>
206{let i=e.height?ede(e.position||t||"top-center",e.visible):{opacity:0},s=g.createElement(Kue,{toast:e}),o=g.createElement(Que,{...e.ariaProps},O0(e.message,e));return g.createElement(Xue,{className:e.className,style:{...i,...n,...e.style}},typeof r=="function"?r({icon:s,message:o}):g.createElement(g.Fragment,null,s,o))});xue(g.createElement);var nde=({id:e,className:t,style:n,onHeightUpdate:r,children:i})=>{let s=g.useCallback(o=>{if(o){let a=()=>{let c=o.getBoundingClientRect().height;r(e,c)};a(),new MutationObserver(a).observe(o,{subtree:!0,childList:!0,characterData:!0})}},[e,r]);return g.createElement("div",{ref:s,className:t,style:n},i)},rde=(e,t)=>{let n=e.includes("top"),r=n?{top:0}:{bottom:0},i=e.includes("center")?{justifyContent:"center"}:e.includes("right")?{justifyContent:"flex-end"}:{};return{left:0,right:0,display:"flex",position:"absolute",transition:C$()?void 0:"all 230ms cubic-bezier(.21,1.02,.73,1)",transform:`translateY(${t*(n?1:-1)}px)`,...r,...i}},ide=X_` 207 z-index: 9999; 208 > * { 209 pointer-events: auto; 210 } 211`,Ky=16,sde=({reverseOrder:e,position:t="top-center",toastOptions:n,gutter:r,children:i,toasterId:s,containerStyle:o,containerClassName:a})=>{let{toasts:c,handlers:d}=Mue(n,s);return g.createElement("div",{"data-rht-toaster":s||"",style:{position:"fixed",zIndex:9999,top:Ky,left:Ky,right:Ky,bottom:Ky,pointerEvents:"none",...o},className:a,onMouseEnter:d.startPause,onMouseLeave:d.endPause},c.map(f=>{let p=f.position||t,m=d.calculateOffset(f,{reverseOrder:e,gutter:r,defaultPosition:t}),v=rde(p,m);return g.createElement(nde,{id:f.id,key:f.id,onHeightUpdate:d.updateHeight,className:f.visible?ide:"",style:v},f.type==="custom"?O0(f.message,f):i?i(f):g.createElement(tde,{toast:f,position:p}))}))},gS=or;class zm extends Error{get name(){return this.kind}constructor(t){super(t),Object.setPrototypeOf(this,new.target.prototype)}}class lT extends zm{kind="FetchError"}class ode extends zm{kind="InvalidJSON"}class s2 extends zm{kind="ParsingFailure";issues;url;constructor(t,n,r){super(t),this.issues=n,this.url=r}}class yu extends zm{statusCode;url;constructor(t,n,r){super(r||`HTTP ${t} error at ${n}`),this.statusCode=t,this.url=n}}class O$ extends yu{kind="BadRequest";validationErrors;constructor(t,n,r=[],i){super(t,n,i||"Request contains invalid values."),this.validationErrors=r}getFormattedErrors(){return this.validationErrors.length===0?[this.message]:this.validationErrors.flatMap(t=>t.messages.map(n=>`${t.target}: ${n}`))}}class A$ extends yu{kind="Unauthorized";constructor(t,n,r){super(t,n,r||"Authentication required.")}}class I$ extends yu{kind="Forbidden";constructor(t,n,r){super(t,n,r||"Access denied.")}}class M$ extends yu{kind="NotFound";constructor(t,n,r){super(t,n,r||"Resource not found.")}}class D$ extends yu{kind="TooManyRequests";constructor(t,n,r){super(t,n,r||"Too many requests. Please try again later.")}}class cT extends yu{kind="InternalServerError";constructor(t,n,r){super(t,n,r||"Internal server error.")}}class uT extends yu{kind="UnknownStatusCodeError";constructor(t,n,r){super(t,n,r||`Unexpected status code: ${t}`)}}class ade extends zm{kind="PollingError"}const Hr=Symbol.for("@ts-pattern/matcher"),L$=Symbol.for("@ts-pattern/isVariadic"),A0="@ts-pattern/anonymous-select-key",o2=e=>!!(e&&typeof e=="object"),Av=e=>e&&!!e[Hr],Jn=(e,t,n)=>{if(Av(e)){const r=e[Hr](),{matched:i,selections:s}=r.match(t);return i&&s&&Object.keys(s).forEach(o=>n(o,s[o])),i}if(o2(e)){if(!o2(t))return!1;if(Array.isArray(e)){if(!Array.isArray(t))return!1;let r=[],i=[],s=[];for(const o of e.keys()){const a=e[o];Av(a)&&a[L$]?s.push(a):s.length?i.push(a):r.push(a)}if(s.length){if(s.length>1)throw new Error("Pattern error: Using `...P.array(...)` several times in a single pattern is not allowed.");if(t.length<r.length+i.length)return!1;const o=t.slice(0,r.length),a=i.length===0?[]:t.slice(-i.length),c=t.slice(r.length,i.length===0?1/0:-i.length);return r.every((d,f)=>Jn(d,o[f],n))&&i.every((d,f)=>Jn(d,a[f],n))&&(s.length===0||Jn(s[0],c,n))}return e.length===t.length&&e.every((o,a)=>Jn(o,t[a],n))}return Reflect.ownKeys(e).every(r=>{const i=e[r];return(r in t||Av(s=i)&&s[Hr]().matcherType==="optional")&&Jn(i,t[r],n);var s})}return Object.is(t,e)},Br=e=>{var t,n,r;return o2(e)?Av(e)?(t=(n=(r=e[Hr]()).getSelectionKeys)==null?void 0:n.call(r))!=null?t:[]:Array.isArray(e)?qp(e,Br):qp(Object.values(e),Br):[]},qp=(e,t)=>e.reduce((n,r)=>n.concat(t(r)),[]);function lde(...e){if(e.length===1){const[t]=e;return n=>Jn(t,n,()=>{})}if(e.length===2){const[t,n]=e;return Jn(t,n,()=>{})}throw new Error(`isMatching wasn't given the right number of arguments: expected 1 or 2, received ${e.length}.`)}function ar(e){return Object.assign(e,{optional:()=>dT(e),and:t=>mn(e,t),or:t=>N$(e,t),select:t=>t===void 0?Kp(e):Kp(t,e)})}function a2(e){return Object.assign((t=>Object.assign(t,{[Symbol.iterator](){let n=0;const r=[{value:Object.assign(t,{[L$]:!0}),done:!1},{done:!0,value:void 0}];return{next:()=>{var i;return(i=r[n++])!=null?i:r.at(-1)}}}}))(e),{optional:()=>a2(dT(e)),select:t=>a2(t===void 0?Kp(e):Kp(t,e))})}function dT(e){return ar({[Hr]:()=>({match:t=>{let n={};const r=(i,s)=>{n[i]=s};return t===void 0?(Br(e).forEach(i=>
211r(i,void 0)),{matched:!0,selections:n}):{matched:Jn(e,t,r),selections:n}},getSelectionKeys:()=>Br(e),matcherType:"optional"})})}const cde=(e,t)=>{for(const n of e)if(!t(n))return!1;return!0},ude=(e,t)=>{for(const[n,r]of e.entries())if(!t(r,n))return!1;return!0},dde=(e,t)=>{const n=Reflect.ownKeys(e);for(const r of n)if(!t(r,e[r]))return!1;return!0};function mn(...e){return ar({[Hr]:()=>({match:t=>{let n={};const r=(i,s)=>{n[i]=s};return{matched:e.every(i=>Jn(i,t,r)),selections:n}},getSelectionKeys:()=>qp(e,Br),matcherType:"and"})})}function N$(...e){return ar({[Hr]:()=>({match:t=>{let n={};const r=(i,s)=>{n[i]=s};return qp(e,Br).forEach(i=>r(i,void 0)),{matched:e.some(i=>Jn(i,t,r)),selections:n}},getSelectionKeys:()=>qp(e,Br),matcherType:"or"})})}function Lt(e){return{[Hr]:()=>({match:t=>({matched:!!e(t)})})}}function Kp(...e){const t=typeof e[0]=="string"?e[0]:void 0,n=e.length===2?e[1]:typeof e[0]=="string"?void 0:e[0];return ar({[Hr]:()=>({match:r=>{let i={[t??A0]:r};return{matched:n===void 0||Jn(n,r,(s,o)=>{i[s]=o}),selections:i}},getSelectionKeys:()=>[t??A0].concat(n===void 0?[]:Br(n))})})}function $$(e){return!0}function Bs(e){return typeof e=="number"}function qa(e){return typeof e=="string"}function Ka(e){return typeof e=="bigint"}const j$=ar(Lt($$)),fde=ar(Lt($$)),hde=j$,Ga=e=>Object.assign(ar(e),{startsWith:t=>{return Ga(mn(e,(n=t,Lt(r=>qa(r)&&r.startsWith(n)))));var n},endsWith:t=>{return Ga(mn(e,(n=t,Lt(r=>qa(r)&&r.endsWith(n)))));var n},minLength:t=>Ga(mn(e,(n=>Lt(r=>qa(r)&&r.length>=n))(t))),length:t=>Ga(mn(e,(n=>Lt(r=>qa(r)&&r.length===n))(t))),maxLength:t=>Ga(mn(e,(n=>Lt(r=>qa(r)&&r.length<=n))(t))),includes:t=>{return Ga(mn(e,(n=t,Lt(r=>qa(r)&&r.includes(n)))));var n},regex:t=>{return Ga(mn(e,(n=t,Lt(r=>qa(r)&&!!r.match(n)))));var n}}),A5=Ga(Lt(qa)),Hs=e=>Object.assign(ar(e),{between:(t,n)=>Hs(mn(e,((r,i)=>Lt(s=>Bs(s)&&r<=s&&i>=s))(t,n))),lt:t=>Hs(mn(e,(n=>Lt(r=>Bs(r)&&r<n))(t))),gt:t=>Hs(mn(e,(n=>Lt(r=>Bs(r)&&r>n))(t))),lte:t=>Hs(mn(e,(n=>Lt(r=>Bs(r)&&r<=n))(t))),gte:t=>Hs(mn(e,(n=>Lt(r=>Bs(r)&&r>=n))(t))),int:()=>Hs(mn(e,Lt(t=>Bs(t)&&Number.isInteger(t)))),finite:()=>Hs(mn(e,Lt(t=>Bs(t)&&Number.isFinite(t)))),positive:()=>Hs(mn(e,Lt(t=>Bs(t)&&t>0))),negative:()=>Hs(mn(e,Lt(t=>Bs(t)&&t<0)))}),pde=Hs(Lt(Bs)),Ya=e=>Object.assign(ar(e),{between:(t,n)=>Ya(mn(e,((r,i)=>Lt(s=>Ka(s)&&r<=s&&i>=s))(t,n))),lt:t=>Ya(mn(e,(n=>Lt(r=>Ka(r)&&r<n))(t))),gt:t=>Ya(mn(e,(n=>Lt(r=>Ka(r)&&r>n))(t))),lte:t=>Ya(mn(e,(n=>Lt(r=>Ka(r)&&r<=n))(t))),gte:t=>Ya(mn(e,(n=>Lt(r=>Ka(r)&&r>=n))(t))),positive:()=>Ya(mn(e,Lt(t=>Ka(t)&&t>0))),negative:()=>Ya(mn(e,Lt(t=>Ka(t)&&t<0)))}),mde=Ya(Lt(Ka)),gde=ar(Lt(function(e){return typeof e=="boolean"})),yde=ar(Lt(function(e){return typeof e=="symbol"})),vde=ar(Lt(function(e){return e==null})),_de=ar(Lt(function(e){return e!=null}));var F$={__proto__:null,matcher:Hr,optional:dT,array:function(...e){return a2({[Hr]:()=>({match:t=>{if(!Array.isArray(t))return{matched:!1};if(e.length===0)return{matched:!0};const n=e[0];let r={};if(t.length===0)return Br(n).forEach(s=>{r[s]=[]}),{matched:!0,selections:r};const i=(s,o)=>{r[s]=(r[s]||[]).concat([o])};return{matched:t.every(s=>Jn(n,s,i)),selections:r}},getSelectionKeys:()=>e.length===0?[]:Br(e[0])})})},set:function(...e){return ar({[Hr]:()=>({match:t=>{if(!(t instanceof Set))return{matched:!1};let n={};if(t.size===0)return{matched:!0,selections:n};if(e.length===0)return{matched:!0};const r=(s,o)=>{n[s]=(n[s]||[]).concat([o])},i=e[0];return{matched:cde(t,s=>Jn(i,s,r)),selections:n}},getSelectionKeys:()=>e.length===0?[]:Br(e[0])})})},map:function(...e){return ar({[Hr]:()=>({match:t=>{if(!(t instanceof Map))return{matched:!1};let n={};if(t.size===0)return{matched:!0,selections:n};const r=(a,c)=>{n[a]=(n[a]||[]).concat([c])};if(e.length===0)return{matched:!0};var i;if(e.length===1)throw new Error(`\`P.map\` wasn't given enough arguments. Expected (key, value), received ${(i=e[0])==null?void 0:i.toString()}`);const[s,o]=e;return{matched:ude(t,(a,c)=>{const d=Jn(s,c,r),f=Jn(o,a,r);return d&&f}),selections:n}},getSelectionKeys:()=>e.length===0?[]:[...Br(e[0]),...Br(e[1])]})})},record:function(...e){return ar({[Hr]:()=>({match:t=>{if(t===null||typeof t!="object"||Array.isArray(t))return{matched:!1};var n;if(e.length===0)throw new Error(`\`P.record\` wasn't given enough arguments. Expected (value) or (key, value), received ${(n=e[0])==null?void 0:n.toString()}`);let r={};
211const i=(a,c)=>{r[a]=(r[a]||[]).concat([c])},[s,o]=e.length===1?[A5,e[0]]:e;return{matched:dde(t,(a,c)=>{const d=typeof a!="string"||Number.isNaN(Number(a))?null:Number(a),f=d!==null&&Jn(s,d,i),p=Jn(s,a,i),m=Jn(o,c,i);return(p||f)&&m}),selections:r}},getSelectionKeys:()=>e.length===0?[]:[...Br(e[0]),...Br(e[1])]})})},intersection:mn,union:N$,not:function(e){return ar({[Hr]:()=>({match:t=>({matched:!Jn(e,t,()=>{})}),getSelectionKeys:()=>[],matcherType:"not"})})},when:Lt,select:Kp,any:j$,unknown:fde,_:hde,string:A5,number:pde,bigint:mde,boolean:gde,symbol:yde,nullish:vde,nonNullable:_de,instanceOf:function(e){return ar(Lt((function(t){return n=>n instanceof t})(e)))},shape:function(e){return ar(Lt(lde(e)))}};let wde=class extends Error{constructor(t){let n;try{n=JSON.stringify(t)}catch{n=t}super(`Pattern matching error: no pattern matches value ${n}`),this.input=void 0,this.input=t}};const l2={matched:!1,value:void 0};function fT(e){return new bde(e,l2)}let bde=class c2{constructor(t,n){this.input=void 0,this.state=void 0,this.input=t,this.state=n}with(...t){if(this.state.matched)return this;const n=t[t.length-1],r=[t[0]];let i;t.length===3&&typeof t[1]=="function"?i=t[1]:t.length>2&&r.push(...t.slice(1,t.length-1));let s=!1,o={};const a=(d,f)=>{s=!0,o[d]=f},c=!r.some(d=>Jn(d,this.input,a))||i&&!i(this.input)?l2:{matched:!0,value:n(s?A0 in o?o[A0]:o:this.input,this.input)};return new c2(this.input,c)}when(t,n){if(this.state.matched)return this;const r=!!t(this.input);return new c2(this.input,r?{matched:!0,value:n(this.input,this.input)}:l2)}otherwise(t){return this.state.matched?this.state.value:t(this.input)}exhaustive(t=Sde){return this.state.matched?this.state.value:t(this.input)}run(){return this.exhaustive()}returnType(){return this}narrow(){return this}};function Sde(e){throw new wde(e)}const Ede=e=>e instanceof lT||e instanceof ode||e instanceof s2||e instanceof O$||e instanceof A$||e instanceof I$||e instanceof M$||e instanceof D$||e instanceof cT||e instanceof uT||e instanceof ade,xde=e=>e instanceof lT,Cde=e=>e instanceof cT,kde=e=>e instanceof uT,Tde=e=>Cde(e)||kde(e),Rde=e=>fT(e).with({kind:"InvalidJSON"},()=>!0).with({kind:"ParsingFailure"},()=>!0).with({kind:"UnknownStatusCodeError"},()=>!0).with({kind:"BadRequest"},()=>!1).with({kind:"Unauthorized"},()=>!1).with({kind:"Forbidden"},()=>!1).with({kind:"NotFound"},()=>!1).with({kind:"TooManyRequests"},()=>!1).with({kind:"FetchError"},()=>!1).with({kind:"InternalServerError"},()=>!1).with({kind:"PollingError"},()=>
211!1).exhaustive(),U$=(e,t,n)=>{const r=n?.errorMessage,i=n?.validationErrors??[];return fT(e).with(400,()=>new O$(e,t,i,r)).with(401,()=>new A$(e,t,r)).with(403,()=>new I$(e,t,r)).with(404,()=>new M$(e,t,r)).with(429,()=>new D$(e,t,r)).with(F$.union(500,502,503,504),()=>new cT(e,t,r)).otherwise(()=>new uT(e,t,r))},Pde=e=>{const t=e.config?.url??"unknown";if(!e.response)return new lT(e.message||`Network error: ${t}`);const{status:n,data:r}=e.response;return U$(n,t,r)},I5=e=>fT(e).with({kind:"BadRequest"},t=>t.getFormattedErrors().join(` 212`)||t.message).with({kind:"Unauthorized"},()=>"Please log in to continue.").with({kind:"Forbidden"},()=>"You don't have permission to perform this action.").with({kind:"NotFound"},()=>"The requested resource was not found.").with({kind:"InternalServerError"},()=>"Something went wrong on our end. Please try again later.").with({kind:"FetchError"},()=>"Network error. Please check your connection.").with({kind:F$.union("ParsingFailure","InvalidJSON")},()=>"Received an unexpected response from the server.").with({kind:"PollingError"},()=>"Failed to get updates. Please refresh the page.").with({kind:"TooManyRequests"},t=>t.message).with({kind:"UnknownStatusCodeError"},()=>"An unexpected error occurred.").exhaustive(),hT=new lX({defaultOptions:{queries:{retry:!1,refetchOnWindowFocus:!1,refetchOnReconnect:!1}},queryCache:new d7({onError:e=>{M5(e)}}),mutationCache:new u7({onError:e=>{M5(e)}})}),M5=e=>{Ede(e)?(Rde(e)&&ia(e),gS.error(I5(e),{id:I5(e)})):e instanceof Error?(ia(e),gS.error(e.message||"An unexpected error occurred")):gS.error("An unexpected error occurred")};var z$=e=>{throw TypeError(e)},Ode=(e,t,n)=>t.has(e)||z$("Cannot "+n),yS=(e,t,n)=>(Ode(e,t,"read from private field"),n?n.call(e):t.get(e)),Ade=(e,t,n)=>t.has(e)?z$("Cannot add the same private member more than once"):t instanceof WeakSet?t.add(e):t.set(e,n),D5="popstate";function Ide(e={}){function t(r,i){let{pathname:s,search:o,hash:a}=r.location;return Gp("",{pathname:s,search:o,hash:a},i.state&&i.state.usr||null,i.state&&i.state.key||"default")}function n(r,i){return typeof i=="string"?i:oo(i)}return Dde(t,n,null,e)}function Ct(e,t){if(e===!1||e===null||typeof e>"u")throw new Error(t)}function Dn(e,t){if(!e){typeof console<"u"&&console.warn(t);try{throw new Error(t)}catch{}}}function Mde(){return Math.random().toString(36).substring(2,10)}function L5(e,t){return{usr:e.state,key:e.key,idx:t}}function Gp(e,t,n=null,r){return{pathname:typeof e=="string"?e:e.pathname,search:"",hash:"",...typeof t=="string"?$l(t):t,state:n,key:t&&t.key||r||Mde()}}function oo({pathname:e="/",search:t="",hash:n=""}){return t&&t!=="?"&&(e+=t.charAt(0)==="?"?t:"?"+t),n&&n!=="#"&&(e+=n.charAt(0)==="#"?n:"#"+n),e}function $l(e){let t={};if(e){let n=e.indexOf("#");n>=0&&(t.hash=e.substring(n),e=e.substring(0,n));let r=e.indexOf("?");r>=0&&(t.search=e.substring(r),e=e.substring(0,r)),e&&(t.pathname=e)}return t}function Dde(e,t,n,r={}){let{window:i=document.defaultView,v5Compat:s=!1}=r,o=i.history,a="POP",c=null,d=f();d==null&&(d=0,o.replaceState({...o.state,idx:d},""));function f(){return(o.state||{idx:null}).idx}function p(){a="POP";let b=f(),C=b==null?null:b-d;d=b,c&&c({action:a,location:_.location,delta:C})}function m(b,C){a="PUSH";let P=Gp(_.location,b,C);d=f()+1;let D=L5(P,d),F=_.createHref(P);try{o.pushState(D,"",F)}catch(R){if(R instanceof DOMException&&R.name==="DataCloneError")throw R;i.location.assign(F)}s&&c&&c({action:a,location:_.location,delta:1})}function v(b,C){a="REPLACE";let P=Gp(_.location,b,C);d=f();let D=L5(P,d),F=_.createHref(P);o.replaceState(D,"",F),s&&c&&c({action:a,location:_.location,delta:0})}function w(b){return B$(b)}let _={get action(){return a},get location(){return e(i,o)},listen(b){if(c)throw new Error("A history only accepts one active listener");return i.addEventListener(D5,p),c=b,()=>{i.removeEventListener(D5,p),c=null}},createHref(b){return t(i,b)},createURL:w,encodeLocation(b){let C=w(b);return{pathname:C.pathname,search:C.search,hash:C.hash}},push:m,replace:v,go(b){return o.go(b)}};return _}function B$(e,t=!1){let n="http://localhost";
212typeof window<"u"&&(n=window.location.origin!=="null"?window.location.origin:window.location.href),Ct(n,"No window.location.(origin|href) available to create URL");let r=typeof e=="string"?e:oo(e);return r=r.replace(/ $/,"%20"),!t&&r.startsWith("//")&&(r=n+r),new URL(r,n)}var Qh,N5=class{constructor(e){if(Ade(this,Qh,new Map),e)for(let[t,n]of e)this.set(t,n)}get(e){if(yS(this,Qh).has(e))return yS(this,Qh).get(e);if(e.defaultValue!==void 0)return e.defaultValue;throw new Error("No value found for context")}set(e,t){yS(this,Qh).set(e,t)}};Qh=new WeakMap;var Lde=new Set(["lazy","caseSensitive","path","id","index","children"]);function Nde(e){return Lde.has(e)}var $de=new Set(["lazy","caseSensitive","path","id","index","middleware","children"]);function jde(e){return $de.has(e)}function Fde(e){return e.index===!0}function Yp(e,t,n=[],r={},i=!1){return e.map((s,o)=>{let a=[...n,String(o)],c=typeof s.id=="string"?s.id:a.join("-");if(Ct(s.index!==!0||!s.children,"Cannot specify children on an index route"),Ct(i||!r[c],`Found a route id collision on i
212d "${c}". Route id's must be globally unique within Data Router usages`),Fde(s)){let d={...s,id:c};return r[c]=$5(d,t(d)),d}else{let d={...s,id:c,children:void 0};return r[c]=$5(d,t(d)),s.children&&(d.children=Yp(s.children,t,a,r,i)),d}})}function $5(e,t){return Object.assign(e,{...t,...typeof t.lazy=="object"&&t.lazy!=null?{lazy:{...e.lazy,...t.lazy}}:{}})}function sl(e,t,n="/"){return ep(e,t,n,!1)}function ep(e,t,n,r){let i=typeof t=="string"?$l(t):t,s=is(i.pathname||"/",n);if(s==null)return null;let o=H$(e);zde(o);let a=null;for(let c=0;a==null&&c<o.length;++c){let d=Xde(s);a=Jde(o[c],d,r)}return a}function Ude(e,t){let{route:n,pathname:r,params:i}=e;return{id:n.id,pathname:r,params:i,data:t[n.id],loaderData:t[n.id],handle:n.handle}}function H$(e,t=[],n=[],r="",i=!1){let s=(o,a,c=i,d)=>{let f={relativePath:d===void 0?o.path||"":d,caseSensitive:o.caseSensitive===!0,childrenIndex:a,route:o};if(f.relativePath.startsWith("/")){if(!f.relativePath.startsWith(r)&&c)return;Ct(f.relativePath.startsWith(r),`Absolute route path "${f.relativePath}" nested under path "${r}" is not valid. An absolute child route path must start with the combined path of all its parent routes.`),f.relativePath=f.relativePath.slice(r.length)}let p=Xs([r,f.relativePath]),m=n.concat(f);o.children&&o.children.length>0&&(Ct(o.index!==!0,`Index routes must not have child routes. Please remove all child routes from route path "${p}".`),H$(o.children,t,m,p,c)),!(o.path==null&&!o.index)&&t.push({path:p,score:Gde(p,o.index),routesMeta:m})};return e.forEach((o,a)=>{if(o.path===""||!o.path?.includes("?"))s(o,a);else for(let c of V$(o.path))s(o,a,!0,c)}),t}function V$(e){let t=e.split("/");if(t.length===0)return[];let[n,...r]=t,i=n.endsWith("?"),s=n.replace(/\?$/,"");if(r.length===0)return i?[s,""]:[s];let o=V$(r.join("/")),a=[];return a.push(...o.map(c=>c===""?s:[s,c].join("/"))),i&&a.push(...o),a.map(c=>e.startsWith("/")&&c===""?"/":c)}function zde(e){e.sort((t,n)=>t.score!==n.score?n.score-t.score:Yde(t.routesMeta.map(r=>r.childrenIndex),n.routesMeta.map(r=>r.childrenIndex)))}var Bde=/^:[\w-]+$/,Hde=3,Vde=2,Wde=1,qde=10,Kde=-2,j5=e=>e==="*";function Gde(e,t){let n=e.split("/"),r=n.length;return n.some(j5)&&(r+=Kde),t&&(r+=Vde),n.filter(i=>!j5(i)).reduce((i,s)=>i+(Bde.test(s)?Hde:s===""?Wde:qde),r)}function Yde(e,t){return e.length===t.length&&e.slice(0,-1).every((r,i)=>r===t[i])?e[e.length-1]-t[t.length-1]:0}function Jde(e,t,n=!1){let{routesMeta:r}=e,i={},s="/",o=[];for(let a=0;a<r.length;++a){let c=r[a],d=a===r.length-1,f=s==="/"?t:t.slice(s.length)||"/",p=I0({path:c.relativePath,caseSensitive:c.caseSensitive,end:d},f),m=c.route;if(!p&&d&&n&&!r[r.length-1].route.index&&(p=I0({path:c.relativePath,caseSensitive:c.caseSensitive,end:!1},f)),!p)return null;
212Object.assign(i,p.params),o.push({params:i,pathname:Xs([s,p.pathname]),pathnameBase:tfe(Xs([s,p.pathnameBase])),route:m}),p.pathnameBase!=="/"&&(s=Xs([s,p.pathnameBase]))}return o}function I0(e,t){typeof e=="string"&&(e={path:e,caseSensitive:!1,end:!0});let[n,r]=Zde(e.path,e.caseSensitive,e.end),i=t.match(n);if(!i)return null;let s=i[0],o=s.replace(/(.)\/+$/,"$1"),a=i.slice(1);return{params:r.reduce((d,{paramName:f,isOptional:p},m)=>{if(f==="*"){let w=a[m]||"";o=s.slice(0,s.length-w.length).replace(/(.)\/+$/,"$1")}const v=a[m];return p&&!v?d[f]=void 0:d[f]=(v||"").replace(/%2F/g,"/"),d},{}),pathname:s,pathnameBase:o,pattern:e}}function Zde(e,t=!1,n=!0){Dn(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=[],i="^"+e.replace(/\/*\*?$/,"").replace(/^\/*/,"/").replace(/[\\.*+^${}|()[\]]/g,"\\$&").replace(/\/:([\w-]+)(\?)?/g,(o,a,c)=>(r.push({paramName:a,isOptional:c!=null}),c?"/?([^\\/]+)?":"/([^\\/]+)")).replace(/\/([\w-]+)\?(\/|$)/g,"(/$1)?$2");return e.endsWith("*")?(r.push({paramName:"*"}),i+=e==="*"||e==="/*"?"(.*)$":"(?:\\/(.+)|\\/*)$"):n?i+="\\/*$":e!==""&&e!=="/"&&(i+="(?:(?=\\/|$))"),[new RegExp(i,t?void 0:"i"),r]}function Xde(e){try{return e.split("/").map(t=>decodeURIComponent(t).replace(/\//g,"%2F")).join("/")}catch(t){return Dn(!1,`The URL path "${e}" could not be decoded because it is a malformed URL segment. This is probably due to a bad percent encoding (${t}).`),e}}function is(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 Qde({basename:e,pathname:t}){return t==="/"?e:Xs([e,t])}var W$=/^(?:[a-z][a-z0-9+.-]*:|\/\/)/i,pT=e=>W$.test(e);function efe(e,t="/"){let{pathname:n,search:r="",hash:i=""}=typeof e=="string"?$l(e):e,s;return n?(n=n.replace(/\/\/+/g,"/"),n.startsWith("/")?s=F5(n.substring(1),"/"):s=F5(n,t)):s=t,{pathname:s,search:nfe(r),hash:rfe(i)}}function F5(e,t){let n=t.replace(/\/+$/,"").split("/");return e.split("/").forEach(i=>{i===".."?n.length>1&&n.pop():i!=="."&&n.push(i)}),n.length>1?n.join("/"):"/"}function vS(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 q$(e){return e.filter((t,n)=>n===0||t.route.path&&t.route.path.length>0)}function e1(e){let t=q$(e);return t.map((n,r)=>r===t.length-1?n.pathname:n.pathnameBase)}function t1(e,t,n,r=!1){let i;typeof e=="string"?i=$l(e):(i={...e},Ct(!i.pathname||!i.pathname.includes("?"),vS("?","pathname","search",i)),Ct(!i.pathname||!i.pathname.includes("#"),vS("#","pathname","hash",i)),Ct(!i.search||!i.search.includes("#"),vS("#","search","hash",i)));let s=e===""||i.pathname==="",o=s?"/":i.pathname,a;if(o==null)a=n;else{let p=t.length-1;if(!r&&o.startsWith("..")){let m=o.split("/");for(;m[0]==="..";)m.shift(),p-=1;i.pathname=m.join("/")}a=p>=0?t[p]:"/"}let c=efe(i,a),d=o&&o!=="/"&&o.endsWith("/"),f=(s||o===".")&&n.endsWith("/");return!c.pathname.endsWith("/")&&(d||f)&&(c.pathname+="/"),c}var Xs=e=>e.join("/").replace(/\/\/+/g,"/"),tfe=e=>e.replace(/\/+$/,"").replace(/^\/*/,"/"),nfe=e=>!e||e==="?"?"":e.startsWith("?")?e:"?"+e,rfe=e=>!e||e==="#"?"":e.startsWith("#")?e:"#"+e,Bm=class{constructor(e,t,n,r=!1){this.status=e,this.statusText=t||"",this.internal=r,n instanceof Error?(this.data=n.toString(),this.error=n):this.data=n}};function tf(e){return e!=null&&typeof e.status=="number"&&typeof e.statusText=="string"&&typeof e.internal=="boolean"&&"data"in e}function Hm(e){return e.map(t=>t.route.path).filter(Boolean).join("/").replace(/\/\/*/g,"/")||"/"}var K$=typeof window<"u"&&typeof window.document<"u"&&typeof window.document.createElement<"u";function G$(e,t){let n=e;
212if(typeof n!="string"||!W$.test(n))return{absoluteURL:void 0,isExternal:!1,to:n};let r=n,i=!1;if(K$)try{let s=new URL(window.location.href),o=n.startsWith("//")?new URL(s.protocol+n):new URL(n),a=is(o.pathname,t);o.origin===s.origin&&a!=null?n=a+o.search+o.hash:i=!0}catch{Dn(!1,`<Link to="${n}"> contains an invalid URL which will probably break when clicked - please update to a valid URL path.`)}return{absoluteURL:r,isExternal:i,to:n}}var cl=Symbol("Uninstrumented");function ife(e,t){let n={lazy:[],"lazy.loader":[],"lazy.action":[],"lazy.middleware":[],middleware:[],loader:[],action:[]};e.forEach(i=>i({id:t.id,index:t.index,path:t.path,instrument(s){let o=Object.keys(n);for(let a of o)s[a]&&n[a].push(s[a])}}));let r={};if(typeof t.lazy=="function"&&n.lazy.length>0){let i=Sd(n.lazy,t.lazy,()=>{});i&&(r.lazy=i)}if(typeof t.lazy=="object"){let i=t.lazy;["middleware","loader","action"].forEach(s=>{let o=i[s],a=n[`lazy.${s}`];if(typeof o=="function"&&a.length>0){let c=Sd(a,o,()=>{});c&&(r.lazy=Object.assign(r.lazy||{},{[s]:c}))}})}return["loader","action"].forEach(i=>{let s=t[i];if(typeof s=="function"&&n[i].length>0){let o=s[cl]??s,a=Sd(n[i],o,(...c)=>U5(c[0]));a&&(i==="loader"&&o.hydrate===!0&&(a.hydrate=!0),a[cl]=o,r[i]=a)}}),t.middleware&&t.middleware.length>0&&n.middleware.length>0&&(r.middleware=t.middleware.map(i=>{let s=i[cl]??i,o=Sd(n.middleware,s,(...a)=>U5(a[0]));return o?(o[cl]=s,o):i})),r}function sfe(e,t){let n={navigate:[],fetch:[]};if(t.forEach(r=>r({instrument(i){let s=Object.keys(i);for(let o of s)i[o]&&n[o].push(i[o])}})),n.navigate.length>0){let r=e.navigate[cl]??e.navigate,i=Sd(n.navigate,r,(...s)=>{let[o,a]=s;return{to:typeof o=="number"||typeof o=="string"?o:o?oo(o):".",...z5(e,a??{})}});i&&(i[cl]=r,e.navigate=i)}if(n.fetch.length>0){let r=e.fetch[cl]??e.fetch,i=Sd(n.fetch,r,(...s)=>{let[o,,a,c]=s;return{href:a??".",fetcherKey:o,...z5(e,c??{})}});i&&(i[cl]=r,e.fetch=i)}return e}function Sd(e,t,n){return e.length===0?null:async(...r)=>{let i=await Y$(e,n(...r),()=>t(...r),e.length-1);if(i.type==="error")throw i.value;return i.value}}async function Y$(e,t,n,r){let i=e[r],s;if(i){let o,a=async()=>(o?console.error("You cannot call instrumented handlers more than once"):o=Y$(e,t,n,r-1),s=await o,Ct(s,"Expected a result"),s.type==="error"&&s.value instanceof Error?{status:"error",error:s.value}:{status:"success",error:void 0});try{await i(a,t)}catch(c){console.error("An instrumentation function threw an error:",c)}o||await a(),await o}else try{s={type:"success",value:await n()}}catch(o){s={type:"error",value:o}}return s||{type:"error",value:new Error("No result assigned in instrumentation chain.")}}function U5(e){let{request:t,context:n,params:r,unstable_pattern:i}=e;return{request:ofe(t),params:{...r},unstable_pattern:i,context:afe(n)}}function z5(e,t){return{currentUrl:oo(e.state.location),..."formMethod"in t?{formMethod:t.formMethod}:{},..."formEncType"in t?{formEncType:t.formEncType}:{},..."formData"in t?{formData:t.formData}:{},..."body"in t?{body:t.body}:{}}}function ofe(e){return{method:e.method,url:e.url,headers:{get:(...t)=>e.headers.get(...t)}}}function afe(e){if(cfe(e)){let t={...e};return Object.freeze(t),t}else return{get:t=>e.get(t)}}var lfe=Object.getOwnPropertyNames(Object.prototype).sort().join("\0");function cfe(e){if(e===null||typeof e!="object")return!1;const t=Object.getPrototypeOf(e);return t===Object.prototype||t===null||Object.getOwnPropertyNames(t).sort().join("\0")===lfe}var J$=["POST","PUT","PATCH","DELETE"],ufe=new Set(J$),dfe=["GET",...J$],ffe=new Set(dfe),Z$=new Set([301,302,303,307,308]),hfe=new Set([307,308]),_S={state:"idle",location:void 0,formMethod:void 0,formAction:void 0,formEncType:void 0,formData:void 0,json:void 0,text:void 0},pfe={state:"idle",data:void 0,formMethod:void 0,formAction:void 0,formEncType:void 0,formData:void 0,json:void 0,text:void 0},Mh={state:"unblocked",proceed:void 0,reset:void 0,location:void 0},mfe=e=>({hasErrorBoundary:!!e.hasErrorBoundary}),X$="remix-router-transitions",Q$=Symbol("ResetLoaderData");function gfe(e){const t=e.window?e.window:typeof window<"u"?window:void 0,n=typeof t<"u"&&typeof t.document<"u"&&typeof t.document.createElement<"u";Ct(e.routes.length>0,"You must provide a non-empty routes array to createRouter");let r=e.hydrationRouteProperties||[],i=e.mapRouteProperties||mfe,s=i;if(e.unstable_instrumentations){let Y=e.unstable_instrumentations;s=ne=>({...i(ne),...ife(Y.map(ce=>
212ce.route).filter(Boolean),ne)})}let o={},a=Yp(e.routes,s,void 0,o),c,d=e.basename||"/";d.startsWith("/")||(d=`/${d}`);let f=e.dataStrategy||bfe,p={...e.future},m=null,v=new Set,w=null,_=null,b=null,C=e.hydrationData!=null,P=sl(a,e.history.location,d),D=!1,F=null,R;if(P==null&&!e.patchRoutesOnNavigation){let Y=Gi(404,{pathname:e.history.location.pathname}),{matches:ne,route:ce}=Gy(a);R=!0,P=ne,F={[ce.id]:Y}}else if(P&&!e.hydrationData&&Hl(P,a,e.history.location.pathname).active&&(P=null),P)if(P.some(Y=>Y.route.lazy))R=!1;else if(!P.some(Y=>mT(Y.route)))R=!0;else{let Y=e.hydrationData?e.hydrationData.loaderData:null,ne=e.hydrationData?e.hydrationData.errors:null;if(ne){let ce=P.findIndex(me=>ne[me.route.id]!==void 0);R=P.slice(0,ce+1).every(me=>!d2(me.route,Y,ne))}else R=P.every(ce=>!d2(ce.route,Y,ne))}else{R=!1,P=[];let Y=Hl(null,a,e.history.location.pathname);Y.active&&Y.matches&&(D=!0,P=Y.matches)}let I,k={historyAction:e.history.action,location:e.history.location,matches:P,initialized:R,navigation:_S,restoreScrollPosition:e.hydrationData!=null?!1:null,preventScrollReset:!1,revalidation:"idle",loaderData:e.hydrationData&&e.hydrationData.loaderData||{},actionData:e.hydrationData&&e.hydrationData.actionData||null,errors:e.hydrationData&&e.hydrationData.errors||F,fetchers:new Map,blockers:new Map},L="POP",B=null,A=!1,V,K=!1,W=new Map,U=null,q=!1,z=!1,x=new Set,N=new Map,M=0,E=-1,O=new Map,H=new Set,Z=new Map,X=new Map,te=new Set,oe=new Map,le,ye=null;function xe(){if(m=e.history.listen(({action:Y,location:ne,delta:ce})=>{if(le){le(),le=void 0;return}Dn(oe.size===0||ce!=null,"You are trying to use a blocker on a POP navigation to a location that was not created by @remix-run/router. This will fail silently in production. This can happen if you are navigating outside the router via `window.history.pushState`/`window.location.hash` instead of using router navigation APIs. This can also happen if you are using createHashRouter and the user manually changes the URL.");let me=fo({currentLocation:k.location,nextLocation:ne,historyAction:Y});if(me&&ce!=null){let we=new Promise(We=>{le=We});e.history.go(ce*-1),ha(me,{state:"blocked",location:ne,proceed(){ha(me,{state:"proceeding",proceed:void 0,reset:void 0,location:ne}),we.then(()=>e.history.go(ce))},reset(){let We=new Map(k.blockers);We.set(me,Mh),Ue({blockers:We})}}),B?.resolve(),B=null;return}return Rt(Y,ne)}),n){Ffe(t,W);let Y=()=>Ufe(t,W);t.addEventListener("pagehide",Y),U=()=>t.removeEventListener("pagehide",Y)}return k.initialized||Rt("POP",k.location,{initialHydration:!0}),I}function be(){m&&m(),U&&U(),v.clear(),V&&V.abort(),k.fetchers.forEach((Y,ne)=>$f(ne)),k.blockers.forEach((Y,ne)=>xu(ne))}function rt(Y){return v.add(Y),()=>v.delete(Y)}function Ue(Y,ne={}){Y.matches&&(Y.matches=Y.matches.map(we=>{let We=o[we.route.id],De=we.route;return De.element!==We.element||De.errorElement!==We.errorElement||De.hydrateFallbackElement!==We.hydrateFallbackElement?{...we,route:We}:we})),k={...k,...Y};let ce=[],me=[];k.fetchers.forEach((we,We)=>{we.state==="idle"&&(te.has(We)?ce.push(We):me.push(We))}),te.forEach(we=>{!k.fetchers.has(we)&&!N.has(we)&&ce.push(we)}),[...v].forEach(we=>we(k,{deletedFetchers:ce,newErrors:Y.errors??null,viewTransitionOpts:ne.viewTransitionOpts,flushSync:ne.flushSync===!0})),ce.forEach(we=>$f(we)),me.forEach(we=>k.fetchers.delete(we))}function Ve(Y,ne,{flushSync:ce}={}){let me=k.actionData!=null&&k.navigation.formMethod!=null&&Ir(k.navigation.formMethod)&&k.navigation.state==="loading"&&Y.state?._isRedirect!==!0,we;ne.actionData?Object.keys(ne.actionData).length>0?we=ne.actionData:we=null:me?we=k.actionData:we=null;let We=ne.loaderData?Z5(k.loaderData,ne.loaderData,ne.matches||[],ne.errors):k.loaderData,De=k.blockers;De.size>0&&(De=new Map(De),De.forEach((st,Ye)=>De.set(Ye,Mh)));let Be=q?!1:Uf(Y,ne.matches||k.matches),Ge=A===!0||k.navigation.formMethod!=null&&Ir(k.navigation.formMethod)&&Y.state?._isRedirect!==!0;c&&(a=c,c=void 0),q||L==="POP"||(L==="PUSH"?e.history.push(Y,Y.state):L==="REPLACE"&&e.history.replace(Y,Y.state));let He;if(L==="POP"){let st=W.get(k.location.pathname);st&&st.has(Y.pathname)?He={currentLocation:k.location,nextLocation:Y}:W.has(Y.pathname)&&(He={currentLocation:Y,nextLocation:k.location})}else if(K){let st=W.get(k.location.pathname);st?st.add(Y.pathname):(st=new Set([Y.pathname]),W.set(k.location.pathname,st)),He={currentLocation:k.location,nextLocation:Y}}Ue({...ne,actionData:we,loaderData:We,historyAction:L,location:Y,initialized:!0,navigation:_S,revalidation:"idle",restoreScrollPosition:Be,preventScrollReset:Ge,blockers:De},{viewTransitionOpts:He,flushSync:ce===!0}),L="POP",A=!1,K=!1,q=!1,z=!1,B?.resolve(),B=null,ye?.resolve(),ye=null}async function Qe(Y,ne){if(B?.resolve(),B=null,typeof Y=="number"){B||(B=t4());let It=B.promise;return e.history.go(Y),It}let ce=u2(k.location,k.matches,d,Y,ne?.fromRouteId,ne?.relative),{path:me,submission:we,error:We}=B5(!1,ce,ne),De=k.location,Be=Gp(k.location,me,ne&&ne.state);Be={...Be,...e.history.encodeLocation(Be)};let Ge=ne&&ne.replace!=null?ne.replace:void 0,He="PUSH";Ge===!0?He="REPLACE":Ge===!1||we!=null&&Ir(we.formMethod)&&we.formAction===k.location.pathname+k.location.search&&(He="REPLACE");let st=ne&&"preventScrollReset"in ne?ne.preventScrollReset===!0:void 0,Ye=(ne&&ne.flushSync)===!0,Ft=fo({currentLocation:De,nextLocation:Be,historyAction:He});if(Ft){ha(Ft,{state:"blocked",location:Be,proceed(){ha(Ft,{state:"proceeding",proceed:void 0,reset:void 0,location:Be}),Qe(Y,ne)},reset(){let It=new Map(k.blockers);It.set(Ft,Mh),Ue({blockers:It})}});return}await Rt(He,Be,{submission:we,pendingError:We,preventScrollReset:st,replace:ne&&ne.replace,enableViewTransition:ne&&ne.viewTransition,flushSync:Ye,callSiteDefaultShouldRevalidate:ne&&ne.unstable_defaultShouldRevalidate})}function ht(){ye||(ye=t4()),kr(),Ue({revalidation:"loading"});let Y=ye.promise;return k.navigation.state==="submitting"?Y:k.navigation.state==="idle"?(Rt(k.historyAction,k.location,{startUninterruptedRevalidation:!0}
212),Y):(Rt(L||k.historyAction,k.navigation.location,{overrideNavigation:k.navigation,enableViewTransition:K===!0}),Y)}async function Rt(Y,ne,ce){V&&V.abort(),V=null,L=Y,q=(ce&&ce.startUninterruptedRevalidation)===!0,pg(k.location,k.matches),A=(ce&&ce.preventScrollReset)===!0,K=(ce&&ce.enableViewTransition)===!0;let me=c||a,we=ce&&ce.overrideNavigation,We=ce?.initialHydration&&k.matches&&k.matches.length>0&&!D?k.matches:sl(me,ne,d),De=(ce&&ce.flushSync)===!0;if(We&&k.initialized&&!z&&Pfe(k.location,ne)&&!(ce&&ce.submission&&Ir(ce.submission.formMethod))){Ve(ne,{matches:We},{flushSync:De});return}let Be=Hl(We,me,ne.pathname);if(Be.active&&Be.matches&&(We=Be.matches),!We){let{error:Ln,notFoundMatches:ur,route:Jt}=Ls(ne.pathname);Ve(ne,{matches:ur,loaderData:{},errors:{[Jt.id]:Ln}},{flushSync:De});return}V=new AbortController;let Ge=ud(e.history,ne,V.signal,ce&&ce.submission),He=e.getContext?await e.getContext():new N5,st;if(ce&&ce.pendingError)st=[ol(We).route.id,{type:"error",error:ce.pendingError}];else if(ce&&ce.submission&&Ir(ce.submission.formMethod)){let Ln=await it(Ge,ne,ce.submission,We,He,Be.active,ce&&ce.initialHydration===!0,{replace:ce.replace,flushSync:De});if(Ln.shortCircuited)return;if(Ln.pendingActionResult){let[ur,Jt]=Ln.pendingActionResult;if(Si(Jt)&&tf(Jt.error)&&Jt.error.status===404){V=null,Ve(ne,{matches:Ln.matches,loaderData:{},errors:{[ur]:Jt.error}});return}}We=Ln.matches||We,st=Ln.pendingActionResult,we=wS(ne,ce.submission),De=!1,Be.active=!1,Ge=ud(e.history,Ge.url,Ge.signal)}let{shortCircuited:Ye,matches:Ft,loaderData:It,errors:Bn}=await Yt(Ge,ne,We,He,Be.active,we,ce&&ce.submission,ce&&ce.fetcherSubmission,ce&&ce.replace,ce&&ce.initialHydration===!0,De,st,ce&&ce.callSiteDefaultShouldRevalidate);Ye||(V=null,Ve(ne,{matches:Ft||We,...X5(st),loaderData:It,errors:Bn}))}async function it(Y,ne,ce,me,we,We,De,Be={}){kr();let Ge=$fe(ne,ce);if(Ue({navigation:Ge},{flushSync:Be.flushSync===!0}),We){let Ye=await pa(me,ne.pathname,Y.signal);if(Ye.type==="aborted")return{shortCircuited:!0};if(Ye.type==="error"){if(Ye.partialMatches.length===0){let{matches:It,route:Bn}=Gy(a);return{matches:It,pendingActionResult:[Bn.id,{type:"error",error:Ye.error}]}}let Ft=ol(Ye.partialMatches).route.id;return{matches:Ye.partialMatches,pendingActionResult:[Ft,{type:"error",error:Ye.error}]}}else if(Ye.matches)me=Ye.matches;else{let{notFoundMatches:Ft,error:It,route:Bn}=Ls(ne.pathname);return{matches:Ft,pendingActionResult:[Bn.id,{type:"error",error:It}]}}}let He,st=Iv(me,ne);if(!st.route.action&&!st.route.lazy)He={type:"error",error:Gi(405,{method:Y.method,pathname:ne.pathname,routeId:st.route.id})};else{let Ye=$d(s,o,Y,me,st,De?[]:r,we),Ft=await Un(Y,Ye,we,null);if(He=Ft[st.route.id],!He){for(let It of me)if(Ft[It.route.id]){He=Ft[It.route.id];break}}if(Y.signal.aborted)return{shortCircuited:!0}}if(Ac(He)){let Ye;return Be&&Be.replace!=null?Ye=Be.replace:Ye=G5(He.response.headers.get("Location"),new URL(Y.url),d,e.history)===k.location.pathname+k.location.search,await yt(Y,He,!0,{submission:ce,replace:Ye}),{shortCircuited:!0}}if(Si(He)){let Ye=ol(me,st.route.id);return(Be&&Be.replace)!==!0&&(L="PUSH"),{matches:me,pendingActionResult:[Ye.route.id,He,st.route.id]}}return{matches:me,pendingActionResult:[st.route.id,He]}}async function Yt(Y,ne,ce,me,we,We,De,Be,Ge,He,st,Ye,Ft){let It=We||wS(ne,De),Bn=De||Be||e4(It),Ln=!q&&!He;if(we){if(Ln){let nn=Xt(Ye);Ue({navigation:It,...nn!==void 0?{actionData:nn}:{}},{flushSync:st})}let Mt=await pa(ce,ne.pathname,Y.signal);if(Mt.type==="aborted")return{shortCircuited:!0};if(Mt.type==="error"){if(Mt.partialMatches.length===0){let{matches:ga,route:po}=Gy(a);return{matches:ga,loaderData:{},errors:{[po.id]:Mt.error}}}let nn=ol(Mt.partialMatches).route.id;return{matches:Mt.partialMatches,loaderData:{},errors:{[nn]:Mt.error}}}else if(Mt.matches)ce=Mt.matches;else{let{error:nn,notFoundMatches:ga,route:po}=Ls(ne.pathname);return{matches:ga,loaderData:{},errors:{[po.id]:nn}}}}let ur=c||a,{dsMatches:Jt,revalidatingFetchers:Zr}=H5(Y,me,s,o,e.history,k,ce,Bn,ne,He?[]:r,He===!0,z,x,te,Z,H,ur,d,e.patchRoutesOnNavigation!=null,Ye,Ft);if(E=++M,!e.dataStrategy&&!Jt.some(Mt=>Mt.shouldLoad)&&!Jt.some(Mt=>Mt.route.middleware&&Mt.route.middleware.length>0)&&Zr.length===0){let Mt=Su();return Ve(ne,{matches:ce,loaderData:{},errors:Ye&&Si(Ye[1])?{[Ye[0]]:Ye[1].error}:null,...X5(Ye),...Mt?{fetchers:new Map(k.fetchers)}:{}},{flushSync:st}),{shortCircuited:!0}}if(Ln){let Mt={};if(!we){Mt.navigation=It;let nn=Xt(Ye);nn!==void 0&&(Mt.actionData=nn)}Zr.length>0&&(Mt.fetchers=Je(Zr)),Ue(Mt,{flushSync:st})}Zr.forEach(Mt=>{Li(Mt.key),Mt.controller&&N.set(Mt.key,Mt.controller)});let Qt=()=>Zr.forEach(Mt=>Li(Mt.key));V&&V.signal.addEventListener("abort",Qt);let{loaderResults:Wl,fetcherResults:Ni}=await zl(Jt,Zr,Y,me);if(Y.signal.aborted)return{shortCircuited:!0};V&&V.signal.removeEventListener("abort",Qt),Zr.forEach(Mt=>N.delete(Mt.key));let mi=Yy(Wl);if(mi)return await yt(Y,mi.result,!0,{replace:Ge}),{shortCircuited:!0};if(mi=Yy(Ni),mi)return H.add(mi.key),await yt(Y,mi.result,!0,{replace:Ge}),{shortCircuited:!0};let{loaderData:ma,errors:ql}=J5(k,ce,Wl,Ye,Zr,Ni);He&&k.errors&&(ql={...k.errors,...ql});let Ns=Su(),ho=Eu(E),Nr=Ns||ho||Zr.length>0;return{matches:ce,loaderData:ma,errors:ql,...Nr?{fetchers:new Map(k.fetchers)}:{}}}function Xt(Y){if(Y&&!Si(Y[1]))return{[Y[0]]:Y[1].data};if(k.actionData)return Object.keys(k.actionData).length===0?null:k.actionData}function Je(Y){return Y.forEach(ne=>{let ce=k.fetchers.get(ne.key),me=Dh(void 0,ce?ce.data:void 0);k.fetchers.set(ne.key,me)}),new Map(k.fetchers)}async function jt(Y,ne,ce,me){Li(Y);let we=(me&&me.flushSync)===!0,We=c||a,De=u2(k.location,k.matches,d,ce,ne,me?.relative),Be=sl(We,De,d),Ge=Hl(Be,We,De);if(Ge.active&&Ge.matches&&(Be=Ge.matches),!Be){Di(Y,ne,Gi(404,{pathname:De}),{flushSync:we});return}let{path:He,submission:st,error:Ye}=B5(!0,De,me);if(Ye){Di(Y,ne,Ye,{flushSync:we});return}let Ft=e.getContext?await e.getContext():new N5,It=(me&&me.preventScrollReset)===!0;if(st&&Ir(st.formMethod)){await ot(Y,ne,He,Be,Ft,Ge.active,we,It,
212st,me&&me.unstable_defaultShouldRevalidate);return}Z.set(Y,{routeId:ne,path:He}),await on(Y,ne,He,Be,Ft,Ge.active,we,It,st)}async function ot(Y,ne,ce,me,we,We,De,Be,Ge,He){kr(),Z.delete(Y);let st=k.fetchers.get(Y);zn(Y,jfe(Ge,st),{flushSync:De});let Ye=new AbortController,Ft=ud(e.history,ce,Ye.signal,Ge);if(We){let vn=await pa(me,new URL(Ft.url).pathname,Ft.signal,Y);if(vn.type==="aborted")return;if(vn.type==="error"){Di(Y,ne,vn.error,{flushSync:De});return}else if(vn.matches)me=vn.matches;else{Di(Y,ne,Gi(404,{pathname:ce}),{flushSync:De});return}}let It=Iv(me,ce);if(!It.route.action&&!It.route.lazy){let vn=Gi(405,{method:Ge.formMethod,pathname:ce,routeId:ne});Di(Y,ne,vn,{flushSync:De});return}N.set(Y,Ye);let Bn=M,Ln=$d(s,o,Ft,me,It,r,we),ur=await Un(Ft,Ln,we,Y),Jt=ur[It.route.id];if(!Jt){for(let vn of Ln)if(ur[vn.route.id]){Jt=ur[vn.route.id];break}}if(Ft.signal.aborted){N.get(Y)===Ye&&N.delete(Y);return}if(te.has(Y)){if(Ac(Jt)||Si(Jt)){zn(Y,Oo(void 0));return}}else{if(Ac(Jt))if(N.delete(Y),E>Bn){zn(Y,Oo(void 0));return}else return H.add(Y),zn(Y,Dh(Ge)),yt(Ft,Jt,!1,{fetcherSubmission:Ge,preventScrollReset:Be});if(Si(Jt)){Di(Y,ne,Jt.error);return}}let Zr=k.navigation.location||k.location,Qt=ud(e.history,Zr,Ye.signal),Wl=c||a,Ni=k.navigation.state!=="idle"?sl(Wl,k.navigation.location,d):k.matches;Ct(Ni,"Didn't find any matches after fetcher action");let mi=++M;O.set(Y,mi);let ma=Dh(Ge,Jt.data);k.fetchers.set(Y,ma);let{dsMatches:ql,revalidatingFetchers:Ns}=H5(Qt,we,s,o,e.history,k,Ni,Ge,Zr,r,!1,z,x,te,Z,H,Wl,d,e.patchRoutesOnNavigation!=null,[It.route.id,Jt],He);Ns.filter(vn=>vn.key!==Y).forEach(vn=>{let mo=vn.key,Kl=k.fetchers.get(mo),Gl=Dh(void 0,Kl?Kl.data:void 0);k.fetchers.set(mo,Gl),Li(mo),vn.controller&&N.set(mo,vn.controller)}),Ue({fetchers:new Map(k.fetchers)});let ho=()=>Ns.forEach(vn=>Li(vn.key));Ye.signal.addEventListener("abort",ho);let{loaderResults:Nr,fetcherResults:Mt}=await zl(ql,Ns,Qt,we);if(Ye.signal.aborted)return;if(Ye.signal.removeEventListener("abort",ho),O.delete(Y),N.delete(Y),Ns.forEach(vn=>N.delete(vn.key)),k.fetchers.has(Y)){let vn=Oo(Jt.data);k.fetchers.set(Y,vn)}let nn=Yy(Nr);if(nn)return yt(Qt,nn.result,!1,{preventScrollReset:Be});if(nn=Yy(Mt),nn)return H.add(nn.key),yt(Qt,nn.result,!1,{preventScrollReset:Be});let{loaderData:ga,errors:po}=J5(k,Ni,Nr,void 0,Ns,Mt);Eu(mi),k.navigation.state==="loading"&&mi>E?(Ct(L,"Expected pending action"),V&&V.abort(),Ve(k.navigation.location,{matches:Ni,loaderData:ga,errors:po,fetchers:new Map(k.fetchers)})):(Ue({errors:po,loaderData:Z5(k.loaderData,ga,Ni,po),fetchers:new Map(k.fetchers)}),z=!1)}async function on(Y,ne,ce,me,we,We,De,Be,Ge){let He=k.fetchers.get(Y);zn(Y,Dh(Ge,He?He.data:void 0),{flushSync:De});let st=new AbortController,Ye=ud(e.history,ce,st.signal);if(We){let Jt=await pa(me,new URL(Ye.url).pathname,Ye.signal,Y);if(Jt.type==="aborted")return;if(Jt.type==="error"){Di(Y,ne,Jt.error,{flushSync:De});return}else if(Jt.matches)me=Jt.matches;else{Di(Y,ne,Gi(404,{pathname:ce}),{flushSync:De});return}}let Ft=Iv(me,ce);N.set(Y,st);let It=M,Bn=$d(s,o,Ye,me,Ft,r,we),ur=(await Un(Ye,Bn,we,Y))[Ft.route.id];if(N.get(Y)===st&&N.delete(Y),!Ye.signal.aborted){if(te.has(Y)){zn(Y,Oo(void 0));return}if(Ac(ur))if(E>It){zn(Y,Oo(void 0));return}else{H.add(Y),await yt(Ye,ur,!1,{preventScrollReset:Be});return}if(Si(ur)){Di(Y,ne,ur.error);return}zn(Y,Oo(ur.data))}}async function yt(Y,ne,ce,{submission:me,fetcherSubmission:we,preventScrollReset:We,replace:De}={}){ce||(B?.resolve(),B=null),ne.response.headers.has("X-Remix-Revalidate")&&(z=!0);let Be=ne.response.headers.get("Location");Ct(Be,"Expected a Location header on the redirect Response"),Be=G5(Be,new URL(Y.url),d,e.history);let Ge=Gp(k.location,Be,{_isRedirect:!0});if(n){let Bn=!1;if(ne.response.headers.has("X-Remix-Reload-Document"))Bn=!0;else if(pT(Be)){const Ln=B$(Be,!0);Bn=Ln.origin!==t.location.origin||is(Ln.pathname,d)==null}if(Bn){De?t.location.replace(Be):t.location.assign(Be);return}}V=null;let He=De===!0||ne.response.headers.has("X-Remix-Replace")?"REPLACE":"PUSH",{formMethod:st,formAction:Ye,formEncType:Ft}=k.navigation;!me&&!we&&st&&Ye&&Ft&&(me=e4(k.navigation));let It=me||we;if(hfe.has(ne.response.status)&&It&&Ir(It.formMethod))await Rt(He,Ge,{submission:{...It,formAction:Be},preventScrollReset:We||A,enableViewTransition:ce?K:void 0});else{let Bn=wS(Ge,me);await Rt(He,Ge,{overrideNavigation:Bn,fetcherSubmission:we,preventScrollReset:We||A,enableViewTransition:ce?K:void 0})}}async function Un(Y,ne,ce,me){let we,We={};try{we=await Efe(f,Y,ne,me,ce,!1)}catch(De){return ne.filter(Be=>
212Be.shouldLoad).forEach(Be=>{We[Be.route.id]={type:"error",error:De}}),We}if(Y.signal.aborted)return We;if(!Ir(Y.method))for(let De of ne){if(we[De.route.id]?.type==="error")break;!we.hasOwnProperty(De.route.id)&&!k.loaderData.hasOwnProperty(De.route.id)&&(!k.errors||!k.errors.hasOwnProperty(De.route.id))&&De.shouldCallHandler()&&(we[De.route.id]={type:"error",result:new Error(`No result returned from dataStrategy for route ${De.route.id}`)})}for(let[De,Be]of Object.entries(we))if(Mfe(Be)){let Ge=Be.result;We[De]={type:"redirect",response:Tfe(Ge,Y,De,ne,d)}}else We[De]=await kfe(Be);return We}async function zl(Y,ne,ce,me){let we=Un(ce,Y,me,null),We=Promise.all(ne.map(async Ge=>{if(Ge.matches&&Ge.match&&Ge.request&&Ge.controller){let st=(await Un(Ge.request,Ge.matches,me,Ge.key))[Ge.match.route.id];return{[Ge.key]:st}}else return Promise.resolve({[Ge.key]:{type:"error",error:Gi(404,{pathname:Ge.path})}})})),De=await we,Be=(await We).reduce((Ge,He)=>Object.assign(Ge,He),{});return{loaderResults:De,fetcherResults:Be}}function kr(){z=!0,Z.forEach((Y,ne)=>{N.has(ne)&&x.add(ne),Li(ne)})}function zn(Y,ne,ce={}){k.fetchers.set(Y,ne),Ue({fetchers:new Map(k.fetchers)},{flushSync:(ce&&ce.flushSync)===!0})}function Di(Y,ne,ce,me={}){let we=ol(k.matches,ne);$f(Y),Ue({errors:{[we.route.id]:ce},fetchers:new Map(k.fetchers)},{flushSync:(me&&me.flushSync)===!0})}function fa(Y){return X.set(Y,(X.get(Y)||0)+1),te.has(Y)&&te.delete(Y),k.fetchers.get(Y)||pfe}function Bl(Y,ne){Li(Y,ne?.reason),zn(Y,Oo(null))}function $f(Y){let ne=k.fetchers.get(Y);N.has(Y)&&!(ne&&ne.state==="loading"&&O.has(Y))&&Li(Y),Z.delete(Y),O.delete(Y),H.delete(Y),te.delete(Y),x.delete(Y),k.fetchers.delete(Y)}function dg(Y){let ne=(X.get(Y)||0)-1;ne<=0?(X.delete(Y),te.add(Y)):X.set(Y,ne),Ue({fetchers:new Map(k.fetchers)})}function Li(Y,ne){let ce=N.get(Y);ce&&(ce.abort(ne),N.delete(Y))}function fg(Y){for(let ne of Y){let ce=fa(ne),me=Oo(ce.data);k.fetchers.set(ne,me)}}function Su(){let Y=[],ne=!1;for(let ce of H){let me=k.fetchers.get(ce);Ct(me,`Expected fetcher: ${ce}`),me.state==="loading"&&(H.delete(ce),Y.push(ce),ne=!0)}return fg(Y),ne}function Eu(Y){let ne=[];for(let[ce,me]of O)if(me<Y){let we=k.fetchers.get(ce);Ct(we,`Expected fetcher: ${ce}`),we.state==="loading"&&(Li(ce),O.delete(ce),ne.push(ce))}return fg(ne),ne.length>0}function jf(Y,ne){let ce=k.blockers.get(Y)||Mh;return oe.get(Y)!==ne&&oe.set(Y,ne),ce}function xu(Y){k.blockers.delete(Y),oe.delete(Y)}function ha(Y,ne){let ce=k.blockers.get(Y)||Mh;Ct(ce.state==="unblocked"&&ne.state==="blocked"||ce.state==="blocked"&&ne.state==="blocked"||ce.state==="blocked"&&ne.state==="proceeding"||ce.state==="blocked"&&ne.state==="unblocked"||ce.state==="proceeding"&&ne.state==="unblocked",`Invalid blocker state transition: ${ce.state} -> ${ne.state}`);let me=new Map(k.blockers);me.set(Y,ne),Ue({blockers:me})}function fo({currentLocation:Y,nextLocation:ne,historyAction:ce}){if(oe.size===0)return;oe.size>1&&Dn(!1,"A router only supports one blocker at a time");let me=Array.from(oe.entries()),[we,We]=me[me.length-1],De=k.blockers.get(we);if(!(De&&De.state==="proceeding")&&We({currentLocation:Y,nextLocation:ne,historyAction:ce}))return we}function Ls(Y){let ne=Gi(404,{pathname:Y}),ce=c||a,{matches:me,route:we}=Gy(ce);return{notFoundMatches:me,route:we,error:ne}}function hg(Y,ne,ce){if(w=Y,b=ne,_=ce||null,!C&&k.navigation===_S){C=!0;let me=Uf(k.location,k.matches);me!=null&&Ue({restoreScrollPosition:me})}return()=>{w=null,b=null,_=null}}function Ff(Y,ne){return _&&_(Y,ne.map(me=>Ude(me,k.loaderData)))||Y.key}function pg(Y,ne){if(w&&b){let ce=Ff(Y,ne);w[ce]=b()}}function Uf(Y,ne){if(w){let ce=Ff(Y,ne),me=w[ce];if(typeof me=="number")return me}return null}function Hl(Y,ne,ce){if(e.patchRoutesOnNavigation)if(Y){if(Object.keys(Y[0].params).length>0)return{active:!0,matches:ep(ne,ce,d,!0)}}else return{active:!0,matches:ep(ne,ce,d,!0)||[]};return{active:!1,matches:null}}async function pa(Y,ne,ce,me){if(!e.patchRoutesOnNavigation)return{type:"success",matches:Y};let we=Y;for(;;){let We=c==null,De=c||a,Be=o;try{await e.patchRoutesOnNavigation({signal:ce,path:ne,matches:we,fetcherKey:me,patch:(st,Ye)=>{ce.aborted||V5(st,Ye,De,Be,s,!1)}})}catch(st){return{type:"error",error:st,partialMatches:we}}finally{We&&!ce.aborted&&(a=[...a])}if(ce.aborted)return{type:"aborted"};let Ge=sl(De,ne,d),He=null;if(Ge){if(Object.keys(Ge[0].params).length===0)return{type:"success",matches:Ge};
212if(He=ep(De,ne,d,!0),!(He&&we.length<He.length&&zf(we,He.slice(0,we.length))))return{type:"success",matches:Ge}}if(He||(He=ep(De,ne,d,!0)),!He||zf(we,He))return{type:"success",matches:null};we=He}}function zf(Y,ne){return Y.length===ne.length&&Y.every((ce,me)=>ce.route.id===ne[me].route.id)}function Vl(Y){o={},c=Yp(Y,s,void 0,o)}function Bf(Y,ne,ce=!1){let me=c==null;V5(Y,ne,c||a,o,s,ce),me&&(a=[...a],Ue({}))}return I={get basename(){return d},get future(){return p},get state(){return k},get routes(){return a},get window(){return t},initialize:xe,subscribe:rt,enableScrollRestoration:hg,navigate:Qe,fetch:jt,revalidate:ht,createHref:Y=>e.history.createHref(Y),encodeLocation:Y=>e.history.encodeLocation(Y),getFetcher:fa,resetFetcher:Bl,deleteFetcher:dg,dispose:be,getBlocker:jf,deleteBlocker:xu,patchRoutes:Bf,_internalFetchControllers:N,_internalSetRoutes:Vl,_internalSetStateDoNotUseOrYouWillBreakYourApp(Y){Ue(Y)}},e.unstable_instrumentations&&(I=sfe(I,e.unstable_instrumentations.map(Y=>Y.router).filter(Boolean))),I}function yfe(e){return e!=null&&("formData"in e&&e.formData!=null||"body"in e&&e.body!==void 0)}function u2(e,t,n,r,i,s){let o,a;if(i){o=[];for(let d of t)if(o.push(d),d.route.id===i){a=d;break}}else o=t,a=t[t.length-1];let c=t1(r||".",e1(o),is(e.pathname,n)||e.pathname,s==="path");if(r==null&&(c.search=e.search,c.hash=e.hash),(r==null||r===""||r===".")&&a){let d=yT(c.search);if(a.route.index&&!d)c.search=c.search?c.search.replace(/^\?/,"?index&"):"?index";else if(!a.route.index&&d){let f=new URLSearchParams(c.search),p=f.getAll("index");f.delete("index"),p.filter(v=>v).forEach(v=>f.append("index",v));let m=f.toString();c.search=m?`?${m}`:""}}return n!=="/"&&(c.pathname=Qde({basename:n,pathname:c.pathname})),oo(c)}function B5(e,t,n){if(!n||!yfe(n))return{path:t};if(n.formMethod&&!Nfe(n.formMethod))return{path:t,error:Gi(405,{method:n.formMethod})};let r=()=>({path:t,error:Gi(400,{type:"invalid-body"})}),s=(n.formMethod||"get").toUpperCase(),o=sj(t);if(n.body!==void 0){if(n.formEncType==="text/plain"){if(!Ir(s))return r();let p=typeof n.body=="string"?n.body:n.body instanceof FormData||n.body instanceof URLSearchParams?Array.from(n.body.entries()).reduce((m,[v,w])=>`${m}${v}=${w} 213`,""):String(n.body);return{path:t,submission:{formMethod:s,formAction:o,formEncType:n.formEncType,formData:void 0,json:void 0,text:p}}}else if(n.formEncType==="application/json"){if(!Ir(s))return r();try{let p=typeof n.body=="string"?JSON.parse(n.body):n.body;return{path:t,submission:{formMethod:s,formAction:o,formEncType:n.formEncType,formData:void 0,json:p,text:void 0}}}catch{return r()}}}Ct(typeof FormData=="function","FormData is not available in this environment");let a,c;if(n.formData)a=h2(n.formData),c=n.formData;else if(n.body instanceof FormData)a=h2(n.body),c=n.body;else if(n.body instanceof URLSearchParams)a=n.body,c=Y5(a);else if(n.body==null)a=new URLSearchParams,c=new FormData;else try{a=new URLSearchParams(n.body),c=Y5(a)}catch{return r()}let d={formMethod:s,formAction:o,formEncType:n&&n.formEncType||"application/x-www-form-urlencoded",formData:c,json:void 0,text:void 0};if(Ir(d.formMethod))return{path:t,submission:d};let f=$l(t);return e&&f.search&&yT(f.search)&&a.append("index",""),f.search=`?${a}`,{path:oo(f),submission:d}}function H5(e,t,n,r,i,s,o,a,c,d,f,p,m,v,w,_,b,C,P,D,F){let R=D?Si(D[1])?D[1].error:D[1].data:void 0,I=i.createURL(s.location),k=i.createURL(c),L;if(f&&s.errors){let q=Object.keys(s.errors)[0];L=o.findIndex(z=>z.route.id===q)}else if(D&&Si(D[1])){let q=D[0];L=o.findIndex(z=>z.route.id===q)-1}let B=D?D[1].statusCode:void 0,A=B&&B>=400,V={currentUrl:I,currentParams:s.matches[0]?.params||{},nextUrl:k,nextParams:o[0].params,...a,actionResult:R,actionStatus:B},K=Hm(o),W=o.map((q,z)=>{let{route:x}=q,N=null;if(L!=null&&z>L?N=!1:x.lazy?N=!0:mT(x)?f?N=d2(x,s.loaderData,s.errors):vfe(s.loaderData,s.matches[z],q)&&(N=!0):N=!1,N!==null)return f2(n,r,e,K,q,d,t,N);let M=!1;typeof F=="boolean"?M=F:A?M=!1:(p||I.pathname+I.search===k.pathname+k.search||I.search!==k.search||_fe(s.matches[z],q))&&(M=!0);let E={...V,defaultShouldRevalidate:M},O=bp(q,E);return f2(n,r,e,K,q,d,t,O,E,F)}),U=[];
213return w.forEach((q,z)=>{if(f||!o.some(X=>X.route.id===q.routeId)||v.has(z))return;let x=s.fetchers.get(z),N=x&&x.state!=="idle"&&x.data===void 0,M=sl(b,q.path,C);if(!M){if(P&&N)return;U.push({key:z,routeId:q.routeId,path:q.path,matches:null,match:null,request:null,controller:null});return}if(_.has(z))return;let E=Iv(M,q.path),O=new AbortController,H=ud(i,q.path,O.signal),Z=null;if(m.has(z))m.delete(z),Z=$d(n,r,H,M,E,d,t);else if(N)p&&(Z=$d(n,r,H,M,E,d,t));else{let X;typeof F=="boolean"?X=F:A?X=!1:X=p;let te={...V,defaultShouldRevalidate:X};bp(E,te)&&(Z=$d(n,r,H,M,E,d,t,te))}Z&&U.push({key:z,routeId:q.routeId,path:q.path,matches:Z,match:E,request:H,controller:O})}),{dsMatches:W,revalidatingFetchers:U}}function mT(e){return e.loader!=null||e.middleware!=null&&e.middleware.length>0}function d2(e,t,n){if(e.lazy)return!0;if(!mT(e))return!1;let r=t!=null&&e.id in t,i=n!=null&&n[e.id]!==void 0;return!r&&i?!1:typeof e.loader=="function"&&e.loader.hydrate===!0?!0:!r&&!i}function vfe(e,t,n){let r=!t||n.route.id!==t.route.id,i=!e.hasOwnProperty(n.route.id);return r||i}function _fe(e,t){let n=e.route.path;return e.pathname!==t.pathname||n!=null&&n.endsWith("*")&&e.params["*"]!==t.params["*"]}function bp(e,t){if(e.route.shouldRevalidate){let n=e.route.shouldRevalidate(t);if(typeof n=="boolean")return n}return t.defaultShouldRevalidate}function V5(e,t,n,r,i,s){let o;if(e){let d=r[e];Ct(d,`No route found to patch children into: routeId = ${e}`),d.children||(d.children=[]),o=d.children}else o=n;let a=[],c=[];if(t.forEach(d=>{let f=o.find(p=>ej(d,p));f?c.push({existingRoute:f,newRoute:d}):a.push(d)}),a.length>0){let d=Yp(a,i,[e||"_","patch",String(o?.length||"0")],r);o.push(...d)}if(s&&c.length>0)for(let d=0;d<c.length;d++){let{existingRoute:f,newRoute:p}=c[d],m=f,[v]=Yp([p],i,[],{},!0);Object.assign(m,{element:v.element?v.element:m.element,errorElement:v.errorElement?v.errorElement:m.errorElement,hydrateFallbackElement:v.hydrateFallbackElement?v.hydrateFallbackElement:m.hydrateFallbackElement})}}function ej(e,t){return"id"in e&&"id"in t&&e.id===t.id?!0:e.index===t.index&&e.path===t.path&&e.caseSensitive===t.caseSensitive?(!e.children||e.children.length===0)&&(!t.children||t.children.length===0)?!0:e.children.every((n,r)=>t.children?.some(i=>ej(n,i))):!1}var W5=new WeakMap,tj=({key:e,route:t,manifest:n,mapRouteProperties:r})=>{let i=n[t.id];if(Ct(i,"No route found in manifest"),!i.lazy||typeof i.lazy!="object")return;let s=i.lazy[e];if(!s)return;let o=W5.get(i);o||(o={},W5.set(i,o));let a=o[e];if(a)return a;let c=(async()=>{let d=Nde(e),p=i[e]!==void 0&&e!=="hasErrorBoundary";if(d)Dn(!d,"Route property "+e+" is not a supported lazy route property. This property will be ignored."),o[e]=Promise.resolve();else if(p)Dn(!1,`Route "${i.id}" has a static property "${e}" defined. The lazy property will be ignored.`);else{let m=await s();m!=null&&(Object.assign(i,{[e]:m}),Object.assign(i,r(i)))}typeof i.lazy=="object"&&(i.lazy[e]=void 0,Object.values(i.lazy).every(m=>m===void 0)&&(i.lazy=void 0))})();return o[e]=c,c},q5=new WeakMap;function wfe(e,t,n,r,i){let s=n[e.id];if(Ct(s,"No route found in manifest"),!e.lazy)return{lazyRoutePromise:void 0,lazyHandlerPromise:void 0};if(typeof e.lazy=="function"){let f=q5.get(s);if(f)return{lazyRoutePromise:f,lazyHandlerPromise:f};let p=(async()=>{Ct(typeof e.lazy=="function","No lazy route function found");let m=await e.lazy(),v={};for(let w in m){let _=m[w];if(_===void 0)continue;let b=jde(w),P=s[w]!==void 0&&w!=="hasErrorBoundary";b?Dn(!b,"Route property "+w+" is not a supported property to be returned from a lazy route function. This property will be ignored."):P?Dn(!P,`Route "${s.id}" has a static property "${w}" defined but its lazy function is also returning a value for this property. The lazy route property "${w}" will be ignored.`):v[w]=_}Object.assign(s,v),Object.assign(s,{...r(s),lazy:void 0})})();return q5.set(s,p),p.catch(()=>{}),{lazyRoutePromise:p,lazyHandlerPromise:p}}let o=Object.keys(e.lazy),a=[],c;for(let f of o){if(i&&i.includes(f))continue;let p=tj({key:f,route:e,manifest:n,mapRouteProperties:r});p&&(a.push(p),f===t&&(c=p))}let d=a.length>0?Promise.all(a).then(()=>{}):void 0;return d?.catch(()=>{}),c?.catch(()=>{}),{lazyRoutePromise:d,lazyHandlerPromise:c}}async function K5(e){let t=e.matches.filter(i=>i.shouldLoad),n={};return(await Promise.all(t.map(i=>
213i.resolve()))).forEach((i,s)=>{n[t[s].route.id]=i}),n}async function bfe(e){return e.matches.some(t=>t.route.middleware)?nj(e,()=>K5(e)):K5(e)}function nj(e,t){return Sfe(e,t,r=>{if(Lfe(r))throw r;return r},Afe,n);function n(r,i,s){if(s)return Promise.resolve(Object.assign(s.value,{[i]:{type:"error",result:r}}));{let{matches:o}=e,a=Math.min(Math.max(o.findIndex(d=>d.route.id===i),0),Math.max(o.findIndex(d=>d.shouldCallHandler()),0)),c=ol(o,o[a].route.id).route.id;return Promise.resolve({[c]:{type:"error",result:r}})}}}async function Sfe(e,t,n,r,i){let{matches:s,request:o,params:a,context:c,unstable_pattern:d}=e,f=s.flatMap(m=>m.route.middleware?m.route.middleware.map(v=>[m.route.id,v]):[]);return await rj({request:o,params:a,context:c,unstable_pattern:d},f,t,n,r,i)}async function rj(e,t,n,r,i,s,o=0){let{request:a}=e;if(a.signal.aborted)throw a.signal.reason??new Error(`Request aborted: ${a.method} ${a.url}`);let c=t[o];if(!c)return await n();let[d,f]=c,p,m=async()=>{if(p)throw new Error("You may only call `next()` once per middleware");try{return p={value:await rj(e,t,n,r,i,s,o+1)},p.value}catch(v){return p={value:await s(v,d,p)},p.value}};try{let v=await f(e,m),w=v!=null?r(v):void 0;return i(w)?w:p?w??p.value:(p={value:await m()},p.value)}catch(v){return await s(v,d,p)}}function ij(e,t,n,r,i){let s=tj({key:"middleware",route:r.route,manifest:t,mapRouteProperties:e}),o=wfe(r.route,Ir(n.method)?"action":"loader",t,e,i);return{middleware:s,route:o.lazyRoutePromise,handler:o.lazyHandlerPromise}}function f2(e,t,n,r,i,s,o,a,c=null,d){let f=!1,p=ij(e,t,n,i,s);return{...i,_lazyPromises:p,shouldLoad:a,shouldRevalidateArgs:c,shouldCallHandler(m){return f=!0,c?typeof d=="boolean"?bp(i,{...c,defaultShouldRevalidate:d}):typeof m=="boolean"?bp(i,{...c,defaultShouldRevalidate:m}):bp(i,c):a},resolve(m){let{lazy:v,loader:w,middleware:_}=i.route,b=f||a||m&&!Ir(n.method)&&(v||w),C=_&&_.length>0&&!w&&!v;return b&&(Ir(n.method)||!C)?xfe({request:n,unstable_pattern:r,match:i,lazyHandlerPromise:p?.handler,lazyRoutePromise:p?.route,handlerOverride:m,scopedContext:o}):Promise.resolve({type:"data",result:void 0})}}}function $d(e,t,n,r,i,s,o,a=null){return r.map(c=>c.route.id!==i.route.id?{...c,shouldLoad:!1,shouldRevalidateArgs:a,shouldCallHandler:()=>!1,_lazyPromises:ij(e,t,n,c,s),resolve:()=>Promise.resolve({type:"data",result:void 0})}:f2(e,t,n,Hm(r),c,s,o,!0,a))}async function Efe(e,t,n,r,i,s){n.some(d=>d._lazyPromises?.middleware)&&await Promise.all(n.map(d=>d._lazyPromises?.middleware));let o={request:t,unstable_pattern:Hm(n),params:n[0].params,context:i,matches:n},c=await e({...o,fetcherKey:r,runClientMiddleware:d=>{let f=o;return nj(f,()=>d({...f,fetcherKey:r,runClientMiddleware:()=>{throw new Error("Cannot call `runClientMiddleware()` from within an `runClientMiddleware` handler")}}))}});try{await Promise.all(n.flatMap(d=>[d._lazyPromises?.handler,d._lazyPromises?.route]))}catch{}return c}async function xfe({request:e,unstable_pattern:t,match:n,lazyHandlerPromise:r,lazyRoutePromise:i,handlerOverride:s,scopedContext:o}){let a,c,d=Ir(e.method),f=d?"action":"loader",p=m=>{let v,w=new Promise((C,P)=>v=P);c=()=>v(),e.signal.addEventListener("abort",c);let _=C=>typeof m!="function"?Promise.reject(new Error(`You cannot call the handler for a route which defines a boolean "${f}" [routeId: ${n.route.id}]`)):m({request:e,unstable_pattern:t,params:n.params,context:o},...C!==void 0?[C]:[]),b=(async()=>{try{return{type:"data",result:await(s?s(P=>_(P)):_())}}catch(C){return{type:"error",result:C}}})();return Promise.race([b,w])};try{let m=d?n.route.action:n.route.loader;if(r||i)if(m){let v,[w]=await Promise.all([p(m).catch(_=>{v=_}),r,i]);if(v!==void 0)throw v;a=w}else{await r;let v=d?n.route.action:n.route.loader;if(v)[a]=await Promise.all([p(v),i]);else if(f==="action"){let w=new URL(e.url),_=w.pathname+w.search;throw Gi(405,{method:e.method,pathname:_,routeId:n.route.id})}else return{type:"data",result:void 0}}else if(m)a=await p(m);else{let v=new URL(e.url),w=v.pathname+v.search;throw Gi(404,{pathname:w})}}catch(m){return{type:"error",result:m}}finally{c&&e.signal.removeEventListener("abort",c)}return a}
213async function Cfe(e){let t=e.headers.get("Content-Type");return t&&/\bapplication\/json\b/.test(t)?e.body==null?null:e.json():e.text()}async function kfe(e){let{result:t,type:n}=e;if(gT(t)){let r;try{r=await Cfe(t)}catch(i){return{type:"error",error:i}}return n==="error"?{type:"error",error:new Bm(t.status,t.statusText,r),statusCode:t.status,headers:t.headers}:{type:"data",data:r,statusCode:t.status,headers:t.headers}}return n==="error"?Q5(t)?t.data instanceof Error?{type:"error",error:t.data,statusCode:t.init?.status,headers:t.init?.headers?new Headers(t.init.headers):void 0}:{type:"error",error:Ofe(t),statusCode:tf(t)?t.status:void 0,headers:t.init?.headers?new Headers(t.init.headers):void 0}:{type:"error",error:t,statusCode:tf(t)?t.status:void 0}:Q5(t)?{type:"data",data:t.data,statusCode:t.init?.status,headers:t.init?.headers?new Headers(t.init.headers):void 0}:{type:"data",data:t}}function Tfe(e,t,n,r,i){let s=e.headers.get("Location");if(Ct(s,"Redirects returned/thrown from loaders/actions must have a Location header"),!pT(s)){let o=r.slice(0,r.findIndex(a=>a.route.id===n)+1);s=u2(new URL(t.url),o,i,s),e.headers.set("Location",s)}return e}function G5(e,t,n,r){let i=["about:","blob:","chrome:","chrome-untrusted:","content:","data:","devtools:","file:","filesystem:","javascript:"];if(pT(e)){let s=e,o=s.startsWith("//")?new URL(t.protocol+s):new URL(s);if(i.includes(o.protocol))throw new Error("Invalid redirect location");let a=is(o.pathname,n)!=null;if(o.origin===t.origin&&a)return o.pathname+o.search+o.hash}try{let s=r.createURL(e);if(i.includes(s.protocol))throw new Error("Invalid redirect location")}catch{}return e}function ud(e,t,n,r){let i=e.createURL(sj(t)).toString(),s={signal:n};if(r&&Ir(r.formMethod)){let{formMethod:o,formEncType:a}=r;s.method=o.toUpperCase(),a==="application/json"?(s.headers=new Headers({"Content-Type":a}),s.body=JSON.stringify(r.json)):a==="text/plain"?s.body=r.text:a==="application/x-www-form-urlencoded"&&r.formData?s.body=h2(r.formData):s.body=r.formData}return new Request(i,s)}function h2(e){let t=new URLSearchParams;for(let[n,r]of e.entries())t.append(n,typeof r=="string"?r:r.name);return t}function Y5(e){let t=new FormData;for(let[n,r]of e.entries())t.append(n,r);return t}function Rfe(e,t,n,r=!1,i=!1){let s={},o=null,a,c=!1,d={},f=n&&Si(n[1])?n[1].error:void 0;return e.forEach(p=>{if(!(p.route.id in t))return;let m=p.route.id,v=t[m];if(Ct(!Ac(v),"Cannot handle redirect results in processLoaderData"),Si(v)){let w=v.error;if(f!==void 0&&(w=f,f=void 0),o=o||{},i)o[m]=w;else{let _=ol(e,m);o[_.route.id]==null&&(o[_.route.id]=w)}r||(s[m]=Q$),c||(c=!0,a=tf(v.error)?v.error.status:500),v.headers&&(d[m]=v.headers)}else s[m]=v.data,v.statusCode&&v.statusCode!==200&&!c&&(a=v.statusCode),v.headers&&(d[m]=v.headers)}),f!==void 0&&n&&(o={[n[0]]:f},n[2]&&(s[n[2]]=void 0)),{loaderData:s,errors:o,statusCode:a||200,loaderHeaders:d}}function J5(e,t,n,r,i,s){let{loaderData:o,errors:a}=Rfe(t,n,r);return i.filter(c=>!c.matches||c.matches.some(d=>d.shouldLoad)).forEach(c=>{let{key:d,match:f,controller:p}=c;if(p&&p.signal.aborted)return;let m=s[d];if(Ct(m,"Did not find corresponding fetcher result"),Si(m)){let v=ol(e.matches,f?.route.id);a&&a[v.route.id]||(a={...a,[v.route.id]:m.error}),e.fetchers.delete(d)}else if(Ac(m))Ct(!1,"Unhandled fetcher revalidation redirect");else{let v=Oo(m.data);e.fetchers.set(d,v)}}),{loaderData:o,errors:a}}function Z5(e,t,n,r){let i=Object.entries(t).filter(([,s])=>s!==Q$).reduce((s,[o,a])=>(s[o]=a,s),{});for(let s of n){let o=s.route.id;if(!t.hasOwnProperty(o)&&e.hasOwnProperty(o)&&s.route.loader&&(i[o]=e[o]),r&&r.hasOwnProperty(o))break}return i}function X5(e){return e?Si(e[1])?{actionData:{}}:{actionData:{[e[0]]:e[1].data}}:{}}function ol(e,t){return(t?e.slice(0,e.findIndex(r=>r.route.id===t)+1):[...e]).reverse().find(r=>r.route.hasErrorBoundary===!0)||e[0]}function Gy(e){let t=e.length===1?e[0]:e.find(n=>n.index||!n.path||n.path==="/")||{id:"__shim-error-route__"};return{matches:[{params:{},pathname:"",pathnameBase:"",route:t}],route:t}}function Gi(e,{pathname:t,routeId:n,method:r,type:i,message:s}={}){let o="Unknown Server Error",a="Unknown @remix-run/router error";return e===400?(o="Bad Request",r&&t&&n?a=`You made a ${r} request to "${t}" but did not provide a \`loader\` for route "${n}", so there is no way to handle the request.`:i==="invalid-body"&&(a="Unable to encode submission body")):e===403?(o="Forbidden",a=`Route "${n}" does not match URL "${t}"`):e===404?(o="Not Found",a=`No route matches URL "${t}"`):e===405&&(o="Method Not Allowed",r&&t&&n?a=`You made a ${r.toUpperCase()} request to "${t}" but did not provide an \`action\` for route "${n}", so there is no way to handle the request.`:r&&(a=`Invalid request method "${r.toUpperCase()}"`)),new Bm(e||500,o,new Error(a),!0)}function Yy(e){let t=Object.entries(e);for(let n=t.length-1;n>=0;n--){let[r,i]=t[n];if(Ac(i))return{key:r,result:i}}}function sj(e){let t=typeof e=="string"?$l(e):e;return oo({...t,hash:""})}function Pfe(e,t){return e.pathname!==t.pathname||e.search!==t.search?!1:e.hash===""?t.hash!=="":e.hash===t.hash?!0:t.hash!==""}function Ofe(e){return new Bm(e.init?.status??500,e.init?.statusText??"Internal Server Error",e.data)}function Afe(e){return e!=null&&typeof e=="object"&&Object.entries(e).every(([t,n])=>typeof t=="string"&&Ife(n))}function Ife(e){return e!=null&&typeof e=="object"&&"type"in e&&"result"in e&&(e.type==="data"||e.type==="error")}function Mfe(e){return gT(e.result)&&Z$.has(e.result.status)}function Si(e){return e.type==="error"}function Ac(e){return(e&&e.type)==="redirect"}function Q5(e){return typeof e=="object"&&e!=null&&"type"in e&&"data"in e&&"init"in e&&e.type==="DataWithResponseInit"}function gT(e){return e!=null&&typeof e.status=="number"&&typeof e.statusText=="string"&&typeof e.headers=="object"&&typeof e.body<"u"}function Dfe(e){return Z$.has(e)}function Lfe(e){return gT(e)&&Dfe(e.status)&&e.headers.has("Location")}function Nfe(e){return ffe.has(e.toUpperCase())}function Ir(e){return ufe.has(e.toUpperCase())}function yT(e){return new URLSearchParams(e).getAll("index").some(t=>t==="")}function Iv(e,t){let n=typeof t=="string"?$l(t).search:t.search;if(e[e.length-1].route.index&&yT(n||""))return e[e.length-1];let r=q$(e);return r[r.length-1]}function e4(e){let{formMethod:t,formAction:n,formEncType:r,text:i,formData:s,json:o}=e;if(!(!t||!n||!r)){if(i!=null)return{formMethod:t,formAction:n,formEncType:r,formData:void 0,json:void 0,text:i};if(s!=null)return{formMethod:t,formAction:n,formEncType:r,formData:s,json:void 0,text:void 0};if(o!==void 0)return{formMethod:t,formAction:n,formEncType:r,formData:void 0,json:o,text:void 0}}}function wS(e,t){return t?{state:"loading",location:e,formMethod:t.formMethod,formAction:t.formAction,formEncType:t.formEncType,formData:t.formData,json:t.json,text:t.text}:{state:"loading",location:e,formMethod:void 0,formAction:void 0,formEncType:void 0,formData:void 0,json:void 0,text:void 0}}function $fe(e,t){return{state:"submitting",location:e,formMethod:t.formMethod,formAction:t.formAction,formEncType:t.formEncType,formData:t.formData,json:t.json,text:t.text}}function Dh(e,t){return e?{state:"loading",formMethod:e.formMethod,formAction:e.formAction,formEncType:e.formEncType,formData:e.formData,json:e.json,text:e.text,data:t}:{state:"loading",formMethod:void 0,formAction:void 0,formEncType:void 0,formData:void 0,json:void 0,text:void 0,data:t}}function jfe(e,t){return{state:"submitting",formMethod:e.formMethod,formAction:e.formAction,formEncType:e.formEncType,formData:e.formData,json:e.json,text:e.text,data:t?t.data:void 0}}function Oo(e){return{state:"idle",formMethod:void 0,formAction:void 0,formEncType:void 0,formData:void 0,json:void 0,text:void 0,data:e}}function Ffe(e,t){try{let n=e.sessionStorage.getItem(X$);if(n){let r=JSON.parse(n);for(let[i,s]of Object.entries(r||{}))s&&Array.isArray(s)&&t.set(i,new Set(s||[]))}}catch{}}function Ufe(e,t){if(t.size>0){let n={};for(let[r,i]of t)n[r]=[...i];try{e.sessionStorage.setItem(X$,JSON.stringify(n))}catch(r){Dn(!1,`Failed to save applied view transitions in sessionStorage (${r}).`)}}}function t4(){let e,t,n=new Promise((r,i)=>{e=async s=>{r(s);try{await n}catch{}},t=async s=>{i(s);try{await n}catch{}}});return{promise:n,resolve:e,reject:t}}var vu=g.createContext(null);vu.displayName="DataRouter";var Vm=g.createContext(null);
213Vm.displayName="DataRouterState";var oj=g.createContext(!1);function zfe(){return g.useContext(oj)}var vT=g.createContext({isTransitioning:!1});vT.displayName="ViewTransition";var aj=g.createContext(new Map);aj.displayName="Fetchers";var Bfe=g.createContext(null);Bfe.displayName="Await";var Ii=g.createContext(null);Ii.displayName="Navigation";var n1=g.createContext(null);n1.displayName="Location";var ss=g.createContext({outlet:null,matches:[],isDataRoute:!1});ss.displayName="Route";var _T=g.createContext(null);_T.displayName="RouteError";var lj="REACT_ROUTER_ERROR",Hfe="REDIRECT",Vfe="ROUTE_ERROR_RESPONSE";function Wfe(e){if(e.startsWith(`${lj}:${Hfe}:{`))try{let t=JSON.parse(e.slice(28));if(typeof t=="object"&&t&&typeof t.status=="number"&&typeof t.statusText=="string"&&typeof t.location=="string"&&typeof t.reloadDocument=="boolean"&&typeof t.replace=="boolean")return t}catch{}}function qfe(e){if(e.startsWith(`${lj}:${Vfe}:{`))try{let t=JSON.parse(e.slice(40));if(typeof t=="object"&&t&&typeof t.status=="number"&&typeof t.statusText=="string")return new Bm(t.status,t.statusText,t.data)}catch{}}function Kfe(e,{relative:t}={}){Ct(Pf(),"useHref() may be used only in the context of a <Router> component.");let{basename:n,navigator:r}=g.useContext(Ii),{hash:i,pathname:s,search:o}=Wm(e,{relative:t}),a=s;return n!=="/"&&(a=s==="/"?n:Xs([n,s])),r.createHref({pathname:a,search:o,hash:i})}function Pf(){return g.useContext(n1)!=null}function Mi(){return Ct(Pf(),"useLocation() may be used only in the context of a <Router> component."),g.useContext(n1).location}var cj="You should call navigate() in a React.useEffect(), not when your component is first rendered.";function uj(e){g.useContext(Ii).static||g.useLayoutEffect(e)}function jl(){let{isDataRoute:e}=g.useContext(ss);return e?ahe():Gfe()}function Gfe(){Ct(Pf(),"useNavigate() may be used only in the context of a <Router> component.");
213let e=g.useContext(vu),{basename:t,navigator:n}=g.useContext(Ii),{matches:r}=g.useContext(ss),{pathname:i}=Mi(),s=JSON.stringify(e1(r)),o=g.useRef(!1);return uj(()=>{o.current=!0}),g.useCallback((c,d={})=>{if(Dn(o.current,cj),!o.current)return;if(typeof c=="number"){n.go(c);return}let f=t1(c,JSON.parse(s),i,d.relative==="path");e==null&&t!=="/"&&(f.pathname=f.pathname==="/"?t:Xs([t,f.pathname])),(d.replace?n.replace:n.push)(f,d.state,d)},[t,n,s,i,e])}var Yfe=g.createContext(null);function Jfe(e){let t=g.useContext(ss).outlet;return g.useMemo(()=>t&&g.createElement(Yfe.Provider,{value:e},t),[t,e])}function xOe(){let{matches:e}=g.useContext(ss),t=e[e.length-1];return t?t.params:{}}function Wm(e,{relative:t}={}){let{matches:n}=g.useContext(ss),{pathname:r}=Mi(),i=JSON.stringify(e1(n));return g.useMemo(()=>t1(e,JSON.parse(i),r,t==="path"),[e,i,r,t])}function Zfe(e,t,n,r,i){Ct(Pf(),"useRoutes() may be used only in the context of a <Router> component.");let{navigator:s}=g.useContext(Ii),{matches:o}=g.useContext(ss),a=o[o.length-1],c=a?a.params:{},d=a?a.pathname:"/",f=a?a.pathnameBase:"/",p=a&&a.route;{let P=p&&p.path||"";hj(d,!p||P.endsWith("*")||P.endsWith("*?"),`You rendered descendant <Routes> (or called \`useRoutes()\`) at "${d}" (under <Route path="${P}">) but the parent route path has no trailing "*". This means if you navigate deeper, the parent won't match anymore and therefore the child routes will never render. 214 215Please change the parent <Route path="${P}"> to <Route path="${P==="/"?"*":`${P}/*`}">.`)}let m=Mi(),v;v=m;let w=v.pathname||"/",_=w;if(f!=="/"){let P=f.replace(/^\//,"").split("/");_="/"+w.replace(/^\//,"").split("/").slice(P.length).join("/")}let b=sl(e,{pathname:_});return Dn(p||b!=null,`No routes matched location "${v.pathname}${v.search}${v.hash}" `),Dn(b==null||b[b.length-1].route.element!==void 0||b[b.length-1].route.Component!==void 0||b[b.length-1].route.lazy!==void 0,`Matched leaf route at location "${v.pathname}${v.search}${v.hash}" does not have an element or Component. This means it will render an <Outlet /> with a null value by default resulting in an "empty" page.`),nhe(b&&b.map(P=>Object.assign({},P,{params:Object.assign({},c,P.params),pathname:Xs([f,s.encodeLocation?s.encodeLocation(P.pathname.replace(/\?/g,"%3F").replace(/#/g,"%23")).pathname:P.pathname]),pathnameBase:P.pathnameBase==="/"?f:Xs([f,s.encodeLocation?s.encodeLocation(P.pathnameBase.replace(/\?/g,"%3F").replace(/#/g,"%23")).pathname:P.pathnameBase])})),o,n,r,i)}function Xfe(){let e=fj(),t=tf(e)?`${e.status} ${e.statusText}`:e instanceof Error?e.message:JSON.stringify(e),n=e instanceof Error?e.stack:null,r="rgba(200,200,200, 0.5)",i={padding:"0.5rem",backgroundColor:r},s={padding:"2px 4px",backgroundColor:r},o=null;return console.error("Error handled by React Router default ErrorBoundary:",e),o=g.createElement(g.Fragment,null,g.createElement("p",null,"💿 Hey developer 👋"),g.createElement("p",null,"You can provide a way better UX than this when your app throws errors by providing your own ",g.createElement("code",{style:s},"ErrorBoundary")," or"," ",g.createElement("code",{style:s},"errorElement")," prop on your route.")),g.createElement(g.Fragment,null,g.createElement("h2",null,"Unexpected Application Error!"),g.createElement("h3",{style:{fontStyle:"italic"}},t),n?g.createElement("pre",{style:i},n):null,o)}var Qfe=g.createElement(Xfe,null),dj=class extends g.Component{constructor(e){super(e),this.state={location:e.location,revalidation:e.revalidation,error:e.error}}static getDerivedStateFromError(e){return{error:e}}static getDerivedStateFromProps(e,t){return t.location!==e.location||t.revalidation!=="idle"&&e.revalidation==="idle"?{error:e.error,location:e.location,revalidation:e.revalidation}:{error:e.error!==void 0?e.error:t.error,location:t.location,revalidation:e.revalidation||t.revalidation}}componentDidCatch(e,t){this.props.onError?this.props.onError(e,t):console.error("React Router caught the following error during render",e)}render(){let e=this.state.error;if(this.context&&typeof e=="object"&&e&&"digest"in e&&typeof e.digest=="string"){const n=qfe(e.digest);n&&(e=n)}let t=e!==void 0?g.createElement(ss.Provider,{value:this.props.routeContext},g.createElement(_T.Provider,{value:e,children:this.props.component})):this.props.children;return this.context?g.createElement(ehe,{error:e},t):t}};dj.contextType=oj;var bS=new WeakMap;function ehe({children:e,error:t}){let{basename:n}=g.useContext(Ii);if(typeof t=="object"&&t&&"digest"in t&&typeof t.digest=="string"){let r=Wfe(t.digest);if(r){let i=bS.get(t);if(i)throw i;let s=G$(r.location,n);if(K$&&!bS.get(t))if(s.isExternal||r.reloadDocument)window.location.href=s.absoluteURL||s.to;else{const o=Promise.resolve().then(()=>window.__reactRouterDataRouter.navigate(s.to,{replace:r.replace}));throw bS.set(t,o),o}return g.createElement("meta",{httpEquiv:"refresh",content:`0;url=${s.absoluteURL||s.to}`})}}return e}function the({routeContext:e,match:t,children:n}){let r=g.useContext(vu);return r&&r.static&&r.staticContext&&(t.route.errorElement||t.route.ErrorBoundary)&&(r.staticContext._deepestRenderedBoundaryId=t.route.id),g.createElement(ss.Provider,{value:e},n)}function nhe(e,t=[],n=null,r=null,i=null){if(e==null){if(!n)return null;if(n.errors)e=n.matches;else if(t.length===0&&!n.initialized&&n.matches.length>0)e=n.matches;else return null}let s=e,o=n?.errors;if(o!=null){let f=s.findIndex(p=>p.route.id&&o?.[p.route.id]!==void 0);Ct(f>=0,`Could not find a matching route for errors on route IDs: ${Object.keys(o).join(",")}`),s=s.slice(0,Math.min(s.length,f+1))}let a=!1,c=-1;if(n)for(let f=0;f<s.length;f++){let p=s[f];if((p.route.HydrateFallback||p.route.hydrateFallbackElement)&&(c=f),p.route.id){let{loaderData:m,errors:v}
215=n,w=p.route.loader&&!m.hasOwnProperty(p.route.id)&&(!v||v[p.route.id]===void 0);if(p.route.lazy||w){a=!0,c>=0?s=s.slice(0,c+1):s=[s[0]];break}}}let d=n&&r?(f,p)=>{r(f,{location:n.location,params:n.matches?.[0]?.params??{},unstable_pattern:Hm(n.matches),errorInfo:p})}:void 0;return s.reduceRight((f,p,m)=>{let v,w=!1,_=null,b=null;n&&(v=o&&p.route.id?o[p.route.id]:void 0,_=p.route.errorElement||Qfe,a&&(c<0&&m===0?(hj("route-fallback",!1,"No `HydrateFallback` element provided to render during initial hydration"),w=!0,b=null):c===m&&(w=!0,b=p.route.hydrateFallbackElement||null)));let C=t.concat(s.slice(0,m+1)),P=()=>{let D;return v?D=_:w?D=b:p.route.Component?D=g.createElement(p.route.Component,null):p.route.element?D=p.route.element:D=f,g.createElement(the,{match:p,routeContext:{outlet:f,matches:C,isDataRoute:n!=null},children:D})};return n&&(p.route.ErrorBoundary||p.route.errorElement||m===0)?g.createElement(dj,{location:n.location,revalidation:n.revalidation,component:_,error:v,children:P(),routeContext:{outlet:null,matches:C,isDataRoute:!0},onError:d}):P()},null)}function wT(e){return`${e} must be used within a data router. See https://reactrouter.com/en/main/routers/picking-a-router.`}function rhe(e){let t=g.useContext(vu);return Ct(t,wT(e)),t}function ihe(e){let t=g.useContext(Vm);return Ct(t,wT(e)),t}function she(e){let t=g.useContext(ss);return Ct(t,wT(e)),t}function bT(e){let t=she(e),n=t.matches[t.matches.length-1];return Ct(n.route.id,`${e} can only be used on routes that contain a unique "id"`),n.route.id}function ohe(){return bT("useRouteId")}function fj(){let e=g.useContext(_T),t=ihe("useRouteError"),n=bT("useRouteError");return e!==void 0?e:t.errors?.[n]}function ahe(){let{router:e}=rhe("useNavigate"),t=bT("useNavigate"),n=g.useRef(!1);return uj(()=>{n.current=!0}),g.useCallback(async(i,s={})=>{Dn(n.current,cj),n.current&&(typeof i=="number"?await e.navigate(i):await e.navigate(i,{fromRouteId:t,...s}))},[e,t])}var n4={};function hj(e,t,n){!t&&!n4[e]&&(n4[e]=!0,Dn(!1,n))}var r4={};function i4(e,t){!e&&!r4[t]&&(r4[t]=!0,console.warn(t))}var lhe="useOptimistic",s4=w_[lhe],che=()=>{};function uhe(e){return s4?s4(e):[e,che]}function dhe(e){let t={hasErrorBoundary:e.hasErrorBoundary||e.ErrorBoundary!=null||e.errorElement!=null};return e.Component&&(e.element&&Dn(!1,"You should not include both `Component` and `element` on your route - `Component` will be used."),Object.assign(t,{element:g.createElement(e.Component),Component:void 0})),e.HydrateFallback&&(e.hydrateFallbackElement&&Dn(!1,"You should not include both `HydrateFallback` and `hydrateFallbackElement` on your route - `HydrateFallback` will be used."),Object.assign(t,{hydrateFallbackElement:g.createElement(e.HydrateFallback),HydrateFallback:void 0})),e.ErrorBoundary&&(e.errorElement&&Dn(!1,"You should not include both `ErrorBoundary` and `errorElement` on your route - `ErrorBoundary` will be used."),Object.assign(t,{errorElement:g.createElement(e.ErrorBoundary),ErrorBoundary:void 0})),t}var fhe=["HydrateFallback","hydrateFallbackElement"],hhe=class{constructor(){this.status="pending",this.promise=new Promise((e,t)=>{this.resolve=n=>{this.status==="pending"&&(this.status="resolved",e(n))},this.reject=n=>{this.status==="pending"&&(this.status="rejected",t(n))}})}};function phe({router:e,flushSync:t,onError:n,unstable_useTransitions:r}){r=zfe()||r;let[s,o]=g.useState(e.state),[a,c]=uhe(s),[d,f]=g.useState(),[p,m]=g.useState({isTransitioning:!1}),[v,w]=g.useState(),[_,b]=g.useState(),[C,P]=g.useState(),D=g.useRef(new Map),F=g.useCallback((L,{deletedFetchers:B,newErrors:A,flushSync:V,viewTransitionOpts:K})=>{A&&n&&Object.values(A).forEach(U=>n(U,{location:L.location,params:L.matches[0]?.params??{},unstable_pattern:Hm(L.matches)})),L.fetchers.forEach((U,q)=>{U.data!==void 0&&D.current.set(q,U.data)}),B.forEach(U=>D.current.delete(U)),i4(V===!1||t!=null,'You provided the `flushSync` option to a router update, but you are not using the `<RouterProvider>` from `react-router/dom` so `ReactDOM.flushSync()` is unavailable. Please update your app to `import { RouterProvider } from "react-router/dom"` and ensure you have `react-dom` installed as a dependency to use the `flushSync` option.');let W=e.window!=null&&e.window.document!=null&&typeof e.window.document.startViewTransition=="function";if(i4(K==null||W,"You provided the `viewTransition` option to a router update, but you do not appear to be running in a DOM environment as `window.startViewTransition` is not available."),!K||!W){t&&V?t(()=>o(L)):r===!1?o(L):g.startTransition(()=>{r===!0&&c(U=>o4(U,L)),o(L)});return}if(t&&V){t(()=>{_&&(v?.resolve(),_.skipTransition()),m({isTransitioning:!0,flushSync:!0,currentLocation:K.currentLocation,nextLocation:K.nextLocation})});let U=e.window.document.startViewTransition(()=>{t(()=>
215o(L))});U.finished.finally(()=>{t(()=>{w(void 0),b(void 0),f(void 0),m({isTransitioning:!1})})}),t(()=>b(U));return}_?(v?.resolve(),_.skipTransition(),P({state:L,currentLocation:K.currentLocation,nextLocation:K.nextLocation})):(f(L),m({isTransitioning:!0,flushSync:!1,currentLocation:K.currentLocation,nextLocation:K.nextLocation}))},[e.window,t,_,v,r,c,n]);g.useLayoutEffect(()=>e.subscribe(F),[e,F]),g.useEffect(()=>{p.isTransitioning&&!p.flushSync&&w(new hhe)},[p]),g.useEffect(()=>{if(v&&d&&e.window){let L=d,B=v.promise,A=e.window.document.startViewTransition(async()=>{r===!1?o(L):g.startTransition(()=>{r===!0&&c(V=>o4(V,L)),o(L)}),await B});A.finished.finally(()=>{w(void 0),b(void 0),f(void 0),m({isTransitioning:!1})}),b(A)}},[d,v,e.window,r,c]),g.useEffect(()=>{v&&d&&a.location.key===d.location.key&&v.resolve()},[v,_,a.location,d]),g.useEffect(()=>{!p.isTransitioning&&C&&(f(C.state),m({isTransitioning:!0,flushSync:!1,currentLocation:C.currentLocation,nextLocation:C.nextLocation}),P(void 0))},[p.isTransitioning,C]);let R=g.useMemo(()=>({createHref:e.createHref,encodeLocation:e.encodeLocation,go:L=>e.navigate(L),push:(L,B,A)=>e.navigate(L,{state:B,preventScrollReset:A?.preventScrollReset}),replace:(L,B,A)=>e.navigate(L,{replace:!0,state:B,preventScrollReset:A?.preventScrollReset})}),[e]),I=e.basename||"/",k=g.useMemo(()=>({router:e,navigator:R,static:!1,basename:I,onError:n}),[e,R,I,n]);return g.createElement(g.Fragment,null,g.createElement(vu.Provider,{value:k},g.createElement(Vm.Provider,{value:a},g.createElement(aj.Provider,{value:D.current},g.createElement(vT.Provider,{value:p},g.createElement(yhe,{basename:I,location:a.location,navigationType:a.historyAction,navigator:R,unstable_useTransitions:r},g.createElement(mhe,{routes:e.routes,future:e.future,state:a,onError:n})))))),null)}function o4(e,t){return{...e,navigation:t.navigation.state!=="idle"?t.navigation:e.navigation,revalidation:t.revalidation!=="idle"?t.revalidation:e.revalidation,actionData:t.navigation.state!=="submitting"?t.actionData:e.actionData,fetchers:t.fetchers}}var mhe=g.memo(ghe);function ghe({routes:e,future:t,state:n,onError:r}){return Zfe(e,void 0,n,r,t)}function pj({to:e,replace:t,state:n,relative:r}){Ct(Pf(),"<Navigate> may be used only in the context of a <Router> component.");let{static:i}=g.useContext(Ii);Dn(!i,"<Navigate> must not be used on the initial render in a <StaticRouter>. This is a no-op, but you should modify your code so the <Navigate> is only ever rendered in response to some user interaction or state change.");let{matches:s}=g.useContext(ss),{pathname:o}=Mi(),a=jl(),c=t1(e,e1(s),o,r==="path"),d=JSON.stringify(c);return g.useEffect(()=>{a(JSON.parse(d),{replace:t,state:n,relative:r})},[a,d,r,t,n]),null}function qm(e){return Jfe(e.context)}function yhe({basename:e="/",children:t=null,location:n,navigationType:r="POP",navigator:i,static:s=!1,unstable_useTransitions:o}){Ct(!Pf(),"You cannot render a <Router> inside another <Router>. You should never have more than one in your app.");let a=e.replace(/^\/*/,"/"),c=g.useMemo(()=>({basename:a,navigator:i,static:s,unstable_useTransitions:o,future:{}}),[a,i,s,o]);typeof n=="string"&&(n=$l(n));let{pathname:d="/",search:f="",hash:p="",state:m=null,key:v="default"}=n,w=g.useMemo(()=>{let _=is(d,a);return _==null?null:{location:{pathname:_,search:f,hash:p,state:m,key:v},navigationType:r}},[a,d,f,p,m,v,r]);return Dn(w!=null,`<Router basename="${a}"> is not able to match the URL "${d}${f}${p}" because it does not start with the basename, so the <Router> won't render anything.`),w==null?null:g.createElement(Ii.Provider,{value:c},g.createElement(n1.Provider,{children:t,value:w}))}var Mv="get",Dv="application/x-www-form-urlencoded";function r1(e){return typeof HTMLElement<"u"&&e instanceof HTMLElement}function vhe(e){return r1(e)&&e.tagName.toLowerCase()==="button"}function _he(e){return r1(e)&&e.tagName.toLowerCase()==="form"}function whe(e){return r1(e)&&e.tagName.toLowerCase()==="input"}function bhe(e){return!!(e.metaKey||e.altKey||e.ctrlKey||e.shiftKey)}function She(e,t){return e.button===0&&(!t||t==="_self")&&!bhe(e)}function p2(e=""){return new URLSearchParams(typeof e=="string"||Array.isArray(e)||e instanceof URLSearchParams?e:Object.keys(e).reduce((t,n)=>{let r=e[n];return t.concat(Array.isArray(r)?r.map(i=>[n,i]):[[n,r]])},[]))}function Ehe(e,t){let n=p2(e);return t&&t.forEach((r,i)=>
215{n.has(i)||t.getAll(i).forEach(s=>{n.append(i,s)})}),n}var Jy=null;function xhe(){if(Jy===null)try{new FormData(document.createElement("form"),0),Jy=!1}catch{Jy=!0}return Jy}var Che=new Set(["application/x-www-form-urlencoded","multipart/form-data","text/plain"]);function SS(e){return e!=null&&!Che.has(e)?(Dn(!1,`"${e}" is not a valid \`encType\` for \`<Form>\`/\`<fetcher.Form>\` and will default to "${Dv}"`),null):e}function khe(e,t){let n,r,i,s,o;if(_he(e)){let a=e.getAttribute("action");r=a?is(a,t):null,n=e.getAttribute("method")||Mv,i=SS(e.getAttribute("enctype"))||Dv,s=new FormData(e)}else if(vhe(e)||whe(e)&&(e.type==="submit"||e.type==="image")){let a=e.form;if(a==null)throw new Error('Cannot submit a <button> or <input type="submit"> without a <form>');let c=e.getAttribute("formaction")||a.getAttribute("action");if(r=c?is(c,t):null,n=e.getAttribute("formmethod")||a.getAttribute("method")||Mv,i=SS(e.getAttribute("formenctype"))||SS(a.getAttribute("enctype"))||Dv,s=new FormData(a,e),!xhe()){let{name:d,type:f,value:p}=e;if(f==="image"){let m=d?`${d}.`:"";s.append(`${m}x`,"0"),s.append(`${m}y`,"0")}else d&&s.append(d,p)}}else{if(r1(e))throw new Error('Cannot submit element that is not <form>, <button>, or <input type="submit|image">');n=Mv,r=null,i=Dv,o=e}return s&&i==="text/plain"&&(o=s,s=void 0),{action:r,method:n.toLowerCase(),encType:i,formData:s,body:o}}Object.getOwnPropertyNames(Object.prototype).sort().join("\0");function ST(e,t){if(e===!1||e===null||typeof e>"u")throw new Error(t)}function The(e,t,n,r){let i=typeof e=="string"?new URL(e,typeof window>"u"?"server://singlefetch/":window.location.origin):e;return n?i.pathname.endsWith("/")?i.pathname=`${i.pathname}_.${r}`:i.pathname=`${i.pathname}.${r}`:i.pathname==="/"?i.pathname=`_root.${r}`:t&&is(i.pathname,t)==="/"?i.pathname=`${t.replace(/\/$/,"")}/_root.${r}`:i.pathname=`${i.pathname.replace(/\/$/,"")}.${r}`,i}async function Rhe(e,t){if(e.id in t)return t[e.id];try{let n=await import(e.module);return t[e.id]=n,n}catch(n){return console.error(`Error loading route module \`${e.module}\`, reloading page...`),console.error(n),window.__reactRouterContext&&window.__reactRouterContext.isSpaMode,window.location.reload(),new Promise(()=>{})}}function Phe(e){return e==null?!1:e.href==null?e.rel==="preload"&&typeof e.imageSrcSet=="string"&&typeof e.imageSizes=="string":typeof e.rel=="string"&&typeof e.href=="string"}async function Ohe(e,t,n){let r=await Promise.all(e.map(async i=>{let s=t.routes[i.route.id];if(s){let o=await Rhe(s,n);return o.links?o.links():[]}return[]}));return Dhe(r.flat(1).filter(Phe).filter(i=>i.rel==="stylesheet"||i.rel==="preload").map(i=>i.rel==="stylesheet"?{...i,rel:"prefetch",as:"style"}:{...i,rel:"prefetch"}))}function a4(e,t,n,r,i,s){let o=(c,d)=>n[d]?c.route.id!==n[d].route.id:!0,a=(c,d)=>n[d].pathname!==c.pathname||n[d].route.path?.endsWith("*")&&n[d].params["*"]!==c.params["*"];return s==="assets"?t.filter((c,d)=>o(c,d)||a(c,d)):s==="data"?t.filter((c,d)=>{let f=r.routes[c.route.id];if(!f||!f.hasLoader)return!1;if(o(c,d)||a(c,d))return!0;if(c.route.shouldRevalidate){let p=c.route.shouldRevalidate({currentUrl:new URL(i.pathname+i.search+i.hash,window.origin),currentParams:n[0]?.params||{},nextUrl:new URL(e,window.origin),nextParams:c.params,defaultShouldRevalidate:!0});if(typeof p=="boolean")return p}return!0}):[]}function Ahe(e,t,{includeHydrateFallback:n}={}){return Ihe(e.map(r=>{let i=t.routes[r.route.id];if(!i)return[];let s=[i.module];return i.clientActionModule&&(s=s.concat(i.clientActionModule)),i.clientLoaderModule&&(s=s.concat(i.clientLoaderModule)),n&&i.hydrateFallbackModule&&(s=s.concat(i.hydrateFallbackModule)),i.imports&&(s=s.concat(i.imports)),s}).flat(1))}function Ihe(e){return[...new Set(e)]}function Mhe(e){let t={},n=Object.keys(e).sort();for(let r of n)t[r]=e[r];return t}function Dhe(e,t){let n=new Set;return new Set(t),e.reduce((r,i)=>{let s=JSON.stringify(Mhe(i));return n.has(s)||(n.add(s),r.push({key:s,link:i})),r},[])}function mj(){let e=g.useContext(vu);return ST(e,"You must render this element inside a <DataRouterContext.Provider> element"),e}function Lhe(){let e=g.useContext(Vm);return ST(e,"You must render this element inside a <DataRouterStateContext.Provider> element"),e}var ET=g.createContext(void 0);ET.displayName="FrameworkContext";function gj(){let e=g.useContext(ET);return ST(e,"You must render this element inside a <HydratedRouter> element"),e}function Nhe(e,t){let n=g.useContext(ET),[r,i]=g.useState(!1),[s,o]=g.useState(!1),{onFocus:a,onBlur:c,onMouseEnter:d,onMouseLeave:f,onTouchStart:p}=t,m=g.useRef(null);g.useEffect(()=>{if(e==="render"&&o(!0),e==="viewport"){let _=C=>
215{C.forEach(P=>{o(P.isIntersecting)})},b=new IntersectionObserver(_,{threshold:.5});return m.current&&b.observe(m.current),()=>{b.disconnect()}}},[e]),g.useEffect(()=>{if(r){let _=setTimeout(()=>{o(!0)},100);return()=>{clearTimeout(_)}}},[r]);let v=()=>{i(!0)},w=()=>{i(!1),o(!1)};return n?e!=="intent"?[s,m,{}]:[s,m,{onFocus:Lh(a,v),onBlur:Lh(c,w),onMouseEnter:Lh(d,v),onMouseLeave:Lh(f,w),onTouchStart:Lh(p,v)}]:[!1,m,{}]}function Lh(e,t){return n=>{e&&e(n),n.defaultPrevented||t(n)}}function $he({page:e,...t}){let{router:n}=mj(),r=g.useMemo(()=>sl(n.routes,e,n.basename),[n.routes,e,n.basename]);return r?g.createElement(Fhe,{page:e,matches:r,...t}):null}function jhe(e){let{manifest:t,routeModules:n}=gj(),[r,i]=g.useState([]);return g.useEffect(()=>{let s=!1;return Ohe(e,t,n).then(o=>{s||i(o)}),()=>{s=!0}},[e,t,n]),r}function Fhe({page:e,matches:t,...n}){let r=Mi(),{future:i,manifest:s,routeModules:o}=gj(),{basename:a}=mj(),{loaderData:c,matches:d}=Lhe(),f=g.useMemo(()=>a4(e,t,d,s,r,"data"),[e,t,d,s,r]),p=g.useMemo(()=>a4(e,t,d,s,r,"assets"),[e,t,d,s,r]),m=g.useMemo(()=>{if(e===r.pathname+r.search+r.hash)return[];let _=new Set,b=!1;if(t.forEach(P=>{let D=s.routes[P.route.id];!D||!D.hasLoader||(!f.some(F=>F.route.id===P.route.id)&&P.route.id in c&&o[P.route.id]?.shouldRevalidate||D.hasClientLoader?b=!0:_.add(P.route.id))}),_.size===0)return[];let C=The(e,a,i.unstable_trailingSlashAwareDataRequests,"data");return b&&_.size>0&&C.searchParams.set("_routes",t.filter(P=>_.has(P.route.id)).map(P=>P.route.id).join(",")),[C.pathname+C.search]},[a,i.unstable_trailingSlashAwareDataRequests,c,r,s,f,t,e,o]),v=g.useMemo(()=>Ahe(p,s),[p,s]),w=jhe(p);return g.createElement(g.Fragment,null,m.map(_=>g.createElement("link",{key:_,rel:"prefetch",as:"fetch",href:_,...n})),v.map(_=>g.createElement("link",{key:_,rel:"modulepreload",href:_,...n})),w.map(({key:_,link:b})=>g.createElement("link",{key:_,nonce:n.nonce,...b,crossOrigin:b.crossOrigin??n.crossOrigin})))}function Uhe(...e){return t=>{e.forEach(n=>{typeof n=="function"?n(t):n!=null&&(n.current=t)})}}var zhe=typeof window<"u"&&typeof window.document<"u"&&typeof window.document.createElement<"u";try{zhe&&(window.__reactRouterVersion="7.13.0")}catch{}function Bhe(e,t){return gfe({basename:t?.basename,getContext:t?.getContext,future:t?.future,history:Ide({window:t?.window}),hydrationData:Hhe(),routes:e,mapRouteProperties:dhe,hydrationRouteProperties:fhe,dataStrategy:t?.dataStrategy,patchRoutesOnNavigation:t?.patchRoutesOnNavigation,window:t?.window,unstable_instrumentations:t?.unstable_instrumentations}).initialize()}function Hhe(){let e=window?.__staticRouterHydrationData;return e&&e.errors&&(e={...e,errors:Vhe(e.errors)}),e}function Vhe(e){if(!e)return null;let t=Object.entries(e),n={};for(let[r,i]of t)if(i&&i.__type==="RouteErrorResponse")n[r]=new Bm(i.status,i.statusText,i.data,i.internal===!0);else if(i&&i.__type==="Error"){if(i.__subType){let s=window[i.__subType];if(typeof s=="function")try{let o=new s(i.message);o.stack="",n[r]=o}catch{}}if(n[r]==null){let s=new Error(i.message);s.stack="",n[r]=s}}else n[r]=i;return n}var yj=/^(?:[a-z][a-z0-9+.-]*:|\/\/)/i,i1=g.forwardRef(function({onClick:t,discover:n="render",prefetch:r="none",relative:i,reloadDocument:s,replace:o,state:a,target:c,to:d,preventScrollReset:f,viewTransition:p,unstable_defaultShouldRevalidate:m,...v},w){let{basename:_,unstable_useTransitions:b}=g.useContext(Ii),C=typeof d=="string"&&yj.test(d),P=G$(d,_);d=P.to;let D=Kfe(d,{relative:i}),[F,R,I]=Nhe(r,v),k=Ghe(d,{replace:o,state:a,target:c,preventScrollReset:f,relative:i,viewTransition:p,unstable_defaultShouldRevalidate:m,unstable_useTransitions:b});function L(A){t&&t(A),A.defaultPrevented||k(A)}let B=g.createElement("a",{...v,...I,href:P.absoluteURL||D,onClick:P.isExternal||s?t:L,ref:Uhe(w,R),target:c,"data-discover":!C&&n==="render"?"true":void 0});return F&&!C?g.createElement(g.Fragment,null,B,g.createElement($he,{page:D})):B});i1.displayName="Link";var Whe=g.forwardRef(function({"aria-current":t="page",caseSensitive:n=!1,className:r="",end:i=!1,style:s,to:o,viewTransition:a,children:c,...d},f){let p=Wm(o,{relative:d.relative}),m=Mi(),v=g.useContext(Vm),{navigator:w,basename:_}=g.useContext(Ii),b=v!=null&&epe(p)&&a===!0,C=w.encodeLocation?w.encodeLocation(p).pathname:p.pathname,P=m.pathname,D=v&&v.navigation&&v.navigation.location?v.navigation.location.pathname:null;n||(P=P.toLowerCase(),D=D?D.toLowerCase():null,C=C.toLowerCase()),D&&_&&(D=is(D,_)||D);const F=C!=="/"&&C.endsWith("/")?C.length-1:C.length;let R=P===C||!i&&P.startsWith(C)&&P.charAt(F)==="/",I=D!=null&&(D===C||!i&&D.startsWith(C)&&D.charAt(C.length)==="/"),k={isActive:R,isPending:I,isTransitioning:b},L=R?t:void 0,B;typeof r=="function"?B=r(k):B=[r,R?"active":null,I?"pending":null,b?"transitioning":null].filter(
215Boolean).join(" ");let A=typeof s=="function"?s(k):s;return g.createElement(i1,{...d,"aria-current":L,className:B,ref:f,style:A,to:o,viewTransition:a},typeof c=="function"?c(k):c)});Whe.displayName="NavLink";var qhe=g.forwardRef(({discover:e="render",fetcherKey:t,navigate:n,reloadDocument:r,replace:i,state:s,method:o=Mv,action:a,onSubmit:c,relative:d,preventScrollReset:f,viewTransition:p,unstable_defaultShouldRevalidate:m,...v},w)=>{let{unstable_useTransitions:_}=g.useContext(Ii),b=Xhe(),C=Qhe(a,{relative:d}),P=o.toLowerCase()==="get"?"get":"post",D=typeof a=="string"&&yj.test(a),F=R=>{if(c&&c(R),R.defaultPrevented)return;R.preventDefault();let I=R.nativeEvent.submitter,k=I?.getAttribute("formmethod")||o,L=()=>b(I||R.currentTarget,{fetcherKey:t,method:k,navigate:n,replace:i,state:s,relative:d,preventScrollReset:f,viewTransition:p,unstable_defaultShouldRevalidate:m});_&&n!==!1?g.startTransition(()=>L()):L()};return g.createElement("form",{ref:w,method:P,action:C,onSubmit:r?c:F,...v,"data-discover":!D&&e==="render"?"true":void 0})});qhe.displayName="Form";function Khe(e){return`${e} must be used within a data router. See https://reactrouter.com/en/main/routers/picking-a-router.`}function vj(e){let t=g.useContext(vu);return Ct(t,Khe(e)),t}function Ghe(e,{target:t,replace:n,state:r,preventScrollReset:i,relative:s,viewTransition:o,unstable_defaultShouldRevalidate:a,unstable_useTransitions:c}={}){let d=jl(),f=Mi(),p=Wm(e,{relative:s});return g.useCallback(m=>{if(She(m,t)){m.preventDefault();let v=n!==void 0?n:oo(f)===oo(p),w=()=>d(e,{replace:v,state:r,preventScrollReset:i,relative:s,viewTransition:o,unstable_defaultShouldRevalidate:a});c?g.startTransition(()=>w()):w()}},[f,d,p,n,r,t,e,i,s,o,a,c])}function Yhe(e){Dn(typeof URLSearchParams<"u","You cannot use the `useSearchParams` hook in a browser that does not support the URLSearchParams API. If you need to support Internet Explorer 11, we recommend you load a polyfill such as https://github.com/ungap/url-search-params.");let t=g.useRef(p2(e)),n=g.useRef(!1),r=Mi(),i=g.useMemo(()=>Ehe(r.search,n.current?null:t.current),[r.search]),s=jl(),o=g.useCallback((a,c)=>{const d=p2(typeof a=="function"?a(new URLSearchParams(i)):a);n.current=!0,s("?"+d,c)},[s,i]);return[i,o]}var Jhe=0,Zhe=()=>`__${String(++Jhe)}__`;function Xhe(){let{router:e}=vj("useSubmit"),{basename:t}=g.useContext(Ii),n=ohe(),r=e.fetch,i=e.navigate;return g.useCallback(async(s,o={})=>{let{action:a,method:c,encType:d,formData:f,body:p}=khe(s,t);if(o.navigate===!1){let m=o.fetcherKey||Zhe();await r(m,n,o.action||a,{unstable_defaultShouldRevalidate:o.unstable_defaultShouldRevalidate,preventScrollReset:o.preventScrollReset,formData:f,body:p,formMethod:o.method||c,formEncType:o.encType||d,flushSync:o.flushSync})}else await i(o.action||a,{unstable_defaultShouldRevalidate:o.unstable_defaultShouldRevalidate,preventScrollReset:o.preventScrollReset,formData:f,body:p,formMethod:o.method||c,formEncType:o.encType||d,replace:o.replace,state:o.state,fromRouteId:n,flushSync:o.flushSync,viewTransition:o.viewTransition})},[r,i,t,n])}function Qhe(e,{relative:t}={}){let{basename:n}=g.useContext(Ii),r=g.useContext(ss);Ct(r,"useFormAction must be used inside a RouteContext");let[i]=r.matches.slice(-1),s={...Wm(e||".",{relative:t})},o=Mi();if(e==null){s.search=o.search;let a=new URLSearchParams(s.search),c=a.getAll("index");if(c.some(f=>f==="")){a.delete("index"),c.filter(p=>p).forEach(p=>a.append("index",p));let f=a.toString();s.search=f?`?${f}`:""}}return(!e||e===".")&&i.route.index&&(s.search=s.search?s.search.replace(/^\?/,"?index&"):"?index"),n!=="/"&&(s.pathname=s.pathname==="/"?n:Xs([n,s.pathname])),oo(s)}function epe(e,{relative:t}={}){let n=g.useContext(vT);Ct(n!=null,"`useViewTransitionState` must be used within `react-router-dom`'s `RouterProvider`. Did you accidentally import `RouterProvider` from `react-router`?");let{basename:r}=vj("useViewTransitionState"),i=Wm(e,{relative:t});if(!n.isTransitioning)return!1;let s=is(n.currentLocation.pathname,r)||n.currentLocation.pathname,o=is(n.nextLocation.pathname,r)||n.nextLocation.pathname;return I0(i.pathname,o)!=null||I0(i.pathname,s)!=null}function tpe(e){return g.createElement(phe,{flushSync:b_.flushSync,...e})}var Vt;(function(e){e.assertEqual=i=>{};function t(i){}e.assertIs=t;function n(i){throw new Error}e.assertNever=n,e.arrayToEnum=i=>{const s={};for(const o of i)s[o]=o;return s},e.getValidEnumValues=i=>{const s=e.objectKeys(i).filter(a=>typeof i[i[a]]!="number"),o={};for(const a of s)o[a]=i[a];return e.objectValues(o)},e.objectValues=i=>e.objectKeys(i).map(function(s){return i[s]}),e.objectKeys=typeof Object.keys=="function"?i=>Object.keys(i):i=>{const s=[];for(const o in i)Object.prototype.hasOwnProperty.call(i,o)&&s.push(o);return s},e.find=(i,s)=>{for(const o of i)if(s(o))return o}
vendor: 10,667 bytes, line 215
215,e.isInteger=typeof Number.isInteger=="function"?i=>Number.isInteger(i):i=>typeof i=="number"&&Number.isFinite(i)&&Math.floor(i)===i;function r(i,s=" | "){return i.map(o=>typeof o=="string"?`'${o}'`:o).join(s)}e.joinValues=r,e.jsonStringifyReplacer=(i,s)=>typeof s=="bigint"?s.toString():s})(Vt||(Vt={}));var l4;(function(e){e.mergeShapes=(t,n)=>({...t,...n})})(l4||(l4={}));const $e=Vt.arrayToEnum(["string","nan","number","integer","float","boolean","date","bigint","symbol","function","undefined","null","array","object","unknown","promise","void","never","map","set"]),nl=e=>{switch(typeof e){case"undefined":return $e.undefined;case"string":return $e.string;case"number":return Number.isNaN(e)?$e.nan:$e.number;case"boolean":return $e.boolean;case"function":return $e.function;case"bigint":return $e.bigint;case"symbol":return $e.symbol;case"object":return Array.isArray(e)?$e.array:e===null?$e.null:e.then&&typeof e.then=="function"&&e.catch&&typeof e.catch=="function"?$e.promise:typeof Map<"u"&&e instanceof Map?$e.map:typeof Set<"u"&&e instanceof Set?$e.set:typeof Date<"u"&&e instanceof Date?$e.date:$e.object;default:return $e.unknown}},ve=Vt.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 oa 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(s){return s.message},r={_errors:[]},i=s=>{for(const o of s.issues)if(o.code==="invalid_union")o.unionErrors.map(i);else if(o.code==="invalid_return_type")i(o.returnTypeError);else if(o.code==="invalid_arguments")i(o.argumentsError);else if(o.path.length===0)r._errors.push(n(o));else{let a=r,c=0;for(;c<o.path.length;){const d=o.path[c];c===o.path.length-1?(a[d]=a[d]||{_errors:[]},a[d]._errors.push(n(o))):a[d]=a[d]||{_errors:[]},a=a[d],c++}}};return i(this),r}static assert(t){if(!(t instanceof oa))throw new Error(`Not a ZodError: ${t}`)}toString(){return this.message}get message(){return JSON.stringify(this.issues,Vt.jsonStringifyReplacer,2)}get isEmpty(){return this.issues.length===0}flatten(t=n=>n.message){const n={},r=[];for(const i of this.issues)if(i.path.length>0){const s=i.path[0];n[s]=n[s]||[],n[s].push(t(i))}else r.push(t(i));return{formErrors:r,fieldErrors:n}}get formErrors(){return this.flatten()}}oa.create=e=>new oa(e);const m2=(e,t)=>{let n;switch(e.code){case ve.invalid_type:e.received===$e.undefined?n="Required":n=`Expected ${e.expected}, received ${e.received}`;break;case ve.invalid_literal:n=`Invalid literal value, expected ${JSON.stringify(e.expected,Vt.jsonStringifyReplacer)}`;break;case ve.unrecognized_keys:n=`Unrecognized key(s) in object: ${Vt.joinValues(e.keys,", ")}`;break;case ve.invalid_union:n="Invalid input";break;case ve.invalid_union_discriminator:n=`Invalid discriminator value. Expected ${Vt.joinValues(e.options)}`;break;case ve.invalid_enum_value:n=`Invalid enum value. Expected ${Vt.joinValues(e.options)}, received '${e.received}'`;break;case ve.invalid_arguments:n="Invalid function arguments";break;case ve.invalid_return_type:n="Invalid function return type";break;case ve.invalid_date:n="Invalid date";break;case ve.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}"`:Vt.assertNever(e.validation):e.validation!=="regex"?n=`Invalid ${e.validation}`:n="Invalid";break;case ve.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 ve.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 ve.custom:n="Invalid input";break;case ve.invalid_intersection_types:n="Intersection results could not be merged";break;case ve.not_multiple_of:n=`Number must be a multiple of ${e.multipleOf}`;break;case ve.not_finite:n="Number must be finite";break;default:n=t.defaultError,Vt.assertNever(e)}return{message:n}};let npe=m2;function rpe(){return npe}const ipe=e=>{const{data:t,path:n,errorMaps:r,issueData:i}=e,s=[...n,...i.path||[]],o={...i,path:s};if(i.message!==void 0)return{...i,path:s,message:i.message};let a="";const c=r.filter(d=>!!d).slice().reverse();for(const d of c)a=d(o,{data:t,defaultError:a}).message;return{...i,path:s,message:a}};function Ae(e,t){const n=rpe(),r=ipe({issueData:t,data:e.data,path:e.path,errorMaps:[e.common.contextualErrorMap,e.schemaErrorMap,n,n===m2?void 0:m2].filter(i=>!!i)});e.common.issues.push(r)}class Oi{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 i of n){if(i.status==="aborted")return mt;i.status==="dirty"&&t.dirty(),r.push(i.value)}return{status:t.value,value:r}}static async mergeObjectAsync(t,n){const r=[];for(const i of n){const s=await i.key,o=await i.value;r.push({key:s,value:o})}return Oi.mergeObjectSync(t,r)}static mergeObjectSync(t,n){const r={};for(const i of n){const{key:s,value:o}=i;if(s.status==="aborted"||o.status==="aborted")return mt;s.status==="dirty"&&t.dirty(),o.status==="dirty"&&t.dirty(),s.value!=="__proto__"&&(typeof o.value<"u"||i.alwaysSet)&&(r[s.value]=o.value)}return{status:t.value,value:r}}}const mt=Object.freeze({status:"aborted"}),tp=e=>({status:"dirty",value:e}),os=e=>({status:"valid",value:e}),c4=e=>e.status==="aborted",u4=e=>e.status==="dirty",nf=e=>e.status==="valid",M0=e=>typeof Promise<"u"&&e instanceof Promise;var Ke;(function(e){e.errToObj=t=>typeof t=="string"?{message:t}:t||{},e.toString=t=>typeof t=="string"?t:t?.message})(Ke||(Ke={}));class xl{constructor(t,n,r,i){this._cachedPath=[],this.parent=t,this.data=n,this._path=r,this._key=i}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 d4=(e,t)=>{if(nf(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 oa(e.common.issues);return this._error=n,this._error}}};function kt(e){if(!e)return{};const{errorMap:t,invalid_type_error:n,required_error:r,description:i}=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:i}:{errorMap:(o,a)=>{const{message:c}=e;return o.code==="invalid_enum_value"?{message:c??a.defaultError}:typeof a.data>"u"?{message:c??r??a.defaultError}:o.code!=="invalid_type"?{message:a.defaultError}:{message:c??n??a.defaultError}},description:i}}class Bt{get description(){return this._def.description}_getType(t){return nl(t.data)}_getOrReturnCtx(t,n){return n||{common:t.parent.common,data:t.data,parsedType:nl(t.data),schemaErrorMap:this._def.errorMap,path:t.path,parent:t.parent}}_processInputParams(t){return{status:new Oi,ctx:{common:t.parent.common,data:t.data,parsedType:nl(t.data),schemaErrorMap:this._def.errorMap,path:t.path,parent:t.parent}}}_parseSync(t){const n=this._parse(t);if(M0(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?.async??!1,contextualErrorMap:n?.errorMap},path:n?.path||[],schemaErrorMap:this._def.errorMap,parent:null,data:t,parsedType:nl(t)},i=this._parseSync({data:t,path:r.path,parent:r});return d4(r,i)}"~validate"(t){const n={common:{issues:[],async:!!this["~standard"].async},path:[],schemaErrorMap:this._def.errorMap,parent:null,data:t,parsedType:nl(t)};if(!this["~standard"].async)try{const r=this._parseSync({data:t,path:[],parent:n});return nf(r)?{value:r.value}:{issues:n.common.issues}}catch(r){r?.message?.toLowerCase()?.includes("encountered")&&(this["~standard"].async=!0),n.common={issues:[],async:!0}}return this._parseAsync({data:t,path:[],parent:n}).then(r=>nf(r)?{value:r.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?.errorMap,async:!0},path:n?.path||[],schemaErrorMap:this._def.errorMap,parent:null,data:t,parsedType:nl(t)},i=this._parse({data:t,path:r.path,parent:r}),s=await(M0(i)?i:Promise.resolve(i));return d4(r,s)}refine(t,n){const r=i=>typeof n=="string"||typeof n>"u"?{message:n}:typeof n=="function"?n(i):n;return this._refinement((i,s)=>{const o=t(i),a=()=>s.addIssue({code:ve.custom,...r(i)});return typeof Promise<"u"&&o instanceof Promise?o.then(c=>c?!0:(a(),!1)):o?!0:(a(),!1)})}refinement(t,n){return this._refinement((r,i)=>
215t(r)?!0:(i.addIssue(typeof n=="function"?n(r,i):n),!1))}_refinement(t){return new ru({schema:this,typeName:_t.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 Ko.create(this,this._def)}nullable(){return iu.create(this,this._def)}nullish(){return this.nullable().optional()}array(){return Qs.create(this)}promise(){return j0.create(this,this._def)}or(t){return L0.create([this,t],this._def)}and(t){return N0.create(this,t,this._def)}transform(t){return new ru({...kt(this._def),schema:this,typeName:_t.ZodEffects,effect:{type:"transform",transform:t}})}default(t){const n=typeof t=="function"?t:()=>t;return new F0({...kt(this._def),innerType:this,defaultValue:n,typeName:_t.ZodDefault})}brand(){return new Sj({typeName:_t.ZodBranded,type:this,...kt(this._def)})}catch(t){const n=typeof t=="function"?t:()=>t;return new U0({...kt(this._def),innerType:this,catchValue:n,typeName:_t.ZodCatch})}describe(t){const n=this.constructor;return new n({...this._def,description:t})}pipe(t){return CT.create(this,t)}readonly(){return z0.create(this)}isOptional(){return this.safeParse(void 0).success}isNullable(){return this.safeParse(null).success}}const spe=/^c[^\s-]{8,}$/i,ope=/^[0-9a-z]+$/,ape=/^[0-9A-HJKMNP-TV-Z]{26}$/i,lpe=/^[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,cpe=/^[a-z0-9_-]{21}$/i,upe=/^[A-Za-z0-9-_]+\.[A-Za-z0-9-_]+\.[A-Za-z0-9-_]*$/,dpe=/^[-+]?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)?)??$/,fpe=/^(?!\.)(?!.*\.\.)([A-Z0-9_'+\-\.]*)[A-Z0-9_+-]@([A-Z0-9][A-Z0-9\-]*\.)+[A-Z]{2,}$/i,hpe="^(\\p{Extended_Pictographic}|\\p{Emoji_Component})+$";let ES;const ppe=/^(?:(?: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])$/,mpe=/^(?:(?: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])$/,gpe=/^(([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]))$/,ype=/^(([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}
vendor: 4,245 bytes, line 215
215[0-9]))\/(12[0-8]|1[01][0-9]|[1-9]?[0-9])$/,vpe=/^([0-9a-zA-Z+/]{4})*(([0-9a-zA-Z+/]{2}==)|([0-9a-zA-Z+/]{3}=))?$/,_pe=/^([0-9a-zA-Z-_]{4})*(([0-9a-zA-Z-_]{2}(==)?)|([0-9a-zA-Z-_]{3}(=)?))?$/,_j="((\\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])))",wpe=new RegExp(`^${_j}$`);function wj(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 bpe(e){return new RegExp(`^${wj(e)}$`)}function Spe(e){let t=`${_j}T${wj(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 Epe(e,t){return!!((t==="v4"||!t)&&ppe.test(e)||(t==="v6"||!t)&&gpe.test(e))}function xpe(e,t){if(!upe.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,"="),i=JSON.parse(atob(r));return!(typeof i!="object"||i===null||"typ"in i&&i?.typ!=="JWT"||!i.alg||t&&i.alg!==t)}catch{return!1}}function Cpe(e,t){return!!((t==="v4"||!t)&&mpe.test(e)||(t==="v6"||!t)&&ype.test(e))}class Fo extends Bt{_parse(t){if(this._def.coerce&&(t.data=String(t.data)),this._getType(t)!==$e.string){const s=this._getOrReturnCtx(t);return Ae(s,{code:ve.invalid_type,expected:$e.string,received:s.parsedType}),mt}const r=new Oi;let i;for(const s of this._def.checks)if(s.kind==="min")t.data.length<s.value&&(i=this._getOrReturnCtx(t,i),Ae(i,{code:ve.too_small,minimum:s.value,type:"string",inclusive:!0,exact:!1,message:s.message}),r.dirty());else if(s.kind==="max")t.data.length>s.value&&(i=this._getOrReturnCtx(t,i),Ae(i,{code:ve.too_big,maximum:s.value,type:"string",inclusive:!0,exact:!1,message:s.message}),r.dirty());else if(s.kind==="length"){const o=t.data.length>s.value,a=t.data.length<s.value;(o||a)&&(i=this._getOrReturnCtx(t,i),o?Ae(i,{code:ve.too_big,maximum:s.value,type:"string",inclusive:!0,exact:!0,message:s.message}):a&&Ae(i,{code:ve.too_small,minimum:s.value,type:"string",inclusive:!0,exact:!0,message:s.message}),r.dirty())}else if(s.kind==="email")fpe.test(t.data)||(i=this._getOrReturnCtx(t,i),Ae(i,{validation:"email",code:ve.invalid_string,message:s.message}),r.dirty());else if(s.kind==="emoji")ES||(ES=new RegExp(hpe,"u")),ES.test(t.data)||(i=this._getOrReturnCtx(t,i),Ae(i,{validation:"emoji",code:ve.invalid_string,message:s.message}),r.dirty());else if(s.kind==="uuid")lpe.test(t.data)||(i=this._getOrReturnCtx(t,i),Ae(i,{validation:"uuid",code:ve.invalid_string,message:s.message}),r.dirty());else if(s.kind==="nanoid")cpe.test(t.data)||(i=this._getOrReturnCtx(t,i),Ae(i,{validation:"nanoid",code:ve.invalid_string,message:s.message}),r.dirty());else if(s.kind==="cuid")spe.test(t.data)||(i=this._getOrReturnCtx(t,i),Ae(i,{validation:"cuid",code:ve.invalid_string,message:s.message}),r.dirty());else if(s.kind==="cuid2")ope.test(t.data)||(i=this._getOrReturnCtx(t,i),Ae(i,{validation:"cuid2",code:ve.invalid_string,message:s.message}),r.dirty());else if(s.kind==="ulid")ape.test(t.data)||(i=this._getOrReturnCtx(t,i),Ae(i,{validation:"ulid",code:ve.invalid_string,message:s.message}),r.dirty());else if(s.kind==="url")try{new URL(t.data)}catch{i=this._getOrReturnCtx(t,i),Ae(i,{validation:"url",code:ve.invalid_string,message:s.message}),r.dirty()}else s.kind==="regex"?(s.regex.lastIndex=0,s.regex.test(t.data)||(i=this._getOrReturnCtx(t,i),Ae(i,{validation:"regex",code:ve.invalid_string,message:s.message}),r.dirty())):s.kind==="trim"?t.data=t.data.trim():s.kind==="includes"?t.data.includes(s.value,s.position)||(i=this._getOrReturnCtx(t,i),Ae(i,{code:ve.invalid_string,validation:{includes:s.value,position:s.position},message:s.message}),r.dirty()):s.kind==="toLowerCase"?t.data=t.data.toLowerCase():s.kind==="toUpperCase"?t.data=t.data.toUpperCase():s.kind==="startsWith"?t.data.startsWith(s.value)||(i=this._getOrReturnCtx(t,i),Ae(i,{code:ve.invalid_string,validation:{startsWith:s.value},message:s.message}),r.dirty()):s.kind==="endsWith"?t.data.endsWith(s.value)||(i=this._getOrReturnCtx(t,i),Ae(i,{code:ve.invali
vendor: 4,387 bytes, line 215
215d_string,validation:{endsWith:s.value},message:s.message}),r.dirty()):s.kind==="datetime"?Spe(s).test(t.data)||(i=this._getOrReturnCtx(t,i),Ae(i,{code:ve.invalid_string,validation:"datetime",message:s.message}),r.dirty()):s.kind==="date"?wpe.test(t.data)||(i=this._getOrReturnCtx(t,i),Ae(i,{code:ve.invalid_string,validation:"date",message:s.message}),r.dirty()):s.kind==="time"?bpe(s).test(t.data)||(i=this._getOrReturnCtx(t,i),Ae(i,{code:ve.invalid_string,validation:"time",message:s.message}),r.dirty()):s.kind==="duration"?dpe.test(t.data)||(i=this._getOrReturnCtx(t,i),Ae(i,{validation:"duration",code:ve.invalid_string,message:s.message}),r.dirty()):s.kind==="ip"?Epe(t.data,s.version)||(i=this._getOrReturnCtx(t,i),Ae(i,{validation:"ip",code:ve.invalid_string,message:s.message}),r.dirty()):s.kind==="jwt"?xpe(t.data,s.alg)||(i=this._getOrReturnCtx(t,i),Ae(i,{validation:"jwt",code:ve.invalid_string,message:s.message}),r.dirty()):s.kind==="cidr"?Cpe(t.data,s.version)||(i=this._getOrReturnCtx(t,i),Ae(i,{validation:"cidr",code:ve.invalid_string,message:s.message}),r.dirty()):s.kind==="base64"?vpe.test(t.data)||(i=this._getOrReturnCtx(t,i),Ae(i,{validation:"base64",code:ve.invalid_string,message:s.message}),r.dirty()):s.kind==="base64url"?_pe.test(t.data)||(i=this._getOrReturnCtx(t,i),Ae(i,{validation:"base64url",code:ve.invalid_string,message:s.message}),r.dirty()):Vt.assertNever(s);return{status:r.value,value:t.data}}_regex(t,n,r){return this.refinement(i=>t.test(i),{validation:n,code:ve.invalid_string,...Ke.errToObj(r)})}_addCheck(t){return new Fo({...this._def,checks:[...this._def.checks,t]})}email(t){return this._addCheck({kind:"email",...Ke.errToObj(t)})}url(t){return this._addCheck({kind:"url",...Ke.errToObj(t)})}emoji(t){return this._addCheck({kind:"emoji",...Ke.errToObj(t)})}uuid(t){return this._addCheck({kind:"uuid",...Ke.errToObj(t)})}nanoid(t){return this._addCheck({kind:"nanoid",...Ke.errToObj(t)})}cuid(t){return this._addCheck({kind:"cuid",...Ke.errToObj(t)})}cuid2(t){return this._addCheck({kind:"cuid2",...Ke.errToObj(t)})}ulid(t){return this._addCheck({kind:"ulid",...Ke.errToObj(t)})}base64(t){return this._addCheck({kind:"base64",...Ke.errToObj(t)})}base64url(t){return this._addCheck({kind:"base64url",...Ke.errToObj(t)})}jwt(t){return this._addCheck({kind:"jwt",...Ke.errToObj(t)})}ip(t){return this._addCheck({kind:"ip",...Ke.errToObj(t)})}cidr(t){return this._addCheck({kind:"cidr",...Ke.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?.precision>"u"?null:t?.precision,offset:t?.offset??!1,local:t?.local??!1,...Ke.errToObj(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?.precision>"u"?null:t?.precision,...Ke.errToObj(t?.message)})}duration(t){return this._addCheck({kind:"duration",...Ke.errToObj(t)})}regex(t,n){return this._addCheck({kind:"regex",regex:t,...Ke.errToObj(n)})}includes(t,n){return this._addCheck({kind:"includes",value:t,position:n?.position,...Ke.errToObj(n?.message)})}startsWith(t,n){return this._addCheck({kind:"startsWith",value:t,...Ke.errToObj(n)})}endsWith(t,n){return this._addCheck({kind:"endsWith",value:t,...Ke.errToObj(n)})}min(t,n){return this._addCheck({kind:"min",value:t,...Ke.errToObj(n)})}max(t,n){return this._addCheck({kind:"max",value:t,...Ke.errToObj(n)})}length(t,n){return this._addCheck({kind:"length",value:t,...Ke.errToObj(n)})}nonempty(t){return this.min(1,Ke.errToObj(t))}trim(){return new Fo({...this._def,checks:[...this._def.checks,{kind:"trim"}]})}toLowerCase(){return new Fo({...this._def,checks:[...this._def.checks,{kind:"toLowerCase"}]})}toUpperCase(){return new Fo({...this._def,checks:[...this._def.checks,{kind:"toUpperCase"}]})}get isDatetime(){return!!this._def.checks.find(t=>t.kind==="datetime")}get 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")}
vendor: 16,665 bytes, line 215
215get 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}}Fo.create=e=>new Fo({checks:[],typeName:_t.ZodString,coerce:e?.coerce??!1,...kt(e)});function kpe(e,t){const n=(e.toString().split(".")[1]||"").length,r=(t.toString().split(".")[1]||"").length,i=n>r?n:r,s=Number.parseInt(e.toFixed(i).replace(".","")),o=Number.parseInt(t.toFixed(i).replace(".",""));return s%o/10**i}class Qc extends Bt{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)!==$e.number){const s=this._getOrReturnCtx(t);return Ae(s,{code:ve.invalid_type,expected:$e.number,received:s.parsedType}),mt}let r;const i=new Oi;for(const s of this._def.checks)s.kind==="int"?Vt.isInteger(t.data)||(r=this._getOrReturnCtx(t,r),Ae(r,{code:ve.invalid_type,expected:"integer",received:"float",message:s.message}),i.dirty()):s.kind==="min"?(s.inclusive?t.data<s.value:t.data<=s.value)&&(r=this._getOrReturnCtx(t,r),Ae(r,{code:ve.too_small,minimum:s.value,type:"number",inclusive:s.inclusive,exact:!1,message:s.message}),i.dirty()):s.kind==="max"?(s.inclusive?t.data>s.value:t.data>=s.value)&&(r=this._getOrReturnCtx(t,r),Ae(r,{code:ve.too_big,maximum:s.value,type:"number",inclusive:s.inclusive,exact:!1,message:s.message}),i.dirty()):s.kind==="multipleOf"?kpe(t.data,s.value)!==0&&(r=this._getOrReturnCtx(t,r),Ae(r,{code:ve.not_multiple_of,multipleOf:s.value,message:s.message}),i.dirty()):s.kind==="finite"?Number.isFinite(t.data)||(r=this._getOrReturnCtx(t,r),Ae(r,{code:ve.not_finite,message:s.message}),i.dirty()):Vt.assertNever(s);return{status:i.value,value:t.data}}gte(t,n){return this.setLimit("min",t,!0,Ke.toString(n))}gt(t,n){return this.setLimit("min",t,!1,Ke.toString(n))}lte(t,n){return this.setLimit("max",t,!0,Ke.toString(n))}lt(t,n){return this.setLimit("max",t,!1,Ke.toString(n))}setLimit(t,n,r,i){return new Qc({...this._def,checks:[...this._def.checks,{kind:t,value:n,inclusive:r,message:Ke.toString(i)}]})}_addCheck(t){return new Qc({...this._def,checks:[...this._def.checks,t]})}int(t){return this._addCheck({kind:"int",message:Ke.toString(t)})}positive(t){return this._addCheck({kind:"min",value:0,inclusive:!1,message:Ke.toString(t)})}negative(t){return this._addCheck({kind:"max",value:0,inclusive:!1,message:Ke.toString(t)})}nonpositive(t){return this._addCheck({kind:"max",value:0,inclusive:!0,message:Ke.toString(t)})}nonnegative(t){return this._addCheck({kind:"min",value:0,inclusive:!0,message:Ke.toString(t)})}multipleOf(t,n){return this._addCheck({kind:"multipleOf",value:t,message:Ke.toString(n)})}finite(t){return this._addCheck({kind:"finite",message:Ke.toString(t)})}safe(t){return this._addCheck({kind:"min",inclusive:!0,value:Number.MIN_SAFE_INTEGER,message:Ke.toString(t)})._addCheck({kind:"max",inclusive:!0,value:Number.MAX_SAFE_INTEGER,message:Ke.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"&&Vt.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)}}Qc.create=e=>new Qc({checks:[],typeName:_t.ZodNumber,coerce:e?.coerce||!1,...kt(e)});class eu extends Bt{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)!==$e.bigint)return this._getInvalidInput(t);let r;const i=new Oi;for(const s of this._def.checks)s.kind==="min"?(s.inclusive?t.data<s.value:t.data<=s.value)&&(r=this._getOrReturnCtx(t,r),Ae(r,{code:ve.too_small,type:"bigint",minimum:s.value,inclusive:s.inclusive,message:s.message}),i.dirty()):s.kind==="max"?(s.inclusive?t.data>s.value:t.data>=s.value)&&(r=this._getOrReturnCtx(t,r),Ae(r,{code:ve.too_big,type:"bigint",maximum:s.value,inclusive:s.inclusive,message:s.message}),i.dirty()):s.kind==="multipleOf"?t.data%s.value!==BigInt(0)&&(r=this._getOrReturnCtx(t,r),Ae(r,{code:ve.not_multiple_of,multipleOf:s.value,message:s.message}),i.dirty()):Vt.assertNever(s);return{status:i.value,value:t.data}}_getInvalidInput(t){const n=this._getOrReturnCtx(t);return Ae(n,{code:ve.invalid_type,expected:$e.bigint,received:n.parsedType}),mt}gte(t,n){return this.setLimit("min",t,!0,Ke.toString(n))}gt(t,n){return this.setLimit("min",t,!1,Ke.toString(n))}lte(t,n){return this.setLimit("max",t,!0,Ke.toString(n))}lt(t,n){return this.setLimit("max",t,!1,Ke.toString(n))}setLimit(t,n,r,i){return new eu({...this._def,checks:[...this._def.checks,{kind:t,value:n,inclusive:r,message:Ke.toString(i)}]})}_addCheck(t){return new eu({...this._def,checks:[...this._def.checks,t]})}positive(t){return this._addCheck({kind:"min",value:BigInt(0),inclusive:!1,message:Ke.toString(t)})}negative(t){return this._addCheck({kind:"max",value:BigInt(0),inclusive:!1,message:Ke.toString(t)})}nonpositive(t){return this._addCheck({kind:"max",value:BigInt(0),inclusive:!0,message:Ke.toString(t)})}nonnegative(t){return this._addCheck({kind:"min",value:BigInt(0),inclusive:!0,message:Ke.toString(t)})}multipleOf(t,n){return this._addCheck({kind:"multipleOf",value:t,message:Ke.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}}eu.create=e=>new eu({checks:[],typeName:_t.ZodBigInt,coerce:e?.coerce??!1,...kt(e)});class D0 extends Bt{_parse(t){if(this._def.coerce&&(t.data=!!t.data),this._getType(t)!==$e.boolean){const r=this._getOrReturnCtx(t);return Ae(r,{code:ve.invalid_type,expected:$e.boolean,received:r.parsedType}),mt}return os(t.data)}}D0.create=e=>new D0({typeName:_t.ZodBoolean,coerce:e?.coerce||!1,...kt(e)});class rf extends Bt{_parse(t){if(this._def.coerce&&(t.data=new Date(t.data)),this._getType(t)!==$e.date){const s=this._getOrReturnCtx(t);return Ae(s,{code:ve.invalid_type,expected:$e.date,received:s.parsedType}),mt}if(Number.isNaN(t.data.getTime())){const s=this._getOrReturnCtx(t);return Ae(s,{code:ve.invalid_date}),mt}const r=new Oi;let i;for(const s of this._def.checks)s.kind==="min"?t.data.getTime()<s.value&&(i=this._getOrReturnCtx(t,i),Ae(i,{code:ve.too_small,message:s.message,inclusive:!0,exact:!1,minimum:s.value,type:"date"}),r.dirty()):s.kind==="max"?t.data.getTime()>s.value&&(i=this._getOrReturnCtx(t,i),Ae(i,{code:ve.too_big,message:s.message,inclusive:!0,exact:!1,maximum:s.value,type:"date"}),r.dirty()):Vt.assertNever(s);return{status:r.value,value:new Date(t.data.getTime())}}_addCheck(t){return new rf({...this._def,checks:[...this._def.checks,t]})}min(t,n){return this._addCheck({kind:"min",value:t.getTime(),message:Ke.toString(n)})}max(t,n){return this._addCheck({kind:"max",value:t.getTime(),message:Ke.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}}rf.create=e=>new rf({checks:[],coerce:e?.coerce||!1,typeName:_t.ZodDate,...kt(e)});class f4 extends Bt{_parse(t){if(this._getType(t)!==$e.symbol){const r=this._getOrReturnCtx(t);return Ae(r,{code:ve.invalid_type,expected:$e.symbol,received:r.parsedType}),mt}return os(t.data)}}f4.create=e=>new f4({typeName:_t.ZodSymbol,...kt(e)});class g2 extends Bt{_parse(t){if(this._getType(t)!==$e.undefined){const r=this._getOrReturnCtx(t);return Ae(r,{code:ve.invalid_type,expected:$e.undefined,received:r.parsedType}),mt}return os(t.data)}}g2.create=e=>new g2({typeName:_t.ZodUndefined,...kt(e)});class y2 extends Bt{_parse(t){if(this._getType(t)!==$e.null){const r=this._getOrReturnCtx(t);return Ae(r,{code:ve.invalid_type,expected:$e.null,received:r.parsedType}),mt}return os(t.data)}}y2.create=e=>new y2({typeName:_t.ZodNull,...kt(e)});class v2 extends Bt{constructor(){super(...arguments),this._any=!0}_parse(t){return os(t.data)}}v2.create=e=>new v2({typeName:_t.ZodAny,...kt(e)});class h4 extends Bt{constructor(){super(...arguments),this._unknown=!0}_parse(t){return os(t.data)}}h4.create=e=>new h4({typeName:_t.ZodUnknown,...kt(e)});class Cl extends Bt{_parse(t){const n=this._getOrReturnCtx(t);return Ae(n,{code:ve.invalid_type,expected:$e.never,received:n.parsedType}),mt}}Cl.create=e=>new Cl({typeName:_t.ZodNever,...kt(e)});class p4 extends Bt{_parse(t){if(this._getType(t)!==$e.undefined){const r=this._getOrReturnCtx(t);return Ae(r,{code:ve.invalid_type,expected:$e.void,received:r.parsedType}),mt}return os(t.data)}}p4.create=e=>new p4({typeName:_t.ZodVoid,...kt(e)});class Qs extends Bt{_parse(t){const{ctx:n,status:r}=this._processInputParams(t),i=this._def;if(n.parsedType!==$e.array)return Ae(n,{code:ve.invalid_type,expected:$e.array,received:n.parsedType}),mt;if(i.exactLength!==null){const o=n.data.length>i.exactLength.value,a=n.data.length<i.exactLength.value;(o||a)&&(Ae(n,{code:o?ve.too_big:ve.too_small,minimum:a?i.exactLength.value:void 0,maximum:o?i.exactLength.value:void 0,type:"array",inclusive:!0,exact:!0,message:i.exactLength.message}),r.dirty())}if(i.minLength!==null&&n.data.length<i.minLength.value&&(Ae(n,{code:ve.too_small,minimum:i.minLength.value,type:"array",inclusive:!0,exact:!1,message:i.minLength.message}),r.dirty()),i.maxLength!==null&&n.data.length>i.maxLength.value&&(Ae(n,{code:ve.too_big,maximum:i.maxLength.value,type:"array",inclusive:!0,exact:!1,message:i.maxLength.message}),r.dirty()),n.common.async)return Promise.all([...n.data].map((o,a)=>i.type._parseAsync(new xl(n,o,n.path,a)))).then(o=>Oi.mergeArray(r,o));const s=[...n.data].map((o,a)=>i.type._parseSync(new xl(n,o,n.path,a)));return Oi.mergeArray(r,s)}get element(){return this._def.type}min(t,n){return new Qs({...this._def,minLength:{value:t,message:Ke.toString(n)}})}max(t,n){return new Qs({...this._def,maxLength:{value:t,message:Ke.toString(n)}})}length(t,n){return new Qs({...this._def,exactLength:{value:t,message:Ke.toString(n)}})}nonempty(t){return this.min(1,t)}}Qs.create=(e,t)=>new Qs({type:e,minLength:null,maxLength:null,exactLength:null,typeName:_t.ZodArray,...kt(t)});function dd(e){if(e instanceof qn){const t={};for(const n in e.shape){const r=e.shape[n];t[n]=Ko.create(dd(r))}return new qn({...e._def,shape:()=>t})}else return e instanceof Qs?new Qs({...e._def,type:dd(e.element)}):e instanceof Ko?Ko.create(dd(e.unwrap())):e instanceof iu?iu.create(dd(e.unwrap())):e instanceof tu?tu.create(e.items.map(t=>dd(t))):e}class qn extends Bt{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=Vt.objectKeys(t);return this._cached={shape:t,keys:n},this._cached}_parse(t){if(this._getType(t)!==$e.object){const d=this._getOrReturnCtx(t);return Ae(d,{code:ve.invalid_type,expected:$e.object,received:d.parsedType}),mt}const{status:r,ctx:i}=this._processInputParams(t),{shape:s,keys:o}=this._getCached(),a=[];if(!(this._def.catchall instanceof Cl&&this._def.unknownKeys==="strip"))for(const d in i.data)o.includes(d)||a.push(d);const c=[];for(const d of o){const f=s[d],p=i.data[d];c.push({key:{status:"valid",value:d},value:f._parse(new xl(i,p,i.path,d)),alwaysSet:d in i.data})}if(this._def.catchall instanceof Cl){const d=this._def.unknownKeys;if(d==="passthrough")for(const f of a)c.push({key:{status:"valid",value:f},value:{status:"valid",value:i.data[f]}});else if(d==="strict")a.length>0&&(Ae(i,{code:ve.unrecognized_keys,keys:a}),r.dirty());else if(d!=="strip")throw new Error("Internal ZodObject error: invalid unknownKeys value.")}else{const d=this._def.catchall;for(const f of a){const p=i.data[f];c.push({key:{status:"valid",value:f},value:d._parse(new xl(i,p,i.path,f)),alwaysSet:f in i.data})}}return i.common.async?Promise.resolve().then(async()=>{const d=[];for(const f of c){const p=await f.key,m=await f.value;d.push({key:p,value:m,alwaysSet:f.alwaysSet})}return d}).then(d=>Oi.mergeObjectSync(r,d)):Oi.mergeObjectSync(r,c)}get shape(){return this._def.shape()}strict(t){return Ke.errToObj,new qn({...this._def,unknownKeys:"strict",...t!==void 0?{errorMap:(n,r)=>{const i=this._def.errorMap?.(n,r).message??r.defaultError;return n.code==="unrecognized_keys"?{message:Ke.errToObj(t).message??i}:{message:i}}}:{}})}strip(){return new qn({...this._def,unknownKeys:"strip"})}passthrough(){return new qn({...this._def,unknownKeys:"passthrough"})}extend(t){return new qn({...this._def,shape:()=>({...this._def.shape(),...t})})}merge(t){return new qn({unknownKeys:t._def.unknownKeys,catchall:t._def.catchall,shape:()=>({...this._def.shape(),...t._def.shape()}),typeName:_t.ZodObject})}setKey(t,n){return this.augment({[t]:n})}catchall(t){return new qn({...this._def,catchall:t})}pick(t){const n={};for(const r of Vt.objectKeys(t))t[r]&&this.shape[r]&&(n[r]=this.shape[r]);return new qn({...this._def,shape:()=>n})}omit(t){const n={};for(const r of Vt.objectKeys(this.shape))t[r]||(n[r]=this.shape[r]);return new qn({...this._def,shape:()=>n})}deepPartial(){return dd(this)}partial(t){const n={};for(const r of Vt.objectKeys(this.shape)){const i=this.shape[r];t&&!t[r]?n[r]=i:n[r]=i.optional()}return new qn({...this._def,shape:()=>n})}required(t){const n={};for(const r of Vt.objectKeys(this.shape))if(t&&!t[r])n[r]=this.shape[r];else{let s=this.shape[r];for(;s instanceof Ko;)s=s._def.innerType;n[r]=s}return new qn({...this._def,shape:()=>n})}keyof(){return bj(Vt.objectKeys(this.shape))}}qn.create=(e,t)=>new qn({shape:()=>e,unknownKeys:"strip",catchall:Cl.create(),typeName:_t.ZodObject,...kt(t)});qn.strictCreate=(e,t)=>new qn({shape:()=>e,unknownKeys:"strict",catchall:Cl.create(),typeName:_t.ZodObject,...kt(t)});qn.lazycreate=(e,t)=>new qn({shape:e,unknownKeys:"strip",catchall:Cl.create(),typeName:_t.ZodObject,...kt(t)});class L0 extends Bt{_parse(t){const{ctx:n}=this._processInputParams(t),r=this._def.options;function i(s){for(const a of s)if(a.result.status==="valid")return a.result;for(const a of s)if(a.result.status==="dirty")return n.common.issues.push(...a.ctx.common.issues),a.result;const o=s.map(a=>new oa(a.ctx.common.issues));return Ae(n,{code:ve.invalid_union,unionErrors:o}),mt}if(n.common.async)return Promise.all(r.map(async s=>{const o={...n,common:{...n.common,issues:[]},parent:null};return{result:await s._parseAsync({data:n.data,path:n.path,parent:o}),ctx:o}})).then(i);{let s;const o=[];for(const c of r){const d={...n,common:{...n.common,issues:[]},parent:null},f=c._parseSync({data:n.data,path:n.path,parent:d});if(f.status==="valid")return f;f.status==="dirty"&&!s&&(s={result:f,ctx:d}),d.common.issues.length&&o.push(d.common.issues)}if(s)return n.common.issues.push(...s.ctx.common.issues),s.result;const a=o.map(c=>new oa(c));return Ae(n,{code:ve.invalid_union,unionErrors:a}),mt}}get options(){return this._def.options}}L0.create=(e,t)=>new L0({options:e,typeName:_t.ZodUnion,...kt(t)});const Ao=e=>e instanceof w2?Ao(e.schema):e instanceof ru?Ao(e.innerType()):e instanceof $0?[e.value]:e instanceof nu?e.options:e instanceof b2?Vt.objectValues(e.enum):e instanceof F0?Ao(e._def.innerType):e instanceof g2?[void 0]:e instanceof y2?[null]:e instanceof Ko?[void 0,...Ao(e.unwrap())]:e instanceof iu?[null,...Ao(e.unwrap())]:e instanceof Sj||e instanceof z0?Ao(e.unwrap()):e instanceof U0?Ao(e._def.innerType):[];class xT extends Bt{_parse(t){const{ctx:n}=this._processInputParams(t);
vendor: 4,138 bytes, line 215
215if(n.parsedType!==$e.object)return Ae(n,{code:ve.invalid_type,expected:$e.object,received:n.parsedType}),mt;const r=this.discriminator,i=n.data[r],s=this.optionsMap.get(i);return s?n.common.async?s._parseAsync({data:n.data,path:n.path,parent:n}):s._parseSync({data:n.data,path:n.path,parent:n}):(Ae(n,{code:ve.invalid_union_discriminator,options:Array.from(this.optionsMap.keys()),path:[r]}),mt)}get discriminator(){return this._def.discriminator}get options(){return this._def.options}get optionsMap(){return this._def.optionsMap}static create(t,n,r){const i=new Map;for(const s of n){const o=Ao(s.shape[t]);if(!o.length)throw new Error(`A discriminator value for key \`${t}\` could not be extracted from all schema options`);for(const a of o){if(i.has(a))throw new Error(`Discriminator property ${String(t)} has duplicate value ${String(a)}`);i.set(a,s)}}return new xT({typeName:_t.ZodDiscriminatedUnion,discriminator:t,options:n,optionsMap:i,...kt(r)})}}function _2(e,t){const n=nl(e),r=nl(t);if(e===t)return{valid:!0,data:e};if(n===$e.object&&r===$e.object){const i=Vt.objectKeys(t),s=Vt.objectKeys(e).filter(a=>i.indexOf(a)!==-1),o={...e,...t};for(const a of s){const c=_2(e[a],t[a]);if(!c.valid)return{valid:!1};o[a]=c.data}return{valid:!0,data:o}}else if(n===$e.array&&r===$e.array){if(e.length!==t.length)return{valid:!1};const i=[];for(let s=0;s<e.length;s++){const o=e[s],a=t[s],c=_2(o,a);if(!c.valid)return{valid:!1};i.push(c.data)}return{valid:!0,data:i}}else return n===$e.date&&r===$e.date&&+e==+t?{valid:!0,data:e}:{valid:!1}}class N0 extends Bt{_parse(t){const{status:n,ctx:r}=this._processInputParams(t),i=(s,o)=>{if(c4(s)||c4(o))return mt;const a=_2(s.value,o.value);return a.valid?((u4(s)||u4(o))&&n.dirty(),{status:n.value,value:a.data}):(Ae(r,{code:ve.invalid_intersection_types}),mt)};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(([s,o])=>i(s,o)):i(this._def.left._parseSync({data:r.data,path:r.path,parent:r}),this._def.right._parseSync({data:r.data,path:r.path,parent:r}))}}N0.create=(e,t,n)=>new N0({left:e,right:t,typeName:_t.ZodIntersection,...kt(n)});class tu extends Bt{_parse(t){const{status:n,ctx:r}=this._processInputParams(t);if(r.parsedType!==$e.array)return Ae(r,{code:ve.invalid_type,expected:$e.array,received:r.parsedType}),mt;if(r.data.length<this._def.items.length)return Ae(r,{code:ve.too_small,minimum:this._def.items.length,inclusive:!0,exact:!1,type:"array"}),mt;!this._def.rest&&r.data.length>this._def.items.length&&(Ae(r,{code:ve.too_big,maximum:this._def.items.length,inclusive:!0,exact:!1,type:"array"}),n.dirty());const s=[...r.data].map((o,a)=>{const c=this._def.items[a]||this._def.rest;return c?c._parse(new xl(r,o,r.path,a)):null}).filter(o=>!!o);return r.common.async?Promise.all(s).then(o=>Oi.mergeArray(n,o)):Oi.mergeArray(n,s)}get items(){return this._def.items}rest(t){return new tu({...this._def,rest:t})}}tu.create=(e,t)=>{if(!Array.isArray(e))throw new Error("You must pass an array of schemas to z.tuple([ ... ])");return new tu({items:e,typeName:_t.ZodTuple,rest:null,...kt(t)})};class m4 extends Bt{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!==$e.map)return Ae(r,{code:ve.invalid_type,expected:$e.map,received:r.parsedType}),mt;const i=this._def.keyType,s=this._def.valueType,o=[...r.data.entries()].map(([a,c],d)=>({key:i._parse(new xl(r,a,r.path,[d,"key"])),value:s._parse(new xl(r,c,r.path,[d,"value"]))}));if(r.common.async){const a=new Map;return Promise.resolve().then(async()=>{for(const c of o){const d=await c.key,f=await c.value;if(d.status==="aborted"||f.status==="aborted")return mt;(d.status==="dirty"||f.status==="dirty")&&n.dirty(),a.set(d.value,f.value)}return{status:n.value,value:a}})}else{const a=new Map;for(const c of o){const d=c.key,f=c.value;if(d.status==="aborted"||f.status==="aborted")return mt;(d.status==="dirty"||f.status==="dirty")&&n.dirty(),a.set(d.value,f.value)}return{status:n.value,value:a}}}}
vendor: 5,422 bytes, line 215
215m4.create=(e,t,n)=>new m4({valueType:t,keyType:e,typeName:_t.ZodMap,...kt(n)});class Jp extends Bt{_parse(t){const{status:n,ctx:r}=this._processInputParams(t);if(r.parsedType!==$e.set)return Ae(r,{code:ve.invalid_type,expected:$e.set,received:r.parsedType}),mt;const i=this._def;i.minSize!==null&&r.data.size<i.minSize.value&&(Ae(r,{code:ve.too_small,minimum:i.minSize.value,type:"set",inclusive:!0,exact:!1,message:i.minSize.message}),n.dirty()),i.maxSize!==null&&r.data.size>i.maxSize.value&&(Ae(r,{code:ve.too_big,maximum:i.maxSize.value,type:"set",inclusive:!0,exact:!1,message:i.maxSize.message}),n.dirty());const s=this._def.valueType;function o(c){const d=new Set;for(const f of c){if(f.status==="aborted")return mt;f.status==="dirty"&&n.dirty(),d.add(f.value)}return{status:n.value,value:d}}const a=[...r.data.values()].map((c,d)=>s._parse(new xl(r,c,r.path,d)));return r.common.async?Promise.all(a).then(c=>o(c)):o(a)}min(t,n){return new Jp({...this._def,minSize:{value:t,message:Ke.toString(n)}})}max(t,n){return new Jp({...this._def,maxSize:{value:t,message:Ke.toString(n)}})}size(t,n){return this.min(t,n).max(t,n)}nonempty(t){return this.min(1,t)}}Jp.create=(e,t)=>new Jp({valueType:e,minSize:null,maxSize:null,typeName:_t.ZodSet,...kt(t)});class w2 extends Bt{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})}}w2.create=(e,t)=>new w2({getter:e,typeName:_t.ZodLazy,...kt(t)});class $0 extends Bt{_parse(t){if(t.data!==this._def.value){const n=this._getOrReturnCtx(t);return Ae(n,{received:n.data,code:ve.invalid_literal,expected:this._def.value}),mt}return{status:"valid",value:t.data}}get value(){return this._def.value}}$0.create=(e,t)=>new $0({value:e,typeName:_t.ZodLiteral,...kt(t)});function bj(e,t){return new nu({values:e,typeName:_t.ZodEnum,...kt(t)})}class nu extends Bt{_parse(t){if(typeof t.data!="string"){const n=this._getOrReturnCtx(t),r=this._def.values;return Ae(n,{expected:Vt.joinValues(r),received:n.parsedType,code:ve.invalid_type}),mt}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 Ae(n,{received:n.data,code:ve.invalid_enum_value,options:r}),mt}return os(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 nu.create(t,{...this._def,...n})}exclude(t,n=this._def){return nu.create(this.options.filter(r=>!t.includes(r)),{...this._def,...n})}}nu.create=bj;class b2 extends Bt{_parse(t){const n=Vt.getValidEnumValues(this._def.values),r=this._getOrReturnCtx(t);if(r.parsedType!==$e.string&&r.parsedType!==$e.number){const i=Vt.objectValues(n);return Ae(r,{expected:Vt.joinValues(i),received:r.parsedType,code:ve.invalid_type}),mt}if(this._cache||(this._cache=new Set(Vt.getValidEnumValues(this._def.values))),!this._cache.has(t.data)){const i=Vt.objectValues(n);return Ae(r,{received:r.data,code:ve.invalid_enum_value,options:i}),mt}return os(t.data)}get enum(){return this._def.values}}b2.create=(e,t)=>new b2({values:e,typeName:_t.ZodNativeEnum,...kt(t)});class j0 extends Bt{unwrap(){return this._def.type}_parse(t){const{ctx:n}=this._processInputParams(t);if(n.parsedType!==$e.promise&&n.common.async===!1)return Ae(n,{code:ve.invalid_type,expected:$e.promise,received:n.parsedType}),mt;const r=n.parsedType===$e.promise?n.data:Promise.resolve(n.data);return os(r.then(i=>this._def.type.parseAsync(i,{path:n.path,errorMap:n.common.contextualErrorMap})))}}j0.create=(e,t)=>new j0({type:e,typeName:_t.ZodPromise,...kt(t)});class ru extends Bt{innerType(){return this._def.schema}sourceType(){return this._def.schema._def.typeName===_t.ZodEffects?this._def.schema.sourceType():this._def.schema}_parse(t){const{status:n,ctx:r}=this._processInputParams(t),i=this._def.effect||null,s={addIssue:o=>{Ae(r,o),o.fatal?n.abort():n.dirty()},get path(){return r.path}};if(s.addIssue=s.addIssue.bind(s),i.type==="preprocess"){const o=i.transform(r.data,s);if(r.common.async)return Promise.resolve(o).then(async a=>{if(n.value==="aborted")return mt;const c=await this._def.schema._parseAsync({data:a,path:r.path,parent:r});return c.status==="aborted"?mt:c.status==="dirty"||n.value==="dirty"?tp(c.value):c});{if(n.value==="aborted")return mt;const a=this._def.schema._parseSync({data:o,path:r.path,parent:r});return a.status==="aborted"?mt:a.status==="dirty"||n.value==="dirty"?tp(a.value):a}}if(i.type==="refinement"){const o=a=>{const c=i.refinement(a,s);if(r.common.async)return Promise.resolve(c);if(c 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"?mt:(a.status==="dirty"&&n.dirty(),o(a.value),{status:n.value,value:a.value})}else return this._def.schema._parseAsync({data:r.data,path:r.path,parent:r}).then(a=>a.status==="aborted"?mt:(a.status==="dirty"&&n.dirty(),o(a.value).then(()=>({status:n.value,value:a.value}))))}if(i.type==="transform")if(r.common.async===!1){const o=this._def.schema._parseSync({data:r.data,path:r.path,parent:r});
215if(!nf(o))return mt;const a=i.transform(o.value,s);if(a instanceof Promise)throw new Error("Asynchronous transform encountered during synchronous parse operation. Use .parseAsync instead.");return{status:n.value,value:a}}else return this._def.schema._parseAsync({data:r.data,path:r.path,parent:r}).then(o=>nf(o)?Promise.resolve(i.transform(o.value,s)).then(a=>({status:n.value,value:a})):mt);Vt.assertNever(i)}}ru.create=(e,t,n)=>new ru({schema:e,typeName:_t.ZodEffects,effect:t,...kt(n)});ru.createWithPreprocess=(e,t,n)=>new ru({schema:t,effect:{type:"preprocess",transform:e},typeName:_t.ZodEffects,...kt(n)});class Ko extends Bt{_parse(t){return this._getType(t)===$e.undefined?os(void 0):this._def.innerType._parse(t)}unwrap(){return this._def.innerType}}Ko.create=(e,t)=>new Ko({innerType:e,typeName:_t.ZodOptional,...kt(t)});class iu extends Bt{_parse(t){return this._getType(t)===$e.null?os(null):this._def.innerType._parse(t)}unwrap(){return this._def.innerType}}iu.create=(e,t)=>new iu({innerType:e,typeName:_t.ZodNullable,...kt(t)});class F0 extends Bt{_parse(t){const{ctx:n}=this._processInputParams(t);let r=n.data;return n.parsedType===$e.undefined&&(r=this._def.defaultValue()),this._def.innerType._parse({data:r,path:n.path,parent:n})}removeDefault(){return this._def.innerType}}F0.create=(e,t)=>new F0({innerType:e,typeName:_t.ZodDefault,defaultValue:typeof t.default=="function"?t.default:()=>t.default,...kt(t)});class U0 extends Bt{_parse(t){const{ctx:n}=this._processInputParams(t),r={...n,common:{...n.common,issues:[]}},i=this._def.innerType._parse({data:r.data,path:r.path,parent:{...r}});return M0(i)?i.then(s=>({status:"valid",value:s.status==="valid"?s.value:this._def.catchValue({get error(){return new oa(r.common.issues)},input:r.data})})):{status:"valid",value:i.status==="valid"?i.value:this._def.catchValue({get error(){return new oa(r.common.issues)},input:r.data})}}removeCatch(){return this._def.innerType}}U0.create=(e,t)=>new U0({innerType:e,typeName:_t.ZodCatch,catchValue:typeof t.catch=="function"?t.catch:()=>t.catch,...kt(t)});class g4 extends Bt{_parse(t){if(this._getType(t)!==$e.nan){const r=this._getOrReturnCtx(t);return Ae(r,{code:ve.invalid_type,expected:$e.nan,received:r.parsedType}),mt}return{status:"valid",value:t.data}}}g4.create=e=>new g4({typeName:_t.ZodNaN,...kt(e)});class Sj extends Bt{_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 CT extends Bt{_parse(t){const{status:n,ctx:r}=this._processInputParams(t);if(r.common.async)return(async()=>{const s=await this._def.in._parseAsync({data:r.data,path:r.path,parent:r});return s.status==="aborted"?mt:s.status==="dirty"?(n.dirty(),tp(s.value)):this._def.out._parseAsync({data:s.value,path:r.path,parent:r})})();{const i=this._def.in._parseSync({data:r.data,path:r.path,parent:r});return i.status==="aborted"?mt:i.status==="dirty"?(n.dirty(),{status:"dirty",value:i.value}):this._def.out._parseSync({data:i.value,path:r.path,parent:r})}}static create(t,n){return new CT({in:t,out:n,typeName:_t.ZodPipeline})}}class z0 extends Bt{_parse(t){const n=this._def.innerType._parse(t),r=i=>(nf(i)&&(i.value=Object.freeze(i.value)),i);return M0(n)?n.then(i=>r(i)):r(n)}unwrap(){return this._def.innerType}}z0.create=(e,t)=>new z0({innerType:e,typeName:_t.ZodReadonly,...kt(t)});var _t;(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"})(_t||(_t={}));const J=Fo.create,se=Qc.create;eu.create;const Ee=D0.create;rf.create;const Ej=v2.create;Cl.create;const Et=Qs.create,re=qn.create,_u=L0.create,Tpe=xT.create;N0.create;const xj=tu.create,Nt=$0.create,s1=nu.create;j0.create;Ko.create;iu.create;const Zp={string:(e=>Fo.create({...e,coerce:!0})),number:(e=>Qc.create({...e,coerce:!0})),boolean:(e=>D0.create({...e,coerce:!0})),bigint:(e=>eu.create({...e,coerce:!0})),date:(e=>rf.create({...e,coerce:!0}))};function Cj(e,t){return function(){return e.apply(t,arguments)}}const{toString:Rpe}=Object.prototype,{getPrototypeOf:kT}=Object,{iterator:o1,toStringTag:kj}=Symbol,a1=(e=>t=>{const n=Rpe.call(t);return e[n]||(e[n]=n.slice(8,-1).toLowerCase())})(Object.create(null)),Is=e=>(e=e.toLowerCase(),t=>a1(t)===e),l1=e=>t=>typeof t===e,{isArray:Of}=Array,sf=l1("undefined");function Km(e){return e!==null&&!sf(e)&&e.constructor!==null&&!sf(e.constructor)&&di(e.constructor.isBuffer)&&e.constructor.isBuffer(e)}const Tj=Is("ArrayBuffer");function Ppe(e){let t;return typeof ArrayBuffer<"u"&&ArrayBuffer.isView?t=ArrayBuffer.isView(e):t=e&&e.buffer&&Tj(e.buffer),t}const Ope=l1("string"),di=l1("function"),Rj=l1("number"),Gm=e=>e!==null&&typeof e=="object",Ape=e=>e===!0||e===!1,Lv=e=>{if(a1(e)!=="object")return!1;const t=kT(e);
vendor: 11,421 bytes, line 215
215return(t===null||t===Object.prototype||Object.getPrototypeOf(t)===null)&&!(kj in e)&&!(o1 in e)},Ipe=e=>{if(!Gm(e)||Km(e))return!1;try{return Object.keys(e).length===0&&Object.getPrototypeOf(e)===Object.prototype}catch{return!1}},Mpe=Is("Date"),Dpe=Is("File"),Lpe=Is("Blob"),Npe=Is("FileList"),$pe=e=>Gm(e)&&di(e.pipe),jpe=e=>{let t;return e&&(typeof FormData=="function"&&e instanceof FormData||di(e.append)&&((t=a1(e))==="formdata"||t==="object"&&di(e.toString)&&e.toString()==="[object FormData]"))},Fpe=Is("URLSearchParams"),[Upe,zpe,Bpe,Hpe]=["ReadableStream","Request","Response","Headers"].map(Is),Vpe=e=>e.trim?e.trim():e.replace(/^[\s\uFEFF\xA0]+|[\s\uFEFF\xA0]+$/g,"");function Ym(e,t,{allOwnKeys:n=!1}={}){if(e===null||typeof e>"u")return;let r,i;if(typeof e!="object"&&(e=[e]),Of(e))for(r=0,i=e.length;r<i;r++)t.call(null,e[r],r,e);else{if(Km(e))return;const s=n?Object.getOwnPropertyNames(e):Object.keys(e),o=s.length;let a;for(r=0;r<o;r++)a=s[r],t.call(null,e[a],a,e)}}function Pj(e,t){if(Km(e))return null;t=t.toLowerCase();const n=Object.keys(e);let r=n.length,i;for(;r-- >0;)if(i=n[r],t===i.toLowerCase())return i;return null}const Ic=typeof globalThis<"u"?globalThis:typeof self<"u"?self:typeof window<"u"?window:global,Oj=e=>!sf(e)&&e!==Ic;function S2(){const{caseless:e,skipUndefined:t}=Oj(this)&&this||{},n={},r=(i,s)=>{if(s==="__proto__"||s==="constructor"||s==="prototype")return;const o=e&&Pj(n,s)||s;Lv(n[o])&&Lv(i)?n[o]=S2(n[o],i):Lv(i)?n[o]=S2({},i):Of(i)?n[o]=i.slice():(!t||!sf(i))&&(n[o]=i)};for(let i=0,s=arguments.length;i<s;i++)arguments[i]&&Ym(arguments[i],r);return n}const Wpe=(e,t,n,{allOwnKeys:r}={})=>(Ym(t,(i,s)=>{n&&di(i)?Object.defineProperty(e,s,{value:Cj(i,n),writable:!0,enumerable:!0,configurable:!0}):Object.defineProperty(e,s,{value:i,writable:!0,enumerable:!0,configurable:!0})},{allOwnKeys:r}),e),qpe=e=>(e.charCodeAt(0)===65279&&(e=e.slice(1)),e),Kpe=(e,t,n,r)=>{e.prototype=Object.create(t.prototype,r),Object.defineProperty(e.prototype,"constructor",{value:e,writable:!0,enumerable:!1,configurable:!0}),Object.defineProperty(e,"super",{value:t.prototype}),n&&Object.assign(e.prototype,n)},Gpe=(e,t,n,r)=>{let i,s,o;const a={};if(t=t||{},e==null)return t;do{for(i=Object.getOwnPropertyNames(e),s=i.length;s-- >0;)o=i[s],(!r||r(o,e,t))&&!a[o]&&(t[o]=e[o],a[o]=!0);e=n!==!1&&kT(e)}while(e&&(!n||n(e,t))&&e!==Object.prototype);return t},Ype=(e,t,n)=>{e=String(e),(n===void 0||n>e.length)&&(n=e.length),n-=t.length;const r=e.indexOf(t,n);return r!==-1&&r===n},Jpe=e=>{if(!e)return null;if(Of(e))return e;let t=e.length;if(!Rj(t))return null;const n=new Array(t);for(;t-- >0;)n[t]=e[t];return n},Zpe=(e=>t=>e&&t instanceof e)(typeof Uint8Array<"u"&&kT(Uint8Array)),Xpe=(e,t)=>{const r=(e&&e[o1]).call(e);let i;for(;(i=r.next())&&!i.done;){const s=i.value;t.call(e,s[0],s[1])}},Qpe=(e,t)=>{let n;const r=[];for(;(n=e.exec(t))!==null;)r.push(n);return r},eme=Is("HTMLFormElement"),tme=e=>e.toLowerCase().replace(/[-_\s]([a-z\d])(\w*)/g,function(n,r,i){return r.toUpperCase()+i}),y4=(({hasOwnProperty:e})=>(t,n)=>e.call(t,n))(Object.prototype),nme=Is("RegExp"),Aj=(e,t)=>{const n=Object.getOwnPropertyDescriptors(e),r={};Ym(n,(i,s)=>{let o;(o=t(i,s,e))!==!1&&(r[s]=o||i)}),Object.defineProperties(e,r)},rme=e=>{Aj(e,(t,n)=>{if(di(e)&&["arguments","caller","callee"].indexOf(n)!==-1)return!1;const r=e[n];if(di(r)){if(t.enumerable=!1,"writable"in t){t.writable=!1;return}t.set||(t.set=()=>{throw Error("Can not rewrite read-only method '"+n+"'")})}})},ime=(e,t)=>{const n={},r=i=>{i.forEach(s=>{n[s]=!0})};return Of(e)?r(e):r(String(e).split(t)),n},sme=()=>{},ome=(e,t)=>e!=null&&Number.isFinite(e=+e)?e:t;function ame(e){return!!(e&&di(e.append)&&e[kj]==="FormData"&&e[o1])}const lme=e=>{const t=new Array(10),n=(r,i)=>{if(Gm(r)){if(t.indexOf(r)>=0)return;if(Km(r))return r;if(!("toJSON"in r)){t[i]=r;const s=Of(r)?[]:{};return Ym(r,(o,a)=>{const c=n(o,i+1);!sf(c)&&(s[a]=c)}),t[i]=void 0,s}}return r};return n(e,0)},cme=Is("AsyncFunction"),ume=e=>e&&(Gm(e)||di(e))&&di(e.then)&&di(e.catch),Ij=((e,t)=>e?setImmediate:t?((n,r)=>(Ic.addEventListener("message",({source:i,data:s})=>{i===Ic&&s===n&&r.length&&r.shift()()},!1),i=>{r.push(i),Ic.postMessage(n,"*")}))(`axios@${Math.random()}`,[]):n=>setTimeout(n))(typeof setImmediate=="function",di(Ic.postMessage)),dme=typeof queueMicrotask<"u"?queueMicrotask.bind(Ic):typeof process<"u"&&process.nextTick||Ij,fme=e=>e!=null&&di(e[o1]),de={isArray:Of,isArrayBuffer:Tj,isBuffer:Km,isFormData:jpe,isArrayBufferView:Ppe,isString:Ope,isNumber:Rj,isBoolean:Ape,isObject:Gm,isPlainObject:Lv,isEmptyObject:Ipe,isReadableStream:Upe,isRequest:zpe,isResponse:Bpe,isHeaders:Hpe,isUndefined:sf,isDate:Mpe,isFile:Dpe,isBlob:Lpe,isRegExp:nme,isFunction:di,isStream:$pe,isURLSearchParams:Fpe,isTypedArray:Zpe,isFileList:Npe,forEach:Ym,merge:S2,extend:Wpe,trim:Vpe,stripBOM:qpe,inherits:Kpe,toFlatObject:Gpe,kindOf:a1,kindOfTest:Is,endsWith:Ype,toArray:Jpe,forEachEntry:Xpe,matchAll:Qpe,isHTMLForm:eme,hasOwnProperty:y4,hasOwnProp:y4,reduceDescriptors:Aj,freezeMethods:rme,toObjectSet:ime,toCamelCase:tme,noop:sme,toFiniteNumber:ome,findKey:Pj,global:Ic,isContextDefined:Oj,isSpecCompliantForm:ame,toJSONObject:lme,isAsyncFn:cme,isThenable:ume,setImmediate:Ij,asap:dme,isIterable:fme};let lt=class Mj extends Error{static from(t,n,r,i,s,o){const a=new Mj(t.message,n||t.code,r,i,s);return a.cause=t,a.name=t.name,o&&Object.assign(a,o),a}constructor(t,n,r,i,s){super(t),this.name="AxiosError",this.isAxiosError=!0,n&&(this.code=n),r&&(this.config=r),i&&(this.request=i),s&&(this.response=s,this.status=s.status)}toJSON(){return{message:this.message,name:this.name,description:this.description,number:this.number,fileName:this.fileName,lineNumber:this.lineNumber,columnNumber:this.columnNumber,stack:this.stack,config:de.toJSONObject(this.config),code:this.code,status:this.status}}};lt.ERR_BAD_OPTION_VALUE="ERR_BAD_OPTION_VALUE";lt.ERR_BAD_OPTION="ERR_BAD_OPTION";lt.ECONNABORTED="ECONNABORTED";lt.ETIMEDOUT="ETIMEDOUT";lt.ERR_NETWORK="ERR_NETWORK";lt.ERR_FR_TOO_MANY_REDIRECTS="ERR_FR_TOO_MANY_REDIRECTS";lt.ERR_DEPRECATED="ERR_DEPRECATED";lt.ERR_BAD_RESPONSE="ERR_BAD_RESPONSE";lt.ERR_BAD_REQUEST="ERR_BAD_REQUEST";lt.ERR_CANCELED="ERR_CANCELED";lt.ERR_NOT_SUPPORT="ERR_NOT_SUPPORT";lt.ERR_INVALID_URL="ERR_INVALID_URL";const hme=null;function E2(e){return de.isPlainObject(e)||de.isArray(e)}function Dj(e){return de.endsWith(e,"[]")?e.slice(0,-2):e}function v4(e,t,n){return e?e.concat(t).map(function(i,s){return i=Dj(i),!n&&s?"["+i+"]":i}).join(n?".":""):t}function pme(e){return de.isArray(e)&&!e.some(E2)}const mme=de.toFlatObject(de,{},null,function(t){return/^is[A-Z]/.test(t)});function c1(e,t,n){if(!de.isObject(e))throw new TypeError("target must be an object");t=t||new FormData,n=de.toFlatObject(n,{metaTokens:!0,dots:!1,indexes:!1},!1,function(_,b){return!de.isUndefined(b[_])});const r=n.metaTokens,i=n.visitor||f,s=n.dots,o=n.indexes,c=(n.Blob||typeof Blob<"u"&&Blob)&&de.isSpecCompliantForm(t);if(!de.isFunction(i))throw new TypeError("visitor must be a function");function d(w){if(w===null)return"";if(de.isDate(w))return w.toISOString();if(de.isBoolean(w))return w.toString();if(!c&&de.isBlob(w))throw new lt("Blob is not supported. Use a Buffer instead.");return de.isArrayBuffer(w)||de.isTypedArray(w)?c&&typeof Blob=="function"?new Blob([w]):Buffer.from(w):w}function f(w,_,b){let C=w;if(w&&!b&&typeof w=="object"){if(de.endsWith(_,"{}"))_=r?_:_.slice(0,-2),w=JSON.stringify(w);else if(de.isArray(w)&&pme(w)||(de.isFileList(w)||de.endsWith(_,"[]"))&&(C=de.toArray(w)))return _=Dj(_),C.forEach(function(D,F){!(de.isUndefined(D)||D===null)&&t.append(o===!0?v4([_],F,s):o===null?_:_+"[]",d(D))}),!1}return E2(w)?!0:(t.append(v4(b,_,s),d(w)),!1)}const p=[],m=Object.assign(mme,{defaultVisitor:f,convertValue:d,isVisitable:E2});function v(w,_){if(!de.isUndefined(w)){if(p.indexOf(w)!==-1)throw Error("Circular reference detected in "+_.join("."));p.push(w),de.forEach(w,function(C,P){(!(de.isUndefined(C)||C===null)&&i.call(t,C,de.isString(P)?P.trim():P,_,m))===!0&&v(C,_?_.concat(P):[P])}),p.pop()}}if(!de.isObject(e))throw new TypeError("data must be an object");return v(e),t}function _4(e){const t={"!":"%21","'":"%27","(":"%28",")":"%29","~":"%7E","%20":"+","%00":"\0"};return encodeURIComponent(e).replace(/[!'()~]|%20|%00/g,function(r){return t[r]})}function TT(e,t){this._pairs=[],e&&c1(e,this,t)}const Lj=TT.prototype;Lj.append=function(t,n){this._pairs.push([t,n])};Lj.toString=function(t){const n=t?function(r){return t.call(this,r,_4)}:_4;return this._pairs.map(function(i){return n(i[0])+"="+n(i[1])},"").join("&")};function gme(e){return encodeURIComponent(e).replace(/%3A/gi,":").replace(/%24/g,"$").replace(/%2C/gi,",").replace(/%20/g,"+")}function Nj(e,t,n){if(!t)return e;const r=n&&n.encode||gme,i=de.isFunction(n)?{serialize:n}:n,s=i&&i.serialize;let o;if(s?o=s(t,i):o=de.isURLSearchParams(t)?t.toString():new TT(t,i).toString(r),o){const a=e.indexOf("#");a!==-1&&(e=e.slice(0,a)),e+=(e.indexOf("?")===-1?"?":"&")+o}return e}class w4{constructor(){this.handlers=[]}use(t,n,r){return this.handlers.push({fulfilled:t,rejected:n,synchronous:r?r.synchronous:!1,runWhen:r?r.runWhen:null}),this.handlers.length-1}eject(t){this.handlers[t]&&(this.handlers[t]=null)}clear(){this.handlers&&(this.handlers=[])}forEach(t){de.forEach(this.handlers,function(r){r!==null&&t(r)})}}const RT={silentJSONParsing:!0,forcedJSONParsing:!0,clarifyTimeoutError:!1,legacyInterceptorReqResOrdering:!0},yme=typeof URLSearchParams<"u"?URLSearchParams:TT,vme=typeof FormData<"u"?FormData:null,_me=typeof Blob<"u"?Blob:null,wme={isBrowser:!0,classes:{URLSearchParams:yme,FormData:vme,Blob:_me},protocols:["http","https","file","blob","url","data"]},PT=typeof window<"u"&&typeof document<"u",x2=typeof navigator=="object"&&navigator||void 0,bme=PT&&(!x2||["ReactNative","NativeScript","NS"].indexOf(x2.product)<0),Sme=typeof WorkerGlobalScope<"u"&&self instanceof WorkerGlobalScope&&typeof self.importScripts=="function",Eme=PT&&window.location.href||"http://localhost",xme=Object.freeze(Object.defineProperty({__proto__:null,hasBrowserEnv:PT,hasStandardBrowserEnv:bme,hasStandardBrowserWebWorkerEnv:Sme,navigator:x2,origin:Eme},Symbol.toStringTag,{value:"Module"})),Mr={...xme,...wme};function Cme(e,t){return c1(e,new Mr.classes.URLSearchParams,{visitor:function(n,r,i,s){return Mr.isNode&&de.isBuffer(n)?(this.append(r,n.toString("base64")),!1):s.defaultVisitor.apply(this,arguments)},...t})}function kme(e){return de.matchAll(/\w+|\[(\w*)]/g,e).map(t=>t[0]==="[]"?"":t[1]||t[0])}function Tme(e){const t={},n=Object.keys(e);let r;const i=n.length;let s;for(r=0;r<i;r++)s=n[r],t[s]=e[s];return t}function $j(e){function t(n,r,i,s){let o=n[s++];if(o==="__proto__")return!0;const a=Number.isFinite(+o),c=s>=n.length;return o=!o&&de.isArray(i)?i.length:o,c?(de.hasOwnProp(i,o)?i[o]=[i[o],r]:i[o]=r,!a):((!i[o]||!de.isObject(i[o]))&&(i[o]=[]),t(n,r,i[o],s)&&de.isArray(i[o])&&(i[o]=Tme(i[o])),!a)}if(de.isFormData(e)&&de.isFunction(e.entries)){const n={};return de.forEachEntry(e,(r,i)=>{t(kme(r),i,n,0)}),n}return null}function Rme(e,t,n){if(de.isString(e))try{return(t||JSON.parse)(e),de.trim(e)}catch(r){if(r.name!=="SyntaxError")throw r}return(n||JSON.stringify)(e)}const Jm={transitional:RT,adapter:["xhr","http","fetch"],transformRequest:[function(t,n){const r=n.getContentType()||"",i=r.indexOf("application/json")>-1,s=de.isObject(t);
vendor: 4,903 bytes, lines 215-217
215if(s&&de.isHTMLForm(t)&&(t=new FormData(t)),de.isFormData(t))return i?JSON.stringify($j(t)):t;if(de.isArrayBuffer(t)||de.isBuffer(t)||de.isStream(t)||de.isFile(t)||de.isBlob(t)||de.isReadableStream(t))return t;if(de.isArrayBufferView(t))return t.buffer;if(de.isURLSearchParams(t))return n.setContentType("application/x-www-form-urlencoded;charset=utf-8",!1),t.toString();let a;if(s){if(r.indexOf("application/x-www-form-urlencoded")>-1)return Cme(t,this.formSerializer).toString();if((a=de.isFileList(t))||r.indexOf("multipart/form-data")>-1){const c=this.env&&this.env.FormData;return c1(a?{"files[]":t}:t,c&&new c,this.formSerializer)}}return s||i?(n.setContentType("application/json",!1),Rme(t)):t}],transformResponse:[function(t){const n=this.transitional||Jm.transitional,r=n&&n.forcedJSONParsing,i=this.responseType==="json";if(de.isResponse(t)||de.isReadableStream(t))return t;if(t&&de.isString(t)&&(r&&!this.responseType||i)){const o=!(n&&n.silentJSONParsing)&&i;try{return JSON.parse(t,this.parseReviver)}catch(a){if(o)throw a.name==="SyntaxError"?lt.from(a,lt.ERR_BAD_RESPONSE,this,null,this.response):a}}return t}],timeout:0,xsrfCookieName:"XSRF-TOKEN",xsrfHeaderName:"X-XSRF-TOKEN",maxContentLength:-1,maxBodyLength:-1,env:{FormData:Mr.classes.FormData,Blob:Mr.classes.Blob},validateStatus:function(t){return t>=200&&t<300},headers:{common:{Accept:"application/json, text/plain, */*","Content-Type":void 0}}};de.forEach(["delete","get","head","post","put","patch"],e=>{Jm.headers[e]={}});const Pme=de.toObjectSet(["age","authorization","content-length","content-type","etag","expires","from","host","if-modified-since","if-unmodified-since","last-modified","location","max-forwards","proxy-authorization","referer","retry-after","user-agent"]),Ome=e=>{const t={};let n,r,i;return e&&e.split(` 216`).forEach(function(o){i=o.indexOf(":"),n=o.substring(0,i).trim().toLowerCase(),r=o.substring(i+1).trim(),!(!n||t[n]&&Pme[n])&&(n==="set-cookie"?t[n]?t[n].push(r):t[n]=[r]:t[n]=t[n]?t[n]+", "+r:r)}),t},b4=Symbol("internals");function Nh(e){return e&&String(e).trim().toLowerCase()}function Nv(e){return e===!1||e==null?e:de.isArray(e)?e.map(Nv):String(e)}function Ame(e){const t=Object.create(null),n=/([^\s,;=]+)\s*(?:=\s*([^,;]+))?/g;let r;for(;r=n.exec(e);)t[r[1]]=r[2];return t}const Ime=e=>/^[-_a-zA-Z0-9^`|~,!#$%&'*+.]+$/.test(e.trim());function xS(e,t,n,r,i){if(de.isFunction(r))return r.call(this,t,n);if(i&&(t=n),!!de.isString(t)){if(de.isString(r))return t.indexOf(r)!==-1;if(de.isRegExp(r))return r.test(t)}}function Mme(e){return e.trim().toLowerCase().replace(/([a-z\d])(\w*)/g,(t,n,r)=>n.toUpperCase()+r)}function Dme(e,t){const n=de.toCamelCase(" "+t);["get","set","has"].forEach(r=>{Object.defineProperty(e,r+n,{value:function(i,s,o){return this[r].call(this,t,i,s,o)},configurable:!0})})}let fi=class{constructor(t){t&&this.set(t)}set(t,n,r){const i=this;function s(a,c,d){const f=Nh(c);if(!f)throw new Error("header name must be a non-empty string");const p=de.findKey(i,f);(!p||i[p]===void 0||d===!0||d===void 0&&i[p]!==!1)&&(i[p||c]=Nv(a))}const o=(a,c)=>de.forEach(a,(d,f)=>s(d,f,c));if(de.isPlainObject(t)||t instanceof this.constructor)o(t,n);else if(de.isString(t)&&(t=t.trim())&&!Ime(t))o(Ome(t),n);else if(de.isObject(t)&&de.isIterable(t)){let a={},c,d;for(const f of t){if(!de.isArray(f))throw TypeError("Object iterator must return a key-value pair");a[d=f[0]]=(c=a[d])?de.isArray(c)?[...c,f[1]]:[c,f[1]]:f[1]}o(a,n)}else t!=null&&s(n,t,r);return this}get(t,n){if(t=Nh(t),t){const r=de.findKey(this,t);if(r){const i=this[r];if(!n)return i;if(n===!0)return Ame(i);if(de.isFunction(n))return n.call(this,i,r);if(de.isRegExp(n))return n.exec(i);throw new TypeError("parser must be boolean|regexp|function")}}}has(t,n){if(t=Nh(t),t){const r=de.findKey(this,t);return!!(r&&this[r]!==void 0&&(!n||xS(this,this[r],r,n)))}return!1}delete(t,n){const r=this;let i=!1;function s(o){if(o=Nh(o),o){const a=de.findKey(r,o);a&&(!n||xS(r,r[a],a,n))&&(delete r[a],i=!0)}}return de.isArray(t)?t.forEach(s):s(t),i}clear(t){const n=Object.keys(this);let r=n.length,i=!1;for(;r--;){const s=n[r];(!t||xS(this,this[s],s,t,!0))&&(delete this[s],i=!0)}return i}normalize(t){const n=this,r={};return de.forEach(this,(i,s)=>{const o=de.findKey(r,s);if(o){n[o]=Nv(i),delete n[s];return}const a=t?Mme(s):String(s).trim();a!==s&&delete n[s],n[a]=Nv(i),r[a]=!0}),this}concat(...t){return this.constructor.concat(this,...t)}toJSON(t){const n=Object.create(null);return de.forEach(this,(r,i)=>{r!=null&&r!==!1&&(n[i]=t&&de.isArray(r)?r.join(", "):r)}),n}[Symbol.iterator](){return Object.entries(this.toJSON())[Symbol.iterator]()}toString(){return Object.entries(this.toJSON()).map(([t,n])=>t+": "+n).join(` 217`)}getSetCookie(){return this.get("set-cookie")||[]}get[Symbol.toStringTag](){return"AxiosHeaders"}static from(t){return t instanceof this?t:new this(t)}static concat(t,...n){const r=new this(t);
vendor: 13,307 bytes, lines 217-219
217return n.forEach(i=>r.set(i)),r}static accessor(t){const r=(this[b4]=this[b4]={accessors:{}}).accessors,i=this.prototype;function s(o){const a=Nh(o);r[a]||(Dme(i,o),r[a]=!0)}return de.isArray(t)?t.forEach(s):s(t),this}};fi.accessor(["Content-Type","Content-Length","Accept","Accept-Encoding","User-Agent","Authorization"]);de.reduceDescriptors(fi.prototype,({value:e},t)=>{let n=t[0].toUpperCase()+t.slice(1);return{get:()=>e,set(r){this[n]=r}}});de.freezeMethods(fi);function CS(e,t){const n=this||Jm,r=t||n,i=fi.from(r.headers);let s=r.data;return de.forEach(e,function(a){s=a.call(n,s,i.normalize(),t?t.status:void 0)}),i.normalize(),s}function jj(e){return!!(e&&e.__CANCEL__)}let Zm=class extends lt{constructor(t,n,r){super(t??"canceled",lt.ERR_CANCELED,n,r),this.name="CanceledError",this.__CANCEL__=!0}};function Fj(e,t,n){const r=n.config.validateStatus;!n.status||!r||r(n.status)?e(n):t(new lt("Request failed with status code "+n.status,[lt.ERR_BAD_REQUEST,lt.ERR_BAD_RESPONSE][Math.floor(n.status/100)-4],n.config,n.request,n))}function Lme(e){const t=/^([-+\w]{1,25})(:?\/\/|:)/.exec(e);return t&&t[1]||""}function Nme(e,t){e=e||10;const n=new Array(e),r=new Array(e);let i=0,s=0,o;return t=t!==void 0?t:1e3,function(c){const d=Date.now(),f=r[s];o||(o=d),n[i]=c,r[i]=d;let p=s,m=0;for(;p!==i;)m+=n[p++],p=p%e;if(i=(i+1)%e,i===s&&(s=(s+1)%e),d-o<t)return;const v=f&&d-f;return v?Math.round(m*1e3/v):void 0}}function $me(e,t){let n=0,r=1e3/t,i,s;const o=(d,f=Date.now())=>{n=f,i=null,s&&(clearTimeout(s),s=null),e(...d)};return[(...d)=>{const f=Date.now(),p=f-n;p>=r?o(d,f):(i=d,s||(s=setTimeout(()=>{s=null,o(i)},r-p)))},()=>i&&o(i)]}const B0=(e,t,n=3)=>{let r=0;const i=Nme(50,250);return $me(s=>{const o=s.loaded,a=s.lengthComputable?s.total:void 0,c=o-r,d=i(c),f=o<=a;r=o;const p={loaded:o,total:a,progress:a?o/a:void 0,bytes:c,rate:d||void 0,estimated:d&&a&&f?(a-o)/d:void 0,event:s,lengthComputable:a!=null,[t?"download":"upload"]:!0};e(p)},n)},S4=(e,t)=>{const n=e!=null;return[r=>t[0]({lengthComputable:n,total:e,loaded:r}),t[1]]},E4=e=>(...t)=>de.asap(()=>e(...t)),jme=Mr.hasStandardBrowserEnv?((e,t)=>n=>(n=new URL(n,Mr.origin),e.protocol===n.protocol&&e.host===n.host&&(t||e.port===n.port)))(new URL(Mr.origin),Mr.navigator&&/(msie|trident)/i.test(Mr.navigator.userAgent)):()=>!0,Fme=Mr.hasStandardBrowserEnv?{write(e,t,n,r,i,s,o){if(typeof document>"u")return;const a=[`${e}=${encodeURIComponent(t)}`];de.isNumber(n)&&a.push(`expires=${new Date(n).toUTCString()}`),de.isString(r)&&a.push(`path=${r}`),de.isString(i)&&a.push(`domain=${i}`),s===!0&&a.push("secure"),de.isString(o)&&a.push(`SameSite=${o}`),document.cookie=a.join("; ")},read(e){if(typeof document>"u")return null;const t=document.cookie.match(new RegExp("(?:^|; )"+e+"=([^;]*)"));return t?decodeURIComponent(t[1]):null},remove(e){this.write(e,"",Date.now()-864e5,"/")}}:{write(){},read(){return null},remove(){}};function Ume(e){return typeof e!="string"?!1:/^([a-z][a-z\d+\-.]*:)?\/\//i.test(e)}function zme(e,t){return t?e.replace(/\/?\/$/,"")+"/"+t.replace(/^\/+/,""):e}function Uj(e,t,n){let r=!Ume(t);return e&&(r||n==!1)?zme(e,t):t}const x4=e=>e instanceof fi?{...e}:e;function su(e,t){t=t||{};const n={};function r(d,f,p,m){return de.isPlainObject(d)&&de.isPlainObject(f)?de.merge.call({caseless:m},d,f):de.isPlainObject(f)?de.merge({},f):de.isArray(f)?f.slice():f}function i(d,f,p,m){if(de.isUndefined(f)){if(!de.isUndefined(d))return r(void 0,d,p,m)}else return r(d,f,p,m)}function s(d,f){if(!de.isUndefined(f))return r(void 0,f)}function o(d,f){if(de.isUndefined(f)){if(!de.isUndefined(d))return r(void 0,d)}else return r(void 0,f)}function a(d,f,p){if(p in t)return r(d,f);if(p in e)return r(void 0,d)}const c={url:s,method:s,data:s,baseURL:o,transformRequest:o,transformResponse:o,paramsSerializer:o,timeout:o,timeoutMessage:o,withCredentials:o,withXSRFToken:o,adapter:o,responseType:o,xsrfCookieName:o,xsrfHeaderName:o,onUploadProgress:o,onDownloadProgress:o,decompress:o,maxContentLength:o,maxBodyLength:o,beforeRedirect:o,transport:o,httpAgent:o,httpsAgent:o,cancelToken:o,socketPath:o,responseEncoding:o,validateStatus:a,headers:(d,f,p)=>i(x4(d),x4(f),p,!0)};return de.forEach(Object.keys({...e,...t}),function(f){if(f==="__proto__"||f==="constructor"||f==="prototype")return;const p=de.hasOwnProp(c,f)?c[f]:i,m=p(e[f],t[f],f);de.isUndefined(m)&&p!==a||(n[f]=m)}),n}const zj=e=>{const t=su({},e);let{data:n,withXSRFToken:r,xsrfHeaderName:i,xsrfCookieName:s,headers:o,auth:a}=t;if(t.headers=o=fi.from(o),t.url=Nj(Uj(t.baseURL,t.url,t.allowAbsoluteUrls),e.params,e.paramsSerializer),a&&o.set("Authorization","Basic "+btoa((a.username||"")+":"+(a.password?unescape(encodeURIComponent(a.password)):""))),de.isFormData(n)){if(Mr.hasStandardBrowserEnv||Mr.hasStandardBrowserWebWorkerEnv)o.setContentType(void 0);else if(de.isFunction(n.getHeaders)){const c=n.getHeaders(),d=["content-type","content-length"];Object.entries(c).forEach(([f,p])=>{d.includes(f.toLowerCase())&&o.set(f,p)})}}if(Mr.hasStandardBrowserEnv&&(r&&de.isFunction(r)&&(r=r(t)),r||r!==!1&&jme(t.url))){const c=i&&s&&Fme.read(s);c&&o.set(i,c)}return t},Bme=typeof XMLHttpRequest<"u",Hme=Bme&&function(e){return new Promise(function(n,r){const i=zj(e);let s=i.data;const o=fi.from(i.headers).normalize();let{responseType:a,onUploadProgress:c,onDownloadProgress:d}=i,f,p,m,v,w;function _(){v&&v(),w&&w(),i.cancelToken&&i.cancelToken.unsubscribe(f),i.signal&&i.signal.removeEventListener("abort",f)}let b=new XMLHttpRequest;b.open(i.method.toUpperCase(),i.url,!0),b.timeout=i.timeout;function C(){if(!b)return;const D=fi.from("getAllResponseHeaders"in b&&b.getAllResponseHeaders()),R={data:!a||a==="text"||a==="json"?b.responseText:b.response,status:b.status,statusText:b.statusText,headers:D,config:e,request:b};Fj(function(k){n(k),_()},function(k){r(k),_()},R),b=null}"onloadend"in b?b.onloadend=C:b.onreadystatechange=function(){!b||b.readyState!==4||b.status===0&&!(b.responseURL&&b.responseURL.indexOf("file:")===0)||setTimeout(C)},b.onabort=function(){b&&(r(new lt("Request aborted",lt.ECONNABORTED,e,b)),b=null)},b.onerror=function(F){const R=F&&F.message?F.message:"Network Error",I=new lt(R,lt.ERR_NETWORK,e,b);I.event=F||null,r(I),b=null},b.ontimeout=function(){let F=i.timeout?"timeout of "+i.timeout+"ms exceeded":"timeout exceeded";const R=i.transitional||RT;i.timeoutErrorMessage&&(F=i.timeoutErrorMessage),r(new lt(F,R.clarifyTimeoutError?lt.ETIMEDOUT:lt.ECONNABORTED,e,b)),b=null},s===void 0&&o.setContentType(null),"setRequestHeader"in b&&de.forEach(o.toJSON(),function(F,R){b.setRequestHeader(R,F)}),de.isUndefined(i.withCredentials)||(b.withCredentials=!!i.withCredentials),a&&a!=="json"&&(b.responseType=i.responseType),d&&([m,w]=B0(d,!0),b.addEventListener("progress",m)),c&&b.upload&&([p,v]=B0(c),b.upload.addEventListener("progress",p),b.upload.addEventListener("loadend",v)),(i.cancelToken||i.signal)&&(f=D=>{b&&(r(!D||D.type?new Zm(null,e,b):D),b.abort(),b=null)},i.cancelToken&&i.cancelToken.subscribe(f),i.signal&&(i.signal.aborted?f():i.signal.addEventListener("abort",f)));const P=Lme(i.url);if(P&&Mr.protocols.indexOf(P)===-1){r(new lt("Unsupported protocol "+P+":",lt.ERR_BAD_REQUEST,e));return}b.send(s||null)})},Vme=(e,t)=>{const{length:n}=e=e?e.filter(Boolean):[];if(t||n){let r=new AbortController,i;const s=function(d){if(!i){i=!0,a();const f=d instanceof Error?d:this.reason;r.abort(f instanceof lt?f:new Zm(f instanceof Error?f.message:f))}};let o=t&&setTimeout(()=>{o=null,s(new lt(`timeout of ${t}ms exceeded`,lt.ETIMEDOUT))},t);const a=()=>{e&&(o&&clearTimeout(o),o=null,e.forEach(d=>{d.unsubscribe?d.unsubscribe(s):d.removeEventListener("abort",s)}),e=null)};e.forEach(d=>d.addEventListener("abort",s));const{signal:c}=r;return c.unsubscribe=()=>de.asap(a),c}},Wme=function*(e,t){let n=e.byteLength;if(n<t){yield e;return}let r=0,i;for(;r<n;)i=r+t,yield e.slice(r,i),r=i},qme=async function*(e,t){for await(const n of Kme(e))yield*Wme(n,t)},Kme=async function*(e){if(e[Symbol.asyncIterator]){yield*e;return}const t=e.getReader();try{for(;;){const{done:n,value:r}=await t.read();if(n)break;yield r}}finally{await t.cancel()}},C4=(e,t,n,r)=>{const i=qme(e,t);let s=0,o,a=c=>{o||(o=!0,r&&r(c))};return new ReadableStream({async pull(c){try{const{done:d,value:f}=await i.next();if(d){a(),c.close();return}let p=f.byteLength;if(n){let m=s+=p;n(m)}c.enqueue(new Uint8Array(f))}catch(d){throw a(d),d}},cancel(c){return a(c),i.return()}},{highWaterMark:2})},k4=64*1024,{isFunction:Zy}=de,Gme=(({Request:e,Response:t})=>({Request:e,Response:t}))(de.global),{ReadableStream:T4,TextEncoder:R4}=de.global,P4=(e,...t)=>{try{return!!e(...t)}catch{return!1}},Yme=e=>{e=de.merge.call({skipUndefined:!0},Gme,e);const{fetch:t,Request:n,Response:r}=e,i=t?Zy(t):typeof fetch=="function",s=Zy(n),o=Zy(r);if(!i)return!1;const a=i&&Zy(T4),c=i&&(typeof R4=="function"?(w=>_=>w.encode(_))(new R4):async w=>new Uint8Array(await new n(w).arrayBuffer())),d=s&&a&&P4(()=>{let w=!1;const _=new n(Mr.origin,{body:new T4,method:"POST",get duplex(){return w=!0,"half"}}).headers.has("Content-Type");return w&&!_}),f=o&&a&&P4(()=>de.isReadableStream(new r("").body)),p={stream:f&&(w=>w.body)};i&&["text","arrayBuffer","blob","formData","stream"].forEach(w=>{!p[w]&&(p[w]=(_,b)=>{let C=_&&_[w];if(C)return C.call(_);throw new lt(`Response type '${w}' is not supported`,lt.ERR_NOT_SUPPORT,b)})});const m=async w=>{if(w==null)return 0;if(de.isBlob(w))return w.size;if(de.isSpecCompliantForm(w))return(await new n(Mr.origin,{method:"POST",body:w}).arrayBuffer()).byteLength;if(de.isArrayBufferView(w)||de.isArrayBuffer(w))return w.byteLength;if(de.isURLSearchParams(w)&&(w=w+""),de.isString(w))return(await c(w)).byteLength},v=async(w,_)=>{const b=de.toFiniteNumber(w.getContentLength());return b??m(_)};return async w=>{let{url:_,method:b,data:C,signal:P,cancelToken:D,timeout:F,onDownloadProgress:R,onUploadProgress:I,responseType:k,headers:L,withCredentials:B="same-origin",fetchOptions:A}=zj(w),V=t||fetch;k=k?(k+"").toLowerCase():"text";let K=Vme([P,D&&D.toAbortSignal()],F),W=null;const U=K&&K.unsubscribe&&(()=>{K.unsubscribe()});let q;try{if(I&&d&&b!=="get"&&b!=="head"&&(q=await v(L,C))!==0){let O=new n(_,{method:"POST",body:C,duplex:"half"}),H;if(de.isFormData(C)&&(H=O.headers.get("content-type"))&&L.setContentType(H),O.body){const[Z,X]=S4(q,B0(E4(I)));C=C4(O.body,k4,Z,X)}}de.isString(B)||(B=B?"include":"omit");const z=s&&"credentials"in n.prototype,x={...A,signal:K,method:b.toUpperCase(),headers:L.normalize().toJSON(),body:C,duplex:"half",credentials:z?B:void 0};W=s&&new n(_,x);let N=await(s?V(W,A):V(_,x));const M=f&&(k==="stream"||k==="response");if(f&&(R||M&&U)){const O={};["status","statusText","headers"].forEach(te=>{O[te]=N[te]});const H=de.toFiniteNumber(N.headers.get("content-length")),[Z,X]=R&&S4(H,B0(E4(R),!0))||[];N=new r(C4(N.body,k4,Z,()=>{X&&X(),U&&U()}),O)}k=k||"text";let E=await p[de.findKey(p,k)||"text"](N,w);return!M&&U&&U(),await new Promise((O,H)=>{Fj(O,H,{data:E,headers:fi.from(N.headers),status:N.status,statusText:N.statusText,config:w,request:W})})}catch(z){throw U&&U(),z&&z.name==="TypeError"&&/Load failed|fetch/i.test(z.message)?Object.assign(new lt("Network Error",lt.ERR_NETWORK,w,W,z&&z.response),{cause:z.cause||z}):lt.from(z,z&&z.code,w,W,z&&z.response)}}},Jme=new Map,Bj=e=>{let t=e&&e.env||{};const{fetch:n,Request:r,Response:i}=t,s=[r,i,n];let o=s.length,a=o,c,d,f=Jme;for(;a--;)c=s[a],d=f.get(c),d===void 0&&f.set(c,d=a?new Map:Yme(t)),f=d;return d};Bj();const OT={http:hme,xhr:Hme,fetch:{get:Bj}};de.forEach(OT,(e,t)=>{if(e){try{Object.defineProperty(e,"name",{value:t})}catch{}Object.defineProperty(e,"adapterName",{value:t})}});const O4=e=>`- ${e}`,Zme=e=>de.isFunction(e)||e===null||e===!1;function Xme(e,t){e=de.isArray(e)?e:[e];const{length:n}=e;let r,i;const s={};for(let o=0;o<n;o++){r=e[o];let a;if(i=r,!Zme(r)&&(i=OT[(a=String(r)).toLowerCase()],i===void 0))throw new lt(`Unknown adapter '${a}'`);if(i&&(de.isFunction(i)||(i=i.get(t))))break;s[a||"#"+o]=i}if(!i){const o=Object.entries(s).map(([c,d])=>`adapter ${c} `+(d===!1?"is not supported by the environment":"is not available in the build"));let a=n?o.length>1?`since : 218`+o.map(O4).join(` 219`):" "+O4(o[0]):"as no adapter specified";throw new lt("There is no suitable adapter to dispatch the request "+a,"ERR_NOT_SUPPORT")}return i}const Hj={getAdapter:Xme,adapters:OT};function kS(e){if(e.cancelToken&&e.cancelToken.throwIfRequested(),e.signal&&e.signal.aborted)throw new Zm(null,e)}function A4(e){return kS(e),e.headers=fi.from(e.headers),e.data=CS.call(e,e.transformRequest),["post","put","patch"].indexOf(e.method)!==-1&&e.headers.setContentType("application/x-www-form-urlencoded",!1),Hj.getAdapter(e.adapter||Jm.adapter,e)(e).then(function(r){return kS(e),r.data=CS.call(e,e.transformResponse,r),r.headers=fi.from(r.headers),r},function(r){return jj(r)||(kS(e),r&&r.response&&(r.response.data=CS.call(e,e.transformResponse,r.response),r.response.headers=fi.from(r.response.headers))),Promise.reject(r)})}const Vj="1.13.5",u1={};["object","boolean","number","function","string","symbol"].forEach((e,t)=>{u1[e]=function(r){return typeof r===e||"a"+(t<1?"n ":" ")+e}});const I4={};u1.transitional=function(t,n,r){function i(s,o){return"[Axios v"+Vj+"] Transitional option '"+s+"'"+o+(r?". "+r:"")}return(s,o,a)=>
vendor: 4,625 bytes, lines 219-220
219{if(t===!1)throw new lt(i(o," has been removed"+(n?" in "+n:"")),lt.ERR_DEPRECATED);return n&&!I4[o]&&(I4[o]=!0,console.warn(i(o," has been deprecated since v"+n+" and will be removed in the near future"))),t?t(s,o,a):!0}};u1.spelling=function(t){return(n,r)=>(console.warn(`${r} is likely a misspelling of ${t}`),!0)};function Qme(e,t,n){if(typeof e!="object")throw new lt("options must be an object",lt.ERR_BAD_OPTION_VALUE);const r=Object.keys(e);let i=r.length;for(;i-- >0;){const s=r[i],o=t[s];if(o){const a=e[s],c=a===void 0||o(a,s,e);if(c!==!0)throw new lt("option "+s+" must be "+c,lt.ERR_BAD_OPTION_VALUE);continue}if(n!==!0)throw new lt("Unknown option "+s,lt.ERR_BAD_OPTION)}}const $v={assertOptions:Qme,validators:u1},Vi=$v.validators;let Bc=class{constructor(t){this.defaults=t||{},this.interceptors={request:new w4,response:new w4}}async request(t,n){try{return await this._request(t,n)}catch(r){if(r instanceof Error){let i={};Error.captureStackTrace?Error.captureStackTrace(i):i=new Error;const s=i.stack?i.stack.replace(/^.+\n/,""):"";try{r.stack?s&&!String(r.stack).endsWith(s.replace(/^.+\n.+\n/,""))&&(r.stack+=` 220`+s):r.stack=s}catch{}}throw r}}_request(t,n){typeof t=="string"?(n=n||{},n.url=t):n=t||{},n=su(this.defaults,n);const{transitional:r,paramsSerializer:i,headers:s}=n;r!==void 0&&$v.assertOptions(r,{silentJSONParsing:Vi.transitional(Vi.boolean),forcedJSONParsing:Vi.transitional(Vi.boolean),clarifyTimeoutError:Vi.transitional(Vi.boolean),legacyInterceptorReqResOrdering:Vi.transitional(Vi.boolean)},!1),i!=null&&(de.isFunction(i)?n.paramsSerializer={serialize:i}:$v.assertOptions(i,{encode:Vi.function,serialize:Vi.function},!0)),n.allowAbsoluteUrls!==void 0||(this.defaults.allowAbsoluteUrls!==void 0?n.allowAbsoluteUrls=this.defaults.allowAbsoluteUrls:n.allowAbsoluteUrls=!0),$v.assertOptions(n,{baseUrl:Vi.spelling("baseURL"),withXsrfToken:Vi.spelling("withXSRFToken")},!0),n.method=(n.method||this.defaults.method||"get").toLowerCase();let o=s&&de.merge(s.common,s[n.method]);s&&de.forEach(["delete","get","head","post","put","patch","common"],w=>{delete s[w]}),n.headers=fi.concat(o,s);const a=[];let c=!0;this.interceptors.request.forEach(function(_){if(typeof _.runWhen=="function"&&_.runWhen(n)===!1)return;c=c&&_.synchronous;const b=n.transitional||RT;b&&b.legacyInterceptorReqResOrdering?a.unshift(_.fulfilled,_.rejected):a.push(_.fulfilled,_.rejected)});const d=[];this.interceptors.response.forEach(function(_){d.push(_.fulfilled,_.rejected)});let f,p=0,m;if(!c){const w=[A4.bind(this),void 0];for(w.unshift(...a),w.push(...d),m=w.length,f=Promise.resolve(n);p<m;)f=f.then(w[p++],w[p++]);return f}m=a.length;let v=n;for(;p<m;){const w=a[p++],_=a[p++];try{v=w(v)}catch(b){_.call(this,b);break}}try{f=A4.call(this,v)}catch(w){return Promise.reject(w)}for(p=0,m=d.length;p<m;)f=f.then(d[p++],d[p++]);return f}getUri(t){t=su(this.defaults,t);const n=Uj(t.baseURL,t.url,t.allowAbsoluteUrls);return Nj(n,t.params,t.paramsSerializer)}};de.forEach(["delete","get","head","options"],function(t){Bc.prototype[t]=function(n,r){return this.request(su(r||{},{method:t,url:n,data:(r||{}).data}))}});de.forEach(["post","put","patch"],function(t){function n(r){return function(s,o,a){return this.request(su(a||{},{method:t,headers:r?{"Content-Type":"multipart/form-data"}:{},url:s,data:o}))}}Bc.prototype[t]=n(),Bc.prototype[t+"Form"]=n(!0)});let ege=class Wj{constructor(t){if(typeof t!="function")throw new TypeError("executor must be a function.");let n;this.promise=new Promise(function(s){n=s});const r=this;this.promise.then(i=>{if(!r._listeners)return;let s=r._listeners.length;for(;s-- >0;)r._listeners[s](i);r._listeners=null}),this.promise.then=i=>{let s;const o=new Promise(a=>{r.subscribe(a),s=a}).then(i);return o.cancel=function(){r.unsubscribe(s)},o},t(function(s,o,a){r.reason||(r.reason=new Zm(s,o,a),n(r.reason))})}throwIfRequested(){if(this.reason)throw this.reason}subscribe(t){if(this.reason){t(this.reason);return}this._listeners?this._listeners.push(t):this._listeners=[t]}unsubscribe(t){if(!this._listeners)return;const n=this._listeners.indexOf(t);n!==-1&&this._listeners.splice(n,1)}toAbortSignal(){const t=new AbortController,n=r=>{t.abort(r)};return this.subscribe(n),t.signal.unsubscribe=()=>this.unsubscribe(n),t.signal}static source(){let t;return{token:new Wj(function(i){t=i}),cancel:t}}};function tge(e){return function(n){return e.apply(null,n)}}function nge(e){return de.isObject(e)&&e.isAxiosError===!0}const C2={Continue:100,SwitchingProtocols:101,Processing:102,EarlyHints:103,Ok:200,Created:201,Accepted:202,NonAuthoritativeInformation:203,NoContent:204,Re
220setContent:205,PartialContent:206,MultiStatus:207,AlreadyReported:208,ImUsed:226,MultipleChoices:300,MovedPermanently:301,Found:302,SeeOther:303,NotModified:304,UseProxy:305,Unused:306,TemporaryRedirect:307,PermanentRedirect:308,BadRequest:400,Unauthorized:401,PaymentRequired:402,Forbidden:403,NotFound:404,MethodNotAllowed:405,NotAcceptable:406,ProxyAuthenticationRequired:407,RequestTimeout:408,Conflict:409,Gone:410,LengthRequired:411,PreconditionFailed:412,PayloadTooLarge:413,UriTooLong:414,UnsupportedMediaType:415,RangeNotSatisfiable:416,ExpectationFailed:417,ImATeapot:418,MisdirectedRequest:421,UnprocessableEntity:422,Locked:423,FailedDependency:424,TooEarly:425,UpgradeRequired:426,PreconditionRequired:428,TooManyRequests:429,RequestHeaderFieldsTooLarge:431,UnavailableForLegalReasons:451,InternalServerError:500,NotImplemented:501,BadGateway:502,ServiceUnavailable:503,GatewayTimeout:504,HttpVersionNotSupported:505,VariantAlsoNegotiates:506,InsufficientStorage:507,LoopDetected:508,NotExtended:510,NetworkAuthenticationRequired:511,WebServerIsDown:521,ConnectionTimedOut:522,OriginIsUnreachable:523,TimeoutOccurred:524,SslHandshakeFailed:525,InvalidSslCertificate:526};Object.entries(C2).forEach(([e,t])=>{C2[t]=e});function qj(e){const t=new Bc(e),n=Cj(Bc.prototype.request,t);return de.extend(n,Bc.prototype,t,{allOwnKeys:!0}),de.extend(n,t,null,{allOwnKeys:!0}),n.create=function(i){return qj(su(e,i))},n}const Fn=qj(Jm);Fn.Axios=Bc;Fn.CanceledError=Zm;Fn.CancelToken=ege;Fn.isCancel=jj;Fn.VERSION=Vj;Fn.toFormData=c1;Fn.AxiosError=lt;Fn.Cancel=Fn.CanceledError;Fn.all=function(t){return Promise.all(t)};Fn.spread=tge;Fn.isAxiosError=nge;Fn.mergeConfig=su;Fn.AxiosHeaders=fi;Fn.formToJSON=e=>$j(de.isHTMLForm(e)?new FormData(e):e);Fn.getAdapter=Hj.getAdapter;Fn.HttpStatusCode=C2;Fn.default=Fn;const{Axios:ROe,AxiosError:POe,CanceledError:OOe,isCancel:AOe,CancelToken:IOe,VERSION:MOe,all:DOe,Cancel:LOe,isAxiosError:NOe,spread:$Oe,toFormData:jOe,AxiosHeaders:FOe,HttpStatusCode:UOe,formToJSON:zOe,getAdapter:BOe,mergeConfig:HOe}=Fn,M4="AES-GCM",rge=1,ige=1e4,ed=16,Xy=12,TS=16,sge=32;async function oge(e,t,n){const r=age(e);if(new DataView(r).getUint8(0)!==rge)throw new Error("Unsupported version");const s=r.slice(1,1+ed),o=r.slice(1+ed,1+ed+Xy),a=r.slice(1+ed+Xy,1+ed+Xy+TS),c=r.slice(1+ed+Xy+TS),d=lge(c,a),f=`${t}.${n}`,p=await crypto.subtle.importKey("raw",new TextEncoder().encode(f),"PBKDF2",!1,["deriveKey"]),m=await crypto.subtle.deriveKey({name:"PBKDF2",salt:s,iterations:ige,hash:"SHA-256"},p,{name:M4,length:sge*8},!1,["decrypt"]),v=await crypto.subtle.decrypt({name:M4,iv:o,tagLength:TS*8},m,d);return JSON.parse(new TextDecoder().decode(v))}function age(e){const t=atob(e),n=t.length,r=new Uint8Array(n);for(let i=0;i<n;i++)r[i]=t.charCodeAt(i);return r.buffer}function lge(e,t){const n=new Uint8Array(e.byteLength+t.byteLength);return n.set(new Uint8Array(e),0),n.set(new Uint8Array(t),e.byteLength),n.buffer}const cge="https://api.puef.ai",D4=()=>{window.location.href="/logout"},Tc=Fn.create({baseURL:cge,headers:{"Content-Type":"application/json"}});let k2=null;const uge=e=>{k2=e};Tc.interceptors.request.use(async e=>{if(k2&&!e.headers.Authorization)try{const t=await k2();e.headers.Authorization=`Bearer ${t}`}catch(t){t instanceof Error&&ia(t,{source:"apiClient/getToken"})}return e});Tc.interceptors.response.use(async e=>{if(e.data.errorMessage){const n={statusCode:e.data.statusCode||500,errorMessage:e.data.errorMessage,validationErrors:e.data.validationErrors};throw n.statusCode===401&&D4(),U$(n.statusCode,e.config.url||"unknown",n)}if(e.config.encryptable===!0)try{const n=hT.getQueryData(["profile"]),r=e.data.data,i=await oge(r,n?.data.email||"",n?.data.id||"");e.data.data=i}catch{throw new Error("Failed to decrypt response data")}return e},e=>{throw e.response?.status===401&&D4(),Pde(e)});function dge(e,t){const n=Object.fromEntries(Object.entries(t).filter(([,r])=>!e.includes(String(r))));return Object.keys(n).length>0?n:void 0}const ct=e=>async t=>{let n;if(e.input&&t){const a=e.input.safeParse(t);if(!a.success)throw new s2("Invalid request data",a.error.issues);n=a.data}const r=typeof e.url=="function"?e.url(n):e.url,s=await(()=>{const a={encryptable:e.encryptable};switch(e.method){case"get":{const c=typeof e.url=="function"&&n?dge(r,n):n;return Tc.get(r,{...a,params:c})}case"post":return Tc.post(r,n,a);case"put":return Tc.put(r,n,a);case"patch":return Tc.patch(r,n,a);case"delete":return Tc.delete(r,{...a,data:n})}})(),o=e.output.safeParse(s.data);if(o.success)return o.data;{const a=new s2(`Invalid response data at ${r}: ${JSON.stringify(o.error.issues)}`,o.error.issues,r);return ia(a,{url:r,issues:o.error.issues}),s.data}},Af=J(),d1=_u([Nt("ACTIVE"),Nt("FUTURE"),Nt("COMPLETED")]),Kj=_u([Nt("mcq"),Nt("spr")]),fge=J(),Gj=_u([Nt("FUTURE"),Nt("UNATTENDED"),Nt("ACTIVE"),Nt("COMPLETED"),Nt("INCOMPLETE")]),hge=_u([Nt("incomplete"),Nt("incomplete_expired"),Nt("tri
220aling"),Nt("active"),Nt("past_due"),Nt("canceled"),Nt("unpaid"),Nt("paused")]),pge=re({cue:J(),response:J()}).passthrough(),AT=re({root:J(),word:J(),part_of_speech:J(),description:J(),example:J(),synonyms:Et(J()),antonyms:Et(J())}).passthrough(),f1=re({id:J(),body:J(),choices:Et(J()),hints:Et(pge).default([]),isRecommended:Ee().default(!1),prompt:J(),questionId:J().default(""),subject:Af,topic:J(),subtopic:J(),type:Kj,vocabulary:Et(AT).default([]),reviewVideos:Et(J()).optional(),isCorrectlyAnswered:Ee().optional(),userAnswer:J().optional(),questionNo:se().optional(),isBookmarked:Ee().optional(),correctAnswer:Et(J()).optional(),answerKeyChangedSinceAttempt:Ee().optional(),difficulty:fge.optional(),activeTime:se().optional(),solveTime:se().optional()}).passthrough(),mge=re({subject:J().optional(),topic:J().optional(),subtopic:J().optional(),testDefinitionId:J().optional()}),gge=re({success:Ee(),statusCode:se(),data:re({count:se(),ids:Et(J())}).passthrough()}).passthrough(),yge=re({questionId:J()}),vge=re({success:Ee(),statusCode:se(),data:f1}).passthrough(),_ge=re({id:J(),userAnswer:J(),hintConsumption:se(),activeTime:se(),solveTime:se(),answerFormat:Nt("value").default("value"),testDefinitionId:J().optional()}),wge=re({success:Ee(),statusCode:se(),data:re({moduleQuestionId:J(),questionNo:se(),isCorrectlyAnswered:Ee(),moduleNo:se(),correctAnswer:Et(J())}).passthrough()}).passthrough(),bge=re({id:J(),questionNo:se(),moduleNo:se(),isCorrectlyAnswered:Ee()}).passthrough(),Sge=re({success:Ee(),statusCode:se(),data:re({questions:Et(bge)}).passthrough()}).passthrough(),Ege=re({questionId:J()}),xge=re({success:Ee(),statusCode:se(),data:re({id:J(),isBookmarked:Ee()}).passthrough()}).passthrough(),Cge=re({id:J(),questionNo:se(),subject:Af,topic:J(),subtopic:J().optional(),prompt:J(),userAnswer:J(),correctAnswer:Et(J()),isCorrectlyAnswered:Ee(),moduleId:J(),moduleNo:se(),questionType:Kj}).passthrough(),kge=re({success:Ee(),statusCode:se(),data:re({questions:Et(Cge)}).passthrough()}).passthrough(),Yj=re({testDefinitionId:J().optional()}),Tge=ct({method:"get",url:"/modules/questions/recommendations",input:mge,output:gge}),Rge=ct({method:"get",url:({questionId:e})=>`/modules/questions/${e}`,input:yge,output:vge,encryptable:!0}),Pge=ct({method:"post",url:"/modules/questions/submit",input:_ge,output:wge}),Oge=ct({method:"get",url:"/modules/questions/history",input:Yj,output:Sge}),Age=ct({method:"patch",url:({questionId:e})=>`/modules/questions/${e}/bookmark`,input:Ege,output:xge}),Ige=ct({method:"get",url:"/modules/questions/bookmarks",input:Yj,output:kge}),Mge=Object.freeze(Object.defineProperty({__proto__:null,bookmarkQuestion:Age,getBookmarkedQuestions:Ige,getQuestionById:Rge,getQuestionsHistory:Oge,getRecommendations:Tge,submitAnswer:Pge},Symbol.toStringTag,{value:"Module"})),Dge=re({word:J(),vocabulary:AT,marked:Ee(),learned:Ee(),mastered:Ee()}).passthrough(),Lge=re({success:Ee(),statusCode:se(),data:re({vocabularies:Et(Dge)}).passthrough()}).passthrough(),Nge=re({success:Ee(),statusCode:se(),data:re({words:Et(J())}).passthrough()}).passthrough(),$ge=re({word:J(),vocabulary:AT.optional(),marked:Ee().optional(),learned:Ee().optional(),mastered:Ee().optional()}),jge=Ej(),Fge=ct({method:"get",url:"/vocabularies/marked",output:Lge}),Uge=ct({method:"get",url:"/vocabularies/marked/list",output:Nge}),zge=ct({method:"put",url:"/vocabularies",input:$ge,output:jge}),Bge=Object.freeze(Object.defineProperty({__proto__:null,getBookmarkedWordList:Uge,getBookmarkedWords:Fge,updateVocabulary:zge},Symbol.toStringTag,{value:"Module"})),IT=re({questionId:J(),userAnswer:J().nullable(),activeTime:se(),solveTime:se(),isBookmarked:Ee(),answerFormat:Nt("value").default("value")}),Hge=re({diagnosisId:J()}),Vge=re({id:J(),isBookmarked:Ee(),questionNo:se(),subject:Af}).passthrough(),Wge=re({success:Ee(),statusCode:se(),data:re({id:J(),startDate:J(),endDate:J().nullable(),status:d1,questions:Et(Vge)}).passthrough()}).passthrough(),qge=re({diagnosisId:J()}),Kge=re({success:Ee(),statusCode:se(),data:re({diagnosisId:J()}).passthrough()}).passthrough(),Gge=re({diagnosisId:J()}),Yge=re({success:Ee(),statusCode:se(),data:re({diagnosisId:J(),status:J()}).passthrough()}).passthrough(),Jge=re({diagnosisId:J()}).merge(IT),Zge=re({success:Ee(),statusCode:se(),data:re({questionId:J(),isBookmarked:Ee()}).passthrough()}).passthrough(),Xge=re({diagnosisId:J(),questionId:J()}),Qge=re({success:Ee(),statusCode:se(),data:f1}).passthrough(),MT=_u([Nt("FUTURE"),Nt("ACTIVE"),Nt("COMPLETED")]),eye=_u([Nt("COMPLETED"),Nt("ACTIVE"),Nt("FUTURE"),Nt("INELIGIBLE")]),tye=J(),L4=re({id:J(),sectionNo:se().optional(),status:eye,startedAt:J().nullable().optional(),finishedAt:J().nullable().optional(),title:J(),duration:se(),breakAfterSeconds:se().nullable().optional(),subject:Af,level:tye,questions:Et(re({id:J(),questionNo:se(),userAnswer:J()}).passthrough()).optional()}).passthrough(),DT=re({id:J(),examNo:se(),status:MT,sections:Et(L4),mathScore:se().optional(),englishScore:se().optional(),totalScore:se().optional(),startDate:J().optional(),endDate:J().nullable().optional(),currentSection:L4.optional(),scoringStatus:J().optional(),deadline:J().nullish()}).passthrough(),nye=re({id:J(),title:J(),createdAt:J(),modifiedAt:J(),status:MT,userId:J(),deadline:J(),startdate:J(),endDate:J(),summary:re({mathScore:se().nullish(),englishScore:se().nullish(),totalScore:se().nullish()}).passthrough()}).passthrough(),rye=re({topic:J(),subject:Af,correctQuestionCount:se(),incorrectQuestionCount:se(),omittedQuestionCount:se(),totalQuestionCount:se(),questions:Et(re({id:J(),subtopic:J(),isCorrectlyAnswered:Ee().nullable(),difficulty:J().nullish(),activeTimeSeconds:Zp.number().nullish(),solveTimeSeconds:Zp.number().nullish()}).passthrough())}).passthrough(),iye=re({examId:J()}),sye=re({success:Ee(),statusCode:se(),data:DT}).passthrough(),oye=re({examId:J(),questionId:J()}),aye=re({success:Ee(),statusCode:se(),data:f1}).passthrough(),lye=re({examId:J()}),cye=re({success:Ee(),statusCode:se(),data:re({examId:J()}).passthrough()}).passthrough(),uye=re({examId:J()}),dye=re({success:Ee(),statusCode:se(),data:re({examId:J(),sectionNo:se(),sectionTitle:J()}).passthrough()}).passthrough(),fye=re({examId:J()}),hye=re({success:Ee(),statusCode:se(),data:re({examStatus:MT,nextSectionNo:se().optional(),nextSectionSubject:J().optional(),nextSectionTitle:J().optional()}).passthrough()}).passthrough(),pye=re({examId:J()}).merge(IT),mye=re({success:Ee(),statusCode:se(),data:re({questionId:J(),isBookmarked:Ee()}).passthrough()}).passthrough(),gye=re({success:Ee(),statusCode:se(),data:re({exams:Et(nye)}).passthrough()}).passthrough(),yye=re({examId:J()}),vye=re({success:Ee(),statusCode:se(),data:re({subjects:Et(rye)}).passthrough()}).passthrough(),_ye=re({examId:J(),sectionNo:se(),secondsSpent:se(),questions:Et(re({questionId:J(),answer:J().nullable()}))}),wye=re({success:Ee(),statusCode:se(),data:DT}).passthrough(),bye=re({examId:J()}),Sye=re({success:Ee(),statusCode:se(),data:DT}).passthrough(),Eye=re({examId:J(),topic:J()}),xye=re({success:Ee(),statusCode:se(),data:re({questions:Et(re({id:J(),questionNo:se(),subject:Af}).passthrough())}).passthrough()}).passthrough(),Qy=re({title:J(),body:J()}).passthrough(),Cye=re({intro:Et(Qy.extend({key:J().optional()})).default([]),directions:re({bySubject:Et(Qy.extend({subject:J()})).optional(),default:Qy.optional()}).passthrough().default({}),breakScreen:Qy.optional(),sittingNoun:J().optional()}).passthrough(),kye=re({examId:J()}),Tye=re({success:Ee(),statusCode:se(),data:Cye}).passthrough(),Rye=ct({method:"get",url:({examId:e})=>`/exams/${e}`,input:iye,output:sye}),Pye=ct({method:"get",url:({examId:e,questionId:t})=>`/exams/${e}/question/${t}`,input:oye,output:aye,encryptable:!0}),Oye=ct({method:"post",url:({examId:e})=>`/exams/${e}/start`,input:lye,output:cye}),Aye=ct({method:"post",url:({examId:e})=>`/exams/${e}/sections/start`,input:uye,output:dye}),Iye=ct({method:"post",url:({examId:e})=>`/exams/${e}/sections/submit`,input:fye,output:hye}),Mye=ct({method:"patch",url:({examId:e})=>`/exams/${e}/save-question`,input:pye,output:mye}),Dye=ct({method:"get",url:"/exams",output:gye}),Lye=ct({method:"get",url:({examId:e})=>`/exams/${e}/stats`,input:yye,output:vye}),Nye=ct({method:"patch",url:({examId:e,sectionNo:t})=>`/exams/${e}/sections/${t}`,input:_ye,output:wye}),$ye=ct({method:"get",url:({examId:e})=>`/exams/${e}/active-section`,input:bye,output:Sye}),jye=ct({method:"get",url:({examId:e})=>`/exams/${e}/questions`,input:Eye,output:xye}),Fye=ct({method:"get",url:({examId:e})=>`/exams/${e}/instructions`,input:kye,output:Tye}),Uye=Object.freeze(Object.defineProperty({__proto__:null,getExamActiveSection:$ye,getExamById:Rye,getExamInstructions:Fye,getExamQuestionById:Pye,getExamQuestions:jye,getExamStats:Lye,getStudentExams:Dye,saveExam:Nye,saveExamQuestion:Mye,startExam:Oye,startExamSection:Aye,submitExamSection:Iye},Symbol.toStringTag,{value:"Module"})),zye=re({id:J(),availableAt:J().nullable(),milestoneNo:se(),moduleNo:se(),questionCapacity:se().default(0),status:d1,achievement:se(),achievementThresholds:Et(se()),deadline:J().nullable(),milestoneType:Nt("Module"),summary:re({numCorrect:se(),numIncorrect:se(),startDate:J().nullable(),endDate:J().nullable(),timeSpent:se()}).passthrough().nullable().default(null)}).passthrough(),Bye=re({id:J(),availableAt:J().nullable(),status:d1,examId:J(),examNo:se(),isTeacherAssigned:Ee().default(!1),deadline:J().nullish(),title:J().nullish(),milestoneNo:se(),milestoneType:Nt("Exam"),summary:re({mathScore:se().nullish(),englishScore:se().nullish(),totalScore:se().nullish(),sectionScores:Et(re({subject:J(),score:se().nullish()}).passthrough()).nullish(),aggregateScore:se().nullish(),aggregateScoreKey:J().nullish()}).passthrough().nullable().default(null)}).passthrough(),Hye=re({id:J(),availableAt:J().nullable(),milestoneType:Nt("Diagnosis"),diagnosisId:J(),status:d1,milestoneNo:se(),summary:re({mathMinScore:se().optional(),mathMaxScore:se().optional(),englishMinScore:se().optional(),englishMaxScore:se().optional(),totalMinScore:se().optional(),totalMaxScore:se().optional(),numCorrect:se(),numIncorrect:se(),totalQuestions:se()}).passthrough().nullable().default(null)}).passthrough(),Vye=Tpe("milestoneType",[zye,Bye,Hye]),Wye=re({success:Ee(),statusCode:se(),data:re({milestones:Et(Vye)}).passthrough()}).passthrough(),Jj=re({testDefinitionId:J().optional()}),qye=ct({method:"get",url:"/milestones",input:Jj,output:Wye}),Kye=Object.freeze(Object.defineProperty({__proto__:null,GetMilestonesInput:Jj,getMilestones:qye},Symbol.toStringTag,{value:"Module"})),Gye=re({message:J(),milestoneType:_u([Nt("Diagnosis"),Nt("Module"),Nt("Exam")]),questionId:J()}),Yye=re({success:Ee(),statusCode:se(),data:Ej()}).passthrough(),Jye=ct({method:"post",url:"/feedback/question-feedback",input:Gye,output:Yye}),Zye=Object.freeze(Object.defineProperty({__proto__:null,sendFeedback:Jye},Symbol.toStringTag,{value:"Module"})),Xye=re({id:J(),title:J(),description:J(),price:se(),period:se(),module
220Capacity:se(),examCapacity:se()}).passthrough(),Qye=re({success:Ee(),statusCode:se(),data:re({plans:Et(Xye)}).passthrough()}).passthrough(),eve=re({success:Ee(),statusCode:se(),data:re({portalUrl:J()}).passthrough()}).passthrough(),tve=re({paymentPlanId:J()}),nve=re({success:Ee(),statusCode:se(),data:re({sessionUrl:J()}).passthrough()}).passthrough(),rve=ct({method:"get",url:"/payment/plans",output:Qye}),ive=ct({method:"get",url:"/payment/portal-link",output:eve}),sve=ct({method:"post",url:"/payment/sessions",input:tve,output:nve}),ove=Object.freeze(Object.defineProperty({__proto__:null,createSession:sve,getPlans:rve,getPortalLink:ive},Symbol.toStringTag,{value:"Module"})),ave=re({id:J(),status:hge,currentPeriodStart:J(),currentPeriodEnd:J()}).passthrough(),lve=re({id:J(),name:J()}).passthrough(),cve=s1(["tenant","subscription","none"]),uve=re({id:J(),email:J(),username:J(),auth0Id:J(),role:J(),isDemoUser:Ee().nullable().optional(),paymentPlanId:J().nullable().optional(),stripeCustomerId:J().nullable().optional(),subscription:ave.nullable().optional(),tenant:lve.nullable().optional(),accessSource:cve.optional(),hasFullAccess:Ee().optional()}).passthrough(),dve=re({success:Ee(),statusCode:se(),data:uve}).passthrough(),fve=ct({method:"get",url:"/users/me",output:dve}),hve=Object.freeze(Object.defineProperty({__proto__:null,getProfile:fve},Symbol.toStringTag,{value:"Module"})),pve=ct({method:"get",url:({diagnosisId:e})=>`/diagnosis/${e}`,input:Hge,output:Wge}),mve=ct({method:"post",url:({diagnosisId:e})=>`/diagnosis/${e}/start`,input:qge,output:Kge}),gve=ct({method:"post",url:({diagnosisId:e})=>`/diagnosis/${e}/submit`,input:Gge,output:Yge}),yve=ct({method:"patch",url:({diagnosisId:e})=>`/diagnosis/${e}/save-question`,input:Jge,output:Zge}),vve=ct({method:"get",url:({diagnosisId:e,questionId:t})=>`/diagnosis/${e}/question/${t}`,input:Xge,output:Qge,encryptable:!0}),_ve=Object.freeze(Object.defineProperty({__proto__:null,getDiagnosisById:pve,getDiagnosisQuestionById:vve,saveDiagnosisQuestion:yve,startDiagnosis:mve,submitDiagnosis:gve},Symbol.toStringTag,{value:"Module"})),wve=J(),bve=s1(["not_started","beginning","developing","proficient","mastered"]),Sve=re({title:J(),correctAnswerCount:se(),incorrectAnswerCount:se(),totalAnswerCount:se(),code:J().optional(),currentMastery:se().optional(),masteryLevel:bve.optional(),difficultyLevel:J().optional(),totalQuestions:se().optional(),progress:Et(xj([se(),se()])).optional()}).passthrough(),Eve=re({topic:J(),totalQuestions:se(),correctAnswerCount:se(),incorrectAnswerCount:se(),currentMastery:se(),progress:Et(xj([se(),se()])),subtopics:Et(Sve),subject:wve}).passthrough(),xve=re({success:Ee(),statusCode:se(),data:re({userId:J(),topicProgress:Et(Eve)}).passthrough()}).passthrough(),Cve=re({success:Ee(),statusCode:se(),data:re({id:J(),moduleNo:se(),milestoneNo:se(),achievement:se(),achievementThresholds:Et(se()),deadline:J().nullable(),summary:re({numCorrect:se(),numIncorrect:se()}).passthrough()}).passthrough()}).passthrough(),Zj=re({testDefinitionId:J().optional()}),kve=ct({method:"get",url:"/modules/active",input:Zj,output:Cve}),Xj=re({testDefinitionId:J().optional(),includeSubtopicHistory:Ee().optional()}),Tve=ct({method:"get",url:"/modules/knowledge-progress",input:Xj,output:xve}),Rve=Object.freeze(Object.defineProperty({__proto__:null,GetActiveModuleInput:Zj,GetKnowledgeProgressInput:Xj,getActiveModule:kve,getKnowledgeProgress:Tve},Symbol.toStringTag,{value:"Module"})),Pve=re({success:Ee(),statusCode:se(),data:re({hasExam:Ee(),hasDiagnosis:Ee(),hasAssignment:Ee()}).passthrough()}).passthrough(),Ove=ct({method:"get",url:"/users/notifications",output:Pve}),Ave=Object.freeze(Object.defineProperty({__proto__:null,getNotifications:Ove},Symbol.toStringTag,{value:"Module"})),Ive=re({id:J(),status:Gj,title:J(),totalQuestions:se(),availableAt:J().nullable(),deadline:J().nullable(),endDate:J().nullable().optional(),timeLimit:Ee().optional(),timeLimitValue:se().nullable().optional(),canStudentsSeeQuizResponses:Ee().optional(),summary:re({correctQuestionCount:se(),incorrectQuestionCount:se(),omittedQuestionCount:se()}).passthrough().optional()}).passthrough(),Mve=re({offset:se().optional().default(0),limit:se().optional().default(20),testDefinitionId:J().optional()}),Dve=re({success:Ee(),statusCode:se(),data:re({count:se(),limit:se(),offset:se(),data:Et(Ive)}).passthrough()}).passthrough(),Lve=re({assignmentId:J()}),Nve=re({success:Ee(),statusCode:se(),data:re({assignmentId:J()}).passthrough()}).passthrough(),$ve=re({assignmentId:J()}),jve=re({id:J(),status:Gj,startDate:J().nullable(),endDate:J().nullable(),title:J(),description:J(),totalQuestions:se(),availableAt:J().nullable(),deadline:J().nullable(),timeLimit:Ee().optional(),timeLimitValue:se().nullable().optional(),questions:Et(re({id:J(),questionNo:se(),userAnswer:J().nullable(),isBookmarked:Ee()}).passthrough()),summary:re({correctQuestionCount:se(),incorrectQuestionCount:se(),omittedQuestionCount:se()}).passthrough().optional()}).passthrough(),Fve=re({success:Ee(),statusCode:se(),data:jve}).passthrough(),Uve=re({assignmentId:J(),questionId:J()}),zve=re({success:Ee(),statusCode:se(),data:f1}).passthrough(),Bve=re({assignmentId:J()}).merge(IT),Hve=re({success:Ee(),statusCode:se(),data:re({questionId:J(),isBookmarked:Ee()}).passthrough()}).passthrough(),Vve=re({assignmentId:J()}),Wve=re({success:Ee(),statusCode:se(),data:re({assignmentId:J(),status:J()}).passthrough()}).passthrough(),qve=ct({method:"get",url:"/assignments",input:Mve,output:Dve}),Kve=ct({method:"post",url:({assignmentId:e})=>`/assignments/${e}/start`,input:Lve,output:Nve}),Gve=ct({method:"get",url:({assignmentId:e})=>`/assignments/${e}`,input:$ve,output:Fve}),Yve=ct({method:"get",url:({assignmentId:e,questionId:t})=>`/assignments/${e}/question/${t}`,input:Uve,output:zve,encryptable:!0}),Jve=ct({method:"patch",url:({assignmentId:e})=>`/assignments/${e}/save-question`,input:Bve,output:Hve}),Zve=ct({method:"post",url:({assignmentId:e})=>`/assignments/${e}/submit`,input:Vve,output:Wve}),Xve=Object.freeze(Object.defineProperty({__proto__:null,getAssignmentById:Gve,getAssignmentQuestionById:Yve,getAssignments:qve,saveAssignmentQuestion:Jve,startAssignment:Kve,submitAssignment:Zve},Symbol.toStringTag,{value:"Module"})),Qve=re({name:J(),questionCount:se()}).passthrough(),e0e=re({name:J(),questionCount:se(),subtopics:Et(Qve)}).passthrough(),t0e=re({id:J(),title:J(),topics:Et(e0e)}).passthrough(),n0e=re({success:Ee(),statusCode:se(),data:re({subjects:Et(t0e)}).passthrough()}).passthrough(),Qj=re({testDefinitionId:J().optional()}),r0e=ct({method:"get",url:"/question-bank/structure",input:Qj,output:n0e}),i0e=Object.freeze(Object.defineProperty({__proto__:null,GetQuestionBankStru
220ctureInput:Qj,getQuestionBankStructure:r0e},Symbol.toStringTag,{value:"Module"})),s0e=re({testDefinitionId:J(),family:J(),name:J().nullable(),status:J(),ready:Ee(),reason:J()}),o0e=re({success:Ee(),statusCode:se(),data:Et(s0e)}).passthrough(),eF=ct({method:"get",url:"/tests/available",output:o0e}),a0e=Object.freeze(Object.defineProperty({__proto__:null,getAvailableTests:eF},Symbol.toStringTag,{value:"Module"})),l0e=re({schoolYear:J(),startDate:J(),endDate:J()}).passthrough(),c0e=re({success:Ee(),statusCode:se(),data:l0e}).passthrough(),u0e=re({subjectCode:J().nullish(),topicLabel:J().nullish(),subtopicLabel:J().nullish(),questionAttempts:se().nullish(),correctAttempts:se().nullish(),incorrectAttempts:se().nullish(),accuracyPct:se().nullish(),activeTimeSeconds:Zp.number().nullish()}).passthrough(),d0e=re({id:J(),status:s1(["correct","incorrect","omitted"]),activeTimeSec:Zp.number().nullish(),solveTimeSec:Zp.number().nullish(),answeredAt:J(),topicLabel:J().nullish(),subtopicLabel:J().nullish()}).passthrough(),f0e=re({success:Ee(),statusCode:se(),data:re({data:Et(d0e),meta:re({limit:se(),offset:se(),total:se()}).passthrough()}).passthrough()}).passthrough(),h0e=re({mastered:se(),proficient:se(),developing:se()}).passthrough(),p0e=re({success:Ee(),statusCode:se(),data:h0e}).passthrough(),m0e=re({success:Ee(),statusCode:se(),data:re({groupBy:J(),skills:Et(u0e)}).passthrough()}).passthrough(),g0e=re({success:Ee(),statusCode:se(),data:re({knowledgeMasteryPct:se().nullable().optional()}).passthrough()}).passthrough(),y0e=ct({method:"get",url:"/analytics-dashboard/academic-session",input:re({}),output:c0e}),v0e=ct({method:"get",url:"/analytics-dashboard/mastery-thresholds",input:re({}),output:p0e}),tF=re({scopeType:Nt("student"),scopeId:J(),startDate:J(),endDate:J(),groupBy:s1(["topic","subtopic"]),subjectCode:J().default("ALL"),gradeLevel:J().default("ALL"),testDefinitionId:J().optional()}),_0e=ct({method:"get",url:"/analytics-dashboard/skills",input:tF,output:m0e}),nF=re({scopeType:Nt("student"),scopeId:J(),startDate:J(),endDate:J(),subjectCode:J().default("ALL"),gradeLevel:J().default("ALL"),testDefinitionId:J().optional()}),w0e=ct({method:"get",url:"/analytics-dashboard/summary",input:nF,output:g0e}),rF=re({studentId:J(),limit:se(),offset:se().optional(),testDefinitionId:J().optional(),startDate:J().optional(),endDate:J().optional(),answeredOnly:Ee().optional()}),b0e=ct({method:"get",url:({studentId:e})=>`/analytics-dashboard/students/${e}/recent-questions`,input:rF,output:f0e}),S0e=Object.freeze(Object.defineProperty({__proto__:null,GetRecentQuestionsInput:rF,GetSkillsInput:tF,GetSummaryInput:nF,getAcademicSession:y0e,getMasteryThresholds:v0e,getRecentQuestions:b0e,getSkills:_0e,getSummary:w0e},Symbol.toStringTag,{value:"Module"})),Gr={exams:Uye,questions:Mge,vocabulary:Bge,milestones:Kye,feedback:Zye,payment:ove,auth:hve,diagnosis:_ve,modules:Rve,notifications:Ave,assignments:Xve,questionBank:i0e,tests:a0e,analytics:S0e},iF=()=>hX({mutationFn:({paymentPlanId:e})=>Gr.payment.createSession({paymentPlanId:e}),onSuccess:e=>{window.location.href=e.data.sessionUrl}}),jv="puef_affiliate",E0e=720*60*60*1e3;function x0e(e){const t={code:e,expiresAt:Date.now()+E0e};localStorage.setItem(jv,JSON.stringify(t))}function C0e(){const e=localStorage.getItem(jv);if(!e)return null;try{const t=JSON.parse(e);return Date.now()>t.expiresAt?(localStorage.removeItem(jv),null):t.code}catch{return localStorage.removeItem(jv),null}}const LT=({enabled:e=!0}={})=>As({queryKey:["profile"],queryFn:Gr.auth.getProfile,select:t=>t.data,gcTime:1e3*60*60*24,enabled:e}),VOe=()=>Tm().getQueryData(["profile"])?.data;function sF(e){if(!e)return"none";if(e.accessSource)return e.accessSource;if(e.tenant)return"tenant";const t=e.subscription?.status;return t==="active"||t==="trialing"?"subscription":"none"}function k0e(e){return typeof e?.hasFullAccess=="boolean"?e.hasFullAccess:sF(e)!=="none"}function oF(e){return sF(e)==="tenant"}const T2="puef_return_to",T0e=new Set(["/","/login","/logout","/signup","/clever-login","/classlink-login"]),aF=e=>!e||!e.startsWith("/")||e.startsWith("//")?!1:!T0e.has(e.split(/[?#]/)[0]),R0e=()=>{try{const e=sessionStorage.getItem(T2);return sessionStorage.removeItem(T2),aF(e)?e:null}catch{return null}};let lF=R0e();function cF(e){if(aF(e))try{sessionStorage.setItem(T2,e)}catch{}}function WOe(){return lF}function qOe(){lF=null}const P0e=()=>j.jsx(O0e,{}),O0e=()=>{const[e,t]=g.useState(null),{isAuthenticated:n,isLoading:r,loginWithRedirect:i,getAccessTokenSilently:s,error:o}=km(),a=Mi(),[c]=Yhe(),d=c.get("planId"),f=c.get("affiliate_code");f&&x0e(f);const p=f??C0e(),m=g.useRef(null),v=g.useRef(!1),{mutateAsync:w}=iF();g.useEffect(()=>{n&&uge(s)},[n,s]);const{data:_,status:b}=LT({enabled:n});return g.useEffect(()=>{if(r||n||v.current)return;v.current=!0;let C=!1;return cF(`${a.pathname}${a.search}`),i({authorizationParams:{prompt:"select_account",...p&&{affiliate_code:p}}}).catch(P=>{if(C)return;P instanceof Error&&ia(P,{source:"AuthLayout/loginRedirect"});let D="Unknown error";typeof P=="string"?D=P:P instanceof Error&&(D=P.message),t(D)}),()=>{C=!0}},[n,r,i,p,a]),g.useEffect(()=>{if(!n||!d||m.current===d||b==="pending"||oF(_))return;m.current=d;let C=!1;return w({paymentPlanId:d}).catch(P=>{C||(P instanceof Error&&ia(P,{source:"AuthLayout/createSession"}),m.current=null)}),()=>{C=!0}},[n,d,w,_,b]),o?.message||e?j.jsxs("div",{className:"h-screen flex flex-col justify-center items-center",children:[j.jsx("h1",{className:"text-2xl font-bold mb-2",children:"Login Error"}),j.jsx("p",{className:"text-lg font-medium",children:"Please try again"})]}):r||!n?j.jsx("div",{className:"h-screen flex justify-center items-center",children:"Loading..."}):j.jsx(qm,{})},N4=e=>{let t;const n=new Set,r=(d,f)=>{const p=typeof d=="function"?d(t):d;if(!Object.is(p,t)){const m=t;t=f??(typeof p!="object"||p===null)?p:Object.assign({}
220,t,p),n.forEach(v=>v(t,m))}},i=()=>t,a={setState:r,getState:i,getInitialState:()=>c,subscribe:d=>(n.add(d),()=>n.delete(d))},c=t=e(r,i,a);return a},A0e=(e=>e?N4(e):N4),I0e=e=>e;function M0e(e,t=I0e){const n=bt.useSyncExternalStore(e.subscribe,bt.useCallback(()=>t(e.getState()),[e,t]),bt.useCallback(()=>t(e.getInitialState()),[e,t]));return bt.useDebugValue(n),n}const D0e=e=>{const t=A0e(e),n=r=>M0e(t,r);return Object.assign(n,t),n},NT=(e=>D0e),$4={BASE_URL:"/",DEV:!1,MODE:"production",PROD:!0,SSR:!1,VITE_API_URL:"https://api.puef.ai",VITE_AUTH0_AUDIENCE:"api.puef.ai/v1",VITE_AUTH0_CLIENT_ID:"SohuOg2vcDazD1OS31zypVJGPWxCFy93",VITE_AUTH0_DOMAIN:"puef-prod.us.auth0.com",VITE_B2B_DOMAINS:"student.harmonytx.org",VITE_BASE_API_URL:"https://api.puef.ai",VITE_DATA_ENCRYPTED:"true",VITE_ENABLE_MOCKS:"false",VITE_PUBLIC_POSTHOG_HOST:"https://us.i.posthog.com",VITE_PUBLIC_POSTHOG_KEY:"phc_w4kJKAVoqZh34nywOK9ssxUvhvXn09vhFDrt4MYrVPd",VITE_SENTRY_DSN:"https://32fe489093c4e0d5b14bf8cc5e1b16a6@o4510744058920960.ingest.us.sentry.io/4510747705802752",VITE_STRICT_API_VALIDATION:"false"},Xp=new Map,ev=e=>{const t=Xp.get(e);return t?Object.fromEntries(Object.entries(t.stores).map(([n,r])=>[n,r.getState()])):{}},L0e=(e,t,n)=>{if(e===void 0)return{type:"untracked",connection:t.connect(n)};const r=Xp.get(n.name);if(r)return{type:"tracked",store:e,...r};const i={connection:t.connect(n),stores:{}};return Xp.set(n.name,i),{type:"tracked",store:e,...i}},N0e=(e,t)=>{if(t===void 0)return;const n=Xp.get(e);n&&(delete n.stores[t],Object.keys(n.stores).length===0&&Xp.delete(e))},$0e=e=>{var t,n;if(!e)return;const r=e.split(` 221`),i=r.findIndex(o=>o.includes("api.setState"));if(i<0)return;const s=((t=r[i+1])==null?void 0:t.trim())||"";return(n=/.+ (.+) .+/.exec(s))==null?void 0:n[1]},j0e=(e,t={})=>(n,r,i)=>{const{enabled:s,anonymousActionType:o,store:a,...c}=t;let d;try{d=(s??($4?"production":void 0)!=="production")&&window.__REDUX_DEVTOOLS_EXTENSION__}catch{}if(!d)return e(n,r,i);const{connection:f,...p}=L0e(a,d,c);let m=!0;i.setState=((_,b,C)=>{const P=n(_,b);if(!m)return P;const D=C===void 0?{type:o||$0e(new Error().stack)||"anonymous"}:typeof C=="string"?{type:C}:C;return a===void 0?(f?.send(D,r()),P):(f?.send({...D,type:`${a}/${D.type}`},{...ev(c.name),[a]:i.getState()}),P)}),i.devtools={cleanup:()=>{f&&typeof f.unsubscribe=="function"&&f.unsubscribe(),N0e(c.name,a)}};const v=(..._)=>{const b=m;m=!1,n(..._),m=b},w=e(i.setState,r,i);if(p.type==="untracked"?f?.init(w):(p.stores[p.store]=i,f?.init(Object.fromEntries(Object.entries(p.stores).map(([_,b])=>[_,_===p.store?w:b.getState()])))),i.dispatchFromDevtools&&typeof i.dispatch=="function"){let _=!1;const b=i.dispatch;i.dispatch=(...C)=>{($4?"production":void 0)!=="production"&&C[0].type==="__setState"&&!_&&(console.warn('[zustand devtools middleware] "__setState" action type is reserved to set state from the devtools. Avoid using it.'),_=!0),b(...C)}}return f.subscribe(_=>{var b;switch(_.type){case"ACTION":if(typeof _.payload!="string"){console.error("[zustand devtools middleware] Unsupported action format");return}return RS(_.payload,C=>{if(C.type==="__setState"){if(a===void 0){v(C.state);return}Object.keys(C.state).length!==1&&console.error(` 222 [zustand devtools middleware] Unsupported __setState action format. 223 When using 'store' option in devtools(), the 'state' should have only one key, which is a value of 'store' that was passed in devtools(), 224 and value of this only key should be a state object. Example: { "type": "__setState", "state": { "abc123Store": { "foo": "bar" } } } 225 `);const P=C.state[a];if(P==null)return;JSON.stringify(i.getState())!==JSON.stringify(P)&&v(P);return}i.dispatchFromDevtools&&typeof i.dispatch=="function"&&i.dispatch(C)});case"DISPATCH":switch(_.payload.type){case"RESET":return v(w),a===void 0?f?.init(i.getState()):f?.
225init(ev(c.name));case"COMMIT":if(a===void 0){f?.init(i.getState());return}return f?.init(ev(c.name));case"ROLLBACK":return RS(_.state,C=>{if(a===void 0){v(C),f?.init(i.getState());return}v(C[a]),f?.init(ev(c.name))});case"JUMP_TO_STATE":case"JUMP_TO_ACTION":return RS(_.state,C=>{if(a===void 0){v(C);return}JSON.stringify(i.getState())!==JSON.stringify(C[a])&&v(C[a])});case"IMPORT_STATE":{const{nextLiftedState:C}=_.payload,P=(b=C.computedStates.slice(-1)[0])==null?void 0:b.state;if(!P)return;v(a===void 0?P:P[a]),f?.send(null,C);return}case"PAUSE_RECORDING":return m=!m}return}}),w},uF=j0e,RS=(e,t)=>{let n;try{n=JSON.parse(e)}catch(r){console.error("[zustand devtools middleware] Could not parse the received json",r)}n!==void 0&&t(n)};function dF(e,t){let n;try{n=e()}catch{return}return{getItem:i=>{var s;const o=c=>c===null?null:JSON.parse(c,void 0),a=(s=n.getItem(i))!=null?s:null;return a instanceof Promise?a.then(o):o(a)},setItem:(i,s)=>n.setItem(i,JSON.stringify(s,void 0)),removeItem:i=>n.removeItem(i)}}const R2=e=>t=>{try{const n=e(t);return n instanceof Promise?n:{then(r){return R2(r)(n)},catch(r){return this}}}catch(n){return{then(r){return this},catch(r){return R2(r)(n)}}}},F0e=(e,t)=>(n,r,i)=>{let s={storage:dF(()=>localStorage),partialize:_=>_,version:0,merge:(_,b)=>({...b,..._}),...t},o=!1;const a=new Set,c=new Set;let d=s.storage;if(!d)return e((..._)=>{console.warn(`[zustand persist middleware] Unable to update item '${s.name}', the given storage is currently unavailable.`),n(..._)},r,i);const f=()=>{const _=s.partialize({...r()});return d.setItem(s.name,{state:_,version:s.version})},p=i.setState;i.setState=(_,b)=>(p(_,b),f());const m=e((..._)=>(n(..._),f()),r,i);i.getInitialState=()=>m;let v;const w=()=>{var _,b;if(!d)return;o=!1,a.forEach(P=>{var D;return P((D=r())!=null?D:m)});const C=((b=s.onRehydrateStorage)==null?void 0:b.call(s,(_=r())!=null?_:m))||void 0;return R2(d.getItem.bind(d))(s.name).then(P=>{if(P)if(typeof P.version=="number"&&P.version!==s.version){if(s.migrate){const D=s.migrate(P.state,P.version);return D instanceof Promise?D.then(F=>[!0,F]):[!0,D]}console.error("State loaded from storage couldn't be migrated since no migrate function was provided")}else return[!1,P.state];return[!1,void 0]}).then(P=>{var D;const[F,R]=P;if(v=s.merge(R,(D=r())!=null?D:m),n(v,!0),F)return f()}).then(()=>{C?.(v,void 0),v=r(),o=!0,c.forEach(P=>P(v))}).catch(P=>{C?.(void 0,P)})};return i.persist={setOptions:_=>{s={...s,..._},_.storage&&(d=_.storage)},clearStorage:()=>{d?.removeItem(s.name)},getOptions:()=>s,rehydrate:()=>w(),hasHydrated:()=>o,onHydrate:_=>(a.add(_),()=>{a.delete(_)}),onFinishHydration:_=>(c.add(_),()=>{c.delete(_)})},s.skipHydration||w(),v||m},$T=F0e;var fF=Symbol.for("immer-nothing"),j4=Symbol.for("immer-draftable"),Ai=Symbol.for("immer-state");function Ss(e,...t){throw new Error(`[Immer] minified error nr: ${e}. Full error at: https://bit.ly/3cXEKWf`)}var Qp=Object.getPrototypeOf;function of(e){return!!e&&!!e[Ai]}function ou(e){return e?hF(e)||Array.isArray(e)||!!e[j4]||!!e.constructor?.[j4]||Xm(e)||p1(e):!1}var U0e=Object.prototype.constructor.toString(),F4=new WeakMap;function hF(e){if(!e||typeof e!="object")return!1;const t=Object.getPrototypeOf(e);if(t===null||t===Object.prototype)return!0;const n=Object.hasOwnProperty.call(t,"constructor")&&t.constructor;if(n===Object)return!0;if(typeof n!="function")return!1;let r=F4.get(n);return r===void 0&&(r=Function.toString.call(n),F4.set(n,r)),r===U0e}function H0(e,t,n=!0){h1(e)===0?(n?Reflect.ownKeys(e):Object.keys(e)).forEach(i=>{t(i,e[i],e)}):e.forEach((r,i)=>t(i,r,e))}function h1(e){const t=e[Ai];return t?t.type_:Array.isArray(e)?1:Xm(e)?2:p1(e)?3:0}function P2(e,t){return h1(e)===2?e.has(t):Object.prototype.hasOwnProperty.call(e,t)}function pF(e,t,n){const r=h1(e);r===2?e.set(t,n):r===3?e.add(n):e[t]=n}function z0e(e,t){return e===t?e!==0||1/e===1/t:e!==e&&t!==t}function Xm(e){return e instanceof Map}function p1(e){return e instanceof Set}function Sc(e){return e.copy_||e.base_}function O2(e,t){if(Xm(e))return new Map(e);if(p1(e))return new Set(e);if(Array.isArray(e))return Array.prototype.slice.call(e);const n=hF(e);if(t===!0||t==="class_only"&&!n){const r=Object.getOwnPropertyDescriptors(e);delete r[Ai];let i=Reflect.ownKeys(r);for(let s=0;s<i.length;s++){const o=i[s],a=r[o];a.writable===!1&&(a.writable=!0,a.configurable=!0),(a.get||a.set)&&(r[o]={configurable:!0,writable:!0,enumerable:a.enumerable,value:e[o]})}return Object.create(Qp(e),r)}else{const r=Qp(e);if(r!==null&&n)return{...e};const i=Object.create(r);return Object.assign(i,e)}}function jT(e,t=!1){return m1(e)||of(e)||!ou(e)||(h1(e)>
2251&&Object.defineProperties(e,{set:tv,add:tv,clear:tv,delete:tv}),Object.freeze(e),t&&Object.values(e).forEach(n=>jT(n,!0))),e}function B0e(){Ss(2)}var tv={value:B0e};function m1(e){return e===null||typeof e!="object"?!0:Object.isFrozen(e)}var H0e={};function au(e){const t=H0e[e];return t||Ss(0,e),t}var em;function mF(){return em}function V0e(e,t){return{drafts_:[],parent_:e,immer_:t,canAutoFreeze_:!0,unfinalizedDrafts_:0}}function U4(e,t){t&&(au("Patches"),e.patches_=[],e.inversePatches_=[],e.patchListener_=t)}function A2(e){I2(e),e.drafts_.forEach(W0e),e.drafts_=null}function I2(e){e===em&&(em=e.parent_)}function z4(e){return em=V0e(em,e)}function W0e(e){const t=e[Ai];t.type_===0||t.type_===1?t.revoke_():t.revoked_=!0}function B4(e,t){t.unfinalizedDrafts_=t.drafts_.length;const n=t.drafts_[0];return e!==void 0&&e!==n?(n[Ai].modified_&&(A2(t),Ss(4)),ou(e)&&(e=V0(t,e),t.parent_||W0(t,e)),t.patches_&&au("Patches").generateReplacementPatches_(n[Ai].base_,e,t.patches_,t.inversePatches_)):e=V0(t,n,[]),A2(t),t.patches_&&t.patchListener_(t.patches_,t.inversePatches_),e!==fF?e:void 0}function V0(e,t,n){if(m1(t))return t;const r=e.immer_.shouldUseStrictIteration(),i=t[Ai];if(!i)return H0(t,(s,o)=>H4(e,i,t,s,o,n),r),t;if(i.scope_!==e)return t;if(!i.modified_)return W0(e,i.base_,!0),i.base_;if(!i.finalized_){i.finalized_=!0,i.scope_.unfinalizedDrafts_--;const s=i.copy_;let o=s,a=!1;i.type_===3&&(o=new Set(s),s.clear(),a=!0),H0(o,(c,d)=>H4(e,i,s,c,d,n,a),r),W0(e,s,!1),n&&e.patches_&&au("Patches").generatePatches_(i,n,e.patches_,e.inversePatches_)}return i.copy_}function H4(e,t,n,r,i,s,o){if(i==null||typeof i!="object"&&!o)return;const a=m1(i);if(!(a&&!o)){if(of(i)){const c=s&&t&&t.type_!==3&&!P2(t.assigned_,r)?s.concat(r):void 0,d=V0(e,i,c);if(pF(n,r,d),of(d))e.canAutoFreeze_=!1;else return}else o&&n.add(i);if(ou(i)&&!a){if(!e.immer_.autoFreeze_&&e.unfinalizedDrafts_<1||t&&t.base_&&t.base_[r]===i&&a)return;V0(e,i),(!t||!t.scope_.parent_)&&typeof r!="symbol"&&(Xm(n)?n.has(r):Object.prototype.propertyIsEnumerable.call(n,r))&&W0(e,i)}}}function W0(e,t,n=!1){!e.parent_&&e.immer_.autoFreeze_&&e.canAutoFreeze_&&jT(t,n)}function q0e(e,t){const n=Array.isArray(e),r={type_:n?1:0,scope_:t?t.scope_:mF(),modified_:!1,finalized_:!1,assigned_:{},parent_:t,base_:e,draft_:null,copy_:null,revoke_:null,isManual_:!1};let i=r,s=FT;n&&(i=[r],s=tm);const{revoke:o,proxy:a}=Proxy.revocable(i,s);return r.draft_=a,r.revoke_=o,a}var FT={get(e,t){if(t===Ai)return e;const n=Sc(e);if(!P2(n,t))return K0e(e,n,t);const r=n[t];return e.finalized_||!ou(r)?r:r===PS(e.base_,t)?(OS(e),e.copy_[t]=D2(r,e)):r},has(e,t){return t in Sc(e)},ownKeys(e){return Reflect.ownKeys(Sc(e))},set(e,t,n){const r=gF(Sc(e),t);if(r?.set)return r.set.call(e.draft_,n),!0;if(!e.modified_){const i=PS(Sc(e),t),s=i?.[Ai];if(s&&s.base_===n)return e.copy_[t]=n,e.assigned_[t]=!1,!0;if(z0e(n,i)&&(n!==void 0||P2(e.base_,t)))return!0;OS(e),M2(e)}return e.copy_[t]===n&&(n!==void 0||t in e.copy_)||Number.isNaN(n)&&Number.isNaN(e.copy_[t])||(e.copy_[t]=n,e.assigned_[t]=!0),!0},deleteProperty(e,t){return PS(e.base_,t)!==void 0||t in e.base_?(e.assigned_[t]=!1,OS(e),M2(e)):delete e.assigned_[t],e.copy_&&delete e.copy_[t],!0},getOwnPropertyDescriptor(e,t){const n=Sc(e),r=Reflect.getOwnPropertyDescriptor(n,t);return r&&{writable:!0,configurable:e.type_!==1||t!=="length",enumerable:r.enumerable,value:n[t]}},defineProperty(){Ss(11)},getPrototypeOf(e){return Qp(e.base_)},setPrototypeOf(){Ss(12)}},tm={};H0(FT,(e,t)=>{tm[e]=function(){return arguments[0]=arguments[0][0],t.apply(this,arguments)}});tm.deleteProperty=function(e,t){return tm.set.call(this,e,t,void 0)};tm.set=function(e,t,n){return FT.set.call(this,e[0],t,n,e[0])};function PS(e,t){const n=e[Ai];return(n?Sc(n):e)[t]}function K0e(e,t,n){const r=gF(t,n);return r?"value"in r?r.value:r.get?.call(e.draft_):void 0}function gF(e,t){if(!(t in e))return;let n=Qp(e);for(;n;){const r=Object.getOwnPropertyDescriptor(n,t);if(r)return r;n=Qp(n)}}function M2(e){e.modified_||(e.modified_=!0,e.parent_&&M2(e.parent_))}function OS(e){e.copy_||(e.copy_=O2(e.base_,e.scope_.immer_.useStrictShallowCopy_))}var G0e=class{constructor(e){this.autoFreeze_=!0,this.useStrictShallowCopy_=!1,this.useStrictIteration_=!0,this.produce=(t,n,r)=>{if(typeof t=="function"&&typeof n!="function"){const s=n;n=t;const o=this;return function(c=s,...d){return o.produce(c,f=>n.call(this,f,...d))}}typeof n!="function"&&Ss(6),r!==void 0&&typeof r!="function"&&Ss(7);let i;if(ou(t)){const s=z4(this),o=D2(t,void 0);let a=!0;try{i=n(o),a=!1}finally{a?A2(s):I2(s)}return U4(s,r),B4(i,s)}else if(!t||typeof t!="object"){if(i=n(t),i===void 0&&(i=t),i===fF&&(i=void 0),this.autoFreeze_&&jT(i,!0),r){const s=[],o=[];au("Patches").generateReplacementPatches_(t,i,s,o),r(s,o)}return i}else Ss(1,t)},this.produceWithPatches=(t,n)=>{if(typeof t=="function")return(o,...a)=>this.produceWithPatches(o,c=>t(c,...a));let r,i;return[this.produce(t,n,(o,a)=>{r=o,i=a}),r,i]},typeof e?.autoFreeze=="boolean"&&this.setAutoFreeze(e.autoFreeze),typeof e?.useStrictShallowCopy=="boolean"&&this.setUseStrictShallowCopy(e.useStrictShallowCopy),typeof e?.useStrictIteration=="boolean"&&this.setUseStrictIteration(e.useStrictIteration)}createDraft(e){ou(e)||Ss(8),of(e)&&(e=Y0e(e));const t=z4(this),n=D2(e,void 0);return n[Ai].isManual_=!0,I2(t),n}finishDraft(e,t){const n=e&&e[Ai];(!n||!n.isManual_)&&Ss(9);const{scope_:r}=n;return U4(r,t),B4(void 0,r)}setAutoFreeze(e){this.autoFreeze_=e}setUseStrictShallowCopy(e){this.useStrictShallowCopy_=e}setUseStrictIteration(e){this.useStrictIteration_=e}shouldUseStrictIteration(){return this.useStrictIteration_}applyPatches(e,t){let n;for(n=t.length-1;n>=0;n--){const i=t[n];if(i.path.length===0&&i.op==="replace"){e=i.value;break}}n>
225-1&&(t=t.slice(n+1));const r=au("Patches").applyPatches_;return of(e)?r(e,t):this.produce(e,i=>r(i,t))}};function D2(e,t){const n=Xm(e)?au("MapSet").proxyMap_(e,t):p1(e)?au("MapSet").proxySet_(e,t):q0e(e,t);return(t?t.scope_:mF()).drafts_.push(n),n}function Y0e(e){return of(e)||Ss(10,e),yF(e)}function yF(e){if(!ou(e)||m1(e))return e;const t=e[Ai];let n,r=!0;if(t){if(!t.modified_)return t.base_;t.finalized_=!0,n=O2(e,t.scope_.immer_.useStrictShallowCopy_),r=t.scope_.immer_.shouldUseStrictIteration()}else n=O2(e,!0);return H0(n,(i,s)=>{pF(n,i,yF(s))},r),t&&(t.finalized_=!1),n}var J0e=new G0e,Z0e=J0e.produce;const X0e=e=>(t,n,r)=>(r.setState=(i,s,...o)=>{const a=typeof i=="function"?Z0e(i):i;return t(a,s,...o)},e(r.setState,n,r)),vF=X0e;function AS(e,t){return t.subjects.find(n=>n.topics.some(r=>r.name===e))?.id}function Q0e(e,t){for(const n of t.subjects)for(const r of n.topics)if(r.subtopics.some(i=>i.name===e))return{topic:r.name,subject:n.id}}function e_e(e,t){return t.subjects.flatMap(r=>r.topics).find(r=>r.name===e)?.subtopics[0]?.name??null}const KOe=(e,t)=>!!t&&e.length>0&&!e.includes(t),GOe=(e,t,n)=>e&&t!=null?t:n,V4=(e,t)=>
225!!t&&(!e||t.subject===e),t_e=!1,n_e={hasFullAccess:!1,isUpgradeDialogOpen:!1,topic:null,subtopic:null,subject:null,subjectLocked:!1,topicLocked:!1,subtopicLocked:!1,isQuestionTimerVisible:!0},q0=NT()(uF($T(vF((e,t)=>({...n_e,setIsUpgradeDialogOpen(n){e(r=>{r.isUpgradeDialogOpen=n},void 0,"AppStore/setIsUpgradeDialogOpen")},requireFullAccess(n){return()=>{t().hasFullAccess?n():e(r=>{r.isUpgradeDialogOpen=!0},void 0,"AppStore/requireFullAccess")}},setHasFullAccess(n){e(r=>{r.hasFullAccess=n},void 0,"AppStore/setHasFullAccess")},setIsQuestionTimerVisible(n){e(r=>{r.isQuestionTimerVisible=n},void 0,"AppStore/setIsQuestionTimerVisible")},setTopic(n){e(r=>{r.topic=n,r.subtopic=null},void 0,"AppStore/setTopic")},setSubtopic(n){e(r=>{r.subtopic=n},void 0,"AppStore/setSubtopic")},setSubject(n){e(r=>{r.subject=n},void 0,"AppStore/setSubject")},setSubjectLocked(n){e(r=>{r.subjectLocked=n},void 0,"AppStore/setSubjectLocked")},setTopicLocked(n){e(r=>{r.topicLocked=n,n?r.subjectLocked=!0:r.subtopicLocked=!1},void 0,"AppStore/setTopicLocked")},setSubtopicLocked(n){e(r=>{r.subtopicLocked=n,n&&(r.topicLocked=!0,r.subjectLocked=!0)},void 0,"AppStore/setSubtopicLocked")},changeSubject(n,r,i){e(s=>{if(s.subject=n,s.subjectLocked=n!==null,s.topicLocked=!1,s.subtopicLocked=!1,i&&V4(n,i))s.topic=i.topic,s.subtopic=i.subto
225pic;else{const a=r.subjects.filter(c=>!n||c.id===n)[0]?.topics[0];s.topic=a?.name??null,s.subtopic=a?.subtopics[0]?.name??null}},void 0,"AppStore/changeSubject")},changeTopic(n,r){e(i=>{i.topic=n,i.topicLocked=!0,i.subtopicLocked=!1;const s=AS(n,r);s&&(i.subject=s,i.subjectLocked=!0),i.subtopic=e_e(n,r)},void 0,"AppStore/changeTopic")},changeSubtopic(n,r){e(i=>{const s=Q0e(n,r);s&&(i.topic=s.topic,i.subject=s.subject,i.subjectLocked=!0),i.subtopic=n,i.topicLocked=!0,i.subtopicLocked=!0},void 0,"AppStore/changeSubtopic")},toggleSubjectLock(){const{subjectLocked:n,subject:r}=t();n?e(i=>{i.subjectLocked=!1,i.topicLocked=!1,i.subtopicLocked=!1},void 0,"AppStore/toggleSubjectLock"):r&&e(i=>{i.subjectLocked=!0},void 0,"AppStore/toggleSubjectLock")},toggleTopicLock(n){const{topicLocked:r,topic:i}=t();r?e(s=>{s.topicLocked=!1,s.subtopicLocked=!1},void 0,"AppStore/toggleTopicLock"):i&&n&&e(s=>{s.topicLocked=!0,s.subjectLocked=!0;const o=AS(i,n);o&&(s.subject=o)},void 0,"AppStore/toggleTopicLock")},toggleSubtopicLock(n){const{subtopicLocked:r,subtopic:i,topic:s}=t();r?e(o=>{o.subtopicLocked=!1},void 0,"AppStore/toggleSubtopicLock"):i&&n&&e(o=>{o.subtopicLocked=!0,o.topicLocked=!0,o.subjectLocked=!0;const a=AS(s??"",n);a&&(o.subject=a)},void 0,"AppStore/toggleSubtopicLock")},syncFromQuestion(n,r,i){const{subjectLocked:s,topicLocked:o,subtopicLocked:a,subject:c}=t();s&&!V4(c,{subject:n})||e(d=>{s||(d.subject=n),o||(d.topic=r),a||(d.subtopic=i)},void 0,"AppStore/syncFromQuestion")}})),{name:"app-store",partialize:e=>({topic:e.topic,subtopic:e.subtopic,subject:e.subject,subjectLocked:e.subjectLocked,topicLocked:e.topicLocked,subtopicLocked:e.subtopicLocked}),onRehydrateStorage:()=>e=>{e&&(typeof e.subjectLocked!="boolean"&&(e.subjectLocked=e.subject!=null),e.topicLocked&&!e.subjectLocked&&(e.topicLocked=!1,e.subtopicLocked=!1),e.subtopic&&!e.topic&&(e.subtopic=null,e.subtopicLocked=!1),e.topic&&e.subtopic&&!e.subject&&(e.topic=null,e.subtopic=null,e.topicLocked=!1,e.subtopicLocked=!1),e.subtopicLocked&&!e.topicLocked&&(e.subtopicLocked=!1))}}),{name:"AppStore",enabled:t_e})),r_e=5e3,i_e=()=>{const{logout:e}=km(),t=g.useCallback(()=>{e({logoutParams:{returnTo:window.location.origin}})},[e]);return g.useEffect(()=>{const n=setTimeout(t,r_e);return()=>clearTimeout(n)},[t]),j.jsxs("div",{className:"h-screen flex flex-col justify-center items-center text-center px-6",children:[j.jsx("h1",{className:"text-2xl font-bold mb-2",children:"PUEF Test Prep is for students only"}),j.jsx("p",{className:"text-lg font-medium max-w-md mb-6",children:"Your account doesn't have student access to this platform. You'll be signed out automatically. Please use the PUEF Admin platform instead."}),j.jsx(Kr,{onClick:t,children:"Log out now"})]})},s_e=({detail:e})=>{const{logout:t}=km(),n=()=>t({logoutParams:{returnTo:window.location.origin}});return j.jsxs("div",{className:"h-screen flex flex-col justify-center items-center text-center px-6",children:[j.jsx("h1",{className:"text-2xl font-bold mb-2",children:"Account not ready"}),j.jsx("p",{className:"text-lg font-medium max-w-md mb-6",children:e??"Your account isn't linked to a PUEF account yet. Please contact your school or district administrator, or sign in with a different account."}),j.jsx(Kr,{onClick:n,children:"Log out"})]})},o_e=()=>{const{data:e,status:t,error:n}=LT(),r=q0(o=>o.setHasFullAccess),i=Mi();g.useEffect(()=>{e&&r(k0e(e))},[e,r]);const s=t!=="pending"&&!e&&n?.statusCode!==403;return g.useEffect(()=>{s&&cF(`${i.pathname}${i.search}`)},[s,i]),t==="pending"?j.jsx("div",{className:"h-screen flex justify-center items-center",children:"Loading..."}):n?.statusCode===403?j.jsx(s_e,{detail:n?.message}):e?e.role!=="student"?j.jsx(i_e,{}):j.jsx(qm,{}):j.jsx(pj,{to:"/login",replace:!0})},a_e=()=>{const{isAuthenticated:e}=km();return e?j.jsx(pj,{to:"/",replace:!0}):j.jsx(qm,{})},l_e=e=>`https://ui-avatars.com/api/?name=${e}&background=213860&color=fff`,c_e=({icon:e,className:t,name:n,style:r,onClick:i})=>{const s=e||l_e(n||"");return j.jsx("div",{className:sn("size-12 rounded-full flex items-center justify-center",t),style:r,onClick:i,children:typeof s=="string"?j.jsx("img",{src:s,alt:"icon",className:"size-full rounded-full"}):e})},u_e=!1;var Fv={exports:{}},d_e=Fv.exports,W4;function f_e(){return W4||(W4=1,(function(e,t){(function(n,r){e.exports=r()})(d_e,(function(){var n=1e3,r=6e4,i=36e5,s="millisecond",o="second",a="minute",c="hour",d="day",f="week",p="month",m="quarter",v="year",w="date",_="Invalid Date",b=/^(\d{4})[-/]?(\d{1,2})?[-/]?(\d{0,2})[Tt\s]*(\d{1,2})?:?(\d{1,2})?:?(\d{1,2})?[.:]?(\d+)?$/,C=/\[([^\]]+)]|Y{1,4}|M{1,4}|D{1,2}|d{1,4}|H{1,2}|h{1,2}
vendor: 5,494 bytes, line 225
225|a|A|m{1,2}|s{1,2}|Z{1,2}|SSS/g,P={name:"en",weekdays:"Sunday_Monday_Tuesday_Wednesday_Thursday_Friday_Saturday".split("_"),months:"January_February_March_April_May_June_July_August_September_October_November_December".split("_"),ordinal:function(U){var q=["th","st","nd","rd"],z=U%100;return"["+U+(q[(z-20)%10]||q[z]||q[0])+"]"}},D=function(U,q,z){var x=String(U);return!x||x.length>=q?U:""+Array(q+1-x.length).join(z)+U},F={s:D,z:function(U){var q=-U.utcOffset(),z=Math.abs(q),x=Math.floor(z/60),N=z%60;return(q<=0?"+":"-")+D(x,2,"0")+":"+D(N,2,"0")},m:function U(q,z){if(q.date()<z.date())return-U(z,q);var x=12*(z.year()-q.year())+(z.month()-q.month()),N=q.clone().add(x,p),M=z-N<0,E=q.clone().add(x+(M?-1:1),p);return+(-(x+(z-N)/(M?N-E:E-N))||0)},a:function(U){return U<0?Math.ceil(U)||0:Math.floor(U)},p:function(U){return{M:p,y:v,w:f,d,D:w,h:c,m:a,s:o,ms:s,Q:m}[U]||String(U||"").toLowerCase().replace(/s$/,"")},u:function(U){return U===void 0}},R="en",I={};I[R]=P;var k="$isDayjsObject",L=function(U){return U instanceof K||!(!U||!U[k])},B=function U(q,z,x){var N;if(!q)return R;if(typeof q=="string"){var M=q.toLowerCase();I[M]&&(N=M),z&&(I[M]=z,N=M);var E=q.split("-");if(!N&&E.length>1)return U(E[0])}else{var O=q.name;I[O]=q,N=O}return!x&&N&&(R=N),N||!x&&R},A=function(U,q){if(L(U))return U.clone();var z=typeof q=="object"?q:{};return z.date=U,z.args=arguments,new K(z)},V=F;V.l=B,V.i=L,V.w=function(U,q){return A(U,{locale:q.$L,utc:q.$u,x:q.$x,$offset:q.$offset})};var K=(function(){function U(z){this.$L=B(z.locale,null,!0),this.parse(z),this.$x=this.$x||z.x||{},this[k]=!0}var q=U.prototype;return q.parse=function(z){this.$d=(function(x){var N=x.date,M=x.utc;if(N===null)return new Date(NaN);if(V.u(N))return new Date;if(N instanceof Date)return new Date(N);if(typeof N=="string"&&!/Z$/i.test(N)){var E=N.match(b);if(E){var O=E[2]-1||0,H=(E[7]||"0").substring(0,3);return M?new Date(Date.UTC(E[1],O,E[3]||1,E[4]||0,E[5]||0,E[6]||0,H)):new Date(E[1],O,E[3]||1,E[4]||0,E[5]||0,E[6]||0,H)}}return new Date(N)})(z),this.init()},q.init=function(){var z=this.$d;this.$y=z.getFullYear(),this.$M=z.getMonth(),this.$D=z.getDate(),this.$W=z.getDay(),this.$H=z.getHours(),this.$m=z.getMinutes(),this.$s=z.getSeconds(),this.$ms=z.getMilliseconds()},q.$utils=function(){return V},q.isValid=function(){return this.$d.toString()!==_},q.isSame=function(z,x){var N=A(z);return this.startOf(x)<=N&&N<=this.endOf(x)},q.isAfter=function(z,x){return A(z)<this.startOf(x)},q.isBefore=function(z,x){return this.endOf(x)<A(z)},q.$g=function(z,x,N){return V.u(z)?this[x]:this.set(N,z)},q.unix=function(){return Math.floor(this.valueOf()/1e3)},q.valueOf=function(){return this.$d.getTime()},q.startOf=function(z,x){var N=this,M=!!V.u(x)||x,E=V.p(z),O=function(xe,be){var rt=V.w(N.$u?Date.UTC(N.$y,be,xe):new Date(N.$y,be,xe),N);return M?rt:rt.endOf(d)},H=function(xe,be){return V.w(N.toDate()[xe].apply(N.toDate("s"),(M?[0,0,0,0]:[23,59,59,999]).slice(be)),N)},Z=this.$W,X=this.$M,te=this.$D,oe="set"+(this.$u?"UTC":"");switch(E){case v:return M?O(1,0):O(31,11);case p:return M?O(1,X):O(0,X+1);case f:var le=this.$locale().weekStart||0,ye=(Z<le?Z+7:Z)-le;return O(M?te-ye:te+(6-ye),X);case d:case w:return H(oe+"Hours",0);case c:return H(oe+"Minutes",1);case a:return H(oe+"Seconds",2);case o:return H(oe+"Milliseconds",3);default:return this.clone()}},q.endOf=function(z){return this.startOf(z,!1)},q.$set=function(z,x){var N,M=V.p(z),E="set"+(this.$u?"UTC":""),O=(N={},N[d]=E+"Date",N[w]=E+"Date",N[p]=E+"Month",N[v]=E+"FullYear",N[c]=E+"Hours",N[a]=E+"Minutes",N[o]=E+"Seconds",N[s]=E+"Milliseconds",N)[M],H=M===d?this.$D+(x-this.$W):x;if(M===p||M===v){var Z=this.clone().set(w,1);Z.$d[O](H),Z.init(),this.$d=Z.set(w,Math.min(this.$D,Z.daysInMonth())).$d}else O&&this.$d[O](H);return this.init(),this},q.set=function(z,x){return this.clone().$set(z,x)},q.get=function(z){return this[V.p(z)]()},q.add=function(z,x){var N,M=this;z=Number(z);var E=V.p(x),O=function(X){var te=A(M);return V.w(te.date(te.date()+Math.round(X*z)),M)};if(E===p)return this.set(p,this.$M+z);if(E===v)return this.set(v,this.$y+z);if(E===d)return O(1);if(E===f)return O(7);var H=(N={},N[a]=r,N[c]=i,N[o]=n,N)[E]||1,Z=this.$d.getTime()+z*H;return V.w(Z,this)},q.subtract=function(z,x){return this.add(-1*z,x)},q.format=function(z){var x=this,N=this.$locale();if(!this.isValid())return N.invalidDate||_;var M=z||"YYYY-MM-DDTHH:mm:ssZ",E=V.z(this),O=this.$H,H=this.$m,Z=this.$M,X=N.weekdays,te=N.months,oe=N.meridiem,le=function(be,rt,Ue,Ve){return be&&(be[rt]||be(x,M))||Ue[rt].slice(0,Ve)},ye=function(be){return V.s(O%12||12,be,"0")},xe=oe||function(be,rt,Ue){var Ve=be<12?"AM":"PM";return Ue?Ve.toLowerCase():Ve};return M.replace(C,(function(be,rt){return rt||(function(Ue){switch(Ue){case"YY":return String(x.$y).slice(-2);case"YYYY":return V.s(x.$y,4,"0");case"M":return Z+1;case"MM":return V.s(Z+1,2,"0");case"MMM":return le(N.monthsShort,Z,te,3);case"MMMM":return le(te,Z);case"D":return x.$D;case"DD":return V.s(x.$D,2,"0");case"d":return String(x.$W);case"dd":return le(N.weekdaysMin,x.$W,X,2);case"ddd":return le(N.weekdaysShort,x.$W,X,3);case"dddd":return X[x.$W];case"H":return String(O);case"HH":return V.s(O,2,"0");case"h":return ye(1);case"hh":return ye(2);case"a":return xe(O,H,!0);case"A":return xe(O,H,!1);case"m":return String(H);case"mm":return V.s(H,2,"0");case"s":return String(x.$s);case"ss":return V.s(x.$s,2,"0");case"SSS":return V.s(x.$ms,3,"0");case"Z":return E}return null})(be)||E.replace(":","")}))}
225,q.utcOffset=function(){return 15*-Math.round(this.$d.getTimezoneOffset()/15)},q.diff=function(z,x,N){var M,E=this,O=V.p(x),H=A(z),Z=(H.utcOffset()-this.utcOffset())*r,X=this-H,te=function(){return V.m(E,H)};switch(O){case v:M=te()/12;break;case p:M=te();break;case m:M=te()/3;break;case f:M=(X-Z)/6048e5;break;case d:M=(X-Z)/864e5;break;case c:M=X/i;break;case a:M=X/r;break;case o:M=X/n;break;default:M=X}return N?M:V.a(M)},q.daysInMonth=function(){return this.endOf(p).$D},q.$locale=function(){return I[this.$L]},q.locale=function(z,x){if(!z)return this.$L;var N=this.clone(),M=B(z,x,!0);return M&&(N.$L=M),N},q.clone=function(){return V.w(this.$d,this)},q.toDate=function(){return new Date(this.valueOf())},q.toJSON=function(){return this.isValid()?this.toISOString():null},q.toISOString=function(){return this.$d.toISOString()},q.toString=function(){return this.$d.toUTCString()},U})(),W=K.prototype;return A.prototype=W,[["$ms",s],["$s",o],["$m",a],["$H",c],["$W",d],["$M",p],["$y",v],["$D",w]].forEach((function(U){W[U[1]]=function(q){return this.$g(q,U[0],U[1])}})),A.extend=function(U,q){return U.$i||(U(q,K,A),U.$i=!0),A},A.locale=B,A.isDayjs=L,A.unix=function(U){return A(1e3*U)},A.en=I[R],A.Ls=I,A.p={},A}))})(Fv)),Fv.exports}var h_e=f_e();const ai=Pl(h_e),p_e=!1,L2="selected-test-store",m_e={testDefinitionId:null,testName:null},kl=NT()(uF($T(vF(e=>({...m_e,setSelectedTest(t,n){e(r=>{r.testDefinitionId=t,r.testName=n},void 0,"SelectedTestStore/setSelectedTest")},clearSelectedTest(){e(t=>{t.testDefinitionId=null,t.testName=null},void 0,"SelectedTestStore/clearSelectedTest")}})),{name:L2}),{name:"SelectedTestStore",enabled:p_e}));function q4(e){const t=g_e(e),n=g.forwardRef((r,i)=>{const{children:s,...o}=r,a=g.Children.toArray(s),c=a.find(v_e);if(c){const d=c.props.children,f=a.map(p=>p===c?g.Children.count(d)>1?g.Children.only(null):g.isValidElement(d)?d.props.children:null:p);return j.jsx(t,{...o,ref:i,children:g.isValidElement(d)?g.cloneElement(d,void 0,f):null})}return j.jsx(t,{...o,ref:i,children:s})});return n.displayName=`${e}.Slot`,n}function g_e(e){const t=g.forwardRef((n,r)=>{const{children:i,...s}=n;if(g.isValidElement(i)){const o=w_e(i),a=__e(s,i.props);return i.type!==g.Fragment&&(a.ref=r?Ol(r,o):o),g.cloneElement(i,a)}return g.Children.count(i)>1?g.Children.only(null):null});return t.displayName=`${e}.SlotClone`,t}var y_e=Symbol("radix.slottable");function v_e(e){return g.isValidElement(e)&&typeof e.type=="function"&&"__radixId"in e.type&&e.type.__radixId===y_e}function __e(e,t){const n={...t};for(const r in t){const i=e[r],s=t[r];/^on[A-Z]/.test(r)?i&&s?n[r]=(...a)=>{const c=s(...a);return i(...a),c}:i&&(n[r]=i):r==="style"?n[r]={...i,...s}:r==="className"&&(n[r]=[i,s].filter(Boolean).join(" "))}return{...e,...n}}function w_e(e){let t=Object.getOwnPropertyDescriptor(e.props,"ref")?.get,n=t&&"isReactWarning"in t&&t.isReactWarning;return n?e.ref:(t=Object.getOwnPropertyDescriptor(e,"ref")?.get,n=t&&"isReactWarning"in t&&t.isReactWarning,n?e.props.ref:e.props.ref||e.ref)}function _F(e){const t=e+"CollectionProvider",[n,r]=Al(t),[i,s]=n(t,{collectionRef:{current:null},itemMap:new Map}),o=_=>{const{scope:b,children:C}=_,P=bt.useRef(null),D=bt.useRef(new Map).current;return j.jsx(i,{scope:b,itemMap:D,collectionRef:P,children:C})};o.displayName=t;const a=e+"CollectionSlot",c=q4(a),d=bt.forwardRef((_,b)=>{const{scope:C,children:P}=_,D=s(a,C),F=lr(b,D.collectionRef);return j.jsx(c,{ref:F,children:P})});d.displayName=a;const f=e+"CollectionItemSlot",p="data-radix-collection-item",m=q4(f),v=bt.forwardRef((_,b)=>{const{scope:C,children:P,...D}=_,F=bt.useRef(null),R=lr(b,F),I=s(f,C);return bt.useEffect(()=>(I.itemMap.set(F,{ref:F,...D}),()=>void I.itemMap.delete(F))),j.jsx(m,{[p]:"",ref:R,children:P})});v.displayName=f;function w(_){const b=s(e+"CollectionConsumer",_);return bt.useCallback(()=>{const P=b.collectionRef.current;if(!P)return[];const D=Array.from(P.querySelectorAll(`[${p}]`));return Array.from(b.itemMap.values()).sort((I,k)=>D.indexOf(I.ref.current)-D.indexOf(k.ref.current))},[b.collectionRef,b.itemMap])}return[{Provider:o,Slot:d,ItemSlot:v},w,r]}var b_e=g.createContext(void 0);function UT(e){const t=g.useContext(b_e);return e||t||"ltr"}var IS=0;function wF(){g.useEffect(()=>{const e=document.querySelectorAll("[data-radix-focus-guard]");return document.body.insertAdjacentElement("afterbegin",e[0]??K4()),document.body.insertAdjacentElement("beforeend",e[1]??K4()),IS++,()=>{IS===1&&document.querySelectorAll("[data-radix-focus-guard]").forEach(t=>t.remove()),IS--}},[])}function K4(){const e=document.createElement("span");return e.setAttribute("data-radix-focus-guard",""),e.tabIndex=0,e.style.outline="none",e.style.opacity="0",e.
vendor: 4,723 bytes, line 225
225style.position="fixed",e.style.pointerEvents="none",e}var MS="focusScope.autoFocusOnMount",DS="focusScope.autoFocusOnUnmount",G4={bubbles:!1,cancelable:!0},S_e="FocusScope",zT=g.forwardRef((e,t)=>{const{loop:n=!1,trapped:r=!1,onMountAutoFocus:i,onUnmountAutoFocus:s,...o}=e,[a,c]=g.useState(null),d=Yo(i),f=Yo(s),p=g.useRef(null),m=lr(t,_=>c(_)),v=g.useRef({paused:!1,pause(){this.paused=!0},resume(){this.paused=!1}}).current;g.useEffect(()=>{if(r){let _=function(D){if(v.paused||!a)return;const F=D.target;a.contains(F)?p.current=F:Ja(p.current,{select:!0})},b=function(D){if(v.paused||!a)return;const F=D.relatedTarget;F!==null&&(a.contains(F)||Ja(p.current,{select:!0}))},C=function(D){if(document.activeElement===document.body)for(const R of D)R.removedNodes.length>0&&Ja(a)};document.addEventListener("focusin",_),document.addEventListener("focusout",b);const P=new MutationObserver(C);return a&&P.observe(a,{childList:!0,subtree:!0}),()=>{document.removeEventListener("focusin",_),document.removeEventListener("focusout",b),P.disconnect()}}},[r,a,v.paused]),g.useEffect(()=>{if(a){J4.add(v);const _=document.activeElement;if(!a.contains(_)){const C=new CustomEvent(MS,G4);a.addEventListener(MS,d),a.dispatchEvent(C),C.defaultPrevented||(E_e(R_e(bF(a)),{select:!0}),document.activeElement===_&&Ja(a))}return()=>{a.removeEventListener(MS,d),setTimeout(()=>{const C=new CustomEvent(DS,G4);a.addEventListener(DS,f),a.dispatchEvent(C),C.defaultPrevented||Ja(_??document.body,{select:!0}),a.removeEventListener(DS,f),J4.remove(v)},0)}}},[a,d,f,v]);const w=g.useCallback(_=>{if(!n&&!r||v.paused)return;const b=_.key==="Tab"&&!_.altKey&&!_.ctrlKey&&!_.metaKey,C=document.activeElement;if(b&&C){const P=_.currentTarget,[D,F]=x_e(P);D&&F?!_.shiftKey&&C===F?(_.preventDefault(),n&&Ja(D,{select:!0})):_.shiftKey&&C===D&&(_.preventDefault(),n&&Ja(F,{select:!0})):C===P&&_.preventDefault()}},[n,r,v.paused]);return j.jsx(yn.div,{tabIndex:-1,...o,ref:m,onKeyDown:w})});zT.displayName=S_e;function E_e(e,{select:t=!1}={}){const n=document.activeElement;for(const r of e)if(Ja(r,{select:t}),document.activeElement!==n)return}function x_e(e){const t=bF(e),n=Y4(t,e),r=Y4(t.reverse(),e);return[n,r]}function bF(e){const t=[],n=document.createTreeWalker(e,NodeFilter.SHOW_ELEMENT,{acceptNode:r=>{const i=r.tagName==="INPUT"&&r.type==="hidden";return r.disabled||r.hidden||i?NodeFilter.FILTER_SKIP:r.tabIndex>=0?NodeFilter.FILTER_ACCEPT:NodeFilter.FILTER_SKIP}});for(;n.nextNode();)t.push(n.currentNode);return t}function Y4(e,t){for(const n of e)if(!C_e(n,{upTo:t}))return n}function C_e(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 k_e(e){return e instanceof HTMLInputElement&&"select"in e}function Ja(e,{select:t=!1}={}){if(e&&e.focus){const n=document.activeElement;e.focus({preventScroll:!0}),e!==n&&k_e(e)&&t&&e.select()}}var J4=T_e();function T_e(){let e=[];return{add(t){const n=e[0];t!==n&&n?.pause(),e=Z4(e,t),e.unshift(t)},remove(t){e=Z4(e,t),e[0]?.resume()}}}function Z4(e,t){const n=[...e],r=n.indexOf(t);return r!==-1&&n.splice(r,1),n}function R_e(e){return e.filter(t=>t.tagName!=="A")}var LS="rovingFocusGroup.onEntryFocus",P_e={bubbles:!1,cancelable:!0},Qm="RovingFocusGroup",[N2,SF,O_e]=_F(Qm),[A_e,g1]=Al(Qm,[O_e]),[I_e,M_e]=A_e(Qm),EF=g.forwardRef((e,t)=>j.jsx(N2.Provider,{scope:e.__scopeRovingFocusGroup,children:j.jsx(N2.Slot,{scope:e.__scopeRovingFocusGroup,children:j.jsx(D_e,{...e,ref:t})})}));EF.displayName=Qm;var D_e=g.forwardRef((e,t)=>{const{__scopeRovingFocusGroup:n,orientation:r,loop:i=!1,dir:s,currentTabStopId:o,defaultCurrentTabStopId:a,onCurrentTabStopIdChange:c,onEntryFocus:d,preventScrollOnEntryFocus:f=!1,...p}=e,m=g.useRef(null),v=lr(t,m),w=UT(s),[_,b]=du({prop:o,defaultProp:a??null,onChange:c,caller:Qm}),[C,P]=g.useState(!1),D=Yo(d),F=SF(n),R=g.useRef(!1),[I,k]=g.useState(0);return g.useEffect(()=>{const L=m.current;if(L)return L.addEventListener(LS,D),()=>L.removeEventListener(LS,D)},[D]),j.jsx(I_e,{scope:n,orientation:r,dir:w,loop:i,currentTabStopId:_,onItemFocus:g.useCallback(L=>b(L),[b]),onItemShiftTab:g.useCallback(()=>P(!0),[]),onFocusableItemAdd:g.useCallback(()=>k(L=>L+1),[]),onFocusableItemRemove:g.useCallback(()=>k(L=>L-1),[]),children:j.jsx(yn.div,{tabIndex:C||I===0?-1:0,"data-orientation":r,...p,ref:v,style:{outline:"none",...e.style},onMouseDown:gt(e.onMouseDown,()=>{R.current=!0}),onFocus:gt(e.onFocus,L=>{const B=!R.current;if(L.target===L.currentTarget&&B&&!C){const A=new CustomEvent(LS,P_e);if(L.currentTarget.dispatchEvent(A),!A.defaultPrevented){const V=F().filter(z=>z.focusable),K=V.find(z=>z.active),W=V.find(z=>
vendor: 10,392 bytes, lines 225-240
225z.id===_),q=[K,W,...V].filter(Boolean).map(z=>z.ref.current);kF(q,f)}}R.current=!1}),onBlur:gt(e.onBlur,()=>P(!1))})})}),xF="RovingFocusGroupItem",CF=g.forwardRef((e,t)=>{const{__scopeRovingFocusGroup:n,focusable:r=!0,active:i=!1,tabStopId:s,children:o,...a}=e,c=Lc(),d=s||c,f=M_e(xF,n),p=f.currentTabStopId===d,m=SF(n),{onFocusableItemAdd:v,onFocusableItemRemove:w,currentTabStopId:_}=f;return g.useEffect(()=>{if(r)return v(),()=>w()},[r,v,w]),j.jsx(N2.ItemSlot,{scope:n,id:d,focusable:r,active:i,children:j.jsx(yn.span,{tabIndex:p?0:-1,"data-orientation":f.orientation,...a,ref:t,onMouseDown:gt(e.onMouseDown,b=>{r?f.onItemFocus(d):b.preventDefault()}),onFocus:gt(e.onFocus,()=>f.onItemFocus(d)),onKeyDown:gt(e.onKeyDown,b=>{if(b.key==="Tab"&&b.shiftKey){f.onItemShiftTab();return}if(b.target!==b.currentTarget)return;const C=$_e(b,f.orientation,f.dir);if(C!==void 0){if(b.metaKey||b.ctrlKey||b.altKey||b.shiftKey)return;b.preventDefault();let D=m().filter(F=>F.focusable).map(F=>F.ref.current);if(C==="last")D.reverse();else if(C==="prev"||C==="next"){C==="prev"&&D.reverse();const F=D.indexOf(b.currentTarget);D=f.loop?j_e(D,F+1):D.slice(F+1)}setTimeout(()=>kF(D))}}),children:typeof o=="function"?o({isCurrentTabStop:p,hasTabStop:_!=null}):o})})});CF.displayName=xF;var L_e={ArrowLeft:"prev",ArrowUp:"prev",ArrowRight:"next",ArrowDown:"next",PageUp:"first",Home:"first",PageDown:"last",End:"last"};function N_e(e,t){return t!=="rtl"?e:e==="ArrowLeft"?"ArrowRight":e==="ArrowRight"?"ArrowLeft":e}function $_e(e,t,n){const r=N_e(e.key,n);if(!(t==="vertical"&&["ArrowLeft","ArrowRight"].includes(r))&&!(t==="horizontal"&&["ArrowUp","ArrowDown"].includes(r)))return L_e[r]}function kF(e,t=!1){const n=document.activeElement;for(const r of e)if(r===n||(r.focus({preventScroll:t}),document.activeElement!==n))return}function j_e(e,t){return e.map((n,r)=>e[(t+r)%e.length])}var TF=EF,RF=CF;function F_e(e){const t=U_e(e),n=g.forwardRef((r,i)=>{const{children:s,...o}=r,a=g.Children.toArray(s),c=a.find(B_e);if(c){const d=c.props.children,f=a.map(p=>p===c?g.Children.count(d)>1?g.Children.only(null):g.isValidElement(d)?d.props.children:null:p);return j.jsx(t,{...o,ref:i,children:g.isValidElement(d)?g.cloneElement(d,void 0,f):null})}return j.jsx(t,{...o,ref:i,children:s})});return n.displayName=`${e}.Slot`,n}function U_e(e){const t=g.forwardRef((n,r)=>{const{children:i,...s}=n;if(g.isValidElement(i)){const o=V_e(i),a=H_e(s,i.props);return i.type!==g.Fragment&&(a.ref=r?Ol(r,o):o),g.cloneElement(i,a)}return g.Children.count(i)>1?g.Children.only(null):null});return t.displayName=`${e}.SlotClone`,t}var z_e=Symbol("radix.slottable");function B_e(e){return g.isValidElement(e)&&typeof e.type=="function"&&"__radixId"in e.type&&e.type.__radixId===z_e}function H_e(e,t){const n={...t};for(const r in t){const i=e[r],s=t[r];/^on[A-Z]/.test(r)?i&&s?n[r]=(...a)=>{const c=s(...a);return i(...a),c}:i&&(n[r]=i):r==="style"?n[r]={...i,...s}:r==="className"&&(n[r]=[i,s].filter(Boolean).join(" "))}return{...e,...n}}function V_e(e){let t=Object.getOwnPropertyDescriptor(e.props,"ref")?.get,n=t&&"isReactWarning"in t&&t.isReactWarning;return n?e.ref:(t=Object.getOwnPropertyDescriptor(e,"ref")?.get,n=t&&"isReactWarning"in t&&t.isReactWarning,n?e.props.ref:e.props.ref||e.ref)}var W_e=function(e){if(typeof document>"u")return null;var t=Array.isArray(e)?e[0]:e;return t.ownerDocument.body},td=new WeakMap,nv=new WeakMap,rv={},NS=0,PF=function(e){return e&&(e.host||PF(e.parentNode))},q_e=function(e,t){return t.map(function(n){if(e.contains(n))return n;var r=PF(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})},K_e=function(e,t,n,r){var i=q_e(t,Array.isArray(e)?e:[e]);rv[n]||(rv[n]=new WeakMap);var s=rv[n],o=[],a=new Set,c=new Set(i),d=function(p){!p||a.has(p)||(a.add(p),d(p.parentNode))};i.forEach(d);var f=function(p){!p||c.has(p)||Array.prototype.forEach.call(p.children,function(m){if(a.has(m))f(m);else try{var v=m.getAttribute(r),w=v!==null&&v!=="false",_=(td.get(m)||0)+1,b=(s.get(m)||0)+1;td.set(m,_),s.set(m,b),o.push(m),_===1&&w&&nv.set(m,!0),b===1&&m.setAttribute(n,"true"),w||m.setAttribute(r,"true")}catch(C){console.error("aria-hidden: cannot operate on ",m,C)}})};return f(t),a.clear(),NS++,function(){o.forEach(function(p){var m=td.get(p)-1,v=s.get(p)-1;td.set(p,m),s.set(p,v),m||(nv.has(p)||p.removeAttribute(r),nv.delete(p)),v||p.removeAttribute(n)}),NS--,NS||(td=new WeakMap,td=new WeakMap,nv=new WeakMap,rv={})}},OF=function(e,t,n){n===void 0&&(n="data-aria-hidden");var r=Array.from(Array.isArray(e)?e:[e]),i=W_e(e);return i?(r.push.apply(r,Array.from(i.querySelectorAll("[aria-live], script"))),K_e(r,i,n,"aria-hidden")):function(){return null}},Ws=function(){return Ws=Object.assign||function(t){for(var n,r=1,i=arguments.length;r<i;r++){n=arguments[r];for(var s in n)Object.prototype.hasOwnProperty.call(n,s)&&(t[s]=n[s])}return t},Ws.apply(this,arguments)};function AF(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 i=0,r=Object.getOwnPropertySymbols(e);i<r.length;i++)t.indexOf(r[i])<0&&Object.prototype.propertyIsEnumerable.call(e,r[i])&&(n[r[i]]=e[r[i]]);return n}function G_e(e,t,n){if(n||arguments.length===2)for(var r=0,i=t.length,s;r<i;r++)(s||!(r in t))&&(s||(s=Array.prototype.slice.call(t,0,r)),s[r]=t[r]);return e.concat(s||Array.prototype.slice.call(t))}var Uv="right-scroll-bar-position",zv="width-before-scroll-bar",Y_e="with-scroll-bars-hidden",J_e="--removed-body-scroll-bar-size";function $S(e,t){return typeof e=="function"?e(t):e&&(e.current=t),e}function Z_e(e,t){var n=g.useState(function(){return{value:e,callback:t,facade:{get current(){return n.value},set current(r){var i=n.value;i!==r&&(n.value=r,n.callback(r,i))}}}})[0];return n.callback=t,n.facade}var X_e=typeof window<"u"?g.useLayoutEffect:g.useEffect,X4=new WeakMap;function Q_e(e,t){var n=Z_e(null,function(r){return e.forEach(function(i){return $S(i,r)})});return X_e(function(){var r=X4.get(n);if(r){var i=new Set(r),s=new Set(e),o=n.current;i.forEach(function(a){s.has(a)||$S(a,null)}),s.forEach(function(a){i.has(a)||$S(a,o)})}X4.set(n,e)},[e]),n}function e1e(e){return e}function t1e(e,t){t===void 0&&(t=e1e);var n=[],r=!1,i={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(s){var o=t(s,r);return n.push(o),function(){n=n.filter(function(a){return a!==o})}},assignSyncMedium:function(s){for(r=!0;n.length;){var o=n;n=[],o.forEach(s)}n={push:function(a){return s(a)},filter:function(){return n}}},assignMedium:function(s){r=!0;var o=[];if(n.length){var a=n;n=[],a.forEach(s),o=n}var c=function(){var f=o;o=[],f.forEach(s)},d=function(){return Promise.resolve().then(c)};d(),n={push:function(f){o.push(f),d()},filter:function(f){return o=o.filter(f),n}}}};return i}function n1e(e){e===void 0&&(e={});var t=t1e(null);return t.options=Ws({async:!0,ssr:!1},e),t}var IF=function(e){var t=e.sideCar,n=AF(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 g.createElement(r,Ws({},n))};IF.isSideCarExport=!0;function r1e(e,t){return e.useMedium(t),IF}var MF=n1e(),jS=function(){},y1=g.forwardRef(function(e,t){var n=g.useRef(null),r=g.useState({onScrollCapture:jS,onWheelCapture:jS,onTouchMoveCapture:jS}),i=r[0],s=r[1],o=e.forwardProps,a=e.children,c=e.className,d=e.removeScrollBar,f=e.enabled,p=e.shards,m=e.sideCar,v=e.noRelative,w=e.noIsolation,_=e.inert,b=e.allowPinchZoom,C=e.as,P=C===void 0?"div":C,D=e.gapMode,F=AF(e,["forwardProps","children","className","removeScrollBar","enabled","shards","sideCar","noRelative","noIsolation","inert","allowPinchZoom","as","gapMode"]),R=m,I=Q_e([n,t]),k=Ws(Ws({},F),i);return g.createElement(g.Fragment,null,f&&g.createElement(R,{sideCar:MF,removeScrollBar:d,shards:p,noRelative:v,noIsolation:w,inert:_,setCallbacks:s,allowPinchZoom:!!b,lockRef:n,gapMode:D}),o?g.cloneElement(g.Children.only(a),Ws(Ws({},k),{ref:I})):g.createElement(P,Ws({},k,{className:c,ref:I}),a))});y1.defaultProps={enabled:!0,removeScrollBar:!0,inert:!1};y1.classNames={fullWidth:zv,zeroRight:Uv};var i1e=function(){if(typeof __webpack_nonce__<"u")return __webpack_nonce__};function s1e(){if(!document)return null;var e=document.createElement("style");e.type="text/css";var t=i1e();return t&&e.setAttribute("nonce",t),e}function o1e(e,t){e.styleSheet?e.styleSheet.cssText=t:e.appendChild(document.createTextNode(t))}function a1e(e){var t=document.head||document.getElementsByTagName("head")[0];t.appendChild(e)}var l1e=function(){var e=0,t=null;return{add:function(n){e==0&&(t=s1e())&&(o1e(t,n),a1e(t)),e++},remove:function(){e--,!e&&t&&(t.parentNode&&t.parentNode.removeChild(t),t=null)}}},c1e=function(){var e=l1e();return function(t,n){g.useEffect(function(){return e.add(t),function(){e.remove()}},[t&&n])}},DF=function(){var e=c1e(),t=function(n){var r=n.styles,i=n.dynamic;return e(r,i),null};return t},u1e={left:0,top:0,right:0,gap:0},FS=function(e){return parseInt(e||"",10)||0},d1e=function(e){var t=window.getComputedStyle(document.body),n=t[e==="padding"?"paddingLeft":"marginLeft"],r=t[e==="padding"?"paddingTop":"marginTop"],i=t[e==="padding"?"paddingRight":"marginRight"];return[FS(n),FS(r),FS(i)]},f1e=function(e){if(e===void 0&&(e="margin"),typeof window>"u")return u1e;var t=d1e(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])}},h1e=DF(),jd="data-scroll-locked",p1e=function(e,t,n,r){var i=e.left,s=e.top,o=e.right,a=e.gap;return n===void 0&&(n="margin"),` 226 .`.concat(Y_e,` { 227 overflow: hidden `).concat(r,`; 228 padding-right: `).concat(a,"px ").concat(r,`; 229 } 230 body[`).concat(jd,`] { 231 overflow: hidden `).concat(r,`; 232 overscroll-behavior: contain; 233 `).concat([t&&"position: relative ".concat(r,";"),n==="margin"&&` 234 padding-left: `.concat(i,`px; 235 padding-top: `).concat(s,`px; 236 padding-right: `).concat(o,`px; 237 margin-left:0; 238 margin-top:0; 239 margin-right: `).concat(a,"px ").concat(r,`; 240 `),n==="padding"&&"padding-right: ".concat(a,"px ").concat(r,";
240")].filter(Boolean).join(""),` 241 } 242 243 .`).concat(Uv,` { 244 right: `).concat(a,"px ").concat(r,`; 245 } 246 247 .`).concat(zv,` { 248 margin-right: `).concat(a,"px ").concat(r,`; 249 } 250 251 .`).concat(Uv," .").concat(Uv,` { 252 right: 0 `).concat(r,`; 253 } 254 255 .`).concat(zv," .").concat(zv,` { 256 margin-right: 0 `).concat(r,`; 257 } 258 259 body[`).concat(jd,`] { 260 `).concat(J_e,": ").concat(a,`px; 261 } 262`)},Q4=function(){var e=parseInt(document.body.getAttribute(jd)||"0",10);return isFinite(e)?e:0},m1e=function(){g.useEffect(function(){return document.body.setAttribute(jd,(Q4()+1).toString()),function(){var e=Q4()-1;e<=0?document.body.removeAttribute(jd):document.body.setAttribute(jd,e.toString())}},[])},g1e=function(e){var t=e.noRelative,n=e.noImportant,r=e.gapMode,i=r===void 0?"margin":r;m1e();var s=g.useMemo(function(){return f1e(i)},[i]);return g.createElement(h1e,{styles:p1e(s,!t,i,n?"":"!important")})},$2=!1;if(typeof window<"u")try{var iv=Object.defineProperty({},"passive",{get:function(){return $2=!0,!0}});window.addEventListener("test",iv,iv),window.removeEventListener("test",iv,iv)}catch{$2=!1}var nd=$2?{passive:!1}:!1,y1e=function(e){return e.tagName==="TEXTAREA"},LF=function(e,t){if(!(e instanceof Element))return!1;var n=window.getComputedStyle(e);return n[t]!=="hidden"&&!(n.overflowY===n.overflowX&&!y1e(e)&&n[t]==="visible")},v1e=function(e){return LF(e,"overflowY")},_1e=function(e){return LF(e,"overflowX")},eM=function(e,t){var n=t.ownerDocument,r=t;do{typeof ShadowRoot<"u"&&r instanceof ShadowRoot&&(r=r.host);var i=NF(e,r);if(i){var s=$F(e,r),o=s[1],a=s[2];if(o>a)return!0}r=r.parentNode}while(r&&r!==n.body);return!1},w1e=function(e){var t=e.scrollTop,n=e.scrollHeight,r=e.clientHeight;return[t,n,r]},b1e=function(e){var t=e.scrollLeft,n=e.scrollWidth,r=e.clientWidth;return[t,n,r]},NF=function(e,t){return e==="v"?v1e(t):_1e(t)},$F=function(e,t){return e==="v"?w1e(t):b1e(t)},S1e=function(e,t){return e==="h"&&t==="rtl"?-1:1},E1e=function(e,t,n,r,i){var s=S1e(e,window.getComputedStyle(t).direction),o=s*r,a=n.target,c=t.contains(a),d=!1,f=o>0,p=0,m=0;do{if(!a)break;var v=$F(e,a),w=v[0],_=v[1],b=v[2],C=_-b-s*w;(w||C)&&NF(e,a)&&(p+=C,m+=w);var P=a.parentNode;a=P&&P.nodeType===Node.DOCUMENT_FRAGMENT_NODE?P.host:P}while(!c&&a!==document.body||c&&(t.contains(a)||t===a));return(f&&Math.abs(p)<1||!f&&Math.abs(m)<1)&&(d=!0),d},sv=function(e){return"changedTouches"in e?[e.changedTouches[0].clientX,e.changedTouches[0].clientY]:[0,0]},tM=function(e){return[e.deltaX,e.deltaY]},nM=function(e){return e&&"current"in e?e.current:e},x1e=function(e,t){return e[0]===t[0]&&e[1]===t[1]},C1e=function(e){return` 263 .block-interactivity-`.concat(e,` {pointer-events: none;} 264 .allow-interactivity-`).concat(e,` {pointer-events: all;} 265`)},k1e=0,rd=[];function T1e(e){var t=g.useRef([]),n=g.useRef([0,0]),r=g.useRef(),i=g.useState(k1e++)[0],s=g.useState(DF)[0],o=g.useRef(e);g.useEffect(function(){o.current=e},[e]),g.useEffect(function(){if(e.inert){document.body.classList.add("block-interactivity-".concat(i));var _=G_e([e.lockRef.current],(e.shards||[]).map(nM),!0).filter(Boolean);return _.forEach(function(b){return b.classList.add("allow-interactivity-".concat(i))}),function(){document.body.classList.remove("block-interactivity-".concat(i)),_.forEach(function(b){return b.classList.remove("allow-interactivity-".concat(i))})}}},[e.inert,e.lockRef.current,e.shards]);var a=g.useCallback(function(_,b){if("touches"in _&&_.touches.length===2||_.type==="wheel"&&_.ctrlKey)return!o.current.allowPinchZoom;var C=sv(_),P=n.current,D="deltaX"in _?_.deltaX:P[0]-C[0],F="deltaY"in _?_.deltaY:P[1]-C[1],R,I=_.target,k=Math.abs(D)>Math.abs(F)?"h":"v";if("touches"in _&&k==="h"&&I.type==="range")return!1;var L=window.getSelection(),B=L&&L.anchorNode,A=B?B===I||B.contains(I):!1;if(A)return!1;var V=eM(k,I);if(!V)return!0;if(V?R=k:(R=k==="v"?"h":"v",V=eM(k,I)),!V)return!1;if(!r.current&&"changedTouches"in _&&(D||F)&&(r.current=R),!R)return!0;var K=r.current||R;return E1e(K,b,_,K==="h"?D:F)},[]),c=g.useCallback(function(_){var b=_;if(!(!rd.length||rd[rd.length-1]!==s)){var C="deltaY"in b?tM(b):sv(b),P=t.current.filter(function(R){return R.name===b.type&&(R.target===b.target||b.target===R.shadowParent)&&x1e(R.delta,C)})[0];if(P&&P.should){b.cancelable&&b.preventDefault();return}
vendor: 17,618 bytes, line 265
265if(!P){var D=(o.current.shards||[]).map(nM).filter(Boolean).filter(function(R){return R.contains(b.target)}),F=D.length>0?a(b,D[0]):!o.current.noIsolation;F&&b.cancelable&&b.preventDefault()}}},[]),d=g.useCallback(function(_,b,C,P){var D={name:_,delta:b,target:C,should:P,shadowParent:R1e(C)};t.current.push(D),setTimeout(function(){t.current=t.current.filter(function(F){return F!==D})},1)},[]),f=g.useCallback(function(_){n.current=sv(_),r.current=void 0},[]),p=g.useCallback(function(_){d(_.type,tM(_),_.target,a(_,e.lockRef.current))},[]),m=g.useCallback(function(_){d(_.type,sv(_),_.target,a(_,e.lockRef.current))},[]);g.useEffect(function(){return rd.push(s),e.setCallbacks({onScrollCapture:p,onWheelCapture:p,onTouchMoveCapture:m}),document.addEventListener("wheel",c,nd),document.addEventListener("touchmove",c,nd),document.addEventListener("touchstart",f,nd),function(){rd=rd.filter(function(_){return _!==s}),document.removeEventListener("wheel",c,nd),document.removeEventListener("touchmove",c,nd),document.removeEventListener("touchstart",f,nd)}},[]);var v=e.removeScrollBar,w=e.inert;return g.createElement(g.Fragment,null,w?g.createElement(s,{styles:C1e(i)}):null,v?g.createElement(g1e,{noRelative:e.noRelative,gapMode:e.gapMode}):null)}function R1e(e){for(var t=null;e!==null;)e instanceof ShadowRoot&&(t=e.host,e=e.host),e=e.parentNode;return t}const P1e=r1e(MF,T1e);var BT=g.forwardRef(function(e,t){return g.createElement(y1,Ws({},e,{ref:t,sideCar:P1e}))});BT.classNames=y1.classNames;var j2=["Enter"," "],O1e=["ArrowDown","PageUp","Home"],jF=["ArrowUp","PageDown","End"],A1e=[...O1e,...jF],I1e={ltr:[...j2,"ArrowRight"],rtl:[...j2,"ArrowLeft"]},M1e={ltr:["ArrowLeft"],rtl:["ArrowRight"]},eg="Menu",[nm,D1e,L1e]=_F(eg),[wu,FF]=Al(eg,[L1e,T_,g1]),v1=T_(),UF=g1(),[N1e,bu]=wu(eg),[$1e,tg]=wu(eg),zF=e=>{const{__scopeMenu:t,open:n=!1,children:r,dir:i,onOpenChange:s,modal:o=!0}=e,a=v1(t),[c,d]=g.useState(null),f=g.useRef(!1),p=Yo(s),m=UT(i);return g.useEffect(()=>{const v=()=>{f.current=!0,document.addEventListener("pointerdown",w,{capture:!0,once:!0}),document.addEventListener("pointermove",w,{capture:!0,once:!0})},w=()=>f.current=!1;return document.addEventListener("keydown",v,{capture:!0}),()=>{document.removeEventListener("keydown",v,{capture:!0}),document.removeEventListener("pointerdown",w,{capture:!0}),document.removeEventListener("pointermove",w,{capture:!0})}},[]),j.jsx(p6,{...a,children:j.jsx(N1e,{scope:t,open:n,onOpenChange:p,content:c,onContentChange:d,children:j.jsx($1e,{scope:t,onClose:g.useCallback(()=>p(!1),[p]),isUsingKeyboardRef:f,dir:m,modal:o,children:r})})})};zF.displayName=eg;var j1e="MenuAnchor",HT=g.forwardRef((e,t)=>{const{__scopeMenu:n,...r}=e,i=v1(n);return j.jsx(m6,{...i,...r,ref:t})});HT.displayName=j1e;var VT="MenuPortal",[F1e,BF]=wu(VT,{forceMount:void 0}),HF=e=>{const{__scopeMenu:t,forceMount:n,children:r,container:i}=e,s=bu(VT,t);return j.jsx(F1e,{scope:t,forceMount:n,children:j.jsx(co,{present:n||s.open,children:j.jsx(R_,{asChild:!0,container:i,children:r})})})};HF.displayName=VT;var Xi="MenuContent",[U1e,WT]=wu(Xi),VF=g.forwardRef((e,t)=>{const n=BF(Xi,e.__scopeMenu),{forceMount:r=n.forceMount,...i}=e,s=bu(Xi,e.__scopeMenu),o=tg(Xi,e.__scopeMenu);return j.jsx(nm.Provider,{scope:e.__scopeMenu,children:j.jsx(co,{present:r||s.open,children:j.jsx(nm.Slot,{scope:e.__scopeMenu,children:o.modal?j.jsx(z1e,{...i,ref:t}):j.jsx(B1e,{...i,ref:t})})})})}),z1e=g.forwardRef((e,t)=>{const n=bu(Xi,e.__scopeMenu),r=g.useRef(null),i=lr(t,r);return g.useEffect(()=>{const s=r.current;if(s)return OF(s)},[]),j.jsx(qT,{...e,ref:i,trapFocus:n.open,disableOutsidePointerEvents:n.open,disableOutsideScroll:!0,onFocusOutside:gt(e.onFocusOutside,s=>s.preventDefault(),{checkForDefaultPrevented:!1}),onDismiss:()=>n.onOpenChange(!1)})}),B1e=g.forwardRef((e,t)=>{const n=bu(Xi,e.__scopeMenu);return j.jsx(qT,{...e,ref:t,trapFocus:!1,disableOutsidePointerEvents:!1,disableOutsideScroll:!1,onDismiss:()=>n.onOpenChange(!1)})}),H1e=F_e("MenuContent.ScrollLock"),qT=g.forwardRef((e,t)=>{const{__scopeMenu:n,loop:r=!1,trapFocus:i,onOpenAutoFocus:s,onCloseAutoFocus:o,disableOutsidePointerEvents:a,onEntryFocus:c,onEscapeKeyDown:d,onPointerDownOutside:f,onFocusOutside:p,onInteractOutside:m,onDismiss:v,disableOutsideScroll:w,..._}=e,b=bu(Xi,n),C=tg(Xi,n),P=v1(n),D=UF(n),F=D1e(n),[R,I]=g.useState(null),k=g.useRef(null),L=lr(t,k,b.onContentChange),B=g.useRef(0),A=g.useRef(""),V=g.useRef(0),K=g.useRef(null),W=g.useRef("right"),U=g.useRef(0),q=w?BT:g.Fragment,z=w?{as:H1e,allowPinchZoom:!0}:void 0,x=M=>{const E=A.current+M,O=F().filter(le=>!le.disabled),H=document.activeElement,Z=O.find(le=>le.ref.current===H)?.textValue,X=O.map(le=>le.textValue),te=twe(X,E,Z),oe=O.find(le=>le.textValue===te)?.ref.current;(function le(ye){A.current=ye,window.clearTimeout(B.current),ye!==""&&(B.current=window.setTimeout(()=>le(""),1e3))})(E),oe&&setTimeout(()=>oe.focus())};g.useEffect(()=>()=>window.clearTimeout(B.current),[]),wF();const N=g.useCallback(M=>W.current===K.current?.side&&rwe(M,K.current?.area),[]);return j.jsx(U1e,{scope:n,searchRef:A,onItemEnter:g.useCallback(M=>{N(M)&&M.preventDefault()},[N]),onItemLeave:g.useCallback(M=>{N(M)||(k.current?.focus(),I(null))},[N]),onTriggerLeave:g.useCallback(M=>{N(M)&&M.preventDefault()},[N]),pointerGraceTimerRef:V,onPointerGraceIntentChange:g.useCallback(M=>{K.current=M},[]),children:j.jsx(q,{...z,children:j.jsx(zT,{asChild:!0,trapped:i,onMountAutoFocus:gt(s,M=>{M.preventDefault(),k.current?.focus({preventScroll:!0})}),onUnmountAutoFocus:o,children:j.jsx(S_,{asChild:!0,disableOutsidePointerEvents:a,onEscapeKeyDown:d,onPointerDownOutside:f,onFocusOutside:p,onInteractOutside:m,onDismiss:v,children:j.jsx(TF,{asChild:!0,...D,dir:C.dir,orientation:"vertical",loop:r,currentTabStopId:R,onCurrentTabStopIdChange:I,onEntryFocus:gt(c,M=>{C.isUsingKeyboardRef.current||M.preventDefault()}),preventScrollOnEntryFocus:!0,children:j.jsx(g6,{role:"menu","aria-orientation":"vertical","data-state":oU(b.open),"data-radix-menu-content":"",dir:C.dir,...P,..._,ref:L,style:{outline:"none",..._.style},onKeyDown:gt(_.onKeyDown,M=>{const O=M.target.closest("[data-radix-menu-content]")===M.currentTarget,H=M.ctrlKey||M.altKey||M.metaKey,Z=M.key.length===1;O&&(M.key==="Tab"&&M.preventDefault(),!H&&Z&&x(M.key));const X=k.current;if(M.target!==X||!A1e.includes(M.key))return;M.preventDefault();const oe=F().filter(le=>!le.disabled).map(le=>le.ref.current);jF.includes(M.key)&&oe.reverse(),Q1e(oe)}),onBlur:gt(e.onBlur,M=>{M.currentTarget.contains(M.target)||(window.clearTimeout(B.current),A.current="")}),onPointerMove:gt(e.onPointerMove,rm(M=>{const E=M.target,O=U.current!==M.clientX;if(M.currentTarget.contains(E)&&O){const H=M.clientX>U.current?"right":"left";W.current=H,U.current=M.clientX}}))})})})})})})});VF.displayName=Xi;var V1e="MenuGroup",KT=g.forwardRef((e,t)=>{const{__scopeMenu:n,...r}=e;return j.jsx(yn.div,{role:"group",...r,ref:t})});KT.displayName=V1e;var W1e="MenuLabel",WF=g.forwardRef((e,t)=>{const{__scopeMenu:n,...r}=e;return j.jsx(yn.div,{...r,ref:t})});WF.displayName=W1e;var K0="MenuItem",rM="menu.itemSelect",_1=g.forwardRef((e,t)=>{const{disabled:n=!1,onSelect:r,...i}=e,s=g.useRef(null),o=tg(K0,e.__scopeMenu),a=WT(K0,e.__scopeMenu),c=lr(t,s),d=g.useRef(!1),f=()=>{const p=s.current;if(!n&&p){const m=new CustomEvent(rM,{bubbles:!0,cancelable:!0});p.addEventListener(rM,v=>r?.(v),{once:!0}),VD(p,m),m.defaultPrevented?d.current=!1:o.onClose()}};return j.jsx(qF,{...i,ref:c,disabled:n,onClick:gt(e.onClick,f),onPointerDown:p=>{e.onPointerDown?.(p),d.current=!0},onPointerUp:gt(e.onPointerUp,p=>{d.current||p.currentTarget?.click()}),onKeyDown:gt(e.onKeyDown,p=>{const m=a.searchRef.current!=="";n||m&&p.key===" "||j2.includes(p.key)&&(p.currentTarget.click(),p.preventDefault())})})});_1.displayName=K0;var qF=g.forwardRef((e,t)=>{const{__scopeMenu:n,disabled:r=!1,textValue:i,...s}=e,o=WT(K0,n),a=UF(n),c=g.useRef(null),d=lr(t,c),[f,p]=g.useState(!1),[m,v]=g.useState("");return g.useEffect(()=>{const w=c.current;w&&v((w.textContent??"").trim())},[s.children]),j.jsx(nm.ItemSlot,{scope:n,disabled:r,textValue:i??m,children:j.jsx(RF,{asChild:!0,...a,focusable:!r,children:j.jsx(yn.div,{role:"menuitem","data-highlighted":f?"":void 0,"aria-disabled":r||void 0,"data-disabled":r?"":void 0,...s,ref:d,onPointerMove:gt(e.onPointerMove,rm(w=>{r?o.onItemLeave(w):(o.onItemEnter(w),w.defaultPrevented||w.currentTarget.focus({preventScroll:!0}))})),onPointerLeave:gt(e.onPointerLeave,rm(w=>o.onItemLeave(w))),onFocus:gt(e.onFocus,()=>p(!0)),onBlur:gt(e.onBlur,()=>p(!1))})})})}),q1e="MenuCheckboxItem",KF=g.forwardRef((e,t)=>{const{checked:n=!1,onCheckedChange:r,...i}=e;return j.jsx(XF,{scope:e.__scopeMenu,checked:n,children:j.jsx(_1,{role:"menuitemcheckbox","aria-checked":G0(n)?"mixed":n,...i,ref:t,"data-state":YT(n),onSelect:gt(i.onSelect,()=>r?.(G0(n)?!0:!n),{checkForDefaultPrevented:!1})})})});KF.displayName=q1e;var GF="MenuRadioGroup",[K1e,G1e]=wu(GF,{value:void 0,onValueChange:()=>{}}),YF=g.forwardRef((e,t)=>{const{value:n,onValueChange:r,...i}=e,s=Yo(r);return j.jsx(K1e,{scope:e.__scopeMenu,value:n,onValueChange:s,children:j.jsx(KT,{...i,ref:t})})});YF.displayName=GF;var JF="MenuRadioItem",ZF=g.forwardRef((e,t)=>{const{value:n,...r}=e,i=G1e(JF,e.__scopeMenu),s=n===i.value;return j.jsx(XF,{scope:e.__scopeMenu,checked:s,children:j.jsx(_1,{role:"menuitemradio","aria-checked":s,...r,ref:t,"data-state":YT(s),onSelect:gt(r.onSelect,()=>i.onValueChange?.(n),{checkForDefaultPrevented:!1})})})});ZF.displayName=JF;var GT="MenuItemIndicator",[XF,Y1e]=wu(GT,{checked:!1}),QF=g.forwardRef((e,t)=>{const{__scopeMenu:n,forceMount:r,...i}=e,s=Y1e(GT,n);return j.jsx(co,{present:r||G0(s.checked)||s.checked===!0,children:j.jsx(yn.span,{...i,ref:t,"data-state":YT(s.checked)})})});QF.displayName=GT;var J1e="MenuSeparator",eU=g.forwardRef((e,t)=>{const{__scopeMenu:n,...r}=e;return j.jsx(yn.div,{role:"separator","aria-orientation":"horizontal",...r,ref:t})});eU.displayName=J1e;var Z1e="MenuArrow",tU=g.forwardRef((e,t)=>{const{__scopeMenu:n,...r}=e,i=v1(n);return j.jsx(y6,{...i,...r,ref:t})});tU.displayName=Z1e;var X1e="MenuSub",[YOe,nU]=wu(X1e),np="MenuSubTrigger",rU=g.forwardRef((e,t)=>{const n=bu(np,e.__scopeMenu),r=tg(np,e.__scopeMenu),i=nU(np,e.__scopeMenu),s=WT(np,e.__scopeMenu),o=g.useRef(null),{pointerGraceTimerRef:a,onPointerGraceIntentChange:c}=s,d={__scopeMenu:e.__scopeMenu},f=g.useCallback(()=>{o.current&&window.clearTimeout(o.current),o.current=null},[]);return g.useEffect(()=>f,[f]),g.useEffect(()=>{const p=a.current;return()=>{window.clearTimeout(p),c(null)}},[a,c]),j.jsx(HT,{asChild:!0,...d,children:j.jsx(qF,{id:i.triggerId,"aria-haspopup":"menu","aria-expanded":n.open,"aria-controls":i.contentId,"data-state":oU(n.open),...e,ref:Ol(t,i.onTriggerChange),onClick:p=>{e.onClick?.(p),!(e.disabled||p.defaultPrevented)&&(p.currentTarget.focus(),n.open||n.onOpenChange(!0))},onPointerMove:gt(e.onPointerMove,rm(p=>{s.onItemEnter(p),!p.defaultPrevented&&!e.disabled&&!n.open&&!o.current&&(s.onPointerGraceIntentChange(null),o.current=window.setTimeout(()=>{n.onOpenChange(!0),f()},100))})),onPointerLeave:gt(e.onPointerLeave,rm(p=>{f();const m=n.content?.getBoundingClientRect();if(m){const v=n.content?.dataset.side,w=v==="right",_=w?-5:5,b=m[w?"left":"right"],C=m[w?"right":"left"];s.onPointerGraceIntentChange({area:[{x:p.clientX+_,y:p.clientY},{x:b,y:m.top},{x:C,y:m.top},{x:C,y:m.bottom},{x:b,y:m.bottom}],side:v}),window.clearTimeout(a.current),a.current=window.setTimeout(()=>s.onPointerGraceIntentChange(null),300)}else{if(s.onTriggerLeave(p),p.defaultPrevented)return;s.onPointerGraceIntentChange(null)}})),onKeyDown:gt(e.onKeyDown,p=>{const m=s.searchRef.current!=="";e.disabled||m&&p.key===" "||I1e[r.dir].includes(p.key)&&(n.onOpenChange(!0),n.content?.focus(),p.preventDefault())})})})});rU.displayName=np;var iU="MenuSubContent",sU=g.forwardRef((e,t)=>{const n=BF(Xi,e.__scopeMenu),{forceMount:r=n.forceMount,...i}=e,s=bu(Xi,e.__scopeMenu),o=tg(Xi,e.__scopeMenu),a=nU(iU,e.__scopeMenu),c=g.useRef(null),d=lr(t,c);return j.jsx(nm.Provider,{scope:e.__scopeMenu,children:j.jsx(co,{present:r||s.open,children:j.jsx(nm.Slot,{scope:e.__scopeMenu,children:j.jsx(qT,{id:a.contentId,"aria-labelledby":a.triggerId,...i,ref:d,align:"start",side:o.dir==="rtl"?"left":"right",disableOutsidePointerEvents:!1,disableOutsideScroll:!1,trapFocus:!1,onOpenAutoFocus:f=>{o.isUsingKeyboardRef.current&&c.current?.focus(),f.preventDefault()},onCloseAutoFocus:f=>f.preventDefault(),onFocusOutside:gt(e.onFocusOutside,f=>{f.target!==a.trigger&&s.onOpenChange(!1)}),onEscapeKeyDown:gt(e.onEscapeKeyDown,f=>{o.onClose(),f.preventDefault()}),onKeyDown:gt(e.onKeyDown,f=>{const p=f.currentTarget.contains(f.target),m=M1e[o.dir].includes(f.key);p&&m&&(s.onOpenChange(!1),a.trigger?.focus(),f.preventDefault())})})})})})});sU.displayName=iU;function oU(e){return e?"open":"closed"}function G0(e){return e==="indeterminate"}function YT(e){return G0(e)?"indeterminate":e?"checked":"unchecked"}function Q1e(e){const t=document.activeElement;for(const n of e)if(n===t||(n.focus(),document.activeElement!==t))return}function ewe(e,t){return e.map((n,r)=>e[(t+r)%e.length])}function twe(e,t,n){const i=t.length>1&&Array.from(t).every(d=>d===t[0])?t[0]:t,s=n?e.indexOf(n):-1;let o=ewe(e,Math.max(s,0));i.length===1&&(o=o.filter(d=>d!==n));const c=o.find(d=>d.toLowerCase().startsWith(i.toLowerCase()));return c!==n?c:void 0}function nwe(e,t){const{x:n,y:r}=e;let i=!1;for(let s=0,o=t.length-1;s<t.length;o=s++){const a=t[s],c=t[o],d=a.x,f=a.y,p=c.x,m=c.y;f>r!=m>r&&n<(p-d)*(r-f)/(m-f)+d&&(i=!i)}return i}function rwe(e,t){if(!t)return!1;const n={x:e.clientX,y:e.clientY};return nwe(n,t)}function rm(e){return t=>t.pointerType==="mouse"?e(t):void 0}var iwe=zF,swe=HT,owe=HF,awe=VF,lwe=KT,cwe=WF,uwe=_1,dwe=KF,fwe=YF,hwe=ZF,pwe=QF,mwe=eU,gwe=tU,ywe=rU,vwe=sU,w1="DropdownMenu",[_we]=Al(w1,[FF]),Jr=FF(),[wwe,aU]=_we(w1),lU=e=>{const{__scopeDropdownMenu:t,children:n,dir:r,open:i,defaultOpen:s,onOpenChange:o,modal:a=!0}=e,c=Jr(t),d=g.useRef(null),[f,p]=du({prop:i,defaultProp:s??!1,onChange:o,caller:w1});return j.jsx(wwe,{scope:t,triggerId:Lc(),triggerRef:d,contentId:Lc(),open:f,onOpenChange:p,onOpenToggle:g.useCallback(()=>p(m=>!m),[p]),modal:a,children:j.jsx(iwe,{...c,open:f,onOpenChange:p,dir:r,modal:a,children:n})})};lU.displayName=w1;var cU="DropdownMenuTrigger",uU=g.forwardRef((e,t)=>{const{__scopeDropdownMenu:n,disabled:r=!1,...i}=e,s=aU(cU,n),o=Jr(n);return j.jsx(swe,{asChild:!0,...o,children:j.jsx(yn.button,{type:"button",id:s.triggerId,"aria-haspopup":"menu","aria-expanded":s.open,"aria-controls":s.open?s.contentId:void 0,"data-state":s.open?"open":"closed","data-disabled":r?"":void 0,disabled:r,...i,ref:Ol(t,s.triggerRef),onPointerDown:gt(e.onPointerDown,a=>{!r&&a.button===0&&a.ctrlKey===!1&&(s.onOpenToggle(),s.open||a.preventDefault())}),onKeyDown:gt(e.onKeyDown,a=>{r||(["Enter"," "].includes(a.key)&&s.onOpenToggle(),a.key==="ArrowDown"&&s.onOpenChange(!0),["Enter"," ","ArrowDown"].includes(a.key)&&a.preventDefault())})})})});uU.displayName=cU;var bwe="DropdownMenuPortal",dU=e=>{const{__scopeDropdownMenu:t,...n}=e,r=Jr(t);return j.jsx(owe,{...r,...n})};dU.displayName=bwe;var fU="DropdownMenuContent",hU=g.forwardRef((e,t)=>{const{__scopeDropdownMenu:n,...r}=e,i=aU(fU,n),s=Jr(n),o=g.useRef(!1);return j.jsx(awe,{id:i.contentId,"aria-labelledby":i.triggerId,...s,...r,ref:t,onCloseAutoFocus:gt(e.onCloseAutoFocus,a=>{o.current||i.triggerRef.current?.focus(),o.current=!1,a.preventDefault()}),onInteractOutside:gt(e.onInteractOutside,a=>{const c=a.detail.originalEvent,d=c.button===0&&c.ctrlKey===!0,f=c.button===2||d;(!i.modal||f)&&(o.current=!0)}),style:{...e.style,"--radix-dropdown-menu-content-transform-origin":"var(--radix-popper-transform-origin)","--radix-dropdown-menu-content-available-width":"var(--radix-popper-available-width)","--radix-dropdown-menu-content-available-height":"var(--radix-popper-available-height)","--radix-dropdown-menu-trigger-width":"var(--radix-popper-anchor-width)","--radix-dropdown-menu-trigger-height":"var(--radix-popper-anchor-height)"}})});hU.displayName=fU;var Swe="DropdownMenuGroup",Ewe=g.forwardRef((e,t)=>{const{__scopeDropdownMenu:n,...r}=e,i=Jr(n);return j.jsx(lwe,{...i,...r,ref:t})});Ewe.displayName=Swe;var xwe="DropdownMenuLabel",pU=g.forwardRef((e,t)=>{const{__scopeDropdownMenu:n,...r}=e,i=Jr(n);return j.jsx(cwe,{...i,...r,ref:t})});pU.displayName=xwe;var Cwe="DropdownMenuItem",mU=g.forwardRef((e,t)=>{const{__scopeDropdownMenu:n,...r}=e,i=Jr(n);return j.jsx(uwe,{...i,...r,ref:t})});mU.displayName=Cwe;var kwe="DropdownMenuCheckboxItem",Twe=g.forwardRef((e,t)=>{const{__scopeDropdownMenu:n,...r}=e,i=Jr(n);return j.jsx(dwe,{...i,...r,ref:t})});Twe.displayName=kwe;var Rwe="DropdownMenuRadioGroup",Pwe=g.forwardRef((e,t)=>{const{__scopeDropdownMenu:n,...r}=e,i=Jr(n);return j.jsx(fwe,{...i,...r,ref:t})});Pwe.displayName=Rwe;var Owe="DropdownMenuRadioItem",Awe=g.forwardRef((e,t)=>{const{__scopeDropdownMenu:n,...r}=e,i=Jr(n);return j.jsx(hwe,{...i,...r,ref:t})});Awe.displayName=Owe;var Iwe="DropdownMenuItemIndicator",Mwe=g.forwardRef((e,t)=>{const{__scopeDropdownMenu:n,...r}=e,i=Jr(n);return j.jsx(pwe,{...i,...r,ref:t})});Mwe.displayName=Iwe;var Dwe="DropdownMenuSeparator",gU=g.forwardRef((e,t)=>{const{__scopeDropdownMenu:n,...r}=e,i=Jr(n);return j.jsx(mwe,{...i,...r,ref:t})});gU.displayName=Dwe;var Lwe="DropdownMenuArrow",Nwe=g.forwardRef((e,t)=>{const{__scopeDropdownMenu:n,...r}=e,i=Jr(n);return j.jsx(gwe,{...i,...r,ref:t})});Nwe.displayName=Lwe;var $we="DropdownMenuSubTrigger",jwe=g.forwardRef((e,t)=>
265{const{__scopeDropdownMenu:n,...r}=e,i=Jr(n);return j.jsx(ywe,{...i,...r,ref:t})});jwe.displayName=$we;var Fwe="DropdownMenuSubContent",Uwe=g.forwardRef((e,t)=>{const{__scopeDropdownMenu:n,...r}=e,i=Jr(n);return j.jsx(vwe,{...i,...r,ref:t,style:{...e.style,"--radix-dropdown-menu-content-transform-origin":"var(--radix-popper-transform-origin)","--radix-dropdown-menu-content-available-width":"var(--radix-popper-available-width)","--radix-dropdown-menu-content-available-height":"var(--radix-popper-available-height)","--radix-dropdown-menu-trigger-width":"var(--radix-popper-anchor-width)","--radix-dropdown-menu-trigger-height":"var(--radix-popper-anchor-height)"}})});Uwe.displayName=Fwe;var zwe=lU,Bwe=uU,Hwe=dU,yU=hU,vU=pU,_U=mU,wU=gU;const bU=zwe,SU=Bwe,JT=g.forwardRef(({className:e,sideOffset:t=4,...n},r)=>j.jsx(Hwe,{children:j.jsx(yU,{ref:r,sideOffset:t,className:sn("z-50 max-h-[var(--radix-dropdown-menu-content-available-height)] min-w-[7rem] overflow-y-auto overflow-x-hidden rounded-[11px] border border-border bg-white p-1 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 origin-[--radix-dropdown-menu-content-transform-origin]",e),...n})}));JT.displayName=yU.displayName;const Fd=g.forwardRef(({className:e,inset:t,...n},r)=>j.jsx(_U,{ref:r,className:sn("relative flex cursor-default select-none items-center gap-2 rounded-sm px-4 py-2 text-sm font-medium text-secondary outline-none transition-colors focus:bg-gray-100 data-[disabled]:pointer-events-none data-[disabled]:opacity-50 [&_svg]:pointer-events-none [&_svg]:size-4 [&_svg]:shrink-0",t&&"pl-8",e),...n}));Fd.displayName=_U.displayName;const Vwe=g.forwardRef(({className:e,inset:t,...n},r)=>j.jsx(vU,{ref:r,className:sn("px-2 py-1.5 text-sm font-semibold",t&&"pl-8",e),...n}));Vwe.displayName=vU.displayName;const ZT=g.forwardRef(({className:e,...t},n)=>j.jsx(wU,{ref:n,className:sn("-mx-1 my-1 h-px bg-[#e9e8f1]",e),...t}));ZT.displayName=wU.displayName;function Wwe({title:e,titleId:t,...n},r){return g.createElement("svg",Object.assign({xmlns:"http://www.w3.org/2000/svg",viewBox:"0 0 20 20",fill:"currentColor","aria-hidden":"true","data-slot":"icon",ref:r,"aria-labelledby":t},n),e?g.createElement("title",{id:t},e):null,g.createElement("path",{fillRule:"evenodd",d:"M16.704 4.153a.75.75 0 0 1 .143 1.052l-8 10.5a.75.75 0 0 1-1.127.075l-4.5-4.5a.75.75 0 0 1 1.06-1.06l3.894 3.893 7.48-9.817a.75.75 0 0 1 1.05-.143Z",clipRule:"evenodd"}))}const qwe=g.forwardRef(Wwe);function Kwe({title:e,titleId:t,...n},r){return g.createElement("svg",Object.assign({xmlns:"http://www.w3.org/2000/svg",viewBox:"0 0 20 20",fill:"currentColor","aria-hidden":"true","data-slot":"icon",ref:r,"aria-labelledby":t},n),e?g.createElement("title",{id:t},e):null,g.createElement("path",{fillRule:"evenodd",d:"M5.22 8.22a.75.75 0 0 1 1.06 0L10 11.94l3.72-3.72a.75.75 0 1 1 1.06 1.06l-4.25 4.25a.75.75 0 0 1-1.06 0L5.22 9.28a.75.75 0 0 1 0-1.06Z",clipRule:"evenodd"}))}const Gwe=g.forwardRef(Kwe),XT=()=>As({queryKey:["available-tests"],queryFn:()=>eF(),select:e=>e.data,staleTime:1e3*60*60}),Ywe=new Map([["mathematics","math"],["ela","english"],["english language arts","english"]]),F2=e=>{const t=String(e??"").trim().toLowerCase();return Ywe.get(t)??t},JOe=(e,t)=>F2(e)===F2(t),EU=e=>g.createElement("svg",{width:13,height:19,viewBox:"0 0 13 19",fill:"none",xmlns:"http://www.w3.org/2000/svg",...e},g.createElement("g",{clipPath:"url(#clip0_1136_5073)"},g.createElement("path",{d:"M4.24907 2.24189C4.24907 1.00373 5.25686 3.05466e-07 6.50002 1.96784e-07C7.74319 8.81034e-08 8.75098 1.00373 8.75098 2.24189L8.75098 10.7058C8.75098 11.9439 7.74319 12.9477 6.50003 12.9477C5.25686 12.9477 4.24907 11.9439 4.24907 10.7058L4.24907 2.24189Z",fill:"currentColor"}),g.createElement("path",{d:"M10.749 4.23204C11.9922 4.23204 13 5.23577 13 6.47393C13 7.71209 11.9922 8.71582 10.749 8.71582L2.25095 8.71582C1.00779 8.71582 -8.77487e-08 7.71209 -1.95992e-07 6.47393C-3.04236e-07 5.23577 1.00779 4.23204 2.25095 4.23204L10.749 4.23204Z",fill:"currentColor"}),g.createElement("path",{d:"M10.749 14.5162C11.9922 14.5162 13 15.5199 13 16.7581C13 17.9963 11.9922 19 10.749 19L2.25095 19C1.00779 19 -8.77487e-08 17.9963 -1.95992e-07 16.7581C-3.04236e-07 15.52 1.00779 14.5162 2.25095 14.5162L10.749 14.5162Z",fill:"currentColor"})),g.createElement("defs",null,g.createElement("clipPath",{id:"clip0_1136_5073"},g.createElement("rect",{width:13,height:19,fill:"white",transform:"matrix(-1 8.74228e-08 8.74228e-08 1 13 0)"})))),Jwe=e=>g.createElement("svg",{width:19,height:17,viewBox:"0 0 19 17",fill:"none",xmlns:"http://www.w3.org/2000/svg",...e},g.createElement("g",{clipPath:"url(#clip0_1136_5080)"},g.createElement("path",{d:"M7.3187 3.4616C7.71485 3.4616 8.23274 3.13785 8.46837 2.83561C8.86992 2.3198 8.96073 1.65288 8.71087 1.0505C8.45364 0.431323 7.89501 0.0288598 7.25243 0H7.24457L1.60127 0.00157417L1.56985 0.00314834C0.843823 0.0692635 0.282242 0.545188 0.0672312 1.27508L0.0510318 1.32965L0.05005 1.38684C-0.0147479 5.62189 -0.0167114 10.2122 0.0446502 15.4201V15.4668L0.0559407 15.5119C0.221862 16.2092 0.755463 16.7235 1.41571 16.8226L1.44124 16.8263H7.4208L7.44387 16.8232C8.25925 16.7135 8.82917 16.014 8.82967 15.1225C8.82967 14.22 8.2617 13.5122 7.44731 13.402L7.42424 13.3988H3.27472V9.92567H6.93384C7.10614 9.92567 7.50229 9.72156 7.50573 9.71946C8.15027 9.3553 8.45953 8.57661 8.27496 7.78165C8.09627 7.01136 7.52438 6.49398 6.85137 6.49398H3.27472V3.4616H7.3187Z",fill:"currentColor"}),g.createElement("path",{d:"M18.972 8.76452C18.8905 6.7753 17.9436 5.35697 16.3742 4.87317C15.2702 4.53263 14.1711 4.66276 13.3052 5.22526C12.8835 4.76823 12.3087 4.5893 11.752 4.74619C11.1668 4.91095 10.7182 5.42623 10.5802 6.09053L10.5714 6.13251L10.564 15.4243V15.4516L10.5675 15.4789C10.7034 16.521 11.4869 16.9948 12.1594 16.9948H12.1643C12.9846 16.9917 13.6351 16.3672 13.7455 15.4763L13.7484 15.4422C13.7902 14.4557 13.7646 13.434 13.7401 12.4465C13.7136 11.374 13.6856 10.2647 13.746 9.21736C13.772 8.76295 13.8898 8.43762 14.0965 8.24977C14.2928 8.07136 14.5893 8.0021 14.9786 8.04408C15.3507 8.08396 15.738 8.27496 15.7901 9.38947C15.8382 10.4237 15.8161 11.5062 15.7945 12.5525C15.7749 13.5117 15.7542 14.504 15.7876 15.4684L15.7886 15.4915L15.792 15.514C15.9413 16.5441 16.7007 17.0001 17.3683 17.0001C17.3899 17.0001 17.412 17.0001 17.4336 16.9985C18.2779 16.9607 18.9107 16.2759 18.972 15.3341L18.9735 15.3136V15.2931C18.9401 14.2678 18.9593 13.2063 18.9779 12.1794C18.9981 11.056 19.0192 9.89425 18.973 8.764L18.972 8.76452Z",fill:"currentColor"})),g.createElement("defs",null,g.createElement("clipPath",{id:"clip0_1136_5080"},g.createElement("rect",{width:19,height:17,fill:"white"})))),Zwe=e=>g.createElement("svg",{width:22,height:14,viewBox:"0 0 22 14",fill:"none",xmlns:"http://www.w3.org/2000/svg",...e},g.createElement("g",{clipPath:"url(#clip0_1136_5245)"},g.createElement("path",{d:"M7.57463 0.473006C7.67481 0.56833 7.75419 0.646657 7.83048 0.76341L12.6261 11.7197C13.3721 13.5848 10.6556 14.909 9.54822 13.2301C9.37097 12.9619 9.30162 12.6042 9.1552 12.3508C9.13131 12.3094 9.08199 12.2577 9.03421 12.2451L3.65211 12.2348C3.36236 12.902 3.13425 13.6055 2.35591 13.8804C0.966462 14.3718 -0.275796 13.2042 0.0532635 11.8572L4.81654 0.906765C5.3529 -0.0782449 6.74004 -0.318401 7.57463 0.473006ZM5.18875 8.91247H7.50065C7.50604 8.91247 7.59467 8.87404 7.59698 8.85335C7.54997 8.69669 7.49294 8.5393 7.43129 8.38782C7.1662 7.74198 6.82095 6.85303 6.49883 6.25227C6.45798 6.17616 6.40558 6.07419 6.32621 6.02985C6.00794 6.80944 5.66886 7.58015 5.34288 8.35752C5.30204 8.45358 5.03 8.86591 5.18875 8.91173V8.91247Z",fill:"currentColor"}),g.createElement("path",{d:"M18.7996 12.4919C18.2817 12.4719 17.7554 12.517 17.2375 12.4934C12.6453 12.2783 10.644 7.04737 14.1966 4.29038C16.1132 2.80289 18.422 3.41104 20.7038 3.29503C21.3881 3.4369 21.9075 3.97116 21.9992 4.63916V12.6596C21.6525 14.5499 18.9283 14.3932 18.7988 12.4919H18.7996ZM17.0849 9.42529C17.6043 9.47776 18.2124 9.38613 18.7418 9.42529L18.7996 9.36987V6.37715L18.7418 6.32173H17.162C15.2701 6.32173 14.9996 9.21395 17.0849 9.42529Z",fill:"currentColor"})),g.createElement("defs",null,g.createElement("clipPath",{id:"clip0_1136_5245"},g.createElement("rect",{width:22,height:14,fill:"white"})))),Xwe=e=>g.createElement("svg",{width:18,height:18,viewBox:"0 0 18 18",fill:"none",xmlns:"http://www.w3.org/2000/svg",...e},g.createElement("path",{d:"M7.3125 1.5H10.6875C11.0327 1.5 11.3125 1.77982 11.3125 2.125C11.3125 2.47018 11.0327 2.75 10.6875 2.75H10.4375V6.28906C10.4375 6.5459 10.5133 6.79707 10.6554 7.01113L14.6009 12.9553C15.4331 14.209 14.5341 15.8848 13.0293 15.8848H4.97072C3.46589 15.8848 2.56694 14.209 3.39912 12.9553L7.34463 7.01113C7.48672 6.79707 7.5625 6.5459 7.5625 6.28906V2.75H7.3125C6.96732 2.75 6.6875 2.47018 6.6875 2.125C6.6875 1.77982 6.96732 1.5 7.3125 1.5Z",fill:"currentColor"}),g.createElement("path",{d:"M6.32812 10.9805H11.6719L13.5596 13.8248C13.8369 14.2427 13.5372 14.8013 13.0357 14.8013H4.96434C4.46279 14.8013 4.16309 14.2427 4.44043 13.8248L6.32812 10.9805Z",fill:"#fff",fillOpacity:.001}),g.createElement("circle",{cx:7.6875,cy:13.0625,r:.9375,fill:"#fff",fillOpacity:.45}),g.createElement("circle",{cx:10.4375,cy:13.8125,r:.625,fill:"#fff",fillOpacity:.45}),g.createElement("circle",{cx:9.90625,cy:11.9688,r:.4375,fill:"#fff",fillOpacity:.45}),g.createElement("path",{d:"M13.9375 3.5C13.9375 3.5 14.2188 4.28125 15 4.5625C14.2188 4.84375 13.9375 5.625 13.9375 5.625C13.9375 5.625 13.6562 4.84375 12.875 4.5625C13.6562 4.28125 13.9375 3.5 13.9375 3.5Z",fill:"currentColor"})),Qwe={math:EU,english:Jwe,reading:Zwe,science:Xwe},ebe={math:"Math",english:"English",reading:"Reading",science:"Science"},xU=F2,ZOe=e=>
265Qwe[xU(e)]??EU,tbe=new Set(["ap","ib","sat","act","psat","ela","ab","bc","hl","sl"]),nbe=new Set(["a","an","and","at","for","in","of","on","or","the","to"]),rbe=e=>e===e.toLowerCase(),iM=e=>e.split(/\s+/).filter(Boolean).map((t,n)=>tbe.has(t)?t.toUpperCase():n>0&&nbe.has(t)?t:t.charAt(0).toUpperCase()+t.slice(1)).join(" "),ibe=(e,t)=>{const n=xU(e);if(!n)return"";const r=t?.trim();return r?rbe(r)?iM(r):r:ebe[n]??iM(n)},CU=e=>({queryKey:["question-bank","structure",e],queryFn:()=>Gr.questionBank.getQuestionBankStructure({testDefinitionId:e||void 0}),staleTime:1/0}),sbe=()=>{const e=kl(t=>t.testDefinitionId);return As({...CU(e),select:t=>t.data})},XOe=()=>{const{data:e}=sbe();return g.useMemo(()=>{const t=new Map((e?.subjects??[]).map(n=>[n.id.trim().toLowerCase(),n.title]));return n=>ibe(n,t.get((n??"").trim().toLowerCase()))},[e])},obe="from-[#5685F3] to-[#00A75F]",abe="from-[#FACC15] to-[#06B6D4]",lbe="from-[#2D9CDB] to-[#E46F3D]",cbe="from-[#4F7EDB] to-[#B13F72]",ube="from-slate-500 to-slate-400",kU=e=>e.toLowerCase().split(/[^a-z0-9]+/).filter(Boolean);function dbe(e){const t=kU(e);return t.includes("psat")?abe:t.includes("ap")?cbe:t.includes("act")?lbe:t.includes("sat")?obe:ube}const fbe={sat_digital:"SAT",psat_89:"8/9",psat_10:"10",act:"ACT",ap_precalculus:"PC",ap_calculus_ab:"AB",ap_physics_1:"P1",ap_computer_science_principles:"CS",state_exams:"SE"},hbe=e=>{const t=kU(e);return t[0]==="course"&&t.shift(),t.join("_")},pbe=new Set(["ap","sat","psat","act","course","digital"]);function sM(e){const t=fbe[hbe(e.family)];if(t)return t;const n=e.name??e.family,r=n.split(/[\s_-]+/).filter(Boolean),i=r.filter(o=>!pbe.has(o.toLowerCase())),s=i.length>0?i:r;return s.length===0?n.slice(0,3).toUpperCase():s.length>=2?(s[0][0]+s[1][0]).toUpperCase():s[0].slice(0,3).toUpperCase()}function TU(e){return e.name??e.family}const mbe=async(e,t)=>{const n=q0.getState();n.setTopic(null),n.setSubtopic(null),n.setTopicLocked(!1),n.setSubtopicLocked(!1);try{const i=(await e.fetchQuery(CU(t))).data.subjects,s=n.subject,a=s&&i.some(c=>c.id===s)?s:i[0]?.id;a&&n.setSubject(a)}catch{}},RU=()=>{const e=Tm(),t=kl(n=>n.setSelectedTest);return g.useCallback(async n=>n.ready?(await mbe(e,n.testDefinitionId),t(n.testDefinitionId,TU(n)),!0):!1,[e,t])},oM=({family:e,label:t,className:n})=>j.jsx("span",{className:sn("flex size-8 shrink-0 items-center justify-center rounded-full bg-linear-to-br text-[10px] font-bold uppercase text-white",dbe(e),n),children:t}),gbe=()=>{const e=jl(),t=RU(),n=kl(c=>c.testDefinitionId),r=kl(c=>c.testName),{data:i=[],isError:s}=XT(),o=i.find(c=>c.testDefinitionId===n),a=async c=>{c.testDefinitionId!==n&&await t(c)};return j.jsxs(bU,{children:[j.jsxs(SU,{"aria-label":"Change test",className:"flex items-center gap-1.5 rounded-[54px] border border-[#E5E7EB] bg-white p-1.5 pr-2 shadow-sm transition-colors hover:bg-brand-gray/40",children:[o?j.jsx(oM,{family:o.family,label:sM(o)}):j.jsx("span",{className:"flex h-8 items-center rounded-full bg-brand-gray/60 px-3 text-xs font-semibold text-secondary",children:r??"Choose"}),j.jsx(Gwe,{className:"size-4 text-secondary/50"})]}),j.jsxs(JT,{align:"start",className:"min-w-[240px] p-2",children:[s&&j.jsx("p",{className:"px-4 py-2 text-sm text-error",children:"Couldn't load your tests."}),!s&&i.length===0&&j.jsx("p",{className:"px-4 py-2 text-sm text-secondary/50",children:"No tests available yet."}),i.map(c=>{const d=c.testDefinitionId===n;return j.jsxs(Fd,{disabled:!c.ready,onSelect:()=>a(c),className:"gap-3 rounded-[10px] py-2.5",title:c.ready?void 0:"Coming soon — no questions published yet",children:[j.jsx(oM,{family:c.family,label:sM(c)}),j.jsx("span",{className:"flex-1 text-[15px] font-semibold",children:TU(c)}),d&&j.jsx(qwe,{className:"size-5 text-secondary"}),!c.ready&&j.jsx("span",{className:"text-[11px] text-secondary/40",children:"Coming soon"})]},c.testDefinitionId)}),j.jsx(ZT,{}),j.jsx(Fd,{onSelect:()=>e("/select-test"),className:"rounded-[10px] py-2.5 text-[15px] font-semibold",children:"Browse exams"})]})]})},ybe="assignment-notification-store",vbe=NT()($T(e=>({isSeen:!1,markSeen:()=>e({isSeen:!0})}),{name:ybe,storage:dF(()=>sessionStorage)})),_be=()=>{vbe.persist.clearStorage()};var PU="Toggle",QT=g.forwardRef((e,t)=>
265{const{pressed:n,defaultPressed:r,onPressedChange:i,...s}=e,[o,a]=du({prop:n,onChange:i,defaultProp:r??!1,caller:PU});return j.jsx(yn.button,{type:"button","aria-pressed":o,"data-state":o?"on":"off","data-disabled":e.disabled?"":void 0,...s,ref:t,onClick:gt(e.onClick,()=>{e.disabled||a(!o)})})});QT.displayName=PU;var OU=QT,Fl="ToggleGroup",[AU]=Al(Fl,[g1]),IU=g1(),eR=bt.forwardRef((e,t)=>{const{type:n,...r}=e;if(n==="single"){const i=r;return j.jsx(wbe,{...i,ref:t})}if(n==="multiple"){const i=r;return j.jsx(bbe,{...i,ref:t})}throw new Error(`Missing prop \`type\` expected on \`${Fl}\``)});eR.displayName=Fl;var[MU,DU]=AU(Fl),wbe=bt.forwardRef((e,t)=>{const{value:n,defaultValue:r,onValueChange:i=()=>{},...s}=e,[o,a]=du({prop:n,defaultProp:r??"",onChange:i,caller:Fl});return j.jsx(MU,{scope:e.__scopeToggleGroup,type:"single",value:bt.useMemo(()=>o?[o]:[],[o]),onItemActivate:a,onItemDeactivate:bt.useCallback(()=>a(""),[a]),children:j.jsx(LU,{...s,ref:t})})}),bbe=bt.forwardRef((e,t)=>{const{value:n,defaultValue:r,onValueChange:i=()=>{},...s}=e,[o,a]=du({prop:n,defaultProp:r??[],onChange:i,caller:Fl}),c=bt.useCallback(f=>a((p=[])=>[...p,f]),[a]),d=bt.useCallback(f=>a((p=[])=>p.filter(m=>m!==f)),[a]);return j.jsx(MU,{scope:e.__scopeToggleGroup,type:"multiple",value:o,onItemActivate:c,onItemDeactivate:d,children:j.jsx(LU,{...s,ref:t})})});eR.displayName=Fl;var[Sbe,Ebe]=AU(Fl),LU=bt.forwardRef((e,t)=>{const{__scopeToggleGroup:n,disabled:r=!1,rovingFocus:i=!0,orientation:s,dir:o,loop:a=!0,...c}=e,d=IU(n),f=UT(o),p={role:"group",dir:f,...c};return j.jsx(Sbe,{scope:n,rovingFocus:i,disabled:r,children:i?j.jsx(TF,{asChild:!0,...d,orientation:s,dir:f,loop:a,children:j.jsx(yn.div,{...p,ref:t})}):j.jsx(yn.div,{...p,ref:t})})}),Y0="ToggleGroupItem",NU=bt.forwardRef((e,t)=>{const n=DU(Y0,e.__scopeToggleGroup),r=Ebe(Y0,e.__scopeToggleGroup),i=IU(e.__scopeToggleGroup),s=n.value.includes(e.value),o=r.disabled||e.disabled,a={...e,pressed:s,disabled:o},c=bt.useRef(null);return r.rovingFocus?j.jsx(RF,{asChild:!0,...i,focusable:!o,active:s,ref:c,children:j.jsx(aM,{...a,ref:t})}):j.jsx(aM,{...a,ref:t})});NU.displayName=Y0;var aM=bt.forwardRef((e,t)=>{const{__scopeToggleGroup:n,value:r,...i}=e,s=DU(Y0,n),o={role:"radio","aria-checked":e.pressed,"aria-pressed":void 0},a=s.type==="single"?o:void 0;return j.jsx(QT,{...a,...i,ref:t,onPressedChange:c=>{c?s.onItemActivate(r):s.onItemDeactivate(r)}})}),$U=eR,jU=NU;const FU=dk({base:["group inline-flex h-[38px] px-3 items-center justify-center gap-[9px] rounded-[11px] text-sm font-semibold transition-all duration-100 ease-in-out","outline-none focus-visible:ring-2 focus-visible:ring-secondary/30 focus-visible:ring-inset"],variants:{variant:{default:["border shadow-xs","text-secondary","bg-white","hover:bg-gray-50","disabled:pointer-events-none disabled:text-gray-400","data-[state=on]:bg-secondary data-[state=on]:text-white","data-[state=open]:bg-secondary data-[state=open]:text-white"],slider:["flex-1 relative","text-secondary"]}}}),xbe=bt.forwardRef(({className:e,variant:t="default",...n},r)=>j.jsx(OU,{ref:r,className:sn(FU({variant:t}),e),...n}));xbe.displayName=OU.displayName;const Cbe=dk({base:["flex items-center justify-center flex-nowrap overflow-hidden"],variants:{variant:{default:[],slider:["p-1 relative bg-brand-gray/40 rounded-[14px] border border-[#E5E7EF] shadow-sm"]}}}),UU=bt.forwardRef(({className:e,children:t,variant:n="default",...r},i)=>j.jsx($U,{ref:i,className:sn(Cbe({variant:n}),e),...r,children:t}));UU.displayName=$U.displayName;const zU=bt.forwardRef(({className:e,children:t,variant:n="default",...r},i)=>j.jsx(jU,{ref:i,className:sn(FU({variant:n}),e),...r,children:t}));zU.displayName=jU.displayName;const BU=g.createContext({});function kbe(e){const t=g.useRef(null);return t.current===null&&(t.current=e()),t.current}const tR=typeof window<"u",Tbe=tR?g.useLayoutEffect:g.useEffect,nR=g.createContext(null);function rR(e,t){e.indexOf(t)===-1&&e.push(t)}function iR(e,t){const n=e.indexOf(t);n>-1&&e.splice(n,1)}const aa=(e,t,n)=>n>t?t:n<e?e:n;let sR=()=>{};const la={},HU=e=>/^-?(?:\d+(?:\.\d+)?|\.\d+)$/u.test(e);function VU(e){return typeof e=="object"&&e!==null}const WU=e=>/^0[^.\s]+$/u.test(e);function oR(e){let t;return()=>(t===void 0&&(t=e()),t)}const Qi=e=>e,Rbe=(e,t)=>
vendor: 27,061 bytes, line 265
265n=>t(e(n)),ng=(...e)=>e.reduce(Rbe),im=(e,t,n)=>{const r=t-e;return r===0?1:(n-e)/r};class aR{constructor(){this.subscriptions=[]}add(t){return rR(this.subscriptions,t),()=>iR(this.subscriptions,t)}notify(t,n,r){const i=this.subscriptions.length;if(i)if(i===1)this.subscriptions[0](t,n,r);else for(let s=0;s<i;s++){const o=this.subscriptions[s];o&&o(t,n,r)}}getSize(){return this.subscriptions.length}clear(){this.subscriptions.length=0}}const eo=e=>e*1e3,Ji=e=>e/1e3;function qU(e,t){return t?e*(1e3/t):0}const KU=(e,t,n)=>(((1-3*n+3*t)*e+(3*n-6*t))*e+3*t)*e,Pbe=1e-7,Obe=12;function Abe(e,t,n,r,i){let s,o,a=0;do o=t+(n-t)/2,s=KU(o,r,i)-e,s>0?n=o:t=o;while(Math.abs(s)>Pbe&&++a<Obe);return o}function rg(e,t,n,r){if(e===t&&n===r)return Qi;const i=s=>Abe(s,0,1,e,n);return s=>s===0||s===1?s:KU(i(s),t,r)}const GU=e=>t=>t<=.5?e(2*t)/2:(2-e(2*(1-t)))/2,YU=e=>t=>1-e(1-t),JU=rg(.33,1.53,.69,.99),lR=YU(JU),ZU=GU(lR),XU=e=>(e*=2)<1?.5*lR(e):.5*(2-Math.pow(2,-10*(e-1))),cR=e=>1-Math.sin(Math.acos(e)),QU=YU(cR),ez=GU(cR),Ibe=rg(.42,0,1,1),Mbe=rg(0,0,.58,1),tz=rg(.42,0,.58,1),Dbe=e=>Array.isArray(e)&&typeof e[0]!="number",nz=e=>Array.isArray(e)&&typeof e[0]=="number",Lbe={linear:Qi,easeIn:Ibe,easeInOut:tz,easeOut:Mbe,circIn:cR,circInOut:ez,circOut:QU,backIn:lR,backInOut:ZU,backOut:JU,anticipate:XU},Nbe=e=>typeof e=="string",lM=e=>{if(nz(e)){sR(e.length===4);const[t,n,r,i]=e;return rg(t,n,r,i)}else if(Nbe(e))return Lbe[e];return e},ov=["setup","read","resolveKeyframes","preUpdate","update","preRender","render","postRender"];function $be(e,t){let n=new Set,r=new Set,i=!1,s=!1;const o=new WeakSet;let a={delta:0,timestamp:0,isProcessing:!1};function c(f){o.has(f)&&(d.schedule(f),e()),f(a)}const d={schedule:(f,p=!1,m=!1)=>{const w=m&&i?n:r;return p&&o.add(f),w.has(f)||w.add(f),f},cancel:f=>{r.delete(f),o.delete(f)},process:f=>{if(a=f,i){s=!0;return}i=!0,[n,r]=[r,n],n.forEach(c),n.clear(),i=!1,s&&(s=!1,d.process(f))}};return d}const jbe=40;function rz(e,t){let n=!1,r=!0;const i={delta:0,timestamp:0,isProcessing:!1},s=()=>n=!0,o=ov.reduce((D,F)=>(D[F]=$be(s),D),{}),{setup:a,read:c,resolveKeyframes:d,preUpdate:f,update:p,preRender:m,render:v,postRender:w}=o,_=()=>{const D=la.useManualTiming?i.timestamp:performance.now();n=!1,la.useManualTiming||(i.delta=r?1e3/60:Math.max(Math.min(D-i.timestamp,jbe),1)),i.timestamp=D,i.isProcessing=!0,a.process(i),c.process(i),d.process(i),f.process(i),p.process(i),m.process(i),v.process(i),w.process(i),i.isProcessing=!1,n&&t&&(r=!1,e(_))},b=()=>{n=!0,r=!0,i.isProcessing||e(_)};return{schedule:ov.reduce((D,F)=>{const R=o[F];return D[F]=(I,k=!1,L=!1)=>(n||b(),R.schedule(I,k,L)),D},{}),cancel:D=>{for(let F=0;F<ov.length;F++)o[ov[F]].cancel(D)},state:i,steps:o}}const{schedule:wn,cancel:Tl,state:wr,steps:US}=rz(typeof requestAnimationFrame<"u"?requestAnimationFrame:Qi,!0);let Bv;function Fbe(){Bv=void 0}const ci={now:()=>(Bv===void 0&&ci.set(wr.isProcessing||la.useManualTiming?wr.timestamp:performance.now()),Bv),set:e=>{Bv=e,queueMicrotask(Fbe)}},iz=e=>t=>typeof t=="string"&&t.startsWith(e),uR=iz("--"),Ube=iz("var(--"),dR=e=>Ube(e)?zbe.test(e.split("/*")[0].trim()):!1,zbe=/var\(--(?:[\w-]+\s*|[\w-]+\s*,(?:\s*[^)(\s]|\s*\((?:[^)(]|\([^)(]*\))*\))+\s*)\)$/iu,If={test:e=>typeof e=="number",parse:parseFloat,transform:e=>e},sm={...If,transform:e=>aa(0,1,e)},av={...If,default:1},Sp=e=>Math.round(e*1e5)/1e5,fR=/-?(?:\d+(?:\.\d+)?|\.\d+)/gu;function Bbe(e){return e==null}const Hbe=/^(?:#[\da-f]{3,8}|(?:rgb|hsl)a?\((?:-?[\d.]+%?[,\s]+){2}-?[\d.]+%?\s*(?:[,/]\s*)?(?:\b\d+(?:\.\d+)?|\.\d+)?%?\))$/iu,hR=(e,t)=>n=>!!(typeof n=="string"&&Hbe.test(n)&&n.startsWith(e)||t&&!Bbe(n)&&Object.prototype.hasOwnProperty.call(n,t)),sz=(e,t,n)=>r=>{if(typeof r!="string")return r;const[i,s,o,a]=r.match(fR);return{[e]:parseFloat(i),[t]:parseFloat(s),[n]:parseFloat(o),alpha:a!==void 0?parseFloat(a):1}},Vbe=e=>aa(0,255,e),zS={...If,transform:e=>Math.round(Vbe(e))},Mc={test:hR("rgb","red"),parse:sz("red","green","blue"),transform:({red:e,green:t,blue:n,alpha:r=1})=>"rgba("+zS.transform(e)+", "+zS.transform(t)+", "+zS.transform(n)+", "+Sp(sm.transform(r))+")"};function Wbe(e){let t="",n="",r="",i="";return e.length>5?(t=e.substring(1,3),n=e.substring(3,5),r=e.substring(5,7),i=e.substring(7,9)):(t=e.substring(1,2),n=e.substring(2,3),r=e.substring(3,4),i=e.substring(4,5),t+=t,n+=n,r+=r,i+=i),{red:parseInt(t,16),green:parseInt(n,16),blue:parseInt(r,16),alpha:i?parseInt(i,16)/255:1}}const U2={test:hR("#"),parse:Wbe,transform:Mc.transform},ig=e=>({test:t=>typeof t=="string"&&t.endsWith(e)&&t.split(" ").length===1,parse:parseFloat,transform:t=>`${t}${e}`}),Za=ig("deg"),to=ig("%"),at=ig("px"),qbe=ig("vh"),Kbe=ig("vw"),cM={...to,parse:e=>to.parse(e)/100,transform:e=>to.transform(e*100)},Ed={test:hR("hsl","hue"),parse:sz("hue","saturation","lightness"),transform:({hue:e,saturation:t,lightness:n,alpha:r=1})=>"hsla("+Math.round(e)+", "+to.transform(Sp(t))+", "+to.transform(Sp(n))+", "+Sp(sm.transform(r))+")"},Kn={test:e=>Mc.test(e)||U2.test(e)||Ed.test(e),parse:e=>Mc.test(e)?Mc.parse(e):Ed.test(e)?Ed.parse(e):U2.parse(e),transform:e=>typeof e=="string"?e:e.hasOwnProperty("red")?Mc.transform(e):Ed.transform(e),getAnimatableNone:e=>{const t=Kn.parse(e);return t.alpha=0,Kn.transform(t)}},Gbe=/(?:#[\da-f]{3,8}|(?:rgb|hsl)a?\((?:-?[\d.]+%?[,\s]+){2}-?[\d.]+%?\s*(?:[,/]\s*)?(?:\b\d+(?:\.\d+)?|\.\d+)?%?\))/giu;function Ybe(e){return isNaN(e)&&typeof e=="string"&&(e.match(fR)?.length||0)+(e.match(Gbe)?.length||0)>0}const oz="number",az="color",Jbe="var",Zbe="var(",uM="${}",Xbe=/var\s*\(\s*--(?:[\w-]+\s*|[\w-]+\s*,(?:\s*[^)(\s]|\s*\((?:[^)(]|\([^)(]*\))*\))+\s*)\)|#[\da-f]{3,8}|(?:rgb|hsl)a?\((?:-?[\d.]+%?[,\s]+){2}-?[\d.]+%?\s*(?:[,/]\s*)?(?:\b\d+(?:\.\d+)?|\.\d+)?%?\)|-?(?:\d+(?:\.\d+)?|\.\d+)/giu;function om(e){const t=e.toString(),n=[],r={color:[],number:[],var:[]},i=[];let s=0;const a=t.replace(Xbe,c=>(Kn.test(c)?(r.color.push(s),i.push(az),n.push(Kn.parse(c))):c.startsWith(Zbe)?(r.var.push(s),i.push(Jbe),n.push(c)):(r.number.push(s),i.push(oz),n.push(parseFloat(c))),++s,uM)).split(uM);return{values:n,split:a,indexes:r,types:i}}function lz(e){return om(e).values}function cz(e){const{split:t,types:n}=om(e),r=t.length;return i=>{let s="";for(let o=0;o<r;o++)if(s+=t[o],i[o]!==void 0){const a=n[o];a===oz?s+=Sp(i[o]):a===az?s+=Kn.transform(i[o]):s+=i[o]}return s}}const Qbe=e=>typeof e=="number"?0:Kn.test(e)?Kn.getAnimatableNone(e):e;function eSe(e){const t=lz(e);return cz(e)(t.map(Qbe))}const Rl={test:Ybe,parse:lz,createTransformer:cz,getAnimatableNone:eSe};function BS(e,t,n){return n<0&&(n+=1),n>1&&(n-=1),n<1/6?e+(t-e)*6*n:n<1/2?t:n<2/3?e+(t-e)*(2/3-n)*6:e}function tSe({hue:e,saturation:t,lightness:n,alpha:r}){e/=360,t/=100,n/=100;let i=0,s=0,o=0;if(!t)i=s=o=n;else{const a=n<.5?n*(1+t):n+t-n*t,c=2*n-a;i=BS(c,a,e+1/3),s=BS(c,a,e),o=BS(c,a,e-1/3)}return{red:Math.round(i*255),green:Math.round(s*255),blue:Math.round(o*255),alpha:r}}function J0(e,t){return n=>n>0?t:e}const kn=(e,t,n)=>e+(t-e)*n,HS=(e,t,n)=>{const r=e*e,i=n*(t*t-r)+r;return i<0?0:Math.sqrt(i)},nSe=[U2,Mc,Ed],rSe=e=>nSe.find(t=>t.test(e));function dM(e){const t=rSe(e);if(!t)return!1;let n=t.parse(e);return t===Ed&&(n=tSe(n)),n}const fM=(e,t)=>{const n=dM(e),r=dM(t);if(!n||!r)return J0(e,t);const i={...n};return s=>(i.red=HS(n.red,r.red,s),i.green=HS(n.green,r.green,s),i.blue=HS(n.blue,r.blue,s),i.alpha=kn(n.alpha,r.alpha,s),Mc.transform(i))},z2=new Set(["none","hidden"]);function iSe(e,t){return z2.has(e)?n=>n<=0?e:t:n=>n>=1?t:e}function sSe(e,t){return n=>kn(e,t,n)}function pR(e){return typeof e=="number"?sSe:typeof e=="string"?dR(e)?J0:Kn.test(e)?fM:lSe:Array.isArray(e)?uz:typeof e=="object"?Kn.test(e)?fM:oSe:J0}function uz(e,t){const n=[...e],r=n.length,i=e.map((s,o)=>pR(s)(s,t[o]));return s=>{for(let o=0;o<r;o++)n[o]=i[o](s);return n}}function oSe(e,t){const n={...e,...t},r={};for(const i in n)e[i]!==void 0&&t[i]!==void 0&&(r[i]=pR(e[i])(e[i],t[i]));return i=>{for(const s in r)n[s]=r[s](i);return n}}function aSe(e,t){const n=[],r={color:0,var:0,number:0};for(let i=0;i<t.values.length;i++){const s=t.types[i],o=e.indexes[s][r[s]],a=e.values[o]??0;n[i]=a,r[s]++}return n}const lSe=(e,t)=>{const n=Rl.createTransformer(t),r=om(e),i=om(t);return r.indexes.var.length===i.indexes.var.length&&r.indexes.color.length===i.indexes.color.length&&r.indexes.number.length>=i.indexes.number.length?z2.has(e)&&!i.values.length||z2.has(t)&&!r.values.length?iSe(e,t):ng(uz(aSe(r,i),i.values),n):J0(e,t)};function dz(e,t,n){return typeof e=="number"&&typeof t=="number"&&typeof n=="number"?kn(e,t,n):pR(e)(e,t)}const cSe=e=>{const t=({timestamp:n})=>e(n);return{start:(n=!0)=>wn.update(t,n),stop:()=>Tl(t),now:()=>wr.isProcessing?wr.timestamp:ci.now()}},fz=(e,t,n=10)=>{let r="";const i=Math.max(Math.round(t/n),2);for(let s=0;s<i;s++)r+=Math.round(e(s/(i-1))*1e4)/1e4+", ";return`linear(${r.substring(0,r.length-2)})`},Z0=2e4;function mR(e){let t=0;const n=50;let r=e.next(t);for(;!r.done&&t<Z0;)t+=n,r=e.next(t);return t>=Z0?1/0:t}function uSe(e,t=100,n){const r=n({...e,keyframes:[0,t]}),i=Math.min(mR(r),Z0);return{type:"keyframes",ease:s=>r.next(i*s).value/t,duration:Ji(i)}}const dSe=5;function hz(e,t,n){const r=Math.max(t-dSe,0);return qU(n-e(r),t-r)}const An={stiffness:100,damping:10,mass:1,velocity:0,duration:800,bounce:.3,visualDuration:.3,restSpeed:{granular:.01,default:2},restDelta:{granular:.005,default:.5},minDuration:.01,maxDuration:10,minDamping:.05,maxDamping:1},VS=.001;function fSe({duration:e=An.duration,bounce:t=An.bounce,velocity:n=An.velocity,mass:r=An.mass}){let i,s,o=1-t;o=aa(An.minDamping,An.maxDamping,o),e=aa(An.minDuration,An.maxDuration,Ji(e)),o<1?(i=d=>{const f=d*o,p=f*e,m=f-n,v=B2(d,o),w=Math.exp(-p);return VS-m/v*w},s=d=>{const p=d*o*e,m=p*n+n,v=Math.pow(o,2)*Math.pow(d,2)*e,w=Math.exp(-p),_=B2(Math.pow(d,2),o);return(-i(d)+VS>0?-1:1)*((m-v)*w)/_}):(i=d=>{const f=Math.exp(-d*e),p=(d-n)*e+1;return-VS+f*p},s=d=>{const f=Math.exp(-d*e),p=(n-d)*(e*e);return f*p});const a=5/e,c=pSe(i,s,a);if(e=eo(e),isNaN(c))return{stiffness:An.stiffness,damping:An.damping,duration:e};{const d=Math.pow(c,2)*r;return{stiffness:d,damping:o*2*Math.sqrt(r*d),duration:e}}}const hSe=12;function pSe(e,t,n){let r=n;for(let i=1;i<hSe;i++)r=r-e(r)/t(r);return r}function B2(e,t){return e*Math.sqrt(1-t*t)}const mSe=["duration","bounce"],gSe=["stiffness","damping","mass"];function hM(e,t){return t.some(n=>e[n]!==void 0)}function ySe(e){let t={velocity:An.velocity,stiffness:An.stiffness,damping:An.damping,mass:An.mass,isResolvedFromDuration:!1,...e};if(!hM(e,gSe)&&hM(e,mSe))if(e.visualDuration){const n=e.visualDuration,r=2*Math.PI/(n*1.2),i=r*r,s=2*aa(.05,1,1-(e.bounce||0))*Math.sqrt(i);t={...t,mass:An.mass,stiffness:i,damping:s}}else{const n=fSe(e);t={...t,...n,mass:An.mass},t.isResolvedFromDuration=!0}return t}function X0(e=An.visualDuration,t=An.bounce){const n=typeof e!="object"?{visualDuration:e,keyframes:[0,1],bounce:t}:e;let{restSpeed:r,restDelta:i}=n;const s=n.keyframes[0],o=n.keyframes[n.keyframes.length-1],a={done:!1,value:s},{stiffness:c,damping:d,mass:f,duration:p,velocity:m,isResolvedFromDuration:v}=ySe({...n,velocity:-Ji(n.velocity||0)}),w=m||0,_=d/(2*Math.sqrt(c*f)),b=o-s,C=Ji(Math.sqrt(c/f)),P=Math.abs(b)<5;r||(r=P?An.restSpeed.granular:An.restSpeed.default),i||(i=P?An.restDelta.granular:An.restDelta.default);let D;if(_<1){const R=B2(C,_);D=I=>{const k=Math.exp(-_*C*I);return o-k*((w+_*C*b)/R*Math.sin(R*I)+b*Math.cos(R*I))}}else if(_===1)D=R=>o-Math.exp(-C*R)*(b+(w+C*b)*R);else{const R=C*Math.sqrt(_*_-1);D=I=>{const k=Math.exp(-_*C*I),L=Math.min(R*I,300);return o-k*((w+_*C*b)*Math.sinh(L)+R*b*Math.cosh(L))/R}}const F={calculatedDuration:v&&p||null,next:R=>{const I=D(R);if(v)a.done=R>=p;else{let k=R===0?w:0;_<1&&(k=R===0?eo(w):hz(D,R,I));const L=Math.abs(k)<=r,B=Math.abs(o-I)<=i;a.done=L&&B}return a.value=a.done?o:I,a},toString:()=>{const R=Math.min(mR(F),Z0),I=fz(k=>F.next(R*k).value,R,30);return R+"ms "+I},toTransition:()=>{}};return F}X0.applyToOptions=e=>{const t=uSe(e,100,X0);return e.ease=t.ease,e.duration=eo(t.duration),e.type="keyframes",e};function H2({keyframes:e,velocity:t=0,power:n=.8,timeConstant:r=325,bounceDamping:i=10,bounceStiffness:s=500,modifyTarget:o,min:a,max:c,restDelta:d=.5,restSpeed:f}){const p=e[0],m={done:!1,value:p},v=L=>a!==void 0&&L<a||c!==void 0&&L>c,w=L=>a===void 0?c:c===void 0||Math.abs(a-L)<Math.abs(c-L)?a:c;let _=n*t;const b=p+_,C=o===void 0?b:o(b);C!==b&&(_=C-p);const P=L=>-_*Math.exp(-L/r),D=L=>C+P(L),F=L=>{const B=P(L),A=D(L);m.done=Math.abs(B)<=d,m.value=m.done?C:A};let R,I;const k=L=>{v(m.value)&&(R=L,I=X0({keyframes:[m.value,w(m.value)],velocity:hz(D,L,m.value),damping:i,stiffness:s,restDelta:d,restSpeed:f}))};return k(0),{calculatedDuration:null,next:L=>{let B=!1;return!I&&R===void 0&&(B=!0,F(L),k(L)),R!==void 0&&L>=R?I.next(L-R):(!B&&F(L),m)}}}function vSe(e,t,n){const r=[],i=n||la.mix||dz,s=e.length-1;for(let o=0;o<s;o++){let a=i(e[o],e[o+1]);if(t){const c=Array.isArray(t)?t[o]||Qi:t;a=ng(c,a)}r.push(a)}return r}function _Se(e,t,{clamp:n=!0,ease:r,mixer:i}={}){const s=e.length;if(sR(s===t.length),s===1)return()=>t[0];if(s===2&&t[0]===t[1])return()=>t[1];const o=e[0]===e[1];e[0]>e[s-1]&&(e=[...e].reverse(),t=[...t].reverse());const a=vSe(t,r,i),c=a.length,d=f=>{if(o&&f<e[0])return t[0];let p=0;if(c>1)for(;p<e.length-2&&!(f<e[p+1]);p++);const m=im(e[p],e[p+1],f);return a[p](m)};return n?f=>d(aa(e[0],e[s-1],f)):d}function wSe(e,t){const n=e[e.length-1];for(let r=1;r<=t;r++){const i=im(0,t,r);e.push(kn(n,1,i))}}function bSe(e){const t=[0];return wSe(t,e.length-1),t}function SSe(e,t){return e.map(n=>n*t)}function ESe(e,t){return e.map(()=>t||tz).splice(0,e.length-1)}function Ep({duration:e=300,keyframes:t,times:n,ease:r="easeInOut"}){const i=Dbe(r)?r.map(lM):lM(r),s={done:!1,value:t[0]},o=SSe(n&&n.length===t.length?n:bSe(t),e),a=_Se(o,t,{ease:Array.isArray(i)?i:ESe(t,i)});return{calculatedDuration:e,next:c=>(s.value=a(c),s.done=c>=e,s)}}const xSe=e=>e!==null;function gR(e,{repeat:t,repeatType:n="loop"},r,i=1){const s=e.filter(xSe),a=i<0||t&&n!=="loop"&&t%2===1?0:s.length-1;return!a||r===void 0?s[a]:r}const CSe={decay:H2,inertia:H2,tween:Ep,keyframes:Ep,spring:X0};function pz(e){typeof e.type=="string"&&(e.type=CSe[e.type])}class yR{constructor(){this.updateFinished()}get finished(){return this._finished}updateFinished(){this._finished=new Promise(t=>{this.resolve=t})}notifyFinished(){this.resolve()}then(t,n){return this.finished.then(t,n)}}const kSe=e=>e/100;class vR extends yR{constructor(t){super(),this.state="idle",this.startTime=null,this.isStopped=!1,this.currentTime=0,this.holdTime=null,this.playbackSpeed=1,this.stop=()=>{const{motionValue:n}=this.options;n&&n.updatedAt!==ci.now()&&this.tick(ci.now()),this.isStopped=!0,this.state!=="idle"&&(this.teardown(),this.options.onStop?.())},this.options=t,this.initAnimation(),this.play(),t.autoplay===!1&&this.pause()}initAnimation(){const{options:t}=this;pz(t);const{type:n=Ep,repeat:r=0,repeatDelay:i=0,repeatType:s,velocity:o=0}=t;let{keyframes:a}=t;const c=n||Ep;c!==Ep&&typeof a[0]!="number"&&(this.mixKeyframes=ng(kSe,dz(a[0],a[1])),a=[0,100]);const d=c({...t,keyframes:a});s==="mirror"&&(this.mirroredGenerator=c({...t,keyframes:[...a].reverse(),velocity:-o})),d.calculatedDuration===null&&(d.calculatedDuration=mR(d));const{calculatedDuration:f}=d;this.calculatedDuration=f,this.resolvedDuration=f+i,this.totalDuration=this.resolvedDuration*(r+1)-i,this.generator=d}updateTime(t){const n=Math.round(t-this.startTime)*this.playbackSpeed;this.holdTime!==null?this.currentTime=this.holdTime:this.currentTime=n}tick(t,n=!1){const{generator:r,totalDuration:i,mixKeyframes:s,mirroredGenerator:o,resolvedDuration:a,calculatedDuration:c}=this;if(this.startTime===null)return r.next(0);const{delay:d=0,keyframes:f,repeat:p,repeatType:m,repeatDelay:v,type:w,onUpdate:_,finalKeyframe:b}=this.options;this.speed>0?this.startTime=Math.min(this.startTime,t):this.speed<0&&(this.startTime=Math.min(t-i/this.speed,this.startTime)),n?this.currentTime=t:this.updateTime(t);const C=this.currentTime-d*(this.playbackSpeed>=0?1:-1),P=this.playbackSpeed>=0?C<0:C>i;this.currentTime=Math.max(C,0),this.state==="finished"&&this.holdTime===null&&(this.currentTime=i);let D=this.currentTime,F=r;if(p){const L=Math.min(this.currentTime,i)/a;let B=Math.floor(L),A=L%1;!A&&L>=1&&(A=1),A===1&&B--,B=Math.min(B,p+1),!!(B%2)&&(m==="reverse"?(A=1-A,v&&(A-=v/a)):m==="mirror"&&(F=o)),D=aa(0,1,A)*a}const R=P?{done:!1,value:f[0]}:F.next(D);s&&(R.value=s(R.value));let{done:I}=R;!P&&c!==null&&(I=this.playbackSpeed>=0?this.currentTime>=i:this.currentTime<=0);const k=this.holdTime===null&&(this.state==="finished"||this.state==="running"&&I);return k&&w!==H2&&(R.value=gR(f,this.options,b,this.speed)),_&&_(R.value),k&&this.finish(),R}then(t,n){return this.finished.then(t,n)}get duration(){return Ji(this.calculatedDuration)}get iterationDuration(){const{delay:t=0}=this.options||{};return this.duration+Ji(t)}get time(){return Ji(this.currentTime)}set time(t){t=eo(t),this.currentTime=t,this.startTime===null||this.holdTime!==null||this.playbackSpeed===0?this.holdTime=t:this.driver&&(this.startTime=this.driver.now()-t/this.playbackSpeed),this.driver?.start(!1)}get speed(){return this.playbackSpeed}set speed(t){this.updateTime(ci.now());const n=this.playbackSpeed!==t;this.playbackSpeed=t,n&&(this.time=Ji(this.currentTime))}play(){if(this.isStopped)return;const{driver:t=cSe,startTime:n}=this.options;this.driver||(this.driver=t(i=>this.tick(i))),this.options.onPlay?.();const r=this.driver.now();this.state==="finished"?(this.updateFinished(),this.startTime=r):this.holdTime!==null?this.startTime=r-this.holdTime:this.startTime||(this.startTime=n??r),this.state==="finished"&&this.speed<0&&(this.startTime+=this.calculatedDuration),this.holdTime=null,this.state="running",this.driver.start()}pause(){this.state="paused",this.updateTime(ci.now()),this.holdTime=this.currentTime}complete(){this.state!=="running"&&this.play(),this.state="finished",this.holdTime=null}finish(){this.notifyFinished(),this.teardown(),this.state="finished",this.options.onComplete?.()}cancel(){this.holdTime=null,this.startTime=0,this.tick(0),this.teardown(),this.options.onCancel?.()}teardown(){this.state="idle",this.stopDriver(),this.startTime=this.holdTime=null}stopDriver(){this.driver&&(this.driver.stop(),this.driver=void 0)}sample(t){return this.startTime=0,this.tick(t,!0)}attachTimeline(t){return this.options.allowFlatten&&(this.options.type="keyframes",this.options.ease="linear",this.initAnimation()),this.driver?.stop(),t.observe(this)}}function TSe(e){for(let t=1;t<e.length;t++)e[t]??(e[t]=e[t-1])}const Dc=e=>e*180/Math.PI,V2=e=>{const t=Dc(Math.atan2(e[1],e[0]));return W2(t)},RSe={x:4,y:5,translateX:4,translateY:5,scaleX:0,scaleY:3,scale:e=>(Math.abs(e[0])+Math.abs(e[3]))/2,rotate:V2,rotateZ:V2,skewX:e=>Dc(Math.atan(e[1])),skewY:e=>Dc(Math.atan(e[2])),skew:e=>(Math.abs(e[1])+Math.abs(e[2]))/2},W2=e=>(e=e%360,e<0&&(e+=360),e),pM=V2,mM=e=>Math.sqrt(e[0]*e[0]+e[1]*e[1]),gM=e=>Math.sqrt(e[4]*e[4]+e[5]*e[5]),PSe={x:12,y:13,z:14,translateX:12,translateY:13,translateZ:14,scaleX:mM,scaleY:gM,scale:e=>(mM(e)+gM(e))/2,rotateX:e=>W2(Dc(Math.atan2(e[6],e[5]))),rotateY:e=>W2(Dc(Math.atan2(-e[2],e[0]))),rotateZ:pM,rotate:pM,skewX:e=>Dc(Math.atan(e[4])),skewY:e=>Dc(Math.atan(e[1])),skew:e=>(Math.abs(e[1])+Math.abs(e[4]))/2};function q2(e){return e.includes("scale")?1:0}function K2(e,t){if(!e||e==="none")return q2(t);const n=e.match(/^matrix3d\(([-\d.e\s,]+)\)$/u);let r,i;if(n)r=PSe,i=n;else{const a=e.match(/^matrix\(([-\d.e\s,]+)\)$/u);r=RSe,i=a}if(!i)return q2(t);const s=r[t],o=i[1].split(",").map(ASe);return typeof s=="function"?s(o):o[s]}const OSe=(e,t)=>{const{transform:n="none"}=getComputedStyle(e);return K2(n,t)};function ASe(e){return parseFloat(e.trim())}const Mf=["transformPerspective","x","y","z","translateX","translateY","translateZ","scale","scaleX","scaleY","rotate","rotateX","rotateY","rotateZ","skew","skewX","skewY"],Df=new Set(Mf),yM=e=>e===If||e===at,ISe=new Set(["x","y","z"]),MSe=Mf.filter(e=>!ISe.has(e));function DSe(e){const t=[];return MSe.forEach(n=>{const r=e.getValue(n);r!==void 0&&(t.push([n,r.get()]),r.set(n.startsWith("scale")?1:0))}),t}const Hc={width:({x:e},{paddingLeft:t="0",paddingRight:n="0"})=>e.max-e.min-parseFloat(t)-parseFloat(n),height:({y:e},{paddingTop:t="0",paddingBottom:n="0"})=>e.max-e.min-parseFloat(t)-parseFloat(n),top:(e,{top:t})=>parseFloat(t),left:(e,{left:t})=>parseFloat(t),bottom:({y:e},{top:t})=>parseFloat(t)+(e.max-e.min),right:({x:e},{left:t})=>parseFloat(t)+(e.max-e.min),x:(e,{transform:t})=>K2(t,"x"),y:(e,{transform:t})=>K2(t,"y")};Hc.translateX=Hc.x;Hc.translateY=Hc.y;const Vc=new Set;let G2=!1,Y2=!1,J2=!1;function mz(){if(Y2){const e=Array.from(Vc).filter(r=>r.needsMeasurement),t=new Set(e.map(r=>r.element)),n=new Map;t.forEach(r=>{const i=DSe(r);i.length&&(n.set(r,i),r.render())}),e.forEach(r=>r.measureInitialState()),t.forEach(r=>{r.render();const i=n.get(r);i&&i.forEach(([s,o])=>{r.getValue(s)?.set(o)})}),e.forEach(r=>r.measureEndState()),e.forEach(r=>{r.suspendedScrollY!==void 0&&window.scrollTo(0,r.suspendedScrollY)})}Y2=!1,G2=!1,Vc.forEach(e=>e.complete(J2)),Vc.clear()}function gz(){Vc.forEach(e=>{e.readKeyframes(),e.needsMeasurement&&(Y2=!0)})}function LSe(){J2=!0,gz(),mz(),J2=!1}class _R{constructor(t,n,r,i,s,o=!1){this.state="pending",this.isAsync=!1,this.needsMeasurement=!1,this.unresolvedKeyframes=[...t],this.onComplete=n,this.name=r,this.motionValue=i,this.element=s,this.isAsync=o}scheduleResolve(){this.state="scheduled",this.isAsync?(Vc.add(this),G2||(G2=!0,wn.read(gz),wn.resolveKeyframes(mz))):(this.readKeyframes(),this.complete())}readKeyframes(){const{unresolvedKeyframes:t,name:n,element:r,motionValue:i}=this;if(t[0]===null){const s=i?.get(),o=t[t.length-1];if(s!==void 0)t[0]=s;else if(r&&n){const a=r.readValue(n,o);a!=null&&(t[0]=a)}t[0]===void 0&&(t[0]=o),i&&s===void 0&&i.set(t[0])}TSe(t)}setFinalKeyframe(){}measureInitialState(){}renderEndStyles(){}measureEndState(){}complete(t=!1){this.state="complete",this.onComplete(this.unresolvedKeyframes,this.finalKeyframe,t),Vc.delete(this)}cancel(){this.state==="scheduled"&&(Vc.delete(this),this.state="pending")}resume(){this.state==="pending"&&this.scheduleResolve()}}const NSe=e=>e.startsWith("--");function $Se(e,t,n){NSe(t)?e.style.setProperty(t,n):e.style[t]=n}const jSe=oR(()=>window.ScrollTimeline!==void 0),FSe={};function USe(e,t){const n=oR(e);return()=>FSe[t]??n()}const yz=USe(()=>{try{document.createElement("div").animate({opacity:0},{easing:"linear(0, 1)"})}catch{return!1}return!0},"linearEasing"),rp=([e,t,n,r])=>`cubic-bezier(${e}, ${t}, ${n}, ${r})`,vM={linear:"linear",ease:"ease",easeIn:"ease-in",easeOut:"ease-out",easeInOut:"ease-in-out",circIn:rp([0,.65,.55,1]),circOut:rp([.55,0,1,.45]),backIn:rp([.31,.01,.66,-.59]),backOut:rp([.33,1.53,.69,.99])};function vz(e,t){if(e)return typeof e=="function"?yz()?fz(e,t):"ease-out":nz(e)?rp(e):Array.isArray(e)?e.map(n=>vz(n,t)||vM.easeOut):vM[e]}function zSe(e,t,n,{delay:r=0,duration:i=300,repeat:s=0,repeatType:o="loop",ease:a="easeOut",times:c}={},d=void 0){const f={[t]:n};c&&(f.offset=c);const p=vz(a,i);Array.isArray(p)&&(f.easing=p);const m={delay:r,duration:i,easing:Array.isArray(p)?"linear":p,fill:"both",iterations:s+1,direction:o==="reverse"?"alternate":"normal"};return d&&(m.pseudoElement=d),e.animate(f,m)}function _z(e){return typeof e=="function"&&"applyToOptions"in e}function BSe({type:e,...t}){return _z(e)&&yz()?e.applyToOptions(t):(t.duration??(t.duration=300),t.ease??(t.ease="easeOut"),t)}class HSe extends yR{constructor(t){if(super(),this.finishedTime=null,this.isStopped=!1,!t)return;const{element:n,name:r,keyframes:i,pseudoElement:s,allowFlatten:o=!1,finalKeyframe:a,onComplete:c}=t;this.isPseudoElement=!!s,this.allowFlatten=o,this.options=t,sR(typeof t.type!="string");const d=BSe(t);this.animation=zSe(n,r,i,d,s),d.autoplay===!1&&this.animation.pause(),this.animation.onfinish=()=>{if(this.finishedTime=this.time,!s){const f=gR(i,this.options,a,this.speed);this.updateMotionValue?this.updateMotionValue(f):$Se(n,r,f),this.animation.cancel()}c?.(),this.notifyFinished()}}play(){this.isStopped||(this.animation.play(),this.state==="finished"&&this.updateFinished())}pause(){this.animation.pause()}complete(){this.animation.finish?.()}cancel(){try{this.animation.cancel()}catch{}}stop(){if(this.isStopped)return;this.isStopped=!0;const{state:t}=this;t==="idle"||t==="finished"||(this.updateMotionValue?this.updateMotionValue():this.commitStyles(),this.isPseudoElement||this.cancel())}commitStyles(){this.isPseudoElement||this.animation.commitStyles?.()}get duration(){const t=this.animation.effect?.getComputedTiming?.().duration||0;return Ji(Number(t))}get iterationDuration(){const{delay:t=0}=this.options||{};return this.duration+Ji(t)}get time(){return Ji(Number(this.animation.currentTime)||0)}set time(t){this.finishedTime=null,this.animation.currentTime=eo(t)}get speed(){return this.animation.playbackRate}set speed(t){t<0&&(this.finishedTime=null),this.animation.playbackRate=t}get state(){return this.finishedTime!==null?"finished":this.animation.playState}get startTime(){return Number(this.animation.startTime)}set startTime(t){this.animation.startTime=t}attachTimeline({timeline:t,observe:n}){return this.allowFlatten&&this.animation.effect?.updateTiming({easing:"linear"}),this.animation.onfinish=null,t&&jSe()?(this.animation.timeline=t,Qi):n(this)}}const wz={anticipate:XU,backInOut:ZU,circInOut:ez};function VSe(e){return e in wz}function WSe(e){typeof e.ease=="string"&&VSe(e.ease)&&(e.ease=wz[e.ease])}const _M=10;class qSe extends HSe{constructor(t){WSe(t),pz(t),super(t),t.startTime&&(this.startTime=t.startTime),this.options=t}updateMotionValue(t){const{motionValue:n,onUpdate:r,onComplete:i,element:s,...o}=this.options;if(!n)return;if(t!==void 0){n.set(t);return}const a=new vR({...o,autoplay:!1}),c=eo(this.finishedTime??this.time);n.setWithVelocity(a.sample(c-_M).value,a.sample(c).value,_M),a.stop()}}const wM=(e,t)=>t==="zIndex"?!1:!!(typeof e=="number"||Array.isArray(e)||typeof e=="string"&&(Rl.test(e)||e==="0")&&!e.startsWith("url("));function KSe(e){const t=e[0];if(e.length===1)return!0;for(let n=0;n<e.length;n++)if(e[n]!==t)return!0}function GSe(e,t,n,r){const i=e[0];if(i===null)return!1;if(t==="display"||t==="visibility")return!0;const s=e[e.length-1],o=wM(i,t),a=wM(s,t);return!o||!a?!1:KSe(e)||(n==="spring"||_z(n))&&r}function Z2(e){e.duration=0,e.type="keyframes"}const YSe=new Set(["opacity","clipPath","filter","transform"]),JSe=oR(()=>Object.hasOwnProperty.call(Element.prototype,"animate"));function ZSe(e){const{motionValue:t,name:n,repeatDelay:r,repeatType:i,damping:s,type:o}=e;if(!(t?.owner?.current instanceof HTMLElement))return!1;const{onUpdate:c,transformTemplate:d}=t.owner.getProps();return JSe()&&n&&YSe.has(n)&&(n!=="transform"||!d)&&!c&&!r&&i!=="mirror"&&s!==0&&o!=="inertia"}const XSe=40;class QSe extends yR{constructor({autoplay:t=!0,delay:n=0,type:r="keyframes",repeat:i=0,repeatDelay:s=0,repeatType:
265o="loop",keyframes:a,name:c,motionValue:d,element:f,...p}){super(),this.stop=()=>{this._animation&&(this._animation.stop(),this.stopTimeline?.()),this.keyframeResolver?.cancel()},this.createdAt=ci.now();const m={autoplay:t,delay:n,type:r,repeat:i,repeatDelay:s,repeatType:o,name:c,motionValue:d,element:f,...p},v=f?.KeyframeResolver||_R;this.keyframeResolver=new v(a,(w,_,b)=>this.onKeyframesResolved(w,_,m,!b),c,d,f),this.keyframeResolver?.scheduleResolve()}onKeyframesResolved(t,n,r,i){this.keyframeResolver=void 0;const{name:s,type:o,velocity:a,delay:c,isHandoff:d,onUpdate:f}=r;this.resolvedAt=ci.now(),GSe(t,s,o,a)||((la.instantAnimations||!c)&&f?.(gR(t,r,n)),t[0]=t[t.length-1],Z2(r),r.repeat=0);const m={startTime:i?this.resolvedAt?this.resolvedAt-this.createdAt>XSe?this.resolvedAt:this.createdAt:this.createdAt:void 0,finalKeyframe:n,...r,keyframes:t},v=!d&&ZSe(m)?new qSe({...m,element:m.motionValue.owner.current}):new vR(m);v.finished.then(()=>this.notifyFinished()).catch(Qi),this.pendingTimeline&&(this.stopTimeline=v.attachTimeline(this.pendingTimeline),this.pendingTimeline=void 0),this._animation=v}get finished(){return this._animation?this.animation.finished:this._finished}then(t,n){return this.finished.finally(t).then(()=>{})}get animation(){return this._animation||(this.keyframeResolver?.resume(),LSe()),this._animation}get duration(){return this.animation.duration}get iterationDuration(){return this.animation.iterationDuration}get time(){return this.animation.time}set time(t){this.animation.time=t}get speed(){return this.animation.speed}get state(){return this.animation.state}set speed(t){this.animation.speed=t}get startTime(){return this.animation.startTime}attachTimeline(t){return this._animation?this.stopTimeline=this.animation.attachTimeline(t):this.pendingTimeline=t,()=>this.stop()}play(){this.animation.play()}pause(){this.animation.pause()}complete(){this.animation.complete()}cancel(){this._animation&&this.animation.cancel(),this.keyframeResolver?.cancel()}}const eEe=/^var\(--(?:([\w-]+)|([\w-]+), ?([a-zA-Z\d ()%#.,-]+))\)/u;function tEe(e){const t=eEe.exec(e);if(!t)return[,];const[,n,r,i]=t;return[`--${n??r}`,i]}function bz(e,t,n=1){const[r,i]=tEe(e);if(!r)return;const s=window.getComputedStyle(t).getPropertyValue(r);if(s){const o=s.trim();return HU(o)?parseFloat(o):o}return dR(i)?bz(i,t,n+1):i}function wR(e,t){return e?.[t]??e?.default??e}const Sz=new Set(["width","height","top","left","right","bottom",...Mf]),nEe={test:e=>e==="auto",parse:e=>e},Ez=e=>t=>t.test(e),xz=[If,at,to,Za,Kbe,qbe,nEe],bM=e=>xz.find(Ez(e));function rEe(e){return typeof e=="number"?e===0:e!==null?e==="none"||e==="0"||WU(e):!0}const iEe=new Set(["brightness","contrast","saturate","opacity"]);function sEe(e){const[t,n]=e.slice(0,-1).split("(");if(t==="drop-shadow")return e;const[r]=n.match(fR)||[];if(!r)return e;const i=n.replace(r,"");let s=iEe.has(t)?1:0;return r!==n&&(s*=100),t+"("+s+i+")"}const oEe=/\b([a-z-]*)\(.*?\)/gu,X2={...Rl,getAnimatableNone:e=>{const t=e.match(oEe);return t?t.map(sEe).join(" "):e}},SM={...If,transform:Math.round},aEe={rotate:Za,rotateX:Za,rotateY:Za,rotateZ:Za,scale:av,scaleX:av,scaleY:av,scaleZ:av,skew:Za,skewX:Za,skewY:Za,distance:at,translateX:at,translateY:at,translateZ:at,x:at,y:at,z:at,perspective:at,transformPerspective:at,opacity:sm,originX:cM,originY:cM,originZ:at},bR={borderWidth:at,borderTopWidth:at,borderRightWidth:at,borderBottomWidth:at,borderLeftWidth:at,borderRadius:at,radius:at,borderTopLeftRadius:at,borderTopRightRadius:at,borderBottomRightRadius:at,borderBottomLeftRadius:at,width:at,maxWidth:at,height:at,maxHeight:at,top:at,right:at,bottom:at,left:at,padding:at,paddingTop:at,paddingRight:at,paddingBottom:at,paddingLeft:at,margin:at,marginTop:at,marginRight:at,marginBottom:at,marginLeft:at,backgroundPositionX:at,backgroundPositionY:at,...aEe,zIndex:SM,fillOpacity:sm,strokeOpacity:sm,numOctaves:SM},lEe={...bR,color:Kn,backgroundColor:Kn,outlineColor:Kn,fill:Kn,stroke:Kn,borderColor:Kn,borderTopColor:Kn,borderRightColor:Kn,borderBottomColor:Kn,borderLeftColor:Kn,filter:X2,WebkitFilter:X2},Cz=e=>lEe[e];function kz(e,t){let n=Cz(e);return n!==X2&&(n=Rl),n.getAnimatableNone?n.getAnimatableNone(t):void 0}
vendor: 1,640 bytes, line 265
265const cEe=new Set(["auto","none","0"]);function uEe(e,t,n){let r=0,i;for(;r<e.length&&!i;){const s=e[r];typeof s=="string"&&!cEe.has(s)&&om(s).values.length&&(i=e[r]),r++}if(i&&n)for(const s of t)e[s]=kz(n,i)}class dEe extends _R{constructor(t,n,r,i,s){super(t,n,r,i,s,!0)}readKeyframes(){const{unresolvedKeyframes:t,element:n,name:r}=this;if(!n||!n.current)return;super.readKeyframes();for(let c=0;c<t.length;c++){let d=t[c];if(typeof d=="string"&&(d=d.trim(),dR(d))){const f=bz(d,n.current);f!==void 0&&(t[c]=f),c===t.length-1&&(this.finalKeyframe=d)}}if(this.resolveNoneKeyframes(),!Sz.has(r)||t.length!==2)return;const[i,s]=t,o=bM(i),a=bM(s);if(o!==a)if(yM(o)&&yM(a))for(let c=0;c<t.length;c++){const d=t[c];typeof d=="string"&&(t[c]=parseFloat(d))}else Hc[r]&&(this.needsMeasurement=!0)}resolveNoneKeyframes(){const{unresolvedKeyframes:t,name:n}=this,r=[];for(let i=0;i<t.length;i++)(t[i]===null||rEe(t[i]))&&r.push(i);r.length&&uEe(t,r,n)}measureInitialState(){const{element:t,unresolvedKeyframes:n,name:r}=this;if(!t||!t.current)return;r==="height"&&(this.suspendedScrollY=window.pageYOffset),this.measuredOrigin=Hc[r](t.measureViewportBox(),window.getComputedStyle(t.current)),n[0]=this.measuredOrigin;const i=n[n.length-1];i!==void 0&&t.getValue(r,i).jump(i,!1)}measureEndState(){const{element:t,name:n,unresolvedKeyframes:r}=this;if(!t||!t.current)return;const i=t.getValue(n);i&&i.jump(this.measuredOrigin,!1);const s=r.length-1,o=r[s];r[s]=Hc[n](t.measureViewportBox(),window.getComputedStyle(t.current)),o!==null&&this.finalKeyframe===void 0&&(this.finalKeyframe=o),this.removedTransforms?.length&&this.removedTransforms.forEac
vendor: 4,935 bytes, line 265
265h(([a,c])=>{t.getValue(a).set(c)}),this.resolveNoneKeyframes()}}function fEe(e,t,n){if(e instanceof EventTarget)return[e];if(typeof e=="string"){let r=document;const i=n?.[e]??r.querySelectorAll(e);return i?Array.from(i):[]}return Array.from(e)}const Tz=(e,t)=>t&&typeof e=="number"?t.transform(e):e;function hEe(e){return VU(e)&&"offsetHeight"in e}const EM=30,pEe=e=>!isNaN(parseFloat(e)),xM={current:void 0};class mEe{constructor(t,n={}){this.canTrackVelocity=null,this.events={},this.updateAndNotify=r=>{const i=ci.now();if(this.updatedAt!==i&&this.setPrevFrameValue(),this.prev=this.current,this.setCurrent(r),this.current!==this.prev&&(this.events.change?.notify(this.current),this.dependents))for(const s of this.dependents)s.dirty()},this.hasAnimated=!1,this.setCurrent(t),this.owner=n.owner}setCurrent(t){this.current=t,this.updatedAt=ci.now(),this.canTrackVelocity===null&&t!==void 0&&(this.canTrackVelocity=pEe(this.current))}setPrevFrameValue(t=this.current){this.prevFrameValue=t,this.prevUpdatedAt=this.updatedAt}onChange(t){return this.on("change",t)}on(t,n){this.events[t]||(this.events[t]=new aR);const r=this.events[t].add(n);return t==="change"?()=>{r(),wn.read(()=>{this.events.change.getSize()||this.stop()})}:r}clearListeners(){for(const t in this.events)this.events[t].clear()}attach(t,n){this.passiveEffect=t,this.stopPassiveEffect=n}set(t){this.passiveEffect?this.passiveEffect(t,this.updateAndNotify):this.updateAndNotify(t)}setWithVelocity(t,n,r){this.set(n),this.prev=void 0,this.prevFrameValue=t,this.prevUpdatedAt=this.updatedAt-r}jump(t,n=!0){this.updateAndNotify(t),this.prev=t,this.prevUpdatedAt=this.prevFrameValue=void 0,n&&this.stop(),this.stopPassiveEffect&&this.stopPassiveEffect()}dirty(){this.events.change?.notify(this.current)}addDependent(t){this.dependents||(this.dependents=new Set),this.dependents.add(t)}removeDependent(t){this.dependents&&this.dependents.delete(t)}get(){return xM.current&&xM.current.push(this),this.current}getPrevious(){return this.prev}getVelocity(){const t=ci.now();if(!this.canTrackVelocity||this.prevFrameValue===void 0||t-this.updatedAt>EM)return 0;const n=Math.min(this.updatedAt-this.prevUpdatedAt,EM);return qU(parseFloat(this.current)-parseFloat(this.prevFrameValue),n)}start(t){return this.stop(),new Promise(n=>{this.hasAnimated=!0,this.animation=t(n),this.events.animationStart&&this.events.animationStart.notify()}).then(()=>{this.events.animationComplete&&this.events.animationComplete.notify(),this.clearAnimation()})}stop(){this.animation&&(this.animation.stop(),this.events.animationCancel&&this.events.animationCancel.notify()),this.clearAnimation()}isAnimating(){return!!this.animation}clearAnimation(){delete this.animation}destroy(){this.dependents?.clear(),this.events.destroy?.notify(),this.clearListeners(),this.stop(),this.stopPassiveEffect&&this.stopPassiveEffect()}}function af(e,t){return new mEe(e,t)}const{schedule:SR}=rz(queueMicrotask,!1),gs={x:!1,y:!1};function Rz(){return gs.x||gs.y}function gEe(e){return e==="x"||e==="y"?gs[e]?null:(gs[e]=!0,()=>{gs[e]=!1}):gs.x||gs.y?null:(gs.x=gs.y=!0,()=>{gs.x=gs.y=!1})}function Pz(e,t){const n=fEe(e),r=new AbortController,i={passive:!0,...t,signal:r.signal};return[n,i,()=>r.abort()]}function CM(e){return!(e.pointerType==="touch"||Rz())}function yEe(e,t,n={}){const[r,i,s]=Pz(e,n),o=a=>{if(!CM(a))return;const{target:c}=a,d=t(c,a);if(typeof d!="function"||!c)return;const f=p=>{CM(p)&&(d(p),c.removeEventListener("pointerleave",f))};c.addEventListener("pointerleave",f,i)};return r.forEach(a=>{a.addEventListener("pointerenter",o,i)}),s}const Oz=(e,t)=>t?e===t?!0:Oz(e,t.parentElement):!1,ER=e=>e.pointerType==="mouse"?typeof e.button!="number"||e.button<=0:e.isPrimary!==!1,vEe=new Set(["BUTTON","INPUT","SELECT","TEXTAREA","A"]);function _Ee(e){return vEe.has(e.tagName)||e.tabIndex!==-1}const Hv=new WeakSet;function kM(e){return t=>{t.key==="Enter"&&e(t)}}function WS(e,t){e.dispatchEvent(new PointerEvent("pointer"+t,{isPrimary:!0,bubbles:!0}))}const wEe=(e,t)=>{const n=e.currentTarget;if(!n)return;const r=kM(()=>{if(Hv.has(n))return;WS(n,"down");const i=kM(()=>{WS(n,"up")}),s=()=>WS(n,"cancel");n.addEventListener("keyup",i,t),n.addEventListener("blur",s,t)});n.addEventListener("keydown",r,t),n.addEventListener("blur",()=>n.removeEventListener("keydown",r),t)};function TM(e){return ER(e)&&!Rz()}function bEe(e,t,n={}){const[r,i,s]=Pz(e,n),o=a=>{const c=a.currentTarget;if(!TM(a))return;Hv.add(c);const d=t(c,a),f=(v,w)=>{window.removeEventListener("pointerup",p),window.removeEventListener("pointercancel",m),Hv.has(c)&&Hv.delete(c),TM(v)&&typeof d=="function"&&d(v,{success:w})},p=v=>{f(v,c===window||c===document||n.useGlobalTarget||Oz(c,v.target))},m=v=>{f(v,!1)};window.addEventListener("pointerup",p,i),window.addEventListener("pointercancel",m,i)};return r.forEach(a=>{(n.useGlobalTarget?window:a).addEventListener("pointerdown",o,i),hEe(a)&&(a.addEventListener("focus",d=>
vendor: 4,441 bytes, line 265
265wEe(d,i)),!_Ee(a)&&!a.hasAttribute("tabindex")&&(a.tabIndex=0))}),s}function Az(e){return VU(e)&&"ownerSVGElement"in e}function SEe(e){return Az(e)&&e.tagName==="svg"}const Dr=e=>!!(e&&e.getVelocity),EEe=[...xz,Kn,Rl],xEe=e=>EEe.find(Ez(e)),Iz=g.createContext({transformPagePoint:e=>e,isStatic:!1,reducedMotion:"never"});function CEe(e=!0){const t=g.useContext(nR);if(t===null)return[!0,null];const{isPresent:n,onExitComplete:r,register:i}=t,s=g.useId();g.useEffect(()=>{if(e)return i(s)},[e]);const o=g.useCallback(()=>e&&r&&r(s),[s,r,e]);return!n&&r?[!1,o]:[!0]}const Mz=g.createContext({strict:!1}),RM={animation:["animate","variants","whileHover","whileTap","exit","whileInView","whileFocus","whileDrag"],exit:["exit"],drag:["drag","dragControls"],focus:["whileFocus"],hover:["whileHover","onHoverStart","onHoverEnd"],tap:["whileTap","onTap","onTapStart","onTapCancel"],pan:["onPan","onPanStart","onPanSessionStart","onPanEnd"],inView:["whileInView","onViewportEnter","onViewportLeave"],layout:["layout","layoutId"]},lf={};for(const e in RM)lf[e]={isEnabled:t=>RM[e].some(n=>!!t[n])};function kEe(e){for(const t in e)lf[t]={...lf[t],...e[t]}}const TEe=new Set(["animate","exit","variants","initial","style","values","variants","transition","transformTemplate","custom","inherit","onBeforeLayoutMeasure","onAnimationStart","onAnimationComplete","onUpdate","onDragStart","onDrag","onDragEnd","onMeasureDragConstraints","onDirectionLock","onDragTransitionEnd","_dragX","_dragY","onHoverStart","onHoverEnd","onViewportEnter","onViewportLeave","globalTapTarget","ignoreStrict","viewport"]);function Q0(e){return e.startsWith("while")||e.startsWith("drag")&&e!=="draggable"||e.startsWith("layout")||e.startsWith("onTap")||e.startsWith("onPan")||e.startsWith("onLayout")||TEe.has(e)}let Dz=e=>!Q0(e);function REe(e){typeof e=="function"&&(Dz=t=>t.startsWith("on")?!Q0(t):e(t))}try{REe(require("@emotion/is-prop-valid").default)}catch{}function PEe(e,t,n){const r={};for(const i in e)i==="values"&&typeof e.values=="object"||(Dz(i)||n===!0&&Q0(i)||!t&&!Q0(i)||e.draggable&&i.startsWith("onDrag"))&&(r[i]=e[i]);return r}const b1=g.createContext({});function S1(e){return e!==null&&typeof e=="object"&&typeof e.start=="function"}function am(e){return typeof e=="string"||Array.isArray(e)}const xR=["animate","whileInView","whileFocus","whileHover","whileTap","whileDrag","exit"],CR=["initial",...xR];function E1(e){return S1(e.animate)||CR.some(t=>am(e[t]))}function Lz(e){return!!(E1(e)||e.variants)}function OEe(e,t){if(E1(e)){const{initial:n,animate:r}=e;return{initial:n===!1||am(n)?n:void 0,animate:am(r)?r:void 0}}return e.inherit!==!1?t:{}}function AEe(e){const{initial:t,animate:n}=OEe(e,g.useContext(b1));return g.useMemo(()=>({initial:t,animate:n}),[PM(t),PM(n)])}function PM(e){return Array.isArray(e)?e.join(" "):e}const lm={};function IEe(e){for(const t in e)lm[t]=e[t],uR(t)&&(lm[t].isCSSVariable=!0)}function Nz(e,{layout:t,layoutId:n}){return Df.has(e)||e.startsWith("origin")||(t||n!==void 0)&&(!!lm[e]||e==="opacity")}const MEe={x:"translateX",y:"translateY",z:"translateZ",transformPerspective:"perspective"},DEe=Mf.length;function LEe(e,t,n){let r="",i=!0;for(let s=0;s<DEe;s++){const o=Mf[s],a=e[o];if(a===void 0)continue;let c=!0;if(typeof a=="number"?c=a===(o.startsWith("scale")?1:0):c=parseFloat(a)===0,!c||n){const d=Tz(a,bR[o]);if(!c){i=!1;const f=MEe[o]||o;r+=`${f}(${d}) `}n&&(t[o]=d)}}return r=r.trim(),n?r=n(t,i?"":r):i&&(r="none"),r}function kR(e,t,n){const{style:r,vars:i,transformOrigin:s}=e;let o=!1,a=!1;for(const c in t){const d=t[c];if(Df.has(c)){o=!0;continue}else if(uR(c)){i[c]=d;continue}else{const f=Tz(d,bR[c]);c.startsWith("origin")?(a=!0,s[c]=f):r[c]=f}}if(t.transform||(o||n?r.transform=LEe(t,e.transform,n):r.transform&&(r.transform="none")),a){const{originX:c="50%",originY:d="50%",originZ:f=0}=s;r.transformOrigin=`${c} ${d} ${f}`}}const TR=()=>({style:{},transform:{},transformOrigin:{},vars:{}});function $z(e,t,n){for(const r in t)!Dr(t[r])&&!Nz(r,n)&&(e[r]=t[r])}function NEe({transformTemplate:e},t){return g.useMemo(()=>{const n=TR();return kR(n,t,e),Object.assign({},n.vars,n.style)},[t])}function $Ee(e,t){const n=e.style||{},r={};return $z(r,n,e),Object.assign(r,NEe(e,t)),r}function jEe(e,t){const n={},r=$Ee(e,t);return e.drag&&e.dragListener!==!1&&(n.draggable=!1,r.userSelect=r.WebkitUserSelect=r.WebkitTouchCallout="none",r.touchAction=e.drag===!0?"none":`pan-${e.drag==="x"?"y":"x"}
265`),e.tabIndex===void 0&&(e.onTap||e.onTapStart||e.whileTap)&&(n.tabIndex=0),n.style=r,n}const FEe={offset:"stroke-dashoffset",array:"stroke-dasharray"},UEe={offset:"strokeDashoffset",array:"strokeDasharray"};function zEe(e,t,n=1,r=0,i=!0){e.pathLength=1;const s=i?FEe:UEe;e[s.offset]=at.transform(-r);const o=at.transform(t),a=at.transform(n);e[s.array]=`${o} ${a}`}function jz(e,{attrX:t,attrY:n,attrScale:r,pathLength:i,pathSpacing:s=1,pathOffset:o=0,...a},c,d,f){if(kR(e,a,d),c){e.style.viewBox&&(e.attrs.viewBox=e.style.viewBox);return}e.attrs=e.style,e.style={};const{attrs:p,style:m}=e;p.transform&&(m.transform=p.transform,delete p.transform),(m.transform||p.transformOrigin)&&(m.transformOrigin=p.transformOrigin??"50% 50%",delete p.transformOrigin),m.transform&&(m.transformBox=f?.transformBox??"fill-box",delete p.transformBox),t!==void 0&&(p.x=t),n!==void 0&&(p.y=n),r!==void 0&&(p.scale=r),i!==void 0&&zEe(p,i,s,o,!1)}const Fz=()=>({...TR(),attrs:{}}),Uz=e=>typeof e=="string"&&e.toLowerCase()==="svg";function BEe(e,t,n,r){const i=g.useMemo(()=>{const s=Fz();return jz(s,t,Uz(r),e.transformTemplate,e.style),{...s.attrs,style:{...s.style}}},[t]);if(e.style){const s={};$z(s,e.style,e),i.style={...s,...i.style}}return i}const HEe=["animate","circle","defs","desc","ellipse","g","image","line","filter","marker","mask","metadata","path","pattern","polygon","polyline","rect","stop","switch","symbol","svg","text","tspan","use","view"];function RR(e){return typeof e!="string"||e.includes("-")?!1:!!(HEe.indexOf(e)>-1||/[A-Z]/u.test(e))}function VEe(e,t,n,{latestValues:r},i,s=!1){const a=(RR(e)?BEe:jEe)(t,r,i,e),c=PEe(t,typeof e=="string",s),d=e!==g.Fragment?{...c,...a,ref:n}:{},{children:f}=t,p=g.useMemo(()=>Dr(f)?f.get():f,[f]);return g.createElement(e,{...d,children:p})}function OM(e){const t=[{},{}];return e?.values.forEach((n,r)=>{t[0][r]=n.get(),t[1][r]=n.getVelocity()}),t}function PR(e,t,n,r){if(typeof t=="function"){const[i,s]=OM(r);t=t(n!==void 0?n:e.custom,i,s)}if(typeof t=="string"&&(t=e.variants&&e.variants[t]),typeof t=="function"){const[i,s]=OM(r);t=t(n!==void 0?n:e.custom,i,s)}return t}function Vv(e){return Dr(e)?e.get():e}function WEe({scrapeMotionValuesFromProps:e,createRenderState:t},n,r,i){return{latestValues:qEe(n,r,i,e),renderState:t()}}function qEe(e,t,n,r){const i={},s=r(e,{});for(const m in s)i[m]=Vv(s[m]);let{initial:o,animate:a}=e;const c=E1(e),d=Lz(e);t&&d&&!c&&e.inherit!==!1&&(o===void 0&&(o=t.initial),a===void 0&&(a=t.animate));let f=n?n.initial===!1:!1;f=f||o===!1;const p=f?a:o;if(p&&typeof p!="boolean"&&!S1(p)){const m=Array.isArray(p)?p:[p];for(let v=0;v<m.length;v++){const w=PR(e,m[v]);if(w){const{transitionEnd:_,transition:b,...C}=w;for(const P in C){let D=C[P];if(Array.isArray(D)){const F=f?D.length-1:0;D=D[F]}D!==null&&(i[P]=D)}for(const P in _)i[P]=_[P]}}}return i}const zz=e=>(t,n)=>{const r=g.useContext(b1),i=g.useContext(nR),s=()=>WEe(e,t,r,i);return n?s():kbe(s)};function OR(e,t,n){const{style:r}=e,i={};for(const s in r)(Dr(r[s])||t.style&&Dr(t.style[s])||Nz(s,e)||n?.getValue(s)?.liveStyle!==void 0)&&(i[s]=r[s]);return i}const KEe=zz({scrapeMotionValuesFromProps:OR,createRenderState:TR});function Bz(e,t,n){const r=OR(e,t,n);for(const i in e)if(Dr(e[i])||Dr(t[i])){const s=Mf.indexOf(i)!==-1?"attr"+i.charAt(0).toUpperCase()+i.substring(1):i;r[s]=e[i]}return r}const GEe=zz({scrapeMotionValuesFromProps:Bz,createRenderState:Fz}),YEe=Symbol.for("motionComponentSymbol");function xd(e){return e&&typeof e=="object"&&Object.prototype.hasOwnProperty.call(e,"current")}function JEe(e,t,n){return g.useCallback(r=>{r&&e.onMount&&e.onMount(r),t&&(r?t.mount(r):t.unmount()),n&&(typeof n=="function"?n(r):xd(n)&&(n.current=r))},[t])}const AR=e=>e.replace(/([a-z])([A-Z])/gu,"$1-$2").toLowerCase(),ZEe="framerAppearId",Hz="data-"+AR(ZEe),Vz=g.createContext({});function XEe(e,t,n,r,i){const{visualElement:s}=g.useContext(b1),o=g.useContext(Mz),a=g.useContext(nR),c=g.useContext(Iz).reducedMotion,d=g.useRef(null);r=r||o.renderer,!d.current&&r&&(d.current=r(e,{visualState:t,parent:s,props:n,presenceContext:a,blockInitialAnimation:a?a.initial===!1:!1,reducedMotionConfig:c}
vendor: 34,330 bytes, line 265
265));const f=d.current,p=g.useContext(Vz);f&&!f.projection&&i&&(f.type==="html"||f.type==="svg")&&QEe(d.current,n,i,p);const m=g.useRef(!1);g.useInsertionEffect(()=>{f&&m.current&&f.update(n,a)});const v=n[Hz],w=g.useRef(!!v&&!window.MotionHandoffIsComplete?.(v)&&window.MotionHasOptimisedAnimation?.(v));return Tbe(()=>{f&&(m.current=!0,window.MotionIsMounted=!0,f.updateFeatures(),f.scheduleRenderMicrotask(),w.current&&f.animationState&&f.animationState.animateChanges())}),g.useEffect(()=>{f&&(!w.current&&f.animationState&&f.animationState.animateChanges(),w.current&&(queueMicrotask(()=>{window.MotionHandoffMarkAsComplete?.(v)}),w.current=!1),f.enteringChildren=void 0)}),f}function QEe(e,t,n,r){const{layoutId:i,layout:s,drag:o,dragConstraints:a,layoutScroll:c,layoutRoot:d,layoutCrossfade:f}=t;e.projection=new n(e.latestValues,t["data-framer-portal-id"]?void 0:Wz(e.parent)),e.projection.setOptions({layoutId:i,layout:s,alwaysMeasureLayout:!!o||a&&xd(a),visualElement:e,animationType:typeof s=="string"?s:"both",initialPromotionConfig:r,crossfade:f,layoutScroll:c,layoutRoot:d})}function Wz(e){if(e)return e.options.allowProjection!==!1?e.projection:Wz(e.parent)}function qS(e,{forwardMotionProps:t=!1}={},n,r){n&&kEe(n);const i=RR(e)?GEe:KEe;function s(a,c){let d;const f={...g.useContext(Iz),...a,layoutId:exe(a)},{isStatic:p}=f,m=AEe(a),v=i(a,p);if(!p&&tR){txe();const w=nxe(f);d=w.MeasureLayout,m.visualElement=XEe(e,v,f,r,w.ProjectionNode)}return j.jsxs(b1.Provider,{value:m,children:[d&&m.visualElement?j.jsx(d,{visualElement:m.visualElement,...f}):null,VEe(e,a,JEe(v,m.visualElement,c),v,p,t)]})}s.displayName=`motion.${typeof e=="string"?e:`create(${e.displayName??e.name??""})`}`;const o=g.forwardRef(s);return o[YEe]=e,o}function exe({layoutId:e}){const t=g.useContext(BU).id;return t&&e!==void 0?t+"-"+e:e}function txe(e,t){g.useContext(Mz).strict}function nxe(e){const{drag:t,layout:n}=lf;if(!t&&!n)return{};const r={...t,...n};return{MeasureLayout:t?.isEnabled(e)||n?.isEnabled(e)?r.MeasureLayout:void 0,ProjectionNode:r.ProjectionNode}}function rxe(e,t){if(typeof Proxy>"u")return qS;const n=new Map,r=(s,o)=>qS(s,o,e,t),i=(s,o)=>r(s,o);return new Proxy(i,{get:(s,o)=>o==="create"?r:(n.has(o)||n.set(o,qS(o,void 0,e,t)),n.get(o))})}function qz({top:e,left:t,right:n,bottom:r}){return{x:{min:t,max:n},y:{min:e,max:r}}}function ixe({x:e,y:t}){return{top:t.min,right:e.max,bottom:t.max,left:e.min}}function sxe(e,t){if(!t)return e;const n=t({x:e.left,y:e.top}),r=t({x:e.right,y:e.bottom});return{top:n.y,left:n.x,bottom:r.y,right:r.x}}function KS(e){return e===void 0||e===1}function Q2({scale:e,scaleX:t,scaleY:n}){return!KS(e)||!KS(t)||!KS(n)}function Ec(e){return Q2(e)||Kz(e)||e.z||e.rotate||e.rotateX||e.rotateY||e.skewX||e.skewY}function Kz(e){return AM(e.x)||AM(e.y)}function AM(e){return e&&e!=="0%"}function e_(e,t,n){const r=e-n,i=t*r;return n+i}function IM(e,t,n,r,i){return i!==void 0&&(e=e_(e,i,r)),e_(e,n,r)+t}function eC(e,t=0,n=1,r,i){e.min=IM(e.min,t,n,r,i),e.max=IM(e.max,t,n,r,i)}function Gz(e,{x:t,y:n}){eC(e.x,t.translate,t.scale,t.originPoint),eC(e.y,n.translate,n.scale,n.originPoint)}const MM=.999999999999,DM=1.0000000000001;function oxe(e,t,n,r=!1){const i=n.length;if(!i)return;t.x=t.y=1;let s,o;for(let a=0;a<i;a++){s=n[a],o=s.projectionDelta;const{visualElement:c}=s.options;c&&c.props.style&&c.props.style.display==="contents"||(r&&s.options.layoutScroll&&s.scroll&&s!==s.root&&kd(e,{x:-s.scroll.offset.x,y:-s.scroll.offset.y}),o&&(t.x*=o.x.scale,t.y*=o.y.scale,Gz(e,o)),r&&Ec(s.latestValues)&&kd(e,s.latestValues))}t.x<DM&&t.x>MM&&(t.x=1),t.y<DM&&t.y>MM&&(t.y=1)}function Cd(e,t){e.min=e.min+t,e.max=e.max+t}function LM(e,t,n,r,i=.5){const s=kn(e.min,e.max,i);eC(e,t,n,s,r)}function kd(e,t){LM(e.x,t.x,t.scaleX,t.scale,t.originX),LM(e.y,t.y,t.scaleY,t.scale,t.originY)}function Yz(e,t){return qz(sxe(e.getBoundingClientRect(),t))}function axe(e,t,n){const r=Yz(e,n),{scroll:i}=t;return i&&(Cd(r.x,i.offset.x),Cd(r.y,i.offset.y)),r}const NM=()=>({translate:0,scale:1,origin:0,originPoint:0}),Td=()=>({x:NM(),y:NM()}),$M=()=>({min:0,max:0}),nr=()=>({x:$M(),y:$M()}),tC={current:null},Jz={current:!1};function lxe(){if(Jz.current=!0,!!tR)if(window.matchMedia){const e=window.matchMedia("(prefers-reduced-motion)"),t=()=>tC.current=e.matches;e.addEventListener("change",t),t()}else tC.current=!1}const cxe=new WeakMap;function uxe(e,t,n){for(const r in t){const i=t[r],s=n[r];if(Dr(i))e.addValue(r,i);else if(Dr(s))e.addValue(r,af(i,{owner:e}));else if(s!==i)if(e.hasValue(r)){const o=e.getValue(r);o.liveStyle===!0?o.jump(i):o.hasAnimated||o.set(i)}else{const o=e.getStaticValue(r);e.addValue(r,af(o!==void 0?o:i,{owner:e}))}}for(const r in n)t[r]===void 0&&e.removeValue(r);return t}const jM=["AnimationStart","AnimationComplete","Update","BeforeLayoutMeasure","LayoutMeasure","LayoutAnimationStart","LayoutAnimationComplete"];class dxe{scrapeMotionValuesFromProps(t,n,r){return{}}constructor({parent:t,props:n,presenceContext:r,reducedMotionConfig:i,blockInitialAnimation:s,visualState:o},a={}){this.current=null,this.children=new Set,this.isVariantNode=!1,this.isControllingVariants=!1,this.shouldReduceMotion=null,this.values=new Map,this.KeyframeResolver=_R,this.features={},this.valueSubscriptions=new Map,this.prevMotionValues={},this.events={},this.propEventSubscriptions={},this.notifyUpdate=()=>this.notify("Update",this.latestValues),this.render=()=>{this.current&&(this.triggerBuild(),this.renderInstance(this.current,this.renderState,this.props.style,this.projection))},this.renderScheduledAt=0,this.scheduleRender=()=>{const m=ci.now();this.renderScheduledAt<m&&(this.renderScheduledAt=m,wn.render(this.render,!1,!0))};const{latestValues:c,renderState:d}=o;this.latestValues=c,this.baseTarget={...c},this.initialValues=n.initial?{...c}:{},this.renderState=d,this.parent=t,this.props=n,this.presenceContext=r,this.depth=t?t.depth+1:0,this.reducedMotionConfig=i,this.options=a,this.blockInitialAnimation=!!s,this.isControllingVariants=E1(n),this.isVariantNode=Lz(n),this.isVariantNode&&(this.variantChildren=new Set),this.manuallyAnimateOnMount=!!(t&&t.current);const{willChange:f,...p}=this.scrapeMotionValuesFromProps(n,{},this);for(const m in p){const v=p[m];c[m]!==void 0&&Dr(v)&&v.set(c[m])}}mount(t){this.current=t,cxe.set(t,this),this.projection&&!this.projection.instance&&this.projection.mount(t),this.parent&&this.isVariantNode&&!this.isControllingVariants&&(this.removeFromVariantTree=this.parent.addVariantChild(this)),this.values.forEach((n,r)=>this.bindToMotionValue(r,n)),Jz.current||lxe(),this.shouldReduceMotion=this.reducedMotionConfig==="never"?!1:this.reducedMotionConfig==="always"?!0:tC.current,this.parent?.addChild(this),this.update(this.props,this.presenceContext)}unmount(){this.projection&&this.projection.unmount(),Tl(this.notifyUpdate),Tl(this.render),this.valueSubscriptions.forEach(t=>t()),this.valueSubscriptions.clear(),this.removeFromVariantTree&&this.removeFromVariantTree(),this.parent?.removeChild(this);for(const t in this.events)this.events[t].clear();for(const t in this.features){const n=this.features[t];n&&(n.unmount(),n.isMounted=!1)}this.current=null}addChild(t){this.children.add(t),this.enteringChildren??(this.enteringChildren=new Set),this.enteringChildren.add(t)}removeChild(t){this.children.delete(t),this.enteringChildren&&this.enteringChildren.delete(t)}bindToMotionValue(t,n){this.valueSubscriptions.has(t)&&this.valueSubscriptions.get(t)();const r=Df.has(t);r&&this.onBindTransform&&this.onBindTransform();const i=n.on("change",o=>{this.latestValues[t]=o,this.props.onUpdate&&wn.preRender(this.notifyUpdate),r&&this.projection&&(this.projection.isTransformDirty=!0),this.scheduleRender()});let s;window.MotionCheckAppearSync&&(s=window.MotionCheckAppearSync(this,t,n)),this.valueSubscriptions.set(t,()=>{i(),s&&s(),n.owner&&n.stop()})}sortNodePosition(t){return!this.current||!this.sortInstanceNodePosition||this.type!==t.type?0:this.sortInstanceNodePosition(this.current,t.current)}updateFeatures(){let t="animation";for(t in lf){const n=lf[t];if(!n)continue;const{isEnabled:r,Feature:i}=n;if(!this.features[t]&&i&&r(this.props)&&(this.features[t]=new i(this)),this.features[t]){const s=this.features[t];s.isMounted?s.update():(s.mount(),s.isMounted=!0)}}}triggerBuild(){this.build(this.renderState,this.latestValues,this.props)}measureViewportBox(){return this.current?this.measureInstanceViewportBox(this.current,this.props):nr()}getStaticValue(t){return this.latestValues[t]}setStaticValue(t,n){this.latestValues[t]=n}update(t,n){(t.transformTemplate||this.props.transformTemplate)&&this.scheduleRender(),this.prevProps=this.props,this.props=t,this.prevPresenceContext=this.presenceContext,this.presenceContext=n;for(let r=0;r<jM.length;r++){const i=jM[r];this.propEventSubscriptions[i]&&(this.propEventSubscriptions[i](),delete this.propEventSubscriptions[i]);const s="on"+i,o=t[s];o&&(this.propEventSubscriptions[i]=this.on(i,o))}this.prevMotionValues=uxe(this,this.scrapeMotionValuesFromProps(t,this.prevProps,this),this.prevMotionValues),this.handleChildMotionValue&&this.handleChildMotionValue()}getProps(){return this.props}getVariant(t){return this.props.variants?this.props.variants[t]:void 0}getDefaultTransition(){return this.props.transition}getTransformPagePoint(){return this.props.transformPagePoint}getClosestVariantNode(){return this.isVariantNode?this:this.parent?this.parent.getClosestVariantNode():void 0}addVariantChild(t){const n=this.getClosestVariantNode();if(n)return n.variantChildren&&n.variantChildren.add(t),()=>n.variantChildren.delete(t)}addValue(t,n){const r=this.values.get(t);n!==r&&(r&&this.removeValue(t),this.bindToMotionValue(t,n),this.values.set(t,n),this.latestValues[t]=n.get())}removeValue(t){this.values.delete(t);const n=this.valueSubscriptions.get(t);n&&(n(),this.valueSubscriptions.delete(t)),delete this.latestValues[t],this.removeValueFromRenderState(t,this.renderState)}hasValue(t){return this.values.has(t)}getValue(t,n){if(this.props.values&&this.props.values[t])return this.props.values[t];let r=this.values.get(t);return r===void 0&&n!==void 0&&(r=af(n===null?void 0:n,{owner:this}),this.addValue(t,r)),r}readValue(t,n){let r=this.latestValues[t]!==void 0||!this.current?this.latestValues[t]:this.getBaseTargetFromProps(this.props,t)??this.readValueFromInstance(this.current,t,this.options);return r!=null&&(typeof r=="string"&&(HU(r)||WU(r))?r=parseFloat(r):!xEe(r)&&Rl.test(n)&&(r=kz(t,n)),this.setBaseTarget(t,Dr(r)?r.get():r)),Dr(r)?r.get():r}setBaseTarget(t,n){this.baseTarget[t]=n}getBaseTarget(t){const{initial:n}=this.props;let r;if(typeof n=="string"||typeof n=="object"){const s=PR(this.props,n,this.presenceContext?.custom);s&&(r=s[t])}if(n&&r!==void 0)return r;const i=this.getBaseTargetFromProps(this.props,t);return i!==void 0&&!Dr(i)?i:this.initialValues[t]!==void 0&&r===void 0?void 0:this.baseTarget[t]}on(t,n){return this.events[t]||(this.events[t]=new aR),this.events[t].add(n)}notify(t,...n){this.events[t]&&this.events[t].notify(...n)}scheduleRenderMicrotask(){SR.render(this.render)}}class Zz extends dxe{constructor(){super(...arguments),this.KeyframeResolver=dEe}sortInstanceNodePosition(t,n){return t.compareDocumentPosition(n)&2?1:-1}getBaseTargetFromProps(t,n){return t.style?t.style[n]:void 0}removeValueFromRenderState(t,{vars:n,style:r}){delete n[t],delete r[t]}handleChildMotionValue(){this.childSubscription&&(this.childSubscription(),delete this.childSubscription);const{children:t}=this.props;Dr(t)&&(this.childSubscription=t.on("change",n=>{this.current&&(this.current.textContent=`${n}`)}))}}function Xz(e,{style:t,vars:n},r,i){const s=e.style;let o;for(o in t)s[o]=t[o];i?.applyProjectionStyles(s,r);for(o in n)s.setProperty(o,n[o])}function fxe(e){return window.getComputedStyle(e)}class hxe extends Zz{constructor(){super(...arguments),this.type="html",this.renderInstance=Xz}readValueFromInstance(t,n){if(Df.has(n))return this.projection?.isProjecting?q2(n):OSe(t,n);{const r=fxe(t),i=(uR(n)?r.getPropertyValue(n):r[n])||0;return typeof i=="string"?i.trim():i}}measureInstanceViewportBox(t,{transformPagePoint:n}){return Yz(t,n)}build(t,n,r){kR(t,n,r.transformTemplate)}scrapeMotionValuesFromProps(t,n,r){return OR(t,n,r)}}const Qz=new Set(["baseFrequency","diffuseConstant","kernelMatrix","kernelUnitLength","keySplines","keyTimes","limitingConeAngle","markerHeight","markerWidth","numOctaves","targetX","targetY","surfaceScale","specularConstant","specularExponent","stdDeviation","tableValues","viewBox","gradientTransform","pathLength","startOffset","textLength","lengthAdjust"]);function pxe(e,t,n,r){Xz(e,t,void 0,r);for(const i in t.attrs)e.setAttribute(Qz.has(i)?i:AR(i),t.attrs[i])}class mxe extends Zz{constructor(){super(...arguments),this.type="svg",this.isSVGTag=!1,this.measureInstanceViewportBox=nr}getBaseTargetFromProps(t,n){return t[n]}readValueFromInstance(t,n){if(Df.has(n)){const r=Cz(n);return r&&r.default||0}return n=Qz.has(n)?n:AR(n),t.getAttribute(n)}scrapeMotionValuesFromProps(t,n,r){return Bz(t,n,r)}build(t,n,r){jz(t,n,this.isSVGTag,r.transformTemplate,r.style)}renderInstance(t,n,r,i){pxe(t,n,r,i)}mount(t){this.isSVGTag=Uz(t.tagName),super.mount(t)}}const gxe=(e,t)=>RR(e)?new mxe(t):new hxe(t,{allowProjection:e!==g.Fragment});function Ud(e,t,n){const r=e.getProps();return PR(r,t,n!==void 0?n:r.custom,e)}const nC=e=>Array.isArray(e);function yxe(e,t,n){e.hasValue(t)?e.getValue(t).set(n):e.addValue(t,af(n))}function vxe(e){return nC(e)?e[e.length-1]||0:e}function _xe(e,t){const n=Ud(e,t);let{transitionEnd:r={},transition:i={},...s}=n||{};s={...s,...r};for(const o in s){const a=vxe(s[o]);yxe(e,o,a)}}function wxe(e){return!!(Dr(e)&&e.add)}function rC(e,t){const n=e.getValue("willChange");if(wxe(n))return n.add(t);if(!n&&la.WillChange){const r=new la.WillChange("auto");e.addValue("willChange",r),r.add(t)}}function eB(e){return e.props[Hz]}const bxe=e=>e!==null;function Sxe(e,{repeat:t,repeatType:n="loop"},r){const i=e.filter(bxe),s=t&&n!=="loop"&&t%2===1?0:i.length-1;return i[s]}const Exe={type:"spring",stiffness:500,damping:25,restSpeed:10},xxe=e=>({type:"spring",stiffness:550,damping:e===0?2*Math.sqrt(550):30,restSpeed:10}),Cxe={type:"keyframes",duration:.8},kxe={type:"keyframes",ease:[.25,.1,.35,1],duration:.3},Txe=(e,{keyframes:t})=>t.length>2?Cxe:Df.has(e)?e.startsWith("scale")?xxe(t[1]):Exe:kxe;function Rxe({when:e,delay:t,delayChildren:n,staggerChildren:r,staggerDirection:i,repeat:s,repeatType:o,repeatDelay:a,from:c,elapsed:d,...f}){return!!Object.keys(f).length}const IR=(e,t,n,r={},i,s)=>o=>{const a=wR(r,e)||{},c=a.delay||r.delay||0;let{elapsed:d=0}=r;d=d-eo(c);const f={keyframes:Array.isArray(n)?n:[null,n],ease:"easeOut",velocity:t.getVelocity(),...a,delay:-d,onUpdate:m=>{t.set(m),a.onUpdate&&a.onUpdate(m)},onComplete:()=>{o(),a.onComplete&&a.onComplete()},name:e,motionValue:t,element:s?void 0:i};Rxe(a)||Object.assign(f,Txe(e,f)),f.duration&&(f.duration=eo(f.duration)),f.repeatDelay&&(f.repeatDelay=eo(f.repeatDelay)),f.from!==void 0&&(f.keyframes[0]=f.from);let p=!1;if((f.type===!1||f.duration===0&&!f.repeatDelay)&&(Z2(f),f.delay===0&&(p=!0)),(la.instantAnimations||la.skipAnimations)&&(p=!0,Z2(f),f.delay=0),f.allowFlatten=!a.type&&!a.ease,p&&!s&&t.get()!==void 0){const m=Sxe(f.keyframes,a);if(m!==void 0){wn.update(()=>{f.onUpdate(m),f.onComplete()});return}}return a.isSync?new vR(f):new QSe(f)};function Pxe({protectedKeys:e,needsAnimating:t},n){const r=e.hasOwnProperty(n)&&t[n]!==!0;return t[n]=!1,r}function tB(e,t,{delay:n=0,transitionOverride:r,type:i}={}){let{transition:s=e.getDefaultTransition(),transitionEnd:o,...a}=t;r&&(s=r);const c=[],d=i&&e.animationState&&e.animationState.getState()[i];for(const f in a){const p=e.getValue(f,e.latestValues[f]??null),m=a[f];if(m===void 0||d&&Pxe(d,f))continue;const v={delay:n,...wR(s||{},f)},w=p.get();if(w!==void 0&&!p.isAnimating&&!Array.isArray(m)&&m===w&&!v.velocity)continue;let _=!1;if(window.MotionHandoffAnimation){const C=eB(e);if(C){const P=window.MotionHandoffAnimation(C,f,wn);P!==null&&(v.startTime=P,_=!0)}}rC(e,f),p.start(IR(f,p,m,e.shouldReduceMotion&&Sz.has(f)?{type:!1}:v,e,_));const b=p.animation;b&&c.push(b)}return o&&Promise.all(c).then(()=>{wn.update(()=>{o&&_xe(e,o)})}),c}function nB(e,t,n,r=0,i=1){const s=Array.from(e).sort((d,f)=>d.sortNodePosition(f)).indexOf(t),o=e.size,a=(o-1)*r;return typeof n=="function"?n(s,o):i===1?s*r:a-s*r}function iC(e,t,n={}){const r=Ud(e,t,n.type==="exit"?e.presenceContext?.custom:void 0);let{transition:i=e.getDefaultTransition()||{}}=r||{};n.transitionOverride&&(i=n.transitionOverride);const s=r?()=>Promise.all(tB(e,r,n)):()=>Promise.resolve(),o=e.variantChildren&&e.variantChildren.size?(c=0)=>{const{delayChildren:d=0,staggerChildren:f,staggerDirection:p}=i;return Oxe(e,t,c,d,f,p,n)}:()=>Promise.resolve(),{when:a}=i;if(a){const[c,d]=a==="beforeChildren"?[s,o]:[o,s];return c().then(()=>d())}else return Promise.all([s(),o(n.delay)])}function Oxe(e,t,n=0,r=0,i=0,s=1,o){const a=[];for(const c of e.variantChildren)c.notify("AnimationStart",t),a.push(iC(c,t,{...o,delay:n+(typeof r=="function"?0:r)+nB(e.variantChildren,c,r,i,s)}).then(()=>c.notify("AnimationComplete",t)));return Promise.all(a)}function Axe(e,t,n={}){e.notify("AnimationStart",t);let r;if(Array.isArray(t)){const i=t.map(s=>iC(e,s,n));r=Promise.all(i)}else if(typeof t=="string")r=iC(e,t,n);else{const i=typeof t=="function"?Ud(e,t,n.custom):t;r=Promise.all(tB(e,i,n))}return r.then(()=>{e.notify("AnimationComplete",t)})}function rB(e,t){if(!Array.isArray(t))return!1;const n=t.length;if(n!==e.length)return!1;for(let r=0;r<n;r++)if(t[r]!==e[r])return!1;return!0}const Ixe=CR.length;function iB(e){if(!e)return;if(!e.isControllingVariants){const n=e.parent?iB(e.parent)||{}:{};return e.props.initial!==void 0&&(n.initial=e.props.initial),n}const t={};for(let n=0;n<Ixe;n++){const r=CR[n],i=e.props[r];(am(i)||i===!1)&&(t[r]=i)}return t}const Mxe=[...xR].reverse(),Dxe=xR.length;function Lxe(e){return t=>Promise.all(t.map(({animation:n,options:r})=>Axe(e,n,r)))}function Nxe(e){let t=Lxe(e),n=FM(),r=!0;const i=c=>(d,f)=>{const p=Ud(e,f,c==="exit"?e.presenceContext?.custom:void 0);if(p){const{transition:m,transitionEnd:v,...w}=p;d={...d,...w,...v}}return d};function s(c){t=c(e)}function o(c){const{props:d}=e,f=iB(e.parent)||{},p=[],m=new Set;let v={},w=1/0;for(let b=0;b<Dxe;b++){const C=Mxe[b],P=n[C],D=d[C]!==void 0?d[C]:f[C],F=am(D),R=C===c?P.isActive:null;R===!1&&(w=b);let I=D===f[C]&&D!==d[C]&&F;if(I&&r&&e.manuallyAnimateOnMount&&(I=!1),P.protectedKeys={...v},!P.isActive&&R===null||!D&&!P.prevProp||S1(D)||typeof D=="boolean")continue;const k=$xe(P.prevProp,D);let L=k||C===c&&P.isActive&&!I&&F||b>w&&F,B=!1;const A=Array.isArray(D)?D:[D];let V=A.reduce(i(C),{});R===!1&&(V={});const{prevResolvedValues:K={}}=P,W={...K,...V},U=x=>{L=!0,m.has(x)&&(B=!0,m.delete(x)),P.needsAnimating[x]=!0;const N=e.getValue(x);N&&(N.liveStyle=!1)};for(const x in W){const N=V[x],M=K[x];if(v.hasOwnProperty(x))continue;let E=!1;nC(N)&&nC(M)?E=!rB(N,M):E=N!==M,E?N!=null?U(x):m.add(x):N!==void 0&&m.has(x)?U(x):P.protectedKeys[x]=!0}P.prevProp=D,P.prevResolvedValues=V,P.isActive&&(v={...v,...V}),r&&e.blockInitialAnimation&&(L=!1);const q=I&&k;L&&(!q||B)&&p.push(...A.map(x=>{const N={type:C};if(typeof x=="string"&&r&&!q&&e.manuallyAnimateOnMount&&e.parent){const{parent:M}=e,E=Ud(M,x);if(M.enteringChildren&&E){const{delayChildren:O}=E.transition||{};N.delay=nB(M.enteringChildren,e,O)}}return{animation:x,options:N}}))}if(m.size){const b={};if(typeof d.initial!="boolean"){const C=Ud(e,Array.isArray(d.initial)?d.initial[0]:d.initial);C&&C.transition&&(b.transition=C.transition)}m.forEach(C=>{const P=e.getBaseTarget(C),D=e.getValue(C);D&&(D.liveStyle=!0),b[C]=P??null}),p.push({animation:b})}let _=!!p.length;return r&&(d.initial===!1||d.initial===d.animate)&&!e.manuallyAnimateOnMount&&(_=!1),r=!1,_?t(p):Promise.resolve()}function a(c,d){if(n[c].isActive===d)return Promise.resolve();e.variantChildren?.forEach(p=>p.animationState?.setActive(c,d)),n[c].isActive=d;const f=o(c);for(const p in n)n[p].protectedKeys={};return f}return{animateChanges:o,setActive:a,setAnimateFunction:s,getState:()=>n,reset:()=>{n=FM()}}}function $xe(e,t){return typeof t=="string"?t!==e:Array.isArray(t)?!rB(t,e):!1}function yc(e=!1){return{isActive:e,protectedKeys:{},needsAnimating:{},prevResolvedValues:{}}}function FM(){return{animate:yc(!0),whileInView:yc(),whileHover:yc(),whileTap:yc(),whileDrag:yc(),whileFocus:yc(),exit:yc()}}class Ul{constructor(t){this.isMounted=!1,this.node=t}update(){}}class jxe extends Ul{constructor(t){super(t),t.animationState||(t.animationState=Nxe(t))}updateAnimationControlsSubscription(){const{animate:t}=this.node.getProps();S1(t)&&(this.unmountControls=t.subscribe(this.node))}mount(){this.updateAnimationControlsSubscription()}update(){const{animate:t}=this.node.getProps(),{animate:n}=this.node.prevProps||{};t!==n&&this.updateAnimationControlsSubscription()}unmount(){this.node.animationState.reset(),this.unmountControls?.()}}let Fxe=0;class Uxe extends Ul{constructor(){super(...arguments),this.id=Fxe++}update(){if(!this.node.presenceContext)return;const{isPresent:t,onExitComplete:n}=this.node.presenceContext,{isPresent:r}=this.node.prevPresenceContext||{};if(!this.node.animationState||t===r)return;const i=this.node.animationState.setActive("exit",!t);n&&!t&&i.then(()=>{n(this.id)})}mount(){const{register:t,onExitComplete:n}=this.node.presenceContext||{};n&&n(this.id),t&&(this.unmount=t(this.id))}unmount(){}}const zxe={animation:{Feature:jxe},exit:{Feature:Uxe}};function cm(e,t,n,r={passive:!0}){return e.addEventListener(t,n,r),()=>e.removeEventListener(t,n)}function sg(e){return{point:{x:e.pageX,y:e.pageY}}}const Bxe=e=>t=>ER(t)&&e(t,sg(t));function xp(e,t,n,r){return cm(e,t,Bxe(n),r)}const sB=1e-4,Hxe=1-sB,Vxe=1+sB,oB=.01,Wxe=0-oB,qxe=0+oB;function Wr(e){return e.max-e.min}function Kxe(e,t,n){return Math.abs(e-t)<=n}function UM(e,t,n,r=.5){e.origin=r,e.originPoint=kn(t.min,t.max,e.origin),e.scale=Wr(n)/Wr(t),e.translate=kn(n.min,n.max,e.origin)-e.originPoint,(e.scale>=Hxe&&e.scale<=Vxe||isNaN(e.scale))&&(e.scale=1),(e.translate>=Wxe&&e.translate<=qxe||isNaN(e.translate))&&(e.translate=0)}function Cp(e,t,n,r){UM(e.x,t.x,n.x,r?r.originX:void 0),UM(e.y,t.y,n.y,r?r.originY:void 0)}function zM(e,t,n){e.min=n.min+t.min,e.max=e.min+Wr(t)}function Gxe(e,t,n){zM(e.x,t.x,n.x),zM(e.y,t.y,n.y)}function BM(e,t,n){e.min=t.min-n.min,e.max=e.min+Wr(t)}function t_(e,t,n){BM(e.x,t.x,n.x),BM(e.y,t.y,n.y)}function Wi(e){return[e("x"),e("y")]}const aB=({current:e})=>e?e.ownerDocument.defaultView:null,HM=(e,t)=>Math.abs(e-t);function Yxe(e,t){const n=HM(e.x,t.x),r=HM(e.y,t.y);return Math.sqrt(n**2+r**2)}class lB{constructor(t,n,{transformPagePoint:r,contextWindow:i=window,dragSnapToOrigin:s=!1,distanceThreshold:o=3}={}){if(this.startEvent=null,this.lastMoveEvent=null,this.lastMoveEventInfo=null,this.handlers={},this.contextWindow=window,this.updatePoint=()=>{if(!(this.lastMoveEvent&&this.lastMoveEventInfo))return;const m=YS(this.lastMoveEventInfo,this.history),v=this.startEvent!==null,w=Yxe(m.offset,{x:0,y:0})>=this.distanceThreshold;if(!v&&!w)return;const{point:_}=m,{timestamp:b}=wr;this.history.push({..._,timestamp:b});const{onStart:C,onMove:P}=this.handlers;v||(C&&C(this.lastMoveEvent,m),this.startEvent=this.lastMoveEvent),P&&P(this.lastMoveEvent,m)},this.handlePointerMove=(m,v)=>{this.lastMoveEvent=m,this.lastMoveEventInfo=GS(v,this.transformPagePoint),wn.update(this.updatePoint,!0)},this.handlePointerUp=(m,v)=>{this.end();const{onEnd:w,onSessionEnd:_,resumeAnimation:b}=this.handlers;if(this.dragSnapToOrigin&&b&&b(),!(this.lastMoveEvent&&this.lastMoveEventInfo))return;const C=YS(m.type==="pointercancel"?this.lastMoveEventInfo:GS(v,this.transformPagePoint),this.history);this.startEvent&&w&&w(m,C),_&&_(m,C)},!ER(t))return;this.dragSnapToOrigin=s,this.handlers=n,this.transformPagePoint=r,this.distanceThreshold=o,this.contextWindow=i||window;const a=sg(t),c=GS(a,this.transformPagePoint),{point:d}=c,{timestamp:f}=wr;this.history=[{...d,timestamp:f}];const{onSessionStart:p}=n;p&&p(t,YS(c,this.history)),this.removeListeners=ng(xp(this.contextWindow,"pointermove",this.handlePointerMove),xp(this.contextWindow,"pointerup",this.handlePointerUp),xp(this.contextWindow,"pointercancel",this.handlePointerUp))}updateHandlers(t){this.handlers=t}end(){this.removeListeners&&this.removeListeners(),Tl(this.updatePoint)}}function GS(e,t){return t?{point:t(e.point)}:e}function VM(e,t){return{x:e.x-t.x,y:e.y-t.y}}function YS({point:e},t){return{point:e,delta:VM(e,cB(t)),offset:VM(e,Jxe(t)),velocity:Zxe(t,.1)}}function Jxe(e){return e[0]}function cB(e){return e[e.length-1]}function Zxe(e,t){if(e.length<2)return{x:0,y:0};let n=e.length-1,r=null;const i=cB(e);for(;n>=0&&(r=e[n],!(i.timestamp-r.timestamp>eo(t)));)n--;if(!r)return{x:0,y:0};const s=Ji(i.timestamp-r.timestamp);if(s===0)return{x:0,y:0};const o={x:(i.x-r.x)/s,y:(i.y-r.y)/s};return o.x===1/0&&(o.x=0),o.y===1/0&&(o.y=0),o}function Xxe(e,{min:t,max:n},r){return t!==void 0&&e<t?e=r?kn(t,e,r.min):Math.max(e,t):n!==void 0&&e>n&&(e=r?kn(n,e,r.max):Math.min(e,n)),e}function WM(e,t,n){return{min:t!==void 0?e.min+t:void 0,max:n!==void 0?e.max+n-(e.max-e.min):void 0}}function Qxe(e,{top:t,left:n,bottom:r,right:i}){return{x:WM(e.x,n,i),y:WM(e.y,t,r)}}function qM(e,t){let n=t.min-e.min,r=t.max-e.max;return t.max-t.min<e.max-e.min&&([n,r]=[r,n]),{min:n,max:r}}function e2e(e,t){return{x:qM(e.x,t.x),y:qM(e.y,t.y)}}function t2e(e,t){let n=.5;const r=Wr(e),i=Wr(t);return i>r?n=im(t.min,t.max-r,e.min):r>i&&(n=im(e.min,e.max-i,t.min)),aa(0,1,n)}function n2e(e,t){const n={};return t.min!==void 0&&(n.min=t.min-e.min),t.max!==void 0&&(n.max=t.max-e.min),n}const sC=.35;function r2e(e=sC){return e===!1?e=0:e===!0&&(e=sC),{x:KM(e,"left","right"),y:KM(e,"top","bottom")}}function KM(e,t,n){return{min:GM(e,t),max:GM(e,n)}}function GM(e,t){return typeof e=="number"?e:e[t]||0}const i2e=new WeakMap;class s2e{constructor(t){this.openDragLock=null,this.isDragging=!1,this.currentDirection=null,this.originPoint={x:0,y:0},this.constraints=!1,this.hasMutatedConstraints=!1,this.elastic=nr(),this.latestPointerEvent=null,this.latestPanInfo=null,this.visualElement=t}start(t,{snapToCursor:n=!1,distanceThreshold:r}={}){const{presenceContext:i}=this.visualElement;if(i&&i.isPresent===!1)return;const s=p=>{const{dragSnapToOrigin:m}=this.getProps();m?this.pauseAnimation():this.stopAnimation(),n&&this.snapToCursor(sg(p).point)},o=(p,m)=>{const{drag:v,dragPropagation:w,onDragStart:_}=this.getProps();if(v&&!w&&(this.openDragLock&&this.openDragLock(),this.openDragLock=gEe(v),!this.openDragLock))return;this.latestPointerEvent=p,this.latestPanInfo=m,this.isDragging=!0,this.currentDirection=null,this.resolveConstraints(),this.visualElement.projection&&(this.visualElement.projection.isAnimationBlocked=!0,this.visualElement.projection.target=void 0),Wi(C=>{let P=this.getAxisMotionValue(C).get()||0;if(to.test(P)){const{projection:D}=this.visualElement;if(D&&D.layout){const F=D.layout.layoutBox[C];F&&(P=Wr(F)*(parseFloat(P)/100))}}this.originPoint[C]=P}),_&&wn.postRender(()=>_(p,m)),rC(this.visualElement,"transform");const{animationState:b}=this.visualElement;b&&b.setActive("whileDrag",!0)},a=(p,m)=>{this.latestPointerEvent=p,this.latestPanInfo=m;const{dragPropagation:v,dragDirectionLock:w,onDirectionLock:_,onDrag:b}=this.getProps();if(!v&&!this.openDragLock)return;const{offset:C}=m;if(w&&this.currentDirection===null){this.currentDirection=o2e(C),this.currentDirection!==null&&_&&_(this.currentDirection);return}this.updateAxis("x",m.point,C),this.updateAxis("y",m.point,C),this.visualElement.render(),b&&b(p,m)},c=(p,m)=>{this.latestPointerEvent=p,this.latestPanInfo=m,this.stop(p,m),this.latestPointerEvent=null,this.latestPanInfo=null},d=()=>Wi(p=>this.getAnimationState(p)==="paused"&&this.getAxisMotionValue(p).animation?.play()),{dragSnapToOrigin:f}=this.getProps();this.panSession=new lB(t,{onSessionStart:s,onStart:o,onMove:a,onSessionEnd:c,resumeAnimation:d},{transformPagePoint:this.visualElement.getTransformPagePoint(),dragSnapToOrigin:f,distanceThreshold:r,contextWindow:aB(this.visualElement)})}stop(t,n){const r=t||this.latestPointerEvent,i=n||this.latestPanInfo,s=this.isDragging;if(this.cancel(),!s||!i||!r)return;const{velocity:o}=i;this.startAnimation(o);const{onDragEnd:a}=this.getProps();a&&wn.postRender(()=>a(r,i))}cancel(){this.isDragging=!1;const{projection:t,animationState:n}=this.visualElement;t&&(t.isAnimationBlocked=!1),this.panSession&&this.panSession.end(),this.panSession=void 0;const{dragPropagation:r}=this.getProps();!r&&this.openDragLock&&(this.openDragLock(),this.openDragLock=null),n&&n.setActive("whileDrag",!1)}updateAxis(t,n,r){const{drag:i}=this.getProps();if(!r||!lv(t,i,this.currentDirection))return;const s=this.getAxisMotionValue(t);let o=this.originPoint[t]+r[t];this.constraints&&this.constraints[t]&&(o=Xxe(o,this.constraints[t],this.elastic[t])),s.set(o)}resolveConstraints(){const{dragConstraints:t,dragElastic:n}=this.getProps(),r=this.visualElement.projection&&!this.visualElement.projection.layout?this.visualElement.projection.measure(!1):this.visualElement.projection?.layout,i=this.constraints;t&&xd(t)?this.constraints||(this.constraints=this.resolveRefConstraints()):t&&r?this.constraints=Qxe(r.layoutBox,t):this.constraints=!1,this.elastic=r2e(n),i!==this.constraints&&r&&this.constraints&&!this.hasMutatedConstraints&&Wi(s=>{this.constraints!==!1&&this.getAxisMotionValue(s)&&(this.constraints[s]=n2e(r.layoutBox[s],this.constraints[s]))})}resolveRefConstraints(){const{dragConstraints:t,onMeasureDragConstraints:n}=this.getProps();if(!t||!xd(t))return!1;const r=t.current,{projection:i}=this.visualElement;if(!i||!i.layout)return!1;const s=axe(r,i.root,this.visualElement.getTransformPagePoint());let o=e2e(i.layout.layoutBox,s);if(n){const a=n(ixe(o));this.hasMutatedConstraints=!!a,a&&(o=qz(a))}return o}startAnimation(t){const{drag:n,dragMomentum:r,dragElastic:i,dragTransition:s,dragSnapToOrigin:o,onDragTransitionEnd:a}=this.getProps(),c=this.constraints||{},d=Wi(f=>{if(!lv(f,n,this.currentDirection))return;let p=c&&c[f]||{};o&&(p={min:0,max:0});const m=i?200:1e6,v=i?40:1e7,w={type:"inertia",velocity:r?t[f]:0,bounceStiffness:m,bounceDamping:v,timeConstant:750,restDelta:1,restSpeed:10,...s,...p};return this.startAxisValueAnimation(f,w)});return Promise.all(d).then(a)}startAxisValueAnimation(t,n){const r=this.getAxisMotionValue(t);return rC(this.visualElement,t),r.start(IR(t,r,0,n,this.visualElement,!1))}stopAnimation(){Wi(t=>this.getAxisMotionValue(t).stop())}pauseAnimation(){Wi(t=>this.getAxisMotionValue(t).animation?.pause())}getAnimationState(t){return this.getAxisMotionValue(t).animation?.state}getAxisMotionValue(t){const n=`_drag${t.toUpperCase()}`,r=this.visualElement.getProps(),i=r[n];return i||this.visualElement.getValue(t,(r.initial?r.initial[t]:void 0)||0)}snapToCursor(t){Wi(n=>{const{drag:r}=this.getProps();if(!lv(n,r,this.currentDirection))return;const{projection:i}=this.visualElement,s=this.getAxisMotionValue(n);if(i&&i.layout){const{min:o,max:a}=i.layout.layoutBox[n];s.set(t[n]-kn(o,a,.5))}})}scalePositionWithinConstraints(){if(!this.visualElement.current)return;const{drag:t,dragConstraints:n}=this.getProps(),{projection:r}=this.visualElement;if(!xd(n)||!r||!this.constraints)return;this.stopAnimation();const i={x:0,y:0};Wi(o=>{const a=this.getAxisMotionValue(o);if(a&&this.constraints!==!1){const c=a.get();i[o]=t2e({min:c,max:c},this.constraints[o])}});const{transformTemplate:s}=this.visualElement.getProps();this.visualElement.current.style.transform=s?s({},""):"none",r.root&&r.root.updateScroll(),r.updateLayout(),this.resolveConstraints(),Wi(o=>{if(!lv(o,t,null))return;const a=this.getAxisMotionValue(o),{min:c,max:d}=this.constraints[o];a.set(kn(c,d,i[o]))})}addListeners(){if(!this.visualElement.current)return;i2e.set(this.visualElement,this);const t=this.visualElement.current,n=xp(t,"pointerdown",c=>{const{drag:d,dragListener:f=!0}=this.getProps();d&&f&&this.start(c)}),r=()=>{const{dragConstraints:c}=this.getProps();xd(c)&&c.current&&(this.constraints=this.resolveRefConstraints())},{projection:i}=this.visualElement,s=i.addEventListener("measure",r);i&&!i.layout&&(i.root&&i.root.updateScroll(),i.updateLayout()),wn.read(r);const o=cm(window,"resize",()=>this.scalePositionWithinConstraints()),a=i.addEventListener("didUpdate",(({delta:c,hasLayoutChanged:d})=>{this.isDragging&&d&&(Wi(f=>{const p=this.getAxisMotionValue(f);p&&(this.originPoint[f]+=c[f].translate,p.set(p.get()+c[f].translate))}),this.visualElement.render())}));return()=>{o(),n(),s(),a&&a()}}getProps(){const t=this.visualElement.getProps(),{drag:n=!1,dragDirectionLock:r=!1,dragPropagation:i=!1,dragConstraints:s=!1,dragElastic:o=sC,dragMomentum:a=!0}=t;return{...t,drag:n,dragDirectionLock:r,dragPropagation:i,dragConstraints:s,dragElastic:o,dragMomentum:a}}}function lv(e,t,n){return(t===!0||t===e)&&(n===null||n===e)}function o2e(e,t=10){let n=null;return Math.abs(e.y)>t?n="y":Math.abs(e.x)>t&&(n="x"),n}class a2e extends Ul{constructor(t){super(t),this.removeGroupControls=Qi,this.removeListeners=Qi,this.controls=new s2e(t)}mount(){const{dragControls:t}=this.node.getProps();t&&(this.removeGroupControls=t.subscribe(this.controls)),this.removeListeners=this.controls.addListeners()||Qi}unmount(){this.removeGroupControls(),this.removeListeners()}}const YM=e=>(t,n)=>{e&&wn.postRender(()=>e(t,n))};class l2e extends Ul{constructor(){super(...arguments),this.removePointerDownListener=Qi}onPointerDown(t){this.session=new lB(t,this.createPanHandlers(),{transformPagePoint:this.node.getTransformPagePoint(),contextWindow:aB(this.node)})}createPanHandlers(){const{onPanSessionStart:t,onPanStart:n,onPan:r,onPanEnd:i}=this.node.getProps();return{onSessionStart:YM(t),onStart:YM(n),onMove:r,onEnd:(s,o)=>{delete this.session,i&&wn.postRender(()=>i(s,o))}}}mount(){this.removePointerDownListener=xp(this.node.current,"pointerdown",t=>this.onPointerDown(t))}update(){this.session&&this.session.updateHandlers(this.createPanHandlers())}unmount(){this.removePointerDownListener(),this.session&&this.session.end()}}const Wv={hasAnimatedSinceResize:!0,hasEverUpdated:!1};function JM(e,t){return t.max===t.min?0:e/(t.max-t.min)*100}const $h={correct:(e,t)=>
vendor: 5,106 bytes, line 265
265{if(!t.target)return e;if(typeof e=="string")if(at.test(e))e=parseFloat(e);else return e;const n=JM(e,t.target.x),r=JM(e,t.target.y);return`${n}% ${r}%`}},c2e={correct:(e,{treeScale:t,projectionDelta:n})=>{const r=e,i=Rl.parse(e);if(i.length>5)return r;const s=Rl.createTransformer(e),o=typeof i[0]!="number"?1:0,a=n.x.scale*t.x,c=n.y.scale*t.y;i[0+o]/=a,i[1+o]/=c;const d=kn(a,c,.5);return typeof i[2+o]=="number"&&(i[2+o]/=d),typeof i[3+o]=="number"&&(i[3+o]/=d),s(i)}};let JS=!1;class u2e extends g.Component{componentDidMount(){const{visualElement:t,layoutGroup:n,switchLayoutGroup:r,layoutId:i}=this.props,{projection:s}=t;IEe(d2e),s&&(n.group&&n.group.add(s),r&&r.register&&i&&r.register(s),JS&&s.root.didUpdate(),s.addEventListener("animationComplete",()=>{this.safeToRemove()}),s.setOptions({...s.options,onExitComplete:()=>this.safeToRemove()})),Wv.hasEverUpdated=!0}getSnapshotBeforeUpdate(t){const{layoutDependency:n,visualElement:r,drag:i,isPresent:s}=this.props,{projection:o}=r;return o&&(o.isPresent=s,JS=!0,i||t.layoutDependency!==n||n===void 0||t.isPresent!==s?o.willUpdate():this.safeToRemove(),t.isPresent!==s&&(s?o.promote():o.relegate()||wn.postRender(()=>{const a=o.getStack();(!a||!a.members.length)&&this.safeToRemove()}))),null}componentDidUpdate(){const{projection:t}=this.props.visualElement;t&&(t.root.didUpdate(),SR.postRender(()=>{!t.currentAnimation&&t.isLead()&&this.safeToRemove()}))}componentWillUnmount(){const{visualElement:t,layoutGroup:n,switchLayoutGroup:r}=this.props,{projection:i}=t;JS=!0,i&&(i.scheduleCheckAfterUnmount(),n&&n.group&&n.group.remove(i),r&&r.deregister&&r.deregister(i))}safeToRemove(){const{safeToRemove:t}=this.props;t&&t()}render(){return null}}function uB(e){const[t,n]=CEe(),r=g.useContext(BU);return j.jsx(u2e,{...e,layoutGroup:r,switchLayoutGroup:g.useContext(Vz),isPresent:t,safeToRemove:n})}const d2e={borderRadius:{...$h,applyTo:["borderTopLeftRadius","borderTopRightRadius","borderBottomLeftRadius","borderBottomRightRadius"]},borderTopLeftRadius:$h,borderTopRightRadius:$h,borderBottomLeftRadius:$h,borderBottomRightRadius:$h,boxShadow:c2e};function f2e(e,t,n){const r=Dr(e)?e:af(e);return r.start(IR("",r,t,n)),r.animation}const h2e=(e,t)=>e.depth-t.depth;class p2e{constructor(){this.children=[],this.isDirty=!1}add(t){rR(this.children,t),this.isDirty=!0}remove(t){iR(this.children,t),this.isDirty=!0}forEach(t){this.isDirty&&this.children.sort(h2e),this.isDirty=!1,this.children.forEach(t)}}function m2e(e,t){const n=ci.now(),r=({timestamp:i})=>{const s=i-n;s>=t&&(Tl(r),e(s-t))};return wn.setup(r,!0),()=>Tl(r)}const dB=["TopLeft","TopRight","BottomLeft","BottomRight"],g2e=dB.length,ZM=e=>typeof e=="string"?parseFloat(e):e,XM=e=>typeof e=="number"||at.test(e);function y2e(e,t,n,r,i,s){i?(e.opacity=kn(0,n.opacity??1,v2e(r)),e.opacityExit=kn(t.opacity??1,0,_2e(r))):s&&(e.opacity=kn(t.opacity??1,n.opacity??1,r));for(let o=0;o<g2e;o++){const a=`border${dB[o]}Radius`;let c=QM(t,a),d=QM(n,a);if(c===void 0&&d===void 0)continue;c||(c=0),d||(d=0),c===0||d===0||XM(c)===XM(d)?(e[a]=Math.max(kn(ZM(c),ZM(d),r),0),(to.test(d)||to.test(c))&&(e[a]+="%")):e[a]=d}(t.rotate||n.rotate)&&(e.rotate=kn(t.rotate||0,n.rotate||0,r))}function QM(e,t){return e[t]!==void 0?e[t]:e.borderRadius}const v2e=fB(0,.5,QU),_2e=fB(.5,.95,Qi);function fB(e,t,n){return r=>r<e?0:r>t?1:n(im(e,t,r))}function e8(e,t){e.min=t.min,e.max=t.max}function hs(e,t){e8(e.x,t.x),e8(e.y,t.y)}function t8(e,t){e.translate=t.translate,e.scale=t.scale,e.originPoint=t.originPoint,e.origin=t.origin}function n8(e,t,n,r,i){return e-=t,e=e_(e,1/n,r),i!==void 0&&(e=e_(e,1/i,r)),e}function w2e(e,t=0,n=1,r=.5,i,s=e,o=e){if(to.test(t)&&(t=parseFloat(t),t=kn(o.min,o.max,t/100)-o.min),typeof t!="number")return;let a=kn(s.min,s.max,r);e===s&&(a-=t),e.min=n8(e.min,t,n,a,i),e.max=n8(e.max,t,n,a,i)}function r8(e,t,[n,r,i],s,o){w2e(e,t[n],t[r],t[i],t.scale,s,o)}const b2e=["x","scaleX","originX"],S2e=["y","scaleY","originY"];function i8(e,t,n,r){r8(e.x,t,b2e,n?n.x:void 0,r?r.x:void 0),r8(e.y,t,S2e,n?n.y:void 0,r?r.y:void 0)}function s8(e){return e.translate===0&&e.scale===1}function hB(e){return s8(e.x)&&s8(e.y)}function o8(e,t){return e.min===t.min&&e.max===t.max}function E2e(e,t){return o8(e.x,t.x)&&o8(e.y,t.y)}function a8(e,t){return Math.round(e.min)===Math.round(t.min)&&Math.round(e.max)===Math.round(t.max)}function pB(e,t){return a8(e.x,t.x)&&a8(e.y,t.y)}function l8(e){return Wr(e.x)/Wr(e.y)}function c8(e,t){return e.translate===t.translate&&e.scale===t.scale&&e.originPoint===t.originPoint}class x2e{constructor(){this.members=[]}add(t){rR(this.members,t),t.scheduleRender()}remove(t){if(iR(this.members,t),t===this.prevLead&&(this.prevLead=void 0),t===this.lead){const n=this.members[this.members.length-1];n&&this.promote(n)}}relegate(t){const n=this.members.findIndex(i=>t===i);if(n===0)return!1;let r;for(let i=n;i>=0;i--){const s=this.members[i];if(s.isPresent!==!1){r=s;break}}return r?(this.promote(r),!0):!1}promote(t,n){const r=this.lead;if(t!==r&&(this.prevLead=r,this.lead=t,t.show(),r)){r.instance&&r.scheduleRender(),t.scheduleRender(),t.resumeFrom=r,
vendor: 22,244 bytes, line 265
265n&&(t.resumeFrom.preserveOpacity=!0),r.snapshot&&(t.snapshot=r.snapshot,t.snapshot.latestValues=r.animationValues||r.latestValues),t.root&&t.root.isUpdating&&(t.isLayoutDirty=!0);const{crossfade:i}=t.options;i===!1&&r.hide()}}exitAnimationComplete(){this.members.forEach(t=>{const{options:n,resumingFrom:r}=t;n.onExitComplete&&n.onExitComplete(),r&&r.options.onExitComplete&&r.options.onExitComplete()})}scheduleRender(){this.members.forEach(t=>{t.instance&&t.scheduleRender(!1)})}removeLeadSnapshot(){this.lead&&this.lead.snapshot&&(this.lead.snapshot=void 0)}}function C2e(e,t,n){let r="";const i=e.x.translate/t.x,s=e.y.translate/t.y,o=n?.z||0;if((i||s||o)&&(r=`translate3d(${i}px, ${s}px, ${o}px) `),(t.x!==1||t.y!==1)&&(r+=`scale(${1/t.x}, ${1/t.y}) `),n){const{transformPerspective:d,rotate:f,rotateX:p,rotateY:m,skewX:v,skewY:w}=n;d&&(r=`perspective(${d}px) ${r}`),f&&(r+=`rotate(${f}deg) `),p&&(r+=`rotateX(${p}deg) `),m&&(r+=`rotateY(${m}deg) `),v&&(r+=`skewX(${v}deg) `),w&&(r+=`skewY(${w}deg) `)}const a=e.x.scale*t.x,c=e.y.scale*t.y;return(a!==1||c!==1)&&(r+=`scale(${a}, ${c})`),r||"none"}const ZS=["","X","Y","Z"],k2e=1e3;let T2e=0;function XS(e,t,n,r){const{latestValues:i}=t;i[e]&&(n[e]=i[e],t.setStaticValue(e,0),r&&(r[e]=0))}function mB(e){if(e.hasCheckedOptimisedAppear=!0,e.root===e)return;const{visualElement:t}=e.options;if(!t)return;const n=eB(t);if(window.MotionHasOptimisedAnimation(n,"transform")){const{layout:i,layoutId:s}=e.options;window.MotionCancelOptimisedAnimation(n,"transform",wn,!(i||s))}const{parent:r}=e;r&&!r.hasCheckedOptimisedAppear&&mB(r)}function gB({attachResizeListener:e,defaultParent:t,measureScroll:n,checkIsScrollRoot:r,resetTransform:i}){return class{constructor(o={},a=t?.()){this.id=T2e++,this.animationId=0,this.animationCommitId=0,this.children=new Set,this.options={},this.isTreeAnimating=!1,this.isAnimationBlocked=!1,this.isLayoutDirty=!1,this.isProjectionDirty=!1,this.isSharedProjectionDirty=!1,this.isTransformDirty=!1,this.updateManuallyBlocked=!1,this.updateBlockedByResize=!1,this.isUpdating=!1,this.isSVG=!1,this.needsReset=!1,this.shouldResetTransform=!1,this.hasCheckedOptimisedAppear=!1,this.treeScale={x:1,y:1},this.eventHandlers=new Map,this.hasTreeAnimated=!1,this.layoutVersion=0,this.updateScheduled=!1,this.scheduleUpdate=()=>this.update(),this.projectionUpdateScheduled=!1,this.checkUpdateFailed=()=>{this.isUpdating&&(this.isUpdating=!1,this.clearAllSnapshots())},this.updateProjection=()=>{this.projectionUpdateScheduled=!1,this.nodes.forEach(O2e),this.nodes.forEach(D2e),this.nodes.forEach(L2e),this.nodes.forEach(A2e)},this.resolvedRelativeTargetAt=0,this.linkedParentVersion=0,this.hasProjected=!1,this.isVisible=!0,this.animationProgress=0,this.sharedNodes=new Map,this.latestValues=o,this.root=a?a.root||a:this,this.path=a?[...a.path,a]:[],this.parent=a,this.depth=a?a.depth+1:0;for(let c=0;c<this.path.length;c++)this.path[c].shouldResetTransform=!0;this.root===this&&(this.nodes=new p2e)}addEventListener(o,a){return this.eventHandlers.has(o)||this.eventHandlers.set(o,new aR),this.eventHandlers.get(o).add(a)}notifyListeners(o,...a){const c=this.eventHandlers.get(o);c&&c.notify(...a)}hasListeners(o){return this.eventHandlers.has(o)}mount(o){if(this.instance)return;this.isSVG=Az(o)&&!SEe(o),this.instance=o;const{layoutId:a,layout:c,visualElement:d}=this.options;if(d&&!d.current&&d.mount(o),this.root.nodes.add(this),this.parent&&this.parent.children.add(this),this.root.hasTreeAnimated&&(c||a)&&(this.isLayoutDirty=!0),e){let f,p=0;const m=()=>this.root.updateBlockedByResize=!1;wn.read(()=>{p=window.innerWidth}),e(o,()=>{const v=window.innerWidth;v!==p&&(p=v,this.root.updateBlockedByResize=!0,f&&f(),f=m2e(m,250),Wv.hasAnimatedSinceResize&&(Wv.hasAnimatedSinceResize=!1,this.nodes.forEach(f8)))})}a&&this.root.registerSharedNode(a,this),this.options.animate!==!1&&d&&(a||c)&&this.addEventListener("didUpdate",({delta:f,hasLayoutChanged:p,hasRelativeLayoutChanged:m,layout:v})=>{if(this.isTreeAnimationBlocked()){this.target=void 0,this.relativeTarget=void 0;return}const w=this.options.transition||d.getDefaultTransition()||U2e,{onLayoutAnimationStart:_,onLayoutAnimationComplete:b}=d.getProps(),C=!this.targetLayout||!pB(this.targetLayout,v),P=!p&&m;if(this.options.layoutRoot||this.resumeFrom||P||p&&(C||!this.currentAnimation)){this.resumeFrom&&(this.resumingFrom=this.resumeFrom,this.resumingFrom.resumingFrom=void 0);const D={...wR(w,"layout"),onPlay:_,onComplete:b};(d.shouldReduceMotion||this.options.layoutRoot)&&(D.delay=0,D.type=!1),this.startAnimation(D),this.setAnimationOrigin(f,P)}else p||f8(this),this.isLead()&&this.options.onExitComplete&&this.options.onExitComplete();this.targetLayout=v})}unmount(){this.options.layoutId&&this.willUpdate(),this.root.nodes.remove(this);const o=this.getStack();o&&o.remove(this),this.parent&&this.parent.children.delete(this),this.instance=void 0,this.eventHandlers.clear(),Tl(this.updateProjection)}blockUpdate(){this.updateManuallyBlocked=!0}unblockUpdate(){this.updateManuallyBlocked=!1}isUpdateBlocked(){return this.updateManuallyBlocked||this.updateBlockedByResize}isTreeAnimationBlocked(){return this.isAnimationBlocked||this.parent&&this.parent.isTreeAnimationBlocked()||!1}startUpdate(){this.isUpdateBlocked()||(this.isUpdating=!0,this.nodes&&this.nodes.forEach(N2e),this.animationId++)}getTransformTemplate(){const{visualElement:o}=this.options;return o&&o.getProps().transformTemplate}willUpdate(o=!0){if(this.root.hasTreeAnimated=!0,this.root.isUpdateBlocked()){this.options.onExitComplete&&this.options.onExitComplete();return}if(window.MotionCancelOptimisedAnimation&&!this.hasCheckedOptimisedAppear&&mB(this),!this.root.isUpdating&&this.root.startUpdate(),this.isLayoutDirty)return;this.isLayoutDirty=!0;for(let f=0;f<this.path.length;f++){const p=this.path[f];p.shouldResetTransform=!0,p.updateScroll("snapshot"),p.options.layoutRoot&&p.willUpdate(!1)}const{layoutId:a,layout:c}=this.options;if(a===void 0&&!c)return;const d=this.getTransformTemplate();this.prevTransformTemplateValue=d?d(this.latestValues,""):void 0,this.updateSnapshot(),o&&this.notifyListeners("willUpdate")}update(){if(this.updateScheduled=!1,this.isUpdateBlocked()){this.unblockUpdate(),this.clearAllSnapshots(),this.nodes.forEach(u8);return}if(this.animationId<=this.animationCommitId){this.nodes.forEach(d8);return}this.animationCommitId=this.animationId,this.isUpdating?(this.isUpdating=!1,this.nodes.forEach(M2e),this.nodes.forEach(R2e),this.nodes.forEach(P2e)):this.nodes.forEach(d8),this.clearAllSnapshots();const a=ci.now();wr.delta=aa(0,1e3/60,a-wr.timestamp),wr.timestamp=a,wr.isProcessing=!0,US.update.process(wr),US.preRender.process(wr),US.render.process(wr),wr.isProcessing=!1}didUpdate(){this.updateScheduled||(this.updateScheduled=!0,SR.read(this.scheduleUpdate))}clearAllSnapshots(){this.nodes.forEach(I2e),this.sharedNodes.forEach($2e)}scheduleUpdateProjection(){this.projectionUpdateScheduled||(this.projectionUpdateScheduled=!0,wn.preRender(this.updateProjection,!1,!0))}scheduleCheckAfterUnmount(){wn.postRender(()=>{this.isLayoutDirty?this.root.didUpdate():this.root.checkUpdateFailed()})}updateSnapshot(){this.snapshot||!this.instance||(this.snapshot=this.measure(),this.snapshot&&!Wr(this.snapshot.measuredBox.x)&&!Wr(this.snapshot.measuredBox.y)&&(this.snapshot=void 0))}updateLayout(){if(!this.instance||(this.updateScroll(),!(this.options.alwaysMeasureLayout&&this.isLead())&&!this.isLayoutDirty))return;if(this.resumeFrom&&!this.resumeFrom.instance)for(let c=0;c<this.path.length;c++)this.path[c].updateScroll();const o=this.layout;this.layout=this.measure(!1),this.layoutVersion++,this.layoutCorrected=nr(),this.isLayoutDirty=!1,this.projectionDelta=void 0,this.notifyListeners("measure",this.layout.layoutBox);const{visualElement:a}=this.options;a&&a.notify("LayoutMeasure",this.layout.layoutBox,o?o.layoutBox:void 0)}updateScroll(o="measure"){let a=!!(this.options.layoutScroll&&this.instance);if(this.scroll&&this.scroll.animationId===this.root.animationId&&this.scroll.phase===o&&(a=!1),a&&this.instance){const c=r(this.instance);this.scroll={animationId:this.root.animationId,phase:o,isRoot:c,offset:n(this.instance),wasRoot:this.scroll?this.scroll.isRoot:c}}}resetTransform(){if(!i)return;const o=this.isLayoutDirty||this.shouldResetTransform||this.options.alwaysMeasureLayout,a=this.projectionDelta&&!hB(this.projectionDelta),c=this.getTransformTemplate(),d=c?c(this.latestValues,""):void 0,f=d!==this.prevTransformTemplateValue;o&&this.instance&&(a||Ec(this.latestValues)||f)&&(i(this.instance,d),this.shouldResetTransform=!1,this.scheduleRender())}measure(o=!0){const a=this.measurePageBox();let c=this.removeElementScroll(a);return o&&(c=this.removeTransform(c)),z2e(c),{animationId:this.root.animationId,measuredBox:a,layoutBox:c,latestValues:{},source:this.id}}measurePageBox(){const{visualElement:o}=this.options;if(!o)return nr();const a=o.measureViewportBox();if(!(this.scroll?.wasRoot||this.path.some(B2e))){const{scroll:d}=this.root;d&&(Cd(a.x,d.offset.x),Cd(a.y,d.offset.y))}return a}removeElementScroll(o){const a=nr();if(hs(a,o),this.scroll?.wasRoot)return a;for(let c=0;c<this.path.length;c++){const d=this.path[c],{scroll:f,options:p}=d;d!==this.root&&f&&p.layoutScroll&&(f.wasRoot&&hs(a,o),Cd(a.x,f.offset.x),Cd(a.y,f.offset.y))}return a}applyTransform(o,a=!1){const c=nr();hs(c,o);for(let d=0;d<this.path.length;d++){const f=this.path[d];!a&&f.options.layoutScroll&&f.scroll&&f!==f.root&&kd(c,{x:-f.scroll.offset.x,y:-f.scroll.offset.y}),Ec(f.latestValues)&&kd(c,f.latestValues)}return Ec(this.latestValues)&&kd(c,this.latestValues),c}removeTransform(o){const a=nr();hs(a,o);for(let c=0;c<this.path.length;c++){const d=this.path[c];if(!d.instance||!Ec(d.latestValues))continue;Q2(d.latestValues)&&d.updateSnapshot();const f=nr(),p=d.measurePageBox();hs(f,p),i8(a,d.latestValues,d.snapshot?d.snapshot.layoutBox:void 0,f)}return Ec(this.latestValues)&&i8(a,this.latestValues),a}setTargetDelta(o){this.targetDelta=o,this.root.scheduleUpdateProjection(),this.isProjectionDirty=!0}setOptions(o){this.options={...this.options,...o,crossfade:o.crossfade!==void 0?o.crossfade:!0}}clearMeasurements(){this.scroll=void 0,this.layout=void 0,this.snapshot=void 0,this.prevTransformTemplateValue=void 0,this.targetDelta=void 0,this.target=void 0,this.isLayoutDirty=!1}forceRelativeParentToResolveTarget(){this.relativeParent&&this.relativeParent.resolvedRelativeTargetAt!==wr.timestamp&&this.relativeParent.resolveTargetDelta(!0)}resolveTargetDelta(o=!1){const a=this.getLead();this.isProjectionDirty||(this.isProjectionDirty=a.isProjectionDirty),this.isTransformDirty||(this.isTransformDirty=a.isTransformDirty),this.isSharedProjectionDirty||(this.isSharedProjectionDirty=a.isSharedProjectionDirty);const c=!!this.resumingFrom||this!==a;if(!(o||c&&this.isSharedProjectionDirty||this.isProjectionDirty||this.parent?.isProjectionDirty||this.attemptToResolveRelativeTarget||this.root.updateBlockedByResize))return;const{layout:f,layoutId:p}=this.options;if(!this.layout||!(f||p))return;this.resolvedRelativeTargetAt=wr.timestamp;const m=this.getClosestProjectingParent();m&&this.linkedParentVersion!==m.layoutVersion&&!m.options.layoutRoot&&this.removeRelativeTarget(),!this.targetDelta&&!this.relativeTarget&&(m&&m.layout?this.createRelativeTarget(m,this.layout.layoutBox,m.layout.layoutBox):this.removeRelativeTarget()),!(!this.relativeTarget&&!this.targetDelta)&&(this.target||(this.target=nr(),this.targetWithTransforms=nr()),this.relativeTarget&&this.relativeTargetOrigin&&this.relativeParent&&this.relativeParent.target?(this.forceRelativeParentToResolveTarget(),Gxe(this.target,this.relativeTarget,this.relativeParent.target)):this.targetDelta?(this.resumingFrom?this.target=this.applyTransform(this.layout.layoutBox):hs(this.target,this.layout.layoutBox),Gz(this.target,this.targetDelta)):hs(this.target,this.layout.layoutBox),this.attemptToResolveRelativeTarget&&(this.attemptToResolveRelativeTarget=!1,m&&!!m.resumingFrom==!!this.resumingFrom&&!m.options.layoutScroll&&m.target&&this.animationProgress!==1?this.createRelativeTarget(m,this.target,m.target):this.relativeParent=this.relativeTarget=void 0))}getClosestProjectingParent(){if(!(!this.parent||Q2(this.parent.latestValues)||Kz(this.parent.latestValues)))return this.parent.isProjecting()?this.parent:this.parent.getClosestProjectingParent()}isProjecting(){return!!((this.relativeTarget||this.targetDelta||this.options.layoutRoot)&&this.layout)}createRelativeTarget(o,a,c){this.relativeParent=o,this.linkedParentVersion=o.layoutVersion,this.forceRelativeParentToResolveTarget(),this.relativeTarget=nr(),this.relativeTargetOrigin=nr(),t_(this.relativeTargetOrigin,a,c),hs(this.relativeTarget,this.relativeTargetOrigin)}removeRelativeTarget(){this.relativeParent=this.relativeTarget=void 0}calcProjection(){const o=this.getLead(),a=!!this.resumingFrom||this!==o;let c=!0;if((this.isProjectionDirty||this.parent?.isProjectionDirty)&&(c=!1),a&&(this.isSharedProjectionDirty||this.isTransformDirty)&&(c=!1),this.resolvedRelativeTargetAt===wr.timestamp&&(c=!1),c)return;const{layout:d,layoutId:f}=this.options;if(this.isTreeAnimating=!!(this.parent&&this.parent.isTreeAnimating||this.currentAnimation||this.pendingAnimation),this.isTreeAnimating||(this.targetDelta=this.relativeTarget=void 0),!this.layout||!(d||f))return;hs(this.layoutCorrected,this.layout.layoutBox);const p=this.treeScale.x,m=this.treeScale.y;oxe(this.layoutCorrected,this.treeScale,this.path,a),o.layout&&!o.target&&(this.treeScale.x!==1||this.treeScale.y!==1)&&(o.target=o.layout.layoutBox,o.targetWithTransforms=nr());const{target:v}=o;if(!v){this.prevProjectionDelta&&(this.createProjectionDeltas(),this.scheduleRender());return}!this.projectionDelta||!this.prevProjectionDelta?this.createProjectionDeltas():(t8(this.prevProjectionDelta.x,this.projectionDelta.x),t8(this.prevProjectionDelta.y,this.projectionDelta.y)),Cp(this.projectionDelta,this.layoutCorrected,v,this.latestValues),(this.treeScale.x!==p||this.treeScale.y!==m||!c8(this.projectionDelta.x,this.prevProjectionDelta.x)||!c8(this.projectionDelta.y,this.prevProjectionDelta.y))&&(this.hasProjected=!0,this.scheduleRender(),this.notifyListeners("projectionUpdate",v))}hide(){this.isVisible=!1}show(){this.isVisible=!0}scheduleRender(o=!0){if(this.options.visualElement?.scheduleRender(),o){const a=this.getStack();a&&a.scheduleRender()}this.resumingFrom&&!this.resumingFrom.instance&&(this.resumingFrom=void 0)}createProjectionDeltas(){this.prevProjectionDelta=Td(),this.projectionDelta=Td(),this.projectionDeltaWithTransform=Td()}setAnimationOrigin(o,a=!1){const c=this.snapshot,d=c?c.latestValues:{},f={...this.latestValues},p=Td();(!this.relativeParent||!this.relativeParent.options.layoutRoot)&&(this.relativeTarget=this.relativeTargetOrigin=void 0),this.attemptToResolveRelativeTarget=!a;const m=nr(),v=c?c.source:void 0,w=this.layout?this.layout.source:void 0,_=v!==w,b=this.getStack(),C=!b||b.members.length<=1,P=!!(_&&!C&&this.options.crossfade===!0&&!this.path.some(F2e));this.animationProgress=0;let D;this.mixTargetDelta=F=>{const R=F/1e3;h8(p.x,o.x,R),h8(p.y,o.y,R),this.setTargetDelta(p),this.relativeTarget&&this.relativeTargetOrigin&&this.layout&&this.relativeParent&&this.relativeParent.layout&&(t_(m,this.layout.layoutBox,this.relativeParent.layout.layoutBox),j2e(this.relativeTarget,this.relativeTargetOrigin,m,R),D&&E2e(this.relativeTarget,D)&&(this.isProjectionDirty=!1),D||(D=nr()),hs(D,this.relativeTarget)),_&&(this.animationValues=f,y2e(f,d,this.latestValues,R,P,C)),this.root.scheduleUpdateProjection(),this.scheduleRender(),this.animationProgress=R},this.mixTargetDelta(this.options.layoutRoot?1e3:0)}startAnimation(o){this.notifyListeners("animationStart"),this.currentAnimation?.stop(),this.resumingFrom?.currentAnimation?.stop(),this.pendingAnimation&&(Tl(this.pendingAnimation),this.pendingAnimation=void 0),this.pendingAnimation=wn.update(()=>{Wv.hasAnimatedSinceResize=!0,this.motionValue||(this.motionValue=af(0)),this.currentAnimation=f2e(this.motionValue,[0,1e3],{...o,velocity:0,isSync:!0,onUpdate:a=>{this.mixTargetDelta(a),o.onUpdate&&o.onUpdate(a)},onStop:()=>{},onComplete:()=>{o.onComplete&&o.onComplete(),this.completeAnimation()}}),this.resumingFrom&&(this.resumingFrom.currentAnimation=this.currentAnimation),this.pendingAnimation=void 0})}completeAnimation(){this.resumingFrom&&(this.resumingFrom.currentAnimation=void 0,this.resumingFrom.preserveOpacity=void 0);const o=this.getStack();o&&o.exitAnimationComplete(),this.resumingFrom=this.currentAnimation=this.animationValues=void 0,this.notifyListeners("animationComplete")}finishAnimation(){this.currentAnimation&&(this.mixTargetDelta&&this.mixTargetDelta(k2e),this.currentAnimation.stop()),this.completeAnimation()}applyTransformsToTarget(){const o=this.getLead();let{targetWithTransforms:a,target:c,layout:d,latestValues:f}=o;if(!(!a||!c||!d)){if(this!==o&&this.layout&&d&&yB(this.options.animationType,this.layout.layoutBox,d.layoutBox)){c=this.target||nr();const p=Wr(this.layout.layoutBox.x);c.x.min=o.target.x.min,c.x.max=c.x.min+p;const m=Wr(this.layout.layoutBox.y);c.y.min=o.target.y.min,c.y.max=c.y.min+m}hs(a,c),kd(a,f),Cp(this.projectionDeltaWithTransform,this.layoutCorrected,a,f)}}registerSharedNode(o,a){this.sharedNodes.has(o)||this.sharedNodes.set(o,new x2e),this.sharedNodes.get(o).add(a);const d=a.options.initialPromotionConfig;a.promote({transition:d?d.transition:void 0,preserveFollowOpacity:d&&d.shouldPreserveFollowOpacity?d.shouldPreserveFollowOpacity(a):void 0})}isLead(){const o=this.getStack();return o?o.lead===this:!0}getLead(){const{layoutId:o}=this.options;return o?this.getStack()?.lead||this:this}getPrevLead(){const{layoutId:o}=this.options;return o?this.getStack()?.prevLead:void 0}getStack(){const{layoutId:o}=this.options;if(o)return this.root.sharedNodes.get(o)}promote({needsReset:o,transition:a,preserveFollowOpacity:c}={}){const d=this.getStack();d&&d.promote(this,c),o&&(this.projectionDelta=void 0,this.needsReset=!0),a&&this.setOptions({transition:a})}relegate(){const o=this.getStack();return o?o.relegate(this):!1}resetSkewAndRotation(){const{visualElement:o}=this.options;if(!o)return;let a=!1;const{latestValues:c}=o;if((c.z||c.rotate||c.rotateX||c.rotateY||c.rotateZ||c.skewX||c.skewY)&&(a=!0),!a)return;const d={};c.z&&XS("z",o,d,this.animationValues);for(let f=0;f<ZS.length;f++)XS(`rotate${ZS[f]}`,o,d,this.animationValues),XS(`skew${ZS[f]}`,o,d,this.animationValues);o.render();for(const f in d)o.setStaticValue(f,d[f]),this.animationValues&&(this.animationValues[f]=d[f]);o.scheduleRender()}applyProjectionStyles(o,a){if(!this.instance||this.isSVG)return;if(!this.isVisible){o.visibility="hidden";return}const c=this.getTransformTemplate();if(this.needsReset){this.needsReset=!1,o.visibility="",o.opacity="",o.pointerEvents=Vv(a?.pointerEvents)||"",o.transform=c?c(this.latestValues,""):"none";return}const d=this.getLead();if(!this.projectionDelta||!this.layout||!d.target){this.options.layoutId&&(o.opacity=this.latestValues.opacity!==void 0?this.latestValues.opacity:1,o.pointerEvents=Vv(a?.pointerEvents)||""),this.hasProjected&&!Ec(this.latestValues)&&(o.transform=c?c({},""):"none",this.hasProjected=!1);return}o.visibility="";const f=d.animationValues||d.latestValues;this.applyTransformsToTarget();let p=C2e(this.projectionDeltaWithTransform,this.treeScale,f);c&&(p=c(f,p)),o.transform=p;const{x:m,y:v}=this.projectionDelta;o.transformOrigin=`${m.origin*100}% ${v.origin*100}% 0`,d.animationValues?o.opacity=d===this?f.opacity??this.latestValues.opacity??1:this.preserveOpacity?this.latestValues.opacity:f.opacityExit:o.opacity=d===this?f.opacity!==void 0?f.opacity:"":f.opacityExit!==void 0?f.opacityExit:0;for(const w in lm){if(f[w]===void 0)continue;const{correct:_,applyTo:b,isCSSVariable:C}=lm[w],P=p==="none"?f[w]:_(f[w],d);if(b){const D=b.length;for(let F=0;F<D;F++)o[b[F]]=P}else C?this.options.visualElement.renderState.vars[w]=P:o[w]=P}this.options.layoutId&&(o.pointerEvents=d===this?Vv(a?.pointerEvents)||"":"none")}clearSnapshot(){this.resumeFrom=this.snapshot=void 0}resetTree(){this.root.nodes.forEach(o=>o.currentAnimation?.stop()),this.root.nodes.forEach(u8),this.root.sharedNodes.clear()}}}function R2e(e){e.updateLayout()}function P2e(e){const t=e.resumeFrom?.snapshot||e.snapshot;if(e.isLead()&&e.layout&&t&&e.hasListeners("didUpdate")){const{layoutBox:n,measuredBox:r}=e.layout,{animationType:i}=e.options,s=t.source!==e.layout.source;i==="size"?Wi(f=>{const p=s?t.measuredBox[f]:t.layoutBox[f],m=Wr(p);p.min=n[f].min,p.max=p.min+m}):yB(i,t.layoutBox,n)&&Wi(f=>{const p=s?t.measuredBox[f]:t.layoutBox[f],m=Wr(n[f]);p.max=p.min+m,e.relativeTarget&&!e.currentAnimation&&(e.isProjectionDirty=!0,e.relativeTarget[f].max=e.relativeTarget[f].min+m)});const o=Td();Cp(o,n,t.layoutBox);const a=Td();s?Cp(a,e.applyTransform(r,!0),t.measuredBox):Cp(a,n,t.layoutBox);const c=!hB(o);let d=!1;if(!e.resumeFrom){const f=e.getClosestProjectingParent();if(f&&!f.resumeFrom){const{snapshot:p,layout:m}=f;if(p&&m){const v=nr();t_(v,t.layoutBox,p.layoutBox);const w=nr();t_(w,n,m.layoutBox),pB(v,w)||(d=!0),f.options.layoutRoot&&(e.relativeTarget=w,e.relativeTargetOrigin=v,e.relativeParent=f)}}}e.notifyListeners("didUpdate",{layout:n,snapshot:t,delta:a,layoutDelta:o,hasLayoutChanged:c,hasRelativeLayoutChanged:d})}else if(e.isLead()){const{onExitComplete:n}=e.options;n&&n()}e.options.transition=void 0}function O2e(e){e.parent&&(e.isProjecting()||(e.isProjectionDirty=e.parent.isProjectionDirty),e.isSharedProjectionDirty||(e.isSharedProjectionDirty=!!(e.isProjectionDirty||e.parent.isProjectionDirty||e.parent.isSharedProjectionDirty)),e.isTransformDirty||(e.isTransformDirty=e.parent.isTransformDirty))}function A2e(e){e.isProjectionDirty=e.isSharedProjectionDirty=e.isTransformDirty=!1}function I2e(e){e.clearSnapshot()}function u8(e){e.clearMeasurements()}function d8(e){e.isLayoutDirty=!1}function M2e(e){const{visualElement:t}=e.options;t&&t.getProps().onBeforeLayoutMeasure&&t.notify("BeforeLayoutMeasure"),e.resetTransform()}function f8(e){e.finishAnimation(),e.targetDelta=e.relativeTarget=e.target=void 0,e.isProjectionDirty=!0}function D2e(e){e.resolveTargetDelta()}function L2e(e){e.calcProjection()}
265function N2e(e){e.resetSkewAndRotation()}function $2e(e){e.removeLeadSnapshot()}function h8(e,t,n){e.translate=kn(t.translate,0,n),e.scale=kn(t.scale,1,n),e.origin=t.origin,e.originPoint=t.originPoint}function p8(e,t,n,r){e.min=kn(t.min,n.min,r),e.max=kn(t.max,n.max,r)}function j2e(e,t,n,r){p8(e.x,t.x,n.x,r),p8(e.y,t.y,n.y,r)}function F2e(e){return e.animationValues&&e.animationValues.opacityExit!==void 0}const U2e={duration:.45,ease:[.4,0,.1,1]},m8=e=>typeof navigator<"u"&&navigator.userAgent&&navigator.userAgent.toLowerCase().includes(e),g8=m8("applewebkit/")&&!m8("chrome/")?Math.round:Qi;function y8(e){e.min=g8(e.min),e.max=g8(e.max)}function z2e(e){y8(e.x),y8(e.y)}function yB(e,t,n){return e==="position"||e==="preserve-aspect"&&!Kxe(l8(t),l8(n),.2)}function B2e(e){return e!==e.root&&e.scroll?.wasRoot}const H2e=gB({attachResizeListener:(e,t)=>cm(e,"resize",t),measureScroll:()=>({x:document.documentElement.scrollLeft||document.body.scrollLeft,y:document.documentElement.scrollTop||document.body.scrollTop}),checkIsScrollRoot:()=>!0}),QS={current:void 0},vB=gB({measureScroll:e=>({x:e.scrollLeft,y:e.scrollTop}),defaultParent:()=>{if(!QS.current){const e=new H2e({});e.mount(window),e.setOptions({layoutScroll:!0}),QS.current=e}return QS.current},resetTransform:(e,t)=>{e.style.transform=t!==void 0?t:"none"},checkIsScrollRoot:e=>window.getComputedStyle(e).position==="fixed"}),V2e={pan:{Feature:l2e},drag:{Feature:a2e,ProjectionNode:vB,MeasureLayout:uB}};function v8(e,t,n){const{props:r}=e;e.animationState&&r.whileHover&&e.animationState.setActive("whileHover",n==="Start");const i="onHover"+n,s=r[i];s&&wn.postRender(()=>s(t,sg(t)))}class W2e extends Ul{mount(){const{current:t}=this.node;t&&(this.unmount=yEe(t,(n,r)=>(v8(this.node,r,"Start"),i=>v8(this.node,i,"End"))))}unmount(){}}class q2e extends Ul{constructor(){super(...arguments),this.isActive=!1}onFocus(){let t=!1;try{t=this.node.current.matches(":focus-visible")}catch{t=!0}!t||!this.node.animationState||(this.node.animationState.setActive("whileFocus",!0),this.isActive=!0)}onBlur(){!this.isActive||!this.node.animationState||(this.node.animationState.setActive("whileFocus",!1),this.isActive=!1)}mount(){this.unmount=ng(cm(this.node.current,"focus",()=>this.onFocus()),cm(this.node.current,"blur",()=>this.onBlur()))}unmount(){}}function _8(e,t,n){const{props:r}=e;if(e.current instanceof HTMLButtonElement&&e.current.disabled)return;e.animationState&&r.whileTap&&e.animationState.setActive("whileTap",n==="Start");const i="onTap"+(n==="End"?"":n),s=r[i];s&&wn.postRender(()=>s(t,sg(t)))}class K2e extends Ul{mount(){const{current:t}=this.node;t&&(this.unmount=bEe(t,(n,r)=>(_8(this.node,r,"Start"),(i,{success:s})=>_8(this.node,i,s?"End":"Cancel")),{useGlobalTarget:this.node.props.globalTapTarget}))}unmount(){}}const oC=new WeakMap,eE=new WeakMap,G2e=e=>{const t=oC.get(e.target);t&&t(e)},Y2e=e=>{e.forEach(G2e)};function J2e({root:e,...t}){const n=e||document;eE.has(n)||eE.set(n,{});const r=eE.get(n),i=JSON.stringify(t);return r[i]||(r[i]=new IntersectionObserver(Y2e,{root:e,...t})),r[i]}function Z2e(e,t,n){const r=J2e(t);return oC.set(e,n),r.observe(e),()=>{oC.delete(e),r.unobserve(e)}}const X2e={some:0,all:1};class Q2e extends Ul{constructor(){super(...arguments),this.hasEnteredView=!1,this.isInView=!1}startObserver(){this.unmount();const{viewport:t={}}=this.node.getProps(),{root:n,margin:r,amount:i="some",once:s}=t,o={root:n?n.current:void 0,rootMargin:r,threshold:typeof i=="number"?i:X2e[i]},a=c=>{const{isIntersecting:d}=c;if(this.isInView===d||(this.isInView=d,s&&!d&&this.hasEnteredView))return;d&&(this.hasEnteredView=!0),this.node.animationState&&this.node.animationState.setActive("whileInView",d);const{onViewportEnter:f,onViewportLeave:p}=this.node.getProps(),m=d?f:p;m&&m(c)};return Z2e(this.node.current,o,a)}mount(){this.startObserver()}update(){if(typeof IntersectionObserver>"u")return;const{props:t,prevProps:n}=this.node;["amount","margin","root"].some(eCe(t,n))&&this.startObserver()}unmount(){}}function eCe({viewport:e={}},{viewport:t={}}={}){return n=>e[n]!==t[n]}const tCe={inView:{Feature:Q2e},tap:{Feature:K2e},focus:{Feature:q2e},hover:{Feature:W2e}},nCe={layout:{ProjectionNode:vB,MeasureLayout:uB}},rCe={...zxe,...tCe,...V2e,...nCe},iCe=rxe(rCe,gxe),jh="8px",sCe="32px",oCe="64px",aCe=({options:e,value:t,onChange:n,className:r,iconClassName:i,buttonClassName:s,activeButtonClassName:o,hideLabelOnMobile:a=!0,variableWidth:c=!1,columns:d,disabled:f=!1})=>{const{isMobile:p}=A_(),m=e.findIndex(D=>D.value===t),v=d!=null&&d>1&&e.length>d,w=v?Math.ceil(e.length/d):1,_=D=>v&&D===e.length-1&&e.length%d===1,b=_(m),C=v?m%d:m,P=v?Math.floor(m/d):0;return j.jsxs(UU,{type:"single",variant:"slider",value:t,onValueChange:n,disabled:f,className:sn("relative",v&&"grid",r),style:v?{gridTemplateColumns:`repeat(${d}, minmax(0, 1fr))`}:void 0,children:[t&&m>-1&&j.jsx(iCe.div,{className:sn("absolute left-1 rounded-[10px] bg-white shadow",v?"top-1":"inset-y-1",o),style:v?{width:b?`calc(100% - ${jh})`:`calc((100% - ${jh}) / ${d})`,height:`calc((100% - ${jh}) / ${w})`}:{width:p&&c?`calc((100% - ${jh}) / ${e.length} + ${sCe})`:`calc((100% - ${jh}) / ${e.length})`},initial:!1,animate:v?{x:b?"0%":`${C*100}%`,y:`${P*100}%`}
265:{x:p&&c?`calc(100% * ${m} - (${oCe} * ${m}))`:`calc(100% * ${m})`},transition:{type:"spring",stiffness:300,damping:30}}),e.map((D,F)=>{const R=t===D.value;return j.jsxs(zU,{variant:"slider",value:D.value,className:sn("relative z-10",s),style:_(F)?{gridColumn:`span ${d} / span ${d}`}:void 0,children:[D.Icon&&j.jsx(D.Icon,{className:sn("size-4 transition-all duration-200 relative z-10 opacity-30 group-data-[state=on]:opacity-100",!D.activeIconStyle&&"group-data-[state=on]:text-primary",i),style:R?D.activeIconStyle:void 0}),j.jsx("span",{className:sn("relative z-10 text-[13px] lg:text-sm font-semibold lg:inline",a&&!R?"hidden":"inline"),children:D.label}),D.trailing]},D.value)})]})};var qv={exports:{}},lCe=qv.exports,w8;function cCe(){return w8||(w8=1,(function(e,t){(function(n,r){e.exports=r()})(lCe,(function(){var n,r,i=1e3,s=6e4,o=36e5,a=864e5,c=/\[([^\]]+)]|Y{1,4}|M{1,4}|D{1,2}|d{1,4}|H{1,2}|h{1,2}|a|A|m{1,2}|s{1,2}|Z{1,2}|SSS/g,d=31536e6,f=2628e6,p=/^(-|\+)?P(?:([-+]?[0-9,.]*)Y)?(?:([-+]?[0-9,.]*)M)?(?:([-+]?[0-9,.]*)W)?(?:([-+]?[0-9,.]*)D)?(?:T(?:([-+]?[0-9,.]*)H)?(?:([-+]?[0-9,.]*)M)?(?:([-+]?[0-9,.]*)S)?)?$/,m={years:d,months:f,days:a,hours:o,minutes:s,seconds:i,milliseconds:1,weeks:6048e5},v=function(I){return I instanceof F},w=function(I,k,L){return new F(I,L,k.$l)},_=function(I){return r.p(I)+"s"},b=function(I){return I<0},C=function(I){return b(I)?Math.ceil(I):Math.floor(I)},P=function(I){return Math.abs(I)},D=function(I,k){return I?b(I)?{negative:!0,format:""+P(I)+k}:{negative:!1,format:""+I+k}:{negative:!1,format:""}},F=(function(){function I(L,B,A){var V=this;if(this.$d={},this.$l=A,L===void 0&&(this.$ms=0,this.parseFromMilliseconds()),B)return w(L*m[_(B)],this);if(typeof L=="number")return this.$ms=L,this.parseFromMilliseconds(),this;if(typeof L=="object")return Object.keys(L).forEach((function(U){V.$d[_(U)]=L[U]})),this.calMilliseconds(),this;if(typeof L=="string"){var K=L.match(p);if(K){var W=K.slice(2).map((function(U){return U!=null?Number(U):0}));return this.$d.years=W[0],this.$d.months=W[1],this.$d.weeks=W[2],this.$d.days=W[3],this.$d.hours=W[4],this.$d.minutes=W[5],this.$d.seconds=W[6],this.calMilliseconds(),this}}return this}var k=I.prototype;return k.calMilliseconds=function(){var L=this;this.$ms=Object.keys(this.$d).reduce((function(B,A){return B+(L.$d[A]||0)*m[A]}),0)},k.parseFromMilliseconds=function(){var L=this.$ms;this.$d.years=C(L/d),L%=d,this.$d.months=C(L/f),L%=f,this.$d.days=C(L/a),L%=a,this.$d.hours=C(L/o),L%=o,this.$d.minutes=C(L/s),L%=s,this.$d.seconds=C(L/i),L%=i,this.$d.milliseconds=L},k.toISOString=function(){var L=D(this.$d.years,"Y"),B=D(this.$d.months,"M"),A=+this.$d.days||0;this.$d.weeks&&(A+=7*this.$d.weeks);var V=D(A,"D"),K=D(this.$d.hours,"H"),W=D(this.$d.minutes,"M"),U=this.$d.seconds||0;this.$d.milliseconds&&(U+=this.$d.milliseconds/1e3,U=Math.round(1e3*U)/1e3);var q=D(U,"S"),z=L.negative||B.negative||V.negative||K.negative||W.negative||q.negative,x=K.format||W.format||q.format?"T":"",N=(z?"-":"")+"P"+L.format+B.format+V.format+x+K.format+W.format+q.format;return N==="P"||N==="-P"?"P0D":N},k.toJSON=function(){return this.toISOString()},k.format=function(L){var B=L||"YYYY-MM-DDTHH:mm:ss",A={Y:this.$d.years,YY:r.s(this.$d.years,2,"0"),YYYY:r.s(this.$d.years,4,"0"),M:this.$d.months,MM:r.s(this.$d.months,2,"0"),D:this.$d.days,DD:r.s(this.$d.days,2,"0"),H:this.$d.hours,HH:r.s(this.$d.hours,2,"0"),m:this.$d.minutes,mm:r.s(this.$d.minutes,2,"0"),s:this.$d.seconds,ss:r.s(this.$d.seconds,2,"0"),SSS:r.s(this.$d.milliseconds,3,"0")};return B.replace(c,(function(V,K){return K||String(A[V])}))},k.as=function(L){return this.$ms/m[_(L)]},k.get=function(L){var B=this.$ms,A=_(L);return A==="milliseconds"?B%=1e3:B=A==="weeks"?C(B/m[A]):this.$d[A],B||0},k.add=function(L,B,A){var V;return V=B?L*m[_(B)]:v(L)?L.$ms:w(L,this).$ms,w(this.$ms+V*(A?-1:1),this)},k.subtract=function(L,B){return this.add(L,B,!0)},k.locale=function(L){var B=this.clone();return B.$l=L,B},k.clone=function(){return w(this.$ms,this)},k.humanize=function(L){return n().add(this.$ms,"ms").locale(this.$l).fromNow(!L)},k.valueOf=function(){return this.asMilliseconds()},k.milliseconds=function(){return this.get("milliseconds")},k.asMilliseconds=function(){return this.as("milliseconds")},k.seconds=function(){return this.get("seconds")},k.asSeconds=function(){return this.as("seconds")},k.minutes=function(){return this.get("minutes")},k.asMinutes=function(){return this.as("minutes")},k.hours=function(){return this.get("hours")},k.asHours=function(){return this.as("hours")},k.days=function(){return this.get("days")},k.asDays=function(){return this.as("days")},k.weeks=function(){return this.get("weeks")},k.asWeeks=function(){return this.as("weeks")},k.months=function(){return this.get("months")},k.asMonths=function(){return this.as("months")},k.years=function(){return this.get("years")},k.asYears=function(){return this.as("years")},I})(),R=function(I,k,L){return I.add(k.years()*L,"y").add(k.months()*L,"M").add(k.days()*L,"d").add(k.hours()*L,"h").add(k.minutes()*L,"m").add(k.seconds()*L,"s").add(k.milliseconds()*L,"ms")};return function(I,k,L){n=L,r=L().$utils(),L.duration=function(V,K){var W=L.locale();return w(V,{$l:W},K)},L.isDuration=v;var B=k.prototype.add,A=k.prototype.subtract;k.prototype.add=function(V,K){return v(V)?R(this,V,1):B.bind(this)(V,K)},k.prototype.subtract=function(V,K){return v(V)?R(this,V,-1):A.bind(this)(V,K)}}}))})(qv)),qv.exports}var uCe=cCe();const dCe=Pl(uCe);function fCe(e){const t=hCe(e),n=g.forwardRef((r,i)=>{const{children:s,...o}=r,a=g.Children.toArray(s),c=a.find(mCe);if(c){const d=c.props.children,f=a.map(p=>p===c?g.Children.count(d)>1?g.Children.only(null):g.isValidElement(d)?d.props.children:null:p);return j.jsx(t,{...o,ref:i,children:g.isValidElement(d)?g.cloneElement(d,void 0,f):null})}return j.jsx(t,{...o,ref:i,children:s})});return n.displayName=`${e}.Slot`,n}function hCe(e){const t=g.forwardRef((n,r)=>{const{children:i,...s}=n;
vendor: 4,476 bytes, line 265
265if(g.isValidElement(i)){const o=yCe(i),a=gCe(s,i.props);return i.type!==g.Fragment&&(a.ref=r?Ol(r,o):o),g.cloneElement(i,a)}return g.Children.count(i)>1?g.Children.only(null):null});return t.displayName=`${e}.SlotClone`,t}var pCe=Symbol("radix.slottable");function mCe(e){return g.isValidElement(e)&&typeof e.type=="function"&&"__radixId"in e.type&&e.type.__radixId===pCe}function gCe(e,t){const n={...t};for(const r in t){const i=e[r],s=t[r];/^on[A-Z]/.test(r)?i&&s?n[r]=(...a)=>{const c=s(...a);return i(...a),c}:i&&(n[r]=i):r==="style"?n[r]={...i,...s}:r==="className"&&(n[r]=[i,s].filter(Boolean).join(" "))}return{...e,...n}}function yCe(e){let t=Object.getOwnPropertyDescriptor(e.props,"ref")?.get,n=t&&"isReactWarning"in t&&t.isReactWarning;return n?e.ref:(t=Object.getOwnPropertyDescriptor(e,"ref")?.get,n=t&&"isReactWarning"in t&&t.isReactWarning,n?e.props.ref:e.props.ref||e.ref)}var x1="Dialog",[_B]=Al(x1),[vCe,Ms]=_B(x1),wB=e=>{const{__scopeDialog:t,children:n,open:r,defaultOpen:i,onOpenChange:s,modal:o=!0}=e,a=g.useRef(null),c=g.useRef(null),[d,f]=du({prop:r,defaultProp:i??!1,onChange:s,caller:x1});return j.jsx(vCe,{scope:t,triggerRef:a,contentRef:c,contentId:Lc(),titleId:Lc(),descriptionId:Lc(),open:d,onOpenChange:f,onOpenToggle:g.useCallback(()=>f(p=>!p),[f]),modal:o,children:n})};wB.displayName=x1;var bB="DialogTrigger",SB=g.forwardRef((e,t)=>{const{__scopeDialog:n,...r}=e,i=Ms(bB,n),s=lr(t,i.triggerRef);return j.jsx(yn.button,{type:"button","aria-haspopup":"dialog","aria-expanded":i.open,"aria-controls":i.contentId,"data-state":NR(i.open),...r,ref:s,onClick:gt(e.onClick,i.onOpenToggle)})});SB.displayName=bB;var MR="DialogPortal",[_Ce,EB]=_B(MR,{forceMount:void 0}),xB=e=>{const{__scopeDialog:t,forceMount:n,children:r,container:i}=e,s=Ms(MR,t);return j.jsx(_Ce,{scope:t,forceMount:n,children:g.Children.map(r,o=>j.jsx(co,{present:n||s.open,children:j.jsx(R_,{asChild:!0,container:i,children:o})}))})};xB.displayName=MR;var n_="DialogOverlay",CB=g.forwardRef((e,t)=>{const n=EB(n_,e.__scopeDialog),{forceMount:r=n.forceMount,...i}=e,s=Ms(n_,e.__scopeDialog);return s.modal?j.jsx(co,{present:r||s.open,children:j.jsx(bCe,{...i,ref:t})}):null});CB.displayName=n_;var wCe=fCe("DialogOverlay.RemoveScroll"),bCe=g.forwardRef((e,t)=>{const{__scopeDialog:n,...r}=e,i=Ms(n_,n);return j.jsx(BT,{as:wCe,allowPinchZoom:!0,shards:[i.contentRef],children:j.jsx(yn.div,{"data-state":NR(i.open),...r,ref:t,style:{pointerEvents:"auto",...r.style}})})}),lu="DialogContent",kB=g.forwardRef((e,t)=>{const n=EB(lu,e.__scopeDialog),{forceMount:r=n.forceMount,...i}=e,s=Ms(lu,e.__scopeDialog);return j.jsx(co,{present:r||s.open,children:s.modal?j.jsx(SCe,{...i,ref:t}):j.jsx(ECe,{...i,ref:t})})});kB.displayName=lu;var SCe=g.forwardRef((e,t)=>{const n=Ms(lu,e.__scopeDialog),r=g.useRef(null),i=lr(t,n.contentRef,r);return g.useEffect(()=>{const s=r.current;if(s)return OF(s)},[]),j.jsx(TB,{...e,ref:i,trapFocus:n.open,disableOutsidePointerEvents:!0,onCloseAutoFocus:gt(e.onCloseAutoFocus,s=>{s.preventDefault(),n.triggerRef.current?.focus()}),onPointerDownOutside:gt(e.onPointerDownOutside,s=>{const o=s.detail.originalEvent,a=o.button===0&&o.ctrlKey===!0;(o.button===2||a)&&s.preventDefault()}),onFocusOutside:gt(e.onFocusOutside,s=>s.preventDefault())})}),ECe=g.forwardRef((e,t)=>{const n=Ms(lu,e.__scopeDialog),r=g.useRef(!1),i=g.useRef(!1);return j.jsx(TB,{...e,ref:t,trapFocus:!1,disableOutsidePointerEvents:!1,onCloseAutoFocus:s=>{e.onCloseAutoFocus?.(s),s.defaultPrevented||(r.current||n.triggerRef.current?.focus(),s.preventDefault()),r.current=!1,i.current=!1},onInteractOutside:s=>{e.onInteractOutside?.(s),s.defaultPrevented||(r.current=!0,s.detail.originalEvent.type==="pointerdown"&&(i.current=!0));const o=s.target;n.triggerRef.current?.contains(o)&&s.preventDefault(),s.detail.originalEvent.type==="focusin"&&i.current&&s.preventDefault()}})}),TB=g.forwardRef((e,t)=>{const{__scopeDialog:n,trapFocus:r,onOpenAutoFocus:i,onCloseAutoFocus:s,...o}=e,a=Ms(lu,n),c=g.useRef(null),d=lr(t,c);return wF(),j.jsxs(j.Fragment,{children:[j.jsx(zT,{asChild:!0,loop:!0,trapped:r,onMountAutoFocus:i,onUnmountAutoFocus:s,children:j.jsx(S_,{role:"dialog",id:a.contentId,"aria-describedby":a.descriptionId,"aria-labelledby":a.titleId,"data-state":NR(a.open),...o,ref:d,onDismiss:()=>a.onOpenChange(!1)})}),j.jsxs(j.Fragment,{children:[j.jsx(xCe,{titleId:a.titleId}),j.jsx(kCe,{contentRef:c,descriptionId:a.descriptionId})]})]})}),DR="DialogTitle",RB=g.forwardRef((e,t)=>
265{const{__scopeDialog:n,...r}=e,i=Ms(DR,n);return j.jsx(yn.h2,{id:i.titleId,...r,ref:t})});RB.displayName=DR;var PB="DialogDescription",LR=g.forwardRef((e,t)=>{const{__scopeDialog:n,...r}=e,i=Ms(PB,n);return j.jsx(yn.p,{id:i.descriptionId,...r,ref:t})});LR.displayName=PB;var OB="DialogClose",AB=g.forwardRef((e,t)=>{const{__scopeDialog:n,...r}=e,i=Ms(OB,n);return j.jsx(yn.button,{type:"button",...r,ref:t,onClick:gt(e.onClick,()=>i.onOpenChange(!1))})});AB.displayName=OB;function NR(e){return e?"open":"closed"}var IB="DialogTitleWarning",[eAe,MB]=sq(IB,{contentName:lu,titleName:DR,docsSlug:"dialog"}),xCe=({titleId:e})=>{const t=MB(IB),n=`\`${t.contentName}\` requires a \`${t.titleName}\` for the component to be accessible for screen reader users. 266 267If you want to hide the \`${t.titleName}\`, you can wrap it with our VisuallyHidden component. 268 269For more information, see https://radix-ui.com/primitives/docs/components/${t.docsSlug}`;return g.useEffect(()=>{e&&(document.getElementById(e)||console.error(n))},[n,e]),null},CCe="DialogDescriptionWarning",kCe=({contentRef:e,descriptionId:t})=>{const r=`Warning: Missing \`Description\` or \`aria-describedby={undefined}\` for {${MB(CCe).contentName}}.`;return g.useEffect(()=>{const i=e.current?.getAttribute("aria-describedby");t&&i&&(document.getElementById(t)||console.warn(r))},[r,e,t]),null},DB=wB,TCe=SB,LB=xB,$R=CB,jR=kB,NB=RB,RCe=LR,FR=AB;function PCe({isOpen:e,onOpenChange:t,title:n,children:r}){return j.jsx(DB,{open:e,onOpenChange:t,children:j.jsxs(LB,{children:[j.jsx($R,{className:`fixed inset-0 bg-black/50 z-40 270 data-[state=open]:animate-in data-[state=closed]:animate-out 271 data-[state=closed]:fade-out-0 data-[state=open]:fade-in-0 272 data-[state=closed]:duration-300 data-[state=open]:duration-300`}),j.jsxs(jR,{className:`fixed top-0 left-0 bottom-0 w-full bg-[var(--color-background)] shadow-lg z-50 focus:outline-none 273 data-[state=open]:animate-in data-[state=closed]:animate-out 274 data-[state=closed]:slide-out-to-left data-[state=open]:slide-in-from-left 275 data-[state=closed]:duration-300 data-[state=open]:duration-300`,children:[j.jsxs("div",{className:"flex justify-between items-center px-5 py-6 border-b border-b-[var(--color-border)]",children:[n&&j.jsx(NB,{className:"text-lg font-semibold text-zinc-900 dark:text-white",children:n}),j.jsx(FR,{asChild:!0,children:j.jsx(x7,{className:"cursor-pointer w-7 h-7 text-[var(--color-navy-blue)] opacity-60"})})]}),j.jsx("div",{className:"overflow-y-auto max-h-full",children:r})]})]})})}const OCe=e=>g.createElement("svg",{width:22,height:18,viewBox:"0 0 22 18",fill:"none",xmlns:"http://www.w3.org/2000/svg",...e},g.createElement("g",{opacity:.6},g.createElement("path",{d:"M14 2L2 2",stroke:"#213860",strokeWidth:2.2,strokeLinecap:"round"}),g.createElement("path",{d:"M20 9L2 9",stroke:"#213860",strokeWidth:2.2,strokeLinecap:"round"}),g.createElement("path",{d:"M14 16L2 16",stroke:"#213860",strokeWidth:2.2,strokeLinecap:"round"}))),$B=e=>g.createElement("svg",{width:97,height:25,viewBox:"0 0 97 25",fill:"none",xmlns:"http://www.w3.org/2000/svg",...e},g.createElement("g",{clipPath:"url(#clip0_1136_10206)"},g.createElement("path",{fillRule:"evenodd",clipRule:"evenodd",d:"M64.9715 2.87407C64.5393 2.90524 64.1949 2.99875 63.9443 3.14838H63.9381C63.7126 3.28554 63.556 3.50374 63.4558 3.8217C63.3556 4.13342 63.293 4.58229 63.2805 5.14963H70.0382V7.97382H63.2742V20.2494H60.0363V7.97382H57.6501V5.14963H60.0425C60.0676 4.27057 60.1803 3.51621 60.387 2.899C60.625 2.17581 61.0321 1.58978 61.5957 1.15337C62.1406 0.729427 62.8671 0.42394 63.7439 0.249377C64.5832 0.0810474 65.6291 0 66.8441 0H70.0382V2.82419H66.8315C66.0925 2.82419 65.4662 2.84289 64.9715 2.87407ZM13.315 5.11832C14.4924 5.3677 15.4631 5.81034 16.2084 6.42131H16.2209C16.9725 7.03852 17.5299 7.88016 17.8681 8.91508C18.1938 9.91258 18.3629 11.1719 18.3629 12.662C18.3629 14.152 18.1938 15.4051 17.8681 16.4026C17.5299 17.4313 16.9725 18.2667 16.2147 18.8839C15.4631 19.4886 14.4924 19.9251 13.3212 20.1682C12.1876 20.4113 10.7973 20.5298 9.18143 20.5298C8.02905 20.5298 7.04578 20.4612 6.26291 20.3241C5.47379 20.1931 4.81618 20.0123 4.30262 19.8066C3.85795 19.6258 3.51349 19.4325 3.23793 19.2268V25.0123H0V5.15573H3.23793V5.91009C3.51349 5.71682 3.86422 5.54849 4.31515 5.3864C4.82244 5.2056 5.47379 5.04974 6.26291 4.93129C7.04578 4.81283 8.02279 4.75049 9.17517 4.75049C10.7847 4.75049 12.1814 4.87518 13.315 5.11832ZM7.07709 17.6433C7.68459 17.6807 8.3923 17.6994 9.17517 17.6994H9.18769C10.1021 17.6994 10.8975 17.6744 11.5551 17.6183C12.1939 17.5684 12.745 17.4687 13.1834 17.3315C13.5968 17.2068 13.9287 17.0261 14.1792 16.8078C14.4235 16.5959 14.6114 16.3153 14.7492 15.9724C14.8932 15.6046 14.9934 15.1557 15.0435 14.632C15.0999 14.0772 15.1249 13.4226 15.1249 12.6682C15.1249 11.9138 15.0936 11.253 15.0435 10.6981C14.9934 10.1682 14.8932 9.71308 14.7492 9.34525C14.6114 9.00236 14.4235 8.72181 14.1792 8.50361C13.9287 8.2854 13.5905 8.1046 13.1772 7.96745C12.7388 7.82405 12.1876 7.7243 11.5488 7.66819C10.8912 7.61832 10.0896 7.58715 9.18143 7.58715C8.39857 7.58715 7.69712 7.61208 7.08335 7.64949C6.49464 7.6869 5.96856 7.76794 5.52389 7.8864C5.10427 7.99862 4.74729 8.16071 4.46546 8.36645C4.18989 8.56595 3.96442 8.84026 3.78906 9.18316C3.60117 9.54475 3.46339 10.0061 3.37571 10.5547C3.28177 11.1283 3.23793 11.8141 3.23793 12.6308C3.23793 13.4475 3.28177 14.152 3.37571 14.7318C3.46339 15.2866 3.60117 15.7542 3.78906 16.1158C3.96442 16.4587 4.19615 16.733 4.46546 16.9325C4.74729 17.1383 5.10427 17.3004 5.52389 17.4126C5.96229 17.531 6.48838 17.6059 7.07709 17.6433ZM33.9387 15.6548C34.1016 15.2246 34.183 14.7321 34.183 14.1959L34.1767 14.2022V5.14979H37.4146V20.2495H34.1767V18.666C33.8761 18.959 33.4753 19.2396 32.9742 19.4889C32.398 19.782 31.6465 20.0313 30.7509 20.2246C29.8616 20.4179 28.7405 20.5176 27.4316 20.5176C26.3481 20.5176 25.3961 20.449 24.6132 20.3181C23.8116 20.181 23.1164 19.9815 22.5527 19.7134C21.9703 19.4391 21.4943 19.0899 21.1311 18.6722C20.7741 18.2608 20.4922 17.7807 20.3044 17.2446C20.1227 16.7271 19.9975 16.1411 19.9348 15.5052C19.8785 14.8879 19.8472 14.2084 19.8472 13.4852L19.8597 5.14355H23.0851V13.4104C23.0851 14.252 23.1477 14.9628 23.273 15.5301C23.3857 16.0538 23.6049 16.4528 23.9431 16.7645C24.2813 17.0762 24.7886 17.3131 25.4399 17.4565C26.1351 17.6124 27.0746 17.6934 28.2332 17.6934C29.4921 17.6934 30.5317 17.6061 31.3208 17.4254C32.0849 17.2446 32.6861 17.0014 33.112 16.6959C33.5191 16.4029 33.7884 16.06 33.9387 15.6548ZM56.0969 8.51607C55.8714 7.99238 55.5583 7.48116 55.1637 7.00735C
27554.7629 6.52106 54.2306 6.10336 53.5917 5.7667C52.9655 5.43627 52.2076 5.18066 51.3371 5.0061C50.4791 4.83777 49.4582 4.75049 48.2996 4.75049C46.6838 4.75049 45.2934 4.87518 44.1598 5.11832C42.9824 5.37393 42.0054 5.82904 41.2601 6.47742C40.5085 7.13203 39.9511 8.01109 39.6192 9.10211C39.2935 10.1557 39.1307 11.5024 39.1307 13.0921C39.1307 14.4949 39.2998 15.6794 39.6254 16.6208C39.9636 17.5934 40.521 18.3852 41.2851 18.9712C42.0304 19.5448 43.0012 19.9562 44.1723 20.1869C45.3059 20.4113 46.6963 20.5236 48.3058 20.5236C49.8089 20.5236 51.0991 20.4425 52.1325 20.2929C53.1909 20.1308 54.0677 19.8752 54.7253 19.5136C55.4205 19.1395 55.9341 18.6345 56.241 18.0173C56.5353 17.4188 56.6919 16.6956 56.6919 15.8664V15.4425H53.454V15.8664C53.454 16.2592 53.3851 16.5709 53.2535 16.8016C53.1345 17.0073 52.9091 17.1757 52.5771 17.3066C52.1951 17.4562 51.6628 17.556 50.9864 17.6121C50.2849 17.6682 49.3831 17.6994 48.3058 17.6994C47.1284 17.6994 46.1326 17.6557 45.3435 17.5747C44.5982 17.4999 44.0032 17.3191 43.5648 17.0385C43.1515 16.7767 42.8571 16.3652 42.6755 15.7792C42.5001 15.2368 42.4062 14.5448 42.3749 13.7156H56.266H56.6919V12.4999C56.6919 11.7517 56.648 11.0285 56.5729 10.3615C56.4915 9.66321 56.3349 9.046 56.1094 8.51607H56.0969ZM46.189 7.62455C46.8027 7.59338 47.5167 7.57468 48.2996 7.57468C49.2641 7.57468 50.097 7.63702 50.7672 7.76794C51.3997 7.8864 51.9195 8.1046 52.3078 8.41632C52.6961 8.72804 52.978 9.10834 53.1596 9.58839C53.3162 10.0061 53.4101 10.5797 53.4352 11.2904H42.3623C42.3749 10.7729 42.4187 10.3116 42.4939 9.92505C42.5753 9.47617 42.7005 9.12705 42.8696 8.89014C43.0387 8.65323 43.2705 8.44126 43.5523 8.26046C43.8404 8.07343 44.2036 7.93004 44.6233 7.83029C45.0617 7.7243 45.5877 7.65573 46.189 7.62455Z",fill:"#213860"})),g.createElement("path",{d:"M93.7617 5.12524V8.34844V20.624H96.9934V8.34844L96.9996 5.12524H93.7617Z",fill:"#00A75F"}),g.createElement("path",{d:"M93.7617 5.12524V8.34844V20.624H96.9934V8.34844L96.9996 5.12524H93.7617Z",fill:"url(#paint0_linear_1136_10206)",fillOpacity:.2}),g.createElement("path",{d:"M93.7617 0.749023V3.57321H96.9934L96.9996 0.749023H93.7617Z",fill:"#00A75F"}),g.createElement("path",{d:"M93.7617 0.749023V3.57321H96.9934L96.9996 0.749023H93.7617Z",fill:"url(#paint1_linear_1136_10206)",fillOpacity:.2}),g.createElement("path",{d:"M70.0512 17.8L70.0449 20.6242H73.2829V17.8H70.0512Z",fill:"#00A75F"}),g.createElement("path",{d:"M70.0512 17.8L70.0449 20.6242H73.2829V17.8H70.0512Z",fill:"url(#paint2_linear_1136_10206)",fillOpacity:.2}),g.createElement("path",{d:"M88.1375 5.12524V6.07287C87.5363 5.77362 86.8286 5.53672 86.0207 5.38085C85.1627 5.21253 84.1418 5.12524 82.9832 5.12524C81.3673 5.12524 79.977 5.24993 78.8434 5.49307C77.6659 5.74869 76.6889 6.2038 75.9436 6.85218C74.2401 8.44195 73.8706 10.6863 73.8143 13.0118C73.6639 15.3185 74.3842 17.7063 76.1816 19.2587C76.7578 19.7449 77.4092 20.1377 78.1043 20.3871C80.1147 21.1227 82.645 21.0542 84.7117 20.5991C85.6073 20.4058 86.3589 20.1564 86.9351 19.8634C87.4361 19.614 87.8369 19.3335 88.1375 19.0405V20.624H91.3755V5.12524H88.1375ZM88.1375 14.6888C87.981 18.2923 83.5218 18.1489 80.7598 18.0118C77.5971 17.8746 76.9582 16.0791 77.0772 13.23C76.952 10.1502 77.3716 8.11153 80.8726 8.00554C86.8474 7.66888 88.5822 8.36714 88.1501 14.5766V14.6826L88.1375 14.6888Z",fill:"#00A75F"}),g.createElement("path",{d:"M88.1375 5.12524V6.07287C87.5363 5.77362 86.8286 5.53672 86.0207 5.38085C85.1627 5.21253 84.1418 5.12524 82.9832 5.12524C81.3673 5.12524 79.977 5.24993 78.8434 5.49307C77.6659 5.74869 76.6889 6.2038 75.9436 6.85218C74.2401 8.44195 73.8706 10.6863 73.8143 13.0118C73.6639 15.3185 74.3842 17.7063 76.1816 19.2587C76.7578 19.7449 77.4092 20.1377 78.1043 20.3871C80.1147 21.1227 82.645 21.0542 84.7117 20.5991C85.6073 20.4058 86.3589 20.1564 86.9351 19.8634C87.4361 19.614 87.8369 19.3335 88.1375 19.0405V20.624H91.3755V5.12524H88.1375ZM88.1375 14.6888C87.981 18.2923 83.5218 18.1489 80.7598 18.0118C77.5971 17.8746 76.9582 16.0791 77.0772 13.23C76.952 10.1502 77.3716 8.11153 80.8726 8.00554C86.8474 7.66888 88.5822 8.36714 88.1501 14.5766V14.6826L88.1375 14.6888Z",fill:"url(#paint3_linear_1136_10206)",fillOpacity:.2}),g.createElement("defs",null,g.createElement("linearGradient",{id:"paint0_linear_1136_10206",x1:94.4447,y1:17.4758,x2:97.64,y2:17.0543,gradientUnits:"userSpaceOnUse"},g.createElement("stop",{stopColor:"white",stopOpacity:0}),g.createElement("stop",{offset:1,stopColor:"white"})),g.createElement("linearGradient",{id:"paint1_linear_1136_10206",x1:94.4447,y1:2.99955,x2:96.5778,y2:1.45543,gradientUnits:"userSpaceOnUse"},g.createElement("stop",{stopColor:"white",stopOpacity:0}),g.createElement("stop",{offset:1,stopColor:"white"})),g.createElement("linearGradient",{id:"paint2_linear_1136_10206",x1:70.7279,y1:20.0506,x2:72.861,y2:18.5064,gradientUnits:"userSpaceOnUse"},g.createElement("stop",{stopColor:"white",stopOpacity:0}),g.createElement("stop",{offset:1,stopColor:"white"})),g.createElement("linearGradient",{id:"paint3_linear_1136_10206",x1:77.5033,y1:17.7286,x2:89.3291,y2:9.42889,gradientUnits:"userSpaceOnUse"},g.createElement("stop",{stopColor:"white",stopOpacity:0}),g.createElement("stop",{offset:1,stopColor:"white"})),g.createElement("clipPath",{id:"clip0_1136_10206"},g.createElement("rect",{width:97,height:25,fill:"white"})))),ACe=e=>g.createElement("svg",{width:20,height:17,viewBox:"0 0 20 17",fill:"none",xmlns:"http://www.w3.org/2000/svg",...e},g.createElement("g",{clipPath:"url(#clip0_1136_10239)"},g.createElement("g",{clipPath:"url(#clip1_1136_10239)"},g.createElement("path",{d:"M10.621 14.4755C10.1298 14.554 9.61039 14.4324 9.18617 14.0932L5.61553 11.2416L3.29139 14.3756C2.76904 15.0801 1.80534 15.2013 1.1396 14.6476C0.473129 14.0933 0.3563 13.073 0.87874 12.3691L3.90315 8.2908C4.53962 7.43261 5.72733 7.27022 6.55156 7.92856L10.1164 10.7756L14.1625 5.2502C14.6805 4.54227 15.6433 4.41445 16.313 4.96477C16.9827 5.51442 17.1052 6.53385 16.5866 7.24188L11.8411 13.7224C11.5313 14.1454 11.
2750891 14.4021 10.6206 14.4769L10.621 14.4755Z",fill:"currentColor"}),g.createElement("path",{d:"M11.3104 5.28172L17.1092 9.90391C17.9077 10.5404 19.0402 9.87926 18.956 8.82566L18.4968 3.07613C18.4388 2.34736 17.7937 1.83346 17.116 1.9766L11.7766 3.10394C10.7975 3.31098 10.5121 4.64592 11.3105 5.28238L11.3104 5.28172Z",fill:"currentColor"}))),g.createElement("defs",null,g.createElement("clipPath",{id:"clip0_1136_10239"},g.createElement("rect",{width:20,height:17,fill:"white",transform:"matrix(-1 0 0 1 20 0)"})),g.createElement("clipPath",{id:"clip1_1136_10239"},g.createElement("rect",{width:19.254,height:11.3209,fill:"white",transform:"matrix(0.987477 -0.157763 0.142778 0.989755 -0.699219 4.8208)"})))),ICe=e=>g.createElement("svg",{width:22,height:18,viewBox:"0 0 22 18",fill:"none",xmlns:"http://www.w3.org/2000/svg",...e},g.createElement("g",null,g.createElement("path",{d:"M17 2L5 2",stroke:"currentColor",strokeWidth:2.8,strokeLinecap:"round"}),g.createElement("path",{d:"M20 9L2 9",stroke:"currentColor",strokeWidth:2.8,strokeLinecap:"round"}),g.createElement("path",{d:"M17 16L5 16",stroke:"currentColor",strokeWidth:2.8,strokeLinecap:"round"}))),jB=e=>g.createElement("svg",{width:16,height:16,viewBox:"0 0 16 16",fill:"none",xmlns:"http://www.w3.org/2000/svg",...e},g.createElement("path",{d:"M5.93359 5.03997C6.14026 2.63997 7.37359 1.65997 10.0736 1.65997H10.1603C13.1403 1.65997 14.3336 2.85331 14.3336 5.83331V10.18C14.3336 13.16 13.1403 14.3533 10.1603 14.3533H10.0736C7.39359 14.3533 6.16026 13.3866 5.94026 11.0266",stroke:"#F35656",strokeWidth:1.5,strokeLinecap:"round",strokeLinejoin:"round"}),g.createElement("path",{d:"M10.0007 8H2.41406",stroke:"#F35656",strokeWidth:1.5,strokeLinecap:"round",strokeLinejoin:"round"}),g.createElement("path",{d:"M3.89935 5.76666L1.66602 8L3.89935 10.2333",stroke:"#F35656",strokeWidth:1.5,strokeLinecap:"round",strokeLinejoin:"round"})),MCe=e=>g.createElement("svg",{width:17,height:17,viewBox:"0 0 17 17",fill:"none",xmlns:"http://www.w3.org/2000/svg",...e},g.createElement("path",{d:"M10.9101 4.19788C10.1718 4.08902 9.67223 4.4053 9.34238 5.04691C8.99094 5.73025 8.43619 7.4525 7.9696 7.91149C7.50061 8.37289 5.85734 8.90323 5.18024 9.26002C3.99457 9.88409 3.95979 11.2538 5.15026 11.8894C5.83035 12.2528 7.53239 12.7995 7.99119 13.2736C8.44398 13.7416 8.98494 15.407 9.32859 16.0867C9.93312 17.2817 11.3197 17.3149 11.9362 16.117C12.2877 15.4336 12.8424 13.7114 13.309 13.2524C13.8176 12.7523 15.4986 12.2425 16.2159 11.847C17.32 11.2381 17.2283 9.84963 16.1283 9.27393C15.4483 8.91775 13.7468 8.36442 13.2874 7.88971C12.7207 7.30374 12.3093 5.59116 11.8133 4.82074C11.6214 4.52261 11.2621 4.24988 10.9107 4.19788H10.9101Z",fill:"currentColor"}),g.createElement("path",{d:"M3.8651 0.0120778C3.43509 -0.0514182 3.14422 0.133023 2.95171 0.506742C2.7466 0.90465 2.42394 1.90789 2.15227 2.17518C1.87879 2.44428 0.922215 2.75269 0.527592 2.96071C-0.1633 3.32415 -0.183691 4.12178 0.510199 4.49248C0.906622 4.70413 1.89738 5.02282 2.16486 5.29857C2.43234 5.57433 2.7436 6.54128 2.94391 6.93677C3.29595 7.63281 4.10379 7.65216 4.46303 6.95431C4.66814 6.5564 4.9908 5.55316 5.26247 5.28588C5.55874 4.9944 6.53811 4.69748 6.95552 4.46708C7.59843 4.11271 7.54505 3.30359 6.90454 2.96857C6.50812 2.76115 5.51736 2.43883 5.24988 2.16248C4.91943 1.82141 4.68014 0.823617 4.39106 0.374912C4.27951 0.201356 4.07021 0.042314 3.8651 0.0120778Z",fill:"currentColor"}));ai.extend(dCe);const DCe=[{value:"practice",label:"Practice",Icon:MCe},{value:"progress",label:"Progress",Icon:ACe}],LCe=()=>{const e=Mi(),t=jl(),[n,r]=g.useState(e.pathname.split("/")[1]);g.useEffect(()=>{r(e.pathname.split("/")[1])},[e.pathname]);const i=s=>{t(`/${s}`)};return j.jsx("div",{className:"sticky top-0 z-50 bg-bg-default border-b border-b-secondary/10",children:j.jsx("div",{className:"max-w-[1307px] mx-auto px-4",children:j.jsxs("div",{className:"h-[83px] flex items-center justify-between gap-[21px]",children:[j.jsxs("div",{className:"flex gap-[14px] items-center",children:[j.jsx(NCe,{}),j.jsx(i1,{to:"/progress",children:j.jsx($B,{className:"w-[81px] h-[21px] lg:h-[24px] lg:w-auto"})}),j.jsx(gbe,{})]}),u_e,j.jsx(aCe,{options:DCe,value:n,onChange:i,iconClassName:"lg:size-5",buttonClassName:"lg:px-5 lg:h-10",variableWidth:!0})]})})})},NCe=()=>{const e=g.useRef(null),[t,n]=g.useState(!1),{isMobile:r}=A_(),{data:i}=LT(),{logout:s}=km(),o=jl(),a=async()=>{const p=localStorage.getItem(L2);localStorage.clear(),p&&localStorage.setItem(L2,p),_be(),s({logoutParams:{returnTo:"https://puef.ai"}})},c=i?.subscription?.status,f=c==="active"||c==="trialing"||oF(i);return j.jsx("div",{className:"relative",ref:e,children:r?j.jsxs(j.Fragment,{children:[j.jsx(OCe,{onClick:()=>
275n(!0),className:"w-[18px] h-[14px] cursor-pointer"}),j.jsx(PCe,{isOpen:t,onOpenChange:n,title:j.jsx($B,{className:"w-[81px] h-[21px] lg:h-[24px] lg:w-auto"}),children:j.jsx($Ce,{hidePlansEntry:f,handleLogout:a,setOpenMenu:n})})]}):j.jsxs(bU,{children:[j.jsx(SU,{children:j.jsxs("div",{className:"flex gap-[10px] rounded-[54px] bg-white p-2 items-center border border-[#E5E7EB] shadow-sm",children:[j.jsx(c_e,{name:i?.username,className:"size-7 min-w-7 min-h-7 p-0 cursor-pointer"}),j.jsx(ICe,{className:"size-[22px] text-secondary/60 cursor-pointer"})]})}),j.jsxs(JT,{align:"start",children:[j.jsx(Fd,{onSelect:()=>o("/account"),children:"Profile Settings"}),!f&&j.jsx(Fd,{onSelect:()=>{o("/plans"),n(!1)},children:"Subscription plans"}),j.jsx(ZT,{}),j.jsx(Fd,{onSelect:a,asChild:!0,children:j.jsxs(Kr,{variant:"text",className:"gap-2 text-error w-full font-medium justify-start",onClick:()=>{a(),n(!1)},children:[j.jsx(jB,{className:"w-[16px] h-[16px]"}),"Logout"]})})]})]})})},$Ce=({hidePlansEntry:e,handleLogout:t,setOpenMenu:n})=>{const r=jl();return j.jsxs("div",{children:[j.jsxs("div",{className:"px-4 flex flex-col py-7.5 border-b border-b-border gap-7.5",children:[j.jsx(Kr,{variant:"text",className:"w-fit text-sm font-medium",onClick:()=>{r("/account"),n(!1)},children:"Profile Settings"}),!e&&j.jsx(Kr,{variant:"text",className:"w-fit text-sm font-medium",onClick:()=>{r("/plans"),n(!1)},children:"Subscription plans"})]}),j.jsx("div",{className:"px-4 py-7.5",children:j.jsxs(Kr,{variant:"text",className:"cursor-pointer flex items-center gap-2 text-error text-sm font-medium",onClick:()=>{t(),n(!1)},children:[j.jsx(jB,{className:"w-[16px] h-[16px]"}),"Logout"]})})]})};var tE={},nE={},Fh={},rE={},b8;function jCe(){return b8||(b8=1,(function(e){Object.defineProperty(e,"__esModule",{value:!0}),e.default=void 0;var t={animating:!1,autoplaying:null,currentDirection:0,currentLeft:null,currentSlide:0,direction:1,dragging:!1,edgeDragged:!1,initialized:!1,lazyLoadedList:[],listHeight:null,listWidth:null,scrolling:!1,slideCount:null,slideHeight:null,slideWidth:null,swipeLeft:null,swiped:!1,swiping:!1,touchObject:{startX:0,startY:0,curX:0,curY:0},trackStyle:{},trackWidth:0,targetSlide:0};e.default=t})(rE)),rE}var iE,S8;function FCe(){if(S8)return iE;S8=1;var e="Expected a function",t=NaN,n="[object Symbol]",r=/^\s+|\s+$/g,i=/^[-+]0x[0-9a-f]+$/i,s=/^0b[01]+$/i,o=/^0o[0-7]+$/i,a=parseInt,c=typeof gy=="object"&&gy&&gy.Object===Object&&gy,d=typeof self=="object"&&self&&self.Object===Object&&self,f=c||d||Function("return this")(),p=Object.prototype,m=p.toString,v=Math.max,w=Math.min,_=function(){return f.Date.now()};function b(R,I,k){var L,B,A,V,K,W,U=0,q=!1,z=!1,x=!0;if(typeof R!="function")throw new TypeError(e);I=F(I)||0,C(k)&&(q=!!k.leading,z="maxWait"in k,A=z?v(F(k.maxWait)||0,I):A,x="trailing"in k?!!k.trailing:x);function N(le){var ye=L,xe=B;return L=B=void 0,U=le,V=R.apply(xe,ye),V}function M(le){return U=le,K=setTimeout(H,I),q?N(le):V}function E(le){var ye=le-W,xe=le-U,be=I-ye;return z?w(be,A-xe):be}function O(le){var ye=le-W,xe=le-U;return W===void 0||ye>=I||ye<0||z&&xe>=A}function H(){var le=_();if(O(le))return Z(le);K=setTimeout(H,E(le))}function Z(le){return K=void 0,x&&L?N(le):(L=B=void 0,V)}function X(){K!==void 0&&clearTimeout(K),U=0,L=W=B=K=void 0}function te(){return K===void 0?V:Z(_())}function oe(){var le=_(),ye=O(le);if(L=arguments,B=this,W=le,ye){if(K===void 0)return M(W);if(z)return K=setTimeout(H,I),N(W)}return K===void 0&&(K=setTimeout(H,I)),V}return oe.cancel=X,oe.flush=te,oe}function C(R){var I=typeof R;return!!R&&(I=="object"||I=="function")}function P(R){return!!R&&typeof R=="object"}function D(R){return typeof R=="symbol"||P(R)&&m.call(R)==n}function F(R){if(typeof R=="number")return R;if(D(R))return t;if(C(R)){var I=typeof R.valueOf=="function"?R.valueOf():R;R=C(I)?I+"":I}if(typeof R!="string")return R===0?R:+R;R=R.replace(r,"");var k=s.test(R);return k||o.test(R)?a(R.slice(2),k?2:8):i.test(R)?t:+R}return iE=b,iE}var sE={exports:{}};var E8;function C1(){return E8||(E8=1,(function(e){(function(){var t={}.hasOwnProperty;function n(){for(var s="",o=0;o<arguments.length;o++){var a=arguments[o];a&&(s=i(s,r(a)))}return s}function r(s){if(typeof s=="string"||typeof s=="number")return s;if(typeof s!="object")return"";if(Array.isArray(s))return n.apply(null,s);if(s.toString!==Object.prototype.toString&&!s.toString.toString().includes("[native code]"))return s.toString();var o="";for(var a in s)t.call(s,a)&&s[a]&&(o=i(o,a));return o}function i(s,o){return o?s?s+" "+o:s+o:s}e.exports?(n.default=n,e.exports=n):window.classNames=n}
275)()})(sE)),sE.exports}var Pe={},oE={},x8;function FB(){return x8||(x8=1,(function(e){Object.defineProperty(e,"__esModule",{value:!0}),e.default=void 0;var t=n(ao());function n(i){return i&&i.__esModule?i:{default:i}}var r={accessibility:!0,adaptiveHeight:!1,afterChange:null,appendDots:function(s){return t.default.createElement("ul",{style:{display:"block"}},s)},arrows:!0,autoplay:!1,autoplaySpeed:3e3,beforeChange:null,centerMode:!1,centerPadding:"50px",className:"",cssEase:"ease",customPaging:function(s){return t.default.createElement("button",null,s+1)},dots:!1,dotsClass:"slick-dots",draggable:!0,easing:"linear",edgeFriction:.35,fade:!1,focusOnSelect:!1,infinite:!0,initialSlide:0,lazyLoad:null,nextArrow:null,onEdge:null,onInit:null,onLazyLoadError:null,onReInit:null,pauseOnDotsHover:!1,pauseOnFocus:!1,pauseOnHover:!0,prevArrow:null,responsive:null,rows:1,rtl:!1,slide:"div",slidesPerRow:1,slidesToScroll:1,slidesToShow:1,speed:500,swipe:!0,swipeEvent:null,swipeToSlide:!1,touchMove:!0,touchThreshold:5,useCSS:!0,useTransform:!0,variableWidth:!1,vertical:!1,waitForAnimate:!0,asNavFor:null,unslick:!1};e.default=r})(oE)),oE}var C8;function og(){if(C8)return Pe;C8=1,Object.defineProperty(Pe,"__esModule",{value:!0}),Pe.checkSpecKeys=Pe.checkNavigable=Pe.changeSlide=Pe.canUseDOM=Pe.canGoNext=void 0,Pe.clamp=d,Pe.extractObject=void 0,Pe.filterSettings=N,Pe.validSettings=Pe.swipeStart=Pe.swipeMove=Pe.swipeEnd=Pe.slidesOnRight=Pe.slidesOnLeft=Pe.slideHandler=Pe.siblingDirection=Pe.safePreventDefault=Pe.lazyStartIndex=Pe.lazySlidesOnRight=Pe.lazySlidesOnLeft=Pe.lazyEndIndex=Pe.keyHandler=Pe.initializedState=Pe.getWidth=Pe.getTrackLeft=Pe.getTrackCSS=Pe.getTrackAnimateCSS=Pe.getTotalSlides=Pe.getSwipeDirection=Pe.getSlideCount=Pe.getRequiredLazySlides=Pe.getPreClones=Pe.getPostClones=Pe.getOnDemandLazySlides=Pe.getNavigableIndexes=Pe.getHeight=void 0;var e=n(ao()),t=n(FB());function n(M){return M&&M.__esModule?M:{default:M}}function r(M){"@babel/helpers - typeof";return r=typeof Symbol=="function"&&typeof Symbol.iterator=="symbol"?function(E){return typeof E}:function(E){return E&&typeof Symbol=="function"&&E.constructor===Symbol&&E!==Symbol.prototype?"symbol":typeof E},r(M)}function i(M,E){var O=Object.keys(M);if(Object.getOwnPropertySymbols){var H=Object.getOwnPropertySymbols(M);E&&(H=H.filter(function(Z){return Object.getOwnPropertyDescriptor(M,Z).enumerable})),O.push.apply(O,H)}return O}function s(M){for(var E=1;E<arguments.length;E++){var O=arguments[E]!=null?arguments[E]:{};E%2?i(Object(O),!0).forEach(function(H){o(M,H,O[H])}):Object.getOwnPropertyDescriptors?Object.defineProperties(M,Object.getOwnPropertyDescriptors(O)):i(Object(O)).forEach(function(H){Object.defineProperty(M,H,Object.getOwnPropertyDescriptor(O,H))})}return M}function o(M,E,O){return E=a(E),E in M?Object.defineProperty(M,E,{value:O,enumerable:!0,configurable:!0,writable:!0}):M[E]=O,M}function a(M){var E=c(M,"string");return r(E)=="symbol"?E:String(E)}function c(M,E){if(r(M)!="object"||!M)return M;var O=M[Symbol.toPrimitive];if(O!==void 0){var H=O.call(M,E);if(r(H)!="object")return H;throw new TypeError("@@toPrimitive must return a primitive value.")}return(E==="string"?String:Number)(M)}function d(M,E,O){return Math.max(E,Math.min(M,O))}var f=Pe.safePreventDefault=function(E){var O=["onTouchStart","onTouchMove","onWheel"];O.includes(E._reactName)||E.preventDefault()},p=Pe.getOnDemandLazySlides=function(E){for(var O=[],H=m(E),Z=v(E),X=H;X<Z;X++)E.lazyLoadedList.indexOf(X)<0&&O.push(X);return O};Pe.getRequiredLazySlides=function(E){for(var O=[],H=m(E),Z=v(E),X=H;X<Z;X++)O.push(X);return O};var m=Pe.lazyStartIndex=function(E){return E.currentSlide-w(E)},v=Pe.lazyEndIndex=function(E){return E.currentSlide+_(E)},w=Pe.lazySlidesOnLeft=function(E){return E.centerMode?Math.floor(E.slidesToShow/2)+(parseInt(E.centerPadding)>0?1:0):0},_=Pe.lazySlidesOnRight=function(E){return E.centerMode?Math.floor((E.slidesToShow-1)/2)+1+(parseInt(E.centerPadding)>0?1:0):E.slidesToShow},b=Pe.getWidth=function(E){return E&&E.offsetWidth||0},C=Pe.getHeight=function(E){return E&&E.offsetHeight||0},P=Pe.getSwipeDirection=function(E){var O=arguments.length>1&&arguments[1]!==void 0?arguments[1]:!1,H,Z,X,te;return H=E.startX-E.curX,Z=E.startY-E.curY,X=Math.atan2(Z,H),te=Math.round(X*180/Math.PI),te<0&&(te=360-Math.abs(te)),te<=45&&te>=0||te<=360&&te>=315?"left":te>=135&&te<=225?"right":O===!0?te>=35&&te<=135?"up":"down":"vertical"},D=Pe.canGoNext=function(E){var O=!0;return E.infinite||(E.centerMode&&E.currentSlide>=E.slideCount-1||E.slideCount<=E.slidesToShow||E.currentSlide>=E.slideCount-E.slidesToShow)&&(O=!1),O};Pe.extractObject=function(E,O){var H={};return O.forEach(function(Z){return H[Z]=E[Z]}),H},Pe.initializedState=function(E){var O=e.default.Children.count(E.children),H=E.listRef,Z=Math.ceil(b(H)),X=E.trackRef&&E.trackRef.node,te=Math.ceil(b(X)),oe;if(E.vertical)oe=Z;else{var le=E.centerMode&&parseInt(E.centerPadding)*2;typeof E.centerPadding=="string"&&E.centerPadding.slice(-1)==="%"&&(le*=Z/100),oe=Math.ceil((Z-le)/E.slidesToShow)}var ye=H&&C(H.querySelector('[data-index="0"]')),xe=ye*E.slidesToShow,be=E.currentSlide===void 0?E.initialSlide:E.currentSlide;E.rtl&&E.currentSlide===void 0&&(be=O-1-E.initialSlide);var rt=E.lazyLoadedList||[],Ue=p(s(s({},E),{},{currentSlide:be,lazyLoadedList:rt}));rt=rt.concat(Ue);var Ve={slideCount:O,slideWidth:oe,listWidth:Z,trackWidth:te,currentSlide:be,slideHeight:ye,listHeight:xe,lazyLoadedList:rt};return E.autoplaying===null&&E.autoplay&&(Ve.autoplaying="playing"),Ve},Pe.slideHandler=function(E){var O=E.waitForAnimate,H=E.animating,Z=E.fade,X=E.infinite,te=E.index,oe=E.slideCount,le=E.lazyLoad,ye=E.currentSlide,xe
vendor: 4,539 bytes, line 275
275=E.centerMode,be=E.slidesToScroll,rt=E.slidesToShow,Ue=E.useCSS,Ve=E.lazyLoadedList;if(O&&H)return{};var Qe=te,ht,Rt,it,Yt={},Xt={},Je=X?te:d(te,0,oe-1);if(Z){if(!X&&(te<0||te>=oe))return{};te<0?Qe=te+oe:te>=oe&&(Qe=te-oe),le&&Ve.indexOf(Qe)<0&&(Ve=Ve.concat(Qe)),Yt={animating:!0,currentSlide:Qe,lazyLoadedList:Ve,targetSlide:Qe},Xt={animating:!1,targetSlide:Qe}}else ht=Qe,Qe<0?(ht=Qe+oe,X?oe%be!==0&&(ht=oe-oe%be):ht=0):!D(E)&&Qe>ye?Qe=ht=ye:xe&&Qe>=oe?(Qe=X?oe:oe-1,ht=X?0:oe-1):Qe>=oe&&(ht=Qe-oe,X?oe%be!==0&&(ht=0):ht=oe-rt),!X&&Qe+rt>=oe&&(ht=oe-rt),Rt=A(s(s({},E),{},{slideIndex:Qe})),it=A(s(s({},E),{},{slideIndex:ht})),X||(Rt===it&&(Qe=ht),Rt=it),le&&(Ve=Ve.concat(p(s(s({},E),{},{currentSlide:Qe})))),Ue?(Yt={animating:!0,currentSlide:ht,trackStyle:B(s(s({},E),{},{left:Rt})),lazyLoadedList:Ve,targetSlide:Je},Xt={animating:!1,currentSlide:ht,trackStyle:L(s(s({},E),{},{left:it})),swipeLeft:null,targetSlide:Je}):Yt={currentSlide:ht,trackStyle:L(s(s({},E),{},{left:it})),lazyLoadedList:Ve,targetSlide:Je};return{state:Yt,nextState:Xt}},Pe.changeSlide=function(E,O){var H,Z,X,te,oe,le=E.slidesToScroll,ye=E.slidesToShow,xe=E.slideCount,be=E.currentSlide,rt=E.targetSlide,Ue=E.lazyLoad,Ve=E.infinite;if(te=xe%le!==0,H=te?0:(xe-be)%le,O.message==="previous")X=H===0?le:ye-H,oe=be-X,Ue&&!Ve&&(Z=be-X,oe=Z===-1?xe-1:Z),Ve||(oe=rt-le);else if(O.message==="next")X=H===0?le:H,oe=be+X,Ue&&!Ve&&(oe=(be+le)%xe+H),Ve||(oe=rt+le);else if(O.message==="dots")oe=O.index*O.slidesToScroll;else if(O.message==="children"){if(oe=O.index,Ve){var Qe=U(s(s({},E),{},{targetSlide:oe}));oe>O.currentSlide&&Qe==="left"?oe=oe-xe:oe<O.currentSlide&&Qe==="right"&&(oe=oe+xe)}}else O.message==="index"&&(oe=Number(O.index));return oe},Pe.keyHandler=function(E,O,H){return E.target.tagName.match("TEXTAREA|INPUT|SELECT")||!O?"":E.keyCode===37?H?"next":"previous":E.keyCode===39?H?"previous":"next":""},Pe.swipeStart=function(E,O,H){return E.target.tagName==="IMG"&&f(E),!O||!H&&E.type.indexOf("mouse")!==-1?"":{dragging:!0,touchObject:{startX:E.touches?E.touches[0].pageX:E.clientX,startY:E.touches?E.touches[0].pageY:E.clientY,curX:E.touches?E.touches[0].pageX:E.clientX,curY:E.touches?E.touches[0].pageY:E.clientY}}},Pe.swipeMove=function(E,O){var H=O.scrolling,Z=O.animating,X=O.vertical,te=O.swipeToSlide,oe=O.verticalSwiping,le=O.rtl,ye=O.currentSlide,xe=O.edgeFriction,be=O.edgeDragged,rt=O.onEdge,Ue=O.swiped,Ve=O.swiping,Qe=O.slideCount,ht=O.slidesToScroll,Rt=O.infinite,it=O.touchObject,Yt=O.swipeEvent,Xt=O.listHeight,Je=O.listWidth;if(!H){if(Z)return f(E);X&&te&&oe&&f(E);var jt,ot={},on=A(O);it.curX=E.touches?E.touches[0].pageX:E.clientX,it.curY=E.touches?E.touches[0].pageY:E.clientY,it.swipeLength=Math.round(Math.sqrt(Math.pow(it.curX-it.startX,2)));var yt=Math.round(Math.sqrt(Math.pow(it.curY-it.startY,2)));if(!oe&&!Ve&&yt>10)return{scrolling:!0};oe&&(it.swipeLength=yt);var Un=(le?-1:1)*(it.curX>it.startX?1:-1);oe&&(Un=it.curY>it.startY?1:-1);var zl=Math.ceil(Qe/ht),kr=P(O.touchObject,oe),zn=it.swipeLength;return Rt||(ye===0&&(kr==="right"||kr==="down")||ye+1>=zl&&(kr==="left"||kr==="up")||!D(O)&&(kr==="left"||kr==="up"))&&(zn=it.swipeLength*xe,be===!1&&rt&&(rt(kr),ot.edgeDragged=!0)),!Ue&&Yt&&(Yt(kr),ot.swiped=!0),X?jt=on+zn*(Xt/Je)*Un:le?jt=on-zn*Un:jt=on+zn*Un,oe&&(jt=on+zn*Un),ot=s(s({},ot),{},{touchObject:it,swipeLeft:jt,trackStyle:L(s(s({},O),{},{left:jt}))}),Math.abs(it.curX-it.startX)<Math.abs(it.curY-it.startY)*.8||it.swipeLength>10&&(ot.swiping=!0,f(E)),ot}},Pe.swipeEnd=function(E,O){var H=O.dragging,Z=O.swipe,X=O.touchObject,te=O.listWidth,oe=O.touchThreshold,le=O.verticalSwiping,ye=O.listHeight,xe=O.swipeToSlide,be=O.scrolling,rt=O.onSwipe,Ue=O.targetSlide,Ve=O.currentSlide,Qe=O.infinite;if(!H)return Z&&f(E),{};var ht=le?ye/oe:te/oe,Rt=P(X,le),it={dragging:!1,edgeDragged:!1,scrolling:!1,swiping:!1,swiped:!1,swipeLeft:null,touchObject:{}};if(be||!X.swipeLength)return it;if(X.swipeLength>ht){f(E),rt&&rt(Rt);var Yt,Xt,Je=Qe?Ve:Ue;switch(Rt){case"left":case"up":Xt=Je+I(O),Yt=xe?R(O,Xt):Xt,it.currentDirection=0;break;case"right":case"down":Xt=Je-I(O),Yt=xe?R(O,Xt):Xt,it.currentDirection=1;break;default:Yt=Je}it.triggerSlideHandler=Yt}else{var jt=A(O);it.trackStyle=B(s(s({},O),{},{left:jt}))}return it};var F=Pe.getNavigableIndexes=function(E){for(var O=E.infinite?E.slideCount*2:E.slideCount,H=E.infinite?E.slidesToShow*-1:0,Z=E.infinite?E.slidesToShow*-1:0,X=[];H<O;)X.push(H),H=Z+E.slidesToScroll,Z+=Math.min(E.slidesToScroll,E.slidesToShow);return X},R=Pe.checkNavigable=function(E,O){var H=F(E),Z=0;
275if(O>H[H.length-1])O=H[H.length-1];else for(var X in H){if(O<H[X]){O=Z;break}Z=H[X]}return O},I=Pe.getSlideCount=function(E){var O=E.centerMode?E.slideWidth*Math.floor(E.slidesToShow/2):0;if(E.swipeToSlide){var H,Z=E.listRef,X=Z.querySelectorAll&&Z.querySelectorAll(".slick-slide")||[];if(Array.from(X).every(function(le){if(E.vertical){if(le.offsetTop+C(le)/2>E.swipeLeft*-1)return H=le,!1}else if(le.offsetLeft-O+b(le)/2>E.swipeLeft*-1)return H=le,!1;return!0}),!H)return 0;var te=E.rtl===!0?E.slideCount-E.currentSlide:E.currentSlide,oe=Math.abs(H.dataset.index-te)||1;return oe}else return E.slidesToScroll},k=Pe.checkSpecKeys=function(E,O){return O.reduce(function(H,Z){return H&&E.hasOwnProperty(Z)},!0)?null:console.error("Keys Missing:",E)},L=Pe.getTrackCSS=function(E){k(E,["left","variableWidth","slideCount","slidesToShow","slideWidth"]);var O,H,Z=E.slideCount+2*E.slidesToShow;E.vertical?H=Z*E.slideHeight:O=W(E)*E.slideWidth;var X={opacity:1,transition:"",WebkitTransition:""};if(E.useTransform){var te=E.vertical?"translate3d(0px, "+E.left+"px, 0px)":"translate3d("+E.left+"px, 0px, 0px)",oe=E.vertical?"translate3d(0px, "+E.left+"px, 0px)":"translate3d("+E.left+"px, 0px, 0px)",le=E.vertical?"translateY("+E.left+"px)":"translateX("+E.left+"px)";X=s(s({},X),{},{WebkitTransform:te,transform:oe,msTransform:le})}else E.vertical?X.top=E.left:X.left=E.left;return E.fade&&(X={opacity:1}),O&&(X.width=O),H&&(X.height=H),window&&!window.addEventListener&&window.attachEvent&&(E.vertical?X.marginTop=E.left+"px":X.marginLeft=E.left+"px"),X},B=Pe.getTrackAnimateCSS=function(E){k(E,["left","variableWidth","slideCount","slidesToShow","slideWidth","speed","cssEase"]);var O=L(E);return E.useTransform?(O.WebkitTransition="-webkit-transform "+E.speed+"ms "+E.cssEase,O.transition="transform "+E.speed+"ms "+E.cssEase):E.vertical?O.transition="top "+E.speed+"ms "+E.cssEase:O.transition="left "+E.speed+"ms "+E.cssEase,O},A=Pe.getTrackLeft=function(E){if(E.unslick)return 0;k(E,["slideIndex","trackRef","infinite","centerMode","slideCount","slidesToShow","slidesToScroll","slideWidth","listWidth","variableWidth","slideHeight"]);var O=E.slideIndex,H=E.trackRef,Z=E.infinite,X=E.centerMode,te=E.slideCount,oe=E.slidesToShow,le=E.slidesToScroll,ye=E.slideWidth,xe=E.listWidth,be=E.variableWidth,rt=E.slideHeight,Ue=E.fade,Ve=E.vertical,Qe=0,ht,Rt,it=0;if(Ue||E.slideCount===1)return 0;var Yt=0;if(Z?(Yt=-V(E),te%le!==0&&O+le>te&&(Yt=-(O>te?oe-(O-te):te%le)),X&&(Yt+=parseInt(oe/2))):(te%le!==0&&O+le>te&&(Yt=oe-te%le),X&&(Yt=parseInt(oe/2))),Qe=Yt*ye,it=Yt*rt,Ve?ht=O*rt*-1+it:ht=O*ye*-1+Qe,be===!0){var Xt,Je=H&&H.node;if(Xt=O+V(E),Rt=Je&&Je.childNodes[Xt],ht=Rt?Rt.offsetLeft*-1:0,X===!0){Xt=Z?O+V(E):O,Rt=Je&&Je.children[Xt],ht=0;for(var jt=0;jt<Xt;jt++)ht-=Je&&Je.children[jt]&&Je.children[jt].offsetWidth;ht-=parseInt(E.centerPadding),ht+=Rt&&(xe-Rt.offsetWidth)/2}}return ht},V=Pe.getPreClones=function(E){return E.unslick||!E.infinite?0:E.variableWidth?E.slideCount:E.slidesToShow+(E.centerMode?1:0)},K=Pe.getPostClones=function(E){return E.unslick||!E.infinite?0:E.slideCount},W=Pe.getTotalSlides=function(E){return E.slideCount===1?1:V(E)+E.slideCount+K(E)},U=Pe.siblingDirection=function(E){return E.targetSlide>E.currentSlide?E.targetSlide>E.currentSlide+q(E)?"left":"right":E.targetSlide<E.currentSlide-z(E)?"right":"left"},q=Pe.slidesOnRight=function(E){var O=E.slidesToShow,H=E.centerMode,Z=E.rtl,X=E.centerPadding;if(H){var te=(O-1)/2+1;return parseInt(X)>0&&(te+=1),Z&&O%2===0&&(te+=1),te}return Z?0:O-1},z=Pe.slidesOnLeft=function(E){var O=E.slidesToShow,H=E.centerMode,Z=E.rtl,X=E.centerPadding;if(H){var te=(O-1)/2+1;return parseInt(X)>0&&(te+=1),!Z&&O%2===0&&(te+=1),te}return Z?O-1:0};Pe.canUseDOM=function(){return!!(typeof window<"u"&&window.document&&window.document.createElement)};var x=Pe.validSettings=Object.keys(t.default);function N(M){return x.reduce(function(E,O){return M.hasOwnProperty(O)&&(E[O]=M[O]),E},{})}return Pe}var Uh={},k8;function UCe(){if(k8)return Uh;k8=1,Object.defineProperty(Uh,"__esModule",{value:!0}),Uh.Track=void 0;var e=r(ao()),t=r(C1()),n=og();function r(B){return B&&B.__esModule?B:{default:B}}function i(B){"@babel/helpers - typeof";return i=typeof Symbol=="function"&&typeof Symbol.iterator=="symbol"?function(A){return typeof A}:function(A){return A&&typeof Symbol=="function"&&A.constructor===Symbol&&A!==Symbol.prototype?"symbol":typeof A},i(B)}function s(){return s=Object.assign?Object.assign.bind():function(B){for(var A=1;A<arguments.length;A++){var V=arguments[A];for(var K in V)Object.prototype.hasOwnProperty.call(V,K)&&(B[K]=V[K])}return B},s.apply(this,arguments)}function o(B,A){if(!(B instanceof A))throw new TypeError("Cannot call a class as a function")}function a(B,A){for(var V=0;V<A.length;V++){var K=A[V];K.enumerable=K.enumerable||!1,K.configurable=!0,"value"in K&&(K.writable=!0),Object.defineProperty(B,D(K.key),K)}}function c(B,A,V){return A&&a(B.prototype,A),Object.defineProperty(B,"prototype",{writable:!1}),B}function d(B,A){if(typeof A!="function"&&A!==null)throw new TypeError("Super expression must either be null or a function");
275B.prototype=Object.create(A&&A.prototype,{constructor:{value:B,writable:!0,configurable:!0}}),Object.defineProperty(B,"prototype",{writable:!1}),A&&f(B,A)}function f(B,A){return f=Object.setPrototypeOf?Object.setPrototypeOf.bind():function(K,W){return K.__proto__=W,K},f(B,A)}function p(B){var A=w();return function(){var K=_(B),W;if(A){var U=_(this).constructor;W=Reflect.construct(K,arguments,U)}else W=K.apply(this,arguments);return m(this,W)}}function m(B,A){if(A&&(i(A)==="object"||typeof A=="function"))return A;if(A!==void 0)throw new TypeError("Derived constructors may only return object or undefined");return v(B)}function v(B){if(B===void 0)throw new ReferenceError("this hasn't been initialised - super() hasn't been called");return B}function w(){try{var B=!Boolean.prototype.valueOf.call(Reflect.construct(Boolean,[],function(){}))}catch{}return(w=function(){return!!B})()}function _(B){return _=Object.setPrototypeOf?Object.getPrototypeOf.bind():function(V){return V.__proto__||Object.getPrototypeOf(V)},_(B)}function b(B,A){var V=Object.keys(B);if(Object.getOwnPropertySymbols){var K=Object.getOwnPropertySymbols(B);A&&(K=K.filter(function(W){return Object.getOwnPropertyDescriptor(B,W).enumerable})),V.push.apply(V,K)}return V}function C(B){for(var A=1;A<arguments.length;A++){var V=arguments[A]!=null?arguments[A]:{};A%2?b(Object(V),!0).forEach(function(K){P(B,K,V[K])}):Object.getOwnPropertyDescriptors?Object.defineProperties(B,Object.getOwnPropertyDescriptors(V)):b(Object(V)).forEach(function(K){Object.defineProperty(B,K,Object.getOwnPropertyDescriptor(V,K))})}return B}function P(B,A,V){return A=D(A),A in B?Object.defineProperty(B,A,{value:V,enumerable:!0,configurable:!0,writable:!0}):B[A]=V,B}function D(B){var A=F(B,"string");return i(A)=="symbol"?A:String(A)}function F(B,A){if(i(B)!="object"||!B)return B;var V=B[Symbol.toPrimitive];if(V!==void 0){var K=V.call(B,A);if(i(K)!="object")return K;throw new TypeError("@@toPrimitive must return a primitive value.")}return(A==="string"?String:Number)(B)}var R=function(A){var V,K,W,U,q;A.rtl?q=A.slideCount-1-A.index:q=A.index,W=q<0||q>=A.slideCount,A.centerMode?(U=Math.floor(A.slidesToShow/2),K=(q-A.currentSlide)%A.slideCount===0,q>A.currentSlide-U-1&&q<=A.currentSlide+U&&(V=!0)):V=A.currentSlide<=q&&q<A.currentSlide+A.slidesToShow;var z;A.targetSlide<0?z=A.targetSlide+A.slideCount:A.targetSlide>=A.slideCount?z=A.targetSlide-A.slideCount:z=A.targetSlide;var x=q===z;return{"slick-slide":!0,"slick-active":V,"slick-center":K,"slick-cloned":W,"slick-current":x}},I=function(A){var V={};return(A.variableWidth===void 0||A.variableWidth===!1)&&(V.width=A.slideWidth),A.fade&&(V.position="relative",A.vertical?V.top=-A.index*parseInt(A.slideHeight):V.left=-A.index*parseInt(A.slideWidth),V.opacity=A.currentSlide===A.index?1:0,V.zIndex=A.currentSlide===A.index?999:998,A.useCSS&&(V.transition="opacity "+A.speed+"ms "+A.cssEase+", visibility "+A.speed+"ms "+A.cssEase)),V},k=function(A,V){return A.key||V},L=function(A){var V,K=[],W=[],U=[],q=e.default.Children.count(A.children),z=(0,n.lazyStartIndex)(A),x=(0,n.lazyEndIndex)(A);return e.default.Children.forEach(A.children,function(N,M){var E,O={message:"children",index:M,slidesToScroll:A.slidesToScroll,currentSlide:A.currentSlide};!A.lazyLoad||A.lazyLoad&&A.lazyLoadedList.indexOf(M)>=0?E=N:E=e.default.createElement("div",null);var H=I(C(C({},A),{},{index:M})),Z=E.props.className||"",X=R(C(C({},A),{},{index:M}));if(K.push(e.default.cloneElement(E,{key:"original"+k(E,M),"data-index":M,className:(0,t.default)(X,Z),tabIndex:"-1","aria-hidden":!X["slick-active"],style:C(C({outline:"none"},E.props.style||{}),H),onClick:function(le){E.props&&E.props.onClick&&E.props.onClick(le),A.focusOnSelect&&A.focusOnSelect(O)}})),A.infinite&&A.fade===!1){var te=q-M;te<=(0,n.getPreClones)(A)&&(V=-te,V>=z&&(E=N),X=R(C(C({},A),{},{index:V})),W.push(e.default.cloneElement(E,{key:"precloned"+k(E,V),"data-index":V,tabIndex:"-1",className:(0,t.default)(X,Z),"aria-hidden":!X["slick-active"],style:C(C({},E.props.style||{}),H),onClick:function(le){E.props&&E.props.onClick&&E.props.onClick(le),A.focusOnSelect&&A.focusOnSelect(O)}}))),V=q+M,V<x&&(E=N),X=R(C(C({},A),{},{index:V})),U.push(e.default.cloneElement(E,{key:"postcloned"+k(E,V),"data-index":V,tabIndex:"-1",className:(0,t.default)(X,Z),"aria-hidden":!X["slick-active"],style:C(C({},E.props.style||{}),H),onClick:function(le){E.props&&E.props.onClick&&E.props.onClick(le),A.focusOnSelect&&A.focusOnSelect(O)}}))}}),A.rtl?W.concat(K,U).reverse():W.concat(K,U)};return Uh.Track=(function(B){d(V,B);var A=p(V);function V(){var K;o(this,V);for(var W=arguments.length,U=new Array(W),q=0;q<W;q++)U[q]=arguments[q];return K=A.call.apply(A,[this].concat(U)),P(v(K),"node",null),P(v(K),"handleRef",function(z){K.node=z}),K}return c(V,[{key:"render",value:function(){var W=L(this.props),U=this.props,q=U.onMouseEnter,z=U.onMouseOver,x=U.onMouseLeave,N={onMouseEnter:q,onMouseOver:z,onMouseLeave:x};return e.default.createElement("div",s({ref:this.handleRef,className:"slick-track",style:this.props.trackStyle},N),W)}}]),V})(e.default.PureComponent),Uh}var zh={},T8;
275function zCe(){if(T8)return zh;T8=1;function e(R){"@babel/helpers - typeof";return e=typeof Symbol=="function"&&typeof Symbol.iterator=="symbol"?function(I){return typeof I}:function(I){return I&&typeof Symbol=="function"&&I.constructor===Symbol&&I!==Symbol.prototype?"symbol":typeof I},e(R)}Object.defineProperty(zh,"__esModule",{value:!0}),zh.Dots=void 0;var t=i(ao()),n=i(C1()),r=og();function i(R){return R&&R.__esModule?R:{default:R}}function s(R,I){var k=Object.keys(R);if(Object.getOwnPropertySymbols){var L=Object.getOwnPropertySymbols(R);I&&(L=L.filter(function(B){return Object.getOwnPropertyDescriptor(R,B).enumerable})),k.push.apply(k,L)}return k}function o(R){for(var I=1;I<arguments.length;I++){var k=arguments[I]!=null?arguments[I]:{};I%2?s(Object(k),!0).forEach(function(L){a(R,L,k[L])}):Object.getOwnPropertyDescriptors?Object.defineProperties(R,Object.getOwnPropertyDescriptors(k)):s(Object(k)).forEach(function(L){Object.defineProperty(R,L,Object.getOwnPropertyDescriptor(k,L))})}return R}function a(R,I,k){return I=p(I),I in R?Object.defineProperty(R,I,{value:k,enumerable:!0,configurable:!0,writable:!0}):R[I]=k,R}function c(R,I){if(!(R instanceof I))throw new TypeError("Cannot call a class as a function")}function d(R,I){for(var k=0;k<I.length;k++){var L=I[k];L.enumerable=L.enumerable||!1,L.configurable=!0,"value"in L&&(L.writable=!0),Object.defineProperty(R,p(L.key),L)}}function f(R,I,k){return I&&d(R.prototype,I),Object.defineProperty(R,"prototype",{writable:!1}),R}function p(R){var I=m(R,"string");return e(I)=="symbol"?I:String(I)}function m(R,I){if(e(R)!="object"||!R)return R;var k=R[Symbol.toPrimitive];if(k!==void 0){var L=k.call(R,I);if(e(L)!="object")return L;throw new TypeError("@@toPrimitive must return a primitive value.")}return String(R)}function v(R,I){if(typeof I!="function"&&I!==null)throw new TypeError("Super expression must either be null or a function");R.prototype=Object.create(I&&I.prototype,{constructor:{value:R,writable:!0,configurable:!0}}),Object.defineProperty(R,"prototype",{writable:!1}),I&&w(R,I)}function w(R,I){return w=Object.setPrototypeOf?Object.setPrototypeOf.bind():function(L,B){return L.__proto__=B,L},w(R,I)}function _(R){var I=P();return function(){var L=D(R),B;if(I){var A=D(this).constructor;B=Reflect.construct(L,arguments,A)}else B=L.apply(this,arguments);return b(this,B)}}function b(R,I){if(I&&(e(I)==="object"||typeof I=="function"))return I;if(I!==void 0)throw new TypeError("Derived constructors may only return object or undefined");return C(R)}function C(R){if(R===void 0)throw new ReferenceError("this hasn't been initialised - super() hasn't been called");return R}function P(){try{var R=!Boolean.prototype.valueOf.call(Reflect.construct(Boolean,[],function(){}))}catch{}return(P=function(){return!!R})()}function D(R){return D=Object.setPrototypeOf?Object.getPrototypeOf.bind():function(k){return k.__proto__||Object.getPrototypeOf(k)},D(R)}var F=function(I){var k;return I.infinite?k=Math.ceil(I.slideCount/I.slidesToScroll):k=Math.ceil((I.slideCount-I.slidesToShow)/I.slidesToScroll)+1,k};return zh.Dots=(function(R){v(k,R);var I=_(k);function k(){return c(this,k),I.apply(this,arguments)}return f(k,[{key:"clickHandler",value:function(B,A){A.preventDefault(),this.props.clickHandler(B)}},{key:"render",value:function(){for(var B=this.props,A=B.onMouseEnter,V=B.onMouseOver,K=B.onMouseLeave,W=B.infinite,U=B.slidesToScroll,q=B.slidesToShow,z=B.slideCount,x=B.currentSlide,N=F({slideCount:z,slidesToScroll:U,slidesToShow:q,infinite:W}),M={onMouseEnter:A,onMouseOver:V,onMouseLeave:K},E=[],O=0;O<N;O++){var H=(O+1)*U-1,Z=W?H:(0,r.clamp)(H,0,z-1),X=Z-(U-1),te=W?X:(0,r.clamp)(X,0,z-1),oe=(0,n.default)({"slick-active":W?x>=te&&x<=Z:x===te}),le={message:"dots",index:O,slidesToScroll:U,currentSlide:x},ye=this.clickHandler.bind(this,le);E=E.concat(t.default.createElement("li",{key:O,className:oe},t.default.cloneElement(this.props.customPaging(O),{onClick:ye})))}return t.default.cloneElement(this.props.appendDots(E),o({className:this.props.dotsClass},M))}}]),k})(t.default.PureComponent),zh}var vc={},R8;function BCe(){if(R8)return vc;R8=1;function e(R){"@babel/helpers - typeof";return e=typeof Symbol=="function"&&typeof Symbol.iterator=="symbol"?function(I){return typeof I}:function(I){return I&&typeof Symbol=="function"&&I.constructor===Symbol&&I!==Symbol.prototype?"symbol":typeof I},e(R)}Object.defineProperty(vc,"__esModule",{value:!0}),vc.PrevArrow=vc.NextArrow=void 0;var t=i(ao()),n=i(C1()),r=og();function i(R){return R&&R.__esModule?R:{default:R}}function s(){return s=Object.assign?Object.assign.bind():function(R){for(var I=1;I<arguments.length;I++){var k=arguments[I];for(var L in k)Object.prototype.hasOwnProperty.call(k,L)&&(R[L]=k[L])}return R},s.apply(this,arguments)}function o(R,I){var k=Object.keys(R);if(Object.getOwnPropertySymbols){var L=Object.getOwnPropertySymbols(R);I&&(L=L.filter(function(B){return Object.getOwnPropertyDescriptor(R,B).enumerable})),k.push.apply(k,L)}return k}function a(R){for(var I=1;I<arguments.length;I++){var k=arguments[I]!=null?arguments[I]:{};
275I%2?o(Object(k),!0).forEach(function(L){c(R,L,k[L])}):Object.getOwnPropertyDescriptors?Object.defineProperties(R,Object.getOwnPropertyDescriptors(k)):o(Object(k)).forEach(function(L){Object.defineProperty(R,L,Object.getOwnPropertyDescriptor(k,L))})}return R}function c(R,I,k){return I=m(I),I in R?Object.defineProperty(R,I,{value:k,enumerable:!0,configurable:!0,writable:!0}):R[I]=k,R}function d(R,I){if(!(R instanceof I))throw new TypeError("Cannot call a class as a function")}function f(R,I){for(var k=0;k<I.length;k++){var L=I[k];L.enumerable=L.enumerable||!1,L.configurable=!0,"value"in L&&(L.writable=!0),Object.defineProperty(R,m(L.key),L)}}function p(R,I,k){return I&&f(R.prototype,I),Object.defineProperty(R,"prototype",{writable:!1}),R}function m(R){var I=v(R,"string");return e(I)=="symbol"?I:String(I)}function v(R,I){if(e(R)!="object"||!R)return R;var k=R[Symbol.toPrimitive];if(k!==void 0){var L=k.call(R,I);if(e(L)!="object")return L;throw new TypeError("@@toPrimitive must return a primitive value.")}return String(R)}function w(R,I){if(typeof I!="function"&&I!==null)throw new TypeError("Super expression must either be null or a function");R.prototype=Object.create(I&&I.prototype,{constructor:{value:R,writable:!0,configurable:!0}}),Object.defineProperty(R,"prototype",{writable:!1}),I&&_(R,I)}function _(R,I){return _=Object.setPrototypeOf?Object.setPrototypeOf.bind():function(L,B){return L.__proto__=B,L},_(R,I)}function b(R){var I=D();return function(){var L=F(R),B;if(I){var A=F(this).constructor;B=Reflect.construct(L,arguments,A)}else B=L.apply(this,arguments);return C(this,B)}}function C(R,I){if(I&&(e(I)==="object"||typeof I=="function"))return I;if(I!==void 0)throw new TypeError("Derived constructors may only return object or undefined");return P(R)}function P(R){if(R===void 0)throw new ReferenceError("this hasn't been initialised - super() hasn't been called");return R}function D(){try{var R=!Boolean.prototype.valueOf.call(Reflect.construct(Boolean,[],function(){}))}catch{}return(D=function(){return!!R})()}function F(R){return F=Object.setPrototypeOf?Object.getPrototypeOf.bind():function(k){return k.__proto__||Object.getPrototypeOf(k)},F(R)}return vc.PrevArrow=(function(R){w(k,R);var I=b(k);function k(){return d(this,k),I.apply(this,arguments)}return p(k,[{key:"clickHandler",value:function(B,A){A&&A.preventDefault(),this.props.clickHandler(B,A)}},{key:"render",value:function(){var B={"slick-arrow":!0,"slick-prev":!0},A=this.clickHandler.bind(this,{message:"previous"});!this.props.infinite&&(this.props.currentSlide===0||this.props.slideCount<=this.props.slidesToShow)&&(B["slick-disabled"]=!0,A=null);var V={key:"0","data-role":"none",className:(0,n.default)(B),style:{display:"block"},onClick:A},K={currentSlide:this.props.currentSlide,slideCount:this.props.slideCount},W;return this.props.prevArrow?W=t.default.cloneElement(this.props.prevArrow,a(a({},V),K)):W=t.default.createElement("button",s({key:"0",type:"button"},V)," ","Previous"),W}}]),k})(t.default.PureComponent),vc.NextArrow=(function(R){w(k,R);var I=b(k);function k(){return d(this,k),I.apply(this,arguments)}return p(k,[{key:"clickHandler",value:function(B,A){A&&A.preventDefault(),this.props.clickHandler(B,A)}},{key:"render",value:function(){var B={"slick-arrow":!0,"slick-next":!0},A=this.clickHandler.bind(this,{message:"next"});(0,r.canGoNext)(this.props)||(B["slick-disabled"]=!0,A=null);var V={key:"1","data-role":"none",className:(0,n.default)(B),style:{display:"block"},onClick:A},K={currentSlide:this.props.currentSlide,slideCount:this.props.slideCount},W;return this.props.nextArrow?W=t.default.cloneElement(this.props.nextArrow,a(a({},V),K)):W=t.default.createElement("button",s({key:"1",type:"button"},V)," ","Next"),W}}]),k})(t.default.PureComponent),vc}var UB=(function(){if(typeof Map<"u")return Map;function e(t,n){var r=-1;return t.some(function(i,s){return i[0]===n?(r=s,!0):!1}),r}return(function(){function t(){this.__entries__=[]}return Object.defineProperty(t.prototype,"size",{get:function(){return this.__entries__.length},enumerable:!0,configurable:!0}),t.prototype.get=function(n){var r=e(this.__entries__,n),i=this.__entries__[r];return i&&i[1]},t.prototype.set=function(n,r){var i=e(this.__entries__,n);~i?this.__entries__[i][1]=r:this.__entries__.push([n,r])},t.prototype.delete=function(n){var r=this.__entries__,i=e(r,n);~i&&r.splice(i,1)},t.prototype.has=function(n){return!!~e(this.__entries__,n)},t.prototype.clear=function(){this.__entries__.splice(0)},t.prototype.forEach=function(n,r){r===void 0&&(r=null);for(var i=0,s=this.__entries__;i<s.length;i++){var o=s[i];n.call(r,o[1],o[0])}},t})()})(),aC=typeof window<"u"&&typeof document<"u"&&window.document===document,r_=(function(){return typeof global<"u"&&global.Math===Math?global:typeof self<"u"&&self.Math===Math?self:typeof window<"u"&&window.Math===Math?window:Function("return this")()})(),HCe=(function(){return typeof requestAnimationFrame=="function"?requestAnimationFrame.bind(r_):function(e){return setTimeout(function(){return e(Date.now())},1e3/60)}})(),VCe=2;function WCe(e,t){var n=!1,r=!1,i=0;
vendor: 4,408 bytes, line 275
275function s(){n&&(n=!1,e()),r&&a()}function o(){HCe(s)}function a(){var c=Date.now();if(n){if(c-i<VCe)return;r=!0}else n=!0,r=!1,setTimeout(o,t);i=c}return a}var qCe=20,KCe=["top","right","bottom","left","width","height","size","weight"],GCe=typeof MutationObserver<"u",YCe=(function(){function e(){this.connected_=!1,this.mutationEventsAdded_=!1,this.mutationsObserver_=null,this.observers_=[],this.onTransitionEnd_=this.onTransitionEnd_.bind(this),this.refresh=WCe(this.refresh.bind(this),qCe)}return e.prototype.addObserver=function(t){~this.observers_.indexOf(t)||this.observers_.push(t),this.connected_||this.connect_()},e.prototype.removeObserver=function(t){var n=this.observers_,r=n.indexOf(t);~r&&n.splice(r,1),!n.length&&this.connected_&&this.disconnect_()},e.prototype.refresh=function(){var t=this.updateObservers_();t&&this.refresh()},e.prototype.updateObservers_=function(){var t=this.observers_.filter(function(n){return n.gatherActive(),n.hasActive()});return t.forEach(function(n){return n.broadcastActive()}),t.length>0},e.prototype.connect_=function(){!aC||this.connected_||(document.addEventListener("transitionend",this.onTransitionEnd_),window.addEventListener("resize",this.refresh),GCe?(this.mutationsObserver_=new MutationObserver(this.refresh),this.mutationsObserver_.observe(document,{attributes:!0,childList:!0,characterData:!0,subtree:!0})):(document.addEventListener("DOMSubtreeModified",this.refresh),this.mutationEventsAdded_=!0),this.connected_=!0)},e.prototype.disconnect_=function(){!aC||!this.connected_||(document.removeEventListener("transitionend",this.onTransitionEnd_),window.removeEventListener("resize",this.refresh),this.mutationsObserver_&&this.mutationsObserver_.disconnect(),this.mutationEventsAdded_&&document.removeEventListener("DOMSubtreeModified",this.refresh),this.mutationsObserver_=null,this.mutationEventsAdded_=!1,this.connected_=!1)},e.prototype.onTransitionEnd_=function(t){var n=t.propertyName,r=n===void 0?"":n,i=KCe.some(function(s){return!!~r.indexOf(s)});i&&this.refresh()},e.getInstance=function(){return this.instance_||(this.instance_=new e),this.instance_},e.instance_=null,e})(),zB=(function(e,t){for(var n=0,r=Object.keys(t);n<r.length;n++){var i=r[n];Object.defineProperty(e,i,{value:t[i],enumerable:!1,writable:!1,configurable:!0})}return e}),cf=(function(e){var t=e&&e.ownerDocument&&e.ownerDocument.defaultView;return t||r_}),BB=k1(0,0,0,0);function i_(e){return parseFloat(e)||0}function P8(e){for(var t=[],n=1;n<arguments.length;n++)t[n-1]=arguments[n];return t.reduce(function(r,i){var s=e["border-"+i+"-width"];return r+i_(s)},0)}function JCe(e){for(var t=["top","right","bottom","left"],n={},r=0,i=t;r<i.length;r++){var s=i[r],o=e["padding-"+s];n[s]=i_(o)}return n}function ZCe(e){var t=e.getBBox();return k1(0,0,t.width,t.height)}function XCe(e){var t=e.clientWidth,n=e.clientHeight;if(!t&&!n)return BB;var r=cf(e).getComputedStyle(e),i=JCe(r),s=i.left+i.right,o=i.top+i.bottom,a=i_(r.width),c=i_(r.height);if(r.boxSizing==="border-box"&&(Math.round(a+s)!==t&&(a-=P8(r,"left","right")+s),Math.round(c+o)!==n&&(c-=P8(r,"top","bottom")+o)),!eke(e)){var d=Math.round(a+s)-t,f=Math.round(c+o)-n;Math.abs(d)!==1&&(a-=d),Math.abs(f)!==1&&(c-=f)}return k1(i.left,i.top,a,c)}var QCe=(function(){return typeof SVGGraphicsElement<"u"?function(e){return e instanceof cf(e).SVGGraphicsElement}:function(e){return e instanceof cf(e).SVGElement&&typeof e.getBBox=="function"}})();function eke(e){return e===cf(e).document.documentElement}function tke(e){return aC?QCe(e)?ZCe(e):XCe(e):BB}function nke(e){var t=e.x,n=e.y,r=e.width,i=e.height,s=typeof DOMRectReadOnly<"u"?DOMRectReadOnly:Object,o=Object.create(s.prototype);return zB(o,{x:t,y:n,width:r,height:i,top:n,right:t+r,bottom:i+n,left:t}),o}function k1(e,t,n,r){return{x:e,y:t,width:n,height:r}}var rke=(function(){function e(t){this.broadcastWidth=0,this.broadcastHeight=0,this.contentRect_=k1(0,0,0,0),this.target=t}return e.prototype.isActive=function(){var t=tke(this.target);return this.contentRect_=t,t.width!==this.broadcastWidth||t.height!==this.broadcastHeight},e.prototype.broadcastRect=function(){var t=this.contentRect_;return this.broadcastWidth=t.width,this.broadcastHeight=t.height,t},e})(),ike=(function(){function e(t,n){var r=nke(n);zB(this,{target:t,contentRect:r})}return e})(),ske=(function(){function e(t,n,r){if(this.activeObservations_=[],this.observations_=new
275UB,typeof t!="function")throw new TypeError("The callback provided as parameter 1 is not a function.");this.callback_=t,this.controller_=n,this.callbackCtx_=r}return e.prototype.observe=function(t){if(!arguments.length)throw new TypeError("1 argument required, but only 0 present.");if(!(typeof Element>"u"||!(Element instanceof Object))){if(!(t instanceof cf(t).Element))throw new TypeError('parameter 1 is not of type "Element".');var n=this.observations_;n.has(t)||(n.set(t,new rke(t)),this.controller_.addObserver(this),this.controller_.refresh())}},e.prototype.unobserve=function(t){if(!arguments.length)throw new TypeError("1 argument required, but only 0 present.");if(!(typeof Element>"u"||!(Element instanceof Object))){if(!(t instanceof cf(t).Element))throw new TypeError('parameter 1 is not of type "Element".');var n=this.observations_;n.has(t)&&(n.delete(t),n.size||this.controller_.removeObserver(this))}},e.prototype.disconnect=function(){this.clearActive(),this.observations_.clear(),this.controller_.removeObserver(this)},e.prototype.gatherActive=function(){var t=this;this.clearActive(),this.observations_.forEach(function(n){n.isActive()&&t.activeObservations_.push(n)})},e.prototype.broadcastActive=function(){if(this.hasActive()){var t=this.callbackCtx_,n=this.activeObservations_.map(function(r){return new ike(r.target,r.broadcastRect())});this.callback_.call(t,n,t),this.clearActive()}},e.prototype.clearActive=function(){this.activeObservations_.splice(0)},e.prototype.hasActive=function(){return this.activeObservations_.length>0},e})(),HB=typeof WeakMap<"u"?new WeakMap:new UB,VB=(function(){function e(t){if(!(this instanceof e))throw new TypeError("Cannot call a class as a function.");if(!arguments.length)throw new TypeError("1 argument required, but only 0 present.");var n=YCe.getInstance(),r=new ske(t,n,this);HB.set(this,r)}return e})();["observe","unobserve","disconnect"].forEach(function(e){VB.prototype[e]=function(){var t;return(t=HB.get(this))[e].apply(t,arguments)}});var oke=(function(){return typeof r_.ResizeObserver<"u"?r_.ResizeObserver:VB})();const ake=Object.freeze(Object.defineProperty({__proto__:null,default:oke},Symbol.toStringTag,{value:"Module"})),lke=JW(ake);var O8;function cke(){if(O8)return Fh;O8=1,Object.defineProperty(Fh,"__esModule",{value:!0}),Fh.InnerSlider=void 0;var e=d(ao()),t=d(jCe()),n=d(FCe()),r=d(C1()),i=og(),s=UCe(),o=zCe(),a=BCe(),c=d(lke);function d(W){return W&&W.__esModule?W:{default:W}}function f(W){"@babel/helpers - typeof";return f=typeof Symbol=="function"&&typeof Symbol.iterator=="symbol"?function(U){return typeof U}:function(U){return U&&typeof Symbol=="function"&&U.constructor===Symbol&&U!==Symbol.prototype?"symbol":typeof U},f(W)}function p(){return p=Object.assign?Object.assign.bind():function(W){for(var U=1;U<arguments.length;U++){var q=arguments[U];for(var z in q)Object.prototype.hasOwnProperty.call(q,z)&&(W[z]=q[z])}return W},p.apply(this,arguments)}function m(W,U){if(W==null)return{};var q=v(W,U),z,x;if(Object.getOwnPropertySymbols){var N=Object.getOwnPropertySymbols(W);for(x=0;x<N.length;x++)z=N[x],!(U.indexOf(z)>=0)&&Object.prototype.propertyIsEnumerable.call(W,z)&&(q[z]=W[z])}return q}function v(W,U){if(W==null)return{};var q={},z=Object.keys(W),x,N;for(N=0;N<z.length;N++)x=z[N],!(U.indexOf(x)>=0)&&(q[x]=W[x]);return q}function w(W,U){var q=Object.keys(W);if(Object.getOwnPropertySymbols){var z=Object.getOwnPropertySymbols(W);U&&(z=z.filter(function(x){return Object.getOwnPropertyDescriptor(W,x).enumerable})),q.push.apply(q,z)}return q}function _(W){for(var U=1;U<arguments.length;U++){var q=arguments[U]!=null?arguments[U]:{};U%2?w(Object(q),!0).forEach(function(z){A(W,z,q[z])}):Object.getOwnPropertyDescriptors?Object.defineProperties(W,Object.getOwnPropertyDescriptors(q)):w(Object(q)).forEach(function(z){Object.defineProperty(W,z,Object.getOwnPropertyDescriptor(q,z))})}return W}function b(W,U){if(!(W instanceof U))throw new TypeError("Cannot call a class as a function")}function C(W,U){for(var q=0;q<U.length;q++){var z=U[q];z.enumerable=z.enumerable||!1,z.configurable=!0,"value"in z&&(z.writable=!0),Object.defineProperty(W,V(z.key),z)}}function P(W,U,q){return U&&C(W.prototype,U),Object.defineProperty(W,"prototype",{writable:!1}),W}function D(W,U){if(typeof U!="function"&&U!==null)throw new TypeError("Super expression must either be null or a function");W.prototype=Object.create(U&&U.prototype,{constructor:{value:W,writable:!0,configurable:!0}}),Object.defineProperty(W,"prototype",{writable:!1}),U&&F(W,U)}
275function F(W,U){return F=Object.setPrototypeOf?Object.setPrototypeOf.bind():function(z,x){return z.__proto__=x,z},F(W,U)}function R(W){var U=L();return function(){var z=B(W),x;if(U){var N=B(this).constructor;x=Reflect.construct(z,arguments,N)}else x=z.apply(this,arguments);return I(this,x)}}function I(W,U){if(U&&(f(U)==="object"||typeof U=="function"))return U;if(U!==void 0)throw new TypeError("Derived constructors may only return object or undefined");return k(W)}function k(W){if(W===void 0)throw new ReferenceError("this hasn't been initialised - super() hasn't been called");return W}function L(){try{var W=!Boolean.prototype.valueOf.call(Reflect.construct(Boolean,[],function(){}))}catch{}return(L=function(){return!!W})()}function B(W){return B=Object.setPrototypeOf?Object.getPrototypeOf.bind():function(q){return q.__proto__||Object.getPrototypeOf(q)},B(W)}function A(W,U,q){return U=V(U),U in W?Object.defineProperty(W,U,{value:q,enumerable:!0,configurable:!0,writable:!0}):W[U]=q,W}function V(W){var U=K(W,"string");return f(U)=="symbol"?U:String(U)}function K(W,U){if(f(W)!="object"||!W)return W;var q=W[Symbol.toPrimitive];if(q!==void 0){var z=q.call(W,U);if(f(z)!="object")return z;throw new TypeError("@@toPrimitive must return a primitive value.")}return(U==="string"?String:Number)(W)}return Fh.InnerSlider=(function(W){D(q,W);var U=R(q);function q(z){var x;b(this,q),x=U.call(this,z),A(k(x),"listRefHandler",function(M){return x.list=M}),A(k(x),"trackRefHandler",function(M){return x.track=M}),A(k(x),"adaptHeight",function(){if(x.props.adaptiveHeight&&x.list){var M=x.list.querySelector('[data-index="'.concat(x.state.currentSlide,'"]'));x.list.style.height=(0,i.getHeight)(M)+"px"}}),A(k(x),"componentDidMount",function(){if(x.props.onInit&&x.props.onInit(),x.props.lazyLoad){var M=(0,i.getOnDemandLazySlides)(_(_({},x.props),x.state));M.length>0&&(x.setState(function(O){return{lazyLoadedList:O.lazyLoadedList.concat(M)}}),x.props.onLazyLoad&&x.props.onLazyLoad(M))}var E=_({listRef:x.list,trackRef:x.track},x.props);x.updateState(E,!0,function(){x.adaptHeight(),x.props.autoplay&&x.autoPlay("update")}),x.props.lazyLoad==="progressive"&&(x.lazyLoadTimer=setInterval(x.progressiveLazyLoad,1e3)),x.ro=new c.default(function(){x.state.animating?(x.onWindowResized(!1),x.callbackTimers.push(setTimeout(function(){return x.onWindowResized()},x.props.speed))):x.onWindowResized()}),x.ro.observe(x.list),document.querySelectorAll&&Array.prototype.forEach.call(document.querySelectorAll(".slick-slide"),function(O){O.onfocus=x.props.pauseOnFocus?x.onSlideFocus:null,O.onblur=x.props.pauseOnFocus?x.onSlideBlur:null}),window.addEventListener?window.addEventListener("resize",x.onWindowResized):window.attachEvent("onresize",x.onWindowResized)}),A(k(x),"componentWillUnmount",function(){x.animationEndCallback&&clearTimeout(x.animationEndCallback),x.lazyLoadTimer&&clearInterval(x.lazyLoadTimer),x.callbackTimers.length&&(x.callbackTimers.forEach(function(M){return clearTimeout(M)}),x.callbackTimers=[]),window.addEventListener?window.removeEventListener("resize",x.onWindowResized):window.detachEvent("onresize",x.onWindowResized),x.autoplayTimer&&clearInterval(x.autoplayTimer),x.ro.disconnect()}),A(k(x),"componentDidUpdate",function(M){if(x.checkImagesLoad(),x.props.onReInit&&x.props.onReInit(),x.props.lazyLoad){var E=(0,i.getOnDemandLazySlides)(_(_({},x.props),x.state));E.length>0&&(x.setState(function(Z){return{lazyLoadedList:Z.lazyLoadedList.concat(E)}}),x.props.onLazyLoad&&x.props.onLazyLoad(E))}x.adaptHeight();var O=_(_({listRef:x.list,trackRef:x.track},x.props),x.state),H=x.didPropsChange(M);H&&x.updateState(O,H,function(){x.state.currentSlide>=e.default.Children.count(x.props.children)&&x.changeSlide({message:"index",index:e.default.Children.count(x.props.children)-x.props.slidesToShow,currentSlide:x.state.currentSlide}),x.props.autoplay?x.autoPlay("update"):x.pause("paused")})}),A(k(x),"onWindowResized",function(M){x.debouncedResize&&x.debouncedResize.cancel(),x.debouncedResize=(0,n.default)(function(){return x.resizeWindow(M)},50),x.debouncedResize()}),A(k(x),"resizeWindow",function(){var M=arguments.length>0&&arguments[0]!==void 0?arguments[0]:!0,E=!!(x.track&&x.track.node);
vendor: 10,114 bytes, line 275
275if(E){var O=_(_({listRef:x.list,trackRef:x.track},x.props),x.state);x.updateState(O,M,function(){x.props.autoplay?x.autoPlay("update"):x.pause("paused")}),x.setState({animating:!1}),clearTimeout(x.animationEndCallback),delete x.animationEndCallback}}),A(k(x),"updateState",function(M,E,O){var H=(0,i.initializedState)(M);M=_(_(_({},M),H),{},{slideIndex:H.currentSlide});var Z=(0,i.getTrackLeft)(M);M=_(_({},M),{},{left:Z});var X=(0,i.getTrackCSS)(M);(E||e.default.Children.count(x.props.children)!==e.default.Children.count(M.children))&&(H.trackStyle=X),x.setState(H,O)}),A(k(x),"ssrInit",function(){if(x.props.variableWidth){var M=0,E=0,O=[],H=(0,i.getPreClones)(_(_(_({},x.props),x.state),{},{slideCount:x.props.children.length})),Z=(0,i.getPostClones)(_(_(_({},x.props),x.state),{},{slideCount:x.props.children.length}));x.props.children.forEach(function(Rt){O.push(Rt.props.style.width),M+=Rt.props.style.width});for(var X=0;X<H;X++)E+=O[O.length-1-X],M+=O[O.length-1-X];for(var te=0;te<Z;te++)M+=O[te];for(var oe=0;oe<x.state.currentSlide;oe++)E+=O[oe];var le={width:M+"px",left:-E+"px"};if(x.props.centerMode){var ye="".concat(O[x.state.currentSlide],"px");le.left="calc(".concat(le.left," + (100% - ").concat(ye,") / 2 ) ")}return{trackStyle:le}}var xe=e.default.Children.count(x.props.children),be=_(_(_({},x.props),x.state),{},{slideCount:xe}),rt=(0,i.getPreClones)(be)+(0,i.getPostClones)(be)+xe,Ue=100/x.props.slidesToShow*rt,Ve=100/rt,Qe=-Ve*((0,i.getPreClones)(be)+x.state.currentSlide)*Ue/100;x.props.centerMode&&(Qe+=(100-Ve*Ue/100)/2);var ht={width:Ue+"%",left:Qe+"%"};return{slideWidth:Ve+"%",trackStyle:ht}}),A(k(x),"checkImagesLoad",function(){var M=x.list&&x.list.querySelectorAll&&x.list.querySelectorAll(".slick-slide img")||[],E=M.length,O=0;Array.prototype.forEach.call(M,function(H){var Z=function(){return++O&&O>=E&&x.onWindowResized()};if(!H.onclick)H.onclick=function(){return H.parentNode.focus()};else{var X=H.onclick;H.onclick=function(te){X(te),H.parentNode.focus()}}H.onload||(x.props.lazyLoad?H.onload=function(){x.adaptHeight(),x.callbackTimers.push(setTimeout(x.onWindowResized,x.props.speed))}:(H.onload=Z,H.onerror=function(){Z(),x.props.onLazyLoadError&&x.props.onLazyLoadError()}))})}),A(k(x),"progressiveLazyLoad",function(){for(var M=[],E=_(_({},x.props),x.state),O=x.state.currentSlide;O<x.state.slideCount+(0,i.getPostClones)(E);O++)if(x.state.lazyLoadedList.indexOf(O)<0){M.push(O);break}for(var H=x.state.currentSlide-1;H>=-(0,i.getPreClones)(E);H--)if(x.state.lazyLoadedList.indexOf(H)<0){M.push(H);break}M.length>0?(x.setState(function(Z){return{lazyLoadedList:Z.lazyLoadedList.concat(M)}}),x.props.onLazyLoad&&x.props.onLazyLoad(M)):x.lazyLoadTimer&&(clearInterval(x.lazyLoadTimer),delete x.lazyLoadTimer)}),A(k(x),"slideHandler",function(M){var E=arguments.length>1&&arguments[1]!==void 0?arguments[1]:!1,O=x.props,H=O.asNavFor,Z=O.beforeChange,X=O.onLazyLoad,te=O.speed,oe=O.afterChange,le=x.state.currentSlide,ye=(0,i.slideHandler)(_(_(_({index:M},x.props),x.state),{},{trackRef:x.track,useCSS:x.props.useCSS&&!E})),xe=ye.state,be=ye.nextState;if(xe){Z&&Z(le,xe.currentSlide);var rt=xe.lazyLoadedList.filter(function(Ue){return x.state.lazyLoadedList.indexOf(Ue)<0});X&&rt.length>0&&X(rt),!x.props.waitForAnimate&&x.animationEndCallback&&(clearTimeout(x.animationEndCallback),oe&&oe(le),delete x.animationEndCallback),x.setState(xe,function(){H&&x.asNavForIndex!==M&&(x.asNavForIndex=M,H.innerSlider.slideHandler(M)),be&&(x.animationEndCallback=setTimeout(function(){var Ue=be.animating,Ve=m(be,["animating"]);x.setState(Ve,function(){x.callbackTimers.push(setTimeout(function(){return x.setState({animating:Ue})},10)),oe&&oe(xe.currentSlide),delete x.animationEndCallback})},te))})}}),A(k(x),"changeSlide",function(M){var E=arguments.length>1&&arguments[1]!==void 0?arguments[1]:!1,O=_(_({},x.props),x.state),H=(0,i.changeSlide)(O,M);if(!(H!==0&&!H)&&(E===!0?x.slideHandler(H,E):x.slideHandler(H),x.props.autoplay&&x.autoPlay("update"),x.props.focusOnSelect)){var Z=x.list.querySelectorAll(".slick-current");Z[0]&&Z[0].focus()}}),A(k(x),"clickHandler",function(M){x.clickable===!1&&(M.stopPropagation(),M.preventDefault()),x.clickable=!0}),A(k(x),"keyHandler",function(M){var E=(0,i.keyHandler)(M,x.props.accessibility,x.props.rtl);E!==""&&x.changeSlide({message:E})}),A(k(x),"selectHandler",function(M){x.changeSlide(M)}),A(k(x),"disableBodyScroll",function(){var M=function(O){O=O||window.event,O.preventDefault&&O.preventDefault(),O.returnValue=!1};window.ontouchmove=M}),A(k(x),"enableBodyScroll",function(){window.ontouchmove=null}),A(k(x),"swipeStart",function(M){x.props.verticalSwiping&&x.disableBodyScroll();var E=(0,i.swipeStart)(M,x.props.swipe,x.props.draggable);E!==""&&x.setState(E)}),A(k(x),"swipeMove",function(M){var E=(0,i.swipeMove)(M,_(_(_({},x.props),x.state),{},{trackRef:x.track,listRef:x.list,slideIndex:x.state.currentSlide}));E&&(E.swiping&&(x.clickable=!1),x.setState(E))}),A(k(x),"swipeEnd",function(M){var E=(0,i.swipeEnd)(M,_(_(_({},x.props),x.state),{},{trackRef:x.track,listRef:x.list,slideIndex:x.state.currentSlide}));if(E){var O=E.triggerSlideHandler;delete E.triggerSlideHandler,x.setState(E),O!==void 0&&(x.slideHandler(O),x.props.verticalSwiping&&x.enableBodyScroll())}}),A(k(x),"touchEnd",function(M){x.swipeEnd(M),x.clickable=!0}),A(k(x),"slickPrev",function(){x.callbackTimers.push(setTimeout(function(){return x.changeSlide({message:"previous"})},0))}),A(k(x),"slickNext",function(){x.callbackTimers.push(setTimeout(function(){return x.changeSlide({message:"next"})},0))}),A(k(x),"slickGoTo",function(M){var E=arguments.length>1&&arguments[1]!==void 0?arguments[1]:!1;if(M=Number(M),isNaN(M))return"";x.callbackTimers.push(setTimeout(function(){return x.changeSlide({message:"index",index:M,currentSlide:x.state.currentSlide},E)},0))}),A(k(x),"play",function(){var M;if(x.props.rtl)M=x.state.currentSlide-x.props.slidesToScroll;else if((0,i.canGoNext)(_(_({},x.props),x.state)))M=x.state.currentSlide+x.props.slidesToScroll;else return!1;x.slideHandler(M)}),A(k(x),"autoPlay",function(M){x.autoplayTimer&&clearInterval(x.autoplayTimer);var E=x.state.autoplaying;if(M==="update"){if(E==="hovered"||E==="focused"||E==="paused")return}else if(M==="leave"){if(E==="paused"||E==="focused")return}else if(M==="blur"&&(E==="paused"||E==="hovered"))return;x.autoplayTimer=setInterval(x.play,x.props.autoplaySpeed+50),x.setState({autoplaying:"playing"})}),A(k(x),"pause",function(M){x.autoplayTimer&&(clearInterval(x.autoplayTimer),x.autoplayTimer=null);var E=x.state.autoplaying;M==="paused"?x.setState({autoplaying:"paused"}):M==="focused"?(E==="hovered"||E==="playing")&&x.setState({autoplaying:"focused"}):E==="playing"&&x.setState({autoplaying:"hovered"})}),A(k(x),"onDotsOver",function(){return x.props.autoplay&&x.pause("hovered")}),A(k(x),"onDotsLeave",function(){return x.props.autoplay&&x.state.autoplaying==="hovered"&&x.autoPlay("leave")}),A(k(x),"onTrackOver",function(){return x.props.autoplay&&x.pause("hovered")}),A(k(x),"onTrackLeave",function(){return x.props.autoplay&&x.state.autoplaying==="hovered"&&x.autoPlay("leave")}),A(k(x),"onSlideFocus",function(){return x.props.autoplay&&x.pause("focused")}),A(k(x),"onSlideBlur",function(){return x.props.autoplay&&x.state.autoplaying==="focused"&&x.autoPlay("blur")}),A(k(x),"render",function(){var M=(0,r.default)("slick-slider",x.props.className,{"slick-vertical":x.props.vertical,"slick-initialized":!0}),E=_(_({},x.props),x.state),O=(0,i.extractObject)(E,["fade","cssEase","speed","infinite","centerMode","focusOnSelect","currentSlide","lazyLoad","lazyLoadedList","rtl","slideWidth","slideHeight","listHeight","vertical","slidesToShow","slidesToScroll","slideCount","trackStyle","variableWidth","unslick","centerPadding","targetSlide","useCSS"]),H=x.props.pauseOnHover;O=_(_({},O),{},{onMouseEnter:H?x.onTrackOver:null,onMouseLeave:H?x.onTrackLeave:null,onMouseOver:H?x.onTrackOver:null,focusOnSelect:x.props.focusOnSelect&&x.clickable?x.selectHandler:null});var Z;if(x.props.dots===!0&&x.state.slideCount>=x.props.slidesToShow){var X=(0,i.extractObject)(E,["dotsClass","slideCount","slidesToShow","currentSlide","slidesToScroll","clickHandler","children","customPaging","infinite","appendDots"]),te=x.props.pauseOnDotsHover;X=_(_({},X),{},{clickHandler:x.changeSlide,onMouseEnter:te?x.onDotsLeave:null,onMouseOver:te?x.onDotsOver:null,onMouseLeave:te?x.onDotsLeave:null}),Z=e.default.createElement(o.Dots,X)}var oe,le,ye=(0,i.extractObject)(E,["infinite","centerMode","currentSlide","slideCount","slidesToShow","prevArrow","nextArrow"]);ye.clickHandler=x.changeSlide,x.props.arrows&&(oe=e.default.createElement(a.PrevArrow,ye),le=e.default.createElement(a.NextArrow,ye));var xe=null;x.props.vertical&&(xe={height:x.state.listHeight});var be=null;x.props.vertical===!1?x.props.centerMode===!0&&(be={padding:"0px "+x.props.centerPadding}):x.props.centerMode===!0&&(be={padding:x.props.centerPadding+" 0px"});var rt=_(_({},xe),be),Ue=x.props.touchMove,Ve={className:"slick-list",style:rt,onClick:x.clickHandler,onMouseDown:Ue?x.swipeStart:null,onMouseMove:x.state.dragging&&Ue?x.swipeMove:null,onMouseUp:Ue?x.swipeEnd:null,onMouseLeave:x.state.dragging&&Ue?x.swipeEnd:null,onTouchStart:Ue?x.swipeStart:null,onTouchMove:x.state.dragging&&Ue?x.swipeMove:null,onTouchEnd:Ue?x.touchEnd:null,onTouchCancel:x.state.dragging&&Ue?x.swipeEnd:null,onKeyDown:x.props.accessibility?x.keyHandler:null},Qe={className:M,dir:"ltr",style:x.props.style};return x.props.unslick&&(Ve={className:"slick-list"},Qe={className:M}),e.default.createElement("div",Qe,x.props.unslick?"":oe,e.default.createElement("div",p({ref:x.listRefHandler},Ve),e.default.createElement(s.Track,p({ref:x.trackRefHandler},O),x.props.children)),x.props.unslick?"":le,x.props.unslick?"":Z)}),x.list=null,x.track=null,x.state=_(_({},t.default),{},{currentSlide:x.props.initialSlide,targetSlide:x.props.initialSlide?x.props.initialSlide:0,slideCount:e.default.Children.count(x.props.children)}),x.callbackTimers=[],x.clickable=!0,x.debouncedResize=null;var N=x.ssrInit();return x.state=_(_({},x.state),N),x}
275return P(q,[{key:"didPropsChange",value:function(x){for(var N=!1,M=0,E=Object.keys(this.props);M<E.length;M++){var O=E[M];if(!x.hasOwnProperty(O)){N=!0;break}if(!(f(x[O])==="object"||typeof x[O]=="function"||isNaN(x[O]))&&x[O]!==this.props[O]){N=!0;break}}return N||e.default.Children.count(this.props.children)!==e.default.Children.count(x.children)}}]),q})(e.default.Component),Fh}var aE,A8;function uke(){if(A8)return aE;A8=1;var e=function(t){return t.replace(/[A-Z]/g,function(n){return"-"+n.toLowerCase()}).toLowerCase()};return aE=e,aE}var lE,I8;function dke(){if(I8)return lE;I8=1;var e=uke(),t=function(i){var s=/[height|width]$/;return s.test(i)},n=function(i){var s="",o=Object.keys(i);return o.forEach(function(a,c){var d=i[a];a=e(a),t(a)&&typeof d=="number"&&(d=d+"px"),d===!0?s+=a:d===!1?s+="not "+a:s+="("+a+": "+d+")",c<o.length-1&&(s+=" and ")}),s},r=function(i){var s="";return typeof i=="string"?i:i instanceof Array?(i.forEach(function(o,a){s+=n(o),a<i.length-1&&(s+=", ")}),s):n(i)};return lE=r,lE}var cE,M8;function fke(){if(M8)return cE;M8=1;function e(t){this.options=t,!t.deferSetup&&this.setup()}return e.prototype={constructor:e,setup:function(){this.options.setup&&this.options.setup(),this.initialised=!0},on:function(){!this.initialised&&this.setup(),this.options.match&&this.options.match()},off:function(){this.options.unmatch&&this.options.unmatch()},destroy:function(){this.options.destroy?this.options.destroy():this.off()},equals:function(t){return this.options===t||this.options.match===t}},cE=e,cE}var uE,D8;function WB(){if(D8)return uE;D8=1;function e(r,i){var s=0,o=r.length,a;for(s;s<o&&(a=i(r[s],s),a!==!1);s++);}function t(r){return Object.prototype.toString.apply(r)==="[object Array]"}function n(r){return typeof r=="function"}return uE={isFunction:n,isArray:t,each:e},uE}var dE,L8;function hke(){if(L8)return dE;L8=1;var e=fke(),t=WB().each;function n(r,i){this.query=r,this.isUnconditional=i,this.handlers=[],this.mql=window.matchMedia(r);var s=this;this.listener=function(o){s.mql=o.currentTarget||o,s.assess()},this.mql.addListener(this.listener)}return n.prototype={constuctor:n,addHandler:function(r){var i=new e(r);this.handlers.push(i),this.matches()&&i.on()},removeHandler:function(r){var i=this.handlers;t(i,function(s,o){if(s.equals(r))return s.destroy(),!i.splice(o,1)})},matches:function(){return this.mql.matches||this.isUnconditional},clear:function(){t(this.handlers,function(r){r.destroy()}),this.mql.removeListener(this.listener),this.handlers.length=0},assess:function(){var r=this.matches()?"on":"off";t(this.handlers,function(i){i[r]()})}},dE=n,dE}var fE,N8;function pke(){if(N8)return fE;N8=1;var e=hke(),t=WB(),n=t.each,r=t.isFunction,i=t.isArray;function s(){if(!window.matchMedia)throw new Error("matchMedia n
275ot present, legacy browsers require a polyfill");this.queries={},this.browserIsIncapable=!window.matchMedia("only all").matches}return s.prototype={constructor:s,register:function(o,a,c){var d=this.queries,f=c&&this.browserIsIncapable;return d[o]||(d[o]=new e(o,f)),r(a)&&(a={match:a}),i(a)||(a=[a]),n(a,function(p){r(p)&&(p={match:p}),d[o].addHandler(p)}),this},unregister:function(o,a){var c=this.queries[o];return c&&(a?c.removeHandler(a):(c.clear(),delete this.queries[o])),this}},fE=s,fE}var hE,$8;function mke(){if($8)return hE;$8=1;var e=pke();return hE=new e,hE}var j8;function gke(){return j8||(j8=1,(function(e){Object.defineProperty(e,"__esModule",{value:!0}),e.default=void 0;var t=o(ao()),n=cke(),r=o(dke()),i=o(FB()),s=og();function o(B){return B&&B.__esModule?B:{default:B}}function a(B){"@babel/helpers - typeof";return a=typeof Symbol=="function"&&typeof Symbol.iterator=="symbol"?function(A){return typeof A}:function(A){return A&&typeof Symbol=="function"&&A.constructor===Symbol&&A!==Symbol.prototype?"symbol":typeof A},a(B)}function c(){return c=Object.assign?Object.assign.bind():function(B){for(var A=1;A<arguments.length;A++){var V=arguments[A];for(var K in V)Object.prototype.hasOwnProperty.call(V,K)&&(B[K]=V[K])}return B},c.apply(this,arguments)}function d(B,A){var V=Object.keys(B);if(Object.getOwnPropertySymbols){var K=Object.getOwnPropertySymbols(B);A&&(K=K.filter(function(W){return Object.getOwnPropertyDescriptor(B,W).enumerable})),V.push.apply(V,K)}return V}function f(B){for(var A=1;A<arguments.length;A++){var V=arguments[A]!=null?arguments[A]:{};A%2?d(Object(V),!0).forEach(function(K){R(B,K,V[K])}):Object.getOwnPropertyDescriptors?Object.defineProperties(B,Object.getOwnPropertyDescriptors(V)):d(Object(V)).forEach(function(K){Object.defineProperty(B,K,Object.getOwnPropertyDescriptor(V,K))})}return B}function p(B,A){if(!(B instanceof A))throw new TypeError("Cannot call a class as a function")}function m(B,A){for(var V=0;V<A.length;V++){var K=A[V];K.enumerable=K.enumerable||!1,K.configurable=!0,"value"in K&&(K.writable=!0),Object.defineProperty(B,I(K.key),K)}}function v(B,A,V){return A&&m(B.prototype,A),Object.defineProperty(B,"prototype",{writable:!1}),B}function w(B,A){if(typeof A!="function"&&A!==null)throw new TypeError("Super expression must either be null or a function");B.prototype=Object.create(A&&A.prototype,{constructor:{value:B,writable:!0,configurable:!0}}),Object.defineProperty(B,"prototype",{writable:!1}),A&&_(B,A)}function _(B,A){return _=Object.setPrototypeOf?Object.setPrototypeOf.bind():function(K,W){return K.__proto__=W,K},_(B,A)}function b(B){var A=D();return function(){var K=F(B),W;if(A){var U=F(this).constructor;W=Reflect.construct(K,arguments,U)}else W=K.apply(this,arguments);return C(this,W)}}function C(B,A){if(A&&(a(A)==="object"||typeof A=="function"))return A;if(A!==void 0)throw new TypeError("Derived constructors may only return object or undefined");return P(B)}function P(B){if(B===void 0)throw new ReferenceError("this hasn't been initialised - super() hasn't been called");return B}function D(){try{var B=!Boolean.prototype.valueOf.call(Reflect.construct(Boolean,[],function(){}))}catch{}return(D=function(){return!!B})()}function F(B){return F=Object.setPrototypeOf?Object.getPrototypeOf.bind():function(V){return V.__proto__||Object.getPrototypeOf(V)},F(B)}function R(B,A,V){return A=I(A),A in B?Object.defineProperty(B,A,{value:V,enumerable:!0,configurable:!0,writable:!0}):B[A]=V,B}function I(B){var A=k(B,"string");return a(A)=="symbol"?A:String(A)}function k(B,A){if(a(B)!="object"||!B)return B;var V=B[Symbol.toPrimitive];if(V!==void 0){var K=V.call(B,A);if(a(K)!="object")return K;throw new TypeError("@@toPrimitive must return a primitive value.")}return(A==="string"?String:Number)(B)}var L=(0,s.canUseDOM)()&&mke();e.default=(function(B){w(V,B);var A=b(V);function V(K){var W;return p(this,V),W=A.call(this,K),R(P(W),"innerSliderRefHandler",function(U){return W.innerSlider=U}),R(P(W),"slickPrev",function(){return W.innerSlider.slickPrev()}),R(P(W),"slickNext",function(){return W.innerSlider.slickNext()}),R(P(W),"slickGoTo",function(U){var q=arguments.length>1&&arguments[1]!==void 0?arguments[1]:!1;return W.innerSlider.slickGoTo(U,q)}),R(P(W),"slickPause",function(){return W.innerSlider.pause("paused")}),R(P(W),"slickPlay",function(){return W.innerSlider.autoPlay("play")}),W.state={breakpoint:null},W._responsiveMediaHandlers=[],W}return v(V,[{key:"media",value:function(W,U){L.register(W,U),this._responsiveMediaHandlers.push({query:W,handler:U})}},{key:"componentDidMount",value:function(){var W=this;if(this.props.responsive){var U=this.props.responsive.map(function(z){return z.breakpoint});U.sort(function(z,x){return z-x}
275),U.forEach(function(z,x){var N;x===0?N=(0,r.default)({minWidth:0,maxWidth:z}):N=(0,r.default)({minWidth:U[x-1]+1,maxWidth:z}),(0,s.canUseDOM)()&&W.media(N,function(){W.setState({breakpoint:z})})});var q=(0,r.default)({minWidth:U.slice(-1)[0]});(0,s.canUseDOM)()&&this.media(q,function(){W.setState({breakpoint:null})})}}},{key:"componentWillUnmount",value:function(){this._responsiveMediaHandlers.forEach(function(W){L.unregister(W.query,W.handler)})}},{key:"render",value:function(){var W=this,U,q;this.state.breakpoint?(q=this.props.responsive.filter(function(te){return te.breakpoint===W.state.breakpoint}),U=q[0].settings==="unslick"?"unslick":f(f(f({},i.default),this.props),q[0].settings)):U=f(f({},i.default),this.props),U.centerMode&&(U.slidesToScroll>1,U.slidesToScroll=1),U.fade&&(U.slidesToShow>1,U.slidesToScroll>1,U.slidesToShow=1,U.slidesToScroll=1);var z=t.default.Children.toArray(this.props.children);z=z.filter(function(te){return typeof te=="string"?!!te.trim():!!te}),U.variableWidth&&(U.rows>1||U.slidesPerRow>1)&&(console.warn("variableWidth is not supported in case of rows > 1 or slidesPerRow > 1"),U.variableWidth=!1);for(var x=[],N=null,M=0;M<z.length;M+=U.rows*U.slidesPerRow){for(var E=[],O=M;O<M+U.rows*U.slidesPerRow;O+=U.slidesPerRow){for(var H=[],Z=O;Z<O+U.slidesPerRow&&(U.variableWidth&&z[Z].props.style&&(N=z[Z].props.style.width),!(Z>=z.length));Z+=1)H.push(t.default.cloneElement(z[Z],{key:100*M+10*O+Z,tabIndex:-1,style:{width:"".concat(100/U.slidesPerRow,"%"),display:"inline-block"}}));E.push(t.default.createElement("div",{key:10*M+O},H))}U.variableWidth?x.push(t.default.createElement("div",{key:M,style:{width:N}},E)):x.push(t.default.createElement("div",{key:M},E))}if(U==="unslick"){var X="regular slider "+(this.props.className||"");return t.default.createElement("div",{className:X},z)}else x.length<=U.slidesToShow&&!U.infinite&&(U.unslick=!0);return t.default.createElement(n.InnerSlider,c({style:this.props.style,ref:this.innerSliderRefHandler},(0,s.filterSettings)(U)),x)}}]),V})(t.default.Component)})(nE)),nE}var F8;function yke(){return F8||(F8=1,(function(e){Object.defineProperty(e,"__esModule",{value:!0}),e.default=void 0;var t=n(gke());function n(r){return r&&r.__esModule?r:{default:r}}e.default=t.default})(tE)),tE}var vke=yke();const _ke=Pl(vke),qB=(e,t)=>xde(t)||Tde(t)?e<5:!1,KB=e=>1e3*2**e,wke=e=>{const t=new Set;return e.map(n=>({...n,data:n.data.filter(r=>t.has(r.id)?!1:(t.add(r.id),!0))}))},bke=(e,t=new Date)=>e.map(n=>({...n,data:n.data.map(r=>r.status!=="UNATTENDED"&&r.status!=="INCOMPLETE"||!r.deadline||new Date(r.deadline)<=t||r.availableAt&&new Date(r.availableAt)>t?r:{...r,status:r.status==="UNATTENDED"?"FUTURE":"ACTIVE",isReopened:!0})})),Ske=20,GB=()=>{const e=kl(t=>t.testDefinitionId);return pX({queryKey:["assignments",e],queryFn:({pageParam:t=0})=>Gr.assignments.getAssignments({limit:Ske,offset:t,testDefinitionId:e??void 0}),initialPageParam:0,getNextPageParam:t=>{const{count:n,limit:r,offset:i}=t.data,s=i+r;return s<n?s:void 0},select:t=>({pages:wke(bke(t.pages.map(n=>n.data))),pageParams:t.pageParams})})},YB=7,Eke=(e=YB)=>{const{data:t}=GB();return g.useMemo(()=>{const n=ai(),r=n.add(e,"day");return(t?.pages??[]).flatMap(i=>i.data).filter(i=>{if(!i.deadline)return!1;const s=ai(i.deadline);return!s.isAfter(n)||s.isAfter(r)?!1:i.status==="ACTIVE"?!0:i.status==="FUTURE"&&(!i.availableAt||!ai(i.availableAt).isAfter(n))})},[t,e])},xke=25,tAe=()=>{const e=GB(),{data:t,hasNextPage:n,isFetchingNextPage:r,fetchNextPage:i}=e,s=t?.pages.length??0,o=n===!0&&s>=xke,a=n===!0&&!o;g.useEffect(()=>{a&&!r&&i()},[a,r,i]);const c=g.useMemo(()=>t?.pages.flatMap(d=>d.data)??[],[t]);return{...e,assignments:c,isComplete:!a,isTruncated:o}},nAe=e=>As({queryKey:["assignments",e],queryFn:async()=>Gr.assignments.getAssignmentById({assignmentId:e}),retry:qB,retryDelay:KB,select:t=>{const n=t.data,r=n.questions.map(c=>({...c,answer:c.userAnswer||""})),i=n.availableAt,s=n.deadline,o=n.timeLimit&&n.timeLimitValue!=null?n.timeLimitValue:null,a=o??ai(s).diff(i,"second");return{title:n.title,questions:r,duration:a,deadline:s,startDate:n.startDate,timeLimitSeconds:o}}}),rAe=e=>As({queryKey:["assignments",e],queryFn:async()=>Gr.assignments.getAssignmentById({assignmentId:e}),select:t=>t.data}),iAe=(e,t)=>
275{const n=fX({queries:t.map(r=>({queryKey:["exams",e,"questions",r],queryFn:()=>Gr.assignments.getAssignmentQuestionById({assignmentId:e,questionId:r}),select:i=>i.data,staleTime:1/0}))});return g.useMemo(()=>{const r=new Map;return t.forEach((i,s)=>{const o=n[s]?.data;o&&r.set(i,{isCorrect:o.isCorrectlyAnswered,isCorrectnessReleased:!!o.correctAnswer?.length})}),{byQuestionId:r,isComplete:n.every(i=>!i.isPending)}},[t,n])};function Cke(e,t,n=new Date){return e.filter(r=>(r.isTeacherAssigned??!1)===t).every(r=>r.status==="COMPLETED"||ag(r.deadline,n))}function U8(e,t=new Date){return e.status==="ACTIVE"&&ag(e.deadline,t)}function sAe({limitSeconds:e,startedAt:t,deadline:n,now:r=new Date}){const i=e!=null&&t?e-Math.ceil((r.getTime()-new Date(t).getTime())/1e3):Number.POSITIVE_INFINITY,s=n?Math.floor((new Date(n).getTime()-r.getTime())/1e3):Number.POSITIVE_INFINITY,o=Math.min(i,s);return Number.isFinite(o)?Math.max(0,o):0}function oAe({limitSeconds:e,startedAt:t,deadline:n,leadSeconds:r=60,now:i=new Date}){if(!n)return null;const s=(new Date(n).getTime()-i.getTime())/1e3;return!Number.isFinite(s)||s<=0||(e!=null&&t?e-(i.getTime()-new Date(t).getTime())/1e3:Number.POSITIVE_INFINITY)<=s?null:Math.max(0,(s-r)*1e3)}function kke(e){const t=n=>n.milestoneType==="Diagnosis"?0:n.status==="COMPLETED"?1:2;return[...e].sort((n,r)=>t(n)-t(r))}function ag(e,t=new Date){return e?new Date(e)<t:!1}function Tke({hasActiveExam:e,isCurrentExamActive:t,arePrevExamsSettled:n,availableAt:r,deadline:i,isFakeExam:s,now:o=new Date}){const a=e&&!t,c=r?new Date(r)<=o:!0;return a||!n||!c||ag(i,o)||s}const JB=e=>ai(e).format("D MMM, HH:mm"),Rke=e=>e?`This exam closed on ${JB(e)}`:"This exam has closed";function Pke({hasActiveExam:e,isCurrentExamActive:t,arePrevExamsSettled:n,availableAt:r,deadline:i,now:s=new Date}){return e&&!t?"Finish the exam you already have in progress first":n?r&&new Date(r)>s?`This exam opens on ${JB(r)}`:ag(i,s)?Rke(i):null:"Finish your previous exam first"}const aAe=e=>As({queryKey:["exams",e],queryFn:()=>Gr.exams.getExamById({examId:e}),select:t=>t.data,retry:qB,retryDelay:KB,gcTime:0}),Oke=(e=!1)=>{const t=kl(n=>n.testDefinitionId);return As({queryKey:["exams",t],queryFn:()=>Gr.milestones.getMilestones({testDefinitionId:t||void 0}),select:n=>{const r=n.data.milestones.filter(a=>a.milestoneType==="Exam"||a.milestoneType==="Diagnosis"),i=new Date,s=r.some(a=>a.milestoneType==="Exam"&&a.status==="ACTIVE"&&!U8(a,i)),o=r.map((a,c)=>{if(a.milestoneType==="Exam"){const d=r.slice(0,c).filter(v=>v.milestoneType==="Exam"),f=Cke(d,a.isTeacherAssigned??!1,i),p=U8(a,i),m={hasActiveExam:s,isCurrentExamActive:a.status==="ACTIVE"&&!p,arePrevExamsSettled:f,availableAt:a.availableAt,deadline:a.deadline,now:i};return{...a,title:a.title?.trim()||`Exam ${a.examNo}`,isBlocked:Tke({...m,isFakeExam:!1}),blockedReason:Pke(m),isClosed:p||a.status==="FUTURE"&&ag(a.deadline,i)}}return a});return kke(o)},refetchInterval:({state:{dataUpdateCount:n}})=>e&&n<5?1e3*2:!1})},lAe=({examId:e,questionId:t,type:n})=>As({queryKey:["exams",e,"questions",t],queryFn:()=>n==="exam"?Gr.exams.getExamQuestionById({examId:e,questionId:t}):n==="diagnosis"?Gr.diagnosis.getDiagnosisQuestionById({diagnosisId:e,questionId:t}):Gr.assignments.getAssignmentQuestionById({assignmentId:e,questionId:t}),enabled:!!t,select:r=>r.data}),Ake=(e,t)=>e.localeCompare(t,void 0,{numeric:!0,sensitivity:"base"}),z8=["math","english","reading","science"],Kv=e=>(e??"").trim().toLowerCase(),B8=e=>{const t=z8.indexOf(Kv(e));return t===-1?z8.length:t},cAe=e=>As({queryKey:["exams",e,"stats"],queryFn:()=>Gr.exams.getExamStats({examId:e}),enabled:!!e,select:t=>{const n=t.data.subjects.map(i=>{const s=i.totalQuestionCount,o=i.correctQuestionCount,a=i.incorrectQuestionCount,c=i.omittedQuestionCount,d=s>0?Math.round(o/s*100):0;return{...i,total:s,correct:o,incorrect:a,omitted:c,percentage:d,color:d>=70?"green":d>=30?"yellow":"red",questions:i.questions}});n.sort((i,s)=>Ake(i.topic,s.topic));const r=new Map;return n.forEach(i=>{const s=Kv(i.subject),o=r.get(s);o?o.topics.push(i):r.set(s,{subject:i.subject,topics:[i]})}),[...r.values()].sort((i,s)=>B8(i.subject)-B8(s.subject)||Kv(i.subject).localeCompare(Kv(s.subject)))}}),Ike=e=>{const{data:t}=Oke();return g.useMemo(()=>
275{if(!t)return[];const n=ai(),r=n.add(e,"day");return t.flatMap(i=>i.milestoneType!=="Exam"||!i.isTeacherAssigned?[]:[{examId:i.examId,title:i.title,status:i.status,availableAt:i.availableAt,deadline:i.deadline}]).filter(i=>{if(!i.deadline)return!1;const s=ai(i.deadline);return!s.isAfter(n)||s.isAfter(r)?!1:i.status==="ACTIVE"?!0:i.status==="FUTURE"&&(!i.availableAt||!ai(i.availableAt).isAfter(n))}).sort((i,s)=>ai(i.deadline).valueOf()-ai(s.deadline).valueOf())},[t,e])},Mke=(e=500)=>new Promise(t=>setTimeout(t,e));let lC=!1;const Dke=1e3,Lke=3e3,ZB=()=>typeof document<"u"&&document.fullscreenEnabled===!0,Nke=()=>typeof document<"u"&&document.fullscreenElement!=null,$ke="Your browser did not allow fullscreen. Try again — if it keeps failing, check this site's fullscreen permission in your browser settings.",XB=async()=>{if(!ZB())return"unavailable";if(document.fullscreenElement)return"entered";try{return await document.documentElement.requestFullscreen(),"entered"}catch(e){return ia(e instanceof Error?e:new Error(String(e)),{feature:"fullscreen",action:"requestFullscreen"}),"refused"}},jke=()=>lC,Fke=async()=>{lC=!0;try{document.fullscreenElement&&await document.exitFullscreen()}catch{}finally{window.setTimeout(()=>{lC=!1},Dke)}},uAe=e=>{const t=g.useRef(e);t.current=e,g.useEffect(()=>{const n=()=>{document.fullscreenElement||jke()||t.current()};return document.addEventListener("fullscreenchange",n),()=>document.removeEventListener("fullscreenchange",n)},[])},dAe=()=>{const[e,t]=g.useState(Nke),[n,r]=g.useState(!1),[i,s]=g.useState(null),o=g.useRef(!1);g.useEffect(()=>{const c=()=>{const d=document.fullscreenElement!=null;t(d),d&&s(null)};return document.addEventListener("fullscreenchange",c),()=>document.removeEventListener("fullscreenchange",c)},[]);const a=g.useCallback(async()=>{if(o.current)return;o.current=!0,r(!0),s(null);const c=await Promise.race([XB(),Mke(Lke).then(()=>"unsettled")]),d=document.fullscreenElement!=null;t(d),s(d||c==="unavailable"?null:$ke),r(!1),o.current=!1},[]);return{isSupported:ZB(),isFullscreen:e,isEntering:n,failure:i,enter:a,exit:Fke}},Uke=e=>g.createElement("svg",{width:12,height:12,viewBox:"0 0 12 12",fill:"none",xmlns:"http://www.w3.org/2000/svg",...e},g.createElement("rect",{x:.34375,y:10.2427,width:14,height:2,rx:1,transform:"rotate(-45 0.34375 10.2427)",fill:"currentColor"}),g.createElement("rect",{x:1.75781,y:.343262,width:14,height:2,rx:1,transform:"rotate(45 1.75781 0.343262)",fill:"currentColor"})),zke="/assets/diagnostic-banner-DX0RIt5a.png",Bke="/assets/exam-banner-Dc6lbjX0.png",Hke=e=>`Due ${ai(e).format("D MMM, HH:mm")}`,Vke="bg-secondary/13 text-secondary/50",Wke=({className:e})=>{const t=jl(),n=Eke(),r=Ike(YB),[i,s]=g.useState(new Set),o=p=>{s(m=>new Set([...m,p]))},a=p=>j.jsx("span",{className:sn("inline-block select-none rounded-full px-2.5 py-1 text-[12px] font-semibold leading-[12px] tracking-tight",Vke),children:Hke(p)}),c=n.map(p=>({key:`assignment-${p.id}`,deadline:p.deadline,title:p.title,description:a(p.deadline),buttonText:p.status==="ACTIVE"?"Continue assignment":"Start assignment",image:zke,onAction:()=>t(`/assignments/${p.id}/intro`)})),d=r.map(p=>({key:`exam-${p.examId}`,deadline:p.deadline,title:p.title,description:a(p.deadline),buttonText:p.status==="ACTIVE"?"Resume exam":"Start exam",image:Bke,onAction:()=>{if(p.status==="ACTIVE"){XB(),t(`/exams/${p.examId}`,{state:{examTitle:p.title}});return}t(`/exams/${p.examId}/intro`,{state:{examTitle:p.title}})}})),f=[...c,...d].filter(p=>!i.has(p.key)).sort((p,m)=>ai(p.deadline).valueOf()-ai(m.deadline).valueOf());return f.length===0?null:j.jsx("div",{className:sn("slider-container",e),children:j.jsx(_ke,{className:"slider",arrows:!0,dots:!0,infinite:!1,slidesToScroll:1,swipeToSlide:!1,responsive:[{breakpoint:1024,settings:{dots:!1}}],children:f.map(p=>j.jsx("div",{children:j.jsx(qke,{title:p.title,description:p.description,buttonText:p.buttonText,image:p.image,link:p.link,onAction:p.onAction,isActionPending:p.isActionPending,onClose:()=>o(p.key)})},p.key))})})},qke=({title:e,description:t,buttonText:n,image:r,link:i,onAction:s,isActionPending:o,onClose:a,className:c})=>{const d=s?j.jsxs(Kr,{color:"secondary",className:"w-full lg:w-auto lg:mr-12",onClick:s,disabled:o,children:[n,o&&j.jsx(E7,{className:"size-4 animate-spin ml-2"})]}):j.jsx(i1,{to:i??"#",className:"w-full lg:w-auto",children:j.jsx(Kr,{color:"secondary",className:"w-full lg:w-auto lg:mr-12",children:n})});return j.jsxs("div",{className:sn("bg-[#dfecfd] bg-(image:--banner-gradient) lg:rounded-3xl flex flex-col lg:flex-row items-center relative p-6 lg:p-0 lg:min-h-[140px]",c),children:[j.jsx(Kr,{variant:"ghost",className:"absolute top-3 right-3 size-8 rounded-full p-0 hover:bg-gray-200 z-10",onClick:a,children:j.jsx(Uke,{className:"size-3"})}),j.jsx("img",{src:r,className:"w-30 lg:w-60 mb-4 lg:mb-0",alt:"banner image"}),j.jsxs("div",{className:"flex-1 text-center lg:text-left mb-4 lg:mb-0 px-2 lg:px-0",children:[j.jsx("h3",{className:"font-semibold text-lg mb-3",children:e}),j.jsx("p",{className:"text-[15px]",children:t})]}),s?j.jsx("div",{className:"w-full lg:w-auto",children:d}):d]})},QB=(e,t)=>{if(!e)return!1;const n=e.filter(r=>r.ready);return n.length===0||n.some(r=>r.testDefinitionId===t)},fAe=()=>{const e=kl(r=>r.testDefinitionId),{data:t,isError:n}=XT();return n||QB(t,e)},Kke=()=>{const e=kl(i=>i.testDefinitionId),t=RU(),{data:n}=XT(),r=g.useRef(!1);g.useEffect(()=>{if(!n||r.current||QB(n,e))return;const i=n.filter(s=>s.ready);r.current=!0,t(i[0]).finally(()=>{r.current=!1})},[n,e,t])},Gke=()=>(Kke(),j.jsxs(j.Fragment,{children:[j.jsx(LCe,{}),j.jsxs("div",{className:"max-w-full lg:max-w-[1307px] mx-auto lg:px-4 lg:flex lg:flex-col lg:min-h-[calc(100svh-84px)]",children:[j.jsx(Wke,{className:"mb-4 mt-4"}),j.jsx(qm,{})]})]})),Yke=()=>{const{pathname:e}=Mi();return g.useEffect(()=>{document.body.scrollTo(0,0)},[e]),null},Jke=()=>j.jsx(sde,{position:"bottom-right",toastOptions:{duration:3e3}}),Zke=DB,hAe=TCe,Xke=NB,Qke=LB,eTe=FR,tTe=RCe,eH=g.forwardRef(({className:e,variant:t="full",...n},r)=>j.jsx(j.Fragment,{children:j.jsx($R,{ref:r,className:sn(t==="full"&&"fixed inset-0 z-50 bg-black/30 data-[state=open]:animate-in data-[state=closed]:animate-out data-[state=closed]:fade-out-0 data-[state=open]:fade-in-0",t==="gradient"&&"fixed inset-0 z-50 bg-gradient-to-r from-transparent to-black/30 data-[state=open]:animate-in data-[state=closed]:animate-out data-[state=closed]:fade-out-0 data-[state=open]:fade-in-0",e),...n})}));eH.displayName=$R.displayName;const tH=g.forwardRef(({className:e,mobileClassName:t,children:n,...r},i)=>{const{isMobile:s}=A_();return j.jsxs(jR,{ref:i,className:sn("fixed left-[50%] top-[50%] z-50 grid w-full max-w-lg translate-x-[-50%] translate-y-[-50%] border border-border bg-white 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 sm:rounded-[26px]",s?["flex flex-col shadow-lg w-full max-w-none","fixed inset-x-0 bottom-0 top-auto","translate-y-0 translate-x-0","rounded-t-2xl","max-h-[90vh]","left-0 bottom-0","border-t border-x-0 border-b-0",t]:e),...r,children:[n,j.jsx(FR,{className:"absolute right-4 top-4 roun
275ded-sm opacity-70 ring-offset-background transition-opacity hover:opacity-100 focus:outline-none focus:ring-2 focus:ring-ring focus:ring-offset-2 disabled:pointer-events-none data-[state=open]:bg-accent data-[state=open]:text-muted-foreground",children:j.jsx("span",{className:"sr-only",children:"Close"})}),j.jsx(tTe,{})]})});tH.displayName=jR.displayName;const nTe=({className:e,icon:t,children:n,iconClassName:r,textClassName:i,wrapperClassName:s})=>j.jsxs("div",{className:sn("flex items-center gap-[14px]",e),children:[t!=null&&j.jsx("div",{className:sn("p-[3px] rounded-[10px] bg-white border size-[30px] lg:size-[38px]",s),children:j.jsx("div",{className:sn("flex items-center justify-center rounded-[6px] size-full bg-primary/20 text-primary",r),children:t})}),n&&j.jsx("span",{className:sn("font-semibold text-[15px]",i),children:n})]}),rTe=()=>As({queryKey:["payment-plans"],queryFn:Gr.payment.getPlans,select:e=>e.data.plans}),pAe=(e={})=>As({queryKey:["portal-link"],queryFn:Gr.payment.getPortalLink,select:t=>t.data.portalUrl,enabled:e.enabled??!0}),iTe=({isInDialog:e})=>{const t=iF(),{data:n=[],status:r}=rTe();return j.jsxs(j.Fragment,{children:[r==="pending"&&j.jsxs("div",{className:"space-y-2",children:[j.jsx("div",{className:"bg-gray-100 animate-pulse h-20 w-full rounded-[20px] lg:rounded-[24px]"}),j.jsx("div",{className:"bg-gray-100 animate-pulse h-20 w-full rounded-[20px] lg:rounded-[24px]"}),j.jsx("div",{className:"bg-gray-100 animate-pulse h-20 w-full rounded-[20px] lg:rounded-[24px]"}),j.jsx("div",{className:"bg-gray-100 animate-pulse h-20 w-full rounded-[20px] lg:rounded-[24px]"})]}),j.jsx("div",{className:"space-y-[8px] lg:space-y-2",children:n.map((i,s)=>{const o=(i.price/100/i.period).toFixed(2);return j.jsxs("button",{value:i.id,"aria-label":i.title,className:"items-start lg:items-center text-start p-5 justify-start gap-4 h-auto lg:py-4 w-full border rounded-[20px] lg:rounded-[24px] cursor-pointer hover:bg-gray-100 transition-colors bg-white data-[state=on]:bg-primary/30",onClick:()=>{t.mutate({paymentPlanId:i.id})},children:[j.jsxs("h3",{className:sn("font-poppins font-medium text-[24px] lg:text-2xl mb-1 text-[#3F4E77]",e&&"text-[26px] font-semibold"),children:[`$${o} `,j.jsx("span",{className:sn("font-poppins text-xl font-medium ml-0",e&&"text-[26px] font-semibold"),children:"/ Month"})]}),j.jsx("p",{className:"font-poppins text-[13px] lg:text-[15px] font-normal text-navy-blue",children:`$${i.price/100} billed every ${i.period} month`})]},s)})})]})},sTe=e=>g.createElement("svg",{width:18,height:20,viewBox:"0 0 18 20",fill:"none",xmlns:"http://www.w3.org/2000/svg",...e},g.createElement("path",{d:"M15.6584 1.29775C16.3547 1.85357 16.896 2.63687 17.2449 3.45446C17.2525 3.47167 17.26 3.48887 17.2678 3.5066C17.5055 4.05313 17.6439 4.67168 17.6643 5.26798C17.6669 5.34205 17.6726 5.415 17.6792 5.48879C17.7182 6.10459 17.607 6.72201 17.4177 7.30541L17.3976 7.36826C17.2656 7.77568 17.0826 8.14774 16.8622 8.51367C16.8506 8.53311 16.8389 8.55256 16.8269 8.57259C16.6177 8.91171 16.3631 9.19724 16.0836 9.47762C16.0663 9.49503 16.049 9.51246 16.0312 9.5304C14.9341 10.6294 13.5329 11.1278 12.0025 11.1247C11.2046 11.1134 10.4383 10.8924 9.72655 10.5383C9.6977 10.524 9.66887 10.5097 9.63916 10.495C9.61131 10.4808 9.58345 10.4666 9.55477 10.4519C9.53028 10.4395 9.5058 10.427 9.48057 10.4141C9.357 10.3409 9.24216 10.2534 9.12551 10.1694L5.61285 13.7108L8.08898 16.2071L6.70695 17.6004L5.17137 16.0523L4.17323 17.0586L5.70882 18.6067L4.32679 20L1.79307 17.4456L1.65871 17.5037C1.31222 17.578 1.05818 17.5071 0.75895 17.3222C0.506113 17.1081 0.362907 16.8705 0.315069 16.5361C0.29596 16.176 0.426911 15.8636 0.663032 15.5977C0.736664 15.5208 0.811441 15.4452 0.886716 15.3699C0.915683 15.3407 0.944645 15.3114 0.97358 15.2822C1.05272 15.2022 1.13211 15.1225 1.21153 15.0428C1.29729 14.9567 1.38283 14.8703 1.46839 14.784C1.61653 14.6346 1.76481 14.4854 1.91319 14.3362C2.12772 14.1206 2.34203 13.9047 2.55629 13.6888C2.90395 13.3384 3.25179 12.9883 3.59973 12.6382C3.93766 12.2983 4.2755 11.9582 4.61323 11.6181C4.63406 11.5971 4.65489 11.5761 4.67635 11.5545C4.78085 11.4492 4.88535 11.344 4.98984 11.2387C5.85629 10.366 6.72301 9.49356 7.58992 8.62131C7.57426 8.59794 7.55862 8.57456 7.54249 8.55048C7.52166 8.51922 7.50083 8.48794 7.48 8.45667C7.46971 8.44134 7.45942 8.426 7.44882 8.4102C7.35516 8.26934 7.27641 8.12391 7.20242 7.97183C7.18939 7.94516 7.17636 7.91848 7.16293 7.891C6.90704 7.358 6.75089 6.79128 6.68776 6.20237L6.67591 6.09458C6.62804 5.61952 6.63131 5.14524 6.70695 4.6736C6.70994 4.65451 6.71295 4.63541 6.71603 4.61574C6.94173 3.22324 7.74342 1.91068 8.87556 1.07626C10.0843 0.227375 11.5615 -0.177853 13.0273 0.0739548C13.9824 0.251854 14.8299 0.644581 15.5942 1.24839L15.6584 1.29775ZM15.6134 5.33156C15.5311 4.26442 14.9376 3.2393 14.0343 2.66386C14.0181 2.6538
2756 14.0024 2.64415 13.9866 2.63444C13.7262 2.4739 13.4564 2.33266 13.1665 2.23441C12.2854 1.9555 11.3463 2.04839 10.5287 2.47451C10.4986 2.49052 10.4986 2.49053 10.4691 2.50624C10.083 2.71041 9.78931 3.01523 9.49205 3.33098C8.97046 3.90535 8.65465 4.76135 8.67908 5.54125L8.68402 5.62183C8.72547 6.35256 8.92284 7.00882 9.34025 7.61382C9.92142 8.35737 10.7194 8.8975 11.6581 9.0376L11.736 9.04705C11.8932 9.06687 12.0488 9.09259 12.2071 9.07736C12.2921 9.06522 12.2921 9.06522 12.3758 9.063C12.4367 9.06112 12.4977 9.05844 12.5585 9.05521C13.47 8.97991 14.2711 8.48021 14.8551 7.79063C15.4019 7.12221 15.6917 6.25179 15.6182 5.38606C15.6158 5.35854 15.6157 5.35853 15.6134 5.33156Z",fill:"#00A75F"})),oTe=()=>{const e=q0(n=>n.isUpgradeDialogOpen&&!n.hasFullAccess),t=q0(n=>n.setIsUpgradeDialogOpen);return j.jsx(Zke,{open:e,onOpenChange:t,children:j.jsxs(Qke,{children:[j.jsx(eH,{}),j.jsx(tH,{onCloseAutoFocus:n=>n.preventDefault(),className:"p-6",children:j.jsxs("div",{className:"py-[39px] lg:py-0",children:[j.jsxs("div",{className:"flex flex-col items-center text-center mb-[22px] lg:mb-0 gap-[25px] lg:gap-[15px] px-4 lg:px-0 lg:pt-0 lg:pb-6 relative",children:[j.jsx(eTe,{asChild:!0,children:j.jsx(Kr,{variant:"outline",className:"px-0 size-9 absolute right-[15px] top-[-9px] lg:top-0 lg:right-0",onClick:()=>t(!1),children:j.jsx(x7,{className:"size-5"})})}),j.jsx(nTe,{wrapperClassName:"size-[38px]",icon:j.jsx(sTe,{className:"size-[18px]"})}),j.jsx(Xke,{className:"font-medium text-lg",children:"Upgrade for More Control"}),j.jsx(LR,{className:"text-[15px] lg:text-base leading-relaxed text-text-default/75",children:"Track progress, review tricky questions, master vocabulary, and customize your study path with Pro tools."})]}),j.jsx("div",{className:"px-4 lg:px-0",children:j.jsx(iTe,{isInDialog:!0})})]})})]})})},aTe=()=>j.jsxs(j.Fragment,{children:[j.jsx(Yke,{}),j.jsx(Jke,{}),j.jsx(qm,{}),j.jsx(oTe,{})]}),lTe=()=>{const e=fj();g.useEffect(()=>{e instanceof Error&&ia(e,{source:"RouteErrorBoundary"})},[e]);const t=()=>tf(e)?e.status===404?"The page you are looking for does not exist.":e.statusText||"An unexpected error occurred.":e instanceof Error?e.message:"An unexpected error occurred.";return j.jsx(p$,{title:"Something went wrong",description:t(),className:"justify-center min-h-screen p-4",children:j.jsxs("div",{className:"flex items-center gap-4",children:[j.jsx(Kr,{variant:"outline",onClick:()=>window.location.reload(),children:"Refresh Page"}),j.jsx(Kr,{onClick:()=>window.location.href="/",children:"Go Home"})]})})},cTe=g.lazy(()=>bn(()=>import("./progress.page-B40lKx4M.js"),__vite__mapDeps([0,1,2,3,4,5,6,7,8,9,10,11,12,13,14,15,16,17,18])).then(e=>({default:e.ProgressPage}))),uTe=g.lazy(()=>bn(()=>import("./practice.page-Bp3Jq6fZ.js"),__vite__mapDeps([19,20,10,17,21,22,12,23,1,2,3,4,5,24,25,26,18,27,28,6,7,8,9,29,30,31,15])).then(e=>({default:e.PracticePage}))),dTe=g.lazy(()=>bn(()=>import("./vocabulary.page-Rpq0iNwJ.js"),__vite__mapDeps([32,30,21,33,10,18,23,34,35])).then(e=>({default:e.VocabularyPage}))),fTe=g.lazy(()=>bn(()=>import("./vocabulary-practice.page-DXBYs3RU.js"),__vite__mapDeps([36,20,10,17,25,23,4,26,12,7,29,30,21])).then(e=>({default:e.VocabularyPracticePage}))),hTe=g.lazy(()=>bn(()=>import("./review-exams.page-COy3qmgE.js"),__vite__mapDeps([37,11,12,2,3,4,5,8,10,13,25,23,26,29,30,21,38,39,28,35,40])).then(e=>({default:e.ReviewExamsPage}))),pTe=g.lazy(()=>bn(()=>import("./account.page-Bpqks3ND.js"),__vite__mapDeps([41,42,43])).then(e=>({default:e.AccountPage}))),mTe=g.lazy(()=>bn(()=>import("./plans.page-4M8B_kLb.js"),__vite__mapDeps([44,42,43,13])).then(e=>({default:e.PlansPage}))),gTe=g.lazy(()=>bn(()=>import("./review-questions.page-BNGJD_vw.js"),__vite__mapDeps([45,29,1,2,3,4,5,25,23,10,26,12,22,24,17,20,21,18,30,33,46,34,35])).then(e=>({default:e.ReviewQuestionsPage}))),yTe=g.lazy(()=>bn(()=>import("./exam-intro.page-B0XQVenI.js"),__vite__mapDeps([47,48,5,30,21,49,39,10,50,51,26,52,17])).then(e=>({default:e.ExamIntroPage}))),vTe=g.lazy(()=>bn(()=>import("./exam.page-COv-aXKH.js"),__vite__mapDeps([53,54,18,25,23,10,4,26,12,22,46,27,51,9,30,21,49,55,15,56,16,50,5])).then(e=>({default:e.ExamPage}))),_Te=g.lazy(()=>bn(()=>import("./login.page-BCDLFU7O.js"),[]).then(e=>({default:e.LogInPage}))),wTe=g.lazy(()=>bn(()=>import("./classlink-login.page-DCq3V0GV.js"),[]).then(e=>({default:e.ClassLinkLoginPage}))),bTe=g.lazy(()=>bn(()=>import("./clever-login.page-Fh__G1lk.js"),[]).then(e=>({default:e.CleverLoginPage}))),STe=g.lazy(()=>bn(()=>import("./signup.page-CWsnwJLU.js"),__vite__mapDeps([57,43,31])).then(e=>({default:e.SignUpPage}
275))),ETe=g.lazy(()=>bn(()=>import("./diagnosis.page-DPKv5Bly.js"),__vite__mapDeps([58,55,54,18,25,23,10,4,26,12,22,46,27,51,9,30,21])).then(e=>({default:e.DiagnosisPage}))),xTe=g.lazy(()=>bn(()=>import("./home.page-CKgvn6iJ.js"),[]).then(e=>({default:e.HomePage}))),CTe=g.lazy(()=>bn(()=>import("./select-test.page-DfxayTyP.js"),[]).then(e=>({default:e.SelectTestPage}))),kTe=g.lazy(()=>bn(()=>import("./payment-success.page-q_JRqRaU.js"),[]).then(e=>({default:e.PaymentSuccessPage}))),TTe=g.lazy(()=>bn(()=>import("./assignments.page-CiOhC0Si.js"),__vite__mapDeps([59,4,17,16,5,34,40,3,35,30])).then(e=>({default:e.AssignmentsPage}))),RTe=g.lazy(()=>bn(()=>import("./assignment.page-J6Mkkc7A.js"),__vite__mapDeps([60,61,39,55,54,18,25,23,10,4,26,12,22,46,27,51,9,30,21,56,16,50,5,62,14,48])).then(e=>({default:e.AssignmentPage}))),PTe=g.lazy(()=>bn(()=>import("./assignment-intro.page-CZagWb96.js"),__vite__mapDeps([63,52,17,55,61,39,50,5,48,16,30,21])).then(e=>({default:e.AssignmentIntroPage}))),OTe=g.lazy(()=>bn(()=>import("./review-assignment.page-zo8qfXau.js"),__vite__mapDeps([64,25,23,10,4,26,12,29,35,30,62,21,38])).then(e=>({default:e.ReviewAssignmentPage}))),ATe=g.lazy(()=>bn(()=>import("./logout.page-8Z55a0U6.js"),[]).then(e=>({default:e.LogoutPage}))),ITe=g.lazy(()=>bn(()=>import("./not-found.page-BeS65EWV.js"),[]).then(e=>({default:e.NotFoundPage}))),MTe=Bhe([{Component:aTe,errorElement:j.jsx(lTe,{}),children:[{Component:P0e,children:[{Component:o_e,children:[{Component:Gke,children:[{path:"/",Component:xTe},{path:"/progress",Component:cTe},{path:"/practice",Component:uTe},{path:"/vocabulary",Component:dTe},{path:"/vocabulary/practice",Component:fTe},{path:"/exams/review",Component:hTe},{path:"/account",Component:pTe},{path:"/review-marked-questions",Component:gTe},{path:"/plans",Component:mTe},{path:"/assignments",Component:TTe},{path:"/assignments/:assignmentId/review",Component:OTe}]},{path:"/select-test",Component:CTe},{path:"/payment/success",Component:kTe},{path:"/exams/:examId/intro",Component:yTe},{path:"/exams/:examId",Component:vTe},{path:"/assignments/:assignmentId/intro",Component:PTe},{path:"/assignments/:assignmentId",Component:RTe},{path:"/diagnosis/:diagnosisId",Component:ETe}]}]},{Component:a_e,children:[{path:"/login",Component:_Te},{path:"/classlink-login",Component:wTe},{path:"/clever-login",Component:bTe},{path:"/signup",Component:STe}]},{path:"/logout",Component:ATe},{path:"*",Component:ITe}]}]),DTe=()=>j.jsx("div",{className:"h-screen flex items-center justify-center",children:j.jsx("div",{className:"animate-pulse",children:"Loading..."})}),LTe=()=>j.jsx(g.Suspense,{fallback:j.jsx(DTe,{}),children:j.jsx(tpe,{router:MTe})});function NTe(e){if(!(e.includes("Mobile")&&(e.includes("iPhone")||e.includes("iPad"))&&e.includes("LinkedInApp")))return!1;const n=e.match(/OS (\d+)_/i),r=n?parseInt(n[1]):null;return r!==null&&r>=17}const $Te=e=>g.createElement("svg",{width:97,height:25,viewBox:"0 0 97 25",fill:"none",xmlns:"http://www.w3.org/2000/svg",...e},g.createElement("g",{clipPath:"url(#clip0_1111_73)"},g.createElement("path",{fillRule:"evenodd",clipRule:"evenodd",d:"M64.9715 2.87407C64.5393 2.90524 64.1949 2.99875 63.9443 3.14838H63.9381C63.7126 3.28554 63.556 3.50374 63.4558 3.8217C63.3556 4.13342 63.293 4.58229 63.2805 5.14963H70.0382V7.97382H63.2742V20.2494H60.0363V7.97382H57.6501V5.14963H60.0425C60.0676 4.27057 60.1803 3.51621 60.387 2.899C60.625 2.17581 61.0321 1.58978 61.5957 1.15337C62.1406 0.729427 62.8671 0.42394 63.7439 0.249377C64.5832 0.0810474 65.6291 0 66.8441 0H70.0382V2.82419H66.8315C66.0925 2.82419 65.4662 2.84289 64.9715 2.87407ZM13.315 5.11832C14.4924 5.3677 15.4631 5.81034 16.2084 6.42131H16.2209C16.9725 7.03852 17.5299 7.88016 17.8681 8.91508C18.1938 9.91258 18.3629 11.1719 18.3629 12.662C18.3629 14.152 18.1938 15.4051 17.8681 16.4026C17.5299 17.4313 16.9725 18.2667 16.2147 18.8839C15.4631 19.4886 14.4924 19.9251 13.3212 20.1682C12.1876 20.4113 10.7973 20.5298 9.18143 20.5298C8.02905 20.5298 7.04578 20.4612 6.26291 20.3241C5.47379 20.1931 4.81618 20.0123 4.30262 19.8066C3.85795 19.6258 3.51349 19.4325 3.23793 19.2268V25.0123H0V5.15573H3.23793V5.91009C3.51349 5.71682 3.86422 5.54849 4.31515 5.3864C4.82244 5.2056 5.47379 5.04974 6.26291 4.93129C7.04578 4.81283 8.02279 4.75049 9.17517 4.75049C10.7847 4.75049 12.1814 4.87518 13.315 5.11832ZM7.07709 17.6433C7.68459 17.6807 8.3923 17.6994 9.17517 17.6994H9.18769C10.1021 17.6994 10.8975 17.6744 11.5551 17.6183C12.1939 17.5684 12.745 17.4687 13.1834 17.3315C13.5968 17.2068 13.9287 17.0261 14.1792 16.8078C14.4235 16.5959 14.6114 16.3153 14.7492 15.9724C14.8932 15.6046 14.9934 15.1557 15.0435 14.632C15.0999 14.0772 15.1249 13.4226 15.1249 12.6682C15.1249 11.9138 15.0936 11.253 15.0435 10.6981C14.9934 10.1682 14.8932 9.71308 14.7492 9.34525C14.6114 9.00236 14.4235 8.72181 14.1792 8.50361C13.9287 8.2854 13.5905 8.1046 13.1772 7.96745C12.7388 7.82405 12.1876 7.7243 11.5488 7.66819C10.8912 7.61832 10.0896 7.58715 9.18143 7.58715C8.39857 7.58715 7.69712 7.61208 7.08335 7.64949C6.49464 7.6869 5.96856 7.76794 5.52389 7.8864C5.10427 7.99862 4.74729 8.16071 4.46546 8.36645C4.18989 8.56595 3.96442 8.84026 3.78906 9.18316C3.60117 9.54475 3.46339 10.0061 3.37571 10.5547C3.28177 11.1283 3.23793 11.8141 3.23793 12.6308C3.23793 13.4475 3.28177 14.152 3.37571 14.7318C3.46339 15.2866 3.60117 15.7542 3.78906 16.1158C3.96442 16.4587 4.19615 16.733 4.46546 16.9325C4.74729 17.1383 5.10427 17.3004 5.52389 17.4126C5.96229 17.531 6.48838 17.6059 7.07709 17.6433ZM33.9387 15.6548C34.1016 15.2246 34.183 14.7321 34.183 14.1959L34.1767 14.2022V5.14979H37.4146V20.2495H34.1767V18.666C33.8761 18.959 33.4753 19.2396 32.9742 19.4889C32.398 19.782 31.6465 20.0313 30.7509 20.2246C29.8616 20.4179 28.7405 20.5176 27.4316 20.5176C26.3481 20.5176 25.3961 20.449 24.6132 20.3181C23.8116 20.181 23.1164 19.9815 22.5527 19.7134C21.9703 19.4391 21.4943 19.0899 21.1311 18.6722C20.7741 18.2608 20.4922 17.7807 20.3044 17.2446C20.1227 16.7271 19.9975 16.1411 19.9348 15.5052C19.8785 14.8879 19.8472 14.2084 19.8472 13.4852L19.8597 5.14355H23.0851V13.4104C23.0851 14.252 23.1477 14.9628 23.273 15.5301C23.3857 16.0538 23.6049 16.4528 23.9431 16.7645C24.2813 17.0762 24.7886 17.3131 25.4399 17.4565C26.1351 17.6124 27.0746 17.6934 28.2332 17.6934C29.4921 17.6934 30.5317 17.6061 31.3208 17.4254C32.0849 17.2446 32.6861 17.0014 33.112 16.6959C33.5191 16.4029 33.7884 16.06 33.9387 15.6548ZM56.0969 8.51607C55.8714 7.99238 55.5583 7.48116 55.1637 7.00735C
27554.7629 6.52106 54.2306 6.10336 53.5917 5.7667C52.9655 5.43627 52.2076 5.18066 51.3371 5.0061C50.4791 4.83777 49.4582 4.75049 48.2996 4.75049C46.6838 4.75049 45.2934 4.87518 44.1598 5.11832C42.9824 5.37393 42.0054 5.82904 41.2601 6.47742C40.5085 7.13203 39.9511 8.01109 39.6192 9.10211C39.2935 10.1557 39.1307 11.5024 39.1307 13.0921C39.1307 14.4949 39.2998 15.6794 39.6254 16.6208C39.9636 17.5934 40.521 18.3852 41.2851 18.9712C42.0304 19.5448 43.0012 19.9562 44.1723 20.1869C45.3059 20.4113 46.6963 20.5236 48.3058 20.5236C49.8089 20.5236 51.0991 20.4425 52.1325 20.2929C53.1909 20.1308 54.0677 19.8752 54.7253 19.5136C55.4205 19.1395 55.9341 18.6345 56.241 18.0173C56.5353 17.4188 56.6919 16.6956 56.6919 15.8664V15.4425H53.454V15.8664C53.454 16.2592 53.3851 16.5709 53.2535 16.8016C53.1345 17.0073 52.9091 17.1757 52.5771 17.3066C52.1951 17.4562 51.6628 17.556 50.9864 17.6121C50.2849 17.6682 49.3831 17.6994 48.3058 17.6994C47.1284 17.6994 46.1326 17.6557 45.3435 17.5747C44.5982 17.4999 44.0032 17.3191 43.5648 17.0385C43.1515 16.7767 42.8571 16.3652 42.6755 15.7792C42.5001 15.2368 42.4062 14.5448 42.3749 13.7156H56.266H56.6919V12.4999C56.6919 11.7517 56.648 11.0285 56.5729 10.3615C56.4915 9.66321 56.3349 9.046 56.1094 8.51607H56.0969ZM46.189 7.62455C46.8027 7.59338 47.5167 7.57468 48.2996 7.57468C49.2641 7.57468 50.097 7.63702 50.7672 7.76794C51.3997 7.8864 51.9195 8.1046 52.3078 8.41632C52.6961 8.72804 52.978 9.10834 53.1596 9.58839C53.3162 10.0061 53.4101 10.5797 53.4352 11.2904H42.3623C42.3749 10.7729 42.4187 10.3116 42.4939 9.92505C42.5753 9.47617 42.7005 9.12705 42.8696 8.89014C43.0387 8.65323 43.2705 8.44126 43.5523 8.26046C43.8404 8.07343 44.2036 7.93004 44.6233 7.83029C45.0617 7.7243 45.5877 7.65573 46.189 7.62455Z",fill:"#213860"})),g.createElement("path",{d:"M93.7621 5.12537V8.34856V20.6241H96.9937V8.34856L97 5.12537H93.7621Z",fill:"#00A75F"}),g.createElement("path",{d:"M93.7621 5.12537V8.34856V20.6241H96.9937V8.34856L97 5.12537H93.7621Z",fill:"url(#paint0_linear_1111_73)",fillOpacity:.2}),g.createElement("path",{d:"M93.7621 0.749146V3.57333H96.9937L97 0.749146H93.7621Z",fill:"#00A75F"}),g.createElement("path",{d:"M93.7621 0.749146V3.57333H96.9937L97 0.749146H93.7621Z",fill:"url(#paint1_linear_1111_73)",fillOpacity:.2}),g.createElement("path",{d:"M70.0507 17.8002L70.0444 20.6244H73.2824V17.8002H70.0507Z",fill:"#00A75F"}),g.createElement("path",{d:"M70.0507 17.8002L70.0444 20.6244H73.2824V17.8002H70.0507Z",fill:"url(#paint2_linear_1111_73)",fillOpacity:.2}),g.createElement("path",{d:"M88.138 5.12537V6.073C87.5368 5.77375 86.8291 5.53684 86.0212 5.38098C85.1631 5.21265 84.1423 5.12537 82.9836 5.12537C81.3678 5.12537 79.9774 5.25005 78.8439 5.4932C77.6664 5.74881 76.6894 6.20392 75.9441 6.8523C74.2406 8.44207 73.8711 10.6865 73.8147 13.0119C73.6644 15.3186 74.3847 17.7064 76.1821 19.2588C76.7583 19.7451 77.4097 20.1378 78.1048 20.3872C80.1152 21.1229 82.6454 21.0543 84.7122 20.5992C85.6078 20.4059 86.3594 20.1565 86.9355 19.8635C87.4366 19.6141 87.8374 19.3336 88.138 19.0406V20.6241H91.3759V5.12537H88.138ZM88.138 14.689C87.9814 18.2924 83.5223 18.1491 80.7603 18.0119C77.5975 17.8747 76.9587 16.0792 77.0777 13.2301C76.9525 10.1503 77.3721 8.11165 80.873 8.00566C86.8479 7.66901 88.5827 8.36726 88.1505 14.5767V14.6827L88.138 14.689Z",fill:"#00A75F"}),g.createElement("path",{d:"M88.138 5.12537V6.073C87.5368 5.77375 86.8291 5.53684 86.0212 5.38098C85.1631 5.21265 84.1423 5.12537 82.9836 5.12537C81.3678 5.12537 79.9774 5.25005 78.8439 5.4932C77.6664 5.74881 76.6894 6.20392 75.9441 6.8523C74.2406 8.44207 73.8711 10.6865 73.8147 13.0119C73.6644 15.3186 74.3847 17.7064 76.1821 19.2588C76.7583 19.7451 77.4097 20.1378 78.1048 20.3872C80.1152 21.1229 82.6454 21.0543 84.7122 20.5992C85.6078 20.4059 86.3594 20.1565 86.9355 19.8635C87.4366 19.6141 87.8374 19.3336 88.138 19.0406V20.6241H91.3759V5.12537H88.138ZM88.138 14.689C87.9814 18.2924 83.5223 18.1491 80.7603 18.0119C77.5975 17.8747 76.9587 16.0792 77.0777 13.2301C76.9525 10.1503 77.3721 8.11165 80.873 8.00566C86.8479 7.66901 88.5827 8.36726 88.1505 14.5767V14.6827L88.138 14.689Z",fill:"url(#paint3_linear_1111_73)",fillOpacity:.2}),g.createElement("defs",null,g.createElement("linearGradient",{id:"paint0_linear_1111_73",x1:94.4451,y1:17.4759,x2:97.6404,y2:17.0545,gradientUnits:"userSpaceOnUse"},g.createElement("stop",{stopColor:"white",stopOpacity:0}),g.createElement("stop",{offset:1,stopColor:"white"})),g.createElement("linearGradient",{id:"paint1_linear_1111_73",x1:94.4451,y1:2.99967,x2:96.5782,y2:1.45555,gradientUnits:"userSpaceOnUse"},g.createElement("stop",{stopColor:"white",stopOpacity:0}),g.createElement("stop",{offset:1,stopColor:"white"})),g.createElement("linearGradient",{id:"paint2_linear_1111_73",x1:70.7274,y1:20.0507,x2:72.8605,y2:18.5066,gradientUnits:"userSpaceOnUse"},g.createElement("stop",{stopColor:"white",stopOpacity:0}),g.createElement("stop",{offset:1,stopColor:"white"})),g.createElement("linearGradient",{id:"paint3_linear_1111_73",x1:77.5038,y1:17.7287,x2:89.3296,y2:9.42901,gradientUnits:"userSpaceOnUse"},g.createElement("stop",{stopColor:"white",stopOpacity:0}),g.createElement("stop",{offset:1,stopColor:"white"})),g.createElement("clipPath",{id:"clip0_1111_73"},g.createElement("rect",{width:97,height:25,fill:"white"})))),jTe=({currentUrl:e})=>{const t=`x-safari-${e}`;return j.jsxs("div",{className:"min-h-screen flex flex-col bg-background",children:[j.jsx("div",{className:"py-[45px] flex items-center justify-center",children:j.jsx($Te,{className:"w-[100px]"})}),j.jsx("div",{className:"flex-1 flex justify-center items-center",children:j.jsx("div",{children:j.jsxs("div",{className:"border border-brand-border w-[480px] shadow-[0px_2px_3px_0px_#30313D0D] rounded-[22px] bg-white p-[30px]",children:[j.jsxs("div",{className:"text-center mb-8",children:[j.jsx("div",{className:"mb-4",children:j.jsx("span",{className:"text-[22px] font-semibold text-navy-blue",children:"Open in Safari"})}),j.jsx("p",{className:"text-[15px] text-navy-blue font-normal mb-6",children:"Please open this page in Safari to continue."}),j.jsx("p",{className:"text-[13px] text-navy-blue/70 font-normal",children:"The LinkedIn app's browser has limitations. Click below to continue in Safari."})]}),j.jsx("a",{href:t,className:"block w-full bg-brand-green hover:bg-brand-green/90 text-white font-semibold py-3 px-4 roun
275ded-[10px] text-center transition-colors",children:"Open in Safari"}),j.jsx("div",{className:"mt-6 pt-6 border-t border-brand-border",children:j.jsx("p",{className:"text-[12px] text-navy-blue/60 text-center",children:"The LinkedIn app's browser has security limitations. Safari provides full access to all features."})})]})})})]})},FTe=({children:e})=>{const[t,n]=g.useState(!1);return g.useEffect(()=>{NTe(navigator.userAgent)&&n(!0)},[]),t?j.jsx(jTe,{currentUrl:window.location.href}):j.jsx(j.Fragment,{children:e})},UTe=hue({storage:window.localStorage});yue({queryClient:hT,persister:UTe,dehydrateOptions:{shouldDehydrateQuery:e=>e.queryKey[0]==="profile"}});const zTe="SohuOg2vcDazD1OS31zypVJGPWxCFy93",BTe="puef-prod.us.auth0.com",HTe="api.puef.ai/v1";function VTe(){return j.jsx(Fce,{children:j.jsx(b$,{children:j.jsx(FTe,{children:j.jsx(OZ,{domain:BTe,clientId:zTe,authorizationParams:{redirect_uri:window.location.origin,audience:HTe,scope:"openid profile email"},cacheLocation:"memory",children:j.jsxs(cX,{client:hT,children:[j.jsx(QG,{children:j.jsx(eY,{delayDuration:100,children:j.jsx(LTe,{})})}),j.jsx(yX,{initialIsOpen:!1,buttonPosition:"bottom-left"})]})})})})})}var fe=typeof window<"u"?window:void 0,xr=typeof globalThis<"u"?globalThis:fe;typeof self>"u"&&(xr.self=xr),typeof File>"u"&&(xr.File=function(){});var nH=Array.prototype,H8=nH.forEach,V8=nH.indexOf,ki=xr?.navigator,ke=xr?.document,Er=xr?.location,cC=xr?.fetch,uC=xr!=null&&xr.XMLHttpRequest&&"withCredentials"in new xr.XMLHttpRequest?xr.XMLHttpRequest:void 0,W8=xr?.AbortController,oi=ki?.userAgent,Xe=fe??{},Mo={DEBUG:!1,LIB_VERSION:"1.351.3"};function q8(e,t,n,r,i,s,o){try{var a=e[s](o),c=a.value}catch(d){return void n(d)}a.done?t(c):Promise.resolve(c).then(r,i)}function Rd(e){return function(){var t=this,n=arguments;return new Promise((function(r,i){var s=e.apply(t,n);function o(c){q8(s,r,i,o,a,"next",c)}function a(c){q8(s,r,i,o,a,"throw",c)}o(void 0)}))}}function Ie(){return Ie=Object.assign?Object.assign.bind():function(e){for(var t=1;t<arguments.length;t++){var n=arguments[t];for(var r in n)({}).hasOwnProperty.call(n,r)&&(e[r]=n[r])}return e},Ie.apply(null,arguments)}function rH(e,t){if(e==null)return{};var n={};for(var r in e)if({}.hasOwnProperty.call(e,r)){if(t.indexOf(r)!==-1)continue;n[r]=e[r]}return n}var WTe=["$snapshot","$pageview","$pageleave","$set","survey dismissed","survey sent","survey shown","$identify","$groupidentify","$create_alias","$$client_ingestion_warning","$web_experiment_applied","$feature_enrollment_update","$feature_flag_called"],qTe=["amazonbot","amazonproductbot","app.hypefactors.com","applebot","archive.org_bot","awariobot","backlinksextendedbot","baiduspider","bingbot","bingpreview","chrome-lighthouse","dataforseobot","deepscan","duckduckbot","facebookexternal","facebookcatalog","http://yandex.com/bots","hubspot","ia_archiver","leikibot","linkedinbot","meta-externalagent","mj12bot","msnbot","nessus","petalbot","pinterest","prerender","rogerbot","screaming frog","sebot-wa","sitebulb","slackbot","slurp","trendictionbot","turnitin","twitterbot","vercel-screenshot","vercelbot","yahoo! slurp","yandexbot","zoombot","bot.htm","bot.php","(bot;","bot/","crawler","ahrefsbot","ahrefssiteaudit","semrushbot","siteauditbot","splitsignalbot","gptbot","oai-searchbot","chatgpt-user","perplexitybot","better uptime bot","sentryuptimebot","uptimerobot","headlesschrome","cypress","google-hoteladsverifier","adsbot-google","apis-google","duplexweb-google","feedfetcher-google","google favicon","google web preview","google-read-aloud","googlebot","googleother","google-cloudvertexbot","googleweblight","mediapartners-google","storebot-google","google-inspectiontool","bytespider"],K8=function(e,t){if(t===void 0&&(t=[]),!e)return!1;var n=e.toLowerCase();return qTe.concat(t).some((r=>{var i=r.toLowerCase();return n.indexOf(i)!==-1}))};function Pt(e,t){return e.indexOf(t)!==-1}var T1=function(e){return e.trim()},dC=function(e){return e.replace(/^\$/,"")},KTe=Array.isArray,iH=Object.prototype,sH=iH.hasOwnProperty,R1=iH.toString,Gt=KTe||function(e){return R1.call(e)==="[object Array]"},Uo=e=>typeof e=="function",sr=e=>e===Object(e)&&!Gt(e),Pd=e=>{if(sr(e)){for(var t in e)if(sH.call(e,t))return!1;return!0}return!1},Te=e=>
vendor: 14,521 bytes, lines 275-276
275e===void 0,Zn=e=>R1.call(e)=="[object String]",fC=e=>Zn(e)&&e.trim().length===0,Ds=e=>e===null,At=e=>Te(e)||Ds(e),ca=e=>R1.call(e)=="[object Number]"&&e==e,fd=e=>ca(e)&&e>0,Go=e=>R1.call(e)==="[object Boolean]",GTe=e=>e instanceof FormData,YTe=e=>Pt(WTe,e);function hC(e){return e===null||typeof e!="object"}function s_(e,t){return Object.prototype.toString.call(e)==="[object "+t+"]"}function oH(e){return!Te(Event)&&(function(t,n){try{return t instanceof n}catch{return!1}})(e,Event)}var JTe=[!0,"true",1,"1","yes"],pE=e=>Pt(JTe,e),ZTe=[!1,"false",0,"0","no"];function Js(e,t,n,r,i){return t>n&&(r.warn("min cannot be greater than max."),t=n),ca(e)?e>n?(r.warn(" cannot be greater than max: "+n+". Using max value instead."),n):e<t?(r.warn(" cannot be less than min: "+t+". Using min value instead."),t):e:(r.warn(" must be a number. using max or fallback. max: "+n+", fallback: "+i),Js(i||n,t,n,r))}class XTe{constructor(t){this.t={},this.i=t.i,this.o=Js(t.bucketSize,0,100,t.h),this.m=Js(t.refillRate,0,this.o,t.h),this.$=Js(t.refillInterval,0,864e5,t.h)}S(t,n){var r=n-t.lastAccess,i=Math.floor(r/this.$);if(i>0){var s=i*this.m;t.tokens=Math.min(t.tokens+s,this.o),t.lastAccess=t.lastAccess+i*this.$}}consumeRateLimit(t){var n,r=Date.now(),i=String(t),s=this.t[i];return s?this.S(s,r):(s={tokens:this.o,lastAccess:r},this.t[i]=s),s.tokens===0||(s.tokens--,s.tokens===0&&((n=this.i)==null||n.call(this,t)),s.tokens===0)}stop(){this.t={}}}var es="Mobile",o_="iOS",zo="Android",um="Tablet",aH=zo+" "+um,lH="iPad",cH="Apple",uH=cH+" Watch",dm="Safari",uf="BlackBerry",dH="Samsung",fH=dH+"Browser",hH=dH+" Internet",cu="Chrome",QTe=cu+" OS",pH=cu+" "+o_,UR="Internet Explorer",mH=UR+" "+es,zR="Opera",eRe=zR+" Mini",BR="Edge",gH="Microsoft "+BR,zd="Firefox",yH=zd+" "+o_,fm="Nintendo",hm="PlayStation",Bd="Xbox",vH=zo+" "+es,_H=es+" "+dm,ip="Windows",pC=ip+" Phone",G8="Nokia",mC="Ouya",wH="Generic",tRe=wH+" "+es.toLowerCase(),bH=wH+" "+um.toLowerCase(),gC="Konqueror",Ur="(\\d+(\\.\\d+)?)",mE=new RegExp("Version/"+Ur),nRe=new RegExp(Bd,"i"),rRe=new RegExp(hm+" \\w+","i"),iRe=new RegExp(fm+" \\w+","i"),HR=new RegExp(uf+"|PlayBook|BB10","i"),sRe={"NT3.51":"NT 3.11","NT4.0":"NT 4.0","5.0":"2000",5.1:"XP",5.2:"XP","6.0":"Vista",6.1:"7",6.2:"8",6.3:"8.1",6.4:"10","10.0":"10"},cv,Y8,gE,oRe=(e,t)=>t&&Pt(t,cH)||(function(n){return Pt(n,dm)&&!Pt(n,cu)&&!Pt(n,zo)})(e),SH=function(e,t){return t=t||"",Pt(e," OPR/")&&Pt(e,"Mini")?eRe:Pt(e," OPR/")?zR:HR.test(e)?uf:Pt(e,"IE"+es)||Pt(e,"WPDesktop")?mH:Pt(e,fH)?hH:Pt(e,BR)||Pt(e,"Edg/")?gH:Pt(e,"FBIOS")?"Facebook "+es:Pt(e,"UCWEB")||Pt(e,"UCBrowser")?"UC Browser":Pt(e,"CriOS")?pH:Pt(e,"CrMo")||Pt(e,cu)?cu:Pt(e,zo)&&Pt(e,dm)?vH:Pt(e,"FxiOS")?yH:Pt(e.toLowerCase(),gC.toLowerCase())?gC:oRe(e,t)?Pt(e,es)?_H:dm:Pt(e,zd)?zd:Pt(e,"MSIE")||Pt(e,"Trident/")?UR:Pt(e,"Gecko")?zd:""},aRe={[mH]:[new RegExp("rv:"+Ur)],[gH]:[new RegExp(BR+"?\\/"+Ur)],[cu]:[new RegExp("("+cu+"|CrMo)\\/"+Ur)],[pH]:[new RegExp("CriOS\\/"+Ur)],"UC Browser":[new RegExp("(UCBrowser|UCWEB)\\/"+Ur)],[dm]:[mE],[_H]:[mE],[zR]:[new RegExp("(Opera|OPR)\\/"+Ur)],[zd]:[new RegExp(zd+"\\/"+Ur)],[yH]:[new RegExp("FxiOS\\/"+Ur)],[gC]:[new RegExp("Konqueror[:/]?"+Ur,"i")],[uf]:[new RegExp(uf+" "+Ur),mE],[vH]:[new RegExp("android\\s"+Ur,"i")],[hH]:[new RegExp(fH+"\\/"+Ur)],[UR]:[new RegExp("(rv:|MSIE )"+Ur)],Mozilla:[new RegExp("rv:"+Ur)]},lRe=function(e,t){var n=SH(e,t),r=aRe[n];if(Te(r))return null;for(var i=0;i<r.length;i++){var s=r[i],o=e.match(s);if(o)return parseFloat(o[o.length-2])}return null},J8=[[new RegExp(Bd+"; "+Bd+" (.*?)[);]","i"),e=>[Bd,e&&e[1]||""]],[new RegExp(fm,"i"),[fm,""]],[new RegExp(hm,"i"),[hm,""]],[HR,[uf,""]],[new RegExp(ip,"i"),(e,t)=>{if(/Phone/.test(t)||/WPDesktop/.test(t))return[pC,""];if(new RegExp(es).test(t)&&!/IEMobile\b/.test(t))return[ip+" "+es,""];var n=/Windows NT ([0-9.]+)/i.exec(t);if(n&&n[1]){var r=n[1],i=sRe[r]||"";return/arm/i.test(t)&&(i="RT"),[ip,i]}return[ip,""]}],[/((iPhone|iPad|iPod).*?OS (\d+)_(\d+)_?(\d+)?|iPhone)/,e=>{if(e&&e[3]){var t=[e[3],e[4],e[5]||"0"];return[o_,t.join(".")]}return[o_,""]}],[/(watch.*\/(\d+\.\d+\.\d+)|watch os,(\d+\.\d+),)/i,e=>{var t="";return e&&e.length>=3&&(t=Te(e[2])?e[3]:e[2]),["watchOS",t]}],[new RegExp("("+zo+" (\\d+)\\.(\\d+)\\.?(\\d+)?|"+zo+")","i"),e=>{if(e&&e[2]){var t=[e[2],e[3],e[4]||"0"];return[zo,t.join(".")]}return[zo,""]}],[/Mac OS X (\d+)[_.](\d+)[_.]?(\d+)?/i,e=>{var t=["Mac OS X",""];if(e&&e[1]){var n=[e[1],e[2],e[3]||"0"];t[1]=n.join(".")}return t}],[/Mac/i,["Mac OS X",""]],[/CrOS/,[QTe,""]],[/Linux|debian/i,["Linux",""]]],Z8=function(e){return iRe.test(e)?fm:rRe.test(e)?hm:nRe.test(e)?Bd:new RegExp(mC,"i").test(e)?mC:new RegExp("("+pC+"|WPDesktop)","i").test(e)?pC:/iPad/.test(e)?lH:/iPod/.test(e)?"iPod Touch":/iPhone/.test(e)?"iPhone":/(watch)(?: ?os[,/]|\d,\d\/)[\d.]+/i.test(e)?uH:HR.test(e)?uf:/(kobo)\s(ereader|touch)/i.test(e)?"Kobo":new RegExp(G8,"i").test(e)?G8:/(kf[a-z]{2}wi|aeo[c-r]{2})( bui|\))/i.test(e)||/(kf[a-z]+)( bui|\)).+silk\//i.test(e)?"Kindle Fire":/(Android|ZTE)/i.test(e)?new RegExp(es).test(e)&&!/(9138B|TB782B|Nexus [97]|pixel c|HUAWEISHT|BTV|noble nook|smart ultra 6)/i.test(e)||/pixel[\daxl ]{1,6}/i.test(e)&&!/pixel c/i.test(e)||/(huaweimed-al00|tah-|APA|SM-G92|i980|zte|U304AA)/i.test(e)||/lmy47v/i.test(e)&&!/QTAQZ3/i.test(e)?zo:aH:new RegExp("(pda|"+es+")","i").test(e)?tRe:new RegExp(um,"i").test(e)&&!new RegExp(um+" pc","i").test(e)?bH:""},cRe=e=>e instanceof Error;function uRe(e){var t=globalThis._posthogChunkIds;if(t){var n=Object.keys(t);return gE&&n.length===Y8||(Y8=n.length,gE=n.reduce(((r,i)=>{cv||(cv={});var s=cv[i];if(s)r[s[0]]=s[1];else for(var o=e(i),a=o.length-1;a>=0;a--){var c=o[a],d=c?.filename,f=t[i];if(d&&f){r[d]=f,cv[i]=[d,f];break}}return r}),{})),gE}}class dRe{constructor(t,n,r){r===void 0&&(r=[]),this.coercers=t,this.stackParser=n,this.modifiers=r}buildFromUnknown(t,n){n===void 0&&(n={});var r=n&&n.mechanism||{handled:!0,type:"generic"},i=this.buildCoercingContext(r,n,0).apply(t),s=this.buildParsingContext(n),o=this.parseStacktrace(i,s);return{$exception_list:this.convertToExceptionList(o,r),$exception_level:"error"}}modifyFrames(t){var n=this;return Rd((function*(){for(var r of t)r.stacktrace&&r.stacktrace.frames&&Gt(r.stacktrace.frames)&&(r.stacktrace.frames=yield n.applyModifiers(r.stacktrace.frames));return t}))()}coerceFallback(t){var n;return{type:"Error",value:"Unknown error",stack:(n=t.syntheticException)==null?void 0:n.stack,synthetic:!0}}parseStacktrace(t,n){var r,i;return t.cause!=null&&(r=this.parseStacktrace(t.cause,n)),t.stack!=""&&t.stack!=null&&(i=this.applyChunkIds(this.stackParser(t.stack,t.synthetic?n.skipFirstLines:0),n.chunkIdMap)),Ie({},t,{cause:r,stack:i})}applyChunkIds(t,n){return t.map((r=>(r.filename&&n&&(r.chunk_id=n[r.filename]),r)))}applyCoercers(t,n){for(var r of this.coercers)if(r.match(t))return r.coerce(t,n);return this.coerceFallback(n)}applyModifiers(t){var n=this;return Rd((function*(){var r=t;for(var i of n.modifiers)r=yield i(r);return r}))()}convertToExceptionList(t,n){var r,i,s,o={type:t.type,value:t.value,mechanism:{type:(r=n.type)!==null&&r!==void 0?r:"generic",handled:(i=n.handled)===null||i===void 0||i,synthetic:(s=t.synthetic)!==null&&s!==void 0&&s}};t.stack&&(o.stacktrace={type:"raw",frames:t.stack});var a=[o];return t.cause!=null&&a.push(...this.convertToExceptionList(t.cause,Ie({},n,{handled:!0}))),a}buildParsingContext(t){var n;return{chunkIdMap:uRe(this.stackParser),skipFirstLines:(n=t.skipFirstLines)!==null&&n!==void 0?n:1}}buildCoercingContext(t,n,r){r===void 0&&(r=0);var i=(s,o)=>{if(o<=4){var a=this.buildCoercingContext(t,n,o);return this.applyCoercers(s,a)}};return Ie({},n,{syntheticException:r==0?n.syntheticException:void 0,mechanism:t,apply:s=>i(s,r),next:s=>i(s,r+1)})}}var df="?";function yC(e,t,n,r,i){var s={platform:e,filename:t,function:n==="<anonymous>"?df:n,in_app:!0};return Te(r)||(s.lineno=r),Te(i)||(s.colno=i),s}var EH=(e,t)=>{var n=e.indexOf("safari-extension")!==-1,r=e.indexOf("safari-web-extension")!==-1;return n||r?[e.indexOf("@")!==-1?e.split("@")[0]:df,n?"safari-extension:"+t:"safari-web-extension:"+t]:[e,t]},fRe=/^\s*at (\S+?)(?::(\d+))(?::(\d+))\s*$/i,hRe=/^\s*at (?:(.+?\)(?: \[.+\])?|.*?) ?\((?:address at )?)?(?:async )?((?:<anonymous>|[-a-z]+:|.*bundle|\/)?.*?)(?::(\d+))?(?::(\d+))?\)?\s*$/i,pRe=/\((\S*)(?::(\d+))(?::(\d+))\)/,mRe=(e,t)=>{var n=fRe.exec(e);if(n){var[,r,i,s]=n;return yC(t,r,df,+i,+s)}var o=hRe.exec(e);if(o){if(o[2]&&o[2].indexOf("eval")===0){var a=pRe.exec(o[2]);a&&(o[2]=a[1],o[3]=a[2],o[4]=a[3])}var[c,d]=EH(o[1]||df,o[2]);return yC(t,d,c,o[3]?+o[3]:void 0,o[4]?+o[4]:void 0)}},gRe=/^\s*(.*?)(?:\((.*?)\))?(?:^|@)?((?:[-a-z]+)?:\/.*?|\[native code\]|[^@]*(?:bundle|\d+\.js)|\/[\w\-. /=]+)(?::(\d+))?(?::(\d+))?\s*$/i,yRe=/(\S+) line (\d+)(?: > eval line \d+)* > eval/i,vRe=(e,t)=>{var n=gRe.exec(e);if(n){if(n[3]&&n[3].indexOf(" > eval")>-1){var r=yRe.exec(n[3]);r&&(n[1]=n[1]||"eval",n[3]=r[1],n[4]=r[2],n[5]="")}var i=n[3],s=n[1]||df;return[s,i]=EH(s,i),yC(t,i,s,n[4]?+n[4]:void 0,n[5]?+n[5]:void 0)}},X8=/\(error: (.*)\)/,Q8=50;function _Re(){return(function(e){for(var t=arguments.length,n=new Array(t>1?t-1:0),r=1;r<t;r++)n[r-1]=arguments[r];return function(i,s){s===void 0&&(s=0);for(var o=[],a=i.split(` 276`),c=s;c<a.length;c++){var d=a[c];if(!(d.length>1024)){var f=X8.test(d)?d.replace(X8,"$1"):d;if(!f.match(/\S*Error: /)){for(var p of n){var m=p(f,e);if(m){o.push(m);break}}if(o.length>=Q8)break}}}return(function(v){if(!v.length)return[];var w=Array.from(v);return w.reverse(),w.slice(0,Q8).map((_=>{return Ie({},_,{filename:_.filename||(b=w,b[b.length-1]||{}).filename,function:_.function||df});var b}))})(o)}})("web:javascript",mRe,vRe)}class wRe{match(t){return this.isDOMException(t)||this.isDOMError(t)}coerce(t,n){var r=Zn(t.stack);return{type:this.getType(t),value:this.getValue(t),stack:r?t.stack:void 0,cause:t.cause?n.next(t.cause):void 0,synthetic:!1}}getType(t){return this.isDOMError(t)?"DOMError":"DOMException"}getValue(t){var n=t.name||(this.isDOMError(t)?"DOMError":"DOMException");return t.message?n+": "+t.message:n}isDOMException(t){return s_(t,"DOMException")}isDOMError(t){return s_(t,"DOMError")}}class bRe{match(t){return(n=>n instanceof Error)(t)}coerce(t,n){return{type:this.getType(t),value:this.getMessage(t,n),stack:this.getStack(t),cause:t.cause?n.next(t.cause):void 0,synthetic:!1}}getType(t){return t.name||t.constructor.name}getMessage(t,n){var r=t.message;return r.error&&typeof r.error.message=="string"?String(r.error.message):String(r)}getStack(t){return t.stacktrace||t.stack||void 0}}class SRe{constructor(){}match(t){return s_(t,"ErrorEvent")&&t.error!=null}coerce(t,n){var r,i=n.apply(t.error);return i||{type:"ErrorEvent",value:t.message,stack:(r=n.syntheticException)==null?void 0:r.stack,synthetic:!0}}}var ERe=/^(?:[Uu]ncaught (?:exception: )?)?(?:((?:Eval|Internal|Range|Reference|Syntax|Type|URI|)Error): )?(.*)$/i;class xRe{match(t){return typeof t=="string"}coerce(t,n){var r,[i,s]=this.getInfos(t);return{type:i??"Error",value:s??t,stack:(r=n.syntheticException)==null?void 0:r.stack,synthetic:!0}}getInfos(t){var n="Error",r=t,i=t.match(ERe);return i&&(n=i[1],r=i[2]),[n,r]}}var CRe=["fatal","error","warning","log","info","debug"];function xH(e,t){t===void 0&&(t=40);var n=Object.keys(e);if(n.sort(),!n.length)return"[object has no keys]";for(var r=n.length;r>0;r--){var i=n.slice(0,r).join(", ");if(!(i.length>t))return r===n.length||i.length<=t?i:i.slice(0,t)+"..."}return""}class kRe{match(t){return typeof t=="object"&&t!==null}coerce(t,n){var r,i=this.getErrorPropertyFromObject(t);return i?n.apply(i):{type:this.getType(t),value:this.getValue(t),stack:(r=n.syntheticException)==null?void 0:r.stack,level:this.isSeverityLevel(t.level)?t.level:"error",synthetic:!0}}getType(t){return oH(t)?t.constructor.name:"Error"}getValue(t){if("name"in t&&typeof t.name=="string"){var n="'"+t.name+"' captured as exception";return"message"in t&&typeof t.message=="string"&&(n+=" with message: '"+t.message+"'"),n}if("message"in t&&typeof t.message=="string")return t.message;var r=this.getObjectClassName(t);return(r&&r!=="Object"?"'"+r+"'":"Object")+" captured as exception with keys: "+xH(t)}isSeverityLevel(t){return Zn(t)&&!fC(t)&&CRe.indexOf(t)>=0}getErrorPropertyFromObject(t){for(var n in t)if(Object.prototype.hasOwnProperty.call(t,n)){var r=t[n];if(cRe(r))return r}}getObjectClassName(t){try{var n=Object.getPrototypeOf(t);return n?n.constructor.name:void 0}catch{return}}}class TRe{match(t){return oH(t)}coerce(t,n){var r,i=t.constructor.name;return{type:i,value:i+" captured as exception with keys: "+xH(t),stack:(r=n.syntheticException)==null?void 0:r.stack,synthetic:!0}}}class RRe{match(t){return hC(t)}coerce(t,n){var r;return{type:"Error",value:"Primitive value captured as exception: "+String(t),stack:(r=n.syntheticException)==null?void 0:r.stack,synthetic:!0}}}class PRe{match(t){return s_(t,"PromiseRejectionEvent")}coerce(t,n){var r,i=this.getUnhandledRejectionReason(t);return hC(i)?{type:"UnhandledRejection",value:"Non-Error promise rejection captured with value: "+String(i),stack:(r=n.syntheticException)==null?void 0:r.stack,synthetic:!0}:n.apply(i)}getUnhandledRejectionReason(t){if(hC(t))return t;try{if("reason"in t)return t.reason;if("detail"in t&&"reason"in t.detail)return t.detail.reason}catch{}return t}}var CH=function(e,t){var{debugEnabled:n}=t===void 0?{}:t,r={k:function(i){if(fe&&(Mo.DEBUG||Xe.POSTHOG_DEBUG||n)&&!Te(fe.console)&&fe.console){for(var s=("__rrweb_original__"in fe.console[i])?fe.console[i].__rrweb_original__:fe.console[i],o=arguments.length,a=new Array(o>1?o-1:0),c=1;c<o;c++)a[c-1]=arguments[c];s(e,...a)}},info:function(){for(var i=arguments.length,s=new Array(i),o=0;o<i;o++)s[o]=arguments[o];r.k("log",...s)},warn:function(){for(var i=arguments.length,s=new Array(i),o=0;o<i;o++)s[o]=arguments[o];r.k("warn",...s)},error:function(){for(var i=arguments.length,s=new Array(i),o=0;o<i;o++)s[o]=arguments[o];r.k("error",...s)},critical:function(){for(var i=arguments.length,s=new Array(i),o=0;o<i;o++)s[o]=arguments[o];console.error(e,...s)},uninitializedWarning:i=>{r.error("You must initialize PostHog before calling "+i)},createLogger:(i,s)=>CH(e+" "+i,s)};return r},Re=CH("[PostHog.js]"),Tn=Re.createLogger,ORe=Tn("[ExternalScriptsLoader]"),eD=(e,t,n)=>{if(e.config.disable_external_dependency_loading)return ORe.warn(t+" was requested but loading of external scripts is disabled."),n("Loading of external scripts is disabled");var r=ke?.querySelectorAll("script");
276if(r){for(var i,s=function(){if(r[o].src===t){var c=r[o];return c.__posthog_loading_callback_fired?{v:n()}:(c.addEventListener("load",(d=>{c.__posthog_loading_callback_fired=!0,n(void 0,d)})),c.onerror=d=>n(d),{v:void 0})}},o=0;o<r.length;o++)if(i=s())return i.v}var a=()=>{if(!ke)return n("document not found");var c=ke.createElement("script");if(c.type="text/javascript",c.crossOrigin="anonymous",c.src=t,c.onload=p=>{c.__posthog_loading_callback_fired=!0,n(void 0,p)},c.onerror=p=>n(p),e.config.prepare_external_dependency_script&&(c=e.config.prepare_external_dependency_script(c)),!c)return n("prepare_external_dependency_script returned null");if(e.config.external_scripts_inject_target==="head")ke.head.appendChild(c);else{var d,f=ke.querySelectorAll("body > script");f.length>0?(d=f[0].parentNode)==null||d.insertBefore(c,f[0]):ke.body.appendChild(c)}};ke!=null&&ke.body?a():ke?.addEventListener("DOMContentLoaded",a)};Xe.__PosthogExtensions__=Xe.__PosthogExtensions__||{},Xe.__PosthogExtensions__.loadExternalDependency=(e,t,n)=>{var r="/static/"+t+".js?v="+e.version;if(t==="remote-config"&&(r="/array/"+e.config.token+"/config.js"),t==="toolbar"){var i=3e5;r=r+"&t="+Math.floor(Date.now()/i)*i}var s=e.requestRouter.endpointFor("assets",r);eD(e,s,n)},Xe.__PosthogExtensions__.loadSiteApp=(e,t,n)=>{var r=e.requestRouter.endpointFor("api",t);eD(e,r,n)};var a_={};function ml(e,t,n){if(Gt(e)){if(H8&&e.forEach===H8)e.forEach(t,n);else if("length"in e&&e.length===+e.length){for(var r=0,i=e.length;r<i;r++)if(r in e&&t.call(n,e[r],r)===a_)return}}}function dn(e,t,n){if(!At(e)){if(Gt(e))return ml(e,t,n);if(GTe(e)){for(var r of e.entries())if(t.call(n,r[1],r[0])===a_)return}else for(var i in e)if(sH.call(e,i)&&t.call(n,e[i],i)===a_)return}}var jn=function(e){for(var t=arguments.length,n=new Array(t>1?t-1:0),r=1;r<t;r++)n[r-1]=arguments[r];return ml(n,(function(i){for(var s in i)i[s]!==void 0&&(e[s]=i[s])})),e},Lf=function(e){for(var t=arguments.length,n=new Array(t>1?t-1:0),r=1;r<t;r++)n[r-1]=arguments[r];return ml(n,(function(i){ml(i,(function(s){e.push(s)}))})),e};function Gv(e){for(var t=Object.keys(e),n=t.length,r=new Array(n);n--;)r[n]=[t[n],e[t[n]]];return r}var tD=function(e){try{return e()}catch{return}},ARe=function(e){return function(){try{for(var t=arguments.length,n=new Array(t),r=0;r<t;r++)n[r]=arguments[r];return e.apply(this,n)}catch(i){Re.critical("Implementation error. Please turn on debug mode and open a ticket on https://app.posthog.com/home#panel=support%3Asupport%3A."),Re.critical(i)}}},VR=function(e){var t={};return dn(e,(function(n,r){(Zn(n)&&n.length>0||ca(n))&&(t[r]=n)})),t};function IRe(e,t){return n=e,r=s=>Zn(s)&&!Ds(t)?s.slice(0,t):s,i=new Set,(function s(o,a){return o!==Object(o)?r?r(o,a):o:i.has(o)?void 0:(i.add(o),Gt(o)?(c=[],ml(o,(d=>{c.push(s(d))}))):(c={},dn(o,((d,f)=>{i.has(d)||(c[f]=s(d,f))}))),c);var c})(n);var n,r,i}var MRe=["herokuapp.com","vercel.app","netlify.app"];function DRe(e){var t=e?.hostname;if(!Zn(t))return!1;var n=t.split(".").slice(-2).join(".");for(var r of MRe)if(n===r)return!1;return!0}function kH(e,t){for(var n=0;n<e.length;n++)if(t(e[n]))return e[n]}function Xn(e,t,n,r){var{capture:i=!1,passive:s=!0}=r??{};e?.addEventListener(t,n,{capture:i,passive:s})}var TH="$people_distinct_id",sp="__alias",op="__timers",nD="$autocapture_disabled_server_side",vC="$heatmaps_enabled_server_side",rD="$exception_capture_enabled_server_side",_C="$error_tracking_suppression_rules",iD="$error_tracking_capture_extension_exceptions",sD="$web_vitals_enabled_server_side",RH="$dead_clicks_enabled_server_side",oD="$product_tours_enabled_server_side",aD="$web_vitals_allowed_metrics",uv="$session_recording_remote_config",l_="$sesid",PH="$session_is_sampled",Od="$enabled_feature_flags",ap="$early_access_features",wC="$feature_flag_details",lp="$stored_person_properties",xc="$stored_group_properties",bC="$surveys",c_="$flag_call_reported",SC="$feature_flag_errors",Do="$user_state",EC="$client_session_props",xC="$capture_rate_limit",CC="$initial_campaign_params",kC="$initial_referrer_info",u_="$initial_person_info",d_
276="$epp",OH="__POSTHOG_TOOLBAR__",Bh="$posthog_cookieless",LRe=[TH,sp,"__cmpns",op,"$session_recording_enabled_server_side",vC,l_,Od,_C,Do,ap,wC,xc,lp,bC,c_,SC,EC,xC,CC,kC,d_,u_,"$conversations_widget_session_id","$conversations_ticket_id","$conversations_widget_state","$conversations_user_traits"];function lD(e){return e instanceof Element&&(e.id===OH||!(e.closest==null||!e.closest(".toolbar-global-fade-container")))}function P1(e){return!!e&&e.nodeType===1}function gl(e,t){return!!e&&!!e.tagName&&e.tagName.toLowerCase()===t.toLowerCase()}function AH(e){return!!e&&e.nodeType===3}function IH(e){return!!e&&e.nodeType===11}function WR(e){return e?T1(e).split(/\s+/):[]}function cD(e){var t=fe?.location.href;return!!(t&&e&&e.some((n=>t.match(n))))}function f_(e){var t="";switch(typeof e.className){case"string":t=e.className;break;case"object":t=(e.className&&"baseVal"in e.className?e.className.baseVal:null)||e.getAttribute("class")||"";break;default:t=""}return WR(t)}function MH(e){return At(e)?null:T1(e).split(/(\s+)/).filter((t=>pm(t))).join("").replace(/[\r\n]/g," ").replace(/[ ]+/g," ").substring(0,255)}function lg(e){var t="";return TC(e)&&!jH(e)&&e.childNodes&&e.childNodes.length&&dn(e.childNodes,(function(n){var r;AH(n)&&n.textContent&&(t+=(r=MH(n.textContent))!==null&&r!==void 0?r:"")})),T1(t)}function DH(e){return Te(e.target)?e.srcElement||null:(t=e.target)!=null&&t.shadowRoot?e.composedPath()[0]||null:e.target||null;var t}var qR=["a","button","form","input","select","textarea","label"];function LH(e,t){if(Te(t))return!0;var n,r=function(s){if(t.some((o=>s.matches(o))))return{v:!0}};for(var i of e)if(n=r(i))return n.v;return!1}function NH(e){var t=e.parentNode;return!(!t||!P1(t))&&t}var NRe=["next","previous","prev",">","<"],uD=10,dD=[".ph-no-rageclick",".ph-no-capture"];function $Re(e,t){if(!fe||KR(e))return!1;var n,r,i;if(Go(t)?(n=!!t&&dD,r=void 0):(n=(i=t?.css_selector_ignorelist)!==null&&i!==void 0?i:dD,r=t?.content_ignorelist),n===!1)return!1;var{targetElementList:s}=$H(e,!1);return!(function(o,a){if(o===!1||Te(o))return!1;var c;if(o===!0)c=NRe;else{if(!Gt(o))return!1;if(o.length>uD)return Re.error("[PostHog] content_ignorelist array cannot exceed "+uD+" items. Use css_selector_ignorelist for more complex matching."),!1;c=o.map((d=>d.toLowerCase()))}return a.some((d=>{var{safeText:f,ariaLabel:p}=d;return c.some((m=>f.includes(m)||p.includes(m)))}))})(r,s.map((o=>{var a;return{safeText:lg(o).toLowerCase(),ariaLabel:((a=o.getAttribute("aria-label"))==null?void 0:a.toLowerCase().trim())||""}})))&&!LH(s,n)}var KR=e=>!e||gl(e,"html")||!P1(e),$H=(e,t)=>{if(!fe||KR(e))return{parentIsUsefulElement:!1,targetElementList:[]};for(var n=!1,r=[e],i=e;i.parentNode&&!gl(i,"body");)if(IH(i.parentNode))r.push(i.parentNode.host),i=i.parentNode.host;else{var s=NH(i);if(!s)break;if(t||qR.indexOf(s.tagName.toLowerCase())>-1)n=!0;else{var o=fe.getComputedStyle(s);o&&o.getPropertyValue("cursor")==="pointer"&&(n=!0)}r.push(s),i=s}return{parentIsUsefulElement:n,targetElementList:r}};function jRe(e,t,n,r,i){var s,o,a,c;if(n===void 0&&(n=void 0),!fe||KR(e)||(s=n)!=null&&s.url_allowlist&&!cD(n.url_allowlist)||(o=n)!=null&&o.url_ignorelist&&cD(n.url_ignorelist))return!1;if((a=n)!=null&&a.dom_event_allowlist){var d=n.dom_event_allowlist;if(d&&!d.some((w=>t.type===w)))return!1}var{parentIsUsefulElement:f,targetElementList:p}=$H(e,r);if(!(function(w,_){var b=_?.element_allowlist;if(Te(b))return!0;var C,P=function(F){if(b.some((R=>F.tagName.toLowerCase()===R)))return{v:!0}};for(var D of w)if(C=P(D))return C.v;return!1})(p,n)||!LH(p,(c=n)==null?void 0:c.css_selector_allowlist))return!1;var m=fe.getComputedStyle(e);if(m&&m.getPropertyValue("cursor")==="pointer"&&t.type==="click")return!0;var v=e.tagName.toLowerCase();switch(v){case"html":return!1;case"form":return(i||["submit"]).indexOf(t.type)>=0;case"input":case"select":case"textarea":return(i||["change","click"]).indexOf(t.type)>=0;default:return f?(i||["click"]).indexOf(t.type)>=0:(i||["click"]).indexOf(t.type)>=0&&(qR.indexOf(v)>-1||e.getAttribute("contenteditable")==="true")}}function TC(e){for(var t=e;t.parentNode&&!gl(t,"body");t=t.parentNode){var n=f_(t);if(Pt(n,"ph-sensitive")||Pt(n,"ph-no-capture"))return!1}if(Pt(f_(e),"ph-include"))return!0;var r=e.type||"";if(Zn(r))switch(r.toLowerCase()){case"hidden":case"password":return!1}
276var i=e.name||e.id||"";return!(Zn(i)&&/^cc|cardnum|ccnum|creditcard|csc|cvc|cvv|exp|pass|pwd|routing|seccode|securitycode|securitynum|socialsec|socsec|ssn/i.test(i.replace(/[^a-zA-Z0-9]/g,"")))}function jH(e){return!!(gl(e,"input")&&!["button","checkbox","submit","reset"].includes(e.type)||gl(e,"select")||gl(e,"textarea")||e.getAttribute("contenteditable")==="true")}var FH="(4[0-9]{12}(?:[0-9]{3})?)|(5[1-5][0-9]{14})|(6(?:011|5[0-9]{2})[0-9]{12})|(3[47][0-9]{13})|(3(?:0[0-5]|[68][0-9])[0-9]{11})|((?:2131|1800|35[0-9]{3})[0-9]{11})",FRe=new RegExp("^(?:"+FH+")$"),URe=new RegExp(FH),UH="\\d{3}-?\\d{2}-?\\d{4}",zRe=new RegExp("^("+UH+")$"),BRe=new RegExp("("+UH+")");function pm(e,t){return t===void 0&&(t=!0),!(At(e)||Zn(e)&&(e=T1(e),(t?FRe:URe).test((e||"").replace(/[- ]/g,""))||(t?zRe:BRe).test(e)))}function zH(e){var t=lg(e);return pm(t=(t+" "+BH(e)).trim())?t:""}function BH(e){var t="";return e&&e.childNodes&&e.childNodes.length&&dn(e.childNodes,(function(n){var r;if(n&&((r=n.tagName)==null?void 0:r.toLowerCase())==="span")try{var i=lg(n);t=(t+" "+i).trim(),n.childNodes&&n.childNodes.length&&(t=(t+" "+BH(n)).trim())}catch(s){Re.error("[AutoCapture]",s)}})),t}function HRe(e){return(function(t){var n=t.map((r=>{var i,s,o="";if(r.tag_name&&(o+=r.tag_name),r.attr_class)for(var a of(r.attr_class.sort(),r.attr_class))o+="."+a.replace(/"/g,"");var c=Ie({},r.text?{text:r.text}:{},{"nth-child":(i=r.nth_child)!==null&&i!==void 0?i:0,"nth-of-type":(s=r.nth_of_type)!==null&&s!==void 0?s:0},r.href?{href:r.href}:{},r.attr_id?{attr_id:r.attr_id}:{},r.attributes),d={};return Gv(c).sort(((f,p)=>{var[m]=f,[v]=p;return m.localeCompare(v)})).forEach((f=>{var[p,m]=f;return d[fD(p.toString())]=fD(m.toString())})),o+=":",o+=Gv(d).map((f=>{var[p,m]=f;return p+'="'+m+'"'})).join("")}));return n.join(";")})((function(t){return t.map((n=>{var r,i,s={text:(r=n.$el_text)==null?void 0:r.slice(0,400),tag_name:n.tag_name,href:(i=n.attr__href)==null?void 0:i.slice(0,2048),attr_class:VRe(n),attr_id:n.attr__id,nth_child:n.nth_child,nth_of_type:n.nth_of_type,attributes:{}};return Gv(n).filter((o=>{var[a]=o;return a.indexOf("attr__")===0})).forEach((o=>{var[a,c]=o;return s.attributes[a]=c})),s}))})(e))}function fD(e){return e.replace(/"|\\"/g,'\\"')}function VRe(e){var t=e.attr__class;return t?Gt(t)?t:WR(t):void 0}class HH{constructor(t){this.disabled=t===!1;var n=sr(t)?t:{};this.thresholdPx=n.threshold_px||30,this.timeoutMs=n.timeout_ms||1e3,this.clickCount=n.click_count||3,this.clicks=[]}isRageClick(t,n,r){if(this.disabled)return!1;var i=this.clicks[this.clicks.length-1];if(i&&Math.abs(t-i.x)+Math.abs(n-i.y)<this.thresholdPx&&r-i.timestamp<this.timeoutMs){if(this.clicks.push({x:t,y:n,timestamp:r}),this.clicks.length===this.clickCount)return!0}else this.clicks=[{x:t,y:n,timestamp:r}];return!1}}var h_=e=>{var t=ke?.createElement("a");return Te(t)?null:(t.href=e,t)},WRe=function(e,t){var n,r;t===void 0&&(t="&");var i=[];return dn(e,(function(s,o){Te(s)||Te(o)||o==="undefined"||(n=encodeURIComponent((a=>a instanceof File)(s)?s.name:s.toString()),r=encodeURIComponent(o),i[i.length]=r+"="+n)})),i.join(t)},p_=function(e,t){for(var n,r=((e.split("#")[0]||"").split(/\?(.*)/)[1]||"").replace(/^\?+/g,"").split("&"),i=0;i<r.length;i++){var s=r[i].split("=");if(s[0]===t){n=s;break}}if(!Gt(n)||n.length<2)return"";var o=n[1];try{o=decodeURIComponent(o)}catch{Re.error("Skipping decoding for malformed query param: "+o)}return o.replace(/\+/g," ")},cg=function(e,t,n){if(!e||!t||!t.length)return e;for(var r=e.split("#"),i=r[0]||"",s=r[1],o=i.split("?"),a=o[1],c=o[0],d=(a||"").split("&"),f=[],p=0;p<d.length;p++){var m=d[p].split("=");Gt(m)&&(t.includes(m[0])?f.push(m[0]+"="+n):f.push(d[p]))}var v=c;return a!=null&&(v+="?"+f.join("&")),s!=null&&(v+="#"+s),v},m_=function(e,t){var n=e.match(new RegExp(t+"=([^&]*)"));return n?n[1]:null},yE="$copy_autocapture",hD=Tn("[AutoCapture]");function vE(e,t){return t.length>e?t.slice(0,e)+"...":t}function qRe(e){if(e.previousElementSibling)return e.previousElementSibling;var t=e;do t=t.previousSibling;while(t&&!P1(t));return t}function KRe(e,t,n,r){var i=e.tagName.toLowerCase(),s={tag_name:i};qR.indexOf(i)>-1&&!n&&(i.toLowerCase()==="a"||i.toLowerCase()==="button"?s.$el_text=vE(1024,zH(e)):s.$el_text=vE(1024,lg(e)));var o=f_(e);o.length>0&&(s.classes=o.filter((function(f){return f!==""}))),dn(e.attributes,(function(f){var p;if((!jH(e)||["name","id","class","aria-label"].indexOf(f.name)!==-1)&&(r==null||!r.includes(f.name))&&
vendor: 9,911 bytes, line 276
276!t&&pm(f.value)&&(p=f.name,!Zn(p)||p.substring(0,10)!=="_ngcontent"&&p.substring(0,7)!=="_nghost")){var m=f.value;f.name==="class"&&(m=WR(m).join(" ")),s["attr__"+f.name]=vE(1024,m)}}));for(var a=1,c=1,d=e;d=qRe(d);)a++,d.tagName===e.tagName&&c++;return s.nth_child=a,s.nth_of_type=c,s}function GRe(e,t){for(var n,r,{e:i,maskAllElementAttributes:s,maskAllText:o,elementAttributeIgnoreList:a,elementsChainAsString:c}=t,d=[e],f=e;f.parentNode&&!gl(f,"body");)IH(f.parentNode)?(d.push(f.parentNode.host),f=f.parentNode.host):(d.push(f.parentNode),f=f.parentNode);var p,m=[],v={},w=!1,_=!1;if(dn(d,(F=>{var R=TC(F);F.tagName.toLowerCase()==="a"&&(w=F.getAttribute("href"),w=R&&w&&pm(w)&&w),Pt(f_(F),"ph-no-capture")&&(_=!0),m.push(KRe(F,s,o,a));var I=(function(k){if(!TC(k))return{};var L={};return dn(k.attributes,(function(B){if(B.name&&B.name.indexOf("data-ph-capture-attribute")===0){var A=B.name.replace("data-ph-capture-attribute-",""),V=B.value;A&&V&&pm(V)&&(L[A]=V)}})),L})(F);jn(v,I)})),_)return{props:{},explicitNoCapture:_};if(o||(e.tagName.toLowerCase()==="a"||e.tagName.toLowerCase()==="button"?m[0].$el_text=zH(e):m[0].$el_text=lg(e)),w){var b,C;m[0].attr__href=w;var P=(b=h_(w))==null?void 0:b.host,D=fe==null||(C=fe.location)==null?void 0:C.host;P&&D&&P!==D&&(p=w)}return{props:jn({$event_type:i.type,$ce_version:1},c?{}:{$elements:m},{$elements_chain:HRe(m)},(n=m[0])!=null&&n.$el_text?{$el_text:(r=m[0])==null?void 0:r.$el_text}:{},p&&i.type==="click"?{$external_click_url:p}:{},v)}}class YRe{constructor(t){this.P=!1,this.T=null,this.I=!1,this.instance=t,this.rageclicks=new HH(t.config.rageclick),this.C=null}get R(){var t,n,r=sr(this.instance.config.autocapture)?this.instance.config.autocapture:{};return r.url_allowlist=(t=r.url_allowlist)==null?void 0:t.map((i=>new RegExp(i))),r.url_ignorelist=(n=r.url_ignorelist)==null?void 0:n.map((i=>new RegExp(i))),r}F(){if(this.isBrowserSupported()){if(fe&&ke){var t=r=>{r=r||fe?.event;try{this.O(r)}catch(i){hD.error("Failed to capture event",i)}};if(Xn(ke,"submit",t,{capture:!0}),Xn(ke,"change",t,{capture:!0}),Xn(ke,"click",t,{capture:!0}),this.R.capture_copied_text){var n=r=>{r=r||fe?.event,this.O(r,yE)};Xn(ke,"copy",n,{capture:!0}),Xn(ke,"cut",n,{capture:!0})}}}else hD.info("Disabling Automatic Event Collection because this browser is not supported")}startIfEnabled(){this.isEnabled&&!this.P&&(this.F(),this.P=!0)}onRemoteConfig(t){t.elementsChainAsString&&(this.I=t.elementsChainAsString),this.instance.persistence&&this.instance.persistence.register({[nD]:!!t.autocapture_opt_out}),this.T=!!t.autocapture_opt_out,this.startIfEnabled()}setElementSelectors(t){this.C=t}getElementSelectors(t){var n,r=[];return(n=this.C)==null||n.forEach((i=>{var s=ke?.querySelectorAll(i);s?.forEach((o=>{t===o&&r.push(i)}))})),r}get isEnabled(){var t,n,r=(t=this.instance.persistence)==null?void 0:t.props[nD],i=this.T;if(Ds(i)&&!Go(r)&&!this.instance.M())return!1;var s=(n=this.T)!==null&&n!==void 0?n:!!r;return!!this.instance.config.autocapture&&!s}O(t,n){if(n===void 0&&(n="$autocapture"),this.isEnabled){var r,i=DH(t);AH(i)&&(i=i.parentNode||null),n==="$autocapture"&&t.type==="click"&&t instanceof MouseEvent&&this.instance.config.rageclick&&(r=this.rageclicks)!=null&&r.isRageClick(t.clientX,t.clientY,t.timeStamp||new Date().getTime())&&$Re(i,this.instance.config.rageclick)&&this.O(t,"$rageclick");var s=n===yE;if(i&&jRe(i,t,this.R,s,s?["copy","cut"]:void 0)){var{props:o,explicitNoCapture:a}=GRe(i,{e:t,maskAllElementAttributes:this.instance.config.mask_all_element_attributes,maskAllText:this.instance.config.mask_all_text,elementAttributeIgnoreList:this.R.element_attribute_ignorelist,elementsChainAsString:this.I});if(a)return!1;var c=this.getElementSelectors(i);if(c&&c.length>0&&(o.$element_selectors=c),n===yE){var d,f=MH(fe==null||(d=fe.getSelection())==null?void 0:d.toString()),p=t.type||"clipboard";if(!f)return!1;o.$selected_content=f,o.$copy_type=p}return this.instance.capture(n,o),!0}}}isBrowserSupported(){return Uo(ke?.querySelectorAll)}}Math.trunc||(Math.trunc=function(e){return e<0?Math.ceil(e):Math.floor(e)}),Number.isInteger||(Number.isInteger=function(e){return ca(e)&&isFinite(e)&&Math.floor(e)===e});var pD="0123456789abcdef";class g_{constructor(t){if(this.bytes=t,t.length!==16)throw new TypeError("not 128-bit length")}static fromFieldsV7(t,n,r,i){if(!Number.isInteger(t)||!Number.isInteger(n)||!Number.isInteger(r)||!Number.isInteger(i)||t<0||n<0||r<0||i<0||t>0xffffffffffff||n>4095||r>1073741823||i>4294967295)throw new RangeError("invalid field value");var s=new Uint8Array(16);return s[0]=t/Math.pow(2,40),s[1]=t/Math.pow(2,32),s[2]=t/Math.pow(2,24),s[3]=t/Math.pow(2,16),s[4]=t/Math.pow(2,8),s[5]=t,s[6]=112|n>>>8,s[7]=n,s[8]=128|r>>>24,s[9]=r>>>16,s[10]=r>>>8,s[11]=r,s[12]=i>>>24,s[13]=i>>>16,s[14]=i>>>8,s[15]=i,new g_(s)}toString(){for(var t="",n=0;n<this.bytes.length;n++)t=t+pD.charAt(this.bytes[n]>>>4)+pD.charAt(15&this.bytes[n]),n!==3&&n!==5&&n!==7&&n!==9||(t+="-");if(t.length!==36)throw new Error("Invalid UUIDv7 was generated");return t}clone(){return new g_(this.bytes.slice(0))}equals(t){return this.compareTo(t)===0}compareTo(t){for(var n=0;n<16;n++){var r=this.bytes[n]-t.bytes[n];if(r!==0)return Math.sign(r)}return 0}}class JRe{constructor(){this.A=0,this.j=0,this.D=new ZRe}generate(){var t=this.generateOrAbort();if(Te(t)){this.A=0;var n=this.generateOrAbort();if(Te(n))throw new Error("Could not generate UUID after timestamp reset");return n}return t}generateOrAbort(){var t=Date.now();if(t>this.A)this.A=t,this.L();else{if(!(t+1e4>this.A))return;this.j++,this.j>4398046511103&&(this.A++,this.L())}return g_.fromFieldsV7(this.A,Math.trunc(this.j/Math.pow(2,30)),this.j&Math.pow(2,30)-1,this.D.nextUint32())}L(){this.j=1024*this.D.nextUint32()+(1023&this.D.nextUint32())}}var mD,VH=e=>{if(typeof UUIDV7_DENY_WEAK_RNG<"u"&&UUIDV7_DENY_WEAK_RNG)throw new Error("no cryptographically strong RNG available");for(var t=0;t<e.length;t++)e[t]=65536*Math.trunc(65536*Math.random())+Math.trunc(65536*Math.random());return e};fe&&!Te(fe.crypto)&&crypto.getRandomValues&&(VH=e=>crypto.getRandomValues(e));class ZRe{constructor(){this.N=new Uint32Array(8),this.U=1/0}nextUint32(){return this.U>=this.N.length&&(VH(this.N),this.U=0),this.N[this.U++]}}var ul=()=>XRe().toString(),XRe=()=>(mD||(mD=new JRe)).generate(),Hh="",QRe=/[a-z0-9][a-z0-9-]+\.[a-z]{2,}$/i;function ePe(e,t){if(t){var n=(function(i,s){if(s===void 0&&(s=ke),Hh)return Hh;if(!s||["localhost","127.0.0.1"].includes(i))return"";for(var o=i.split("."),a=Math.min(o.length,8),c="dmn_chk_"+ul();!Hh&&a--;){var d=o.slice(a).join("."),f=c+"=1;domain=."+d+";path=/";s.cookie=f+";max-age=3",s.cookie.includes(c)&&(s.cookie=f+";max-age=0",Hh=d)}return Hh})(e);if(!n){var r=(i=>{var s=i.match(QRe);return s?s[0]:""})(e);r!==n&&Re.info("Warning: cookie subdomain discovery mismatch",r,n),n=r}return n?"; domain=."+n:""}return""}var qs={H:()=>!!ke,B:function(e){Re.error("cookieStore error: "+e)},q:function(e){if(ke){try{for(var t=e+"=",n=ke.cookie.split(";").filter((s=>s.length)),r=0;r<n.length;r++){for(var i=n[r];i.charAt(0)==" ";)i=i.substring(1,i.length);if(i.indexOf(t)===0)return decodeURIComponent(i.substring(t.length,i.length))}}catch{}return null}},W:function(e){var t;try{t=JSON.parse(qs.q(e))||{}}catch{}return t},G:function(e,t,n,r,i){if(ke)try{var s="",o="",a=ePe(ke.location.hostname,r);if(n){var c=new Date;c.setTime(c.getTime()+24*n*60*60*1e3),s="; expires="+c.toUTCString()}i&&(o="; secure");var d=e+"="+encodeURIComponent(JSON.stringify(t))+s+"; SameSite=Lax; path=/"+a+o;return d.length>3686.4&&Re.warn("cookieStore warning: large cookie, len="+d.length),ke.cookie=d,d}catch{return}},V:function(e,t){if(ke!=null&&ke.cookie)try{qs.G(e,"",-1,t)}catch{return}}},_E=null,Cn={H:function(){if(!Ds(_E))return _E;var e=!0;if(Te(fe))e=!1;else try{var t="__mplssupport__";Cn.G(t,"xyz"),Cn.q(t)!=='"xyz"'&&(e=!1),Cn.V(t)}catch{e=!1}return e||Re.error("localStorage unsupported; falling back to cookie store"),_E=e,e},B:function(e){Re.error("localStorage error: "+e)},q:function(e){try{return fe?.localStorage.getItem(e)}catch(t){Cn.B(t)}return null},W:function(e){try{return JSON.parse(Cn.q(e))||{}}catch{}return null},G:function(e,t){try{fe?.localStorage.setItem(e,JSON.stringify(t))}catch(n){Cn.B(n)}},V:function(e){try{fe?.localStorage.removeItem(e)}catch(t){Cn.B(t)}}},tPe=["$device_id","distinct_id",l_,PH,d_,u_],dv={},nPe={H:function(){return!0},B:function(e){Re.error("memoryStorage error: "+e)},q:function(e){return dv[e]||null},W:function(e){return dv[e]||null},G:function(e,t){dv[e]=t},V:function(e){delete dv[e]}},_c=null,br={H:function(){if(!Ds(_c))return _c;if(_c=!0,Te(fe))_c=!1;else try{var e="__support__";br.G(e,"xyz"),br.q(e)!=='"xyz"'&&(_c=!1),br.V(e)}catch{_c=!1}return _c},B:function(e){Re.error("sessionStorage error: ",e)},q:function(e){try{return fe?.sessionStorage.getItem(e)}catch(t){br.B(t)}return null},W:function(e){try{return JSON.parse(br.q(e))||null}catch{}return null},G:function(e,t){try{fe?.sessionStorage.setItem(e,JSON.stringify(t))}catch(n){br.B(n)}},V:function(e){try{fe?.sessionStorage.removeItem(e)}catch(t){br.B(t)}}},Lo=(function(e){return e[e.PENDING=-1]="PENDING",e[e.DENIED=0]="DENIED",e[e.GRANTED=1]="GRANTED",e})({});class rPe{constructor(t){this._instance=t}get R(){return this._instance.config}get consent(){return this.J()?Lo.DENIED:this.K}isOptedOut(){return this.R.cookieless_mode==="always"||this.consent===Lo.DENIED||this.consent===Lo.PENDING&&(this.R.opt_out_capturing_by_default||this.R.cookieless_mode==="on_reject")}isOptedIn(){return!this.isOptedOut()}isExplicitlyOptedOut(){return this.consent===Lo.DENIED}optInOut(t){this.Y.G(this.X,t?1:0,this.R.cookie_expiration,this.R.cross_subdomain_cookie,this.R.secure_cookie)}reset(){this.Y.V(this.X,this.R.cross_subdomain_cookie)}get X(){var{token:t,opt_out_capturing_cookie_prefix:n,consent_persistence_name:r}=this._instance.config;
276return r||(n?n+t:"__ph_opt_in_out_"+t)}get K(){var t=this.Y.q(this.X);return pE(t)?Lo.GRANTED:Pt(ZTe,t)?Lo.DENIED:Lo.PENDING}get Y(){if(!this.Z){var t=this.R.opt_out_capturing_persistence_type;this.Z=t==="localStorage"?Cn:qs;var n=t==="localStorage"?qs:Cn;n.q(this.X)&&(this.Z.q(this.X)||this.optInOut(pE(n.q(this.X))),n.V(this.X,this.R.cross_subdomain_cookie))}return this.Z}J(){return!!this.R.respect_dnt&&!!kH([ki?.doNotTrack,ki?.msDoNotTrack,Xe.doNotTrack],(t=>pE(t)))}}var fv=Tn("[Dead Clicks]"),iPe=()=>!0,sPe=e=>{var t,n=!((t=e.instance.persistence)==null||!t.get_property(RH)),r=e.instance.config.capture_dead_clicks;return Go(r)?r:!!sr(r)||n};class WH{get lazyLoadedDeadClicksAutocapture(){return this.tt}constructor(t,n,r){this.instance=t,this.isEnabled=n,this.onCapture=r,this.startIfEnabledOrStop()}onRemoteConfig(t){"captureDeadClicks"in t&&(this.instance.persistence&&this.instance.persistence.register({[RH]:t.captureDeadClicks}),this.startIfEnabledOrStop())}startIfEnabledOrStop(){this.isEnabled(this)?this.it((()=>{this.et()})):this.stop()}it(t){var n,r;(n=Xe.__PosthogExtensions__)!=null&&n.initDeadClicksAutocapture&&t(),(r=Xe.__PosthogExtensions__)==null||r.loadExternalDependency==null||r.loadExternalDependency(this.instance,"dead-clicks-autocapture",(i=>{i?fv.error("failed to load script",i):t()}))}et(){var t;if(ke){if(!this.tt&&(t=Xe.__PosthogExtensions__)!=null&&t.initDeadClicksAutocapture){var n=sr(this.instance.config.capture_dead_clicks)?this.instance.config.capture_dead_clicks:{};n.__onCapture=this.onCapture,this.tt=Xe.__PosthogExtensions__.initDeadClicksAutocapture(this.instance,n),this.tt.start(ke),fv.info("starting...")}}else fv.error("`document` not found. Cannot start.")}stop(){this.tt&&(this.tt.stop(),this.tt=void 0,fv.info("stopping..."))}}var Vh=Tn("[ExceptionAutocapture]");class oPe{constructor(t){var n,r,i;this.rt=()=>{var s;if(fe&&this.isEnabled&&(s=Xe.__PosthogExtensions__)!=null&&s.errorWrappingFunctions){var o=Xe.__PosthogExtensions__.errorWrappingFunctions.wrapOnError,a=Xe.__PosthogExtensions__.errorWrappingFunctions.wrapUnhandledRejection,c=Xe.__PosthogExtensions__.errorWrappingFunctions.wrapConsoleError;try{!this.st&&this.R.capture_unhandled_errors&&(this.st=o(this.captureException.bind(this))),!this.nt&&this.R.capture_unhandled_rejections&&(this.nt=a(this.captureException.bind(this))),!this.ot&&this.R.capture_console_errors&&(this.ot=c(this.captureException.bind(this)))}catch(d){Vh.error("failed to start",d),this.ut()}}},this._instance=t,this.ht=!((n=this._instance.persistence)==null||!n.props[rD]),this.dt=new XTe({refillRate:(r=this._instance.config.error_tracking.__exceptionRateLimiterRefillRate)!==null&&r!==void 0?r:1,bucketSize:(i=this._instance.config.error_tracking.__exceptionRateLimiterBucketSize)!==null&&i!==void 0?i:10,refillInterval:1e4,h:Vh}),this.R=this.vt(),this.startIfEnabledOrStop()}vt(){var t=this._instance.config.capture_exceptions,n={capture_unhandled_errors:!1,capture_unhandled_rejections:!1,capture_console_errors:!1};return sr(t)?n=Ie({},n,t):(Te(t)?this.ht:t)&&(n=Ie({},n,{capture_unhandled_errors:!0,capture_unhandled_rejections:!0})),n}get isEnabled(){return this.R.capture_console_errors||this.R.capture_unhandled_errors||this.R.capture_unhandled_rejections}startIfEnabledOrStop(){this.isEnabled?(Vh.info("enabled"),this.ut(),this.it(this.rt)):this.ut()}it(t){var n,r;(n=Xe.__PosthogExtensions__)!=null&&n.errorWrappingFunctions&&t(),(r=Xe.__PosthogExtensions__)==null||r.loadExternalDependency==null||r.loadExternalDependency(this._instance,"exception-autocapture",(i=>{if(i)return Vh.error("failed to load script",i);t()}))}ut(){var t,n,r;(t=this.st)==null||t.call(this),this.st=void 0,(n=this.nt)==null||n.call(this),this.nt=void 0,(r=this.ot)==null||r.call(this),this.ot=void 0}onRemoteConfig(t){if("autocaptureExceptions"in t){var n=t.autocaptureExceptions;this.ht=!!n||!1,this._instance.persistence&&this._instance.persistence.register({[rD]:this.ht}),this.R=this.vt(),this.startIfEnabledOrStop()}}onConfigChange(){this.R=this.vt()}captureException(t){var n,r,i=(n=t==null||(r=t.$exception_list)==null||(r=r[0])==null?void 0:r.type)!==null&&n!==void 0?n:"Exception";this.dt.consumeRateLimit(i)?Vh.info("Skipping exception capture because of client rate limiting.",{exception:i}):this._instance.exceptions.sendExceptionEvent(t)}}function gD(e,t,n){try{if(!(t in e))return()=>{};var r=e[t],i=n(r);return Uo(i)&&(i.prototype=i.prototype||{},Object.defineProperties(i,{__posthog_wrapped__:{enumerable:!1,value:!0}})),e[t]=i,()=>{e[t]=r}}catch{return()=>{}}}class aPe{constructor(t){var n;this._instance=t,this.ct=(fe==null||(n=fe.location)==null?void 0:n.pathname)||""}get isEnabled(){return this._instance.config.capture_pageview==="history_change"}startIfEnabled(){this.isEnabled&&(Re.info("History API monitoring enabled, starting..."),this.monitorHistoryChanges())}stop(){this.ft&&this.ft(),this.ft=void 0,Re.info("History API monitoring stopped")}monitorHistoryChanges(){var t,n;if(fe&&fe.history){var r=this;(t=fe.history.pushState)!=null&&t.__posthog_wrapped__||gD(fe.history,"pushState",(i=>function(s,o,a){i.call(this,s,o,a),r._t("pushState")})),(n=fe.history.replaceState)!=null&&n.__posthog_wrapped__||gD(fe.history,"replaceState",(i=>function(s,o,a){i.call(this,s,o,a),r._t("replaceState")})),this.bt()}}_t(t){try{var n,r=fe==null||(n=fe.location)==null?void 0:n.pathname;if(!r)return;r!==this.ct&&this.isEnabled&&this._instance.capture("$pageview",{navigation_type:t}),this.ct=r}catch(i){Re.error("Error capturing "+t+" pageview",i)}}
276bt(){if(!this.ft){var t=()=>{this._t("popstate")};Xn(fe,"popstate",t),this.ft=()=>{fe&&fe.removeEventListener("popstate",t)}}}}var wE=Tn("[SegmentIntegration]");function lPe(e,t){var n=e.config.segment;if(!n)return t();(function(r,i){var s=r.config.segment;if(!s)return i();var o=c=>{var d=()=>c.anonymousId()||ul();r.config.get_device_id=d,c.id()&&(r.register({distinct_id:c.id(),$device_id:d()}),r.persistence.set_property(Do,"identified")),i()},a=s.user();"then"in a&&Uo(a.then)?a.then(o):o(a)})(e,(()=>{n.register((r=>{Promise&&Promise.resolve||wE.warn("This browser does not have Promise support, and can not use the segment integration");var i=(s,o)=>{if(!o)return s;s.event.userId||s.event.anonymousId===r.get_distinct_id()||(wE.info("No userId set, resetting PostHog"),r.reset()),s.event.userId&&s.event.userId!==r.get_distinct_id()&&(wE.info("UserId set, identifying with PostHog"),r.identify(s.event.userId));var a=r.calculateEventProperties(o,s.event.properties);return s.event.properties=Object.assign({},a,s.event.properties),s};return{name:"PostHog JS",type:"enrichment",version:"1.0.0",isLoaded:()=>!0,load:()=>Promise.resolve(),track:s=>i(s,s.event.event),page:s=>i(s,"$pageview"),identify:s=>i(s,"$identify"),screen:s=>i(s,"$screen")}})(e)).then((()=>{t()}))}))}var qH="posthog-js";function KH(e,t){var{organization:n,projectId:r,prefix:i,severityAllowList:s=["error"],sendExceptionsToPostHog:o=!0}=t===void 0?{}:t;return a=>{var c,d,f,p,m;if(!(s==="*"||s.includes(a.level))||!e.__loaded)return a;a.tags||(a.tags={});var v=e.requestRouter.endpointFor("ui","/project/"+e.config.token+"/person/"+e.get_distinct_id());a.tags["PostHog Person URL"]=v,e.sessionRecordingStarted()&&(a.tags["PostHog Recording URL"]=e.get_session_replay_url({withTimestamp:!0}));var w=((c=a.exception)==null?void 0:c.values)||[],_=w.map((C=>Ie({},C,{stacktrace:C.stacktrace?Ie({},C.stacktrace,{type:"raw",frames:(C.stacktrace.frames||[]).map((P=>Ie({},P,{platform:"web:javascript"})))}):void 0}))),b={$exception_message:((d=w[0])==null?void 0:d.value)||a.message,$exception_type:(f=w[0])==null?void 0:f.type,$exception_level:a.level,$exception_list:_,$sentry_event_id:a.event_id,$sentry_exception:a.exception,$sentry_exception_message:((p=w[0])==null?void 0:p.value)||a.message,$sentry_exception_type:(m=w[0])==null?void 0:m.type,$sentry_tags:a.tags};return n&&r&&(b.$sentry_url=(i||"https://sentry.io/organizations/")+n+"/issues/?project="+r+"&query="+a.event_id),o&&e.exceptions.sendExceptionEvent(b),a}}class cPe{constructor(t,n,r,i,s,o){this.name=qH,this.setupOnce=function(a){a(KH(t,{organization:n,projectId:r,prefix:i,severityAllowList:s,sendExceptionsToPostHog:o==null||o}))}}}var uPe=fe!=null&&fe.location?m_(fe.location.hash,"__posthog")||m_(location.hash,"state"):null,yD="_postHogToolbarParams",vD=Tn("[Toolbar]"),Xa=(function(e){return e[e.UNINITIALIZED=0]="UNINITIALIZED",e[e.LOADING=1]="LOADING",e[e.LOADED=2]="LOADED",e})(Xa||{});class dPe{constructor(t){this.instance=t}yt(t){Xe.ph_toolbar_state=t}wt(){var t;return(t=Xe.ph_toolbar_state)!==null&&t!==void 0?t:Xa.UNINITIALIZED}maybeLoadToolbar(t,n,r){if(t===void 0&&(t=void 0),n===void 0&&(n=void 0),r===void 0&&(r=void 0),this.instance.config.name&&this.instance.config.name==="ph_toolbar_internal"||!fe||!ke)return!1;t=t??fe.location,r=r??fe.history;try{if(!n){try{fe.localStorage.setItem("test","test"),fe.localStorage.removeItem("test")}catch{return!1}n=fe?.localStorage}var i,s=uPe||m_(t.hash,"__posthog")||m_(t.hash,"state"),o=s?tD((()=>JSON.parse(atob(decodeURIComponent(s)))))||tD((()=>JSON.parse(decodeURIComponent(s)))):null;return o&&o.action==="ph_authorize"?((i=o).source="url",i&&Object.keys(i).length>0&&(o.desiredHash?t.hash=o.desiredHash:r?r.replaceState(r.state,"",t.pathname+t.search):t.hash="")):((i=JSON.parse(n.getItem(yD)||"{}")).source="localstorage",delete i.userIntent),!(!i.token||this.instance.config.token!==i.token)&&(this.loadToolbar(i),!0)}catch{return!1}}xt(t){var n=Xe.ph_load_toolbar||Xe.ph_load_editor;!At(n)&&Uo(n)?n(t,this.instance):vD.warn("No toolbar load function found")}loadToolbar(t){var n=!(ke==null||!ke.getElementById(OH));if(!fe||n)return!1;var r=this.instance.requestRouter.region==="custom"&&this.instance.config.advanced_disable_toolbar_metrics,i=Ie({token:this.instance.config.token},t,{apiURL:this.instance.requestRouter.endpointFor("ui")},r?{instrument:!1}:{});if(fe.localStorage.setItem(yD,JSON.stringify(Ie({},i,{source:void 0}))),this.wt()===Xa.LOADED)this.xt(i);else if(this.wt()===Xa.UNINITIALIZED){var s;this.yt(Xa.LOADING),(s=Xe.__PosthogExtensions__)==null||s.loadExternalDependency==null||s.loadExternalDependency(this.instance,"toolbar",(o=>{if(o)return vD.error("[Toolbar] Failed to load",o),void this.yt(Xa.UNINITIALIZED);this.yt(Xa.LOADED),this.xt(i)})),Xn(fe,"turbolinks:load",(()=>{this.yt(Xa.UNINITIALIZED),this.loadToolbar(i)}))}return!0}$t(t){return this.loadToolbar(t)}maybeLoadEditor(t,n,r){return t===void 0&&(t=void 0),n===void 0&&(n=void 0),r===void 0&&(r=void 0),this.maybeLoadToolbar(t,n,r)}}var fPe=Tn("[TracingHeaders]");class hPe{constructor(t){this.Et=void 0,this.St=void 0,this.rt=()=>{var n,r;Te(this.Et)&&((n=Xe.__PosthogExtensions__)==null||(n=n.tracingHeadersPatchFns)==null||n._patchXHR(this._instance.config.__add_tracing_headers||[],this._instance.get_distinct_id(),this._instance.sessionManager)),Te(this.St)&&((r=Xe.__PosthogExtensions__)==null||(r=r.tracingHeadersPatchFns)==null||r._patchFetch(this._instance.config.__add_tracing_headers||[],this._instance.get_distinct_id(),this._instance.sessionManager))},this._instance=t}it(t){var n,r;(n=Xe.__PosthogExtensions__)!=null&&n.tracingHeadersPatchFns&&t(),(r=Xe.__PosthogExtensions__)==null||r.loadExternalDependency==null||r.loadExternalDependency(this._instance,"tracing-headers",(i=>{if(i)return fPe.error("failed to load script",i);t()}))}startIfEnabledOrStop(){var t,n;this._instance.config.__add_tracing_headers?this.it(this.rt):((t=this.Et)==null||t.call(this),(n=this.St)==null||n.call(this),this.Et=void 0,this.St=void 0)}}var hv="https?://(.*)",Nf=["gclid","gclsrc","dclid","gbraid","wbraid","fbclid","msclkid","twclid","li_fat_id","igshid","ttclid","rdt_cid","epik","qclid","sccid","irclid","_kx"],pPe=Lf(["utm_source","utm_medium","utm_campaign","utm_content","utm_term","gad_source","mc_cid"],Nf),ug="<masked>",mPe=["li_fat_id"];function GH(e,t,n){if(!ke)return{};var r,i=t?Lf([],Nf,n||[]):[],s=YH(cg(ke.URL,i,ug),e),o=(r={},dn(mPe,(function(a){var c=qs.q(a);r[a]=c||null})),r);return jn(o,s)}function YH(e,t){var n=pPe.concat(t||[]),r={};return dn(n,(function(i){var s=p_(e,i);r[i]=s||null})),r}function JH(e){var t=(function(s){return s?s.search(hv+"google.([^/?]*)")===0?"google":s.search(hv+"bing.com")===0?"bing":s.search(hv+"yahoo.com")===0?"yahoo":s.search(hv+"duckduckgo.com")===0?"duckduckgo":null:null})(e),n=t!="yahoo"?"q":"p",r={};if(!Ds(t)){r.$search_engine=t;var i=ke?p_(ke.referrer,n):"";i.length&&(r.ph_keyword=i)}return r}function _D(){return navigator.language||navigator.userLanguage}function ZH(){return ke?.referrer||"$direct"}function XH(e,t){var n=e?Lf([],Nf,t||[]):[],r=Er?.href.substring(0,1e3);return{r:ZH().substring(0,1e3),u:r?cg(r,n,ug):void 0}}function QH(e){var t,{r:n,u:r}=e,i={$referrer:n,$referring_domain:n==null?void 0:n=="$direct"?"$direct":(t=h_(n))==null?void 0:t.host};
vendor: 19,069 bytes, lines 276-278
276if(r){i.$current_url=r;var s=h_(r);i.$host=s?.host,i.$pathname=s?.pathname;var o=YH(r);jn(i,o)}if(n){var a=JH(n);jn(i,a)}return i}function eV(){try{return Intl.DateTimeFormat().resolvedOptions().timeZone}catch{return}}function gPe(){try{return new Date().getTimezoneOffset()}catch{return}}function yPe(e,t){if(!oi)return{};var n,r,i,s=e?Lf([],Nf,t||[]):[],[o,a]=(function(c){for(var d=0;d<J8.length;d++){var[f,p]=J8[d],m=f.exec(c),v=m&&(Uo(p)?p(m,c):p);if(v)return v}return["",""]})(oi);return jn(VR({$os:o,$os_version:a,$browser:SH(oi,navigator.vendor),$device:Z8(oi),$device_type:(r=oi,i=Z8(r),i===lH||i===aH||i==="Kobo"||i==="Kindle Fire"||i===bH?um:i===fm||i===Bd||i===hm||i===mC?"Console":i===uH?"Wearable":i?es:"Desktop"),$timezone:eV(),$timezone_offset:gPe()}),{$current_url:cg(Er?.href,s,ug),$host:Er?.host,$pathname:Er?.pathname,$raw_user_agent:oi.length>1e3?oi.substring(0,997)+"...":oi,$browser_version:lRe(oi,navigator.vendor),$browser_language:_D(),$browser_language_prefix:(n=_D(),typeof n=="string"?n.split("-")[0]:void 0),$screen_height:fe?.screen.height,$screen_width:fe?.screen.width,$viewport_height:fe?.innerHeight,$viewport_width:fe?.innerWidth,$lib:"web",$lib_version:Mo.LIB_VERSION,$insert_id:Math.random().toString(36).substring(2,10)+Math.random().toString(36).substring(2,10),$time:Date.now()/1e3})}var Va=Tn("[Web Vitals]"),wD=9e5;class vPe{constructor(t){var n;this.kt=!1,this.P=!1,this.N={url:void 0,metrics:[],firstMetricTimestamp:void 0},this.Pt=()=>{clearTimeout(this.Tt),this.N.metrics.length!==0&&(this._instance.capture("$web_vitals",this.N.metrics.reduce(((r,i)=>Ie({},r,{["$web_vitals_"+i.name+"_event"]:Ie({},i),["$web_vitals_"+i.name+"_value"]:i.value})),{})),this.N={url:void 0,metrics:[],firstMetricTimestamp:void 0})},this.It=r=>{var i,s=(i=this._instance.sessionManager)==null?void 0:i.checkAndGetSessionAndWindowId(!0);if(Te(s))Va.error("Could not read session ID. Dropping metrics!");else{this.N=this.N||{url:void 0,metrics:[],firstMetricTimestamp:void 0};var o=this.Ct();Te(o)||(At(r?.name)||At(r?.value)?Va.error("Invalid metric received",r):this.Rt&&r.value>=this.Rt?Va.error("Ignoring metric with value >= "+this.Rt,r):(this.N.url!==o&&(this.Pt(),this.Tt=setTimeout(this.Pt,this.flushToCaptureTimeoutMs)),Te(this.N.url)&&(this.N.url=o),this.N.firstMetricTimestamp=Te(this.N.firstMetricTimestamp)?Date.now():this.N.firstMetricTimestamp,r.attribution&&r.attribution.interactionTargetElement&&(r.attribution.interactionTargetElement=void 0),this.N.metrics.push(Ie({},r,{$current_url:o,$session_id:s.sessionId,$window_id:s.windowId,timestamp:Date.now()})),this.N.metrics.length===this.allowedMetrics.length&&this.Pt()))}},this.rt=()=>{if(!this.P){var r,i,s,o,a=Xe.__PosthogExtensions__;Te(a)||Te(a.postHogWebVitalsCallbacks)||({onLCP:r,onCLS:i,onFCP:s,onINP:o}=a.postHogWebVitalsCallbacks),r&&i&&s&&o?(this.allowedMetrics.indexOf("LCP")>-1&&r(this.It.bind(this)),this.allowedMetrics.indexOf("CLS")>-1&&i(this.It.bind(this)),this.allowedMetrics.indexOf("FCP")>-1&&s(this.It.bind(this)),this.allowedMetrics.indexOf("INP")>-1&&o(this.It.bind(this)),this.P=!0):Va.error("web vitals callbacks not loaded - not starting")}},this._instance=t,this.kt=!((n=this._instance.persistence)==null||!n.props[sD]),this.startIfEnabled()}get allowedMetrics(){var t,n,r=sr(this._instance.config.capture_performance)?(t=this._instance.config.capture_performance)==null?void 0:t.web_vitals_allowed_metrics:void 0;return At(r)?((n=this._instance.persistence)==null?void 0:n.props[aD])||["CLS","FCP","INP","LCP"]:r}get flushToCaptureTimeoutMs(){return(sr(this._instance.config.capture_performance)?this._instance.config.capture_performance.web_vitals_delayed_flush_ms:void 0)||5e3}get useAttribution(){var t=sr(this._instance.config.capture_performance)?this._instance.config.capture_performance.web_vitals_attribution:void 0;return t!=null&&t}get Rt(){var t=sr(this._instance.config.capture_performance)&&ca(this._instance.config.capture_performance.__web_vitals_max_value)?this._instance.config.capture_performance.__web_vitals_max_value:wD;return 0<t&&t<=6e4?wD:t}get isEnabled(){var t=Er?.protocol;if(t!=="http:"&&t!=="https:")return Va.info("Web Vitals are disabled on non-http/https protocols"),!1;var n=sr(this._instance.config.capture_performance)?this._instance.config.capture_performance.web_vitals:Go(this._instance.config.capture_performance)?this._instance.config.capture_performance:void 0;return Go(n)?n:this.kt}startIfEnabled(){this.isEnabled&&!this.P&&(Va.info("enabled, starting..."),this.it(this.rt))}onRemoteConfig(t){if("capturePerformance"in t){var n=sr(t.capturePerformance)&&!!t.capturePerformance.web_vitals,r=sr(t.capturePerformance)?t.capturePerformance.web_vitals_allowed_metrics:void 0;this._instance.persistence&&(this._instance.persistence.register({[sD]:n}),this._instance.persistence.register({[aD]:r})),this.kt=n,this.startIfEnabled()}}it(t){var n,r;if((n=Xe.__PosthogExtensions__)!=null&&n.postHogWebVitalsCallbacks)t();else{var i=this.useAttribution?"web-vitals-with-attribution":"web-vitals";(r=Xe.__PosthogExtensions__)==null||r.loadExternalDependency==null||r.loadExternalDependency(this._instance,i,(s=>{s?Va.error("failed to load script",s):t()}))}}Ct(){var t=fe?fe.location.href:void 0;if(t){var n=this._instance.config.mask_personal_data_properties,r=this._instance.config.custom_personal_data_properties,i=n?Lf([],Nf,r||[]):[];return cg(t,i,ug)}Va.error("Could not determine current URL")}}var _Pe=Tn("[Heatmaps]");function bD(e){return sr(e)&&"clientX"in e&&"clientY"in e&&ca(e.clientX)&&ca(e.clientY)}class wPe{constructor(t){var n;this.kt=!1,this.P=!1,this.Ft=null,this.instance=t,this.kt=!((n=this.instance.persistence)==null||!n.props[vC]),this.rageclicks=new HH(t.config.rageclick)}get flushIntervalMilliseconds(){var t=5e3;return sr(this.instance.config.capture_heatmaps)&&this.instance.config.capture_heatmaps.flush_interval_milliseconds&&(t=this.instance.config.capture_heatmaps.flush_interval_milliseconds),t}get isEnabled(){return At(this.instance.config.capture_heatmaps)?At(this.instance.config.enable_heatmaps)?this.kt:this.instance.config.enable_heatmaps:this.instance.config.capture_heatmaps!==!1}startIfEnabled(){if(this.isEnabled){if(this.P)return;_Pe.info("starting..."),this.Ot(),this.Mt()}else{var t;clearInterval((t=this.Ft)!==null&&t!==void 0?t:void 0),this.At(),this.getAndClearBuffer()}}onRemoteConfig(t){if("heatmaps"in t){var n=!!t.heatmaps;this.instance.persistence&&this.instance.persistence.register({[vC]:n}),this.kt=n,this.startIfEnabled()}}getAndClearBuffer(){var t=this.N;return this.N=void 0,t}jt(t){this.Dt(t.originalEvent,"deadclick")}Mt(){this.Ft&&clearInterval(this.Ft),this.Ft=(function(t){return t?.visibilityState==="visible"})(ke)?setInterval(this.Lt.bind(this),this.flushIntervalMilliseconds):null}Ot(){fe&&ke&&(this.Nt=this.Lt.bind(this),Xn(fe,"beforeunload",this.Nt),this.Ut=t=>this.Dt(t||fe?.event),Xn(ke,"click",this.Ut,{capture:!0}),this.zt=t=>this.Ht(t||fe?.event),Xn(ke,"mousemove",this.zt,{capture:!0}),this.Bt=new WH(this.instance,iPe,this.jt.bind(this)),this.Bt.startIfEnabledOrStop(),this.qt=this.Mt.bind(this),Xn(ke,"visibilitychange",this.qt),this.P=!0)}At(){var t;fe&&ke&&(this.Nt&&fe.removeEventListener("beforeunload",this.Nt),this.Ut&&ke.removeEventListener("click",this.Ut,{capture:!0}),this.zt&&ke.removeEventListener("mousemove",this.zt,{capture:!0}),this.qt&&ke.removeEventListener("visibilitychange",this.qt),clearTimeout(this.Wt),(t=this.Bt)==null||t.stop(),this.P=!1)}Gt(t,n){var r=this.instance.scrollManager.scrollY(),i=this.instance.scrollManager.scrollX(),s=this.instance.scrollManager.scrollElement(),o=(function(a,c,d){for(var f=a;f&&P1(f)&&!gl(f,"body");){if(f===d)return!1;if(Pt(c,fe?.getComputedStyle(f).position))return!0;f=NH(f)}return!1})(DH(t),["fixed","sticky"],s);return{x:t.clientX+(o?0:i),y:t.clientY+(o?0:r),target_fixed:o,type:n}}Dt(t,n){var r;if(n===void 0&&(n="click"),!lD(t.target)&&bD(t)){var i=this.Gt(t,n);(r=this.rageclicks)!=null&&r.isRageClick(t.clientX,t.clientY,new Date().getTime())&&this.Vt(Ie({},i,{type:"rageclick"})),this.Vt(i)}}Ht(t){!lD(t.target)&&bD(t)&&(clearTimeout(this.Wt),this.Wt=setTimeout((()=>{this.Vt(this.Gt(t,"mousemove"))}),500))}Vt(t){if(fe){var n=fe.location.href,r=this.instance.config.mask_personal_data_properties,i=this.instance.config.custom_personal_data_properties,s=r?Lf([],Nf,i||[]):[],o=cg(n,s,ug);this.N=this.N||{},this.N[o]||(this.N[o]=[]),this.N[o].push(t)}}Lt(){this.N&&!Pd(this.N)&&this.instance.capture("$$heatmap",{$heatmap_data:this.getAndClearBuffer()})}}class SD{constructor(t){this.Jt=(n,r,i)=>{i&&(i.noSessionId||i.activityTimeout||i.sessionPastMaximumLength)&&(Re.info("[PageViewManager] Session rotated, clearing pageview state",{sessionId:n,changeReason:i}),this.Kt=void 0,this._instance.scrollManager.resetContext())},this._instance=t,this.Yt()}Yt(){var t;this.Xt=(t=this._instance.sessionManager)==null?void 0:t.onSessionId(this.Jt)}destroy(){var t;(t=this.Xt)==null||t.call(this),this.Xt=void 0}doPageView(t,n){var r,i=this.Qt(t,n);return this.Kt={pathname:(r=fe?.location.pathname)!==null&&r!==void 0?r:"",pageViewId:n,timestamp:t},this._instance.scrollManager.resetContext(),i}doPageLeave(t){var n;return this.Qt(t,(n=this.Kt)==null?void 0:n.pageViewId)}doEvent(){var t;return{$pageview_id:(t=this.Kt)==null?void 0:t.pageViewId}}Qt(t,n){var r=this.Kt;if(!r)return{$pageview_id:n};var i={$pageview_id:n,$prev_pageview_id:r.pageViewId},s=this._instance.scrollManager.getContext();if(s&&!this._instance.config.disable_scroll_properties){var{maxScrollHeight:o,lastScrollY:a,maxScrollY:c,maxContentHeight:d,lastContentY:f,maxContentY:p}=s;if(!(Te(o)||Te(a)||Te(c)||Te(d)||Te(f)||Te(p))){o=Math.ceil(o),a=Math.ceil(a),c=Math.ceil(c),d=Math.ceil(d),f=Math.ceil(f),p=Math.ceil(p);var m=o<=1?1:Js(a/o,0,1,Re),v=o<=1?1:Js(c/o,0,1,Re),w=d<=1?1:Js(f/d,0,1,Re),_=d<=1?1:Js(p/d,0,1,Re);i=jn(i,{$prev_pageview_last_scroll:a,$prev_pageview_last_scroll_percentage:m,$prev_pageview_max_scroll:c,$prev_pageview_max_scroll_percentage:v,$prev_pageview_last_content:f,$prev_pageview_last_content_percentage:w,$prev_pageview_max_content:p,$prev_pageview_max_content_percentage:_})}}return r.pathname&&(i.$prev_pageview_pathname=r.pathname),r.timestamp&&(i.$prev_pageview_duration=(t.getTime()-r.timestamp.getTime())/1e3),i}}var $o=(function(e){return e.GZipJS="gzip-js",e.Base64="base64",e})({}),ts=Uint8Array,ui=Uint16Array,ff=Uint32Array,GR=new ts([0,0,0,0,0,0,0,0,1,1,1,1,2,2,2,2,3,3,3,3,4,4,4,4,5,5,5,5,0,0,0,0]),YR=new ts([0,0,0,0,1,1,2,2,3,3,4,4,5,5,6,6,7,7,8,8,9,9,10,10,11,11,12,12,13,13,0,0]),ED=new ts([16,17,18,0,8,7,9,6,10,5,11,4,12,3,13,2,14,1,15]),tV=function(e,t){for(var n=new ui(31),r=0;r<31;++r)n[r]=t+=1<<e[r-1];var i=new ff(n[30]);for(r=1;r<30;++r)for(var s=n[r];s<n[r+1];++s)i[s]=s-n[r]<<5|r;return[n,i]},nV=tV(GR,2),bPe=nV[0],RC=nV[1];bPe[28]=258,RC[258]=28;for(var xD=tV(YR,0)[1],rV=new ui(32768),gn=0;gn<32768;++gn){var wc=(43690&gn)>>>1|(21845&gn)<<1;wc=(61680&(wc=(52428&wc)>>>2|(13107&wc)<<2))>>>4|(3855&wc)<<4,rV[gn]=((65280&wc)>>>8|(255&wc)<<8)>>>1}var kp=function(e,t,n){for(var r=e.length,i=0,s=new ui(t);i<r;++i)++s[e[i]-1];var o,a=new ui(t);for(i=0;i<t;++i)a[i]=a[i-1]+s[i-1]<<1;for(o=new ui(r),i=0;i<r;++i)o[i]=rV[a[e[i]-1]++]>>>15-e[i];return o},uu=new ts(288);for(gn=0;gn<144;++gn)uu[gn]=8;for(gn=144;gn<256;++gn)uu[gn]=9;for(gn=256;gn<280;++gn)uu[gn]=7;for(gn=280;gn<288;++gn)uu[gn]=8;var y_=new ts(32);for(gn=0;gn<32;++gn)y_[gn]=5;var SPe=kp(uu,9),EPe=kp(y_,5),iV=function(e){return(e/8>>0)+(7&e&&1)},sV=function(e,t,n){(n==null||n>e.length)&&(n=e.length);var r=new(e instanceof ui?ui:e instanceof ff?ff:ts)(n-t);return r.set(e.subarray(t,n)),r},To=function(e,t,n){n<<=7&t;var r=t/8>>0;e[r]|=n,e[r+1]|=n>>>8},Wh=function(e,t,n){n<<=7&t;var r=t/8>>0;e[r]|=n,e[r+1]|=n>>>8,e[r+2]|=n>>>16},bE=function(e,t){for(var n=[],r=0;r<e.length;++r)e[r]&&n.push({s:r,f:e[r]});var i=n.length,s=n.slice();if(!i)return[new ts(0),0];if(i==1){var o=new ts(n[0].s+1);return o[n[0].s]=1,[o,1]}n.sort((function(R,I){return R.f-I.f})),n.push({s:-1,f:25001});var a=n[0],c=n[1],d=0,f=1,p=2;for(n[0]={s:-1,f:a.f+c.f,l:a,r:c};f!=i-1;)a=n[n[d].f<n[p].f?d++:p++],c=n[d!=f&&n[d].f<n[p].f?d++:p++],n[f++]={s:-1,f:a.f+c.f,l:a,r:c};var m=s[0].s;for(r=1;r<i;++r)s[r].s>m&&(m=s[r].s);var v=new ui(m+1),w=PC(n[f-1],v,0);if(w>t){r=0;var _=0,b=w-t,C=1<<b;for(s.sort((function(R,I){return v[I.s]-v[R.s]||R.f-I.f}));r<i;++r){var P=s[r].s;if(!(v[P]>t))break;_+=C-(1<<w-v[P]),v[P]=t}for(_>>>=b;_>0;){var D=s[r].s;v[D]<t?_-=1<<t-v[D]++-1:++r}for(;r>=0&&_;--r){var F=s[r].s;v[F]==t&&(--v[F],++_)}w=t}return[new ts(v),w]},PC=function(e,t,n){return e.s==-1?Math.max(PC(e.l,t,n+1),PC(e.r,t,n+1)):t[e.s]=n},CD=function(e){for(var t=e.length;t&&!e[--t];);for(var n=new ui(++t),r=0,i=e[0],s=1,o=function(c){n[r++]=c},a=1;a<=t;++a)if(e[a]==i&&a!=t)++s;else{if(!i&&s>2){for(;s>138;s-=138)o(32754);s>2&&(o(s>10?s-11<<5|28690:s-3<<5|12305),s=0)}else if(s>3){for(o(i),--s;s>6;s-=6)o(8304);s>2&&(o(s-3<<5|8208),s=0)}for(;s--;)o(i);s=1,i=e[a]}return[n.subarray(0,r),t]},qh=function(e,t){for(var n=0,r=0;r<t.length;++r)n+=e[r]*t[r];return n},OC=function(e,t,n){var r=n.length,i=iV(t+2);e[i]=255&r,e[i+1]=r>>>8,e[i+2]=255^e[i],e[i+3]=255^e[i+1];for(var s=0;s<r;++s)e[i+s+4]=n[s];return 8*(i+4+r)},kD=function(e,t,n,r,i,s,o,a,c,d,f){To(t,f++,n),++i[256];for(var p=bE(i,15),m=p[0],v=p[1],w=bE(s,15),_=w[0],b=w[1],C=CD(m),P=C[0],D=C[1],F=CD(_),R=F[0],I=F[1],k=new ui(19),L=0;L<P.length;++L)k[31&P[L]]++;for(L=0;L<R.length;++L)k[31&R[L]]++;for(var B=bE(k,7),A=B[0],V=B[1],K=19;K>4&&!A[ED[K-1]];--K);var W,U,q,z,x=d+5<<3,N=qh(i,uu)+qh(s,y_)+o,M=qh(i,m)+qh(s,_)+o+14+3*K+qh(k,A)+(2*k[16]+3*k[17]+7*k[18]);if(x<=N&&x<=M)return OC(t,f,e.subarray(c,c+d));if(To(t,f,1+(M<N)),f+=2,M<N){W=kp(m,v),U=m,q=kp(_,b),z=_;var E=kp(A,V);for(To(t,f,D-257),To(t,f+5,I-1),To(t,f+10,K-4),f+=14,L=0;L<K;++L)To(t,f+3*L,A[ED[L]]);f+=3*K;for(var O=[P,R],H=0;H<2;++H){var Z=O[H];for(L=0;L<Z.length;++L){var X=31&Z[L];To(t,f,E[X]),f+=A[X],X>15&&(To(t,f,Z[L]>>>5&127),f+=Z[L]>>>12)}}}else W=SPe,U=uu,q=EPe,z=y_;for(L=0;L<a;++L)if(r[L]>255){X=r[L]>>>18&31,Wh(t,f,W[X+257]),f+=U[X+257],X>7&&(To(t,f,r[L]>>>23&31),f+=GR[X]);var te=31&r[L];Wh(t,f,q[te]),f+=z[te],te>3&&(Wh(t,f,r[L]>>>5&8191),f+=YR[te])}else Wh(t,f,W[r[L]]),f+=U[r[L]];return Wh(t,f,W[256]),f+U[256]},xPe=new ff([65540,131080,131088,131104,262176,1048704,1048832,2114560,2117632]),CPe=(function(){for(var e=new ff(256),t=0;t<256;++t){for(var n=t,r=9;--r;)n=(1&n&&3988292384)^n>>>1;e[t]=n}return e})(),kPe=function(e,t,n,r,i){return(function(s,o,a,c,d,f){var p=s.length,m=new ts(c+p+5*(1+Math.floor(p/7e3))+d),v=m.subarray(c,m.length-d),w=0;if(!o||p<8)for(var _=0;_<=p;_+=65535){var b=_+65535;b<p?w=OC(v,w,s.subarray(_,b)):(v[_]=f,w=OC(v,w,s.subarray(_,p)))}else{for(var C=xPe[o-1],P=C>>>13,D=8191&C,F=(1<<a)-1,R=new ui(32768),I=new ui(F+1),k=Math.ceil(a/3),L=2*k,B=function(it){return(s[it]^s[it+1]<<k^s[it+2]<<L)&F},A=new ff(25e3),V=new ui(288),K=new ui(32),W=0,U=0,q=(_=0,0),z=0,x=0;_<p;++_){var N=B(_),M=32767&_,E=I[N];if(R[M]=E,I[N]=M,z<=_){var O=p-_;if((W>7e3||q>24576)&&O>423){w=kD(s,v,0,A,V,K,U,q,x,_-x,w),q=W=U=0,x=_;for(var H=0;H<286;++H)V[H]=0;for(H=0;H<30;++H)K[H]=0}var Z=2,X=0,te=D,oe=M-E&32767;if(O>2&&N==B(_-oe))for(var le=Math.min(P,O)-1,ye=Math.min(32767,_),xe=Math.min(258,O);oe<=ye&&--te&&M!=E;){if(s[_+Z]==s[_+Z-oe]){for(var be=0;be<xe&&s[_+be]==s[_+be-oe];++be);if(be>Z){if(Z=be,X=oe,be>le)break;var rt=Math.min(oe,be-2),Ue=0;for(H=0;H<rt;++H){var Ve=_-oe+H+32768&32767,Qe=Ve-R[Ve]+32768&32767;Qe>Ue&&(Ue=Qe,E=Ve)}}}oe+=(M=E)-(E=R[M])+32768&32767}if(X){A[q++]=268435456|RC[Z]<<18|xD[X];var ht=31&RC[Z],Rt=31&xD[X];U+=GR[ht]+YR[Rt],++V[257+ht],++K[Rt],z=_+Z,++W}else A[q++]=s[_],++V[s[_]]}}w=kD(s,v,f,A,V,K,U,q,x,_-x,w)}return sV(m,0,c+iV(w)+d)})(e,t.level==null?6:t.level,t.mem==null?Math.ceil(1.5*Math.max(8,Math.min(13,Math.log(e.length)))):12+t.mem,n,r,!0)},SE=function(e,t,n){for(;n;++t)e[t]=n,n>>>=8};function TPe(e,t){t===void 0&&(t={});var n=(function(){var a=4294967295;return{p:function(c){for(var d=a,f=0;f<c.length;++f)d=CPe[255&d^c[f]]^d>>>8;a=d},d:function(){return 4294967295^a}}})(),r=e.length;n.p(e);var i,s=kPe(e,t,10+((i=t).filename&&i.filename.length+1||0),8),o=s.length;return(function(a,c){var d=c.filename;if(a[0]=31,a[1]=139,a[2]=8,a[8]=c.level<2?4:c.level==9?2:0,a[9]=3,c.mtime!=0&&SE(a,4,Math.floor(new Date(c.mtime||Date.now())/1e3)),d){a[3]=8;for(var f=0;f<=d.length;++f)a[f+10]=d.charCodeAt(f)}})(s,t),SE(s,o-8,n.d()),SE(s,o-4,r),s}var RPe=function(e){var t,n,r,i,s="";for(t=n=0,r=(e=(e+"").replace(/\r\n/g,` 277`).replace(/\r/g,` 278`)).length,i=0;i<r;i++){var o=e.charCodeAt(i),a=null;o<128?n++:a=o>127&&o<2048?String.fromCharCode(o>>6|192,63&o|128):String.fromCharCode(o>>12|224,o>>6&63|128,63&o|128),Ds(a)||(n>t&&(s+=e.substring(t,n)),s+=a,t=n=i+1)}return n>t&&(s+=e.substring(t,e.length)),s},PPe=!!uC||!!cC,TD="text/plain",v_=function(e,t,n){var r;n===void 0&&(n=!0);var[i,s]=e.split("?"),o=Ie({},t),a=(r=s?.split("&").map((d=>{var f,[p,m]=d.split("="),v=n&&(f=o[p])!==null&&f!==void 0?f:m;return delete o[p],p+"="+v})))!==null&&r!==void 0?r:[],c=WRe(o);return c&&a.push(c),i+"?"+a.join("&")},cp=(e,t)=>JSON.stringify(e,((n,r)=>typeof r=="bigint"?r.toString():r),t),EE=e=>{var{data:t,compression:n}=e;if(t){if(n===$o.GZipJS){var r=TPe((function(c,d){var f=c.length;if(typeof TextEncoder<"u")return new TextEncoder().encode(c);for(var p=new ts(c.length+(c.length>>>1)),m=0,v=function(C){p[m++]=C},w=0;w<f;++w){if(m+5>p.length){var _=new ts(m+8+(f-w<<1));_.set(p),p=_}var b=c.charCodeAt(w);b<128||d?v(b):b<2048?(v(192|b>>>6),v(128|63&b)):b>55295&&b<57344?(v(240|(b=65536+(1047552&b)|1023&c.charCodeAt(++w))>>>18),v(128|b>>>12&63),v(128|b>>>6&63),v(128|63&b)):(v(224|b>>>12),v(128|b>>>6&63),v(128|63&b))}return sV(p,0,m)})(cp(t)),{mtime:0}),i=new Blob([r],{type:TD});return{contentType:TD,body:i,estimatedSize:i.size}}if(n===$o.Base64){var s=(function(c){var d,f,p,m,v,w="ABCDEFGHIJKLMNOPQRSTUVWXYZabcdefghijklmnopqrstuvwxyz0123456789+/=",_=0,b=0,C="",P=[];if(!c)return c;c=RPe(c);do d=(v=c.charCodeAt(_++)<<16|c.charCodeAt(_++)<<8|c.charCodeAt(_++))>>18&63,f=v>>12&63,p=v>>6&63,m=63&v,P[b++]=w.charAt(d)+w.charAt(f)+w.charAt(p)+w.charAt(m);while(_<c.length);switch(C=P.join(""),c.length%3){case 1:C=C.slice(0,-2)+"==";break;case 2:C=C.slice(0,-1)+"="}return C})(cp(t)),o=(c=>"data="+encodeURIComponent(typeof c=="string"?c:cp(c)))(s);return{contentType:"application/x-www-form-urlencoded",body:o,estimatedSize:new Blob([o]).size}}var a=cp(t);return{contentType:"application/json",body:a,estimatedSize:new Blob([a]).size}}},Yv=[];cC&&Yv.push({transport:"fetch",method:e=>{var t,n,{contentType:r,body:i,estimatedSize:s}=(t=EE(e))!==null&&t!==void 0?t:{},o=new Headers;dn(e.headers,(function(f,p){o.append(p,f)})),r&&o.append("Content-Type",r);var a=e.url,c=null;if(W8){var d=new W8;c={signal:d.signal,timeout:setTimeout((()=>d.abort()),e.timeout)}}cC(a,Ie({method:e?.method||"GET",headers:o,keepalive:e.method==="POST"&&(s||0)<52428.8,body:i,signal:(n=c)==null?void 0:n.signal},e.fetchOptions)).then((f=>f.text().then((p=>
278{var m={statusCode:f.status,text:p};if(f.status===200)try{m.json=JSON.parse(p)}catch(v){Re.error(v)}e.callback==null||e.callback(m)})))).catch((f=>{Re.error(f),e.callback==null||e.callback({statusCode:0,error:f})})).finally((()=>c?clearTimeout(c.timeout):null))}}),uC&&Yv.push({transport:"XHR",method:e=>{var t,n=new uC;n.open(e.method||"GET",e.url,!0);var{contentType:r,body:i}=(t=EE(e))!==null&&t!==void 0?t:{};dn(e.headers,(function(s,o){n.setRequestHeader(o,s)})),r&&n.setRequestHeader("Content-Type",r),e.timeout&&(n.timeout=e.timeout),e.disableXHRCredentials||(n.withCredentials=!0),n.onreadystatechange=()=>{if(n.readyState===4){var s={statusCode:n.status,text:n.responseText};if(n.status===200)try{s.json=JSON.parse(n.responseText)}catch{}e.callback==null||e.callback(s)}},n.send(i)}}),ki!=null&&ki.sendBeacon&&Yv.push({transport:"sendBeacon",method:e=>{var t=v_(e.url,{beacon:"1"});try{var n,{contentType:r,body:i}=(n=EE(e))!==null&&n!==void 0?n:{},s=typeof i=="string"?new Blob([i],{type:r}):i;ki.sendBeacon(t,s)}catch{}}});var __=function(e,t){if(!(function(n){try{new RegExp(n)}catch{return!1}return!0})(t))return!1;try{return new RegExp(t).test(e)}catch{return!1}};function RD(e,t,n){return cp({distinct_id:e,userPropertiesToSet:t,userPropertiesToSetOnce:n})}var oV={exact:(e,t)=>t.some((n=>e.some((r=>n===r)))),is_not:(e,t)=>t.every((n=>e.every((r=>n!==r)))),regex:(e,t)=>t.some((n=>e.some((r=>__(n,r))))),not_regex:(e,t)=>t.every((n=>e.every((r=>!__(n,r))))),icontains:(e,t)=>t.map(pv).some((n=>e.map(pv).some((r=>n.includes(r))))),not_icontains:(e,t)=>t.map(pv).every((n=>e.map(pv).every((r=>!n.includes(r))))),gt:(e,t)=>t.some((n=>{var r=parseFloat(n);return!isNaN(r)&&e.some((i=>r>parseFloat(i)))})),lt:(e,t)=>t.some((n=>{var r=parseFloat(n);return!isNaN(r)&&e.some((i=>r<parseFloat(i)))}))},pv=e=>e.toLowerCase();function aV(e,t){return!e||Object.entries(e).every((n=>{var[r,i]=n,s=t?.[r];if(Te(s)||Ds(s))return!1;var o=[String(s)],a=oV[i.operator];return!!a&&a(i.values,o)}))}var xE=Tn("[Error tracking]");class OPe{constructor(t){var n,r;this.Zt=[],this.ti=new dRe([new wRe,new PRe,new SRe,new bRe,new TRe,new kRe,new xRe,new RRe],_Re()),this._instance=t,this.Zt=(n=(r=this._instance.persistence)==null?void 0:r.get_property(_C))!==null&&n!==void 0?n:[]}onRemoteConfig(t){var n,r,i;if("errorTracking"in t){var s=(n=(r=t.errorTracking)==null?void 0:r.suppressionRules)!==null&&n!==void 0?n:[],o=(i=t.errorTracking)==null?void 0:i.captureExtensionExceptions;this.Zt=s,this._instance.persistence&&this._instance.persistence.register({[_C]:this.Zt,[iD]:o})}}get ii(){var t,n=!!this._instance.get_property(iD),r=this._instance.config.error_tracking.captureExtensionExceptions;return(t=r??n)!==null&&t!==void 0&&t}buildProperties(t,n){return this.ti.buildFromUnknown(t,{syntheticException:n?.syntheticException,mechanism:{handled:n?.handled}})}sendExceptionEvent(t){var n=t.$exception_list;if(this.ei(n)){if(this.ri(n))return void xE.info("Skipping exception capture because a suppression rule matched");if(!this.ii&&this.si(n))return void xE.info("Skipping exception capture because it was thrown by an extension");if(!this._instance.config.error_tracking.__capturePostHogExceptions&&this.ni(n))return void xE.info("Skipping exception capture because it was thrown by the PostHog SDK")}return this._instance.capture("$exception",t,{_noTruncate:!0,_batchKey:"exceptionEvent",oi:!0})}ri(t){if(t.length===0)return!1;var n=t.reduce(((r,i)=>{var{type:s,value:o}=i;return Zn(s)&&s.length>0&&r.$exception_types.push(s),Zn(o)&&o.length>0&&r.$exception_values.push(o),r}),{$exception_types:[],$exception_values:[]});return this.Zt.some((r=>{var i=r.values.map((s=>{var o,a=oV[s.operator],c=Gt(s.value)?s.value:[s.value],d=(o=n[s.key])!==null&&o!==void 0?o:[];return c.length>0&&a(c,d)}));return r.type==="OR"?i.some(Boolean):i.every(Boolean)}))}si(t){return t.flatMap((n=>{var r,i;return(r=(i=n.stacktrace)==null?void 0:i.frames)!==null&&r!==void 0?r:[]})).some((n=>n.filename&&n.filename.startsWith("chrome-extension://")))}ni(t){if(t.length>0){var n,r,i,s,o=(n=(r=t[0].stacktrace)==null?void 0:r.frames)!==null&&n!==void 0?n:[],a=o[o.length-1];return(i=a==null||(s=a.filename)==null?void 0:s.includes("posthog.com/static"))!==null&&i!==void 0&&i}return!1}ei(t){return!At(t)&&Gt(t)}}var wi=Tn("[FeatureFlags]"),Kh=Tn("[FeatureFlags]",{debugEnabled:!0}),APe="errors_while_computing_flags",IPe="flag_missing",MPe="quota_limited",DPe="timeout",LPe="connection_error",NPe="unknown_error",$Pe=e=>"api_error_"+e,CE="$active_feature_flags",id="$override_feature_flags",PD="$feature_flag_payloads",Gh="$override_feature_flag_payloads",OD="$feature_flag_request_id",AD="$feature_flag_evaluated_at",ID=e=>{var t={};for(var[n,r]of Gv(e||{}))r&&(t[n]=r);return t},jPe=e=>{var t=e.flags;return t?(e.featureFlags=Object.fromEntries(Object.keys(t).map((n=>{var r;return[n,(r=t[n].variant)!==null&&r!==void 0?r:t[n].enabled]}))),e.featureFlagPayloads=Object.fromEntries(Object.keys(t).filter((n=>t[n].enabled)).filter((n=>{var r;return(r=t[n].metadata)==null?void 0:r.payload})).map((n=>{var r;return[n,(r=t[n].metadata)==null?void 0:r.payload]})))):wi.warn("Using an older version of the feature flags endpoint. Please upgrade your PostHog server to the latest version"),e},FPe=(function(e){return e.FeatureFlags="feature_flags",e.Recordings="recordings",e})({});class UPe{constructor(t){this.ai=!1,this.li=!1,this.ui=!1,this.hi=!1,this.di=!1,this.vi=!1,this.ci=!1,this._instance=t,this.featureFlagEventHandlers=[]}fi(){var t,n=(t=this._instance.config.evaluation_contexts)!==null&&t!==void 0?t:this._instance.config.evaluation_environments;return!this._instance.config.evaluation_environments||this._instance.config.evaluation_contexts||this.ci||(wi.warn("evaluation_environments is deprecated. Use evaluation_contexts instead. evaluation_environments will be removed in a future version."),this.ci=!0),n!=null&&n.length?n.filter((r=>{var i=r&&typeof r=="string"&&r.trim().length>0;return i||wi.error("Invalid evaluation context found:",r,"Expected non-empty string"),i})):[]}pi(){return this.fi().length>0}get hasLoadedFlags(){return this.li}getFlags(){return Object.keys(this.getFlagVariants())}getFlagsWithDetails(){var t=this._instance.get_property(wC),n=this._instance.get_property(id),r=this._instance.get_property(Gh);if(!r&&!n)return t||{};var i=jn({},t||{}),s=[...new Set([...Object.keys(r||{}),...Object.keys(n||{})])];for(var o of s){var a,c,d=i[o],f=n?.[o],p=Te(f)?(a=d?.enabled)!==null&&a!==void 0&&a:!!f,m=Te(f)?d.variant:typeof f=="string"?f:void 0,v=r?.[o],w=Ie({},d,{enabled:p,variant:p?m??d?.variant:void 0});p!==d?.enabled&&(w.original_enabled=d?.enabled),m!==d?.variant&&(w.original_variant=d?.variant),v&&(w.metadata=Ie({},d?.metadata,{payload:v,original_payload:d==null||(c=d.metadata)==null?void 0:c.payload})),i[o]=w}return this.ai||(wi.warn(" Overriding feature flag details!",{flagDetails:t,overriddenPayloads:r,finalDetails:i}
278),this.ai=!0),i}getFlagVariants(){var t=this._instance.get_property(Od),n=this._instance.get_property(id);if(!n)return t||{};for(var r=jn({},t),i=Object.keys(n),s=0;s<i.length;s++)r[i[s]]=n[i[s]];return this.ai||(wi.warn(" Overriding feature flags!",{enabledFlags:t,overriddenFlags:n,finalFlags:r}),this.ai=!0),r}getFlagPayloads(){var t=this._instance.get_property(PD),n=this._instance.get_property(Gh);if(!n)return t||{};for(var r=jn({},t||{}),i=Object.keys(n),s=0;s<i.length;s++)r[i[s]]=n[i[s]];return this.ai||(wi.warn(" Overriding feature flag payloads!",{flagPayloads:t,overriddenPayloads:n,finalPayloads:r}),this.ai=!0),r}reloadFeatureFlags(){this.hi||this._instance.config.advanced_disable_feature_flags||this.gi||(this._instance.mi.emit("featureFlagsReloading",!0),this.gi=setTimeout((()=>{this.bi()}),5))}yi(){clearTimeout(this.gi),this.gi=void 0}ensureFlagsLoaded(){this.li||this.ui||this.gi||this.reloadFeatureFlags()}setAnonymousDistinctId(t){this.$anon_distinct_id=t}setReloadingPaused(t){this.hi=t}bi(t){var n;if(this.yi(),!this._instance.M())if(this.ui)this.di=!0;else{var r=this._instance.config.token,i=this._instance.get_property("$device_id"),s={token:r,distinct_id:this._instance.get_distinct_id(),groups:this._instance.getGroups(),$anon_distinct_id:this.$anon_distinct_id,person_properties:Ie({},((n=this._instance.persistence)==null?void 0:n.get_initial_props())||{},this._instance.get_property(lp)||{}),group_properties:this._instance.get_property(xc),timezone:eV()};Ds(i)||Te(i)||(s.$device_id=i),(t!=null&&t.disableFlags||this._instance.config.advanced_disable_feature_flags)&&(s.disable_flags=!0),this.pi()&&(s.evaluation_contexts=this.fi());var o=this._instance.config.advanced_only_evaluate_survey_feature_flags?"&only_evaluate_survey_feature_flags=true":"",a=this._instance.requestRouter.endpointFor("flags","/flags/?v=2"+o);this.ui=!0,this._instance._send_request({method:"POST",url:a,data:s,compression:this._instance.config.disable_compression?void 0:$o.Base64,timeout:this._instance.config.feature_flag_request_timeout_ms,callback:c=>{var d,f,p,m=!0;if(c.statusCode===200&&(this.di||(this.$anon_distinct_id=void 0),m=!1),this.ui=!1,!s.disable_flags||this.di){this.vi=!m;var v=[];c.error?c.error instanceof Error?v.push(c.error.name==="AbortError"?DPe:LPe):v.push(NPe):c.statusCode!==200&&v.push($Pe(c.statusCode)),(d=c.json)!=null&&d.errorsWhileComputingFlags&&v.push(APe);var w=!((f=c.json)==null||(f=f.quotaLimited)==null||!f.includes(FPe.FeatureFlags));if(w&&v.push(MPe),(p=this._instance.persistence)==null||p.register({[SC]:v}),w)wi.warn("You have hit your feature flags quota limit, and will not be able to load feature flags until the quota is reset. Please visit https://posthog.com/docs/billing/limits-alerts to learn more.");else{var _;s.disable_flags||this.receivedFeatureFlags((_=c.json)!==null&&_!==void 0?_:{},m),this.di&&(this.di=!1,this.bi())}}}})}}getFeatureFlag(t,n){var r;if(n===void 0&&(n={}),this.li||this.getFlags()&&this.getFlags().length>0){var i=this.getFeatureFlagResult(t,n);return(r=i?.variant)!==null&&r!==void 0?r:i?.enabled}wi.warn('getFeatureFlag for key "'+t+`" failed. Feature flags didn't load in time.`)}getFeatureFlagDetails(t){return this.getFlagsWithDetails()[t]}getFeatureFlagPayload(t){var n=this.getFeatureFlagResult(t,{send_event:!1});return n?.payload}getFeatureFlagResult(t,n){if(n===void 0&&(n={}),this.li||this.getFlags()&&this.getFlags().length>0){var r=this.getFlagVariants(),i=t in r,s=r[t],o=this.getFlagPayloads()[t],a=String(s),c=this._instance.get_property(OD)||void 0,d=this._instance.get_property(AD)||void 0,f=this._instance.get_property(c_)||{};if((n.send_event||!("send_event"in n))&&(!(t in f)||!f[t].includes(a))){var p,m,v,w,_,b,C,P,D,F;Gt(f[t])?f[t].push(a):f[t]=[a],(p=this._instance.persistence)==null||p.register({[c_]:f});var R=this.getFeatureFlagDetails(t),I=[...(m=this._instance.get_property(SC))!==null&&m!==void 0?m:[]];Te(s)&&I.push(IPe);var k={$feature_flag:t,$feature_flag_response:s,$feature_flag_payload:o||null,$feature_flag_request_id:c,$feature_flag_evaluated_at:d,$feature_flag_bootstrapped_response:((v=this._instance.config.bootstrap)==null||(v=v.featureFlags)==null?void 0:v[t])||null,$feature_flag_bootstrapped_payload:((w=this._instance.config.bootstrap)==null||(w=w.featureFlagPayloads)==null?void 0:w[t])||null,$used_bootstrap_value:!this.vi};Te(R==null||(_=R.metadata)==null?void 0:_.version)||(k.$feature_flag_version=R.metadata.version);var L,B=(b=R==null||(C=R.reason)==null?void 0:C.description)!==null&&b!==void 0?b:R==null||(P=R.reason)==null?void 0:P.code;B&&(k.$feature_flag_reason=B),R!=null&&(D=R.metadata)!=null&&D.id&&(k.$feature_flag_id=R.metadata.id),Te(R?.original_variant)&&Te(R?.original_enabled)||(k.$feature_flag_original_response=Te(R.original_variant)?R.original_enabled:R.original_variant),R!=null&&(F=R.metadata)!=null&&F.original_payload&&(k.$feature_flag_original_payload=R==null||(L=R.metadata)==null?void 0:L.original_payload),I.length&&(k.$feature_flag_error=I.join(",")),this._instance.capture("$feature_flag_called",k)}if(i){var A=o;if(!Te(o))try{A=JSON.parse(o)}catch{}return{key:t,enabled:!!s,variant:typeof s=="string"?s:void 0,payload:A}}}else wi.warn('getFeatureFlagResult for key "'+t+`" failed. Feature flags didn't load in time.`)}getRemoteConfigPayload(t,n){var r=this._instance.config.token,i={distinct_id:this._instance.get_distinct_id(),token:r};this.pi()&&(i.evaluation_contexts=this.fi()),this._instance._send_request({method:"POST",url:this._instance.requestRouter.endpointFor("flags","/flags/?v=2"),data:i,compression:this._instance.config.disable_compression?void 0:$o.Base64,timeout:this._instance.config.feature_flag_request_timeout_ms,callback:s=>{var o,a=(o=s.json)==null?void 0:o.featureFlagPayloads;n(a?.[t]||void 0)}})}isFeatureEnabled(t,n){if(n===void 0&&(n={}),this.li||this.getFlags()&&this.getFlags().length>0){var r=this.getFeatureFlag(t,n);return Te(r)?void 0:!!r}wi.warn('isFeatureEnabled for key "'+t+`" failed. Feature flags didn't load in time.`)}addFeatureFlagsHandler(t){this.featureFlagEventHandlers.push(t)}removeFeatureFlagsHandler(t){this.featureFlagEventHandlers=this.featureFlagEventHandlers.filter((n=>n!==t))}receivedFeatureFlags(t,n){if(this._instance.persistence){this.li=!0;var r=this.getFlagVariants(),i=this.getFlagPayloads(),s=this.getFlagsWithDetails();(function(o,a,c,d,f){c===void 0&&(c={}),d===void 0&&(d={}),f===void 0&&(f={});var p=jPe(o),m=p.flags,v=p.featureFlags,w=p.featureFlagPayloads;if(v){var _=o.requestId,b=o.evaluatedAt;if(Gt(v)){wi.warn("v1 of the feature flags endpoint is deprecated. Please use the latest version.");var C={};if(v)for(var P=0;P<v.length;P++)C[v[P]]=!0;a&&a.register({[CE]:v,[Od]:C})}else{var D=v,F=w,R=m;if(o.errorsWhileComputingFlags)if(m){var I=new Set(Object.keys(m).filter((k=>{var L;return!((L=m[k])!=null&&L.failed)})));D=Ie({},c,Object.fromEntries(Object.entries(D).filter((k=>{var[L]=k;return I.has(L)})))),F=Ie({},d,Object.fromEntries(Object.entries(F||{}).filter((k=>{var[L]=k;return I.has(L)})))),R=Ie({},f,Object.fromEntries(Object.entries(R||{}).filter((k=>{var[L]=k;return I.has(L)}))))}else D=Ie({},c,D),F=Ie({},d,F),R=Ie({},f,R);a&&a.register(Ie({[CE]:Object.keys(ID(D)),[Od]:D||{},[PD]:F||{},[wC]:R||{}},_?{[OD]:_}:{},b?{[AD]:b}:{}))}}})(t,this._instance.persistence,r,i,s),this.wi(n)}}override(t,n){n===void 0&&(n=!1),wi.warn("override is deprecated. Please use overrideFeatureFlags instead."),this.overrideFeatureFlags({flags:t,suppressWarning:n})}overrideFeatureFlags(t){if(!this._instance.__loaded||!this._instance.persistence)return wi.uninitializedWarning("posthog.featureFlags.overrideFeatureFlags");if(t===!1)return this._instance.persistence.unregister(id),this._instance.persistence.unregister(Gh),this.wi(),Kh.info("All overrides cleared");if(t&&typeof t=="object"&&("flags"in t||"payloads"in t)){var n,r=t;if(this.ai=!!((n=r.suppressWarning)!==null&&n!==void 0&&n),"flags"in r){if(r.flags===!1)this._instance.persistence.unregister(id),Kh.info("Flag overrides cleared");else if(r.flags){if(Gt(r.flags)){for(var i={},s=0;s<r.flags.length;s++)i[r.flags[s]]=!0;this._instance.persistence.register({[id]:i})}else this._instance.persistence.register({[id]:r.flags});Kh.info("Flag overrides set",{flags:r.flags})}}return"payloads"in r&&(r.payloads===!1?(this._instance.persistence.unregister(Gh),Kh.info("Payload overrides cleared")):r.payloads&&(this._instance.persistence.register({[Gh]:r.payloads}),Kh.info("Payload overrides set",{payloads:r.payloads}))),void this.wi()}this.wi()}onFeatureFlags(t){if(this.addFeatureFlagsHandler(t),this.li){var{flags:n,flagVariants:r}=this.xi();t(n,r)}return()=>this.removeFeatureFlagsHandler(t)}updateEarlyAccessFeatureEnrollment(t,n,r){var i,s=(this._instance.get_property(ap)||[]).find((d=>d.flagKey===t)),o={["$feature_enrollment/"+t]:n},a={$feature_flag:t,$feature_enrollment:n,$set:o};s&&(a.$early_access_feature_name=s.name),r&&(a.$feature_enrollment_stage=r),this._instance.capture("$feature_enrollment_update",a),this.setPersonPropertiesForFlags(o,!1);var c=Ie({},this.getFlagVariants(),{[t]:n});(i=this._instance.persistence)==null||i.register({[CE]:Object.keys(ID(c)),[Od]:c}),this.wi()}getEarlyAccessFeatures(t,n,r){n===void 0&&(n=!1);var i=this._instance.get_property(ap),s=r?"&"+r.map((o=>"stage="+o)).join("&"):"";if(i&&!n)return t(i);this._instance._send_request({url:this._instance.requestRouter.endpointFor("api","/api/early_access_features/?token="+this._instance.config.token+s),method:"GET",callback:o=>{var a,c;if(o.json){var d=o.json.earlyAccessFeatures;return(a=this._instance.persistence)==null||a.unregister(ap),(c=this._instance.persistence)==null||c.register({[ap]:d}),t(d)}}})}xi(){var t=this.getFlags(),n=this.getFlagVariants();return{flags:t.filter((r=>n[r])),flagVariants:Object.keys(n).filter((r=>n[r])).reduce(((r,i)=>(r[i]=n[i],r)),{})}}wi(t){var{flags:n,flagVariants:r}=this.xi();
278this.featureFlagEventHandlers.forEach((i=>i(n,r,{errorsLoading:t})))}setPersonPropertiesForFlags(t,n){n===void 0&&(n=!0);var r=this._instance.get_property(lp)||{};this._instance.register({[lp]:Ie({},r,t)}),n&&this._instance.reloadFeatureFlags()}resetPersonPropertiesForFlags(){this._instance.unregister(lp)}setGroupPropertiesForFlags(t,n){n===void 0&&(n=!0);var r=this._instance.get_property(xc)||{};Object.keys(r).length!==0&&Object.keys(r).forEach((i=>{r[i]=Ie({},r[i],t[i]),delete t[i]})),this._instance.register({[xc]:Ie({},r,t)}),n&&this._instance.reloadFeatureFlags()}resetGroupPropertiesForFlags(t){if(t){var n=this._instance.get_property(xc)||{};this._instance.register({[xc]:Ie({},n,{[t]:{}})})}else this._instance.unregister(xc)}reset(){this.li=!1,this.ui=!1,this.hi=!1,this.di=!1,this.vi=!1,this.$anon_distinct_id=void 0,this.yi(),this.ai=!1}}var zPe=["cookie","localstorage","localstorage+cookie","sessionstorage","memory"];class kE{constructor(t,n){this.R=t,this.props={},this.$i=!1,this.Ei=(r=>{var i="";return r.token&&(i=r.token.replace(/\+/g,"PL").replace(/\//g,"SL").replace(/=/g,"EQ")),r.persistence_name?"ph_"+r.persistence_name:"ph_"+i+"_posthog"})(t),this.Y=this.Si(t),this.load(),t.debug&&Re.info("Persistence loaded",t.persistence,Ie({},this.props)),this.update_config(t,t,n),this.save()}isDisabled(){return!!this.ki}Si(t){zPe.indexOf(t.persistence.toLowerCase())===-1&&(Re.critical("Unknown persistence type "+t.persistence+"; falling back to localStorage+cookie"),t.persistence="localStorage+cookie");var n=(function(i){i===void 0&&(i=[]);var s=[...tPe,...i];return Ie({},Cn,{W:function(o){try{var a={};try{a=qs.W(o)||{}}catch{}var c=jn(a,JSON.parse(Cn.q(o)||"{}"));return Cn.G(o,c),c}catch{}return null},G:function(o,a,c,d,f,p){try{Cn.G(o,a,void 0,void 0,p);var m={};s.forEach((v=>{a[v]&&(m[v]=a[v])})),Object.keys(m).length&&qs.G(o,m,c,d,f,p)}catch(v){Cn.B(v)}},V:function(o,a){try{fe?.localStorage.removeItem(o),qs.V(o,a)}catch(c){Cn.B(c)}}})})(t.cookie_persisted_properties||[]),r=t.persistence.toLowerCase();return r==="localstorage"&&Cn.H()?Cn:r==="localstorage+cookie"&&n.H()?n:r==="sessionstorage"&&br.H()?br:r==="memory"?nPe:r==="cookie"?qs:n.H()?n:qs}properties(){var t={};return dn(this.props,(function(n,r){if(r===Od&&sr(n))for(var i=Object.keys(n),s=0;s<i.length;s++)t["$feature/"+i[s]]=n[i[s]];else a=r,c=!1,(Ds(o=LRe)?c:V8&&o.indexOf===V8?o.indexOf(a)!=-1:(dn(o,(function(d){if(c||(c=d===a))return a_})),c))||(t[r]=n);var o,a,c})),t}load(){if(!this.ki){var t=this.Y.W(this.Ei);t&&(this.props=jn({},t))}}save(){this.ki||this.Y.G(this.Ei,this.props,this.Pi,this.Ti,this.Ii,this.R.debug)}remove(){this.Y.V(this.Ei,!1),this.Y.V(this.Ei,!0)}clear(){this.remove(),this.props={}}register_once(t,n,r){if(sr(t)){Te(n)&&(n="None"),this.Pi=Te(r)?this.Ci:r;var i=!1;if(dn(t,((s,o)=>{this.props.hasOwnProperty(o)&&this.props[o]!==n||(this.props[o]=s,i=!0)})),i)return this.save(),!0}return!1}register(t,n){if(sr(t)){this.Pi=Te(n)?this.Ci:n;var r=!1;if(dn(t,((i,s)=>{t.hasOwnProperty(s)&&this.props[s]!==i&&(this.props[s]=i,r=!0)})),r)return this.save(),!0}return!1}unregister(t){t in this.props&&(delete this.props[t],this.save())}update_campaign_params(){if(!this.$i){var t=GH(this.R.custom_campaign_params,this.R.mask_personal_data_properties,this.R.custom_personal_data_properties);Pd(VR(t))||this.register(t),this.$i=!0}}update_search_keyword(){var t;this.register((t=ke?.referrer)?JH(t):{})}update_referrer_info(){var t;this.register_once({$referrer:ZH(),$referring_domain:ke!=null&&ke.referrer&&((t=h_(ke.referrer))==null?void 0:t.host)||"$direct"},void 0)}set_initial_person_info(){this.props[CC]||this.props[kC]||this.register_once({[u_]:XH(this.R.mask_personal_data_properties,this.R.custom_personal_data_properties)},void 0)}get_initial_props(){var t={};dn([kC,CC],(o=>{var a=this.props[o];a&&dn(a,(function(c,d){t["$initial_"+dC(d)]=c}))}));var n,r,i=this.props[u_];if(i){var s=(n=QH(i),r={},dn(n,(function(o,a){r["$initial_"+dC(a)]=o})),r);jn(t,s)}return t}safe_merge(t){return dn(this.props,(function(n,r){r in t||(t[r]=n)})),t}update_config(t,n,r){if(this.Ci=this.Pi=t.cookie_expiration,this.set_disabled(t.disable_persistence||!!r),this.set_cross_subdomain(t.cross_subdomain_cookie),this.set_secure(t.secure_cookie),t.persistence!==n.persistence||!((o,a)=>
278{if(o.length!==a.length)return!1;var c=[...o].sort(),d=[...a].sort();return c.every(((f,p)=>f===d[p]))})(t.cookie_persisted_properties||[],n.cookie_persisted_properties||[])){var i=this.Si(t),s=this.props;this.clear(),this.Y=i,this.props=s,this.save()}}set_disabled(t){this.ki=t,this.ki?this.remove():this.save()}set_cross_subdomain(t){t!==this.Ti&&(this.Ti=t,this.remove(),this.save())}set_secure(t){t!==this.Ii&&(this.Ii=t,this.remove(),this.save())}set_event_timer(t,n){var r=this.props[op]||{};r[t]=n,this.props[op]=r,this.save()}remove_event_timer(t){var n=(this.props[op]||{})[t];return Te(n)||(delete this.props[op][t],this.save()),n}get_property(t){return this.props[t]}set_property(t,n){this.props[t]=n,this.save()}}var MD=Tn("[Product Tours]"),TE="ph_product_tours";class BPe{constructor(t){this.Ri=null,this.Fi=null,this._instance=t}onRemoteConfig(t){"productTours"in t&&(this._instance.persistence&&this._instance.persistence.register({[oD]:!!t.productTours}),this.loadIfEnabled())}loadIfEnabled(){var t,n;this.Ri||(t=this._instance).config.disable_product_tours||(n=t.persistence)==null||!n.get_property(oD)||this.it((()=>this.Oi()))}it(t){var n,r;(n=Xe.__PosthogExtensions__)!=null&&n.generateProductTours?t():(r=Xe.__PosthogExtensions__)==null||r.loadExternalDependency==null||r.loadExternalDependency(this._instance,"product-tours",(i=>{i?MD.error("Could not load product tours script",i):t()}))}Oi(){var t;!this.Ri&&(t=Xe.__PosthogExtensions__)!=null&&t.generateProductTours&&(this.Ri=Xe.__PosthogExtensions__.generateProductTours(this._instance,!0))}getProductTours(t,n){if(n===void 0&&(n=!1),!Gt(this.Fi)||n){var r=this._instance.persistence;if(r){var i=r.props[TE];if(Gt(i)&&!n)return this.Fi=i,void t(i,{isLoaded:!0})}this._instance._send_request({url:this._instance.requestRouter.endpointFor("api","/api/product_tours/?token="+this._instance.config.token),method:"GET",callback:s=>{var o=s.statusCode;if(o!==200||!s.json){var a="Product Tours API could not be loaded, status: "+o;return MD.error(a),void t([],{isLoaded:!1,error:a})}var c=Gt(s.json.product_tours)?s.json.product_tours:[];this.Fi=c,r&&r.register({[TE]:c}),t(c,{isLoaded:!0})}})}else t(this.Fi,{isLoaded:!0})}getActiveProductTours(t){At(this.Ri)?t([],{isLoaded:!1,error:"Product tours not loaded"}):this.Ri.getActiveProductTours(t)}showProductTour(t){var n;(n=this.Ri)==null||n.showTourById(t)}previewTour(t){this.Ri?this.Ri.previewTour(t):this.it((()=>{var n;this.Oi(),(n=this.Ri)==null||n.previewTour(t)}))}dismissProductTour(){var t;(t=this.Ri)==null||t.dismissTour("user_clicked_skip")}nextStep(){var t;(t=this.Ri)==null||t.nextStep()}previousStep(){var t;(t=this.Ri)==null||t.previousStep()}clearCache(){var t;this.Fi=null,(t=this._instance.persistence)==null||t.unregister(TE)}resetTour(t){var n;(n=this.Ri)==null||n.resetTour(t)}resetAllTours(){var t;(t=this.Ri)==null||t.resetAllTours()}cancelPendingTour(t){var n;(n=this.Ri)==null||n.cancelPendingTour(t)}}var Yh=(function(e){return e.Activation="events",e.Cancellation="cancelEvents",e})({});(function(e){return e.Button="button",e.Tab="tab",e.Selector="selector",e})({});(function(e){return e.TopLeft="top_left",e.TopRight="top_right",e.TopCenter="top_center",e.MiddleLeft="middle_left",e.MiddleRight="middle_right",e.MiddleCenter="middle_center",e.Left="left",e.Center="center",e.Right="right",e.NextToTrigger="next_to_trigger",e})({});(function(e){return e.Top="top",e.Left="left",e.Right="right",e.Bottom="bottom",e})({});var RE=(function(e){return e.Popover="popover",e.API="api",e.Widget="widget",e.ExternalSurvey="external_survey",e})({});(function(e){return e.Open="open",e.MultipleChoice="multiple_choice",e.SingleChoice="single_choice",e.Rating="rating",e.Link="link",e})({});(function(e){return e.NextQuestion="next_question",e.End="end",e.ResponseBased="response_based",e.SpecificQuestion="specific_question",e})({});(function(e){return e.Once="once",e.Recurring="recurring",e.Always="always",e})({});var up=(function(e){return e.SHOWN="survey shown",e.DISMISSED="survey dismissed",e.SENT="survey sent",e.ABANDONED="survey abandoned",e})({}),PE=(function(e){return e.SURVEY_ID="$survey_id",e.SURVEY_NAME="$survey_name",e.SURVEY_RESPONSE="$survey_response",e.SURVEY_ITERATION="$survey_iteration",e.SURVEY_ITERATION_
278START_DATE="$survey_iteration_start_date",e.SURVEY_PARTIALLY_COMPLETED="$survey_partially_completed",e.SURVEY_SUBMISSION_ID="$survey_submission_id",e.SURVEY_QUESTIONS="$survey_questions",e.SURVEY_COMPLETED="$survey_completed",e.PRODUCT_TOUR_ID="$product_tour_id",e.SURVEY_LAST_SEEN_DATE="$survey_last_seen_date",e})({}),AC=(function(e){return e.Popover="popover",e.Inline="inline",e})({}),an=Tn("[Surveys]"),lV="seenSurvey_",HPe=(e,t)=>{var n="$survey_"+t+"/"+e.id;return e.current_iteration&&e.current_iteration>0&&(n="$survey_"+t+"/"+e.id+"/"+e.current_iteration),n},DD=e=>((t,n)=>{var r=""+t+n.id;return n.current_iteration&&n.current_iteration>0&&(r=""+t+n.id+"_"+n.current_iteration),r})(lV,e),VPe=[RE.Popover,RE.Widget,RE.API],WPe={ignoreConditions:!1,ignoreDelay:!1,displayType:AC.Popover};class JR{constructor(){this.Mi={},this.Mi={}}on(t,n){return this.Mi[t]||(this.Mi[t]=[]),this.Mi[t].push(n),()=>{this.Mi[t]=this.Mi[t].filter((r=>r!==n))}}emit(t,n){for(var r of this.Mi[t]||[])r(n);for(var i of this.Mi["*"]||[])i(t,n)}}function sd(e,t,n){if(At(e))return!1;switch(n){case"exact":return e===t;case"contains":var r=t.replace(/[.*+?^${}()|[\]\\]/g,"\\$&").replace(/_/g,".").replace(/%/g,".*");return new RegExp(r,"i").test(e);case"regex":try{return new RegExp(t).test(e)}catch{return!1}default:return!1}}class qPe{constructor(t){this.Ai=new JR,this.ji=(n,r)=>this.Di(n,r)&&this.Li(n,r)&&this.Ni(n,r)&&this.Ui(n,r),this.Di=(n,r)=>r==null||!r.event||n?.event===r?.event,this._instance=t,this.zi=new Set,this.Hi=new Set}init(){var t;if(!Te((t=this._instance)==null?void 0:t._addCaptureHook)){var n;(n=this._instance)==null||n._addCaptureHook(((r,i)=>{this.on(r,i)}))}}register(t){var n,r;if(!Te((n=this._instance)==null?void 0:n._addCaptureHook)&&(t.forEach((o=>{var a,c;(a=this.Hi)==null||a.add(o),(c=o.steps)==null||c.forEach((d=>{var f;(f=this.zi)==null||f.add(d?.event||"")}))})),(r=this._instance)!=null&&r.autocapture)){var i,s=new Set;t.forEach((o=>{var a;(a=o.steps)==null||a.forEach((c=>{c!=null&&c.selector&&s.add(c?.selector)}))})),(i=this._instance)==null||i.autocapture.setElementSelectors(s)}}on(t,n){var r;n!=null&&t.length!=0&&(this.zi.has(t)||this.zi.has(n?.event))&&this.Hi&&((r=this.Hi)==null?void 0:r.size)>0&&this.Hi.forEach((i=>{this.Bi(n,i)&&this.Ai.emit("actionCaptured",i.name)}))}qi(t){this.onAction("actionCaptured",(n=>t(n)))}Bi(t,n){if(n?.steps==null)return!1;for(var r of n.steps)if(this.ji(t,r))return!0;return!1}onAction(t,n){return this.Ai.on(t,n)}Li(t,n){if(n!=null&&n.url){var r,i=t==null||(r=t.properties)==null?void 0:r.$current_url;if(!i||typeof i!="string"||!sd(i,n.url,n.url_matching||"contains"))return!1}return!0}Ni(t,n){return!!this.Wi(t,n)&&!!this.Gi(t,n)&&!!this.Vi(t,n)}Wi(t,n){var r;if(n==null||!n.href)return!0;var i=this.Ji(t);if(i.length>0)return i.some((a=>sd(a.href,n.href,n.href_matching||"exact")));var s,o=(t==null||(r=t.properties)==null?void 0:r.$elements_chain)||"";return!!o&&sd((s=o.match(/(?::|")href="(.*?)"/))?s[1]:"",n.href,n.href_matching||"exact")}Gi(t,n){var r;if(n==null||!n.text)return!0;var i=this.Ji(t);if(i.length>0)return i.some((d=>sd(d.text,n.text,n.text_matching||"exact")||sd(d.$el_text,n.text,n.text_matching||"exact")));var s,o,a,c=(t==null||(r=t.properties)==null?void 0:r.$elements_chain)||"";return!!c&&(s=(function(d){for(var f,p=[],m=/(?::|")text="(.*?)"/g;!At(f=m.exec(d));)p.includes(f[1])||p.push(f[1]);return p})(c),o=n.text,a=n.text_matching||"exact",s.some((d=>sd(d,o,a))))}Vi(t,n){var r,i;if(n==null||!n.selector)return!0;var s=t==null||(r=t.properties)==null?void 0:r.$element_selectors;if(s!=null&&s.includes(n.selector))return!0;var o=(t==null||(i=t.properties)==null?void 0:i.$elements_chain)||"";if(n.selector_regex&&o)try{return new RegExp(n.selector_regex).test(o)}catch{return!1}return!1}Ji(t){var n;return(t==null||(n=t.properties)==null?void 0:n.$elements)==null?[]:t?.properties.$elements}Ui(t,n){return n==null||!n.properties||n.properties.length===0||aV(n.properties.reduce(((r,i)=>{var s=Gt(i.value)?i.value.map(String):i.value!=null?[String(i.value)]:[];return r[i.key]={values:s,operator:i.operator||"exact"},r}),{}),t?.properties)}}class KPe{constructor(t){this._instance=t,this.Ki=new Map,this.Yi=new Map,this.Xi=new Map}Qi(t,n){return!!t&&aV(t.propertyFilters,n?.properties)}Zi(t,n){var r=new Map;return t.forEach((i=>{var s;(s=i.conditions)==null||(s=s[n])==null||(s=s.values)==null||s.forEac
278h((o=>{if(o!=null&&o.name){var a=r.get(o.name)||[];a.push(i.id),r.set(o.name,a)}}))})),r}te(t,n,r){var i=(r===Yh.Activation?this.Ki:this.Yi).get(t),s=[];return this.ie((o=>{s=o.filter((a=>i?.includes(a.id)))})),s.filter((o=>{var a,c=(a=o.conditions)==null||(a=a[r])==null||(a=a.values)==null?void 0:a.find((d=>d.name===t));return this.Qi(c,n)}))}register(t){var n;Te((n=this._instance)==null?void 0:n._addCaptureHook)||(this.ee(t),this.re(t))}re(t){var n=t.filter((r=>{var i,s;return((i=r.conditions)==null?void 0:i.actions)&&((s=r.conditions)==null||(s=s.actions)==null||(s=s.values)==null?void 0:s.length)>0}));n.length!==0&&(this.se==null&&(this.se=new qPe(this._instance),this.se.init(),this.se.qi((r=>{this.onAction(r)}))),n.forEach((r=>{var i,s,o,a,c;r.conditions&&(i=r.conditions)!=null&&i.actions&&(s=r.conditions)!=null&&(s=s.actions)!=null&&s.values&&((o=r.conditions)==null||(o=o.actions)==null||(o=o.values)==null?void 0:o.length)>0&&((a=this.se)==null||a.register(r.conditions.actions.values),(c=r.conditions)==null||(c=c.actions)==null||(c=c.values)==null||c.forEach((d=>{if(d&&d.name){var f=this.Xi.get(d.name);f&&f.push(r.id),this.Xi.set(d.name,f||[r.id])}})))})))}ee(t){var n,r=t.filter((s=>{var o,a;return((o=s.conditions)==null?void 0:o.events)&&((a=s.conditions)==null||(a=a.events)==null||(a=a.values)==null?void 0:a.length)>0})),i=t.filter((s=>{var o,a;return((o=s.conditions)==null?void 0:o.cancelEvents)&&((a=s.conditions)==null||(a=a.cancelEvents)==null||(a=a.values)==null?void 0:a.length)>0}));(r.length!==0||i.length!==0)&&((n=this._instance)==null||n._addCaptureHook(((s,o)=>{this.onEvent(s,o)})),this.Ki=this.Zi(t,Yh.Activation),this.Yi=this.Zi(t,Yh.Cancellation))}onEvent(t,n){var r,i=this.ne(),s=this.oe(),o=this.ae(),a=((r=this._instance)==null||(r=r.persistence)==null?void 0:r.props[s])||[];if(o===t&&n&&a.length>0){var c,d;i.info("event matched, removing item from activated items",{event:t,eventPayload:n,existingActivatedItems:a});var f=(n==null||(c=n.properties)==null?void 0:c.$survey_id)||(n==null||(d=n.properties)==null?void 0:d.$product_tour_id);if(f){var p=a.indexOf(f);p>=0&&(a.splice(p,1),this.le(a))}}else{if(this.Yi.has(t)){var m=this.te(t,n,Yh.Cancellation);m.length>0&&(i.info("cancel event matched, cancelling items",{event:t,itemsToCancel:m.map((w=>w.id))}),m.forEach((w=>{var _=a.indexOf(w.id);_>=0&&a.splice(_,1),this.ue(w.id)})),this.le(a))}if(this.Ki.has(t)){i.info("event name matched",{event:t,eventPayload:n,items:this.Ki.get(t)});var v=this.te(t,n,Yh.Activation);this.le(a.concat(v.map((w=>w.id))||[]))}}}onAction(t){var n,r=this.oe(),i=((n=this._instance)==null||(n=n.persistence)==null?void 0:n.props[r])||[];this.Xi.has(t)&&this.le(i.concat(this.Xi.get(t)||[]))}le(t){var n,r=this.ne(),i=this.oe(),s=[...new Set(t)].filter((o=>!this.he(o)));r.info("updating activated items",{activatedItems:s}),(n=this._instance)==null||(n=n.persistence)==null||n.register({[i]:s})}getActivatedIds(){var t,n=this.oe(),r=(t=this._instance)==null||(t=t.persistence)==null?void 0:t.props[n];return r||[]}getEventToItemsMap(){return this.Ki}de(){return this.se}}class GPe extends KPe{constructor(t){super(t)}oe(){return"$surveys_activated"}ae(){return up.SHOWN}ie(t){var n;(n=this._instance)==null||n.getSurveys(t)}ue(t){var n;(n=this._instance)==null||n.cancelPendingSurvey(t)}ne(){return an}he(){return!1}getSurveys(){return this.getActivatedIds()}getEventToSurveys(){return this.getEventToItemsMap()}}class YPe{constructor(t){this.ve=void 0,this._surveyManager=null,this.ce=!1,this.fe=[],this.pe=null,this._instance=t,this._surveyEventReceiver=null}onRemoteConfig(t){if(!this._instance.config.disable_surveys){var n=t.surveys;if(At(n))return an.warn("Flags not loaded yet. Not loading surveys.");var r=Gt(n);this.ve=r?n.length>0:n,an.info("flags response received, isSurveysEnabled: "+this.ve),this.loadIfEnabled()}}reset(){localStorage.removeItem("lastSeenSurveyDate");for(var t=[],n=0;n<localStorage.length;n++){var r=localStorage.key(n);(r!=null&&r.startsWith(lV)||r!=null&&r.startsWith("inProgressSurvey_"))&&t.push(r)}t.forEach((i=>localStorage.removeItem(i)))}loadIfEnabled(){if(!this._surveyManager)if(this.ce)an.info("Already initializing surveys, skipping...");else if(this._instance.config.disable_surveys)an.info("Disabled. Not loading surveys.");else if(this._instance.config.cookieless_mode&&this._instance.consent.isOptedOut())an.info("Not loading surveys in cookieless mode without consent.");else{var t=Xe?.__PosthogExtensions__;if(t){if(!Te(this.ve)||this._instance.config.advanced_enable_surveys){var n=this.ve||this._instance.config.advanced_enable_surveys;this.ce=!0;try{var r=t.generateSurveys;if(r)return void this._e(r,n);var i=t.loadExternalDependency;if(!i)return void this.ge("PostHog loadExternalDependency extension not found.");i(this._instance,"surveys",(s=>{s||!t.generateSurveys?this.ge("Could not load surveys script",s):this._e(t.generateSurveys,n)}))}catch(s){throw this.ge("Error initializing surveys",s),s}finally{this.ce=!1}}}else an.error("PostHog Extensions not found.")}}_e(t,n){this._surveyManager=t(this._instance,n),this._surveyEventReceiver=new GPe(this._instance),an.info("Surveys loaded successfully"),this.me({isLoaded:!0})}ge(t,n){an.error(t,n),this.me({isLoaded:!1,error:t})}onSurveysLoaded(t){return this.fe.push(t),this._surveyManager&&this.me({isLoaded:!0}),()=>{this.fe=this.fe.filter((n=>n!==t))}}getSurveys(t,n){if(n===void 0&&(n=!1),this._instance.config.disable_surveys)return an.info("Disabled. Not loading surveys."),t([]);var r,i=this._instance.get_property(bC);if(i&&!n)return t(i,{isLoaded:!0});typeof Promise<"u"&&this.pe?this.pe.then((s=>{var{surveys:o,context:a}=s;return t(o,a)})):(typeof Promise<"u"&&(this.pe=new Promise((s=>{r=s}))),this._instance._send_request({url:this._instance.requestRouter.endpointFor("api","/api/surveys/?token="+this._instance.config.token),method:"GET",timeout:this._instance.config.surveys_request_timeout_ms,callback:s=>{var o;this.pe=null;var a=s.statusCode;if(a!==200||!s.json){var c="Surveys API could not be loaded, status: "+a;an.error(c);var d={isLoaded:!1,error:c};return t([],d),void(r==null||r({surveys:[],context:d}))}var f,p=s.json.surveys||[],m=p.filter((w=>(function(_){return!(!_.start_date||_.end_date)})(w)&&((function(_){var b;return!((b=_.conditions)==null||(b=b.events)==null||(b=b.values)==null||!b.length)})(w)||(function(_){var b;return!((b=_.conditions)==null||(b=b.actions)==null||(b=b.values)==null||!b.length)})(w))));m.length>0&&((f=this._surveyEventReceiver)==null||f.register(m)),(o=this._instance.persistence)==null||o.register({[bC]:p});var v={isLoaded:!0};t(p,v),r?.({surveys:p,context:v})}}))}me(t){for(var n of this.fe)try{if(!t.isLoaded)return n([],t);
278this.getSurveys(n)}catch(r){an.error("Error in survey callback",r)}}getActiveMatchingSurveys(t,n){if(n===void 0&&(n=!1),!At(this._surveyManager))return this._surveyManager.getActiveMatchingSurveys(t,n);an.warn("init was not called")}be(t){var n=null;return this.getSurveys((r=>{var i;n=(i=r.find((s=>s.id===t)))!==null&&i!==void 0?i:null})),n}ye(t){if(At(this._surveyManager))return{eligible:!1,reason:"SDK is not enabled or survey functionality is not yet loaded"};var n=typeof t=="string"?this.be(t):t;return n?this._surveyManager.checkSurveyEligibility(n):{eligible:!1,reason:"Survey not found"}}canRenderSurvey(t){if(At(this._surveyManager))return an.warn("init was not called"),{visible:!1,disabledReason:"SDK is not enabled or survey functionality is not yet loaded"};var n=this.ye(t);return{visible:n.eligible,disabledReason:n.reason}}canRenderSurveyAsync(t,n){return At(this._surveyManager)?(an.warn("init was not called"),Promise.resolve({visible:!1,disabledReason:"SDK is not enabled or survey functionality is not yet loaded"})):new Promise((r=>{this.getSurveys((i=>{var s,o=(s=i.find((c=>c.id===t)))!==null&&s!==void 0?s:null;if(o){var a=this.ye(o);r({visible:a.eligible,disabledReason:a.reason})}else r({visible:!1,disabledReason:"Survey not found"})}),n)}))}renderSurvey(t,n,r){var i;if(At(this._surveyManager))an.warn("init was not called");else{var s=typeof t=="string"?this.be(t):t;if(s!=null&&s.id)if(VPe.includes(s.type)){var o=ke?.querySelector(n);if(o)return(i=s.appearance)!=null&&i.surveyPopupDelaySeconds?(an.info("Rendering survey "+s.id+" with delay of "+s.appearance.surveyPopupDelaySeconds+" seconds"),void setTimeout((()=>{var a,c;an.info("Rendering survey "+s.id+" with delay of "+((a=s.appearance)==null?void 0:a.surveyPopupDelaySeconds)+" seconds"),(c=this._surveyManager)==null||c.renderSurvey(s,o,r),an.info("Survey "+s.id+" rendered")}),1e3*s.appearance.surveyPopupDelaySeconds)):void this._surveyManager.renderSurvey(s,o,r);an.warn("Survey element not found")}else an.warn("Surveys of type "+s.type+" cannot be rendered in the app");else an.warn("Survey not found")}}displaySurvey(t,n){var r;if(At(this._surveyManager))an.warn("init was not called");else{var i=this.be(t);if(i){var s=i;if((r=i.appearance)!=null&&r.surveyPopupDelaySeconds&&n.ignoreDelay&&(s=Ie({},i,{appearance:Ie({},i.appearance,{surveyPopupDelaySeconds:0})})),n.displayType!==AC.Popover&&n.initialResponses&&an.warn("initialResponses is only supported for popover surveys. prefill will not be applied."),n.ignoreConditions===!1){var o=this.canRenderSurvey(i);if(!o.visible)return void an.warn("Survey is not eligible to be displayed: ",o.disabledReason)}n.displayType!==AC.Inline?this._surveyManager.handlePopoverSurvey(s,n):this.renderSurvey(s,n.selector,n.properties)}else an.warn("Survey not found")}}cancelPendingSurvey(t){At(this._surveyManager)?an.warn("init was not called"):this._surveyManager.cancelSurvey(t)}handlePageUnload(){var t;(t=this._surveyManager)==null||t.handlePageUnload()}}var Ro=Tn("[Conversations]");class JPe{constructor(t){this.we=void 0,this._conversationsManager=null,this.xe=!1,this.$e=null,this._instance=t}onRemoteConfig(t){if(!this._instance.config.disable_conversations){var n=t.conversations;At(n)||(Go(n)?this.we=n:(this.we=n.enabled,this.$e=n),this.loadIfEnabled())}}reset(){var t;(t=this._conversationsManager)==null||t.reset(),this._conversationsManager=null,this.we=void 0,this.$e=null}loadIfEnabled(){if(!this._conversationsManager&&!this.xe&&!(this._instance.config.disable_conversations||this._instance.config.cookieless_mode&&this._instance.consent.isOptedOut())){var t=Xe?.__PosthogExtensions__;if(t&&!Te(this.we)&&this.we)if(this.$e&&this.$e.token){this.xe=!0;try{var n=t.initConversations;if(n)return this.Ee(n),void(this.xe=!1);var r=t.loadExternalDependency;if(!r)return void this.Se("PostHog loadExternalDependency extension not found.");r(this._instance,"conversations",(i=>{i||!t.initConversations?this.Se("Could not load conversations script",i):this.Ee(t.initConversations),this.xe=!1}))}catch(i){this.Se("Error initializing conversations",i),this.xe=!1}}else Ro.error("Conversations enabled but missing token in remote config.")}}Ee(t){if(this.$e)try{this._conversationsManager=t(this.$e,this._instance),Ro.info("Conversations loaded successfully")}catch(n){this.Se("Error completing conversations initialization",n)}else Ro.error("Cannot complete initialization: remote config is null")}Se(t,n){Ro.error(t,n),this._conversationsManager=null,this.xe=!1}show(){this._conversationsManager?this._conversationsManager.show():Ro.warn("Conversations not loaded yet.")}hide(){this._conversationsManager&&this._conversationsManager.hide()}isAvailable(){return this.we===!0&&!Ds(this._conversationsManager)}isVisible(){var t,n;return(t=(n=this._conversationsManager)==null?void 0:n.isVisible())!==null&&t!==void 0&&t}sendMessage(t,n,r){var i=this;return Rd((function*(){return i._conversationsManager?i._conversationsManager.sendMessage(t,n,r):(Ro.warn("Conversations not available yet."),null)}))()}
278getMessages(t,n){var r=this;return Rd((function*(){return r._conversationsManager?r._conversationsManager.getMessages(t,n):(Ro.warn("Conversations not available yet."),null)}))()}markAsRead(t){var n=this;return Rd((function*(){return n._conversationsManager?n._conversationsManager.markAsRead(t):(Ro.warn("Conversations not available yet."),null)}))()}getTickets(t){var n=this;return Rd((function*(){return n._conversationsManager?n._conversationsManager.getTickets(t):(Ro.warn("Conversations not available yet."),null)}))()}getCurrentTicketId(){var t,n;return(t=(n=this._conversationsManager)==null?void 0:n.getCurrentTicketId())!==null&&t!==void 0?t:null}getWidgetSessionId(){var t,n;return(t=(n=this._conversationsManager)==null?void 0:n.getWidgetSessionId())!==null&&t!==void 0?t:null}}class ZPe{constructor(t){var n;this.ke=!1,this.Pe=!1,this._instance=t,this._instance&&(n=this._instance.config.logs)!=null&&n.captureConsoleLogs&&(this.ke=!0)}onRemoteConfig(t){var n,r=(n=t.logs)==null?void 0:n.captureConsoleLogs;!At(r)&&r&&(this.ke=!0,this.loadIfEnabled())}reset(){}loadIfEnabled(){if(this.ke&&!this.Pe){var t=Tn("[logs]"),n=Xe?.__PosthogExtensions__;if(n){var r=n.loadExternalDependency;r?r(this._instance,"logs",(i=>{var s;i||(s=n.logs)==null||!s.initializeLogs?t.error("Could not load logs script",i):(n.logs.initializeLogs(this._instance),this.Pe=!0)})):t.error("PostHog loadExternalDependency extension not found.")}else t.error("PostHog Extensions not found.")}}}var LD=Tn("[RateLimiter]");class XPe{constructor(t){this.serverLimits={},this.lastEventRateLimited=!1,this.checkForLimiting=n=>{var r=n.text;if(r&&r.length)try{(JSON.parse(r).quota_limited||[]).forEach((i=>{LD.info((i||"events")+" is quota limited."),this.serverLimits[i]=new Date().getTime()+6e4}))}catch(i){return void LD.warn('could not rate limit - continuing. Error: "'+i?.message+'"',{text:r})}},this.instance=t,this.lastEventRateLimited=this.clientRateLimitContext(!0).isRateLimited}get captureEventsPerSecond(){var t;return((t=this.instance.config.rate_limiting)==null?void 0:t.events_per_second)||10}get captureEventsBurstLimit(){var t;return Math.max(((t=this.instance.config.rate_limiting)==null?void 0:t.events_burst_limit)||10*this.captureEventsPerSecond,this.captureEventsPerSecond)}clientRateLimitContext(t){var n,r,i;t===void 0&&(t=!1);var{captureEventsBurstLimit:s,captureEventsPerSecond:o}=this,a=new Date().getTime(),c=(n=(r=this.instance.persistence)==null?void 0:r.get_property(xC))!==null&&n!==void 0?n:{tokens:s,last:a};c.tokens+=(a-c.last)/1e3*o,c.last=a,c.tokens>s&&(c.tokens=s);var d=c.tokens<1;return d||t||(c.tokens=Math.max(0,c.tokens-1)),!d||this.lastEventRateLimited||t||this.instance.capture("$$client_ingestion_warning",{$$client_ingestion_warning_message:"posthog-js client rate limited. Config is set to "+o+" events per second and "+s+" events burst limit."},{skip_client_rate_limiting:!0}),this.lastEventRateLimited=d,(i=this.instance.persistence)==null||i.set_property(xC,c),{isRateLimited:d,remainingTokens:c.tokens}}isServerRateLimited(t){var n=this.serverLimits[t||"events"]||!1;return n!==!1&&new Date().getTime()<n}}var Jh=Tn("[RemoteConfig]");class cV{constructor(t){this._instance=t}get remoteConfig(){var t;return(t=Xe._POSTHOG_REMOTE_CONFIG)==null||(t=t[this._instance.config.token])==null?void 0:t.config}Te(t){var n,r;(n=Xe.__PosthogExtensions__)!=null&&n.loadExternalDependency?(r=Xe.__PosthogExtensions__)==null||r.loadExternalDependency==null||r.loadExternalDependency(this._instance,"remote-config",(()=>t(this.remoteConfig))):t()}Ie(t){this._instance._send_request({method:"GET",url:this._instance.requestRouter.endpointFor("assets","/array/"+this._instance.config.token+"/config"),callback:n=>{t(n.json)}})}load(){try{if(this.remoteConfig)return Jh.info("Using preloaded remote config",this.remoteConfig),this.Ce(this.remoteConfig),void this.Re();if(this._instance.M())return void Jh.warn("Remote config is disabled. Falling back to local config.");this.Te((t=>{if(!t)return Jh.info("No config found after loading remote JS config. Falling back to JSON."),void this.Ie((n=>{this.Ce(n),this.Re()}));this.Ce(t),this.Re()}))}catch(t){Jh.error("Error loading remote config",t)}}stop(){this.Fe&&(clearInterval(this.Fe),this.Fe=void 0)}refresh(){this._instance.M()||ke?.visibilityState==="hidden"||this._instance.featureFlags.reloadFeatureFlags()}Re(){this.Fe||(this.Fe=setInterval((()=>{this.refresh()}),3e5))}Ce(t){t||Jh.error("Failed to fetch remote config from PostHog."),this._instance.Ce(t??{}),t?.hasFeatureFlags!==!1&&(this._instance.config.advanced_disable_feature_flags_on_first_load||this._instance.featureFlags.ensureFlagsLoaded())}}var IC=3e3;class QPe{constructor(t,n){this.Oe=!0,this.Me=[],this.Ae=Js(n?.flush_interval_ms||IC,250,5e3,Re.createLogger("flush interval"),IC),this.je=t}enqueue(t){this.Me.push(t),this.De||this.Le()}unload(){this.Ne();var t=this.Me.length>0?this.Ue():{},n=Object.values(t);[...n.filter((r=>r.url.indexOf("/e")===0)),...n.filter((r=>r.url.indexOf("/e")!==0))].map((r=>{this.je(Ie({},r,{transport:"sendBeacon"}))}))}enable(){this.Oe=!1,this.Le()}Le(){var t=this;this.Oe||(this.De=setTimeout((()=>
278{if(this.Ne(),this.Me.length>0){var n=this.Ue(),r=function(){var s=n[i],o=new Date().getTime();s.data&&Gt(s.data)&&dn(s.data,(a=>{a.offset=Math.abs(a.timestamp-o),delete a.timestamp})),t.je(s)};for(var i in n)r()}}),this.Ae))}Ne(){clearTimeout(this.De),this.De=void 0}Ue(){var t={};return dn(this.Me,(n=>{var r,i=n,s=(i?i.batchKey:null)||i.url;Te(t[s])&&(t[s]=Ie({},i,{data:[]})),(r=t[s].data)==null||r.push(i.data)})),this.Me=[],t}}var e3e=["retriesPerformedSoFar"];class t3e{constructor(t){this.ze=!1,this.He=3e3,this.Me=[],this._instance=t,this.Me=[],this.Be=!0,!Te(fe)&&"onLine"in fe.navigator&&(this.Be=fe.navigator.onLine,this.qe=()=>{this.Be=!0,this.Lt()},this.We=()=>{this.Be=!1},Xn(fe,"online",this.qe),Xn(fe,"offline",this.We))}get length(){return this.Me.length}retriableRequest(t){var{retriesPerformedSoFar:n}=t,r=rH(t,e3e);fd(n)&&(r.url=v_(r.url,{retry_count:n})),this._instance._send_request(Ie({},r,{callback:i=>{i.statusCode!==200&&(i.statusCode<400||i.statusCode>=500)&&(n??0)<10?this.Ge(Ie({retriesPerformedSoFar:n},r)):r.callback==null||r.callback(i)}}))}Ge(t){var n=t.retriesPerformedSoFar||0;t.retriesPerformedSoFar=n+1;var r=(function(o){var a=3e3*Math.pow(2,o),c=a/2,d=Math.min(18e5,a),f=(Math.random()-.5)*(d-c);return Math.ceil(d+f)})(n),i=Date.now()+r;this.Me.push({retryAt:i,requestOptions:t});var s="Enqueued failed request for retry in "+r;navigator.onLine||(s+=" (Browser is offline)"),Re.warn(s),this.ze||(this.ze=!0,this.Ve())}Ve(){if(this.Je&&clearTimeout(this.Je),this.Me.length===0)return this.ze=!1,void(this.Je=void 0);this.Je=setTimeout((()=>{this.Be&&this.Me.length>0&&this.Lt(),this.Ve()}),this.He)}Lt(){var t=Date.now(),n=[],r=this.Me.filter((s=>s.retryAt<t||(n.push(s),!1)));if(this.Me=n,r.length>0)for(var{requestOptions:i}of r)this.retriableRequest(i)}unload(){for(var{requestOptions:t}of(this.Je&&(clearTimeout(this.Je),this.Je=void 0),this.ze=!1,Te(fe)||(this.qe&&(fe.removeEventListener("online",this.qe),this.qe=void 0),this.We&&(fe.removeEventListener("offline",this.We),this.We=void 0)),this.Me))try{this._instance._send_request(Ie({},t,{transport:"sendBeacon"}))}catch(n){Re.error(n)}this.Me=[]}}class n3e{constructor(t){this.Ke=()=>{var n,r,i,s;this.Ye||(this.Ye={});var o=this.scrollElement(),a=this.scrollY(),c=o?Math.max(0,o.scrollHeight-o.clientHeight):0,d=a+(o?.clientHeight||0),f=o?.scrollHeight||0;this.Ye.lastScrollY=Math.ceil(a),this.Ye.maxScrollY=Math.max(a,(n=this.Ye.maxScrollY)!==null&&n!==void 0?n:0),this.Ye.maxScrollHeight=Math.max(c,(r=this.Ye.maxScrollHeight)!==null&&r!==void 0?r:0),this.Ye.lastContentY=d,this.Ye.maxContentY=Math.max(d,(i=this.Ye.maxContentY)!==null&&i!==void 0?i:0),this.Ye.maxContentHeight=Math.max(f,(s=this.Ye.maxContentHeight)!==null&&s!==void 0?s:0)},this._instance=t}getContext(){return this.Ye}resetContext(){var t=this.Ye;return setTimeout(this.Ke,0),t}startMeasuringScrollPosition(){Xn(fe,"scroll",this.Ke,{capture:!0}),Xn(fe,"scrollend",this.Ke,{capture:!0}),Xn(fe,"resize",this.Ke)}scrollElement(){if(!this._instance.config.scroll_root_selector)return fe?.document.documentElement;var t=Gt(this._instance.config.scroll_root_selector)?this._instance.config.scroll_root_selector:[this._instance.config.scroll_root_selector];for(var n of t){var r=fe?.document.querySelector(n);if(r)return r}}scrollY(){if(this._instance.config.scroll_root_selector){var t=this.scrollElement();return t&&t.scrollTop||0}return fe&&(fe.scrollY||fe.pageYOffset||fe.document.documentElement.scrollTop)||0}scrollX(){if(this._instance.config.scroll_root_selector){var t=this.scrollElement();return t&&t.scrollLeft||0}return fe&&(fe.scrollX||fe.pageXOffset||fe.document.documentElement.scrollLeft)||0}}var r3e=e=>XH(e?.config.mask_personal_data_properties,e?.config.custom_personal_data_properties);class ND{constructor(t,n,r,i){this.Xe=s=>{var o=this.Qe();if(!o||o.sessionId!==s){var a={sessionId:s,props:this.Ze(this._instance)};this.tr.register({[EC]:a})}},this._instance=t,this.ir=n,this.tr=r,this.Ze=i||r3e,this.ir.onSessionId(this.Xe)}Qe(){return this.tr.props[EC]}getSetOnceProps(){var t,n=(t=this.Qe())==null?void 0:t.props;return n?"r"in n?QH(n):{$referring_domain:n.referringDomain,$pathname:n.initialPathName,utm_source:n.utm_source,utm_campaign:n.utm_campaign,utm_medium:n.utm_medium,utm_content:n.utm_content,utm_term:n.utm_term}:{}}getSessionProps(){var t={};return dn(VR(this.getSetOnceProps()),((n,r)=>{r==="$current_url"&&(r="url"),t["$session_entry_"+dC(r)]=n})),t}}var OE=Tn("[SessionId]");class $D{on(t,n){return this.er.on(t,n)}constructor(t,n,r){var i;if(this.rr=[],this.sr=void 0,this.er=new JR,this.nr=(f,p)=>!(!fd(f)||!fd(p))&&Math.abs(f-p)>
vendor: 2,710 bytes, line 278
278this.sessionTimeoutMs,!t.persistence)throw new Error("SessionIdManager requires a PostHogPersistence instance");if(t.config.cookieless_mode==="always")throw new Error('SessionIdManager cannot be used with cookieless_mode="always"');this.R=t.config,this.tr=t.persistence,this.ar=void 0,this.lr=void 0,this._sessionStartTimestamp=null,this._sessionActivityTimestamp=null,this.ur=n||ul,this.hr=r||ul;var s=this.R.persistence_name||this.R.token,o=this.R.session_idle_timeout_seconds||1800;if(this._sessionTimeoutMs=1e3*Js(o,60,36e3,OE.createLogger("session_idle_timeout_seconds"),1800),t.register({$configured_session_timeout_ms:this._sessionTimeoutMs}),this.dr(),this.vr="ph_"+s+"_window_id",this.cr="ph_"+s+"_primary_window_exists",this.pr()){var a=br.W(this.vr),c=br.W(this.cr);a&&!c?this.ar=a:br.V(this.vr),br.G(this.cr,!0)}if((i=this.R.bootstrap)!=null&&i.sessionID)try{var d=(f=>{var p=f.replace(/-/g,"");if(p.length!==32)throw new Error("Not a valid UUID");if(p[12]!=="7")throw new Error("Not a UUIDv7");return parseInt(p.substring(0,12),16)})(this.R.bootstrap.sessionID);this._r(this.R.bootstrap.sessionID,new Date().getTime(),d)}catch(f){OE.error("Invalid sessionID in bootstrap",f)}this.gr()}get sessionTimeoutMs(){return this._sessionTimeoutMs}onSessionId(t){return Te(this.rr)&&(this.rr=[]),this.rr.push(t),this.lr&&t(this.lr,this.ar),()=>{this.rr=this.rr.filter((n=>n!==t))}}pr(){return this.R.persistence!=="memory"&&!this.tr.ki&&br.H()}mr(t){t!==this.ar&&(this.ar=t,this.pr()&&br.G(this.vr,t))}br(){return this.ar?this.ar:this.pr()?br.W(this.vr):null}_r(t,n,r){t===this.lr&&n===this._sessionActivityTimestamp&&r===this._sessionStartTimestamp||(this._sessionStartTimestamp=r,this._sessionActivityTimestamp=n,this.lr=t,this.tr.register({[l_]:[n,t,r]}))}yr(){var t=this.tr.props[l_];return Gt(t)&&t.length===2&&t.push(t[0]),t||[0,null,0]}resetSessionId(){this._r(null,null,null)}destroy(){clearTimeout(this.wr),this.wr=void 0,this.sr&&fe&&(fe.removeEventListener("beforeunload",this.sr,{capture:!1}),this.sr=void 0),this.rr=[]}gr(){this.sr=()=>{this.pr()&&br.V(this.cr)},Xn(fe,"beforeunload",this.sr,{capture:!1})}checkAndGetSessionAndWindowId(t,n){if(t===void 0&&(t=!1),n===void 0&&(n=null),this.R.cookieless_mode==="always")throw new Error('checkAndGetSessionAndWindowId should not be called with cookieless_mode="always"');var r=n||new Date().getTime(),[i,s,o]=this.yr(),a=this.br(),c=fd(o)&&Math.abs(r-o)>864e5,d=!1,f=!s,p=!f&&!t&&this.nr(r,i);f||p||c?(s=this.ur(),a=this.hr(),OE.info("new session ID generated",{sessionId:s,windowId:a,changeReason:{noSessionId:f,activityTimeout:p,sessionPastMaximumLength:c}}),o=r,d=!0):a||(a=this.hr(),d=!0);var m=fd(i)&&t&&!c?i:r,v=fd(o)?o:new Date().getTime();
278return this.mr(a),this._r(s,m,v),t||this.dr(),d&&this.rr.forEach((w=>w(s,a,d?{noSessionId:f,activityTimeout:p,sessionPastMaximumLength:c}:void 0))),{sessionId:s,windowId:a,sessionStartTimestamp:v,changeReason:d?{noSessionId:f,activityTimeout:p,sessionPastMaximumLength:c}:void 0,lastActivityTimestamp:i}}dr(){clearTimeout(this.wr),this.wr=setTimeout((()=>{var[t]=this.yr();if(this.nr(new Date().getTime(),t)){var n=this.lr;this.resetSessionId(),this.er.emit("forcedIdleReset",{idleSessionId:n})}}),1.1*this.sessionTimeoutMs)}}var i3e=["$set_once","$set"],Wa=Tn("[SiteApps]");class s3e{constructor(t){this._instance=t,this.$r=[],this.apps={}}get isEnabled(){return!!this._instance.config.opt_in_site_apps}Er(t,n){if(n){var r=this.globalsForEvent(n);this.$r.push(r),this.$r.length>1e3&&(this.$r=this.$r.slice(10))}}get siteAppLoaders(){var t;return(t=Xe._POSTHOG_REMOTE_CONFIG)==null||(t=t[this._instance.config.token])==null?void 0:t.siteApps}init(){if(this.isEnabled){var t=this._instance._addCaptureHook(this.Er.bind(this));this.Sr=()=>{t(),this.$r=[],this.Sr=void 0}}}globalsForEvent(t){var n,r,i,s,o,a,c;if(!t)throw new Error("Event payload is required");var d={},f=this._instance.get_property("$groups")||[],p=this._instance.get_property("$stored_group_properties")||{};for(var[m,v]of Object.entries(p))d[m]={id:f[m],type:m,properties:v};var{$set_once:w,$set:_}=t;return{event:Ie({},rH(t,i3e),{properties:Ie({},t.properties,_?{$set:Ie({},(n=(r=t.properties)==null?void 0:r.$set)!==null&&n!==void 0?n:{},_)}:{},w?{$set_once:Ie({},(i=(s=t.properties)==null?void 0:s.$set_once)!==null&&i!==void 0?i:{},w)}:{}),elements_chain:(o=(a=t.properties)==null?void 0:a.$elements_chain)!==null&&o!==void 0?o:"",distinct_id:(c=t.properties)==null?void 0:c.distinct_id}),person:{properties:this._instance.get_property("$stored_person_properties")},groups:d}}setupSiteApp(t){var n=this.apps[t.id],r=()=>{var a;!n.errored&&this.$r.length&&(Wa.info("Processing "+this.$r.length+" events for site app with id "+t.id),this.$r.forEach((c=>n.processEvent==null?void 0:n.processEvent(c))),n.processedBuffer=!0),Object.values(this.apps).every((c=>c.processedBuffer||c.errored))&&((a=this.Sr)==null||a.call(this))},i=!1,s=a=>{n.errored=!a,n.loaded=!0,Wa.info("Site app with id "+t.id+" "+(a?"loaded":"errored")),i&&r()};try{var{processEvent:o}=t.init({posthog:this._instance,callback:a=>{s(a)}});o&&(n.processEvent=o),i=!0}catch(a){Wa.error("Error while initializing PostHog app with config id "+t.id,a),s(!1)}if(i&&n.loaded)try{r()}catch(a){Wa.error("Error while processing buffered events PostHog app with config id "+t.id,a),n.errored=!0}}kr(){var t=this.siteAppLoaders||[];for(var n of t)this.apps[n.id]={id:n.id,loaded:!1,errored:!1,processedBuffer:!1};for(var r of t)this.setupSiteApp(r)}Pr(t){if(Object.keys(this.apps).length!==0){var n=this.globalsForEvent(t);for(var r of Object.values(this.apps))try{r.processEvent==null||r.processEvent(n)}catch(i){Wa.error("Error while processing event "+t.event+" for site app "+r.id,i)}}}onRemoteConfig(t){var n,r,i,s=this;if((n=this.siteAppLoaders)!=null&&n.length)return this.isEnabled?(this.kr(),void this._instance.on("eventCaptured",(d=>this.Pr(d)))):void Wa.error('PostHog site apps are disabled. Enable the "opt_in_site_apps" config to proceed.');if((r=this.Sr)==null||r.call(this),(i=t.siteApps)!=null&&i.length)if(this.isEnabled){var o=function(d){var f;Xe["__$$ph_site_app_"+d]=s._instance,(f=Xe.__PosthogExtensions__)==null||f.loadSiteApp==null||f.loadSiteApp(s._instance,c,(p=>{if(p)return Wa.error("Error while initializing PostHog app with config id "+d,p)}))};for(var{id:a,url:c}of t.siteApps)o(a)}else Wa.error('PostHog site apps are disabled. Enable the "opt_in_site_apps" config to proceed.')}}var uV=function(e,t){if(!e)return!1;var n=e.userAgent;if(n&&K8(n,t))return!0;try{var r=e?.userAgentData;if(r!=null&&r.brands&&r.brands.some((i=>K8(i?.brand,t))))return!0}catch{}return!!e.webdriver},dp=(function(e){return e.US="us",e.EU="eu",e.CUSTOM="custom",e})({}),jD="i.posthog.com";class o3e{constructor(t){this.Tr={},this.instance=t}get apiHost(){var t=this.instance.config.api_host.trim().replace(/\/$/,"");return t==="https://app.posthog.com"?"https://us.i.posthog.com":t}get flagsApiHost(){var t=this.instance.config.flags_api_host;return t?t.trim().replace(/\/$/,""):this.apiHost}get uiHost(){var t,n=(t=this.instance.config.ui_host)==null?void 0:t.replace(/\/$/,"");return n||(n=this.apiHost.replace("."+jD,".posthog.com")),n==="https://app.posthog.com"?"https://us.posthog.com":n}
278get region(){return this.Tr[this.apiHost]||(/https:\/\/(app|us|us-assets)(\.i)?\.posthog\.com/i.test(this.apiHost)?this.Tr[this.apiHost]=dp.US:/https:\/\/(eu|eu-assets)(\.i)?\.posthog\.com/i.test(this.apiHost)?this.Tr[this.apiHost]=dp.EU:this.Tr[this.apiHost]=dp.CUSTOM),this.Tr[this.apiHost]}endpointFor(t,n){if(n===void 0&&(n=""),n&&(n=n[0]==="/"?n:"/"+n),t==="ui")return this.uiHost+n;if(t==="flags")return this.flagsApiHost+n;if(this.region===dp.CUSTOM)return this.apiHost+n;var r=jD+n;switch(t){case"assets":return"https://"+this.region+"-assets."+r;case"api":return"https://"+this.region+"."+r}}}var a3e={icontains:(e,t)=>!!fe&&t.href.toLowerCase().indexOf(e.toLowerCase())>-1,not_icontains:(e,t)=>!!fe&&t.href.toLowerCase().indexOf(e.toLowerCase())===-1,regex:(e,t)=>!!fe&&__(t.href,e),not_regex:(e,t)=>!!fe&&!__(t.href,e),exact:(e,t)=>t.href===e,is_not:(e,t)=>t.href!==e};class Ar{constructor(t){var n=this;this.getWebExperimentsAndEvaluateDisplayLogic=function(r){r===void 0&&(r=!1),n.getWebExperiments((i=>{Ar.Ir("retrieved web experiments from the server"),n.Cr=new Map,i.forEach((s=>{if(s.feature_flag_key){var o;n.Cr&&(Ar.Ir("setting flag key ",s.feature_flag_key," to web experiment ",s),(o=n.Cr)==null||o.set(s.feature_flag_key,s));var a=n._instance.getFeatureFlag(s.feature_flag_key);Zn(a)&&s.variants[a]&&n.Rr(s.name,a,s.variants[a].transforms)}else if(s.variants)for(var c in s.variants){var d=s.variants[c];Ar.Fr(d)&&n.Rr(s.name,c,d.transforms)}}))}),r)},this._instance=t,this._instance.onFeatureFlags((r=>{this.onFeatureFlags(r)}))}onFeatureFlags(t){if(this._is_bot())Ar.Ir("Refusing to render web experiment since the viewer is a likely bot");else if(!this._instance.config.disable_web_experiments){if(At(this.Cr))return this.Cr=new Map,this.loadIfEnabled(),void this.previewWebExperiment();Ar.Ir("applying feature flags",t),t.forEach((n=>{var r;if(this.Cr&&(r=this.Cr)!=null&&r.has(n)){var i,s=this._instance.getFeatureFlag(n),o=(i=this.Cr)==null?void 0:i.get(n);s&&o!=null&&o.variants[s]&&this.Rr(o.name,s,o.variants[s].transforms)}}))}}previewWebExperiment(){var t=Ar.getWindowLocation();if(t!=null&&t.search){var n=p_(t?.search,"__experiment_id"),r=p_(t?.search,"__experiment_variant");n&&r&&(Ar.Ir("previewing web experiments "+n+" && "+r),this.getWebExperiments((i=>{this.Or(parseInt(n),r,i)}),!1,!0))}}loadIfEnabled(){this._instance.config.disable_web_experiments||this.getWebExperimentsAndEvaluateDisplayLogic()}getWebExperiments(t,n,r){if(this._instance.config.disable_web_experiments&&!r)return t([]);var i=this._instance.get_property("$web_experiments");if(i&&!n)return t(i);this._instance._send_request({url:this._instance.requestRouter.endpointFor("api","/api/web_experiments/?token="+this._instance.config.token),method:"GET",callback:s=>{if(s.statusCode!==200||!s.json)return t([]);var o=s.json.experiments||[];return t(o)}})}Or(t,n,r){var i=r.filter((s=>s.id===t));i&&i.length>0&&(Ar.Ir("Previewing web experiment ["+i[0].name+"] with variant ["+n+"]"),this.Rr(i[0].name,n,i[0].variants[n].transforms))}static Fr(t){return!At(t.conditions)&&Ar.Mr(t)&&Ar.Ar(t)}static Mr(t){var n;if(At(t.conditions)||At((n=t.conditions)==null?void 0:n.url))return!0;var r,i,s,o=Ar.getWindowLocation();return!!o&&((r=t.conditions)==null||!r.url||a3e[(i=(s=t.conditions)==null?void 0:s.urlMatchType)!==null&&i!==void 0?i:"icontains"](t.conditions.url,o))}
278static getWindowLocation(){return fe?.location}static Ar(t){var n;if(At(t.conditions)||At((n=t.conditions)==null?void 0:n.utm))return!0;var r=GH();if(r.utm_source){var i,s,o,a,c,d,f,p,m=(i=t.conditions)==null||(i=i.utm)==null||!i.utm_campaign||((s=t.conditions)==null||(s=s.utm)==null?void 0:s.utm_campaign)==r.utm_campaign,v=(o=t.conditions)==null||(o=o.utm)==null||!o.utm_source||((a=t.conditions)==null||(a=a.utm)==null?void 0:a.utm_source)==r.utm_source,w=(c=t.conditions)==null||(c=c.utm)==null||!c.utm_medium||((d=t.conditions)==null||(d=d.utm)==null?void 0:d.utm_medium)==r.utm_medium,_=(f=t.conditions)==null||(f=f.utm)==null||!f.utm_term||((p=t.conditions)==null||(p=p.utm)==null?void 0:p.utm_term)==r.utm_term;return m&&w&&_&&v}return!1}static Ir(t){for(var n=arguments.length,r=new Array(n>1?n-1:0),i=1;i<n;i++)r[i-1]=arguments[i];Re.info("[WebExperiments] "+t,r)}Rr(t,n,r){this._is_bot()?Ar.Ir("Refusing to render web experiment since the viewer is a likely bot"):n!=="control"?r.forEach((i=>{if(i.selector){var s;Ar.Ir("applying transform of variant "+n+" for experiment "+t+" ",i);var o=(s=document)==null?void 0:s.querySelectorAll(i.selector);o?.forEach((a=>{var c=a;i.html&&(c.innerHTML=i.html),i.css&&c.setAttribute("style",i.css)}))}})):Ar.Ir("Control variants leave the page unmodified.")}_is_bot(){return ki&&this._instance?uV(ki,this._instance.config.custom_blocked_useragents):void 0}}var l3e=Tn("[PostHog ExternalIntegrations]"),c3e={intercom:"intercom-integration",crispChat:"crisp-chat-integration"};class u3e{constructor(t){this._instance=t}it(t,n){var r;(r=Xe.__PosthogExtensions__)==null||r.loadExternalDependency==null||r.loadExternalDependency(this._instance,t,(i=>{if(i)return l3e.error("failed to load script",i);n()}))}startIfEnabledOrStop(){var t=this,n=function(o){var a,c,d;!i||(a=Xe.__PosthogExtensions__)!=null&&(a=a.integrations)!=null&&a[o]||t.it(c3e[o],(()=>{var f;(f=Xe.__PosthogExtensions__)==null||(f=f.integrations)==null||(f=f[o])==null||f.start(t._instance)})),!i&&(c=Xe.__PosthogExtensions__)!=null&&(c=c.integrations)!=null&&c[o]&&((d=Xe.__PosthogExtensions__)==null||(d=d.integrations)==null||(d=d[o])==null||d.stop())};for(var[r,i]of Object.entries((s=this._instance.config.integrations)!==null&&s!==void 0?s:{})){var s;n(r)}}}Tn("[SessionRecording]");var MC="[SessionRecording]",od=Tn(MC);class FD{get started(){var t;return!((t=this.jr)==null||!t.isStarted)}get status(){return this.jr?this.jr.status:this.Dr&&!this.Lr?"disabled":"lazy_loading"}constructor(t){if(this._forceAllowLocalhostNetworkCapture=!1,this.Dr=!1,this.Nr=!1,this.Ur=void 0,this._instance=t,!this._instance.sessionManager)throw od.error("started without valid sessionManager"),new Error(MC+" started without valid sessionManager. This is a bug.");if(this._instance.config.cookieless_mode==="always")throw new Error(MC+' cannot be used with cookieless_mode="always"')}get Lr(){var t,n=!((t=this._instance.get_property(uv))==null||!t.enabled),r=!this._instance.config.disable_session_recording,i=this._instance.config.disable_session_recording||this._instance.consent.isOptedOut();return fe&&n&&r&&!i}startIfEnabledOrStop(t){var n;if(!this.Lr||(n=this.jr)==null||!n.isStarted){var r=!Te(Object.assign)&&!Te(Array.from);this.Lr&&r?(this.zr(t),od.info("starting")):this.stopRecording()}}zr(t){var n,r,i;this.Lr&&(Xe!=null&&(n=Xe.__PosthogExtensions__)!=null&&(n=n.rrweb)!=null&&n.record&&(r=Xe.__PosthogExtensions__)!=null&&r.initSessionRecording?this.Hr(t):(i=Xe.__PosthogExtensions__)==null||i.loadExternalDependency==null||i.loadExternalDependency(this._instance,this.Br,(s=>{if(s)return od.error("could not load recorder",s);this.Hr(t)})))}stopRecording(){var t,n;(t=this.Ur)==null||t.call(this),this.Ur=void 0,(n=this.jr)==null||n.stop()}qr(){var t;(t=this._instance.persistence)==null||t.unregister(PH)}Wr(t){if(this._instance.persistence){var n,r,i=this._instance.persistence,s=()=>{var o=t.sessionRecording===!1?void 0:t.sessionRecording,a=o?.sampleRate,c=At(a)?null:parseFloat(a);At(c)&&this.qr();var d=o?.minimumDurationMilliseconds;i.register({[uv]:Ie({cache_timestamp:Date.now(),enabled:!!o},o,{networkPayloadCapture:Ie({capturePerformance:t.capturePerformance},o?.networkPayloadCapture),canvasRecording:{enabled:o?.recordCanvas,fps:o?.canvasFps,quality:o?.canvasQuality},sampleRate:c,minimumDurationMilliseconds:Te(d)?null:d,endpoint:o?.endpoint,triggerMatchType:o?.triggerMatchType,masking:o?.masking,urlTriggers:o?.urlTriggers})})};s(),(n=this.Ur)==null||n.call(this),this.Ur=(r=this._instance.sessionManager)==null?void 0:r.onSessionId(s)}}onRemoteConfig(t){"sessionRecording"in t?t.sessionRecording!==!1?(this.Nr=!1,this.Wr(t),this.Dr=!0,this.startIfEnabledOrStop()):this.Dr=!0:od.info("skipping remote config with no sessionRecording",t)}log(t,n){var r;n===void 0&&(n="log"),(r=this.jr)!=null&&r.log?this.jr.log(t,n):od.warn("log called before recorder was ready")}get Br(){var t,n,r=(t=this._instance)==null||(t=t.persistence)==null?void 0:t.get_property(uv);return(r==null||(n=r.scriptConfig)==null?void 0:n.script)||"lazy-recorder"}Gr(){var t,n=this._instance.get_property(uv);if(!n)return!1;var r=(t=(typeof n=="object"?n:JSON.parse(n)).cache_timestamp)!==null&&t!==void 0?t:Date.now();return Date.now()-r<=3e5}Hr(t){var n,r;if((n=Xe.__PosthogExtensions__)==null||!n.initSessionRecording)throw Error("Called on script loaded before session recording is available");this.jr||(this.jr=(r=Xe.__PosthogExtensions__)==null?void 0:r.initSessionRecording(this._instance),this.jr._forceAllowLocalhostNetworkCapture=this._forceAllowLocalhostNetworkCapture),this.Gr()?this.jr.start(t):this.Nr||(this.Nr=!0,od.info("persisted remote config is stale, requesting fresh config before starting"),new cV(this._instance).load())}onRRwebEmit(t){var n;(n=this.jr)==null||n.onRRwebEmit==null||n.onRRwebEmit(t)}overrideLinkedFlag(){var t,n;this.jr||(n=this._instance.persistence)==null||n.register({$replay_override_linked_flag:!0}),(t=this.jr)==null||t.overrideLinkedFlag()}overrideSampling(){var t,n;this.jr||(n=this._instance.persistence)==null||n.register({$replay_override_sampling:!0}),(t=this.jr)==null||t.overrideSampling()}overrideTrigger(t){var n,r;this.jr||(r=this._instance.persistence)==null||r.register({[t==="url"?"$replay_override_url_trigger":"$replay_override_event_trigger"]:!0}
278),(n=this.jr)==null||n.overrideTrigger(t)}get sdkDebugProperties(){var t;return((t=this.jr)==null?void 0:t.sdkDebugProperties)||{$recording_status:this.status}}tryAddCustomEvent(t,n){var r;return!((r=this.jr)==null||!r.tryAddCustomEvent(t,n))}}var Tp={},AE=0,DC=()=>{},hd="posthog",dV=!PPe&&oi?.indexOf("MSIE")===-1&&oi?.indexOf("Mozilla")===-1,UD=e=>{var t;return Ie({api_host:"https://us.i.posthog.com",flags_api_host:null,ui_host:null,token:"",autocapture:!0,cross_subdomain_cookie:DRe(ke?.location),persistence:"localStorage+cookie",persistence_name:"",cookie_persisted_properties:[],loaded:DC,save_campaign_params:!0,custom_campaign_params:[],custom_blocked_useragents:[],save_referrer:!0,capture_pageleave:"if_capture_pageview",defaults:e??"unset",__preview_deferred_init_extensions:!1,debug:Er&&Zn(Er?.search)&&Er.search.indexOf("__posthog_debug=true")!==-1||!1,cookie_expiration:365,upgrade:!1,disable_session_recording:!1,disable_persistence:!1,disable_web_experiments:!0,disable_surveys:!1,disable_surveys_automatic_display:!1,disable_conversations:!1,disable_product_tours:!1,disable_external_dependency_loading:!1,enable_recording_console_log:void 0,secure_cookie:(fe==null||(t=fe.location)==null?void 0:t.protocol)==="https:",ip:!1,opt_out_capturing_by_default:!1,opt_out_persistence_by_default:!1,opt_out_useragent_filter:!1,opt_out_capturing_persistence_type:"localStorage",consent_persistence_name:null,opt_out_capturing_cookie_prefix:null,opt_in_site_apps:!1,property_denylist:[],respect_dnt:!1,sanitize_properties:null,request_headers:{},request_batching:!0,properties_string_max_length:65535,mask_all_element_attributes:!1,mask_all_text:!1,mask_personal_data_properties:!1,custom_personal_data_properties:[],advanced_disable_flags:!1,advanced_disable_decide:!1,advanced_disable_feature_flags:!1,advanced_disable_feature_flags_on_first_load:!1,advanced_only_evaluate_survey_feature_flags:!1,advanced_enable_surveys:!1,advanced_disable_toolbar_metrics:!1,feature_flag_request_timeout_ms:3e3,surveys_request_timeout_ms:1e4,on_request_error:n=>{var r="Bad HTTP status: "+n.statusCode+" "+n.text;Re.error(r)},get_device_id:n=>n,capture_performance:void 0,name:"posthog",bootstrap:{},disable_compression:!1,session_idle_timeout_seconds:1800,person_profiles:"identified_only",before_send:void 0,request_queue_config:{flush_interval_ms:IC},error_tracking:{},_onCapture:DC,__preview_eager_load_replay:!1},(n=>({rageclick:!(n&&n>="2025-11-30")||{content_ignorelist:!0},capture_pageview:!(n&&n>="2025-05-24")||"history_change",session_recording:n&&n>="2025-11-30"?{strictMinimumDuration:!0}:{},external_scripts_inject_target:n&&n>="2026-01-30"?"head":"body",internal_or_test_user_hostname:n&&n>="2026-01-30"?/^(localhost|127\.0\.0\.1)$/:void 0}))(e))},zD=e=>{var t={};Te(e.process_person)||(t.person_profiles=e.process_person),Te(e.xhr_headers)||(t.request_headers=e.xhr_headers),Te(e.cookie_name)||(t.persistence_name=e.cookie_name),Te(e.disable_cookie)||(t.disable_persistence=e.disable_cookie),Te(e.store_google)||(t.save_campaign_params=e.store_google),Te(e.verbose)||(t.debug=e.verbose);var n=jn({},t,e);return Gt(e.property_blacklist)&&(Te(e.property_denylist)?n.property_denylist=e.property_blacklist:Gt(e.property_denylist)?n.property_denylist=[...e.property_blacklist,...e.property_denylist]:Re.error("Invalid value for property_denylist config: "+e.property_denylist)),n};class d3e{constructor(){this.__forceAllowLocalhost=!1}get Vr(){return this.__forceAllowLocalhost}set Vr(t){Re.error("WebPerformanceObserver is deprecated and has no impact on network capture. Use `_forceAllowLocalhostNetworkCapture` on `posthog.sessionRecording`"),this.__forceAllowLocalhost=t}}class mm{get decideEndpointWasHit(){var t,n;return(t=(n=this.featureFlags)==null?void 0:n.hasLoadedFlags)!==null&&t!==void 0&&t}get flagsEndpointWasHit(){var t,n;return(t=(n=this.featureFlags)==null?void 0:n.hasLoadedFlags)!==null&&t!==void 0&&t}constructor(){this.webPerformance=new d3e,this.Jr=!1,this.version=Mo.LIB_VERSION,this.mi=new JR,this._calculate_event_properties=this.calculateEventProperties.bind(this),this.config=UD(),this.SentryIntegration=cPe,this.sentryIntegration=t=>(function(n,r){var i=KH(n,r);return{name:qH,processEvent:s=>i(s)}})(this,t),this.__request_queue=[],this.__loaded=!1,this.analyticsDefaultEndpoint="/e/",this.Kr=!1,this.Yr=null,this.Xr=null,this.Qr=null,this.featureFlags=new UPe(this),this.toolbar=ne
278w dPe(this),this.scrollManager=new n3e(this),this.pageViewManager=new SD(this),this.surveys=new YPe(this),this.conversations=new JPe(this),this.logs=new ZPe(this),this.experiments=new Ar(this),this.exceptions=new OPe(this),this.rateLimiter=new XPe(this),this.requestRouter=new o3e(this),this.consent=new rPe(this),this.externalIntegrations=new u3e(this),this.people={set:(t,n,r)=>{var i=Zn(t)?{[t]:n}:t;this.setPersonProperties(i),r?.({})},set_once:(t,n,r)=>{var i=Zn(t)?{[t]:n}:t;this.setPersonProperties(void 0,i),r?.({})}},this.on("eventCaptured",(t=>Re.info('send "'+t?.event+'"',t)))}init(t,n,r){if(r&&r!==hd){var i,s=(i=Tp[r])!==null&&i!==void 0?i:new mm;return s._init(t,n,r),Tp[r]=s,Tp[hd][r]=s,s}return this._init(t,n,r)}_init(t,n,r){var i;if(n===void 0&&(n={}),Te(t)||fC(t))return Re.critical("PostHog was initialized without a token. This likely indicates a misconfiguration. Please check the first argument passed to posthog.init()"),this;if(this.__loaded)return console.warn("[PostHog.js]","You have already initialized PostHog! Re-initializing is a no-op"),this;this.__loaded=!0,this.config={},n.debug=this.Zr(n.debug),this.ts=n,this.es=[],n.person_profiles?this.Xr=n.person_profiles:n.process_person&&(this.Xr=n.process_person),this.set_config(jn({},UD(n.defaults),zD(n),{name:r,token:t})),this.config.on_xhr_error&&Re.error("on_xhr_error is deprecated. Use on_request_error instead"),this.compression=n.disable_compression?void 0:$o.GZipJS;var s=this.rs();this.persistence=new kE(this.config,s),this.sessionPersistence=this.config.persistence==="sessionStorage"||this.config.persistence==="memory"?this.persistence:new kE(Ie({},this.config,{persistence:"sessionStorage"}),s);var o=Ie({},this.persistence.props),a=Ie({},this.sessionPersistence.props);this.register({$initialization_time:new Date().toISOString()}),this.ss=new QPe((P=>this.ns(P)),this.config.request_queue_config),this.os=new t3e(this),this.__request_queue=[];var c=this.config.cookieless_mode==="always"||this.config.cookieless_mode==="on_reject"&&this.consent.isExplicitlyOptedOut();if(c||(this.sessionManager=new $D(this),this.sessionPropsManager=new ND(this,this.sessionManager,this.persistence)),this.config.__preview_deferred_init_extensions?(Re.info("Deferring extension initialization to improve startup performance"),setTimeout((()=>{this.ls(c)}),0)):(Re.info("Initializing extensions synchronously"),this.ls(c)),Mo.DEBUG=Mo.DEBUG||this.config.debug,Mo.DEBUG&&Re.info("Starting in debug mode",{this:this,config:n,thisC:Ie({},this.config),p:o,s:a}),((i=n.bootstrap)==null?void 0:i.distinctID)!==void 0){var d,f,p=this.config.get_device_id(ul()),m=(d=n.bootstrap)!=null&&d.isIdentifiedID?p:n.bootstrap.distinctID;this.persistence.set_property(Do,(f=n.bootstrap)!=null&&f.isIdentifiedID?"identified":"anonymous"),this.register({distinct_id:n.bootstrap.distinctID,$device_id:m})}if(this.us()){var v,w,_=Object.keys(((v=n.bootstrap)==null?void 0:v.featureFlags)||{}).filter((P=>{var D;return!((D=n.bootstrap)==null||(D=D.featureFlags)==null||!D[P])})).reduce(((P,D)=>{var F;return P[D]=((F=n.bootstrap)==null||(F=F.featureFlags)==null?void 0:F[D])||!1,P}),{}),b=Object.keys(((w=n.bootstrap)==null?void 0:w.featureFlagPayloads)||{}).filter((P=>_[P])).reduce(((P,D)=>{var F,R;return(F=n.bootstrap)!=null&&(F=F.featureFlagPayloads)!=null&&F[D]&&(P[D]=(R=n.bootstrap)==null||(R=R.featureFlagPayloads)==null?void 0:R[D]),P}),{});this.featureFlags.receivedFeatureFlags({featureFlags:_,featureFlagPayloads:b})}if(c)this.register_once({distinct_id:Bh,$device_id:null},"");else if(!this.get_distinct_id()){var C=this.config.get_device_id(ul());this.register_once({distinct_id:C,$device_id:C},""),this.persistence.set_property(Do,"anonymous")}return Xn(fe,"onpagehide"in self?"pagehide":"unload",this._handle_unload.bind(this),{passive:!1}),this.toolbar.maybeLoadToolbar(),n.segment?lPe(this,(()=>this.hs())):this.hs(),Uo(this.config._onCapture)&&this.config._onCapture!==DC&&(Re.warn("onCapture is deprecated. Please use `before_send` instead"),this.on("eventCaptured",(P=>this.config._onCapture(P.event,P)))),this.config.ip&&Re.warn('The `ip` config option has NO EFFECT AT ALL and has been deprecated. Use a custom transformation or "Discard IP data" project setting instead. See https://posthog.com/tutorials/web-redact-properties#hiding-customer-ip-address for more information.'),this}ls(t){var n=performance.now();this.historyAutocapture=new aPe(this),this.historyAutocapture.startIfEnabled();var r=[];r.push((()=>{new hPe(this).startIfEnabledOrStop()})),r.push((()=>{var i;this.siteApps=new s3e(this),(i=this.siteApps)==null||i.init()})),t||r.push((()=>{this.sessionRecording=new FD(this),this.sessionRecording.startIfEnabledOrStop()})),this.config.disable_scroll_properties||r.push((()=>{this.scrollManager.startMeasuringScrollPosition()})),r.push((()=>{this.autocapture=new YRe(this),this.autocapture.startIfEnabled()})),r.push((()=>{this.surveys.loadIfEnabled()})),r.push((()=>{this.logs.loadIfEnabled()})),r.push((()=>{this.conversations.loadIfEnabled()})),r.push((()=>{this.productTours=new BPe(this),this.productTours.loadIfEnabled()})),r.push((()=>{this.heatmaps=new wPe(this),this.heatmaps.startIfEnabled()})),r.push((()=>{this.webVitalsAutocapture=new vPe(this)})),r.push((()=>{this.exceptionObserver=new oPe(this),this.exceptionObserver.startIfEnabledOrStop()})),r.push((()=>{this.deadClicksAutocapture=new WH(this,sPe),this.deadClicksAutocapture.startIfEnabledOrStop()})),r.push((()=>
278{if(this.ds){var i=this.ds;this.ds=void 0,this.Ce(i)}})),this.vs(r,n)}vs(t,n){for(;t.length>0;){if(this.config.__preview_deferred_init_extensions&&performance.now()-n>=30&&t.length>0)return void setTimeout((()=>{this.vs(t,n)}),0);var r=t.shift();if(r)try{r()}catch(s){Re.error("Error initializing extension:",s)}}var i=Math.round(performance.now()-n);this.register_for_session({$sdk_debug_extensions_init_method:this.config.__preview_deferred_init_extensions?"deferred":"synchronous",$sdk_debug_extensions_init_time_ms:i}),this.config.__preview_deferred_init_extensions&&Re.info("PostHog extensions initialized ("+i+"ms)")}Ce(t){var n,r,i,s,o,a,c,d,f;if(!ke||!ke.body)return Re.info("document not ready yet, trying again in 500 milliseconds..."),void setTimeout((()=>{this.Ce(t)}),500);this.config.__preview_deferred_init_extensions&&(this.ds=t),this.compression=void 0,t.supportedCompression&&!this.config.disable_compression&&(this.compression=Pt(t.supportedCompression,$o.GZipJS)?$o.GZipJS:Pt(t.supportedCompression,$o.Base64)?$o.Base64:void 0),(n=t.analytics)!=null&&n.endpoint&&(this.analyticsDefaultEndpoint=t.analytics.endpoint),this.set_config({person_profiles:this.Xr?this.Xr:"identified_only"}),(r=this.siteApps)==null||r.onRemoteConfig(t),(i=this.sessionRecording)==null||i.onRemoteConfig(t),(s=this.autocapture)==null||s.onRemoteConfig(t),(o=this.heatmaps)==null||o.onRemoteConfig(t),this.surveys.onRemoteConfig(t),this.logs.onRemoteConfig(t),this.conversations.onRemoteConfig(t),(a=this.productTours)==null||a.onRemoteConfig(t),(c=this.webVitalsAutocapture)==null||c.onRemoteConfig(t),(d=this.exceptionObserver)==null||d.onRemoteConfig(t),this.exceptions.onRemoteConfig(t),(f=this.deadClicksAutocapture)==null||f.onRemoteConfig(t)}hs(){try{this.config.loaded(this)}catch(r){Re.critical("`loaded` function failed",r)}if(this.cs(),this.config.internal_or_test_user_hostname&&Er!=null&&Er.hostname){var t=Er.hostname,n=this.config.internal_or_test_user_hostname;(typeof n=="string"?t===n:n.test(t))&&this.setInternalOrTestUser()}this.config.capture_pageview&&setTimeout((()=>{(this.consent.isOptedIn()||this.config.cookieless_mode==="always")&&this.fs()}),1),this.ps=new cV(this),this.ps.load()}cs(){var t;this.is_capturing()&&this.config.request_batching&&((t=this.ss)==null||t.enable())}_dom_loaded(){this.is_capturing()&&ml(this.__request_queue,(t=>this.ns(t))),this.__request_queue=[],this.cs()}_handle_unload(){var t,n;this.surveys.handlePageUnload(),this.config.request_batching?(this._s()&&this.capture("$pageleave"),(t=this.ss)==null||t.unload(),(n=this.os)==null||n.unload()):this._s()&&this.capture("$pageleave",null,{transport:"sendBeacon"})}_send_request(t){this.__loaded&&(dV?this.__request_queue.push(t):this.rateLimiter.isServerRateLimited(t.batchKey)||(t.transport=t.transport||this.config.api_transport,t.url=v_(t.url,{ip:this.config.ip?1:0}),t.headers=Ie({},this.config.request_headers,t.headers),t.compression=t.compression==="best-available"?this.compression:t.compression,t.disableXHRCredentials=this.config.__preview_disable_xhr_credentials,this.config.__preview_disable_beacon&&(t.disableTransport=["sendBeacon"]),t.fetchOptions=t.fetchOptions||this.config.fetch_options,(n=>{var r,i,s,o=Ie({},n);o.timeout=o.timeout||6e4,o.url=v_(o.url,{_:new Date().getTime().toString(),ver:Mo.LIB_VERSION,compression:o.compression});var a=(r=o.transport)!==null&&r!==void 0?r:"fetch",c=Yv.filter((f=>!o.disableTransport||!f.transport||!o.disableTransport.includes(f.transport))),d=(i=(s=kH(c,(f=>f.transport===a)))==null?void 0:s.method)!==null&&i!==void 0?i:c[0].method;if(!d)throw new Error("No available transport method");d(o)})(Ie({},t,{callback:n=>{var r,i;this.rateLimiter.checkForLimiting(n),n.statusCode>=400&&((r=(i=this.config).on_request_error)==null||r.call(i,n)),t.callback==null||t.callback(n)}}))))}ns(t){this.os?this.os.retriableRequest(t):this._send_request(t)}_execute_array(t){AE++;try{var n,r=[],i=[],s=[];ml(t,(a=>{a&&(n=a[0],Gt(n)?s.push(a):Uo(a)?a.call(this):Gt(a)&&n==="alias"?r.push(a):Gt(a)&&n.indexOf("capture")!==-1&&Uo(this[n])?s.push(a):i.push(a))}));var o=function(a,c){ml(a,(function(d){if(Gt(d[0])){var f=c;dn(d,(function(p){f=f[p[0]].apply(f,p.slice(1))}))}else this[d[0]].apply(this,d.slice(1))}),c)};o(r,this),o(i,this),o(s,this)}finally{AE--}}us(){var t,n;return((t=this.config.bootstrap)==null?void 0:t.featureFlags)&&Object.keys((n=this.config.bootstrap)==null?void 0:n.featureFlags).length>0||!1}push(t){if(AE>0&&Gt(t)&&Zn(t[0])){var n=mm.prototype[t[0]];Uo(n)&&n.apply(this,t.slice(1))}else this._execute_array([t])}capture(t,n,r){var i;if(this.__loaded&&this.persistence&&this.sessionPersistence&&this.ss){if(this.is_capturing())if(!Te(t)&&Zn(t)){var s=!this.config.opt_out_useragent_filter&&this._is_bot();if(!(s&&!this.config.__preview_capture_bot_pageviews)){var o=r!=null&&r.skip_client_rate_limiting?void 0:this.rateLimiter.clientRateLimitContext();if(o==null||!o.isRateLimited){n!=null&&n.$current_url&&!Zn(n?.$current_url)&&(Re.error("Invalid `$current_url` property provided to `posthog.capture`. Input must be a string. Ignoring provided value."),n==null||delete n.$current_url),t!=="$exception"||r!=null&&r.oi||Re.warn("Using `posthog.capture('$exception')` is unreliable because it does not attach required metadata. Use `posthog.captureException(error)` instead, which attaches required metadata automatically."),this.sessionPersistence.update_search_keyword(),this.config.save_campaign_params&&this.sessionPersistence.update_campaign_params(),this.config.save_referrer&&this.sessionPersistence.update_referrer_info(),(this.config.save_campaign_params||this.config.save_referrer)&&this.persistence.set_initial_person_info();var a=new Date,c=r?.timestamp||a,d=ul(),f={uuid:d,event:t,properties:this.calculateEventProperties(t,n||{},c,d)};t==="$pageview"&&this.config.__preview_capture_bot_pageviews&&s&&(f.event="$bot_pageview",f.properties.$browser_type="bot"),o&&(f.properties.$lib_rate_limit_remaining_tokens=o.remainingTokens),r?.$set&&(f.$set=r?.$set);var p,m=t!=="$groupidentify",v=this.gs(r?.$set_once,m);if(v&&(f.$set_once=v),(f=IRe(f,r!=null&&r._noTruncate?null:this.config.properties_string_max_length)).timestamp=c,Te(r?.timestamp)||(f.properties.$event_time_override_provided=!0,f.properties.$event_time_override_system_time=a),t===up.DISMISSED||t===up.SENT){var w=n?.[PE.SURVEY_ID],_=n?.[PE.SURVEY_ITERATION];p={id:w,current_iteration:_},localStorage.getItem(DD(p))||localStorage.setItem(DD(p),"true"),f.$set=Ie({},f.$set,{[HPe({id:w,current_iteration:_},t===up.SENT?"responded":"dismissed")]:!0})}else t===up.SHOWN&&(f.$set=Ie({},f.$set,{[PE.SURVEY_LAST_SEEN_DATE]:new Date().toISOString()}));var b=Ie({},f.properties.$set,f.$set);if(Pd(b)||this.setPersonPropertiesForFlags(b),!At(this.config.before_send)){var C=this.bs(f);if(!C)return;f=C}this.mi.emit("eventCaptured",f);var P={method:"POST",url:(i=r?._url)!==null&&i!==void 0?i:this.requestRouter.endpointFor("api",this.analyticsDefaultEndpoint),data:f,compression:"best-available",batchKey:r?._batchKey};return!this.config.request_batching||r&&(r==null||!r._batchKey)||r!=null&&r.send_instantly?this.ns(P):this.ss.enqueue(P),f}Re.critical("This capture call is ignored due to client rate limiting.")}}else Re.error("No event name provided to posthog.capture")}else Re.uninitializedWarning("posthog.capture")}_addCaptureHook(t){return this.on("eventCaptured",(n=>t(n.event,n)))}calculateEventProperties(t,n,r,i,s){if(r=r||new Date,!this.persistence||!this.sessionPersistence)return n;var o=s?void 0:this.persistence.remove_event_timer(t),a=Ie({},n);if(a.token=this.config.token,a.$config_defaults=this.config.defaults,(this.config.cookieless_mode=="always"||this.config.cookieless_mode=="on_reject"&&this.consent.isExplicitlyOptedOut())&&(a.$cookieless_mode=!0),t==="$snapshot"){var c=Ie({},this.persistence.properties(),this.sessionPersistence.properties());return a.distinct_id=c.distinct_id,(!Zn(a.distinct_id)&&!ca(a.distinct_id)||fC(a.distinct_id))&&Re.error("Invalid distinct_id for replay event. This indicates a bug in your implementation"),a}var d,f=yPe(this.config.mask_personal_data_properties,this.config.custom_personal_data_properties);if(this.sessionManager){var{sessionId:p,windowId:m}=this.sessionManager.checkAndGetSessionAndWindowId(s,r.getTime());a.$session_id=p,a.$window_id=m}this.sessionPropsManager&&jn(a,this.sessionPropsManager.getSessionProps());try{var v;this.sessionRecording&&jn(a,this.sessionRecording.sdkDebugProperties),a.$sdk_debug_retry_queue_size=(v=this.os)==null?void 0:v.length}catch(C){a.$sdk_debug_error_capturing_properties=String(C)}if(this.requestRouter.region===dp.CUSTOM&&(a.$lib_custom_api_host=this.config.api_host),d=t!=="$pageview"||s?t!=="$pageleave"||s?this.pageViewM
vendor: 13,010 bytes, line 278
278anager.doEvent():this.pageViewManager.doPageLeave(r):this.pageViewManager.doPageView(r,i),a=jn(a,d),t==="$pageview"&&ke&&(a.title=ke.title),!Te(o)){var w=r.getTime()-o;a.$duration=parseFloat((w/1e3).toFixed(3))}oi&&this.config.opt_out_useragent_filter&&(a.$browser_type=this._is_bot()?"bot":"browser"),(a=jn({},f,this.persistence.properties(),this.sessionPersistence.properties(),a)).$is_identified=this._isIdentified(),Gt(this.config.property_denylist)?dn(this.config.property_denylist,(function(C){delete a[C]})):Re.error("Invalid value for property_denylist config: "+this.config.property_denylist+" or property_blacklist config: "+this.config.property_blacklist);var _=this.config.sanitize_properties;_&&(Re.error("sanitize_properties is deprecated. Use before_send instead"),a=_(a,t));var b=this.ys();return a.$process_person_profile=b,b&&!s&&this.ws("_calculate_event_properties"),a}gs(t,n){var r;if(n===void 0&&(n=!0),!this.persistence||!this.ys()||this.Jr)return t;var i=this.persistence.get_initial_props(),s=(r=this.sessionPropsManager)==null?void 0:r.getSetOnceProps(),o=jn({},i,s||{},t||{}),a=this.config.sanitize_properties;return a&&(Re.error("sanitize_properties is deprecated. Use before_send instead"),o=a(o,"$set_once")),n&&(this.Jr=!0),Pd(o)?void 0:o}register(t,n){var r;(r=this.persistence)==null||r.register(t,n)}register_once(t,n,r){var i;(i=this.persistence)==null||i.register_once(t,n,r)}register_for_session(t){var n;(n=this.sessionPersistence)==null||n.register(t)}unregister(t){var n;(n=this.persistence)==null||n.unregister(t)}unregister_for_session(t){var n;(n=this.sessionPersistence)==null||n.unregister(t)}xs(t,n){this.register({[t]:n})}getFeatureFlag(t,n){return this.featureFlags.getFeatureFlag(t,n)}getFeatureFlagPayload(t){return this.featureFlags.getFeatureFlagPayload(t)}getFeatureFlagResult(t,n){return this.featureFlags.getFeatureFlagResult(t,n)}isFeatureEnabled(t,n){return this.featureFlags.isFeatureEnabled(t,n)}reloadFeatureFlags(){this.featureFlags.reloadFeatureFlags()}updateFlags(t,n,r){var i=r!=null&&r.merge?this.featureFlags.getFlagVariants():{},s=r!=null&&r.merge?this.featureFlags.getFlagPayloads():{},o=Ie({},i,t),a=Ie({},s,n),c={};for(var[d,f]of Object.entries(o)){var p=typeof f=="string";c[d]={key:d,enabled:!!p||!!f,variant:p?f:void 0,reason:void 0,metadata:Te(a?.[d])?void 0:{id:0,version:void 0,description:void 0,payload:a[d]}}}this.featureFlags.receivedFeatureFlags({flags:c})}updateEarlyAccessFeatureEnrollment(t,n,r){this.featureFlags.updateEarlyAccessFeatureEnrollment(t,n,r)}getEarlyAccessFeatures(t,n,r){return n===void 0&&(n=!1),this.featureFlags.getEarlyAccessFeatures(t,n,r)}on(t,n){return this.mi.on(t,n)}onFeatureFlags(t){return this.featureFlags.onFeatureFlags(t)}onSurveysLoaded(t){return this.surveys.onSurveysLoaded(t)}onSessionId(t){var n,r;return(n=(r=this.sessionManager)==null?void 0:r.onSessionId(t))!==null&&n!==void 0?n:()=>{}}getSurveys(t,n){n===void 0&&(n=!1),this.surveys.getSurveys(t,n)}getActiveMatchingSurveys(t,n){n===void 0&&(n=!1),this.surveys.getActiveMatchingSurveys(t,n)}renderSurvey(t,n){this.surveys.renderSurvey(t,n)}displaySurvey(t,n){n===void 0&&(n=WPe),this.surveys.displaySurvey(t,n)}cancelPendingSurvey(t){this.surveys.cancelPendingSurvey(t)}canRenderSurvey(t){return this.surveys.canRenderSurvey(t)}canRenderSurveyAsync(t,n){return n===void 0&&(n=!1),this.surveys.canRenderSurveyAsync(t,n)}identify(t,n,r){if(!this.__loaded||!this.persistence)return Re.uninitializedWarning("posthog.identify");if(ca(t)&&(t=t.toString(),Re.warn("The first argument to posthog.identify was a number, but it should be a string. It has been converted to a string.")),t)if(["distinct_id","distinctid"].includes(t.toLowerCase()))Re.critical('The string "'+t+'" was set in posthog.identify which indicates an error. This ID should be unique to the user and not a hardcoded string.');else if(t!==Bh){if(this.ws("posthog.identify")){var i=this.get_distinct_id();if(this.register({$user_id:t}),!this.get_property("$device_id")){var s=i;this.register_once({$had_persisted_distinct_id:!0,$device_id:s},"")}t!==i&&t!==this.get_property(sp)&&(this.unregister(sp),this.register({distinct_id:t}));var o=(this.persistence.get_property(Do)||"anonymous")==="anonymous";t!==i&&o?(this.persistence.set_property(Do,"identified"),this.setPersonPropertiesForFlags(Ie({},r||{},n||{}),!1),this.capture("$identify",{distinct_id:t,$anon_distinct_id:i},{$set:n||{},$set_once:r||{}}),this.Qr=RD(t,n,r),this.featureFlags.setAnonymousDistinctId(i)):(n||r)&&this.setPersonProperties(n,r),t!==i&&(this.reloadFeatureFlags(),this.unregister(c_))}}else Re.critical('The string "'+Bh+'" was set in posthog.identify which indicates an error. This ID is only used as a sentinel value.');else Re.error("Unique user id has not been set in posthog.identify")}setPersonProperties(t,n){if((t||n)&&this.ws("posthog.setPersonProperties")){var r=RD(this.get_distinct_id(),t,n);this.Qr!==r?(this.setPersonPropertiesForFlags(Ie({},n||{},t||{})),this.capture("$set",{$set:t||{},$set_once:n||{}}),this.Qr=r):Re.info("A duplicate setPersonProperties call was made with the same properties. It has been ignored.")}}group(t,n,r){if(t&&n){var i=this.getGroups();i[t]!==n&&this.resetGroupPropertiesForFlags(t),this.register({$groups:Ie({},i,{[t]:n})}),r&&(this.capture("$groupidentify",{$group_type:t,$group_key:n,$group_set:r}),this.setGroupPropertiesForFlags({[t]:r})),i[t]===n||r||this.reloadFeatureFlags()}else Re.error("posthog.group requires a group type and group key")}resetGroups(){this.register({$groups:{}}),this.resetGroupPropertiesForFlags(),this.reloadFeatureFlags()}setPersonPropertiesForFlags(t,n){n===void 0&&(n=!0),this.featureFlags.setPersonPropertiesForFlags(t,n)}resetPersonPropertiesForFlags(){this.featureFlags.resetPersonPropertiesForFlags()}setGroupPropertiesForFlags(t,n){n===void 0&&(n=!0),this.ws("posthog.setGroupPropertiesForFlags")&&this.featureFlags.setGroupPropertiesForFlags(t,n)}resetGroupPropertiesForFlags(t){this.featureFlags.resetGroupPropertiesForFlags(t)}reset(t){var n,r,i,s,o;if(Re.info("reset"),!this.__loaded)return Re.uninitializedWarning("posthog.reset");var a=this.get_property("$device_id");if(this.consent.reset(),(n=this.persistence)==null||n.clear(),(r=this.sessionPersistence)==null||r.clear(),this.surveys.reset(),(i=this.ps)==null||i.stop(),this.featureFlags.reset(),(s=this.persistence)==null||s.set_property(Do,"anonymous"),(o=this.sessionManager)==null||o.resetSessionId(),this.Qr=null,this.config.cookieless_mode==="always")this.register_once({distinct_id:Bh,$device_id:null},"");else{var c=this.config.get_device_id(ul());this.register_once({distinct_id:c,$device_id:t?c:a},"")}this.register({$last_posthog_reset:new Date().toISOString()},1)}get_distinct_id(){return this.get_property("distinct_id")}getGroups(){return this.get_property("$groups")||{}}get_session_id(){var t,n;return(t=(n=this.sessionManager)==null?void 0:n.checkAndGetSessionAndWindowId(!0).sessionId)!==null&&t!==void 0?t:""}get_session_replay_url(t){if(!this.sessionManager)return"";var{sessionId:n,sessionStartTimestamp:r}=this.sessionManager.checkAndGetSessionAndWindowId(!0),i=this.requestRouter.endpointFor("ui","/project/"+this.config.token+"/replay/"+n);if(t!=null&&t.withTimestamp&&r){var s,o=(s=t.timestampLookBack)!==null&&s!==void 0?s:10;if(!r)return i;i+="?t="+Math.max(Math.floor((new Date().getTime()-r)/1e3)-o,0)}return i}alias(t,n){return t===this.get_property(TH)?(Re.critical("Attempting to create alias for existing People user - aborting."),-2):this.ws("posthog.alias")?(Te(n)&&(n=this.get_distinct_id()),t!==n?(this.xs(sp,t),this.capture("$create_alias",{alias:t,distinct_id:n})):(Re.warn("alias matches current distinct_id - skipping api call."),this.identify(t),-1)):void 0}set_config(t){var n=Ie({},this.config);if(sr(t)){var r,i,s,o,a,c,d,f;jn(this.config,zD(t));var p=this.rs();(r=this.persistence)==null||r.update_config(this.config,n,p),this.sessionPersistence=this.config.persistence==="sessionStorage"||this.config.persistence==="memory"?this.persistence:new kE(Ie({},this.config,{persistence:"sessionStorage"}),p);var m=this.Zr(this.config.debug);Go(m)&&(this.config.debug=m),Go(this.config.debug)&&(this.config.debug?(Mo.DEBUG=!0,Cn.H()&&Cn.G("ph_debug","true"),Re.info("set_config",{config:t,oldConfig:n,newConfig:Ie({},this.config)})):(Mo.DEBUG=!1,Cn.H()&&Cn.V("ph_debug"))),(i=this.exceptionObserver)==null||i.onConfigChange(),(s=this.sessionRecording)==null||s.startIfEnabledOrStop(),(o=this.autocapture)==null||o.startIfEnabled(),(a=this.heatmaps)==null||a.startIfEnabled(),(c=this.exceptionObserver)==null||c.startIfEnabledOrStop(),(d=this.deadClicksAutocapture)==null||d.startIfEnabledOrStop(),this.surveys.loadIfEnabled(),this.$s(),(f=this.externalIntegrations)==null||f.startIfEnabledOrStop()}}startSessionRecording(t){var n=t===!0,r={sampling:n||!(t==null||!t.sampling),linked_flag:n||!(t==null||!t.linked_flag),url_trigger:n||!(t==null||!t.url_trigger),event_trigger:n||!(t==null||!t.event_trigger)};if(Object.values(r).some(Boolean)){var i,s,o,a,c;(i=this.sessionManager)==null||i.checkAndGetSessionAndWindowId(),r.sampling&&((s=this.sessionRecording)==null||s.overrideSampling()),r.linked_flag&&((o=this.sessionRecording)==null||o.overrideLinkedFlag()),r.url_trigger&&((a=this.sessionRecording)==null||a.overrideTrigger("url")),r.event_trigger&&((c=this.sessionRecording)==null||c.overrideTrigger("event"))}this.set_config({disable_session_recording:!1})}stopSessionRecording(){this.set_config({disable_session_recording:!0})}sessionRecordingStarted(){var t;return!((t=this.sessionRecording)==null||!t.started)}captureException(t,n){var r=new Error("PostHog syntheticException"),i=this.exceptions.buildProperties(t,{handled:!0,syntheticException:r});return this.exceptions.sendExceptionEvent(Ie({},i,n))}startExceptionAutocapture(t){this.set_config({capture_exceptions:t==null||t})}stopExceptionAutocapture(){this.set_config({capture_exceptions:!1})}loadToolbar(t){return this.toolbar.loadToolbar(t)}get_property(t){var n;return(n=this.persistence)==null?void 0:n.props[t]}getSessionProperty(t){var n;return(n=this.sessionPersistence)==null?void 0:n.props[t]}toString(){var t,n=(t=this.config.name)!==null&&t!==void 0?t:hd;return n!==hd&&(n=hd+"."+n),n}_isIdentified(){var t,n;return((t=this.persistence)==null?void 0:t.get_property(Do))==="identified"||((n=this.sessionPersistence)==null?void 0:n.get_property(Do))==="identified"}ys(){var t,n;return!(this.config.person_profiles==="never"||this.config.person_profiles==="identified_only"&&!this._isIdentified()&&Pd(this.getGroups())&&((t=this.persistence)==null||(t=t.props)==null||!t[sp])&&((n=this.persistence)==null||(n=n.props)==null||!n[d_]))}_s(){return this.config.capture_pageleave===!0||this.config.capture_pageleave==="if_capture_pageview"&&(this.config.capture_pageview===!0||this.config.capture_pageview==="history_change")}createPersonProfile(){this.ys()||this.ws("posthog.createPersonProfile")&&this.setPersonProperties({},{})}setInternalOrTestUser(){this.ws("posthog.setInternalOrTestUser")&&this.setPersonProperties({$internal_or_test_user:!0})}ws(t){return this.config.person_profiles==="never"?(Re.error(t+' was called, but process_person is set to "never". This call will be ignored.'),!1):(this.xs(d_,!0),!0)}rs(){if(this.config.cookieless_mode==="always")return!0;var t=this.consent.isOptedOut(),n=this.config.opt_out_persistence_by_default||this.config.cookieless_mode==="on_reject";return this.config.disable_persistence||t&&!!n}$s(){var t,n,r,i,s=this.rs();return((t=this.persistence)==null?void 0:t.ki)!==s&&((r=this.persistence)==null||r.set_disabled(s)),((n=this.sessionPersistence)==null?void 0:n.ki)!==s&&((i=this.sessionPersistence)==null||i.set_disabled(s)),s}opt_in_capturing(t){var n;if(this.config.cookieless_mode!=="always"){var r,i,s;this.config.cookieless_mode==="on_reject"&&this.consent.isExplicitlyOptedOut()&&(this.reset(!0),(r=this.sessionManager)==null||r.destroy(),(i=this.pageViewManager)==null||i.destroy(),this.sessionManager=new $D(this),this.pageViewManager=new SD(this),this.persistence&&(this.sessionPropsManager=new ND(this,this.sessionManager,this.persistence)),this.sessionRecording=new FD(this),this.sessionRecording.startIfEnabledOrStop()),this.consent.optInOut(!0),this.$s(),this.cs(),(n=this.sessionRecording)==null||n.startIfEnabledOrStop(),this.config.cookieless_mode=="on_reject"&&this.surveys.loadIfEnabled(),(Te(t?.captureEventName)||t!=null&&t.captureEventName)&&this.capture((s=t?.captureEventName)!==null&&s!==void 0?s:"$opt_in",t?.captureProperties,{send_instantly:!0}),this.config.capture_pageview&&this.fs()}else Re.warn('Consent opt in/out is not valid with cookieless_mode="always" and will be ignored')}opt_out_capturing(){var t,n,r;this.config.cookieless_mode!=="always"?(this.config.cookieless_mode==="on_reject"&&this.consent.isOptedIn()&&this.reset(!0),this.consent.optInOut(!1),this.$s(),this.config.cookieless_mode==="on_reject"&&(this.register({distinct_id:Bh,$device_id:null}
278),(t=this.sessionManager)==null||t.destroy(),(n=this.pageViewManager)==null||n.destroy(),this.sessionManager=void 0,this.sessionPropsManager=void 0,(r=this.sessionRecording)==null||r.stopRecording(),this.sessionRecording=void 0,this.fs())):Re.warn('Consent opt in/out is not valid with cookieless_mode="always" and will be ignored')}has_opted_in_capturing(){return this.consent.isOptedIn()}has_opted_out_capturing(){return this.consent.isOptedOut()}get_explicit_consent_status(){var t=this.consent.consent;return t===Lo.GRANTED?"granted":t===Lo.DENIED?"denied":"pending"}is_capturing(){return this.config.cookieless_mode==="always"||(this.config.cookieless_mode==="on_reject"?this.consent.isExplicitlyOptedOut()||this.consent.isOptedIn():!this.has_opted_out_capturing())}clear_opt_in_out_capturing(){this.consent.reset(),this.$s()}_is_bot(){return ki?uV(ki,this.config.custom_blocked_useragents):void 0}fs(){ke&&(ke.visibilityState==="visible"?this.Kr||(this.Kr=!0,this.capture("$pageview",{title:ke.title},{send_instantly:!0}),this.Yr&&(ke.removeEventListener("visibilitychange",this.Yr),this.Yr=null)):this.Yr||(this.Yr=this.fs.bind(this),Xn(ke,"visibilitychange",this.Yr)))}debug(t){t===!1?(fe?.console.log("You've disabled debug mode."),this.set_config({debug:!1})):(fe?.console.log("You're now in debug mode. All calls to PostHog will be logged in your console.\nYou can disable this with `posthog.debug(false)`."),this.set_config({debug:!0}))}M(){var t,n,r,i,s,o,a,c=this.ts||{};return"advanced_disable_flags"in c?!!c.advanced_disable_flags:this.config.advanced_disable_flags!==!1?!!this.config.advanced_disable_flags:this.config.advanced_disable_decide===!0?(Re.warn("Config field 'advanced_disable_decide' is deprecated. Please use 'advanced_disable_flags' instead. The old field will be removed in a future major version."),!0):(r="advanced_disable_decide",i=!1,s=Re,o=(n="advanced_disable_flags")in(t=c)&&!At(t[n]),a=r in t&&!At(t[r]),o?t[n]:a?(s&&s.warn("Config field '"+r+"' is deprecated. Please use '"+n+"' instead. The old field will be removed in a future major version."),t[r]):i)}bs(t){if(At(this.config.before_send))return t;var n=Gt(this.config.before_send)?this.config.before_send:[this.config.before_send],r=t;for(var i of n){if(r=i(r),At(r)){var s="Event '"+t.event+"' was rejected in beforeSend function";return YTe(t.event)?Re.warn(s+". This can cause unexpected behavior."):Re.info(s),null}r.properties&&!Pd(r.properties)||Re.warn("Event '"+t.event+"' has no properties after beforeSend function, this is likely an error.")}return r}getPageViewId(){var t;return(t=this.pageViewManager.Kt)==null?void 0:t.pageViewId}captureTraceFeedback(t,n){this.capture("$ai_feedback",{$ai_trace_id:String(t),$ai_feedback_text:n})}captureTraceMetric(t,n,r){this.capture("$ai_metric",{$ai_trace_id:String(t),$ai_metric_name:n,$ai_metric_value:String(r)})}Zr(t){var n=Go(t)&&!t,r=Cn.H()&&Cn.q("ph_debug")==="true";return!n&&(!!r||t)}}(function(e,t){for(var n=0;n<t.length;n++)e.prototype[t[n]]=ARe(e.prototype[t[n]])})(mm,["identify"]);var BD;(function(e){return e.SHOWN="product tour shown",e.DISMISSED="product tour dismissed",e.COMPLETED="product tour completed",e.STEP_SHOWN="product tour step shown",e.STEP_COMPLETED="product tour step completed",e.BUTTON_CLICKED="product tour button clicked",e.STEP_SELECTOR_FAILED="product tour step selector failed",e.BANNER_CONTAINER_SELECTOR_FAILED="product tour banner container selector failed",e.BANNER_ACTION_CLICKED="product tour banner action clicked",e})({});(function(e){return e.TOUR_ID="$product_tour_id",e.TOUR_NAME="$product_tour_name",e.TOUR_ITERATION="$product_tour_iteration",e.TOUR_RENDER_REASON="$product_tour_render_reason",e.TOUR_STEP_ID="$product_tour_step_id",e.TOUR_STEP_ORDER="$product_tour_step_order",e.TOUR_STEP_TYPE="$product_tour_step_type",e.TOUR_DISMISS_REASON="$product_tour_dismiss_reason",e.TOUR_BUTTON_TEXT="$product_tour_button_text",e.TOUR_BUTTON_ACTION="$product_tour_button_action",e.TOUR_BUTTON_LINK="$product_tour_button_link",e.TOUR_BUTTON_TOUR_ID="$product_tour_button_tour_id",e.TOUR_STEPS_COUNT="$product_tour_steps_count",e.TOUR_STEP_SELECTOR="$product_tour_step_selector",e.TOUR_STEP_SELECTOR_FOUND="$product_tour_step_selector_found",e.TOUR_STEP_ELEMENT_TAG="$product_tour_step_element_tag",e.TOUR_STEP_ELEMENT_ID="$product_tour_step_element_id",e.TOUR_STEP_ELEMENT_CLASSES="$product_tour_step_element_classes",e.TOUR_STEP_ELEMENT_TEXT="$product_tour_step_element_text",e.TOUR_ERROR="$product_tour_error",e.TOUR_MATCHES_COUNT="$product_tour_matches_count",e.TOUR_FAILURE_PHASE="$product_tour_failure_phase",e.TOUR_WAITED_FOR_ELEMENT="$product_tour_waited_for_element",e.TOUR_WAIT_DURATION_MS="$product_tour_wait_duration_ms",e.TOUR_BANNER_SELECTOR="$product_tour_banner_selector",e.TOUR_LINKED_SURVEY_ID="$product_tour_linked_survey_id",e.USE_MANUAL_SELECTOR="$use_manual_selector",e.INFERENCE_DATA_PRESENT="$inference_data_present",e})({});var pd=(BD=Tp[hd]=new mm,(function(){function e(){e.done||(e.done=!0,dV=!1,dn(Tp,(function(t){t._dom_loaded()})))}ke!=null&&ke.addEventListener?ke.readyState==="complete"?e():Xn(ke,"DOMContentLoaded",e,{capture:!1}):fe&&Re.error("Browser doesn't support `document.addEventListener` so PostHog couldn't be initialized")})(),BD),fV=g.createContext({client:pd,bootstrap:void 0});function hV(e,t,n){if(n===void 0&&(n=new WeakMap),e===t)return!0;
278if(typeof e!="object"||e===null||typeof t!="object"||t===null)return!1;if(n.has(e)&&n.get(e)===t)return!0;n.set(e,t);var r=Object.keys(e),i=Object.keys(t);if(r.length!==i.length)return!1;for(var s=0,o=r;s<o.length;s++){var a=o[s];if(!i.includes(a)||!hV(e[a],t[a],n))return!1}return!0}function f3e(e){var t,n,r=e.children,i=e.client,s=e.apiKey,o=e.options,a=g.useRef(null),c=g.useMemo(function(){return i?(s&&console.warn("[PostHog.js] You have provided both `client` and `apiKey` to `PostHogProvider`. `apiKey` will be ignored in favour of `client`."),o&&console.warn("[PostHog.js] You have provided both `client` and `options` to `PostHogProvider`. `options` will be ignored in favour of `client`."),i):(s||console.warn("[PostHog.js] No `apiKey` or `client` were provided to `PostHogProvider`. Using default global `window.posthog` instance. You must initialize it manually. This is not recommended behavior."),pd)},[i,s,JSON.stringify(o)]);return g.useEffect(function(){if(!i){var d=a.current;d?(s!==d.apiKey&&console.warn("[PostHog.js] You have provided a different `apiKey` to `PostHogProvider` than the one that was already initialized. This is not supported by our provider and we'll keep using the previous key. If you need to toggle between API Keys you need to control the `client` yourself and pass it in as a prop rather than an `apiKey` prop."),o&&!hV(o,d.options)&&pd.set_config(o),a.current={apiKey:s,options:o??{}}):(pd.__loaded&&console.warn("[PostHog.js] `posthog` was already loaded elsewhere. This may cause issues."),pd.init(s,o),a.current={apiKey:s,options:o??{}})}},[i,s,JSON.stringify(o)]),bt.createElement(fV.Provider,{value:{client:c,bootstrap:(t=o?.bootstrap)!==null&&t!==void 0?t:(n=i?.config)===null||n===void 0?void 0:n.bootstrap}},r)}var IE=function(e){return typeof e=="function"},LC=function(e,t){return LC=Object.setPrototypeOf||{__proto__:[]}instanceof Array&&function(n,r){n.__proto__=r}||function(n,r){for(var i in r)Object.prototype.hasOwnProperty.call(r,i)&&(n[i]=r[i])},LC(e,t)};function h3e(e,t){if(typeof t!="function"&&t!==null)throw new TypeError("Class extends value "+String(t)+" is not a constructor or null");LC(e,t);function n(){this.constructor=e}e.prototype=t===null?Object.create(t):(n.prototype=t.prototype,new n)}var p3e={componentStack:null,exceptionEvent:null,error:null},m3e={INVALID_FALLBACK:"[PostHog.js][PostHogErrorBoundary] Invalid fallback prop, provide a valid React element or a function that returns a valid React element."};(function(e){h3e(t,e);function t(n){var r=e.call(this,n)||this;return r.state=p3e,r}return t.prototype.componentDidCatch=function(n,r){var i=this.props.additionalProperties,s;IE(i)?s=i(n):typeof i=="object"&&(s=i);var o=this.context.client,a=o.captureException(n,s),c=r.componentStack;this.setState({error:n,componentStack:c??null,exceptionEvent:a})},t.prototype.render=function(){var n=this.props,r=n.children,i=n.fallback,s=this.state;if(s.componentStack==null)return IE(r)?r():r;var o=IE(i)?bt.createElement(i,{error:s.error,componentStack:s.componentStack,exceptionEvent:s.exceptionEvent}):i;return bt.isValidElement(o)?o:(console.warn(m3e.INVALID_FALLBACK),bt.createElement(bt.Fragment,null))},t.contextType=fV,t})(bt.Component);$ce();async function g3e(){}const y3e="https://us.i.posthog.com",v3e="phc_w4kJKAVoqZh34nywOK9ssxUvhvXn09vhFDrt4MYrVPd",_3e={api_host:y3e,defaults:"2025-05-24"},w3e=j.jsx(f3e,{apiKey:v3e,options:_3e,children:j.jsx(VTe,{})});g3e().then(()=>{iq.createRoot(document.getElementById("root")).render(j.jsx(g.StrictMode,{children:w3e}))});export{aCe as $,In as A,Kr as B,_Se as C,Zke as D,Iz as E,x7 as F,hEe as G,SOe as H,kbe as I,CEe as J,Tbe as K,nTe as L,u_e as M,BU as N,wn as O,nR as P,Tl as Q,bt as R,Uke as S,xM as T,Jz as U,lxe as V,tC as W,KOe as X,GOe as Y,ZOe as Z,ibe as _,LT as a,yn as a$,iCe as a0,nY as a1,$6 as a2,tY as a3,hX as a4,Z0e as a5,xbe as a6,Zwe as a7,E7 as a8,VOe as a9,bSe as aA,uSe as aB,wSe as aC,_z as aD,eo as aE,im as aF,dxe as aG,nr as aH,Az as aI,SEe as aJ,mxe as aK,hxe as aL,cxe as aM,f2e as aN,tB as aO,X0 as aP,oF as aQ,pAe as aR,c_e as aS,pj as aT,rTe as aU,iF as aV,UU as aW,zU as aX,du as aY,Al as aZ,Lc as a_,hAe as aa,g
278S as ab,LR as ac,iTe as ad,A0e as ae,uF as af,vF as ag,fAe as ah,p$ as ai,ai as aj,i1 as ak,M0e as al,lAe as am,cAe as an,Mi as ao,Yhe as ap,Oke as aq,Rke as ar,XB as as,_ke as at,Dbe as au,af as av,fEe as aw,kn as ax,iR as ay,Dr as az,kl as b,TF as b$,co as b0,gt as b1,lr as b2,yl as b3,ao as b4,bn as b5,JW as b6,Uce as b7,gy as b8,KB as b9,TU as bA,Gwe as bB,tAe as bC,jce as bD,nAe as bE,dAe as bF,jke as bG,uAe as bH,w_ as bI,UT as bJ,Yo as bK,rAe as bL,iAe as bM,Ol as bN,T_ as bO,p6 as bP,m6 as bQ,R_ as bR,OF as bS,BT as bT,wF as bU,zT as bV,S_ as bW,g6 as bX,y6 as bY,Nce as bZ,g1 as b_,qB as ba,wX as bb,$K as bc,dk as bd,jR as be,xOe as bf,Fke as bg,ag as bh,AB as bi,aAe as bj,oAe as bk,sAe as bl,km as bm,x0e as bn,C0e as bo,ia as bp,$Te as bq,re as br,J as bs,Mke as bt,qOe as bu,WOe as bv,RU as bw,XT as bx,sM as by,dbe as bz,sn as c,RF as c0,se as c1,b3e as c2,_be as c3,Gr as d,q0 as e,jl as f,sbe as g,A_ as h,JOe as i,j,XOe as k,Qke as l,eH as m,tH as n,Xke as o,Pl as p,aq as q,g as r,F2 as s,b_ as t,As as u,eTe as v,Eke as w,vbe as x,zke as y,Tm 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.