vendor: 6,236 bytes, lines 1-9
1var Sx=e=>{throw TypeError(e)};var mm=(e,t,r)=>t.has(e)||Sx("Cannot "+r);var z=(e,t,r)=>(mm(e,t,"read from private field"),r?r.call(e):t.get(e)),me=(e,t,r)=>t.has(e)?Sx("Cannot add the same private member more than once"):t instanceof WeakSet?t.add(e):t.set(e,r),se=(e,t,r,n)=>(mm(e,t,"write to private field"),n?n.call(e,r):t.set(e,r),r),Pt=(e,t,r)=>(mm(e,t,"access private method"),r);var Dc=(e,t,r,n)=>({set _(i){se(e,t,i,r)},get _(){return z(e,t,n)}});function pI(e,t){for(var r=0;r<t.length;r++){const n=t[r];if(typeof n!="string"&&!Array.isArray(n)){for(const i in n)if(i!=="default"&&!(i in e)){const a=Object.getOwnPropertyDescriptor(n,i);a&&Object.defineProperty(e,i,a.get?a:{enumerable:!0,get:()=>n[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"]'))n(i);new MutationObserver(i=>{for(const a of i)if(a.type==="childList")for(const o of a.addedNodes)o.tagName==="LINK"&&o.rel==="modulepreload"&&n(o)}).observe(document,{childList:!0,subtree:!0});function r(i){const a={};return i.integrity&&(a.integrity=i.integrity),i.referrerPolicy&&(a.referrerPolicy=i.referrerPolicy),i.crossOrigin==="use-credentials"?a.credentials="include":i.crossOrigin==="anonymous"?a.credentials="omit":a.credentials="same-origin",a}function n(i){if(i.ep)return;i.ep=!0;const a=r(i);fetch(i.href,a)}})();var Lc=typeof globalThis<"u"?globalThis:typeof window<"u"?window:typeof global<"u"?global:typeof self<"u"?self:{};function Ce(e){return e&&e.__esModule&&Object.prototype.hasOwnProperty.call(e,"default")?e.default:e}var Jk={exports:{}},Rh={},Zk={exports:{}},de={};/** 2 * @license React 3 * react.production.min.js 4 * 5 * Copyright (c) Facebook, Inc. and its affiliates. 6 * 7 * This source code is licensed under the MIT license found in the 8 * LICENSE file in the root directory of this source tree. 9 */var gc=Symbol.for("react.element"),mI=Symbol.for("react.portal"),vI=Symbol.for("react.fragment"),gI=Symbol.for("react.strict_mode"),yI=Symbol.for("react.profiler"),bI=Symbol.for("react.provider"),wI=Symbol.for("react.context"),xI=Symbol.for("react.forward_ref"),_I=Symbol.for("react.suspense"),SI=Symbol.for("react.memo"),OI=Symbol.for("react.lazy"),Ox=Symbol.iterator;function EI(e){return e===null||typeof e!="object"?null:(e=Ox&&e[Ox]||e["@@iterator"],typeof e=="function"?e:null)}var eP={isMounted:function(){return!1},enqueueForceUpdate:function(){},enqueueReplaceState:function(){},enqueueSetState:function(){}},tP=Object.assign,rP={};function qs(e,t,r){this.props=e,this.context=t,this.refs=rP,this.updater=r||eP}qs.prototype.isReactComponent={};qs.prototype.setState=function(e,t){if(typeof e!="object"&&typeof e!="function"&&e!=null)throw Error("setState(...): takes an object of state variables to update or a function which returns an object of state variables.");this.updater.enqueueSetState(this,e,t,"setState")};qs.prototype.forceUpdate=function(e){this.updater.enqueueForceUpdate(this,e,"forceUpdate")};function nP(){}nP.prototype=qs.prototype;function T0(e,t,r){this.props=e,this.context=t,this.refs=rP,this.updater=r||eP}var C0=T0.prototype=new nP;C0.constructor=T0;tP(C0,qs.prototype);C0.isPureReactComponent=!0;var Ex=Array.isArray,iP=Object.prototype.hasOwnProperty,N0={current:null},aP={key:!0,ref:!0,__self:!0,__source:!0};function oP(e,t,r){var n,i={},a=null,o=null;if(t!=null)for(n in t.ref!==void 0&&(o=t.ref),t.key!==void 0&&(a=""+t.key),t)iP.call(t,n)&&!aP.hasOwnProperty(n)&&(i[n]=t[n]);var s=arguments.length-2;if(s===1)i.children=r;else if(1<s){for(var l=Array(s),u=0;u<s;u++)l[u]=arguments[u+2];i.children=l}if(e&&e.defaultProps)for(n in s=e.defaultProps,s)i[n]===void 0&&(i[n]=s[n]);return{$$typeof:gc,type:e,key:a,ref:o,props:i,_owner:N0.current}}function kI(e,t){return{$$typeof:gc,type:e.type,key:t,ref:e.ref,props:e.props,_owner:e._owner}}function $0(e){return typeof e=="object"&&e!==null&&e.$$typeof===gc}function PI(e){var t={"=":"=0",":":"=2"};return"$"+e.replace(/[=:]/g,function(r){return t[r]})}var kx=/\/+/g;function vm(e,t){return typeof e=="object"&&e!==null&&e.key!=null?PI(""+e.key):t.toString(36)}function Nd(e,t,r,n,i){var a=typeof e;(a==="undefined"||a==="boolean")&&(e=null);var o=!1;if(e===null)o=!0;else switch(a){case"string":case"number":o=!0;break;case"object":switch(e.$$typeof){case gc:case mI:o=!0}}if(o)return o=e,i=i(o),e=n===""?"."+vm(o,0):n,Ex(i)?(r="",e!=null&&(r=e.replace(kx,"$&/")+"/"),Nd(i,t,r,"",function(u){return u})):i!=null&&($0(i)&&(i=kI(i,r+(!i.key||o&&o.key===i.key?"":(""+i.key).replace(kx,"$&/")+"/")+e)),t.push(i)),1;if(o=0,n=n===""?".":n+":",Ex(e))for(var s=0;s<e.length;s++){a=e[s];var l=n+vm(a,s);o+=Nd(a,t,r,l,i)}else if(l=EI(e),typeof l=="function")for(e=l.call(e),s=0;!(a=e.next()).done;)a=a.value,l=n+vm(a,s++),o+=Nd(a,t,r,l,i);else if(a==="object")throw t=String(e),Error("Objects are not valid as a React child (found: "+(t==="[object Object]"?"object with keys {"+Object.keys(e).join(", ")+"}":t)+"). If you meant to render a collection of children, use an array instead.");return o}function Bc(e,t,r){if(e==null)return e;var n=[],i=0;return Nd(e,n,"","",function(a){return t.call(r,a,i++)}),n}function AI(e){if(e._status===-1){var t=e._result;t=t(),t.then(function(r){(e._status===0||e._status===-1)&&(e._status=1,e._result=r)},function(r){(e._status===0||e._status===-1)&&(e._status=2,e._result=r)}),e._status===-1&&(e._status=0,e._result=t)}if(e._status===1)return e._result.default;throw e._result}var Ft={current:null},$d={transition:null},jI={ReactCurrentDispatcher:Ft,ReactCurrentBatchConfig:$d,ReactCurrentOwner:N0};function sP(){throw Error("act(...) is not supported in production builds of React.")}de.Children={map:Bc,forEach:function(e,t,r){Bc(e,function(){t.apply(this,arguments)},r)},count:function(e){var t=0;return Bc(e,function(){t++}),t},toArray:function(e){return Bc(e,function(t){return t})||[]},only:function(e){if(!$0(e))throw Error("React.Children.only expected to receive a single React element child.");return e}};de.Component=qs;de.Fragment=vI;de.Profiler=yI;de.PureComponent=T0;de.StrictMode=gI;de.Suspense=_I;
vendor: 9,005 bytes, lines 9-33
9de.__SECRET_INTERNALS_DO_NOT_USE_OR_YOU_WILL_BE_FIRED=jI;de.act=sP;de.cloneElement=function(e,t,r){if(e==null)throw Error("React.cloneElement(...): The argument must be a React element, but you passed "+e+".");var n=tP({},e.props),i=e.key,a=e.ref,o=e._owner;if(t!=null){if(t.ref!==void 0&&(a=t.ref,o=N0.current),t.key!==void 0&&(i=""+t.key),e.type&&e.type.defaultProps)var s=e.type.defaultProps;for(l in t)iP.call(t,l)&&!aP.hasOwnProperty(l)&&(n[l]=t[l]===void 0&&s!==void 0?s[l]:t[l])}var l=arguments.length-2;if(l===1)n.children=r;else if(1<l){s=Array(l);for(var u=0;u<l;u++)s[u]=arguments[u+2];n.children=s}return{$$typeof:gc,type:e.type,key:i,ref:a,props:n,_owner:o}};de.createContext=function(e){return e={$$typeof:wI,_currentValue:e,_currentValue2:e,_threadCount:0,Provider:null,Consumer:null,_defaultValue:null,_globalName:null},e.Provider={$$typeof:bI,_context:e},e.Consumer=e};de.createElement=oP;de.createFactory=function(e){var t=oP.bind(null,e);return t.type=e,t};de.createRef=function(){return{current:null}};de.forwardRef=function(e){return{$$typeof:xI,render:e}};de.isValidElement=$0;de.lazy=function(e){return{$$typeof:OI,_payload:{_status:-1,_result:e},_init:AI}};de.memo=function(e,t){return{$$typeof:SI,type:e,compare:t===void 0?null:t}};de.startTransition=function(e){var t=$d.transition;$d.transition={};try{e()}finally{$d.transition=t}};de.unstable_act=sP;de.useCallback=function(e,t){return Ft.current.useCallback(e,t)};de.useContext=function(e){return Ft.current.useContext(e)};de.useDebugValue=function(){};de.useDeferredValue=function(e){return Ft.current.useDeferredValue(e)};de.useEffect=function(e,t){return Ft.current.useEffect(e,t)};de.useId=function(){return Ft.current.useId()};de.useImperativeHandle=function(e,t,r){return Ft.current.useImperativeHandle(e,t,r)};de.useInsertionEffect=function(e,t){return Ft.current.useInsertionEffect(e,t)};de.useLayoutEffect=function(e,t){return Ft.current.useLayoutEffect(e,t)};de.useMemo=function(e,t){return Ft.current.useMemo(e,t)};de.useReducer=function(e,t,r){return Ft.current.useReducer(e,t,r)};de.useRef=function(e){return Ft.current.useRef(e)};de.useState=function(e){return Ft.current.useState(e)};de.useSyncExternalStore=function(e,t,r){return Ft.current.useSyncExternalStore(e,t,r)};de.useTransition=function(){return Ft.current.useTransition()};de.version="18.3.1";Zk.exports=de;var O=Zk.exports;const j=Ce(O),R0=pI({__proto__:null,default:j},[O]);/** 10 * @license React 11 * react-jsx-runtime.production.min.js 12 * 13 * Copyright (c) Facebook, Inc. and its affiliates. 14 * 15 * This source code is licensed under the MIT license found in the 16 * LICENSE file in the root directory of this source tree. 17 */var TI=O,CI=Symbol.for("react.element"),NI=Symbol.for("react.fragment"),$I=Object.prototype.hasOwnProperty,RI=TI.__SECRET_INTERNALS_DO_NOT_USE_OR_YOU_WILL_BE_FIRED.ReactCurrentOwner,II={key:!0,ref:!0,__self:!0,__source:!0};function lP(e,t,r){var n,i={},a=null,o=null;r!==void 0&&(a=""+r),t.key!==void 0&&(a=""+t.key),t.ref!==void 0&&(o=t.ref);for(n in t)$I.call(t,n)&&!II.hasOwnProperty(n)&&(i[n]=t[n]);if(e&&e.defaultProps)for(n in t=e.defaultProps,t)i[n]===void 0&&(i[n]=t[n]);return{$$typeof:CI,type:e,key:a,ref:o,props:i,_owner:RI.current}}Rh.Fragment=NI;Rh.jsx=lP;Rh.jsxs=lP;Jk.exports=Rh;var p=Jk.exports,uP={exports:{}},pr={},cP={exports:{}},dP={};/** 18 * @license React 19 * scheduler.production.min.js 20 * 21 * Copyright (c) Facebook, Inc. and its affiliates. 22 * 23 * This source code is licensed under the MIT license found in the 24 * LICENSE file in the root directory of this source tree. 25 */(function(e){function t(A,T){var U=A.length;A.push(T);e:for(;0<U;){var q=U-1>>>1,B=A[q];if(0<i(B,T))A[q]=T,A[U]=B,U=q;else break e}}function r(A){return A.length===0?null:A[0]}function n(A){if(A.length===0)return null;var T=A[0],U=A.pop();if(U!==T){A[0]=U;e:for(var q=0,B=A.length,W=B>>>1;q<W;){var K=2*(q+1)-1,Z=A[K],xe=K+1,ue=A[xe];if(0>i(Z,U))xe<B&&0>i(ue,Z)?(A[q]=ue,A[xe]=U,q=xe):(A[q]=Z,A[K]=U,q=K);else if(xe<B&&0>i(ue,U))A[q]=ue,A[xe]=U,q=xe;else break e}}return T}function i(A,T){var U=A.sortIndex-T.sortIndex;return U!==0?U:A.id-T.id}if(typeof performance=="object"&&typeof performance.now=="function"){var a=performance;e.unstable_now=function(){return a.now()}}else{var o=Date,s=o.now();e.unstable_now=function(){return o.now()-s}}var l=[],u=[],d=1,c=null,f=3,h=!1,v=!1,m=!1,g=typeof setTimeout=="function"?setTimeout:null,y=typeof clearTimeout=="function"?clearTimeout:null,b=typeof setImmediate<"u"?setImmediate:null;typeof navigator<"u"&&navigator.scheduling!==void 0&&navigator.scheduling.isInputPending!==void 0&&navigator.scheduling.isInputPending.bind(navigator.scheduling);function w(A){for(var T=r(u);T!==null;){if(T.callback===null)n(u);else if(T.startTime<=A)n(u),T.sortIndex=T.expirationTime,t(l,T);else break;T=r(u)}}function _(A){if(m=!1,w(A),!v)if(r(l)!==null)v=!0,M(x);else{var T=r(u);T!==null&&L(_,T.startTime-A)}}function x(A,T){v=!1,m&&(m=!1,y(k),k=-1),h=!0;var U=f;try{for(w(T),c=r(l);c!==null&&(!(c.expirationTime>T)||A&&!N());){var q=c.callback;if(typeof q=="function"){c.callback=null,f=c.priorityLevel;var B=q(c.expirationTime<=T);T=e.unstable_now(),typeof B=="function"?c.callback=B:c===r(l)&&n(l),w(T)}else n(l);c=r(l)}if(c!==null)var W=!0;else{var K=r(u);K!==null&&L(_,K.startTime-T),W=!1}return W}finally{c=null,f=U,h=!1}}var S=!1,E=null,k=-1,P=5,C=-1;function N(){return!(e.unstable_now()-C<P)}function $(){if(E!==null){var A=e.unstable_now();C=A;var T=!0;try{T=E(!0,A)}finally{T?D():(S=!1,E=null)}}else S=!1}var D;if(typeof b=="function")D=function(){b($)};else if(typeof MessageChannel<"u"){var I=new MessageChannel,R=I.port2;I.port1.onmessage=$,D=function(){R.postMessage(null)}}else D=function(){g($,0)};function M(A){E=A,S||(S=!0,D())}function L(A,T){k=g(function(){A(e.unstable_now())},T)}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(A){A.callback=null},e.unstable_continueExecution=function(){v||h||(v=!0,M(x))},e.unstable_forceFrameRate=function(A){0>A||125<A?console.error("forceFrameRate takes a positive int between 0 and 125, forcing frame rates higher than 125 fps is not supported"):P=0<A?Math.floor(1e3/A):5},e.unstable_getCurrentPriorityLevel=function(){return f},e.unstable_getFirstCallbackNode=function(){return r(l)},e.unstable_next=function(A){switch(f){case 1:case 2:case 3:var T=3;break;default:T=f}var U=f;f=T;try{return A()}finally{f=U}},e.unstable_pauseExecution=function(){},e.unstable_requestPaint=function(){},e.unstable_runWithPriority=function(A,T){switch(A){case 1:case 2:case 3:case 4:case 5:break;default:A=3}var U=f;f=A;try{return T()}finally{f=U}},e.unstable_scheduleCallback=function(A,T,U){var q=e.unstable_now();switch(typeof U=="object"&&U!==null?(U=U.delay,U=typeof U=="number"&&0<U?q+U:q):U=q,A){case 1:var B=-1;break;case 2:B=250;break;case 5:B=1073741823;break;case 4:B=1e4;break;default:B=5e3}return B=U+B,A={id:d++,callback:T,priorityLevel:A,startTime:U,expirationTime:B,sortIndex:-1},U>q?(A.sortIndex=U,t(u,A),r(l)===null&&A===r(u)&&(m?(y(k),k=-1):m=!0,L(_,U-q))):(A.sortIndex=B,t(l,A),v||h||(v=!0,M(x))),A},e.unstable_shouldYield=N,e.unstable_wrapCallback=function(A){var T=f;return function(){var U=f;f=T;try{return A.apply(this,arguments)}finally{f=U}}}})(dP);cP.exports=dP;var MI=cP.exports;/** 26 * @license React 27 * react-dom.production.min.js 28 * 29 * Copyright (c) Facebook, Inc. and its affiliates. 30 * 31 * This source code is licensed under the MIT license found in the 32 * LICENSE file in the root directory of this source tree. 33 */var DI=O,hr=MI;function V(e){for(var t="https://reactjs.org/docs/error-decoder.html?invariant="+e,r=1;r<arguments.length;r++)t+="&args[]="+encodeURIComponent(arguments[r]);return"Minified React error #"+e+"; visit "+t+" for the full message or use the non-minified dev environment for full errors and additional helpful warnings."}var fP=new Set,tu={};function Ja(e,t){ds(e,t),ds(e+"Capture",t)}function ds(e,t){for(tu[e]=t,e=0;e<t.length;e++)fP.add(t[e])}var Kn=!(typeof window>"u"||typeof window.document>"u"||typeof window.document.createElement>"u"),Bv=Object.prototype.hasOwnProperty,LI=/^[: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]*$/,Px={},Ax={};function BI(e){return Bv.call(Ax,e)?!0:Bv.call(Px,e)?!1:LI.test(e)?Ax[e]=!0:(Px[e]=!0,!1)}function UI(e,t,r,n){if(r!==null&&r.type===0)return!1;switch(typeof t){case"function":case"symbol":return!0;case"boolean":return n?!1:r!==null?!r.acceptsBooleans:(e=e.toLowerCase().slice(0,5),e!=="data-"&&e!=="aria-");default:return!1}}function FI(e,t,r,n){if(t===null||typeof t>"u"||UI(e,t,r,n))return!0;
vendor: 5,200 bytes, lines 33-34
33if(n)return!1;if(r!==null)switch(r.type){case 3:return!t;case 4:return t===!1;case 5:return isNaN(t);case 6:return isNaN(t)||1>t}return!1}function zt(e,t,r,n,i,a,o){this.acceptsBooleans=t===2||t===3||t===4,this.attributeName=n,this.attributeNamespace=i,this.mustUseProperty=r,this.propertyName=e,this.type=t,this.sanitizeURL=a,this.removeEmptyString=o}var kt={};"children dangerouslySetInnerHTML defaultValue defaultChecked innerHTML suppressContentEditableWarning suppressHydrationWarning style".split(" ").forEach(function(e){kt[e]=new zt(e,0,!1,e,null,!1,!1)});[["acceptCharset","accept-charset"],["className","class"],["htmlFor","for"],["httpEquiv","http-equiv"]].forEach(function(e){var t=e[0];kt[t]=new zt(t,1,!1,e[1],null,!1,!1)});["contentEditable","draggable","spellCheck","value"].forEach(function(e){kt[e]=new zt(e,2,!1,e.toLowerCase(),null,!1,!1)});["autoReverse","externalResourcesRequired","focusable","preserveAlpha"].forEach(function(e){kt[e]=new zt(e,2,!1,e,null,!1,!1)});"allowFullScreen async autoFocus autoPlay controls default defer disabled disablePictureInPicture disableRemotePlayback formNoValidate hidden loop noModule noValidate open playsInline readOnly required reversed scoped seamless itemScope".split(" ").forEach(function(e){kt[e]=new zt(e,3,!1,e.toLowerCase(),null,!1,!1)});["checked","multiple","muted","selected"].forEach(function(e){kt[e]=new zt(e,3,!0,e,null,!1,!1)});["capture","download"].forEach(function(e){kt[e]=new zt(e,4,!1,e,null,!1,!1)});["cols","rows","size","span"].forEach(function(e){kt[e]=new zt(e,6,!1,e,null,!1,!1)});["rowSpan","start"].forEach(function(e){kt[e]=new zt(e,5,!1,e.toLowerCase(),null,!1,!1)});var I0=/[\-:]([a-z])/g;function M0(e){return e[1].toUpperCase()}"accent-height alignment-baseline arabic-form baseline-shift cap-height clip-path clip-rule color-interpolation color-interpolation-filters color-profile color-rendering dominant-baseline enable-background fill-opacity fill-rule flood-color flood-opacity font-family font-size font-size-adjust font-stretch font-style font-variant font-weight glyph-name glyph-orientation-horizontal glyph-orientation-vertical horiz-adv-x horiz-origin-x image-rendering letter-spacing lighting-color marker-end marker-mid marker-start overline-position overline-thickness paint-order panose-1 pointer-events rendering-intent shape-rendering stop-color stop-opacity strikethrough-position strikethrough-thickness stroke-dasharray stroke-dashoffset stroke-linecap stroke-linejoin stroke-miterlimit stroke-opacity stroke-width text-anchor text-decoration text-rendering underline-position underline-thickness unicode-bidi unicode-range units-per-em v-alphabetic v-hanging v-ideographic v-mathematical vector-effect vert-adv-y vert-origin-x vert-origin-y word-spacing writing-mode xmlns:xlink x-height".split(" ").forEach(function(e){var t=e.replace(I0,M0);kt[t]=new zt(t,1,!1,e,null,!1,!1)});"xlink:actuate xlink:arcrole xlink:role xlink:show xlink:title xlink:type".split(" ").forEach(function(e){var t=e.replace(I0,M0);kt[t]=new zt(t,1,!1,e,"http://www.w3.org/1999/xlink",!1,!1)});["xml:base","xml:lang","xml:space"].forEach(function(e){var t=e.replace(I0,M0);kt[t]=new zt(t,1,!1,e,"http://www.w3.org/XML/1998/namespace",!1,!1)});["tabIndex","crossOrigin"].forEach(function(e){kt[e]=new zt(e,1,!1,e.toLowerCase(),null,!1,!1)});kt.xlinkHref=new zt("xlinkHref",1,!1,"xlink:href","http://www.w3.org/1999/xlink",!0,!1);["src","href","action","formAction"].forEach(function(e){kt[e]=new zt(e,1,!1,e.toLowerCase(),null,!0,!0)});function D0(e,t,r,n){var i=kt.hasOwnProperty(t)?kt[t]:null;(i!==null?i.type!==0:n||!(2<t.length)||t[0]!=="o"&&t[0]!=="O"||t[1]!=="n"&&t[1]!=="N")&&(FI(t,r,i,n)&&(r=null),n||i===null?BI(t)&&(r===null?e.removeAttribute(t):e.setAttribute(t,""+r)):i.mustUseProperty?e[i.propertyName]=r===null?i.type===3?!1:"":r:(t=i.attributeName,n=i.attributeNamespace,r===null?e.removeAttribute(t):(i=i.type,r=i===3||i===4&&r===!0?"":""+r,n?e.setAttributeNS(n,t,r):e.setAttribute(t,r))))}var ri=DI.__SECRET_INTERNALS_DO_NOT_USE_OR_YOU_WILL_BE_FIRED,Uc=Symbol.for("react.element"),Po=Symbol.for("react.portal"),Ao=Symbol.for("react.fragment"),L0=Symbol.for("react.strict_mode"),Uv=Symbol.for("react.profiler"),hP=Symbol.for("react.provider"),pP=Symbol.for("react.context"),B0=Symbol.for("react.forward_ref"),Fv=Symbol.for("react.suspense"),zv=Symbol.for("react.suspense_list"),U0=Symbol.for("react.memo"),yi=Symbol.for("react.lazy"),mP=Symbol.for("react.offscreen"),jx=Symbol.iterator;function dl(e){return e===null||typeof e!="object"?null:(e=jx&&e[jx]||e["@@iterator"],typeof e=="function"?e:null)}var Ge=Object.assign,gm;function Nl(e){if(gm===void 0)try{throw Error()}catch(r){var t=r.stack.trim().match(/\n( *(at )?)/);gm=t&&t[1]||""}return` 34`+gm+e}var ym=!1;function bm(e,t){if(!e||ym)return"";ym=!0;var r=Error.prepareStackTrace;Error.prepareStackTrace=void 0;try{if(t)if(t=function(){throw Error()},Object.defineProperty(t.prototype,"props",{set:function(){throw Error()}}),typeof Reflect=="object"&&Reflect.construct){try{Reflect.construct(t,[])}catch(u){var n=u}Reflect.construct(e,[],t)}else{try{t.call()}catch(u){n=u}e.call(t.prototype)}else{try{throw Error()}catch(u){n=u}e()}}
vendor: 14,090 bytes, lines 34-37
34catch(u){if(u&&n&&typeof u.stack=="string"){for(var i=u.stack.split(` 35`),a=n.stack.split(` 36`),o=i.length-1,s=a.length-1;1<=o&&0<=s&&i[o]!==a[s];)s--;for(;1<=o&&0<=s;o--,s--)if(i[o]!==a[s]){if(o!==1||s!==1)do if(o--,s--,0>s||i[o]!==a[s]){var l=` 37`+i[o].replace(" at new "," at ");return e.displayName&&l.includes("<anonymous>")&&(l=l.replace("<anonymous>",e.displayName)),l}while(1<=o&&0<=s);break}}}finally{ym=!1,Error.prepareStackTrace=r}return(e=e?e.displayName||e.name:"")?Nl(e):""}function zI(e){switch(e.tag){case 5:return Nl(e.type);case 16:return Nl("Lazy");case 13:return Nl("Suspense");case 19:return Nl("SuspenseList");case 0:case 2:case 15:return e=bm(e.type,!1),e;case 11:return e=bm(e.type.render,!1),e;case 1:return e=bm(e.type,!0),e;default:return""}}function Wv(e){if(e==null)return null;if(typeof e=="function")return e.displayName||e.name||null;if(typeof e=="string")return e;switch(e){case Ao:return"Fragment";case Po:return"Portal";case Uv:return"Profiler";case L0:return"StrictMode";case Fv:return"Suspense";case zv:return"SuspenseList"}if(typeof e=="object")switch(e.$$typeof){case pP:return(e.displayName||"Context")+".Consumer";case hP:return(e._context.displayName||"Context")+".Provider";case B0:var t=e.render;return e=e.displayName,e||(e=t.displayName||t.name||"",e=e!==""?"ForwardRef("+e+")":"ForwardRef"),e;case U0:return t=e.displayName||null,t!==null?t:Wv(e.type)||"Memo";case yi:t=e._payload,e=e._init;try{return Wv(e(t))}catch{}}return null}function WI(e){var t=e.type;switch(e.tag){case 24:return"Cache";case 9:return(t.displayName||"Context")+".Consumer";case 10:return(t._context.displayName||"Context")+".Provider";case 18:return"DehydratedFragment";case 11:return e=t.render,e=e.displayName||e.name||"",t.displayName||(e!==""?"ForwardRef("+e+")":"ForwardRef");case 7:return"Fragment";case 5:return t;case 4:return"Portal";case 3:return"Root";case 6:return"Text";case 16:return Wv(t);case 8:return t===L0?"StrictMode":"Mode";case 22:return"Offscreen";case 12:return"Profiler";case 21:return"Scope";case 13:return"Suspense";case 19:return"SuspenseList";case 25:return"TracingMarker";case 1:case 0:case 17:case 2:case 14:case 15:if(typeof t=="function")return t.displayName||t.name||null;if(typeof t=="string")return t}return null}function qi(e){switch(typeof e){case"boolean":case"number":case"string":case"undefined":return e;case"object":return e;default:return""}}function vP(e){var t=e.type;return(e=e.nodeName)&&e.toLowerCase()==="input"&&(t==="checkbox"||t==="radio")}function qI(e){var t=vP(e)?"checked":"value",r=Object.getOwnPropertyDescriptor(e.constructor.prototype,t),n=""+e[t];if(!e.hasOwnProperty(t)&&typeof r<"u"&&typeof r.get=="function"&&typeof r.set=="function"){var i=r.get,a=r.set;return Object.defineProperty(e,t,{configurable:!0,get:function(){return i.call(this)},set:function(o){n=""+o,a.call(this,o)}}),Object.defineProperty(e,t,{enumerable:r.enumerable}),{getValue:function(){return n},setValue:function(o){n=""+o},stopTracking:function(){e._valueTracker=null,delete e[t]}}}}function Fc(e){e._valueTracker||(e._valueTracker=qI(e))}function gP(e){if(!e)return!1;var t=e._valueTracker;if(!t)return!0;var r=t.getValue(),n="";return e&&(n=vP(e)?e.checked?"true":"false":e.value),e=n,e!==r?(t.setValue(e),!0):!1}function Qd(e){if(e=e||(typeof document<"u"?document:void 0),typeof e>"u")return null;try{return e.activeElement||e.body}catch{return e.body}}function qv(e,t){var r=t.checked;return Ge({},t,{defaultChecked:void 0,defaultValue:void 0,value:void 0,checked:r??e._wrapperState.initialChecked})}function Tx(e,t){var r=t.defaultValue==null?"":t.defaultValue,n=t.checked!=null?t.checked:t.defaultChecked;r=qi(t.value!=null?t.value:r),e._wrapperState={initialChecked:n,initialValue:r,controlled:t.type==="checkbox"||t.type==="radio"?t.checked!=null:t.value!=null}}function yP(e,t){t=t.checked,t!=null&&D0(e,"checked",t,!1)}function Hv(e,t){yP(e,t);var r=qi(t.value),n=t.type;if(r!=null)n==="number"?(r===0&&e.value===""||e.value!=r)&&(e.value=""+r):e.value!==""+r&&(e.value=""+r);else if(n==="submit"||n==="reset"){e.removeAttribute("value");return}t.hasOwnProperty("value")?Vv(e,t.type,r):t.hasOwnProperty("defaultValue")&&Vv(e,t.type,qi(t.defaultValue)),t.checked==null&&t.defaultChecked!=null&&(e.defaultChecked=!!t.defaultChecked)}function Cx(e,t,r){if(t.hasOwnProperty("value")||t.hasOwnProperty("defaultValue")){var n=t.type;if(!(n!=="submit"&&n!=="reset"||t.value!==void 0&&t.value!==null))return;t=""+e._wrapperState.initialValue,r||t===e.value||(e.value=t),e.defaultValue=t}r=e.name,r!==""&&(e.name=""),e.defaultChecked=!!e._wrapperState.initialChecked,r!==""&&(e.name=r)}function Vv(e,t,r){(t!=="number"||Qd(e.ownerDocument)!==e)&&(r==null?e.defaultValue=""+e._wrapperState.initialValue:e.defaultValue!==""+r&&(e.defaultValue=""+r))}var $l=Array.isArray;function Wo(e,t,r,n){if(e=e.options,t){t={};for(var i=0;i<r.length;i++)t["$"+r[i]]=!0;for(r=0;r<e.length;r++)i=t.hasOwnProperty("$"+e[r].value),e[r].selected!==i&&(e[r].selected=i),i&&n&&(e[r].defaultSelected=!0)}else{for(r=""+qi(r),t=null,i=0;i<e.length;i++){if(e[i].value===r){e[i].selected=!0,n&&(e[i].defaultSelected=!0);return}t!==null||e[i].disabled||(t=e[i])}t!==null&&(t.selected=!0)}}function Kv(e,t){if(t.dangerouslySetInnerHTML!=null)throw Error(V(91));return Ge({},t,{value:void 0,defaultValue:void 0,children:""+e._wrapperState.initialValue})}function Nx(e,t){var r=t.value;if(r==null){if(r=t.children,t=t.defaultValue,r!=null){if(t!=null)throw Error(V(92));if($l(r)){if(1<r.length)throw Error(V(93));r=r[0]}t=r}t==null&&(t=""),r=t}e._wrapperState={initialValue:qi(r)}}function bP(e,t){var r=qi(t.value),n=qi(t.defaultValue);r!=null&&(r=""+r,r!==e.value&&(e.value=r),t.defaultValue==null&&e.defaultValue!==r&&(e.defaultValue=r)),n!=null&&(e.defaultValue=""+n)}function $x(e){var t=e.textContent;t===e._wrapperState.initialValue&&t!==""&&t!==null&&(e.value=t)}function wP(e){switch(e){case"svg":return"http://www.w3.org/2000/svg";case"math":return"http://www.w3.org/1998/Math/MathML";default:return"http://www.w3.org/1999/xhtml"}}function Gv(e,t){return e==null||e==="http://www.w3.org/1999/xhtml"?wP(t):e==="http://www.w3.org/2000/svg"&&t==="foreignObject"?"http://www.w3.org/1999/xhtml":e}var zc,xP=function(e){return typeof MSApp<"u"&&MSApp.execUnsafeLocalFunction?function(t,r,n,i){MSApp.execUnsafeLocalFunction(function(){return e(t,r,n,i)})}:e}(function(e,t){if(e.namespaceURI!=="http://www.w3.org/2000/svg"||"innerHTML"in e)e.innerHTML=t;else{for(zc=zc||document.createElement("div"),zc.innerHTML="<svg>"+t.valueOf().toString()+"</svg>",t=zc.firstChild;e.firstChild;)e.removeChild(e.firstChild);for(;t.firstChild;)e.appendChild(t.firstChild)}});function ru(e,t){if(t){var r=e.firstChild;if(r&&r===e.lastChild&&r.nodeType===3){r.nodeValue=t;return}}e.textContent=t}var Ll={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},HI=["Webkit","ms","Moz","O"];Object.keys(Ll).forEach(function(e){HI.forEach(function(t){t=t+e.charAt(0).toUpperCase()+e.substring(1),Ll[t]=Ll[e]})});function _P(e,t,r){return t==null||typeof t=="boolean"||t===""?"":r||typeof t!="number"||t===0||Ll.hasOwnProperty(e)&&Ll[e]?(""+t).trim():t+"px"}function SP(e,t){e=e.style;for(var r in t)if(t.hasOwnProperty(r)){var n=r.indexOf("--")===0,i=_P(r,t[r],n);r==="float"&&(r="cssFloat"),n?e.setProperty(r,i):e[r]=i}}var VI=Ge({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 Yv(e,t){if(t){if(VI[e]&&(t.children!=null||t.dangerouslySetInnerHTML!=null))throw Error(V(137,e));if(t.dangerouslySetInnerHTML!=null){if(t.children!=null)throw Error(V(60));if(typeof t.dangerouslySetInnerHTML!="object"||!("__html"in t.dangerouslySetInnerHTML))throw Error(V(61))}if(t.style!=null&&typeof t.style!="object")throw Error(V(62))}}function Xv(e,t){if(e.indexOf("-")===-1)return typeof t.is=="string";switch(e){case"annotation-xml":case"color-profile":case"font-face":case"font-face-src":case"font-face-uri":case"font-face-format":case"font-face-name":case"missing-glyph":return!1;default:return!0}}var Qv=null;function F0(e){return e=e.target||e.srcElement||window,e.correspondingUseElement&&(e=e.correspondingUseElement),e.nodeType===3?e.parentNode:e}var Jv=null,qo=null,Ho=null;function Rx(e){if(e=wc(e)){if(typeof Jv!="function")throw Error(V(280));var t=e.stateNode;t&&(t=Bh(t),Jv(e.stateNode,e.type,t))}}function OP(e){qo?Ho?Ho.push(e):Ho=[e]:qo=e}function EP(){if(qo){var e=qo,t=Ho;if(Ho=qo=null,Rx(e),t)for(e=0;e<t.length;e++)Rx(t[e])}}function kP(e,t){return e(t)}function PP(){}var wm=!1;function AP(e,t,r){if(wm)return e(t,r);wm=!0;try{return kP(e,t,r)}finally{wm=!1,(qo!==null||Ho!==null)&&(PP(),EP())}}function nu(e,t){var r=e.stateNode;if(r===null)return null;var n=Bh(r);if(n===null)return null;r=n[t];e:switch(t){case"onClick":case"onClickCapture":case"onDoubleClick":case"onDoubleClickCapture":case"onMouseDown":case"onMouseDownCapture":case"onMouseMove":case"onMouseMoveCapture":case"onMouseUp":case"onMouseUpCapture":case"onMouseEnter":(n=!n.disabled)||(e=e.type,n=!(e==="button"||e==="input"||e==="select"||e==="textarea")),e=!n;break e;default:e=!1}if(e)return null;if(r&&typeof r!="function")throw Error(V(231,t,typeof r));return r}var Zv=!1;if(Kn)try{var fl={};Object.defineProperty(fl,"passive",{get:function(){Zv=!0}}),window.addEventListener("test",fl,fl),window.removeEventListener("test",fl,fl)}catch{Zv=!1}function KI(e,t,r,n,i,a,o,s,l){var u=Array.prototype.slice.call(arguments,3);try{t.apply(r,u)}catch(d){this.onError(d)}}var Bl=!1,Jd=null,Zd=!1,eg=null,GI={onError:function(e){Bl=!0,Jd=e}};function YI(e,t,r,n,i,a,o,s,l){Bl=!1,Jd=null,KI.apply(GI,arguments)}function XI(e,t,r,n,i,a,o,s,l){if(YI.apply(this,arguments),Bl){if(Bl){var u=Jd;Bl=!1,Jd=null}else throw Error(V(198));Zd||(Zd=!0,eg=u)}}function Za(e){var t=e,r=e;if(e.alternate)for(;t.return;)t=t.return;else{e=t;do t=e,t.flags&4098&&(r=t.return),e=t.return;while(e)}return t.tag===3?r:null}function jP(e){if(e.tag===13){var t=e.memoizedState;if(t===null&&(e=e.alternate,e!==null&&(t=e.memoizedState)),t!==null)return t.dehydrated}return null}function Ix(e){if(Za(e)!==e)throw Error(V(188))}function QI(e){var t=e.alternate;if(!t){if(t=Za(e),t===null)throw Error(V(188));return t!==e?null:e}for(var r=e,n=t;;){var i=r.return;if(i===null)break;var a=i.alternate;if(a===null){if(n=i.return,n!==null){r=n;continue}break}if(i.child===a.child){for(a=i.child;a;){if(a===r)return Ix(i),e;if(a===n)return Ix(i),t;a=a.sibling}throw Error(V(188))}if(r.return!==n.return)r=i,n=a;else{for(var o=!1,s=i.child;s;){if(s===r){o=!0,r=i,n=a;break}if(s===n){o=!0,n=i,r=a;break}s=s.sibling}if(!o){for(s=a.child;s;){if(s===r){o=!0,r=a,n=i;break}if(s===n){o=!0,n=a,r=i;break}s=s.sibling}if(!o)throw Error(V(189))}}if(r.alternate!==n)throw Error(V(190))}if(r.tag!==3)throw Error(V(188));return r.stateNode.current===r?e:t}function TP(e){return e=QI(e),e!==null?CP(e):null}function CP(e){if(e.tag===5||e.tag===6)return e;for(e=e.child;e!==null;){var t=CP(e);if(t!==null)return t;e=e.sibling}return null}var NP=hr.unstable_scheduleCallback,Mx=hr.unstable_cancelCallback,JI=hr.unstable_shouldYield,ZI=hr.unstable_requestPaint,et=hr.unstable_now,eM=hr.unstable_getCurrentPriorityLevel,z0=hr.unstable_ImmediatePriority,$P=hr.unstable_UserBlockingPriority,ef=hr.unstable_NormalPriority,tM=hr.unstable_LowPriority,RP=hr.unstable_IdlePriority,Ih=null,xn=null;function rM(e){if(xn&&typeof xn.onCommitFiberRoot=="function")try{xn.onCommitFiberRoot(Ih,e,void 0,(e.current.flags&128)===128)}catch{}}var Qr=Math.clz32?Math.clz32:aM,nM=Math.log,iM=Math.LN2;function aM(e){return e>>>=0,e===0?32:31-(nM(e)/iM|0)|0}var Wc=64,qc=4194304;function Rl(e){switch(e&-e){case 1:return 1;case 2:return 2;case 4:return 4;case 8:return 8;case 16:return 16;case 32:return 32;case 64:case 128:case 256:case 512:case 1024:case 2048:case 4096:case 8192:case 16384:case 32768:case 65536:case 131072:case 262144:case 524288:case 1048576:case 2097152:return e&4194240;case 4194304:case 8388608:case 16777216:case 33554432:case 67108864:return e&130023424;case 134217728:return 134217728;case 268435456:return 268435456;case 536870912:return 536870912;case 1073741824:return 1073741824;default:return e}}function tf(e,t){var r=e.pendingLanes;if(r===0)return 0;var n=0,i=e.suspendedLanes,a=e.pingedLanes,o=r&268435455;if(o!==0){var s=o&~i;s!==0?n=Rl(s):(a&=o,a!==0&&(n=Rl(a)))}else o=r&~i,o!==0?n=Rl(o):a!==0&&(n=Rl(a));if(n===0)return 0;if(t!==0&&t!==n&&!(t&i)&&(i=n&-n,a=t&-t,i>=a||i===16&&(a&4194240)!==0))return t;if(n&4&&(n|=r&16),t=e.entangledLanes,t!==0)for(e=e.entanglements,t&=n;0<t;)r=31-Qr(t),i=1<<r,n|=e[r],t&=~i;return n}function oM(e,t){switch(e){case 1:case 2:case 4:return t+250;case 8:case 16:case 32:case 64:case 128:case 256:case 512:case 1024:case 2048:case 4096:case 8192:case 16384:case 32768:case 65536:case 131072:case 262144:case 524288:case 1048576:case 2097152:return t+5e3;case 4194304:case 8388608:case 16777216:case 33554432:case 67108864:return-1;case 134217728:case 268435456:case 536870912:case 1073741824:return-1;default:return-1}}function sM(e,t){for(var r=e.suspendedLanes,n=e.pingedLanes,i=e.expirationTimes,a=e.pendingLanes;0<a;){var o=31-Qr(a),s=1<<o,l=i[o];l===-1?(!(s&r)||s&n)&&(i[o]=oM(s,t)):l<=t&&(e.expiredLanes|=s),a&=~s}}function tg(e){return e=e.pendingLanes&-1073741825,e!==0?e:e&1073741824?1073741824:0}function IP(){var e=Wc;return Wc<<=1,!(Wc&4194240)&&(Wc=64),e}function xm(e){for(var t=[],r=0;31>r;r++)t.push(e);return t}
vendor: 4,087 bytes, line 37
37function yc(e,t,r){e.pendingLanes|=t,t!==536870912&&(e.suspendedLanes=0,e.pingedLanes=0),e=e.eventTimes,t=31-Qr(t),e[t]=r}function lM(e,t){var r=e.pendingLanes&~t;e.pendingLanes=t,e.suspendedLanes=0,e.pingedLanes=0,e.expiredLanes&=t,e.mutableReadLanes&=t,e.entangledLanes&=t,t=e.entanglements;var n=e.eventTimes;for(e=e.expirationTimes;0<r;){var i=31-Qr(r),a=1<<i;t[i]=0,n[i]=-1,e[i]=-1,r&=~a}}function W0(e,t){var r=e.entangledLanes|=t;for(e=e.entanglements;r;){var n=31-Qr(r),i=1<<n;i&t|e[n]&t&&(e[n]|=t),r&=~i}}var Ee=0;function MP(e){return e&=-e,1<e?4<e?e&268435455?16:536870912:4:1}var DP,q0,LP,BP,UP,rg=!1,Hc=[],Ri=null,Ii=null,Mi=null,iu=new Map,au=new Map,_i=[],uM="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 Dx(e,t){switch(e){case"focusin":case"focusout":Ri=null;break;case"dragenter":case"dragleave":Ii=null;break;case"mouseover":case"mouseout":Mi=null;break;case"pointerover":case"pointerout":iu.delete(t.pointerId);break;case"gotpointercapture":case"lostpointercapture":au.delete(t.pointerId)}}function hl(e,t,r,n,i,a){return e===null||e.nativeEvent!==a?(e={blockedOn:t,domEventName:r,eventSystemFlags:n,nativeEvent:a,targetContainers:[i]},t!==null&&(t=wc(t),t!==null&&q0(t)),e):(e.eventSystemFlags|=n,t=e.targetContainers,i!==null&&t.indexOf(i)===-1&&t.push(i),e)}function cM(e,t,r,n,i){switch(t){case"focusin":return Ri=hl(Ri,e,t,r,n,i),!0;case"dragenter":return Ii=hl(Ii,e,t,r,n,i),!0;case"mouseover":return Mi=hl(Mi,e,t,r,n,i),!0;case"pointerover":var a=i.pointerId;return iu.set(a,hl(iu.get(a)||null,e,t,r,n,i)),!0;case"gotpointercapture":return a=i.pointerId,au.set(a,hl(au.get(a)||null,e,t,r,n,i)),!0}return!1}function FP(e){var t=ba(e.target);if(t!==null){var r=Za(t);if(r!==null){if(t=r.tag,t===13){if(t=jP(r),t!==null){e.blockedOn=t,UP(e.priority,function(){LP(r)});return}}else if(t===3&&r.stateNode.current.memoizedState.isDehydrated){e.blockedOn=r.tag===3?r.stateNode.containerInfo:null;return}}}e.blockedOn=null}function Rd(e){if(e.blockedOn!==null)return!1;for(var t=e.targetContainers;0<t.length;){var r=ng(e.domEventName,e.eventSystemFlags,t[0],e.nativeEvent);if(r===null){r=e.nativeEvent;var n=new r.constructor(r.type,r);Qv=n,r.target.dispatchEvent(n),Qv=null}else return t=wc(r),t!==null&&q0(t),e.blockedOn=r,!1;t.shift()}return!0}function Lx(e,t,r){Rd(e)&&r.delete(t)}function dM(){rg=!1,Ri!==null&&Rd(Ri)&&(Ri=null),Ii!==null&&Rd(Ii)&&(Ii=null),Mi!==null&&Rd(Mi)&&(Mi=null),iu.forEach(Lx),au.forEach(Lx)}function pl(e,t){e.blockedOn===t&&(e.blockedOn=null,rg||(rg=!0,hr.unstable_scheduleCallback(hr.unstable_NormalPriority,dM)))}function ou(e){function t(i){return pl(i,e)}if(0<Hc.length){pl(Hc[0],e);for(var r=1;r<Hc.length;r++){var n=Hc[r];n.blockedOn===e&&(n.blockedOn=null)}}for(Ri!==null&&pl(Ri,e),Ii!==null&&pl(Ii,e),Mi!==null&&pl(Mi,e),iu.forEach(t),au.forEach(t),r=0;r<_i.length;r++)n=_i[r],n.blockedOn===e&&(n.blockedOn=null);for(;0<_i.length&&(r=_i[0],r.blockedOn===null);)FP(r),r.blockedOn===null&&_i.shift()}var Vo=ri.ReactCurrentBatchConfig,rf=!0;function fM(e,t,r,n){var i=Ee,a=Vo.transition;Vo.transition=null;try{Ee=1,H0(e,t,r,n)}finally{Ee=i,Vo.transition=a}}function hM(e,t,r,n){var i=Ee,a=Vo.transition;Vo.transition=null;try{Ee=4,H0(e,t,r,n)}finally{Ee=i,Vo.transition=a}}function H0(e,t,r,n){if(rf){var i=ng(e,t,r,n);if(i===null)Cm(e,t,n,nf,r),Dx(e,n);else if(cM(i,e,t,r,n))n.stopPropagation();else if(Dx(e,n),t&4&&-1<uM.indexOf(e)){for(;i!==null;){var a=wc(i);if(a!==null&&DP(a),a=ng(e,t,r,n),a===null&&Cm(e,t,n,nf,r),a===i)break;i=a}i!==null&&n.stopPropagation()}else Cm(e,t,n,null,r)}}var nf=null;function ng(e,t,r,n){if(nf=null,e=F0(n),e=ba(e),e!==null)if(t=Za(e),t===null)e=null;else if(r=t.tag,r===13){if(e=jP(t),e!==null)return e;e=null}else if(r===3){if(t.stateNode.current.memoizedState.isDehydrated)return t.tag===3?t.stateNode.containerInfo:null;e=null}else t!==e&&(e=null);return nf=e,null}
vendor: 10,401 bytes, line 37
37function zP(e){switch(e){case"cancel":case"click":case"close":case"contextmenu":case"copy":case"cut":case"auxclick":case"dblclick":case"dragend":case"dragstart":case"drop":case"focusin":case"focusout":case"input":case"invalid":case"keydown":case"keypress":case"keyup":case"mousedown":case"mouseup":case"paste":case"pause":case"play":case"pointercancel":case"pointerdown":case"pointerup":case"ratechange":case"reset":case"resize":case"seeked":case"submit":case"touchcancel":case"touchend":case"touchstart":case"volumechange":case"change":case"selectionchange":case"textInput":case"compositionstart":case"compositionend":case"compositionupdate":case"beforeblur":case"afterblur":case"beforeinput":case"blur":case"fullscreenchange":case"focus":case"hashchange":case"popstate":case"select":case"selectstart":return 1;case"drag":case"dragenter":case"dragexit":case"dragleave":case"dragover":case"mousemove":case"mouseout":case"mouseover":case"pointermove":case"pointerout":case"pointerover":case"scroll":case"toggle":case"touchmove":case"wheel":case"mouseenter":case"mouseleave":case"pointerenter":case"pointerleave":return 4;case"message":switch(eM()){case z0:return 1;case $P:return 4;case ef:case tM:return 16;case RP:return 536870912;default:return 16}default:return 16}}var Ti=null,V0=null,Id=null;function WP(){if(Id)return Id;var e,t=V0,r=t.length,n,i="value"in Ti?Ti.value:Ti.textContent,a=i.length;for(e=0;e<r&&t[e]===i[e];e++);var o=r-e;for(n=1;n<=o&&t[r-n]===i[a-n];n++);return Id=i.slice(e,1<n?1-n:void 0)}function Md(e){var t=e.keyCode;return"charCode"in e?(e=e.charCode,e===0&&t===13&&(e=13)):e=t,e===10&&(e=13),32<=e||e===13?e:0}function Vc(){return!0}function Bx(){return!1}function mr(e){function t(r,n,i,a,o){this._reactName=r,this._targetInst=i,this.type=n,this.nativeEvent=a,this.target=o,this.currentTarget=null;for(var s in e)e.hasOwnProperty(s)&&(r=e[s],this[s]=r?r(a):a[s]);return this.isDefaultPrevented=(a.defaultPrevented!=null?a.defaultPrevented:a.returnValue===!1)?Vc:Bx,this.isPropagationStopped=Bx,this}return Ge(t.prototype,{preventDefault:function(){this.defaultPrevented=!0;var r=this.nativeEvent;r&&(r.preventDefault?r.preventDefault():typeof r.returnValue!="unknown"&&(r.returnValue=!1),this.isDefaultPrevented=Vc)},stopPropagation:function(){var r=this.nativeEvent;r&&(r.stopPropagation?r.stopPropagation():typeof r.cancelBubble!="unknown"&&(r.cancelBubble=!0),this.isPropagationStopped=Vc)},persist:function(){},isPersistent:Vc}),t}var Hs={eventPhase:0,bubbles:0,cancelable:0,timeStamp:function(e){return e.timeStamp||Date.now()},defaultPrevented:0,isTrusted:0},K0=mr(Hs),bc=Ge({},Hs,{view:0,detail:0}),pM=mr(bc),_m,Sm,ml,Mh=Ge({},bc,{screenX:0,screenY:0,clientX:0,clientY:0,pageX:0,pageY:0,ctrlKey:0,shiftKey:0,altKey:0,metaKey:0,getModifierState:G0,button:0,buttons:0,relatedTarget:function(e){return e.relatedTarget===void 0?e.fromElement===e.srcElement?e.toElement:e.fromElement:e.relatedTarget},movementX:function(e){return"movementX"in e?e.movementX:(e!==ml&&(ml&&e.type==="mousemove"?(_m=e.screenX-ml.screenX,Sm=e.screenY-ml.screenY):Sm=_m=0,ml=e),_m)},movementY:function(e){return"movementY"in e?e.movementY:Sm}}),Ux=mr(Mh),mM=Ge({},Mh,{dataTransfer:0}),vM=mr(mM),gM=Ge({},bc,{relatedTarget:0}),Om=mr(gM),yM=Ge({},Hs,{animationName:0,elapsedTime:0,pseudoElement:0}),bM=mr(yM),wM=Ge({},Hs,{clipboardData:function(e){return"clipboardData"in e?e.clipboardData:window.clipboardData}}),xM=mr(wM),_M=Ge({},Hs,{data:0}),Fx=mr(_M),SM={Esc:"Escape",Spacebar:" ",Left:"ArrowLeft",Up:"ArrowUp",Right:"ArrowRight",Down:"ArrowDown",Del:"Delete",Win:"OS",Menu:"ContextMenu",Apps:"ContextMenu",Scroll:"ScrollLock",MozPrintableKey:"Unidentified"},OM={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"},EM={Alt:"altKey",Control:"ctrlKey",Meta:"metaKey",Shift:"shiftKey"};function kM(e){var t=this.nativeEvent;return t.getModifierState?t.getModifierState(e):(e=EM[e])?!!t[e]:!1}function G0(){return kM}var PM=Ge({},bc,{key:function(e){if(e.key){var t=SM[e.key]||e.key;if(t!=="Unidentified")return t}return e.type==="keypress"?(e=Md(e),e===13?"Enter":String.fromCharCode(e)):e.type==="keydown"||e.type==="keyup"?OM[e.keyCode]||"Unidentified":""},code:0,location:0,ctrlKey:0,shiftKey:0,altKey:0,metaKey:0,repeat:0,locale:0,getModifierState:G0,charCode:function(e){return e.type==="keypress"?Md(e):0},keyCode:function(e){return e.type==="keydown"||e.type==="keyup"?e.keyCode:0},which:function(e){return e.type==="keypress"?Md(e):e.type==="keydown"||e.type==="keyup"?e.keyCode:0}}),AM=mr(PM),jM=Ge({},Mh,{pointerId:0,width:0,height:0,pressure:0,tangentialPressure:0,tiltX:0,tiltY:0,twist:0,pointerType:0,isPrimary:0}),zx=mr(jM),TM=Ge({},bc,{touches:0,targetTouches:0,changedTouches:0,altKey:0,metaKey:0,ctrlKey:0,shiftKey:0,getModifierState:G0}),CM=mr(TM),NM=Ge({},Hs,{propertyName:0,elapsedTime:0,pseudoElement:0}),$M=mr(NM),RM=Ge({},Mh,{deltaX:function(e){return"deltaX"in e?e.deltaX:"wheelDeltaX"in e?-e.wheelDeltaX:0},deltaY:function(e){return"deltaY"in e?e.deltaY:"wheelDeltaY"in e?-e.wheelDeltaY:"wheelDelta"in e?-e.wheelDelta:0},deltaZ:0,deltaMode:0}),IM=mr(RM),MM=[9,13,27,32],Y0=Kn&&"CompositionEvent"in window,Ul=null;Kn&&"documentMode"in document&&(Ul=document.documentMode);var DM=Kn&&"TextEvent"in window&&!Ul,qP=Kn&&(!Y0||Ul&&8<Ul&&11>=Ul),Wx=" ",qx=!1;function HP(e,t){switch(e){case"keyup":return MM.indexOf(t.keyCode)!==-1;case"keydown":return t.keyCode!==229;case"keypress":case"mousedown":case"focusout":return!0;default:return!1}}function VP(e){return e=e.detail,typeof e=="object"&&"data"in e?e.data:null}var jo=!1;function LM(e,t){switch(e){case"compositionend":return VP(t);case"keypress":return t.which!==32?null:(qx=!0,Wx);case"textInput":return e=t.data,e===Wx&&qx?null:e;default:return null}}function BM(e,t){if(jo)return e==="compositionend"||!Y0&&HP(e,t)?(e=WP(),Id=V0=Ti=null,jo=!1,e):null;switch(e){case"paste":return null;case"keypress":if(!(t.ctrlKey||t.altKey||t.metaKey)||t.ctrlKey&&t.altKey){if(t.char&&1<t.char.length)return t.char;if(t.which)return String.fromCharCode(t.which)}return null;case"compositionend":return qP&&t.locale!=="ko"?null:t.data;default:return null}}var UM={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 Hx(e){var t=e&&e.nodeName&&e.nodeName.toLowerCase();return t==="input"?!!UM[e.type]:t==="textarea"}function KP(e,t,r,n){OP(n),t=af(t,"onChange"),0<t.length&&(r=new K0("onChange","change",null,r,n),e.push({event:r,listeners:t}))}var Fl=null,su=null;function FM(e){iA(e,0)}function Dh(e){var t=No(e);if(gP(t))return e}function zM(e,t){if(e==="change")return t}var GP=!1;if(Kn){var Em;if(Kn){var km="oninput"in document;if(!km){var Vx=document.createElement("div");Vx.setAttribute("oninput","return;"),km=typeof Vx.oninput=="function"}Em=km}else Em=!1;GP=Em&&(!document.documentMode||9<document.documentMode)}function Kx(){Fl&&(Fl.detachEvent("onpropertychange",YP),su=Fl=null)}function YP(e){if(e.propertyName==="value"&&Dh(su)){var t=[];KP(t,su,e,F0(e)),AP(FM,t)}}function WM(e,t,r){e==="focusin"?(Kx(),Fl=t,su=r,Fl.attachEvent("onpropertychange",YP)):e==="focusout"&&Kx()}function qM(e){if(e==="selectionchange"||e==="keyup"||e==="keydown")return Dh(su)}function HM(e,t){if(e==="click")return Dh(t)}function VM(e,t){if(e==="input"||e==="change")return Dh(t)}function KM(e,t){return e===t&&(e!==0||1/e===1/t)||e!==e&&t!==t}var nn=typeof Object.is=="function"?Object.is:KM;function lu(e,t){if(nn(e,t))return!0;if(typeof e!="object"||e===null||typeof t!="object"||t===null)return!1;var r=Object.keys(e),n=Object.keys(t);if(r.length!==n.length)return!1;for(n=0;n<r.length;n++){var i=r[n];if(!Bv.call(t,i)||!nn(e[i],t[i]))return!1}return!0}function Gx(e){for(;e&&e.firstChild;)e=e.firstChild;return e}function Yx(e,t){var r=Gx(e);e=0;for(var n;r;){if(r.nodeType===3){if(n=e+r.textContent.length,e<=t&&n>=t)return{node:r,offset:t-e};e=n}e:{for(;r;){if(r.nextSibling){r=r.nextSibling;break e}r=r.parentNode}r=void 0}r=Gx(r)}}function XP(e,t){return e&&t?e===t?!0:e&&e.nodeType===3?!1:t&&t.nodeType===3?XP(e,t.parentNode):"contains"in e?e.contains(t):e.compareDocumentPosition?!!(e.compareDocumentPosition(t)&16):!1:!1}function QP(){for(var e=window,t=Qd();t instanceof e.HTMLIFrameElement;){try{var r=typeof t.contentWindow.location.href=="string"}catch{r=!1}if(r)e=t.contentWindow;else break;t=Qd(e.document)}return t}function X0(e){var t=e&&e.nodeName&&e.nodeName.toLowerCase();return t&&(t==="input"&&(e.type==="text"||e.type==="search"||e.type==="tel"||e.type==="url"||e.type==="password")||t==="textarea"||e.contentEditable==="true")}function GM(e){var t=QP(),r=e.focusedElem,n=e.selectionRange;if(t!==r&&r&&r.ownerDocument&&XP(r.ownerDocument.documentElement,r)){if(n!==null&&X0(r)){if(t=n.start,e=n.end,e===void 0&&(e=t),"selectionStart"in r)r.selectionStart=t,r.selectionEnd=Math.min(e,r.value.length);else if(e=(t=r.ownerDocument||document)&&t.defaultView||window,e.getSelection){e=e.getSelection();var i=r.textContent.length,a=Math.min(n.start,i);n=n.end===void 0?a:Math.min(n.end,i),!e.extend&&a>n&&(i=n,n=a,a=i),i=Yx(r,a);var o=Yx(r,n);i&&o&&(e.rangeCount!==1||e.anchorNode!==i.node||e.anchorOffset!==i.offset||e.focusNode!==o.node||e.focusOffset!==o.offset)&&(t=t.createRange(),t.setStart(i.node,i.offset),e.removeAllRanges(),a>n?(e.addRange(t),e.extend(o.node,o.offset)):(t.setEnd(o.node,o.offset),e.addRange(t)))}}for(t=[],e=r;e=e.parentNode;)e.nodeType===1&&t.push({element:e,left:e.scrollLeft,top:e.scrollTop});for(typeof r.focus=="function"&&r.focus(),r=0;r<t.length;r++)e=t[r],e.element.scrollLeft=e.left,e.element.scrollTop=e.top}}var YM=Kn&&"documentMode"in document&&11>=document.documentMode,To=null,ig=null,zl=null,ag=!1;function Xx(e,t,r){var n=r.window===r?r.document:r.nodeType===9?r:r.ownerDocument;ag||To==null||To!==Qd(n)||(n=To,"selectionStart"in n&&X0(n)?n={start:n.selectionStart,end:n.selectionEnd}:(n=(n.ownerDocument&&n.ownerDocument.defaultView||window).getSelection(),n={anchorNode:n.anchorNode,anchorOffset:n.anchorOffset,focu
vendor: 4,501 bytes, line 37
37sNode:n.focusNode,focusOffset:n.focusOffset}),zl&&lu(zl,n)||(zl=n,n=af(ig,"onSelect"),0<n.length&&(t=new K0("onSelect","select",null,t,r),e.push({event:t,listeners:n}),t.target=To)))}function Kc(e,t){var r={};return r[e.toLowerCase()]=t.toLowerCase(),r["Webkit"+e]="webkit"+t,r["Moz"+e]="moz"+t,r}var Co={animationend:Kc("Animation","AnimationEnd"),animationiteration:Kc("Animation","AnimationIteration"),animationstart:Kc("Animation","AnimationStart"),transitionend:Kc("Transition","TransitionEnd")},Pm={},JP={};Kn&&(JP=document.createElement("div").style,"AnimationEvent"in window||(delete Co.animationend.animation,delete Co.animationiteration.animation,delete Co.animationstart.animation),"TransitionEvent"in window||delete Co.transitionend.transition);function Lh(e){if(Pm[e])return Pm[e];if(!Co[e])return e;var t=Co[e],r;for(r in t)if(t.hasOwnProperty(r)&&r in JP)return Pm[e]=t[r];return e}var ZP=Lh("animationend"),eA=Lh("animationiteration"),tA=Lh("animationstart"),rA=Lh("transitionend"),nA=new Map,Qx="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 Xi(e,t){nA.set(e,t),Ja(t,[e])}for(var Am=0;Am<Qx.length;Am++){var jm=Qx[Am],XM=jm.toLowerCase(),QM=jm[0].toUpperCase()+jm.slice(1);Xi(XM,"on"+QM)}Xi(ZP,"onAnimationEnd");Xi(eA,"onAnimationIteration");Xi(tA,"onAnimationStart");Xi("dblclick","onDoubleClick");Xi("focusin","onFocus");Xi("focusout","onBlur");Xi(rA,"onTransitionEnd");ds("onMouseEnter",["mouseout","mouseover"]);ds("onMouseLeave",["mouseout","mouseover"]);ds("onPointerEnter",["pointerout","pointerover"]);ds("onPointerLeave",["pointerout","pointerover"]);Ja("onChange","change click focusin focusout input keydown keyup selectionchange".split(" "));Ja("onSelect","focusout contextmenu dragend focusin keydown keyup mousedown mouseup selectionchange".split(" "));Ja("onBeforeInput",["compositionend","keypress","textInput","paste"]);Ja("onCompositionEnd","compositionend focusout keydown keypress keyup mousedown".split(" "));Ja("onCompositionStart","compositionstart focusout keydown keypress keyup mousedown".split(" "));Ja("onCompositionUpdate","compositionupdate focusout keydown keypress keyup mousedown".split(" "));var Il="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(" "),JM=new Set("cancel close invalid load scroll toggle".split(" ").concat(Il));function Jx(e,t,r){var n=e.type||"unknown-event";e.currentTarget=r,XI(n,t,void 0,e),e.currentTarget=null}function iA(e,t){t=(t&4)!==0;for(var r=0;r<e.length;r++){var n=e[r],i=n.event;n=n.listeners;e:{var a=void 0;if(t)for(var o=n.length-1;0<=o;o--){var s=n[o],l=s.instance,u=s.currentTarget;if(s=s.listener,l!==a&&i.isPropagationStopped())break e;Jx(i,s,u),a=l}else for(o=0;o<n.length;o++){if(s=n[o],l=s.instance,u=s.currentTarget,s=s.listener,l!==a&&i.isPropagationStopped())break e;Jx(i,s,u),a=l}}}if(Zd)throw e=eg,Zd=!1,eg=null,e}function De(e,t){var r=t[cg];r===void 0&&(r=t[cg]=new Set);var n=e+"__bubble";r.has(n)||(aA(t,e,2,!1),r.add(n))}function Tm(e,t,r){var n=0;t&&(n|=4),aA(r,e,n,t)}var Gc="_reactListening"+Math.random().toString(36).slice(2);function uu(e){if(!e[Gc]){e[Gc]=!0,fP.forEach(function(r){r!=="selectionchange"&&(JM.has(r)||Tm(r,!1,e),Tm(r,!0,e))});var t=e.nodeType===9?e:e.ownerDocument;t===null||t[Gc]||(t[Gc]=!0,Tm("selectionchange",!1,t))}}function aA(e,t,r,n){switch(zP(t)){case 1:var i=fM;break;case 4:i=hM;break;default:i=H0}r=i.bind(null,t,r,e),i=void 0,!Zv||t!=="touchstart"&&t!=="touchmove"&&t!=="wheel"||(i=!0),n?i!==void 0?e.addEventListener(t,r,{capture:!0,passive:i}):e.addEventListener(t,r,!0):i!==void 0?e.addEventListener(t,r,{passive:i}):e.addEventListener(t,r,!1)}function Cm(e,t,r,n,i){var a=n;if(!(t&1)&&!(t&2)&&n!==null)e:for(;;){if(n===null)return;var o=n.tag;if(o===3||o===4){var s=n.stateNode.containerInfo;
vendor: 5,572 bytes, lines 37-38
37if(s===i||s.nodeType===8&&s.parentNode===i)break;if(o===4)for(o=n.return;o!==null;){var l=o.tag;if((l===3||l===4)&&(l=o.stateNode.containerInfo,l===i||l.nodeType===8&&l.parentNode===i))return;o=o.return}for(;s!==null;){if(o=ba(s),o===null)return;if(l=o.tag,l===5||l===6){n=a=o;continue e}s=s.parentNode}}n=n.return}AP(function(){var u=a,d=F0(r),c=[];e:{var f=nA.get(e);if(f!==void 0){var h=K0,v=e;switch(e){case"keypress":if(Md(r)===0)break e;case"keydown":case"keyup":h=AM;break;case"focusin":v="focus",h=Om;break;case"focusout":v="blur",h=Om;break;case"beforeblur":case"afterblur":h=Om;break;case"click":if(r.button===2)break e;case"auxclick":case"dblclick":case"mousedown":case"mousemove":case"mouseup":case"mouseout":case"mouseover":case"contextmenu":h=Ux;break;case"drag":case"dragend":case"dragenter":case"dragexit":case"dragleave":case"dragover":case"dragstart":case"drop":h=vM;break;case"touchcancel":case"touchend":case"touchmove":case"touchstart":h=CM;break;case ZP:case eA:case tA:h=bM;break;case rA:h=$M;break;case"scroll":h=pM;break;case"wheel":h=IM;break;case"copy":case"cut":case"paste":h=xM;break;case"gotpointercapture":case"lostpointercapture":case"pointercancel":case"pointerdown":case"pointermove":case"pointerout":case"pointerover":case"pointerup":h=zx}var m=(t&4)!==0,g=!m&&e==="scroll",y=m?f!==null?f+"Capture":null:f;m=[];for(var b=u,w;b!==null;){w=b;var _=w.stateNode;if(w.tag===5&&_!==null&&(w=_,y!==null&&(_=nu(b,y),_!=null&&m.push(cu(b,_,w)))),g)break;b=b.return}0<m.length&&(f=new h(f,v,null,r,d),c.push({event:f,listeners:m}))}}if(!(t&7)){e:{if(f=e==="mouseover"||e==="pointerover",h=e==="mouseout"||e==="pointerout",f&&r!==Qv&&(v=r.relatedTarget||r.fromElement)&&(ba(v)||v[Gn]))break e;if((h||f)&&(f=d.window===d?d:(f=d.ownerDocument)?f.defaultView||f.parentWindow:window,h?(v=r.relatedTarget||r.toElement,h=u,v=v?ba(v):null,v!==null&&(g=Za(v),v!==g||v.tag!==5&&v.tag!==6)&&(v=null)):(h=null,v=u),h!==v)){if(m=Ux,_="onMouseLeave",y="onMouseEnter",b="mouse",(e==="pointerout"||e==="pointerover")&&(m=zx,_="onPointerLeave",y="onPointerEnter",b="pointer"),g=h==null?f:No(h),w=v==null?f:No(v),f=new m(_,b+"leave",h,r,d),f.target=g,f.relatedTarget=w,_=null,ba(d)===u&&(m=new m(y,b+"enter",v,r,d),m.target=w,m.relatedTarget=g,_=m),g=_,h&&v)t:{for(m=h,y=v,b=0,w=m;w;w=uo(w))b++;for(w=0,_=y;_;_=uo(_))w++;for(;0<b-w;)m=uo(m),b--;for(;0<w-b;)y=uo(y),w--;for(;b--;){if(m===y||y!==null&&m===y.alternate)break t;m=uo(m),y=uo(y)}m=null}else m=null;h!==null&&Zx(c,f,h,m,!1),v!==null&&g!==null&&Zx(c,g,v,m,!0)}}e:{if(f=u?No(u):window,h=f.nodeName&&f.nodeName.toLowerCase(),h==="select"||h==="input"&&f.type==="file")var x=zM;else if(Hx(f))if(GP)x=VM;else{x=qM;var S=WM}else(h=f.nodeName)&&h.toLowerCase()==="input"&&(f.type==="checkbox"||f.type==="radio")&&(x=HM);if(x&&(x=x(e,u))){KP(c,x,r,d);break e}S&&S(e,f,u),e==="focusout"&&(S=f._wrapperState)&&S.controlled&&f.type==="number"&&Vv(f,"number",f.value)}switch(S=u?No(u):window,e){case"focusin":(Hx(S)||S.contentEditable==="true")&&(To=S,ig=u,zl=null);break;case"focusout":zl=ig=To=null;break;case"mousedown":ag=!0;break;case"contextmenu":case"mouseup":case"dragend":ag=!1,Xx(c,r,d);break;case"selectionchange":if(YM)break;case"keydown":case"keyup":Xx(c,r,d)}var E;if(Y0)e:{switch(e){case"compositionstart":var k="onCompositionStart";break e;case"compositionend":k="onCompositionEnd";break e;case"compositionupdate":k="onCompositionUpdate";break e}k=void 0}else jo?HP(e,r)&&(k="onCompositionEnd"):e==="keydown"&&r.keyCode===229&&(k="onCompositionStart");k&&(qP&&r.locale!=="ko"&&(jo||k!=="onCompositionStart"?k==="onCompositionEnd"&&jo&&(E=WP()):(Ti=d,V0="value"in Ti?Ti.value:Ti.textContent,jo=!0)),S=af(u,k),0<S.length&&(k=new Fx(k,e,null,r,d),c.push({event:k,listeners:S}),E?k.data=E:(E=VP(r),E!==null&&(k.data=E)))),(E=DM?LM(e,r):BM(e,r))&&(u=af(u,"onBeforeInput"),0<u.length&&(d=new Fx("onBeforeInput","beforeinput",null,r,d),c.push({event:d,listeners:u}),d.data=E))}iA(c,t)})}function cu(e,t,r){return{instance:e,listener:t,currentTarget:r}}function af(e,t){for(var r=t+"Capture",n=[];e!==null;){var i=e,a=i.stateNode;i.tag===5&&a!==null&&(i=a,a=nu(e,r),a!=null&&n.unshift(cu(e,a,i)),a=nu(e,t),a!=null&&n.push(cu(e,a,i))),e=e.return}return n}function uo(e){if(e===null)return null;do e=e.return;while(e&&e.tag!==5);return e||null}function Zx(e,t,r,n,i){for(var a=t._reactName,o=[];r!==null&&r!==n;){var s=r,l=s.alternate,u=s.stateNode;if(l!==null&&l===n)break;s.tag===5&&u!==null&&(s=u,i?(l=nu(r,a),l!=null&&o.unshift(cu(r,l,s))):i||(l=nu(r,a),l!=null&&o.push(cu(r,l,s)))),r=r.return}o.length!==0&&e.push({event:t,listeners:o})}var ZM=/\r\n?/g,eD=/\u0000|\uFFFD/g;function e1(e){return(typeof e=="string"?e:""+e).replace(ZM,` 38`).replace(eD,"")}function Yc(e,t,r){if(t=e1(t),e1(e)!==t&&r)throw Error(V(425))}function of(){}var og=null,sg=null;function lg(e,t){return e==="textarea"||e==="noscript"||typeof t.children=="string"||typeof t.children=="number"||typeof t.dangerouslySetInnerHTML=="object"&&t.dangerouslySetInnerHTML!==null&&t.dangerouslySetInnerHTML.__html!=null}var ug=typeof setTimeout=="function"?setTimeout:void 0,tD=typeof clearTimeout=="function"?clearTimeout:void 0,t1=typeof Promise=="function"?Promise:void 0,rD=typeof queueMicrotask=="function"?queueMicrotask:typeof t1<"u"?function(e){return t1.resolve(null).then(e).catch(nD)}:ug;function nD(e){setTimeout(function(){throw e})}function Nm(e,t){var r=t,n=0;do{var i=r.nextSibling;if(e.removeChild(r),i&&i.nodeType===8)if(r=i.data,r==="/$"){if(n===0){e.removeChild(i),ou(t);return}n--}else r!=="$"&&r!=="$?"&&r!=="$!"||n++;r=i}
vendor: 4,658 bytes, line 38
38while(r);ou(t)}function Di(e){for(;e!=null;e=e.nextSibling){var t=e.nodeType;if(t===1||t===3)break;if(t===8){if(t=e.data,t==="$"||t==="$!"||t==="$?")break;if(t==="/$")return null}}return e}function r1(e){e=e.previousSibling;for(var t=0;e;){if(e.nodeType===8){var r=e.data;if(r==="$"||r==="$!"||r==="$?"){if(t===0)return e;t--}else r==="/$"&&t++}e=e.previousSibling}return null}var Vs=Math.random().toString(36).slice(2),gn="__reactFiber$"+Vs,du="__reactProps$"+Vs,Gn="__reactContainer$"+Vs,cg="__reactEvents$"+Vs,iD="__reactListeners$"+Vs,aD="__reactHandles$"+Vs;function ba(e){var t=e[gn];if(t)return t;for(var r=e.parentNode;r;){if(t=r[Gn]||r[gn]){if(r=t.alternate,t.child!==null||r!==null&&r.child!==null)for(e=r1(e);e!==null;){if(r=e[gn])return r;e=r1(e)}return t}e=r,r=e.parentNode}return null}function wc(e){return e=e[gn]||e[Gn],!e||e.tag!==5&&e.tag!==6&&e.tag!==13&&e.tag!==3?null:e}function No(e){if(e.tag===5||e.tag===6)return e.stateNode;throw Error(V(33))}function Bh(e){return e[du]||null}var dg=[],$o=-1;function Qi(e){return{current:e}}function Ue(e){0>$o||(e.current=dg[$o],dg[$o]=null,$o--)}function Ie(e,t){$o++,dg[$o]=e.current,e.current=t}var Hi={},It=Qi(Hi),Yt=Qi(!1),Fa=Hi;function fs(e,t){var r=e.type.contextTypes;if(!r)return Hi;var n=e.stateNode;if(n&&n.__reactInternalMemoizedUnmaskedChildContext===t)return n.__reactInternalMemoizedMaskedChildContext;var i={},a;for(a in r)i[a]=t[a];return n&&(e=e.stateNode,e.__reactInternalMemoizedUnmaskedChildContext=t,e.__reactInternalMemoizedMaskedChildContext=i),i}function Xt(e){return e=e.childContextTypes,e!=null}function sf(){Ue(Yt),Ue(It)}function n1(e,t,r){if(It.current!==Hi)throw Error(V(168));Ie(It,t),Ie(Yt,r)}function oA(e,t,r){var n=e.stateNode;if(t=t.childContextTypes,typeof n.getChildContext!="function")return r;n=n.getChildContext();for(var i in n)if(!(i in t))throw Error(V(108,WI(e)||"Unknown",i));return Ge({},r,n)}function lf(e){return e=(e=e.stateNode)&&e.__reactInternalMemoizedMergedChildContext||Hi,Fa=It.current,Ie(It,e),Ie(Yt,Yt.current),!0}function i1(e,t,r){var n=e.stateNode;if(!n)throw Error(V(169));r?(e=oA(e,t,Fa),n.__reactInternalMemoizedMergedChildContext=e,Ue(Yt),Ue(It),Ie(It,e)):Ue(Yt),Ie(Yt,r)}var Ln=null,Uh=!1,$m=!1;function sA(e){Ln===null?Ln=[e]:Ln.push(e)}function oD(e){Uh=!0,sA(e)}function Ji(){if(!$m&&Ln!==null){$m=!0;var e=0,t=Ee;try{var r=Ln;for(Ee=1;e<r.length;e++){var n=r[e];do n=n(!0);while(n!==null)}Ln=null,Uh=!1}catch(i){throw Ln!==null&&(Ln=Ln.slice(e+1)),NP(z0,Ji),i}finally{Ee=t,$m=!1}}return null}var Ro=[],Io=0,uf=null,cf=0,xr=[],_r=0,za=null,Un=1,Fn="";function da(e,t){Ro[Io++]=cf,Ro[Io++]=uf,uf=e,cf=t}function lA(e,t,r){xr[_r++]=Un,xr[_r++]=Fn,xr[_r++]=za,za=e;var n=Un;e=Fn;var i=32-Qr(n)-1;n&=~(1<<i),r+=1;var a=32-Qr(t)+i;if(30<a){var o=i-i%5;a=(n&(1<<o)-1).toString(32),n>>=o,i-=o,Un=1<<32-Qr(t)+i|r<<i|n,Fn=a+e}else Un=1<<a|r<<i|n,Fn=e}function Q0(e){e.return!==null&&(da(e,1),lA(e,1,0))}function J0(e){for(;e===uf;)uf=Ro[--Io],Ro[Io]=null,cf=Ro[--Io],Ro[Io]=null;for(;e===za;)za=xr[--_r],xr[_r]=null,Fn=xr[--_r],xr[_r]=null,Un=xr[--_r],xr[_r]=null}var ur=null,lr=null,We=!1,Gr=null;function uA(e,t){var r=Sr(5,null,null,0);r.elementType="DELETED",r.stateNode=t,r.return=e,t=e.deletions,t===null?(e.deletions=[r],e.flags|=16):t.push(r)}function a1(e,t){switch(e.tag){case 5:var r=e.type;return t=t.nodeType!==1||r.toLowerCase()!==t.nodeName.toLowerCase()?null:t,t!==null?(e.stateNode=t,ur=e,lr=Di(t.firstChild),!0):!1;case 6:return t=e.pendingProps===""||t.nodeType!==3?null:t,t!==null?(e.stateNode=t,ur=e,lr=null,!0):!1;case 13:return t=t.nodeType!==8?null:t,t!==null?(r=za!==null?{id:Un,overflow:Fn}:null,e.memoizedState={dehydrated:t,treeContext:r,retryLane:1073741824},r=Sr(18,null,null,0),r.stateNode=t,r.return=e,e.child=r,ur=e,lr=null,!0):!1;default:return!1}}function fg(e){return(e.mode&1)!==0&&(e.flags&128)===0}function hg(e){if(We){var t=lr;if(t){var r=t;if(!a1(e,t)){if(fg(e))throw Error(V(418));t=Di(r.nextSibling);var n=ur;t&&a1(e,t)?uA(n,r):(e.flags=e.flags&-4097|2,We=!1,ur=e)}}else{if(fg(e))throw Error(V(418));e.flags=e.flags&-4097|2,We=!1,ur=e}}}function o1(e){for(e=e.return;e!==null&&e.tag!==5&&e.tag!==3&&e.tag!==13;)e=e.return;ur=e}function Xc(e){if(e!==ur)return!1;if(!We)return o1(e),We=!0,!1;var t;if((t=e.tag!==3)&&!(t=e.tag!==5)&&(t=e.type,t=t!=="head"&&t!=="body"&&!lg(e.type,e.memoizedProps)),t&&(t=lr)){if(fg(e))throw cA(),Error(V(418));for(;t;)uA(e,t),t=Di(t.nextSibling)}if(o1(e),e.tag===13){if(e=e.memoizedState,e=e!==null?e.dehydrated:null,!e)throw Error(V(317));e:{for(e=e.nextSibling,t=0;e;){if(e.nodeType===8){var r=e.data;if(r==="/$"){if(t===0){lr=Di(e.nextSibling);break e}t--}
vendor: 4,724 bytes, line 38
38else r!=="$"&&r!=="$!"&&r!=="$?"||t++}e=e.nextSibling}lr=null}}else lr=ur?Di(e.stateNode.nextSibling):null;return!0}function cA(){for(var e=lr;e;)e=Di(e.nextSibling)}function hs(){lr=ur=null,We=!1}function Z0(e){Gr===null?Gr=[e]:Gr.push(e)}var sD=ri.ReactCurrentBatchConfig;function vl(e,t,r){if(e=r.ref,e!==null&&typeof e!="function"&&typeof e!="object"){if(r._owner){if(r=r._owner,r){if(r.tag!==1)throw Error(V(309));var n=r.stateNode}if(!n)throw Error(V(147,e));var i=n,a=""+e;return t!==null&&t.ref!==null&&typeof t.ref=="function"&&t.ref._stringRef===a?t.ref:(t=function(o){var s=i.refs;o===null?delete s[a]:s[a]=o},t._stringRef=a,t)}if(typeof e!="string")throw Error(V(284));if(!r._owner)throw Error(V(290,e))}return e}function Qc(e,t){throw e=Object.prototype.toString.call(t),Error(V(31,e==="[object Object]"?"object with keys {"+Object.keys(t).join(", ")+"}":e))}function s1(e){var t=e._init;return t(e._payload)}function dA(e){function t(y,b){if(e){var w=y.deletions;w===null?(y.deletions=[b],y.flags|=16):w.push(b)}}function r(y,b){if(!e)return null;for(;b!==null;)t(y,b),b=b.sibling;return null}function n(y,b){for(y=new Map;b!==null;)b.key!==null?y.set(b.key,b):y.set(b.index,b),b=b.sibling;return y}function i(y,b){return y=Fi(y,b),y.index=0,y.sibling=null,y}function a(y,b,w){return y.index=w,e?(w=y.alternate,w!==null?(w=w.index,w<b?(y.flags|=2,b):w):(y.flags|=2,b)):(y.flags|=1048576,b)}function o(y){return e&&y.alternate===null&&(y.flags|=2),y}function s(y,b,w,_){return b===null||b.tag!==6?(b=Um(w,y.mode,_),b.return=y,b):(b=i(b,w),b.return=y,b)}function l(y,b,w,_){var x=w.type;return x===Ao?d(y,b,w.props.children,_,w.key):b!==null&&(b.elementType===x||typeof x=="object"&&x!==null&&x.$$typeof===yi&&s1(x)===b.type)?(_=i(b,w.props),_.ref=vl(y,b,w),_.return=y,_):(_=Wd(w.type,w.key,w.props,null,y.mode,_),_.ref=vl(y,b,w),_.return=y,_)}function u(y,b,w,_){return b===null||b.tag!==4||b.stateNode.containerInfo!==w.containerInfo||b.stateNode.implementation!==w.implementation?(b=Fm(w,y.mode,_),b.return=y,b):(b=i(b,w.children||[]),b.return=y,b)}function d(y,b,w,_,x){return b===null||b.tag!==7?(b=Ra(w,y.mode,_,x),b.return=y,b):(b=i(b,w),b.return=y,b)}function c(y,b,w){if(typeof b=="string"&&b!==""||typeof b=="number")return b=Um(""+b,y.mode,w),b.return=y,b;if(typeof b=="object"&&b!==null){switch(b.$$typeof){case Uc:return w=Wd(b.type,b.key,b.props,null,y.mode,w),w.ref=vl(y,null,b),w.return=y,w;case Po:return b=Fm(b,y.mode,w),b.return=y,b;case yi:var _=b._init;return c(y,_(b._payload),w)}if($l(b)||dl(b))return b=Ra(b,y.mode,w,null),b.return=y,b;Qc(y,b)}return null}function f(y,b,w,_){var x=b!==null?b.key:null;if(typeof w=="string"&&w!==""||typeof w=="number")return x!==null?null:s(y,b,""+w,_);if(typeof w=="object"&&w!==null){switch(w.$$typeof){case Uc:return w.key===x?l(y,b,w,_):null;case Po:return w.key===x?u(y,b,w,_):null;case yi:return x=w._init,f(y,b,x(w._payload),_)}if($l(w)||dl(w))return x!==null?null:d(y,b,w,_,null);Qc(y,w)}return null}function h(y,b,w,_,x){if(typeof _=="string"&&_!==""||typeof _=="number")return y=y.get(w)||null,s(b,y,""+_,x);if(typeof _=="object"&&_!==null){switch(_.$$typeof){case Uc:return y=y.get(_.key===null?w:_.key)||null,l(b,y,_,x);case Po:return y=y.get(_.key===null?w:_.key)||null,u(b,y,_,x);case yi:var S=_._init;return h(y,b,w,S(_._payload),x)}if($l(_)||dl(_))return y=y.get(w)||null,d(b,y,_,x,null);Qc(b,_)}return null}function v(y,b,w,_){for(var x=null,S=null,E=b,k=b=0,P=null;E!==null&&k<w.length;k++){E.index>k?(P=E,E=null):P=E.sibling;var C=f(y,E,w[k],_);if(C===null){E===null&&(E=P);break}e&&E&&C.alternate===null&&t(y,E),b=a(C,b,k),S===null?x=C:S.sibling=C,S=C,E=P}if(k===w.length)return r(y,E),We&&da(y,k),x;if(E===null){for(;k<w.length;k++)E=c(y,w[k],_),E!==null&&(b=a(E,b,k),S===null?x=E:S.sibling=E,S=E);return We&&da(y,k),x}for(E=n(y,E);k<w.length;k++)P=h(E,y,k,w[k],_),P!==null&&(e&&P.alternate!==null&&E.delete(P.key===null?k:P.key),b=a(P,b,k),S===null?x=P:S.sibling=P,S=P);return e&&E.forEach(function(N){return t(y,N)}),We&&da(y,k),x}function m(y,b,w,_){var x=dl(w);if(typeof x!="function")throw Error(V(150));if(w=x.call(w),w==null)throw Error(V(151));for(var S=x=null,E=b,k=b=0,P=null,C=w.next();E!==null&&!C.done;k++,C=w.next()){E.index>k?(P=E,E=null):P=E.sibling;var N=f(y,E,C.value,_);if(N===null){E===null&&(E=P);break}e&&E&&N.alternate===null&&t(y,E),b=a(N,b,k),S===null?x=N:S.sibling=N,S=N,E=P}if(C.done)return r(y,E),We&&da(y,k),x;if(E===null){for(;!C.done;k++,C=w.next())C=c(y,C.value,_),C!==null&&(b=a(C,b,k),S===null?x=C:S.sibling=C,S=C);return We&&da(y,k),x}for(E=n(y,E);!C.done;k++,C=w.next())C=h(E,y,k,C.value,_),C!==null&&(e&&C.alternate!==null&&E.delete(C.key===null?k:C.key),b=a(C,b,k),S===null?x=C:S.sibling=C,S=C);
vendor: 1,088 bytes, line 38
38return e&&E.forEach(function($){return t(y,$)}),We&&da(y,k),x}function g(y,b,w,_){if(typeof w=="object"&&w!==null&&w.type===Ao&&w.key===null&&(w=w.props.children),typeof w=="object"&&w!==null){switch(w.$$typeof){case Uc:e:{for(var x=w.key,S=b;S!==null;){if(S.key===x){if(x=w.type,x===Ao){if(S.tag===7){r(y,S.sibling),b=i(S,w.props.children),b.return=y,y=b;break e}}else if(S.elementType===x||typeof x=="object"&&x!==null&&x.$$typeof===yi&&s1(x)===S.type){r(y,S.sibling),b=i(S,w.props),b.ref=vl(y,S,w),b.return=y,y=b;break e}r(y,S);break}else t(y,S);S=S.sibling}w.type===Ao?(b=Ra(w.props.children,y.mode,_,w.key),b.return=y,y=b):(_=Wd(w.type,w.key,w.props,null,y.mode,_),_.ref=vl(y,b,w),_.return=y,y=_)}return o(y);case Po:e:{for(S=w.key;b!==null;){if(b.key===S)if(b.tag===4&&b.stateNode.containerInfo===w.containerInfo&&b.stateNode.implementation===w.implementation){r(y,b.sibling),b=i(b,w.children||[]),b.return=y,y=b;break e}else{r(y,b);break}else t(y,b);b=b.sibling}b=Fm(w,y.mode,_),b.return=y,y=b}return o(y);case yi:return S=w._init,g(y,b,S(w._payload),_)}if($l(w))return v(y,b,w,_);
vendor: 5,160 bytes, line 38
38if(dl(w))return m(y,b,w,_);Qc(y,w)}return typeof w=="string"&&w!==""||typeof w=="number"?(w=""+w,b!==null&&b.tag===6?(r(y,b.sibling),b=i(b,w),b.return=y,y=b):(r(y,b),b=Um(w,y.mode,_),b.return=y,y=b),o(y)):r(y,b)}return g}var ps=dA(!0),fA=dA(!1),df=Qi(null),ff=null,Mo=null,eb=null;function tb(){eb=Mo=ff=null}function rb(e){var t=df.current;Ue(df),e._currentValue=t}function pg(e,t,r){for(;e!==null;){var n=e.alternate;if((e.childLanes&t)!==t?(e.childLanes|=t,n!==null&&(n.childLanes|=t)):n!==null&&(n.childLanes&t)!==t&&(n.childLanes|=t),e===r)break;e=e.return}}function Ko(e,t){ff=e,eb=Mo=null,e=e.dependencies,e!==null&&e.firstContext!==null&&(e.lanes&t&&(Vt=!0),e.firstContext=null)}function Pr(e){var t=e._currentValue;if(eb!==e)if(e={context:e,memoizedValue:t,next:null},Mo===null){if(ff===null)throw Error(V(308));Mo=e,ff.dependencies={lanes:0,firstContext:e}}else Mo=Mo.next=e;return t}var wa=null;function nb(e){wa===null?wa=[e]:wa.push(e)}function hA(e,t,r,n){var i=t.interleaved;return i===null?(r.next=r,nb(t)):(r.next=i.next,i.next=r),t.interleaved=r,Yn(e,n)}function Yn(e,t){e.lanes|=t;var r=e.alternate;for(r!==null&&(r.lanes|=t),r=e,e=e.return;e!==null;)e.childLanes|=t,r=e.alternate,r!==null&&(r.childLanes|=t),r=e,e=e.return;return r.tag===3?r.stateNode:null}var bi=!1;function ib(e){e.updateQueue={baseState:e.memoizedState,firstBaseUpdate:null,lastBaseUpdate:null,shared:{pending:null,interleaved:null,lanes:0},effects:null}}function pA(e,t){e=e.updateQueue,t.updateQueue===e&&(t.updateQueue={baseState:e.baseState,firstBaseUpdate:e.firstBaseUpdate,lastBaseUpdate:e.lastBaseUpdate,shared:e.shared,effects:e.effects})}function qn(e,t){return{eventTime:e,lane:t,tag:0,payload:null,callback:null,next:null}}function Li(e,t,r){var n=e.updateQueue;if(n===null)return null;if(n=n.shared,he&2){var i=n.pending;return i===null?t.next=t:(t.next=i.next,i.next=t),n.pending=t,Yn(e,r)}return i=n.interleaved,i===null?(t.next=t,nb(n)):(t.next=i.next,i.next=t),n.interleaved=t,Yn(e,r)}function Dd(e,t,r){if(t=t.updateQueue,t!==null&&(t=t.shared,(r&4194240)!==0)){var n=t.lanes;n&=e.pendingLanes,r|=n,t.lanes=r,W0(e,r)}}function l1(e,t){var r=e.updateQueue,n=e.alternate;if(n!==null&&(n=n.updateQueue,r===n)){var i=null,a=null;if(r=r.firstBaseUpdate,r!==null){do{var o={eventTime:r.eventTime,lane:r.lane,tag:r.tag,payload:r.payload,callback:r.callback,next:null};a===null?i=a=o:a=a.next=o,r=r.next}while(r!==null);a===null?i=a=t:a=a.next=t}else i=a=t;r={baseState:n.baseState,firstBaseUpdate:i,lastBaseUpdate:a,shared:n.shared,effects:n.effects},e.updateQueue=r;return}e=r.lastBaseUpdate,e===null?r.firstBaseUpdate=t:e.next=t,r.lastBaseUpdate=t}function hf(e,t,r,n){var i=e.updateQueue;bi=!1;var a=i.firstBaseUpdate,o=i.lastBaseUpdate,s=i.shared.pending;if(s!==null){i.shared.pending=null;var l=s,u=l.next;l.next=null,o===null?a=u:o.next=u,o=l;var d=e.alternate;d!==null&&(d=d.updateQueue,s=d.lastBaseUpdate,s!==o&&(s===null?d.firstBaseUpdate=u:s.next=u,d.lastBaseUpdate=l))}if(a!==null){var c=i.baseState;o=0,d=u=l=null,s=a;do{var f=s.lane,h=s.eventTime;if((n&f)===f){d!==null&&(d=d.next={eventTime:h,lane:0,tag:s.tag,payload:s.payload,callback:s.callback,next:null});e:{var v=e,m=s;switch(f=t,h=r,m.tag){case 1:if(v=m.payload,typeof v=="function"){c=v.call(h,c,f);break e}c=v;break e;case 3:v.flags=v.flags&-65537|128;case 0:if(v=m.payload,f=typeof v=="function"?v.call(h,c,f):v,f==null)break e;c=Ge({},c,f);break e;case 2:bi=!0}}s.callback!==null&&s.lane!==0&&(e.flags|=64,f=i.effects,f===null?i.effects=[s]:f.push(s))}else h={eventTime:h,lane:f,tag:s.tag,payload:s.payload,callback:s.callback,next:null},d===null?(u=d=h,l=c):d=d.next=h,o|=f;if(s=s.next,s===null){if(s=i.shared.pending,s===null)break;f=s,s=f.next,f.next=null,i.lastBaseUpdate=f,i.shared.pending=null}}while(!0);if(d===null&&(l=c),i.baseState=l,i.firstBaseUpdate=u,i.lastBaseUpdate=d,t=i.shared.interleaved,t!==null){i=t;do o|=i.lane,i=i.next;while(i!==t)}else a===null&&(i.shared.lanes=0);qa|=o,e.lanes=o,e.memoizedState=c}}function u1(e,t,r){if(e=t.effects,t.effects=null,e!==null)for(t=0;t<e.length;t++){var n=e[t],i=n.callback;if(i!==null){if(n.callback=null,n=r,typeof i!="function")throw Error(V(191,i));i.call(n)}}}var xc={},_n=Qi(xc),fu=Qi(xc),hu=Qi(xc);function xa(e){if(e===xc)throw Error(V(174));return e}function ab(e,t){switch(Ie(hu,t),Ie(fu,e),Ie(_n,xc),e=t.nodeType,e){case 9:case 11:t=(t=t.documentElement)?t.namespaceURI:Gv(null,"");break;default:e=e===8?t.parentNode:t,t=e.namespaceURI||null,e=e.tagName,t=Gv(t,e)}Ue(_n),Ie(_n,t)}function ms(){Ue(_n),Ue(fu),Ue(hu)}function mA(e){xa(hu.current);var t=xa(_n.current),r=Gv(t,e.type);t!==r&&(Ie(fu,e),Ie(_n,r))}function ob(e){fu.current===e&&(Ue(_n),Ue(fu))}var Ve=Qi(0);function pf(e){for(var t=e;t!==null;){if(t.tag===13){var r=t.memoizedState;if(r!==null&&(r=r.dehydrated,r===null||r.data==="$?"||r.data==="$!"))return t}else if(t.tag===19&&t.memoizedProps.revealOrder!==void 0){if(t.flags&128)return t}else if(t.child!==null){t.child.return=t,t=t.child;continue}if(t===e)break;for(;t.sibling===null;){if(t.return===null||t.return===e)return null;t=t.return}t.sibling.return=t.return,t=t.sibling}return null}var Rm=[];
vendor: 7,103 bytes, line 38
38function sb(){for(var e=0;e<Rm.length;e++)Rm[e]._workInProgressVersionPrimary=null;Rm.length=0}var Ld=ri.ReactCurrentDispatcher,Im=ri.ReactCurrentBatchConfig,Wa=0,Ke=null,lt=null,vt=null,mf=!1,Wl=!1,pu=0,lD=0;function At(){throw Error(V(321))}function lb(e,t){if(t===null)return!1;for(var r=0;r<t.length&&r<e.length;r++)if(!nn(e[r],t[r]))return!1;return!0}function ub(e,t,r,n,i,a){if(Wa=a,Ke=t,t.memoizedState=null,t.updateQueue=null,t.lanes=0,Ld.current=e===null||e.memoizedState===null?fD:hD,e=r(n,i),Wl){a=0;do{if(Wl=!1,pu=0,25<=a)throw Error(V(301));a+=1,vt=lt=null,t.updateQueue=null,Ld.current=pD,e=r(n,i)}while(Wl)}if(Ld.current=vf,t=lt!==null&<.next!==null,Wa=0,vt=lt=Ke=null,mf=!1,t)throw Error(V(300));return e}function cb(){var e=pu!==0;return pu=0,e}function fn(){var e={memoizedState:null,baseState:null,baseQueue:null,queue:null,next:null};return vt===null?Ke.memoizedState=vt=e:vt=vt.next=e,vt}function Ar(){if(lt===null){var e=Ke.alternate;e=e!==null?e.memoizedState:null}else e=lt.next;var t=vt===null?Ke.memoizedState:vt.next;if(t!==null)vt=t,lt=e;else{if(e===null)throw Error(V(310));lt=e,e={memoizedState:lt.memoizedState,baseState:lt.baseState,baseQueue:lt.baseQueue,queue:lt.queue,next:null},vt===null?Ke.memoizedState=vt=e:vt=vt.next=e}return vt}function mu(e,t){return typeof t=="function"?t(e):t}function Mm(e){var t=Ar(),r=t.queue;if(r===null)throw Error(V(311));r.lastRenderedReducer=e;var n=lt,i=n.baseQueue,a=r.pending;if(a!==null){if(i!==null){var o=i.next;i.next=a.next,a.next=o}n.baseQueue=i=a,r.pending=null}if(i!==null){a=i.next,n=n.baseState;var s=o=null,l=null,u=a;do{var d=u.lane;if((Wa&d)===d)l!==null&&(l=l.next={lane:0,action:u.action,hasEagerState:u.hasEagerState,eagerState:u.eagerState,next:null}),n=u.hasEagerState?u.eagerState:e(n,u.action);else{var c={lane:d,action:u.action,hasEagerState:u.hasEagerState,eagerState:u.eagerState,next:null};l===null?(s=l=c,o=n):l=l.next=c,Ke.lanes|=d,qa|=d}u=u.next}while(u!==null&&u!==a);l===null?o=n:l.next=s,nn(n,t.memoizedState)||(Vt=!0),t.memoizedState=n,t.baseState=o,t.baseQueue=l,r.lastRenderedState=n}if(e=r.interleaved,e!==null){i=e;do a=i.lane,Ke.lanes|=a,qa|=a,i=i.next;while(i!==e)}else i===null&&(r.lanes=0);return[t.memoizedState,r.dispatch]}function Dm(e){var t=Ar(),r=t.queue;if(r===null)throw Error(V(311));r.lastRenderedReducer=e;var n=r.dispatch,i=r.pending,a=t.memoizedState;if(i!==null){r.pending=null;var o=i=i.next;do a=e(a,o.action),o=o.next;while(o!==i);nn(a,t.memoizedState)||(Vt=!0),t.memoizedState=a,t.baseQueue===null&&(t.baseState=a),r.lastRenderedState=a}return[a,n]}function vA(){}function gA(e,t){var r=Ke,n=Ar(),i=t(),a=!nn(n.memoizedState,i);if(a&&(n.memoizedState=i,Vt=!0),n=n.queue,db(wA.bind(null,r,n,e),[e]),n.getSnapshot!==t||a||vt!==null&&vt.memoizedState.tag&1){if(r.flags|=2048,vu(9,bA.bind(null,r,n,i,t),void 0,null),yt===null)throw Error(V(349));Wa&30||yA(r,t,i)}return i}function yA(e,t,r){e.flags|=16384,e={getSnapshot:t,value:r},t=Ke.updateQueue,t===null?(t={lastEffect:null,stores:null},Ke.updateQueue=t,t.stores=[e]):(r=t.stores,r===null?t.stores=[e]:r.push(e))}function bA(e,t,r,n){t.value=r,t.getSnapshot=n,xA(t)&&_A(e)}function wA(e,t,r){return r(function(){xA(t)&&_A(e)})}function xA(e){var t=e.getSnapshot;e=e.value;try{var r=t();return!nn(e,r)}catch{return!0}}function _A(e){var t=Yn(e,1);t!==null&&Jr(t,e,1,-1)}function c1(e){var t=fn();return typeof e=="function"&&(e=e()),t.memoizedState=t.baseState=e,e={pending:null,interleaved:null,lanes:0,dispatch:null,lastRenderedReducer:mu,lastRenderedState:e},t.queue=e,e=e.dispatch=dD.bind(null,Ke,e),[t.memoizedState,e]}function vu(e,t,r,n){return e={tag:e,create:t,destroy:r,deps:n,next:null},t=Ke.updateQueue,t===null?(t={lastEffect:null,stores:null},Ke.updateQueue=t,t.lastEffect=e.next=e):(r=t.lastEffect,r===null?t.lastEffect=e.next=e:(n=r.next,r.next=e,e.next=n,t.lastEffect=e)),e}function SA(){return Ar().memoizedState}function Bd(e,t,r,n){var i=fn();Ke.flags|=e,i.memoizedState=vu(1|t,r,void 0,n===void 0?null:n)}function Fh(e,t,r,n){var i=Ar();n=n===void 0?null:n;var a=void 0;if(lt!==null){var o=lt.memoizedState;if(a=o.destroy,n!==null&&lb(n,o.deps)){i.memoizedState=vu(t,r,a,n);return}}Ke.flags|=e,i.memoizedState=vu(1|t,r,a,n)}function d1(e,t){return Bd(8390656,8,e,t)}function db(e,t){return Fh(2048,8,e,t)}function OA(e,t){return Fh(4,2,e,t)}function EA(e,t){return Fh(4,4,e,t)}function kA(e,t){if(typeof t=="function")return e=e(),t(e),function(){t(null)};if(t!=null)return e=e(),t.current=e,function(){t.current=null}}function PA(e,t,r){return r=r!=null?r.concat([e]):null,Fh(4,4,kA.bind(null,t,e),r)}function fb(){}function AA(e,t){var r=Ar();t=t===void 0?null:t;var n=r.memoizedState;return n!==null&&t!==null&&lb(t,n[1])?n[0]:(r.memoizedState=[e,t],e)}function jA(e,t){var r=Ar();t=t===void 0?null:t;var n=r.memoizedState;return n!==null&&t!==null&&lb(t,n[1])?n[0]:(e=e(),r.memoizedState=[e,t],e)}function TA(e,t,r){return Wa&21?(nn(r,t)||(r=IP(),Ke.lanes|=r,qa|=r,e.baseState=!0),t):(e.baseState&&(e.baseState=!1,Vt=!0),e.memoizedState=r)}function uD(e,t){var r=Ee;Ee=r!==0&&4>r?r:4,e(!0);var n=Im.transition;Im.transition={};try{e(!1),t()}finally{Ee=r,Im.transition=n}}function CA(){return Ar().memoizedState}function cD(e,t,r){var n=Ui(e);if(r={lane:n,action:r,hasEagerState:!1,eagerState:null,next:null},NA(e))$A(t,r);else if(r=hA(e,t,r,n),r!==null){var i=Ut();Jr(r,e,n,i),RA(r,t,n)}}function dD(e,t,r){var n=Ui(e),i={lane:n,action:r,hasEagerState:!1,eagerState:null,next:null};if(NA(e))$A(t,i);else{var a=e.alternate;if(e.lanes===0&&(a===null||a.lanes===0)&&(a=t.lastRenderedReducer,a!==null))try{var o=t.lastRenderedState,s=a(o,r);if(i.hasEagerState=!0,i.eagerState=s,nn(s,o)){var l=t.interleaved;l===null?(i.next=i,nb(t)):(i.next=l.next,l.next=i),t.interleaved=i;return}}catch{}finally{}r=hA(e,t,i,n),r!==null&&(i=Ut(),Jr(r,e,n,i),RA(r,t,n))}}function NA(e){var t=e.alternate;return e===Ke||t!==null&&t===Ke}function $A(e,t){Wl=mf=!0;var r=e.pending;r===null?t.next=t:(t.next=r.next,r.next=t),e.pending=t}function RA(e,t,r){if(r&4194240){var n=t.lanes;n&=e.pendingLanes,r|=n,t.lanes=r,W0(e,r)}}var vf={readContext:Pr,useCallback:At,useContext:At,useEffect:At,useImperativeHandle:At,useInsertionEffect:At,useLayoutEffect:At,useMemo:At,useReducer:At,useRef:At,useState:At,useDebugValue:At,useDeferredValue:At,useTransition:At,useMutableSource:At,useSyncExternalStore:At,useId:At,unstable_isNewReconciler:!1},fD={readContext:Pr,useCallback:function(e,t){return fn().memoizedState=[e,t===void 0?null:t],e},useContext:Pr,useEffect:d1,useImperativeHandle:function(e,t,r){return r=r!=null?r.concat([e]):null,Bd(4194308,4,kA.bind(null,t,e),r)},useLayoutEffect:function(e,t){return Bd(4194308,4,e,t)},useInsertionEffect:function(e,t){return Bd(4,2,e,t)},useMemo:function(e,t){var r=fn();return t=t===void 0?null:t,e=e(),r.memoizedState=[e,t],e},useReducer:function(e,t,r){var n=fn();return t=r!==void 0?r(t):t,n.memoizedState=n.baseState=t,e={pending:null,interleaved:null,lanes:0,dispatch:null,lastRenderedReducer:e,lastRenderedState:t},n.queue=e,e=e.dispatch=cD.bind(null,Ke,e),[n.memoizedState,e]}
vendor: 7,431 bytes, lines 38-40
38,useRef:function(e){var t=fn();return e={current:e},t.memoizedState=e},useState:c1,useDebugValue:fb,useDeferredValue:function(e){return fn().memoizedState=e},useTransition:function(){var e=c1(!1),t=e[0];return e=uD.bind(null,e[1]),fn().memoizedState=e,[t,e]},useMutableSource:function(){},useSyncExternalStore:function(e,t,r){var n=Ke,i=fn();if(We){if(r===void 0)throw Error(V(407));r=r()}else{if(r=t(),yt===null)throw Error(V(349));Wa&30||yA(n,t,r)}i.memoizedState=r;var a={value:r,getSnapshot:t};return i.queue=a,d1(wA.bind(null,n,a,e),[e]),n.flags|=2048,vu(9,bA.bind(null,n,a,r,t),void 0,null),r},useId:function(){var e=fn(),t=yt.identifierPrefix;if(We){var r=Fn,n=Un;r=(n&~(1<<32-Qr(n)-1)).toString(32)+r,t=":"+t+"R"+r,r=pu++,0<r&&(t+="H"+r.toString(32)),t+=":"}else r=lD++,t=":"+t+"r"+r.toString(32)+":";return e.memoizedState=t},unstable_isNewReconciler:!1},hD={readContext:Pr,useCallback:AA,useContext:Pr,useEffect:db,useImperativeHandle:PA,useInsertionEffect:OA,useLayoutEffect:EA,useMemo:jA,useReducer:Mm,useRef:SA,useState:function(){return Mm(mu)},useDebugValue:fb,useDeferredValue:function(e){var t=Ar();return TA(t,lt.memoizedState,e)},useTransition:function(){var e=Mm(mu)[0],t=Ar().memoizedState;return[e,t]},useMutableSource:vA,useSyncExternalStore:gA,useId:CA,unstable_isNewReconciler:!1},pD={readContext:Pr,useCallback:AA,useContext:Pr,useEffect:db,useImperativeHandle:PA,useInsertionEffect:OA,useLayoutEffect:EA,useMemo:jA,useReducer:Dm,useRef:SA,useState:function(){return Dm(mu)},useDebugValue:fb,useDeferredValue:function(e){var t=Ar();return lt===null?t.memoizedState=e:TA(t,lt.memoizedState,e)},useTransition:function(){var e=Dm(mu)[0],t=Ar().memoizedState;return[e,t]},useMutableSource:vA,useSyncExternalStore:gA,useId:CA,unstable_isNewReconciler:!1};function Ur(e,t){if(e&&e.defaultProps){t=Ge({},t),e=e.defaultProps;for(var r in e)t[r]===void 0&&(t[r]=e[r]);return t}return t}function mg(e,t,r,n){t=e.memoizedState,r=r(n,t),r=r==null?t:Ge({},t,r),e.memoizedState=r,e.lanes===0&&(e.updateQueue.baseState=r)}var zh={isMounted:function(e){return(e=e._reactInternals)?Za(e)===e:!1},enqueueSetState:function(e,t,r){e=e._reactInternals;var n=Ut(),i=Ui(e),a=qn(n,i);a.payload=t,r!=null&&(a.callback=r),t=Li(e,a,i),t!==null&&(Jr(t,e,i,n),Dd(t,e,i))},enqueueReplaceState:function(e,t,r){e=e._reactInternals;var n=Ut(),i=Ui(e),a=qn(n,i);a.tag=1,a.payload=t,r!=null&&(a.callback=r),t=Li(e,a,i),t!==null&&(Jr(t,e,i,n),Dd(t,e,i))},enqueueForceUpdate:function(e,t){e=e._reactInternals;var r=Ut(),n=Ui(e),i=qn(r,n);i.tag=2,t!=null&&(i.callback=t),t=Li(e,i,n),t!==null&&(Jr(t,e,n,r),Dd(t,e,n))}};function f1(e,t,r,n,i,a,o){return e=e.stateNode,typeof e.shouldComponentUpdate=="function"?e.shouldComponentUpdate(n,a,o):t.prototype&&t.prototype.isPureReactComponent?!lu(r,n)||!lu(i,a):!0}function IA(e,t,r){var n=!1,i=Hi,a=t.contextType;return typeof a=="object"&&a!==null?a=Pr(a):(i=Xt(t)?Fa:It.current,n=t.contextTypes,a=(n=n!=null)?fs(e,i):Hi),t=new t(r,a),e.memoizedState=t.state!==null&&t.state!==void 0?t.state:null,t.updater=zh,e.stateNode=t,t._reactInternals=e,n&&(e=e.stateNode,e.__reactInternalMemoizedUnmaskedChildContext=i,e.__reactInternalMemoizedMaskedChildContext=a),t}function h1(e,t,r,n){e=t.state,typeof t.componentWillReceiveProps=="function"&&t.componentWillReceiveProps(r,n),typeof t.UNSAFE_componentWillReceiveProps=="function"&&t.UNSAFE_componentWillReceiveProps(r,n),t.state!==e&&zh.enqueueReplaceState(t,t.state,null)}function vg(e,t,r,n){var i=e.stateNode;i.props=r,i.state=e.memoizedState,i.refs={},ib(e);var a=t.contextType;typeof a=="object"&&a!==null?i.context=Pr(a):(a=Xt(t)?Fa:It.current,i.context=fs(e,a)),i.state=e.memoizedState,a=t.getDerivedStateFromProps,typeof a=="function"&&(mg(e,t,a,r),i.state=e.memoizedState),typeof t.getDerivedStateFromProps=="function"||typeof i.getSnapshotBeforeUpdate=="function"||typeof i.UNSAFE_componentWillMount!="function"&&typeof i.componentWillMount!="function"||(t=i.state,typeof i.componentWillMount=="function"&&i.componentWillMount(),typeof i.UNSAFE_componentWillMount=="function"&&i.UNSAFE_componentWillMount(),t!==i.state&&zh.enqueueReplaceState(i,i.state,null),hf(e,r,i,n),i.state=e.memoizedState),typeof i.componentDidMount=="function"&&(e.flags|=4194308)}function vs(e,t){try{var r="",n=t;do r+=zI(n),n=n.return;while(n);var i=r}catch(a){i=` 39Error generating stack: `+a.message+` 40`+a.stack}return{value:e,source:t,stack:i,digest:null}}function Lm(e,t,r){return{value:e,source:null,stack:r??null,digest:t??null}}function gg(e,t){try{console.error(t.value)}catch(r){setTimeout(function(){throw r})}}var mD=typeof WeakMap=="function"?WeakMap:Map;function MA(e,t,r){r=qn(-1,r),r.tag=3,r.payload={element:null};var n=t.value;return r.callback=function(){yf||(yf=!0,Pg=n),gg(e,t)},r}function DA(e,t,r){r=qn(-1,r),r.tag=3;var n=e.type.getDerivedStateFromError;if(typeof n=="function"){var i=t.value;r.payload=function(){return n(i)},r.callback=function(){gg(e,t)}}var a=e.stateNode;return a!==null&&typeof a.componentDidCatch=="function"&&(r.callback=function(){gg(e,t),typeof n!="function"&&(Bi===null?Bi=new Set([this]):Bi.add(this));var o=t.stack;this.componentDidCatch(t.value,{componentStack:o!==null?o:""})}),r}function p1(e,t,r){var n=e.pingCache;if(n===null){n=e.pingCache=new mD;var i=new Set;n.set(t,i)}else i=n.get(t),i===void 0&&(i=new Set,n.set(t,i));i.has(r)||(i.add(r),e=jD.bind(null,e,t,r),t.then(e,e))}function m1(e){do{var t;if((t=e.tag===13)&&(t=e.memoizedState,t=t!==null?t.dehydrated!==null:!0),t)return e;e=e.return}while(e!==null);return null}function v1(e,t,r,n,i){return e.mode&1?(e.flags|=65536,e.lanes=i,e):(e===t?e.flags|=65536:(e.flags|=128,r.flags|=131072,r.flags&=-52805,r.tag===1&&(r.alternate===null?r.tag=17:(t=qn(-1,1),t.tag=2,Li(r,t,1))),r.lanes|=1),e)}var vD=ri.ReactCurrentOwner,Vt=!1;function Dt(e,t,r,n){t.child=e===null?fA(t,null,r,n):ps(t,e.child,r,n)}function g1(e,t,r,n,i){r=r.render;var a=t.ref;return Ko(t,i),n=ub(e,t,r,n,a,i),r=cb(),e!==null&&!Vt?(t.updateQueue=e.updateQueue,t.flags&=-2053,e.lanes&=~i,Xn(e,t,i)):(We&&r&&Q0(t),t.flags|=1,Dt(e,t,n,i),t.child)}function y1(e,t,r,n,i){if(e===null){var a=r.type;return typeof a=="function"&&!wb(a)&&a.defaultProps===void 0&&r.compare===null&&r.defaultProps===void 0?(t.tag=15,t.type=a,LA(e,t,a,n,i)):(e=Wd(r.type,null,n,t,t.mode,i),e.ref=t.ref,e.return=t,t.child=e)}if(a=e.child,!(e.lanes&i)){var o=a.memoizedProps;if(r=r.compare,r=r!==null?r:lu,r(o,n)&&e.ref===t.ref)return Xn(e,t,i)}return t.flags|=1,e=Fi(a,n),e.ref=t.ref,e.return=t,t.child=e}function LA(e,t,r,n,i){if(e!==null){var a=e.memoizedProps;if(lu(a,n)&&e.ref===t.ref)if(Vt=!1,t.pendingProps=n=a,(e.lanes&i)!==0)e.flags&131072&&(Vt=!0);else return t.lanes=e.lanes,Xn(e,t,i)}return yg(e,t,r,n,i)}function BA(e,t,r){var n=t.pendingProps,i=n.children,a=e!==null?e.memoizedState:null;if(n.mode==="hidden")if(!(t.mode&1))t.memoizedState={baseLanes:0,cachePool:null,transitions:null},Ie(Lo,nr),nr|=r;else{if(!(r&1073741824))return e=a!==null?a.baseLanes|r:r,t.lanes=t.childLanes=1073741824,t.memoizedState={baseLanes:e,cachePool:null,transitions:null},t.updateQueue=null,Ie(Lo,nr),nr|=e,null;t.memoizedState={baseLanes:0,cachePool:null,transitions:null},n=a!==null?a.baseLanes:r,Ie(Lo,nr),nr|=n}else a!==null?(n=a.baseLanes|r,t.memoizedState=null):n=r,Ie(Lo,nr),nr|=n;return Dt(e,t,i,r),t.child}function UA(e,t){var r=t.ref;(e===null&&r!==null||e!==null&&e.ref!==r)&&(t.flags|=512,t.flags|=2097152)}
vendor: 4,711 bytes, line 40
40function yg(e,t,r,n,i){var a=Xt(r)?Fa:It.current;return a=fs(t,a),Ko(t,i),r=ub(e,t,r,n,a,i),n=cb(),e!==null&&!Vt?(t.updateQueue=e.updateQueue,t.flags&=-2053,e.lanes&=~i,Xn(e,t,i)):(We&&n&&Q0(t),t.flags|=1,Dt(e,t,r,i),t.child)}function b1(e,t,r,n,i){if(Xt(r)){var a=!0;lf(t)}else a=!1;if(Ko(t,i),t.stateNode===null)Ud(e,t),IA(t,r,n),vg(t,r,n,i),n=!0;else if(e===null){var o=t.stateNode,s=t.memoizedProps;o.props=s;var l=o.context,u=r.contextType;typeof u=="object"&&u!==null?u=Pr(u):(u=Xt(r)?Fa:It.current,u=fs(t,u));var d=r.getDerivedStateFromProps,c=typeof d=="function"||typeof o.getSnapshotBeforeUpdate=="function";c||typeof o.UNSAFE_componentWillReceiveProps!="function"&&typeof o.componentWillReceiveProps!="function"||(s!==n||l!==u)&&h1(t,o,n,u),bi=!1;var f=t.memoizedState;o.state=f,hf(t,n,o,i),l=t.memoizedState,s!==n||f!==l||Yt.current||bi?(typeof d=="function"&&(mg(t,r,d,n),l=t.memoizedState),(s=bi||f1(t,r,s,n,f,l,u))?(c||typeof o.UNSAFE_componentWillMount!="function"&&typeof o.componentWillMount!="function"||(typeof o.componentWillMount=="function"&&o.componentWillMount(),typeof o.UNSAFE_componentWillMount=="function"&&o.UNSAFE_componentWillMount()),typeof o.componentDidMount=="function"&&(t.flags|=4194308)):(typeof o.componentDidMount=="function"&&(t.flags|=4194308),t.memoizedProps=n,t.memoizedState=l),o.props=n,o.state=l,o.context=u,n=s):(typeof o.componentDidMount=="function"&&(t.flags|=4194308),n=!1)}else{o=t.stateNode,pA(e,t),s=t.memoizedProps,u=t.type===t.elementType?s:Ur(t.type,s),o.props=u,c=t.pendingProps,f=o.context,l=r.contextType,typeof l=="object"&&l!==null?l=Pr(l):(l=Xt(r)?Fa:It.current,l=fs(t,l));var h=r.getDerivedStateFromProps;(d=typeof h=="function"||typeof o.getSnapshotBeforeUpdate=="function")||typeof o.UNSAFE_componentWillReceiveProps!="function"&&typeof o.componentWillReceiveProps!="function"||(s!==c||f!==l)&&h1(t,o,n,l),bi=!1,f=t.memoizedState,o.state=f,hf(t,n,o,i);var v=t.memoizedState;s!==c||f!==v||Yt.current||bi?(typeof h=="function"&&(mg(t,r,h,n),v=t.memoizedState),(u=bi||f1(t,r,u,n,f,v,l)||!1)?(d||typeof o.UNSAFE_componentWillUpdate!="function"&&typeof o.componentWillUpdate!="function"||(typeof o.componentWillUpdate=="function"&&o.componentWillUpdate(n,v,l),typeof o.UNSAFE_componentWillUpdate=="function"&&o.UNSAFE_componentWillUpdate(n,v,l)),typeof o.componentDidUpdate=="function"&&(t.flags|=4),typeof o.getSnapshotBeforeUpdate=="function"&&(t.flags|=1024)):(typeof o.componentDidUpdate!="function"||s===e.memoizedProps&&f===e.memoizedState||(t.flags|=4),typeof o.getSnapshotBeforeUpdate!="function"||s===e.memoizedProps&&f===e.memoizedState||(t.flags|=1024),t.memoizedProps=n,t.memoizedState=v),o.props=n,o.state=v,o.context=l,n=u):(typeof o.componentDidUpdate!="function"||s===e.memoizedProps&&f===e.memoizedState||(t.flags|=4),typeof o.getSnapshotBeforeUpdate!="function"||s===e.memoizedProps&&f===e.memoizedState||(t.flags|=1024),n=!1)}return bg(e,t,r,n,a,i)}function bg(e,t,r,n,i,a){UA(e,t);var o=(t.flags&128)!==0;if(!n&&!o)return i&&i1(t,r,!1),Xn(e,t,a);n=t.stateNode,vD.current=t;var s=o&&typeof r.getDerivedStateFromError!="function"?null:n.render();return t.flags|=1,e!==null&&o?(t.child=ps(t,e.child,null,a),t.child=ps(t,null,s,a)):Dt(e,t,s,a),t.memoizedState=n.state,i&&i1(t,r,!0),t.child}function FA(e){var t=e.stateNode;t.pendingContext?n1(e,t.pendingContext,t.pendingContext!==t.context):t.context&&n1(e,t.context,!1),ab(e,t.containerInfo)}function w1(e,t,r,n,i){return hs(),Z0(i),t.flags|=256,Dt(e,t,r,n),t.child}var wg={dehydrated:null,treeContext:null,retryLane:0};function xg(e){return{baseLanes:e,cachePool:null,transitions:null}}function zA(e,t,r){var n=t.pendingProps,i=Ve.current,a=!1,o=(t.flags&128)!==0,s;if((s=o)||(s=e!==null&&e.memoizedState===null?!1:(i&2)!==0),s?(a=!0,t.flags&=-129):(e===null||e.memoizedState!==null)&&(i|=1),Ie(Ve,i&1),e===null)return hg(t),e=t.memoizedState,e!==null&&(e=e.dehydrated,e!==null)?(t.mode&1?e.data==="$!"?t.lanes=8:t.lanes=1073741824:t.lanes=1,null):(o=n.children,e=n.fallback,a?(n=t.mode,a=t.child,o={mode:"hidden",children:o},!(n&1)&&a!==null?(a.childLanes=0,a.pendingProps=o):a=Hh(o,n,0,null),e=Ra(e,n,r,null),a.return=t,e.return=t,a.sibling=e,t.child=a,t.child.memoizedState=xg(r),t.memoizedState=wg,e):hb(t,o));if(i=e.memoizedState,i!==null&&(s=i.dehydrated,s!==null))return gD(e,t,o,n,s,i,r);if(a){a=n.fallback,o=t.mode,i=e.child,s=i.sibling;var l={mode:"hidden",children:n.children};return!(o&1)&&t.child!==i?(n=t.child,n.childLanes=0,n.pendingProps=l,t.deletions=null):(n=Fi(i,l),n.subtreeFlags=i.subtreeFlags&14680064),s!==null?a=Fi(s,a):(a=Ra(a,o,r,null),a.flags|=2),a.return=t,n.return=t,n.sibling=a,t.child=n,n=a,a=t.child,o=e.child.memoizedState,o=o===null?xg(r):{base
vendor: 7,075 bytes, line 40
40Lanes:o.baseLanes|r,cachePool:null,transitions:o.transitions},a.memoizedState=o,a.childLanes=e.childLanes&~r,t.memoizedState=wg,n}return a=e.child,e=a.sibling,n=Fi(a,{mode:"visible",children:n.children}),!(t.mode&1)&&(n.lanes=r),n.return=t,n.sibling=null,e!==null&&(r=t.deletions,r===null?(t.deletions=[e],t.flags|=16):r.push(e)),t.child=n,t.memoizedState=null,n}function hb(e,t){return t=Hh({mode:"visible",children:t},e.mode,0,null),t.return=e,e.child=t}function Jc(e,t,r,n){return n!==null&&Z0(n),ps(t,e.child,null,r),e=hb(t,t.pendingProps.children),e.flags|=2,t.memoizedState=null,e}function gD(e,t,r,n,i,a,o){if(r)return t.flags&256?(t.flags&=-257,n=Lm(Error(V(422))),Jc(e,t,o,n)):t.memoizedState!==null?(t.child=e.child,t.flags|=128,null):(a=n.fallback,i=t.mode,n=Hh({mode:"visible",children:n.children},i,0,null),a=Ra(a,i,o,null),a.flags|=2,n.return=t,a.return=t,n.sibling=a,t.child=n,t.mode&1&&ps(t,e.child,null,o),t.child.memoizedState=xg(o),t.memoizedState=wg,a);if(!(t.mode&1))return Jc(e,t,o,null);if(i.data==="$!"){if(n=i.nextSibling&&i.nextSibling.dataset,n)var s=n.dgst;return n=s,a=Error(V(419)),n=Lm(a,n,void 0),Jc(e,t,o,n)}if(s=(o&e.childLanes)!==0,Vt||s){if(n=yt,n!==null){switch(o&-o){case 4:i=2;break;case 16:i=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:i=32;break;case 536870912:i=268435456;break;default:i=0}i=i&(n.suspendedLanes|o)?0:i,i!==0&&i!==a.retryLane&&(a.retryLane=i,Yn(e,i),Jr(n,e,i,-1))}return bb(),n=Lm(Error(V(421))),Jc(e,t,o,n)}return i.data==="$?"?(t.flags|=128,t.child=e.child,t=TD.bind(null,e),i._reactRetry=t,null):(e=a.treeContext,lr=Di(i.nextSibling),ur=t,We=!0,Gr=null,e!==null&&(xr[_r++]=Un,xr[_r++]=Fn,xr[_r++]=za,Un=e.id,Fn=e.overflow,za=t),t=hb(t,n.children),t.flags|=4096,t)}function x1(e,t,r){e.lanes|=t;var n=e.alternate;n!==null&&(n.lanes|=t),pg(e.return,t,r)}function Bm(e,t,r,n,i){var a=e.memoizedState;a===null?e.memoizedState={isBackwards:t,rendering:null,renderingStartTime:0,last:n,tail:r,tailMode:i}:(a.isBackwards=t,a.rendering=null,a.renderingStartTime=0,a.last=n,a.tail=r,a.tailMode=i)}function WA(e,t,r){var n=t.pendingProps,i=n.revealOrder,a=n.tail;if(Dt(e,t,n.children,r),n=Ve.current,n&2)n=n&1|2,t.flags|=128;else{if(e!==null&&e.flags&128)e:for(e=t.child;e!==null;){if(e.tag===13)e.memoizedState!==null&&x1(e,r,t);else if(e.tag===19)x1(e,r,t);else if(e.child!==null){e.child.return=e,e=e.child;continue}if(e===t)break e;for(;e.sibling===null;){if(e.return===null||e.return===t)break e;e=e.return}e.sibling.return=e.return,e=e.sibling}n&=1}if(Ie(Ve,n),!(t.mode&1))t.memoizedState=null;else switch(i){case"forwards":for(r=t.child,i=null;r!==null;)e=r.alternate,e!==null&&pf(e)===null&&(i=r),r=r.sibling;r=i,r===null?(i=t.child,t.child=null):(i=r.sibling,r.sibling=null),Bm(t,!1,i,r,a);break;case"backwards":for(r=null,i=t.child,t.child=null;i!==null;){if(e=i.alternate,e!==null&&pf(e)===null){t.child=i;break}e=i.sibling,i.sibling=r,r=i,i=e}Bm(t,!0,r,null,a);break;case"together":Bm(t,!1,null,null,void 0);break;default:t.memoizedState=null}return t.child}function Ud(e,t){!(t.mode&1)&&e!==null&&(e.alternate=null,t.alternate=null,t.flags|=2)}function Xn(e,t,r){if(e!==null&&(t.dependencies=e.dependencies),qa|=t.lanes,!(r&t.childLanes))return null;if(e!==null&&t.child!==e.child)throw Error(V(153));if(t.child!==null){for(e=t.child,r=Fi(e,e.pendingProps),t.child=r,r.return=t;e.sibling!==null;)e=e.sibling,r=r.sibling=Fi(e,e.pendingProps),r.return=t;r.sibling=null}return t.child}function yD(e,t,r){switch(t.tag){case 3:FA(t),hs();break;case 5:mA(t);break;case 1:Xt(t.type)&&lf(t);break;case 4:ab(t,t.stateNode.containerInfo);break;case 10:var n=t.type._context,i=t.memoizedProps.value;Ie(df,n._currentValue),n._currentValue=i;break;case 13:if(n=t.memoizedState,n!==null)return n.dehydrated!==null?(Ie(Ve,Ve.current&1),t.flags|=128,null):r&t.child.childLanes?zA(e,t,r):(Ie(Ve,Ve.current&1),e=Xn(e,t,r),e!==null?e.sibling:null);Ie(Ve,Ve.current&1);break;case 19:if(n=(r&t.childLanes)!==0,e.flags&128){if(n)return WA(e,t,r);t.flags|=128}if(i=t.memoizedState,i!==null&&(i.rendering=null,i.tail=null,i.lastEffect=null),Ie(Ve,Ve.current),n)break;return null;case 22:case 23:return t.lanes=0,BA(e,t,r)}return Xn(e,t,r)}var qA,_g,HA,VA;qA=function(e,t){for(var r=t.child;r!==null;){if(r.tag===5||r.tag===6)e.appendChild(r.stateNode);else if(r.tag!==4&&r.child!==null){r.child.return=r,r=r.child;continue}if(r===t)break;for(;r.sibling===null;){if(r.return===null||r.return===t)return;r=r.return}r.sibling.return=r.return,r=r.sibling}};_g=function(){};HA=function(e,t,r,n){var i=e.memoizedProps;if(i!==n){e=t.stateNode,xa(_n.current);var a=null;switch(r){case"input":i=qv(e,i),n=qv(e,n),a=[];break;case"select":i=Ge({},i,{value:void 0}),n=Ge({},n,{value:void 0}),a=[];break;case"textarea":i=Kv(e,i),n=Kv(e,n),a=[];break;default:typeof i.onClick!="function"&&typeof n.onClick=="function"&&(e.onclick=of)}Yv(r,n);var o;r=null;for(u in i)if(!n.hasOwnProperty(u)&&i.hasOwnProperty(u)&&i[u]!=null)if(u==="style"){var s=i[u];for(o in s)s.hasOwnProperty(o)&&(r||(r={}),r[o]="")}else u!=="dangerouslySetInnerHTML"&&u!=="children"&&u!=="suppressContentEditableWarning"&&u!=="suppressHydrationWarning"&&u!=="autoFocus"&&(tu.hasOwnProperty(u)?a||(a=[]):(a=a||[]).push(u,null));for(u in n){var l=n[u];if(s=i!=null?i[u]:void 0,n.hasOwnProperty(u)&&l!==s&&(l!=null||s!=null))if(u==="style")if(s){for(o in s)!s.hasOwnProperty(o)||l&&l.hasOwnProperty(o)||(r||(r={}),r[o]="");for(o in l)l.hasOwnProperty(o)&&s[o]!==l[o]&&(r||(r={}),r[o]=l[o])}else r||(a||(a=[]),a.push(u,r)),r=l;else u==="dangerouslySetInnerHTML"?(l=l?l.__html:void 0,s=s?s.__html:void 0,l!=null&&s!==l&&(a=a||[]).push(u,l)):u==="children"?typeof l!="string"&&typeof l!="number"||(a=a||[]).push(u,""+l):u!=="suppressContentEditableWarning"&&u!=="suppressHydrationWarning"&&(tu.hasOwnProperty(u)?(l!=null&&u==="onScroll"&&De("scroll",e),a||s===l||(a=[])):(a=a||[]).push(u,l))}r&&(a=a||[]).push("style",r);var u=a;(t.updateQueue=u)&&(t.flags|=4)}};VA=function(e,t,r,n){r!==n&&(t.flags|=4)};function gl(e,t){if(!We)switch(e.tailMode){case"hidden":t=e.tail;for(var r=null;t!==null;)t.alternate!==null&&(r=t),t=t.sibling;r===null?e.tail=null:r.sibling=null;break;case"collapsed":r=e.tail;for(var n=null;r!==null;)r.alternate!==null&&(n=r),r=r.sibling;n===null?t||e.tail===null?e.tail=null:e.tail.sibling=null:n.sibling=null}}function jt(e){var t=e.alternate!==null&&e.alternate.child===e.child,r=0,n=0;if(t)for(var i=e.child;i!==null;)r|=i.lanes|i.childLanes,n|=i.subtreeFlags&14680064,n|=i.flags&14680064,i.return=e,i=i.sibling;else for(i=e.child;i!==null;)r|=i.lanes|i.childLanes,n|=i.subtreeFlags,n|=i.flags,i.return=e,i=i.sibling;return e.subtreeFlags|=n,e.childLanes=r,t}function bD(e,t,r){var n=t.pendingProps;switch(J0(t),t.tag){case 2:case 16:case 15:case 0:case 11:case 7:case 8:case 12:case 9:case 14:return jt(t),null;case 1:return Xt(t.type)&&sf(),jt(t),null;
vendor: 32,833 bytes, line 40
40case 3:return n=t.stateNode,ms(),Ue(Yt),Ue(It),sb(),n.pendingContext&&(n.context=n.pendingContext,n.pendingContext=null),(e===null||e.child===null)&&(Xc(t)?t.flags|=4:e===null||e.memoizedState.isDehydrated&&!(t.flags&256)||(t.flags|=1024,Gr!==null&&(Tg(Gr),Gr=null))),_g(e,t),jt(t),null;case 5:ob(t);var i=xa(hu.current);if(r=t.type,e!==null&&t.stateNode!=null)HA(e,t,r,n,i),e.ref!==t.ref&&(t.flags|=512,t.flags|=2097152);else{if(!n){if(t.stateNode===null)throw Error(V(166));return jt(t),null}if(e=xa(_n.current),Xc(t)){n=t.stateNode,r=t.type;var a=t.memoizedProps;switch(n[gn]=t,n[du]=a,e=(t.mode&1)!==0,r){case"dialog":De("cancel",n),De("close",n);break;case"iframe":case"object":case"embed":De("load",n);break;case"video":case"audio":for(i=0;i<Il.length;i++)De(Il[i],n);break;case"source":De("error",n);break;case"img":case"image":case"link":De("error",n),De("load",n);break;case"details":De("toggle",n);break;case"input":Tx(n,a),De("invalid",n);break;case"select":n._wrapperState={wasMultiple:!!a.multiple},De("invalid",n);break;case"textarea":Nx(n,a),De("invalid",n)}Yv(r,a),i=null;for(var o in a)if(a.hasOwnProperty(o)){var s=a[o];o==="children"?typeof s=="string"?n.textContent!==s&&(a.suppressHydrationWarning!==!0&&Yc(n.textContent,s,e),i=["children",s]):typeof s=="number"&&n.textContent!==""+s&&(a.suppressHydrationWarning!==!0&&Yc(n.textContent,s,e),i=["children",""+s]):tu.hasOwnProperty(o)&&s!=null&&o==="onScroll"&&De("scroll",n)}switch(r){case"input":Fc(n),Cx(n,a,!0);break;case"textarea":Fc(n),$x(n);break;case"select":case"option":break;default:typeof a.onClick=="function"&&(n.onclick=of)}n=i,t.updateQueue=n,n!==null&&(t.flags|=4)}else{o=i.nodeType===9?i:i.ownerDocument,e==="http://www.w3.org/1999/xhtml"&&(e=wP(r)),e==="http://www.w3.org/1999/xhtml"?r==="script"?(e=o.createElement("div"),e.innerHTML="<script><\/script>",e=e.removeChild(e.firstChild)):typeof n.is=="string"?e=o.createElement(r,{is:n.is}):(e=o.createElement(r),r==="select"&&(o=e,n.multiple?o.multiple=!0:n.size&&(o.size=n.size))):e=o.createElementNS(e,r),e[gn]=t,e[du]=n,qA(e,t,!1,!1),t.stateNode=e;e:{switch(o=Xv(r,n),r){case"dialog":De("cancel",e),De("close",e),i=n;break;case"iframe":case"object":case"embed":De("load",e),i=n;break;case"video":case"audio":for(i=0;i<Il.length;i++)De(Il[i],e);i=n;break;case"source":De("error",e),i=n;break;case"img":case"image":case"link":De("error",e),De("load",e),i=n;break;case"details":De("toggle",e),i=n;break;case"input":Tx(e,n),i=qv(e,n),De("invalid",e);break;case"option":i=n;break;case"select":e._wrapperState={wasMultiple:!!n.multiple},i=Ge({},n,{value:void 0}),De("invalid",e);break;case"textarea":Nx(e,n),i=Kv(e,n),De("invalid",e);break;default:i=n}Yv(r,i),s=i;for(a in s)if(s.hasOwnProperty(a)){var l=s[a];a==="style"?SP(e,l):a==="dangerouslySetInnerHTML"?(l=l?l.__html:void 0,l!=null&&xP(e,l)):a==="children"?typeof l=="string"?(r!=="textarea"||l!=="")&&ru(e,l):typeof l=="number"&&ru(e,""+l):a!=="suppressContentEditableWarning"&&a!=="suppressHydrationWarning"&&a!=="autoFocus"&&(tu.hasOwnProperty(a)?l!=null&&a==="onScroll"&&De("scroll",e):l!=null&&D0(e,a,l,o))}switch(r){case"input":Fc(e),Cx(e,n,!1);break;case"textarea":Fc(e),$x(e);break;case"option":n.value!=null&&e.setAttribute("value",""+qi(n.value));break;case"select":e.multiple=!!n.multiple,a=n.value,a!=null?Wo(e,!!n.multiple,a,!1):n.defaultValue!=null&&Wo(e,!!n.multiple,n.defaultValue,!0);break;default:typeof i.onClick=="function"&&(e.onclick=of)}switch(r){case"button":case"input":case"select":case"textarea":n=!!n.autoFocus;break e;case"img":n=!0;break e;default:n=!1}}n&&(t.flags|=4)}t.ref!==null&&(t.flags|=512,t.flags|=2097152)}return jt(t),null;case 6:if(e&&t.stateNode!=null)VA(e,t,e.memoizedProps,n);else{if(typeof n!="string"&&t.stateNode===null)throw Error(V(166));if(r=xa(hu.current),xa(_n.current),Xc(t)){if(n=t.stateNode,r=t.memoizedProps,n[gn]=t,(a=n.nodeValue!==r)&&(e=ur,e!==null))switch(e.tag){case 3:Yc(n.nodeValue,r,(e.mode&1)!==0);break;case 5:e.memoizedProps.suppressHydrationWarning!==!0&&Yc(n.nodeValue,r,(e.mode&1)!==0)}a&&(t.flags|=4)}else n=(r.nodeType===9?r:r.ownerDocument).createTextNode(n),n[gn]=t,t.stateNode=n}return jt(t),null;case 13:if(Ue(Ve),n=t.memoizedState,e===null||e.memoizedState!==null&&e.memoizedState.dehydrated!==null){if(We&&lr!==null&&t.mode&1&&!(t.flags&128))cA(),hs(),t.flags|=98560,a=!1;else if(a=Xc(t),n!==null&&n.dehydrated!==null){if(e===null){if(!a)throw Error(V(318));if(a=t.memoizedState,a=a!==null?a.dehydrated:null,!a)throw Error(V(317));a[gn]=t}else hs(),!(t.flags&128)&&(t.memoizedState=null),t.flags|=4;jt(t),a=!1}else Gr!==null&&(Tg(Gr),Gr=null),a=!0;if(!a)return t.flags&65536?t:null}return t.flags&128?(t.lanes=r,t):(n=n!==null,n!==(e!==null&&e.memoizedState!==null)&&n&&(t.child.flags|=8192,t.mode&1&&(e===null||Ve.current&1?ut===0&&(ut=3):bb())),t.updateQueue!==null&&(t.flags|=4),jt(t),null);case 4:return ms(),_g(e,t),e===null&&uu(t.stateNode.containerInfo),jt(t),null;case 10:return rb(t.type._context),jt(t),null;case 17:return Xt(t.type)&&sf(),jt(t),null;case 19:if(Ue(Ve),a=t.memoizedState,a===null)return jt(t),null;if(n=(t.flags&128)!==0,o=a.rendering,o===null)if(n)gl(a,!1);else{if(ut!==0||e!==null&&e.flags&128)for(e=t.child;e!==null;){if(o=pf(e),o!==null){for(t.flags|=128,gl(a,!1),n=o.updateQueue,n!==null&&(t.updateQueue=n,t.flags|=4),t.subtreeFlags=0,n=r,r=t.child;r!==null;)a=r,e=n,a.flags&=14680066,o=a.alternate,o===null?(a.childLanes=0,a.lanes=e,a.child=null,a.subtreeFlags=0,a.memoizedProps=null,a.memoizedState=null,a.updateQueue=null,a.dependencies=null,a.stateNode=null):(a.childLanes=o.childLanes,a.lanes=o.lanes,a.child=o.child,a.subtreeFlags=0,a.deletions=null,a.memoizedProps=o.memoizedProps,a.memoizedState=o.memoizedState,a.updateQueue=o.updateQueue,a.type=o.type,e=o.dependencies,a.dependencies=e===null?null:{lanes:e.lanes,firstContext:e.firstContext}),r=r.sibling;return Ie(Ve,Ve.current&1|2),t.child}e=e.sibling}a.tail!==null&&et()>gs&&(t.flags|=128,n=!0,gl(a,!1),t.lanes=4194304)}else{if(!n)if(e=pf(o),e!==null){if(t.flags|=128,n=!0,r=e.updateQueue,r!==null&&(t.updateQueue=r,t.flags|=4),gl(a,!0),a.tail===null&&a.tailMode==="hidden"&&!o.alternate&&!We)return jt(t),null}else 2*et()-a.renderingStartTime>gs&&r!==1073741824&&(t.flags|=128,n=!0,gl(a,!1),t.lanes=4194304);a.isBackwards?(o.sibling=t.child,t.child=o):(r=a.last,r!==null?r.sibling=o:t.child=o,a.last=o)}return a.tail!==null?(t=a.tail,a.rendering=t,a.tail=t.sibling,a.renderingStartTime=et(),t.sibling=null,r=Ve.current,Ie(Ve,n?r&1|2:r&1),t):(jt(t),null);case 22:case 23:return yb(),n=t.memoizedState!==null,e!==null&&e.memoizedState!==null!==n&&(t.flags|=8192),n&&t.mode&1?nr&1073741824&&(jt(t),t.subtreeFlags&6&&(t.flags|=8192)):jt(t),null;case 24:return null;case 25:return null}throw Error(V(156,t.tag))}function wD(e,t){switch(J0(t),t.tag){case 1:return Xt(t.type)&&sf(),e=t.flags,e&65536?(t.flags=e&-65537|128,t):null;case 3:return ms(),Ue(Yt),Ue(It),sb(),e=t.flags,e&65536&&!(e&128)?(t.flags=e&-65537|128,t):null;case 5:return ob(t),null;case 13:if(Ue(Ve),e=t.memoizedState,e!==null&&e.dehydrated!==null){if(t.alternate===null)throw Error(V(340));hs()}return e=t.flags,e&65536?(t.flags=e&-65537|128,t):null;case 19:return Ue(Ve),null;case 4:return ms(),null;case 10:return rb(t.type._context),null;case 22:case 23:return yb(),null;case 24:return null;default:return null}}var Zc=!1,Nt=!1,xD=typeof WeakSet=="function"?WeakSet:Set,X=null;function Do(e,t){var r=e.ref;if(r!==null)if(typeof r=="function")try{r(null)}catch(n){Qe(e,t,n)}else r.current=null}function Sg(e,t,r){try{r()}catch(n){Qe(e,t,n)}}var _1=!1;function _D(e,t){if(og=rf,e=QP(),X0(e)){if("selectionStart"in e)var r={start:e.selectionStart,end:e.selectionEnd};else e:{r=(r=e.ownerDocument)&&r.defaultView||window;var n=r.getSelection&&r.getSelection();if(n&&n.rangeCount!==0){r=n.anchorNode;var i=n.anchorOffset,a=n.focusNode;n=n.focusOffset;try{r.nodeType,a.nodeType}catch{r=null;break e}var o=0,s=-1,l=-1,u=0,d=0,c=e,f=null;t:for(;;){for(var h;c!==r||i!==0&&c.nodeType!==3||(s=o+i),c!==a||n!==0&&c.nodeType!==3||(l=o+n),c.nodeType===3&&(o+=c.nodeValue.length),(h=c.firstChild)!==null;)f=c,c=h;for(;;){if(c===e)break t;if(f===r&&++u===i&&(s=o),f===a&&++d===n&&(l=o),(h=c.nextSibling)!==null)break;c=f,f=c.parentNode}c=h}r=s===-1||l===-1?null:{start:s,end:l}}else r=null}r=r||{start:0,end:0}}else r=null;for(sg={focusedElem:e,selectionRange:r},rf=!1,X=t;X!==null;)if(t=X,e=t.child,(t.subtreeFlags&1028)!==0&&e!==null)e.return=t,X=e;else for(;X!==null;){t=X;try{var v=t.alternate;if(t.flags&1024)switch(t.tag){case 0:case 11:case 15:break;case 1:if(v!==null){var m=v.memoizedProps,g=v.memoizedState,y=t.stateNode,b=y.getSnapshotBeforeUpdate(t.elementType===t.type?m:Ur(t.type,m),g);y.__reactInternalSnapshotBeforeUpdate=b}break;case 3:var w=t.stateNode.containerInfo;w.nodeType===1?w.textContent="":w.nodeType===9&&w.documentElement&&w.removeChild(w.documentElement);break;case 5:case 6:case 4:case 17:break;default:throw Error(V(163))}}catch(_){Qe(t,t.return,_)}if(e=t.sibling,e!==null){e.return=t.return,X=e;break}X=t.return}return v=_1,_1=!1,v}function ql(e,t,r){var n=t.updateQueue;if(n=n!==null?n.lastEffect:null,n!==null){var i=n=n.next;do{if((i.tag&e)===e){var a=i.destroy;i.destroy=void 0,a!==void 0&&Sg(t,r,a)}i=i.next}while(i!==n)}}function Wh(e,t){if(t=t.updateQueue,t=t!==null?t.lastEffect:null,t!==null){var r=t=t.next;do{if((r.tag&e)===e){var n=r.create;r.destroy=n()}r=r.next}while(r!==t)}}function Og(e){var t=e.ref;if(t!==null){var r=e.stateNode;switch(e.tag){case 5:e=r;break;default:e=r}typeof t=="function"?t(e):t.current=e}}function KA(e){var t=e.alternate;t!==null&&(e.alternate=null,KA(t)),e.child=null,e.deletions=null,e.sibling=null,e.tag===5&&(t=e.stateNode,t!==null&&(delete t[gn],delete t[du],delete t[cg],delete t[iD],delete t[aD])),e.stateNode=null,e.return=null,e.dependencies=null,e.memoizedProps=null,e.memoizedState=null,e.pendingProps=null,e.stateNode=null,e.updateQueue=null}function GA(e){return e.tag===5||e.tag===3||e.tag===4}function S1(e){e:for(;;){for(;e.sibling===null;){if(e.return===null||GA(e.return))return null;e=e.return}for(e.sibling.return=e.return,e=e.sibling;e.tag!==5&&e.tag!==6&&e.tag!==18;){if(e.flags&2||e.child===null||e.tag===4)continue e;e.child.return=e,e=e.child}if(!(e.flags&2))return e.stateNode}}function Eg(e,t,r){var n=e.tag;if(n===5||n===6)e=e.stateNode,t?r.nodeType===8?r.parentNode.insertBefore(e,t):r.insertBefore(e,t):(r.nodeType===8?(t=r.parentNode,t.insertBefore(e,r)):(t=r,t.appendChild(e)),r=r._reactRootContainer,r!=null||t.onclick!==null||(t.onclick=of));else if(n!==4&&(e=e.child,e!==null))for(Eg(e,t,r),e=e.sibling;e!==null;)Eg(e,t,r),e=e.sibling}function kg(e,t,r){var n=e.tag;if(n===5||n===6)e=e.stateNode,t?r.insertBefore(e,t):r.appendChild(e);else if(n!==4&&(e=e.child,e!==null))for(kg(e,t,r),e=e.sibling;e!==null;)kg(e,t,r),e=e.sibling}var St=null,Hr=!1;function fi(e,t,r){for(r=r.child;r!==null;)YA(e,t,r),r=r.sibling}function YA(e,t,r){if(xn&&typeof xn.onCommitFiberUnmount=="function")try{xn.onCommitFiberUnmount(Ih,r)}catch{}switch(r.tag){case 5:Nt||Do(r,t);case 6:var n=St,i=Hr;St=null,fi(e,t,r),St=n,Hr=i,St!==null&&(Hr?(e=St,r=r.stateNode,e.nodeType===8?e.parentNode.removeChild(r):e.removeChild(r)):St.removeChild(r.stateNode));break;case 18:St!==null&&(Hr?(e=St,r=r.stateNode,e.nodeType===8?Nm(e.parentNode,r):e.nodeType===1&&Nm(e,r),ou(e)):Nm(St,r.stateNode));break;case 4:n=St,i=Hr,St=r.stateNode.containerInfo,Hr=!0,fi(e,t,r),St=n,Hr=i;break;case 0:case 11:case 14:case 15:if(!Nt&&(n=r.updateQueue,n!==null&&(n=n.lastEffect,n!==null))){i=n=n.next;do{var a=i,o=a.destroy;a=a.tag,o!==void 0&&(a&2||a&4)&&Sg(r,t,o),i=i.next}while(i!==n)}fi(e,t,r);break;case 1:if(!Nt&&(Do(r,t),n=r.stateNode,typeof n.componentWillUnmount=="function"))try{n.props=r.memoizedProps,n.state=r.memoizedState,n.componentWillUnmount()}catch(s){Qe(r,t,s)}fi(e,t,r);break;case 21:fi(e,t,r);break;case 22:r.mode&1?(Nt=(n=Nt)||r.memoizedState!==null,fi(e,t,r),Nt=n):fi(e,t,r);break;default:fi(e,t,r)}}function O1(e){var t=e.updateQueue;if(t!==null){e.updateQueue=null;var r=e.stateNode;r===null&&(r=e.stateNode=new xD),t.forEach(function(n){var i=CD.bind(null,e,n);r.has(n)||(r.add(n),n.then(i,i))})}}function Mr(e,t){var r=t.deletions;if(r!==null)for(var n=0;n<r.length;n++){var i=r[n];try{var a=e,o=t,s=o;e:for(;s!==null;){switch(s.tag){case 5:St=s.stateNode,Hr=!1;break e;case 3:St=s.stateNode.containerInfo,Hr=!0;break e;case 4:St=s.stateNode.containerInfo,Hr=!0;break e}s=s.return}if(St===null)throw Error(V(160));YA(a,o,i),St=null,Hr=!1;var l=i.alternate;l!==null&&(l.return=null),i.return=null}catch(u){Qe(i,t,u)}}if(t.subtreeFlags&12854)for(t=t.child;t!==null;)XA(t,e),t=t.sibling}function XA(e,t){var r=e.alternate,n=e.flags;switch(e.tag){case 0:case 11:case 14:case 15:if(Mr(t,e),dn(e),n&4){try{ql(3,e,e.return),Wh(3,e)}catch(m){Qe(e,e.return,m)}try{ql(5,e,e.return)}catch(m){Qe(e,e.return,m)}}break;case 1:Mr(t,e),dn(e),n&512&&r!==null&&Do(r,r.return);break;case 5:if(Mr(t,e),dn(e),n&512&&r!==null&&Do(r,r.return),e.flags&32){var i=e.stateNode;try{ru(i,"")}catch(m){Qe(e,e.return,m)}}if(n&4&&(i=e.stateNode,i!=null)){var a=e.memoizedProps,o=r!==null?r.memoizedProps:a,s=e.type,l=e.updateQueue;if(e.updateQueue=null,l!==null)try{s==="input"&&a.type==="radio"&&a.name!=null&&yP(i,a),Xv(s,o);var u=Xv(s,a);for(o=0;o<l.length;o+=2){var d=l[o],c=l[o+1];d==="style"?SP(i,c):d==="dangerouslySetInnerHTML"?xP(i,c):d==="children"?ru(i,c):D0(i,d,c,u)}switch(s){case"input":Hv(i,a);break;case"textarea":bP(i,a);break;case"select":var f=i._wrapperState.wasMultiple;i._wrapperState.wasMultiple=!!a.multiple;var h=a.value;h!=null?Wo(i,!!a.multiple,h,!1):f!==!!a.multiple&&(a.defaultValue!=null?Wo(i,!!a.multiple,a.defaultValue,!0):Wo(i,!!a.multiple,a.multiple?[]:"",!1))}i[du]=a}catch(m){Qe(e,e.return,m)}}break;case 6:if(Mr(t,e),dn(e),n&4){if(e.stateNode===null)throw Error(V(162));i=e.stateNode,a=e.memoizedProps;try{i.nodeValue=a}catch(m){Qe(e,e.return,m)}}break;case 3:if(Mr(t,e),dn(e),n&4&&r!==null&&r.memoizedState.isDehydrated)try{ou(t.containerInfo)}catch(m){Qe(e,e.return,m)}break;case 4:Mr(t,e),dn(e);break;case 13:Mr(t,e),dn(e),i=e.child,i.flags&8192&&(a=i.memoizedState!==null,i.stateNode.isHidden=a,!a||i.alternate!==null&&i.alternate.memoizedState!==null||(vb=et())),n&4&&O1(e);break;case 22:if(d=r!==null&&r.memoizedState!==null,e.mode&1?(Nt=(u=Nt)||d,Mr(t,e),Nt=u):Mr(t,e),dn(e),n&8192){if(u=e.memoizedState!==null,(e.stateNode.isHidden=u)&&!d&&e.mode&1)for(X=e,d=e.child;d!==null;){for(c=X=d;X!==null;){switch(f=X,h=f.child,f.tag){case 0:case 11:case 14:case 15:ql(4,f,f.return);break;case 1:Do(f,f.return);var v=f.stateNode;if(typeof v.componentWillUnmount=="function"){n=f,r=f.return;try{t=n,v.props=t.memoizedProps,v.state=t.memoizedState,v.componentWillUnmount()}catch(m){Qe(n,r,m)}}break;case 5:Do(f,f.return);break;case 22:if(f.memoizedState!==null){k1(c);continue}}h!==null?(h.return=f,X=h):k1(c)}d=d.sibling}e:for(d=null,c=e;;){if(c.tag===5){if(d===null){d=c;try{i=c.stateNode,u?(a=i.style,typeof a.setProperty=="function"?a.setProperty("display","none","important"):a.display="none"):(s=c.stateNode,l=c.memoizedProps.style,o=l!=null&&l.hasOwnProperty("display")?l.display:null,s.style.display=_P("display",o))}catch(m){Qe(e,e.return,m)}}}else if(c.tag===6){if(d===null)try{c.stateNode.nodeValue=u?"":c.memoizedProps}catch(m){Qe(e,e.return,m)}}else if((c.tag!==22&&c.tag!==23||c.memoizedState===null||c===e)&&c.child!==null){c.child.return=c,c=c.child;continue}if(c===e)break e;for(;c.sibling===null;){if(c.return===null||c.return===e)break e;d===c&&(d=null),c=c.return}d===c&&(d=null),c.sibling.return=c.return,c=c.sibling}}break;case 19:Mr(t,e),dn(e),n&4&&O1(e);break;case 21:break;default:Mr(t,e),dn(e)}}function dn(e){var t=e.flags;if(t&2){try{e:{for(var r=e.return;r!==null;){if(GA(r)){var n=r;break e}r=r.return}throw Error(V(160))}switch(n.tag){case 5:var i=n.stateNode;n.flags&32&&(ru(i,""),n.flags&=-33);var a=S1(e);kg(e,a,i);break;case 3:case 4:var o=n.stateNode.containerInfo,s=S1(e);Eg(e,s,o);break;default:throw Error(V(161))}}catch(l){Qe(e,e.return,l)}e.flags&=-3}t&4096&&(e.flags&=-4097)}function SD(e,t,r){X=e,QA(e)}function QA(e,t,r){for(var n=(e.mode&1)!==0;X!==null;){var i=X,a=i.child;if(i.tag===22&&n){var o=i.memoizedState!==null||Zc;if(!o){var s=i.alternate,l=s!==null&&s.memoizedState!==null||Nt;s=Zc;var u=Nt;if(Zc=o,(Nt=l)&&!u)for(X=i;X!==null;)o=X,l=o.child,o.tag===22&&o.memoizedState!==null?P1(i):l!==null?(l.return=o,X=l):P1(i);for(;a!==null;)X=a,QA(a),a=a.sibling;X=i,Zc=s,Nt=u}E1(e)}else i.subtreeFlags&8772&&a!==null?(a.return=i,X=a):E1(e)}}function E1(e){for(;X!==null;){var t=X;if(t.flags&8772){var r=t.alternate;try{if(t.flags&8772)switch(t.tag){case 0:case 11:case 15:Nt||Wh(5,t);break;case 1:var n=t.stateNode;if(t.flags&4&&!Nt)if(r===null)n.componentDidMount();else{var i=t.elementType===t.type?r.memoizedProps:Ur(t.type,r.memoizedProps);n.componentDidUpdate(i,r.memoizedState,n.__reactInternalSnapshotBeforeUpdate)}var a=t.updateQueue;a!==null&&u1(t,a,n);break;case 3:var o=t.updateQueue;if(o!==null){if(r=null,t.child!==null)switch(t.child.tag){case 5:r=t.child.stateNode;break;case 1:r=t.child.stateNode}u1(t,o,r)}break;case 5:var s=t.stateNode;if(r===null&&t.flags&4){r=s;var l=t.memoizedProps;switch(t.type){case"button":case"input":case"select":case"textarea":l.autoFocus&&r.focus();break;case"img":l.src&&(r.src=l.src)}}break;case 6:break;case 4:break;case 12:break;case 13:if(t.memoizedState===null){var u=t.alternate;if(u!==null){var d=u.memoizedState;if(d!==null){var c=d.dehydrated;c!==null&&ou(c)}}}break;case 19:case 17:case 21:case 22:case 23:case 25:break;default:throw Error(V(163))}Nt||t.flags&512&&Og(t)}catch(f){Qe(t,t.return,f)}}if(t===e){X=null;break}if(r=t.sibling,r!==null){r.return=t.return,X=r;break}X=t.return}}function k1(e){for(;X!==null;){var t=X;if(t===e){X=null;break}var r=t.sibling;if(r!==null){r.return=t.return,X=r;break}X=t.return}}function P1(e){for(;X!==null;){var t=X;try{switch(t.tag){case 0:case 11:case 15:var r=t.return;try{Wh(4,t)}catch(l){Qe(t,r,l)}break;case 1:var n=t.stateNode;if(typeof n.componentDidMount=="function"){var i=t.return;try{n.componentDidMount()}catch(l){Qe(t,i,l)}}var a=t.return;try{Og(t)}catch(l){Qe(t,a,l)}break;case 5:var o=t.return;try{Og(t)}catch(l){Qe(t,o,l)}}}catch(l){Qe(t,t.return,l)}if(t===e){X=null;break}var s=t.sibling;if(s!==null){s.return=t.return,X=s;break}X=t.return}}var OD=Math.ceil,gf=ri.ReactCurrentDispatcher,pb=ri.ReactCurrentOwner,Er=ri.ReactCurrentBatchConfig,he=0,yt=null,nt=null,Et=0,nr=0,Lo=Qi(0),ut=0,gu=null,qa=0,qh=0,mb=0,Hl=null,Ht=null,vb=0,gs=1/0,Mn=null,yf=!1,Pg=null,Bi=null,ed=!1,Ci=null,bf=0,Vl=0,Ag=null,Fd=-1,zd=0;function Ut(){return he&6?et():Fd!==-1?Fd:Fd=et()}function Ui(e){return e.mode&1?he&2&&Et!==0?Et&-Et:sD.transition!==null?(zd===0&&(zd=IP()),zd):(e=Ee,e!==0||(e=window.event,e=e===void 0?16:zP(e.type)),e):1}function Jr(e,t,r,n){if(50<Vl)throw Vl=0,Ag=null,Error(V(185));yc(e,r,n),(!(he&2)||e!==yt)&&(e===yt&&(!(he&2)&&(qh|=r),ut===4&&Si(e,Et)),Qt(e,n),r===1&&he===0&&!(t.mode&1)&&(gs=et()+500,Uh&&Ji()))}function Qt(e,t){var r=e.callbackNode;sM(e,t);var n=tf(e,e===yt?Et:0);if(n===0)r!==null&&Mx(r),e.callbackNode=null,e.callbackPriority=0;else if(t=n&-n,e.callbackPriority!==t){if(r!=null&&Mx(r),t===1)e.tag===0?oD(A1.bind(null,e)):sA(A1.bind(null,e)),rD(function(){!(he&6)&&Ji()}),r=null;else{switch(MP(n)){case 1:r=z0;break;case 4:r=$P;break;case 16:r=ef;break;case 536870912:r=RP;break;default:r=ef}r=aj(r,JA.bind(null,e))}e.callbackPriority=t,e.callbackNode=r}}function JA(e,t){if(Fd=-1,zd=0,he&6)throw Error(V(327));var r=e.callbackNode;if(Go()&&e.callbackNode!==r)return null;var n=tf(e,e===yt?Et:0);if(n===0)return null;if(n&30||n&e.expiredLanes||t)t=wf(e,n);else{t=n;var i=he;he|=2;var a=ej();(yt!==e||Et!==t)&&(Mn=null,gs=et()+500,$a(e,t));do try{PD();break}catch(s){ZA(e,s)}while(!0);tb(),gf.current=a,he=i,nt!==null?t=0:(yt=null,Et=0,t=ut)}if(t!==0){if(t===2&&(i=tg(e),i!==0&&(n=i,t=jg(e,i))),t===1)throw r=gu,$a(e,0),Si(e,n),Qt(e,et()),r;if(t===6)Si(e,n);else{if(i=e.current.alternate,!(n&30)&&!ED(i)&&(t=wf(e,n),t===2&&(a=tg(e),a!==0&&(n=a,t=jg(e,a))),t===1))throw r=gu,$a(e,0),Si(e,n),Qt(e,et()),r;switch(e.finishedWork=i,e.finishedLanes=n,t){case 0:case 1:throw Error(V(345));case 2:fa(e,Ht,Mn);break;case 3:if(Si(e,n),(n&130023424)===n&&(t=vb+500-et(),10<t)){if(tf(e,0)!==0)break;if(i=e.suspendedLanes,(i&n)!==n){Ut(),e.pingedLanes|=e.suspendedLanes&i;break}e.timeoutHandle=ug(fa.bind(null,e,Ht,Mn),t);break}fa(e,Ht,Mn);break;case 4:if(Si(e,n),(n&4194240)===n)break;for(t=e.eventTimes,i=-1;0<n;){var o=31-Qr(n);a=1<<o,o=t[o],o>i&&(i=o),n&=~a}if(n=i,n=et()-n,n=(120>n?120:480>n?480:1080>n?1080:1920>n?1920:3e3>n?3e3:4320>n?4320:1960*OD(n/1960))-n,10<n){e.timeoutHandle=ug(fa.bind(null,e,Ht,Mn),n);break}fa(e,Ht,Mn);break;case 5:fa(e,Ht,Mn);break;default:throw Error(V(329))}}}return Qt(e,et()),e.callbackNode===r?JA.bind(null,e):null}function jg(e,t){var r=Hl;return e.current.memoizedState.isDehydrated&&($a(e,t).flags|=256),e=wf(e,t),e!==2&&(t=Ht,Ht=r,t!==null&&Tg(t)),e}function Tg(e){Ht===null?Ht=e:Ht.push.apply(Ht,e)}function ED(e){for(var t=e;;){if(t.flags&16384){var r=t.updateQueue;if(r!==null&&(r=r.stores,r!==null))for(var n=0;n<r.length;n++){var i=r[n],a=i.getSnapshot;i=i.value;try{if(!nn(a(),i))return!1}catch{return!1}}}if(r=t.child,t.subtreeFlags&16384&&r!==null)r.return=t,t=r;else{if(t===e)break;for(;t.sibling===null;){if(t.return===null||t.return===e)return!0;t=t.return}t.sibling.return=t.return,t=t.sibling}}return!0}function Si(e,t){for(t&=~mb,t&=~qh,e.suspendedLanes|=t,e.pingedLanes&=~t,e=e.expirationTimes;0<t;){var r=31-Qr(t),n=1<<r;e[r]=-1,t&=~n}}function A1(e){if(he&6)throw Error(V(327));Go();var t=tf(e,0);if(!(t&1))return Qt(e,et()),null;var r=wf(e,t);if(e.tag!==0&&r===2){var n=tg(e);n!==0&&(t=n,r=jg(e,n))}if(r===1)throw r=gu,$a(e,0),Si(e,t),Qt(e,et()),r;if(r===6)throw Error(V(345));return e.finishedWork=e.current.alternate,e.finishedLanes=t,fa(e,Ht,Mn),Qt(e,et()),null}function gb(e,t){var r=he;he|=1;try{return e(t)}finally{he=r,he===0&&(gs=et()+500,Uh&&Ji())}}function Ha(e){Ci!==null&&Ci.tag===0&&!(he&6)&&Go();var t=he;he|=1;var r=Er.transition,n=Ee;try{if(Er.transition=null,Ee=1,e)return e()}finally{Ee=n,Er.transition=r,he=t,!(he&6)&&Ji()}}function yb(){nr=Lo.current,Ue(Lo)}function $a(e,t){e.finishedWork=null,e.finishedLanes=0;var r=e.timeoutHandle;if(r!==-1&&(e.timeoutHandle=-1,tD(r)),nt!==null)for(r=nt.return;r!==null;){var n=r;switch(J0(n),n.tag){case 1:n=n.type.childContextTypes,n!=null&&sf();break;case 3:ms(),Ue(Yt),Ue(It),sb();break;case 5:ob(n);break;case 4:ms();break;case 13:Ue(Ve);break;case 19:Ue(Ve);break;case 10:rb(n.type._context);break;case 22:case 23:yb()}r=r.return}if(yt=e,nt=e=Fi(e.current,null),Et=nr=t,ut=0,gu=null,mb=qh=qa=0,Ht=Hl=null,wa!==null){for(t=0;t<wa.length;t++)if(r=wa[t],n=r.interleaved,n!==null){r.interleaved=null;var i=n.next,a=r.pending;if(a!==null){var o=a.next;a.next=i,n.next=o}r.pending=n}wa=null}return e}function ZA(e,t){do{var r=nt;try{if(tb(),Ld.current=vf,mf){for(var n=Ke.memoizedState;n!==null;){var i=n.queue;i!==null&&(i.pending=null),n=n.next}mf=!1}if(Wa=0,vt=lt=Ke=null,Wl=!1,pu=0,pb.current=null,r===null||r.return===null){ut=1,gu=t,nt=null;break}e:{var a=e,o=r.return,s=r,l=t;if(t=Et,s.flags|=32768,l!==null&&typeof l=="object"&&typeof l.then=="function"){var u=l,d=s,c=d.tag;if(!(d.mode&1)&&(c===0||c===11||c===15)){var f=d.alternate;f?(d.updateQueue=f.updateQueue,d.memoizedState=f.memoizedState,d.lanes=f.lanes):(d.updateQueue=null,d.memoizedState=null)}var h=m1(o);if(h!==null){h.flags&=-257,v1(h,o,s,a,t),h.mode&1&&p1(a,u,t),t=h,l=u;var v=t.updateQueue;if(v===null){var m=new Set;m.add(l),t.updateQueue=m}else v.add(l);break e}else{if(!(t&1)){p1(a,u,t),bb();break e}l=Error(V(426))}}else if(We&&s.mode&1){var g=m1(o);if(g!==null){!(g.flags&65536)&&(g.flags|=256),v1(g,o,s,a,t),Z0(vs(l,s));break e}}a=l=vs(l,s),ut!==4&&(ut=2),Hl===null?Hl=[a]:Hl.push(a),a=o;do{switch(a.tag){case 3:a.flags|=65536,t&=-t,a.lanes|=t;var y=MA(a,l,t);l1(a,y);break e;case 1:s=l;var b=a.type,w=a.stateNode;if(!(a.flags&128)&&(typeof b.getDerivedStateFromError=="function"||w!==null&&typeof w.componentDidCatch=="function"&&(Bi===null||!Bi.has(w)))){a.flags|=65536,t&=-t,a.lanes|=t;var _=DA(a,s,t);l1(a,_);break e}}a=a.return}while(a!==null)}rj(r)}catch(x){t=x,nt===r&&r!==null&&(nt=r=r.return);continue}break}while(!0)}function ej(){var e=gf.current;return gf.current=vf,e===null?vf:e}function bb(){(ut===0||ut===3||ut===2)&&(ut=4),yt===null||!(qa&268435455)&&!(qh&268435455)||Si(yt,Et)}function wf(e,t){var r=he;he|=2;var n=ej();(yt!==e||Et!==t)&&(Mn=null,$a(e,t));do try{kD();break}catch(i){ZA(e,i)}while(!0);if(tb(),he=r,gf.current=n,nt!==null)throw Error(V(261));return yt=null,Et=0,ut}function kD(){for(;nt!==null;)tj(nt)}function PD(){for(;nt!==null&&!JI();)tj(nt)}function tj(e){var t=ij(e.alternate,e,nr);e.memoizedProps=e.pendingProps,t===null?rj(e):nt=t,pb.current=null}function rj(e){var t=e;do{var r=t.alternate;if(e=t.return,t.flags&32768){if(r=wD(r,t),r!==null){r.flags&=32767,nt=r;return}if(e!==null)e.flags|=32768,e.subtreeFlags=0,e.deletions=null;else{ut=6,nt=null;return}}else if(r=bD(r,t,nr),r!==null){nt=r;return}if(t=t.sibling,t!==null){nt=t;return}nt=t=e}while(t!==null);ut===0&&(ut=5)}function fa(e,t,r){var n=Ee,i=Er.transition;try{Er.transition=null,Ee=1,AD(e,t,r,n)}finally{Er.transition=i,Ee=n}return null}function AD(e,t,r,n){do Go();while(Ci!==null);if(he&6)throw Error(V(327));r=e.finishedWork;var i=e.finishedLanes;if(r===null)return null;if(e.finishedWork=null,e.finishedLanes=0,r===e.current)throw Error(V(177));e.callbackNode=null,e.callbackPriority=0;var a=r.lanes|r.childLanes;if(lM(e,a),e===yt&&(nt=yt=null,Et=0),!(r.subtreeFlags&2064)&&!(r.flags&2064)||ed||(ed=!0,aj(ef,function(){return Go(),null})),a=(r.flags&15990)!==0,r.subtreeFlags&15990||a){a=Er.transition,Er.transition=null;var o=Ee;Ee=1;var s=he;he|=4,pb.current=null,_D(e,r),XA(r,e),GM(sg),rf=!!og,sg=og=null,e.current=r,SD(r),ZI(),he=s,Ee=o,Er.transition=a}else e.current=r;if(ed&&(ed=!1,Ci=e,bf=i),a=e.pendingLanes,a===0&&(Bi=null),rM(r.stateNode),Qt(e,et()),t!==null)for(n=e.onRecoverableError,r=0;r<t.length;r++)i=t[r],n(i.value,{componentStack:i.stack,digest:i.digest});if(yf)throw yf=!1,e=Pg,Pg=null,e;return bf&1&&e.tag!==0&&Go(),a=e.pendingLanes,a&1?e===Ag?Vl++:(Vl=0,Ag=e):Vl=0,Ji(),null}function Go(){if(Ci!==null){var e=MP(bf),t=Er.transition,r=Ee;try{if(Er.transition=null,Ee=16>e?16:e,Ci===null)var n=!1;else{if(e=Ci,Ci=null,bf=0,he&6)throw Error(V(331));var i=he;for(he|=4,X=e.current;X!==null;){var a=X,o=a.child;if(X.flags&16){var s=a.deletions;if(s!==null){for(var l=0;l<s.length;l++){var u=s[l];for(X=u;X!==null;){var d=X;switch(d.tag){case 0:case 11:case 15:ql(8,d,a)}var c=d.child;if(c!==null)c.return=d,X=c;else for(;X!==null;){d=X;var f=d.sibling,h=d.return;if(KA(d),d===u){X=null;break}if(f!==null){f.return=h,X=f;break}X=h}}}var v=a.alternate;if(v!==null){var m=v.child;if(m!==null){v.child=null;do{var g=m.sibling;m.sibling=null,m=g}while(m!==null)}}X=a}}if(a.subtreeFlags&2064&&o!==null)o.return=a,X=o;else e:for(;X!==null;){if(a=X,a.flags&2048)switch(a.tag){case 0:case 11:case 15:ql(9,a,a.return)}var y=a.sibling;if(y!==null){y.return=a.return,X=y;break e}X=a.return}}var b=e.current;for(X=b;X!==null;){o=X;var w=o.child;if(o.subtreeFlags&2064&&w!==null)w.return=o,X=w;else e:for(o=b;X!==null;){if(s=X,s.flags&2048)try{switch(s.tag){case 0:case 11:case 15:Wh(9,s)}}catch(x){Qe(s,s.return,x)}if(s===o){X=null;break e}var _=s.sibling;if(_!==null){_.return=s.return,X=_;break e}X=s.return}}if(he=i,Ji(),xn&&typeof xn.onPostCommitFiberRoot=="function")try{xn.onPostCommitFiberRoot(Ih,e)}catch{}n=!0}return n}finally{Ee=r,Er.transition=t}}return!1}function j1(e,t,r){t=vs(r,t),t=MA(e,t,1),e=Li(e,t,1),t=Ut(),e!==null&&(yc(e,1,t),Qt(e,t))}function Qe(e,t,r){if(e.tag===3)j1(e,e,r);else for(;t!==null;){if(t.tag===3){j1(t,e,r);break}else if(t.tag===1){var n=t.stateNode;if(typeof t.type.getDerivedStateFromError=="function"||typeof n.componentDidCatch=="function"&&(Bi===null||!Bi.has(n))){e=vs(r,e),e=DA(t,e,1),t=Li(t,e,1),e=Ut(),t!==null&&(yc(t,1,e),Qt(t,e));break}}t=t.return}}function jD(e,t,r){var n=e.pingCache;n!==null&&n.delete(t),t=Ut(),e.pingedLanes|=e.suspendedLanes&r,yt===e&&(Et&r)===r&&(ut===4||ut===3&&(Et&130023424)===Et&&500>et()-vb?$a(e,0):mb|=r),Qt(e,t)}function nj(e,t){t===0&&(e.mode&1?(t=qc,qc<<=1,!(qc&130023424)&&(qc=4194304)):t=1);var r=Ut();e=Yn(e,t),e!==null&&(yc(e,t,r),Qt(e,r))}function TD(e){var t=e.memoizedState,r=0;t!==null&&(r=t.retryLane),nj(e,r)}function CD(e,t){var r=0;switch(e.tag){case 13:var n=e.stateNode,i=e.memoizedState;i!==null&&(r=i.retryLane);break;case 19:n=e.stateNode;break;default:throw Error(V(314))}n!==null&&n.delete(t),nj(e,r)}var ij;ij=function(e,t,r){if(e!==null)if(e.memoizedProps!==t.pendingProps||Yt.current)Vt=!0;else{if(!(e.lanes&r)&&!(t.flags&128))return Vt=!1,yD(e,t,r);Vt=!!(e.flags&131072)}else Vt=!1,We&&t.flags&1048576&&lA(t,cf,t.index);switch(t.lanes=0,t.tag){case 2:var n=t.type;Ud(e,t),e=t.pendingProps;var i=fs(t,It.current);Ko(t,r),i=ub(null,t,n,e,i,r);var a=cb();return t.flags|=1,typeof i=="object"&&i!==null&&typeof i.render=="function"&&i.$$typeof===void 0?(t.tag=1,t.memoizedState=null,t.updateQueue=null,Xt(n)?(a=!0,lf(t)):a=!1,t.memoizedState=i.state!==null&&i.state!==void 0?i.state:null,ib(t),i.updater=zh,t.stateNode=i,i._reactInternals=t,vg(t,n,e,r),t=bg(null,t,n,!0,a,r)):(t.tag=0,We&&a&&Q0(t),Dt(null,t,i,r),t=t.child),t;case 16:n=t.elementType;e:{switch(Ud(e,t),e=t.pendingProps,i=n._init,n=i(n._payload),t.type=n,i=t.tag=$D(n),e=Ur(n,e),i){case 0:t=yg(null,t,n,e,r);break e;case 1:t=b1(null,t,n,e,r);break e;case 11:t=g1(null,t,n,e,r);break e;case 14:t=y1(null,t,n,Ur(n.type,e),r);break e}throw Error(V(306,n,""))}return t;case 0:return n=t.type,i=t.pendingProps,i=t.elementType===n?i:Ur(n,i),yg(e,t,n,i,r);case 1:return n=t.type,i=t.pendingProps,i=t.elementType===n?i:Ur(n,i),b1(e,t,n,i,r);case 3:e:{if(FA(t),e===null)throw Error(V(387));n=t.pendingProps,a=t.memoizedState,i=a.element,pA(e,t),hf(t,n,null,r);var o=t.memoizedState;if(n=o.element,a.isDehydrated)if(a={element:n,isDehydrated:!1,cache:o.cache,pendingSuspenseBoundaries:o.pendingSuspenseBoundaries,transitions:o.transitions},t.updateQueue.baseState=a,t.memoizedState=a,t.flags&256){i=vs(Error(V(423)),t),t=w1(e,t,n,r,i);break e}else if(n!==i){i=vs(Error(V(424)),t),t=w1(e,t,n,r,i);break e}else for(lr=Di(t.stateNode.containerInfo.firstChild),ur=t,We=!0,Gr=null,r=fA(t,null,n,r),t.child=r;r;)r.flags=r.flags&-3|4096,r=r.sibling;else{if(hs(),n===i){t=Xn(e,t,r);break e}Dt(e,t,n,r)}t=t.child}return t;case 5:return mA(t),e===null&&hg(t),n=t.type,i=t.pendingProps,a=e!==null?e.memoizedProps:null,o=i.children,lg(n,i)?o=null:a!==null&&lg(n,a)&&(t.flags|=32),UA(e,t),Dt(e,t,o,r),t.child;case 6:return e===null&&hg(t),null;case 13:return zA(e,t,r);case 4:return ab(t,t.stateNode.containerInfo),n=t.pendingProps,e===null?t.child=ps(t,null,n,r):Dt(e,t,n,r),t.child;case 11:return n=t.type,i=t.pendingProps,i=t.elementType===n?i:Ur(n,i),g1(e,t,n,i,r);case 7:return Dt(e,t,t.pendingProps,r),t.child;case 8:return Dt(e,t,t.pendingProps.children,r),t.child;case 12:return Dt(e,t,t.pendingProps.children,r),t.child;case 10:e:{if(n=t.type._context,i=t.pendingProps,a=t.memoizedProps,o=i.value,Ie(df,n._currentValue),n._currentValue=o,a!==null)if(nn(a.value,o)){if(a.children===i.children&&!Yt.current){t=Xn(e,t,r);break e}}else for(a=t.child,a!==null&&(a.return=t);a!==null;){var s=a.dependencies;if(s!==null){o=a.child;for(var l=s.firstContext;l!==null;){if(l.context===n){if(a.tag===1){l=qn(-1,r&-r),l.tag=2;var u=a.updateQueue;if(u!==null){u=u.shared;var d=u.pending;d===null?l.next=l:(l.next=d.next,d.next=l),u.pending=l}}a.lanes|=r,l=a.alternate,l!==null&&(l.lanes|=r),pg(a.return,r,t),s.lanes|=r;break}l=l.next}}else if(a.tag===10)o=a.type===t.type?null:a.child;else if(a.tag===18){if(o=a.return,o===null)throw Error(V(341));o.lanes|=r,s=o.alternate,s!==null&&(s.lanes|=r),pg(o,r,t),o=a.sibling}else o=a.child;if(o!==null)o.return=a;else for(o=a;o!==null;){if(o===t){o=null;break}if(a=o.sibling,a!==null){a.return=o.return,o=a;break}o=o.return}a=o}Dt(e,t,i.children,r),t=t.child}return t;case 9:return i=t.type,n=t.pendingProps.children,Ko(t,r),i=Pr(i),n=n(i),t.flags|=1,Dt(e,t,n,r),t.child;case 14:return n=t.type,i=Ur(n,t.pendingProps),i=Ur(n.type,i),y1(e,t,n,i,r);case 15:return LA(e,t,t.type,t.pendingProps,r);case 17:return n=t.type,i=t.pendingProps,i=t.elementType===n?i:Ur(n,i),Ud(e,t),t.tag=1,Xt(n)?(e=!0,lf(t)):e=!1,Ko(t,r),IA(t,n,i),vg(t,n,i,r),bg(null,t,n,!0,e,r);case 19:return WA(e,t,r);case 22:return BA(e,t,r)}throw Error(V(156,t.tag))};function aj(e,t){return NP(e,t)}function ND(e,t,r,n){this.tag=e,this.key=r,this.sibling=this.child=this.return=this.stateNode=this.t
vendor: 9,849 bytes, line 40
40ype=this.elementType=null,this.index=0,this.ref=null,this.pendingProps=t,this.dependencies=this.memoizedState=this.updateQueue=this.memoizedProps=null,this.mode=n,this.subtreeFlags=this.flags=0,this.deletions=null,this.childLanes=this.lanes=0,this.alternate=null}function Sr(e,t,r,n){return new ND(e,t,r,n)}function wb(e){return e=e.prototype,!(!e||!e.isReactComponent)}function $D(e){if(typeof e=="function")return wb(e)?1:0;if(e!=null){if(e=e.$$typeof,e===B0)return 11;if(e===U0)return 14}return 2}function Fi(e,t){var r=e.alternate;return r===null?(r=Sr(e.tag,t,e.key,e.mode),r.elementType=e.elementType,r.type=e.type,r.stateNode=e.stateNode,r.alternate=e,e.alternate=r):(r.pendingProps=t,r.type=e.type,r.flags=0,r.subtreeFlags=0,r.deletions=null),r.flags=e.flags&14680064,r.childLanes=e.childLanes,r.lanes=e.lanes,r.child=e.child,r.memoizedProps=e.memoizedProps,r.memoizedState=e.memoizedState,r.updateQueue=e.updateQueue,t=e.dependencies,r.dependencies=t===null?null:{lanes:t.lanes,firstContext:t.firstContext},r.sibling=e.sibling,r.index=e.index,r.ref=e.ref,r}function Wd(e,t,r,n,i,a){var o=2;if(n=e,typeof e=="function")wb(e)&&(o=1);else if(typeof e=="string")o=5;else e:switch(e){case Ao:return Ra(r.children,i,a,t);case L0:o=8,i|=8;break;case Uv:return e=Sr(12,r,t,i|2),e.elementType=Uv,e.lanes=a,e;case Fv:return e=Sr(13,r,t,i),e.elementType=Fv,e.lanes=a,e;case zv:return e=Sr(19,r,t,i),e.elementType=zv,e.lanes=a,e;case mP:return Hh(r,i,a,t);default:if(typeof e=="object"&&e!==null)switch(e.$$typeof){case hP:o=10;break e;case pP:o=9;break e;case B0:o=11;break e;case U0:o=14;break e;case yi:o=16,n=null;break e}throw Error(V(130,e==null?e:typeof e,""))}return t=Sr(o,r,t,i),t.elementType=e,t.type=n,t.lanes=a,t}function Ra(e,t,r,n){return e=Sr(7,e,n,t),e.lanes=r,e}function Hh(e,t,r,n){return e=Sr(22,e,n,t),e.elementType=mP,e.lanes=r,e.stateNode={isHidden:!1},e}function Um(e,t,r){return e=Sr(6,e,null,t),e.lanes=r,e}function Fm(e,t,r){return t=Sr(4,e.children!==null?e.children:[],e.key,t),t.lanes=r,t.stateNode={containerInfo:e.containerInfo,pendingChildren:null,implementation:e.implementation},t}function RD(e,t,r,n,i){this.tag=t,this.containerInfo=e,this.finishedWork=this.pingCache=this.current=this.pendingChildren=null,this.timeoutHandle=-1,this.callbackNode=this.pendingContext=this.context=null,this.callbackPriority=0,this.eventTimes=xm(0),this.expirationTimes=xm(-1),this.entangledLanes=this.finishedLanes=this.mutableReadLanes=this.expiredLanes=this.pingedLanes=this.suspendedLanes=this.pendingLanes=0,this.entanglements=xm(0),this.identifierPrefix=n,this.onRecoverableError=i,this.mutableSourceEagerHydrationData=null}function xb(e,t,r,n,i,a,o,s,l){return e=new RD(e,t,r,s,l),t===1?(t=1,a===!0&&(t|=8)):t=0,a=Sr(3,null,null,t),e.current=a,a.stateNode=e,a.memoizedState={element:n,isDehydrated:r,cache:null,transitions:null,pendingSuspenseBoundaries:null},ib(a),e}function ID(e,t,r){var n=3<arguments.length&&arguments[3]!==void 0?arguments[3]:null;return{$$typeof:Po,key:n==null?null:""+n,children:e,containerInfo:t,implementation:r}}function oj(e){if(!e)return Hi;e=e._reactInternals;e:{if(Za(e)!==e||e.tag!==1)throw Error(V(170));var t=e;do{switch(t.tag){case 3:t=t.stateNode.context;break e;case 1:if(Xt(t.type)){t=t.stateNode.__reactInternalMemoizedMergedChildContext;break e}}t=t.return}while(t!==null);throw Error(V(171))}if(e.tag===1){var r=e.type;if(Xt(r))return oA(e,r,t)}return t}function sj(e,t,r,n,i,a,o,s,l){return e=xb(r,n,!0,e,i,a,o,s,l),e.context=oj(null),r=e.current,n=Ut(),i=Ui(r),a=qn(n,i),a.callback=t??null,Li(r,a,i),e.current.lanes=i,yc(e,i,n),Qt(e,n),e}function Vh(e,t,r,n){var i=t.current,a=Ut(),o=Ui(i);return r=oj(r),t.context===null?t.context=r:t.pendingContext=r,t=qn(a,o),t.payload={element:e},n=n===void 0?null:n,n!==null&&(t.callback=n),e=Li(i,t,o),e!==null&&(Jr(e,i,o,a),Dd(e,i,o)),o}function xf(e){if(e=e.current,!e.child)return null;switch(e.child.tag){case 5:return e.child.stateNode;default:return e.child.stateNode}}function T1(e,t){if(e=e.memoizedState,e!==null&&e.dehydrated!==null){var r=e.retryLane;e.retryLane=r!==0&&r<t?r:t}}function _b(e,t){T1(e,t),(e=e.alternate)&&T1(e,t)}function MD(){return null}var lj=typeof reportError=="function"?reportError:function(e){console.error(e)};function Sb(e){this._internalRoot=e}Kh.prototype.render=Sb.prototype.render=function(e){var t=this._internalRoot;if(t===null)throw Error(V(409));Vh(e,t,null,null)};Kh.prototype.unmount=Sb.prototype.unmount=function(){var e=this._internalRoot;if(e!==null){this._internalRoot=null;var t=e.containerInfo;Ha(function(){Vh(null,e,null,null)}),t[Gn]=null}};function Kh(e){this._internalRoot=e}Kh.prototype.unstable_scheduleHydration=function(e){if(e){var t=BP();e={blockedOn:null,target:e,priority:t};for(var r=0;r<_i.length&&t!==0&&t<_i[r].priority;r++);_i.splice(r,0,e),r===0&&FP(e)}};function Ob(e){return!(!e||e.nodeType!==1&&e.nodeType!==9&&e.nodeType!==11)}function Gh(e){return!(!e||e.nodeType!==1&&e.nodeType!==9&&e.nodeType!==11&&(e.nodeType!==8||e.nodeValue!==" react-mount-point-unstable "))}function C1(){}function DD(e,t,r,n,i){if(i){if(typeof n=="function"){var a=n;n=function(){var u=xf(o);a.call(u)}}var o=sj(t,n,e,0,null,!1,!1,"",C1);return e._reactRootContainer=o,e[Gn]=o.current,uu(e.nodeType===8?e.parentNode:e),Ha(),o}for(;i=e.lastChild;)e.removeChild(i);if(typeof n=="function"){var s=n;n=function(){var u=xf(l);s.call(u)}}var l=xb(e,0,!1,null,null,!1,!1,"",C1);return e._reactRootContainer=l,e[Gn]=l.current,uu(e.nodeType===8?e.parentNode:e),Ha(function(){Vh(t,l,r,n)}),l}function Yh(e,t,r,n,i){var a=r._reactRootContainer;if(a){var o=a;if(typeof i=="function"){var s=i;i=function(){var l=xf(o);s.call(l)}}Vh(t,o,e,i)}else o=DD(r,t,e,i,n);return xf(o)}DP=function(e){switch(e.tag){case 3:var t=e.stateNode;if(t.current.memoizedState.isDehydrated){var r=Rl(t.pendingLanes);r!==0&&(W0(t,r|1),Qt(t,et()),!(he&6)&&(gs=et()+500,Ji()))}break;case 13:Ha(function(){var n=Yn(e,1);if(n!==null){var i=Ut();Jr(n,e,1,i)}}),_b(e,1)}};q0=function(e){if(e.tag===13){var t=Yn(e,134217728);if(t!==null){var r=Ut();Jr(t,e,134217728,r)}_b(e,134217728)}};LP=function(e){if(e.tag===13){var t=Ui(e),r=Yn(e,t);if(r!==null){var n=Ut();Jr(r,e,t,n)}_b(e,t)}};BP=function(){return Ee};UP=function(e,t){var r=Ee;try{return Ee=e,t()}finally{Ee=r}};Jv=function(e,t,r){switch(t){case"input":if(Hv(e,r),t=r.name,r.type==="radio"&&t!=null){for(r=e;r.parentNode;)r=r.parentNode;for(r=r.querySelectorAll("input[name="+JSON.stringify(""+t)+'][type="radio"]'),t=0;t<r.length;t++){var n=r[t];if(n!==e&&n.form===e.form){var i=Bh(n);if(!i)throw Error(V(90));gP(n),Hv(n,i)}}}break;case"textarea":bP(e,r);break;case"select":t=r.value,t!=null&&Wo(e,!!r.multiple,t,!1)}};kP=gb;PP=Ha;var LD={usingClientEntryPoint:!1,Events:[wc,No,Bh,OP,EP,gb]},yl={findFiberByHostInstance:ba,bundleType:0,version:"18.3.1",rendererPackageName:"react-dom"},BD={bundleType:yl.bundleType,version:yl.version,rendererPackageName:yl.rendererPackageName,rendererConfig:yl.rendererConfig,overrideHookState:null,overrideHookStateDeletePath:null,overrideHookStateRenamePath:null,overrideProps:null,overridePropsDeletePath:null,overridePropsRenamePath:null,setErrorHandler:null,setSuspenseHandler:null,scheduleUpdate:null,currentDispatcherRef:ri.ReactCurrentDispatcher,findHostInstanceByFiber:function(e){return e=TP(e),e===null?null:e.stateNode},findFiberByHostInstance:yl.findFiberByHostInstance||MD,findHostInstancesForRefresh:null,scheduleRefresh:null,scheduleRoot:null,setRefreshHandler:null,getCurrentFiber:null,reconcilerVersion:"18.3.1-next-f1338f8080-20240426"};if(typeof __REACT_DEVTOOLS_GLOBAL_HOOK__<"u"){var td=__REACT_DEVTOOLS_GLOBAL_HOOK__;if(!td.isDisabled&&td.supportsFiber)try{Ih=td.inject(BD),xn=td}catch{}}pr.__SECRET_INTERNALS_DO_NOT_USE_OR_YOU_WILL_BE_FIRED=LD;pr.createPortal=function(e,t){var r=2<arguments.length&&arguments[2]!==void 0?arguments[2]:null;if(!Ob(t))throw Error(V(200));return ID(e,t,null,r)};pr.createRoot=function(e,t){if(!Ob(e))throw Error(V(299));var r=!1,n="",i=lj;return t!=null&&(t.unstable_strictMode===!0&&(r=!0),t.identifierPrefix!==void 0&&(n=t.identifierPrefix),t.onRecoverableError!==void 0&&(i=t.onRecoverableError)),t=xb(e,1,!1,null,null,r,!1,n,i),e[Gn]=t.current,uu(e.nodeType===8?e.parentNode:e),new Sb(t)};pr.findDOMNode=function(e){if(e==null)return null;if(e.nodeType===1)return e;var t=e._reactInternals;if(t===void 0)throw typeof e.render=="function"?Error(V(188)):(e=Object.keys(e).join(","),Error(V(268,e)));return e=TP(t),e=e===null?null:e.stateNode,e};pr.flushSync=function(e){return Ha(e)};pr.hydrate=function(e,t,r){if(!Gh(t))throw Error(V(200));return Yh(null,e,t,!0,r)};pr.hydrateRoot=function(e,t,r){if(!Ob(e))throw Error(V(405));var n=r!=null&&r.hydratedSources||null,i=!1,a="",o=lj;if(r!=null&&(r.unstable_strictMode===!0&&(i=!0),r.identifierPrefix!==void 0&&(a=r.identifierPrefix),r.onRecoverableError!==void 0&&(o=r.onRecoverableError)),t=sj(t,null,e,1,r??null,i,!1,a,o),e[Gn]=t.current,uu(e),n)for(e=0;e<n.length;e++)r=n[e],i=r._getVersion,i=i(r._source),t.mutableSourceEagerHydrationData==null?t.mutableSourceEagerHydrationData=[r,i]:t.mutableSourceEagerHydrationData.push(r,i);return new Kh(t)};pr.render=function(e,t,r){if(!Gh(t))throw Error(V(200));return Yh(null,e,t,!1,r)};pr.unmountComponentAtNode=function(e){if(!Gh(e))throw Error(V(40));return e._reactRootContainer?(Ha(function(){Yh(null,null,e,!1,function(){e._reactRootContainer=null,e[Gn]=null})}),!0):!1};pr.unstable_batchedUpdates=gb;pr.unstable_renderSubtreeIntoContainer=function(e,t,r,n){if(!Gh(r))throw Error(V(200));if(e==null||e._reactInternals===void 0)throw Error(V(38));return Yh(e,t,r,!1,n)};pr.version="18.3.1-next-f1338f8080-20240426";function uj(){if(!(typeof __REACT_DEVTOOLS_GLOBAL_HOOK__>"u"||typeof __REACT_DEVTOOLS_GLOBAL_HOOK__.checkDCE!="function"))try{__REACT_DEVTOOLS_GLOBAL_HOOK__.checkDCE(u
40j)}catch(e){console.error(e)}}uj(),uP.exports=pr;var _c=uP.exports;const cj=Ce(_c);var dj,N1=_c;dj=N1.createRoot,N1.hydrateRoot;const UD=1,FD=1e6;let zm=0;function zD(){return zm=(zm+1)%Number.MAX_SAFE_INTEGER,zm.toString()}const Wm=new Map,$1=e=>{if(Wm.has(e))return;const t=setTimeout(()=>{Wm.delete(e),Kl({type:"REMOVE_TOAST",toastId:e})},FD);Wm.set(e,t)},WD=(e,t)=>{switch(t.type){case"ADD_TOAST":return{...e,toasts:[t.toast,...e.toasts].slice(0,UD)};case"UPDATE_TOAST":return{...e,toasts:e.toasts.map(r=>r.id===t.toast.id?{...r,...t.toast}:r)};case"DISMISS_TOAST":{const{toastId:r}=t;return r?$1(r):e.toasts.forEach(n=>{$1(n.id)}),{...e,toasts:e.toasts.map(n=>n.id===r||r===void 0?{...n,open:!1}:n)}}case"REMOVE_TOAST":return t.toastId===void 0?{...e,toasts:[]}:{...e,toasts:e.toasts.filter(r=>r.id!==t.toastId)}}},qd=[];let Hd={toasts:[]};function Kl(e){Hd=WD(Hd,e),qd.forEach(t=>{t(Hd)})}function qD({...e}){const t=zD(),r=i=>Kl({type:"UPDATE_TOAST",toast:{...i,id:t}}),n=()=>Kl({type:"DISMISS_TOAST",toastId:t});return Kl({type:"ADD_TOAST",toast:{...e,id:t,open:!0,onOpenChange:i=>{i||n()}}}),{id:t,dismiss:n,update:r}}function Zi(){const[e,t]=O.useState(Hd);return O.useEffect(()=>(qd.push(t),()=>{const r=qd.indexOf(t);r>-1&&qd.splice(r,1)}),[e]),{...e,toast:qD,dismiss:r=>Kl({type:"DISMISS_TOAST",toastId:r})}}function be(e,t,{checkForDefaultPrevented:r=!0}={}){return function(i){if(e==null||e(i),r===!1||!i.defaultPrevented)return t==null?void 0:t(i)}}function R1(e,t){if(typeof e=="function")return e(t);e!=null&&(e.current=t)}function fj(...e){return t=>{let r=!1;const n=e.map(i=>{const a=R1(i,t);return!r&&typeof a=="function"&&(r=!0),a});if(r)return()=>{for(let i=0;i<n.length;i++){const a=n[i];typeof a=="function"?a():R1(e[i],null)}}}}function ft(...e){return O.useCallback(fj(...e),e)}function HD(e,t){const r=O.createContext(t),n=a=>{const{children:o,...s}=a,l=O.useMemo(()=>s,Object.values(s));return p.jsx(r.Provider,{value:l,children:o})};n.displayName=e+"Provider";function i(a){const o=O.useContext(r);if(o)return o;if(t!==void 0)return t;throw new Error(`\`${a}\` must be used within \`${e}\``)}return[n,i]}function ni(e,t=[]){let r=[];function n(a,o){const s=O.createContext(o),l=r.length;r=[...r,o];const u=c=>{var y;const{scope:f,children:h,...v}=c,m=((y=f==null?void 0:f[e])==null?void 0:y[l])||s,g=O.useMemo(()=>v,Object.values(v));return p.jsx(m.Provider,{value:g,children:h})};u.displayName=a+"Provider";function d(c,f){var m;const h=((m=f==null?void 0:f[e])==null?void 0:m[l])||s,v=O.useContext(h);if(v)return v;if(o!==void 0)return o;throw new Error(`\`${c}\` must be used within \`${a}\``)}return[u,d]}const i=()=>{const a=r.map(o=>O.createContext(o));return function(s){const l=(s==null?void 0:s[e])||a;return O.useMemo(()=>({[`__scope${e}`]:{...s,[e]:l}}),[s,l])}};return i.scopeName=e,[n,VD(i,...t)]}function VD(...e){const t=e[0];if(e.length===1)return t;const r=()=>{const n=e.map(i=>({useScope:i(),scopeName:i.scopeName}));return function(a){const o=n.reduce((s,{useScope:l,scopeName:u})=>{const c=l(a)[`__scope${u}`];return{...s,...c}},{});return O.useMemo(()=>({[`__scope${t.scopeName}`]:o}),[o])}};return r.scopeName=t.scopeName,r}function ys(e){const t=GD(e),r=O.forwardRef((n,i)=>{const{children:a,...o}=n,s=O.Children.toArray(a),l=s.find(XD);if(l){const u=l.props.children,d=s.map(c=>c===l?O.Children.count(u)>1?O.Children.only(null):O.isValidElement(u)?u.props.children:null:c);return p.jsx(t,{...o,ref:i,children:O.isValidElement(u)?O.cloneElement(u,void 0,d):null})}return p.jsx(t,{...o,ref:i,children:a})});return r.displayName=`${e}.Slot`,r}var KD=ys("Slot");function GD(e){const t=O.forwardRef((r,n)=>{const{children:i,...a}=r;if(O.isValidElement(i)){const o=JD(i),s=QD(a,i.props);return i.type!==O.Fragment&&(s.ref=n?fj(n,o):o),O.cloneElement(i,s)}return O.Children.count(i)>1?O.Children.only(null):null});return t.displayName=`${e}.SlotClone`,t}var hj=Symbol("radix.slottable");function YD(e){const t=({children:r})=>p.jsx(p.Fragment,{children:r});return t.displayName=`${e}.Slottable`,t.__radixId=hj,t}function XD(e){return O.isValidElement(e)&&typeof e.type=="function"&&"__radixId"in e.type&&e.type.__radixId===hj}function QD(e,t){const r={...t};for(const n in t){const i=e[n],a=t[n];/^on[A-Z]/.test(n)?i&&a?r[n]=(...s)=>{const l=a(...s);return i(...s),l}:i&&(r[n]=i):n==="style"?r[n]={...i,...a}
vendor: 9,308 bytes, line 40
40:n==="className"&&(r[n]=[i,a].filter(Boolean).join(" "))}return{...e,...r}}function JD(e){var n,i;let t=(n=Object.getOwnPropertyDescriptor(e.props,"ref"))==null?void 0:n.get,r=t&&"isReactWarning"in t&&t.isReactWarning;return r?e.ref:(t=(i=Object.getOwnPropertyDescriptor(e,"ref"))==null?void 0:i.get,r=t&&"isReactWarning"in t&&t.isReactWarning,r?e.props.ref:e.props.ref||e.ref)}function pj(e){const t=e+"CollectionProvider",[r,n]=ni(t),[i,a]=r(t,{collectionRef:{current:null},itemMap:new Map}),o=m=>{const{scope:g,children:y}=m,b=j.useRef(null),w=j.useRef(new Map).current;return p.jsx(i,{scope:g,itemMap:w,collectionRef:b,children:y})};o.displayName=t;const s=e+"CollectionSlot",l=ys(s),u=j.forwardRef((m,g)=>{const{scope:y,children:b}=m,w=a(s,y),_=ft(g,w.collectionRef);return p.jsx(l,{ref:_,children:b})});u.displayName=s;const d=e+"CollectionItemSlot",c="data-radix-collection-item",f=ys(d),h=j.forwardRef((m,g)=>{const{scope:y,children:b,...w}=m,_=j.useRef(null),x=ft(g,_),S=a(d,y);return j.useEffect(()=>(S.itemMap.set(_,{ref:_,...w}),()=>void S.itemMap.delete(_))),p.jsx(f,{[c]:"",ref:x,children:b})});h.displayName=d;function v(m){const g=a(e+"CollectionConsumer",m);return j.useCallback(()=>{const b=g.collectionRef.current;if(!b)return[];const w=Array.from(b.querySelectorAll(`[${c}]`));return Array.from(g.itemMap.values()).sort((S,E)=>w.indexOf(S.ref.current)-w.indexOf(E.ref.current))},[g.collectionRef,g.itemMap])}return[{Provider:o,Slot:u,ItemSlot:h},v,n]}var ZD=["a","button","div","form","h2","h3","img","input","label","li","nav","ol","p","select","span","svg","ul"],Oe=ZD.reduce((e,t)=>{const r=ys(`Primitive.${t}`),n=O.forwardRef((i,a)=>{const{asChild:o,...s}=i,l=o?r:t;return typeof window<"u"&&(window[Symbol.for("radix-ui")]=!0),p.jsx(l,{...s,ref:a})});return n.displayName=`Primitive.${t}`,{...e,[t]:n}},{});function mj(e,t){e&&_c.flushSync(()=>e.dispatchEvent(t))}function kn(e){const t=O.useRef(e);return O.useEffect(()=>{t.current=e}),O.useMemo(()=>(...r)=>{var n;return(n=t.current)==null?void 0:n.call(t,...r)},[])}function eL(e,t=globalThis==null?void 0:globalThis.document){const r=kn(e);O.useEffect(()=>{const n=i=>{i.key==="Escape"&&r(i)};return t.addEventListener("keydown",n,{capture:!0}),()=>t.removeEventListener("keydown",n,{capture:!0})},[r,t])}var tL="DismissableLayer",Cg="dismissableLayer.update",rL="dismissableLayer.pointerDownOutside",nL="dismissableLayer.focusOutside",I1,vj=O.createContext({layers:new Set,layersWithOutsidePointerEventsDisabled:new Set,branches:new Set}),Sc=O.forwardRef((e,t)=>{const{disableOutsidePointerEvents:r=!1,onEscapeKeyDown:n,onPointerDownOutside:i,onFocusOutside:a,onInteractOutside:o,onDismiss:s,...l}=e,u=O.useContext(vj),[d,c]=O.useState(null),f=(d==null?void 0:d.ownerDocument)??(globalThis==null?void 0:globalThis.document),[,h]=O.useState({}),v=ft(t,E=>c(E)),m=Array.from(u.layers),[g]=[...u.layersWithOutsidePointerEventsDisabled].slice(-1),y=m.indexOf(g),b=d?m.indexOf(d):-1,w=u.layersWithOutsidePointerEventsDisabled.size>0,_=b>=y,x=aL(E=>{const k=E.target,P=[...u.branches].some(C=>C.contains(k));!_||P||(i==null||i(E),o==null||o(E),E.defaultPrevented||s==null||s())},f),S=oL(E=>{const k=E.target;[...u.branches].some(C=>C.contains(k))||(a==null||a(E),o==null||o(E),E.defaultPrevented||s==null||s())},f);return eL(E=>{b===u.layers.size-1&&(n==null||n(E),!E.defaultPrevented&&s&&(E.preventDefault(),s()))},f),O.useEffect(()=>{if(d)return r&&(u.layersWithOutsidePointerEventsDisabled.size===0&&(I1=f.body.style.pointerEvents,f.body.style.pointerEvents="none"),u.layersWithOutsidePointerEventsDisabled.add(d)),u.layers.add(d),M1(),()=>{r&&u.layersWithOutsidePointerEventsDisabled.size===1&&(f.body.style.pointerEvents=I1)}},[d,f,r,u]),O.useEffect(()=>()=>{d&&(u.layers.delete(d),u.layersWithOutsidePointerEventsDisabled.delete(d),M1())},[d,u]),O.useEffect(()=>{const E=()=>h({});return document.addEventListener(Cg,E),()=>document.removeEventListener(Cg,E)},[]),p.jsx(Oe.div,{...l,ref:v,style:{pointerEvents:w?_?"auto":"none":void 0,...e.style},onFocusCapture:be(e.onFocusCapture,S.onFocusCapture),onBlurCapture:be(e.onBlurCapture,S.onBlurCapture),onPointerDownCapture:be(e.onPointerDownCapture,x.onPointerDownCapture)})});Sc.displayName=tL;var iL="DismissableLayerBranch",gj=O.forwardRef((e,t)=>{const r=O.useContext(vj),n=O.useRef(null),i=ft(t,n);return O.useEffect(()=>{const a=n.current;if(a)return r.branches.add(a),()=>{r.branches.delete(a)}},[r.branches]),p.jsx(Oe.div,{...e,ref:i})});gj.displayName=iL;function aL(e,t=globalThis==null?void 0:globalThis.document){const r=kn(e),n=O.useRef(!1),i=O.useRef(()=>{});return O.useEffect(()=>{const a=s=>{if(s.target&&!n.current){let l=function(){yj(rL,r,u,{discrete:!0})};const u={originalEvent:s};s.pointerType==="touch"?(t.removeEventListener("click",i.current),i.current=l,t.addEventListener("click",i.current,{once:!0})):l()}else t.removeEventListener("click",i.current);n.current=!1},o=window.setTimeout(()=>{t.addEventListener("pointerdown",a)},0);return()=>{window.clearTimeout(o),t.removeEventListener("pointerdown",a),t.removeEventListener("click",i.current)}},[t,r]),{onPointerDownCapture:()=>n.current=!0}}function oL(e,t=globalThis==null?void 0:globalThis.document){const r=kn(e),n=O.useRef(!1);return O.useEffect(()=>{const i=a=>{a.target&&!n.current&&yj(nL,r,{originalEvent:a},{discrete:!1})};return t.addEventListener("focusin",i),()=>t.removeEventListener("focusin",i)},[t,r]),{onFocusCapture:()=>n.current=!0,onBlurCapture:()=>n.current=!1}}function M1(){const e=new CustomEvent(Cg);document.dispatchEvent(e)}function yj(e,t,r,{discrete:n}){const i=r.originalEvent.target,a=new CustomEvent(e,{bubbles:!1,cancelable:!0,detail:r});t&&i.addEventListener(e,t,{once:!0}),n?mj(i,a):i.dispatchEvent(a)}var sL=Sc,lL=gj,Pn=globalThis!=null&&globalThis.document?O.useLayoutEffect:()=>{},uL="Portal",Xh=O.forwardRef((e,t)=>{var s;const{container:r,...n}=e,[i,a]=O.useState(!1);Pn(()=>a(!0),[]);const o=r||i&&((s=globalThis==null?void 0:globalThis.document)==null?void 0:s.body);return o?cj.createPortal(p.jsx(Oe.div,{...n,ref:t}),o):null});Xh.displayName=uL;function cL(e,t){return O.useReducer((r,n)=>t[r][n]??r,e)}var ii=e=>{const{present:t,children:r}=e,n=dL(t),i=typeof r=="function"?r({present:n.isPresent}):O.Children.only(r),a=ft(n.ref,fL(i));return typeof r=="function"||n.isPresent?O.cloneElement(i,{ref:a}):null};ii.displayName="Presence";function dL(e){const[t,r]=O.useState(),n=O.useRef(null),i=O.useRef(e),a=O.useRef("none"),o=e?"mounted":"unmounted",[s,l]=cL(o,{mounted:{UNMOUNT:"unmounted",ANIMATION_OUT:"unmountSuspended"},unmountSuspended:{MOUNT:"mounted",ANIMATION_END:"unmounted"},unmounted:{MOUNT:"mounted"}});return O.useEffect(()=>{const u=rd(n.current);a.current=s==="mounted"?u:"none"},[s]),Pn(()=>{const u=n.current,d=i.current;if(d!==e){const f=a.current,h=rd(u);e?l("MOUNT"):h==="none"||(u==null?void 0:u.display)==="none"?l("UNMOUNT"):l(d&&f!==h?"ANIMATION_OUT":"UNMOUNT"),i.current=e}},[e,l]),Pn(()=>{if(t){let u;const d=t.ownerDocument.defaultView??window,c=h=>{const m=rd(n.current).includes(h.animationName);if(h.target===t&&m&&(l("ANIMATION_END"),!i.current)){const g=t.style.animationFillMode;t.style.animationFillMode="forwards",u=d.setTimeout(()=>{t.style.animationFillMode==="forwards"&&(t.style.animationFillMode=g)})}},f=h=>{h.target===t&&(a.current=rd(n.current))};return t.addEventListener("animationstart",f),t.addEventListener("animationcancel",c),t.addEventListener("animationend",c),()=>{d.clearTimeout(u),t.removeEventListener("animationstart",f),t.removeEventListener("animationcancel",c),t.removeEventListener("animationend",c)}}else l("ANIMATION_END")},[t,l]),{isPresent:["mounted","unmountSuspended"].includes(s),ref:O.useCallback(u=>{n.current=u?getComputedStyle(u):null,r(u)},[])}}function rd(e){return(e==null?void 0:e.animationName)||"none"}function fL(e){var n,i;let t=(n=Object.getOwnPropertyDescriptor(e.props,"ref"))==null?void 0:n.get,r=t&&"isReactWarning"in t&&t.isReactWarning;return r?e.ref:(t=(i=Object.getOwnPropertyDescriptor(e,"ref"))==null?void 0:i.get,r=t&&"isReactWarning"in t&&t.isReactWarning,r?e.props.ref:e.props.ref||e.ref)}var hL=R0[" useInsertionEffect ".trim().toString()]||Pn;function eo({prop:e,defaultProp:t,onChange:r=()=>{},caller:n}){const[i,a,o]=pL({defaultProp:t,onChange:r}),s=e!==void 0,l=s?e:i;{const d=O.useRef(e!==void 0);O.useEffect(()=>{const c=d.current;c!==s&&console.warn(`${n} is changing from ${c?"controlled":"uncontrolled"} to ${s?"controlled":"uncontrolled"}. Components should not switch from controlled to uncontrolled (or vice versa). Decide between using a controlled or uncontrolled value for the lifetime of the component.`),d.current=s},[s,n])}const u=O.useCallback(d=>{var c;if(s){const f=mL(d)?d(e):d;f!==e&&((c=o.current)==null||c.call(o,f))}else a(d)},[s,e,a,o]);return[l,u]}function pL({defaultProp:e,onChange:t}){const[r,n]=O.useState(e),i=O.useRef(r),a=O.useRef(t);return hL(()=>{a.current=t},[t]),O.useEffect(()=>{var o;i.current!==r&&((o=a.current)==null||o.call(a,r),i.current=r)},[r,i]),[r,n,a]}function mL(e){return typeof e=="function"}var vL=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"}),gL="VisuallyHidden",Qh=O.forwardRef((e,t)=>
40p.jsx(Oe.span,{...e,ref:t,style:{...vL,...e.style}}));Qh.displayName=gL;var yL=Qh,Eb="ToastProvider",[kb,bL,wL]=pj("Toast"),[bj,xpe]=ni("Toast",[wL]),[xL,Jh]=bj(Eb),wj=e=>{const{__scopeToast:t,label:r="Notification",duration:n=5e3,swipeDirection:i="right",swipeThreshold:a=50,children:o}=e,[s,l]=O.useState(null),[u,d]=O.useState(0),c=O.useRef(!1),f=O.useRef(!1);return r.trim()||console.error(`Invalid prop \`label\` supplied to \`${Eb}\`. Expected non-empty \`string\`.`),p.jsx(kb.Provider,{scope:t,children:p.jsx(xL,{scope:t,label:r,duration:n,swipeDirection:i,swipeThreshold:a,toastCount:u,viewport:s,onViewportChange:l,onToastAdd:O.useCallback(()=>d(h=>h+1),[]),onToastRemove:O.useCallback(()=>d(h=>h-1),[]),isFocusedToastEscapeKeyDownRef:c,isClosePausedRef:f,children:o})})};wj.displayName=Eb;var xj="ToastViewport",_L=["F8"],Ng="toast.viewportPause",$g="toast.viewportResume",_j=O.forwardRef((e,t)=>{const{__scopeToast:r,hotkey:n=_L,label:i="Notifications ({hotkey})",...a}=e,o=Jh(xj,r),s=bL(r),l=O.useRef(null),u=O.useRef(null),d=O.useRef(null),c=O.useRef(null),f=ft(t,c,o.onViewportChange),h=n.join("+").replace(/Key/g,"").replace(/Digit/g,""),v=o.toastCount>0;O.useEffect(()=>{const g=y=>{var w;n.length!==0&&n.every(_=>y[_]||y.code===_)&&((w=c.current)==null||w.focus())};return document.addEventListener("keydown",g),()=>document.removeEventListener("keydown",g)},[n]),O.useEffect(()=>{const g=l.current,y=c.current;if(v&&g&&y){const b=()=>{if(!o.isClosePausedRef.current){const S=new CustomEvent(Ng);y.dispatchEvent(S),o.isClosePausedRef.current=!0}},w=()=>{if(o.isClosePausedRef.current){const S=new CustomEvent($g);y.dispatchEvent(S),o.isClosePausedRef.current=!1}},_=S=>{!g.contains(S.relatedTarget)&&w()},x=()=>{g.contains(document.activeElement)||w()};return g.addEventListener("focusin",b),g.addEventListener("focusout",_),g.addEventListener("pointermove",b),g.addEventListener("pointerleave",x),window.addEventListener("blur",b),window.addEventListener("focus",w),()=>{g.removeEventListener("focusin",b),g.removeEventListener("focusout",_),g.removeEventListener("pointermove",b),g.removeEventListener("pointerleave",x),window.removeEventListener("blur",b),window.removeEventListener("focus",w)}}},[v,o.isClosePausedRef]);const m=O.useCallback(({tabbingDirection:g})=>{const b=s().map(w=>{const _=w.ref.current,x=[_,...IL(_)];return g==="forwards"?x:x.reverse()});return(g==="forwards"?b.reverse():b).flat()},[s]);return O.useEffect(()=>{const g=c.current;if(g){const y=b=>{var x,S,E;const w=b.altKey||b.ctrlKey||b.metaKey;if(b.key==="Tab"&&!w){const k=document.activeElement,P=b.shiftKey;if(b.target===g&&P){(x=u.current)==null||x.focus();return}const $=m({tabbingDirection:P?"backwards":"forwards"}),D=$.findIndex(I=>I===k);qm($.slice(D+1))?b.preventDefault():P?(S=u.current)==null||S.focus():(E=d.current)==null||E.focus()}};return g.addEventListener("keydown",y),()=>g.removeEventListener("keydown",y)}},[s,m]),p.jsxs(lL,{ref:l,role:"region","aria-label":i.replace("{hotkey}",h),tabIndex:-1,style:{pointerEvents:v?void 0:"none"},children:[v&&p.jsx(Rg,{ref:u,onFocusFromOutsideViewport:()=>{const g=m({tabbingDirection:"forwards"});qm(g)}}),p.jsx(kb.Slot,{scope:r,children:p.jsx(Oe.ol,{tabIndex:-1,...a,ref:f})}),v&&p.jsx(Rg,{ref:d,onFocusFromOutsideViewport:()=>{const g=m({tabbingDirection:"backwards"});qm(g)}})]})});_j.displayName=xj;var Sj="ToastFocusProxy",Rg=O.forwardRef((e,t)=>{const{__scopeToast:r,onFocusFromOutsideViewport:n,...i}=e,a=Jh(Sj,r);return p.jsx(Qh,{"aria-hidden":!0,tabIndex:0,...i,ref:t,style:{position:"fixed"},onFocus:o=>{var u;const s=o.relatedTarget;!((u=a.viewport)!=null&&u.contains(s))&&n()}})});Rg.displayName=Sj;var Oc="Toast",SL="toast.swipeStart",OL="toast.swipeMove",EL="toast.swipeCancel",kL="toast.swipeEnd",Oj=O.forwardRef((e,t)=>{const{forceMount:r,open:n,defaultOpen:i,onOpenChange:a,...o}=e,[s,l]=eo({prop:n,defaultProp:i??!0,onChange:a,caller:Oc});return p.jsx(ii,{present:r||s,children:p.jsx(jL,{open:s,...o,ref:t,onClose:()=>l(!1),onPause:kn(e.onPause),onResume:kn(e.onResume),onSwipeStart:be(e.onSwipeStart,u=>{u.currentTarget.setAttribute("data-swipe","start")}),onSwipeMove:be(e.onSwipeMove,u=>{const{x:d,y:c}=u.detail.delta;u.currentTarget.setAttribute("data-swipe","move"),u.currentTarget.style.setProperty("--radix-toast-swipe-move-x",`${d}px`),u.currentTarget.style.setProperty("--radix-toast-swipe-move-y",`${c}px`)}),onSwipeCancel:be(e.onSwipeCancel,u=>{u.currentTarget.setAttribute("data-swipe","cancel"),u.currentTarget.style.removeProperty("--radix-toast-swipe-move-x"),u.currentTarget.style.removeProperty("--radix-toast-swipe-move-y"),u.currentTarget.style.removeProperty("--radix-toast-swipe-end-x"),u.currentTarget.style.removeProperty("--radix-toast-swipe-end-y")}),onSwipeEnd:be(e.onSwipeEnd,u=>{const{x:d,y:c}=u.detail.delta;u.currentTarget.setAttribute("data-swipe","end"),u.currentTarget.style.removeProperty("--radix-toast-swipe-move-x"),u.currentTarget.style.removeProperty("--radix-toast-swipe-move-y"),u.currentTarget.style.setProperty("--radix-toast-swipe-end-x",`${d}px`),u.currentTarget.style.setProperty("--radix-toast-swipe-end-y",`${c}px`),l(!1)})})})});Oj.displayName=Oc;var[PL,AL]=bj(Oc,{onClose(){}}),jL=O.forwardRef((e,t)=>
40{const{__scopeToast:r,type:n="foreground",duration:i,open:a,onClose:o,onEscapeKeyDown:s,onPause:l,onResume:u,onSwipeStart:d,onSwipeMove:c,onSwipeCancel:f,onSwipeEnd:h,...v}=e,m=Jh(Oc,r),[g,y]=O.useState(null),b=ft(t,I=>y(I)),w=O.useRef(null),_=O.useRef(null),x=i||m.duration,S=O.useRef(0),E=O.useRef(x),k=O.useRef(0),{onToastAdd:P,onToastRemove:C}=m,N=kn(()=>{var R;(g==null?void 0:g.contains(document.activeElement))&&((R=m.viewport)==null||R.focus()),o()}),$=O.useCallback(I=>{!I||I===1/0||(window.clearTimeout(k.current),S.current=new Date().getTime(),k.current=window.setTimeout(N,I))},[N]);O.useEffect(()=>{const I=m.viewport;if(I){const R=()=>{$(E.current),u==null||u()},M=()=>{const L=new Date().getTime()-S.current;E.current=E.current-L,window.clearTimeout(k.current),l==null||l()};return I.addEventListener(Ng,M),I.addEventListener($g,R),()=>{I.removeEventListener(Ng,M),I.removeEventListener($g,R)}}},[m.viewport,x,l,u,$]),O.useEffect(()=>{a&&!m.isClosePausedRef.current&&$(x)},[a,x,m.isClosePausedRef,$]),O.useEffect(()=>(P(),()=>C()),[P,C]);const D=O.useMemo(()=>g?Cj(g):null,[g]);return m.viewport?p.jsxs(p.Fragment,{children:[D&&p.jsx(TL,{__scopeToast:r,role:"status","aria-live":n==="foreground"?"assertive":"polite","aria-atomic":!0,children:D}),p.jsx(PL,{scope:r,onClose:N,children:_c.createPortal(p.jsx(kb.ItemSlot,{scope:r,children:p.jsx(sL,{asChild:!0,onEscapeKeyDown:be(s,()=>{m.isFocusedToastEscapeKeyDownRef.current||N(),m.isFocusedToastEscapeKeyDownRef.current=!1}),children:p.jsx(Oe.li,{role:"status","aria-live":"off","aria-atomic":!0,tabIndex:0,"data-state":a?"open":"closed","data-swipe-direction":m.swipeDirection,...v,ref:b,style:{userSelect:"none",touchAction:"none",...e.style},onKeyDown:be(e.onKeyDown,I=>{I.key==="Escape"&&(s==null||s(I.nativeEvent),I.nativeEvent.defaultPrevented||(m.isFocusedToastEscapeKeyDownRef.current=!0,N()))}),onPointerDown:be(e.onPointerDown,I=>{I.button===0&&(w.current={x:I.clientX,y:I.clientY})}),onPointerMove:be(e.onPointerMove,I=>{if(!w.current)return;const R=I.clientX-w.current.x,M=I.clientY-w.current.y,L=!!_.current,A=["left","right"].includes(m.swipeDirection),T=["left","up"].includes(m.swipeDirection)?Math.min:Math.max,U=A?T(0,R):0,q=A?0:T(0,M),B=I.pointerType==="touch"?10:2,W={x:U,y:q},K={originalEvent:I,delta:W};L?(_.current=W,nd(OL,c,K,{discrete:!1})):D1(W,m.swipeDirection,B)?(_.current=W,nd(SL,d,K,{discrete:!1}),I.target.setPointerCapture(I.pointerId)):(Math.abs(R)>B||Math.abs(M)>B)&&(w.current=null)}),onPointerUp:be(e.onPointerUp,I=>{const R=_.current,M=I.target;if(M.hasPointerCapture(I.pointerId)&&M.releasePointerCapture(I.pointerId),_.current=null,w.current=null,R){const L=I.currentTarget,A={originalEvent:I,delta:R};D1(R,m.swipeDirection,m.swipeThreshold)?nd(kL,h,A,{discrete:!0}):nd(EL,f,A,{discrete:!0}),L.addEventListener("click",T=>T.preventDefault(),{once:!0})}})})})}),m.viewport)})]}):null}),TL=e=>{const{__scopeToast:t,children:r,...n}=e,i=Jh(Oc,t),[a,o]=O.useState(!1),[s,l]=O.useState(!1);return $L(()=>o(!0)),O.useEffect(()=>{const u=window.setTimeout(()=>l(!0),1e3);return()=>window.clearTimeout(u)},[]),s?null:p.jsx(Xh,{asChild:!0,children:p.jsx(Qh,{...n,children:a&&p.jsxs(p.Fragment,{children:[i.label," ",r]})})})},CL="ToastTitle",Ej=O.forwardRef((e,t)=>{const{__scopeToast:r,...n}=e;return p.jsx(Oe.div,{...n,ref:t})});Ej.displayName=CL;var NL="ToastDescription",kj=O.forwardRef((e,t)=>{const{__scopeToast:r,...n}=e;return p.jsx(Oe.div,{...n,ref:t})});kj.displayName=NL;var Pj="ToastAction",Aj=O.forwardRef((e,t)=>{const{altText:r,...n}=e;return r.trim()?p.jsx(Tj,{altText:r,asChild:!0,children:p.jsx(Pb,{...n,ref:t})}):(console.error(`Invalid prop \`altText\` supplied to \`${Pj}\`. Expected non-empty \`string\`.`),null)});Aj.displayName=Pj;var jj="ToastClose",Pb=O.forwardRef((e,t)=>{const{__scopeToast:r,...n}=e,i=AL(jj,r);return p.jsx(Tj,{asChild:!0,children:p.jsx(Oe.button,{type:"button",...n,ref:t,onClick:be(e.onClick,i.onClose)})})});Pb.displayName=jj;var Tj=O.forwardRef((e,t)=>{const{__scopeToast:r,altText:n,...i}=e;return p.jsx(Oe.div,{"data-radix-toast-announce-exclude":"","data-radix-toast-announce-alt":n||void 0,...i,ref:t})});function Cj(e){const t=[];
vendor: 6,214 bytes, lines 40-99
40return Array.from(e.childNodes).forEach(n=>{if(n.nodeType===n.TEXT_NODE&&n.textContent&&t.push(n.textContent),RL(n)){const i=n.ariaHidden||n.hidden||n.style.display==="none",a=n.dataset.radixToastAnnounceExclude==="";if(!i)if(a){const o=n.dataset.radixToastAnnounceAlt;o&&t.push(o)}else t.push(...Cj(n))}}),t}function nd(e,t,r,{discrete:n}){const i=r.originalEvent.currentTarget,a=new CustomEvent(e,{bubbles:!0,cancelable:!0,detail:r});t&&i.addEventListener(e,t,{once:!0}),n?mj(i,a):i.dispatchEvent(a)}var D1=(e,t,r=0)=>{const n=Math.abs(e.x),i=Math.abs(e.y),a=n>i;return t==="left"||t==="right"?a&&n>r:!a&&i>r};function $L(e=()=>{}){const t=kn(e);Pn(()=>{let r=0,n=0;return r=window.requestAnimationFrame(()=>n=window.requestAnimationFrame(t)),()=>{window.cancelAnimationFrame(r),window.cancelAnimationFrame(n)}},[t])}function RL(e){return e.nodeType===e.ELEMENT_NODE}function IL(e){const t=[],r=document.createTreeWalker(e,NodeFilter.SHOW_ELEMENT,{acceptNode:n=>{const i=n.tagName==="INPUT"&&n.type==="hidden";return n.disabled||n.hidden||i?NodeFilter.FILTER_SKIP:n.tabIndex>=0?NodeFilter.FILTER_ACCEPT:NodeFilter.FILTER_SKIP}});for(;r.nextNode();)t.push(r.currentNode);return t}function qm(e){const t=document.activeElement;return e.some(r=>r===t?!0:(r.focus(),document.activeElement!==t))}var ML=wj,Nj=_j,$j=Oj,Rj=Ej,Ij=kj,Mj=Aj,Dj=Pb;function Lj(e){var t,r,n="";if(typeof e=="string"||typeof e=="number")n+=e;else if(typeof e=="object")if(Array.isArray(e)){var i=e.length;for(t=0;t<i;t++)e[t]&&(r=Lj(e[t]))&&(n&&(n+=" "),n+=r)}else for(r in e)e[r]&&(n&&(n+=" "),n+=r);return n}function pe(){for(var e,t,r=0,n="",i=arguments.length;r<i;r++)(e=arguments[r])&&(t=Lj(e))&&(n&&(n+=" "),n+=t);return n}const L1=e=>typeof e=="boolean"?`${e}`:e===0?"0":e,B1=pe,Ab=(e,t)=>r=>{var n;if((t==null?void 0:t.variants)==null)return B1(e,r==null?void 0:r.class,r==null?void 0:r.className);const{variants:i,defaultVariants:a}=t,o=Object.keys(i).map(u=>{const d=r==null?void 0:r[u],c=a==null?void 0:a[u];if(d===null)return null;const f=L1(d)||L1(c);return i[u][f]}),s=r&&Object.entries(r).reduce((u,d)=>{let[c,f]=d;return f===void 0||(u[c]=f),u},{}),l=t==null||(n=t.compoundVariants)===null||n===void 0?void 0:n.reduce((u,d)=>{let{class:c,className:f,...h}=d;return Object.entries(h).every(v=>{let[m,g]=v;return Array.isArray(g)?g.includes({...a,...s}[m]):{...a,...s}[m]===g})?[...u,c,f]:u},[]);return B1(e,o,l,r==null?void 0:r.class,r==null?void 0:r.className)};/** 41 * @license lucide-react v0.462.0 - ISC 42 * 43 * This source code is licensed under the ISC license. 44 * See the LICENSE file in the root directory of this source tree. 45 */const DL=e=>e.replace(/([a-z0-9])([A-Z])/g,"$1-$2").toLowerCase(),Bj=(...e)=>e.filter((t,r,n)=>!!t&&t.trim()!==""&&n.indexOf(t)===r).join(" ").trim();/** 46 * @license lucide-react v0.462.0 - ISC 47 * 48 * This source code is licensed under the ISC license. 49 * See the LICENSE file in the root directory of this source tree. 50 */var LL={xmlns:"http://www.w3.org/2000/svg",width:24,height:24,viewBox:"0 0 24 24",fill:"none",stroke:"currentColor",strokeWidth:2,strokeLinecap:"round",strokeLinejoin:"round"};/** 51 * @license lucide-react v0.462.0 - ISC 52 * 53 * This source code is licensed under the ISC license. 54 * See the LICENSE file in the root directory of this source tree. 55 */const BL=O.forwardRef(({color:e="currentColor",size:t=24,strokeWidth:r=2,absoluteStrokeWidth:n,className:i="",children:a,iconNode:o,...s},l)=>O.createElement("svg",{ref:l,...LL,width:t,height:t,stroke:e,strokeWidth:n?Number(r)*24/Number(t):r,className:Bj("lucide",i),...s},[...o.map(([u,d])=>O.createElement(u,d)),...Array.isArray(a)?a:[a]]));/** 56 * @license lucide-react v0.462.0 - ISC 57 * 58 * This source code is licensed under the ISC license. 59 * See the LICENSE file in the root directory of this source tree. 60 */const ge=(e,t)=>{const r=O.forwardRef(({className:n,...i},a)=>O.createElement(BL,{ref:a,iconNode:t,className:Bj(`lucide-${DL(e)}`,n),...i}));return r.displayName=`${e}`,r};/** 61 * @license lucide-react v0.462.0 - ISC 62 * 63 * This source code is licensed under the ISC license. 64 * See the LICENSE file in the root directory of this source tree. 65 */const UL=ge("ArrowLeft",[["path",{d:"m12 19-7-7 7-7",key:"1l729n"}],["path",{d:"M19 12H5",key:"x3x0zl"}]]);/** 66 * @license lucide-react v0.462.0 - ISC 67 * 68 * This source code is licensed under the ISC license. 69 * See the LICENSE file in the root directory of this source tree. 70 */const FL=ge("ArrowRight",[["path",{d:"M5 12h14",key:"1ays0h"}],["path",{d:"m12 5 7 7-7 7",key:"xquz4c"}]]);/** 71 * @license lucide-react v0.462.0 - ISC 72 * 73 * This source code is licensed under the ISC license. 74 * See the LICENSE file in the root directory of this source tree. 75 */const Vd=ge("ChartColumn",[["path",{d:"M3 3v16a2 2 0 0 0 2 2h16",key:"c24i48"}],["path",{d:"M18 17V9",key:"2bz60n"}],["path",{d:"M13 17V5",key:"1frdt8"}],["path",{d:"M8 17v-3",key:"17ska0"}]]);/** 76 * @license lucide-react v0.462.0 - ISC 77 * 78 * This source code is licensed under the ISC license. 79 * See the LICENSE file in the root directory of this source tree. 80 */const Uj=ge("ChevronDown",[["path",{d:"m6 9 6 6 6-6",key:"qrunsl"}]]);/** 81 * @license lucide-react v0.462.0 - ISC 82 * 83 * This source code is licensed under the ISC license. 84 * See the LICENSE file in the root directory of this source tree. 85 */const Fj=ge("CircleAlert",[["circle",{cx:"12",cy:"12",r:"10",key:"1mglay"}],["line",{x1:"12",x2:"12",y1:"8",y2:"12",key:"1pkeuh"}],["line",{x1:"12",x2:"12.01",y1:"16",y2:"16",key:"4dfq90"}]]);/** 86 * @license lucide-react v0.462.0 - ISC 87 * 88 * This source code is licensed under the ISC license. 89 * See the LICENSE file in the root directory of this source tree. 90 */const jb=ge("CircleCheck",[["circle",{cx:"12",cy:"12",r:"10",key:"1mglay"}],["path",{d:"m9 12 2 2 4-4",key:"dzmm74"}]]);/** 91 * @license lucide-react v0.462.0 - ISC 92 * 93 * This source code is licensed under the ISC license. 94 * See the LICENSE file in the root directory of this source tree. 95 */const zj=ge("Circle",[["circle",{cx:"12",cy:"12",r:"10",key:"1mglay"}]]);/** 96 * @license lucide-react v0.462.0 - ISC 97 * 98 * This source code is licensed under the ISC license. 99 * See the LICENSE file in the root directory of this source tree.
100 */const zL=ge("Compass",[["path",{d:"m16.24 7.76-1.804 5.411a2 2 0 0 1-1.265 1.265L7.76 16.24l1.804-5.411a2 2 0 0 1 1.265-1.265z",key:"9ktpf1"}],["circle",{cx:"12",cy:"12",r:"10",key:"1mglay"}]]);/** 101 * @license lucide-react v0.462.0 - ISC 102 * 103 * This source code is licensed under the ISC license. 104 * See the LICENSE file in the root directory of this source tree. 105 */const Kd=ge("Copy",[["rect",{width:"14",height:"14",x:"8",y:"8",rx:"2",ry:"2",key:"17jyea"}],["path",{d:"M4 16c-1.1 0-2-.9-2-2V4c0-1.1.9-2 2-2h10c1.1 0 2 .9 2 2",key:"zix9uf"}]]);/** 106 * @license lucide-react v0.462.0 - ISC 107 * 108 * This source code is licensed under the ISC license. 109 * See the LICENSE file in the root directory of this source tree. 110 */const WL=ge("Download",[["path",{d:"M21 15v4a2 2 0 0 1-2 2H5a2 2 0 0 1-2-2v-4",key:"ih7n3h"}],["polyline",{points:"7 10 12 15 17 10",key:"2ggqvy"}],["line",{x1:"12",x2:"12",y1:"15",y2:"3",key:"1vk2je"}]]);/** 111 * @license lucide-react v0.462.0 - ISC 112 * 113 * This source code is licensed under the ISC license. 114 * See the LICENSE file in the root directory of this source tree. 115 */const Wj=ge("ExternalLink",[["path",{d:"M15 3h6v6",key:"1q9fwt"}],["path",{d:"M10 14 21 3",key:"gplh6r"}],["path",{d:"M18 13v6a2 2 0 0 1-2 2H5a2 2 0 0 1-2-2V8a2 2 0 0 1 2-2h6",key:"a6xqqp"}]]);/** 116 * @license lucide-react v0.462.0 - ISC 117 * 118 * This source code is licensed under the ISC license. 119 * See the LICENSE file in the root directory of this source tree. 120 */const _f=ge("FileText",[["path",{d:"M15 2H6a2 2 0 0 0-2 2v16a2 2 0 0 0 2 2h12a2 2 0 0 0 2-2V7Z",key:"1rqfz7"}],["path",{d:"M14 2v4a2 2 0 0 0 2 2h4",key:"tnqrlb"}],["path",{d:"M10 9H8",key:"b1mrlr"}],["path",{d:"M16 13H8",key:"t4e002"}],["path",{d:"M16 17H8",key:"z1uh3a"}]]);/** 121 * @license lucide-react v0.462.0 - ISC 122 * 123 * This source code is licensed under the ISC license. 124 * See the LICENSE file in the root directory of this source tree. 125 */const qL=ge("Globe",[["circle",{cx:"12",cy:"12",r:"10",key:"1mglay"}],["path",{d:"M12 2a14.5 14.5 0 0 0 0 20 14.5 14.5 0 0 0 0-20",key:"13o1zl"}],["path",{d:"M2 12h20",key:"9i4pu4"}]]);/** 126 * @license lucide-react v0.462.0 - ISC 127 * 128 * This source code is licensed under the ISC license. 129 * See the LICENSE file in the root directory of this source tree. 130 */const Tb=ge("Leaf",[["path",{d:"M11 20A7 7 0 0 1 9.8 6.1C15.5 5 17 4.48 19 2c1 2 2 4.18 2 8 0 5.5-4.78 10-10 10Z",key:"nnexq3"}],["path",{d:"M2 21c0-3 1.85-5.36 5.08-6C9.5 14.52 12 13 13 12",key:"mt58a7"}]]);/** 131 * @license lucide-react v0.462.0 - ISC 132 * 133 * This source code is licensed under the ISC license. 134 * See the LICENSE file in the root directory of this source tree. 135 */const HL=ge("Lightbulb",[["path",{d:"M15 14c.2-1 .7-1.7 1.5-2.5 1-.9 1.5-2.2 1.5-3.5A6 6 0 0 0 6 8c0 1 .2 2.2 1.5 3.5.7.7 1.3 1.5 1.5 2.5",key:"1gvzjb"}],["path",{d:"M9 18h6",key:"x1upvd"}],["path",{d:"M10 22h4",key:"ceow96"}]]);/** 136 * @license lucide-react v0.462.0 - ISC 137 * 138 * This source code is licensed under the ISC license. 139 * See the LICENSE file in the root directory of this source tree. 140 */const Rt=ge("LoaderCircle",[["path",{d:"M21 12a9 9 0 1 1-6.219-8.56",key:"13zald"}]]);/** 141 * @license lucide-react v0.462.0 - ISC 142 * 143 * This source code is licensed under the ISC license. 144 * See the LICENSE file in the root directory of this source tree. 145 */const VL=ge("Lock",[["rect",{width:"18",height:"11",x:"3",y:"11",rx:"2",ry:"2",key:"1w4ew1"}],["path",{d:"M7 11V7a5 5 0 0 1 10 0v4",key:"fwvmzm"}]]);/** 146 * @license lucide-react v0.462.0 - ISC 147 * 148 * This source code is licensed under the ISC license. 149 * See the LICENSE file in the root directory of this source tree. 150 */const KL=ge("LogOut",[["path",{d:"M9 21H5a2 2 0 0 1-2-2V5a2 2 0 0 1 2-2h4",key:"1uf3rs"}],["polyline",{points:"16 17 21 12 16 7",key:"1gabdz"}],["line",{x1:"21",x2:"9",y1:"12",y2:"12",key:"1uyos4"}]]);/** 151 * @license lucide-react v0.462.0 - ISC 152 * 153 * This source code is licensed under the ISC license. 154 * See the LICENSE file in the root directory of this source tree. 155 */const GL=ge("Moon",[["path",{d:"M12 3a6 6 0 0 0 9 9 9 9 0 1 1-9-9Z",key:"a7tn18"}]]);/** 156 * @license lucide-react v0.462.0 - ISC 157 * 158 * This source code is licensed under the ISC license. 159 * See the LICENSE file in the root directory of this source tree. 160 */const qj=ge("Plus",[["path",{d:"M5 12h14",key:"1ays0h"}],["path",{d:"M12 5v14",key:"s699le"}]]);/** 161 * @license lucide-react v0.462.0 - ISC 162 * 163 * This source code is licensed under the ISC license. 164 * See the LICENSE file in the root directory of this source tree. 165 */const Hj=ge("Share2",[["circle",{cx:"18",cy:"5",r:"3",key:"gq8acd"}],["circle",{cx:"6",cy:"12",r:"3",key:"w7nqdw"}],["circle",{cx:"18",cy:"19",r:"3",key:"1xt0gg"}],["line",{x1:"8.59",x2:"15.42",y1:"13.51",y2:"17.49",key:"47mynk"}],["line",{x1:"15.41",x2:"8.59",y1:"6.51",y2:"10.49",key:"1n3mei"}]]);/** 166 * @license lucide-react v0.462.0 - ISC 167 * 168 * This source code is licensed under the ISC license. 169 * See the LICENSE file in the root directory of this source tree. 170 */const YL=ge("ShieldAlert",[["path",{d:"M20 13c0 5-3.5 7.5-7.66 8.95a1 1 0 0 1-.67-.01C7.5 20.5 4 18 4 13V6a1 1 0 0 1 1-1c2 0 4.5-1.2 6.24-2.72a1.17 1.17 0 0 1 1.52 0C14.51 3.81 17 5 19 5a1 1 0 0 1 1 1z",ke
170y:"oel41y"}],["path",{d:"M12 8v4",key:"1got3b"}],["path",{d:"M12 16h.01",key:"1drbdi"}]]);/** 171 * @license lucide-react v0.462.0 - ISC 172 * 173 * This source code is licensed under the ISC license. 174 * See the LICENSE file in the root directory of this source tree. 175 */const XL=ge("ShieldCheck",[["path",{d:"M20 13c0 5-3.5 7.5-7.66 8.95a1 1 0 0 1-.67-.01C7.5 20.5 4 18 4 13V6a1 1 0 0 1 1-1c2 0 4.5-1.2 6.24-2.72a1.17 1.17 0 0 1 1.52 0C14.51 3.81 17 5 19 5a1 1 0 0 1 1 1z",key:"oel41y"}],["path",{d:"m9 12 2 2 4-4",key:"dzmm74"}]]);/** 176 * @license lucide-react v0.462.0 - ISC 177 * 178 * This source code is licensed under the ISC license. 179 * See the LICENSE file in the root directory of this source tree. 180 */const QL=ge("Sun",[["circle",{cx:"12",cy:"12",r:"4",key:"4exip2"}],["path",{d:"M12 2v2",key:"tus03m"}],["path",{d:"M12 20v2",key:"1lh1kg"}],["path",{d:"m4.93 4.93 1.41 1.41",key:"149t6j"}],["path",{d:"m17.66 17.66 1.41 1.41",key:"ptbguv"}],["path",{d:"M2 12h2",key:"1t8f8n"}],["path",{d:"M20 12h2",key:"1q8mjw"}],["path",{d:"m6.34 17.66-1.41 1.41",key:"1m8zz5"}],["path",{d:"m19.07 4.93-1.41 1.41",key:"1shlcs"}]]);/** 181 * @license lucide-react v0.462.0 - ISC 182 * 183 * This source code is licensed under the ISC license. 184 * See the LICENSE file in the root directory of this source tree. 185 */const JL=ge("Target",[["circle",{cx:"12",cy:"12",r:"10",key:"1mglay"}],["circle",{cx:"12",cy:"12",r:"6",key:"1vlfrh"}],["circle",{cx:"12",cy:"12",r:"2",key:"1c9p78"}]]);/** 186 * @license lucide-react v0.462.0 - ISC 187 * 188 * This source code is licensed under the ISC license. 189 * See the LICENSE file in the root directory of this source tree. 190 */const Ig=ge("Trash2",[["path",{d:"M3 6h18",key:"d0wm0j"}],["path",{d:"M19 6v14c0 1-1 2-2 2H7c-1 0-2-1-2-2V6",key:"4alrt4"}],["path",{d:"M8 6V4c0-1 1-2 2-2h4c1 0 2 1 2 2v2",key:"v07s0e"}],["line",{x1:"10",x2:"10",y1:"11",y2:"17",key:"1uufr5"}],["line",{x1:"14",x2:"14",y1:"11",y2:"17",key:"xtxkd"}]]);/** 191 * @license lucide-react v0.462.0 - ISC 192 * 193 * This source code is licensed under the ISC license. 194 * See the LICENSE file in the root directory of this source tree. 195 */const Cb=ge("TrendingUp",[["polyline",{points:"22 7 13.5 15.5 8.5 10.5 2 17",key:"126l90"}],["polyline",{points:"16 7 22 7 22 13",key:"kwv8wd"}]]);/** 196 * @license lucide-react v0.462.0 - ISC 197 * 198 * This source code is licensed under the ISC license. 199 * See the LICENSE file in the root directory of this source tree. 200 */const Vj=ge("TriangleAlert",[["path",{d:"m21.73 18-8-14a2 2 0 0 0-3.48 0l-8 14A2 2 0 0 0 4 21h16a2 2 0 0 0 1.73-3",key:"wmoenq"}],["path",{d:"M12 9v4",key:"juzpu7"}],["path",{d:"M12 17h.01",key:"p32p05"}]]);/** 201 * @license lucide-react v0.462.0 - ISC 202 * 203 * This source code is licensed under the ISC license. 204 * See the LICENSE file in the root directory of this source tree. 205 */const Kj=ge("Upload",[["path",{d:"M21 15v4a2 2 0 0 1-2 2H5a2 2 0 0 1-2-2v-4",key:"ih7n3h"}],["polyline",{points:"17 8 12 3 7 8",key:"t8dd8p"}],["line",{x1:"12",x2:"12",y1:"3",y2:"15",key:"widbto"}]]);/** 206 * @license lucide-react v0.462.0 - ISC 207 * 208 * This source code is licensed under the ISC license. 209 * See the LICENSE file in the root directory of this source tree. 210 */const ZL=ge("Users",[["path",{d:"M16 21v-2a4 4 0 0 0-4-4H6a4 4 0 0 0-4 4v2",key:"1yyitq"}],["circle",{cx:"9",cy:"7",r:"4",key:"nufk8"}],["path",{d:"M22 21v-2a4 4 0 0 0-3-3.87",key:"kshegd"}],["path",{d:"M16 3.13a4 4 0 0 1 0 7.75",key:"1da9ce"}]]);/** 211 * @license lucide-react v0.462.0 - ISC 212 * 213 * This source code is licensed under the ISC license. 214 * See the LICENSE file in the root directory of this source tree. 215 */const Zh=ge("X",[["path",{d:"M18 6 6 18",key:"1bl5f8"}],["path",{d:"m6 6 12 12",key:"d8bk6v"}]]);/** 216 * @license lucide-react v0.462.0 - ISC 217 * 218 * This source code is licensed under the ISC license. 219 * See the LICENSE file in the root directory of this source tree. 220 */const e4=ge("Zap",[["path",{d:"M4 14a1 1 0 0 1-.78-1.63l9.9-10.2a.5.5 0 0 1 .86.46l-1.92 6.02A1 1 0 0 0 13 10h7a1 1 0 0 1 .78 1.63l-9.9 10.2a.5.5 0 0 1-.86-.46l1.92-6.02A1 1 0 0 0 11 14z",key:"1xq2db"}]]),Nb="-",t4=e=>{const t=n4(e),{conflictingClassGroups:r,conflictingClassGroupModifiers:n}=e;return{getClassGroupId:o=>{const s=o.split(Nb);return s[0]===""&&s.length!==1&&s.shift(),Gj(s,t)||r4(o)},getConflictingClassGroupIds:(o,s)=>
vendor: 11,983 bytes, line 220
220{const l=r[o]||[];return s&&n[o]?[...l,...n[o]]:l}}},Gj=(e,t)=>{var o;if(e.length===0)return t.classGroupId;const r=e[0],n=t.nextPart.get(r),i=n?Gj(e.slice(1),n):void 0;if(i)return i;if(t.validators.length===0)return;const a=e.join(Nb);return(o=t.validators.find(({validator:s})=>s(a)))==null?void 0:o.classGroupId},U1=/^\[(.+)\]$/,r4=e=>{if(U1.test(e)){const t=U1.exec(e)[1],r=t==null?void 0:t.substring(0,t.indexOf(":"));if(r)return"arbitrary.."+r}},n4=e=>{const{theme:t,prefix:r}=e,n={nextPart:new Map,validators:[]};return a4(Object.entries(e.classGroups),r).forEach(([a,o])=>{Mg(o,n,a,t)}),n},Mg=(e,t,r,n)=>{e.forEach(i=>{if(typeof i=="string"){const a=i===""?t:F1(t,i);a.classGroupId=r;return}if(typeof i=="function"){if(i4(i)){Mg(i(n),t,r,n);return}t.validators.push({validator:i,classGroupId:r});return}Object.entries(i).forEach(([a,o])=>{Mg(o,F1(t,a),r,n)})})},F1=(e,t)=>{let r=e;return t.split(Nb).forEach(n=>{r.nextPart.has(n)||r.nextPart.set(n,{nextPart:new Map,validators:[]}),r=r.nextPart.get(n)}),r},i4=e=>e.isThemeGetter,a4=(e,t)=>t?e.map(([r,n])=>{const i=n.map(a=>typeof a=="string"?t+a:typeof a=="object"?Object.fromEntries(Object.entries(a).map(([o,s])=>[t+o,s])):a);return[r,i]}):e,o4=e=>{if(e<1)return{get:()=>{},set:()=>{}};let t=0,r=new Map,n=new Map;const i=(a,o)=>{r.set(a,o),t++,t>e&&(t=0,n=r,r=new Map)};return{get(a){let o=r.get(a);if(o!==void 0)return o;if((o=n.get(a))!==void 0)return i(a,o),o},set(a,o){r.has(a)?r.set(a,o):i(a,o)}}},Yj="!",s4=e=>{const{separator:t,experimentalParseClassName:r}=e,n=t.length===1,i=t[0],a=t.length,o=s=>{const l=[];let u=0,d=0,c;for(let g=0;g<s.length;g++){let y=s[g];if(u===0){if(y===i&&(n||s.slice(g,g+a)===t)){l.push(s.slice(d,g)),d=g+a;continue}if(y==="/"){c=g;continue}}y==="["?u++:y==="]"&&u--}const f=l.length===0?s:s.substring(d),h=f.startsWith(Yj),v=h?f.substring(1):f,m=c&&c>d?c-d:void 0;return{modifiers:l,hasImportantModifier:h,baseClassName:v,maybePostfixModifierPosition:m}};return r?s=>r({className:s,parseClassName:o}):o},l4=e=>{if(e.length<=1)return e;const t=[];let r=[];return e.forEach(n=>{n[0]==="["?(t.push(...r.sort(),n),r=[]):r.push(n)}),t.push(...r.sort()),t},u4=e=>({cache:o4(e.cacheSize),parseClassName:s4(e),...t4(e)}),c4=/\s+/,d4=(e,t)=>{const{parseClassName:r,getClassGroupId:n,getConflictingClassGroupIds:i}=t,a=[],o=e.trim().split(c4);let s="";for(let l=o.length-1;l>=0;l-=1){const u=o[l],{modifiers:d,hasImportantModifier:c,baseClassName:f,maybePostfixModifierPosition:h}=r(u);let v=!!h,m=n(v?f.substring(0,h):f);if(!m){if(!v){s=u+(s.length>0?" "+s:s);continue}if(m=n(f),!m){s=u+(s.length>0?" "+s:s);continue}v=!1}const g=l4(d).join(":"),y=c?g+Yj:g,b=y+m;if(a.includes(b))continue;a.push(b);const w=i(m,v);for(let _=0;_<w.length;++_){const x=w[_];a.push(y+x)}s=u+(s.length>0?" "+s:s)}return s};function f4(){let e=0,t,r,n="";for(;e<arguments.length;)(t=arguments[e++])&&(r=Xj(t))&&(n&&(n+=" "),n+=r);return n}const Xj=e=>{if(typeof e=="string")return e;let t,r="";for(let n=0;n<e.length;n++)e[n]&&(t=Xj(e[n]))&&(r&&(r+=" "),r+=t);return r};function h4(e,...t){let r,n,i,a=o;function o(l){const u=t.reduce((d,c)=>c(d),e());return r=u4(u),n=r.cache.get,i=r.cache.set,a=s,s(l)}function s(l){const u=n(l);if(u)return u;const d=d4(l,r);return i(l,d),d}return function(){return a(f4.apply(null,arguments))}}const Me=e=>{const t=r=>r[e]||[];return t.isThemeGetter=!0,t},Qj=/^\[(?:([a-z-]+):)?(.+)\]$/i,p4=/^\d+\/\d+$/,m4=new Set(["px","full","screen"]),v4=/^(\d+(\.\d+)?)?(xs|sm|md|lg|xl)$/,g4=/\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$/,y4=/^(rgba?|hsla?|hwb|(ok)?(lab|lch))\(.+\)$/,b4=/^(inset_)?-?((\d+)?\.?(\d+)[a-z]+|0)_-?((\d+)?\.?(\d+)[a-z]+|0)/,w4=/^(url|image|image-set|cross-fade|element|(repeating-)?(linear|radial|conic)-gradient)\(.+\)$/,$n=e=>Yo(e)||m4.has(e)||p4.test(e),hi=e=>Ks(e,"length",A4),Yo=e=>!!e&&!Number.isNaN(Number(e)),Hm=e=>Ks(e,"number",Yo),bl=e=>!!e&&Number.isInteger(Number(e)),x4=e=>e.endsWith("%")&&Yo(e.slice(0,-1)),le=e=>Qj.test(e),pi=e=>v4.test(e),_4=new Set(["length","size","percentage"]),S4=e=>Ks(e,_4,Jj),O4=e=>Ks(e,"position",Jj),E4=new Set(["image","url"]),k4=e=>Ks(e,E4,T4),P4=e=>Ks(e,"",j4),wl=()=>!0,Ks=(e,t,r)=>{const n=Qj.exec(e);return n?n[1]?typeof t=="string"?n[1]===t:t.has(n[1]):r(n[2]):!1},A4=e=>g4.test(e)&&!y4.test(e),Jj=()=>!1,j4=e=>b4.test(e),T4=e=>w4.test(e),C4=()=>{const e=Me("colors"),t=Me("spacing"),r=Me("blur"),n=Me("brightness"),i=Me("borderColor"),a=Me("borderRadius"),o=Me("borderSpacing"),s=Me("borderWidth"),l=Me("contrast"),u=Me("grayscale"),d=Me("hueRotate"),c=Me("invert"),f=Me("gap"),h=Me("gradientColorStops"),v=Me("gradientColorStopPositions"),m=Me("inset"),g=Me("margin"),y=Me("opacity"),b=Me("padding"),w=Me("saturate"),_=Me("scale"),x=Me("sepia"),S=Me("skew"),E=Me("space"),k=Me("translate"),P=()=>["auto","contain","none"],C=()=>["auto","hidden","clip","visible","scroll"],N=()=>["auto",le,t],$=()=>[le,t],D=()=>["",$n,hi],I=()=>["auto",Yo,le],R=()=>["bottom","center","left","left-bottom","left-top","right","right-bottom","right-top","top"],M=()=>["solid","dashed","dotted","double","none"],L=()=>["normal","multiply","screen","overlay","darken","lighten","color-dodge","color-burn","hard-light","soft-light","difference","exclusion","hue","saturation","color","luminosity"],A=()=>["start","end","center","between","around","evenly","stretch"],T=()=>["","0",le],U=()=>["auto","avoid","all","avoid-page","page","left","right","column"],q=()=>[Yo,le];return{cacheSize:500,separator:":",theme:{colors:[wl],spacing:[$n,hi],blur:["none","",pi,le],brightness:q(),borderColor:[e],borderRadius:["none","","full",pi,le],borderSpacing:$(),borderWidth:D(),contrast:q(),grayscale:T(),hueRotate:q(),invert:T(),gap:$(),gradientColorStops:[e],gradientColorStopPositions:[x4,hi],inset:N(),margin:N(),opacity:q(),padding:$(),saturate:q(),scale:q(),sepia:T(),skew:q(),space:$(),translate:$()},classGroups:{aspect:[{aspect:["auto","square","video",le]}],container:["container"],columns:[{columns:[pi]}],"break-after":[{"break-after":U()}],"break-before":[{"break-before":U()}],"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:[...R(),le]}],overflow:[{overflow:C()}],"overflow-x":[{"overflow-x":C()}],"overflow-y":[{"overflow-y":C()}],overscroll:[{overscroll:P()}],"overscroll-x":[{"overscroll-x":P()}],"overscroll-y":[{"overscroll-y":P()}],position:["static","fixed","absolute","relative","sticky"],inset:[{inset:[m]}],"inset-x":[{"inset-x":[m]}],"inset-y":[{"inset-y":[m]}],start:[{start:[m]}],end:[{end:[m]}],top:[{top:[m]}],right:[{right:[m]}],bottom:[{bottom:[m]}],left:[{left:[m]}],visibility:["visible","invisible","collapse"],z:[{z:["auto",bl,le]}],basis:[{basis:N()}],"flex-direction":[{flex:["row","row-reverse","col","col-reverse"]}],"flex-wrap":[{flex:["wrap","wrap-reverse","nowrap"]}],flex:[{flex:["1","auto","initial","none",le]}],grow:[{grow:T()}],shrink:[{shrink:T()}],order:[{order:["first","last","none",bl,le]}],"grid-cols":[{"grid-cols":[wl]}],"col-start-end":[{col:["auto",{span:["full",bl,le]},le]}],"col-start":[{"col-start":I()}],"col-end":[{"col-end":I()}],"grid-rows":[{"grid-rows":[wl]}],"row-start-end":[{row:["auto",{span:[bl,le]},le]}],"row-start":[{"row-start":I()}],"row-end":[{"row-end":I()}],"grid-flow":[{"grid-flow":["row","col","dense","row-dense","col-dense"]}],"auto-cols":[{"auto-cols":["auto","min","max","fr",le]}],"auto-rows":[{"auto-rows":["auto","min","max","fr",le]}],gap:[{gap:[f]}],"gap-x":[{"gap-x":[f]}],"gap-y":[{"gap-y":[f]}],"justify-content":[{justify:["normal",...A()]}],"justify-items":[{"justify-items":["start","end","center","stretch"]}],"justify-self":[{"justify-self":["auto","start","end","center","stretch"]}],"align-content":[{content:["normal",...A(),"baseline"]}],"align-items":[{items:["start","end","center","baseline","stretch"]}],"align-self":[{self:["auto","start","end","center","stretch","baseline"]}],"place-content":[{"place-content":[...A(),"baseline"]}],"place-items":[{"place-items":["start","end","center","baseline","stretch"]}],"place-self":[{"place-self":["auto","start","end","center","stretch"]}],p:[{p:[b]}],px:[{px:[b]}],py:[{py:[b]}],ps:[{ps:[b]}],pe:[{pe:[b]}],pt:[{pt:[b]}],pr:[{pr:[b]}],pb:[{pb:[b]}],pl:[{pl:[b]}],m:[{m:[g]}],mx:[{mx:[g]}],my:[{my:[g]}],ms:[{ms:[g]}],me:[{me:[g]}],mt:[{mt:[g]}],mr:[{mr:[g]}],mb:[{mb:[g]}],ml:[{ml:[g]}],"space-x":[{"space-x":[E]}],"space-x-reverse":["space-x-reverse"],"space-y":[{"space-y":[E]}],"space-y-reverse":["space-y-reverse"],w:[{w:["auto","min","max","fit","svw","lvw","dvw",le,t]}],"min-w":[{"min-w":[le,t,"min","max","fit"]}],"max-w":[{"max-w":[le,t,"none","full","min","max","fit","prose",{screen:[pi]},pi]}],h:[{h:[le,t,"auto","min","max","fit","svh","lvh","dvh"]}],"min-h":[{"min-h":[le,t,"min","max","fit","svh","lvh","dvh"]}],"max-h":[{"max-h":[le,t,"min","max","fit","svh","lvh","dvh"]}],size:[{size:[le,t,"auto","min","max","fit"]}],"font-size":[{text:["base",pi,hi]}],"font-smoothing":["antialiased","subpixel-antialiased"],"font-style":["italic","not-italic"],"font-weight":[{font:["thin","extralight","light","normal","medium","semibold","bold","extrabold","black",Hm]}],"font-family":[{font:[wl]}],"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",le]}],"line-clamp":[{"line-clamp":["none",Yo,Hm]}],leading:[{leading:["none","tight","snug","normal","relaxed","loose",$n,le]}],"list-image":[{"list-image":["none",le]}],"list-style-type":[{list:["none","disc","decimal",le]}],"list-style-position":[{list:["inside","outside"]}],"placeholder-color":[{placeholder:[e]}],"placeholder-opacity":[{"placeholder-opacity":[y]}],"text-alignment":[{text:["left","center","right","justify","start","end"]}],"text-color":[{text:[e]}],"text-opacity":[{"text-opacity":[y]}],"text-decoration":["underline","overline","line-through","no-underline"],"text-decoration-style":[{decoration:[...M(),"wavy"]}],"text-decoration-thickness":[{decoration:["auto","from-font",$n,hi]}],"underline-offset":[{"underline-offset":["auto",$n,le]}],"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:$()}],"vertical-align":[{align:["baseline","top","middle","bottom","text-top","text-bottom","sub","super",le]}],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",le]}],"bg-attachment":[{bg:["fixed","local","scroll"]}],"bg-clip":[{"bg-clip":["border","padding","content","text"]}],"bg-opacity":[{"bg-opacity":[y]}],"bg-origin":[{"bg-origin":["border","padding","content"]}],"bg-position":[{bg:[...R(),O4]}],"bg-repeat":[{bg:["no-repeat",{repeat:["","x","y","round","space"]}]}],"bg-size":[{bg:["auto","cover","contain",S4]}],"bg-image":[{bg:["none",{"gradient-to":["t","tr","r","br","b","bl","l","tl"]},k4]}],"bg-color":[{bg:[e]}],"gradient-from-pos":[{from:[v]}
220],"gradient-via-pos":[{via:[v]}],"gradient-to-pos":[{to:[v]}],"gradient-from":[{from:[h]}],"gradient-via":[{via:[h]}],"gradient-to":[{to:[h]}],rounded:[{rounded:[a]}],"rounded-s":[{"rounded-s":[a]}],"rounded-e":[{"rounded-e":[a]}],"rounded-t":[{"rounded-t":[a]}],"rounded-r":[{"rounded-r":[a]}],"rounded-b":[{"rounded-b":[a]}],"rounded-l":[{"rounded-l":[a]}],"rounded-ss":[{"rounded-ss":[a]}],"rounded-se":[{"rounded-se":[a]}],"rounded-ee":[{"rounded-ee":[a]}],"rounded-es":[{"rounded-es":[a]}],"rounded-tl":[{"rounded-tl":[a]}],"rounded-tr":[{"rounded-tr":[a]}],"rounded-br":[{"rounded-br":[a]}],"rounded-bl":[{"rounded-bl":[a]}],"border-w":[{border:[s]}],"border-w-x":[{"border-x":[s]}],"border-w-y":[{"border-y":[s]}],"border-w-s":[{"border-s":[s]}],"border-w-e":[{"border-e":[s]}],"border-w-t":[{"border-t":[s]}],"border-w-r":[{"border-r":[s]}],"border-w-b":[{"border-b":[s]}],"border-w-l":[{"border-l":[s]}],"border-opacity":[{"border-opacity":[y]}],"border-style":[{border:[...M(),"hidden"]}],"divide-x":[{"divide-x":[s]}],"divide-x-reverse":["divide-x-reverse"],"divide-y":[{"divide-y":[s]}],"divide-y-reverse":["divide-y-reverse"],"divide-opacity":[{"divide-opacity":[y]}
vendor: 4,467 bytes, line 220
220],"divide-style":[{divide:M()}],"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:["",...M()]}],"outline-offset":[{"outline-offset":[$n,le]}],"outline-w":[{outline:[$n,hi]}],"outline-color":[{outline:[e]}],"ring-w":[{ring:D()}],"ring-w-inset":["ring-inset"],"ring-color":[{ring:[e]}],"ring-opacity":[{"ring-opacity":[y]}],"ring-offset-w":[{"ring-offset":[$n,hi]}],"ring-offset-color":[{"ring-offset":[e]}],shadow:[{shadow:["","inner","none",pi,P4]}],"shadow-color":[{shadow:[wl]}],opacity:[{opacity:[y]}],"mix-blend":[{"mix-blend":[...L(),"plus-lighter","plus-darker"]}],"bg-blend":[{"bg-blend":L()}],filter:[{filter:["","none"]}],blur:[{blur:[r]}],brightness:[{brightness:[n]}],contrast:[{contrast:[l]}],"drop-shadow":[{"drop-shadow":["","none",pi,le]}],grayscale:[{grayscale:[u]}],"hue-rotate":[{"hue-rotate":[d]}],invert:[{invert:[c]}],saturate:[{saturate:[w]}],sepia:[{sepia:[x]}],"backdrop-filter":[{"backdrop-filter":["","none"]}],"backdrop-blur":[{"backdrop-blur":[r]}],"backdrop-brightness":[{"backdrop-brightness":[n]}],"backdrop-contrast":[{"backdrop-contrast":[l]}],"backdrop-grayscale":[{"backdrop-grayscale":[u]}],"backdrop-hue-rotate":[{"backdrop-hue-rotate":[d]}],"backdrop-invert":[{"backdrop-invert":[c]}],"backdrop-opacity":[{"backdrop-opacity":[y]}],"backdrop-saturate":[{"backdrop-saturate":[w]}],"backdrop-sepia":[{"backdrop-sepia":[x]}],"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",le]}],duration:[{duration:q()}],ease:[{ease:["linear","in","out","in-out",le]}],delay:[{delay:q()}],animate:[{animate:["none","spin","ping","pulse","bounce",le]}],transform:[{transform:["","gpu","none"]}],scale:[{scale:[_]}],"scale-x":[{"scale-x":[_]}],"scale-y":[{"scale-y":[_]}],rotate:[{rotate:[bl,le]}],"translate-x":[{"translate-x":[k]}],"translate-y":[{"translate-y":[k]}],"skew-x":[{"skew-x":[S]}],"skew-y":[{"skew-y":[S]}],"transform-origin":[{origin:["center","top","top-right","right","bottom-right","bottom","bottom-left","left","top-left",le]}],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",le]}],"caret-color":[{caret:[e]}],"pointer-events":[{"pointer-events":["none","auto"]}],resize:[{resize:["none","y","x",""]}],"scroll-behavior":[{scroll:["auto","smooth"]}],"scroll-m":[{"scroll-m":$()}],"scroll-mx":[{"scroll-mx":$()}],"scroll-my":[{"scroll-my":$()}],"scroll-ms":[{"scroll-ms":$()}],"scroll-me":[{"scroll-me":$()}],"scroll-mt":[{"scroll-mt":$()}],"scroll-mr":[{"scroll-mr":$()}],"scroll-mb":[{"scroll-mb":$()}],"scroll-ml":[{"scroll-ml":$()}],"scroll-p":[{"scroll-p":$()}],"scroll-px":[{"scroll-px":$()}],"scroll-py":[{"scroll-py":$()}],"scroll-ps":[{"scroll-ps":$()}],"scroll-pe":[{"scroll-pe":$()}],"scroll-pt":[{"scroll-pt":$()}],"scroll-pr":[{"scroll-pr":$()}],"scroll-pb":[{"scroll-pb":$()}],"scroll-pl":[{"scroll-pl":$()}],"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",le]}],fill:[{fill:[e,"none"]}],"stroke-w":[{stroke:[$n,hi,Hm]}],stroke:[{stroke:[e,"none"]}],sr:["sr-only","not-sr-only"],"forced-color-adjust":[{"forced-color-adjust":["auto","
220none"]}]},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"]}}},N4=h4(C4);function Ne(...e){return N4(pe(e))}const $4=ML,Zj=O.forwardRef(({className:e,...t},r)=>p.jsx(Nj,{ref:r,className:Ne("fixed top-0 z-[100] flex max-h-screen w-full flex-col-reverse p-4 sm:bottom-0 sm:right-0 sm:top-auto sm:flex-col md:max-w-[420px]",e),...t}));Zj.displayName=Nj.displayName;const R4=Ab("group pointer-events-auto relative flex w-full items-center justify-between space-x-4 overflow-hidden rounded-md border p-6 pr-8 shadow-lg transition-all data-[swipe=cancel]:translate-x-0 data-[swipe=end]:translate-x-[var(--radix-toast-swipe-end-x)] data-[swipe=move]:translate-x-[var(--radix-toast-swipe-move-x)] data-[swipe=move]:transition-none data-[state=open]:animate-in data-[state=closed]:animate-out data-[swipe=end]:animate-out data-[state=closed]:fade-out-80 data-[state=closed]:slide-out-to-right-full data-[state=open]:slide-in-from-top-full data-[state=open]:sm:slide-in-from-bottom-full",{variants:{variant:{default:"border bg-background text-foreground",destructive:"destructive group border-destructive bg-destructive text-destructive-foreground"}},defaultVariants:{variant:"default"}}),eT=O.forwardRef(({className:e,variant:t,...r},n)=>p.jsx($j,{ref:n,className:Ne(R4({variant:t}),e),...r}));eT.displayName=$j.displayName;const I4=O.forwardRef(({className:e,...t},r)=>p.jsx(Mj,{ref:r,className:Ne("inline-flex h-8 shrink-0 items-center justify-center rounded-md border bg-transparent px-3 text-sm font-medium ring-offset-background transition-colors group-[.destructive]:border-muted/40 hover:bg-secondary group-[.destructive]:hover:border-destructive/30 group-[.destructive]:hover:bg-destructive group-[.destructive]:hover:text-destructive-foreground focus:outline-none focus:ring-2 focus:ring-ring focus:ring-offset-2 group-[.destructive]:focus:ring-destructive disabled:pointer-events-none disabled:opacity-50",e),...t}));I4.displayName=Mj.displayName;const tT=O.forwardRef(({className:e,...t},r)=>p.jsx(Dj,{ref:r,className:Ne("absolute right-2 top-2 rounded-md p-1 text-foreground
220/50 opacity-0 transition-opacity group-hover:opacity-100 group-[.destructive]:text-red-300 hover:text-foreground group-[.destructive]:hover:text-red-50 focus:opacity-100 focus:outline-none focus:ring-2 group-[.destructive]:focus:ring-red-400 group-[.destructive]:focus:ring-offset-red-600",e),"toast-close":"",...t,children:p.jsx(Zh,{className:"h-4 w-4"})}));tT.displayName=Dj.displayName;const rT=O.forwardRef(({className:e,...t},r)=>p.jsx(Rj,{ref:r,className:Ne("text-sm font-semibold",e),...t}));rT.displayName=Rj.displayName;const nT=O.forwardRef(({className:e,...t},r)=>p.jsx(Ij,{ref:r,className:Ne("text-sm opacity-90",e),...t}));nT.displayName=Ij.displayName;function M4(){const{toasts:e}=Zi();return p.jsxs($4,{children:[e.map(function({id:t,title:r,description:n,action:i,...a}){return p.jsxs(eT,{...a,children:[p.jsxs("div",{className:"grid gap-1",children:[r&&p.jsx(rT,{children:r}),n&&p.jsx(nT,{children:n})]}),i,p.jsx(tT,{})]},t)}),p.jsx(Zj,{})]})}var z1=["light","dark"],D4="(prefers-color-scheme: dark)",L4=O.createContext(void 0),B4={setTheme:e=>{},themes:[]},U4=()=>{var e;return(e=O.useContext(L4))!=null?e:B4};O.memo(({forcedTheme:e,storageKey:t,attribute:r,enableSystem:n,enableColorScheme:i,defaultTheme:a,value:o,attrs:s,nonce:l})=>{let u=a==="system",d=r==="class"?`var d=document.documentElement,c=d.classList;${`c.remove(${s.map(v=>`'${v}'`).join(",")})`};`:`var d=document.documentElement,n='${r}',s='setAttribute';`,c=i?z1.includes(a)&&a?`if(e==='light'||e==='dark'||!e)d.style.colorScheme=e||'${a}'`:"if(e==='light'||e==='dark')d.style.colorScheme=e":"",f=(v,m=!1,g=!0)=>{let y=o?o[v]:v,b=m?v+"|| ''":`'${y}'`,w="";return i&&g&&!m&&z1.includes(v)&&(w+=`d.style.colorScheme = '${v}';`),r==="class"?m||y?w+=`c.add(${b})`:w+="null":y&&(w+=`d[s](n,${b})`),w},h=e?`!function(){${d}${f(e)}}()`:n?`!function(){try{${d}var e=localStorage.getItem('${t}');if('system'===e||(!e&&${u})){var t='${D4}',m=window.matchMedia(t);if(m.media!==t||m.matches){${f("dark")}}else{${f("light")}}}else if(e){${o?`var x=${JSON.stringify(o)};`:""}${f(o?"x[e]":"e",!0)}}${u?"":"else{"+f(a,!1,!1)+"}"}${c}}catch(e){}}()`:`!function(){try{${d}var e=localStorage.getItem('${t}');if(e){${o?`var x=${JSON.stringify(o)};`:""}${f(o?"x[e]":"e",!0)}}else{${f(a,!1,!1)};}${c}}catch(t){}}();`;return O.createElement("script",{nonce:l,dangerouslySetInnerHTML:{__html:h}})});var F4=e=>{switch(e){case"success":return q4;case"info":return V4;case"warning":return H4;case"error":return K4;default:return null}},z4=Array(12).fill(0),W4=({visible:e,className:t})=>j.createElement("div",{className:["sonner-loading-wrapper",t].filter(Boolean).join(" "),"data-visible":e},j.createElement("div",{className:"sonner-spinner"},z4.map((r,n)=>j.createElement("div",{className:"sonner-loading-bar",key:`spinner-bar-${n}`})))),q4=j.createElement("svg",{xmlns:"http://www.w3.org/2000/svg",viewBox:"0 0 20 20",fill:"currentColor",height:"20",width:"20"},j.createElement("path",{fillRule:"evenodd",d:"M10 18a8 8 0 100-16 8 8 0 000 16zm3.857-9.809a.75.75 0 00-1.214-.882l-3.483 4.79-1.88-1.88a.75.75 0 10-1.06 1.061l2.5 2.5a.75.75 0 001.137-.089l4-5.5z",clipRule:"evenodd"})),H4=j.createElement("svg",{xmlns:"http://www.w3.org/2000/svg",viewBox:"0 0 24 24",fill:"currentColor",height:"20",width:"20"},j.createElement("path",{fillRule:"evenodd",d:"M9.401 3.003c1.155-2 4.043-2 5.197 0l7.355 12.748c1.154 2-.29 4.5-2.599 4.5H4.645c-2.309 0-3.752-2.5-2.598-4.5L9.4 3.003zM12 8.25a.75.75 0 01.75.75v3.75a.75.75 0 01-1.5 0V9a.75.75 0 01.75-.75zm0 8.25a.75.75 0 100-1.5.75.75 0 000 1.5z",clipRule:"evenodd"})),V4=j.createElement("svg",{xmlns:"http://www.w3.org/2000/svg",viewBox:"0 0 20 20",fill:"currentColor",height:"20",width:"20"},j.createElement("path",{fillRule:"evenodd",d:"M18 10a8 8 0 11-16 0 8 8 0 0116 0zm-7-4a1 1 0 11-2 0 1 1 0 012 0zM9 9a.75.75 0 000 1.5h.253a.25.25 0 01.244.304l-.459 2.066A1.75 1.75 0 0010.747 15H11a.75.75 0 000-1.5h-.253a.25.25 0 01-.244-.304l.459-2.066A1.75 1.75 0 009.253 9H9z",clipRule:"evenodd"})),K4=j.createElement("svg",{xmlns:"http://www.w3.org/2000/svg",viewBox:"0 0 20 20",fill:"currentColor",height:"20",width:"20"},j.createElement("path",{fillRule:"evenodd",d:"M18 10a8 8 0 11-16 0 8 8 0 0116 0zm-8-5a.75.75 0 01.75.75v4.5a.75.75 0 01-1.5 0v-4.5A.75.75 0 0110 5zm0 10a1 1 0 100-2 1 1 0 000 2z",clipRule:"evenodd"})),G4=j.createElement("svg",{xmlns:"http://www.w3.org/2000/svg",width:"12",height:"12",viewBox:"0 0 24 24",fill:"none",stroke:"currentColor",strokeWidth:"1.5",strokeLinecap:"round",strokeLinejoin:"round"},j.createElement("line",{x1:"18",y1:"6",x2:"6",y2:"18"}),j.createElement("line",{x1:"6",y1:"6",x2:"18",y2:"18"})),Y4=()=>{let[e,t]=j.useState(document.hidden);return j.useEffect(()=>{let r=()=>{t(document.hidden)};return document.addEventListener("visibilitychange",r),()=>window.removeEventListener("visibilitychange",r)},[]),e},Dg=1,X4=class{constructor(){this.subscribe=e=>(this.subscribers.push(e),()=>{let t=this.subscribers.indexOf(e);this.subscribers.splice(t,1)}),this.publish=e=>
vendor: 1,050 bytes, line 220
220{this.subscribers.forEach(t=>t(e))},this.addToast=e=>{this.publish(e),this.toasts=[...this.toasts,e]},this.create=e=>{var t;let{message:r,...n}=e,i=typeof(e==null?void 0:e.id)=="number"||((t=e.id)==null?void 0:t.length)>0?e.id:Dg++,a=this.toasts.find(s=>s.id===i),o=e.dismissible===void 0?!0:e.dismissible;return this.dismissedToasts.has(i)&&this.dismissedToasts.delete(i),a?this.toasts=this.toasts.map(s=>s.id===i?(this.publish({...s,...e,id:i,title:r}),{...s,...e,id:i,dismissible:o,title:r}):s):this.addToast({title:r,...n,dismissible:o,id:i}),i},this.dismiss=e=>(this.dismissedToasts.add(e),e||this.toasts.forEach(t=>{this.subscribers.forEach(r=>r({id:t.id,dismiss:!0}))}),this.subscribers.forEach(t=>t({id:e,dismiss:!0})),e),this.message=(e,t)=>this.create({...t,message:e}),this.error=(e,t)=>this.create({...t,message:e,type:"error"}),this.success=(e,t)=>this.create({...t,type:"success",message:e}),this.info=(e,t)=>this.create({...t,type:"info",message:e}),this.warning=(e,t)=>this.create({...t,type:"warning",message:e}),this.loading=(e,t)=>
220this.create({...t,type:"loading",message:e}),this.promise=(e,t)=>{if(!t)return;let r;t.loading!==void 0&&(r=this.create({...t,promise:e,type:"loading",message:t.loading,description:typeof t.description!="function"?t.description:void 0}));let n=e instanceof Promise?e:e(),i=r!==void 0,a,o=n.then(async l=>{if(a=["resolve",l],j.isValidElement(l))i=!1,this.create({id:r,type:"default",message:l});else if(J4(l)&&!l.ok){i=!1;let u=typeof t.error=="function"?await t.error(`HTTP error! status: ${l.status}`):t.error,d=typeof t.description=="function"?await t.description(`HTTP error! status: ${l.status}`):t.description;this.create({id:r,type:"error",message:u,description:d})}else if(t.success!==void 0){i=!1;let u=typeof t.success=="function"?await t.success(l):t.success,d=typeof t.description=="function"?await t.description(l):t.description;this.create({id:r,type:"success",message:u,description:d})}}).catch(async l=>{if(a=["reject",l],t.error!==void 0){i=!1;let u=typeof t.error=="function"?await t.error(l):t.error,d=typeof t.description=="function"?await t.description(l):t.description;this.create({id:r,type:"error",message:u,description:d})}}).finally(()=>{var l;i&&(this.dismiss(r),r=void 0),(l=t.finally)==null||l.call(t)}),s=()=>new Promise((l,u)=>o.then(()=>a[0]==="reject"?u(a[1]):l(a[1])).catch(u));return typeof r!="string"&&typeof r!="number"?{unwrap:s}:Object.assign(r,{unwrap:s})},this.custom=(e,t)=>{let r=(t==null?void 0:t.id)||Dg++;return this.create({jsx:e(r),id:r,...t}),r},this.getActiveToasts=()=>this.toasts.filter(e=>!this.dismissedToasts.has(e.id)),this.subscribers=[],this.toasts=[],this.dismissedToasts=new Set}},qt=new X4,Q4=(e,t)=>{let r=(t==null?void 0:t.id)||Dg++;return qt.addToast({title:e,...t,id:r}),r},J4=e=>e&&typeof e=="object"&&"ok"in e&&typeof e.ok=="boolean"&&"status"in e&&typeof e.status=="number",Z4=Q4,e3=()=>qt.toasts,t3=()=>qt.getActiveToasts();Object.assign(Z4,{success:qt.success,info:qt.info,warning:qt.warning,error:qt.error,custom:qt.custom,message:qt.message,promise:qt.promise,dismiss:qt.dismiss,loading:qt.loading},{getHistory:e3,getToasts:t3});function r3(e,{insertAt:t}={}){if(typeof document>"u")return;let r=document.head||document.getElementsByTagName("head")[0],n=document.createElement("style");n.type="text/css",t==="top"&&r.firstChild?r.insertBefore(n,r.firstChild):r.appendChild(n),n.styleSheet?n.styleSheet.cssText=e:n.appendChild(document.createTextNode(e))}r3(`:where(html[dir="ltr"]),:where([data-sonner-toaster][dir="ltr"]){--toast-icon-margin-start: -3px;--toast-icon-margin-end: 4px;--toast-svg-margin-start: -1px;--toast-svg-margin-end: 0px;--toast-button-margin-start: auto;--toast-button-margin-end: 0;--toast-close-button-start: 0;--toast-close-button-end: unset;--toast-close-button-transform: translate(-35%, -35%)}:where(html[dir="rtl"]),:where([data-sonner-toaster][dir="rtl"]){--toast-icon-margin-start: 4px;--toast-icon-margin-end: -3px;--toast-svg-margin-start: 0px;--toast-svg-margin-end: -1px;--toast-button-margin-start: 0;--toast-button-margin-end: auto;--toast-close-button-start: unset;--toast-close-button-end: 0;--toast-close-button-transform: translate(35%, -35%)}:where([data-sonner-toaster]){position:fixed;width:var(--width);font-family:ui-sans-serif,system-ui,-apple-system,BlinkMacSystemFont,Segoe UI,Roboto,Helvetica Neue,Arial,Noto Sans,sans-serif,Apple Color Emoji,Segoe UI Emoji,Segoe UI Symbol,Noto Color Emoji;--gray1: hsl(0, 0%, 99%);--gray2: hsl(0, 0%, 97.3%);--gray3: hsl(0, 0%, 95.1%);--gray4: hsl(0, 0%, 93%);--gray5: hsl(0, 0%, 90.9%);--gray6: hsl(0, 0%, 88.7%);--gray7: hsl(0, 0%, 85.8%);--gray8: hsl(0, 0%, 78%);--gray9: hsl(0, 0%, 56.1%);--gray10: hsl(0, 0%, 52.3%);--gray11: hsl(0, 0%, 43.5%);--gray12: hsl(0, 0%, 9%);--border-radius: 8px;box-sizing:border-box;padding:0;margin:0;list-style:none;outline:none;z-index:999999999;transition:transform .4s ease}:where([data-sonner-toaster][data-lifted="true"]){transform:translateY(-10px)}@media (hover: none) and (pointer: coarse){:where([data-sonner-toaster][data-lifted="true"]){transform:none}}:where([data-sonner-toaster][data-x-position="right"]){right:var(--offset-right)}:where([data-sonner-toaster][data-x-position="left"]){left:var(--offset-left)}:where([data-sonner-toaster][data-x-position="center"]){left:50%;transform:translate(-50%)}:where([data-sonner-toaster][data-y-position="top"]){top:var(--offset-top)}:where([data-sonner-toaster][data-y-position="bottom"]){bottom:var(--offset-bottom)}:where([data-sonner-toast]){--y: translateY(100%);--lift-amount: calc(var(--lift) * var(--gap));z-index:var(--z-index);position:absolute;opacity:0;transform:var(--y);filter:blur(0);touch-action:none;transition:transform .4s,opacity .4s,height .4s,box-shadow .2s;box-sizing:border-box;outline:none;overflow-wrap:anywhere}:where([data-sonner-toast][data-styled="true"]){padding:16px;background:var(--normal-bg);border:1px solid var(--normal-border);color:var(--normal-text);border-radius:var(--border-radius);box-shadow:0 4px 12px #0000001a;width:var(--width);font-size:13px;display:flex;align-items:center;gap:6px}:where([data-sonner-toast]:focus-visible){box-shadow:0 4px 12px #0000001a,0 0 0 2px #0003}:where([data-sonner-toast][data-y-position="top"]){top:0;--y: translateY(-100%);--lift: 1;--lift-amount: calc(1 * var(--gap))}:where([data-sonner-toast][data-y-position="bottom"]){bottom:0;--y: translateY(100%);--lift: -1;--lift-amount: calc(var(--lift) * var(--gap))}:where([data-sonner-toast]) :where([data-description]){font-weight:400;line-height:1.4;color:inherit}:where([data-sonner-toast]) :where([data-title]){font-weight:500;line-height:1.5;color:inherit}:where([data-sonner-toast]) :where([data-icon]){display:flex;height:16px;width:16px;position:relative;justify-content:flex-start;align-items:center;flex-shrink:0;margin-left:var(--toast-icon-margin-start);margin-right:var(--toast-icon-margin-end)}:where([data-sonner-toast][data-promise="true"]) :where([data-icon])>svg{opacity:0;transform:scale(.8);transform-origin:center;animation:sonner-fade-in .3s ease forwards}:where([data-sonner-toast]) :where([data-icon])>*{flex-shrink:0}:where([data-sonner-toast]) :where([data-icon]) svg{margin-left:var(--toast-svg-margin-start);margin-right:var(--toast-svg-margin-end)}:where([data-sonner-toast]) :where([data-content]){display:flex;flex-direction:column;gap:2px}[data-sonner-toast][data-styled=true] [data-button]{border-radius:4px;padding-left:8px;padding-right:8px;height:24px;font-size:12px;color:var(--normal-bg);background:var(--normal-text);margin-left:var(--toast-button-margin-start);margin-right:var(--toast-button-margin-end);border:none;cursor:pointer;outline:none;display:flex;align-items:center;flex-shrink:0;transition:opacity .4s,box-shadow .2s}:where([data-sonner-toast]) :where([data-button]):focus-visible{box-shadow:0 0 0 2px #0006}:where([data-sonner-toast]) :where([data-button]):first-of-type{margin-left:var(--toast-button-margin-start);margin-right:var(--toast-button-margin-end)}:where([data-sonner-toast]) :where([data-cancel]){color:var(--normal-text);background:rgba(0,0,0,.08)}:where([data-sonner-toast][data-theme="dark"]) :where([data-cancel]){background:rgba(255,255,255,.3)}:where([data-sonner-toast]) :where([data-close-button]){position:absolute;
220left:var(--toast-close-button-start);right:var(--toast-close-button-end);top:0;height:20px;width:20px;display:flex;justify-content:center;align-items:center;padding:0;color:var(--gray12);border:1px solid var(--gray4);transform:var(--toast-close-button-transform);border-radius:50%;cursor:pointer;z-index:1;transition:opacity .1s,background .2s,border-color .2s}[data-sonner-toast] [data-close-button]{background:var(--gray1)}:where([data-sonner-toast]) :where([data-close-button]):focus-visible{box-shadow:0 4px 12px #0000001a,0 0 0 2px #0003}:where([data-sonner-toast]) :where([data-disabled="true"]){cursor:not-allowed}:where([data-sonner-toast]):hover :where([data-close-button]):hover{background:var(--gray2);border-color:var(--gray5)}:where([data-sonner-toast][data-swiping="true"]):before{content:"";position:absolute;left:-50%;right:-50%;height:100%;z-index:-1}:where([data-sonner-toast][data-y-position="top"][data-swiping="true"]):before{bottom:50%;transform:scaleY(3) translateY(50%)}:where([data-sonner-toast][data-y-position="bottom"][data-swiping="true"]):before{top:50%;transform:scaleY(3) translateY(-50%)}:where([data-sonner-toast][data-swiping="false"][data-removed="true"]):before{content:"";position:absolute;inset:0;transform:scaleY(2)}:where([data-sonner-toast]):after{content:"";position:absolute;left:0;height:calc(var(--gap) + 1px);bottom:100%;width:100%}:where([data-sonner-toast][data-mounted="true"]){--y: translateY(0);opacity:1}:where([data-sonner-toast][data-expanded="false"][data-front="false"]){--scale: var(--toasts-before) * .05 + 1;--y: translateY(calc(var(--lift-amount) * var(--toasts-before))) scale(calc(-1 * var(--scale)));height:var(--front-toast-height)}:where([data-sonner-toast])>*{transition:opacity .4s}:where([data-sonner-toast][data-expanded="false"][data-front="false"][data-styled="true"])>*{opacity:0}
220:where([data-sonner-toast][data-visible="false"]){opacity:0;pointer-events:none}:where([data-sonner-toast][data-mounted="true"][data-expanded="true"]){--y: translateY(calc(var(--lift) * var(--offset)));height:var(--initial-height)}:where([data-sonner-toast][data-removed="true"][data-front="true"][data-swipe-out="false"]){--y: translateY(calc(var(--lift) * -100%));opacity:0}:where([data-sonner-toast][data-removed="true"][data-front="false"][data-swipe-out="false"][data-expanded="true"]){--y: translateY(calc(var(--lift) * var(--offset) + var(--lift) * -100%));opacity:0}:where([data-sonner-toast][data-removed="true"][data-front="false"][data-swipe-out="false"][data-expanded="false"]){--y: translateY(40%);opacity:0;transition:transform .5s,opacity .2s}:where([data-sonner-toast][data-removed="true"][data-front="false"]):before{height:calc(var(--initial-height) + 20%)}[data-sonner-toast][data-swiping=true]{transform:var(--y) translateY(var(--swipe-amount-y, 0px)) translate(var(--swipe-amount-x, 0px));transition:none}[data-sonner-toast][data-swiped=true]{user-select:none}[data-sonner-toast][data-swipe-out=true][data-y-position=bottom],[data-sonner-toast][data-swipe-out=true][data-y-position=top]{animation-duration:.2s;animation-timing-function:ease-out;animation-fill-mode:forwards}[data-sonner-toast][data-swipe-out=true][data-swipe-direction=left]{animation-name:swipe-out-left}[data-sonner-toast][data-swipe-out=true][data-swipe-direction=right]{animation-name:swipe-out-right}[data-sonner-toast][data-swipe-out=true][data-swipe-direction=up]{animation-name:swipe-out-up}[data-sonner-toast][data-swipe-out=true][data-swipe-direction=down]{animation-name:swipe-out-down}@keyframes swipe-out-left{0%{transform:var(--y) translate(var(--swipe-amount-x));opacity:1}to{transform:var(--y) translate(calc(var(--swipe-amount-x) - 100%));opacity:0}}@keyframes swipe-out-right{0%{transform:var(--y) translate(var(--swipe-amount-x));opacity:1}to{transform:var(--y) translate(calc(var(--swipe-amount-x) + 100%));opacity:0}}@keyframes swipe-out-up{0%{transform:var(--y) translateY(var(--swipe-amount-y));opacity:1}to{transform:var(--y) translateY(calc(var(--swipe-amount-y) - 100%));opacity:0}}@keyframes swipe-out-down{0%{transform:var(--y) translateY(var(--swipe-amount-y));opacity:1}to{transform:var(--y) translateY(calc(var(--swipe-amount-y) + 100%));opacity:0}}@media (max-width: 600px){[data-sonner-toaster]{position:fixed;right:var(--mobile-offset-right);left:var(--mobile-offset-left);width:100%}[data-sonner-toaster][dir=rtl]{left:calc(var(--mobile-offset-left) * -1)}[data-sonner-toaster] [data-sonner-toast]{left:0;right:0;width:calc(100% - var(--mobile-offset-left) * 2)}[data-sonner-toaster][data-x-position=left]{left:var(--mobile-offset-left)}[data-sonner-toaster][data-y-position=bottom]{bottom:var(--mobile-offset-bottom)}[data-sonner-toaster][data-y-position=top]{top:var(--mobile-offset-top)}[data-sonner-toaster][data-x-position=center]{left:var(--mobile-offset-left);right:var(--mobile-offset-right);transform:none}}[data-sonner-toaster][data-theme=light]{--normal-bg: #fff;--normal-border: var(--gray4);--normal-text: var(--gray12);--success-bg: hsl(143, 85%, 96%);--success-border: hsl(145, 92%, 91%);--success-text: hsl(140, 100%, 27%);--info-bg: hsl(208, 100%, 97%);--info-border: hsl(221, 91%, 91%);--info-text: hsl(210, 92%, 45%);--warning-bg: hsl(49, 100%, 97%);--warning-border: hsl(49, 91%, 91%);--warning-text: hsl(31, 92%, 45%);--error-bg: hsl(359, 100%, 97%);--error-border: hsl(359, 100%, 94%);--error-text: hsl(360, 100%, 45%)}[data-sonner-toaster][data-theme=light] [data-sonner-toast][data-invert=true]{--normal-bg: #000;--normal-border: hsl(0, 0%, 20%);--normal-text: var(--gray1)}[data-sonner-toaster][data-theme=dark] [data-sonner-toast][data-invert=true]{--normal-bg: #fff;--normal-border: var(--gray3);--normal-text: var(--gray12)}[data-sonner-toaster][data-theme=dark]{--normal-bg: #000;--normal-bg-hover: hsl(0, 0%, 12%);--normal-border: hsl(0, 0%, 20%);--normal-border-hover: hsl(0, 0%, 25%);--normal-text: var(--gray1);--success-bg: hsl(150, 100%, 6%);--success-border: hsl(147, 100%, 12%);--success-text: hsl(150, 86%, 65%);--info-bg: hsl(215, 100%, 6%);--info-border: hsl(223, 100%, 12%);--info-text: hsl(216, 87%, 65%);--warning-bg: hsl(64, 100%, 6%);--warning-border: hsl(60, 100%, 12%);--warning-text: hsl(46, 87%, 65%);--error-bg: hsl(358, 76%, 10%);--error-border: hsl(357, 89%, 16%);
220--error-text: hsl(358, 100%, 81%)}[data-sonner-toaster][data-theme=dark] [data-sonner-toast] [data-close-button]{background:var(--normal-bg);border-color:var(--normal-border);color:var(--normal-text)}[data-sonner-toaster][data-theme=dark] [data-sonner-toast] [data-close-button]:hover{background:var(--normal-bg-hover);border-color:var(--normal-border-hover)}[data-rich-colors=true][data-sonner-toast][data-type=success],[data-rich-colors=true][data-sonner-toast][data-type=success] [data-close-button]{background:var(--success-bg);border-color:var(--success-border);color:var(--success-text)}[data-rich-colors=true][data-sonner-toast][data-type=info],[data-rich-colors=true][data-sonner-toast][data-type=info] [data-close-button]{background:var(--info-bg);border-color:var(--info-border);color:var(--info-text)}[data-rich-colors=true][data-sonner-toast][data-type=warning],[data-rich-colors=true][data-sonner-toast][data-type=warning] [data-close-button]{background:var(--warning-bg);border-color:var(--warning-border);color:var(--warning-text)}[data-rich-colors=true][data-sonner-toast][data-type=error],[data-rich-colors=true][data-sonner-toast][data-type=error] [data-close-button]{background:var(--error-bg);border-color:var(--error-border);color:var(--error-text)}.sonner-loading-wrapper{--size: 16px;height:var(--size);width:var(--size);position:absolute;inset:0;z-index:10}.sonner-loading-wrapper[data-visible=false]{transform-origin:center;animation:sonner-fade-out .2s ease forwards}.sonner-spinner{position:relative;top:50%;left:50%;height:var(--size);width:var(--size)}.sonner-loading-bar{animation:sonner-spin 1.2s linear infinite;background:var(--gray11);border-radius:6px;height:8%;left:-10%;position:absolute;top:-3.9%;width:24%}.sonner-loading-bar:nth-child(1){animation-delay:-1.2s;transform:rotate(.0001deg) translate(146%)}.sonner-loading-bar:nth-child(2){animation-delay:-1.1s;transform:rotate(30deg) translate(146%)}.sonner-loading-bar:nth-child(3){animation-delay:-1s;transform:rotate(60deg) translate(146%)}.sonner-loading-bar:nth-child(4){animation-delay:-.9s;transform:rotate(90deg) translate(146%)}.sonner-loading-bar:nth-child(5){animation-delay:-.8s;transform:rotate(120deg) translate(146%)}.sonner-loading-bar:nth-child(6){animation-delay:-.7s;transform:rotate(150deg) translate(146%)}.sonner-loading-bar:nth-child(7){animation-delay:-.6s;transform:rotate(180deg) translate(146%)}.sonner-loading-bar:nth-child(8){animation-delay:-.5s;transform:rotate(210deg) translate(146%)}.sonner-loading-bar:nth-child(9){animation-delay:-.4s;transform:rotate(240deg) translate(146%)}.sonner-loading-bar:nth-child(10){animation-delay:-.3s;transform:rotate(270deg) translate(146%)}.sonner-loading-bar:nth-child(11){animation-delay:-.2s;transform:rotate(300deg) translate(146%)}.sonner-loading-bar:nth-child(12){animation-delay:-.1s;transform:rotate(330deg) translate(146%)}@keyframes sonner-fade-in{0%{opacity:0;transform:scale(.8)}to{opacity:1;transform:scale(1)}}@keyframes sonner-fade-out{0%{opacity:1;transform:scale(1)}to{opacity:0;transform:scale(.8)}}@keyframes sonner-spin{0%{opacity:1}to{opacity:.15}}@media (prefers-reduced-motion){[data-sonner-toast],[data-sonner-toast]>*,.sonner-loading-bar{transition:none!important;animation:none!important}}.sonner-loader{position:absolute;top:50%;left:50%;transform:translate(-50%,-50%);transform-origin:center;transition:opacity .2s,transform .2s}.sonner-loader[data-visible=false]{opacity:0;transform:scale(.8) translate(-50%,-50%)} 221`);function id(e){return e.label!==void 0}var n3=3,i3="32px",a3="16px",W1=4e3,o3=356,s3=14,l3=20,u3=200;function Dr(...e){return e.filter(Boolean).join(" ")}function c3(e){let[t,r]=e.split("-"),n=[];return t&&n.push(t),r&&n.push(r),n}var d3=e=>{var t,r,n,i,a,o,s,l,u,d,c;let{invert:f,toast:h,unstyled:v,interacting:m,setHeights:g,visibleToasts:y,heights:b,index:w,toasts:_,expanded:x,removeToast:S,defaultRichColors:E,closeButton:k,style:P,cancelButtonStyle:C,actionButtonStyle:N,className:$="",descriptionClassName:D="",duration:I,position:R,gap:M,loadingIcon:L,expandByDefault:A,classNames:T,icons:U,closeButtonAriaLabel:q="Close toast",pauseWhenPageIsHidden:B}=e,[W,K]=j.useState(null),[Z,xe]=j.useState(null),[ue,Ze]=j.useState(!1),[G,ie]=j.useState(!1),[ae,H]=j.useState(!1),[ye,ce]=j.useState(!1),[He,Fe]=j.useState(!1),[pt,Wt]=j.useState(0),[Zt,oa]=j.useState(0),er=j.useRef(h.duration||I||W1),cn=j.useRef(null),Nr=j.useRef(null),Rc=w===0,Ic=w+1<=y,vr=h.type,oo=h.dismissible!==!1,sI=h.className||"",lI=h.descriptionClassName||"",Mc=j.useMemo(()=>b.findIndex(oe=>oe.toastId===h.id)||0,[b,h.id]),uI=j.useMemo(()=>{var oe;return(oe=h.closeButton)!=null?oe:k},[h.closeButton,k]),bx=j.useMemo(()=>h.duration||I||W1,[h.duration,I]),hm=j.useRef(0),so=j.useRef(0),wx=j.useRef(0),lo=j.useRef(null),[cI,dI]=R.split("-"),xx=j.useMemo(()=>b.reduce((oe,Pe,ze)=>ze>=Mc?oe:oe+Pe.height,0),[b,Mc]),_x=Y4(),fI=h.invert||f,pm=vr==="loading";so.current=j.useMemo(()=>Mc*M+xx,[Mc,xx]),j.useEffect(()=>{er.current=bx},[bx]),j.useEffect(()=>{Ze(!0)},[]),j.useEffect(()=>{let oe=Nr.current;if(oe){let Pe=oe.getBoundingClientRect().height;return oa(Pe),g(ze=>[{toastId:h.id,height:Pe,position:h.position},...ze]),()=>g(ze=>ze.filter($r=>$r.toastId!==h.id))}},[g,h.id]),j.useLayoutEffect(()=>{if(!ue)return;let oe=Nr.current,Pe=oe.style.height;oe.style.height="auto";let ze=oe.getBoundingClientRect().height;oe.style.height=Pe,oa(ze),g($r=>$r.find(Rr=>Rr.toastId===h.id)?$r.map(Rr=>Rr.toastId===h.id?{...Rr,height:ze}:Rr):[{toastId:h.id,height:ze,position:h.position},...$r])},[ue,h.title,h.description,g,h.id]);let ui=j.useCallback(()=>{ie(!0),Wt(so.current),g(oe=>oe.filter(Pe=>Pe.toastId!==h.id)),setTimeout(()=>{S(h)},u3)},[h,S,g,so]);j.useEffect(()=>{if(h.promise&&vr==="loading"||h.duration===1/0||h.type==="loading")return;let oe;return x||m||B&&_x?(()=>{if(wx.current<hm.current){let Pe=new Date().getTime()-hm.current;er.current=er.current-Pe}
221wx.current=new Date().getTime()})():er.current!==1/0&&(hm.current=new Date().getTime(),oe=setTimeout(()=>{var Pe;(Pe=h.onAutoClose)==null||Pe.call(h,h),ui()},er.current)),()=>clearTimeout(oe)},[x,m,h,vr,B,_x,ui]),j.useEffect(()=>{h.delete&&ui()},[ui,h.delete]);function hI(){var oe,Pe,ze;return U!=null&&U.loading?j.createElement("div",{className:Dr(T==null?void 0:T.loader,(oe=h==null?void 0:h.classNames)==null?void 0:oe.loader,"sonner-loader"),"data-visible":vr==="loading"},U.loading):L?j.createElement("div",{className:Dr(T==null?void 0:T.loader,(Pe=h==null?void 0:h.classNames)==null?void 0:Pe.loader,"sonner-loader"),"data-visible":vr==="loading"},L):j.createElement(W4,{className:Dr(T==null?void 0:T.loader,(ze=h==null?void 0:h.classNames)==null?void 0:ze.loader),visible:vr==="loading"})}return j.createElement("li",{tabIndex:0,ref:Nr,className:Dr($,sI,T==null?void 0:T.toast,(t=h==null?void 0:h.classNames)==null?void 0:t.toast,T==null?void 0:T.default,T==null?void 0:T[vr],(r=h==null?void 0:h.classNames)==null?void 0:r[vr]),"data-sonner-toast":"","data-rich-colors":(n=h.richColors)!=null?n:E,"data-styled":!(h.jsx||h.unstyled||v),"data-mounted":ue,"data-promise":!!h.promise,"data-swiped":He,"data-removed":G,"data-visible":Ic,"data-y-position":cI,"data-x-position":dI,"data-index":w,"data-front":Rc,"data-swiping":ae,"data-dismissible":oo,"data-type":vr,"data-invert":fI,"data-swipe-out":ye,"data-swipe-direction":Z,"data-expanded":!!(x||A&&ue),style:{"--index":w,"--toasts-before":w,"--z-index":_.length-w,"--offset":`${G?pt:so.current}px`,"--initial-height":A?"auto":`${Zt}px`,...P,...h.style},onDragEnd:()=>{H(!1),K(null),lo.current=null},onPointerDown:oe=>{pm||!oo||(cn.current=new Date,Wt(so.current),oe.target.setPointerCapture(oe.pointerId),oe.target.tagName!=="BUTTON"&&(H(!0),lo.current={x:oe.clientX,y:oe.clientY}))},onPointerUp:()=>{var oe,Pe,ze,$r;if(ye||!oo)return;lo.current=null;let Rr=Number(((oe=Nr.current)==null?void 0:oe.style.getPropertyValue("--swipe-amount-x").replace("px",""))||0),ci=Number(((Pe=Nr.current)==null?void 0:Pe.style.getPropertyValue("--swipe-amount-y").replace("px",""))||0),sa=new Date().getTime()-((ze=cn.current)==null?void 0:ze.getTime()),Ir=W==="x"?Rr:ci,di=Math.abs(Ir)/sa;if(Math.abs(Ir)>=l3||di>.11){Wt(so.current),($r=h.onDismiss)==null||$r.call(h,h),xe(W==="x"?Rr>0?"right":"left":ci>0?"down":"up"),ui(),ce(!0),Fe(!1);return}H(!1),K(null)},onPointerMove:oe=>{var Pe,ze,$r,Rr;if(!lo.current||!oo||((Pe=window.getSelection())==null?void 0:Pe.toString().length)>0)return;let ci=oe.clientY-lo.current.y,sa=oe.clientX-lo.current.x,Ir=(ze=e.swipeDirections)!=null?ze:c3(R);!W&&(Math.abs(sa)>1||Math.abs(ci)>1)&&K(Math.abs(sa)>Math.abs(ci)?"x":"y");let di={x:0,y:0};W==="y"?(Ir.includes("top")||Ir.includes("bottom"))&&(Ir.includes("top")&&ci<0||Ir.includes("bottom")&&ci>0)&&(di.y=ci):W==="x"&&(Ir.includes("left")||Ir.includes("right"))&&(Ir.includes("left")&&sa<0||Ir.includes("right")&&sa>0)&&(di.x=sa),(Math.abs(di.x)>0||Math.abs(di.y)>0)&&Fe(!0),($r=Nr.current)==null||$r.style.setProperty("--swipe-amount-x",`${di.x}px`),(Rr=Nr.current)==null||Rr.style.setProperty("--swipe-amount-y",`${di.y}px`)}},uI&&!h.jsx?j.createElement("button",{"aria-label":q,"data-disabled":pm,"data-close-button":!0,onClick:pm||!oo?()=>{}:()=>{var oe;ui(),(oe=h.onDismiss)==null||oe.call(h,h)},className:Dr(T==null?void 0:T.closeButton,(i=h==null?void 0:h.classNames)==null?void 0:i.closeButton)},(a=U==null?void 0:U.close)!=null?a:G4):null,h.jsx||O.isValidElement(h.title)?h.jsx?h.jsx:typeof h.title=="function"?h.title():h.title:j.createElement(j.Fragment,null,vr||h.icon||h.promise?j.createElement("div",{"data-icon":"",className:Dr(T==null?void 0:T.icon,(o=h==null?void 0:h.classNames)==null?void 0:o.icon)},h.promise||h.type==="loading"&&!h.icon?h.icon||hI():null,h.type!=="loading"?h.icon||(U==null?void 0:U[vr])||F4(vr):null):null,j.createElement("div",{"data-content":"",className:Dr(T==null?void 0:T.content,(s=h==null?void 0:h.classNames)==null?void 0:s.content)},j.createElement("div",{"data-title":"",className:Dr(T==null?void 0:T.title,(l=h==null?void 0:h.classNames)==null?void 0:l.title)},typeof h.title=="function"?h.title():h.title),h.description?j.createElement("div",{"data-description":"",className:Dr(D,lI,T==null?void 0:T.description,(u=h==null?void 0:h.classNames)==null?void 0:u.description)},typeof h.description=="function"?h.description():h.description):null),O.isValidElement(h.cancel)?h.cancel:h.cancel&&id(h.cancel)?j.createElement("button",{"data-button":!0,"data-cancel":!0,style:h.cancelButtonStyle||C,onClick:oe=>{var Pe,ze;id(h.cancel)&&oo&&((ze=(Pe=h.cancel).onClick)==null||ze.call(Pe,oe),ui())},className:Dr(T==null?void 0:T.cancelButton,(d=h==null?void 0:h.classNames)==null?void 0:d.cancelButton)},h.cancel.label):null,O.isValidElement(h.action)?h.action:h.action&&id(h.action)?j.createElement("button",{"data-button":!0,"data-action":!0,style:h.actionButtonStyle||N,onClick:oe=>{var Pe,ze;id(h.action)&&((ze=(Pe=h.action).onClick)==null||ze.call(Pe,oe),
vendor: 5,541 bytes, line 221
221!oe.defaultPrevented&&ui())},className:Dr(T==null?void 0:T.actionButton,(c=h==null?void 0:h.classNames)==null?void 0:c.actionButton)},h.action.label):null))};function q1(){if(typeof window>"u"||typeof document>"u")return"ltr";let e=document.documentElement.getAttribute("dir");return e==="auto"||!e?window.getComputedStyle(document.documentElement).direction:e}function f3(e,t){let r={};return[e,t].forEach((n,i)=>{let a=i===1,o=a?"--mobile-offset":"--offset",s=a?a3:i3;function l(u){["top","right","bottom","left"].forEach(d=>{r[`${o}-${d}`]=typeof u=="number"?`${u}px`:u})}typeof n=="number"||typeof n=="string"?l(n):typeof n=="object"?["top","right","bottom","left"].forEach(u=>{n[u]===void 0?r[`${o}-${u}`]=s:r[`${o}-${u}`]=typeof n[u]=="number"?`${n[u]}px`:n[u]}):l(s)}),r}var h3=O.forwardRef(function(e,t){let{invert:r,position:n="bottom-right",hotkey:i=["altKey","KeyT"],expand:a,closeButton:o,className:s,offset:l,mobileOffset:u,theme:d="light",richColors:c,duration:f,style:h,visibleToasts:v=n3,toastOptions:m,dir:g=q1(),gap:y=s3,loadingIcon:b,icons:w,containerAriaLabel:_="Notifications",pauseWhenPageIsHidden:x}=e,[S,E]=j.useState([]),k=j.useMemo(()=>Array.from(new Set([n].concat(S.filter(B=>B.position).map(B=>B.position)))),[S,n]),[P,C]=j.useState([]),[N,$]=j.useState(!1),[D,I]=j.useState(!1),[R,M]=j.useState(d!=="system"?d:typeof window<"u"&&window.matchMedia&&window.matchMedia("(prefers-color-scheme: dark)").matches?"dark":"light"),L=j.useRef(null),A=i.join("+").replace(/Key/g,"").replace(/Digit/g,""),T=j.useRef(null),U=j.useRef(!1),q=j.useCallback(B=>{E(W=>{var K;return(K=W.find(Z=>Z.id===B.id))!=null&&K.delete||qt.dismiss(B.id),W.filter(({id:Z})=>Z!==B.id)})},[]);return j.useEffect(()=>qt.subscribe(B=>{if(B.dismiss){E(W=>W.map(K=>K.id===B.id?{...K,delete:!0}:K));return}setTimeout(()=>{cj.flushSync(()=>{E(W=>{let K=W.findIndex(Z=>Z.id===B.id);return K!==-1?[...W.slice(0,K),{...W[K],...B},...W.slice(K+1)]:[B,...W]})})})}),[]),j.useEffect(()=>{if(d!=="system"){M(d);return}if(d==="system"&&(window.matchMedia&&window.matchMedia("(prefers-color-scheme: dark)").matches?M("dark"):M("light")),typeof window>"u")return;let B=window.matchMedia("(prefers-color-scheme: dark)");try{B.addEventListener("change",({matches:W})=>{M(W?"dark":"light")})}catch{B.addListener(({matches:K})=>{try{M(K?"dark":"light")}catch(Z){console.error(Z)}})}},[d]),j.useEffect(()=>{S.length<=1&&$(!1)},[S]),j.useEffect(()=>{let B=W=>{var K,Z;i.every(xe=>W[xe]||W.code===xe)&&($(!0),(K=L.current)==null||K.focus()),W.code==="Escape"&&(document.activeElement===L.current||(Z=L.current)!=null&&Z.contains(document.activeElement))&&$(!1)};return document.addEventListener("keydown",B),()=>document.removeEventListener("keydown",B)},[i]),j.useEffect(()=>{if(L.current)return()=>{T.current&&(T.current.focus({preventScroll:!0}),T.current=null,U.current=!1)}},[L.current]),j.createElement("section",{ref:t,"aria-label":`${_} ${A}`,tabIndex:-1,"aria-live":"polite","aria-relevant":"additions text","aria-atomic":"false",suppressHydrationWarning:!0},k.map((B,W)=>{var K;let[Z,xe]=B.split("-");return S.length?j.createElement("ol",{key:B,dir:g==="auto"?q1():g,tabIndex:-1,ref:L,className:s,"data-sonner-toaster":!0,"data-theme":R,"data-y-position":Z,"data-lifted":N&&S.length>1&&!a,"data-x-position":xe,style:{"--front-toast-height":`${((K=P[0])==null?void 0:K.height)||0}px`,"--width":`${o3}px`,"--gap":`${y}px`,...h,...f3(l,u)},onBlur:ue=>{U.current&&!ue.currentTarget.contains(ue.relatedTarget)&&(U.current=!1,T.current&&(T.current.focus({preventScroll:!0}),T.current=null))},onFocus:ue=>{ue.target instanceof HTMLElement&&ue.target.dataset.dismissible==="false"||U.current||(U.current=!0,T.current=ue.relatedTarget)},onMouseEnter:()=>$(!0),onMouseMove:()=>$(!0),onMouseLeave:()=>{D||$(!1)},onDragEnd:()=>$(!1),onPointerDown:ue=>{ue.target instanceof HTMLElement&&ue.target.dataset.dismissible==="false"||I(!0)},onPointerUp:()=>I(!1)},S.filter(ue=>!ue.position&&W===0||ue.position===B).map((ue,Ze)=>{var G,ie;return j.createElement(d3,{key:ue.id,icons:w,index:Ze,toast:ue,defaultRichColors:c,duration:(G=m==null?void 0:m.duration)!=null?G:f,className:m==null?void 0:m.className,descriptionClassName:m==null?void 0:m.descriptionClassName,invert:r,visibleToasts:v,closeButton:(ie=m==null?void 0:m.closeButton)!=null?ie:o,interacting:D,position:B,style:m==null?void 0:m.style,unstyled:m==null?void 0:m.unstyled,classNames:m==null?void 0:m.classNames,cancelButtonStyle:m==null?void 0:m.cancelButtonStyle,actionButtonStyle:m==null?void 0:m.actionButtonStyle,removeToast:q,toasts:S.filter(ae=>ae.position==ue.position),heights:P.filter(ae=>ae.position==ue.position),setHeights:C,expandByDefault:a,gap:y,loadingIcon:b,expanded:N,pauseWhenPageIsHidden:x,swipeDirections:e.swipeDirections})})):null}))});const p3=({...e})=>{const{theme:t="system"}=U4();return p.jsx(h3,{theme:t,className:"toaster group",toastOptions:{classNames:{toast:"group toast group-[.toaster]:bg-background group-[.toaster]:text-foreground group-[.toaster]:border-border group-[.toaster]:shadow-lg",description:"group-[.toast]:text-muted-foreground",actionButton:"group-[.toast]:bg-primary group-[.toast]:text-primary-foreground",cancelButton:"group-[.toast]:bg-muted group-[.toast]:text-muted-foreground"}},...e})};var m3=R0[" useId ".trim().toString()]||(()=>{}),v3=0;function Ia(e){const[t,r]=O.useState(m3());return Pn(()=>{r(n=>n??String(v3++))},[e]),t?`radix-${t}`:""}const g3=["top","right","bottom","left"],Vi=Math.min,ar=Math.max,Sf=Math.round,ad=Math.floor,Sn=e=>({x:e,y:e}
vendor: 11,921 bytes, line 221
221),y3={left:"right",right:"left",bottom:"top",top:"bottom"},b3={start:"end",end:"start"};function Lg(e,t,r){return ar(e,Vi(t,r))}function Qn(e,t){return typeof e=="function"?e(t):e}function Jn(e){return e.split("-")[0]}function Gs(e){return e.split("-")[1]}function $b(e){return e==="x"?"y":"x"}function Rb(e){return e==="y"?"height":"width"}const w3=new Set(["top","bottom"]);function bn(e){return w3.has(Jn(e))?"y":"x"}function Ib(e){return $b(bn(e))}function x3(e,t,r){r===void 0&&(r=!1);const n=Gs(e),i=Ib(e),a=Rb(i);let o=i==="x"?n===(r?"end":"start")?"right":"left":n==="start"?"bottom":"top";return t.reference[a]>t.floating[a]&&(o=Of(o)),[o,Of(o)]}function _3(e){const t=Of(e);return[Bg(e),t,Bg(t)]}function Bg(e){return e.replace(/start|end/g,t=>b3[t])}const H1=["left","right"],V1=["right","left"],S3=["top","bottom"],O3=["bottom","top"];function E3(e,t,r){switch(e){case"top":case"bottom":return r?t?V1:H1:t?H1:V1;case"left":case"right":return t?S3:O3;default:return[]}}function k3(e,t,r,n){const i=Gs(e);let a=E3(Jn(e),r==="start",n);return i&&(a=a.map(o=>o+"-"+i),t&&(a=a.concat(a.map(Bg)))),a}function Of(e){return e.replace(/left|right|bottom|top/g,t=>y3[t])}function P3(e){return{top:0,right:0,bottom:0,left:0,...e}}function iT(e){return typeof e!="number"?P3(e):{top:e,right:e,bottom:e,left:e}}function Ef(e){const{x:t,y:r,width:n,height:i}=e;return{width:n,height:i,top:r,left:t,right:t+n,bottom:r+i,x:t,y:r}}function K1(e,t,r){let{reference:n,floating:i}=e;const a=bn(t),o=Ib(t),s=Rb(o),l=Jn(t),u=a==="y",d=n.x+n.width/2-i.width/2,c=n.y+n.height/2-i.height/2,f=n[s]/2-i[s]/2;let h;switch(l){case"top":h={x:d,y:n.y-i.height};break;case"bottom":h={x:d,y:n.y+n.height};break;case"right":h={x:n.x+n.width,y:c};break;case"left":h={x:n.x-i.width,y:c};break;default:h={x:n.x,y:n.y}}switch(Gs(t)){case"start":h[o]-=f*(r&&u?-1:1);break;case"end":h[o]+=f*(r&&u?-1:1);break}return h}const A3=async(e,t,r)=>{const{placement:n="bottom",strategy:i="absolute",middleware:a=[],platform:o}=r,s=a.filter(Boolean),l=await(o.isRTL==null?void 0:o.isRTL(t));let u=await o.getElementRects({reference:e,floating:t,strategy:i}),{x:d,y:c}=K1(u,n,l),f=n,h={},v=0;for(let m=0;m<s.length;m++){const{name:g,fn:y}=s[m],{x:b,y:w,data:_,reset:x}=await y({x:d,y:c,initialPlacement:n,placement:f,strategy:i,middlewareData:h,rects:u,platform:o,elements:{reference:e,floating:t}});d=b??d,c=w??c,h={...h,[g]:{...h[g],..._}},x&&v<=50&&(v++,typeof x=="object"&&(x.placement&&(f=x.placement),x.rects&&(u=x.rects===!0?await o.getElementRects({reference:e,floating:t,strategy:i}):x.rects),{x:d,y:c}=K1(u,f,l)),m=-1)}return{x:d,y:c,placement:f,strategy:i,middlewareData:h}};async function yu(e,t){var r;t===void 0&&(t={});const{x:n,y:i,platform:a,rects:o,elements:s,strategy:l}=e,{boundary:u="clippingAncestors",rootBoundary:d="viewport",elementContext:c="floating",altBoundary:f=!1,padding:h=0}=Qn(t,e),v=iT(h),g=s[f?c==="floating"?"reference":"floating":c],y=Ef(await a.getClippingRect({element:(r=await(a.isElement==null?void 0:a.isElement(g)))==null||r?g:g.contextElement||await(a.getDocumentElement==null?void 0:a.getDocumentElement(s.floating)),boundary:u,rootBoundary:d,strategy:l})),b=c==="floating"?{x:n,y:i,width:o.floating.width,height:o.floating.height}:o.reference,w=await(a.getOffsetParent==null?void 0:a.getOffsetParent(s.floating)),_=await(a.isElement==null?void 0:a.isElement(w))?await(a.getScale==null?void 0:a.getScale(w))||{x:1,y:1}:{x:1,y:1},x=Ef(a.convertOffsetParentRelativeRectToViewportRelativeRect?await a.convertOffsetParentRelativeRectToViewportRelativeRect({elements:s,rect:b,offsetParent:w,strategy:l}):b);return{top:(y.top-x.top+v.top)/_.y,bottom:(x.bottom-y.bottom+v.bottom)/_.y,left:(y.left-x.left+v.left)/_.x,right:(x.right-y.right+v.right)/_.x}}const j3=e=>({name:"arrow",options:e,async fn(t){const{x:r,y:n,placement:i,rects:a,platform:o,elements:s,middlewareData:l}=t,{element:u,padding:d=0}=Qn(e,t)||{};if(u==null)return{};const c=iT(d),f={x:r,y:n},h=Ib(i),v=Rb(h),m=await o.getDimensions(u),g=h==="y",y=g?"top":"left",b=g?"bottom":"right",w=g?"clientHeight":"clientWidth",_=a.reference[v]+a.reference[h]-f[h]-a.floating[v],x=f[h]-a.reference[h],S=await(o.getOffsetParent==null?void 0:o.getOffsetParent(u));let E=S?S[w]:0;(!E||!await(o.isElement==null?void 0:o.isElement(S)))&&(E=s.floating[w]||a.floating[v]);const k=_/2-x/2,P=E/2-m[v]/2-1,C=Vi(c[y],P),N=Vi(c[b],P),$=C,D=E-m[v]-N,I=E/2-m[v]/2+k,R=Lg($,I,D),M=!l.arrow&&Gs(i)!=null&&I!==R&&a.reference[v]/2-(I<$?C:N)-m[v]/2<0,L=M?I<$?I-$:I-D:0;return{[h]:f[h]+L,data:{[h]:R,centerOffset:I-R-L,...M&&{alignmentOffset:L}},reset:M}}}),T3=function(e){return e===void 0&&(e={}),{name:"flip",options:e,async fn(t){var r,n;const{placement:i,middlewareData:a,rects:o,initialPlacement:s,platform:l,elements:u}=t,{mainAxis:d=!0,crossAxis:c=!0,fallbackPlacements:f,fallbackStrategy:h="bestFit",fallbackAxisSideDirection:v="none",flipAlignment:m=!0,...g}=Qn(e,t);if((r=a.arrow)!=null&&r.alignmentOffset)return{};const y=Jn(i),b=bn(s),w=Jn(s)===s,_=await(l.isRTL==null?void 0:l.isRTL(u.floating)),x=f||(w||!m?[Of(s)]:_3(s)),S=v!=="none";!f&&S&&x.push(...k3(s,m,v,_));const E=[s,...x],k=await yu(t,g),P=[];let C=((n=a.flip)==null?void 0:n.overflows)||[];if(d&&P.push(k[y]),c){const I=x3(i,o,_);P.push(k[I[0]],k[I[1]])}if(C=[...C,{placement:i,overflows:P}],!P.every(I=>I<=0)){var N,$;const I=(((N=a.flip)==null?void 0:N.index)||0)+1,R=E[I];if(R&&(!(c==="alignment"?b!==bn(R):!1)||C.every(A=>A.overflows[0]>0&&bn(A.placement)===b)))return{data:{index:I,overflows:C},reset:{placement:R}};let M=($=C.filter(L=>L.overflows[0]<=0).sort((L,A)=>L.overflows[1]-A.overflows[1])[0])==null?void 0:$.placement;if(!M)switch(h){case"bestFit":{var D;const L=(D=C.filter(A=>{if(S){const T=bn(A.placement);return T===b||T==="y"}return!0}).map(A=>[A.placement,A.overflows.filter(T=>T>0).reduce((T,U)=>T+U,0)]).sort((A,T)=>A[1]-T[1])[0])==null?void 0:D[0];L&&(M=L);break}case"initialPlacement":M=s;break}if(i!==M)return{reset:{placement:M}}}return{}}}};function G1(e,t){return{top:e.top-t.height,right:e.right-t.width,bottom:e.bottom-t.height,left:e.left-t.width}}function Y1(e){return g3.some(t=>e[t]>=0)}const C3=function(e){return e===void 0&&(e={}),{name:"hide",options:e,async fn(t){const{rects:r}=t,{strategy:n="referenceHidden",...i}=Qn(e,t);switch(n){case"referenceHidden":{const a=await yu(t,{...i,elementContext:"reference"}),o=G1(a,r.reference);return{data:{referenceHiddenOffsets:o,referenceHidden:Y1(o)}}}case"escaped":{const a=await yu(t,{...i,altBoundary:!0}),o=G1(a,r.floating);return{data:{escapedOffsets:o,escaped:Y1(o)}}}default:return{}}}}},aT=new Set(["left","top"]);async function N3(e,t){const{placement:r,platform:n,elements:i}=e,a=await(n.isRTL==null?void 0:n.isRTL(i.floating)),o=Jn(r),s=Gs(r),l=bn(r)==="y",u=aT.has(o)?-1:1,d=a&&l?-1:1,c=Qn(t,e);let{mainAxis:f,crossAxis:h,alignmentAxis:v}=typeof c=="number"?{mainAxis:c,crossAxis:0,alignmentAxis:null}:{mainAxis:c.mainAxis||0,crossAxis:c.crossAxis||0,alignmentAxis:c.alignmentAxis};return s&&typeof v=="number"&&(h=s==="end"?v*-1:v),l?{x:h*d,y:f*u}:{x:f*u,y:h*d}}const $3=function(e){return e===void 0&&(e=0),{name:"offset",options:e,async fn(t){var r,n;const{x:i,y:a,placement:o,middlewareData:s}=t,l=await N3(t,e);return o===((r=s.offset)==null?void 0:r.placement)&&(n=s.arrow)!=null&&n.alignmentOffset?{}:{x:i+l.x,y:a+l.y,data:{...l,placement:o}}}}},R3=function(e){return e===void 0&&(e={}),{name:"shift",options:e,async fn(t){const{x:r,y:n,placement:i}=t,{mainAxis:a=!0,crossAxis:o=!1,limiter:s={fn:g=>{let{x:y,y:b}=g;return{x:y,y:b}}},...l}=Qn(e,t),u={x:r,y:n},d=await yu(t,l),c=bn(Jn(i)),f=$b(c);let h=u[f],v=u[c];if(a){const g=f==="y"?"top":"left",y=f==="y"?"bottom":"right",b=h+d[g],w=h-d[y];h=Lg(b,h,w)}if(o){const g=c==="y"?"top":"left",y=c==="y"?"bottom":"right",b=v+d[g],w=v-d[y];v=Lg(b,v,w)}const m=s.fn({...t,[f]:h,[c]:v});return{...m,data:{x:m.x-r,y:m.y-n,enabled:{[f]:a,[c]:o}}}}}},I3=function(e){return e===void 0&&(e={}),{options:e,fn(t){const{x:r,y:n,placement:i,rects:a,middlewareData:o}=t,{offset:s=0,mainAxis:l=!0,crossAxis:u=!0}=Qn(e,t),d={x:r,y:n},c=bn(i),f=$b(c);let h=d[f],v=d[c];const m=Qn(s,t),g=typeof m=="number"?{mainAxis:m,crossAxis:0}:{mainAxis:0,crossAxis:0,...m};if(l){const w=f==="y"?"height":"width",_=a.reference[f]-a.floating[w]+g.mainAxis,x=a.reference[f]+a.reference[w]-g.mainAxis;h<_?h=_:h>x&&(h=x)}if(u){var y,b;const w=f==="y"?"width":"height",_=aT.has(Jn(i)),x=a.reference[c]-a.floating[w]+(_&&((y=o.offset)==null?void 0:y[c])||0)+(_?0:g.crossAxis),S=a.reference[c]+a.reference[w]+(_?0:((b=o.offset)==null?void 0:b[c])||0)-(_?g.crossAxis:0);v<x?v=x:v>S&&(v=S)}return{[f]:h,[c]:v}}}},M3=function(e){return e===void 0&&(e={}),{name:"size",options:e,async fn(t){var r,n;const{placement:i,rects:a,platform:o,elements:s}=t,{apply:l=()=>{},...u}=Qn(e,t),d=await yu(t,u),c=Jn(i),f=Gs(i),h=bn(i)==="y",{width:v,height:m}=a.floating;let g,y;c==="top"||c==="bottom"?(g=c,y=f===(await(o.isRTL==null?void 0:o.isRTL(s.floating))?"start":"end")?"left":"right"):(y=c,g=f==="end"?"top":"bottom");const b=m-d.top-d.bottom,w=v-d.left-d.right,_=Vi(m-d[g],b),x=Vi(v-d[y],w),S=!t.middlewareData.shift;let E=_,k=x;if((r=t.middlewareData.shift)!=null&&r.enabled.x&&(k=w),(n=t.middlewareData.shift)!=null&&n.enabled.y&&(E=b),S&&!f){const C=ar(d.left,0),N=ar(d.right,0),$=ar(d.top,0),D=ar(d.bottom,0);h?k=v-2*(C!==0||N!==0?C+N:ar(d.left,d.right)):E=m-2*($!==0||D!==0?$+D:ar(d.top,d.bottom))}await l({...t,availableWidth:k,availableHeight:E});const P=await o.getDimensions(s.floating);return v!==P.width||m!==P.height?{reset:{rects:!0}}:{}}}};function ep(){return typeof window<"u"}function Ys(e){return oT(e)?(e.nodeName||"").toLowerCase():"#document"}function cr(e){var t;return(e==null||(t=e.ownerDocument)==null?void 0:t.defaultView)||window}function Cn(e){var t;return(t=(oT(e)?e.ownerDocument:e.document)||window.document)==null?void 0:t.documentElement}function oT(e){return ep()?e instanceof Node||e instanceof cr(e).Node:!1}function an(e){return ep()?e instanceof Element||e instanceof cr(e).Element:!1}function An(e){return ep()?e instanceof HTMLElement||e instanceof cr(e).HTMLElement:!1}function X1(e){return!ep()||typeof ShadowRoot>"u"?!1:e instanceof ShadowRoot||e instanceof cr(e).ShadowRoot}const D3=new Set(["inline","contents"]);function Ec(e){const{overflow:t,overflowX:r,overflowY:n,display:i}=on(e);return/auto|scroll|overlay|hidden|clip/.test(t+n+r)&&!D3.has(i)}const L3=new Set(["table","td","th"]);function B3(e){return L3.has(Ys(e))}const U3=[":popover-open",":modal"];function tp(e){return U3.some(t=>{try{return e.matches(t)}catch{return!1}})}const F3=["transform","translate","scale","rotate","perspective"],z3=["transform","translate","scale","rotate","perspective","filter"],W3=["paint","layout","strict","content"];function Mb(e){const t=Db(),r=an(e)?on(e):e;return F3.some(n=>r[n]?r[n]!=="none":!1)||(r.containerType?r.containerType!=="normal":!1)||!t&&(r.backdropFilter?r.backdropFilter!=="none":!1)||!t&&(r.filter?r.filter!=="none":!1)||z3.some(n=>(r.willChange||"").includes(n))||W3.some(n=>(r.contain||"").includes(n))}function q3(e){let t=Ki(e);for(;An(t)&&!bs(t);){if(Mb(t))return t;if(tp(t))return null;t=Ki(t)}return null}function Db(){return typeof CSS>"u"||!CSS.supports?!1:CSS.supports("-webkit-backdrop-filter","none")}const H3=new Set(["html","body","#document"]);function bs(e){return H3.has(Ys(e))}function on(e){return cr(e).getComputedStyle(e)}function rp(e){return an(e)?{scrollLeft:e.scrollLeft,scrollTop:e.scrollTop}:{scrollLeft:e.scrollX,scrollTop:e.scrollY}}function Ki(e){if(Ys(e)==="html")return e;const t=e.assignedSlot||e.parentNode||X1(e)&&e.host||Cn(e);return X1(t)?t.host:t}function sT(e){const t=Ki(e);return bs(t)?e.ownerDocument?e.ownerDocument.body:e.body:An(t)&&Ec(t)?t:sT(t)}function bu(e,t,r){var n;t===void 0&&(t=[]),r===void 0&&(r=!0);const i=sT(e),a=i===((n=e.ownerDocument)==null?void 0:n.body),o=cr(i);if(a){const s=Ug(o);
vendor: 3,862 bytes, line 221
221return t.concat(o,o.visualViewport||[],Ec(i)?i:[],s&&r?bu(s):[])}return t.concat(i,bu(i,[],r))}function Ug(e){return e.parent&&Object.getPrototypeOf(e.parent)?e.frameElement:null}function lT(e){const t=on(e);let r=parseFloat(t.width)||0,n=parseFloat(t.height)||0;const i=An(e),a=i?e.offsetWidth:r,o=i?e.offsetHeight:n,s=Sf(r)!==a||Sf(n)!==o;return s&&(r=a,n=o),{width:r,height:n,$:s}}function Lb(e){return an(e)?e:e.contextElement}function Xo(e){const t=Lb(e);if(!An(t))return Sn(1);const r=t.getBoundingClientRect(),{width:n,height:i,$:a}=lT(t);let o=(a?Sf(r.width):r.width)/n,s=(a?Sf(r.height):r.height)/i;return(!o||!Number.isFinite(o))&&(o=1),(!s||!Number.isFinite(s))&&(s=1),{x:o,y:s}}const V3=Sn(0);function uT(e){const t=cr(e);return!Db()||!t.visualViewport?V3:{x:t.visualViewport.offsetLeft,y:t.visualViewport.offsetTop}}function K3(e,t,r){return t===void 0&&(t=!1),!r||t&&r!==cr(e)?!1:t}function Va(e,t,r,n){t===void 0&&(t=!1),r===void 0&&(r=!1);const i=e.getBoundingClientRect(),a=Lb(e);let o=Sn(1);t&&(n?an(n)&&(o=Xo(n)):o=Xo(e));const s=K3(a,r,n)?uT(a):Sn(0);let l=(i.left+s.x)/o.x,u=(i.top+s.y)/o.y,d=i.width/o.x,c=i.height/o.y;if(a){const f=cr(a),h=n&&an(n)?cr(n):n;let v=f,m=Ug(v);for(;m&&n&&h!==v;){const g=Xo(m),y=m.getBoundingClientRect(),b=on(m),w=y.left+(m.clientLeft+parseFloat(b.paddingLeft))*g.x,_=y.top+(m.clientTop+parseFloat(b.paddingTop))*g.y;l*=g.x,u*=g.y,d*=g.x,c*=g.y,l+=w,u+=_,v=cr(m),m=Ug(v)}}return Ef({width:d,height:c,x:l,y:u})}function Bb(e,t){const r=rp(e).scrollLeft;return t?t.left+r:Va(Cn(e)).left+r}function cT(e,t,r){r===void 0&&(r=!1);const n=e.getBoundingClientRect(),i=n.left+t.scrollLeft-(r?0:Bb(e,n)),a=n.top+t.scrollTop;return{x:i,y:a}}function G3(e){let{elements:t,rect:r,offsetParent:n,strategy:i}=e;const a=i==="fixed",o=Cn(n),s=t?tp(t.floating):!1;if(n===o||s&&a)return r;let l={scrollLeft:0,scrollTop:0},u=Sn(1);const d=Sn(0),c=An(n);if((c||!c&&!a)&&((Ys(n)!=="body"||Ec(o))&&(l=rp(n)),An(n))){const h=Va(n);u=Xo(n),d.x=h.x+n.clientLeft,d.y=h.y+n.clientTop}const f=o&&!c&&!a?cT(o,l,!0):Sn(0);return{width:r.width*u.x,height:r.height*u.y,x:r.x*u.x-l.scrollLeft*u.x+d.x+f.x,y:r.y*u.y-l.scrollTop*u.y+d.y+f.y}}function Y3(e){return Array.from(e.getClientRects())}function X3(e){const t=Cn(e),r=rp(e),n=e.ownerDocument.body,i=ar(t.scrollWidth,t.clientWidth,n.scrollWidth,n.clientWidth),a=ar(t.scrollHeight,t.clientHeight,n.scrollHeight,n.clientHeight);let o=-r.scrollLeft+Bb(e);const s=-r.scrollTop;return on(n).direction==="rtl"&&(o+=ar(t.clientWidth,n.clientWidth)-i),{width:i,height:a,x:o,y:s}}function Q3(e,t){const r=cr(e),n=Cn(e),i=r.visualViewport;let a=n.clientWidth,o=n.clientHeight,s=0,l=0;if(i){a=i.width,o=i.height;const u=Db();(!u||u&&t==="fixed")&&(s=i.offsetLeft,l=i.offsetTop)}return{width:a,height:o,x:s,y:l}}const J3=new Set(["absolute","fixed"]);function Z3(e,t){const r=Va(e,!0,t==="fixed"),n=r.top+e.clientTop,i=r.left+e.clientLeft,a=An(e)?Xo(e):Sn(1),o=e.clientWidth*a.x,s=e.clientHeight*a.y,l=i*a.x,u=n*a.y;return{width:o,height:s,x:l,y:u}}function Q1(e,t,r){let n;if(t==="viewport")n=Q3(e,r);else if(t==="document")n=X3(Cn(e));else if(an(t))n=Z3(t,r);else{const i=uT(e);n={x:t.x-i.x,y:t.y-i.y,width:t.width,height:t.height}}return Ef(n)}function dT(e,t){const r=Ki(e);return r===t||!an(r)||bs(r)?!1:on(r).position==="fixed"||dT(r,t)}function eB(e,t){const r=t.get(e);if(r)return r;let n=bu(e,[],!1).filter(s=>an(s)&&Ys(s)!=="body"),i=null;const a=on(e).position==="fixed";let o=a?Ki(e):e;for(;an(o)&&!bs(o);){const s=on(o),l=Mb(o);!l&&s.position==="fixed"&&(i=null),(a?!l&&!i:!l&&s.position==="static"&&!!i&&J3.has(i.position)||Ec(o)&&!l&&dT(e,o))?n=n.filter(d=>d!==o):i=s,o=Ki(o)}return t.set(e,n),n}function tB(e){let{element:t,boundary:r,rootBoundary:n,strategy:i}=e;const o=[...r==="clippingAncestors"?tp(t)?[]:eB(t,this._c):[].concat(r),n],s=o[0],l=o.reduce((u,d)=>{const c=Q1(t,d,i);
vendor: 9,127 bytes, line 221
221return u.top=ar(c.top,u.top),u.right=Vi(c.right,u.right),u.bottom=Vi(c.bottom,u.bottom),u.left=ar(c.left,u.left),u},Q1(t,s,i));return{width:l.right-l.left,height:l.bottom-l.top,x:l.left,y:l.top}}function rB(e){const{width:t,height:r}=lT(e);return{width:t,height:r}}function nB(e,t,r){const n=An(t),i=Cn(t),a=r==="fixed",o=Va(e,!0,a,t);let s={scrollLeft:0,scrollTop:0};const l=Sn(0);function u(){l.x=Bb(i)}if(n||!n&&!a)if((Ys(t)!=="body"||Ec(i))&&(s=rp(t)),n){const h=Va(t,!0,a,t);l.x=h.x+t.clientLeft,l.y=h.y+t.clientTop}else i&&u();a&&!n&&i&&u();const d=i&&!n&&!a?cT(i,s):Sn(0),c=o.left+s.scrollLeft-l.x-d.x,f=o.top+s.scrollTop-l.y-d.y;return{x:c,y:f,width:o.width,height:o.height}}function Vm(e){return on(e).position==="static"}function J1(e,t){if(!An(e)||on(e).position==="fixed")return null;if(t)return t(e);let r=e.offsetParent;return Cn(e)===r&&(r=r.ownerDocument.body),r}function fT(e,t){const r=cr(e);if(tp(e))return r;if(!An(e)){let i=Ki(e);for(;i&&!bs(i);){if(an(i)&&!Vm(i))return i;i=Ki(i)}return r}let n=J1(e,t);for(;n&&B3(n)&&Vm(n);)n=J1(n,t);return n&&bs(n)&&Vm(n)&&!Mb(n)?r:n||q3(e)||r}const iB=async function(e){const t=this.getOffsetParent||fT,r=this.getDimensions,n=await r(e.floating);return{reference:nB(e.reference,await t(e.floating),e.strategy),floating:{x:0,y:0,width:n.width,height:n.height}}};function aB(e){return on(e).direction==="rtl"}const oB={convertOffsetParentRelativeRectToViewportRelativeRect:G3,getDocumentElement:Cn,getClippingRect:tB,getOffsetParent:fT,getElementRects:iB,getClientRects:Y3,getDimensions:rB,getScale:Xo,isElement:an,isRTL:aB};function hT(e,t){return e.x===t.x&&e.y===t.y&&e.width===t.width&&e.height===t.height}function sB(e,t){let r=null,n;const i=Cn(e);function a(){var s;clearTimeout(n),(s=r)==null||s.disconnect(),r=null}function o(s,l){s===void 0&&(s=!1),l===void 0&&(l=1),a();const u=e.getBoundingClientRect(),{left:d,top:c,width:f,height:h}=u;if(s||t(),!f||!h)return;const v=ad(c),m=ad(i.clientWidth-(d+f)),g=ad(i.clientHeight-(c+h)),y=ad(d),w={rootMargin:-v+"px "+-m+"px "+-g+"px "+-y+"px",threshold:ar(0,Vi(1,l))||1};let _=!0;function x(S){const E=S[0].intersectionRatio;if(E!==l){if(!_)return o();E?o(!1,E):n=setTimeout(()=>{o(!1,1e-7)},1e3)}E===1&&!hT(u,e.getBoundingClientRect())&&o(),_=!1}try{r=new IntersectionObserver(x,{...w,root:i.ownerDocument})}catch{r=new IntersectionObserver(x,w)}r.observe(e)}return o(!0),a}function lB(e,t,r,n){n===void 0&&(n={});const{ancestorScroll:i=!0,ancestorResize:a=!0,elementResize:o=typeof ResizeObserver=="function",layoutShift:s=typeof IntersectionObserver=="function",animationFrame:l=!1}=n,u=Lb(e),d=i||a?[...u?bu(u):[],...bu(t)]:[];d.forEach(y=>{i&&y.addEventListener("scroll",r,{passive:!0}),a&&y.addEventListener("resize",r)});const c=u&&s?sB(u,r):null;let f=-1,h=null;o&&(h=new ResizeObserver(y=>{let[b]=y;b&&b.target===u&&h&&(h.unobserve(t),cancelAnimationFrame(f),f=requestAnimationFrame(()=>{var w;(w=h)==null||w.observe(t)})),r()}),u&&!l&&h.observe(u),h.observe(t));let v,m=l?Va(e):null;l&&g();function g(){const y=Va(e);m&&!hT(m,y)&&r(),m=y,v=requestAnimationFrame(g)}return r(),()=>{var y;d.forEach(b=>{i&&b.removeEventListener("scroll",r),a&&b.removeEventListener("resize",r)}),c==null||c(),(y=h)==null||y.disconnect(),h=null,l&&cancelAnimationFrame(v)}}const uB=$3,cB=R3,dB=T3,fB=M3,hB=C3,Z1=j3,pB=I3,mB=(e,t,r)=>{const n=new Map,i={platform:oB,...r},a={...i.platform,_c:n};return A3(e,t,{...i,platform:a})};var vB=typeof document<"u",gB=function(){},Gd=vB?O.useLayoutEffect:gB;function kf(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 r,n,i;if(e&&t&&typeof e=="object"){if(Array.isArray(e)){if(r=e.length,r!==t.length)return!1;for(n=r;n--!==0;)if(!kf(e[n],t[n]))return!1;return!0}if(i=Object.keys(e),r=i.length,r!==Object.keys(t).length)return!1;for(n=r;n--!==0;)if(!{}.hasOwnProperty.call(t,i[n]))return!1;for(n=r;n--!==0;){const a=i[n];if(!(a==="_owner"&&e.$$typeof)&&!kf(e[a],t[a]))return!1}return!0}return e!==e&&t!==t}function pT(e){return typeof window>"u"?1:(e.ownerDocument.defaultView||window).devicePixelRatio||1}function e_(e,t){const r=pT(e);return Math.round(t*r)/r}function Km(e){const t=O.useRef(e);return Gd(()=>{t.current=e}),t}function yB(e){e===void 0&&(e={});const{placement:t="bottom",strategy:r="absolute",middleware:n=[],platform:i,elements:{reference:a,floating:o}={},transform:s=!0,whileElementsMounted:l,open:u}=e,[d,c]=O.useState({x:0,y:0,strategy:r,placement:t,middlewareData:{},isPositioned:!1}),[f,h]=O.useState(n);kf(f,n)||h(n);const[v,m]=O.useState(null),[g,y]=O.useState(null),b=O.useCallback(A=>{A!==S.current&&(S.current=A,m(A))},[]),w=O.useCallback(A=>{A!==E.current&&(E.current=A,y(A))},[]),_=a||v,x=o||g,S=O.useRef(null),E=O.useRef(null),k=O.useRef(d),P=l!=null,C=Km(l),N=Km(i),$=Km(u),D=O.useCallback(()=>{if(!S.current||!E.current)return;const A={placement:t,strategy:r,middleware:f};N.current&&(A.platform=N.current),mB(S.current,E.current,A).then(T=>{const U={...T,isPositioned:$.current!==!1};I.current&&!kf(k.current,U)&&(k.current=U,_c.flushSync(()=>{c(U)}))})},[f,t,r,N,$]);Gd(()=>{u===!1&&k.current.isPositioned&&(k.current.isPositioned=!1,c(A=>({...A,isPositioned:!1})))},[u]);const I=O.useRef(!1);Gd(()=>(I.current=!0,()=>{I.current=!1}),[]),Gd(()=>{if(_&&(S.current=_),x&&(E.current=x),_&&x){if(C.current)return C.current(_,x,D);D()}},[_,x,D,C,P]);const R=O.useMemo(()=>({reference:S,floating:E,setReference:b,setFloating:w}),[b,w]),M=O.useMemo(()=>({reference:_,floating:x}),[_,x]),L=O.useMemo(()=>{const A={position:r,left:0,top:0};if(!M.floating)return A;const T=e_(M.floating,d.x),U=e_(M.floating,d.y);return s?{...A,transform:"translate("+T+"px, "+U+"px)",...pT(M.floating)>=1.5&&{willChange:"transform"}}:{position:r,left:T,top:U}},[r,s,M.floating,d.x,d.y]);return O.useMemo(()=>({...d,update:D,refs:R,elements:M,floatingStyles:L}),[d,D,R,M,L])}const bB=e=>{function t(r){return{}.hasOwnProperty.call(r,"current")}return{name:"arrow",options:e,fn(r){const{element:n,padding:i}=typeof e=="function"?e(r):e;return n&&t(n)?n.current!=null?Z1({element:n.current,padding:i}).fn(r):{}:n?Z1({element:n,padding:i}).fn(r):{}}}},wB=(e,t)=>({...uB(e),options:[e,t]}),xB=(e,t)=>({...cB(e),options:[e,t]}),_B=(e,t)=>({...pB(e),options:[e,t]}),SB=(e,t)=>({...dB(e),options:[e,t]}),OB=(e,t)=>({...fB(e),options:[e,t]}),EB=(e,t)=>({...hB(e),options:[e,t]}),kB=(e,t)=>({...bB(e),options:[e,t]});var PB="Arrow",mT=O.forwardRef((e,t)=>{const{children:r,width:n=10,height:i=5,...a}=e;return p.jsx(Oe.svg,{...a,ref:t,width:n,height:i,viewBox:"0 0 30 10",preserveAspectRatio:"none",children:e.asChild?r:p.jsx("polygon",{points:"0,0 30,0 15,10"})})});mT.displayName=PB;var AB=mT;function jB(e){const[t,r]=O.useState(void 0);return Pn(()=>{if(e){r({width:e.offsetWidth,height:e.offsetHeight});const n=new ResizeObserver(i=>{if(!Array.isArray(i)||!i.length)return;const a=i[0];let o,s;if("borderBoxSize"in a){const l=a.borderBoxSize,u=Array.isArray(l)?l[0]:l;o=u.inlineSize,s=u.blockSize}else o=e.offsetWidth,s=e.offsetHeight;r({width:o,height:s})});return n.observe(e,{box:"border-box"}),()=>n.unobserve(e)}else r(void 0)},[e]),t}var Ub="Popper",[vT,np]=ni(Ub),[TB,gT]=vT(Ub),yT=e=>{const{__scopePopper:t,children:r}=e,[n,i]=O.useState(null);return p.jsx(TB,{scope:t,anchor:n,onAnchorChange:i,children:r})};yT.displayName=Ub;var bT="PopperAnchor",wT=O.forwardRef((e,t)=>{const{__scopePopper:r,virtualRef:n,...i}=e,a=gT(bT,r),o=O.useRef(null),s=ft(t,o);return O.useEffect(()=>{a.onAnchorChange((n==null?void 0:n.current)||o.current)}),n?null:p.jsx(Oe.div,{...i,ref:s})});wT.displayName=bT;var Fb="PopperContent",[CB,NB]=vT(Fb),xT=O.forwardRef((e,t)=>{var ue,Ze,G,ie,ae,H;const{__scopePopper:r,side:n="bottom",sideOffset:i=0,align:a="center",alignOffset:o=0,arrowPadding:s=0,avoidCollisions:l=!0,collisionBoundary:u=[],collisionPadding:d=0,sticky:c="partial",hideWhenDetached:f=!1,updatePositionStrategy:h="optimized",onPlaced:v,...m}=e,g=gT(Fb,r),[y,b]=O.useState(null),w=ft(t,ye=>b(ye)),[_,x]=O.useState(null),S=jB(_),E=(S==null?void 0:S.width)??0,k=(S==null?void 0:S.height)??0,P=n+(a!=="center"?"-"+a:""),C=typeof d=="number"?d:{top:0,right:0,bottom:0,left:0,...d},N=Array.isArray(u)?u:[u],$=N.length>0,D={padding:C,boundary:N.filter(RB),altBoundary:$},{refs:I,floatingStyles:R,placement:M,isPositioned:L,middlewareData:A}=yB({strategy:"fixed",placement:P,whileElementsMounted:(...ye)=>lB(...ye,{animationFrame:h==="always"}),elements:{reference:g.anchor},middleware:[wB({mainAxis:i+k,alignmentAxis:o}),l&&xB({mainAxis:!0,crossAxis:!1,limiter:c==="partial"?_B():void 0,...D}),l&&SB({...D}),OB({...D,apply:({elements:ye,rects:ce,availableWidth:He,availableHeight:Fe})=>{const{width:pt,height:Wt}=ce.reference,Zt=ye.floating.style;Zt.setProperty("--radix-popper-available-width",`${He}px`),Zt.setProperty("--radix-popper-available-height",`${Fe}px`),Zt.setProperty("--radix-popper-anchor-width",`${pt}px`),Zt.setProperty("--radix-popper-anchor-height",`${Wt}px`)}}),_&&kB({element:_,padding:s}),IB({arrowWidth:E,arrowHeight:k}),f&&EB({strategy:"referenceHidden",...D})]}),[T,U]=OT(M),q=kn(v);Pn(()=>
vendor: 4,241 bytes, line 221
221{L&&(q==null||q())},[L,q]);const B=(ue=A.arrow)==null?void 0:ue.x,W=(Ze=A.arrow)==null?void 0:Ze.y,K=((G=A.arrow)==null?void 0:G.centerOffset)!==0,[Z,xe]=O.useState();return Pn(()=>{y&&xe(window.getComputedStyle(y).zIndex)},[y]),p.jsx("div",{ref:I.setFloating,"data-radix-popper-content-wrapper":"",style:{...R,transform:L?R.transform:"translate(0, -200%)",minWidth:"max-content",zIndex:Z,"--radix-popper-transform-origin":[(ie=A.transformOrigin)==null?void 0:ie.x,(ae=A.transformOrigin)==null?void 0:ae.y].join(" "),...((H=A.hide)==null?void 0:H.referenceHidden)&&{visibility:"hidden",pointerEvents:"none"}},dir:e.dir,children:p.jsx(CB,{scope:r,placedSide:T,onArrowChange:x,arrowX:B,arrowY:W,shouldHideArrow:K,children:p.jsx(Oe.div,{"data-side":T,"data-align":U,...m,ref:w,style:{...m.style,animation:L?void 0:"none"}})})})});xT.displayName=Fb;var _T="PopperArrow",$B={top:"bottom",right:"left",bottom:"top",left:"right"},ST=O.forwardRef(function(t,r){const{__scopePopper:n,...i}=t,a=NB(_T,n),o=$B[a.placedSide];return p.jsx("span",{ref:a.onArrowChange,style:{position:"absolute",left:a.arrowX,top:a.arrowY,[o]:0,transformOrigin:{top:"",right:"0 0",bottom:"center 0",left:"100% 0"}[a.placedSide],transform:{top:"translateY(100%)",right:"translateY(50%) rotate(90deg) translateX(-50%)",bottom:"rotate(180deg)",left:"translateY(50%) rotate(-90deg) translateX(50%)"}[a.placedSide],visibility:a.shouldHideArrow?"hidden":void 0},children:p.jsx(AB,{...i,ref:r,style:{...i.style,display:"block"}})})});ST.displayName=_T;function RB(e){return e!==null}var IB=e=>({name:"transformOrigin",options:e,fn(t){var g,y,b;const{placement:r,rects:n,middlewareData:i}=t,o=((g=i.arrow)==null?void 0:g.centerOffset)!==0,s=o?0:e.arrowWidth,l=o?0:e.arrowHeight,[u,d]=OT(r),c={start:"0%",center:"50%",end:"100%"}[d],f=(((y=i.arrow)==null?void 0:y.x)??0)+s/2,h=(((b=i.arrow)==null?void 0:b.y)??0)+l/2;let v="",m="";return u==="bottom"?(v=o?c:`${f}px`,m=`${-l}px`):u==="top"?(v=o?c:`${f}px`,m=`${n.floating.height+l}px`):u==="right"?(v=`${-l}px`,m=o?c:`${h}px`):u==="left"&&(v=`${n.floating.width+l}px`,m=o?c:`${h}px`),{data:{x:v,y:m}}}});function OT(e){const[t,r="center"]=e.split("-");return[t,r]}var ET=yT,zb=wT,kT=xT,PT=ST,[ip,_pe]=ni("Tooltip",[np]),ap=np(),AT="TooltipProvider",MB=700,Fg="tooltip.open",[DB,Wb]=ip(AT),jT=e=>{const{__scopeTooltip:t,delayDuration:r=MB,skipDelayDuration:n=300,disableHoverableContent:i=!1,children:a}=e,o=O.useRef(!0),s=O.useRef(!1),l=O.useRef(0);return O.useEffect(()=>{const u=l.current;return()=>window.clearTimeout(u)},[]),p.jsx(DB,{scope:t,isOpenDelayedRef:o,delayDuration:r,onOpen:O.useCallback(()=>{window.clearTimeout(l.current),o.current=!1},[]),onClose:O.useCallback(()=>{window.clearTimeout(l.current),l.current=window.setTimeout(()=>o.current=!0,n)},[n]),isPointerInTransitRef:s,onPointerInTransitChange:O.useCallback(u=>{s.current=u},[]),disableHoverableContent:i,children:a})};jT.displayName=AT;var wu="Tooltip",[LB,op]=ip(wu),TT=e=>{const{__scopeTooltip:t,children:r,open:n,defaultOpen:i,onOpenChange:a,disableHoverableContent:o,delayDuration:s}=e,l=Wb(wu,e.__scopeTooltip),u=ap(t),[d,c]=O.useState(null),f=Ia(),h=O.useRef(0),v=o??l.disableHoverableContent,m=s??l.delayDuration,g=O.useRef(!1),[y,b]=eo({prop:n,defaultProp:i??!1,onChange:E=>{E?(l.onOpen(),document.dispatchEvent(new CustomEvent(Fg))):l.onClose(),a==null||a(E)},caller:wu}),w=O.useMemo(()=>y?g.current?"delayed-open":"instant-open":"closed",[y]),_=O.useCallback(()=>{window.clearTimeout(h.current),h.current=0,g.current=!1,b(!0)},[b]),x=O.useCallback(()=>{window.clearTimeout(h.current),h.current=0,b(!1)},[b]),S=O.useCallback(()=>{window.clearTimeout(h.current),h.current=window.setTimeout(()=>{g.current=!0,b(!0),h.current=0},m)},[m,b]);return O.useEffect(()=>()=>{h.current&&(window.clearTimeout(h.current),h.current=0)},[]),p.jsx(ET,{...u,children:p.jsx(LB,{scope:t,contentId:f,open:y,stateAttribute:w,trigger:d,onTriggerChange:c,onTriggerEnter:O.useCallback(()=>{l.isOpenDelayedRef.current?S():_()},[l.isOpenDelayedRef,S,_]),onTriggerLeave:O.useCallback(()=>{v?x():(window.clearTimeout(h.current),h.current=0)},[x,v]),onOpen:_,onClose:x,disableHoverableContent:v,children:r})})};TT.displayName=wu;var zg="TooltipTrigger",CT=O.forwardRef((e,t)=>
vendor: 5,251 bytes, line 221
221{const{__scopeTooltip:r,...n}=e,i=op(zg,r),a=Wb(zg,r),o=ap(r),s=O.useRef(null),l=ft(t,s,i.onTriggerChange),u=O.useRef(!1),d=O.useRef(!1),c=O.useCallback(()=>u.current=!1,[]);return O.useEffect(()=>()=>document.removeEventListener("pointerup",c),[c]),p.jsx(zb,{asChild:!0,...o,children:p.jsx(Oe.button,{"aria-describedby":i.open?i.contentId:void 0,"data-state":i.stateAttribute,...n,ref:l,onPointerMove:be(e.onPointerMove,f=>{f.pointerType!=="touch"&&!d.current&&!a.isPointerInTransitRef.current&&(i.onTriggerEnter(),d.current=!0)}),onPointerLeave:be(e.onPointerLeave,()=>{i.onTriggerLeave(),d.current=!1}),onPointerDown:be(e.onPointerDown,()=>{i.open&&i.onClose(),u.current=!0,document.addEventListener("pointerup",c,{once:!0})}),onFocus:be(e.onFocus,()=>{u.current||i.onOpen()}),onBlur:be(e.onBlur,i.onClose),onClick:be(e.onClick,i.onClose)})})});CT.displayName=zg;var BB="TooltipPortal",[Spe,UB]=ip(BB,{forceMount:void 0}),ws="TooltipContent",NT=O.forwardRef((e,t)=>{const r=UB(ws,e.__scopeTooltip),{forceMount:n=r.forceMount,side:i="top",...a}=e,o=op(ws,e.__scopeTooltip);return p.jsx(ii,{present:n||o.open,children:o.disableHoverableContent?p.jsx($T,{side:i,...a,ref:t}):p.jsx(FB,{side:i,...a,ref:t})})}),FB=O.forwardRef((e,t)=>{const r=op(ws,e.__scopeTooltip),n=Wb(ws,e.__scopeTooltip),i=O.useRef(null),a=ft(t,i),[o,s]=O.useState(null),{trigger:l,onClose:u}=r,d=i.current,{onPointerInTransitChange:c}=n,f=O.useCallback(()=>{s(null),c(!1)},[c]),h=O.useCallback((v,m)=>{const g=v.currentTarget,y={x:v.clientX,y:v.clientY},b=VB(y,g.getBoundingClientRect()),w=KB(y,b),_=GB(m.getBoundingClientRect()),x=XB([...w,..._]);s(x),c(!0)},[c]);return O.useEffect(()=>()=>f(),[f]),O.useEffect(()=>{if(l&&d){const v=g=>h(g,d),m=g=>h(g,l);return l.addEventListener("pointerleave",v),d.addEventListener("pointerleave",m),()=>{l.removeEventListener("pointerleave",v),d.removeEventListener("pointerleave",m)}}},[l,d,h,f]),O.useEffect(()=>{if(o){const v=m=>{const g=m.target,y={x:m.clientX,y:m.clientY},b=(l==null?void 0:l.contains(g))||(d==null?void 0:d.contains(g)),w=!YB(y,o);b?f():w&&(f(),u())};return document.addEventListener("pointermove",v),()=>document.removeEventListener("pointermove",v)}},[l,d,o,u,f]),p.jsx($T,{...e,ref:a})}),[zB,WB]=ip(wu,{isInside:!1}),qB=YD("TooltipContent"),$T=O.forwardRef((e,t)=>{const{__scopeTooltip:r,children:n,"aria-label":i,onEscapeKeyDown:a,onPointerDownOutside:o,...s}=e,l=op(ws,r),u=ap(r),{onClose:d}=l;return O.useEffect(()=>(document.addEventListener(Fg,d),()=>document.removeEventListener(Fg,d)),[d]),O.useEffect(()=>{if(l.trigger){const c=f=>{const h=f.target;h!=null&&h.contains(l.trigger)&&d()};return window.addEventListener("scroll",c,{capture:!0}),()=>window.removeEventListener("scroll",c,{capture:!0})}},[l.trigger,d]),p.jsx(Sc,{asChild:!0,disableOutsidePointerEvents:!1,onEscapeKeyDown:a,onPointerDownOutside:o,onFocusOutside:c=>c.preventDefault(),onDismiss:d,children:p.jsxs(kT,{"data-state":l.stateAttribute,...u,...s,ref:t,style:{...s.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:[p.jsx(qB,{children:n}),p.jsx(zB,{scope:r,isInside:!0,children:p.jsx(yL,{id:l.contentId,role:"tooltip",children:i||n})})]})})});NT.displayName=ws;var RT="TooltipArrow",HB=O.forwardRef((e,t)=>{const{__scopeTooltip:r,...n}=e,i=ap(r);return WB(RT,r).isInside?null:p.jsx(PT,{...i,...n,ref:t})});HB.displayName=RT;function VB(e,t){const r=Math.abs(t.top-e.y),n=Math.abs(t.bottom-e.y),i=Math.abs(t.right-e.x),a=Math.abs(t.left-e.x);switch(Math.min(r,n,i,a)){case a:return"left";case i:return"right";case r:return"top";case n:return"bottom";default:throw new Error("unreachable")}}function KB(e,t,r=5){const n=[];switch(t){case"top":n.push({x:e.x-r,y:e.y+r},{x:e.x+r,y:e.y+r});break;case"bottom":n.push({x:e.x-r,y:e.y-r},{x:e.x+r,y:e.y-r});break;case"left":n.push({x:e.x+r,y:e.y-r},{x:e.x+r,y:e.y+r});break;case"right":n.push({x:e.x-r,y:e.y-r},{x:e.x-r,y:e.y+r});break}return n}function GB(e){const{top:t,right:r,bottom:n,left:i}=e;return[{x:i,y:t},{x:r,y:t},{x:r,y:n},{x:i,y:n}]}function YB(e,t){const{x:r,y:n}=e;let i=!1;for(let a=0,o=t.length-1;a<t.length;o=a++){const s=t[a],l=t[o],u=s.x,d=s.y,c=l.x,f=l.y;d>n!=f>n&&r<(c-u)*(n-d)/(f-d)+u&&(i=!i)}return i}function XB(e){const t=e.slice();return t.sort((r,n)=>r.x<n.x?-1:r.x>n.x?1:r.y<n.y?-1:r.y>n.y?1:0),QB(t)}function QB(e){if(e.length<=1)return e.slice();const t=[];for(let n=0;n<e.length;n++){const i=e[n];for(;t.length>=2;){const a=t[t.length-1],o=t[t.length-2];if((a.x-o.x)*(i.y-o.y)>=(a.y-o.y)*(i.x-o.x))t.pop();else break}t.push(i)}t.pop();const r=[];for(let n=e.length-1;n>=0;n--){const i=e[n];for(;r.length>=2;){const a=r[r.length-1],o=r[r.length-2];if((a.x-o.x)*(i.y-o.y)>=(a.y-o.y)*(i.x-o.x))r.pop();else break}r.push(i)}return r.pop(),t.length===1&&r.length===1&&t[0].x===r[0].x&&t[0].y===r[0].y?t:t.concat(r)}var JB=jT,ZB=TT,e5=CT,IT=NT;const Wg=JB,t_=ZB,r_=e5,qg=O.forwardRef(({className:e,sideOffset:t=4,...r},n)=>
vendor: 8,841 bytes, line 221
221p.jsx(IT,{ref:n,sideOffset:t,className:Ne("z-50 overflow-hidden rounded-md border bg-popover px-3 py-1.5 text-sm text-popover-foreground shadow-md animate-in fade-in-0 zoom-in-95 data-[state=closed]:animate-out data-[state=closed]:fade-out-0 data-[state=closed]:zoom-out-95 data-[side=bottom]:slide-in-from-top-2 data-[side=left]:slide-in-from-right-2 data-[side=right]:slide-in-from-left-2 data-[side=top]:slide-in-from-bottom-2",e),...r}));qg.displayName=IT.displayName;var sp=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(){}},lp=typeof window>"u"||"Deno"in globalThis;function Fr(){}function t5(e,t){return typeof e=="function"?e(t):e}function r5(e){return typeof e=="number"&&e>=0&&e!==1/0}function n5(e,t){return Math.max(e+(t||0)-Date.now(),0)}function Hg(e,t){return typeof e=="function"?e(t):e}function i5(e,t){return typeof e=="function"?e(t):e}function n_(e,t){const{type:r="all",exact:n,fetchStatus:i,predicate:a,queryKey:o,stale:s}=e;if(o){if(n){if(t.queryHash!==qb(o,t.options))return!1}else if(!_u(t.queryKey,o))return!1}if(r!=="all"){const l=t.isActive();if(r==="active"&&!l||r==="inactive"&&l)return!1}return!(typeof s=="boolean"&&t.isStale()!==s||i&&i!==t.state.fetchStatus||a&&!a(t))}function i_(e,t){const{exact:r,status:n,predicate:i,mutationKey:a}=e;if(a){if(!t.options.mutationKey)return!1;if(r){if(xu(t.options.mutationKey)!==xu(a))return!1}else if(!_u(t.options.mutationKey,a))return!1}return!(n&&t.state.status!==n||i&&!i(t))}function qb(e,t){return((t==null?void 0:t.queryKeyHashFn)||xu)(e)}function xu(e){return JSON.stringify(e,(t,r)=>Vg(r)?Object.keys(r).sort().reduce((n,i)=>(n[i]=r[i],n),{}):r)}function _u(e,t){return e===t?!0:typeof e!=typeof t?!1:e&&t&&typeof e=="object"&&typeof t=="object"?Object.keys(t).every(r=>_u(e[r],t[r])):!1}function MT(e,t){if(e===t)return e;const r=a_(e)&&a_(t);if(r||Vg(e)&&Vg(t)){const n=r?e:Object.keys(e),i=n.length,a=r?t:Object.keys(t),o=a.length,s=r?[]:{},l=new Set(n);let u=0;for(let d=0;d<o;d++){const c=r?d:a[d];(!r&&l.has(c)||r)&&e[c]===void 0&&t[c]===void 0?(s[c]=void 0,u++):(s[c]=MT(e[c],t[c]),s[c]===e[c]&&e[c]!==void 0&&u++)}return i===o&&u===i?e:s}return t}function a_(e){return Array.isArray(e)&&e.length===Object.keys(e).length}function Vg(e){if(!o_(e))return!1;const t=e.constructor;if(t===void 0)return!0;const r=t.prototype;return!(!o_(r)||!r.hasOwnProperty("isPrototypeOf")||Object.getPrototypeOf(e)!==Object.prototype)}function o_(e){return Object.prototype.toString.call(e)==="[object Object]"}function a5(e){return new Promise(t=>{setTimeout(t,e)})}function o5(e,t,r){return typeof r.structuralSharing=="function"?r.structuralSharing(e,t):r.structuralSharing!==!1?MT(e,t):t}function s5(e,t,r=0){const n=[...e,t];return r&&n.length>r?n.slice(1):n}function l5(e,t,r=0){const n=[t,...e];return r&&n.length>r?n.slice(0,-1):n}var Hb=Symbol();function DT(e,t){return!e.queryFn&&(t!=null&&t.initialPromise)?()=>t.initialPromise:!e.queryFn||e.queryFn===Hb?()=>Promise.reject(new Error(`Missing queryFn: '${e.queryHash}'`)):e.queryFn}var Pa,Ei,ns,qk,u5=(qk=class extends sp{constructor(){super();me(this,Pa);me(this,Ei);me(this,ns);se(this,ns,t=>{if(!lp&&window.addEventListener){const r=()=>t();return window.addEventListener("visibilitychange",r,!1),()=>{window.removeEventListener("visibilitychange",r)}}})}onSubscribe(){z(this,Ei)||this.setEventListener(z(this,ns))}onUnsubscribe(){var t;this.hasListeners()||((t=z(this,Ei))==null||t.call(this),se(this,Ei,void 0))}setEventListener(t){var r;se(this,ns,t),(r=z(this,Ei))==null||r.call(this),se(this,Ei,t(n=>{typeof n=="boolean"?this.setFocused(n):this.onFocus()}))}setFocused(t){z(this,Pa)!==t&&(se(this,Pa,t),this.onFocus())}onFocus(){const t=this.isFocused();this.listeners.forEach(r=>{r(t)})}isFocused(){var t;return typeof z(this,Pa)=="boolean"?z(this,Pa):((t=globalThis.document)==null?void 0:t.visibilityState)!=="hidden"}},Pa=new WeakMap,Ei=new WeakMap,ns=new WeakMap,qk),LT=new u5,is,ki,as,Hk,c5=(Hk=class extends sp{constructor(){super();me(this,is,!0);me(this,ki);me(this,as);se(this,as,t=>{if(!lp&&window.addEventListener){const r=()=>t(!0),n=()=>t(!1);return window.addEventListener("online",r,!1),window.addEventListener("offline",n,!1),()=>{window.removeEventListener("online",r),window.removeEventListener("offline",n)}}})}onSubscribe(){z(this,ki)||this.setEventListener(z(this,as))}onUnsubscribe(){var t;this.hasListeners()||((t=z(this,ki))==null||t.call(this),se(this,ki,void 0))}setEventListener(t){var r;se(this,as,t),(r=z(this,ki))==null||r.call(this),se(this,ki,t(this.setOnline.bind(this)))}setOnline(t){z(this,is)!==t&&(se(this,is,t),this.listeners.forEach(n=>{n(t)}))}isOnline(){return z(this,is)}},is=new WeakMap,ki=new WeakMap,as=new WeakMap,Hk),Pf=new c5;function d5(){let e,t;const r=new Promise((i,a)=>{e=i,t=a});r.status="pending",r.catch(()=>{});function n(i){Object.assign(r,i),delete r.resolve,delete r.reject}return r.resolve=i=>{n({status:"fulfilled",value:i}),e(i)},r.reject=i=>{n({status:"rejected",reason:i}),t(i)},r}function f5(e){return Math.min(1e3*2**e,3e4)}function BT(e){return(e??"online")==="online"?Pf.isOnline():!0}var UT=class extends Error{constructor(e){super("CancelledError"),this.revert=e==null?void 0:e.revert,this.silent=e==null?void 0:e.silent}};function Gm(e){return e instanceof UT}function FT(e){let t=!1,r=0,n=!1,i;const a=d5(),o=m=>{var g;n||(f(new UT(m)),(g=e.abort)==null||g.call(e))},s=()=>{t=!0},l=()=>{t=!1},u=()=>LT.isFocused()&&(e.networkMode==="always"||Pf.isOnline())&&e.canRun(),d=()=>BT(e.networkMode)&&e.canRun(),c=m=>{var g;n||(n=!0,(g=e.onSuccess)==null||g.call(e,m),i==null||i(),a.resolve(m))},f=m=>{var g;n||(n=!0,(g=e.onError)==null||g.call(e,m),i==null||i(),a.reject(m))},h=()=>new Promise(m=>{var g;i=y=>{(n||u())&&m(y)},(g=e.onPause)==null||g.call(e)}).then(()=>{var m;i=void 0,n||(m=e.onContinue)==null||m.call(e)}),v=()=>{if(n)return;let m;const g=r===0?e.initialPromise:void 0;try{m=g??e.fn()}catch(y){m=Promise.reject(y)}Promise.resolve(m).then(c).catch(y=>{var S;if(n)return;const b=e.retry??(lp?0:3),w=e.retryDelay??f5,_=typeof w=="function"?w(r,y):w,x=b===!0||typeof b=="number"&&r<b||typeof b=="function"&&b(r,y);if(t||!x){f(y);return}r++,(S=e.onFail)==null||S.call(e,r,y),a5(_).then(()=>u()?void 0:h()).then(()=>{t?f(y):v()})})};return{promise:a,cancel:o,continue:()=>(i==null||i(),a),cancelRetry:s,continueRetry:l,canStart:d,start:()=>(d()?v():h().then(v),a)}}var h5=e=>setTimeout(e,0);function p5(){let e=[],t=0,r=s=>{s()},n=s=>{s()},i=h5;const a=s=>{t?e.push(s):i(()=>{r(s)})},o=()=>{const s=e;e=[],s.length&&i(()=>{n(()=>{s.forEach(l=>{r(l)})})})};return{batch:s=>{let l;t++;try{l=s()}finally{t--,t||o()}return l},batchCalls:s=>(...l)=>{a(()=>{s(...l)})},schedule:a,setNotifyFunction:s=>{r=s},setBatchNotifyFunction:s=>{n=s},setScheduler:s=>{i=s}}}var Lt=p5(),Aa,Vk,zT=(Vk=class{constructor(){me(this,Aa)}destroy(){this.clearGcTimeout()}scheduleGc(){this.clearGcTimeout(),r5(this.gcTime)&&se(this,Aa,setTimeout(()=>{this.optionalRemove()},this.gcTime))}updateGcTime(e){this.gcTime=Math.max(this.gcTime||0,e??(lp?1/0:5*60*1e3))}clearGcTimeout(){z(this,Aa)&&(clearTimeout(z(this,Aa)),se(this,Aa,void 0))}},Aa=new WeakMap,Vk),os,ja,wr,Ta,Tt,mc,Ca,Wr,In,Kk,m5=(Kk=class extends zT{constructor(t){super();me(this,Wr);me(this,os);me(this,ja);me(this,wr);me(this,Ta);me(this,Tt);me(this,mc);me(this,Ca);se(this,Ca,!1),se(this,mc,t.defaultOptions),this.setOptions(t.options),this.observers=[],se(this,Ta,t.client),se(this,wr,z(this,Ta).getQueryCache()),this.queryKey=t.queryKey,this.queryHash=t.queryHash,se(this,os,g5(this.options)),this.state=t.state??z(this,os),this.scheduleGc()}get meta(){return this.options.meta}get promise(){var t;return(t=z(this,Tt))==null?void 0:t.promise}setOptions(t){this.options={...z(this,mc),...t},this.updateGcTime(this.options.gcTime)}optionalRemove(){!this.observers.length&&this.state.fetchStatus==="idle"&&z(this,wr).remove(this)}setData(t,r){const n=o5(this.state.data,t,this.options);return Pt(this,Wr,In).call(this,{data:n,type:"success",dataUpdatedAt:r==null?void 0:r.updatedAt,manual:r==null?void 0:r.manual}),n}setState(t,r){Pt(this,Wr,In).call(this,{type:"setState",state:t,setStateOptions:r})}cancel(t){var n,i;const r=(n=z(this,Tt))==null?void 0:n.promise;return(i=z(this,Tt))==null||i.cancel(t),r?r.then(Fr).catch(Fr):Promise.resolve()}destroy(){super.destroy(),this.cancel({silent:!0})}reset(){this.destroy(),this.setState(z(this,os))}isActive(){return this.observers.some(t=>i5(t.options.enabled,this)!==!1)}isDisabled(){return this.getObserversCount()>0?!this.isActive():this.options.queryFn===Hb||this.state.dataUpdateCount+this.state.errorUpdate
221Count===0}isStatic(){return this.getObserversCount()>0?this.observers.some(t=>Hg(t.options.staleTime,this)==="static"):!1}isStale(){return this.getObserversCount()>0?this.observers.some(t=>t.getCurrentResult().isStale):this.state.data===void 0||this.state.isInvalidated}isStaleByTime(t=0){return this.state.data===void 0?!0:t==="static"?!1:this.state.isInvalidated?!0:!n5(this.state.dataUpdatedAt,t)}onFocus(){var r;const t=this.observers.find(n=>n.shouldFetchOnWindowFocus());t==null||t.refetch({cancelRefetch:!1}),(r=z(this,Tt))==null||r.continue()}onOnline(){var r;const t=this.observers.find(n=>n.shouldFetchOnReconnect());t==null||t.refetch({cancelRefetch:!1}),(r=z(this,Tt))==null||r.continue()}addObserver(t){this.observers.includes(t)||(this.observers.push(t),this.clearGcTimeout(),z(this,wr).notify({type:"observerAdded",query:this,observer:t}))}removeObserver(t){this.observers.includes(t)&&(this.observers=this.observers.filter(r=>r!==t),this.observers.length||(z(this,Tt)&&(z(this,Ca)?z(this,Tt).cancel({revert:!0}):z(this,Tt).cancelRetry()),this.scheduleGc()),z(this,wr).notify({type:"observerRemoved",query:this,observer:t}))}getObserversCount(){return this.observers.length}invalidate(){this.state.isInvalidated||Pt(this,Wr,In).call(this,{type:"invalidate"})}fetch(t,r){var u,d,c;if(this.state.fetchStatus!=="idle"){if(this.state.data!==void 0&&(r!=null&&r.cancelRefetch))this.cancel({silent:!0});else if(z(this,Tt))return z(this,Tt).continueRetry(),z(this,Tt).promise}if(t&&this.setOptions(t),!this.options.queryFn){const f=this.observers.find(h=>h.options.queryFn);f&&this.setOptions(f.options)}const n=new AbortController,i=f=>{Object.defineProperty(f,"signal",{enumerable:!0,get:()=>(se(this,Ca,!0),n.signal)})},a=()=>{const f=DT(this.options,r),v=(()=>{const m={client:z(this,Ta),queryKey:this.queryKey,meta:this.meta};return i(m),m})();return se(this,Ca,!1),this.options.persister?this.options.persister(f,v,this):f(v)},s=(()=>{const f={fetchOptions:r,options:this.options,queryKey:this.queryKey,client:z(this,Ta),state:this.state,fetchFn:a};return i(f),f})();(u=this.options.behavior)==null||u.onFetch(s,this),se(this,ja,this.state),(this.state.fetchStatus==="idle"||this.state.fetchMeta!==((d=s.fetchOptions)==null?void 0:d.meta))&&Pt(this,Wr,In).call(this,{type:"fetch",meta:(c=s.fetchOptions)==null?void 0:c.meta});const l=f=>{var h,v,m,g;Gm(f)&&f.silent||Pt(this,Wr,In).call(this,{type:"error",error:f}),Gm(f)||((v=(h=z(this,wr).config).onError)==null||v.call(h,f,this),(g=(m=z(this,wr).config).onSettled)==null||g.call(m,this.state.data,f,this)),this.scheduleGc()};return se(this,Tt,FT({initialPromise:r==null?void 0:r.initialPromise,fn:s.fetchFn,abort:n.abort.bind(n),onSuccess:f=>{var h,v,m,g;if(f===void 0){l(new Error(`${this.queryHash} data is undefined`));return}try{this.setData(f)}catch(y){l(y);return}(v=(h=z(this,wr).config).onSuccess)==null||v.call(h,f,this),(g=(m=z(this,wr).config).onSettled)==null||g.call(m,f,this.state.error,this),this.scheduleGc()},onError:l,onFail:(f,h)=>{Pt(this,Wr,In).call(this,{type:"failed",failureCount:f,error:h})},onPause:()=>{Pt(this,Wr,In).call(this,{type:"pause"})},onContinue:()=>{Pt(this,Wr,In).call(this,{type:"continue"})},retry:s.options.retry,retryDelay:s.options.retryDelay,networkMode:s.options.networkMode,canRun:()=>!0})),z(this,Tt).start()}},os=new WeakMap,ja=new WeakMap,wr=new WeakMap,Ta=new WeakMap,Tt=new WeakMap,mc=new WeakMap,Ca=new WeakMap,Wr=new WeakSet,In=function(t){const r=n=>{switch(t.type){case"failed":return{...n,fetchFailureCount:t.failureCount,fetchFailureReason:t.error};case"pause":return{...n,fetchStatus:"paused"};case"continue":return{...n,fetchStatus:"fetching"};case"fetch":return{...n,...v5(n.data,this.options),fetchMeta:t.meta??null};case"success":return se(this,ja,void 0),{...n,data:t.data,dataUpdateCount:n.dataUpdateCount+1,dataUpdatedAt:t.dataUpdatedAt??Date.now(),error:null,isInvalidated:!1,status:"success",...!t.manual&&{fetchStatus:"idle",fetchFailureCount:0,fetchFailureReason:null}};case"error":const i=t.error;return Gm(i)&&i.revert&&z(this,ja)?{...z(this,ja),fetchStatus:"idle"}
vendor: 5,105 bytes, line 221
221:{...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,...t.state}}};this.state=r(this.state),Lt.batch(()=>{this.observers.forEach(n=>{n.onQueryUpdate()}),z(this,wr).notify({query:this,type:"updated",action:t})})},Kk);function v5(e,t){return{fetchFailureCount:0,fetchFailureReason:null,fetchStatus:BT(t.networkMode)?"fetching":"paused",...e===void 0&&{error:null,status:"pending"}}}function g5(e){const t=typeof e.initialData=="function"?e.initialData():e.initialData,r=t!==void 0,n=r?typeof e.initialDataUpdatedAt=="function"?e.initialDataUpdatedAt():e.initialDataUpdatedAt:0;return{data:t,dataUpdateCount:0,dataUpdatedAt:r?n??Date.now():0,error:null,errorUpdateCount:0,errorUpdatedAt:0,fetchFailureCount:0,fetchFailureReason:null,fetchMeta:null,isInvalidated:!1,status:r?"success":"pending",fetchStatus:"idle"}}var pn,Gk,y5=(Gk=class extends sp{constructor(t={}){super();me(this,pn);this.config=t,se(this,pn,new Map)}build(t,r,n){const i=r.queryKey,a=r.queryHash??qb(i,r);let o=this.get(a);return o||(o=new m5({client:t,queryKey:i,queryHash:a,options:t.defaultQueryOptions(r),state:n,defaultOptions:t.getQueryDefaults(i)}),this.add(o)),o}add(t){z(this,pn).has(t.queryHash)||(z(this,pn).set(t.queryHash,t),this.notify({type:"added",query:t}))}remove(t){const r=z(this,pn).get(t.queryHash);r&&(t.destroy(),r===t&&z(this,pn).delete(t.queryHash),this.notify({type:"removed",query:t}))}clear(){Lt.batch(()=>{this.getAll().forEach(t=>{this.remove(t)})})}get(t){return z(this,pn).get(t)}getAll(){return[...z(this,pn).values()]}find(t){const r={exact:!0,...t};return this.getAll().find(n=>n_(r,n))}findAll(t={}){const r=this.getAll();return Object.keys(t).length>0?r.filter(n=>n_(t,n)):r}notify(t){Lt.batch(()=>{this.listeners.forEach(r=>{r(t)})})}onFocus(){Lt.batch(()=>{this.getAll().forEach(t=>{t.onFocus()})})}onOnline(){Lt.batch(()=>{this.getAll().forEach(t=>{t.onOnline()})})}},pn=new WeakMap,Gk),mn,Mt,Na,vn,mi,Yk,b5=(Yk=class extends zT{constructor(t){super();me(this,vn);me(this,mn);me(this,Mt);me(this,Na);this.mutationId=t.mutationId,se(this,Mt,t.mutationCache),se(this,mn,[]),this.state=t.state||w5(),this.setOptions(t.options),this.scheduleGc()}setOptions(t){this.options=t,this.updateGcTime(this.options.gcTime)}get meta(){return this.options.meta}addObserver(t){z(this,mn).includes(t)||(z(this,mn).push(t),this.clearGcTimeout(),z(this,Mt).notify({type:"observerAdded",mutation:this,observer:t}))}removeObserver(t){se(this,mn,z(this,mn).filter(r=>r!==t)),this.scheduleGc(),z(this,Mt).notify({type:"observerRemoved",mutation:this,observer:t})}optionalRemove(){z(this,mn).length||(this.state.status==="pending"?this.scheduleGc():z(this,Mt).remove(this))}continue(){var t;return((t=z(this,Na))==null?void 0:t.continue())??this.execute(this.state.variables)}async execute(t){var a,o,s,l,u,d,c,f,h,v,m,g,y,b,w,_,x,S,E,k;const r=()=>{Pt(this,vn,mi).call(this,{type:"continue"})};se(this,Na,FT({fn:()=>this.options.mutationFn?this.options.mutationFn(t):Promise.reject(new Error("No mutationFn found")),onFail:(P,C)=>{Pt(this,vn,mi).call(this,{type:"failed",failureCount:P,error:C})},onPause:()=>{Pt(this,vn,mi).call(this,{type:"pause"})},onContinue:r,retry:this.options.retry??0,retryDelay:this.options.retryDelay,networkMode:this.options.networkMode,canRun:()=>z(this,Mt).canRun(this)}));const n=this.state.status==="pending",i=!z(this,Na).canStart();try{if(n)r();else{Pt(this,vn,mi).call(this,{type:"pending",variables:t,isPaused:i}),await((o=(a=z(this,Mt).config).onMutate)==null?void 0:o.call(a,t,this));const C=await((l=(s=this.options).onMutate)==null?void 0:l.call(s,t));C!==this.state.context&&Pt(this,vn,mi).call(this,{type:"pending",context:C,variables:t,isPaused:i})}const P=await z(this,Na).start();return await((d=(u=z(this,Mt).config).onSuccess)==null?void 0:d.call(u,P,t,this.state.context,this)),await((f=(c=this.options).onSuccess)==null?void 0:f.call(c,P,t,this.state.context)),await((v=(h=z(this,Mt).config).onSettled)==null?void 0:v.call(h,P,null,this.state.variables,this.state.context,this)),await((g=(m=this.options).onSettled)==null?void 0:g.call(m,P,null,t,this.state.context)),Pt(this,vn,mi).call(this,{type:"success",data:P}),P}catch(P){try{throw await((b=(y=z(this,Mt).config).onError)==null?void 0:b.call(y,P,t,this.state.context,this)),await((_=(w=this.options).onError)==null?void 0:_.call(w,P,t,this.state.context)),await((S=(x=z(this,Mt).config).onSettled)==null?void 0:S.call(x,void 0,P,this.state.variables,this.state.context,this)),await((k=(E=this.options).onSettled)==null?void 0:k.call(E,void 0,P,t,this.state.context)),P}finally{Pt(this,vn,mi).call(this,{type:"error",error:P})}}finally{z(this,Mt).runNext(this)}}},mn=new WeakMap,Mt=new WeakMap,Na=new WeakMap,vn=new WeakSet,mi=function(t){const r=n=>{switch(t.type){case"failed":return{...n,failureCount:t.failureCount,failureReason:t.error};case"pause":return{...n,isPaused:!0};case"continue":return{...n,isPaused:!1};
221case"pending":return{...n,context:t.context,data:void 0,failureCount:0,failureReason:null,error:null,isPaused:t.isPaused,status:"pending",variables:t.variables,submittedAt:Date.now()};case"success":return{...n,data:t.data,failureCount:0,failureReason:null,error:null,status:"success",isPaused:!1};case"error":return{...n,data:void 0,error:t.error,failureCount:n.failureCount+1,failureReason:t.error,isPaused:!1,status:"error"}}};this.state=r(this.state),Lt.batch(()=>{z(this,mn).forEach(n=>{n.onMutationUpdate(t)}),z(this,Mt).notify({mutation:this,type:"updated",action:t})})},Yk);function w5(){return{context:void 0,data:void 0,error:null,failureCount:0,failureReason:null,isPaused:!1,status:"idle",variables:void 0,submittedAt:0}}var Bn,qr,vc,Xk,x5=(Xk=class extends sp{constructor(t={}){super();me(this,Bn);me(this,qr);me(this,vc);this.config=t,se(this,Bn,new Set),se(this,qr,new Map),se(this,vc,0)}build(t,r,n){const i=new b5({mutationCache:this,mutationId:++Dc(this,vc)._,options:t.defaultMutationOptions(r),state:n});return this.add(i),i}add(t){z(this,Bn).add(t);const r=od(t);if(typeof r=="string"){const n=z(this,qr).get(r);n?n.push(t):z(this,qr).set(r,[t])}this.notify({type:"added",mutation:t})}remove(t){if(z(this,Bn).delete(t)){const r=od(t);if(typeof r=="string"){const n=z(this,qr).get(r);if(n)if(n.length>1){const i=n.indexOf(t);i!==-1&&n.splice(i,1)}else n[0]===t&&z(this,qr).delete(r)}}this.notify({type:"removed",mutation:t})}canRun(t){const r=od(t);if(typeof r=="string"){const n=z(this,qr).get(r),i=n==null?void 0:n.find(a=>a.state.status==="pending");return!i||i===t}else return!0}runNext(t){var n;const r=od(t);if(typeof r=="string"){const i=(n=z(this,qr).get(r))==null?void 0:n.find(a=>a!==t&&a.state.isPaused);return(i==null?void 0:i.continue())??Promise.resolve()}else return Promise.resolve()}clear(){Lt.batch(()=>
vendor: 4,251 bytes, line 221
221{z(this,Bn).forEach(t=>{this.notify({type:"removed",mutation:t})}),z(this,Bn).clear(),z(this,qr).clear()})}getAll(){return Array.from(z(this,Bn))}find(t){const r={exact:!0,...t};return this.getAll().find(n=>i_(r,n))}findAll(t={}){return this.getAll().filter(r=>i_(t,r))}notify(t){Lt.batch(()=>{this.listeners.forEach(r=>{r(t)})})}resumePausedMutations(){const t=this.getAll().filter(r=>r.state.isPaused);return Lt.batch(()=>Promise.all(t.map(r=>r.continue().catch(Fr))))}},Bn=new WeakMap,qr=new WeakMap,vc=new WeakMap,Xk);function od(e){var t;return(t=e.options.scope)==null?void 0:t.id}function s_(e){return{onFetch:(t,r)=>{var d,c,f,h,v;const n=t.options,i=(f=(c=(d=t.fetchOptions)==null?void 0:d.meta)==null?void 0:c.fetchMore)==null?void 0:f.direction,a=((h=t.state.data)==null?void 0:h.pages)||[],o=((v=t.state.data)==null?void 0:v.pageParams)||[];let s={pages:[],pageParams:[]},l=0;const u=async()=>{let m=!1;const g=w=>{Object.defineProperty(w,"signal",{enumerable:!0,get:()=>(t.signal.aborted?m=!0:t.signal.addEventListener("abort",()=>{m=!0}),t.signal)})},y=DT(t.options,t.fetchOptions),b=async(w,_,x)=>{if(m)return Promise.reject();if(_==null&&w.pages.length)return Promise.resolve(w);const E=(()=>{const N={client:t.client,queryKey:t.queryKey,pageParam:_,direction:x?"backward":"forward",meta:t.options.meta};return g(N),N})(),k=await y(E),{maxPages:P}=t.options,C=x?l5:s5;return{pages:C(w.pages,k,P),pageParams:C(w.pageParams,_,P)}};if(i&&a.length){const w=i==="backward",_=w?_5:l_,x={pages:a,pageParams:o},S=_(n,x);s=await b(x,S,w)}else{const w=e??a.length;do{const _=l===0?o[0]??n.initialPageParam:l_(n,s);if(l>0&&_==null)break;s=await b(s,_),l++}while(l<w)}return s};t.options.persister?t.fetchFn=()=>{var m,g;return(g=(m=t.options).persister)==null?void 0:g.call(m,u,{client:t.client,queryKey:t.queryKey,meta:t.options.meta,signal:t.signal},r)}:t.fetchFn=u}}}function l_(e,{pages:t,pageParams:r}){const n=t.length-1;return t.length>0?e.getNextPageParam(t[n],t,r[n],r):void 0}function _5(e,{pages:t,pageParams:r}){var n;return t.length>0?(n=e.getPreviousPageParam)==null?void 0:n.call(e,t[0],t,r[0],r):void 0}var Ye,Pi,Ai,ss,ls,ji,us,cs,Qk,S5=(Qk=class{constructor(e={}){me(this,Ye);me(this,Pi);me(this,Ai);me(this,ss);me(this,ls);me(this,ji);me(this,us);me(this,cs);se(this,Ye,e.queryCache||new y5),se(this,Pi,e.mutationCache||new x5),se(this,Ai,e.defaultOptions||{}),se(this,ss,new Map),se(this,ls,new Map),se(this,ji,0)}mount(){Dc(this,ji)._++,z(this,ji)===1&&(se(this,us,LT.subscribe(async e=>{e&&(await this.resumePausedMutations(),z(this,Ye).onFocus())})),se(this,cs,Pf.subscribe(async e=>{e&&(await this.resumePausedMutations(),z(this,Ye).onOnline())})))}unmount(){var e,t;Dc(this,ji)._--,z(this,ji)===0&&((e=z(this,us))==null||e.call(this),se(this,us,void 0),(t=z(this,cs))==null||t.call(this),se(this,cs,void 0))}isFetching(e){return z(this,Ye).findAll({...e,fetchStatus:"fetching"}).length}isMutating(e){return z(this,Pi).findAll({...e,status:"pending"}).length}getQueryData(e){var r;const t=this.defaultQueryOptions({queryKey:e});return(r=z(this,Ye).get(t.queryHash))==null?void 0:r.state.data}ensureQueryData(e){const t=this.defaultQueryOptions(e),r=z(this,Ye).build(this,t),n=r.state.data;return n===void 0?this.fetchQuery(e):(e.revalidateIfStale&&r.isStaleByTime(Hg(t.staleTime,r))&&this.prefetchQuery(t),Promise.resolve(n))}getQueriesData(e){return z(this,Ye).findAll(e).map(({queryKey:t,state:r})=>{const n=r.data;return[t,n]})}setQueryData(e,t,r){const n=this.defaultQueryOptions({queryKey:e}),i=z(this,Ye).get(n.queryHash),a=i==null?void 0:i.state.data,o=t5(t,a);if(o!==void 0)return z(this,Ye).build(this,n).setData(o,{...r,manual:!0})}setQueriesData(e,t,r){return Lt.batch(()=>z(this,Ye).findAll(e).map(({queryKey:n})=>[n,this.setQueryData(n,t,r)]))}getQueryState(e){var r;const t=this.defaultQueryOptions({queryKey:e});return(r=z(this,Ye).get(t.queryHash))==null?void 0:r.state}removeQueries(e){const t=z(this,Ye);Lt.batch(()=>{t.findAll(e).forEach(r=>{t.remove(r)})})}resetQueries(e,t){const r=z(this,Ye);return Lt.batch(()=>(r.findAll(e).forEach(n=>{n.reset()}),this.refetchQueries({type:"active",...e},t)))}cancelQueries(e,t={}){const r={revert:!0,...t},n=Lt.batch(()=>z(this,Ye).findAll(e).map(i=>i.cancel(r)));
221return Promise.all(n).then(Fr).catch(Fr)}invalidateQueries(e,t={}){return Lt.batch(()=>(z(this,Ye).findAll(e).forEach(r=>{r.invalidate()}),(e==null?void 0:e.refetchType)==="none"?Promise.resolve():this.refetchQueries({...e,type:(e==null?void 0:e.refetchType)??(e==null?void 0:e.type)??"active"},t)))}refetchQueries(e,t={}){const r={...t,cancelRefetch:t.cancelRefetch??!0},n=Lt.batch(()=>z(this,Ye).findAll(e).filter(i=>!i.isDisabled()&&!i.isStatic()).map(i=>{let a=i.fetch(void 0,r);return r.throwOnError||(a=a.catch(Fr)),i.state.fetchStatus==="paused"?Promise.resolve():a}));return Promise.all(n).then(Fr)}fetchQuery(e){const t=this.defaultQueryOptions(e);t.retry===void 0&&(t.retry=!1);const r=z(this,Ye).build(this,t);return r.isStaleByTime(Hg(t.staleTime,r))?r.fetch(t):Promise.resolve(r.state.data)}prefetchQuery(e){return this.fetchQuery(e).then(Fr).catch(Fr)}fetchInfiniteQuery(e){return e.behavior=s_(e.pages),this.fetchQuery(e)}prefetchInfiniteQuery(e){return this.fetchInfiniteQuery(e).then(Fr).catch(Fr)}ensureInfiniteQueryData(e){return e.behavior=s_(e.pages),this.ensureQueryData(e)}resumePausedMutations(){return Pf.isOnline()?z(this,Pi).resumePausedMutations():Promise.resolve()}getQueryCache(){return z(this,Ye)}getMutationCache(){return z(this,Pi)}getDefaultOptions(){return z(this,Ai)}setDefaultOptions(e){se(this,Ai,e)}setQueryDefaults(e,t){z(this,ss).set(xu(e),{queryKey:e,defaultOptions:t})}getQueryDefaults(e){const t=[...z(this,ss).values()],r={};return t.forEach(n=>{_u(e,n.queryKey)&&Object.assign(r,n.defaultOptions)}),r}setMutationDefaults(e,t){z(this,ls).set(xu(e),{mutationKey:e,defaultOptions:t})}getMutationDefaults(e){const t=[...z(this,ls).values()],r={};return t.forEach(n=>{_u(e,n.mutationKey)&&Object.assign(r,n.defaultOptions)}),r}defaultQueryOptions(e){if(e._defaulted)return e;const t={...z(this,Ai).queries,...this.getQueryDefaults(e.queryKey),...e,_defaulted:!0};return t.queryHash||(t.queryHash=qb(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===Hb&&(t.enabled=!1),t}defaultMutationOptions(e){return e!=null&&e._defaulted?e:{...z(this,Ai).mutations,...(e==null?void 0:e.mutationKey)&&this.getMutationDefaults(e.mutationKey),...e,_defaulted:!0}}clear(){z(this,Ye).clear(),z(this,Pi).clear()}},Ye=new WeakMap,Pi=new WeakMap,Ai=new WeakMap,ss=new WeakMap,ls=new WeakMap,ji=new WeakMap,us=new WeakMap,cs=new WeakMap,Qk),O5=O.createContext(void 0),E5=({client:e,children:t})=>(O.useEffect(()=>(e.mount(),()=>{e.unmount()}),[e]),p.jsx(O5.Provider,{value:e,children:t}));/** 222 * @remix-run/router v1.23.0 223 * 224 * Copyright (c) Remix Software Inc. 225 * 226 * This source code is licensed under the MIT license found in the 227 * LICENSE.md file in the root directory of this source tree. 228 * 229 * @license MIT 230 */function Su(){return Su=Object.assign?Object.assign.bind():function(e){for(var t=1;t<arguments.length;t++){var r=arguments[t];for(var n in r)Object.prototype.hasOwnProperty.call(r,n)&&(e[n]=r[n])}return e},Su.apply(this,arguments)}var Ni;(function(e){e.Pop="POP",e.Push="PUSH",e.Replace="REPLACE"})(Ni||(Ni={}));const u_="popstate";function k5(e){e===void 0&&(e={});function t(n,i){let{pathname:a,search:o,hash:s}=n.location;return Kg("",{pathname:a,search:o,hash:s},i.state&&i.state.usr||null,i.state&&i.state.key||"default")}function r(n,i){return typeof i=="string"?i:qT(i)}return A5(t,r,null,e)}function dt(e,t){if(e===!1||e===null||typeof e>"u")throw new Error(t)}function WT(e,t){if(!e){typeof console<"u"&&console.warn(t);try{throw new Error(t)}catch{}}}function P5(){return Math.random().toString(36).substr(2,8)}function c_(e,t){return{usr:e.state,key:e.key,idx:t}}function Kg(e,t,r,n){return r===void 0&&(r=null),Su({pathname:typeof e=="string"?e:e.pathname,search:"",hash:""},typeof t=="string"?Xs(t):t,{state:r,key:t&&t.key||n||P5()})}function qT(e){let{pathname:t="/",search:r="",hash:n=""}=e;return r&&r!=="?"&&(t+=r.charAt(0)==="?"?r:"?"+r),n&&n!=="#"&&(t+=n.charAt(0)==="#"?n:"#"+n),t}function Xs(e){let t={};if(e){let r=e.indexOf("#");r>=0&&(t.hash=e.substr(r),e=e.substr(0,r));let n=e.indexOf("?");n>=0&&(t.search=e.substr(n),e=e.substr(0,n)),e&&(t.pathname=e)}return t}function A5(e,t,r,n){n===void 0&&(n={});let{window:i=document.defaultView,v5Compat:a=!1}=n,o=i.history,s=Ni.Pop,l=null,u=d();u==null&&(u=0,o.replaceState(Su({},o.state,{idx:u}),""));function d(){return(o.state||{idx:null}).idx}function c(){s=Ni.Pop;let g=d(),y=g==null?null:g-u;u=g,l&&l({action:s,location:m.location,delta:y})}function f(g,y){s=Ni.Push;let b=Kg(m.location,g,y);u=d()+1;let w=c_(b,u),_=m.createHref(b);try{o.pushState(w,"",_)}
vendor: 3,324 bytes, line 230
230catch(x){if(x instanceof DOMException&&x.name==="DataCloneError")throw x;i.location.assign(_)}a&&l&&l({action:s,location:m.location,delta:1})}function h(g,y){s=Ni.Replace;let b=Kg(m.location,g,y);u=d();let w=c_(b,u),_=m.createHref(b);o.replaceState(w,"",_),a&&l&&l({action:s,location:m.location,delta:0})}function v(g){let y=i.location.origin!=="null"?i.location.origin:i.location.href,b=typeof g=="string"?g:qT(g);return b=b.replace(/ $/,"%20"),dt(y,"No window.location.(origin|href) available to create URL for href: "+b),new URL(b,y)}let m={get action(){return s},get location(){return e(i,o)},listen(g){if(l)throw new Error("A history only accepts one active listener");return i.addEventListener(u_,c),l=g,()=>{i.removeEventListener(u_,c),l=null}},createHref(g){return t(i,g)},createURL:v,encodeLocation(g){let y=v(g);return{pathname:y.pathname,search:y.search,hash:y.hash}},push:f,replace:h,go(g){return o.go(g)}};return m}var d_;(function(e){e.data="data",e.deferred="deferred",e.redirect="redirect",e.error="error"})(d_||(d_={}));function j5(e,t,r){return r===void 0&&(r="/"),T5(e,t,r,!1)}function T5(e,t,r,n){let i=typeof t=="string"?Xs(t):t,a=KT(i.pathname||"/",r);if(a==null)return null;let o=HT(e);C5(o);let s=null;for(let l=0;s==null&&l<o.length;++l){let u=z5(a);s=U5(o[l],u,n)}return s}function HT(e,t,r,n){t===void 0&&(t=[]),r===void 0&&(r=[]),n===void 0&&(n="");let i=(a,o,s)=>{let l={relativePath:s===void 0?a.path||"":s,caseSensitive:a.caseSensitive===!0,childrenIndex:o,route:a};l.relativePath.startsWith("/")&&(dt(l.relativePath.startsWith(n),'Absolute route path "'+l.relativePath+'" nested under path '+('"'+n+'" is not valid. An absolute child route path ')+"must start with the combined path of all its parent routes."),l.relativePath=l.relativePath.slice(n.length));let u=Ma([n,l.relativePath]),d=r.concat(l);a.children&&a.children.length>0&&(dt(a.index!==!0,"Index routes must not have child routes. Please remove "+('all child routes from route path "'+u+'".')),HT(a.children,t,d,u)),!(a.path==null&&!a.index)&&t.push({path:u,score:L5(u,a.index),routesMeta:d})};return e.forEach((a,o)=>{var s;if(a.path===""||!((s=a.path)!=null&&s.includes("?")))i(a,o);else for(let l of VT(a.path))i(a,o,l)}),t}function VT(e){let t=e.split("/");if(t.length===0)return[];let[r,...n]=t,i=r.endsWith("?"),a=r.replace(/\?$/,"");if(n.length===0)return i?[a,""]:[a];let o=VT(n.join("/")),s=[];return s.push(...o.map(l=>l===""?a:[a,l].join("/"))),i&&s.push(...o),s.map(l=>e.startsWith("/")&&l===""?"/":l)}function C5(e){e.sort((t,r)=>t.score!==r.score?r.score-t.score:B5(t.routesMeta.map(n=>n.childrenIndex),r.routesMeta.map(n=>n.childrenIndex)))}const N5=/^:[\w-]+$/,$5=3,R5=2,I5=1,M5=10,D5=-2,f_=e=>e==="*";function L5(e,t){let r=e.split("/"),n=r.length;return r.some(f_)&&(n+=D5),t&&(n+=R5),r.filter(i=>!f_(i)).reduce((i,a)=>i+(N5.test(a)?$5:a===""?I5:M5),n)}function B5(e,t){return e.length===t.length&&e.slice(0,-1).every((n,i)=>n===t[i])?e[e.length-1]-t[t.length-1]:0}function U5(e,t,r){let{routesMeta:n}=e,i={},a="/",o=[];for(let s=0;s<n.length;++s){let l=n[s],u=s===n.length-1,d=a==="/"?t:t.slice(a.length)||"/",c=h_({path:l.relativePath,caseSensitive:l.caseSensitive,end:u},d),f=l.route;if(!c&&u&&r&&!n[n.length-1].route.index&&(c=h_({path:l.relativePath,caseSensitive:l.caseSensitive,end:!1},d)),!c)return null;
vendor: 9,017 bytes, lines 230-239
230Object.assign(i,c.params),o.push({params:i,pathname:Ma([a,c.pathname]),pathnameBase:G5(Ma([a,c.pathnameBase])),route:f}),c.pathnameBase!=="/"&&(a=Ma([a,c.pathnameBase]))}return o}function h_(e,t){typeof e=="string"&&(e={path:e,caseSensitive:!1,end:!0});let[r,n]=F5(e.path,e.caseSensitive,e.end),i=t.match(r);if(!i)return null;let a=i[0],o=a.replace(/(.)\/+$/,"$1"),s=i.slice(1);return{params:n.reduce((u,d,c)=>{let{paramName:f,isOptional:h}=d;if(f==="*"){let m=s[c]||"";o=a.slice(0,a.length-m.length).replace(/(.)\/+$/,"$1")}const v=s[c];return h&&!v?u[f]=void 0:u[f]=(v||"").replace(/%2F/g,"/"),u},{}),pathname:a,pathnameBase:o,pattern:e}}function F5(e,t,r){t===void 0&&(t=!1),r===void 0&&(r=!0),WT(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 n=[],i="^"+e.replace(/\/*\*?$/,"").replace(/^\/*/,"/").replace(/[\\.*+^${}|()[\]]/g,"\\$&").replace(/\/:([\w-]+)(\?)?/g,(o,s,l)=>(n.push({paramName:s,isOptional:l!=null}),l?"/?([^\\/]+)?":"/([^\\/]+)"));return e.endsWith("*")?(n.push({paramName:"*"}),i+=e==="*"||e==="/*"?"(.*)$":"(?:\\/(.+)|\\/*)$"):r?i+="\\/*$":e!==""&&e!=="/"&&(i+="(?:(?=\\/|$))"),[new RegExp(i,t?void 0:"i"),n]}function z5(e){try{return e.split("/").map(t=>decodeURIComponent(t).replace(/\//g,"%2F")).join("/")}catch(t){return WT(!1,'The URL path "'+e+'" could not be decoded because it is is a malformed URL segment. This is probably due to a bad percent '+("encoding ("+t+").")),e}}function KT(e,t){if(t==="/")return e;if(!e.toLowerCase().startsWith(t.toLowerCase()))return null;let r=t.endsWith("/")?t.length-1:t.length,n=e.charAt(r);return n&&n!=="/"?null:e.slice(r)||"/"}function W5(e,t){t===void 0&&(t="/");let{pathname:r,search:n="",hash:i=""}=typeof e=="string"?Xs(e):e;return{pathname:r?r.startsWith("/")?r:q5(r,t):t,search:Y5(n),hash:X5(i)}}function q5(e,t){let r=t.replace(/\/+$/,"").split("/");return e.split("/").forEach(i=>{i===".."?r.length>1&&r.pop():i!=="."&&r.push(i)}),r.length>1?r.join("/"):"/"}function Ym(e,t,r,n){return"Cannot include a '"+e+"' character in a manually specified "+("`to."+t+"` field ["+JSON.stringify(n)+"]. Please separate it out to the ")+("`to."+r+"` field. Alternatively you may provide the full path as ")+'a string in <Link to="..."> and the router will parse it for you.'}function H5(e){return e.filter((t,r)=>r===0||t.route.path&&t.route.path.length>0)}function V5(e,t){let r=H5(e);return t?r.map((n,i)=>i===r.length-1?n.pathname:n.pathnameBase):r.map(n=>n.pathnameBase)}function K5(e,t,r,n){n===void 0&&(n=!1);let i;typeof e=="string"?i=Xs(e):(i=Su({},e),dt(!i.pathname||!i.pathname.includes("?"),Ym("?","pathname","search",i)),dt(!i.pathname||!i.pathname.includes("#"),Ym("#","pathname","hash",i)),dt(!i.search||!i.search.includes("#"),Ym("#","search","hash",i)));let a=e===""||i.pathname==="",o=a?"/":i.pathname,s;if(o==null)s=r;else{let c=t.length-1;if(!n&&o.startsWith("..")){let f=o.split("/");for(;f[0]==="..";)f.shift(),c-=1;i.pathname=f.join("/")}s=c>=0?t[c]:"/"}let l=W5(i,s),u=o&&o!=="/"&&o.endsWith("/"),d=(a||o===".")&&r.endsWith("/");return!l.pathname.endsWith("/")&&(u||d)&&(l.pathname+="/"),l}const Ma=e=>e.join("/").replace(/\/\/+/g,"/"),G5=e=>e.replace(/\/+$/,"").replace(/^\/*/,"/"),Y5=e=>!e||e==="?"?"":e.startsWith("?")?e:"?"+e,X5=e=>!e||e==="#"?"":e.startsWith("#")?e:"#"+e;function Q5(e){return e!=null&&typeof e.status=="number"&&typeof e.statusText=="string"&&typeof e.internal=="boolean"&&"data"in e}const GT=["post","put","patch","delete"];new Set(GT);const J5=["get",...GT];new Set(J5);/** 231 * React Router v6.30.1 232 * 233 * Copyright (c) Remix Software Inc. 234 * 235 * This source code is licensed under the MIT license found in the 236 * LICENSE.md file in the root directory of this source tree. 237 * 238 * @license MIT 239 */function Ou(){return Ou=Object.assign?Object.assign.bind():function(e){for(var t=1;t<arguments.length;t++){var r=arguments[t];for(var n in r)Object.prototype.hasOwnProperty.call(r,n)&&(e[n]=r[n])}return e},Ou.apply(this,arguments)}const Vb=O.createContext(null),Z5=O.createContext(null),up=O.createContext(null),cp=O.createContext(null),to=O.createContext({outlet:null,matches:[],isDataRoute:!1}),YT=O.createContext(null);function dp(){return O.useContext(cp)!=null}function fp(){return dp()||dt(!1),O.useContext(cp).location}function XT(e){O.useContext(up).static||O.useLayoutEffect(e)}function ea(){let{isDataRoute:e}=O.useContext(to);return e?hU():eU()}function eU(){dp()||dt(!1);let e=O.useContext(Vb),{basename:t,future:r,navigator:n}=O.useContext(up),{matches:i}=O.useContext(to),{pathname:a}=fp(),o=JSON.stringify(V5(i,r.v7_relativeSplatPath)),s=O.useRef(!1);return XT(()=>{s.current=!0}),O.useCallback(function(u,d){if(d===void 0&&(d={}),!s.current)return;if(typeof u=="number"){n.go(u);return}let c=K5(u,JSON.parse(o),a,d.relative==="path");e==null&&t!=="/"&&(c.pathname=c.pathname==="/"?t:Ma([t,c.pathname])),(d.replace?n.replace:n.push)(c,d.state,d)},[t,n,o,a,e])}function tU(){let{matches:e}=O.useContext(to),t=e[e.length-1];return t?t.params:{}}function rU(e,t){return nU(e,t)}function nU(e,t,r,n){dp()||dt(!1);let{navigator:i}=O.useContext(up),{matches:a}=O.useContext(to),o=a[a.length-1],s=o?o.params:{};o&&o.pathname;let l=o?o.pathnameBase:"/";o&&o.route;let u=fp(),d;if(t){var c;let g=typeof t=="string"?Xs(t):t;l==="/"||(c=g.pathname)!=null&&c.startsWith(l)||dt(!1),d=g}else d=u;let f=d.pathname||"/",h=f;if(l!=="/"){let g=l.replace(/^\//,"").split("/");h="/"+f.replace(/^\//,"").split("/").slice(g.length).join("/")}let v=j5(e,{pathname:h}),m=lU(v&&v.map(g=>Object.assign({},g,{params:Object.assign({},s,g.params),pathname:Ma([l,i.encodeLocation?i.encodeLocation(g.pathname).pathname:g.pathname]),pathnameBase:g.pathnameBase==="/"?l:Ma([l,i.encodeLocation?i.encodeLocation(g.pathnameBase).pathname:g.pathnameBase])})),a,r,n);return t&&m?O.createElement(cp.Provider,{value:{location:Ou({pathname:"/",search:"",hash:"",state:null,key:"default"},d),navigationType:Ni.Pop}},m):m}function iU(){let e=fU(),t=Q5(e)?e.status+" "+e.statusText:e instanceof Error?e.message:JSON.stringify(e),r=e instanceof Error?e.stack:null,i={padding:"0.5rem",backgroundColor:"rgba(200,200,200, 0.5)"};return O.createElement(O.Fragment,null,O.createElement("h2",null,"Unexpected Application Error!"),O.createElement("h3",{style:{fontStyle:"italic"}},t),r?O.createElement("pre",{style:i},r):null,null)}const aU=O.createElement(iU,null);class oU extends O.Component{constructor(t){super(t),this.state={location:t.location,revalidation:t.revalidation,error:t.error}}static getDerivedStateFromError(t){return{error:t}}static getDerivedStateFromProps(t,r){return r.location!==t.location||r.revalidation!=="idle"&&t.revalidation==="idle"?{error:t.error,location:t.location,revalidation:t.revalidation}:{error:t.error!==void 0?t.error:r.error,location:r.location,revalidation:t.revalidation||r.revalidation}}componentDidCatch(t,r){console.error("React Router caught the following error during render",t,r)}render(){return this.state.error!==void 0?O.createElement(to.Provider,{value:this.props.routeContext},O.createElement(YT.Provider,{value:this.state.error,children:this.props.component})):this.props.children}}function sU(e){let{routeContext:t,match:r,children:n}=e,i=O.useContext(Vb);return i&&i.static&&i.staticContext&&(r.route.errorElement||r.route.ErrorBoundary)&&(i.staticContext._deepestRenderedBoundaryId=r.route.id),O.createElement(to.Provider,{value:t},n)}function lU(e,t,r,n){var i;if(t===void 0&&(t=[]),r===void 0&&(r=null),n===void 0&&(n=null),e==null){var a;if(!r)return null;if(r.errors)e=r.matches;else if((a=n)!=null&&a.v7_partialHydration&&t.length===0&&!r.initialized&&r.matches.length>0)e=r.matches;else return null}let o=e,s=(i=r)==null?void 0:i.errors;if(s!=null){let d=o.findIndex(c=>c.route.id&&(s==null?void 0:s[c.route.id])!==void 0);d>=0||dt(!1),o=o.slice(0,Math.min(o.length,d+1))}let l=!1,u=-1;if(r&&n&&n.v7_partialHydration)for(let d=0;d<o.length;d++){let c=o[d];if((c.route.HydrateFallback||c.route.hydrateFallbackElement)&&(u=d),c.route.id){let{loaderData:f,errors:h}=r,v=c.route.loader&&f[c.route.id]===void 0&&(!h||h[c.route.id]===void 0);if(c.route.lazy||v){l=!0,u>=0?o=o.slice(0,u+1):o=[o[0]];break}}}return o.reduceRight((d,c,f)=>{let h,v=!1,m=null,g=null;r&&(h=s&&c.route.id?s[c.route.id]:void 0,m=c.route.errorElement||aU,l&&(u<0&&f===0?(v=!0,g=null):u===f&&(v=!0,g=c.route.hydrateFallbackElement||null)));let y=t.concat(o.slice(0,f+1)),b=()=>{let w;return h?w=m:v?w=g:c.route.Component?w=O.createElement(c.route.Component,null):c.route.element?w=c.route.element:w=d,O.createElement(sU,{match:c,routeContext:{outlet:d,matches:y,isDataRoute:r!=null},children:w})};return r&&(c.route.ErrorBoundary||c.route.errorElement||f===0)?O.createElement(oU,{location:r.location,revalidation:r.revalidation,component:m,error:h,children:b(),routeC
239ontext:{outlet:null,matches:y,isDataRoute:!0}}):b()},null)}var QT=function(e){return e.UseBlocker="useBlocker",e.UseRevalidator="useRevalidator",e.UseNavigateStable="useNavigate",e}(QT||{}),Af=function(e){return e.UseBlocker="useBlocker",e.UseLoaderData="useLoaderData",e.UseActionData="useActionData",e.UseRouteError="useRouteError",e.UseNavigation="useNavigation",e.UseRouteLoaderData="useRouteLoaderData",e.UseMatches="useMatches",e.UseRevalidator="useRevalidator",e.UseNavigateStable="useNavigate",e.UseRouteId="useRouteId",e}(Af||{});function uU(e){let t=O.useContext(Vb);return t||dt(!1),t}function cU(e){let t=O.useContext(Z5);return t||dt(!1),t}function dU(e){let t=O.useContext(to);return t||dt(!1),t}function JT(e){let t=dU(),r=t.matches[t.matches.length-1];return r.route.id||dt(!1),r.route.id}function fU(){var e;let t=O.useContext(YT),r=cU(Af.UseRouteError),n=JT(Af.UseRouteError);return t!==void 0?t:(e=r.errors)==null?void 0:e[n]}function hU(){let{router:e}=uU(QT.UseNavigateStable),t=JT(Af.UseNavigateStable),r=O.useRef(!1);return XT(()=>{r.current=!0}),O.useCallback(function(i,a){a===void 0&&(a={}),r.current&&(typeof i=="number"?e.navigate(i):e.navigate(i,Ou({fromRouteId:t},a)))},[e,t])}function pU(e,t){e==null||e.v7_startTransition,e==null||e.v7_relativeSplatPath}function vi(e){dt(!1)}function mU(e){let{basename:t="/",children:r=null,location:n,navigationType:i=Ni.Pop,navigator:a,static:o=!1,future:s}=e;dp()&&dt(!1);let l=t.replace(/^\/*/,"/"),u=O.useMemo(()=>({basename:l,navigator:a,static:o,future:Ou({v7_relativeSplatPath:!1},s)}),[l,s,a,o]);typeof n=="string"&&(n=Xs(n));let{pathname:d="/",search:c="",hash:f="",state:h=null,key:v="default"}=n,m=O.useMemo(()=>{let g=KT(d,l);return g==null?null:{location:{pathname:g,search:c,hash:f,state:h,key:v},navigationType:i}},[l,d,c,f,h,v,i]);return m==null?null:O.createElement(up.Provider,{value:u},O.createElement(cp.Provider,{children:r,value:m}))}function vU(e){let{children:t,location:r}=e;return rU(Gg(t),r)}new Promise(()=>{});function Gg(e,t){t===void 0&&(t=[]);let r=[];return O.Children.forEach(e,(n,i)=>{if(!O.isValidElement(n))return;let a=[...t,i];if(n.type===O.Fragment){r.push.apply(r,Gg(n.props.children,a));return}n.type!==vi&&dt(!1),!n.props.index||!n.props.children||dt(!1);let o={id:n.props.id||a.join("-"),caseSensitive:n.props.caseSensitive,element:n.props.element,Component:n.props.Component,index:n.props.index,path:n.props.path,loader:n.props.loader,action:n.props.action,errorElement:n.props.errorElement,ErrorBoundary:n.props.ErrorBoundary,hasErrorBoundary:n.props.ErrorBoundary!=null||n.props.errorElement!=null,shouldRevalidate:n.props.shouldRevalidate,handle:n.props.handle,lazy:n.props.lazy};n.props.children&&(o.children=Gg(n.props.children,a)),r.push(o)}),r}/** 240 * React Router DOM v6.30.1 241 * 242 * Copyright (c) Remix Software Inc. 243 * 244 * This source code is licensed under the MIT license found in the 245 * LICENSE.md file in the root directory of this source tree. 246 * 247 * @license MIT 248 */function Yg(e){return e===void 0&&(e=""),new URLSearchParams(typeof e=="string"||Array.isArray(e)||e instanceof URLSearchParams?e:Object.keys(e).reduce((t,r)=>{let n=e[r];return t.concat(Array.isArray(n)?n.map(i=>[r,i]):[[r,n]])},[]))}function gU(e,t){let r=Yg(e);return t&&t.forEach((n,i)=>{r.has(i)||t.getAll(i).forEach(a=>{r.append(i,a)})}),r}const yU="6";try{window.__reactRouterVersion=yU}catch{}const bU="startTransition",p_=R0[bU];function wU(e){let{basename:t,children:r,future:n,window:i}=e,a=O.useRef();a.current==null&&(a.current=k5({window:i,v5Compat:!0}));let o=a.current,[s,l]=O.useState({action:o.action,location:o.location}),{v7_startTransition:u}=n||{},d=O.useCallback(c=>{u&&p_?p_(()=>l(c)):l(c)},[l,u]);return O.useLayoutEffect(()=>o.listen(d),[o,d]),O.useEffect(()=>pU(n),[n]),O.createElement(mU,{basename:t,children:r,location:s.location,navigationType:s.action,navigator:o,future:n})}var m_;(function(e){e.UseScrollRestoration="useScrollRestoration",e.UseSubmit="useSubmit",e.UseSubmitFetcher="useSubmitFetcher",e.UseFetcher="useFetcher",e.useViewTransitionState="useViewTransitionState"})(m_||(m_={}));var v_;(function(e){e.UseFetcher="useFetcher",e.UseFetchers="useFetchers",e.UseScrollRestoration="useScrollRestoration"})(v_||(v_={}));function xU(e){let t=O.useRef(Yg(e)),r=O.useRef(!1),n=fp(),i=O.useMemo(()=>gU(n.search,r.current?null:t.current),[n.search]),a=ea(),o=O.useCallback((s,l)=>{const u=Yg(typeof s=="function"?s(i):s);r.current=!0,a("?"+u,l)},[a,i]);return[i,o]}const _U=Ab("inline-flex items-center justify-center gap-2 whitespace-nowrap rounded-md text-sm font-medium ring-offset-background transition-colors focus-visible:outline-none focus-visible:ring-2 focus-visible:ring-ring focus-visible:ring-offset-2 disabled:pointer-events-none disabled:opacity-50 [&_svg]:pointer-events-none [&_svg]:size-4 [&_svg]:shrink-0",{variants:{variant:{default:"bg-primary text-primary-foreground hover:bg-primary/90",destructive:"bg-destructive text-destructive-foreground hover:bg-destructive/90",outline:"border border-input bg-background hover:bg-accent hover:text-accent-foreground",secondary:"bg-secondary text-secondary-foreground hover:bg-secondary/80",ghost:"hover:bg-accent hover:text-accent-foreground",link:"text-primary underline-offset-4 hover:underline"},size:{default:"h-10 px-4 py-2",sm:"h-9 rounded-md px-3",lg:"h-11 rounded-md px-8",icon:"h-10 w-10"}},defaultVariants:{variant:"default",size:"default"}}),je=O.forwardRef(({className:e,variant:t,size:r,asChild:n=!1,...i},a)=>{const o=n?KD:"button";return p.jsx(o,{className:Ne(_U({variant:t,size:r,className:e})),ref:a,...i})});
248je.displayName="Button";const Kt=O.forwardRef(({className:e,type:t,...r},n)=>p.jsx("input",{type:t,className:Ne("flex h-10 w-full rounded-md border border-input bg-background px-3 py-2 text-base ring-offset-background file:border-0 file:bg-transparent file:text-sm file:font-medium file:text-foreground placeholder:text-muted-foreground focus-visible:outline-none focus-visible:ring-2 focus-visible:ring-ring focus-visible:ring-offset-2 disabled:cursor-not-allowed disabled:opacity-50 md:text-sm",e),ref:n,...r}));Kt.displayName="Input";const dr=O.forwardRef(({className:e,...t},r)=>p.jsx("div",{ref:r,className:Ne("rounded-lg border bg-card text-card-foreground shadow-sm",e),...t}));dr.displayName="Card";const Zr=O.forwardRef(({className:e,...t},r)=>p.jsx("div",{ref:r,className:Ne("flex flex-col space-y-1.5 p-6",e),...t}));Zr.displayName="CardHeader";const en=O.forwardRef(({className:e,...t},r)=>p.jsx("h3",{ref:r,className:Ne("text-2xl font-semibold leading-none tracking-tight",e),...t}));en.displayName="CardTitle";const Kb=O.forwardRef(({className:e,...t},r)=>p.jsx("p",{ref:r,className:Ne("text-sm text-muted-foreground",e),...t}));Kb.displayName="CardDescription";const fr=O.forwardRef(({className:e,...t},r)=>p.jsx("div",{ref:r,className:Ne("p-6 pt-0",e),...t}));fr.displayName="CardContent";const SU=O.forwardRef(({className:e,...t},r)=>p.jsx("div",{ref:r,className:Ne("flex items-center p-6 pt-0",e),...t}));SU.displayName="CardFooter";var yn=function(){return yn=Object.assign||function(t){for(var r,n=1,i=arguments.length;n<i;n++){r=arguments[n];for(var a in r)Object.prototype.hasOwnProperty.call(r,a)&&(t[a]=r[a])}return t},yn.apply(this,arguments)};function Qs(e,t){var r={};for(var n in e)Object.prototype.hasOwnProperty.call(e,n)&&t.indexOf(n)<0&&(r[n]=e[n]);if(e!=null&&typeof Object.getOwnPropertySymbols=="function")for(var i=0,n=Object.getOwnPropertySymbols(e);i<n.length;i++)t.indexOf(n[i])<0&&Object.prototype.propertyIsEnumerable.call(e,n[i])&&(r[n[i]]=e[n[i]]);return r}function OU(e,t,r,n){function i(a){return a instanceof r?a:new r(function(o){o(a)})}return new(r||(r=Promise))(function(a,o){function s(d){try{u(n.next(d))}catch(c){o(c)}}function l(d){try{u(n.throw(d))}catch(c){o(c)}}function u(d){d.done?a(d.value):i(d.value).then(s,l)}u((n=n.apply(e,t||[])).next())})}function EU(e,t,r){if(r||arguments.length===2)for(var n=0,i=t.length,a;n<i;n++)(a||!(n in t))&&(a||(a=Array.prototype.slice.call(t,0,n)),a[n]=t[n]);return e.concat(a||Array.prototype.slice.call(t))}const kU=e=>e?(...t)=>e(...t):(...t)=>fetch(...t);class Gb extends Error{constructor(t,r="FunctionsError",n){super(t),this.name=r,this.context=n}}class PU extends Gb{constructor(t){super("Failed to send a request to the Edge Function","FunctionsFetchError",t)}}class g_ extends Gb{constructor(t){super("Relay Error invoking the Edge Function","FunctionsRelayError",t)}}class y_ extends Gb{constructor(t){super("Edge Function returned a non-2xx status code","FunctionsHttpError",t)}}var Xg;(function(e){e.Any="any",e.ApNortheast1="ap-northeast-1",e.ApNortheast2="ap-northeast-2",e.ApSouth1="ap-south-1",e.ApSoutheast1="ap-southeast-1",e.ApSoutheast2="ap-southeast-2",e.CaCentral1="ca-central-1",e.EuCentral1="eu-central-1",e.EuWest1="eu-west-1",e.EuWest2="eu-west-2",e.EuWest3="eu-west-3",e.SaEast1="sa-east-1",e.UsEast1="us-east-1",e.UsWest1="us-west-1",e.UsWest2="us-west-2"})(Xg||(Xg={}));class AU{constructor(t,{headers:r={},customFetch:n,region:i=Xg.Any}={}){this.url=t,this.headers=r,this.region=i,this.fetch=kU(n)}setAuth(t){this.headers.Authorization=`Bearer ${t}`}invoke(t){return OU(this,arguments,void 0,function*(r,n={}){var i;let a,o;try{const{headers:s,method:l,body:u,signal:d,timeout:c}=n;let f={},{region:h}=n;h||(h=this.region);const v=new URL(`${this.url}/${r}`);h&&h!=="any"&&(f["x-region"]=h,v.searchParams.set("forceFunctionRegion",h));let m;u&&(s&&!Object.prototype.hasOwnProperty.call(s,"Content-Type")||!s)?typeof Blob<"u"&&u instanceof Blob||u instanceof ArrayBuffer?(f["Content-Type"]="application/octet-stream",m=u):typeof u=="string"?(f["Content-Type"]="text/plain",m=u):typeof FormData<"u"&&u instanceof FormData?m=u:(f["Content-Type"]="application/json",m=JSON.stringify(u)):u&&typeof u!="string"&&!(typeof Blob<"u"&&u instanceof Blob)&&!(u instanceof ArrayBuffer)&&!(typeof FormData<"u"&&u instanceof FormData)?m=JSON.stringify(u):m=u;let g=d;c&&(o=new AbortController,a=setTimeout(()=>
248o.abort(),c),d?(g=o.signal,d.addEventListener("abort",()=>o.abort())):g=o.signal);const y=yield this.fetch(v.toString(),{method:l||"POST",headers:Object.assign(Object.assign(Object.assign({},f),this.headers),s),body:m,signal:g}).catch(x=>{throw new PU(x)}),b=y.headers.get("x-relay-error");if(b&&b==="true")throw new g_(y);if(!y.ok)throw new y_(y);let w=((i=y.headers.get("Content-Type"))!==null&&i!==void 0?i:"text/plain").split(";")[0].trim(),_;return w==="application/json"?_=yield y.json():w==="application/octet-stream"||w==="application/pdf"?_=yield y.blob():w==="text/event-stream"?_=y:w==="multipart/form-data"?_=yield y.formData():_=yield y.text(),{data:_,error:null,response:y}}catch(s){return{data:null,error:s,response:s instanceof y_||s instanceof g_?s.context:void 0}}finally{a&&clearTimeout(a)}})}}var jU=class extends Error{constructor(e){super(e.message),this.name="PostgrestError",this.details=e.details,this.hint=e.hint,this.code=e.code}},TU=class{constructor(e){var t,r,n;this.shouldThrowOnError=!1,this.method=e.method,this.url=e.url,this.headers=new Headers(e.headers),this.schema=e.schema,this.body=e.body,this.shouldThrowOnError=(t=e.shouldThrowOnError)!==null&&t!==void 0?t:!1,this.signal=e.signal,this.isMaybeSingle=(r=e.isMaybeSingle)!==null&&r!==void 0?r:!1,this.urlLengthLimit=(n=e.urlLengthLimit)!==null&&n!==void 0?n:8e3,e.fetch?this.fetch=e.fetch:this.fetch=fetch}throwOnError(){return this.shouldThrowOnError=!0,this}setHeader(e,t){return this.headers=new Headers(this.headers),this.headers.set(e,t),this}then(e,t){var r=this;this.schema===void 0||(["GET","HEAD"].includes(this.method)?this.headers.set("Accept-Profile",this.schema):this.headers.set("Content-Profile",this.schema)),this.method!=="GET"&&this.method!=="HEAD"&&this.headers.set("Content-Type","application/json");const n=this.fetch;let i=n(this.url.toString(),{method:this.method,headers:this.headers,body:JSON.stringify(this.body),signal:this.signal}).then(async a=>{let o=null,s=null,l=null,u=a.status,d=a.statusText;if(a.ok){var c,f;if(r.method!=="HEAD"){var h;const y=await a.text();y===""||(r.headers.get("Accept")==="text/csv"||r.headers.get("Accept")&&(!((h=r.headers.get("Accept"))===null||h===void 0)&&h.includes("application/vnd.pgrst.plan+text"))?s=y:s=JSON.parse(y))}const m=(c=r.headers.get("Prefer"))===null||c===void 0?void 0:c.match(/count=(exact|planned|estimated)/),g=(f=a.headers.get("content-range"))===null||f===void 0?void 0:f.split("/");m&&g&&g.length>1&&(l=parseInt(g[1])),r.isMaybeSingle&&r.method==="GET"&&Array.isArray(s)&&(s.length>1?(o={code:"PGRST116",details:`Results contain ${s.length} rows, application/vnd.pgrst.object+json requires 1 row`,hint:null,message:"JSON object requested, multiple (or no) rows returned"},s=null,l=null,u=406,d="Not Acceptable"):s.length===1?s=s[0]:s=null)}else{var v;const m=await a.text();try{o=JSON.parse(m),Array.isArray(o)&&a.status===404&&(s=[],o=null,u=200,d="OK")}catch{a.status===404&&m===""?(u=204,d="No Content"):o={message:m}}if(o&&r.isMaybeSingle&&(!(o==null||(v=o.details)===null||v===void 0)&&v.includes("0 rows"))&&(o=null,u=200,d="OK"),o&&r.shouldThrowOnError)throw new jU(o)}return{error:o,data:s,count:l,status:u,statusText:d}});return this.shouldThrowOnError||(i=i.catch(a=>{var o;let s="",l="",u="";const d=a==null?void 0:a.cause;if(d){var c,f,h,v;const y=(c=d==null?void 0:d.message)!==null&&c!==void 0?c:"",b=(f=d==null?void 0:d.code)!==null&&f!==void 0?f:"";s=`${(h=a==null?void 0:a.name)!==null&&h!==void 0?h:"FetchError"}: ${a==null?void 0:a.message}`,s+=` 249 250Caused by: ${(v=d==null?void 0:d.name)!==null&&v!==void 0?v:"Error"}: ${y}`,b&&(s+=` (${b})`),d!=null&&d.stack&&(s+=` 251${d.stack}`)}else{var m;s=(m=a==null?void 0:a.stack)!==null&&m!==void 0?m:""}const g=this.url.toString().length;return(a==null?void 0:a.name)==="AbortError"||(a==null?void 0:a.code)==="ABORT_ERR"?(u="",l="Request was aborted (timeout or manual cancellation)",g>this.urlLengthLimit&&(l+=`. Note: Your request URL is ${g} characters, which may exceed server limits. If selecting many fields, consider using views. If filtering with large arrays (e.g., .in('id', [many IDs])), consider using an RPC function to pass values server-side.`)):((d==null?void 0:d.name)==="HeadersOverflowError"||(d==null?void 0:d.code)==="UND_ERR_HEADERS_OVERFLOW")&&(u="",l="HTTP headers exceeded server limits (typically 16KB)",g>this.urlLengthLimit&&(l+=`. Your request URL is ${g} characters. If selecting many fields, consider using views. If filtering with large arrays (e.g., .in('id', [200+ IDs])), consider using an RPC function instead.`)),{error:{message:`${(o=a==null?void 0:a.name)!==null&&o!==void 0?o:"FetchError"}: ${a==null?void 0:a.message}`,details:s,hint:l,code:u},data:null,count:null,status:0,statusText:""}}
251)),i.then(e,t)}returns(){return this}overrideTypes(){return this}},CU=class extends TU{select(e){let t=!1;const r=(e??"*").split("").map(n=>/\s/.test(n)&&!t?"":(n==='"'&&(t=!t),n)).join("");return this.url.searchParams.set("select",r),this.headers.append("Prefer","return=representation"),this}order(e,{ascending:t=!0,nullsFirst:r,foreignTable:n,referencedTable:i=n}={}){const a=i?`${i}.order`:"order",o=this.url.searchParams.get(a);return this.url.searchParams.set(a,`${o?`${o},`:""}${e}.${t?"asc":"desc"}${r===void 0?"":r?".nullsfirst":".nullslast"}`),this}limit(e,{foreignTable:t,referencedTable:r=t}={}){const n=typeof r>"u"?"limit":`${r}.limit`;return this.url.searchParams.set(n,`${e}`),this}range(e,t,{foreignTable:r,referencedTable:n=r}={}){const i=typeof n>"u"?"offset":`${n}.offset`,a=typeof n>"u"?"limit":`${n}.limit`;return this.url.searchParams.set(i,`${e}`),this.url.searchParams.set(a,`${t-e+1}`),this}abortSignal(e){return this.signal=e,this}single(){return this.headers.set("Accept","application/vnd.pgrst.object+json"),this}maybeSingle(){return this.method==="GET"?this.headers.set("Accept","application/json"):this.headers.set("Accept","application/vnd.pgrst.object+json"),this.isMaybeSingle=!0,this}csv(){return this.headers.set("Accept","text/csv"),this}geojson(){return this.headers.set("Accept","application/geo+json"),this}explain({analyze:e=!1,verbose:t=!1,settings:r=!1,buffers:n=!1,wal:i=!1,format:a="text"}={}){var o;const s=[e?"analyze":null,t?"verbose":null,r?"settings":null,n?"buffers":null,i?"wal":null].filter(Boolean).join("|"),l=(o=this.headers.get("Accept"))!==null&&o!==void 0?o:"application/json";return this.headers.set("Accept",`application/vnd.pgrst.plan+${a}; for="${l}"; options=${s};`),a==="json"?this:this}rollback(){return this.headers.append("Prefer","tx=rollback"),this}returns(){return this}maxAffected(e){return this.headers.append("Prefer","handling=strict"),this.headers.append("Prefer",`max-affected=${e}`),this}};const b_=new RegExp("[,()]");var So=class extends CU{eq(e,t){return this.url.searchParams.append(e,`eq.${t}`),this}neq(e,t){return this.url.searchParams.append(e,`neq.${t}`),this}gt(e,t){return this.url.searchParams.append(e,`gt.${t}`),this}gte(e,t){return this.url.searchParams.append(e,`gte.${t}`),this}lt(e,t){return this.url.searchParams.append(e,`lt.${t}`),this}lte(e,t){return this.url.searchParams.append(e,`lte.${t}`),this}like(e,t){return this.url.searchParams.append(e,`like.${t}`),this}likeAllOf(e,t){return this.url.searchParams.append(e,`like(all).{${t.join(",")}}`),this}likeAnyOf(e,t){return this.url.searchParams.append(e,`like(any).{${t.join(",")}}`),this}ilike(e,t){return this.url.searchParams.append(e,`ilike.${t}`),this}ilikeAllOf(e,t){return this.url.searchParams.append(e,`ilike(all).{${t.join(",")}}`),this}ilikeAnyOf(e,t){return this.url.searchParams.append(e,`ilike(any).{${t.join(",")}}`),this}regexMatch(e,t){return this.url.searchParams.append(e,`match.${t}`),this}regexIMatch(e,t){return this.url.searchParams.append(e,`imatch.${t}`),this}is(e,t){return this.url.searchParams.append(e,`is.${t}`),this}isDistinct(e,t){return this.url.searchParams.append(e,`isdistinct.${t}`),this}in(e,t){const r=Array.from(new Set(t)).map(n=>typeof n=="string"&&b_.test(n)?`"${n}"`:`${n}`).join(",");return this.url.searchParams.append(e,`in.(${r})`),this}notIn(e,t){const r=Array.from(new Set(t)).map(n=>typeof n=="string"&&b_.test(n)?`"${n}"`:`${n}`).join(",");return this.url.searchParams.append(e,`not.in.(${r})`),this}contains(e,t){return typeof t=="string"?this.url.searchParams.append(e,`cs.${t}`):Array.isArray(t)?this.url.searchParams.append(e,`cs.{${t.join(",")}}`):this.url.searchParams.append(e,`cs.${JSON.stringify(t)}`),this}containedBy(e,t){return typeof t=="string"?this.url.searchParams.append(e,`cd.${t}`):Array.isArray(t)?this.url.searchParams.append(e,`cd.{${t.join(",")}}`):this.url.searchParams.append(e,`cd.${JSON.stringify(t)}`),this}rangeGt(e,t){return this.url.searchParams.append(e,`sr.${t}`),this}rangeGte(e,t){return this.url.searchParams.append(e,`nxl.${t}`),this}rangeLt(e,t){return this.url.searchParams.append(e,`sl.${t}`),this}rangeLte(e,t){return this.url.searchParams.append(e,`nxr.${t}`),this}rangeAdjacent(e,t){return this.url.searchParams.append(e,`adj.${t}`),this}overlaps(e,t){return typeof t=="string"?this.url.searchParams.append(e,`ov.${t}`):this.url.searchParams.append(e,`ov.{${t.join(",")}}`),this}textSearch(e,t,{config:r,type:n}={}){let i="";n==="plain"?i="pl":n==="phrase"?i="ph":n==="websearch"&&(i="w");const a=r===void 0?"":`(${r})`;return this.url.searchParams.append(e,`${i}fts${a}.${t}`),this}match(e){return Object.entries(e).forEach(([t,r])=>{this.url.searchParams.append(t,`eq.${r}`)}),this}not(e,t,r){return this.url.searchParams.append(e,`not.${t}.${r}`),this}or(e,{foreignTable:t,referencedTable:r=t}={}){const n=r?`${r}.or`:"or";return this.url.searchParams.append(n,`(${e})`),this}filter(e,t,r){return this.url.searchParams.append(e,`${t}.${r}`),this}},NU=class{constructor(e,{headers:t={},schema:r,fetch:n,urlLengthLimit:i=8e3}){this.url=e,this.headers=new Headers(t),this.schema=r,this.fetch=n,this.urlLengthLimit=i}
251cloneRequestState(){return{url:new URL(this.url.toString()),headers:new Headers(this.headers)}}select(e,t){const{head:r=!1,count:n}=t??{},i=r?"HEAD":"GET";let a=!1;const o=(e??"*").split("").map(u=>/\s/.test(u)&&!a?"":(u==='"'&&(a=!a),u)).join(""),{url:s,headers:l}=this.cloneRequestState();return s.searchParams.set("select",o),n&&l.append("Prefer",`count=${n}`),new So({method:i,url:s,headers:l,schema:this.schema,fetch:this.fetch,urlLengthLimit:this.urlLengthLimit})}insert(e,{count:t,defaultToNull:r=!0}={}){var n;const i="POST",{url:a,headers:o}=this.cloneRequestState();if(t&&o.append("Prefer",`count=${t}`),r||o.append("Prefer","missing=default"),Array.isArray(e)){const s=e.reduce((l,u)=>l.concat(Object.keys(u)),[]);if(s.length>0){const l=[...new Set(s)].map(u=>`"${u}"`);a.searchParams.set("columns",l.join(","))}}return new So({method:i,url:a,headers:o,schema:this.schema,body:e,fetch:(n=this.fetch)!==null&&n!==void 0?n:fetch,urlLengthLimit:this.urlLengthLimit})}upsert(e,{onConflict:t,ignoreDuplicates:r=!1,count:n,defaultToNull:i=!0}={}){var a;const o="POST",{url:s,headers:l}=this.cloneRequestState();if(l.append("Prefer",`resolution=${r?"ignore":"merge"}-duplicates`),t!==void 0&&s.searchParams.set("on_conflict",t),n&&l.append("Prefer",`count=${n}`),i||l.append("Prefer","missing=default"),Array.isArray(e)){const u=e.reduce((d,c)=>d.concat(Object.keys(c)),[]);if(u.length>0){const d=[...new Set(u)].map(c=>`"${c}"`);s.searchParams.set("columns",d.join(","))}}return new So({method:o,url:s,headers:l,schema:this.schema,body:e,fetch:(a=this.fetch)!==null&&a!==void 0?a:fetch,urlLengthLimit:this.urlLengthLimit})}update(e,{count:t}={}){var r;const n="PATCH",{url:i,headers:a}=this.cloneRequestState();return t&&a.append("Prefer",`count=${t}`),new So({method:n,url:i,headers:a,schema:this.schema,body:e,fetch:(r=this.fetch)!==null&&r!==void 0?r:fetch,urlLengthLimit:this.urlLengthLimit})}delete({count:e}={}){var t;const r="DELETE",{url:n,headers:i}=this.cloneRequestState();return e&&i.append("Prefer",`count=${e}`),new So({method:r,url:n,headers:i,schema:this.schema,fetch:(t=this.fetch)!==null&&t!==void 0?t:fetch,urlLengthLimit:this.urlLengthLimit})}};function Eu(e){"@babel/helpers - typeof";return Eu=typeof Symbol=="function"&&typeof Symbol.iterator=="symbol"?function(t){return typeof t}:function(t){return t&&typeof Symbol=="function"&&t.constructor===Symbol&&t!==Symbol.prototype?"symbol":typeof t},Eu(e)}function $U(e,t){if(Eu(e)!="object"||!e)return e;var r=e[Symbol.toPrimitive];if(r!==void 0){var n=r.call(e,t||"default");if(Eu(n)!="object")return n;throw new TypeError("@@toPrimitive must return a primitive value.")}return(t==="string"?String:Number)(e)}function RU(e){var t=$U(e,"string");return Eu(t)=="symbol"?t:t+""}function IU(e,t,r){return(t=RU(t))in e?Object.defineProperty(e,t,{value:r,enumerable:!0,configurable:!0,writable:!0}):e[t]=r,e}function w_(e,t){var r=Object.keys(e);if(Object.getOwnPropertySymbols){var n=Object.getOwnPropertySymbols(e);t&&(n=n.filter(function(i){return Object.getOwnPropertyDescriptor(e,i).enumerable})),r.push.apply(r,n)}return r}function sd(e){for(var t=1;t<arguments.length;t++){var r=arguments[t]!=null?arguments[t]:{};t%2?w_(Object(r),!0).forEach(function(n){IU(e,n,r[n])}):Object.getOwnPropertyDescriptors?Object.defineProperties(e,Object.getOwnPropertyDescriptors(r)):w_(Object(r)).forEach(function(n){Object.defineProperty(e,n,Object.getOwnPropertyDescriptor(r,n))})}return e}var MU=class ZT{constructor(t,{headers:r={},schema:n,fetch:i,timeout:a,urlLengthLimit:o=8e3}={}){this.url=t,this.headers=new Headers(r),this.schemaName=n,this.urlLengthLimit=o;const s=i??globalThis.fetch;a!==void 0&&a>0?this.fetch=(l,u)=>{const d=new AbortController,c=setTimeout(()=>d.abort(),a),f=u==null?void 0:u.signal;if(f){if(f.aborted)return clearTimeout(c),s(l,u);const h=()=>{clearTimeout(c),d.abort()};return f.addEventListener("abort",h,{once:!0}),s(l,sd(sd({},u),{},{signal:d.signal})).finally(()=>{clearTimeout(c),f.removeEventListener("abort",h)})}return s(l,sd(sd({},u),{},{signal:d.signal})).finally(()=>clearTimeout(c))}:this.fetch=s}from(t){if(!t||typeof t!="string"||t.trim()==="")throw new Error("Invalid relation name: relation must be a non-empty string.");return new NU(new URL(`${this.url}/${t}`),{headers:new Headers(this.headers),schema:this.schemaName,fetch:this.fetch,urlLengthLimit:this.urlLengthLimit})}schema(t){return new ZT(this.url,{headers:this.headers,schema:t,fetch:this.fetch,urlLengthLimit:this.urlLengthLimit})}rpc(t,r={},{head:n=!1,get:i=!1,count:a}={}){var o;let s;const l=new URL(`${this.url}/rpc/${t}`);let u;const d=h=>h!==null&&typeof h=="object"&&(!Array.isArray(h)||h.some(d)),c=n&&Object.values(r).some(d);c?(s="POST",u=r):n||i?(s=n?"HEAD":"GET",Object.entries(r).filter(([h,v])=>v!==void 0).map(([h,v])=>[h,Array.isArray(v)?`{${v.join(",")}}`:`${v}
251`]).forEach(([h,v])=>{l.searchParams.append(h,v)})):(s="POST",u=r);const f=new Headers(this.headers);return c?f.set("Prefer",a?`count=${a},return=minimal`:"return=minimal"):a&&f.set("Prefer",`count=${a}`),new So({method:s,url:l,headers:f,schema:this.schemaName,body:u,fetch:(o=this.fetch)!==null&&o!==void 0?o:fetch,urlLengthLimit:this.urlLengthLimit})}};class DU{constructor(){}static detectEnvironment(){var t;if(typeof WebSocket<"u")return{type:"native",constructor:WebSocket};if(typeof globalThis<"u"&&typeof globalThis.WebSocket<"u")return{type:"native",constructor:globalThis.WebSocket};if(typeof global<"u"&&typeof global.WebSocket<"u")return{type:"native",constructor:global.WebSocket};if(typeof globalThis<"u"&&typeof globalThis.WebSocketPair<"u"&&typeof globalThis.WebSocket>"u")return{type:"cloudflare",error:"Cloudflare Workers detected. WebSocket clients are not supported in Cloudflare Workers.",workaround:"Use Cloudflare Workers WebSocket API for server-side WebSocket handling, or deploy to a different runtime."};if(typeof globalThis<"u"&&globalThis.EdgeRuntime||typeof navigator<"u"&&(!((t=navigator.userAgent)===null||t===void 0)&&t.includes("Vercel-Edge")))return{type:"unsupported",error:"Edge runtime detected (Vercel Edge/Netlify Edge). WebSockets are not supported in edge functions.",workaround:"Use serverless functions or a different deployment target for WebSocket functionality."};const r=globalThis.process;if(r){const n=r.versions;if(n&&n.node){const i=n.node,a=parseInt(i.replace(/^v/,"").split(".")[0]);return a>=22?typeof globalThis.WebSocket<"u"?{type:"native",constructor:globalThis.WebSocket}:{type:"unsupported",error:`Node.js ${a} detected but native WebSocket not found.`,workaround:"Provide a WebSocket implementation via the transport option."}:{type:"unsupported",error:`Node.js ${a} detected without native WebSocket support.`,workaround:`For Node.js < 22, install "ws" package and provide it via the transport option: 252import ws from "ws" 253new RealtimeClient(url, { transport: ws })`}}}return{type:"unsupported",error:"Unknown JavaScript runtime without WebSocket support.",workaround:"Ensure you're running in a supported environment (browser, Node.js, Deno) or provide a custom WebSocket implementation."}}static getWebSocketConstructor(){const t=this.detectEnvironment();if(t.constructor)return t.constructor;let r=t.error||"WebSocket not supported in this environment.";throw t.workaround&&(r+=` 254 255Suggested solution: ${t.workaround}`),new Error(r)}static createWebSocket(t,r){const n=this.getWebSocketConstructor();return new n(t,r)}static isWebSocketSupported(){try{const t=this.detectEnvironment();return t.type==="native"||t.type==="ws"}catch{return!1}}}const LU="2.97.0",BU=`realtime-js/${LU}`,UU="1.0.0",eC="2.0.0",x_=eC,Qg=1e4,FU=1e3,zU=100;var wi;(function(e){e[e.connecting=0]="connecting",e[e.open=1]="open",e[e.closing=2]="closing",e[e.closed=3]="closed"})(wi||(wi={}));var st;(function(e){e.closed="closed",e.errored="errored",e.joined="joined",e.joining="joining",e.leaving="leaving"})(st||(st={}));var Vr;(function(e){e.close="phx_close",e.error="phx_error",e.join="phx_join",e.reply="phx_reply",e.leave="phx_leave",e.access_token="access_token"})(Vr||(Vr={}));var Jg;(function(e){e.websocket="websocket"})(Jg||(Jg={}));var ga;(function(e){e.Connecting="connecting",e.Open="open",e.Closing="closing",e.Closed="closed"})(ga||(ga={}));class WU{constructor(t){this.HEADER_LENGTH=1,this.USER_BROADCAST_PUSH_META_LENGTH=6,this.KINDS={userBroadcastPush:3,userBroadcast:4},this.BINARY_ENCODING=0,this.JSON_ENCODING=1,this.BROADCAST_EVENT="broadcast",this.allowedMetadataKeys=[],this.allowedMetadataKeys=t??[]}encode(t,r){if(t.event===this.BROADCAST_EVENT&&!(t.payload instanceof ArrayBuffer)&&typeof t.payload.event=="string")return r(this._binaryEncodeUserBroadcastPush(t));let n=[t.join_ref,t.ref,t.topic,t.event,t.payload];return r(JSON.stringify(n))}_binaryEncodeUserBroadcastPush(t){var r;return this._isArrayBuffer((r=t.payload)===null||r===void 0?void 0:r.payload)?this._encodeBinaryUserBroadcastPush(t):this._encodeJsonUserBroadcastPush(t)}_encodeBinaryUserBroadcastPush(t){var r,n;const i=(n=(r=t.payload)===null||r===void 0?void 0:r.payload)!==null&&n!==void 0?n:new ArrayBuffer(0);return this._encodeUserBroadcastPush(t,this.BINARY_ENCODING,i)}_encodeJsonUserBroadcastPush(t){var r,n;const i=(n=(r=t.payload)===null||r===void 0?void 0:r.payload)!==null&&n!==void 0?n:{},o=new TextEncoder().encode(JSON.stringify(i)).buffer;return this._encodeUserBroadcastPush(t,this.JSON_ENCODING,o)}_encodeUserBroadcastPush(t,r,n){var i,a;const o=t.topic,s=(i=t.ref)!==null&&i!==void 0?i:"",l=(a=t.join_ref)!==null&&a!==void 0?a:"",u=t.payload.event,d=this.allowedMetadataKeys?this._pick(t.payload,this.allowedMetadataKeys):{},c=Object.keys(d).length===0?"":JSON.stringify(d);if(l.length>255)throw new Error(`joinRef length ${l.length} exceeds maximum of 255`);if(s.length>255)throw new Error(`ref length ${s.length} exceeds maximum of 255`);if(o.length>255)throw new Error(`topic length ${o.length} exceeds maximum of 255`);if(u.length>255)throw new Error(`userEvent length ${u.length} exceeds maximum of 255`);if(c.length>255)throw new Error(`metadata length ${c.length} exceeds maximum of 255`);const f=this.USER_BROADCAST_PUSH_META_LENGTH+l.length+s.length+o.length+u.length+c.length,h=new ArrayBuffer(this.HEADER_LENGTH+f);
255let v=new DataView(h),m=0;v.setUint8(m++,this.KINDS.userBroadcastPush),v.setUint8(m++,l.length),v.setUint8(m++,s.length),v.setUint8(m++,o.length),v.setUint8(m++,u.length),v.setUint8(m++,c.length),v.setUint8(m++,r),Array.from(l,y=>v.setUint8(m++,y.charCodeAt(0))),Array.from(s,y=>v.setUint8(m++,y.charCodeAt(0))),Array.from(o,y=>v.setUint8(m++,y.charCodeAt(0))),Array.from(u,y=>v.setUint8(m++,y.charCodeAt(0))),Array.from(c,y=>v.setUint8(m++,y.charCodeAt(0)));var g=new Uint8Array(h.byteLength+n.byteLength);return g.set(new Uint8Array(h),0),g.set(new Uint8Array(n),h.byteLength),g.buffer}decode(t,r){if(this._isArrayBuffer(t)){let n=this._binaryDecode(t);return r(n)}if(typeof t=="string"){const n=JSON.parse(t),[i,a,o,s,l]=n;return r({join_ref:i,ref:a,topic:o,event:s,payload:l})}return r({})}_binaryDecode(t){const r=new DataView(t),n=r.getUint8(0),i=new TextDecoder;switch(n){case this.KINDS.userBroadcast:return this._decodeUserBroadcast(t,r,i)}}_decodeUserBroadcast(t,r,n){const i=r.getUint8(1),a=r.getUint8(2),o=r.getUint8(3),s=r.getUint8(4);let l=this.HEADER_LENGTH+4;const u=n.decode(t.slice(l,l+i));l=l+i;const d=n.decode(t.slice(l,l+a));l=l+a;const c=n.decode(t.slice(l,l+o));l=l+o;const f=t.slice(l,t.byteLength),h=s===this.JSON_ENCODING?JSON.parse(n.decode(f)):f,v={type:this.BROADCAST_EVENT,event:d,payload:h};return o>0&&(v.meta=JSON.parse(c)),{join_ref:null,ref:null,topic:u,event:this.BROADCAST_EVENT,payload:v}}_isArrayBuffer(t){var r;return t instanceof ArrayBuffer||((r=t==null?void 0:t.constructor)===null||r===void 0?void 0:r.name)==="ArrayBuffer"}_pick(t,r){return!t||typeof t!="object"?{}:Object.fromEntries(Object.entries(t).filter(([n])=>r.includes(n)))}}class tC{constructor(t,r){this.callback=t,this.timerCalc=r,this.timer=void 0,this.tries=0,this.callback=t,this.timerCalc=r}reset(){this.tries=0,clearTimeout(this.timer),this.timer=void 0}scheduleTimeout(){clearTimeout(this.timer),this.timer=setTimeout(()=>{this.tries=this.tries+1,this.callback()},this.timerCalc(this.tries+1))}}var $e;(function(e){e.abstime="abstime",e.bool="bool",e.date="date",e.daterange="daterange",e.float4="float4",e.float8="float8",e.int2="int2",e.int4="int4",e.int4range="int4range",e.int8="int8",e.int8range="int8range",e.json="json",e.jsonb="jsonb",e.money="money",e.numeric="numeric",e.oid="oid",e.reltime="reltime",e.text="text",e.time="time",e.timestamp="timestamp",e.timestamptz="timestamptz",e.timetz="timetz",e.tsrange="tsrange",e.tstzrange="tstzrange"})($e||($e={}));const __=(e,t,r={})=>{var n;const i=(n=r.skipTypes)!==null&&n!==void 0?n:[];return t?Object.keys(t).reduce((a,o)=>(a[o]=qU(o,e,t,i),a),{}):{}},qU=(e,t,r,n)=>{const i=t.find(s=>s.name===e),a=i==null?void 0:i.type,o=r[e];return a&&!n.includes(a)?rC(a,o):Zg(o)},rC=(e,t)=>{if(e.charAt(0)==="_"){const r=e.slice(1,e.length);return GU(t,r)}switch(e){case $e.bool:return HU(t);case $e.float4:case $e.float8:case $e.int2:case $e.int4:case $e.int8:case $e.numeric:case $e.oid:return VU(t);case $e.json:case $e.jsonb:return KU(t);case $e.timestamp:return YU(t);case $e.abstime:case $e.date:case $e.daterange:case $e.int4range:case $e.int8range:case $e.money:case $e.reltime:case $e.text:case $e.time:case $e.timestamptz:case $e.timetz:case $e.tsrange:case $e.tstzrange:return Zg(t);default:return Zg(t)}},Zg=e=>e,HU=e=>{switch(e){case"t":return!0;case"f":return!1;default:return e}},VU=e=>{if(typeof e=="string"){const t=parseFloat(e);if(!Number.isNaN(t))return t}return e},KU=e=>{if(typeof e=="string")try{return JSON.parse(e)}catch{return e}return e},GU=(e,t)=>{if(typeof e!="string")return e;const r=e.length-1,n=e[r];if(e[0]==="{"&&n==="}"){let a;const o=e.slice(1,r);try{a=JSON.parse("["+o+"]")}catch{a=o?o.split(","):[]}return a.map(s=>rC(t,s))}return e},YU=e=>typeof e=="string"?e.replace(" ","T"):e,nC=e=>{const t=new URL(e);return t.protocol=t.protocol.replace(/^ws/i,"http"),t.pathname=t.pathname.replace(/\/+$/,"").replace(/\/socket\/websocket$/i,"").replace(/\/socket$/i,"").replace(/\/websocket$/i,""),t.pathname===""||t.pathname==="/"?t.pathname="/api/broadcast":t.pathname=t.pathname+"/api/broadcast",t.href};class Xm{constructor(t,r,n={},i=Qg){this.channel=t,this.event=r,this.payload=n,this.timeout=i,this.sent=!1,this.timeoutTimer=void 0,this.ref="",this.receivedResp=null,this.recHo
255oks=[],this.refEvent=null}resend(t){this.timeout=t,this._cancelRefEvent(),this.ref="",this.refEvent=null,this.receivedResp=null,this.sent=!1,this.send()}send(){this._hasReceived("timeout")||(this.startTimeout(),this.sent=!0,this.channel.socket.push({topic:this.channel.topic,event:this.event,payload:this.payload,ref:this.ref,join_ref:this.channel._joinRef()}))}updatePayload(t){this.payload=Object.assign(Object.assign({},this.payload),t)}receive(t,r){var n;return this._hasReceived(t)&&r((n=this.receivedResp)===null||n===void 0?void 0:n.response),this.recHooks.push({status:t,callback:r}),this}startTimeout(){if(this.timeoutTimer)return;this.ref=this.channel.socket._makeRef(),this.refEvent=this.channel._replyEventName(this.ref);const t=r=>{this._cancelRefEvent(),this._cancelTimeout(),this.receivedResp=r,this._matchReceive(r)};this.channel._on(this.refEvent,{},t),this.timeoutTimer=setTimeout(()=>{this.trigger("timeout",{})},this.timeout)}trigger(t,r){this.refEvent&&this.channel._trigger(this.refEvent,{status:t,response:r})}destroy(){this._cancelRefEvent(),this._cancelTimeout()}_cancelRefEvent(){this.refEvent&&this.channel._off(this.refEvent,{})}_cancelTimeout(){clearTimeout(this.timeoutTimer),this.timeoutTimer=void 0}_matchReceive({status:t,response:r}){this.recHooks.filter(n=>n.status===t).forEach(n=>n.callback(r))}_hasReceived(t){return this.receivedResp&&this.receivedResp.status===t}}var S_;(function(e){e.SYNC="sync",e.JOIN="join",e.LEAVE="leave"})(S_||(S_={}));class Gl{constructor(t,r){this.channel=t,this.state={},this.pendingDiffs=[],this.joinRef=null,this.enabled=!1,this.caller={onJoin:()=>{},onLeave:()=>{},onSync:()=>{}};const n=(r==null?void 0:r.events)||{state:"presence_state",diff:"presence_diff"};this.channel._on(n.state,{},i=>{const{onJoin:a,onLeave:o,onSync:s}=this.caller;this.joinRef=this.channel._joinRef(),this.state=Gl.syncState(this.state,i,a,o),this.pendingDiffs.forEach(l=>{this.state=Gl.syncDiff(this.state,l,a,o)}),this.pendingDiffs=[],s()}),this.channel._on(n.diff,{},i=>{const{onJoin:a,onLeave:o,onSync:s}=this.caller;this.inPendingSyncState()?this.pendingDiffs.push(i):(this.state=Gl.syncDiff(this.state,i,a,o),s())}),this.onJoin((i,a,o)=>{this.channel._trigger("presence",{event:"join",key:i,currentPresences:a,newPresences:o})}),this.onLeave((i,a,o)=>{this.channel._trigger("presence",{event:"leave",key:i,currentPresences:a,leftPresences:o})}),this.onSync(()=>{this.channel._trigger("presence",{event:"sync"})})}static syncState(t,r,n,i){const a=this.cloneDeep(t),o=this.transformState(r),s={},l={};return this.map(a,(u,d)=>{o[u]||(l[u]=d)}),this.map(o,(u,d)=>{const c=a[u];if(c){const f=d.map(g=>g.presence_ref),h=c.map(g=>g.presence_ref),v=d.filter(g=>h.indexOf(g.presence_ref)<0),m=c.filter(g=>f.indexOf(g.presence_ref)<0);v.length>0&&(s[u]=v),m.length>0&&(l[u]=m)}else s[u]=d}),this.syncDiff(a,{joins:s,leaves:l},n,i)}static syncDiff(t,r,n,i){const{joins:a,leaves:o}={joins:this.transformState(r.joins),leaves:this.transformState(r.leaves)};return n||(n=()=>{}),i||(i=()=>{}),this.map(a,(s,l)=>{var u;const d=(u=t[s])!==null&&u!==void 0?u:[];if(t[s]=this.cloneDeep(l),d.length>0){const c=t[s].map(h=>h.presence_ref),f=d.filter(h=>c.indexOf(h.presence_ref)<0);t[s].unshift(...f)}n(s,d,l)}),this.map(o,(s,l)=>{let u=t[s];if(!u)return;const d=l.map(c=>c.presence_ref);u=u.filter(c=>d.indexOf(c.presence_ref)<0),t[s]=u,i(s,u,l),u.length===0&&delete t[s]}),t}static map(t,r){return Object.getOwnPropertyNames(t).map(n=>r(n,t[n]))}static transformState(t){return t=this.cloneDeep(t),Object.getOwnPropertyNames(t).reduce((r,n)=>{const i=t[n];return"metas"in i?r[n]=i.metas.map(a=>(a.presence_ref=a.phx_ref,delete a.phx_ref,delete a.phx_ref_prev,a)):r[n]=i,r},{})}static cloneDeep(t){return JSON.parse(JSON.stringify(t))}onJoin(t){this.caller.onJoin=t}onLeave(t){this.caller.onLeave=t}onSync(t){this.caller.onSync=t}inPendingSyncState(){return!this.joinRef||this.joinRef!==this.channel._joinRef()}}var O_;(function(e){e.ALL="*",e.INSERT="INSERT",e.UPDATE="UPDATE",e.DELETE="DELETE"})(O_||(O_={}));var Yl;(function(e){e.BROADCAST="broadcast",e.PRESENCE="presence",e.POSTGRES_CHANGES="postgres_changes",e.SYSTEM="system"})(Yl||(Yl={}));var Dn;(function(e){e.SUBSCRIBED="SUBSCRIBED",e.TIMED_OUT="TIMED_OUT",e.CLOSED="CLOSED",e.CHANNEL_ERROR="CHANNEL_ERROR"})(Dn||(Dn={}));class Bo{constructor(t,r={config:{}},n){var i,a;if(this.topic=t,this.params=r,this.socket=n,this.bindings={},this.state=st.closed,this.joinedOnce=!1,this.pushBuffer=[],this.subTopic=t.replace(/^realtime:/i,""),this.params.config=Object.assign({broadcast:{ack:!1,self:!1},presence:{key:"",enabled:!1},private:!1},r.config),this.timeout=this.socket.timeout,this.joinPush=new Xm(this,Vr.join,this.params,this.timeout),this.rejoinTimer=new tC(()=>this._rejoinUntilConnected(),this.socket.reconnectAfterMs),this.joinPush.receive("ok",()=>{this.state=st.joined,this.rejoinTimer.reset(),this.pushBuffer.forEach(o=>o.send()),this.pushBuffer=[]}),this._onClose(()=>{this.rejoinTimer.reset(),this.socket.log("channel",`close ${this.topic} ${this._joinRef()}`),this.state=st.closed,this.socket._remove(this)}),this._onError(o=>{this._isLeaving()||this._isClosed()||(this.socket.log("channel",`error ${this.topic}`,o),this.state=st.errored,this.rejoinTimer.scheduleTimeout())}),this.joinPush.receive("timeout",()=>{this._isJoining()&&(this.socket.log("channel",`timeout ${this.topic}`,this.joinPush.timeout),this.state=st.errored,this.rejoinTimer.scheduleTimeout())}),this.joinPush.receive("error",o=>{this._isLeaving()||this._isClosed()||(this.socket.log("channel",`error ${this.topic}`,o),this.state=st.errored,this.rejoinTimer.scheduleTimeout())}),this._on(Vr.reply,{},(o,s)=>{this._trigger(this._replyEventName(s),o)}),this.presence=new Gl(this),this.broadcastEndpointURL=nC(this.socket.endPoint),this.private=this.params.config.private||!1,!this.private&&(!((a=(i=this.params.config)===null||i===void 0?void 0:i.broadcast)===null||a===void 0)&&a.replay))throw`tried to use replay on public channel '${this.topic}'. It must be a private channel.`}subscribe(t,r=this.timeout){var n,i,a;if(this.socket.isConnected()||this.socket.connect(),this.state==st.closed){const{config:{broadcast:o,presence:s,private:l}}=this.params,u=(i=(n=this.bindings.postgres_changes)===null||n===void 0?void 0:n.map(h=>h.filter))!==null&&i!==void 0?i:[],d=!!this.bindings[Yl.PRESENCE]&&this.bindings[Yl.PRESENCE].length>0||((a=this.params.config.presence)===null||a===void 0?void 0:a.enabled)===!0,c={},f={broadcast:o,presence:Object.assign(Object.assign({},s),{enabled:d}),postgres_changes:u,private:l};this.socket.accessTokenValue&&(c.access_token=this.socket.accessTokenValue),this._onError(h=>t==null?void 0:t(Dn.CHANNEL_ERROR,h)),this._onClose(()=>t==null?void 0:t(Dn.CLOSED)),this.updateJoinPayload(Object.assign({config:f},c)),this.joinedOnce=!0,this._rejoin(r),this.joinPush.receive("ok",async({postgres_changes:h})=>{var v;if(this.socket._isManualToken()||this.socket.setAuth(),h===void 0){t==null||t(Dn.SUBSCRIBED);return}else{const m=this.bindings.postgres_changes,g=(v=m==null?void 0:m.length)!==null&&v!==void 0?v:0,y=[];for(let b=0;b<g;b++){const w=m[b],{filter:{event:_,schema:x,table:S,filter:E}}=w,k=h&&h[b];if(k&&k.event===_&&Bo.isFilterValueEqual(k.schema,x)&&Bo.isFilterValueEqual(k.table,S)&&Bo.isFilterValueEqual(k.filter,E))y.push(Object.assign(Object.assign({},w),{id:k.id}));else{this.unsubscribe(),this.state=st.errored,t==null||t(Dn.CHANNEL_ERROR,new Error("mismatch between server and client bindings for postgres changes"));return}}this.bindings.postgres_changes=y,t&&t(Dn.SUBSCRIBED);return}}).receive("error",h=>{this.state=st.errored,t==null||t(Dn.CHANNEL_ERROR,new Error(JSON.stringify(Object.values(h).join(", ")||"error")))}).receive("timeout",()=>{t==null||t(Dn.TIMED_OUT)})}return this}presenceState(){return this.presence.state}async track(t,r={}){return await this.send({type:"presence",event:"track",payload:t},r.timeout||this.timeout)}async untrack(t={}){return await this.send({type:"presence",event:"untrack"},t)}on(t,r,n){return this.state===st.joined&&t===Yl.PRESENCE&&(this.socket.log("channel",`resubscribe to ${this.topic} due to change in presence callbacks on joined channel`),this.unsubscribe().then(async()=>await this.subscribe())),this._on(t,r,n)}async httpSend(t,r,n={}){var i;if(r==null)return Promise.reject("Payload is required for httpSend()");const a={apikey:this.socket.apiKey?this.socket.apiKey:"","Content-Type":"application/json"};this.socket.accessTokenValue&&(a.Authorization=`Bearer ${this.socket.accessTokenValue}`);const o={method:"POST",headers:a,body:JSON.stringify({messages:[{topic:this.subTopic,event:t,payload:r,private:this.private}]})},s=await this._fetchWithTimeout(this.broadcastEndpointURL,o,(i=n.timeout)!==null&&i!==void 0?i:this.timeout);if(s.status===202)return{success:!0};let l=s.statusText;
255try{const u=await s.json();l=u.error||u.message||l}catch{}return Promise.reject(new Error(l))}async send(t,r={}){var n,i;if(!this._canPush()&&t.type==="broadcast"){console.warn("Realtime send() is automatically falling back to REST API. This behavior will be deprecated in the future. Please use httpSend() explicitly for REST delivery.");const{event:a,payload:o}=t,s={apikey:this.socket.apiKey?this.socket.apiKey:"","Content-Type":"application/json"};this.socket.accessTokenValue&&(s.Authorization=`Bearer ${this.socket.accessTokenValue}`);const l={method:"POST",headers:s,body:JSON.stringify({messages:[{topic:this.subTopic,event:a,payload:o,private:this.private}]})};try{const u=await this._fetchWithTimeout(this.broadcastEndpointURL,l,(n=r.timeout)!==null&&n!==void 0?n:this.timeout);return await((i=u.body)===null||i===void 0?void 0:i.cancel()),u.ok?"ok":"error"}catch(u){return u.name==="AbortError"?"timed out":"error"}}else return new Promise(a=>{var o,s,l;const u=this._push(t.type,t,r.timeout||this.timeout);t.type==="broadcast"&&!(!((l=(s=(o=this.params)===null||o===void 0?void 0:o.config)===null||s===void 0?void 0:s.broadcast)===null||l===void 0)&&l.ack)&&a("ok"),u.receive("ok",()=>a("ok")),u.receive("error",()=>a("error")),u.receive("timeout",()=>a("timed out"))})}updateJoinPayload(t){this.joinPush.updatePayload(t)}unsubscribe(t=this.timeout){this.state=st.leaving;const r=()=>{this.socket.log("channel",`leave ${this.topic}`),this._trigger(Vr.close,"leave",this._joinRef())};this.joinPush.destroy();let n=null;return new Promise(i=>{n=new Xm(this,Vr.leave,{},t),n.receive("ok",()=>{r(),i("ok")}).receive("timeout",()=>{r(),i("timed out")}).receive("error",()=>{i("error")}),n.send(),this._canPush()||n.trigger("ok",{})}).finally(()=>{n==null||n.destroy()})}teardown(){this.pushBuffer.forEach(t=>t.destroy()),this.pushBuffer=[],this.rejoinTimer.reset(),this.joinPush.destroy(),this.state=st.closed,this.bindings={}}async _fetchWithTimeout(t,r,n){const i=new AbortController,a=setTimeout(()=>i.abort(),n),o=await this.socket.fetch(t,Object.assign(Object.assign({},r),{signal:i.signal}));return clearTimeout(a),o}_push(t,r,n=this.timeout){if(!this.joinedOnce)throw`tried to push '${t}' to '${this.topic}' before joining. Use channel.subscribe() before pushing events`;let i=new Xm(this,t,r,n);return this._canPush()?i.send():this._addToPushBuffer(i),i}_addToPushBuffer(t){if(t.startTimeout(),this.pushBuffer.push(t),this.pushBuffer.length>zU){const r=this.pushBuffer.shift();r&&(r.destroy(),this.socket.log("channel",`discarded push due to buffer overflow: ${r.event}`,r.payload))}}_onMessage(t,r,n){return r}_isMember(t){return this.topic===t}_joinRef(){return this.joinPush.ref}_trigger(t,r,n){var i,a;const o=t.toLocaleLowerCase(),{close:s,error:l,leave:u,join:d}=Vr;if(n&&[s,l,u,d].indexOf(o)>=0&&n!==this._joinRef())return;let f=this._onMessage(o,r,n);if(r&&!f)throw"channel onMessage callbacks must return the payload, modified or unmodified";["insert","update","delete"].includes(o)?(i=this.bindings.postgres_changes)===null||i===void 0||i.filter(h=>{var v,m,g;return((v=h.filter)===null||v===void 0?void 0:v.event)==="*"||((g=(m=h.filter)===null||m===void 0?void 0:m.event)===null||g===void 0?void 0:g.toLocaleLowerCase())===o}).map(h=>h.callback(f,n)):(a=this.bindings[o])===null||a===void 0||a.filter(h=>{var v,m,g,y,b,w;if(["broadcast","presence","postgres_changes"].includes(o))if("id"in h){const _=h.id,x=(v=h.filter)===null||v===void 0?void 0:v.event;return _&&((m=r.ids)===null||m===void 0?void 0:m.includes(_))&&(x==="*"||(x==null?void 0:x.toLocaleLowerCase())===((g=r.data)===null||g===void 0?void 0:g.type.toLocaleLowerCase()))}else{const _=(b=(y=h==null?void 0:h.filter)===null||y===void 0?void 0:y.event)===null||b===void 0?void 0:b.toLocaleLowerCase();return _==="*"||_===((w=r==null?void 0:r.event)===null||w===void 0?void 0:w.toLocaleLowerCase())}else return h.type.toLocaleLowerCase()===o}).map(h=>{if(typeof f=="object"&&"ids"in f){const v=f.data,{schema:m,table:g,commit_timestamp:y,type:b,errors:w}=v;f=Object.assign(Object.assign({},{schema:m,table:g,commit_timestamp:y,eventType:b,new:{},old:{},errors:w}),this._getPayloadRecords(v))}h.callback(f,n)})}_isClosed(){return this.state===st.closed}_isJoined(){return this.state===st.joined}_isJoining(){return this.state===st.joining}_isLeaving(){return this.state===st.leaving}_replyEventName(t){return`chan_reply_${t}`}_on(t,r,n){const i=t.toLocaleLowerCase(),a={type:i,filter:r,callback:n};return this.bindings[i]?this.bindings[i].push(a):this.bindings[i]=[a],this}_off(t,r){const n=t.toLocaleLowerCase();return this.bindings[n]&&(this.bindings[n]=this.bindings[n].filter(i=>{var a;return!(((a=i.type)===null||a===void 0?void 0:a.toLocaleLowerCase())===n&&Bo.isEqual(i.filter,r))})),this}static isEqual(t,r){if(Object.keys(t).length!==Object.keys(r).length)return!1;for(const n in t)if(t[n]!==r[n])return!1;return!0}static isFilterValueEqual(t,r){return(t??void 0)===(r??void 0)}_rejoinUntilConnected(){this.rejoinTimer.scheduleTimeout(),this.socket.isConnected()&&this._rejoin()}_onClose(t){this._on(Vr.close,{},t)}_onError(t){this._on(Vr.error,{},r=>t(r))}_canPush(){return this.socket.isConnected()&&this._isJoined()}_rejoin(t=this.timeout){this._isLeaving()||(this.socket._leaveOpenTopic(this.topic),this.state=st.joining,this.joinPush.resend(t))}_getPayloadRecords(t){const r={new:{},old:{}};return(t.type==="INSERT"||t.type==="UPDATE")&&(r.new=__(t.columns,t.record)),(t.type==="UPDATE"||t.type==="DELETE")&&(r.old=__
255(t.columns,t.old_record)),r}}const Qm=()=>{},ld={HEARTBEAT_INTERVAL:25e3,RECONNECT_DELAY:10,HEARTBEAT_TIMEOUT_FALLBACK:100},XU=[1e3,2e3,5e3,1e4],QU=1e4,JU=` 256 addEventListener("message", (e) => { 257 if (e.data.event === "start") { 258 setInterval(() => postMessage({ event: "keepAlive" }), e.data.interval); 259 } 260 });`;class ZU{constructor(t,r){var n;if(this.accessTokenValue=null,this.apiKey=null,this._manuallySetToken=!1,this.channels=new Array,this.endPoint="",this.httpEndpoint="",this.headers={},this.params={},this.timeout=Qg,this.transport=null,this.heartbeatIntervalMs=ld.HEARTBEAT_INTERVAL,this.heartbeatTimer=void 0,this.pendingHeartbeatRef=null,this.heartbeatCallback=Qm,this.ref=0,this.reconnectTimer=null,this.vsn=x_,this.logger=Qm,this.conn=null,this.sendBuffer=[],this.serializer=new WU,this.stateChangeCallbacks={open:[],close:[],error:[],message:[]},this.accessToken=null,this._connectionState="disconnected",this._wasManualDisconnect=!1,this._authPromise=null,this._heartbeatSentAt=null,this._resolveFetch=i=>i?(...a)=>i(...a):(...a)=>fetch(...a),!(!((n=r==null?void 0:r.params)===null||n===void 0)&&n.apikey))throw new Error("API key is required to connect to Realtime");this.apiKey=r.params.apikey,this.endPoint=`${t}/${Jg.websocket}`,this.httpEndpoint=nC(t),this._initializeOptions(r),this._setupReconnectionTimer(),this.fetch=this._resolveFetch(r==null?void 0:r.fetch)}connect(){if(!(this.isConnecting()||this.isDisconnecting()||this.conn!==null&&this.isConnected())){if(this._setConnectionState("connecting"),this.accessToken&&!this._authPromise&&this._setAuthSafely("connect"),this.transport)this.conn=new this.transport(this.endpointURL());else try{this.conn=DU.createWebSocket(this.endpointURL())}catch(t){this._setConnectionState("disconnected");const r=t.message;throw r.includes("Node.js")?new Error(`${r} 261 262To use Realtime in Node.js, you need to provide a WebSocket implementation: 263 264Option 1: Use Node.js 22+ which has native WebSocket support 265Option 2: Install and provide the "ws" package: 266 267 npm install ws 268 269 import ws from "ws" 270 const client = new RealtimeClient(url, { 271 ...options, 272 transport: ws 273 })`):new Error(`WebSocket not available: ${r}`)}this._setupConnectionHandlers()}}endpointURL(){return this._appendParams(this.endPoint,Object.assign({},this.params,{vsn:this.vsn}))}disconnect(t,r){if(!this.isDisconnecting())if(this._setConnectionState("disconnecting",!0),this.conn){const n=setTimeout(()=>{this._setConnectionState("disconnected")},100);this.conn.onclose=()=>{clearTimeout(n),this._setConnectionState("disconnected")},typeof this.conn.close=="function"&&(t?this.conn.close(t,r??""):this.conn.close()),this._teardownConnection()}else this._setConnectionState("disconnected")}getChannels(){return this.channels}async removeChannel(t){const r=await t.unsubscribe();return this.channels.length===0&&this.disconnect(),r}async removeAllChannels(){const t=await Promise.all(this.channels.map(r=>r.unsubscribe()));return this.channels=[],this.disconnect(),t}log(t,r,n){this.logger(t,r,n)}connectionState(){switch(this.conn&&this.conn.readyState){case wi.connecting:return ga.Connecting;case wi.open:return ga.Open;case wi.closing:return ga.Closing;default:return ga.Closed}}isConnected(){return this.connectionState()===ga.Open}isConnecting(){return this._connectionState==="connecting"}isDisconnecting(){return this._connectionState==="disconnecting"}channel(t,r={config:{}}){const n=`realtime:${t}`,i=this.getChannels().find(a=>a.topic===n);if(i)return i;{const a=new Bo(`realtime:${t}`,r,this);return this.channels.push(a),a}}push(t){const{topic:r,event:n,payload:i,ref:a}=t,o=()=>{this.encode(t,s=>{var l;(l=this.conn)===null||l===void 0||l.send(s)})};this.log("push",`${r} ${n} (${a})`,i),this.isConnected()?o():this.sendBuffer.push(o)}async setAuth(t=null){this._authPromise=this._performAuth(t);try{await this._authPromise}finally{this._authPromise=null}}_isManualToken(){return this._manuallySetToken}async sendHeartbeat(){var t;if(!this.isConnected()){try{this.heartbeatCallback("disconnected")}catch(r){this.log("error","error in heartbeat callback",r)}return}if(this.pendingHeartbeatRef){this.pendingHeartbeatRef=null,this._heartbeatSentAt=null,this.log("transport","heartbeat timeout. Attempting to re-establish connection");try{this.heartbeatCallback("timeout")}catch(r){this.log("error","error in heartbeat callback",r)}this._wasManualDisconnect=!1,(t=this.conn)===null||t===void 0||t.close(FU,"heartbeat timeout"),setTimeout(()=>{var r;this.isConnected()||(r=this.reconnectTimer)===null||r===void 0||r.sc
vendor: 3,886 bytes, line 273
273heduleTimeout()},ld.HEARTBEAT_TIMEOUT_FALLBACK);return}this._heartbeatSentAt=Date.now(),this.pendingHeartbeatRef=this._makeRef(),this.push({topic:"phoenix",event:"heartbeat",payload:{},ref:this.pendingHeartbeatRef});try{this.heartbeatCallback("sent")}catch(r){this.log("error","error in heartbeat callback",r)}this._setAuthSafely("heartbeat")}onHeartbeat(t){this.heartbeatCallback=t}flushSendBuffer(){this.isConnected()&&this.sendBuffer.length>0&&(this.sendBuffer.forEach(t=>t()),this.sendBuffer=[])}_makeRef(){let t=this.ref+1;return t===this.ref?this.ref=0:this.ref=t,this.ref.toString()}_leaveOpenTopic(t){let r=this.channels.find(n=>n.topic===t&&(n._isJoined()||n._isJoining()));r&&(this.log("transport",`leaving duplicate topic "${t}"`),r.unsubscribe())}_remove(t){this.channels=this.channels.filter(r=>r.topic!==t.topic)}_onConnMessage(t){this.decode(t.data,r=>{if(r.topic==="phoenix"&&r.event==="phx_reply"&&r.ref&&r.ref===this.pendingHeartbeatRef){const u=this._heartbeatSentAt?Date.now()-this._heartbeatSentAt:void 0;try{this.heartbeatCallback(r.payload.status==="ok"?"ok":"error",u)}catch(d){this.log("error","error in heartbeat callback",d)}this._heartbeatSentAt=null,this.pendingHeartbeatRef=null}const{topic:n,event:i,payload:a,ref:o}=r,s=o?`(${o})`:"",l=a.status||"";this.log("receive",`${l} ${n} ${i} ${s}`.trim(),a),this.channels.filter(u=>u._isMember(n)).forEach(u=>u._trigger(i,a,o)),this._triggerStateCallbacks("message",r)})}_clearTimer(t){var r;t==="heartbeat"&&this.heartbeatTimer?(clearInterval(this.heartbeatTimer),this.heartbeatTimer=void 0):t==="reconnect"&&((r=this.reconnectTimer)===null||r===void 0||r.reset())}_clearAllTimers(){this._clearTimer("heartbeat"),this._clearTimer("reconnect")}_setupConnectionHandlers(){this.conn&&("binaryType"in this.conn&&(this.conn.binaryType="arraybuffer"),this.conn.onopen=()=>this._onConnOpen(),this.conn.onerror=t=>this._onConnError(t),this.conn.onmessage=t=>this._onConnMessage(t),this.conn.onclose=t=>this._onConnClose(t),this.conn.readyState===wi.open&&this._onConnOpen())}_teardownConnection(){if(this.conn){if(this.conn.readyState===wi.open||this.conn.readyState===wi.connecting)try{this.conn.close()}catch(t){this.log("error","Error closing connection",t)}this.conn.onopen=null,this.conn.onerror=null,this.conn.onmessage=null,this.conn.onclose=null,this.conn=null}this._clearAllTimers(),this._terminateWorker(),this.channels.forEach(t=>t.teardown())}_onConnOpen(){this._setConnectionState("connected"),this.log("transport",`connected to ${this.endpointURL()}`),(this._authPromise||(this.accessToken&&!this.accessTokenValue?this.setAuth():Promise.resolve())).then(()=>{this.flushSendBuffer()}).catch(r=>{this.log("error","error waiting for auth on connect",r),this.flushSendBuffer()}),this._clearTimer("reconnect"),this.worker?this.workerRef||this._startWorkerHeartbeat():this._startHeartbeat(),this._triggerStateCallbacks("open")}_startHeartbeat(){this.heartbeatTimer&&clearInterval(this.heartbeatTimer),this.heartbeatTimer=setInterval(()=>this.sendHeartbeat(),this.heartbeatIntervalMs)}_startWorkerHeartbeat(){this.workerUrl?this.log("worker",`starting worker for from ${this.workerUrl}`):this.log("worker","starting default worker");const t=this._workerObjectUrl(this.workerUrl);this.workerRef=new Worker(t),this.workerRef.onerror=r=>{this.log("worker","worker error",r.message),this._terminateWorker()},this.workerRef.onmessage=r=>{r.data.event==="keepAlive"&&this.sendHeartbeat()},this.workerRef.postMessage({event:"start",interval:this.heartbeatIntervalMs})}_terminateWorker(){this.workerRef&&(this.log("worker","terminating worker"),this.workerRef.terminate(),this.workerRef=void 0)}_onConnClose(t){var r;this._setConnectionState("disconnected"),this.log("transport","close",t),this._triggerChanError(),this._clearTimer("heartbeat"),this._wasManualDisconnect||(r=this.reconnectTimer)===null||r===void 0||r.sc
273heduleTimeout(),this._triggerStateCallbacks("close",t)}_onConnError(t){this._setConnectionState("disconnected"),this.log("transport",`${t}`),this._triggerChanError(),this._triggerStateCallbacks("error",t);try{this.heartbeatCallback("error")}catch(r){this.log("error","error in heartbeat callback",r)}}_triggerChanError(){this.channels.forEach(t=>t._trigger(Vr.error))}_appendParams(t,r){if(Object.keys(r).length===0)return t;const n=t.match(/\?/)?"&":"?",i=new URLSearchParams(r);return`${t}${n}${i}`}_workerObjectUrl(t){let r;if(t)r=t;else{const n=new Blob([JU],{type:"application/javascript"});r=URL.createObjectURL(n)}return r}_setConnectionState(t,r=!1){this._connectionState=t,t==="connecting"?this._wasManualDisconnect=!1:t==="disconnecting"&&(this._wasManualDisconnect=r)}async _performAuth(t=null){let r,n=!1;if(t)r=t,n=!0;else if(this.accessToken)try{r=await this.accessToken()}catch(i){this.log("error","Error fetching access token from callback",i),r=this.accessTokenValue}else r=this.accessTokenValue;n?this._manuallySetToken=!0:this.accessToken&&(this._manuallySetToken=!1),this.accessTokenValue!=r&&(this.accessTokenValue=r,this.channels.forEach(i=>{const a={access_token:r,version:BU};r&&i.updateJoinPayload(a),i.joinedOnce&&i._isJoined()&&i._push(Vr.access_token,{access_token:r})}))}async _waitForAuthIfNeeded(){this._authPromise&&await this._authPromise}_setAuthSafely(t="general"){this._isManualToken()||this.setAuth().catch(r=>{this.log("error",`Error setting auth in ${t}`,r)})}_triggerStateCallbacks(t,r){try{this.stateChangeCallbacks[t].forEach(n=>{try{n(r)}catch(i){this.log("error",`error in ${t} callback`,i)}})}catch(n){this.log("error",`error triggering ${t} callbacks`,n)}}_setupReconnectionTimer(){this.reconnectTimer=new tC(async()=>{setTimeout(async()=>{await this._waitForAuthIfNeeded(),this.isConnected()||this.connect()},ld.RECONNECT_DELAY)},this.reconnectAfterMs)}_initializeOptions(t){var r,n,i,a,o,s,l,u,d,c,f,h;switch(this.transport=(r=t==null?void 0:t.transport)!==null&&r!==void 0?r:null,this.timeout=(n=t==null?void 0:t.timeout)!==null&&n!==void 0?n:Qg,this.heartbeatIntervalMs=(i=t==null?void 0:t.heartbeatIntervalMs)!==null&&i!==void 0?i:ld.HEARTBEAT_INTERVAL,this.worker=(a=t==null?void 0:t.worker)!==null&&a!==void 0?a:!1,this.accessToken=(o=t==null?void 0:t.accessToken)!==null&&o!==void 0?o:null,this.heartbeatCallback=(s=t==null?void 0:t.heartbeatCallback)!==null&&s!==void 0?s:Qm,this.vsn=(l=t==null?void 0:t.vsn)!==null&&l!==void 0?l:x_,t!=null&&t.params&&(this.params=t.params),t!=null&&t.logger&&(this.logger=t.logger),(t!=null&&t.logLevel||t!=null&&t.log_level)&&(this.logLevel=t.logLevel||t.log_level,this.params=Object.assign(Object.assign({},this.params),{log_level:this.logLevel})),this.reconnectAfterMs=(u=t==null?void 0:t.reconnectAfterMs)!==null&&u!==void 0?u:v=>XU[v-1]||QU,this.vsn){case UU:this.encode=(d=t==null?void 0:t.encode)!==null&&d!==void 0?d:(v,m)=>m(JSON.stringify(v)),this.decode=(c=t==null?void 0:t.decode)!==null&&c!==void 0?c:(v,m)=>m(JSON.parse(v));break;case eC:this.encode=(f=t==null?void 0:t.encode)!==null&&f!==void 0?f:this.serializer.encode.bind(this.serializer),this.decode=(h=t==null?void 0:t.decode)!==null&&h!==void 0?h:this.serializer.decode.bind(this.serializer);break;default:throw new Error(`Unsupported serializer version: ${this.vsn}`)}if(this.worker){if(typeof window<"u"&&!window.Worker)throw new Error("Web Worker is not supported");this.workerUrl=t==null?void 0:t.workerUrl}}}var ku=class extends Error{constructor(e,t){var r;super(e),this.name="IcebergError",this.status=t.status,this.icebergType=t.icebergType,this.icebergCode=t.icebergCode,this.details=t.details,this.isCommitStateUnknown=t.icebergType==="CommitStateUnknownException"||[500,502,504].includes(t.status)&&((r=t.icebergType)==null?void 0:r.includes("CommitState"))===!0}isNotFound(){return this.status===404}isConflict(){return this.status===409}isAuthenticationTimeout(){return this.status===419}};function eF(e,t,r){const n=new URL(t,e);if(r)for(const[i,a]of Object.entries(r))a!==void 0&&n.searchParams.set(i,a);return n.toString()}async function tF(e){return!e||e.type==="none"?{}:e.type==="bearer"?{Authorization:`Bearer ${e.token}`}:e.type==="header"?{[e.name]:e.value}:e.type==="custom"?await e.getHeaders():{}}function rF(e){const t=e.fetchImpl??globalThis.fetch;return{async request({method:r,path:n,query:i,body:a,headers:o}){const s=eF(e.baseUrl,n,i),l=await tF(e.auth),u=await t(s,{method:r,headers:{...a?{"Content-Type":"application/json"}:{},...l,...o},body:a?JSON.stringify(a):void 0}),d=await u.text(),c=(u.headers.get("content-type")||"").includes("application/json"),f=c&&d?JSON.parse(d):d;if(!u.ok){const h=c?f:void 0,v=h==null?void 0:h.error;throw new ku((v==null?void 0:v.message)??`Request failed with status ${u.status}`,{status:u.status,icebergType:v==null?void 0:v.type,icebergCode:v==null?void 0:v.code,details:h})}return{status:u.status,headers:u.headers,data:f}}}}function ud(e){return e.join("�")}var nF=class{constructor(e,t=""){this.client=e,this.prefix=t}async listNamespaces(e){const t=e?{parent:ud(e.namespace)}:void 0;return(await this.client.request({method:"GET",path:`${this.prefix}/namespaces`,query:t})).data.namespaces.map(n=>({namespace:n}))}async createNamespace(e,t){const r={namespace:e.namespace,properties:t==null?void 0:t.properties};return(await this.client.request({method:"POST",path:`${this.prefix}/namespaces`,body:r})).data}async dropNamespace(e){await this.client.request({method:"DELETE",path:`${this.prefix}/namespaces/${ud(e.namespace)}`})}async loadNamespaceMetadata(e){return{properties:(await this.client.request({method:"GET",path:`${this.prefix}/namespaces/${ud(e.namespace)}`})).data.properties}}async namespaceExists(e){try{return await this.client.request({method:"HEAD",path:`${this.prefix}/namespaces/${ud(e.namespace)}`}),!0}catch(t){if(t instanceof ku&&t.status===404)return!1;throw t}}async createNamespaceIfNotExists(e,t){try{return await this.createNamespace(e,t)}catch(r){if(r instanceof ku&&r.status===409)return;throw r}}};function co(e){return e.join("�")}var iF=class{constructor(e,t="",r){this.client=e,this.prefix=t,this.accessDelegation=r}async listTables(e){return(await this.client.request({method:"GET",path:`${this.prefix}/namespaces/${co(e.namespace)}/tables`})).data.identifiers}async createTable(e,t){const r={};return this.accessDelegation&&(r["X-Iceberg-Access-Delegation"]=this.accessDelegation),(await this.client.request({method:"POST",path:`${this.prefix}/namespaces/${co(e.namespace)}/tables`,body:t,headers:r})).data.metadata}async updateTable(e,t){const r=await this.client.request({method:"POST",path:`${this.prefix}/namespaces/${co(e.namespace)}/tables/${e.name}`,body:t});return{"metadata-location":r.data["metadata-location"],metadata:r.data.metadata}}async dropTable(e,t){await this.client.request({method:"DELETE",path:`${this.prefix}/namespaces/${co(e.namespace)}/tables/${e.name}`,query:{purgeRequested:String((t==null?void 0:t.purge)??!1)}})}async loadTable(e){const t={};return this.accessDelegation&&(t["X-Iceberg-Access-Delegation"]=this.accessDelegation),(await this.client.request({method:"GET",path:`${this.prefix}/namespaces/${co(e.namespace)}/tables/${e.name}`,headers:t})).data.metadata}async tableExists(e){const t={};this.accessDelegation&&(t["X-Iceberg-Access-Delegation"]=this.accessDelegation);try{return await this.client.request({method:"HEAD",path:`${this.prefix}/namespaces/${co(e.namespace)}/tables/${e.name}`,headers:t}),!0}catch(r){if(r instanceof ku&&r.status===404)return!1;throw r}}async createTableIfNotExists(e,t){try{return await this.createTable(e,t)}catch(r){if(r instanceof ku&&r.status===409)return await this.loadTable({namespace:e.namespace,name:t.name});throw r}}},aF=class{constructor(e){var n;let t="v1";e.catalogName&&(t+=`/${e.catalogName}`);const r=e.baseUrl.endsWith("/")?e.baseUrl:`${e.baseUrl}/`;this.client=rF({baseUrl:r,auth:e.auth,fetchImpl:e.fetch}),this.accessDelegation=(n=e.accessDelegation)==null?void 0:n.join(","),this.namespaceOps=new nF(this.client,t),this.tableOps=new iF(this.client,t,this.accessDelegation)}async listNamespaces(e){return this.namespaceOps.listNamespaces(e)}async createNamespace(e,t){return this.namespaceOps.createNamespace(e,t)}async dropNamespace(e){await this.namespaceOps.dropNamespace(e)}async loadNamespaceMetadata(e){return this.namespaceOps.loadNamespaceMetadata(e)}async listTables(e){return this.tableOps.listTables(e)}
273async createTable(e,t){return this.tableOps.createTable(e,t)}async updateTable(e,t){return this.tableOps.updateTable(e,t)}async dropTable(e,t){await this.tableOps.dropTable(e,t)}async loadTable(e){return this.tableOps.loadTable(e)}async namespaceExists(e){return this.namespaceOps.namespaceExists(e)}async tableExists(e){return this.tableOps.tableExists(e)}async createNamespaceIfNotExists(e,t){return this.namespaceOps.createNamespaceIfNotExists(e,t)}async createTableIfNotExists(e,t){return this.tableOps.createTableIfNotExists(e,t)}},hp=class extends Error{constructor(e,t="storage",r,n){super(e),this.__isStorageError=!0,this.namespace=t,this.name=t==="vectors"?"StorageVectorsError":"StorageError",this.status=r,this.statusCode=n}};function pp(e){return typeof e=="object"&&e!==null&&"__isStorageError"in e}var cd=class extends hp{constructor(e,t,r,n="storage"){super(e,n,t,r),this.name=n==="vectors"?"StorageVectorsApiError":"StorageApiError",this.status=t,this.statusCode=r}toJSON(){return{name:this.name,message:this.message,status:this.status,statusCode:this.statusCode}}},iC=class extends hp{constructor(e,t,r="storage"){super(e,r),this.name=r==="vectors"?"StorageVectorsUnknownError":"StorageUnknownError",this.originalError=t}};const oF=e=>e?(...t)=>e(...t):(...t)=>fetch(...t),sF=e=>{if(typeof e!="object"||e===null)return!1;const t=Object.getPrototypeOf(e);return(t===null||t===Object.prototype||Object.getPrototypeOf(t)===null)&&!(Symbol.toStringTag in e)&&!(Symbol.iterator in e)},ey=e=>{if(Array.isArray(e))return e.map(r=>ey(r));if(typeof e=="function"||e!==Object(e))return e;const t={};return Object.entries(e).forEach(([r,n])=>{const i=r.replace(/([-_][a-z])/gi,a=>a.toUpperCase().replace(/[-_]/g,""));t[i]=ey(n)}),t},lF=e=>!e||typeof e!="string"||e.length===0||e.length>100||e.trim()!==e||e.includes("/")||e.includes("\\")?!1:/^[\w!.\*'() &$@=;:+,?-]+$/.test(e);function Pu(e){"@babel/helpers - typeof";return Pu=typeof Symbol=="function"&&typeof Symbol.iterator=="symbol"?function(t){return typeof t}:function(t){return t&&typeof Symbol=="function"&&t.constructor===Symbol&&t!==Symbol.prototype?"symbol":typeof t},Pu(e)}function uF(e,t){if(Pu(e)!="object"||!e)return e;var r=e[Symbol.toPrimitive];if(r!==void 0){var n=r.call(e,t||"default");if(Pu(n)!="object")return n;throw new TypeError("@@toPrimitive must return a primitive value.")}return(t==="string"?String:Number)(e)}function cF(e){var t=uF(e,"string");return Pu(t)=="symbol"?t:t+""}function dF(e,t,r){return(t=cF(t))in e?Object.defineProperty(e,t,{value:r,enumerable:!0,configurable:!0,writable:!0}):e[t]=r,e}function E_(e,t){var r=Object.keys(e);if(Object.getOwnPropertySymbols){var n=Object.getOwnPropertySymbols(e);t&&(n=n.filter(function(i){return Object.getOwnPropertyDescriptor(e,i).enumerable})),r.push.apply(r,n)}return r}function ee(e){for(var t=1;t<arguments.length;t++){var r=arguments[t]!=null?arguments[t]:{};t%2?E_(Object(r),!0).forEach(function(n){dF(e,n,r[n])}):Object.getOwnPropertyDescriptors?Object.defineProperties(e,Object.getOwnPropertyDescriptors(r)):E_(Object(r)).forEach(function(n){Object.defineProperty(e,n,Object.getOwnPropertyDescriptor(r,n))})}return e}const k_=e=>{var t;return e.msg||e.message||e.error_description||(typeof e.error=="string"?e.error:(t=e.error)===null||t===void 0?void 0:t.message)||JSON.stringify(e)},fF=async(e,t,r,n)=>{if(e&&typeof e=="object"&&"status"in e&&"ok"in e&&typeof e.status=="number"&&!(r!=null&&r.noResolveJson)){const i=e,a=i.status||500;if(typeof i.json=="function")i.json().then(o=>{const s=(o==null?void 0:o.statusCode)||(o==null?void 0:o.code)||a+"";t(new cd(k_(o),a,s,n))}).catch(()=>{if(n==="vectors"){const o=a+"";t(new cd(i.statusText||`HTTP ${a} error`,a,o,n))}else{const o=a+"";t(new cd(i.statusText||`HTTP ${a} error`,a,o,n))}});else{const o=a+"";t(new cd(i.statusText||`HTTP ${a} error`,a,o,n))}}else t(new iC(k_(e),e,n))},hF=(e,t,r,n)=>{const i={method:e,headers:(t==null?void 0:t.headers)||{}};return e==="GET"||e==="HEAD"||!n?ee(ee({},i),r):(sF(n)?(i.headers=ee({"Content-Type":"application/json"},t==null?void 0:t.headers),i.body=JSON.stringify(n)):i.body=n,t!=null&&t.duplex&&(i.duplex=t.duplex),ee(ee({},i),r))};async function xl(e,t,r,n,i,a,o){return new Promise((s,l)=>{e(r,hF(t,n,i,a)).then(u=>{if(!u.ok)throw u;if(n!=null&&n.noResolveJson)return u;if(o==="vectors"){const d=u.headers.get("content-type");if(u.headers.get("content-length")==="0"||u.status===204)return{};if(!d||!d.includes("application/json"))return{}}return u.json()}).then(u=>s(u)).catch(u=>fF(u,l,n,o))})}function aC(e="storage"){return{get:async(t,r,n,i)=>xl(t,"GET",r,n,i,void 0,e),post:async(t,r,n,i,a)=>xl(t,"POST",r,i,a,n,e),put:async(t,r,n,i,a)=>xl(t,"PUT",r,i,a,n,e),head:async(t,r,n,i)=>xl(t,"HEAD",r,ee(ee({},n),{},{noResolveJson:!0}),i,void 0,e),remove:async(t,r,n,i,a)=>xl(t,"DELETE",r,i,a,n,e)}}const pF=aC("storage"),{get:Au,post:zr,put:ty,head:mF,remove:Yb}=pF,or=aC("vectors");var Js=class{constructor(e,t={},r,n="storage"){this.shouldThrowOnError=!1,this.url=e,this.headers=t,this.fetch=oF(r),this.namespace=n}throwOnError(){return this.shouldThrowOnError=!0,this}setHeader(e,t){return this.headers=ee(ee({},this.headers),{},{[e]:t}),this}async handleOperation(e){var t=this;try{return{data:await e(),error:null}}catch(r){if(t.shouldThrowOnError)throw r;if(pp(r))return{data:null,error:r};throw r}}},vF=class{constructor(e,t){this.downloadFn=e,this.shouldThrowOnError=t}then(e,t){return this.execute().then(e,t)}async execute(){var e=this;try{return{data:(await e.downloadFn()).body,error:null}}catch(t){if(e.shouldThrowOnError)throw t;if(pp(t))return{data:null,error:t};throw t}}};let oC;oC=Symbol.toStringTag;var gF=class{constructor(e,t){this.downloadFn=e,this.shouldThrowOnError=t,this[oC]="BlobDownloadBuilder",this.promise=null}asStream(){return new vF(this.downloadFn,this.shouldThrowOnError)}then(e,t){return this.getPromise().then(e,t)}catch(e){return this.getPromise().catch(e)}finally(e){return this.getPromise().finally(e)}getPromise(){return this.promise||(this.promise=this.execute()),this.promise}async execute(){var e=this;try{return{data:await(await e.downloadFn()).blob(),error:null}}catch(t){if(e.shouldThrowOnError)throw t;if(pp(t))return{data:null,error:t};throw t}}};const yF={limit:100,offset:0,sortBy:{column:"name",order:"asc"}},P_={cacheControl:"3600",contentType:"text/plain;charset=UTF-8",upsert:!1};var bF=class extends Js{constructor(e,t={},r,n){super(e,t,n,"storage"),this.bucketId=r}async uploadOrUpdate(e,t,r,n){var i=this;return i.handleOperation(async()=>{let a;const o=ee(ee({},P_),n);let s=ee(ee({},i.headers),e==="POST"&&{"x-upsert":String(o.upsert)});const l=o.metadata;typeof Blob<"u"&&r instanceof Blob?(a=new FormData,a.append("cacheControl",o.cacheControl),l&&a.append("metadata",i.encodeMetadata(l)),a.append("",r)):typeof FormData<"u"&&r instanceof FormData?(a=r,a.has("cacheControl")||a.append("cacheControl",o.cacheControl),l&&!a.has("metadata")&&a.append("metadata",i.encodeMetadata(l))):(a=r,s["cache-control"]=`max-age=${o.cacheControl}`,s["content-type"]=o.contentType,l&&(s["x-metadata"]=i.toBase64(i.encodeMetadata(l))),(typeof ReadableStream<"u"&&a
273instanceof ReadableStream||a&&typeof a=="object"&&"pipe"in a&&typeof a.pipe=="function")&&!o.duplex&&(o.duplex="half")),n!=null&&n.headers&&(s=ee(ee({},s),n.headers));const u=i._removeEmptyFolders(t),d=i._getFinalPath(u),c=await(e=="PUT"?ty:zr)(i.fetch,`${i.url}/object/${d}`,a,ee({headers:s},o!=null&&o.duplex?{duplex:o.duplex}:{}));return{path:u,id:c.Id,fullPath:c.Key}})}async upload(e,t,r){return this.uploadOrUpdate("POST",e,t,r)}async uploadToSignedUrl(e,t,r,n){var i=this;const a=i._removeEmptyFolders(e),o=i._getFinalPath(a),s=new URL(i.url+`/object/upload/sign/${o}`);return s.searchParams.set("token",t),i.handleOperation(async()=>{let l;const u=ee({upsert:P_.upsert},n),d=ee(ee({},i.headers),{"x-upsert":String(u.upsert)});return typeof Blob<"u"&&r instanceof Blob?(l=new FormData,l.append("cacheControl",u.cacheControl),l.append("",r)):typeof FormData<"u"&&r instanceof FormData?(l=r,l.append("cacheControl",u.cacheControl)):(l=r,d["cache-control"]=`max-age=${u.cacheControl}`,d["content-type"]=u.contentType),{path:a,fullPath:(await ty(i.fetch,s.toString(),l,{headers:d})).Key}})}async createSignedUploadUrl(e,t){var r=this;return r.handleOperation(async()=>{let n=r._getFinalPath(e);const i=ee({},r.headers);t!=null&&t.upsert&&(i["x-upsert"]="true");const a=await zr(r.fetch,`${r.url}/object/upload/sign/${n}`,{},{headers:i}),o=new URL(r.url+a.url),s=o.searchParams.get("token");if(!s)throw new hp("No token returned by API");return{signedUrl:o.toString(),path:e,token:s}})}async update(e,t,r){return this.uploadOrUpdate("PUT",e,t,r)}async move(e,t,r){var n=this;return n.handleOperation(async()=>await zr(n.fetch,`${n.url}/object/move`,{bucketId:n.bucketId,sourceKey:e,destinationKey:t,de
273stinationBucket:r==null?void 0:r.destinationBucket},{headers:n.headers}))}async copy(e,t,r){var n=this;return n.handleOperation(async()=>({path:(await zr(n.fetch,`${n.url}/object/copy`,{bucketId:n.bucketId,sourceKey:e,destinationKey:t,destinationBucket:r==null?void 0:r.destinationBucket},{headers:n.headers})).Key}))}async createSignedUrl(e,t,r){var n=this;return n.handleOperation(async()=>{let i=n._getFinalPath(e),a=await zr(n.fetch,`${n.url}/object/sign/${i}`,ee({expiresIn:t},r!=null&&r.transform?{transform:r.transform}:{}),{headers:n.headers});const o=r!=null&&r.download?`&download=${r.download===!0?"":r.download}`:"";return{signedUrl:encodeURI(`${n.url}${a.signedURL}${o}`)}})}async createSignedUrls(e,t,r){var n=this;return n.handleOperation(async()=>{const i=await zr(n.fetch,`${n.url}/object/sign/${n.bucketId}`,{expiresIn:t,paths:e},{headers:n.headers}),a=r!=null&&r.download?`&download=${r.download===!0?"":r.download}`:"";return i.map(o=>ee(ee({},o),{},{signedUrl:o.signedURL?encodeURI(`${n.url}${o.signedURL}${a}`):null}))})}download(e,t,r){const n=typeof(t==null?void 0:t.transform)<"u"?"render/image/authenticated":"object",i=this.transformOptsToQueryString((t==null?void 0:t.transform)||{}),a=i?`?${i}`:"",o=this._getFinalPath(e),s=()=>Au(this.fetch,`${this.url}/${n}/${o}${a}`,{headers:this.headers,noResolveJson:!0},r);return new gF(s,this.shouldThrowOnError)}async info(e){var t=this;const r=t._getFinalPath(e);return t.handleOperation(async()=>ey(await Au(t.fetch,`${t.url}/object/info/${r}`,{headers:t.headers})))}async exists(e){var t=this;const r=t._getFinalPath(e);try{return await mF(t.fetch,`${t.url}/object/${r}`,{headers:t.headers}),{data:!0,error:null}}catch(n){if(t.shouldThrowOnError)throw n;if(pp(n)&&n instanceof iC){const i=n.originalError;if([400,404].includes(i==null?void 0:i.status))return{data:!1,error:n}}throw n}}getPublicUrl(e,t){const r=this._getFinalPath(e),n=[],i=t!=null&&t.download?`download=${t.download===!0?"":t.download}`:"";i!==""&&n.push(i);const a=typeof(t==null?void 0:t.transform)<"u"?"render/image":"object",o=this.transformOptsToQueryString((t==null?void 0:t.transform)||{});o!==""&&n.push(o);let s=n.join("&");return s!==""&&(s=`?${s}`),{data:{publicUrl:encodeURI(`${this.url}/${a}/public/${r}${s}`)}}}async remove(e){var t=this;return t.handleOperation(async()=>await Yb(t.fetch,`${t.url}/object/${t.bucketId}`,{prefixes:e},{headers:t.headers}))}async list(e,t,r){var n=this;return n.handleOperation(async()=>{const i=ee(ee(ee({},yF),t),{},{prefix:e||""});return await zr(n.fetch,`${n.url}/object/list/${n.bucketId}`,i,{headers:n.headers},r)})}async listV2(e,t){var r=this;return r.handleOperation(async()=>{const n=ee({},e);return await zr(r.fetch,`${r.url}/object/list-v2/${r.bucketId}`,n,{headers:r.headers},t)})}encodeMetadata(e){return JSON.stringify(e)}toBase64(e){return typeof Buffer<"u"?Buffer.from(e).toString("base64"):btoa(e)}_getFinalPath(e){return`${this.bucketId}/${e.replace(/^\/+/,"")}`}_removeEmptyFolders(e){return e.replace(/^\/|\/$/g,"").replace(/\/+/g,"/")}transformOptsToQueryString(e){const t=[];return e.width&&t.push(`width=${e.width}`),e.height&&t.push(`height=${e.height}`),e.resize&&t.push(`resize=${e.resize}`),e.format&&t.push(`format=${e.format}`),e.quality&&t.push(`quality=${e.quality}`),t.join("&")}};const wF="2.97.0",kc={"X-Client-Info":`storage-js/${wF}`};var xF=class extends Js{constructor(e,t={},r,n){const i=new URL(e);n!=null&&n.useNewHostname&&/supabase\.(co|in|red)$/.test(i.hostname)&&!i.hostname.includes("storage.supabase.")&&(i.hostname=i.hostname.replace("supabase.","storage.supabase."));const a=i.href.replace(/\/$/,""),o=ee(ee({},kc),t);super(a,o,r,"storage")}async listBuckets(e){var t=this;return t.handleOperation(async()=>{const r=t.listBucketOptionsToQueryString(e);return await Au(t.fetch,`${t.url}/bucket${r}`,{headers:t.headers})})}async getBucket(e){var t=this;return t.handleOperation(async()=>await Au(t.fetch,`${t.url}/bucket/${e}`,{headers:t.headers}))}async createBucket(e,t={public:!1}){var r=this;return r.handleOperation(async()=>await zr(r.fetch,`${r.url}/bucket`,{id:e,name:e,type:t.type,public:t.public,file_size_limit:t.fileSizeLimit,allowed_mime_types:t.allowedMimeTypes},{headers:r.headers}))}async updateBucket(e,t){var r=this;return r.handleOperation(async()=>await ty(r.fetch,`${r.url}/bucket/${e}`,{id:e,name:e,public:t.public,file_size_limit:t.fileSizeLimit,allowed_mime_types:t.allowedMimeTypes},{headers:r.headers}))}async emptyBucket(e){var t=this;return t.handleOperation(async()=>await zr(t.fetch,`${t.url}/bucket/${e}/empty`,{},{headers:t.headers}))}async deleteBucket(e){var t=this;return t.handleOperation(async()=>await Yb(t.fetch,`${t.url}/bucket/${e}`,{},{headers:t.headers}))}listBucketOptionsToQueryString(e){const t={};return e&&("limit"in e&&(t.limit=String(e.limit)),"offset"in e&&(t.offset=String(e.offset)),e.search&&(t.search=e.search),e.sortColumn&&(t.sortColumn=e.sortColumn),e.sortOrder&&(t.sortOrder=e.sortOrder)),Object.keys(t).length>0?"?"+new URLSearchParams(t).toString():""}},_F=class extends Js{constructor(e,t={},r){const n=e.replace(/\/$/,""),i=ee(ee({},kc),t);super(n,i,r,"storage")}async createBucket(e){var t=this;return t.handleOperation(async()=>await zr(t.fetch,`${t.url}/bucket`,{name:e},{headers:t.headers}))}async listBuckets(e){var t=this;return t.handleOperation(async()=>
273{const r=new URLSearchParams;(e==null?void 0:e.limit)!==void 0&&r.set("limit",e.limit.toString()),(e==null?void 0:e.offset)!==void 0&&r.set("offset",e.offset.toString()),e!=null&&e.sortColumn&&r.set("sortColumn",e.sortColumn),e!=null&&e.sortOrder&&r.set("sortOrder",e.sortOrder),e!=null&&e.search&&r.set("search",e.search);const n=r.toString(),i=n?`${t.url}/bucket?${n}`:`${t.url}/bucket`;return await Au(t.fetch,i,{headers:t.headers})})}async deleteBucket(e){var t=this;return t.handleOperation(async()=>await Yb(t.fetch,`${t.url}/bucket/${e}`,{},{headers:t.headers}))}from(e){var t=this;if(!lF(e))throw new hp("Invalid bucket name: File, folder, and bucket names must follow AWS object key naming guidelines and should avoid the use of any other characters.");const r=new aF({baseUrl:this.url,catalogName:e,auth:{type:"custom",getHeaders:async()=>t.headers},fetch:this.fetch}),n=this.shouldThrowOnError;return new Proxy(r,{get(i,a){const o=i[a];return typeof o!="function"?o:async(...s)=>{try{return{data:await o.apply(i,s),error:null}}catch(l){if(n)throw l;return{data:null,error:l}}}}})}},SF=class extends Js{constructor(e,t={},r){const n=e.replace(/\/$/,""),i=ee(ee({},kc),{},{"Content-Type":"application/json"},t);super(n,i,r,"vectors")}async createIndex(e){var t=this;return t.handleOperation(async()=>await or.post(t.fetch,`${t.url}/CreateIndex`,e,{headers:t.headers})||{})}async getIndex(e,t){var r=this;return r.handleOperation(async()=>await or.post(r.fetch,`${r.url}/GetIndex`,{vectorBucketName:e,indexName:t},{headers:r.headers}))}async listIndexes(e){var t=this;return t.handleOperation(async()=>await or.post(t.fetch,`${t.url}/ListIndexes`,e,{headers:t.headers}))}async deleteIndex(e,t){var r=this;return r.handleOperation(async()=>await or.post(r.fetch,`${r.url}/DeleteIndex`,{vectorBucketName:e,indexName:t},{headers:r.headers})||{})}},OF=class extends Js{constructor(e,t={},r){const n=e.replace(/\/$/,""),i=ee(ee({},kc),{},{"Content-Type":"application/json"},t);super(n,i,r,"vectors")}async putVectors(e){var t=this;if(e.vectors.length<1||e.vectors.length>500)throw new Error("Vector batch size must be between 1 and 500 items");return t.handleOperation(async()=>await or.post(t.fetch,`${t.url}/PutVectors`,e,{headers:t.headers})||{})}async getVectors(e){var t=this;return t.handleOperation(async()=>await or.post(t.fetch,`${t.url}/GetVectors`,e,{headers:t.headers}))}async listVectors(e){var t=this;if(e.segmentCount!==void 0){if(e.segmentCount<1||e.segmentCount>16)throw new Error("segmentCount must be between 1 and 16");if(e.segmentIndex!==void 0&&(e.segmentIndex<0||e.segmentIndex>=e.segmentCount))throw new Error(`segmentIndex must be between 0 and ${e.segmentCount-1}`)}return t.handleOperation(async()=>await or.post(t.fetch,`${t.url}/ListVectors`,e,{headers:t.headers}))}async queryVectors(e){var t=this;return t.handleOperation(async()=>await or.post(t.fetch,`${t.url}/QueryVectors`,e,{headers:t.headers}))}async deleteVectors(e){var t=this;if(e.keys.length<1||e.keys.length>500)throw new Error("Keys batch size must be between 1 and 500 items");return t.handleOperation(async()=>await or.post(t.fetch,`${t.url}/DeleteVectors`,e,{headers:t.headers})||{})}},EF=class extends Js{constructor(e,t={},r){const n=e.replace(/\/$/,""),i=ee(ee({},kc),{},{"Content-Type":"application/json"},t);super(n,i,r,"vectors")}async createBucket(e){var t=this;return t.handleOperation(async()=>await or.post(t.fetch,`${t.url}/CreateVectorBucket`,{vectorBucketName:e},{headers:t.headers})||{})}async getBucket(e){var t=this;return t.handleOperation(async()=>await or.post(t.fetch,`${t.url}/GetVectorBucket`,{vectorBucketName:e},{headers:t.headers}))}async listBuckets(e={}){var t=this;return t.handleOperation(async()=>await or.post(t.fetch,`${t.url}/ListVectorBuckets`,e,{headers:t.headers}))}async deleteBucket(e){var t=this;return t.handleOperation(async()=>await or.post(t.fetch,`${t.url}/DeleteVectorBucket`,{vectorBucketName:e},{headers:t.headers})||{})}},kF=class extends EF{constructor(e,t={}){super(e,t.headers||{},t.fetch)}from(e){return new PF(this.url,this.headers,e,this.fetch)}async createBucket(e){var t=()=>super.createBucket,r=this;return t().call(r,e)}async getBucket(e){var t=()=>super.getBucket,r=this;return t().call(r,e)}async listBuckets(e={}){var t=()=>super.listBuckets,r=this;return t().call(r,e)}async deleteBucket(e){var t=()=>super.deleteBucket,r=this;return t().call(r,e)}},PF=class extends SF{constructor(e,t,r,n){super(e,t,n),this.vectorBucketName=r}async createIndex(e){var t=()=>super.createIndex,r=this;return t().call(r,ee(ee({},e),{},{vectorBucketName:r.vectorBucketName}))}
273async listIndexes(e={}){var t=()=>super.listIndexes,r=this;return t().call(r,ee(ee({},e),{},{vectorBucketName:r.vectorBucketName}))}async getIndex(e){var t=()=>super.getIndex,r=this;return t().call(r,r.vectorBucketName,e)}async deleteIndex(e){var t=()=>super.deleteIndex,r=this;return t().call(r,r.vectorBucketName,e)}index(e){return new AF(this.url,this.headers,this.vectorBucketName,e,this.fetch)}},AF=class extends OF{constructor(e,t,r,n,i){super(e,t,i),this.vectorBucketName=r,this.indexName=n}async putVectors(e){var t=()=>super.putVectors,r=this;return t().call(r,ee(ee({},e),{},{vectorBucketName:r.vectorBucketName,indexName:r.indexName}))}async getVectors(e){var t=()=>super.getVectors,r=this;return t().call(r,ee(ee({},e),{},{vectorBucketName:r.vectorBucketName,indexName:r.indexName}))}async listVectors(e={}){var t=()=>super.listVectors,r=this;return t().call(r,ee(ee({},e),{},{vectorBucketName:r.vectorBucketName,indexName:r.indexName}))}async queryVectors(e){var t=()=>super.queryVectors,r=this;return t().call(r,ee(ee({},e),{},{vectorBucketName:r.vectorBucketName,indexName:r.indexName}))}async deleteVectors(e){var t=()=>super.deleteVectors,r=this;return t().call(r,ee(ee({},e),{},{vectorBucketName:r.vectorBucketName,indexName:r.indexName}))}},jF=class extends xF{constructor(e,t={},r,n){super(e,t,r,n)}from(e){return new bF(this.url,this.headers,e,this.fetch)}get vectors(){return new kF(this.url+"/vector",{headers:this.headers,fetch:this.fetch})}get analytics(){return new _F(this.url+"/iceberg",this.headers,this.fetch)}};const sC="2.97.0",Oo=30*1e3,ry=3,Jm=ry*Oo,TF="http://localhost:9999",CF="supabase.auth.token",NF={"X-Client-Info":`gotrue-js/${sC}`},ny="X-Supabase-Api-Version",lC={"2024-01-01":{timestamp:Date.parse("2024-01-01T00:00:00.0Z"),name:"2024-01-01"}},$F=/^([a-z0-9_-]{4})*($|[a-z0-9_-]{3}$|[a-z0-9_-]{2}$)$/i,RF=10*60*1e3;class ju extends Error{constructor(t,r,n){super(t),this.__isAuthError=!0,this.name="AuthError",this.status=r,this.code=n}}function J(e){return typeof e=="object"&&e!==null&&"__isAuthError"in e}class IF extends ju{constructor(t,r,n){super(t,r,n),this.name="AuthApiError",this.status=r,this.code=n}}function MF(e){return J(e)&&e.name==="AuthApiError"}class ya extends ju{constructor(t,r){super(t),this.name="AuthUnknownError",this.originalError=r}}class ai extends ju{constructor(t,r,n,i){super(t,n,i),this.name=r,this.status=n}}class tr extends ai{constructor(){super("Auth session missing!","AuthSessionMissingError",400,void 0)}}function Zm(e){return J(e)&&e.name==="AuthSessionMissingError"}class fo extends ai{constructor(){super("Auth session or user missing","AuthInvalidToken
273ResponseError",500,void 0)}}class dd extends ai{constructor(t){super(t,"AuthInvalidCredentialsError",400,void 0)}}class fd extends ai{constructor(t,r=null){super(t,"AuthImplicitGrantRedirectError",500,void 0),this.details=null,this.details=r}toJSON(){return{name:this.name,message:this.message,status:this.status,details:this.details}}}function DF(e){return J(e)&&e.name==="AuthImplicitGrantRedirectError"}class A_ extends ai{constructor(t,r=null){super(t,"AuthPKCEGrantCodeExchangeError",500,void 0),this.details=null,this.details=r}toJSON(){return{name:this.name,message:this.message,status:this.status,details:this.details}}}class LF extends ai{constructor(){super("PKCE code verifier not found in storage. This can happen if the auth flow was initiated in a different browser or device, or if the storage was cleared. For SSR frameworks (Next.js, SvelteKit, etc.), use @supabase/ssr on both the server and client to store the code verifier in cookies.","AuthPKCECodeVerifierMissingError",400,"pkce_code_verifier_not_found")}}class iy extends ai{constructor(t,r){super(t,"AuthRetryableFetchError",r,void 0)}}function ev(e){return J(e)&&e.name==="AuthRetryableFetchError"}class j_ extends ai{constructor(t,r,n){super(t,"AuthWeakPasswordError",r,"weak_password"),this.reasons=n}}class ay extends ai{constructor(t){super(t,"AuthInvalidJwtError",400,"invalid_jwt")}}const jf="ABCDEFGHIJKLMNOPQRSTUVWXYZabcdefghijklmnopqrstuvwxyz0123456789-_".split(""),T_=` 274\r=`.split(""),BF=(()=>{const e=new Array(128);for(let t=0;t<e.length;t+=1)e[t]=-1;for(let t=0;t<T_.length;t+=1)e[T_[t].charCodeAt(0)]=-2;for(let t=0;t<jf.length;t+=1)e[jf[t].charCodeAt(0)]=t;return e})();function C_(e,t,r){if(e!==null)for(t.queue=t.queue<<8|e,t.queuedBits+=8;t.queuedBits>=6;){const n=t.queue>>t.queuedBits-6&63;r(jf[n]),t.queuedBits-=6}else if(t.queuedBits>0)for(t.queue=t.queue<<6-t.queuedBits,t.queuedBits=6;t.queuedBits>=6;){const n=t.queue>>t.queuedBits-6&63;r(jf[n]),t.queuedBits-=6}}function uC(e,t,r){const n=BF[e];if(n>-1)for(t.queue=t.queue<<6|n,t.queuedBits+=6;t.queuedBits>=8;)r(t.queue>>t.queuedBits-8&255),t.queuedBits-=8;else{if(n===-2)return;throw new Error(`Invalid Base64-URL character "${String.fromCharCode(e)}"`)}}function N_(e){const t=[],r=o=>{t.push(String.fromCodePoint(o))},n={utf8seq:0,codepoint:0},i={queue:0,queuedBits:0},a=o=>{zF(o,n,r)};for(let o=0;o<e.length;o+=1)uC(e.charCodeAt(o),i,a);return t.join("")}function UF(e,t){if(e<=127){t(e);return}else if(e<=2047){t(192|e>>6),t(128|e&63);return}else if(e<=65535){t(224|e>>12),t(128|e>>6&63),t(128|e&63);return}else if(e<=1114111){t(240|e>>18),t(128|e>>12&63),t(128|e>>6&63),t(128|e&63);return}throw new Error(`Unrecognized Unicode codepoint: ${e.toString(16)}`)}function FF(e,t){for(let r=0;r<e.length;r+=1){let n=e.charCodeAt(r);if(n>55295&&n<=56319){const i=(n-55296)*1024&65535;n=(e.charCodeAt(r+1)-56320&65535|i)+65536,r+=1}UF(n,t)}}function zF(e,t,r){if(t.utf8seq===0){if(e<=127){r(e);return}for(let n=1;n<6;n+=1)if(!(e>>7-n&1)){t.utf8seq=n;break}if(t.utf8seq===2)t.codepoint=e&31;else if(t.utf8seq===3)t.codepoint=e&15;else if(t.utf8seq===4)t.codepoint=e&7;else throw new Error("Invalid UTF-8 sequence");t.utf8seq-=1}else if(t.utf8seq>0){if(e<=127)throw new Error("Invalid UTF-8 sequence");t.codepoint=t.codepoint<<6|e&63,t.utf8seq-=1,t.utf8seq===0&&r(t.codepoint)}}function Qo(e){const t=[],r={queue:0,queuedBits:0},n=i=>{t.push(i)};for(let i=0;i<e.length;i+=1)uC(e.charCodeAt(i),r,n);return new Uint8Array(t)}function WF(e){const t=[];return FF(e,r=>t.push(r)),new Uint8Array(t)}function _a(e){const t=[],r={queue:0,queuedBits:0},n=i=>{t.push(i)};return e.forEach(i=>C_(i,r,n)),C_(null,r,n),t.join("")}function qF(e){return Math.round(Date.now()/1e3)+e}function HF(){return Symbol("auth-callback")}const xt=()=>typeof window<"u"&&typeof document<"u",la={tested:!1,writable:!1},cC=()=>{if(!xt())return!1;try{if(typeof globalThis.localStorage!="object")return!1}catch{return!1}if(la.tested)return la.writable;const e=`lswt-${Math.random()}${Math.random()}`;try{globalThis.localStorage.setItem(e,e),globalThis.localStorage.removeItem(e),la.tested=!0,la.writable=!0}catch{la.tested=!0,la.writable=!1}return la.writable};function VF(e){const t={},r=new URL(e);if(r.hash&&r.hash[0]==="#")try{new URLSearchParams(r.hash.substring(1)).forEac
274h((i,a)=>{t[a]=i})}catch{}return r.searchParams.forEach((n,i)=>{t[i]=n}),t}const dC=e=>e?(...t)=>e(...t):(...t)=>fetch(...t),KF=e=>typeof e=="object"&&e!==null&&"status"in e&&"ok"in e&&"json"in e&&typeof e.json=="function",Eo=async(e,t,r)=>{await e.setItem(t,JSON.stringify(r))},ua=async(e,t)=>{const r=await e.getItem(t);if(!r)return null;try{return JSON.parse(r)}catch{return r}},wt=async(e,t)=>{await e.removeItem(t)};class mp{constructor(){this.promise=new mp.promiseConstructor((t,r)=>{this.resolve=t,this.reject=r})}}mp.promiseConstructor=Promise;function hd(e){const t=e.split(".");if(t.length!==3)throw new ay("Invalid JWT structure");for(let n=0;n<t.length;n++)if(!$F.test(t[n]))throw new ay("JWT not in base64url format");return{header:JSON.parse(N_(t[0])),payload:JSON.parse(N_(t[1])),signature:Qo(t[2]),raw:{header:t[0],payload:t[1]}}}async function GF(e){return await new Promise(t=>{setTimeout(()=>t(null),e)})}function YF(e,t){return new Promise((n,i)=>{(async()=>{for(let a=0;a<1/0;a++)try{const o=await e(a);if(!t(a,null,o)){n(o);return}}catch(o){if(!t(a,o)){i(o);return}}})()})}function XF(e){return("0"+e.toString(16)).substr(-2)}function QF(){const t=new Uint32Array(56);if(typeof crypto>"u"){const r="ABCDEFGHIJKLMNOPQRSTUVWXYZabcdefghijklmnopqrstuvwxyz0123456789-._~",n=r.length;let i="";for(let a=0;a<56;a++)i+=r.charAt(Math.floor(Math.random()*n));return i}return crypto.getRandomValues(t),Array.from(t,XF).join("")}async function JF(e){const r=new TextEncoder().encode(e),n=await crypto.subtle.digest("SHA-256",r),i=new Uint8Array(n);return Array.from(i).map(a=>String.fromCharCode(a)).join("")}async function ZF(e){if(!(typeof crypto<"u"&&typeof crypto.subtle<"u"&&typeof TextEncoder<"u"))return console.warn("WebCrypto API is not supported. Code challenge method will default to use plain instead of sha256."),e;const r=await JF(e);return btoa(r).replace(/\+/g,"-").replace(/\//g,"_").replace(/=+$/,"")}async function ho(e,t,r=!1){const n=QF();let i=n;r&&(i+="/PASSWORD_RECOVERY"),await Eo(e,`${t}-code-verifier`,i);const a=await ZF(n);return[a,n===a?"plain":"s256"]}const ez=/^2[0-9]{3}-(0[1-9]|1[0-2])-(0[1-9]|1[0-9]|2[0-9]|3[0-1])$/i;function tz(e){const t=e.headers.get(ny);if(!t||!t.match(ez))return null;try{return new Date(`${t}T00:00:00.0Z`)}catch{return null}}function rz(e){if(!e)throw new Error("Missing exp claim");const t=Math.floor(Date.now()/1e3);if(e<=t)throw new Error("JWT has expired")}function nz(e){switch(e){case"RS256":return{name:"RSASSA-PKCS1-v1_5",hash:{name:"SHA-256"}};case"ES256":return{name:"ECDSA",namedCurve:"P-256",hash:{name:"SHA-256"}};default:throw new Error("Invalid alg claim")}}const iz=/^[0-9a-f]{8}-[0-9a-f]{4}-[0-9a-f]{4}-[0-9a-f]{4}-[0-9a-f]{12}$/;function po(e){if(!iz.test(e))throw new Error("@supabase/auth-js: Expected parameter to be UUID but is not")}function tv(){const e={};return new Proxy(e,{get:(t,r)=>{if(r==="__isUserNotAvailableProxy")return!0;if(typeof r=="symbol"){const n=r.toString();if(n==="Symbol(Symbol.toPrimitive)"||n==="Symbol(Symbol.toStringTag)"||n==="Symbol(util.inspect.custom)")return}throw new Error(`@supabase/auth-js: client was created with userStorage option and there was no user stored in the user storage. Accessing the "${r}" property of the session object is not supported. Please use getUser() instead.`)},set:(t,r)=>{throw new Error(`@supabase/auth-js: client was created with userStorage option and there was no user stored in the user storage. Setting the "${r}" property of the session object is not supported. Please use getUser() to fetch a user object you can manipulate.`)},deleteProperty:(t,r)=>{throw new Error(`@supabase/auth-js: client was created with userStorage option and there was no user stored in the user storage. Deleting the "${r}" property of the session object is not supported. Please use getUser() to fetch a user object you can manipulate.`)}})}function az(e,t){return new Proxy(e,{get:(r,n,i)=>{if(n==="__isInsecureUserWarningProxy")return!0;if(typeof n=="symbol"){const a=n.toString();if(a==="Symbol(Symbol.toPrimitive)"||a==="Symbol(Symbol.toStringTag)"||a==="Symbol(util.inspect.custom)"||a==="Symbol(nodejs.util.inspect.custom)")return Reflect.get(r,n,i)}return!t.value&&typeof n=="string"&&(console.warn("Using the user object as returned from supabase.auth.getSession() or from some supabase.auth.onAuthStateChange() events could be insecure! This value comes directly from the storage medium (usually cookies on the server) and may not be authentic. Use supabase.auth.getUser() instead which authenticates the data by contacting the Supabase Auth server."),t.value=!0),Reflect.get(r,n,i)}})}function $_(e){return JSON.parse(JSON.stringify(e))}const ha=e=>e.msg||e.message||e.error_description||e.error||JSON.stringify(e),oz=[502,503,504];async function R_(e){var t;if(!KF(e))throw new iy(ha(e),0);if(oz.includes(e.status))throw new iy(ha(e),e.status);let r;try{r=await e.json()}catch(a){throw new ya(ha(a),a)}let n;const i=tz(e);if(i&&i.getTime()>=lC["2024-01-01"].timestamp&&typeof r=="object"&&r&&typeof r.code=="string"?n=r.code:typeof r=="object"&&r&&typeof r.error_code=="string"&&(n=r.error_code),n){if(n==="weak_password")throw new j_(ha(r),e.status,((t=r.weak_password)===null||t===void 0?void 0:t.reasons)||[]);if(n==="session_not_found")throw new tr}else if(typeof r=="object"&&r&&typeof r.weak_password=="object"&&r.weak_password&&Array.isArray(r.weak_password.reasons)&&r.weak_password.reasons.length&&r.weak_password.reasons.reduce((a,o)=>
274a&&typeof o=="string",!0))throw new j_(ha(r),e.status,r.weak_password.reasons);throw new IF(ha(r),e.status||500,n)}const sz=(e,t,r,n)=>{const i={method:e,headers:(t==null?void 0:t.headers)||{}};return e==="GET"?i:(i.headers=Object.assign({"Content-Type":"application/json;charset=UTF-8"},t==null?void 0:t.headers),i.body=JSON.stringify(n),Object.assign(Object.assign({},i),r))};async function ne(e,t,r,n){var i;const a=Object.assign({},n==null?void 0:n.headers);a[ny]||(a[ny]=lC["2024-01-01"].name),n!=null&&n.jwt&&(a.Authorization=`Bearer ${n.jwt}`);const o=(i=n==null?void 0:n.query)!==null&&i!==void 0?i:{};n!=null&&n.redirectTo&&(o.redirect_to=n.redirectTo);const s=Object.keys(o).length?"?"+new URLSearchParams(o).toString():"",l=await lz(e,t,r+s,{headers:a,noResolveJson:n==null?void 0:n.noResolveJson},{},n==null?void 0:n.body);return n!=null&&n.xform?n==null?void 0:n.xform(l):{data:Object.assign({},l),error:null}}async function lz(e,t,r,n,i,a){const o=sz(t,n,i,a);let s;try{s=await e(r,Object.assign({},o))}catch(l){throw console.error(l),new iy(ha(l),0)}if(s.ok||await R_(s),n!=null&&n.noResolveJson)return s;try{return await s.json()}catch(l){await R_(l)}}function Br(e){var t;let r=null;dz(e)&&(r=Object.assign({},e),e.expires_at||(r.expires_at=qF(e.expires_in)));const n=(t=e.user)!==null&&t!==void 0?t:e;return{data:{session:r,user:n},error:null}}function I_(e){const t=Br(e);return!t.error&&e.weak_password&&typeof e.weak_password=="object"&&Array.isArray(e.weak_password.reasons)&&e.weak_password.reasons.length&&e.weak_password.message&&typeof e.weak_password.message=="string"&&e.weak_password.reasons.reduce((r,n)=>r&&typeof n=="string",!0)&&(t.data.weak_password=e.weak_password),t}function Oi(e){var t;return{data:{user:(t=e.user)!==null&&t!==void 0?t:e},error:null}}function uz(e){return{data:e,error:null}}function cz(e){const{action_link:t,email_otp:r,hashed_token:n,redirect_to:i,verification_type:a}=e,o=Qs(e,["action_link","email_otp","hashed_token","redirect_to","verification_type"]),s={action_link:t,email_otp:r,hashed_token:n,redirect_to:i,verification_type:a},l=Object.assign({},o);return{data:{properties:s,user:l},error:null}}function M_(e){return e}function dz(e){return e.access_token&&e.refresh_token&&e.expires_in}const rv=["global","local","others"];class fz{constructor({url:t="",headers:r={},fetch:n}){this.url=t,this.headers=r,this.fetch=dC(n),this.mfa={listFactors:this._listFactors.bind(this),deleteFactor:this._deleteFactor.bind(this)},this.oauth={listClients:this._listOAuthClients.bind(this),createClient:this._createOAuthClient.bind(this),getClient:this._getOAuthClient.bind(this),updateClient:this._updateOAuthClient.bind(this),deleteClient:this._deleteOAuthClient.bind(this),regenerateClientSecret:this._regenerateOAuthClientSecret.bind(this)}}async signOut(t,r=rv[0]){if(rv.indexOf(r)<0)throw new Error(`@supabase/auth-js: Parameter scope must be one of ${rv.join(", ")}`);try{return await ne(this.fetch,"POST",`${this.url}/logout?scope=${r}`,{headers:this.headers,jwt:t,noResolveJson:!0}),{data:null,error:null}}catch(n){if(J(n))return{data:null,error:n};throw n}}async inviteUserByEmail(t,r={}){try{return await ne(this.fetch,"POST",`${this.url}/invite`,{body:{email:t,data:r.data},headers:this.headers,redirectTo:r.redirectTo,xform:Oi})}catch(n){if(J(n))return{data:{user:null},error:n};throw n}}async generateLink(t){try{const{options:r}=t,n=Qs(t,["options"]),i=Object.assign(Object.assign({},n),r);return"newEmail"in n&&(i.new_email=n==null?void 0:n.newEmail,delete i.newEmail),await ne(this.fetch,"POST",`${this.url}/admin/generate_link`,{body:i,headers:this.headers,xform:cz,redirectTo:r==null?void 0:r.redirectTo})}catch(r){if(J(r))return{data:{properties:null,user:null},error:r};throw r}}async createUser(t){try{return await ne(this.fetch,"POST",`${this.url}/admin/users`,{body:t,headers:this.headers,xform:Oi})}catch(r){if(J(r))return{data:{user:null},error:r};throw r}}async listUsers(t){var r,n,i,a,o,s,l;try{const u={nextPage:null,lastPage:0,total:0},d=await ne(this.fetch,"GET",`${this.url}/admin/users`,{headers:this.headers,noResolveJson:!0,query:{page:(n=(r=t==null?void 0:t.page)===null||r===void 0?void 0:r.toString())!==null&&n!==void 0?n:"",per_page:(a=(i=t==null?void 0:t.perPage)===null||i===void 0?void 0:i.toString())!==null&&a!==void 0?a:""},xform:M_});if(d.error)throw d.error;const c=await d.json(),f=(o=d.headers.get("x-total-count"))!==null&&o!==void 0?o:0,h=(l=(s=d.headers.get("link"))===null||s===void 0?void 0:s.split(","))!==null&&l!==void 0?l:[];return h.length>
2740&&(h.forEach(v=>{const m=parseInt(v.split(";")[0].split("=")[1].substring(0,1)),g=JSON.parse(v.split(";")[1].split("=")[1]);u[`${g}Page`]=m}),u.total=parseInt(f)),{data:Object.assign(Object.assign({},c),u),error:null}}catch(u){if(J(u))return{data:{users:[]},error:u};throw u}}async getUserById(t){po(t);try{return await ne(this.fetch,"GET",`${this.url}/admin/users/${t}`,{headers:this.headers,xform:Oi})}catch(r){if(J(r))return{data:{user:null},error:r};throw r}}async updateUserById(t,r){po(t);try{return await ne(this.fetch,"PUT",`${this.url}/admin/users/${t}`,{body:r,headers:this.headers,xform:Oi})}catch(n){if(J(n))return{data:{user:null},error:n};throw n}}async deleteUser(t,r=!1){po(t);try{return await ne(this.fetch,"DELETE",`${this.url}/admin/users/${t}`,{headers:this.headers,body:{should_soft_delete:r},xform:Oi})}catch(n){if(J(n))return{data:{user:null},error:n};throw n}}async _listFactors(t){po(t.userId);try{const{data:r,error:n}=await ne(this.fetch,"GET",`${this.url}/admin/users/${t.userId}/factors`,{headers:this.headers,xform:i=>({data:{factors:i},error:null})});return{data:r,error:n}}catch(r){if(J(r))return{data:null,error:r};throw r}}async _deleteFactor(t){po(t.userId),po(t.id);try{return{data:await ne(this.fetch,"DELETE",`${this.url}/admin/users/${t.userId}/factors/${t.id}`,{headers:this.headers}),error:null}}catch(r){if(J(r))return{data:null,error:r};throw r}}async _listOAuthClients(t){var r,n,i,a,o,s,l;try{const u={nextPage:null,lastPage:0,total:0},d=await ne(this.fetch,"GET",`${this.url}/admin/oauth/clients`,{headers:this.headers,noResolveJson:!0,query:{page:(n=(r=t==null?void 0:t.page)===null||r===void 0?void 0:r.toString())!==null&&n!==void 0?n:"",per_page:(a=(i=t==null?void 0:t.perPage)===null||i===void 0?void 0:i.toString())!==null&&a!==void 0?a:""},xform:M_});if(d.error)throw d.error;const c=await d.json(),f=(o=d.headers.get("x-total-count"))!==null&&o!==void 0?o:0,h=(l=(s=d.headers.get("link"))===null||s===void 0?void 0:s.split(","))!==null&&l!==void 0?l:[];return h.length>0&&(h.forEach(v=>{const m=parseInt(v.split(";")[0].split("=")[1].substring(0,1)),g=JSON.parse(v.split(";")[1].split("=")[1]);u[`${g}Page`]=m}),u.total=parseInt(f)),{data:Object.assign(Object.assign({},c),u),error:null}}catch(u){if(J(u))return{data:{clients:[]},error:u};throw u}}async _createOAuthClient(t){try{return await ne(this.fetch,"POST",`${this.url}/admin/oauth/clients`,{body:t,headers:this.headers,xform:r=>({data:r,error:null})})}catch(r){if(J(r))return{data:null,error:r};throw r}}async _getOAuthClient(t){try{return await ne(this.fetch,"GET",`${this.url}/admin/oauth/clients/${t}`,{headers:this.headers,xform:r=>({data:r,error:null})})}catch(r){if(J(r))return{data:null,error:r};throw r}}async _updateOAuthClient(t,r){try{return await ne(this.fetch,"PUT",`${this.url}/admin/oauth/clients/${t}`,{body:r,headers:this.headers,xform:n=>({data:n,error:null})})}catch(n){if(J(n))return{data:null,error:n};throw n}}async _deleteOAuthClient(t){try{return await ne(this.fetch,"DELETE",`${this.url}/admin/oauth/clients/${t}`,{headers:this.headers,noResolveJson:!0}),{data:null,error:null}}catch(r){if(J(r))return{data:null,error:r};throw r}}async _regenerateOAuthClientSecret(t){try{return await ne(this.fetch,"POST",`${this.url}/admin/oauth/clients/${t}/regenerate_secret`,{headers:this.headers,xform:r=>({data:r,error:null})})}catch(r){if(J(r))return{data:null,error:r};throw r}}}function D_(e={}){return{getItem:t=>e[t]||null,setItem:(t,r)=>{e[t]=r},removeItem:t=>{delete e[t]}}}const mo={debug:!!(globalThis&&cC()&&globalThis.localStorage&&globalThis.localStorage.getItem("supabase.gotrue-js.locks.debug")==="true")};class fC extends Error{constructor(t){super(t),this.isAcquireTimeout=!0}}class L_ extends fC{}async function hz(e,t,r){mo.debug&&console.log("@supabase/gotrue-js: navigatorLock: acquire lock",e,t);const n=new globalThis.AbortController;t>0&&setTimeout(()=>{n.abort(),mo.debug&&console.log("@supabase/gotrue-js: navigatorLock acquire timed out",e)},t),await Promise.resolve();try{return await globalThis.navigator.locks.request(e,t===0?{mode:"exclusive",ifAvailable:!0}:{mode:"exclusive",signal:n.signal}
274,async i=>{if(i){mo.debug&&console.log("@supabase/gotrue-js: navigatorLock: acquired",e,i.name);try{return await r()}finally{mo.debug&&console.log("@supabase/gotrue-js: navigatorLock: released",e,i.name)}}else{if(t===0)throw mo.debug&&console.log("@supabase/gotrue-js: navigatorLock: not immediately available",e),new L_(`Acquiring an exclusive Navigator LockManager lock "${e}" immediately failed`);if(mo.debug)try{const a=await globalThis.navigator.locks.query();console.log("@supabase/gotrue-js: Navigator LockManager state",JSON.stringify(a,null," "))}catch(a){console.warn("@supabase/gotrue-js: Error when querying Navigator LockManager state",a)}return console.warn("@supabase/gotrue-js: Navigator LockManager returned a null lock when using #request without ifAvailable set to true, it appears this browser is not following the LockManager spec https://developer.mozilla.org/en-US/docs/Web/API/LockManager/request"),await r()}})}catch(i){throw(i==null?void 0:i.name)==="AbortError"?new L_(`Acquiring an exclusive Navigator LockManager lock "${e}" timed out waiting ${t}ms`):i}}function pz(){if(typeof globalThis!="object")try{Object.defineProperty(Object.prototype,"__magic__",{get:function(){return this},configurable:!0}),__magic__.globalThis=__magic__,delete Object.prototype.__magic__}catch{typeof self<"u"&&(self.globalThis=self)}}function hC(e){if(!/^0x[a-fA-F0-9]{40}$/.test(e))throw new Error(`@supabase/auth-js: Address "${e}" is invalid.`);return e.toLowerCase()}function mz(e){return parseInt(e,16)}function vz(e){const t=new TextEncoder().encode(e);return"0x"+Array.from(t,n=>n.toString(16).padStart(2,"0")).join("")}function gz(e){var t;const{chainId:r,domain:n,expirationTime:i,issuedAt:a=new Date,nonce:o,notBefore:s,requestId:l,resources:u,scheme:d,uri:c,version:f}=e;{if(!Number.isInteger(r))throw new Error(`@supabase/auth-js: Invalid SIWE message field "chainId". Chain ID must be a EIP-155 chain ID. Provided value: ${r}`);if(!n)throw new Error('@supabase/auth-js: Invalid SIWE message field "domain". Domain must be provided.');if(o&&o.length<8)throw new Error(`@supabase/auth-js: Invalid SIWE message field "nonce". Nonce must be at least 8 characters. Provided value: ${o}`);if(!c)throw new Error('@supabase/auth-js: Invalid SIWE message field "uri". URI must be provided.');if(f!=="1")throw new Error(`@supabase/auth-js: Invalid SIWE message field "version". Version must be '1'. Provided value: ${f}`);if(!((t=e.statement)===null||t===void 0)&&t.includes(` 275`))throw new Error(`@supabase/auth-js: Invalid SIWE message field "statement". Statement must not include '\\n'. Provided value: ${e.statement}`)}const h=hC(e.address),v=d?`${d}://${n}`:n,m=e.statement?`${e.statement} 276`:"",g=`${v} wants you to sign in with your Ethereum account: 277${h} 278 279${m}`;let y=`URI: ${c} 280Version: ${f} 281Chain ID: ${r}${o?` 282Nonce: ${o}`:""} 283Issued At: ${a.toISOString()}`;if(i&&(y+=` 284Expiration Time: ${i.toISOString()}`),s&&(y+=` 285Not Before: ${s.toISOString()}`),l&&(y+=` 286Request ID: ${l}`),u){let b=` 287Resources:`;for(const w of u){if(!w||typeof w!="string")throw new Error(`@supabase/auth-js: Invalid SIWE message field "resources". Every resource must be a valid string. Provided value: ${w}`);b+=` 288- ${w}`}y+=b}return`${g} 289${y}`}class rt extends Error{constructor({message:t,code:r,cause:n,name:i}){var a;super(t,{cause:n}),this.__isWebAuthnError=!0,this.name=(a=i??(n instanceof Error?n.name:void 0))!==null&&a!==void 0?a:"Unknown Error",this.code=r}}class Tf extends rt{constructor(t,r){super({code:"ERROR_PASSTHROUGH_SEE_CAUSE_PROPERTY",cause:r,message:t}),this.name="WebAuthnUnknownError",this.originalError=r}}function yz({error:e,options:t}){var r,n,i;const{publicKey:a}=t;if(!a)throw Error("options was missing required publicKey property");if(e.name==="AbortError"){if(t.signal instanceof AbortSignal)return new rt({message:"Registration ceremony was sent an abort signal",code:"ERROR_CEREMONY_ABORTED",cause:e})}else if(e.name==="ConstraintError"){if(((r=a.authenticatorSelection)===null||r===void 0?void 0:r.requireResidentKey)===!0)return new rt({message:"Discoverable credentials were required but no available authenticator supported it",code:"ERROR_AUTHENTICATOR_MISSING_DISCOVERABLE_CREDENTIAL_SUPPORT",cause:e});if(t.mediation==="conditional"&&((n=a.authenticatorSelection)===null||n===void 0?void 0:n.userVerification)==="required")return new rt({message:"User verification was required during automatic registration but it could not be performed",code:"ERROR_AUTO_REGISTER_USER_VERIFICATION_FAILURE",cause:e});if(((i=a.authenticatorSelection)===null||i===void 0?void 0:i.userVerification)==="required")return new rt({message:"User verification was required but no available authenticator supported it",code:"ERROR_AUTHENTICATOR_MISSING_USER_VERIFICATION_SUPPORT",cause:e})}else{if(e.name==="InvalidStateError")return new rt({message:"The authenticator was previously registered",code:"ERROR_AUTHENTICATOR_PREVIOUSLY_REGISTERED",cause:e});if(e.name==="NotAllowedError")return new rt({message:e.message,code:"ERROR_PASSTHROUGH_SEE_CAUSE_PROPERTY",cause:e});if(e.name==="NotSupportedError")return a.pubKeyCredParams.filter(s=>s.type==="public-key").length===0?new rt({message:'No entry in pubKeyCredParams was of type "public-key"',code:"ERROR_MALFORMED_PUBKEYCREDPARAMS",cause:e}):new rt({message:"No available authenticator supported any of the specified pubKeyCredParams algorithms",code:"ERROR_AUTHENTICATOR_NO_SUPPORTED_PUBKEYCREDPARAMS_ALG",cause:e});if(e.name==="SecurityError"){const o=window.location.hostname;if(pC(o)){if(a.rp.id!==o)return new rt({message:`The RP ID "${a.rp.id}
289" is invalid for this domain`,code:"ERROR_INVALID_RP_ID",cause:e})}else return new rt({message:`${window.location.hostname} is an invalid domain`,code:"ERROR_INVALID_DOMAIN",cause:e})}else if(e.name==="TypeError"){if(a.user.id.byteLength<1||a.user.id.byteLength>64)return new rt({message:"User ID was not between 1 and 64 characters",code:"ERROR_INVALID_USER_ID_LENGTH",cause:e})}else if(e.name==="UnknownError")return new rt({message:"The authenticator was unable to process the specified options, or could not create a new credential",code:"ERROR_AUTHENTICATOR_GENERAL_ERROR",cause:e})}return new rt({message:"a Non-Webauthn related error has occurred",code:"ERROR_PASSTHROUGH_SEE_CAUSE_PROPERTY",cause:e})}function bz({error:e,options:t}){const{publicKey:r}=t;if(!r)throw Error("options was missing required publicKey property");if(e.name==="AbortError"){if(t.signal instanceof AbortSignal)return new rt({message:"Authentication ceremony was sent an abort signal",code:"ERROR_CEREMONY_ABORTED",cause:e})}else{if(e.name==="NotAllowedError")return new rt({message:e.message,code:"ERROR_PASSTHROUGH_SEE_CAUSE_PROPERTY",cause:e});if(e.name==="SecurityError"){const n=window.location.hostname;if(pC(n)){if(r.rpId!==n)return new rt({message:`The RP ID "${r.rpId}" is invalid for this domain`,code:"ERROR_INVALID_RP_ID",cause:e})}else return new rt({message:`${window.location.hostname} is an invalid domain`,code:"ERROR_INVALID_DOMAIN",cause:e})}else if(e.name==="UnknownError")return new rt({message:"The authenticator was unable to process the specified options, or could not create a new assertion signature",code:"ERROR_AUTHENTICATOR_GENERAL_ERROR",cause:e})}return new rt({message:"a Non-Webauthn related error has occurred",code:"ERROR_PASSTHROUGH_SEE_CAUSE_PROPERTY",cause:e})}class wz{createNewAbortSignal(){if(this.controller){const r=new Error("Cancelling existing WebAuthn API call for new one");r.name="AbortError",this.controller.abort(r)}const t=new AbortController;return this.controller=t,t.signal}cancelCeremony(){if(this.controller){const t=new Error("Manually cancelling existing WebAuthn API call");t.name="AbortError",this.controller.abort(t),this.controller=void 0}}}const xz=new wz;function _z(e){if(!e)throw new Error("Credential creation options are required");if(typeof PublicKeyCredential<"u"&&"parseCreationOptionsFromJSON"in PublicKeyCredential&&typeof PublicKeyCredential.parseCreationOptionsFromJSON=="function")return PublicKeyCredential.parseCreationOptionsFromJSON(e);const{challenge:t,user:r,excludeCredentials:n}=e,i=Qs(e,["challenge","user","excludeCredentials"]),a=Qo(t).buffer,o=Object.assign(Object.assign({},r),{id:Qo(r.id).buffer}),s=Object.assign(Object.assign({},i),{challenge:a,user:o});if(n&&n.length>0){s.excludeCredentials=new Array(n.length);for(let l=0;l<n.length;l++){const u=n[l];s.excludeCredentials[l]=Object.assign(Object.assign({},u),{id:Qo(u.id).buffer,type:u.type||"public-key",transports:u.transports})}}return s}function Sz(e){if(!e)throw new Error("Credential request options are required");if(typeof PublicKeyCredential<"u"&&"parseRequestOptionsFromJSON"in PublicKeyCredential&&typeof PublicKeyCredential.parseRequestOptionsFromJSON=="function")return PublicKeyCredential.parseRequestOptionsFromJSON(e);const{challenge:t,allowCredentials:r}=e,n=Qs(e,["challenge","allowCredentials"]),i=Qo(t).buffer,a=Object.assign(Object.assign({},n),{challenge:i});if(r&&r.length>0){a.allowCredentials=new Array(r.length);for(let o=0;o<r.length;o++){const s=r[o];a.allowCredentials[o]=Object.assign(Object.assign({},s),{id:Qo(s.id).buffer,type:s.type||"public-key",transports:s.transports})}}return a}function Oz(e){var t;if("toJSON"in e&&typeof e.toJSON=="function")return e.toJSON();const r=e;return{id:e.id,rawId:e.id,response:{attestationObject:_a(new Uint8Array(e.response.attestationObject)),clientDataJSON:_a(new Uint8Array(e.response.clientDataJSON))},type:"public-key",clientExtensionResults:e.getClientExtensionResults(),authenticatorAttachment:(t=r.authenticatorAttachment)!==null&&t!==void 0?t:void 0}}function Ez(e){var t;if("toJSON"in e&&typeof e.toJSON=="function")return e.toJSON();const r=e,n=e.getClientExtensionResults(),i=e.response;return{id:e.id,rawId:e.id,response:{authenticatorData:_a(new Uint8Array(i.authenticatorData)),clientDataJSON:_a(new Uint8Array(i.clientDataJSON)),signature:_a(new Uint8Array(i.signature)),userHandle:i.userHandle?_a(new Uint8Array(i.userHandle)):void 0},type:"public-key",clientExtensionResults:n,authenticatorAttachment:(t=r.authenticatorAttachment)!==null&&t!==void 0?t:void 0}}function pC(e){return e==="localhost"||/^([a-z0-9]+(-[a-z0-9]+)*\.)+[a-z]{2,}$/i.test(e)}function B_(){var e,t;return!!(xt()&&"PublicKeyCredential"in window&&window.PublicKeyCredential&&"credentials"in navigator&&typeof((e=navigator==null?void 0:navigator.credentials)===null||e===void 0?void 0:e.create)=="function"&&typeof((t=navigator==null?void 0:navigator.credentials)===null||t===void 0?void 0:t.get)=="function")}async function kz(e){try{const t=await navigator.credentials.create(e);return t?t instanceof PublicKeyCredential?{data:t,error:null}:{data:null,error:new Tf("Browser returned unexpected credential type",t)}:{data:null,error:new Tf("Empty credential response",t)}}
289catch(t){return{data:null,error:yz({error:t,options:e})}}}async function Pz(e){try{const t=await navigator.credentials.get(e);return t?t instanceof PublicKeyCredential?{data:t,error:null}:{data:null,error:new Tf("Browser returned unexpected credential type",t)}:{data:null,error:new Tf("Empty credential response",t)}}catch(t){return{data:null,error:bz({error:t,options:e})}}}const Az={hints:["security-key"],authenticatorSelection:{authenticatorAttachment:"cross-platform",requireResidentKey:!1,userVerification:"preferred",residentKey:"discouraged"},attestation:"direct"},jz={userVerification:"preferred",hints:["security-key"],attestation:"direct"};function Cf(...e){const t=i=>i!==null&&typeof i=="object"&&!Array.isArray(i),r=i=>i instanceof ArrayBuffer||ArrayBuffer.isView(i),n={};for(const i of e)if(i)for(const a in i){const o=i[a];if(o!==void 0)if(Array.isArray(o))n[a]=o;else if(r(o))n[a]=o;else if(t(o)){const s=n[a];t(s)?n[a]=Cf(s,o):n[a]=Cf(o)}else n[a]=o}return n}function Tz(e,t){return Cf(Az,e,t||{})}function Cz(e,t){return Cf(jz,e,t||{})}class Nz{constructor(t){this.client=t,this.enroll=this._enroll.bind(this),this.challenge=this._challenge.bind(this),this.verify=this._verify.bind(this),this.authenticate=this._authenticate.bind(this),this.register=this._register.bind(this)}async _enroll(t){return this.client.mfa.enroll(Object.assign(Object.assign({},t),{factorType:"webauthn"}))}async _challenge({factorId:t,webauthn:r,friendlyName:n,signal:i},a){var o;try{const{data:s,error:l}=await this.client.mfa.challenge({factorId:t,webauthn:r});if(!s)return{data:null,error:l};const u=i??xz.createNewAbortSignal();if(s.webauthn.type==="create"){const{user:d}=s.webauthn.credential_options.publicKey;if(!d.name){const c=n;if(c)d.name=`${d.id}:${c}`;else{const h=(await this.client.getUser()).data.user,v=((o=h==null?void 0:h.user_metadata)===null||o===void 0?void 0:o.name)||(h==null?void 0:h.email)||(h==null?void 0:h.id)||"User";d.name=`${d.id}:${v}`}}d.displayName||(d.displayName=d.name)}switch(s.webauthn.type){case"create":{const d=Tz(s.webauthn.credential_options.publicKey,a==null?void 0:a.create),{data:c,error:f}=await kz({publicKey:d,signal:u});return c?{data:{factorId:t,challengeId:s.id,webauthn:{type:s.webauthn.type,credential_response:c}},error:null}:{data:null,error:f}}case"request":{const d=Cz(s.webauthn.credential_options.publicKey,a==null?void 0:a.request),{data:c,error:f}=await Pz(Object.assign(Object.assign({},s.webauthn.credential_options),{publicKey:d,signal:u}));return c?{data:{factorId:t,challengeId:s.id,webauthn:{type:s.webauthn.type,credential_response:c}},error:null}:{data:null,error:f}}}}catch(s){return J(s)?{data:null,error:s}:{data:null,error:new ya("Unexpected error in challenge",s)}}}async _verify({challengeId:t,factorId:r,webauthn:n}){return this.client.mfa.verify({factorId:r,challengeId:t,webauthn:n})}async _authenticate({factorId:t,webauthn:{rpId:r=typeof window<"u"?window.location.hostname:void 0,rpOrigins:n=typeof window<"u"?[window.location.origin]:void 0,signal:i}={}},a){if(!r)return{data:null,error:new ju("rpId is required for WebAuthn authentication")};try{if(!B_())return{data:null,error:new ya("Browser does not support WebAuthn",null)};const{data:o,error:s}=await this.challenge({factorId:t,webauthn:{rpId:r,rpOrigins:n},signal:i},{request:a});if(!o)return{data:null,error:s};const{webauthn:l}=o;return this._verify({factorId:t,challengeId:o.challengeId,webauthn:{type:l.type,rpId:r,rpOrigins:n,credential_response:l.credential_response}})}catch(o){return J(o)?{data:null,error:o}:{data:null,error:new ya("Unexpected error in authenticate",o)}}}async _register({friendlyName:t,webauthn:{rpId:r=typeof window<"u"?window.location.hostname:void 0,rpOrigins:n=typeof window<"u"?[window.location.origin]:void 0,signal:i}={}},a){if(!r)return{data:null,error:new ju("rpId is required for WebAuthn registration")};try{if(!B_())return{data:null,error:new ya("Browser does not support WebAuthn",null)};const{data:o,error:s}=await this._enroll({friendlyName:t});if(!o)return await this.client.mfa.listFactors().then(d=>{var c;return(c=d.data)===null||c===void 0?void 0:c.all.find(f=>f.factor_type==="webauthn"&&f.friendly_name===t&&f.status!=="unverified")}).then(d=>d?this.client.mfa.unenroll({factorId:d==null?void 0:d.id}):void 0),{data:null,error:s};const{data:l,error:u}=await this._challenge({factorId:o.id,friendlyName:o.friendly_name,webauthn:{rpId:r,rpOrigins:n},signal:i},{create:a});return l?this._verify({factorId:o.id,challengeId:l.challengeId,webauthn:{rpId:r,rpOrigins:n,type:l.webauthn.type,credential_response:l.webauthn.credential_response}}):{data:null,error:u}}catch(o){return J(o)?{data:null,error:o}:{data:null,error:new ya("Unexpected error in register",o)}}}}pz();const $z={url:TF,storageKey:CF,autoRefreshToken:!0,persistSession:!0,detectSessionInUrl:!0,headers:NF,flowType:"implicit",debug:!1,hasCustomAuthorizationHeader:!1,throwOnError:!1,lockAcquireTimeout:1e4,skipAutoInitialize:!1};async function U_(e,t,r){return await r()}const vo={};class Tu{get jwks(){var t,r;return(r=(t=vo[this.storageKey])===null||t===void 0?void 0:t.jwks)!==null&&r!==void 0?r:{keys:[]}}set jwks(t){vo[this.storageKey]=Object.assign(Object.assign({},vo[this.storageKey]),{jwks:t})}get jwks_cached_at(){var t,r;return(r=(t=vo[this.storageKey])===null||t===void 0?void 0:t.cachedAt)!==null&&r!==void 0?r:Number.MIN_SAFE_INTEGER}set jwks_cached_at(t){vo[this.storageKey]=Object.assign(Object.assign({},vo[this.storageKey]),{cachedAt:t})}constructor(t){var r,n,i;this.userStorage=null,this.memoryStorage=null,this.stateChangeEmitters=new Map,this.autoRefreshTicker=null,this.autoRefreshTickTimeout=null,this.visibilityChangedCallback=null,this.refreshingDeferred=null,this.initializePromise=null,this.detectSessionInUrl=!0,this.hasCustomAuthorizationHeader=!1,this.suppressGetSessionWarning=!1,this.lockAcquired=!1,this.pendingInLock=[],this.broadcastChannel=null,this.logger=console.log;const a=Object.assign(Object.assign({},$z),t);if(this.storageKey=a.storageKey,this.instanceID=(r=Tu.nextInstanceID[this.storageKey])!==null&&r!==void 0?r:0,Tu.nextInstanceID[this.storageKey]=this.instanceID+1,this.logDebugMessages=!!a.debug,typeof a.debug=="function"&&(this.logger=a.debug),this.instanceID>0&&xt()){const o=`${this._logPrefix()} Multiple GoTrueClient instances detected in the same browser context. It is not an error, but this should be avoided as it may produce undefined behavior when used concurrently under the same storage key.`;console.warn(o),this.logDebugMessages&&console.trace(o)}if(this.persistSession=a.persistSession,this.autoRefreshToken=a.autoRefreshToken,this.admin=new fz({url:a.url,headers:a.headers,fetch:a.fetch}),this.url=a.url,this.headers=a.headers,this.fetch=dC(a.fetch),this.lock=a.lock||U_,this.detectSessionInUrl=a.detectSessionInUrl,this.flowType=a.flowType,this.hasCustomAuthorizationHeader=a.hasCustomAuthorizationHeader,this.throwOnError=a.throwOnError,this.lockAcquireTimeout=a.lockAcquireTimeout,a.lock?this.lock=a.lock:this.persistSession&&xt()&&(!((n=globalThis==null?void 0:globalThis.navigator)===null||n===void 0)&&n.locks)?this.lock=hz:this.lock=U_,this.jwks||(this.jwks={keys:[]},this.jwks_cached_at=Number.MIN_SAFE_INTEGER),this.mfa={verify:this._verify.bind(this),enroll:this._enroll.bind(this),unenroll:this._unenroll.bind(this),challenge:this._challenge.bind(this),listFactors:this._listFactors.bind(this),challengeAndVerify:this._challengeAndVerify.bind(this),getAuthenticatorAssuranceLevel:this._getAuthenticatorAssuranceLevel.bind(this),webauthn:new Nz(this)}
289,this.oauth={getAuthorizationDetails:this._getAuthorizationDetails.bind(this),approveAuthorization:this._approveAuthorization.bind(this),denyAuthorization:this._denyAuthorization.bind(this),listGrants:this._listOAuthGrants.bind(this),revokeGrant:this._revokeOAuthGrant.bind(this)},this.persistSession?(a.storage?this.storage=a.storage:cC()?this.storage=globalThis.localStorage:(this.memoryStorage={},this.storage=D_(this.memoryStorage)),a.userStorage&&(this.userStorage=a.userStorage)):(this.memoryStorage={},this.storage=D_(this.memoryStorage)),xt()&&globalThis.BroadcastChannel&&this.persistSession&&this.storageKey){try{this.broadcastChannel=new globalThis.BroadcastChannel(this.storageKey)}catch(o){console.error("Failed to create a new BroadcastChannel, multi-tab state changes will not be available",o)}(i=this.broadcastChannel)===null||i===void 0||i.addEventListener("message",async o=>{this._debug("received broadcast notification from other tab or client",o);try{await this._notifyAllSubscribers(o.data.event,o.data.session,!1)}catch(s){this._debug("#broadcastChannel","error",s)}})}a.skipAutoInitialize||this.initialize().catch(o=>{this._debug("#initialize()","error",o)})}isThrowOnErrorEnabled(){return this.throwOnError}_returnResult(t){if(this.throwOnError&&t&&t.error)throw t.error;return t}_logPrefix(){return`GoTrueClient@${this.storageKey}:${this.instanceID} (${sC}) ${new Date().toISOString()}`}_debug(...t){return this.logDebugMessages&&this.logger(this._logPrefix(),...t),this}async initialize(){return this.initializePromise?await this.initializePromise:(this.initializePromise=(async()=>await this._acquireLock(this.lockAcquireTimeout,async()=>await this._initialize()))(),await this.initializePromise)}async _initialize(){var t;try{let r={},n="none";if(xt()&&(r=VF(window.location.href),this._isImplicitGrantCallback(r)?n="implicit":await this._isPKCECallback(r)&&(n="pkce")),xt()&&this.detectSessionInUrl&&n!=="none"){const{data:i,error:a}=await this._getSessionFromURL(r,n);if(a){if(this._debug("#_initialize()","error detecting session from URL",a),DF(a)){const l=(t=a.details)===null||t===void 0?void 0:t.code;if(l==="identity_already_exists"||l==="identity_not_found"||l==="single_identity_not_deletable")return{error:a}}return{error:a}}const{session:o,redirectType:s}=i;return this._debug("#_initialize()","detected session in URL",o,"redirect type",s),await this._saveSession(o),setTimeout(async()=>{s==="recovery"?await this._notifyAllSubscribers("PASSWORD_RECOVERY",o):await this._notifyAllSubscribers("SIGNED_IN",o)},0),{error:null}}return await this._recoverAndRefresh(),{error:null}}catch(r){return J(r)?this._returnResult({error:r}):this._returnResult({error:new ya("Unexpected error during initialization",r)})}finally{await this._handleVisibilityChange(),this._debug("#_initialize()","end")}}async signInAnonymously(t){var r,n,i;try{const a=await ne(this.fetch,"POST",`${this.url}/signup`,{headers:this.headers,body:{data:(n=(r=t==null?void 0:t.options)===null||r===void 0?void 0:r.data)!==null&&n!==void 0?n:{},gotrue_meta_security:{captcha_token:(i=t==null?void 0:t.options)===null||i===void 0?void 0:i.captchaToken}},xform:Br}),{data:o,error:s}=a;if(s||!o)return this._returnResult({data:{user:null,session:null},error:s});const l=o.session,u=o.user;return o.session&&(await this._saveSession(o.session),await this._notifyAllSubscribers("SIGNED_IN",l)),this._returnResult({data:{user:u,session:l},error:null})}catch(a){if(J(a))return this._returnResult({data:{user:null,session:null},error:a});throw a}}async signUp(t){var r,n,i;try{let a;if("email"in t){const{email:d,password:c,options:f}=t;let h=null,v=null;this.flowType==="pkce"&&([h,v]=await ho(this.storage,this.storageKey)),a=await ne(this.fetch,"POST",`${this.url}/signup`,{headers:this.headers,redirectTo:f==null?void 0:f.emailRedirectTo,body:{email:d,password:c,data:(r=f==null?void 0:f.data)!==null&&r!==void 0?r:{},gotrue_meta_security:{captcha_token:f==null?void 0:f.captchaToken},code_challenge:h,code_challenge_method:v},xform:Br})}else if("phone"in t){const{phone:d,password:c,options:f}=t;a=await ne(this.fetch,"POST",`${this.url}/signup`,{headers:this.headers,body:{phone:d,password:c,data:(n=f==null?void 0:f.data)!==null&&n!==void 0?n:{},channel:(i=f==null?void 0:f.channel)!==null&&i!==void 0?i:"sms",gotrue_meta_security:{captcha_token:f==null?void 0:f.captchaToken}},xform:Br})}else throw new dd("You must provide either an email or phone number and a password");const{data:o,error:s}=a;if(s||!o)return await wt(this.storage,`${this.storageKey}-code-verifier`),this._returnResult({data:{user:null,session:null},error:s});const l=o.session,u=o.user;return o.session&&(await this._saveSession(o.session),await this._notifyAllSubscribers("SIGNED_IN",l)),this._returnResult({data:{user:u,session:l},error:null})}catch(a){if(await wt(this.storage,`${this.storageKey}-code-verifier`),J(a))return this._returnResult({data:{user:null,session:null},error:a});throw a}}async signInWithPassword(t){try{let r;if("email"in t){const{email:a,password:o,options:s}=t;r=await ne(this.fetch,"POST",`${this.url}/token?grant_type=password`,{headers:this.headers,body:{email:a,password:o,gotrue_meta_security:{captcha_token:s==null?void 0:s.captchaToken}},xform:I_})}else if("phone"in t){const{phone:a,password:o,options:s}=t;r=await ne(this.fetch,"POST",`${this.url}/token?grant_type=password`,{headers:this.headers,body:{phone:a,password:o,gotrue_meta_security:{captcha_token:s==null?void 0:s.captchaToken}},xform:I_})}else throw new dd("You must provide either an email or phone number and a password");const{data:n,error:i}=r;if(i)return this._returnResult({data:{user:null,session:null},error:i});if(!n||!n.session||!n.user){const a=new fo;return this._returnResult({data:{user:null,session:null},error:a})}return n.session&&(await this._saveSession(n.session),await this._notifyAllSubscribers("SIGNED_IN",n.session)),this._returnResult({data:Object.assign({user:n.user,session:n.session},n.weak_password?{weakPassword:n.weak_password}:null),error:i})}catch(r){if(J(r))return this._returnResult({data:{user:null,session:null},error:r});throw r}}async signInWithOAuth(t){var r,n,i,a;return await this._handleProviderSignIn(t.provider,{redirectTo:(r=t.options)===null||r===void 0?void 0:r.redirectTo,scopes:(n=t.options)===null||n===void 0?void 0:n.scopes,queryParams:(i=t.options)===null||i===void 0?void 0:i.queryParams,skipBrowserRedirect:(a=t.o
289ptions)===null||a===void 0?void 0:a.skipBrowserRedirect})}async exchangeCodeForSession(t){return await this.initializePromise,this._acquireLock(this.lockAcquireTimeout,async()=>this._exchangeCodeForSession(t))}async signInWithWeb3(t){const{chain:r}=t;switch(r){case"ethereum":return await this.signInWithEthereum(t);case"solana":return await this.signInWithSolana(t);default:throw new Error(`@supabase/auth-js: Unsupported chain "${r}"`)}}async signInWithEthereum(t){var r,n,i,a,o,s,l,u,d,c,f;let h,v;if("message"in t)h=t.message,v=t.signature;else{const{chain:m,wallet:g,statement:y,options:b}=t;let w;if(xt())if(typeof g=="object")w=g;else{const P=window;if("ethereum"in P&&typeof P.ethereum=="object"&&"request"in P.ethereum&&typeof P.ethereum.request=="function")w=P.ethereum;else throw new Error("@supabase/auth-js: No compatible Ethereum wallet interface on the window object (window.ethereum) detected. Make sure the user already has a wallet installed and connected for this app. Prefer passing the wallet interface object directly to signInWithWeb3({ chain: 'ethereum', wallet: resolvedUserWallet }) instead.")}else{if(typeof g!="object"||!(b!=null&&b.url))throw new Error("@supabase/auth-js: Both wallet and url must be specified in non-browser environments.");w=g}const _=new URL((r=b==null?void 0:b.url)!==null&&r!==void 0?r:window.location.href),x=await w.request({method:"eth_requestAccounts"}).then(P=>P).catch(()=>{throw new Error("@supabase/auth-js: Wallet method eth_requestAccounts is missing or invalid")});if(!x||x.length===0)throw new Error("@supabase/auth-js: No accounts available. Please ensure the wallet is connected.");const S=hC(x[0]);let E=(n=b==null?void 0:b.signInWithEthereum)===null||n===void 0?void 0:n.chainId;if(!E){const P=await w.request({method:"eth_chainId"});E=mz(P)}const k={domain:_.host,address:S,statement:y,uri:_.href,version:"1",chainId:E,nonce:(i=b==null?void 0:b.signInWithEthereum)===null||i===void 0?void 0:i.nonce,issuedAt:(o=(a=b==null?void 0:b.signInWithEthereum)===null||a===void 0?void 0:a.issuedAt)!==null&&o!==void 0?o:new Date,expirationTime:(s=b==null?void 0:b.signInWithEthereum)===null||s===void 0?void 0:s.expirationTime,notBefore:(l=b==null?void 0:b.signInWithEthereum)===null||l===void 0?void 0:l.notBefore,requestId:(u=b==null?void 0:b.signInWithEthereum)===null||u===void 0?void 0:u.requestId,resources:(d=b==null?void 0:b.signInWithEthereum)===null||d===void 0?void 0:d.resources};h=gz(k),v=await w.request({method:"personal_sign",params:[vz(h),S]})}try{const{data:m,error:g}=await ne(this.fetch,"POST",`${this.url}/token?grant_type=web3`,{headers:this.headers,body:Object.assign({chain:"ethereum",message:h,signature:v},!((c=t.options)===null||c===void 0)&&c.captchaToken?{gotrue_meta_security:{captcha_token:(f=t.options)===null||f===void 0?void 0:f.captchaToken}}:null),xform:Br});if(g)throw g;if(!m||!m.session||!m.user){const y=new fo;return this._returnResult({data:{user:null,session:null},error:y})}return m.session&&(await this._saveSession(m.session),await this._notifyAllSubscribers("SIGNED_IN",m.session)),this._returnResult({data:Object.assign({},m),error:g})}catch(m){if(J(m))return this._returnResult({data:{user:null,session:null},error:m});throw m}}async signInWithSolana(t){var r,n,i,a,o,s,l,u,d,c,f,h;let v,m;if("message"in t)v=t.message,m=t.signature;else{const{chain:g,wallet:y,statement:b,options:w}=t;let _;if(xt())if(typeof y=="object")_=y;else{const S=window;if("solana"in S&&typeof S.solana=="object"&&("signIn"in S.solana&&typeof S.solana.signIn=="function"||"signMessage"in S.solana&&typeof S.solana.signMessage=="function"))_=S.solana;else throw new Error("@supabase/auth-js: No compatible Solana wallet interface on the window object (window.solana) detected. Make sure the user already has a wallet installed and connected for this app. Prefer passing the wallet interface object directly to signInWithWeb3({ chain: 'solana', wallet: resolvedUserWallet }) instead.")}else{if(typeof y!="object"||!(w!=null&&w.url))throw new Error("@supabase/auth-js: Both wallet and url must be specified in non-browser environments.");_=y}const x=new URL((r=w==null?void 0:w.url)!==null&&r!==void 0?r:window.location.href);if("signIn"in _&&_.signIn){const S=await _.signIn(Object.assign(Object.assign(Object.assign({issuedAt:new Date().toISOString()},w==null?void 0:w.signInWithSolana),{version:"1",domain:x.host,uri:x.href}),b?{statement:b}:null));let E;if(Array.isArray(S)&&S[0]&&typeof S[0]=="object")E=S[0];else if(S&&typeof S=="object"&&"signedMessage"in S&&"signature"in S)E=S;else throw new Error("@supabase/auth-js: Wallet method signIn() returned unrecognized value");if("signedMessage"in E&&"signature"in E&&(typeof E.signedMessage=="string"||E.signedMessage instanceof Uint8Array)&&E.signature instanceof Uint8Array)v=typeof E.signedMessage=="string"?E.signedMessage:new TextDecoder().decode(E.signedMessage),m=E.signature;else throw new Error("@supabase/auth-js: Wallet method signIn() API returned object without signedMessage and signature fields")}else{if(!("signMessage"in _)||typeof _.signMessage!="function"||!("publicKey"in _)||typeof _!="object"||!_.publicKey||!("toBase58"in _.publicKey)||typeof _.publicKey.toBase58!="function")throw new Error("@supabase/auth-js: Wallet does not have a compatible signMessage() and publicKey.toBase58() API");v=[`${x.host} wants you to sign in with your Solana account:`,_.publicKey.toBase58(),...b?["",b,""]:[""],"Version: 1",`URI: ${x.href}`,`Issued At: ${(i=(n=w==null?void 0:w.signInWithSolana)===null||n===void 0?void 0:n.issuedAt)!==null&&i!==void 0?i:new Date().toISOString()}`,...!((a=w==null?void 0:w.signInWithSolana)===null||a===void 0)&&a.notBefore?[`Not Before: ${w.signInWithSolana.notBefore}`]:[],...!((o=w==null?void 0:w.signInWithSolana)===null||o===void 0)&&o.expirationTime?[`Expiration Time: ${w.signInWithSolana.expirationTime}`]:[],...!((s=w==null?void 0:w.signInWithSolana)===null||s===void 0)&&s.chainId?[`Chain ID: ${w.signInWithSolana.chainId}`]:[],...!((l=w==null?void 0:w.signInWithSolana)===null||l===void 0)&&l.nonce?[`Nonce: ${w.signInWithSolana.nonce}`]:[],...!((u=w==null?void 0:w.signInWithSolana)===null||u===void 0)&&u.requestId?[`Request ID: ${w.signInWithSolana.requestId}`]:[],...!((c=(d=w==null?void 0:w.signInWithSolana)===null||d===void 0?void 0:d.resources)===null||c===void 0)&&c.length?["Resources",...w.sign
289InWithSolana.resources.map(E=>`- ${E}`)]:[]].join(` 290`);const S=await _.signMessage(new TextEncoder().encode(v),"utf8");if(!S||!(S instanceof Uint8Array))throw new Error("@supabase/auth-js: Wallet signMessage() API returned an recognized value");m=S}}try{const{data:g,error:y}=await ne(this.fetch,"POST",`${this.url}/token?grant_type=web3`,{headers:this.headers,body:Object.assign({chain:"solana",message:v,signature:_a(m)},!((f=t.options)===null||f===void 0)&&f.captchaToken?{gotrue_meta_security:{captcha_token:(h=t.options)===null||h===void 0?void 0:h.captchaToken}}:null),xform:Br});if(y)throw y;if(!g||!g.session||!g.user){const b=new fo;return this._returnResult({data:{user:null,session:null},error:b})}return g.session&&(await this._saveSession(g.session),await this._notifyAllSubscribers("SIGNED_IN",g.session)),this._returnResult({data:Object.assign({},g),error:y})}catch(g){if(J(g))return this._returnResult({data:{user:null,session:null},error:g});throw g}}async _exchangeCodeForSession(t){const r=await ua(this.storage,`${this.storageKey}-code-verifier`),[n,i]=(r??"").split("/");try{if(!n&&this.flowType==="pkce")throw new LF;const{data:a,error:o}=await ne(this.fetch,"POST",`${this.url}/token?grant_type=pkce`,{headers:this.headers,body:{auth_code:t,code_verifier:n},xform:Br});if(await wt(this.storage,`${this.storageKey}-code-verifier`),o)throw o;if(!a||!a.session||!a.user){const s=new fo;return this._returnResult({data:{user:null,session:null,redirectType:null},error:s})}return a.session&&(await this._saveSession(a.session),await this._notifyAllSubscribers("SIGNED_IN",a.session)),this._returnResult({data:Object.assign(Object.assign({},a),{redirectType:i??null}),error:o})}catch(a){if(await wt(this.storage,`${this.storageKey}-code-verifier`),J(a))return this._returnResult({data:{user:null,session:null,redirectType:null},error:a});throw a}}async signInWithIdToken(t){try{const{options:r,provider:n,token:i,access_token:a,nonce:o}=t,s=await ne(this.fetch,"POST",`${this.url}/token?grant_type=id_token`,{headers:this.headers,body:{provider:n,id_token:i,access_token:a,nonce:o,gotrue_meta_security:{captcha_token:r==null?void 0:r.captchaToken}},xform:Br}),{data:l,error:u}=s;if(u)return this._returnResult({data:{user:null,session:null},error:u});if(!l||!l.session||!l.user){const d=new fo;return this._returnResult({data:{user:null,session:null},error:d})}return l.session&&(await this._saveSession(l.session),await this._notifyAllSubscribers("SIGNED_IN",l.session)),this._returnResult({data:l,error:u})}catch(r){if(J(r))return this._returnResult({data:{user:null,session:null},error:r});throw r}}async signInWithOtp(t){var r,n,i,a,o;try{if("email"in t){const{email:s,options:l}=t;let u=null,d=null;this.flowType==="pkce"&&([u,d]=await ho(this.storage,this.storageKey));const{error:c}=await ne(this.fetch,"POST",`${this.url}/otp`,{headers:this.headers,body:{email:s,data:(r=l==null?void 0:l.data)!==null&&r!==void 0?r:{},create_user:(n=l==null?void 0:l.shouldCreateUser)!==null&&n!==void 0?n:!0,gotrue_meta_security:{captcha_token:l==null?void 0:l.captchaToken},code_challenge:u,code_challenge_method:d},redirectTo:l==null?void 0:l.emailRedirectTo});return this._returnResult({data:{user:null,session:null},error:c})}if("phone"in t){const{phone:s,options:l}=t,{data:u,error:d}=await ne(this.fetch,"POST",`${this.url}/otp`,{headers:this.headers,body:{phone:s,data:(i=l==null?void 0:l.data)!==null&&i!==void 0?i:{},create_user:(a=l==null?void 0:l.shouldCreateUser)!==null&&a!==void 0?a:!0,gotrue_meta_security:{captcha_token:l==null?void 0:l.captchaToken},channel:(o=l==null?void 0:l.channel)!==null&&o!==void 0?o:"sms"}});return this._returnResult({data:{user:null,session:null,messageId:u==null?void 0:u.message_id},error:d})}throw new dd("You must provide either an email or phone number.")}catch(s){if(await wt(this.storage,`${this.storageKey}-code-verifier`),J(s))return this._returnResult({data:{user:null,session:null},error:s});throw s}}async verifyOtp(t){var r,n;try{let i,a;"options"in t&&(i=(r=t.options)===null||r===void 0?void 0:r.redirectTo,a=(n=t.options)===null||n===void 0?void 0:n.captchaToken);const{data:o,error:s}=await ne(this.fetch,"POST",`${this.url}/verify`,{headers:this.headers,body:Object.assign(Object.assign({},t),{gotrue_meta_security:{captcha_token:a}}),redirectTo:i,xform:Br});if(s)throw s;if(!o)throw new Error("An error occurred on token verification.");const l=o.session,u=o.user;return l!=null&&l.access_token&&(await this._saveSession(l),await this._notifyAllSubscribers(t.type=="recovery"?"PASSWORD_RECOVERY":"SIGNED_IN",l)),this._returnResult({data:{user:u,session:l},error:null})}catch(i){if(J(i))return this._returnResult({data:{user:null,session:null},error:i});throw i}}async signInWithSSO(t){var r,n,i,a,o;try{let s=null,l=null;this.flowType==="pkce"&&([s,l]=await ho(this.storage,this.storageKey));const u=await ne(this.fetch,"POST",`${this.url}/sso`,{body:Object.assign(Object.assign(Object.assign(Object.assign(Object.assign({},"providerId"in t?{provider_id:t.providerId}:null),"domain"in t?{domain:t.domain}:null),{redirect_to:(n=(r=t.options)===null||r===void 0?void 0:r.redirectTo)!==null&&n!==void 0?n:void 0}),!((i=t==null?void 0:t.options)===null||i===void 0)&&i.captchaToken?{gotrue_meta_security:{captcha_token:t.options.captchaToken}}:null),{skip_http_redirect:!0,code_challenge:s,code_challenge_method:l}),headers:this.headers,xform:uz});return!((a=u.data)===null||a===void 0)&&a.url&&xt()&&!(!((o=t.options)===null||o===void 0)&&o.skipBrowserRedirect)&&window.location.assign(u.data.url),this._returnResult(u)}catch(s){if(await wt(this.storage,`${this.storageKey}-code-verifier`),J(s))return this._returnResult({data:null,error:s});throw s}}async reauthenticate(){return await this.initializePromise,await this._acquireLock(this.lockAcquireTimeout,async()=>await this._reauthenticate())}async _reauthenticate(){try{return await this._useSession(async t=>{const{data:{session:r},error:n}=t;if(n)throw n;if(!r)throw new tr;const{error:i}=await ne(this.fetch,"GET",`${this.url}/reauthenticate`,{headers:this.headers,jwt:r.access_token});return this._returnResult({data:{user:null,session:null},error:i})})}catch(t){if(J(t))return this._returnResult({data:{user:null,session:null},error:t});throw t}}async resend(t){try{const r=`${this.url}/resend`;if("email"in t){const{email:n,type:i,options:a}=t,{error:o}=await ne(this.fetch,"POST",r,{headers:this.headers,body:{email:n,type:i,gotrue_meta_security:{captcha_token:a==null?void 0:a.captchaToken}},redirectTo:a==null?void 0:a.emailRedirectTo});return this._returnResult({data:{user:null,session:null},error:o})}else if("phone"in t){const{phone:n,type:i,options:a}=t,{data:o,error:s}=await ne(this.fetch,"POST",r,{headers:this.headers,body:{phone:n,type:i,gotrue_meta_security:{captcha_token:a==null?void 0:a.captchaToken}}});return this._returnResult({data:{user:null,session:null,messageId:o==null?void 0:o.message_id},error:s})}throw new dd("You must provide either an email or phone number and a type")}catch(r){if(J(r))return this._returnResult({data:{user:null,session:null},error:r});throw r}}async getSession(){return await this.initializePromise,await this._acquireLock(this.lockAcquireTimeout,async()=>this._useSession(async r=>r))}async _acquireLock(t,r){this._debug("#_acquireLock","begin",t);try{if(this.lockAcquired){const n=this.pendingInLock.length?this.pendingInLock[this.pendingInLock.length-1]:Promise.resolve(),i=(async()=>(await n,await r()))();return this.pendingInLock.push((async()=>{try{await i}catch{}})()),i}return await this.lock(`lock:${this.storageKey}`,t,async()=>{this._debug("#_acquireLock","lock acquired for storage key",this.storageKey);try{this.lockAcquired=!0;const n=r();for(this.pendingInLock.push((async()=>{try{await n}catch{}})()),await n;this.pendingInLock.length;){const i=[...this.pendingInLock];await Promise.all(i),this.pendingInLock.splice(0,i.length)}return await n}finally{this._debug("#_acquireLock","lock released for storage key",this.storageKey),this.lockAcquired=!1}})}finally{this._debug("#_acquireLock","end")}}async _useSession(t){this._debug("#_useSession","begin");try{const r=await this.__loadSession();return await t(r)}finally{this._debug("#_useSession","end")}}async __loadSession(){this._debug("#__loadSession()","begin"),this.lockAcquired||this._debug("#__loadSession()","used outside of an acquired lock!",new Error().stack);try{let t=null;const r=await ua(this.storage,this.storageKey);if(this._debug("#getSession()","session from storage",r),r!==null&&(this._isValidSession(r)?t=r:(this._debug("#getSession()","session from storage is not val
290id"),await this._removeSession())),!t)return{data:{session:null},error:null};const n=t.expires_at?t.expires_at*1e3-Date.now()<Jm:!1;if(this._debug("#__loadSession()",`session has${n?"":" not"} expired`,"expires_at",t.expires_at),!n){if(this.userStorage){const o=await ua(this.userStorage,this.storageKey+"-user");o!=null&&o.user?t.user=o.user:t.user=tv()}if(this.storage.isServer&&t.user&&!t.user.__isUserNotAvailableProxy){const o={value:this.suppressGetSessionWarning};t.user=az(t.user,o),o.value&&(this.suppressGetSessionWarning=!0)}return{data:{session:t},error:null}}const{data:i,error:a}=await this._callRefreshToken(t.refresh_token);return a?this._returnResult({data:{session:null},error:a}):this._returnResult({data:{session:i},error:null})}finally{this._debug("#__loadSession()","end")}}async getUser(t){if(t)return await this._getUser(t);await this.initializePromise;const r=await this._acquireLock(this.lockAcquireTimeout,async()=>await this._getUser());return r.data.user&&(this.suppressGetSessionWarning=!0),r}async _getUser(t){try{return t?await ne(this.fetch,"GET",`${this.url}/user`,{headers:this.headers,jwt:t,xform:Oi}):await this._useSession(async r=>{var n,i,a;const{data:o,error:s}=r;if(s)throw s;return!(!((n=o.session)===null||n===void 0)&&n.access_token)&&!this.hasCustomAuthorizationHeader?{data:{user:null},error:new tr}:await ne(this.fetch,"GET",`${this.url}/user`,{headers:this.headers,jwt:(a=(i=o.session)===null||i===void 0?void 0:i.access_token)!==null&&a!==void 0?a:void 0,xform:Oi})})}catch(r){if(J(r))return Zm(r)&&(await this._removeSession(),await wt(this.storage,`${this.storageKey}-code-verifier`)),this._returnResult({data:{user:null},error:r});throw r}}async updateUser(t,r={}){return await this.initializePromise,await this._acquireLock(this.lockAcquireTimeout,async()=>await this._updateUser(t,r))}async _updateUser(t,r={}){try{return await this._useSession(async n=>{const{data:i,error:a}=n;if(a)throw a;if(!i.session)throw new tr;const o=i.session;let s=null,l=null;this.flowType==="pkce"&&t.email!=null&&([s,l]=await ho(this.storage,this.storageKey));const{data:u,error:d}=await ne(this.fetch,"PUT",`${this.url}/user`,{headers:this.headers,redirectTo:r==null?void 0:r.emailRedirectTo,body:Object.assign(Object.assign({},t),{code_challenge:s,code_challenge_method:l}),jwt:o.access_token,xform:Oi});if(d)throw d;return o.user=u.user,await this._saveSession(o),await this._notifyAllSubscribers("USER_UPDATED",o),this._returnResult({data:{user:o.user},error:null})})}catch(n){if(await wt(this.storage,`${this.storageKey}-code-verifier`),J(n))return this._returnResult({data:{user:null},error:n});throw n}}async setSession(t){return await this.initializePromise,await this._acquireLock(this.lockAcquireTimeout,async()=>await this._setSession(t))}async _setSession(t){try{if(!t.access_token||!t.refresh_token)throw new tr;const r=Date.now()/1e3;let n=r,i=!0,a=null;const{payload:o}=hd(t.access_token);if(o.exp&&(n=o.exp,i=n<=r),i){const{data:s,error:l}=await this._callRefreshToken(t.refresh_token);if(l)return this._returnResult({data:{user:null,session:null},error:l});if(!s)return{data:{user:null,session:null},error:null};a=s}else{const{data:s,error:l}=await this._getUser(t.access_token);if(l)return this._returnResult({data:{user:null,session:null},error:l});a={access_token:t.access_token,refresh_token:t.refresh_token,user:s.user,token_type:"bearer",expires_in:n-r,expires_at:n},await this._saveSession(a),await this._notifyAllSubscribers("SIGNED_IN",a)}return this._returnResult({data:{user:a.user,session:a},error:null})}catch(r){if(J(r))return this._returnResult({data:{session:null,user:null},error:r});throw r}}async refreshSession(t){return await this.initializePromise,await this._acquireLock(this.lockAcquireTimeout,async()=>await this._refreshSession(t))}async _refreshSession(t){try{return await this._useSession(async r=>{var n;if(!t){const{data:o,error:s}=r;if(s)throw s;t=(n=o.session)!==null&&n!==void 0?n:void 0}if(!(t!=null&&t.refresh_token))throw new tr;const{data:i,error:a}=await this._callRefreshToken(t.refresh_token);return a?this._returnResult({data:{user:null,session:null},error:a}):i?this._returnResult({data:{user:i.user,session:i},error:null}):this._returnResult({data:{user:null,session:null},error:null})})}catch(r){if(J(r))return this._returnResult({data:{user:null,session:null},error:r});throw r}}async _getSessionFromURL(t,r){try{if(!xt())throw new fd("No browser detected.");
290if(t.error||t.error_description||t.error_code)throw new fd(t.error_description||"Error in URL with unspecified error_description",{error:t.error||"unspecified_error",code:t.error_code||"unspecified_code"});switch(r){case"implicit":if(this.flowType==="pkce")throw new A_("Not a valid PKCE flow url.");break;case"pkce":if(this.flowType==="implicit")throw new fd("Not a valid implicit grant flow url.");break;default:}if(r==="pkce"){if(this._debug("#_initialize()","begin","is PKCE flow",!0),!t.code)throw new A_("No code detected.");const{data:b,error:w}=await this._exchangeCodeForSession(t.code);if(w)throw w;const _=new URL(window.location.href);return _.searchParams.delete("code"),window.history.replaceState(window.history.state,"",_.toString()),{data:{session:b.session,redirectType:null},error:null}}const{provider_token:n,provider_refresh_token:i,access_token:a,refresh_token:o,expires_in:s,expires_at:l,token_type:u}=t;if(!a||!s||!o||!u)throw new fd("No session defined in URL");const d=Math.round(Date.now()/1e3),c=parseInt(s);let f=d+c;l&&(f=parseInt(l));const h=f-d;h*1e3<=Oo&&console.warn(`@supabase/gotrue-js: Session as retrieved from URL expires in ${h}s, should have been closer to ${c}s`);const v=f-c;d-v>=120?console.warn("@supabase/gotrue-js: Session as retrieved from URL was issued over 120s ago, URL could be stale",v,f,d):d-v<0&&console.warn("@supabase/gotrue-js: Session as retrieved from URL was issued in the future? Check the device clock for skew",v,f,d);const{data:m,error:g}=await this._getUser(a);if(g)throw g;const y={provider_token:n,provider_refresh_token:i,access_token:a,expires_in:c,expires_at:f,refresh_token:o,token_type:u,user:m.user};return window.location.hash="",this._debug("#_getSessionFromURL()","clearing window.location.hash"),this._returnResult({data:{session:y,redirectType:t.type},error:null})}catch(n){if(J(n))return this._returnResult({data:{session:null,redirectType:null},error:n});throw n}}_isImplicitGrantCallback(t){return typeof this.detectSessionInUrl=="function"?this.detectSessionInUrl(new URL(window.location.href),t):!!(t.access_token||t.error_description)}async _isPKCECallback(t){const r=await ua(this.storage,`${this.storageKey}-code-verifier`);return!!(t.code&&r)}async signOut(t={scope:"global"}){return await this.initializePromise,await this._acquireLock(this.lockAcquireTimeout,async()=>await this._signOut(t))}async _signOut({scope:t}={scope:"global"}){return await this._useSession(async r=>{var n;const{data:i,error:a}=r;if(a&&!Zm(a))return this._returnResult({error:a});const o=(n=i.session)===null||n===void 0?void 0:n.access_token;if(o){const{error:s}=await this.admin.signOut(o,t);if(s&&!(MF(s)&&(s.status===404||s.status===401||s.status===403)||Zm(s)))return this._returnResult({error:s})}return t!=="others"&&(await this._removeSession(),await wt(this.storage,`${this.storageKey}-code-verifier`)),this._returnResult({error:null})})}onAuthStateChange(t){const r=HF(),n={id:r,callback:t,unsubscribe:()=>{this._debug("#unsubscribe()","state change callback with id removed",r),this.stateChangeEmitters.delete(r)}};return this._debug("#onAuthStateChange()","registered callback with id",r),this.stateChangeEmitters.set(r,n),(async()=>(await this.initializePromise,await this._acquireLock(this.lockAcquireTimeout,async()=>{this._emitInitialSession(r)})))(),{data:{subscription:n}}}async _emitInitialSession(t){return await this._useSession(async r=>{var n,i;try{const{data:{session:a},error:o}=r;if(o)throw o;await((n=this.stateChangeEmitters.get(t))===null||n===void 0?void 0:n.callback("INITIAL_SESSION",a)),this._debug("INITIAL_SESSION","callback id",t,"session",a)}catch(a){await((i=this.stateChangeEmitters.get(t))===null||i===void 0?void 0:i.callback("INITIAL_SESSION",null)),this._debug("INITIAL_SESSION","callback id",t,"error",a),console.error(a)}})}async resetPasswordForEmail(t,r={}){let n=null,i=null;this.flowType==="pkce"&&([n,i]=await ho(this.storage,this.storageKey,!0));try{return await ne(this.fetch,"POST",`${this.url}/recover`,{body:{email:t,code_challenge:n,code_challenge_method:i,gotrue_meta_security:{captcha_token:r.captchaToken}},headers:this.headers,redirectTo:r.redirectTo})}catch(a){if(await wt(this.storage,`${this.storageKey}-code-verifier`),J(a))return this._returnResult({data:null,error:a});throw a}}async getUserIdentities(){var t;try{const{data:r,error:n}=await this.getUser();if(n)throw n;return this._returnResult({data:{identities:(t=r.user.identities)!==null&&t!==void 0?t:[]},error:null})}catch(r){if(J(r))return this._returnResult({data:null,error:r});throw r}}async linkIdentity(t){return"token"in t?this.linkIdentityIdToken(t):this.linkIdentityOAuth(t)}async linkIdentityOAuth(t){var r;try{const{data:n,error:i}=await this._useSession(async a=>{var o,s,l,u,d;const{data:c,error:f}=a;if(f)throw f;const h=await this._getUrlForProvider(`${this.url}/user/identities/authorize`,t.provider,{redirectTo:(o=t.options)===null||o===void 0?void 0:o.redirectTo,scopes:(s=t.options)===null||s===void 0?void 0:s.scopes,queryParams:(l=t.options)===null||l===void 0?void 0:l.queryParams,skipBrowserRedirect:!0});return await ne(this.fetch,"GET",h,{headers:this.headers,jwt:(d=(u=c.session)===null||u===void 0?void 0:u.access_token)!==null&&d!==void 0?d:void 0})});if(i)throw i;return xt()&&!(!((r=t.options)===null||r===void 0)&&r.skipBrowserRedirect)&&window.location.assign(n==null?void 0:n.url),this._returnResult({data:{provider:t.provider,url:n==null?void 0:n.url},error:null})}catch(n){if(J(n))return this._returnResult({data:{provider:t.provider,url:null},error:n});throw n}}async linkIdentityIdToken(t){return await this._useSession(async r=>{var n;try{const{error:i,data:{session:a}}=r;if(i)throw i;const{options:o,provider:s,token:l,access_token:u,nonce:d}=t,c=await ne(this.fetch,"POST",`${this.url}/token?grant_type=id_token`,{headers:this.headers,jwt:(n=a==null?void 0:a.access_token)!==null&&n!==void 0?n:void 0,body:{provider:s,id_token:l,access_token:u,nonce:d,link_identity:!0,gotrue_meta_security:{captcha_token:o==null?void 0:o.captchaToken}},xform:Br}),{data:f,error:h}=c;return h?this._returnResult({data:{user:null,session:null},error:h}):!f||!f.session||!f.user?this._returnResult({data:{user:null,session:null},error:new fo}):(f.session&&(await this._saveSession(f.session),await this._notifyAllSubscribers("USER_UPDATED",f.session)),this._returnResult({data:f,error:h}))}catch(i){if(await wt(this.storage,`${this.storageKey}-code-verifier`),J(i))return this._returnResult({data:{user:null,session:null},error:i});throw i}})}async unlinkIdentity(t){try{return await this._useSession(async r=>{var n,i;const{data:a,error:o}=r;if(o)throw o;
290return await ne(this.fetch,"DELETE",`${this.url}/user/identities/${t.identity_id}`,{headers:this.headers,jwt:(i=(n=a.session)===null||n===void 0?void 0:n.access_token)!==null&&i!==void 0?i:void 0})})}catch(r){if(J(r))return this._returnResult({data:null,error:r});throw r}}async _refreshAccessToken(t){const r=`#_refreshAccessToken(${t.substring(0,5)}...)`;this._debug(r,"begin");try{const n=Date.now();return await YF(async i=>(i>0&&await GF(200*Math.pow(2,i-1)),this._debug(r,"refreshing attempt",i),await ne(this.fetch,"POST",`${this.url}/token?grant_type=refresh_token`,{body:{refresh_token:t},headers:this.headers,xform:Br})),(i,a)=>{const o=200*Math.pow(2,i);return a&&ev(a)&&Date.now()+o-n<Oo})}catch(n){if(this._debug(r,"error",n),J(n))return this._returnResult({data:{session:null,user:null},error:n});throw n}finally{this._debug(r,"end")}}_isValidSession(t){return typeof t=="object"&&t!==null&&"access_token"in t&&"refresh_token"in t&&"expires_at"in t}async _handleProviderSignIn(t,r){const n=await this._getUrlForProvider(`${this.url}/authorize`,t,{redirectTo:r.redirectTo,scopes:r.scopes,queryParams:r.queryParams});return this._debug("#_handleProviderSignIn()","provider",t,"options",r,"url",n),xt()&&!r.skipBrowserRedirect&&window.location.assign(n),{data:{provider:t,url:n},error:null}}async _recoverAndRefresh(){var t,r;const n="#_recoverAndRefresh()";this._debug(n,"begin");try{const i=await ua(this.storage,this.storageKey);if(i&&this.userStorage){let o=await ua(this.userStorage,this.storageKey+"-user");!this.storage.isServer&&Object.is(this.storage,this.userStorage)&&!o&&(o={user:i.user},await Eo(this.userStorage,this.storageKey+"-user",o)),i.user=(t=o==null?void 0:o.user)!==null&&t!==void 0?t:tv()}else if(i&&!i.user&&!i.user){const o=await ua(this.storage,this.storageKey+"-user");o&&(o!=null&&o.user)?(i.user=o.user,await wt(this.storage,this.storageKey+"-user"),await Eo(this.storage,this.storageKey,i)):i.user=tv()}if(this._debug(n,"session from storage",i),!this._isValidSession(i)){this._debug(n,"session is not valid"),i!==null&&await this._removeSession();return}const a=((r=i.expires_at)!==null&&r!==void 0?r:1/0)*1e3-Date.now()<Jm;if(this._debug(n,`session has${a?"":" not"} expired with margin of ${Jm}s`),a){if(this.autoRefreshToken&&i.refresh_token){const{error:o}=await this._callRefreshToken(i.refresh_token);o&&(console.error(o),ev(o)||(this._debug(n,"refresh failed with a non-retryable error, removing the session",o),await this._removeSession()))}}else if(i.user&&i.user.__isUserNotAvailableProxy===!0)try{const{data:o,error:s}=await this._getUser(i.access_token);!s&&(o!=null&&o.user)?(i.user=o.user,await this._saveSession(i),await this._notifyAllSubscribers("SIGNED_IN",i)):this._debug(n,"could not get user data, skipping SIGNED_IN notification")}catch(o){console.error("Error getting user data:",o),this._debug(n,"error getting user data, skipping SIGNED_IN notification",o)}else await this._notifyAllSubscribers("SIGNED_IN",i)}catch(i){this._debug(n,"error",i),console.error(i);return}finally{this._debug(n,"end")}}async _callRefreshToken(t){var r,n;if(!t)throw new tr;if(this.refreshingDeferred)return this.refreshingDeferred.promise;const i=`#_callRefreshToken(${t.substring(0,5)}...)`;this._debug(i,"begin");try{this.refreshingDeferred=new mp;const{data:a,error:o}=await this._refreshAccessToken(t);if(o)throw o;if(!a.session)throw new tr;await this._saveSession(a.session),await this._notifyAllSubscribers("TOKEN_REFRESHED",a.session);const s={data:a.session,error:null};return this.refreshingDeferred.resolve(s),s}catch(a){if(this._debug(i,"error",a),J(a)){const o={data:null,error:a};return ev(a)||await this._removeSession(),(r=this.refreshingDeferred)===null||r===void 0||r.resolve(o),o}throw(n=this.refreshingDeferred)===null||n===void 0||n.reject(a),a}finally{this.refreshingDeferred=null,this._debug(i,"end")}}async _notifyAllSubscribers(t,r,n=!0){const i=`#_notifyAllSubscribers(${t})`;this._debug(i,"begin",r,`broadcast = ${n}`);try{this.broadcastChannel&&n&&this.broadcastChannel.postMessage({event:t,session:r});const a=[],o=Array.from(this.stateChangeEmitters.values()).map(async s=>{try{await s.callback(t,r)}catch(l){a.push(l)}});if(await Promise.all(o),a.length>0){for(let s=0;s<a.length;s+=1)console.error(a[s]);throw a[0]}}finally{this._debug(i,"end")}}async _saveSession(t){this._debug("#_saveSession()",t),this.suppressGetSessionWarning=!0,await wt(this.storage,`${this.storageKey}-code-verifier`);const r=Object.assign({},t),n=r.user&&r.user.__isUserNotAvailableProxy===!0;if(this.userStorage){!n&&r.user&&await Eo(this.userStorage,this.storageKey+"-user",{user:r.user});const i=Object.assign({},r);delete i.user;const a=$_(i);await Eo(this.storage,this.storageKey,a)}else{const i=$_(r);await Eo(this.storage,this.storageKey,i)}}async _removeSession(){this._debug("#_removeSession()"),this.suppressGetSessionWarning=!1,await wt(this.storage,this.storageKey),await wt(this.storage,this.storageKey+"-code-verifier"),await wt(this.storage,this.storageKey+"-user"),this.userStorage&&await wt(this.userStorage,this.storageKey+"-user"),await this._notifyAllSubscribers("SIGNED_OUT",null)}_removeVisibilityChangedCallback(){this._debug("#_removeVisibilityChangedCallback()");const t=this.visibilityChangedCallback;this.visibilityChangedCallback=null;try{t&&xt()&&(window!=null&&window.removeEventListener)&&window.removeEventListener("visibilitychange",t)}
290catch(r){console.error("removing visibilitychange callback failed",r)}}async _startAutoRefresh(){await this._stopAutoRefresh(),this._debug("#_startAutoRefresh()");const t=setInterval(()=>this._autoRefreshTokenTick(),Oo);this.autoRefreshTicker=t,t&&typeof t=="object"&&typeof t.unref=="function"?t.unref():typeof Deno<"u"&&typeof Deno.unrefTimer=="function"&&Deno.unrefTimer(t);const r=setTimeout(async()=>{await this.initializePromise,await this._autoRefreshTokenTick()},0);this.autoRefreshTickTimeout=r,r&&typeof r=="object"&&typeof r.unref=="function"?r.unref():typeof Deno<"u"&&typeof Deno.unrefTimer=="function"&&Deno.unrefTimer(r)}async _stopAutoRefresh(){this._debug("#_stopAutoRefresh()");const t=this.autoRefreshTicker;this.autoRefreshTicker=null,t&&clearInterval(t);const r=this.autoRefreshTickTimeout;this.autoRefreshTickTimeout=null,r&&clearTimeout(r)}async startAutoRefresh(){this._removeVisibilityChangedCallback(),await this._startAutoRefresh()}async stopAutoRefresh(){this._removeVisibilityChangedCallback(),await this._stopAutoRefresh()}async _autoRefreshTokenTick(){this._debug("#_autoRefreshTokenTick()","begin");try{await this._acquireLock(0,async()=>{try{const t=Date.now();try{return await this._useSession(async r=>{const{data:{session:n}}=r;if(!n||!n.refresh_token||!n.expires_at){this._debug("#_autoRefreshTokenTick()","no session");return}const i=Math.floor((n.expires_at*1e3-t)/Oo);this._debug("#_autoRefreshTokenTick()",`access token expires in ${i} ticks, a tick lasts ${Oo}ms, refresh threshold is ${ry} ticks`),i<=ry&&await this._callRefreshToken(n.refresh_token)})}catch(r){console.error("Auto refresh tick failed with error. This is likely a transient error.",r)}}finally{this._debug("#_autoRefreshTokenTick()","end")}})}catch(t){if(t.isAcquireTimeout||t instanceof fC)this._debug("auto refresh token tick lock not available");else throw t}}async _handleVisibilityChange(){if(this._debug("#_handleVisibilityChange()"),!xt()||!(window!=null&&window.addEventListener))return this.autoRefreshToken&&this.startAutoRefresh(),!1;try{this.visibilityChangedCallback=async()=>{try{await this._onVisibilityChanged(!1)}catch(t){this._debug("#visibilityChangedCallback","error",t)}},window==null||window.addEventListener("visibilitychange",this.visibilityChangedCallback),await this._onVisibilityChanged(!0)}catch(t){console.error("_handleVisibilityChange",t)}}async _onVisibilityChanged(t){const r=`#_onVisibilityChanged(${t})`;this._debug(r,"visibilityState",document.visibilityState),document.visibilityState==="visible"?(this.autoRefreshToken&&this._startAutoRefresh(),t||(await this.initializePromise,await this._acquireLock(this.lockAcquireTimeout,async()=>{if(document.visibilityState!=="visible"){this._debug(r,"acquired the lock to recover the session, but the browser visibilityState is no longer visible, aborting");return}await this._recoverAndRefresh()}))):document.visibilityState==="hidden"&&this.autoRefreshToken&&this._stopAutoRefresh()}async _getUrlForProvider(t,r,n){const i=[`provider=${encodeURIComponent(r)}`];if(n!=null&&n.redirectTo&&i.push(`redirect_to=${encodeURIComponent(n.redirectTo)}`),n!=null&&n.scopes&&i.push(`scopes=${encodeURIComponent(n.scopes)}`),this.flowType==="pkce"){const[a,o]=await ho(this.storage,this.storageKey),s=new URLSearchParams({code_challenge:`${encodeURIComponent(a)}`,code_challenge_method:`${encodeURIComponent(o)}`});i.push(s.toString())}if(n!=null&&n.queryParams){const a=new URLSearchParams(n.queryParams);i.push(a.toString())}return n!=null&&n.skipBrowserRedirect&&i.push(`skip_http_redirect=${n.skipBrowserRedirect}`),`${t}?${i.join("&")}`}async _unenroll(t){try{return await this._useSession(async r=>{var n;const{data:i,error:a}=r;return a?this._returnResult({data:null,error:a}):await ne(this.fetch,"DELETE",`${this.url}/factors/${t.factorId}`,{headers:this.headers,jwt:(n=i==null?void 0:i.session)===null||n===void 0?void 0:n.access_token})})}catch(r){if(J(r))return this._returnResult({data:null,error:r});throw r}}async _enroll(t){try{return await this._useSession(async r=>{var n,i;const{data:a,error:o}=r;if(o)return this._returnResult({data:null,error:o});const s=Object.assign({friendly_name:t.friendlyName,factor_type:t.factorType},t.factorType==="phone"?{phone:t.phone}:t.factorType==="totp"?{issuer:t.issuer}:{}),{data:l,error:u}=await ne(this.fetch,"POST",`${this.url}/factors`,{body:s,headers:this.headers,jwt:(n=a==null?void 0:a.session)===null||n===void 0?void 0:n.access_token});return u?this._returnResult({data:null,error:u}):(t.factorType==="totp"&&l.type==="totp"&&(!((i=l==null?void 0:l.totp)===null||i===void 0)&&i.qr_code)&&(l.totp.qr_code=`data:image/svg+xml;utf-8,${l.totp.qr_code}`),this._returnResult({data:l,error:null}))})}catch(r){if(J(r))return this._returnResult({data:null,error:r});throw r}}async _verify(t){return this._acquireLock(this.lockAcquireTimeout,async()=>{try{return await this._useSession(async r=>{var n;const{data:i,error:a}=r;if(a)return this._returnResult({data:null,error:a});const o=Object.assign({challenge_id:t.challengeId},"webauthn"in t?{webauthn:Object.assign(Object.assign({},t.webauthn),{credential_response:t.webauthn.type==="create"?Oz(t.webauthn.credential_response):Ez(t.webauthn.credential_response)})}:{code:t.code}),{data:s,error:l}=await ne(this.fetch,"POST",`${this.url}/factors/${t.factorId}/verify`,{body:o,headers:this.headers,jwt:(n=i==null?void 0:i.session)===null||n===void 0?void 0:n.access_token});return l?this._returnResult({data:null,error:l}):(await this._saveSession(Object.assign({expires_at:Math.round(Date.now()/1e3)+s.expires_in},s)),await this._notifyAllSubscribers("MFA_CHALLENGE_VERIFIED",s),this._returnResult({data:s,error:l}))})}catch(r){if(J(r))return this._returnResult({data:null,error:r});throw r}})}async _challenge(t){return this._acquireLock(this.lockAcquireTimeout,async()=>{try{return await this._useSession(async r=>{var n;const{data:i,error:a}=r;if(a)return this._returnResult({data:null,error:a});const o=await ne(this.fetch,"POST",`${this.url}/factors/${t.factorId}/challenge`,{body:t,headers:this.headers,jwt:(n=i==null?void 0:i.session)===null||n===void 0?void 0:n.access_token});if(o.error)return o;const{data:s}=o;if(s.type!=="webauthn")return{data:s,error:null};switch(s.webauthn.type){case"create":return{data:Object.assign(Object.assign({},s),{webauthn:Object.assign(Object.assign({},s.webauthn),{credential_options:Object.assign(Object.assign({},s.webauthn.credential_options),{publicKey:_z(s.webauthn.credential_options.publicKey)})})}),error:null};case"request":return{data:Object.assign(Object.assign({},s),{webauthn:Object.assign(Object.assign({},s.webauthn),{credential_options:Object.assign(Object.assign({},s.webauthn.credential_options),{publicKey:Sz(s.webauthn.credential_options.publicKey)})})}),error:null}}})}catch(r){if(J(r))return this._returnResult({data:null,error:r});throw r}})}async _challengeAndVerify(t){const{data:r,error:n}=await this._challenge({factorId:t.factorId});return n?this._returnResult({data:null,error:n}):await this._verify({factorId:t.factorId,challengeId:r.id,code:t.code})}async _listFactors(){var t;const{data:{user:r},error:n}=await this.getUser();if(n)return{data:null,error:n};const i={all:[],phone:[],totp:[],webauthn:[]};for(const a of(t=r==null?void 0:r.factors)!==null&&t!==void 0?t:[])i.all.push(a),a.status==="verified"&&i[a.factor_type].push(a);return{data:i,error:null}}async _getAuthenticatorAssuranceLevel(t){var r,n,i,a;if(t)try{const{payload:h}=hd(t);let v=null;h.aal&&(v=h.aal);let m=v;const{data:{user:g},error:y}=await this.getUser(t);if(y)return this._returnResult({data:null,error:y});((n=(r=g==null?void 0:g.factors)===null||r===void 0?void 0:r.filter(_=>_.status==="verified"))!==null&&n!==void 0?n:[]).length>0&&(m="aal2");const w=h.amr||[];return{data:{currentLevel:v,nextLevel:m,currentAuthenticationMethods:w},error:null}}catch(h){if(J(h))return this._returnResult({data:null,error:h});throw h}const{data:{session:o},error:s}
290=await this.getSession();if(s)return this._returnResult({data:null,error:s});if(!o)return{data:{currentLevel:null,nextLevel:null,currentAuthenticationMethods:[]},error:null};const{payload:l}=hd(o.access_token);let u=null;l.aal&&(u=l.aal);let d=u;((a=(i=o.user.factors)===null||i===void 0?void 0:i.filter(h=>h.status==="verified"))!==null&&a!==void 0?a:[]).length>0&&(d="aal2");const f=l.amr||[];return{data:{currentLevel:u,nextLevel:d,currentAuthenticationMethods:f},error:null}}async _getAuthorizationDetails(t){try{return await this._useSession(async r=>{const{data:{session:n},error:i}=r;return i?this._returnResult({data:null,error:i}):n?await ne(this.fetch,"GET",`${this.url}/oauth/authorizations/${t}`,{headers:this.headers,jwt:n.access_token,xform:a=>({data:a,error:null})}):this._returnResult({data:null,error:new tr})})}catch(r){if(J(r))return this._returnResult({data:null,error:r});throw r}}async _approveAuthorization(t,r){try{return await this._useSession(async n=>{const{data:{session:i},error:a}=n;if(a)return this._returnResult({data:null,error:a});if(!i)return this._returnResult({data:null,error:new tr});const o=await ne(this.fetch,"POST",`${this.url}/oauth/authorizations/${t}/consent`,{headers:this.headers,jwt:i.access_token,body:{action:"approve"},xform:s=>({data:s,error:null})});return o.data&&o.data.redirect_url&&xt()&&!(r!=null&&r.skipBrowserRedirect)&&window.location.assign(o.data.redirect_url),o})}catch(n){if(J(n))return this._returnResult({data:null,error:n});throw n}}async _denyAuthorization(t,r){try{return await this._useSession(async n=>{const{data:{session:i},error:a}=n;if(a)return this._returnResult({data:null,error:a});if(!i)return this._returnResult({data:null,error:new tr});const o=await ne(this.fetch,"POST",`${this.url}/oauth/authorizations/${t}/consent`,{headers:this.headers,jwt:i.access_token,body:{action:"deny"},xform:s=>({data:s,error:null})});return o.data&&o.data.redirect_url&&xt()&&!(r!=null&&r.skipBrowserRedirect)&&window.location.assign(o.data.redirect_url),o})}catch(n){if(J(n))return this._returnResult({data:null,error:n});throw n}}async _listOAuthGrants(){try{return await this._useSession(async t=>{const{data:{session:r},error:n}=t;return n?this._returnResult({data:null,error:n}):r?await ne(this.fetch,"GET",`${this.url}/user/oauth/grants`,{headers:this.headers,jwt:r.access_token,xform:i=>({data:i,error:null})}):this._returnResult({data:null,error:new tr})})}catch(t){if(J(t))return this._returnResult({data:null,error:t});throw t}}async _revokeOAuthGrant(t){try{return await this._useSession(async r=>{const{data:{session:n},error:i}=r;return i?this._returnResult({data:null,error:i}):n?(await ne(this.fetch,"DELETE",`${this.url}/user/oauth/grants`,{headers:this.headers,jwt:n.access_token,query:{client_id:t.clientId},noResolveJson:!0}),{data:{},error:null}):this._returnResult({data:null,error:new tr})})}catch(r){if(J(r))return this._returnResult({data:null,error:r});throw r}}async fetchJwk(t,r={keys:[]}){let n=r.keys.find(s=>s.kid===t);if(n)return n;const i=Date.now();if(n=this.jwks.keys.find(s=>s.kid===t),n&&this.jwks_cached_at+RF>i)return n;const{data:a,error:o}=await ne(this.fetch,"GET",`${this.url}/.well-known/jwks.json`,{headers:this.headers});if(o)throw o;return!a.keys||a.keys.length===0||(this.jwks=a,this.jwks_cached_at=i,n=a.keys.find(s=>s.kid===t),!n)?null:n}async getClaims(t,r={}){try{let n=t;if(!n){const{data:h,error:v}
290=await this.getSession();if(v||!h.session)return this._returnResult({data:null,error:v});n=h.session.access_token}const{header:i,payload:a,signature:o,raw:{header:s,payload:l}}=hd(n);r!=null&&r.allowExpired||rz(a.exp);const u=!i.alg||i.alg.startsWith("HS")||!i.kid||!("crypto"in globalThis&&"subtle"in globalThis.crypto)?null:await this.fetchJwk(i.kid,r!=null&&r.keys?{keys:r.keys}:r==null?void 0:r.jwks);if(!u){const{error:h}=await this.getUser(n);if(h)throw h;return{data:{claims:a,header:i,signature:o},error:null}}const d=nz(i.alg),c=await crypto.subtle.importKey("jwk",u,d,!0,["verify"]);if(!await crypto.subtle.verify(d,c,o,WF(`${s}.${l}`)))throw new ay("Invalid JWT signature");return{data:{claims:a,header:i,signature:o},error:null}}catch(n){if(J(n))return this._returnResult({data:null,error:n});throw n}}}Tu.nextInstanceID={};const Rz=Tu,Iz="2.97.0";let Ml="";typeof Deno<"u"?Ml="deno":typeof document<"u"?Ml="web":typeof navigator<"u"&&navigator.product==="ReactNative"?Ml="react-native":Ml="node";const Mz={"X-Client-Info":`supabase-js-${Ml}/${Iz}`},Dz={headers:Mz},Lz={schema:"public"},Bz={autoRefreshToken:!0,persistSession:!0,detectSessionInUrl:!0,flowType:"implicit"},Uz={};function Cu(e){"@babel/helpers - typeof";return Cu=typeof Symbol=="function"&&typeof Symbol.iterator=="symbol"?function(t){return typeof t}:function(t){return t&&typeof Symbol=="function"&&t.constructor===Symbol&&t!==Symbol.prototype?"symbol":typeof t},Cu(e)}function Fz(e,t){if(Cu(e)!="object"||!e)return e;var r=e[Symbol.toPrimitive];if(r!==void 0){var n=r.call(e,t||"default");if(Cu(n)!="object")return n;throw new TypeError("@@toPrimitive must return a primitive value.")}return(t==="string"?String:Number)(e)}function zz(e){var t=Fz(e,"string");return Cu(t)=="symbol"?t:t+""}function Wz(e,t,r){return(t=zz(t))in e?Object.defineProperty(e,t,{value:r,enumerable:!0,configurable:!0,writable:!0}):e[t]=r,e}function F_(e,t){var r=Object.keys(e);if(Object.getOwnPropertySymbols){var n=Object.getOwnPropertySymbols(e);t&&(n=n.filter(function(i){return Object.getOwnPropertyDescriptor(e,i).enumerable})),r.push.apply(r,n)}return r}function Xe(e){for(var t=1;t<arguments.length;t++){var r=arguments[t]!=null?arguments[t]:{};t%2?F_(Object(r),!0).forEach(function(n){Wz(e,n,r[n])}):Object.getOwnPropertyDescriptors?Object.defineProperties(e,Object.getOwnPropertyDescriptors(r)):F_(Object(r)).forEach(function(n){Object.defineProperty(e,n,Object.getOwnPropertyDescriptor(r,n))})}return e}const qz=e=>e?(...t)=>e(...t):(...t)=>fetch(...t),Hz=()=>Headers,Vz=(e,t,r)=>{const n=qz(r),i=Hz();return async(a,o)=>{var s;const l=(s=await t())!==null&&s!==void 0?s:e;let u=new i(o==null?void 0:o.headers);return u.has("apikey")||u.set("apikey",e),u.has("Authorization")||u.set("Authorization",`Bearer ${l}`),n(a,Xe(Xe({},o),{},{headers:u}))}};function Kz(e){return e.endsWith("/")?e:e+"/"}function Gz(e,t){var r,n;const{db:i,auth:a,realtime:o,global:s}=e,{db:l,auth:u,realtime:d,global:c}=t,f={db:Xe(Xe({},l),i),auth:Xe(Xe({},u),a),realtime:Xe(Xe({},d),o),storage:{},global:Xe(Xe(Xe({},c),s),{},{headers:Xe(Xe({},(r=c==null?void 0:c.headers)!==null&&r!==void 0?r:{}),(n=s==null?void 0:s.headers)!==null&&n!==void 0?n:{})}),accessToken:async()=>""};return e.accessToken?f.accessToken=e.accessToken:delete f.accessToken,f}function Yz(e){const t=e==null?void 0:e.trim();if(!t)throw new Error("supabaseUrl is required.");if(!t.match(/^https?:\/\//i))throw new Error("Invalid supabaseUrl: Must be a valid HTTP or HTTPS URL.");try{return new URL(Kz(t))}catch{throw Error("Invalid supabaseUrl: Provided URL is malformed.")}}var Xz=class extends Rz{constructor(e){super(e)}},Qz=class{constructor(e,t,r){var n,i;this.supabaseUrl=e,this.supabaseKey=t;const a=Yz(e);if(!t)throw new Error("supabaseKey is required.");this.realtimeUrl=new URL("realtime/v1",a),this.realtimeUrl.protocol=this.realtimeUrl.protocol.replace("http","ws"),this.authUrl=new URL("auth/v1",a),this.storageUrl=new URL("storage/v1",a),this.functionsUrl=new URL("functions/v1",a);const o=`sb-${a.hostname.split(".")[0]}-auth-token`,s={db:Lz,realtime:Uz,auth:Xe(Xe({},Bz),{},{storageKey:o}),global:Dz},l=Gz(r??{},s);if(this.storageKey=(n=l.auth.storageKey)!==null&&n!==void 0?n:"",this.headers=(i=l.global.headers)!==null&&i!==void 0?i:{},l.accessToken)this.accessToken=l.accessToken,this.auth=new Proxy({},{get:(d,c)=>{throw new Error(`@supabase/supabase-js: Supabase Client is configured with the accessToken option, accessing supabase.auth.${String(c)} is not possible`)}});else{var u;this.auth=this._initSupabaseAuthClient((u=l.auth)!==null&&u!==void 0?u:{},this.headers,l.global.fetch)}this.fetch=Vz(t,this._getAccessToken.bind(this),l.global.fetch),this.realtime=this._initRealtimeClient(Xe({headers:this.headers,accessToken:this._getAccessToken.bind(this)},l.realtime)),this.accessToken&&Promise.resolve(this.accessToken()).then(d=>this.realtime.setAuth(d)).catch(d=>console.warn("Failed to set initial Realtime auth token:",d)),this.rest=new MU(new URL("rest/v1",a).href,{headers:this.headers,schema:l.db.schema,fetch:this.fetch,timeout:l.db.timeout,urlLengthLimit:l.db.urlLengthLimit}),this.storage=new jF(this.storageUrl.href,this.headers,this.fetch,r==null?void 0:r.storage),l.accessToken||this._listenForAuthEvents()}get functions(){return new AU(this.functionsUrl.href,{headers:this.headers,customFetch:this.fetch})}from(e){return this.rest.from(e)}schema(e){return this.rest.schema(e)}rpc(e,t={},r={head:!1,get:!1,count:void 0}){return this.rest.rpc(e,t,r)}
290channel(e,t={config:{}}){return this.realtime.channel(e,t)}getChannels(){return this.realtime.getChannels()}removeChannel(e){return this.realtime.removeChannel(e)}removeAllChannels(){return this.realtime.removeAllChannels()}async _getAccessToken(){var e=this,t,r;if(e.accessToken)return await e.accessToken();const{data:n}=await e.auth.getSession();return(t=(r=n.session)===null||r===void 0?void 0:r.access_token)!==null&&t!==void 0?t:e.supabaseKey}_initSupabaseAuthClient({autoRefreshToken:e,persistSession:t,detectSessionInUrl:r,storage:n,userStorage:i,storageKey:a,flowType:o,lock:s,debug:l,throwOnError:u},d,c){const f={Authorization:`Bearer ${this.supabaseKey}`,apikey:`${this.supabaseKey}`};return new Xz({url:this.authUrl.href,headers:Xe(Xe({},f),d),storageKey:a,autoRefreshToken:e,persistSession:t,detectSessionInUrl:r,storage:n,userStorage:i,flowType:o,lock:s,debug:l,throwOnError:u,fetch:c,hasCustomAuthorizationHeader:Object.keys(this.headers).some(h=>h.toLowerCase()==="authorization")})}_initRealtimeClient(e){return new ZU(this.realtimeUrl.href,Xe(Xe({},e),{},{params:Xe(Xe({},{apikey:this.supabaseKey}),e==null?void 0:e.params)}))}_listenForAuthEvents(){return this.auth.onAuthStateChange((e,t)=>{this._handleTokenChanged(e,"CLIENT",t==null?void 0:t.access_token)})}_handleTokenChanged(e,t,r){(e==="TOKEN_REFRESHED"||e==="SIGNED_IN")&&this.changedAccessToken!==r?(this.changedAccessToken=r,this.realtime.setAuth(r)):e==="SIGNED_OUT"&&(this.realtime.setAuth(),t=="STORAGE"&&this.auth.signOut(),this.changedAccessToken=void 0)}};const Jz=(e,t,r)=>new Qz(e,t,r);function Zz(){if(typeof window<"u")return!1;const e=globalThis.process;if(!e)return!1;const t=e.version;if(t==null)return!1;const r=t.match(/^v(\d+)\./);return r?parseInt(r[1],10)<=18:!1}Zz()&&console.warn("â ï¸ Node.js 18 and below are deprecated and will no longer be supported in future versions of @supabase/supabase-js. Please upgrade to Node.js 20 or later. For more information, visit: https://github.com/orgs/supabase/discussions/37217");const e8="https://taxbtuaxnaczvpziaefd.supabase.co",t8="eyJhbGciOiJIUzI1NiIsInR5cCI6IkpXVCJ9.eyJpc3MiOiJzdXBhYmFzZSIsInJlZiI6InRheGJ0dWF4bmFjenZwemlhZWZkIiwicm9sZSI6ImFub24iLCJpYXQiOjE3NzE5NDcwMDAsImV4cCI6MjA4NzUyMzAwMH0.uRZ-YSCS1ZZuwBVbZHp5tamyhbFnfcAMsro-g15mkEg",te=Jz(e8,t8,{auth:{storage:localStorage,persistSession:!0,autoRefreshToken:!0}});function r8(){const[e,t]=O.useState(""),[r,n]=O.useState(""),[i,a]=O.useState(!1),[o,s]=O.useState(!1),l=ea(),{toast:u}=Zi();O.useEffect(()=>{te.auth.getSession().then(({data:{session:f}})=>{f&&l("/dashboard",{replace:!0})});const{data:{subscription:c}}=te.auth.onAuthStateChange((f,h)=>{h&&l("/dashboard",{replace:!0})});return()=>c.unsubscribe()},[l]);const d=async c=>{c.preventDefault(),s(!0);try{if(i){const{error:f}=await te.auth.resetPasswordForEmail(e,{redirectTo:`${window.location.origin}/reset-password`});if(f)throw f;u({title:"Ã
terställningslänk skickad!",description:"Kolla din inkorg för att återställa lösenordet."}),a(!1)}else{const{error:f}=await te.auth.signInWithPassword({email:e,password:r});if(f)throw f}}catch(f){u({title:"Fel",description:f.message,variant:"destructive"})}finally{s(!1)}};return p.jsxs("div",{className:"min-h-screen relative overflow-hidden flex items-center justify-center p-4",children:[p.jsx("div",{className:"absolute inset-0 pointer-events-none",style:{background:"linear-gradient(45deg, hsl(27 40% 57% / 0.15) 0%, hsl(27 35% 75% / 0.1) 40%, hsl(24 33% 94%) 100%)"}}),p.jsxs("div",{className:"relative w-full max-w-md animate-fade-in",children:[p.jsxs("div",{className:"flex items-center justify-center gap-3 mb-8",children:[p.jsx("div",{className:"h-10 w-10 rounded-xl bg-primary flex items-center justify-center",children:p.jsx(Tb,{className:"h-5 w-5 text-primary-foreground"})}),p.jsx("h1",{className:"font-display text-2xl font-bold tracking-tight",children:"Gap Analysis"})]}),p.jsxs(dr,{className:"border-border/50 shadow-lg",children:[p.jsxs(Zr,{className:"text-center",children:[p.jsx(en,{className:"font-display text-xl",children:i?"Glömt lösenord":"Välkommen tillbaka"}),p.jsx(Kb,{children:i?"Ange din e-post så skickar vi en återställningslänk":"Logga in på din hållbarhetsanalys"})]}),p.jsxs(fr,{children:[p.jsxs("form",{onSubmit:d,className:"space-y-4",children:[p.jsxs("div",{className:"space-y-2",children:[p.jsx("label",{className:"text-sm font-medium",children:"E-post"}),p.jsx(Kt,{type:"email",placeholder:"[email protected]",value:e,onCh
290ange:c=>t(c.target.value),required:!0})]}),!i&&p.jsxs("div",{className:"space-y-2",children:[p.jsx("label",{className:"text-sm font-medium",children:"Lösenord"}),p.jsx(Kt,{type:"password",placeholder:"â¢â¢â¢â¢â¢â¢â¢â¢",value:r,onChange:c=>n(c.target.value),required:!0,minLength:6})]}),p.jsxs(je,{type:"submit",className:"w-full font-semibold",disabled:o,children:[o&&p.jsx(Rt,{className:"h-4 w-4 animate-spin mr-2"}),i?"Skicka Ã¥terställningslänk":"Logga in"]})]}),!i&&p.jsx("button",{type:"button",onClick:()=>a(!0),className:"text-sm text-primary hover:underline font-medium w-full text-center mt-3 block",children:"Glömt lösenord?"}),i&&p.jsx("p",{className:"text-sm text-muted-foreground text-center mt-4",children:p.jsx("button",{type:"button",onClick:()=>a(!1),className:"text-primary hover:underline font-medium",children:"Tillbaka till inloggning"})})]})]})]})]})}function Xb(){const[e,t]=O.useState(!1),[r,n]=O.useState(!0);return O.useEffect(()=>{(async()=>{const{data:{session:a}}=await te.auth.getSession();if(!a){n(!1);return}const{data:o}=await te.from("user_roles").select("role").eq("user_id",a.user.id).eq("role","admin").maybeSingle();t(!!o),n(!1)})()},[]),{isAdmin:e,loading:r}}function mC({score:e,classification:t}){const r=e/100*180-90,n={risk:"Greenwashing-risk",balanced:"Balanserad",opportunity:"Missad kommunikationsmöjlighet"}[t],i={risk:"text-destructive",balanced:"text-primary",opportunity:"text-foreground"}[t];return p.jsxs("div",{className:"flex flex-col items-center gap-4",children:[p.jsx("div",{className:"relative w-64 h-40 overflow-hidden",children:p.jsx("div",{className:"absolute inset-0",children:p.jsxs("svg",{viewBox:"0 0 200 125",className:"w-full h-full",children:[p.jsx("defs",{children:p.jsxs("linearGradient",{id:"gaugeGradient",x1:"0%",y1:"0%",x2:"100%",y2:"0%",children:[p.jsx("stop",{offset:"0%",stopColor:"hsl(var(--destructive))"}),p.jsx("stop",{offset:"35%",stopColor:"hsl(var(--warning))"}),p.jsx("stop",{offset:"50%",stopColor:"hsl(var(--primary))"}),p.jsx("stop",{offset:"75%",stopColor:"hsl(var(--warning))"}),p.jsx("stop",{offset:"100%",stopColor:"hsl(var(--chart-amber))"})]})}),p.jsx("path",{d:"M 20 100 A 80 80 0 0 1 180 100",fill:"none",stroke:"hsl(var(--muted))",strokeWidth:"12",strokeLinecap:"round"}),p.jsx("path",{d:"M 20 100 A 80 80 0 0 1 180 100",fill:"none",stroke:"url(#gaugeGradient)",strokeWidth:"12",strokeLinecap:"round",opacity:"0.8"}),p.jsx("line",{x1:"100",y1:"100",x2:"100",y2:"30",stroke:"hsl(var(--foreground))",strokeWidth:"3",strokeLinecap:"round",transform:`rotate(${r}, 100, 100)`,className:"transition-transform duration-1000 ease-out"}
vendor: 6,231 bytes, line 290
290),p.jsx("circle",{cx:"100",cy:"100",r:"6",fill:"hsl(var(--foreground))"}),p.jsx("text",{x:"10",y:"118",className:"fill-muted-foreground text-[8px]",fontFamily:"Inter",children:"Greenwashing"}),p.jsx("text",{x:"148",y:"118",className:"fill-muted-foreground text-[8px]",fontFamily:"Inter",children:"Greenhushing"})]})})}),p.jsx("div",{className:"text-center -mt-2",children:p.jsx("div",{className:Ne("text-sm font-semibold mt-1 uppercase tracking-wider",i),children:n})})]})}function n8({summary:e}){return p.jsxs(dr,{className:"border-border/50 bg-white",children:[p.jsx(Zr,{className:"pb-3",children:p.jsx(en,{className:"font-display text-lg",children:"Sammanfattning"})}),p.jsx(fr,{children:p.jsx("p",{className:"text-base leading-relaxed text-muted-foreground",children:e})})]})}var i8=Array.isArray,Jt=i8,a8=typeof Lc=="object"&&Lc&&Lc.Object===Object&&Lc,vC=a8,o8=vC,s8=typeof self=="object"&&self&&self.Object===Object&&self,l8=o8||s8||Function("return this")(),Nn=l8,u8=Nn,c8=u8.Symbol,Pc=c8,z_=Pc,gC=Object.prototype,d8=gC.hasOwnProperty,f8=gC.toString,_l=z_?z_.toStringTag:void 0;function h8(e){var t=d8.call(e,_l),r=e[_l];try{e[_l]=void 0;var n=!0}catch{}var i=f8.call(e);return n&&(t?e[_l]=r:delete e[_l]),i}var p8=h8,m8=Object.prototype,v8=m8.toString;function g8(e){return v8.call(e)}var y8=g8,W_=Pc,b8=p8,w8=y8,x8="[object Null]",_8="[object Undefined]",q_=W_?W_.toStringTag:void 0;function S8(e){return e==null?e===void 0?_8:x8:q_&&q_ in Object(e)?b8(e):w8(e)}var oi=S8;function O8(e){return e!=null&&typeof e=="object"}var si=O8,E8=oi,k8=si,P8="[object Symbol]";function A8(e){return typeof e=="symbol"||k8(e)&&E8(e)==P8}var Zs=A8,j8=Jt,T8=Zs,C8=/\.|\[(?:[^[\]]*|(["'])(?:(?!\1)[^\\]|\\.)*?\1)\]/,N8=/^\w*$/;function $8(e,t){if(j8(e))return!1;var r=typeof e;return r=="number"||r=="symbol"||r=="boolean"||e==null||T8(e)?!0:N8.test(e)||!C8.test(e)||t!=null&&e in Object(t)}var Qb=$8;function R8(e){var t=typeof e;return e!=null&&(t=="object"||t=="function")}var ta=R8;const el=Ce(ta);var I8=oi,M8=ta,D8="[object AsyncFunction]",L8="[object Function]",B8="[object GeneratorFunction]",U8="[object Proxy]";function F8(e){if(!M8(e))return!1;var t=I8(e);return t==L8||t==B8||t==D8||t==U8}var Jb=F8;const fe=Ce(Jb);var z8=Nn,W8=z8["__core-js_shared__"],q8=W8,nv=q8,H_=function(){var e=/[^.]+$/.exec(nv&&nv.keys&&nv.keys.IE_PROTO||"");return e?"Symbol(src)_1."+e:""}();function H8(e){return!!H_&&H_ in e}var V8=H8,K8=Function.prototype,G8=K8.toString;function Y8(e){if(e!=null){try{return G8.call(e)}catch{}try{return e+""}catch{}}return""}var yC=Y8,X8=Jb,Q8=V8,J8=ta,Z8=yC,e6=/[\\^$.*+?()[\]{}|]/g,t6=/^\[object .+?Constructor\]$/,r6=Function.prototype,n6=Object.prototype,i6=r6.toString,a6=n6.hasOwnProperty,o6=RegExp("^"+i6.call(a6).replace(e6,"\\$&").replace(/hasOwnProperty|(function).*?(?=\\\()| for .+?(?=\\\])/g,"$1.*?")+"$");function s6(e){if(!J8(e)||Q8(e))return!1;var t=X8(e)?o6:t6;return t.test(Z8(e))}var l6=s6;function u6(e,t){return e==null?void 0:e[t]}var c6=u6,d6=l6,f6=c6;function h6(e,t){var r=f6(e,t);return d6(r)?r:void 0}var ro=h6,p6=ro,m6=p6(Object,"create"),vp=m6,V_=vp;function v6(){this.__data__=V_?V_(null):{},this.size=0}var g6=v6;function y6(e){var t=this.has(e)&&delete this.__data__[e];return this.size-=t?1:0,t}var b6=y6,w6=vp,x6="__lodash_hash_undefined__",_6=Object.prototype,S6=_6.hasOwnProperty;function O6(e){var t=this.__data__;if(w6){var r=t[e];return r===x6?void 0:r}return S6.call(t,e)?t[e]:void 0}var E6=O6,k6=vp,P6=Object.prototype,A6=P6.hasOwnProperty;function j6(e){var t=this.__data__;return k6?t[e]!==void 0:A6.call(t,e)}var T6=j6,C6=vp,N6="__lodash_hash_undefined__";function $6(e,t){var r=this.__data__;return this.size+=this.has(e)?0:1,r[e]=C6&&t===void 0?N6:t,this}var R6=$6,I6=g6,M6=b6,D6=E6,L6=T6,B6=R6;function tl(e){var t=-1,r=e==null?0:e.length;for(this.clear();++t<r;){var n=e[t];this.set(n[0],n[1])}}tl.prototype.clear=I6;tl.prototype.delete=M6;tl.prototype.get=D6;tl.prototype.has=L6;tl.prototype.set=B6;var U6=tl;function F6(){this.__data__=[],this.size=0}var z6=F6;function W6(e,t){return e===t||e!==e&&t!==t}var Zb=W6,q6=Zb;function H6(e,t){for(var r=e.length;r--;)if(q6(e[r][0],t))return r;return-1}var gp=H6,V6=gp,K6=Array.prototype,G6=K6.splice;function Y6(e){var t=this.__data__,r=V6(t,e);if(r<0)return!1;var n=t.length-1;return r==n?t.pop():G6.call(t,r,1),--this.size,!0}var X6=Y6,Q6=gp;function J6(e){var t=this.__data__,r=Q6(t,e);return r<0?void 0:t[r][1]}var Z6=J6,eW=gp;function tW(e){return eW(this.__data__,e)>-1}var rW=tW,nW=gp;function iW(e,t){var r=this.__data__,n=nW(r,e);return n<0?(++this.size,r.push([e,t])):r[n][1]=t,this}var aW=iW,oW=z6,sW=X6,lW=Z6,uW=rW,cW=aW;function rl(e){var t=-1,r=e==null?0:e.length;for(this.clear();++t<r;){var n=e[t];this.set(n[0],n[1])}}rl.prototype.clear=oW;rl.prototype.delete=sW;rl.prototype.get=lW;rl.prototype.has=uW;rl.prototype.set=cW;var yp=rl,dW=ro,fW=Nn,hW=dW(fW,"Map"),ew=hW,K_=U6,pW=yp,mW=ew;function vW(){this.size=0,this.__data__={hash:new K_,map:new(mW||pW),string:new K_}}var gW=vW;function yW(e){var t=typeof e;return t=="string"||t=="number"||t=="symbol"||t=="boolean"?e!=="__proto__":e===null}var bW=yW,wW=bW;function xW(e,t){var r=e.__data__;return wW(t)?r[typeof t=="string"?"string":"hash"]:r.map}var bp=xW,_W=bp;function SW(e){var t=_W(this,e).delete(e);return this.size-=t?1:0,t}var OW=SW,EW=bp;function kW(e){return EW(this,e).get(e)}var PW=kW,AW=bp;function jW(e){return AW(this,e).has(e)}var TW=jW,CW=bp;function NW(e,t){var r=CW(this,e),n=r.size;return r.set(e,t),this.size+=r.size==n?0:1,this}var $W=NW,RW=gW,IW=OW,MW=PW,DW=TW,LW=$W;function nl(e){var t=-1,r=e==null?0:e.length;for(this.clear();++t<r;){var n=e[t];this.set(n[0],n[1])}}nl.prototype.clear=RW;nl.prototype.delete=IW;nl.prototype.get=MW;nl.prototype.has=DW;nl.prototype.set=LW;var tw=nl,bC=tw,BW="Expected a function";function rw(e,t){if(typeof e!="function"||t!=null&&typeof t!="function")throw new TypeError(BW);var r=function(){var n=arguments,i=t?t.apply(this,n):n[0],a=r.cache;if(a.has(i))return a.get(i);var o=e.apply(this,n);return r.cache=a.set(i,o)||a,o};return r.cache=new(rw.Cache||bC),r}rw.Cache=bC;var wC=rw;const UW=Ce(wC);var FW=wC,zW=500;function WW(e){var t=FW(e,function(n){return r.size===zW&&r.clear(),n}
vendor: 6,644 bytes, lines 290-298
290),r=t.cache;return t}var qW=WW,HW=qW,VW=/[^.[\]]+|\[(?:(-?\d+(?:\.\d+)?)|(["'])((?:(?!\2)[^\\]|\\.)*?)\2)\]|(?=(?:\.|\[\])(?:\.|\[\]|$))/g,KW=/\\(\\)?/g,GW=HW(function(e){var t=[];return e.charCodeAt(0)===46&&t.push(""),e.replace(VW,function(r,n,i,a){t.push(i?a.replace(KW,"$1"):n||r)}),t}),YW=GW;function XW(e,t){for(var r=-1,n=e==null?0:e.length,i=Array(n);++r<n;)i[r]=t(e[r],r,e);return i}var nw=XW,G_=Pc,QW=nw,JW=Jt,ZW=Zs,eq=1/0,Y_=G_?G_.prototype:void 0,X_=Y_?Y_.toString:void 0;function xC(e){if(typeof e=="string")return e;if(JW(e))return QW(e,xC)+"";if(ZW(e))return X_?X_.call(e):"";var t=e+"";return t=="0"&&1/e==-eq?"-0":t}var tq=xC,rq=tq;function nq(e){return e==null?"":rq(e)}var _C=nq,iq=Jt,aq=Qb,oq=YW,sq=_C;function lq(e,t){return iq(e)?e:aq(e,t)?[e]:oq(sq(e))}var SC=lq,uq=Zs,cq=1/0;function dq(e){if(typeof e=="string"||uq(e))return e;var t=e+"";return t=="0"&&1/e==-cq?"-0":t}var wp=dq,fq=SC,hq=wp;function pq(e,t){t=fq(t,e);for(var r=0,n=t.length;e!=null&&r<n;)e=e[hq(t[r++])];return r&&r==n?e:void 0}var iw=pq,mq=iw;function vq(e,t,r){var n=e==null?void 0:mq(e,t);return n===void 0?r:n}var OC=vq;const kr=Ce(OC);function gq(e){return e==null}var yq=gq;const we=Ce(yq);var bq=oi,wq=Jt,xq=si,_q="[object String]";function Sq(e){return typeof e=="string"||!wq(e)&&xq(e)&&bq(e)==_q}var Oq=Sq;const Ka=Ce(Oq);var EC={exports:{}},ke={};/** 291 * @license React 292 * react-is.production.min.js 293 * 294 * Copyright (c) Facebook, Inc. and its affiliates. 295 * 296 * This source code is licensed under the MIT license found in the 297 * LICENSE file in the root directory of this source tree. 298 */var aw=Symbol.for("react.element"),ow=Symbol.for("react.portal"),xp=Symbol.for("react.fragment"),_p=Symbol.for("react.strict_mode"),Sp=Symbol.for("react.profiler"),Op=Symbol.for("react.provider"),Ep=Symbol.for("react.context"),Eq=Symbol.for("react.server_context"),kp=Symbol.for("react.forward_ref"),Pp=Symbol.for("react.suspense"),Ap=Symbol.for("react.suspense_list"),jp=Symbol.for("react.memo"),Tp=Symbol.for("react.lazy"),kq=Symbol.for("react.offscreen"),kC;kC=Symbol.for("react.module.reference");function Tr(e){if(typeof e=="object"&&e!==null){var t=e.$$typeof;switch(t){case aw:switch(e=e.type,e){case xp:case Sp:case _p:case Pp:case Ap:return e;default:switch(e=e&&e.$$typeof,e){case Eq:case Ep:case kp:case Tp:case jp:case Op:return e;default:return t}}case ow:return t}}}ke.ContextConsumer=Ep;ke.ContextProvider=Op;ke.Element=aw;ke.ForwardRef=kp;ke.Fragment=xp;ke.Lazy=Tp;ke.Memo=jp;ke.Portal=ow;ke.Profiler=Sp;ke.StrictMode=_p;ke.Suspense=Pp;ke.SuspenseList=Ap;ke.isAsyncMode=function(){return!1};ke.isConcurrentMode=function(){return!1};ke.isContextConsumer=function(e){return Tr(e)===Ep};ke.isContextProvider=function(e){return Tr(e)===Op};ke.isElement=function(e){return typeof e=="object"&&e!==null&&e.$$typeof===aw};ke.isForwardRef=function(e){return Tr(e)===kp};ke.isFragment=function(e){return Tr(e)===xp};ke.isLazy=function(e){return Tr(e)===Tp};ke.isMemo=function(e){return Tr(e)===jp};ke.isPortal=function(e){return Tr(e)===ow};ke.isProfiler=function(e){return Tr(e)===Sp};ke.isStrictMode=function(e){return Tr(e)===_p};ke.isSuspense=function(e){return Tr(e)===Pp};ke.isSuspenseList=function(e){return Tr(e)===Ap};ke.isValidElementType=function(e){return typeof e=="string"||typeof e=="function"||e===xp||e===Sp||e===_p||e===Pp||e===Ap||e===kq||typeof e=="object"&&e!==null&&(e.$$typeof===Tp||e.$$typeof===jp||e.$$typeof===Op||e.$$typeof===Ep||e.$$typeof===kp||e.$$typeof===kC||e.getModuleId!==void 0)};ke.typeOf=Tr;EC.exports=ke;var Pq=EC.exports,Aq=oi,jq=si,Tq="[object Number]";function Cq(e){return typeof e=="number"||jq(e)&&Aq(e)==Tq}var PC=Cq;const Nq=Ce(PC);var $q=PC;function Rq(e){return $q(e)&&e!=+e}var Iq=Rq;const Ac=Ce(Iq);var Xr=function(t){return t===0?0:t>0?1:-1},Sa=function(t){return Ka(t)&&t.indexOf("%")===t.length-1},Y=function(t){return Nq(t)&&!Ac(t)},Mq=function(t){return we(t)},ct=function(t){return Y(t)||Ka(t)},Dq=0,Cp=function(t){var r=++Dq;return"".concat(t||"").concat(r)},Ga=function(t,r){var n=arguments.length>2&&arguments[2]!==void 0?arguments[2]:0,i=arguments.length>3&&arguments[3]!==void 0?arguments[3]:!1;if(!Y(t)&&!Ka(t))return n;var a;if(Sa(t)){var o=t.indexOf("%");a=r*parseFloat(t.slice(0,o))/100}else a=+t;return Ac(a)&&(a=n),i&&a>r&&(a=r),a},ko=function(t){if(!t)return null;var r=Object.keys(t);return r&&r.length?t[r[0]]:null},Lq=function(t){if(!Array.isArray(t))return!1;for(var r=t.length,n={},i=0;i<r;i++)if(!n[t[i]])n[t[i]]=!0;else return!0;return!1},go=function(t,r){return Y(t)&&Y(r)?function(n){return t+n*(r-t)}:function(){return r}};function oy(e,t,r){return!e||!e.length?null:e.find(function(n){return n&&(typeof t=="function"?t(n):kr(n,t))===r})}var Bq=function(t,r){return Y(t)&&Y(r)?t-r:Ka(t)&&Ka(r)?t.localeCompare(r):t instanceof Date&&r instanceof Date?t.getTime()-r.getTime():String(t).localeCompare(String(r))};function Jo(e,t){for(var r in e)if({}.hasOwnProperty.call(e,r)&&(!{}.hasOwnProperty.call(t,r)||e[r]!==t[r]))return!1;for(var n in t)if({}.hasOwnProperty.call(t,n)&&!{}.hasOwnProperty.call(e,n))return!1;return!0}function sy(e){"@babel/helpers - typeof";return sy=typeof Symbol=="function"&&typeof Symbol.iterator=="symbol"?function(t){return typeof t}:function(t){return t&&typeof Symbol=="function"&&t.constructor===Symbol&&t!==Symbol.prototype?"symbol":typeof t},sy(e)}var Uq=["viewBox","children"],Fq=["aria-activedescendant","aria-atomic","aria-autocomplete","aria-busy","aria-checked","aria-colcount","aria-colindex","aria-colspan","aria-controls","aria-current","aria-describedby","aria-details","aria-disabled","aria-errormessage","aria-expanded","aria-flowto","aria-haspopup","aria-hidden","aria-invalid","aria-keyshortcuts","aria-label","aria-labelledby","aria-level","aria-live","aria-modal","aria-multiline","aria-multiselectable","aria-orientation","aria-owns","aria-placeholder","aria-posinset","aria-pressed","aria-readonly","aria-relevant","aria-required","aria-roledescription","aria-rowcount","aria-rowindex","aria-rowspan","aria-selected","aria-setsize","aria-sort","aria-valuemax","aria-valuemin","aria-valuenow","aria-valuetext","className","color","height","id","lang","max","media","method","min","name","style","target","width","role","tabIndex","accentHeight","accumulate","additive","alignmentBaseline","allowReorder","alphabetic","amplitude","arabicForm","ascent","attributeName","attributeType","autoReverse","azimuth","baseFrequency","baselineShift","baseProfile","bbox","begin","bias","by","calcMode","capHeight","clip","clipPath","clipPathUnits","clipRule","colorInterpolation","colorInterpolationFilters","colorProfile","colorRen
298dering","contentScriptType","contentStyleType","cursor","cx","cy","d","decelerate","descent","diffuseConstant","direction","display","divisor","dominantBaseline","dur","dx","dy","edgeMode","elevation","enableBackground","end","exponent","externalResourcesRequired","fill","fillOpacity","fillRule","filter","filterRes","filterUnits","floodColor","floodOpacity","focusable","fontFamily","fontSize","fontSizeAdjust","fontStretch","fontStyle","fontVariant","fontWeight","format","from","fx","fy","g1","g2","glyphName","glyphOrientationHorizontal","glyphOrientationVertical","glyphRef","gradientTransform","gradientUnits","hanging","horizAdvX","horizOriginX","href","ideographic","imageRendering","in2","in","intercept","k1","k2","k3","k4","k","kernelMatrix","kernelUnitLength","kerning","keyPoints","keySplines","keyTimes","lengthAdjust","letterSpacing","lightingColor","limitingConeAngle","local","markerEnd","markerHeight","markerMid","markerStart","markerUnits","markerWidth","mask","maskContentUnits","maskUnits","mathematical","mode","numOctaves","offset","opacity","operator","order","orient","orientation","origin","overflow","overlinePosition","overlineThickness","paintOrder","panose1","pathLength","patternContentUnits","patternTransform","patternUnits","pointerEvents","pointsAtX","pointsAtY","pointsAtZ","preserveAlpha","preserveAspectRatio","primitiveUnits","r","radius","refX","refY","renderingIntent","repeatCount","repeatDur","requiredExtensions","requiredFeatures","restart","result","rotate","rx","ry","seed","shapeRendering","slope","spacing","specularConstant","specularExponent","speed","spreadMethod","startOffset","stdDeviation","stemh","stemv","stitchTiles","stopColor","stopOpacity","strikethroughPosition","strikethroughThickness","string","stroke","strokeDasharray","strokeDashoffset","strokeLinecap","strokeLinejoin","strokeMiterlimit","strokeOpacity","strokeWidth","surfaceScale","systemLanguage","tableValues","targetX","targetY","textAnchor","textDecoration","textLength","textRendering","to","transform","u1","u2","underlinePosition","underlineThickness","unicode","unicodeBidi","unicodeRange","unitsPerEm","vAlphabetic","values","vectorEffect","version","vertAdvY","vertOriginX","vertOriginY","vHanging","vIdeographic","viewTarget","visibility","vMathematical","widths","wordSpacing","writingMode","x1","x2","x","xChannelSelector","xHeight","xlinkActuate","xlinkArcrole","xlinkHref","xlinkRole","xlinkShow","xlinkTitle","xlinkType","xmlBase","xmlLang","xmlns","xmlnsXlink","xmlSpace","y1","y2","y","yChannelSelector","z","zoomAndPan","ref","key","angle"],Q_=["points","pathLength"],iv={svg:Uq,polygon:Q_,polyline:Q_},sw=["dangerouslySetInnerHTML","onCopy","onCopyCapture","onCut","onCutCapture","onPaste","onPasteCapture","onCompositionEnd","onCompositionEndCapture","onCompositionStart","onCompositionStartCapture","onCompositionUpdate","onCompositionUpdateCapture","onFocus","onFocusCapture","onBlur","onBlurCapture","onChange","onChangeCapture","onBeforeInput","onBeforeInputCapture","onInput","onInputCapture","onReset","onResetCapture","onSubmit","onSubmitCapture","onInvalid","onInvalidCapture","onLoad","onLoadCapture","onError","onErrorCapture","onKeyDown","onKeyDownCapture","onKeyPress","onKeyPressCapture","onKeyUp","onKeyUpCapture","onAbort","onAbortCapture","onCanPlay","onCanPlayCapture","onCanPlayThrough","onCanPlayThroughCapture","onDurationChange","onDurationChangeCapture","onEmptied","onEmptiedCapture","onEncrypted","onEncryptedCapture","onEnded","onEndedCapture","onLoadedData","onLoadedDataCapture","onLoadedMetadata","onLoadedMetadataCapture","onLoadStart","onLoadStartCapture","onPause","onPauseCapture","onPlay","onPlayCapture","onPlaying","onPlayingCapture","onProgress","onProgressCapture","onRateChange","onRateChangeCapture","onSeeked","onSeekedCapture","onSeeking","onSeekingCapture","onStalled","onStalledCapture","onSuspend","onSuspendCapture","onTimeUpdate","onTimeUpdateCapture","onVolumeChange","onVolumeChangeCapture","onWaiting","onWaitingCapture","onAuxClick","onAuxClickCapture","onClick","onClickCapture","onContextMenu","onContextMenuCapture","onDoubleClick","onDoubleClickCapture","onDrag","onDrag
298Capture","onDragEnd","onDragEndCapture","onDragEnter","onDragEnterCapture","onDragExit","onDragExitCapture","onDragLeave","onDragLeaveCapture","onDragOver","onDragOverCapture","onDragStart","onDragStartCapture","onDrop","onDropCapture","onMouseDown","onMouseDownCapture","onMouseEnter","onMouseLeave","onMouseMove","onMouseMoveCapture","onMouseOut","onMouseOutCapture","onMouseOver","onMouseOverCapture","onMouseUp","onMouseUpCapture","onSelect","onSelectCapture","onTouchCancel","onTouchCancelCapture","onTouchEnd","onTouchEndCapture","onTouchMove","onTouchMoveCapture","onTouchStart","onTouchStartCapture","onPointerDown","onPointerDownCapture","onPointerMove","onPointerMoveCapture","onPointerUp","onPointerUpCapture","onPointerCancel","onPointerCancelCapture","onPointerEnter","onPointerEnterCapture","onPointerLeave","onPointerLeaveCapture","onPointerOver","onPointerOverCapture","onPointerOut","onPointerOutCapture","onGotPointerCapture","onGotPointerCaptureCapture","onLostPointerCapture","onLostPointerCaptureCapture","onScroll","onScrollCapture","onWheel","onWheelCapture","onAnimationStart","onAnimationStartCapture","onAnimationEnd","onAnimationEndCapture","onAnimationIteration","onAnimationIterationCapture","onTransitionEnd","onTransitionEndCapture"],Nf=function(t,r){if(!t||typeof t=="function"||typeof t=="boolean")return null;var n=t;if(O.isValidElement(t)&&(n=t.props),!el(n))return null;var i={};return Object.keys(n).forEach(function(a){sw.includes(a)&&(i[a]=r||function(o){return n[a](n,o)})}),i},zq=function(t,r,n){return function(i){return t(r,n,i),null}},$f=function(t,r,n){if(!el(t)||sy(t)!=="object")return null;var i=null;return Object.keys(t).forEach(function(a){var o=t[a];sw.includes(a)&&typeof o=="function"&&(i||(i={}),i[a]=zq(o,r,n))}),i},Wq=["children"],qq=["children"];function J_(e,t){if(e==null)return{};var r=Hq(e,t),n,i;if(Object.getOwnPropertySymbols){var a=Object.getOwnPropertySymbols(e);for(i=0;i<a.length;i++)n=a[i],!(t.indexOf(n)>=0)&&Object.prototype.propertyIsEnumerable.call(e,n)&&(r[n]=e[n])}return r}function Hq(e,t){if(e==null)return{};var r={};for(var n in e)if(Object.prototype.hasOwnProperty.call(e,n)){if(t.indexOf(n)>=0)continue;r[n]=e[n]}return r}var Z_={click:"onClick",mousedown:"onMouseDown",mouseup:"onMouseUp",mouseover:"onMouseOver",mousemove:"onMouseMove",mouseout:"onMouseOut",mouseenter:"onMouseEnter",mouseleave:"onMouseLeave",touchcancel:"onTouchCancel",touchend:"onTouchEnd",touchmove:"onTouchMove",touchstart:"onTouchStart",contextmenu:"onContextMenu",dblclick:"onDoubleClick"},Hn=function(t){return typeof t=="string"?t:t?t.displayName||t.name||"Component":""},eS=null,av=null,lw=function e(t){if(t===eS&&Array.isArray(av))return av;var r=[];return O.Children.forEach(t,function(n){we(n)||(Pq.isFragment(n)?r=r.concat(e(n.props.children)):r.push(n))}),av=r,eS=t,r};function tn(e,t){var r=[],n=[];return Array.isArray(t)?n=t.map(function(i){return Hn(i)}):n=[Hn(t)],lw(e).forEach(function(i){var a=kr(i,"type.displayName")||kr(i,"type.name");n.indexOf(a)!==-1&&r.push(i)}),r}function ir(e,t){var r=tn(e,t);return r&&r[0]}var tS=function(t){if(!t||!t.props)return!1;var r=t.props,n=r.width,i=r.height;return!(!Y(n)||n<=0||!Y(i)||i<=0)},Vq=["a","altGlyph","altGlyphDef","altGlyphItem","animate","animateColor","animateMotion","animateTransform","circle","clipPath","color-profile","cursor","defs","desc","ellipse","feBlend","feColormatrix","feComponentTransfer","feComposite","feConvolveMatrix","feDiffuseLighting","feDisplacementMap","feDistantLight","feFlood","feFuncA","feFuncB","feFuncG","feFuncR","feGaussianBlur","feImage","feMerge","feMergeNode","feMorphology","feOffset","fePointLight","feSpecularLighting","feSpotLight","feTile","feTurbulence","filter","font","font-face","font-face-format","font-face-name","font-face-url","foreignObject","g","glyph","glyphRef","hkern","image","line","lineGradient","marker","mask","metadata","missing-glyph","mpath","path","pattern","polygon","polyline","radialGradient","rect","script","set","stop","style","svg","switch","symbol","text","textPath","title","tref","tspan","use","view","vkern"],Kq=function(t){return t&&t.type&&Ka(t.type)&&Vq.indexOf(t.type)>=0},Gq=function(t,r,n,i){var a,o=(a=iv==null?void 0:iv[i])!==null&&a!==void 0?a:[];return r.startsWith("data-")||!fe(t)&&(i&&o.includes(r)||Fq.includes(r))||n&&sw.includes(r)},Se=function(t,r,n){if(!t||typeof t=="function"||typeof t=="boolean")return null;var i=t;if(O.isValidElement(t)&&(i=t.props),!el(i))return null;var a={};
298return Object.keys(i).forEach(function(o){var s;Gq((s=i)===null||s===void 0?void 0:s[o],o,r,n)&&(a[o]=i[o])}),a},ly=function e(t,r){if(t===r)return!0;var n=O.Children.count(t);if(n!==O.Children.count(r))return!1;if(n===0)return!0;if(n===1)return rS(Array.isArray(t)?t[0]:t,Array.isArray(r)?r[0]:r);for(var i=0;i<n;i++){var a=t[i],o=r[i];if(Array.isArray(a)||Array.isArray(o)){if(!e(a,o))return!1}else if(!rS(a,o))return!1}return!0},rS=function(t,r){if(we(t)&&we(r))return!0;if(!we(t)&&!we(r)){var n=t.props||{},i=n.children,a=J_(n,Wq),o=r.props||{},s=o.children,l=J_(o,qq);return i&&s?Jo(a,l)&&ly(i,s):!i&&!s?Jo(a,l):!1}return!1},nS=function(t,r){var n=[],i={};return lw(t).forEach(function(a,o){if(Kq(a))n.push(a);else if(a){var s=Hn(a.type),l=r[s]||{},u=l.handler,d=l.once;if(u&&(!d||!i[s])){var c=u(a,s,o);n.push(c),i[s]=!0}}}),n},Yq=function(t){var r=t&&t.type;return r&&Z_[r]?Z_[r]:null},Xq=function(t,r){return lw(r).indexOf(t)},Qq=["children","width","height","viewBox","className","style","title","desc"];function uy(){return uy=Object.assign?Object.assign.bind():function(e){for(var t=1;t<arguments.length;t++){var r=arguments[t];for(var n in r)Object.prototype.hasOwnProperty.call(r,n)&&(e[n]=r[n])}return e},uy.apply(this,arguments)}function Jq(e,t){if(e==null)return{};var r=Zq(e,t),n,i;if(Object.getOwnPropertySymbols){var a=Object.getOwnPropertySymbols(e);for(i=0;i<a.length;i++)n=a[i],!(t.indexOf(n)>=0)&&Object.prototype.propertyIsEnumerable.call(e,n)&&(r[n]=e[n])}return r}function Zq(e,t){if(e==null)return{};var r={};for(var n in e)if(Object.prototype.hasOwnProperty.call(e,n)){if(t.indexOf(n)>=0)continue;r[n]=e[n]}return r}function cy(e){var t=e.children,r=e.width,n=e.height,i=e.viewBox,a=e.className,o=e.style,s=e.title,l=e.desc,u=Jq(e,Qq),d=i||{width:r,height:n,x:0,y:0},c=pe("recharts-surface",a);return j.createElement("svg",uy({},Se(u,!0,"svg"),{className:c,width:r,height:n,style:o,viewBox:"".concat(d.x," ").concat(d.y," ").concat(d.width," ").concat(d.height)}),j.createElement("title",null,s),j.createElement("desc",null,l),t)}var eH=["children","className"];function dy(){return dy=Object.assign?Object.assign.bind():function(e){for(var t=1;t<arguments.length;t++){var r=arguments[t];for(var n in r)Object.prototype.hasOwnProperty.call(r,n)&&(e[n]=r[n])}return e},dy.apply(this,arguments)}function tH(e,t){if(e==null)return{};var r=rH(e,t),n,i;if(Object.getOwnPropertySymbols){var a=Object.getOwnPropertySymbols(e);for(i=0;i<a.length;i++)n=a[i],!(t.indexOf(n)>=0)&&Object.prototype.propertyIsEnumerable.call(e,n)&&(r[n]=e[n])}return r}function rH(e,t){if(e==null)return{};var r={};for(var n in e)if(Object.prototype.hasOwnProperty.call(e,n)){if(t.indexOf(n)>=0)continue;r[n]=e[n]}return r}var gt=j.forwardRef(function(e,t){var r=e.children,n=e.className,i=tH(e,eH),a=pe("recharts-layer",n);return j.createElement("g",dy({className:a},Se(i,!0),{ref:t}),r)}),Da=function(t,r){for(var n=arguments.length,i=new Array(n>2?n-2:0),a=2;a<n;a++)i[a-2]=arguments[a]};function nH(e,t,r){var n=-1,i=e.length;t<0&&(t=-t>i?0:i+t),r=r>i?i:r,r<0&&(r+=i),i=t>r?0:r-t>>>0,t>>>=0;for(var a=Array(i);++n<i;)a[n]=e[n+t];return a}var iH=nH,aH=iH;function oH(e,t,r){var n=e.length;return r=r===void 0?n:r,!t&&r>=n?e:aH(e,t,r)}var sH=oH,lH="\\ud800-\\udfff",uH="\\u0300-\\u036f",cH="\\ufe20-\\ufe2f",dH="\\u20d0-\\u20ff",fH=uH+cH+dH,hH="\\ufe0e\\ufe0f",pH="\\u200d",mH=RegExp("["+pH+lH+fH+hH+"]");function vH(e){return mH.test(e)}var AC=vH;function gH(e){return e.split("")}var yH=gH,jC="\\ud800-\\udfff",bH="\\u0300-\\u036f",wH="\\ufe20-\\ufe2f",xH="\\u20d0-\\u20ff",_H=bH+wH+xH,SH="\\ufe0e\\ufe0f",OH="["+jC+"]",fy="["+_H+"]",hy="\\ud83c[\\udffb-\\udfff]",EH="(?:"+fy+"|"+hy+")",TC="[^"+jC+"]",CC="(?:\\ud83c[\\udde6-\\uddff]){2}",NC="[\\ud800-\\udbff][\\udc00-\\udfff]",kH="\\u200d",$C=EH+"?",RC="["+SH+"]?",PH="(?:"+kH+"(?:"+[TC,CC,NC].join("|")+")"+RC+$C+")*",AH=RC+$C+PH,jH="(?:"+[TC+fy+"?",fy,CC,NC,OH].join("|")+")",TH=RegExp(hy+"(?="+hy+")|"+jH+AH,"g");function CH(e){return e.match(TH)||[]}var NH=CH,$H=yH,RH=AC,IH=NH;function MH(e){return RH(e)?IH(e):$H(e)}var DH=MH,LH=sH,BH=AC,UH=DH,FH=_C;function zH(e){return function(t){t=FH(t);var r=BH(t)?UH(t):void 0,n=r?r[0]:t.charAt(0),i=r?LH(r,1).join(""):t.slice(1);return n[e]()+i}}var WH=zH,qH=WH,HH=qH("toUpperCase"),VH=HH;const Np=Ce(VH);function Re(e){return function(){return e}}const IC=Math.cos,Rf=Math.sin,sn=Math.sqrt,If=Math.PI,$p=2*If,py=Math.PI,my=2*py,pa=1e-6,KH=my-pa;function MC(e){this._+=e[0];for(let t=1,r=e.length;t<r;++t)this._+=arguments[t]+e[t]}function GH(e){let t=Math.floor(e);if(!(t>=0))throw new Error(`invalid digits: ${e}`);if(t>15)return MC;const r=10**t;return function(n){this._+=n[0];for(let i=1,a=n.length;i<a;++i)this._+=Math.round(arguments[i]*r)/r+n[i]}}class YH{constructor(t){this._x0=this._y0=this._x1=this._y1=null,this._="",this._append=t==null?MC:GH(t)}moveTo(t,r){this._append`M${this._x0=this._x1=+t},${this._y0=this._y1=+r}`}closePath(){this._x1!==null&&(this._x1=this._x0,this._y1=this._y0,this._append`Z`)}lineTo(t,r){this._append`L${this._x1=+t},${this._y1=+r}`}quadraticCurveTo(t,r,n,i){this._append`Q${+t},${+r},${this._x1=+n},${this._y1=+i}`}bezierCurveTo(t,r,n,i,a,o){this._append`C${+t},${+r},${+n}
298,${+i},${this._x1=+a},${this._y1=+o}`}arcTo(t,r,n,i,a){if(t=+t,r=+r,n=+n,i=+i,a=+a,a<0)throw new Error(`negative radius: ${a}`);let o=this._x1,s=this._y1,l=n-t,u=i-r,d=o-t,c=s-r,f=d*d+c*c;if(this._x1===null)this._append`M${this._x1=t},${this._y1=r}`;else if(f>pa)if(!(Math.abs(c*l-u*d)>pa)||!a)this._append`L${this._x1=t},${this._y1=r}`;else{let h=n-o,v=i-s,m=l*l+u*u,g=h*h+v*v,y=Math.sqrt(m),b=Math.sqrt(f),w=a*Math.tan((py-Math.acos((m+f-g)/(2*y*b)))/2),_=w/b,x=w/y;Math.abs(_-1)>pa&&this._append`L${t+_*d},${r+_*c}`,this._append`A${a},${a},0,0,${+(c*h>d*v)},${this._x1=t+x*l},${this._y1=r+x*u}`}}arc(t,r,n,i,a,o){if(t=+t,r=+r,n=+n,o=!!o,n<0)throw new Error(`negative radius: ${n}`);let s=n*Math.cos(i),l=n*Math.sin(i),u=t+s,d=r+l,c=1^o,f=o?i-a:a-i;this._x1===null?this._append`M${u},${d}`:(Math.abs(this._x1-u)>pa||Math.abs(this._y1-d)>pa)&&this._append`L${u},${d}`,n&&(f<0&&(f=f%my+my),f>KH?this._append`A${n},${n},0,1,${c},${t-s},${r-l}A${n},${n},0,1,${c},${this._x1=u},${this._y1=d}`:f>pa&&this._append`A${n},${n},0,${+(f>=py)},${c},${this._x1=t+n*Math.cos(a)},${this._y1=r+n*Math.sin(a)}`)}rect(t,r,n,i){this._append`M${this._x0=this._x1=+t},${this._y0=this._y1=+r}h${n=+n}v${+i}h${-n}Z`}toString(){return this._}}function uw(e){let t=3;return e.digits=function(r){if(!arguments.length)return t;if(r==null)t=null;else{const n=Math.floor(r);if(!(n>=0))throw new RangeError(`invalid digits: ${r}`);t=n}return e},()=>new YH(t)}function cw(e){return typeof e=="object"&&"length"in e?e:Array.from(e)}function DC(e){this._context=e}DC.prototype={areaStart:function(){this._line=0},areaEnd:function(){this._line=NaN},lineStart:function(){this._point=0},lineEnd:function(){(this._line||this._line!==0&&this._point===1)&&this._context.closePath(),this._line=1-this._line},point:function(e,t){switch(e=+e,t=+t,this._point){case 0:this._point=1,this._line?this._context.lineTo(e,t):this._context.moveTo(e,t);break;case 1:this._point=2;default:this._context.lineTo(e,t);break}}};function Rp(e){return new DC(e)}function LC(e){return e[0]}function BC(e){return e[1]}function UC(e,t){var r=Re(!0),n=null,i=Rp,a=null,o=uw(s);e=typeof e=="function"?e:e===void 0?LC:Re(e),t=typeof t=="function"?t:t===void 0?BC:Re(t);function s(l){var u,d=(l=cw(l)).length,c,f=!1,h;for(n==null&&(a=i(h=o())),u=0;u<=d;++u)!(u<d&&r(c=l[u],u,l))===f&&((f=!f)?a.lineStart():a.lineEnd()),f&&a.point(+e(c,u,l),+t(c,u,l));if(h)return a=null,h+""||null}return s.x=function(l){return arguments.length?(e=typeof l=="function"?l:Re(+l),s):e},s.y=function(l){return arguments.length?(t=typeof l=="function"?l:Re(+l),s):t},s.defined=function(l){return arguments.length?(r=typeof l=="function"?l:Re(!!l),s):r},s.curve=function(l){return arguments.length?(i=l,n!=null&&(a=i(n)),s):i},s.context=function(l){return arguments.length?(l==null?n=a=null:a=i(n=l),s):n},s}function pd(e,t,r){var n=null,i=Re(!0),a=null,o=Rp,s=null,l=uw(u);e=typeof e=="function"?e:e===void 0?LC:Re(+e),t=typeof t=="function"?t:Re(t===void 0?0:+t),r=typeof r=="function"?r:r===void 0?BC:Re(+r);function u(c){var f,h,v,m=(c=cw(c)).length,g,y=!1,b,w=new Array(m),_=new Array(m);for(a==null&&(s=o(b=l())),f=0;f<=m;++f){if(!(f<m&&i(g=c[f],f,c))===y)if(y=!y)h=f,s.areaStart(),s.lineStart();else{for(s.lineEnd(),s.lineStart(),v=f-1;v>=h;--v)s.point(w[v],_[v]);s.lineEnd(),s.areaEnd()}y&&(w[f]=+e(g,f,c),_[f]=+t(g,f,c),s.point(n?+n(g,f,c):w[f],r?+r(g,f,c):_[f]))}if(b)return s=null,b+""||null}function d(){return UC().defined(i).curve(o).context(a)}return u.x=function(c){return arguments.length?(e=typeof c=="function"?c:Re(+c),n=null,u):e},u.x0=function(c){return arguments.length?(e=typeof c=="function"?c:Re(+c),u):e},u.x1=function(c){return arguments.length?(n=c==null?null:typeof c=="function"?c:Re(+c),u):n},u.y=function(c){return arguments.length?(t=typeof c=="function"?c:Re(+c),r=null,u):t},u.y0=function(c){return arguments.length?(t=typeof c=="function"?c:Re(+c),u):t},u.y1=function(c){return arguments.length?(r=c==null?null:typeof c=="function"?c:Re(+c),u):r},u.lineX0=u.lineY0=function(){return d().x(e).y(t)},u.lineY1=function(){return d().x(e).y(r)},u.lineX1=function(){return d().x(n).y(t)},u.defined=function(c){return arguments.length?(i=typeof c=="function"?c:Re(!!c),u):i},u.curve=function(c){return arguments.length?(o=c,a!=null&&(s=o(a)),u):o},u.context=function(c){return arguments.length?(c==null?a=s=null:s=o(a=c),u):a},u}class FC{constructor(t,r){this._context=t,this._x=r}areaStart(){this._line=0}areaEnd(){this._line=NaN}lineStart(){this._point=0}lineEnd(){(this._line||this._line!==0&&this._point===1)&&this._context.closePath(),this._line=1-this._line}point(t,r){switch(t=+t,r=+r,this._point){case 0:{this._point=1,this._line?this._context.lineTo(t,r):this._context.moveTo(t,r);break}case 1:this._point=2;default:{this._x?this._context.bezierCurveTo(this._x0=(this._x0+t)/2,this._y0,this._x0,r,t,r):this._context.bezierCurveTo(this._x0,this._y0=(this._y0+r)/2,t,this._y0,t,r);break}}this._x0=t,this._y0=r}}function XH(e){return new FC(e,!0)}function QH(e){return new FC(e,!1)}const dw={draw(e,t){const r=sn(t/If);e.moveTo(r,0),e.arc(0,0,r,0,$p)}},JH={draw(e,t){const r=sn(t/5)/2;e.moveTo(-3*r,-r),e.lineTo(-r,-r),e.lineTo(-r,-3*r),e.lineTo(r,-3*r),e.lineTo(r,-r),e.lineTo(3*r,-r),e.lineTo(3*r,r),e.lineTo(r,r),e.lineTo(r,3*r),e.lineTo(-r,3*r),e.lineTo(-r,r),e.lineTo(-3*r,r),e.closePath()}},zC=sn(1/3),ZH=zC*2,eV={draw(e,t){const r=sn(t/ZH),n=r*zC;e.moveTo(0,-r),e.lineTo(n,0),e.lineTo(0,r),e.lineTo(-n,0),e.closePath()}},tV={draw(e,t){const r=sn(t),n=-r/2;e.rect(n,n,r,r)}},rV=.8908130915292852,WC=Rf(If/10)/Rf(7*If/10),nV=Rf($p/10)*WC,iV=-IC($p/10)*WC,aV={draw(e,t){const r=sn(t*rV),n=nV*r,i=iV*r;e.moveTo(0,-r),e.lineTo(n,i);for(let a=1;a<5;++a){const o=$p*a/5,s=IC(o),l=Rf(o);e.lineTo(l*r,-s*r),e.lineTo(s*n-l*i,l*n+s*i)}e.closePath()}},ov=sn(3),oV={draw(e,t){const r=-sn(t/(ov*3));e.moveTo(0,r*2),e.lineTo(-ov*r,-r),e.lineTo(ov*r,-r),e.closePath()}},gr=-.5,yr=sn(3)/2,vy=1/sn(12),sV=(vy/2+1)*3,lV={draw(e,t){const r=sn(t/sV),n=r/2,i=r*vy,a=n,o=r*vy+r,s=-a,l=o;e.moveTo(n,i),e.lineTo(a,o),e.lineTo(s,l),e.lineTo(gr*n-yr*i,yr*n+gr*i),e.lineTo(gr*a-yr*o,yr*a+gr*o),e.lineTo(gr*s-yr*l,yr*s+gr*l),e.lineTo(gr*n+yr*i,gr*i-yr*n),e.lineTo(gr*a+yr*o,gr*o-yr*a),e.lineTo(gr*s+yr*l,gr*l-yr*s),e.closePath()}};function uV(e,t){let r=null,n=uw(i);e=typeof e=="function"?e:Re(e||dw),t=typeof t=="function"?t:Re(t===void 0?64:+t);function i(){let a;if(r||(r=a=n()),e.apply(this,arguments).draw(r,+t.apply(this,arguments)),a)return r=null,a+""||null}return i.type=function(a){return arguments.length?(e=typeof a=="function"?a:Re(a),i):e},i.size=function(a){return arguments.length?(t=typeof a=="function"?a:Re(+a),i):t}
vendor: 6,361 bytes, line 298
298,i.context=function(a){return arguments.length?(r=a??null,i):r},i}function Mf(){}function Df(e,t,r){e._context.bezierCurveTo((2*e._x0+e._x1)/3,(2*e._y0+e._y1)/3,(e._x0+2*e._x1)/3,(e._y0+2*e._y1)/3,(e._x0+4*e._x1+t)/6,(e._y0+4*e._y1+r)/6)}function qC(e){this._context=e}qC.prototype={areaStart:function(){this._line=0},areaEnd:function(){this._line=NaN},lineStart:function(){this._x0=this._x1=this._y0=this._y1=NaN,this._point=0},lineEnd:function(){switch(this._point){case 3:Df(this,this._x1,this._y1);case 2:this._context.lineTo(this._x1,this._y1);break}(this._line||this._line!==0&&this._point===1)&&this._context.closePath(),this._line=1-this._line},point:function(e,t){switch(e=+e,t=+t,this._point){case 0:this._point=1,this._line?this._context.lineTo(e,t):this._context.moveTo(e,t);break;case 1:this._point=2;break;case 2:this._point=3,this._context.lineTo((5*this._x0+this._x1)/6,(5*this._y0+this._y1)/6);default:Df(this,e,t);break}this._x0=this._x1,this._x1=e,this._y0=this._y1,this._y1=t}};function cV(e){return new qC(e)}function HC(e){this._context=e}HC.prototype={areaStart:Mf,areaEnd:Mf,lineStart:function(){this._x0=this._x1=this._x2=this._x3=this._x4=this._y0=this._y1=this._y2=this._y3=this._y4=NaN,this._point=0},lineEnd:function(){switch(this._point){case 1:{this._context.moveTo(this._x2,this._y2),this._context.closePath();break}case 2:{this._context.moveTo((this._x2+2*this._x3)/3,(this._y2+2*this._y3)/3),this._context.lineTo((this._x3+2*this._x2)/3,(this._y3+2*this._y2)/3),this._context.closePath();break}case 3:{this.point(this._x2,this._y2),this.point(this._x3,this._y3),this.point(this._x4,this._y4);break}}},point:function(e,t){switch(e=+e,t=+t,this._point){case 0:this._point=1,this._x2=e,this._y2=t;break;case 1:this._point=2,this._x3=e,this._y3=t;break;case 2:this._point=3,this._x4=e,this._y4=t,this._context.moveTo((this._x0+4*this._x1+e)/6,(this._y0+4*this._y1+t)/6);break;default:Df(this,e,t);break}this._x0=this._x1,this._x1=e,this._y0=this._y1,this._y1=t}};function dV(e){return new HC(e)}function VC(e){this._context=e}VC.prototype={areaStart:function(){this._line=0},areaEnd:function(){this._line=NaN},lineStart:function(){this._x0=this._x1=this._y0=this._y1=NaN,this._point=0},lineEnd:function(){(this._line||this._line!==0&&this._point===3)&&this._context.closePath(),this._line=1-this._line},point:function(e,t){switch(e=+e,t=+t,this._point){case 0:this._point=1;break;case 1:this._point=2;break;case 2:this._point=3;var r=(this._x0+4*this._x1+e)/6,n=(this._y0+4*this._y1+t)/6;this._line?this._context.lineTo(r,n):this._context.moveTo(r,n);break;case 3:this._point=4;default:Df(this,e,t);break}this._x0=this._x1,this._x1=e,this._y0=this._y1,this._y1=t}};function fV(e){return new VC(e)}function KC(e){this._context=e}KC.prototype={areaStart:Mf,areaEnd:Mf,lineStart:function(){this._point=0},lineEnd:function(){this._point&&this._context.closePath()},point:function(e,t){e=+e,t=+t,this._point?this._context.lineTo(e,t):(this._point=1,this._context.moveTo(e,t))}};function hV(e){return new KC(e)}function iS(e){return e<0?-1:1}function aS(e,t,r){var n=e._x1-e._x0,i=t-e._x1,a=(e._y1-e._y0)/(n||i<0&&-0),o=(r-e._y1)/(i||n<0&&-0),s=(a*i+o*n)/(n+i);return(iS(a)+iS(o))*Math.min(Math.abs(a),Math.abs(o),.5*Math.abs(s))||0}function oS(e,t){var r=e._x1-e._x0;return r?(3*(e._y1-e._y0)/r-t)/2:t}function sv(e,t,r){var n=e._x0,i=e._y0,a=e._x1,o=e._y1,s=(a-n)/3;e._context.bezierCurveTo(n+s,i+s*t,a-s,o-s*r,a,o)}function Lf(e){this._context=e}Lf.prototype={areaStart:function(){this._line=0},areaEnd:function(){this._line=NaN},lineStart:function(){this._x0=this._x1=this._y0=this._y1=this._t0=NaN,this._point=0},lineEnd:function(){switch(this._point){case 2:this._context.lineTo(this._x1,this._y1);break;case 3:sv(this,this._t0,oS(this,this._t0));break}(this._line||this._line!==0&&this._point===1)&&this._context.closePath(),this._line=1-this._line},point:function(e,t){var r=NaN;if(e=+e,t=+t,!(e===this._x1&&t===this._y1)){switch(this._point){case 0:this._point=1,this._line?this._context.lineTo(e,t):this._context.moveTo(e,t);break;case 1:this._point=2;break;case 2:this._point=3,sv(this,oS(this,r=aS(this,e,t)),r);break;default:sv(this,this._t0,r=aS(this,e,t));break}this._x0=this._x1,this._x1=e,this._y0=this._y1,this._y1=t,this._t0=r}}};function GC(e){this._context=new YC(e)}(GC.prototype=Object.create(Lf.prototype)).point=function(e,t){Lf.prototype.point.call(this,t,e)};function YC(e){this._context=e}YC.prototype={moveTo:function(e,t){this._context.moveTo(t,e)},closePath:function(){this._context.closePath()},lineTo:function(e,t){this._context.lineTo(t,e)},bezierCurveTo:function(e,t,r,n,i,a){this._context.bezierCurveTo(t,e,n,r,a,i)}};function pV(e){return new Lf(e)}function mV(e){return new GC(e)}function XC(e){this._context=e}XC.prototype={areaStart:function(){this._line=0},areaEnd:function(){this._line=NaN},lineStart:function(){this._x=[],this._y=[]},lineEnd:function(){var e=this._x,t=this._y,r=e.length;if(r)if(this._line?this._context.lineTo(e[0],t[0]):this._context.moveTo(e[0],t[0]),r===2)this._context.lineTo(e[1],t[1]);else for(var n=sS(e),i=sS(t),a=0,o=1;o<r;++a,++o)this._context.bezierCurveTo(n[0][a],i[0][a],n[1][a],i[1][a],e[o],t[o]);(this._line||this._line!==0&&r===1)&&this._context.closePath(),this._line=1-this._line,this._x=this._y=null},point:function(e,t){this._x.push(+e),this._y.push(+t)}};function sS(e){var t,r=e.length-1,n,i=new Array(r),a=new Array(r),o=new Array(r);for(i[0]=0,a[0]=2,o[0]=e[0]+2*e[1],t=1;t<r-1;++t)i[t]=1,a[t]=4,o[t]=4*e[t]+2*e[t+1];for(i[r-1]=2,a[r-1]=7,o[r-1]=8*e[r-1]+e[r],t=1;t<r;++t)n=i[t]/a[t-1],a[t]-=n,o[t]-=n*o[t-1];for(i[r-1]=o[r-1]/a[r-1],t=r-2;t>=0;--t)i[t]=(o[t]-i[t+1])/a[t];for(a[r-1]=(e[r]+i[r-1])/2,t=0;t<r-1;++t)a[t]=2*e[t+1]-i[t+1];return[i,a]}function vV(e){return new XC(e)}function Ip(e,t){this._context=e,this._t=t}Ip.prototype={areaStart:function(){this._line=0},areaEnd:function(){this._line=NaN},lineStart:function(){this._x=this._y=NaN,this._point=0},lineEnd:function(){0<this._t&&this._t<1&&this._point===2&&this._context.lineTo(this._x,this._y),(this._line||this._line!==0&&this._point===1)&&this._context.closePath(),this._line>=0&&(this._t=1-this._t,this._line=1-this._line)},point:function(e,t){switch(e=+e,t=+t,this._point){case 0:this._point=1,this._line?this._context.lineTo(e,t):this._context.moveTo(e,t);break;case 1:this._point=2;
vendor: 10,605 bytes, lines 298-301
298default:{if(this._t<=0)this._context.lineTo(this._x,t),this._context.lineTo(e,t);else{var r=this._x*(1-this._t)+e*this._t;this._context.lineTo(r,this._y),this._context.lineTo(r,t)}break}}this._x=e,this._y=t}};function gV(e){return new Ip(e,.5)}function yV(e){return new Ip(e,0)}function bV(e){return new Ip(e,1)}function xs(e,t){if((o=e.length)>1)for(var r=1,n,i,a=e[t[0]],o,s=a.length;r<o;++r)for(i=a,a=e[t[r]],n=0;n<s;++n)a[n][1]+=a[n][0]=isNaN(i[n][1])?i[n][0]:i[n][1]}function gy(e){for(var t=e.length,r=new Array(t);--t>=0;)r[t]=t;return r}function wV(e,t){return e[t]}function xV(e){const t=[];return t.key=e,t}function _V(){var e=Re([]),t=gy,r=xs,n=wV;function i(a){var o=Array.from(e.apply(this,arguments),xV),s,l=o.length,u=-1,d;for(const c of a)for(s=0,++u;s<l;++s)(o[s][u]=[0,+n(c,o[s].key,u,a)]).data=c;for(s=0,d=cw(t(o));s<l;++s)o[d[s]].index=s;return r(o,d),o}return i.keys=function(a){return arguments.length?(e=typeof a=="function"?a:Re(Array.from(a)),i):e},i.value=function(a){return arguments.length?(n=typeof a=="function"?a:Re(+a),i):n},i.order=function(a){return arguments.length?(t=a==null?gy:typeof a=="function"?a:Re(Array.from(a)),i):t},i.offset=function(a){return arguments.length?(r=a??xs,i):r},i}function SV(e,t){if((n=e.length)>0){for(var r,n,i=0,a=e[0].length,o;i<a;++i){for(o=r=0;r<n;++r)o+=e[r][i][1]||0;if(o)for(r=0;r<n;++r)e[r][i][1]/=o}xs(e,t)}}function OV(e,t){if((i=e.length)>0){for(var r=0,n=e[t[0]],i,a=n.length;r<a;++r){for(var o=0,s=0;o<i;++o)s+=e[o][r][1]||0;n[r][1]+=n[r][0]=-s/2}xs(e,t)}}function EV(e,t){if(!(!((o=e.length)>0)||!((a=(i=e[t[0]]).length)>0))){for(var r=0,n=1,i,a,o;n<a;++n){for(var s=0,l=0,u=0;s<o;++s){for(var d=e[t[s]],c=d[n][1]||0,f=d[n-1][1]||0,h=(c-f)/2,v=0;v<s;++v){var m=e[t[v]],g=m[n][1]||0,y=m[n-1][1]||0;h+=g-y}l+=c,u+=h*c}i[n-1][1]+=i[n-1][0]=r,l&&(r-=u/l)}i[n-1][1]+=i[n-1][0]=r,xs(e,t)}}function Nu(e){"@babel/helpers - typeof";return Nu=typeof Symbol=="function"&&typeof Symbol.iterator=="symbol"?function(t){return typeof t}:function(t){return t&&typeof Symbol=="function"&&t.constructor===Symbol&&t!==Symbol.prototype?"symbol":typeof t},Nu(e)}var kV=["type","size","sizeType"];function yy(){return yy=Object.assign?Object.assign.bind():function(e){for(var t=1;t<arguments.length;t++){var r=arguments[t];for(var n in r)Object.prototype.hasOwnProperty.call(r,n)&&(e[n]=r[n])}return e},yy.apply(this,arguments)}function lS(e,t){var r=Object.keys(e);if(Object.getOwnPropertySymbols){var n=Object.getOwnPropertySymbols(e);t&&(n=n.filter(function(i){return Object.getOwnPropertyDescriptor(e,i).enumerable})),r.push.apply(r,n)}return r}function uS(e){for(var t=1;t<arguments.length;t++){var r=arguments[t]!=null?arguments[t]:{};t%2?lS(Object(r),!0).forEach(function(n){PV(e,n,r[n])}):Object.getOwnPropertyDescriptors?Object.defineProperties(e,Object.getOwnPropertyDescriptors(r)):lS(Object(r)).forEach(function(n){Object.defineProperty(e,n,Object.getOwnPropertyDescriptor(r,n))})}return e}function PV(e,t,r){return t=AV(t),t in e?Object.defineProperty(e,t,{value:r,enumerable:!0,configurable:!0,writable:!0}):e[t]=r,e}function AV(e){var t=jV(e,"string");return Nu(t)=="symbol"?t:t+""}function jV(e,t){if(Nu(e)!="object"||!e)return e;var r=e[Symbol.toPrimitive];if(r!==void 0){var n=r.call(e,t||"default");if(Nu(n)!="object")return n;throw new TypeError("@@toPrimitive must return a primitive value.")}return(t==="string"?String:Number)(e)}function TV(e,t){if(e==null)return{};var r=CV(e,t),n,i;if(Object.getOwnPropertySymbols){var a=Object.getOwnPropertySymbols(e);for(i=0;i<a.length;i++)n=a[i],!(t.indexOf(n)>=0)&&Object.prototype.propertyIsEnumerable.call(e,n)&&(r[n]=e[n])}return r}function CV(e,t){if(e==null)return{};var r={};for(var n in e)if(Object.prototype.hasOwnProperty.call(e,n)){if(t.indexOf(n)>=0)continue;r[n]=e[n]}return r}var QC={symbolCircle:dw,symbolCross:JH,symbolDiamond:eV,symbolSquare:tV,symbolStar:aV,symbolTriangle:oV,symbolWye:lV},NV=Math.PI/180,$V=function(t){var r="symbol".concat(Np(t));return QC[r]||dw},RV=function(t,r,n){if(r==="area")return t;switch(n){case"cross":return 5*t*t/9;case"diamond":return .5*t*t/Math.sqrt(3);case"square":return t*t;case"star":{var i=18*NV;return 1.25*t*t*(Math.tan(i)-Math.tan(i*2)*Math.pow(Math.tan(i),2))}case"triangle":return Math.sqrt(3)*t*t/4;case"wye":return(21-10*Math.sqrt(3))*t*t/8;default:return Math.PI*t*t/4}},IV=function(t,r){QC["symbol".concat(Np(t))]=r},fw=function(t){var r=t.type,n=r===void 0?"circle":r,i=t.size,a=i===void 0?64:i,o=t.sizeType,s=o===void 0?"area":o,l=TV(t,kV),u=uS(uS({},l),{},{type:n,size:a,sizeType:s}),d=function(){var g=$V(n),y=uV().type(g).size(RV(a,s,n));return y()},c=u.className,f=u.cx,h=u.cy,v=Se(u,!0);return f===+f&&h===+h&&a===+a?j.createElement("path",yy({},v,{className:pe("recharts-symbols",c),transform:"translate(".concat(f,", ").concat(h,")"),d:d()})):null};fw.registerSymbol=IV;function _s(e){"@babel/helpers - typeof";return _s=typeof Symbol=="function"&&typeof Symbol.iterator=="symbol"?function(t){return typeof t}:function(t){return t&&typeof Symbol=="function"&&t.constructor===Symbol&&t!==Symbol.prototype?"symbol":typeof t},_s(e)}function by(){return by=Object.assign?Object.assign.bind():function(e){for(var t=1;t<arguments.length;t++){var r=arguments[t];for(var n in r)Object.prototype.hasOwnProperty.call(r,n)&&(e[n]=r[n])}return e},by.apply(this,arguments)}function cS(e,t){var r=Object.keys(e);if(Object.getOwnPropertySymbols){var n=Object.getOwnPropertySymbols(e);t&&(n=n.filter(function(i){return Object.getOwnPropertyDescriptor(e,i).enumerable})),r.push.apply(r,n)}return r}function MV(e){for(var t=1;t<arguments.length;t++){var r=arguments[t]!=null?arguments[t]:{};t%2?cS(Object(r),!0).forEach(function(n){$u(e,n,r[n])}):Object.getOwnPropertyDescriptors?Object.defineProperties(e,Object.getOwnPropertyDescriptors(r)):cS(Object(r)).forEach(function(n){Object.defineProperty(e,n,Object.getOwnPropertyDescriptor(r,n))})}return e}function DV(e,t){if(!(e instanceof t))throw new TypeError("Cannot call a class as a function")}function LV(e,t){for(var r=0;r<t.length;r++){var n=t[r];n.enumerable=n.enumerable||!1,n.configurable=!0,"value"in n&&(n.writable=!0),Object.defineProperty(e,ZC(n.key),n)}}function BV(e,t,r){return t&&LV(e.prototype,t),Object.defineProperty(e,"prototype",{writable:!1}),e}function UV(e,t,r){return t=Bf(t),FV(e,JC()?Reflect.construct(t,r||[],Bf(e).constructor):t.apply(e,r))}function FV(e,t){if(t&&(_s(t)==="object"||typeof t=="function"))return t;if(t!==void 0)throw new TypeError("Derived constructors may only return object or undefined");return zV(e)}function zV(e){if(e===void 0)throw new ReferenceError("this hasn't been initialised - super() hasn't been called");return e}function JC(){try{var e=!Boolean.prototype.valueOf.call(Reflect.construct(Boolean,[],function(){}))}catch{}return(JC=function(){return!!e})()}function Bf(e){return Bf=Object.setPrototypeOf?Object.getPrototypeOf.bind():function(r){return r.__proto__||Object.getPrototypeOf(r)},Bf(e)}function WV(e,t){if(typeof t!="function"&&t!==null)throw new TypeError("Super expression must either be null or a function");e.prototype=Object.create(t&&t.prototype,{constructor:{value:e,writable:!0,configurable:!0}}),Object.defineProperty(e,"prototype",{writable:!1}),t&&wy(e,t)}function wy(e,t){return wy=Object.setPrototypeOf?Object.setPrototypeOf.bind():function(n,i){return n.__proto__=i,n},wy(e,t)}function $u(e,t,r){return t=ZC(t),t in e?Object.defineProperty(e,t,{value:r,enumerable:!0,configurable:!0,writable:!0}):e[t]=r,e}function ZC(e){var t=qV(e,"string");return _s(t)=="symbol"?t:t+""}function qV(e,t){if(_s(e)!="object"||!e)return e;var r=e[Symbol.toPrimitive];if(r!==void 0){var n=r.call(e,t||"default");if(_s(n)!="object")return n;throw new TypeError("@@toPrimitive must return a primitive value.")}return(t==="string"?String:Number)(e)}var br=32,hw=function(e){function t(){return DV(this,t),UV(this,t,arguments)}return WV(t,e),BV(t,[{key:"renderIcon",value:function(n){var i=this.props.inactiveColor,a=br/2,o=br/6,s=br/3,l=n.inactive?i:n.color;if(n.type==="plainline")return j.createElement("line",{strokeWidth:4,fill:"none",stroke:l,strokeDasharray:n.payload.strokeDasharray,x1:0,y1:a,x2:br,y2:a,className:"recharts-legend-icon"});if(n.type==="line")return j.createElement("path",{strokeWidth:4,fill:"none",stroke:l,d:"M0,".concat(a,"h").concat(s,` 299 A`).concat(o,",").concat(o,",0,1,1,").concat(2*s,",").concat(a,` 300 H`).concat(br,"M").concat(2*s,",").concat(a,` 301 A`).concat(o,",").concat(o,",0,1,1,").concat(s,",").concat(a),className:"recharts-legend-icon"});if(n.type==="rect")return j.createElement("path",{stroke:"none",fill:l,d:"M0,".concat(br/8,"h").concat(br,"v").concat(br*3/4,"h").concat(-br,"z"),className:"recharts-legend-icon"});if(j.isValidElement(n.legendIcon)){var u=MV({},n);return delete u.legendIcon,j.cloneElement(n.legendIcon,u)}return j.createElement(fw,{fill:l,cx:a,cy:a,size:br,sizeType:"diameter",type:n.type})}},{key:"renderItems",value:function(){var n=this,i=this.props,a=i.payload,o=i.iconSize,s=i.layout,l=i.formatter,u=i.inactiveColor,d={x:0,y:0,width:br,height:br},c={display:s==="horizontal"?"inline-block":"block",marginRight:10},f={display:"inline-block",verticalAlign:"middle",marginRight:4};return a.map(function(h,v){var m=h.formatter||l,g=pe($u($u({"recharts-legend-item":!0},"legend-item-".concat(v),!0),"inactive",h.inactive));if(h.type==="none")return null;var y=fe(h.value)?null:h.value;Da(!fe(h.value),`The name property is also required when using a function for the dataKey of a chart's cartesian components. Ex: <Bar name="Name of my Data"/>`);var b=h.inactive?u:h.color;return j.createElement("li",by({className:g,style:c,key:"legend-item-".concat(v)},$f(n.props,h,v)),j.createElement(cy,{width:o,height:o,viewBox:d,style:f},n.renderIcon(h)),j.createElement("span",{className:"recharts-legend-item-text",style:{color:b}},m?m(y,h,v):y))})}},{key:"render",value:function(){var n=this.props,i=n.payload,a=n.layout,o=n.align;if(!i||!i.length)return null;var s={padding:0,margin:0,textAlign:a==="horizontal"?o:"left"};return j.createElement("ul",{className:"recharts-default-legend",style:s},this.renderItems())}}])}(O.PureComponent);$u(hw,"displayName","Legend");$u(hw,"defaultProps",{iconSize:14,layout:"horizontal",align:"center",verticalAlign:"middle",inactiveColor:"#ccc"});var HV=yp;function VV(){this.__data__=new HV,this.size=0}var KV=VV;function GV(e){var t=this.__data__,r=t.delete(e);return this.size=t.size,r}var YV=GV;function XV(e){return this.__data__.get(e)}var QV=XV;function JV(e){return this.__data__.has(e)}
vendor: 4,326 bytes, line 301
301var ZV=JV,eK=yp,tK=ew,rK=tw,nK=200;function iK(e,t){var r=this.__data__;if(r instanceof eK){var n=r.__data__;if(!tK||n.length<nK-1)return n.push([e,t]),this.size=++r.size,this;r=this.__data__=new rK(n)}return r.set(e,t),this.size=r.size,this}var aK=iK,oK=yp,sK=KV,lK=YV,uK=QV,cK=ZV,dK=aK;function il(e){var t=this.__data__=new oK(e);this.size=t.size}il.prototype.clear=sK;il.prototype.delete=lK;il.prototype.get=uK;il.prototype.has=cK;il.prototype.set=dK;var eN=il,fK="__lodash_hash_undefined__";function hK(e){return this.__data__.set(e,fK),this}var pK=hK;function mK(e){return this.__data__.has(e)}var vK=mK,gK=tw,yK=pK,bK=vK;function Uf(e){var t=-1,r=e==null?0:e.length;for(this.__data__=new gK;++t<r;)this.add(e[t])}Uf.prototype.add=Uf.prototype.push=yK;Uf.prototype.has=bK;var tN=Uf;function wK(e,t){for(var r=-1,n=e==null?0:e.length;++r<n;)if(t(e[r],r,e))return!0;return!1}var rN=wK;function xK(e,t){return e.has(t)}var nN=xK,_K=tN,SK=rN,OK=nN,EK=1,kK=2;function PK(e,t,r,n,i,a){var o=r&EK,s=e.length,l=t.length;if(s!=l&&!(o&&l>s))return!1;var u=a.get(e),d=a.get(t);if(u&&d)return u==t&&d==e;var c=-1,f=!0,h=r&kK?new _K:void 0;for(a.set(e,t),a.set(t,e);++c<s;){var v=e[c],m=t[c];if(n)var g=o?n(m,v,c,t,e,a):n(v,m,c,e,t,a);if(g!==void 0){if(g)continue;f=!1;break}if(h){if(!SK(t,function(y,b){if(!OK(h,b)&&(v===y||i(v,y,r,n,a)))return h.push(b)})){f=!1;break}}else if(!(v===m||i(v,m,r,n,a))){f=!1;break}}return a.delete(e),a.delete(t),f}var iN=PK,AK=Nn,jK=AK.Uint8Array,TK=jK;function CK(e){var t=-1,r=Array(e.size);return e.forEach(function(n,i){r[++t]=[i,n]}),r}var NK=CK;function $K(e){var t=-1,r=Array(e.size);return e.forEach(function(n){r[++t]=n}),r}var pw=$K,dS=Pc,fS=TK,RK=Zb,IK=iN,MK=NK,DK=pw,LK=1,BK=2,UK="[object Boolean]",FK="[object Date]",zK="[object Error]",WK="[object Map]",qK="[object Number]",HK="[object RegExp]",VK="[object Set]",KK="[object String]",GK="[object Symbol]",YK="[object ArrayBuffer]",XK="[object DataView]",hS=dS?dS.prototype:void 0,lv=hS?hS.valueOf:void 0;function QK(e,t,r,n,i,a,o){switch(r){case XK:if(e.byteLength!=t.byteLength||e.byteOffset!=t.byteOffset)return!1;e=e.buffer,t=t.buffer;case YK:return!(e.byteLength!=t.byteLength||!a(new fS(e),new fS(t)));case UK:case FK:case qK:return RK(+e,+t);case zK:return e.name==t.name&&e.message==t.message;case HK:case KK:return e==t+"";case WK:var s=MK;case VK:var l=n&LK;if(s||(s=DK),e.size!=t.size&&!l)return!1;var u=o.get(e);if(u)return u==t;n|=BK,o.set(e,t);var d=IK(s(e),s(t),n,i,a,o);return o.delete(e),d;case GK:if(lv)return lv.call(e)==lv.call(t)}return!1}var JK=QK;function ZK(e,t){for(var r=-1,n=t.length,i=e.length;++r<n;)e[i+r]=t[r];return e}var aN=ZK,e7=aN,t7=Jt;function r7(e,t,r){var n=t(e);return t7(e)?n:e7(n,r(e))}var n7=r7;function i7(e,t){for(var r=-1,n=e==null?0:e.length,i=0,a=[];++r<n;){var o=e[r];t(o,r,e)&&(a[i++]=o)}return a}var a7=i7;function o7(){return[]}var s7=o7,l7=a7,u7=s7,c7=Object.prototype,d7=c7.propertyIsEnumerable,pS=Object.getOwnPropertySymbols,f7=pS?function(e){return e==null?[]:(e=Object(e),l7(pS(e),function(t){return d7.call(e,t)}))}:u7,h7=f7;function p7(e,t){for(var r=-1,n=Array(e);++r<e;)n[r]=t(r);return n}var m7=p7,v7=oi,g7=si,y7="[object Arguments]";function b7(e){return g7(e)&&v7(e)==y7}var w7=b7,mS=w7,x7=si,oN=Object.prototype,_7=oN.hasOwnProperty,S7=oN.propertyIsEnumerable,O7=mS(function(){return arguments}())?mS:function(e){return x7(e)&&_7.call(e,"callee")&&!S7.call(e,"callee")},mw=O7,Ff={exports:{}};function E7(){return!1}var k7=E7;Ff.exports;(function(e,t){var r=Nn,n=k7,i=t&&!t.nodeType&&t,a=i&&!0&&e&&!e.nodeType&&e,o=a&&a.exports===i,s=o?r.Buffer:void 0,l=s?s.isBuffer:void 0,u=l||n;e.exports=u})(Ff,Ff.exports);var sN=Ff.exports,P7=9007199254740991,A7=/^(?:0|[1-9]\d*)$/;function j7(e,t){var r=typeof e;return t=t??P7,!!t&&(r=="number"||r!="symbol"&&A7.test(e))&&e>-1&&e%1==0&&e<t}var vw=j7,T7=9007199254740991;function C7(e){return typeof e=="number"&&e>-1&&e%1==0&&e<=T7}var gw=C7,N7=oi,$7=gw,R7=si,I7="[object Arguments]",M7="[object Array]",D7="[object Boolean]",L7="[object Date]",B7="[object Error]",U7="[object Function]",F7="[object Map]",z7="[object Number]",W7="[object Object]",q7="[object RegExp]",H7="[object Set]",V7="[object String]",K7="[object WeakMap]",G7="[object ArrayBuffer]",Y7="[object DataView]",X7="[object Float32Array]",Q7="[object Float64Array
301]",J7="[object Int8Array]",Z7="[object Int16Array]",e9="[object Int32Array]",t9="[object Uint8Array]",r9="[object Uint8ClampedArray]",n9="[object Uint16Array]",i9="[object Uint32Array]",Le={};Le[X7]=Le[Q7]=Le[J7]=Le[Z7]=Le[e9]=Le[t9]=Le[r9]=Le[n9]=Le[i9]=!0;Le[I7]=Le[M7]=Le[G7]=Le[D7]=Le[Y7]=Le[L7]=Le[B7]=Le[U7]=Le[F7]=Le[z7]=Le[W7]=Le[q7]=Le[H7]=Le[V7]=Le[K7]=!1;function a9(e){return R7(e)&&$7(e.length)&&!!Le[N7(e)]}var o9=a9;function s9(e){return function(t){return e(t)}}var lN=s9,zf={exports:{}};zf.exports;(function(e,t){var r=vC,n=t&&!t.nodeType&&t,i=n&&!0&&e&&!e.nodeType&&e,a=i&&i.exports===n,o=a&&r.process,s=function(){try{var l=i&&i.require&&i.require("util").types;return l||o&&o.binding&&o.binding("util")}catch{}}();e.exports=s})(zf,zf.exports);var l9=zf.exports,u9=o9,c9=lN,vS=l9,gS=vS&&vS.isTypedArray,d9=gS?c9(gS):u9,uN=d9,f9=m7,h9=mw,p9=Jt,m9=sN,v9=vw,g9=uN,y9=Object.prototype,b9=y9.hasOwnProperty;function w9(e,t){var r=p9(e),n=!r&&h9(e),i=!r&&!n&&m9(e),a=!r&&!n&&!i&&g9(e),o=r||n||i||a,s=o?f9(e.length,String):[],l=s.length;for(var u in e)(t||b9.call(e,u))&&!(o&&(u=="length"||i&&(u=="offset"||u=="parent")||a&&(u=="buffer"||u=="byteLength"||u=="byteOffset")||v9(u,l)))&&s.push(u);return s}var x9=w9,_9=Object.prototype;function S9(e){var t=e&&e.constructor,r=typeof t=="function"&&t.prototype||_9;return e===r}var O9=S9;function E9(e,t){return function(r){return e(t(r))}}var cN=E9,k9=cN,P9=k9(Object.keys,Object),A9=P9,j9=O9,T9=A9,C9=Object.prototype,N9=C9.hasOwnProperty;function $9(e){if(!j9(e))return T9(e);var t=[];for(var r in Object(e))N9.call(e,r)&&r!="constructor"&&t.push(r);return t}var R9=$9,I9=Jb,M9=gw;function D9(e){return e!=null&&M9(e.length)&&!I9(e)}var Mp=D9,L9=x9,B9=R9,U9=Mp;function F9(e){return U9(e)?L9(e):B9(e)}var yw=F9,z9=n7,W9=h7,q9=yw;function H9(e){return z9(e,q9,W9)}var V9=H9,yS=V9,K9=1,G9=Object.prototype,Y9=G9.hasOwnProperty;function X9(e,t,r,n,i,a){var o=r&K9,s=yS(e),l=s.length,u=yS(t),d=u.length;if(l!=d&&!o)return!1;for(var c=l;c--;){var f=s[c];if(!(o?f in t:Y9.call(t,f)))return!1}var h=a.get(e),v=a.get(t);if(h&&v)return h==t&&v==e;var m=!0;a.set(e,t),a.set(t,e);for(var g=o;++c<l;){f=s[c];var y=e[f],b=t[f];if(n)var w=o?n(b,y,f,t,e,a):n(y,b,f,e,t,a);if(!(w===void 0?y===b||i(y,b,r,n,a):w)){m=!1;break}g||(g=f=="constructor")}if(m&&!g){var _=e.constructor,x=t.constructor;_!=x&&"constructor"in e&&"constructor"in t&&!(typeof _=="function"&&_ instanceof _&&typeof x=="function"&&x instanceof x)&&(m=!1)}return a.delete(e),a.delete(t),m}var Q9=X9,J9=ro,Z9=Nn,eG=J9(Z9,"DataView"),tG=eG,rG=ro,nG=Nn,iG=rG(nG,"Promise"),aG=iG,oG=ro,sG=Nn,lG=oG(sG,"Set"),dN=lG,uG=ro,cG=Nn,dG=uG(cG,"WeakMap"),fG=dG,xy=tG,_y=ew,Sy=aG,Oy=dN,Ey=fG,fN=oi,al=yC,bS="[object Map]",hG="[object Object]",wS="[object Promise]",xS="[object Set]",_S="[object WeakMap]",SS="[object DataView]",pG=al(xy),mG=al(_y),vG=al(Sy),gG=al(Oy),yG=al(Ey),ma=fN;(xy&&ma(new xy(new ArrayBuffer(1)))!=SS||_y&&ma(new _y)!=bS||Sy&&ma(Sy.resolve())!=wS||Oy&&ma(new Oy)!=xS||Ey&&ma(new Ey)!=_S)&&(ma=function(e){var t=fN(e),r=t==hG?e.constructor:void 0,n=r?al(r):"";if(n)switch(n){case pG:return SS;case mG:return bS;case vG:return wS;case gG:return xS;case yG:return _S}return t});var bG=ma,uv=eN,wG=iN,xG=JK,_G=Q9,OS=bG,ES=Jt,kS=sN,SG=uN,OG=1,PS="[object Arguments]",AS="[object Array]",md="[object Object]",EG=Object.prototype,jS=EG.hasOwnProperty;function kG(e,t,r,n,i,a){var o=ES(e),s=ES(t),l=o?AS:OS(e),u=s?AS:OS(t);l=l==PS?md:l,u=u==PS?md:u;var d=l==md,c=u==md,f=l==u;if(f&&kS(e)){if(!kS(t))return!1;o=!0,d=!1}if(f&&!d)return a||(a=new uv),o||SG(e)?wG(e,t,r,n,i,a):xG(e,t,l,r,n,i,a);if(!(r&OG)){var h=d&&jS.call(e,"__wrapped__"),v=c&&jS.call(t,"__wrapped__");
vendor: 1,392 bytes, line 301
301if(h||v){var m=h?e.value():e,g=v?t.value():t;return a||(a=new uv),i(m,g,r,n,a)}}return f?(a||(a=new uv),_G(e,t,r,n,i,a)):!1}var PG=kG,AG=PG,TS=si;function hN(e,t,r,n,i){return e===t?!0:e==null||t==null||!TS(e)&&!TS(t)?e!==e&&t!==t:AG(e,t,r,n,hN,i)}var bw=hN,jG=eN,TG=bw,CG=1,NG=2;function $G(e,t,r,n){var i=r.length,a=i,o=!n;if(e==null)return!a;for(e=Object(e);i--;){var s=r[i];if(o&&s[2]?s[1]!==e[s[0]]:!(s[0]in e))return!1}for(;++i<a;){s=r[i];var l=s[0],u=e[l],d=s[1];if(o&&s[2]){if(u===void 0&&!(l in e))return!1}else{var c=new jG;if(n)var f=n(u,d,l,e,t,c);if(!(f===void 0?TG(d,u,CG|NG,n,c):f))return!1}}return!0}var RG=$G,IG=ta;function MG(e){return e===e&&!IG(e)}var pN=MG,DG=pN,LG=yw;function BG(e){for(var t=LG(e),r=t.length;r--;){var n=t[r],i=e[n];t[r]=[n,i,DG(i)]}return t}var UG=BG;function FG(e,t){return function(r){return r==null?!1:r[e]===t&&(t!==void 0||e in Object(r))}}var mN=FG,zG=RG,WG=UG,qG=mN;function HG(e){var t=WG(e);return t.length==1&&t[0][2]?qG(t[0][0],t[0][1]):function(r){return r===e||zG(r,e,t)}}var VG=HG;function KG(e,t){return e!=null&&t in Object(e)}var GG=KG,YG=SC,XG=mw,QG=Jt,JG=vw,ZG=gw,eY=wp;function tY(e,t,r){t=YG(t,e);for(var n=-1,i=t.length,a=!1;++n<i;){var o=eY(t[n]);if(!(a=e!=null&&r(e,o)))break;e=e[o]}return a||++n!=i?a:(i=e==null?0:e.length,!!i&&ZG(i)&&JG(o,i)&&(QG(e)||XG(e)))}var rY=tY,nY=GG,iY=rY;function aY(e,t){return e!=null&&iY(e,t,nY)}
301var oY=aY,sY=bw,lY=OC,uY=oY,cY=Qb,dY=pN,fY=mN,hY=wp,pY=1,mY=2;function vY(e,t){return cY(e)&&dY(t)?fY(hY(e),t):function(r){var n=lY(r,e);return n===void 0&&n===t?uY(r,e):sY(t,n,pY|mY)}}var gY=vY;function yY(e){return e}var ol=yY;function bY(e){return function(t){return t==null?void 0:t[e]}}var wY=bY,xY=iw;function _Y(e){return function(t){return xY(t,e)}}var SY=_Y,OY=wY,EY=SY,kY=Qb,PY=wp;function AY(e){return kY(e)?OY(PY(e)):EY(e)}var jY=AY,TY=VG,CY=gY,NY=ol,$Y=Jt,RY=jY;function IY(e){return typeof e=="function"?e:e==null?NY:typeof e=="object"?$Y(e)?CY(e[0],e[1]):TY(e):RY(e)}var sl=IY;function MY(e,t,r,n){for(var i=e.length,a=r+(n?1:-1);n?a--:++a<i;)if(t(e[a],a,e))return a;return-1}var DY=MY;function LY(e){return e!==e}var BY=LY;function UY(e,t,r){for(var n=r-1,i=e.length;++n<i;)if(e[n]===t)return n;return-1}var FY=UY,zY=DY,WY=BY,qY=FY;function HY(e,t,r){return t===t?qY(e,t,r):zY(e,WY,r)}var VY=HY,KY=VY;function GY(e,t){var r=e==null?0:e.length;return!!r&&KY(e,t,0)>-1}var YY=GY;function XY(e,t,r){for(var n=-1,i=e==null?0:e.length;++n<i;)if(r(t,e[n]))return!0;return!1}var QY=XY;function JY(){}var ZY=JY,cv=dN,eX=ZY,tX=pw,rX=1/0,nX=cv&&1/tX(new cv([,-0]))[1]==rX?function(e){return new cv(e)}:eX,iX=nX,aX=tN,oX=YY,sX=QY,lX=nN,uX=iX,cX=pw,dX=200;function fX(e,t,r){var n=-1,i=oX,a=e.length,o=!0,s=[],l=s;if(r)o=!1,i=sX;else if(a>=dX){var u=t?null:uX(e);if(u)return cX(u);o=!1,i=lX,l=new aX}else l=t?[]:s;e:for(;++n<a;){var d=e[n],c=t?t(d):d;if(d=r||d!==0?d:0,o&&c===c){for(var f=l.length;f--;)if(l[f]===c)continue e;t&&l.push(c),s.push(d)}else i(l,c,r)||(l!==s&&l.push(c),s.push(d))}return s}var hX=fX,pX=sl,mX=hX;function vX(e,t){return e&&e.length?mX(e,pX(t)):[]}var gX=vX;const CS=Ce(gX);function vN(e,t,r){return t===!0?CS(e,r):fe(t)?CS(e,t):e}function Ss(e){"@babel/helpers - typeof";return Ss=typeof Symbol=="function"&&typeof Symbol.iterator=="symbol"?function(t){return typeof t}:function(t){return t&&typeof Symbol=="function"&&t.constructor===Symbol&&t!==Symbol.prototype?"symbol":typeof t},Ss(e)}var yX=["ref"];function NS(e,t){var r=Object.keys(e);if(Object.getOwnPropertySymbols){var n=Object.getOwnPropertySymbols(e);t&&(n=n.filter(function(i){return Object.getOwnPropertyDescriptor(e,i).enumerable})),r.push.apply(r,n)}return r}function Rn(e){for(var t=1;t<arguments.length;t++){var r=arguments[t]!=null?arguments[t]:{};t%2?NS(Object(r),!0).forEach(function(n){Dp(e,n,r[n])}):Object.getOwnPropertyDescriptors?Object.defineProperties(e,Object.getOwnPropertyDescriptors(r)):NS(Object(r)).forEach(function(n){Object.defineProperty(e,n,Object.getOwnPropertyDescriptor(r,n))})}return e}function bX(e,t){if(!(e instanceof t))throw new TypeError("Cannot call a class as a function")}function $S(e,t){for(var r=0;r<t.length;r++){var n=t[r];n.enumerable=n.enumerable||!1,n.configurable=!0,"value"in n&&(n.writable=!0),Object.defineProperty(e,yN(n.key),n)}}function wX(e,t,r){return t&&$S(e.prototype,t),r&&$S(e,r),Object.defineProperty(e,"prototype",{writable:!1}),e}function xX(e,t,r){return t=Wf(t),_X(e,gN()?Reflect.construct(t,r||[],Wf(e).constructor):t.apply(e,r))}function _X(e,t){if(t&&(Ss(t)==="object"||typeof t=="function"))return t;if(t!==void 0)throw new TypeError("Derived constructors may only return object or undefined");return SX(e)}function SX(e){if(e===void 0)throw new ReferenceError("this hasn't been initialised - super() hasn't been called");return e}function gN(){try{var e=!Boolean.prototype.valueOf.call(Reflect.construct(Boolean,[],function(){}))}catch{}return(gN=function(){return!!e})()}function Wf(e){return Wf=Object.setPrototypeOf?Object.getPrototypeOf.bind():function(r){return r.__proto__||Object.getPrototypeOf(r)},Wf(e)}function OX(e,t){if(typeof t!="function"&&t!==null)throw new TypeError("Super expression must either be null or a function");e.prototype=Object.create(t&&t.prototype,{constructor:{value:e,writable:!0,configurable:!0}}),Object.defineProperty(e,"prototype",{writable:!1}),t&&ky(e,t)}function ky(e,t){return ky=Object.setPrototypeOf?Object.setPrototypeOf.bind():function(n,i){return n.__proto__=i,n},ky(e,t)}function Dp(e,t,r){return t=yN(t),t in e?Object.defineProperty(e,t,{value:r,enumerable:!0,configurable:!0,writable:!0}):e[t]=r,e}function yN(e){var t=EX(e,"string");return Ss(t)=="symbol"?t:t+""}function EX(e,t){if(Ss(e)!="object"||!e)return e;var r=e[Symbol.toPrimitive];if(r!==void 0){var n=r.call(e,t||"default");if(Ss(n)!="object")return n;throw new TypeError("@@toPrimitive must return a primitive value.")}return(t==="string"?String:Number)(e)}function kX(e,t){if(e==null)return{};var r=PX(e,t),n,i;if(Object.getOwnPropertySymbols){var a=Object.getOwnPropertySymbols(e);for(i=0;i<a.length;i++)n=a[i],!(t.indexOf(n)>=0)&&Object.prototype.propertyIsEnumerable.call(e,n)&&(r[n]=e[n])}return r}function PX(e,t){if(e==null)return{};var r={};for(var n in e)if(Object.prototype.hasOwnProperty.call(e,n)){if(t.indexOf(n)>=0)continue;r[n]=e[n]}return r}function AX(e){return e.value}function jX(e,t){if(j.isValidElement(e))return j.cloneElement(e,t);if(typeof e=="function")return j.createElement(e,t);t.ref;var r=kX(t,yX);return j.createElement(hw,r)}var RS=1,Zo=function(e){function t(){var r;bX(this,t);for(var n=arguments.length,i=new Array(n),a=0;a<n;a++)i[a]=arguments[a];return r=xX(this,t,[].concat(i)),Dp(r,"lastBoundingBox",{width:-1,height:-1}),r}
vendor: 38,296 bytes, lines 301-309
301return OX(t,e),wX(t,[{key:"componentDidMount",value:function(){this.updateBBox()}},{key:"componentDidUpdate",value:function(){this.updateBBox()}},{key:"getBBox",value:function(){if(this.wrapperNode&&this.wrapperNode.getBoundingClientRect){var n=this.wrapperNode.getBoundingClientRect();return n.height=this.wrapperNode.offsetHeight,n.width=this.wrapperNode.offsetWidth,n}return null}},{key:"updateBBox",value:function(){var n=this.props.onBBoxUpdate,i=this.getBBox();i?(Math.abs(i.width-this.lastBoundingBox.width)>RS||Math.abs(i.height-this.lastBoundingBox.height)>RS)&&(this.lastBoundingBox.width=i.width,this.lastBoundingBox.height=i.height,n&&n(i)):(this.lastBoundingBox.width!==-1||this.lastBoundingBox.height!==-1)&&(this.lastBoundingBox.width=-1,this.lastBoundingBox.height=-1,n&&n(null))}},{key:"getBBoxSnapshot",value:function(){return this.lastBoundingBox.width>=0&&this.lastBoundingBox.height>=0?Rn({},this.lastBoundingBox):{width:0,height:0}}},{key:"getDefaultPosition",value:function(n){var i=this.props,a=i.layout,o=i.align,s=i.verticalAlign,l=i.margin,u=i.chartWidth,d=i.chartHeight,c,f;if(!n||(n.left===void 0||n.left===null)&&(n.right===void 0||n.right===null))if(o==="center"&&a==="vertical"){var h=this.getBBoxSnapshot();c={left:((u||0)-h.width)/2}}else c=o==="right"?{right:l&&l.right||0}:{left:l&&l.left||0};if(!n||(n.top===void 0||n.top===null)&&(n.bottom===void 0||n.bottom===null))if(s==="middle"){var v=this.getBBoxSnapshot();f={top:((d||0)-v.height)/2}}else f=s==="bottom"?{bottom:l&&l.bottom||0}:{top:l&&l.top||0};return Rn(Rn({},c),f)}},{key:"render",value:function(){var n=this,i=this.props,a=i.content,o=i.width,s=i.height,l=i.wrapperStyle,u=i.payloadUniqBy,d=i.payload,c=Rn(Rn({position:"absolute",width:o||"auto",height:s||"auto"},this.getDefaultPosition(l)),l);return j.createElement("div",{className:"recharts-legend-wrapper",style:c,ref:function(h){n.wrapperNode=h}},jX(a,Rn(Rn({},this.props),{},{payload:vN(d,u,AX)})))}}],[{key:"getWithHeight",value:function(n,i){var a=Rn(Rn({},this.defaultProps),n.props),o=a.layout;return o==="vertical"&&Y(n.props.height)?{height:n.props.height}:o==="horizontal"?{width:n.props.width||i}:null}}])}(O.PureComponent);Dp(Zo,"displayName","Legend");Dp(Zo,"defaultProps",{iconSize:14,layout:"horizontal",align:"center",verticalAlign:"bottom"});var IS=Pc,TX=mw,CX=Jt,MS=IS?IS.isConcatSpreadable:void 0;function NX(e){return CX(e)||TX(e)||!!(MS&&e&&e[MS])}var $X=NX,RX=aN,IX=$X;function bN(e,t,r,n,i){var a=-1,o=e.length;for(r||(r=IX),i||(i=[]);++a<o;){var s=e[a];t>0&&r(s)?t>1?bN(s,t-1,r,n,i):RX(i,s):n||(i[i.length]=s)}return i}var wN=bN;function MX(e){return function(t,r,n){for(var i=-1,a=Object(t),o=n(t),s=o.length;s--;){var l=o[e?s:++i];if(r(a[l],l,a)===!1)break}return t}}var DX=MX,LX=DX,BX=LX(),UX=BX,FX=UX,zX=yw;function WX(e,t){return e&&FX(e,t,zX)}var xN=WX,qX=Mp;function HX(e,t){return function(r,n){if(r==null)return r;if(!qX(r))return e(r,n);for(var i=r.length,a=t?i:-1,o=Object(r);(t?a--:++a<i)&&n(o[a],a,o)!==!1;);return r}}var VX=HX,KX=xN,GX=VX,YX=GX(KX),ww=YX,XX=ww,QX=Mp;function JX(e,t){var r=-1,n=QX(e)?Array(e.length):[];return XX(e,function(i,a,o){n[++r]=t(i,a,o)}),n}var _N=JX;function ZX(e,t){var r=e.length;for(e.sort(t);r--;)e[r]=e[r].value;return e}var eQ=ZX,DS=Zs;function tQ(e,t){if(e!==t){var r=e!==void 0,n=e===null,i=e===e,a=DS(e),o=t!==void 0,s=t===null,l=t===t,u=DS(t);if(!s&&!u&&!a&&e>t||a&&o&&l&&!s&&!u||n&&o&&l||!r&&l||!i)return 1;if(!n&&!a&&!u&&e<t||u&&r&&i&&!n&&!a||s&&r&&i||!o&&i||!l)return-1}return 0}var rQ=tQ,nQ=rQ;function iQ(e,t,r){for(var n=-1,i=e.criteria,a=t.criteria,o=i.length,s=r.length;++n<o;){var l=nQ(i[n],a[n]);if(l){if(n>=s)return l;var u=r[n];return l*(u=="desc"?-1:1)}}return e.index-t.index}var aQ=iQ,dv=nw,oQ=iw,sQ=sl,lQ=_N,uQ=eQ,cQ=lN,dQ=aQ,fQ=ol,hQ=Jt;function pQ(e,t,r){t.length?t=dv(t,function(a){return hQ(a)?function(o){return oQ(o,a.length===1?a[0]:a)}:a}):t=[fQ];var n=-1;t=dv(t,cQ(sQ));var i=lQ(e,function(a,o,s){var l=dv(t,function(u){return u(a)});return{criteria:l,index:++n,value:a}});return uQ(i,function(a,o){return dQ(a,o,r)})}var mQ=pQ;function vQ(e,t,r){switch(r.length){case 0:return e.call(t);case 1:return e.call(t,r[0]);case 2:return e.call(t,r[0],r[1]);case 3:return e.call(t,r[0],r[1],r[2])}return e.apply(t,r)}var gQ=vQ,yQ=gQ,LS=Math.max;function bQ(e,t,r){return t=LS(t===void 0?e.length-1:t,0),function(){for(var n=arguments,i=-1,a=LS(n.length-t,0),o=Array(a);++i<a;)o[i]=n[t+i];i=-1;for(var s=Array(t+1);++i<t;)s[i]=n[i];return s[t]=r(o),yQ(e,this,s)}}var wQ=bQ;function xQ(e){return function(){return e}}var _Q=xQ,SQ=ro,OQ=function(){try{var e=SQ(Object,"defineProperty");return e({},"",{}),e}catch{}}(),SN=OQ,EQ=_Q,BS=SN,kQ=ol,PQ=BS?function(e,t){return BS(e,"toString",{configurable:!0,enumerable:!1,value:EQ(t),writable:!0})}:kQ,AQ=PQ,jQ=800,TQ=16,CQ=Date.now;function NQ(e){var t=0,r=0;return function(){var n=CQ(),i=TQ-(n-r);if(r=n,i>0){if(++t>=jQ)return arguments[0]}else t=0;return e.apply(void 0,arguments)}}var $Q=NQ,RQ=AQ,IQ=$Q,MQ=IQ(RQ),DQ=MQ,LQ=ol,BQ=wQ,UQ=DQ;function FQ(e,t){return UQ(BQ(e,t,LQ),e+"")}var zQ=FQ,WQ=Zb,qQ=Mp,HQ=vw,VQ=ta;function KQ(e,t,r){if(!VQ(r))return!1;var n=typeof t;return(n=="number"?qQ(r)&&HQ(t,r.length):n=="string"&&t in r)?WQ(r[t],e):!1}var Lp=KQ,GQ=wN,YQ=mQ,XQ=zQ,US=Lp,QQ=XQ(function(e,t){if(e==null)return[];var r=t.length;return r>1&&US(e,t[0],t[1])?t=[]:r>2&&US(t[0],t[1],t[2])&&(t=[t[0]]),YQ(e,GQ(t,1),[])}),JQ=QQ;const xw=Ce(JQ);function Ru(e){"@babel/helpers - typeof";return Ru=typeof Symbol=="function"&&typeof Symbol.iterator=="symbol"?function(t){return typeof t}:function(t){return t&&typeof Symbol=="function"&&t.constructor===Symbol&&t!==Symbol.prototype?"symbol":typeof t},Ru(e)}function Py(){return Py=Object.assign?Object.assign.bind():function(e){for(var t=1;t<arguments.length;t++){var r=arguments[t];for(var n in r)Object.prototype.hasOwnProperty.call(r,n)&&(e[n]=r[n])}return e},Py.apply(this,arguments)}function ZQ(e,t){return nJ(e)||rJ(e,t)||tJ(e,t)||eJ()}function eJ(){throw new TypeError(`Invalid attempt to destructure non-iterable instance. 302In order to be iterable, non-array objects must have a [Symbol.iterator]() method.`)}function tJ(e,t){if(e){if(typeof e=="string")return FS(e,t);var r=Object.prototype.toString.call(e).slice(8,-1);if(r==="Object"&&e.constructor&&(r=e.constructor.name),r==="Map"||r==="Set")return Array.from(e);if(r==="Arguments"||/^(?:Ui|I)nt(?:8|16|32)(?:Clamped)?Array$/.test(r))return FS(e,t)}}function FS(e,t){(t==null||t>e.length)&&(t=e.length);for(var r=0,n=new Array(t);r<t;r++)n[r]=e[r];return n}function rJ(e,t){var r=e==null?null:typeof Symbol<"u"&&e[Symbol.iterator]||e["@@iterator"];if(r!=null){var n,i,a,o,s=[],l=!0,u=!1;try{if(a=(r=r.call(e)).next,t!==0)for(;!(l=(n=a.call(r)).done)&&(s.push(n.value),s.length!==t);l=!0);}catch(d){u=!0,i=d}finally{try{if(!l&&r.return!=null&&(o=r.return(),Object(o)!==o))return}finally{if(u)throw i}}return s}}function nJ(e){if(Array.isArray(e))return e}function zS(e,t){var r=Object.keys(e);if(Object.getOwnPropertySymbols){var n=Object.getOwnPropertySymbols(e);t&&(n=n.filter(function(i){return Object.getOwnPropertyDescriptor(e,i).enumerable})),r.push.apply(r,n)}return r}function fv(e){for(var t=1;t<arguments.length;t++){var r=arguments[t]!=null?arguments[t]:{};t%2?zS(Object(r),!0).forEach(function(n){iJ(e,n,r[n])}):Object.getOwnPropertyDescriptors?Object.defineProperties(e,Object.getOwnPropertyDescriptors(r)):zS(Object(r)).forEach(function(n){Object.defineProperty(e,n,Object.getOwnPropertyDescriptor(r,n))})}return e}function iJ(e,t,r){return t=aJ(t),t in e?Object.defineProperty(e,t,{value:r,enumerable:!0,configurable:!0,writable:!0}):e[t]=r,e}function aJ(e){var t=oJ(e,"string");return Ru(t)=="symbol"?t:t+""}function oJ(e,t){if(Ru(e)!="object"||!e)return e;var r=e[Symbol.toPrimitive];if(r!==void 0){var n=r.call(e,t||"default");if(Ru(n)!="object")return n;throw new TypeError("@@toPrimitive must return a primitive value.")}return(t==="string"?String:Number)(e)}function sJ(e){return Array.isArray(e)&&ct(e[0])&&ct(e[1])?e.join(" ~ "):e}var lJ=function(t){var r=t.separator,n=r===void 0?" : ":r,i=t.contentStyle,a=i===void 0?{}:i,o=t.itemStyle,s=o===void 0?{}:o,l=t.labelStyle,u=l===void 0?{}:l,d=t.payload,c=t.formatter,f=t.itemSorter,h=t.wrapperClassName,v=t.labelClassName,m=t.label,g=t.labelFormatter,y=t.accessibilityLayer,b=y===void 0?!1:y,w=function(){if(d&&d.length){var $={padding:0,margin:0},D=(f?xw(d,f):d).map(function(I,R){if(I.type==="none")return null;var M=fv({display:"block",paddingTop:4,paddingBottom:4,color:I.color||"#000"},s),L=I.formatter||c||sJ,A=I.value,T=I.name,U=A,q=T;if(L&&U!=null&&q!=null){var B=L(A,T,I,R,d);if(Array.isArray(B)){var W=ZQ(B,2);U=W[0],q=W[1]}else U=B}return j.createElement("li",{className:"recharts-tooltip-item",key:"tooltip-item-".concat(R),style:M},ct(q)?j.createElement("span",{className:"recharts-tooltip-item-name"},q):null,ct(q)?j.createElement("span",{className:"recharts-tooltip-item-separator"},n):null,j.createElement("span",{className:"recharts-tooltip-item-value"},U),j.createElement("span",{className:"recharts-tooltip-item-unit"},I.unit||""))});return j.createElement("ul",{className:"recharts-tooltip-item-list",style:$},D)}return null},_=fv({margin:0,padding:10,backgroundColor:"#fff",border:"1px solid #ccc",whiteSpace:"nowrap"},a),x=fv({margin:0},u),S=!we(m),E=S?m:"",k=pe("recharts-default-tooltip",h),P=pe("recharts-tooltip-label",v);S&&g&&d!==void 0&&d!==null&&(E=g(m,d));var C=b?{role:"status","aria-live":"assertive"}:{};return j.createElement("div",Py({className:k,style:_},C),j.createElement("p",{className:P,style:x},j.isValidElement(E)?E:"".concat(E)),w())};function Iu(e){"@babel/helpers - typeof";return Iu=typeof Symbol=="function"&&typeof Symbol.iterator=="symbol"?function(t){return typeof t}:function(t){return t&&typeof Symbol=="function"&&t.constructor===Symbol&&t!==Symbol.prototype?"symbol":typeof t},Iu(e)}function vd(e,t,r){return t=uJ(t),t in e?Object.defineProperty(e,t,{value:r,enumerable:!0,configurable:!0,writable:!0}):e[t]=r,e}function uJ(e){var t=cJ(e,"string");return Iu(t)=="symbol"?t:t+""}function cJ(e,t){if(Iu(e)!="object"||!e)return e;var r=e[Symbol.toPrimitive];if(r!==void 0){var n=r.call(e,t||"default");if(Iu(n)!="object")return n;throw new TypeError("@@toPrimitive must return a primitive value.")}return(t==="string"?String:Number)(e)}var Sl="recharts-tooltip-wrapper",dJ={visibility:"hidden"};function fJ(e){var t=e.coordinate,r=e.translateX,n=e.translateY;return pe(Sl,vd(vd(vd(vd({},"".concat(Sl,"-right"),Y(r)&&t&&Y(t.x)&&r>=t.x),"".concat(Sl,"-left"),Y(r)&&t&&Y(t.x)&&r<t.x),"".concat(Sl,"-bottom"),Y(n)&&t&&Y(t.y)&&n>=t.y),"".concat(Sl,"-top"),Y(n)&&t&&Y(t.y)&&n<t.y))}function WS(e){var t=e.allowEscapeViewBox,r=e.coordinate,n=e.key,i=e.offsetTopLeft,a=e.position,o=e.reverseDirection,s=e.tooltipDimension,l=e.viewBox,u=e.viewBoxDimension;if(a&&Y(a[n]))return a[n];var d=r[n]-s-i,c=r[n]+i;if(t[n])return o[n]?d:c;if(o[n]){var f=d,h=l[n];return f<h?Math.max(c,l[n]):Math.max(d,l[n])}var v=c+s,m=l[n]+u;return v>m?Math.max(d,l[n]):Math.max(c,l[n])}function hJ(e){var t=e.translateX,r=e.translateY,n=e.useTranslate3d;return{transform:n?"translate3d(".concat(t,"px, ").concat(r,"px, 0)"):"translate(".concat(t,"px, ").concat(r,"px)")}}function pJ(e){var t=e.allowEscapeViewBox,r=e.coordinate,n=e.offsetTopLeft,i=e.position,a=e.reverseDirection,o=e.tooltipBox,s=e.useTranslate3d,l=e.viewBox,u,d,c;return o.height>0&&o.width>0&&r?(d=WS({allowEscapeViewBox:t,coordinate:r,key:"x",offsetTopLeft:n,position:i,reverseDirection:a,tooltipDimension:o.width,viewBox:l,viewBoxDimension:l.width}),c=WS({allowEscapeViewBox:t,coordinate:r,key:"y",offsetTopLeft:n,position:i,reverseDirection:a,tooltipDimension:o.height,viewBox:l,viewBoxDimension:l.height}),u=hJ({translateX:d,translateY:c,useTranslate3d:s})):u=dJ,{cssProperties:u,cssClasses:fJ({translateX:d,translateY:c,coordinate:r})}}function Os(e){"@babel/helpers - typeof";return Os=typeof Symbol=="function"&&typeof Symbol.iterator=="symbol"?function(t){return typeof t}:function(t){return t&&typeof Symbol=="function"&&t.constructor===Symbol&&t!==Symbol.prototype?"symbol":typeof t},Os(e)}function qS(e,t){var r=Object.keys(e);if(Object.getOwnPropertySymbols){var n=Object.getOwnPropertySymbols(e);t&&(n=n.filter(function(i){return Object.getOwnPropertyDescriptor(e,i).enumerable})),r.push.apply(r,n)}return r}function HS(e){for(var t=1;t<arguments.length;t++){var r=arguments[t]!=null?arguments[t]:{};t%2?qS(Object(r),!0).forEach(function(n){jy(e,n,r[n])}):Object.getOwnPropertyDescriptors?Object.defineProperties(e,Object.getOwnPropertyDescriptors(r)):qS(Object(r)).forEach(function(n){Object.defineProperty(e,n,Object.getOwnPropertyDescriptor(r,n))})}return e}function mJ(e,t){if(!(e instanceof t))throw new TypeError("Cannot call a class as a function")}function vJ(e,t){for(var r=0;r<t.length;r++){var n=t[r];n.enumerable=n.enumerable||!1,n.configurable=!0,"value"in n&&(n.writable=!0),Object.defineProperty(e,EN(n.key),n)}}function gJ(e,t,r){return t&&vJ(e.prototype,t),Object.defineProperty(e,"prototype",{writable:!1}),e}function yJ(e,t,r){return t=qf(t),bJ(e,ON()?Reflect.construct(t,r||[],qf(e).constructor):t.apply(e,r))}function bJ(e,t){if(t&&(Os(t)==="object"||typeof t=="function"))return t;if(t!==void 0)throw new TypeError("Derived constructors may only return object or undefined");return wJ(e)}function wJ(e){if(e===void 0)throw new ReferenceError("this hasn't been initialised - super() hasn't been called");return e}function ON(){try{var e=!Boolean.prototype.valueOf.call(Reflect.construct(Boolean,[],function(){}))}catch{}return(ON=function(){return!!e})()}function qf(e){return qf=Object.setPrototypeOf?Object.getPrototypeOf.bind():function(r){return r.__proto__||Object.getPrototypeOf(r)},qf(e)}function xJ(e,t){if(typeof t!="function"&&t!==null)throw new TypeError("Super expression must either be null or a function");e.prototype=Object.create(t&&t.prototype,{constructor:{value:e,writable:!0,configurable:!0}}),Object.defineProperty(e,"prototype",{writable:!1}),t&&Ay(e,t)}function Ay(e,t){return Ay=Object.setPrototypeOf?Object.setPrototypeOf.bind():function(n,i){return n.__proto__=i,n},Ay(e,t)}function jy(e,t,r){return t=EN(t),t in e?Object.defineProperty(e,t,{value:r,enumerable:!0,configurable:!0,writable:!0}):e[t]=r,e}function EN(e){var t=_J(e,"string");return Os(t)=="symbol"?t:t+""}function _J(e,t){if(Os(e)!="object"||!e)return e;var r=e[Symbol.toPrimitive];if(r!==void 0){var n=r.call(e,t||"default");if(Os(n)!="object")return n;throw new TypeError("@@toPrimitive must return a primitive value.")}return(t==="string"?String:Number)(e)}var VS=1,SJ=function(e){function t(){var r;mJ(this,t);for(var n=arguments.length,i=new Array(n),a=0;a<n;a++)i[a]=arguments[a];return r=yJ(this,t,[].concat(i)),jy(r,"state",{dismissed:!1,dismissedAtCoordinate:{x:0,y:0},lastBoundingBox:{width:-1,height:-1}}),jy(r,"handleKeyDown",function(o){if(o.key==="Escape"){var s,l,u,d;r.setState({dismissed:!0,dismissedAtCoordinate:{x:(s=(l=r.props.coordinate)===null||l===void 0?void 0:l.x)!==null&&s!==void 0?s:0,y:(u=(d=r.props.coordinate)===null||d===void 0?void 0:d.y)!==null&&u!==void 0?u:0}})}}),r}return xJ(t,e),gJ(t,[{key:"updateBBox",value:function(){if(this.wrapperNode&&this.wrapperNode.getBoundingClientRect){var n=this.wrapperNode.getBoundingClientRect();(Math.abs(n.width-this.state.lastBoundingBox.width)>VS||Math.abs(n.height-this.state.lastBoundingBox.height)>VS)&&this.setState({lastBoundingBox:{width:n.width,height:n.height}})}else(this.state.lastBoundingBox.width!==-1||this.state.lastBoundingBox.height!==-1)&&this.setState({lastBoundingBox:{width:-1,height:-1}})}},{key:"componentDidMount",value:function(){document.addEventListener("keydown",this.handleKeyDown),this.updateBBox()}},{key:"componentWillUnmount",value:function(){document.removeEventListener("keydown",this.handleKeyDown)}},{key:"componentDidUpdate",value:function(){var n,i;this.props.active&&this.updateBBox(),this.state.dismissed&&(((n=this.props.coordinate)===null||n===void 0?void 0:n.x)!==this.state.dismissedAtCoordinate.x||((i=this.props.coordinate)===null||i===void 0?void 0:i.y)!==this.state.dismissedAtCoordinate.y)&&(this.state.dismissed=!1)}},{key:"render",value:function(){var n=this,i=this.props,a=i.active,o=i.allowEscapeViewBox,s=i.animationDuration,l=i.animationEasing,u=i.children,d=i.coordinate,c=i.hasPayload,f=i.isAnimationActive,h=i.offset,v=i.position,m=i.reverseDirection,g=i.useTranslate3d,y=i.viewBox,b=i.wrapperStyle,w=pJ({allowEscapeViewBox:o,coordinate:d,offsetTopLeft:h,position:v,reverseDirection:m,tooltipBox:this.state.lastBoundingBox,useTranslate3d:g,viewBox:y}),_=w.cssClasses,x=w.cssProperties,S=HS(HS({transition:f&&a?"transform ".concat(s,"ms ").concat(l):void 0},x),{},{pointerEvents:"none",visibility:!this.state.dismissed&&a&&c?"visible":"hidden",position:"absolute",top:0,left:0},b);return j.createElement("div",{tabIndex:-1,className:_,style:S,ref:function(k){n.wrapperNode=k}},u)}}])}(O.PureComponent),OJ=function(){return!(typeof window<"u"&&window.document&&window.document.createElement&&window.setTimeout)},zi={isSsr:OJ(),get:function(t){return zi[t]},set:function(t,r){if(typeof t=="string")zi[t]=r;else{var n=Object.keys(t);n&&n.length&&n.forEach(function(i){zi[i]=t[i]})}}};function Es(e){"@babel/helpers - typeof";return Es=typeof Symbol=="function"&&typeof Symbol.iterator=="symbol"?function(t){return typeof t}:function(t){return t&&typeof Symbol=="function"&&t.constructor===Symbol&&t!==Symbol.prototype?"symbol":typeof t},Es(e)}function KS(e,t){var r=Object.keys(e);if(Object.getOwnPropertySymbols){var n=Object.getOwnPropertySymbols(e);t&&(n=n.filter(function(i){return Object.getOwnPropertyDescriptor(e,i).enumerable})),r.push.apply(r,n)}return r}function GS(e){for(var t=1;t<arguments.length;t++){var r=arguments[t]!=null?arguments[t]:{};t%2?KS(Object(r),!0).forEach(function(n){_w(e,n,r[n])}):Object.getOwnPropertyDescriptors?Object.defineProperties(e,Object.getOwnPropertyDescriptors(r)):KS(Object(r)).forEach(function(n){Object.defineProperty(e,n,Object.getOwnPropertyDescriptor(r,n))})}return e}function EJ(e,t){if(!(e instanceof t))throw new TypeError("Cannot call a class as a function")}function kJ(e,t){for(var r=0;r<t.length;r++){var n=t[r];n.enumerable=n.enumerable||!1,n.configurable=!0,"value"in n&&(n.writable=!0),Object.defineProperty(e,PN(n.key),n)}}function PJ(e,t,r){return t&&kJ(e.prototype,t),Object.defineProperty(e,"prototype",{writable:!1}),e}function AJ(e,t,r){return t=Hf(t),jJ(e,kN()?Reflect.construct(t,r||[],Hf(e).constructor):t.apply(e,r))}function jJ(e,t){if(t&&(Es(t)==="object"||typeof t=="function"))return t;if(t!==void 0)throw new TypeError("Derived constructors may only return object or undefined");return TJ(e)}function TJ(e){if(e===void 0)throw new ReferenceError("this hasn't been initialised - super() hasn't been called");return e}function kN(){try{var e=!Boolean.prototype.valueOf.call(Reflect.construct(Boolean,[],function(){}))}catch{}return(kN=function(){return!!e})()}function Hf(e){return Hf=Object.setPrototypeOf?Object.getPrototypeOf.bind():function(r){return r.__proto__||Object.getPrototypeOf(r)},Hf(e)}function CJ(e,t){if(typeof t!="function"&&t!==null)throw new TypeError("Super expression must either be null or a function");e.prototype=Object.create(t&&t.prototype,{constructor:{value:e,writable:!0,configurable:!0}}),Object.defineProperty(e,"prototype",{writable:!1}),t&&Ty(e,t)}function Ty(e,t){return Ty=Object.setPrototypeOf?Object.setPrototypeOf.bind():function(n,i){return n.__proto__=i,n},Ty(e,t)}function _w(e,t,r){return t=PN(t),t in e?Object.defineProperty(e,t,{value:r,enumerable:!0,configurable:!0,writable:!0}):e[t]=r,e}function PN(e){var t=NJ(e,"string");return Es(t)=="symbol"?t:t+""}function NJ(e,t){if(Es(e)!="object"||!e)return e;var r=e[Symbol.toPrimitive];if(r!==void 0){var n=r.call(e,t||"default");if(Es(n)!="object")return n;throw new TypeError("@@toPrimitive must return a primitive value.")}return(t==="string"?String:Number)(e)}function $J(e){return e.dataKey}function RJ(e,t){return j.isValidElement(e)?j.cloneElement(e,t):typeof e=="function"?j.createElement(e,t):j.createElement(lJ,t)}var hn=function(e){function t(){return EJ(this,t),AJ(this,t,arguments)}return CJ(t,e),PJ(t,[{key:"render",value:function(){var n=this,i=this.props,a=i.active,o=i.allowEscapeViewBox,s=i.animationDuration,l=i.animationEasing,u=i.content,d=i.coordinate,c=i.filterNull,f=i.isAnimationActive,h=i.offset,v=i.payload,m=i.payloadUniqBy,g=i.position,y=i.reverseDirection,b=i.useTranslate3d,w=i.viewBox,_=i.wrapperStyle,x=v??[];c&&x.length&&(x=vN(v.filter(function(E){return E.value!=null&&(E.hide!==!0||n.props.includeHidden)}),m,$J));var S=x.length>0;return j.createElement(SJ,{allowEscapeViewBox:o,animationDuration:s,animationEasing:l,isAnimationActive:f,active:a,coordinate:d,hasPayload:S,offset:h,position:g,reverseDirection:y,useTranslate3d:b,viewBox:w,wrapperStyle:_},RJ(u,GS(GS({},this.props),{},{payload:x})))}}])}(O.PureComponent);_w(hn,"displayName","Tooltip");_w(hn,"defaultProps",{accessibilityLayer:!1,allowEscapeViewBox:{x:!1,y:!1},animationDuration:400,animationEasing:"ease",contentStyle:{},coordinate:{x:0,y:0},cursor:!0,cursorStyle:{},filterNull:!0,isAnimationActive:!zi.isSsr,itemStyle:{},labelStyle:{},offset:10,reverseDirection:{x:!1,y:!1},separator:" : ",trigger:"hover",useTranslate3d:!1,viewBox:{x:0,y:0,height:0,width:0},wrapperStyle:{}});var IJ=Nn,MJ=function(){return IJ.Date.now()},DJ=MJ,LJ=/\s/;function BJ(e){for(var t=e.length;t--&&LJ.test(e.charAt(t)););return t}var UJ=BJ,FJ=UJ,zJ=/^\s+/;function WJ(e){return e&&e.slice(0,FJ(e)+1).replace(zJ,"")}var qJ=WJ,HJ=qJ,YS=ta,VJ=Zs,XS=NaN,KJ=/^[-+]0x[0-9a-f]+$/i,GJ=/^0b[01]+$/i,YJ=/^0o[0-7]+$/i,XJ=parseInt;function QJ(e){if(typeof e=="number")return e;if(VJ(e))return XS;if(YS(e)){var t=typeof e.valueOf=="function"?e.valueOf():e;e=YS(t)?t+"":t}if(typeof e!="string")return e===0?e:+e;e=HJ(e);var r=GJ.test(e);return r||YJ.test(e)?XJ(e.slice(2),r?2:8):KJ.test(e)?XS:+e}var AN=QJ,JJ=ta,hv=DJ,QS=AN,ZJ="Expected a function",eZ=Math.max,tZ=Math.min;function rZ(e,t,r){var n,i,a,o,s,l,u=0,d=!1,c=!1,f=!0;if(typeof e!="function")throw new TypeError(ZJ);t=QS(t)||0,JJ(r)&&(d=!!r.leading,c="maxWait"in r,a=c?eZ(QS(r.maxWait)||0,t):a,f="trailing"in r?!!r.trailing:f);function h(S){var E=n,k=i;return n=i=void 0,u=S,o=e.apply(k,E),o}function v(S){return u=S,s=setTimeout(y,t),d?h(S):o}function m(S){var E=S-l,k=S-u,P=t-E;return c?tZ(P,a-k):P}function g(S){var E=S-l,k=S-u;return l===void 0||E>=t||E<0||c&&k>=a}function y(){var S=hv();if(g(S))return b(S);s=setTimeout(y,m(S))}function b(S){return s=void 0,f&&n?h(S):(n=i=void 0,o)}function w(){s!==void 0&&clearTimeout(s),u=0,n=l=i=s=void 0}function _(){return s===void 0?o:b(hv())}function x(){var S=hv(),E=g(S);if(n=arguments,i=this,l=S,E){if(s===void 0)return v(l);if(c)return clearTimeout(s),s=setTimeout(y,t),h(l)}return s===void 0&&(s=setTimeout(y,t)),o}return x.cancel=w,x.flush=_,x}var nZ=rZ,iZ=nZ,aZ=ta,oZ="Expected a function";function sZ(e,t,r){var n=!0,i=!0;if(typeof e!="function")throw new TypeError(oZ);return aZ(r)&&(n="leading"in r?!!r.leading:n,i="trailing"in r?!!r.trailing:i),iZ(e,t,{leading:n,maxWait:t,trailing:i})}var lZ=sZ;const jN=Ce(lZ);function Mu(e){"@babel/helpers - typeof";return Mu=typeof Symbol=="function"&&typeof Symbol.iterator=="symbol"?function(t){return typeof t}:function(t){return t&&typeof Symbol=="function"&&t.constructor===Symbol&&t!==Symbol.prototype?"symbol":typeof t},Mu(e)}function JS(e,t){var r=Object.keys(e);if(Object.getOwnPropertySymbols){var n=Object.getOwnPropertySymbols(e);t&&(n=n.filter(function(i){return Object.getOwnPropertyDescriptor(e,i).enumerable})),r.push.apply(r,n)}return r}function gd(e){for(var t=1;t<arguments.length;t++){var r=arguments[t]!=null?arguments[t]:{};t%2?JS(Object(r),!0).forEach(function(n){uZ(e,n,r[n])}):Object.getOwnPropertyDescriptors?Object.defineProperties(e,Object.getOwnPropertyDescriptors(r)):JS(Object(r)).forEach(function(n){Object.defineProperty(e,n,Object.getOwnPropertyDescriptor(r,n))})}return e}function uZ(e,t,r){return t=cZ(t),t in e?Object.defineProperty(e,t,{value:r,enumerable:!0,configurable:!0,writable:!0}):e[t]=r,e}function cZ(e){var t=dZ(e,"string");return Mu(t)=="symbol"?t:t+""}function dZ(e,t){if(Mu(e)!="object"||!e)return e;var r=e[Symbol.toPrimitive];if(r!==void 0){var n=r.call(e,t||"default");if(Mu(n)!="object")return n;throw new TypeError("@@toPrimitive must return a primitive value.")}return(t==="string"?String:Number)(e)}function fZ(e,t){return vZ(e)||mZ(e,t)||pZ(e,t)||hZ()}function hZ(){throw new TypeError(`Invalid attempt to destructure non-iterable instance. 303In order to be iterable, non-array objects must have a [Symbol.iterator]() method.`)}function pZ(e,t){if(e){if(typeof e=="string")return ZS(e,t);var r=Object.prototype.toString.call(e).slice(8,-1);if(r==="Object"&&e.constructor&&(r=e.constructor.name),r==="Map"||r==="Set")return Array.from(e);if(r==="Arguments"||/^(?:Ui|I)nt(?:8|16|32)(?:Clamped)?Array$/.test(r))return ZS(e,t)}}function ZS(e,t){(t==null||t>e.length)&&(t=e.length);for(var r=0,n=new Array(t);r<t;r++)n[r]=e[r];return n}function mZ(e,t){var r=e==null?null:typeof Symbol<"u"&&e[Symbol.iterator]||e["@@iterator"];if(r!=null){var n,i,a,o,s=[],l=!0,u=!1;try{if(a=(r=r.call(e)).next,t!==0)for(;!(l=(n=a.call(r)).done)&&(s.push(n.value),s.length!==t);l=!0);}catch(d){u=!0,i=d}finally{try{if(!l&&r.return!=null&&(o=r.return(),Object(o)!==o))return}finally{if(u)throw i}}return s}}function vZ(e){if(Array.isArray(e))return e}var gZ=O.forwardRef(function(e,t){var r=e.aspect,n=e.initialDimension,i=n===void 0?{width:-1,height:-1}:n,a=e.width,o=a===void 0?"100%":a,s=e.height,l=s===void 0?"100%":s,u=e.minWidth,d=u===void 0?0:u,c=e.minHeight,f=e.maxHeight,h=e.children,v=e.debounce,m=v===void 0?0:v,g=e.id,y=e.className,b=e.onResize,w=e.style,_=w===void 0?{}:w,x=O.useRef(null),S=O.useRef();S.current=b,O.useImperativeHandle(t,function(){return Object.defineProperty(x.current,"current",{get:function(){return console.warn("The usage of ref.current.current is deprecated and will no longer be supported."),x.current},configurable:!0})});var E=O.useState({containerWidth:i.width,containerHeight:i.height}),k=fZ(E,2),P=k[0],C=k[1],N=O.useCallback(function(D,I){C(function(R){var M=Math.round(D),L=Math.round(I);return R.containerWidth===M&&R.containerHeight===L?R:{containerWidth:M,containerHeight:L}})},[]);O.useEffect(function(){var D=function(T){var U,q=T[0].contentRect,B=q.width,W=q.height;N(B,W),(U=S.current)===null||U===void 0||U.call(S,B,W)};m>0&&(D=jN(D,m,{trailing:!0,leading:!1}));var I=new ResizeObserver(D),R=x.current.getBoundingClientRect(),M=R.width,L=R.height;return N(M,L),I.observe(x.current),function(){I.disconnect()}},[N,m]);var $=O.useMemo(function(){var D=P.containerWidth,I=P.containerHeight;if(D<0||I<0)return null;Da(Sa(o)||Sa(l),`The width(%s) and height(%s) are both fixed numbers, 304 maybe you don't need to use a ResponsiveContainer.`,o,l),Da(!r||r>0,"The aspect(%s) must be greater than zero.",r);var R=Sa(o)?D:o,M=Sa(l)?I:l;r&&r>0&&(R?M=R/r:M&&(R=M*r),f&&M>f&&(M=f)),Da(R>0||M>0,`The width(%s) and height(%s) of chart should be greater than 0, 305 please check the style of container, or the props width(%s) and height(%s), 306 or add a minWidth(%s) or minHeight(%s) or use aspect(%s) to control the 307 height and width.`,R,M,o,l,d,c,r);var L=!Array.isArray(h)&&Hn(h.type).endsWith("Chart");return j.Children.map(h,function(A){return j.isValidElement(A)?O.cloneElement(A,gd({width:R,height:M},L?{style:gd({height:"100%",width:"100%",maxHeight:M,maxWidth:R},A.props.style)}:{})):A})},[r,h,l,f,c,d,P,o]);return j.createElement("div",{id:g?"".concat(g):void 0,className:pe("recharts-responsive-container",y),style:gd(gd({},_),{},{width:o,height:l,minWidth:d,minHeight:c,maxHeight:f}),ref:x},$)}),Vf=function(t){return null};Vf.displayName="Cell";function Du(e){"@babel/helpers - typeof";return Du=typeof Symbol=="function"&&typeof Symbol.iterator=="symbol"?function(t){return typeof t}:function(t){return t&&typeof Symbol=="function"&&t.constructor===Symbol&&t!==Symbol.prototype?"symbol":typeof t},Du(e)}function eO(e,t){var r=Object.keys(e);if(Object.getOwnPropertySymbols){var n=Object.getOwnPropertySymbols(e);t&&(n=n.filter(function(i){return Object.getOwnPropertyDescriptor(e,i).enumerable})),r.push.apply(r,n)}return r}function Cy(e){for(var t=1;t<arguments.length;t++){var r=arguments[t]!=null?arguments[t]:{};t%2?eO(Object(r),!0).forEach(function(n){yZ(e,n,r[n])}):Object.getOwnPropertyDescriptors?Object.defineProperties(e,Object.getOwnPropertyDescriptors(r)):eO(Object(r)).forEach(function(n){Object.defineProperty(e,n,Object.getOwnPropertyDescriptor(r,n))})}return e}function yZ(e,t,r){return t=bZ(t),t in e?Object.defineProperty(e,t,{value:r,enumerable:!0,configurable:!0,writable:!0}):e[t]=r,e}function bZ(e){var t=wZ(e,"string");return Du(t)=="symbol"?t:t+""}function wZ(e,t){if(Du(e)!="object"||!e)return e;var r=e[Symbol.toPrimitive];if(r!==void 0){var n=r.call(e,t||"default");if(Du(n)!="object")return n;throw new TypeError("@@toPrimitive must return a primitive value.")}return(t==="string"?String:Number)(e)}var yo={widthCache:{},cacheCount:0},xZ=2e3,_Z={position:"absolute",top:"-20000px",left:0,padding:0,margin:0,border:"none",whiteSpace:"pre"},tO="recharts_measurement_span";function SZ(e){var t=Cy({},e);return Object.keys(t).forEach(function(r){t[r]||delete t[r]}),t}var Xl=function(t){var r=arguments.length>1&&arguments[1]!==void 0?arguments[1]:{};if(t==null||zi.isSsr)return{width:0,height:0};var n=SZ(r),i=JSON.stringify({text:t,copyStyle:n});if(yo.widthCache[i])return yo.widthCache[i];try{var a=document.getElementById(tO);a||(a=document.createElement("span"),a.setAttribute("id",tO),a.setAttribute("aria-hidden","true"),document.body.appendChild(a));var o=Cy(Cy({},_Z),n);Object.assign(a.style,o),a.textContent="".concat(t);var s=a.getBoundingClientRect(),l={width:s.width,height:s.height};return yo.widthCache[i]=l,++yo.cacheCount>xZ&&(yo.cacheCount=0,yo.widthCache={}),l}catch{return{width:0,height:0}}},OZ=function(t){return{top:t.top+window.scrollY-document.documentElement.clientTop,left:t.left+window.scrollX-document.documentElement.clientLeft}};function Lu(e){"@babel/helpers - typeof";return Lu=typeof Symbol=="function"&&typeof Symbol.iterator=="symbol"?function(t){return typeof t}:function(t){return t&&typeof Symbol=="function"&&t.constructor===Symbol&&t!==Symbol.prototype?"symbol":typeof t},Lu(e)}function Kf(e,t){return AZ(e)||PZ(e,t)||kZ(e,t)||EZ()}function EZ(){throw new TypeError(`Invalid attempt to destructure non-iterable instance. 308In order to be iterable, non-array objects must have a [Symbol.iterator]() method.`)}function kZ(e,t){if(e){if(typeof e=="string")return rO(e,t);var r=Object.prototype.toString.call(e).slice(8,-1);if(r==="Object"&&e.constructor&&(r=e.constructor.name),r==="Map"||r==="Set")return Array.from(e);if(r==="Arguments"||/^(?:Ui|I)nt(?:8|16|32)(?:Clamped)?Array$/.test(r))return rO(e,t)}}function rO(e,t){(t==null||t>e.length)&&(t=e.length);for(var r=0,n=new Array(t);r<t;r++)n[r]=e[r];return n}function PZ(e,t){var r=e==null?null:typeof Symbol<"u"&&e[Symbol.iterator]||e["@@iterator"];if(r!=null){var n,i,a,o,s=[],l=!0,u=!1;try{if(a=(r=r.call(e)).next,t===0){if(Object(r)!==r)return;l=!1}else for(;!(l=(n=a.call(r)).done)&&(s.push(n.value),s.length!==t);l=!0);}catch(d){u=!0,i=d}finally{try{if(!l&&r.return!=null&&(o=r.return(),Object(o)!==o))return}finally{if(u)throw i}}return s}}function AZ(e){if(Array.isArray(e))return e}function jZ(e,t){if(!(e instanceof t))throw new TypeError("Cannot call a class as a function")}function nO(e,t){for(var r=0;r<t.length;r++){var n=t[r];n.enumerable=n.enumerable||!1,n.configurable=!0,"value"in n&&(n.writable=!0),Object.defineProperty(e,CZ(n.key),n)}}function TZ(e,t,r){return t&&nO(e.prototype,t),r&&nO(e,r),Object.defineProperty(e,"prototype",{writable:!1}),e}function CZ(e){var t=NZ(e,"string");return Lu(t)=="symbol"?t:t+""}function NZ(e,t){if(Lu(e)!="object"||!e)return e;var r=e[Symbol.toPrimitive];if(r!==void 0){var n=r.call(e,t);if(Lu(n)!="object")return n;throw new TypeError("@@toPrimitive must return a primitive value.")}return String(e)}var iO=/(-?\d+(?:\.\d+)?[a-zA-Z%]*)([*/])(-?\d+(?:\.\d+)?[a-zA-Z%]*)/,aO=/(-?\d+(?:\.\d+)?[a-zA-Z%]*)([+-])(-?\d+(?:\.\d+)?[a-zA-Z%]*)/,$Z=/^px|cm|vh|vw|em|rem|%|mm|in|pt|pc|ex|ch|vmin|vmax|Q$/,RZ=/(-?\d+(?:\.\d+)?)([a-zA-Z%]+)?/,TN={cm:96/2.54,mm:96/25.4,pt:96/72,pc:96/6,in:96,Q:96/(2.54*40),px:1},IZ=Object.keys(TN),Uo="NaN";function MZ(e,t){return e*TN[t]}var yd=function(){function e(t,r){jZ(this,e),this.num=t,this.unit=r,this.num=t,this.unit=r,Number.isNaN(t)&&(this.unit=""),r!==""&&!$Z.test(r)&&(this.num=NaN,this.unit=""),IZ.includes(r)&&(this.num=MZ(t,r),this.unit="px")}return TZ(e,[{key:"add",value:function(r){return this.unit!==r.unit?new e(NaN,""):new e(this.num+r.num,this.unit)}},{key:"subtract",value:function(r){return this.unit!==r.unit?new e(NaN,""):new e(this.num-r.num,this.unit)}},{key:"multiply",value:function(r){return this.unit!==""&&r.unit!==""&&this.unit!==r.unit?new e(NaN,""):new e(this.num*r.num,this.unit||r.unit)}},{key:"divide",value:function(r){return this.unit!==""&&r.unit!==""&&this.unit!==r.unit?new e(NaN,""):new e(this.num/r.num,this.unit||r.unit)}},{key:"toString",value:function(){return"".concat(this.num).concat(this.unit)}},{key:"isNaN",value:function(){return Number.isNaN(this.num)}}],[{key:"parse",value:function(r){var n,i=(n=RZ.exec(r))!==null&&n!==void 0?n:[],a=Kf(i,3),o=a[1],s=a[2];return new e(parseFloat(o),s??"")}}])}();function CN(e){if(e.includes(Uo))return Uo;for(var t=e;t.includes("*")||t.includes("/");){var r,n=(r=iO.exec(t))!==null&&r!==void 0?r:[],i=Kf(n,4),a=i[1],o=i[2],s=i[3],l=yd.parse(a??""),u=yd.parse(s??""),d=o==="*"?l.multiply(u):l.divide(u);if(d.isNaN())return Uo;t=t.replace(iO,d.toString())}for(;t.includes("+")||/.-\d+(?:\.\d+)?/.test(t);){var c,f=(c=aO.exec(t))!==null&&c!==void 0?c:[],h=Kf(f,4),v=h[1],m=h[2],g=h[3],y=yd.parse(v??""),b=yd.parse(g??""),w=m==="+"?y.add(b):y.subtract(b);if(w.isNaN())return Uo;t=t.replace(aO,w.toString())}return t}var oO=/\(([^()]*)\)/;function DZ(e){for(var t=e;t.includes("(");){var r=oO.exec(t),n=Kf(r,2),i=n[1];t=t.replace(oO,CN(i))}return t}function LZ(e){var t=e.replace(/\s+/g,"");return t=DZ(t),t=CN(t),t}function BZ(e){try{return LZ(e)}catch{return Uo}}function pv(e){var t=BZ(e.slice(5,-1));return t===Uo?"":t}var UZ=["x","y","lineHeight","capHeight","scaleToFit","textAnchor","verticalAnchor","fill"],FZ=["dx","dy","angle","className","breakAll"];function Ny(){return Ny=Object.assign?Object.assign.bind():function(e){for(var t=1;t<arguments.length;t++){var r=arguments[t];for(var n in r)Object.prototype.hasOwnProperty.call(r,n)&&(e[n]=r[n])}return e},Ny.apply(this,arguments)}function sO(e,t){if(e==null)return{};var r=zZ(e,t),n,i;if(Object.getOwnPropertySymbols){var a=Object.getOwnPropertySymbols(e);for(i=0;i<a.length;i++)n=a[i],!(t.indexOf(n)>=0)&&Object.prototype.propertyIsEnumerable.call(e,n)&&(r[n]=e[n])}return r}function zZ(e,t){if(e==null)return{};var r={};for(var n in e)if(Object.prototype.hasOwnProperty.call(e,n)){if(t.indexOf(n)>=0)continue;r[n]=e[n]}return r}function lO(e,t){return VZ(e)||HZ(e,t)||qZ(e,t)||WZ()}function WZ(){throw new TypeError(`Invalid attempt to destructure non-iterable instance. 309In order to be iterable, non-array objects must have a [Symbol.iterator]() method.`)}function qZ(e,t){if(e){if(typeof e=="string")return uO(e,t);var r=Object.prototype.toString.call(e).slice(8,-1);if(r==="Object"&&e.constructor&&(r=e.constructor.name),r==="Map"||r==="Set")return Array.from(e);if(r==="Arguments"||/^(?:Ui|I)nt(?:8|16|32)(?:Clamped)?Array$/.test(r))return uO(e,t)}}function uO(e,t){(t==null||t>e.length)&&(t=e.length);for(var r=0,n=new Array(t);r<t;r++)n[r]=e[r];return n}function HZ(e,t){var r=e==null?null:typeof Symbol<"u"&&e[Symbol.iterator]||e["@@iterator"];if(r!=null){var n,i,a,o,s=[],l=!0,u=!1;try{if(a=(r=r.call(e)).next,t===0){if(Object(r)!==r)return;l=!1}else for(;!(l=(n=a.call(r)).done)&&(s.push(n.value),s.length!==t);l=!0);}catch(d){u=!0,i=d}finally{try{if(!l&&r.return!=null&&(o=r.return(),Object(o)!==o))return}finally{if(u)throw i}}return s}}function VZ(e){if(Array.isArray(e))return e}var NN=/[ \f\n\r\t\v\u2028\u2029]+/,$N=function(t){var r=t.children,n=t.breakAll,i=t.style;try{var a=[];we(r)||(n?a=r.toString().split(""):a=r.toString().split(NN));var o=a.map(function(l){return{word:l,width:Xl(l,i).width}}),s=n?0:Xl(" ",i).width;return{wordsWithComputedWidth:o,spaceWidth:s}}catch{return null}},KZ=function(t,r,n,i,a){var o=t.maxLines,s=t.children,l=t.style,u=t.breakAll,d=Y(o),c=s,f=function(){var R=arguments.length>0&&arguments[0]!==void 0?arguments[0]:[];return R.reduce(function(M,L){var A=L.word,T=L.width,U=M[M.length-1];if(U&&(i==null||a||U.width+T+n<Number(i)))U.words.push(A),U.width+=T+n;else{var q={words:[A],width:T};M.push(q)}return M},[])},h=f(r),v=function(R){return R.reduce(function(M,L){return M.width>L.width?M:L})};if(!d)return h;for(var m="â¦",g=function(R){var M=c.slice(0,R),L=$N({breakAll:u,style:l,children:M+m}).wordsWithComputedWidth,A=f(L),T=A.length>o||v(A).width>Number(i);return[T,A]},y=0,b=c.length-1,w=0,_;y<=b&&w<=c.length-1;){var x=Math.floor((y+b)/2),S=x-1,E=g(S),k=lO(E,2),P=k[0],C=k[1],N=g(x),$=lO(N,1),D=$[0];if(!P&&!D&&(y=x+1),P&&D&&(b=x-1),!P&&D){_=C;break}w++}return _||h},cO=function(t){var r=we(t)?[]:t.toString().split(NN);return[{words:r}]},GZ=function(t){var r=t.width,n=t.scaleToFit,i=t.children,a=t.style,o=t.breakAll,s=t.maxLines;if((r||n)&&!zi.isSsr){var l,u,d=$N({breakAll:o,children:i,style:a});if(d){var c=d.wordsWithComputedWidth,f=d.spaceWidth;l=c,u=f}else return cO(i);return KZ({breakAll:o,children:i,maxLines:s,style:a},l,u,r,n)}return cO(i)},dO="#808080",Gf=function(t){var r=t.x,n=r===void 0?0:r,i=t.y,a=i===void 0?0:i,o=t.lineHeight,s=o===void 0?"1em":o,l=t.capHeight,u=l===void 0?"0.71em":l,d=t.scaleToFit,c=d===void 0?!1:d,f=t.textAnchor,h=f===void 0?"start":f,v=t.verticalAnchor,m=v===void 0?"end":v,g=t.fill,y=g===void 0?dO:g,b=sO(t,UZ),w=O.useMemo(function(){return GZ({breakAll:b.breakAll,children:b.children,maxLines:b.maxLines,scaleToFit:c,style:b.style,width:b.
309width})},[b.breakAll,b.children,b.maxLines,c,b.style,b.width]),_=b.dx,x=b.dy,S=b.angle,E=b.className,k=b.breakAll,P=sO(b,FZ);if(!ct(n)||!ct(a))return null;var C=n+(Y(_)?_:0),N=a+(Y(x)?x:0),$;switch(m){case"start":$=pv("calc(".concat(u,")"));break;case"middle":$=pv("calc(".concat((w.length-1)/2," * -").concat(s," + (").concat(u," / 2))"));break;default:$=pv("calc(".concat(w.length-1," * -").concat(s,")"));break}var D=[];if(c){var I=w[0].width,R=b.width;D.push("scale(".concat((Y(R)?R/I:1)/I,")"))}return S&&D.push("rotate(".concat(S,", ").concat(C,", ").concat(N,")")),D.length&&(P.transform=D.join(" ")),j.createElement("text",Ny({},Se(P,!0),{x:C,y:N,className:pe("recharts-text",E),textAnchor:h,fill:y.includes("url")?dO:y}),w.map(function(M,L){var A=M.words.join(k?"":" ");return j.createElement("tspan",{x:C,dy:L===0?$:s,key:"".concat(A,"-").concat(L)},A)}))};function Wi(e,t){return e==null||t==null?NaN:e<t?-1:e>t?1:e>=t?0:NaN}function YZ(e,t){return e==null||t==null?NaN:t<e?-1:t>e?1:t>=e?0:NaN}function Sw(e){let t,r,n;e.length!==2?(t=Wi,r=(s,l)=>Wi(e(s),l),n=(s,l)=>e(s)-l):(t=e===Wi||e===YZ?e:XZ,r=e,n=e);function i(s,l,u=0,d=s.length){if(u<d){if(t(l,l)!==0)return d;do{const c=u+d>>>1;r(s[c],l)<0?u=c+1:d=c}while(u<d)}return u}function a(s,l,u=0,d=s.length){if(u<d){if(t(l,l)!==0)return d;do{const c=u+d>>>1;r(s[c],l)<=0?u=c+1:d=c}while(u<d)}return u}function o(s,l,u=0,d=s.length){const c=i(s,l,u,d-1);return c>u&&n(s[c-1],l)>-n(s[c],l)?c-1:c}return{left:i,center:o,right:a}}function XZ(){return 0}function RN(e){return e===null?NaN:+e}function*QZ(e,t){for(let r of e)r!=null&&(r=+r)>=r&&(yield r)}const JZ=Sw(Wi),jc=JZ.right;Sw(RN).center;class fO extends Map{constructor(t,r=tee){if(super(),Object.defineProperties(this,{_intern:{value:new Map},_key:{value:r}}),t!=null)for(const[n,i]of t)this.set(n,i)}get(t){return super.get(hO(this,t))}has(t){return super.has(hO(this,t))}set(t,r){return super.set(ZZ(this,t),r)}delete(t){return super.delete(eee(this,t))}}function hO({_intern:e,_key:t},r){const n=t(r);return e.has(n)?e.get(n):r}function ZZ({_intern:e,_key:t},r){const n=t(r);return e.has(n)?e.get(n):(e.set(n,r),r)}function eee({_intern:e,_key:t},r){const n=t(r);return e.has(n)&&(r=e.get(n),e.delete(n)),r}function tee(e){return e!==null&&typeof e=="object"?e.valueOf():e}function ree(e=Wi){if(e===Wi)return IN;if(typeof e!="function")throw new TypeError("compare is not a function");return(t,r)=>{const n=e(t,r);return n||n===0?n:(e(r,r)===0)-(e(t,t)===0)}}function IN(e,t){return(e==null||!(e>=e))-(t==null||!(t>=t))||(e<t?-1:e>t?1:0)}const nee=Math.sqrt(50),iee=Math.sqrt(10),aee=Math.sqrt(2);function Yf(e,t,r){const n=(t-e)/Math.max(0,r),i=Math.floor(Math.log10(n)),a=n/Math.pow(10,i),o=a>=nee?10:a>=iee?5:a>=aee?2:1;let s,l,u;return i<0?(u=Math.pow(10,-i)/o,s=Math.round(e*u),l=Math.round(t*u),s/u<e&&++s,l/u>t&&--l,u=-u):(u=Math.pow(10,i)*o,s=Math.round(e/u),l=Math.round(t/u),s*u<e&&++s,l*u>t&&--l),l<s&&.5<=r&&r<2?Yf(e,t,r*2):[s,l,u]}function $y(e,t,r){if(t=+t,e=+e,r=+r,!(r>0))return[];if(e===t)return[e];const n=t<e,[i,a,o]=n?Yf(t,e,r):Yf(e,t,r);if(!(a>=i))return[];const s=a-i+1,l=new Array(s);if(n)if(o<0)for(let u=0;u<s;++u)l[u]=(a-u)/-o;else for(let u=0;u<s;++u)l[u]=(a-u)*o;else if(o<0)for(let u=0;u<s;++u)l[u]=(i+u)/-o;else for(let u=0;u<s;++u)l[u]=(i+u)*o;return l}function Ry(e,t,r){return t=+t,e=+e,r=+r,Yf(e,t,r)[2]}function Iy(e,t,r){t=+t,e=+e,r=+r;const n=t<e,i=n?Ry(t,e,r):Ry(e,t,r);return(n?-1:1)*(i<0?1/-i:i)}function pO(e,t){let r;for(const n of e)n!=null&&(r<n||r===void 0&&n>=n)&&(r=n);return r}function mO(e,t){let r;for(const n of e)n!=null&&(r>n||r===void 0&&n>=n)&&(r=n);return r}function MN(e,t,r=0,n=1/0,i){if(t=Math.floor(t),r=Math.floor(Math.max(0,r)),n=Math.floor(Math.min(e.length-1,n)),!(r<=t&&t<=n))return e;for(i=i===void 0?IN:ree(i);n>r;){if(n-r>600){const l=n-r+1,u=t-r+1,d=Math.log(l),c=.5*Math.exp(2*d/3),f=.5*Math.sqrt(d*c*(l-c)/l)*(u-l/2<0?-1:1),h=Math.max(r,Math.floor(t-u*c/l+f)),v=Math.min(n,Math.floor(t+(l-u)*c/l+f));MN(e,t,h,v,i)}const a=e[t];let o=r,s=n;for(Ol(e,r,t),i(e[n],a)>0&&Ol(e,r,n);o<s;){for(Ol(e,o,s),++o,--s;i(e[o],a)<0;)++o;for(;i(e[s],a)>0;)--s}i(e[r],a)===0?Ol(e,r,s):(++s,Ol(e,s,n)),s<=t&&(r=s+1),t<=s&&(n=s-1)}return e}function Ol(e,t,r){const n=e[t];e[t]=e[r],e[r]=n}function oee(e,t,r){if(e=Float64Array.from(QZ(e)),!(!(n=e.length)||isNaN(t=+t))){if(t<=0||n<2)return mO(e);if(t>=1)return pO(e);var n,i=(n-1)*t,a=Math.floor(i),o=pO(MN(e,a).subarray(0,a+1)),s=mO(e.subarray(a+1));return o+(s-o)*(i-a)}}function see(e,t,r=RN){if(!(!(n=e.length)||isNaN(t=+t))){if(t<=0||n<2)return+r(e[0],0,e);if(t>=1)return+r(e[n-1],n-1,e);var n,i=(n-1)*t,a=Math.floor(i),o=+r(e[a],a,e),s=+r(e[a+1],a+1,e);return o+(s-o)*(i-a)}}function lee(e,t,r){e=+e,t=+t,r=(i=arguments.length)<2?(t=e,e=0,1):i<3?1:+r;for(var n=-1,i=Math.max(0,Math.ceil((t-e)/r))|0,a=new Array(i);++n<i;)a[n]=e+n*r;return a}function Cr(e,t){switch(arguments.length){case 0:break;case 1:this.range(e);break;default:this.range(t).domain(e);break}return this}function li(e,t){switch(arguments.length){case 0:break;case 1:{typeof e=="function"?this.interpolator(e):this.range(e);break}default:{this.domain(e),typeof t=="function"?this.interpolator(t):this.range(t);break}}return this}
vendor: 13,227 bytes, line 309
309const My=Symbol("implicit");function Ow(){var e=new fO,t=[],r=[],n=My;function i(a){let o=e.get(a);if(o===void 0){if(n!==My)return n;e.set(a,o=t.push(a)-1)}return r[o%r.length]}return i.domain=function(a){if(!arguments.length)return t.slice();t=[],e=new fO;for(const o of a)e.has(o)||e.set(o,t.push(o)-1);return i},i.range=function(a){return arguments.length?(r=Array.from(a),i):r.slice()},i.unknown=function(a){return arguments.length?(n=a,i):n},i.copy=function(){return Ow(t,r).unknown(n)},Cr.apply(i,arguments),i}function Bu(){var e=Ow().unknown(void 0),t=e.domain,r=e.range,n=0,i=1,a,o,s=!1,l=0,u=0,d=.5;delete e.unknown;function c(){var f=t().length,h=i<n,v=h?i:n,m=h?n:i;a=(m-v)/Math.max(1,f-l+u*2),s&&(a=Math.floor(a)),v+=(m-v-a*(f-l))*d,o=a*(1-l),s&&(v=Math.round(v),o=Math.round(o));var g=lee(f).map(function(y){return v+a*y});return r(h?g.reverse():g)}return e.domain=function(f){return arguments.length?(t(f),c()):t()},e.range=function(f){return arguments.length?([n,i]=f,n=+n,i=+i,c()):[n,i]},e.rangeRound=function(f){return[n,i]=f,n=+n,i=+i,s=!0,c()},e.bandwidth=function(){return o},e.step=function(){return a},e.round=function(f){return arguments.length?(s=!!f,c()):s},e.padding=function(f){return arguments.length?(l=Math.min(1,u=+f),c()):l},e.paddingInner=function(f){return arguments.length?(l=Math.min(1,f),c()):l},e.paddingOuter=function(f){return arguments.length?(u=+f,c()):u},e.align=function(f){return arguments.length?(d=Math.max(0,Math.min(1,f)),c()):d},e.copy=function(){return Bu(t(),[n,i]).round(s).paddingInner(l).paddingOuter(u).align(d)},Cr.apply(c(),arguments)}function DN(e){var t=e.copy;return e.padding=e.paddingOuter,delete e.paddingInner,delete e.paddingOuter,e.copy=function(){return DN(t())},e}function Ql(){return DN(Bu.apply(null,arguments).paddingInner(1))}function Ew(e,t,r){e.prototype=t.prototype=r,r.constructor=e}function LN(e,t){var r=Object.create(e.prototype);for(var n in t)r[n]=t[n];return r}function Tc(){}var Uu=.7,Xf=1/Uu,es="\\s*([+-]?\\d+)\\s*",Fu="\\s*([+-]?(?:\\d*\\.)?\\d+(?:[eE][+-]?\\d+)?)\\s*",On="\\s*([+-]?(?:\\d*\\.)?\\d+(?:[eE][+-]?\\d+)?)%\\s*",uee=/^#([0-9a-f]{3,8})$/,cee=new RegExp(`^rgb\\(${es},${es},${es}\\)$`),dee=new RegExp(`^rgb\\(${On},${On},${On}\\)$`),fee=new RegExp(`^rgba\\(${es},${es},${es},${Fu}\\)$`),hee=new RegExp(`^rgba\\(${On},${On},${On},${Fu}\\)$`),pee=new RegExp(`^hsl\\(${Fu},${On},${On}\\)$`),mee=new RegExp(`^hsla\\(${Fu},${On},${On},${Fu}\\)$`),vO={aliceblue:15792383,antiquewhite:16444375,aqua:65535,aquamarine:8388564,azure:15794175,beige:16119260,bisque:16770244,black:0,blanchedalmond:16772045,blue:255,blueviolet:9055202,brown:10824234,burlywood:14596231,cadetblue:6266528,chartreuse:8388352,chocolate:13789470,coral:16744272,cornflowerblue:6591981,cornsilk:16775388,crimson:14423100,cyan:65535,darkblue:139,darkcyan:35723,darkgoldenrod:12092939,darkgray:11119017,darkgreen:25600,darkgrey:11119017,darkkhaki:12433259,darkmagenta:9109643,darkolivegreen:5597999,darkorange:16747520,darkorchid:10040012,darkred:9109504,darksalmon:15308410,darkseagreen:9419919,darkslateblue:4734347,darkslategray:3100495,darkslategrey:3100495,darkturquoise:52945,darkviolet:9699539,deeppink:16716947,deepskyblue:49151,dimgray:6908265,dimgrey:6908265,dodgerblue:2003199,firebrick:11674146,floralwhite:16775920,forestgreen:2263842,fuchsia:16711935,gainsboro:14474460,ghostwhite:16316671,gold:16766720,goldenrod:14329120,gray:8421504,green:32768,greenyellow:11403055,grey:8421504,honeydew:15794160,hotpink:16738740,indianred:13458524,indigo:4915330,ivory:16777200,khaki:15787660,lavender:15132410,lavenderblush:16773365,lawngreen:8190976,lemonchiffon:16775885,lightblue:11393254,lightcoral:15761536,lightcyan:14745599,lightgoldenrodyellow:16448210,lightgray:13882323,lightgreen:9498256,lightgrey:13882323,lightpink:16758465,lightsalmon:16752762,lightseagreen:2142890,lightskyblue:8900346,lightslategray:7833753,lightslategrey:7833753,lightsteelblue:11584734,lightyellow:16777184,lime:65280,limegreen:3329330,linen:16445670,magenta:16711935,maroon:8388608,mediumaquamarine:6737322,mediumblue:205,mediumorchid:12211667,mediumpurple:9662683,mediumseagreen:3978097,mediumslateblue:8087790,mediumspringgreen:64154,mediumturquoise:4772300,mediumvioletred:13047173,midnightblue:1644912,mintcream:16121850,mistyrose:16770273,moccasin:16770229,navajowhite:16768685,navy:128,oldlace:16643558,olive:8421376,olivedrab:7048739,orange:16753920,orangered:16729344,orchid:14315734,palegoldenrod:15657130,palegreen:10025880,paleturquoise:11529966,palevioletred:14381203,papayawhip:16773077,peachpuff:16767673,peru:13468991,pink:16761035,plum:14524637,powderblue:11591910,purple:8388736,rebeccapurple:6697881,red:16711680,rosybrown:12357519,royalblue:4286945,saddlebrown:9127187,salmon:16416882,sandybrown:16032864,seagreen:3050327,seashell:16774638,sienna:10506797,silver:12632256,skyblue:8900331,slateblue:6970061,slategray:7372944,slategrey:7372944,snow:16775930,springgreen:65407,steelblue:4620980,tan:13808780,teal:32896,thistle:14204888,tomato:16737095,turquoise:4251856,violet:15631086,wheat:16113331,white:16777215,whitesmoke:16119285,yellow:16776960,yellowgreen:10145074};Ew(Tc,zu,{copy(e){return Object.assign(new this.constructor,this,e)},displayable(){return this.rgb().displayable()},hex:gO,formatHex:gO,formatHex8:vee,formatHsl:gee,formatRgb:yO,toString:yO});function gO(){return this.rgb().formatHex()}function vee(){return this.rgb().formatHex8()}function gee(){return BN(this).formatHsl()}function yO(){return this.rgb().formatRgb()}function zu(e){var t,r;return e=(e+"").trim().toLowerCase(),(t=uee.exec(e))?(r=t[1].length,t=parseInt(t[1],16),r===6?bO(t):r===3?new Gt(t>>8&15|t>>4&240,t>>4&15|t&240,(t&15)<<4|t&15,1):r===8?bd(t>>24&255,t>>16&255,t>>8&255,(t&255)/255):r===4?bd(t>>12&15|t>>8&240,t>>8&15|t>>4&240,t>>4&15|t&240,((t&15)<<4|t&15)/255):null):(t=cee.exec(e))?new Gt(t[1],t[2],t[3],1):(t=dee.exec(e))?new Gt(t[1]*255/100,t[2]*255/100,t[3]*255/100,1):(t=fee.exec(e))?bd(t[1],t[2],t[3],t[4]):(t=hee.exec(e))?bd(t[1]*255/100,t[2]*255/100,t[3]*255/100,t[4]):(t=pee.exec(e))?_O(t[1],t[2]/100,t[3]/100,1):(t=mee.exec(e))?_O(t[1],t[2]/100,t[3]/100,t[4]):vO.hasOwnProperty(e)?bO(vO[e]):e==="transparent"?new Gt(NaN,NaN,NaN,0):null}function bO(e){return new Gt(e>>16&255,e>>8&255,e&255,1)}function bd(e,t,r,n){return n<=0&&(e=t=r=NaN),new Gt(e,t,r,n)}function yee(e){return e instanceof Tc||(e=zu(e)),e?(e=e.rgb(),new Gt(e.r,e.g,e.b,e.opacity)):new Gt}function Dy(e,t,r,n){return arguments.length===1?yee(e):new Gt(e,t,r,n??1)}function Gt(e,t,r,n){this.r=+e,this.g=+t,this.b=+r,this.opacity=+n}Ew(Gt,Dy,LN(Tc,{brighter(e){return e=e==null?Xf:Math.pow(Xf,e),new Gt(this.r*e,this.g*e,this.b*e,this.opacity)},darker(e){return e=e==null?Uu:Math.pow(Uu,e),new Gt(this.r*e,this.g*e,this.b*e,this.opacity)},rgb(){return this},clamp(){return new Gt(La(this.r),La(this.g),La(this.b),Qf(this.opacity))},displayable(){return-.5<=this.r&&this.r<255.5&&-.5<=this.g&&this.g<255.5&&-.5<=this.b&&this.b<255.5&&0<=this.opacity&&this.opacity<=1},hex:wO,formatHex:wO,formatHex8:bee,formatRgb:xO,toString:xO}));function wO(){return`#${Oa(this.r)}${Oa(this.g)}${Oa(this.b)}`}function bee(){return`#${Oa(this.r)}${Oa(this.g)}${Oa(this.b)}${Oa((isNaN(this.opacity)?1:this.opacity)*255)}`}function xO(){const e=Qf(this.opacity);return`${e===1?"rgb(":"rgba("}${La(this.r)}, ${La(this.g)}, ${La(this.b)}${e===1?")":`, ${e})`}`}function Qf(e){return isNaN(e)?1:Math.max(0,Math.min(1,e))}function La(e){return Math.max(0,Math.min(255,Math.round(e)||0))}function Oa(e){return e=La(e),(e<16?"0":"")+e.toString(16)}function _O(e,t,r,n){return n<=0?e=t=r=NaN:r<=0||r>=1?e=t=NaN:t<=0&&(e=NaN),new Yr(e,t,r,n)}function BN(e){if(e instanceof Yr)return new Yr(e.h,e.s,e.l,e.opacity);if(e instanceof Tc||(e=zu(e)),!e)return new Yr;if(e instanceof Yr)return e;e=e.rgb();var t=e.r/255,r=e.g/255,n=e.b/255,i=Math.min(t,r,n),a=Math.max(t,r,n),o=NaN,s=a-i,l=(a+i)/2;return s?(t===a?o=(r-n)/s+(r<n)*6:r===a?o=(n-t)/s+2:o=(t-r)/s+4,s/=l<.5?a+i:2-a-i,o*=60):s=l>0&&l<1?0:o,new Yr(o,s,l,e.opacity)}function wee(e,t,r,n){return arguments.length===1?BN(e):new Yr(e,t,r,n??1)}function Yr(e,t,r,n){this.h=+e,this.s=+t,this.l=+r,this.opacity=+n}Ew(Yr,wee,LN(Tc,{brighter(e){return e=e==null?Xf:Math.pow(Xf,e),new Yr(this.h,this.s,this.l*e,this.opacity)},darker(e){return e=e==null?Uu:Math.pow(Uu,e),new Yr(this.h,this.s,this.l*e,this.opacity)},rgb(){var e=this.h%360+(this.h<0)*360,t=isNaN(e)||isNaN(this.s)?0:this.s,r=this.l,n=r+(r<.5?r:1-r)*t,i=2*r-n;return new Gt(mv(e>=240?e-240:e+120,i,n),mv(e,i,n),mv(e<120?e+240:e-120,i,n),this.opacity)},clamp(){return new Yr(SO(this.h),wd(this.s),wd(this.l),Qf(this.opacity))},displayable(){return(0<=this.s&&this.s<=1||isNaN(this.s))&&0<=this.l&&this.l<=1&&0<=this.opacity&&this.opacity<=1},formatHsl(){const e=Qf(this.opacity);return`${e===1?"hsl(":"hsla("}${SO(this.h)}, ${wd(this.s)*100}%, ${wd(this.l)*100}%${e===1?")":`, ${e})`}`}}));function SO(e){return e=(e||0)%360,e<0?e+360:e}function wd(e){return Math.max(0,Math.min(1,e||0))}function mv(e,t,r){return(e<60?t+(r-t)*e/60:e<180?r:e<240?t+(r-t)*(240-e)/60:t)*255}const kw=e=>()=>e;function xee(e,t){return function(r){return e+r*t}}function _ee(e,t,r){return e=Math.pow(e,r),t=Math.pow(t,r)-e,r=1/r,function(n){return Math.pow(e+n*t,r)}}function See(e){return(e=+e)==1?UN:function(t,r){return r-t?_ee(t,r,e):kw(isNaN(t)?r:t)}}function UN(e,t){var r=t-e;return r?xee(e,r):kw(isNaN(e)?t:e)}const OO=function e(t){var r=See(t);function n(i,a){var o=r((i=Dy(i)).r,(a=Dy(a)).r),s=r(i.g,a.g),l=r(i.b,a.b),u=UN(i.opacity,a.opacity);return function(d){return i.r=o(d),i.g=s(d),i.b=l(d),i.opacity=u(d),i+""}}return n.gamma=e,n}(1);function Oee(e,t){t||(t=[]);var r=e?Math.min(t.length,e.length):0,n=t.slice(),i;return function(a){for(i=0;i<r;++i)n[i]=e[i]*(1-a)+t[i]*a;return n}}function Eee(e){return ArrayBuffer.isView(e)&&!(e instanceof DataView)}function kee(e,t){var r=t?t.length:0,n=e?Math.min(r,e.length):0,i=new Array(n),a=new Array(r),o;for(o=0;o<n;++o)i[o]=ll(e[o],t[o]);for(;o<r;++o)a[o]=t[o];return function(s){for(o=0;o<n;++o)a[o]=i[o](s);return a}}function Pee(e,t){var r=new Date;return e=+e,t=+t,function(n){return r.setTime(e*(1-n)+t*n),r}}function Jf(e,t){return e=+e,t=+t,function(r){return e*(1-r)+t*r}}function Aee(e,t){var r={},n={},i;(e===null||typeof e!="object")&&(e={}),(t===null||typeof t!="object")&&(t={});for(i in t)i in e?r[i]=ll(e[i],t[i]):n[i]=t[i];return function(a){for(i in r)n[i]=r[i](a);return n}}var Ly=/[-+]?(?:\d+\.?\d*|\.?\d+)(?:[eE][-+]?\d+)?/g,vv=new RegExp(Ly.source,"g");function jee(e){return function(){return e}}function Tee(e){return function(t){return e(t)+""}}function Cee(e,t){var r=Ly.lastIndex=vv.lastIndex=0,n,i,a,o=-1,s=[],l=[];for(e=e+"",t=t+"";(n=Ly.exec(e))&&(i=vv.exec(t));)(a=i.index)>r&&(a=t.slice(r,a),s[o]?s[o]+=a:s[++o]=a),(n=n[0])===(i=i[0])?s[o]?s[o]+=i:s[++o]=i:(s[++o]=null,l.push({i:o,x:Jf(n,i)})),r=vv.lastIndex;return r<t.length&&(a=t.slice(r),s[o]?s[o]+=a:s[++o]=a),s.length<2?l[0]?Tee(l[0].x):jee(t):(t=l.length,function(u){for(var d=0,c;d<t;++d)s[(c=l[d]).i]=c.x(u);return s.join("")})}function ll(e,t){var r=typeof t,n;return t==null||r==="boolean"?kw(t):(r==="number"?Jf:r==="string"?(n=zu(t))?(t=n,OO):Cee:t instanceof zu?OO:t instanceof Date?Pee:Eee(t)?Oee:Array.isArray(t)?kee:typeof t.valueOf!="function"&&typeof t.toString!="function"||isNaN(t)?Aee:Jf)(e,t)}function Pw(e,t){return e=+e,t=+t,function(r){return Math.round(e*(1-r)+t*r)}}function Nee(e,t){t===void 0&&(t=e,e=ll);for(var r=0,n=t.length-1,i=t[0],a=new Array(n<0?0:n);r<n;)a[r]=e(i,i=t[++r]);return function(o){var s=Math.max(0,Math.min(n-1,Math.floor(o*=n)));return a[s](o-s)}}function $ee(e){return function(){return e}}function Zf(e){return+e}var EO=[0,1];function Bt(e){return e}function By(e,t){return(t-=e=+e)?function(r){return(r-e)/t}:$ee(isNaN(t)?NaN:.5)}function Ree(e,t){var r;return e>t&&(r=e,e=t,t=r),function(n){return Math.max(e,Math.min(t,n))}}function Iee(e,t,r){var n=e[0],i=e[1],a=t[0],o=t[1];return i<n?(n=By(i,n),a=r(o,a)):(n=By(n,i),a=r(a,o)),function(s){return a(n(s))}}function Mee(e,t,r){var n=Math.min(e.length,t.length)-1,i=new Array(n),a=new Array(n),o=-1;for(e[n]<e[0]&&(e=e.slice().reverse(),t=t.slice().reverse());++o<n;)i[o]=By(e[o],e[o+1]),a[o]=r(t[o],t[o+1]);return function(s){var l=jc(e,s,1,n)-1;return a[l](i[l](s))}}function Cc(e,t){return t.domain(e.domain()).range(e.range()).interpolate(e.interpolate()).clamp(e.clamp()).unknown(e.unknown())}function Bp(){var e=EO,t=EO,r=ll,n,i,a,o=Bt,s,l,u;function d(){var f=Math.min(e.length,t.length);return o!==Bt&&(o=Ree(e[0],e[f-1])),s=f>2?Mee:Iee,l=u=null,c}function c(f){return f==null||isNaN(f=+f)?a:(l||(l=s(e.map(n),t,r)))(n(o(f)))}return c.invert=function(f){return o(i((u||(u=s(t,e.map(n),Jf)))(f)))},c.domain=function(f){return arguments.length?(e=Array.from(f,Zf),d()):e.slice()},c.range=function(f){return arguments.length?(t=Array.from(f),d()):t.slice()},c.rangeRound=function(f){return t=Array.from(f),r=Pw,d()},c.clamp=function(f){return arguments.length?(o=f?!0:Bt,d()):o!==Bt},c.interpolate=function(f){return arguments.length?(r=f,d()):r},c.unknown=function(f){return arguments.length?(a=f,c):a},function(f,h){return n=f,i=h,d()}}function Aw(){return Bp()(Bt,Bt)}
vendor: 7,906 bytes, line 309
309function Dee(e){return Math.abs(e=Math.round(e))>=1e21?e.toLocaleString("en").replace(/,/g,""):e.toString(10)}function eh(e,t){if((r=(e=t?e.toExponential(t-1):e.toExponential()).indexOf("e"))<0)return null;var r,n=e.slice(0,r);return[n.length>1?n[0]+n.slice(2):n,+e.slice(r+1)]}function ks(e){return e=eh(Math.abs(e)),e?e[1]:NaN}function Lee(e,t){return function(r,n){for(var i=r.length,a=[],o=0,s=e[0],l=0;i>0&&s>0&&(l+s+1>n&&(s=Math.max(1,n-l)),a.push(r.substring(i-=s,i+s)),!((l+=s+1)>n));)s=e[o=(o+1)%e.length];return a.reverse().join(t)}}function Bee(e){return function(t){return t.replace(/[0-9]/g,function(r){return e[+r]})}}var Uee=/^(?:(.)?([<>=^]))?([+\-( ])?([$#])?(0)?(\d+)?(,)?(\.\d+)?(~)?([a-z%])?$/i;function Wu(e){if(!(t=Uee.exec(e)))throw new Error("invalid format: "+e);var t;return new jw({fill:t[1],align:t[2],sign:t[3],symbol:t[4],zero:t[5],width:t[6],comma:t[7],precision:t[8]&&t[8].slice(1),trim:t[9],type:t[10]})}Wu.prototype=jw.prototype;function jw(e){this.fill=e.fill===void 0?" ":e.fill+"",this.align=e.align===void 0?">":e.align+"",this.sign=e.sign===void 0?"-":e.sign+"",this.symbol=e.symbol===void 0?"":e.symbol+"",this.zero=!!e.zero,this.width=e.width===void 0?void 0:+e.width,this.comma=!!e.comma,this.precision=e.precision===void 0?void 0:+e.precision,this.trim=!!e.trim,this.type=e.type===void 0?"":e.type+""}jw.prototype.toString=function(){return this.fill+this.align+this.sign+this.symbol+(this.zero?"0":"")+(this.width===void 0?"":Math.max(1,this.width|0))+(this.comma?",":"")+(this.precision===void 0?"":"."+Math.max(0,this.precision|0))+(this.trim?"~":"")+this.type};function Fee(e){e:for(var t=e.length,r=1,n=-1,i;r<t;++r)switch(e[r]){case".":n=i=r;break;case"0":n===0&&(n=r),i=r;break;default:if(!+e[r])break e;n>0&&(n=0);break}return n>0?e.slice(0,n)+e.slice(i+1):e}var FN;function zee(e,t){var r=eh(e,t);if(!r)return e+"";var n=r[0],i=r[1],a=i-(FN=Math.max(-8,Math.min(8,Math.floor(i/3)))*3)+1,o=n.length;return a===o?n:a>o?n+new Array(a-o+1).join("0"):a>0?n.slice(0,a)+"."+n.slice(a):"0."+new Array(1-a).join("0")+eh(e,Math.max(0,t+a-1))[0]}function kO(e,t){var r=eh(e,t);if(!r)return e+"";var n=r[0],i=r[1];return i<0?"0."+new Array(-i).join("0")+n:n.length>i+1?n.slice(0,i+1)+"."+n.slice(i+1):n+new Array(i-n.length+2).join("0")}const PO={"%":(e,t)=>(e*100).toFixed(t),b:e=>Math.round(e).toString(2),c:e=>e+"",d:Dee,e:(e,t)=>e.toExponential(t),f:(e,t)=>e.toFixed(t),g:(e,t)=>e.toPrecision(t),o:e=>Math.round(e).toString(8),p:(e,t)=>kO(e*100,t),r:kO,s:zee,X:e=>Math.round(e).toString(16).toUpperCase(),x:e=>Math.round(e).toString(16)};function AO(e){return e}var jO=Array.prototype.map,TO=["y","z","a","f","p","n","µ","m","","k","M","G","T","P","E","Z","Y"];function Wee(e){var t=e.grouping===void 0||e.thousands===void 0?AO:Lee(jO.call(e.grouping,Number),e.thousands+""),r=e.currency===void 0?"":e.currency[0]+"",n=e.currency===void 0?"":e.currency[1]+"",i=e.decimal===void 0?".":e.decimal+"",a=e.numerals===void 0?AO:Bee(jO.call(e.numerals,String)),o=e.percent===void 0?"%":e.percent+"",s=e.minus===void 0?"â":e.minus+"",l=e.nan===void 0?"NaN":e.nan+"";function u(c){c=Wu(c);var f=c.fill,h=c.align,v=c.sign,m=c.symbol,g=c.zero,y=c.width,b=c.comma,w=c.precision,_=c.trim,x=c.type;x==="n"?(b=!0,x="g"):PO[x]||(w===void 0&&(w=12),_=!0,x="g"),(g||f==="0"&&h==="=")&&(g=!0,f="0",h="=");var S=m==="$"?r:m==="#"&&/[boxX]/.test(x)?"0"+x.toLowerCase():"",E=m==="$"?n:/[%p]/.test(x)?o:"",k=PO[x],P=/[defgprs%]/.test(x);w=w===void 0?6:/[gprs]/.test(x)?Math.max(1,Math.min(21,w)):Math.max(0,Math.min(20,w));function C(N){var $=S,D=E,I,R,M;if(x==="c")D=k(N)+D,N="";else{N=+N;var L=N<0||1/N<0;if(N=isNaN(N)?l:k(Math.abs(N),w),_&&(N=Fee(N)),L&&+N==0&&v!=="+"&&(L=!1),$=(L?v==="("?v:s:v==="-"||v==="("?"":v)+$,D=(x==="s"?TO[8+FN/3]:"")+D+(L&&v==="("?")":""),P){for(I=-1,R=N.length;++I<R;)if(M=N.charCodeAt(I),48>M||M>57){D=(M===46?i+N.slice(I+1):N.slice(I))+D,N=N.slice(0,I);break}}}b&&!g&&(N=t(N,1/0));var A=$.length+N.length+D.length,T=A<y?new Array(y-A+1).join(f):"";switch(b&&g&&(N=t(T+N,T.length?y-D.length:1/0),T=""),h){case"<":N=$+N+D+T;break;case"=":N=$+T+N+D;break;case"^":N=T.slice(0,A=T.length>>1)+$+N+D+T.slice(A);break;default:N=T+$+N+D;break}return a(N)}return C.toString=function(){return c+""},C}function d(c,f){var h=u((c=Wu(c),c.type="f",c)),v=Math.max(-8,Math.min(8,Math.floor(ks(f)/3)))*3,m=Math.pow(10,-v),g=TO[8+v/3];return function(y){return h(m*y)+g}}return{format:u,formatPrefix:d}}var xd,Tw,zN;qee({thousands:",",grouping:[3],currency:["$",""]});function qee(e){return xd=Wee(e),Tw=xd.format,zN=xd.formatPrefix,xd}function Hee(e){return Math.max(0,-ks(Math.abs(e)))}function Vee(e,t){return Math.max(0,Math.max(-8,Math.min(8,Math.floor(ks(t)/3)))*3-ks(Math.abs(e)))}function Kee(e,t){return e=Math.abs(e),t=Math.abs(t)-e,Math.max(0,ks(t)-ks(e))+1}function WN(e,t,r,n){var i=Iy(e,t,r),a;switch(n=Wu(n??",f"),n.type){case"s":{var o=Math.max(Math.abs(e),Math.abs(t));return n.precision==null&&!isNaN(a=Vee(i,o))&&(n.precision=a),zN(n,o)}case"":case"e":case"g":case"p":case"r":{n.precision==null&&!isNaN(a=Kee(i,Math.max(Math.abs(e),Math.abs(t))))&&(n.precision=a-(n.type==="e"));break}case"f":case"%":{n.precision==null&&!isNaN(a=Hee(i))&&(n.precision=a-(n.type==="%")*2);break}}return Tw(n)}function ra(e){var t=e.domain;return e.ticks=function(r){var n=t();return $y(n[0],n[n.length-1],r??10)},e.tickFormat=function(r,n){var i=t();return WN(i[0],i[i.length-1],r??10,n)},e.nice=function(r){r==null&&(r=10);var n=t(),i=0,a=n.length-1,o=n[i],s=n[a],l,u,d=10;for(s<o&&(u=o,o=s,s=u,u=i,i=a,a=u);d-- >0;){if(u=Ry(o,s,r),u===l)return n[i]=o,n[a]=s,t(n);if(u>0)o=Math.floor(o/u)*u,s=Math.ceil(s/u)*u;else if(u<0)o=Math.ceil(o*u)/u,s=Math.floor(s*u)/u;else break;l=u}return e},e}function th(){var e=Aw();return e.copy=function(){return Cc(e,th())},Cr.apply(e,arguments),ra(e)}function qN(e){var t;function r(n){return n==null||isNaN(n=+n)?t:n}return r.invert=r,r.domain=r.range=function(n){return arguments.length?(e=Array.from(n,Zf),r):e.slice()},r.unknown=function(n){return arguments.length?(t=n,r):t},r.copy=function(){return qN(e).unknown(t)},e=arguments.length?Array.from(e,Zf):[0,1],ra(r)}function HN(e,t){e=e.slice();var r=0,n=e.length-1,i=e[r],a=e[n],o;return a<i&&(o=r,r=n,n=o,o=i,i=a,a=o),e[r]=t.floor(i),e[n]=t.ceil(a),e}function CO(e){return Math.log(e)}function NO(e){return Math.exp(e)}function Gee(e){return-Math.log(-e)}function Yee(e){return-Math.exp(-e)}function Xee(e){return isFinite(e)?+("1e"+e):e<0?0:e}function Qee(e){return e===10?Xee:e===Math.E?Math.exp:t=>Math.pow(e,t)}function Jee(e){return e===Math.E?Math.log:e===10&&Math.log10||e===2&&Math.log2||(e=Math.log(e),t=>Math.log(t)/e)}function $O(e){return(t,r)=>-e(-t,r)}function Cw(e){const t=e(CO,NO),r=t.domain;let n=10,i,a;function o(){return i=Jee(n),a=Qee(n),r()[0]<0?(i=$O(i),a=$O(a),e(Gee,Yee)):e(CO,NO),t}return t.base=function(s){return arguments.length?(n=+s,o()):n},t.domain=function(s){return arguments.length?(r(s),o()):r()},t.ticks=s=>{const l=r();let u=l[0],d=l[l.length-1];const c=d<u;c&&([u,d]=[d,u]);let f=i(u),h=i(d),v,m;const g=s==null?10:+s;let y=[];if(!(n%1)&&h-f<g){if(f=Math.floor(f),h=Math.ceil(h),u>0){for(;f<=h;++f)for(v=1;v<n;++v)if(m=f<0?v/a(-f):v*a(f),!(m<u)){if(m>d)break;y.push(m)}}else for(;f<=h;++f)for(v=n-1;v>=1;--v)if(m=f>0?v/a(-f):v*a(f),!(m<u)){if(m>d)break;y.push(m)}y.length*2<g&&(y=$y(u,d,g))}else y=$y(f,h,Math.min(h-f,g)).map(a);return c?y.reverse():y},t.tickFormat=(s,l)=>{if(s==null&&(s=10),l==null&&(l=n===10?"s":","),typeof l!="function"&&(!(n%1)&&(l=Wu(l)).precision==null&&(l.trim=!0),l=Tw(l)),s===1/0)return l;const u=Math.max(1,n*s/t.ticks().length);return d=>{let c=d/a(Math.round(i(d)));return c*n<n-.5&&(c*=n),c<=u?l(d):""}},t.nice=()=>r(HN(r(),{floor:s=>a(Math.floor(i(s))),ceil:s=>a(Math.ceil(i(s)))})),t}function VN(){const e=Cw(Bp()).domain([1,10]);return e.copy=()=>Cc(e,VN()).base(e.base()),Cr.apply(e,arguments),e}
309function RO(e){return function(t){return Math.sign(t)*Math.log1p(Math.abs(t/e))}}function IO(e){return function(t){return Math.sign(t)*Math.expm1(Math.abs(t))*e}}function Nw(e){var t=1,r=e(RO(t),IO(t));return r.constant=function(n){return arguments.length?e(RO(t=+n),IO(t)):t},ra(r)}function KN(){var e=Nw(Bp());return e.copy=function(){return Cc(e,KN()).constant(e.constant())},Cr.apply(e,arguments)}function MO(e){return function(t){return t<0?-Math.pow(-t,e):Math.pow(t,e)}}function Zee(e){return e<0?-Math.sqrt(-e):Math.sqrt(e)}function ete(e){return e<0?-e*e:e*e}function $w(e){var t=e(Bt,Bt),r=1;function n(){return r===1?e(Bt,Bt):r===.5?e(Zee,ete):e(MO(r),MO(1/r))}return t.exponent=function(i){return arguments.length?(r=+i,n()):r},ra(t)}function Rw(){var e=$w(Bp());return e.copy=function(){return Cc(e,Rw()).exponent(e.exponent())},Cr.apply(e,arguments),e}function tte(){return Rw.apply(null,arguments).exponent(.5)}function DO(e){return Math.sign(e)*e*e}function rte(e){return Math.sign(e)*Math.sqrt(Math.abs(e))}function GN(){var e=Aw(),t=[0,1],r=!1,n;function i(a){var o=rte(e(a));return isNaN(o)?n:r?Math.round(o):o}return i.invert=function(a){return e.invert(DO(a))},i.domain=function(a){return arguments.length?(e.domain(a),i):e.domain()},i.range=function(a){return arguments.length?(e.range((t=Array.from(a,Zf)).map(DO)),i):t.slice()},i.rangeRound=function(a){return i.range(a).round(!0)},i.round=function(a){return arguments.length?(r=!!a,i):r},i.clamp=function(a){return arguments.length?(e.clamp(a),i):e.clamp()},i.unknown=function(a){return arguments.length?(n=a,i):n},i.copy=function(){return GN(e.domain(),t).round(r).clamp(e.clamp()).unknown(n)},Cr.apply(i,arguments),ra(i)}function YN(){var e=[],t=[],r=[],n;function i(){var o=0,s=Math.max(1,t.length);for(r=new Array(s-1);++o<s;)r[o-1]=see(e,o/s);return a}function a(o){return o==null||isNaN(o=+o)?n:t[jc(r,o)]}return a.invertExtent=function(o){var s=t.indexOf(o);return s<0?[NaN,NaN]:[s>0?r[s-1]:e[0],s<r.length?r[s]:e[e.length-1]]},a.domain=function(o){if(!arguments.length)return e.slice();e=[];for(let s of o)s!=null&&!isNaN(s=+s)&&e.push(s);return e.sort(Wi),i()},a.range=function(o){return arguments.length?(t=Array.from(o),i()):t.slice()},a.unknown=function(o){return arguments.length?(n=o,a):n},a.quantiles=function(){return r.slice()},a.copy=function(){return YN().domain(e).range(t).unknown(n)},Cr.apply(a,arguments)}function XN(){var e=0,t=1,r=1,n=[.5],i=[0,1],a;function o(l){return l!=null&&l<=l?i[jc(n,l,0,r)]:a}function s(){var l=-1;for(n=new Array(r);++l<r;)n[l]=((l+1)*t-(l-r)*e)/(r+1);return o}return o.domain=function(l){return arguments.length?([e,t]=l,e=+e,t=+t,s()):[e,t]},o.range=function(l){return arguments.length?(r=(i=Array.from(l)).length-1,s()):i.slice()},o.invertExtent=function(l){var u=i.indexOf(l);return u<0?[NaN,NaN]:u<1?[e,n[0]]:u>=r?[n[r-1],t]:[n[u-1],n[u]]},o.unknown=function(l){return arguments.length&&(a=l),o},o.thresholds=function(){return n.slice()},o.copy=function(){return XN().domain([e,t]).range(i).unknown(a)},Cr.apply(ra(o),arguments)}function QN(){var e=[.5],t=[0,1],r,n=1;function i(a){return a!=null&&a<=a?t[jc(e,a,0,n)]:r}return i.domain=function(a){return arguments.length?(e=Array.from(a),n=Math.min(e.length,t.length-1),i):e.slice()},i.range=function(a){return arguments.length?(t=Array.from(a),n=Math.min(e.length,t.length-1),i):t.slice()},i.invertExtent=function(a){var o=t.indexOf(a);return[e[o-1],e[o]]},i.unknown=function(a){return arguments.length?(r=a,i):r},i.copy=function(){return QN().domain(e).range(t).unknown(r)},Cr.apply(i,arguments)}const gv=new Date,yv=new Date;function ht(e,t,r,n){function i(a){return e(a=arguments.length===0?new Date:new Date(+a)),a}return i.floor=a=>(e(a=new Date(+a)),a),i.ceil=a=>(e(a=new Date(a-1)),t(a,1),e(a),a),i.round=a=>{const o=i(a),s=i.ceil(a);return a-o<s-a?o:s},i.offset=(a,o)=>(t(a=new Date(+a),o==null?1:Math.floor(o)),a),i.range=(a,o,s)=>{const l=[];if(a=i.ceil(a),s=s==null?1:Math.floor(s),!(a<o)||!(s>0))return l;let u;do l.push(u=new Date(+a)),t(a,s),e(a);while(u<a&&a<o);return l},i.filter=a=>ht(o=>{if(o>=o)for(;e(o),!a(o);)o.setTime(o-1)},(o,s)=>{if(o>=o)if(s<0)for(;++s<=0;)for(;t(o,-1),!a(o););else for(;--s>=0;)for(;t(o,1),!a(o););}),r&&(i.count=(a,o)=>(gv.setTime(+a),yv.setTime(+o),e(gv),e(yv),Math.floor(r(gv,yv))),i.every=a=>(a=Math.floor(a),!isFinite(a)||!(a>0)?null:a>1?i.filter(n?o=>n(o)%a===0:o=>i.count(0,o)%a===0):i)),i}const rh=ht(()=>{},(e,t)=>{e.setTime(+e+t)},(e,t)=>t-e);rh.every=e=>(e=Math.floor(e),!isFinite(e)||!(e>0)?null:e>1?ht(t=>{t.setTime(Math.floor(t/e)*e)},(t,r)=>{t.setTime(+t+r*e)},(t,r)=>(r-t)/e):rh);rh.range;const zn=1e3,Or=zn*60,Wn=Or*60,Zn=Wn*24,Iw=Zn*7,LO=Zn*30,bv=Zn*365,Ea=ht(e=>{e.setTime(e-e.getMilliseconds())},(e,t)=>{e.setTime(+e+t*zn)},(e,t)=>(t-e)/zn,e=>e.getUTCSeconds());Ea.range;const Mw=ht(e=>{e.setTime(e-e.getMilliseconds()-e.getSeconds()*zn)},(e,t)=>{e.setTime(+e+t*Or)},(e,t)=>(t-e)/Or,e=>e.getMinutes());Mw.range;const Dw=ht(e=>{e.setUTCSeconds(0,0)},(e,t)=>{e.setTime(+e+t*Or)},(e,t)=>(t-e)/Or,e=>e.getUTCMinutes());Dw.range;const Lw=ht(e=>{e.setTime(e-e.getMilliseconds()-e.getSeconds()*zn-e.getMinutes()*Or)},(e,t)=>{e.setTime(+e+t*Wn)},(e,t)=>(t-e)/Wn,e=>e.getHours());Lw.range;const Bw=ht(e=>{e.setUTCMinutes(0,0,0)},(e,t)=>{e.setTime(+e+t*Wn)},(e,t)=>(t-e)/Wn,e=>e.getUTCHours());Bw.range;const Nc=ht(e=>e.setHours(0,0,0,0),(e,t)=>e.setDate(e.getDate()+t),(e,t)=>(t-e-(t.getTimezoneOffset()-e.getTimezoneOffset())*Or)/Zn,e=>e.getDate()-1);Nc.range;const Up=ht(e=>{e.setUTCHours(0,0,0,0)},(e,t)=>{e.setUTCDate(e.getUTCDate()+t)},(e,t)=>(t-e)/Zn,e=>e.getUTCDate()-1);Up.range;const JN=ht(e=>{e.setUTCHours(0,0,0,0)},(e,t)=>{e.setUTCDate(e.getUTCDate()+t)},(e,t)=>(t-e)/Zn,e=>Math.floor(e/Zn));JN.range;function no(e){return ht(t=>{t.setDate(t.getDate()-(t.getDay()+7-e)%7),t.setHours(0,0,0,0)},(t,r)=>{t.setDate(t.getDate()+r*7)},(t,r)=>(r-t-(r.getTimezoneOffset()-t.getTimezoneOffset())*Or)/Iw)}const Fp=no(0),nh=no(1),nte=no(2),ite=no(3),Ps=no(4),ate=no(5),ote=no(6);Fp.range;nh.range;nte.range;ite.range;Ps.range;ate.range;ote.range;function io(e){return ht(t=>{t.setUTCDate(t.getUTCDate()-(t.getUTCDay()+7-e)%7),t.setUTCHours(0,0,0,0)},(t,r)=>{t.setUTCDate(t.getUTCDate()+r*7)},(t,r)=>(r-t)/Iw)}const zp=io(0),ih=io(1),ste=io(2),lte=io(3),As=io(4),ute=io(5),cte=io(6);zp.range;ih.range;ste.range;lte.range;As.range;ute.range;cte.range;const Uw=ht(e=>{e.setDate(1),e.setHours(0,0,0,0)},(e,t)=>{e.setMonth(e.getMonth()+t)},(e,t)=>t.getMonth()-e.getMonth()+(t.getFullYear()-e.getFullYear())*12,e=>e.getMonth());Uw.range;const Fw=ht(e=>{e.setUTCDate(1),e.setUTCHours(0,0,0,0)},(e,t)=>{e.setUTCMonth(e.getUTCMonth()+t)},(e,t)=>t.getUTCMonth()-e.getUTCMonth()+(t.getUTCFullYear()-e.getUTCFullYear())*12,e=>e.getUTCMonth());Fw.range;const ei=ht(e=>{e.setMonth(0,1),e.setHours(0,0,0,0)},(e,t)=>{e.setFullYear(e.getFullYear()+t)},(e,t)=>t.getFullYear()-e.getFullYear(),e=>e.getFullYear());ei.every=e=>
vendor: 8,936 bytes, line 309
309!isFinite(e=Math.floor(e))||!(e>0)?null:ht(t=>{t.setFullYear(Math.floor(t.getFullYear()/e)*e),t.setMonth(0,1),t.setHours(0,0,0,0)},(t,r)=>{t.setFullYear(t.getFullYear()+r*e)});ei.range;const ti=ht(e=>{e.setUTCMonth(0,1),e.setUTCHours(0,0,0,0)},(e,t)=>{e.setUTCFullYear(e.getUTCFullYear()+t)},(e,t)=>t.getUTCFullYear()-e.getUTCFullYear(),e=>e.getUTCFullYear());ti.every=e=>!isFinite(e=Math.floor(e))||!(e>0)?null:ht(t=>{t.setUTCFullYear(Math.floor(t.getUTCFullYear()/e)*e),t.setUTCMonth(0,1),t.setUTCHours(0,0,0,0)},(t,r)=>{t.setUTCFullYear(t.getUTCFullYear()+r*e)});ti.range;function ZN(e,t,r,n,i,a){const o=[[Ea,1,zn],[Ea,5,5*zn],[Ea,15,15*zn],[Ea,30,30*zn],[a,1,Or],[a,5,5*Or],[a,15,15*Or],[a,30,30*Or],[i,1,Wn],[i,3,3*Wn],[i,6,6*Wn],[i,12,12*Wn],[n,1,Zn],[n,2,2*Zn],[r,1,Iw],[t,1,LO],[t,3,3*LO],[e,1,bv]];function s(u,d,c){const f=d<u;f&&([u,d]=[d,u]);const h=c&&typeof c.range=="function"?c:l(u,d,c),v=h?h.range(u,+d+1):[];return f?v.reverse():v}function l(u,d,c){const f=Math.abs(d-u)/c,h=Sw(([,,g])=>g).right(o,f);if(h===o.length)return e.every(Iy(u/bv,d/bv,c));if(h===0)return rh.every(Math.max(Iy(u,d,c),1));const[v,m]=o[f/o[h-1][2]<o[h][2]/f?h-1:h];return v.every(m)}return[s,l]}const[dte,fte]=ZN(ti,Fw,zp,JN,Bw,Dw),[hte,pte]=ZN(ei,Uw,Fp,Nc,Lw,Mw);function wv(e){if(0<=e.y&&e.y<100){var t=new Date(-1,e.m,e.d,e.H,e.M,e.S,e.L);return t.setFullYear(e.y),t}return new Date(e.y,e.m,e.d,e.H,e.M,e.S,e.L)}function xv(e){if(0<=e.y&&e.y<100){var t=new Date(Date.UTC(-1,e.m,e.d,e.H,e.M,e.S,e.L));return t.setUTCFullYear(e.y),t}return new Date(Date.UTC(e.y,e.m,e.d,e.H,e.M,e.S,e.L))}function El(e,t,r){return{y:e,m:t,d:r,H:0,M:0,S:0,L:0}}function mte(e){var t=e.dateTime,r=e.date,n=e.time,i=e.periods,a=e.days,o=e.shortDays,s=e.months,l=e.shortMonths,u=kl(i),d=Pl(i),c=kl(a),f=Pl(a),h=kl(o),v=Pl(o),m=kl(s),g=Pl(s),y=kl(l),b=Pl(l),w={a:L,A,b:T,B:U,c:null,d:qO,e:qO,f:Lte,g:Gte,G:Xte,H:Ite,I:Mte,j:Dte,L:e$,m:Bte,M:Ute,p:q,q:B,Q:KO,s:GO,S:Fte,u:zte,U:Wte,V:qte,w:Hte,W:Vte,x:null,X:null,y:Kte,Y:Yte,Z:Qte,"%":VO},_={a:W,A:K,b:Z,B:xe,c:null,d:HO,e:HO,f:tre,g:dre,G:hre,H:Jte,I:Zte,j:ere,L:r$,m:rre,M:nre,p:ue,q:Ze,Q:KO,s:GO,S:ire,u:are,U:ore,V:sre,w:lre,W:ure,x:null,X:null,y:cre,Y:fre,Z:pre,"%":VO},x={a:C,A:N,b:$,B:D,c:I,d:zO,e:zO,f:Cte,g:FO,G:UO,H:WO,I:WO,j:Pte,L:Tte,m:kte,M:Ate,p:P,q:Ete,Q:$te,s:Rte,S:jte,u:wte,U:xte,V:_te,w:bte,W:Ste,x:R,X:M,y:FO,Y:UO,Z:Ote,"%":Nte};w.x=S(r,w),w.X=S(n,w),w.c=S(t,w),_.x=S(r,_),_.X=S(n,_),_.c=S(t,_);function S(G,ie){return function(ae){var H=[],ye=-1,ce=0,He=G.length,Fe,pt,Wt;for(ae instanceof Date||(ae=new Date(+ae));++ye<He;)G.charCodeAt(ye)===37&&(H.push(G.slice(ce,ye)),(pt=BO[Fe=G.charAt(++ye)])!=null?Fe=G.charAt(++ye):pt=Fe==="e"?" ":"0",(Wt=ie[Fe])&&(Fe=Wt(ae,pt)),H.push(Fe),ce=ye+1);return H.push(G.slice(ce,ye)),H.join("")}}function E(G,ie){return function(ae){var H=El(1900,void 0,1),ye=k(H,G,ae+="",0),ce,He;if(ye!=ae.length)return null;if("Q"in H)return new Date(H.Q);if("s"in H)return new Date(H.s*1e3+("L"in H?H.L:0));if(ie&&!("Z"in H)&&(H.Z=0),"p"in H&&(H.H=H.H%12+H.p*12),H.m===void 0&&(H.m="q"in H?H.q:0),"V"in H){if(H.V<1||H.V>53)return null;"w"in H||(H.w=1),"Z"in H?(ce=xv(El(H.y,0,1)),He=ce.getUTCDay(),ce=He>4||He===0?ih.ceil(ce):ih(ce),ce=Up.offset(ce,(H.V-1)*7),H.y=ce.getUTCFullYear(),H.m=ce.getUTCMonth(),H.d=ce.getUTCDate()+(H.w+6)%7):(ce=wv(El(H.y,0,1)),He=ce.getDay(),ce=He>4||He===0?nh.ceil(ce):nh(ce),ce=Nc.offset(ce,(H.V-1)*7),H.y=ce.getFullYear(),H.m=ce.getMonth(),H.d=ce.getDate()+(H.w+6)%7)}else("W"in H||"U"in H)&&("w"in H||(H.w="u"in H?H.u%7:"W"in H?1:0),He="Z"in H?xv(El(H.y,0,1)).getUTCDay():wv(El(H.y,0,1)).getDay(),H.m=0,H.d="W"in H?(H.w+6)%7+H.W*7-(He+5)%7:H.w+H.U*7-(He+6)%7);return"Z"in H?(H.H+=H.Z/100|0,H.M+=H.Z%100,xv(H)):wv(H)}}function k(G,ie,ae,H){for(var ye=0,ce=ie.length,He=ae.length,Fe,pt;ye<ce;){if(H>=He)return-1;if(Fe=ie.charCodeAt(ye++),Fe===37){if(Fe=ie.charAt(ye++),pt=x[Fe in BO?ie.charAt(ye++):Fe],!pt||(H=pt(G,ae,H))<0)return-1}else if(Fe!=ae.charCodeAt(H++))return-1}return H}function P(G,ie,ae){var H=u.exec(ie.slice(ae));return H?(G.p=d.get(H[0].toLowerCase()),ae+H[0].length):-1}function C(G,ie,ae){var H=h.exec(ie.slice(ae));return H?(G.w=v.get(H[0].toLowerCase()),ae+H[0].length):-1}function N(G,ie,ae){var H=c.exec(ie.slice(ae));return H?(G.w=f.get(H[0].toLowerCase()),ae+H[0].length):-1}function $(G,ie,ae){var H=y.exec(ie.slice(ae));return H?(G.m=b.get(H[0].toLowerCase()),ae+H[0].length):-1}function D(G,ie,ae){var H=m.exec(ie.slice(ae));return H?(G.m=g.get(H[0].toLowerCase()),ae+H[0].length):-1}function I(G,ie,ae){return k(G,t,ie,ae)}function R(G,ie,ae){return k(G,r,ie,ae)}function M(G,ie,ae){return k(G,n,ie,ae)}function L(G){return o[G.getDay()]}function A(G){return a[G.getDay()]}function T(G){return l[G.getMonth()]}function U(G){return s[G.getMonth()]}function q(G){return i[+(G.getHours()>=12)]}function B(G){return 1+~~(G.getMonth()/3)}function W(G){return o[G.getUTCDay()]}function K(G){return a[G.getUTCDay()]}function Z(G){return l[G.getUTCMonth()]}function xe(G){return s[G.getUTCMonth()]}function ue(G){return i[+(G.getUTCHours()>=12)]}function Ze(G){return 1+~~(G.getUTCMonth()/3)}return{format:function(G){var ie=S(G+="",w);return ie.toString=function(){return G},ie},parse:function(G){var ie=E(G+="",!1);return ie.toString=function(){return G},ie},utcFormat:function(G){var ie=S(G+="",_);return ie.toString=function(){return G},ie},utcParse:function(G){var ie=E(G+="",!0);return ie.toString=function(){return G},ie}}}var BO={"-":"",_:" ",0:"0"},bt=/^\s*\d+/,vte=/^%/,gte=/[\\^$*+?|[\]().{}]/g;function ve(e,t,r){var n=e<0?"-":"",i=(n?-e:e)+"",a=i.length;return n+(a<r?new Array(r-a+1).join(t)+i:i)}function yte(e){return e.replace(gte,"\\$&")}function kl(e){return new RegExp("^(?:"+e.map(yte).join("|")+")","i")}function Pl(e){return new Map(e.map((t,r)=>[t.toLowerCase(),r]))}function bte(e,t,r){var n=bt.exec(t.slice(r,r+1));return n?(e.w=+n[0],r+n[0].length):-1}function wte(e,t,r){var n=bt.exec(t.slice(r,r+1));return n?(e.u=+n[0],r+n[0].length):-1}function xte(e,t,r){var n=bt.exec(t.slice(r,r+2));return n?(e.U=+n[0],r+n[0].length):-1}function _te(e,t,r){var n=bt.exec(t.slice(r,r+2));return n?(e.V=+n[0],r+n[0].length):-1}function Ste(e,t,r){var n=bt.exec(t.slice(r,r+2));return n?(e.W=+n[0],r+n[0].length):-1}function UO(e,t,r){var n=bt.exec(t.slice(r,r+4));return n?(e.y=+n[0],r+n[0].length):-1}function FO(e,t,r){var n=bt.exec(t.slice(r,r+2));return n?(e.y=+n[0]+(+n[0]>68?1900:2e3),r+n[0].length):-1}function Ote(e,t,r){var n=/^(Z)|([+-]\d\d)(?::?(\d\d))?/.exec(t.slice(r,r+6));return n?(e.Z=n[1]?0:-(n[2]+(n[3]||"00")),r+n[0].length):-1}function Ete(e,t,r){var n=bt.exec(t.slice(r,r+1));return n?(e.q=n[0]*3-3,r+n[0].length):-1}function kte(e,t,r){var n=bt.exec(t.slice(r,r+2));return n?(e.m=n[0]-1,r+n[0].length):-1}function zO(e,t,r){var n=bt.exec(t.slice(r,r+2));return n?(e.d=+n[0],r+n[0].length):-1}function Pte(e,t,r){var n=bt.exec(t.slice(r,r+3));return n?(e.m=0,e.d=+n[0],r+n[0].length):-1}function WO(e,t,r){var n=bt.exec(t.slice(r,r+2));return n?(e.H=+n[0],r+n[0].length):-1}function Ate(e,t,r){var n=bt.exec(t.slice(r,r+2));return n?(e.M=+n[0],r+n[0].length):-1}function jte(e,t,r){var n=bt.exec(t.slice(r,r+2));return n?(e.S=+n[0],r+n[0].length):-1}function Tte(e,t,r){var n=bt.exec(t.slice(r,r+3));return n?(e.L=+n[0],r+n[0].length):-1}function Cte(e,t,r){var n=bt.exec(t.slice(r,r+6));return n?(e.L=Math.floor(n[0]/1e3),r+n[0].length):-1}function Nte(e,t,r){var n=vte.exec(t.slice(r,r+1));return n?r+n[0].length:-1}function $te(e,t,r){var n=bt.exec(t.slice(r));return n?(e.Q=+n[0],r+n[0].length):-1}function Rte(e,t,r){var n=bt.exec(t.slice(r));return n?(e.s=+n[0],r+n[0].length):-1}function qO(e,t){return ve(e.getDate(),t,2)}function Ite(e,t){return ve(e.getHours(),t,2)}function Mte(e,t){return ve(e.getHours()%12||12,t,2)}function Dte(e,t){return ve(1+Nc.count(ei(e),e),t,3)}function e$(e,t){return ve(e.getMilliseconds(),t,3)}function Lte(e,t){return e$(e,t)+"000"}function Bte(e,t){return ve(e.getMonth()+1,t,2)}function Ute(e,t){return ve(e.getMinutes(),t,2)}function Fte(e,t){return ve(e.getSeconds(),t,2)}function zte(e){var t=e.getDay();return t===0?7:t}function Wte(e,t){return ve(Fp.count(ei(e)-1,e),t,2)}function t$(e){var t=e.getDay();return t>=4||t===0?Ps(e):Ps.ceil(e)}function qte(e,t){return e=t$(e),ve(Ps.count(ei(e),e)+(ei(e).getDay()===4),t,2)}function Hte(e){return e.getDay()}function Vte(e,t){return ve(nh.count(ei(e)-1,e),t,2)}function Kte(e,t){return ve(e.getFullYear()%100,t,2)}function Gte(e,t){return e=t$(e),ve(e.getFullYear()%100,t,2)}function Yte(e,t){return ve(e.getFullYear()%1e4,t,4)}function Xte(e,t){var r=e.getDay();return e=r>=4||r===0?Ps(e):Ps.ceil(e),ve(e.getFullYear()%1e4,t,4)}function Qte(e){var t=e.getTimezoneOffset();return(t>0?"-":(t*=-1,"+"))+ve(t/60|0,"0",2)+ve(t%60,"0",2)}function HO(e,t){return ve(e.getUTCDate(),t,2)}function Jte(e,t){return ve(e.getUTCHours(),t,2)}function Zte(e,t){return ve(e.getUTCHours()%12||12,t,2)}
309function ere(e,t){return ve(1+Up.count(ti(e),e),t,3)}function r$(e,t){return ve(e.getUTCMilliseconds(),t,3)}function tre(e,t){return r$(e,t)+"000"}function rre(e,t){return ve(e.getUTCMonth()+1,t,2)}function nre(e,t){return ve(e.getUTCMinutes(),t,2)}function ire(e,t){return ve(e.getUTCSeconds(),t,2)}function are(e){var t=e.getUTCDay();return t===0?7:t}function ore(e,t){return ve(zp.count(ti(e)-1,e),t,2)}function n$(e){var t=e.getUTCDay();return t>=4||t===0?As(e):As.ceil(e)}function sre(e,t){return e=n$(e),ve(As.count(ti(e),e)+(ti(e).getUTCDay()===4),t,2)}function lre(e){return e.getUTCDay()}function ure(e,t){return ve(ih.count(ti(e)-1,e),t,2)}function cre(e,t){return ve(e.getUTCFullYear()%100,t,2)}function dre(e,t){return e=n$(e),ve(e.getUTCFullYear()%100,t,2)}function fre(e,t){return ve(e.getUTCFullYear()%1e4,t,4)}function hre(e,t){var r=e.getUTCDay();return e=r>=4||r===0?As(e):As.ceil(e),ve(e.getUTCFullYear()%1e4,t,4)}function pre(){return"+0000"}function VO(){return"%"}function KO(e){return+e}function GO(e){return Math.floor(+e/1e3)}var bo,i$,a$;mre({dateTime:"%x, %X",date:"%-m/%-d/%Y",time:"%-I:%M:%S %p",periods:["AM","PM"],days:["Sunday","Monday","Tuesday","Wednesday","Thursday","Friday","Saturday"],shortDays:["Sun","Mon","Tue","Wed","Thu","Fri","Sat"],months:["January","February","March","April","May","June","July","August","September","October","November","December"],shortMonths:["Jan","Feb","Mar","Apr","May","Jun","Jul","Aug","Sep","Oct","Nov","Dec"]});function mre(e){return bo=mte(e),i$=bo.format,bo.parse,a$=bo.utcFormat,bo.utcParse,bo}function vre(e){return new Date(e)}function gre(e){return e instanceof Date?+e:+new Date(+e)}function zw(e,t,r,n,i,a,o,s,l,u){var d=Aw(),c=d.invert,f=d.domain,h=u(".%L"),v=u(":%S"),m=u("%I:%M"),g=u("%I %p"),y=u("%a %d"),b=u("%b %d"),w=u("%B"),_=u("%Y");function x(S){return(l(S)<S?h:s(S)<S?v:o(S)<S?m:a(S)<S?g:n(S)<S?i(S)<S?y:b:r(S)<S?w:_)(S)}return d.invert=function(S){return new Date(c(S))},d.domain=function(S){return arguments.length?f(Array.from(S,gre)):f().map(vre)},d.ticks=function(S){var E=f();return e(E[0],E[E.length-1],S??10)},d.tickFormat=function(S,E){return E==null?x:u(E)},d.nice=function(S){var E=f();return(!S||typeof S.range!="function")&&(S=t(E[0],E[E.length-1],S??10)),S?f(HN(E,S)):d},d.copy=function(){return Cc(d,zw(e,t,r,n,i,a,o,s,l,u))},d}function yre(){return Cr.apply(zw(hte,pte,ei,Uw,Fp,Nc,Lw,Mw,Ea,i$).domain([new Date(2e3,0,1),new Date(2e3,0,2)]),arguments)}function bre(){return Cr.apply(zw(dte,fte,ti,Fw,zp,Up,Bw,Dw,Ea,a$).domain([Date.UTC(2e3,0,1),Date.UTC(2e3,0,2)]),arguments)}function Wp(){var e=0,t=1,r,n,i,a,o=Bt,s=!1,l;function u(c){return c==null||isNaN(c=+c)?l:o(i===0?.5:(c=(a(c)-r)*i,s?Math.max(0,Math.min(1,c)):c))}u.domain=function(c){return arguments.length?([e,t]=c,r=a(e=+e),n=a(t=+t),i=r===n?0:1/(n-r),u):[e,t]},u.clamp=function(c){return arguments.length?(s=!!c,u):s},u.interpolator=function(c){return arguments.length?(o=c,u):o};function d(c){return function(f){var h,v;return arguments.length?([h,v]=f,o=c(h,v),u):[o(0),o(1)]}}return u.range=d(ll),u.rangeRound=d(Pw),u.unknown=function(c){return arguments.length?(l=c,u):l},function(c){return a=c,r=c(e),n=c(t),i=r===n?0:1/(n-r),u}}function na(e,t){return t.domain(e.domain()).interpolator(e.interpolator()).clamp(e.clamp()).unknown(e.unknown())}function o$(){var e=ra(Wp()(Bt));return e.copy=function(){return na(e,o$())},li.apply(e,arguments)}function s$(){var e=Cw(Wp()).domain([1,10]);return e.copy=function(){return na(e,s$()).base(e.base())},li.apply(e,arguments)}function l$(){var e=Nw(Wp());return e.copy=function(){return na(e,l$()).constant(e.constant())},li.apply(e,arguments)}function Ww(){var e=$w(Wp());return e.copy=function(){return na(e,Ww()).exponent(e.exponent())},li.apply(e,arguments)}function wre(){return Ww.apply(null,arguments).exponent(.5)}function u$(){var e=[],t=Bt;function r(n){if(n!=null&&!isNaN(n=+n))return t((jc(e,n,1)-1)/(e.length-1))}return r.domain=function(n){if(!arguments.length)return e.slice();e=[];for(let i of n)i!=null&&!isNaN(i=+i)&&e.push(i);return e.sort(Wi),r},r.interpolator=function(n){return arguments.length?(t=n,r):t},r.range=function(){return e.map((n,i)=>t(i/(e.length-1)))},r.quantiles=function(n){return Array.from({length:n+1},(i,a)=>oee(e,a/n))},r.copy=function(){return u$(t).domain(e)},li.apply(r,arguments)}function qp(){var e=0,t=.5,r=1,n=1,i,a,o,s,l,u=Bt,d,c=!1,f;function h(m){return isNaN(m=+m)?f:(m=.5+((m=+d(m))-a)*(n*m<n*a?s:l),u(c?Math.max(0,Math.min(1,m)):m))}h.domain=function(m){return arguments.length?([e,t,r]=m,i=d(e=+e),a=d(t=+t),o=d(r=+r),s=i===a?0:.5/(a-i),l=a===o?0:.5/(o-a),n=a<i?-1:1,h):[e,t,r]},h.clamp=function(m){return arguments.length?(c=!!m,h):c},h.interpolator=function(m){return arguments.length?(u=m,h):u};function v(m){return function(g){var y,b,w;return arguments.length?([y,b,w]=g,u=Nee(m,[y,b,w]),h):[u(0),u(.5),u(1)]}}return h.range=v(ll),h.rangeRound=v(Pw),h.unknown=function(m){return arguments.length?(f=m,h):f},function(m){return d=m,i=m(e),a=m(t),o=m(r),s=i===a?0:.5/(a-i),l=a===o?0:.5/(o-a),n=a<i?-1:1,h}}function c$(){var e=ra(qp()(Bt));return e.copy=function(){return na(e,c$())},li.apply(e,arguments)}function d$(){var e=Cw(qp()).domain([.1,1,10]);return e.copy=function(){return na(e,d$()).base(e.base())},li.apply(e,arguments)}function f$(){var e=Nw(qp());return e.copy=function(){return na(e,f$()).constant(e.constant())},li.apply(e,arguments)}function qw(){var e=$w(qp());return e.copy=function(){return na(e,qw()).exponent(e.exponent())},li.apply(e,arguments)}function xre(){return qw.apply(null,arguments).exponent(.5)}const YO=Object.freeze(Object.defineProperty({__proto__:null,scaleBand:Bu,scaleDiverging:c$,scaleDivergingLog:d$,scaleDivergingPow:qw,scaleDivergingSqrt:xre,scaleDivergingSymlog:f$,scaleIdentity:qN,scaleImplicit:
vendor: 59,999 bytes, lines 309-335
309My,scaleLinear:th,scaleLog:VN,scaleOrdinal:Ow,scalePoint:Ql,scalePow:Rw,scaleQuantile:YN,scaleQuantize:XN,scaleRadial:GN,scaleSequential:o$,scaleSequentialLog:s$,scaleSequentialPow:Ww,scaleSequentialQuantile:u$,scaleSequentialSqrt:wre,scaleSequentialSymlog:l$,scaleSqrt:tte,scaleSymlog:KN,scaleThreshold:QN,scaleTime:yre,scaleUtc:bre,tickFormat:WN},Symbol.toStringTag,{value:"Module"}));var _re=Zs;function Sre(e,t,r){for(var n=-1,i=e.length;++n<i;){var a=e[n],o=t(a);if(o!=null&&(s===void 0?o===o&&!_re(o):r(o,s)))var s=o,l=a}return l}var h$=Sre;function Ore(e,t){return e>t}var Ere=Ore,kre=h$,Pre=Ere,Are=ol;function jre(e){return e&&e.length?kre(e,Are,Pre):void 0}var Tre=jre;const Hp=Ce(Tre);function Cre(e,t){return e<t}var Nre=Cre,$re=h$,Rre=Nre,Ire=ol;function Mre(e){return e&&e.length?$re(e,Ire,Rre):void 0}var Dre=Mre;const Vp=Ce(Dre);var Lre=nw,Bre=sl,Ure=_N,Fre=Jt;function zre(e,t){var r=Fre(e)?Lre:Ure;return r(e,Bre(t))}var Wre=zre,qre=wN,Hre=Wre;function Vre(e,t){return qre(Hre(e,t),1)}var Kre=Vre;const Gre=Ce(Kre);var Yre=bw;function Xre(e,t){return Yre(e,t)}var Qre=Xre;const Hw=Ce(Qre);var ul=1e9,Jre={precision:20,rounding:4,toExpNeg:-7,toExpPos:21,LN10:"2.302585092994045684017991454684364207601101488628772976033327900967572609677352480235997205089598298341967784042286"},Kw,qe=!0,jr="[DecimalError] ",Ba=jr+"Invalid argument: ",Vw=jr+"Exponent out of range: ",cl=Math.floor,va=Math.pow,Zre=/^(\d+(\.\d*)?|\.\d+)(e[+-]?\d+)?$/i,sr,mt=1e7,Be=7,p$=9007199254740991,ah=cl(p$/Be),Q={};Q.absoluteValue=Q.abs=function(){var e=new this.constructor(this);return e.s&&(e.s=1),e};Q.comparedTo=Q.cmp=function(e){var t,r,n,i,a=this;if(e=new a.constructor(e),a.s!==e.s)return a.s||-e.s;if(a.e!==e.e)return a.e>e.e^a.s<0?1:-1;for(n=a.d.length,i=e.d.length,t=0,r=n<i?n:i;t<r;++t)if(a.d[t]!==e.d[t])return a.d[t]>e.d[t]^a.s<0?1:-1;return n===i?0:n>i^a.s<0?1:-1};Q.decimalPlaces=Q.dp=function(){var e=this,t=e.d.length-1,r=(t-e.e)*Be;if(t=e.d[t],t)for(;t%10==0;t/=10)r--;return r<0?0:r};Q.dividedBy=Q.div=function(e){return Vn(this,new this.constructor(e))};Q.dividedToIntegerBy=Q.idiv=function(e){var t=this,r=t.constructor;return Te(Vn(t,new r(e),0,1),r.precision)};Q.equals=Q.eq=function(e){return!this.cmp(e)};Q.exponent=function(){return it(this)};Q.greaterThan=Q.gt=function(e){return this.cmp(e)>0};Q.greaterThanOrEqualTo=Q.gte=function(e){return this.cmp(e)>=0};Q.isInteger=Q.isint=function(){return this.e>this.d.length-2};Q.isNegative=Q.isneg=function(){return this.s<0};Q.isPositive=Q.ispos=function(){return this.s>0};Q.isZero=function(){return this.s===0};Q.lessThan=Q.lt=function(e){return this.cmp(e)<0};Q.lessThanOrEqualTo=Q.lte=function(e){return this.cmp(e)<1};Q.logarithm=Q.log=function(e){var t,r=this,n=r.constructor,i=n.precision,a=i+5;if(e===void 0)e=new n(10);else if(e=new n(e),e.s<1||e.eq(sr))throw Error(jr+"NaN");if(r.s<1)throw Error(jr+(r.s?"NaN":"-Infinity"));return r.eq(sr)?new n(0):(qe=!1,t=Vn(qu(r,a),qu(e,a),a),qe=!0,Te(t,i))};Q.minus=Q.sub=function(e){var t=this;return e=new t.constructor(e),t.s==e.s?g$(t,e):m$(t,(e.s=-e.s,e))};Q.modulo=Q.mod=function(e){var t,r=this,n=r.constructor,i=n.precision;if(e=new n(e),!e.s)throw Error(jr+"NaN");return r.s?(qe=!1,t=Vn(r,e,0,1).times(e),qe=!0,r.minus(t)):Te(new n(r),i)};Q.naturalExponential=Q.exp=function(){return v$(this)};Q.naturalLogarithm=Q.ln=function(){return qu(this)};Q.negated=Q.neg=function(){var e=new this.constructor(this);return e.s=-e.s||0,e};Q.plus=Q.add=function(e){var t=this;return e=new t.constructor(e),t.s==e.s?m$(t,e):g$(t,(e.s=-e.s,e))};Q.precision=Q.sd=function(e){var t,r,n,i=this;if(e!==void 0&&e!==!!e&&e!==1&&e!==0)throw Error(Ba+e);if(t=it(i)+1,n=i.d.length-1,r=n*Be+1,n=i.d[n],n){for(;n%10==0;n/=10)r--;for(n=i.d[0];n>=10;n/=10)r++}return e&&t>r?t:r};Q.squareRoot=Q.sqrt=function(){var e,t,r,n,i,a,o,s=this,l=s.constructor;if(s.s<1){if(!s.s)return new l(0);throw Error(jr+"NaN")}for(e=it(s),qe=!1,i=Math.sqrt(+s),i==0||i==1/0?(t=wn(s.d),(t.length+e)%2==0&&(t+="0"),i=Math.sqrt(t),e=cl((e+1)/2)-(e<0||e%2),i==1/0?t="5e"+e:(t=i.toExponential(),t=t.slice(0,t.indexOf("e")+1)+e),n=new l(t)):n=new l(i.toString()),r=l.precision,i=o=r+3;;)if(a=n,n=a.plus(Vn(s,a,o+2)).times(.5),wn(a.d).slice(0,o)===(t=wn(n.d)).slice(0,o)){if(t=t.slice(o-3,o+1),i==o&&t=="4999"){if(Te(a,r+1,0),a.times(a).eq(s)){n=a;break}}else if(t!="9999")break;o+=4}return qe=!0,Te(n,r)};Q.times=Q.mul=function(e){var t,r,n,i,a,o,s,l,u,d=this,c=d.constructor,f=d.d,h=(e=new c(e)).d;if(!d.s||!e.s)return new c(0);for(e.s*=d.s,r=d.e+e.e,l=f.length,u=h.length,l<u&&(a=f,f=h,h=a,o=l,l=u,u=o),a=[],o=l+u,n=o;n--;)a.push(0);for(n=u;--n>=0;){for(t=0,i=l+n;i>n;)s=a[i]+h[n]*f[i-n-1]+t,a[i--]=s%mt|0,t=s/mt|0;a[i]=(a[i]+t)%mt|0}for(;!a[--o];)a.pop();return t?++r:a.shift(),e.d=a,e.e=r,qe?Te(e,c.precision):e};Q.toDecimalPlaces=Q.todp=function(e,t){var r=this,n=r.constructor;return r=new n(r),e===void 0?r:(jn(e,0,ul),t===void 0?t=n.rounding:jn(t,0,8),Te(r,e+it(r)+1,t))};Q.toExponential=function(e,t){var r,n=this,i=n.constructor;return e===void 0?r=Ya(n,!0):(jn(e,0,ul),t===void 0?t=i.rounding:jn(t,0,8),n=Te(new i(n),e+1,t),r=Ya(n,!0,e+1)),r};Q.toFixed=function(e,t){var r,n,i=this,a=i.constructor;return e===void 0?Ya(i):(jn(e,0,ul),t===void 0?t=a.rounding:jn(t,0,8),n=Te(new a(i),e+it(i)+1,t),r=Ya(n.abs(),!1,e+it(n)+1),i.isneg()&&!i.isZero()?"-"+r:r)};Q.toInteger=Q.toint=function(){var e=this,t=e.constructor;return Te(new t(e),it(e)+1,t.rounding)};Q.toNumber=function(){return+this};Q.toPower=Q.pow=function(e){var t,r,n,i,a,o,s=this,l=s.constructor,u=12,d=+(e=new l(e));if(!e.s)return new l(sr);if(s=new l(s),!s.s){if(e.s<1)throw Error(jr+"Infinity");return s}if(s.eq(sr))return s;if(n=l.precision,e.eq(sr))return Te(s,n);if(t=e.e,r=e.d.length-1,o=t>=r,a=s.s,o){if((r=d<0?-d:d)<=p$){for(i=new l(sr),t=Math.ceil(n/Be+4),qe=!1;r%2&&(i=i.times(s),QO(i.d,t)),r=cl(r/2),r!==0;)s=s.times(s),QO(s.d,t);return qe=!0,e.s<0?new l(sr).div(i):Te(i,n)}}else if(a<0)throw Error(jr+"NaN");return a=a<0&&e.d[Math.max(t,r)]&1?-1:1,s.s=1,qe=!1,i=e.times(qu(s,n+u)),qe=!0,i=v$(i),i.s=a,i};Q.toPrecision=function(e,t){var r,n,i=this,a=i.constructor;return e===void 0?(r=it(i),n=Ya(i,r<=a.toExpNeg||r>=a.toExpPos)):(jn(e,1,ul),t===void 0?t=a.rounding:jn(t,0,8),i=Te(new a(i),e,t),r=it(i),n=Ya(i,e<=r||r<=a.toExpNeg,e)),n};Q.toSignificantDigits=Q.tosd=function(e,t){var r=this,n=r.constructor;return e===void 0?(e=n.precision,t=n.rounding):(jn(e,1,ul),t===void 0?t=n.rounding:jn(t,0,8)),Te(new n(r),e,t)};Q.toString=Q.valueOf=Q.val=Q.toJSON=Q[Symbol.for("nodejs.util.inspect.custom")]=function(){var e=this,t=it(e),r=e.constructor;return Ya(e,t<=r.toExpNeg||t>=r.toExpPos)};function m$(e,t){var r,n,i,a,o,s,l,u,d=e.constructor,c=d.precision;if(!e.s||!t.s)return t.s||(t=new d(e)),qe?Te(t,c):t;if(l=e.d,u=t.d,o=e.e,i=t.e,l=l.slice(),a=o-i,a){for(a<0?(n=l,a=-a,s=u.length):(n=u,i=o,s=l.length),o=Math.ceil(c/Be),s=o>s?o+1:s+1,a>s&&(a=s,n.length=1),n.reverse();a--;)n.push(0);n.reverse()}for(s=l.length,a=u.length,s-a<0&&(a=s,n=u,u=l,l=n),r=0;a;)r=(l[--a]=l[a]+u[a]+r)/mt|0,l[a]%=mt;for(r&&(l.unshift(r),++i),s=l.length;l[--s]==0;)l.pop();return t.d=l,t.e=i,qe?Te(t,c):t}function jn(e,t,r){if(e!==~~e||e<t||e>r)throw Error(Ba+e)}function wn(e){var t,r,n,i=e.length-1,a="",o=e[0];if(i>0){for(a+=o,t=1;t<i;t++)n=e[t]+"",r=Be-n.length,r&&(a+=xi(r)),a+=n;o=e[t],n=o+"",r=Be-n.length,r&&(a+=xi(r))}else if(o===0)return"0";for(;o%10===0;)o/=10;return a+o}var Vn=function(){function e(n,i){var a,o=0,s=n.length;for(n=n.slice();s--;)a=n[s]*i+o,n[s]=a%mt|0,o=a/mt|0;return o&&n.unshift(o),n}function t(n,i,a,o){var s,l;if(a!=o)l=a>o?1:-1;else for(s=l=0;s<a;s++)if(n[s]!=i[s]){l=n[s]>i[s]?1:-1;break}return l}function r(n,i,a){for(var o=0;a--;)n[a]-=o,o=n[a]<i[a]?1:0,n[a]=o*mt+n[a]-i[a];for(;!n[0]&&n.length>1;)n.shift()}return function(n,i,a,o){var s,l,u,d,c,f,h,v,m,g,y,b,w,_,x,S,E,k,P=n.constructor,C=n.s==i.s?1:-1,N=n.d,$=i.d;if(!n.s)return new P(n);if(!i.s)throw Error(jr+"Division by zero");for(l=n.e-i.e,E=$.length,x=N.length,h=new P(C),v=h.d=[],u=0;$[u]==(N[u]||0);)++u;if($[u]>(N[u]||0)&&--l,a==null?b=a=P.precision:o?b=a+(it(n)-it(i))+1:b=a,b<0)return new P(0);if(b=b/Be+2|0,u=0,E==1)for(d=0,$=$[0],b++;(u<x||d)&&b--;u++)w=d*mt+(N[u]||0),v[u]=w/$|0,d=w%$|0;else{for(d=mt/($[0]+1)|0,d>1&&($=e($,d),N=e(N,d),E=$.length,x=N.length),_=E,m=N.slice(0,E),g=m.length;g<E;)m[g++]=0;k=$.slice(),k.unshift(0),S=$[0],$[1]>=mt/2&&++S;do d=0,s=t($,m,E,g),s<0?(y=m[0],E!=g&&(y=y*mt+(m[1]||0)),d=y/S|0,d>1?(d>=mt&&(d=mt-1),c=e($,d),f=c.length,g=m.length,s=t(c,m,f,g),s==1&&(d--,r(c,E<f?k:$,f))):(d==0&&(s=d=1),c=$.slice()),f=c.length,f<g&&c.unshift(0),r(m,c,g),s==-1&&(g=m.length,s=t($,m,E,g),s<1&&(d++,r(m,E<g?k:$,g))),g=m.length):s===0&&(d++,m=[0]),v[u++]=d,s&&m[0]?m[g++]=N[_]||0:(m=[N[_]],g=1);while((_++<x||m[0]!==void 0)&&b--)}return v[0]||v.shift(),h.e=l,Te(h,o?a+it(h)+1:a)}}();function v$(e,t){var r,n,i,a,o,s,l=0,u=0,d=e.constructor,c=d.precision;if(it(e)>16)throw Error(Vw+it(e));if(!e.s)return new d(sr);for(t==null?(qe=!1,s=c):s=t,o=new d(.03125);e.abs().gte(.1);)e=e.times(o),u+=5;for(n=Math.log(va(2,u))/Math.LN10*2+5|0,s+=n,r=i=a=new d(sr),d.precision=s;;){if(i=Te(i.times(e),s),r=r.times(++l),o=a.plus(Vn(i,r,s)),wn(o.d).slice(0,s)===wn(a.d).slice(0,s)){for(;u--;)a=Te(a.times(a),s);return d.precision=c,t==null?(qe=!0,Te(a,c)):a}a=o}}function it(e){for(var t=e.e*Be,r=e.d[0];r>=10;r/=10)t++;return t}function _v(e,t,r){if(t>e.LN10.sd())throw qe=!0,r&&(e.precision=r),Error(jr+"LN10 precision limit exceeded");return Te(new e(e.LN10),t)}function xi(e){for(var t="";e--;)t+="0";return t}function qu(e,t){var r,n,i,a,o,s,l,u,d,c=1,f=10,h=e,v=h.d,m=h.constructor,g=m.precision;if(h.s<1)throw Error(jr+(h.s?"NaN":"-Infinity"));if(h.eq(sr))return new m(0);if(t==null?(qe=!1,u=g):u=t,h.eq(10))return t==null&&(qe=!0),_v(m,u);if(u+=f,m.precision=u,r=wn(v),n=r.charAt(0),a=it(h),Math.abs(a)<15e14){for(;n<7&&n!=1||n==1&&r.charAt(1)>3;)h=h.times(e),r=wn(h.d),n=r.charAt(0),c++;a=it(h),n>1?(h=new m("0."+r),a++):h=new m(n+"."+r.slice(1))}else return l=_v(m,u+2,g).times(a+""),h=qu(new m(n+"."+r.slice(1)),u-f).plus(l),m.precision=g,t==null?(qe=!0,Te(h,g)):h;for(s=o=h=Vn(h.minus(sr),h.plus(sr),u),d=Te(h.times(h),u),i=3;;){if(o=Te(o.times(d),u),l=s.plus(Vn(o,new m(i),u)),wn(l.d).slice(0,u)===wn(s.d).slice(0,u))return s=s.times(2),a!==0&&(s=s.plus(_v(m,u+2,g).times(a+""))),s=Vn(s,new m(c),u),m.precision=g,t==null?(qe=!0,Te(s,g)):s;s=l,i+=2}}function XO(e,t){var r,n,i;for((r=t.indexOf("."))>-1&&(t=t.replace(".","")),(n=t.search(/e/i))>0?(r<0&&(r=n),r+=+t.slice(n+1),t=t.substring(0,n)):r<0&&(r=t.length),n=0;t.charCodeAt(n)===48;)++n;for(i=t.length;t.charCodeAt(i-1)===48;)--i;if(t=t.slice(n,i),t){if(i-=n,r=r-n-1,e.e=cl(r/Be),e.d=[],n=(r+1)%Be,r<0&&(n+=Be),n<i){for(n&&e.d.push(+t.slice(0,n)),i-=Be;n<i;)e.d.push(+t.slice(n,n+=Be));t=t.slice(n),n=Be-t.length}else n-=i;for(;n--;)t+="0";if(e.d.push(+t),qe&&(e.e>ah||e.e<-ah))throw Error(Vw+r)}else e.s=0,e.e=0,e.d=[0];return e}function Te(e,t,r){var n,i,a,o,s,l,u,d,c=e.d;for(o=1,a=c[0];a>=10;a/=10)o++;if(n=t-o,n<0)n+=Be,i=t,u=c[d=0];else{if(d=Math.ceil((n+1)/Be),a=c.length,d>=a)return e;for(u=a=c[d],o=1;a>=10;a/=10)o++;n%=Be,i=n-Be+o}if(r!==void 0&&(a=va(10,o-i-1),s=u/a%10|0,l=t<0||c[d+1]!==void 0||u%a,l=r<4?(s||l)&&(r==0||r==(e.s<0?3:2)):s>5||s==5&&(r==4||l||r==6&&(n>0?i>0?u/va(10,o-i):0:c[d-1])%10&1||r==(e.s<0?8:7))),t<1||!c[0])return l?(a=it(e),c.length=1,t=t-a-1,c[0]=va(10,(Be-t%Be)%Be),e.e=cl(-t/Be)||0):(c.length=1,c[0]=e.e=e.s=0),e;if(n==0?(c.length=d,a=1,d--):(c.length=d+1,a=va(10,Be-n),c[d]=i>0?(u/va(10,o-i)%va(10,i)|0)*a:0),l)for(;;)if(d==0){(c[0]+=a)==mt&&(c[0]=1,++e.e);break}else{if(c[d]+=a,c[d]!=mt)break;c[d--]=0,a=1}for(n=c.length;c[--n]===0;)c.pop();if(qe&&(e.e>ah||e.e<-ah))throw Error(Vw+it(e));return e}function g$(e,t){var r,n,i,a,o,s,l,u,d,c,f=e.constructor,h=f.precision;if(!e.s||!t.s)return t.s?t.s=-t.s:t=new f(e),qe?Te(t,h):t;if(l=e.d,c=t.d,n=t.e,u=e.e,l=l.slice(),o=u-n,o){for(d=o<0,d?(r=l,o=-o,s=c.length):(r=c,n=u,s=l.length),i=Math.max(Math.ceil(h/Be),s)+2,o>i&&(o=i,r.length=1),r.reverse(),i=o;i--;)r.push(0);r.reverse()}else{for(i=l.length,s=c.length,d=i<s,d&&(s=i),i=0;i<s;i++)if(l[i]!=c[i]){d=l[i]<c[i];break}o=0}for(d&&(r=l,l=c,c=r,t.s=-t.s),s=l.length,i=c.length-s;i>0;--i)l[s++]=0;for(i=c.length;i>o;){if(l[--i]<c[i]){for(a=i;a&&l[--a]===0;)l[a]=mt-1;--l[a],l[i]+=mt}l[i]-=c[i]}for(;l[--s]===0;)l.pop();for(;l[0]===0;l.shift())--n;return l[0]?(t.d=l,t.e=n,qe?Te(t,h):t):new f(0)}function Ya(e,t,r){var n,i=it(e),a=wn(e.d),o=a.length;return t?(r&&(n=r-o)>0?a=a.charAt(0)+"."+a.slice(1)+xi(n):o>1&&(a=a.charAt(0)+"."+a.slice(1)),a=a+(i<0?"e":"e+")+i):i<0?(a="0."+xi(-i-1)+a,r&&(n=r-o)>0&&(a+=xi(n))):i>=o?(a+=xi(i+1-o),r&&(n=r-i-1)>0&&(a=a+"."+xi(n))):((n=i+1)<o&&(a=a.slice(0,n)+"."+a.slice(n)),r&&(n=r-o)>0&&(i+1===o&&(a+="."),a+=xi(n))),e.s<0?"-"+a:a}function QO(e,t){if(e.length>t)return e.length=t,!0}function y$(e){var t,r,n;function i(a){var o=this;if(!(o instanceof i))return new i(a);if(o.constructor=i,a instanceof i){o.s=a.s,o.e=a.e,o.d=(a=a.d)?a.slice():a;return}if(typeof a=="number"){if(a*0!==0)throw Error(Ba+a);if(a>0)o.s=1;else if(a<0)a=-a,o.s=-1;else{o.s=0,o.e=0,o.d=[0];return}if(a===~~a&&a<1e7){o.e=0,o.d=[a];return}return XO(o,a.toString())}else if(typeof a!="string")throw Error(Ba+a);if(a.charCodeAt(0)===45?(a=a.slice(1),o.s=-1):o.s=1,Zre.test(a))XO(o,a);else throw Error(Ba+a)}if(i.prototype=Q,i.ROUND_UP=0,i.ROUND_DOWN=1,i.ROUND_CEIL=2,i.ROUND_FLOOR=3,i.ROUND_HALF_UP=4,i.ROUND_HALF_DOWN=5,i.ROUND_HALF_EVEN=6,i.ROUND_HALF_CEIL=7,i.ROUND_HALF_FLOOR=8,i.clone=y$,i.config=i.set=ene,e===void 0&&(e={}),e)for(n=["precision","rounding","toExpNeg","toExpPos","LN10"],t=0;t<n.length;)e.hasOwnProperty(r=n[t++])||(e[r]=this[r]);return i.config(e),i}function ene(e){if(!e||typeof e!="object")throw Error(jr+"Object expected");var t,r,n,i=["precision",1,ul,"rounding",0,8,"toExpNeg",-1/0,0,"toExpPos",0,1/0];for(t=0;t<i.length;t+=3)if((n=e[r=i[t]])!==void 0)if(cl(n)===n&&n>=i[t+1]&&n<=i[t+2])this[r]=n;else throw Error(Ba+r+": "+n);if((n=e[r="LN10"])!==void 0)if(n==Math.LN10)this[r]=new this(n);else throw Error(Ba+r+": "+n);return this}var Kw=y$(Jre);sr=new Kw(1);const Ae=Kw;function tne(e){return ane(e)||ine(e)||nne(e)||rne()}function rne(){throw new TypeError(`Invalid attempt to spread non-iterable instance. 310In order to be iterable, non-array objects must have a [Symbol.iterator]() method.`)}function nne(e,t){if(e){if(typeof e=="string")return Uy(e,t);var r=Object.prototype.toString.call(e).slice(8,-1);if(r==="Object"&&e.constructor&&(r=e.constructor.name),r==="Map"||r==="Set")return Array.from(e);if(r==="Arguments"||/^(?:Ui|I)nt(?:8|16|32)(?:Clamped)?Array$/.test(r))return Uy(e,t)}}function ine(e){if(typeof Symbol<"u"&&Symbol.iterator in Object(e))return Array.from(e)}function ane(e){if(Array.isArray(e))return Uy(e)}function Uy(e,t){(t==null||t>e.length)&&(t=e.length);for(var r=0,n=new Array(t);r<t;r++)n[r]=e[r];return n}var one=function(t){return t},b$={"@@functional/placeholder":!0},w$=function(t){return t===b$},JO=function(t){return function r(){return arguments.length===0||arguments.length===1&&w$(arguments.length<=0?void 0:arguments[0])?r:t.apply(void 0,arguments)}},sne=function e(t,r){return t===1?r:JO(function(){for(var n=arguments.length,i=new Array(n),a=0;a<n;a++)i[a]=arguments[a];var o=i.filter(function(s){return s!==b$}).length;return o>=t?r.apply(void 0,i):e(t-o,JO(function(){for(var s=arguments.length,l=new Array(s),u=0;u<s;u++)l[u]=arguments[u];var d=i.map(function(c){return w$(c)?l.shift():c});return r.apply(void 0,tne(d).concat(l))}))})},Kp=function(t){return sne(t.length,t)},Fy=function(t,r){for(var n=[],i=t;i<r;++i)n[i-t]=i;return n},lne=Kp(function(e,t){return Array.isArray(t)?t.map(e):Object.keys(t).map(function(r){return t[r]}).map(e)}),une=function(){for(var t=arguments.length,r=new Array(t),n=0;n<t;n++)r[n]=arguments[n];if(!r.length)return one;var i=r.reverse(),a=i[0],o=i.slice(1);return function(){return o.reduce(function(s,l){return l(s)},a.apply(void 0,arguments))}},zy=function(t){return Array.isArray(t)?t.reverse():t.split("").reverse.join("")},x$=function(t){var r=null,n=null;return function(){for(var i=arguments.length,a=new Array(i),o=0;o<i;o++)a[o]=arguments[o];return r&&a.every(function(s,l){return s===r[l]})||(r=a,n=t.apply(void 0,a)),n}};function cne(e){var t;return e===0?t=1:t=Math.floor(new Ae(e).abs().log(10).toNumber())+1,t}function dne(e,t,r){for(var n=new Ae(e),i=0,a=[];n.lt(t)&&i<1e5;)a.push(n.toNumber()),n=n.add(r),i++;return a}var fne=Kp(function(e,t,r){var n=+e,i=+t;return n+r*(i-n)}),hne=Kp(function(e,t,r){var n=t-+e;return n=n||1/0,(r-e)/n}),pne=Kp(function(e,t,r){var n=t-+e;return n=n||1/0,Math.max(0,Math.min(1,(r-e)/n))});const Gp={rangeStep:dne,getDigitCount:cne,interpolateNumber:fne,uninterpolateNumber:hne,uninterpolateTruncation:pne};function Wy(e){return gne(e)||vne(e)||_$(e)||mne()}function mne(){throw new TypeError(`Invalid attempt to spread non-iterable instance. 311In order to be iterable, non-array objects must have a [Symbol.iterator]() method.`)}function vne(e){if(typeof Symbol<"u"&&Symbol.iterator in Object(e))return Array.from(e)}function gne(e){if(Array.isArray(e))return qy(e)}function Hu(e,t){return wne(e)||bne(e,t)||_$(e,t)||yne()}function yne(){throw new TypeError(`Invalid attempt to destructure non-iterable instance. 312In order to be iterable, non-array objects must have a [Symbol.iterator]() method.`)}function _$(e,t){if(e){if(typeof e=="string")return qy(e,t);var r=Object.prototype.toString.call(e).slice(8,-1);if(r==="Object"&&e.constructor&&(r=e.constructor.name),r==="Map"||r==="Set")return Array.from(e);if(r==="Arguments"||/^(?:Ui|I)nt(?:8|16|32)(?:Clamped)?Array$/.test(r))return qy(e,t)}}function qy(e,t){(t==null||t>e.length)&&(t=e.length);for(var r=0,n=new Array(t);r<t;r++)n[r]=e[r];return n}function bne(e,t){if(!(typeof Symbol>"u"||!(Symbol.iterator in Object(e)))){var r=[],n=!0,i=!1,a=void 0;try{for(var o=e[Symbol.iterator](),s;!(n=(s=o.next()).done)&&(r.push(s.value),!(t&&r.length===t));n=!0);}catch(l){i=!0,a=l}finally{try{!n&&o.return!=null&&o.return()}finally{if(i)throw a}}return r}}function wne(e){if(Array.isArray(e))return e}function S$(e){var t=Hu(e,2),r=t[0],n=t[1],i=r,a=n;return r>n&&(i=n,a=r),[i,a]}function O$(e,t,r){if(e.lte(0))return new Ae(0);var n=Gp.getDigitCount(e.toNumber()),i=new Ae(10).pow(n),a=e.div(i),o=n!==1?.05:.1,s=new Ae(Math.ceil(a.div(o).toNumber())).add(r).mul(o),l=s.mul(i);return t?l:new Ae(Math.ceil(l))}function xne(e,t,r){var n=1,i=new Ae(e);if(!i.isint()&&r){var a=Math.abs(e);a<1?(n=new Ae(10).pow(Gp.getDigitCount(e)-1),i=new Ae(Math.floor(i.div(n).toNumber())).mul(n)):a>1&&(i=new Ae(Math.floor(e)))}else e===0?i=new Ae(Math.floor((t-1)/2)):r||(i=new Ae(Math.floor(e)));var o=Math.floor((t-1)/2),s=une(lne(function(l){return i.add(new Ae(l-o).mul(n)).toNumber()}),Fy);return s(0,t)}function E$(e,t,r,n){var i=arguments.length>4&&arguments[4]!==void 0?arguments[4]:0;if(!Number.isFinite((t-e)/(r-1)))return{step:new Ae(0),tickMin:new Ae(0),tickMax:new Ae(0)};var a=O$(new Ae(t).sub(e).div(r-1),n,i),o;e<=0&&t>=0?o=new Ae(0):(o=new Ae(e).add(t).div(2),o=o.sub(new Ae(o).mod(a)));var s=Math.ceil(o.sub(e).div(a).toNumber()),l=Math.ceil(new Ae(t).sub(o).div(a).toNumber()),u=s+l+1;return u>r?E$(e,t,r,n,i+1):(u<r&&(l=t>0?l+(r-u):l,s=t>0?s:s+(r-u)),{step:a,tickMin:o.sub(new Ae(s).mul(a)),tickMax:o.add(new Ae(l).mul(a))})}function _ne(e){var t=Hu(e,2),r=t[0],n=t[1],i=arguments.length>1&&arguments[1]!==void 0?arguments[1]:6,a=arguments.length>2&&arguments[2]!==void 0?arguments[2]:!0,o=Math.max(i,2),s=S$([r,n]),l=Hu(s,2),u=l[0],d=l[1];if(u===-1/0||d===1/0){var c=d===1/0?[u].concat(Wy(Fy(0,i-1).map(function(){return 1/0}))):[].concat(Wy(Fy(0,i-1).map(function(){return-1/0})),[d]);return r>n?zy(c):c}if(u===d)return xne(u,i,a);var f=E$(u,d,o,a),h=f.step,v=f.tickMin,m=f.tickMax,g=Gp.rangeStep(v,m.add(new Ae(.1).mul(h)),h);return r>n?zy(g):g}function Sne(e,t){var r=Hu(e,2),n=r[0],i=r[1],a=arguments.length>2&&arguments[2]!==void 0?arguments[2]:!0,o=S$([n,i]),s=Hu(o,2),l=s[0],u=s[1];if(l===-1/0||u===1/0)return[n,i];if(l===u)return[l];var d=Math.max(t,2),c=O$(new Ae(u).sub(l).div(d-1),a,0),f=[].concat(Wy(Gp.rangeStep(new Ae(l),new Ae(u).sub(new Ae(.99).mul(c)),c)),[u]);return n>i?zy(f):f}var One=x$(_ne),Ene=x$(Sne),kne="Invariant failed";function Xa(e,t){throw new Error(kne)}var Pne=["offset","layout","width","dataKey","data","dataPointFormatter","xAxis","yAxis"];function js(e){"@babel/helpers - typeof";return js=typeof Symbol=="function"&&typeof Symbol.iterator=="symbol"?function(t){return typeof t}:function(t){return t&&typeof Symbol=="function"&&t.constructor===Symbol&&t!==Symbol.prototype?"symbol":typeof t},js(e)}function oh(){return oh=Object.assign?Object.assign.bind():function(e){for(var t=1;t<arguments.length;t++){var r=arguments[t];for(var n in r)Object.prototype.hasOwnProperty.call(r,n)&&(e[n]=r[n])}return e},oh.apply(this,arguments)}function Ane(e,t){return Nne(e)||Cne(e,t)||Tne(e,t)||jne()}function jne(){throw new TypeError(`Invalid attempt to destructure non-iterable instance. 313In order to be iterable, non-array objects must have a [Symbol.iterator]() method.`)}function Tne(e,t){if(e){if(typeof e=="string")return ZO(e,t);var r=Object.prototype.toString.call(e).slice(8,-1);if(r==="Object"&&e.constructor&&(r=e.constructor.name),r==="Map"||r==="Set")return Array.from(e);if(r==="Arguments"||/^(?:Ui|I)nt(?:8|16|32)(?:Clamped)?Array$/.test(r))return ZO(e,t)}}function ZO(e,t){(t==null||t>e.length)&&(t=e.length);for(var r=0,n=new Array(t);r<t;r++)n[r]=e[r];return n}function Cne(e,t){var r=e==null?null:typeof Symbol<"u"&&e[Symbol.iterator]||e["@@iterator"];if(r!=null){var n,i,a,o,s=[],l=!0,u=!1;try{if(a=(r=r.call(e)).next,t!==0)for(;!(l=(n=a.call(r)).done)&&(s.push(n.value),s.length!==t);l=!0);}catch(d){u=!0,i=d}finally{try{if(!l&&r.return!=null&&(o=r.return(),Object(o)!==o))return}finally{if(u)throw i}}return s}}function Nne(e){if(Array.isArray(e))return e}function $ne(e,t){if(e==null)return{};var r=Rne(e,t),n,i;if(Object.getOwnPropertySymbols){var a=Object.getOwnPropertySymbols(e);for(i=0;i<a.length;i++)n=a[i],!(t.indexOf(n)>=0)&&Object.prototype.propertyIsEnumerable.call(e,n)&&(r[n]=e[n])}return r}function Rne(e,t){if(e==null)return{};var r={};for(var n in e)if(Object.prototype.hasOwnProperty.call(e,n)){if(t.indexOf(n)>=0)continue;r[n]=e[n]}return r}function Ine(e,t){if(!(e instanceof t))throw new TypeError("Cannot call a class as a function")}function Mne(e,t){for(var r=0;r<t.length;r++){var n=t[r];n.enumerable=n.enumerable||!1,n.configurable=!0,"value"in n&&(n.writable=!0),Object.defineProperty(e,A$(n.key),n)}}function Dne(e,t,r){return t&&Mne(e.prototype,t),Object.defineProperty(e,"prototype",{writable:!1}),e}function Lne(e,t,r){return t=sh(t),Bne(e,k$()?Reflect.construct(t,r||[],sh(e).constructor):t.apply(e,r))}function Bne(e,t){if(t&&(js(t)==="object"||typeof t=="function"))return t;if(t!==void 0)throw new TypeError("Derived constructors may only return object or undefined");return Une(e)}function Une(e){if(e===void 0)throw new ReferenceError("this hasn't been initialised - super() hasn't been called");return e}function k$(){try{var e=!Boolean.prototype.valueOf.call(Reflect.construct(Boolean,[],function(){}))}catch{}return(k$=function(){return!!e})()}function sh(e){return sh=Object.setPrototypeOf?Object.getPrototypeOf.bind():function(r){return r.__proto__||Object.getPrototypeOf(r)},sh(e)}function Fne(e,t){if(typeof t!="function"&&t!==null)throw new TypeError("Super expression must either be null or a function");e.prototype=Object.create(t&&t.prototype,{constructor:{value:e,writable:!0,configurable:!0}}),Object.defineProperty(e,"prototype",{writable:!1}),t&&Hy(e,t)}function Hy(e,t){return Hy=Object.setPrototypeOf?Object.setPrototypeOf.bind():function(n,i){return n.__proto__=i,n},Hy(e,t)}function P$(e,t,r){return t=A$(t),t in e?Object.defineProperty(e,t,{value:r,enumerable:!0,configurable:!0,writable:!0}):e[t]=r,e}function A$(e){var t=zne(e,"string");return js(t)=="symbol"?t:t+""}function zne(e,t){if(js(e)!="object"||!e)return e;var r=e[Symbol.toPrimitive];if(r!==void 0){var n=r.call(e,t||"default");if(js(n)!="object")return n;throw new TypeError("@@toPrimitive must return a primitive value.")}return(t==="string"?String:Number)(e)}var Yp=function(e){function t(){return Ine(this,t),Lne(this,t,arguments)}return Fne(t,e),Dne(t,[{key:"render",value:function(){var n=this.props,i=n.offset,a=n.layout,o=n.width,s=n.dataKey,l=n.data,u=n.dataPointFormatter,d=n.xAxis,c=n.yAxis,f=$ne(n,Pne),h=Se(f,!1);this.props.direction==="x"&&d.type!=="number"&&Xa();var v=l.map(function(m){var g=u(m,s),y=g.x,b=g.y,w=g.value,_=g.errorVal;if(!_)return null;var x=[],S,E;if(Array.isArray(_)){var k=Ane(_,2);S=k[0],E=k[1]}else S=E=_;if(a==="vertical"){var P=d.scale,C=b+i,N=C+o,$=C-o,D=P(w-S),I=P(w+E);x.push({x1:I,y1:N,x2:I,y2:$}),x.push({x1:D,y1:C,x2:I,y2:C}),x.push({x1:D,y1:N,x2:D,y2:$})}else if(a==="horizontal"){var R=c.scale,M=y+i,L=M-o,A=M+o,T=R(w-S),U=R(w+E);x.push({x1:L,y1:U,x2:A,y2:U}),x.push({x1:M,y1:T,x2:M,y2:U}),x.push({x1:L,y1:T,x2:A,y2:T})}return j.createElement(gt,oh({className:"recharts-errorBar",key:"bar-".concat(x.map(function(q){return"".concat(q.x1,"-").concat(q.x2,"-").concat(q.y1,"-").concat(q.y2)}))},h),x.map(function(q){return j.createElement("line",oh({},q,{key:"line-".concat(q.x1,"-").concat(q.x2,"-").concat(q.y1,"-").concat(q.y2)}))}))});return j.createElement(gt,{className:"recharts-errorBars"},v)}}])}(j.Component);P$(Yp,"defaultProps",{stroke:"black",strokeWidth:1.5,width:5,offset:0,layout:"horizontal"});P$(Yp,"displayName","ErrorBar");function Vu(e){"@babel/helpers - typeof";return Vu=typeof Symbol=="function"&&typeof Symbol.iterator=="symbol"?function(t){return typeof t}:function(t){return t&&typeof Symbol=="function"&&t.constructor===Symbol&&t!==Symbol.prototype?"symbol":typeof t},Vu(e)}function eE(e,t){var r=Object.keys(e);if(Object.getOwnPropertySymbols){var n=Object.getOwnPropertySymbols(e);t&&(n=n.filter(function(i){return Object.getOwnPropertyDescriptor(e,i).enumerable})),r.push.apply(r,n)}return r}function ca(e){for(var t=1;t<arguments.length;t++){var r=arguments[t]!=null?arguments[t]:{};t%2?eE(Object(r),!0).forEach(function(n){Wne(e,n,r[n])}):Object.getOwnPropertyDescriptors?Object.defineProperties(e,Object.getOwnPropertyDescriptors(r)):eE(Object(r)).forEach(function(n){Object.defineProperty(e,n,Object.getOwnPropertyDescriptor(r,n))})}return e}function Wne(e,t,r){return t=qne(t),t in e?Object.defineProperty(e,t,{value:r,enumerable:!0,configurable:!0,writable:!0}):e[t]=r,e}function qne(e){var t=Hne(e,"string");return Vu(t)=="symbol"?t:t+""}function Hne(e,t){if(Vu(e)!="object"||!e)return e;var r=e[Symbol.toPrimitive];if(r!==void 0){var n=r.call(e,t||"default");if(Vu(n)!="object")return n;throw new TypeError("@@toPrimitive must return a primitive value.")}return(t==="string"?String:Number)(e)}var j$=function(t){var r=t.children,n=t.formattedGraphicalItems,i=t.legendWidth,a=t.legendContent,o=ir(r,Zo);if(!o)return null;var s=Zo.defaultProps,l=s!==void 0?ca(ca({},s),o.props):{},u;return o.props&&o.props.payload?u=o.props&&o.props.payload:a==="children"?u=(n||[]).reduce(function(d,c){var f=c.item,h=c.props,v=h.sectors||h.data||[];return d.concat(v.map(function(m){return{type:o.props.iconType||f.props.legendType,value:m.name,color:m.fill,payload:m}}))},[]):u=(n||[]).map(function(d){var c=d.item,f=c.type.defaultProps,h=f!==void 0?ca(ca({},f),c.props):{},v=h.dataKey,m=h.name,g=h.legendType,y=h.hide;return{inactive:y,dataKey:v,type:l.iconType||g||"square",color:Gw(c),value:m||v,payload:h}}),ca(ca(ca({},l),Zo.getWithHeight(o,i)),{},{payload:u,item:o})};function Ku(e){"@babel/helpers - typeof";return Ku=typeof Symbol=="function"&&typeof Symbol.iterator=="symbol"?function(t){return typeof t}:function(t){return t&&typeof Symbol=="function"&&t.constructor===Symbol&&t!==Symbol.prototype?"symbol":typeof t},Ku(e)}function tE(e){return Yne(e)||Gne(e)||Kne(e)||Vne()}function Vne(){throw new TypeError(`Invalid attempt to spread non-iterable instance. 314In order to be iterable, non-array objects must have a [Symbol.iterator]() method.`)}function Kne(e,t){if(e){if(typeof e=="string")return Vy(e,t);var r=Object.prototype.toString.call(e).slice(8,-1);if(r==="Object"&&e.constructor&&(r=e.constructor.name),r==="Map"||r==="Set")return Array.from(e);if(r==="Arguments"||/^(?:Ui|I)nt(?:8|16|32)(?:Clamped)?Array$/.test(r))return Vy(e,t)}}function Gne(e){if(typeof Symbol<"u"&&e[Symbol.iterator]!=null||e["@@iterator"]!=null)return Array.from(e)}function Yne(e){if(Array.isArray(e))return Vy(e)}function Vy(e,t){(t==null||t>e.length)&&(t=e.length);for(var r=0,n=new Array(t);r<t;r++)n[r]=e[r];return n}function rE(e,t){var r=Object.keys(e);if(Object.getOwnPropertySymbols){var n=Object.getOwnPropertySymbols(e);t&&(n=n.filter(function(i){return Object.getOwnPropertyDescriptor(e,i).enumerable})),r.push.apply(r,n)}return r}function Je(e){for(var t=1;t<arguments.length;t++){var r=arguments[t]!=null?arguments[t]:{};t%2?rE(Object(r),!0).forEach(function(n){ts(e,n,r[n])}):Object.getOwnPropertyDescriptors?Object.defineProperties(e,Object.getOwnPropertyDescriptors(r)):rE(Object(r)).forEach(function(n){Object.defineProperty(e,n,Object.getOwnPropertyDescriptor(r,n))})}return e}function ts(e,t,r){return t=Xne(t),t in e?Object.defineProperty(e,t,{value:r,enumerable:!0,configurable:!0,writable:!0}):e[t]=r,e}function Xne(e){var t=Qne(e,"string");return Ku(t)=="symbol"?t:t+""}function Qne(e,t){if(Ku(e)!="object"||!e)return e;var r=e[Symbol.toPrimitive];if(r!==void 0){var n=r.call(e,t||"default");if(Ku(n)!="object")return n;throw new TypeError("@@toPrimitive must return a primitive value.")}return(t==="string"?String:Number)(e)}function Tn(e,t,r){return we(e)||we(t)?r:ct(t)?kr(e,t,r):fe(t)?t(e):r}function Jl(e,t,r,n){var i=Gre(e,function(s){return Tn(s,t)});if(r==="number"){var a=i.filter(function(s){return Y(s)||parseFloat(s)});return a.length?[Vp(a),Hp(a)]:[1/0,-1/0]}var o=n?i.filter(function(s){return!we(s)}):i;return o.map(function(s){return ct(s)||s instanceof Date?s:""})}var Jne=function(t){var r,n=arguments.length>1&&arguments[1]!==void 0?arguments[1]:[],i=arguments.length>2?arguments[2]:void 0,a=arguments.length>3?arguments[3]:void 0,o=-1,s=(r=n==null?void 0:n.length)!==null&&r!==void 0?r:0;if(s<=1)return 0;if(a&&a.axisType==="angleAxis"&&Math.abs(Math.abs(a.range[1]-a.range[0])-360)<=1e-6)for(var l=a.range,u=0;u<s;u++){var d=u>0?i[u-1].coordinate:i[s-1].coordinate,c=i[u].coordinate,f=u>=s-1?i[0].coordinate:i[u+1].coordinate,h=void 0;if(Xr(c-d)!==Xr(f-c)){var v=[];if(Xr(f-c)===Xr(l[1]-l[0])){h=f;var m=c+l[1]-l[0];v[0]=Math.min(m,(m+d)/2),v[1]=Math.max(m,(m+d)/2)}else{h=d;var g=f+l[1]-l[0];v[0]=Math.min(c,(g+c)/2),v[1]=Math.max(c,(g+c)/2)}var y=[Math.min(c,(h+c)/2),Math.max(c,(h+c)/2)];if(t>y[0]&&t<=y[1]||t>=v[0]&&t<=v[1]){o=i[u].index;break}}else{var b=Math.min(d,f),w=Math.max(d,f);if(t>(b+c)/2&&t<=(w+c)/2){o=i[u].index;break}}}else for(var _=0;_<s;_++)if(_===0&&t<=(n[_].coordinate+n[_+1].coordinate)/2||_>0&&_<s-1&&t>(n[_].coordinate+n[_-1].coordinate)/2&&t<=(n[_].coordinate+n[_+1].coordinate)/2||_===s-1&&t>(n[_].coordinate+n[_-1].coordinate)/2){o=n[_].index;break}return o},Gw=function(t){var r,n=t,i=n.type.displayName,a=(r=t.type)!==null&&r!==void 0&&r.defaultProps?Je(Je({},t.type.defaultProps),t.props):t.props,o=a.stroke,s=a.fill,l;switch(i){case"Line":l=o;break;case"Area":case"Radar":l=o&&o!=="none"?o:s;break;default:l=s;break}return l},Zne=function(t){var r=t.barSize,n=t.totalSize,i=t.stackGroups,a=i===void 0?{}:i;if(!a)return{};for(var o={},s=Object.keys(a),l=0,u=s.length;l<u;l++)for(var d=a[s[l]].stackGroups,c=Object.keys(d),f=0,h=c.length;f<h;f++){var v=d[c[f]],m=v.items,g=v.cateAxisId,y=m.filter(function(E){return Hn(E.type).indexOf("Bar")>=0});if(y&&y.length){var b=y[0].type.defaultProps,w=b!==void 0?Je(Je({},b),y[0].props):y[0].props,_=w.barSize,x=w[g];o[x]||(o[x]=[]);var S=we(_)?r:_;o[x].push({item:y[0],stackList:y.slice(1),barSize:we(S)?void 0:Ga(S,n,0)})}}return o},eie=function(t){var r=t.barGap,n=t.barCategoryGap,i=t.bandSize,a=t.sizeList,o=a===void 0?[]:a,s=t.maxBarSize,l=o.length;if(l<1)return null;var u=Ga(r,i,0,!0),d,c=[];if(o[0].barSize===+o[0].barSize){var f=!1,h=i/l,v=o.reduce(function(_,x){return _+x.barSize||0},0);v+=(l-1)*u,v>=i&&(v-=(l-1)*u,u=0),v>=i&&h>0&&(f=!0,h*=.9,v=l*h);var m=(i-v)/2>>0,g={offset:m-u,size:0};d=o.reduce(function(_,x){var S={item:x.item,position:{offset:g.offset+g.size+u,size:f?h:x.barSize}},E=[].concat(tE(_),[S]);return g=E[E.length-1].position,x.stackList&&x.stackList.length&&x.stackList.forEach(function(k){E.push({item:k,position:g})}),E},c)}else{var y=Ga(n,i,0,!0);i-2*y-(l-1)*u<=0&&(u=0);var b=(i-2*y-(l-1)*u)/l;b>1&&(b>>=0);var w=s===+s?Math.min(b,s):b;d=o.reduce(function(_,x,S){var E=[].concat(tE(_),[{item:x.item,position:{offset:y+(b+u)*S+(b-w)/2,size:w}}]);return x.stackList&&x.stackList.length&&x.stackList.forEach(function(k){E.push({item:k,position:E[E.length-1].position})}),E},c)}return d},tie=function(t,r,n,i){var a=n.children,o=n.width,s=n.margin,l=o-(s.left||0)-(s.right||0),u=j$({children:a,legendWidth:l});if(u){var d=i||{},c=d.width,f=d.height,h=u.align,v=u.verticalAlign,m=u.layout;if((m==="vertical"||m==="horizontal"&&v==="middle")&&h!=="center"&&Y(t[h]))return Je(Je({},t),{},ts({},h,t[h]+(c||0)));if((m==="horizontal"||m==="vertical"&&h==="center")&&v!=="middle"&&Y(t[v]))return Je(Je({},t),{},ts({},v,t[v]+(f||0)))}return t},rie=function(t,r,n){return we(r)?!0:t==="horizontal"?r==="yAxis":t==="vertical"||n==="x"?r==="xAxis":n==="y"?r==="yAxis":!0},T$=function(t,r,n,i,a){var o=r.props.children,s=tn(o,Yp).filter(function(u){return rie(i,a,u.props.direction)});if(s&&s.length){var l=s.map(function(u){return u.props.dataKey});return t.reduce(function(u,d){var c=Tn(d,n);if(we(c))return u;var f=Array.isArray(c)?[Vp(c),Hp(c)]:[c,c],h=l.reduce(function(v,m){var g=Tn(d,m,0),y=f[0]-Math.abs(Array.isArray(g)?g[0]:g),b=f[1]+Math.abs(Array.isArray(g)?g[1]:g);return[Math.min(y,v[0]),Math.max(b,v[1])]},[1/0,-1/0]);return[Math.min(h[0],u[0]),Math.max(h[1],u[1])]},[1/0,-1/0])}return null},nie=function(t,r,n,i,a){var o=r.map(function(s){return T$(t,s,n,a,i)}).filter(function(s){return!we(s)});return o&&o.length?o.reduce(function(s,l){return[Math.min(s[0],l[0]),Math.max(s[1],l[1])]},[1/0,-1/0]):null},C$=function(t,r,n,i,a){var o=r.map(function(l){var u=l.props.dataKey;return n==="number"&&u&&T$(t,l,u,i)||Jl(t,u,n,a)});if(n==="number")return o.reduce(function(l,u){return[Math.min(l[0],u[0]),Math.max(l[1],u[1])]},[1/0,-1/0]);var s={};return o.reduce(function(l,u){for(var d=0,c=u.length;d<c;d++)s[u[d]]||(s[u[d]]=!0,l.push(u[d]));return l},[])},N$=function(t,r){return t==="horizontal"&&r==="xAxis"||t==="vertical"&&r==="yAxis"||t==="centric"&&r==="angleAxis"||t==="radial"&&r==="radiusAxis"},ka=function(t,r,n){if(!t)return null;var i=t.scale,a=t.duplicateDomain,o=t.type,s=t.range,l=t.realScaleType==="scaleBand"?i.bandwidth()/2:2,u=(r||n)&&o==="category"&&i.bandwidth?i.bandwidth()/l:0;if(u=t.axisType==="angleAxis"&&(s==null?void 0:s.length)>=2?Xr(s[0]-s[1])*2*u:u,r&&(t.ticks||t.niceTicks)){var d=(t.ticks||t.niceTicks).map(function(c){var f=a?a.indexOf(c):c;return{coordinate:i(f)+u,value:c,offset:u}});return d.filter(function(c){return!Ac(c.coordinate)})}return t.isCategorical&&t.categoricalDomain?t.categoricalDomain.map(function(c,f){return{coordinate:i(c)+u,value:c,index:f,offset:u}}):i.ticks&&!n?i.ticks(t.tickCount).map(function(c){return{coordinate:i(c)+u,value:c,offset:u}}):i.domain().map(function(c,f){return{coordinate:i(c)+u,value:a?a[c]:c,index:f,offset:u}})},Sv=new WeakMap,_d=function(t,r){if(typeof r!="function")return t;Sv.has(t)||Sv.set(t,new WeakMap);var n=Sv.get(t);if(n.has(r))return n.get(r);var i=function(){t.apply(void 0,arguments),r.apply(void 0,arguments)};return n.set(r,i),i},iie=function(t,r,n){var i=t.scale,a=t.type,o=t.layout,s=t.axisType;if(i==="auto")return o==="radial"&&s==="radiusAxis"?{scale:Bu(),realScaleType:"band"}:o==="radial"&&s==="angleAxis"?{scale:th(),realScaleType:"linear"}:a==="category"&&r&&(r.indexOf("LineChart")>=0||r.indexOf("AreaChart")>=0||r.indexOf("ComposedChart")>=0&&!n)?{scale:Ql(),realScaleType:"point"}:a==="category"?{scale:Bu(),realScaleType:"band"}:{scale:th(),realScaleType:"linear"};if(Ka(i)){var l="scale".concat(Np(i));return{scale:(YO[l]||Ql)(),realScaleType:YO[l]?l:"point"}}return fe(i)?{scale:i}:{scale:Ql(),realScaleType:"point"}},nE=1e-4,aie=function(t){var r=t.domain();if(!(!r||r.length<=2)){var n=r.length,i=t.range(),a=Math.min(i[0],i[1])-nE,o=Math.max(i[0],i[1])+nE,s=t(r[0]),l=t(r[n-1]);(s<a||s>o||l<a||l>o)&&t.domain([r[0],r[n-1]])}},oie=function(t,r){if(!t)return null;for(var n=0,i=t.length;n<i;n++)if(t[n].item===r)return t[n].position;return null},sie=function(t,r){if(!r||r.length!==2||!Y(r[0])||!Y(r[1]))return t;var n=Math.min(r[0],r[1]),i=Math.max(r[0],r[1]),a=[t[0],t[1]];return(!Y(t[0])||t[0]<n)&&(a[0]=n),(!Y(t[1])||t[1]>i)&&(a[1]=i),a[0]>i&&(a[0]=i),a[1]<n&&(a[1]=n),a},lie=function(t){var r=t.length;if(!(r<=0))for(var n=0,i=t[0].length;n<i;++n)for(var a=0,o=0,s=0;s<r;++s){var l=Ac(t[s][n][1])?t[s][n][0]:t[s][n][1];l>=0?(t[s][n][0]=a,t[s][n][1]=a+l,a=t[s][n][1]):(t[s][n][0]=o,t[s][n][1]=o+l,o=t[s][n][1])}},uie=function(t){var r=t.length;if(!(r<=0))for(var n=0,i=t[0].length;n<i;++n)for(var a=0,o=0;o<r;++o){var s=Ac(t[o][n][1])?t[o][n][0]:t[o][n][1];s>=0?(t[o][n][0]=a,t[o][n][1]=a+s,a=t[o][n][1]):(t[o][n][0]=0,t[o][n][1]=0)}},cie={sign:lie,expand:SV,none:xs,silhouette:OV,wiggle:EV,positive:uie},die=function(t,r,n){var i=r.map(function(s){return s.props.dataKey}),a=cie[n],o=_V().keys(i).value(function(s,l){return+Tn(s,l,0)}).order(gy).offset(a);return o(t)},fie=function(t,r,n,i,a,o){if(!t)return null;var s=o?r.reverse():r,l={},u=s.reduce(function(c,f){var h,v=(h=f.type)!==null&&h!==void 0&&h.defaultProps?Je(Je({},f.type.defaultProps),f.props):f.props,m=v.stackId,g=v.hide;if(g)return c;var y=v[n],b=c[y]||{hasStack:!1,stackGroups:{}};if(ct(m)){var w=b.stackGroups[m]||{numericAxisId:n,cateAxisId:i,items:[]};w.items.push(f),b.hasStack=!0,b.stackGroups[m]=w}else b.stackGroups[Cp("_stackId_")]={numericAxisId:n,cateAxisId:i,items:[f]};return Je(Je({},c),{},ts({},y,b))},l),d={};return Object.keys(u).reduce(function(c,f){var h=u[f];if(h.hasStack){var v={};h.stackGroups=Object.keys(h.stackGroups).reduce(function(m,g){var y=h.stackGroups[g];return Je(Je({},m),{},ts({},g,{numericAxisId:n,cateAxisId:i,items:y.items,stackedData:die(t,y.items,a)}))},v)}return Je(Je({},c),{},ts({},f,h))},d)},hie=function(t,r){var n=r.realScaleType,i=r.type,a=r.tickCount,o=r.originalDomain,s=r.allowDecimals,l=n||r.scale;if(l!=="auto"&&l!=="linear")return null;if(a&&i==="number"&&o&&(o[0]==="auto"||o[1]==="auto")){var u=t.domain();if(!u.length)return null;var d=One(u,a,s);return t.domain([Vp(d),Hp(d)]),{niceTicks:d}}if(a&&i==="number"){var c=t.domain(),f=Ene(c,a,s);return{niceTicks:f}}return null},iE=function(t){var r=t.axis,n=t.ticks,i=t.offset,a=t.bandSize,o=t.entry,s=t.index;if(r.type==="category")return n[s]?n[s].coordinate+i:null;var l=Tn(o,r.dataKey,r.domain[s]);return we(l)?null:r.scale(l)-a/2+i},pie=function(t){var r=t.numericAxis,n=r.scale.domain();if(r.type==="number"){var i=Math.min(n[0],n[1]),a=Math.max(n[0],n[1]);return i<=0&&a>=0?0:a<0?a:i}return n[0]},mie=function(t,r){var n,i=(n=t.type)!==null&&n!==void 0&&n.defaultProps?Je(Je({},t.type.defaultProps),t.props):t.props,a=i.stackId;if(ct(a)){var o=r[a];if(o){var s=o.items.indexOf(t);return s>=0?o.stackedData[s]:null}}return null},vie=function(t){return t.reduce(function(r,n){return[Vp(n.concat([r[0]]).filter(Y)),Hp(n.concat([r[1]]).filter(Y))]},[1/0,-1/0])},$$=function(t,r,n){return Object.keys(t).reduce(function(i,a){var o=t[a],s=o.stackedData,l=s.reduce(function(u,d){var c=vie(d.slice(r,n+1));return[Math.min(u[0],c[0]),Math.max(u[1],c[1])]},[1/0,-1/0]);return[Math.min(l[0],i[0]),Math.max(l[1],i[1])]},[1/0,-1/0]).map(function(i){return i===1/0||i===-1/0?0:i})},aE=/^dataMin[\s]*-[\s]*([0-9]+([.]{1}[0-9]+){0,1})$/,oE=/^dataMax[\s]*\+[\s]*([0-9]+([.]{1}[0-9]+){0,1})$/,Ky=function(t,r,n){if(fe(t))return t(r,n);if(!Array.isArray(t))return r;var i=[];if(Y(t[0]))i[0]=n?t[0]:Math.min(t[0],r[0]);else if(aE.test(t[0])){var a=+aE.exec(t[0])[1];i[0]=r[0]-a}else fe(t[0])?i[0]=t[0](r[0]):i[0]=r[0];if(Y(t[1]))i[1]=n?t[1]:Math.max(t[1],r[1]);else if(oE.test(t[1])){var o=+oE.exec(t[1])[1];i[1]=r[1]+o}else fe(t[1])?i[1]=t[1](r[1]):i[1]=r[1];return i},lh=function(t,r,n){if(t&&t.scale&&t.scale.bandwidth){var i=t.scale.bandwidth();if(!n||i>0)return i}if(t&&r&&r.length>=2){for(var a=xw(r,function(c){return c.coordinate}),o=1/0,s=1,l=a.length;s<l;s++){var u=a[s],d=a[s-1];o=Math.min((u.coordinate||0)-(d.coordinate||0),o)}return o===1/0?0:o}return n?void 0:0},sE=function(t,r,n){return!t||!t.length||Hw(t,kr(n,"type.defaultProps.domain"))?r:t},R$=function(t,r){var n=t.type.defaultProps?Je(Je({},t.type.defaultProps),t.props):t.props,i=n.dataKey,a=n.name,o=n.unit,s=n.formatter,l=n.tooltipType,u=n.chartType,d=n.hide;return Je(Je({},Se(t,!1)),{},{dataKey:i,unit:o,formatter:s,name:a||i,color:Gw(t),value:Tn(r,i),type:l,payload:r,chartType:u,hide:d})};function Gu(e){"@babel/helpers - typeof";return Gu=typeof Symbol=="function"&&typeof Symbol.iterator=="symbol"?function(t){return typeof t}:function(t){return t&&typeof Symbol=="function"&&t.constructor===Symbol&&t!==Symbol.prototype?"symbol":typeof t},Gu(e)}function lE(e,t){var r=Object.keys(e);if(Object.getOwnPropertySymbols){var n=Object.getOwnPropertySymbols(e);t&&(n=n.filter(function(i){return Object.getOwnPropertyDescriptor(e,i).enumerable})),r.push.apply(r,n)}return r}function uE(e){for(var t=1;t<arguments.length;t++){var r=arguments[t]!=null?arguments[t]:{};t%2?lE(Object(r),!0).forEach(function(n){gie(e,n,r[n])}):Object.getOwnPropertyDescriptors?Object.defineProperties(e,Object.getOwnPropertyDescriptors(r)):lE(Object(r)).forEach(function(n){Object.defineProperty(e,n,Object.getOwnPropertyDescriptor(r,n))})}return e}function gie(e,t,r){return t=yie(t),t in e?Object.defineProperty(e,t,{value:r,enumerable:!0,configurable:!0,writable:!0}):e[t]=r,e}function yie(e){var t=bie(e,"string");return Gu(t)=="symbol"?t:t+""}function bie(e,t){if(Gu(e)!="object"||!e)return e;var r=e[Symbol.toPrimitive];if(r!==void 0){var n=r.call(e,t||"default");if(Gu(n)!="object")return n;throw new TypeError("@@toPrimitive must return a primitive value.")}return(t==="string"?String:Number)(e)}var uh=Math.PI/180,wie=function(t){return t*180/Math.PI},Ot=function(t,r,n,i){return{x:t+Math.cos(-uh*i)*n,y:r+Math.sin(-uh*i)*n}},xie=function(t,r){var n=t.x,i=t.y,a=r.x,o=r.y;return Math.sqrt(Math.pow(n-a,2)+Math.pow(i-o,2))},_ie=function(t,r){var n=t.x,i=t.y,a=r.cx,o=r.cy,s=xie({x:n,y:i},{x:a,y:o});if(s<=0)return{radius:s};var l=(n-a)/s,u=Math.acos(l);return i>o&&(u=2*Math.PI-u),{radius:s,angle:wie(u),angleInRadian:u}},Sie=function(t){var r=t.startAngle,n=t.endAngle,i=Math.floor(r/360),a=Math.floor(n/360),o=Math.min(i,a);return{startAngle:r-o*360,endAngle:n-o*360}},Oie=function(t,r){var n=r.startAngle,i=r.endAngle,a=Math.floor(n/360),o=Math.floor(i/360),s=Math.min(a,o);return t+s*360},cE=function(t,r){var n=t.x,i=t.y,a=_ie({x:n,y:i},r),o=a.radius,s=a.angle,l=r.innerRadius,u=r.outerRadius;if(o<l||o>u)return!1;if(o===0)return!0;var d=Sie(r),c=d.startAngle,f=d.endAngle,h=s,v;if(c<=f){for(;h>f;)h-=360;for(;h<c;)h+=360;v=h>=c&&h<=f}else{for(;h>c;)h-=360;for(;h<f;)h+=360;v=h>=f&&h<=c}return v?uE(uE({},r),{},{radius:o,angle:Oie(h,r)}):null};function Yu(e){"@babel/helpers - typeof";return Yu=typeof Symbol=="function"&&typeof Symbol.iterator=="symbol"?function(t){return typeof t}:function(t){return t&&typeof Symbol=="function"&&t.constructor===Symbol&&t!==Symbol.prototype?"symbol":typeof t},Yu(e)}var Eie=["offset"];function kie(e){return Tie(e)||jie(e)||Aie(e)||Pie()}function Pie(){throw new TypeError(`Invalid attempt to spread non-iterable instance. 315In order to be iterable, non-array objects must have a [Symbol.iterator]() method.`)}function Aie(e,t){if(e){if(typeof e=="string")return Gy(e,t);var r=Object.prototype.toString.call(e).slice(8,-1);if(r==="Object"&&e.constructor&&(r=e.constructor.name),r==="Map"||r==="Set")return Array.from(e);if(r==="Arguments"||/^(?:Ui|I)nt(?:8|16|32)(?:Clamped)?Array$/.test(r))return Gy(e,t)}}function jie(e){if(typeof Symbol<"u"&&e[Symbol.iterator]!=null||e["@@iterator"]!=null)return Array.from(e)}function Tie(e){if(Array.isArray(e))return Gy(e)}function Gy(e,t){(t==null||t>e.length)&&(t=e.length);for(var r=0,n=new Array(t);r<t;r++)n[r]=e[r];return n}function Cie(e,t){if(e==null)return{};var r=Nie(e,t),n,i;if(Object.getOwnPropertySymbols){var a=Object.getOwnPropertySymbols(e);for(i=0;i<a.length;i++)n=a[i],!(t.indexOf(n)>=0)&&Object.prototype.propertyIsEnumerable.call(e,n)&&(r[n]=e[n])}return r}function Nie(e,t){if(e==null)return{};var r={};for(var n in e)if(Object.prototype.hasOwnProperty.call(e,n)){if(t.indexOf(n)>=0)continue;r[n]=e[n]}return r}function dE(e,t){var r=Object.keys(e);if(Object.getOwnPropertySymbols){var n=Object.getOwnPropertySymbols(e);t&&(n=n.filter(function(i){return Object.getOwnPropertyDescriptor(e,i).enumerable})),r.push.apply(r,n)}return r}function ot(e){for(var t=1;t<arguments.length;t++){var r=arguments[t]!=null?arguments[t]:{};t%2?dE(Object(r),!0).forEach(function(n){$ie(e,n,r[n])}):Object.getOwnPropertyDescriptors?Object.defineProperties(e,Object.getOwnPropertyDescriptors(r)):dE(Object(r)).forEach(function(n){Object.defineProperty(e,n,Object.getOwnPropertyDescriptor(r,n))})}return e}function $ie(e,t,r){return t=Rie(t),t in e?Object.defineProperty(e,t,{value:r,enumerable:!0,configurable:!0,writable:!0}):e[t]=r,e}function Rie(e){var t=Iie(e,"string");return Yu(t)=="symbol"?t:t+""}function Iie(e,t){if(Yu(e)!="object"||!e)return e;var r=e[Symbol.toPrimitive];if(r!==void 0){var n=r.call(e,t||"default");if(Yu(n)!="object")return n;throw new TypeError("@@toPrimitive must return a primitive value.")}return(t==="string"?String:Number)(e)}function Xu(){return Xu=Object.assign?Object.assign.bind():function(e){for(var t=1;t<arguments.length;t++){var r=arguments[t];for(var n in r)Object.prototype.hasOwnProperty.call(r,n)&&(e[n]=r[n])}return e},Xu.apply(this,arguments)}var Mie=function(t){var r=t.value,n=t.formatter,i=we(t.children)?r:t.children;return fe(n)?n(i):i},Die=function(t,r){var n=Xr(r-t),i=Math.min(Math.abs(r-t),360);return n*i},Lie=function(t,r,n){var i=t.position,a=t.viewBox,o=t.offset,s=t.className,l=a,u=l.cx,d=l.cy,c=l.innerRadius,f=l.outerRadius,h=l.startAngle,v=l.endAngle,m=l.clockWise,g=(c+f)/2,y=Die(h,v),b=y>=0?1:-1,w,_;i==="insideStart"?(w=h+b*o,_=m):i==="insideEnd"?(w=v-b*o,_=!m):i==="end"&&(w=v+b*o,_=m),_=y<=0?_:!_;var x=Ot(u,d,g,w),S=Ot(u,d,g,w+(_?1:-1)*359),E="M".concat(x.x,",").concat(x.y,` 316 A`).concat(g,",").concat(g,",0,1,").concat(_?0:1,`, 317 `).concat(S.x,",").concat(S.y),k=we(t.id)?Cp("recharts-radial-line-"):t.id;return j.createElement("text",Xu({},n,{dominantBaseline:"central",className:pe("recharts-radial-bar-label",s)}),j.createElement("defs",null,j.createElement("path",{id:k,d:E})),j.createElement("textPath",{xlinkHref:"#".concat(k)},r))},Bie=function(t){var r=t.viewBox,n=t.offset,i=t.position,a=r,o=a.cx,s=a.cy,l=a.innerRadius,u=a.outerRadius,d=a.startAngle,c=a.endAngle,f=(d+c)/2;if(i==="outside"){var h=Ot(o,s,u+n,f),v=h.x,m=h.y;return{x:v,y:m,textAnchor:v>=o?"start":"end",verticalAnchor:"middle"}}if(i==="center")return{x:o,y:s,textAnchor:"middle",verticalAnchor:"middle"};if(i==="centerTop")return{x:o,y:s,textAnchor:"middle",verticalAnchor:"start"};if(i==="centerBottom")return{x:o,y:s,textAnchor:"middle",verticalAnchor:"end"};var g=(l+u)/2,y=Ot(o,s,g,f),b=y.x,w=y.y;return{x:b,y:w,textAnchor:"middle",verticalAnchor:"middle"}},Uie=function(t){var r=t.viewBox,n=t.parentViewBox,i=t.offset,a=t.position,o=r,s=o.x,l=o.y,u=o.width,d=o.height,c=d>=0?1:-1,f=c*i,h=c>0?"end":"start",v=c>0?"start":"end",m=u>=0?1:-1,g=m*i,y=m>0?"end":"start",b=m>0?"start":"end";if(a==="top"){var w={x:s+u/2,y:l-c*i,textAnchor:"middle",verticalAnchor:h};return ot(ot({},w),n?{height:Math.max(l-n.y,0),width:u}:{})}if(a==="bottom"){var _={x:s+u/2,y:l+d+f,textAnchor:"middle",verticalAnchor:v};return ot(ot({},_),n?{height:Math.max(n.y+n.height-(l+d),0),width:u}:{})}if(a==="left"){var x={x:s-g,y:l+d/2,textAnchor:y,verticalAnchor:"middle"};return ot(ot({},x),n?{width:Math.max(x.x-n.x,0),height:d}:{})}if(a==="right"){var S={x:s+u+g,y:l+d/2,textAnchor:b,verticalAnchor:"middle"};return ot(ot({},S),n?{width:Math.max(n.x+n.width-S.x,0),height:d}:{})}var E=n?{width:u,height:d}:{};return a==="insideLeft"?ot({x:s+g,y:l+d/2,textAnchor:b,verticalAnchor:"middle"},E):a==="insideRight"?ot({x:s+u-g,y:l+d/2,textAnchor:y,verticalAnchor:"middle"},E):a==="insideTop"?ot({x:s+u/2,y:l+f,textAnchor:"middle",verticalAnchor:v},E):a==="insideBottom"?ot({x:s+u/2,y:l+d-f,textAnchor:"middle",verticalAnchor:h},E):a==="insideTopLeft"?ot({x:s+g,y:l+f,textAnchor:b,verticalAnchor:v},E):a==="insideTopRight"?ot({x:s+u-g,y:l+f,textAnchor:y,verticalAnchor:v},E):a==="insideBottomLeft"?ot({x:s+g,y:l+d-f,textAnchor:b,verticalAnchor:h},E):a==="insideBottomRight"?ot({x:s+u-g,y:l+d-f,textAnchor:y,verticalAnchor:h},E):el(a)&&(Y(a.x)||Sa(a.x))&&(Y(a.y)||Sa(a.y))?ot({x:s+Ga(a.x,u),y:l+Ga(a.y,d),textAnchor:"end",verticalAnchor:"end"},E):ot({x:s+u/2,y:l+d/2,textAnchor:"middle",verticalAnchor:"middle"},E)},Fie=function(t){return"cx"in t&&Y(t.cx)};function $t(e){var t=e.offset,r=t===void 0?5:t,n=Cie(e,Eie),i=ot({offset:r},n),a=i.viewBox,o=i.position,s=i.value,l=i.children,u=i.content,d=i.className,c=d===void 0?"":d,f=i.textBreakAll;if(!a||we(s)&&we(l)&&!O.isValidElement(u)&&!fe(u))return null;if(O.isValidElement(u))return O.cloneElement(u,i);var h;if(fe(u)){if(h=O.createElement(u,i),O.isValidElement(h))return h}else h=Mie(i);var v=Fie(a),m=Se(i,!0);if(v&&(o==="insideStart"||o==="insideEnd"||o==="end"))return Lie(i,h,m);var g=v?Bie(i):Uie(i);return j.createElement(Gf,Xu({className:pe("recharts-label",c)},m,g,{breakAll:f}),h)}$t.displayName="Label";var I$=function(t){var r=t.cx,n=t.cy,i=t.angle,a=t.startAngle,o=t.endAngle,s=t.r,l=t.radius,u=t.innerRadius,d=t.outerRadius,c=t.x,f=t.y,h=t.top,v=t.left,m=t.width,g=t.height,y=t.clockWise,b=t.labelViewBox;if(b)return b;if(Y(m)&&Y(g)){if(Y(c)&&Y(f))return{x:c,y:f,width:m,height:g};if(Y(h)&&Y(v))return{x:h,y:v,width:m,height:g}}return Y(c)&&Y(f)?{x:c,y:f,width:0,height:0}:Y(r)&&Y(n)?{cx:r,cy:n,startAngle:a||i||0,endAngle:o||i||0,innerRadius:u||0,outerRadius:d||l||s||0,clockWise:y}:t.viewBox?t.viewBox:{}},zie=function(t,r){return t?t===!0?j.createElement($t,{key:"label-implicit",viewBox:r}):ct(t)?j.createElement($t,{key:"label-implicit",viewBox:r,value:t}):O.isValidElement(t)?t.type===$t?O.cloneElement(t,{key:"label-implicit",viewBox:r}):j.createElement($t,{key:"label-implicit",content:t,viewBox:r}):fe(t)?j.createElement($t,{key:"label-implicit",content:t,viewBox:r}):el(t)?j.createElement($t,Xu({viewBox:r},t,{key:"label-implicit"})):null:null},Wie=function(t,r){var n=arguments.length>2&&arguments[2]!==void 0?arguments[2]:!0;if(!t||!t.children&&n&&!t.label)return null;var i=t.children,a=I$(t),o=tn(i,$t).map(function(l,u){return O.cloneElement(l,{viewBox:r||a,key:"label-".concat(u)})});if(!n)return o;var s=zie(t.label,r||a);return[s].concat(kie(o))};$t.parseViewBox=I$;$t.renderCallByParent=Wie;function qie(e){var t=e==null?0:e.length;return t?e[t-1]:void 0}var Hie=qie;const Vie=Ce(Hie);function Qu(e){"@babel/helpers - typeof";return Qu=typeof Symbol=="function"&&typeof Symbol.iterator=="symbol"?function(t){return typeof t}:function(t){return t&&typeof Symbol=="function"&&t.constructor===Symbol&&t!==Symbol.prototype?"symbol":typeof t},Qu(e)}var Kie=["valueAccessor"],Gie=["data","dataKey","clockWise","id","textBreakAll"];function Yie(e){return Zie(e)||Jie(e)||Qie(e)||Xie()}function Xie(){throw new TypeError(`Invalid attempt to spread non-iterable instance. 318In order to be iterable, non-array objects must have a [Symbol.iterator]() method.`)}function Qie(e,t){if(e){if(typeof e=="string")return Yy(e,t);var r=Object.prototype.toString.call(e).slice(8,-1);if(r==="Object"&&e.constructor&&(r=e.constructor.name),r==="Map"||r==="Set")return Array.from(e);if(r==="Arguments"||/^(?:Ui|I)nt(?:8|16|32)(?:Clamped)?Array$/.test(r))return Yy(e,t)}}function Jie(e){if(typeof Symbol<"u"&&e[Symbol.iterator]!=null||e["@@iterator"]!=null)return Array.from(e)}function Zie(e){if(Array.isArray(e))return Yy(e)}function Yy(e,t){(t==null||t>e.length)&&(t=e.length);for(var r=0,n=new Array(t);r<t;r++)n[r]=e[r];return n}function ch(){return ch=Object.assign?Object.assign.bind():function(e){for(var t=1;t<arguments.length;t++){var r=arguments[t];for(var n in r)Object.prototype.hasOwnProperty.call(r,n)&&(e[n]=r[n])}return e},ch.apply(this,arguments)}function fE(e,t){var r=Object.keys(e);if(Object.getOwnPropertySymbols){var n=Object.getOwnPropertySymbols(e);t&&(n=n.filter(function(i){return Object.getOwnPropertyDescriptor(e,i).enumerable})),r.push.apply(r,n)}return r}function hE(e){for(var t=1;t<arguments.length;t++){var r=arguments[t]!=null?arguments[t]:{};t%2?fE(Object(r),!0).forEach(function(n){eae(e,n,r[n])}):Object.getOwnPropertyDescriptors?Object.defineProperties(e,Object.getOwnPropertyDescriptors(r)):fE(Object(r)).forEach(function(n){Object.defineProperty(e,n,Object.getOwnPropertyDescriptor(r,n))})}return e}function eae(e,t,r){return t=tae(t),t in e?Object.defineProperty(e,t,{value:r,enumerable:!0,configurable:!0,writable:!0}):e[t]=r,e}function tae(e){var t=rae(e,"string");return Qu(t)=="symbol"?t:t+""}function rae(e,t){if(Qu(e)!="object"||!e)return e;var r=e[Symbol.toPrimitive];if(r!==void 0){var n=r.call(e,t||"default");if(Qu(n)!="object")return n;throw new TypeError("@@toPrimitive must return a primitive value.")}return(t==="string"?String:Number)(e)}function pE(e,t){if(e==null)return{};var r=nae(e,t),n,i;if(Object.getOwnPropertySymbols){var a=Object.getOwnPropertySymbols(e);for(i=0;i<a.length;i++)n=a[i],!(t.indexOf(n)>=0)&&Object.prototype.propertyIsEnumerable.call(e,n)&&(r[n]=e[n])}return r}function nae(e,t){if(e==null)return{};var r={};for(var n in e)if(Object.prototype.hasOwnProperty.call(e,n)){if(t.indexOf(n)>=0)continue;r[n]=e[n]}return r}var iae=function(t){return Array.isArray(t.value)?Vie(t.value):t.value};function Ua(e){var t=e.valueAccessor,r=t===void 0?iae:t,n=pE(e,Kie),i=n.data,a=n.dataKey,o=n.clockWise,s=n.id,l=n.textBreakAll,u=pE(n,Gie);return!i||!i.length?null:j.createElement(gt,{className:"recharts-label-list"},i.map(function(d,c){var f=we(a)?r(d,c):Tn(d&&d.payload,a),h=we(s)?{}:{id:"".concat(s,"-").concat(c)};return j.createElement($t,ch({},Se(d,!0),u,h,{parentViewBox:d.parentViewBox,value:f,textBreakAll:l,viewBox:$t.parseViewBox(we(o)?d:hE(hE({},d),{},{clockWise:o})),key:"label-".concat(c),index:c}))}))}Ua.displayName="LabelList";function aae(e,t){return e?e===!0?j.createElement(Ua,{key:"labelList-implicit",data:t}):j.isValidElement(e)||fe(e)?j.createElement(Ua,{key:"labelList-implicit",data:t,content:e}):el(e)?j.createElement(Ua,ch({data:t},e,{key:"labelList-implicit"})):null:null}function oae(e,t){var r=arguments.length>2&&arguments[2]!==void 0?arguments[2]:!0;if(!e||!e.children&&r&&!e.label)return null;var n=e.children,i=tn(n,Ua).map(function(o,s){return O.cloneElement(o,{data:t,key:"labelList-".concat(s)})});if(!r)return i;var a=aae(e.label,t);return[a].concat(Yie(i))}Ua.renderCallByParent=oae;function Ju(e){"@babel/helpers - typeof";return Ju=typeof Symbol=="function"&&typeof Symbol.iterator=="symbol"?function(t){return typeof t}:function(t){return t&&typeof Symbol=="function"&&t.constructor===Symbol&&t!==Symbol.prototype?"symbol":typeof t},Ju(e)}function Xy(){return Xy=Object.assign?Object.assign.bind():function(e){for(var t=1;t<arguments.length;t++){var r=arguments[t];for(var n in r)Object.prototype.hasOwnProperty.call(r,n)&&(e[n]=r[n])}return e},Xy.apply(this,arguments)}function mE(e,t){var r=Object.keys(e);if(Object.getOwnPropertySymbols){var n=Object.getOwnPropertySymbols(e);t&&(n=n.filter(function(i){return Object.getOwnPropertyDescriptor(e,i).enumerable})),r.push.apply(r,n)}return r}function vE(e){for(var t=1;t<arguments.length;t++){var r=arguments[t]!=null?arguments[t]:{};t%2?mE(Object(r),!0).forEach(function(n){sae(e,n,r[n])}):Object.getOwnPropertyDescriptors?Object.defineProperties(e,Object.getOwnPropertyDescriptors(r)):mE(Object(r)).forEach(function(n){Object.defineProperty(e,n,Object.getOwnPropertyDescriptor(r,n))})}return e}function sae(e,t,r){return t=lae(t),t in e?Object.defineProperty(e,t,{value:r,enumerable:!0,configurable:!0,writable:!0}):e[t]=r,e}function lae(e){var t=uae(e,"string");return Ju(t)=="symbol"?t:t+""}function uae(e,t){if(Ju(e)!="object"||!e)return e;var r=e[Symbol.toPrimitive];if(r!==void 0){var n=r.call(e,t||"default");if(Ju(n)!="object")return n;throw new TypeError("@@toPrimitive must return a primitive value.")}return(t==="string"?String:Number)(e)}var cae=function(t,r){var n=Xr(r-t),i=Math.min(Math.abs(r-t),359.999);return n*i},Sd=function(t){var r=t.cx,n=t.cy,i=t.radius,a=t.angle,o=t.sign,s=t.isExternal,l=t.cornerRadius,u=t.cornerIsExternal,d=l*(s?1:-1)+i,c=Math.asin(l/d)/uh,f=u?a:a+o*c,h=Ot(r,n,d,f),v=Ot(r,n,i,f),m=u?a-o*c:a,g=Ot(r,n,d*Math.cos(c*uh),m);return{center:h,circleTangency:v,lineTangency:g,theta:c}},M$=function(t){var r=t.cx,n=t.cy,i=t.innerRadius,a=t.outerRadius,o=t.startAngle,s=t.endAngle,l=cae(o,s),u=o+l,d=Ot(r,n,a,o),c=Ot(r,n,a,u),f="M ".concat(d.x,",").concat(d.y,` 319 A `).concat(a,",").concat(a,`,0, 320 `).concat(+(Math.abs(l)>180),",").concat(+(o>u),`, 321 `).concat(c.x,",").concat(c.y,` 322 `);if(i>0){var h=Ot(r,n,i,o),v=Ot(r,n,i,u);f+="L ".concat(v.x,",").concat(v.y,` 323 A `).concat(i,",").concat(i,`,0, 324 `).concat(+(Math.abs(l)>180),",").concat(+(o<=u),`, 325 `).concat(h.x,",").concat(h.y," Z")}else f+="L ".concat(r,",").concat(n," Z");return f},dae=function(t){var r=t.cx,n=t.cy,i=t.innerRadius,a=t.outerRadius,o=t.cornerRadius,s=t.forceCornerRadius,l=t.cornerIsExternal,u=t.startAngle,d=t.endAngle,c=Xr(d-u),f=Sd({cx:r,cy:n,radius:a,angle:u,sign:c,cornerRadius:o,cornerIsExternal:l}),h=f.circleTangency,v=f.lineTangency,m=f.theta,g=Sd({cx:r,cy:n,radius:a,angle:d,sign:-c,cornerRadius:o,cornerIsExternal:l}),y=g.circleTangency,b=g.lineTangency,w=g.theta,_=l?Math.abs(u-d):Math.abs(u-d)-m-w;if(_<0)return s?"M ".concat(v.x,",").concat(v.y,` 326 a`).concat(o,",").concat(o,",0,0,1,").concat(o*2,`,0 327 a`).concat(o,",").concat(o,",0,0,1,").concat(-o*2,`,0 328 `):M$({cx:r,cy:n,innerRadius:i,outerRadius:a,startAngle:u,endAngle:d});var x="M ".concat(v.x,",").concat(v.y,` 329 A`).concat(o,",").concat(o,",0,0,").concat(+(c<0),",").concat(h.x,",").concat(h.y,` 330 A`).concat(a,",").concat(a,",0,").concat(+(_>180),",").concat(+(c<0),",").concat(y.x,",").concat(y.y,` 331 A`).concat(o,",").concat(o,",0,0,").concat(+(c<0),",").concat(b.x,",").concat(b.y,` 332 `);if(i>0){var S=Sd({cx:r,cy:n,radius:i,angle:u,sign:c,isExternal:!0,cornerRadius:o,cornerIsExternal:l}),E=S.circleTangency,k=S.lineTangency,P=S.theta,C=Sd({cx:r,cy:n,radius:i,angle:d,sign:-c,isExternal:!0,cornerRadius:o,cornerIsExternal:l}),N=C.circleTangency,$=C.lineTangency,D=C.theta,I=l?Math.abs(u-d):Math.abs(u-d)-P-D;if(I<0&&o===0)return"".concat(x,"L").concat(r,",").concat(n,"Z");x+="L".concat($.x,",").concat($.y,` 333 A`).concat(o,",").concat(o,",0,0,").concat(+(c<0),",").concat(N.x,",").concat(N.y,` 334 A`).concat(i,",").concat(i,",0,").concat(+(I>180),",").concat(+(c>0),",").concat(E.x,",").concat(E.y,` 335 A`).concat(o,",").concat(o,",0,0,").concat(+(c<0),",").concat(k.x,",").concat(k.y,"Z")}else x+="L".concat(r,",").concat(n,"Z");return x},fae={cx:0,cy:0,innerRadius:0,outerRadius:0,startAngle:0,endAngle:0,cornerRadius:0,forceCornerRadius:!1,cornerIsExternal:!1},D$=function(t){var r=vE(vE({},fae),t),n=r.cx,i=r.cy,a=r.innerRadius,o=r.outerRadius,s=r.cornerRadius,l=r.forceCornerRadius,u=r.cornerIsExternal,d=r.startAngle,c=r.endAngle,f
335=r.className;if(o<a||d===c)return null;var h=pe("recharts-sector",f),v=o-a,m=Ga(s,v,0,!0),g;return m>0&&Math.abs(d-c)<360?g=dae({cx:n,cy:i,innerRadius:a,outerRadius:o,cornerRadius:Math.min(m,v/2),forceCornerRadius:l,cornerIsExternal:u,startAngle:d,endAngle:c}):g=M$({cx:n,cy:i,innerRadius:a,outerRadius:o,startAngle:d,endAngle:c}),j.createElement("path",Xy({},Se(r,!0),{className:h,d:g,role:"img"}))};function Zu(e){"@babel/helpers - typeof";return Zu=typeof Symbol=="function"&&typeof Symbol.iterator=="symbol"?function(t){return typeof t}:function(t){return t&&typeof Symbol=="function"&&t.constructor===Symbol&&t!==Symbol.prototype?"symbol":typeof t},Zu(e)}function Qy(){return Qy=Object.assign?Object.assign.bind():function(e){for(var t=1;t<arguments.length;t++){var r=arguments[t];for(var n in r)Object.prototype.hasOwnProperty.call(r,n)&&(e[n]=r[n])}return e},Qy.apply(this,arguments)}function gE(e,t){var r=Object.keys(e);if(Object.getOwnPropertySymbols){var n=Object.getOwnPropertySymbols(e);t&&(n=n.filter(function(i){return Object.getOwnPropertyDescriptor(e,i).enumerable})),r.push.apply(r,n)}return r}function yE(e){for(var t=1;t<arguments.length;t++){var r=arguments[t]!=null?arguments[t]:{};t%2?gE(Object(r),!0).forEach(function(n){hae(e,n,r[n])}):Object.getOwnPropertyDescriptors?Object.defineProperties(e,Object.getOwnPropertyDescriptors(r)):gE(Object(r)).forEach(function(n){Object.defineProperty(e,n,Object.getOwnPropertyDescriptor(r,n))})}return e}function hae(e,t,r){return t=pae(t),t in e?Object.defineProperty(e,t,{value:r,enumerable:!0,configurable:!0,writable:!0}):e[t]=r,e}function pae(e){var t=mae(e,"string");return Zu(t)=="symbol"?t:t+""}function mae(e,t){if(Zu(e)!="object"||!e)return e;var r=e[Symbol.toPrimitive];if(r!==void 0){var n=r.call(e,t||"default");if(Zu(n)!="object")return n;throw new TypeError("@@toPrimitive must return a primitive value.")}return(t==="string"?String:Number)(e)}var bE={curveBasisClosed:dV,curveBasisOpen:fV,curveBasis:cV,curveBumpX:XH,curveBumpY:QH,curveLinearClosed:hV,curveLinear:Rp,curveMonotoneX:pV,curveMonotoneY:mV,curveNatural:vV,curveStep:gV,curveStepAfter:bV,curveStepBefore:yV},Od=function(t){return t.x===+t.x&&t.y===+t.y},Al=function(t){return t.x},jl=function(t){return t.y},vae=function(t,r){if(fe(t))return t;var n="curve".concat(Np(t));return(n==="curveMonotone"||n==="curveBump")&&r?bE["".concat(n).concat(r==="vertical"?"Y":"X")]:bE[n]||Rp},gae=function(t){var r=t.type,n=r===void 0?"linear":r,i=t.points,a=i===void 0?[]:i,o=t.baseLine,s=t.layout,l=t.connectNulls,u=l===void 0?!1:l,d=vae(n,s),c=u?a.filter(function(m){return Od(m)}):a,f;if(Array.isArray(o)){var h=u?o.filter(function(m){return Od(m)}):o,v=c.map(function(m,g){return yE(yE({},m),{},{base:h[g]})});return s==="vertical"?f=pd().y(jl).x1(Al).x0(function(m){return m.base.x}):f=pd().x(Al).y1(jl).y0(function(m){return m.base.y}),f.defined(Od).curve(d),f(v)}return s==="vertical"&&Y(o)?f=pd().y(jl).x1(Al).x0(o):Y(o)?f=pd().x(Al).y1(jl).y0(o):f=UC().x(Al).y(jl),f.defined(Od).curve(d),f(c)},wE=function(t){var r=t.className,n=t.points,i=t.path,a=t.pathRef;if((!n||!n.length)&&!i)return null;var o=n&&n.length?gae(t):i;return O.createElement("path",Qy({},Se(t,!1),Nf(t),{className:pe("recharts-curve",r),d:o,ref:a}))},L$={exports:{}},yae="SECRET_DO_NOT_PASS_THIS_OR_YOU_WILL_BE_FIRED",bae=yae,wae=bae;function B$(){}function U$(){}U$.resetWarningCache=B$;var xae=function(){function e(n,i,a,o,s,l){if(l!==wae){var u=new Error("Calling PropTypes validators directly is not supported by the `prop-types` package. Use PropTypes.checkPropTypes() to call them. Read more at http://fb.me/use-check-prop-types");throw u.name="Invariant Violation",u}}e.isRequired=e;function t(){return e}var r={array:e,bigint:e,bool:e,func:e,number:e,object:e,string:e,symbol:e,any:e,arrayOf:t,element:e,elementType:e,instanceOf:t,node:e,objectOf:t,oneOf:t,oneOfType:t,shape:t,exact:t,checkPropTypes:U$,resetWarningCache:B$};return r.PropTypes=r,r};L$.exports=xae();var _ae=L$.exports;const _e=Ce(_ae);var Sae=Object.getOwnPropertyNames,Oae=Object.getOwnPropertySymbols,Eae=Object.prototype.hasOwnProperty;function xE(e,t){return function(n,i,a){return e(n,i,a)&&t(n,i,a)}}function Ed(e){return function(r,n,i){if(!r||!n||typeof r!="object"||typeof n!="object")return e(r,n,i);var a=i.cache,o=a.get(r),s=a.get(n);if(o&&s)return o===n&&s===r;a.set(r,n),a.set(n,r);var l=e(r,n,i);return a.delete(r),a.delete(n),l}}function _E(e){return Sae(e).concat(Oae(e))}var kae=Object.hasOwn||function(e,t){return Eae.call(e,t)};function ao(e,t){return e===t||!e&&!t&&e!==e&&t!==t}var Pae="__v",Aae="__o",jae="_owner",SE=Object.getOwnPropertyDescriptor,OE=Object.keys;function Tae(e,t,r){var n=e.length;if(t.length!==n)return!1;for(;n-- >0;)if(!r.equals(e[n],t[n],n,n,e,t,r))return!1;return!0}function Cae(e,t){return ao(e.getTime(),t.getTime())}function Nae(e,t){return e.name===t.name&&e.message===t.message&&e.cause===t.cause&&e.stack===t.stack}function $ae(e,t){return e===t}function EE(e,t,r){var n=e.size;if(n!==t.size)return!1;if(!n)return!0;for(var i=new Array(n),a=e.entries(),o,s,l=0;(o=a.next())&&!o.done;){for(var u=t.entries(),d=!1,c=0;(s=u.next())&&!s.done;){if(i[c]){c++;continue}var f=o.value,h=s.value;if(r.equals(f[0],h[0],l,c,e,t,r)&&r.equals(f[1],h[1],f[0],h[0],e,t,r)){d=i[c]=!0;break}c++}if(!d)return!1;l++}return!0}var Rae=ao;function Iae(e,t,r){var n=OE(e),i=n.length;if(OE(t).length!==i)return!1;for(;i-- >0;)if(!F$(e,t,r,n[i]))return!1;return!0}function Tl(e,t,r){var n=_E(e),i=n.length;if(_E(t).length!==i)return!1;for(var a,o,s;i-- >0;)if(a=n[i],!F$(e,t,r,a)||(o=SE(e,a),s=SE(t,a),(o||s)&&(!o||!s||o.configurable!==s.configurable||o.enumerable!==s.enumerable||o.writable!==s.writable)))return!1;return!0}function Mae(e,t){return ao(e.valueOf(),t.valueOf())}function Dae(e,t){return e.source===t.source&&e.flags===t.flags}function kE(e,t,r){var n=e.size;if(n!==t.size)return!1;if(!n)return!0;for(var i=new Array(n),a=e.values(),o,s;(o=a.next())&&!o.done;){for(var l=t.values(),u=!1,d=0;(s=l.next())&&!s.done;){if(!i[d]&&r.equals(o.value,s.value,o.value,s.value,e,t,r)){u=i[d]=!0;break}d++}if(!u)return!1}return!0}function Lae(e,t){var r=e.length;if(t.length!==r)return!1;for(;r-- >0;)if(e[r]!==t[r])return!1;return!0}function Bae(e,t){return e.hostname===t.hostname&&e.pathname===t.pathname&&e.protocol===t.protocol&&e.port===t.port&&e.hash===t.hash&&e.username===t.username&&e.password===t.password}function F$(e,t,r,n){return(n===jae||n===Aae||n===Pae)&&(e.$$typeof||t.$$typeof)?!0:kae(t,n)&&r.equals(e[n],t[n],n,n,e,t,r)}var Uae="[object Arguments]",Fae="[object Boolean]",zae="[object Date]",Wae="[object Error]",qae="[object Map]",Hae="[object Number]",Vae="[object Object]",Kae="[object RegExp]",Gae="[object Set]",Yae="[object String]",Xae="[object URL]",Qae=Array.isArray,PE=typeof ArrayBuffer=="function"&&ArrayBuffer.isView?ArrayBuffer.isView:null,AE=Object.assign,Jae=Object.prototype.toString.call.bind(Object.prototype.toString);function Zae(e){var t=e.areArraysEqual,r=e.areDatesEqual,n=e.areErrorsEqual,i=e.areFunctionsEqual,a=e.areMapsEqual,o=e.areNumbersEqual,s=e.areObjectsEqual,l=e.arePrimitiveWrappersEqual,u=e.areRegExpsEqual,d=e.areSetsEqual,c=e.areTypedArraysEqual,f=e.areUrlsEqual;return function(v,m,g){if(v===m)return!0;
335if(v==null||m==null)return!1;var y=typeof v;if(y!==typeof m)return!1;if(y!=="object")return y==="number"?o(v,m,g):y==="function"?i(v,m,g):!1;var b=v.constructor;if(b!==m.constructor)return!1;if(b===Object)return s(v,m,g);if(Qae(v))return t(v,m,g);if(PE!=null&&PE(v))return c(v,m,g);if(b===Date)return r(v,m,g);if(b===RegExp)return u(v,m,g);if(b===Map)return a(v,m,g);if(b===Set)return d(v,m,g);var w=Jae(v);return w===zae?r(v,m,g):w===Kae?u(v,m,g):w===qae?a(v,m,g):w===Gae?d(v,m,g):w===Vae?typeof v.then!="function"&&typeof m.then!="function"&&s(v,m,g):w===Xae?f(v,m,g):w===Wae?n(v,m,g):w===Uae?s(v,m,g):w===Fae||w===Hae||w===Yae?l(v,m,g):!1}}function eoe(e){var t=e.circular,r=e.createCustomConfig,n=e.strict,i={areArraysEqual:n?Tl:Tae,areDatesEqual:Cae,areErrorsEqual:Nae,areFunctionsEqual:$ae,areMapsEqual:n?xE(EE,Tl):EE,areNumbersEqual:Rae,areObjectsEqual:n?Tl:Iae,arePrimitiveWrappersEqual:Mae,areRegExpsEqual:Dae,areSetsEqual:n?xE(kE,Tl):kE,areTypedArraysEqual:n?Tl:Lae,areUrlsEqual:Bae};if(r&&(i=AE({},i,r(i))),t){var a=Ed(i.areArraysEqual),o=Ed(i.areMapsEqual),s=Ed(i.areObjectsEqual),l=Ed(i.areSetsEqual);i=AE({},i,{areArraysEqual:a,areMapsEqual:o,areObjectsEqual:s,areSetsEqual:l})}return i}function toe(e){return function(t,r,n,i,a,o,s){return e(t,r,s)}}function roe(e){var t=e.circular,r=e.comparator,n=e.createState,i=e.equals,a=e.strict;if(n)return function(l,u){var d=n(),c=d.cache,f=c===void 0?t?new WeakMap:void 0:c,h=d.meta;return r(l,u,{cache:f,equals:i,meta:h,strict:a})};if(t)return function(l,u){return r(l,u,{cache:new WeakMap,equals:i,meta:void 0,strict:a})};var o={cache:void 0,equals:i,meta:void 0,strict:a};return function(l,u){return r(l,u,o)}}var noe=ia();ia({strict:!0});ia({circular:!0});ia({circular:!0,strict:!0});ia({createInternalComparator:function(){return ao}});ia({strict:!0,createInternalComparator:function(){return ao}});ia({circular:!0,createInternalComparator:function(){return ao}});ia({circular:!0,createInternalComparator:function(){return ao},strict:!0});function ia(e){e===void 0&&(e={});var t=e.circular,r=t===void 0?!1:t,n=e.createInternalComparator,i=e.createState,a=e.strict,o=a===void 0?!1:a,s=eoe(e),l=Zae(s),u=n?n(l):toe(l);return roe({circular:r,comparator:l,createState:i,equals:u,strict:o})}function ioe(e){typeof requestAnimationFrame<"u"&&requestAnimationFrame(e)}function jE(e){var t=arguments.length>1&&arguments[1]!==void 0?arguments[1]:0,r=-1,n=function i(a){r<0&&(r=a),a-r>t?(e(a),r=-1):ioe(i)};requestAnimationFrame(n)}function Jy(e){"@babel/helpers - typeof";return Jy=typeof Symbol=="function"&&typeof Symbol.iterator=="symbol"?function(t){return typeof t}:function(t){return t&&typeof Symbol=="function"&&t.constructor===Symbol&&t!==Symbol.prototype?"symbol":typeof t},Jy(e)}function aoe(e){return uoe(e)||loe(e)||soe(e)||ooe()}function ooe(){throw new TypeError(`Invalid attempt to destructure non-iterable instance. 336In order to be iterable, non-array objects must have a [Symbol.iterator]() method.`)}function soe(e,t){if(e){if(typeof e=="string")return TE(e,t);var r=Object.prototype.toString.call(e).slice(8,-1);if(r==="Object"&&e.constructor&&(r=e.constructor.name),r==="Map"||r==="Set")return Array.from(e);if(r==="Arguments"||/^(?:Ui|I)nt(?:8|16|32)(?:Clamped)?Array$/.test(r))return TE(e,t)}}function TE(e,t){(t==null||t>e.length)&&(t=e.length);for(var r=0,n=new Array(t);r<t;r++)n[r]=e[r];return n}function loe(e){if(typeof Symbol<"u"&&e[Symbol.iterator]!=null||e["@@iterator"]!=null)return Array.from(e)}function uoe(e){if(Array.isArray(e))return e}function coe(){var e={},t=function(){return null},r=!1,n=function i(a){if(!r){if(Array.isArray(a)){if(!a.length)return;var o=a,s=aoe(o),l=s[0],u=s.slice(1);if(typeof l=="number"){jE(i.bind(null,u),l);return}i(l),jE(i.bind(null,u));return}Jy(a)==="object"&&(e=a,t(e)),typeof a=="function"&&a()}};return{stop:function(){r=!0},start:function(a){r=!1,n(a)},subscribe:function(a){return t=a,function(){t=function(){return null}}}}}function ec(e){"@babel/helpers - typeof";return ec=typeof Symbol=="function"&&typeof Symbol.iterator=="symbol"?function(t){return typeof t}:function(t){return t&&typeof Symbol=="function"&&t.constructor===Symbol&&t!==Symbol.prototype?"symbol":typeof t},ec(e)}function CE(e,t){var r=Object.keys(e);if(Object.getOwnPropertySymbols){var n=Object.getOwnPropertySymbols(e);t&&(n=n.filter(function(i){return Object.getOwnPropertyDescriptor(e,i).enumerable})),r.push.apply(r,n)}return r}function NE(e){for(var t=1;t<arguments.length;t++){var r=arguments[t]!=null?arguments[t]:{};
vendor: 142,507 bytes, lines 336-357
336t%2?CE(Object(r),!0).forEach(function(n){z$(e,n,r[n])}):Object.getOwnPropertyDescriptors?Object.defineProperties(e,Object.getOwnPropertyDescriptors(r)):CE(Object(r)).forEach(function(n){Object.defineProperty(e,n,Object.getOwnPropertyDescriptor(r,n))})}return e}function z$(e,t,r){return t=doe(t),t in e?Object.defineProperty(e,t,{value:r,enumerable:!0,configurable:!0,writable:!0}):e[t]=r,e}function doe(e){var t=foe(e,"string");return ec(t)==="symbol"?t:String(t)}function foe(e,t){if(ec(e)!=="object"||e===null)return e;var r=e[Symbol.toPrimitive];if(r!==void 0){var n=r.call(e,t||"default");if(ec(n)!=="object")return n;throw new TypeError("@@toPrimitive must return a primitive value.")}return(t==="string"?String:Number)(e)}var hoe=function(t,r){return[Object.keys(t),Object.keys(r)].reduce(function(n,i){return n.filter(function(a){return i.includes(a)})})},poe=function(t){return t},moe=function(t){return t.replace(/([A-Z])/g,function(r){return"-".concat(r.toLowerCase())})},Zl=function(t,r){return Object.keys(r).reduce(function(n,i){return NE(NE({},n),{},z$({},i,t(i,r[i])))},{})},$E=function(t,r,n){return t.map(function(i){return"".concat(moe(i)," ").concat(r,"ms ").concat(n)}).join(",")};function voe(e,t){return boe(e)||yoe(e,t)||W$(e,t)||goe()}function goe(){throw new TypeError(`Invalid attempt to destructure non-iterable instance. 337In order to be iterable, non-array objects must have a [Symbol.iterator]() method.`)}function yoe(e,t){var r=e==null?null:typeof Symbol<"u"&&e[Symbol.iterator]||e["@@iterator"];if(r!=null){var n,i,a,o,s=[],l=!0,u=!1;try{if(a=(r=r.call(e)).next,t!==0)for(;!(l=(n=a.call(r)).done)&&(s.push(n.value),s.length!==t);l=!0);}catch(d){u=!0,i=d}finally{try{if(!l&&r.return!=null&&(o=r.return(),Object(o)!==o))return}finally{if(u)throw i}}return s}}function boe(e){if(Array.isArray(e))return e}function woe(e){return Soe(e)||_oe(e)||W$(e)||xoe()}function xoe(){throw new TypeError(`Invalid attempt to spread non-iterable instance. 338In order to be iterable, non-array objects must have a [Symbol.iterator]() method.`)}function W$(e,t){if(e){if(typeof e=="string")return Zy(e,t);var r=Object.prototype.toString.call(e).slice(8,-1);if(r==="Object"&&e.constructor&&(r=e.constructor.name),r==="Map"||r==="Set")return Array.from(e);if(r==="Arguments"||/^(?:Ui|I)nt(?:8|16|32)(?:Clamped)?Array$/.test(r))return Zy(e,t)}}function _oe(e){if(typeof Symbol<"u"&&e[Symbol.iterator]!=null||e["@@iterator"]!=null)return Array.from(e)}function Soe(e){if(Array.isArray(e))return Zy(e)}function Zy(e,t){(t==null||t>e.length)&&(t=e.length);for(var r=0,n=new Array(t);r<t;r++)n[r]=e[r];return n}var dh=1e-4,q$=function(t,r){return[0,3*t,3*r-6*t,3*t-3*r+1]},H$=function(t,r){return t.map(function(n,i){return n*Math.pow(r,i)}).reduce(function(n,i){return n+i})},RE=function(t,r){return function(n){var i=q$(t,r);return H$(i,n)}},Ooe=function(t,r){return function(n){var i=q$(t,r),a=[].concat(woe(i.map(function(o,s){return o*s}).slice(1)),[0]);return H$(a,n)}},IE=function(){for(var t=arguments.length,r=new Array(t),n=0;n<t;n++)r[n]=arguments[n];var i=r[0],a=r[1],o=r[2],s=r[3];if(r.length===1)switch(r[0]){case"linear":i=0,a=0,o=1,s=1;break;case"ease":i=.25,a=.1,o=.25,s=1;break;case"ease-in":i=.42,a=0,o=1,s=1;break;case"ease-out":i=.42,a=0,o=.58,s=1;break;case"ease-in-out":i=0,a=0,o=.58,s=1;break;default:{var l=r[0].split("(");if(l[0]==="cubic-bezier"&&l[1].split(")")[0].split(",").length===4){var u=l[1].split(")")[0].split(",").map(function(g){return parseFloat(g)}),d=voe(u,4);i=d[0],a=d[1],o=d[2],s=d[3]}}}var c=RE(i,o),f=RE(a,s),h=Ooe(i,o),v=function(y){return y>1?1:y<0?0:y},m=function(y){for(var b=y>1?1:y,w=b,_=0;_<8;++_){var x=c(w)-b,S=h(w);if(Math.abs(x-b)<dh||S<dh)return f(w);w=v(w-x/S)}return f(w)};return m.isStepper=!1,m},Eoe=function(){var t=arguments.length>0&&arguments[0]!==void 0?arguments[0]:{},r=t.stiff,n=r===void 0?100:r,i=t.damping,a=i===void 0?8:i,o=t.dt,s=o===void 0?17:o,l=function(d,c,f){var h=-(d-c)*n,v=f*a,m=f+(h-v)*s/1e3,g=f*s/1e3+d;return Math.abs(g-c)<dh&&Math.abs(m)<dh?[c,0]:[g,m]};return l.isStepper=!0,l.dt=s,l},koe=function(){for(var t=arguments.length,r=new Array(t),n=0;n<t;n++)r[n]=arguments[n];var i=r[0];if(typeof i=="string")switch(i){case"ease":case"ease-in-out":case"ease-out":case"ease-in":case"linear":return IE(i);case"spring":return Eoe();default:if(i.split("(")[0]==="cubic-bezier")return IE(i)}return typeof i=="function"?i:null};function tc(e){"@babel/helpers - typeof";return tc=typeof Symbol=="function"&&typeof Symbol.iterator=="symbol"?function(t){return typeof t}:function(t){return t&&typeof Symbol=="function"&&t.constructor===Symbol&&t!==Symbol.prototype?"symbol":typeof t},tc(e)}function ME(e){return joe(e)||Aoe(e)||V$(e)||Poe()}function Poe(){throw new TypeError(`Invalid attempt to spread non-iterable instance. 339In order to be iterable, non-array objects must have a [Symbol.iterator]() method.`)}function Aoe(e){if(typeof Symbol<"u"&&e[Symbol.iterator]!=null||e["@@iterator"]!=null)return Array.from(e)}function joe(e){if(Array.isArray(e))return t0(e)}function DE(e,t){var r=Object.keys(e);if(Object.getOwnPropertySymbols){var n=Object.getOwnPropertySymbols(e);t&&(n=n.filter(function(i){return Object.getOwnPropertyDescriptor(e,i).enumerable})),r.push.apply(r,n)}return r}function _t(e){for(var t=1;t<arguments.length;t++){var r=arguments[t]!=null?arguments[t]:{};t%2?DE(Object(r),!0).forEach(function(n){e0(e,n,r[n])}):Object.getOwnPropertyDescriptors?Object.defineProperties(e,Object.getOwnPropertyDescriptors(r)):DE(Object(r)).forEach(function(n){Object.defineProperty(e,n,Object.getOwnPropertyDescriptor(r,n))})}return e}function e0(e,t,r){return t=Toe(t),t in e?Object.defineProperty(e,t,{value:r,enumerable:!0,configurable:!0,writable:!0}):e[t]=r,e}function Toe(e){var t=Coe(e,"string");return tc(t)==="symbol"?t:String(t)}function Coe(e,t){if(tc(e)!=="object"||e===null)return e;var r=e[Symbol.toPrimitive];if(r!==void 0){var n=r.call(e,t||"default");if(tc(n)!=="object")return n;throw new TypeError("@@toPrimitive must return a primitive value.")}return(t==="string"?String:Number)(e)}function Noe(e,t){return Ioe(e)||Roe(e,t)||V$(e,t)||$oe()}function $oe(){throw new TypeError(`Invalid attempt to destructure non-iterable instance. 340In order to be iterable, non-array objects must have a [Symbol.iterator]() method.`)}function V$(e,t){if(e){if(typeof e=="string")return t0(e,t);var r=Object.prototype.toString.call(e).slice(8,-1);if(r==="Object"&&e.constructor&&(r=e.constructor.name),r==="Map"||r==="Set")return Array.from(e);if(r==="Arguments"||/^(?:Ui|I)nt(?:8|16|32)(?:Clamped)?Array$/.test(r))return t0(e,t)}}function t0(e,t){(t==null||t>e.length)&&(t=e.length);for(var r=0,n=new Array(t);r<t;r++)n[r]=e[r];return n}function Roe(e,t){var r=e==null?null:typeof Symbol<"u"&&e[Symbol.iterator]||e["@@iterator"];if(r!=null){var n,i,a,o,s=[],l=!0,u=!1;try{if(a=(r=r.call(e)).next,t!==0)for(;!(l=(n=a.call(r)).done)&&(s.push(n.value),s.length!==t);l=!0);}catch(d){u=!0,i=d}finally{try{if(!l&&r.return!=null&&(o=r.return(),Object(o)!==o))return}finally{if(u)throw i}}return s}}function Ioe(e){if(Array.isArray(e))return e}var fh=function(t,r,n){return t+(r-t)*n},r0=function(t){var r=t.from,n=t.to;return r!==n},Moe=function e(t,r,n){var i=Zl(function(a,o){if(r0(o)){var s=t(o.from,o.to,o.velocity),l=Noe(s,2),u=l[0],d=l[1];return _t(_t({},o),{},{from:u,velocity:d})}return o},r);return n<1?Zl(function(a,o){return r0(o)?_t(_t({},o),{},{velocity:fh(o.velocity,i[a].velocity,n),from:fh(o.from,i[a].from,n)}):o},r):e(t,i,n-1)};const Doe=function(e,t,r,n,i){var a=hoe(e,t),o=a.reduce(function(g,y){return _t(_t({},g),{},e0({},y,[e[y],t[y]]))},{}),s=a.reduce(function(g,y){return _t(_t({},g),{},e0({},y,{from:e[y],velocity:0,to:t[y]}))},{}),l=-1,u,d,c=function(){return null},f=function(){return Zl(function(y,b){return b.from},s)},h=function(){return!Object.values(s).filter(r0).length},v=function(y){u||(u=y);var b=y-u,w=b/r.dt;s=Moe(r,s,w),i(_t(_t(_t({},e),t),f())),u=y,h()||(l=requestAnimationFrame(c))},m=function(y){d||(d=y);var b=(y-d)/n,w=Zl(function(x,S){return fh.apply(void 0,ME(S).concat([r(b)]))},o);if(i(_t(_t(_t({},e),t),w)),b<1)l=requestAnimationFrame(c);else{var _=Zl(function(x,S){return fh.apply(void 0,ME(S).concat([r(1)]))},o);i(_t(_t(_t({},e),t),_))}};return c=r.isStepper?v:m,function(){return requestAnimationFrame(c),function(){cancelAnimationFrame(l)}}};function Ts(e){"@babel/helpers - typeof";return Ts=typeof Symbol=="function"&&typeof Symbol.iterator=="symbol"?function(t){return typeof t}:function(t){return t&&typeof Symbol=="function"&&t.constructor===Symbol&&t!==Symbol.prototype?"symbol":typeof t},Ts(e)}var Loe=["children","begin","duration","attributeName","easing","isActive","steps","from","to","canBegin","onAnimationEnd","shouldReAnimate","onAnimationReStart"];function Boe(e,t){if(e==null)return{};var r=Uoe(e,t),n,i;if(Object.getOwnPropertySymbols){var a=Object.getOwnPropertySymbols(e);for(i=0;i<a.length;i++)n=a[i],!(t.indexOf(n)>=0)&&Object.prototype.propertyIsEnumerable.call(e,n)&&(r[n]=e[n])}return r}function Uoe(e,t){if(e==null)return{};var r={},n=Object.keys(e),i,a;for(a=0;a<n.length;a++)i=n[a],!(t.indexOf(i)>=0)&&(r[i]=e[i]);return r}function Ov(e){return qoe(e)||Woe(e)||zoe(e)||Foe()}function Foe(){throw new TypeError(`Invalid attempt to spread non-iterable instance. 341In order to be iterable, non-array objects must have a [Symbol.iterator]() method.`)}function zoe(e,t){if(e){if(typeof e=="string")return n0(e,t);var r=Object.prototype.toString.call(e).slice(8,-1);if(r==="Object"&&e.constructor&&(r=e.constructor.name),r==="Map"||r==="Set")return Array.from(e);if(r==="Arguments"||/^(?:Ui|I)nt(?:8|16|32)(?:Clamped)?Array$/.test(r))return n0(e,t)}}function Woe(e){if(typeof Symbol<"u"&&e[Symbol.iterator]!=null||e["@@iterator"]!=null)return Array.from(e)}function qoe(e){if(Array.isArray(e))return n0(e)}function n0(e,t){(t==null||t>e.length)&&(t=e.length);for(var r=0,n=new Array(t);r<t;r++)n[r]=e[r];return n}function LE(e,t){var r=Object.keys(e);if(Object.getOwnPropertySymbols){var n=Object.getOwnPropertySymbols(e);t&&(n=n.filter(function(i){return Object.getOwnPropertyDescriptor(e,i).enumerable})),r.push.apply(r,n)}return r}function Lr(e){for(var t=1;t<arguments.length;t++){var r=arguments[t]!=null?arguments[t]:{};t%2?LE(Object(r),!0).forEach(function(n){Dl(e,n,r[n])}):Object.getOwnPropertyDescriptors?Object.defineProperties(e,Object.getOwnPropertyDescriptors(r)):LE(Object(r)).forEach(function(n){Object.defineProperty(e,n,Object.getOwnPropertyDescriptor(r,n))})}return e}function Dl(e,t,r){return t=K$(t),t in e?Object.defineProperty(e,t,{value:r,enumerable:!0,configurable:!0,writable:!0}):e[t]=r,e}function Hoe(e,t){if(!(e instanceof t))throw new TypeError("Cannot call a class as a function")}function Voe(e,t){for(var r=0;r<t.length;r++){var n=t[r];n.enumerable=n.enumerable||!1,n.configurable=!0,"value"in n&&(n.writable=!0),Object.defineProperty(e,K$(n.key),n)}}function Koe(e,t,r){return t&&Voe(e.prototype,t),Object.defineProperty(e,"prototype",{writable:!1}),e}function K$(e){var t=Goe(e,"string");return Ts(t)==="symbol"?t:String(t)}function Goe(e,t){if(Ts(e)!=="object"||e===null)return e;var r=e[Symbol.toPrimitive];if(r!==void 0){var n=r.call(e,t||"default");if(Ts(n)!=="object")return n;throw new TypeError("@@toPrimitive must return a primitive value.")}return(t==="string"?String:Number)(e)}function Yoe(e,t){if(typeof t!="function"&&t!==null)throw new TypeError("Super expression must either be null or a function");e.prototype=Object.create(t&&t.prototype,{constructor:{value:e,writable:!0,configurable:!0}}),Object.defineProperty(e,"prototype",{writable:!1}),t&&i0(e,t)}function i0(e,t){return i0=Object.setPrototypeOf?Object.setPrototypeOf.bind():function(n,i){return n.__proto__=i,n},i0(e,t)}function Xoe(e){var t=Qoe();return function(){var n=hh(e),i;if(t){var a=hh(this).constructor;i=Reflect.construct(n,arguments,a)}else i=n.apply(this,arguments);return a0(this,i)}}function a0(e,t){if(t&&(Ts(t)==="object"||typeof t=="function"))return t;if(t!==void 0)throw new TypeError("Derived constructors may only return object or undefined");return o0(e)}function o0(e){if(e===void 0)throw new ReferenceError("this hasn't been initialised - super() hasn't been called");return e}function Qoe(){if(typeof Reflect>"u"||!Reflect.construct||Reflect.construct.sham)return!1;if(typeof Proxy=="function")return!0;try{return Boolean.prototype.valueOf.call(Reflect.construct(Boolean,[],function(){})),!0}catch{return!1}}function hh(e){return hh=Object.setPrototypeOf?Object.getPrototypeOf.bind():function(r){return r.__proto__||Object.getPrototypeOf(r)},hh(e)}var Gi=function(e){Yoe(r,e);var t=Xoe(r);function r(n,i){var a;Hoe(this,r),a=t.call(this,n,i);var o=a.props,s=o.isActive,l=o.attributeName,u=o.from,d=o.to,c=o.steps,f=o.children,h=o.duration;if(a.handleStyleChange=a.handleStyleChange.bind(o0(a)),a.changeStyle=a.changeStyle.bind(o0(a)),!s||h<=0)return a.state={style:{}},typeof f=="function"&&(a.state={style:d}),a0(a);if(c&&c.length)a.state={style:c[0].style};else if(u){if(typeof f=="function")return a.state={style:u},a0(a);a.state={style:l?Dl({},l,u):u}}else a.state={style:{}};return a}return Koe(r,[{key:"componentDidMount",value:function(){var i=this.props,a=i.isActive,o=i.canBegin;this.mounted=!0,!(!a||!o)&&this.runAnimation(this.props)}},{key:"componentDidUpdate",value:function(i){var a=this.props,o=a.isActive,s=a.canBegin,l=a.attributeName,u=a.shouldReAnimate,d=a.to,c=a.from,f=this.state.style;if(s){if(!o){var h={style:l?Dl({},l,d):d};this.state&&f&&(l&&f[l]!==d||!l&&f!==d)&&this.setState(h);return}if(!(noe(i.to,d)&&i.canBegin&&i.isActive)){var v=!i.canBegin||!i.isActive;this.manager&&this.manager.stop(),this.stopJSAnimation&&this.stopJSAnimation();var m=v||u?c:i.to;if(this.state&&f){var g={style:l?Dl({},l,m):m};(l&&f[l]!==m||!l&&f!==m)&&this.setState(g)}this.runAnimation(Lr(Lr({},this.props),{},{from:m,begin:0}))}}}},{key:"componentWillUnmount",value:function(){this.mounted=!1;var i=this.props.onAnimationEnd;this.unSubscribe&&this.unSubscribe(),this.manager&&(this.manager.stop(),this.manager=null),this.stopJSAnimation&&this.stopJSAnimation(),i&&i()}},{key:"handleStyleChange",value:function(i){this.changeStyle(i)}},{key:"changeStyle",value:function(i){this.mounted&&this.setState({style:i})}},{key:"runJSAnimation",value:function(i){var a=this,o=i.from,s=i.to,l=i.duration,u=i.easing,d=i.begin,c=i.onAnimationEnd,f=i.onAnimationStart,h=Doe(o,s,koe(u),l,this.changeStyle),v=function(){a.stopJSAnimation=h()};this.manager.start([f,d,v,l,c])}},{key:"runStepAnimation",value:function(i){var a=this,o=i.steps,s=i.begin,l=i.onAnimationStart,u=o[0],d=u.style,c=u.duration,f=c===void 0?0:c,h=function(m,g,y){if(y===0)return m;var b=g.duration,w=g.easing,_=w===void 0?"ease":w,x=g.style,S=g.properties,E=g.onAnimationEnd,k=y>0?o[y-1]:g,P=S||Object.keys(x);if(typeof _=="function"||_==="spring")return[].concat(Ov(m),[a.runJSAnimation.bind(a,{from:k.style,to:x,duration:b,easing:_}),b]);var C=$E(P,b,_),N=Lr(Lr(Lr({},k.style),x),{},{transition:C});return[].concat(Ov(m),[N,b,E]).filter(poe)};return this.manager.start([l].concat(Ov(o.reduce(h,[d,Math.max(f,s)])),[i.onAnimationEnd]))}},{key:"runAnimation",value:function(i){this.manager||(this.manager=coe());var a=i.begin,o=i.duration,s=i.attributeName,l=i.to,u=i.easing,d=i.onAnimationStart,c=i.onAnimationEnd,f=i.steps,h=i.children,v=this.manager;if(this.unSubscribe=v.subscribe(this.handleStyleChange),typeof u=="function"||typeof h=="function"||u==="spring"){this.runJSAnimation(i);return}if(f.length>1){this.runStepAnimation(i);return}var m=s?Dl({},s,l):l,g=$E(Object.keys(m),o,u);v.start([d,a,Lr(Lr({},m),{},{transition:g}),o,c])}},{key:"render",value:function(){var i=this.props,a=i.children;i.begin;var o=i.duration;i.attributeName,i.easing;var s=i.isActive;i.steps,i.from,i.to,i.canBegin,i.onAnimationEnd,i.shouldReAnimate,i.onAnimationReStart;var l=Boe(i,Loe),u=O.Children.count(a),d=this.state.style;if(typeof a=="function")return a(d);if(!s||u===0||o<=0)return a;var c=function(h){var v=h.props,m=v.style,g=m===void 0?{}:m,y=v.className,b=O.cloneElement(h,Lr(Lr({},l),{},{style:Lr(Lr({},g),d),className:y}));return b};return u===1?c(O.Children.only(a)):j.createElement("div",null,O.Children.map(a,function(f){return c(f)}))}}]),r}(O.PureComponent);Gi.displayName="Animate";Gi.defaultProps={begin:0,duration:1e3,from:"",to:"",attributeName:"",easing:"ease",isActive:!0,canBegin:!0,steps:[],onAnimationEnd:function(){},onAnimationStart:function(){}};Gi.propTypes={from:_e.oneOfType([_e.object,_e.string]),to:_e.oneOfType([_e.object,_e.string]),attributeName:_e.string,duration:_e.number,begin:_e.number,easing:_e.oneOfType([_e.string,_e.func]),steps:_e.arrayOf(_e.shape({duration:_e.number.isRequired,style:_e.object.isRequired,easing:_e.oneOfType([_e.oneOf(["ease","ease-in","ease-out","ease-in-out","linear"]),_e.func]),properties:_e.arrayOf("string"),onAnimationEnd:_e.func})),children:_e.oneOfType([_e.node,_e.func]),isActive:_e.bool,canBegin:_e.bool,onAnimationEnd:_e.func,shouldReAnimate:_e.bool,onAnimationStart:_e.func,onAnimationReStart:_e.func};function rc(e){"@babel/helpers - typeof";return rc=typeof Symbol=="function"&&typeof Symbol.iterator=="symbol"?function(t){return typeof t}:function(t){return t&&typeof Symbol=="function"&&t.constructor===Symbol&&t!==Symbol.prototype?"symbol":typeof t},rc(e)}function ph(){return ph=Object.assign?Object.assign.bind():function(e){for(var t=1;t<arguments.length;t++){var r=arguments[t];for(var n in r)Object.prototype.hasOwnProperty.call(r,n)&&(e[n]=r[n])}return e},ph.apply(this,arguments)}function Joe(e,t){return rse(e)||tse(e,t)||ese(e,t)||Zoe()}function Zoe(){throw new TypeError(`Invalid attempt to destructure non-iterable instance. 342In order to be iterable, non-array objects must have a [Symbol.iterator]() method.`)}function ese(e,t){if(e){if(typeof e=="string")return BE(e,t);var r=Object.prototype.toString.call(e).slice(8,-1);if(r==="Object"&&e.constructor&&(r=e.constructor.name),r==="Map"||r==="Set")return Array.from(e);if(r==="Arguments"||/^(?:Ui|I)nt(?:8|16|32)(?:Clamped)?Array$/.test(r))return BE(e,t)}}function BE(e,t){(t==null||t>e.length)&&(t=e.length);for(var r=0,n=new Array(t);r<t;r++)n[r]=e[r];return n}function tse(e,t){var r=e==null?null:typeof Symbol<"u"&&e[Symbol.iterator]||e["@@iterator"];if(r!=null){var n,i,a,o,s=[],l=!0,u=!1;try{if(a=(r=r.call(e)).next,t!==0)for(;!(l=(n=a.call(r)).done)&&(s.push(n.value),s.length!==t);l=!0);}catch(d){u=!0,i=d}finally{try{if(!l&&r.return!=null&&(o=r.return(),Object(o)!==o))return}finally{if(u)throw i}}return s}}function rse(e){if(Array.isArray(e))return e}function UE(e,t){var r=Object.keys(e);if(Object.getOwnPropertySymbols){var n=Object.getOwnPropertySymbols(e);t&&(n=n.filter(function(i){return Object.getOwnPropertyDescriptor(e,i).enumerable})),r.push.apply(r,n)}return r}function FE(e){for(var t=1;t<arguments.length;t++){var r=arguments[t]!=null?arguments[t]:{};t%2?UE(Object(r),!0).forEach(function(n){nse(e,n,r[n])}):Object.getOwnPropertyDescriptors?Object.defineProperties(e,Object.getOwnPropertyDescriptors(r)):UE(Object(r)).forEach(function(n){Object.defineProperty(e,n,Object.getOwnPropertyDescriptor(r,n))})}return e}function nse(e,t,r){return t=ise(t),t in e?Object.defineProperty(e,t,{value:r,enumerable:!0,configurable:!0,writable:!0}):e[t]=r,e}function ise(e){var t=ase(e,"string");return rc(t)=="symbol"?t:t+""}function ase(e,t){if(rc(e)!="object"||!e)return e;var r=e[Symbol.toPrimitive];if(r!==void 0){var n=r.call(e,t||"default");if(rc(n)!="object")return n;throw new TypeError("@@toPrimitive must return a primitive value.")}return(t==="string"?String:Number)(e)}var zE=function(t,r,n,i,a){var o=Math.min(Math.abs(n)/2,Math.abs(i)/2),s=i>=0?1:-1,l=n>=0?1:-1,u=i>=0&&n>=0||i<0&&n<0?1:0,d;if(o>0&&a instanceof Array){for(var c=[0,0,0,0],f=0,h=4;f<h;f++)c[f]=a[f]>o?o:a[f];d="M".concat(t,",").concat(r+s*c[0]),c[0]>0&&(d+="A ".concat(c[0],",").concat(c[0],",0,0,").concat(u,",").concat(t+l*c[0],",").concat(r)),d+="L ".concat(t+n-l*c[1],",").concat(r),c[1]>0&&(d+="A ".concat(c[1],",").concat(c[1],",0,0,").concat(u,`, 343 `).concat(t+n,",").concat(r+s*c[1])),d+="L ".concat(t+n,",").concat(r+i-s*c[2]),c[2]>0&&(d+="A ".concat(c[2],",").concat(c[2],",0,0,").concat(u,`, 344 `).concat(t+n-l*c[2],",").concat(r+i)),d+="L ".concat(t+l*c[3],",").concat(r+i),c[3]>0&&(d+="A ".concat(c[3],",").concat(c[3],",0,0,").concat(u,`, 345 `).concat(t,",").concat(r+i-s*c[3])),d+="Z"}else if(o>0&&a===+a&&a>0){var v=Math.min(o,a);d="M ".concat(t,",").concat(r+s*v,` 346 A `).concat(v,",").concat(v,",0,0,").concat(u,",").concat(t+l*v,",").concat(r,` 347 L `).concat(t+n-l*v,",").concat(r,` 348 A `).concat(v,",").concat(v,",0,0,").concat(u,",").concat(t+n,",").concat(r+s*v,` 349 L `).concat(t+n,",").concat(r+i-s*v,` 350 A `).concat(v,",").concat(v,",0,0,").concat(u,",").concat(t+n-l*v,",").concat(r+i,` 351 L `).concat(t+l*v,",").concat(r+i,` 352 A `).concat(v,",").concat(v,",0,0,").concat(u,",").concat(t,",").concat(r+i-s*v," Z")}else d="M ".concat(t,",").concat(r," h ").concat(n," v ").concat(i," h ").concat(-n," Z");return d},ose=function(t,r){if(!t||!r)return!1;var n=t.x,i=t.y,a=r.x,o=r.y,s=r.width,l=r.height;if(Math.abs(s)>0&&Math.abs(l)>0){var u=Math.min(a,a+s),d=Math.max(a,a+s),c=Math.min(o,o+l),f=Math.max(o,o+l);return n>=u&&n<=d&&i>=c&&i<=f}return!1},sse={x:0,y:0,width:0,height:0,radius:0,isAnimationActive:!1,isUpdateAnimationActive:!1,animationBegin:0,animationDuration:1500,animationEasing:"ease"},Yw=function(t){var r=FE(FE({},sse),t),n=O.useRef(),i=O.useState(-1),a=Joe(i,2),o=a[0],s=a[1];O.useEffect(function(){if(n.current&&n.current.getTotalLength)try{var _=n.current.getTotalLength();_&&s(_)}catch{}},[]);var l=r.x,u=r.y,d=r.width,c=r.height,f=r.radius,h=r.className,v=r.animationEasing,m=r.animationDuration,g=r.animationBegin,y=r.isAnimationActive,b=r.isUpdateAnimationActive;if(l!==+l||u!==+u||d!==+d||c!==+c||d===0||c===0)return null;var w=pe("recharts-rectangle",h);return b?j.createElement(Gi,{canBegin:o>0,from:{width:d,height:c,x:l,y:u},to:{width:d,height:c,x:l,y:u},duration:m,animationEasing:v,isActive:b},function(_){var x=_.width,S=_.height,E=_.x,k=_.y;return j.createElement(Gi,{canBegin:o>0,from:"0px ".concat(o===-1?1:o,"px"),to:"".concat(o,"px 0px"),attributeName:"strokeDasharray",begin:g,duration:m,isActive:y,easing:v},j.createElement("path",ph({},Se(r,!0),{className:w,d:zE(E,k,x,S,f),ref:n})))}):j.createElement("path",ph({},Se(r,!0),{className:w,d:zE(l,u,d,c,f)}))};function s0(){return s0=Object.assign?Object.assign.bind():function(e){for(var t=1;t<arguments.length;t++){var r=arguments[t];for(var n in r)Object.prototype.hasOwnProperty.call(r,n)&&(e[n]=r[n])}return e},s0.apply(this,arguments)}var G$=function(t){var r=t.cx,n=t.cy,i=t.r,a=t.className,o=pe("recharts-dot",a);return r===+r&&n===+n&&i===+i?O.createElement("circle",s0({},Se(t,!1),Nf(t),{className:o,cx:r,cy:n,r:i})):null};function nc(e){"@babel/helpers - typeof";return nc=typeof Symbol=="function"&&typeof Symbol.iterator=="symbol"?function(t){return typeof t}:function(t){return t&&typeof Symbol=="function"&&t.constructor===Symbol&&t!==Symbol.prototype?"symbol":typeof t},nc(e)}var lse=["x","y","top","left","width","height","className"];function l0(){return l0=Object.assign?Object.assign.bind():function(e){for(var t=1;t<arguments.length;t++){var r=arguments[t];for(var n in r)Object.prototype.hasOwnProperty.call(r,n)&&(e[n]=r[n])}return e},l0.apply(this,arguments)}function WE(e,t){var r=Object.keys(e);if(Object.getOwnPropertySymbols){var n=Object.getOwnPropertySymbols(e);t&&(n=n.filter(function(i){return Object.getOwnPropertyDescriptor(e,i).enumerable})),r.push.apply(r,n)}return r}function use(e){for(var t=1;t<arguments.length;t++){var r=arguments[t]!=null?arguments[t]:{};t%2?WE(Object(r),!0).forEach(function(n){cse(e,n,r[n])}):Object.getOwnPropertyDescriptors?Object.defineProperties(e,Object.getOwnPropertyDescriptors(r)):WE(Object(r)).forEach(function(n){Object.defineProperty(e,n,Object.getOwnPropertyDescriptor(r,n))})}return e}function cse(e,t,r){return t=dse(t),t in e?Object.defineProperty(e,t,{value:r,enumerable:!0,configurable:!0,writable:!0}):e[t]=r,e}function dse(e){var t=fse(e,"string");return nc(t)=="symbol"?t:t+""}function fse(e,t){if(nc(e)!="object"||!e)return e;var r=e[Symbol.toPrimitive];if(r!==void 0){var n=r.call(e,t||"default");if(nc(n)!="object")return n;throw new TypeError("@@toPrimitive must return a primitive value.")}return(t==="string"?String:Number)(e)}function hse(e,t){if(e==null)return{};var r=pse(e,t),n,i;if(Object.getOwnPropertySymbols){var a=Object.getOwnPropertySymbols(e);for(i=0;i<a.length;i++)n=a[i],!(t.indexOf(n)>=0)&&Object.prototype.propertyIsEnumerable.call(e,n)&&(r[n]=e[n])}return r}function pse(e,t){if(e==null)return{};var r={};for(var n in e)if(Object.prototype.hasOwnProperty.call(e,n)){if(t.indexOf(n)>=0)continue;r[n]=e[n]}return r}var mse=function(t,r,n,i,a,o){return"M".concat(t,",").concat(a,"v").concat(i,"M").concat(o,",").concat(r,"h").concat(n)},vse=function(t){var r=t.x,n=r===void 0?0:r,i=t.y,a=i===void 0?0:i,o=t.top,s=o===void 0?0:o,l=t.left,u=l===void 0?0:l,d=t.width,c=d===void 0?0:d,f=t.height,h=f===void 0?0:f,v=t.className,m=hse(t,lse),g=use({x:n,y:a,top:s,left:u,width:c,height:h},m);return!Y(n)||!Y(a)||!Y(c)||!Y(h)||!Y(s)||!Y(u)?null:j.createElement("path",l0({},Se(g,!0),{className:pe("recharts-cross",v),d:mse(n,a,c,h,s,u)}))},gse=cN,yse=gse(Object.getPrototypeOf,Object),bse=yse,wse=oi,xse=bse,_se=si,Sse="[object Object]",Ose=Function.prototype,Ese=Object.prototype,Y$=Ose.toString,kse=Ese.hasOwnProperty,Pse=Y$.call(Object);function Ase(e){if(!_se(e)||wse(e)!=Sse)return!1;var t=xse(e);if(t===null)return!0;var r=kse.call(t,"constructor")&&t.constructor;return typeof r=="function"&&r instanceof r&&Y$.call(r)==Pse}var jse=Ase;const Tse=Ce(jse);var Cse=oi,Nse=si,$se="[object Boolean]";function Rse(e){return e===!0||e===!1||Nse(e)&&Cse(e)==$se}var Ise=Rse;const Mse=Ce(Ise);function ic(e){"@babel/helpers - typeof";return ic=typeof Symbol=="function"&&typeof Symbol.iterator=="symbol"?function(t){return typeof t}:function(t){return t&&typeof Symbol=="function"&&t.constructor===Symbol&&t!==Symbol.prototype?"symbol":typeof t},ic(e)}function mh(){return mh=Object.assign?Object.assign.bind():function(e){for(var t=1;t<arguments.length;t++){var r=arguments[t];for(var n in r)Object.prototype.hasOwnProperty.call(r,n)&&(e[n]=r[n])}return e},mh.apply(this,arguments)}function Dse(e,t){return Fse(e)||Use(e,t)||Bse(e,t)||Lse()}function Lse(){throw new TypeError(`Invalid attempt to destructure non-iterable instance. 353In order to be iterable, non-array objects must have a [Symbol.iterator]() method.`)}function Bse(e,t){if(e){if(typeof e=="string")return qE(e,t);var r=Object.prototype.toString.call(e).slice(8,-1);if(r==="Object"&&e.constructor&&(r=e.constructor.name),r==="Map"||r==="Set")return Array.from(e);if(r==="Arguments"||/^(?:Ui|I)nt(?:8|16|32)(?:Clamped)?Array$/.test(r))return qE(e,t)}}function qE(e,t){(t==null||t>e.length)&&(t=e.length);for(var r=0,n=new Array(t);r<t;r++)n[r]=e[r];return n}function Use(e,t){var r=e==null?null:typeof Symbol<"u"&&e[Symbol.iterator]||e["@@iterator"];if(r!=null){var n,i,a,o,s=[],l=!0,u=!1;try{if(a=(r=r.call(e)).next,t!==0)for(;!(l=(n=a.call(r)).done)&&(s.push(n.value),s.length!==t);l=!0);}catch(d){u=!0,i=d}finally{try{if(!l&&r.return!=null&&(o=r.return(),Object(o)!==o))return}finally{if(u)throw i}}return s}}function Fse(e){if(Array.isArray(e))return e}function HE(e,t){var r=Object.keys(e);if(Object.getOwnPropertySymbols){var n=Object.getOwnPropertySymbols(e);t&&(n=n.filter(function(i){return Object.getOwnPropertyDescriptor(e,i).enumerable})),r.push.apply(r,n)}return r}function VE(e){for(var t=1;t<arguments.length;t++){var r=arguments[t]!=null?arguments[t]:{};t%2?HE(Object(r),!0).forEach(function(n){zse(e,n,r[n])}):Object.getOwnPropertyDescriptors?Object.defineProperties(e,Object.getOwnPropertyDescriptors(r)):HE(Object(r)).forEach(function(n){Object.defineProperty(e,n,Object.getOwnPropertyDescriptor(r,n))})}return e}function zse(e,t,r){return t=Wse(t),t in e?Object.defineProperty(e,t,{value:r,enumerable:!0,configurable:!0,writable:!0}):e[t]=r,e}function Wse(e){var t=qse(e,"string");return ic(t)=="symbol"?t:t+""}function qse(e,t){if(ic(e)!="object"||!e)return e;var r=e[Symbol.toPrimitive];if(r!==void 0){var n=r.call(e,t||"default");if(ic(n)!="object")return n;throw new TypeError("@@toPrimitive must return a primitive value.")}return(t==="string"?String:Number)(e)}var KE=function(t,r,n,i,a){var o=n-i,s;return s="M ".concat(t,",").concat(r),s+="L ".concat(t+n,",").concat(r),s+="L ".concat(t+n-o/2,",").concat(r+a),s+="L ".concat(t+n-o/2-i,",").concat(r+a),s+="L ".concat(t,",").concat(r," Z"),s},Hse={x:0,y:0,upperWidth:0,lowerWidth:0,height:0,isUpdateAnimationActive:!1,animationBegin:0,animationDuration:1500,animationEasing:"ease"},Vse=function(t){var r=VE(VE({},Hse),t),n=O.useRef(),i=O.useState(-1),a=Dse(i,2),o=a[0],s=a[1];O.useEffect(function(){if(n.current&&n.current.getTotalLength)try{var w=n.current.getTotalLength();w&&s(w)}catch{}},[]);var l=r.x,u=r.y,d=r.upperWidth,c=r.lowerWidth,f=r.height,h=r.className,v=r.animationEasing,m=r.animationDuration,g=r.animationBegin,y=r.isUpdateAnimationActive;if(l!==+l||u!==+u||d!==+d||c!==+c||f!==+f||d===0&&c===0||f===0)return null;var b=pe("recharts-trapezoid",h);return y?j.createElement(Gi,{canBegin:o>0,from:{upperWidth:0,lowerWidth:0,height:f,x:l,y:u},to:{upperWidth:d,lowerWidth:c,height:f,x:l,y:u},duration:m,animationEasing:v,isActive:y},function(w){var _=w.upperWidth,x=w.lowerWidth,S=w.height,E=w.x,k=w.y;return j.createElement(Gi,{canBegin:o>0,from:"0px ".concat(o===-1?1:o,"px"),to:"".concat(o,"px 0px"),attributeName:"strokeDasharray",begin:g,duration:m,easing:v},j.createElement("path",mh({},Se(r,!0),{className:b,d:KE(E,k,_,x,S),ref:n})))}):j.createElement("g",null,j.createElement("path",mh({},Se(r,!0),{className:b,d:KE(l,u,d,c,f)})))},Kse=["option","shapeType","propTransformer","activeClassName","isActive"];function ac(e){"@babel/helpers - typeof";return ac=typeof Symbol=="function"&&typeof Symbol.iterator=="symbol"?function(t){return typeof t}:function(t){return t&&typeof Symbol=="function"&&t.constructor===Symbol&&t!==Symbol.prototype?"symbol":typeof t},ac(e)}function Gse(e,t){if(e==null)return{};var r=Yse(e,t),n,i;if(Object.getOwnPropertySymbols){var a=Object.getOwnPropertySymbols(e);for(i=0;i<a.length;i++)n=a[i],!(t.indexOf(n)>=0)&&Object.prototype.propertyIsEnumerable.call(e,n)&&(r[n]=e[n])}return r}function Yse(e,t){if(e==null)return{};var r={};for(var n in e)if(Object.prototype.hasOwnProperty.call(e,n)){if(t.indexOf(n)>=0)continue;r[n]=e[n]}return r}function GE(e,t){var r=Object.keys(e);if(Object.getOwnPropertySymbols){var n=Object.getOwnPropertySymbols(e);t&&(n=n.filter(function(i){return Object.getOwnPropertyDescriptor(e,i).enumerable})),r.push.apply(r,n)}return r}function vh(e){for(var t=1;t<arguments.length;t++){var r=arguments[t]!=null?arguments[t]:{};t%2?GE(Object(r),!0).forEach(function(n){Xse(e,n,r[n])}):Object.getOwnPropertyDescriptors?Object.defineProperties(e,Object.getOwnPropertyDescriptors(r)):GE(Object(r)).forEach(function(n){Object.defineProperty(e,n,Object.getOwnPropertyDescriptor(r,n))})}return e}function Xse(e,t,r){return t=Qse(t),t in e?Object.defineProperty(e,t,{value:r,enumerable:!0,configurable:!0,writable:!0}):e[t]=r,e}function Qse(e){var t=Jse(e,"string");return ac(t)=="symbol"?t:t+""}function Jse(e,t){if(ac(e)!="object"||!e)return e;var r=e[Symbol.toPrimitive];if(r!==void 0){var n=r.call(e,t||"default");if(ac(n)!="object")return n;throw new TypeError("@@toPrimitive must return a primitive value.")}return(t==="string"?String:Number)(e)}function Zse(e,t){return vh(vh({},t),e)}function ele(e,t){return e==="symbols"}function YE(e){var t=e.shapeType,r=e.elementProps;switch(t){case"rectangle":return j.createElement(Yw,r);case"trapezoid":return j.createElement(Vse,r);case"sector":return j.createElement(D$,r);case"symbols":if(ele(t))return j.createElement(fw,r);break;default:return null}}function tle(e){return O.isValidElement(e)?e.props:e}function rle(e){var t=e.option,r=e.shapeType,n=e.propTransformer,i=n===void 0?Zse:n,a=e.activeClassName,o=a===void 0?"recharts-active-shape":a,s=e.isActive,l=Gse(e,Kse),u;if(O.isValidElement(t))u=O.cloneElement(t,vh(vh({},l),tle(t)));else if(fe(t))u=t(l);else if(Tse(t)&&!Mse(t)){var d=i(t,l);u=j.createElement(YE,{shapeType:r,elementProps:d})}else{var c=l;u=j.createElement(YE,{shapeType:r,elementProps:c})}return s?j.createElement(gt,{className:o},u):u}function Xp(e,t){return t!=null&&"trapezoids"in e.props}function Qp(e,t){return t!=null&&"sectors"in e.props}function oc(e,t){return t!=null&&"points"in e.props}function nle(e,t){var r,n,i=e.x===(t==null||(r=t.labelViewBox)===null||r===void 0?void 0:r.x)||e.x===t.x,a=e.y===(t==null||(n=t.labelViewBox)===null||n===void 0?void 0:n.y)||e.y===t.y;return i&&a}function ile(e,t){var r=e.endAngle===t.endAngle,n=e.startAngle===t.startAngle;return r&&n}function ale(e,t){var r=e.x===t.x,n=e.y===t.y,i=e.z===t.z;return r&&n&&i}function ole(e,t){var r;return Xp(e,t)?r=nle:Qp(e,t)?r=ile:oc(e,t)&&(r=ale),r}function sle(e,t){var r;return Xp(e,t)?r="trapezoids":Qp(e,t)?r="sectors":oc(e,t)&&(r="points"),r}function lle(e,t){if(Xp(e,t)){var r;return(r=t.tooltipPayload)===null||r===void 0||(r=r[0])===null||r===void 0||(r=r.payload)===null||r===void 0?void 0:r.payload}if(Qp(e,t)){var n;return(n=t.tooltipPayload)===null||n===void 0||(n=n[0])===null||n===void 0||(n=n.payload)===null||n===void 0?void 0:n.payload}return oc(e,t)?t.payload:{}}function ule(e){var t=e.activeTooltipItem,r=e.graphicalItem,n=e.itemData,i=sle(r,t),a=lle(r,t),o=n.filter(function(l,u){var d=Hw(a,l),c=r.props[i].filter(function(v){var m=ole(r,t);return m(v,t)}),f=r.props[i].indexOf(c[c.length-1]),h=u===f;return d&&h}),s=n.indexOf(o[o.length-1]);return s}var cle=Math.ceil,dle=Math.max;function fle(e,t,r,n){for(var i=-1,a=dle(cle((t-e)/(r||1)),0),o=Array(a);a--;)o[n?a:++i]=e,e+=r;return o}var hle=fle,ple=AN,XE=1/0,mle=17976931348623157e292;function vle(e){if(!e)return e===0?e:0;if(e=ple(e),e===XE||e===-XE){var t=e<0?-1:1;return t*mle}return e===e?e:0}var gle=vle,yle=hle,ble=Lp,Ev=gle;function wle(e){return function(t,r,n){return n&&typeof n!="number"&&ble(t,r,n)&&(r=n=void 0),t=Ev(t),r===void 0?(r=t,t=0):r=Ev(r),n=n===void 0?t<r?1:-1:Ev(n),yle(t,r,n,e)}}var xle=wle,_le=xle,Sle=_le(),Ole=Sle;const gh=Ce(Ole);function sc(e){"@babel/helpers - typeof";return sc=typeof Symbol=="function"&&typeof Symbol.iterator=="symbol"?function(t){return typeof t}:function(t){return t&&typeof Symbol=="function"&&t.constructor===Symbol&&t!==Symbol.prototype?"symbol":typeof t},sc(e)}function QE(e,t){var r=Object.keys(e);if(Object.getOwnPropertySymbols){var n=Object.getOwnPropertySymbols(e);t&&(n=n.filter(function(i){return Object.getOwnPropertyDescriptor(e,i).enumerable})),r.push.apply(r,n)}return r}function JE(e){for(var t=1;t<arguments.length;t++){var r=arguments[t]!=null?arguments[t]:{};t%2?QE(Object(r),!0).forEach(function(n){X$(e,n,r[n])}):Object.getOwnPropertyDescriptors?Object.defineProperties(e,Object.getOwnPropertyDescriptors(r)):QE(Object(r)).forEach(function(n){Object.defineProperty(e,n,Object.getOwnPropertyDescriptor(r,n))})}return e}function X$(e,t,r){return t=Ele(t),t in e?Object.defineProperty(e,t,{value:r,enumerable:!0,configurable:!0,writable:!0}):e[t]=r,e}function Ele(e){var t=kle(e,"string");return sc(t)=="symbol"?t:t+""}function kle(e,t){if(sc(e)!="object"||!e)return e;var r=e[Symbol.toPrimitive];if(r!==void 0){var n=r.call(e,t||"default");if(sc(n)!="object")return n;throw new TypeError("@@toPrimitive must return a primitive value.")}return(t==="string"?String:Number)(e)}var Ple=["Webkit","Moz","O","ms"],Ale=function(t,r){var n=t.replace(/(\w)/,function(a){return a.toUpperCase()}),i=Ple.reduce(function(a,o){return JE(JE({},a),{},X$({},o+n,r))},{});return i[t]=r,i};function Cs(e){"@babel/helpers - typeof";return Cs=typeof Symbol=="function"&&typeof Symbol.iterator=="symbol"?function(t){return typeof t}:function(t){return t&&typeof Symbol=="function"&&t.constructor===Symbol&&t!==Symbol.prototype?"symbol":typeof t},Cs(e)}function yh(){return yh=Object.assign?Object.assign.bind():function(e){for(var t=1;t<arguments.length;t++){var r=arguments[t];for(var n in r)Object.prototype.hasOwnProperty.call(r,n)&&(e[n]=r[n])}return e},yh.apply(this,arguments)}function ZE(e,t){var r=Object.keys(e);if(Object.getOwnPropertySymbols){var n=Object.getOwnPropertySymbols(e);t&&(n=n.filter(function(i){return Object.getOwnPropertyDescriptor(e,i).enumerable})),r.push.apply(r,n)}return r}function kv(e){for(var t=1;t<arguments.length;t++){var r=arguments[t]!=null?arguments[t]:{};t%2?ZE(Object(r),!0).forEach(function(n){rr(e,n,r[n])}):Object.getOwnPropertyDescriptors?Object.defineProperties(e,Object.getOwnPropertyDescriptors(r)):ZE(Object(r)).forEach(function(n){Object.defineProperty(e,n,Object.getOwnPropertyDescriptor(r,n))})}return e}function jle(e,t){if(!(e instanceof t))throw new TypeError("Cannot call a class as a function")}function ek(e,t){for(var r=0;r<t.length;r++){var n=t[r];n.enumerable=n.enumerable||!1,n.configurable=!0,"value"in n&&(n.writable=!0),Object.defineProperty(e,J$(n.key),n)}}function Tle(e,t,r){return t&&ek(e.prototype,t),r&&ek(e,r),Object.defineProperty(e,"prototype",{writable:!1}),e}function Cle(e,t,r){return t=bh(t),Nle(e,Q$()?Reflect.construct(t,r||[],bh(e).constructor):t.apply(e,r))}function Nle(e,t){if(t&&(Cs(t)==="object"||typeof t=="function"))return t;if(t!==void 0)throw new TypeError("Derived constructors may only return object or undefined");return $le(e)}function $le(e){if(e===void 0)throw new ReferenceError("this hasn't been initialised - super() hasn't been called");return e}function Q$(){try{var e=!Boolean.prototype.valueOf.call(Reflect.construct(Boolean,[],function(){}))}catch{}return(Q$=function(){return!!e})()}function bh(e){return bh=Object.setPrototypeOf?Object.getPrototypeOf.bind():function(r){return r.__proto__||Object.getPrototypeOf(r)},bh(e)}function Rle(e,t){if(typeof t!="function"&&t!==null)throw new TypeError("Super expression must either be null or a function");e.prototype=Object.create(t&&t.prototype,{constructor:{value:e,writable:!0,configurable:!0}}),Object.defineProperty(e,"prototype",{writable:!1}),t&&u0(e,t)}function u0(e,t){return u0=Object.setPrototypeOf?Object.setPrototypeOf.bind():function(n,i){return n.__proto__=i,n},u0(e,t)}function rr(e,t,r){return t=J$(t),t in e?Object.defineProperty(e,t,{value:r,enumerable:!0,configurable:!0,writable:!0}):e[t]=r,e}function J$(e){var t=Ile(e,"string");return Cs(t)=="symbol"?t:t+""}function Ile(e,t){if(Cs(e)!="object"||!e)return e;var r=e[Symbol.toPrimitive];if(r!==void 0){var n=r.call(e,t||"default");if(Cs(n)!="object")return n;throw new TypeError("@@toPrimitive must return a primitive value.")}return(t==="string"?String:Number)(e)}var Mle=function(t){var r=t.data,n=t.startIndex,i=t.endIndex,a=t.x,o=t.width,s=t.travellerWidth;if(!r||!r.length)return{};var l=r.length,u=Ql().domain(gh(0,l)).range([a,a+o-s]),d=u.domain().map(function(c){return u(c)});return{isTextActive:!1,isSlideMoving:!1,isTravellerMoving:!1,isTravellerFocused:!1,startX:u(n),endX:u(i),scale:u,scaleValues:d}},tk=function(t){return t.changedTouches&&!!t.changedTouches.length},Ns=function(e){function t(r){var n;return jle(this,t),n=Cle(this,t,[r]),rr(n,"handleDrag",function(i){n.leaveTimer&&(clearTimeout(n.leaveTimer),n.leaveTimer=null),n.state.isTravellerMoving?n.handleTravellerMove(i):n.state.isSlideMoving&&n.handleSlideDrag(i)}),rr(n,"handleTouchMove",function(i){i.changedTouches!=null&&i.changedTouches.length>0&&n.handleDrag(i.changedTouches[0])}),rr(n,"handleDragEnd",function(){n.setState({isTravellerMoving:!1,isSlideMoving:!1},function(){var i=n.props,a=i.endIndex,o=i.onDragEnd,s=i.startIndex;o==null||o({endIndex:a,startIndex:s})}),n.detachDragEndListener()}),rr(n,"handleLeaveWrapper",function(){(n.state.isTravellerMoving||n.state.isSlideMoving)&&(n.leaveTimer=window.setTimeout(n.handleDragEnd,n.props.leaveTimeOut))}),rr(n,"handleEnterSlideOrTraveller",function(){n.setState({isTextActive:!0})}),rr(n,"handleLeaveSlideOrTraveller",function(){n.setState({isTextActive:!1})}),rr(n,"handleSlideDragStart",function(i){var a=tk(i)?i.changedTouches[0]:i;n.setState({isTravellerMoving:!1,isSlideMoving:!0,slideMoveStartX:a.pageX}),n.attachDragEndListener()}),n.travellerDragStartHandlers={startX:n.handleTravellerDragStart.bind(n,"startX"),endX:n.handleTravellerDragStart.bind(n,"endX")},n.state={},n}return Rle(t,e),Tle(t,[{key:"componentWillUnmount",value:function(){this.leaveTimer&&(clearTimeout(this.leaveTimer),this.leaveTimer=null),this.detachDragEndListener()}},{key:"getIndex",value:function(n){var i=n.startX,a=n.endX,o=this.state.scaleValues,s=this.props,l=s.gap,u=s.data,d=u.length-1,c=Math.min(i,a),f=Math.max(i,a),h=t.getIndexInRange(o,c),v=t.getIndexInRange(o,f);return{startIndex:h-h%l,endIndex:v===d?d:v-v%l}}},{key:"getTextOfTick",value:function(n){var i=this.props,a=i.data,o=i.tickFormatter,s=i.dataKey,l=Tn(a[n],s,n);return fe(o)?o(l,n):l}},{key:"attachDragEndListener",value:function(){window.addEventListener("mouseup",this.handleDragEnd,!0),window.addEventListener("touchend",this.handleDragEnd,!0),window.addEventListener("mousemove",this.handleDrag,!0)}},{key:"detachDragEndListener",value:function(){window.removeEventListener("mouseup",this.handleDragEnd,!0),window.removeEventListener("touchend",this.handleDragEnd,!0),window.removeEventListener("mousemove",this.handleDrag,!0)}},{key:"handleSlideDrag",value:function(n){var i=this.state,a=i.slideMoveStartX,o=i.startX,s=i.endX,l=this.props,u=l.x,d=l.width,c=l.travellerWidth,f=l.startIndex,h=l.endIndex,v=l.onChange,m=n.pageX-a;m>0?m=Math.min(m,u+d-c-s,u+d-c-o):m<0&&(m=Math.max(m,u-o,u-s));var g=this.getIndex({startX:o+m,endX:s+m});(g.startIndex!==f||g.endIndex!==h)&&v&&v(g),this.setState({startX:o+m,endX:s+m,slideMoveStartX:n.pageX})}},{key:"handleTravellerDragStart",value:function(n,i){var a=tk(i)?i.changedTouches[0]:i;this.setState({isSlideMoving:!1,isTravellerMoving:!0,movingTravellerId:n,brushMoveStartX:a.pageX}),this.attachDragEndListener()}},{key:"handleTravellerMove",value:function(n){var i=this.state,a=i.brushMoveStartX,o=i.movingTravellerId,s=i.endX,l=i.startX,u=this.state[o],d=this.props,c=d.x,f=d.width,h=d.travellerWidth,v=d.onChange,m=d.gap,g=d.data,y={startX:this.state.startX,endX:this.state.endX},b=n.pageX-a;b>0?b=Math.min(b,c+f-h-u):b<0&&(b=Math.max(b,c-u)),y[o]=u+b;var w=this.getIndex(y),_=w.startIndex,x=w.endIndex,S=function(){var k=g.length-1;return o==="startX"&&(s>l?_%m===0:x%m===0)||s<l&&x===k||o==="endX"&&(s>l?x%m===0:_%m===0)||s>l&&x===k};this.setState(rr(rr({},o,u+b),"brushMoveStartX",n.pageX),function(){v&&S()&&v(w)})}},{key:"handleTravellerMoveKeyboard",value:function(n,i){var a=this,o=this.state,s=o.scaleValues,l=o.startX,u=o.endX,d=this.state[i],c=s.indexOf(d);if(c!==-1){var f=c+n;if(!(f===-1||f>=s.length)){var h=s[f];i==="startX"&&h>=u||i==="endX"&&h<=l||this.setState(rr({},i,h),function(){a.props.onChange(a.getIndex({startX:a.state.startX,endX:a.state.endX}))})}}}},{key:"renderBackground",value:function(){var n=this.props,i=n.x,a=n.y,o=n.width,s=n.height,l=n.fill,u=n.stroke;return j.createElement("rect",{stroke:u,fill:l,x:i,y:a,width:o,height:s})}},{key:"renderPanorama",value:function(){var n=this.props,i=n.x,a=n.y,o=n.width,s=n.height,l=n.data,u=n.children,d=n.padding,c=O.Children.only(u);return c?j.cloneElement(c,{x:i,y:a,width:o,height:s,margin:d,compact:!0,data:l}):null}},{key:"renderTravellerLayer",value:function(n,i){var a,o,s=this,l=this.props,u=l.y,d=l.travellerWidth,c=l.height,f=l.traveller,h=l.ariaLabel,v=l.data,m=l.startIndex,g=l.endIndex,y=Math.max(n,this.props.x),b=kv(kv({},Se(this.props,!1)),{},{x:y,y:u,width:d,height:c}),w=h||"Min value: ".concat((a=v[m])===null||a===void 0?void 0:a.name,", Max value: ").concat((o=v[g])===null||o===void 0?void 0:o.name);return j.createElement(gt,{tabIndex:0,role:"slider","aria-label":w,"aria-valuenow":n,className:"recharts-brush-traveller",onMouseEnter:this.handleEnterSlideOrTraveller,onMouseLeave:this.handleLeaveSlideOrTraveller,onMouseDown:this.travellerDragStartHandlers[i],onTouchStart:this.travellerDragStartHandlers[i],onKeyDown:function(x){["ArrowLeft","ArrowRight"].includes(x.key)&&(x.preventDefault(),x.stopPropagation(),s.handleTravellerMoveKeyboard(x.key==="ArrowRight"?1:-1,i))},onFocus:function(){s.setState({isTravellerFocused:!0})},onBlur:function(){s.setState({isTravellerFocused:!1})},style:{cursor:"col-resize"}},t.renderTraveller(f,b))}},{key:"renderSlide",value:function(n,i){var a=this.props,o=a.y,s=a.height,l=a.stroke,u=a.travellerWidth,d=Math.min(n,i)+u,c=Math.max(Math.abs(i-n)-u,0);return j.createElement("rect",{className:"recharts-brush-slide",onMouseEnter:this.handleEnterSlideOrTraveller,onMouseLeave:this.handleLeaveSlideOrTraveller,onMouseDown:this.handleSlideDragStart,onTouchStart:this.handleSlideDragStart,style:{cursor:"move"},stroke:"none",fill:l,fillOpacity:.2,x:d,y:o,width:c,height:s})}},{key:"renderText",value:function(){var n=this.props,i=n.startIndex,a=n.endIndex,o=n.y,s=n.height,l=n.travellerWidth,u=n.stroke,d=this.state,c=d.startX,f=d.endX,h=5,v={pointerEvents:"none",fill:u};return j.createElement(gt,{className:"recharts-brush-texts"},j.createElement(Gf,yh({textAnchor:"end",verticalAnchor:"middle",x:Math.min(c,f)-h,y:o+s/2},v),this.getTextOfTick(i)),j.createElement(Gf,yh({textAnchor:"start",verticalAnchor:"middle",x:Math.max(c,f)+l+h,y:o+s/2},v),this.getTextOfTick(a)))}},{key:"render",value:function(){var n=this.props,i=n.data,a=n.className,o=n.children,s=n.x,l=n.y,u=n.width,d=n.height,c=n.alwaysShowText,f=this.state,h=f.startX,v=f.endX,m=f.isTextActive,g=f.isSlideMoving,y=f.isTravellerMoving,b=f.isTravellerFocused;if(!i||!i.length||!Y(s)||!Y(l)||!Y(u)||!Y(d)||u<=0||d<=0)return null;var w=pe("recharts-brush",a),_=j.Children.count(o)===1,x=Ale("userSelect","none");return j.createElement(gt,{className:w,onMouseLeave:this.handleLeaveWrapper,onTouchMove:this.handleTouchMove,style:x},this.renderBackground(),_&&this.renderPanorama(),this.renderSlide(h,v),this.renderTravellerLayer(h,"startX"),this.renderTravellerLayer(v,"endX"),(m||g||y||b||c)&&this.renderText())}}],[{key:"renderDefaultTraveller",value:function(n){var i=n.x,a=n.y,o=n.width,s=n.height,l=n.stroke,u=Math.floor(a+s/2)-1;return j.createElement(j.Fragment,null,j.createElement("rect",{x:i,y:a,width:o,height:s,fill:l,stroke:"none"}),j.createElement("line",{x1:i+1,y1:u,x2:i+o-1,y2:u,fill:"none",stroke:"#fff"}),j.createElement("line",{x1:i+1,y1:u+2,x2:i+o-1,y2:u+2,fill:"none",stroke:"#fff"}))}},{key:"renderTraveller",value:function(n,i){var a;return j.isValidElement(n)?a=j.cloneElement(n,i):fe(n)?a=n(i):a=t.renderDefaultTraveller(i),a}},{key:"getDerivedStateFromProps",value:function(n,i){var a=n.data,o=n.width,s=n.x,l=n.travellerWidth,u=n.updateId,d=n.startIndex,c=n.endIndex;if(a!==i.prevData||u!==i.prevUpdateId)return kv({prevData:a,prevTravellerWidth:l,prevUpdateId:u,prevX:s,prevWidth:o},a&&a.length?Mle({data:a,width:o,x:s,travellerWidth:l,startIndex:d,endIndex:c}):{scale:null,scaleValues:null});if(i.scale&&(o!==i.prevWidth||s!==i.prevX||l!==i.prevTravellerWidth)){i.scale.range([s,s+o-l]);var f=i.scale.domain().map(function(h){return i.scale(h)});return{prevData:a,prevTravellerWidth:l,prevUpdateId:u,prevX:s,prevWidth:o,startX:i.scale(n.startIndex),endX:i.scale(n.endIndex),scaleValues:f}}return null}},{key:"getIndexInRange",value:function(n,i){for(var a=n.length,o=0,s=a-1;s-o>1;){var l=Math.floor((o+s)/2);n[l]>i?s=l:o=l}return i>=n[s]?s:o}}])}(O.PureComponent);rr(Ns,"displayName","Brush");rr(Ns,"defaultProps",{height:40,travellerWidth:5,gap:1,fill:"#fff",stroke:"#666",padding:{top:1,right:1,bottom:1,left:1},leaveTimeOut:1e3,alwaysShowText:!1});var Dle=ww;function Lle(e,t){var r;return Dle(e,function(n,i,a){return r=t(n,i,a),!r}),!!r}var Ble=Lle,Ule=rN,Fle=sl,zle=Ble,Wle=Jt,qle=Lp;function Hle(e,t,r){var n=Wle(e)?Ule:zle;return r&&qle(e,t,r)&&(t=void 0),n(e,Fle(t))}var Vle=Hle;const Kle=Ce(Vle);var En=function(t,r){var n=t.alwaysShow,i=t.ifOverflow;return n&&(i="extendDomain"),i===r},rk=SN;function Gle(e,t,r){t=="__proto__"&&rk?rk(e,t,{configurable:!0,enumerable:!0,value:r,writable:!0}):e[t]=r}var Yle=Gle,Xle=Yle,Qle=xN,Jle=sl;function Zle(e,t){var r={};return t=Jle(t),Qle(e,function(n,i,a){Xle(r,i,t(n,i,a))}),r}var eue=Zle;const tue=Ce(eue);function rue(e,t){for(var r=-1,n=e==null?0:e.length;++r<n;)if(!t(e[r],r,e))return!1;return!0}var nue=rue,iue=ww;function aue(e,t){var r=!0;return iue(e,function(n,i,a){return r=!!t(n,i,a),r}),r}var oue=aue,sue=nue,lue=oue,uue=sl,cue=Jt,due=Lp;function fue(e,t,r){var n=cue(e)?sue:lue;return r&&due(e,t,r)&&(t=void 0),n(e,uue(t))}var hue=fue;const pue=Ce(hue);var mue=["x","y"];function lc(e){"@babel/helpers - typeof";return lc=typeof Symbol=="function"&&typeof Symbol.iterator=="symbol"?function(t){return typeof t}:function(t){return t&&typeof Symbol=="function"&&t.constructor===Symbol&&t!==Symbol.prototype?"symbol":typeof t},lc(e)}function c0(){return c0=Object.assign?Object.assign.bind():function(e){for(var t=1;t<arguments.length;t++){var r=arguments[t];for(var n in r)Object.prototype.hasOwnProperty.call(r,n)&&(e[n]=r[n])}return e},c0.apply(this,arguments)}function nk(e,t){var r=Object.keys(e);if(Object.getOwnPropertySymbols){var n=Object.getOwnPropertySymbols(e);t&&(n=n.filter(function(i){return Object.getOwnPropertyDescriptor(e,i).enumerable})),r.push.apply(r,n)}return r}function Cl(e){for(var t=1;t<arguments.length;t++){var r=arguments[t]!=null?arguments[t]:{};t%2?nk(Object(r),!0).forEach(function(n){vue(e,n,r[n])}):Object.getOwnPropertyDescriptors?Object.defineProperties(e,Object.getOwnPropertyDescriptors(r)):nk(Object(r)).forEach(function(n){Object.defineProperty(e,n,Object.getOwnPropertyDescriptor(r,n))})}return e}function vue(e,t,r){return t=gue(t),t in e?Object.defineProperty(e,t,{value:r,enumerable:!0,configurable:!0,writable:!0}):e[t]=r,e}function gue(e){var t=yue(e,"string");return lc(t)=="symbol"?t:t+""}function yue(e,t){if(lc(e)!="object"||!e)return e;var r=e[Symbol.toPrimitive];if(r!==void 0){var n=r.call(e,t||"default");if(lc(n)!="object")return n;throw new TypeError("@@toPrimitive must return a primitive value.")}return(t==="string"?String:Number)(e)}function bue(e,t){if(e==null)return{};var r=wue(e,t),n,i;if(Object.getOwnPropertySymbols){var a=Object.getOwnPropertySymbols(e);for(i=0;i<a.length;i++)n=a[i],!(t.indexOf(n)>=0)&&Object.prototype.propertyIsEnumerable.call(e,n)&&(r[n]=e[n])}return r}function wue(e,t){if(e==null)return{};var r={};for(var n in e)if(Object.prototype.hasOwnProperty.call(e,n)){if(t.indexOf(n)>=0)continue;r[n]=e[n]}return r}function xue(e,t){var r=e.x,n=e.y,i=bue(e,mue),a="".concat(r),o=parseInt(a,10),s="".concat(n),l=parseInt(s,10),u="".concat(t.height||i.height),d=parseInt(u,10),c="".concat(t.width||i.width),f=parseInt(c,10);return Cl(Cl(Cl(Cl(Cl({},t),i),o?{x:o}:{}),l?{y:l}:{}),{},{height:d,width:f,name:t.name,radius:t.radius})}function ik(e){return j.createElement(rle,c0({shapeType:"rectangle",propTransformer:xue,activeClassName:"recharts-active-bar"},e))}var _ue=function(t){var r=arguments.length>1&&arguments[1]!==void 0?arguments[1]:0;return function(n,i){if(typeof t=="number")return t;var a=Y(n)||Mq(n);return a?t(n,i):(a||Xa(),r)}},Sue=["value","background"],Z$;function $s(e){"@babel/helpers - typeof";return $s=typeof Symbol=="function"&&typeof Symbol.iterator=="symbol"?function(t){return typeof t}:function(t){return t&&typeof Symbol=="function"&&t.constructor===Symbol&&t!==Symbol.prototype?"symbol":typeof t},$s(e)}function Oue(e,t){if(e==null)return{};var r=Eue(e,t),n,i;if(Object.getOwnPropertySymbols){var a=Object.getOwnPropertySymbols(e);for(i=0;i<a.length;i++)n=a[i],!(t.indexOf(n)>=0)&&Object.prototype.propertyIsEnumerable.call(e,n)&&(r[n]=e[n])}return r}function Eue(e,t){if(e==null)return{};var r={};for(var n in e)if(Object.prototype.hasOwnProperty.call(e,n)){if(t.indexOf(n)>=0)continue;r[n]=e[n]}return r}function wh(){return wh=Object.assign?Object.assign.bind():function(e){for(var t=1;t<arguments.length;t++){var r=arguments[t];for(var n in r)Object.prototype.hasOwnProperty.call(r,n)&&(e[n]=r[n])}return e},wh.apply(this,arguments)}function ak(e,t){var r=Object.keys(e);if(Object.getOwnPropertySymbols){var n=Object.getOwnPropertySymbols(e);t&&(n=n.filter(function(i){return Object.getOwnPropertyDescriptor(e,i).enumerable})),r.push.apply(r,n)}return r}function tt(e){for(var t=1;t<arguments.length;t++){var r=arguments[t]!=null?arguments[t]:{};t%2?ak(Object(r),!0).forEach(function(n){$i(e,n,r[n])}):Object.getOwnPropertyDescriptors?Object.defineProperties(e,Object.getOwnPropertyDescriptors(r)):ak(Object(r)).forEach(function(n){Object.defineProperty(e,n,Object.getOwnPropertyDescriptor(r,n))})}return e}function kue(e,t){if(!(e instanceof t))throw new TypeError("Cannot call a class as a function")}function ok(e,t){for(var r=0;r<t.length;r++){var n=t[r];n.enumerable=n.enumerable||!1,n.configurable=!0,"value"in n&&(n.writable=!0),Object.defineProperty(e,t2(n.key),n)}}function Pue(e,t,r){return t&&ok(e.prototype,t),r&&ok(e,r),Object.defineProperty(e,"prototype",{writable:!1}),e}function Aue(e,t,r){return t=xh(t),jue(e,e2()?Reflect.construct(t,r||[],xh(e).constructor):t.apply(e,r))}function jue(e,t){if(t&&($s(t)==="object"||typeof t=="function"))return t;if(t!==void 0)throw new TypeError("Derived constructors may only return object or undefined");return Tue(e)}function Tue(e){if(e===void 0)throw new ReferenceError("this hasn't been initialised - super() hasn't been called");return e}function e2(){try{var e=!Boolean.prototype.valueOf.call(Reflect.construct(Boolean,[],function(){}))}catch{}return(e2=function(){return!!e})()}function xh(e){return xh=Object.setPrototypeOf?Object.getPrototypeOf.bind():function(r){return r.__proto__||Object.getPrototypeOf(r)},xh(e)}function Cue(e,t){if(typeof t!="function"&&t!==null)throw new TypeError("Super expression must either be null or a function");e.prototype=Object.create(t&&t.prototype,{constructor:{value:e,writable:!0,configurable:!0}}),Object.defineProperty(e,"prototype",{writable:!1}),t&&d0(e,t)}function d0(e,t){return d0=Object.setPrototypeOf?Object.setPrototypeOf.bind():function(n,i){return n.__proto__=i,n},d0(e,t)}function $i(e,t,r){return t=t2(t),t in e?Object.defineProperty(e,t,{value:r,enumerable:!0,configurable:!0,writable:!0}):e[t]=r,e}function t2(e){var t=Nue(e,"string");return $s(t)=="symbol"?t:t+""}function Nue(e,t){if($s(e)!="object"||!e)return e;var r=e[Symbol.toPrimitive];if(r!==void 0){var n=r.call(e,t||"default");if($s(n)!="object")return n;throw new TypeError("@@toPrimitive must return a primitive value.")}return(t==="string"?String:Number)(e)}var Yi=function(e){function t(){var r;kue(this,t);for(var n=arguments.length,i=new Array(n),a=0;a<n;a++)i[a]=arguments[a];return r=Aue(this,t,[].concat(i)),$i(r,"state",{isAnimationFinished:!1}),$i(r,"id",Cp("recharts-bar-")),$i(r,"handleAnimationEnd",function(){var o=r.props.onAnimationEnd;r.setState({isAnimationFinished:!0}),o&&o()}),$i(r,"handleAnimationStart",function(){var o=r.props.onAnimationStart;r.setState({isAnimationFinished:!1}),o&&o()}),r}return Cue(t,e),Pue(t,[{key:"renderRectanglesStatically",value:function(n){var i=this,a=this.props,o=a.shape,s=a.dataKey,l=a.activeIndex,u=a.activeBar,d=Se(this.props,!1);return n&&n.map(function(c,f){var h=f===l,v=h?u:o,m=tt(tt(tt({},d),c),{},{isActive:h,option:v,index:f,dataKey:s,onAnimationStart:i.handleAnimationStart,onAnimationEnd:i.handleAnimationEnd});return j.createElement(gt,wh({className:"recharts-bar-rectangle"},$f(i.props,c,f),{key:"rectangle-".concat(c==null?void 0:c.x,"-").concat(c==null?void 0:c.y,"-").concat(c==null?void 0:c.value,"-").concat(f)}),j.createElement(ik,m))})}},{key:"renderRectanglesWithAnimation",value:function(){var n=this,i=this.props,a=i.data,o=i.layout,s=i.isAnimationActive,l=i.animationBegin,u=i.animationDuration,d=i.animationEasing,c=i.animationId,f=this.state.prevData;return j.createElement(Gi,{begin:l,duration:u,isActive:s,easing:d,from:{t:0},to:{t:1},key:"bar-".concat(c),onAnimationEnd:this.handleAnimationEnd,onAnimationStart:this.handleAnimationStart},function(h){var v=h.t,m=a.map(function(g,y){var b=f&&f[y];if(b){var w=go(b.x,g.x),_=go(b.y,g.y),x=go(b.width,g.width),S=go(b.height,g.height);return tt(tt({},g),{},{x:w(v),y:_(v),width:x(v),height:S(v)})}if(o==="horizontal"){var E=go(0,g.height),k=E(v);return tt(tt({},g),{},{y:g.y+g.height-k,height:k})}var P=go(0,g.width),C=P(v);return tt(tt({},g),{},{width:C})});return j.createElement(gt,null,n.renderRectanglesStatically(m))})}},{key:"renderRectangles",value:function(){var n=this.props,i=n.data,a=n.isAnimationActive,o=this.state.prevData;return a&&i&&i.length&&(!o||!Hw(o,i))?this.renderRectanglesWithAnimation():this.renderRectanglesStatically(i)}},{key:"renderBackground",value:function(){var n=this,i=this.props,a=i.data,o=i.dataKey,s=i.activeIndex,l=Se(this.props.background,!1);return a.map(function(u,d){u.value;var c=u.background,f=Oue(u,Sue);if(!c)return null;var h=tt(tt(tt(tt(tt({},f),{},{fill:"#eee"},c),l),$f(n.props,u,d)),{},{onAnimationStart:n.handleAnimationStart,onAnimationEnd:n.handleAnimationEnd,dataKey:o,index:d,className:"recharts-bar-background-rectangle"});return j.createElement(ik,wh({key:"background-bar-".concat(d),option:n.props.background,isActive:d===s},h))})}},{key:"renderErrorBar",value:function(n,i){if(this.props.isAnimationActive&&!this.state.isAnimationFinished)return null;var a=this.props,o=a.data,s=a.xAxis,l=a.yAxis,u=a.layout,d=a.children,c=tn(d,Yp);if(!c)return null;var f=u==="vertical"?o[0].height/2:o[0].width/2,h=function(g,y){var b=Array.isArray(g.value)?g.value[1]:g.value;return{x:g.x,y:g.y,value:b,errorVal:Tn(g,y)}},v={clipPath:n?"url(#clipPath-".concat(i,")"):null};return j.createElement(gt,v,c.map(function(m){return j.cloneElement(m,{key:"error-bar-".concat(i,"-").concat(m.props.dataKey),data:o,xAxis:s,yAxis:l,layout:u,offset:f,dataPointFormatter:h})}))}},{key:"render",value:function(){var n=this.props,i=n.hide,a=n.data,o=n.className,s=n.xAxis,l=n.yAxis,u=n.left,d=n.top,c=n.width,f=n.height,h=n.isAnimationActive,v=n.background,m=n.id;if(i||!a||!a.length)return null;var g=this.state.isAnimationFinished,y=pe("recharts-bar",o),b=s&&s.allowDataOverflow,w=l&&l.allowDataOverflow,_=b||w,x=we(m)?this.id:m;return j.createElement(gt,{className:y},b||w?j.createElement("defs",null,j.createElement("clipPath",{id:"clipPath-".concat(x)},j.createElement("rect",{x:b?u:u-c/2,y:w?d:d-f/2,width:b?c:c*2,height:w?f:f*2}))):null,j.createElement(gt,{className:"recharts-bar-rectangles",clipPath:_?"url(#clipPath-".concat(x,")"):null},v?this.renderBackground():null,this.renderRectangles()),this.renderErrorBar(_,x),(!h||g)&&Ua.renderCallByParent(this.props,a))}}],[{key:"getDerivedStateFromProps",value:function(n,i){return n.animationId!==i.prevAnimationId?{prevAnimationId:n.animationId,curData:n.data,prevData:i.curData}:n.data!==i.curData?{curData:n.data}:null}}])}(O.PureComponent);Z$=Yi;$i(Yi,"displayName","Bar");$i(Yi,"defaultProps",{xAxisId:0,yAxisId:0,legendType:"rect",minPointSize:0,hide:!1,data:[],layout:"vertical",activeBar:!1,isAnimationActive:!zi.isSsr,animationBegin:0,animationDuration:400,animationEasing:"ease"});$i(Yi,"getComposedData",function(e){var t=e.props,r=e.item,n=e.barPosition,i=e.bandSize,a=e.xAxis,o=e.yAxis,s=e.xAxisTicks,l=e.yAxisTicks,u=e.stackedData,d=e.dataStartIndex,c=e.displayedData,f=e.offset,h=oie(n,r);if(!h)return null;var v=t.layout,m=r.type.defaultProps,g=m!==void 0?tt(tt({},m),r.props):r.props,y=g.dataKey,b=g.children,w=g.minPointSize,_=v==="horizontal"?o:a,x=u?_.scale.domain():null,S=pie({numericAxis:_}),E=tn(b,Vf),k=c.map(function(P,C){var N,$,D,I,R,M;u?N=sie(u[d+C],x):(N=Tn(P,y),Array.isArray(N)||(N=[S,N]));var L=_ue(w,Z$.defaultProps.minPointSize)(N[1],C);if(v==="horizontal"){var A,T=[o.scale(N[0]),o.scale(N[1])],U=T[0],q=T[1];$=iE({axis:a,ticks:s,bandSize:i,offset:h.offset,entry:P,index:C}),D=(A=q??U)!==null&&A!==void 0?A:void 0,I=h.size;var B=U-q;if(R=Number.isNaN(B)?0:B,M={x:$,y:o.y,width:I,height:o.height},Math.abs(L)>0&&Math.abs(R)<Math.abs(L)){var W=Xr(R||L)*(Math.abs(L)-Math.abs(R));D-=W,R+=W}}else{var K=[a.scale(N[0]),a.scale(N[1])],Z=K[0],xe=K[1];if($=Z,D=iE({axis:o,ticks:l,bandSize:i,offset:h.offset,entry:P,index:C}),I=xe-Z,R=h.size,M={x:a.x,y:D,width:a.width,height:R},Math.abs(L)>0&&Math.abs(I)<Math.abs(L)){var ue=Xr(I||L)*(Math.abs(L)-Math.abs(I));I+=ue}}return tt(tt(tt({},P),{},{x:$,y:D,width:I,height:R,value:u?N:N[1],payload:P,background:M},E&&E[C]&&E[C].props),{},{tooltipPayload:[R$(r,P)],tooltipPosition:{x:$+I/2,y:D+R/2}})});return tt({data:k,layout:v},f)});function uc(e){"@babel/helpers - typeof";return uc=typeof Symbol=="function"&&typeof Symbol.iterator=="symbol"?function(t){return typeof t}:function(t){return t&&typeof Symbol=="function"&&t.constructor===Symbol&&t!==Symbol.prototype?"symbol":typeof t},uc(e)}function $ue(e,t){if(!(e instanceof t))throw new TypeError("Cannot call a class as a function")}function sk(e,t){for(var r=0;r<t.length;r++){var n=t[r];n.enumerable=n.enumerable||!1,n.configurable=!0,"value"in n&&(n.writable=!0),Object.defineProperty(e,r2(n.key),n)}}function Rue(e,t,r){return t&&sk(e.prototype,t),r&&sk(e,r),Object.defineProperty(e,"prototype",{writable:!1}),e}function lk(e,t){var r=Object.keys(e);if(Object.getOwnPropertySymbols){var n=Object.getOwnPropertySymbols(e);t&&(n=n.filter(function(i){return Object.getOwnPropertyDescriptor(e,i).enumerable})),r.push.apply(r,n)}return r}function Kr(e){for(var t=1;t<arguments.length;t++){var r=arguments[t]!=null?arguments[t]:{};t%2?lk(Object(r),!0).forEach(function(n){Jp(e,n,r[n])}):Object.getOwnPropertyDescriptors?Object.defineProperties(e,Object.getOwnPropertyDescriptors(r)):lk(Object(r)).forEach(function(n){Object.defineProperty(e,n,Object.getOwnPropertyDescriptor(r,n))})}return e}function Jp(e,t,r){return t=r2(t),t in e?Object.defineProperty(e,t,{value:r,enumerable:!0,configurable:!0,writable:!0}):e[t]=r,e}function r2(e){var t=Iue(e,"string");return uc(t)=="symbol"?t:t+""}function Iue(e,t){if(uc(e)!="object"||!e)return e;var r=e[Symbol.toPrimitive];if(r!==void 0){var n=r.call(e,t||"default");if(uc(n)!="object")return n;throw new TypeError("@@toPrimitive must return a primitive value.")}return(t==="string"?String:Number)(e)}var Mue=function(t,r,n,i,a){var o=t.width,s=t.height,l=t.layout,u=t.children,d=Object.keys(r),c={left:n.left,leftMirror:n.left,right:o-n.right,rightMirror:o-n.right,top:n.top,topMirror:n.top,bottom:s-n.bottom,bottomMirror:s-n.bottom},f=!!ir(u,Yi);return d.reduce(function(h,v){var m=r[v],g=m.orientation,y=m.domain,b=m.padding,w=b===void 0?{}:b,_=m.mirror,x=m.reversed,S="".concat(g).concat(_?"Mirror":""),E,k,P,C,N;if(m.type==="number"&&(m.padding==="gap"||m.padding==="no-gap")){var $=y[1]-y[0],D=1/0,I=m.categoricalDomain.sort(Bq);if(I.forEach(function(K,Z){Z>0&&(D=Math.min((K||0)-(I[Z-1]||0),D))}),Number.isFinite(D)){var R=D/$,M=m.layout==="vertical"?n.height:n.width;if(m.padding==="gap"&&(E=R*M/2),m.padding==="no-gap"){var L=Ga(t.barCategoryGap,R*M),A=R*M/2;E=A-L-(A-L)/M*L}}}i==="xAxis"?k=[n.left+(w.left||0)+(E||0),n.left+n.width-(w.right||0)-(E||0)]:i==="yAxis"?k=l==="horizontal"?[n.top+n.height-(w.bottom||0),n.top+(w.top||0)]:[n.top+(w.top||0)+(E||0),n.top+n.height-(w.bottom||0)-(E||0)]:k=m.range,x&&(k=[k[1],k[0]]);var T=iie(m,a,f),U=T.scale,q=T.realScaleType;U.domain(y).range(k),aie(U);var B=hie(U,Kr(Kr({},m),{},{realScaleType:q}));i==="xAxis"?(N=g==="top"&&!_||g==="bottom"&&_,P=n.left,C=c[S]-N*m.height):i==="yAxis"&&(N=g==="left"&&!_||g==="right"&&_,P=c[S]-N*m.width,C=n.top);var W=Kr(Kr(Kr({},m),B),{},{realScaleType:q,x:P,y:C,scale:U,width:i==="xAxis"?n.width:m.width,height:i==="yAxis"?n.height:m.height});return W.bandSize=lh(W,B),!m.hide&&i==="xAxis"?c[S]+=(N?-1:1)*W.height:m.hide||(c[S]+=(N?-1:1)*W.width),Kr(Kr({},h),{},Jp({},v,W))},{})},n2=function(t,r){var n=t.x,i=t.y,a=r.x,o=r.y;return{x:Math.min(n,a),y:Math.min(i,o),width:Math.abs(a-n),height:Math.abs(o-i)}},Due=function(t){var r=t.x1,n=t.y1,i=t.x2,a=t.y2;return n2({x:r,y:n},{x:i,y:a})},i2=function(){function e(t){$ue(this,e),this.scale=t}return Rue(e,[{key:"domain",get:function(){return this.scale.domain}},{key:"range",get:function(){return this.scale.range}},{key:"rangeMin",get:function(){return this.range()[0]}},{key:"rangeMax",get:function(){return this.range()[1]}},{key:"bandwidth",get:function(){return this.scale.bandwidth}},{key:"apply",value:function(r){var n=arguments.length>1&&arguments[1]!==void 0?arguments[1]:{},i=n.bandAware,a=n.position;if(r!==void 0){if(a)switch(a){case"start":return this.scale(r);case"middle":{var o=this.bandwidth?this.bandwidth()/2:0;return this.scale(r)+o}case"end":{var s=this.bandwidth?this.bandwidth():0;return this.scale(r)+s}default:return this.scale(r)}if(i){var l=this.bandwidth?this.bandwidth()/2:0;return this.scale(r)+l}return this.scale(r)}}},{key:"isInRange",value:function(r){var n=this.range(),i=n[0],a=n[n.length-1];return i<=a?r>=i&&r<=a:r>=a&&r<=i}}],[{key:"create",value:function(r){return new e(r)}}])}();Jp(i2,"EPS",1e-4);var Xw=function(t){var r=Object.keys(t).reduce(function(n,i){return Kr(Kr({},n),{},Jp({},i,i2.create(t[i])))},{});return Kr(Kr({},r),{},{apply:function(i){var a=arguments.length>1&&arguments[1]!==void 0?arguments[1]:{},o=a.bandAware,s=a.position;return tue(i,function(l,u){return r[u].apply(l,{bandAware:o,position:s})})},isInRange:function(i){return pue(i,function(a,o){return r[o].isInRange(a)})}})};function Lue(e){return(e%180+180)%180}var Bue=function(t){var r=t.width,n=t.height,i=arguments.length>1&&arguments[1]!==void 0?arguments[1]:0,a=Lue(i),o=a*Math.PI/180,s=Math.atan(n/r),l=o>s&&o<Math.PI-s?n/Math.sin(o):r/Math.cos(o);return Math.abs(l)},Uue=UW(function(e){return{x:e.left,y:e.top,width:e.width,height:e.height}},function(e){return["l",e.left,"t",e.top,"w",e.width,"h",e.height].join("")}),a2=O.createContext(void 0),o2=O.createContext(void 0),s2=O.createContext(void 0),Fue=O.createContext({}),l2=O.createContext(void 0),u2=O.createContext(0),c2=O.createContext(0),uk=function(t){var r=t.state,n=r.xAxisMap,i=r.yAxisMap,a=r.offset,o=t.clipPathId,s=t.children,l=t.width,u=t.height,d=Uue(a);return j.createElement(a2.Provider,{value:n},j.createElement(o2.Provider,{value:i},j.createElement(Fue.Provider,{value:a},j.createElement(s2.Provider,{value:d},j.createElement(l2.Provider,{value:o},j.createElement(u2.Provider,{value:u},j.createElement(c2.Provider,{value:l},s)))))))},zue=function(){return O.useContext(l2)},d2=function(t){var r=O.useContext(a2);r==null&&Xa();var n=r[t];return n==null&&Xa(),n},f2=function(t){var r=O.useContext(o2);r==null&&Xa();var n=r[t];return n==null&&Xa(),n},Wue=function(){var t=O.useContext(s2);return t},h2=function(){return O.useContext(c2)},p2=function(){return O.useContext(u2)};function Rs(e){"@babel/helpers - typeof";return Rs=typeof Symbol=="function"&&typeof Symbol.iterator=="symbol"?function(t){return typeof t}:function(t){return t&&typeof Symbol=="function"&&t.constructor===Symbol&&t!==Symbol.prototype?"symbol":typeof t},Rs(e)}function que(e,t){if(!(e instanceof t))throw new TypeError("Cannot call a class as a function")}function Hue(e,t){for(var r=0;r<t.length;r++){var n=t[r];n.enumerable=n.enumerable||!1,n.configurable=!0,"value"in n&&(n.writable=!0),Object.defineProperty(e,v2(n.key),n)}}function Vue(e,t,r){return t&&Hue(e.prototype,t),Object.defineProperty(e,"prototype",{writable:!1}),e}function Kue(e,t,r){return t=_h(t),Gue(e,m2()?Reflect.construct(t,r||[],_h(e).constructor):t.apply(e,r))}function Gue(e,t){if(t&&(Rs(t)==="object"||typeof t=="function"))return t;if(t!==void 0)throw new TypeError("Derived constructors may only return object or undefined");return Yue(e)}function Yue(e){if(e===void 0)throw new ReferenceError("this hasn't been initialised - super() hasn't been called");return e}function m2(){try{var e=!Boolean.prototype.valueOf.call(Reflect.construct(Boolean,[],function(){}))}catch{}return(m2=function(){return!!e})()}function _h(e){return _h=Object.setPrototypeOf?Object.getPrototypeOf.bind():function(r){return r.__proto__||Object.getPrototypeOf(r)},_h(e)}function Xue(e,t){if(typeof t!="function"&&t!==null)throw new TypeError("Super expression must either be null or a function");e.prototype=Object.create(t&&t.prototype,{constructor:{value:e,writable:!0,configurable:!0}}),Object.defineProperty(e,"prototype",{writable:!1}),t&&f0(e,t)}function f0(e,t){return f0=Object.setPrototypeOf?Object.setPrototypeOf.bind():function(n,i){return n.__proto__=i,n},f0(e,t)}function ck(e,t){var r=Object.keys(e);if(Object.getOwnPropertySymbols){var n=Object.getOwnPropertySymbols(e);t&&(n=n.filter(function(i){return Object.getOwnPropertyDescriptor(e,i).enumerable})),r.push.apply(r,n)}return r}function dk(e){for(var t=1;t<arguments.length;t++){var r=arguments[t]!=null?arguments[t]:{};t%2?ck(Object(r),!0).forEach(function(n){Qw(e,n,r[n])}):Object.getOwnPropertyDescriptors?Object.defineProperties(e,Object.getOwnPropertyDescriptors(r)):ck(Object(r)).forEach(function(n){Object.defineProperty(e,n,Object.getOwnPropertyDescriptor(r,n))})}return e}function Qw(e,t,r){return t=v2(t),t in e?Object.defineProperty(e,t,{value:r,enumerable:!0,configurable:!0,writable:!0}):e[t]=r,e}function v2(e){var t=Que(e,"string");return Rs(t)=="symbol"?t:t+""}function Que(e,t){if(Rs(e)!="object"||!e)return e;var r=e[Symbol.toPrimitive];if(r!==void 0){var n=r.call(e,t||"default");if(Rs(n)!="object")return n;throw new TypeError("@@toPrimitive must return a primitive value.")}return(t==="string"?String:Number)(e)}function Jue(e,t){return rce(e)||tce(e,t)||ece(e,t)||Zue()}function Zue(){throw new TypeError(`Invalid attempt to destructure non-iterable instance. 354In order to be iterable, non-array objects must have a [Symbol.iterator]() method.`)}function ece(e,t){if(e){if(typeof e=="string")return fk(e,t);var r=Object.prototype.toString.call(e).slice(8,-1);if(r==="Object"&&e.constructor&&(r=e.constructor.name),r==="Map"||r==="Set")return Array.from(e);if(r==="Arguments"||/^(?:Ui|I)nt(?:8|16|32)(?:Clamped)?Array$/.test(r))return fk(e,t)}}function fk(e,t){(t==null||t>e.length)&&(t=e.length);for(var r=0,n=new Array(t);r<t;r++)n[r]=e[r];return n}function tce(e,t){var r=e==null?null:typeof Symbol<"u"&&e[Symbol.iterator]||e["@@iterator"];if(r!=null){var n,i,a,o,s=[],l=!0,u=!1;try{if(a=(r=r.call(e)).next,t!==0)for(;!(l=(n=a.call(r)).done)&&(s.push(n.value),s.length!==t);l=!0);}catch(d){u=!0,i=d}finally{try{if(!l&&r.return!=null&&(o=r.return(),Object(o)!==o))return}finally{if(u)throw i}}return s}}function rce(e){if(Array.isArray(e))return e}function h0(){return h0=Object.assign?Object.assign.bind():function(e){for(var t=1;t<arguments.length;t++){var r=arguments[t];for(var n in r)Object.prototype.hasOwnProperty.call(r,n)&&(e[n]=r[n])}return e},h0.apply(this,arguments)}var nce=function(t,r){var n;return j.isValidElement(t)?n=j.cloneElement(t,r):fe(t)?n=t(r):n=j.createElement("line",h0({},r,{className:"recharts-reference-line-line"})),n},ice=function(t,r,n,i,a,o,s,l,u){var d=a.x,c=a.y,f=a.width,h=a.height;if(n){var v=u.y,m=t.y.apply(v,{position:o});if(En(u,"discard")&&!t.y.isInRange(m))return null;var g=[{x:d+f,y:m},{x:d,y:m}];return l==="left"?g.reverse():g}if(r){var y=u.x,b=t.x.apply(y,{position:o});if(En(u,"discard")&&!t.x.isInRange(b))return null;var w=[{x:b,y:c+h},{x:b,y:c}];return s==="top"?w.reverse():w}if(i){var _=u.segment,x=_.map(function(S){return t.apply(S,{position:o})});return En(u,"discard")&&Kle(x,function(S){return!t.isInRange(S)})?null:x}return null};function ace(e){var t=e.x,r=e.y,n=e.segment,i=e.xAxisId,a=e.yAxisId,o=e.shape,s=e.className,l=e.alwaysShow,u=zue(),d=d2(i),c=f2(a),f=Wue();if(!u||!f)return null;Da(l===void 0,'The alwaysShow prop is deprecated. Please use ifOverflow="extendDomain" instead.');var h=Xw({x:d.scale,y:c.scale}),v=ct(t),m=ct(r),g=n&&n.length===2,y=ice(h,v,m,g,f,e.position,d.orientation,c.orientation,e);if(!y)return null;var b=Jue(y,2),w=b[0],_=w.x,x=w.y,S=b[1],E=S.x,k=S.y,P=En(e,"hidden")?"url(#".concat(u,")"):void 0,C=dk(dk({clipPath:P},Se(e,!0)),{},{x1:_,y1:x,x2:E,y2:k});return j.createElement(gt,{className:pe("recharts-reference-line",s)},nce(o,C),$t.renderCallByParent(e,Due({x1:_,y1:x,x2:E,y2:k})))}var Jw=function(e){function t(){return que(this,t),Kue(this,t,arguments)}return Xue(t,e),Vue(t,[{key:"render",value:function(){return j.createElement(ace,this.props)}}])}(j.Component);Qw(Jw,"displayName","ReferenceLine");Qw(Jw,"defaultProps",{isFront:!1,ifOverflow:"discard",xAxisId:0,yAxisId:0,fill:"none",stroke:"#ccc",fillOpacity:1,strokeWidth:1,position:"middle"});function p0(){return p0=Object.assign?Object.assign.bind():function(e){for(var t=1;t<arguments.length;t++){var r=arguments[t];for(var n in r)Object.prototype.hasOwnProperty.call(r,n)&&(e[n]=r[n])}return e},p0.apply(this,arguments)}function Is(e){"@babel/helpers - typeof";return Is=typeof Symbol=="function"&&typeof Symbol.iterator=="symbol"?function(t){return typeof t}:function(t){return t&&typeof Symbol=="function"&&t.constructor===Symbol&&t!==Symbol.prototype?"symbol":typeof t},Is(e)}function hk(e,t){var r=Object.keys(e);if(Object.getOwnPropertySymbols){var n=Object.getOwnPropertySymbols(e);t&&(n=n.filter(function(i){return Object.getOwnPropertyDescriptor(e,i).enumerable})),r.push.apply(r,n)}return r}function pk(e){for(var t=1;t<arguments.length;t++){var r=arguments[t]!=null?arguments[t]:{};t%2?hk(Object(r),!0).forEach(function(n){Zp(e,n,r[n])}):Object.getOwnPropertyDescriptors?Object.defineProperties(e,Object.getOwnPropertyDescriptors(r)):hk(Object(r)).forEach(function(n){Object.defineProperty(e,n,Object.getOwnPropertyDescriptor(r,n))})}return e}function oce(e,t){if(!(e instanceof t))throw new TypeError("Cannot call a class as a function")}function sce(e,t){for(var r=0;r<t.length;r++){var n=t[r];n.enumerable=n.enumerable||!1,n.configurable=!0,"value"in n&&(n.writable=!0),Object.defineProperty(e,y2(n.key),n)}}function lce(e,t,r){return t&&sce(e.prototype,t),Object.defineProperty(e,"prototype",{writable:!1}),e}function uce(e,t,r){return t=Sh(t),cce(e,g2()?Reflect.construct(t,r||[],Sh(e).constructor):t.apply(e,r))}function cce(e,t){if(t&&(Is(t)==="object"||typeof t=="function"))return t;if(t!==void 0)throw new TypeError("Derived constructors may only return object or undefined");return dce(e)}function dce(e){if(e===void 0)throw new ReferenceError("this hasn't been initialised - super() hasn't been called");return e}function g2(){try{var e=!Boolean.prototype.valueOf.call(Reflect.construct(Boolean,[],function(){}))}catch{}return(g2=function(){return!!e})()}function Sh(e){return Sh=Object.setPrototypeOf?Object.getPrototypeOf.bind():function(r){return r.__proto__||Object.getPrototypeOf(r)},Sh(e)}function fce(e,t){if(typeof t!="function"&&t!==null)throw new TypeError("Super expression must either be null or a function");e.prototype=Object.create(t&&t.prototype,{constructor:{value:e,writable:!0,configurable:!0}}),Object.defineProperty(e,"prototype",{writable:!1}),t&&m0(e,t)}function m0(e,t){return m0=Object.setPrototypeOf?Object.setPrototypeOf.bind():function(n,i){return n.__proto__=i,n},m0(e,t)}function Zp(e,t,r){return t=y2(t),t in e?Object.defineProperty(e,t,{value:r,enumerable:!0,configurable:!0,writable:!0}):e[t]=r,e}function y2(e){var t=hce(e,"string");return Is(t)=="symbol"?t:t+""}function hce(e,t){if(Is(e)!="object"||!e)return e;var r=e[Symbol.toPrimitive];if(r!==void 0){var n=r.call(e,t||"default");if(Is(n)!="object")return n;throw new TypeError("@@toPrimitive must return a primitive value.")}return(t==="string"?String:Number)(e)}var pce=function(t){var r=t.x,n=t.y,i=t.xAxis,a=t.yAxis,o=Xw({x:i.scale,y:a.scale}),s=o.apply({x:r,y:n},{bandAware:!0});return En(t,"discard")&&!o.isInRange(s)?null:s},em=function(e){function t(){return oce(this,t),uce(this,t,arguments)}return fce(t,e),lce(t,[{key:"render",value:function(){var n=this.props,i=n.x,a=n.y,o=n.r,s=n.alwaysShow,l=n.clipPathId,u=ct(i),d=ct(a);if(Da(s===void 0,'The alwaysShow prop is deprecated. Please use ifOverflow="extendDomain" instead.'),!u||!d)return null;var c=pce(this.props);if(!c)return null;var f=c.x,h=c.y,v=this.props,m=v.shape,g=v.className,y=En(this.props,"hidden")?"url(#".concat(l,")"):void 0,b=pk(pk({clipPath:y},Se(this.props,!0)),{},{cx:f,cy:h});return j.createElement(gt,{className:pe("recharts-reference-dot",g)},t.renderDot(m,b),$t.renderCallByParent(this.props,{x:f-o,y:h-o,width:2*o,height:2*o}))}}])}(j.Component);Zp(em,"displayName","ReferenceDot");Zp(em,"defaultProps",{isFront:!1,ifOverflow:"discard",xAxisId:0,yAxisId:0,r:10,fill:"#fff",stroke:"#ccc",fillOpacity:1,strokeWidth:1});Zp(em,"renderDot",function(e,t){var r;return j.isValidElement(e)?r=j.cloneElement(e,t):fe(e)?r=e(t):r=j.createElement(G$,p0({},t,{cx:t.cx,cy:t.cy,className:"recharts-reference-dot-dot"})),r});function v0(){return v0=Object.assign?Object.assign.bind():function(e){for(var t=1;t<arguments.length;t++){var r=arguments[t];for(var n in r)Object.prototype.hasOwnProperty.call(r,n)&&(e[n]=r[n])}return e},v0.apply(this,arguments)}function Ms(e){"@babel/helpers - typeof";return Ms=typeof Symbol=="function"&&typeof Symbol.iterator=="symbol"?function(t){return typeof t}:function(t){return t&&typeof Symbol=="function"&&t.constructor===Symbol&&t!==Symbol.prototype?"symbol":typeof t},Ms(e)}function mk(e,t){var r=Object.keys(e);if(Object.getOwnPropertySymbols){var n=Object.getOwnPropertySymbols(e);t&&(n=n.filter(function(i){return Object.getOwnPropertyDescriptor(e,i).enumerable})),r.push.apply(r,n)}return r}function vk(e){for(var t=1;t<arguments.length;t++){var r=arguments[t]!=null?arguments[t]:{};t%2?mk(Object(r),!0).forEach(function(n){tm(e,n,r[n])}):Object.getOwnPropertyDescriptors?Object.defineProperties(e,Object.getOwnPropertyDescriptors(r)):mk(Object(r)).forEach(function(n){Object.defineProperty(e,n,Object.getOwnPropertyDescriptor(r,n))})}return e}function mce(e,t){if(!(e instanceof t))throw new TypeError("Cannot call a class as a function")}function vce(e,t){for(var r=0;r<t.length;r++){var n=t[r];n.enumerable=n.enumerable||!1,n.configurable=!0,"value"in n&&(n.writable=!0),Object.defineProperty(e,w2(n.key),n)}}function gce(e,t,r){return t&&vce(e.prototype,t),Object.defineProperty(e,"prototype",{writable:!1}),e}function yce(e,t,r){return t=Oh(t),bce(e,b2()?Reflect.construct(t,r||[],Oh(e).constructor):t.apply(e,r))}function bce(e,t){if(t&&(Ms(t)==="object"||typeof t=="function"))return t;if(t!==void 0)throw new TypeError("Derived constructors may only return object or undefined");return wce(e)}function wce(e){if(e===void 0)throw new ReferenceError("this hasn't been initialised - super() hasn't been called");return e}function b2(){try{var e=!Boolean.prototype.valueOf.call(Reflect.construct(Boolean,[],function(){}))}catch{}return(b2=function(){return!!e})()}function Oh(e){return Oh=Object.setPrototypeOf?Object.getPrototypeOf.bind():function(r){return r.__proto__||Object.getPrototypeOf(r)},Oh(e)}function xce(e,t){if(typeof t!="function"&&t!==null)throw new TypeError("Super expression must either be null or a function");e.prototype=Object.create(t&&t.prototype,{constructor:{value:e,writable:!0,configurable:!0}}),Object.defineProperty(e,"prototype",{writable:!1}),t&&g0(e,t)}function g0(e,t){return g0=Object.setPrototypeOf?Object.setPrototypeOf.bind():function(n,i){return n.__proto__=i,n},g0(e,t)}function tm(e,t,r){return t=w2(t),t in e?Object.defineProperty(e,t,{value:r,enumerable:!0,configurable:!0,writable:!0}):e[t]=r,e}function w2(e){var t=_ce(e,"string");return Ms(t)=="symbol"?t:t+""}function _ce(e,t){if(Ms(e)!="object"||!e)return e;var r=e[Symbol.toPrimitive];if(r!==void 0){var n=r.call(e,t||"default");if(Ms(n)!="object")return n;throw new TypeError("@@toPrimitive must return a primitive value.")}return(t==="string"?String:Number)(e)}var Sce=function(t,r,n,i,a){var o=a.x1,s=a.x2,l=a.y1,u=a.y2,d=a.xAxis,c=a.yAxis;if(!d||!c)return null;var f=Xw({x:d.scale,y:c.scale}),h={x:t?f.x.apply(o,{position:"start"}):f.x.rangeMin,y:n?f.y.apply(l,{position:"start"}):f.y.rangeMin},v={x:r?f.x.apply(s,{position:"end"}):f.x.rangeMax,y:i?f.y.apply(u,{position:"end"}):f.y.rangeMax};return En(a,"discard")&&(!f.isInRange(h)||!f.isInRange(v))?null:n2(h,v)},rm=function(e){function t(){return mce(this,t),yce(this,t,arguments)}return xce(t,e),gce(t,[{key:"render",value:function(){var n=this.props,i=n.x1,a=n.x2,o=n.y1,s=n.y2,l=n.className,u=n.alwaysShow,d=n.clipPathId;Da(u===void 0,'The alwaysShow prop is deprecated. Please use ifOverflow="extendDomain" instead.');var c=ct(i),f=ct(a),h=ct(o),v=ct(s),m=this.props.shape;if(!c&&!f&&!h&&!v&&!m)return null;var g=Sce(c,f,h,v,this.props);if(!g&&!m)return null;var y=En(this.props,"hidden")?"url(#".concat(d,")"):void 0;return j.createElement(gt,{className:pe("recharts-reference-area",l)},t.renderRect(m,vk(vk({clipPath:y},Se(this.props,!0)),g)),$t.renderCallByParent(this.props,g))}}])}(j.Component);tm(rm,"displayName","ReferenceArea");tm(rm,"defaultProps",{isFront:!1,ifOverflow:"discard",xAxisId:0,yAxisId:0,r:10,fill:"#ccc",fillOpacity:.5,stroke:"none",strokeWidth:1});tm(rm,"renderRect",function(e,t){var r;return j.isValidElement(e)?r=j.cloneElement(e,t):fe(e)?r=e(t):r=j.createElement(Yw,v0({},t,{className:"recharts-reference-area-rect"})),r});function x2(e,t,r){if(t<1)return[];if(t===1&&r===void 0)return e;for(var n=[],i=0;i<e.length;i+=t)n.push(e[i]);return n}function Oce(e,t,r){var n={width:e.width+t.width,height:e.height+t.height};return Bue(n,r)}function Ece(e,t,r){var n=r==="width",i=e.x,a=e.y,o=e.width,s=e.height;return t===1?{start:n?i:a,end:n?i+o:a+s}:{start:n?i+o:a+s,end:n?i:a}}function Eh(e,t,r,n,i){if(e*t<e*n||e*t>e*i)return!1;var a=r();return e*(t-e*a/2-n)>=0&&e*(t+e*a/2-i)<=0}function kce(e,t){return x2(e,t+1)}function Pce(e,t,r,n,i){for(var a=(n||[]).slice(),o=t.start,s=t.end,l=0,u=1,d=o,c=function(){var v=n==null?void 0:n[l];if(v===void 0)return{v:x2(n,u)};var m=l,g,y=function(){return g===void 0&&(g=r(v,m)),g},b=v.coordinate,w=l===0||Eh(e,b,y,d,s);w||(l=0,d=o,u+=1),w&&(d=b+e*(y()/2+i),l+=u)},f;u<=a.length;)if(f=c(),f)return f.v;return[]}function cc(e){"@babel/helpers - typeof";return cc=typeof Symbol=="function"&&typeof Symbol.iterator=="symbol"?function(t){return typeof t}:function(t){return t&&typeof Symbol=="function"&&t.constructor===Symbol&&t!==Symbol.prototype?"symbol":typeof t},cc(e)}function gk(e,t){var r=Object.keys(e);if(Object.getOwnPropertySymbols){var n=Object.getOwnPropertySymbols(e);t&&(n=n.filter(function(i){return Object.getOwnPropertyDescriptor(e,i).enumerable})),r.push.apply(r,n)}return r}function Ct(e){for(var t=1;t<arguments.length;t++){var r=arguments[t]!=null?arguments[t]:{};t%2?gk(Object(r),!0).forEach(function(n){Ace(e,n,r[n])}):Object.getOwnPropertyDescriptors?Object.defineProperties(e,Object.getOwnPropertyDescriptors(r)):gk(Object(r)).forEach(function(n){Object.defineProperty(e,n,Object.getOwnPropertyDescriptor(r,n))})}return e}function Ace(e,t,r){return t=jce(t),t in e?Object.defineProperty(e,t,{value:r,enumerable:!0,configurable:!0,writable:!0}):e[t]=r,e}function jce(e){var t=Tce(e,"string");return cc(t)=="symbol"?t:t+""}function Tce(e,t){if(cc(e)!="object"||!e)return e;var r=e[Symbol.toPrimitive];if(r!==void 0){var n=r.call(e,t||"default");if(cc(n)!="object")return n;throw new TypeError("@@toPrimitive must return a primitive value.")}return(t==="string"?String:Number)(e)}function Cce(e,t,r,n,i){for(var a=(n||[]).slice(),o=a.length,s=t.start,l=t.end,u=function(f){var h=a[f],v,m=function(){return v===void 0&&(v=r(h,f)),v};if(f===o-1){var g=e*(h.coordinate+e*m()/2-l);a[f]=h=Ct(Ct({},h),{},{tickCoord:g>0?h.coordinate-g*e:h.coordinate})}else a[f]=h=Ct(Ct({},h),{},{tickCoord:h.coordinate});var y=Eh(e,h.tickCoord,m,s,l);y&&(l=h.tickCoord-e*(m()/2+i),a[f]=Ct(Ct({},h),{},{isShow:!0}))},d=o-1;d>=0;d--)u(d);return a}function Nce(e,t,r,n,i,a){var o=(n||[]).slice(),s=o.length,l=t.start,u=t.end;if(a){var d=n[s-1],c=r(d,s-1),f=e*(d.coordinate+e*c/2-u);o[s-1]=d=Ct(Ct({},d),{},{tickCoord:f>0?d.coordinate-f*e:d.coordinate});var h=Eh(e,d.tickCoord,function(){return c},l,u);h&&(u=d.tickCoord-e*(c/2+i),o[s-1]=Ct(Ct({},d),{},{isShow:!0}))}for(var v=a?s-1:s,m=function(b){var w=o[b],_,x=function(){return _===void 0&&(_=r(w,b)),_};if(b===0){var S=e*(w.coordinate-e*x()/2-l);o[b]=w=Ct(Ct({},w),{},{tickCoord:S<0?w.coordinate-S*e:w.coordinate})}else o[b]=w=Ct(Ct({},w),{},{tickCoord:w.coordinate});var E=Eh(e,w.tickCoord,x,l,u);E&&(l=w.tickCoord+e*(x()/2+i),o[b]=Ct(Ct({},w),{},{isShow:!0}))},g=0;g<v;g++)m(g);return o}function $ce(e,t,r){var n=e.tick,i=e.ticks,a=e.viewBox,o=e.minTickGap,s=e.orientation,l=e.interval,u=e.tickFormatter,d=e.unit,c=e.angle;if(!i||!i.length||!n)return[];if(Y(l)||zi.isSsr)return kce(i,typeof l=="number"&&Y(l)?l:0);var f=[],h=s==="top"||s==="bottom"?"width":"height",v=d&&h==="width"?Xl(d,{fontSize:t,letterSpacing:r}):{width:0,height:0},m=function(w,_){var x=fe(u)?u(w.value,_):w.value;return h==="width"?Oce(Xl(x,{fontSize:t,letterSpacing:r}),v,c):Xl(x,{fontSize:t,letterSpacing:r})[h]},g=i.length>=2?Xr(i[1].coordinate-i[0].coordinate):1,y=Ece(a,g,h);return l==="equidistantPreserveStart"?Pce(g,y,m,i,o):(l==="preserveStart"||l==="preserveStartEnd"?f=Nce(g,y,m,i,o,l==="preserveStartEnd"):f=Cce(g,y,m,i,o),f.filter(function(b){return b.isShow}))}var Rce=["viewBox"],Ice=["viewBox"],Mce=["ticks"];function Ds(e){"@babel/helpers - typeof";return Ds=typeof Symbol=="function"&&typeof Symbol.iterator=="symbol"?function(t){return typeof t}:function(t){return t&&typeof Symbol=="function"&&t.constructor===Symbol&&t!==Symbol.prototype?"symbol":typeof t},Ds(e)}function Fo(){return Fo=Object.assign?Object.assign.bind():function(e){for(var t=1;t<arguments.length;t++){var r=arguments[t];for(var n in r)Object.prototype.hasOwnProperty.call(r,n)&&(e[n]=r[n])}return e},Fo.apply(this,arguments)}function yk(e,t){var r=Object.keys(e);if(Object.getOwnPropertySymbols){var n=Object.getOwnPropertySymbols(e);t&&(n=n.filter(function(i){return Object.getOwnPropertyDescriptor(e,i).enumerable})),r.push.apply(r,n)}return r}function at(e){for(var t=1;t<arguments.length;t++){var r=arguments[t]!=null?arguments[t]:{};t%2?yk(Object(r),!0).forEach(function(n){Zw(e,n,r[n])}):Object.getOwnPropertyDescriptors?Object.defineProperties(e,Object.getOwnPropertyDescriptors(r)):yk(Object(r)).forEach(function(n){Object.defineProperty(e,n,Object.getOwnPropertyDescriptor(r,n))})}return e}function Pv(e,t){if(e==null)return{};var r=Dce(e,t),n,i;if(Object.getOwnPropertySymbols){var a=Object.getOwnPropertySymbols(e);for(i=0;i<a.length;i++)n=a[i],!(t.indexOf(n)>=0)&&Object.prototype.propertyIsEnumerable.call(e,n)&&(r[n]=e[n])}return r}function Dce(e,t){if(e==null)return{};var r={};for(var n in e)if(Object.prototype.hasOwnProperty.call(e,n)){if(t.indexOf(n)>=0)continue;r[n]=e[n]}return r}function Lce(e,t){if(!(e instanceof t))throw new TypeError("Cannot call a class as a function")}function bk(e,t){for(var r=0;r<t.length;r++){var n=t[r];n.enumerable=n.enumerable||!1,n.configurable=!0,"value"in n&&(n.writable=!0),Object.defineProperty(e,S2(n.key),n)}}function Bce(e,t,r){return t&&bk(e.prototype,t),r&&bk(e,r),Object.defineProperty(e,"prototype",{writable:!1}),e}function Uce(e,t,r){return t=kh(t),Fce(e,_2()?Reflect.construct(t,r||[],kh(e).constructor):t.apply(e,r))}function Fce(e,t){if(t&&(Ds(t)==="object"||typeof t=="function"))return t;if(t!==void 0)throw new TypeError("Derived constructors may only return object or undefined");return zce(e)}function zce(e){if(e===void 0)throw new ReferenceError("this hasn't been initialised - super() hasn't been called");return e}function _2(){try{var e=!Boolean.prototype.valueOf.call(Reflect.construct(Boolean,[],function(){}))}catch{}return(_2=function(){return!!e})()}function kh(e){return kh=Object.setPrototypeOf?Object.getPrototypeOf.bind():function(r){return r.__proto__||Object.getPrototypeOf(r)},kh(e)}function Wce(e,t){if(typeof t!="function"&&t!==null)throw new TypeError("Super expression must either be null or a function");e.prototype=Object.create(t&&t.prototype,{constructor:{value:e,writable:!0,configurable:!0}}),Object.defineProperty(e,"prototype",{writable:!1}),t&&y0(e,t)}function y0(e,t){return y0=Object.setPrototypeOf?Object.setPrototypeOf.bind():function(n,i){return n.__proto__=i,n},y0(e,t)}function Zw(e,t,r){return t=S2(t),t in e?Object.defineProperty(e,t,{value:r,enumerable:!0,configurable:!0,writable:!0}):e[t]=r,e}function S2(e){var t=qce(e,"string");return Ds(t)=="symbol"?t:t+""}function qce(e,t){if(Ds(e)!="object"||!e)return e;var r=e[Symbol.toPrimitive];if(r!==void 0){var n=r.call(e,t||"default");if(Ds(n)!="object")return n;throw new TypeError("@@toPrimitive must return a primitive value.")}return(t==="string"?String:Number)(e)}var nm=function(e){function t(r){var n;return Lce(this,t),n=Uce(this,t,[r]),n.state={fontSize:"",letterSpacing:""},n}return Wce(t,e),Bce(t,[{key:"shouldComponentUpdate",value:function(n,i){var a=n.viewBox,o=Pv(n,Rce),s=this.props,l=s.viewBox,u=Pv(s,Ice);return!Jo(a,l)||!Jo(o,u)||!Jo(i,this.state)}},{key:"componentDidMount",value:function(){var n=this.layerReference;if(n){var i=n.getElementsByClassName("recharts-cartesian-axis-tick-value")[0];i&&this.setState({fontSize:window.getComputedStyle(i).fontSize,letterSpacing:window.getComputedStyle(i).letterSpacing})}}},{key:"getTickLineCoord",value:function(n){var i=this.props,a=i.x,o=i.y,s=i.width,l=i.height,u=i.orientation,d=i.tickSize,c=i.mirror,f=i.tickMargin,h,v,m,g,y,b,w=c?-1:1,_=n.tickSize||d,x=Y(n.tickCoord)?n.tickCoord:n.coordinate;switch(u){case"top":h=v=n.coordinate,g=o+ +!c*l,m=g-w*_,b=m-w*f,y=x;break;case"left":m=g=n.coordinate,v=a+ +!c*s,h=v-w*_,y=h-w*f,b=x;break;case"right":m=g=n.coordinate,v=a+ +c*s,h=v+w*_,y=h+w*f,b=x;break;default:h=v=n.coordinate,g=o+ +c*l,m=g+w*_,b=m+w*f,y=x;break}return{line:{x1:h,y1:m,x2:v,y2:g},tick:{x:y,y:b}}}},{key:"getTickTextAnchor",value:function(){var n=this.props,i=n.orientation,a=n.mirror,o;switch(i){case"left":o=a?"start":"end";break;case"right":o=a?"end":"start";break;default:o="middle";break}return o}},{key:"getTickVerticalAnchor",value:function(){var n=this.props,i=n.orientation,a=n.mirror,o="end";switch(i){case"left":case"right":o="middle";break;case"top":o=a?"start":"end";break;default:o=a?"end":"start";break}return o}},{key:"renderAxisLine",value:function(){var n=this.props,i=n.x,a=n.y,o=n.width,s=n.height,l=n.orientation,u=n.mirror,d=n.axisLine,c=at(at(at({},Se(this.props,!1)),Se(d,!1)),{},{fill:"none"});if(l==="top"||l==="bottom"){var f=+(l==="top"&&!u||l==="bottom"&&u);c=at(at({},c),{},{x1:i,y1:a+f*s,x2:i+o,y2:a+f*s})}else{var h=+(l==="left"&&!u||l==="right"&&u);c=at(at({},c),{},{x1:i+h*o,y1:a,x2:i+h*o,y2:a+s})}return j.createElement("line",Fo({},c,{className:pe("recharts-cartesian-axis-line",kr(d,"className"))}))}},{key:"renderTicks",value:function(n,i,a){var o=this,s=this.props,l=s.tickLine,u=s.stroke,d=s.tick,c=s.tickFormatter,f=s.unit,h=$ce(at(at({},this.props),{},{ticks:n}),i,a),v=this.getTickTextAnchor(),m=this.getTickVerticalAnchor(),g=Se(this.props,!1),y=Se(d,!1),b=at(at({},g),{},{fill:"none"},Se(l,!1)),w=h.map(function(_,x){var S=o.getTickLineCoord(_),E=S.line,k=S.tick,P=at(at(at(at({textAnchor:v,verticalAnchor:m},g),{},{stroke:"none",fill:u},y),k),{},{index:x,payload:_,visibleTicksCount:h.length,tickFormatter:c});return j.createElement(gt,Fo({className:"recharts-cartesian-axis-tick",key:"tick-".concat(_.value,"-").concat(_.coordinate,"-").concat(_.tickCoord)},$f(o.props,_,x)),l&&j.createElement("line",Fo({},b,E,{className:pe("recharts-cartesian-axis-tick-line",kr(l,"className"))})),d&&t.renderTickItem(d,P,"".concat(fe(c)?c(_.value,x):_.value).concat(f||"")))});return j.createElement("g",{className:"recharts-cartesian-axis-ticks"},w)}},{key:"render",value:function(){var n=this,i=this.props,a=i.axisLine,o=i.width,s=i.height,l=i.ticksGenerator,u=i.className,d=i.hide;if(d)return null;var c=this.props,f=c.ticks,h=Pv(c,Mce),v=f;return fe(l)&&(v=f&&f.length>0?l(this.props):l(h)),o<=0||s<=0||!v||!v.length?null:j.createElement(gt,{className:pe("recharts-cartesian-axis",u),ref:function(g){n.layerReference=g}},a&&this.renderAxisLine(),this.renderTicks(v,this.state.fontSize,this.state.letterSpacing),$t.renderCallByParent(this.props))}}],[{key:"renderTickItem",value:function(n,i,a){var o,s=pe(i.className,"recharts-cartesian-axis-tick-value");return j.isValidElement(n)?o=j.cloneElement(n,at(at({},i),{},{className:s})):fe(n)?o=n(at(at({},i),{},{className:s})):o=j.createElement(Gf,Fo({},i,{className:"recharts-cartesian-axis-tick-value"}),a),o}}])}(O.Component);Zw(nm,"displayName","CartesianAxis");Zw(nm,"defaultProps",{x:0,y:0,width:0,height:0,viewBox:{x:0,y:0,width:0,height:0},orientation:"bottom",ticks:[],stroke:"#666",tickLine:!0,axisLine:!0,tick:!0,mirror:!1,minTickGap:5,tickSize:6,tickMargin:2,interval:"preserveEnd"});function Ls(e){"@babel/helpers - typeof";return Ls=typeof Symbol=="function"&&typeof Symbol.iterator=="symbol"?function(t){return typeof t}:function(t){return t&&typeof Symbol=="function"&&t.constructor===Symbol&&t!==Symbol.prototype?"symbol":typeof t},Ls(e)}function Hce(e,t){if(!(e instanceof t))throw new TypeError("Cannot call a class as a function")}function Vce(e,t){for(var r=0;r<t.length;r++){var n=t[r];n.enumerable=n.enumerable||!1,n.configurable=!0,"value"in n&&(n.writable=!0),Object.defineProperty(e,k2(n.key),n)}}function Kce(e,t,r){return t&&Vce(e.prototype,t),Object.defineProperty(e,"prototype",{writable:!1}),e}function Gce(e,t,r){return t=Ph(t),Yce(e,O2()?Reflect.construct(t,r||[],Ph(e).constructor):t.apply(e,r))}function Yce(e,t){if(t&&(Ls(t)==="object"||typeof t=="function"))return t;if(t!==void 0)throw new TypeError("Derived constructors may only return object or undefined");return Xce(e)}function Xce(e){if(e===void 0)throw new ReferenceError("this hasn't been initialised - super() hasn't been called");return e}function O2(){try{var e=!Boolean.prototype.valueOf.call(Reflect.construct(Boolean,[],function(){}))}catch{}return(O2=function(){return!!e})()}function Ph(e){return Ph=Object.setPrototypeOf?Object.getPrototypeOf.bind():function(r){return r.__proto__||Object.getPrototypeOf(r)},Ph(e)}function Qce(e,t){if(typeof t!="function"&&t!==null)throw new TypeError("Super expression must either be null or a function");e.prototype=Object.create(t&&t.prototype,{constructor:{value:e,writable:!0,configurable:!0}}),Object.defineProperty(e,"prototype",{writable:!1}),t&&b0(e,t)}function b0(e,t){return b0=Object.setPrototypeOf?Object.setPrototypeOf.bind():function(n,i){return n.__proto__=i,n},b0(e,t)}function E2(e,t,r){return t=k2(t),t in e?Object.defineProperty(e,t,{value:r,enumerable:!0,configurable:!0,writable:!0}):e[t]=r,e}function k2(e){var t=Jce(e,"string");return Ls(t)=="symbol"?t:t+""}function Jce(e,t){if(Ls(e)!="object"||!e)return e;var r=e[Symbol.toPrimitive];if(r!==void 0){var n=r.call(e,t||"default");if(Ls(n)!="object")return n;throw new TypeError("@@toPrimitive must return a primitive value.")}return(t==="string"?String:Number)(e)}function w0(){return w0=Object.assign?Object.assign.bind():function(e){for(var t=1;t<arguments.length;t++){var r=arguments[t];for(var n in r)Object.prototype.hasOwnProperty.call(r,n)&&(e[n]=r[n])}return e},w0.apply(this,arguments)}function Zce(e){var t=e.xAxisId,r=h2(),n=p2(),i=d2(t);return i==null?null:O.createElement(nm,w0({},i,{className:pe("recharts-".concat(i.axisType," ").concat(i.axisType),i.className),viewBox:{x:0,y:0,width:r,height:n},ticksGenerator:function(o){return ka(o,!0)}}))}var im=function(e){function t(){return Hce(this,t),Gce(this,t,arguments)}return Qce(t,e),Kce(t,[{key:"render",value:function(){return O.createElement(Zce,this.props)}}])}(O.Component);E2(im,"displayName","XAxis");E2(im,"defaultProps",{allowDecimals:!0,hide:!1,orientation:"bottom",width:0,height:30,mirror:!1,xAxisId:0,tickCount:5,type:"category",padding:{left:0,right:0},allowDataOverflow:!1,scale:"auto",reversed:!1,allowDuplicatedCategory:!0});function Bs(e){"@babel/helpers - typeof";return Bs=typeof Symbol=="function"&&typeof Symbol.iterator=="symbol"?function(t){return typeof t}:function(t){return t&&typeof Symbol=="function"&&t.constructor===Symbol&&t!==Symbol.prototype?"symbol":typeof t},Bs(e)}function ede(e,t){if(!(e instanceof t))throw new TypeError("Cannot call a class as a function")}function tde(e,t){for(var r=0;r<t.length;r++){var n=t[r];n.enumerable=n.enumerable||!1,n.configurable=!0,"value"in n&&(n.writable=!0),Object.defineProperty(e,j2(n.key),n)}}function rde(e,t,r){return t&&tde(e.prototype,t),Object.defineProperty(e,"prototype",{writable:!1}),e}function nde(e,t,r){return t=Ah(t),ide(e,P2()?Reflect.construct(t,r||[],Ah(e).constructor):t.apply(e,r))}function ide(e,t){if(t&&(Bs(t)==="object"||typeof t=="function"))return t;if(t!==void 0)throw new TypeError("Derived constructors may only return object or undefined");return ade(e)}function ade(e){if(e===void 0)throw new ReferenceError("this hasn't been initialised - super() hasn't been called");return e}function P2(){try{var e=!Boolean.prototype.valueOf.call(Reflect.construct(Boolean,[],function(){}))}catch{}return(P2=function(){return!!e})()}function Ah(e){return Ah=Object.setPrototypeOf?Object.getPrototypeOf.bind():function(r){return r.__proto__||Object.getPrototypeOf(r)},Ah(e)}function ode(e,t){if(typeof t!="function"&&t!==null)throw new TypeError("Super expression must either be null or a function");e.prototype=Object.create(t&&t.prototype,{constructor:{value:e,writable:!0,configurable:!0}}),Object.defineProperty(e,"prototype",{writable:!1}),t&&x0(e,t)}function x0(e,t){return x0=Object.setPrototypeOf?Object.setPrototypeOf.bind():function(n,i){return n.__proto__=i,n},x0(e,t)}function A2(e,t,r){return t=j2(t),t in e?Object.defineProperty(e,t,{value:r,enumerable:!0,configurable:!0,writable:!0}):e[t]=r,e}function j2(e){var t=sde(e,"string");return Bs(t)=="symbol"?t:t+""}function sde(e,t){if(Bs(e)!="object"||!e)return e;var r=e[Symbol.toPrimitive];if(r!==void 0){var n=r.call(e,t||"default");if(Bs(n)!="object")return n;throw new TypeError("@@toPrimitive must return a primitive value.")}return(t==="string"?String:Number)(e)}function _0(){return _0=Object.assign?Object.assign.bind():function(e){for(var t=1;t<arguments.length;t++){var r=arguments[t];for(var n in r)Object.prototype.hasOwnProperty.call(r,n)&&(e[n]=r[n])}return e},_0.apply(this,arguments)}var lde=function(t){var r=t.yAxisId,n=h2(),i=p2(),a=f2(r);return a==null?null:O.createElement(nm,_0({},a,{className:pe("recharts-".concat(a.axisType," ").concat(a.axisType),a.className),viewBox:{x:0,y:0,width:n,height:i},ticksGenerator:function(s){return ka(s,!0)}}))},am=function(e){function t(){return ede(this,t),nde(this,t,arguments)}return ode(t,e),rde(t,[{key:"render",value:function(){return O.createElement(lde,this.props)}}])}(O.Component);A2(am,"displayName","YAxis");A2(am,"defaultProps",{allowDuplicatedCategory:!0,allowDecimals:!0,hide:!1,orientation:"left",width:60,height:0,mirror:!1,yAxisId:0,tickCount:5,type:"number",padding:{top:0,bottom:0},allowDataOverflow:!1,scale:"auto",reversed:!1});function wk(e){return fde(e)||dde(e)||cde(e)||ude()}function ude(){throw new TypeError(`Invalid attempt to spread non-iterable instance. 355In order to be iterable, non-array objects must have a [Symbol.iterator]() method.`)}function cde(e,t){if(e){if(typeof e=="string")return S0(e,t);var r=Object.prototype.toString.call(e).slice(8,-1);if(r==="Object"&&e.constructor&&(r=e.constructor.name),r==="Map"||r==="Set")return Array.from(e);if(r==="Arguments"||/^(?:Ui|I)nt(?:8|16|32)(?:Clamped)?Array$/.test(r))return S0(e,t)}}function dde(e){if(typeof Symbol<"u"&&e[Symbol.iterator]!=null||e["@@iterator"]!=null)return Array.from(e)}function fde(e){if(Array.isArray(e))return S0(e)}function S0(e,t){(t==null||t>e.length)&&(t=e.length);for(var r=0,n=new Array(t);r<t;r++)n[r]=e[r];return n}var O0=function(t,r,n,i,a){var o=tn(t,Jw),s=tn(t,em),l=[].concat(wk(o),wk(s)),u=tn(t,rm),d="".concat(i,"Id"),c=i[0],f=r;if(l.length&&(f=l.reduce(function(m,g){if(g.props[d]===n&&En(g.props,"extendDomain")&&Y(g.props[c])){var y=g.props[c];return[Math.min(m[0],y),Math.max(m[1],y)]}return m},f)),u.length){var h="".concat(c,"1"),v="".concat(c,"2");f=u.reduce(function(m,g){if(g.props[d]===n&&En(g.props,"extendDomain")&&Y(g.props[h])&&Y(g.props[v])){var y=g.props[h],b=g.props[v];return[Math.min(m[0],y,b),Math.max(m[1],y,b)]}return m},f)}return a&&a.length&&(f=a.reduce(function(m,g){return Y(g)?[Math.min(m[0],g),Math.max(m[1],g)]:m},f)),f},T2={exports:{}};(function(e){var t=Object.prototype.hasOwnProperty,r="~";function n(){}Object.create&&(n.prototype=Object.create(null),new n().__proto__||(r=!1));function i(l,u,d){this.fn=l,this.context=u,this.once=d||!1}function a(l,u,d,c,f){if(typeof d!="function")throw new TypeError("The listener must be a function");var h=new i(d,c||l,f),v=r?r+u:u;return l._events[v]?l._events[v].fn?l._events[v]=[l._events[v],h]:l._events[v].push(h):(l._events[v]=h,l._eventsCount++),l}function o(l,u){--l._eventsCount===0?l._events=new n:delete l._events[u]}function s(){this._events=new n,this._eventsCount=0}s.prototype.eventNames=function(){var u=[],d,c;if(this._eventsCount===0)return u;for(c in d=this._events)t.call(d,c)&&u.push(r?c.slice(1):c);return Object.getOwnPropertySymbols?u.concat(Object.getOwnPropertySymbols(d)):u},s.prototype.listeners=function(u){var d=r?r+u:u,c=this._events[d];if(!c)return[];if(c.fn)return[c.fn];for(var f=0,h=c.length,v=new Array(h);f<h;f++)v[f]=c[f].fn;return v},s.prototype.listenerCount=function(u){var d=r?r+u:u,c=this._events[d];return c?c.fn?1:c.length:0},s.prototype.emit=function(u,d,c,f,h,v){var m=r?r+u:u;if(!this._events[m])return!1;var g=this._events[m],y=arguments.length,b,w;if(g.fn){switch(g.once&&this.removeListener(u,g.fn,void 0,!0),y){case 1:return g.fn.call(g.context),!0;case 2:return g.fn.call(g.context,d),!0;case 3:return g.fn.call(g.context,d,c),!0;case 4:return g.fn.call(g.context,d,c,f),!0;case 5:return g.fn.call(g.context,d,c,f,h),!0;case 6:return g.fn.call(g.context,d,c,f,h,v),!0}for(w=1,b=new Array(y-1);w<y;w++)b[w-1]=arguments[w];g.fn.apply(g.context,b)}else{var _=g.length,x;for(w=0;w<_;w++)switch(g[w].once&&this.removeListener(u,g[w].fn,void 0,!0),y){case 1:g[w].fn.call(g[w].context);break;case 2:g[w].fn.call(g[w].context,d);break;case 3:g[w].fn.call(g[w].context,d,c);break;case 4:g[w].fn.call(g[w].context,d,c,f);break;default:if(!b)for(x=1,b=new Array(y-1);x<y;x++)b[x-1]=arguments[x];g[w].fn.apply(g[w].context,b)}}return!0},s.prototype.on=function(u,d,c){return a(this,u,d,c,!1)},s.prototype.once=function(u,d,c){return a(this,u,d,c,!0)},s.prototype.removeListener=function(u,d,c,f){var h=r?r+u:u;if(!this._events[h])return this;if(!d)return o(this,h),this;var v=this._events[h];if(v.fn)v.fn===d&&(!f||v.once)&&(!c||v.context===c)&&o(this,h);else{for(var m=0,g=[],y=v.length;m<y;m++)(v[m].fn!==d||f&&!v[m].once||c&&v[m].context!==c)&&g.push(v[m]);g.length?this._events[h]=g.length===1?g[0]:g:o(this,h)}return this},s.prototype.removeAllListeners=function(u){var d;return u?(d=r?r+u:u,this._events[d]&&o(this,d)):(this._events=new n,this._eventsCount=0),this},s.prototype.off=s.prototype.removeListener,s.prototype.addListener=s.prototype.on,s.prefixed=r,s.EventEmitter=s,e.exports=s})(T2);var hde=T2.exports;const pde=Ce(hde);var Av=new pde,jv="recharts.syncMouseEvents";function dc(e){"@babel/helpers - typeof";return dc=typeof Symbol=="function"&&typeof Symbol.iterator=="symbol"?function(t){return typeof t}:function(t){return t&&typeof Symbol=="function"&&t.constructor===Symbol&&t!==Symbol.prototype?"symbol":typeof t},dc(e)}function mde(e,t){if(!(e instanceof t))throw new TypeError("Cannot call a class as a function")}function vde(e,t){for(var r=0;r<t.length;r++){var n=t[r];n.enumerable=n.enumerable||!1,n.configurable=!0,"value"in n&&(n.writable=!0),Object.defineProperty(e,C2(n.key),n)}}function gde(e,t,r){return t&&vde(e.prototype,t),Object.defineProperty(e,"prototype",{writable:!1}),e}function Tv(e,t,r){return t=C2(t),t in e?Object.defineProperty(e,t,{value:r,enumerable:!0,configurable:!0,writable:!0}):e[t]=r,e}function C2(e){var t=yde(e,"string");return dc(t)=="symbol"?t:t+""}function yde(e,t){if(dc(e)!="object"||!e)return e;var r=e[Symbol.toPrimitive];if(r!==void 0){var n=r.call(e,t);if(dc(n)!="object")return n;throw new TypeError("@@toPrimitive must return a primitive value.")}return String(e)}var bde=function(){function e(){mde(this,e),Tv(this,"activeIndex",0),Tv(this,"coordinateList",[]),Tv(this,"layout","horizontal")}return gde(e,[{key:"setDetails",value:function(r){var n,i=r.coordinateList,a=i===void 0?null:i,o=r.container,s=o===void 0?null:o,l=r.layout,u=l===void 0?null:l,d=r.offset,c=d===void 0?null:d,f=r.mouseHandlerCallback,h=f===void 0?null:f;this.coordinateList=(n=a??this.coordinateList)!==null&&n!==void 0?n:[],this.container=s??this.container,this.layout=u??this.layout,this.offset=c??this.offset,this.mouseHandlerCallback=h??this.mouseHandlerCallback,this.activeIndex=Math.min(Math.max(this.activeIndex,0),this.coordinateList.length-1)}},{key:"focus",value:function(){this.spoofMouse()}},{key:"keyboardEvent",value:function(r){if(this.coordinateList.length!==0)switch(r.key){case"ArrowRight":{if(this.layout!=="horizontal")return;this.activeIndex=Math.min(this.activeIndex+1,this.coordinateList.length-1),this.spoofMouse();break}case"ArrowLeft":{if(this.layout!=="horizontal")return;this.activeIndex=Math.max(this.activeIndex-1,0),this.spoofMouse();break}}}},{key:"setIndex",value:function(r){this.activeIndex=r}},{key:"spoofMouse",value:function(){var r,n;if(this.layout==="horizontal"&&this.coordinateList.length!==0){var i=this.container.getBoundingClientRect(),a=i.x,o=i.y,s=i.height,l=this.coordinateList[this.activeIndex].coordinate,u=((r=window)===null||r===void 0?void 0:r.scrollX)||0,d=((n=window)===null||n===void 0?void 0:n.scrollY)||0,c=a+l+u,f=o+this.offset.top+s/2+d;this.mouseHandlerCallback({pageX:c,pageY:f})}}}])}();function wde(e,t,r){if(r==="number"&&t===!0&&Array.isArray(e)){var n=e==null?void 0:e[0],i=e==null?void 0:e[1];if(n&&i&&Y(n)&&Y(i))return!0}return!1}function xde(e,t,r,n){var i=n/2;return{stroke:"none",fill:"#ccc",x:e==="horizontal"?t.x-i:r.left+.5,y:e==="horizontal"?r.top+.5:t.y-i,width:e==="horizontal"?n:r.width-1,height:e==="horizontal"?r.height-1:n}}function N2(e){var t=e.cx,r=e.cy,n=e.radius,i=e.startAngle,a=e.endAngle,o=Ot(t,r,n,i),s=Ot(t,r,n,a);return{points:[o,s],cx:t,cy:r,radius:n,startAngle:i,endAngle:a}}function _de(e,t,r){var n,i,a,o;if(e==="horizontal")n=t.x,a=n,i=r.top,o=r.top+r.height;else if(e==="vertical")i=t.y,o=i,n=r.left,a=r.left+r.width;else if(t.cx!=null&&t.cy!=null)if(e==="centric"){var s=t.cx,l=t.cy,u=t.innerRadius,d=t.outerRadius,c=t.angle,f=Ot(s,l,u,c),h=Ot(s,l,d,c);n=f.x,i=f.y,a=h.x,o=h.y}else return N2(t);return[{x:n,y:i},{x:a,y:o}]}function fc(e){"@babel/helpers - typeof";return fc=typeof Symbol=="function"&&typeof Symbol.iterator=="symbol"?function(t){return typeof t}:function(t){return t&&typeof Symbol=="function"&&t.constructor===Symbol&&t!==Symbol.prototype?"symbol":typeof t},fc(e)}function xk(e,t){var r=Object.keys(e);if(Object.getOwnPropertySymbols){var n=Object.getOwnPropertySymbols(e);t&&(n=n.filter(function(i){return Object.getOwnPropertyDescriptor(e,i).enumerable})),r.push.apply(r,n)}return r}function kd(e){for(var t=1;t<arguments.length;t++){var r=arguments[t]!=null?arguments[t]:{};t%2?xk(Object(r),!0).forEach(function(n){Sde(e,n,r[n])}):Object.getOwnPropertyDescriptors?Object.defineProperties(e,Object.getOwnPropertyDescriptors(r)):xk(Object(r)).forEach(function(n){Object.defineProperty(e,n,Object.getOwnPropertyDescriptor(r,n))})}return e}function Sde(e,t,r){return t=Ode(t),t in e?Object.defineProperty(e,t,{value:r,enumerable:!0,configurable:!0,writable:!0}):e[t]=r,e}function Ode(e){var t=Ede(e,"string");return fc(t)=="symbol"?t:t+""}function Ede(e,t){if(fc(e)!="object"||!e)return e;var r=e[Symbol.toPrimitive];if(r!==void 0){var n=r.call(e,t||"default");if(fc(n)!="object")return n;throw new TypeError("@@toPrimitive must return a primitive value.")}return(t==="string"?String:Number)(e)}function kde(e){var t,r,n=e.element,i=e.tooltipEventType,a=e.isActive,o=e.activeCoordinate,s=e.activePayload,l=e.offset,u=e.activeTooltipIndex,d=e.tooltipAxisBandSize,c=e.layout,f=e.chartName,h=(t=n.props.cursor)!==null&&t!==void 0?t:(r=n.type.defaultProps)===null||r===void 0?void 0:r.cursor;if(!n||!h||!a||!o||f!=="ScatterChart"&&i!=="axis")return null;var v,m=wE;if(f==="ScatterChart")v=o,m=vse;else if(f==="BarChart")v=xde(c,o,l,d),m=Yw;else if(c==="radial"){var g=N2(o),y=g.cx,b=g.cy,w=g.radius,_=g.startAngle,x=g.endAngle;v={cx:y,cy:b,startAngle:_,endAngle:x,innerRadius:w,outerRadius:w},m=D$}else v={points:_de(c,o,l)},m=wE;var S=kd(kd(kd(kd({stroke:"#ccc",pointerEvents:"none"},l),v),Se(h,!1)),{},{payload:s,payloadIndex:u,className:pe("recharts-tooltip-cursor",h.className)});return O.isValidElement(h)?O.cloneElement(h,S):O.createElement(m,S)}var Pde=["item"],Ade=["children","className","width","height","style","compact","title","desc"];function Us(e){"@babel/helpers - typeof";return Us=typeof Symbol=="function"&&typeof Symbol.iterator=="symbol"?function(t){return typeof t}:function(t){return t&&typeof Symbol=="function"&&t.constructor===Symbol&&t!==Symbol.prototype?"symbol":typeof t},Us(e)}function zo(){return zo=Object.assign?Object.assign.bind():function(e){for(var t=1;t<arguments.length;t++){var r=arguments[t];for(var n in r)Object.prototype.hasOwnProperty.call(r,n)&&(e[n]=r[n])}return e},zo.apply(this,arguments)}function _k(e,t){return Cde(e)||Tde(e,t)||R2(e,t)||jde()}function jde(){throw new TypeError(`Invalid attempt to destructure non-iterable instance. 356In order to be iterable, non-array objects must have a [Symbol.iterator]() method.`)}function Tde(e,t){var r=e==null?null:typeof Symbol<"u"&&e[Symbol.iterator]||e["@@iterator"];if(r!=null){var n,i,a,o,s=[],l=!0,u=!1;try{if(a=(r=r.call(e)).next,t!==0)for(;!(l=(n=a.call(r)).done)&&(s.push(n.value),s.length!==t);l=!0);}catch(d){u=!0,i=d}finally{try{if(!l&&r.return!=null&&(o=r.return(),Object(o)!==o))return}finally{if(u)throw i}}return s}}function Cde(e){if(Array.isArray(e))return e}function Sk(e,t){if(e==null)return{};var r=Nde(e,t),n,i;if(Object.getOwnPropertySymbols){var a=Object.getOwnPropertySymbols(e);for(i=0;i<a.length;i++)n=a[i],!(t.indexOf(n)>=0)&&Object.prototype.propertyIsEnumerable.call(e,n)&&(r[n]=e[n])}return r}function Nde(e,t){if(e==null)return{};var r={};for(var n in e)if(Object.prototype.hasOwnProperty.call(e,n)){if(t.indexOf(n)>=0)continue;r[n]=e[n]}return r}function $de(e,t){if(!(e instanceof t))throw new TypeError("Cannot call a class as a function")}function Rde(e,t){for(var r=0;r<t.length;r++){var n=t[r];n.enumerable=n.enumerable||!1,n.configurable=!0,"value"in n&&(n.writable=!0),Object.defineProperty(e,I2(n.key),n)}}function Ide(e,t,r){return t&&Rde(e.prototype,t),Object.defineProperty(e,"prototype",{writable:!1}),e}function Mde(e,t,r){return t=jh(t),Dde(e,$2()?Reflect.construct(t,r||[],jh(e).constructor):t.apply(e,r))}function Dde(e,t){if(t&&(Us(t)==="object"||typeof t=="function"))return t;if(t!==void 0)throw new TypeError("Derived constructors may only return object or undefined");return Lde(e)}function Lde(e){if(e===void 0)throw new ReferenceError("this hasn't been initialised - super() hasn't been called");return e}function $2(){try{var e=!Boolean.prototype.valueOf.call(Reflect.construct(Boolean,[],function(){}))}catch{}return($2=function(){return!!e})()}function jh(e){return jh=Object.setPrototypeOf?Object.getPrototypeOf.bind():function(r){return r.__proto__||Object.getPrototypeOf(r)},jh(e)}function Bde(e,t){if(typeof t!="function"&&t!==null)throw new TypeError("Super expression must either be null or a function");e.prototype=Object.create(t&&t.prototype,{constructor:{value:e,writable:!0,configurable:!0}}),Object.defineProperty(e,"prototype",{writable:!1}),t&&E0(e,t)}function E0(e,t){return E0=Object.setPrototypeOf?Object.setPrototypeOf.bind():function(n,i){return n.__proto__=i,n},E0(e,t)}function Fs(e){return zde(e)||Fde(e)||R2(e)||Ude()}function Ude(){throw new TypeError(`Invalid attempt to spread non-iterable instance. 357In order to be iterable, non-array objects must have a [Symbol.iterator]() method.`)}function R2(e,t){if(e){if(typeof e=="string")return k0(e,t);var r=Object.prototype.toString.call(e).slice(8,-1);if(r==="Object"&&e.constructor&&(r=e.constructor.name),r==="Map"||r==="Set")return Array.from(e);if(r==="Arguments"||/^(?:Ui|I)nt(?:8|16|32)(?:Clamped)?Array$/.test(r))return k0(e,t)}}function Fde(e){if(typeof Symbol<"u"&&e[Symbol.iterator]!=null||e["@@iterator"]!=null)return Array.from(e)}function zde(e){if(Array.isArray(e))return k0(e)}function k0(e,t){(t==null||t>e.length)&&(t=e.length);for(var r=0,n=new Array(t);r<t;r++)n[r]=e[r];return n}function Ok(e,t){var r=Object.keys(e);if(Object.getOwnPropertySymbols){var n=Object.getOwnPropertySymbols(e);t&&(n=n.filter(function(i){return Object.getOwnPropertyDescriptor(e,i).enumerable})),r.push.apply(r,n)}return r}function F(e){for(var t=1;t<arguments.length;t++){var r=arguments[t]!=null?arguments[t]:{};t%2?Ok(Object(r),!0).forEach(function(n){re(e,n,r[n])}):Object.getOwnPropertyDescriptors?Object.defineProperties(e,Object.getOwnPropertyDescriptors(r)):Ok(Object(r)).forEach(function(n){Object.defineProperty(e,n,Object.getOwnPropertyDescriptor(r,n))})}return e}function re(e,t,r){return t=I2(t),t in e?Object.defineProperty(e,t,{value:r,enumerable:!0,configurable:!0,writable:!0}):e[t]=r,e}function I2(e){var t=Wde(e,"string");return Us(t)=="symbol"?t:t+""}function Wde(e,t){if(Us(e)!="object"||!e)return e;var r=e[Symbol.toPrimitive];if(r!==void 0){var n=r.call(e,t||"default");if(Us(n)!="object")return n;throw new TypeError("@@toPrimitive must return a primitive value.")}return(t==="string"?String:Number)(e)}var qde={xAxis:["bottom","top"],yAxis:["left","right"]},Hde={width:"100%",height:"100%"},M2={x:0,y:0};function Pd(e){return e}var Vde=function(t,r){return r==="horizontal"?t.x:r==="vertical"?t.y:r==="centric"?t.angle:t.radius},Kde=function(t,r,n,i){var a=r.find(function(d){return d&&d.index===n});if(a){if(t==="horizontal")return{x:a.coordinate,y:i.y};if(t==="vertical")return{x:i.x,y:a.coordinate};if(t==="centric"){var o=a.coordinate,s=i.radius;return F(F(F({},i),Ot(i.cx,i.cy,s,o)),{},{angle:o,radius:s})}var l=a.coordinate,u=i.angle;return F(F(F({},i),Ot(i.cx,i.cy,l,u)),{},{angle:u,radius:l})}return M2},om=function(t,r){var n=r.graphicalItems,i=r.dataStartIndex,a=r.dataEndIndex,o=(n??[]).reduce(function(s,l){var u=l.props.data;return u&&u.length?[].concat(Fs(s),Fs(u)):s},[]);return o.length>0?o:t&&t.length&&Y(i)&&Y(a)?t.slice(i,a+1):[]};function D2(e){return e==="number"?[0,"auto"]:void 0}var P0=function(t,r,n,i){var a=t.graphicalItems,o=t.tooltipAxis,s=om(r,t);return n<0||!a||!a.length||n>=s.length?null:a.reduce(function(l,u){var d,c=(d=u.props.data)!==null&&d!==void 0?d:r;c&&t.dataStartIndex+t.dataEndIndex!==0&&t.dataEndIndex-t.dataStartIndex>=n&&(c=c.slice(t.dataStartIndex,t.dataEndIndex+1));var f;if(o.dataKey&&!o.allowDuplicatedCategory){var h=c===void 0?s:c;f=oy(h,o.dataKey,i)}else f=c&&c[n]||s[n];return f?[].concat(Fs(l),[R$(u,f)]):l},[])},Ek=function(t,r,n,i){var a=i||{x:t.chartX,y:t.chartY},o=Vde(a,n),s=t.orderedTooltipTicks,l=t.tooltipAxis,u=t.tooltipTicks,d=Jne(o,s,u,l);if(d>=0&&u){var c=u[d]&&u[d].value,f=P0(t,r,d,c),h=Kde(n,s,d,a);return{activeTooltipIndex:d,activeLabel:c,activePayload:f,activeCoordinate:h}}return null},Gde=function(t,r){var n=r.axes,i=r.graphicalItems,a=r.axisType,o=r.axisIdKey,s=r.stackGroups,l=r.dataStartIndex,u=r.dataEndIndex,d=t.layout,c=t.children,f=t.stackOffset,h=N$(d,a);return n.reduce(function(v,m){var g,y=m.type.defaultProps!==void 0?F(F({},m.type.defaultProps),m.props):m.props,b=y.type,w=y.dataKey,_=y.allowDataOverflow,x=y.allowDuplicatedCategory,S=y.scale,E=y.ticks,k=y.includeHidden,P=y[o];if(v[P])return v;var C=om(t.data,{graphicalItems:i.filter(function(B){var W,K=o in B.props?B.props[o]:(W=B.type.defaultProps)===null||W===void 0?void 0:W[o];return K===P}),dataStartIndex:l,dataEndIndex:u}),N=C.length,$,D,I;wde(y.domain,_,b)&&($=Ky(y.domain,null,_),h&&(b==="number"||S!=="auto")&&(I=Jl(C,w,"category")));var R=D2(b);if(!$||$.length===0){var M,L=(M=y.domain)!==null&&M!==void 0?M:R;if(w){if($=Jl(C,w,b),b==="category"&&h){var A=Lq($);x&&A?(D=$,$=gh(0,N)):x||($=sE(L,$,m).reduce(function(B,W){return B.indexOf(W)>=0?B:[].concat(Fs(B),[W])},[]))}else if(b==="category")x?$=$.filter(function(B){return B!==""&&!we(B)}):$=sE(L,$,m).reduce(function(B,W){return B.indexOf(W)>=0||W===""||we(W)?B:[].concat(Fs(B),[W])},[]);else if(b==="number"){var T=nie(C,i.filter(function(B){var W,K,Z=o in B.props?B.props[o]:(W=B.type.defaultProps)===null||W===void 0?void 0:W[o],xe="hide"in B.props?B.props.hide:(K=B.type.defaultProps)===null||K===void 0?void 0:K.hide;return Z===P&&(k||!xe)}),w,a,d);T&&($=T)}h&&(b==="number"||S!=="auto")&&(I=Jl(C,w,"category"))}else h?$=gh(0,N):s&&s[P]&&s[P].hasStack&&b==="number"?$=f==="expand"?[0,1]:$$(s[P].stackGroups,l,u):$=C$(C,i.filter(function(B){var W=o in B.props?B.props[o]:B.type.defaultProps[o],K="hide"in B.props?B.props.hide:B.type.defaultProps.hide;return W===P&&(k||!K)}),b,d,!0);if(b==="number")$=O0(c,$,P,a,E),L&&($=Ky(L,$,_));else if(b==="category"&&L){var U=L,q=$.every(function(B){return U.indexOf(B)>=0});q&&($=U)}}return F(F({},v),{},re({},P,F(F({},y),{},{axisType:a,domain:$,categoricalDomain:I,duplicateDomain:D,originalDomain:(g=y.domain)!==null&&g!==void 0?g:R,isCategorical:h,layout:d})))},{})},Yde=function(t,r){var n=r.graphicalItems,i=r.Axis,a=r.axisType,o=r.axisIdKey,s=r.stackGroups,l=r.dataStartIndex,u=r.dataEndIndex,d=t.layout,c=t.children,f=om(t.data,{graphicalItems:n,dataStartIndex:l,dataEndIndex:u}),h=f.length,v=N$(d,a),m=-1;return n.reduce(function(g,y){var b=y.type.defaultProps!==void 0?F(F({},y.type.defaultProps),y.props):y.props,w=b[o],_=D2("number");if(!g[w]){m++;var x;return v?x=gh(0,h):s&&s[w]&&s[w].hasStack?(x=$$(s[w].stackGroups,l,u),x=O0(c,x,w,a)):(x=Ky(_,C$(f,n.filter(function(S){var E,k,P=o in S.props?S.props[o]:(E=S.type.defaultProps)===null||E===void 0?void 0:E[o],C="hide"in S.props?S.props.hide:(k=S.type.defaultProps)===null||k===void 0?void 0:k.hide;return P===w&&!C}),"number",d),i.defaultProps.allowDataOverflow),x=O0(c,x,w,a)),F(F({},g),{},re({},w,F(F({axisType:a},i.defaultProps),{},{hide:!0,orientation:kr(qde,"".concat(a,".").concat(m%2),null),domain:x,originalDomain:_,isCategorical:v,layout:d})))}return g},{})},Xde=function(t,r){var n=r.axisType,i=n===void 0?"xAxis":n,a=r.AxisComp,o=r.graphicalItems,s=r.stackGroups,l=r.dataStartIndex,u=r.dataEndIndex,d=t.children,c="".concat(i,"Id"),f=tn(d,a),h={};return f&&f.length?h=Gde(t,{axes:f,graphicalItems:o,axisType:i,axisIdKey:c,stackGroups:s,dataStartIndex:l,dataEndIndex:u}):o&&o.length&&(h=Yde(t,{Axis:a,graphicalItems:o,axisType:i,axisIdKey:c,stackGroups:s,dataStartIndex:l,dataEndIndex:u})),h},Qde=function(t){var r=ko(t),n=ka(r,!1,!0);return{tooltipTicks:n,orderedTooltipTicks:xw(n,function(i){return i.coordinate}),tooltipAxis:r,tooltipAxisBandSize:lh(r,n)}},kk=function(t){var r=t.children,n=t.defaultShowTooltip,i=ir(r,Ns),a=0,o=0;return t.data&&t.data.length!==0&&(o=t.data.length-1),i&&i.props&&(i.props.startIndex>=0&&(a=i.props.startIndex),i.props.endIndex>=0&&(o=i.props.endIndex)),{chartX:0,chartY:0,dataStartIndex:a,dataEndIndex:o,activeTooltipIndex:-1,isTooltipActive:!!n}},Jde=function(t){return!t||!t.length?!1:t.some(function(r){var n=Hn(r&&r.type);return n&&n.indexOf("Bar")>=0})},Pk=function(t){return t==="horizontal"?{numericAxisName:"yAxis",cateAxisName:"xAxis"}:t==="vertical"?{numericAxisName:"xAxis",cateAxisName:"yAxis"}:t==="centric"?{numericAxisName:"radiusAxis",cateAxisName:"angleAxis"}:{numericAxisName:"angleAxis",cateAxisName:"radiusAxis"}},Zde=function(t,r){var n=t.props,i=t.graphicalItems,a=t.xAxisMap,o=a===void 0?{}:a,s=t.yAxisMap,l=s===void 0?{}:s,u=n.width,d=n.height,c=n.children,f=n.margin||{},h=ir(c,Ns),v=ir(c,Zo),m=Object.keys(l).reduce(function(x,S){var E=l[S],k=E.orientation;return!E.mirror&&!E.hide?F(F({},x),{},re({},k,x[k]+E.width)):x},{left:f.left||0,right:f.right||0}),g=Object.keys(o).reduce(function(x,S){var E=o[S],k=E.orientation;return!E.mirror&&!E.hide?F(F({},x),{},re({},k,kr(x,"".concat(k))+E.height)):x},{top:f.top||0,bottom:f.bottom||0}),y=F(F({},g),m),b=y.bottom;h&&(y.bottom+=h.props.height||Ns.defaultProps.height),v&&r&&(y=tie(y,i,n,r));var w=u-y.left-y.right,_=d-y.top-y.bottom;return F(F({brushBottom:b},y),{},{width:Math.max(w,0),height:Math.max(_,0)})},efe=function(t,r){if(r==="xAxis")return t[r].width;if(r==="yAxis")return t[r].height},tfe=function(t){var r=t.chartName,n=t.GraphicalChild,i=t.defaultTooltipEventType,a=i===void 0?"axis":i,o=t.validateTooltipEventTypes,s=o===void 0?["axis"]:o,l=t.axisComponents,u=t.legendContent,d=t.formatAxisMap,c=t.defaultProps,f=function(y,b){var w=b.graphicalItems,_=b.stackGroups,x=b.offset,S=b.updateId,E=b.dataStartIndex,k=b.dataEndIndex,P=y.barSize,C=y.layout,N=y.barGap,$=y.barCategoryGap,D=y.maxBarSize,I=Pk(C),R=I.numericAxisName,M=I.cateAxisName,L=Jde(w),A=[];return w.forEach(function(T,U){var q=om(y.data,{graphicalItems:[T],dataStartIndex:E,dataEndIndex:k}),B=T.type.defaultProps!==void 0?F(F({},T.type.defaultProps),T.props):T.props,W=B.dataKey,K=B.maxBarSize,Z=B["".concat(R,"Id")],xe=B["".concat(M,"Id")],ue={},Ze=l.reduce(function(er,cn){var Nr=b["".concat(cn.axisType,"Map")],Rc=B["".concat(cn.axisType,"Id")];Nr&&Nr[Rc]||cn.axisType==="zAxis"||Xa();var Ic=Nr[Rc];return F(F({},er),{},re(re({},cn.axisType,Ic),"".concat(cn.axisType,"Ticks"),ka(Ic)))},ue),G=Ze[M],ie=Ze["".concat(M,"Ticks")],ae=_&&_[Z]&&_[Z].hasStack&&mie(T,_[Z].stackGroups),H=Hn(T.type).indexOf("Bar")>=0,ye=lh(G,ie),ce=[],He=L&&Zne({barSize:P,stackGroups:_,totalSize:efe(Ze,M)});if(H){var Fe,pt,Wt=we(K)?D:K,Zt=(Fe=(pt=lh(G,ie,!0))!==null&&pt!==void 0?pt:Wt)!==null&&Fe!==void 0?Fe:0;ce=eie({barGap:N,barCategoryGap:$,bandSize:Zt!==ye?Zt:ye,sizeList:He[xe],maxBarSize:Wt}),Zt!==ye&&(ce=ce.map(function(er){return F(F({},er),{},{position:F(F({},er.position),{},{offset:er.position.offset-Zt/2})})}))}var oa=T&&T.type&&T.type.getComposedData;oa&&A.push({props:F(F({},oa(F(F({},Ze),{},{displayedData:q,props:y,dataKey:W,item:T,bandSize:ye,barPosition:ce,offset:x,stackedData:ae,layout:C,dataStartIndex:E,dataEndIndex:k}))),{},re(re(re({key:T.key||"item-".concat(U)},R,Ze[R]),M,Ze[M]),"animationId",S)),childIndex:Xq(T,y.children),item:T})}),A},h=function(y,b){var w=y.props,_=y.dataStartIndex,x=y.dataEndIndex,S=y.updateId;if(!tS({props:w}))return null;var E=w.children,k=w.layout,P=w.stackOffset,C=w.data,N=w.reverseStackOrder,$=Pk(k),D=$.numericAxisName,I=$.cateAxisName,R=tn(E,n),M=fie(C,R,"".concat(D,"Id"),"".concat(I,"Id"),P,N),L=l.reduce(function(B,W){var K="".concat(W.axisType,"Map");return F(F({},B),{},re({},K,Xde(w,F(F({},W),{},{graphicalItems:R,stackGroups:W.axisType===D&&M,dataStartIndex:_,dataEndIndex:x}))))},{}),A=Zde(F(F({},L),{},{props:w,graphicalItems:R}),b==null?void 0:b.legendBBox);Object.keys(L).forEach(function(B){L[B]=d(w,L[B],A,B.replace("Map",""),r)});var T=L["".concat(I,"Map")],U=Qde(T),q=f(w,F(F({},L),{},{dataStartIndex:_,dataEndIndex:x,updateId:S,graphicalItems:R,stackGroups:M,offset:A}));return F(F({formattedGraphicalItems:q,graphicalItems:R,offset:A,stackGroups:M},U),L)},v=function(g){function y(b){var w,_,x;return $de(this,y),x=Mde(this,y,[b]),re(x,"eventEmitterSymbol",Symbol("rechartsEventEmitter")),re(x,"accessibilityManager",new bde),re(x,"handleLegendBBoxUpdate",function(S){if(S){var E=x.state,k=E.dataStartIndex,P=E.dataEndIndex,C=E.updateId;x.setState(F({legendBBox:S},h({props:x.props,dataStartIndex:k,dataEndIndex:P,updateId:C},F(F({},x.state),{},{legendBBox:S}))))}}),re(x,"handleReceiveSyncEvent",function(S,E,k){if(x.props.syncId===S){if(k===x.eventEmitterSymbol&&typeof x.props.syncMethod!="function")return;x.applySyncEvent(E)}}),re(x,"handleBrushChange",function(S){var E=S.startIndex,k=S.endIndex;if(E!==x.state.dataStartIndex||k!==x.state.dataEndIndex){var P=x.state.updateId;x.setState(function(){return F({dataStartIndex:E,dataEndIndex:k},h({props:x.props,dataStartIndex:E,dataEndIndex:k,updateId:P},x.state))}),x.triggerSyncEvent({dataStartIndex:E,dataEndIndex:k})}}),re(x,"handleMouseEnter",function(S){var E=x.getMouseInfo(S);if(E){var k=F(F({},E),{},{isTooltipActive:!0});x.setState(k),x.triggerSyncEvent(k);var P=x.props.onMouseEnter;fe(P)&&P(k,S)}}),re(x,"triggeredAfterMouseMove",function(S){var E=x.getMouseInfo(S),k=E?F(F({},E),{},{isTooltipActive:!0}):{isTooltipActive:!1};x.setState(k),x.triggerSyncEvent(k);var P=x.props.onMouseMove;fe(P)&&P(k,S)}),re(x,"handleItemMouseEnter",function(S){x.setState(function(){return{isTooltipActive:!0,activeItem:S,activePayload:S.tooltipPayload,activeCoordinate:S.tooltipPosition||{x:S.cx,y:S.cy}}})}),re(x,"handleItemMouseLeave",function(){x.setState(function(){return{isTooltipActive:!1}})}),re(x,"handleMouseMove",function(S){S.persist(),x.throttleTriggeredAfterMouseMove(S)}),re(x,"handleMouseLeave",function(S){x.throttleTriggeredAfterMouseMove.cancel();var E={isTooltipActive:!1};x.setState(E),x.triggerSyncEvent(E);var k=x.props.onMouseLeave;fe(k)&&k(E,S)}),re(x,"handleOuterEvent",function(S){var E=Yq(S),k=kr(x.props,"".concat(E));if(E&&fe(k)){var P,C;/.*touch.*/i.test(E)?C=x.getMouseInfo(S.changedTouches[0]):C=x.getMouseInfo(S),k((P=C)!==null&&P!==void 0?P:{},S)}}),re(x,"handleClick",function(S){var E=x.getMouseInfo(S);if(E){var k=F(F({},E),{},{isTooltipActive:!0});x.setState(k),x.triggerSyncEvent(k);var P=x.props.onClick;fe(P)&&P(k,S)}}),re(x,"handleMouseDown",function(S){var E=x.props.onMouseDown;if(fe(E)){var k=x.getMouseInfo(S);E(k,S)}}),re(x,"handleMouseUp",function(S){var E=x.props.onMouseUp;if(fe(E)){var k=x.getMouseInfo(S);E(k,S)}}),re(x,"handleTouchMove",function(S){S.changedTouches!=null&&S.changedTouches.length>0&&x.throttleTriggeredAfterMouseMove(S.changedTouches[0])}),re(x,"handleTouchStart",function(S){S.changedTouches!=null&&S.changedTouches.length>0&&x.handleMouseDown(S.changedTouches[0])}),re(x,"handleTouchEnd",function(S){S.changedTouches!=null&&S.changedTouches.length>0&&x.handleMouseUp(S.changedTouches[0])}),re(x,"handleDoubleClick",function(S){var E=x.props.onDoubleClick;if(fe(E)){var k=x.getMouseInfo(S);E(k,S)}}),re(x,"handleContextMenu",function(S){var E=x.props.onContextMenu;if(fe(E)){var k=x.getMouseInfo(S);E(k,S)}}),re(x,"triggerSyncEvent",function(S){x.props.syncId!==void 0&&Av.emit(jv,x.props.syncId,S,x.eventEmitterSymbol)}),re(x,"applySyncEvent",function(S){var E=x.props,k=E.layout,P=E.syncMethod,C=x.state.updateId,N=S.dataStartIndex,$=S.dataEndIndex;if(S.dataStartIndex!==void 0||S.dataEndIndex!==void 0)x.setState(F({dataStartIndex:N,dataEndIndex:$},h({props:x.props,dataStartIndex:N,dataEndIndex:$,updateId:C},x.state)));else if(S.activeTooltipIndex!==void 0){var D=S.chartX,I=S.chartY,R=S.activeTooltipIndex,M=x.state,L=M.offset,A=M.tooltipTicks;if(!L)return;if(typeof P=="function")R=P(A,S);else if(P==="value"){R=-1;for(var T=0;T<A.length;T++)if(A[T].value===S.activeLabel){R=T;break}}var U=F(F({},L),{},{x:L.left,y:L.top}),q=Math.min(D,U.x+U.width),B=Math.min(I,U.y+U.height),W=A[R]&&A[R].value,K=P0(x.state,x.props.data,R),Z=A[R]?{x:k==="horizontal"?A[R].coordinate:q,y:k==="horizontal"?B:A[R].coordinate}:M2;x.setState(F(F({},S),{},{activeLabel:W,activeCoordinate:Z,activePayload:K,activeTooltipIndex:R}))}else x.setState(S)}),re(x,"renderCursor",function(S){var E,k=x.state,P=k.isTooltipActive,C=k.activeCoordinate,N=k.activePayload,$=k.offset,D=k.activeTooltipIndex,I=k.tooltipAxisBandSize,R=x.getTooltipEventType(),M=(E=S.props.active)!==null&&E!==void 0?E:P,L=x.props.layout,A=S.key||"_recharts-cursor";return j.createElement(kde,{key:A,activeCoordinate:C,activePayload:N,activeTooltipIndex:D,chartName:r,element:S,isActive:M,layout:L,offset:$,tooltipAxisBandSize:I,tooltipEventType:R})}),re(x,"renderPolarAxis",function(S,E,k){var P=kr(S,"type.axisType"),C=kr(x.state,"".concat(P,"Map")),N=S.type.defaultProps,$=N!==void 0?F(F({},N),S.props):S.props,D=C&&C[$["".concat(P,"Id")]];return O.cloneElement(S,F(F({},D),{},{className:pe(P,D.className),key:S.key||"".concat(E,"-").concat(k),ticks:ka(D,!0)}))}),re(x,"renderPolarGrid",function(S){var E=S.props,k=E.radialLines,P=E.polarAngles,C=E.polarRadius,N=x.state,$=N.radiusAxisMap,D=N.angleAxisMap,I=ko($),R=ko(D),M=R.cx,L=R.cy,A=R.innerRadius,T=R.outerRadius;return O.cloneElement(S,{polarAngles:Array.isArray(P)?P:ka(R,!0).map(function(U){return U.coordinate}),polarRadius:Array.isArray(C)?C:ka(I,!0).map(function(U){return U.coordinate}),cx:M,cy:L,innerRadius:A,outerRadius:T,key:S.key||"polar-grid",radialLines:k})}),re(x,"renderLegend",function(){var S=x.state.formattedGraphicalItems,E=x.props,k=E.children,P=E.width,C=E.height,N=x.props.margin||{},$=P-(N.left||0)-(N.right||0),D=j$({children:k,formattedGraphicalItems:S,legendWidth:$,legendContent:u});if(!D)return null;var I=D.item,R=Sk(D,Pde);return O.cloneElement(I,F(F({},R),{},{chartWidth:P,chartHeight:C,margin:N,onBBoxUpdate:x.handleLegendBBoxUpdate}))}),re(x,"renderTooltip",function(){var S,E=x.props,k=E.children,P=E.accessibilityLayer,C=ir(k,hn);if(!C)return null;var N=x.state,$=N.isTooltipActive,D=N.activeCoordinate,I=N.activePayload,R=N.activeLabel,M=N.offset,L=(S=C.props.active)!==null&&S!==void 0?S:$;return O.cloneElement(C,{viewBox:F(F({},M),{},{x:M.left,y:M.top}),active:L,label:R,payload:L?I:[],coordinate:D,accessibilityLayer:P})}),re(x,"renderBrush",function(S){var E=x.props,k=E.margin,P=E.data,C=x.state,N=C.offset,$=C.dataStartIndex,D=C.dataEndIndex,I=C.updateId;return O.cloneElement(S,{key:S.key||"_recharts-brush",onChange:_d(x.handleBrushChange,S.props.onChange),data:P,x:Y(S.props.x)?S.props.x:N.left,y:Y(S.props.y)?S.props.y:N.top+N.height+N.brushBottom-(k.bottom||0),width:Y(S.props.width)?S.props.width:N.width,startIndex:$,endIndex:D,updateId:"brush-".concat(I)})}),re(x,"renderReferenceElement",function(S,E,k){if(!S)return null;var P=x,C=P.clipPathId,N=x.state,$=N.xAxisMap,D=N.yAxisMap,I=N.offset,R=S.type.defaultProps||{},M=S.props,L=M.xAxisId,A=L===void 0?R.xAxisId:L,T=M.yAxisId,U=T===void 0?R.yAxisId:T;return O.cloneElement(S,{key:S.key||"".concat(E,"-").concat(k),xAxis:$[A],yAxis:D[U],viewBox:{x:I.left,y:I.top,width:I.width,height:I.height},clipPathId:C})}),re(x,"renderActivePoints",function(S){var E=S.item,k=S.activePoint,P=S.basePoint,C=S.childIndex,N=S.isRange,$=[],D=E.props.key,I=E.item.type.defaultProps!==void 0?F(F({},E.item.type.defaultProps),E.item.props):E.item.props,R=I.activeDot,M=I.dataKey,L=F(F({index:C,dataKey:M,cx:k.x,cy:k.y,r:4,fill:Gw(E.item),strokeWidth:2,stroke:"#fff",payload:k.payload,value:k.value},Se(R,!1)),Nf(R));return $.push(y.renderActiveDot(R,L,"".concat(D,"-activePoint-").concat(C))),P?$.push(y.renderActiveDot(R,F(F({},L),{},{cx:P.x,cy:P.y}),"".concat(D,"-basePoint-").concat(C))):N&&$.push(null),$}),re(x,"renderGraphicChild",function(S,E,k){var P=x.filterFormatItem(S,E,k);if(!P)return null;var C=x.getTooltipEventType(),N=x.state,$=N.isTooltipActive,D=N.tooltipAxis,I=N.activeTooltipIndex,R=N.activeLabel,M=x.props.children,L=ir(M,hn),A=P.props,T=A.points,U=A.isRange,q=A.baseLine,B=P.item.type.defaultProps!==void 0?F(F({},P.item.type.defaultProps),P.item.props):P.item.props,W=B.activeDot,K=B.hide,Z=B.activeBar,xe=B.activeShape,ue=!!(!K&&$&&L&&(W||Z||xe)),Ze={};C!=="axis"&&L&&L.props.trigger==="click"?Ze={onClick:_d(x.handleItemMouseEnter,S.props.onClick)}:C!=="axis"&&(Ze={onMouseLeave:_d(x.handleItemMouseLeave,S.props.onMouseLeave),onMouseEnter:_d(x.handleItemMouseEnter,S.props.onMouseEnter)});var G=O.cloneElement(S,F(F({},P.props),Ze));function ie(cn){return typeof D.dataKey=="function"?D.dataKey(cn.payload):null}if(ue)if(I>=0){var ae,H;if(D.dataKey&&!D.allowDuplicatedCategory){var ye=typeof D.dataKey=="function"?ie:"payload.".concat(D.dataKey.toString());ae=oy(T,ye,R),H=U&&q&&oy(q,ye,R)}else ae=T==null?void 0:T[I],H=U&&q&&q[I];if(xe||Z){var ce=S.props.activeIndex!==void 0?S.props.activeIndex:I;return[O.cloneElement(S,F(F(F({},P.props),Ze),{},{activeIndex:ce})),null,null]}if(!we(ae))return[G].concat(Fs(x.renderActivePoints({item:P,activePoint:ae,basePoint:H,childIndex:I,isRange:U})))}else{var He,Fe=(He=x.getItemByXY(x.state.activeCoordinate))!==null&&He!==void 0?He:{graphicalItem:G},pt=Fe.graphicalItem,Wt=pt.item,Zt=Wt===void 0?S:Wt,oa=pt.childIndex,er=F(F(F({},P.props),Ze),{},{activeIndex:oa});return[O.cloneElement(Zt,er),null,null]}return U?[G,null,null]:[G,null]}),re(x,"renderCustomized",function(S,E,k){return O.cloneElement(S,F(F({key:"recharts-customized-".concat(k)},x.props),x.state))}),re(x,"renderMap",{CartesianGrid:{handler:Pd,once:!0},ReferenceArea:{handler:x.renderReferenceElement},ReferenceLine:{handler:Pd},ReferenceDot:{handler:x.renderReferenceElement},XAxis:{handler:Pd},YAxis:{handler:Pd},Brush:{handler:x.renderBrush,once:!0},Bar:{handler:x.renderGraphicChild},Line:{handler:x.renderGraphicChild},Area:{handler:x.renderGraphicChild},Radar:{handler:x.renderGraphicChild},RadialBar:{handler:x.renderGraphicChild},Scatter:{handler:x.renderGraphicChild},Pie:{handler:x.renderGraphicChild},Funnel:{handler:x.renderGraphicChild},Tooltip:{handler:x.renderCursor,once:!0},PolarGrid:{handler:x.renderPolarGrid,once:!0},PolarAngleAxis:{handler:x.renderPolarAxis},PolarRadiusAxis:{handler:x.renderPolarAxis},Customized:{handler:x.renderCustomized}}),x.clipPathId="".concat((w=b.id)!==null&&w!==void 0?w:Cp("recharts"),"-clip"),x.throttleTriggeredAfterMouseMove=jN(x.triggeredAfterMouseMove,(_=b.throttleDelay)!==null&&_!==void 0?_:1e3/60),x.state={},x}return Bde(y,g),Ide(y,[{key:"componentDidMount",value:function(){var w,_;this.addListener(),this.accessibilityManager.setDetails({container:this.container,offset:{left:(w=this.props.margin.left)!==null&&w!==void 0?w:0,top:(_=this.props.margin.top)!==null&&_!==void 0?_:0},coordinateList:this.state.tooltipTicks,mouseHandlerCallback:this.triggeredAfterMouseMove,layout:this.props.layout}),this.displayDefaultTooltip()}},{key:"displayDefaultTooltip",value:function(){var w=this.props,_=w.children,x=w.data,S=w.height,E=w.layout,k=ir(_,hn);if(k){var P=k.props.defaultIndex;if(!(typeof P!="number"||P<0||P>this.state.tooltipTicks.length-1)){var C=this.state.tooltipTicks[P]&&this.state.tooltipTicks[P].value,N=P0(this.state,x,P,C),$=this.state.tooltipTicks[P].coordinate,D=(this.state.offset.top+S)/2,I=E==="horizontal",R=I?{x:$,y:D}:{y:$,x:D},M=this.state.formattedGraphicalItems.find(function(A){var T=A.item;return T.type.name==="Scatter"});M&&(R=F(F({},R),M.props.points[P].tooltipPosition),N=M.props.points[P].tooltipPayload);var L={activeTooltipIndex:P,isTooltipActive:!0,activeLabel:C,activePayload:N,activeCoordinate:R};this.setState(L),this.renderCursor(k),this.accessibilityManager.setIndex(P)}}}},{key:"getSnapshotBeforeUpdate",value:function(w,_){if(!this.props.accessibilityLayer)return null;if(this.state.tooltipTicks!==_.tooltipTicks&&this.accessibilityManager.setDetails({coordinateList:this.state.tooltipTicks}),this.props.layout!==w.layout&&this.accessibilityManager.setDetails({layout:this.props.layout}),this.props.margin!==w.margin){var x,S;this.accessibilityManager.setDetails({offset:{left:(x=this.props.margin.left)!==null&&x!==void 0?x:0,top:(S=this.props.margin.top)!==null&&S!==void 0?S:0}})}return null}},{key:"componentDidUpdate",value:function(w){ly([ir(w.children,hn)],[ir(this.props.children,hn)])||this.displayDefaultTooltip()}},{key:"componentWillUnmount",value:function(){this.removeListener(),this.throttleTriggeredAfterMouseMove.cancel()}},{key:"getTooltipEventType",value:function(){var w=ir(this.props.children,hn);if(w&&typeof w.props.shared=="boolean"){var _=w.props.shared?"axis":"item";return s.indexOf(_)>=0?_:a}return a}},{key:"getMouseInfo",value:function(w){if(!this.container)return null;var _=this.container,x=_.getBoundingClientRect(),S=OZ(x),E={chartX:Math.round(w.pageX-S.left),chartY:Math.round(w.pageY-S.top)},k=x.width/_.offsetWidth||1,P=this.inRange(E.chartX,E.chartY,k);if(!P)return null;var C=this.state,N=C.xAxisMap,$=C.yAxisMap,D=this.getTooltipEventType(),I=Ek(this.state,this.props.data,this.props.layout,P);if(D!=="axis"&&N&&$){var R=ko(N).scale,M=ko($).scale,L=R&&R.invert?R.invert(E.chartX):null,A=M&&M.invert?M.invert(E.chartY):null;return F(F({},E),{},{xValue:L,yValue:A},I)}return I?F(F({},E),I):null}},{key:"inRange",value:function(w,_){var x=arguments.length>2&&arguments[2]!==void 0?arguments[2]:1,S=this.props.layout,E=w/x,k=_/x;if(S==="horizontal"||S==="vertical"){var P=this.state.offset,C=E>=P.left&&E<=P.left+P.width&&k>=P.top&&k<=P.top+P.height;return C?{x:E,y:k}:null}var N=this.state,$=N.angleAxisMap,D=N.radiusAxisMap;if($&&D){var I=ko($);return cE({x:E,y:k},I)}return null}},{key:"parseEventsOfWrapper",value:function(){var w=this.props.children,_=this.getTooltipEventType(),x=ir(w,hn),S={};x&&_==="axis"&&(x.props.trigger==="click"?S={onClick:this.handleClick}:S={onMouseEnter:this.handleMouseEnter,onDoubleClick:this.handleDoubleClick,onMouseMove:this.handleMouseMove,onMouseLeave:this.handleMouseLeave,onTouchMove:this.handleTouchMove,onTouchStart:this.handleTouchStart,onTouchEnd:this.handleTouchEnd,onContextMenu:this.handleContextMenu});var E=Nf(this.props,this.handleOuterEvent);return F(F({},E),S)}},{key:"addListener",value:function(){Av.on(jv,this.handleReceiveSyncEvent)}},{key:"removeListener",value:function(){Av.removeListener(jv,this.handleReceiveSyncEvent)}},{key:"filterFormatItem",value:function(w,_,x){for(var S=this.state.formattedGraphicalItems,E=0,k=S.length;E<k;E++){var P=S[E];if(P.item===w||P.props.key===w.key||_===Hn(P.item.type)&&x===P.childIndex)return P}return null}},{key:"renderClipPath",value:function(){var w=this.clipPathId,_=this.state.offset,x=_.left,S=_.top,E=_.height,k=_.width;return j.createElement("defs",null,j.createElement("clipPath",{id:w},j.createElement("rect",{x,y:S,height:E,width:k})))}},{key:"getXScales",value:function(){var w=this.state.xAxisMap;return w?Object.entries(w).reduce(function(_,x){var S=_k(x,2),E=S[0],k=S[1];return F(F({},_),{},re({},E,k.scale))},{}):null}},{key:"getYScales",value:function(){var w=this.state.yAxisMap;return w?Object.entries(w).reduce(function(_,x){var S=_k(x,2),E=S[0],k=S[1];return F(F({},_),{},re({},E,k.scale))},{}):null}},{key:"getXScaleByAxisId",value:function(w){var _;return(_=this.state.xAxisMap)===null||_===void 0||(_=_[w])===null||_===void 0?void 0:_.scale}},{key:"getYScaleByAxisId",value:function(w){var _;return(_=this.state.yAxisMap)===null||_===void 0||(_=_[w])===null||_===void 0?void 0:_.scale}},{key:"getItemByXY",value:function(w){var _=this.state,x=_.formattedGraphicalItems,S=_.activeItem;if(x&&x.length)for(var E=0,k=x.length;E<k;E++){var P=x[E],C=P.props,N=P.item,$=N.type.defaultProps!==void 0?F(F({},N.type.defaultProps),N.props):N.props,D=Hn(N.type);if(D==="Bar"){var I=(C.data||[]).find(function(A){return ose(w,A)});if(I)return{graphicalItem:P,payload:I}}else if(D==="RadialBar"){var R=(C.data||[]).find(function(A){return cE(w,A)});if(R)return{graphicalItem:P,payload:R}}else if(Xp(P,S)||Qp(P,S)||oc(P,S)){var M=ule({graphicalItem:P,activeTooltipItem:S,itemData:$.data}),L=$.activeIndex===void 0?M:$.activeIndex;return{graphicalItem:F(F({},P),{},{childIndex:L}),payload:oc(P,S)?$.data[M]:P.props.data[M]}}}return null}},{key:"render",value:function(){var w=this;if(!tS(this))return null;var _=this.props,x=_.children,S=_.className,E=_.width,k=_.height,P=_.style,C=_.compact,N=_.title,$=_.desc,D=Sk(_,Ade),I=Se(D,!1);if(C)return j.createElement(uk,{state:this.state,width:this.props.width,height:this.props.height,clipPathId:this.clipPathId},j.createElement(cy,zo({},I,{width:E,height:k,title:N,desc:$}),this.renderClipPath(),nS(x,this.renderMap)));if(this.props.accessibilityLayer){var R,M;I.tabIndex=(R=this.props.tabIndex)!==null&&R!==void 0?R:0,I.role=(M=this.props.role)!==null&&M!==void 0?M:"application",I.onKeyDown=function(A){w.accessibilityManager.keyboardEvent(A)},I.onFocus=function(){w.accessibilityManager.focus()}}var L=this.parseEventsOfWrapper();return j.createElement(uk,{state:this.state,width:this.props.width,height:this.props.height,clipPathId:this.clipPathId},j.createElement("div",zo({className:pe("recharts-wrapper",S),style:F({position:"relative",cursor:"default",width:E,height:k},P)},L,{ref:function(T){w.container=T}}),j.createElement(cy,zo({},I,{width:E,height:k,title:N,desc:$,style:Hde}),this.renderClipPath(),nS(x,this.renderMap)),this.renderLegend(),this.renderTooltip()))}}])}(O.Component);re(v,"displayName",r),re(v,"defaultProps",F({layout:"horizontal",stackOffset:"none",barCategoryGap:"10%",barGap:4,margin:{top:5,right:5,bottom:5,left:5},reverseStackOrder:!1,syncMethod:"index"},c)),re(v,"getDerivedStateFromProps",function(g,y){var b=g.dataKey,w=g.data,_=g.children,x=g.width,S=g.height,E=g.layout,k=g.stackOffset,P=g.margin,C=y.dataStartIndex,N=y.dataEndIndex;if(y.updateId===void 0){var $=kk(g);return F(F(F({},$),{},{updateId:0},h(F(F({props:g},$),{},{updateId:0}),y)),{},{prevDataKey:b,prevData:w,prevWidth:x,prevHeight:S,prevLayout:E,prevStackOffset:k,prevMargin:P,prevChildren:_})}if(b!==y.prevDataKey||w!==y.prevData||x!==y.prevWidth||S!==y.prevHeight||E!==y.prevLayout||k!==y.prevStackOffset||!Jo(P,y.prevMargin)){var D=kk(g),I={chartX:y.chartX,chartY:y.chartY,isTooltipActive:y.isTooltipActive},R=F(F({},Ek(y,w,E)),{},{updateId:y.updateId+1}),M=F(F(F({},D),I),R);return F(F(F({},M),h(F({props:g},M),y)),{},{prevDataKey:b,prevData:w,prevWidth:x,prevHeight:S,prevLayout:E,prevStackOffset:k,prevMargin:P,prevChildren:_})}if(!ly(_,y.prevChildren)){var L,A,T,U,q=ir(_,Ns),B=q&&(L=(A=q.props)===null||A===void 0?void 0:A.startIndex)!==null&&L!==void 0?L:C,W=q&&(T=(U=q.props)===null||U===void 0?void 0:U.endIndex)!==null&&T!==void 0?T:N,K=B!==C||W!==N,Z=!we(w),xe=Z&&!K?y.updateId:y.updateId+1;return F(F({updateId:xe},h(F(F({props:g},y),{},{updateId:xe,dataStartIndex:B,dataEndIndex:W}),y)),{},{prevChildren:_,dataStartIndex:B,dataEndIndex:W})}return null}),re(v,"renderActiveDot",function(g,y,b){var w;return O.isValidElement(g)?w=O.cloneElement(g,y):fe(g)?w=g(y):w=j.createElement(G$,y),j.createElement(gt,{className:"recharts-active-dot",ke
357y:b},w)});var m=O.forwardRef(function(y,b){return j.createElement(v,zo({},y,{ref:b}))});return m.displayName=v.displayName,m},rfe=tfe({chartName:"BarChart",GraphicalChild:Yi,defaultTooltipEventType:"axis",validateTooltipEventTypes:["axis","item"],axisComponents:[{axisType:"xAxis",AxisComp:im},{axisType:"yAxis",AxisComp:am}],formatAxisMap:Mue});const nfe=["Klimatförändringar","Förlust av biologisk mÃ¥ngfald","Kvävecykeln & fosforflöden","Stratosfärisk ozonförtunning","Havsförsurning","Sötvattenanvändning","Förändrad markanvändning","Kemisk förorening","Aerosolbelastning"],Ak="Klimatförändringar";function ex(e){if(!e||e.length===0)return null;const t=new Map(e.map(s=>[s.topic,s])),n=e.filter(s=>s.performance>s.communication).sort((s,l)=>l.performance-l.communication-(s.performance-s.communication)).filter(s=>s.topic!==Ak),i=e.filter(s=>s.communication>s.performance+10).sort((s,l)=>l.communication-l.performance-(s.communication-s.performance)),a=[],o=t.get(Ak);if(o&&(o.performance>50&&o.communication>50?a.push(`Inom klimatomrÃ¥det har företaget bÃ¥de stark prestation (${o.performance}) och aktiv kommunikation (${o.communication}), vilket är positivt men ocksÃ¥ förväntat â de flesta konkurrenter kommunicerar klimat.`):o.performance>o.communication&&a.push(`Klimatarbetet (prestation ${o.performance}) kommuniceras inte i nivÃ¥ med insatserna (${o.communication}), vilket innebär en outnyttjad möjlighet.`)),n.length>0){const l=n.slice(0,3).map(u=>`<strong>${u.topic}</strong> (prestation ${u.performance}, kommunikation ${u.communication})`).join("; ");a.push(`De mest intressanta positioneringsmöjligheterna finns utanför klimat: ${l}. Dessa omrÃ¥den är underrepresenterade i marknadskommunikation generellt, vilket ger en möjlighet att särskilja varumärket.`)}if(i.length>0){const s=i.map(l=>l.topic).join(", ");a.push(`Inom ${s} kommuniceras mer än vad prestationen motiverar â ett potentiellt greenwashing-riskomrÃ¥de som bör uppmärksammas.`)}return{summary:a.join(" ")}}function L2({data:e}){const t=new Map;for(const n of e)t.set(n.topic,n);const r=nfe.map(n=>{const i=t.get(n),a=!!i;return{name:n,Prestation:a?i.performance:0,Kommunikation:a?i.communication:0,hasData:a}});return ex(e),p.jsxs(dr,{className:"border-0 shadow-none bg-white",children:[p.jsx(Zr,{className:"pb-3",children:p.jsx(en,{className:"font-display text-lg",children:"Prestation vs Kommunikation"})}),p.jsxs(fr,{children:[p.jsx("div",{className:"h-[480px]",children:p.jsx(gZ,{width:"100%",height:"100%",children:p.jsxs(rfe,{data:r,layout:"vertical",margin:{left:30,right:20,top:5,bottom:5},children:[p.jsx(im,{type:"number",domain:[0,100],tick:{fontSize:11,fill:"hsl(var(--muted-foreground))"}}),p.jsx(am,{type:"category",dataKey:"name",tick:({x:n,y:i,payload:a})=>{const o=r.find(l=>
357l.name===a.value),s=o!=null&&o.hasData?1:.4;return p.jsxs("text",{x:n,y:i,dy:4,textAnchor:"end",fontSize:10,fill:"hsl(var(--muted-foreground))",opacity:s,children:[a.value,o!=null&&o.hasData?"":" (ej data)"]})},width:180}),p.jsx(hn,{contentStyle:{backgroundColor:"hsl(var(--card))",border:"1px solid hsl(var(--border))",borderRadius:"8px",fontSize:"12px"},formatter:(n,i,a)=>a.payload.hasData?[n,i]:["Ej tillgänglig",i]}),p.jsx(Yi,{dataKey:"Prestation",radius:[0,4,4,0],barSize:12,children:r.map((n,i)=>p.jsx(Vf,{fill:"hsl(var(--chart-green))",opacity:n.hasData?1:.15},i))}),p.jsx(Yi,{dataKey:"Kommunikation",radius:[0,4,4,0],barSize:12,children:r.map((n,i)=>p.jsx(Vf,{fill:"hsl(var(--chart-blue))",opacity:n.hasData?1:.15},i))})]})})}),p.jsxs("div",{className:"flex items-center justify-center gap-6 mt-4 text-xs text-muted-foreground",children:[p.jsxs("div",{className:"flex items-center gap-2",children:[p.jsx("div",{className:"w-3 h-3 rounded-sm bg-chart-green"}),p.jsx("span",{children:"Prestation (evidens)"})]}),p.jsxs("div",{className:"flex items-center gap-2",children:[p.jsx("div",{className:"w-3 h-3 rounded-sm bg-chart-blue"}),p.jsx("span",{children:"Kommunikation (budskap)"})]}),p.jsxs("div",{className:"flex items-center gap-2",children:[p.jsx("div",{className:"w-3 h-3 rounded-sm bg-muted opacity-40"}),p.jsx("span",{children:"Ej data tillgänglig"})]})]})]})]})}const B2="/assets/PB_2025_sv-Bwa9Q7qq.png";function Cv(e){const t=e.match(/^\*\*(.+?):?\*\*:?\s*([\s\S]*)/);if(t){const r=t[1],n=t[2];return p.jsxs("div",{children:[p.jsx("span",{className:"font-semibold text-foreground block mb-1",children:r}),p.jsx("span",{className:"text-muted-foreground",children:jk(n)})]})}return p.jsx("span",{className:"text-muted-foreground",children:jk(e)})}function jk(e){const t=[{pattern:/\b(SBTi|Science Based Targets initiative)\b/g,url:"https://sciencebasedtargets.org/"},{pattern:/\b(Parisavtalet)\b/g,url:"https://unfccc.int/process-and-meetings/the-paris-agreement"},{pattern:/\b(EU:s nya direktiv|EU:s "Empowering Consumers|Empowering Consumers in the Green Transition)\b/g,url:"https://commission.europa.eu/live-work-travel-eu/consumer-rights-and-complaints/enforcement-consumer-protection/green-transition_en"},{pattern:/\b(GRI|Global Reporting Initiative)\b/g,url:"https://www.globalreporting.org/"},{pattern:/\b(CSRD)\b/g,url:"https://finance.ec.europa.eu/capital-markets-union-and-financial-markets/company-reporting-and-auditing/company-reporting/corporate-sustainability-reporting_en"},{pattern:/\b(GHG Protocol)\b/g,url:"https://ghgprotocol.org/"}];let r=e,n=0;for(const i of t){const a=[];for(const o of typeof r=="string"?[r]:[]){let s=0;const l=new RegExp(i.pattern.source,"g");let u;for(;(u=l.exec(o))!==null;)u.index>s&&a.push(o.slice(s,u.index)),a.push(p.jsxs("a",{href:i.url,target:"_blank",rel:"noopener noreferrer",className:"inline-flex items-center gap-0.5 text-primary hover:underline font-medium",children:[u[0],p.jsx(Wj,{className:"h-3 w-3 inline-block"})]},`ref-${n++}`)),s=l.lastIndex;s<o.length&&a.push(o.slice(s))}a.length>0&&(r=a)}return typeof r=="string"?r:p.jsx(p.Fragment,{children:r})}function U2({risks:e,opportunities:t,quickWins:r}){return p.jsxs("div",{className:"grid grid-cols-1 lg:grid-cols-3 gap-4",children:[p.jsxs(dr,{className:"border-red-400 bg-white",children:[p.jsx(Zr,{className:"pb-3",children:p.jsxs(en,{className:"font-display text-lg flex items-center gap-2 text-foreground",children:[p.jsx(Vj,{className:"h-5 w-5"}),"Greenwashing-risker"]})}),p.jsx(fr,{children:p.jsx("ul",{className:"space-y-4",children:e.map((n,i)=>p.jsxs("li",{className:"text-sm leading-relaxed flex gap-2.5",children:[p.jsx("span",{className:"text-destructive mt-1 shrink-0",children:"â¢"}),p.jsx("div",{children:Cv(n)})]},i))})})]}),p.jsxs(dr,{className:"border-yellow-400 bg-white",children:[p.jsx(Zr,{className:"pb-3",children:p.jsxs(en,{className:"font-display text-lg flex items-center gap-2 text-foreground",children:[p.jsx(Cb,{className:"h-5 w-5"}),"Positiva exempel & möjligheter"]})}),p.jsx(fr,{children:p.jsx("ul",{className:"space-y-4",children:t.map((n,i)=>p.jsxs("li",{className:"text-sm leading-relaxed flex gap-2.5",children:[p.jsx("span",{className:"text-warning mt-1 shrink-0",children:"â¢"}),p.jsx("div",{children:Cv(n)})]},i))})})]}),p.jsxs(dr,{className:"border-green-500 bg-white",children:[p.jsx(Zr,{className:"pb-3",children:p.jsxs(en,{className:"font-display text-lg flex items-center gap-2 text-foreground",children:[p.jsx(e4,{className:"h-5 w-5"}),"Snabba vinster"]})}),p.jsx(fr,{children:p.jsx("ul",{className:"space-y-4",children:r.map((n,i)=>p.jsxs("li",{className:"text-sm leading-relaxed flex gap-2.5",children:[p.jsx("span",{className:"text-primary mt-1 shrink-0",children:"â¢"}),p.jsx("div",{children:Cv(n)})]},i))})})]})]})}var sm="Collapsible",[ife,F2]=ni(sm),[afe,tx]=ife(sm),z2=O.forwardRef((e,t)=>
vendor: 4,276 bytes, line 357
357{const{__scopeCollapsible:r,open:n,defaultOpen:i,disabled:a,onOpenChange:o,...s}=e,[l,u]=eo({prop:n,defaultProp:i??!1,onChange:o,caller:sm});return p.jsx(afe,{scope:r,disabled:a,contentId:Ia(),open:l,onOpenToggle:O.useCallback(()=>u(d=>!d),[u]),children:p.jsx(Oe.div,{"data-state":nx(l),"data-disabled":a?"":void 0,...s,ref:t})})});z2.displayName=sm;var W2="CollapsibleTrigger",q2=O.forwardRef((e,t)=>{const{__scopeCollapsible:r,...n}=e,i=tx(W2,r);return p.jsx(Oe.button,{type:"button","aria-controls":i.contentId,"aria-expanded":i.open||!1,"data-state":nx(i.open),"data-disabled":i.disabled?"":void 0,disabled:i.disabled,...n,ref:t,onClick:be(e.onClick,i.onOpenToggle)})});q2.displayName=W2;var rx="CollapsibleContent",H2=O.forwardRef((e,t)=>{const{forceMount:r,...n}=e,i=tx(rx,e.__scopeCollapsible);return p.jsx(ii,{present:r||i.open,children:({present:a})=>p.jsx(ofe,{...n,ref:t,present:a})})});H2.displayName=rx;var ofe=O.forwardRef((e,t)=>{const{__scopeCollapsible:r,present:n,children:i,...a}=e,o=tx(rx,r),[s,l]=O.useState(n),u=O.useRef(null),d=ft(t,u),c=O.useRef(0),f=c.current,h=O.useRef(0),v=h.current,m=o.open||s,g=O.useRef(m),y=O.useRef(void 0);return O.useEffect(()=>{const b=requestAnimationFrame(()=>g.current=!1);return()=>cancelAnimationFrame(b)},[]),Pn(()=>{const b=u.current;if(b){y.current=y.current||{transitionDuration:b.style.transitionDuration,animationName:b.style.animationName},b.style.transitionDuration="0s",b.style.animationName="none";const w=b.getBoundingClientRect();c.current=w.height,h.current=w.width,g.current||(b.style.transitionDuration=y.current.transitionDuration,b.style.animationName=y.current.animationName),l(n)}},[o.open,n]),p.jsx(Oe.div,{"data-state":nx(o.open),"data-disabled":o.disabled?"":void 0,id:o.contentId,hidden:!m,...a,ref:d,style:{"--radix-collapsible-content-height":f?`${f}px`:void 0,"--radix-collapsible-content-width":v?`${v}px`:void 0,...e.style},children:m&&i})});function nx(e){return e?"open":"closed"}var sfe=z2,lfe=q2,ufe=H2,cfe=O.createContext(void 0);function dfe(e){const t=O.useContext(cfe);return e||t||"ltr"}var ln="Accordion",ffe=["Home","End","ArrowDown","ArrowUp","ArrowLeft","ArrowRight"],[ix,hfe,pfe]=pj(ln),[lm,Ope]=ni(ln,[pfe,F2]),ax=F2(),V2=j.forwardRef((e,t)=>{const{type:r,...n}=e,i=n,a=n;return p.jsx(ix.Provider,{scope:e.__scopeAccordion,children:r==="multiple"?p.jsx(yfe,{...a,ref:t}):p.jsx(gfe,{...i,ref:t})})});V2.displayName=ln;var[K2,mfe]=lm(ln),[G2,vfe]=lm(ln,{collapsible:!1}),gfe=j.forwardRef((e,t)=>{const{value:r,defaultValue:n,onValueChange:i=()=>{},collapsible:a=!1,...o}=e,[s,l]=eo({prop:r,defaultProp:n??"",onChange:i,caller:ln});return p.jsx(K2,{scope:e.__scopeAccordion,value:j.useMemo(()=>s?[s]:[],[s]),onItemOpen:l,onItemClose:j.useCallback(()=>a&&l(""),[a,l]),children:p.jsx(G2,{scope:e.__scopeAccordion,collapsible:a,children:p.jsx(Y2,{...o,ref:t})})})}),yfe=j.forwardRef((e,t)=>{const{value:r,defaultValue:n,onValueChange:i=()=>{},...a}=e,[o,s]=eo({prop:r,defaultProp:n??[],onChange:i,caller:ln}),l=j.useCallback(d=>s((c=[])=>[...c,d]),[s]),u=j.useCallback(d=>s((c=[])=>c.filter(f=>f!==d)),[s]);return p.jsx(K2,{scope:e.__scopeAccordion,value:o,onItemOpen:l,onItemClose:u,children:p.jsx(G2,{scope:e.__scopeAccordion,collapsible:!0,children:p.jsx(Y2,{...a,ref:t})})})}),[bfe,um]=lm(ln),Y2=j.forwardRef((e,t)=>{const{__scopeAccordion:r,disabled:n,dir:i,orientation:a="vertical",...o}=e,s=j.useRef(null),l=ft(s,t),u=hfe(r),c=dfe(i)==="ltr",f=be(e.onKeyDown,h=>{var k;if(!ffe.includes(h.key))return;const v=h.target,m=u().filter(P=>{var C;return!((C=P.ref.current)!=null&&C.disabled)}),g=m.findIndex(P=>P.ref.current===v),y=m.length;if(g===-1)return;h.preventDefault();let b=g;const w=0,_=y-1,x=()=>{b=g+1,b>_&&(b=w)},S=()=>{b=g-1,b<w&&(b=_)};switch(h.key){case"Home":b=w;break;case"End":b=_;break;case"ArrowRight":a==="horizontal"&&(c?x():S());break;case"ArrowDown":a==="vertical"&&x();break;case"ArrowLeft":a==="horizontal"&&(c?S():x());break;case"ArrowUp":a==="vertical"&&S();break}const E=b%y;(k=m[E].ref.current)==null||k.focus()});return p.jsx(bfe,{scope:r,disabled:n,direction:i,orientation:a,children:p.jsx(ix.Slot,{scope:r,children:p.jsx(Oe.div,{...o,"data-orientation":a,ref:l,onKeyDown:n?void 0:f})})})}),Th="AccordionItem",[wfe,ox]=lm(Th),X2=j.forwardRef((e,t)=>
357{const{__scopeAccordion:r,value:n,...i}=e,a=um(Th,r),o=mfe(Th,r),s=ax(r),l=Ia(),u=n&&o.value.includes(n)||!1,d=a.disabled||e.disabled;return p.jsx(wfe,{scope:r,open:u,disabled:d,triggerId:l,children:p.jsx(sfe,{"data-orientation":a.orientation,"data-state":rR(u),...s,...i,ref:t,disabled:d,open:u,onOpenChange:c=>{c?o.onItemOpen(n):o.onItemClose(n)}})})});X2.displayName=Th;var Q2="AccordionHeader",J2=j.forwardRef((e,t)=>{const{__scopeAccordion:r,...n}=e,i=um(ln,r),a=ox(Q2,r);return p.jsx(Oe.h3,{"data-orientation":i.orientation,"data-state":rR(a.open),"data-disabled":a.disabled?"":void 0,...n,ref:t})});J2.displayName=Q2;var A0="AccordionTrigger",Z2=j.forwardRef((e,t)=>{const{__scopeAccordion:r,...n}=e,i=um(ln,r),a=ox(A0,r),o=vfe(A0,r),s=ax(r);return p.jsx(ix.ItemSlot,{scope:r,children:p.jsx(lfe,{"aria-disabled":a.open&&!o.collapsible||void 0,"data-orientation":i.orientation,id:a.triggerId,...s,...n,ref:t})})});Z2.displayName=A0;var eR="AccordionContent",tR=j.forwardRef((e,t)=>{const{__scopeAccordion:r,...n}=e,i=um(ln,r),a=ox(eR,r),o=ax(r);return p.jsx(ufe,{role:"region","aria-labelledby":a.triggerId,"data-orientation":i.orientation,...o,...n,ref:t,style:{"--radix-accordion-content-height":"var(--radix-collapsible-content-height)","--radix-accordion-content-width":"var(--radix-collapsible-content-width)",...e.style}})});tR.displayName=eR;function rR(e){return e?"open":"closed"}var xfe=V2,_fe=X2,Sfe=J2,nR=Z2,iR=tR;const Ofe=xfe,aR=O.forwardRef(({className:e,...t},r)=>p.jsx(_fe,{ref:r,className:Ne("border-b",e),...t}));aR.displayName="AccordionItem";const oR=O.forwardRef(({className:e,children:t,...r},n)=>p.jsx(Sfe,{className:"flex",children:p.jsxs(nR,{ref:n,className:Ne("flex flex-1 items-center justify-between py-4 font-medium transition-all hover:underline [&[data-state=open]>svg]:rotate-180",e),...r,children:[t,p.jsx(Uj,{className:"h-4 w-4 shrink-0 transition-transform duration-200"})]})}));oR.displayName=nR.displayName;const sR=O.forwardRef(({className:e,children:t,...r},n)=>p.jsx(iR,{ref:n,className:"overflow-hidden text-sm transition-all data-[state=closed]:animate-accordion-up data-[state=open]:animate-accordion-down",...r,children:p.jsx("div",{className:Ne("pb-4 pt-0",e),children:t})}));sR.displayName=iR.displayName;const eu=e=>e.split(/\*\*(.*?)\*\*/g).map((r,n)=>n%2===1?p.jsx("strong",{className:"font-semibold text-foreground",children:r},n):p.jsx("span",{children:r},n));function Efe(e){if(!e)return null;const t=e.split(/(?:^|\s)(\d+\.\s)/),r=[];let n="";if(t.length>1){n=t[0].trim();for(let i=1;i<t.length;i+=2){const a=(t[i+1]||"").trim();a&&r.push(a)}}return r.length===0?p.jsx("p",{className:"text-sm leading-relaxed text-muted-foreground",children:eu(e)}):p.jsxs("div",{className:"space-y-3",children:[n&&p.jsx("p",{className:"text-sm leading-relaxed text-muted-foreground",children:eu(n)}),p.jsx("ol",{className:"space-y-2 list-none",children:r.map((i,a)=>p.jsxs("li",{className:"text-sm leading-relaxed text-muted-foreground flex gap-2.5",children:[p.jsxs("span",{className:"font-semibold text-primary shrink-0 mt-0.5",children:[a+1,"."]}),p.jsx("span",{children:eu(i)})]},a))})]})}function kfe({competitor:e}){const t=(e.communication_examples??[])[0];return p.jsx("p",{className:"text-sm text-muted-foreground line-clamp-2 pr-4",children:t||"Ingen sammanfattning tillgänglig."})}function lR({competitors:e,positioning:t}){const r=(e??[]).filter(n=>n!=null&&typeof n=="object"&&typeof n.name=="string"&&Array.isArray(n.communication_examples));return r.length===0&&!t?p.jsx(dr,{className:"border-border/50",children:p.jsx(fr,{className:"py-8 text-center text-muted-foreground",children:"Ingen konkurrentdata tillgänglig. Kör en ny analys för att se konkurrentjämförelse."})}):p.jsxs("div",{className:"space-y-6",children:[p.jsx(Ofe,{type:"multiple",className:"space-y-3",children:r.map((n,i)=>p.jsxs(aR,{value:`competitor-${i}`,className:"border border-border/50 rounded-lg px-4 bg-white data-[state=open]:bg-white",children:[p.jsx(oR,{className:"hover:no-underline py-4",children:p.jsxs("div",{className:"flex flex-col items-start gap-1.5 text-left",children:[p.jsxs("span",{className:"font-display text-base font-semibold flex items-center gap-2",children:[p.jsx(ZL,{className:"h-4 w-4 text-muted-foreground"}),n.name]}),p.jsx(kfe,{competitor:n})]})}),p.jsxs(sR,{className:"pb-5 space-y-4",children:[p.jsxs("div",{children:[p.jsxs("h4",{className:"text-sm font-semibold text-foreground flex items-center gap-1.5 mb-2",children:[p.jsx(JL,{className:"h-4 w-4 text-primary"}),"SÃ¥ kommunicerar de hÃ¥llbarhet"]}),p.jsx("ul",{className:"space-y-1.5",children:(n.communication_examples??[]).map((a,o)=>p.jsxs("li",{className:"text-sm leading-relaxed text-muted-foreground flex gap-2",children:[p.jsx("span",{className:"text-primary mt-0.5 shrink-0",children:"â¢"}),p.jsx("span",{children:a})]},o))})]}),p.jsxs("div",{className:"grid grid-cols-2 gap-4",children:[p.jsxs("div",{children:[p.jsxs("h4",{className:"text-sm font-semibold text-foreground flex items-center gap-1.5 mb-2",children:[p.jsx(XL,{className:"h-4 w-4 text-success"}),"Styrkor"]}),p.jsx("ul",{className:"space-y-1",children:(n.strengths??[]).map((a,o)=>p.jsxs("li",{className:"text-sm leading-relaxed text-muted-foreground flex gap-2",children:[p.jsx("span",{className:"text-success mt-0.5 shrink-0",children:"+"}),p.jsx("span",{children:eu(a)})]},o))})]}),p.jsxs("div",{children:[p.jsxs("h4",{className:"text-sm font-semibold text-foreground flex items-center gap-1.5 mb-2",children:[p.jsx(YL,{className:"h-4 w-4 text-destructive"}),"Svagheter"]}),p.jsx("ul",{className:"space-y-1",children:(n.weaknesses??[]).map((a,o)=>p.jsxs("li",{className:"text-sm leading-relaxed text-muted-foreground flex gap-2",children:[p.jsx("span",{className:"text-destructive mt-0.5 shrink-0",children:"â"}),p.jsx("span",{children:eu(a)})]},o))})]})]})]})]},i))}),t&&p.jsxs(dr,{className:"border-primary/30 bg-white",children:[p.jsx(Zr,{className:"pb-3",children:p.jsxs(en,{className:"font-display text-lg flex items-center gap-2 text-primary",children:[p.jsx(zL,{className:"h-5 w-5"}),"Er position att ta"]})}),p.jsx(fr,{children:Efe(t)})]}),t&&p.jsx("div",{className:"flex justify-center",children:p.jsx("a",{href:"#azote-section",className:"inline-flex items-center justify-center gap-2 rounded-md bg-primary text-primary-foreground hover:bg-primary/90 h-10 px-6 text-sm font-medium transition-colors",children:"Prata strategisk kommunikation med oss"})})]})}function Pfe({inspirations:e}){return p.jsxs(dr,{className:"border-border/50 bg-white",children:[p.jsx(Zr,{className:"pb-3",children:p.jsxs(en,{className:"font-display text-lg flex items-center gap-2",children:[p.jsx(HL,{className:"h-5 w-5 text-warning"}),"Strategisk kommunikation"]})}),p.jsx(fr,{className:"space-y-8",children:e.map((t,r)=>p.jsxs("div",{className:"space-y-3",children:[p.jsx("h4",{className:"font-display font-bold text-base text-foreground",children:t.angle}),p.jsx("p",{className:"text-sm text-muted-foreground leading-relaxed",children:t.description}),p.jsx("ul",{className:"space-y-2 mt-1",children:t.proofPoints.map((n,i)=>p.jsxs("li",{className:"flex items-start gap-2.5 text-sm leading-relaxed text-foreground",children:[p.jsx(jb,{className:"h-4 w-4 text-primary shrink-0 mt-0.5"}),p.jsx("span",{children:n})]},i))}),r<e.length-1&&p.jsx("div",{className:"border-b border-border/50 pt-2"})]},r))})]})}function uR({sources:e}){if(!e.length)return null;const t={};for(const n of e){const i=n.category||"Ãvrigt";t[i]||(t[i]=[]),t[i].push(n)}const r=Object.keys(t);return p.jsxs(dr,{className:"bg-white",children:[p.jsx(Zr,{children:p.jsxs(en,{className:"text-lg flex items-center gap-2",children:[p.jsx(_f,{className:"h-5 w-5"}),"Källor (",e.length,")"]})}),p.jsx(fr,{className:"space-y-6",children:r.map(n=>p.jsxs("div",{children:[p.jsx("h4",{className:"text-sm font-semibold text-muted-foreground uppercase tracking-wide mb-2",children:n}),p.jsx("ul",{className:"space-y-2",children:t[n].map((i,a)=>p.jsxs("li",{className:"flex items-start gap-3 text-sm",children:[i.type==="pdf"?p.jsx(_f,{className:"h-4 w-4 mt-0.5 text-muted-foreground shrink-0"}):p.jsx(qL,{className:"h-4 w-4 mt-0.5 text-muted-foreground shrink-0"}),p.jsx("div",{className:"min-w-0",children:i.url?p.jsxs("a",{href:i.url,target:"_blank",rel:"noopener noreferrer",className:"flex items-center gap-1 text-primary hover:underline break-all",children:[i.name,p.jsx(Wj,{className:"h-3 w-3 shrink-0"})]}):p.jsx("span",{className:"font-medium",children:i.name})})]},a))})]},n))})]})}const Afe={media:{label:"Media & PR",description:"Sökningen av pressreleaser, LinkedIn och media kunde inte genomföras. Analysen i detta avsnitt kan vara ofullständig."},competitors:{label:"Konkurrentanalys",description:"Konkurrentanalysen kunde inte genomföras. Jämförelsen i detta avsnitt kan vara ofullständig."}};function Ch({stepName:e}){const t=Afe[e];return t?p.jsxs("div",{className:"rounded-lg border border-warning/30 bg-warning/5 p-3 flex items-start gap-2.5 mb-4",children:[p.jsx(Vj,{className:"h-4 w-4 text-warning shrink-0 mt-0.5"}),p.jsxs("p",{className:"text-sm text-muted-foreground leading-relaxed",children:[p.jsxs("span",{className:"font-medium text-foreground",children:[t.label," hoppades över."]})," ",t.description]})]}):null}var Nv="focusScope.autoFocusOnMount",$v="focusScope.autoFocusOnUnmount",Tk={bubbles:!1,cancelable:!0},jfe="FocusScope",sx=O.forwardRef((e,t)=>
vendor: 4,277 bytes, line 357
357{const{loop:r=!1,trapped:n=!1,onMountAutoFocus:i,onUnmountAutoFocus:a,...o}=e,[s,l]=O.useState(null),u=kn(i),d=kn(a),c=O.useRef(null),f=ft(t,m=>l(m)),h=O.useRef({paused:!1,pause(){this.paused=!0},resume(){this.paused=!1}}).current;O.useEffect(()=>{if(n){let m=function(w){if(h.paused||!s)return;const _=w.target;s.contains(_)?c.current=_:gi(c.current,{select:!0})},g=function(w){if(h.paused||!s)return;const _=w.relatedTarget;_!==null&&(s.contains(_)||gi(c.current,{select:!0}))},y=function(w){if(document.activeElement===document.body)for(const x of w)x.removedNodes.length>0&&gi(s)};document.addEventListener("focusin",m),document.addEventListener("focusout",g);const b=new MutationObserver(y);return s&&b.observe(s,{childList:!0,subtree:!0}),()=>{document.removeEventListener("focusin",m),document.removeEventListener("focusout",g),b.disconnect()}}},[n,s,h.paused]),O.useEffect(()=>{if(s){Nk.add(h);const m=document.activeElement;if(!s.contains(m)){const y=new CustomEvent(Nv,Tk);s.addEventListener(Nv,u),s.dispatchEvent(y),y.defaultPrevented||(Tfe(Ife(cR(s)),{select:!0}),document.activeElement===m&&gi(s))}return()=>{s.removeEventListener(Nv,u),setTimeout(()=>{const y=new CustomEvent($v,Tk);s.addEventListener($v,d),s.dispatchEvent(y),y.defaultPrevented||gi(m??document.body,{select:!0}),s.removeEventListener($v,d),Nk.remove(h)},0)}}},[s,u,d,h]);const v=O.useCallback(m=>{if(!r&&!n||h.paused)return;const g=m.key==="Tab"&&!m.altKey&&!m.ctrlKey&&!m.metaKey,y=document.activeElement;if(g&&y){const b=m.currentTarget,[w,_]=Cfe(b);w&&_?!m.shiftKey&&y===_?(m.preventDefault(),r&&gi(w,{select:!0})):m.shiftKey&&y===w&&(m.preventDefault(),r&&gi(_,{select:!0})):y===b&&m.preventDefault()}},[r,n,h.paused]);return p.jsx(Oe.div,{tabIndex:-1,...o,ref:f,onKeyDown:v})});sx.displayName=jfe;function Tfe(e,{select:t=!1}={}){const r=document.activeElement;for(const n of e)if(gi(n,{select:t}),document.activeElement!==r)return}function Cfe(e){const t=cR(e),r=Ck(t,e),n=Ck(t.reverse(),e);return[r,n]}function cR(e){const t=[],r=document.createTreeWalker(e,NodeFilter.SHOW_ELEMENT,{acceptNode:n=>{const i=n.tagName==="INPUT"&&n.type==="hidden";return n.disabled||n.hidden||i?NodeFilter.FILTER_SKIP:n.tabIndex>=0?NodeFilter.FILTER_ACCEPT:NodeFilter.FILTER_SKIP}});for(;r.nextNode();)t.push(r.currentNode);return t}function Ck(e,t){for(const r of e)if(!Nfe(r,{upTo:t}))return r}function Nfe(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 $fe(e){return e instanceof HTMLInputElement&&"select"in e}function gi(e,{select:t=!1}={}){if(e&&e.focus){const r=document.activeElement;e.focus({preventScroll:!0}),e!==r&&$fe(e)&&t&&e.select()}}var Nk=Rfe();function Rfe(){let e=[];return{add(t){const r=e[0];t!==r&&(r==null||r.pause()),e=$k(e,t),e.unshift(t)},remove(t){var r;e=$k(e,t),(r=e[0])==null||r.resume()}}}function $k(e,t){const r=[...e],n=r.indexOf(t);return n!==-1&&r.splice(n,1),r}function Ife(e){return e.filter(t=>t.tagName!=="A")}var Rv=0;function dR(){O.useEffect(()=>{const e=document.querySelectorAll("[data-radix-focus-guard]");return document.body.insertAdjacentElement("afterbegin",e[0]??Rk()),document.body.insertAdjacentElement("beforeend",e[1]??Rk()),Rv++,()=>{Rv===1&&document.querySelectorAll("[data-radix-focus-guard]").forEach(t=>t.remove()),Rv--}},[])}function Rk(){const e=document.createElement("span");return e.setAttribute("data-radix-focus-guard",""),e.tabIndex=0,e.style.outline="none",e.style.opacity="0",e.style.position="fixed",e.style.pointerEvents="none",e}var Yd="right-scroll-bar-position",Xd="width-before-scroll-bar",Mfe="with-scroll-bars-hidden",Dfe="--removed-body-scroll-bar-size";function Iv(e,t){return typeof e=="function"?e(t):e&&(e.current=t),e}function Lfe(e,t){var r=O.useState(function(){return{value:e,callback:t,facade:{get current(){return r.value},set current(n){var i=r.value;i!==n&&(r.value=n,r.callback(n,i))}}}})[0];return r.callback=t,r.facade}var Bfe=typeof window<"u"?O.useLayoutEffect:O.useEffect,Ik=new WeakMap;function Ufe(e,t){var r=Lfe(null,function(n){return e.forEach(function(i){return Iv(i,n)})});return Bfe(function(){var n=Ik.get(r);if(n){var i=new Set(n),a=new Set(e),o=r.current;
vendor: 4,224 bytes, lines 357-372
357i.forEach(function(s){a.has(s)||Iv(s,null)}),a.forEach(function(s){i.has(s)||Iv(s,o)})}Ik.set(r,e)},[e]),r}function Ffe(e){return e}function zfe(e,t){t===void 0&&(t=Ffe);var r=[],n=!1,i={read:function(){if(n)throw new Error("Sidecar: could not `read` from an `assigned` medium. `read` could be used only with `useMedium`.");return r.length?r[r.length-1]:e},useMedium:function(a){var o=t(a,n);return r.push(o),function(){r=r.filter(function(s){return s!==o})}},assignSyncMedium:function(a){for(n=!0;r.length;){var o=r;r=[],o.forEach(a)}r={push:function(s){return a(s)},filter:function(){return r}}},assignMedium:function(a){n=!0;var o=[];if(r.length){var s=r;r=[],s.forEach(a),o=r}var l=function(){var d=o;o=[],d.forEach(a)},u=function(){return Promise.resolve().then(l)};u(),r={push:function(d){o.push(d),u()},filter:function(d){return o=o.filter(d),r}}}};return i}function Wfe(e){e===void 0&&(e={});var t=zfe(null);return t.options=yn({async:!0,ssr:!1},e),t}var fR=function(e){var t=e.sideCar,r=Qs(e,["sideCar"]);if(!t)throw new Error("Sidecar: please provide `sideCar` property to import the right car");var n=t.read();if(!n)throw new Error("Sidecar medium not found");return O.createElement(n,yn({},r))};fR.isSideCarExport=!0;function qfe(e,t){return e.useMedium(t),fR}var hR=Wfe(),Mv=function(){},cm=O.forwardRef(function(e,t){var r=O.useRef(null),n=O.useState({onScrollCapture:Mv,onWheelCapture:Mv,onTouchMoveCapture:Mv}),i=n[0],a=n[1],o=e.forwardProps,s=e.children,l=e.className,u=e.removeScrollBar,d=e.enabled,c=e.shards,f=e.sideCar,h=e.noRelative,v=e.noIsolation,m=e.inert,g=e.allowPinchZoom,y=e.as,b=y===void 0?"div":y,w=e.gapMode,_=Qs(e,["forwardProps","children","className","removeScrollBar","enabled","shards","sideCar","noRelative","noIsolation","inert","allowPinchZoom","as","gapMode"]),x=f,S=Ufe([r,t]),E=yn(yn({},_),i);return O.createElement(O.Fragment,null,d&&O.createElement(x,{sideCar:hR,removeScrollBar:u,shards:c,noRelative:h,noIsolation:v,inert:m,setCallbacks:a,allowPinchZoom:!!g,lockRef:r,gapMode:w}),o?O.cloneElement(O.Children.only(s),yn(yn({},E),{ref:S})):O.createElement(b,yn({},E,{className:l,ref:S}),s))});cm.defaultProps={enabled:!0,removeScrollBar:!0,inert:!1};cm.classNames={fullWidth:Xd,zeroRight:Yd};var Hfe=function(){if(typeof __webpack_nonce__<"u")return __webpack_nonce__};function Vfe(){if(!document)return null;var e=document.createElement("style");e.type="text/css";var t=Hfe();return t&&e.setAttribute("nonce",t),e}function Kfe(e,t){e.styleSheet?e.styleSheet.cssText=t:e.appendChild(document.createTextNode(t))}function Gfe(e){var t=document.head||document.getElementsByTagName("head")[0];t.appendChild(e)}var Yfe=function(){var e=0,t=null;return{add:function(r){e==0&&(t=Vfe())&&(Kfe(t,r),Gfe(t)),e++},remove:function(){e--,!e&&t&&(t.parentNode&&t.parentNode.removeChild(t),t=null)}}},Xfe=function(){var e=Yfe();return function(t,r){O.useEffect(function(){return e.add(t),function(){e.remove()}},[t&&r])}},pR=function(){var e=Xfe(),t=function(r){var n=r.styles,i=r.dynamic;return e(n,i),null};return t},Qfe={left:0,top:0,right:0,gap:0},Dv=function(e){return parseInt(e||"",10)||0},Jfe=function(e){var t=window.getComputedStyle(document.body),r=t[e==="padding"?"paddingLeft":"marginLeft"],n=t[e==="padding"?"paddingTop":"marginTop"],i=t[e==="padding"?"paddingRight":"marginRight"];return[Dv(r),Dv(n),Dv(i)]},Zfe=function(e){if(e===void 0&&(e="margin"),typeof window>"u")return Qfe;var t=Jfe(e),r=document.documentElement.clientWidth,n=window.innerWidth;return{left:t[0],top:t[1],right:t[2],gap:Math.max(0,n-r+t[2]-t[0])}},ehe=pR(),rs="data-scroll-locked",the=function(e,t,r,n){var i=e.left,a=e.top,o=e.right,s=e.gap;return r===void 0&&(r="margin"),` 358 .`.concat(Mfe,` { 359 overflow: hidden `).concat(n,`; 360 padding-right: `).concat(s,"px ").concat(n,`; 361 } 362 body[`).concat(rs,`] { 363 overflow: hidden `).concat(n,`; 364 overscroll-behavior: contain; 365 `).concat([t&&"position: relative ".concat(n,";"),r==="margin"&&` 366 padding-left: `.concat(i,`px; 367 padding-top: `).concat(a,`px; 368 padding-right: `).concat(o,`px; 369 margin-left:0; 370 margin-top:0; 371 margin-right: `).concat(s,"px ").concat(n,`; 372 `),r==="padding"&&"padding-right: ".concat(s,"px ").concat(n,";
372")].filter(Boolean).join(""),` 373 } 374 375 .`).concat(Yd,` { 376 right: `).concat(s,"px ").concat(n,`; 377 } 378 379 .`).concat(Xd,` { 380 margin-right: `).concat(s,"px ").concat(n,`; 381 } 382 383 .`).concat(Yd," .").concat(Yd,` { 384 right: 0 `).concat(n,`; 385 } 386 387 .`).concat(Xd," .").concat(Xd,` { 388 margin-right: 0 `).concat(n,`; 389 } 390 391 body[`).concat(rs,`] { 392 `).concat(Dfe,": ").concat(s,`px; 393 } 394`)},Mk=function(){var e=parseInt(document.body.getAttribute(rs)||"0",10);return isFinite(e)?e:0},rhe=function(){O.useEffect(function(){return document.body.setAttribute(rs,(Mk()+1).toString()),function(){var e=Mk()-1;e<=0?document.body.removeAttribute(rs):document.body.setAttribute(rs,e.toString())}},[])},nhe=function(e){var t=e.noRelative,r=e.noImportant,n=e.gapMode,i=n===void 0?"margin":n;rhe();var a=O.useMemo(function(){return Zfe(i)},[i]);return O.createElement(ehe,{styles:the(a,!t,i,r?"":"!important")})},j0=!1;if(typeof window<"u")try{var Ad=Object.defineProperty({},"passive",{get:function(){return j0=!0,!0}});window.addEventListener("test",Ad,Ad),window.removeEventListener("test",Ad,Ad)}catch{j0=!1}var wo=j0?{passive:!1}:!1,ihe=function(e){return e.tagName==="TEXTAREA"},mR=function(e,t){if(!(e instanceof Element))return!1;var r=window.getComputedStyle(e);return r[t]!=="hidden"&&!(r.overflowY===r.overflowX&&!ihe(e)&&r[t]==="visible")},ahe=function(e){return mR(e,"overflowY")},ohe=function(e){return mR(e,"overflowX")},Dk=function(e,t){var r=t.ownerDocument,n=t;do{typeof ShadowRoot<"u"&&n instanceof ShadowRoot&&(n=n.host);var i=vR(e,n);if(i){var a=gR(e,n),o=a[1],s=a[2];if(o>s)return!0}n=n.parentNode}while(n&&n!==r.body);return!1},she=function(e){var t=e.scrollTop,r=e.scrollHeight,n=e.clientHeight;return[t,r,n]},lhe=function(e){var t=e.scrollLeft,r=e.scrollWidth,n=e.clientWidth;return[t,r,n]},vR=function(e,t){return e==="v"?ahe(t):ohe(t)},gR=function(e,t){return e==="v"?she(t):lhe(t)},uhe=function(e,t){return e==="h"&&t==="rtl"?-1:1},che=function(e,t,r,n,i){var a=uhe(e,window.getComputedStyle(t).direction),o=a*n,s=r.target,l=t.contains(s),u=!1,d=o>0,c=0,f=0;do{if(!s)break;var h=gR(e,s),v=h[0],m=h[1],g=h[2],y=m-g-a*v;(v||y)&&vR(e,s)&&(c+=y,f+=v);var b=s.parentNode;s=b&&b.nodeType===Node.DOCUMENT_FRAGMENT_NODE?b.host:b}while(!l&&s!==document.body||l&&(t.contains(s)||t===s));return(d&&(Math.abs(c)<1||!i)||!d&&(Math.abs(f)<1||!i))&&(u=!0),u},jd=function(e){return"changedTouches"in e?[e.changedTouches[0].clientX,e.changedTouches[0].clientY]:[0,0]},Lk=function(e){return[e.deltaX,e.deltaY]},Bk=function(e){return e&&"current"in e?e.current:e},dhe=function(e,t){return e[0]===t[0]&&e[1]===t[1]},fhe=function(e){return` 395 .block-interactivity-`.concat(e,` {pointer-events: none;} 396 .allow-interactivity-`).concat(e,` {pointer-events: all;} 397`)},hhe=0,xo=[];function phe(e){var t=O.useRef([]),r=O.useRef([0,0]),n=O.useRef(),i=O.useState(hhe++)[0],a=O.useState(pR)[0],o=O.useRef(e);O.useEffect(function(){o.current=e},[e]),O.useEffect(function(){if(e.inert){document.body.classList.add("block-interactivity-".concat(i));var m=EU([e.lockRef.current],(e.shards||[]).map(Bk),!0).filter(Boolean);return m.forEach(function(g){return g.classList.add("allow-interactivity-".concat(i))}),function(){document.body.classList.remove("block-interactivity-".concat(i)),m.forEach(function(g){return g.classList.remove("allow-interactivity-".concat(i))})}}},[e.inert,e.lockRef.current,e.shards]);var s=O.useCallback(function(m,g){if("touches"in m&&m.touches.length===2||m.type==="wheel"&&m.ctrlKey)return!o.current.allowPinchZoom;var y=jd(m),b=r.current,w="deltaX"in m?m.deltaX:b[0]-y[0],_="deltaY"in m?m.deltaY:b[1]-y[1],x,S=m.target,E=Math.abs(w)>Math.abs(_)?"h":"v";if("touches"in m&&E==="h"&&S.type==="range")return!1;var k=Dk(E,S);if(!k)return!0;if(k?x=E:(x=E==="v"?"h":"v",k=Dk(E,S)),!k)return!1;if(!n.current&&"changedTouches"in m&&(w||_)&&(n.current=x),!x)return!0;var P=n.current||x;return che(P,g,m,P==="h"?w:_,!0)},[]),l=O.useCallback(function(m){var g=m;if(!(!xo.length||xo[xo.length-1]!==a)){var y="deltaY"in g?Lk(g):jd(g),b=t.current.filter(function(x){return x.name===g.type&&(x.target===g.target||g.target===x.shadowParent)&&dhe(x.delta,y)})[0];if(b&&b.should){g.cancelable&&g.preventDefault();return}
vendor: 4,355 bytes, line 397
397if(!b){var w=(o.current.shards||[]).map(Bk).filter(Boolean).filter(function(x){return x.contains(g.target)}),_=w.length>0?s(g,w[0]):!o.current.noIsolation;_&&g.cancelable&&g.preventDefault()}}},[]),u=O.useCallback(function(m,g,y,b){var w={name:m,delta:g,target:y,should:b,shadowParent:mhe(y)};t.current.push(w),setTimeout(function(){t.current=t.current.filter(function(_){return _!==w})},1)},[]),d=O.useCallback(function(m){r.current=jd(m),n.current=void 0},[]),c=O.useCallback(function(m){u(m.type,Lk(m),m.target,s(m,e.lockRef.current))},[]),f=O.useCallback(function(m){u(m.type,jd(m),m.target,s(m,e.lockRef.current))},[]);O.useEffect(function(){return xo.push(a),e.setCallbacks({onScrollCapture:c,onWheelCapture:c,onTouchMoveCapture:f}),document.addEventListener("wheel",l,wo),document.addEventListener("touchmove",l,wo),document.addEventListener("touchstart",d,wo),function(){xo=xo.filter(function(m){return m!==a}),document.removeEventListener("wheel",l,wo),document.removeEventListener("touchmove",l,wo),document.removeEventListener("touchstart",d,wo)}},[]);var h=e.removeScrollBar,v=e.inert;return O.createElement(O.Fragment,null,v?O.createElement(a,{styles:fhe(i)}):null,h?O.createElement(nhe,{noRelative:e.noRelative,gapMode:e.gapMode}):null)}function mhe(e){for(var t=null;e!==null;)e instanceof ShadowRoot&&(t=e.host,e=e.host),e=e.parentNode;return t}const vhe=qfe(hR,phe);var lx=O.forwardRef(function(e,t){return O.createElement(cm,yn({},e,{ref:t,sideCar:vhe}))});lx.classNames=cm.classNames;var ghe=function(e){if(typeof document>"u")return null;var t=Array.isArray(e)?e[0]:e;return t.ownerDocument.body},_o=new WeakMap,Td=new WeakMap,Cd={},Lv=0,yR=function(e){return e&&(e.host||yR(e.parentNode))},yhe=function(e,t){return t.map(function(r){if(e.contains(r))return r;var n=yR(r);return n&&e.contains(n)?n:(console.error("aria-hidden",r,"in not contained inside",e,". Doing nothing"),null)}).filter(function(r){return!!r})},bhe=function(e,t,r,n){var i=yhe(t,Array.isArray(e)?e:[e]);Cd[r]||(Cd[r]=new WeakMap);var a=Cd[r],o=[],s=new Set,l=new Set(i),u=function(c){!c||s.has(c)||(s.add(c),u(c.parentNode))};i.forEach(u);var d=function(c){!c||l.has(c)||Array.prototype.forEach.call(c.children,function(f){if(s.has(f))d(f);else try{var h=f.getAttribute(n),v=h!==null&&h!=="false",m=(_o.get(f)||0)+1,g=(a.get(f)||0)+1;_o.set(f,m),a.set(f,g),o.push(f),m===1&&v&&Td.set(f,!0),g===1&&f.setAttribute(r,"true"),v||f.setAttribute(n,"true")}catch(y){console.error("aria-hidden: cannot operate on ",f,y)}})};return d(t),s.clear(),Lv++,function(){o.forEach(function(c){var f=_o.get(c)-1,h=a.get(c)-1;_o.set(c,f),a.set(c,h),f||(Td.has(c)||c.removeAttribute(n),Td.delete(c)),h||c.removeAttribute(r)}),Lv--,Lv||(_o=new WeakMap,_o=new WeakMap,Td=new WeakMap,Cd={})}},bR=function(e,t,r){r===void 0&&(r="data-aria-hidden");var n=Array.from(Array.isArray(e)?e:[e]),i=ghe(e);return i?(n.push.apply(n,Array.from(i.querySelectorAll("[aria-live]"))),bhe(n,i,r,"aria-hidden")):function(){return null}},dm="Dialog",[wR,Epe]=ni(dm),[whe,un]=wR(dm),xR=e=>{const{__scopeDialog:t,children:r,open:n,defaultOpen:i,onOpenChange:a,modal:o=!0}=e,s=O.useRef(null),l=O.useRef(null),[u,d]=eo({prop:n,defaultProp:i??!1,onChange:a,caller:dm});return p.jsx(whe,{scope:t,triggerRef:s,contentRef:l,contentId:Ia(),titleId:Ia(),descriptionId:Ia(),open:u,onOpenChange:d,onOpenToggle:O.useCallback(()=>d(c=>!c),[d]),modal:o,children:r})};xR.displayName=dm;var _R="DialogTrigger",SR=O.forwardRef((e,t)=>{const{__scopeDialog:r,...n}=e,i=un(_R,r),a=ft(t,i.triggerRef);return p.jsx(Oe.button,{type:"button","aria-haspopup":"dialog","aria-expanded":i.open,"aria-controls":i.contentId,"data-state":dx(i.open),...n,ref:a,onClick:be(e.onClick,i.onOpenToggle)})});SR.displayName=_R;var ux="DialogPortal",[xhe,OR]=wR(ux,{forceMount:void 0}),ER=e=>{const{__scopeDialog:t,forceMount:r,children:n,container:i}=e,a=un(ux,t);return p.jsx(xhe,{scope:t,forceMount:r,children:O.Children.map(n,o=>p.jsx(ii,{present:r||a.open,children:p.jsx(Xh,{asChild:!0,container:i,children:o})}))})};ER.displayName=ux;var Nh="DialogOverlay",kR=O.forwardRef((e,t)=>{const r=OR(Nh,e.__scopeDialog),{forceMount:n=r.forceMount,...i}=e,a=un(Nh,e.__scopeDialog);return a.modal?p.jsx(ii,{present:n||a.open,children:p.jsx(She,{...i,ref:t})}):null});kR.displayName=Nh;var _he=ys("DialogOverlay.RemoveScroll"),She=O.forwardRef((e,t)=>
vendor: 4,662 bytes, lines 397-401
397{const{__scopeDialog:r,...n}=e,i=un(Nh,r);return p.jsx(lx,{as:_he,allowPinchZoom:!0,shards:[i.contentRef],children:p.jsx(Oe.div,{"data-state":dx(i.open),...n,ref:t,style:{pointerEvents:"auto",...n.style}})})}),Qa="DialogContent",PR=O.forwardRef((e,t)=>{const r=OR(Qa,e.__scopeDialog),{forceMount:n=r.forceMount,...i}=e,a=un(Qa,e.__scopeDialog);return p.jsx(ii,{present:n||a.open,children:a.modal?p.jsx(Ohe,{...i,ref:t}):p.jsx(Ehe,{...i,ref:t})})});PR.displayName=Qa;var Ohe=O.forwardRef((e,t)=>{const r=un(Qa,e.__scopeDialog),n=O.useRef(null),i=ft(t,r.contentRef,n);return O.useEffect(()=>{const a=n.current;if(a)return bR(a)},[]),p.jsx(AR,{...e,ref:i,trapFocus:r.open,disableOutsidePointerEvents:!0,onCloseAutoFocus:be(e.onCloseAutoFocus,a=>{var o;a.preventDefault(),(o=r.triggerRef.current)==null||o.focus()}),onPointerDownOutside:be(e.onPointerDownOutside,a=>{const o=a.detail.originalEvent,s=o.button===0&&o.ctrlKey===!0;(o.button===2||s)&&a.preventDefault()}),onFocusOutside:be(e.onFocusOutside,a=>a.preventDefault())})}),Ehe=O.forwardRef((e,t)=>{const r=un(Qa,e.__scopeDialog),n=O.useRef(!1),i=O.useRef(!1);return p.jsx(AR,{...e,ref:t,trapFocus:!1,disableOutsidePointerEvents:!1,onCloseAutoFocus:a=>{var o,s;(o=e.onCloseAutoFocus)==null||o.call(e,a),a.defaultPrevented||(n.current||(s=r.triggerRef.current)==null||s.focus(),a.preventDefault()),n.current=!1,i.current=!1},onInteractOutside:a=>{var l,u;(l=e.onInteractOutside)==null||l.call(e,a),a.defaultPrevented||(n.current=!0,a.detail.originalEvent.type==="pointerdown"&&(i.current=!0));const o=a.target;((u=r.triggerRef.current)==null?void 0:u.contains(o))&&a.preventDefault(),a.detail.originalEvent.type==="focusin"&&i.current&&a.preventDefault()}})}),AR=O.forwardRef((e,t)=>{const{__scopeDialog:r,trapFocus:n,onOpenAutoFocus:i,onCloseAutoFocus:a,...o}=e,s=un(Qa,r),l=O.useRef(null),u=ft(t,l);return dR(),p.jsxs(p.Fragment,{children:[p.jsx(sx,{asChild:!0,loop:!0,trapped:n,onMountAutoFocus:i,onUnmountAutoFocus:a,children:p.jsx(Sc,{role:"dialog",id:s.contentId,"aria-describedby":s.descriptionId,"aria-labelledby":s.titleId,"data-state":dx(s.open),...o,ref:u,onDismiss:()=>s.onOpenChange(!1)})}),p.jsxs(p.Fragment,{children:[p.jsx(khe,{titleId:s.titleId}),p.jsx(Ahe,{contentRef:l,descriptionId:s.descriptionId})]})]})}),cx="DialogTitle",jR=O.forwardRef((e,t)=>{const{__scopeDialog:r,...n}=e,i=un(cx,r);return p.jsx(Oe.h2,{id:i.titleId,...n,ref:t})});jR.displayName=cx;var TR="DialogDescription",CR=O.forwardRef((e,t)=>{const{__scopeDialog:r,...n}=e,i=un(TR,r);return p.jsx(Oe.p,{id:i.descriptionId,...n,ref:t})});CR.displayName=TR;var NR="DialogClose",$R=O.forwardRef((e,t)=>{const{__scopeDialog:r,...n}=e,i=un(NR,r);return p.jsx(Oe.button,{type:"button",...n,ref:t,onClick:be(e.onClick,()=>i.onOpenChange(!1))})});$R.displayName=NR;function dx(e){return e?"open":"closed"}var RR="DialogTitleWarning",[kpe,IR]=HD(RR,{contentName:Qa,titleName:cx,docsSlug:"dialog"}),khe=({titleId:e})=>{const t=IR(RR),r=`\`${t.contentName}\` requires a \`${t.titleName}\` for the component to be accessible for screen reader users. 398 399If you want to hide the \`${t.titleName}\`, you can wrap it with our VisuallyHidden component. 400 401For more information, see https://radix-ui.com/primitives/docs/components/${t.docsSlug}`;return O.useEffect(()=>{e&&(document.getElementById(e)||console.error(r))},[r,e]),null},Phe="DialogDescriptionWarning",Ahe=({contentRef:e,descriptionId:t})=>{const n=`Warning: Missing \`Description\` or \`aria-describedby={undefined}\` for {${IR(Phe).contentName}}.`;return O.useEffect(()=>{var a;const i=(a=e.current)==null?void 0:a.getAttribute("aria-describedby");t&&i&&(document.getElementById(t)||console.warn(n))},[n,e,t]),null},jhe=xR,The=SR,Che=ER,MR=kR,DR=PR,LR=jR,BR=CR,Nhe=$R;const UR=jhe,$he=The,Rhe=Che,FR=O.forwardRef(({className:e,...t},r)=>p.jsx(MR,{ref:r,className:Ne("fixed inset-0 z-50 bg-black/80 data-[state=open]:animate-in data-[state=closed]:animate-out data-[state=closed]:fade-out-0 data-[state=open]:fade-in-0",e),...t}));FR.displayName=MR.displayName;const fx=O.forwardRef(({className:e,children:t,...r},n)=>p.jsxs(Rhe,{children:[p.jsx(FR,{}),p.jsxs(DR,{ref:n,className:Ne("fixed left-[50%] top-[50%] z-50 grid w-full max-w-lg translate-x-[-50%] translate-y-[-50%] gap-4 border bg-background p-6 shadow-lg duration-200 data-[state=open]:animate-in data-[state=closed]:animate-out data-[state=closed]:fade-out-0 data-[state=open]:fade-in-0 data-[state=closed]:zoom-out-95 data-[state=open]:zoom-in-95 data-[state=closed]:slide-out-to-left-1/2 data-[state=closed]:slide-out-to-top-[48%] data-[state=open]:slide-in-from-left-1/2 data-[state=open]:slide-in-from-top-[48%] sm:rou
401nded-lg",e),...r,children:[t,p.jsxs(Nhe,{className:"absolute right-4 top-4 rounded-sm opacity-70 ring-offset-background transition-opacity data-[state=open]:bg-accent data-[state=open]:text-muted-foreground hover:opacity-100 focus:outline-none focus:ring-2 focus:ring-ring focus:ring-offset-2 disabled:pointer-events-none",children:[p.jsx(Zh,{className:"h-4 w-4"}),p.jsx("span",{className:"sr-only",children:"Close"})]})]})]}));fx.displayName=DR.displayName;const hx=({className:e,...t})=>p.jsx("div",{className:Ne("flex flex-col space-y-1.5 text-center sm:text-left",e),...t});hx.displayName="DialogHeader";const px=O.forwardRef(({className:e,...t},r)=>p.jsx(LR,{ref:r,className:Ne("text-lg font-semibold leading-none tracking-tight",e),...t}));px.displayName=LR.displayName;const zR=O.forwardRef(({className:e,...t},r)=>p.jsx(BR,{ref:r,className:Ne("text-sm text-muted-foreground",e),...t}));zR.displayName=BR.displayName;var Ihe="Label",WR=O.forwardRef((e,t)=>p.jsx(Oe.label,{...e,ref:t,onMouseDown:r=>{var i;r.target.closest("button, input, select, textarea")||((i=e.onMouseDown)==null||i.call(e,r),!r.defaultPrevented&&r.detail>1&&r.preventDefault())}}));WR.displayName=Ihe;var qR=WR;const Mhe=Ab("text-sm font-medium leading-none peer-disabled:cursor-not-allowed peer-disabled:opacity-70"),rn=O.forwardRef(({className:e,...t},r)=>p.jsx(qR,{ref:r,className:Ne(Mhe(),e),...t}));rn.displayName=qR.displayName;var mx="Progress",vx=100,[Dhe,Ppe]=ni(mx),[Lhe,Bhe]=Dhe(mx),HR=O.forwardRef((e,t)=>{const{__scopeProgress:r,value:n=null,max:i,getValueLabel:a=Uhe,...o}=e;(i||i===0)&&!Uk(i)&&console.error(Fhe(`${i}`,"Progress"));const s=Uk(i)?i:vx;n!==null&&!Fk(n,s)&&console.error(zhe(`${n}`,"Progress"));const l=Fk(n,s)?n:null,u=$h(l)?a(l,s):void 0;return p.jsx(Lhe,{scope:r,value:l,max:s,children:p.jsx(Oe.div,{"aria-valuemax":s,"aria-valuemin":0,"aria-valuenow":$h(l)?l:void 0,"aria-valuetext":u,role:"progressbar","data-state":GR(l,s),"data-value":l??void 0,"data-max":s,...o,ref:t})})});HR.displayName=mx;var VR="ProgressIndicator",KR=O.forwardRef((e,t)=>{const{__scopeProgress:r,...n}=e,i=Bhe(VR,r);return p.jsx(Oe.div,{"data-state":GR(i.value,i.max),"data-value":i.value??void 0,"data-max":i.max,...n,ref:t})});KR.displayName=VR;function Uhe(e,t){return`${Math.round(e/t*100)}%`}function GR(e,t){return e==null?"indeterminate":e===t?"complete":"loading"}function $h(e){return typeof e=="number"}function Uk(e){return $h(e)&&!isNaN(e)&&e>0}function Fk(e,t){return $h(e)&&!isNaN(e)&&e<=t&&e>=0}function Fhe(e,t){return`Invalid prop \`max\` of value \`${e}\` supplied to \`${t}\`. Only numbers greater than 0 are valid max values. Defaulting to \`${vx}\`.`}function zhe(e,t){return`Invalid prop \`value\` of value \`${e}\` supplied to \`${t}\`. The \`value\` prop must be: 402 - a positive number 403 - less than the value passed to \`max\` (or ${vx} if no \`max\` prop is set) 404 - \`null\` or \`undefined\` if the progress is indeterminate. 405 406Defaulting to \`null\`.`}var YR=HR,Whe=KR;const gx=O.forwardRef(({className:e,value:t,...r},n)=>p.jsx(YR,{ref:n,className:Ne("relative h-4 w-full overflow-hidden rounded-full bg-secondary",e),...r,children:p.jsx(Whe,{className:"h-full w-full flex-1 bg-primary transition-all",style:{transform:`translateX(-${100-(t||0)}%)`}})}));gx.displayName=YR.displayName;function qhe(e){try{const r=new URL(e).hostname.replace(/^www\./,"").split(".")[0];return r.charAt(0).toUpperCase()+r.slice(1)}catch{return"Hållbarhetsanalys"}}function zk({onAnalysisCreated:e,trigger:t}={}){const[r,n]=O.useState(!1),[i,a]=O.useState(""),[o,s]=O.useState(""),[l,u]=O.useState([]),[d,c]=O.useState(!1),[f,h]=O.useState(0),[v,m]=O.useState(null),g=O.useRef(null),{toast:y}=Zi(),b=S=>{if(S.target.files){const E=Array.from(S.target.files).filter(k=>k.type==="application/pdf");E.length!==Array.from(S.target.files).length&&y({title:"Fel",description:"Endast PDF-filer stöds.",variant:"destructive"}),u(k=>[...k,...E])}},w=S=>{u(E=>E.filter((k,P)=>P!==S))},_=()=>{a(""),s(""),u([]),h(0),m(null),c(!1)},x=async S=>{if(S.preventDefault(),l.length===0){y({title:"Fyll i alla fält",description:"Minst en PDF-rapport krävs.",variant:"destructive"});return}const E=o?qhe(o):"Hållbarhetsanalys";c(!0),m("Skapar analysprojekt..."),h(10);let k=null;try{const{data:{user:P}}=await te.auth.getUser();if(!P){y({title:"Ej inloggad",description:"Logga in för att skapa en analys.",variant:"destructive"}),c(!1);return}const{data:C,error:N}=await te.from("analysis_projects").insert({name:E,website_url:o||null,user_id:P.id,status:"draft",notification_email:i||null}).select().single();if(N||!C)throw N??new Error("Kunde inte skapa projekt");k=C.id,h(30),m("Laddar upp rapporter...");for(let I=0;I<l.length;I++){const R=l[I],M=R.name.replace(/[^a-zA-Z0-9._-]/g,"_"),L=`${P.id}/${C.id}/${Date.now()}_${M}
406`,{error:A}=await te.storage.from("reports").upload(L,R);if(A)throw A;const{error:T}=await te.from("documents").insert({project_id:C.id,user_id:P.id,file_name:R.name,file_path:L,doc_type:"report"});if(T)throw T;h(30+Math.round((I+1)/l.length*40))}h(80),m("Startar AI-analys i bakgrunden...");const{error:$}=await te.from("analysis_projects").update({status:"processing"}).eq("id",C.id);if($)throw $;const{error:D}=await te.functions.invoke("analyze",{body:{project_id:C.id}});if(D)throw D;h(100),m("Analysen har startats!"),y({title:"Analysen har startats!",description:"Du kan följa framstegen på dashboarden. Vi meddelar dig när den är klar."}),setTimeout(()=>{const I=C.id;_(),n(!1),e==null||e(I)},1e3)}catch(P){console.error("Error creating analysis:",P),k&&await te.from("analysis_projects").update({status:"error"}).eq("id",k),y({title:"Något gick fel",description:P.message||"Kunde inte skapa analysen.",variant:"destructive"}),c(!1),m(null),h(0)}};return p.jsxs(UR,{open:r,onOpenChange:S=>{n(S),S||_()},children:[p.jsx($he,{asChild:!0,children:t||p.jsxs(je,{variant:"outline",size:"sm",className:"gap-2",children:[p.jsx(qj,{className:"h-3.5 w-3.5"}),"Ny analys"]})}),p.jsxs(fx,{className:"sm:max-w-lg",children:[p.jsx(hx,{children:p.jsx(px,{className:"font-display text-xl",children:"Skapa ny analys"})}),p.jsxs("form",{onSubmit:x,className:"space-y-5 mt-2",children:[p.jsxs("div",{className:"space-y-2",children:[p.jsxs(rn,{htmlFor:"notification-email",children:["E-postadress ",p.jsx("span",{className:"text-muted-foreground font-normal",children:"(för att få resultatet skickat till dig)"})]}),p.jsx(Kt,{id:"notification-email",type:"email",placeholder:"[email protected]",value:i,onChange:S=>a(S.target.value),disabled:d})]}),p.jsxs("div",{className:"space-y-2",children:[p.jsxs(rn,{htmlFor:"website-url",children:["Webbplats-URL ",p.jsx("span",{className:"text-muted-foreground font-normal",children:"(valfritt)"})]}),p.jsx(Kt,{id:"website-url",type:"url",placeholder:"https://www.dittforetag.se",value:o,onChange:S=>s(S.target.value),disabled:d})]}),p.jsxs("div",{className:"space-y-2",children:[p.jsx(rn,{children:"Hållbarhetsrapport (PDF)"}),p.jsx("input",{ref:g,type:"file",accept:".pdf",multiple:!0,className:"hidden",onChange:b}),p.jsxs(je,{type:"button",variant:"outline",className:"w-full gap-2 border-dashed",onClick:()=>{var S;return(S=g.current)==null?void 0:S.click()},disabled:d,children:[p.jsx(Kj,{className:"h-4 w-4"}),"Ladda upp PDF-rapporter"]}),l.length>0&&p.jsx("div",{className:"space-y-2 mt-3",children:l.map((S,E)=>p.jsxs("div",{className:"flex items-center gap-2 rounded-md border border-border/50 bg-muted/30 px-3 py-2 text-sm",children:[p.jsx(_f,{className:"h-4 w-4 text-muted-foreground shrink-0"}),p.jsx("span",{className:"truncate flex-1",children:S.name}),p.jsxs("span",{className:"text-muted-foreground text-xs shrink-0",children:[(S.size/1024/1024).toFixed(1)," MB"]}),!d&&p.jsx("button",{type:"button",onClick:()=>w(E),className:"text-muted-foreground hover:text-foreground",children:p.jsx(Zh,{className:"h-3.5 w-3.5"})})]},E))})]}),d&&p.jsxs("div",{className:"space-y-2",children:[p.jsx(gx,{value:f,className:"h-2"}),p.jsxs("p",{className:"text-xs text-muted-foreground flex items-center gap-2",children:[p.jsx(Rt,{className:"h-3 w-3 animate-spin"}),v]})]}),p.jsx(je,{type:"submit",className:"w-full font-semibold",disabled:d,children:d?"Bearbetar...":"Starta analys"})]})]})]})}const Hhe=[{key:"pdf",label:"Extraherar text från hållbarhetsrapport"},{key:"website",label:"Analyserar webbplatsens kommunikation"},{key:"media",label:"Söker pressreleaser, LinkedIn & media"},{key:"competitors",label:"Analyserar konkurrenters kommunikation"},{key:"synthesize",label:"Sammanställer slutgiltig analys"}];function Vhe({status:e,projectId:t}){const[r,n]=O.useState([]);O.useEffect(()=>{const l=async()=>{const{data:d}=await te.from("analysis_steps").select("step_name, status, error_message").eq("project_id",t).order("created_at",{ascending:!0});d&&n(d)};l();const u=te.channel(`steps-${t}`).on("postgres_changes",{event:"*",schema:"public",table:"analysis_steps",filter:`project_id=eq.${t}`},()=>l()).subscribe();return()=>{te.removeChannel(u)}},[t]);const i=l=>r.find(u=>u.step_name===l),a=l=>{const u=i(l);return u?u.status:"pending"},o=e==="error",s=r.find(l=>l.status==="error");return p.jsxs("div",{className:"flex flex-col items-center py-16 space-y-8 max-w-md mx-auto",children:[p.jsx("div",{className:"w-full space-y-3",children:Hhe.map(l=>
vendor: 4,623 bytes, line 406
406{const u=a(l.key),d=i(l.key);return p.jsxs("div",{className:"space-y-1",children:[p.jsxs("div",{className:"flex items-center gap-3",children:[u==="complete"?p.jsx(jb,{className:"h-5 w-5 text-primary shrink-0"}):u==="in_progress"?p.jsx(Rt,{className:"h-5 w-5 animate-spin text-primary shrink-0"}):u==="error"?p.jsx(Fj,{className:"h-5 w-5 text-destructive shrink-0"}):p.jsx(zj,{className:"h-5 w-5 text-muted-foreground/40 shrink-0"}),p.jsx("span",{className:u==="complete"?"text-sm text-foreground":u==="in_progress"?"text-sm font-medium text-foreground":u==="error"?"text-sm text-destructive font-medium":"text-sm text-muted-foreground/60",children:l.label})]}),u==="error"&&(d==null?void 0:d.error_message)&&p.jsx("p",{className:"text-xs text-destructive/80 ml-8 leading-relaxed",children:d.error_message})]},l.key)})}),o&&s&&p.jsxs("div",{className:"rounded-lg border border-destructive/30 bg-destructive/5 p-4 w-full space-y-2",children:[p.jsx("p",{className:"text-sm text-destructive font-medium",children:s.error_message||"Ett okänt fel inträffade under analysen."}),p.jsx("p",{className:"text-xs text-muted-foreground",children:"Kontrollera att PDF-filen inte är lösenordsskyddad eller skannad, och att webbplatsadressen stämmer. Försök sedan skapa en ny analys."})]}),!o&&p.jsx("p",{className:"text-muted-foreground text-sm text-center",children:"Analysen söker igenom rapport, webbplats, media och konkurrenter. Detta kan ta några minuter."})]})}var fm="Popover",[XR,Ape]=ni(fm,[np]),$c=np(),[Khe,aa]=XR(fm),QR=e=>{const{__scopePopover:t,children:r,open:n,defaultOpen:i,onOpenChange:a,modal:o=!1}=e,s=$c(t),l=O.useRef(null),[u,d]=O.useState(!1),[c,f]=eo({prop:n,defaultProp:i??!1,onChange:a,caller:fm});return p.jsx(ET,{...s,children:p.jsx(Khe,{scope:t,contentId:Ia(),triggerRef:l,open:c,onOpenChange:f,onOpenToggle:O.useCallback(()=>f(h=>!h),[f]),hasCustomAnchor:u,onCustomAnchorAdd:O.useCallback(()=>d(!0),[]),onCustomAnchorRemove:O.useCallback(()=>d(!1),[]),modal:o,children:r})})};QR.displayName=fm;var JR="PopoverAnchor",Ghe=O.forwardRef((e,t)=>{const{__scopePopover:r,...n}=e,i=aa(JR,r),a=$c(r),{onCustomAnchorAdd:o,onCustomAnchorRemove:s}=i;return O.useEffect(()=>(o(),()=>s()),[o,s]),p.jsx(zb,{...a,...n,ref:t})});Ghe.displayName=JR;var ZR="PopoverTrigger",eI=O.forwardRef((e,t)=>{const{__scopePopover:r,...n}=e,i=aa(ZR,r),a=$c(r),o=ft(t,i.triggerRef),s=p.jsx(Oe.button,{type:"button","aria-haspopup":"dialog","aria-expanded":i.open,"aria-controls":i.contentId,"data-state":aI(i.open),...n,ref:o,onClick:be(e.onClick,i.onOpenToggle)});return i.hasCustomAnchor?s:p.jsx(zb,{asChild:!0,...a,children:s})});eI.displayName=ZR;var yx="PopoverPortal",[Yhe,Xhe]=XR(yx,{forceMount:void 0}),tI=e=>{const{__scopePopover:t,forceMount:r,children:n,container:i}=e,a=aa(yx,t);return p.jsx(Yhe,{scope:t,forceMount:r,children:p.jsx(ii,{present:r||a.open,children:p.jsx(Xh,{asChild:!0,container:i,children:n})})})};tI.displayName=yx;var zs="PopoverContent",rI=O.forwardRef((e,t)=>{const r=Xhe(zs,e.__scopePopover),{forceMount:n=r.forceMount,...i}=e,a=aa(zs,e.__scopePopover);return p.jsx(ii,{present:n||a.open,children:a.modal?p.jsx(Jhe,{...i,ref:t}):p.jsx(Zhe,{...i,ref:t})})});rI.displayName=zs;var Qhe=ys("PopoverContent.RemoveScroll"),Jhe=O.forwardRef((e,t)=>{const r=aa(zs,e.__scopePopover),n=O.useRef(null),i=ft(t,n),a=O.useRef(!1);return O.useEffect(()=>{const o=n.current;if(o)return bR(o)},[]),p.jsx(lx,{as:Qhe,allowPinchZoom:!0,children:p.jsx(nI,{...e,ref:i,trapFocus:r.open,disableOutsidePointerEvents:!0,onCloseAutoFocus:be(e.onCloseAutoFocus,o=>{var s;o.preventDefault(),a.current||(s=r.triggerRef.current)==null||s.focus()}),onPointerDownOutside:be(e.onPointerDownOutside,o=>{const s=o.detail.originalEvent,l=s.button===0&&s.ctrlKey===!0,u=s.button===2||l;a.current=u},{checkForDefaultPrevented:!1}),onFocusOutside:be(e.onFocusOutside,o=>o.preventDefault(),{checkForDefaultPrevented:!1})})})}),Zhe=O.forwardRef((e,t)=>{const r=aa(zs,e.__scopePopover),n=O.useRef(!1),i=O.useRef(!1);return p.jsx(nI,{...e,ref:t,trapFocus:!1,disableOutsidePointerEvents:!1,onCloseAutoFocus:a=>{var o,s;(o=e.onCloseAutoFocus)==null||o.call(e,a),a.defaultPrevented||(n.current||(s=r.triggerRef.current)==null||s.focus(),a.preventDefault()),n.current=!1,i.current=!1},onInteractOutside:a=>{var l,u;(l=e.onInteractOutside)==null||l.call(e,a),a.defaultPrevented||(n.current=!0,a.detail.originalEvent.type==="pointerdown"&&(i.current=!0));const o=a.target;((u=r.triggerRef.current)==null?void 0:u.contains(o))&&a.preventDefault(),a.detail.originalEvent.type==="focusin"&&i.current&&a.preventDefault()}})}),nI=O.forwardRef((e,t)=>
406{const{__scopePopover:r,trapFocus:n,onOpenAutoFocus:i,onCloseAutoFocus:a,disableOutsidePointerEvents:o,onEscapeKeyDown:s,onPointerDownOutside:l,onFocusOutside:u,onInteractOutside:d,...c}=e,f=aa(zs,r),h=$c(r);return dR(),p.jsx(sx,{asChild:!0,loop:!0,trapped:n,onMountAutoFocus:i,onUnmountAutoFocus:a,children:p.jsx(Sc,{asChild:!0,disableOutsidePointerEvents:o,onInteractOutside:d,onEscapeKeyDown:s,onPointerDownOutside:l,onFocusOutside:u,onDismiss:()=>f.onOpenChange(!1),children:p.jsx(kT,{"data-state":aI(f.open),role:"dialog",id:f.contentId,...h,...c,ref:t,style:{...c.style,"--radix-popover-content-transform-origin":"var(--radix-popper-transform-origin)","--radix-popover-content-available-width":"var(--radix-popper-available-width)","--radix-popover-content-available-height":"var(--radix-popper-available-height)","--radix-popover-trigger-width":"var(--radix-popper-anchor-width)","--radix-popover-trigger-height":"var(--radix-popper-anchor-height)"}})})})}),iI="PopoverClose",epe=O.forwardRef((e,t)=>{const{__scopePopover:r,...n}=e,i=aa(iI,r);return p.jsx(Oe.button,{type:"button",...n,ref:t,onClick:be(e.onClick,()=>i.onOpenChange(!1))})});epe.displayName=iI;var tpe="PopoverArrow",rpe=O.forwardRef((e,t)=>{const{__scopePopover:r,...n}=e,i=$c(r);return p.jsx(PT,{...i,...n,ref:t})});rpe.displayName=tpe;function aI(e){return e?"open":"closed"}var npe=QR,ipe=eI,ape=tI,oI=rI;const hc=npe,pc=ipe,Ws=O.forwardRef(({className:e,align:t="center",sideOffset:r=4,...n},i)=>p.jsx(ape,{children:p.jsx(oI,{ref:i,align:t,sideOffset:r,className:Ne("z-50 w-72 rounded-md border bg-popover p-4 text-popover-foreground shadow-md outline-none data-[state=open]:animate-in data-[state=closed]:animate-out data-[state=closed]:fade-out-0 data-[state=open]:fade-in-0 data-[state=closed]:zoom-out-95 data-[state=open]:zoom-in-95 data-[side=bottom]:slide-in-from-top-2 data-[side=left]:slide-in-from-right-2 data-[side=right]:slide-in-from-left-2 data-[side=top]:slide-in-from-bottom-2",e),...n})}));Ws.displayName=oI.displayName;function ope({project:e,onProjectUpdated:t}){const{toast:r}=Zi(),[n,i]=O.useState(null),[a,o]=O.useState(!1),s=async l=>{if(!l){i(null);return}let u=e;if(u.internal_url_parameter){i({url:u.internal_url_parameter});return}if(!u.public_token||!u.share_password){o(!0);const c=crypto.randomUUID(),f=Array.from(crypto.getRandomValues(new Uint8Array(4))).map(m=>m.toString(36).slice(-1)).join("").toUpperCase().slice(0,6),h=`${window.location.origin}/analys/${c}?pw=${encodeURIComponent(f)}`,{error:v}=await te.from("analysis_projects").update({is_public:!0,public_token:c,share_password:f,internal_url_parameter:h}).eq("id",u.id);if(o(!1),v){r({title:"Kunde inte generera länk",variant:"destructive"});return}t({id:u.id,public_token:c,share_password:f,internal_url_parameter:h}),u={...u,public_token:c,share_password:f,internal_url_parameter:h}}const d=u.internal_url_parameter||`${window.location.origin}/analys/${u.public_token}?pw=${encodeURIComponent(u.share_password)}`;i({url:d})};return p.jsxs(hc,{onOpenChange:s,children:[p.jsx(pc,{asChild:!0,children:p.jsxs(je,{variant:"outline",size:"sm",className:"gap-2",children:[p.jsx(Hj,{className:"h-3.5 w-3.5"}),"Kopiera säker länk"]})}),p.jsx(Ws,{align:"start",className:"w-80 space-y-3",children:a?p.jsx("div",{className:"flex justify-center py-4",children:p.jsx(Rt,{className:"h-5 w-5 animate-spin"})}):n?p.jsxs(p.Fragment,{children:[p.jsx("p",{className:"text-sm font-semibold",children:"Kopiera säker länk"}),p.jsxs("div",{className:"space-y-1.5",children:[p.jsx(rn,{className:"text-xs",children:"Länk"}),p.jsxs("div",{className:"flex gap-1.5",children:[p.jsx(Kt,{readOnly:!0,value:n.url,className:"text-xs h-8"}),p.jsx(je,{variant:"outline",size:"icon",className:"shrink-0 h-8 w-8",onClick:()=>{navigator.clipboard.writeText(n.url),r({title:"Länk kopierad"})},children:p.jsx(Kd,{className:"h-3.5 w-3.5"})})]})]})]}):null})]})}function spe(){var I;Zi();const{isAdmin:e,loading:t}=Xb(),r=ea(),[n]=xU(),[i,a]=O.useState(!1),[o,s]=O.useState(!0),[l,u]=O.useState([]),[d,c]=O.useState(null),[f,h]=O.useState(null),[v,m]=O.useState(!1),[g,y]=O.useState([]),[b,w]=O.useState(!1),[_,x]=O.useState([]),[S,E]=O.useState([]);O.useEffect(()=>{if(t)return;te.auth.getSession().then(({data:{session:M}})=>{M?k():r("/",{replace:!0})});const{data:{subscription:R}}=te.auth.onAuthStateChange((M,L)=>{L||r("/",{replace:!0})});return()=>R.unsubscribe()},[r,t]),O.useEffect(()=>{const R=te.channel("project-status").on("postgres_changes",{event:"UPDATE",schema:"public",table:"analysis_projects"},M=>{const L=M.new;u(A=>A.map(T=>T.id===L.id?{...T,status:L.status}:T)),L.status==="complete"&&L.id===d&&P(L.id)}).subscribe();return()=>{te.removeChannel(R)}},[d]),O.useEffect(()=>{document.documentElement.classList.toggle("dark",i)},[i]);const k=O.useCallback(async()=>{const{data:{session:R}}=await te.auth.getSession();if(!R)return;let M=te.from("analysis_projects").select("id, name, status, created_at, website_url, public_token, share_password, internal_url_parameter").order("created_at",{ascending:!1});e||(M=M.eq("user_id",R.user.id));const{data:L}=await M;u(L||[]);const A=n.get("project");
406if(A&&(L||[]).find(T=>T.id===A))c(A),P(A);else{const T=(L||[]).find(U=>U.status==="complete");T&&(c(T.id),P(T.id))}s(!1)},[e]),P=async R=>{m(!0);const[{data:M},{data:L},{data:A},{data:T}]=await Promise.all([te.from("analysis_results").select("*").eq("project_id",R).order("created_at",{ascending:!1}).limit(1).single(),te.from("documents").select("file_name, doc_type").eq("project_id",R),te.from("analysis_steps").select("step_name, result").eq("project_id",R).eq("status","complete"),te.from("analysis_steps").select("step_name").eq("project_id",R).eq("status","error")]);h(M),y(L||[]);const U=[];for(const q of L||[])U.push({type:"pdf",name:q.file_name,category:"Uppladdade dokument"});for(const q of A||[]){const B=q.result;if(q.step_name==="website"&&(B!=null&&B.scraped_urls))for(const W of B.scraped_urls)U.push({type:"url",name:W,url:W,category:"Företagets webbplats"});if(q.step_name==="media"&&(B!=null&&B.media_urls))for(const W of B.media_urls)U.push({type:"url",name:W.title||W.url,url:W.url,category:"Media & extern kommunikation"});if(q.step_name==="competitors"&&(B!=null&&B.competitor_urls))for(const W of B.competitor_urls)U.push({type:"url",name:W.title||W.url,url:W.url,category:`Konkurrent: ${W.competitor}`})}x(U),E((T||[]).map(q=>q.step_name)),m(!1)},C=R=>{c(R),P(R)};if(o)return p.jsx("div",{className:"min-h-screen flex items-center justify-center bg-background",children:p.jsx(Rt,{className:"h-8 w-8 animate-spin text-primary"})});const N=async()=>{await te.auth.signOut(),r("/")},$=async R=>{await te.from("analysis_steps").delete().eq("project_id",R),await te.from("analysis_results").delete().eq("project_id",R),await te.from("documents").delete().eq("project_id",R),await te.from("analysis_projects").delete().eq("id",R),d===R&&(c(null),h(null)),u(M=>M.filter(L=>L.id!==R))},D=l.find(R=>R.id===d);return p.jsxs("div",{className:"min-h-screen relative overflow-hidden",children:[p.jsx("div",{className:"absolute inset-0 pointer-events-none",style:{background:"linear-gradient(45deg, hsl(27 40% 57% / 0.15) 0%, hsl(27 35% 75% / 0.1) 40%, hsl(24 33% 94%) 100%)"}}),p.jsx("header",{className:"relative sticky top-0 z-50 border-b border-border/50 bg-white/40 backdrop-blur-sm",children:p.jsx("div",{className:"container flex h-14 items-center justify-end",children:p.jsxs("div",{className:"flex items-center gap-2",children:[p.jsx(zk,{onAnalysisCreated:R=>{k().then(()=>{c(R),h(null)})}}),p.jsx(je,{variant:"ghost",size:"icon",onClick:()=>a(!i),children:i?p.jsx(QL,{className:"h-4 w-4"}):p.jsx(GL,{className:"h-4 w-4"})}),p.jsx(je,{variant:"ghost",size:"icon",onClick:N,children:p.jsx(KL,{className:"h-4 w-4"})})]})})}),p.jsxs("main",{className:"relative container py-8 space-y-8",children:[l.length>0&&(()=>{const R=l.slice(0,3),M=l.slice(3,28),L=l.length>3,A=l.length>28;return p.jsx("div",{className:"space-y-2",children:p.jsxs("div",{className:"flex flex-wrap gap-2",children:[R.map(T=>p.jsxs("div",{className:"flex items-center gap-1",children:[p.jsxs(je,{variant:d===T.id?"default":"outline",size:"sm",onClick:()=>C(T.id),className:"gap-2",children:[p.jsx(Vd,{className:"h-3.5 w-3.5"}),T.name,T.status==="processing"&&p.jsx(Rt,{className:"h-3 w-3 animate-spin"})]}),p.jsx(je,{variant:"ghost",size:"icon",className:"h-7 w-7 text-muted-foreground hover:text-destructive",onClick:U=>{U.stopPropagation(),$(T.id)},children:p.jsx(Ig,{className:"h-3 w-3"})})]},T.id)),L&&p.jsxs(hc,{open:b,onOpenChange:w,children:[p.jsx(pc,{asChild:!0,children:p.jsxs(je,{variant:"outline",size:"sm",className:"gap-1",children:["Visa mer",p.jsx(Uj,{className:`h-3.5 w-3.5 transition-transform ${b?"rotate-180":""}`})]})}),p.jsx(Ws,{align:"start",className:"w-auto max-w-md p-2 z-50",children:p.jsxs("div",{className:"flex flex-col gap-1",children:[M.map(T=>p.jsxs("div",{className:"flex items-center gap-1",children:[p.jsxs(je,{variant:d===T.id?"default":"outline",size:"sm",onClick:()=>{C(T.id),w(!1)},className:"gap-2",children:[p.jsx(Vd,{className:"h-3.5 w-3.5"}),T.name,T.status==="processing"&&p.jsx(Rt,{className:"h-3 w-3 animate-spin"})]}),p.jsx(je,{variant:"ghost",size:"icon",className:"h-7 w-7 text-muted-foreground hover:text-destructive",onClick:U=>{U.stopPropagation(),$(T.id)},children:p.jsx(Ig,{className:"h-3 w-3"})})]},T.id)),A&&p.jsxs(je,{variant:"link",size:"sm",className:"text-primary",onClick:()=>r("/alla-analyser"),children:["Visa alla (",l.length," st)"]})]})})]})]})})})(),l.length===0&&p.jsxs("div",{className:"text-center py-20 space-y-4",children:[p.jsx(Vd,{className:"h-12 w-12 mx-auto text-muted-foreground"}),p.jsx("h2",{className:"font-display text-2xl font-bold",children:"Inga analyser ännu"}),p.jsx("p",{className:"text-muted-foreground max-w-md mx-auto",children:"Skapa din första gap-analys genom att ladda upp en hÃ¥llbarhetsrapport och ange företagets webbadress."}),p.jsx(zk,{onAnalysisCreated:R=>{k().then(()=>{c(R),h(null)})}})]}),v&&p.jsx("div",{className:"flex items-center justify-center py-20",children:p.jsx(Rt,{className:"h-8 w-8 animate-spin text-primary"})}),D&&(D.status==="processing"||D.status==="error")&&!v&&p.jsxs("div",{children:[p.jsx("h2",{className:"font-display text-2xl font-bold text-center mb-2",children:D.status==="error"?"Analysen kunde inte slutföras":"Analys pÃ¥gÃ¥r..."}),p.jsx(Vhe,{status:D.status,projectId:D.id})]}),f&&!v&&p.jsxs(p.Fragment,{children:[p.jsxs("section",{className:"animate-fade-in",children:[p.jsxs("div",{className:"flex items-center gap-2 mb-6",children:[p.jsx("h2",{className:"font-display text-2xl font-bold",children:(D==null?void 0:D.name)||"Analys"}),e&&D&&p.jsx(ope,{project:D,onProjectUpdated:R=>{u(M=>M.map(L=>L.id===R.id?{...L,...R}:L))}})]}),p.jsxs("div",{className:"grid grid-cols-1 lg:grid-cols-3 gap-6 items-stretch",children:[p.jsx("div",{className:"rounded-xl border border-border bg-white flex items-center justify-center p-6",children:p.jsx(mC,{score:f.gap_score??0,classification:f.classification??"balanced"})}),p.jsx("div",{className:"lg:col-span-2",children:p.jsx(n8,{summary:f.executive_summary??""})})]})]}),p.jsxs("section",{className:"animate-fade-in",style:{animationDelay:"0.1s"},children:[p.jsx("h2",{className:"font-display text-xl font-bold mb-4",children:"Planetära gränser â analys"}),p.jsx("div",{className:"rounded-xl border border-border bg-white p-6",children:p.jsxs("div",{className:"grid grid-cols-1 lg:grid-cols-3 gap-6 items-start",children:[p.jsxs("div",{className:"flex flex-col items-start gap-4",children:[p.jsx("img",{src:B2,alt:"De nio planetära gränserna â illustration av Stockholm Resilience Centre",className:"w-full rounded-lg"}),p.jsxs(hc,{children:[p.jsx(pc,{asChild:!0,children:p.jsxs("button",{className:"w-full flex items-center gap-2 rounded-lg border border-border bg-white p-3 text-xs text-muted-foreground hover:text-foreground transition-colors cursor-pointer",children:[p.jsx("span",{className:"shrink-0 rounded-full border border-border bg-background w-5 h-5 flex items-center justify-center text-[10px] font-bold",children:"?"}),p.jsx("span",{children:"Vad är Planetära gränser?"})]})}),p.jsxs(Ws,{side:"right",className:"max-w-xs text-xs leading-relaxed",children:[p.jsx("p",{children:"Nio vetenskapligt definierade gränser som anger det säkra handlingsutrymmet för mänskligheten. Sex av nio gränser har redan överskridits. Ramverket togs fram av Stockholm Resilience Centre 2009."}),p.jsx("p",{className:"mt-2",children:"Analysen kartlägger ert företags styrkor och möjligheter inom alla nio omrÃ¥den â inte bara klimat. Det synliggör outnyttjade positioneringsmöjligheter inom exempelvis biologisk mÃ¥ngfald, vattenanvändning eller kemisk förorening."})]})]})]}),p.jsxs("div",{className:"lg:col-span-2",children:[p.jsx(L2,{data:f.topic_scores??[]}),(()=>{const R=ex(f.topic_scores??[]);return R!=null&&R.summary?p.jsxs("div",{className:"mt-4 border-t border-border/50 pt-4",children:[p.jsxs("h4",{className:"text-sm font-semibold text-foreground flex items-center gap-1.5 mb-2",children:[p.jsx(Cb,{className:"h-4 w-4 text-primary"}),"Möjligheter"]}),p.jsx("p",{className:"text-sm leading-relaxed text-muted-foreground",dangerouslySetInnerHTML:{__html:R.summary}})]}):null})()]})]})})]}),p.jsxs("section",{className:"animate-fade-in",style:{animationDelay:"0.2s"},children:[p.jsx("h2",{className:"font-display text-xl font-bold mb-4",children:"Risker & möjligheter"}),S.includes("media")&&p.jsx(Ch,{stepName:"media"}),p.jsx(U2,{risks:f.risks??[],opportunities:f.opportunities??[],quickWins:f.quick_wins??[]})]}),p.jsxs("section",{className:"animate-fade-in",style:{animationDelay:"0.3s"},children:[p.jsx("h2",{className:"font-display text-xl font-bold mb-4",children:"Konkurrentjämförelse"}),S.includes("competitors")&&p.jsx(Ch,{stepName:"competitors"}),p.jsx(lR,{competitors:f.competitors??[],positioning:((I=f.your_company)==null?void 0:I.positioning)||""})]}),p.jsxs("section",{className:"animate-fade-in",style:{animationDelay:"0.4s"},children:[p.jsx("h2",{className:"font-display text-xl font-bold mb-4",children:"Kreativa kommunikationsförslag (visas inte till kund)"}),p.jsx(Pfe,{inspirations:f.inspirations??[]})]}),p.jsxs("section",{className:"animate-fade-in",style:{animationDelay:"0.5s"},children:[p.jsx("h2",{className:"font-display text-xl font-bold mb-4",children:"Källor"}),p.jsx(uR,{sources:_})]})]})]})]})}function lpe(){const[e,t]=O.useState(""),[r,n]=O.useState(""),[i,a]=O.useState(!1),[o,s]=O.useState(!1),l=ea(),{toast:u}=Zi();O.useEffect(()=>{const{data:{subscription:c}}=te.auth.onAuthStateChange(h=>{h==="PASSWORD_RECOVERY"&&s(!0)});return window.location.hash.includes("type=recovery")&&s(!0),()=>c.unsubscribe()},[]);const d=async c=>{if(c.preventDefault(),e!==r){u({title:"Fel",description:"Lösenorden matchar inte.",variant:"destructive"});return}if(e.length<6){u({title:"Fel",description:"Lösenordet mÃ¥ste vara minst 6 tecken.",variant:"destructive"});return}a(!0);try{const{error:f}=await te.auth.updateUser({password:e});if(f)throw f;u({title:"Lösenord uppdaterat!",description:"Du kan nu logga in med ditt nya lösenord."}),l("/",{replace:!0})}catch(f){u({title:"Fel",description:f.message,variant:"destructive"})}finally{a(!1)}};return p.jsxs("div",{className:"min-h-screen relative overflow-hidden flex items-center justify-center p-4",children:[p.jsx("div",{className:"absolute inset-0 pointer-events-none",style:{background:"linear-gradient(45deg, hsl(27 40% 57% / 0.15) 0%, hsl(27 35% 75% / 0.1) 40%, hsl(24 33% 94%) 100%)"}}),p.jsxs("div",{className:"relative w-full max-w-md animate-fade-in",children:[p.jsxs("div",{className:"flex items-center justify-center gap-3 mb-8",children:[p.jsx("div",{className:"h-10 w-10 rounded-xl bg-primary flex items-center justify-center",children:p.jsx(Tb,{className:"h-5 w-5 text-primary-foreground"})}),p.jsx("h1",{className:"font-display text-2xl font-bold tracking-tight",children:"Gap Analysis"})]}),p.jsxs(dr,{className:"border-border/50 shadow-lg",children:[p.jsxs(Zr,{className:"text-center",children:[p.jsx(en,{className:"font-display text-xl",children:"Nytt lösenord"}),p.jsx(Kb,{children:"Ange ditt nya lösenord nedan"})]}),p.jsx(fr,{children:o?p.jsxs("form",{onSubmit:d,className:"space-y-4",children:[p.jsxs("div",{className:"space-y-2",children:[p.jsx("label",{className:"text-sm font-medium",children:"Nytt lösenord"}),p.jsx(Kt,{type:"password",placeholder:"â¢â¢â¢â¢â¢â¢â¢â¢",value:e,onCh
406ange:c=>t(c.target.value),required:!0,minLength:6})]}),p.jsxs("div",{className:"space-y-2",children:[p.jsx("label",{className:"text-sm font-medium",children:"Bekräfta lösenord"}),p.jsx(Kt,{type:"password",placeholder:"â¢â¢â¢â¢â¢â¢â¢â¢",value:r,onChange:c=>n(c.target.value),required:!0,minLength:6})]}),p.jsxs(je,{type:"submit",className:"w-full font-semibold",disabled:i,children:[i&&p.jsx(Rt,{className:"h-4 w-4 animate-spin mr-2"}),"Uppdatera lösenord"]})]}):p.jsxs("div",{className:"text-center py-4",children:[p.jsx(Rt,{className:"h-6 w-6 animate-spin mx-auto mb-3 text-primary"}),p.jsx("p",{className:"text-sm text-muted-foreground",children:"Verifierar Ã¥terställningslänkâ¦"})]})})]})]})]})}function upe(){const e=ea(),[t,r]=O.useState(""),[n,i]=O.useState(""),[a,o]=O.useState(null),[s,l]=O.useState(!1),[u,d]=O.useState(0),[c,f]=O.useState(null),[h,v]=O.useState(!1),m=O.useRef(null),{toast:g}=Zi(),y=_=>{if(_.type!=="application/pdf"){g({title:"Fel filformat",description:"Endast PDF-filer stöds.",variant:"destructive"});return}o(_)},b=_=>{_.preventDefault(),v(!1),_.dataTransfer.files[0]&&y(_.dataTransfer.files[0])},w=async _=>{if(_.preventDefault(),!n.trim()){g({title:"E-post saknas",description:"Ange din e-postadress för att fÃ¥ resultatet.",variant:"destructive"});return}if(!t.trim()){g({title:"Webbplats-URL saknas",description:"Ange företagets webbplats-URL för en fullständig analys.",variant:"destructive"});return}if(!a){g({title:"PDF saknas",description:"Ladda upp en hÃ¥llbarhetsrapport i PDF-format.",variant:"destructive"});return}l(!0),f("Laddar upp rapport..."),d(20);try{const x=new FormData;x.append("pdf",a),t&&x.append("website_url",t),n&&x.append("email",n),d(40),f("Startar analys...");const k=await fetch("https://taxbtuaxnaczvpziaefd.supabase.co/functions/v1/public-analyze",{method:"POST",headers:{apikey:"eyJhbGciOiJIUzI1NiIsInR5cCI6IkpXVCJ9.eyJpc3MiOiJzdXBhYmFzZSIsInJlZiI6InRheGJ0dWF4bmFjenZwemlhZWZkIiwicm9sZSI6ImFub24iLCJpYXQiOjE3NzE5NDcwMDAsImV4cCI6MjA4NzUyMzAwMH0.uRZ-YSCS1ZZuwBVbZHp5tamyhbFnfcAMsro-g15mkEg"},body:x});if(!k.ok){const C=await k.json();throw new Error(C.error||"NÃ¥got gick fel")}const P=await k.json();d(100),f("Omdirigerar..."),P.share_password&&localStorage.setItem(`pw_${P.public_token}`,"1"),e(`/analys/${P.public_token}`)}catch(x){console.error("Public analyze error:",x);const S=x.message&&x.message!=="Unknown error"?x.message:"Kunde inte starta analysen. Kontrollera att PDF-filen inte är skadad eller lösenordsskyddad, och att webbplatsadressen stämmer. Försök igen.";g({title:"Analysen kunde inte startas",description:S,variant:"destructive"}),l(!1),f(null),d(0)}};return p.jsxs("div",{className:"min-h-screen relative overflow-hidden",children:[p.jsx("div",{className:"absolute inset-0 pointer-events-none",style:{background:"linear-gradient(45deg, hsl(27 40% 57% / 0.15) 0%, hsl(27 35% 75% / 0.1) 40%, hsl(24 33% 94%) 100%)"}}),p.jsx("header",{className:"relative border-b border-border/50 bg-white/40 backdrop-blur-sm",children:p.jsx("div",{className:"container flex h-14 items-center"})}),p.jsxs("main",{className:"relative container max-w-2xl py-16 space-y-8",children:[p.jsxs("div",{className:"text-center space-y-3",children:[p.jsx("div",{className:"flex justify-center mb-2",children:p.jsx("div",{className:"w-48 h-28 overflow-hidden",children:p.jsxs("svg",{viewBox:"0 0 200 125",className:"w-full h-full",children:[p.jsx("defs",{children:p.jsxs("linearGradient",{id:"gaugeGradientPublic",x1:"0%",y1:"0%",x2:"100%",y2:"0%",children:[p.jsx("stop",{offset:"0%",stopColor:"hsl(var(--destructive))"}),p.jsx("stop",{offset:"35%",stopColor:"hsl(var(--warning))"}),p.jsx("stop",{offset:"50%",stopColor:"hsl(var(--primary))"}),p.jsx("stop",{offset:"75%",stopColor:"hsl(var(--warning))"}),p.jsx("stop",{offset:"100%",stopColor:"hsl(var(--chart-amber))"})]})}),p.jsx("path",{d:"M 20 100 A 80 80 0 0 1 180 100",fill:"none",stroke:"hsl(var(--muted))",strokeWidth:"12",strokeLinecap:"round"}),p.jsx("path",{d:"M 20 100 A 80 80 0 0 1 180 100",fill:"none",stroke:"url(#gaugeGradientPublic)",strokeWidth:"12",strokeLinecap:"round",opacity:"0.8"}),p.jsx("line",{x1:"100",y1:"100",x2:"100",y2:"30",stroke:"hsl(var(--foreground))",strokeWidth:"3",strokeLinecap:"round",style:{transformOrigin:"100px 100px",animation:"gauge-swing 3s ease-in-out infinite"}}
406),p.jsx("circle",{cx:"100",cy:"100",r:"6",fill:"hsl(var(--foreground))"}),p.jsx("text",{x:"10",y:"118",className:"fill-muted-foreground text-[8px]",fontFamily:"Inter",children:"Greenwashing"}),p.jsx("text",{x:"148",y:"118",className:"fill-muted-foreground text-[8px]",fontFamily:"Inter",children:"Greenhushing"})]})})}),p.jsx("h1",{className:"font-display text-3xl md:text-4xl font-bold text-foreground",children:"Corporate Sustainability Gap Analysis"}),p.jsx("p",{className:"text-muted-foreground text-lg leading-relaxed",children:"Ladda upp er hÃ¥llbarhetsrapport och fÃ¥ en AI-driven analys av gapet mellan vad ni gör och vad ni kommunicerar."})]}),p.jsxs("form",{onSubmit:w,className:"space-y-6 bg-white rounded-xl border border-border p-6 md:p-8",children:[p.jsxs("div",{className:"space-y-2",children:[p.jsxs(rn,{htmlFor:"pub-email",children:["E-postadress ",p.jsx("span",{className:"text-muted-foreground font-normal",children:"(för att fÃ¥ resultatet skickat till dig)"})]}),p.jsx(Kt,{id:"pub-email",type:"email",placeholder:"[email protected]",value:n,onChange:_=>i(_.target.value),disabled:s,required:!0})]}),p.jsxs("div",{className:"space-y-2",children:[p.jsx(rn,{htmlFor:"pub-url",children:"Webbplats-URL"}),p.jsx(Kt,{id:"pub-url",type:"url",placeholder:"https://www.ertforetag.se",value:t,onChange:_=>r(_.target.value),disabled:s,required:!0})]}),p.jsxs("div",{className:"space-y-2",children:[p.jsx(rn,{children:"HÃ¥llbarhetsrapport (PDF)"}),p.jsx("input",{ref:m,type:"file",accept:".pdf",className:"hidden",onChange:_=>{var x;return((x=_.target.files)==null?void 0:x[0])&&y(_.target.files[0])}}),a?p.jsxs("div",{className:"flex items-center gap-3 rounded-lg border border-border bg-muted/30 px-4 py-3",children:[p.jsx(_f,{className:"h-5 w-5 text-muted-foreground shrink-0"}),p.jsxs("div",{className:"flex-1 min-w-0",children:[p.jsx("p",{className:"text-sm font-medium truncate",children:a.name}),p.jsxs("p",{className:"text-xs text-muted-foreground",children:[(a.size/1024/1024).toFixed(1)," MB"]})]}),!s&&p.jsx("button",{type:"button",onClick:()=>o(null),className:"text-muted-foreground hover:text-foreground",children:p.jsx(Zh,{className:"h-4 w-4"})})]}):p.jsxs("div",{className:`flex flex-col items-center justify-center gap-3 rounded-lg border-2 border-dashed p-8 cursor-pointer transition-colors ${h?"border-primary bg-primary/5":"border-border hover:border-primary/50"}`,onClick:()=>{var _;return(_=m.current)==null?void 0:_.click()},onDragOver:_=>{_.preventDefault(),v(!0)},onDragLeave:()=>v(!1),onDrop:b,children:[p.jsx(Kj,{className:"h-8 w-8 text-muted-foreground"}),p.jsxs("div",{className:"text-center",children:[p.jsx("p",{className:"text-sm font-medium",children:"Dra och släpp PDF här"}),p.jsx("p",{className:"text-xs text-muted-foreground mt-1",children:"eller klicka för att välja fil"})]})]})]}),s&&p.jsxs("div",{className:"space-y-2",children:[p.jsx(gx,{value:u,className:"h-2"}),p.jsxs("p",{className:"text-xs text-muted-foreground flex items-center gap-2",children:[p.jsx(Rt,{className:"h-3 w-3 animate-spin"}),c]})]}),p.jsx(je,{type:"submit",className:"w-full font-semibold text-base py-5",disabled:s,children:s?"Bearbetar...":"Starta analys"})]}),p.jsx("p",{className:"text-center text-xs text-muted-foreground",children:"Analysen tar vanligtvis 2â4 minuter. Dina uppgifter hanteras konfidentiellt."})]})]})}function cpe(){const{isAdmin:e,loading:t}=Xb(),r=ea(),[n,i]=O.useState([]),[a,o]=O.useState(!0);O.useEffect(()=>{t||te.auth.getSession().then(({data:{session:c}})=>{c?s():r("/",{replace:!0})})},[r,t]);const s=async()=>{const{data:{session:c}}=await te.auth.getSession();if(!c)return;let f=te.from("analysis_projects").select("id, name, status, created_at, website_url, classification, overall_gap_score").order("created_at",{ascending:!1});e||(f=f.eq("user_id",c.user.id));const{data:h}=await f;i(h||[]),o(!1)},l=async c=>{await te.from("analysis_steps").delete().eq("project_id",c),await te.from("analysis_results").delete().eq("project_id",c),await te.from("documents").delete().eq("project_id",c),await te.from("analysis_projects").delete().eq("id",c),i(f=>f.filter(h=>h.id!==c))},u=c=>{switch(c){case"complete":return"Klar";case"processing":return"PÃ¥gÃ¥r";case"error":return"Fel";default:return"Utkast"}},d=c=>{switch(c){case"complete":return"bg-green-100 text-green-800";
406case"processing":return"bg-yellow-100 text-yellow-800";case"error":return"bg-red-100 text-red-800";default:return"bg-muted text-muted-foreground"}};return a?p.jsx("div",{className:"min-h-screen flex items-center justify-center bg-background",children:p.jsx(Rt,{className:"h-8 w-8 animate-spin text-primary"})}):p.jsxs("div",{className:"min-h-screen relative overflow-hidden",children:[p.jsx("div",{className:"absolute inset-0 pointer-events-none",style:{background:"linear-gradient(45deg, hsl(27 40% 57% / 0.15) 0%, hsl(27 35% 75% / 0.1) 40%, hsl(24 33% 94%) 100%)"}}),p.jsx("header",{className:"relative sticky top-0 z-50 border-b border-border/50 bg-white/40 backdrop-blur-sm",children:p.jsx("div",{className:"container flex h-14 items-center justify-between",children:p.jsxs("div",{className:"flex items-center gap-3",children:[p.jsx("div",{className:"h-8 w-8 rounded-lg bg-primary flex items-center justify-center",children:p.jsx(Tb,{className:"h-4 w-4 text-primary-foreground"})}),p.jsx("span",{className:"font-display font-bold text-lg tracking-tight",children:"Gap Analysis"})]})})}),p.jsxs("main",{className:"container py-8 space-y-6",children:[p.jsxs("div",{className:"flex items-center gap-4",children:[p.jsxs(je,{variant:"ghost",size:"sm",onClick:()=>r("/dashboard"),className:"gap-2",children:[p.jsx(UL,{className:"h-4 w-4"}),"Tillbaka"]}),p.jsx("h1",{className:"font-display text-2xl font-bold",children:"Alla analyser"}),p.jsxs("span",{className:"text-sm text-muted-foreground",children:["(",n.length," st)"]})]}),p.jsx("div",{className:"rounded-xl border border-border bg-white overflow-hidden",children:p.jsxs("table",{className:"w-full text-sm",children:[p.jsx("thead",{children:p.jsxs("tr",{className:"border-b border-border bg-muted/30",children:[p.jsx("th",{className:"text-left px-4 py-3 font-semibold",children:"Namn"}),p.jsx("th",{className:"text-left px-4 py-3 font-semibold hidden sm:table-cell",children:"Webbplats"}),p.jsx("th",{className:"text-left px-4 py-3 font-semibold hidden md:table-cell",children:"Skapad"}),p.jsx("th",{className:"text-left px-4 py-3 font-semibold",children:"Status"}),p.jsx("th",{className:"w-12 px-4 py-3"})]})}),p.jsx("tbody",{children:n.map(c=>p.jsxs("tr",{className:"border-b border-border/50 hover:bg-muted/20 cursor-pointer transition-colors",onClick:()=>r(`/dashboard?project=${c.id}`),children:[p.jsxs("td",{className:"px-4 py-3 font-medium flex items-center gap-2",children:[p.jsx(Vd,{className:"h-3.5 w-3.5 text-muted-foreground shrink-0"}),c.name]}),p.jsx("td",{className:"px-4 py-3 text-muted-foreground hidden sm:table-cell truncate max-w-[200px]",children:c.website_url||"â"}),p.jsx("td",{className:"px-4 py-3 text-muted-foreground hidden md:table-cell",children:new Date(c.created_at).toLocaleDateString("sv-SE")}),p.jsx("td",{className:"px-4 py-3",children:p.jsxs("span",{className:`inline-flex items-center gap-1 rounded-full px-2 py-0.5 text-xs font-medium ${d(c.status)}`,children:[c.status==="processing"&&p.jsx(Rt,{className:"h-3 w-3 animate-spin"}),u(c.status)]})}),p.jsx("td",{className:"px-4 py-3",children:p.jsx(je,{variant:"ghost",size:"icon",className:"h-7 w-7 text-muted-foreground hover:text-destructive",onClick:f=>{f.stopPropagation(),l(c.id)},children:p.jsx(Ig,{className:"h-3.5 w-3.5"})})})]},c.id))})]})})]})]})}const dpe="/assets/azote-strategy-CZ0Atkz5.jpg",fpe="/assets/azote-contact-CamYPJ12.jpg",hpe="/assets/azote-greenclaims-B3XsUu7Y.png";function ppe(){const e=[{image:hpe,title:"AI-baserad Green Claims-analys",description:"Azote har skapat en avancerad AI som är expert pÃ¥ green claims och nya EU-direktiv. Den är tränad med vÃ¥r kunskap och erfarenhet och utvecklad för att scanna av texter, rapporter och webbsidor. AI:n analyserar och listar problematiska formuleringar och ord. Dessutom ger den rekommendationer för hur ni själva kan arbeta vidare med er hÃ¥llbarhetskommunikation.",cta:{label:"Testa analysen",href:"https://www.azote.se/green-claims-analys"}},{image:dpe,title:"Strategisk hÃ¥llbarhetskommunikation",description:"Vi hjälper företag att skapa trovärdig och kvalitetssäkrad kommunikation som är grundad i vetenskap och som hÃ¥ller över tid. Vi erbjuder helhetslösningar â frÃ¥n strategisk rÃ¥dgivning till kreativ produktion och projektledning.",cta:{label:"VÃ¥ra tjänster",href:"https://www.azote.se/foretag"}},{image:fpe,title:"Grundad i vetenskap",description:"Vi fungerar som diskussionspartner och rÃ¥dgivare och hjälper dig att prioritera och utforma kommunikationen sÃ¥ att den ger största möjliga effekt. Med vÃ¥r erfarenhet kommer vi ofta med förslag pÃ¥ lösningar och format som stärker genomslaget.",cta:{label:"[email protected]",href:"https://www.azote.se/kontakt"}}];return p.jsx("section",{id:"azote-section",className:"bg-[#317584] text-white py-16 -mx-4 px-4 sm:-mx-8 sm:px-8 md:-mx-12 md:px-12 print:hidden",children:p.jsxs("div",{className:"max-w-6xl mx-auto
406space-y-10",children:[p.jsxs("div",{className:"text-center space-y-3",children:[p.jsx("h2",{className:"font-display text-3xl font-bold text-white",children:"Grunda er kommunikation i vetenskap"}),p.jsx("p",{className:"text-white/70 max-w-2xl mx-auto text-base leading-relaxed",children:"PÃ¥ Azote hjälper vi företag att omsätta den senaste hÃ¥llbarhetsforskningen till konkreta affärsmöjligheter. Med över 20 Ã¥rs erfarenhet använder vi vetenskap och kommunikation för att navigera komplexa hÃ¥llbarhetsfrÃ¥gor. Vi arbetar som er katalysator och kompass â för att bÃ¥de driva och kommunicera omställningen. Tillsammans kan vi skapa lÃ¥ngsiktig affärsnytta och samtidigt göra positiv skillnad för planeten."})]}),p.jsx("div",{className:"grid grid-cols-1 md:grid-cols-3 gap-6",children:e.map((t,r)=>p.jsxs("a",{href:t.cta.href,target:t.cta.href.startsWith("mailto:")?void 0:"_blank",rel:"noopener noreferrer",className:"group rounded-xl overflow-hidden bg-white/10 backdrop-blur-sm border border-white/10 hover:bg-white/15 transition-all duration-300",children:[p.jsx("div",{className:"aspect-[16/10] overflow-hidden",children:p.jsx("img",{src:t.image,alt:t.title,className:"w-full h-full object-cover group-hover:scale-105 transition-transform duration-500"})}),p.jsxs("div",{className:"p-5 space-y-3",children:[p.jsx("h3",{className:"font-display text-lg font-bold text-white",children:t.title}),p.jsx("p",{className:"text-sm text-white/70 leading-relaxed",children:t.description}),p.jsxs("span",{className:"inline-flex items-center gap-1.5 text-sm font-medium text-white/90 group-hover:text-white transition-colors",children:[t.cta.label,p.jsx(FL,{className:"h-3.5 w-3.5 group-hover:translate-x-1 transition-transform"})]})]})]},r))})]})})}const mpe=[{key:"pdf",label:"Extraherar text frÃ¥n hÃ¥llbarhetsrapport"},{key:"website",label:"Analyserar webbplatsens kommunikation"},{key:"media",label:"Söker pressreleaser, LinkedIn & media"},{key:"competitors",label:"Analyserar konkurrenters kommunikation"},{key:"synthesize",label:"Sammanställer slutgiltig analys"}];function vpe(){var L;const{token:e}=tU();ea();const{toast:t}=Zi(),{isAdmin:r}=Xb(),[n,i]=O.useState(!0),[a,o]=O.useState(null),[s,l]=O.useState(null),[u,d]=O.useState([]),[c,f]=O.useState([]),[h,v]=O.useState(!1),[m,g]=O.useState(!1),[y,b]=O.useState(""),[w,_]=O.useState(!1);O.useEffect(()=>{if(e){const T=new URLSearchParams(window.location.search).get("pw");T&&b(T)}},[e]),O.useEffect(()=>{if(!e)return;(async()=>{const{data:T,error:U}=await te.from("analysis_projects").select("*").eq("public_token",e).single();if(U||!T){console.error("Error loading public project:",U),i(!1);return}if(T.public_token!==e){console.error("Token mismatch â refusing to show data"),i(!1);return}if(o(T),T.share_password&&y&&y===T.share_password&&g(!0),T.status==="complete"){await x(T.id);const q=`dialog_seen_${e}`;localStorage.getItem(q)||(v(!0),localStorage.setItem(q,"1"))}i(!1)})()},[e,y]),O.useEffect(()=>{if(!a)return;const A=a.id,T=async()=>{const{data:B}=await te.from("analysis_steps").select("step_name, status, error_message").eq("project_id",A).order("created_at",{ascending:!0});B&&d(B)};T();const U=te.channel(`public-project-${A}`).on("postgres_changes",{event:"UPDATE",schema:"public",table:"analysis_projects",filter:`id=eq.${A}`},B=>{const W=B.new;if(o(K=>({...K,...W})),W.status==="complete"){const K=`dialog_seen_${e}`;x(A).then(()=>{localStorage.getItem(K)||(v(!0),localStorage.setItem(K,"1"))})}}).on("postgres_changes",{event:"*",schema:"public",table:"analysis_steps",filter:`project_id=eq.${A}`},()=>{T()}).subscribe(),q=setInterval(async()=>{const{data:B}=await te.from("analysis_projects").select("status").eq("id",A).single();if((B==null?void 0:B.status)==="complete"&&a.status!=="complete"){o(K=>({...K,status:"complete"}));const W=`dialog_seen_${e}`;x(A).then(()=>{localStorage.getItem(W)||(v(!0),localStorage.setItem(W,"1"))})}(B==null?void 0:B.status)==="error"&&a.status!=="error"&&o(W=>({...W,status:"error"})),T()},1e4);return()=>{te.removeChannel(U),clearInterval(q)}},[a==null?void 0:a.id]);const x=async A=>{const[{data:T},{data:U},{data:q}]=await Promise.all([te.from("analysis_results").select("*").eq("project_id",A).order("created_at",{ascending:!1}).limit(1).single(),te.from("documents").select("file_name, doc_type").eq("project_id",A),te.from("analysis_steps").select("step_name, result").eq("project_id",A).eq("status","complete")]);l(T);const B=[];for(const W of U||[])B.push({type:"pdf",name:W.file_name,category:"Uppladdade dokument"});for(const W of q||[]){const K=W.result;if(W.step_name==="website"&&(K!=null&&K.scraped_urls))for(const Z of K.scraped_urls)B.push({type:"url",name:Z,url:Z,category:"Företagets webbplats"});if(W.step_name==="media"&&(K!=null&&K.media_urls))for(const Z of K.media_urls)B.push({type:"url",name:Z.title||Z.url,url:Z.url,category:"Media & extern kommunikation"});if(W.step_name==="competitors"&&(K!=null&&K.competitor_urls))for(const Z of K.c
406ompetitor_urls)B.push({type:"url",name:Z.title||Z.url,url:Z.url,category:`Konkurrent: ${Z.competitor}`})}f(B)},S=A=>{const T=u.find(U=>U.step_name===A);return(T==null?void 0:T.status)||"pending"},E=()=>{window.print()};if(n)return p.jsx("div",{className:"min-h-screen flex items-center justify-center bg-background",children:p.jsx(Rt,{className:"h-8 w-8 animate-spin text-primary"})});if(!a)return p.jsx("div",{className:"min-h-screen flex items-center justify-center bg-background",children:p.jsxs("div",{className:"text-center space-y-2",children:[p.jsx("h1",{className:"font-display text-2xl font-bold",children:"Analysen hittades inte"}),p.jsx("p",{className:"text-muted-foreground",children:"Kontrollera att länken är korrekt."})]})});const k=!!a.share_password,P=e?!!localStorage.getItem(`pw_${e}`):!1,C=k&&!m&&!P,N=A=>{A.preventDefault(),y===a.share_password?(g(!0),_(!1)):_(!0)};if(C)return p.jsx("div",{className:"min-h-screen bg-background flex items-center justify-center",children:p.jsxs("div",{className:"w-full max-w-sm mx-auto p-8 rounded-xl border border-border bg-white space-y-6 text-center",children:[p.jsx("div",{className:"inline-flex items-center justify-center h-14 w-14 rounded-full bg-primary/10 mx-auto",children:p.jsx(VL,{className:"h-7 w-7 text-primary"})}),p.jsxs("div",{className:"space-y-2",children:[p.jsx("h1",{className:"font-display text-xl font-bold",children:"Lösenord krävs"}),p.jsx("p",{className:"text-sm text-muted-foreground",children:"Ange lösenordet du fÃ¥tt för att visa analysen."})]}),p.jsxs("form",{onSubmit:N,className:"space-y-4",children:[p.jsx(Kt,{type:"text",placeholder:"Lösenord",value:y,onChange:A=>{b(A.target.value),_(!1)},className:w?"border-destructive":"",autoFocus:!0}),w&&p.jsx("p",{className:"text-xs text-destructive",children:"Fel lösenord. Försök igen."}),p.jsx(je,{type:"submit",className:"w-full font-semibold",children:"Visa analys"})]})]})});const D=(()=>{if(!s)return null;s.gap_score;const A=s.classification;return A==="opportunity"?{emoji:"ð¿",title:"Greenhushing",subtitle:"Missad kommunikationsmöjlighet",description:"Ni visar pÃ¥ en tendens av greenhushing â ert hÃ¥llbarhetsarbete verkar starkare än vad er kommunikation speglar.",bullets:["Ni kan missa möjligheten att bygga varumärke och positionera er som ledande. Kunder, investerare och partners fattar beslut baserat pÃ¥ vad de ser â inte vad ni gör i det tysta.",'Intern frustration kan växa när investeringar i hÃ¥llbarhet inte synliggörs. "Varför ska vi hÃ¥lla pÃ¥ med allt det här om ingen vet om det?"',"Ni kan missa chansen att attrahera ny kompetens. Talanger söker sig till organisationer som vÃ¥gar kommunicera sina ambitioner.","Om en hel bransch tystnar kan allmänheten tro att ingenting händer i omställningen â det kan skada inte bara er, utan alla."]}:A==="risk"?{emoji:"â ï¸",title:"Greenwashing-risk",subtitle:"Mer kommunikation än bevis",description:"Er kommunikation kan utlova mer än vad underliggande data och rapportering visar â det kan innebära en greenwashing-risk.",bullets:["Det kan finnas ökad regulatorisk risk â EU:s Green Claims Directive och CSRD ställer krav pÃ¥ att pÃ¥stÃ¥enden kan styrkas med data.","Det finns en risk för förtroendeskada om journalister, NGO:er eller kunder granskar era pÃ¥stÃ¥enden och hittar luckor.","Intern osäkerhet kan uppstÃ¥ â medarbetare kan tappa tillit om de upplever att kommunikationen inte speglar verkligheten.","Konkurrenter som kommunicerar mer ärligt kan framstÃ¥ som trovärdiga alternativ."]}:{emoji:"â
",title:"Balanserad kommunikation",subtitle:"Kommunikation och data i linje",description:"Bra jobbat! Er hÃ¥llbarhetskommunikation stämmer väl överens med det underliggande arbetet och tillgänglig data.",bullets:["Ni har en stark grund att bygga vidare pÃ¥ â trovärdigheten finns där.","Fortsätt säkerställa att nya pÃ¥stÃ¥enden alltid backas upp med konkreta bevis och data.","Utnyttja er balans för att positionera er som ett trovärdigt branschexempel.","Se över detaljerna i ämnesanalysen â det kan finnas specifika omrÃ¥den med potential att kommunicera ännu bättre."]}})(),I=a.status==="processing",R=a.status==="error",M=a.status==="complete"&&s;return p.jsxs("div",{className:"min-h-screen relative overflow-hidden",children:[p.jsx("div",{className:"absolute inset-0 pointer-events-none",style:{background:"linear-gradient(45deg, hsl(27 40% 57% / 0.15) 0%, hsl(27 35% 75% / 0.1) 40%, hsl(24 33% 94%) 100%)"}}),p.jsxs("div",{className:"fixed top-1/2 -translate-y-1/2 right-4 z-50 flex flex-col gap-2 print:hidden",children:[M&&p.jsxs(hc,{children:[p.jsx(pc,{asChild:!0,children:p.jsxs(je,{size:"sm",className:"gap-1.5 text-xs px-3 py-2 h-auto flex-col items-center leading-tight",children:[p.jsx(Hj,{className:"h-4 w-4"}),p.jsx("span",{children:"Dela"})]})}),p.jsxs(Ws,{align:"end",side:"left",className:"w-80 space-y-3",children:[p.jsx("p",{className:"text-sm font-semibold",children:"Dela med kollega"}),r?p.jsxs("div",{className:"space-y-1.5",children:[p.jsx(rn,{className:"text-xs",children:"Säker länk"}),p.jsxs("div",{className:"flex gap-1.5",children:[p.jsx(Kt,{readOnly:!0,value:`${window.location.origin}/analys/${a==null?void 0:a.public_token}?pw=${encodeURIComponent((a==null?void 0:a.share_password)||"")}`,className:"text-xs h-8"}),p.jsx(je,{variant:"outline",size:"icon",className:"shrink-0 h-8 w-8",onClick:()=>{const A=`${window.location.origin}/analys/${a==null?void 0:a.public_token}?pw=${encodeURIComponent((a==null?void 0:a.share_password)||"")}`;navigator.clipboard.writeText(A),t({title:"Länk kopierad"})},children:p.jsx(Kd,{className:"h-3.5 w-3.5"})})]})]}):p.jsxs(p.Fragment,{children:[p.jsxs("div",{className:"space-y-1.5",children:[p.jsx(rn,{className:"text-xs",children:"Länk"}),p.jsxs("div",{className:"flex gap-1.5",children:[p.jsx(Kt,{readOnly:!0,value:`${window.location.origin}/analys/${a==null?void 0:a.public_token}`,className:"text-xs h-8"}),p.jsx(je,{variant:"outline",size:"icon",className:"shrink-0 h-8 w-8",onClick:()=>{navigator.clipboard.writeText(`${window.location.origin}/analys/${a==null?void 0:a.public_token}`),t({title:"Länk kopierad"})},children:p.jsx(Kd,{className:"h-3.5 w-3.5"})})]})]}),p.jsxs("div",{className:"space-y-1.5",children:[p.jsx(rn,{className:"text-xs",children:"Lösenord"}),p.jsxs("div",{className:"flex gap-1.5",children:[p.jsx(Kt,{readOnly:!0,value:(a==null?void 0:a.share_password)||"",className:"text-xs h-8 font-mono"}),p.jsx(je,{variant:"outline",size:"icon",className:"shrink-0 h-8 w-8",onClick:()=>{navigator.clipboard.writeText((a==null?void 0:a.share_password)||""),t({title:"Lösenord kopierat"})},children:p.jsx(Kd,{className:"h-3.5 w-3.5"})})]})]})]})]})]}),M&&p.jsx(Wg,{children:p.jsxs(t_,{children:[p.jsx(r_,{asChild:!0,children:p.jsx(je,{variant:"outline",size:"icon",className:"h-9 w-9 bg-white/80 backdrop-blur-sm",onClick:E,children:p.jsx(WL,{className:"h-4 w-4"})})}),p.jsx(qg,{side:"left",children:"Ladda ner PDF"})]})}),p.jsx(Wg,{children:p.jsxs(t_,{children:[p.jsx(r_,{asChild:!0,children:p.jsx("a",{href:"https://www.azote.se/en/corporate-sustainability-gap-analysis",target:"_blank",rel:"noopener noreferrer",children:p.jsx(je,{variant:"outline",size:"icon",className:"h-9 w-9 bg-white/80 backdrop-blur-sm",title:"Ny analys",children:p.jsx(qj,{
406className:"h-4 w-4"})})})}),p.jsx(qg,{side:"left",children:"Ny analys"})]})})]}),p.jsx(UR,{open:h,onOpenChange:v,children:p.jsx(fx,{className:"sm:max-w-lg",children:D&&p.jsxs(p.Fragment,{children:[p.jsxs(hx,{children:[p.jsxs(px,{className:"flex items-center gap-2 text-2xl",children:[p.jsx("span",{className:"text-3xl",children:D.emoji}),D.title]}),p.jsx(zR,{className:"text-base font-semibold text-foreground/80 pt-1",children:D.subtitle})]}),p.jsxs("div",{className:"space-y-4 py-2",children:[p.jsx("p",{className:"text-sm leading-relaxed text-muted-foreground",children:D.description}),p.jsx("ul",{className:"space-y-2.5",children:D.bullets.map((A,T)=>p.jsxs("li",{className:"flex gap-2 text-sm leading-relaxed text-muted-foreground",children:[p.jsx("span",{className:"mt-1 shrink-0 h-1.5 w-1.5 rounded-full bg-primary"}),p.jsx("span",{children:A})]},T))}),p.jsxs("div",{className:"rounded-lg bg-muted/50 border border-border/50 p-3 space-y-2 text-xs text-muted-foreground leading-relaxed",children:[p.jsx("p",{children:"â¡ Detta är en AI-genererad analys baserad pÃ¥ publikt tillgängliga källor och er uppladdade rapport. Den ska ses som inspiration och utgÃ¥ngspunkt â inte som en absolut sanning."}),p.jsxs("p",{children:["Vi pÃ¥ ",p.jsx("strong",{className:"text-foreground",children:"Azote"})," arbetar med strategisk och kreativ hÃ¥llbarhetskommunikation och hjälper er gärna att nÃ¥ er fulla potential. ",p.jsx("a",{href:"https://azote.se",target:"_blank",rel:"noopener noreferrer",className:"text-primary hover:underline font-medium",children:"azote.se"})]})]})]}),p.jsx(je,{className:"w-full font-semibold",onClick:()=>v(!1),children:"Visa resultatet"})]})})}),p.jsxs("main",{className:"relative container py-8 space-y-8",children:[p.jsx("h1",{className:"font-display text-3xl md:text-4xl font-bold text-center text-foreground",children:"Corporate Sustainability Gap Analysis"}),(I||R)&&p.jsxs("div",{className:"max-w-lg mx-auto space-y-8",children:[!R&&p.jsx("div",{className:"flex justify-center",children:p.jsx("div",{className:"w-64 h-40 overflow-hidden",children:p.jsxs("svg",{viewBox:"0 0 200 125",className:"w-full h-full",children:[p.jsx("defs",{children:p.jsxs("linearGradient",{id:"gaugeGradientAnim",x1:"0%",y1:"0%",x2:"100%",y2:"0%",children:[p.jsx("stop",{offset:"0%",stopColor:"hsl(var(--destructive))"}),p.jsx("stop",{offset:"35%",stopColor:"hsl(var(--warning))"}),p.jsx("stop",{offset:"50%",stopColor:"hsl(var(--primary))"}),p.jsx("stop",{offset:"75%",stopColor:"hsl(var(--warning))"}),p.jsx("stop",{offset:"100%",stopColor:"hsl(var(--chart-amber))"})]})}),p.jsx("path",{d:"M 20 100 A 80 80 0 0 1 180 100",fill:"none",stroke:"hsl(var(--muted))",strokeWidth:"12",strokeLinecap:"round"}),p.jsx("path",{d:"M 20 100 A 80 80 0 0 1 180 100",fill:"none",stroke:"url(#gaugeGradientAnim)",strokeWidth:"12",strokeLinecap:"round",opacity:"0.8"}),p.jsx("line",{x1:"100",y1:"100",x2:"100",y2:"30",stroke:"hsl(var(--foreground))",strokeWidth:"3",strokeLinecap:"round",className:"origin-center",style:{transformOrigin:"100px 100px",animation:"gauge-swing 3s ease-in-out infinite"}}
406),p.jsx("circle",{cx:"100",cy:"100",r:"6",fill:"hsl(var(--foreground))"}),p.jsx("text",{x:"10",y:"118",className:"fill-muted-foreground text-[8px]",fontFamily:"Inter",children:"Greenwashing"}),p.jsx("text",{x:"148",y:"118",className:"fill-muted-foreground text-[8px]",fontFamily:"Inter",children:"Greenhushing"})]})})}),p.jsx("h2",{className:"font-display text-2xl font-bold text-center",children:R?"Analysen kunde inte slutföras":"Analys pÃ¥gÃ¥r..."}),R&&p.jsxs("div",{className:"rounded-lg border border-destructive/30 bg-destructive/5 p-4 text-center space-y-2",children:[p.jsx("p",{className:"text-sm text-destructive font-medium",children:(()=>{const A=u.find(T=>T.status==="error");return(A==null?void 0:A.error_message)||"Det gick inte att bearbeta ett av stegen i analysen."})()}),p.jsx("p",{className:"text-xs text-muted-foreground",children:"Försök gärna igen med en annan fil eller kontrollera webbplatsadressen."}),p.jsx("a",{href:"/analys",className:"inline-block mt-2 text-sm font-semibold text-primary hover:underline",children:"â Starta en ny analys"})]}),p.jsxs("div",{className:"rounded-xl border border-border bg-white p-6 space-y-6",children:[p.jsx("div",{className:"space-y-3",children:mpe.map(A=>{const T=S(A.key);return p.jsxs("div",{className:"flex items-center gap-3",children:[T==="complete"?p.jsx(jb,{className:"h-5 w-5 text-primary shrink-0"}):T==="in_progress"?p.jsx(Rt,{className:"h-5 w-5 animate-spin text-primary shrink-0"}):T==="error"?p.jsx(Fj,{className:"h-5 w-5 text-destructive shrink-0"}):p.jsx(zj,{className:"h-5 w-5 text-muted-foreground/40 shrink-0"}),p.jsx("span",{className:T==="in_progress"?"text-sm font-medium":T==="error"?"text-sm text-destructive":T==="complete"?"text-sm":"text-sm text-muted-foreground/60",children:A.label})]},A.key)})}),p.jsx("p",{className:"text-muted-foreground text-sm text-left",children:"Analysen söker igenom rapport, webbplats, media och konkurrenter. Detta kan ta nÃ¥gra minuter."}),(a==null?void 0:a.notification_email)&&p.jsxs("p",{className:"text-sm text-left font-bold text-primary",children:["Resultatet skickas till ",a.notification_email," när analysen är klar."]})]})]}),M&&p.jsxs(p.Fragment,{children:[p.jsx("section",{className:"animate-fade-in",children:p.jsxs("div",{className:"grid grid-cols-1 lg:grid-cols-3 gap-6 items-stretch",children:[p.jsx("div",{className:"rounded-xl border border-border/50 bg-white flex items-center justify-center p-6",children:p.jsx(mC,{score:s.gap_score??0,classification:s.classification??"balanced"})}),p.jsx("div",{className:"lg:col-span-2",children:p.jsx(dr,{className:"border-border/50 bg-white",children:p.jsxs(fr,{className:"pt-6 space-y-4",children:[p.jsxs("div",{className:"space-y-1",children:[p.jsx("h2",{className:"font-display text-xl font-bold text-foreground",children:a.name}),p.jsxs("p",{className:"text-sm text-muted-foreground",children:["Analyserad ",new Date(a.created_at).toLocaleDateString("sv-SE",{year:"numeric",month:"long",day:"numeric"})]})]}),p.jsxs("div",{className:"border-t border-border/50 pt-4",children:[p.jsx("h3",{className:"font-display text-lg font-semibold mb-2",children:"Sammanfattning"}),p.jsx("p",{className:"text-base leading-relaxed text-muted-foreground",children:s.executive_summary??""})]})]})})})]})}),p.jsxs("section",{className:"animate-fade-in",style:{animationDelay:"0.1s"},children:[p.jsx("h2",{className:"font-display text-xl font-bold mb-4",children:"Planetära gränser â analys"}),p.jsx("div",{className:"rounded-xl border border-border bg-white p-6",children:p.jsxs("div",{className:"grid grid-cols-1 lg:grid-cols-3 gap-6 items-start",children:[p.jsxs("div",{className:"flex flex-col items-start gap-4",children:[p.jsx("img",{src:B2,alt:"De nio planetära gränserna",className:"w-full rounded-lg"}),p.jsxs(hc,{children:[p.jsx(pc,{asChild:!0,children:p.jsxs("button",{className:"w-full flex items-center gap-2 rounded-lg border border-border bg-white p-3 text-xs text-muted-foreground hover:text-foreground transition-colors cursor-pointer",children:[p.jsx("span",{className:"shrink-0 rounded-full border border-border bg-background w-5 h-5 flex items-center justify-center text-[10px] font-bold",children:"?"}),p.jsx("span",{children:"Vad är Planetära gränser?"})]})}),p.jsxs(Ws,{side:"right",className:"max-w-xs text-xs leading-relaxed",children:[p.jsx("p",{children:"Nio vetenskapligt definierade gränser som anger det säkra handlingsutrymmet för mänskligheten. Sex av nio gränser har redan överskridits. Ramverket togs fram av Stockholm Resilience Centre 2009."}),p.jsx("p",{className:"mt-2",children:"Analysen kartlägger ert företags styrkor och möjligheter inom alla nio omrÃ¥den â inte bara klimat. Det synliggör outnyttjade positioneringsmöjligheter inom exempelvis biologisk mÃ¥ngfald, vattenanvändning eller kemisk förorening."})]})]})]}),p.jsxs("div",{className:"lg:col-span-2",children:[p.jsx(L2,{data:s.topic_scores??[]}),(()=>{const A=ex(s.topic_scores??[]);return A!=null&&A.summary?p.jsxs("div",{className:"mt-4 border-t border-border/50 pt-4",children:[p.jsxs("h4",{className:"text-sm font-semibold text-foreground flex items-center gap-1.5 mb-2",children:[p.jsx(Cb,{className:"h-4 w-4 text-primary"}),"Möjligheter"]}),p.jsx("p",{className:"text-sm leading-relaxed text-muted-foreground",dangerouslySetInnerHTML:{__html:A.summary}})]}):null})()]})]})})]}),p.jsxs("section",{className:"animate-fade-in",style:{animationDelay:"0.2s"},children:[p.jsx("h2",{className:"font-display text-xl font-bold mb-4",children:"Risker & möjligheter"}),u.find(A=>A.step_name==="media"&&A.status==="error")&&p.jsx(Ch,{stepName:"media"}),p.jsx(U2,{risks:s.risks??[],opportunities:s.opportunities??[],quickWins:s.quick_wins??[]})]}),p.jsxs("section",{className:"animate-fade-in",style:{animationDelay:"0.3s"},children:[p.jsx("h2",{className:"font-display text-xl font-bold mb-4",children:"Konkurrentjämförelse"}),u.find(A=>A.step_name==="competitors"&&A.status==="error")&&p.jsx(Ch,{stepName:"competitors"}),p.jsx(lR,{competitors:s.competitors??[],positioning:((L=s.your_company)==null?void 0:L.positioning)||""})]}),p.jsxs("section",{className:"animate-fade-in",style:{animationDelay:"0.5s"},children:[p.jsx("h2",{className:"font-display text-xl font-bold mb-4",children:"Källor"}),p.jsx(uR,{sources:c})]}),p.jsx("section",{className:"animate-fade-in",style:{animationDelay:"0.6s"},children:p.jsx(ppe,{})})]})]})]})}const gpe=()=>{const e=fp();return O.useEffect(()=>{console.error("404 Error: User attempted to access non-existent route:",e.pathname)},[e.pathname]),p.jsx("div",{className:"flex min-h-screen items-center justify-center bg-muted",children:p.jsxs("div",{className:"text-center",children:[p.jsx("h1",{className:"mb-4 text-4xl font-bold",children:"404"}),p.jsx("p",{className:"mb-4 text-xl text-muted-foreground",children:"Oops! Page not found"}),p.jsx("a",{href:"/",className:"text-primary underline hover:text-primary/90",children:"Return to Home"})]})})};function Wk({children:e}){const[t,r]=O.useState(!0),[n,i]=O.useState(!1),a=ea();return O.useEffect(()=>{const{data:{subscription:o}}=te.auth.onAuthStateChange((s,l)=>{l?i(!0):a("/",{replace:!0}),r(!1)});return te.auth.getSession().then(({data:{session:s}})=>{s?i(!0):a("/",{replace:!0}),r(!1)}),()=>o.unsubscribe()},[a]),t?p.jsx("div",{className:"min-h-screen flex items-center justify-center bg-background",children:p.jsx(Rt,{className:"h-8 w-8 animate-spin text-primary"})}):n?p.jsx(p.Fragment,{children:e}):null}const ype=new S5,bpe=()=>p.jsx(E5,{client:ype,children:p.jsxs(Wg,{children:[p.jsx(M4,{}),p.jsx(p3,{}),p.jsx(wU,{children:p.jsxs(vU,{children:[p.jsx(vi,{path:"/",element:p.jsx(r8,{})}),p.jsx(vi,{path:"/dashboard",element:p.jsx(Wk,{children:p.jsx(spe,{})})}),p.jsx(vi,{path:"/alla-analyser",element:p.jsx(Wk,{children:p.jsx(cpe,{})})}),p.jsx(vi,{path:"/reset-password",element:p.jsx(lpe,{})}),p.jsx(vi,{path:"/analys",element:p.jsx(upe,{})}),p.jsx(vi,{path:"/analys/:token",element:p.jsx(vpe,{})}),p.jsx(vi,{path:"*",element:p.jsx(gpe,{})})]})})]})});dj(document.getElementById("root")).render(p.jsx(bpe,{}));
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.